Resuelve el modelo de exportacion y le establece los parametros
@param type $idChain
@param array $options
@return ChainModel
171138
public function resolveChainModel($idChain,array $options = []) {
        $resolver = new OptionsResolver();
        $resolver->setDefaults([
            "base_path" => null,
            "sub_path" => null,
            "data" => [],
            "fileName" => null,
        ]);
        $resolver->setAllowedTypes("data","array");
        $options = $resolver->resolve($options);
        $chainModel = $this->getChainModel($idChain);
        $chainModel
            ->setExporterManager($this)
            ->setSubPath($options["sub_path"])
            ->setBasePath($options["base_path"])
            ;
        return $chainModel;
    }
292675
public function createQueue($queueName, array $options = [])
    {
        /** @var \Generated\Shared\Transfer\RabbitMqOptionTransfer $rabbitMqOption */
        $rabbitMqOption = $options['rabbitMqConsumerOption'];

        return $this->queueEstablishmentHelper->createQueue($this->channel, $rabbitMqOption);
    }
1357017
public function exportFromList($definition = null, $options = [])
    {
        $lists = $this->controller->makeLists();

        $widget = $lists[$definition] ?? reset($lists);

        /*
         * Parse options
         */
        $defaultOptions = [
            'fileName' => $this->exportFileName,
            'delimiter' => ',',
            'enclosure' => '"'
        ];

        $options = array_merge($defaultOptions, $options);

        /*
         * Prepare CSV
         */
        $csv = CsvWriter::createFromFileObject(new SplTempFileObject);
        $csv->setDelimiter($options['delimiter']);
        $csv->setEnclosure($options['enclosure']);

        /*
         * Add headers
         */
        $headers = [];
        $columns = $widget->getVisibleColumns();
        foreach ($columns as $column) {
            $headers[] = Lang::get($column->label);
        }
        $csv->insertOne($headers);

        /*
         * Add records
         */
        $getter = $this->getConfig('export[useList][raw]', false)
            ? 'getColumnValueRaw'
            : 'getColumnValue';

        $query = $widget->prepareQuery();
        $results = $query->get();
        foreach ($results as $result) {
            $record = [];
            foreach ($columns as $column) {
                $value = $widget->$getter($result, $column);
                if (is_array($value)) {
                    $value = implode('|', $value);
                }
                $record[] = $value;
            }
            $csv->insertOne($record);
        }

        /*
         * Output
         */
        $csv->output($options['fileName']);
        exit;
    }
92570
public function getIronMQ($projectId, $token, array $options)
    {
        if (!class_exists(IronMQ::class)) {
            throw new \DomainException('Please install iron-io/iron_mq first.');
        }

        $defaultOptions = [
            'project_id' => $projectId,
            'token' => $token,
        ];

        $options = array_merge($defaultOptions, $options);

        return new IronMQ($options);
    }
888138
public static function couponsList($id, $params = null, $options = null)
    {
        $url = static::classUrl() . '/' . $id . '/coupons';
        return static::_directRequest('get', $url, $params, $options);
    }
1081633
public function find($id, array $options = [])
    {
        $test = $this->gateway->getConfig()['test'];

        foreach ($options as $key => $value) {
            $options[$key] = $value == null ? '' : $value;
        }

        $params = array_merge(
            ['cmd' => '_notify-validate'],
            $options
        );

        $url = $test
            ? 'https://ipnpb.sandbox.paypal.com/cgi-bin/webscr'
            : 'https://ipnpb.paypal.com/cgi-bin/webscr';

        return $this->gateway->commit('post', $url, $params);
    }
