Class JavaModelStatus

java.lang.Object
org.eclipse.core.runtime.Status
org.aspectj.org.eclipse.jdt.internal.core.JavaModelStatus
All Implemented Interfaces:
IJavaModelStatus, IJavaModelStatusConstants, org.eclipse.core.runtime.IStatus

public class JavaModelStatus extends org.eclipse.core.runtime.Status implements IJavaModelStatus, IJavaModelStatusConstants
See Also:
IJavaModelStatus
  • Field Details

    • elements

      protected IJavaElement[] elements
      The elements related to the failure, or null if no elements are involved.
    • path

      protected org.eclipse.core.runtime.IPath path
      The path related to the failure, or null if no path is involved.
    • string

      protected String string
      The String related to the failure, or null if no String is involved.
    • NO_CHILDREN

      protected static final org.eclipse.core.runtime.IStatus[] NO_CHILDREN
      Empty children
    • children

      protected org.eclipse.core.runtime.IStatus[] children
    • VERIFIED_OK

      public static final IJavaModelStatus VERIFIED_OK
      Singleton OK object
  • Constructor Details

    • JavaModelStatus

      public JavaModelStatus()
      Constructs an Java model status with no corresponding elements.
    • JavaModelStatus

      public JavaModelStatus(int code)
      Constructs an Java model status with no corresponding elements.
    • JavaModelStatus

      public JavaModelStatus(int code, IJavaElement[] elements)
      Constructs an Java model status with the given corresponding elements.
    • JavaModelStatus

      public JavaModelStatus(int code, String string)
      Constructs an Java model status with no corresponding elements.
    • JavaModelStatus

      public JavaModelStatus(int severity, int code, String string)
      Constructs an Java model status with no corresponding elements.
    • JavaModelStatus

      public JavaModelStatus(int code, Throwable throwable)
      Constructs an Java model status with no corresponding elements.
    • JavaModelStatus

      public JavaModelStatus(int code, org.eclipse.core.runtime.IPath path)
      Constructs an Java model status with no corresponding elements.
    • JavaModelStatus

      public JavaModelStatus(int code, IJavaElement element)
      Constructs an Java model status with the given corresponding element.
    • JavaModelStatus

      public JavaModelStatus(int code, IJavaElement element, String string)
      Constructs an Java model status with the given corresponding element and string
    • JavaModelStatus

      public JavaModelStatus(int code, IJavaElement element, org.eclipse.core.runtime.IPath path)
      Constructs an Java model status with the given corresponding element and path
    • JavaModelStatus

      public JavaModelStatus(int code, IJavaElement element, org.eclipse.core.runtime.IPath path, String string)
      Constructs an Java model status with the given corresponding element, path and string
    • JavaModelStatus

      public JavaModelStatus(int severity, int code, IJavaElement element, org.eclipse.core.runtime.IPath path, String msg)
      Constructs an Java model status with the given corresponding element and path
    • JavaModelStatus

      public JavaModelStatus(org.eclipse.core.runtime.CoreException coreException)
      Constructs an Java model status with no corresponding elements.
  • Method Details

    • getBits

      protected int getBits()
    • getChildren

      public org.eclipse.core.runtime.IStatus[] getChildren()
      Specified by:
      getChildren in interface org.eclipse.core.runtime.IStatus
      Overrides:
      getChildren in class org.eclipse.core.runtime.Status
      See Also:
      IStatus
    • getElements

      public IJavaElement[] getElements()
      Description copied from interface: IJavaModelStatus
      Returns any Java elements associated with the failure (see specification of the status code), or an empty array if no elements are related to this particular status code.
      Specified by:
      getElements in interface IJavaModelStatus
      Returns:
      the list of Java element culprits
      See Also:
      IJavaModelStatus
    • getMessage

      public String getMessage()
      Returns the message that is relevant to the code of this status.
      Specified by:
      getMessage in interface org.eclipse.core.runtime.IStatus
      Overrides:
      getMessage in class org.eclipse.core.runtime.Status
    • getPath

      public org.eclipse.core.runtime.IPath getPath()
      Description copied from interface: IJavaModelStatus
      Returns the path associated with the failure (see specification of the status code), or null if the failure is not one of DEVICE_PATH, INVALID_PATH, PATH_OUTSIDE_PROJECT, or RELATIVE_PATH.
      Specified by:
      getPath in interface IJavaModelStatus
      Returns:
      the path that caused the failure, or null if none
      See Also:
      IJavaModelStatus.getPath()
    • getSeverity

      public int getSeverity()
      Specified by:
      getSeverity in interface org.eclipse.core.runtime.IStatus
      Overrides:
      getSeverity in class org.eclipse.core.runtime.Status
      See Also:
      IStatus.getSeverity()
    • getString

      public String getString()
      Deprecated.
      Description copied from interface: IJavaModelStatus
      Returns the string associated with the failure (see specification of the status code), or null if no string is related to this particular status code.
      Specified by:
      getString in interface IJavaModelStatus
      Returns:
      the string culprit, or null if none
      See Also:
      IJavaModelStatus.getString()
    • isDoesNotExist

      public boolean isDoesNotExist()
      Description copied from interface: IJavaModelStatus
      Returns whether this status indicates that a Java model element does not exist. This convenience method is equivalent to getCode() == IJavaModelStatusConstants.ELEMENT_DOES_NOT_EXIST.
      Specified by:
      isDoesNotExist in interface IJavaModelStatus
      Returns:
      true if the status code indicates that a Java model element does not exist
      See Also:
      IJavaModelStatus.isDoesNotExist()
    • isMultiStatus

      public boolean isMultiStatus()
      Specified by:
      isMultiStatus in interface org.eclipse.core.runtime.IStatus
      Overrides:
      isMultiStatus in class org.eclipse.core.runtime.Status
      See Also:
      IStatus.isMultiStatus()
    • isOK

      public boolean isOK()
      Specified by:
      isOK in interface org.eclipse.core.runtime.IStatus
      Overrides:
      isOK in class org.eclipse.core.runtime.Status
      See Also:
      IStatus.isOK()
    • matches

      public boolean matches(int mask)
      Specified by:
      matches in interface org.eclipse.core.runtime.IStatus
      Overrides:
      matches in class org.eclipse.core.runtime.Status
      See Also:
      IStatus.matches(int)
    • matches

      protected boolean matches(JavaModelStatus status, int mask)
      Helper for matches(int).
    • newMultiStatus

      public static IJavaModelStatus newMultiStatus(IJavaModelStatus[] children)
      Creates and returns a new IJavaModelStatus that is a a multi-status status.
      See Also:
      IStatus.isMultiStatus()
    • toString

      public String toString()
      Returns a printable representation of this exception for debugging purposes.
      Overrides:
      toString in class org.eclipse.core.runtime.Status