wood burning stoves 2.0
The moose likes Beginning Java and the fly likes Is this consider a JavaBean? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of OCA Java SE 8 Programmer I Study Guide this week in the OCAJP 8 forum!
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "Is this consider a JavaBean?" Watch "Is this consider a JavaBean?" New topic
Author

Is this consider a JavaBean?

K. Tsang
Bartender

Joined: Sep 13, 2007
Posts: 3045
    
    9

Hi all, I want to make sure my definition of JavaBean.



I want to point out is the method setVar2(String) valid if classify as JavaBean? Or "must" I use setVar2(int)?


K. Tsang JavaRanch SCJP5 SCJD OCPJP7 OCPWCD5 OCPBCD5 OCPWSD5 OCMJEA5 part 1 part 2/3
Campbell Ritchie
Sheriff

Joined: Oct 13, 2005
Posts: 44581
    
  34
I am not sure, but I think you need a setVar2(int) method.
K. Tsang
Bartender

Joined: Sep 13, 2007
Posts: 3045
    
    9

thanks Campbell, so i assume it's not a javabean.
Balu Sadhasivam
Ranch Hand

Joined: Jan 01, 2009
Posts: 874




One of the rule of Java Beans is the setter argument type must be same as the getter return type.
K. Tsang
Bartender

Joined: Sep 13, 2007
Posts: 3045
    
    9

thanks Balu
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Is this consider a JavaBean?
 
It's not a secret anymore!