Interface Problem

    • Method Detail

      • getSeverity

        Problem.Severity getSeverity()
        Returns the severity of the problem. Current supported types are INFORMATION, WARNING, and ERROR.
      • getType

        ProblemType getType()
        Returns the type of the problem.
      • getInspector

        Inspector getInspector()
        Returns the inspector that created this problem.
      • getLine

        int getLine()
        Returns the line in the orders of the unit that caused the problem. The first order is line 1!
        The line that is the cause of the order or -1 if no single line can be made responsible
      • getObject

        java.lang.Object getObject()
        Returns the object this problem criticizes.
      • getFaction

        Faction getFaction()
        Returns the faction this problem belongs to.
        The faction this problem belongs to or null if not applicable
      • getRegion

        Region getRegion()
        Returns the value of region.
        Returns region.
      • getOwner

        Unit getOwner()
        Returns a unit responsible for this problem.
        Returns owner.
      • getMessage

        java.lang.String getMessage()
        Returns a message for the user.
        Returns message.
      • addSuppressComment

        Unit addSuppressComment()
        Modifies the orders such that this problem is not listed by the inspector in the future, i.e. by adding a comment to the source unit's orders. Note that it is in the responsibility of the caller to fire OrderChangedEvents.
        Returns a Unit whose orders were changed to suppress this warning or null if no orders were changed
      • toString

        java.lang.String toString()
        Implementations should usually also overwrite this.
        toString in class java.lang.Object