Interface CustomFields


public interface CustomFields
CustomFields
Example to create an instance using the builder pattern

     CustomFields customFields = CustomFields.builder()
             .type(typeBuilder -> typeBuilder)
             .fields(fieldsBuilder -> fieldsBuilder)
             .build()
 
  • Method Details

    • getType

      @NotNull @Valid @NotNull @Valid Reference getType()
      Returns:
      type
    • getFields

      @NotNull @Valid @NotNull @Valid Object getFields()

      A valid JSON object, based on FieldDefinition.

      Returns:
      fields
    • setType

      void setType(Reference type)
      set type
      Parameters:
      type - value to be set
    • setFields

      void setFields(Object fields)

      A valid JSON object, based on FieldDefinition.

      Parameters:
      fields - value to be set
    • of

      static CustomFields of()
      factory method
      Returns:
      instance of CustomFields
    • of

      static CustomFields of(CustomFields template)
      factory method to create a shallow copy CustomFields
      Parameters:
      template - instance to be copied
      Returns:
      copy instance
    • deepCopy

      @Nullable static CustomFields deepCopy(@Nullable CustomFields template)
      factory method to create a deep copy of CustomFields
      Parameters:
      template - instance to be copied
      Returns:
      copy instance
    • builder

      static CustomFieldsBuilder builder()
      builder factory method for CustomFields
      Returns:
      builder
    • builder

      static CustomFieldsBuilder builder(CustomFields template)
      create builder for CustomFields instance
      Parameters:
      template - instance with prefilled values for the builder
      Returns:
      builder
    • withCustomFields

      default <T> T withCustomFields(Function<CustomFields,T> helper)
      accessor map function
      Type Parameters:
      T - mapped type
      Parameters:
      helper - function to map the object
      Returns:
      mapped value
    • typeReference

      static com.fasterxml.jackson.core.type.TypeReference<CustomFields> typeReference()
      gives a TypeReference for usage with Jackson DataBind
      Returns:
      TypeReference