C# Class Ironman.Core.API.Manager.Manager

API manager
Mostra file Open project: JaCraig/Craig-s-Utility-Library

Private Properties

Property Type Description
Error Dynamo
Success Dynamo

Public Methods

Method Description
All ( int Version, string Mapping ) : IEnumerable

Gets all items of the specified mapping

Any ( int Version, string Mapping, string ID ) : Dynamo

Gets the specified item

CallService ( int Version, string Mapping, Dynamo Value ) : Dynamo

Runs the specified service

Delete ( int Version, string Mapping, string ID ) : Dynamo

Deletes an object

DeleteProperty ( int Version, string Mapping, string ID, string PropertyName, string PropertyID ) : Dynamo

Deletes a property value

GetProperty ( int Version, string Mapping, string ID, string Property ) : dynamic

Gets the specified item

Manager ( IEnumerable Mappings, IEnumerable Services, IEnumerable Modules, Utilities WorkflowManager ) : System

Constructor

PageCount ( int Version, string Mapping, int PageSize ) : Dynamo

Gets the page count for the mapping specified

Paged ( int Version, string Mapping, int PageSize, int Page, string OrderBy, string EmbeddedProperties ) : IEnumerable

Gets all items of the specified mapping of the specified page

RegisterRoutes ( RouteCollection routes, string ControllerName = "API", string AreaName = "" ) : void

Registers the routes used by the API system

Save ( int Version, string Mapping, IEnumerable Objects ) : Dynamo

Saves a list of objects

SaveProperty ( int Version, string Mapping, string ID, string PropertyName, IEnumerable Models ) : Dynamo

Saves a property

ToString ( ) : string

Outputs manager info as a string

this ( int Version, string Key ) : IAPIMapping

Gets the specified mapping

Private Methods

Method Description
Error ( string Message ) : Dynamo
Success ( string Message ) : Dynamo

Method Details

All() public method

Gets all items of the specified mapping
public All ( int Version, string Mapping ) : IEnumerable
Version int API version number
Mapping string Mapping name
return IEnumerable

Any() public method

Gets the specified item
public Any ( int Version, string Mapping, string ID ) : Dynamo
Version int API version number
Mapping string Mapping name
ID string ID of the item to get
return Dynamo

CallService() public method

Runs the specified service
public CallService ( int Version, string Mapping, Dynamo Value ) : Dynamo
Version int API version number
Mapping string Mapping name
Value Dynamo The value.
return Dynamo

Delete() public method

Deletes an object
public Delete ( int Version, string Mapping, string ID ) : Dynamo
Version int API version number
Mapping string Mapping name
ID string ID of the object to delete
return Dynamo

DeleteProperty() public method

Deletes a property value
public DeleteProperty ( int Version, string Mapping, string ID, string PropertyName, string PropertyID ) : Dynamo
Version int Version number
Mapping string Model name
ID string ID of the item to get
PropertyName string Property name
PropertyID string Property ID
return Dynamo

GetProperty() public method

Gets the specified item
public GetProperty ( int Version, string Mapping, string ID, string Property ) : dynamic
Version int API version number
Mapping string Mapping name
ID string ID of the item to get
Property string Property name
return dynamic

Manager() public method

Constructor
public Manager ( IEnumerable Mappings, IEnumerable Services, IEnumerable Modules, Utilities WorkflowManager ) : System
Mappings IEnumerable The mappings.
Services IEnumerable The services.
Modules IEnumerable The workflow modules.
WorkflowManager Utilities The workflow manager.
return System

PageCount() public method

Gets the page count for the mapping specified
public PageCount ( int Version, string Mapping, int PageSize ) : Dynamo
Version int API version number
Mapping string Mapping name
PageSize int Size of the page.
return Dynamo

Paged() public method

Gets all items of the specified mapping of the specified page
public Paged ( int Version, string Mapping, int PageSize, int Page, string OrderBy, string EmbeddedProperties ) : IEnumerable
Version int API version number
Mapping string Mapping name
PageSize int Size of the page.
Page int The page desired
OrderBy string The order by clause
EmbeddedProperties string Embedded properties
return IEnumerable

RegisterRoutes() public method

Registers the routes used by the API system
public RegisterRoutes ( RouteCollection routes, string ControllerName = "API", string AreaName = "" ) : void
routes RouteCollection The routing table
ControllerName string Name of the controller.
AreaName string Name of the area (leave blank if you're not using one).
return void

Save() public method

Saves a list of objects
public Save ( int Version, string Mapping, IEnumerable Objects ) : Dynamo
Version int API version number
Mapping string Mapping name
Objects IEnumerable Objects to save
return Dynamo

SaveProperty() public method

Saves a property
public SaveProperty ( int Version, string Mapping, string ID, string PropertyName, IEnumerable Models ) : Dynamo
Version int Version
Mapping string Model name
ID string ID
PropertyName string Property name
Models IEnumerable Models
return Dynamo

ToString() public method

Outputs manager info as a string
public ToString ( ) : string
return string

this() public method

Gets the specified mapping
public this ( int Version, string Key ) : IAPIMapping
Version int API version number
Key string Name of the mapped type
return IAPIMapping