# Google Cloud OsConfig V1 Client - Class Inventory (2.2.3)

2.2.3 (latest) 2.2.2 2.1.0 2.0.5 1.3.5 1.2.2 1.1.1 1.0.5 Reference documentation and code samples for the Google Cloud OsConfig V1 Client class Inventory.

VM inventory details.

Generated from protobuf message `google.cloud.osconfig.v1.OSPolicyAssignment.InstanceFilter.Inventory`

## Namespace

Google \\ Cloud \\ OsConfig \\ V1 \\ OSPolicyAssignment \\ InstanceFilter

## Methods

### __construct

Constructor.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `data` | `array` Optional. Data for populating the Message object. |
| `↳ os_short_name` | `string` Required. The OS short name |
| `↳ os_version` | `string` The OS version Prefix matches are supported if asterisk(*) is provided as the last character. For example, to match all versions with a major version of `7`, specify the following value for this field \`7.*\` An empty string matches all OS versions. |

### getOsShortName

Required. The OS short name

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

### setOsShortName

Required. The OS short name

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

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

### getOsVersion

The OS version
Prefix matches are supported if asterisk(*) is provided as the
last character. For example, to match all versions with a major
version of `7`, specify the following value for this field \`7.*\`
An empty string matches all OS versions.

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

### setOsVersion

The OS version
Prefix matches are supported if asterisk(*) is provided as the
last character. For example, to match all versions with a major
version of `7`, specify the following value for this field \`7.*\`
An empty string matches all OS versions.

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

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