Class GraphQLInvalidFieldErrorBuilder

java.lang.Object
com.commercetools.api.models.error.GraphQLInvalidFieldErrorBuilder
All Implemented Interfaces:
io.vrap.rmf.base.client.Builder<GraphQLInvalidFieldError>

public class GraphQLInvalidFieldErrorBuilder extends Object implements io.vrap.rmf.base.client.Builder<GraphQLInvalidFieldError>
GraphQLInvalidFieldErrorBuilder
Example to create an instance using the builder pattern

     GraphQLInvalidFieldError graphQLInvalidFieldError = GraphQLInvalidFieldError.builder()
             .field("{field}")
             .build()
 
  • Constructor Details

    • GraphQLInvalidFieldErrorBuilder

      public GraphQLInvalidFieldErrorBuilder()
  • Method Details

    • values

      Error-specific additional fields.

      Parameters:
      values - properties to be set
      Returns:
      Builder
    • addValue

      public GraphQLInvalidFieldErrorBuilder addValue(String key, Object value)

      Error-specific additional fields.

      Parameters:
      key - property name
      value - property value
      Returns:
      Builder
    • field

      Name of the field with the invalid value.

      Parameters:
      field - value to be set
      Returns:
      Builder
    • invalidValue

      public GraphQLInvalidFieldErrorBuilder invalidValue(Object invalidValue)

      Value invalid for the field.

      Parameters:
      invalidValue - value to be set
      Returns:
      Builder
    • allowedValues

      public GraphQLInvalidFieldErrorBuilder allowedValues(@Nullable Object... allowedValues)

      Fixed set of allowed values for the field, if any.

      Parameters:
      allowedValues - value to be set
      Returns:
      Builder
    • allowedValues

      public GraphQLInvalidFieldErrorBuilder allowedValues(@Nullable List<Object> allowedValues)

      Fixed set of allowed values for the field, if any.

      Parameters:
      allowedValues - value to be set
      Returns:
      Builder
    • plusAllowedValues

      public GraphQLInvalidFieldErrorBuilder plusAllowedValues(@Nullable Object... allowedValues)

      Fixed set of allowed values for the field, if any.

      Parameters:
      allowedValues - value to be set
      Returns:
      Builder
    • getValues

      public Map<String,Object> getValues()

      Error-specific additional fields.

      Returns:
      pattern properties
    • getField

      public String getField()

      Name of the field with the invalid value.

      Returns:
      field
    • getInvalidValue

      public Object getInvalidValue()

      Value invalid for the field.

      Returns:
      invalidValue
    • getAllowedValues

      @Nullable public List<Object> getAllowedValues()

      Fixed set of allowed values for the field, if any.

      Returns:
      allowedValues
    • build

      public GraphQLInvalidFieldError build()
      builds GraphQLInvalidFieldError with checking for non-null required values
      Specified by:
      build in interface io.vrap.rmf.base.client.Builder<GraphQLInvalidFieldError>
      Returns:
      GraphQLInvalidFieldError
    • buildUnchecked

      public GraphQLInvalidFieldError buildUnchecked()
      builds GraphQLInvalidFieldError without checking for non-null required values
      Returns:
      GraphQLInvalidFieldError
    • of

      public static GraphQLInvalidFieldErrorBuilder of()
      factory method for an instance of GraphQLInvalidFieldErrorBuilder
      Returns:
      builder
    • of

      create builder for GraphQLInvalidFieldError instance
      Parameters:
      template - instance with prefilled values for the builder
      Returns:
      builder