JetoReader
Since v2.14Methods to load Eto objects from .jeto (JSON) files
Remarks: Set
EtoXamlJeto to true in your project to embed .jeto files, and EtoXamlCodeGen to compile them. Use XamlReader for .xeto files.Methods
Load<T>
#public static T Load<T>()
Loads the specified type from the embedded .jeto of the same name, e.g. MyNamespace.MyType.jeto
Returns: A new instance of the specified type with the contents loaded from the jeto
Load<T>
#Loads the specified type from the specified jeto stream
Parameters:
| stream (Stream) | Jeto content to load (e.g. from resources) |
| instance (T) | Instance to use as the starting object, or null to create a new instance |
| settings (XamlReaderSettings) | Settings for reading the jeto |
Returns: A new or existing instance of the specified type with the contents loaded from the jeto stream
Load<T>
#Loads the specified type from the specified jeto stream
Parameters:
| stream (Stream) | Jeto content to load (e.g. from resources) |
| instance (T) | Instance to use as the starting object, or null to create a new instance |
Returns: A new or existing instance of the specified type with the contents loaded from the jeto stream
Load<T>
#Loads the specified type from the specified jeto stream
Parameters:
| stream (Stream) | Jeto content to load (e.g. from resources) |
Returns: A new instance of the specified type with the contents loaded from the jeto stream
Load<T>
#Loads the specified type from the specified jeto
reader.Parameters:
| reader (TextReader) | Reader to read the jeto content |
| instance (T) | Instance to use as the starting object, or null to create a new instance |
Returns: A new or existing instance of the specified type with the contents loaded from the jeto
Load<T>
#Loads the specified instance from a fully qualified .jeto embedded resource in the same assembly as
TParameters:
| instance (T) | Instance to use as the starting object |
| resourceName (string) | Fully qualified name of the embedded resource to load. |
Load<T>
#Loads the specified instance from the embedded .jeto of the same name, e.g. MyNamespace.MyType.jeto
Parameters:
| instance (T) | Instance to use as the starting object |
| settings (XamlReaderSettings) | Settings for reading the jeto, or null to use compiled code when available |
Load<T>
#public static void Load<T>(T instance)
Loads the specified instance from the embedded .jeto of the same name, e.g. MyNamespace.MyType.jeto, or runs its compiled code when
EtoXamlCodeGen is enabled.Parameters:
| instance (T) | Instance to use as the starting object |
Watch<T>
#Watches the .jeto file for changes and triggers the method specified by the HotReloadAttribute, if any, when the file changes. Otherwise, it will reload the jeto into the control using Load<T>(T).