public final class JavaAttributeInfo extends Object
| Constructor and Description |
|---|
JavaAttributeInfo(org.onosproject.yang.compiler.datamodel.YangType<?> attrType,
String name,
boolean isListAttr,
boolean isQualifiedName)
Creates object of java attribute info.
|
| Modifier and Type | Method and Description |
|---|---|
static JavaAttributeInfo |
getAttributeInfoForTheData(org.onosproject.yang.compiler.datamodel.javadatamodel.JavaQualifiedTypeInfo importInfo,
String attributeName,
org.onosproject.yang.compiler.datamodel.YangType<?> attributeType,
boolean isQualifiedAccess,
boolean isListAttribute)
Returns java attribute info.
|
String |
getAttributeName()
Returns name of the attribute.
|
org.onosproject.yang.compiler.datamodel.YangType<?> |
getAttributeType()
Returns the data type info of attribute.
|
org.onosproject.yang.compiler.datamodel.YangCompilerAnnotation |
getCompilerAnnotation()
Returns the compiler annotation.
|
String |
getCurHolderOrCount()
Returns current holder or count in type list of attribute for from string method.
|
JavaQualifiedTypeInfoTranslator |
getImportInfo()
Returns the import info for the attribute type.
|
boolean |
isIntConflict()
Returns true if conflict between int and uint.
|
boolean |
isListAttr()
Returns if the added attribute is a list of info.
|
boolean |
isLongConflict()
Returns true if conflict between long and uLong.
|
boolean |
isQualifiedName()
Returns if the added attribute has to be accessed in a fully qualified
manner.
|
boolean |
isShortConflict()
Returns true if conflict between short and uint8.
|
void |
setAttributeName(String attrName)
Sets name of the attribute.
|
void |
setAttributeType(org.onosproject.yang.compiler.datamodel.YangType<?> type)
Sets the data type info of attribute.
|
void |
setCompilerAnnotation(org.onosproject.yang.compiler.datamodel.YangCompilerAnnotation compilerAnnotation)
Sets the compiler annotation.
|
void |
setCurHolderOrCount(String curHolderOrCount)
Sets current holder or count in type list of attribute for from string method.
|
void |
setImportInfo(JavaQualifiedTypeInfoTranslator importInfo)
Sets the import info for the attribute type.
|
void |
setIsQualifiedAccess(boolean isQualified)
Sets if the added attribute has to be accessed in a fully qualified
manner.
|
void |
setShortConflict(boolean shortConflict)
Sets true if conflict between short and uint8.
|
public JavaAttributeInfo(org.onosproject.yang.compiler.datamodel.YangType<?> attrType,
String name,
boolean isListAttr,
boolean isQualifiedName)
attrType - YANG typename - attribute nameisListAttr - is list attributeisQualifiedName - is qualified namepublic org.onosproject.yang.compiler.datamodel.YangType<?> getAttributeType()
public void setAttributeType(org.onosproject.yang.compiler.datamodel.YangType<?> type)
type - the data type info of attributepublic String getAttributeName()
public void setAttributeName(String attrName)
attrName - name of the attributepublic boolean isListAttr()
public boolean isQualifiedName()
public void setIsQualifiedAccess(boolean isQualified)
isQualified - if the added attribute has to be accessed in a fully
qualified mannerpublic JavaQualifiedTypeInfoTranslator getImportInfo()
public void setImportInfo(JavaQualifiedTypeInfoTranslator importInfo)
importInfo - import info for the attribute typepublic org.onosproject.yang.compiler.datamodel.YangCompilerAnnotation getCompilerAnnotation()
public void setCompilerAnnotation(org.onosproject.yang.compiler.datamodel.YangCompilerAnnotation compilerAnnotation)
compilerAnnotation - the compiler annotation to setpublic boolean isIntConflict()
public boolean isLongConflict()
public boolean isShortConflict()
public void setShortConflict(boolean shortConflict)
shortConflict - true if conflict between short and uint8public static JavaAttributeInfo getAttributeInfoForTheData(org.onosproject.yang.compiler.datamodel.javadatamodel.JavaQualifiedTypeInfo importInfo, String attributeName, org.onosproject.yang.compiler.datamodel.YangType<?> attributeType, boolean isQualifiedAccess, boolean isListAttribute)
importInfo - java qualified type infoattributeName - attribute nameattributeType - attribute typeisQualifiedAccess - is the attribute a qualified accessisListAttribute - is list attributepublic String getCurHolderOrCount()
public void setCurHolderOrCount(String curHolderOrCount)
curHolderOrCount - current holder or count in type list of attribute for from string methodCopyright © 2018. All rights reserved.