id stringlengths 7 14 | test_class dict | test_case dict | focal_class dict | focal_method dict | repository dict |
|---|---|---|---|---|---|
32104835_118 | {
"fields": [],
"file": "zxpoly-z80/src/test/java/com/igormaznitsa/z80/Z80Test.java",
"identifier": "Z80Test",
"interfaces": "",
"superclass": "extends AbstractZ80Test"
} | {
"body": "@Test\n public void testCommand_INC_SP() {\n final Z80State state = new Z80State();\n state.SP = 0x1000;\n state.F = 0xFF;\n\n final Pair<Z80, Integer> cpu = executeCommand(state, 0x33);\n\n assertEquals(0x1001, cpu.getLeft().getRegister(Z80.REG_SP));\n assertFlagsNotChanged(state, cpu.g... | {
"fields": [
{
"declarator": "REG_A = 0",
"modifier": "public static final",
"original_string": "public static final int REG_A = 0;",
"type": "int",
"var_name": "REG_A"
},
{
"declarator": "REG_F = 1",
"modifier": "public static final",
"original_string": "p... | {
"body": "public int getRegister(final int reg) {\n return this.getRegister(reg, false);\n }",
"class_method_signature": "Z80.getRegister(final int reg)",
"constructor": false,
"full_signature": "public int getRegister(final int reg)",
"identifier": "getRegister",
"invocations": [
"getRegister"
]... | {
"created": null,
"fork": null,
"fork_count": 5,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 32104835,
"size": 23159,
"stargazer_count": 44,
"stars": null,
"updates": null,
"url": "https://github.com/raydac/zxpoly"
} |
32104835_227 | {
"fields": [],
"file": "zxpoly-z80/src/test/java/com/igormaznitsa/z80/Z80Test.java",
"identifier": "Z80Test",
"interfaces": "",
"superclass": "extends AbstractZ80Test"
} | {
"body": "@Test\n public void testCommand_LD_IXh_nn() {\n final Z80State state = new Z80State();\n state.IX = 0xFFFF;\n final Pair<Z80, Integer> cpu = executeCommand(state, 0xDD, 0x26, 0x12);\n assertEquals(0x12FF, cpu.getLeft().getRegister(Z80.REG_IX));\n assertFlagsNotChanged(state, cpu.getLeft());... | {
"fields": [
{
"declarator": "REG_A = 0",
"modifier": "public static final",
"original_string": "public static final int REG_A = 0;",
"type": "int",
"var_name": "REG_A"
},
{
"declarator": "REG_F = 1",
"modifier": "public static final",
"original_string": "p... | {
"body": "public int getRegister(final int reg) {\n return this.getRegister(reg, false);\n }",
"class_method_signature": "Z80.getRegister(final int reg)",
"constructor": false,
"full_signature": "public int getRegister(final int reg)",
"identifier": "getRegister",
"invocations": [
"getRegister"
]... | {
"created": null,
"fork": null,
"fork_count": 5,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 32104835,
"size": 23159,
"stargazer_count": 44,
"stars": null,
"updates": null,
"url": "https://github.com/raydac/zxpoly"
} |
32104835_63 | {
"fields": [],
"file": "zxpoly-z80/src/test/java/com/igormaznitsa/z80/Z80Test.java",
"identifier": "Z80Test",
"interfaces": "",
"superclass": "extends AbstractZ80Test"
} | {
"body": "@Test\n public void testCommand_ADC_C_flagV() {\n final Z80State state = new Z80State();\n state.A = 0x44;\n state.C = 0x7F;\n\n state.F = 0xFF;\n\n final Pair<Z80, Integer> cpu = executeCommand(state, 0x89);\n\n assertEquals(0x7F, cpu.getLeft().getRegister(Z80.REG_C));\n assertEquals... | {
"fields": [
{
"declarator": "REG_A = 0",
"modifier": "public static final",
"original_string": "public static final int REG_A = 0;",
"type": "int",
"var_name": "REG_A"
},
{
"declarator": "REG_F = 1",
"modifier": "public static final",
"original_string": "p... | {
"body": "public int getRegister(final int reg) {\n return this.getRegister(reg, false);\n }",
"class_method_signature": "Z80.getRegister(final int reg)",
"constructor": false,
"full_signature": "public int getRegister(final int reg)",
"identifier": "getRegister",
"invocations": [
"getRegister"
]... | {
"created": null,
"fork": null,
"fork_count": 5,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 32104835,
"size": 23159,
"stargazer_count": 44,
"stars": null,
"updates": null,
"url": "https://github.com/raydac/zxpoly"
} |
32104835_34 | {
"fields": [],
"file": "zxpoly-z80/src/test/java/com/igormaznitsa/z80/Z80Test.java",
"identifier": "Z80Test",
"interfaces": "",
"superclass": "extends AbstractZ80Test"
} | {
"body": "@Test\n public void testCommand_LD_HL_nn() {\n final Z80State state = new Z80State();\n final Pair<Z80, Integer> cpu = executeCommand(state, 0x21, 0x34, 0x12);\n assertEquals(0x1234, cpu.getLeft().getRegisterPair(Z80.REGPAIR_HL));\n assertFlagsNotChanged(state, cpu.getLeft());\n assertEqual... | {
"fields": [
{
"declarator": "REG_A = 0",
"modifier": "public static final",
"original_string": "public static final int REG_A = 0;",
"type": "int",
"var_name": "REG_A"
},
{
"declarator": "REG_F = 1",
"modifier": "public static final",
"original_string": "p... | {
"body": "public int getRegisterPair(final int regPair) {\n return this.getRegisterPair(regPair, false);\n }",
"class_method_signature": "Z80.getRegisterPair(final int regPair)",
"constructor": false,
"full_signature": "public int getRegisterPair(final int regPair)",
"identifier": "getRegisterPair",
"i... | {
"created": null,
"fork": null,
"fork_count": 5,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 32104835,
"size": 23159,
"stargazer_count": 44,
"stars": null,
"updates": null,
"url": "https://github.com/raydac/zxpoly"
} |
32104835_159 | {
"fields": [],
"file": "zxpoly-z80/src/test/java/com/igormaznitsa/z80/Z80Test.java",
"identifier": "Z80Test",
"interfaces": "",
"superclass": "extends AbstractZ80Test"
} | {
"body": "@Test\n public void testCommand_SLA_mIYd() {\n final Z80State state = new Z80State();\n state.IY = 0x1234;\n state.F = 0x00;\n\n memory[0x1239] = (byte) 0xB1;\n\n final Pair<Z80, Integer> cpu = executeCommand(state, 0xFD, 0xCB, 0x05, 0x26);\n\n assertMemory(0x1239, 0x62);\n assertFlag... | {
"fields": [
{
"declarator": "REG_A = 0",
"modifier": "public static final",
"original_string": "public static final int REG_A = 0;",
"type": "int",
"var_name": "REG_A"
},
{
"declarator": "REG_F = 1",
"modifier": "public static final",
"original_string": "p... | {
"body": "public int getRegister(final int reg) {\n return this.getRegister(reg, false);\n }",
"class_method_signature": "Z80.getRegister(final int reg)",
"constructor": false,
"full_signature": "public int getRegister(final int reg)",
"identifier": "getRegister",
"invocations": [
"getRegister"
]... | {
"created": null,
"fork": null,
"fork_count": 5,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 32104835,
"size": 23159,
"stargazer_count": 44,
"stars": null,
"updates": null,
"url": "https://github.com/raydac/zxpoly"
} |
32104835_122 | {
"fields": [],
"file": "zxpoly-z80/src/test/java/com/igormaznitsa/z80/Z80Test.java",
"identifier": "Z80Test",
"interfaces": "",
"superclass": "extends AbstractZ80Test"
} | {
"body": "@Test\n public void testCommand_INC_IXl() {\n final Z80State state = new Z80State();\n state.IX = 0xFFFF;\n state.F = 0xFF;\n\n final Pair<Z80, Integer> cpu = executeCommand(state, 0xDD, 0x2C);\n\n assertEquals(0xFF00, cpu.getLeft().getRegister(Z80.REG_IX));\n assertEquals(8, cpu.getRigh... | {
"fields": [
{
"declarator": "REG_A = 0",
"modifier": "public static final",
"original_string": "public static final int REG_A = 0;",
"type": "int",
"var_name": "REG_A"
},
{
"declarator": "REG_F = 1",
"modifier": "public static final",
"original_string": "p... | {
"body": "public int getRegister(final int reg) {\n return this.getRegister(reg, false);\n }",
"class_method_signature": "Z80.getRegister(final int reg)",
"constructor": false,
"full_signature": "public int getRegister(final int reg)",
"identifier": "getRegister",
"invocations": [
"getRegister"
]... | {
"created": null,
"fork": null,
"fork_count": 5,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 32104835,
"size": 23159,
"stargazer_count": 44,
"stars": null,
"updates": null,
"url": "https://github.com/raydac/zxpoly"
} |
32104835_18 | {
"fields": [],
"file": "zxpoly-z80/src/test/java/com/igormaznitsa/z80/Z80Test.java",
"identifier": "Z80Test",
"interfaces": "",
"superclass": "extends AbstractZ80Test"
} | {
"body": "@Test\n public void testCommand_LD_A_mBC() {\n final Z80State state = new Z80State();\n state.A = 0x48;\n state.B = 0x12;\n state.C = 0x34;\n this.memory[0x1234] = 0x33;\n final Pair<Z80, Integer> cpu = executeCommand(state, 0x0A);\n assertEquals(0x33, cpu.getLeft().getRegister(Z80.RE... | {
"fields": [
{
"declarator": "REG_A = 0",
"modifier": "public static final",
"original_string": "public static final int REG_A = 0;",
"type": "int",
"var_name": "REG_A"
},
{
"declarator": "REG_F = 1",
"modifier": "public static final",
"original_string": "p... | {
"body": "public int getRegister(final int reg) {\n return this.getRegister(reg, false);\n }",
"class_method_signature": "Z80.getRegister(final int reg)",
"constructor": false,
"full_signature": "public int getRegister(final int reg)",
"identifier": "getRegister",
"invocations": [
"getRegister"
]... | {
"created": null,
"fork": null,
"fork_count": 5,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 32104835,
"size": 23159,
"stargazer_count": 44,
"stars": null,
"updates": null,
"url": "https://github.com/raydac/zxpoly"
} |
32104835_175 | {
"fields": [],
"file": "zxpoly-z80/src/test/java/com/igormaznitsa/z80/Z80Test.java",
"identifier": "Z80Test",
"interfaces": "",
"superclass": "extends AbstractZ80Test"
} | {
"body": "@Test\n public void testCommand_BIT_7_regIX() {\n for (int i = 0; i < 0xFF; i++) {\n final Z80State state = new Z80State();\n state.IX = 0x1010;\n this.memory[0x1011] = (byte) i;\n\n final int origf = i ^ 0xFF;\n state.F = origf;\n\n final Pair<Z80, Integer> cpu = executeC... | {
"fields": [
{
"declarator": "REG_A = 0",
"modifier": "public static final",
"original_string": "public static final int REG_A = 0;",
"type": "int",
"var_name": "REG_A"
},
{
"declarator": "REG_F = 1",
"modifier": "public static final",
"original_string": "p... | {
"body": "public int getRegister(final int reg) {\n return this.getRegister(reg, false);\n }",
"class_method_signature": "Z80.getRegister(final int reg)",
"constructor": false,
"full_signature": "public int getRegister(final int reg)",
"identifier": "getRegister",
"invocations": [
"getRegister"
]... | {
"created": null,
"fork": null,
"fork_count": 5,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 32104835,
"size": 23159,
"stargazer_count": 44,
"stars": null,
"updates": null,
"url": "https://github.com/raydac/zxpoly"
} |
32104835_163 | {
"fields": [],
"file": "zxpoly-z80/src/test/java/com/igormaznitsa/z80/Z80Test.java",
"identifier": "Z80Test",
"interfaces": "",
"superclass": "extends AbstractZ80Test"
} | {
"body": "@Test\n public void testCommand_SLL_mIYd() {\n final Z80State state = new Z80State();\n state.IY = 0x1234;\n state.F = 0x00;\n\n memory[0x1239] = (byte) 0xB1;\n\n final Pair<Z80, Integer> cpu = executeCommand(state, 0xFD, 0xCB, 0x05, 0x36);\n\n assertMemory(0x1239, 0x63);\n assertFlag... | {
"fields": [
{
"declarator": "REG_A = 0",
"modifier": "public static final",
"original_string": "public static final int REG_A = 0;",
"type": "int",
"var_name": "REG_A"
},
{
"declarator": "REG_F = 1",
"modifier": "public static final",
"original_string": "p... | {
"body": "public int getRegister(final int reg) {\n return this.getRegister(reg, false);\n }",
"class_method_signature": "Z80.getRegister(final int reg)",
"constructor": false,
"full_signature": "public int getRegister(final int reg)",
"identifier": "getRegister",
"invocations": [
"getRegister"
]... | {
"created": null,
"fork": null,
"fork_count": 5,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 32104835,
"size": 23159,
"stargazer_count": 44,
"stars": null,
"updates": null,
"url": "https://github.com/raydac/zxpoly"
} |
32104835_59 | {
"fields": [],
"file": "zxpoly-z80/src/test/java/com/igormaznitsa/z80/Z80Test.java",
"identifier": "Z80Test",
"interfaces": "",
"superclass": "extends AbstractZ80Test"
} | {
"body": "@Test\n public void testCommand_ADD_mIXd_flagV() {\n final Z80State state = new Z80State();\n state.A = 0x44;\n\n state.F = 0xFF;\n state.IX = 0x1234;\n\n memory[0x1237] = (byte) 0x7F;\n\n final Pair<Z80, Integer> cpu = executeCommand(state, 0xDD, 0x86, 3);\n\n assertEquals(0xC3, cpu.... | {
"fields": [
{
"declarator": "REG_A = 0",
"modifier": "public static final",
"original_string": "public static final int REG_A = 0;",
"type": "int",
"var_name": "REG_A"
},
{
"declarator": "REG_F = 1",
"modifier": "public static final",
"original_string": "p... | {
"body": "public int getRegister(final int reg) {\n return this.getRegister(reg, false);\n }",
"class_method_signature": "Z80.getRegister(final int reg)",
"constructor": false,
"full_signature": "public int getRegister(final int reg)",
"identifier": "getRegister",
"invocations": [
"getRegister"
]... | {
"created": null,
"fork": null,
"fork_count": 5,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 32104835,
"size": 23159,
"stargazer_count": 44,
"stars": null,
"updates": null,
"url": "https://github.com/raydac/zxpoly"
} |
32104835_134 | {
"fields": [],
"file": "zxpoly-z80/src/test/java/com/igormaznitsa/z80/Z80Test.java",
"identifier": "Z80Test",
"interfaces": "",
"superclass": "extends AbstractZ80Test"
} | {
"body": "@Test\n public void testCommand_DEC_IY() {\n final Z80State state = new Z80State();\n state.IY = 0x1000;\n state.F = 0xFF;\n\n final Pair<Z80, Integer> cpu = executeCommand(state, 0xFD, 0x2B);\n\n assertEquals(0x0FFF, cpu.getLeft().getRegister(Z80.REG_IY));\n assertFlagsNotChanged(state,... | {
"fields": [
{
"declarator": "REG_A = 0",
"modifier": "public static final",
"original_string": "public static final int REG_A = 0;",
"type": "int",
"var_name": "REG_A"
},
{
"declarator": "REG_F = 1",
"modifier": "public static final",
"original_string": "p... | {
"body": "public int getRegister(final int reg) {\n return this.getRegister(reg, false);\n }",
"class_method_signature": "Z80.getRegister(final int reg)",
"constructor": false,
"full_signature": "public int getRegister(final int reg)",
"identifier": "getRegister",
"invocations": [
"getRegister"
]... | {
"created": null,
"fork": null,
"fork_count": 5,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 32104835,
"size": 23159,
"stargazer_count": 44,
"stars": null,
"updates": null,
"url": "https://github.com/raydac/zxpoly"
} |
32104835_135 | {
"fields": [],
"file": "zxpoly-z80/src/test/java/com/igormaznitsa/z80/Z80Test.java",
"identifier": "Z80Test",
"interfaces": "",
"superclass": "extends AbstractZ80Test"
} | {
"body": "@Test\n public void testCommand_RLCA() {\n final Z80State state = new Z80State();\n state.A = 0x88;\n state.F = 0x00;\n\n final Pair<Z80, Integer> cpu = executeCommand(state, 0x07);\n\n assertEquals(0x11, cpu.getLeft().getRegister(Z80.REG_A));\n assertEquals(Z80.FLAG_C, cpu.getLeft().get... | {
"fields": [
{
"declarator": "REG_A = 0",
"modifier": "public static final",
"original_string": "public static final int REG_A = 0;",
"type": "int",
"var_name": "REG_A"
},
{
"declarator": "REG_F = 1",
"modifier": "public static final",
"original_string": "p... | {
"body": "public int getRegister(final int reg) {\n return this.getRegister(reg, false);\n }",
"class_method_signature": "Z80.getRegister(final int reg)",
"constructor": false,
"full_signature": "public int getRegister(final int reg)",
"identifier": "getRegister",
"invocations": [
"getRegister"
]... | {
"created": null,
"fork": null,
"fork_count": 5,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 32104835,
"size": 23159,
"stargazer_count": 44,
"stars": null,
"updates": null,
"url": "https://github.com/raydac/zxpoly"
} |
32104835_58 | {
"fields": [],
"file": "zxpoly-z80/src/test/java/com/igormaznitsa/z80/Z80Test.java",
"identifier": "Z80Test",
"interfaces": "",
"superclass": "extends AbstractZ80Test"
} | {
"body": "@Test\n public void testCommand_ADD_mHL_flagV() {\n final Z80State state = new Z80State();\n state.A = 0x44;\n\n state.F = 0xFF;\n state.H = 0x12;\n state.L = 0x34;\n\n memory[0x1234] = (byte) 0x7F;\n\n final Pair<Z80, Integer> cpu = executeCommand(state, 0x86);\n\n assertEquals(0x... | {
"fields": [
{
"declarator": "REG_A = 0",
"modifier": "public static final",
"original_string": "public static final int REG_A = 0;",
"type": "int",
"var_name": "REG_A"
},
{
"declarator": "REG_F = 1",
"modifier": "public static final",
"original_string": "p... | {
"body": "public int getRegister(final int reg) {\n return this.getRegister(reg, false);\n }",
"class_method_signature": "Z80.getRegister(final int reg)",
"constructor": false,
"full_signature": "public int getRegister(final int reg)",
"identifier": "getRegister",
"invocations": [
"getRegister"
]... | {
"created": null,
"fork": null,
"fork_count": 5,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 32104835,
"size": 23159,
"stargazer_count": 44,
"stars": null,
"updates": null,
"url": "https://github.com/raydac/zxpoly"
} |
32104835_162 | {
"fields": [],
"file": "zxpoly-z80/src/test/java/com/igormaznitsa/z80/Z80Test.java",
"identifier": "Z80Test",
"interfaces": "",
"superclass": "extends AbstractZ80Test"
} | {
"body": "@Test\n public void testCommand_SLL_mIXd() {\n final Z80State state = new Z80State();\n state.IX = 0x1234;\n state.F = 0x00;\n\n memory[0x1239] = (byte) 0xB1;\n\n final Pair<Z80, Integer> cpu = executeCommand(state, 0xDD, 0xCB, 0x05, 0x36);\n\n assertMemory(0x1239, 0x63);\n assertFlag... | {
"fields": [
{
"declarator": "REG_A = 0",
"modifier": "public static final",
"original_string": "public static final int REG_A = 0;",
"type": "int",
"var_name": "REG_A"
},
{
"declarator": "REG_F = 1",
"modifier": "public static final",
"original_string": "p... | {
"body": "public int getRegister(final int reg) {\n return this.getRegister(reg, false);\n }",
"class_method_signature": "Z80.getRegister(final int reg)",
"constructor": false,
"full_signature": "public int getRegister(final int reg)",
"identifier": "getRegister",
"invocations": [
"getRegister"
]... | {
"created": null,
"fork": null,
"fork_count": 5,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 32104835,
"size": 23159,
"stargazer_count": 44,
"stars": null,
"updates": null,
"url": "https://github.com/raydac/zxpoly"
} |
32104835_174 | {
"fields": [],
"file": "zxpoly-z80/src/test/java/com/igormaznitsa/z80/Z80Test.java",
"identifier": "Z80Test",
"interfaces": "",
"superclass": "extends AbstractZ80Test"
} | {
"body": "@Test\n public void testCommand_BIT_2_reg() {\n final int[] codes = new int[] {0x50, 0x51, 0x52, 0x53, 0x54, 0x55, 0x57};\n final int[] regs =\n new int[] {Z80.REG_B, Z80.REG_C, Z80.REG_D, Z80.REG_E, Z80.REG_H, Z80.REG_L, Z80.REG_A};\n for (int i = 0; i < codes.length; i++) {\n final ... | {
"fields": [
{
"declarator": "REG_A = 0",
"modifier": "public static final",
"original_string": "public static final int REG_A = 0;",
"type": "int",
"var_name": "REG_A"
},
{
"declarator": "REG_F = 1",
"modifier": "public static final",
"original_string": "p... | {
"body": "public int getRegister(final int reg) {\n return this.getRegister(reg, false);\n }",
"class_method_signature": "Z80.getRegister(final int reg)",
"constructor": false,
"full_signature": "public int getRegister(final int reg)",
"identifier": "getRegister",
"invocations": [
"getRegister"
]... | {
"created": null,
"fork": null,
"fork_count": 5,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 32104835,
"size": 23159,
"stargazer_count": 44,
"stars": null,
"updates": null,
"url": "https://github.com/raydac/zxpoly"
} |
32104835_19 | {
"fields": [],
"file": "zxpoly-z80/src/test/java/com/igormaznitsa/z80/Z80Test.java",
"identifier": "Z80Test",
"interfaces": "",
"superclass": "extends AbstractZ80Test"
} | {
"body": "@Test\n public void testCommand_LD_A_mDE() {\n final Z80State state = new Z80State();\n state.A = 0x48;\n state.D = 0x12;\n state.E = 0x34;\n this.memory[0x1234] = 0x33;\n final Pair<Z80, Integer> cpu = executeCommand(state, 0x1A);\n assertEquals(0x33, cpu.getLeft().getRegister(Z80.RE... | {
"fields": [
{
"declarator": "REG_A = 0",
"modifier": "public static final",
"original_string": "public static final int REG_A = 0;",
"type": "int",
"var_name": "REG_A"
},
{
"declarator": "REG_F = 1",
"modifier": "public static final",
"original_string": "p... | {
"body": "public int getRegister(final int reg) {\n return this.getRegister(reg, false);\n }",
"class_method_signature": "Z80.getRegister(final int reg)",
"constructor": false,
"full_signature": "public int getRegister(final int reg)",
"identifier": "getRegister",
"invocations": [
"getRegister"
]... | {
"created": null,
"fork": null,
"fork_count": 5,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 32104835,
"size": 23159,
"stargazer_count": 44,
"stars": null,
"updates": null,
"url": "https://github.com/raydac/zxpoly"
} |
32104835_123 | {
"fields": [],
"file": "zxpoly-z80/src/test/java/com/igormaznitsa/z80/Z80Test.java",
"identifier": "Z80Test",
"interfaces": "",
"superclass": "extends AbstractZ80Test"
} | {
"body": "@Test\n public void testCommand_INC_IYh() {\n final Z80State state = new Z80State();\n state.IY = 0x1000;\n state.F = 0xFF;\n\n final Pair<Z80, Integer> cpu = executeCommand(state, 0xFD, 0x24);\n\n assertEquals(0x1100, cpu.getLeft().getRegister(Z80.REG_IY));\n assertEquals(8, cpu.getRigh... | {
"fields": [
{
"declarator": "REG_A = 0",
"modifier": "public static final",
"original_string": "public static final int REG_A = 0;",
"type": "int",
"var_name": "REG_A"
},
{
"declarator": "REG_F = 1",
"modifier": "public static final",
"original_string": "p... | {
"body": "public int getRegister(final int reg) {\n return this.getRegister(reg, false);\n }",
"class_method_signature": "Z80.getRegister(final int reg)",
"constructor": false,
"full_signature": "public int getRegister(final int reg)",
"identifier": "getRegister",
"invocations": [
"getRegister"
]... | {
"created": null,
"fork": null,
"fork_count": 5,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 32104835,
"size": 23159,
"stargazer_count": 44,
"stars": null,
"updates": null,
"url": "https://github.com/raydac/zxpoly"
} |
32104835_158 | {
"fields": [],
"file": "zxpoly-z80/src/test/java/com/igormaznitsa/z80/Z80Test.java",
"identifier": "Z80Test",
"interfaces": "",
"superclass": "extends AbstractZ80Test"
} | {
"body": "@Test\n public void testCommand_SLA_mIXd() {\n final Z80State state = new Z80State();\n state.IX = 0x1234;\n state.F = 0x00;\n\n memory[0x1239] = (byte) 0xB1;\n\n final Pair<Z80, Integer> cpu = executeCommand(state, 0xDD, 0xCB, 0x05, 0x26);\n\n assertMemory(0x1239, 0x62);\n assertFlag... | {
"fields": [
{
"declarator": "REG_A = 0",
"modifier": "public static final",
"original_string": "public static final int REG_A = 0;",
"type": "int",
"var_name": "REG_A"
},
{
"declarator": "REG_F = 1",
"modifier": "public static final",
"original_string": "p... | {
"body": "public int getRegister(final int reg) {\n return this.getRegister(reg, false);\n }",
"class_method_signature": "Z80.getRegister(final int reg)",
"constructor": false,
"full_signature": "public int getRegister(final int reg)",
"identifier": "getRegister",
"invocations": [
"getRegister"
]... | {
"created": null,
"fork": null,
"fork_count": 5,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 32104835,
"size": 23159,
"stargazer_count": 44,
"stars": null,
"updates": null,
"url": "https://github.com/raydac/zxpoly"
} |
32104835_35 | {
"fields": [],
"file": "zxpoly-z80/src/test/java/com/igormaznitsa/z80/Z80Test.java",
"identifier": "Z80Test",
"interfaces": "",
"superclass": "extends AbstractZ80Test"
} | {
"body": "@Test\n public void testCommand_LD_IX_nn() {\n final Z80State state = new Z80State();\n final Pair<Z80, Integer> cpu = executeCommand(state, 0xDD, 0x21, 0x34, 0x12);\n assertEquals(0x1234, cpu.getLeft().getRegister(Z80.REG_IX));\n assertFlagsNotChanged(state, cpu.getLeft());\n assertEquals(... | {
"fields": [
{
"declarator": "REG_A = 0",
"modifier": "public static final",
"original_string": "public static final int REG_A = 0;",
"type": "int",
"var_name": "REG_A"
},
{
"declarator": "REG_F = 1",
"modifier": "public static final",
"original_string": "p... | {
"body": "public int getRegister(final int reg) {\n return this.getRegister(reg, false);\n }",
"class_method_signature": "Z80.getRegister(final int reg)",
"constructor": false,
"full_signature": "public int getRegister(final int reg)",
"identifier": "getRegister",
"invocations": [
"getRegister"
]... | {
"created": null,
"fork": null,
"fork_count": 5,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 32104835,
"size": 23159,
"stargazer_count": 44,
"stars": null,
"updates": null,
"url": "https://github.com/raydac/zxpoly"
} |
32104835_226 | {
"fields": [],
"file": "zxpoly-z80/src/test/java/com/igormaznitsa/z80/Z80Test.java",
"identifier": "Z80Test",
"interfaces": "",
"superclass": "extends AbstractZ80Test"
} | {
"body": "@Test\n public void testCommand_LD_IXh_D() {\n final Z80State state = new Z80State();\n state.D = 0xDD;\n final Pair<Z80, Integer> cpu = executeCommand(state, 0xDD, 0x62);\n assertEquals(0xDD00, cpu.getLeft().getRegister(Z80.REG_IX));\n assertFlagsNotChanged(state, cpu.getLeft());\n asse... | {
"fields": [
{
"declarator": "REG_A = 0",
"modifier": "public static final",
"original_string": "public static final int REG_A = 0;",
"type": "int",
"var_name": "REG_A"
},
{
"declarator": "REG_F = 1",
"modifier": "public static final",
"original_string": "p... | {
"body": "public int getRegister(final int reg) {\n return this.getRegister(reg, false);\n }",
"class_method_signature": "Z80.getRegister(final int reg)",
"constructor": false,
"full_signature": "public int getRegister(final int reg)",
"identifier": "getRegister",
"invocations": [
"getRegister"
]... | {
"created": null,
"fork": null,
"fork_count": 5,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 32104835,
"size": 23159,
"stargazer_count": 44,
"stars": null,
"updates": null,
"url": "https://github.com/raydac/zxpoly"
} |
32104835_62 | {
"fields": [],
"file": "zxpoly-z80/src/test/java/com/igormaznitsa/z80/Z80Test.java",
"identifier": "Z80Test",
"interfaces": "",
"superclass": "extends AbstractZ80Test"
} | {
"body": "@Test\n public void testCommand_ADC_C_notFlagSet() {\n final Z80State state = new Z80State();\n state.A = 0x44;\n state.C = 0x11;\n\n state.F = 0xFF;\n\n final Pair<Z80, Integer> cpu = executeCommand(state, 0x89);\n\n assertEquals(0x11, cpu.getLeft().getRegister(Z80.REG_C));\n assertE... | {
"fields": [
{
"declarator": "REG_A = 0",
"modifier": "public static final",
"original_string": "public static final int REG_A = 0;",
"type": "int",
"var_name": "REG_A"
},
{
"declarator": "REG_F = 1",
"modifier": "public static final",
"original_string": "p... | {
"body": "public int getRegister(final int reg) {\n return this.getRegister(reg, false);\n }",
"class_method_signature": "Z80.getRegister(final int reg)",
"constructor": false,
"full_signature": "public int getRegister(final int reg)",
"identifier": "getRegister",
"invocations": [
"getRegister"
]... | {
"created": null,
"fork": null,
"fork_count": 5,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 32104835,
"size": 23159,
"stargazer_count": 44,
"stars": null,
"updates": null,
"url": "https://github.com/raydac/zxpoly"
} |
32104835_119 | {
"fields": [],
"file": "zxpoly-z80/src/test/java/com/igormaznitsa/z80/Z80Test.java",
"identifier": "Z80Test",
"interfaces": "",
"superclass": "extends AbstractZ80Test"
} | {
"body": "@Test\n public void testCommand_INC_HL() {\n final Z80State state = new Z80State();\n state.H = 0x10;\n state.L = 0x00;\n state.F = 0xFF;\n\n final Pair<Z80, Integer> cpu = executeCommand(state, 0x23);\n\n assertEquals(0x1001, cpu.getLeft().getRegisterPair(Z80.REGPAIR_HL));\n assertFl... | {
"fields": [
{
"declarator": "REG_A = 0",
"modifier": "public static final",
"original_string": "public static final int REG_A = 0;",
"type": "int",
"var_name": "REG_A"
},
{
"declarator": "REG_F = 1",
"modifier": "public static final",
"original_string": "p... | {
"body": "public int getRegisterPair(final int regPair) {\n return this.getRegisterPair(regPair, false);\n }",
"class_method_signature": "Z80.getRegisterPair(final int regPair)",
"constructor": false,
"full_signature": "public int getRegisterPair(final int regPair)",
"identifier": "getRegisterPair",
"i... | {
"created": null,
"fork": null,
"fork_count": 5,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 32104835,
"size": 23159,
"stargazer_count": 44,
"stars": null,
"updates": null,
"url": "https://github.com/raydac/zxpoly"
} |
32104835_74 | {
"fields": [],
"file": "zxpoly-z80/src/test/java/com/igormaznitsa/z80/Z80Test.java",
"identifier": "Z80Test",
"interfaces": "",
"superclass": "extends AbstractZ80Test"
} | {
"body": "@Test\n public void testCommand_SBC_C() {\n final Z80State state = new Z80State();\n state.A = 0x29;\n state.C = 0x11;\n\n state.F = 0xFF;\n\n final Pair<Z80, Integer> cpu = executeCommand(state, 0x99);\n\n assertEquals(0x11, cpu.getLeft().getRegister(Z80.REG_C));\n assertEquals(0x17,... | {
"fields": [
{
"declarator": "REG_A = 0",
"modifier": "public static final",
"original_string": "public static final int REG_A = 0;",
"type": "int",
"var_name": "REG_A"
},
{
"declarator": "REG_F = 1",
"modifier": "public static final",
"original_string": "p... | {
"body": "public int getRegister(final int reg) {\n return this.getRegister(reg, false);\n }",
"class_method_signature": "Z80.getRegister(final int reg)",
"constructor": false,
"full_signature": "public int getRegister(final int reg)",
"identifier": "getRegister",
"invocations": [
"getRegister"
]... | {
"created": null,
"fork": null,
"fork_count": 5,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 32104835,
"size": 23159,
"stargazer_count": 44,
"stars": null,
"updates": null,
"url": "https://github.com/raydac/zxpoly"
} |
32104835_230 | {
"fields": [],
"file": "zxpoly-z80/src/test/java/com/igormaznitsa/z80/Z80Test.java",
"identifier": "Z80Test",
"interfaces": "",
"superclass": "extends AbstractZ80Test"
} | {
"body": "@Test\n public void testCommand_LD_IYl_nn() {\n final Z80State state = new Z80State();\n state.IY = 0xFFFF;\n final Pair<Z80, Integer> cpu = executeCommand(state, 0xFD, 0x2E, 0x12);\n assertEquals(0xFF12, cpu.getLeft().getRegister(Z80.REG_IY));\n assertFlagsNotChanged(state, cpu.getLeft());... | {
"fields": [
{
"declarator": "REG_A = 0",
"modifier": "public static final",
"original_string": "public static final int REG_A = 0;",
"type": "int",
"var_name": "REG_A"
},
{
"declarator": "REG_F = 1",
"modifier": "public static final",
"original_string": "p... | {
"body": "public int getRegister(final int reg) {\n return this.getRegister(reg, false);\n }",
"class_method_signature": "Z80.getRegister(final int reg)",
"constructor": false,
"full_signature": "public int getRegister(final int reg)",
"identifier": "getRegister",
"invocations": [
"getRegister"
]... | {
"created": null,
"fork": null,
"fork_count": 5,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 32104835,
"size": 23159,
"stargazer_count": 44,
"stars": null,
"updates": null,
"url": "https://github.com/raydac/zxpoly"
} |
32104835_23 | {
"fields": [],
"file": "zxpoly-z80/src/test/java/com/igormaznitsa/z80/Z80Test.java",
"identifier": "Z80Test",
"interfaces": "",
"superclass": "extends AbstractZ80Test"
} | {
"body": "@Test\n public void testCommand_LD_mNN_A() {\n final Z80State state = new Z80State();\n state.A = 0x48;\n state.D = 0x12;\n state.E = 0x34;\n this.memory[0x1234] = 0x33;\n final Pair<Z80, Integer> cpu = executeCommand(state, 0x32, 0x34, 0x12);\n assertEquals(0x48, cpu.getLeft().getReg... | {
"fields": [
{
"declarator": "REG_A = 0",
"modifier": "public static final",
"original_string": "public static final int REG_A = 0;",
"type": "int",
"var_name": "REG_A"
},
{
"declarator": "REG_F = 1",
"modifier": "public static final",
"original_string": "p... | {
"body": "public int getRegister(final int reg) {\n return this.getRegister(reg, false);\n }",
"class_method_signature": "Z80.getRegister(final int reg)",
"constructor": false,
"full_signature": "public int getRegister(final int reg)",
"identifier": "getRegister",
"invocations": [
"getRegister"
]... | {
"created": null,
"fork": null,
"fork_count": 5,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 32104835,
"size": 23159,
"stargazer_count": 44,
"stars": null,
"updates": null,
"url": "https://github.com/raydac/zxpoly"
} |
32104835_54 | {
"fields": [],
"file": "zxpoly-z80/src/test/java/com/igormaznitsa/z80/Z80Test.java",
"identifier": "Z80Test",
"interfaces": "",
"superclass": "extends AbstractZ80Test"
} | {
"body": "@Test\n public void testCommand_EXX() {\n final Z80State state = new Z80State();\n state.A = 1;\n state.F = 3;\n state.B = 0x10;\n state.C = 0x20;\n state.D = 0x30;\n state.E = 0x40;\n state.H = 0x50;\n state.L = 0x60;\n state.IX = 0x61;\n state.IY = 0x62;\n state.WZ = ... | {
"fields": [
{
"declarator": "REG_A = 0",
"modifier": "public static final",
"original_string": "public static final int REG_A = 0;",
"type": "int",
"var_name": "REG_A"
},
{
"declarator": "REG_F = 1",
"modifier": "public static final",
"original_string": "p... | {
"body": "public int getRegister(final int reg) {\n return this.getRegister(reg, false);\n }",
"class_method_signature": "Z80.getRegister(final int reg)",
"constructor": false,
"full_signature": "public int getRegister(final int reg)",
"identifier": "getRegister",
"invocations": [
"getRegister"
]... | {
"created": null,
"fork": null,
"fork_count": 5,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 32104835,
"size": 23159,
"stargazer_count": 44,
"stars": null,
"updates": null,
"url": "https://github.com/raydac/zxpoly"
} |
32104835_210 | {
"fields": [],
"file": "zxpoly-z80/src/test/java/com/igormaznitsa/z80/Z80Test.java",
"identifier": "Z80Test",
"interfaces": "",
"superclass": "extends AbstractZ80Test"
} | {
"body": "@Test\n public void testCommand_JP_rHL() {\n final Z80State state = new Z80State();\n\n state.H = 0x12;\n state.L = 0x34;\n\n final Pair<Z80, Integer> cpu = executeCommand(state, false, 0xE9);\n\n assertEquals(0x1234, cpu.getLeft().getRegister(Z80.REG_PC));\n assertFlagsNotChanged(state,... | {
"fields": [
{
"declarator": "REG_A = 0",
"modifier": "public static final",
"original_string": "public static final int REG_A = 0;",
"type": "int",
"var_name": "REG_A"
},
{
"declarator": "REG_F = 1",
"modifier": "public static final",
"original_string": "p... | {
"body": "public int getRegister(final int reg) {\n return this.getRegister(reg, false);\n }",
"class_method_signature": "Z80.getRegister(final int reg)",
"constructor": false,
"full_signature": "public int getRegister(final int reg)",
"identifier": "getRegister",
"invocations": [
"getRegister"
]... | {
"created": null,
"fork": null,
"fork_count": 5,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 32104835,
"size": 23159,
"stargazer_count": 44,
"stars": null,
"updates": null,
"url": "https://github.com/raydac/zxpoly"
} |
32104835_139 | {
"fields": [],
"file": "zxpoly-z80/src/test/java/com/igormaznitsa/z80/Z80Test.java",
"identifier": "Z80Test",
"interfaces": "",
"superclass": "extends AbstractZ80Test"
} | {
"body": "@Test\n public void testCommand_RLC_r() {\n final int[] codes = new int[] {0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x07};\n final int[] regs =\n new int[] {Z80.REG_B, Z80.REG_C, Z80.REG_D, Z80.REG_E, Z80.REG_H, Z80.REG_L, Z80.REG_A};\n for (int i = 0; i < codes.length; i++) {\n final Z80S... | {
"fields": [
{
"declarator": "REG_A = 0",
"modifier": "public static final",
"original_string": "public static final int REG_A = 0;",
"type": "int",
"var_name": "REG_A"
},
{
"declarator": "REG_F = 1",
"modifier": "public static final",
"original_string": "p... | {
"body": "public int getRegister(final int reg) {\n return this.getRegister(reg, false);\n }",
"class_method_signature": "Z80.getRegister(final int reg)",
"constructor": false,
"full_signature": "public int getRegister(final int reg)",
"identifier": "getRegister",
"invocations": [
"getRegister"
]... | {
"created": null,
"fork": null,
"fork_count": 5,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 32104835,
"size": 23159,
"stargazer_count": 44,
"stars": null,
"updates": null,
"url": "https://github.com/raydac/zxpoly"
} |
32104835_181 | {
"fields": [],
"file": "zxpoly-z80/src/test/java/com/igormaznitsa/z80/Z80Test.java",
"identifier": "Z80Test",
"interfaces": "",
"superclass": "extends AbstractZ80Test"
} | {
"body": "@Test\n public void testCommand_IM0() {\n final Z80State state = new Z80State();\n final Pair<Z80, Integer> cpu = executeCommand(state, 0xED, 0x46);\n\n assertEquals(0, cpu.getLeft().getIM());\n\n assertEquals(8, cpu.getRight().intValue());\n assertFlagsNotChanged(state, cpu.getLeft());\n ... | {
"fields": [
{
"declarator": "REG_A = 0",
"modifier": "public static final",
"original_string": "public static final int REG_A = 0;",
"type": "int",
"var_name": "REG_A"
},
{
"declarator": "REG_F = 1",
"modifier": "public static final",
"original_string": "p... | {
"body": "public int getIM() {\n return this.im;\n }",
"class_method_signature": "Z80.getIM()",
"constructor": false,
"full_signature": "public int getIM()",
"identifier": "getIM",
"invocations": [],
"modifiers": "public",
"parameters": "()",
"return": "int",
"signature": "int getIM()",
"test... | {
"created": null,
"fork": null,
"fork_count": 5,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 32104835,
"size": 23159,
"stargazer_count": 44,
"stars": null,
"updates": null,
"url": "https://github.com/raydac/zxpoly"
} |
32104835_15 | {
"fields": [],
"file": "zxpoly-z80/src/test/java/com/igormaznitsa/z80/Z80Test.java",
"identifier": "Z80Test",
"interfaces": "",
"superclass": "extends AbstractZ80Test"
} | {
"body": "@Test\n public void testCommand_LD_mIXd_A() {\n final Z80State state = new Z80State();\n state.A = 0x48;\n state.IX = 0x1234;\n this.memory[0x1239] = 0x33;\n final Pair<Z80, Integer> cpu = executeCommand(state, 0xDD, 0x77, 5);\n assertEquals(0x48, cpu.getLeft().getRegister(Z80.REG_A));\n... | {
"fields": [
{
"declarator": "REG_A = 0",
"modifier": "public static final",
"original_string": "public static final int REG_A = 0;",
"type": "int",
"var_name": "REG_A"
},
{
"declarator": "REG_F = 1",
"modifier": "public static final",
"original_string": "p... | {
"body": "public int getRegister(final int reg) {\n return this.getRegister(reg, false);\n }",
"class_method_signature": "Z80.getRegister(final int reg)",
"constructor": false,
"full_signature": "public int getRegister(final int reg)",
"identifier": "getRegister",
"invocations": [
"getRegister"
]... | {
"created": null,
"fork": null,
"fork_count": 5,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 32104835,
"size": 23159,
"stargazer_count": 44,
"stars": null,
"updates": null,
"url": "https://github.com/raydac/zxpoly"
} |
32104835_197 | {
"fields": [],
"file": "zxpoly-z80/src/test/java/com/igormaznitsa/z80/Z80Test.java",
"identifier": "Z80Test",
"interfaces": "",
"superclass": "extends AbstractZ80Test"
} | {
"body": "@Test\n public void testCommand_JP_P_nn_false() {\n final Z80State state = new Z80State();\n state.F = Z80.FLAG_S;\n\n final Pair<Z80, Integer> cpu = executeCommand(state, false, 0xF2, 0x34, 0x12);\n\n assertEquals(0x0003, cpu.getLeft().getRegister(Z80.REG_PC));\n assertFlagsNotChanged(stat... | {
"fields": [
{
"declarator": "REG_A = 0",
"modifier": "public static final",
"original_string": "public static final int REG_A = 0;",
"type": "int",
"var_name": "REG_A"
},
{
"declarator": "REG_F = 1",
"modifier": "public static final",
"original_string": "p... | {
"body": "public int getRegister(final int reg) {\n return this.getRegister(reg, false);\n }",
"class_method_signature": "Z80.getRegister(final int reg)",
"constructor": false,
"full_signature": "public int getRegister(final int reg)",
"identifier": "getRegister",
"invocations": [
"getRegister"
]... | {
"created": null,
"fork": null,
"fork_count": 5,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 32104835,
"size": 23159,
"stargazer_count": 44,
"stars": null,
"updates": null,
"url": "https://github.com/raydac/zxpoly"
} |
32104835_178 | {
"fields": [],
"file": "zxpoly-z80/src/test/java/com/igormaznitsa/z80/Z80Test.java",
"identifier": "Z80Test",
"interfaces": "",
"superclass": "extends AbstractZ80Test"
} | {
"body": "@Test\n public void testCommand_BIT_2_mIYd() {\n final Z80State state = new Z80State();\n state.IY = 0x5000;\n\n this.memory[0x5010] = (byte) 4;\n\n state.F = 0x00;\n\n final Pair<Z80, Integer> cpu = executeCommand(state, 0xFD, 0xCB, 0x10, 0x56);\n\n assertEquals(Z80.FLAG_H, cpu.getLeft(... | {
"fields": [
{
"declarator": "REG_A = 0",
"modifier": "public static final",
"original_string": "public static final int REG_A = 0;",
"type": "int",
"var_name": "REG_A"
},
{
"declarator": "REG_F = 1",
"modifier": "public static final",
"original_string": "p... | {
"body": "public int getRegister(final int reg) {\n return this.getRegister(reg, false);\n }",
"class_method_signature": "Z80.getRegister(final int reg)",
"constructor": false,
"full_signature": "public int getRegister(final int reg)",
"identifier": "getRegister",
"invocations": [
"getRegister"
]... | {
"created": null,
"fork": null,
"fork_count": 5,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 32104835,
"size": 23159,
"stargazer_count": 44,
"stars": null,
"updates": null,
"url": "https://github.com/raydac/zxpoly"
} |
32104835_206 | {
"fields": [],
"file": "zxpoly-z80/src/test/java/com/igormaznitsa/z80/Z80Test.java",
"identifier": "Z80Test",
"interfaces": "",
"superclass": "extends AbstractZ80Test"
} | {
"body": "@Test\n public void testCommand_JR_NC_nn_false() {\n final Z80State state = new Z80State();\n state.F = Z80.FLAG_C;\n\n final Pair<Z80, Integer> cpu = executeCommand(state, false, 0x30, 0x03);\n\n assertEquals(0x0002, cpu.getLeft().getRegister(Z80.REG_PC));\n assertFlagsNotChanged(state, cp... | {
"fields": [
{
"declarator": "REG_A = 0",
"modifier": "public static final",
"original_string": "public static final int REG_A = 0;",
"type": "int",
"var_name": "REG_A"
},
{
"declarator": "REG_F = 1",
"modifier": "public static final",
"original_string": "p... | {
"body": "public int getRegister(final int reg) {\n return this.getRegister(reg, false);\n }",
"class_method_signature": "Z80.getRegister(final int reg)",
"constructor": false,
"full_signature": "public int getRegister(final int reg)",
"identifier": "getRegister",
"invocations": [
"getRegister"
]... | {
"created": null,
"fork": null,
"fork_count": 5,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 32104835,
"size": 23159,
"stargazer_count": 44,
"stars": null,
"updates": null,
"url": "https://github.com/raydac/zxpoly"
} |
32104835_42 | {
"fields": [],
"file": "zxpoly-z80/src/test/java/com/igormaznitsa/z80/Z80Test.java",
"identifier": "Z80Test",
"interfaces": "",
"superclass": "extends AbstractZ80Test"
} | {
"body": "@Test\n public void testCommand_PUSH_BC() {\n final Z80State state = new Z80State();\n state.B = 0x22;\n state.C = 0x33;\n state.SP = 0x1007;\n final Pair<Z80, Integer> cpu = executeCommand(state, 0xC5);\n assertEquals(0x1005, cpu.getLeft().getRegister(Z80.REG_SP));\n assertMemory(0x1... | {
"fields": [
{
"declarator": "REG_A = 0",
"modifier": "public static final",
"original_string": "public static final int REG_A = 0;",
"type": "int",
"var_name": "REG_A"
},
{
"declarator": "REG_F = 1",
"modifier": "public static final",
"original_string": "p... | {
"body": "public int getRegister(final int reg) {\n return this.getRegister(reg, false);\n }",
"class_method_signature": "Z80.getRegister(final int reg)",
"constructor": false,
"full_signature": "public int getRegister(final int reg)",
"identifier": "getRegister",
"invocations": [
"getRegister"
]... | {
"created": null,
"fork": null,
"fork_count": 5,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 32104835,
"size": 23159,
"stargazer_count": 44,
"stars": null,
"updates": null,
"url": "https://github.com/raydac/zxpoly"
} |
32104835_39 | {
"fields": [],
"file": "zxpoly-z80/src/test/java/com/igormaznitsa/z80/Z80Test.java",
"identifier": "Z80Test",
"interfaces": "",
"superclass": "extends AbstractZ80Test"
} | {
"body": "@Test\n public void testCommand_LD_HL_mNN() {\n final Z80State state = new Z80State();\n this.memory[0x1234] = (byte) 0xAA;\n this.memory[0x1235] = (byte) 0xBB;\n final Pair<Z80, Integer> cpu = executeCommand(state, 0xED, 0x6B, 0x34, 0x12);\n assertEquals(0xBBAA, cpu.getLeft().getRegisterPa... | {
"fields": [
{
"declarator": "REG_A = 0",
"modifier": "public static final",
"original_string": "public static final int REG_A = 0;",
"type": "int",
"var_name": "REG_A"
},
{
"declarator": "REG_F = 1",
"modifier": "public static final",
"original_string": "p... | {
"body": "public int getRegisterPair(final int regPair) {\n return this.getRegisterPair(regPair, false);\n }",
"class_method_signature": "Z80.getRegisterPair(final int regPair)",
"constructor": false,
"full_signature": "public int getRegisterPair(final int regPair)",
"identifier": "getRegisterPair",
"i... | {
"created": null,
"fork": null,
"fork_count": 5,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 32104835,
"size": 23159,
"stargazer_count": 44,
"stars": null,
"updates": null,
"url": "https://github.com/raydac/zxpoly"
} |
32104835_154 | {
"fields": [],
"file": "zxpoly-z80/src/test/java/com/igormaznitsa/z80/Z80Test.java",
"identifier": "Z80Test",
"interfaces": "",
"superclass": "extends AbstractZ80Test"
} | {
"body": "@Test\n public void testCommand_RR_mIYd() {\n final Z80State state = new Z80State();\n state.IY = 0x1234;\n state.F = 0x00;\n\n memory[0x1239] = (byte) 0xDD;\n\n final Pair<Z80, Integer> cpu = executeCommand(state, 0xFD, 0xCB, 0x05, 0x1E);\n\n assertMemory(0x1239, 0x6E);\n assertFlags... | {
"fields": [
{
"declarator": "REG_A = 0",
"modifier": "public static final",
"original_string": "public static final int REG_A = 0;",
"type": "int",
"var_name": "REG_A"
},
{
"declarator": "REG_F = 1",
"modifier": "public static final",
"original_string": "p... | {
"body": "public int getRegister(final int reg) {\n return this.getRegister(reg, false);\n }",
"class_method_signature": "Z80.getRegister(final int reg)",
"constructor": false,
"full_signature": "public int getRegister(final int reg)",
"identifier": "getRegister",
"invocations": [
"getRegister"
]... | {
"created": null,
"fork": null,
"fork_count": 5,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 32104835,
"size": 23159,
"stargazer_count": 44,
"stars": null,
"updates": null,
"url": "https://github.com/raydac/zxpoly"
} |
32104835_81 | {
"fields": [],
"file": "zxpoly-z80/src/test/java/com/igormaznitsa/z80/Z80Test.java",
"identifier": "Z80Test",
"interfaces": "",
"superclass": "extends AbstractZ80Test"
} | {
"body": "@Test\n public void testCommand_AND_C_ParityFalse() {\n final Z80State state = new Z80State();\n state.A = 0x07;\n state.C = 0x09;\n\n state.F = 0xFF;\n\n final Pair<Z80, Integer> cpu = executeCommand(state, 0xA1);\n\n assertEquals(0x09, cpu.getLeft().getRegister(Z80.REG_C));\n assert... | {
"fields": [
{
"declarator": "REG_A = 0",
"modifier": "public static final",
"original_string": "public static final int REG_A = 0;",
"type": "int",
"var_name": "REG_A"
},
{
"declarator": "REG_F = 1",
"modifier": "public static final",
"original_string": "p... | {
"body": "public int getRegister(final int reg) {\n return this.getRegister(reg, false);\n }",
"class_method_signature": "Z80.getRegister(final int reg)",
"constructor": false,
"full_signature": "public int getRegister(final int reg)",
"identifier": "getRegister",
"invocations": [
"getRegister"
]... | {
"created": null,
"fork": null,
"fork_count": 5,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 32104835,
"size": 23159,
"stargazer_count": 44,
"stars": null,
"updates": null,
"url": "https://github.com/raydac/zxpoly"
} |
32104835_103 | {
"fields": [],
"file": "zxpoly-z80/src/test/java/com/igormaznitsa/z80/Z80Test.java",
"identifier": "Z80Test",
"interfaces": "",
"superclass": "extends AbstractZ80Test"
} | {
"body": "@Test\n public void testCommand_CP_mHL() {\n final Z80State state = new Z80State();\n state.A = 0x29;\n\n state.L = 0x34;\n state.H = 0x12;\n memory[0x1234] = 0x11;\n\n state.F = 0xFF;\n\n final Pair<Z80, Integer> cpu = executeCommand(state, 0xBE);\n\n assertEquals(0x29, cpu.getLef... | {
"fields": [
{
"declarator": "REG_A = 0",
"modifier": "public static final",
"original_string": "public static final int REG_A = 0;",
"type": "int",
"var_name": "REG_A"
},
{
"declarator": "REG_F = 1",
"modifier": "public static final",
"original_string": "p... | {
"body": "public int getRegister(final int reg) {\n return this.getRegister(reg, false);\n }",
"class_method_signature": "Z80.getRegister(final int reg)",
"constructor": false,
"full_signature": "public int getRegister(final int reg)",
"identifier": "getRegister",
"invocations": [
"getRegister"
]... | {
"created": null,
"fork": null,
"fork_count": 5,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 32104835,
"size": 23159,
"stargazer_count": 44,
"stars": null,
"updates": null,
"url": "https://github.com/raydac/zxpoly"
} |
32104835_6 | {
"fields": [],
"file": "zxpoly-z80/src/test/java/com/igormaznitsa/z80/Z80Test.java",
"identifier": "Z80Test",
"interfaces": "",
"superclass": "extends AbstractZ80Test"
} | {
"body": "@Test\n public void testCommand_LD_A_IXh() {\n final Z80State state = new Z80State();\n state.A = 0xFF;\n state.IX = 0x1234;\n final Pair<Z80, Integer> cpu = executeCommand(state, 0xDD, 0x7C);\n assertEquals(0x12, cpu.getLeft().getRegister(Z80.REG_A));\n assertEquals(0x1234, cpu.getLeft(... | {
"fields": [
{
"declarator": "REG_A = 0",
"modifier": "public static final",
"original_string": "public static final int REG_A = 0;",
"type": "int",
"var_name": "REG_A"
},
{
"declarator": "REG_F = 1",
"modifier": "public static final",
"original_string": "p... | {
"body": "public int getRegister(final int reg) {\n return this.getRegister(reg, false);\n }",
"class_method_signature": "Z80.getRegister(final int reg)",
"constructor": false,
"full_signature": "public int getRegister(final int reg)",
"identifier": "getRegister",
"invocations": [
"getRegister"
]... | {
"created": null,
"fork": null,
"fork_count": 5,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 32104835,
"size": 23159,
"stargazer_count": 44,
"stars": null,
"updates": null,
"url": "https://github.com/raydac/zxpoly"
} |
32104835_97 | {
"fields": [],
"file": "zxpoly-z80/src/test/java/com/igormaznitsa/z80/Z80Test.java",
"identifier": "Z80Test",
"interfaces": "",
"superclass": "extends AbstractZ80Test"
} | {
"body": "@Test\n public void testCommand_CP_C_More() {\n final Z80State state = new Z80State();\n state.A = 0xF7;\n state.C = 0xF8;\n\n state.F = 0xFF;\n\n final Pair<Z80, Integer> cpu = executeCommand(state, 0xB9);\n\n assertEquals(0xF8, cpu.getLeft().getRegister(Z80.REG_C));\n assertEquals(0... | {
"fields": [
{
"declarator": "REG_A = 0",
"modifier": "public static final",
"original_string": "public static final int REG_A = 0;",
"type": "int",
"var_name": "REG_A"
},
{
"declarator": "REG_F = 1",
"modifier": "public static final",
"original_string": "p... | {
"body": "public int getRegister(final int reg) {\n return this.getRegister(reg, false);\n }",
"class_method_signature": "Z80.getRegister(final int reg)",
"constructor": false,
"full_signature": "public int getRegister(final int reg)",
"identifier": "getRegister",
"invocations": [
"getRegister"
]... | {
"created": null,
"fork": null,
"fork_count": 5,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 32104835,
"size": 23159,
"stargazer_count": 44,
"stars": null,
"updates": null,
"url": "https://github.com/raydac/zxpoly"
} |
32104835_78 | {
"fields": [],
"file": "zxpoly-z80/src/test/java/com/igormaznitsa/z80/Z80Test.java",
"identifier": "Z80Test",
"interfaces": "",
"superclass": "extends AbstractZ80Test"
} | {
"body": "@Test\n public void testCommand_SBC_mIYd() {\n final Z80State state = new Z80State();\n state.A = 0x29;\n state.F = 0xFF;\n\n state.IY = 0x1234;\n\n memory[0x1237] = 0x11;\n\n final Pair<Z80, Integer> cpu = executeCommand(state, 0xFD, 0x9E, 0x03);\n\n assertEquals(0x17, cpu.getLeft().... | {
"fields": [
{
"declarator": "REG_A = 0",
"modifier": "public static final",
"original_string": "public static final int REG_A = 0;",
"type": "int",
"var_name": "REG_A"
},
{
"declarator": "REG_F = 1",
"modifier": "public static final",
"original_string": "p... | {
"body": "public int getRegister(final int reg) {\n return this.getRegister(reg, false);\n }",
"class_method_signature": "Z80.getRegister(final int reg)",
"constructor": false,
"full_signature": "public int getRegister(final int reg)",
"identifier": "getRegister",
"invocations": [
"getRegister"
]... | {
"created": null,
"fork": null,
"fork_count": 5,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 32104835,
"size": 23159,
"stargazer_count": 44,
"stars": null,
"updates": null,
"url": "https://github.com/raydac/zxpoly"
} |
32104835_115 | {
"fields": [],
"file": "zxpoly-z80/src/test/java/com/igormaznitsa/z80/Z80Test.java",
"identifier": "Z80Test",
"interfaces": "",
"superclass": "extends AbstractZ80Test"
} | {
"body": "@Test\n public void testCommand_INC_mIXd() {\n final Z80State state = new Z80State();\n state.IX = 0x2020;\n state.F = 0xFF;\n\n this.memory[0x2030] = 0x34;\n\n final Pair<Z80, Integer> cpu = executeCommand(state, 0xDD, 0x34, 0x10);\n\n assertEquals(0x2020, cpu.getLeft().getRegister(Z80.... | {
"fields": [
{
"declarator": "REG_A = 0",
"modifier": "public static final",
"original_string": "public static final int REG_A = 0;",
"type": "int",
"var_name": "REG_A"
},
{
"declarator": "REG_F = 1",
"modifier": "public static final",
"original_string": "p... | {
"body": "public int getRegister(final int reg) {\n return this.getRegister(reg, false);\n }",
"class_method_signature": "Z80.getRegister(final int reg)",
"constructor": false,
"full_signature": "public int getRegister(final int reg)",
"identifier": "getRegister",
"invocations": [
"getRegister"
]... | {
"created": null,
"fork": null,
"fork_count": 5,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 32104835,
"size": 23159,
"stargazer_count": 44,
"stars": null,
"updates": null,
"url": "https://github.com/raydac/zxpoly"
} |
32104835_142 | {
"fields": [],
"file": "zxpoly-z80/src/test/java/com/igormaznitsa/z80/Z80Test.java",
"identifier": "Z80Test",
"interfaces": "",
"superclass": "extends AbstractZ80Test"
} | {
"body": "@Test\n public void testCommand_RLC_mIYd() {\n final Z80State state = new Z80State();\n state.IY = 0x1234;\n state.F = 0x00;\n\n memory[0x1239] = (byte) 0x88;\n\n final Pair<Z80, Integer> cpu = executeCommand(state, 0xFD, 0xCB, 0x05, 0x06);\n\n assertMemory(0x1239, 0x11);\n assertEqua... | {
"fields": [
{
"declarator": "REG_A = 0",
"modifier": "public static final",
"original_string": "public static final int REG_A = 0;",
"type": "int",
"var_name": "REG_A"
},
{
"declarator": "REG_F = 1",
"modifier": "public static final",
"original_string": "p... | {
"body": "public int getRegister(final int reg) {\n return this.getRegister(reg, false);\n }",
"class_method_signature": "Z80.getRegister(final int reg)",
"constructor": false,
"full_signature": "public int getRegister(final int reg)",
"identifier": "getRegister",
"invocations": [
"getRegister"
]... | {
"created": null,
"fork": null,
"fork_count": 5,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 32104835,
"size": 23159,
"stargazer_count": 44,
"stars": null,
"updates": null,
"url": "https://github.com/raydac/zxpoly"
} |
61947614_6 | {
"fields": [
{
"declarator": "processorsService",
"modifier": "@Mock",
"original_string": "@Mock\n MessageProcessorsService processorsService;",
"type": "MessageProcessorsService",
"var_name": "processorsService"
},
{
"declarator": "messageProcessor",
"modifie... | {
"body": "@Test\n public void shouldProcessMessagesInCorrectOrder() {\n messageQueue.addMessage(stubPeer, MESSAGE_ID, 2, stubContent);\n messageQueue.addMessage(stubPeer, OTHER_MESSAGE_ID, 1, stubContent);\n\n InOrder inOrder = Mockito.inOrder(processorsService);\n inOrder.verify(proce... | {
"fields": [
{
"declarator": "minDependencyId = 1",
"modifier": "private",
"original_string": "private int minDependencyId = 1;",
"type": "int",
"var_name": "minDependencyId"
},
{
"declarator": "messageQueue = new PriorityQueue<>(new IncomingEnvelopeComparator())",
... | {
"body": "public synchronized void addMessage(Peer sourcePeer, int messageType, int dependencyId, ByteBuf content) {\n if (checkDependency(dependencyId)) {\n byte[] contentBytes = new byte[content.readableBytes()];\n content.readBytes(contentBytes);\n\n messageQueue.add(new In... | {
"created": null,
"fork": null,
"fork_count": 1,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 61947614,
"size": 243998,
"stargazer_count": 27,
"stars": null,
"updates": null,
"url": "https://github.com/WarpOrganization/warp"
} |
61947614_7 | {
"fields": [],
"file": "core/src/test/java/net/warpgame/engine/core/context/config/ConfigLoaderTest.java",
"identifier": "ConfigLoaderTest",
"interfaces": "",
"superclass": ""
} | {
"body": "@Test\n public void parseShouldReturnInteger() {\n Assert.assertSame(100, new ConfigLoader().parse(\"100\"));\n }",
"class_method_signature": "ConfigLoaderTest.parseShouldReturnInteger()",
"constructor": false,
"full_signature": "@Test public void parseShouldReturnInteger()",
"identifi... | {
"fields": [
{
"declarator": "logger = Logger.getLogger(ConfigLoader.class)",
"modifier": "private static final",
"original_string": "private static final Logger logger = Logger.getLogger(ConfigLoader.class);",
"type": "Logger",
"var_name": "logger"
},
{
"declarator": ... | {
"body": "Object parse(String o) { //lol\n Scanner s = new Scanner(o);\n if (s.hasNextInt()) return s.nextInt();\n if (s.hasNextFloat()) return s.nextFloat();\n if (s.hasNextBoolean()) return s.nextBoolean();\n return o;\n }",
"class_method_signature": "ConfigLoader.parse(Stri... | {
"created": null,
"fork": null,
"fork_count": 1,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 61947614,
"size": 243998,
"stargazer_count": 27,
"stars": null,
"updates": null,
"url": "https://github.com/WarpOrganization/warp"
} |
61947614_0 | {
"fields": [
{
"declarator": "context",
"modifier": "@Mock",
"original_string": "@Mock\n Context context;",
"type": "Context",
"var_name": "context"
},
{
"declarator": "holder",
"modifier": "@Mock",
"original_string": "@Mock\n SceneHolder holder;",
... | {
"body": "@Test\n public void sendChatMessageTest() {\n service.sendChatMessage(\"User\", \"Hello\");\n verify(service.consoleComponent).triggerEvent(any());\n }",
"class_method_signature": "ClientConsoleServiceTest.sendChatMessageTest()",
"constructor": false,
"full_signature": "@Test publ... | {
"fields": [],
"file": "console/src/main/java/net/warpgame/engine/console/ClientConsoleService.java",
"identifier": "ClientConsoleService",
"interfaces": "",
"methods": [
{
"class_method_signature": "ClientConsoleService.ClientConsoleService(SceneHolder holder, Context context)",
"constructor... | {
"body": "public void sendChatMessage(String sender, String msg) {\n consoleComponent.triggerEvent(new ChatMessageEvent(sender, msg));\n }",
"class_method_signature": "ClientConsoleService.sendChatMessage(String sender, String msg)",
"constructor": false,
"full_signature": "public void sendChatMessag... | {
"created": null,
"fork": null,
"fork_count": 1,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 61947614,
"size": 243998,
"stargazer_count": 27,
"stars": null,
"updates": null,
"url": "https://github.com/WarpOrganization/warp"
} |
61947614_1 | {
"fields": [
{
"declarator": "consumer",
"modifier": "@Mock",
"original_string": "@Mock\n Consumer<String[]> consumer;",
"type": "Consumer<String[]>",
"var_name": "consumer"
},
{
"declarator": "command",
"modifier": "private",
"original_string": "private... | {
"body": "@Test(expected = IllegalStateException.class)\n public void executeShouldThrowException() {\n command.execute(\"arg1\", \"arg2\");\n }",
"class_method_signature": "SimpleCommandTest.executeShouldThrowException()",
"constructor": false,
"full_signature": "@Test(expected = IllegalStateExce... | {
"fields": [
{
"declarator": "executor",
"modifier": "private",
"original_string": "private Consumer<String[]> executor;",
"type": "Consumer<String[]>",
"var_name": "executor"
}
],
"file": "console/src/main/java/net/warpgame/engine/console/command/SimpleCommand.java",
"ide... | {
"body": "@Override\n public void execute(String... args) {\n if (executor == null)\n throw new IllegalStateException(\"Executor not defined.\");\n\n executor.accept(args);\n }",
"class_method_signature": "SimpleCommand.execute(String... args)",
"constructor": false,
"full_signat... | {
"created": null,
"fork": null,
"fork_count": 1,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 61947614,
"size": 243998,
"stargazer_count": 27,
"stars": null,
"updates": null,
"url": "https://github.com/WarpOrganization/warp"
} |
61947614_2 | {
"fields": [
{
"declarator": "processorsService",
"modifier": "@Mock",
"original_string": "@Mock\n MessageProcessorsService processorsService;",
"type": "MessageProcessorsService",
"var_name": "processorsService"
},
{
"declarator": "messageProcessor",
"modifie... | {
"body": "@Test\n public void shouldProcessMessage() {\n messageQueue.addMessage(stubPeer, MESSAGE_ID, 1, stubContent);\n\n verify(messageProcessor, times(1)).processMessage(eq(stubPeer), any());\n }",
"class_method_signature": "IncomingMessageQueueTest.shouldProcessMessage()",
"constructor":... | {
"fields": [
{
"declarator": "minDependencyId = 1",
"modifier": "private",
"original_string": "private int minDependencyId = 1;",
"type": "int",
"var_name": "minDependencyId"
},
{
"declarator": "messageQueue = new PriorityQueue<>(new IncomingEnvelopeComparator())",
... | {
"body": "public synchronized void addMessage(Peer sourcePeer, int messageType, int dependencyId, ByteBuf content) {\n if (checkDependency(dependencyId)) {\n byte[] contentBytes = new byte[content.readableBytes()];\n content.readBytes(contentBytes);\n\n messageQueue.add(new In... | {
"created": null,
"fork": null,
"fork_count": 1,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 61947614,
"size": 243998,
"stargazer_count": 27,
"stars": null,
"updates": null,
"url": "https://github.com/WarpOrganization/warp"
} |
61947614_11 | {
"fields": [],
"file": "core/src/test/java/net/warpgame/engine/core/context/config/ConfigLoaderTest.java",
"identifier": "ConfigLoaderTest",
"interfaces": "",
"superclass": ""
} | {
"body": "@Test\n public void parseShouldReturnString() {\n Assert.assertSame(\"127.0.0.1\", new ConfigLoader().parse(\"127.0.0.1\"));\n }",
"class_method_signature": "ConfigLoaderTest.parseShouldReturnString()",
"constructor": false,
"full_signature": "@Test public void parseShouldReturnString()"... | {
"fields": [
{
"declarator": "logger = Logger.getLogger(ConfigLoader.class)",
"modifier": "private static final",
"original_string": "private static final Logger logger = Logger.getLogger(ConfigLoader.class);",
"type": "Logger",
"var_name": "logger"
},
{
"declarator": ... | {
"body": "Object parse(String o) { //lol\n Scanner s = new Scanner(o);\n if (s.hasNextInt()) return s.nextInt();\n if (s.hasNextFloat()) return s.nextFloat();\n if (s.hasNextBoolean()) return s.nextBoolean();\n return o;\n }",
"class_method_signature": "ConfigLoader.parse(Stri... | {
"created": null,
"fork": null,
"fork_count": 1,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 61947614,
"size": 243998,
"stargazer_count": 27,
"stars": null,
"updates": null,
"url": "https://github.com/WarpOrganization/warp"
} |
61947614_10 | {
"fields": [],
"file": "core/src/test/java/net/warpgame/engine/core/context/config/ConfigLoaderTest.java",
"identifier": "ConfigLoaderTest",
"interfaces": "",
"superclass": ""
} | {
"body": "@Test\n public void parseShouldReturnFalse() {\n Assert.assertSame(false, new ConfigLoader().parse(\"false\"));\n }",
"class_method_signature": "ConfigLoaderTest.parseShouldReturnFalse()",
"constructor": false,
"full_signature": "@Test public void parseShouldReturnFalse()",
"identifier... | {
"fields": [
{
"declarator": "logger = Logger.getLogger(ConfigLoader.class)",
"modifier": "private static final",
"original_string": "private static final Logger logger = Logger.getLogger(ConfigLoader.class);",
"type": "Logger",
"var_name": "logger"
},
{
"declarator": ... | {
"body": "Object parse(String o) { //lol\n Scanner s = new Scanner(o);\n if (s.hasNextInt()) return s.nextInt();\n if (s.hasNextFloat()) return s.nextFloat();\n if (s.hasNextBoolean()) return s.nextBoolean();\n return o;\n }",
"class_method_signature": "ConfigLoader.parse(Stri... | {
"created": null,
"fork": null,
"fork_count": 1,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 61947614,
"size": 243998,
"stargazer_count": 27,
"stars": null,
"updates": null,
"url": "https://github.com/WarpOrganization/warp"
} |
61947614_3 | {
"fields": [
{
"declarator": "processorsService",
"modifier": "@Mock",
"original_string": "@Mock\n MessageProcessorsService processorsService;",
"type": "MessageProcessorsService",
"var_name": "processorsService"
},
{
"declarator": "messageProcessor",
"modifie... | {
"body": "@Test(expected = UnknownMessageTypeException.class)\n public void shouldThrowUnknownMessageType() {\n messageQueue.addMessage(stubPeer, 2, 1, stubContent);\n }",
"class_method_signature": "IncomingMessageQueueTest.shouldThrowUnknownMessageType()",
"constructor": false,
"full_signature": ... | {
"fields": [
{
"declarator": "minDependencyId = 1",
"modifier": "private",
"original_string": "private int minDependencyId = 1;",
"type": "int",
"var_name": "minDependencyId"
},
{
"declarator": "messageQueue = new PriorityQueue<>(new IncomingEnvelopeComparator())",
... | {
"body": "public synchronized void addMessage(Peer sourcePeer, int messageType, int dependencyId, ByteBuf content) {\n if (checkDependency(dependencyId)) {\n byte[] contentBytes = new byte[content.readableBytes()];\n content.readBytes(contentBytes);\n\n messageQueue.add(new In... | {
"created": null,
"fork": null,
"fork_count": 1,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 61947614,
"size": 243998,
"stargazer_count": 27,
"stars": null,
"updates": null,
"url": "https://github.com/WarpOrganization/warp"
} |
61947614_8 | {
"fields": [],
"file": "core/src/test/java/net/warpgame/engine/core/context/config/ConfigLoaderTest.java",
"identifier": "ConfigLoaderTest",
"interfaces": "",
"superclass": ""
} | {
"body": "@Test\n public void parseShouldReturnFloat() {\n Assert.assertSame(Float.class, new ConfigLoader().parse(\"1.1\").getClass());\n }",
"class_method_signature": "ConfigLoaderTest.parseShouldReturnFloat()",
"constructor": false,
"full_signature": "@Test public void parseShouldReturnFloat()"... | {
"fields": [
{
"declarator": "logger = Logger.getLogger(ConfigLoader.class)",
"modifier": "private static final",
"original_string": "private static final Logger logger = Logger.getLogger(ConfigLoader.class);",
"type": "Logger",
"var_name": "logger"
},
{
"declarator": ... | {
"body": "Object parse(String o) { //lol\n Scanner s = new Scanner(o);\n if (s.hasNextInt()) return s.nextInt();\n if (s.hasNextFloat()) return s.nextFloat();\n if (s.hasNextBoolean()) return s.nextBoolean();\n return o;\n }",
"class_method_signature": "ConfigLoader.parse(Stri... | {
"created": null,
"fork": null,
"fork_count": 1,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 61947614,
"size": 243998,
"stargazer_count": 27,
"stars": null,
"updates": null,
"url": "https://github.com/WarpOrganization/warp"
} |
61947614_4 | {
"fields": [
{
"declarator": "processorsService",
"modifier": "@Mock",
"original_string": "@Mock\n MessageProcessorsService processorsService;",
"type": "MessageProcessorsService",
"var_name": "processorsService"
},
{
"declarator": "messageProcessor",
"modifie... | {
"body": "@Test\n public void shouldNotProcessMessageWithTooHighDependencyId() {\n messageQueue.addMessage(stubPeer, 1, 2, stubContent);\n verifyZeroInteractions(processorsService);\n }",
"class_method_signature": "IncomingMessageQueueTest.shouldNotProcessMessageWithTooHighDependencyId()",
"c... | {
"fields": [
{
"declarator": "minDependencyId = 1",
"modifier": "private",
"original_string": "private int minDependencyId = 1;",
"type": "int",
"var_name": "minDependencyId"
},
{
"declarator": "messageQueue = new PriorityQueue<>(new IncomingEnvelopeComparator())",
... | {
"body": "public synchronized void addMessage(Peer sourcePeer, int messageType, int dependencyId, ByteBuf content) {\n if (checkDependency(dependencyId)) {\n byte[] contentBytes = new byte[content.readableBytes()];\n content.readBytes(contentBytes);\n\n messageQueue.add(new In... | {
"created": null,
"fork": null,
"fork_count": 1,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 61947614,
"size": 243998,
"stargazer_count": 27,
"stars": null,
"updates": null,
"url": "https://github.com/WarpOrganization/warp"
} |
61947614_5 | {
"fields": [
{
"declarator": "processorsService",
"modifier": "@Mock",
"original_string": "@Mock\n MessageProcessorsService processorsService;",
"type": "MessageProcessorsService",
"var_name": "processorsService"
},
{
"declarator": "messageProcessor",
"modifie... | {
"body": "@Test\n public void shouldDiscardMessageWithTooLowDependencyId() {\n messageQueue.addMessage(stubPeer, MESSAGE_ID, 1, stubContent);\n messageQueue.addMessage(stubPeer, OTHER_MESSAGE_ID, 2, stubContent);\n verify(processorsService, times(2)).getMessageProcessor(anyInt());\n\n ... | {
"fields": [
{
"declarator": "minDependencyId = 1",
"modifier": "private",
"original_string": "private int minDependencyId = 1;",
"type": "int",
"var_name": "minDependencyId"
},
{
"declarator": "messageQueue = new PriorityQueue<>(new IncomingEnvelopeComparator())",
... | {
"body": "public synchronized void addMessage(Peer sourcePeer, int messageType, int dependencyId, ByteBuf content) {\n if (checkDependency(dependencyId)) {\n byte[] contentBytes = new byte[content.readableBytes()];\n content.readBytes(contentBytes);\n\n messageQueue.add(new In... | {
"created": null,
"fork": null,
"fork_count": 1,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 61947614,
"size": 243998,
"stargazer_count": 27,
"stars": null,
"updates": null,
"url": "https://github.com/WarpOrganization/warp"
} |
61947614_9 | {
"fields": [],
"file": "core/src/test/java/net/warpgame/engine/core/context/config/ConfigLoaderTest.java",
"identifier": "ConfigLoaderTest",
"interfaces": "",
"superclass": ""
} | {
"body": "@Test\n public void parseShouldReturnTrue() {\n Assert.assertSame(true, new ConfigLoader().parse(\"true\"));\n }",
"class_method_signature": "ConfigLoaderTest.parseShouldReturnTrue()",
"constructor": false,
"full_signature": "@Test public void parseShouldReturnTrue()",
"identifier": "p... | {
"fields": [
{
"declarator": "logger = Logger.getLogger(ConfigLoader.class)",
"modifier": "private static final",
"original_string": "private static final Logger logger = Logger.getLogger(ConfigLoader.class);",
"type": "Logger",
"var_name": "logger"
},
{
"declarator": ... | {
"body": "Object parse(String o) { //lol\n Scanner s = new Scanner(o);\n if (s.hasNextInt()) return s.nextInt();\n if (s.hasNextFloat()) return s.nextFloat();\n if (s.hasNextBoolean()) return s.nextBoolean();\n return o;\n }",
"class_method_signature": "ConfigLoader.parse(Stri... | {
"created": null,
"fork": null,
"fork_count": 1,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 61947614,
"size": 243998,
"stargazer_count": 27,
"stars": null,
"updates": null,
"url": "https://github.com/WarpOrganization/warp"
} |
58336236_0 | {
"fields": [],
"file": "pds4j/src/test/java/org/gridkit/pds4j/hash/SimpleHashLookupTest.java",
"identifier": "SimpleHashLookupTest",
"interfaces": "",
"superclass": ""
} | {
"body": "@Test\n public void test_clear() {\n \n HashStore store = new HashStore();\n \n int[] vals = serie(2000, -1000, 3);\n store.add(vals);\n \n verify(store, vals);\n \n store.clear();\n \n verify(store);\n\n store.add(vals)... | {
"fields": [
{
"declarator": "size = 0",
"modifier": "protected",
"original_string": "protected int size = 0;",
"type": "int",
"var_name": "size"
},
{
"declarator": "loadFactor = (int)(0.75 * (1 << 10))",
"modifier": "protected",
"original_string": "protect... | {
"body": "public void clear() {\n Arrays.fill(nexts, -1);\n Arrays.fill(hashes, -1);\n Arrays.fill(heads, -1);\n load = (loadFactor * heads.length) >> 10;\n size = 0; \n }",
"class_method_signature": "SimpleHashLookup.clear()",
"constructor": false,
"full_signature"... | {
"created": null,
"fork": null,
"fork_count": 0,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 58336236,
"size": 30,
"stargazer_count": 8,
"stars": null,
"updates": null,
"url": "https://github.com/aragozin/pds4j"
} |
58336236_1 | {
"fields": [],
"file": "pds4j/src/test/java/org/gridkit/pds4j/hash/SimpleHashLookupTest.java",
"identifier": "SimpleHashLookupTest",
"interfaces": "",
"superclass": ""
} | {
"body": "@Test\n public void test_reset() {\n \n HashStore store = new HashStore();\n \n int[] vals = serie(2000, -1000, 3);\n store.add(vals);\n \n verify(store, vals);\n \n store.reset();\n \n verify(store);\n \n store.a... | {
"fields": [
{
"declarator": "size = 0",
"modifier": "protected",
"original_string": "protected int size = 0;",
"type": "int",
"var_name": "size"
},
{
"declarator": "loadFactor = (int)(0.75 * (1 << 10))",
"modifier": "protected",
"original_string": "protect... | {
"body": "public void reset() {\n\n nexts = new int[1024];\n Arrays.fill(nexts, -1);\n hashes = new int[1024];\n Arrays.fill(hashes, -1);\n heads = new int[1024];\n Arrays.fill(heads, -1);\n load = (loadFactor * heads.length) >> 10;\n size = 0;\n }",
"clas... | {
"created": null,
"fork": null,
"fork_count": 0,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 58336236,
"size": 30,
"stargazer_count": 8,
"stars": null,
"updates": null,
"url": "https://github.com/aragozin/pds4j"
} |
146510094_7 | {
"fields": [
{
"declarator": "thrown = ExpectedException.none()",
"modifier": "@Rule\n public",
"original_string": "@Rule\n public ExpectedException thrown = ExpectedException.none();",
"type": "ExpectedException",
"var_name": "thrown"
},
{
"declarator": "factory... | {
"body": "@Test\n public void testConfigurationsLoadedFromMultipleFilesForDefaultServerWithAbsolutePath() {\n String config = this.getClass().getClassLoader().getResource(\"servers/default\").getPath();\n Configuration configuration = factory.initConfiguration(config, \"default\", \"dummy\", null);\... | {
"fields": [
{
"declarator": "instance = new BaseConfigurationFactory()",
"modifier": "private static final",
"original_string": "private static final BaseConfigurationFactory instance = new BaseConfigurationFactory();",
"type": "BaseConfigurationFactory",
"var_name": "instance"
... | {
"body": "@Override\n public Configuration initConfiguration(String configDirectory, String serverName, String userName, Map<String, String> additionalProperties) {\n // start with built-in Hadoop configuration that loads core-site.xml\n LOG.debug(\"Initializing configuration for server {}\", server... | {
"created": "8/28/2018 9:42:19 PM +00:00",
"fork": "False",
"fork_count": null,
"is_fork": null,
"language": null,
"license": "licensed",
"repo_id": 146510094,
"size": null,
"stargazer_count": null,
"stars": 14,
"updates": "2020-01-25T19:21:50+00:00",
"url": "https://github.com/greenplum-db/pxf... |
146510094_19 | {
"fields": [
{
"declarator": "thrown = ExpectedException.none()",
"modifier": "@Rule\n public",
"original_string": "@Rule\n public ExpectedException thrown = ExpectedException.none();",
"type": "ExpectedException",
"var_name": "thrown"
},
{
"declarator": "context... | {
"body": "@Test\n public void testStatsMaxFragmentsFailsOnZero() {\n thrown.expect(IllegalArgumentException.class);\n thrown.expectMessage(\"Wrong value '0'. STATS-MAX-FRAGMENTS must be a positive integer\");\n context.setStatsMaxFragments(0);\n }",
"class_method_signature": "RequestCont... | {
"fields": [
{
"declarator": "requestType",
"modifier": "private",
"original_string": "private RequestType requestType;",
"type": "RequestType",
"var_name": "requestType"
},
{
"declarator": "accessor",
"modifier": "private",
"original_string": "private Stri... | {
"body": "public void setStatsMaxFragments(int statsMaxFragments) {\n this.statsMaxFragments = statsMaxFragments;\n if (statsMaxFragments <= 0) {\n throw new IllegalArgumentException(String\n .format(\"Wrong value '%d'. STATS-MAX-FRAGMENTS must be a positive integer\",\n ... | {
"created": "8/28/2018 9:42:19 PM +00:00",
"fork": "False",
"fork_count": null,
"is_fork": null,
"language": null,
"license": "licensed",
"repo_id": 146510094,
"size": null,
"stargazer_count": null,
"stars": 14,
"updates": "2020-01-25T19:21:50+00:00",
"url": "https://github.com/greenplum-db/pxf... |
146510094_145 | {
"fields": [
{
"declarator": "UN_SUPPORTED_TYPE = -1",
"modifier": "private static final",
"original_string": "private static final int UN_SUPPORTED_TYPE = -1;",
"type": "int",
"var_name": "UN_SUPPORTED_TYPE"
},
{
"declarator": "output = null",
"modifier": "priva... | {
"body": "@Test\n public void testCSVSerialization() throws Exception {\n RequestContext context = new RequestContext();\n\n addColumn(context, 0, DataType.INTEGER, \"col0\");\n addColumn(context, 1, DataType.FLOAT8, \"col1\");\n addColumn(context, 2, DataType.REAL, \"col2\");\n ... | {
"fields": [
{
"declarator": "LOG = LoggerFactory.getLogger(BridgeOutputBuilder.class)",
"modifier": "private static final",
"original_string": "private static final Logger LOG = LoggerFactory.getLogger(BridgeOutputBuilder.class);",
"type": "Logger",
"var_name": "LOG"
},
{
... | {
"body": "public LinkedList<Writable> makeOutput(List<OneField> recFields)\n throws BadRecordException {\n if (output == null && context.getOutputFormat() == OutputFormat.GPDBWritable) {\n makeGPDBWritableOutput();\n }\n\n outputList.clear();\n\n fillOutputRecord(rec... | {
"created": "8/28/2018 9:42:19 PM +00:00",
"fork": "False",
"fork_count": null,
"is_fork": null,
"language": null,
"license": "licensed",
"repo_id": 146510094,
"size": null,
"stargazer_count": null,
"stars": 14,
"updates": "2020-01-25T19:21:50+00:00",
"url": "https://github.com/greenplum-db/pxf... |
146510094_329 | {
"fields": [
{
"declarator": "expectedException = ExpectedException.none()",
"modifier": "@Rule\n public",
"original_string": "@Rule\n public ExpectedException expectedException = ExpectedException.none();",
"type": "ExpectedException",
"var_name": "expectedException"
},
... | {
"body": "@Test\n public void getTableMetadataWithIncompatibleTables() throws Exception {\n\n fetcher = new HiveMetadataFetcher(context, mockConfigurationFactory, fakeHiveClientWrapper);\n\n String tablePattern = \"*\";\n String dbPattern = \"*\";\n String dbName = \"default\";\n ... | {
"fields": [
{
"declarator": "DELIM_FIELD = \"DELIMITER\"",
"modifier": "private static final",
"original_string": "private static final String DELIM_FIELD = \"DELIMITER\";",
"type": "String",
"var_name": "DELIM_FIELD"
},
{
"declarator": "LOG = LogFactory.getLog(HiveMe... | {
"body": "@Override\n public List<Metadata> getMetadata(String pattern) throws Exception {\n\n boolean ignoreErrors = false;\n List<Metadata.Item> tblsDesc = hiveClientWrapper.extractTablesFromPattern(client, pattern);\n\n if (tblsDesc == null || tblsDesc.isEmpty()) {\n LOG.warn(\"... | {
"created": "8/28/2018 9:42:19 PM +00:00",
"fork": "False",
"fork_count": null,
"is_fork": null,
"language": null,
"license": "licensed",
"repo_id": 146510094,
"size": null,
"stargazer_count": null,
"stars": 14,
"updates": "2020-01-25T19:21:50+00:00",
"url": "https://github.com/greenplum-db/pxf... |
146510094_283 | {
"fields": [
{
"declarator": "expectedException = ExpectedException.none()",
"modifier": "@Rule\n public",
"original_string": "@Rule\n public ExpectedException expectedException = ExpectedException.none();",
"type": "ExpectedException",
"var_name": "expectedException"
},
... | {
"body": "@Test\n public void testReadFromSingleLineCsvFile() throws Exception {\n prepareTest(\"csv/singleline.csv\", false);\n\n OneRow oneRow = accessor.readNextObject();\n assertNotNull(oneRow);\n assertEquals(\"a,b,c\", oneRow.getData());\n\n oneRow = accessor.readNextObjec... | {
"fields": [
{
"declarator": "fileAsRow",
"modifier": "private",
"original_string": "private boolean fileAsRow;",
"type": "boolean",
"var_name": "fileAsRow"
},
{
"declarator": "firstLine",
"modifier": "private",
"original_string": "private boolean firstLine... | {
"body": "@Override\n public OneRow readNextObject() throws IOException {\n if (super.readNextObject() == null) /* check if working segment */ {\n return null;\n }\n\n String nextLine = readLine();\n if (nextLine == null) /* EOF */ {\n return null;\n }\n\n ... | {
"created": "8/28/2018 9:42:19 PM +00:00",
"fork": "False",
"fork_count": null,
"is_fork": null,
"language": null,
"license": "licensed",
"repo_id": 146510094,
"size": null,
"stargazer_count": null,
"stars": 14,
"updates": "2020-01-25T19:21:50+00:00",
"url": "https://github.com/greenplum-db/pxf... |
146510094_407 | {
"fields": [
{
"declarator": "thrown = ExpectedException.none()",
"modifier": "@Rule\n public",
"original_string": "@Rule\n public ExpectedException thrown = ExpectedException.none();",
"type": "ExpectedException",
"var_name": "thrown"
}
],
"file": "server/pxf-s3/src/t... | {
"body": "@Test\n public void testRecordDelimiter() {\n RequestContext context = getDefaultRequestContext();\n context.addOption(\"NEWLINE\", \"\\n\");\n InputSerialization inputSerialization =\n new S3SelectAccessor().getInputSerialization(context);\n assertEquals('\\n'... | {
"fields": [
{
"declarator": "COMPRESSION_TYPE = \"COMPRESSION_CODEC\"",
"modifier": "public static final",
"original_string": "public static final String COMPRESSION_TYPE = \"COMPRESSION_CODEC\";",
"type": "String",
"var_name": "COMPRESSION_TYPE"
},
{
"declarator": "F... | {
"body": "InputSerialization getInputSerialization(RequestContext context) {\n InputSerialization inputSerialization = new InputSerialization();\n\n // We need to infer the format name from the profile (i.e. s3:parquet\n // would return parquet for the format)\n String format = context.in... | {
"created": "8/28/2018 9:42:19 PM +00:00",
"fork": "False",
"fork_count": null,
"is_fork": null,
"language": null,
"license": "licensed",
"repo_id": 146510094,
"size": null,
"stargazer_count": null,
"stars": 14,
"updates": "2020-01-25T19:21:50+00:00",
"url": "https://github.com/greenplum-db/pxf... |
146510094_112 | {
"fields": [
{
"declarator": "serverName",
"modifier": "private",
"original_string": "private String serverName;",
"type": "String",
"var_name": "serverName"
},
{
"declarator": "configuration",
"modifier": "private",
"original_string": "private Configuratio... | {
"body": "@Test\n public void testReloginFromKeytabNoValidTGT() throws Exception {\n\n assertEquals(1, subject.getPrivateCredentials().size()); // subject has 1 ticket\n\n user.setLogin(mockLoginContext);\n PowerMockito.mockStatic(KerberosUtil.class);\n when(KerberosUtil.hasKerberosKey... | {
"fields": [
{
"declarator": "LOGIN_FAILURE = \"Login failure\"",
"modifier": "private static final",
"original_string": "private static final String LOGIN_FAILURE = \"Login failure\";",
"type": "String",
"var_name": "LOGIN_FAILURE"
},
{
"declarator": "LOG = LoggerFact... | {
"body": "public static void reloginFromKeytab(String serverName, LoginSession loginSession) throws KerberosAuthException {\n\n UserGroupInformation ugi = loginSession.getLoginUser();\n\n if (ugi.getAuthenticationMethod() != UserGroupInformation.AuthenticationMethod.KERBEROS ||\n !ugi.is... | {
"created": "8/28/2018 9:42:19 PM +00:00",
"fork": "False",
"fork_count": null,
"is_fork": null,
"language": null,
"license": "licensed",
"repo_id": 146510094,
"size": null,
"stargazer_count": null,
"stars": 14,
"updates": "2020-01-25T19:21:50+00:00",
"url": "https://github.com/greenplum-db/pxf... |
146510094_391 | {
"fields": [
{
"declarator": "FILE_FRAGMENTER = \"org.greenplum.pxf.plugins.hdfs.HdfsFileFragmenter\"",
"modifier": "private static final",
"original_string": "private static final String FILE_FRAGMENTER = \"org.greenplum.pxf.plugins.hdfs.HdfsFileFragmenter\";",
"type": "String",
"v... | {
"body": "@Test\n public void testTextSelectOptionMissing() {\n context.setFormat(\"CSV\");\n context.setOutputFormat(OutputFormat.TEXT);\n assertEquals(\"default-accessor\", handler.getAccessorClassName(context));\n }",
"class_method_signature": "S3ProtocolHandlerTest.testTextSelectOpti... | {
"fields": [
{
"declarator": "S3_SELECT_OPTION = \"S3_SELECT\"",
"modifier": "public static final",
"original_string": "public static final String S3_SELECT_OPTION = \"S3_SELECT\";",
"type": "String",
"var_name": "S3_SELECT_OPTION"
},
{
"declarator": "LOG = LoggerFacto... | {
"body": "@Override\n public String getAccessorClassName(RequestContext context) {\n String accessor = context.getAccessor(); // default to accessor defined by the profile\n if (useS3Select(context)) {\n accessor = S3SelectAccessor.class.getName();\n }\n LOG.debug(\"Determin... | {
"created": "8/28/2018 9:42:19 PM +00:00",
"fork": "False",
"fork_count": null,
"is_fork": null,
"language": null,
"license": "licensed",
"repo_id": 146510094,
"size": null,
"stargazer_count": null,
"stars": 14,
"updates": "2020-01-25T19:21:50+00:00",
"url": "https://github.com/greenplum-db/pxf... |
146510094_411 | {
"fields": [
{
"declarator": "thrown = ExpectedException.none()",
"modifier": "@Rule\n public",
"original_string": "@Rule\n public ExpectedException thrown = ExpectedException.none();",
"type": "ExpectedException",
"var_name": "thrown"
}
],
"file": "server/pxf-s3/src/t... | {
"body": "@Test\n public void testFailsOnWriteNextObject() {\n thrown.expect(UnsupportedOperationException.class);\n thrown.expectMessage(\"S3 Select does not support writing\");\n new S3SelectAccessor().writeNextObject(new OneRow());\n }",
"class_method_signature": "S3SelectAccessorTest... | {
"fields": [
{
"declarator": "COMPRESSION_TYPE = \"COMPRESSION_CODEC\"",
"modifier": "public static final",
"original_string": "public static final String COMPRESSION_TYPE = \"COMPRESSION_CODEC\";",
"type": "String",
"var_name": "COMPRESSION_TYPE"
},
{
"declarator": "F... | {
"body": "@Override\n public boolean writeNextObject(OneRow onerow) {\n throw new UnsupportedOperationException(\"S3 Select does not support writing\");\n }",
"class_method_signature": "S3SelectAccessor.writeNextObject(OneRow onerow)",
"constructor": false,
"full_signature": "@Override public bool... | {
"created": "8/28/2018 9:42:19 PM +00:00",
"fork": "False",
"fork_count": null,
"is_fork": null,
"language": null,
"license": "licensed",
"repo_id": 146510094,
"size": null,
"stargazer_count": null,
"stars": 14,
"updates": "2020-01-25T19:21:50+00:00",
"url": "https://github.com/greenplum-db/pxf... |
146510094_58 | {
"fields": [
{
"declarator": "thrown = ExpectedException.none()",
"modifier": "@Rule\n public",
"original_string": "@Rule\n public ExpectedException thrown = ExpectedException.none();",
"type": "ExpectedException",
"var_name": "thrown"
}
],
"file": "server/pxf-api/src/... | {
"body": "@Test\n public void testTraverseTree() {\n TreeVisitor visitor = mock(TreeVisitor.class);\n Node l0 = new Node();\n l0.setLeft(new Node());\n l0.setRight(new Node());\n l0.getLeft().setLeft(new Node());\n l0.getLeft().setRight(new Node());\n l0.getLeft().... | {
"fields": [
{
"declarator": "LOG = LoggerFactory.getLogger(TreeTraverser.class)",
"modifier": "private static final",
"original_string": "private static final Logger LOG = LoggerFactory.getLogger(TreeTraverser.class);",
"type": "Logger",
"var_name": "LOG"
}
],
"file": "serv... | {
"body": "public Node traverse(Node node, TreeVisitor... visitors) {\n\n if (ArrayUtils.isEmpty(visitors)) {\n throw new IllegalArgumentException(\"You need to provide at least one visitor for this traverser\");\n }\n\n Node result = node;\n for (TreeVisitor visitor : visitors)... | {
"created": "8/28/2018 9:42:19 PM +00:00",
"fork": "False",
"fork_count": null,
"is_fork": null,
"language": null,
"license": "licensed",
"repo_id": 146510094,
"size": null,
"stargazer_count": null,
"stars": 14,
"updates": "2020-01-25T19:21:50+00:00",
"url": "https://github.com/greenplum-db/pxf... |
146510094_104 | {
"fields": [
{
"declarator": "session",
"modifier": "private",
"original_string": "private LoginSession session, sessionFoo, sessionBar;",
"type": "LoginSession",
"var_name": "session"
},
{
"declarator": "ugiFoo",
"modifier": "private",
"original_string": "... | {
"body": "@Test\n public void testEquality() {\n sessionFoo = new LoginSession(\"config\", \"principal\", \"keytab\", ugiFoo, subjectFoo, 1);\n\n sessionBar = new LoginSession(\"config\", \"principal\", \"keytab\", ugiBar, subjectBar, 1);\n assertEquals(sessionFoo, sessionBar);\n asser... | {
"fields": [
{
"declarator": "configDirectory",
"modifier": "private",
"original_string": "private String configDirectory;",
"type": "String",
"var_name": "configDirectory"
},
{
"declarator": "principalName",
"modifier": "private",
"original_string": "priva... | {
"body": "@Override\n public int hashCode() {\n return Objects.hash(configDirectory, principalName, keytabPath, kerberosMinMillisBeforeRelogin);\n }",
"class_method_signature": "LoginSession.hashCode()",
"constructor": false,
"full_signature": "@Override public int hashCode()",
"identifier": "ha... | {
"created": "8/28/2018 9:42:19 PM +00:00",
"fork": "False",
"fork_count": null,
"is_fork": null,
"language": null,
"license": "licensed",
"repo_id": 146510094,
"size": null,
"stargazer_count": null,
"stars": 14,
"updates": "2020-01-25T19:21:50+00:00",
"url": "https://github.com/greenplum-db/pxf... |
146510094_387 | {
"fields": [
{
"declarator": "thrown = ExpectedException.none()",
"modifier": "@Rule\n public",
"original_string": "@Rule\n public ExpectedException thrown = ExpectedException.none();",
"type": "ExpectedException",
"var_name": "thrown"
},
{
"declarator": "dbProdu... | {
"body": "@Test\n public void testInvalidNullQuoteString() {\n DatePartition partition = new DatePartition(COL_RAW, LocalDate.parse(\"2000-01-01\"), LocalDate.parse(\"2000-01-02\"));\n\n thrown.expect(RuntimeException.class);\n\n partition.toSqlConstraint(null, dbProduct);\n }",
"class_m... | {
"fields": [
{
"declarator": "serialVersionUID = 0L",
"modifier": "private static final",
"original_string": "private static final long serialVersionUID = 0L;",
"type": "long",
"var_name": "serialVersionUID"
},
{
"declarator": "boundaries",
"modifier": "private f... | {
"body": "@Override\n public String toSqlConstraint(String quoteString, DbProduct dbProduct) {\n if (quoteString == null) {\n throw new RuntimeException(\"Quote string cannot be null\");\n }\n if (dbProduct == null) {\n throw new RuntimeException(String.format(\n ... | {
"created": "8/28/2018 9:42:19 PM +00:00",
"fork": "False",
"fork_count": null,
"is_fork": null,
"language": null,
"license": "licensed",
"repo_id": 146510094,
"size": null,
"stargazer_count": null,
"stars": 14,
"updates": "2020-01-25T19:21:50+00:00",
"url": "https://github.com/greenplum-db/pxf... |
146510094_368 | {
"fields": [
{
"declarator": "connConfig",
"modifier": "private",
"original_string": "private Properties connConfig, poolConfig;",
"type": "Properties",
"var_name": "connConfig"
},
{
"declarator": "poolDescriptor",
"modifier": "private",
"original_string": ... | {
"body": "@Test\n public void testPoolDescriptorToString() {\n poolDescriptor = new PoolDescriptor(\"test-server\", \"test-jdbcUrl\", connConfig, poolConfig, null);\n assertEquals(\"PoolDescriptor{jdbcUrl=test-jdbcUrl, user=test-user, password=*************, connectionConfig={test-other-property=tes... | {
"fields": [
{
"declarator": "USER_PROPERTY_NAME = \"user\"",
"modifier": "private static final",
"original_string": "private static final String USER_PROPERTY_NAME = \"user\";",
"type": "String",
"var_name": "USER_PROPERTY_NAME"
},
{
"declarator": "PASSWORD_PROPERTY_N... | {
"body": "@Override\n public String toString() {\n return \"PoolDescriptor{\" +\n \"jdbcUrl=\" + jdbcUrl +\n \", user=\" + user +\n \", password=\" + ConnectionManager.maskPassword(password) +\n \", connectionConfig=\" + connectionConfig +\n ... | {
"created": "8/28/2018 9:42:19 PM +00:00",
"fork": "False",
"fork_count": null,
"is_fork": null,
"language": null,
"license": "licensed",
"repo_id": 146510094,
"size": null,
"stargazer_count": null,
"stars": 14,
"updates": "2020-01-25T19:21:50+00:00",
"url": "https://github.com/greenplum-db/pxf... |
146510094_153 | {
"fields": [
{
"declarator": "expectedException = ExpectedException.none()",
"modifier": "@Rule\n public",
"original_string": "@Rule\n public ExpectedException expectedException = ExpectedException.none();",
"type": "ExpectedException",
"var_name": "expectedException"
},
... | {
"body": "@Test\n public void throwsWhenRequiredUserIdHeaderIsMissing() throws Exception {\n expectedException.expect(IllegalArgumentException.class);\n expectedException.expectMessage(\"Header X-GP-USER is missing in the request\");\n filter.doFilter(mockServletRequest, mockServletResponse, ... | {
"fields": [
{
"declarator": "LOG = LoggerFactory.getLogger(SecurityServletFilter.class)",
"modifier": "private static final",
"original_string": "private static final Logger LOG = LoggerFactory.getLogger(SecurityServletFilter.class);",
"type": "Logger",
"var_name": "LOG"
},
... | {
"body": "@Override\n public void doFilter(final ServletRequest request, final ServletResponse response, final FilterChain chain)\n throws IOException, ServletException {\n\n // retrieve user header and make sure header is present and is not empty\n final String gpdbUser = getHeaderValue(... | {
"created": "8/28/2018 9:42:19 PM +00:00",
"fork": "False",
"fork_count": null,
"is_fork": null,
"language": null,
"license": "licensed",
"repo_id": 146510094,
"size": null,
"stargazer_count": null,
"stars": 14,
"updates": "2020-01-25T19:21:50+00:00",
"url": "https://github.com/greenplum-db/pxf... |
146510094_295 | {
"fields": [
{
"declarator": "thrown = ExpectedException.none()",
"modifier": "@Rule\n public",
"original_string": "@Rule\n public ExpectedException thrown = ExpectedException.none();",
"type": "ExpectedException",
"var_name": "thrown"
},
{
"declarator": "resolve... | {
"body": "@Test\n public void testGetFields_Primitive_With_Projection() throws IOException {\n schema = getParquetSchemaForPrimitiveTypes(Type.Repetition.OPTIONAL, true);\n context.setTupleDescription(getColumnDescriptorsFromSchema(schema));\n\n // set odd columns to be not projected, their v... | {
"fields": [
{
"declarator": "TIMESTAMP_PATTERN = Pattern.compile(\"[+-]\\\\d{2}(:\\\\d{2})?$\")",
"modifier": "public static final",
"original_string": "public static final Pattern TIMESTAMP_PATTERN = Pattern.compile(\"[+-]\\\\d{2}(:\\\\d{2})?$\");",
"type": "Pattern",
"var_name": ... | {
"body": "@Override\n public void initialize(RequestContext requestContext) {\n super.initialize(requestContext);\n this.columnDescriptors = context.getTupleDescription();\n }",
"class_method_signature": "ParquetResolver.initialize(RequestContext requestContext)",
"constructor": false,
"ful... | {
"created": "8/28/2018 9:42:19 PM +00:00",
"fork": "False",
"fork_count": null,
"is_fork": null,
"language": null,
"license": "licensed",
"repo_id": 146510094,
"size": null,
"stargazer_count": null,
"stars": 14,
"updates": "2020-01-25T19:21:50+00:00",
"url": "https://github.com/greenplum-db/pxf... |
146510094_128 | {
"fields": [
{
"declarator": "MINUTES = 60 * 1000L",
"modifier": "private static final",
"original_string": "private static final long MINUTES = 60 * 1000L;",
"type": "long",
"var_name": "MINUTES"
},
{
"declarator": "provider = null",
"modifier": "private",
... | {
"body": "@Test\n public void getProxyUGIWithEquivalentSessionsReturnsTheSameInstance() throws Exception {\n SessionId session2 = new SessionId(0, \"txn-id\", \"the-user\", \"default\");\n UserGroupInformation ugi1 = cache.getUserGroupInformation(session, true);\n UserGroupInformation ugi2 = ... | {
"fields": [
{
"declarator": "NANOS_PER_MILLIS = 1000000",
"modifier": "static final",
"original_string": "static final int NANOS_PER_MILLIS = 1000000;",
"type": "int",
"var_name": "NANOS_PER_MILLIS"
},
{
"declarator": "UGI_CACHE_EXPIRY = 15 * 60 * 1000L",
"modif... | {
"body": "@SuppressWarnings(\"SynchronizationOnLocalVariableOrMethodParameter\")\n public UserGroupInformation getUserGroupInformation(SessionId session, boolean isProxyUser) throws IOException {\n Integer segmentId = session.getSegmentId();\n String user = session.getUser();\n DelayQueue<Ent... | {
"created": "8/28/2018 9:42:19 PM +00:00",
"fork": "False",
"fork_count": null,
"is_fork": null,
"language": null,
"license": "licensed",
"repo_id": 146510094,
"size": null,
"stargazer_count": null,
"stars": 14,
"updates": "2020-01-25T19:21:50+00:00",
"url": "https://github.com/greenplum-db/pxf... |
146510094_74 | {
"fields": [
{
"declarator": "PROPERTY_KEY_FRAGMENTER_CACHE = \"pxf.service.fragmenter.cache.enabled\"",
"modifier": "private",
"original_string": "private String PROPERTY_KEY_FRAGMENTER_CACHE = \"pxf.service.fragmenter.cache.enabled\";",
"type": "String",
"var_name": "PROPERTY_KEY_... | {
"body": "@Test\n public void validRestrictedDirectoryName() {\n assertTrue(Utilities.isValidRestrictedDirectoryName(\"pxf\"));\n assertTrue(Utilities.isValidRestrictedDirectoryName(\"\\uD83D\\uDE0A\"));\n }",
"class_method_signature": "UtilitiesTest.validRestrictedDirectoryName()",
"construc... | {
"fields": [
{
"declarator": "LOG = LoggerFactory.getLogger(Utilities.class)",
"modifier": "private static final",
"original_string": "private static final Logger LOG = LoggerFactory.getLogger(Utilities.class);",
"type": "Logger",
"var_name": "LOG"
},
{
"declarator": "... | {
"body": "public static boolean isValidRestrictedDirectoryName(String name) {\n return isValidRestrictedDirectoryName(name, true);\n }",
"class_method_signature": "Utilities.isValidRestrictedDirectoryName(String name)",
"constructor": false,
"full_signature": "public static boolean isValidRestrictedD... | {
"created": "8/28/2018 9:42:19 PM +00:00",
"fork": "False",
"fork_count": null,
"is_fork": null,
"language": null,
"license": "licensed",
"repo_id": 146510094,
"size": null,
"stargazer_count": null,
"stars": 14,
"updates": "2020-01-25T19:21:50+00:00",
"url": "https://github.com/greenplum-db/pxf... |
146510094_344 | {
"fields": [
{
"declarator": "expectedException = ExpectedException.none()",
"modifier": "@Rule\n public",
"original_string": "@Rule\n public ExpectedException expectedException = ExpectedException.none();",
"type": "ExpectedException",
"var_name": "expectedException"
},
... | {
"body": "@Test\n public void testSingletonInstance() {\n assertSame(manager, ConnectionManager.getInstance());\n }",
"class_method_signature": "ConnectionManagerTest.testSingletonInstance()",
"constructor": false,
"full_signature": "@Test public void testSingletonInstance()",
"identifier": "tes... | {
"fields": [
{
"declarator": "LOG = LoggerFactory.getLogger(ConnectionManager.class)",
"modifier": "private static final",
"original_string": "private static final Logger LOG = LoggerFactory.getLogger(ConnectionManager.class);",
"type": "Logger",
"var_name": "LOG"
},
{
... | {
"body": "public static ConnectionManager getInstance() {\n return instance;\n }",
"class_method_signature": "ConnectionManager.getInstance()",
"constructor": false,
"full_signature": "public static ConnectionManager getInstance()",
"identifier": "getInstance",
"invocations": [],
"modifiers": "... | {
"created": "8/28/2018 9:42:19 PM +00:00",
"fork": "False",
"fork_count": null,
"is_fork": null,
"language": null,
"license": "licensed",
"repo_id": 146510094,
"size": null,
"stargazer_count": null,
"stars": 14,
"updates": "2020-01-25T19:21:50+00:00",
"url": "https://github.com/greenplum-db/pxf... |
146510094_201 | {
"fields": [
{
"declarator": "parameters",
"modifier": "private",
"original_string": "private MultivaluedMap<String, String> parameters;",
"type": "MultivaluedMap<String, String>",
"var_name": "parameters"
},
{
"declarator": "parser",
"modifier": "private",
... | {
"body": "@Test\n public void getFragmentMetadata() {\n RequestContext context = parser.parseRequest(mockRequestHeaders, RequestType.FRAGMENTER);\n byte[] location = context.getFragmentMetadata();\n assertEquals(\"Something in the way\", new String(location));\n }",
"class_method_signatu... | {
"fields": [
{
"declarator": "TRUE_LCASE = \"true\"",
"modifier": "private static final",
"original_string": "private static final String TRUE_LCASE = \"true\";",
"type": "String",
"var_name": "TRUE_LCASE"
},
{
"declarator": "FALSE_LCASE = \"false\"",
"modifier":... | {
"body": "@Override\n public RequestContext parseRequest(HttpHeaders request, RequestContext.RequestType requestType) {\n\n RequestMap params = new RequestMap(request.getRequestHeaders());\n\n if (LOG.isDebugEnabled()) {\n // Logging only keys to prevent sensitive data to be logged\n ... | {
"created": "8/28/2018 9:42:19 PM +00:00",
"fork": "False",
"fork_count": null,
"is_fork": null,
"language": null,
"license": "licensed",
"repo_id": 146510094,
"size": null,
"stargazer_count": null,
"stars": 14,
"updates": "2020-01-25T19:21:50+00:00",
"url": "https://github.com/greenplum-db/pxf... |
146510094_23 | {
"fields": [
{
"declarator": "thrown = ExpectedException.none()",
"modifier": "@Rule\n public",
"original_string": "@Rule\n public ExpectedException thrown = ExpectedException.none();",
"type": "ExpectedException",
"var_name": "thrown"
},
{
"declarator": "context... | {
"body": "@Test\n public void testStatsSampleRatioFailsOnLessThanOneTenThousand() {\n thrown.expect(IllegalArgumentException.class);\n thrown.expectMessage(\"Wrong value '5.0E-5'. STATS-SAMPLE-RATIO must be a value between 0.0001 and 1.0\");\n context.setStatsSampleRatio(0.00005f);\n }",
... | {
"fields": [
{
"declarator": "requestType",
"modifier": "private",
"original_string": "private RequestType requestType;",
"type": "RequestType",
"var_name": "requestType"
},
{
"declarator": "accessor",
"modifier": "private",
"original_string": "private Stri... | {
"body": "public void setStatsSampleRatio(float statsSampleRatio) {\n this.statsSampleRatio = statsSampleRatio;\n if (statsSampleRatio < 0.0001 || statsSampleRatio > 1.0) {\n throw new IllegalArgumentException(\n \"Wrong value '\"\n + statsSample... | {
"created": "8/28/2018 9:42:19 PM +00:00",
"fork": "False",
"fork_count": null,
"is_fork": null,
"language": null,
"license": "licensed",
"repo_id": 146510094,
"size": null,
"stargazer_count": null,
"stars": 14,
"updates": "2020-01-25T19:21:50+00:00",
"url": "https://github.com/greenplum-db/pxf... |
146510094_190 | {
"fields": [
{
"declarator": "response = null",
"modifier": "",
"original_string": "MetadataResponse response = null;",
"type": "MetadataResponse",
"var_name": "response"
}
],
"file": "server/pxf-service/src/test/java/org/greenplum/pxf/service/MetadataResponseFormatterTest.j... | {
"body": "@Test\n public void formatResponseStringWithSourceType() throws Exception {\n List<Metadata> metadataList = new ArrayList<Metadata>();\n List<Metadata.Field> fields = new ArrayList<Metadata.Field>();\n Metadata.Item itemName = new Metadata.Item(\"default\", \"table1\");\n Met... | {
"fields": [
{
"declarator": "LOG = LogFactory.getLog(MetadataResponseFormatter.class)",
"modifier": "private static final",
"original_string": "private static final Log LOG = LogFactory.getLog(MetadataResponseFormatter.class);",
"type": "Log",
"var_name": "LOG"
}
],
"file":... | {
"body": "public static MetadataResponse formatResponse(List<Metadata> metadataList, String path) throws IOException {\n /* print the fragment list to log when in debug level */\n if (LOG.isDebugEnabled()) {\n MetadataResponseFormatter.printMetadata(metadataList, path);\n }\n\n ... | {
"created": "8/28/2018 9:42:19 PM +00:00",
"fork": "False",
"fork_count": null,
"is_fork": null,
"language": null,
"license": "licensed",
"repo_id": 146510094,
"size": null,
"stargazer_count": null,
"stars": 14,
"updates": "2020-01-25T19:21:50+00:00",
"url": "https://github.com/greenplum-db/pxf... |
146510094_313 | {
"fields": [
{
"declarator": "hiveColumn",
"modifier": "",
"original_string": "FieldSchema hiveColumn;",
"type": "FieldSchema",
"var_name": "hiveColumn"
},
{
"declarator": "typesMappings = {\n /* hive type -> gpdb type */\n {\"tinyint\", \"int2\"}... | {
"body": "@Test\n public void mapHiveTypeSimple() throws Exception {\n /*\n * tinyint -> int2\n * smallint -> int2\n * int -> int4\n * bigint -> int8\n * boolean -> bool\n * float -> float4\n * double -> float8\n * string -> text\n * b... | {
"fields": [
{
"declarator": "LOG = LoggerFactory.getLogger(HiveUtilities.class)",
"modifier": "private static final",
"original_string": "private static final Logger LOG = LoggerFactory.getLogger(HiveUtilities.class);",
"type": "Logger",
"var_name": "LOG"
}
],
"file": "serv... | {
"body": "public static Metadata.Field mapHiveType(FieldSchema hiveColumn) throws UnsupportedTypeException {\n String fieldName = hiveColumn.getName();\n String hiveType = hiveColumn.getType(); // Type name and modifiers if any\n String hiveTypeName; // Type name\n String[] modifiers = nu... | {
"created": "8/28/2018 9:42:19 PM +00:00",
"fork": "False",
"fork_count": null,
"is_fork": null,
"language": null,
"license": "licensed",
"repo_id": 146510094,
"size": null,
"stargazer_count": null,
"stars": 14,
"updates": "2020-01-25T19:21:50+00:00",
"url": "https://github.com/greenplum-db/pxf... |
146510094_256 | {
"fields": [
{
"declarator": "context",
"modifier": "private",
"original_string": "private RequestContext context;",
"type": "RequestContext",
"var_name": "context"
},
{
"declarator": "schema",
"modifier": "private",
"original_string": "private Schema schem... | {
"body": "@Test\n public void testObtainSchema_OnWrite_WithUserProvidedSchema_Binary_HCFS() {\n avroUtilities = new AvroUtilities((file) -> dontFindLocalFile());\n context.setRequestType(RequestContext.RequestType.WRITE_BRIDGE);\n context.addOption(\"SCHEMA\", avroDirectory + \"user-provided.... | {
"fields": [
{
"declarator": "COMMON_NAMESPACE = \"public.avro\"",
"modifier": "private static",
"original_string": "private static String COMMON_NAMESPACE = \"public.avro\";",
"type": "String",
"var_name": "COMMON_NAMESPACE"
},
{
"declarator": "fileSearcher",
"m... | {
"body": "public Schema obtainSchema(RequestContext context, Configuration configuration, HcfsType hcfsType) {\n Schema schema = (Schema) context.getMetadata();\n\n if (schema != null) {\n return schema;\n }\n try {\n schemaPath = context.getDataSource();\n ... | {
"created": "8/28/2018 9:42:19 PM +00:00",
"fork": "False",
"fork_count": null,
"is_fork": null,
"language": null,
"license": "licensed",
"repo_id": 146510094,
"size": null,
"stargazer_count": null,
"stars": 14,
"updates": "2020-01-25T19:21:50+00:00",
"url": "https://github.com/greenplum-db/pxf... |
146510094_169 | {
"fields": [
{
"declarator": "expectedException = ExpectedException.none()",
"modifier": "@Rule\n public",
"original_string": "@Rule\n public ExpectedException expectedException = ExpectedException.none();",
"type": "ExpectedException",
"var_name": "expectedException"
},
... | {
"body": "@Test\n @SuppressWarnings(\"unchecked\")\n public void cleansUGICacheWhenTheFilterExecutionThrowsAnInterruptedException() throws Exception {\n expectedException.expect(ServletException.class);\n expectScenario(false, false, false);\n doThrow(InterruptedException.class).when(mockP... | {
"fields": [
{
"declarator": "LOG = LoggerFactory.getLogger(SecurityServletFilter.class)",
"modifier": "private static final",
"original_string": "private static final Logger LOG = LoggerFactory.getLogger(SecurityServletFilter.class);",
"type": "Logger",
"var_name": "LOG"
},
... | {
"body": "@Override\n public void doFilter(final ServletRequest request, final ServletResponse response, final FilterChain chain)\n throws IOException, ServletException {\n\n // retrieve user header and make sure header is present and is not empty\n final String gpdbUser = getHeaderValue(... | {
"created": "8/28/2018 9:42:19 PM +00:00",
"fork": "False",
"fork_count": null,
"is_fork": null,
"language": null,
"license": "licensed",
"repo_id": 146510094,
"size": null,
"stargazer_count": null,
"stars": 14,
"updates": "2020-01-25T19:21:50+00:00",
"url": "https://github.com/greenplum-db/pxf... |
146510094_35 | {
"fields": [
{
"declarator": "gpCSV",
"modifier": "private",
"original_string": "private GreenplumCSV gpCSV;",
"type": "GreenplumCSV",
"var_name": "gpCSV"
},
{
"declarator": "thrown = ExpectedException.none()",
"modifier": "@Rule\n public",
"original_str... | {
"body": "@Test\n public void testToCsvFieldEscapesQuotes() {\n String input = \"{\\\"key\\\": \\\"value\\\", \\\"foo\\\": \\\"bar\\\"}\";\n String expected = \"{\\\"\\\"key\\\"\\\": \\\"\\\"value\\\"\\\", \\\"\\\"foo\\\"\\\": \\\"\\\"bar\\\"\\\"}\";\n\n assertEquals(expected, gpCSV.toCsvFiel... | {
"fields": [
{
"declarator": "QUOTE = '\"'",
"modifier": "private static final",
"original_string": "private static final char QUOTE = '\"';",
"type": "char",
"var_name": "QUOTE"
},
{
"declarator": "ESCAPE = '\"'",
"modifier": "private static final",
"origi... | {
"body": "public String toCsvField(String s, boolean prependQuoteChar, boolean appendQuoteChar) {\n return toCsvField(s, prependQuoteChar, appendQuoteChar, false);\n }",
"class_method_signature": "GreenplumCSV.toCsvField(String s, boolean prependQuoteChar, boolean appendQuoteChar)",
"constructor": fals... | {
"created": "8/28/2018 9:42:19 PM +00:00",
"fork": "False",
"fork_count": null,
"is_fork": null,
"language": null,
"license": "licensed",
"repo_id": 146510094,
"size": null,
"stargazer_count": null,
"stars": 14,
"updates": "2020-01-25T19:21:50+00:00",
"url": "https://github.com/greenplum-db/pxf... |
146510094_186 | {
"fields": [
{
"declarator": "expectedException = ExpectedException.none()",
"modifier": "@Rule\n public",
"original_string": "@Rule\n public ExpectedException expectedException = ExpectedException.none();",
"type": "ExpectedException",
"var_name": "expectedException"
}
... | {
"body": "@Test\n public void testProfileWithSpacesInName() {\n ProfilesConf profilesConf = getProfilesConf(\"profileWithSpacesInName\");\n\n Map<String, String> map = profilesConf.getPlugins(\"HBase\");\n assertNotNull(map);\n assertEquals(1, map.size());\n assertEquals(\"Y\", ... | {
"fields": [
{
"declarator": "EXTERNAL_PROFILES = \"pxf-profiles.xml\"",
"modifier": "private final static",
"original_string": "private final static String EXTERNAL_PROFILES = \"pxf-profiles.xml\";",
"type": "String",
"var_name": "EXTERNAL_PROFILES"
},
{
"declarator":... | {
"body": "@Override\n public Map<String, String> getPlugins(String profileName) {\n Profile profile = getProfile(profileName);\n Map<String, String> result = profile.getPluginsMap();\n if (result.isEmpty()) {\n throw new ProfileConfException(NO_PLUGINS_IN_PROFILE_DEF, profileName, ... | {
"created": "8/28/2018 9:42:19 PM +00:00",
"fork": "False",
"fork_count": null,
"is_fork": null,
"language": null,
"license": "licensed",
"repo_id": 146510094,
"size": null,
"stargazer_count": null,
"stars": 14,
"updates": "2020-01-25T19:21:50+00:00",
"url": "https://github.com/greenplum-db/pxf... |
146510094_305 | {
"fields": [
{
"declarator": "factory",
"modifier": "private",
"original_string": "private CodecFactory factory;",
"type": "CodecFactory",
"var_name": "factory"
},
{
"declarator": "thrown = ExpectedException.none()",
"modifier": "@Rule\n public",
"origin... | {
"body": "@Test\n public void getCodecNoName() {\n thrown.expect(IllegalArgumentException.class);\n thrown.expectMessage(\"Compression codec some.bad.codec was not found.\");\n\n Configuration conf = new Configuration();\n String name = \"some.bad.codec\";\n factory.getCodec(nam... | {
"fields": [
{
"declarator": "LOG = LoggerFactory.getLogger(CodecFactory.class)",
"modifier": "private static",
"original_string": "private static Logger LOG = LoggerFactory.getLogger(CodecFactory.class);",
"type": "Logger",
"var_name": "LOG"
},
{
"declarator": "codecF... | {
"body": "public CompressionCodecName getCodec(String name, CompressionCodecName defaultCodec) {\n if (name == null) return defaultCodec;\n\n try {\n return CompressionCodecName.fromConf(name);\n } catch (IllegalArgumentException ie) {\n try {\n return Compre... | {
"created": "8/28/2018 9:42:19 PM +00:00",
"fork": "False",
"fork_count": null,
"is_fork": null,
"language": null,
"license": "licensed",
"repo_id": 146510094,
"size": null,
"stargazer_count": null,
"stars": 14,
"updates": "2020-01-25T19:21:50+00:00",
"url": "https://github.com/greenplum-db/pxf... |
146510094_240 | {
"fields": [
{
"declarator": "context",
"modifier": "private",
"original_string": "private RequestContext context;",
"type": "RequestContext",
"var_name": "context"
},
{
"declarator": "schema",
"modifier": "private",
"original_string": "private Schema schem... | {
"body": "@Test\n public void testObtainSchema_OnRead_WithUserProvidedSchema_Binary_HCFS_Spaces() {\n avroUtilities = new AvroUtilities((file) -> dontFindLocalFile());\n context.setRequestType(RequestContext.RequestType.READ_BRIDGE);\n context.addOption(\"SCHEMA\", avroDirectory + \"user prov... | {
"fields": [
{
"declarator": "COMMON_NAMESPACE = \"public.avro\"",
"modifier": "private static",
"original_string": "private static String COMMON_NAMESPACE = \"public.avro\";",
"type": "String",
"var_name": "COMMON_NAMESPACE"
},
{
"declarator": "fileSearcher",
"m... | {
"body": "public Schema obtainSchema(RequestContext context, Configuration configuration, HcfsType hcfsType) {\n Schema schema = (Schema) context.getMetadata();\n\n if (schema != null) {\n return schema;\n }\n try {\n schemaPath = context.getDataSource();\n ... | {
"created": "8/28/2018 9:42:19 PM +00:00",
"fork": "False",
"fork_count": null,
"is_fork": null,
"language": null,
"license": "licensed",
"repo_id": 146510094,
"size": null,
"stargazer_count": null,
"stars": 14,
"updates": "2020-01-25T19:21:50+00:00",
"url": "https://github.com/greenplum-db/pxf... |
146510094_62 | {
"fields": [
{
"declarator": "thrown = ExpectedException.none()",
"modifier": "@Rule\n public",
"original_string": "@Rule\n public ExpectedException thrown = ExpectedException.none();",
"type": "ExpectedException",
"var_name": "thrown"
}
],
"file": "server/pxf-api/src/... | {
"body": "@Test\n public void testPruningRootNodeDuringAfter() {\n Node root = new Node();\n TreeVisitor visitor = mock(TreeVisitor.class);\n\n when(visitor.before(root, 0)).thenReturn(root);\n when(visitor.visit(root, 0)).thenReturn(root);\n\n Node result = new TreeTraverser().... | {
"fields": [
{
"declarator": "LOG = LoggerFactory.getLogger(TreeTraverser.class)",
"modifier": "private static final",
"original_string": "private static final Logger LOG = LoggerFactory.getLogger(TreeTraverser.class);",
"type": "Logger",
"var_name": "LOG"
}
],
"file": "serv... | {
"body": "public Node traverse(Node node, TreeVisitor... visitors) {\n\n if (ArrayUtils.isEmpty(visitors)) {\n throw new IllegalArgumentException(\"You need to provide at least one visitor for this traverser\");\n }\n\n Node result = node;\n for (TreeVisitor visitor : visitors)... | {
"created": "8/28/2018 9:42:19 PM +00:00",
"fork": "False",
"fork_count": null,
"is_fork": null,
"language": null,
"license": "licensed",
"repo_id": 146510094,
"size": null,
"stargazer_count": null,
"stars": 14,
"updates": "2020-01-25T19:21:50+00:00",
"url": "https://github.com/greenplum-db/pxf... |
146510094_352 | {
"fields": [],
"file": "server/pxf-jdbc/src/test/java/org/greenplum/pxf/plugins/jdbc/utils/HiveJdbcUtilsTest.java",
"identifier": "HiveJdbcUtilsTest",
"interfaces": "",
"superclass": ""
} | {
"body": "@Test\n public void testURLWithoutImpersonationPropertyAndWithQuestionMark() throws Exception {\n String url = \"jdbc:hive2://server:10000/default;foo=bar;saslQop=auth-conf?hive.property=value\";\n assertEquals(\"jdbc:hive2://server:10000/default;foo=bar;saslQop=auth-conf;hive.server2.prox... | {
"fields": [
{
"declarator": "HIVE_URL_IMPERSONATION_PROPERTY = \";hive.server2.proxy.user\"",
"modifier": "private static final",
"original_string": "private static final String HIVE_URL_IMPERSONATION_PROPERTY = \";hive.server2.proxy.user\";",
"type": "String",
"var_name": "HIVE_UR... | {
"body": "public static String updateImpersonationPropertyInHiveJdbcUrl(String url, String user) {\n String suffix, prefix = null;\n int terminatorIndex = findTerminatorIndex(url, 0, TERMINATORS_TWO_CHARS);\n\n // impersonation property might already be in the URL\n int impersonationPrope... | {
"created": "8/28/2018 9:42:19 PM +00:00",
"fork": "False",
"fork_count": null,
"is_fork": null,
"language": null,
"license": "licensed",
"repo_id": 146510094,
"size": null,
"stargazer_count": null,
"stars": 14,
"updates": "2020-01-25T19:21:50+00:00",
"url": "https://github.com/greenplum-db/pxf... |
146510094_217 | {
"fields": [
{
"declarator": "parameters",
"modifier": "private",
"original_string": "private MultivaluedMap<String, String> parameters;",
"type": "MultivaluedMap<String, String>",
"var_name": "parameters"
},
{
"declarator": "parser",
"modifier": "private",
... | {
"body": "@Test\n public void testWireFormatIsPresentAndFormatIsInferred() {\n parameters.putSingle(\"X-GP-FORMAT\", \"GPDBWritable\");\n parameters.putSingle(\"X-GP-OPTIONS-PROFILE\", \"foo:bar\");\n RequestContext context = parser.parseRequest(mockRequestHeaders, RequestType.FRAGMENTER);\n ... | {
"fields": [
{
"declarator": "TRUE_LCASE = \"true\"",
"modifier": "private static final",
"original_string": "private static final String TRUE_LCASE = \"true\";",
"type": "String",
"var_name": "TRUE_LCASE"
},
{
"declarator": "FALSE_LCASE = \"false\"",
"modifier":... | {
"body": "@Override\n public RequestContext parseRequest(HttpHeaders request, RequestContext.RequestType requestType) {\n\n RequestMap params = new RequestMap(request.getRequestHeaders());\n\n if (LOG.isDebugEnabled()) {\n // Logging only keys to prevent sensitive data to be logged\n ... | {
"created": "8/28/2018 9:42:19 PM +00:00",
"fork": "False",
"fork_count": null,
"is_fork": null,
"language": null,
"license": "licensed",
"repo_id": 146510094,
"size": null,
"stargazer_count": null,
"stars": 14,
"updates": "2020-01-25T19:21:50+00:00",
"url": "https://github.com/greenplum-db/pxf... |
146510094_260 | {
"fields": [
{
"declarator": "context",
"modifier": "private",
"original_string": "private RequestContext context;",
"type": "RequestContext",
"var_name": "context"
},
{
"declarator": "schema",
"modifier": "private",
"original_string": "private Schema schem... | {
"body": "@Test\n public void testObtainSchema_OnWrite_WithUserProvidedSchema_Binary_FullPathToLocalFile() {\n context.setRequestType(RequestContext.RequestType.WRITE_BRIDGE);\n context.addOption(\"SCHEMA\", avroDirectory + \"user-provided.avro\");\n\n schema = avroUtilities.obtainSchema(cont... | {
"fields": [
{
"declarator": "COMMON_NAMESPACE = \"public.avro\"",
"modifier": "private static",
"original_string": "private static String COMMON_NAMESPACE = \"public.avro\";",
"type": "String",
"var_name": "COMMON_NAMESPACE"
},
{
"declarator": "fileSearcher",
"m... | {
"body": "public Schema obtainSchema(RequestContext context, Configuration configuration, HcfsType hcfsType) {\n Schema schema = (Schema) context.getMetadata();\n\n if (schema != null) {\n return schema;\n }\n try {\n schemaPath = context.getDataSource();\n ... | {
"created": "8/28/2018 9:42:19 PM +00:00",
"fork": "False",
"fork_count": null,
"is_fork": null,
"language": null,
"license": "licensed",
"repo_id": 146510094,
"size": null,
"stargazer_count": null,
"stars": 14,
"updates": "2020-01-25T19:21:50+00:00",
"url": "https://github.com/greenplum-db/pxf... |
146510094_325 | {
"fields": [
{
"declarator": "expectedException = ExpectedException.none()",
"modifier": "@Rule\n public",
"original_string": "@Rule\n public ExpectedException expectedException = ExpectedException.none();",
"type": "ExpectedException",
"var_name": "expectedException"
},
... | {
"body": "@Test\n public void invalidTableName() throws Exception {\n expectedException.expect(IllegalArgumentException.class);\n expectedException.expectMessage(\"\\\"t.r.o.u.b.l.e.m.a.k.e.r\\\" is not a valid Hive table name. Should be either <table_name> or <db_name.table_name>\");\n\n IMe... | {
"fields": [
{
"declarator": "instance = new HiveClientWrapper()",
"modifier": "private static final",
"original_string": "private static final HiveClientWrapper instance = new HiveClientWrapper();",
"type": "HiveClientWrapper",
"var_name": "instance"
},
{
"declarator"... | {
"body": "public List<Metadata.Item> extractTablesFromPattern(IMetaStoreClient client, String pattern) {\n\n String dbPattern, tablePattern;\n String errorMsg = \" is not a valid Hive table name. \"\n + \"Should be either <table_name> or <db_name.table_name>\";\n\n if (StringUtils... | {
"created": "8/28/2018 9:42:19 PM +00:00",
"fork": "False",
"fork_count": null,
"is_fork": null,
"language": null,
"license": "licensed",
"repo_id": 146510094,
"size": null,
"stargazer_count": null,
"stars": 14,
"updates": "2020-01-25T19:21:50+00:00",
"url": "https://github.com/greenplum-db/pxf... |
146510094_149 | {
"fields": [
{
"declarator": "mockContext",
"modifier": "",
"original_string": "RequestContext mockContext;",
"type": "RequestContext",
"var_name": "mockContext"
},
{
"declarator": "inputBuilder",
"modifier": "",
"original_string": "BridgeInputBuilder input... | {
"body": "@Test\n /*\n * Test the makeInput method: input > buffer size, \\n terminated\n */\n public void makeInputBigArray() throws Exception {\n\n byte[] bigArray = new byte[2000];\n for (int i = 0; i < 1999; ++i) {\n bigArray[i] = (byte) (i % 10 + 30);\n }\n b... | {
"fields": [
{
"declarator": "protocolData",
"modifier": "private final",
"original_string": "private final RequestContext protocolData;",
"type": "RequestContext",
"var_name": "protocolData"
},
{
"declarator": "LOG = LogFactory.getLog(BridgeInputBuilder.class)",
... | {
"body": "public List<OneField> makeInput(DataInput inputStream) throws Exception {\n if (protocolData.getOutputFormat() == OutputFormat.TEXT) {\n // Avoid copying the bytes from the inputStream directly. This\n // code used to use the Text class to read bytes until a line\n /... | {
"created": "8/28/2018 9:42:19 PM +00:00",
"fork": "False",
"fork_count": null,
"is_fork": null,
"language": null,
"license": "licensed",
"repo_id": 146510094,
"size": null,
"stargazer_count": null,
"stars": 14,
"updates": "2020-01-25T19:21:50+00:00",
"url": "https://github.com/greenplum-db/pxf... |
146510094_15 | {
"fields": [],
"file": "server/pxf-api/src/test/java/org/greenplum/pxf/api/model/BasePluginTest.java",
"identifier": "BasePluginTest",
"interfaces": "",
"superclass": ""
} | {
"body": "@Test\n public void testInitialize() {\n ConfigurationFactory mockConfigurationFactory = mock(ConfigurationFactory.class);\n\n Configuration configuration = new Configuration();\n RequestContext context = new RequestContext();\n\n when(mockConfigurationFactory.\n ... | {
"fields": [
{
"declarator": "configurationFactory",
"modifier": "protected",
"original_string": "protected ConfigurationFactory configurationFactory;",
"type": "ConfigurationFactory",
"var_name": "configurationFactory"
},
{
"declarator": "LOG = LoggerFactory.getLogger... | {
"body": "@Override\n public void initialize(RequestContext requestContext) {\n this.context = requestContext;\n this.configuration = configurationFactory.\n initConfiguration(context.getConfig(), context.getServerName(), context.getUser(), context.getAdditionalConfigProps());\n ... | {
"created": "8/28/2018 9:42:19 PM +00:00",
"fork": "False",
"fork_count": null,
"is_fork": null,
"language": null,
"license": "licensed",
"repo_id": 146510094,
"size": null,
"stargazer_count": null,
"stars": 14,
"updates": "2020-01-25T19:21:50+00:00",
"url": "https://github.com/greenplum-db/pxf... |
146510094_237 | {
"fields": [
{
"declarator": "PRUNER = new SupportedOperatorPruner(SUPPORTED_OPERATORS)",
"modifier": "private static final",
"original_string": "private static final TreeVisitor PRUNER = new SupportedOperatorPruner(SUPPORTED_OPERATORS);",
"type": "TreeVisitor",
"var_name": "PRUNER"... | {
"body": "@Test\n public void testNestedLogicalOperators() throws Exception {\n // cdate > '2008-02-01' OR (cdate < '2008-12-01' AND amt > 1200)\n Filter filter = helper(\"a1c1082s10d2008-02-01o2a1c1082s10d2008-12-01o1a0c23s4d1200o2l0l1\", tupleDescription);\n assertNotNull(filter);\n ... | {
"fields": [
{
"declarator": "OPERATORS_MAP =\n Collections.unmodifiableMap(new HashMap<Operator, CompareFilter.CompareOp>() {{\n put(Operator.LESS_THAN, CompareFilter.CompareOp.LESS); // \"<\"\n put(Operator.GREATER_THAN, CompareFilter.CompareOp.GREATER); // \">\"\... | {
"body": "private ByteArrayComparable getComparator(int type, OperandNode data) {\n ByteArrayComparable result;\n switch (DataType.get(type)) {\n case TEXT:\n result = new BinaryComparator(Bytes.toBytes(data.toString()));\n break;\n case SMALLINT:\n ... | {
"created": "8/28/2018 9:42:19 PM +00:00",
"fork": "False",
"fork_count": null,
"is_fork": null,
"language": null,
"license": "licensed",
"repo_id": 146510094,
"size": null,
"stargazer_count": null,
"stars": 14,
"updates": "2020-01-25T19:21:50+00:00",
"url": "https://github.com/greenplum-db/pxf... |
146510094_372 | {
"fields": [
{
"declarator": "thrown = ExpectedException.none()",
"modifier": "@Rule\n public",
"original_string": "@Rule\n public ExpectedException thrown = ExpectedException.none();",
"type": "ExpectedException",
"var_name": "thrown"
},
{
"declarator": "dbProdu... | {
"body": "@Test\n public void testRightBoundedInclusive() {\n IntPartition partition = new IntPartition(COL_RAW, null, 0L);\n String constraint = partition.toSqlConstraint(QUOTE, dbProduct);\n\n assertEquals(COL + \" < 0\", constraint);\n }",
"class_method_signature": "IntPartitionTest.t... | {
"fields": [
{
"declarator": "serialVersionUID = 0L",
"modifier": "private static final",
"original_string": "private static final long serialVersionUID = 0L;",
"type": "long",
"var_name": "serialVersionUID"
},
{
"declarator": "boundaries",
"modifier": "private f... | {
"body": "@Override\n public String toSqlConstraint(String quoteString, DbProduct dbProduct) {\n if (quoteString == null) {\n throw new RuntimeException(\"Quote string cannot be null\");\n }\n\n return generateRangeConstraint(\n quoteString + column + quoteString,\n ... | {
"created": "8/28/2018 9:42:19 PM +00:00",
"fork": "False",
"fork_count": null,
"is_fork": null,
"language": null,
"license": "licensed",
"repo_id": 146510094,
"size": null,
"stargazer_count": null,
"stars": 14,
"updates": "2020-01-25T19:21:50+00:00",
"url": "https://github.com/greenplum-db/pxf... |
146510094_42 | {
"fields": [],
"file": "server/pxf-api/src/test/java/org/greenplum/pxf/api/filter/CollectionOperandNodeTest.java",
"identifier": "CollectionOperandNodeTest",
"interfaces": "",
"superclass": ""
} | {
"body": "@Test\n public void testToString() {\n List<String> data = new ArrayList<>();\n data.add(\"s\");\n CollectionOperandNode operand = new CollectionOperandNode(DataType.INTEGER, data);\n\n assertEquals(\"(s)\", operand.toString());\n\n data.add(\"t\");\n operand = ... | {
"fields": [
{
"declarator": "data",
"modifier": "private final",
"original_string": "private final List<String> data;",
"type": "List<String>",
"var_name": "data"
}
],
"file": "server/pxf-api/src/main/java/org/greenplum/pxf/api/filter/CollectionOperandNode.java",
"identif... | {
"body": "@Override\n public String toString() {\n return String.format(\"(%s)\", String.join(\",\", data));\n }",
"class_method_signature": "CollectionOperandNode.toString()",
"constructor": false,
"full_signature": "@Override public String toString()",
"identifier": "toString",
"invocations"... | {
"created": "8/28/2018 9:42:19 PM +00:00",
"fork": "False",
"fork_count": null,
"is_fork": null,
"language": null,
"license": "licensed",
"repo_id": 146510094,
"size": null,
"stargazer_count": null,
"stars": 14,
"updates": "2020-01-25T19:21:50+00:00",
"url": "https://github.com/greenplum-db/pxf... |
146510094_221 | {
"fields": [
{
"declarator": "parameters",
"modifier": "private",
"original_string": "private MultivaluedMap<String, String> parameters;",
"type": "MultivaluedMap<String, String>",
"var_name": "parameters"
},
{
"declarator": "parser",
"modifier": "private",
... | {
"body": "@Test\n public void testHandlerIsCalled() {\n when(mockPluginConf.getHandler(\"test-profile\")).thenReturn(TestHandler.class.getName());\n parameters.putSingle(\"X-GP-OPTIONS-PROFILE\", \"test-profile\");\n RequestContext context = parser.parseRequest(mockRequestHeaders, RequestType... | {
"fields": [
{
"declarator": "TRUE_LCASE = \"true\"",
"modifier": "private static final",
"original_string": "private static final String TRUE_LCASE = \"true\";",
"type": "String",
"var_name": "TRUE_LCASE"
},
{
"declarator": "FALSE_LCASE = \"false\"",
"modifier":... | {
"body": "@Override\n public RequestContext parseRequest(HttpHeaders request, RequestContext.RequestType requestType) {\n\n RequestMap params = new RequestMap(request.getRequestHeaders());\n\n if (LOG.isDebugEnabled()) {\n // Logging only keys to prevent sensitive data to be logged\n ... | {
"created": "8/28/2018 9:42:19 PM +00:00",
"fork": "False",
"fork_count": null,
"is_fork": null,
"language": null,
"license": "licensed",
"repo_id": 146510094,
"size": null,
"stargazer_count": null,
"stars": 14,
"updates": "2020-01-25T19:21:50+00:00",
"url": "https://github.com/greenplum-db/pxf... |
146510094_364 | {
"fields": [],
"file": "server/pxf-jdbc/src/test/java/org/greenplum/pxf/plugins/jdbc/utils/HiveJdbcUtilsTest.java",
"identifier": "HiveJdbcUtilsTest",
"interfaces": "",
"superclass": ""
} | {
"body": "@Test\n public void testImpersonationPropertyAfterQuestionMark() throws Exception {\n String url = \"jdbc:hive2://server:10000/default?questionMarkProperty=questionMarkValue;hive.server2.proxy.user=bar\";\n assertEquals(\"jdbc:hive2://server:10000/default;hive.server2.proxy.user=foo?questi... | {
"fields": [
{
"declarator": "HIVE_URL_IMPERSONATION_PROPERTY = \";hive.server2.proxy.user\"",
"modifier": "private static final",
"original_string": "private static final String HIVE_URL_IMPERSONATION_PROPERTY = \";hive.server2.proxy.user\";",
"type": "String",
"var_name": "HIVE_UR... | {
"body": "public static String updateImpersonationPropertyInHiveJdbcUrl(String url, String user) {\n String suffix, prefix = null;\n int terminatorIndex = findTerminatorIndex(url, 0, TERMINATORS_TWO_CHARS);\n\n // impersonation property might already be in the URL\n int impersonationPrope... | {
"created": "8/28/2018 9:42:19 PM +00:00",
"fork": "False",
"fork_count": null,
"is_fork": null,
"language": null,
"license": "licensed",
"repo_id": 146510094,
"size": null,
"stargazer_count": null,
"stars": 14,
"updates": "2020-01-25T19:21:50+00:00",
"url": "https://github.com/greenplum-db/pxf... |
146510094_108 | {
"fields": [
{
"declarator": "serverName",
"modifier": "private",
"original_string": "private String serverName;",
"type": "String",
"var_name": "serverName"
},
{
"declarator": "configuration",
"modifier": "private",
"original_string": "private Configuratio... | {
"body": "@Test\n public void testReloginFromKeytabNoopInsufficientTimeElapsed() throws KerberosAuthException {\n user.setLogin(mockLoginContext);\n PowerMockito.mockStatic(KerberosUtil.class);\n when(KerberosUtil.hasKerberosKeyTab(subject)).thenReturn(true);\n ugi = new UserGroupInfor... | {
"fields": [
{
"declarator": "LOGIN_FAILURE = \"Login failure\"",
"modifier": "private static final",
"original_string": "private static final String LOGIN_FAILURE = \"Login failure\";",
"type": "String",
"var_name": "LOGIN_FAILURE"
},
{
"declarator": "LOG = LoggerFact... | {
"body": "public static void reloginFromKeytab(String serverName, LoginSession loginSession) throws KerberosAuthException {\n\n UserGroupInformation ugi = loginSession.getLoginUser();\n\n if (ugi.getAuthenticationMethod() != UserGroupInformation.AuthenticationMethod.KERBEROS ||\n !ugi.is... | {
"created": "8/28/2018 9:42:19 PM +00:00",
"fork": "False",
"fork_count": null,
"is_fork": null,
"language": null,
"license": "licensed",
"repo_id": 146510094,
"size": null,
"stargazer_count": null,
"stars": 14,
"updates": "2020-01-25T19:21:50+00:00",
"url": "https://github.com/greenplum-db/pxf... |
146510094_54 | {
"fields": [],
"file": "server/pxf-api/src/test/java/org/greenplum/pxf/api/filter/ToStringTreeVisitorTest.java",
"identifier": "ToStringTreeVisitorTest",
"interfaces": "",
"superclass": ""
} | {
"body": "@Test\n public void testReset() throws Exception {\n String filterString = \"a1c25s10d2016-01-03o4\";\n Node root = new FilterParser().parse(filterString);\n\n ToStringTreeVisitor visitor = new ToStringTreeVisitor();\n new TreeTraverser().traverse(root, visitor);\n\n a... | {
"fields": [
{
"declarator": "sb = new StringBuilder()",
"modifier": "private final",
"original_string": "private final StringBuilder sb = new StringBuilder();",
"type": "StringBuilder",
"var_name": "sb"
}
],
"file": "server/pxf-api/src/main/java/org/greenplum/pxf/api/filter... | {
"body": "public void reset() {\n sb.setLength(0);\n }",
"class_method_signature": "ToStringTreeVisitor.reset()",
"constructor": false,
"full_signature": "public void reset()",
"identifier": "reset",
"invocations": [
"setLength"
],
"modifiers": "public",
"parameters": "()",
"return": ... | {
"created": "8/28/2018 9:42:19 PM +00:00",
"fork": "False",
"fork_count": null,
"is_fork": null,
"language": null,
"license": "licensed",
"repo_id": 146510094,
"size": null,
"stargazer_count": null,
"stars": 14,
"updates": "2020-01-25T19:21:50+00:00",
"url": "https://github.com/greenplum-db/pxf... |
146510094_276 | {
"fields": [
{
"declarator": "context",
"modifier": "",
"original_string": "RequestContext context;",
"type": "RequestContext",
"var_name": "context"
}
],
"file": "server/pxf-hdfs/src/test/java/org/greenplum/pxf/plugins/hdfs/StringPassResolverTest.java",
"identifier": "Str... | {
"body": "@Test\n /*\n * Test the setFields method: empty byte array\n */\n public void testSetFieldsEmptyByteArray() throws Exception {\n\n StringPassResolver resolver = buildResolver();\n\n byte[] empty = new byte[0];\n\n List<OneField> record = Collections.singletonList(new OneF... | {
"fields": [
{
"declarator": "oneRow = new OneRow()",
"modifier": "private final",
"original_string": "private final OneRow oneRow = new OneRow();",
"type": "OneRow",
"var_name": "oneRow"
},
{
"declarator": "resolveWriteCount = 0",
"modifier": "private",
"o... | {
"body": "@Override\n public OneRow setFields(List<OneField> record) {\n OneField oneField = record.get(0);\n\n if ((oneField.val instanceof InputStream && resolveWriteCount > 0) ||\n (oneField.val instanceof byte[] && ((byte[]) oneField.val).length == 0)) {\n // For the in... | {
"created": "8/28/2018 9:42:19 PM +00:00",
"fork": "False",
"fork_count": null,
"is_fork": null,
"language": null,
"license": "licensed",
"repo_id": 146510094,
"size": null,
"stargazer_count": null,
"stars": 14,
"updates": "2020-01-25T19:21:50+00:00",
"url": "https://github.com/greenplum-db/pxf... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.