Member Modifier (Cross Ref > OOP Basics)
Languages Focus Traditional private , protected , public , etc. member modifiers are documented under the member visibility topic of the Cross Reference Encyclopedia . With member modifiers here, we address additional member modifiers such as method and field modifiers.
ASP Classic:
"Member Modifiers" Default
Other than visibility modifiers Public and Private , the only other member modifier available in ASP Classic is Default which is used only with the Public keyword in a class block. It indicates that the sub, function, or property is the default method for the class. You can have only one Default per class.
More Info / Comment
C#:
"Member Modifiers"
The method modifiers are abstract, extern, new, partial, sealed, virtual , and override . Specify C# member modifiers as follows:
abstract SomeMethod() {..}
The field modifiers are const , readonly , static , volatile . Specify field modifiers as follows:
readonly int MyAge;
More Info / Comment
Corel Paradox:
"Member Modifiers" Not Supported
Delphi:
"Member Modifiers"
Specify Delphi member modifiers as follows:
reintroduce ; overload ; [binding modifier]; [calling convention]; abstract ; [warning]
The binding modifiers are virtual , dynamic , or override .
The calling conventions are register , pascal , cdecl , stdcall , or safecall .
The warnings are platform , deprecated , or library .
Additional directives include reintroduce , abstract , class , static , overload , and message .
Syntax Example: TCyborg = class(TObject) public procedure Speak(pMessage: String); virtual; end; TSeries888 = class(TCyborg) public procedure Speak(pMessage: String); override; end;
Delphi Prism:
"Member Modifiers"
Prism supports a full suite of member modifiers. Prism virtuality modifiers are virtual , override , final , and reintroduce .
Prism general modifiers are abstract , empty , async , external , locked , unsafe , implements , and iterator .
Not all member types support all member modifiers. For example, member fields support only readonly and implements .
Syntax Example: Cyborg = public class(System.Object) public method Speak(pMessage: String); virtual; end; Series888 = public class(Cyborg) public method Speak(pMessage: String); override; end;
VB.Net:
"Member Modifiers"
The method modifiers include�MustOverride,�NotOverridable, Overridable, Overrides . Specify�VB.Net member modifiers as follows:
Public Overrides Function SomeFunction() As Double
The field modifiers include ReadOnly and Shared . Specify field modifiers as follows:
Public ReadOnly SomeField As String
More Info / Comment