get variable name
495390
private function getVariableName() {
		$arrBacktrace = debug_backtrace();

		//possible 'included' functions
		$arrInclude = array("include","include_once","require","require_once");

		//check for any included/required files. if found, get array of the last included file (they contain the right line numbers)
		for($i=count($arrBacktrace)-1; $i>=0; $i--) {
			$arrCurrent = $arrBacktrace[$i];
			if(array_key_exists("function", $arrCurrent) &&
				(in_array($arrCurrent["function"], $arrInclude) || (0 != strcasecmp($arrCurrent["function"], "dbug"))))
				continue;

			$arrFile = $arrCurrent;

			break;
		}

		if(isset($arrFile)) {
			$arrLines = file($arrFile["file"]);
			$code = $arrLines[($arrFile["line"]-1)];

			//find call to dBug class
			preg_match('/\bnew dBug\s*\(\s*(.+)\s*\);/i', $code, $arrMatches);


			if (isset($arrMatches[1])) {
				return $arrMatches[1];
			}

		}
		return "";
	}
138480
def get_local_variable_from_name(self, variable_name):
        
        return next((v for v in self.variables if v.name == variable_name), None)
375401
public String getVariableQualifiedName(VariableElement var) {
    String shortName = getVariableShortName(var);
    if (ElementUtil.isGlobalVar(var)) {
      String className = getFullName(ElementUtil.getDeclaringClass(var));
      if (ElementUtil.isEnumConstant(var)) {
        // Enums are declared in an array, so we use a macro to shorten the
        // array access expression.
        return "JreEnum(" + className + ", " + shortName + ")";
      }
      return className + '_' + shortName;
    }
    return shortName;
  }
372272
function get_var_names($file_name, $section = NULL)
	{
		if (empty($file_name)) {
			$this->_trigger_error_msg('Empty config file name');
			return;
		} else if (!isset($this->_config_data[$file_name])) {
			$this->_trigger_error_msg("Unknown config file '$file_name'");
			return;
		}

		if (empty($section))
		return array_keys($this->_config_data[$file_name]["vars"]);
		else
		return array_keys($this->_config_data[$file_name]["sections"][$section]["vars"]);
	}
140254
def variable_names(self):
        
        result = []
        names = javabridge.call(self.jobject, "getVariableNames", "()Ljava/util/Set;")
        for name in javabridge.iterate_collection(names):
            result.append(javabridge.to_string(name))
        return result
1355827
def __getVariables(self):
        """'"""
        try:
            startupinfo = None
            if os.name == 'nt':
                startupinfo = subprocess.STARTUPINFO()
                startupinfo.dwFlags |= subprocess.STARTF_USESHOWWINDOW
            output = subprocess.check_output(['p4', 'set'], startupinfo=startupinfo)
            if six.PY3:
                output = str(output, 'utf8')
        except subprocess.CalledProcessError as err:
            LOGGER.error(err)
            return

        p4vars = {}
        for line in output.splitlines():
            if not line:
                continue
            try:
                k, v = line.split('=', 1)
            except ValueError:
                continue
            p4vars[k.strip()] = v.strip().split(' (')[0]
            if p4vars[k.strip()].startswith('(config'):
                del p4vars[k.strip()]

        self._port = self._port or os.getenv('P4PORT', p4vars.get('P4PORT'))
        self._user = self._user or os.getenv('P4USER', p4vars.get('P4USER'))
        self._client = self._client or os.getenv('P4CLIENT', p4vars.get('P4CLIENT'))
1207415
def get_var(self, name):
        
        for var in self.vars:
            if var.name == name:
                return var
        else:
            raise ValueError
864013
function getVariable(variable) {

  if ( cached.data == null ) {
    getData();
  }

  if (variable.toUpperCase() in cached.data ) {
    return cached.data[variable.toUpperCase()];
  } else if (variable in cached.data) {
    return cached.data[variable];
  }
}
843727
def get_var(self, name):
        
        if name not in self._vars:
            raise VarNotDefinedError

        return self._vars[name]
66688
def _get_variables(self):
        """"""
        if self._specs_in[_VARIABLES_STR] == 'all':
            return _get_all_objs_of_type(
                Var, getattr(self._obj_lib, 'variables', self._obj_lib)
            )
        else:
            return set(self._specs_in[_VARIABLES_STR])
308346
def getName(self, value, defaultName = None):
        '''
        
        '''
        for k,v in self._values.items():
            if v == value:
                return k
        return defaultName
1274357
def variable(self, name: str, default_value=None):
        
        return self.__variables.get(name, default_value)
527711
def _get_value(self, var):
        """"""
        return self._problem._cp.solution.get_values(
            self._problem._variables[var])
108863
def _get_value(self, var):
        """"""
        return self._problem._p.get_value(self._problem._variables[var])
968120
def get_unique_variable_names(text, nb):
    ''''''
    base_name = '__VAR_'
    var_names = []
    i = 0
    j = 0
    while j < nb:
        tentative_name = base_name + str(i)
        if text.count(tentative_name) == 0 and tentative_name not in ALL_NAMES:
            var_names.append(tentative_name)
            ALL_NAMES.append(tentative_name)
            j += 1
        i += 1
    return var_names
891290
def get_variable(self, name):
        
        name = get_op_tensor_name(name)[1]
        if len(self.vs_name):
            name_with_vs = self.vs_name + "/" + name
        else:
            name_with_vs = name
        return get_op_or_tensor_by_name(name_with_vs)
1347456
Variable getVariable(String name) {
    VarKey varKey = VarKey.create(Kind.USER_DEFINED, name);
    return getVariable(varKey);
  }