> ## Documentation Index
> Fetch the complete documentation index at: https://docs.xbox.com/llms.txt
> Use this file to discover all available pages before exploring further.

# IDStorageFactoryX (Interface contents)

> IDStorageFactoryX

Represents the static DirectStorage factory object.

## Syntax

```cpp theme={null}
class IDStorageFactoryX : public IUnknown  
```

## Methods

| Method | Description |
| - | - |
| [CreateQueue](https://docs.xbox.com/reference/system/dstorage/interfaces/IDStorageFactoryX/methods/idstoragefactoryx_createqueue.md) | Creates a DirectStorage queue object. |
| [CreateStatusArray](https://docs.xbox.com/reference/system/dstorage/interfaces/IDStorageFactoryX/methods/idstoragefactoryx_createstatusarray.md) | Creates a DirectStorage status array object. |
| [OpenFile](https://docs.xbox.com/reference/system/dstorage/interfaces/IDStorageFactoryX/methods/idstoragefactoryx_openfile.md) | Opens a file for DirectStorage access. |
| [SetCpuAffinity](https://docs.xbox.com/reference/system/dstorage/interfaces/IDStorageFactoryX/methods/idstoragefactoryx_setcpuaffinity.md) | Sets a CPU affinity mask for DirectStorage. |
| [SetDebugFlags](https://docs.xbox.com/reference/system/dstorage/interfaces/IDStorageFactoryX/methods/idstoragefactoryx_setdebugflags.md) | Sets flags used to control the debug layer. |
| [SetStagingBufferSize](https://docs.xbox.com/reference/system/dstorage/interfaces/IDStorageFactoryX/methods/idstoragefactoryx_setstagingbuffersize.md) | Sets the size of the staging buffer. |

## Remarks

Use the DirectStorage factory object to create DirectStorage queues, open files for DirectStorage access, and perform global operations.

To obtain a pointer to the `IDStorageFactoryX` singleton, use [DStorageGetFactory](https://docs.xbox.com/reference/system/dstorage/functions/dstoragegetfactory.md).

For more information, see the "IDStorageFactoryX" section of [DirectStorage Overview](https://docs.xbox.com/build/console-features/storage/directstorage/directstorage-overview.md).

## Requirements

**Header:** dstorage\_xs.h

**Library:** dstorage.lib

**Supported platforms:** XBOX Series consoles

## See also

[DStorageGetFactory](https://docs.xbox.com/reference/system/dstorage/functions/dstoragegetfactory.md)\
[DStorage](https://docs.xbox.com/reference/system/dstorage/dstorage_members.md)


## Related topics

- [IDStorageFactoryX2 (Interface contents)](https://docs.xbox.com/reference/system/dstorage/interfaces/IDStorageFactoryX2/idstoragefactoryx2.md)
- [IDStorageFactoryX1 (Interface contents)](https://docs.xbox.com/reference/system/dstorage/interfaces/IDStorageFactoryX1/idstoragefactoryx1.md)
- [IDStorageQueueX2 (Interface contents)](https://docs.xbox.com/reference/system/dstorage/interfaces/IDStorageQueueX2/idstoragequeuex2.md)
- [IDStorageFileX (Interface contents)](https://docs.xbox.com/reference/system/dstorage/interfaces/IDStorageFileX/idstoragefilex.md)
- [IDStorageQueueX (Interface contents)](https://docs.xbox.com/reference/system/dstorage/interfaces/IDStorageQueueX/idstoragequeuex.md)
