Results 1 to 6 of 6
Thread: Final,abstract and static
- 12-26-2007, 11:13 AM #1
Member
- Join Date
- Dec 2007
- Posts
- 4
- Rep Power
- 0
- 12-26-2007, 11:34 PM #2
This, coming from the source - Sun itself.
- 12-28-2007, 12:19 AM #3
Member
- Join Date
- Dec 2007
- Posts
- 12
- Rep Power
- 0
final means method cannot be overridden; constructors can't be overridden
abstract means method must be overridden; static methods can't be overridden
- 01-08-2008, 01:07 PM #4
Member
- Join Date
- Dec 2007
- Posts
- 4
- Rep Power
- 0
Still confused!!!!!!
I still dont get why constructor cant be declared as final????
- 01-08-2008, 01:37 PM #5
You can't mark constructors as final as there would be no meaning, as spoon says constructors cannot be overridden, final only makes sense when applied to something that _could_ have been overridden but you don't want it to be.
-- Hope that helps
- 01-09-2008, 05:23 AM #6
Member
- Join Date
- Dec 2007
- Posts
- 4
- Rep Power
- 0
Similar Threads
-
Abstract Class with Static Methods
By bugger in forum New To JavaReplies: 7Last Post: 09-05-2008, 12:20 AM -
Error: Non-static method append(char) cannot be referenced from a static context
By paul in forum Advanced JavaReplies: 1Last Post: 08-07-2007, 05:05 AM -
Error: non-static variable height cannot be referenced from a static context at line
By fernando in forum AWT / SwingReplies: 1Last Post: 08-01-2007, 09:25 PM


LinkBack URL
About LinkBacks
Reply With Quote

Bookmarks