# XRSystemStateFeature

This [XRSystemStateFeature](https://developer.android.com/develop/xr/unity/reference/class/Google/XR/Extensions/XRSystemStateFeature#classGoogle_1_1XR_1_1Extensions_1_1XRSystemStateFeature) provides a function to query the system state information at runtime.

## Summary

### Inheritance

Inherits from: `OpenXRFeature`

| ### Public attributes ||
|---|---|
| [ExtensionString](https://developer.android.com/develop/xr/unity/reference/class/Google/XR/Extensions/XRSystemStateFeature#extensionstring)` = "XR_ANDROIDX_system_state"` | `const string` The OpenXR Extension string. |
| [FeatureId](https://developer.android.com/develop/xr/unity/reference/class/Google/XR/Extensions/XRSystemStateFeature#featureid)` = "com.google.xr.extensions.system_state"` | `const string` The feature ID string. |
| [UiName](https://developer.android.com/develop/xr/unity/reference/class/Google/XR/Extensions/XRSystemStateFeature#uiname)` = "Android XR: System State (Experimental*)"` | `const string` The UI name shows on the XR Plug-in Management panel, to help users understand validation errors and expected fixes. |

| ### Public static attributes ||
|---|---|
| [IsExtensionEnabled](https://developer.android.com/develop/xr/unity/reference/class/Google/XR/Extensions/XRSystemStateFeature#isextensionenabled)` => _extensionEnabled` | `bool` Gets if the required OpenXR extension is enabled. |

| ### Public static functions ||
|---|---|
| [TryGetSystemState](https://developer.android.com/develop/xr/unity/reference/class/Google/XR/Extensions/XRSystemStateFeature#trygetsystemstate)`(out `[XrSystemState](https://developer.android.com/develop/xr/unity/reference/struct/Google/XR/Extensions/XrSystemState#structGoogle_1_1XR_1_1Extensions_1_1XrSystemState)` systemState)` | `bool` Gets the current system state |

## Public attributes

### ExtensionString

```c#
const string ExtensionString = "XR_ANDROIDX_system_state"
```  
The OpenXR Extension string.

Used to check if this extension is available or enabled.  

### FeatureId

```c#
const string FeatureId = "com.google.xr.extensions.system_state"
```  
The feature ID string.  

### UiName

```c#
const string UiName = "Android XR: System State (Experimental*)"
```  
The UI name shows on the XR Plug-in Management panel, to help users understand validation errors and expected fixes.

## Public static attributes

### IsExtensionEnabled

```c#
bool IsExtensionEnabled => _extensionEnabled
```  
Gets if the required OpenXR extension is enabled.

When OpenXR runtime is waiting, it returns `null`. Otherwise, it indicates whether the XR_ANDROIDX_system_state extension is available on the current device.

## Public static functions

### TryGetSystemState

```c#
bool TryGetSystemState(
  out XrSystemState systemState
)
```  
Gets the current system state


| Details ||
|---|---|
| Parameters | |---|---| | `systemState` | System state info obtained from the system. | |