Class DocumentHttpServiceExtensions
Inheritance
System.Object
DocumentHttpServiceExtensions
Namespace:InfinniPlatform.DocumentStorage
Assembly:InfinniPlatform.DocumentStorage.HttpService.dll
Syntax
public static class DocumentHttpServiceExtensions : object
Methods
| Improve this Doc View SourceRegisterDocumentHttpService(IContainerBuilder, String)
Регистрирует обработчик по умолчанию для сервиса по работе с документами указанного типа.
Declaration
public static void RegisterDocumentHttpService(this IContainerBuilder builder, string documentType)
Parameters
Type | Name | Description |
---|---|---|
IContainerBuilder | builder | |
System.String | documentType | Имя типа документа. |
RegisterDocumentHttpService<TDocument>(IContainerBuilder, String)
Регистрирует обработчик по умолчанию для сервиса по работе с документами указанного типа.
Declaration
public static void RegisterDocumentHttpService<TDocument>(this IContainerBuilder builder, string documentType = null)where TDocument : Document
Parameters
Type | Name | Description |
---|---|---|
IContainerBuilder | builder | |
System.String | documentType | Имя типа документа. |
Type Parameters
Name | Description |
---|---|
TDocument | Тип документа. |
RegisterDocumentHttpServiceInstance<TServiceHandler>(IContainerBuilder, TServiceHandler)
Регистрирует экземпляр обработчика для сервиса по работе с документами.
Declaration
public static void RegisterDocumentHttpServiceInstance<TServiceHandler>(this IContainerBuilder builder, TServiceHandler serviceHandler)where TServiceHandler : class, IDocumentHttpServiceHandlerBase
Parameters
Type | Name | Description |
---|---|---|
IContainerBuilder | builder | |
TServiceHandler | serviceHandler |
Type Parameters
Name | Description |
---|---|
TServiceHandler | Тип обработчика для сервиса по работе с документами. |
Examples
RegisterDocumentHttpServiceInstance(new MyDocumentHttpServiceHandler())
|
Improve this Doc
View Source
RegisterDocumentHttpServices(IContainerBuilder, Assembly)
Регистрирует все обработчики для сервисов по работе с документами.
Declaration
public static void RegisterDocumentHttpServices(this IContainerBuilder builder, Assembly assembly)
Parameters
Type | Name | Description |
---|---|---|
IContainerBuilder | builder | |
Assembly | assembly |
Remarks
Обработчики будут зарегистрированы со стратегией SingleInstance().
Examples
RegisterDocumentHttpServices(GetType().Assembly)
|
Improve this Doc
View Source
RegisterDocumentHttpServiceType(IContainerBuilder, Type)
Регистрирует тип обработчика для сервиса по работе с документами.
Declaration
public static void RegisterDocumentHttpServiceType(this IContainerBuilder builder, Type serviceHandlerType)
Parameters
Type | Name | Description |
---|---|---|
IContainerBuilder | builder | |
Type | serviceHandlerType | Тип обработчика для сервиса по работе с документами. |
Examples
RegisterDocumentHttpServiceType(typeof(MyDocumentHttpServiceHandler))
|
Improve this Doc
View Source
RegisterDocumentHttpServiceType<TServiceHandler>(IContainerBuilder)
Регистрирует тип обработчика для сервиса по работе с документами.
Declaration
public static void RegisterDocumentHttpServiceType<TServiceHandler>(this IContainerBuilder builder)where TServiceHandler : class, IDocumentHttpServiceHandlerBase
Parameters
Type | Name | Description |
---|---|---|
IContainerBuilder | builder |
Type Parameters
Name | Description |
---|---|
TServiceHandler | Тип обработчика для сервиса по работе с документами. |
Examples
RegisterDocumentHttpServiceType<MyDocumentHttpServiceHandler>()