# Google Cloud Private Catalog V1beta1 Client - Class SearchProductsRequest (0.6.3)

0.6.3 (latest) 0.6.2 0.5.3 0.4.6 0.3.3 0.2.13

> [!WARNING]
> **Beta**
>
>
> This library is covered by the [Pre-GA Offerings Terms](https://docs.cloud.google.com/terms/service-terms#1)
> of the Terms of Service. Pre-GA libraries might have limited support,
> and changes to pre-GA libraries might not be compatible with other pre-GA versions.
> For more information, see the
> [launch stage descriptions](https://docs.cloud.google.com/products#product-launch-stages).

Reference documentation and code samples for the Google Cloud Private Catalog V1beta1 Client class SearchProductsRequest.

Request message for [PrivateCatalog.SearchProducts](https://docs.cloud.google.com/php/docs/reference/cloud-private-catalog/latest/V1beta1.Client.PrivateCatalogClient#_Google_Cloud_PrivateCatalog_V1beta1_Client_PrivateCatalogClient__searchProducts__).

Generated from protobuf message `google.cloud.privatecatalog.v1beta1.SearchProductsRequest`

## Namespace

Google \\ Cloud \\ PrivateCatalog \\ V1beta1

## Methods

### __construct

Constructor.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `data` | `array` Optional. Data for populating the Message object. |
| `↳ resource` | `string` Required. The name of the resource context. See [SearchCatalogsRequest.resource](https://docs.cloud.google.com/php/docs/reference/cloud-private-catalog/latest/V1beta1.SearchCatalogsRequest#_Google_Cloud_PrivateCatalog_V1beta1_SearchCatalogsRequest__getResource__) for details. |
| `↳ query` | `string` The query to filter the products. The supported queries are: \* \* List products of all catalogs: empty \* \* List products under a catalog: `parent=catalogs/{catalog}` \* \* Get a product by name: `name=catalogs/{catalog}/products/{product}` |
| `↳ page_size` | `int` The maximum number of entries that are requested. |
| `↳ page_token` | `string` A pagination token returned from a previous call to SearchProducts that indicates where this listing should continue from. |

### getResource

Required. The name of the resource context. See [SearchCatalogsRequest.resource](https://docs.cloud.google.com/php/docs/reference/cloud-private-catalog/latest/V1beta1.SearchCatalogsRequest#_Google_Cloud_PrivateCatalog_V1beta1_SearchCatalogsRequest__getResource__)
for details.

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

### setResource

Required. The name of the resource context. See [SearchCatalogsRequest.resource](https://docs.cloud.google.com/php/docs/reference/cloud-private-catalog/latest/V1beta1.SearchCatalogsRequest#_Google_Cloud_PrivateCatalog_V1beta1_SearchCatalogsRequest__getResource__)
for details.

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

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

### getQuery

The query to filter the products.

The supported queries are:

- List products of all catalogs: empty
- List products under a catalog: `parent=catalogs/{catalog}`
- Get a product by name: `name=catalogs/{catalog}/products/{product}`

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

### setQuery

The query to filter the products.

The supported queries are:

- List products of all catalogs: empty
- List products under a catalog: `parent=catalogs/{catalog}`
- Get a product by name: `name=catalogs/{catalog}/products/{product}`

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

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

### getPageSize

The maximum number of entries that are requested.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `int` |   |

### setPageSize

The maximum number of entries that are requested.

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

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

### getPageToken

A pagination token returned from a previous call to SearchProducts that
indicates where this listing should continue from.

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

### setPageToken

A pagination token returned from a previous call to SearchProducts that
indicates where this listing should continue from.

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

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