id int32 0 165k | repo stringlengths 7 58 | path stringlengths 12 218 | func_name stringlengths 3 140 | original_string stringlengths 73 34.1k | language stringclasses 1
value | code stringlengths 73 34.1k | code_tokens list | docstring stringlengths 3 16k | docstring_tokens list | sha stringlengths 40 40 | url stringlengths 105 339 |
|---|---|---|---|---|---|---|---|---|---|---|---|
33,000 | google/j2objc | translator/src/main/java/com/google/devtools/j2objc/util/NameTable.java | NameTable.getFunctionName | public String getFunctionName(ExecutableElement method) {
String name = ElementUtil.getSelector(method);
if (name == null) {
name = getRenamedMethodName(method);
}
if (name != null) {
return name.replaceAll(":", "_");
} else {
return addParamNames(method, getMethodName(method), '_'... | java | public String getFunctionName(ExecutableElement method) {
String name = ElementUtil.getSelector(method);
if (name == null) {
name = getRenamedMethodName(method);
}
if (name != null) {
return name.replaceAll(":", "_");
} else {
return addParamNames(method, getMethodName(method), '_'... | [
"public",
"String",
"getFunctionName",
"(",
"ExecutableElement",
"method",
")",
"{",
"String",
"name",
"=",
"ElementUtil",
".",
"getSelector",
"(",
"method",
")",
";",
"if",
"(",
"name",
"==",
"null",
")",
"{",
"name",
"=",
"getRenamedMethodName",
"(",
"meth... | Returns an appropriate name to use for this method as a function. This name
is guaranteed to be unique within the declaring class, if no methods in the
class have a renaming. The returned name should be given an appropriate
prefix to avoid collisions with methods from other classes. | [
"Returns",
"an",
"appropriate",
"name",
"to",
"use",
"for",
"this",
"method",
"as",
"a",
"function",
".",
"This",
"name",
"is",
"guaranteed",
"to",
"be",
"unique",
"within",
"the",
"declaring",
"class",
"if",
"no",
"methods",
"in",
"the",
"class",
"have",
... | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/translator/src/main/java/com/google/devtools/j2objc/util/NameTable.java#L439-L449 |
33,001 | google/j2objc | translator/src/main/java/com/google/devtools/j2objc/util/NameTable.java | NameTable.getPrimitiveObjCType | public static String getPrimitiveObjCType(TypeMirror type) {
return TypeUtil.isVoid(type) ? "void"
: type.getKind().isPrimitive() ? "j" + TypeUtil.getName(type) : "id";
} | java | public static String getPrimitiveObjCType(TypeMirror type) {
return TypeUtil.isVoid(type) ? "void"
: type.getKind().isPrimitive() ? "j" + TypeUtil.getName(type) : "id";
} | [
"public",
"static",
"String",
"getPrimitiveObjCType",
"(",
"TypeMirror",
"type",
")",
"{",
"return",
"TypeUtil",
".",
"isVoid",
"(",
"type",
")",
"?",
"\"void\"",
":",
"type",
".",
"getKind",
"(",
")",
".",
"isPrimitive",
"(",
")",
"?",
"\"j\"",
"+",
"Ty... | Converts a Java type to an equivalent Objective-C type, returning "id" for an object type. | [
"Converts",
"a",
"Java",
"type",
"to",
"an",
"equivalent",
"Objective",
"-",
"C",
"type",
"returning",
"id",
"for",
"an",
"object",
"type",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/translator/src/main/java/com/google/devtools/j2objc/util/NameTable.java#L505-L508 |
33,002 | google/j2objc | translator/src/main/java/com/google/devtools/j2objc/util/NameTable.java | NameTable.getJniType | public String getJniType(TypeMirror type) {
if (TypeUtil.isPrimitiveOrVoid(type)) {
return getPrimitiveObjCType(type);
} else if (TypeUtil.isArray(type)) {
return "jarray";
} else if (typeUtil.isString(type)) {
return "jstring";
} else if (typeUtil.isClassType(type)) {
return "jc... | java | public String getJniType(TypeMirror type) {
if (TypeUtil.isPrimitiveOrVoid(type)) {
return getPrimitiveObjCType(type);
} else if (TypeUtil.isArray(type)) {
return "jarray";
} else if (typeUtil.isString(type)) {
return "jstring";
} else if (typeUtil.isClassType(type)) {
return "jc... | [
"public",
"String",
"getJniType",
"(",
"TypeMirror",
"type",
")",
"{",
"if",
"(",
"TypeUtil",
".",
"isPrimitiveOrVoid",
"(",
"type",
")",
")",
"{",
"return",
"getPrimitiveObjCType",
"(",
"type",
")",
";",
"}",
"else",
"if",
"(",
"TypeUtil",
".",
"isArray",... | Convert a Java type into the equivalent JNI type. | [
"Convert",
"a",
"Java",
"type",
"into",
"the",
"equivalent",
"JNI",
"type",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/translator/src/main/java/com/google/devtools/j2objc/util/NameTable.java#L525-L536 |
33,003 | google/j2objc | translator/src/main/java/com/google/devtools/j2objc/util/NameTable.java | NameTable.getFullName | public String getFullName(TypeElement element) {
element = typeUtil.getObjcClass(element);
String fullName = fullNameCache.get(element);
if (fullName == null) {
fullName = getFullNameImpl(element);
fullNameCache.put(element, fullName);
}
return fullName;
} | java | public String getFullName(TypeElement element) {
element = typeUtil.getObjcClass(element);
String fullName = fullNameCache.get(element);
if (fullName == null) {
fullName = getFullNameImpl(element);
fullNameCache.put(element, fullName);
}
return fullName;
} | [
"public",
"String",
"getFullName",
"(",
"TypeElement",
"element",
")",
"{",
"element",
"=",
"typeUtil",
".",
"getObjcClass",
"(",
"element",
")",
";",
"String",
"fullName",
"=",
"fullNameCache",
".",
"get",
"(",
"element",
")",
";",
"if",
"(",
"fullName",
... | Return the full name of a type, including its package. For outer types,
is the type's full name; for example, java.lang.Object's full name is
"JavaLangObject". For inner classes, the full name is their outer class'
name plus the inner class name; for example, java.util.ArrayList.ListItr's
name is "JavaUtilArrayList_L... | [
"Return",
"the",
"full",
"name",
"of",
"a",
"type",
"including",
"its",
"package",
".",
"For",
"outer",
"types",
"is",
"the",
"type",
"s",
"full",
"name",
";",
"for",
"example",
"java",
".",
"lang",
".",
"Object",
"s",
"full",
"name",
"is",
"JavaLangOb... | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/translator/src/main/java/com/google/devtools/j2objc/util/NameTable.java#L593-L601 |
33,004 | google/j2objc | translator/src/main/java/com/google/devtools/j2objc/util/NameTable.java | NameTable.getDefaultObjectiveCName | private String getDefaultObjectiveCName(TypeElement element) {
String binaryName = elementUtil.getBinaryName(element);
return camelCaseQualifiedName(binaryName).replace('$', '_');
} | java | private String getDefaultObjectiveCName(TypeElement element) {
String binaryName = elementUtil.getBinaryName(element);
return camelCaseQualifiedName(binaryName).replace('$', '_');
} | [
"private",
"String",
"getDefaultObjectiveCName",
"(",
"TypeElement",
"element",
")",
"{",
"String",
"binaryName",
"=",
"elementUtil",
".",
"getBinaryName",
"(",
"element",
")",
";",
"return",
"camelCaseQualifiedName",
"(",
"binaryName",
")",
".",
"replace",
"(",
"... | Ignores the ObjectiveCName annotation. | [
"Ignores",
"the",
"ObjectiveCName",
"annotation",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/translator/src/main/java/com/google/devtools/j2objc/util/NameTable.java#L656-L659 |
33,005 | google/j2objc | xalan/third_party/android/platform/external/apache-xml/src/main/java/org/apache/xml/utils/NodeVector.java | NodeVector.pushPair | public final void pushPair(int v1, int v2)
{
if (null == m_map)
{
m_map = new int[m_blocksize];
m_mapSize = m_blocksize;
}
else
{
if ((m_firstFree + 2) >= m_mapSize)
{
m_mapSize += m_blocksize;
int newMap[] = new int[m_mapSize];
System.arraycopy(m... | java | public final void pushPair(int v1, int v2)
{
if (null == m_map)
{
m_map = new int[m_blocksize];
m_mapSize = m_blocksize;
}
else
{
if ((m_firstFree + 2) >= m_mapSize)
{
m_mapSize += m_blocksize;
int newMap[] = new int[m_mapSize];
System.arraycopy(m... | [
"public",
"final",
"void",
"pushPair",
"(",
"int",
"v1",
",",
"int",
"v2",
")",
"{",
"if",
"(",
"null",
"==",
"m_map",
")",
"{",
"m_map",
"=",
"new",
"int",
"[",
"m_blocksize",
"]",
";",
"m_mapSize",
"=",
"m_blocksize",
";",
"}",
"else",
"{",
"if",... | Push a pair of nodes into the stack.
Special purpose method for TransformerImpl, pushElemTemplateElement.
Performance critical.
@param v1 First node to add to vector
@param v2 Second node to add to vector | [
"Push",
"a",
"pair",
"of",
"nodes",
"into",
"the",
"stack",
".",
"Special",
"purpose",
"method",
"for",
"TransformerImpl",
"pushElemTemplateElement",
".",
"Performance",
"critical",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/xalan/third_party/android/platform/external/apache-xml/src/main/java/org/apache/xml/utils/NodeVector.java#L244-L269 |
33,006 | google/j2objc | xalan/third_party/android/platform/external/apache-xml/src/main/java/org/apache/xml/utils/NodeVector.java | NodeVector.popPair | public final void popPair()
{
m_firstFree -= 2;
m_map[m_firstFree] = DTM.NULL;
m_map[m_firstFree + 1] = DTM.NULL;
} | java | public final void popPair()
{
m_firstFree -= 2;
m_map[m_firstFree] = DTM.NULL;
m_map[m_firstFree + 1] = DTM.NULL;
} | [
"public",
"final",
"void",
"popPair",
"(",
")",
"{",
"m_firstFree",
"-=",
"2",
";",
"m_map",
"[",
"m_firstFree",
"]",
"=",
"DTM",
".",
"NULL",
";",
"m_map",
"[",
"m_firstFree",
"+",
"1",
"]",
"=",
"DTM",
".",
"NULL",
";",
"}"
] | Pop a pair of nodes from the tail of the stack.
Special purpose method for TransformerImpl, pushElemTemplateElement.
Performance critical. | [
"Pop",
"a",
"pair",
"of",
"nodes",
"from",
"the",
"tail",
"of",
"the",
"stack",
".",
"Special",
"purpose",
"method",
"for",
"TransformerImpl",
"pushElemTemplateElement",
".",
"Performance",
"critical",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/xalan/third_party/android/platform/external/apache-xml/src/main/java/org/apache/xml/utils/NodeVector.java#L276-L282 |
33,007 | google/j2objc | xalan/third_party/android/platform/external/apache-xml/src/main/java/org/apache/xml/utils/NodeVector.java | NodeVector.insertInOrder | public void insertInOrder(int value)
{
for (int i = 0; i < m_firstFree; i++)
{
if (value < m_map[i])
{
insertElementAt(value, i);
return;
}
}
addElement(value);
} | java | public void insertInOrder(int value)
{
for (int i = 0; i < m_firstFree; i++)
{
if (value < m_map[i])
{
insertElementAt(value, i);
return;
}
}
addElement(value);
} | [
"public",
"void",
"insertInOrder",
"(",
"int",
"value",
")",
"{",
"for",
"(",
"int",
"i",
"=",
"0",
";",
"i",
"<",
"m_firstFree",
";",
"i",
"++",
")",
"{",
"if",
"(",
"value",
"<",
"m_map",
"[",
"i",
"]",
")",
"{",
"insertElementAt",
"(",
"value"... | Insert a node in order in the list.
@param value Node to insert | [
"Insert",
"a",
"node",
"in",
"order",
"in",
"the",
"list",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/xalan/third_party/android/platform/external/apache-xml/src/main/java/org/apache/xml/utils/NodeVector.java#L337-L351 |
33,008 | google/j2objc | xalan/third_party/android/platform/external/apache-xml/src/main/java/org/apache/xml/utils/NodeVector.java | NodeVector.sort | public void sort(int a[], int lo0, int hi0) throws Exception
{
int lo = lo0;
int hi = hi0;
// pause(lo, hi);
if (lo >= hi)
{
return;
}
else if (lo == hi - 1)
{
/*
* sort a two element list by swapping if necessary
*/
if (a[lo] > a[hi])
{
... | java | public void sort(int a[], int lo0, int hi0) throws Exception
{
int lo = lo0;
int hi = hi0;
// pause(lo, hi);
if (lo >= hi)
{
return;
}
else if (lo == hi - 1)
{
/*
* sort a two element list by swapping if necessary
*/
if (a[lo] > a[hi])
{
... | [
"public",
"void",
"sort",
"(",
"int",
"a",
"[",
"]",
",",
"int",
"lo0",
",",
"int",
"hi0",
")",
"throws",
"Exception",
"{",
"int",
"lo",
"=",
"lo0",
";",
"int",
"hi",
"=",
"hi0",
";",
"// pause(lo, hi);",
"if",
"(",
"lo",
">=",
"hi",
")",
"{",
... | Sort an array using a quicksort algorithm.
@param a The array to be sorted.
@param lo0 The low index.
@param hi0 The high index.
@throws Exception | [
"Sort",
"an",
"array",
"using",
"a",
"quicksort",
"algorithm",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/xalan/third_party/android/platform/external/apache-xml/src/main/java/org/apache/xml/utils/NodeVector.java#L640-L728 |
33,009 | google/j2objc | jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/text/RelativeDateTimeFormatter.java | RelativeDateTimeFormatter.getInstance | public static RelativeDateTimeFormatter getInstance(ULocale locale) {
return getInstance(locale, null, Style.LONG, DisplayContext.CAPITALIZATION_NONE);
} | java | public static RelativeDateTimeFormatter getInstance(ULocale locale) {
return getInstance(locale, null, Style.LONG, DisplayContext.CAPITALIZATION_NONE);
} | [
"public",
"static",
"RelativeDateTimeFormatter",
"getInstance",
"(",
"ULocale",
"locale",
")",
"{",
"return",
"getInstance",
"(",
"locale",
",",
"null",
",",
"Style",
".",
"LONG",
",",
"DisplayContext",
".",
"CAPITALIZATION_NONE",
")",
";",
"}"
] | Returns a RelativeDateTimeFormatter for a particular locale.
@param locale the locale.
@return An instance of RelativeDateTimeFormatter. | [
"Returns",
"a",
"RelativeDateTimeFormatter",
"for",
"a",
"particular",
"locale",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/text/RelativeDateTimeFormatter.java#L370-L372 |
33,010 | google/j2objc | jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/text/RelativeDateTimeFormatter.java | RelativeDateTimeFormatter.getInstance | public static RelativeDateTimeFormatter getInstance(ULocale locale, NumberFormat nf) {
return getInstance(locale, nf, Style.LONG, DisplayContext.CAPITALIZATION_NONE);
} | java | public static RelativeDateTimeFormatter getInstance(ULocale locale, NumberFormat nf) {
return getInstance(locale, nf, Style.LONG, DisplayContext.CAPITALIZATION_NONE);
} | [
"public",
"static",
"RelativeDateTimeFormatter",
"getInstance",
"(",
"ULocale",
"locale",
",",
"NumberFormat",
"nf",
")",
"{",
"return",
"getInstance",
"(",
"locale",
",",
"nf",
",",
"Style",
".",
"LONG",
",",
"DisplayContext",
".",
"CAPITALIZATION_NONE",
")",
"... | Returns a RelativeDateTimeFormatter for a particular locale that uses a particular
NumberFormat object.
@param locale the locale
@param nf the number format object. It is defensively copied to ensure thread-safety
and immutability of this class.
@return An instance of RelativeDateTimeFormatter. | [
"Returns",
"a",
"RelativeDateTimeFormatter",
"for",
"a",
"particular",
"locale",
"that",
"uses",
"a",
"particular",
"NumberFormat",
"object",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/text/RelativeDateTimeFormatter.java#L393-L395 |
33,011 | google/j2objc | jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/text/RelativeDateTimeFormatter.java | RelativeDateTimeFormatter.getInstance | public static RelativeDateTimeFormatter getInstance(
ULocale locale,
NumberFormat nf,
Style style,
DisplayContext capitalizationContext) {
RelativeDateTimeFormatterData data = cache.get(locale);
if (nf == null) {
nf = NumberFormat.getInstance(l... | java | public static RelativeDateTimeFormatter getInstance(
ULocale locale,
NumberFormat nf,
Style style,
DisplayContext capitalizationContext) {
RelativeDateTimeFormatterData data = cache.get(locale);
if (nf == null) {
nf = NumberFormat.getInstance(l... | [
"public",
"static",
"RelativeDateTimeFormatter",
"getInstance",
"(",
"ULocale",
"locale",
",",
"NumberFormat",
"nf",
",",
"Style",
"style",
",",
"DisplayContext",
"capitalizationContext",
")",
"{",
"RelativeDateTimeFormatterData",
"data",
"=",
"cache",
".",
"get",
"("... | Returns a RelativeDateTimeFormatter for a particular locale that uses a particular
NumberFormat object, style, and capitalization context
@param locale the locale
@param nf the number format object. It is defensively copied to ensure thread-safety
and immutability of this class. May be null.
@param style the style.
@p... | [
"Returns",
"a",
"RelativeDateTimeFormatter",
"for",
"a",
"particular",
"locale",
"that",
"uses",
"a",
"particular",
"NumberFormat",
"object",
"style",
"and",
"capitalization",
"context"
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/text/RelativeDateTimeFormatter.java#L407-L430 |
33,012 | google/j2objc | jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/text/RelativeDateTimeFormatter.java | RelativeDateTimeFormatter.format | public String format(double quantity, Direction direction, RelativeUnit unit) {
if (direction != Direction.LAST && direction != Direction.NEXT) {
throw new IllegalArgumentException("direction must be NEXT or LAST");
}
String result;
int pastFutureIndex = (direction == Directi... | java | public String format(double quantity, Direction direction, RelativeUnit unit) {
if (direction != Direction.LAST && direction != Direction.NEXT) {
throw new IllegalArgumentException("direction must be NEXT or LAST");
}
String result;
int pastFutureIndex = (direction == Directi... | [
"public",
"String",
"format",
"(",
"double",
"quantity",
",",
"Direction",
"direction",
",",
"RelativeUnit",
"unit",
")",
"{",
"if",
"(",
"direction",
"!=",
"Direction",
".",
"LAST",
"&&",
"direction",
"!=",
"Direction",
".",
"NEXT",
")",
"{",
"throw",
"ne... | Formats a relative date with a quantity such as "in 5 days" or
"3 months ago"
@param quantity The numerical amount e.g 5. This value is formatted
according to this object's {@link NumberFormat} object.
@param direction NEXT means a future relative date; LAST means a past
relative date.
@param unit the unit e.g day? mon... | [
"Formats",
"a",
"relative",
"date",
"with",
"a",
"quantity",
"such",
"as",
"in",
"5",
"days",
"or",
"3",
"months",
"ago"
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/text/RelativeDateTimeFormatter.java#L457-L477 |
33,013 | google/j2objc | jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/text/RelativeDateTimeFormatter.java | RelativeDateTimeFormatter.format | public String format(Direction direction, AbsoluteUnit unit) {
if (unit == AbsoluteUnit.NOW && direction != Direction.PLAIN) {
throw new IllegalArgumentException("NOW can only accept direction PLAIN.");
}
String result;
// Get plain day of week names from DateFormatSymbols.
... | java | public String format(Direction direction, AbsoluteUnit unit) {
if (unit == AbsoluteUnit.NOW && direction != Direction.PLAIN) {
throw new IllegalArgumentException("NOW can only accept direction PLAIN.");
}
String result;
// Get plain day of week names from DateFormatSymbols.
... | [
"public",
"String",
"format",
"(",
"Direction",
"direction",
",",
"AbsoluteUnit",
"unit",
")",
"{",
"if",
"(",
"unit",
"==",
"AbsoluteUnit",
".",
"NOW",
"&&",
"direction",
"!=",
"Direction",
".",
"PLAIN",
")",
"{",
"throw",
"new",
"IllegalArgumentException",
... | Formats a relative date without a quantity.
@param direction NEXT, LAST, THIS, etc.
@param unit e.g SATURDAY, DAY, MONTH
@return the formatted string. If direction has a value that is documented as not being
fully supported in every locale (for example NEXT_2 or LAST_2) then this function may
return null to signal that... | [
"Formats",
"a",
"relative",
"date",
"without",
"a",
"quantity",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/text/RelativeDateTimeFormatter.java#L537-L556 |
33,014 | google/j2objc | jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/text/RelativeDateTimeFormatter.java | RelativeDateTimeFormatter.getAbsoluteUnitString | private String getAbsoluteUnitString(Style style, AbsoluteUnit unit, Direction direction) {
EnumMap<AbsoluteUnit, EnumMap<Direction, String>> unitMap;
EnumMap<Direction, String> dirMap;
do {
unitMap = qualitativeUnitMap.get(style);
if (unitMap != null) {
... | java | private String getAbsoluteUnitString(Style style, AbsoluteUnit unit, Direction direction) {
EnumMap<AbsoluteUnit, EnumMap<Direction, String>> unitMap;
EnumMap<Direction, String> dirMap;
do {
unitMap = qualitativeUnitMap.get(style);
if (unitMap != null) {
... | [
"private",
"String",
"getAbsoluteUnitString",
"(",
"Style",
"style",
",",
"AbsoluteUnit",
"unit",
",",
"Direction",
"direction",
")",
"{",
"EnumMap",
"<",
"AbsoluteUnit",
",",
"EnumMap",
"<",
"Direction",
",",
"String",
">",
">",
"unitMap",
";",
"EnumMap",
"<"... | Gets the string value from qualitativeUnitMap with fallback based on style. | [
"Gets",
"the",
"string",
"value",
"from",
"qualitativeUnitMap",
"with",
"fallback",
"based",
"on",
"style",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/text/RelativeDateTimeFormatter.java#L636-L657 |
33,015 | google/j2objc | jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/text/RelativeDateTimeFormatter.java | RelativeDateTimeFormatter.combineDateAndTime | public String combineDateAndTime(String relativeDateString, String timeString) {
return SimpleFormatterImpl.formatCompiledPattern(
combinedDateAndTime, timeString, relativeDateString);
} | java | public String combineDateAndTime(String relativeDateString, String timeString) {
return SimpleFormatterImpl.formatCompiledPattern(
combinedDateAndTime, timeString, relativeDateString);
} | [
"public",
"String",
"combineDateAndTime",
"(",
"String",
"relativeDateString",
",",
"String",
"timeString",
")",
"{",
"return",
"SimpleFormatterImpl",
".",
"formatCompiledPattern",
"(",
"combinedDateAndTime",
",",
"timeString",
",",
"relativeDateString",
")",
";",
"}"
] | Combines a relative date string and a time string in this object's
locale. This is done with the same date-time separator used for the
default calendar in this locale.
@param relativeDateString the relative date e.g 'yesterday'
@param timeString the time e.g '3:45'
@return the date and time concatenated according to th... | [
"Combines",
"a",
"relative",
"date",
"string",
"and",
"a",
"time",
"string",
"in",
"this",
"object",
"s",
"locale",
".",
"This",
"is",
"done",
"with",
"the",
"same",
"date",
"-",
"time",
"separator",
"used",
"for",
"the",
"default",
"calendar",
"in",
"th... | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/text/RelativeDateTimeFormatter.java#L668-L671 |
33,016 | google/j2objc | translator/src/main/java/com/google/devtools/j2objc/translate/NilCheckResolver.java | NilCheckResolver.handleThrows | private void handleThrows() {
Scope curScope = scope;
while (curScope != null) {
if (curScope.kind == Scope.Kind.TRY) {
scope.mergeInto(curScope.next);
}
curScope = curScope.next;
}
} | java | private void handleThrows() {
Scope curScope = scope;
while (curScope != null) {
if (curScope.kind == Scope.Kind.TRY) {
scope.mergeInto(curScope.next);
}
curScope = curScope.next;
}
} | [
"private",
"void",
"handleThrows",
"(",
")",
"{",
"Scope",
"curScope",
"=",
"scope",
";",
"while",
"(",
"curScope",
"!=",
"null",
")",
"{",
"if",
"(",
"curScope",
".",
"kind",
"==",
"Scope",
".",
"Kind",
".",
"TRY",
")",
"{",
"scope",
".",
"mergeInto... | scope of each try block. | [
"scope",
"of",
"each",
"try",
"block",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/translator/src/main/java/com/google/devtools/j2objc/translate/NilCheckResolver.java#L328-L336 |
33,017 | google/j2objc | translator/src/main/java/com/google/devtools/j2objc/translate/NilCheckResolver.java | NilCheckResolver.isBoxingMethod | private boolean isBoxingMethod(ExecutableElement method) {
TypeElement declaringClass = ElementUtil.getDeclaringClass(method);
// Autoboxing methods.
if (typeUtil.isBoxedType(declaringClass.asType())) {
String name = ElementUtil.getName(method);
TypeMirror returnType = method.getReturnType();
... | java | private boolean isBoxingMethod(ExecutableElement method) {
TypeElement declaringClass = ElementUtil.getDeclaringClass(method);
// Autoboxing methods.
if (typeUtil.isBoxedType(declaringClass.asType())) {
String name = ElementUtil.getName(method);
TypeMirror returnType = method.getReturnType();
... | [
"private",
"boolean",
"isBoxingMethod",
"(",
"ExecutableElement",
"method",
")",
"{",
"TypeElement",
"declaringClass",
"=",
"ElementUtil",
".",
"getDeclaringClass",
"(",
"method",
")",
";",
"// Autoboxing methods.",
"if",
"(",
"typeUtil",
".",
"isBoxedType",
"(",
"d... | Checks if the given method is a primitive boxing or unboxing method. | [
"Checks",
"if",
"the",
"given",
"method",
"is",
"a",
"primitive",
"boxing",
"or",
"unboxing",
"method",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/translator/src/main/java/com/google/devtools/j2objc/translate/NilCheckResolver.java#L370-L387 |
33,018 | google/j2objc | translator/src/main/java/com/google/devtools/j2objc/translate/NilCheckResolver.java | NilCheckResolver.endVisit | @Override
public void endVisit(FunctionInvocation node) {
if (Objects.equals(node.getFunctionElement(), NIL_CHK_ELEM)) {
VariableElement var = TreeUtil.getVariableElement(node.getArgument(0));
if (var != null) {
addSafeVar(var);
}
}
} | java | @Override
public void endVisit(FunctionInvocation node) {
if (Objects.equals(node.getFunctionElement(), NIL_CHK_ELEM)) {
VariableElement var = TreeUtil.getVariableElement(node.getArgument(0));
if (var != null) {
addSafeVar(var);
}
}
} | [
"@",
"Override",
"public",
"void",
"endVisit",
"(",
"FunctionInvocation",
"node",
")",
"{",
"if",
"(",
"Objects",
".",
"equals",
"(",
"node",
".",
"getFunctionElement",
"(",
")",
",",
"NIL_CHK_ELEM",
")",
")",
"{",
"VariableElement",
"var",
"=",
"TreeUtil",
... | added nil_chk's. | [
"added",
"nil_chk",
"s",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/translator/src/main/java/com/google/devtools/j2objc/translate/NilCheckResolver.java#L814-L822 |
33,019 | google/j2objc | jre_emul/android/platform/libcore/ojluni/src/main/java/java/net/URLConnection.java | URLConnection.setRequestProperty | public void setRequestProperty(String key, String value) {
if (connected)
throw new IllegalStateException("Already connected");
if (key == null)
throw new NullPointerException ("key is null");
if (requests == null)
requests = new MessageHeader();
req... | java | public void setRequestProperty(String key, String value) {
if (connected)
throw new IllegalStateException("Already connected");
if (key == null)
throw new NullPointerException ("key is null");
if (requests == null)
requests = new MessageHeader();
req... | [
"public",
"void",
"setRequestProperty",
"(",
"String",
"key",
",",
"String",
"value",
")",
"{",
"if",
"(",
"connected",
")",
"throw",
"new",
"IllegalStateException",
"(",
"\"Already connected\"",
")",
";",
"if",
"(",
"key",
"==",
"null",
")",
"throw",
"new",... | Sets the general request property. If a property with the key already
exists, overwrite its value with the new value.
<p> NOTE: HTTP requires all request properties which can
legally have multiple instances with the same key
to use a comma-seperated list syntax which enables multiple
properties to be appended into a s... | [
"Sets",
"the",
"general",
"request",
"property",
".",
"If",
"a",
"property",
"with",
"the",
"key",
"already",
"exists",
"overwrite",
"its",
"value",
"with",
"the",
"new",
"value",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/libcore/ojluni/src/main/java/java/net/URLConnection.java#L1068-L1078 |
33,020 | google/j2objc | jre_emul/android/platform/libcore/ojluni/src/main/java/java/net/URLConnection.java | URLConnection.addRequestProperty | public void addRequestProperty(String key, String value) {
if (connected)
throw new IllegalStateException("Already connected");
if (key == null)
throw new NullPointerException ("key is null");
if (requests == null)
requests = new MessageHeader();
req... | java | public void addRequestProperty(String key, String value) {
if (connected)
throw new IllegalStateException("Already connected");
if (key == null)
throw new NullPointerException ("key is null");
if (requests == null)
requests = new MessageHeader();
req... | [
"public",
"void",
"addRequestProperty",
"(",
"String",
"key",
",",
"String",
"value",
")",
"{",
"if",
"(",
"connected",
")",
"throw",
"new",
"IllegalStateException",
"(",
"\"Already connected\"",
")",
";",
"if",
"(",
"key",
"==",
"null",
")",
"throw",
"new",... | Adds a general request property specified by a
key-value pair. This method will not overwrite
existing values associated with the same key.
@param key the keyword by which the request is known
(e.g., "<code>Accept</code>").
@param value the value associated with it.
@throws IllegalStateException if already c... | [
"Adds",
"a",
"general",
"request",
"property",
"specified",
"by",
"a",
"key",
"-",
"value",
"pair",
".",
"This",
"method",
"will",
"not",
"overwrite",
"existing",
"values",
"associated",
"with",
"the",
"same",
"key",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/libcore/ojluni/src/main/java/java/net/URLConnection.java#L1093-L1103 |
33,021 | google/j2objc | jre_emul/android/platform/libcore/ojluni/src/main/java/java/net/URLConnection.java | URLConnection.getRequestProperty | public String getRequestProperty(String key) {
if (connected)
throw new IllegalStateException("Already connected");
if (requests == null)
return null;
return requests.findValue(key);
} | java | public String getRequestProperty(String key) {
if (connected)
throw new IllegalStateException("Already connected");
if (requests == null)
return null;
return requests.findValue(key);
} | [
"public",
"String",
"getRequestProperty",
"(",
"String",
"key",
")",
"{",
"if",
"(",
"connected",
")",
"throw",
"new",
"IllegalStateException",
"(",
"\"Already connected\"",
")",
";",
"if",
"(",
"requests",
"==",
"null",
")",
"return",
"null",
";",
"return",
... | Returns the value of the named general request property for this
connection.
@param key the keyword by which the request is known (e.g., "Accept").
@return the value of the named general request property for this
connection. If key is null, then null is returned.
@throws IllegalStateException if already connected
@se... | [
"Returns",
"the",
"value",
"of",
"the",
"named",
"general",
"request",
"property",
"for",
"this",
"connection",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/libcore/ojluni/src/main/java/java/net/URLConnection.java#L1116-L1124 |
33,022 | google/j2objc | jre_emul/android/platform/libcore/ojluni/src/main/java/java/net/URLConnection.java | URLConnection.getRequestProperties | public Map<String,List<String>> getRequestProperties() {
if (connected)
throw new IllegalStateException("Already connected");
if (requests == null)
return Collections.EMPTY_MAP;
return requests.getHeaders(null);
} | java | public Map<String,List<String>> getRequestProperties() {
if (connected)
throw new IllegalStateException("Already connected");
if (requests == null)
return Collections.EMPTY_MAP;
return requests.getHeaders(null);
} | [
"public",
"Map",
"<",
"String",
",",
"List",
"<",
"String",
">",
">",
"getRequestProperties",
"(",
")",
"{",
"if",
"(",
"connected",
")",
"throw",
"new",
"IllegalStateException",
"(",
"\"Already connected\"",
")",
";",
"if",
"(",
"requests",
"==",
"null",
... | Returns an unmodifiable Map of general request
properties for this connection. The Map keys
are Strings that represent the request-header
field names. Each Map value is a unmodifiable List
of Strings that represents the corresponding
field values.
@return a Map of the general request properties for this connection.
@... | [
"Returns",
"an",
"unmodifiable",
"Map",
"of",
"general",
"request",
"properties",
"for",
"this",
"connection",
".",
"The",
"Map",
"keys",
"are",
"Strings",
"that",
"represent",
"the",
"request",
"-",
"header",
"field",
"names",
".",
"Each",
"Map",
"value",
"... | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/libcore/ojluni/src/main/java/java/net/URLConnection.java#L1138-L1146 |
33,023 | google/j2objc | jre_emul/android/platform/libcore/ojluni/src/main/java/java/net/URLConnection.java | URLConnection.getContentHandler | synchronized ContentHandler getContentHandler()
throws IOException
{
String contentType = stripOffParameters(getContentType());
ContentHandler handler = null;
if (contentType == null) {
if ((contentType = guessContentTypeFromName(url.getFile())) == null) {
... | java | synchronized ContentHandler getContentHandler()
throws IOException
{
String contentType = stripOffParameters(getContentType());
ContentHandler handler = null;
if (contentType == null) {
if ((contentType = guessContentTypeFromName(url.getFile())) == null) {
... | [
"synchronized",
"ContentHandler",
"getContentHandler",
"(",
")",
"throws",
"IOException",
"{",
"String",
"contentType",
"=",
"stripOffParameters",
"(",
"getContentType",
"(",
")",
")",
";",
"ContentHandler",
"handler",
"=",
"null",
";",
"if",
"(",
"contentType",
"... | Gets the Content Handler appropriate for this connection.
@param connection the connection to use. | [
"Gets",
"the",
"Content",
"Handler",
"appropriate",
"for",
"this",
"connection",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/libcore/ojluni/src/main/java/java/net/URLConnection.java#L1232-L1265 |
33,024 | google/j2objc | jre_emul/android/platform/libcore/ojluni/src/main/java/java/net/URLConnection.java | URLConnection.getContentHandlerPkgPrefixes | private String getContentHandlerPkgPrefixes() {
String packagePrefixList = System.getProperty(contentPathProp, "");
if (packagePrefixList != "") {
packagePrefixList += "|";
}
return packagePrefixList + contentClassPrefix;
} | java | private String getContentHandlerPkgPrefixes() {
String packagePrefixList = System.getProperty(contentPathProp, "");
if (packagePrefixList != "") {
packagePrefixList += "|";
}
return packagePrefixList + contentClassPrefix;
} | [
"private",
"String",
"getContentHandlerPkgPrefixes",
"(",
")",
"{",
"String",
"packagePrefixList",
"=",
"System",
".",
"getProperty",
"(",
"contentPathProp",
",",
"\"\"",
")",
";",
"if",
"(",
"packagePrefixList",
"!=",
"\"\"",
")",
"{",
"packagePrefixList",
"+=",
... | Returns a vertical bar separated list of package prefixes for potential
content handlers. Tries to get the java.content.handler.pkgs property
to use as a set of package prefixes to search. Whether or not
that property has been defined, the sun.net.www.content is always
the last one on the returned package list. | [
"Returns",
"a",
"vertical",
"bar",
"separated",
"list",
"of",
"package",
"prefixes",
"for",
"potential",
"content",
"handlers",
".",
"Tries",
"to",
"get",
"the",
"java",
".",
"content",
".",
"handler",
".",
"pkgs",
"property",
"to",
"use",
"as",
"a",
"set"... | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/libcore/ojluni/src/main/java/java/net/URLConnection.java#L1366-L1374 |
33,025 | google/j2objc | jre_emul/android/platform/libcore/ojluni/src/main/java/java/net/URLConnection.java | URLConnection.readBytes | static private int readBytes(int c[], int len, InputStream is)
throws IOException {
byte buf[] = new byte[len];
if (is.read(buf, 0, len) < len) {
return -1;
}
// fill the passed in int array
for (int i = 0; i < len; i++) {
c[i] = buf[i] ... | java | static private int readBytes(int c[], int len, InputStream is)
throws IOException {
byte buf[] = new byte[len];
if (is.read(buf, 0, len) < len) {
return -1;
}
// fill the passed in int array
for (int i = 0; i < len; i++) {
c[i] = buf[i] ... | [
"static",
"private",
"int",
"readBytes",
"(",
"int",
"c",
"[",
"]",
",",
"int",
"len",
",",
"InputStream",
"is",
")",
"throws",
"IOException",
"{",
"byte",
"buf",
"[",
"]",
"=",
"new",
"byte",
"[",
"len",
"]",
";",
"if",
"(",
"is",
".",
"read",
"... | Tries to read the specified number of bytes from the stream
Returns -1, If EOF is reached before len bytes are read, returns 0
otherwise | [
"Tries",
"to",
"read",
"the",
"specified",
"number",
"of",
"bytes",
"from",
"the",
"stream",
"Returns",
"-",
"1",
"If",
"EOF",
"is",
"reached",
"before",
"len",
"bytes",
"are",
"read",
"returns",
"0",
"otherwise"
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/libcore/ojluni/src/main/java/java/net/URLConnection.java#L1738-L1751 |
33,026 | google/j2objc | jre_emul/android/platform/libcore/ojluni/src/main/java/java/net/URLConnection.java | URLConnection.skipForward | static private long skipForward(InputStream is, long toSkip)
throws IOException {
long eachSkip = 0;
long skipped = 0;
while (skipped != toSkip) {
eachSkip = is.skip(toSkip - skipped);
// check if EOF is reached
if (eachSkip <= 0) {
... | java | static private long skipForward(InputStream is, long toSkip)
throws IOException {
long eachSkip = 0;
long skipped = 0;
while (skipped != toSkip) {
eachSkip = is.skip(toSkip - skipped);
// check if EOF is reached
if (eachSkip <= 0) {
... | [
"static",
"private",
"long",
"skipForward",
"(",
"InputStream",
"is",
",",
"long",
"toSkip",
")",
"throws",
"IOException",
"{",
"long",
"eachSkip",
"=",
"0",
";",
"long",
"skipped",
"=",
"0",
";",
"while",
"(",
"skipped",
"!=",
"toSkip",
")",
"{",
"eachS... | Skips through the specified number of bytes from the stream
until either EOF is reached, or the specified
number of bytes have been skipped | [
"Skips",
"through",
"the",
"specified",
"number",
"of",
"bytes",
"from",
"the",
"stream",
"until",
"either",
"EOF",
"is",
"reached",
"or",
"the",
"specified",
"number",
"of",
"bytes",
"have",
"been",
"skipped"
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/libcore/ojluni/src/main/java/java/net/URLConnection.java#L1759-L1779 |
33,027 | google/j2objc | xalan/third_party/android/platform/external/apache-xml/src/main/java/org/apache/xml/serializer/ToHTMLStream.java | ToHTMLStream.getElemDesc | public static final ElemDesc getElemDesc(String name)
{
/* this method used to return m_dummy when name was null
* but now it doesn't check and and requires non-null name.
*/
Object obj = m_elementFlags.get(name);
if (null != obj)
return (ElemDesc)obj;
... | java | public static final ElemDesc getElemDesc(String name)
{
/* this method used to return m_dummy when name was null
* but now it doesn't check and and requires non-null name.
*/
Object obj = m_elementFlags.get(name);
if (null != obj)
return (ElemDesc)obj;
... | [
"public",
"static",
"final",
"ElemDesc",
"getElemDesc",
"(",
"String",
"name",
")",
"{",
"/* this method used to return m_dummy when name was null\n * but now it doesn't check and and requires non-null name.\n */",
"Object",
"obj",
"=",
"m_elementFlags",
".",
"get",
... | Get a description of the given element.
@param name non-null name of element, case insensitive.
@return non-null reference to ElemDesc, which may be m_dummy if no
element description matches the given name. | [
"Get",
"a",
"description",
"of",
"the",
"given",
"element",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/xalan/third_party/android/platform/external/apache-xml/src/main/java/org/apache/xml/serializer/ToHTMLStream.java#L626-L635 |
33,028 | google/j2objc | xalan/third_party/android/platform/external/apache-xml/src/main/java/org/apache/xml/serializer/ToHTMLStream.java | ToHTMLStream.outputDocTypeDecl | private void outputDocTypeDecl(String name) throws SAXException {
if (true == m_needToOutputDocTypeDecl)
{
String doctypeSystem = getDoctypeSystem();
String doctypePublic = getDoctypePublic();
if ((null != doctypeSystem) || (null != doctypePublic))
{
... | java | private void outputDocTypeDecl(String name) throws SAXException {
if (true == m_needToOutputDocTypeDecl)
{
String doctypeSystem = getDoctypeSystem();
String doctypePublic = getDoctypePublic();
if ((null != doctypeSystem) || (null != doctypePublic))
{
... | [
"private",
"void",
"outputDocTypeDecl",
"(",
"String",
"name",
")",
"throws",
"SAXException",
"{",
"if",
"(",
"true",
"==",
"m_needToOutputDocTypeDecl",
")",
"{",
"String",
"doctypeSystem",
"=",
"getDoctypeSystem",
"(",
")",
";",
"String",
"doctypePublic",
"=",
... | This method should only get called once.
If a DOCTYPE declaration needs to get written out, it will
be written out. If it doesn't need to be written out, then
the call to this method has no effect. | [
"This",
"method",
"should",
"only",
"get",
"called",
"once",
".",
"If",
"a",
"DOCTYPE",
"declaration",
"needs",
"to",
"get",
"written",
"out",
"it",
"will",
"be",
"written",
"out",
".",
"If",
"it",
"doesn",
"t",
"need",
"to",
"be",
"written",
"out",
"t... | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/xalan/third_party/android/platform/external/apache-xml/src/main/java/org/apache/xml/serializer/ToHTMLStream.java#L700-L742 |
33,029 | google/j2objc | xalan/third_party/android/platform/external/apache-xml/src/main/java/org/apache/xml/serializer/ToHTMLStream.java | ToHTMLStream.makeHHString | private static String makeHHString(int i)
{
String s = Integer.toHexString(i).toUpperCase();
if (s.length() == 1)
{
s = "0" + s;
}
return s;
} | java | private static String makeHHString(int i)
{
String s = Integer.toHexString(i).toUpperCase();
if (s.length() == 1)
{
s = "0" + s;
}
return s;
} | [
"private",
"static",
"String",
"makeHHString",
"(",
"int",
"i",
")",
"{",
"String",
"s",
"=",
"Integer",
".",
"toHexString",
"(",
"i",
")",
".",
"toUpperCase",
"(",
")",
";",
"if",
"(",
"s",
".",
"length",
"(",
")",
"==",
"1",
")",
"{",
"s",
"=",... | Make an integer into an HH hex value.
Does no checking on the size of the input, since this
is only meant to be used locally by writeAttrURI.
@param i must be a value less than 255.
@return should be a two character string. | [
"Make",
"an",
"integer",
"into",
"an",
"HH",
"hex",
"value",
".",
"Does",
"no",
"checking",
"on",
"the",
"size",
"of",
"the",
"input",
"since",
"this",
"is",
"only",
"meant",
"to",
"be",
"used",
"locally",
"by",
"writeAttrURI",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/xalan/third_party/android/platform/external/apache-xml/src/main/java/org/apache/xml/serializer/ToHTMLStream.java#L1108-L1116 |
33,030 | google/j2objc | xalan/third_party/android/platform/external/apache-xml/src/main/java/org/apache/xml/serializer/ToHTMLStream.java | ToHTMLStream.closeStartTag | protected void closeStartTag() throws SAXException
{
try
{
// finish processing attributes, time to fire off the start element event
if (m_tracer != null)
super.fireStartElem(m_elemContext.m_elementName);
int nAttrs = m_attr... | java | protected void closeStartTag() throws SAXException
{
try
{
// finish processing attributes, time to fire off the start element event
if (m_tracer != null)
super.fireStartElem(m_elemContext.m_elementName);
int nAttrs = m_attr... | [
"protected",
"void",
"closeStartTag",
"(",
")",
"throws",
"SAXException",
"{",
"try",
"{",
"// finish processing attributes, time to fire off the start element event",
"if",
"(",
"m_tracer",
"!=",
"null",
")",
"super",
".",
"fireStartElem",
"(",
"m_elemContext",
".",
"m... | For the enclosing elements starting tag write out out any attributes
followed by ">". At this point we also mark if this element is
a cdata-section-element.
@throws org.xml.sax.SAXException | [
"For",
"the",
"enclosing",
"elements",
"starting",
"tag",
"write",
"out",
"out",
"any",
"attributes",
"followed",
"by",
">",
".",
"At",
"this",
"point",
"we",
"also",
"mark",
"if",
"this",
"element",
"is",
"a",
"cdata",
"-",
"section",
"-",
"element",
".... | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/xalan/third_party/android/platform/external/apache-xml/src/main/java/org/apache/xml/serializer/ToHTMLStream.java#L1790-L1826 |
33,031 | google/j2objc | xalan/third_party/android/platform/external/apache-xml/src/main/java/org/apache/xml/serializer/ToHTMLStream.java | ToHTMLStream.attributeDecl | public void attributeDecl(
String eName,
String aName,
String type,
String valueDefault,
String value)
throws SAXException
{
// The internal DTD subset is not serialized by the ToHTMLStream serializer
} | java | public void attributeDecl(
String eName,
String aName,
String type,
String valueDefault,
String value)
throws SAXException
{
// The internal DTD subset is not serialized by the ToHTMLStream serializer
} | [
"public",
"void",
"attributeDecl",
"(",
"String",
"eName",
",",
"String",
"aName",
",",
"String",
"type",
",",
"String",
"valueDefault",
",",
"String",
"value",
")",
"throws",
"SAXException",
"{",
"// The internal DTD subset is not serialized by the ToHTMLStream serialize... | This method does nothing. | [
"This",
"method",
"does",
"nothing",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/xalan/third_party/android/platform/external/apache-xml/src/main/java/org/apache/xml/serializer/ToHTMLStream.java#L1882-L1891 |
33,032 | google/j2objc | jre_emul/android/platform/libcore/ojluni/src/main/java/sun/security/x509/X509CertInfo.java | X509CertInfo.getEncodedInfo | public byte[] getEncodedInfo() throws CertificateEncodingException {
try {
if (rawCertInfo == null) {
DerOutputStream tmp = new DerOutputStream();
emit(tmp);
rawCertInfo = tmp.toByteArray();
}
return rawCertInfo.clone();
... | java | public byte[] getEncodedInfo() throws CertificateEncodingException {
try {
if (rawCertInfo == null) {
DerOutputStream tmp = new DerOutputStream();
emit(tmp);
rawCertInfo = tmp.toByteArray();
}
return rawCertInfo.clone();
... | [
"public",
"byte",
"[",
"]",
"getEncodedInfo",
"(",
")",
"throws",
"CertificateEncodingException",
"{",
"try",
"{",
"if",
"(",
"rawCertInfo",
"==",
"null",
")",
"{",
"DerOutputStream",
"tmp",
"=",
"new",
"DerOutputStream",
"(",
")",
";",
"emit",
"(",
"tmp",
... | Returns the encoded certificate info.
@exception CertificateEncodingException on encoding information errors. | [
"Returns",
"the",
"encoded",
"certificate",
"info",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/libcore/ojluni/src/main/java/sun/security/x509/X509CertInfo.java#L222-L235 |
33,033 | google/j2objc | jre_emul/android/platform/libcore/ojluni/src/main/java/sun/security/x509/X509CertInfo.java | X509CertInfo.set | public void set(String name, Object val)
throws CertificateException, IOException {
X509AttributeName attrName = new X509AttributeName(name);
int attr = attributeMap(attrName.getPrefix());
if (attr == 0) {
throw new CertificateException("Attribute name not recognized: "
... | java | public void set(String name, Object val)
throws CertificateException, IOException {
X509AttributeName attrName = new X509AttributeName(name);
int attr = attributeMap(attrName.getPrefix());
if (attr == 0) {
throw new CertificateException("Attribute name not recognized: "
... | [
"public",
"void",
"set",
"(",
"String",
"name",
",",
"Object",
"val",
")",
"throws",
"CertificateException",
",",
"IOException",
"{",
"X509AttributeName",
"attrName",
"=",
"new",
"X509AttributeName",
"(",
"name",
")",
";",
"int",
"attr",
"=",
"attributeMap",
"... | Set the certificate attribute.
@params name the name of the Certificate attribute.
@params val the value of the Certificate attribute.
@exception CertificateException on invalid attributes.
@exception IOException on other errors. | [
"Set",
"the",
"certificate",
"attribute",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/libcore/ojluni/src/main/java/sun/security/x509/X509CertInfo.java#L364-L444 |
33,034 | google/j2objc | jre_emul/android/platform/libcore/ojluni/src/main/java/sun/security/x509/X509CertInfo.java | X509CertInfo.delete | public void delete(String name)
throws CertificateException, IOException {
X509AttributeName attrName = new X509AttributeName(name);
int attr = attributeMap(attrName.getPrefix());
if (attr == 0) {
throw new CertificateException("Attribute name not recognized: "
... | java | public void delete(String name)
throws CertificateException, IOException {
X509AttributeName attrName = new X509AttributeName(name);
int attr = attributeMap(attrName.getPrefix());
if (attr == 0) {
throw new CertificateException("Attribute name not recognized: "
... | [
"public",
"void",
"delete",
"(",
"String",
"name",
")",
"throws",
"CertificateException",
",",
"IOException",
"{",
"X509AttributeName",
"attrName",
"=",
"new",
"X509AttributeName",
"(",
"name",
")",
";",
"int",
"attr",
"=",
"attributeMap",
"(",
"attrName",
".",
... | Delete the certificate attribute.
@params name the name of the Certificate attribute.
@exception CertificateException on invalid attributes.
@exception IOException on other errors. | [
"Delete",
"the",
"certificate",
"attribute",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/libcore/ojluni/src/main/java/sun/security/x509/X509CertInfo.java#L453-L523 |
33,035 | google/j2objc | jre_emul/android/platform/libcore/ojluni/src/main/java/sun/security/x509/X509CertInfo.java | X509CertInfo.get | public Object get(String name)
throws CertificateException, IOException {
X509AttributeName attrName = new X509AttributeName(name);
int attr = attributeMap(attrName.getPrefix());
if (attr == 0) {
throw new CertificateParsingException(
"Attribute name no... | java | public Object get(String name)
throws CertificateException, IOException {
X509AttributeName attrName = new X509AttributeName(name);
int attr = attributeMap(attrName.getPrefix());
if (attr == 0) {
throw new CertificateParsingException(
"Attribute name no... | [
"public",
"Object",
"get",
"(",
"String",
"name",
")",
"throws",
"CertificateException",
",",
"IOException",
"{",
"X509AttributeName",
"attrName",
"=",
"new",
"X509AttributeName",
"(",
"name",
")",
";",
"int",
"attr",
"=",
"attributeMap",
"(",
"attrName",
".",
... | Get the certificate attribute.
@params name the name of the Certificate attribute.
@exception CertificateException on invalid attributes.
@exception IOException on other errors. | [
"Get",
"the",
"certificate",
"attribute",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/libcore/ojluni/src/main/java/sun/security/x509/X509CertInfo.java#L533-L603 |
33,036 | google/j2objc | jre_emul/android/platform/libcore/ojluni/src/main/java/sun/security/x509/X509CertInfo.java | X509CertInfo.attributeMap | private int attributeMap(String name) {
Integer num = map.get(name);
if (num == null) {
return 0;
}
return num.intValue();
} | java | private int attributeMap(String name) {
Integer num = map.get(name);
if (num == null) {
return 0;
}
return num.intValue();
} | [
"private",
"int",
"attributeMap",
"(",
"String",
"name",
")",
"{",
"Integer",
"num",
"=",
"map",
".",
"get",
"(",
"name",
")",
";",
"if",
"(",
"num",
"==",
"null",
")",
"{",
"return",
"0",
";",
"}",
"return",
"num",
".",
"intValue",
"(",
")",
";"... | Returns the integer attribute number for the passed attribute name. | [
"Returns",
"the",
"integer",
"attribute",
"number",
"for",
"the",
"passed",
"attribute",
"name",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/libcore/ojluni/src/main/java/sun/security/x509/X509CertInfo.java#L804-L810 |
33,037 | google/j2objc | jre_emul/android/platform/libcore/ojluni/src/main/java/sun/security/x509/X509CertInfo.java | X509CertInfo.setVersion | private void setVersion(Object val) throws CertificateException {
if (!(val instanceof CertificateVersion)) {
throw new CertificateException("Version class type invalid.");
}
version = (CertificateVersion)val;
} | java | private void setVersion(Object val) throws CertificateException {
if (!(val instanceof CertificateVersion)) {
throw new CertificateException("Version class type invalid.");
}
version = (CertificateVersion)val;
} | [
"private",
"void",
"setVersion",
"(",
"Object",
"val",
")",
"throws",
"CertificateException",
"{",
"if",
"(",
"!",
"(",
"val",
"instanceof",
"CertificateVersion",
")",
")",
"{",
"throw",
"new",
"CertificateException",
"(",
"\"Version class type invalid.\"",
")",
"... | Set the version number of the certificate.
@params val the Object class value for the Extensions
@exception CertificateException on invalid data. | [
"Set",
"the",
"version",
"number",
"of",
"the",
"certificate",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/libcore/ojluni/src/main/java/sun/security/x509/X509CertInfo.java#L818-L823 |
33,038 | google/j2objc | jre_emul/android/platform/libcore/ojluni/src/main/java/sun/security/x509/X509CertInfo.java | X509CertInfo.setSerialNumber | private void setSerialNumber(Object val) throws CertificateException {
if (!(val instanceof CertificateSerialNumber)) {
throw new CertificateException("SerialNumber class type invalid.");
}
serialNum = (CertificateSerialNumber)val;
} | java | private void setSerialNumber(Object val) throws CertificateException {
if (!(val instanceof CertificateSerialNumber)) {
throw new CertificateException("SerialNumber class type invalid.");
}
serialNum = (CertificateSerialNumber)val;
} | [
"private",
"void",
"setSerialNumber",
"(",
"Object",
"val",
")",
"throws",
"CertificateException",
"{",
"if",
"(",
"!",
"(",
"val",
"instanceof",
"CertificateSerialNumber",
")",
")",
"{",
"throw",
"new",
"CertificateException",
"(",
"\"SerialNumber class type invalid.... | Set the serial number of the certificate.
@params val the Object class value for the CertificateSerialNumber
@exception CertificateException on invalid data. | [
"Set",
"the",
"serial",
"number",
"of",
"the",
"certificate",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/libcore/ojluni/src/main/java/sun/security/x509/X509CertInfo.java#L831-L836 |
33,039 | google/j2objc | jre_emul/android/platform/libcore/ojluni/src/main/java/sun/security/x509/X509CertInfo.java | X509CertInfo.setAlgorithmId | private void setAlgorithmId(Object val) throws CertificateException {
if (!(val instanceof CertificateAlgorithmId)) {
throw new CertificateException(
"AlgorithmId class type invalid.");
}
algId = (CertificateAlgorithmId)val;
} | java | private void setAlgorithmId(Object val) throws CertificateException {
if (!(val instanceof CertificateAlgorithmId)) {
throw new CertificateException(
"AlgorithmId class type invalid.");
}
algId = (CertificateAlgorithmId)val;
} | [
"private",
"void",
"setAlgorithmId",
"(",
"Object",
"val",
")",
"throws",
"CertificateException",
"{",
"if",
"(",
"!",
"(",
"val",
"instanceof",
"CertificateAlgorithmId",
")",
")",
"{",
"throw",
"new",
"CertificateException",
"(",
"\"AlgorithmId class type invalid.\""... | Set the algorithm id of the certificate.
@params val the Object class value for the AlgorithmId
@exception CertificateException on invalid data. | [
"Set",
"the",
"algorithm",
"id",
"of",
"the",
"certificate",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/libcore/ojluni/src/main/java/sun/security/x509/X509CertInfo.java#L844-L850 |
33,040 | google/j2objc | jre_emul/android/platform/libcore/ojluni/src/main/java/sun/security/x509/X509CertInfo.java | X509CertInfo.setIssuer | private void setIssuer(Object val) throws CertificateException {
if (!(val instanceof X500Name)) {
throw new CertificateException(
"Issuer class type invalid.");
}
issuer = (X500Name)val;
} | java | private void setIssuer(Object val) throws CertificateException {
if (!(val instanceof X500Name)) {
throw new CertificateException(
"Issuer class type invalid.");
}
issuer = (X500Name)val;
} | [
"private",
"void",
"setIssuer",
"(",
"Object",
"val",
")",
"throws",
"CertificateException",
"{",
"if",
"(",
"!",
"(",
"val",
"instanceof",
"X500Name",
")",
")",
"{",
"throw",
"new",
"CertificateException",
"(",
"\"Issuer class type invalid.\"",
")",
";",
"}",
... | Set the issuer name of the certificate.
@params val the Object class value for the issuer
@exception CertificateException on invalid data. | [
"Set",
"the",
"issuer",
"name",
"of",
"the",
"certificate",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/libcore/ojluni/src/main/java/sun/security/x509/X509CertInfo.java#L858-L864 |
33,041 | google/j2objc | jre_emul/android/platform/libcore/ojluni/src/main/java/sun/security/x509/X509CertInfo.java | X509CertInfo.setValidity | private void setValidity(Object val) throws CertificateException {
if (!(val instanceof CertificateValidity)) {
throw new CertificateException(
"CertificateValidity class type invalid.");
}
interval = (CertificateValidity)val;
} | java | private void setValidity(Object val) throws CertificateException {
if (!(val instanceof CertificateValidity)) {
throw new CertificateException(
"CertificateValidity class type invalid.");
}
interval = (CertificateValidity)val;
} | [
"private",
"void",
"setValidity",
"(",
"Object",
"val",
")",
"throws",
"CertificateException",
"{",
"if",
"(",
"!",
"(",
"val",
"instanceof",
"CertificateValidity",
")",
")",
"{",
"throw",
"new",
"CertificateException",
"(",
"\"CertificateValidity class type invalid.\... | Set the validity interval of the certificate.
@params val the Object class value for the CertificateValidity
@exception CertificateException on invalid data. | [
"Set",
"the",
"validity",
"interval",
"of",
"the",
"certificate",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/libcore/ojluni/src/main/java/sun/security/x509/X509CertInfo.java#L872-L878 |
33,042 | google/j2objc | jre_emul/android/platform/libcore/ojluni/src/main/java/sun/security/x509/X509CertInfo.java | X509CertInfo.setSubject | private void setSubject(Object val) throws CertificateException {
if (!(val instanceof X500Name)) {
throw new CertificateException(
"Subject class type invalid.");
}
subject = (X500Name)val;
} | java | private void setSubject(Object val) throws CertificateException {
if (!(val instanceof X500Name)) {
throw new CertificateException(
"Subject class type invalid.");
}
subject = (X500Name)val;
} | [
"private",
"void",
"setSubject",
"(",
"Object",
"val",
")",
"throws",
"CertificateException",
"{",
"if",
"(",
"!",
"(",
"val",
"instanceof",
"X500Name",
")",
")",
"{",
"throw",
"new",
"CertificateException",
"(",
"\"Subject class type invalid.\"",
")",
";",
"}",... | Set the subject name of the certificate.
@params val the Object class value for the Subject
@exception CertificateException on invalid data. | [
"Set",
"the",
"subject",
"name",
"of",
"the",
"certificate",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/libcore/ojluni/src/main/java/sun/security/x509/X509CertInfo.java#L886-L892 |
33,043 | google/j2objc | jre_emul/android/platform/libcore/ojluni/src/main/java/sun/security/x509/X509CertInfo.java | X509CertInfo.setKey | private void setKey(Object val) throws CertificateException {
if (!(val instanceof CertificateX509Key)) {
throw new CertificateException(
"Key class type invalid.");
}
pubKey = (CertificateX509Key)val;
} | java | private void setKey(Object val) throws CertificateException {
if (!(val instanceof CertificateX509Key)) {
throw new CertificateException(
"Key class type invalid.");
}
pubKey = (CertificateX509Key)val;
} | [
"private",
"void",
"setKey",
"(",
"Object",
"val",
")",
"throws",
"CertificateException",
"{",
"if",
"(",
"!",
"(",
"val",
"instanceof",
"CertificateX509Key",
")",
")",
"{",
"throw",
"new",
"CertificateException",
"(",
"\"Key class type invalid.\"",
")",
";",
"}... | Set the public key in the certificate.
@params val the Object class value for the PublicKey
@exception CertificateException on invalid data. | [
"Set",
"the",
"public",
"key",
"in",
"the",
"certificate",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/libcore/ojluni/src/main/java/sun/security/x509/X509CertInfo.java#L900-L906 |
33,044 | google/j2objc | jre_emul/android/platform/libcore/ojluni/src/main/java/sun/security/x509/X509CertInfo.java | X509CertInfo.setIssuerUniqueId | private void setIssuerUniqueId(Object val) throws CertificateException {
if (version.compare(CertificateVersion.V2) < 0) {
throw new CertificateException("Invalid version");
}
if (!(val instanceof UniqueIdentity)) {
throw new CertificateException(
... | java | private void setIssuerUniqueId(Object val) throws CertificateException {
if (version.compare(CertificateVersion.V2) < 0) {
throw new CertificateException("Invalid version");
}
if (!(val instanceof UniqueIdentity)) {
throw new CertificateException(
... | [
"private",
"void",
"setIssuerUniqueId",
"(",
"Object",
"val",
")",
"throws",
"CertificateException",
"{",
"if",
"(",
"version",
".",
"compare",
"(",
"CertificateVersion",
".",
"V2",
")",
"<",
"0",
")",
"{",
"throw",
"new",
"CertificateException",
"(",
"\"Inval... | Set the Issuer Unique Identity in the certificate.
@params val the Object class value for the IssuerUniqueId
@exception CertificateException | [
"Set",
"the",
"Issuer",
"Unique",
"Identity",
"in",
"the",
"certificate",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/libcore/ojluni/src/main/java/sun/security/x509/X509CertInfo.java#L914-L923 |
33,045 | google/j2objc | jre_emul/android/platform/libcore/ojluni/src/main/java/sun/security/x509/X509CertInfo.java | X509CertInfo.setSubjectUniqueId | private void setSubjectUniqueId(Object val) throws CertificateException {
if (version.compare(CertificateVersion.V2) < 0) {
throw new CertificateException("Invalid version");
}
if (!(val instanceof UniqueIdentity)) {
throw new CertificateException(
... | java | private void setSubjectUniqueId(Object val) throws CertificateException {
if (version.compare(CertificateVersion.V2) < 0) {
throw new CertificateException("Invalid version");
}
if (!(val instanceof UniqueIdentity)) {
throw new CertificateException(
... | [
"private",
"void",
"setSubjectUniqueId",
"(",
"Object",
"val",
")",
"throws",
"CertificateException",
"{",
"if",
"(",
"version",
".",
"compare",
"(",
"CertificateVersion",
".",
"V2",
")",
"<",
"0",
")",
"{",
"throw",
"new",
"CertificateException",
"(",
"\"Inva... | Set the Subject Unique Identity in the certificate.
@params val the Object class value for the SubjectUniqueId
@exception CertificateException | [
"Set",
"the",
"Subject",
"Unique",
"Identity",
"in",
"the",
"certificate",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/libcore/ojluni/src/main/java/sun/security/x509/X509CertInfo.java#L931-L940 |
33,046 | google/j2objc | jre_emul/android/platform/libcore/ojluni/src/main/java/sun/security/x509/X509CertInfo.java | X509CertInfo.setExtensions | private void setExtensions(Object val) throws CertificateException {
if (version.compare(CertificateVersion.V3) < 0) {
throw new CertificateException("Invalid version");
}
if (!(val instanceof CertificateExtensions)) {
throw new CertificateException(
... | java | private void setExtensions(Object val) throws CertificateException {
if (version.compare(CertificateVersion.V3) < 0) {
throw new CertificateException("Invalid version");
}
if (!(val instanceof CertificateExtensions)) {
throw new CertificateException(
... | [
"private",
"void",
"setExtensions",
"(",
"Object",
"val",
")",
"throws",
"CertificateException",
"{",
"if",
"(",
"version",
".",
"compare",
"(",
"CertificateVersion",
".",
"V3",
")",
"<",
"0",
")",
"{",
"throw",
"new",
"CertificateException",
"(",
"\"Invalid v... | Set the extensions in the certificate.
@params val the Object class value for the Extensions
@exception CertificateException | [
"Set",
"the",
"extensions",
"in",
"the",
"certificate",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/libcore/ojluni/src/main/java/sun/security/x509/X509CertInfo.java#L948-L957 |
33,047 | google/j2objc | jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/text/NumberFormat.java | NumberFormat.parseObject | @Override
public final Object parseObject(String source,
ParsePosition parsePosition) {
return parse(source, parsePosition);
} | java | @Override
public final Object parseObject(String source,
ParsePosition parsePosition) {
return parse(source, parsePosition);
} | [
"@",
"Override",
"public",
"final",
"Object",
"parseObject",
"(",
"String",
"source",
",",
"ParsePosition",
"parsePosition",
")",
"{",
"return",
"parse",
"(",
"source",
",",
"parsePosition",
")",
";",
"}"
] | Parses text from a string to produce a number.
@param source the String to parse
@param parsePosition the position at which to start the parse
@return the parsed number, or null
@see java.text.NumberFormat#parseObject(String, ParsePosition) | [
"Parses",
"text",
"from",
"a",
"string",
"to",
"produce",
"a",
"number",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/text/NumberFormat.java#L276-L280 |
33,048 | google/j2objc | jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/text/NumberFormat.java | NumberFormat.format | public final String format(long number) {
StringBuffer buf = new StringBuffer(19);
FieldPosition pos = new FieldPosition(0);
format(number, buf, pos);
return buf.toString();
} | java | public final String format(long number) {
StringBuffer buf = new StringBuffer(19);
FieldPosition pos = new FieldPosition(0);
format(number, buf, pos);
return buf.toString();
} | [
"public",
"final",
"String",
"format",
"(",
"long",
"number",
")",
"{",
"StringBuffer",
"buf",
"=",
"new",
"StringBuffer",
"(",
"19",
")",
";",
"FieldPosition",
"pos",
"=",
"new",
"FieldPosition",
"(",
"0",
")",
";",
"format",
"(",
"number",
",",
"buf",
... | Specialization of format.
@see java.text.Format#format(Object) | [
"Specialization",
"of",
"format",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/text/NumberFormat.java#L295-L300 |
33,049 | google/j2objc | jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/text/NumberFormat.java | NumberFormat.format | public final String format(java.math.BigDecimal number) {
return format(number, new StringBuffer(),
new FieldPosition(0)).toString();
} | java | public final String format(java.math.BigDecimal number) {
return format(number, new StringBuffer(),
new FieldPosition(0)).toString();
} | [
"public",
"final",
"String",
"format",
"(",
"java",
".",
"math",
".",
"BigDecimal",
"number",
")",
"{",
"return",
"format",
"(",
"number",
",",
"new",
"StringBuffer",
"(",
")",
",",
"new",
"FieldPosition",
"(",
"0",
")",
")",
".",
"toString",
"(",
")",... | Convenience method to format a BigDecimal. | [
"Convenience",
"method",
"to",
"format",
"a",
"BigDecimal",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/text/NumberFormat.java#L313-L316 |
33,050 | google/j2objc | jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/text/NumberFormat.java | NumberFormat.setMaximumIntegerDigits | public void setMaximumIntegerDigits(int newValue) {
maximumIntegerDigits = Math.max(0,newValue);
if (minimumIntegerDigits > maximumIntegerDigits)
minimumIntegerDigits = maximumIntegerDigits;
} | java | public void setMaximumIntegerDigits(int newValue) {
maximumIntegerDigits = Math.max(0,newValue);
if (minimumIntegerDigits > maximumIntegerDigits)
minimumIntegerDigits = maximumIntegerDigits;
} | [
"public",
"void",
"setMaximumIntegerDigits",
"(",
"int",
"newValue",
")",
"{",
"maximumIntegerDigits",
"=",
"Math",
".",
"max",
"(",
"0",
",",
"newValue",
")",
";",
"if",
"(",
"minimumIntegerDigits",
">",
"maximumIntegerDigits",
")",
"minimumIntegerDigits",
"=",
... | Sets the maximum number of digits allowed in the integer portion of a
number. This must be >= minimumIntegerDigits. If the
new value for maximumIntegerDigits is less than the current value
of minimumIntegerDigits, then minimumIntegerDigits will also be set to
the new value.
@param newValue the maximum number of int... | [
"Sets",
"the",
"maximum",
"number",
"of",
"digits",
"allowed",
"in",
"the",
"integer",
"portion",
"of",
"a",
"number",
".",
"This",
"must",
"be",
">",
";",
"=",
"minimumIntegerDigits",
".",
"If",
"the",
"new",
"value",
"for",
"maximumIntegerDigits",
"is",
... | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/text/NumberFormat.java#L1061-L1065 |
33,051 | google/j2objc | jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/text/NumberFormat.java | NumberFormat.setMinimumIntegerDigits | public void setMinimumIntegerDigits(int newValue) {
minimumIntegerDigits = Math.max(0,newValue);
if (minimumIntegerDigits > maximumIntegerDigits)
maximumIntegerDigits = minimumIntegerDigits;
} | java | public void setMinimumIntegerDigits(int newValue) {
minimumIntegerDigits = Math.max(0,newValue);
if (minimumIntegerDigits > maximumIntegerDigits)
maximumIntegerDigits = minimumIntegerDigits;
} | [
"public",
"void",
"setMinimumIntegerDigits",
"(",
"int",
"newValue",
")",
"{",
"minimumIntegerDigits",
"=",
"Math",
".",
"max",
"(",
"0",
",",
"newValue",
")",
";",
"if",
"(",
"minimumIntegerDigits",
">",
"maximumIntegerDigits",
")",
"maximumIntegerDigits",
"=",
... | Sets the minimum number of digits allowed in the integer portion of a
number. This must be <= maximumIntegerDigits. If the
new value for minimumIntegerDigits is more than the current value
of maximumIntegerDigits, then maximumIntegerDigits will also be set to
the new value.
@param newValue the minimum number of in... | [
"Sets",
"the",
"minimum",
"number",
"of",
"digits",
"allowed",
"in",
"the",
"integer",
"portion",
"of",
"a",
"number",
".",
"This",
"must",
"be",
"<",
";",
"=",
"maximumIntegerDigits",
".",
"If",
"the",
"new",
"value",
"for",
"minimumIntegerDigits",
"is",
... | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/text/NumberFormat.java#L1091-L1095 |
33,052 | google/j2objc | jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/text/NumberFormat.java | NumberFormat.setMinimumFractionDigits | public void setMinimumFractionDigits(int newValue) {
minimumFractionDigits = Math.max(0,newValue);
if (maximumFractionDigits < minimumFractionDigits)
maximumFractionDigits = minimumFractionDigits;
} | java | public void setMinimumFractionDigits(int newValue) {
minimumFractionDigits = Math.max(0,newValue);
if (maximumFractionDigits < minimumFractionDigits)
maximumFractionDigits = minimumFractionDigits;
} | [
"public",
"void",
"setMinimumFractionDigits",
"(",
"int",
"newValue",
")",
"{",
"minimumFractionDigits",
"=",
"Math",
".",
"max",
"(",
"0",
",",
"newValue",
")",
";",
"if",
"(",
"maximumFractionDigits",
"<",
"minimumFractionDigits",
")",
"maximumFractionDigits",
"... | Sets the minimum number of digits allowed in the fraction portion of a
number. This must be <= maximumFractionDigits. If the
new value for minimumFractionDigits exceeds the current value
of maximumFractionDigits, then maximumFractionDigits will also be set to
the new value.
@param newValue the minimum number of fr... | [
"Sets",
"the",
"minimum",
"number",
"of",
"digits",
"allowed",
"in",
"the",
"fraction",
"portion",
"of",
"a",
"number",
".",
"This",
"must",
"be",
"<",
";",
"=",
"maximumFractionDigits",
".",
"If",
"the",
"new",
"value",
"for",
"minimumFractionDigits",
"ex... | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/text/NumberFormat.java#L1151-L1155 |
33,053 | google/j2objc | jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/text/NumberFormat.java | NumberFormat.getInstance | public static NumberFormat getInstance(ULocale desiredLocale, int choice) {
if (choice < NUMBERSTYLE || choice > STANDARDCURRENCYSTYLE) {
throw new IllegalArgumentException(
"choice should be from NUMBERSTYLE to STANDARDCURRENCYSTYLE");
}
// if (shim == null) {
// ... | java | public static NumberFormat getInstance(ULocale desiredLocale, int choice) {
if (choice < NUMBERSTYLE || choice > STANDARDCURRENCYSTYLE) {
throw new IllegalArgumentException(
"choice should be from NUMBERSTYLE to STANDARDCURRENCYSTYLE");
}
// if (shim == null) {
// ... | [
"public",
"static",
"NumberFormat",
"getInstance",
"(",
"ULocale",
"desiredLocale",
",",
"int",
"choice",
")",
"{",
"if",
"(",
"choice",
"<",
"NUMBERSTYLE",
"||",
"choice",
">",
"STANDARDCURRENCYSTYLE",
")",
"{",
"throw",
"new",
"IllegalArgumentException",
"(",
... | Returns a specific style number format for a specific locale.
@param desiredLocale the specific locale.
@param choice number format style
@throws IllegalArgumentException if choice is not one of
NUMBERSTYLE, CURRENCYSTYLE,
PERCENTSTYLE, SCIENTIFICSTYLE,
INTEGERSTYLE, ISOCURRENCYSTYLE,
PLURALCURRENCYSTYLE, ACC... | [
"Returns",
"a",
"specific",
"style",
"number",
"format",
"for",
"a",
"specific",
"locale",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/text/NumberFormat.java#L1237-L1249 |
33,054 | google/j2objc | jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/text/NumberFormat.java | NumberFormat.createInstance | static NumberFormat createInstance(ULocale desiredLocale, int choice) {
// If the choice is PLURALCURRENCYSTYLE, the pattern is not a single
// pattern, it is a pattern set, so we do not need to get them here.
// If the choice is ISOCURRENCYSTYLE, the pattern is the currrency
// pattern ... | java | static NumberFormat createInstance(ULocale desiredLocale, int choice) {
// If the choice is PLURALCURRENCYSTYLE, the pattern is not a single
// pattern, it is a pattern set, so we do not need to get them here.
// If the choice is ISOCURRENCYSTYLE, the pattern is the currrency
// pattern ... | [
"static",
"NumberFormat",
"createInstance",
"(",
"ULocale",
"desiredLocale",
",",
"int",
"choice",
")",
"{",
"// If the choice is PLURALCURRENCYSTYLE, the pattern is not a single",
"// pattern, it is a pattern set, so we do not need to get them here.",
"// If the choice is ISOCURRENCYSTYLE... | Hook for service | [
"Hook",
"for",
"service"
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/text/NumberFormat.java#L1253-L1345 |
33,055 | google/j2objc | xalan/third_party/android/platform/external/apache-xml/src/main/java/org/apache/xml/serializer/utils/XML11Char.java | XML11Char.isXML11ValidLiteral | public static boolean isXML11ValidLiteral(int c) {
return ((c < 0x10000 && ((XML11CHARS[c] & MASK_XML11_VALID) != 0 && (XML11CHARS[c] & MASK_XML11_CONTROL) == 0))
|| (0x10000 <= c && c <= 0x10FFFF));
} | java | public static boolean isXML11ValidLiteral(int c) {
return ((c < 0x10000 && ((XML11CHARS[c] & MASK_XML11_VALID) != 0 && (XML11CHARS[c] & MASK_XML11_CONTROL) == 0))
|| (0x10000 <= c && c <= 0x10FFFF));
} | [
"public",
"static",
"boolean",
"isXML11ValidLiteral",
"(",
"int",
"c",
")",
"{",
"return",
"(",
"(",
"c",
"<",
"0x10000",
"&&",
"(",
"(",
"XML11CHARS",
"[",
"c",
"]",
"&",
"MASK_XML11_VALID",
")",
"!=",
"0",
"&&",
"(",
"XML11CHARS",
"[",
"c",
"]",
"&... | Returns true if the specified character is valid and permitted outside
of a character reference.
That is, this method will return false for the same set as
isXML11Valid, except it also reports false for "control characters".
@param c The character to check. | [
"Returns",
"true",
"if",
"the",
"specified",
"character",
"is",
"valid",
"and",
"permitted",
"outside",
"of",
"a",
"character",
"reference",
".",
"That",
"is",
"this",
"method",
"will",
"return",
"false",
"for",
"the",
"same",
"set",
"as",
"isXML11Valid",
"e... | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/xalan/third_party/android/platform/external/apache-xml/src/main/java/org/apache/xml/serializer/utils/XML11Char.java#L196-L199 |
33,056 | google/j2objc | jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/text/AnyTransliterator.java | AnyTransliterator.scriptNameToCode | private static int scriptNameToCode(String name) {
try{
int[] codes = UScript.getCode(name);
return codes != null ? codes[0] : UScript.INVALID_CODE;
}catch( MissingResourceException e){
///CLOVER:OFF
return UScript.INVALID_CODE;
///CLOVER:ON
... | java | private static int scriptNameToCode(String name) {
try{
int[] codes = UScript.getCode(name);
return codes != null ? codes[0] : UScript.INVALID_CODE;
}catch( MissingResourceException e){
///CLOVER:OFF
return UScript.INVALID_CODE;
///CLOVER:ON
... | [
"private",
"static",
"int",
"scriptNameToCode",
"(",
"String",
"name",
")",
"{",
"try",
"{",
"int",
"[",
"]",
"codes",
"=",
"UScript",
".",
"getCode",
"(",
"name",
")",
";",
"return",
"codes",
"!=",
"null",
"?",
"codes",
"[",
"0",
"]",
":",
"UScript"... | Return the script code for a given name, or
UScript.INVALID_CODE if not found. | [
"Return",
"the",
"script",
"code",
"for",
"a",
"given",
"name",
"or",
"UScript",
".",
"INVALID_CODE",
"if",
"not",
"found",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/text/AnyTransliterator.java#L283-L292 |
33,057 | google/j2objc | xalan/third_party/android/platform/external/apache-xml/src/main/java/org/apache/xalan/templates/ElemElement.java | ElemElement.resolvePrefix | protected String resolvePrefix(SerializationHandler rhandler,
String prefix, String nodeNamespace)
throws TransformerException
{
// if (null != prefix && prefix.length() == 0)
// {
// String foundPrefix = rhandler.getPrefix(nodeNamespace);
//
// // System.out.prin... | java | protected String resolvePrefix(SerializationHandler rhandler,
String prefix, String nodeNamespace)
throws TransformerException
{
// if (null != prefix && prefix.length() == 0)
// {
// String foundPrefix = rhandler.getPrefix(nodeNamespace);
//
// // System.out.prin... | [
"protected",
"String",
"resolvePrefix",
"(",
"SerializationHandler",
"rhandler",
",",
"String",
"prefix",
",",
"String",
"nodeNamespace",
")",
"throws",
"TransformerException",
"{",
"// if (null != prefix && prefix.length() == 0)",
"// {",
"// String foundPrefix = rhan... | Resolve the namespace into a prefix. Meant to be
overidded by elemAttribute if this class is derived.
@param rhandler The current result tree handler.
@param prefix The probable prefix if already known.
@param nodeNamespace The namespace.
@return The prefix to be used. | [
"Resolve",
"the",
"namespace",
"into",
"a",
"prefix",
".",
"Meant",
"to",
"be",
"overidded",
"by",
"elemAttribute",
"if",
"this",
"class",
"is",
"derived",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/xalan/third_party/android/platform/external/apache-xml/src/main/java/org/apache/xalan/templates/ElemElement.java#L172-L186 |
33,058 | google/j2objc | xalan/third_party/android/platform/external/apache-xml/src/main/java/org/apache/xpath/compiler/Lexer.java | Lexer.mapPatternElemPos | private boolean mapPatternElemPos(int nesting, boolean isStart,
boolean isAttrName)
{
if (0 == nesting)
{
if(m_patternMapSize >= m_patternMap.length)
{
int patternMap[] = m_patternMap;
int len = m_patternMap.length;
m_patternMap = new in... | java | private boolean mapPatternElemPos(int nesting, boolean isStart,
boolean isAttrName)
{
if (0 == nesting)
{
if(m_patternMapSize >= m_patternMap.length)
{
int patternMap[] = m_patternMap;
int len = m_patternMap.length;
m_patternMap = new in... | [
"private",
"boolean",
"mapPatternElemPos",
"(",
"int",
"nesting",
",",
"boolean",
"isStart",
",",
"boolean",
"isAttrName",
")",
"{",
"if",
"(",
"0",
"==",
"nesting",
")",
"{",
"if",
"(",
"m_patternMapSize",
">=",
"m_patternMap",
".",
"length",
")",
"{",
"i... | Record the current position on the token queue as long as
this is a top-level element. Must be called before the
next token is added to the m_tokenQueue.
@param nesting The nesting count for the pattern element.
@param isStart true if this is the start of a pattern.
@param isAttrName true if we have determined that t... | [
"Record",
"the",
"current",
"position",
"on",
"the",
"token",
"queue",
"as",
"long",
"as",
"this",
"is",
"a",
"top",
"-",
"level",
"element",
".",
"Must",
"be",
"called",
"before",
"the",
"next",
"token",
"is",
"added",
"to",
"the",
"m_tokenQueue",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/xalan/third_party/android/platform/external/apache-xml/src/main/java/org/apache/xpath/compiler/Lexer.java#L396-L422 |
33,059 | google/j2objc | xalan/third_party/android/platform/external/apache-xml/src/main/java/org/apache/xpath/compiler/Lexer.java | Lexer.getTokenQueuePosFromMap | private int getTokenQueuePosFromMap(int i)
{
int pos = m_patternMap[i];
return (pos >= TARGETEXTRA) ? (pos - TARGETEXTRA) : pos;
} | java | private int getTokenQueuePosFromMap(int i)
{
int pos = m_patternMap[i];
return (pos >= TARGETEXTRA) ? (pos - TARGETEXTRA) : pos;
} | [
"private",
"int",
"getTokenQueuePosFromMap",
"(",
"int",
"i",
")",
"{",
"int",
"pos",
"=",
"m_patternMap",
"[",
"i",
"]",
";",
"return",
"(",
"pos",
">=",
"TARGETEXTRA",
")",
"?",
"(",
"pos",
"-",
"TARGETEXTRA",
")",
":",
"pos",
";",
"}"
] | Given a map pos, return the corresponding token queue pos.
@param i The index in the m_patternMap.
@return the token queue position. | [
"Given",
"a",
"map",
"pos",
"return",
"the",
"corresponding",
"token",
"queue",
"pos",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/xalan/third_party/android/platform/external/apache-xml/src/main/java/org/apache/xpath/compiler/Lexer.java#L431-L437 |
33,060 | google/j2objc | xalan/third_party/android/platform/external/apache-xml/src/main/java/org/apache/xpath/compiler/Lexer.java | Lexer.resetTokenMark | private final void resetTokenMark(int mark)
{
int qsz = m_compiler.getTokenQueueSize();
m_processor.m_queueMark = (mark > 0)
? ((mark <= qsz) ? mark - 1 : mark) : 0;
if (m_processor.m_queueMark < qsz)
{
m_processor.m_token =
(String) m_compiler.getTokenQu... | java | private final void resetTokenMark(int mark)
{
int qsz = m_compiler.getTokenQueueSize();
m_processor.m_queueMark = (mark > 0)
? ((mark <= qsz) ? mark - 1 : mark) : 0;
if (m_processor.m_queueMark < qsz)
{
m_processor.m_token =
(String) m_compiler.getTokenQu... | [
"private",
"final",
"void",
"resetTokenMark",
"(",
"int",
"mark",
")",
"{",
"int",
"qsz",
"=",
"m_compiler",
".",
"getTokenQueueSize",
"(",
")",
";",
"m_processor",
".",
"m_queueMark",
"=",
"(",
"mark",
">",
"0",
")",
"?",
"(",
"(",
"mark",
"<=",
"qsz"... | Reset token queue mark and m_token to a
given position.
@param mark The new position. | [
"Reset",
"token",
"queue",
"mark",
"and",
"m_token",
"to",
"a",
"given",
"position",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/xalan/third_party/android/platform/external/apache-xml/src/main/java/org/apache/xpath/compiler/Lexer.java#L444-L463 |
33,061 | google/j2objc | xalan/third_party/android/platform/external/apache-xml/src/main/java/org/apache/xpath/compiler/Lexer.java | Lexer.getKeywordToken | final int getKeywordToken(String key)
{
int tok;
try
{
Integer itok = (Integer) Keywords.getKeyWord(key);
tok = (null != itok) ? itok.intValue() : 0;
}
catch (NullPointerException npe)
{
tok = 0;
}
catch (ClassCastException cce)
{
tok = 0;
}
retu... | java | final int getKeywordToken(String key)
{
int tok;
try
{
Integer itok = (Integer) Keywords.getKeyWord(key);
tok = (null != itok) ? itok.intValue() : 0;
}
catch (NullPointerException npe)
{
tok = 0;
}
catch (ClassCastException cce)
{
tok = 0;
}
retu... | [
"final",
"int",
"getKeywordToken",
"(",
"String",
"key",
")",
"{",
"int",
"tok",
";",
"try",
"{",
"Integer",
"itok",
"=",
"(",
"Integer",
")",
"Keywords",
".",
"getKeyWord",
"(",
"key",
")",
";",
"tok",
"=",
"(",
"null",
"!=",
"itok",
")",
"?",
"it... | Given a string, return the corresponding keyword token.
@param key The keyword.
@return An opcode value. | [
"Given",
"a",
"string",
"return",
"the",
"corresponding",
"keyword",
"token",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/xalan/third_party/android/platform/external/apache-xml/src/main/java/org/apache/xpath/compiler/Lexer.java#L472-L493 |
33,062 | google/j2objc | xalan/third_party/android/platform/external/apache-xml/src/main/java/org/apache/xpath/compiler/Lexer.java | Lexer.recordTokenString | private void recordTokenString(Vector targetStrings)
{
int tokPos = getTokenQueuePosFromMap(m_patternMapSize - 1);
resetTokenMark(tokPos + 1);
if (m_processor.lookahead('(', 1))
{
int tok = getKeywordToken(m_processor.m_token);
switch (tok)
{
case OpCodes.NODETYPE_COMMENT :... | java | private void recordTokenString(Vector targetStrings)
{
int tokPos = getTokenQueuePosFromMap(m_patternMapSize - 1);
resetTokenMark(tokPos + 1);
if (m_processor.lookahead('(', 1))
{
int tok = getKeywordToken(m_processor.m_token);
switch (tok)
{
case OpCodes.NODETYPE_COMMENT :... | [
"private",
"void",
"recordTokenString",
"(",
"Vector",
"targetStrings",
")",
"{",
"int",
"tokPos",
"=",
"getTokenQueuePosFromMap",
"(",
"m_patternMapSize",
"-",
"1",
")",
";",
"resetTokenMark",
"(",
"tokPos",
"+",
"1",
")",
";",
"if",
"(",
"m_processor",
".",
... | Record the current token in the passed vector.
@param targetStrings Vector of string. | [
"Record",
"the",
"current",
"token",
"in",
"the",
"passed",
"vector",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/xalan/third_party/android/platform/external/apache-xml/src/main/java/org/apache/xpath/compiler/Lexer.java#L500-L551 |
33,063 | google/j2objc | xalan/third_party/android/platform/external/apache-xml/src/main/java/org/apache/xpath/compiler/Lexer.java | Lexer.mapNSTokens | private int mapNSTokens(String pat, int startSubstring, int posOfNSSep,
int posOfScan)
throws javax.xml.transform.TransformerException
{
String prefix = "";
if ((startSubstring >= 0) && (posOfNSSep >= 0))
{
prefix = pat.substring(startSubstring, posOfNSSep)... | java | private int mapNSTokens(String pat, int startSubstring, int posOfNSSep,
int posOfScan)
throws javax.xml.transform.TransformerException
{
String prefix = "";
if ((startSubstring >= 0) && (posOfNSSep >= 0))
{
prefix = pat.substring(startSubstring, posOfNSSep)... | [
"private",
"int",
"mapNSTokens",
"(",
"String",
"pat",
",",
"int",
"startSubstring",
",",
"int",
"posOfNSSep",
",",
"int",
"posOfScan",
")",
"throws",
"javax",
".",
"xml",
".",
"transform",
".",
"TransformerException",
"{",
"String",
"prefix",
"=",
"\"\"",
"... | When a seperator token is found, see if there's a element name or
the like to map.
@param pat The XPath name string.
@param startSubstring The start of the name string.
@param posOfNSSep The position of the namespace seperator (':').
@param posOfScan The end of the name index.
@throws javax.xml.transform.TransformerE... | [
"When",
"a",
"seperator",
"token",
"is",
"found",
"see",
"if",
"there",
"s",
"a",
"element",
"name",
"or",
"the",
"like",
"to",
"map",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/xalan/third_party/android/platform/external/apache-xml/src/main/java/org/apache/xpath/compiler/Lexer.java#L577-L668 |
33,064 | google/j2objc | jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/util/GlobalizationPreferences.java | GlobalizationPreferences.getLocale | public ULocale getLocale(int index) {
List<ULocale> lcls = locales;
if (lcls == null) {
lcls = guessLocales();
}
if (index >= 0 && index < lcls.size()) {
return lcls.get(index);
}
return null;
} | java | public ULocale getLocale(int index) {
List<ULocale> lcls = locales;
if (lcls == null) {
lcls = guessLocales();
}
if (index >= 0 && index < lcls.size()) {
return lcls.get(index);
}
return null;
} | [
"public",
"ULocale",
"getLocale",
"(",
"int",
"index",
")",
"{",
"List",
"<",
"ULocale",
">",
"lcls",
"=",
"locales",
";",
"if",
"(",
"lcls",
"==",
"null",
")",
"{",
"lcls",
"=",
"guessLocales",
"(",
")",
";",
"}",
"if",
"(",
"index",
">=",
"0",
... | Convenience function for getting the locales in priority order
@param index The index (0..n) of the desired item.
@return desired item. null if index is out of range
@hide draft / provisional / internal are hidden on Android | [
"Convenience",
"function",
"for",
"getting",
"the",
"locales",
"in",
"priority",
"order"
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/util/GlobalizationPreferences.java#L196-L205 |
33,065 | google/j2objc | jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/util/GlobalizationPreferences.java | GlobalizationPreferences.setLocales | public GlobalizationPreferences setLocales(String acceptLanguageString) {
if (isFrozen()) {
throw new UnsupportedOperationException("Attempt to modify immutable object");
}
ULocale[] acceptLocales = null;
try {
acceptLocales = ULocale.parseAcceptLanguage(acceptLan... | java | public GlobalizationPreferences setLocales(String acceptLanguageString) {
if (isFrozen()) {
throw new UnsupportedOperationException("Attempt to modify immutable object");
}
ULocale[] acceptLocales = null;
try {
acceptLocales = ULocale.parseAcceptLanguage(acceptLan... | [
"public",
"GlobalizationPreferences",
"setLocales",
"(",
"String",
"acceptLanguageString",
")",
"{",
"if",
"(",
"isFrozen",
"(",
")",
")",
"{",
"throw",
"new",
"UnsupportedOperationException",
"(",
"\"Attempt to modify immutable object\"",
")",
";",
"}",
"ULocale",
"[... | Convenience routine for setting the locale priority list from
an Accept-Language string.
@see #setLocales(List locales)
@param acceptLanguageString Accept-Language list, as defined by
Section 14.4 of the RFC 2616 (HTTP 1.1)
@return this, for chaining
@hide draft / provisional / internal are hidden on Android | [
"Convenience",
"routine",
"for",
"setting",
"the",
"locale",
"priority",
"list",
"from",
"an",
"Accept",
"-",
"Language",
"string",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/util/GlobalizationPreferences.java#L248-L260 |
33,066 | google/j2objc | jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/util/GlobalizationPreferences.java | GlobalizationPreferences.setCalendar | public GlobalizationPreferences setCalendar(Calendar calendar) {
if (isFrozen()) {
throw new UnsupportedOperationException("Attempt to modify immutable object");
}
this.calendar = (Calendar) calendar.clone(); // clone for safety
return this;
} | java | public GlobalizationPreferences setCalendar(Calendar calendar) {
if (isFrozen()) {
throw new UnsupportedOperationException("Attempt to modify immutable object");
}
this.calendar = (Calendar) calendar.clone(); // clone for safety
return this;
} | [
"public",
"GlobalizationPreferences",
"setCalendar",
"(",
"Calendar",
"calendar",
")",
"{",
"if",
"(",
"isFrozen",
"(",
")",
")",
"{",
"throw",
"new",
"UnsupportedOperationException",
"(",
"\"Attempt to modify immutable object\"",
")",
";",
"}",
"this",
".",
"calend... | Sets the calendar. If this has not been set, uses default for territory.
@param calendar arbitrary calendar
@return this, for chaining
@hide draft / provisional / internal are hidden on Android | [
"Sets",
"the",
"calendar",
".",
"If",
"this",
"has",
"not",
"been",
"set",
"uses",
"default",
"for",
"territory",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/util/GlobalizationPreferences.java#L400-L406 |
33,067 | google/j2objc | jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/util/GlobalizationPreferences.java | GlobalizationPreferences.getCalendar | public Calendar getCalendar() {
if (calendar == null) {
return guessCalendar();
}
Calendar temp = (Calendar) calendar.clone(); // clone for safety
temp.setTimeZone(getTimeZone());
temp.setTimeInMillis(System.currentTimeMillis());
return temp;
} | java | public Calendar getCalendar() {
if (calendar == null) {
return guessCalendar();
}
Calendar temp = (Calendar) calendar.clone(); // clone for safety
temp.setTimeZone(getTimeZone());
temp.setTimeInMillis(System.currentTimeMillis());
return temp;
} | [
"public",
"Calendar",
"getCalendar",
"(",
")",
"{",
"if",
"(",
"calendar",
"==",
"null",
")",
"{",
"return",
"guessCalendar",
"(",
")",
";",
"}",
"Calendar",
"temp",
"=",
"(",
"Calendar",
")",
"calendar",
".",
"clone",
"(",
")",
";",
"// clone for safety... | Get a copy of the calendar according to the settings.
@return calendar explicit or implicit.
@hide draft / provisional / internal are hidden on Android | [
"Get",
"a",
"copy",
"of",
"the",
"calendar",
"according",
"to",
"the",
"settings",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/util/GlobalizationPreferences.java#L414-L422 |
33,068 | google/j2objc | jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/util/GlobalizationPreferences.java | GlobalizationPreferences.setTimeZone | public GlobalizationPreferences setTimeZone(TimeZone timezone) {
if (isFrozen()) {
throw new UnsupportedOperationException("Attempt to modify immutable object");
}
this.timezone = (TimeZone) timezone.clone(); // clone for safety;
return this;
} | java | public GlobalizationPreferences setTimeZone(TimeZone timezone) {
if (isFrozen()) {
throw new UnsupportedOperationException("Attempt to modify immutable object");
}
this.timezone = (TimeZone) timezone.clone(); // clone for safety;
return this;
} | [
"public",
"GlobalizationPreferences",
"setTimeZone",
"(",
"TimeZone",
"timezone",
")",
"{",
"if",
"(",
"isFrozen",
"(",
")",
")",
"{",
"throw",
"new",
"UnsupportedOperationException",
"(",
"\"Attempt to modify immutable object\"",
")",
";",
"}",
"this",
".",
"timezo... | Sets the timezone ID. If this has not been set, uses default for territory.
@param timezone a valid TZID (see UTS#35).
@return this, for chaining
@hide draft / provisional / internal are hidden on Android | [
"Sets",
"the",
"timezone",
"ID",
".",
"If",
"this",
"has",
"not",
"been",
"set",
"uses",
"default",
"for",
"territory",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/util/GlobalizationPreferences.java#L431-L437 |
33,069 | google/j2objc | jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/util/GlobalizationPreferences.java | GlobalizationPreferences.getCollator | public Collator getCollator() {
if (collator == null) {
return guessCollator();
}
try {
return (Collator) collator.clone(); // clone for safety
} catch (CloneNotSupportedException e) {
throw new ICUCloneNotSupportedException("Error in cloning collator... | java | public Collator getCollator() {
if (collator == null) {
return guessCollator();
}
try {
return (Collator) collator.clone(); // clone for safety
} catch (CloneNotSupportedException e) {
throw new ICUCloneNotSupportedException("Error in cloning collator... | [
"public",
"Collator",
"getCollator",
"(",
")",
"{",
"if",
"(",
"collator",
"==",
"null",
")",
"{",
"return",
"guessCollator",
"(",
")",
";",
"}",
"try",
"{",
"return",
"(",
"Collator",
")",
"collator",
".",
"clone",
"(",
")",
";",
"// clone for safety",
... | Get a copy of the collator according to the settings.
@return collator explicit or implicit.
@hide draft / provisional / internal are hidden on Android | [
"Get",
"a",
"copy",
"of",
"the",
"collator",
"according",
"to",
"the",
"settings",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/util/GlobalizationPreferences.java#L459-L468 |
33,070 | google/j2objc | jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/util/GlobalizationPreferences.java | GlobalizationPreferences.setCollator | public GlobalizationPreferences setCollator(Collator collator) {
if (isFrozen()) {
throw new UnsupportedOperationException("Attempt to modify immutable object");
}
try {
this.collator = (Collator) collator.clone(); // clone for safety
} catch (CloneNotSupportedExc... | java | public GlobalizationPreferences setCollator(Collator collator) {
if (isFrozen()) {
throw new UnsupportedOperationException("Attempt to modify immutable object");
}
try {
this.collator = (Collator) collator.clone(); // clone for safety
} catch (CloneNotSupportedExc... | [
"public",
"GlobalizationPreferences",
"setCollator",
"(",
"Collator",
"collator",
")",
"{",
"if",
"(",
"isFrozen",
"(",
")",
")",
"{",
"throw",
"new",
"UnsupportedOperationException",
"(",
"\"Attempt to modify immutable object\"",
")",
";",
"}",
"try",
"{",
"this",
... | Explicitly set the collator for this object.
@param collator The collator object to be passed.
@return this, for chaining
@hide draft / provisional / internal are hidden on Android | [
"Explicitly",
"set",
"the",
"collator",
"for",
"this",
"object",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/util/GlobalizationPreferences.java#L476-L486 |
33,071 | google/j2objc | jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/util/GlobalizationPreferences.java | GlobalizationPreferences.getBreakIterator | public BreakIterator getBreakIterator(int type) {
if (type < BI_CHARACTER || type >= BI_LIMIT) {
throw new IllegalArgumentException("Illegal break iterator type");
}
if (breakIterators == null || breakIterators[type] == null) {
return guessBreakIterator(type);
}
... | java | public BreakIterator getBreakIterator(int type) {
if (type < BI_CHARACTER || type >= BI_LIMIT) {
throw new IllegalArgumentException("Illegal break iterator type");
}
if (breakIterators == null || breakIterators[type] == null) {
return guessBreakIterator(type);
}
... | [
"public",
"BreakIterator",
"getBreakIterator",
"(",
"int",
"type",
")",
"{",
"if",
"(",
"type",
"<",
"BI_CHARACTER",
"||",
"type",
">=",
"BI_LIMIT",
")",
"{",
"throw",
"new",
"IllegalArgumentException",
"(",
"\"Illegal break iterator type\"",
")",
";",
"}",
"if"... | Get a copy of the break iterator for the specified type according to the
settings.
@param type break type - BI_CHARACTER or BI_WORD, BI_LINE, BI_SENTENCE, BI_TITLE
@return break iterator explicit or implicit
@hide draft / provisional / internal are hidden on Android | [
"Get",
"a",
"copy",
"of",
"the",
"break",
"iterator",
"for",
"the",
"specified",
"type",
"according",
"to",
"the",
"settings",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/util/GlobalizationPreferences.java#L496-L504 |
33,072 | google/j2objc | jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/util/GlobalizationPreferences.java | GlobalizationPreferences.setBreakIterator | public GlobalizationPreferences setBreakIterator(int type, BreakIterator iterator) {
if (type < BI_CHARACTER || type >= BI_LIMIT) {
throw new IllegalArgumentException("Illegal break iterator type");
}
if (isFrozen()) {
throw new UnsupportedOperationException("Attempt to m... | java | public GlobalizationPreferences setBreakIterator(int type, BreakIterator iterator) {
if (type < BI_CHARACTER || type >= BI_LIMIT) {
throw new IllegalArgumentException("Illegal break iterator type");
}
if (isFrozen()) {
throw new UnsupportedOperationException("Attempt to m... | [
"public",
"GlobalizationPreferences",
"setBreakIterator",
"(",
"int",
"type",
",",
"BreakIterator",
"iterator",
")",
"{",
"if",
"(",
"type",
"<",
"BI_CHARACTER",
"||",
"type",
">=",
"BI_LIMIT",
")",
"{",
"throw",
"new",
"IllegalArgumentException",
"(",
"\"Illegal ... | Explicitly set the break iterator for this object.
@param type break type - BI_CHARACTER or BI_WORD, BI_LINE, BI_SENTENCE, BI_TITLE
@param iterator a break iterator
@return this, for chaining
@hide draft / provisional / internal are hidden on Android | [
"Explicitly",
"set",
"the",
"break",
"iterator",
"for",
"this",
"object",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/util/GlobalizationPreferences.java#L514-L525 |
33,073 | google/j2objc | jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/util/GlobalizationPreferences.java | GlobalizationPreferences.setDateFormat | public GlobalizationPreferences setDateFormat(int dateStyle, int timeStyle, DateFormat format) {
if (isFrozen()) {
throw new UnsupportedOperationException("Attempt to modify immutable object");
}
if (dateFormats == null) {
dateFormats = new DateFormat[DF_LIMIT][DF_LIMIT];... | java | public GlobalizationPreferences setDateFormat(int dateStyle, int timeStyle, DateFormat format) {
if (isFrozen()) {
throw new UnsupportedOperationException("Attempt to modify immutable object");
}
if (dateFormats == null) {
dateFormats = new DateFormat[DF_LIMIT][DF_LIMIT];... | [
"public",
"GlobalizationPreferences",
"setDateFormat",
"(",
"int",
"dateStyle",
",",
"int",
"timeStyle",
",",
"DateFormat",
"format",
")",
"{",
"if",
"(",
"isFrozen",
"(",
")",
")",
"{",
"throw",
"new",
"UnsupportedOperationException",
"(",
"\"Attempt to modify immu... | Set an explicit date format. Overrides the locale priority list for
a particular combination of dateStyle and timeStyle. DF_NONE should
be used if for the style, where only the date or time format individually
is being set.
@param dateStyle DF_FULL, DF_LONG, DF_MEDIUM, DF_SHORT or DF_NONE
@param timeStyle DF_FULL, DF_... | [
"Set",
"an",
"explicit",
"date",
"format",
".",
"Overrides",
"the",
"locale",
"priority",
"list",
"for",
"a",
"particular",
"combination",
"of",
"dateStyle",
"and",
"timeStyle",
".",
"DF_NONE",
"should",
"be",
"used",
"if",
"for",
"the",
"style",
"where",
"o... | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/util/GlobalizationPreferences.java#L639-L648 |
33,074 | google/j2objc | jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/util/GlobalizationPreferences.java | GlobalizationPreferences.setNumberFormat | public GlobalizationPreferences setNumberFormat(int style, NumberFormat format) {
if (isFrozen()) {
throw new UnsupportedOperationException("Attempt to modify immutable object");
}
if (numberFormats == null) {
numberFormats = new NumberFormat[NF_LIMIT];
}
... | java | public GlobalizationPreferences setNumberFormat(int style, NumberFormat format) {
if (isFrozen()) {
throw new UnsupportedOperationException("Attempt to modify immutable object");
}
if (numberFormats == null) {
numberFormats = new NumberFormat[NF_LIMIT];
}
... | [
"public",
"GlobalizationPreferences",
"setNumberFormat",
"(",
"int",
"style",
",",
"NumberFormat",
"format",
")",
"{",
"if",
"(",
"isFrozen",
"(",
")",
")",
"{",
"throw",
"new",
"UnsupportedOperationException",
"(",
"\"Attempt to modify immutable object\"",
")",
";",
... | Sets a number format explicitly. Overrides the general locale settings.
@param style NF_NUMBER, NF_CURRENCY, NF_PERCENT, NF_SCIENTIFIC, NF_INTEGER
@param format The number format
@return this, for chaining
@hide draft / provisional / internal are hidden on Android | [
"Sets",
"a",
"number",
"format",
"explicitly",
".",
"Overrides",
"the",
"general",
"locale",
"settings",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/util/GlobalizationPreferences.java#L715-L724 |
33,075 | google/j2objc | jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/util/GlobalizationPreferences.java | GlobalizationPreferences.reset | public GlobalizationPreferences reset() {
if (isFrozen()) {
throw new UnsupportedOperationException("Attempt to modify immutable object");
}
locales = null;
territory = null;
calendar = null;
collator = null;
breakIterators = null;
timezone = n... | java | public GlobalizationPreferences reset() {
if (isFrozen()) {
throw new UnsupportedOperationException("Attempt to modify immutable object");
}
locales = null;
territory = null;
calendar = null;
collator = null;
breakIterators = null;
timezone = n... | [
"public",
"GlobalizationPreferences",
"reset",
"(",
")",
"{",
"if",
"(",
"isFrozen",
"(",
")",
")",
"{",
"throw",
"new",
"UnsupportedOperationException",
"(",
"\"Attempt to modify immutable object\"",
")",
";",
"}",
"locales",
"=",
"null",
";",
"territory",
"=",
... | Restore the object to the initial state.
@return this, for chaining
@hide draft / provisional / internal are hidden on Android | [
"Restore",
"the",
"object",
"to",
"the",
"initial",
"state",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/util/GlobalizationPreferences.java#L732-L747 |
33,076 | google/j2objc | jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/util/GlobalizationPreferences.java | GlobalizationPreferences.guessTerritory | protected String guessTerritory() {
String result;
// pass through locales to see if there is a territory.
for (ULocale locale : getLocales()) {
result = locale.getCountry();
if (result.length() != 0) {
return result;
}
}
// if ... | java | protected String guessTerritory() {
String result;
// pass through locales to see if there is a territory.
for (ULocale locale : getLocales()) {
result = locale.getCountry();
if (result.length() != 0) {
return result;
}
}
// if ... | [
"protected",
"String",
"guessTerritory",
"(",
")",
"{",
"String",
"result",
";",
"// pass through locales to see if there is a territory.",
"for",
"(",
"ULocale",
"locale",
":",
"getLocales",
"(",
")",
")",
"{",
"result",
"=",
"locale",
".",
"getCountry",
"(",
")"... | This function can be overridden by subclasses to use different heuristics.
@hide draft / provisional / internal are hidden on Android | [
"This",
"function",
"can",
"be",
"overridden",
"by",
"subclasses",
"to",
"use",
"different",
"heuristics",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/external/icu/android_icu4j/src/main/java/android/icu/util/GlobalizationPreferences.java#L973-L1000 |
33,077 | google/j2objc | xalan/third_party/android/platform/external/apache-xml/src/main/java/org/apache/xml/utils/DefaultErrorHandler.java | DefaultErrorHandler.error | public void error(TransformerException exception) throws TransformerException
{
// If the m_throwExceptionOnError flag is true, rethrow the exception.
// Otherwise report the error to System.err.
if (m_throwExceptionOnError)
throw exception;
else
{
PrintWriter pw = getErrorWriter();
... | java | public void error(TransformerException exception) throws TransformerException
{
// If the m_throwExceptionOnError flag is true, rethrow the exception.
// Otherwise report the error to System.err.
if (m_throwExceptionOnError)
throw exception;
else
{
PrintWriter pw = getErrorWriter();
... | [
"public",
"void",
"error",
"(",
"TransformerException",
"exception",
")",
"throws",
"TransformerException",
"{",
"// If the m_throwExceptionOnError flag is true, rethrow the exception.",
"// Otherwise report the error to System.err.",
"if",
"(",
"m_throwExceptionOnError",
")",
"throw... | Receive notification of a recoverable error.
<p>This corresponds to the definition of "error" in section 1.2
of the W3C XML 1.0 Recommendation. For example, a validating
parser would use this callback to report the violation of a
validity constraint. The default behaviour is to take no
action.</p>
<p>The SAX parser... | [
"Receive",
"notification",
"of",
"a",
"recoverable",
"error",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/xalan/third_party/android/platform/external/apache-xml/src/main/java/org/apache/xml/utils/DefaultErrorHandler.java#L228-L241 |
33,078 | google/j2objc | jre_emul/android/platform/libcore/ojluni/src/main/java/java/util/Scanner.java | Scanner.readInput | private void readInput() {
if (buf.limit() == buf.capacity())
makeSpace();
// Prepare to receive data
int p = buf.position();
buf.position(buf.limit());
buf.limit(buf.capacity());
int n = 0;
try {
n = source.read(buf);
} catch (IO... | java | private void readInput() {
if (buf.limit() == buf.capacity())
makeSpace();
// Prepare to receive data
int p = buf.position();
buf.position(buf.limit());
buf.limit(buf.capacity());
int n = 0;
try {
n = source.read(buf);
} catch (IO... | [
"private",
"void",
"readInput",
"(",
")",
"{",
"if",
"(",
"buf",
".",
"limit",
"(",
")",
"==",
"buf",
".",
"capacity",
"(",
")",
")",
"makeSpace",
"(",
")",
";",
"// Prepare to receive data",
"int",
"p",
"=",
"buf",
".",
"position",
"(",
")",
";",
... | Tries to read more input. May block. | [
"Tries",
"to",
"read",
"more",
"input",
".",
"May",
"block",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/libcore/ojluni/src/main/java/java/util/Scanner.java#L757-L788 |
33,079 | google/j2objc | jre_emul/android/platform/libcore/ojluni/src/main/java/java/util/Scanner.java | Scanner.makeSpace | private boolean makeSpace() {
clearCaches();
int offset = savedScannerPosition == -1 ?
position : savedScannerPosition;
buf.position(offset);
// Gain space by compacting buffer
if (offset > 0) {
buf.compact();
translateSavedIndexes(offset);
... | java | private boolean makeSpace() {
clearCaches();
int offset = savedScannerPosition == -1 ?
position : savedScannerPosition;
buf.position(offset);
// Gain space by compacting buffer
if (offset > 0) {
buf.compact();
translateSavedIndexes(offset);
... | [
"private",
"boolean",
"makeSpace",
"(",
")",
"{",
"clearCaches",
"(",
")",
";",
"int",
"offset",
"=",
"savedScannerPosition",
"==",
"-",
"1",
"?",
"position",
":",
"savedScannerPosition",
";",
"buf",
".",
"position",
"(",
"offset",
")",
";",
"// Gain space b... | or else there will be space in the buffer | [
"or",
"else",
"there",
"will",
"be",
"space",
"in",
"the",
"buffer"
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/libcore/ojluni/src/main/java/java/util/Scanner.java#L792-L815 |
33,080 | google/j2objc | jre_emul/android/platform/libcore/ojluni/src/main/java/java/util/Scanner.java | Scanner.hasTokenInBuffer | private boolean hasTokenInBuffer() {
matchValid = false;
matcher.usePattern(delimPattern);
matcher.region(position, buf.limit());
// Skip delims first
if (matcher.lookingAt())
position = matcher.end();
// If we are sitting at the end, no more tokens in buffe... | java | private boolean hasTokenInBuffer() {
matchValid = false;
matcher.usePattern(delimPattern);
matcher.region(position, buf.limit());
// Skip delims first
if (matcher.lookingAt())
position = matcher.end();
// If we are sitting at the end, no more tokens in buffe... | [
"private",
"boolean",
"hasTokenInBuffer",
"(",
")",
"{",
"matchValid",
"=",
"false",
";",
"matcher",
".",
"usePattern",
"(",
"delimPattern",
")",
";",
"matcher",
".",
"region",
"(",
"position",
",",
"buf",
".",
"limit",
"(",
")",
")",
";",
"// Skip delims ... | means that there will be another token with or without more input. | [
"means",
"that",
"there",
"will",
"be",
"another",
"token",
"with",
"or",
"without",
"more",
"input",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/libcore/ojluni/src/main/java/java/util/Scanner.java#L837-L851 |
33,081 | google/j2objc | jre_emul/android/platform/libcore/ojluni/src/main/java/java/util/Scanner.java | Scanner.findPatternInBuffer | private String findPatternInBuffer(Pattern pattern, int horizon) {
matchValid = false;
matcher.usePattern(pattern);
int bufferLimit = buf.limit();
int horizonLimit = -1;
int searchLimit = bufferLimit;
if (horizon > 0) {
horizonLimit = position + horizon;
... | java | private String findPatternInBuffer(Pattern pattern, int horizon) {
matchValid = false;
matcher.usePattern(pattern);
int bufferLimit = buf.limit();
int horizonLimit = -1;
int searchLimit = bufferLimit;
if (horizon > 0) {
horizonLimit = position + horizon;
... | [
"private",
"String",
"findPatternInBuffer",
"(",
"Pattern",
"pattern",
",",
"int",
"horizon",
")",
"{",
"matchValid",
"=",
"false",
";",
"matcher",
".",
"usePattern",
"(",
"pattern",
")",
";",
"int",
"bufferLimit",
"=",
"buf",
".",
"limit",
"(",
")",
";",
... | Returns a match for the specified input pattern. | [
"Returns",
"a",
"match",
"for",
"the",
"specified",
"input",
"pattern",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/libcore/ojluni/src/main/java/java/util/Scanner.java#L966-L1008 |
33,082 | google/j2objc | jre_emul/android/platform/libcore/ojluni/src/main/java/java/util/Scanner.java | Scanner.matchPatternInBuffer | private String matchPatternInBuffer(Pattern pattern) {
matchValid = false;
matcher.usePattern(pattern);
matcher.region(position, buf.limit());
if (matcher.lookingAt()) {
if (matcher.hitEnd() && (!sourceClosed)) {
// Get more input and try again
... | java | private String matchPatternInBuffer(Pattern pattern) {
matchValid = false;
matcher.usePattern(pattern);
matcher.region(position, buf.limit());
if (matcher.lookingAt()) {
if (matcher.hitEnd() && (!sourceClosed)) {
// Get more input and try again
... | [
"private",
"String",
"matchPatternInBuffer",
"(",
"Pattern",
"pattern",
")",
"{",
"matchValid",
"=",
"false",
";",
"matcher",
".",
"usePattern",
"(",
"pattern",
")",
";",
"matcher",
".",
"region",
"(",
"position",
",",
"buf",
".",
"limit",
"(",
")",
")",
... | the current position | [
"the",
"current",
"position"
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/libcore/ojluni/src/main/java/java/util/Scanner.java#L1012-L1032 |
33,083 | google/j2objc | jre_emul/android/platform/libcore/ojluni/src/main/java/java/util/Scanner.java | Scanner.close | public void close() {
if (closed)
return;
if (source instanceof Closeable) {
try {
((Closeable)source).close();
} catch (IOException ioe) {
lastException = ioe;
}
}
sourceClosed = true;
source = null;... | java | public void close() {
if (closed)
return;
if (source instanceof Closeable) {
try {
((Closeable)source).close();
} catch (IOException ioe) {
lastException = ioe;
}
}
sourceClosed = true;
source = null;... | [
"public",
"void",
"close",
"(",
")",
"{",
"if",
"(",
"closed",
")",
"return",
";",
"if",
"(",
"source",
"instanceof",
"Closeable",
")",
"{",
"try",
"{",
"(",
"(",
"Closeable",
")",
"source",
")",
".",
"close",
"(",
")",
";",
"}",
"catch",
"(",
"I... | Closes this scanner.
<p> If this scanner has not yet been closed then if its underlying
{@linkplain java.lang.Readable readable} also implements the {@link
java.io.Closeable} interface then the readable's <tt>close</tt> method
will be invoked. If this scanner is already closed then invoking this
method will have no e... | [
"Closes",
"this",
"scanner",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/libcore/ojluni/src/main/java/java/util/Scanner.java#L1055-L1068 |
33,084 | google/j2objc | jre_emul/android/platform/libcore/ojluni/src/main/java/java/util/Scanner.java | Scanner.useLocale | public Scanner useLocale(Locale locale) {
if (locale.equals(this.locale))
return this;
this.locale = locale;
DecimalFormat df =
(DecimalFormat)NumberFormat.getNumberInstance(locale);
DecimalFormatSymbols dfs = DecimalFormatSymbols.getInstance(locale);
//... | java | public Scanner useLocale(Locale locale) {
if (locale.equals(this.locale))
return this;
this.locale = locale;
DecimalFormat df =
(DecimalFormat)NumberFormat.getNumberInstance(locale);
DecimalFormatSymbols dfs = DecimalFormatSymbols.getInstance(locale);
//... | [
"public",
"Scanner",
"useLocale",
"(",
"Locale",
"locale",
")",
"{",
"if",
"(",
"locale",
".",
"equals",
"(",
"this",
".",
"locale",
")",
")",
"return",
"this",
";",
"this",
".",
"locale",
"=",
"locale",
";",
"DecimalFormat",
"df",
"=",
"(",
"DecimalFo... | Sets this scanner's locale to the specified locale.
<p>A scanner's locale affects many elements of its default
primitive matching regular expressions; see
<a href= "#localized-numbers">localized numbers</a> above.
<p>Invoking the {@link #reset} method will set the scanner's locale to
the <a href= "#initial-locale">in... | [
"Sets",
"this",
"scanner",
"s",
"locale",
"to",
"the",
"specified",
"locale",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/libcore/ojluni/src/main/java/java/util/Scanner.java#L1147-L1184 |
33,085 | google/j2objc | jre_emul/android/platform/libcore/ojluni/src/main/java/java/util/Scanner.java | Scanner.useRadix | public Scanner useRadix(int radix) {
if ((radix < Character.MIN_RADIX) || (radix > Character.MAX_RADIX))
throw new IllegalArgumentException("radix:"+radix);
if (this.defaultRadix == radix)
return this;
this.defaultRadix = radix;
// Force rebuilding and recompilat... | java | public Scanner useRadix(int radix) {
if ((radix < Character.MIN_RADIX) || (radix > Character.MAX_RADIX))
throw new IllegalArgumentException("radix:"+radix);
if (this.defaultRadix == radix)
return this;
this.defaultRadix = radix;
// Force rebuilding and recompilat... | [
"public",
"Scanner",
"useRadix",
"(",
"int",
"radix",
")",
"{",
"if",
"(",
"(",
"radix",
"<",
"Character",
".",
"MIN_RADIX",
")",
"||",
"(",
"radix",
">",
"Character",
".",
"MAX_RADIX",
")",
")",
"throw",
"new",
"IllegalArgumentException",
"(",
"\"radix:\"... | Sets this scanner's default radix to the specified radix.
<p>A scanner's radix affects elements of its default
number matching regular expressions; see
<a href= "#localized-numbers">localized numbers</a> above.
<p>If the radix is less than <code>Character.MIN_RADIX</code>
or greater than <code>Character.MAX_RADIX</co... | [
"Sets",
"this",
"scanner",
"s",
"default",
"radix",
"to",
"the",
"specified",
"radix",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/libcore/ojluni/src/main/java/java/util/Scanner.java#L1217-L1227 |
33,086 | google/j2objc | jre_emul/android/platform/libcore/ojluni/src/main/java/java/util/Scanner.java | Scanner.setRadix | private void setRadix(int radix) {
// Android-changed: Complain loudly if a bogus radix is being set.
if (radix > Character.MAX_RADIX) {
throw new IllegalArgumentException("radix == " + radix);
}
if (this.radix != radix) {
// Force rebuilding and recompilation of... | java | private void setRadix(int radix) {
// Android-changed: Complain loudly if a bogus radix is being set.
if (radix > Character.MAX_RADIX) {
throw new IllegalArgumentException("radix == " + radix);
}
if (this.radix != radix) {
// Force rebuilding and recompilation of... | [
"private",
"void",
"setRadix",
"(",
"int",
"radix",
")",
"{",
"// Android-changed: Complain loudly if a bogus radix is being set.",
"if",
"(",
"radix",
">",
"Character",
".",
"MAX_RADIX",
")",
"{",
"throw",
"new",
"IllegalArgumentException",
"(",
"\"radix == \"",
"+",
... | the default is left untouched. | [
"the",
"default",
"is",
"left",
"untouched",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/libcore/ojluni/src/main/java/java/util/Scanner.java#L1231-L1242 |
33,087 | google/j2objc | jre_emul/android/platform/libcore/ojluni/src/main/java/java/util/Scanner.java | Scanner.hasNext | public boolean hasNext() {
ensureOpen();
saveState();
while (!sourceClosed) {
if (hasTokenInBuffer())
return revertState(true);
readInput();
}
boolean result = hasTokenInBuffer();
return revertState(result);
} | java | public boolean hasNext() {
ensureOpen();
saveState();
while (!sourceClosed) {
if (hasTokenInBuffer())
return revertState(true);
readInput();
}
boolean result = hasTokenInBuffer();
return revertState(result);
} | [
"public",
"boolean",
"hasNext",
"(",
")",
"{",
"ensureOpen",
"(",
")",
";",
"saveState",
"(",
")",
";",
"while",
"(",
"!",
"sourceClosed",
")",
"{",
"if",
"(",
"hasTokenInBuffer",
"(",
")",
")",
"return",
"revertState",
"(",
"true",
")",
";",
"readInpu... | Returns true if this scanner has another token in its input.
This method may block while waiting for input to scan.
The scanner does not advance past any input.
@return true if and only if this scanner has another token
@throws IllegalStateException if this scanner is closed
@see java.util.Iterator | [
"Returns",
"true",
"if",
"this",
"scanner",
"has",
"another",
"token",
"in",
"its",
"input",
".",
"This",
"method",
"may",
"block",
"while",
"waiting",
"for",
"input",
"to",
"scan",
".",
"The",
"scanner",
"does",
"not",
"advance",
"past",
"any",
"input",
... | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/libcore/ojluni/src/main/java/java/util/Scanner.java#L1305-L1315 |
33,088 | google/j2objc | jre_emul/android/platform/libcore/ojluni/src/main/java/java/util/Scanner.java | Scanner.hasNext | public boolean hasNext(Pattern pattern) {
ensureOpen();
if (pattern == null)
throw new NullPointerException();
hasNextPattern = null;
saveState();
while (true) {
if (getCompleteTokenInBuffer(pattern) != null) {
matchValid = true;
... | java | public boolean hasNext(Pattern pattern) {
ensureOpen();
if (pattern == null)
throw new NullPointerException();
hasNextPattern = null;
saveState();
while (true) {
if (getCompleteTokenInBuffer(pattern) != null) {
matchValid = true;
... | [
"public",
"boolean",
"hasNext",
"(",
"Pattern",
"pattern",
")",
"{",
"ensureOpen",
"(",
")",
";",
"if",
"(",
"pattern",
"==",
"null",
")",
"throw",
"new",
"NullPointerException",
"(",
")",
";",
"hasNextPattern",
"=",
"null",
";",
"saveState",
"(",
")",
"... | Returns true if the next complete token matches the specified pattern.
A complete token is prefixed and postfixed by input that matches
the delimiter pattern. This method may block while waiting for input.
The scanner does not advance past any input.
@param pattern the pattern to scan for
@return true if and only if t... | [
"Returns",
"true",
"if",
"the",
"next",
"complete",
"token",
"matches",
"the",
"specified",
"pattern",
".",
"A",
"complete",
"token",
"is",
"prefixed",
"and",
"postfixed",
"by",
"input",
"that",
"matches",
"the",
"delimiter",
"pattern",
".",
"This",
"method",
... | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/libcore/ojluni/src/main/java/java/util/Scanner.java#L1404-L1422 |
33,089 | google/j2objc | jre_emul/android/platform/libcore/ojluni/src/main/java/java/util/Scanner.java | Scanner.hasNextLine | public boolean hasNextLine() {
saveState();
String result = findWithinHorizon(linePattern(), 0);
if (result != null) {
MatchResult mr = this.match();
String lineSep = mr.group(1);
if (lineSep != null) {
result = result.substring(0, result.leng... | java | public boolean hasNextLine() {
saveState();
String result = findWithinHorizon(linePattern(), 0);
if (result != null) {
MatchResult mr = this.match();
String lineSep = mr.group(1);
if (lineSep != null) {
result = result.substring(0, result.leng... | [
"public",
"boolean",
"hasNextLine",
"(",
")",
"{",
"saveState",
"(",
")",
";",
"String",
"result",
"=",
"findWithinHorizon",
"(",
"linePattern",
"(",
")",
",",
"0",
")",
";",
"if",
"(",
"result",
"!=",
"null",
")",
"{",
"MatchResult",
"mr",
"=",
"this"... | Returns true if there is another line in the input of this scanner.
This method may block while waiting for input. The scanner does not
advance past any input.
@return true if and only if this scanner has another line of input
@throws IllegalStateException if this scanner is closed | [
"Returns",
"true",
"if",
"there",
"is",
"another",
"line",
"in",
"the",
"input",
"of",
"this",
"scanner",
".",
"This",
"method",
"may",
"block",
"while",
"waiting",
"for",
"input",
".",
"The",
"scanner",
"does",
"not",
"advance",
"past",
"any",
"input",
... | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/libcore/ojluni/src/main/java/java/util/Scanner.java#L1469-L1487 |
33,090 | google/j2objc | jre_emul/android/platform/libcore/ojluni/src/main/java/java/util/Scanner.java | Scanner.nextLine | public String nextLine() {
if (hasNextPattern == linePattern())
return getCachedResult();
clearCaches();
String result = findWithinHorizon(linePattern, 0);
if (result == null)
throw new NoSuchElementException("No line found");
MatchResult mr = this.match(... | java | public String nextLine() {
if (hasNextPattern == linePattern())
return getCachedResult();
clearCaches();
String result = findWithinHorizon(linePattern, 0);
if (result == null)
throw new NoSuchElementException("No line found");
MatchResult mr = this.match(... | [
"public",
"String",
"nextLine",
"(",
")",
"{",
"if",
"(",
"hasNextPattern",
"==",
"linePattern",
"(",
")",
")",
"return",
"getCachedResult",
"(",
")",
";",
"clearCaches",
"(",
")",
";",
"String",
"result",
"=",
"findWithinHorizon",
"(",
"linePattern",
",",
... | Advances this scanner past the current line and returns the input
that was skipped.
This method returns the rest of the current line, excluding any line
separator at the end. The position is set to the beginning of the next
line.
<p>Since this method continues to search through the input looking
for a line separator,... | [
"Advances",
"this",
"scanner",
"past",
"the",
"current",
"line",
"and",
"returns",
"the",
"input",
"that",
"was",
"skipped",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/libcore/ojluni/src/main/java/java/util/Scanner.java#L1505-L1521 |
33,091 | google/j2objc | jre_emul/android/platform/libcore/ojluni/src/main/java/java/util/Scanner.java | Scanner.findWithinHorizon | public String findWithinHorizon(String pattern, int horizon) {
return findWithinHorizon(patternCache.forName(pattern), horizon);
} | java | public String findWithinHorizon(String pattern, int horizon) {
return findWithinHorizon(patternCache.forName(pattern), horizon);
} | [
"public",
"String",
"findWithinHorizon",
"(",
"String",
"pattern",
",",
"int",
"horizon",
")",
"{",
"return",
"findWithinHorizon",
"(",
"patternCache",
".",
"forName",
"(",
"pattern",
")",
",",
"horizon",
")",
";",
"}"
] | Attempts to find the next occurrence of a pattern constructed from the
specified string, ignoring delimiters.
<p>An invocation of this method of the form
<tt>findWithinHorizon(pattern)</tt> behaves in exactly the same way as
the invocation
<tt>findWithinHorizon(Pattern.compile(pattern, horizon))</tt>.
@param pattern ... | [
"Attempts",
"to",
"find",
"the",
"next",
"occurrence",
"of",
"a",
"pattern",
"constructed",
"from",
"the",
"specified",
"string",
"ignoring",
"delimiters",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/libcore/ojluni/src/main/java/java/util/Scanner.java#L1606-L1608 |
33,092 | google/j2objc | jre_emul/android/platform/libcore/ojluni/src/main/java/java/util/Scanner.java | Scanner.findWithinHorizon | public String findWithinHorizon(Pattern pattern, int horizon) {
ensureOpen();
if (pattern == null)
throw new NullPointerException();
if (horizon < 0)
throw new IllegalArgumentException("horizon < 0");
clearCaches();
// Search for the pattern
while... | java | public String findWithinHorizon(Pattern pattern, int horizon) {
ensureOpen();
if (pattern == null)
throw new NullPointerException();
if (horizon < 0)
throw new IllegalArgumentException("horizon < 0");
clearCaches();
// Search for the pattern
while... | [
"public",
"String",
"findWithinHorizon",
"(",
"Pattern",
"pattern",
",",
"int",
"horizon",
")",
"{",
"ensureOpen",
"(",
")",
";",
"if",
"(",
"pattern",
"==",
"null",
")",
"throw",
"new",
"NullPointerException",
"(",
")",
";",
"if",
"(",
"horizon",
"<",
"... | Attempts to find the next occurrence of the specified pattern.
<p>This method searches through the input up to the specified
search horizon, ignoring delimiters. If the pattern is found the
scanner advances past the input that matched and returns the string
that matched the pattern. If no such pattern is detected then... | [
"Attempts",
"to",
"find",
"the",
"next",
"occurrence",
"of",
"the",
"specified",
"pattern",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/libcore/ojluni/src/main/java/java/util/Scanner.java#L1641-L1662 |
33,093 | google/j2objc | jre_emul/android/platform/libcore/ojluni/src/main/java/java/util/Scanner.java | Scanner.skip | public Scanner skip(Pattern pattern) {
ensureOpen();
if (pattern == null)
throw new NullPointerException();
clearCaches();
// Search for the pattern
while (true) {
String token = matchPatternInBuffer(pattern);
if (token != null) {
... | java | public Scanner skip(Pattern pattern) {
ensureOpen();
if (pattern == null)
throw new NullPointerException();
clearCaches();
// Search for the pattern
while (true) {
String token = matchPatternInBuffer(pattern);
if (token != null) {
... | [
"public",
"Scanner",
"skip",
"(",
"Pattern",
"pattern",
")",
"{",
"ensureOpen",
"(",
")",
";",
"if",
"(",
"pattern",
"==",
"null",
")",
"throw",
"new",
"NullPointerException",
"(",
")",
";",
"clearCaches",
"(",
")",
";",
"// Search for the pattern",
"while",... | Skips input that matches the specified pattern, ignoring delimiters.
This method will skip input if an anchored match of the specified
pattern succeeds.
<p>If a match to the specified pattern is not found at the
current position, then no input is skipped and a
<tt>NoSuchElementException</tt> is thrown.
<p>Since this ... | [
"Skips",
"input",
"that",
"matches",
"the",
"specified",
"pattern",
"ignoring",
"delimiters",
".",
"This",
"method",
"will",
"skip",
"input",
"if",
"an",
"anchored",
"match",
"of",
"the",
"specified",
"pattern",
"succeeds",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/libcore/ojluni/src/main/java/java/util/Scanner.java#L1687-L1706 |
33,094 | google/j2objc | jre_emul/android/platform/libcore/ojluni/src/main/java/java/util/Scanner.java | Scanner.processIntegerToken | private String processIntegerToken(String token) {
String result = token.replaceAll(""+groupSeparator, "");
boolean isNegative = false;
int preLen = negativePrefix.length();
if ((preLen > 0) && result.startsWith(negativePrefix)) {
isNegative = true;
result = resul... | java | private String processIntegerToken(String token) {
String result = token.replaceAll(""+groupSeparator, "");
boolean isNegative = false;
int preLen = negativePrefix.length();
if ((preLen > 0) && result.startsWith(negativePrefix)) {
isNegative = true;
result = resul... | [
"private",
"String",
"processIntegerToken",
"(",
"String",
"token",
")",
"{",
"String",
"result",
"=",
"token",
".",
"replaceAll",
"(",
"\"\"",
"+",
"groupSeparator",
",",
"\"\"",
")",
";",
"boolean",
"isNegative",
"=",
"false",
";",
"int",
"preLen",
"=",
... | The integer token must be stripped of prefixes, group separators,
and suffixes, non ascii digits must be converted into ascii digits
before parse will accept it. | [
"The",
"integer",
"token",
"must",
"be",
"stripped",
"of",
"prefixes",
"group",
"separators",
"and",
"suffixes",
"non",
"ascii",
"digits",
"must",
"be",
"converted",
"into",
"ascii",
"digits",
"before",
"parse",
"will",
"accept",
"it",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/libcore/ojluni/src/main/java/java/util/Scanner.java#L2013-L2030 |
33,095 | google/j2objc | jre_emul/android/platform/libcore/ojluni/src/main/java/java/util/Scanner.java | Scanner.processFloatToken | private String processFloatToken(String token) {
String result = token.replaceAll(groupSeparator, "");
if (!decimalSeparator.equals("\\."))
result = result.replaceAll(decimalSeparator, ".");
boolean isNegative = false;
int preLen = negativePrefix.length();
if ((preLen... | java | private String processFloatToken(String token) {
String result = token.replaceAll(groupSeparator, "");
if (!decimalSeparator.equals("\\."))
result = result.replaceAll(decimalSeparator, ".");
boolean isNegative = false;
int preLen = negativePrefix.length();
if ((preLen... | [
"private",
"String",
"processFloatToken",
"(",
"String",
"token",
")",
"{",
"String",
"result",
"=",
"token",
".",
"replaceAll",
"(",
"groupSeparator",
",",
"\"\"",
")",
";",
"if",
"(",
"!",
"decimalSeparator",
".",
"equals",
"(",
"\"\\\\.\"",
")",
")",
"r... | The float token must be stripped of prefixes, group separators,
and suffixes, non ascii digits must be converted into ascii digits
before parseFloat will accept it.
If there are non-ascii digits in the token these digits must
be processed before the token is passed to parseFloat. | [
"The",
"float",
"token",
"must",
"be",
"stripped",
"of",
"prefixes",
"group",
"separators",
"and",
"suffixes",
"non",
"ascii",
"digits",
"must",
"be",
"converted",
"into",
"ascii",
"digits",
"before",
"parseFloat",
"will",
"accept",
"it",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/libcore/ojluni/src/main/java/java/util/Scanner.java#L2212-L2258 |
33,096 | google/j2objc | jre_emul/android/platform/libcore/ojluni/src/main/java/java/util/Scanner.java | Scanner.reset | public Scanner reset() {
delimPattern = WHITESPACE_PATTERN;
useLocale(Locale.getDefault(Locale.Category.FORMAT));
useRadix(10);
clearCaches();
return this;
} | java | public Scanner reset() {
delimPattern = WHITESPACE_PATTERN;
useLocale(Locale.getDefault(Locale.Category.FORMAT));
useRadix(10);
clearCaches();
return this;
} | [
"public",
"Scanner",
"reset",
"(",
")",
"{",
"delimPattern",
"=",
"WHITESPACE_PATTERN",
";",
"useLocale",
"(",
"Locale",
".",
"getDefault",
"(",
"Locale",
".",
"Category",
".",
"FORMAT",
")",
")",
";",
"useRadix",
"(",
"10",
")",
";",
"clearCaches",
"(",
... | Resets this scanner.
<p> Resetting a scanner discards all of its explicit state
information which may have been changed by invocations of {@link
#useDelimiter}, {@link #useLocale}, or {@link #useRadix}.
<p> An invocation of this method of the form
<tt>scanner.reset()</tt> behaves in exactly the same way as the
invoca... | [
"Resets",
"this",
"scanner",
"."
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/libcore/ojluni/src/main/java/java/util/Scanner.java#L2585-L2591 |
33,097 | google/j2objc | jre_emul/android/platform/libcore/luni/src/main/java/org/xml/sax/ext/Attributes2Impl.java | Attributes2Impl.removeAttribute | public void removeAttribute (int index)
{
int origMax = getLength () - 1;
super.removeAttribute (index);
if (index != origMax) {
System.arraycopy (declared, index + 1, declared, index,
origMax - index);
System.arraycopy (specified, index + 1, specified, index,
or... | java | public void removeAttribute (int index)
{
int origMax = getLength () - 1;
super.removeAttribute (index);
if (index != origMax) {
System.arraycopy (declared, index + 1, declared, index,
origMax - index);
System.arraycopy (specified, index + 1, specified, index,
or... | [
"public",
"void",
"removeAttribute",
"(",
"int",
"index",
")",
"{",
"int",
"origMax",
"=",
"getLength",
"(",
")",
"-",
"1",
";",
"super",
".",
"removeAttribute",
"(",
"index",
")",
";",
"if",
"(",
"index",
"!=",
"origMax",
")",
"{",
"System",
".",
"a... | javadoc entirely from superclass | [
"javadoc",
"entirely",
"from",
"superclass"
] | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/libcore/luni/src/main/java/org/xml/sax/ext/Attributes2Impl.java#L263-L274 |
33,098 | google/j2objc | jre_emul/android/platform/libcore/luni/src/main/java/org/xml/sax/ext/Attributes2Impl.java | Attributes2Impl.setDeclared | public void setDeclared (int index, boolean value)
{
if (index < 0 || index >= getLength ())
throw new ArrayIndexOutOfBoundsException (
"No attribute at index: " + index);
declared [index] = value;
} | java | public void setDeclared (int index, boolean value)
{
if (index < 0 || index >= getLength ())
throw new ArrayIndexOutOfBoundsException (
"No attribute at index: " + index);
declared [index] = value;
} | [
"public",
"void",
"setDeclared",
"(",
"int",
"index",
",",
"boolean",
"value",
")",
"{",
"if",
"(",
"index",
"<",
"0",
"||",
"index",
">=",
"getLength",
"(",
")",
")",
"throw",
"new",
"ArrayIndexOutOfBoundsException",
"(",
"\"No attribute at index: \"",
"+",
... | Assign a value to the "declared" flag of a specific attribute.
This is normally needed only for attributes of type CDATA,
including attributes whose type is changed to or from CDATA.
@param index The index of the attribute (zero-based).
@param value The desired flag value.
@exception java.lang.ArrayIndexOutOfBoundsExc... | [
"Assign",
"a",
"value",
"to",
"the",
"declared",
"flag",
"of",
"a",
"specific",
"attribute",
".",
"This",
"is",
"normally",
"needed",
"only",
"for",
"attributes",
"of",
"type",
"CDATA",
"including",
"attributes",
"whose",
"type",
"is",
"changed",
"to",
"or",... | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/libcore/luni/src/main/java/org/xml/sax/ext/Attributes2Impl.java#L288-L294 |
33,099 | google/j2objc | jre_emul/android/platform/libcore/luni/src/main/java/org/xml/sax/ext/Attributes2Impl.java | Attributes2Impl.setSpecified | public void setSpecified (int index, boolean value)
{
if (index < 0 || index >= getLength ())
throw new ArrayIndexOutOfBoundsException (
"No attribute at index: " + index);
specified [index] = value;
} | java | public void setSpecified (int index, boolean value)
{
if (index < 0 || index >= getLength ())
throw new ArrayIndexOutOfBoundsException (
"No attribute at index: " + index);
specified [index] = value;
} | [
"public",
"void",
"setSpecified",
"(",
"int",
"index",
",",
"boolean",
"value",
")",
"{",
"if",
"(",
"index",
"<",
"0",
"||",
"index",
">=",
"getLength",
"(",
")",
")",
"throw",
"new",
"ArrayIndexOutOfBoundsException",
"(",
"\"No attribute at index: \"",
"+",
... | Assign a value to the "specified" flag of a specific attribute.
This is the only way this flag can be cleared, except clearing
by initialization with the copy constructor.
@param index The index of the attribute (zero-based).
@param value The desired flag value.
@exception java.lang.ArrayIndexOutOfBoundsException When... | [
"Assign",
"a",
"value",
"to",
"the",
"specified",
"flag",
"of",
"a",
"specific",
"attribute",
".",
"This",
"is",
"the",
"only",
"way",
"this",
"flag",
"can",
"be",
"cleared",
"except",
"clearing",
"by",
"initialization",
"with",
"the",
"copy",
"constructor",... | 471504a735b48d5d4ace51afa1542cc4790a921a | https://github.com/google/j2objc/blob/471504a735b48d5d4ace51afa1542cc4790a921a/jre_emul/android/platform/libcore/luni/src/main/java/org/xml/sax/ext/Attributes2Impl.java#L307-L313 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.