Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
3 changed files
with
402 additions
and
395 deletions.
There are no files selected for viewing
93 changes: 49 additions & 44 deletions
93
src/ServiceStack.Interfaces/ServiceHost/IServiceController.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,45 +1,50 @@ | ||
using System; | ||
using System.Collections.Generic; | ||
|
||
namespace ServiceStack.ServiceHost | ||
{ | ||
/// <summary> | ||
/// Responsible for executing the operation within the specified context. | ||
/// </summary> | ||
/// <value>The operation types.</value> | ||
public interface IServiceController | ||
{ | ||
/// <summary> | ||
/// Returns a list of operation types available in this service | ||
/// </summary> | ||
/// <value>The operation types.</value> | ||
IList<Type> OperationTypes { get; } | ||
|
||
/// <summary> | ||
/// Returns a list of ALL operation types available in this service | ||
/// </summary> | ||
/// <value>The operation types.</value> | ||
IList<Type> AllOperationTypes { get; } | ||
|
||
/// <summary> | ||
/// Returns the first matching RestPath | ||
/// </summary> | ||
/// <param name="httpMethod"></param> | ||
/// <param name="pathInfo"></param> | ||
/// <returns></returns> | ||
IRestPath GetRestPathForRequest(string httpMethod, string pathInfo); | ||
|
||
/// <summary> | ||
/// Allow the registration of custom routes | ||
/// </summary> | ||
IServiceRoutes Routes { get; } | ||
|
||
/// <summary> | ||
/// Executes the DTO request under the supplied requestContext. | ||
/// </summary> | ||
/// <param name="request"></param> | ||
/// <param name="requestContext"></param> | ||
/// <returns></returns> | ||
object Execute(object request, IRequestContext requestContext); | ||
} | ||
using System; | ||
using System.Collections.Generic; | ||
|
||
namespace ServiceStack.ServiceHost | ||
{ | ||
/// <summary> | ||
/// Responsible for executing the operation within the specified context. | ||
/// </summary> | ||
/// <value>The operation types.</value> | ||
public interface IServiceController | ||
{ | ||
/// <summary> | ||
/// Returns a list of operation types available in this service | ||
/// </summary> | ||
/// <value>The operation types.</value> | ||
IList<Type> OperationTypes { get; } | ||
|
||
/// <summary> | ||
/// Returns a list of ALL operation types available in this service | ||
/// </summary> | ||
/// <value>The operation types.</value> | ||
IList<Type> AllOperationTypes { get; } | ||
|
||
/// <summary> | ||
/// Returns the first matching RestPath | ||
/// </summary> | ||
/// <param name="httpMethod"></param> | ||
/// <param name="pathInfo"></param> | ||
/// <returns></returns> | ||
IRestPath GetRestPathForRequest(string httpMethod, string pathInfo); | ||
|
||
/// <summary> | ||
/// Allow the registration of custom routes | ||
/// </summary> | ||
IServiceRoutes Routes { get; } | ||
|
||
/// <summary> | ||
/// Executes the DTO request with no requestContext. | ||
/// </summary> | ||
object Execute(object dto); | ||
|
||
/// <summary> | ||
/// Executes the DTO request under the supplied requestContext. | ||
/// </summary> | ||
/// <param name="request"></param> | ||
/// <param name="requestContext"></param> | ||
/// <returns></returns> | ||
object Execute(object request, IRequestContext requestContext); | ||
} | ||
} |
Oops, something went wrong.