Class Type<T>.Indexer<A, V>
Provides access to indexer property declared in type T
.
Namespace: DotNext.Reflection
Assembly: DotNext.Reflection.dll
Syntax
public static class Indexer<A, V> : object where A : struct
Type Parameters
Name | Description |
---|---|
A | A structure representing parameters of indexer. |
V | Property value. |
Methods
| Improve this Doc View SourceGet(String, Boolean)
Reflects instance indexer property.
Declaration
public static Indexer<T, A, V> Get(string propertyName = null, bool nonPublic = false)
Parameters
Type | Name | Description |
---|---|---|
String | propertyName | The name of the indexer property. |
Boolean | nonPublic | true to reflect non-public property. |
Returns
Type | Description |
---|---|
Indexer<T, A, V> | The reflected property; or null, if property doesn't exist. |
GetStatic(String, Boolean)
Reflects static indexer property.
Declaration
public static Indexer<A, V> GetStatic(string propertyName, bool nonPublic = false)
Parameters
Type | Name | Description |
---|---|---|
String | propertyName | The name of the indexer property. |
Boolean | nonPublic | true to reflect non-public property. |
Returns
Type | Description |
---|---|
Indexer<A, V> | The reflected property; or null, if property doesn't exist. |
Require(String, Boolean)
Reflects instance indexer property.
Declaration
public static Indexer<T, A, V> Require(string propertyName = null, bool nonPublic = false)
Parameters
Type | Name | Description |
---|---|---|
String | propertyName | The name of the indexer property. |
Boolean | nonPublic | true to reflect non-public property. |
Returns
Type | Description |
---|---|
Indexer<T, A, V> | The reflected indexer property. |
Exceptions
Type | Condition |
---|---|
MissingPropertyException | The property doesn't exist. |
RequireStatic(String, Boolean)
Reflects static indexer property.
Declaration
public static Indexer<A, V> RequireStatic(string propertyName, bool nonPublic = false)
Parameters
Type | Name | Description |
---|---|---|
String | propertyName | The name of the indexer property. |
Boolean | nonPublic | true to reflect non-public property. |
Returns
Type | Description |
---|---|
Indexer<A, V> | The reflected indexer property. |
Exceptions
Type | Condition |
---|---|
MissingPropertyException | The property doesn't exist. |