Finsished restful support and added tess to demonstrate restful services hosted in...
[castle.git] / Facilities / Wcf / Castle.Facilities.WcfIntegration / IServiceHostBuilder.cs
blobc731df5de13a6077bd072265e15984ec357bd481
1 // Copyright 2004-2008 Castle Project - http://www.castleproject.org/
2 //
3 // Licensed under the Apache License, Version 2.0 (the "License");
4 // you may not use this file except in compliance with the License.
5 // You may obtain a copy of the License at
6 //
7 // http://www.apache.org/licenses/LICENSE-2.0
8 //
9 // Unless required by applicable law or agreed to in writing, software
10 // distributed under the License is distributed on an "AS IS" BASIS,
11 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 // See the License for the specific language governing permissions and
13 // limitations under the License.
15 namespace Castle.Facilities.WcfIntegration
17 using System;
18 using Castle.Core;
19 using System.ServiceModel;
21 /// <summary>
22 /// The contract for building service hosts.
23 /// </summary>
24 /// <typeparam name="M">The <see cref="IWcfServiceModel"/> type.</typeparam>
25 public interface IServiceHostBuilder<M> where M : IWcfServiceModel
27 /// <summary>
28 /// Builds a service host.
29 /// </summary>
30 /// <param name="model">The component model.</param>
31 /// <param name="serviceModel">The service model.</param>
32 /// <param name="baseAddresses">The base addresses.</param>
33 /// <returns>The service host.</returns>
34 ///
35 ServiceHost Build(ComponentModel model, M serviceModel, params Uri[] baseAddresses);
37 /// <summary>
38 /// Builds a service host for a hosted environment.
39 /// </summary>
40 /// <param name="model">The component model.</param>
41 /// <param name="baseAddresses">The base addresses.</param>
42 /// <returns>The service host.</returns>
43 ServiceHost Build(ComponentModel model, params Uri[] baseAddresses);
45 /// <summary>
46 /// Builds a service host for a hosted environment.
47 /// </summary>
48 /// <param name="serviceType">The service type.</param>
49 /// <param name="baseAddresses">The base addresses.</param>
50 /// <returns>The service host.</returns>
51 ServiceHost Build(Type serviceType, params Uri[] baseAddresses);