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

# XPackageWriteStats

> XPackageWriteStats

# XPackageWriteStats

Contains the output write statistics (writeStats).

<a id="syntaxSection" />

## Syntax

```cpp theme={null}
typedef struct XPackageWriteStats {  
    uint64_t interval;  
    uint64_t budget;  
    uint64_t elapsed;  
    uint64_t bytesWritten;  
} XPackageWriteStats  
```

<a id="membersSection" />

### Members

*interval*\
Type: uint64\_t

Read/Write: The total amount of time, in milliseconds, of the current interval.

*budget*\
Type: uint64\_t

Read: The amount of data the system will permit the title to write in the current interval without causing an exceeded event to be logged.

*elapsed*\
Type: uint64\_t

Read/Write: The amount of time, in milliseconds, elapsed in the current interval.

*bytesWritten*\
Type: uint64\_t

Read/Write: The number of bytes written by the title in the current interval.

<a id="remarksSection" />

## Remarks

The `XpackageWriteStats` structure is used by the [XPackageGetWriteStats](/reference/system/xpackage/functions/xpackagegetwritestats) function to both specify and receive write statistics (writeStats) for the current interval.

<Note>The first interval tracked by the title does not update *elapsed* and will not cause an exceeded event to be logged when surpassing the *budget*. Once the total *budget* of data has been written once, the interval will reset and the *elapsed* value will now start updating. Future intervals in the title will then reset based on interval times and trigger the exceeded event if the *budget* is surpassed.</Note>

For information about the packaging technology used with XBOX One titles, see [Overview of Packaging](/build/core-features/common/packaging/overviews/packaging). For information about the steps to create an XVC package, see [Getting started packaging titles for XBOX consoles](/build/core-features/common/packaging/overviews/packaging-getting-started-for-console).

<a id="requirementsSection" />

## Requirements

**Header:** XPackage.h

**Supported platforms:** Windows, XBOX One family consoles and XBOX Series consoles

<a id="seealsoSection" />

## See also

[Overview of downloadable content (DLC) packages](/build/core-features/common/packaging/packaging-downloadable-content-dlc)\
[XPackage](/reference/system/xpackage/xpackage_members)


## Related topics

- [XPackageGetWriteStats](/reference/system/xpackage/functions/xpackagegetwritestats.md)
- [XPackage](/reference/system/xpackage/xpackage_members.md)
- [Packages](/publishing/game-publishing/concepts/game-package-management.md)
- [Transaction writes](/services/playfab/player-progression/statistics/transactional-writes.md)
- [MicrosoftGame.config Element - EnableWritesToPackageRoot (DEPRECATED)](/reference/system/microsoftgameconfig/elements/microsoftgameconfig-element-enablewritestopackageroot.md)
