Class TextDataProvider
Provides raw text from a local or remote URL.
Inherited Members
Namespace: UnityEngine.ResourceManagement.ResourceProviders
Syntax
public class TextDataProvider : ResourceProviderBase, IResourceProvider, IInitializableObject
Properties
IgnoreFailures
Controls whether errors are logged - this is disabled when trying to load from the local cache since failures are expected
Declaration
public bool IgnoreFailures { get; set; }
Property Value
| Type | Description |
|---|---|
| Boolean |
Methods
Convert(Type, String)
Method to convert the text into the object type requested. Usually the text contains a JSON formatted serialized object.
Declaration
public virtual object Convert(Type type, string text)
Parameters
| Type | Name | Description |
|---|---|---|
| Type | type | The object type the text is converted to. |
| String | text | The text to be converted. |
Returns
| Type | Description |
|---|---|
| Object | The converted object. |
Provide(ProvideHandle)
Provides raw text data from the location.
Declaration
public override void Provide(ProvideHandle provideHandle)
Parameters
| Type | Name | Description |
|---|---|---|
| ProvideHandle | provideHandle | The data needed by the provider to perform the load. |