|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface JCoClassMetaData
Encapsulates the metadata of ABAP classes. The interface comprises public methods for access to ABAP class definition. JCoClassMetaData is used by JCoAbapObjects.
Note: The implementation for this interface provided by the JCo runtime. Other implementations are not supported.
Nested Class Summary | |
---|---|
static class |
JCoClassMetaData.JCoAttributeKind
An enumeration of the possible or relevant attribute types. |
Field Summary |
---|
Fields inherited from interface com.sap.conn.jco.JCoMetaData |
---|
TYPE_ABAPOBJECT, TYPE_BCD, TYPE_BOX, TYPE_BYTE, TYPE_CHAR, TYPE_DATE, TYPE_DECF16, TYPE_DECF34, TYPE_EXCEPTION, TYPE_FLOAT, TYPE_GENERIC_BOX, TYPE_INT, TYPE_INT1, TYPE_INT2, TYPE_INVALID, TYPE_ITAB, TYPE_NUM, TYPE_STRING, TYPE_STRUCTURE, TYPE_TABLE, TYPE_TIME, TYPE_XSTRING, UNINITIALIZED |
Method Summary | |
---|---|
void |
add(java.lang.String declaringClass,
java.lang.String attributeName,
int attributeType,
int charLength,
int decimals,
java.lang.String description,
java.lang.Object metaData,
JCoExtendedFieldMetaData extended,
JCoClassMetaData.JCoAttributeKind kind,
boolean readOnly,
java.lang.String initialValue)
Adds an attribute to the class definition |
void |
addImplementedInterface(java.lang.String implementedInterface)
Adds an interface implemented by the class type |
void |
addParentClass(java.lang.String parentClass)
Adds the parent class |
JCoClassMetaData.JCoAttributeKind |
getAttributeKind(int index)
Returns what kind of attribute the given attribute is. |
JCoClassMetaData.JCoAttributeKind |
getAttributeKind(java.lang.String attributeName)
Returns what kind of attribute the given attribute is. |
java.lang.String |
getDeclaringClass(int index)
Returns the name of the declaring class of the given attribute. |
java.lang.String |
getDeclaringClass(java.lang.String attributeName)
Returns the name of the declaring class of the given attribute. |
java.lang.String |
getDefault(int index)
Returns the default value of the data field at the specified index |
java.lang.String |
getDefault(java.lang.String attributeName)
Returns the default value for the attribute with the given name |
java.util.List<java.lang.String> |
getImplementedInterfaces()
Returns the list of implemented interfaces. |
java.util.List<java.lang.String> |
getParentClasses()
Returns the parent classes. |
boolean |
isReadOnly(int index)
Indicates whether the given attribute is a read-only attribute or not. |
boolean |
isReadOnly(java.lang.String attributeName)
Indicates whether the given attribute is a read-only attribute or not. |
Method Detail |
---|
java.util.List<java.lang.String> getParentClasses()
String
array starting with the root class and then going down the extension
hierarchy until the current class is reached.
java.util.List<java.lang.String> getImplementedInterfaces()
boolean isReadOnly(java.lang.String attributeName)
attributeName
- -
the name of the attribute
true
if the attribute is read-only (const
) or not
JCoRuntimeException
- with group JCoException.JCO_ERROR_FIELD_NOT_FOUND
if an attribute with
the given name does not existisReadOnly(int)
boolean isReadOnly(int index)
index
- -
the index of the attribute
true
if the attribute is read-only (const
) or notisReadOnly(String)
JCoClassMetaData.JCoAttributeKind getAttributeKind(java.lang.String attributeName)
attributeName
- -
the name of the attribute
JCoClassMetaData.JCoAttributeKind
JCoRuntimeException
- with group JCoException.JCO_ERROR_FIELD_NOT_FOUND
if an attribute with
the given name does not existgetAttributeKind(int)
JCoClassMetaData.JCoAttributeKind getAttributeKind(int index)
index
- -
the index of the attribute
JCoClassMetaData.JCoAttributeKind
getAttributeKind(String)
java.lang.String getDeclaringClass(java.lang.String attributeName)
attributeName
- -
the name of the attribute
getDeclaringClass(String)
java.lang.String getDeclaringClass(int index)
index
- -
the index of the attribute
JCoRuntimeException
- with group JCoException.JCO_ERROR_FIELD_NOT_FOUND
if an attribute with
the given name does not existgetDeclaringClass(int)
java.lang.String getDefault(int index)
index
- -
the index of the field
getDefault(String)
java.lang.String getDefault(java.lang.String attributeName)
attributeName
- -
the name of the attribute
JCoRuntimeException
- with group JCoException.JCO_ERROR_FIELD_NOT_FOUND
if an attribute with
the given name does not existgetDefault(int)
void add(java.lang.String declaringClass, java.lang.String attributeName, int attributeType, int charLength, int decimals, java.lang.String description, java.lang.Object metaData, JCoExtendedFieldMetaData extended, JCoClassMetaData.JCoAttributeKind kind, boolean readOnly, java.lang.String initialValue)
declaringClass
- class where the attribute was declaredattributeName
- attribute nameattributeType
- type of the attributecharLength
- length in charsdecimals
- number of decimals in case of BCD typedescription
- attribute descriptionmetaData
- metadata if the attribute has a non scalar typeextended
- additional object associated with the attributekind
- kind of attribute - instance, class member or constantreadOnly
- flag, true if the attribute has read only accessinitialValue
- initial value for the attributevoid addParentClass(java.lang.String parentClass)
parentClass
- a parent classvoid addImplementedInterface(java.lang.String implementedInterface)
implementedInterface
- implemented interface
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |