This week's book giveaway is in the Servlets forum.
We're giving away four copies of Murach's Java Servlets and JSP and have Joel Murach on-line!
See this thread for details.
The moose likes Beginning Java and the fly likes Java file / Java bean Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "Java file / Java bean" Watch "Java file / Java bean" New topic
Author

Java file / Java bean

aakash bhatt
Ranch Hand

Joined: Jan 09, 2003
Posts: 182
when is a Java file a Java bean
Regards,
aakash
Jeroen Wenting
Ranch Hand

Joined: Oct 12, 2000
Posts: 5093
Never
A Java Bean is a class (and more properly an instance of such a class) that conforms to the standards set for Java Beans, which basically means getters and setters called getXXX and setXXX for all public properties and serialisation support.
Therefore the java file (either source or compiled source) is not a bean, though a bean can be loaded from a file defining a class that conforms to the Bean specifications.


42
Pradeep bhatt
Ranch Hand

Joined: Feb 27, 2002
Posts: 8904

serialisation support.

I dont think serialization support is mandatory.


Groovy
Dirk Schreckmann
Sheriff

Joined: Dec 10, 2001
Posts: 7023
You might want to take a look at the JavaBeans Trail of Sun's Java Tutorial.


[How To Ask Good Questions] [JavaRanch FAQ Wiki] [JavaRanch Radio]
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: Java file / Java bean
 
Similar Threads
file uploading error
Java Bean and weblogic6.0
NoClassDefFoundError
knowing how many guests and registered users
Spring inject a list