Get an option value.

@param string $optionName Name of option to retrieve.

@return mixed|null
175132
public function get(string $optionName)
    {
        foreach ($this->strategies as $strategy) {
            $value = $strategy->get($optionName);

            if (null !== $value) {
                return $value;
            }
        }

        return null;
    }
270456
public static String getOptionValue(String[] args, String optionName) {
		String opt = "-" + optionName + "=";
		for (String arg : args) {
			if (arg.startsWith(opt))
				return arg.substring(opt.length());
		}
		return null;
	}
839427
private function handleOptionName($name)
    {
        if (is_string($name)) {
            $name = explode('.', $name);
        }

        foreach ($this->optionNameHandlers as $handler) {
            $name = $handler($name);
        }

        return $name;
    }
287429
public function get_value() {
		$config = $this->options->get( $this->options_key );
		$value  = $config[ $this->id ];

		// Make sure $value is in $option_values if $option_values is set.
		if ( isset( $this->option_values ) && ! isset( $this->option_values[ $value ] ) ) {
			$value = null;
		}

		return $value;
	}
882068
public function getOption(string $option)
    {
        if (!$this->hasOption($option)) {
            throw ParameterException::noOption($option);
        }

        return $this->options[$option];
    }
243335
public function getOption($option)
    {
        if ($this->_link) {
            if (defined($option)) {
                if (@ldap_get_option($this->_link, constant($option), $value)) {
                    return $value;
                } else {
                    $err = @ldap_errno($this->_link);
                    if ($err) {
                        $msg = @ldap_err2str($err);
                    } else {
                        $err = NET_LDAP2_ERROR;
                        $msg = Net_LDAP2::errorMessage($err);
                    }
                    return $this->raiseError($msg, $err);
                }
            } else {
                $this->raiseError("Unkown Option requested");
            }
        } else {
            $this->raiseError("No LDAP connection");
        }
    }
1171126
public function getOption($option)
    {
        $this->_setErrorHandler();
        ldap_get_option($this->getConnection(), $option, $returnValue);
        $this->_unsetErrorHandler();

        return $returnValue;
    }
1025309
public function getOption($name = '')
    {
        if ('' === $name) {
            return $this->option;
        }

        return isset($this->option[$name]) ? $this->option[$name] : null;
    }
1192789
final protected function get($option)
    {
        if (array_key_exists($key = "$option", $this->options)) {
            return $this->options[$key];
        }

        if (array_key_exists($key, $this->defaults)) {
            return $this->defaults[$key];
        }
    }
1331825
protected function getOptions($optionNames = null)
    {
        $options = [];

        if ($optionNames === null) {
            $optionNames = $this->optionNames;
        }

        foreach ($optionNames as $option) {
            $converter = 'convert' . ucfirst($option);
            $value = method_exists($this, $converter) ? $this->$converter() : $this->$option;

            if ($value === null) {
                continue;
            }

            $options[$option] = $value;
        }

        return $options;
    }
516269
private function getOption() {
		
		// figure out which option was passed
		$searchOption = Console::findCommandOptionValue("get");
		$optionValue  = Config::getOption($searchOption);
		
		// write it out
		if (!$optionValue) {
			Console::writeError("the --get value you provided, <info>".$searchOption."</info>, does not exists in the config...");
		} else {
			$optionValue = (is_array($optionValue)) ? implode(", ",$optionValue) : $optionValue;
			$optionValue = (!$optionValue) ? "false" : $optionValue;
			Console::writeInfo($searchOption.": <ok>".$optionValue."</ok>");
		}
		
	}
1249516
public function getOption($option)
    {
        if (null !== $this->logger) {
            $this->logger->startMethod('getOption', ['option' => $option]);
        }

        if (!$this->assertOption($option)) {
            $this->stopMethod();

            return false;
        }

        $this->setResultOK();
        $this->stopMethod();

        return array_key_exists($option, $this->options) ? $this->options[$option] : false;
    }
1366317
public function getSourceValue($fieldname, $options = [])
    {
        $valueMap = [
            'data' => 'getData',
            'query' => 'getQuery'
        ];
        foreach ($this->getValueSources() as $valuesSource) {
            if ($valuesSource === 'context') {
                $val = $this->_getContext()->val($fieldname, $options);
                if ($val !== null) {
                    return $val;
                }
            }
            if (isset($valueMap[$valuesSource])) {
                $method = $valueMap[$valuesSource];
                $value = $this->_View->getRequest()->{$method}($fieldname);
                if ($value !== null) {
                    return $value;
                }
            }
        }

        return null;
    }
995310
public function getConfigOption($option)
    {
        // An exception will be thrown instead of returning NULL or something similar.
        if ( ! array_key_exists($option, $this->config)) {
            throw new UnexpectedValueException("Unexpected option name: {$option}");
        }

        return $this->config[$option];
    }
1164010
public function getOption($optionName)
    {
        if (!array_key_exists($optionName, $this->supportedOptions)) {
            throw new \Neos\Flow\Mvc\Exception(sprintf('The view option "%s" you\'re trying to get doesn\'t exist in class "%s".', $optionName, get_class($this)), 1359625876);
        }

        return $this->options[$optionName];
    }
834118
public function getOption($option)
    {
        if (!empty($this->options->{$option})) {
            return $this->options->{$option};
        }

        return false;
    }
895321
public function option($name)
    {
        $input = $this->getInput();

        return (is_null($name)) ? $input->getOptions() : $input->getOption($name);
    }