Interface GenericError

All Superinterfaces:
ErrorObject

public interface GenericError extends ErrorObject
GenericError
Example to create an instance using the builder pattern

     GenericError genericError = GenericError.builder()
             .message("{message}")
             .build()
 
  • Field Details

  • Method Details

    • of

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

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

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

      static GenericErrorBuilder builder()
      builder factory method for GenericError
      Returns:
      builder
    • builder

      static GenericErrorBuilder builder(GenericError template)
      create builder for GenericError instance
      Parameters:
      template - instance with prefilled values for the builder
      Returns:
      builder
    • withGenericError

      default <T> T withGenericError(Function<GenericError,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<GenericError> typeReference()
      gives a TypeReference for usage with Jackson DataBind
      Returns:
      TypeReference