Interface Dto

All Superinterfaces:
Type

@Immutable public interface Dto extends Type
Model of a DTO object.
  • Method Details

    • builder

      static dk.mada.jaxrs.model.ImmutableDto.Builder builder(String name, TypeName typeName)
      Returns a builder for this type.
      Parameters:
      name - the name of the DTO
      typeName - the type name of the DTO
      Returns:
      a builder for this type
    • builderFrom

      static dk.mada.jaxrs.model.ImmutableDto.Builder builderFrom(Dto other)
      Returns a builder for this type.
      Parameters:
      other - the existing DTO to create a builder from
      Returns:
      a builder for this type
    • name

      String name()
      Returns the DTO name.
      Returns:
      the DTO name
    • mpSchemaName

      String mpSchemaName()
      Returns the MP Schema name.
      Returns:
      the MP Schema name
    • reference

      Reference reference()
      Returns the type of the DTO object.
      Returns:
      the type of the DTO object
    • description

      Optional<String> description()
      Returns the optional description of the DTO.
      Returns:
      the optional description of the DTO
    • isDto

      default boolean isDto()
      Description copied from interface: Type
      Returns true if this type represents a custom type DTO.
      Specified by:
      isDto in interface Type
      Returns:
      true if this type represents a custom type DTO
    • openapiId

      TypeName openapiId()
      Returns the name the DTO was identified by in the schema.
      Returns:
      the name the DTO was identified by in the schema
    • properties

      List<Property> properties()
      Returns the properties on the DTO.
      Returns:
      the properties on the DTO
    • enumValues

      List<String> enumValues()
      Returns the optional enumeration values on the DTO.
      Returns:
      the optional enumeration values on the DTO
    • isEnum

      default boolean isEnum()
      Returns true if this is an enumeration, otherwise false.
      Specified by:
      isEnum in interface Type
      Returns:
      true if this is an enumeration, otherwise false
    • implementsInterfaces

      List<TypeInterface> implementsInterfaces()
      Returns the list of interfaces implemented by this DTO.
      Returns:
      the list of interfaces implemented by this DTO
    • subtypeSelector

      Optional<SubtypeSelector> subtypeSelector()
      Returns an optional sub-type mapping.
      Returns:
      an optional sub-type mapping
    • extendsParents

      List<Dto> extendsParents()
      Returns the parents that this DTO extends.
      Returns:
      the parents that this DTO extends
    • isMultipartForm

      boolean isMultipartForm()
      Returns true if this instance is used as a multipart form body.
      Returns:
      true if this instance is used as a multipart form body