Επεξεργασία

Κοινή χρήση μέσω


_PropertyInfo.GetSetMethod Method

Definition

Provides COM objects with version-independent access to the GetSetMethod methods.

Overloads

GetSetMethod(Boolean)

Provides COM objects with version-independent access to the GetSetMethod(Boolean) method.

GetSetMethod()

Provides COM objects with version-independent access to the GetSetMethod() method.

Remarks

This method is for access to managed classes from unmanaged code and should not be called from managed code.

The GetSetMethod methods return a MethodInfo object representing the set accessor for this property.

GetSetMethod(Boolean)

Provides COM objects with version-independent access to the GetSetMethod(Boolean) method.

public:
 System::Reflection::MethodInfo ^ GetSetMethod(bool nonPublic);
public System.Reflection.MethodInfo GetSetMethod (bool nonPublic);
abstract member GetSetMethod : bool -> System.Reflection.MethodInfo
Public Function GetSetMethod (nonPublic As Boolean) As MethodInfo

Parameters

nonPublic
Boolean

true to return a non-public accessor; otherwise, false.

Returns

One of the values in the following table.

Value Meaning
A MethodInfo object representing the Set method for this property. The set accessor is public, OR the nonPublic parameter is true and the set accessor is non-public.
null The nonPublic parameter is true, but the property is read-only, OR the nonPublic parameter is false and the set accessor is non-public, OR there is no set accessor.

Remarks

This method is for access to managed classes from unmanaged code and should not be called from managed code.

The GetSetMethod method returns the set accessor for this property.

Applies to

GetSetMethod()

Provides COM objects with version-independent access to the GetSetMethod() method.

public:
 System::Reflection::MethodInfo ^ GetSetMethod();
public System.Reflection.MethodInfo GetSetMethod ();
abstract member GetSetMethod : unit -> System.Reflection.MethodInfo
Public Function GetSetMethod () As MethodInfo

Returns

The MethodInfo object representing the Set method for this property if the set accessor is public, or null if the set accessor is not public.

Remarks

This method is for access to managed classes from unmanaged code and should not be called from managed code.

The GetSetMethod method returns the public set accessor for this property.

Applies to