Class InputParser

java.lang.Object
no.sikt.graphitron.generators.context.InputParser

public class InputParser extends Object
A helper class for handling input type data for services and mutations.
  • Constructor Details

  • Method Details

    • getMethodInputs

      public Map<String,InputField> getMethodInputs()
      Returns:
      Map of inputs that the field specifies.
    • getMethodInputsWithOrderField

      public Map<String,InputField> getMethodInputsWithOrderField()
      Returns:
      Map of inputs that the field specifies.
    • getRecords

      public Map<String,InputField> getRecords()
      Returns:
      Map of inputs that the field specifies that correspond to any records.
    • getJOOQRecords

      public Map<String,InputField> getJOOQRecords()
      Returns:
      Map of inputs that the field specifies that correspond to jOOQ records.
    • hasRecords

      public boolean hasRecords()
      Returns:
      Are there any records among the inputs?
    • hasJOOQRecords

      public boolean hasJOOQRecords()
      Returns:
      Are there any jOOQ records among the inputs?.
    • getInputParamString

      public String getInputParamString()
      Returns:
      The inputs this service will require formatted as a comma separated string.
    • getAllErrors

      public List<ObjectField> getAllErrors()
      Returns:
      List of all error types this operation has specified in the schema.
    • getValidationErrorException

      public Optional<ExceptionDefinition> getValidationErrorException()
      Returns:
      ExceptionDefinition used for validation errors. If it's configured and present in the schema as a returnable error for this operation.