Added in [API level 1](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels) Summary: [Ctors](https://developer.android.com/reference/java/security/cert/PKIXCertPathValidatorResult#pubctors) \| [Methods](https://developer.android.com/reference/java/security/cert/PKIXCertPathValidatorResult#pubmethods) \| [Inherited Methods](https://developer.android.com/reference/java/security/cert/PKIXCertPathValidatorResult#inhmethods)

# PKIXCertPathValidatorResult

` public class PKIXCertPathValidatorResult `   
` extends https://developer.android.com/reference/java/lang/Object ` ` implements https://developer.android.com/reference/java/security/cert/CertPathValidatorResult `

|---|---|
| [java.lang.Object](https://developer.android.com/reference/java/lang/Object) ||
| ↳ | java.security.cert.PKIXCertPathValidatorResult |

Known direct subclasses [PKIXCertPathBuilderResult](https://developer.android.com/reference/java/security/cert/PKIXCertPathBuilderResult) [PKIXCertPathBuilderResult](https://developer.android.com/reference/java/security/cert/PKIXCertPathBuilderResult) This class represents the successful result of the PKIX certification path builder algorithm.   

*** ** * ** ***

This class represents the successful result of the PKIX certification path validation algorithm.

Instances of `PKIXCertPathValidatorResult` are returned by the `https://developer.android.com/reference/java/security/cert/CertPathValidator#validate(java.security.cert.CertPath,%20java.security.cert.CertPathParameters)` method of `CertPathValidator` objects implementing the PKIX algorithm.

All `PKIXCertPathValidatorResult` objects contain the valid policy tree and subject public key resulting from the validation algorithm, as well as a `TrustAnchor` describing the certification authority (CA) that served as a trust anchor for the certification path.

**Concurrent Access**

Unless otherwise specified, the methods defined in this class are not thread-safe. Multiple threads that need to access a single object concurrently should synchronize amongst themselves and provide the necessary locking. Multiple threads each manipulating separate objects need not synchronize.
**See also:**

- `https://developer.android.com/reference/java/security/cert/CertPathValidatorResult`

## Summary

| ### Public constructors ||
|---|---|
| ` https://developer.android.com/reference/java/security/cert/PKIXCertPathValidatorResult#PKIXCertPathValidatorResult(java.security.cert.TrustAnchor,%20java.security.cert.PolicyNode,%20java.security.PublicKey)(https://developer.android.com/reference/java/security/cert/TrustAnchor trustAnchor, https://developer.android.com/reference/java/security/cert/PolicyNode policyTree, https://developer.android.com/reference/java/security/PublicKey subjectPublicKey) ` Creates an instance of `PKIXCertPathValidatorResult` containing the specified parameters. |

| ### Public methods ||
|---|---|
| ` https://developer.android.com/reference/java/lang/Object` | ` https://developer.android.com/reference/java/security/cert/PKIXCertPathValidatorResult#clone()() ` Returns a copy of this object. |
| ` https://developer.android.com/reference/java/security/cert/PolicyNode` | ` https://developer.android.com/reference/java/security/cert/PKIXCertPathValidatorResult#getPolicyTree()() ` Returns the root node of the valid policy tree resulting from the PKIX certification path validation algorithm. |
| ` https://developer.android.com/reference/java/security/PublicKey` | ` https://developer.android.com/reference/java/security/cert/PKIXCertPathValidatorResult#getPublicKey()() ` Returns the public key of the subject (target) of the certification path, including any inherited public key parameters if applicable. |
| ` https://developer.android.com/reference/java/security/cert/TrustAnchor` | ` https://developer.android.com/reference/java/security/cert/PKIXCertPathValidatorResult#getTrustAnchor()() ` Returns the `TrustAnchor` describing the CA that served as a trust anchor for the certification path. |
| ` https://developer.android.com/reference/java/lang/String` | ` https://developer.android.com/reference/java/security/cert/PKIXCertPathValidatorResult#toString()() ` Return a printable representation of this `PKIXCertPathValidatorResult`. |

### Inherited methods

From class ` https://developer.android.com/reference/java/lang/Object ` ` https://developer.android.com/reference/java/lang/Object` ` https://developer.android.com/reference/java/lang/Object#clone()() `

Creates and returns a copy of this object.
` boolean` ` https://developer.android.com/reference/java/lang/Object#equals(java.lang.Object)(https://developer.android.com/reference/java/lang/Object obj) `

Indicates whether some other object is "equal to" this one.
` void` ` https://developer.android.com/reference/java/lang/Object#finalize()() `

Called by the garbage collector on an object when garbage collection determines that there are no more references to the object.
` final https://developer.android.com/reference/java/lang/Class<?>` ` https://developer.android.com/reference/java/lang/Object#getClass()() `

Returns the runtime class of this `Object`.
` int` ` https://developer.android.com/reference/java/lang/Object#hashCode()() `

Returns a hash code value for the object.
` final void` ` https://developer.android.com/reference/java/lang/Object#notify()() `

Wakes up a single thread that is waiting on this object's monitor.
` final void` ` https://developer.android.com/reference/java/lang/Object#notifyAll()() `

Wakes up all threads that are waiting on this object's monitor.
` https://developer.android.com/reference/java/lang/String` ` https://developer.android.com/reference/java/lang/Object#toString()() `

Returns a string representation of the object.
` final void` ` https://developer.android.com/reference/java/lang/Object#wait(long,%20int)(long timeoutMillis, int nanos) `

Causes the current thread to wait until it is awakened, typically by being *notified* or *interrupted*, or until a certain amount of real time has elapsed.
` final void` ` https://developer.android.com/reference/java/lang/Object#wait(long)(long timeoutMillis) `

Causes the current thread to wait until it is awakened, typically by being *notified* or *interrupted*, or until a certain amount of real time has elapsed.
` final void` ` https://developer.android.com/reference/java/lang/Object#wait()() `

Causes the current thread to wait until it is awakened, typically by being *notified* or *interrupted*.
From interface ` https://developer.android.com/reference/java/security/cert/CertPathValidatorResult ` ` abstract https://developer.android.com/reference/java/lang/Object` ` https://developer.android.com/reference/java/security/cert/CertPathValidatorResult#clone()() `

Makes a copy of this `CertPathValidatorResult`.

## Public constructors

### PKIXCertPathValidatorResult

Added in [API level 1](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)

```
public PKIXCertPathValidatorResult (TrustAnchor trustAnchor, 
                PolicyNode policyTree, 
                PublicKey subjectPublicKey)
```

Creates an instance of `PKIXCertPathValidatorResult` containing the specified parameters.

<br />

| Parameters ||
|---|---|
| `trustAnchor` | `TrustAnchor`: a `TrustAnchor` describing the CA that served as a trust anchor for the certification path <br /> |
| `policyTree` | `PolicyNode`: the immutable valid policy tree, or `null` if there are no valid policies <br /> |
| `subjectPublicKey` | `PublicKey`: the public key of the subject <br /> |

| Throws ||
|---|---|
| `https://developer.android.com/reference/java/lang/NullPointerException` | if the `subjectPublicKey` or `trustAnchor` parameters are `null` |

## Public methods

### clone

Added in [API level 1](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)

```
public Object clone ()
```

Returns a copy of this object.

<br />

| Returns ||
|---|---|
| `https://developer.android.com/reference/java/lang/Object` | the copy <br /> |

### getPolicyTree

Added in [API level 1](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)

```
public PolicyNode getPolicyTree ()
```

Returns the root node of the valid policy tree resulting from the PKIX certification path validation algorithm. The `PolicyNode` object that is returned and any objects that it returns through public methods are immutable.

Most applications will not need to examine the valid policy tree. They can achieve their policy processing goals by setting the policy-related parameters in `PKIXParameters`. However, more sophisticated applications, especially those that process policy qualifiers, may need to traverse the valid policy tree using the `https://developer.android.com/reference/java/security/cert/PolicyNode#getParent()` and `https://developer.android.com/reference/java/security/cert/PolicyNode#getChildren()` methods.

<br />

| Returns ||
|---|---|
| `https://developer.android.com/reference/java/security/cert/PolicyNode` | the root node of the valid policy tree, or `null` if there are no valid policies <br /> |

### getPublicKey

Added in [API level 1](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)

```
public PublicKey getPublicKey ()
```

Returns the public key of the subject (target) of the certification path, including any inherited public key parameters if applicable.

<br />

| Returns ||
|---|---|
| `https://developer.android.com/reference/java/security/PublicKey` | the public key of the subject (never `null`) <br /> |

### getTrustAnchor

Added in [API level 1](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)

```
public TrustAnchor getTrustAnchor ()
```

Returns the `TrustAnchor` describing the CA that served as a trust anchor for the certification path.

<br />

| Returns ||
|---|---|
| `https://developer.android.com/reference/java/security/cert/TrustAnchor` | the `TrustAnchor` (never `null`) <br /> |

### toString

Added in [API level 1](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)

```
public String toString ()
```

Return a printable representation of this `PKIXCertPathValidatorResult`.

<br />

| Returns ||
|---|---|
| `https://developer.android.com/reference/java/lang/String` | a `String` describing the contents of this `PKIXCertPathValidatorResult` <br /> |