LicenseProvider.GetLicense(LicenseContext, Type, Object, Boolean) 메서드

정의

파생 클래스에서 재정의된 경우, 컨텍스트 및 라이선스가 거부되면 예외가 throw되는지 여부를 지정하면 구성 요소의 인스턴스 또는 형식에 대한 라이선스를 가져옵니다.

public:
 abstract System::ComponentModel::License ^ GetLicense(System::ComponentModel::LicenseContext ^ context, Type ^ type, System::Object ^ instance, bool allowExceptions);
public abstract System.ComponentModel.License GetLicense (System.ComponentModel.LicenseContext context, Type type, object instance, bool allowExceptions);
public abstract System.ComponentModel.License? GetLicense (System.ComponentModel.LicenseContext context, Type type, object? instance, bool allowExceptions);
abstract member GetLicense : System.ComponentModel.LicenseContext * Type * obj * bool -> System.ComponentModel.License
Public MustOverride Function GetLicense (context As LicenseContext, type As Type, instance As Object, allowExceptions As Boolean) As License

매개 변수

context
LicenseContext

라이선스가 있는 개체를 사용할 수 있는 경우를 지정하는 LicenseContext입니다.

type
Type

라이선스를 요청하는 구성 요소를 나타내는 Type입니다.

instance
Object

라이선스를 요청하는 개체입니다.

allowExceptions
Boolean

구성 요소에 라이선스를 부여할 수 없는 경우 LicenseException이 throw되면 true이고, 그렇지 않으면 false입니다.

반환

유효한 License입니다.

구현자 참고

에서 LicenseProvider상속하는 경우 를 재정 GetLicense(LicenseContext, Type, Object, Boolean) 의하여 라이선스 키에 대한 유효성 검사 방법을 구현해야 합니다.

적용 대상

추가 정보