Initialize the admin-on-rest admin
437575
def _setup(app, *, schema,  title=None, app_key=APP_KEY, db=None):
    """"""

    admin = web.Application(loop=app.loop)
    app[app_key] = admin
    loader = jinja2.FileSystemLoader([TEMPLATES_ROOT, ])
    aiohttp_jinja2.setup(admin, loader=loader, app_key=TEMPLATE_APP_KEY)

    if title:
        schema.title = title

    resources = [
        init(db, info['table'], url=info['url'])
        for init, info in schema.resources
    ]

    admin_handler = AdminOnRestHandler(
        admin,
        resources=resources,
        loop=app.loop,
        schema=schema,
    )

    admin['admin_handler'] = admin_handler
    setup_admin_on_rest_handlers(admin, admin_handler)

    return admin
1249681
def init(self):
        """"""
        try:
            start_http_server(port=int(self.port), addr=self.host)
        except Exception as e:
            logger.critical("Can not start Prometheus exporter on {}:{} ({})".format(self.host, self.port, e))
            sys.exit(2)
        else:
            logger.info("Start Prometheus exporter on {}:{}".format(self.host, self.port))
635829
def administration(self):
        """"""
        from ..manageags._services import AGSService
        url = self._url
        res = search("/rest/", url).span()
        addText = "/admin/"
        part1 = url[:res[1]].lower().replace('/rest/', '')
        part2 = url[res[1]:].lower().replace('/featureserver', ".mapserver")
        adminURL = "%s%s%s" % (part1, addText, part2)
        return AGSService(url=adminURL,
                          securityHandler=self._securityHandler,
                          proxy_url=self._proxy_url,
                          proxy_port=self._proxy_port,
                          initialize=False)
537410
protected function init()
    {
        $this->addCommand(new SyncCommand());
        $this->addCommand(new MakesumCommand());

        $this->addGlobalOption('e')
            ->alias('env')
            ->description('The environment application name or class.')
            ->defaultValue('dev');
    }
1357230
public function initialize()
    {

        $this->title = '';
        $this->settings = array();
        $this->groupSets = null;
        $this->groups = null;
        $this->primaryResourceLinkId = null;
        $this->shareApproved = null;
        $this->created = null;
        $this->updated = null;

    }
249451
private static function init() {
        $lang = isset($_SERVER['HTTP_ACCEPT_LANGUAGE'])? substr($_SERVER['HTTP_ACCEPT_LANGUAGE'], 0, 2) : null;
        if (empty($lang))
            $lang = "es";
        self::$language = $lang;
        self::$messages = [];
        self::$messagesPath = get_property("app.messages_path", get_app()->resourcesPath() . DIRECTORY_SEPARATOR . "messages");
    }
536260
function initialize(server, callback) {
		source = new Backend(server, options);
		source.initialize(callback);
	}
134952
protected static function init() {
        self::$_serviceBusEndpointSetting = self::settingWithFunc(
            Resources::SERVICE_BUS_ENDPOINT_NAME,
            Validate::getIsValidUri()
        );

        self::$_wrapNameSetting = self::setting(
            Resources::SHARED_SECRET_ISSUER_NAME
        );

        self::$_wrapPasswordSetting = self::setting(
            Resources::SHARED_SECRET_VALUE_NAME
        );

        self::$_sasKeyNameSetting = self::setting(
            Resources::SHARED_SHARED_ACCESS_KEY_NAME
        );

        self::$_sasKeySetting = self::setting(
            Resources::SHARED_SHARED_ACCESS_KEY
        );

        self::$_wrapEndpointUriSetting = self::settingWithFunc(
            Resources::STS_ENDPOINT_NAME,
            Validate::getIsValidUri()
        );

        self::$validSettingKeys[] = Resources::SERVICE_BUS_ENDPOINT_NAME;
        self::$validSettingKeys[] = Resources::SHARED_SECRET_ISSUER_NAME;
        self::$validSettingKeys[] = Resources::SHARED_SECRET_VALUE_NAME;
        self::$validSettingKeys[] = Resources::SHARED_SHARED_ACCESS_KEY_NAME;
        self::$validSettingKeys[] = Resources::SHARED_SHARED_ACCESS_KEY;
        self::$validSettingKeys[] = Resources::STS_ENDPOINT_NAME;
    }
