C# Class RAML.WebApiExplorer.ApiExplorerService

Mostra file Open project: mulesoft-labs/raml-dotnet-apiexplorer Class Usage Examples

Protected Properties

Property Type Description
RamlTypes Raml.Parser.Expressions.RamlTypesOrderedDictionary
Schemas string>.IDictionary
Types ICollection

Public Methods

Method Description
ApiExplorerService ( IApiExplorer apiExplorer, string baseUri = null ) : System
GetRaml ( RamlVersion ramlVersion = RamlVersion.Version1, string title = null ) : Raml.Parser.Expressions.RamlDocument
SetSecurityScheme ( string type, Raml.Parser.Expressions.SecurityScheme scheme ) : void
UseOAuth1 ( string authorizationUri, string requestTokenUri, string tokenCredentialsUri, Raml.Parser.Expressions.SecuritySchemeDescriptor securitySchemeDescriptor ) : void
UseOAuth2 ( string authorizationUri, string accessTokenUri, IEnumerable authorizationGrants, IEnumerable scopes, Raml.Parser.Expressions.SecuritySchemeDescriptor securitySchemeDescriptor ) : void

Protected Methods

Method Description
AddType ( Type type ) : string
CreateJsonMimeType ( string type ) : MimeType>.Dictionary
CreateMimeType ( string type ) : Raml.Parser.Expressions.MimeType
CreateMimeTypes ( Raml.Parser.Expressions.MimeType mimeType ) : MimeType>.Dictionary
GetUniqueSchemaName ( string schemaName ) : string

Private Methods

Method Description
AddMethods ( Raml.Parser.Expressions.Resource resource, System.Web.Http.Description.ApiDescription api, ICollection verbs ) : void
GetDescription ( System.Web.Http.Description.ApiDescription api ) : string
GetMethods ( System.Web.Http.Description.ApiDescription api, ICollection verbs ) : IEnumerable
GetParameterFromProperty ( System.Web.Http.Description.ApiParameterDescription apiParam, PropertyInfo property ) : Raml.Parser.Expressions.Parameter
GetParametersFromComplexType ( System.Web.Http.Description.ApiParameterDescription apiParam, Parameter>.IDictionary queryParams ) : void
GetParametersFromUrl ( string url ) : Parameter>.IDictionary
GetPrimitiveParameter ( System.Web.Http.Description.ApiParameterDescription apiParam ) : Raml.Parser.Expressions.Parameter
GetQueryParameters ( IEnumerable parameterDescriptions ) : Parameter>.IDictionary
GetRequestMimeTypes ( System.Web.Http.Description.ApiDescription api ) : MimeType>.Dictionary
GetResponse ( Attribute attribute ) : Raml.Parser.Expressions.Response
GetResponses ( System.Web.Http.Description.ResponseDescription responseDescription, System.Web.Http.Description.ApiDescription api ) : IEnumerable
GetUriParameters ( string url, IEnumerable apiParameterDescriptions ) : Parameter>.IDictionary
HandleResponseTypeAttributes ( Type responseType ) : Raml.Parser.Expressions.Response
HandleResponseTypeStatusAttributes ( IEnumerable attributes ) : List
IsNullable ( Type type ) : bool
IsPrimitiveType ( Type parameterType ) : bool
OrganizeResourcesHierarchically ( Raml.Parser.Expressions.RamlDocument raml, Resource>.Dictionary resourcesDic ) : void
RemoveNonExistingParametersFromRoute ( string relativeUri, System.Web.Http.Description.ApiDescription api, string parameterName ) : string
SetSecurityScheme ( Raml.Parser.Expressions.RamlDocument raml ) : void
SetUriParameters ( IEnumerable resources, Dictionary parameterDescriptionsDic, string parentUrl ) : void

Method Details

AddType() protected abstract method

protected abstract AddType ( Type type ) : string
type System.Type
return string

ApiExplorerService() public method

public ApiExplorerService ( IApiExplorer apiExplorer, string baseUri = null ) : System
apiExplorer IApiExplorer
baseUri string
return System

CreateJsonMimeType() protected method

protected CreateJsonMimeType ( string type ) : MimeType>.Dictionary
type string
return MimeType>.Dictionary

CreateMimeType() protected abstract method

protected abstract CreateMimeType ( string type ) : Raml.Parser.Expressions.MimeType
type string
return Raml.Parser.Expressions.MimeType

CreateMimeTypes() protected method

protected CreateMimeTypes ( Raml.Parser.Expressions.MimeType mimeType ) : MimeType>.Dictionary
mimeType Raml.Parser.Expressions.MimeType
return MimeType>.Dictionary

GetRaml() public method

public GetRaml ( RamlVersion ramlVersion = RamlVersion.Version1, string title = null ) : Raml.Parser.Expressions.RamlDocument
ramlVersion RamlVersion
title string
return Raml.Parser.Expressions.RamlDocument

GetUniqueSchemaName() protected method

protected GetUniqueSchemaName ( string schemaName ) : string
schemaName string
return string

SetSecurityScheme() public method

public SetSecurityScheme ( string type, Raml.Parser.Expressions.SecurityScheme scheme ) : void
type string
scheme Raml.Parser.Expressions.SecurityScheme
return void

UseOAuth1() public method

public UseOAuth1 ( string authorizationUri, string requestTokenUri, string tokenCredentialsUri, Raml.Parser.Expressions.SecuritySchemeDescriptor securitySchemeDescriptor ) : void
authorizationUri string
requestTokenUri string
tokenCredentialsUri string
securitySchemeDescriptor Raml.Parser.Expressions.SecuritySchemeDescriptor
return void

UseOAuth2() public method

public UseOAuth2 ( string authorizationUri, string accessTokenUri, IEnumerable authorizationGrants, IEnumerable scopes, Raml.Parser.Expressions.SecuritySchemeDescriptor securitySchemeDescriptor ) : void
authorizationUri string
accessTokenUri string
authorizationGrants IEnumerable
scopes IEnumerable
securitySchemeDescriptor Raml.Parser.Expressions.SecuritySchemeDescriptor
return void

Property Details

RamlTypes protected_oe property

protected RamlTypesOrderedDictionary,Raml.Parser.Expressions RamlTypes
return Raml.Parser.Expressions.RamlTypesOrderedDictionary

Schemas protected_oe property

protected IDictionary Schemas
return string>.IDictionary

Types protected_oe property

protected ICollection Types
return ICollection