You are here

function _variable_realm_controller in Variable 7

Same name and namespace in other branches
  1. 7.2 variable_realm/variable_realm.module \_variable_realm_controller()

Create realm controller object.

1 call to _variable_realm_controller()
variable_realm in variable_realm/variable_realm.module
Get variable realm controller.

File

variable_realm/variable_realm.module, line 175
Variable API module - Realms

Code

function _variable_realm_controller($realm, $key, $variables = NULL) {
  $info = variable_realm_controller($realm);
  $class = isset($info['class']) ? $info['class'] : 'VariableRealmDefaultController';

  // Set realm weight if not set before.
  variable_realm_weight($realm, NULL, _variable_realm_weight($realm));
  return new $class($realm, $key, $variables);
}