Class ErrorContainer

  • All Implemented Interfaces:
    adams.core.CloneHandler<adams.flow.container.Container>, adams.core.GlobalInfoSupporter,, adams.flow.container.Container, Serializable

    public class ErrorContainer
    extends adams.flow.container.AbstractContainer
    Container to send in case of errors.
    fracpete (fracpete at waikato dot ac dot nz)
    See Also:
    Serialized Form
    • Field Summary

      Modifier and Type Field Description
      static String VALUE_ERROR
      the key for the error message.
      static String VALUE_PAYLOAD
      the key for the payload.
      static String VALUE_SOURCE
      the key for the origin.
      • Fields inherited from class adams.flow.container.AbstractContainer

        m_AdditionalNames, m_Help, m_Values
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      protected void initHelp()
      Initializes the help strings.
      boolean isValid()
      Checks whether the setup of the container is valid.
      Iterator<String> names()
      Returns all value names that can be used (theoretically).
      • Methods inherited from class adams.flow.container.AbstractContainer

        addAdditionalName, addHelp, addHelp, addHelp, checkDefaultConstructor, getClone, getHelp, getValue, getValue, globalInfo, hasHelp, hasValue, isValidName, removeAdditionalName, setValue, store, stored, toSpreadSheet, toString
    • Constructor Detail

      • ErrorContainer

        public ErrorContainer()
        Initializes the container.
      • ErrorContainer

        public ErrorContainer​(Object payload,
                              String error,
                              String source)
        Initializes the container.
        payload - the token's payload to forward
        error - the associated error
        source - the source of the error
    • Method Detail

      • initHelp

        protected void initHelp()
        Initializes the help strings.
        initHelp in class adams.flow.container.AbstractContainer
      • names

        public Iterator<String> names()
        Returns all value names that can be used (theoretically).
        Specified by:
        names in interface adams.flow.container.Container
        Specified by:
        names in class adams.flow.container.AbstractContainer
        iterator over all possible value names
      • isValid

        public boolean isValid()
        Checks whether the setup of the container is valid.
        Specified by:
        isValid in interface adams.flow.container.Container
        Specified by:
        isValid in class adams.flow.container.AbstractContainer
        true if all the necessary values are available