Gets the identifier from the provided data object.
@param data The data object.
@return {string} identifier The identifier.
@private
324611
function _getIdentifier(data) {
        let identifier;
        if (typeof data === 'string') { // name of the mock
            identifier = data;
        } else if (data.name) { // the data containing the name of the mock
            identifier = data.name;
        } else {
            identifier = data.expression + '$$' + data.method;
        }
        return identifier;
    }
1087180
function(data) {

    var _mode = QRMode.MODE_NUMBER;
    var _data = data;

    var _this = {};

    _this.getMode = function() {
      return _mode;
    };

    _this.getLength = function(buffer) {
      return _data.length;
    };

    _this.write = function(buffer) {

      var data = _data;

      var i = 0;

      while (i + 2 < data.length) {
        buffer.put(strToNum(data.substring(i, i + 3) ), 10);
        i += 3;
      }

      if (i < data.length) {
        if (data.length - i == 1) {
          buffer.put(strToNum(data.substring(i, i + 1) ), 4);
        } else if (data.length - i == 2) {
          buffer.put(strToNum(data.substring(i, i + 2) ), 7);
        }
      }
    };

    var strToNum = function(s) {
      var num = 0;
      for (var i = 0; i < s.length; i += 1) {
        num = num * 10 + chatToNum(s.charAt(i) );
      }
      return num;
    };

    var chatToNum = function(c) {
      if ('0' <= c && c <= '9') {
        return c.charCodeAt(0) - '0'.charCodeAt(0);
      }
      throw 'illegal char :' + c;
    };

    return _this;
  }
1320818
function getFirstAndLastName(data) {
    var names = data.split(" ");
    if (names && names.length >= 2) {
        var firstName = names[0];
        var lastName = names[1];
        if (firstName && lastName) {
            var text = firstName.substr(0, 1) + lastName.substr(0, 1);
            return text;
        }
        else {
            return data.substr(0, 2);
        }
    }
}
360573
function parseVariableIdentifier() {
        var token = lex();

        if (token.type !== Token.Identifier) {
            throwUnexpected(token);
        }

        return {
            type: Syntax.Identifier,
            name: token.value
        };
    }
1018982
function stringInterner() { // eslint-disable-line no-unused-vars
  const strings = [];
  const ids = {};
  return {
    intern: function internString(s) {
      const find = ids[s];
      if (find === undefined) {
        const id = strings.length;
        ids[s] = id;
        strings.push(s);
        return id;
      } else {
        return find;
      }
    },
    get: function getString(id) {
      return strings[id];
    },
  };
}
856827
function(data) {
      return proto.encodeStrict(data.a, data.b, data.c, data.d);
    }
66138
public function getObjectIdentifierFromData(array $data) : array
    {
        $identifier = [];

        foreach ($this->class->getIdentifier() as $name) {
            $identifier[$name] = $data[$name];
        }

        return $identifier;
    }
441927
private static String getIdentifier(String target) {

        // check map
        String id = LOCATION_IDENTIFIER_MAP.get(target);
        if (id == null) {
            id = LOCATION_IDENTIFIER_PREFIX + target;
            LOCATION_IDENTIFIER_MAP.put(target, id);
        }
        return id;

    }
1055656
function (data) {
    var str = '', start = true;
    var jsondata = '';
    for (var key in data) {
      if (typeof (jsondata = JSON.stringify(data[key])) === 'string') {
        str += (start? '': '&');
        str += encodeURIComponent(key) + '=' + encodeURIComponent(jsondata);
        if (start) { start = false; }
      }
    }
    return str;
  }
695443
function(data) {
		if( typeof data == "string" ) {
			var transformed = {};
			$.each(data.split(/\s/), function() {
				transformed[this] = true;
			});
			data = transformed;
		}
		return data;
	}
466745
public static Object getId(Object object) {
		Objects.nonNull(object);
		try {
			Field idField = getIdField(object.getClass());
			if (idField == null) throw new IllegalArgumentException(object.getClass().getName() + " has no id field to get");
			Object id = idField.get(object);
			return id;
		} catch (SecurityException | IllegalAccessException e) {
			throw new LoggingRuntimeException(e, logger, "getting Id failed");
		}
	}
250843
function (identifier) {
            var self = this;

            return this.findByIdentifier(identifier).then(function (record) {
                if (!record) {
                    throw new Errors.NotFoundError(
                        'Could not find %s with identifier %s'.format(
                            pluralize.singular(self.identity),
                            identifier
                        ), {
                            identifier: identifier,
                            collection: self.identity
                        });
                }

                return record;
            });
        }
1243433
function id(d) {

    if (!d.d3plus.id) {
      d.d3plus.id = "";
      for (var i = 0; i <= vars.depth.value; i++) {
        d.d3plus.id += fetchValue(vars,d,vars.id.nesting[i])+"_"
      }

      d.d3plus.id += shape;

      ["x", "y", "x2", "y2"].forEach(function(axis){
        if (vars[axis].scale.value == "discrete") {
          var val = fetchValue(vars, d, vars[axis].value)
          if (val.constructor === Date) val = val.getTime()
          d.d3plus.id += "_"+val
        }
      })

      if (d.d3plus.suffix) {
        d.d3plus.id += "_" + d.d3plus.suffix;
      }

      d.d3plus.id = stringStrip(d.d3plus.id)
    }

    return d
  }
1335614
protected Identifier identifier(Data data, boolean firstCanBeNumber, boolean upper) {
	Position start = data.srcCode.getPosition();
	if (!data.srcCode.isCurrentLetter() && !data.srcCode.isCurrentSpecial()) {
	    if (!firstCanBeNumber) return null;
	    else if (!data.srcCode.isCurrentBetween('0', '9')) return null;
	}
	do {
	    data.srcCode.next();
	    if (!(data.srcCode.isCurrentLetter() || data.srcCode.isCurrentBetween('0', '9') || data.srcCode.isCurrentSpecial())) {
		break;
	    }
	}
	while (data.srcCode.isValidIndex());
	return Identifier.toIdentifier(data.factory, data.srcCode.substring(start.pos, data.srcCode.getPos() - start.pos),
		upper && data.settings.dotNotationUpper ? Identifier.CASE_UPPER : Identifier.CASE_ORIGNAL, start, data.srcCode.getPosition());
    }
77746
public function name($data) {
		if (is_object($data) && isset($data->type)) {
			return $data->value;
		}
		if ($data === '*') {
			return '*';
		}
		if (is_array($data)) {
			foreach ($data as $i => $dataItem) {
				$data[$i] = $this->name($dataItem);
			}
			return $data;
		}
		return (string)$data;
	}
105801
public String get_user(Map<String, String> data) {
        String id = data.get("email");
        return get("user/" + id, EMPTY_STRING);
    }
673815
public String checkIn(byte[] data) {
        String id = UUID.randomUUID().toString();
        dataMap.put(id, data);
        return id;
    }