コード例 #1
0
 /// <summary>
 /// Initializes new instance of <see cref="LazyController"/>.
 /// </summary>
 /// <param name="convertor">Instance of <see cref="IResponseConversionProvider{TConvertedResponse}"/>.</param>
 /// <param name="logger"></param>
 protected LazyController(IResponseConversionProvider <IHttpActionResult> convertor, ILogProvider logger)
 {
     Dispatcher =
         ServiceDispatcherFactory <IHttpActionResult> .Create(
             convertor ?? new ResponseConversionProvider(this),
             logger ?? new NullLogProvider());
 }
コード例 #2
0
 /// <summary>
 /// Initializes new instance of <see cref="LazyController"/>.
 /// </summary>
 /// <param name="convertor">Instance of <see cref="IResponseConversionProvider{TConvertedResponse}"/>.</param>
 protected LazyController(IResponseConversionProvider <IHttpActionResult> convertor) : this(convertor, null)
 {
 }
コード例 #3
0
 public static IServiceDispatcher <T> Create(IResponseConversionProvider <T> convertor)
 {
     return(new ServiceDispatcher <T>(convertor.ConvertResponse));
 }