# Stackdriver Debugger V2 Client - Class StackFrame (1.9.5)

<button class="button button-with-icon cloud-select-dropdown__button " aria-haspopup="true">Version latest</button>

- [1.9.5 (latest)](https://docs.cloud.google.com/php/docs/reference/cloud-debugger/latest/V2.StackFrame)
- [1.9.4](https://docs.cloud.google.com/php/docs/reference/cloud-debugger/1.9.4/V2.StackFrame)
- [1.8.8](https://docs.cloud.google.com/php/docs/reference/cloud-debugger/1.8.8/V2.StackFrame)
- [1.7.0](https://docs.cloud.google.com/php/docs/reference/cloud-debugger/1.7.0/V2.StackFrame)
- [1.6.4](https://docs.cloud.google.com/php/docs/reference/cloud-debugger/1.6.4/V2.StackFrame)
- [1.5.1](https://docs.cloud.google.com/php/docs/reference/cloud-debugger/1.5.1/V2.StackFrame)
- [1.4.16](https://docs.cloud.google.com/php/docs/reference/cloud-debugger/1.4.16/V2.StackFrame)
Reference documentation and code samples for the Stackdriver Debugger V2 Client class StackFrame.

Represents a stack frame context.

Generated from protobuf message `google.devtools.clouddebugger.v2.StackFrame`

## Namespace

Google \\ Cloud \\ Debugger \\ V2

## Methods

### __construct

Constructor.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `data` | `array` Optional. Data for populating the Message object. |
| `↳ function` | `string` Demangled function name at the call site. |
| `↳ location` | `https://docs.cloud.google.com/php/docs/reference/cloud-debugger/latest/V2.SourceLocation` Source location of the call site. |
| `↳ arguments` | `array<https://docs.cloud.google.com/php/docs/reference/cloud-debugger/latest/V2.Variable>` Set of arguments passed to this function. Note that this might not be populated for all stack frames. |
| `↳ locals` | `array<https://docs.cloud.google.com/php/docs/reference/cloud-debugger/latest/V2.Variable>` Set of local variables at the stack frame location. Note that this might not be populated for all stack frames. |

### getFunction

Demangled function name at the call site.

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

### setFunction

Demangled function name at the call site.

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

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

### getLocation

Source location of the call site.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/cloud-debugger/latest/V2.SourceLocation|null` |   |

### hasLocation

### clearLocation

### setLocation

Source location of the call site.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `https://docs.cloud.google.com/php/docs/reference/cloud-debugger/latest/V2.SourceLocation` |

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

### getArguments

Set of arguments passed to this function.

Note that this might not be populated for all stack frames.

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

### setArguments

Set of arguments passed to this function.

Note that this might not be populated for all stack frames.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `array<https://docs.cloud.google.com/php/docs/reference/cloud-debugger/latest/V2.Variable>` |

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

### getLocals

Set of local variables at the stack frame location.

Note that this might not be populated for all stack frames.

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

### setLocals

Set of local variables at the stack frame location.

Note that this might not be populated for all stack frames.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `array<https://docs.cloud.google.com/php/docs/reference/cloud-debugger/latest/V2.Variable>` |

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