Package org.eclipse.equinox.p2.core

# Class ProvisionException

java.lang.Object
java.lang.Throwable
java.lang.Exception
org.eclipse.core.runtime.CoreException
org.eclipse.equinox.p2.core.ProvisionException

All Implemented Interfaces:
  `Serializable`

public class ProvisionException extends CoreException
A checked exception indicating a recoverable error occurred while provisioning. The status provides a further description of the problem.

Since:
  2.0
See Also:
  - Serialized Form
Restriction:
  This class is not intended to be subclassed by clients.

## Field Summary

Fields
Modifier and Type
Field
Description
`static final int`
`ARTIFACT_EXISTS`
Status code constant (value 1201) indicating an artifact unexpectedly already exists.
`static final int`
`ARTIFACT_INCOMPLETE_SIZING`
Status code constant (value 1202) indicating an artifact's size could not be found.
`static final int`
`ARTIFACT_MD5_NOT_MATCH`
Status code constant (value 1203) indicating an artifact's md5 does not match the expected value.
`static final int`
`ARTIFACT_NOT_FOUND`
Status code constant (value 1200) indicating an artifact unexpectedly does not exist.
`static final int`
`INTERNAL_ERROR`
Status code constant (value 1) for an uncategorized error.
`static final int`
`REPOSITORY_EXISTS`
Status code constant (value 1001) indicating a repository unexpectedly exists.
`static final int`
`REPOSITORY_FAILED_AUTHENTICATION`
Status code constant (value 1007) indicating that there was an authentication error while reading a repository
`static final int`
`REPOSITORY_FAILED_READ`
Status code constant (value 1002) indicating a repository could not be read
`static final int`
`REPOSITORY_FAILED_WRITE`
Status code constant (value 1003) indicating a failure occurred while writing to a repository.
`static final int`
`REPOSITORY_INVALID_LOCATION`
Status code constant (value 1006) indicating that a specified repository location is not valid.
`static final int`
`REPOSITORY_NOT_FOUND`
Status code constant (value 1000) indicating a repository unexpectedly does not exist.
`static final int`
`REPOSITORY_READ_ONLY`
Status code constant (value 1004) indicating a repository could not be written because it is a read-only repository.
`static final int`
`REPOSITORY_UNKNOWN_TYPE`
Status code constant (value 1005) indicating an attempt was made to create or access a repository of unknown type.

## Constructor Summary

Constructors
Constructor
Description
`ProvisionException(String message)`
Creates a new exception with the given message and a severity of `IStatus.ERROR`.
`ProvisionException(String message, Throwable cause)`
Creates a new exception with the given message and cause, and a severity of `IStatus.ERROR`.
`ProvisionException(IStatus status)`
Creates a new exception with the given status object.

## Method Summary

### Methods inherited from class org.eclipse.core.runtime.CoreException

`getCause, getStatus, printStackTrace, printStackTrace, printStackTrace`

### Methods inherited from class java.lang.Throwable

`addSuppressed, fillInStackTrace, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, setStackTrace, toString`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

## Field Details

### INTERNAL_ERROR

public static final int INTERNAL_ERROR
Status code constant (value 1) for an uncategorized error.

See Also:
  - Constant Field Values

### REPOSITORY_NOT_FOUND

public static final int REPOSITORY_NOT_FOUND
Status code constant (value 1000) indicating a repository unexpectedly does not exist.

See Also:
  - Constant Field Values

### REPOSITORY_EXISTS

public static final int REPOSITORY_EXISTS
Status code constant (value 1001) indicating a repository unexpectedly exists.

See Also:
  - Constant Field Values

### REPOSITORY_FAILED_READ

public static final int REPOSITORY_FAILED_READ
Status code constant (value 1002) indicating a repository could not be read

See Also:
  - Constant Field Values

### REPOSITORY_FAILED_WRITE

public static final int REPOSITORY_FAILED_WRITE
Status code constant (value 1003) indicating a failure occurred while writing to a repository.

See Also:
  - Constant Field Values

### REPOSITORY_READ_ONLY

public static final int REPOSITORY_READ_ONLY
Status code constant (value 1004) indicating a repository could not be written because it is a read-only repository.

See Also:
  - Constant Field Values

### REPOSITORY_UNKNOWN_TYPE

public static final int REPOSITORY_UNKNOWN_TYPE
Status code constant (value 1005) indicating an attempt was made to create or access a repository of unknown type.

See Also:
  - Constant Field Values

### REPOSITORY_INVALID_LOCATION

public static final int REPOSITORY_INVALID_LOCATION
Status code constant (value 1006) indicating that a specified repository location is not valid.

See Also:
  - Constant Field Values

### REPOSITORY_FAILED_AUTHENTICATION

public static final int REPOSITORY_FAILED_AUTHENTICATION
Status code constant (value 1007) indicating that there was an authentication error while reading a repository

See Also:
  - Constant Field Values

### ARTIFACT_NOT_FOUND

public static final int ARTIFACT_NOT_FOUND
Status code constant (value 1200) indicating an artifact unexpectedly does not exist.

See Also:
  - Constant Field Values

### ARTIFACT_EXISTS

public static final int ARTIFACT_EXISTS
Status code constant (value 1201) indicating an artifact unexpectedly already exists.

See Also:
  - Constant Field Values

### ARTIFACT_INCOMPLETE_SIZING

public static final int ARTIFACT_INCOMPLETE_SIZING
Status code constant (value 1202) indicating an artifact's size could not be found.

See Also:
  - Constant Field Values

### ARTIFACT_MD5_NOT_MATCH

public static final int ARTIFACT_MD5_NOT_MATCH
Status code constant (value 1203) indicating an artifact's md5 does not match the expected value.

Since:
  2.1
See Also:
  - Constant Field Values

## Constructor Details

### ProvisionException

public ProvisionException(IStatus status)
Creates a new exception with the given status object. The message of the given status is used as the exception message.

Parameters:
  `status` - the status object to be associated with this exception

### ProvisionException

public ProvisionException(String message)
Creates a new exception with the given message and a severity of `IStatus.ERROR`.

Parameters:
  `message` - The human-readable problem message

### ProvisionException

public ProvisionException(String message, Throwable cause)
Creates a new exception with the given message and cause, and a severity of `IStatus.ERROR`.

Parameters:
  `message` - The human-readable problem message
  `cause` - The underlying cause of the exception