# Grafeas V1 Client - Class Subject (1.7.0)

1.7.0 (latest) 1.6.0 1.5.0 1.4.0 1.3.2 1.2.2 1.1.3 1.0.0 0.10.3 0.9.0 0.8.3 0.7.1 0.6.0 0.5.0 0.4.4 Reference documentation and code samples for the Grafeas V1 Client class Subject.

Generated from protobuf message `grafeas.v1.Subject`

## Namespace

Grafeas \\ V1

## Methods

### __construct

Constructor.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `data` | `array` Optional. Data for populating the Message object. |
| `↳ name` | `string` |
| `↳ digest` | `array|https://protobuf.dev/reference/php/api-docs/Google/Protobuf/Internal/MapField` `"<ALGORITHM>": "<HEX_VALUE>"` Algorithms can be e.g. sha256, sha512 See <https://github.com/in-toto/attestation/blob/main/spec/field_types.md#DigestSet> |

### getName

Generated from protobuf field `string name = 1;`

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `string` |   |

### setName

Generated from protobuf field `string name = 1;`

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `string` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getDigest

`"<ALGORITHM>": "<HEX_VALUE>"`
Algorithms can be e.g. sha256, sha512
See
<https://github.com/in-toto/attestation/blob/main/spec/field_types.md#DigestSet>

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://protobuf.dev/reference/php/api-docs/Google/Protobuf/Internal/MapField` |   |

### setDigest

`"<ALGORITHM>": "<HEX_VALUE>"`
Algorithms can be e.g. sha256, sha512
See
<https://github.com/in-toto/attestation/blob/main/spec/field_types.md#DigestSet>

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `array|https://protobuf.dev/reference/php/api-docs/Google/Protobuf/Internal/MapField` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |