# Google Cloud Workflows V1 Client - Class StackTrace (1.3.0)

1.3.0 (latest) 1.2.1 1.1.1 1.0.3 0.5.5 0.4.2 0.3.0 0.2.17 Reference documentation and code samples for the Google Cloud Workflows V1 Client class StackTrace.

A collection of stack elements (frames) where an error occurred.

Generated from protobuf message `google.cloud.workflows.executions.v1.Execution.StackTrace`

## Namespace

Google \\ Cloud \\ Workflows \\ Executions \\ V1 \\ Execution

## Methods

### __construct

Constructor.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `data` | `array` Optional. Data for populating the Message object. |
| `↳ elements` | `array<https://docs.cloud.google.com/php/docs/reference/cloud-workflows/latest/Executions.V1.Execution.StackTraceElement>` An array of stack elements. |

### getElements

An array of stack elements.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://protobuf.dev/reference/php/api-docs/Google/Protobuf/RepeatedField<https://docs.cloud.google.com/php/docs/reference/cloud-workflows/latest/Executions.V1.Execution.StackTraceElement>` |   |

### setElements

An array of stack elements.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `array<https://docs.cloud.google.com/php/docs/reference/cloud-workflows/latest/Executions.V1.Execution.StackTraceElement>` |

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