Package dk.mada.jaxrs.model.types
Class TypeByteArray
java.lang.Object
dk.mada.jaxrs.model.types.TypeByteArray
- All Implemented Interfaces:
Type
Special type for handing byte[] type.
In resources this would be treated as a stream, while it it treated as an array in DTOs.
-
Method Summary
Modifier and TypeMethodDescriptionstatic TypeByteArray
getArray()
Returns the byte-array instance.static TypeByteArray
Returns the stream instance.boolean
isArray()
Returns true if this is the byte-array instance, otherwise false.boolean
isStream()
Returns true if this is the stream instance, otherwise false.Returns the set of imports needed to use this type in a DTO.toString()
typeName()
Returns the type name.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface dk.mada.jaxrs.model.types.Type
isBigDecimal, isContainer, isDate, isDateTime, isDto, isEnum, isPlainObject, isPrimitive, isPrimitive, isTime, isUUID, isValidation, isVoid, wrapperTypeName
-
Method Details
-
getArray
Returns the byte-array instance.- Returns:
- the byte-array instance
-
getStream
Returns the stream instance.- Returns:
- the stream instance
-
isStream
public boolean isStream()Returns true if this is the stream instance, otherwise false.- Returns:
- true if this is the stream instance, otherwise false
-
isArray
public boolean isArray()Returns true if this is the byte-array instance, otherwise false.- Returns:
- true if this is the byte-array instance, otherwise false
-
typeName
Description copied from interface:Type
Returns the type name. -
toString
-
neededImports
Description copied from interface:Type
Returns the set of imports needed to use this type in a DTO.- Specified by:
neededImports
in interfaceType
- Returns:
- the set of imports needed to use this type in a DTO
-