For Programmers: Free Programming Magazines  


Home > Archive > Java Help > August 2005 > How to build a tree in a jsp ?









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author How to build a tree in a jsp ?
MC

2005-08-15, 5:03 pm

Hi to all,

First excuse my bad english ;-)

I'm working on a struts web application. I've to develop a screen in
order to construct and/or modify a hierarchical structure (typically a
DOM tree) of the following type:
http://www.oracle.com/technology/or...s/o53xml_f1.gif

A click on a node would allow the user to define the childs nodes ....

I don't know how to proceed ....

Any ideas ?

Thanks a lot for yours answers

Marie
Andrew Thompson

2005-08-15, 5:03 pm

On Mon, 15 Aug 2005 16:51:07 +0200, MC wrote:

> I'm working on a struts web application. I've to develop a screen ..


Do you mean 'develop a web page'? Oh, wait..
"Sub: How to build a tree in a jsp ?"
(please repeat all important words from subject in body -
some people don't read 'subject' lines)

A web page might still be done with DHTML (HTML and
JavaScript) or an applet.

>..in
> order to construct and/or modify a hierarchical structure (typically a
> DOM tree) of the following type:
> http://www.oracle.com/technology/or...s/o53xml_f1.gif


As mentioned in this article?
<http://www.oracle.com/technology/or.../o53devxml.html>

How did you come by that image?

> A click on a node would allow the user to define the childs nodes ....
>
> I don't know how to proceed ....


Where are you now?

I ask because developing web-applications is not easy,
but it also seems to be attracting a lot of people who
have little experience in Java (or debugging, or web
development..)

It almost sounds as though this page might get you kick started.
<http://home.earthlink.net/~patricia...n/beginner.html>

[ Note: Follow-Ups set to c.l.j.help. ]

--
Andrew Thompson
physci.org 1point1c.org javasaver.com lensescapes.com athompson.info
"If I could find the reason, I'd know the answer why" Status Quo
'Gerdundula'
jan V

2005-08-15, 5:03 pm

> I don't know how to proceed ....
>
> Any ideas ?


Marie, when you tackle any non-trivial stuff which relies on several
technologies (Struts, JSP, XML, DOM, .. whatever), you really need to make
sure you are *comfortable* with each and every one of these *before* you
design your solution. Did I just write "design your solution" there? Yes I
did... not code, but design first.

It seems you're already swimming/drowning in code, without even having
thought through the design.

If you're a salaried programmer, you need to go to your manager(s) and ask
them if you and them can allocate a reasonable amount of time to
self-learning of technologies BEFORE continuing on your project.


Jon Martin Solaas

2005-08-16, 5:08 pm

jan V wrote:
>
>
> Marie, when you tackle any non-trivial stuff which relies on several
> technologies (Struts, JSP, XML, DOM, .. whatever), you really need to make
> sure you are *comfortable* with each and every one of these *before* you
> design your solution. Did I just write "design your solution" there? Yes I
> did... not code, but design first.
>
> It seems you're already swimming/drowning in code, without even having
> thought through the design.
>
> If you're a salaried programmer, you need to go to your manager(s) and ask
> them if you and them can allocate a reasonable amount of time to
> self-learning of technologies BEFORE continuing on your project.
>
>


One can also assume that we are not dealing with a complete moron here,
and that the question simply is; How to best represent an editable,
hierarchical structure on the web. It is not given that a programmer
fluent in Strus, JSP, XML, DOM ... whatever, really has a ready solution
for that up his/hers nose. I use all those technologies on a daily
basis, and still I'd appreciate some input if I were to implement a
tree/hierarchy-editor for the web.

I think the requirements for the actual GUI/representation must be
worked out here. HTML, Applet, Gif-image? How nice and slick must the
layout be? Interaction considerations; How to add a new node;
Right-click menu or [Add Child]/[Add Siebling] submit buttons for each node?

Is it acceptable to represent the tree-structure in an explorer-like
view? If yes, it should be possible to re-use some existing code from
the web. After all, such tree-structures are used commonly for hierarchy
navigation (catalogs, site-structures, etc.). Different web frameworks
also have such components pre-defined, that could be extended/subclassed.

--
jon martin solaas
jan V

2005-08-17, 10:02 pm

> > If you're a salaried programmer, you need to go to your manager(s) and
ask
>
> One can also assume that we are not dealing with a complete moron here,


I always assume this. Morons never even get stranded on the shores of
c.l.j.p by accident ;-)

> and that the question simply is; How to best represent an editable,
> hierarchical structure on the web.


As an ex-video games programmer, you'll excuse me for saying that I hate the
current madness of trying to shoehorn every possible application into
f*cking web browsers. Maybe I'm part of a small minority, but I still
believe in standalone applications... applications in which simple-ish
things like interactive tree GUIs don't pose massive design decisions which
risk the whole success or failure of a project !

Browsers are brilliant for PAGES... but IMO they are not a suitable medium
for complex applications.. especially not those requiring non-trivial GUIs
(e.g. one containing an editable tree for starters...)

I mean, we're all Java programmers, so we can write standalone executables
which run on most popular platforms... so please, what am I missing? Why
does every tom, dick and harry application have to be a "web app"?? So that
virus and adware writers have a nice fat, static target to hit all the time?


Andrew Thompson

2005-08-17, 10:02 pm

On Wed, 17 Aug 2005 21:25:59 GMT, jan V wrote:

> Browsers are brilliant for PAGES... but IMO they are not a suitable medium
> for complex applications..


I largely agree.

> I mean, we're all Java programmers, so we can write standalone executables
> which run on most popular platforms... so please, what am I missing? Why
> does every tom, dick and harry application have to be a "web app"??


I think a lot of people have remote data and begin
immediately to think of accessing it 'via the net',
which in turn leads to the follow on 'by browser'.

Unfortuanately, too often people ask how do I connect
inappropriate technology 'a' to inappropriate technology 'b',
only to have a number of people rush un with 'the answer'
rather than stopping to question if the OP has any idea
what they are doing.

Jon Martin Solaas[color=darkred]

Not a comment directly on this thread, but that does
seem like a rash assumption for a message cross-posted
to c.l.j.programmer and c.l.j.help.

There are posts made to c.l.j.programmer alone that show the
classic signs of 'a fundamental and profound lack of inexperience'
(let's not call them morons).

Note. Follow-Ups set to c.l.j.programmer only.

--
Andrew Thompson
physci.org 1point1c.org javasaver.com lensescapes.com athompson.info
"Everybody's groovin' to their own song."
Josh Abrahams/Amiel Daemion 'Addicted to Bass'
Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2008 codecomments.com