API Documentation for: 1.1.2
Show:

Canteen.Gateway Class

Namespace: Canteen

The Gateway object is responsible for connecting to the json gateway for site data

Constructor

Canteen.Gateway

(
  • gatewayUrl
  • callback
)

Parameters:

  • gatewayUrl String

    The url to the gateway

  • callback Function

    The callback function when server is read

Item Index

Properties

Methods

destroy

()

Destroy the Gateway and don't use after this

get

(
  • callback
  • service
  • method
  • [parameters]
)

Main call for the service

Parameters:

  • callback Function

    The callback when we're done

  • service String

    The service to call from

  • method String

    The service method name

  • [parameters] Mixed optional

    Optional, additional parameters to pass to service call

initialize

(
  • gatewayUrl
  • callback
)

Estable a connection to the gatewayUrl

Parameters:

  • gatewayUrl String

    The url to the gateway

  • callback Function

    The callback function when server is read

Properties

gatewayUrl

String

The url of the gateway service