Class GenericFileResourceLoader
Inheritance
System.Object
GenericFileResourceLoader
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: FixAntenna.Common.ResourceLoading
Assembly: FixAntenna.Common.dll
Syntax
public class GenericFileResourceLoader : ResourceLoader
Constructors
GenericFileResourceLoader(String)
Create the GenericFileResourceLoader
.
The next nextLoader is DummyResourceLoader.
Declaration
public GenericFileResourceLoader(string path)
Parameters
Type | Name | Description |
---|---|---|
System.String | path | path; should not contain resource name |
GenericFileResourceLoader(String, ResourceLoader)
Create the GenericFileResourceLoader
.
Declaration
public GenericFileResourceLoader(string path, ResourceLoader nextLoader)
Parameters
Type | Name | Description |
---|---|---|
System.String | path | path; should not contain resource name |
ResourceLoader | nextLoader | the next nextLoader |
Methods
GetResourcePath(String)
Get resource path according to which file would be loaded
Declaration
protected virtual string GetResourcePath(string resourceName)
Parameters
Type | Name | Description |
---|---|---|
System.String | resourceName |
Returns
Type | Description |
---|---|
System.String |
LoadResource(String)
Load resource
Declaration
public override Stream LoadResource(string resourceName)
Parameters
Type | Name | Description |
---|---|---|
System.String | resourceName | resource name |
Returns
Type | Description |
---|---|
System.IO.Stream | Stream with resource |
Overrides
Exceptions
Type | Condition |
---|---|
ResourceNotFoundException | if resource is not found and no parent ResourceLoader is available |