Follow Techotopia on Twitter

On-line Guides
All Guides
eBook Store
iOS / Android
Linux for Beginners
Office Productivity
Linux Installation
Linux Security
Linux Utilities
Linux Virtualization
Linux Kernel
System/Network Admin
Programming
Scripting Languages
Development Tools
Web Development
GUI Toolkits/Desktop
Databases
Mail Systems
openSolaris
Eclipse Documentation
Techotopia.com
Virtuatopia.com

How To Guides
Virtualization
General System Admin
Linux Security
Linux Filesystems
Web Servers
Graphics & Desktop
PC Hardware
Windows
Problem Solutions
Privacy Policy

  




 

 


Eclipse Platform
Release 3.5

org.eclipse.core.runtime
Class MultiStatus

java.lang.Object
  extended by 

org.eclipse.core.runtime.Status
      extended by 
org.eclipse.core.runtime.MultiStatus
All Implemented Interfaces:
IStatus

public class MultiStatus
extends Status

A concrete multi-status implementation, suitable either for instantiating or subclassing.

This class can be used without OSGi running.


Field Summary
 
Fields inherited from class org.eclipse.core.runtime. Status
CANCEL_STATUS, OK_STATUS
 
Fields inherited from interface org.eclipse.core.runtime. IStatus
CANCEL, ERROR, INFO, OK, WARNING
 
Constructor Summary
MultiStatus ( String pluginId, int code, IStatus[] newChildren, String message, Throwable exception)
          Creates and returns a new multi-status object with the given children.
MultiStatus ( String pluginId, int code, String message, Throwable exception)
          Creates and returns a new multi-status object with no children.
 
Method Summary
 void add ( IStatus status)
          Adds the given status to this multi-status.
 void addAll ( IStatus status)
          Adds all of the children of the given status to this multi-status.
  IStatus[] getChildren ()
          Returns a list of status object immediately contained in this multi-status, or an empty list if this is not a multi-status.
 boolean isMultiStatus ()
          Returns whether this status is a multi-status.
 void merge ( IStatus status)
          Merges the given status into this multi-status.
  String toString ()
          Returns a string representation of the status, suitable for debugging purposes only.
 
Methods inherited from class org.eclipse.core.runtime. Status
getCode, getException, getMessage, getPlugin, getSeverity, isOK, matches, setCode, setException, setMessage, setPlugin, setSeverity
 
Methods inherited from class java.lang. Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

MultiStatus

public MultiStatus(
String pluginId,
                   int code,
                   
IStatus[] newChildren,
                   
String message,
                   
Throwable exception)
Creates and returns a new multi-status object with the given children.

Parameters:
pluginId - the unique identifier of the relevant plug-in
code - the plug-in-specific status code
newChildren - the list of children status objects
message - a human-readable message, localized to the current locale
exception - a low-level exception, or null if not applicable

MultiStatus

public MultiStatus(
String pluginId,
                   int code,
                   
String message,
                   
Throwable exception)
Creates and returns a new multi-status object with no children.

Parameters:
pluginId - the unique identifier of the relevant plug-in
code - the plug-in-specific status code
message - a human-readable message, localized to the current locale
exception - a low-level exception, or null if not applicable
Method Detail

add

public void add(
IStatus status)
Adds the given status to this multi-status.

Parameters:
status - the new child status

addAll

public void addAll(
IStatus status)
Adds all of the children of the given status to this multi-status. Does nothing if the given status has no children (which includes the case where it is not a multi-status).

Parameters:
status - the status whose children are to be added to this one

getChildren

public 
IStatus[] getChildren()
Description copied from interface: IStatus
Returns a list of status object immediately contained in this multi-status, or an empty list if this is not a multi-status.

Specified by:
getChildren in interface IStatus
Overrides:
getChildren in class Status
Returns:
an array of status objects
See Also:
IStatus.isMultiStatus()

isMultiStatus

public boolean isMultiStatus()
Description copied from interface: IStatus
Returns whether this status is a multi-status. A multi-status describes the outcome of an operation involving multiple operands.

The severity of a multi-status is derived from the severities of its children; a multi-status with no children is OK by definition. A multi-status carries a plug-in identifier, a status code, a message, and an optional exception. Clients may treat multi-status objects in a multi-status unaware way.

Specified by:
isMultiStatus in interface IStatus
Overrides:
isMultiStatus in class Status
Returns:
true for a multi-status, false otherwise
See Also:
IStatus.getChildren()

merge

public void merge(
IStatus status)
Merges the given status into this multi-status. Equivalent to add(status) if the given status is not a multi-status. Equivalent to addAll(status) if the given status is a multi-status.

Parameters:
status - the status to merge into this one
See Also:
add(IStatus), addAll(IStatus)

toString

public 
String toString()
Returns a string representation of the status, suitable for debugging purposes only.

Overrides:
toString in class Status

Eclipse Platform
Release 3.5

Guidelines for using Eclipse APIs.

Copyright (c) Eclipse contributors and others 2000, 2008. All rights reserved.


 
 
  Published under the terms of the Eclipse Public License Version 1.0 ("EPL") Design by Interspire