Class InvalidSubjectErrorBuilder

java.lang.Object
com.commercetools.api.models.error.InvalidSubjectErrorBuilder
All Implemented Interfaces:
Builder<InvalidSubjectError>

public class InvalidSubjectErrorBuilder extends Object implements Builder<InvalidSubjectError>
InvalidSubjectErrorBuilder
Example to create an instance using the builder pattern

     InvalidSubjectError invalidSubjectError = InvalidSubjectError.builder()
             .message("{message}")
             .build()
 
  • Constructor Details

    • InvalidSubjectErrorBuilder

      public InvalidSubjectErrorBuilder()
  • Method Details

    • message

      public InvalidSubjectErrorBuilder message(String message)

      Plain text description of the cause of the error.

      Parameters:
      message - value to be set
      Returns:
      Builder
    • values

      public InvalidSubjectErrorBuilder values(Map<String,Object> values)

      Error-specific additional fields.

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

      public InvalidSubjectErrorBuilder addValue(String key, Object value)

      Error-specific additional fields.

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

      public String getMessage()

      Plain text description of the cause of the error.

      Returns:
      message
    • getValues

      public Map<String,Object> getValues()

      Error-specific additional fields.

      Returns:
      pattern properties
    • build

      public InvalidSubjectError build()
      builds InvalidSubjectError with checking for non-null required values
      Specified by:
      build in interface Builder<InvalidSubjectError>
      Returns:
      InvalidSubjectError
    • buildUnchecked

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

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

      public static InvalidSubjectErrorBuilder of(InvalidSubjectError template)
      create builder for InvalidSubjectError instance
      Parameters:
      template - instance with prefilled values for the builder
      Returns:
      builder