# Stackdriver Logging V2 Client - Class TailLogEntriesRequest (2.1.0)

2.1.0 (latest) 2.0.0 1.34.5 1.33.0 1.32.3 1.31.3 1.30.3 1.29.0 1.28.5 1.27.1 1.26.0 1.25.5 1.24.10 Reference documentation and code samples for the Stackdriver Logging V2 Client class TailLogEntriesRequest.

The parameters to `TailLogEntries`.

Generated from protobuf message `google.logging.v2.TailLogEntriesRequest`

## Namespace

Google \\ Cloud \\ Logging \\ V2

## Methods

### __construct

Constructor.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `data` | `array` Optional. Data for populating the Message object. |
| `↳ resource_names` | `string[]` Required. Name of a parent resource from which to retrieve log entries: \* \* `projects/[PROJECT_ID]` \* \* `organizations/[ORGANIZATION_ID]` \* \* `billingAccounts/[BILLING_ACCOUNT_ID]` \* \* `folders/[FOLDER_ID]` May alternatively be one or more views: \* \* `projects/[PROJECT_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]/views/[VIEW_ID]` \* \* `organizations/[ORGANIZATION_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]/views/[VIEW_ID]` \* \* `billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]/views/[VIEW_ID]` \* \* `folders/[FOLDER_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]/views/[VIEW_ID]` |
| `↳ filter` | `string` Optional. Only log entries that match the filter are returned. An empty filter matches all log entries in the resources listed in `resource_names`. Referencing a parent resource that is not listed in `resource_names` will cause the filter to return no results. The maximum length of a filter is 20,000 characters. |
| `↳ buffer_window` | `https://protobuf.dev/reference/php/api-docs/Google/Protobuf/Duration` Optional. The amount of time to buffer log entries at the server before being returned to prevent out of order results due to late arriving log entries. Valid values are between 0-60000 milliseconds. Defaults to 2000 milliseconds. |

### getResourceNames

Required. Name of a parent resource from which to retrieve log entries:

- `projects/[PROJECT_ID]`
- `organizations/[ORGANIZATION_ID]`
- `billingAccounts/[BILLING_ACCOUNT_ID]`
- `folders/[FOLDER_ID]` May alternatively be one or more views:
  - `projects/[PROJECT_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]/views/[VIEW_ID]`
  - `organizations/[ORGANIZATION_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]/views/[VIEW_ID]`
  - `billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]/views/[VIEW_ID]`
  - `folders/[FOLDER_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]/views/[VIEW_ID]`

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

### setResourceNames

Required. Name of a parent resource from which to retrieve log entries:

- `projects/[PROJECT_ID]`
- `organizations/[ORGANIZATION_ID]`
- `billingAccounts/[BILLING_ACCOUNT_ID]`
- `folders/[FOLDER_ID]` May alternatively be one or more views:
  - `projects/[PROJECT_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]/views/[VIEW_ID]`
  - `organizations/[ORGANIZATION_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]/views/[VIEW_ID]`
  - `billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]/views/[VIEW_ID]`
  - `folders/[FOLDER_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]/views/[VIEW_ID]`

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

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

### getFilter

Optional. Only log entries that match the filter are returned. An empty
filter matches all log entries in the resources listed in `resource_names`.

Referencing a parent resource that is not listed in `resource_names` will
cause the filter to return no results. The maximum length of a filter is
20,000 characters.

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

### setFilter

Optional. Only log entries that match the filter are returned. An empty
filter matches all log entries in the resources listed in `resource_names`.

Referencing a parent resource that is not listed in `resource_names` will
cause the filter to return no results. The maximum length of a filter is
20,000 characters.

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

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

### getBufferWindow

Optional. The amount of time to buffer log entries at the server before
being returned to prevent out of order results due to late arriving log
entries. Valid values are between 0-60000 milliseconds. Defaults to 2000
milliseconds.

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

### hasBufferWindow

### clearBufferWindow

### setBufferWindow

Optional. The amount of time to buffer log entries at the server before
being returned to prevent out of order results due to late arriving log
entries. Valid values are between 0-60000 milliseconds. Defaults to 2000
milliseconds.

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

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