relax

Class DSLService

lucee.Component
    extended by relax.DSLService

Copyright Ortus Solutions, Corp, All rights reserved www.ortussolutions.com --- The DSL Service

Class Attributes:
  • singleton
  •  
  • synchronized : false
  •  
  • accessors : true
  •  
  • persistent : false
  •  
    Property Summary
    type property default serializable required
    struct APIDefinitions
          Storage for API Definitions.

    • access = public
    • returntype = any
    true false
    any log


    • access = public
    • returntype = any
    • inject = logbox:logger:{this}
    true false
    boolean sessionsEnabled
          Flag that tell us if the underlying application leverages session scope.

    • access = public
    • returntype = any
    true false
    struct settings
          The relax module's settings.

    • access = public
    • returntype = any
    true false
    Constructor Summary
    init(any settings)
          Constructor.
    Method Summary
    DSLService clearUserData()
         Clears user data.
    any getAPI(any name)
         Get an API definition.
    string getAPIDefinitions()
    any getLoadedAPI()
         Get the loaded API representation.
    string getLoadedAPIName()
         Get the loaded API name.
    string getLog()
    string getSessionsEnabled()
    string getSettings()
    DSLService importAPI(any name, any json)
         Import a relax API.
    private any injectMixin(any name, any UDF)
         Injection method.
    boolean isLoadedAPI()
         Checks if an API is loaded or not, usually by checking the user's data.
    query listAPIs()
         Get a listing of all the APIs in the resources folder.
    any loadAPI(any name)
         Load an API into the service and get its representation.
    DSLService processConfiguration(any dataCFC)
         Process a relax configure method.
    any setAPIDefinitions(struct APIDefinitions)
    any setLog(any log)
    any setSessionsEnabled(boolean sessionsEnabled)
    any setSettings(struct settings)
     
    Methods inherited from class lucee.Component
    None

    Constructor Detail

    init

    public init(any settings)

    Constructor

    Parameters:
    settings - The relax module settings needed

    Property Detail

    APIDefinitions

    property struct APIDefinitions

    Storage for API Definitions

    Attributes:
    access - public
    required - false
    returntype - any
    serializable - true

    log

    property any log

    Attributes:
    access - public
    required - false
    returntype - any
    inject - logbox:logger:{this}
    serializable - true

    sessionsEnabled

    property boolean sessionsEnabled

    Flag that tell us if the underlying application leverages session scope

    Attributes:
    access - public
    required - false
    returntype - any
    serializable - true

    settings

    property struct settings

    The relax module's settings

    Attributes:
    access - public
    required - false
    returntype - any
    serializable - true

    Method Detail

    clearUserData

    public DSLService clearUserData()

    Clears user data


    getAPI

    public any getAPI(any name)

    Get an API definition

    Parameters:
    name - The name of the API to get.

    getAPIDefinitions

    public string getAPIDefinitions()


    getLoadedAPI

    public any getLoadedAPI()

    Get the loaded API representation


    getLoadedAPIName

    public string getLoadedAPIName()

    Get the loaded API name


    getLog

    public string getLog()


    getSessionsEnabled

    public string getSessionsEnabled()


    getSettings

    public string getSettings()


    importAPI

    public DSLService importAPI(any name, any json)

    Import a relax API

    Parameters:
    name - The name of the API to import
    json - The JSON representation of the API

    injectMixin

    private any injectMixin(any name, any UDF)

    Injection method

    Parameters:
    name
    UDF

    isLoadedAPI

    public boolean isLoadedAPI()

    Checks if an API is loaded or not, usually by checking the user's data


    listAPIs

    public query listAPIs()

    Get a listing of all the APIs in the resources folder


    loadAPI

    public any loadAPI(any name)

    Load an API into the service and get its representation. This can be a Relax.cfc or a Relax.json representation.

    Parameters:
    name - The API to load

    processConfiguration

    public DSLService processConfiguration(any dataCFC)

    Process a relax configure method

    Parameters:
    dataCFC - The data CFC to process

    setAPIDefinitions

    public any setAPIDefinitions(struct APIDefinitions)

    Parameters:
    APIDefinitions

    setLog

    public any setLog(any log)

    Parameters:
    log

    setSessionsEnabled

    public any setSessionsEnabled(boolean sessionsEnabled)

    Parameters:
    sessionsEnabled

    setSettings

    public any setSettings(struct settings)

    Parameters:
    settings