Class AnnotatedElement
.NET implementations of https://docs.oracle.com/javase/8/docs/api/java/lang/reflect/AnnotatedElement.html
public class AnnotatedElement : JVMBridgeBase<AnnotatedElement>, IDynamicMetaObjectProvider, IJVMBridgeCore, IDisposable, IJVMBridgeBaseStatic, IJVMBridgeBase, IJVMBridgeDefinition, IAnnotatedElement
- Inheritance
-
AnnotatedElement
- Implements
- Derived
- Inherited Members
- Extension Methods
Constructors
AnnotatedElement()
Default constructor: even if the corresponding Java class does not have one, it is mandatory for JCOBridge
[Obsolete("AnnotatedElement class represents, in .NET, an instance of a JVM interface or abstract class. This public initializer is needed for JCOBridge internal use, other uses can produce unidentible behaviors.")]
public AnnotatedElement()
AnnotatedElement(params object[])
Generic constructor: it is useful for JCOBridge when there is a derived class which needs to pass arguments to the highest JVMBridgeBase class
[Obsolete("AnnotatedElement class represents, in .NET, an instance of a JVM interface or abstract class. This public initializer is needed for JCOBridge internal use, other uses can produce unidentible behaviors.")]
public AnnotatedElement(params object[] args)
Parameters
args
object[]
Properties
Annotations
public Annotation[] Annotations { get; }
Property Value
BridgeClassName
Java class name to be instantiated
public override string BridgeClassName { get; }
Property Value
DeclaredAnnotations
public Annotation[] DeclaredAnnotations { get; }
Property Value
IsBridgeAbstract
true if the BridgeClassName is an abstract class, i.e. cannot be created an instance
public override bool IsBridgeAbstract { get; }
Property Value
IsBridgeCloseable
true if the BridgeClassName implements Closeable
public override bool IsBridgeCloseable { get; }
Property Value
IsBridgeInterface
true if the BridgeClassName is an interface, i.e. does not have any public constructor
public override bool IsBridgeInterface { get; }
Property Value
IsBridgeStatic
true if the BridgeClassName is a static class, i.e. does not have any public constructor
public override bool IsBridgeStatic { get; }
Property Value
Methods
GetAnnotation<T>(Class)
public T GetAnnotation<T>(Class arg0) where T : IAnnotation, new()
Parameters
Returns
- T
T
Type Parameters
GetAnnotation<T>(Class<T>)
Returns this element's annotation for the specified type if such an annotation is present, else null.
public T GetAnnotation<T>(Class<T> annotationClass) where T : Annotation
Parameters
annotationClass
Class<T>
Returns
- T
Type Parameters
T
GetAnnotationsByType<T>(Class)
public T[] GetAnnotationsByType<T>(Class arg0) where T : IAnnotation, new()
Parameters
Returns
- T[]
T
Type Parameters
GetAnnotationsByType<T>(Class<T>)
Returns annotations that are associated with this element.
public T[] GetAnnotationsByType<T>(Class<T> annotationClass) where T : Annotation
Parameters
annotationClass
Class<T>
Returns
- T[]
Type Parameters
T
GetDeclaredAnnotation<T>(Class)
public T GetDeclaredAnnotation<T>(Class arg0) where T : IAnnotation, new()
Parameters
Returns
- T
T
Type Parameters
GetDeclaredAnnotation<T>(Class<T>)
Returns this element's annotation for the specified type if such an annotation is directly present, else null.
public T GetDeclaredAnnotation<T>(Class<T> annotationClass) where T : Annotation
Parameters
annotationClass
Class<T>
Returns
- T
Type Parameters
T
GetDeclaredAnnotationsByType<T>(Class)
public T[] GetDeclaredAnnotationsByType<T>(Class arg0) where T : IAnnotation, new()
Parameters
Returns
- T[]
T
Type Parameters
GetDeclaredAnnotationsByType<T>(Class<T>)
Returns this element's annotation(s) for the specified type if such annotations are either directly present or indirectly present.
public T[] GetDeclaredAnnotationsByType<T>(Class<T> annotationClass) where T : Annotation
Parameters
annotationClass
Class<T>
Returns
- T[]
Type Parameters
T
IsAnnotationPresent(Class)
public bool IsAnnotationPresent(Class arg0)
Parameters
Returns
IsAnnotationPresent<T>(Class<T>)
public bool IsAnnotationPresent<T>(Class<T> annotationClass) where T : Annotation
Parameters
annotationClass
Class<T>
Returns
Type Parameters
T