855695
public static function Connect ($dsn, $options = []) {
		$dsn = is_array($dsn) ? $dsn : IniFile::GetConfig($dsn, array_keys(static::$_enableIniRuleList), $options);

		if (isset($dsn['password']) && isset($options['key'])) {
			$algorithm = isset($options['algorithm']) ? $options['algorithm'] : self::PASSWORD_HASH_ALGORITHM;
			$dsn['password'] = static::CreateSecurePassword($dsn['password'], $options['key'], $algorithm);
		}

		$dsn_options = [];
		foreach ($dsn['options'] ?? [] as $option) {
			$dsn_options[(int)$option['name']] = (int)$option['value'];
		}
		$dsn['options'] = $dsn_options;

		$dsn['schemas'] = $dsn['schemas'] ?? [];

		static::$_dsnList[static::AdjustConnectionName($options, $dsn)][static::AdjustPriority($options)][static::AdjustStackNumber($options)] = $dsn;
	}
679549
public function beginTransaction($transactionOptions, array $options = [])
    {
        $res = $this->connection->beginTransaction([
            'projectId' => $this->projectId,
            'transactionOptions' => $transactionOptions
        ] + $options);

        return $res['transaction'];
    }
575117
public function filterInactiveExtensions($classChain)
    {
        $disabledModules = $this->getDisabledModuleIds();

        foreach ($disabledModules as $disabledModuleId) {
            $classChain = $this->cleanModuleFromClassChain($disabledModuleId, $classChain);
        }

        return $classChain;
    }
259114
public function get($index, $type, $id, $options = [])
    {
        return $this->db->get([$index, $type, $id], $options);
    }
543810
public static function delete($id, $options = [])
    {
        $url = static::classUrl() . '/' . $id;
        return static::_directRequest('delete', $url, null, $options);
    }
279038
private function executeAction($id, array $options)
    {
        $action = $this->adapter->post(sprintf('%s/floating_ips/%s/actions', $this->endpoint, $id), $options);

        $action = json_decode($action);

        return new ActionEntity($action->action);
    }
16477
public function select($name, $id, $options = [], array $attr = null)
    {
        $basic = $this->merge_attr([ 'id' => $id ], $attr);

        return $this->input($name, [ 'type' => 'select', 'options' => $options, 'attr' => $basic ]);
    }
933377
public function createConnection($dsn, array $config, array $options)
    {
        list($username, $password) = [
            Arr::get($config, 'username'), Arr::get($config, 'password'),
        ];

        try {
            return $this->createPdoConnection(
                $dsn,
                $username,
                $password,
                $options
            );
        } catch (Exception $e) {
            return $this->tryAgainIfCausedByLostConnection(
                $e,
                $dsn,
                $username,
                $password,
                $options
            );
        }
    }
963024
public static function reverse($id, $options = null)
    {
        $url = static::classUrl().'/'.$id.'/reverse';
        $params = [];
        return static::_directRequest('post', $url, $params, $options);
    }
96399
public function flowQueryAction(array $chain)
    {
        $createContext = array_shift($chain);
        $finisher = array_pop($chain);

        $flowQuery = new FlowQuery(array_map(
            function ($envelope) {
                return $this->nodeService->getNodeFromContextPath($envelope['$node']);
            },
            $createContext['payload']
        ));

        foreach ($chain as $operation) {
            $flowQuery = call_user_func_array([$flowQuery, $operation['type']], $operation['payload']);
        }

        $nodeInfoHelper = new NodeInfoHelper();
        $result = [];
        switch ($finisher['type']) {
            case 'get':
                $result = $nodeInfoHelper->renderNodes($flowQuery->get(), $this->getControllerContext());
            break;
            case 'getForTree':
                $result = $nodeInfoHelper->renderNodes($flowQuery->get(), $this->getControllerContext(), true);
            break;
            case 'getForTreeWithParents':
                $result = $nodeInfoHelper->renderNodesWithParents($flowQuery->get(), $this->getControllerContext());
            break;
        }

        return json_encode($result);
    }
1152613
public function postEvent($id, $event, $options = [ ]) {
        $data = $options;
        $data['id'] = $id;
        $data['event'] = $event;

        $result = $this->apiPost('event', $data);
        return $result;
    }