Get the value for a custom option or its inherent default.
@param key Key identifying option
966744
@ExperimentalApi("https://github.com/grpc/grpc-java/issues/1869")
  @SuppressWarnings("unchecked")
  public <T> T getOption(Key<T> key) {
    Preconditions.checkNotNull(key, "key");
    for (int i = 0; i < customOptions.length; i++) {
      if (key.equals(customOptions[i][0])) {
        return (T) customOptions[i][1];
      }
    }
    return key.defaultValue;
  }
600972
@Override
	public String getString(String key, String defaultValue) {
		return this.backingConfig.getString(this.prefix + key, defaultValue);
	}
901033
public int get(Object key, int defaultValue) {
        if (key == null) { key = UniqueTag.NULL_VALUE; }
        int index = findIndex(key);
        if (0 <= index) {
            return values[index];
        }
        return defaultValue;
    }
48658
@Override
  public String get(String key, String defaultValue)
  {
    String value = _map.get(key);

    if (value != null) {
      return value;
    }
    else {
      return defaultValue;
    }
  }
1153844
protected final String getConfigurationValue(String key)
    {
        //get value
        String value=this.monitorConfiguration.get(key);
        
        //trim value
        if(value!=null)
        {
            value=value.trim();
            
            //set as null if empty string
            if(value.length()==0)
            {
                value=null;
            }
        }
        
        this.monitorLogger.logDebug(new Object[]{"Extracted configuration for key: ",key," value: ",value},null);
        
        return value;
    }
148753
private Optional<String> get(String key, Set<String> processingKeys) {

        for (ConfigurationSource configurationSource : config.getConfigurationSources()) {

            Optional<String> value = configurationSource.get(key);

            if (value.isPresent()) {

                return Optional.of(interpolateString(
                        key, ConfigurationDecoderUtils.decodeConfigValueIfEncoded(key, value.get()), processingKeys));
            }
        }

        return Optional.empty();
    }
135067
private String getInternal(String key) {
		Preconditions.checkArgument(configuredOptions.containsKey(key),
			"The configuration " + key + " has not been configured.");

		return configuredOptions.get(key);
	}
788402
@SuppressWarnings("unchecked")
    public <V> V getOption(java.lang.String key)
    {
        return (V)extraOptions.get(key);
    }
669055
@SuppressWarnings("unchecked")
    public <T> T getCustom(String key) {
        return (T) custom.get(key);
    }
1125352
function defaultValue (key) {
    if (!checkAllAliases(key, flags.bools) &&
        !checkAllAliases(key, flags.counts) &&
        `${key}` in defaults) {
      return defaults[key]
    } else {
      return defaultForType(guessType(key))
    }
  }
515014
private String getPropertyValue( final String    key )
    {
        String    value = null;
        for ( Properties    source : _sources )
        {
            value = source.getProperty( key );

            if ( value != null )
            {
                break;
            }
        }

        return value;
    }
1272910
public String getValue(String key) {
        KeyValue kv = getKV(key);
        return kv == null ? null : kv.getValue();
    }
272973
public static String getValue(Map<String,String> map, String key, String defaultValue) {
		return map.containsKey( key ) ? map.get( key ) : defaultValue;
	}
911183
@Override
	public List<CPDefinitionOptionValueRel> findByKey(String key) {
		return findByKey(key, QueryUtil.ALL_POS, QueryUtil.ALL_POS, null);
	}
353398
public String get(String key) {
    if (properties.get(key) != null) {
      return properties.get(key);
    } else {
      return getConfigurationValue(key);
    }
  }
510551
public String get(String key)
	{
		String ret = getValueFromOptions(key, StringOption.class);
		if (ret == null && options.containsKey(key))
			ret = options.get(key).toString();
		return ret;
	}
1014878
public String get(String key, String defaultValue) {
		addToDefaults(key, defaultValue);
		String value = get(key);
		if (value == null) {
			return defaultValue;
		} else {
			return value;
		}
	}