On 7/8/99 at 12:02 AM, Chris <[EMAIL PROTECTED]> wrote:
> Part II in what's threatening to be my Pedantic Bean Series . . .
Please, spare us. I'd also change the word "pedantic" to
the more appropriate, "sophomoric".
> [some classes ] Shouldn't Be a Bean. All well and good, but then
> JSP apparantly decides everything MUST be a bean --
> even things that have no use manipulation with a visual tool.
> So that seemed like a bad decision by the JSP guys.
The commonest words of a know-it-all: someone else got it wrong.
Not me -- they did, obviously.
Maybe if you stopped to think about what the JSP-compliant web server
does with a JSP, you might understand just what the "JSP guys" were
thinking. Via reflection, the JSP can set properties of the bean. How
do you make a class so that this can be done? You provide public
accessor methods, otherwise known as "getter/setter" methods.
Additionally, one of the requirements of a JavaBean is that it have
a zero-parameter constructor. Seems to fit with the JSP spec doesn't
it, especially when it comes to serialization and session management
of such beans, eh?
> So now I'm frustrated, I've read some stuff that annoyed me (not hard),
> and I STILL don't really know what a bean is or how to write one. ...
>
> And guess what?
> They're Not Beans!!!!!!!!!!
How do you know, since you admitted later on that you still don't
know what a JavaBean is? (Even though you taught a class on Beans!?)
> They're just plain ol classes, the kind I actually know how to write.
>
> Which brings me to the place I could have started from if I wasn't
> hamming it up . . .
You said it. You could have said all of this in about two sentences:
"I've just read the entire JB spec, and I still don't understand.
Can someone give me some references?"
> ... All griping & insufferable garrulity aside, I would kind of
> like an answer.
Here's a start: 1) Go to a good bookstore. There are a number of
good books on JavaBeans. 2) In lieu of that, buy an IDE meant for
developing in Java. One suggestion would be Borland's JBuilder, whose
manuals discuss what a JavaBean is, and how you write one -- quite
clearly. Your present tool is letting you down if it doesn't help
you create something so fundamental to Java programming as a JavaBean.
Here's a free start:
http://www.borland.com/techpubs/jbuilder/jbuilder3/pdf_index.html
Scan down the page and find "Creating JavaBeans". The PDF file
is a portion of their entire suite of manuals for JBuilder.
After that, and other leg work on your part, you won't need to
continue what otherwise promises to be a very aggravating mini-
series.
Paul Furbacher
===========================================================================
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff JSP-INTEREST". For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".