Mitika Moharil

Greenhorn
+ Follow
since Jul 29, 2008
Merit badge: grant badges
For More
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Mitika Moharil

Can we implement an interface in a JSP?

If yes please explain and if no please explain. I am new to J2EE so confused with this question.
14 years ago
JSP
Hello,

I am attaching here a file with a tree structure. It is a directory structure.

In that image D1 is a parent directory, D2,D3,D4 are subdirectories and F1, F2 represents files. I want to create my own classes which represents this directory structure.

1) Please note that I dont want to use TreeSet or any other collection because these are built in classes in Java. I want to create my classes.
2) If i create D1 as an interface or abstract class. for example D1 is abstract class the D2,D3,D4 must extends D1 but problem is in future if I want to create another subdirectory lets say D5 then I have to create a new subclass as D5. That means for each new sudbdirectory creation I have to create anew class. This is not correct. I want to create classes such as by simply creating object of those classes we can create subdirectory.

Could you please help me to resolve this problem
14 years ago