Spread the love

Abstract Interface Member in Java

Spread the love

Abstract Interface Member in Java

The Member interface defines methods shared by members of a class: fields, methods, and constructors.

The structure of the abstract interface Member is given by

public abstract interface java.lang.reflect.Member {
// Constants
public final static int DECLARED;
public final static int PUBLIC;
// Methods
public abstract Class getDeclaringClass();
public abstract int getModifiers();
public abstract String getName();
}

The details of the class structure are given as follows:

public final static int DECLARED;

public final static int DECLARED represents a  constant that represents the set of all declared members of a class or interface. This set does not include inherited members. The set can be used in calls to SecurityManager.checkMemberAccess().

public final static int PUBLIC;

public final static int PUBLIC represents a constant that represents the set of all public members of a class or interface, including inherited members. The set can be used in calls to SecurityManager.checkMemberAccess().

public abstract Class getDeclaringClass();

public abstract Class getDeclaringClass() method returns the Class object for the class in which this member is declared.

This method returns the Class object that represents the class that declared this member.

public abstract int getModifiers();

public abstract int getModifiers() method returns an integer value that represents the modifiers of this member. The Modifier class should be used to decode the returned value.

READ  Class Properties in Java

This method returns an integer that represents the modifier keywords used to declare this member.

public abstract String getName();

public abstract String getName() method returns the name of this member.

READ  Class Properties in Java

This method returns the name of this member as a String.




Spread the love
READ  Abstract Interface URLStreamHandlerFactory in Java
Animesh Chatterjeehttps://techtravelhub.com/
I am the founder and owner of the blog - TechTravelHub.com, always love to share knowledge on test automation,tools,techniques and tips.I am a passionate coder of Java and VBScript.I also publish articles on Travel ideas and great honeymoon destinations.Apart from these, I am a gear-head,love to drive across India. I have shared lots of articles here on How to travel several parts of India.Customization of cars aka car modification is my another hobby.Get in touch with me on ani01104@gamil.com

Related Articles

Super Keyword in Java Simplified

Super Keyword Super Keyword in Java Simplified: Java defines a special keyword called...

Comments

LEAVE A REPLY

Please enter your comment!
Please enter your name here

Recent Posts

Super Keyword in Java Simplified

Super Keyword Super Keyword in Java Simplified: Java defines a special...

Learn Object Repository in UFT in An Efficient and Fast Manner

Object Repository in UFT The post will cover the following...

Learn What Primary Tools For Test Automation

Primary Tools For Test Automation According to the Gartner report...

EDITOR PICKS


Spread the love