public interface CdsSimpleType extends CdsType
Modifier and Type | Method and Description |
---|---|
default void |
accept(CdsVisitor visitor)
Accepts a
CdsVisitor visiting the elements of this definition
(depth-first) |
Optional<Object> |
defaultValue()
Returns an
Optional wrapping the default value of this
CdsSimpleType . |
<T> T |
get(String property)
Returns the property for the given key.
|
Class<?> |
getJavaType()
Returns the Java type of this
CdsSimpleType definition. |
default String |
getQualifiedName()
Returns the fully qualified name of this definition.
|
CdsBaseType |
getType()
Returns the
CdsBaseType of this CdsSimpleType definition. |
default boolean |
isSimple()
Returns
true if this is a simple type. |
default boolean |
isSimpleType(CdsBaseType baseType)
Returns
true if this is a simple type with a given base type. |
isArrayed, isAssociation, isEnum, isStructured, isSymbolicType
as, byNamespace, getKey, getKind, getName, getQualifier
annotations, byAnnotation, findAnnotation, getAnnotationValue
CdsBaseType getType()
CdsBaseType
of this CdsSimpleType
definition.CdsBaseType
of this simple type definition, not
null
Class<?> getJavaType()
CdsSimpleType
definition.null
Optional<Object> defaultValue()
Optional
wrapping the default value of this
CdsSimpleType
.Optional
describing the default value of this simple type,
or an empty Optional
if there is no default value<T> T get(String property)
T
- the expected type of the propertyproperty
- the name of the propertynull
if there is no property
with the given namedefault boolean isSimple()
CdsType
true
if this is a simple type.default boolean isSimpleType(CdsBaseType baseType)
CdsType
true
if this is a simple type with a given base type.isSimpleType
in interface CdsType
baseType
- the base typetrue
if this is a simple type with a given base type,
otherwise false
default String getQualifiedName()
CdsDefinition
getQualifiedName
in interface CdsDefinition
default void accept(CdsVisitor visitor)
CdsDefinition
CdsVisitor
visiting the elements of this definition
(depth-first)accept
in interface CdsDefinition
visitor
- the CdsVisitor
Copyright © 2023 SAP. All rights reserved.