> For the complete documentation index, see [llms.txt](https://docs.yarnspinner.dev/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.yarnspinner.dev/api/csharp/yarn.unity/yarn.unity.iassetprovider.md).

# IAssetProvider

Interface in [Yarn.Unity](/api/csharp/yarn.unity.md)

## Summary

Contains methods for accessing assets of a given type stored within an object.

```csharp
public interface IAssetProvider
```

## Methods

| Name                                                                                                               | Description                                              |
| ------------------------------------------------------------------------------------------------------------------ | -------------------------------------------------------- |
| [GetAssetsOfType()](/api/csharp/yarn.unity/yarn.unity.iassetprovider/yarn.unity.iassetprovider.getassetsoftype.md) | Gets a collection of assets of type `T` from the target. |
| [TryGetAsset(T?)](/api/csharp/yarn.unity/yarn.unity.iassetprovider/yarn.unity.iassetprovider.trygetasset.md)       | Attempts to fetch an asset of type `T` from the object.  |
