ilog.rules.brl

Class IlrBRLMarker

  • java.lang.Object
    • ilog.rules.brl.IlrBRLMarker


  • public class IlrBRLMarker
    extends java.lang.Object
    Represents a business rule language marker. Markers are issued by the business rule language parser when parsing the definition of a rule. A business rule language marker reports an error or a warning that can be lexical, syntactic or semantic. The business rule language marker is associated with a business rule language marker descriptor which gives information about the kind and severity of errors.
    • Method Summary

      Methods 
      Modifier and Type Method and Description
      IlrBRLMarkerFixProposal[] computeFixProposals()
      Returns the possible proposals according to this marker, if this marker can be fixed.
      IlrBRLMarkerDescriptor getDescriptor()
      Returns the marker descriptor associated to this business rule language marker.
      IlrBRLMarker getErrorContext()
      Returns the error context attached to the marker.
      int getKind()
      Returns the kind of this marker.
      int getLength()
      Returns the length of the marker in the parsed definition.
      int getLineNumber(java.lang.String originalText)
      Gets the line number at which the error occurred.
      java.lang.String getMessage()
      Returns a localized message about this marker.
      int getOffset()
      Returns the offset of the marker in the parsed definition.
      int getSeverity()
      Returns the severity of this marker.
      boolean hasErrorContext()
      Returns true if the marker has an error context.
      boolean isError()
      States whether the marker reports an error.
      boolean isFixable()
      Returns true if this marker can be fixed automatically.
      boolean isInfo()
      States whether the marker reports an info.
      boolean isLexical()
      States whether the marker reports a lexical error.
      boolean isSemantic()
      States whether the marker reports a semantic error.
      boolean isSyntactic()
      States whether the marker reports a syntactic error.
      boolean isWarning()
      States whether the marker reports a warning.
      void setErrorContext(IlrBRLMarker errorContext)
      Sets the error context of the marker.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Method Detail

      • getDescriptor

        public IlrBRLMarkerDescriptor getDescriptor()
        Returns the marker descriptor associated to this business rule language marker.
        Returns:
        The marker descriptor.
      • isLexical

        public boolean isLexical()
        States whether the marker reports a lexical error.
        Returns:
        true if the marker reports a lexical error
      • isSyntactic

        public boolean isSyntactic()
        States whether the marker reports a syntactic error.
        Returns:
        true if the marker reports a syntactic error.
      • isSemantic

        public boolean isSemantic()
        States whether the marker reports a semantic error.
        Returns:
        true if the marker reports a semantic error.
      • isError

        public boolean isError()
        States whether the marker reports an error.
        Returns:
        true if the marker reports an error.
      • isWarning

        public boolean isWarning()
        States whether the marker reports a warning.
        Returns:
        true if the marker reports a warning.
      • isInfo

        public boolean isInfo()
        States whether the marker reports an info.
        Returns:
        true if the marker reports an info.
      • isFixable

        public boolean isFixable()
        Returns true if this marker can be fixed automatically.
        Returns:
        true if this marker can be fixed automatically.
        See Also:
        IlrBRLMarkerDescriptor.isFixable()
      • getOffset

        public int getOffset()
        Returns the offset of the marker in the parsed definition.
        Returns:
        The offset of the marker in the parsed definition.
      • getLength

        public int getLength()
        Returns the length of the marker in the parsed definition.
        Returns:
        The length of the marker in the parsed definition.
      • getMessage

        public java.lang.String getMessage()
        Returns a localized message about this marker.
        Returns:
        A localized message about this marker.
      • getErrorContext

        public IlrBRLMarker getErrorContext()
        Returns the error context attached to the marker. The error context can be null.
        Returns:
        The error context attached to the marker.
      • hasErrorContext

        public boolean hasErrorContext()
        Returns true if the marker has an error context.
        Returns:
        true if the marker has an error context.
      • setErrorContext

        public void setErrorContext(IlrBRLMarker errorContext)
        Sets the error context of the marker.
        Parameters:
        errorContext - The error context to attach to the marker.
      • getLineNumber

        public int getLineNumber(java.lang.String originalText)
        Gets the line number at which the error occurred.
        Parameters:
        originalText - the text this error is originated.

© Copyright IBM Corp. 1987, 2017