Class TypeDescription
- java.lang.Object
-
- de.fraunhofer.iese.mydata.common.MyDataEntity
-
- de.fraunhofer.iese.mydata.component.information.method.TypeDescription
-
@Entity public class TypeDescription extends MyDataEntity
Describes a JSON Type
-
-
Field Summary
Fields Modifier and Type Field Description static String
SPECIAL_FIELD_FOR_CONTENT_INFORMATION
-
Constructor Summary
Constructors Constructor Description TypeDescription()
basic constructor needed for JPA
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addTypeNameForField(String fieldName, String typeName)
Adds the fields.Set<String>
getFieldNames()
Optional<Class<?>>
getTypeClass()
Optional<TypeDescription>
getTypeDescriptionForField(String fieldName)
Optional<String>
getTypeNameForField(String fieldName)
boolean
hasField(String fieldName)
-
Methods inherited from class de.fraunhofer.iese.mydata.common.MyDataEntity
fromJson, getGson, getGson, toJson, toString, validate, validateAndNullCheck
-
-
-
-
Field Detail
-
SPECIAL_FIELD_FOR_CONTENT_INFORMATION
public static final String SPECIAL_FIELD_FOR_CONTENT_INFORMATION
- See Also:
- Constant Field Values
-
-
Method Detail
-
addTypeNameForField
public void addTypeNameForField(String fieldName, String typeName)
Adds the fields.- Parameters:
fieldName
- the keytypeName
- the value
-
hasField
public boolean hasField(String fieldName)
- Parameters:
fieldName
-- Returns:
- true if there is such a field name
-
getTypeDescriptionForField
public Optional<TypeDescription> getTypeDescriptionForField(String fieldName)
- Parameters:
fieldName
-- Returns:
- the TypeDescription corresponding to a field name
-
-