jQuery in Action, 2nd edition*
The moose likes Java in General and the fly likes Calling Superclass Methods and Forgetting to Use the Return Value Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Java in General
Bookmark "Calling Superclass Methods and Forgetting to Use the Return Value " Watch "Calling Superclass Methods and Forgetting to Use the Return Value " New topic
Author

Calling Superclass Methods and Forgetting to Use the Return Value

melvin bernabe
Greenhorn

Joined: Sep 12, 2004
Posts: 2
can someone help me with my code..I wants to include the superclass toString() result in the subclass toString() result..
here is the my code:
****************************************************************************
public class GraphicalRectangle extends Rectangle {
Color fillColor;
boolean beveled;
...
public String toString() {
super();
return("color=" + fillColor + ", beveled=" + beveled);
}
}


nhivlem...
Pat Hays
Ranch Hand

Joined: Aug 20, 2004
Posts: 138


Download Java GUI Builder, <a href="http://www.mars3000.com" target="_blank" rel="nofollow">http://www.mars3000.com</a>
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: Calling Superclass Methods and Forgetting to Use the Return Value