Class ParameterSignature
Represent the signature of a parameter to a method, property or similar.
Inheritance
Namespace: Cuemon.Reflection
Assembly: Cuemon.Core.dll
Syntax
public sealed class ParameterSignature
Constructors
| Improve this DocParameterSignature(Type, String)
Initializes a new instance of the ParameterSignature class.
Declaration
public ParameterSignature(Type parameterType, string parameterName)
Parameters
Type | Name | Description |
---|---|---|
System.Type | parameterType | The type of the parameter. |
System.String | parameterName | The name of the parameter. |
Exceptions
Type | Condition |
---|---|
System.ArgumentNullException |
|
ArgumentEmptyException |
|
Properties
| Improve this DocParameterName
Gets the name of the parameter.
Declaration
public string ParameterName { get; }
Property Value
Type | Description |
---|---|
System.String | The name of the parameter. |
ParameterType
Gets the System.Type of the parameter.
Declaration
public Type ParameterType { get; }
Property Value
Type | Description |
---|---|
System.Type | The System.Type of the parameter. |
Methods
| Improve this DocParse(IEnumerable<ParameterInfo>)
Converts the specified System.Reflection.ParameterInfo sequence to its System.Collections.Generic.IEnumerable<T> equivalent.
Declaration
public static IEnumerable<ParameterSignature> Parse(IEnumerable<ParameterInfo> parameters)
Parameters
Type | Name | Description |
---|---|---|
System.Collections.Generic.IEnumerable<System.Reflection.ParameterInfo> | parameters | A sequence of System.Reflection.ParameterInfo. |
Returns
Type | Description |
---|---|
System.Collections.Generic.IEnumerable<ParameterSignature> | An System.Collections.Generic.IEnumerable<T> that is equivalent to the System.Reflection.ParameterInfo sequence. |
Exceptions
Type | Condition |
---|---|
System.ArgumentNullException |
|
Parse(MethodBase)
Extracts and converts the System.Reflection.ParameterInfo sequence to its System.Collections.Generic.IEnumerable<T> equivalent from System.Reflection.MethodBase.GetParameters().
Declaration
public static IEnumerable<ParameterSignature> Parse(MethodBase method)
Parameters
Type | Name | Description |
---|---|---|
System.Reflection.MethodBase | method | The System.Reflection.MethodBase to extract parameter information from. |
Returns
Type | Description |
---|---|
System.Collections.Generic.IEnumerable<ParameterSignature> | An System.Collections.Generic.IEnumerable<T> that is equivalent to the System.Reflection.ParameterInfo sequence in System.Reflection.MethodBase.GetParameters(). |
Exceptions
Type | Condition |
---|---|
System.ArgumentNullException |
|