Returns the initial of given name.
For standard names: "First [Midddles] Last", returns capital "FL";
For others, returns substr(0, 2).

@param {string} name -
@return {string} - initial
766
function getNameInitial(name) {
		var namePart = name.split(' ');
		if (namePart.length >= 2) {
			return (namePart[0].charAt(0) + namePart[namePart.length - 1].charAt(0)).toUpperCase();
		} else {
			return name.substr(0, 2);
		}
	}
40125
String getName() {
        int idx = mName.lastIndexOf('/');
        return (idx > 0) ? mName.substring(idx) : mName;
    }
951736
public function getFirstName() : ?string 
    {
        if ( ! $this->hasFirstName()) {
            $this->setFirstName($this->getDefaultFirstName());
        }
        return $this->firstName;
    }
1162711
function(name) {
			if (typeof name === 'number') {
				return this.list()[name];
			}
			
			if (typeof name === 'string') {
				return utils.find(this.list(), function(prop) {
					return prop.name() === name;
				});
			}
			
			return name;
		}
644441
public static String getFirstLowerName(String name) {
        if (StringUtils.isBlank(name)) {
            return null;
        }
        String firstChar = name.substring(0, 1).toLowerCase();
        return firstChar + name.substring(1);
    }
452313
public String toFirstLower(String name) {
		if (name.length() == 0) {
			return name;
		} else {
			return name.substring(0, 1).toLowerCase() + name.substring(1);
		}
	}
1277022
function(name) {
		var i, lookup;

		// Replace diacritics
		lookup = [
			/[\300-\306]/g, 'A', /[\340-\346]/g, 'a',
			/\307/g, 'C', /\347/g, 'c',
			/[\310-\313]/g, 'E', /[\350-\353]/g, 'e',
			/[\314-\317]/g, 'I', /[\354-\357]/g, 'i',
			/\321/g, 'N', /\361/g, 'n',
			/[\322-\330]/g, 'O', /[\362-\370]/g, 'o',
			/[\331-\334]/g, 'U', /[\371-\374]/g, 'u'
		];

		for (i = 0; i < lookup.length; i += 2) {
			name = name.replace(lookup[i], lookup[i + 1]);
		}

		// Replace whitespace
		name = name.replace(/\s+/g, '_');

		// Remove anything else
		name = name.replace(/[^a-z0-9_\-\.]+/gi, '');

		return name;
	}
713301
function (name) {
    name = name.trim();
    if (!name) {
        return name;
    }
    //首字母如果是大写，不转义为_x
    name = name[0].toLowerCase() + name.substr(1);
    return name.replace(/[A-Z]/g, function (a) {
        return '_' + a.toLowerCase();
    });
}
227667
private int getInitInt(String name)
    {
        String value = getInitParameter(name);
        if (value != null && value.length() > 0)
            return Integer.parseInt(value);
        return -1;
    }
546480
def get_initial(self, form, name):
        

        if hasattr(form, 'initial'):
            return form.initial.get(name, None)
        return None
70588
def extract_middle(name)
      return unless name && name.size >= 1

      (name.size - 1).downto(0) do |n|
        next unless name[n]

        if name[n] =~ Nameable::Latin::Patterns::LAST_NAME_PRE_DANGLERS
          @last = "#{name[n].downcase.capitalize} #{@last}"
        elsif name[n] =~ Nameable::Latin::Patterns::O_LAST_NAME_PRE_CONCATS
          @last = "O'#{@last}"
        elsif name[n] =~ /\-/ && n > 0 && name[n - 1]
          @last = "#{name[n - 1].delete('-')}-#{@last}"
          name[n - 1] = nil
        else
          @middle = @middle ? "#{name[n]} #{@middle}" : name[n]
        end

        name.delete_at(n)
      end

      @middle.capitalize! if @middle && !(@middle =~ /[a-z]/ && @middle =~ /[A-Z]/)
      @middle = "#{@middle}." if @middle && @middle.size == 1
    end
697788
public String getValue(String name) {
		String result = null;
		for (InitParam initParam : initParams) {
			if (initParam.getName().equals(name)) {
				result = initParam.getValue();
				break;
			}
		}
		return result;
	}
1306088
def last_first(self):
        
        return "{}, {} ".format(self.last_name, self.first_name) + ("({})".format(self.nickname) if self.nickname else "")
333445
public int firstIndexOf(String name) {
    Integer index =
        (Strings.isDoubleQuoted(name))
            ? byCaseSensitiveName.get(Strings.unDoubleQuote(name))
            : byCaseInsensitiveName.get(name.toLowerCase());
    return (index == null) ? -1 : index;
  }
186478
public static String toFirstLower( String name ) {
        if ( isEmpty( name )) {
            return name;
        }
        return "" + name.toLowerCase( Locale.ROOT ).charAt(0) + name.substring(1);
    }
466226
function(name) {
        var parts = name.split(' ');
        parts[0] = parts[0].toLowerCase();
        for (var i = 1; i < parts.length; ++i) {
            parts[i] = parts[i].charAt(0).toUpperCase() + parts[i].substr(1);
        }
        return parts.join('');
    }
296902
private static String getTopVarName(String name) {
    int firstDotIndex = name.indexOf('.');
    return firstDotIndex == -1 ? name : name.substring(0, firstDotIndex);
  }