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. An error hit maintains a main error - the main error of the result.
Author:
bratseth
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    Adds an error to this.
    void
    addErrors(ErrorHit errorHit)
    Add all errors from another error hit to this
     
    Returns all the detail errors of this error hit, including the main error
    Returns a read-only set containing all the error of this, including the main error
    boolean
    hasOnlyErrorCode(int code)
    Returns true if all errors in this has the given error code
    boolean
    Returns true - this is a meta hit containing information on other hits
    void
    setSource(String source)
     
  • Method Details

    • 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
    • clone

      Object clone()