WcfDataServerHelper.AddKnownType(Type) Method
Adds the specified custom permission requests or custom logon parameters type to the WCF data service contract’s known types list.
Namespace: DevExpress.ExpressApp.Security.ClientServer.Wcf
Assembly: DevExpress.ExpressApp.Security.Xpo.v24.2.dll
NuGet Package: DevExpress.ExpressApp.Security.Xpo
Declaration
Parameters
Name | Type | Description |
---|---|---|
type | Type | A System.Type object to be added to the WCF data service contract’s known types list. |
Remarks
In the Middle Tier Security scenario, you should call this method both at the server and client sides to register your custom permission requests and custom logon parameters. You do not need to use this method when you use standard logon parameters and have no custom permission requests implemented. Do not add business classes using this method.
The AddKnownType method throws an InvalidOperationException if the WcfDataServerHelper.GetKnownTypes method was already called internally. If you receive such an exception, call this method earlier, before the data server and/or client application are initialized.
The AddKnownType method can be called only once during the application life cycle. So, you should not call it from the Session_Start method of the ASP.NET Web Forms application. Instead, call it from the Application_Start method.