docstring_tokens
list | code_tokens
list |
---|---|
[
"returns",
"the",
"name",
"of",
"the",
"executor",
"that",
"this",
"factory",
"creates"
] |
[
"string",
"get",
"name",
"(",
")",
";"
] |
[
"the",
"{",
"@",
"link",
"resource",
"calculator",
"}",
"returned",
"by",
"this",
"method",
"should",
"be",
"used",
"for",
"any",
"calculations",
"involving",
"resources"
] |
[
"public",
"abstract",
"resource",
"calculator",
"get",
"resource",
"calculator",
"(",
")",
";"
] |
[
"returns",
"an",
"iterable",
"containing",
"all",
"combinations",
"weak",
"keys",
"and",
"weaksoft",
"values"
] |
[
"private",
"static",
"iterable",
"<",
"cache",
"builder",
"<",
"object",
",",
"object",
">",
">",
"all",
"key",
"value",
"strength",
"makers",
"(",
")",
"{",
"return",
"immutable",
"list",
"of",
"(",
"create",
"cache",
"builder",
"(",
")",
",",
"create",
"cache",
"builder",
"(",
")",
"weak",
"values",
"(",
")",
",",
"create",
"cache",
"builder",
"(",
")",
"soft",
"values",
"(",
")",
",",
"create",
"cache",
"builder",
"(",
")",
"weak",
"keys",
"(",
")",
",",
"create",
"cache",
"builder",
"(",
")",
"weak",
"keys",
"(",
")",
"weak",
"values",
"(",
")",
",",
"create",
"cache",
"builder",
"(",
")",
"weak",
"keys",
"(",
")",
"soft",
"values",
"(",
")",
")",
";",
"}"
] |
[
"sets",
"the",
"radius",
"of",
"the",
"transparent",
"circle",
"that",
"is",
"drawn",
"next",
"to",
"the",
"hole",
"in",
"the",
"piechart",
"in",
"percent",
"of",
"the",
"maximum",
"radius",
"(",
"max",
"=",
"the",
"radius",
"of",
"the",
"whole",
"chart",
")",
",",
"default",
"55",
"%",
"-",
">",
"means",
"5",
"%",
"larger",
"than",
"the",
"center",
"-",
"hole",
"by",
"default"
] |
[
"public",
"void",
"set",
"transparent",
"circle",
"radius",
"(",
"final",
"float",
"percent",
")",
"{",
"m",
"transparent",
"circle",
"radius",
"percent",
"=",
"percent",
";",
"}"
] |
[
"returns",
"a",
"set",
"of",
"resource",
"patterns",
"that",
"are",
"permitted",
"for",
"the",
"provided",
"privilege",
"the",
"returned",
"set",
"may",
"include",
"patterns",
"that",
"overlap",
"(",
"e",
"g",
"\"",
"object",
"\"",
"and",
"\"",
"object",
"1",
"\"",
")",
"and",
"may",
"also",
"include",
"patterns",
"that",
"are",
"defined",
"again",
"a",
"more",
"permissive",
"privilege",
"e",
"g",
"if",
"a",
"permission",
"grants",
"\"",
"my",
"-",
"app",
"\"",
",",
"\"",
"read",
"\"",
",",
"[",
"\"",
"user",
"\"",
"]",
"\"",
"my",
"-",
"app",
"\"",
",",
"\"",
"all",
"\"",
",",
"[",
"\"",
"userkimchy",
"\"",
",",
"\"",
"config",
"\"",
"]",
"then",
"<",
"code",
">",
"get",
"resource",
"patterns",
"(",
"my",
"app",
"read",
")",
"<",
"code",
">",
"would",
"return",
"<",
"code",
">",
"\"",
"user",
"\"",
",",
"\"",
"userkimchy",
"\"",
",",
"\"",
"config",
"\"",
"<",
"code",
">"
] |
[
"public",
"set",
"<",
"string",
">",
"get",
"resource",
"patterns",
"(",
"application",
"privilege",
"privilege",
")",
"{",
"return",
"permissions",
"stream",
"(",
")",
"filter",
"(",
"e",
"-",
">",
"e",
"matches",
"privilege",
"(",
"privilege",
")",
")",
"map",
"(",
"e",
"-",
">",
"e",
"resource",
"names",
")",
"flat",
"map",
"(",
"set",
":",
":",
"stream",
")",
"collect",
"(",
"collectors",
"to",
"set",
"(",
")",
")",
";",
"}"
] |
[
"select",
"or",
"deselect",
"specified",
"option"
] |
[
"private",
"void",
"set",
"selected",
"(",
"web",
"element",
"option",
",",
"boolean",
"select",
")",
"{",
"if",
"(",
"option",
"is",
"selected",
"(",
")",
"!",
"=",
"select",
")",
"{",
"option",
"click",
"(",
")",
";",
"}",
"}"
] |
[
"test",
"the",
"property",
"'",
"category",
"'"
] |
[
"public",
"void",
"category",
"test",
"(",
")",
"{",
"/",
"/",
"todo",
":",
"test",
"category",
"}"
] |
[
"writes",
"an",
"{",
"@",
"code",
"int",
"}",
"as",
"specified",
"by",
"{",
"@",
"link",
"data",
"output",
"stream",
"#",
"write",
"int",
"(",
"int",
")",
"}",
",",
"except",
"using",
"little",
"-",
"endian",
"byte",
"order"
] |
[
"public",
"void",
"write",
"int",
"(",
"int",
"v",
")",
"throws",
"i",
"o",
"exception",
"{",
"out",
"write",
"(",
"0x",
"f",
"f",
"&",
"v",
")",
";",
"out",
"write",
"(",
"0x",
"f",
"f",
"&",
"(",
"v",
">",
">",
"8",
")",
")",
";",
"out",
"write",
"(",
"0x",
"f",
"f",
"&",
"(",
"v",
">",
">",
"16",
")",
")",
";",
"out",
"write",
"(",
"0x",
"f",
"f",
"&",
"(",
"v",
">",
">",
"24",
")",
")",
";",
"}"
] |
[
"test",
"create",
",",
"update",
"and",
"delete",
"events",
"of",
"process",
"instances"
] |
[
"public",
"void",
"test",
"execution",
"events",
"(",
")",
"throws",
"exception",
"{",
"process",
"instance",
"process",
"instance",
"=",
"runtime",
"service",
"start",
"process",
"instance",
"by",
"key",
"(",
"\"",
"one",
"task",
"process",
"\"",
")",
";",
"assert",
"that",
"(",
"process",
"instance",
")",
"is",
"not",
"null",
"(",
")",
";",
"/",
"/",
"check",
"create",
"-",
"event",
"assert",
"that",
"(",
"listener",
"get",
"events",
"received",
"(",
")",
")",
"has",
"size",
"(",
"6",
")",
";",
"assert",
"that",
"(",
"listener",
"get",
"events",
"received",
"(",
")",
"get",
"(",
"0",
")",
")",
"is",
"instance",
"of",
"(",
"activiti",
"entity",
"event",
"class",
")",
";",
"activiti",
"entity",
"event",
"event",
"=",
"(",
"activiti",
"entity",
"event",
")",
"listener",
"get",
"events",
"received",
"(",
")",
"get",
"(",
"0",
")",
";",
"assert",
"that",
"(",
"event",
"get",
"type",
"(",
")",
")",
"is",
"equal",
"to",
"(",
"activiti",
"event",
"type",
"entity",
"created",
")",
";",
"assert",
"that",
"(",
"(",
"(",
"execution",
")",
"event",
"get",
"entity",
"(",
")",
")",
"get",
"process",
"instance",
"id",
"(",
")",
")",
"is",
"equal",
"to",
"(",
"process",
"instance",
"get",
"id",
"(",
")",
")",
";",
"event",
"=",
"(",
"activiti",
"entity",
"event",
")",
"listener",
"get",
"events",
"received",
"(",
")",
"get",
"(",
"1",
")",
";",
"assert",
"that",
"(",
"event",
"get",
"type",
"(",
")",
")",
"is",
"equal",
"to",
"(",
"activiti",
"event",
"type",
"entity",
"created",
")",
";",
"assert",
"that",
"(",
"(",
"(",
"execution",
")",
"event",
"get",
"entity",
"(",
")",
")",
"get",
"process",
"instance",
"id",
"(",
")",
")",
"is",
"equal",
"to",
"(",
"process",
"instance",
"get",
"id",
"(",
")",
")",
";",
"event",
"=",
"(",
"activiti",
"entity",
"event",
")",
"listener",
"get",
"events",
"received",
"(",
")",
"get",
"(",
"2",
")",
";",
"assert",
"that",
"(",
"event",
"get",
"type",
"(",
")",
")",
"is",
"equal",
"to",
"(",
"activiti",
"event",
"type",
"entity",
"initialized",
")",
";",
"assert",
"that",
"(",
"(",
"(",
"execution",
")",
"event",
"get",
"entity",
"(",
")",
")",
"get",
"process",
"instance",
"id",
"(",
")",
")",
"is",
"equal",
"to",
"(",
"process",
"instance",
"get",
"id",
"(",
")",
")",
";",
"event",
"=",
"(",
"activiti",
"entity",
"event",
")",
"listener",
"get",
"events",
"received",
"(",
")",
"get",
"(",
"3",
")",
";",
"assert",
"that",
"(",
"event",
"get",
"type",
"(",
")",
")",
"is",
"equal",
"to",
"(",
"activiti",
"event",
"type",
"entity",
"initialized",
")",
";",
"assert",
"that",
"(",
"(",
"(",
"execution",
")",
"event",
"get",
"entity",
"(",
")",
")",
"get",
"process",
"instance",
"id",
"(",
")",
")",
"is",
"equal",
"to",
"(",
"process",
"instance",
"get",
"id",
"(",
")",
")",
";",
"listener",
"clear",
"events",
"received",
"(",
")",
";",
"/",
"/",
"check",
"update",
"event",
"when",
"suspended",
"/",
"activated",
"runtime",
"service",
"suspend",
"process",
"instance",
"by",
"id",
"(",
"process",
"instance",
"get",
"id",
"(",
")",
")",
";",
"runtime",
"service",
"activate",
"process",
"instance",
"by",
"id",
"(",
"process",
"instance",
"get",
"id",
"(",
")",
")",
";",
"assert",
"that",
"(",
"listener",
"get",
"events",
"received",
"(",
")",
")",
"has",
"size",
"(",
"4",
")",
";",
"event",
"=",
"(",
"activiti",
"entity",
"event",
")",
"listener",
"get",
"events",
"received",
"(",
")",
"get",
"(",
"0",
")",
";",
"assert",
"that",
"(",
"(",
"(",
"execution",
")",
"event",
"get",
"entity",
"(",
")",
")",
"get",
"process",
"instance",
"id",
"(",
")",
")",
"is",
"equal",
"to",
"(",
"process",
"instance",
"get",
"id",
"(",
")",
")",
";",
"assert",
"that",
"(",
"event",
"get",
"type",
"(",
")",
")",
"is",
"equal",
"to",
"(",
"activiti",
"event",
"type",
"entity",
"suspended",
")",
";",
"event",
"=",
"(",
"activiti",
"entity",
"event",
")",
"listener",
"get",
"events",
"received",
"(",
")",
"get",
"(",
"1",
")",
";",
"assert",
"that",
"(",
"(",
"(",
"execution",
")",
"event",
"get",
"entity",
"(",
")",
")",
"get",
"process",
"instance",
"id",
"(",
")",
")",
"is",
"equal",
"to",
"(",
"process",
"instance",
"get",
"id",
"(",
")",
")",
";",
"assert",
"that",
"(",
"event",
"get",
"type",
"(",
")",
")",
"is",
"equal",
"to",
"(",
"activiti",
"event",
"type",
"entity",
"suspended",
")",
";",
"event",
"=",
"(",
"activiti",
"entity",
"event",
")",
"listener",
"get",
"events",
"received",
"(",
")",
"get",
"(",
"2",
")",
";",
"assert",
"that",
"(",
"event",
"get",
"type",
"(",
")",
")",
"is",
"equal",
"to",
"(",
"activiti",
"event",
"type",
"entity",
"activated",
")",
";",
"assert",
"that",
"(",
"(",
"(",
"execution",
")",
"event",
"get",
"entity",
"(",
")",
")",
"get",
"process",
"instance",
"id",
"(",
")",
")",
"is",
"equal",
"to",
"(",
"process",
"instance",
"get",
"id",
"(",
")",
")",
";",
"event",
"=",
"(",
"activiti",
"entity",
"event",
")",
"listener",
"get",
"events",
"received",
"(",
")",
"get",
"(",
"3",
")",
";",
"assert",
"that",
"(",
"event",
"get",
"type",
"(",
")",
")",
"is",
"equal",
"to",
"(",
"activiti",
"event",
"type",
"entity",
"activated",
")",
";",
"assert",
"that",
"(",
"(",
"(",
"execution",
")",
"event",
"get",
"entity",
"(",
")",
")",
"get",
"process",
"instance",
"id",
"(",
")",
")",
"is",
"equal",
"to",
"(",
"process",
"instance",
"get",
"id",
"(",
")",
")",
";",
"listener",
"clear",
"events",
"received",
"(",
")",
";",
"/",
"/",
"check",
"update",
"event",
"when",
"process",
"-",
"definition",
"is",
"supended",
"(",
"should",
"/",
"/",
"cascade",
"suspend",
"/",
"activate",
"all",
"process",
"instances",
")",
"repository",
"service",
"suspend",
"process",
"definition",
"by",
"id",
"(",
"process",
"instance",
"get",
"process",
"definition",
"id",
"(",
")",
",",
"true",
",",
"null",
")",
";",
"repository",
"service",
"activate",
"process",
"definition",
"by",
"id",
"(",
"process",
"instance",
"get",
"process",
"definition",
"id",
"(",
")",
",",
"true",
",",
"null",
")",
";",
"assert",
"that",
"(",
"listener",
"get",
"events",
"received",
"(",
")",
")",
"has",
"size",
"(",
"4",
")",
";",
"event",
"=",
"(",
"activiti",
"entity",
"event",
")",
"listener",
"get",
"events",
"received",
"(",
")",
"get",
"(",
"0",
")",
";",
"assert",
"that",
"(",
"(",
"(",
"execution",
")",
"event",
"get",
"entity",
"(",
")",
")",
"get",
"process",
"instance",
"id",
"(",
")",
")",
"is",
"equal",
"to",
"(",
"process",
"instance",
"get",
"id",
"(",
")",
")",
";",
"assert",
"that",
"(",
"event",
"get",
"type",
"(",
")",
")",
"is",
"equal",
"to",
"(",
"activiti",
"event",
"type",
"entity",
"suspended",
")",
";",
"event",
"=",
"(",
"activiti",
"entity",
"event",
")",
"listener",
"get",
"events",
"received",
"(",
")",
"get",
"(",
"1",
")",
";",
"assert",
"that",
"(",
"(",
"(",
"execution",
")",
"event",
"get",
"entity",
"(",
")",
")",
"get",
"process",
"instance",
"id",
"(",
")",
")",
"is",
"equal",
"to",
"(",
"process",
"instance",
"get",
"id",
"(",
")",
")",
";",
"assert",
"that",
"(",
"event",
"get",
"type",
"(",
")",
")",
"is",
"equal",
"to",
"(",
"activiti",
"event",
"type",
"entity",
"suspended",
")",
";",
"event",
"=",
"(",
"activiti",
"entity",
"event",
")",
"listener",
"get",
"events",
"received",
"(",
")",
"get",
"(",
"2",
")",
";",
"assert",
"that",
"(",
"event",
"get",
"type",
"(",
")",
")",
"is",
"equal",
"to",
"(",
"activiti",
"event",
"type",
"entity",
"activated",
")",
";",
"assert",
"that",
"(",
"(",
"(",
"execution",
")",
"event",
"get",
"entity",
"(",
")",
")",
"get",
"process",
"instance",
"id",
"(",
")",
")",
"is",
"equal",
"to",
"(",
"process",
"instance",
"get",
"id",
"(",
")",
")",
";",
"event",
"=",
"(",
"activiti",
"entity",
"event",
")",
"listener",
"get",
"events",
"received",
"(",
")",
"get",
"(",
"3",
")",
";",
"assert",
"that",
"(",
"event",
"get",
"type",
"(",
")",
")",
"is",
"equal",
"to",
"(",
"activiti",
"event",
"type",
"entity",
"activated",
")",
";",
"assert",
"that",
"(",
"(",
"(",
"execution",
")",
"event",
"get",
"entity",
"(",
")",
")",
"get",
"process",
"instance",
"id",
"(",
")",
")",
"is",
"equal",
"to",
"(",
"process",
"instance",
"get",
"id",
"(",
")",
")",
";",
"listener",
"clear",
"events",
"received",
"(",
")",
";",
"/",
"/",
"check",
"update",
"-",
"event",
"when",
"business",
"-",
"key",
"is",
"updated",
"runtime",
"service",
"update",
"business",
"key",
"(",
"process",
"instance",
"get",
"id",
"(",
")",
",",
"\"",
"thekey",
"\"",
")",
";",
"assert",
"that",
"(",
"listener",
"get",
"events",
"received",
"(",
")",
")",
"has",
"size",
"(",
"1",
")",
";",
"event",
"=",
"(",
"activiti",
"entity",
"event",
")",
"listener",
"get",
"events",
"received",
"(",
")",
"get",
"(",
"0",
")",
";",
"assert",
"that",
"(",
"(",
"(",
"execution",
")",
"event",
"get",
"entity",
"(",
")",
")",
"get",
"id",
"(",
")",
")",
"is",
"equal",
"to",
"(",
"process",
"instance",
"get",
"id",
"(",
")",
")",
";",
"assert",
"that",
"(",
"event",
"get",
"type",
"(",
")",
")",
"is",
"equal",
"to",
"(",
"activiti",
"event",
"type",
"entity",
"updated",
")",
";",
"listener",
"clear",
"events",
"received",
"(",
")",
";",
"runtime",
"service",
"delete",
"process",
"instance",
"(",
"process",
"instance",
"get",
"id",
"(",
")",
",",
"\"",
"testing",
"events",
"\"",
")",
";",
"assert",
"that",
"(",
"listener",
"get",
"events",
"received",
"(",
")",
")",
"extracting",
"(",
"activiti",
"event",
":",
":",
"get",
"type",
",",
"activiti",
"event",
":",
":",
"get",
"process",
"instance",
"id",
")",
"contains",
"(",
"tuple",
"(",
"activiti",
"event",
"type",
"process",
"cancelled",
",",
"process",
"instance",
"get",
"id",
"(",
")",
")",
",",
"tuple",
"(",
"activiti",
"event",
"type",
"entity",
"deleted",
",",
"process",
"instance",
"get",
"id",
"(",
")",
")",
")",
";",
"listener",
"clear",
"events",
"received",
"(",
")",
";",
"}"
] |
[
"inserts",
"the",
"given",
"value",
",",
"mapped",
"under",
"the",
"given",
"key",
"if",
"the",
"table",
"already",
"contains",
"a",
"value",
"for",
"the",
"key",
",",
"the",
"value",
"is",
"replaced",
"and",
"returned",
"if",
"no",
"value",
"is",
"contained",
",",
"yet",
",",
"the",
"function",
"returns",
"null"
] |
[
"public",
"final",
"v",
"put",
"(",
"k",
"key",
",",
"v",
"value",
")",
"{",
"final",
"int",
"hash",
"=",
"hash",
"(",
"key",
")",
";",
"final",
"int",
"slot",
"=",
"index",
"of",
"(",
"hash",
")",
";",
"/",
"/",
"search",
"the",
"chain",
"from",
"the",
"slot",
"for",
"(",
"entry",
"<",
"k",
",",
"v",
">",
"e",
"=",
"table",
"[",
"slot",
"]",
";",
"e",
"!",
"=",
"null",
";",
"e",
"=",
"e",
"next",
")",
"{",
"object",
"k",
";",
"if",
"(",
"e",
"hash",
"code",
"=",
"=",
"hash",
"&",
"&",
"(",
"(",
"k",
"=",
"e",
"key",
")",
"=",
"=",
"key",
"|",
"|",
"key",
"equals",
"(",
"k",
")",
")",
")",
"{",
"/",
"/",
"found",
"match",
"v",
"old",
"=",
"e",
"value",
";",
"e",
"value",
"=",
"value",
";",
"return",
"old",
";",
"}",
"}",
"/",
"/",
"no",
"match",
",",
"insert",
"a",
"new",
"value",
"insert",
"new",
"entry",
"(",
"hash",
",",
"key",
",",
"value",
",",
"slot",
")",
";",
"return",
"null",
";",
"}"
] |
[
"get",
"the",
"address",
"set",
"that",
"represents",
"the",
"addresses",
"consumed",
"by",
"this",
"table"
] |
[
"public",
"address",
"set",
"view",
"get",
"table",
"body",
"(",
")",
"{",
"address",
"set",
"set",
"=",
"new",
"address",
"set",
"(",
")",
";",
"set",
"add",
"range",
"(",
"top",
"address",
",",
"top",
"address",
"add",
"(",
"get",
"byte",
"length",
"(",
")",
"-",
"1",
")",
")",
";",
"if",
"(",
"top",
"index",
"address",
"!",
"=",
"null",
")",
"{",
"set",
"add",
"range",
"(",
"top",
"index",
"address",
",",
"top",
"index",
"address",
"add",
"(",
"index",
"len",
"-",
"1",
")",
")",
";",
"}",
"return",
"set",
";",
"}"
] |
[
"creates",
"customers",
"schema"
] |
[
"public",
"void",
"create",
"schema",
"(",
")",
"throws",
"s",
"q",
"l",
"exception",
"{",
"try",
"(",
"var",
"connection",
"=",
"driver",
"manager",
"get",
"connection",
"(",
"db",
"url",
")",
";",
"var",
"statement",
"=",
"connection",
"create",
"statement",
"(",
")",
")",
"{",
"statement",
"execute",
"(",
"customer",
"schema",
"sql",
"create",
"schema",
"sql",
")",
";",
"}",
"}"
] |
[
"checks",
"whether",
"the",
"given",
"sample",
"number",
"is",
"valid",
"and",
",",
"if",
"so",
",",
"reads",
"it",
"and",
"writes",
"it",
"in",
"{",
"@",
"code",
"sample",
"number",
"holder",
"}",
"if",
"the",
"sample",
"number",
"is",
"valid",
",",
"the",
"position",
"of",
"{",
"@",
"code",
"data",
"}",
"is",
"moved",
"to",
"the",
"byte",
"following",
"it",
"otherwise",
",",
"there",
"is",
"no",
"guarantee",
"on",
"the",
"position"
] |
[
"private",
"static",
"boolean",
"check",
"and",
"read",
"first",
"sample",
"number",
"(",
"parsable",
"byte",
"array",
"data",
",",
"flac",
"stream",
"metadata",
"flac",
"stream",
"metadata",
",",
"boolean",
"is",
"block",
"size",
"variable",
",",
"sample",
"number",
"holder",
"sample",
"number",
"holder",
")",
"{",
"long",
"utf",
"8",
"value",
";",
"try",
"{",
"utf",
"8",
"value",
"=",
"data",
"read",
"utf",
"8",
"encoded",
"long",
"(",
")",
";",
"}",
"catch",
"(",
"number",
"format",
"exception",
"e",
")",
"{",
"return",
"false",
";",
"}",
"sample",
"number",
"holder",
"sample",
"number",
"=",
"is",
"block",
"size",
"variable",
"?",
"utf",
"8",
"value",
":",
"utf",
"8",
"value",
"*",
"flac",
"stream",
"metadata",
"max",
"block",
"size",
"samples",
";",
"return",
"true",
";",
"}"
] |
[
"for",
"use",
"from",
"{",
"@",
"link",
"build",
"button",
"column",
"}"
] |
[
"default",
"boolean",
"is",
"parameterized",
"(",
")",
"{",
"return",
"get",
"parameterized",
"job",
"mix",
"in",
"(",
")",
"is",
"parameterized",
"(",
")",
";",
"}"
] |
[
"determine",
"if",
"one",
"or",
"more",
"equivalence",
"determinations",
"are",
"in",
"-",
"progress"
] |
[
"boolean",
"is",
"cache",
"active",
"(",
")",
"{",
"return",
"outstanding",
"request",
"count",
">",
"0",
";",
"}"
] |
[
"test",
"the",
"property",
"'",
"name",
"wrapped",
"array",
"'"
] |
[
"public",
"void",
"name",
"wrapped",
"array",
"test",
"(",
")",
"{",
"/",
"/",
"todo",
":",
"test",
"name",
"wrapped",
"array",
"}"
] |
[
"find",
"the",
"fields",
"constant",
"that",
"matches",
"name",
",",
"or",
"null",
"if",
"its",
"not",
"found"
] |
[
"public",
"static",
"fields",
"find",
"by",
"name",
"(",
"string",
"name",
")",
"{",
"return",
"by",
"name",
"get",
"(",
"name",
")",
";",
"}"
] |
[
"reuse",
"input",
"metadata",
"query",
"instance",
"if",
"it",
"could",
"cast",
"to",
"flink",
"rel",
"metadata",
"query",
"class",
",",
"or",
"create",
"one",
"if",
"not"
] |
[
"public",
"static",
"flink",
"rel",
"metadata",
"query",
"reuse",
"or",
"create",
"(",
"rel",
"metadata",
"query",
"mq",
")",
"{",
"if",
"(",
"mq",
"instanceof",
"flink",
"rel",
"metadata",
"query",
")",
"{",
"return",
"(",
"flink",
"rel",
"metadata",
"query",
")",
"mq",
";",
"}",
"else",
"{",
"return",
"instance",
"(",
")",
";",
"}",
"}"
] |
[
"whether",
"the",
"response",
"was",
"returned",
"successfully",
"either",
"by",
"executing",
"<",
"code",
">",
"run",
"(",
")",
"<",
"code",
">",
"or",
"from",
"cache"
] |
[
"public",
"boolean",
"is",
"successful",
"execution",
"(",
")",
"{",
"return",
"get",
"command",
"result",
"(",
")",
"get",
"event",
"counts",
"(",
")",
"contains",
"(",
"hystrix",
"event",
"type",
"success",
")",
";",
"}"
] |
[
"set",
"of",
"labels",
"relevant",
"to",
"this",
"job",
"this",
"method",
"is",
"used",
"to",
"determine",
"what",
"agents",
"are",
"relevant",
"to",
"jobs",
",",
"for",
"example",
"by",
"{",
"@",
"link",
"view",
"}",
"s",
"it",
"does",
"not",
"affect",
"the",
"scheduling",
"this",
"information",
"is",
"informational",
"and",
"the",
"best",
"-",
"effort",
"basis"
] |
[
"public",
"set",
"<",
"label",
">",
"get",
"relevant",
"labels",
"(",
")",
"{",
"return",
"collections",
"singleton",
"(",
"get",
"assigned",
"label",
"(",
")",
")",
";",
"}"
] |
[
"expect",
"an",
"operation",
"to",
"raise",
"an",
"unknown",
"store",
"exception"
] |
[
"public",
"static",
"<",
"t",
">",
"void",
"expect",
"unknown",
"store",
"(",
"callable",
"<",
"t",
">",
"eval",
")",
"throws",
"exception",
"{",
"intercept",
"(",
"unknown",
"store",
"exception",
"class",
",",
"eval",
")",
";",
"}"
] |
[
"a",
"utility",
"function",
"that",
"tries",
"to",
"read",
"up",
"to",
"<",
"code",
">",
"len",
"<",
"code",
">",
"bytes",
"from",
"<",
"code",
">",
"stm",
"<",
"code",
">"
] |
[
"protected",
"static",
"int",
"read",
"fully",
"(",
"input",
"stream",
"stm",
",",
"byte",
"[",
"]",
"buf",
",",
"int",
"offset",
",",
"int",
"len",
")",
"throws",
"i",
"o",
"exception",
"{",
"int",
"n",
"=",
"0",
";",
"for",
"(",
";",
";",
")",
"{",
"int",
"nread",
"=",
"stm",
"read",
"(",
"buf",
",",
"offset",
"+",
"n",
",",
"len",
"-",
"n",
")",
";",
"if",
"(",
"nread",
"<",
"=",
"0",
")",
"return",
"(",
"n",
"=",
"=",
"0",
")",
"?",
"nread",
":",
"n",
";",
"n",
"+",
"=",
"nread",
";",
"if",
"(",
"n",
">",
"=",
"len",
")",
"return",
"n",
";",
"}",
"}"
] |
[
"whether",
"the",
"replica",
"was",
"chosen",
"for",
"recovery"
] |
[
"boolean",
"get",
"chosen",
"as",
"primary",
"(",
")",
"{",
"return",
"chosen",
"as",
"primary",
";",
"}"
] |
[
"construct",
"a",
"uri",
";",
"raises",
"an",
"rte",
"if",
"it",
"won",
"'",
"t",
"parse",
"this",
"allows",
"it",
"to",
"be",
"used",
"in",
"static",
"constructors"
] |
[
"private",
"static",
"uri",
"uri",
"(",
"string",
"s",
")",
"{",
"try",
"{",
"return",
"new",
"uri",
"(",
"s",
")",
";",
"}",
"catch",
"(",
"u",
"r",
"i",
"syntax",
"exception",
"e",
")",
"{",
"throw",
"new",
"runtime",
"exception",
"(",
"e",
"to",
"string",
"(",
")",
",",
"e",
")",
";",
"}",
"}"
] |
[
"tests",
"that",
"track",
"selector",
"will",
"select",
"a",
"track",
"that",
"exceeds",
"the",
"renderer",
"'",
"s",
"capabilities",
"when",
"there",
"are",
"no",
"other",
"choice",
",",
"given",
"the",
"default",
"{",
"@",
"link",
"parameters",
"}"
] |
[
"public",
"void",
"select",
"tracks",
"with",
"no",
"track",
"within",
"capabilities",
"select",
"exceeded",
"capability",
"track",
"(",
")",
"throws",
"exception",
"{",
"track",
"group",
"array",
"track",
"groups",
"=",
"single",
"track",
"group",
"(",
"audio",
"format",
")",
";",
"track",
"selector",
"result",
"result",
"=",
"track",
"selector",
"select",
"tracks",
"(",
"new",
"renderer",
"capabilities",
"[",
"]",
"{",
"all",
"audio",
"format",
"exceeded",
"renderer",
"capabilities",
"}",
",",
"track",
"groups",
",",
"period",
"id",
",",
"timeline",
")",
";",
"assert",
"fixed",
"selection",
"(",
"result",
"selections",
"get",
"(",
"0",
")",
",",
"track",
"groups",
",",
"audio",
"format",
")",
";",
"}"
] |
[
"finds",
"all",
"the",
"matching",
"{",
"@",
"link",
"index",
"item",
"}",
"s",
"that",
"match",
"the",
"given",
"type",
"and",
"instantiate",
"them"
] |
[
"private",
"<",
"t",
">",
"collection",
"<",
"extension",
"component",
"<",
"t",
">",
">",
"find",
"(",
"class",
"<",
"t",
">",
"type",
",",
"list",
"<",
"index",
"item",
"<",
"extension",
",",
"object",
">",
">",
"indices",
")",
"{",
"list",
"<",
"extension",
"component",
"<",
"t",
">",
">",
"result",
"=",
"new",
"array",
"list",
"<",
">",
"(",
")",
";",
"for",
"(",
"index",
"item",
"<",
"extension",
",",
"object",
">",
"item",
":",
"indices",
")",
"{",
"try",
"{",
"class",
"<",
"?",
">",
"ext",
"type",
"=",
"get",
"class",
"from",
"index",
"(",
"item",
")",
";",
"if",
"(",
"type",
"is",
"assignable",
"from",
"(",
"ext",
"type",
")",
")",
"{",
"object",
"instance",
"=",
"item",
"instance",
"(",
")",
";",
"if",
"(",
"instance",
"!",
"=",
"null",
")",
"result",
"add",
"(",
"new",
"extension",
"component",
"<",
">",
"(",
"type",
"cast",
"(",
"instance",
")",
",",
"item",
"annotation",
"(",
")",
")",
")",
";",
"}",
"}",
"catch",
"(",
"linkage",
"error",
"|",
"exception",
"e",
")",
"{",
"/",
"/",
"sometimes",
"the",
"instantiation",
"fails",
"in",
"an",
"indirect",
"classloading",
"failure",
",",
"/",
"/",
"which",
"results",
"in",
"a",
"linkage",
"error",
"logger",
"log",
"(",
"log",
"level",
"(",
"item",
")",
",",
"\"",
"failed",
"to",
"load",
"\"",
"+",
"item",
"class",
"name",
"(",
")",
",",
"e",
")",
";",
"}",
"}",
"return",
"result",
";",
"}"
] |
[
"build",
"call",
"for",
"test",
"group",
"parameters"
] |
[
"public",
"okhttp",
"3",
"call",
"build",
"call",
"(",
"final",
"api",
"callback",
"callback",
")",
"throws",
"api",
"exception",
"{",
"return",
"test",
"group",
"parameters",
"call",
"(",
"required",
"string",
"group",
",",
"required",
"boolean",
"group",
",",
"required",
"int",
"6",
"4",
"group",
",",
"string",
"group",
",",
"boolean",
"group",
",",
"int",
"6",
"4",
"group",
",",
"callback",
")",
";",
"}"
] |
[
"similar",
"to",
"{",
"@",
"link",
"#",
"get",
"variable",
"(",
"string",
")",
"}",
",",
"including",
"the",
"searching",
"via",
"the",
"parent",
"scopes",
",",
"but",
"for",
"transient",
"variables",
"only",
"see",
"{",
"@",
"link",
"#",
"set",
"transient",
"variable",
"(",
"string",
",",
"object",
")",
"}",
"for",
"the",
"rules",
"on",
"'",
"transient",
"'",
"variables"
] |
[
"object",
"get",
"transient",
"variable",
"(",
"string",
"variable",
"name",
")",
";"
] |
[
"ensures",
"the",
"given",
"{",
"@",
"link",
"map",
"}",
"has",
"keys",
"that",
"have",
"{",
"@",
"link",
"label",
"}",
"type",
"and",
"values",
"that",
"have",
"either",
"{",
"@",
"link",
"iterable",
"}",
"or",
"{",
"@",
"link",
"depset",
"}",
"type",
",",
"and",
"raises",
"{",
"@",
"link",
"eval",
"exception",
"}",
"otherwise",
"returns",
"a",
"corresponding",
"map",
"where",
"any",
"sets",
"are",
"replaced",
"by",
"iterables"
] |
[
"private",
"static",
"map",
"<",
"label",
",",
"iterable",
"<",
"artifact",
">",
">",
"check",
"label",
"dict",
"(",
"map",
"<",
"?",
",",
"?",
">",
"label",
"dict",
")",
"throws",
"eval",
"exception",
"{",
"map",
"<",
"label",
",",
"iterable",
"<",
"artifact",
">",
">",
"converted",
"map",
"=",
"new",
"hash",
"map",
"<",
">",
"(",
")",
";",
"for",
"(",
"map",
"entry",
"<",
"?",
",",
"?",
">",
"entry",
":",
"label",
"dict",
"entry",
"set",
"(",
")",
")",
"{",
"object",
"key",
"=",
"entry",
"get",
"key",
"(",
")",
";",
"if",
"(",
"!",
"(",
"key",
"instanceof",
"label",
")",
")",
"{",
"throw",
"starlark",
"errorf",
"(",
"\"",
"invalid",
"key",
"%",
"s",
"in",
"'",
"label",
"dict",
"'",
"\"",
",",
"starlark",
"repr",
"(",
"key",
")",
")",
";",
"}",
"immutable",
"list",
"builder",
"<",
"artifact",
">",
"files",
"=",
"immutable",
"list",
"builder",
"(",
")",
";",
"object",
"val",
"=",
"entry",
"get",
"value",
"(",
")",
";",
"iterable",
"<",
"?",
">",
"val",
"iter",
";",
"if",
"(",
"val",
"instanceof",
"iterable",
")",
"{",
"val",
"iter",
"=",
"(",
"iterable",
"<",
"?",
">",
")",
"val",
";",
"}",
"else",
"{",
"throw",
"starlark",
"errorf",
"(",
"\"",
"invalid",
"value",
"%",
"s",
"in",
"'",
"label",
"dict",
"'",
":",
"expected",
"iterable",
",",
"but",
"got",
"'",
"%",
"s",
"'",
"\"",
",",
"starlark",
"repr",
"(",
"val",
")",
",",
"starlark",
"type",
"(",
"val",
")",
")",
";",
"}",
"for",
"(",
"object",
"file",
":",
"val",
"iter",
")",
"{",
"if",
"(",
"!",
"(",
"file",
"instanceof",
"artifact",
")",
")",
"{",
"throw",
"starlark",
"errorf",
"(",
"\"",
"invalid",
"value",
"%",
"s",
"in",
"'",
"label",
"dict",
"'",
"\"",
",",
"starlark",
"repr",
"(",
"val",
")",
")",
";",
"}",
"files",
"add",
"(",
"(",
"artifact",
")",
"file",
")",
";",
"}",
"converted",
"map",
"put",
"(",
"(",
"label",
")",
"key",
",",
"files",
"build",
"(",
")",
")",
";",
"}",
"return",
"converted",
"map",
";",
"}"
] |
[
"multiply",
"with",
"a",
"sparse",
"vector"
] |
[
"public",
"dense",
"vector",
"multiplies",
"(",
"sparse",
"vector",
"x",
")",
"{",
"dense",
"vector",
"y",
"=",
"new",
"dense",
"vector",
"(",
"this",
"num",
"rows",
"(",
")",
")",
";",
"for",
"(",
"int",
"i",
"=",
"0",
";",
"i",
"<",
"this",
"num",
"rows",
"(",
")",
";",
"i",
"+",
"+",
")",
"{",
"double",
"s",
"=",
"0",
";",
"int",
"[",
"]",
"indices",
"=",
"x",
"get",
"indices",
"(",
")",
";",
"double",
"[",
"]",
"values",
"=",
"x",
"get",
"values",
"(",
")",
";",
"for",
"(",
"int",
"j",
"=",
"0",
";",
"j",
"<",
"indices",
"length",
";",
"j",
"+",
"+",
")",
"{",
"int",
"index",
"=",
"indices",
"[",
"j",
"]",
";",
"if",
"(",
"index",
">",
"=",
"this",
"num",
"cols",
"(",
")",
")",
"{",
"throw",
"new",
"runtime",
"exception",
"(",
"\"",
"vector",
"index",
"out",
"of",
"bound",
":",
"\"",
"+",
"index",
")",
";",
"}",
"s",
"+",
"=",
"this",
"get",
"(",
"i",
",",
"index",
")",
"*",
"values",
"[",
"j",
"]",
";",
"}",
"y",
"set",
"(",
"i",
",",
"s",
")",
";",
"}",
"return",
"y",
";",
"}"
] |
[
"returns",
"a",
"string",
"formatted",
"as",
"if",
"by",
"the",
"starlark",
"expression",
"{",
"@",
"code",
"pattern",
"%",
"arguments",
"}"
] |
[
"public",
"static",
"string",
"format",
"(",
"string",
"pattern",
",",
"object",
"arguments",
")",
"{",
"printer",
"pr",
"=",
"new",
"printer",
"(",
")",
";",
"printer",
"format",
"(",
"pr",
",",
"pattern",
",",
"arguments",
")",
";",
"return",
"pr",
"to",
"string",
"(",
")",
";",
"}"
] |
[
"cancel",
"vibrate",
"must",
"hold",
"{",
"@",
"code",
"<",
"uses",
"-",
"permission",
"android",
":",
"name",
"=",
"\"",
"android",
"permission",
"vibrate",
"\"",
">",
"}"
] |
[
"public",
"static",
"void",
"cancel",
"(",
")",
"{",
"vibrator",
"vibrator",
"=",
"get",
"vibrator",
"(",
")",
";",
"if",
"(",
"vibrator",
"=",
"=",
"null",
")",
"return",
";",
"vibrator",
"cancel",
"(",
")",
";",
"}"
] |
[
"return",
"a",
"sample",
"stat",
"object",
"that",
"supports",
"calls",
"like",
"std",
"dev",
"and",
"mean"
] |
[
"public",
"sample",
"stat",
"last",
"stat",
"(",
")",
"{",
"return",
"changed",
"(",
")",
"?",
"interval",
"stat",
":",
"prev",
"stat",
";",
"}"
] |
[
"get",
"map",
"array",
"anytype"
] |
[
"public",
"map",
"<",
"string",
",",
"list",
"<",
"object",
">",
">",
"get",
"map",
"array",
"anytype",
"(",
")",
"{",
"return",
"map",
"array",
"anytype",
";",
"}"
] |
[
"tests",
"continuing",
"a",
"write",
"pipeline",
"over",
"a",
"failover",
"when",
"a",
"dn",
"fails",
"after",
"the",
"failover",
"-",
"ensures",
"that",
"updating",
"the",
"pipeline",
"succeeds",
"even",
"when",
"the",
"pipeline",
"was",
"constructed",
"on",
"a",
"different",
"nn"
] |
[
"public",
"void",
"test",
"write",
"over",
"graceful",
"failover",
"with",
"dn",
"fail",
"(",
")",
"throws",
"exception",
"{",
"do",
"test",
"write",
"over",
"failover",
"with",
"dn",
"fail",
"(",
"test",
"scenario",
"graceful",
"failover",
")",
";",
"}"
] |
[
"this",
"waits",
"until",
"completion",
"to",
"ensure",
"the",
"number",
"of",
"executing",
"calls",
"doesn",
"'",
"t",
"surpass",
"the",
"concurrency",
"limit",
"of",
"the",
"executor",
"<",
"h",
"3",
">",
"the",
"{",
"@",
"link",
"listener",
"}",
"isn",
"'",
"t",
"affected",
"during",
"run",
"<",
"h",
"3",
">",
"there",
"could",
"be",
"an",
"error",
"enqueuing",
"the",
"call",
"or",
"an",
"interruption",
"during",
"shutdown",
"of",
"the",
"executor",
"we",
"do",
"not",
"affect",
"the",
"{",
"@",
"link",
"listener",
"}",
"here",
"because",
"it",
"would",
"be",
"redundant",
"to",
"handling",
"already",
"done",
"in",
"callbacks",
"for",
"example",
",",
"if",
"shutting",
"down",
",",
"the",
"storage",
"layer",
"would",
"also",
"invoke",
"{",
"@",
"link",
"#",
"on",
"error",
"(",
"throwable",
")",
"}"
] |
[
"@",
"override",
"public",
"void",
"run",
"(",
")",
"{",
"if",
"(",
"delegate",
"is",
"canceled",
"(",
")",
")",
"return",
";",
"try",
"{",
"delegate",
"enqueue",
"(",
"this",
")",
";",
"/",
"/",
"need",
"to",
"wait",
"here",
"since",
"the",
"callback",
"call",
"will",
"run",
"asynchronously",
"also",
"/",
"/",
"this",
"ensures",
"we",
"don",
"'",
"t",
"exceed",
"our",
"throttle",
"/",
"queue",
"limits",
"await",
"(",
"latch",
")",
";",
"}",
"catch",
"(",
"throwable",
"t",
")",
"{",
"/",
"/",
"edge",
"case",
":",
"error",
"during",
"enqueue",
"!",
"propagate",
"if",
"fatal",
"(",
"t",
")",
";",
"callback",
"on",
"error",
"(",
"t",
")",
";",
"}",
"}"
] |
[
"apply",
"the",
"given",
"{",
"@",
"code",
"cors",
"configuration",
"}",
"to",
"the",
"one",
"being",
"configured",
"via",
"{",
"@",
"link",
"cors",
"configuration",
"#",
"combine",
"(",
"cors",
"configuration",
")",
"}",
"which",
"in",
"turn",
"has",
"been",
"initialized",
"with",
"{",
"@",
"link",
"cors",
"configuration",
"#",
"apply",
"permit",
"default",
"values",
"(",
")",
"}"
] |
[
"public",
"cors",
"registration",
"combine",
"(",
"cors",
"configuration",
"other",
")",
"{",
"this",
"config",
"combine",
"(",
"other",
")",
";",
"return",
"this",
";",
"}"
] |
[
"asynchronous",
"version",
"of",
"{",
"@",
"link",
"abstract",
"dao",
"session",
"#",
"run",
"in",
"tx",
"(",
"runnable",
")",
"}"
] |
[
"public",
"async",
"operation",
"run",
"in",
"tx",
"(",
"runnable",
"runnable",
")",
"{",
"return",
"run",
"in",
"tx",
"(",
"runnable",
",",
"0",
")",
";",
"}"
] |
[
"writes",
"a",
"{",
"@",
"link",
"tuple",
"}",
"data",
"set",
"as",
"csv",
"file",
"(",
"s",
")",
"to",
"the",
"specified",
"location",
"<",
"b",
">",
"note",
":",
"only",
"a",
"tuple",
"data",
"set",
"can",
"written",
"as",
"a",
"csv",
"file",
"<",
"b",
">",
"for",
"each",
"tuple",
"field",
"the",
"result",
"of",
"{",
"@",
"link",
"object",
"#",
"to",
"string",
"(",
")",
"}",
"is",
"written",
"tuple",
"fields",
"are",
"separated",
"by",
"the",
"default",
"field",
"delimiter",
"{",
"@",
"code",
"\"",
"comma",
"\"",
"(",
",",
")",
"}",
"tuples",
"are",
"are",
"separated",
"by",
"the",
"newline",
"character",
"(",
"{",
"@",
"code",
"\\",
"n",
"}",
")"
] |
[
"public",
"data",
"sink",
"<",
"t",
">",
"write",
"as",
"csv",
"(",
"string",
"file",
"path",
")",
"{",
"return",
"write",
"as",
"csv",
"(",
"file",
"path",
",",
"csv",
"output",
"format",
"default",
"line",
"delimiter",
",",
"csv",
"output",
"format",
"default",
"field",
"delimiter",
")",
";",
"}"
] |
[
"get",
"the",
"density",
",",
"the",
"ratio",
"of",
"actual",
"to",
"potential",
"edges",
"between",
"vertices",
"a",
"result",
"of",
"{",
"@",
"code",
"float",
"na",
"n",
"}",
"is",
"returned",
"for",
"a",
"graph",
"with",
"fewer",
"than",
"two",
"vertices",
"for",
"which",
"the",
"number",
"of",
"edges",
"is",
"zero"
] |
[
"public",
"double",
"get",
"density",
"(",
")",
"{",
"return",
"vertex",
"count",
"<",
"=",
"1",
"?",
"double",
"na",
"n",
":",
"edge",
"count",
"/",
"(",
"double",
")",
"(",
"vertex",
"count",
"*",
"(",
"vertex",
"count",
"-",
"1",
")",
"/",
"2",
")",
";",
"}"
] |
[
"get",
"last",
"name"
] |
[
"public",
"string",
"get",
"last",
"name",
"(",
")",
"{",
"return",
"last",
"name",
";",
"}"
] |
[
"fake",
"endpoint",
"for",
"testing",
"various",
"parameters",
"가짜",
"엔드",
"포인트",
"fake",
"endpoint",
"for",
"testing",
"various",
"parameters",
"가짜",
"엔드",
"포인트"
] |
[
"public",
"void",
"test",
"endpoint",
"parameters",
"test",
"(",
"test",
"context",
"test",
"context",
")",
"{",
"async",
"async",
"=",
"test",
"context",
"async",
"(",
")",
";",
"big",
"decimal",
"number",
"=",
"null",
";",
"double",
"double",
"=",
"null",
";",
"string",
"pattern",
"without",
"delimiter",
"=",
"null",
";",
"byte",
"[",
"]",
"byte",
"=",
"null",
";",
"integer",
"integer",
"=",
"null",
";",
"integer",
"int",
"3",
"2",
"=",
"null",
";",
"long",
"int",
"6",
"4",
"=",
"null",
";",
"float",
"float",
"=",
"null",
";",
"string",
"string",
"=",
"null",
";",
"async",
"file",
"binary",
"=",
"null",
";",
"local",
"date",
"date",
"=",
"null",
";",
"offset",
"date",
"time",
"date",
"time",
"=",
"null",
";",
"string",
"password",
"=",
"null",
";",
"string",
"param",
"callback",
"=",
"null",
";",
"api",
"test",
"endpoint",
"parameters",
"(",
"number",
",",
"double",
",",
"pattern",
"without",
"delimiter",
",",
"byte",
",",
"integer",
",",
"int",
"3",
"2",
",",
"int",
"6",
"4",
",",
"float",
",",
"string",
",",
"binary",
",",
"date",
",",
"date",
"time",
",",
"password",
",",
"param",
"callback",
",",
"result",
"-",
">",
"{",
"/",
"/",
"todo",
":",
"test",
"validations",
"async",
"complete",
"(",
")",
";",
"}",
")",
";",
"}"
] |
[
"this",
"method",
"registers",
"3",
"snapshotrestore",
"repositories",
":",
"-",
"repository",
"-",
"fs",
":",
"this",
"fs",
"repository",
"is",
"used",
"to",
"create",
"snapshots",
"-",
"repository",
"-",
"url",
":",
"this",
"url",
"repository",
"is",
"used",
"to",
"restore",
"snapshots",
"created",
"using",
"the",
"previous",
"repository",
"it",
"uses",
"the",
"u",
"r",
"l",
"fixture",
"to",
"restore",
"snapshots",
"over",
"http",
"-",
"repository",
"-",
"file",
":",
"similar",
"as",
"the",
"previous",
"repository",
"but",
"using",
"a",
"file",
":",
"prefix",
"instead",
"of",
"http",
":"
] |
[
"public",
"void",
"register",
"repositories",
"(",
")",
"throws",
"i",
"o",
"exception",
"{",
"request",
"cluster",
"settings",
"request",
"=",
"new",
"request",
"(",
"\"",
"get",
"\"",
",",
"\"",
"/",
"cluster",
"/",
"settings",
"\"",
")",
";",
"cluster",
"settings",
"request",
"add",
"parameter",
"(",
"\"",
"include",
"defaults",
"\"",
",",
"\"",
"true",
"\"",
")",
";",
"cluster",
"settings",
"request",
"add",
"parameter",
"(",
"\"",
"filter",
"path",
"\"",
",",
"\"",
"defaults",
"path",
"repo",
",",
"defaults",
"repositories",
"url",
"allowed",
"urls",
"\"",
")",
";",
"response",
"cluster",
"settings",
"response",
"=",
"client",
"(",
")",
"perform",
"request",
"(",
"cluster",
"settings",
"request",
")",
";",
"map",
"<",
"string",
",",
"object",
">",
"cluster",
"settings",
"=",
"entity",
"as",
"map",
"(",
"cluster",
"settings",
"response",
")",
";",
"@",
"suppress",
"warnings",
"(",
"\"",
"unchecked",
"\"",
")",
"list",
"<",
"string",
">",
"path",
"repos",
"=",
"(",
"list",
"<",
"string",
">",
")",
"x",
"content",
"map",
"values",
"extract",
"value",
"(",
"\"",
"defaults",
"path",
"repo",
"\"",
",",
"cluster",
"settings",
")",
";",
"assert",
"that",
"(",
"path",
"repos",
",",
"not",
"null",
"value",
"(",
")",
")",
";",
"assert",
"that",
"(",
"path",
"repos",
",",
"has",
"size",
"(",
"1",
")",
")",
";",
"final",
"string",
"path",
"repo",
"=",
"path",
"repos",
"get",
"(",
"0",
")",
";",
"final",
"uri",
"path",
"repo",
"uri",
"=",
"path",
"utils",
"get",
"(",
"path",
"repo",
")",
"to",
"uri",
"(",
")",
"normalize",
"(",
")",
";",
"/",
"/",
"create",
"a",
"fs",
"repository",
"using",
"the",
"path",
"repo",
"location",
"request",
"create",
"fs",
"repository",
"request",
"=",
"new",
"request",
"(",
"\"",
"put",
"\"",
",",
"\"",
"/",
"snapshot",
"/",
"repository",
"-",
"fs",
"\"",
")",
";",
"create",
"fs",
"repository",
"request",
"set",
"entity",
"(",
"build",
"repository",
"settings",
"(",
"fs",
"repository",
"type",
",",
"settings",
"builder",
"(",
")",
"put",
"(",
"\"",
"location",
"\"",
",",
"path",
"repo",
")",
"build",
"(",
")",
")",
")",
";",
"response",
"create",
"fs",
"repository",
"response",
"=",
"client",
"(",
")",
"perform",
"request",
"(",
"create",
"fs",
"repository",
"request",
")",
";",
"assert",
"that",
"(",
"create",
"fs",
"repository",
"response",
"get",
"status",
"line",
"(",
")",
"get",
"status",
"code",
"(",
")",
",",
"equal",
"to",
"(",
"rest",
"status",
"ok",
"get",
"status",
"(",
")",
")",
")",
";",
"/",
"/",
"create",
"a",
"url",
"repository",
"using",
"the",
"file",
":",
"/",
"/",
"{",
"path",
"repo",
"}",
"url",
"request",
"create",
"file",
"repository",
"request",
"=",
"new",
"request",
"(",
"\"",
"put",
"\"",
",",
"\"",
"/",
"snapshot",
"/",
"repository",
"-",
"file",
"\"",
")",
";",
"create",
"file",
"repository",
"request",
"set",
"entity",
"(",
"build",
"repository",
"settings",
"(",
"\"",
"url",
"\"",
",",
"settings",
"builder",
"(",
")",
"put",
"(",
"\"",
"url",
"\"",
",",
"path",
"repo",
"uri",
"to",
"string",
"(",
")",
")",
"build",
"(",
")",
")",
")",
";",
"response",
"create",
"file",
"repository",
"response",
"=",
"client",
"(",
")",
"perform",
"request",
"(",
"create",
"file",
"repository",
"request",
")",
";",
"assert",
"that",
"(",
"create",
"file",
"repository",
"response",
"get",
"status",
"line",
"(",
")",
"get",
"status",
"code",
"(",
")",
",",
"equal",
"to",
"(",
"rest",
"status",
"ok",
"get",
"status",
"(",
")",
")",
")",
";",
"/",
"/",
"create",
"a",
"url",
"repository",
"using",
"the",
"http",
":",
"/",
"/",
"{",
"fixture",
"}",
"url",
"@",
"suppress",
"warnings",
"(",
"\"",
"unchecked",
"\"",
")",
"list",
"<",
"string",
">",
"allowed",
"urls",
"=",
"(",
"list",
"<",
"string",
">",
")",
"x",
"content",
"map",
"values",
"extract",
"value",
"(",
"\"",
"defaults",
"repositories",
"url",
"allowed",
"urls",
"\"",
",",
"cluster",
"settings",
")",
";",
"for",
"(",
"string",
"allowed",
"url",
":",
"allowed",
"urls",
")",
"{",
"try",
"{",
"inet",
"address",
"inet",
"address",
"=",
"inet",
"address",
"get",
"by",
"name",
"(",
"new",
"url",
"(",
"allowed",
"url",
")",
"get",
"host",
"(",
")",
")",
";",
"if",
"(",
"inet",
"address",
"is",
"any",
"local",
"address",
"(",
")",
"|",
"|",
"inet",
"address",
"is",
"loopback",
"address",
"(",
")",
")",
"{",
"request",
"create",
"url",
"repository",
"request",
"=",
"new",
"request",
"(",
"\"",
"put",
"\"",
",",
"\"",
"/",
"snapshot",
"/",
"repository",
"-",
"url",
"\"",
")",
";",
"create",
"url",
"repository",
"request",
"set",
"entity",
"(",
"build",
"repository",
"settings",
"(",
"\"",
"url",
"\"",
",",
"settings",
"builder",
"(",
")",
"put",
"(",
"\"",
"url",
"\"",
",",
"allowed",
"url",
")",
"build",
"(",
")",
")",
")",
";",
"response",
"create",
"url",
"repository",
"response",
"=",
"client",
"(",
")",
"perform",
"request",
"(",
"create",
"url",
"repository",
"request",
")",
";",
"assert",
"that",
"(",
"create",
"url",
"repository",
"response",
"get",
"status",
"line",
"(",
")",
"get",
"status",
"code",
"(",
")",
",",
"equal",
"to",
"(",
"rest",
"status",
"ok",
"get",
"status",
"(",
")",
")",
")",
";",
"break",
";",
"}",
"}",
"catch",
"(",
"exception",
"e",
")",
"{",
"logger",
"debug",
"(",
"\"",
"failed",
"to",
"resolve",
"inet",
"address",
"for",
"allowed",
"url",
"[",
"{",
"}",
"]",
",",
"skipping",
"\"",
",",
"allowed",
"url",
")",
";",
"}",
"}",
"}"
] |
[
"schedules",
"a",
"new",
"build",
"command"
] |
[
"default",
"void",
"do",
"build",
"(",
"stapler",
"request",
"req",
",",
"stapler",
"response",
"rsp",
",",
"@",
"query",
"parameter",
"time",
"duration",
"delay",
")",
"throws",
"i",
"o",
"exception",
",",
"servlet",
"exception",
"{",
"get",
"parameterized",
"job",
"mix",
"in",
"(",
")",
"do",
"build",
"(",
"req",
",",
"rsp",
",",
"delay",
")",
";",
"}"
] |
[
"test",
"trash",
"for",
"the",
"shell",
"'",
"s",
"delete",
"command",
"for",
"the",
"file",
"system",
"fs"
] |
[
"public",
"static",
"void",
"trash",
"shell",
"(",
"final",
"file",
"system",
"fs",
",",
"final",
"path",
"base",
")",
"throws",
"exception",
"{",
"configuration",
"conf",
"=",
"new",
"configuration",
"(",
")",
";",
"conf",
"set",
"(",
"\"",
"fs",
"default",
"f",
"s",
"\"",
",",
"fs",
"get",
"uri",
"(",
")",
"to",
"string",
"(",
")",
")",
";",
"trash",
"shell",
"(",
"conf",
",",
"base",
",",
"null",
",",
"null",
")",
";",
"}"
] |
[
"returns",
"the",
"name",
"of",
"the",
"symbol"
] |
[
"public",
"string",
"get",
"name",
"(",
")",
"{",
"return",
"name",
";",
"}"
] |
[
"set",
"max",
"total",
"qps",
"in",
"a",
"high",
"concurrency",
"condition",
",",
"real",
"passed",
"qps",
"may",
"be",
"greater",
"than",
"max",
"qps",
"set",
"the",
"real",
"passed",
"qps",
"will",
"nearly",
"satisfy",
"the",
"following",
"formula",
":",
"<",
"br",
">",
"real",
"passed",
"qps",
"=",
"qps",
"set",
"+",
"concurrent",
"thread",
"number"
] |
[
"public",
"void",
"set",
"qps",
"(",
"double",
"qps",
")",
"{",
"this",
"qps",
"=",
"qps",
";",
"}"
] |
[
"updates",
"the",
"java",
"project",
"'",
"s",
"classpath",
"to",
"include",
"the",
"given",
"list",
"of",
"classpath",
"entries"
] |
[
"public",
"static",
"void",
"add",
"to",
"classpath",
"(",
"i",
"java",
"project",
"java",
"project",
",",
"list",
"<",
"i",
"classpath",
"entry",
">",
"classpath",
"entries",
",",
"i",
"progress",
"monitor",
"monitor",
")",
"throws",
"java",
"model",
"exception",
"{",
"for",
"(",
"i",
"classpath",
"entry",
"entry",
":",
"java",
"project",
"get",
"raw",
"classpath",
"(",
")",
")",
"{",
"classpath",
"entries",
"add",
"(",
"entry",
")",
";",
"}",
"java",
"project",
"set",
"raw",
"classpath",
"(",
"classpath",
"entries",
"to",
"array",
"(",
"new",
"i",
"classpath",
"entry",
"[",
"classpath",
"entries",
"size",
"(",
")",
"]",
")",
",",
"monitor",
")",
";",
"}"
] |
[
"generates",
"the",
"token"
] |
[
"private",
"void",
"generate",
"token",
"(",
")",
"{",
"string",
"builder",
"sb",
"=",
"new",
"string",
"builder",
"(",
")",
";",
"sb",
"append",
"(",
"user",
"name",
")",
"append",
"(",
"\"",
"=",
"\"",
")",
"append",
"(",
"get",
"user",
"name",
"(",
")",
")",
"append",
"(",
"attr",
"separator",
")",
";",
"sb",
"append",
"(",
"principal",
")",
"append",
"(",
"\"",
"=",
"\"",
")",
"append",
"(",
"get",
"name",
"(",
")",
")",
"append",
"(",
"attr",
"separator",
")",
";",
"sb",
"append",
"(",
"type",
")",
"append",
"(",
"\"",
"=",
"\"",
")",
"append",
"(",
"get",
"type",
"(",
")",
")",
"append",
"(",
"attr",
"separator",
")",
";",
"if",
"(",
"get",
"max",
"inactives",
"(",
")",
"!",
"=",
"-",
"1",
")",
"{",
"sb",
"append",
"(",
"max",
"inactives",
")",
"append",
"(",
"\"",
"=",
"\"",
")",
"append",
"(",
"get",
"max",
"inactives",
"(",
")",
")",
"append",
"(",
"attr",
"separator",
")",
";",
"}",
"sb",
"append",
"(",
"expires",
")",
"append",
"(",
"\"",
"=",
"\"",
")",
"append",
"(",
"get",
"expires",
"(",
")",
")",
";",
"token",
"str",
"=",
"sb",
"to",
"string",
"(",
")",
";",
"}"
] |
[
"tests",
"that",
"updating",
"the",
"{",
"@",
"link",
"same",
"shard",
"allocation",
"decider",
"#",
"cluster",
"routing",
"allocation",
"same",
"host",
"setting",
"}",
"setting",
"works",
"as",
"expected"
] |
[
"public",
"void",
"test",
"update",
"same",
"host",
"setting",
"(",
")",
"{",
"internal",
"cluster",
"(",
")",
"start",
"nodes",
"(",
"2",
")",
";",
"/",
"/",
"same",
"same",
"host",
"to",
"true",
",",
"since",
"2",
"nodes",
"are",
"started",
"on",
"the",
"same",
"host",
",",
"/",
"/",
"only",
"primaries",
"should",
"be",
"assigned",
"client",
"(",
")",
"admin",
"(",
")",
"cluster",
"(",
")",
"prepare",
"update",
"settings",
"(",
")",
"set",
"transient",
"settings",
"(",
"settings",
"builder",
"(",
")",
"put",
"(",
"cluster",
"routing",
"allocation",
"same",
"host",
"setting",
"get",
"key",
"(",
")",
",",
"true",
")",
")",
"get",
"(",
")",
";",
"final",
"string",
"index",
"name",
"=",
"\"",
"idx",
"\"",
";",
"client",
"(",
")",
"admin",
"(",
")",
"indices",
"(",
")",
"prepare",
"create",
"(",
"index",
"name",
")",
"set",
"settings",
"(",
"settings",
"builder",
"(",
")",
"put",
"(",
"index",
"metadata",
"setting",
"number",
"of",
"shards",
",",
"1",
")",
"put",
"(",
"index",
"metadata",
"setting",
"number",
"of",
"replicas",
",",
"1",
")",
")",
"get",
"(",
")",
";",
"cluster",
"state",
"cluster",
"state",
"=",
"client",
"(",
")",
"admin",
"(",
")",
"cluster",
"(",
")",
"prepare",
"state",
"(",
")",
"get",
"(",
")",
"get",
"state",
"(",
")",
";",
"assert",
"false",
"(",
"\"",
"replica",
"should",
"be",
"unassigned",
"\"",
",",
"cluster",
"state",
"get",
"routing",
"table",
"(",
")",
"index",
"(",
"index",
"name",
")",
"shards",
"with",
"state",
"(",
"shard",
"routing",
"state",
"unassigned",
")",
"is",
"empty",
"(",
")",
")",
";",
"/",
"/",
"now",
",",
"update",
"the",
"same",
"host",
"setting",
"to",
"allow",
"shards",
"to",
"be",
"allocated",
"to",
"multiple",
"nodes",
"on",
"/",
"/",
"the",
"same",
"host",
"-",
"the",
"replica",
"should",
"get",
"assigned",
"client",
"(",
")",
"admin",
"(",
")",
"cluster",
"(",
")",
"prepare",
"update",
"settings",
"(",
")",
"set",
"transient",
"settings",
"(",
"settings",
"builder",
"(",
")",
"put",
"(",
"cluster",
"routing",
"allocation",
"same",
"host",
"setting",
"get",
"key",
"(",
")",
",",
"false",
")",
")",
"get",
"(",
")",
";",
"cluster",
"state",
"=",
"client",
"(",
")",
"admin",
"(",
")",
"cluster",
"(",
")",
"prepare",
"state",
"(",
")",
"get",
"(",
")",
"get",
"state",
"(",
")",
";",
"assert",
"true",
"(",
"\"",
"all",
"shards",
"should",
"be",
"assigned",
"\"",
",",
"cluster",
"state",
"get",
"routing",
"table",
"(",
")",
"index",
"(",
"index",
"name",
")",
"shards",
"with",
"state",
"(",
"shard",
"routing",
"state",
"unassigned",
")",
"is",
"empty",
"(",
")",
")",
";",
"}"
] |
[
"merges",
"the",
"bookmarks",
"from",
"the",
"origin",
"program",
"into",
"the",
"result",
"program",
"at",
"an",
"address",
"equivalent",
"to",
"the",
"origin",
"address",
"merging",
"means",
"replace",
"any",
"existing",
"bookmarks",
"in",
"the",
"merge",
"program",
"at",
"the",
"address",
"with",
"the",
"bookmarks",
"found",
"in",
"the",
"listing",
"at",
"that",
"address"
] |
[
"private",
"void",
"merge",
"bookmarks",
"at",
"address",
"(",
"address",
"origin",
"address",
")",
"{",
"if",
"(",
"origin",
"address",
"!",
"=",
"null",
")",
"{",
"address",
"result",
"address",
"=",
"origin",
"to",
"result",
"translator",
"get",
"address",
"(",
"origin",
"address",
")",
";",
"bookmark",
"manager",
"bm",
"1",
"=",
"result",
"program",
"get",
"bookmark",
"manager",
"(",
")",
";",
"bookmark",
"manager",
"bm",
"2",
"=",
"origin",
"program",
"get",
"bookmark",
"manager",
"(",
")",
";",
"try",
"{",
"bm",
"1",
"remove",
"bookmarks",
"(",
"new",
"address",
"set",
"(",
"result",
"address",
",",
"result",
"address",
")",
",",
"task",
"monitor",
"adapter",
"dummy",
"monitor",
")",
";",
"}",
"catch",
"(",
"cancelled",
"exception",
"e",
")",
"{",
"/",
"/",
"dummy",
"adapter",
"doesn",
"'",
"t",
"let",
"cancel",
"occur",
"}",
"bookmark",
"[",
"]",
"marks",
"=",
"bm",
"2",
"get",
"bookmarks",
"(",
"origin",
"address",
")",
";",
"for",
"(",
"bookmark",
"mark",
":",
"marks",
")",
"{",
"bm",
"1",
"set",
"bookmark",
"(",
"result",
"address",
",",
"mark",
"get",
"type",
"string",
"(",
")",
",",
"mark",
"get",
"category",
"(",
")",
",",
"mark",
"get",
"comment",
"(",
")",
")",
";",
"}",
"}",
"}"
] |
[
"return",
"the",
"stored",
"element",
"which",
"is",
"equal",
"to",
"the",
"given",
"key",
"this",
"operation",
"is",
"similar",
"to",
"{",
"@",
"link",
"java",
"util",
"map",
"#",
"get",
"(",
"object",
")",
"}"
] |
[
"e",
"get",
"(",
"k",
"key",
")",
";"
] |
[
"returns",
"the",
"configuration",
"corresponding",
"to",
"the",
"given",
"set",
"of",
"build",
"options",
"should",
"not",
"be",
"used",
"in",
"a",
"world",
"with",
"trimmed",
"configurations"
] |
[
"public",
"build",
"configuration",
"get",
"configuration",
"(",
"extended",
"event",
"handler",
"event",
"handler",
",",
"build",
"options",
"options",
",",
"boolean",
"keep",
"going",
")",
"throws",
"invalid",
"configuration",
"exception",
"{",
"return",
"iterables",
"get",
"only",
"element",
"(",
"get",
"configurations",
"(",
"event",
"handler",
",",
"immutable",
"list",
"of",
"(",
"options",
")",
",",
"options",
",",
"keep",
"going",
")",
")",
";",
"}"
] |
[
"produce",
"a",
"{",
"@",
"code",
"value",
"array",
"}",
"for",
"the",
"given",
"{",
"@",
"code",
"value",
"}",
"type",
"with",
"the",
"given",
"bounded",
"size"
] |
[
"public",
"static",
"<",
"t",
">",
"value",
"array",
"<",
"t",
">",
"create",
"value",
"array",
"(",
"class",
"<",
"?",
"extends",
"value",
">",
"cls",
",",
"int",
"bytes",
")",
"{",
"if",
"(",
"byte",
"value",
"class",
"is",
"assignable",
"from",
"(",
"cls",
")",
")",
"{",
"return",
"(",
"value",
"array",
"<",
"t",
">",
")",
"new",
"byte",
"value",
"array",
"(",
"bytes",
")",
";",
"}",
"else",
"if",
"(",
"char",
"value",
"class",
"is",
"assignable",
"from",
"(",
"cls",
")",
")",
"{",
"return",
"(",
"value",
"array",
"<",
"t",
">",
")",
"new",
"char",
"value",
"array",
"(",
"bytes",
")",
";",
"}",
"else",
"if",
"(",
"double",
"value",
"class",
"is",
"assignable",
"from",
"(",
"cls",
")",
")",
"{",
"return",
"(",
"value",
"array",
"<",
"t",
">",
")",
"new",
"double",
"value",
"array",
"(",
"bytes",
")",
";",
"}",
"else",
"if",
"(",
"float",
"value",
"class",
"is",
"assignable",
"from",
"(",
"cls",
")",
")",
"{",
"return",
"(",
"value",
"array",
"<",
"t",
">",
")",
"new",
"float",
"value",
"array",
"(",
"bytes",
")",
";",
"}",
"else",
"if",
"(",
"int",
"value",
"class",
"is",
"assignable",
"from",
"(",
"cls",
")",
")",
"{",
"return",
"(",
"value",
"array",
"<",
"t",
">",
")",
"new",
"int",
"value",
"array",
"(",
"bytes",
")",
";",
"}",
"else",
"if",
"(",
"long",
"value",
"class",
"is",
"assignable",
"from",
"(",
"cls",
")",
")",
"{",
"return",
"(",
"value",
"array",
"<",
"t",
">",
")",
"new",
"long",
"value",
"array",
"(",
"bytes",
")",
";",
"}",
"else",
"if",
"(",
"null",
"value",
"class",
"is",
"assignable",
"from",
"(",
"cls",
")",
")",
"{",
"return",
"(",
"value",
"array",
"<",
"t",
">",
")",
"new",
"null",
"value",
"array",
"(",
"bytes",
")",
";",
"}",
"else",
"if",
"(",
"short",
"value",
"class",
"is",
"assignable",
"from",
"(",
"cls",
")",
")",
"{",
"return",
"(",
"value",
"array",
"<",
"t",
">",
")",
"new",
"short",
"value",
"array",
"(",
"bytes",
")",
";",
"}",
"else",
"if",
"(",
"string",
"value",
"class",
"is",
"assignable",
"from",
"(",
"cls",
")",
")",
"{",
"return",
"(",
"value",
"array",
"<",
"t",
">",
")",
"new",
"string",
"value",
"array",
"(",
"bytes",
")",
";",
"}",
"else",
"{",
"throw",
"new",
"illegal",
"argument",
"exception",
"(",
"\"",
"unable",
"to",
"create",
"bounded",
"value",
"array",
"for",
"type",
"\"",
"+",
"cls",
")",
";",
"}",
"}"
] |
[
"declares",
"that",
"the",
"implementation",
"of",
"the",
"associated",
"rule",
"class",
"requires",
"the",
"given",
"fragments",
"to",
"be",
"present",
"in",
"the",
"specified",
"configuration",
"valid",
"transition",
"values",
"are",
"host",
"for",
"the",
"host",
"configuration",
"and",
"none",
"for",
"the",
"target",
"configuration",
"the",
"value",
"is",
"inherited",
"by",
"subclasses"
] |
[
"public",
"builder",
"requires",
"configuration",
"fragments",
"(",
"configuration",
"transition",
"transition",
",",
"collection",
"<",
"class",
"<",
"?",
">",
">",
"configuration",
"fragments",
")",
"{",
"/",
"/",
"we",
"can",
"relax",
"this",
"assumption",
"if",
"needed",
"but",
"it",
"'",
"s",
"already",
"sketchy",
"to",
"let",
"a",
"rule",
"see",
"more",
"/",
"/",
"than",
"its",
"own",
"configuration",
"so",
"we",
"don",
"'",
"t",
"want",
"to",
"casually",
"proliferate",
"this",
"pattern",
"preconditions",
"check",
"argument",
"(",
"transition",
"=",
"=",
"no",
"transition",
"instance",
"|",
"|",
"transition",
"is",
"host",
"transition",
"(",
")",
")",
";",
"required",
"configuration",
"fragments",
"put",
"all",
"(",
"transition",
",",
"configuration",
"fragments",
")",
";",
"return",
"this",
";",
"}"
] |
[
"dumps",
"memory",
"section",
"refinement",
"to",
"log"
] |
[
"private",
"void",
"log",
"memory",
"section",
"refinement",
"(",
")",
"throws",
"cancelled",
"exception",
"{",
"/",
"/",
"offer",
"memory",
"refinement",
"(",
"could",
"have",
"done",
"it",
"as",
"symbols",
"came",
"in",
";",
"we",
"just",
"collected",
"/",
"/",
"them",
"and",
"are",
"dealing",
"with",
"them",
"now",
"ultimately",
"not",
"sure",
"if",
"we",
"will",
"want",
"to",
"use",
"/",
"/",
"this",
"refinement",
"/",
"/",
"look",
"at",
"section",
"flags",
"java",
"for",
"characteristics",
"information",
"/",
"/",
"todo",
":",
"should",
"we",
"perform",
"refinement",
"of",
"program",
"memory",
"blocks",
"?",
"pdb",
"log",
"message",
"(",
"\"",
"\\",
"n",
"memory",
"section",
"refinement",
"\"",
")",
";",
"for",
"(",
"pe",
"coff",
"section",
"ms",
"symbol",
"sym",
":",
"memory",
"section",
"refinement",
")",
"{",
"applicator",
"check",
"canceled",
"(",
")",
";",
"string",
"name",
"=",
"sym",
"get",
"name",
"(",
")",
";",
"int",
"section",
"=",
"sym",
"get",
"section",
"number",
"(",
")",
";",
"int",
"relative",
"virtual",
"address",
"=",
"sym",
"get",
"rva",
"(",
")",
";",
"int",
"align",
"=",
"sym",
"get",
"align",
"(",
")",
";",
"int",
"length",
"=",
"sym",
"get",
"length",
"(",
")",
";",
"int",
"characteristics",
"=",
"sym",
"get",
"characteristics",
"(",
")",
";",
"address",
"address",
"=",
"image",
"base",
"add",
"(",
"relative",
"virtual",
"address",
")",
";",
"pdb",
"log",
"message",
"(",
"string",
"format",
"(",
"\"",
"%",
"s",
":",
"[",
"%",
"04x",
"(",
"%",
"08x",
")",
"]",
"(",
"%",
"s",
")",
"align",
":",
"%",
"02x",
",",
"len",
":",
"%",
"08x",
",",
"characteristics",
":",
"%",
"08x",
"\"",
",",
"name",
",",
"section",
",",
"relative",
"virtual",
"address",
",",
"address",
"to",
"string",
"(",
")",
",",
"align",
",",
"length",
",",
"characteristics",
")",
")",
";",
"}",
"}"
] |
[
"gets",
"the",
"partition",
"number",
"of",
"this",
"partition"
] |
[
"public",
"int",
"get",
"partition",
"number",
"(",
")",
"{",
"return",
"this",
"partition",
"number",
";",
"}"
] |
[
"delegates",
"to",
"{",
"@",
"link",
"collection",
"#",
"remove",
"}",
"returns",
"{",
"@",
"code",
"false",
"}",
"if",
"the",
"{",
"@",
"code",
"remove",
"}",
"method",
"throws",
"a",
"{",
"@",
"code",
"class",
"cast",
"exception",
"}",
"or",
"{",
"@",
"code",
"null",
"pointer",
"exception",
"}"
] |
[
"static",
"boolean",
"safe",
"remove",
"(",
"collection",
"<",
"?",
">",
"collection",
",",
"@",
"nullable",
"object",
"object",
")",
"{",
"check",
"not",
"null",
"(",
"collection",
")",
";",
"try",
"{",
"return",
"collection",
"remove",
"(",
"object",
")",
";",
"}",
"catch",
"(",
"class",
"cast",
"exception",
"|",
"null",
"pointer",
"exception",
"e",
")",
"{",
"return",
"false",
";",
"}",
"}"
] |
[
"a",
"{",
"@",
"link",
"cache",
"loader",
"}",
"for",
"a",
"cache",
"of",
"readdir",
"calls",
"input",
":",
"path",
"output",
":",
"either",
"dirents",
"or",
"i",
"o",
"exception"
] |
[
"private",
"static",
"cache",
"loader",
"<",
"path",
",",
"object",
">",
"new",
"readdir",
"loader",
"(",
")",
"{",
"return",
"new",
"cache",
"loader",
"<",
"path",
",",
"object",
">",
"(",
")",
"{",
"@",
"override",
"public",
"object",
"load",
"(",
"path",
"p",
")",
"{",
"try",
"{",
"/",
"/",
"todo",
"(",
"bazel",
"-",
"team",
")",
":",
"consider",
"storing",
"the",
"collection",
"of",
"dirent",
"values",
"more",
"compactly",
"/",
"/",
"by",
"reusing",
"directory",
"entry",
"listing",
"state",
"value",
"#",
"compact",
"sorted",
"dirents",
"return",
"p",
"readdir",
"(",
"symlinks",
"nofollow",
")",
";",
"}",
"catch",
"(",
"i",
"o",
"exception",
"e",
")",
"{",
"return",
"e",
";",
"}",
"}",
"}",
";",
"}"
] |
[
"get",
"volume",
"report"
] |
[
"public",
"string",
"get",
"datanode",
"volume",
"report",
"(",
")",
"{",
"string",
"builder",
"report",
"=",
"new",
"string",
"builder",
"(",
")",
";",
"report",
"append",
"(",
"\"",
"directory",
":",
"\"",
"+",
"path",
")",
"append",
"(",
"\"",
"\\",
"n",
"storage",
"type",
":",
"\"",
"+",
"storage",
"type",
")",
"append",
"(",
"\"",
"\\",
"n",
"capacity",
"used",
":",
"\"",
"+",
"used",
"space",
"+",
"\"",
"(",
"\"",
"+",
"string",
"utils",
"byte",
"desc",
"(",
"used",
"space",
")",
"+",
"\"",
")",
"\"",
")",
"append",
"(",
"\"",
"\\",
"n",
"capacity",
"left",
":",
"\"",
"+",
"free",
"space",
"+",
"\"",
"(",
"\"",
"+",
"string",
"utils",
"byte",
"desc",
"(",
"free",
"space",
")",
"+",
"\"",
")",
"\"",
")",
"append",
"(",
"\"",
"\\",
"n",
"capacity",
"reserved",
":",
"\"",
"+",
"reserved",
"space",
"+",
"\"",
"(",
"\"",
"+",
"string",
"utils",
"byte",
"desc",
"(",
"reserved",
"space",
")",
"+",
"\"",
")",
"\"",
")",
"append",
"(",
"\"",
"\\",
"n",
"reserved",
"space",
"for",
"replicas",
":",
"\"",
"+",
"reserved",
"space",
"for",
"replicas",
"+",
"\"",
"(",
"\"",
"+",
"string",
"utils",
"byte",
"desc",
"(",
"reserved",
"space",
"for",
"replicas",
")",
"+",
"\"",
")",
"\"",
")",
"append",
"(",
"\"",
"\\",
"n",
"blocks",
":",
"\"",
"+",
"num",
"blocks",
")",
";",
"return",
"report",
"to",
"string",
"(",
")",
";",
"}"
] |
[
"returns",
"the",
"weight",
"of",
"a",
"server"
] |
[
"public",
"long",
"get",
"weight",
"(",
"long",
"id",
")",
"{",
"return",
"server",
"weight",
"get",
"(",
"id",
")",
";",
"}"
] |
[
"confirm",
"that",
"running",
"on",
"a",
"thread",
"pool",
"scheduler",
"allows",
"multiple",
"threads",
"but",
"is",
"still",
"ordered"
] |
[
"public",
"void",
"observe",
"on",
"with",
"thread",
"pool",
"scheduler",
"(",
")",
"{",
"final",
"atomic",
"integer",
"count",
"=",
"new",
"atomic",
"integer",
"(",
")",
";",
"final",
"int",
"multiple",
"=",
"99",
";",
"observable",
"range",
"(",
"1",
",",
"100000",
")",
"map",
"(",
"new",
"function",
"<",
"integer",
",",
"integer",
">",
"(",
")",
"{",
"@",
"override",
"public",
"integer",
"apply",
"(",
"integer",
"t",
"1",
")",
"{",
"return",
"t",
"1",
"*",
"multiple",
";",
"}",
"}",
")",
"observe",
"on",
"(",
"schedulers",
"computation",
"(",
")",
")",
"blocking",
"for",
"each",
"(",
"new",
"consumer",
"<",
"integer",
">",
"(",
")",
"{",
"@",
"override",
"public",
"void",
"accept",
"(",
"integer",
"t",
"1",
")",
"{",
"assert",
"equals",
"(",
"count",
"increment",
"and",
"get",
"(",
")",
"*",
"multiple",
",",
"t",
"1",
"int",
"value",
"(",
")",
")",
";",
"/",
"/",
"fixme",
"to",
"blocking",
"methods",
"run",
"on",
"the",
"caller",
"'",
"s",
"thread",
"string",
"name",
"=",
"thread",
"current",
"thread",
"(",
")",
"get",
"name",
"(",
")",
";",
"assert",
"false",
"(",
"\"",
"wrong",
"thread",
"name",
":",
"\"",
"+",
"name",
",",
"name",
"starts",
"with",
"(",
"\"",
"rx",
"\"",
")",
")",
";",
"}",
"}",
")",
";",
"}"
] |
[
"set",
"the",
"location",
"of",
"the",
"free",
"marker",
"config",
"file",
"alternatively",
",",
"you",
"can",
"specify",
"all",
"setting",
"locally"
] |
[
"public",
"void",
"set",
"config",
"location",
"(",
"resource",
"resource",
")",
"{",
"this",
"config",
"location",
"=",
"resource",
";",
"}"
] |
[
"find",
"the",
"corresponding",
"meta",
"data",
"file",
"from",
"a",
"given",
"block",
"file"
] |
[
"public",
"static",
"file",
"find",
"meta",
"file",
"(",
"final",
"file",
"block",
"file",
")",
"throws",
"i",
"o",
"exception",
"{",
"final",
"string",
"prefix",
"=",
"block",
"file",
"get",
"name",
"(",
")",
"+",
"\"",
"\"",
";",
"final",
"file",
"parent",
"=",
"block",
"file",
"get",
"parent",
"file",
"(",
")",
";",
"final",
"file",
"[",
"]",
"matches",
"=",
"parent",
"list",
"files",
"(",
"new",
"filename",
"filter",
"(",
")",
"{",
"@",
"override",
"public",
"boolean",
"accept",
"(",
"file",
"dir",
",",
"string",
"name",
")",
"{",
"return",
"dir",
"equals",
"(",
"parent",
")",
"&",
"&",
"name",
"starts",
"with",
"(",
"prefix",
")",
"&",
"&",
"name",
"ends",
"with",
"(",
"block",
"metadata",
"extension",
")",
";",
"}",
"}",
")",
";",
"if",
"(",
"matches",
"=",
"=",
"null",
"|",
"|",
"matches",
"length",
"=",
"=",
"0",
")",
"{",
"throw",
"new",
"i",
"o",
"exception",
"(",
"\"",
"meta",
"file",
"not",
"found",
",",
"block",
"file",
"=",
"\"",
"+",
"block",
"file",
")",
";",
"}",
"if",
"(",
"matches",
"length",
">",
"1",
")",
"{",
"throw",
"new",
"i",
"o",
"exception",
"(",
"\"",
"found",
"more",
"than",
"one",
"meta",
"files",
":",
"\"",
"+",
"arrays",
"as",
"list",
"(",
"matches",
")",
")",
";",
"}",
"return",
"matches",
"[",
"0",
"]",
";",
"}"
] |
[
"use",
"this",
"property",
"to",
"enable",
"relative",
"redirects",
"as",
"explained",
"in",
"{",
"@",
"link",
"relative",
"redirect",
"filter",
"}",
",",
"and",
"also",
"using",
"the",
"same",
"response",
"wrapper",
"as",
"that",
"filter",
"does",
",",
"or",
"if",
"both",
"are",
"configured",
",",
"only",
"one",
"will",
"wrap",
"by",
"default",
",",
"if",
"this",
"property",
"is",
"set",
"to",
"false",
",",
"in",
"which",
"case",
"calls",
"to",
"{",
"@",
"link",
"http",
"servlet",
"response",
"#",
"send",
"redirect",
"(",
"string",
")",
"}",
"are",
"overridden",
"in",
"order",
"to",
"turn",
"relative",
"into",
"absolute",
"u",
"r",
"ls",
",",
"also",
"taking",
"into",
"account",
"forwarded",
"headers"
] |
[
"public",
"void",
"set",
"relative",
"redirects",
"(",
"boolean",
"relative",
"redirects",
")",
"{",
"this",
"relative",
"redirects",
"=",
"relative",
"redirects",
";",
"}"
] |
[
"wait",
"until",
"all",
"the",
"journalnodes",
"start"
] |
[
"public",
"void",
"wait",
"active",
"(",
")",
"throws",
"i",
"o",
"exception",
"{",
"for",
"(",
"int",
"i",
"=",
"0",
";",
"i",
"<",
"nodes",
"length",
";",
"i",
"+",
"+",
")",
"{",
"final",
"int",
"index",
"=",
"i",
";",
"try",
"{",
"generic",
"test",
"utils",
"wait",
"for",
"(",
"new",
"supplier",
"<",
"boolean",
">",
"(",
")",
"{",
"/",
"/",
"wait",
"until",
"all",
"jn",
"'",
"s",
"ipc",
"server",
"is",
"running",
"@",
"override",
"public",
"boolean",
"get",
"(",
")",
"{",
"try",
"{",
"quorum",
"journal",
"manager",
"qjm",
"=",
"new",
"quorum",
"journal",
"manager",
"(",
"nodes",
"[",
"index",
"]",
"node",
"get",
"conf",
"(",
")",
",",
"get",
"quorum",
"journal",
"u",
"r",
"i",
"(",
"cluster",
"waitactive",
"uri",
")",
",",
"fake",
"nsinfo",
")",
";",
"qjm",
"has",
"some",
"data",
"(",
")",
";",
"qjm",
"close",
"(",
")",
";",
"}",
"catch",
"(",
"i",
"o",
"exception",
"e",
")",
"{",
"/",
"/",
"exception",
"from",
"ipc",
"call",
",",
"likely",
"due",
"to",
"server",
"not",
"ready",
"yet",
"return",
"false",
";",
"}",
"return",
"true",
";",
"}",
"}",
",",
"50",
",",
"3000",
")",
";",
"}",
"catch",
"(",
"timeout",
"exception",
"e",
")",
"{",
"fail",
"(",
"\"",
"time",
"out",
"while",
"waiting",
"for",
"journal",
"node",
"\"",
"+",
"index",
"+",
"\"",
"to",
"start",
"\"",
")",
";",
"}",
"catch",
"(",
"interrupted",
"exception",
"ite",
")",
"{",
"log",
"warn",
"(",
"\"",
"thread",
"interrupted",
"when",
"waiting",
"for",
"node",
"start",
"\"",
",",
"ite",
")",
";",
"}",
"}",
"}"
] |
[
"build",
"an",
"expression",
"string",
"used",
"for",
"partition",
"filtering",
"in",
"{",
"@",
"link",
"get",
"partitions",
"request",
"}",
"ex",
":",
"partition",
"keys",
":",
"[",
"'",
"a",
"'",
",",
"'",
"b",
"'",
"]",
"partition",
"values",
":",
"[",
"'",
"1",
"'",
",",
"'",
"2",
"'",
"]",
"expression",
":",
"(",
"a",
"=",
"'",
"1",
"'",
")",
"and",
"(",
"b",
"=",
"'",
"2",
"'",
")",
"partial",
"specification",
"ex",
":",
"partition",
"values",
":",
"[",
"'",
"'",
",",
"'",
"2",
"'",
"]",
"expression",
":",
"(",
"b",
"=",
"'",
"2",
"'",
")"
] |
[
"public",
"static",
"string",
"build",
"glue",
"expression",
"(",
"list",
"<",
"column",
">",
"partition",
"keys",
",",
"list",
"<",
"string",
">",
"partition",
"values",
")",
"{",
"if",
"(",
"partition",
"values",
"=",
"=",
"null",
"|",
"|",
"partition",
"values",
"is",
"empty",
"(",
")",
")",
"{",
"return",
"null",
";",
"}",
"if",
"(",
"partition",
"keys",
"=",
"=",
"null",
"|",
"|",
"partition",
"values",
"size",
"(",
")",
"!",
"=",
"partition",
"keys",
"size",
"(",
")",
")",
"{",
"throw",
"new",
"presto",
"exception",
"(",
"hive",
"metastore",
"error",
",",
"\"",
"incorrect",
"number",
"of",
"partition",
"values",
":",
"\"",
"+",
"partition",
"values",
")",
";",
"}",
"list",
"<",
"string",
">",
"predicates",
"=",
"new",
"linked",
"list",
"<",
">",
"(",
")",
";",
"for",
"(",
"int",
"i",
"=",
"0",
";",
"i",
"<",
"partition",
"values",
"size",
"(",
")",
";",
"i",
"+",
"+",
")",
"{",
"if",
"(",
"!",
"strings",
"is",
"null",
"or",
"empty",
"(",
"partition",
"values",
"get",
"(",
"i",
")",
")",
")",
"{",
"predicates",
"add",
"(",
"build",
"predicate",
"(",
"partition",
"keys",
"get",
"(",
"i",
")",
",",
"partition",
"values",
"get",
"(",
"i",
")",
")",
")",
";",
"}",
"}",
"return",
"joiner",
"join",
"(",
"predicates",
")",
";",
"}"
] |
[
"returns",
"the",
"attributes"
] |
[
"public",
"attributes",
"get",
"attributes",
"(",
")",
"{",
"return",
"attrs",
";",
"}"
] |
[
"produce",
"error",
"view",
"model",
"and",
"view"
] |
[
"public",
"static",
"model",
"and",
"view",
"produce",
"error",
"view",
"(",
"final",
"exception",
"e",
")",
"{",
"return",
"produce",
"error",
"view",
"(",
"cas",
"webflow",
"constants",
"view",
"id",
"service",
"error",
",",
"e",
")",
";",
"}"
] |
[
"get",
"the",
"audio",
"from",
"the",
"list",
"with",
"the",
"highest",
"quality",
"format",
"will",
"be",
"ignored",
"if",
"it",
"yields",
"no",
"results"
] |
[
"static",
"int",
"get",
"highest",
"quality",
"audio",
"index",
"(",
"@",
"nullable",
"media",
"format",
"format",
",",
"final",
"list",
"<",
"audio",
"stream",
">",
"audio",
"streams",
")",
"{",
"int",
"result",
"=",
"-",
"1",
";",
"if",
"(",
"audio",
"streams",
"!",
"=",
"null",
")",
"{",
"while",
"(",
"result",
"=",
"=",
"-",
"1",
")",
"{",
"audio",
"stream",
"prev",
"stream",
"=",
"null",
";",
"for",
"(",
"int",
"idx",
"=",
"0",
";",
"idx",
"<",
"audio",
"streams",
"size",
"(",
")",
";",
"idx",
"+",
"+",
")",
"{",
"final",
"audio",
"stream",
"stream",
"=",
"audio",
"streams",
"get",
"(",
"idx",
")",
";",
"if",
"(",
"(",
"format",
"=",
"=",
"null",
"|",
"|",
"stream",
"get",
"format",
"(",
")",
"=",
"=",
"format",
")",
"&",
"&",
"(",
"prev",
"stream",
"=",
"=",
"null",
"|",
"|",
"compare",
"audio",
"stream",
"bitrate",
"(",
"prev",
"stream",
",",
"stream",
",",
"audio",
"format",
"quality",
"ranking",
")",
"<",
"0",
")",
")",
"{",
"prev",
"stream",
"=",
"stream",
";",
"result",
"=",
"idx",
";",
"}",
"}",
"if",
"(",
"result",
"=",
"=",
"-",
"1",
"&",
"&",
"format",
"=",
"=",
"null",
")",
"{",
"break",
";",
"}",
"format",
"=",
"null",
";",
"}",
"}",
"return",
"result",
";",
"}"
] |
[
"get",
"sub",
"sections",
"for",
"the",
"given",
"children",
"this",
"is",
"very",
"similar",
"to",
"{",
"@",
"link",
"#",
"get",
"children",
"(",
"section",
")",
"}",
"except",
"it",
"gets",
"the",
"children",
"intead",
"of",
"calling",
"create",
"children",
"this",
"is",
"useful",
"for",
"testing",
"the",
"output",
"of",
"{",
"@",
"link",
"com",
"facebook",
"litho",
"sections",
"common",
"render",
"section",
"event",
"}",
"handlers"
] |
[
"public",
"static",
"list",
"<",
"sub",
"section",
">",
"get",
"sub",
"sections",
"(",
"children",
"children",
")",
"{",
"if",
"(",
"children",
"=",
"=",
"null",
"|",
"|",
"children",
"get",
"children",
"(",
")",
"=",
"=",
"null",
")",
"{",
"return",
"null",
";",
"}",
"final",
"list",
"<",
"sub",
"section",
">",
"subsection",
"=",
"new",
"array",
"list",
"<",
">",
"(",
"children",
"get",
"children",
"(",
")",
"size",
"(",
")",
")",
";",
"for",
"(",
"final",
"section",
"s",
":",
"children",
"get",
"children",
"(",
")",
")",
"{",
"subsection",
"add",
"(",
"sub",
"section",
"of",
"(",
"s",
")",
")",
";",
"}",
"return",
"subsection",
";",
"}"
] |
[
"invoked",
"second",
"(",
"and",
"last",
")",
"if",
"the",
"body",
"is",
"empty"
] |
[
"object",
"handle",
"empty",
"body",
"(",
"@",
"nullable",
"object",
"body",
",",
"http",
"input",
"message",
"input",
"message",
",",
"method",
"parameter",
"parameter",
",",
"type",
"target",
"type",
",",
"class",
"<",
"?",
"extends",
"http",
"message",
"converter",
"<",
"?",
">",
">",
"converter",
"type",
")",
";"
] |
[
"configures",
"the",
"current",
"{",
"@",
"code",
"json",
"path",
"result",
"matchers",
"}",
"instance",
"to",
"verify",
"that",
"the",
"json",
"payload",
"is",
"prepended",
"with",
"the",
"given",
"prefix",
"use",
"this",
"method",
"if",
"the",
"json",
"payloads",
"are",
"prefixed",
"to",
"avoid",
"cross",
"site",
"script",
"inclusion",
"(",
"xssi",
")",
"attacks"
] |
[
"public",
"json",
"path",
"result",
"matchers",
"prefix",
"(",
"string",
"prefix",
")",
"{",
"this",
"prefix",
"=",
"prefix",
";",
"return",
"this",
";",
"}"
] |
[
"returns",
"the",
"long",
"array",
"which",
"this",
"buffer",
"is",
"based",
"on",
",",
"if",
"there",
"is",
"one"
] |
[
"public",
"final",
"long",
"[",
"]",
"array",
"(",
")",
"{",
"return",
"protected",
"array",
"(",
")",
";",
"}"
] |
[
"testing",
"an",
"error",
"case",
"reported",
"in",
"zookeeper",
"-",
"3756",
":",
"when",
"a",
"new",
"leader",
"election",
"happens",
"after",
"a",
"zoo",
"keeper",
"server",
"restarted",
",",
"in",
"kubernetes",
"the",
"rest",
"of",
"the",
"servers",
"can",
"not",
"initiate",
"connection",
"to",
"the",
"restarted",
"one",
"but",
"they",
"get",
"socket",
"timeout",
"exception",
"instead",
"of",
"immediate",
"i",
"o",
"exception",
"the",
"leader",
"election",
"was",
"time",
"-",
"outing",
"quicker",
"than",
"the",
"socket",
"connect",
"call",
",",
"so",
"we",
"ended",
"up",
"with",
"cycles",
"of",
"broken",
"leader",
"elections",
"the",
"fix",
"was",
"to",
"make",
"the",
"connection",
"initiation",
"asynchronous",
",",
"so",
"one",
"'",
"broken",
"'",
"connection",
"doesn",
"'",
"t",
"make",
"the",
"whole",
"leader",
"election",
"to",
"be",
"blocked",
",",
"even",
"in",
"case",
"of",
"socket",
"timeout",
"exception"
] |
[
"public",
"void",
"test",
"socket",
"connection",
"timeout",
"during",
"connecting",
"to",
"election",
"address",
"(",
")",
"throws",
"exception",
"{",
"int",
"leader",
"id",
"=",
"qu",
"get",
"leader",
"server",
"(",
")",
";",
"/",
"/",
"use",
"a",
"custom",
"socket",
"factory",
"that",
"will",
"cause",
"timeout",
"instead",
"of",
"connecting",
"to",
"the",
"/",
"/",
"leader",
"election",
"port",
"of",
"the",
"current",
"leader",
"final",
"inet",
"socket",
"address",
"leader",
"election",
"address",
"=",
"qu",
"get",
"leader",
"quorum",
"peer",
"(",
")",
"get",
"election",
"address",
"(",
")",
"get",
"one",
"(",
")",
";",
"quorum",
"cnx",
"manager",
"set",
"socket",
"factory",
"(",
"(",
")",
"-",
">",
"new",
"socket",
"stub",
"(",
"leader",
"election",
"address",
")",
")",
";",
"qu",
"shutdown",
"(",
"leader",
"id",
")",
";",
"assert",
"true",
"(",
"client",
"base",
"wait",
"for",
"server",
"down",
"(",
"\"",
"127",
"0",
"0",
"1",
":",
"\"",
"+",
"qu",
"get",
"peer",
"(",
"leader",
"id",
")",
"client",
"port",
",",
"client",
"base",
"connection",
"timeout",
")",
",",
"\"",
"timeout",
"during",
"waiting",
"for",
"current",
"leader",
"to",
"go",
"down",
"\"",
")",
";",
"string",
"error",
"message",
"=",
"\"",
"no",
"new",
"leader",
"was",
"elected",
"\"",
";",
"wait",
"for",
"(",
"error",
"message",
",",
"(",
")",
"-",
">",
"qu",
"leader",
"exists",
"(",
")",
"&",
"&",
"qu",
"get",
"leader",
"server",
"(",
")",
"!",
"=",
"leader",
"id",
",",
"15",
")",
";",
"}"
] |
[
"create",
"a",
"put",
"object",
"request",
"adds",
"the",
"acl",
"and",
"metadata"
] |
[
"public",
"put",
"object",
"request",
"new",
"put",
"object",
"request",
"(",
"string",
"key",
",",
"object",
"metadata",
"metadata",
",",
"file",
"srcfile",
")",
"{",
"preconditions",
"check",
"not",
"null",
"(",
"srcfile",
")",
";",
"put",
"object",
"request",
"put",
"object",
"request",
"=",
"new",
"put",
"object",
"request",
"(",
"bucket",
",",
"key",
",",
"srcfile",
")",
";",
"set",
"optional",
"put",
"request",
"parameters",
"(",
"put",
"object",
"request",
")",
";",
"put",
"object",
"request",
"set",
"canned",
"acl",
"(",
"canned",
"a",
"c",
"l",
")",
";",
"put",
"object",
"request",
"set",
"metadata",
"(",
"metadata",
")",
";",
"return",
"put",
"object",
"request",
";",
"}"
] |
[
"test",
"the",
"property",
"'",
"namespace",
"wrapped",
"array",
"'"
] |
[
"public",
"void",
"namespace",
"wrapped",
"array",
"test",
"(",
")",
"{",
"/",
"/",
"todo",
":",
"test",
"namespace",
"wrapped",
"array",
"}"
] |
[
"prepares",
"to",
"close",
"the",
"{",
"@",
"link",
"channel",
"}",
"if",
"this",
"method",
"returns",
"an",
"{",
"@",
"link",
"executor",
"}",
",",
"the",
"caller",
"must",
"call",
"the",
"{",
"@",
"link",
"executor",
"#",
"execute",
"(",
"runnable",
")",
"}",
"method",
"with",
"a",
"task",
"that",
"calls",
"{",
"@",
"link",
"#",
"do",
"close",
"(",
")",
"}",
"on",
"the",
"returned",
"{",
"@",
"link",
"executor",
"}",
"if",
"this",
"method",
"returns",
"{",
"@",
"code",
"null",
"}",
",",
"{",
"@",
"link",
"#",
"do",
"close",
"(",
")",
"}",
"must",
"be",
"called",
"from",
"the",
"caller",
"thread",
"(",
"i",
"e",
"{",
"@",
"link",
"event",
"loop",
"}",
")"
] |
[
"protected",
"executor",
"prepare",
"to",
"close",
"(",
")",
"{",
"return",
"null",
";",
"}"
] |
[
"use",
"router",
"navigation"
] |
[
"protected",
"object",
"navigation",
"(",
"final",
"context",
"context",
",",
"final",
"postcard",
"postcard",
",",
"final",
"int",
"request",
"code",
",",
"final",
"navigation",
"callback",
"callback",
")",
"{",
"pretreatment",
"service",
"pretreatment",
"service",
"=",
"a",
"router",
"get",
"instance",
"(",
")",
"navigation",
"(",
"pretreatment",
"service",
"class",
")",
";",
"if",
"(",
"null",
"!",
"=",
"pretreatment",
"service",
"&",
"&",
"!",
"pretreatment",
"service",
"on",
"pretreatment",
"(",
"context",
",",
"postcard",
")",
")",
"{",
"/",
"/",
"pretreatment",
"failed",
",",
"navigation",
"canceled",
"return",
"null",
";",
"}",
"/",
"/",
"set",
"context",
"to",
"postcard",
"postcard",
"set",
"context",
"(",
"null",
"=",
"=",
"context",
"?",
"m",
"context",
":",
"context",
")",
";",
"try",
"{",
"logistics",
"center",
"completion",
"(",
"postcard",
")",
";",
"}",
"catch",
"(",
"no",
"route",
"found",
"exception",
"ex",
")",
"{",
"logger",
"warning",
"(",
"consts",
"tag",
",",
"ex",
"get",
"message",
"(",
")",
")",
";",
"if",
"(",
"debuggable",
"(",
")",
")",
"{",
"/",
"/",
"show",
"friendly",
"tips",
"for",
"user",
"run",
"in",
"main",
"thread",
"(",
"new",
"runnable",
"(",
")",
"{",
"@",
"override",
"public",
"void",
"run",
"(",
")",
"{",
"toast",
"make",
"text",
"(",
"m",
"context",
",",
"\"",
"there",
"'",
"s",
"no",
"route",
"matched",
"!",
"\\",
"n",
"\"",
"+",
"\"",
"path",
"=",
"[",
"\"",
"+",
"postcard",
"get",
"path",
"(",
")",
"+",
"\"",
"]",
"\\",
"n",
"\"",
"+",
"\"",
"group",
"=",
"[",
"\"",
"+",
"postcard",
"get",
"group",
"(",
")",
"+",
"\"",
"]",
"\"",
",",
"toast",
"length",
"long",
")",
"show",
"(",
")",
";",
"}",
"}",
")",
";",
"}",
"if",
"(",
"null",
"!",
"=",
"callback",
")",
"{",
"callback",
"on",
"lost",
"(",
"postcard",
")",
";",
"}",
"else",
"{",
"/",
"/",
"no",
"callback",
"for",
"this",
"invoke",
",",
"then",
"we",
"use",
"the",
"global",
"degrade",
"service",
"degrade",
"service",
"degrade",
"service",
"=",
"a",
"router",
"get",
"instance",
"(",
")",
"navigation",
"(",
"degrade",
"service",
"class",
")",
";",
"if",
"(",
"null",
"!",
"=",
"degrade",
"service",
")",
"{",
"degrade",
"service",
"on",
"lost",
"(",
"context",
",",
"postcard",
")",
";",
"}",
"}",
"return",
"null",
";",
"}",
"if",
"(",
"null",
"!",
"=",
"callback",
")",
"{",
"callback",
"on",
"found",
"(",
"postcard",
")",
";",
"}",
"if",
"(",
"!",
"postcard",
"is",
"green",
"channel",
"(",
")",
")",
"{",
"/",
"/",
"it",
"must",
"be",
"run",
"in",
"async",
"thread",
",",
"maybe",
"interceptor",
"cost",
"too",
"mush",
"time",
"made",
"anr",
"interceptor",
"service",
"do",
"interceptions",
"(",
"postcard",
",",
"new",
"interceptor",
"callback",
"(",
")",
"{",
"/",
"*",
"*",
"*",
"continue",
"process",
"*",
"*",
"@",
"param",
"postcard",
"route",
"meta",
"*",
"/",
"@",
"override",
"public",
"void",
"on",
"continue",
"(",
"postcard",
"postcard",
")",
"{",
"navigation",
"(",
"postcard",
",",
"request",
"code",
",",
"callback",
")",
";",
"}"
] |
[
"update",
"the",
"status",
"of",
"the",
"task",
"this",
"update",
"is",
"done",
"by",
"ping",
"thread",
"before",
"sending",
"the",
"status"
] |
[
"synchronized",
"void",
"status",
"update",
"(",
"float",
"progress",
",",
"string",
"state",
",",
"counters",
"counters",
")",
"{",
"set",
"progress",
"(",
"progress",
")",
";",
"set",
"state",
"string",
"(",
"state",
")",
";",
"set",
"counters",
"(",
"counters",
")",
";",
"}"
] |
[
"returns",
"the",
"format",
"model",
"for",
"the",
"function",
"signature"
] |
[
"public",
"field",
"format",
"model",
"get",
"function",
"format",
"(",
")",
"{",
"return",
"models",
"[",
"field",
"format",
"model",
"function",
"]",
";",
"}"
] |
[
"{",
"@",
"inherit",
"doc",
"}"
] |
[
"public",
"int",
"hash",
"code",
"(",
")",
"{",
"return",
"annotation",
"hash",
"code",
"(",
")",
";",
"}"
] |
[
"quotes",
"an",
"argument",
"while",
"escaping",
"special",
"characters",
"interpreted",
"by",
"create",
"process"
] |
[
"public",
"static",
"@",
"non",
"null",
"string",
"quote",
"argument",
"(",
"@",
"non",
"null",
"string",
"argument",
")",
"{",
"if",
"(",
"!",
"needs",
"quoting",
"matcher",
"(",
"argument",
")",
"find",
"(",
")",
")",
"return",
"argument",
";",
"string",
"builder",
"sb",
"=",
"new",
"string",
"builder",
"(",
")",
";",
"sb",
"append",
"(",
"'",
"\"",
"'",
")",
";",
"int",
"end",
"=",
"argument",
"length",
"(",
")",
";",
"for",
"(",
"int",
"i",
"=",
"0",
";",
"i",
"<",
"end",
";",
"i",
"+",
"+",
")",
"{",
"int",
"nr",
"backslashes",
"=",
"0",
";",
"while",
"(",
"i",
"<",
"end",
"&",
"&",
"argument",
"char",
"at",
"(",
"i",
")",
"=",
"=",
"'",
"\\",
"\\",
"'",
")",
"{",
"i",
"+",
"+",
";",
"nr",
"backslashes",
"+",
"+",
";",
"}",
"if",
"(",
"i",
"=",
"=",
"end",
")",
"{",
"/",
"/",
"backslashes",
"at",
"the",
"end",
"of",
"the",
"argument",
"must",
"be",
"escaped",
"so",
"the",
"terminate",
"quote",
"isn",
"'",
"t",
"nr",
"backslashes",
"=",
"nr",
"backslashes",
"*",
"2",
";",
"}",
"else",
"if",
"(",
"argument",
"char",
"at",
"(",
"i",
")",
"=",
"=",
"'",
"\"",
"'",
")",
"{",
"/",
"/",
"backslashes",
"preceding",
"a",
"quote",
"all",
"need",
"to",
"be",
"escaped",
"along",
"with",
"the",
"quote",
"nr",
"backslashes",
"=",
"nr",
"backslashes",
"*",
"2",
"+",
"1",
";",
"}",
"/",
"/",
"else",
"backslashes",
"have",
"no",
"special",
"meaning",
"and",
"don",
"'",
"t",
"need",
"to",
"be",
"escaped",
"here",
"for",
"(",
"int",
"j",
"=",
"0",
";",
"j",
"<",
"nr",
"backslashes",
";",
"j",
"+",
"+",
")",
"{",
"sb",
"append",
"(",
"'",
"\\",
"\\",
"'",
")",
";",
"}",
"if",
"(",
"i",
"<",
"end",
")",
"{",
"sb",
"append",
"(",
"argument",
"char",
"at",
"(",
"i",
")",
")",
";",
"}",
"}",
"return",
"sb",
"append",
"(",
"'",
"\"",
"'",
")",
"to",
"string",
"(",
")",
";",
"}"
] |
[
"appends",
"a",
"{",
"@",
"link",
"uuid",
"}",
"to",
"the",
"fingerprint",
"message"
] |
[
"public",
"fingerprint",
"add",
"u",
"u",
"i",
"d",
"(",
"uuid",
"uuid",
")",
"{",
"add",
"long",
"(",
"uuid",
"get",
"least",
"significant",
"bits",
"(",
")",
")",
";",
"add",
"long",
"(",
"uuid",
"get",
"most",
"significant",
"bits",
"(",
")",
")",
";",
"return",
"this",
";",
"}"
] |
[
"gets",
"http",
"servlet",
"response",
"from",
"request",
"attributes"
] |
[
"public",
"static",
"http",
"servlet",
"response",
"get",
"http",
"servlet",
"response",
"from",
"request",
"attributes",
"(",
")",
"{",
"val",
"request",
"attributes",
"=",
"(",
"servlet",
"request",
"attributes",
")",
"request",
"context",
"holder",
"get",
"request",
"attributes",
"(",
")",
";",
"return",
"optional",
"of",
"nullable",
"(",
"request",
"attributes",
")",
"map",
"(",
"servlet",
"request",
"attributes",
":",
":",
"get",
"response",
")",
"or",
"else",
"(",
"null",
")",
";",
"}"
] |
[
"get",
"parser",
"for",
"this",
"command",
"exposed",
"to",
"be",
"overridden",
"by",
"{",
"@",
"link",
"hudson",
"cli",
"declarative",
"c",
"l",
"i",
"registerer",
"}"
] |
[
"protected",
"cmd",
"line",
"parser",
"get",
"cmd",
"line",
"parser",
"(",
")",
"{",
"return",
"new",
"cmd",
"line",
"parser",
"(",
"this",
")",
";",
"}"
] |
[
"creates",
"a",
"new",
"set",
"of",
"rotation",
"options",
"for",
"jpeg",
"images",
"to",
"use",
"the",
"rotation",
"angle",
"in",
"the",
"image",
"metadata",
"the",
"rotation",
"may",
"be",
"deferred",
"until",
"the",
"image",
"is",
"rendered"
] |
[
"public",
"static",
"rotation",
"options",
"auto",
"rotate",
"at",
"render",
"time",
"(",
")",
"{",
"return",
"rotation",
"options",
"rotate",
"at",
"render",
"time",
";",
"}"
] |
[
"tests",
"that",
"a",
"tree",
"prop",
"is",
"propagated",
"down",
"a",
"section",
"tree",
",",
"is",
"scoped",
"correctly",
",",
"and",
"can",
"be",
"overwritten"
] |
[
"public",
"void",
"test",
"tree",
"props",
"propagated",
"(",
")",
"{",
"final",
"result",
"prop",
"a",
"leaf",
"1",
"=",
"new",
"result",
"(",
")",
";",
"final",
"result",
"prop",
"b",
"leaf",
"1",
"=",
"new",
"result",
"(",
")",
";",
"final",
"result",
"prop",
"b",
"leaf",
"2",
"=",
"new",
"result",
"(",
")",
";",
"final",
"tree",
"prop",
"number",
"type",
"tree",
"prop",
"a",
"=",
"new",
"tree",
"prop",
"number",
"type",
"(",
"9",
")",
";",
"final",
"tree",
"prop",
"string",
"type",
"tree",
"prop",
"b",
"=",
"new",
"tree",
"prop",
"string",
"type",
"(",
"\"",
"prop",
"b",
"\"",
")",
";",
"final",
"tree",
"prop",
"string",
"type",
"tree",
"prop",
"b",
"changed",
"=",
"new",
"tree",
"prop",
"string",
"type",
"(",
"\"",
"prop",
"b",
"changed",
"\"",
")",
";",
"final",
"section",
"tree",
"tree",
"=",
"section",
"tree",
"create",
"(",
"m",
"context",
",",
"new",
"test",
"target",
"(",
")",
")",
"build",
"(",
")",
";",
"tree",
"set",
"root",
"(",
"tree",
"prop",
"section",
"test",
"parent",
"group",
"create",
"(",
"m",
"context",
")",
"prop",
"a",
"(",
"tree",
"prop",
"a",
")",
"prop",
"b",
"(",
"tree",
"prop",
"b",
")",
"result",
"prop",
"a",
"leaf",
"1",
"(",
"prop",
"a",
"leaf",
"1",
")",
"result",
"prop",
"b",
"leaf",
"1",
"(",
"prop",
"b",
"leaf",
"1",
")",
"result",
"prop",
"b",
"leaf",
"2",
"(",
"prop",
"b",
"leaf",
"2",
")",
"build",
"(",
")",
")",
";",
"assert",
"that",
"(",
"prop",
"a",
"leaf",
"1",
"m",
"prop",
")",
"is",
"equal",
"to",
"(",
"tree",
"prop",
"a",
")",
";",
"/",
"/",
"tree",
"prop",
"section",
"test",
"middle",
"group",
"spec",
"modifies",
"\"",
"prop",
"b",
"\"",
"assert",
"that",
"(",
"prop",
"b",
"leaf",
"1",
"m",
"prop",
")",
"is",
"equal",
"to",
"(",
"tree",
"prop",
"b",
"changed",
")",
";",
"/",
"/",
"the",
"second",
"leaf",
"group",
"spec",
"does",
"not",
"see",
"the",
"modification",
"to",
"\"",
"prop",
"b",
"\"",
"/",
"/",
"because",
"its",
"not",
"a",
"descendant",
"of",
"middle",
"group",
"spec",
"assert",
"that",
"(",
"prop",
"b",
"leaf",
"2",
"m",
"prop",
")",
"is",
"equal",
"to",
"(",
"tree",
"prop",
"b",
")",
";",
"}"
] |
[
"block",
"recovery",
"f",
"i",
"07",
"max",
"replica",
"length",
"from",
"all",
"d",
"ns",
"is",
"zero"
] |
[
"public",
"void",
"test",
"zero",
"len",
"replicas",
"(",
")",
"throws",
"i",
"o",
"exception",
",",
"interrupted",
"exception",
"{",
"if",
"(",
"log",
"is",
"debug",
"enabled",
"(",
")",
")",
"{",
"log",
"debug",
"(",
"\"",
"running",
"\"",
"+",
"generic",
"test",
"utils",
"get",
"method",
"name",
"(",
")",
")",
";",
"}",
"do",
"return",
"(",
"new",
"replica",
"recovery",
"info",
"(",
"block",
"get",
"block",
"id",
"(",
")",
",",
"0",
",",
"block",
"get",
"generation",
"stamp",
"(",
")",
",",
"replica",
"state",
"finalized",
")",
")",
"when",
"(",
"spy",
"d",
"n",
")",
"init",
"replica",
"recovery",
"(",
"any",
"(",
"recovering",
"block",
"class",
")",
")",
";",
"for",
"(",
"recovering",
"block",
"r",
"block",
":",
"init",
"recovering",
"blocks",
"(",
")",
")",
"{",
"block",
"recovery",
"worker",
"recovery",
"task",
"contiguous",
"recovery",
"task",
"contiguous",
"=",
"recovery",
"worker",
"new",
"recovery",
"task",
"contiguous",
"(",
"r",
"block",
")",
";",
"block",
"recovery",
"worker",
"recovery",
"task",
"contiguous",
"spy",
"task",
"=",
"spy",
"(",
"recovery",
"task",
"contiguous",
")",
";",
"spy",
"task",
"recover",
"(",
")",
";",
"}",
"datanode",
"protocol",
"dn",
"p",
"=",
"recovery",
"worker",
"get",
"active",
"namenode",
"for",
"b",
"p",
"(",
"pool",
"id",
")",
";",
"verify",
"(",
"dn",
"p",
")",
"commit",
"block",
"synchronization",
"(",
"block",
",",
"recovery",
"id",
",",
"0",
",",
"true",
",",
"true",
",",
"datanode",
"i",
"d",
"empty",
"array",
",",
"null",
")",
";",
"}"
] |
[
"model",
"tests",
"for",
"model",
"2",
"0",
"0",
"response"
] |
[
"public",
"void",
"test",
"model",
"2",
"0",
"0",
"response",
"(",
")",
"{",
"/",
"/",
"todo",
":",
"test",
"model",
"2",
"0",
"0",
"response",
"}"
] |
[
"model",
"tests",
"for",
"user"
] |
[
"public",
"void",
"test",
"user",
"(",
")",
"{",
"/",
"/",
"todo",
":",
"test",
"user",
"}"
] |
[
"set",
"the",
"offset",
"this",
"value",
"is",
"the",
"byte",
"offset",
"into",
"the",
"elf",
"file"
] |
[
"public",
"void",
"set",
"offset",
"(",
"long",
"offset",
")",
"{",
"this",
"p",
"offset",
"=",
"offset",
";",
"}"
] |
[
"return",
"the",
"regular",
"expression",
"j",
"s",
"o",
"n",
"schema",
"pattern",
"(",
"http",
":",
"json",
"-",
"schema",
"orglatestjson",
"-",
"schema",
"-",
"validation",
"html",
"#",
"anchor",
"3",
"3",
")"
] |
[
"public",
"string",
"to",
"regular",
"expression",
"(",
"string",
"pattern",
")",
"{",
"return",
"escape",
"text",
"(",
"pattern",
")",
";",
"}"
] |
[
"send",
"a",
"command",
"with",
"2",
"parameters",
"to",
"the",
"decompiler",
"and",
"read",
"the",
"result"
] |
[
"public",
"synchronized",
"limited",
"byte",
"buffer",
"send",
"command",
"2",
"params",
"(",
"string",
"command",
",",
"string",
"param",
"1",
",",
"string",
"param",
"2",
")",
"throws",
"i",
"o",
"exception",
",",
"decompile",
"exception",
"{",
"if",
"(",
"!",
"status",
"good",
")",
"{",
"throw",
"new",
"i",
"o",
"exception",
"(",
"command",
"+",
"\"",
"called",
"on",
"bad",
"process",
"\"",
")",
";",
"}",
"limited",
"byte",
"buffer",
"resbuf",
"=",
"null",
";",
"try",
"{",
"write",
"(",
"command",
"start",
")",
";",
"write",
"string",
"(",
"command",
")",
";",
"write",
"string",
"(",
"integer",
"to",
"string",
"(",
"arch",
"id",
")",
")",
";",
"write",
"string",
"(",
"param",
"1",
")",
";",
"write",
"string",
"(",
"param",
"2",
")",
";",
"write",
"(",
"command",
"end",
")",
";",
"resbuf",
"=",
"read",
"response",
"(",
")",
";",
"}",
"catch",
"(",
"i",
"o",
"exception",
"e",
")",
"{",
"status",
"good",
"=",
"false",
";",
"throw",
"e",
";",
"}",
"return",
"resbuf",
";",
"}"
] |
[
"reads",
"the",
"next",
"four",
"bytes",
"as",
"an",
"unsigned",
"integer",
"into",
"an",
"integer",
",",
"if",
"the",
"top",
"bit",
"is",
"a",
"zero"
] |
[
"public",
"int",
"read",
"unsigned",
"int",
"to",
"int",
"(",
")",
"{",
"int",
"result",
"=",
"read",
"int",
"(",
")",
";",
"if",
"(",
"result",
"<",
"0",
")",
"{",
"throw",
"new",
"illegal",
"state",
"exception",
"(",
"\"",
"top",
"bit",
"not",
"zero",
":",
"\"",
"+",
"result",
")",
";",
"}",
"return",
"result",
";",
"}"
] |
[
"assert",
"that",
"the",
"target",
"bean",
"class",
"is",
"an",
"instance",
"of",
"the",
"class",
"where",
"the",
"given",
"method",
"is",
"declared",
"in",
"some",
"cases",
"the",
"actual",
"bean",
"instance",
"at",
"event",
"-",
"processing",
"time",
"may",
"be",
"a",
"jdk",
"dynamic",
"proxy",
"(",
"lazy",
"initialization",
",",
"prototype",
"beans",
",",
"and",
"others",
")",
"event",
"listener",
"beans",
"that",
"require",
"proxying",
"should",
"prefer",
"class",
"-",
"based",
"proxy",
"mechanisms"
] |
[
"private",
"void",
"assert",
"target",
"bean",
"(",
"method",
"method",
",",
"object",
"target",
"bean",
",",
"object",
"[",
"]",
"args",
")",
"{",
"class",
"<",
"?",
">",
"method",
"declaring",
"class",
"=",
"method",
"get",
"declaring",
"class",
"(",
")",
";",
"class",
"<",
"?",
">",
"target",
"bean",
"class",
"=",
"target",
"bean",
"get",
"class",
"(",
")",
";",
"if",
"(",
"!",
"method",
"declaring",
"class",
"is",
"assignable",
"from",
"(",
"target",
"bean",
"class",
")",
")",
"{",
"string",
"msg",
"=",
"\"",
"the",
"event",
"listener",
"method",
"class",
"'",
"\"",
"+",
"method",
"declaring",
"class",
"get",
"name",
"(",
")",
"+",
"\"",
"'",
"is",
"not",
"an",
"instance",
"of",
"the",
"actual",
"bean",
"class",
"'",
"\"",
"+",
"target",
"bean",
"class",
"get",
"name",
"(",
")",
"+",
"\"",
"'",
"if",
"the",
"bean",
"requires",
"proxying",
"\"",
"+",
"\"",
"(",
"e",
"g",
"due",
"to",
"@",
"transactional",
")",
",",
"please",
"use",
"class",
"-",
"based",
"proxying",
"\"",
";",
"throw",
"new",
"illegal",
"state",
"exception",
"(",
"get",
"invocation",
"error",
"message",
"(",
"target",
"bean",
",",
"msg",
",",
"args",
")",
")",
";",
"}",
"}"
] |
[
"returns",
"the",
"prefixed",
"name",
"of",
"a",
"server",
"property"
] |
[
"public",
"string",
"get",
"prefixed",
"name",
"(",
"string",
"name",
")",
"{",
"return",
"get",
"prefix",
"(",
")",
"+",
"\"",
"\"",
"+",
"check",
"not",
"empty",
"(",
"name",
",",
"\"",
"name",
"\"",
")",
";",
"}"
] |
[
"register",
"a",
"listener",
"that",
"will",
"be",
"called",
"when",
"this",
"model",
"is",
"bound",
"to",
"a",
"view",
"the",
"listener",
"will",
"contribute",
"to",
"this",
"model",
"'",
"s",
"hash",
"code",
"state",
"per",
"the",
"{",
"@",
"link",
"com",
"airbnb",
"epoxy",
"epoxy",
"attribute",
"option",
"#",
"do",
"not",
"hash",
"}",
"rules",
"you",
"may",
"clear",
"the",
"listener",
"by",
"setting",
"a",
"null",
"value",
",",
"or",
"by",
"calling",
"{",
"@",
"link",
"#",
"reset",
"(",
")",
"}"
] |
[
"public",
"model",
"view",
"extending",
"super",
"class",
"model",
"on",
"bind",
"(",
"on",
"model",
"bound",
"listener",
"<",
"model",
"view",
"extending",
"super",
"class",
"model",
",",
"model",
"view",
"extending",
"super",
"class",
">",
"listener",
")",
"{",
"on",
"mutation",
"(",
")",
";",
"this",
"on",
"model",
"bound",
"listener",
"epoxy",
"generated",
"model",
"=",
"listener",
";",
"return",
"this",
";",
"}"
] |
[
"merges",
"this",
"rectangle",
"with",
"the",
"other",
"rectangle",
"the",
"rectangle",
"should",
"not",
"have",
"negative",
"width",
"or",
"negative",
"height"
] |
[
"public",
"rectangle",
"merge",
"(",
"rectangle",
"rect",
")",
"{",
"float",
"min",
"x",
"=",
"math",
"min",
"(",
"x",
",",
"rect",
"x",
")",
";",
"float",
"max",
"x",
"=",
"math",
"max",
"(",
"x",
"+",
"width",
",",
"rect",
"x",
"+",
"rect",
"width",
")",
";",
"x",
"=",
"min",
"x",
";",
"width",
"=",
"max",
"x",
"-",
"min",
"x",
";",
"float",
"min",
"y",
"=",
"math",
"min",
"(",
"y",
",",
"rect",
"y",
")",
";",
"float",
"max",
"y",
"=",
"math",
"max",
"(",
"y",
"+",
"height",
",",
"rect",
"y",
"+",
"rect",
"height",
")",
";",
"y",
"=",
"min",
"y",
";",
"height",
"=",
"max",
"y",
"-",
"min",
"y",
";",
"return",
"this",
";",
"}"
] |
[
"cancels",
"all",
"running",
"uploads",
"the",
"method",
"returns",
"immediately",
"and",
"does",
"not",
"wait",
"for",
"the",
"uploads",
"to",
"be",
"cancelled",
"this",
"method",
"should",
"not",
"be",
"called",
"directly",
",",
"but",
"will",
"be",
"called",
"implicitly",
"when",
"the",
"reference",
"count",
"reaches",
"{",
"@",
"code",
"0",
"}"
] |
[
"void",
"shutdown",
"(",
")",
"{",
"synchronized",
"(",
"lock",
")",
"{",
"if",
"(",
"is",
"shutdown",
")",
"{",
"return",
";",
"}",
"is",
"shutdown",
"=",
"true",
";",
"/",
"/",
"before",
"cancelling",
",",
"copy",
"the",
"futures",
"to",
"a",
"separate",
"list",
"in",
"order",
"to",
"avoid",
"concurrently",
"/",
"/",
"iterating",
"over",
"and",
"modifying",
"the",
"map",
"(",
"cancel",
"triggers",
"a",
"listener",
"that",
"removes",
"the",
"entry",
"/",
"/",
"from",
"the",
"map",
"the",
"listener",
"is",
"executed",
"in",
"the",
"same",
"thread",
")",
"list",
"<",
"future",
"<",
"void",
">",
">",
"uploads",
"to",
"cancel",
"=",
"new",
"array",
"list",
"<",
">",
"(",
"uploads",
"in",
"progress",
"values",
"(",
")",
")",
";",
"for",
"(",
"future",
"<",
"void",
">",
"upload",
":",
"uploads",
"to",
"cancel",
")",
"{",
"upload",
"cancel",
"(",
"true",
")",
";",
"}",
"}",
"}"
] |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.