Win a copy of Design for the Mind this week in the Design forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

interfaces

 
Kourosh Keshavarzi
Ranch Hand
Posts: 66
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Are variables in an interface implicityly just static and public
or are the static public and final.

 
Kourosh Keshavarzi
Ranch Hand
Posts: 66
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
In general what modifiers are allowed to be used if you want to overide the default modifiers.
thanks
 
Bin Zhao
Ranch Hand
Posts: 73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Yes,variables in interface implicitly are public,static final.
 
Mary Anitha
Greenhorn
Posts: 23
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Kourosh Keshavarzi:
In general what modifiers are allowed to be used if you want to overide the default modifiers.
thanks

In general default,protected or public are allowed to override a method with a default modifier

[This message has been edited by Mary Anitha (edited October 28, 2000).]
 
Mary Anitha
Greenhorn
Posts: 23
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I would like to add that
methods in an interface are implicitly public and abstract

Originally posted by Bin Zhao:
Yes,variables in interface implicitly are public,static final.

 
Kourosh Keshavarzi
Ranch Hand
Posts: 66
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks Bin and Mary
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic