Interface ErrorHit

  • All Superinterfaces:
    Cloneable
    All Known Implementing Classes:
    DefaultErrorHit

    public interface ErrorHit
    extends Cloneable
    A hit which holds information on error conditions in a result. En error hit maintains a main error - the main error of the result.
    Author:
    bratseth
    • Method Detail

      • setSource

        void setSource​(String source)
      • addError

        void addError​(ErrorMessage error)
        Adds an error to this. This may change the main error and/or the list of detailed errors
      • addErrors

        void addErrors​(ErrorHit errorHit)
        Add all errors from another error hit to this
      • errorIterator

        Iterator<? extends ErrorMessage> errorIterator()
        Returns all the detail errors of this error hit, including the main error
      • errors

        Set<ErrorMessage> errors()
        Returns a read-only set containing all the error of this, including the main error
      • isMeta

        boolean isMeta()
        Returns true - this is a meta hit containing information on other hits
      • hasOnlyErrorCode

        boolean hasOnlyErrorCode​(int code)
        Returns true if all errors in this has the given error code