API Docs for: 0.7.5
Show:

Params.common Class

Access point: ac.params.* Addon that provides access to any parameters given to the system

Methods

all

() Object

Alias for 'getAll'.

Returns:

Object: all params.

body

(
  • key
)
String | Object

Alias for 'getFromBody'.

Parameters:

  • key String

    The name of the parameter required.

Returns:

String | Object: param value, or all params if no key specified.

getAll

() Object

Gets all params, keyed by 'route', 'url', 'body', and 'file'.

Returns:

Object: all params.

getFromBody

(
  • key
)
String | Object

Gets body parameters

Parameters:

  • key String

    The name of the parameter required.

Returns:

String | Object: param value, or all params if no key specified.

getFromMerged

(
  • key
)
String | Object

Gets all params merged into one object. Route -> URL -> Body precedence.

Parameters:

  • key String

    The name of the parameter required.

Returns:

String | Object: param value, or all params if no key specified.

getFromRoute

(
  • key
)
String | Object

Gets route parameters

Parameters:

  • key String

    The name of the parameter.

Returns:

String | Object: param value, or all params if no key specified.

getFromUrl

(
  • key
)
String | Object

Gets URL parameters

Parameters:

  • key String

    The name of the parameter required.

Returns:

String | Object: param value, or all params if no key specified.

merged

(
  • key
)
String | Object

Alias for 'getFromMerged'.

Parameters:

  • key String

    The name of the parameter required.

Returns:

String | Object: param value, or all params if no key specified.

route

(
  • key
)
String | Object

Alias for 'getFromRoute'.

Parameters:

  • key String

    The name of the parameter required.

Returns:

String | Object: param value, or all params if no key specified.

url

(
  • key
)
String | Object

Alias for 'getFromUrl'.

Parameters:

  • key String

    The name of the parameter required.

Returns:

String | Object: param value, or all params if no key specified.