ret.setIsIndexable((Boolean) attribInfo.get("isIndexable")); ret.setIncludeInNotification((Boolean) attribInfo.get("includeInNotification")); ret.setDefaultValue((String) attribInfo.get("defaultValue")); ret.setDescription((String) attribInfo.get("description"));
ret.setIsIndexable((Boolean) attribInfo.get("isIndexable")); ret.setIncludeInNotification((Boolean) attribInfo.get("includeInNotification")); ret.setDefaultValue((String) attribInfo.get("defaultValue")); ret.setDescription((String) attribInfo.get("description"));
public static AtlasEntityDef createPrimitiveEntityDef() { AtlasEntityDef newtestEntityDef = new AtlasEntityDef("newtest"); AtlasAttributeDef attrName = new AtlasAttributeDef("name", AtlasBaseTypeDef.ATLAS_TYPE_STRING); AtlasAttributeDef attrDescription = new AtlasAttributeDef("description", AtlasBaseTypeDef.ATLAS_TYPE_STRING); attrDescription.setIsOptional(false); AtlasAttributeDef attrcheck = new AtlasAttributeDef("check", AtlasBaseTypeDef.ATLAS_TYPE_STRING); attrcheck.setIsOptional(true); AtlasAttributeDef attrSourceCode = new AtlasAttributeDef("sourcecode", AtlasBaseTypeDef.ATLAS_TYPE_STRING); attrSourceCode.setDefaultValue("Hello World"); attrSourceCode.setIsOptional(true); AtlasAttributeDef attrCost = new AtlasAttributeDef("Cost", AtlasBaseTypeDef.ATLAS_TYPE_INT); attrCost.setIsOptional(true); attrCost.setDefaultValue("30"); AtlasAttributeDef attrDiskUsage = new AtlasAttributeDef("diskUsage", AtlasBaseTypeDef.ATLAS_TYPE_FLOAT); attrDiskUsage.setIsOptional(true); attrDiskUsage.setDefaultValue("70.50"); AtlasAttributeDef attrisStoreUse = new AtlasAttributeDef("isstoreUse", AtlasBaseTypeDef.ATLAS_TYPE_BOOLEAN); attrisStoreUse.setIsOptional(true); attrisStoreUse.setDefaultValue("true"); newtestEntityDef.addAttribute(attrName); newtestEntityDef.addAttribute(attrDescription); newtestEntityDef.addAttribute(attrcheck); newtestEntityDef.addAttribute(attrSourceCode); newtestEntityDef.addAttribute(attrCost); newtestEntityDef.addAttribute(attrDiskUsage); newtestEntityDef.addAttribute(attrisStoreUse); populateSystemAttributes(newtestEntityDef); return newtestEntityDef; }
public AtlasAttributeDef(String name, String typeName, boolean isOptional, Cardinality cardinality, int valuesMinCount, int valuesMaxCount, boolean isUnique, boolean isIndexable, boolean includeInNotification, String defaultValue, List<AtlasConstraintDef> constraints, String description) { setName(name); setTypeName(typeName); setIsOptional(isOptional); setCardinality(cardinality); setValuesMinCount(valuesMinCount); setValuesMaxCount(valuesMaxCount); setIsUnique(isUnique); setIsIndexable(isIndexable); setIncludeInNotification(includeInNotification); setDefaultValue(defaultValue); setConstraints(constraints); setDescription(description); }
public AtlasAttributeDef(AtlasAttributeDef other) { if (other != null) { setName(other.getName()); setTypeName(other.getTypeName()); setIsOptional(other.getIsOptional()); setCardinality(other.getCardinality()); setValuesMinCount(other.getValuesMinCount()); setValuesMaxCount(other.getValuesMaxCount()); setIsUnique(other.getIsUnique()); setIsIndexable(other.getIsIndexable()); setIncludeInNotification(other.getIncludeInNotification()); setDefaultValue(other.getDefaultValue()); setConstraints(other.getConstraints()); setDescription((other.getDescription())); } }
public AtlasAttributeDef(String name, String typeName, boolean isOptional, Cardinality cardinality, int valuesMinCount, int valuesMaxCount, boolean isUnique, boolean isIndexable, String defaultValue, List<AtlasConstraintDef> constraints) { setName(name); setTypeName(typeName); setIsOptional(isOptional); setCardinality(cardinality); setValuesMinCount(valuesMinCount); setValuesMaxCount(valuesMaxCount); setIsUnique(isUnique); setIsIndexable(isIndexable); setDefaultValue(defaultValue); setConstraints(constraints); }
public AtlasAttributeDef(AtlasAttributeDef other) { if (other != null) { setName(other.getName()); setTypeName(other.getTypeName()); setIsOptional(other.getIsOptional()); setCardinality(other.getCardinality()); setValuesMinCount(other.getValuesMinCount()); setValuesMaxCount(other.getValuesMaxCount()); setIsUnique(other.getIsUnique()); setIsIndexable(other.getIsIndexable()); setDefaultValue(other.getDefaultValue()); setConstraints(other.getConstraints()); } }