Check that there is a local variable with such name.

@param variableName a name to be checked, can be null
@return false if there is not such variable or it is null, true if such local variable exists
352100
public boolean isLocalVariable(@Nullable final String variableName) {
    boolean result = false;
    if (variableName != null) {
      final String normalized = PreprocessorUtils.normalizeVariableName(variableName);
      result = this.localVarTable.containsKey(normalized);
    }
    return result;
  }
661262
@SuppressWarnings("unchecked")
    public <T> T getValue(final String variableName) {
        final Variable variable = getVariable(variableName);
        return (variable == null) ? null : (T) variable.getValue();
    }
255062
protected void validName(String name) throws SyntaxException {
		for (String varName : automaticVariables) {
			if (varName.equals(name)) {
				throw SyntaxException.create(getSourceRange(),
						MSG_AUTO_VAR_CANNOT_BE_SET, varName);
			}
		}
	}
322815
public boolean isGlobalVariable(@Nullable final String variableName) {
    boolean result = false;
    if (variableName != null) {
      final String normalized = PreprocessorUtils.normalizeVariableName(variableName);
      result = this.globalVarTable.containsKey(normalized) || mapVariableNameToSpecialVarProcessor.containsKey(normalized);
    }
    return result;
  }
420112
function checkVariable(variable) {
            if (variable.writeable === false && exceptions.indexOf(variable.name) === -1) {
                variable.references.forEach(checkReference);
            }
        }
279809
protected void checkVariableName(GraphRewrite event, EvaluationContext context)
    {
        if (variableName == null)
        {
            setVariableName(Iteration.getPayloadVariableName(event, context));
        }
    }
1238776
public boolean hasInputVariable(String name) {
        for (InputVariable inputVariable : this.inputVariables) {
            if (inputVariable.getName().equals(name)) {
                return true;
            }
        }
        return false;
    }
1294084
def is_valid_variable_name(string_to_check):
    

    try:

        parse('{} = None'.format(string_to_check))
        return True

    except (SyntaxError, ValueError, TypeError):

        return False
1044398
@Nullable
  public Value getLocalVariable(@Nullable final String name) {
    if (name == null) {
      return null;
    }

    final String normalized = assertNotNull(PreprocessorUtils.normalizeVariableName(name));

    if (normalized.isEmpty()) {
      return null;
    }

    return localVarTable.get(normalized);
  }
144782
function hasVariable( $blockName, $varName )
    {
        // 1. Check if the variable is set in either injected or regular settings.
        if (
            !isset( self::$injectedSettings[$this->FileName][$blockName][$varName] )
            && !isset( $this->BlockValues[$blockName][$varName] )
        )
        {
            return false;
        }

        // 2. Check if injected setting isn't strictly false (false being the default value when a variable doesn't exist).
        if (
            isset( self::$injectedSettings[$this->FileName][$blockName][$varName] )
            && self::$injectedSettings[$this->FileName][$blockName][$varName] === false
        )
        {
            return false;
        }

        return true;
    }
1125552
public final VariableNumMap getVariablesByName(Collection<String> variableNames) {
    int[] newNums = new int[nums.length];
    String[] newNames = new String[nums.length];
    Variable[] newVars = new Variable[nums.length];

    int numFilled = 0;
    for (int i = 0; i < nums.length; i++) {
      if (variableNames.contains(names[i])) {
        newNums[numFilled] = nums[i];
        newNames[numFilled] = names[i];
        newVars[numFilled] = vars[i];
        numFilled++;
      }
    }
    return VariableNumMap.fromSortedArrays(newNums, newNames, newVars, numFilled);
  }
609516
public static boolean isVariableSet(QuerySolution resultRow, String variableName) {

        if (resultRow != null) {
            return resultRow.contains(variableName);
        }

        return false;
    }
73860
def get_local(self, variable_name):
        '''
        
        '''
        if variable_name not in self._locals:
            raise UnknownVariable('Unknown variable %s' % variable_name)
        return self._locals[variable_name]
1347456
Variable getVariable(String name) {
    VarKey varKey = VarKey.create(Kind.USER_DEFINED, name);
    return getVariable(varKey);
  }
1165614
@Override
	public String onVariable(String variable) {
		String value = null;
		if(variables != null && variables.containsKey(variable)) {
			Object val = variables.get(variable);
			value = (val != null) ? val.toString() : null;
		}
		return value;
	}
881984
@Override
    public boolean contains(final String varName) {
        return runWithContext(new RhinoCallable<Boolean, RuntimeException>() {
            @Override
            protected Boolean doCall(Context cx, Scriptable scope) {
                return scope.get(varName, scope) != null;
            }
        });
    }
411872
function findVariable(variables, name) {
  let i;
  let len;

  for (i = 0, len = variables.length; i < len; i++) { // eslint-disable-line no-plusplus
    if (variables[i].name === name) {
      return true;
    }
  }

  return false;
}