Record Class ProcedureRunner.Outcome

java.lang.Object
java.lang.Record
com.axelor.ai.procedure.ProcedureRunner.Outcome
Record Components:
status - how it ended: DONE, or why it stopped
message - the error, refusal or declined alert, when it stopped
id - the record's id at the end, null for a new record never saved
saved - whether the record was saved during the run
changes - the fields whose values differ from those loaded, with their values now: once saved, as the database holds them
previous - the same fields, with their values as loaded
unsaved - after a save, the fields whose values the run holds but did not save, with those values: a later step changed them and no save followed, or the save failed
result - everything the browser would have shown, from the last step run
messages - the messages of every step, in order
writes - the records the form's actions wrote themselves, kept whether or not the run saved: what a failed run leaves behind
answers - the alerts met, and how each was answered
paused - the run to carry on once the user answers, when it stopped at a question
openForm - how the form open beside the chat was used, or null when none matched
Enclosing class:
ProcedureRunner

public static record ProcedureRunner.Outcome(FormResult.Status status, String message, Long id, boolean saved, Map<String,Object> changes, Map<String,Object> previous, Map<String,Object> unsaved, FormResult result, List<ProcedureRunner.Said> messages, List<FormResult.Write> writes, List<ProcedureRunner.Answer> answers, ProcedureRunner.Paused paused, ProcedureRunner.OpenForm openForm) extends Record
What a run did.
  • Constructor Details

  • Method Details

    • toString

      public final String toString()
      Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components.
      Specified by:
      toString in class Record
      Returns:
      a string representation of this object
    • hashCode

      public final int hashCode()
      Returns a hash code value for this object. The value is derived from the hash code of each of the record components.
      Specified by:
      hashCode in class Record
      Returns:
      a hash code value for this object
    • equals

      public final boolean equals(Object o)
      Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. Reference components are compared with Objects::equals(Object,Object); primitive components are compared with '=='.
      Specified by:
      equals in class Record
      Parameters:
      o - the object with which to compare
      Returns:
      true if this object is the same as the o argument; false otherwise.
    • status

      public FormResult.Status status()
      Returns the value of the status record component.
      Returns:
      the value of the status record component
    • message

      public String message()
      Returns the value of the message record component.
      Returns:
      the value of the message record component
    • id

      public Long id()
      Returns the value of the id record component.
      Returns:
      the value of the id record component
    • saved

      public boolean saved()
      Returns the value of the saved record component.
      Returns:
      the value of the saved record component
    • changes

      public Map<String,Object> changes()
      Returns the value of the changes record component.
      Returns:
      the value of the changes record component
    • previous

      public Map<String,Object> previous()
      Returns the value of the previous record component.
      Returns:
      the value of the previous record component
    • unsaved

      public Map<String,Object> unsaved()
      Returns the value of the unsaved record component.
      Returns:
      the value of the unsaved record component
    • result

      public FormResult result()
      Returns the value of the result record component.
      Returns:
      the value of the result record component
    • messages

      public List<ProcedureRunner.Said> messages()
      Returns the value of the messages record component.
      Returns:
      the value of the messages record component
    • writes

      public List<FormResult.Write> writes()
      Returns the value of the writes record component.
      Returns:
      the value of the writes record component
    • answers

      public List<ProcedureRunner.Answer> answers()
      Returns the value of the answers record component.
      Returns:
      the value of the answers record component
    • paused

      public ProcedureRunner.Paused paused()
      Returns the value of the paused record component.
      Returns:
      the value of the paused record component
    • openForm

      public ProcedureRunner.OpenForm openForm()
      Returns the value of the openForm record component.
      Returns:
      the value of the openForm record component