Member INTERFACE

The interface defining certain shared properties of a class member.

All Members


TypeNameSignature
methodgetAttributespublic Attribute[] getAttributes()
methodgetKindpublic MemberKind getKind()
methodgetNamepublic String getName()
methodisStaticpublic bool isStatic()

Methods


public Attribute[] getAttributes()

Get all the attributes annotated on the member definition.

The result array contains each instance of Attribute placed at the type definition.

Returns

  • The attributes annotated on this member. In case of members which do not have attributes, this returns a 0-sized Attribute array.

public MemberKind getKind()

Get the kind of this member. Typically used before downcasting.

Returns

  • The kind of this member.

public String getName()

Get the name of this member. Note due to class inheritance and method overloading, there could be multiple methods possessing the same name. All the constructors have the same name as that of the containing class.

Returns

  • The member's name.

public bool isStatic()

Whether this member is static. Constructors are always non-static, but methods and fields can vary for each member.

If a member is static, accessing to it requires specification of the instance target, which is prominently supplied among the arguments upon the pertaining calls.

Returns

  • True if the member is static; false instance-scoped.