470878
public function initialize()
    {
        if ($this->initialized) {
            return;
        }

        $this->initialized = true;
        $currentLevel = ob_get_level();

        if (!defined('JPATH_BASE')) {
            define('JAPPLICATION_TYPE', $this->type);
        }

        $application = JAPPLICATION_TYPE;
        $cacheDir =
            rtrim(
                $this->container->getParameter('joomla.cache_dir') . DIRECTORY_SEPARATOR . strtolower($application),
                DIRECTORY_SEPARATOR
            );

        if (!defined('JPATH_BASE')) {
            $path = rtrim(JPATH_ROOT . DIRECTORY_SEPARATOR . strtolower(JAPPLICATION_TYPE), DIRECTORY_SEPARATOR);
            if (!is_dir($path)) {
                $path = JPATH_ROOT;
            }
            define('JPATH_BASE', $path);
        }

        if (!defined('JPATH_THEMES')) {
            define('JPATH_THEMES', JPATH_BASE . DIRECTORY_SEPARATOR . 'templates');
        }

        if (!defined('JPATH_CACHE')) {
            define('JPATH_CACHE', $cacheDir);
        }

        $filesystem = new Filesystem();
        if (!$filesystem->exists(JPATH_CACHE)) {
            $filesystem->mkdir(JPATH_CACHE);
        }

        $this->bootstrapHelpers();

        // Mark afterLoad in the profiler.
        JDEBUG ? $this->container->get('joomla.profiler')->mark('afterLoad') : null;

        register_shutdown_function([$this, 'shutdown'], $currentLevel);

        $this->restoreBufferLevel($currentLevel);

        $this->getApplication()->symfonyInitialise();

        $this->state = self::STATE_INIT;
    }
74081
function initialize() 
	{
		parent::initialize();

		// Provider api end-points
		$this->api->api_base_url  = "https://api.citrixonline.com/";
		$this->api->authorize_url = "https://api.citrixonline.com/oauth/authorize";
		$this->api->token_url     = "https://api.citrixonline.com/oauth/access_token";

        $this->api->curl_authenticate_method  = "GET";
	}
424353
public static function initialize()
    {
        switch($_SERVER['REQUEST_METHOD']) {
            case "POST":
                self::$_method = self::POST;
                break;
            case "GET":
                self::$_method = self::GET;
                break;
            case "PUT":
                self::$_method = self::PUT;
                break;
            case "DELETE":
                self::$_method = self::DELETE;
                break;
            default:
                self::$_method = self::HEAD;
        }
        self::$_data = array();
        self::_parseData($_GET);
        self::_parseData($_POST);
        
        if(
            isset($_SERVER['HTTPS']) &&
            $_SERVER['HTTPS'] !== null &&
            $_SERVER['HTTPS'] !== "off"
        ) {
            self::$_https = true;
        } else {
            self::$_https = false;
        }
        
        self::$_domain = (string) $_SERVER['HTTP_HOST'];
        self::$_file = (string) $_SERVER['SCRIPT_FILENAME'];
        if(isset($_SERVER['PATH_INFO'])) {
            self::$_pathInfo = (string) $_SERVER['PATH_INFO'];
        } else {
            self::$_pathInfo = "";
        }
    }
1025164
protected function initialize()
    {
        $actionResolverMiddleware = $this->getActionResolverMiddleware(
            $this->actionResolvers,
            $this->routingResultAttribute,
            self::$actionAttribute
        );

        $actionExecutorMiddleware = $this->getActionExecutorMiddleware(
            self::$actionAttribute,
            self::$payloadAttribute
        );

        $responderResolverMiddleware = $this->getResponderResolverMiddleware(
            $this->responderResolvers,
            self::$payloadAttribute,
            self::$responderAttribute
        );

        $responderExecutorMiddleware = $this->getResponderExecutorMiddleware(
            self::$responderAttribute,
            self::$payloadAttribute
        );

        $this->pipeEach($this->beforeActionResolverMiddlewares);
        $this->pipe($actionResolverMiddleware);
        $this->pipeEach($this->beforeActionExecutorMiddlewares);
        $this->pipe($actionExecutorMiddleware);
        $this->pipeEach($this->beforeResponderResolverMiddlewares);
        $this->pipe($responderResolverMiddleware);
        $this->pipeEach($this->beforeResponderExecutorMiddlewares);
        $this->pipe($responderExecutorMiddleware);
    }
1199445
function initGetOne(router, adminCGIBase, pluginName, handlerNameField, callback) {
    router.get(`${adminCGIBase}/${pluginName}/:${handlerNameField}`, callback);
}
477177
public function initialize() : void
    {
        $rem = $this->di->get("remserver");

        if (!$rem->hasDataset()) {
            $rem->init();
        }
    }
246767
function init(msg, done) {
  var config = {
    context: opts.context,
    adapter: opts.adapter,
    routes: opts.routes,
    auth: opts.auth,
    options: opts.options
  }

  setServer.call(this, config, done)
}
1335701
function initializeState(requester, updateParams) {
        var currentRequester = requester || "";
        _updateParams = updateParams;
        installerPath = path.resolve(updateDir, updateParams.installerName);
        postMessageToBrackets(MessageIds.NOTIFY_INITIALIZATION_COMPLETE, currentRequester);
    }
966456
function initalizeAdmins (adminConfigObject) {
            
            const admins = adminConfigObject || client.config("admins");

            if (!Array.isArray(admins)) {
                const errormsg = "\"admins\" property in configuration must be an array";
                client.error(errormsg);
                throw new Error(errormsg);
            }

            return admins.map(cloneOnlyAdminKeys).map(regexify);
        }