query
stringlengths 7
33.1k
| document
stringlengths 7
335k
| metadata
dict | negatives
sequencelengths 3
101
| negative_scores
sequencelengths 3
101
| document_score
stringlengths 3
10
| document_rank
stringclasses 102
values |
---|---|---|---|---|---|---|
Called when a key is pressed on the keyboard providing this Widget has the focus. | public abstract void keyPressed(KeyPressedEvent keyPressedEvent); | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@Override public void keyPressed(KeyEvent e)\n {\n // Delegate key press events to the focused component\n if (this.focusedComponent != null)\n this.focusedComponent.executeEvent(new KeyPressEvent(e.getKey(),e.getKeyCode()));\n }",
"@Override\n public void keyPressed(KeyEvent key) {\n gsm.keyPressed(key.getKeyCode());\n }",
"public void keyPressed(KeyEvent e) {}",
"public void onKeyPress(Widget sender, char keyCode, int modifiers) {\n }",
"public void keyPressed(int keyCode) {\n //CR 14694\n if (itemFocused == UISettings.CAPTURE_IMAGE) { //14418\n iCaptureImage.keyPressed(keyCode);\n } else if(itemFocused == UISettings.IMAGE_MENU){ //CR 14694\n handleImageMenu(keyCode);\n } else if (itemFocused == UISettings.MENU) {\n handleMenu(keyCode);\n } else if (itemFocused == UISettings.BANNER) {\n bannerHandler.handleBanner(keyCode);\n } \n //#if KEYPAD\n //|JG| else if (itemFocused == UISettings.RENAMETEXTBOX) {\n //|JG| handleRenameTextbox(keyCode);\n //|JG| }\n //#endif\n else if(itemFocused == UISettings.POPUPSCREN){\n iCustomPopup.keyPressed(keyCode);\n }\n }",
"@Override\r\n\tpublic void keyPressed(KeyEvent key) {\r\n\t\t// Invoke method if the key is pressed. \r\n\t\t// Do nothing, not all three methods need to be used. \r\n\t}",
"@Override\r\n\t\t\tpublic void keyPressed(KeyEvent arg0) {\n\t\t\t}",
"@Override\n public void onKeyPressed(KeyEvent event) {\n }",
"@Override\r\n\tpublic void keyPressed(KeyEvent keyPressed)\r\n\t{\r\n\t\t\r\n\t}",
"public void keyPressed(KeyEvent e) {\n \n }",
"public void keyPressed(KeyEvent e) {\n \n }",
"public void keyPressed(KeyEvent e) {\n \n }",
"boolean onKeyPressed(KeyEvent event);",
"public void keyPressed(KeyEvent arg0) {\n\t\t\t\t\n\t\t\t}",
"public void keyPressed(KeyEvent arg0) {\n\t\t\t\t\n\t\t\t}",
"public void keyPressed(KeyEvent arg0) {\n\t\t\t\t\n\t\t\t}",
"public void keyPressed(KeyEvent arg0) {\n\t\t\t\t\n\t\t\t}",
"@Override\n\t\t\t\tpublic void keyPressed(KeyEvent arg0)\n\t\t\t\t{\n\t\t\t\t\t\n\t\t\t\t}",
"@Override\n\t\tpublic void keyPressed(KeyEvent arg0) {\n\t\t\t\n\t\t}",
"@Override\r\n\tpublic void keyPressed(KeyEvent arg0) {\r\n\t}",
"@Override\n\t\t\tpublic void keyPressed(KeyEvent arg0) {\n\t\t\t\t\n\t\t\t}",
"public void keyPressed() {\r\n \t\tkeys[keyCode] = true;\r\n \t}",
"@Override public void keyTyped(KeyEvent e)\n {\n if (this.focusedComponent != null)\n this.focusedComponent.executeEvent(new KeyTypeEvent(e.getKey(),e.getKeyCode()));\n }",
"public void keyPressed( KeyEvent e ) { }",
"@Override\r\n public void keyPressed(KeyEvent ke) {\n }",
"@Override\r\n\t\t\tpublic void keyPressed(KeyEvent arg0)\r\n\t\t\t{\n\t\t\t\t\r\n\t\t\t}",
"public void keyReleased(KeyEvent ke){}",
"@Override\n public void keyboardAction( KeyEvent ke )\n {\n \n }",
"public void keyPressed() { \n\t\twantsFrameBreak = true;\n\t\t//key = e.getKeyChar();\n\t\tkeyPressed = true;\n\t\tif (System.nanoTime() - acted > .033e9f) {\n\t\t\t_keyPressed();\n\t\t}\n\t}",
"@Override\n public void triggerKeyRelease(KeyEvent e) {\n\n }",
"@Override\n\tpublic void keyPressed(KeyEvent arg0) {\n\n\t}",
"@Override\n\tpublic void keyPressed(KeyEvent arg0) {\n\n\t}",
"@Override\n\tpublic void keyPressed(KeyEvent arg0) {\n\n\t}",
"@Override\n\tpublic void keyPressed(KeyEvent arg0) {\n\n\t}",
"public void keyPressed(KeyEvent e) {\n }",
"@Override\r\n\tpublic void keyPressed(KeyEvent arg0) {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void keyPressed(KeyEvent arg0) {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void keyPressed(KeyEvent arg0) {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void keyPressed(KeyEvent arg0) {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void keyPressed(KeyEvent arg0) {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void keyTyped(KeyEvent key) {\r\n\t\t/** Gets the typed character. If it's not typed on the text field, \r\n\t\t * this method will not be invoked. */\r\n\t\tchar typedKey = key.getKeyChar();\r\n\t\tkeyLabel.setText(\"You pressed \" + typedKey + \". \");\r\n\t}",
"@Override\n\tpublic void keyPressed(KeyEvent arg0) {\n\t\t\n\t}",
"@Override\n\tpublic void keyPressed(KeyEvent arg0) {\n\t\t\n\t}",
"@Override\n\tpublic void keyPressed(KeyEvent arg0) {\n\t\t\n\t}",
"@Override\n\tpublic void keyPressed(KeyEvent arg0) {\n\t\t\n\t}",
"@Override\n public void keyPressed(KeyEvent e) {}",
"public void keyPressed() {\n\t ackEvent();\n if (key == ' ') {\n pauseTic = !pauseTic;\n EventQueue.getInstance().togglePause();\n }\n if (key == '.') {\n EventQueue.getInstance().beginEvents();\n } else if (key == '\\n') {\n if (pauseTic) { //only let this run if the display is paused\n StringManager.getInstance().ticAllOneCycle();\n }\n }else KeyMap.getInstance().run(key);\n }",
"void keyPressed(int keyCode);",
"@Override\r\n\tpublic boolean onKeyDown(int keyCode, KeyEvent event) {\n\t\treturn super.onKeyDown(keyCode, event);\r\n\t}",
"@Override\n\tpublic void keyPressed(KeyEvent arg0)\n\t{\n\t\t\n\t}",
"public void keyTyped(KeyEvent e) {}",
"public void keyPressed(KeyEvent ke) {\n\t\t}",
"@Override\n public void keyTyped(KeyEvent key) {\n gsm.keyTyped(key.getKeyCode());\n }",
"@Override\n\tpublic boolean onKeyDown(int keyCode, KeyEvent event) {\n\t\treturn super.onKeyDown(keyCode, event);\n\t}",
"public void keyPressed(KeyEvent e) {\n\t\t\t\t\t}",
"public void keyReleased(KeyEvent e) {}",
"public void keyReleased(KeyEvent e) {}",
"public void keyReleased(KeyEvent e) {}",
"public abstract void keyPressed(int key);",
"@Override\n public boolean onKeyDown(int keyCode, KeyEvent event) {\n return super.onKeyDown(keyCode, event);\n }",
"public boolean keyPressed(KeyEvent e);",
"public void keyPressed(KeyEvent e) {\n\t\t\t\t}",
"public void keyPressed(KeyEvent e) {\n\t\t\t\t}",
"public void keyPressed(KeyEvent e) {\n\t\t\t\t}",
"public void keyReleased(KeyEvent arg0) {}",
"public void keyTyped( KeyEvent event )\n {}",
"@Override public void keyReleased(KeyEvent e)\n {\n if (this.focusedComponent != null)\n this.focusedComponent.executeEvent(new KeyReleaseEvent(e.getKey(),e.getKeyCode()));\n }",
"public void keyPressed(KeyEvent e) { }",
"void keyPressed(int keycode);",
"@Override\n public void keyReleased(KeyEvent arg0) {\n\n }",
"@Override\r\n public void keyPressed(KeyEvent e) {\n }",
"public abstract void keyPressed(int k);",
"public void keyReleased(KeyEvent e){}",
"public void keyTyped(KeyEvent e){}",
"@Override\r\n public void keyTyped(KeyEvent ke) {\r\n }",
"public void keyReleased (KeyEvent e){}",
"void keyPress(int key);",
"public void keyTyped (KeyEvent e) { }",
"@Override\n\tpublic void keyTyped(final KeyEvent arg0) {\n\t\t\n\t}",
"@Override\r\n\tpublic void keyReleased(KeyEvent key) {\r\n\t\t// Invoke method if the key is released. \r\n\t\t// Do nothing, not all three methods need to be used. \r\n\t}",
"@Override\r\n public void keyPressed(KeyEvent e) {\r\n\r\n }",
"@Override\n public void keyTyped(KeyEvent ke) {\n \n }",
"public void keyPressed(KeyEvent arg0) {\n\r\n\t}",
"@Override\r\n\tpublic void keyReleased(KeyEvent arg0) {\n\t}",
"@Override\n public void keyPressed(KeyEvent e) {\n }",
"@Override\r\n\t\t\tpublic void keyTyped(KeyEvent arg0) {\n\t\t\t\t\r\n\t\t\t}",
"@Override\r\n\tpublic void keyPressed() {\n\t\tl.key();\r\n\t\t\r\n\t}",
"@Override\n public void keyPressed(KeyEvent e) {\n }",
"@Override\n public void keyPressed(KeyEvent e) {\n }",
"@Override\n public void keyPressed(KeyEvent e) {\n }",
"@Override\n public void keyPressed(KeyEvent e) {\n }",
"@Override\n public void keyPressed(KeyEvent e) {\n }",
"@Override\n public void keyPressed(KeyEvent e) {\n }",
"@Override\n public void keyPressed(KeyEvent e) {\n }",
"@Override\n public void keyPressed(KeyEvent e) {\n }",
"public void onKeyUp(Widget sender, char keyCode, int modifiers) {\n }",
"@Override\r\n public void keyPressed(KeyEvent e) {\n \r\n }",
"@Override\n\t\t\tpublic void keyPressed(KeyEvent e) {\n\n\t\t\t}",
"@Override\n\t\t\tpublic void keyPressed(KeyEvent e) {\n\n\t\t\t}",
"@Override\n\t\t\tpublic void keyPressed(KeyEvent e) {\n\n\t\t\t}"
] | [
"0.6988586",
"0.6943482",
"0.6920989",
"0.6882613",
"0.68567014",
"0.68267953",
"0.6793777",
"0.6787212",
"0.67813987",
"0.67689407",
"0.67689407",
"0.67689407",
"0.6767135",
"0.67380106",
"0.67380106",
"0.67380106",
"0.67380106",
"0.6734918",
"0.6728971",
"0.6717455",
"0.6713526",
"0.6701989",
"0.67019266",
"0.6696323",
"0.66948444",
"0.66922134",
"0.66902435",
"0.6687143",
"0.6676251",
"0.66672236",
"0.6644222",
"0.6644222",
"0.6644222",
"0.6644222",
"0.66283613",
"0.6622304",
"0.6622304",
"0.6622304",
"0.6622304",
"0.6622304",
"0.66125935",
"0.66055036",
"0.66055036",
"0.66055036",
"0.66055036",
"0.65954596",
"0.65840334",
"0.6573699",
"0.6573211",
"0.65655035",
"0.65640986",
"0.65622705",
"0.65535396",
"0.65388083",
"0.6538541",
"0.65369296",
"0.65369296",
"0.65369296",
"0.6532683",
"0.6531311",
"0.65312856",
"0.6525523",
"0.6525523",
"0.6525523",
"0.6513026",
"0.65101063",
"0.6502221",
"0.6501465",
"0.64827114",
"0.64795333",
"0.64767694",
"0.6475256",
"0.6456128",
"0.64548105",
"0.64532804",
"0.6450839",
"0.6449978",
"0.6443186",
"0.64430517",
"0.64396167",
"0.6436371",
"0.64343166",
"0.6432746",
"0.6430524",
"0.6425152",
"0.6413723",
"0.64104646",
"0.6409963",
"0.6409963",
"0.6409963",
"0.6409963",
"0.6409963",
"0.6409963",
"0.6409963",
"0.6409963",
"0.6403987",
"0.64029294",
"0.6399588",
"0.6399588",
"0.6399588"
] | 0.659782 | 45 |
Called when a previously pressed key on the keyboard is released, providing this Widget has the focus. | public abstract void keyReleased(KeyReleasedEvent keyReleasedEvent); | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@Override public void keyReleased(KeyEvent e)\n {\n if (this.focusedComponent != null)\n this.focusedComponent.executeEvent(new KeyReleaseEvent(e.getKey(),e.getKeyCode()));\n }",
"public void keyReleased(KeyEvent ke){}",
"public void keyReleased() {\t\t\r\n \t\t\r\n \t\tkeys[keyCode] = false;\r\n \t}",
"public void keyReleased (KeyEvent e)\r\n {\r\n \tkeyPressed = false;\r\n \tkeyReleased = true;\r\n \tkey = 0;\r\n }",
"public void keyReleased(KeyEvent arg0) {}",
"@Override\n \t\t\tpublic void keyReleased(KeyEvent arg0) {\n \t\t\t\t\n \t\t\t}",
"public void keyReleased(KeyEvent e) {}",
"public void keyReleased(KeyEvent e) {}",
"public void keyReleased(KeyEvent e) {}",
"@Override\r\n\t\t\tpublic void keyReleased(KeyEvent arg0) {\n\t\t\t\t\r\n\t\t\t}",
"@Override\n\t\tpublic void keyReleased(KeyEvent arg0) {\n\t\t\t\n\t\t}",
"@Override\n public void keyReleased(KeyEvent keyEvent) {\n\n b.keyReleased(keyEvent);\n }",
"@Override\n\t\t\t\t\t\tpublic void keyReleased(KeyEvent arg0) {\n\n\t\t\t\t\t\t}",
"@Override\n\t\t\t\t\t\tpublic void keyReleased(KeyEvent arg0) {\n\n\t\t\t\t\t\t}",
"@Override\n\t\t\t\t\t\tpublic void keyReleased(KeyEvent arg0) {\n\n\t\t\t\t\t\t}",
"@Override\n\t\t\t\t\t\tpublic void keyReleased(KeyEvent arg0) {\n\n\t\t\t\t\t\t}",
"@Override\n\t\t\t\t\t\tpublic void keyReleased(KeyEvent arg0) {\n\n\t\t\t\t\t\t}",
"@Override\n\t\t\t\t\t\tpublic void keyReleased(KeyEvent arg0) {\n\n\t\t\t\t\t\t}",
"@Override\n\t\t\t\t\t\tpublic void keyReleased(KeyEvent arg0) {\n\n\t\t\t\t\t\t}",
"@Override\n\t\t\t\t\tpublic void keyReleased(KeyEvent arg0) {\n\n\t\t\t\t\t}",
"@Override\n\t\t\t\t\tpublic void keyReleased(KeyEvent arg0) {\n\n\t\t\t\t\t}",
"@Override\n\t\t\tpublic void keyReleased(KeyEvent arg0)\n\t\t\t{\n\t\t\t\t\n\t\t\t}",
"@Override\n public void keyReleased(KeyEvent key) {\n gsm.keyReleased(key.getKeyCode());\n }",
"public final void stop() {\n isKeyPressed = false;\n keyReleased();\n }",
"@Override\r\n\tpublic void keyReleased(KeyEvent arg0) {\n\t}",
"@Override\r\n\tpublic void keyReleased(KeyEvent arg0) {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void keyReleased(KeyEvent arg0) {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void keyReleased(KeyEvent arg0) {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void keyReleased(KeyEvent arg0) {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void keyReleased(KeyEvent arg0) {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void keyReleased(KeyEvent arg0) {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void keyReleased(KeyEvent arg0) {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void keyReleased(KeyEvent arg0) {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void keyReleased(KeyEvent arg0) {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void keyReleased(KeyEvent arg0) {\n\t\t\r\n\t}",
"@Override\n\t\t\tpublic void keyReleased(KeyEvent arg0) {\n\t\t\t\t\n\t\t\t}",
"@Override\n\t\t\tpublic void keyReleased(KeyEvent arg0) {\n\t\t\t\t\n\t\t\t}",
"@Override\n\t\t\tpublic void keyReleased(KeyEvent arg0) {\n\t\t\t\t\n\t\t\t}",
"@Override\n\t\t\tpublic void keyReleased(KeyEvent arg0) {\n\t\t\t\t\n\t\t\t}",
"@Override\n\t\t\tpublic void keyReleased(KeyEvent arg0) {\n\t\t\t\t\n\t\t\t}",
"@Override\r\n\tpublic void keyReleased(KeyEvent key) {\r\n\t\t// Invoke method if the key is released. \r\n\t\t// Do nothing, not all three methods need to be used. \r\n\t}",
"public void keyReleased(KeyEvent e){}",
"@Override\n\tpublic void keyReleased(KeyEvent arg0)\n\t{\n\t\t\n\t}",
"@Override\n\tpublic void keyReleased(KeyEvent arg0) {\n\n\t}",
"@Override\n\tpublic void keyReleased(KeyEvent arg0) {\n\n\t}",
"@Override\n\tpublic void keyReleased(KeyEvent arg0) {\n\n\t}",
"@Override\n\tpublic void keyReleased(KeyEvent arg0) {\n\n\t}",
"@Override\n\tpublic void keyReleased(KeyEvent arg0) {\n\n\t}",
"@Override\r\n\t\t\tpublic void keyReleased(KeyEvent arg0) {\n\r\n\t\t\t}",
"public void keyReleased (KeyEvent e){}",
"@Override\n\tpublic void keyReleased(KeyEvent arg0) {\n\t\t\n\t}",
"@Override\n\tpublic void keyReleased(KeyEvent arg0) {\n\t\t\n\t}",
"@Override\n\tpublic void keyReleased(KeyEvent arg0) {\n\t\t\n\t}",
"@Override\n\tpublic void keyReleased(KeyEvent arg0) {\n\t\t\n\t}",
"@Override\n\tpublic void keyReleased(KeyEvent arg0) {\n\t\t\n\t}",
"@Override\n\tpublic void keyReleased(KeyEvent arg0) {\n\t\t\n\t}",
"@Override\n\tpublic void keyReleased(KeyEvent arg0) {\n\t\t\n\t}",
"@Override\n\tpublic void keyReleased(KeyEvent arg0) {\n\t\t\n\t}",
"@Override\n\tpublic void keyReleased(KeyEvent arg0) {\n\t\t\n\t}",
"@Override\n public void keyReleased(KeyEvent e) {\n\n keyPressed[e.getKeyCode()] = false;\n\n updateFlags();\n\n }",
"public void setKeyReleased(int keyCode){\n this.keys[keyCode] = false;\n\n }",
"@Override\n\tpublic void keyReleased(KeyEvent arg0) {\n\t\t\t\n\t}",
"@Override\n public void keyReleased(KeyEvent arg0) {\n\n }",
"public void keyReleased() {\n ticker.stop();\n }",
"@Override\n\tpublic void keyReleased(int k) {\n\n\t}",
"public void keyReleased(KeyEvent ke) {\n\t\t}",
"@Override\r\n\tpublic void keyReleased(KeyEvent arg0) {\n\t\tcdx = 0;\r\n\t}",
"@Override\n public void triggerKeyRelease(KeyEvent e) {\n\n }",
"@Override\n public void keyReleased(KeyEvent e) {}",
"@Override\r\n public void keyReleased(KeyEvent e) {\r\n switchKey(e.getKeyCode(), false);\r\n }",
"public void keyReleased (KeyEvent arg0) {\n\t}",
"@Override\n\tpublic void onKeyRelease(KeyEvent e) {\n\t\t\n\t}",
"@Override\n\tpublic void keyReleased(int key) {\n\t\tif (key == input.KEY_SPACE) {\n\t\t\tmain.closeScene();\n\t\t\tmain.closeScene();\n\t\t}\n\t}",
"@Override\n\tpublic void keyReleased(KeyEvent ke) {\n\t\tif (ke.getKeyCode() == KeyEvent.VK_ESCAPE) {\n\t\t\tdExit.setVisible(true);\n\t\t}\n\t}",
"@Override\r\n\tpublic void keyReleased(int key, char c)\r\n\t{\n\t\t\r\n\t}",
"public void keyReleased(KeyEvent arg0) {\n\n }",
"public void keyReleased(KeyEvent e)\n {\n \n }",
"@Override\n public void keyReleased(KeyEvent event) {\n }",
"public void keyReleased(KeyEvent arg0) {\n\r\n\t}",
"public void keyReleased(KeyEvent e) \r\n {\r\n \tkeyUser = 0;\r\n }",
"@Override\r\n public void keyReleased(KeyEvent e)\r\n {\n }",
"@Override\n\tpublic void nativeKeyReleased(NativeKeyEvent arg0) {\n\n\t}",
"public void keyReleased(KeyEvent arg0) {\n\t\n}",
"@Override\n\tpublic void onBackKeyPressed() {\n\t\treturn;\n\t}",
"public void keyReleased(KeyEvent e) {\n\t}",
"@Override public void keyPressed(KeyEvent e) {\r\n keyReleaseOccured(e);\r\n if ((getControl() == null) || getControl().isDisposed()) {\r\n return;\r\n }\r\n }",
"@Override\r\n public void keyReleased(KeyEvent e) {\n }",
"@Override\r\n public void keyReleased(KeyEvent e) {\r\n }",
"@Override\r\n\tpublic void keyReleased(KeyEvent arg0) {\n\t\tactionPerformed(null);\r\n\t}",
"@Override\n public boolean onKeyPreIme(int keyCode, KeyEvent event) {\n if (keyCode == KEYCODE_BACK) clearFocus();\n return super.onKeyPreIme(keyCode, event);\n }",
"public void keyReleased(KeyEvent e){\n\t\t\tboolean transferKey = e.getKeyCode() == KeyEvent.VK_ESCAPE\n\t\t\t\t\t\t\t || e.getKeyCode() == KeyEvent.VK_ENTER;\n\t\t\tif(transferKey) field.transferFocus();\n\t\t}",
"@Override\r\n public void keyReleased(KeyEvent e) {\r\n StateForm state = StateForm.EMPTY;\r\n\r\n if (_nameText.getCharCount() > 0 && _numberGroupText.getCharCount() > 0) {\r\n state = StateForm.FILLED;\r\n }\r\n _stateService.setState(state);\r\n _stateService.runEvent();\r\n }",
"public void keyBackIsPressed(){}",
"public void keyReleased(KeyEvent e) {\n\t\t\t\t\n\t\t\t}",
"public void keyReleased(KeyEvent e) {\n\t\t\t\t\n\t\t\t}",
"@Override\r\n\tpublic void keyReleased(KeyEvent arg0) {\n\t\tctrl = false;\r\n\t}",
"@Override\n public void keyReleased(KeyEvent e) {\n }",
"@Override\n public void keyReleased(KeyEvent e) {\n }",
"@Override\n public void keyReleased(KeyEvent e) {\n }",
"public void keyReleased(KeyEvent e)\t\n\t{\n\t}"
] | [
"0.70240355",
"0.7010234",
"0.68699265",
"0.67958933",
"0.67581964",
"0.67496306",
"0.6731021",
"0.6731021",
"0.6731021",
"0.6729777",
"0.67280793",
"0.6724008",
"0.67095834",
"0.67095834",
"0.67095834",
"0.67095834",
"0.67095834",
"0.67095834",
"0.67095834",
"0.67055994",
"0.67055994",
"0.668905",
"0.66883975",
"0.6687977",
"0.6679601",
"0.66661066",
"0.66661066",
"0.66661066",
"0.66661066",
"0.66661066",
"0.66661066",
"0.66661066",
"0.66661066",
"0.66661066",
"0.66661066",
"0.6663872",
"0.6663872",
"0.6663872",
"0.6663872",
"0.6663872",
"0.6653537",
"0.6645669",
"0.6635318",
"0.6626899",
"0.6626899",
"0.6626899",
"0.6626899",
"0.6626899",
"0.6624111",
"0.6619254",
"0.6618381",
"0.6618381",
"0.6618381",
"0.6618381",
"0.6618381",
"0.6618381",
"0.6618381",
"0.6618381",
"0.6618381",
"0.66123205",
"0.6601145",
"0.65995127",
"0.6580278",
"0.6562019",
"0.6530221",
"0.6524773",
"0.6522035",
"0.65215576",
"0.6498021",
"0.64881396",
"0.6460897",
"0.64474475",
"0.6444655",
"0.64390635",
"0.642578",
"0.64205706",
"0.64184225",
"0.64132375",
"0.64040923",
"0.6370323",
"0.63617843",
"0.63614947",
"0.63609385",
"0.6360396",
"0.6350775",
"0.63492054",
"0.63489753",
"0.6337221",
"0.6336362",
"0.63325226",
"0.6319776",
"0.6316553",
"0.6316298",
"0.6314506",
"0.6314506",
"0.63098145",
"0.6301677",
"0.6301677",
"0.6301677",
"0.6296452"
] | 0.6629122 | 43 |
Called when a key is Typed. | public abstract void keyTyped(KeyTypedEvent keyTypedEvent); | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@Override\n\t\tpublic void keyTyped(KeyEvent arg0) {\n\t\t\t\n\t\t}",
"@Override\n\t\tpublic void keyTyped(KeyEvent arg0) {\n\t\t\t\n\t\t}",
"@Override\n\t\tpublic void keyTyped(KeyEvent arg0) {\n\t\t\t\n\t\t}",
"@Override\n\t\t\t\tpublic void keyTyped(KeyEvent arg0)\n\t\t\t\t{\n\t\t\t\t\t\n\t\t\t\t}",
"@Override\n\t\t\tpublic void keyTyped(KeyEvent arg0) {\n\t\t\t\t\n\t\t\t}",
"@Override\n\t\t\tpublic void keyTyped(KeyEvent arg0) {\n\t\t\t\t\n\t\t\t}",
"@Override\n\t\t\tpublic void keyTyped(KeyEvent arg0) {\n\t\t\t\t\n\t\t\t}",
"@Override\n\t\t\tpublic void keyTyped(KeyEvent arg0) {\n\t\t\t\t\n\t\t\t}",
"@Override\n\t\t\tpublic void keyTyped(KeyEvent arg0) {\n\t\t\t\t\n\t\t\t}",
"@Override\n\t\t\tpublic void keyTyped(KeyEvent arg0) {\n\t\t\t\t\n\t\t\t}",
"@Override\r\n\t\t\tpublic void keyTyped(KeyEvent arg0)\r\n\t\t\t{\n\t\t\t\t\r\n\t\t\t}",
"@Override\r\n\t\t\tpublic void keyTyped(KeyEvent arg0) {\n\t\t\t\t\r\n\t\t\t}",
"@Override\n\tpublic void keyTyped(KeyEvent arg0) {\n\t}",
"@Override\n\tpublic void keyTyped(KeyEvent arg0) {\n\t}",
"@Override\n \t\t\tpublic void keyTyped(KeyEvent arg0) {\n \t\t\t\t\n \t\t\t}",
"@Override\r\n\tpublic void keyTyped(KeyEvent arg0) {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void keyTyped(KeyEvent arg0) {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void keyTyped(KeyEvent arg0) {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void keyTyped(KeyEvent arg0) {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void keyTyped(KeyEvent arg0) {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void keyTyped(KeyEvent arg0) {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void keyTyped(KeyEvent arg0) {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void keyTyped(KeyEvent arg0) {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void keyTyped(KeyEvent arg0) {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void keyTyped(KeyEvent arg0) {\n\t\t\r\n\t}",
"public void keyTyped(KeyEvent arg0) {\n\t\t\t\t\n\t\t\t}",
"public void keyTyped(KeyEvent arg0) {\n\t\t\t\t\n\t\t\t}",
"public void keyTyped(KeyEvent arg0) {\n\t\t\t\t\n\t\t\t}",
"public void keyTyped(KeyEvent arg0) {\n\t\t\t\t\n\t\t\t}",
"@Override\n\tpublic void keyTyped(KeyEvent arg0) {\n\t\t\n\t}",
"@Override\n\tpublic void keyTyped(KeyEvent arg0) {\n\t\t\n\t}",
"@Override\n\tpublic void keyTyped(KeyEvent arg0) {\n\t\t\n\t}",
"@Override\n\tpublic void keyTyped(KeyEvent arg0) {\n\t\t\n\t}",
"@Override\n\tpublic void keyTyped(KeyEvent arg0) {\n\t\t\n\t}",
"@Override\n\tpublic void keyTyped(KeyEvent arg0) {\n\t\t\n\t}",
"@Override\n\tpublic void keyTyped(KeyEvent arg0) {\n\t\t\n\t}",
"@Override\n\tpublic void keyTyped(KeyEvent arg0) {\n\t\t\n\t}",
"@Override\n\tpublic void keyTyped(KeyEvent arg0) {\n\t\t\n\t}",
"@Override\n\tpublic void keyTyped(KeyEvent arg0) {\n\t\t\n\t}",
"@Override\n\tpublic void keyTyped(KeyEvent arg0) {\n\t\t\n\t}",
"@Override\n\tpublic void keyTyped(KeyEvent arg0) {\n\t\t\n\t}",
"@Override\n\tpublic void keyTyped(KeyEvent arg0) {\n\t\t\n\t}",
"@Override\n\tpublic void keyTyped(KeyEvent arg0) {\n\t\t\n\t}",
"@Override\n\tpublic void keyTyped(KeyEvent arg0) {\n\t\t\n\t}",
"@Override\n\tpublic void keyTyped(KeyEvent arg0) {\n\t\t\n\t}",
"@Override\n\tpublic void keyTyped(KeyEvent arg0) {\n\t\t\n\t}",
"public void keyTyped(KeyEvent e) {\n // System.out.println(\"typed\");\n }",
"@Override\n\tpublic void keyTyped(KeyEvent arg0) {\n\n\t}",
"@Override\n\tpublic void keyTyped(KeyEvent arg0) {\n\n\t}",
"@Override\n\tpublic void keyTyped(KeyEvent arg0) {\n\n\t}",
"@Override\n\tpublic void keyTyped(KeyEvent arg0) {\n\n\t}",
"@Override\n\tpublic void keyTyped(KeyEvent arg0) {\n\n\t}",
"@Override\n\tpublic void keyTyped(KeyEvent arg0) {\n\n\t}",
"@Override\n\tpublic void keyTyped(KeyEvent arg0) {\n\n\t}",
"@Override\n\tpublic void keyTyped(final KeyEvent arg0) {\n\t\t\n\t}",
"@Override\n\tpublic void keyTyped(KeyEvent arg0)\n\t{\n\t\t\n\t}",
"public void keyTyped (KeyEvent arg0) {\n\t}",
"@Override\r\n\t\t\tpublic void keyTyped(KeyEvent arg0) {\n\r\n\t\t\t}",
"public void keyTyped(KeyEvent arg0) {\r\n\r\n\t}",
"public void keyTyped(KeyEvent arg0) {\n\t}",
"public void keyTyped(KeyEvent e)\n {\n \t//System.out.println(\"Key Typed!\");\n }",
"@Override\n\t\tpublic void keyTyped(KeyEvent e) {\n\n\t\t}",
"@Override\n\t\t\tpublic void keyTyped(KeyEvent e) {\n\n\t\t\t}",
"@Override\n\t\t\tpublic void keyTyped(KeyEvent e) {\n\n\t\t\t}",
"@Override\n\t\t\tpublic void keyTyped(KeyEvent e) {\n\n\t\t\t}",
"@Override\n\t\t\tpublic void keyTyped(KeyEvent e) {\n\n\t\t\t}",
"@Override\n\t\t\tpublic void keyTyped(KeyEvent e) {\n\n\t\t\t}",
"@Override\n\t\t\tpublic void keyTyped(KeyEvent e) {\n\n\t\t\t}",
"@Override\n\t\t\tpublic void keyTyped(KeyEvent e) {\n\n\t\t\t}",
"@Override\n\t\t\tpublic void keyTyped(KeyEvent e) {\n\n\t\t\t}",
"@Override\n\t\t\tpublic void keyTyped(KeyEvent e) {\n\n\t\t\t}",
"@Override\n\t\t\tpublic void keyTyped(KeyEvent e) {\n\n\t\t\t}",
"@Override\n\t\t\tpublic void keyTyped(KeyEvent e) {\n\n\t\t\t}",
"@Override\n\t\t\tpublic void keyTyped(KeyEvent e) {\n\n\t\t\t}",
"@Override\n\t\t\tpublic void keyTyped(KeyEvent e) {\n\n\t\t\t}",
"@Override\n\t\t\tpublic void keyTyped(KeyEvent e) {\n\n\t\t\t}",
"@Override\n\t\t\tpublic void keyTyped(KeyEvent e) {\n\n\t\t\t}",
"@Override\n\t\t\tpublic void keyTyped(KeyEvent e) {\n\n\t\t\t}",
"@Override\n\t\t\tpublic void keyTyped(KeyEvent e) {\n\n\t\t\t}",
"@Override\n\t\t\tpublic void keyTyped(KeyEvent e) {\n\n\t\t\t}",
"@Override\n\t\t\tpublic void keyTyped(KeyEvent e) {\n\n\t\t\t}",
"@Override\n\t\t\tpublic void keyTyped(KeyEvent e) {\n\t\t\t}",
"public void keyTyped (KeyEvent e) {\n\n\t\t}",
"@Override\n\tpublic void keyTyped(KeyEvent arg0) {\n\t\tSystem.out.println(\"keyTyped\");\n\t}",
"public void keyTyped(KeyEvent arg0)\n\t{\n\t}",
"@Override\n\t\tpublic void keyTyped(KeyEvent e) {\n\t\t}",
"@Override\r\n\tpublic void keyTyped(KeyEvent ke) {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void keyTyped(KeyEvent arg0) {\n\r\n\t}",
"@Override\r\n\tpublic void keyTyped(KeyEvent arg0) {\n\r\n\t}",
"public void keyTyped(KeyEvent e) {\n\n\t\t\t}",
"public void keyTyped(KeyEvent e) {\n \n }",
"public void keyTyped(KeyEvent e) {\n \n }",
"public void keyTyped(KeyEvent e) {\n \n }",
"@Override\n\tpublic void keyTyped(KeyEvent e)\n\t\t{\n\t\t\t\n\t\t}",
"public void keyTyped(KeyEvent e) {\n }",
"public void keyTyped(KeyEvent e)\n\t{\n\t}",
"public void keyTyped(KeyEvent e)\r\n\t{\n\t}",
"public void keyTyped (KeyEvent e) { }",
"public void keyTyped(KeyEvent e) {}",
"public void keyTyped(KeyEvent arg0) {\n\n }",
"public void keyTyped(KeyEvent e)\n {\n \n }"
] | [
"0.7840094",
"0.7840094",
"0.7840094",
"0.7777214",
"0.77474815",
"0.77474815",
"0.77474815",
"0.77474815",
"0.77474815",
"0.77474815",
"0.77266574",
"0.77167606",
"0.766435",
"0.766435",
"0.7645868",
"0.76360226",
"0.76360226",
"0.76360226",
"0.76360226",
"0.76360226",
"0.76360226",
"0.76360226",
"0.76360226",
"0.76360226",
"0.76360226",
"0.76112986",
"0.76112986",
"0.76112986",
"0.76112986",
"0.76057935",
"0.76057935",
"0.76057935",
"0.76057935",
"0.76057935",
"0.76057935",
"0.76057935",
"0.76057935",
"0.76057935",
"0.76057935",
"0.76057935",
"0.76057935",
"0.76057935",
"0.76057935",
"0.76057935",
"0.76057935",
"0.76057935",
"0.75953776",
"0.7593607",
"0.7593607",
"0.7593607",
"0.7593607",
"0.7593607",
"0.7593607",
"0.7593607",
"0.75755465",
"0.7554128",
"0.75252867",
"0.7524134",
"0.75197524",
"0.7518198",
"0.7512931",
"0.75044453",
"0.7476063",
"0.7476063",
"0.7476063",
"0.7476063",
"0.7476063",
"0.7476063",
"0.7476063",
"0.7476063",
"0.7476063",
"0.7476063",
"0.7476063",
"0.7476063",
"0.7476063",
"0.7476063",
"0.7476063",
"0.7476063",
"0.7476063",
"0.7476063",
"0.7476063",
"0.7475762",
"0.7474623",
"0.7474563",
"0.7451951",
"0.7451188",
"0.7446608",
"0.7438251",
"0.7438251",
"0.743507",
"0.7428888",
"0.7428888",
"0.7428888",
"0.742173",
"0.7395148",
"0.7393328",
"0.7387436",
"0.73873496",
"0.73841614",
"0.7378036",
"0.73746574"
] | 0.0 | -1 |
Called if the size changed. | public abstract void sizeChanged(SizeChangedEvent event); | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@Override\n protected void sizeChanged () {\n }",
"private void checkAndModifySize() {\r\n if (size == data.length * LOAD_FACTOR) {\r\n resizeAndTransfer();\r\n }\r\n }",
"private void compatibilityDataSizeChanged(int size) {\n final int dataSize = mData == null ? 0 : mData.size();\n if (dataSize == size) {\n notifyDataSetChanged();\n }\n }",
"protected void checkSize(){\n if (size == data.length){\n resize( 2 * data.length);\n }\n }",
"@Override\n protected final void onSizeChanged(int w, int h, int oldw, int oldh) {\n super.onSizeChanged(w, h, oldw, oldh);\n this.invalidate();\n }",
"@Override\n public int size() {\n return currentSize;\n }",
"public void notifyChildrenOfSizeChange() {\n Util.runDescendentsLayout(this);\n }",
"@Override\n public int size() {\n return curSize;\n }",
"public void changed() {\n this.fireContentsChanged(this, 0, this.getSize() - 1);\n }",
"void updateSize() {\n setMeAndMyParentsAsDirty();\n }",
"public abstract void adjustSize(long size);",
"@Override\n protected void onSizeChanged(int w, int h, int oldw, int oldh) {\n super.onSizeChanged(w, h, oldw, oldh);\n this.w = w;\n this.h = h;\n }",
"@Override\n\tprotected void onSizeChanged(int w, int h, int oldw, int oldh) {\n\t\twidth = w;\n\t\theigth = h;\n\t\tajestPosition();\n\t\tthis.invalidate();\n\t\tsuper.onSizeChanged(w, h, oldw, oldh);\n\t}",
"@Override\n\tpublic void resized() {\n\t}",
"@Override public void onSizeChanged(int w, int h, int oldw, int oldh)\n {\n super.onSizeChanged(w, h, oldw, oldh);\n // Release the buffer, if any and it will be reallocated on the next draw\n mBuffer = null;\n }",
"public void sizeHasBeenSet() {\n isSizeSet = true;\n }",
"@Override\n public int size() { return size; }",
"@Override\r\n\tpublic void resize() {\n\t\t\r\n\t}",
"@Override\n public int getSize() {\n return size;\n }",
"@Override\n public int getSize() { return size; }",
"@Override\r\n public int size() {\r\n return size;\r\n }",
"@Override\r\n public int size() {\r\n return size;\r\n }",
"@Override\r\n public int size() {\r\n return size;\r\n }",
"public void sizeIncrease1() {\n\t\t _size++;\n\t}",
"int getLostedSize();",
"@Override\n public int size() {\n return size;\n }",
"@Override\n public int size() {\n return size;\n }",
"public void update() {\n\tfireContentsChanged(this, 0, getSize());\n }",
"@Override\n public int size(){\n return size;\n }",
"@Override\n public int size() {\n return size;\n }",
"@Override\n public int size() {\n return size;\n }",
"@Override\n public int size() {\n return size;\n }",
"@Override\n public int size() {\n return size;\n }",
"@Override\n public int size() {\n return size;\n }",
"@Override\n public int size() {\n return size;\n }",
"@Override\n public int size() {\n return size;\n }",
"@Override\n public int size() {\n return size;\n }",
"@Override\n public int size() {\n return size;\n }",
"@Override\n public int size() {\n return size;\n }",
"@Override\n public int size() {\n return size;\n }",
"@Override\n public int size() {\n return size;\n }",
"@Override\n public int size() {\n return size;\n }",
"@Override\n public int size() {\n return size;\n }",
"@Override\n public int size() {\n return size;\n }",
"@java.lang.Override\n public int getSize() {\n return size_;\n }",
"@java.lang.Override\n public int getSize() {\n return size_;\n }",
"public int size(){\r\n return currentSize;\r\n }",
"@Override\n\tpublic void resize() {\n\t\t\n\t}",
"@Override\n public int size() {\n return size;\n }",
"int getCurrentSize();",
"protected void sendSizeChange(int oldw, int oldh) {\n if (oldw != this.getWidth() || oldh != this.getHeight())\n this.m_eventSender.sendEvent(RESIZED_EVENT, this, new SizeData(oldw,oldh));\n }",
"private void resize() {\n }",
"@Override\n\tprotected void changeSize(int x, int y, int previousX, int previousY) {\n this.setWidth(this.getWidth()+(x-previousX));\n this.setHeight(this.getHeight()+(y-previousY));\n this.setX(this.getX()+(x-previousX));\n\t}",
"@Override\n protected void onSizeChanged(int w, int h, int oldw, int oldh) {\n super.onSizeChanged(w, h, oldw, oldh);\n viewMatrix = null;\n }",
"@Override\r\n \tpublic int size() {\r\n \t\t// TODO\r\n \t\treturn size;\r\n \t}",
"@java.lang.Override\n public int getSize() {\n return size_;\n }",
"@java.lang.Override\n public int getSize() {\n return size_;\n }",
"public void sizeDecrease1() {\n\t\t _size--;\n\t}",
"public void setSize(int newSize);",
"public void setSize(int newSize);",
"private void set_size(int size)\r\n\t{\r\n\t\tthis.size = size;\r\n\t}",
"private void increaseSize() {\n data = Arrays.copyOf(data, size * 3 / 2);\n }",
"@Override\n\tprotected void onSizeChanged(int w, int h, int oldw, int oldh) {\n\t\tif (w != oldw && mIsFirstLoad == false) {\n\t\t\tmIsFirstLoad = false;\n\t\t\tif (mIsShowTextsSingleLine) {\n\t\t\t\tupdateSingleLineTextVisiable();\n\t\t\t}\n\t\t}\n\t\tsuper.onSizeChanged(w, h, oldw, oldh);\n\t}",
"public int getSize(){return this.size;}",
"@Override\n public int size() {\n return _size;\n }",
"@Override\n protected void onSizeChanged(int w, int h, int oldw, int oldh) {\n super.onSizeChanged(w, h, oldw, oldh);\n setGameCards();\n }",
"private void handleSizeChange(Object observable) {\n imageView.fitToSize(getWidth(), getHeight());\n placeHolder.setGlyphSize(Math.min(getWidth(), getHeight()) * 0.6);\n }",
"@Override\n public void onSizeChanged(int w, int h, int oldW, int oldH) {\n mId = w / 2;\n mId = mId - mViewsCount * 9;\n }",
"@Override\n protected void onSizeChanged(int w, int h, int oldW, int oldH) {\n super.onSizeChanged(w, h, oldW, oldH);\n\n canvasWidth = w;\n canvasHeight = h;\n updatePolygonSize();\n\n if (Math.min(canvasWidth, canvasHeight) != Math.min(oldW, oldH)) {\n refreshImage();\n }\n }",
"@Override\n\tpublic int getSize() {\n\t\treturn size;\n\t}",
"@Override\n\tpublic int getSize() {\n\t\treturn size;\n\t}",
"protected abstract void resize();",
"@Override\n public long getSize() {\n return allocatedSize;\n }",
"protected void newSize() {\r\n adjustSize();\r\n halt();\r\n newGame();\r\n }",
"private void setFinalSize()\n {\n if (! m_isEmpty)\n return;\n m_isEmpty = false;\n setSize(m_finalSize);\n if (m_finalLocation != null)\n setLocation(m_finalLocation);\n }",
"@Override\r\n\tpublic int size() {\r\n\t\treturn size;\r\n\t}",
"@Override\n public int size() {\n return (totalSize - offset);\n }",
"public void updateSize() {\n\t\t\tthis.setSize();\n\t\t\tif (this.checkRoot()) {\n\t\t\t\treturn;\n\t\t\t}\n\t\t\tAVLNode parent = (AVLNode) this.parent;\n\t\t\tparent.updateSize();\n\t\t}",
"protected abstract void setSize();",
"public void reSize() {\n int newSize = arr.length * 2;\n arr = Arrays.copyOf(arr, newSize);\n }",
"public int getSize() {return size;}",
"public void setSize(int _size)\r\n {\r\n size = _size;\r\n }",
"@Override\r\n public int size() {\r\n return this.size;\r\n }",
"@Override\n protected void contentViewDidChangeSize()\n {\n // Do normal version\n super.contentViewDidChangeSize();\n\n // Clear DataPath\n clearDataPath();\n }",
"public int getSize() { return size; }",
"@Override\n\tpublic int size() {\n\t\treturn getSize();\n\t}",
"public int getSize(){return _size;}",
"@Override\r\n\tprotected void onSizeChanged(int w, int h, int oldw, int oldh) {\n\t\tsuper.onSizeChanged(w, h, oldw, oldh);\r\n\t\tif (w > 0 && h > 0) {\r\n\t\t\tcontainerWidth = w;\r\n\t\t\tcontainerHeight = h;\r\n\t\t}\r\n\t}",
"@Override\n\tpublic int size() {\n\t\treturn size;\n\t}",
"@Override\n\tpublic int size() {\n\t\treturn size;\n\t}",
"@Override\n\tpublic int size() {\n\t\treturn size;\n\t}",
"@Override\n\tpublic int size() {\n\t\treturn size;\n\t}",
"@Override\n\tpublic int size() {\n\t\treturn size;\n\t}",
"@Override\r\n public void gameSize(String[] arr) {\r\n\tMaze3d temp = hMaze.get(arr[arr.length - 1]);\r\n\ttry {\r\n\t int size = (temp.toByteArray()).length;\r\n\t setChanged();\r\n\t notifyObservers(\"Maze \" + arr[arr.length - 1] + \" size is:\" + size);\r\n\t} catch (IOException e) {\r\n\t setChanged();\r\n\t notifyObservers(\"Error, please try again\");\r\n\t}\r\n }",
"@Override\r\n\tpublic void resize(int arg0, int arg1) {\n\t}",
"default void onVideoSizeChanged(int oldWidth, int oldHeight, int width, int height) {\n }",
"@Override\n public void sizeChanged(IntBuffer collection) {\n semaphore.release();\n }",
"@Override\n public int size() {\n return this.size;\n }",
"@Override\n public int size() {\n return this.size;\n }",
"@Override\n public int size() {\n return this.size;\n }"
] | [
"0.80437696",
"0.7680577",
"0.7578963",
"0.7308866",
"0.7126924",
"0.7109925",
"0.70706785",
"0.7034927",
"0.70267236",
"0.7022934",
"0.6998919",
"0.6958116",
"0.69540274",
"0.6951825",
"0.69340515",
"0.691168",
"0.68339545",
"0.6791787",
"0.6762097",
"0.67536134",
"0.6736412",
"0.6736412",
"0.6736412",
"0.6722207",
"0.6715055",
"0.6693009",
"0.6693009",
"0.6691602",
"0.6687793",
"0.668009",
"0.668009",
"0.668009",
"0.668009",
"0.668009",
"0.668009",
"0.668009",
"0.668009",
"0.668009",
"0.668009",
"0.668009",
"0.668009",
"0.668009",
"0.668009",
"0.668009",
"0.66599315",
"0.66599315",
"0.6647209",
"0.6646025",
"0.6642245",
"0.66390324",
"0.6635313",
"0.6631848",
"0.66198",
"0.6599719",
"0.65969896",
"0.65941536",
"0.65941536",
"0.65881985",
"0.6583024",
"0.6583024",
"0.65726155",
"0.6559151",
"0.6547737",
"0.6519168",
"0.6514894",
"0.65136683",
"0.65109706",
"0.6506918",
"0.6502719",
"0.64902985",
"0.64902985",
"0.6489596",
"0.648948",
"0.648935",
"0.648605",
"0.6469312",
"0.64594215",
"0.6453451",
"0.6438747",
"0.64352834",
"0.64309376",
"0.64289385",
"0.6396963",
"0.6394633",
"0.6387641",
"0.63850904",
"0.63787794",
"0.63770825",
"0.63669324",
"0.63669324",
"0.63669324",
"0.63669324",
"0.63669324",
"0.6355543",
"0.6354413",
"0.6349897",
"0.6340257",
"0.6305909",
"0.6305909",
"0.6305909"
] | 0.7240933 | 4 |
Called of the position changed. | public abstract void positionChanged(PositionChangedEvent event); | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@Override\n\tpublic void updatePosition() {\n\t\t\n\t}",
"@Override\n public void onDragPositionsChanged(int oldPosition, int newPosition) {\n }",
"private void updatePosition(){\n updateXPosition(true);\n updateYPosition(true);\n }",
"@Override\n\tpublic void posModify() {\n\t\t\n\t}",
"@Override\n\tpublic void posModify() {\n\t\t\n\t}",
"public void onSwapPosition() {\n\n\t}",
"@Override\n protected void showChangePosition(long duration, int newPositionProgress) {\n }",
"private void cursorPosChanged( double x, double y )\n {\n }",
"protected void update(){\n\t\t_offx = _x.valueToPosition(0);\n\t\t_offy = _y.valueToPosition(0);\n\t}",
"@Override\n public void recalculatePositions() { \n \n }",
"protected final void viewChanged()\n {\n synchronized (this)\n {\n resetProjectionMatrixClipped();\n resetModelViewMatrix();\n resetClipPlanes();\n notifyViewChanged(ViewChangeSupport.ViewChangeType.VIEW_CHANGE);\n if (getPreferences() != null)\n {\n getPreferences().putJAXBObject(POSITION_PREF_KEY, getPosition().clone(), true, this);\n }\n }\n }",
"@Override\n public void positionChanged(int newPosition) {\n\t if (newPosition >= stop) {\n stopButtonActionPerformed(null);\n } else {\n if (newPosition < posStart || newPosition > posEnd) {\n test = false;\n scrollBar.setValue(newPosition);\n test = true;\n posStart = newPosition;\n posEnd = (int) (newPosition + scrollBar.getVisibleAmount());\n if (posEnd > wave.getSampleCount()) {\n posStart -= (posEnd - wave.getSampleCount());\n posEnd = wave.getSampleCount();\n }\n rysuj();\n if (!startTime.getValue().equals(endTime.getValue())) {\n paintSelected();\n }\n }\n position = (int) (wavePanel.getWidth() * ((newPosition - posStart) / (double) (posEnd - posStart)));\n cursorPanel.setLocation(position, 0);\n }\n }",
"public void setPosition(Point newPosition);",
"public void changed() {\n this.fireContentsChanged(this, 0, this.getSize() - 1);\n }",
"public void setPosition(){\r\n currentPosition = 0; \r\n }",
"protected void timeChanged(Real time) {\n try {\n getChart().timeChanged(time);\n } catch (Exception exc) {\n logException(\"changePosition\", exc);\n }\n super.timeChanged(time);\n }",
"void playerPositionChanged(Player player);",
"public void updatePositionValue(){\n m_X.setSelectedSensorPosition(this.getFusedPosition());\n }",
"@Override\n public void onMove(float x, float y) {\n }",
"public void changed(LocationEvent arg0) {\n \t\t\t\t\t\t\n \t\t\t\t\t}",
"@Override\n public void update() {\n if (changedState) {\n selectedPosY = selection * hItemBox + yPos + hItemBox;\n selectedPosX = xPos; \n changedState = false;\n }\n }",
"public abstract void setPosition(Position position);",
"@Override\n\t\t\t\t\t\t\t\t\tpublic void callback(int position) {\n\n\t\t\t\t\t\t\t\t\t}",
"protected void onMove() {\r\n }",
"@Override\n public void setPosition(float x, float y) {\n }",
"@Override\r\n\tprotected void onMove() {\n\t\t\r\n\t}",
"public void refreshPosition() {\n\n this.setTransform(getTransform());\n }",
"@Override\r\n\tpublic void updatePosition(int id, float[] pos) {\n\r\n\t}",
"@Override\n public void update(){\n getNextPosition();\n checkTileMapCollision();\n setPosition(xtemp, ytemp);\n animation.update();\n }",
"public void updatePosition() {\n\n this.x = this.temp_x;\n this.y = this.temp_y;\n this.ax = 0;\n this.ay = 0;\n\t\tthis.axplusone = 0;\n this.ayplusone = 0;\n \n }",
"@Override\n protected void positionChanged () {\n\n\n valueLabel.setPosition( this.getX() + ((this.getScaleX() * this.getWidth() - valueLabel.getScaleX() * valueLabel.getWidth()) / 2),\n this.getY() + ((this.getScaleY() * this.getHeight() - valueLabel.getScaleY() * valueLabel.getHeight()) / 2) );\n }",
"@Override\n\tpublic void onLocationChanged(Location arg0) {\n\n\t}",
"@Override\n\tpublic void onLocationChanged(Location arg0) {\n\n\t}",
"public void move() {\n this.pposX = this.posX;\n this.pposY = this.posY;\n this.posX = newPosX;\n this.posY = newPosY;\n }",
"public void setPosition(Position pos);",
"public void onPositionChanged() {\n\n currentLat = location.getLatitude();\n currentLng = location.getLongitude();\n\n }",
"public void onPositionChanged() {\n\n currentLat = location.getLatitude();\n currentLng = location.getLongitude();\n\n }",
"public synchronized void visitorPositionChanged (CityMap sender) {\n cityMap.getVisitorXY (tmpXY);\n visitorX = tmpXY[CityMap.X];\n visitorY = tmpXY[CityMap.Y];\n repaint ();\n }",
"@Override\n\tpublic void update() {\n\t\tmove();\n\t\tplace();\n\t}",
"Position getOldPosition();",
"public void setPosition(int newPosition) {\n if (newPosition != position) {\n position = newPosition;\n notifyListeners(getCurrentItem());\n }\n }",
"void setPosition(Position position);",
"void setPosition(Position position);",
"void onNewCoords(Coords coords);",
"public void frogReposition() {\n\t\tsetY(FrogPositionY);\n\t\tsetX(FrogPositionX);\t\t\n\t\t}",
"@Override\n \t\t\tpublic void onLocationChanged(Location loc) {\n \t \n \t\t\t}",
"@Override\r\n\tpublic void caretUpdate(CaretEvent e) {\n\t\t\r\n\t}",
"@Override\n\tpublic void update(Event e) {\n\t}",
"protected void probePositionChanged(RealTuple position) {\n try {\n loadProfile(position);\n } catch (Exception exc) {\n logException(\"probePositionChanged\", exc);\n }\n\n }",
"@Override\n public int getPosition() {\n return position;\n }",
"public void redoMove(){\n circleObj.setX(newX);\n circleObj.setY(newY);\n }",
"protected void sendPosChange(int oldx, int oldy) {\n if (oldx != this.getXPos() || oldy != this.getYPos())\n this.m_eventSender.sendEvent(MOVED_EVENT, this, new LocationData(oldx,oldy));\n }",
"void msgViewableChanged() {\n resetViewport(start);\n }",
"public void updatePosition() {\n \t\r\n \tx += dx;\r\n \ty += dy;\r\n \t\r\n\t}",
"protected void onUpdate() {\r\n\r\n\t}",
"@Override\r\n\tpublic boolean editPosition(Position post) throws Exception {\n\t\treturn false;\r\n\t}",
"@Override\n\tpublic void stateChanged() {\n\t\t\n\t}",
"public void updateXLoc();",
"public void mazeChanged(Maze maze);",
"@Override\n public void setPosition(int position) {\n this.position = position;\n }",
"@Override\n public void OnGo(int position) {\n }",
"@Override\n public void onMove(boolean absolute) {\n \n }",
"public void setPostion(int newXPosition, int newYPosition) {\n xPosition = newXPosition;\n yPosition = newYPosition;\n }",
"@Override\n\tpublic void onUpdate() {\n\t\t\n\t}",
"@Override\r\n public void onUpdate() {\n super.onUpdate();\r\n }",
"@Override\n public void propertyChange(PropertyChangeEvent e) {\n this.updateCoords();\n }",
"public void setPosition(int position);",
"@Override\n public void update() {\n \n }",
"public void move(){\n super.move();\n load.updateCoordinates(this.x,this.y);\n }",
"public void stateChanged(ChangeEvent e) {\n\t\t\t\tplane.setX(jsCentreStick.getValue());\n\t\t\t}",
"@Override\n public void update()\n {\n\n }",
"@Override\n protected void onLayout(boolean changed, int l, int t, int r, int b) {\n }",
"@Override\n\tpublic void positionChanged(ModelPositionChangeEvent event) {\n\t\tIPosition position = event.getNewPosition();\n\t\tif(position instanceof SmilAudioPosition) {\t\t\t\n\t\t\tTimeContainer parentContainer = \n\t\t\t\t((SmilAudioPosition)position).getSmilAudioMediaObject().getParentContainer();\n\t\t\tif(parentContainer == lastTimeContainer) return;\n\t\t\tlastTimeContainer = parentContainer;\n\t\t}\t\t\n\t\tsuper.positionChanged(event);\n\t}",
"public void setPosition(Position p);",
"public void markTileEntityChanged(Point3d position){\r\n\t\tworld.getTileEntity(new BlockPos(position.x, position.y, position.z)).markDirty();\r\n\t}",
"@Override\n\tpublic void onLocationChanged(Location loc)\n\t{\n\t}",
"@Override\n protected void onContentsChanged(int slot) {\n setChanged();\n }",
"@Override\n public void onPageChanged(int position) {\n }",
"void setPosition(Position p);",
"public void setPosition(int position) {\r\r\r\r\r\r\n this.position = position;\r\r\r\r\r\r\n }",
"@Override\n public void delta() {\n \n }",
"protected void notifyParentOfPositionChange()\n {\n rotatedCorners = null;\n ShapeView view = getParentView();\n \n if (view != null)\n {\n view.onPositionChanged(this);\n }\n }",
"@Override\r\n\tpublic void update(float delta) {\n\t\t\r\n\t}",
"@Override\n public void stateChanged(javax.swing.event.ChangeEvent e) {\n }",
"public void update() {\n\tfireContentsChanged(this, 0, getSize());\n }",
"@Override\n public void onCurShapeIndexUpdate(BNRGCurShapeIndexUpdate arg0) {\n Log.d(BNRemoteConstants.MODULE_TAG, \"onCurShapeIndexUpdate...... \");\n }",
"public void update() {\n if (isActive()) {\n updatePosition(dx, dy);\n }\n }",
"@Override\n\tpublic void setPosition(Vector3 pos) {\n\t\t\n\t}",
"private void change() {\n\t\tsetChanged();\n\t\t//NotifyObservers calls on the update-method in the GUI\n\t\tnotifyObservers();\n\t}",
"@Override\n public void setChanged() {\n set(getItem());\n }",
"public void onPositionChanged() {\n\n latPeriodic = location.getLatitude();\n lonperiodic = location.getLongitude();\n\n }",
"public void setPosition(Position pos) {\n \tthis.position = pos;\n \t//setGrade();\n }",
"void positionCleared();",
"@Override\n public void update() {\n }",
"@Override\n public void update() {\n }",
"void onPageChanged(int position);",
"@Override\r\n public void changedUpdate(DocumentEvent e)\r\n {\n }",
"protected void setPosition(Position p) {\n\t\tposition = p;\n\t}",
"@Override\n public void update() {\n\n }",
"@Override\n\t\t\tpublic void changedUpdate(DocumentEvent arg0) {\n\t\t\t}"
] | [
"0.78546",
"0.7281376",
"0.72677255",
"0.72117275",
"0.72117275",
"0.7203668",
"0.7199442",
"0.7082394",
"0.69090027",
"0.69027215",
"0.6847724",
"0.67895246",
"0.6777462",
"0.6762818",
"0.67494226",
"0.6746385",
"0.6732648",
"0.67109096",
"0.6681322",
"0.6643402",
"0.66186696",
"0.66110456",
"0.65850407",
"0.6565587",
"0.6561811",
"0.6545115",
"0.65334153",
"0.6516191",
"0.6502933",
"0.6492947",
"0.6491041",
"0.64852613",
"0.64852613",
"0.64459336",
"0.6445462",
"0.6425996",
"0.6425996",
"0.64016414",
"0.6398059",
"0.6394306",
"0.6385002",
"0.6379168",
"0.6379168",
"0.6351923",
"0.6335853",
"0.6334347",
"0.63303226",
"0.6326934",
"0.62983394",
"0.62948436",
"0.6292519",
"0.6289961",
"0.6287818",
"0.62785184",
"0.6277548",
"0.62769383",
"0.62761104",
"0.62731576",
"0.62649786",
"0.6261989",
"0.6257703",
"0.6255544",
"0.62517226",
"0.62513644",
"0.62499523",
"0.62454087",
"0.6241113",
"0.62385917",
"0.6233136",
"0.62315786",
"0.6231099",
"0.62257415",
"0.6218913",
"0.6216648",
"0.6212972",
"0.62125105",
"0.62094957",
"0.62080574",
"0.6203418",
"0.6202868",
"0.6200848",
"0.6190088",
"0.61899626",
"0.6189338",
"0.6187777",
"0.6180978",
"0.61749816",
"0.61723185",
"0.6168292",
"0.61596435",
"0.6154169",
"0.6148785",
"0.61426413",
"0.6139133",
"0.61387783",
"0.6135391",
"0.613399",
"0.6127741",
"0.6126615",
"0.6123838"
] | 0.7622127 | 1 |
public IAppearance getAppearance(); / (nonJavadoc) | public abstract Display getDisplay(); | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"Appearance getAppearance();",
"public App getLocalAppearance() {\n return localAppearance;\n }",
"@Override\n public String toString() {\n return \"\" + this.getAppearance();\n }",
"public App getWorldAppearance() {\n return worldAppearance;\n }",
"public String getDefaultAppearance() {\n/* 530 */ return getCOSObject().getString(COSName.DA);\n/* */ }",
"public IfcCharacterStyleSelect getTextCharacterAppearance() {\n return textCharacterAppearance;\n }",
"public boolean preparedAppearance() {\r\n return preparedAppearance;\r\n }",
"public abstract String getStyle();",
"public void setAppearance(String s)\n\t{\n\t\tappearance = s;\n\t}",
"public Object getDefault(VisualStyle style) {\n \t\tif (style == null)\n \t\t\treturn null;\n \n \t\tAppearance a = null;\n \n \t\tif (isNodeProp())\n \t\t\ta = style.getNodeAppearanceCalculator().getDefaultAppearance();\n \t\telse\n \t\t\ta = style.getEdgeAppearanceCalculator().getDefaultAppearance();\n \n \t\treturn a.get(this);\n \t}",
"public void constructAppearances() {\n/* 860 */ if (this.customAppearanceHandler == null) {\n/* */ PDSoundAppearanceHandler pDSoundAppearanceHandler;\n/* 862 */ PDAppearanceHandler appearanceHandler = null;\n/* 863 */ if (\"Caret\".equals(getSubtype())) {\n/* */ \n/* 865 */ PDCaretAppearanceHandler pDCaretAppearanceHandler = new PDCaretAppearanceHandler(this);\n/* */ }\n/* 867 */ else if (\"FreeText\".equals(getSubtype())) {\n/* */ \n/* 869 */ PDFreeTextAppearanceHandler pDFreeTextAppearanceHandler = new PDFreeTextAppearanceHandler(this);\n/* */ }\n/* 871 */ else if (\"Ink\".equals(getSubtype())) {\n/* */ \n/* 873 */ PDInkAppearanceHandler pDInkAppearanceHandler = new PDInkAppearanceHandler(this);\n/* */ }\n/* 875 */ else if (\"Polygon\".equals(getSubtype())) {\n/* */ \n/* 877 */ PDPolygonAppearanceHandler pDPolygonAppearanceHandler = new PDPolygonAppearanceHandler(this);\n/* */ }\n/* 879 */ else if (\"PolyLine\".equals(getSubtype())) {\n/* */ \n/* 881 */ PDPolylineAppearanceHandler pDPolylineAppearanceHandler = new PDPolylineAppearanceHandler(this);\n/* */ }\n/* 883 */ else if (\"Sound\".equals(getSubtype())) {\n/* */ \n/* 885 */ pDSoundAppearanceHandler = new PDSoundAppearanceHandler(this);\n/* */ } \n/* */ \n/* 888 */ if (pDSoundAppearanceHandler != null)\n/* */ {\n/* 890 */ pDSoundAppearanceHandler.generateAppearanceStreams();\n/* */ }\n/* */ }\n/* */ else {\n/* */ \n/* 895 */ this.customAppearanceHandler.generateAppearanceStreams();\n/* */ } \n/* */ }",
"public String getDefaultAppearanceString()\r\n {\r\n return ((COSString)option.getObject( 1 ) ).getString();\r\n }",
"Style getStyle();",
"public ArrayList<AttributDescribe> getAttributs(){\r\n \treturn this.attributs;\r\n }",
"UiStyle getUiStyle();",
"public Typeface a() {\n return this.f2079d;\n }",
"IAttributes getAttributes();",
"public String getAesthetic() {\n return aesthetic;\n }",
"public FaceAttributes faceAttributes() {\n return this.faceAttributes;\n }",
"public A_Class_Diagram getDiagram() {\r\n\t\treturn diagram;\r\n\t}",
"Attributes getAttributes();",
"public DisplayType getDisplayType();",
"Appearance lineApp() {\n\t\tAppearance app = new Appearance();\n\t\tapp.setPolygonAttributes(\n\t\t\tnew PolygonAttributes(\n\t\t\t\tPolygonAttributes.POLYGON_LINE,\n\t\t\t\tPolygonAttributes.CULL_NONE,\n\t\t\t\t0f));\n\t\treturn app;\n\t}",
"public abstract String getFeeling();",
"void showCustomizer();",
"public BackgroundImage getBackgroundImage() {\n return this.backgroundImage;\n }",
"public VisualPalette getVisualPalette() {\n return this.visualPalette;\n }",
"public DrawingComponent getAnnotation()\n\t{\n\t\treturn this.annotation;\n\t}",
"public FontStyle getStyle();",
"public AOC getAOC() {\n\t\treturn aoc;\n\t}",
"public String getStyle() {\r\n return style;\r\n }",
"public Icon getRibbonIcon()\n\t{\n\t\treturn ribbonIcon;\n\t}",
"public String getStyle() {\n return style;\n }",
"public String getStyle() {\n return style;\n }",
"public String getStyle() {\n return style;\n }",
"public String getStyle() {\n return style;\n }",
"public EffectInfoModel apZ() {\n if (this.dcA == null) {\n this.dcA = mo30002aG(QStyle.NONE_THEME_TEMPLATE_ID);\n }\n return this.dcA;\n }",
"public HasDisplayableProperties getProperties();",
"public Colour getColour();",
"public Color getForeground();",
"public abstract String getDesign();",
"public int getStyle() {\n\treturn style;\n }",
"Behavior getBehavior();",
"public Theme getTheme() {\n return this.theme;\n }",
"public abstract Design getDesign();",
"public String getDisplayType();",
"public String getAccessibleIconDescription();",
"String getDesignation();",
"void setView(ImageView appearance) {\n this.view = appearance;\n }",
"public FighterCharacteristics characteristics();",
"public Background getBackground() {\r\n return this.background;\r\n }",
"public Graphic getGraphic() {\n\t\treturn this.graphic;\n\t}",
"public String getAsciidocDiagramImageFormat() {\n\t\treturn asciidocDiagramImageFormat;\n\t}",
"public abstract BossStyle getStyle();",
"public gov.nih.nlm.ncbi.www.soap.eutils.efetch_pmc.Graphic getGraphic() {\r\n return graphic;\r\n }",
"String getTheme();",
"int getSkin();",
"@Override\n\t/**\n\t * returns the visibility modifiers for the specific class\n\t * \n\t * @return visibility modifiers \n\t */\n\tpublic String getVisability() {\n\t\treturn visability;\n\t}",
"public AcronymTagger getAcronymTagger() {\n return acronymTagger;\n }",
"abstract public Skin getSkin();",
"public void setCustomAppearanceHandler(PDAppearanceHandler appearanceHandler) {\n/* 854 */ this.customAppearanceHandler = appearanceHandler;\n/* */ }",
"public String getFlavor() {\n \t\treturn flavor == null ? \"tooling\" : flavor; //$NON-NLS-1$\n \t}",
"protected IDescriptor getActiveDescriptor() {\n if (editor != null) {\n return editor.getActiveDisplayPane().getDescriptor();\n }\n return null;\n }",
"RecommendationRenderType getRenderType();",
"BalloonAttributes getAttributes();",
"public CustomizedBiGULDefinitionElements getCustomizedBiGULDefinitionAccess() {\r\n\t\treturn pCustomizedBiGULDefinition;\r\n\t}",
"public String getattribut() \n\t{\n\t\treturn attribut;\n\t}",
"public String getBackgroundImage() {\n\t\treturn this.backgroundImage;\n\t}",
"public Set<String> Atributos()\n {\n return this.repositorio.keySet();\n }",
"public final Face getFace() {\n\t\treturn this.face;\n\t}",
"public Visualization getVisualization() {\r\n return this.vis;\r\n }",
"public IfcShapeAspect getShapeAspectStyle()\n\t{\n\t\treturn this.ShapeAspectStyle;\n\t}",
"public IRibbonComponent getRibbonComponent()\n\t{\n\t\treturn ribbonComponent;\n\t}",
"public ComponentTheme getTheme() {\r\n return ui;\r\n }",
"public Attributes getAttributes() { return this.attributes; }",
"public VisualizationStyle getOldStyle()\r\n {\r\n return myOldStyle;\r\n }",
"public Graphic getGraphic(){\r\n\t\treturn this.graphic;\r\n\t}",
"public BufferedImage getBackgroundImage(){\n\t\treturn currentBackgroundImage;\n\t}",
"@Override\n\tpublic String getDesignation() {\n\t\treturn libelle;\n\t}",
"public int getStyle() {\r\n\t\treturn style;\r\n\t}",
"public Color getBackground();",
"private static String getStyleClass(Object obj) { return ((MetaData)obj).getStyle(); }",
"EObject getDiagrammableElement();",
"public AwesomeIconMode awesomeIconMode() {\n\t\treturn awesomeIconMode;\n\t}",
"public boolean getAdvancedInputCategory();",
"public interface HasUiAttributes {\n}",
"public Design getDesign() {\n return design;\n }",
"EDataType getReactance();",
"Annotation getAnnotation();",
"public String getFormatDesign() {\n return (String)getAttributeInternal(FORMATDESIGN);\n }",
"public interface AttributePropertiesEditionPart {\n\n\n\n\t/**\n\t * Init the anotations\n\t * @param current the current value\n\t * @param containgFeature the feature where to navigate if necessary\n\t * @param feature the feature to manage\n\t */\n\tpublic void initAnotations(ReferencesTableSettings settings);\n\n\t/**\n\t * Update the anotations\n\t * @param newValue the anotations to update\n\t * \n\t */\n\tpublic void updateAnotations();\n\n\t/**\n\t * Adds the given filter to the anotations edition editor.\n\t * \n\t * @param filter\n\t * a viewer filter\n\t * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter)\n\t * \n\t */\n\tpublic void addFilterToAnotations(ViewerFilter filter);\n\n\t/**\n\t * Adds the given filter to the anotations edition editor.\n\t * \n\t * @param filter\n\t * a viewer filter\n\t * @see org.eclipse.jface.viewers.StructuredViewer#addFilter(ViewerFilter)\n\t * \n\t */\n\tpublic void addBusinessFilterToAnotations(ViewerFilter filter);\n\n\t/**\n\t * @return true if the given element is contained inside the anotations table\n\t * \n\t */\n\tpublic boolean isContainedInAnotationsTable(EObject element);\n\n\n\t/**\n\t * @return the visibility\n\t * \n\t */\n\tpublic Enumerator getVisibility();\n\n\t/**\n\t * Init the visibility\n\t * @param input the viewer input\n\t * @param current the current value\n\t */\n\tpublic void initVisibility(Object input, Enumerator current);\n\n\t/**\n\t * Defines a new visibility\n\t * @param newValue the new visibility to set\n\t * \n\t */\n\tpublic void setVisibility(Enumerator newValue);\n\n\n\n\n\n\t/**\n\t * Returns the internationalized title text.\n\t * \n\t * @return the internationalized title text.\n\t * \n\t */\n\tpublic String getTitle();\n\n\t// Start of user code for additional methods\n\t\n\t// End of user code\n\n}",
"public Baraja getBaraja() {\n\t\treturn baraja;\n\t}",
"public java.util.Collection getAttributes();",
"public javax.accessibility.Accessible getAccessibleSummary() {\n // Not yet supported.\n return null;\n }",
"protected Visualizer getVis() {\n\t\treturn myVis;\n\t}",
"public String getAnnotation();",
"public String getIndicative() {\n\t\treturn null;\r\n\t}",
"public UiBackground getBackground() {\n if (getBackground == null)\n getBackground = new UiBackground(jsBase + \".background()\");\n\n return getBackground;\n }",
"public static List<DisplayProperty> getDisplayProperties() {return DISPLAY_PROPERTIES;}",
"@Override\r\n public DataFlavor getDataFlavor() {\r\n return dataFlavor;\r\n }",
"public BoardTheme getTheme()\n {\n return theme;\n }"
] | [
"0.9348971",
"0.73956984",
"0.71338975",
"0.7019933",
"0.6896052",
"0.65428776",
"0.628665",
"0.6098339",
"0.60165143",
"0.59230345",
"0.5921546",
"0.59149474",
"0.58288926",
"0.5783849",
"0.57469386",
"0.57072586",
"0.56404346",
"0.56114507",
"0.5535744",
"0.5501557",
"0.5497668",
"0.5481228",
"0.5441385",
"0.5429755",
"0.54101324",
"0.5380736",
"0.5377341",
"0.53717524",
"0.5367199",
"0.53621507",
"0.53610605",
"0.535194",
"0.5329609",
"0.5329609",
"0.5329609",
"0.5329609",
"0.5326644",
"0.53261375",
"0.532114",
"0.53169924",
"0.530783",
"0.5296922",
"0.5295802",
"0.5293584",
"0.52883035",
"0.52850395",
"0.5283684",
"0.5280049",
"0.5273701",
"0.52726746",
"0.5263407",
"0.5258385",
"0.52579844",
"0.5256388",
"0.5255614",
"0.52484727",
"0.52402353",
"0.52346355",
"0.5233794",
"0.5231287",
"0.522823",
"0.5224002",
"0.52154326",
"0.5212808",
"0.5202801",
"0.52016455",
"0.52008027",
"0.519657",
"0.51962435",
"0.5193842",
"0.518617",
"0.51800233",
"0.5165971",
"0.516199",
"0.51579356",
"0.5157705",
"0.5139628",
"0.51375586",
"0.51342726",
"0.5126767",
"0.5121424",
"0.5121291",
"0.51196516",
"0.51149166",
"0.510959",
"0.51060253",
"0.51055586",
"0.5101017",
"0.50977314",
"0.5091416",
"0.50903815",
"0.50868094",
"0.508561",
"0.5084615",
"0.5081965",
"0.5078278",
"0.5077168",
"0.5071807",
"0.5067287",
"0.50647765",
"0.50598246"
] | 0.0 | -1 |
/ public abstract int getWidth(); public abstract int getHeight(); | public abstract void removedFromWidgetTree(); | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public abstract int getHeight();",
"public abstract int getHeight();",
"public abstract int getHeight(int pWidth);",
"public abstract int getWidth();",
"public int getHeight();",
"public int getHeight();",
"public int getHeight();",
"public int getHeight();",
"public int getHeight();",
"public int getHeight();",
"public abstract float getHeight();",
"public abstract double getBaseHeight();",
"int getHeight();",
"int getHeight();",
"int getHeight();",
"int getHeight();",
"int getHeight();",
"int getHeight();",
"int getHeight();",
"int getHeight();",
"int getHeight();",
"int getHeight();",
"int getHeight();",
"int getHeight();",
"int getHeight();",
"int getHeight();",
"int getHeight();",
"int getHeight();",
"public abstract Dimension getSize();",
"public int height();",
"public int height();",
"public int height();",
"public int height();",
"public int getWidth();",
"public int getWidth();",
"public int getWidth();",
"public abstract int getNormalizedHeight();",
"public int getHeight() {return height;}",
"public int getHeight() { return height; }",
"int getHeight() {return height;}",
"public double getHeight();",
"public double getHeight();",
"public abstract int getYSize();",
"int getWidth();",
"int getWidth();",
"int getWidth();",
"int getWidth();",
"int getWidth();",
"int getWidth();",
"int getWidth();",
"int getWidth();",
"int getWidth();",
"int getWidth();",
"int getWidth();",
"int getWidth();",
"int getWidth();",
"int getWidth();",
"int getWidth();",
"int getWidth();",
"int getWidth();",
"@Override\r\n\tpublic double getArea() {\r\n\t\treturn width * height;\r\n\t}",
"@Override\r\n\tpublic double getArea() {\r\n\t\treturn width * height;\r\n\t}",
"public float getHeight();",
"double getHeight();",
"@Override\n\tpublic double getArea() {\n\t\treturn height * width;\n\t}",
"public int getH() { return height; }",
"public double getWidth();",
"public double getWidth();",
"int height();",
"public float getWidth();",
"abstract public int getMinHeight();",
"long getHeight();",
"public abstract double getBaseWidth();",
"Length getHeight();",
"public double getBaseHeight();",
"public int getWidth() { return width; }",
"public int getWidth() { return width; }",
"public int getHeight()\n {return height;}",
"public abstract int getDisplayHeight();",
"public byte getWidth();",
"public void size(final int theWidth, final int theHeight);",
"public Dimension getSize() { return new Dimension(width,height); }",
"double getWidth();",
"double getWidth();",
"int getAreaSize();",
"int getWidth() {return width;}",
"double getArea() {\n return width * height;\n }",
"long getWidth();",
"public int getFrameSize();",
"public int getHeight(){\n return height;\n }",
"public abstract int layoutHeight();",
"@Override\r\n public double area() {\n return height*width;\r\n }",
"public Integer getHeight(){return this.height;}",
"int getheight();",
"public double getWidth() {\n return this.size * 2.0; \n }",
"Dimension getSize();",
"Dimension getSize();",
"public abstract float getSquareSize();",
"@Override\n public double getArea() {\n return width * width;\n }",
"public abstract int getSourceHeight();",
"int getHeight()\n {\n return height;\n }"
] | [
"0.8403694",
"0.8403694",
"0.8337515",
"0.8330536",
"0.8062881",
"0.8062881",
"0.8062881",
"0.8062881",
"0.8062881",
"0.8062881",
"0.80004746",
"0.78451705",
"0.78098845",
"0.78098845",
"0.78098845",
"0.78098845",
"0.78098845",
"0.78098845",
"0.78098845",
"0.78098845",
"0.78098845",
"0.78098845",
"0.78098845",
"0.78098845",
"0.78098845",
"0.78098845",
"0.78098845",
"0.78098845",
"0.7788333",
"0.77717775",
"0.77717775",
"0.77717775",
"0.77717775",
"0.7765025",
"0.7765025",
"0.7765025",
"0.77124083",
"0.76845807",
"0.7674553",
"0.7659731",
"0.76531464",
"0.76531464",
"0.7643976",
"0.7599543",
"0.7599543",
"0.7599543",
"0.7599543",
"0.7599543",
"0.7599543",
"0.7599543",
"0.7599543",
"0.7599543",
"0.7599543",
"0.7599543",
"0.7599543",
"0.7599543",
"0.7599543",
"0.7599543",
"0.7599543",
"0.7599543",
"0.7547804",
"0.7547804",
"0.7544693",
"0.75403374",
"0.752733",
"0.7509878",
"0.7482253",
"0.7482253",
"0.74679136",
"0.7459182",
"0.74401027",
"0.74362874",
"0.7412975",
"0.741198",
"0.7409877",
"0.7375816",
"0.7375816",
"0.7375207",
"0.73735756",
"0.7366487",
"0.73591673",
"0.735628",
"0.7344533",
"0.7344533",
"0.73116916",
"0.7302676",
"0.73004526",
"0.7298355",
"0.7276486",
"0.72362804",
"0.72114944",
"0.7203921",
"0.72032785",
"0.718926",
"0.7181911",
"0.71663016",
"0.71663016",
"0.7157149",
"0.71556157",
"0.7151911",
"0.7146954"
] | 0.0 | -1 |
Returns whether this widget is registered in a widget tree. | public abstract boolean isInWidgetTree(); | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@Override\n\tpublic boolean is(Widget widget){\n\t\treturn (widget == this);\n\t}",
"public boolean canBeSeen()\n {\n if (!this.hasParent() || !this.isVisible())\n {\n return false;\n }\n\n GuiElement element = this;\n\n while (true)\n {\n if (!element.isVisible())\n {\n return false;\n }\n\n GuiElement parent = element.getParent();\n\n if (parent instanceof GuiDelegateElement && ((GuiDelegateElement) parent).delegate != element)\n {\n return false;\n }\n\n if (parent == null)\n {\n break;\n }\n\n element = parent;\n }\n\n return element instanceof GuiBase.GuiRootElement;\n }",
"public boolean hasChildComponent(Widget component) {\n return locationToWidget.containsValue(component);\n }",
"public boolean hasRegistry() {\n return registryBuilder_ != null || registry_ != null;\n }",
"boolean hasChildren();",
"protected boolean isFullyContained(Widget widget) {\r\n // Calling getPreferredBounds forces the bounds to be calculated if it\r\n // has not already been calculated. For example when the Widget was\r\n // just created and therefore has not had a chance to be displayed.\r\n Rectangle area = widget.getClientArea();\r\n\r\n boolean retVal = false;\r\n if (area != null) {\r\n Rectangle sceneArea = widget.convertLocalToScene(area);\r\n\r\n Rectangle localArea = scene.convertSceneToLocal(sceneArea);\r\n Rectangle myArea = scene.getClientArea();\r\n retVal = myArea.contains(localArea);\r\n }\r\n\r\n return retVal;\r\n }",
"public boolean isShowing() {\n return getRoot().isShowing();\n }",
"private boolean isBST() {\n return isBST(root, null, null);\n }",
"boolean hasParent();",
"boolean hasParent();",
"public boolean hasGadget() {\n return (this.curItem instanceof Gadget);\n }",
"public boolean containsChild() {\n return !(getChildList().isEmpty());\n }",
"public boolean hasRegistry() {\n return registry_ != null;\n }",
"@objid (\"808c086e-1dec-11e2-8cad-001ec947c8cc\")\n public final boolean hasChildren() {\n return !this.children.isEmpty();\n }",
"public boolean isExpanded(){\n\t\treturn syncExec(new BoolResult() {\n\t\t\t\n\t\t\t@Override\n\t\t\tpublic Boolean run() {\n\t\t\t\treturn widget.isExpanded();\n\t\t\t}\n\t\t});\n\t}",
"public boolean isTree() {\r\n\t\tfor (Entry<Object, SerialziationTypeRefs> ent : serTypes.entrySet()) {\r\n\t\t\tSerialziationTypeRefs rs = ent.getValue();\r\n\t\t\tif (ent.getKey() instanceof Resource && rs.total > 1) {\r\n\t\t\t\treturn false;\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn true;\r\n\t}",
"private boolean isBST() {\r\n return isBST(root, null, null);\r\n }",
"public boolean hasRecursive() {\n return recursiveBuilder_ != null || recursive_ != null;\n }",
"boolean hasParentalStatusView();",
"public boolean isChild();",
"protected final boolean isShowing() {\n synchronized (getPeerTreeLock()) {\n if (isVisible()) {\n final LWContainerPeer<?, ?> container = getContainerPeer();\n return (container == null) || container.isShowing();\n }\n }\n return false;\n }",
"public boolean getIsContainer()\n {\n return standardDefs.isContainer(root.getType());\n }",
"public boolean hasChildren()\n\t{\n\t\treturn !getChildren().isEmpty();\n\t}",
"public boolean getIsVisualElementContainer()\n {\n return root.getType().isAssignableTo(standardDefs.INTERFACE_IVISUALELEMENTCONTAINER);\n }",
"public boolean isGroupListSideBarPresent() {\r\n\t\treturn isElementPresent(groupListSideBar, SHORTWAIT);\r\n\t}",
"boolean isParentInitialized();",
"public boolean contains() {\n return (Bukkit.getServer().getPluginManager().getPlugin(this.name) != null);\n }",
"public boolean isNode() {\n return (kids != null);\n }",
"public boolean isValidateRoot() {\n\tComponent parent = getParent();\n\tif (parent instanceof JViewport) {\n\t return false;\n\t}\n return true;\n }",
"public boolean isEnabled () {\r\n\tcheckWidget();\r\n\treturn getEnabled () && parent.isEnabled ();\r\n}",
"public boolean hasTreeNodeId() {\n return treeNodeIdBuilder_ != null || treeNodeId_ != null;\n }",
"boolean hasRootFrame();",
"private boolean hasTFoot() {\r\n\t\treturn null != this.getTFoot();\r\n\t}",
"boolean hasGlobalSettingsPanel();",
"public boolean IsTree() {\r\n\t\treturn this.IsConnected() && !this.IsCyclic();\r\n\t}",
"boolean hasRegistry();",
"public boolean isParent();",
"public boolean isCheckingDirtyChildPainters()\n/* */ {\n/* 254 */ return this.checkForDirtyChildPainters;\n/* */ }",
"public boolean hasNode() {\n return nodeBuilder_ != null || node_ != null;\n }",
"public boolean hasNode() {\n return nodeBuilder_ != null || node_ != null;\n }",
"@Override\r\n \tpublic boolean hasChildren() {\n \t\treturn getChildren().length > 0;\r\n \t}",
"public Boolean isRootNode();",
"public boolean isRoot() {\r\n return (_parent == null);\r\n }",
"private boolean _hasChild() {\r\n boolean ret = false;\r\n if (_childs != null && _childs.size() > 0) {\r\n ret = true;\r\n }\r\n\r\n return ret;\r\n }",
"public boolean isSetPlugin() {\n return this.plugin != null;\n }",
"public boolean hasPlugin() {\n return plugin != null;\n }",
"public boolean isContainer();",
"public boolean isTree() {\r\n\t\tif (isConnected() && !isCyclic())\r\n\t\t\treturn true;\r\n\t\treturn false;\r\n\t}",
"public boolean hasChildren()\n/* */ {\n/* 487 */ return !this.children.isEmpty();\n/* */ }",
"boolean isTopLevel();",
"public boolean hasRecursive() {\n return recursive_ != null;\n }",
"boolean isRoot()\n {\n return this.parent == null;\n }",
"protected boolean parentExists() {\n\n\t\tIRodinElement parentElement = getParent();\n\t\tif (parentElement == null)\n\t\t\treturn true;\n\t\treturn parentElement.exists();\n\t}",
"public boolean getSubtreeSearch()\n {\n return SearchScope.SUBTREE == this.getSearchScope();\n }",
"public boolean hasParent() {\n return getParent() != null;\n }",
"public boolean isRoot() {\n return !hasParent();\n }",
"public final boolean hasXmlTreePathValue ()\r\n {\r\n return _value.isXmlTreePath();\r\n }",
"public boolean isRoot() { return getAncestorCount()<2; }",
"@Override\n public boolean test() {\n return parentName.equals(themesComboBox.target().getSelectedItem().toString());\n }",
"public boolean isLeafContextNode();",
"boolean hasSkin();",
"public boolean isDisplayed() {\n return graphConfig.isDisplayed();\n }",
"boolean hasHasNodeSettings();",
"public final boolean hasChild ()\r\n {\r\n return _value.hasChild();\r\n }",
"public boolean isPaletteRoot() {\n return className == null \n && parent != null && parent.parent == null;\n }",
"public boolean isRoot()\r\n\t{\r\n\t\treturn (m_parent == null);\r\n\t}",
"public boolean hasGui() {\n return hasGui;\n }",
"boolean hasNode();",
"boolean hasNode();",
"public boolean isRoot(){\n\t\treturn bound.isRoot();\n\t}",
"public boolean isNotEmpty(){\n return root != null;\n }",
"public boolean hasTreeNodeId() {\n return treeNodeId_ != null;\n }",
"public boolean isRegistered()\n {\n return getRegistrationState().equals(RegistrationState.REGISTERED);\n }",
"public boolean isSetBrowse()\n {\n synchronized (monitor())\n {\n check_orphaned();\n return get_store().count_elements(BROWSE$2) != 0;\n }\n }",
"public boolean hasParent() {\r\n if (parent == null) \r\n return false;\r\n \r\n return true;\r\n }",
"public boolean isShowing() {\n return true; // Not supported for MenuComponents\n }",
"public Boolean isParentable();",
"boolean hasIsNodeOf();",
"public boolean isRootVisible()\n {\n return rootVisible;\n }",
"public boolean isRootVisible()\n {\n return rootVisible;\n }",
"public boolean isBST() {\n\t\treturn isBST(root, Integer.MIN_VALUE, Integer.MAX_VALUE);\n\t}",
"public boolean isSupportsChildren() {\n return supportsChildren;\n }",
"public boolean containsContextNodes();",
"public boolean isBST() {\n\t\treturn isBST(this, Integer.MIN_VALUE, Integer.MAX_VALUE);\n\t}",
"static synchronized boolean isRegistered(Tool tool) {\n\t\treturn getTool(tool.getItem()) != null;\n\t}",
"public boolean isTreeBinarySearchTree() {\r\n\t\treturn isTreeBinarySearchTree(rootNode, Integer.MIN_VALUE, Integer.MAX_VALUE);\r\n\t}",
"public boolean hasObject() {\n return objectBuilder_ != null || object_ != null;\n }",
"public boolean isSet() {\n return !this.stack.isEmpty();\n }",
"public boolean hasParent() {\n return internalGroup.hasParent();\n }",
"public boolean getIsRootElement() {\r\n\t\treturn mIsRootElement;\r\n\t}",
"public boolean isDisplayed();",
"public boolean isVehicleListSideBarPresent() {\r\n\t\treturn isElementPresent(groupListSideBar.replace(\"Group List\", \"Vehicle List\"), SHORTWAIT);\r\n\t}",
"boolean isExpandScopeShadowRoot();",
"public boolean hasTopLevelNode(IAstTopLevelNode node);",
"boolean hasResourceType();",
"public boolean hasRenderers()\r\n {\r\n return !_renderers.isEmpty();\r\n }",
"protected final boolean isReady() {\n // check if visible (invisible components are ok to be not ready)\n if (!this.isVisible()) {\n return true;\n }\n if (!this.isDisplayable()) {\n return true;\n }\n // check if this is not ready\n if (!ready) {\n return false;\n }\n // check if any child is not ready\n for (BlankDialogModule module : childModules) {\n if (!module.isReady()) {\n return false;\n }\n }\n // all ready!\n return true;\n }",
"public boolean HasChildren() {\n\t\treturn left_ptr != null && right_ptr != null;\n\t}",
"protected final boolean isLeaf() {\n return (getChildIds().isEmpty());\n }",
"public boolean hasSubTaxa() {\n\t\treturn !children.isEmpty();\n\t}"
] | [
"0.6763279",
"0.66591895",
"0.63850504",
"0.629917",
"0.6167155",
"0.6146068",
"0.6082211",
"0.6027157",
"0.5967135",
"0.5967135",
"0.59512234",
"0.5940197",
"0.5897054",
"0.58907396",
"0.5889083",
"0.5866355",
"0.585837",
"0.58375126",
"0.58350116",
"0.5816483",
"0.5790825",
"0.57760286",
"0.5764529",
"0.5759199",
"0.5738143",
"0.57347864",
"0.57227457",
"0.569845",
"0.56889266",
"0.568582",
"0.56708074",
"0.5653211",
"0.5651193",
"0.5641892",
"0.56368876",
"0.56293386",
"0.5619386",
"0.5616006",
"0.56096995",
"0.56096995",
"0.5595697",
"0.5582916",
"0.5578668",
"0.5572039",
"0.5563449",
"0.5562527",
"0.55621725",
"0.5557344",
"0.5554429",
"0.555411",
"0.5547208",
"0.5545874",
"0.5544744",
"0.5541339",
"0.55207473",
"0.5517488",
"0.55036855",
"0.55015194",
"0.5494771",
"0.54930145",
"0.5486584",
"0.5484584",
"0.5483749",
"0.54837376",
"0.5483187",
"0.5482595",
"0.54647577",
"0.5462341",
"0.5462341",
"0.54517525",
"0.54503405",
"0.5446197",
"0.54400957",
"0.5428842",
"0.54254967",
"0.54204506",
"0.54104215",
"0.5408589",
"0.54043496",
"0.54043496",
"0.5397774",
"0.53923696",
"0.53870904",
"0.53826356",
"0.5377573",
"0.5374882",
"0.53730726",
"0.53702027",
"0.5369648",
"0.536776",
"0.5366778",
"0.5366398",
"0.5362719",
"0.5361883",
"0.5351494",
"0.5351382",
"0.5345901",
"0.53444344",
"0.5340256",
"0.53362584"
] | 0.7891037 | 0 |
/ public abstract int getValidMinHeight(); public abstract int getValidMinWidth(); public abstract void setValidWidth(int width); public abstract void setValidHeight(int height); public abstract void setHeight(int height); public abstract void setWidth(int width); public abstract void setSize(int width, int height); | public abstract void setSize(Dimension d); | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"abstract public int getMinHeight();",
"protected abstract void setSize();",
"public void setMinSize(double aWidth, double aHeight) { setMinWidth(aWidth); setMinHeight(aHeight); }",
"@Override\n\tpublic void setWidthAndHeight(int width, int height) {\n\t\t\n\t}",
"abstract public int getMinWidth();",
"public abstract Dimension getSize();",
"public void setMinimumSize( int width, int height ) {\n checkWidget();\n Point point = parent.fixPoint( width, height );\n minimumWidth = point.x;\n minimumHeight = point.y;\n }",
"public abstract boolean init(int width, int height);",
"@Test\n public final void testValidGetSize() {\n int expRes = 5;\n int result = ship.getSize();\n assertEquals(expRes, result);\n expRes = 19;\n ship.setSize(expRes);\n result = ship.getSize();\n assertEquals(expRes, result);\n }",
"public void size(final int theWidth, final int theHeight);",
"public void setSize();",
"private interface Dimension {\n\n\t/**\n\t * @return The placeholder width in px.\n\t */\n\tint getWidth();\n\n\t/**\n\t * @return The placeholder height in px.\n\t */\n\tint getHeight();\n\n }",
"public void setSize(double aWidth, double aHeight) { setWidth(aWidth); setHeight(aHeight); }",
"public void setSize(float width, float height);",
"void setSize(float w, float h) {\n _w = w;\n _h = h;\n }",
"public abstract int getYSize();",
"private void basicSize(){\n setSize(375,400);\n }",
"public interface Size extends Quality {\n\n /**\n * Returns the size of an shape in terms of width.\n */\n double getWidth();\n\n /**\n * Returns the size of an shape in terms of height.\n */\n double getHeight();\n\n}",
"void setSize(Dimension size);",
"@Test\n\tpublic void testGetWidthHeight() {\n\t\tassertTrue(auto.getHeight()==15);\n\t\tassertTrue(auto.getWidth()==15);\n\t}",
"public CommonPopWindow setSize(int width, int height) {\n/* 140 */ this.mWidth = width;\n/* 141 */ this.mHeight = height;\n/* 142 */ return this;\n/* */ }",
"public abstract VehicleSize getSize();",
"public abstract int getSize();",
"public abstract int getSize();",
"public abstract int getSize();",
"public abstract int getSize();",
"public int getSetSize(){ return Integer.parseInt(setSize.getText()); }",
"public int getMinSize() {\n return minSize;\n }",
"@Override\n\tpublic Point getMinSize() {\n\t\treturn Parameter.SPRITE_MIN_SIZE;\n\t}",
"public abstract int getWidth();",
"@Override\n public Position setSize(double w, double h) {\n return new Position(w, h);\n }",
"@Override\n public void settings() {\n setSize(WIDTH, HEIGHT);\n }",
"public abstract int getXSize();",
"@Override\n public Dimension getMinimumSize()\n {\n return getPreferredSize();\n }",
"@Override\r\n public Dimension getMinimumSize() {\r\n return getPreferredSize();\r\n }",
"void setDimension(double width, double height);",
"public boolean isCorrectSize(int height, int width);",
"Rectangle(double newWidth, double newHeight){\n height = newHeight;\n width = newWidth;\n }",
"public abstract int GetSize();",
"public boolean isMinHeightSet() { return get(\"MinHeight\")!=null; }",
"public void setMinHeight(double aHeight)\n{\n double h = aHeight<=0? 0 : aHeight; if(h==getMinHeight()) return;\n firePropertyChange(\"MinHeight\", put(\"MinHeight\", h), h, -1);\n}",
"protected abstract void resize();",
"@Override\r\n public void resize(int width, int height) {\r\n\r\n }",
"public void setSize( int width, int height ) {\n checkWidget();\n int newHeight = height;\n int newWidth = width;\n Point point = parent.fixPoint( newWidth, newHeight );\n newWidth = Math.max( point.x, minimumWidth + MINIMUM_WIDTH );\n newHeight = Math.max( point.y, 0 );\n if ( !ideal ) {\n preferredWidth = newWidth;\n preferredHeight = newHeight;\n }\n itemBounds.width = requestedWidth = newWidth;\n itemBounds.height = newHeight;\n if ( control != null ) {\n int controlWidth = newWidth - MINIMUM_WIDTH;\n if ( (style & SWT.DROP_DOWN) != 0 && newWidth < preferredWidth ) {\n controlWidth -= CHEVRON_IMAGE_WIDTH + CHEVRON_HORIZONTAL_TRIM\n + CHEVRON_LEFT_MARGIN;\n }\n control.setSize( parent.fixPoint( controlWidth, newHeight ) );\n }\n parent.relayout();\n updateChevron();\n }",
"public abstract double getBaseWidth();",
"public abstract float getSquareSize();",
"public Point getMinimumSize() {\n checkWidget();\n return parent.fixPoint( minimumWidth, minimumHeight );\n }",
"@Override\n public void resize(int width, int height) {\n\n }",
"public abstract double getBaseHeight();",
"public RMSize getSize() { return new RMSize(getWidth(), getHeight()); }",
"@Override\n public void resize(int width, int height) {\n }",
"public void setSize(int size) {\n\tthis.sizeNumber = sizeNumber;\r\n}",
"@Override\r\n\tpublic void resize(int width, int height) {\n\r\n\t}",
"@Override\r\n\tpublic void resize(int width, int height) {\n\r\n\t}",
"@Override\r\n\tpublic void resize(int width, int height) {\n\r\n\t}",
"public void setPreferredSize( int width, int height ) {\n checkWidget();\n ideal = true;\n Point point = parent.fixPoint( width, height );\n preferredWidth = Math.max( point.x, MINIMUM_WIDTH );\n preferredHeight = point.y;\n }",
"@Override\n public void resize(int width, int height) {\n \n }",
"@Override\n\tpublic void resize(int width, int height) \n\t{\n\n\t}",
"@Override\n\tpublic void resize(int width, int height) {\n\n\t}",
"@Override\n\tpublic void resize(int width, int height) {\n\n\t}",
"@Override\n\tpublic void resize(int width, int height) {\n\n\t}",
"@Override\n\tpublic void resize(int width, int height) {\n\n\t}",
"@Override\n\tpublic void resize(int width, int height) {\n\n\t}",
"@Override\n\tpublic void resize(int width, int height) {\n\n\t}",
"@Override\n\tpublic void resize(int width, int height) {\n\n\t}",
"@Override\n\tpublic void resize(int width, int height) {\n\n\t}",
"@Override\n\tpublic void resize(int width, int height) {\n\n\t}",
"@Override\n\tpublic void resize(int width, int height) {\n\n\t}",
"public Size(double width, double height)\r\n {\r\n this.width = width;\r\n this.height = height;\r\n }",
"@Override\n\tpublic void resize(float width, float height) {\n\t}",
"@Override\n public Position getSize() {\n return new Position(this.w, this.h);\n }",
"public void setSize(int size);",
"@Override\n\tpublic void resize(int width, int height) {\n\t}",
"@Override\n\tpublic void resize(int width, int height) {\n\t}",
"@Override\n\tpublic void resize(int width, int height) {\n\t}",
"@Override\n\tpublic void resize(int width, int height) {\n\t}",
"public void setBestSize() { setSize(getBestWidth(), getBestHeight()); }",
"public void setSize(int x, int y)\n {\n \tthis.width = x;\n \tthis.height = y;\n }",
"@Override\n\tpublic void setBounds(int x, int y, int width, int height) {\n\t\t\n\t\t\n\t\tsuper.setBounds(x, y, width, height);\n\t}",
"@Override\r\n\tpublic void resize(int width, int height) {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void resize(int width, int height) {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void resize(int width, int height) {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void resize(int width, int height) {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void resize(int width, int height) {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void resize(int width, int height) {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void resize(int width, int height) {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void resize(int width, int height) {\n\t\t\r\n\t}",
"public interface Unresizable {\n void setSize();\n}",
"@Test\n public final void testSetSize() {\n int expRes = 5;\n int falseEnter = -4;\n ship.setSize(falseEnter);\n int result = this.ship.getSize();\n assertEquals(expRes, result);\n falseEnter = -1;\n ship.setSize(falseEnter);\n result = this.ship.getSize();\n assertEquals(expRes, result);\n }",
"public float getSizeX(){return sx;}",
"@Override\r\n\tpublic void resize(int width, int height) {\n\t}",
"@Override\n public void resize(int width, int height) {\n\n }",
"@Override\n\tpublic void resize(int width, int height)\n\t{\n\n\t}",
"public void setFrameSize();",
"public abstract int getHeight(int pWidth);",
"@Override\n\tpublic void resize(int width, int height) {\n\t\t\n\t}",
"@Override\n\tpublic void resize(int width, int height) {\n\t\t\n\t}",
"@Override\n\tpublic void resize(int width, int height) {\n\t\t\n\t}",
"@Override\n\tpublic void resize(int width, int height) {\n\t\t\n\t}",
"@Override\n\tpublic void resize(int width, int height) {\n\t\t\n\t}"
] | [
"0.72569376",
"0.7219508",
"0.7081311",
"0.7054746",
"0.67804706",
"0.66646254",
"0.6602996",
"0.649916",
"0.64783823",
"0.6470794",
"0.64674485",
"0.64610934",
"0.6450819",
"0.6449257",
"0.63470876",
"0.6324683",
"0.6323964",
"0.63233864",
"0.6297198",
"0.62738246",
"0.6271858",
"0.6252956",
"0.62383467",
"0.62383467",
"0.62383467",
"0.62383467",
"0.62306684",
"0.6225103",
"0.62210315",
"0.6176849",
"0.6174314",
"0.61699736",
"0.6158567",
"0.61546147",
"0.614818",
"0.6128266",
"0.60982364",
"0.6093454",
"0.6092795",
"0.60901636",
"0.60897565",
"0.608854",
"0.60765237",
"0.60692215",
"0.60590094",
"0.6053767",
"0.6046985",
"0.60458034",
"0.6044862",
"0.6042514",
"0.60374904",
"0.60360324",
"0.603138",
"0.603138",
"0.603138",
"0.6023145",
"0.60220915",
"0.60121894",
"0.6006342",
"0.6006342",
"0.6006342",
"0.6006342",
"0.6006342",
"0.6006342",
"0.6006342",
"0.6006342",
"0.6006342",
"0.6006342",
"0.6005433",
"0.60020685",
"0.59997296",
"0.5995114",
"0.5990311",
"0.5990311",
"0.5990311",
"0.5990311",
"0.59829825",
"0.5980194",
"0.5979819",
"0.59683156",
"0.59683156",
"0.59683156",
"0.59683156",
"0.59683156",
"0.59683156",
"0.59683156",
"0.59683156",
"0.596808",
"0.5964209",
"0.596319",
"0.59628195",
"0.5957694",
"0.59479",
"0.5942526",
"0.594137",
"0.593531",
"0.593531",
"0.593531",
"0.593531",
"0.593531"
] | 0.68167835 | 4 |
Checks if the widget is set to be visible or not. Doesn't check if the widget is actually drawn on screen. | public abstract boolean isVisible(); | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public boolean isShowing() {\n return visible;\n }",
"protected final boolean isShowing() {\n synchronized (getPeerTreeLock()) {\n if (isVisible()) {\n final LWContainerPeer<?, ?> container = getContainerPeer();\n return (container == null) || container.isShowing();\n }\n }\n return false;\n }",
"@Override // com.android.server.wm.WindowContainer\n public boolean isVisible() {\n return true;\n }",
"public boolean isVisible() {\n\t\treturn element.isDisplayed();\n\t}",
"@Override // com.android.server.wm.WindowContainer\n public boolean isVisible() {\n return true;\n }",
"public boolean isVisible(){\n \t\treturn visible;\n \t}",
"public final boolean isVisible() {\n return visible;\n }",
"public boolean isVisible () {\n return visible;\n }",
"boolean isVisible();",
"boolean isVisible();",
"public boolean isVisible() {\r\n return visible;\r\n }",
"public boolean isVisible() {\n return true;\n }",
"public boolean isVisible()\n {\n return visible;\n }",
"public static native boolean _isVisible(Element elem) /*-{\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\treturn (elem.style.display != 'none');\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t}-*/;",
"public boolean isVisible() {\n return true;\n }",
"public boolean isVisible() {\n\t\treturn visible;\n\t}",
"public boolean isVisible() {\r\n\t\t\tif (outOfRange()) {\r\n\t\t\t\treturn false;\r\n\t\t\t}\r\n\t\t\treturn true;\r\n\t\t}",
"public boolean isVisible();",
"public boolean isVisible();",
"public boolean isVisible();",
"public boolean isVisible() {\n\t\treturn true;\n\t}",
"@Override\n public boolean isVisible(){\n \n try\t{\n new WebDriverWait(driver, 1)\n .until((Function<? super WebDriver, ? extends Object>) ExpectedConditions.visibilityOfElementLocated(locator));\n \n return true;\n }\n catch (NoSuchElementException ex){\n return false;\n }\n catch (TimeoutException ex){\n return false;\n }\n \n }",
"public boolean checkVisibility() {\n LocalDateTime now = LocalDateTime.now();\n return (this.viewer != 0 && !now.isAfter(this.destructTime));\n }",
"public boolean isVisible(){ return visible; }",
"public boolean isAtLeastVisible(Visibility v);",
"public boolean isPanelVisibleBecauseOfHeadsUp() {\n return (this.mHeadsUpManager.hasPinnedHeadsUp() || this.mHeadsUpAnimatingAway) && this.mBarState == 0;\n }",
"public boolean isVisible()\n {\n return visible;\n }",
"public boolean isShown(){\r\n return shown;\r\n }",
"public boolean getBorderVisible() {\n checkWidget();\n return borderLeft == 1;\n }",
"@Override\n\tpublic boolean isVisible() {\n\t\treturn this.isVisible;\n\t}",
"public boolean isVisible(String place) {\n boolean result = false;\n WebElement element = getElement(place);\n if (element != null) {\n result = element.isDisplayed() && isElementOnScreen(element);\n }\n return result;\n }",
"@Override\r\n\tpublic boolean isVisible()\r\n\t{\n\t\treturn !getFormScreen().getMode().equals(Mode.LIST_VIEW);\r\n\t}",
"private boolean visible() {\r\n return NOT(GO() && CATS(Cc,Cn,Co,Cs,Zl,Zp)) && POINT();\r\n }",
"boolean isReadyForShowing();",
"public Boolean isVisible();",
"public Boolean isVisible();",
"public boolean isInvisible ( ) {\n\t\treturn extract ( handle -> handle.isInvisible ( ) );\n\t}",
"public boolean isVisible() { return _visible; }",
"public boolean getIsVisible();",
"public boolean isVisible(){\n\t\treturn this.visible;\n\t}",
"public boolean isDisplayed();",
"public boolean isTargetVisible() {\n return getDouble(\"tv\") == 1;\n }",
"@Override\n public boolean isVisible()\n {\n return true;\n }",
"public java.lang.Boolean getIsVisible();",
"@UnsupportedAppUsage\n public boolean isVisible() {\n return mSearchDialog == null? false : mSearchDialog.isShowing();\n }",
"public boolean isShowing() {\n\t\tLinearLayout loading = (LinearLayout) findViewById(R.id.loading);\n\t\treturn loading.getVisibility() == View.VISIBLE;\n\t}",
"public boolean isVisible(){\n if(hideMenu) {\n hideMenu = false;\n return true;\n }\n\n return isMenuVisible;\n }",
"public boolean isDisplayed() {\n return isValid() && (getLastSeen() > System.currentTimeMillis() - DAYS_30);\n }",
"private synchronized void monitorWidgetVisibility(GridPane gridPane, StackPane stackPane)\n {\n boolean showing = false;\n List<Node> widgets = stackPane.getChildren();\n for (Node widget : widgets)\n {\n if (widget.isVisible())\n {\n showing = widget.isVisible();\n }\n }\n\n gridPane.setVisible(showing);\n }",
"boolean isDisplayed();",
"public boolean getVisible() {\r\n return visible;\r\n }",
"public boolean getVisibility() {\n return GtkEntry.getVisibility(this);\n }",
"public final boolean isProgressBarVisible() {\r\n\r\n if ((pBarVisible == true) && (progressBar != null)) {\r\n return true;\r\n } else {\r\n return false;\r\n }\r\n }",
"public boolean isVisible() {\r\n return !((x + width) < ocean.getXmin() || x > ocean.getXmax() || (y + height) < ocean.getYmin()\r\n || y > ocean.getYmax());\r\n }",
"private boolean visibles() {\r\n return OPT(GO() && visible() && visibles());\r\n }",
"boolean isVisible() {\r\n return this.isVisible;\r\n }",
"protected boolean checkVisiblePermission() {\r\n ClientSecurityManager manager = ApplicationManager.getClientSecurityManager();\r\n if (manager != null) {\r\n if (this.visiblePermission == null) {\r\n if ((this.buttonKey != null) && (this.parentForm != null)) {\r\n this.visiblePermission = new FormPermission(this.parentForm.getArchiveName(), \"visible\",\r\n this.buttonKey, true);\r\n }\r\n }\r\n try {\r\n // Checks to show\r\n if (this.visiblePermission != null) {\r\n manager.checkPermission(this.visiblePermission);\r\n }\r\n this.restricted = false;\r\n return true;\r\n } catch (Exception e) {\r\n this.restricted = true;\r\n if (e instanceof NullPointerException) {\r\n ToggleButton.logger.error(null, e);\r\n }\r\n if (ApplicationManager.DEBUG_SECURITY) {\r\n ToggleButton.logger.debug(this.getClass().toString() + \": \" + e.getMessage(), e);\r\n }\r\n return false;\r\n }\r\n } else {\r\n return true;\r\n }\r\n }",
"@Override\n public boolean isShown() {\n return super.isShown();\n }",
"public boolean hasDisplay() {\n return displayBuilder_ != null || display_ != null;\n }",
"public boolean isVisible(Visibility v);",
"public boolean isShowing() {\n return true; // Not supported for MenuComponents\n }",
"public boolean isShowing() {\n return getRoot().isShowing();\n }",
"public boolean visible() {\n \treturn model.isVisible();\n }",
"@Override\n public boolean isVisible()\n {\n return !this.isDead();\n }",
"public boolean isDisplayed() \n\t\t\t\t{\n\t\t\t\t\treturn false;\n\t\t\t\t}",
"public boolean isSetDisplay() {\n return this.display != null;\n }",
"@Override\r\n\tpublic boolean isVisible() {\n\t\treturn false;\r\n\t}",
"public boolean canBeSeen()\n {\n if (!this.hasParent() || !this.isVisible())\n {\n return false;\n }\n\n GuiElement element = this;\n\n while (true)\n {\n if (!element.isVisible())\n {\n return false;\n }\n\n GuiElement parent = element.getParent();\n\n if (parent instanceof GuiDelegateElement && ((GuiDelegateElement) parent).delegate != element)\n {\n return false;\n }\n\n if (parent == null)\n {\n break;\n }\n\n element = parent;\n }\n\n return element instanceof GuiBase.GuiRootElement;\n }",
"public final boolean isOnScreen() {\n\t\treturn Calculations.isOnScreen(this.getCenterPointOnScreen());\n\t}",
"@Override\n\tpublic boolean isShowing() {\n\t\treturn false;\n\t}",
"boolean updateVisibility() {\n boolean honorsVisibility;\n if (this.honorsVisibility == null) {\n honorsVisibility = GroupLayout.this.getHonorsVisibility();\n } else {\n honorsVisibility = this.honorsVisibility;\n }\n boolean newVisible = (honorsVisibility) ?\n component.isVisible() : true;\n if (visible != newVisible) {\n visible = newVisible;\n return true;\n }\n return false;\n }",
"public boolean isShowingInCallUi() {\n return (isActivityStarted() && mInCallActivity.isVisible());\n }",
"public boolean getVisible() {\n\t\treturn visible;\n\t}",
"public boolean getVisible() {\n\t\treturn visible;\n\t}",
"public boolean okToDisplay() {\n return this.mDisplayId == 0 ? !this.mWmService.mDisplayFrozen && this.mWmService.mDisplayEnabled && this.mWmService.mPolicy.isScreenOn() : this.mDisplayInfo.state == 2;\n }",
"public void setVisible()\r\n\t{\r\n\t\tthis.setVisible(true);\r\n\t}",
"public void visible() {\n\n setSize(canvasW, canvasH);\n setResizable(false);\n setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);\n setVisible(true);\n }",
"public boolean isMakeVisible()\r\n {\r\n return myMakeVisible;\r\n }",
"public boolean isCastOverLayShown() {\n if (currentContext != null) {\n SharedPreferences sharedPrefs = currentContext.getSharedPreferences(CASTING_OVERLAY_PREF_NAME, 0);\n return sharedPrefs.getBoolean(CAST_SHARED_PREF_NAME, false);\n }\n return false;\n }",
"public void setVisible(Boolean visible);",
"public boolean onlyVisible()\n\t{\n\t\treturn visible;\n\t}",
"public static boolean isShownOrQueued() {\n\treturn SnackbarMessage.mLastMessage != null && SnackbarMessage.mLastMessage.isShown();\n}",
"public boolean isVBarShowing() { return getVBar().getParent()!=null; }",
"@Override\n public void setVisible(boolean arg0)\n {\n \n }",
"public boolean getIsVisible()\n\t{\n\t\tif (getParentFragment() != null && getParentFragment() instanceof BaseFragment)\n\t\t{\n\t\t\treturn isVisible() && ((BaseFragment) getParentFragment()).getIsVisible();\n\t\t}\n\t\telse\n\t\t{\n\t\t\treturn isVisible();\n\t\t}\n\t}",
"public static boolean displayed(WebElement element){\n waitForVisibility(element);\n return element.isDisplayed();\n }",
"public void setVisible(Boolean isVisible);",
"public boolean isVisible(Position screenRes) {\n if (coords.fitsIn(screenRes)) {\n return true;\n } else {\n return false;\n }\n }",
"public static native void _setVisible(Element elem, boolean visible) /*-{\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\telem.style.display = visible ? '' : 'none';\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t}-*/;",
"public boolean isSetShowAnimation()\n {\n synchronized (monitor())\n {\n check_orphaned();\n return get_store().find_attribute_user(SHOWANIMATION$20) != null;\n }\n }",
"public boolean shown();",
"void onControlVisibilityChange(Object object, boolean visible);",
"public void setIsVisible(boolean isVisible);",
"public final boolean isCursorVisible() {\n // If cursor is out of my bounds, it is not visible.\n if ((cursorX >= width)\n || (cursorX < 0)\n || (cursorY >= height)\n || (cursorY < 0)\n ) {\n return false;\n }\n\n // If cursor is out of my window's bounds, it is not visible.\n if ((getCursorAbsoluteX() >= window.getAbsoluteX()\n + window.getWidth() - 1)\n || (getCursorAbsoluteX() < 0)\n || (getCursorAbsoluteY() >= window.getAbsoluteY()\n + window.getHeight() - 1)\n || (getCursorAbsoluteY() < 0)\n ) {\n return false;\n }\n return cursorVisible;\n }",
"@Override\n\tpublic void setVisible(boolean b) {\n\t\t\n\t}",
"public boolean isPickVisible() {\n\t\treturn false;\n\t}",
"public boolean isProgressBarVisible() {\r\n return pBarVisible;\r\n }",
"public boolean isDisplayed() {\n return graphConfig.isDisplayed();\n }",
"@SuppressWarnings(\"unused\")\n void setVisible(boolean visible);"
] | [
"0.71216965",
"0.7089849",
"0.7042639",
"0.7032431",
"0.70146966",
"0.6905462",
"0.6901267",
"0.6877249",
"0.68558234",
"0.68558234",
"0.67975324",
"0.67968833",
"0.6794082",
"0.67547166",
"0.67455137",
"0.6744411",
"0.674234",
"0.67390907",
"0.67390907",
"0.67390907",
"0.6737603",
"0.6728575",
"0.6717651",
"0.6713493",
"0.67084575",
"0.6706812",
"0.67021596",
"0.6699603",
"0.6639862",
"0.6636219",
"0.6632121",
"0.66300076",
"0.6617987",
"0.6586521",
"0.65393597",
"0.65393597",
"0.65299773",
"0.65263796",
"0.6525181",
"0.6522424",
"0.6520209",
"0.647045",
"0.6468698",
"0.6446071",
"0.6443659",
"0.64094335",
"0.63911563",
"0.63910323",
"0.63860244",
"0.63785166",
"0.6358736",
"0.63512194",
"0.6339751",
"0.6335615",
"0.6330645",
"0.6326058",
"0.63222665",
"0.63111275",
"0.6296598",
"0.62938344",
"0.629293",
"0.6286532",
"0.6285186",
"0.62735856",
"0.6269881",
"0.6265583",
"0.6259907",
"0.6250218",
"0.6245723",
"0.62402076",
"0.62257963",
"0.62234914",
"0.6210099",
"0.6210099",
"0.6186745",
"0.6183972",
"0.6129881",
"0.61267835",
"0.6119996",
"0.61020255",
"0.60881317",
"0.606359",
"0.6051641",
"0.604974",
"0.6025034",
"0.5990156",
"0.5978357",
"0.59693325",
"0.59650487",
"0.59588695",
"0.59497184",
"0.5949512",
"0.5934695",
"0.5934528",
"0.59305006",
"0.5930071",
"0.59284425",
"0.59142977",
"0.5912852"
] | 0.63943225 | 47 |
Sets the visibility state of the widget. If set to false the widget will not be drawn and will not receive any events but takes its space (remains in the widgettree). Also all child elements will not be drawn or receive any events. | public abstract void setVisible(boolean visible); | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@Override\n\tpublic void setVisible(boolean visibility) {\n\t\t//do nothing\n\t}",
"@Override\n\tpublic void setVisible(boolean vis) {\n\t\t\n\t}",
"public void setVisible(boolean newVisible)\n {\n this.visible = newVisible;\n conditionallyRepaint();\n }",
"public void setVisible(Boolean visible);",
"public void setVisible(boolean visible);",
"public void setVisible(Boolean isVisible);",
"@SuppressWarnings(\"unused\")\n void setVisible(boolean visible);",
"@Override\n\tpublic void setVisibility(int visibility) {\n\t\tsuper.setVisibility(visibility);\n\t\tif(visibility==View.VISIBLE){\n\t\t\ttoggleOnAreaChange();\n\t\t}\n\t}",
"void setVisible(boolean visible);",
"void setVisible(boolean visible);",
"private void setVis(boolean b) {\n this.setVisible(b);\n }",
"public void setVisible(boolean val);",
"@Override\n\tpublic void setVisible(boolean b) {\n\t\t\n\t}",
"public void setVisible()\r\n\t{\r\n\t\tthis.setVisible(true);\r\n\t}",
"public void setVisible(boolean b) {\n\t\t\n\t}",
"public void setVisible(boolean value) {\n\t\tvisible = value;\n\t}",
"public void makeVisible() {\n if (isVisible()) {\n return;\n }\n pack();\n setVisible(true);\n }",
"public void setVisible( boolean v) {\r\n visible = v;\r\n }",
"public void setVisible(boolean visible){\r\n\t\tthis.visible = visible;\r\n\t}",
"public void setIsVisible(boolean isVisible);",
"public void setVisible(boolean visible)\n {\n this.visible = visible;\n }",
"public void setVisible(boolean visible) {\r\n this.visible = visible;\r\n }",
"public void setVisible (boolean visible) {\n this.visible = visible;\n }",
"public void setVisible(boolean v) {\n }",
"public void setVisible(boolean b) {\n\t\tsuper.setVisible(b);\n\n\t\tif (b)\n\t\t\tpaint(this.getGraphics());\n\t}",
"public void setIsVisible(java.lang.Boolean isVisible);",
"void setVisibleGlassPanel(Visibility visible);",
"public void setVisible(boolean val)\r\n\t{\r\n\t\t_isOn = val;\r\n\t}",
"@Override\n public void setVisibility(int visibility) {\n // For some reason FrameView does not forward visiblity to it children. So we manually\n // override it to do so. That way when this view is invisible or gone we don't show an ad.\n int originalVisiblity = super.getVisibility();\n\n if (originalVisiblity != visibility) {\n synchronized (this) {\n // Forward the visibility event to all the children.\n int children = getChildCount();\n\n for (int i = 0; i < children; i++) {\n View child = getChildAt(i);\n child.setVisibility(visibility);\n }\n\n // Continue processing the event.\n super.setVisibility(visibility);\n\n // Get or remove ads depending on visiblity.\n if (visibility == View.VISIBLE) {\n requestFreshAd();\n } else {\n // Remove the old ad so we fade into the new one.\n removeView(ad);\n ad = null;\n invalidate();\n }\n }\n }\n }",
"public void setVisible(boolean value)\n\t{\n\t\tisVisible = value;\n\t\tif(!isVisible)\n\t\t{\n\t\t\tsetWorldRegion(null);\n\t\t}\n\t}",
"void setIsVisible(boolean visible) {\r\n this.isVisible = visible;\r\n this.getComponent().setVisible(isVisible);\r\n }",
"final void setVisible(boolean visible) {\n this.visible = visible;\n }",
"public void setDisplayVisibility(boolean on) {\n if (settingVisibility) {\n return;\n }\n super.setDisplayVisibility(on);\n applyVisibilityFlags();\n }",
"public static native void _setVisible(Element elem, boolean visible) /*-{\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\telem.style.display = visible ? '' : 'none';\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t}-*/;",
"@Override\n public void setVisible(boolean arg0)\n {\n \n }",
"public void setVisibility(int visibility)\n {\n for (Button b : this.buttons)\n {\n b.setVisibility(visibility);\n }\n }",
"public void setVisible(boolean visible)\n\t{\n\t\tsuper.setVisible(visible);\n\t\trequestFocus();\n\t}",
"public void setInvisible ( boolean invisible ) {\n\t\texecute ( handle -> handle.setInvisible ( invisible ) );\n\t}",
"public void setVisible(boolean b) {\n // Not supported for MenuComponents\n }",
"public void hide() {\n isVisible = false;\n this.saveBorderColor(Color.BLACK);\n this.setBorderColor(Color.BLACK);\n }",
"public void visibility(boolean state){ this.table.setVisible(state);}",
"public void setVisible(boolean v) {\n\t\tif (v) {\n\t\t\trequestFocus();\n\t\t}\n\t\tsuper.setVisible(v);\n\t}",
"public void hide() {\n visible=false;\n }",
"@Override\n public void setVisible (boolean f)\n { \n }",
"public void setVisible(boolean is_visible){\n\t\tswingComponent.setVisible(is_visible);\n\t}",
"public void toggle()\n\t{\n\t\tsetVisible(!this.isShowing());\n\t}",
"public void setVisible(boolean newVal) {\n if (newVal != visible) {\n visible = newVal;\n listeners.firePropertyChange(PROPERTY_VISIBLE, !visible, visible);\n }\n }",
"public void setVisible(boolean b) {\n\t\tframe.setVisible(b);\t\n\t}",
"public void setVisible(boolean visible) {\n window.setVisible(visible);\n }",
"public void setVisibility(int value) {\n this.visibility = value;\n }",
"public void setInvisible(boolean b)\n\t{\n\t\t_invisible = b;\n\t}",
"void setVisibility(Layer layer, boolean visibility);",
"public void setVisible(boolean a){\n \t\tvisible = a;\n \t}",
"public Visible (boolean visible) {\n setVisible(visible);\n }",
"void toggleMenuButtonVisibility(boolean visible) {\n exitButton.setVisible(visible);\n addTimelineButton.setVisible(visible);\n addEventButton.setVisible(visible);\n saveButton.setVisible(visible);\n deleteButton.setVisible(visible);\n }",
"private synchronized void setVisible(boolean b)\n {\n Platform.runLater(() ->\n {\n this.temperatureView.setVisible(b);\n StackPane parentPane = (StackPane) this.temperatureView.getParent();\n GridPane parentGrid = (GridPane) parentPane.getParent();\n\n monitorWidgetVisibility(parentGrid, parentPane);\n });\n if (b && this.townName != null)\n {\n updateWeather(this.townName);\n }\n }",
"public void setVisible(boolean visible)\n {\n frame.setVisible(visible);\n }",
"public void setVisible(boolean visible) {\n\t\tframe.setVisible(visible);\n\t}",
"public void setHidden(boolean value) {\r\n this.hidden = value;\r\n }",
"public void setHidden(Boolean hidden){\n m_hidden = hidden;\n }",
"public void setVisible()\n\t{\n\t\tMainController.getInstance().setVisible(name, true);\n\t}",
"private boolean setVisible(boolean b) {\n\t\treturn b;\n\t}",
"public void setVisible(boolean bool)\r\n\t{\r\n\t\tsuper.setVisible(bool);\r\n\t\tif(bool == true)\r\n\t\t{\r\n\t\ttry {\r\n\t\t\tThread.sleep(1000);\r\n\t\t\tlblServerFound.setVisible(true);\r\n\t\t\tbtnClose.setVisible(true);\r\n\t\t} catch (InterruptedException e) {\r\n\t\t\t\te.printStackTrace();\r\n\t\t}\r\n\t\t\r\n\t\t}\r\n\t\t\t\r\n\r\n\t}",
"public boolean isVisible(){\n \t\treturn visible;\n \t}",
"public void show() {\n visible=true;\n }",
"private void setVisible(JTextField a, boolean b) {\n\t\ta.setVisible(b);\r\n\t}",
"public void setVisible(boolean visible) {\n internalGroup.setVisible(visible);\n dataTrait.visible = visible;\n }",
"public void hideIt(){\n this.setVisible(false);\n }",
"@Override\n\tpublic void setVisible(boolean visible) {\n\t\tsuper.setVisible(visible);\n\t\tif (this.getMenuItems() != null) {\n\t\t\tfor (CFComponentMenuItem item : this.getMenuItems()) {\n\t\t\t\titem.setVisible(visible);\n\t\t\t}\n\t\t}\n\t}",
"@Override\r\n\tpublic boolean isVisible() {\n\t\treturn false;\r\n\t}",
"void toggleVisible (ActionEvent actionEvent) {\n element.visible = this.isSelected();\n }",
"public void setUnselectedCloseVisible( final boolean visible ) {\n checkWidget();\n if( showUnselectedClose != visible ) {\n showUnselectedClose = visible;\n updateItems();\n }\n }",
"@Override\n\tpublic void setVisible (boolean visible)\n\t{\n\t\tif (visible)\n\t\t{\n\t\t\t//this.updateLayerList();\n\t\t\t//this.updateConstrainedLayerList();\n\t\t}\n\t\telse\n\t\t{\n\t\t\t// Update the amount of deformation.\n\t\t\tmCartogramWizard.setAmountOfDeformation(\n\t\t\t\tmDeformationSlider.getValue());\n\t\t\t\t\n\t\t}\n\t\t\n\t\tsuper.setVisible(visible);\n\t}",
"public boolean isVisible(){ return visible; }",
"public void visible() {\n\n setSize(canvasW, canvasH);\n setResizable(false);\n setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);\n setVisible(true);\n }",
"public void setHide()\n\t{\n\t\tMainController.getInstance().setVisible(name, false);\n\t}",
"public boolean isVisible()\n {\n return visible;\n }",
"public static aVisibility setVisibility()\n {\n read_if_needed_();\n \n return _set_visibility;\n }",
"public void setVisible(boolean visible)\n\t{\n\t\tshaderMaterial.setUniform(\"AMBIENT\", \"isVisible\", new UniformBool(\n\t\t\t\tvisible));\n\t}",
"private void setContentVisible(CONST.VISIBLE visible) {\n if (layoutEmpty != null && contentScrollLayout != null && progressView != null) {\n switch (visible) {\n case EMPTY:\n layoutEmpty.setVisibility(View.VISIBLE);\n contentScrollLayout.setVisibility(View.INVISIBLE);\n progressView.setVisibility(View.GONE);\n break;\n case PROGRESS:\n layoutEmpty.setVisibility(View.GONE);\n contentScrollLayout.setVisibility(View.INVISIBLE);\n progressView.setVisibility(View.VISIBLE);\n break;\n default: // Content\n layoutEmpty.setVisibility(View.GONE);\n contentScrollLayout.setVisibility(View.VISIBLE);\n progressView.setVisibility(View.GONE);\n }\n } else {\n Timber.e(new RuntimeException(), \"Setting content visibility with null views.\");\n }\n }",
"public void hide() {\n hidden = true;\n }",
"public void setProgressTextVisibility(boolean visibility){\n this.textVisibility = visibility;\n }",
"public boolean isVisible () {\n return visible;\n }",
"public void showUI(boolean isVisible) {\r\n \r\n psui.setVisible(isVisible);\r\n }",
"public final boolean isVisible() {\n return visible;\n }",
"public boolean isVisible() {\r\n return visible;\r\n }",
"public void setVisible(boolean visibile) {\n\t\tthis.visible = visibile;\n\t\tfor (GameObject gameObject : objects) {\n\t\t\tgameObject.setVisible(visibile);\n\t\t}\n\t}",
"public void setVisible(boolean value)\n {\n super.setVisible(value);\n\n // Set the focus\n if (value && !errorFound())\n {\n setCurrentFocus(amountField);\n }\n }",
"public boolean isVisible() { return _visible; }",
"public static void setVisible (boolean isVisible)\n\t{\n\t\tm_console.setVisible (isVisible);\n\t}",
"public boolean isVisible()\n {\n return visible;\n }",
"public void setIconListVisibility(boolean visibility) {\n FloatingActionButton fab = (FloatingActionButton) findViewById(R.id.floatingActionButtonList);\n if (visibility == true) {\n fab.setVisibility(View.VISIBLE);\n } else {\n fab.setVisibility(View.INVISIBLE);\n }\n }",
"public void changeHasInvisibility()\r\n\t{\r\n\t\thasInvisibility = !hasInvisibility;\r\n\t}",
"public void setCursorVisible(boolean visible){\n for(int c=0;c<getChildCount();c++){\n getFieldAt(c).setCursorVisible(visible);\n }\n }",
"public void setUnselectedImageVisible( final boolean visible ) {\n checkWidget();\n if( showUnselectedImage != visible ) {\n showUnselectedImage = visible;\n updateItems();\n }\n }",
"@Override\n\tpublic void setVisible(boolean visible) {\n\t\tsuper.setVisible(visible);\n\t\tif (visible && invalidFieldEditor != null) {\n\t\t\tinvalidFieldEditor.setFocus();\n\t\t}\n\t}",
"public void setVisible(boolean visible) {\n\t\t// when the visible becomes true to false, ExtraLife restarts.\n\t\tif(visible == false && this.visible == true) {\n\t\t\tif(restartTimer != null) {\n\t\t\t\trestartTimer.cancel();\n\t\t\t}\n\t\t\trestartTimer = new Timer();\n\t\t\trestartTimer(0);\n\t\t}\n\t\tthis.visible = visible;\n\t}",
"public static void setVisible() {\r\n\t\tfrmMfhEmailer.setVisible(true);\r\n\t}",
"public boolean isVisible() {\n\t\treturn visible;\n\t}",
"public void setDisplayed(boolean show);"
] | [
"0.72827023",
"0.71724266",
"0.7127721",
"0.71173394",
"0.7108997",
"0.70756",
"0.7061048",
"0.7042339",
"0.70102364",
"0.70102364",
"0.7005197",
"0.6948994",
"0.6948135",
"0.6932805",
"0.68944836",
"0.6877895",
"0.6872385",
"0.6842068",
"0.6838468",
"0.6826108",
"0.6815749",
"0.6784668",
"0.67833894",
"0.67825997",
"0.6714989",
"0.6706814",
"0.66675603",
"0.66648567",
"0.6637383",
"0.66320455",
"0.6629917",
"0.6625331",
"0.66243047",
"0.66041404",
"0.6601891",
"0.65875125",
"0.65749025",
"0.65288997",
"0.6510167",
"0.65079874",
"0.6439498",
"0.6434034",
"0.6420528",
"0.64202976",
"0.6403617",
"0.6393776",
"0.63849753",
"0.6300657",
"0.6296907",
"0.62941533",
"0.62929827",
"0.62869537",
"0.6273639",
"0.6244002",
"0.62370414",
"0.61988395",
"0.6198607",
"0.61481214",
"0.6139717",
"0.6127446",
"0.6113591",
"0.6106842",
"0.60881716",
"0.60842484",
"0.6052839",
"0.60441595",
"0.60431033",
"0.60312235",
"0.602736",
"0.5995946",
"0.59912366",
"0.5985155",
"0.5981944",
"0.5975501",
"0.5971895",
"0.59711486",
"0.5957532",
"0.5953735",
"0.5948858",
"0.59433687",
"0.5938079",
"0.5933578",
"0.5926953",
"0.59195584",
"0.5910176",
"0.5905333",
"0.59011644",
"0.5891802",
"0.58748823",
"0.58691144",
"0.58676296",
"0.5867406",
"0.5860746",
"0.58549625",
"0.5842716",
"0.58423215",
"0.582759",
"0.58220315",
"0.5820416",
"0.5800284"
] | 0.67275965 | 24 |
Returns the TooltipData object associated with this widget or null if there is none. | public abstract ITooltipData getTooltipData(); | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public TooltipOptions getTooltip() {\n return this.tooltip;\n }",
"public IFigure getTooltip() {\n return this.tooltip;\n }",
"String getTooltip() {\n return mTooltip;\n }",
"public String getTooltip() {\n\t\treturn tooltip;\n\t}",
"@Nullable\n\tdefault String getTooltip()\n\t{\n\t\treturn null;\n\t}",
"public JToolTip getCustomToolTip() {\n // to be overwritten by subclasses\n return null;\n }",
"@Override\n public StringTextComponent getTooltip() {\n return this.tooltip;\n }",
"public TooltipDisplay getTooltipDisplay();",
"public String getToolTipText() {\n return this.toString();\n }",
"@Exported(visibility = 999)\n public String getTooltip() {\n return tooltip;\n }",
"String getTooltip() {\n return bufTip;\n }",
"public String getToolTip() {\n\treturn this.toolTip;\n }",
"@Override\n public String getTooltip()\n {\n return null;\n }",
"public static String getToolTipText() {\n\t\treturn (toolTipText);\n\t}",
"public String getToolTipText () {\r\n\tcheckWidget();\r\n\treturn toolTipText;\r\n}",
"@Override\r\n public String getTooltip() {\r\n return TOOLTIP;\r\n }",
"public abstract void setTooltipData(ITooltipData data);",
"public FakeToolTip getFakeToolTip() {\n\t\treturn fakeToolTip;\n\t}",
"public String getToolTipText() {\n\t\treturn \"\";\r\n\t}",
"default void setTooltip(@Nullable String tooltip) {}",
"public ToolTipView getToolTipView() { return _toolTipView; }",
"public Object[] getTooltipTokens() {\n return null;\n }",
"public JToolTip createToolTip(){\n return new CreatureTooltip(this);\n }",
"protected DecoratorString<ARXNode> getTooltipDecorator() {\n return this.tooltipDecorator;\n }",
"public SafeHtml getTooltip(C value) {\n return tooltipFallback;\n }",
"public void setTooltipText() { tooltip.setText(name); }",
"public abstract String getToolTip();",
"TooltipTextMap getTooltipText() throws SearchServiceException;",
"public DateFormat getTooltipDateFormat() {\r\n return calendarTable.getTooltipDateFormat();\r\n }",
"public Optional<String> tooltip(double[] coord) {\n return Optional.empty();\n }",
"@Override\r\n\tpublic String getToolTipText() {\n\t\treturn \"\";\r\n\t}",
"public java.lang.String getTip()\n {\n return this.tip;\n }",
"public String getToolTipText() {\n\t\t\treturn fragname.toString();\n\t\t}",
"public void setTooltip(TooltipOptions tooltip) {\n this.tooltip = tooltip;\n }",
"public double getTip() {\r\n return tipCalculator.getCalculatedTip();\r\n }",
"public String getColdTips(){\n\t\ttry{\n\t\t\treturn jsonData.get(\"ganmao\").getAsString();\n\t\t} catch (Exception e) {\n\t\t\te.printStackTrace();\n\t\t}\n\t\treturn null;\n\t}",
"default String getTooltip() {\n throw new UnsupportedOperationException();\n }",
"@Override\n public void setTooltip(String arg0)\n {\n \n }",
"protected String getToolTip( MouseEvent event )\n {\n SmartText descr = new SmartText();\n int column = treeTable.columnAtPoint( event.getPoint() );\n if ( column == 0 )\n {\n int row = treeTable.rowAtPoint( event.getPoint() );\n if ( row == 0 )\n {\n descr.setText( componentModel.getTypeDescription() );\n }\n else\n {\n Object value = treeTable.getValueAt( row, 1 );\n if ( value instanceof Property )\n {\n Property p = ( Property )value;\n descr.setText( p.getToolTip() );\n }\n }\n\n // perform line wrapping now\n descr.setText( \"<html>\" + descr.insertBreaks( \"<br>\", toolTipWidth, true ) + \"</html>\" );\n return descr.toString();\n }\n return null;\n }",
"@Override\r\n\tpublic IFigure getTooltip(Object entity) {\n\t\tif (entity instanceof GraphNode) {\r\n\t\t\tGraphNode node = (GraphNode) entity;\r\n\t\t\treturn new Label(node.getName());\r\n\t\t} else if (entity instanceof EntityConnectionData) {\r\n\t\t\tEntityConnectionData conn = (EntityConnectionData) entity;\r\n\t\t\tGraphNode caller = (GraphNode) conn.source;\r\n\t\t\tGraphNode callee = (GraphNode) conn.dest;\r\n\t\t\treturn new Label(caller.getName() + \"-\" + callee.getName());\r\n\t\t}\r\n\t\treturn null;\r\n\t}",
"public String getRibbonToolTipText()\n\t{\n\t\treturn ribbonToolTipText;\n\t}",
"public BoxPlotChartConfiguration withTooltip(TooltipOptions tooltip) {\n setTooltip(tooltip);\n return this;\n }",
"public String getTabToolTipText();",
"@Override\n\tpublic String getToolTipText() {\n\t\treturn \"shopEditorToolTipText\";\n\t}",
"@Override\n\tpublic void setToolTip(String tooltip) {\n\t\t\n\t}",
"public String getToolTip ()\r\n\t{\r\n\t\tif (!((imageName.equals(\"GND\")) || (imageName.equals(\"VCC\")) || (imageName.equals(\"BOX\")) || (imageName.equals(\"OUTPUT\"))))\r\n\t\t{\r\n\t\t\tthis.toolTip = \"<html><img src=\"+this.imageName+\"></html>\";\r\n\t\t\treturn this.toolTip;\r\n\t\t}\r\n\t\t\r\n\t\telse if (imageName.equals(\"GND\"))\r\n\t\t\treturn \"GND\";\r\n\t\t\r\n\t\telse if (imageName.equals(\"VCC\"))\r\n\t\t\treturn \"VCC\";\r\n\t\t\r\n\t\telse if (imageName.equals(\"OUTPUT\"))\r\n\t\t\treturn \"Output window\";\r\n\t\t\r\n\t\telse\r\n\t\t\treturn \"TODO\";\r\n\t}",
"@RecentlyNullable\n/* */ public CharSequence getTooltipText() {\n/* 1556 */ throw new RuntimeException(\"Stub!\");\n/* */ }",
"public int getTip() {\n\t\treturn tip;\n\t}",
"public String getToolTip(ViewEvent anEvent)\n {\n LineMarker<?>[] markers = getMarkers();\n LineMarker<?> marker = ArrayUtils.findMatch(markers, m -> m.contains(_mx, _my));\n return marker != null ? marker.getToolTip() : null;\n }",
"@Override\n public String getToolTipText (final MouseEvent mEvent) {\n return getText();\n }",
"@Override\r\n\tpublic String getTips() {\n\t\treturn null;\r\n\t}",
"public void setTooltipDisplay(TooltipDisplay tooltipDisplay);",
"String getTooltipContent(WebElement field){\n String tooltip = null;\n String tooltipId = field.getAttribute(\"aria-describedby\");\n By tooltipLocator = By.id(tooltipId);\n WebElement tooltipField = driver.findElement(tooltipLocator);\n tooltip = tooltipField.getText();\n System.out.println(\"** tooltip value: \" + tooltip);\n return tooltip;\n }",
"public T getData() {\n return null;\n }",
"public boolean isShowToolTip()\n {\n return showToolTip;\n }",
"public X tooltipText(String text) {\n component.setToolTipText(text);\n return (X) this;\n }",
"public String getHover() { return (String)get(\"Hover\"); }",
"public String getTooltipDatePattern() {\r\n return calendarTable.getTooltipDatePattern();\r\n }",
"private Tooltip generateToolTip(ELesxFunction type) {\n Tooltip tool = new Tooltip();\n StringBuilder text = new StringBuilder();\n if (type == ELesxFunction.PERIOD) {\n text.append(\"Una fecha puede ser invalida por:\\n\")\n .append(\" - Fecha incompleta.\\n\")\n .append(\" - Fecha inicial es posterior a la final.\");\n }\n else {\n text.append(\"La función Suma determina:\\n\")\n .append(\" - Sumatoria total de los precios del recurso seleccionado.\\n\")\n .append(\" - Suma el total de la sumatoria del punto anterior si son varios recursos\\n\")\n .append(\" - Ignora las Fechas de los precios.\");\n }\n tool.setText(text.toString());\n return tool;\n }",
"final public boolean isTooltipsVisible()\n {\n return ComponentUtils.resolveBoolean(getProperty(TOOLTIPS_VISIBLE_KEY), true);\n }",
"@Override\r\n\tpublic String getToolTipText(MouseEvent event) {\r\n return toolTipWriter.write(getToolTipText(), event.getPoint());\r\n }",
"@SuppressWarnings(\"deprecation\")\n public String getToolTipText(JTextComponent t, Point pt) {\n if (!painted) {\n return null;\n }\n Document doc = editor.getDocument();\n String tt = null;\n Rectangle alloc = getVisibleEditorRect();\n\n if (alloc != null) {\n if (doc instanceof AbstractDocument) {\n ((AbstractDocument)doc).readLock();\n }\n try {\n tt = rootView.getToolTipText(pt.x, pt.y, alloc);\n } finally {\n if (doc instanceof AbstractDocument) {\n ((AbstractDocument)doc).readUnlock();\n }\n }\n }\n return tt;\n }",
"private void initializeTooltips() {\n\t\ttooltipPitch = new Tooltip();\n\t\tbuttonInfoPitch.setTooltip(tooltipPitch);\n\n\t\ttooltipGain = new Tooltip();\n\t\tbuttonInfoGain.setTooltip(tooltipGain);\n\n\t\ttooltipEcho = new Tooltip();\n\t\tbuttonInfoEcho.setTooltip(tooltipEcho);\n\n\t\ttooltipFlanger = new Tooltip();\n\t\tbuttonInfoFlanger.setTooltip(tooltipFlanger);\n\n\t\ttooltipLowPass = new Tooltip();\n\t\tbuttonInfoLowPass.setTooltip(tooltipLowPass);\n\t}",
"public JLabel getDataHora() {\n return dataHora;\n }",
"private Tip createTip(final int tipSetId) {\n\n Tip tip = null;\n\n if (tipSetId > 0) {\n final JSONObject jsonTipSet = lookupTipSet(tipSetId);\n final JSONArray jsonTips = (JSONArray) jsonTipSet.get(\"tip\");\n\n final JSONObject jsonTip = getRandomJsonObject(jsonTips);\n\n tip = new Tip();\n tip.setTipId((Integer) jsonTip.get(\"tipId\"));\n tip.setText((String) jsonTip.get(\"text\"));\n }\n\n return tip;\n }",
"public Object getData() {\r\n if (data != null) {\r\n return data;\r\n }\r\n ValueBinding vb = getValueBinding(\"data\");\r\n if (vb != null) {\r\n return vb.getValue(getFacesContext());\r\n } else {\r\n \r\n if(!Beans.isDesignTime()){\r\n setChartTitle(getChartTitle() + \" with default data\");\r\n }\r\n return DEFAULT_DATA;\r\n }\r\n }",
"public String generateToolTip(ContourDataset data, int item) {\n/* */ String xString;\n/* 83 */ double x = data.getXValue(0, item);\n/* 84 */ double y = data.getYValue(0, item);\n/* 85 */ double z = data.getZValue(0, item);\n/* */ \n/* */ \n/* 88 */ if (data.isDateAxis(0)) {\n/* 89 */ SimpleDateFormat formatter = new SimpleDateFormat(\"MM/dd/yyyy hh:mm:ss\");\n/* */ \n/* 91 */ StringBuffer strbuf = new StringBuffer();\n/* 92 */ strbuf = formatter.format(new Date((long)x), strbuf, new FieldPosition(false));\n/* */ \n/* */ \n/* 95 */ xString = strbuf.toString();\n/* */ } else {\n/* */ \n/* 98 */ xString = this.valueForm.format(x);\n/* */ } \n/* 100 */ if (!Double.isNaN(z)) {\n/* 101 */ return \"X: \" + xString + \", Y: \" + this.valueForm\n/* 102 */ .format(y) + \", Z: \" + this.valueForm\n/* 103 */ .format(z);\n/* */ }\n/* */ \n/* 106 */ return \"X: \" + xString + \", Y: \" + this.valueForm\n/* 107 */ .format(y) + \", Z: no data\";\n/* */ }",
"public static String getToolTipOfObject(By byObj) throws IllegalArgumentException, IllegalAccessException, InterruptedException, IOException {\n\t\tString tooltip = \"\";\n\t\tString t1 = driver.findElement(byObj).getAttribute(\"tooltip-text\");\n\t\tif(t1!=null) {\n\t\t\ttooltip = t1;\n\t\t}\n\t\telse {\n\t\t\thoverMouseToObject(byObj);\n\t\t\tsnooze(1000);\n\t\t\tif(getExistentStatus(byToolTip_Object)) {\n\t\t\t\tString t2 = driver.findElement(byToolTip_Object).getText();\n\t\t\t\ttooltip = t2;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tString objectName = getObjectName(byObj);\n\t\t\t\ttooltip = \"\";\n\t\t\t\tTestNotify.warning(GenLogTC() + \"There is no tooltip for the object [\" + objectName +\"].\");\n\t\t\t}\n\t\t}\t\n\t\treturn tooltip;\n\t}",
"public final FontCallback<DatasetContext> getHoverFontCallback() {\n\t\treturn hoverFontCallback;\n\t}",
"public Object getData() {\n\t\t\treturn null;// this.element;\n\t\t}",
"public amdocs.iam.pd.webservices.bundlecomponents.bundledetailsinputimpl.DataCustom getDataCustom()\n {\n synchronized (monitor())\n {\n check_orphaned();\n amdocs.iam.pd.webservices.bundlecomponents.bundledetailsinputimpl.DataCustom target = null;\n target = (amdocs.iam.pd.webservices.bundlecomponents.bundledetailsinputimpl.DataCustom)get_store().find_element_user(DATACUSTOM$2, 0);\n if (target == null)\n {\n return null;\n }\n return target;\n }\n }",
"public BubbleData getBubbleData() { return (BubbleData)this.mData; }",
"public String getToolTip(int columnIndex) {\n\t\t//@formatter:off\n\t\tList<ColumnConstraintSet<R, ?>> filtered =\n\t\t\tconstraintSets.stream()\n\t\t\t\t.filter(cf -> cf.getColumnModelIndex() == columnIndex)\n\t\t\t\t.collect(Collectors.toList());\n\t\t//@formatter:on\n\n\t\tif (filtered.isEmpty()) {\n\t\t\treturn null;\n\t\t}\n\t\treturn getHtmlRepresentation(filtered);\n\t}",
"public String getQtip() {\n return qtip;\n }",
"void showTooltip();",
"public void setToolTipText (String string) {\r\n\tcheckWidget();\r\n\ttoolTipText = string;\r\n}",
"public T getData() {\r\n\t\t\treturn t;\r\n\t\t}",
"@Override\n\t\tpublic int getToolTipDisplayDelayTime(Object object) {\n\t\t\treturn 2;\n\t\t}",
"public DatasetItem getDatasetItem() {\n return (attributes.containsKey(KEY_DATASET_ITEM) ? (DatasetItem) attributes\n .get(KEY_DATASET_ITEM) : null);\n }",
"public void setTooltip(IFigure tooltip) {\n hasCustomTooltip = true;\n this.tooltip = tooltip;\n updateFigureForModel(nodeFigure);\n }",
"public abstract String getTipForTextField();",
"public static String setToolTipText(String text) {\n\t\tString oldTip = toolTipText;\n\t\ttoolTipText = text;\n\t\treturn (oldTip);\n\t}",
"public void deleteToolTip() {\r\n\t\tString expectedTooltip = \"Delete\";\r\n\t\tWebElement editTooltip = driver.findElement(By.cssSelector(\".ant-btn.ant-btn-danger.ant-btn-circle\"));\r\n\t\tActions actions = new Actions(driver);\r\n\t\tactions.moveToElement(editTooltip).perform();\r\n\t\tWebElement toolTipElement = driver.findElement(By.cssSelector(\"div[role='tooltip']\"));\r\n\t\tneedToWait(2);\r\n\t\tString actualTooltip = toolTipElement.getText();\r\n\t\tSystem.out.println(\"Actual Title of Tool Tip +++++++++\" + actualTooltip);\r\n\t\tAssert.assertEquals(actualTooltip, expectedTooltip);\r\n\t}",
"public void setToolTipExtractor(FeatureTextExtractor toolTipExtractor)\n\t{\n\t\tif (toolTipExtractor == null)\n\t\t\tthrow new NullPointerException(\"toolTipExtractor is null\");\n\n\t\tthis.toolTipExtractor = toolTipExtractor;\n\t}",
"public void createToolTip(View view, Tooltip.Gravity gravity, String text){\n Tooltip.make(getContext(),\n new Tooltip.Builder(101)\n .anchor(view, gravity)\n .closePolicy(new Tooltip.ClosePolicy()\n .insidePolicy(true, false)\n .outsidePolicy(true, false), 3000)\n .activateDelay(800)\n .showDelay(300)\n .text(text)\n .maxWidth(700)\n .withArrow(true)\n .withOverlay(true)\n .withStyleId(R.style.ToolTipLayoutCustomStyle)\n .floatingAnimation(Tooltip.AnimationBuilder.DEFAULT)\n .build()\n ).show();\n }",
"@Override\n public boolean hasTooltip() {\n AbstractComponentState state = getState();\n if (state.description != null && !state.description.equals(\"\")) {\n return true;\n } else if (state.errorMessage != null && !state.errorMessage.equals(\"\")) {\n return true;\n } else {\n return false;\n }\n }",
"@Override\r\n\tpublic String getToolTipText(MouseEvent e) {\r\n\t\tMCLParticleSet particles = model.getParticles();\r\n\t\tif (particles == null) return null;\r\n\t\t\r\n\t\t// If the mouse is on a article, show its weight\r\n\t\tfloat x = e.getX()/ parent.pixelsPerUnit + viewStart.x;\r\n\t\tfloat y = (getHeight() - e.getY())/ parent.pixelsPerUnit + viewStart.y;\r\n\t\tint i = particles.findClosest(x,y);\r\n\t\tMCLParticle part = particles.getParticle(i);\r\n\t\tPose p = part.getPose(); \r\n\t\tif (Math.abs(p.getX() - x) <= 2f && Math.abs(p.getY() - y) <= 2f) return \"Weight \" + part.getWeight();\r\n\t\telse return null;\r\n\t}",
"public Timestamp getTimestamp() {\r\n for (int i = 0; i < eventFields.size(); i++) {\r\n EventDataEntry currentEntry = eventFields.get(i);\r\n if (currentEntry.getColumnName().equalsIgnoreCase(\"timestamp\")) {\r\n return (Timestamp) currentEntry.getValues().getFirst();\r\n }\r\n }\r\n return null;\r\n }",
"public DefaultTip() {}",
"public HelpTopic getCurrentItem() {\n return position < 0 ? null : getItem(position);\n }",
"public void setTooltipHandler(CanvasType.TooltipHandler handler)\r\n\t{\n\t}",
"public void editToolTip() {\r\n\t\tString expectedTooltip = \"Edit\";\r\n\t\tWebElement editTooltip = driver.findElement(By.cssSelector(\".ant-btn.ant-btn-primary.ant-btn-circle\"));\r\n\t\tActions actions = new Actions(driver);\r\n\t\tactions.moveToElement(editTooltip).perform();\r\n\t\tWebElement toolTipElement = driver.findElement(By.cssSelector(\"div[role='tooltip']\"));\r\n\t\tneedToWait(2);\r\n\t\tString actualTooltip = toolTipElement.getText();\r\n\t\tSystem.out.println(\"Actual Title of Tool Tip +++++++++\" + actualTooltip);\r\n\t\tAssert.assertEquals(actualTooltip, expectedTooltip);\r\n\t}",
"public String getTip(int tipNo) {\n\t\treturn tips.get(tipNo);\n\t}",
"protected Boolean hasToolTipText(Object value) {\n\t\treturn false;\n }",
"public Object getLegendPlacement() {\r\n if (legendPlacement != null) {\r\n return legendPlacement;\r\n }\r\n ValueBinding vb = getValueBinding(\"legendPlacement\");\r\n return vb != null ? vb.getValue(getFacesContext()) : \"bottom\";\r\n }",
"public void createToolTip(View view, Tooltip.Gravity gravity, String text){\n Tooltip.make(this,\n new Tooltip.Builder(101)\n .anchor(view, gravity)\n .closePolicy(new Tooltip.ClosePolicy()\n .insidePolicy(true, false)\n .outsidePolicy(true, false), 3000)\n .activateDelay(800)\n .showDelay(300)\n .text(text)\n .maxWidth(700)\n .withArrow(true)\n .withOverlay(true)\n .withStyleId(R.style.ToolTipLayoutCustomStyle)\n .floatingAnimation(Tooltip.AnimationBuilder.DEFAULT)\n .build()\n ).show();\n }",
"String getHoverDetail();",
"T getData() {\n return null;\n }",
"public gov.nih.nlm.ncbi.www.SeqIdDocument.SeqId.Tpd getTpd()\r\n {\r\n synchronized (monitor())\r\n {\r\n check_orphaned();\r\n gov.nih.nlm.ncbi.www.SeqIdDocument.SeqId.Tpd target = null;\r\n target = (gov.nih.nlm.ncbi.www.SeqIdDocument.SeqId.Tpd)get_store().find_element_user(TPD$34, 0);\r\n if (target == null)\r\n {\r\n return null;\r\n }\r\n return target;\r\n }\r\n }",
"public int getWingTip() {\n if (arrowhead != null) {\n return arrowhead.getWingTip();\n }\n return 0;\n }"
] | [
"0.6877646",
"0.6655209",
"0.6489125",
"0.6478548",
"0.63196343",
"0.62750405",
"0.62419474",
"0.61954606",
"0.6189636",
"0.61869884",
"0.61141753",
"0.6032647",
"0.5998912",
"0.5974037",
"0.59040445",
"0.5817592",
"0.5774884",
"0.57347405",
"0.571772",
"0.562724",
"0.561749",
"0.56049085",
"0.5579986",
"0.55469096",
"0.553933",
"0.5398594",
"0.5380765",
"0.5376664",
"0.5285621",
"0.5280978",
"0.52683604",
"0.5252743",
"0.5240181",
"0.5158626",
"0.51565915",
"0.5123239",
"0.5058339",
"0.49860057",
"0.4945487",
"0.49403796",
"0.4898155",
"0.48834348",
"0.48720247",
"0.4859408",
"0.48483568",
"0.48132932",
"0.48005864",
"0.47944945",
"0.4785165",
"0.47816396",
"0.4770498",
"0.47287124",
"0.4716426",
"0.4691052",
"0.4690779",
"0.46884215",
"0.46612585",
"0.46378672",
"0.45906076",
"0.4572277",
"0.4566936",
"0.45551872",
"0.45431092",
"0.45421678",
"0.45404112",
"0.4538144",
"0.45223618",
"0.45081714",
"0.44926962",
"0.44917706",
"0.44813383",
"0.44571137",
"0.44541934",
"0.44477412",
"0.4420706",
"0.4417281",
"0.44137394",
"0.4397843",
"0.4356092",
"0.43544254",
"0.4353583",
"0.43535778",
"0.43530566",
"0.43332812",
"0.4328195",
"0.43254668",
"0.43166155",
"0.43163118",
"0.43138582",
"0.43040648",
"0.43005085",
"0.4292926",
"0.42842636",
"0.42841387",
"0.4283374",
"0.42806026",
"0.42799136",
"0.42783153",
"0.42753085",
"0.42712373"
] | 0.67050177 | 1 |
Sets the tooltipdata object for this widget. Set it to null to remove the tooltipdata object. | public abstract void setTooltipData(ITooltipData data); | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void setTooltip(TooltipOptions tooltip) {\n this.tooltip = tooltip;\n }",
"public void setTooltip(IFigure tooltip) {\n hasCustomTooltip = true;\n this.tooltip = tooltip;\n updateFigureForModel(nodeFigure);\n }",
"@Override\n\tpublic void setToolTip(String tooltip) {\n\t\t\n\t}",
"default void setTooltip(@Nullable String tooltip) {}",
"public void setTooltipText() { tooltip.setText(name); }",
"@Override\n public void setTooltip(String arg0)\n {\n \n }",
"protected void setToolTip(String toolTip) {\n\tthis.toolTip = toolTip;\n }",
"protected void setToolTipErrorMessage() {\n\t\tString toolTipErrorMessage = null;\n\t\tsetToolTipMessage(toolTipErrorMessage);\n\t}",
"@Override\n public String getTooltip()\n {\n return null;\n }",
"public void setToolTipText (String string) {\r\n\tcheckWidget();\r\n\ttoolTipText = string;\r\n}",
"public void setToolTipExtractor(FeatureTextExtractor toolTipExtractor)\n\t{\n\t\tif (toolTipExtractor == null)\n\t\t\tthrow new NullPointerException(\"toolTipExtractor is null\");\n\n\t\tthis.toolTipExtractor = toolTipExtractor;\n\t}",
"public void setToolTipProvider(ToolTipProvider provider) {\n mToolTipProvider = provider;\n setToolTipText(mToolTipProvider == null ? null : \"\");\n }",
"public abstract ITooltipData getTooltipData();",
"public void setTooltipDisplay(TooltipDisplay tooltipDisplay);",
"public void setToolTipText(String text)\n/* */ {\n/* 227 */ putClientProperty(\"ToolTipText\", text);\n/* */ }",
"public String getToolTipText() {\n\t\treturn \"\";\r\n\t}",
"@Override\r\n\tpublic String getToolTipText() {\n\t\treturn \"\";\r\n\t}",
"public static String setToolTipText(String text) {\n\t\tString oldTip = toolTipText;\n\t\ttoolTipText = text;\n\t\treturn (oldTip);\n\t}",
"public void setTargDataPoint(DataPoint aDP)\n{\n if(SnapUtils.equals(aDP, _targPoint)) return;\n firePropChange(TargDataPoint_Prop, _targPoint, _targPoint = aDP);\n _toolTipView.reloadContents();\n}",
"private void setToolTips() {\n \t// set tool tips\n Tooltip startTip, stopTip, filterTip, listViewTip, viewAllTip, viewInfoTip, removeTip, editRuleFileTip, editRulePathTip;\n startTip = new Tooltip(ToolTips.getStarttip());\n stopTip = new Tooltip(ToolTips.getStoptip());\n filterTip = new Tooltip(ToolTips.getFiltertip());\n listViewTip = new Tooltip(ToolTips.getListviewtip());\n viewAllTip = new Tooltip(ToolTips.getViewalltip());\n viewInfoTip = new Tooltip(ToolTips.getViewinfotip());\t\n removeTip = new Tooltip(ToolTips.getRemovetip());\n editRuleFileTip = new Tooltip(ToolTips.getEditrulefiletip());\n editRulePathTip = new Tooltip(ToolTips.getEditrulepathtip());\n \n startButton.setTooltip(startTip);\n stopButton.setTooltip(stopTip);\n filterButton.setTooltip(filterTip);\n unseenPacketList.setTooltip(listViewTip);\n viewAll.setTooltip(viewAllTip);\n viewInformation.setTooltip(viewInfoTip);\n removeButton.setTooltip(removeTip);\n editRuleFileButton.setTooltip(editRuleFileTip);\n editRuleFilePath.setTooltip(editRulePathTip);\n }",
"@Override\n protected void processUnhover() {\n \n Dialog.getInstance().hideTooltip();\n }",
"public JToolTip getCustomToolTip() {\n // to be overwritten by subclasses\n return null;\n }",
"public TooltipOptions getTooltip() {\n return this.tooltip;\n }",
"@Override\n public StringTextComponent getTooltip() {\n return this.tooltip;\n }",
"public void setTooltipText(@RecentlyNullable CharSequence tooltipText) {\n/* 1572 */ throw new RuntimeException(\"Stub!\");\n/* */ }",
"@Override\n\tpublic void setTip(double tip) {\n\t\t\n\t}",
"String getTooltip() {\n return mTooltip;\n }",
"public String getTooltip() {\n\t\treturn tooltip;\n\t}",
"private void initializeTooltips() {\n\t\ttooltipPitch = new Tooltip();\n\t\tbuttonInfoPitch.setTooltip(tooltipPitch);\n\n\t\ttooltipGain = new Tooltip();\n\t\tbuttonInfoGain.setTooltip(tooltipGain);\n\n\t\ttooltipEcho = new Tooltip();\n\t\tbuttonInfoEcho.setTooltip(tooltipEcho);\n\n\t\ttooltipFlanger = new Tooltip();\n\t\tbuttonInfoFlanger.setTooltip(tooltipFlanger);\n\n\t\ttooltipLowPass = new Tooltip();\n\t\tbuttonInfoLowPass.setTooltip(tooltipLowPass);\n\t}",
"@Nullable\n\tdefault String getTooltip()\n\t{\n\t\treturn null;\n\t}",
"public void setTooltipHandler(CanvasType.TooltipHandler handler)\r\n\t{\n\t}",
"private void setTooltip() {\n\t\tif (buttonAddScannable != null && !buttonAddScannable.isDisposed()) {\n\t\t\tgetParentShell().getDisplay().asyncExec(() -> buttonAddScannable.setToolTipText(\"Select scannable to add to list...\"));\n\t\t}\n\t}",
"public String getToolTip() {\n\treturn this.toolTip;\n }",
"private void setAllToolTip() {\n\t\tDeviceSettingsController.setAllToolTip(tooltipAndErrorProperties, deviceName.getText(), vendorId, productId,\n\t\t\t\tmanufacture, productString, autoGenerateSerialNumber, serialNumber, serialNumberIncrement,\n\t\t\t\tenableRemoteWakeup, powerConfiguration, Endpoint_1, fifoBusWidth, fifoClockFrequency, enableDebugLevel,\n\t\t\t\tdebugValue, gpio1, gpio2, gpio3, gpio4, gpio5, gpio6, gpio7, interFaceType, uvcVersion,\n\t\t\t\tuvcHeaderAddition, enableFPGA, fpgaFamily, browseBitFile, i2cSlaveAddress, deviceSttingFirmWare,\n\t\t\t\tdeviceSttingI2CFrequency);\n\t}",
"public ToolTipView getToolTipView() { return _toolTipView; }",
"private static void setValueTips(Series<String, Number> series1) {\n \tfor (Data<String, Number> entry : series1.getData()) { \n Tooltip t = new Tooltip(entry.getYValue().toString());\n Tooltip.install(entry.getNode(), t);\n }\n }",
"public void removePlotData() {\n\t\tif (xySeries != null) {\n\t\t\tfor (int i = 0; i < xySeries.length; i++) {\n\t\t\t\tif (xySeries[i] != null) {\n\t\t\t\t\txySeries[i].clear();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tseriesCount = 0;\n\t\txySeries = new XYSeries[seriesCount + 1];\n\t}",
"String getTooltip() {\n return bufTip;\n }",
"public DefaultTip() {}",
"public void clearData() {\r\n\t\tdata = null;\r\n\t}",
"@Override\r\n public String getTooltip() {\r\n return TOOLTIP;\r\n }",
"public Object[] getTooltipTokens() {\n return null;\n }",
"public BoxPlotChartConfiguration withTooltip(TooltipOptions tooltip) {\n setTooltip(tooltip);\n return this;\n }",
"public X tooltipText(String text) {\n component.setToolTipText(text);\n return (X) this;\n }",
"public MultipleToolTipManager()\n {\n\tthis(null);\n }",
"public JToolTip createToolTip(){\n return new CreatureTooltip(this);\n }",
"public IFigure getTooltip() {\n return this.tooltip;\n }",
"public void setTip(java.lang.String tip)\n {\n this.tip = tip;\n }",
"public Builder clearMsgTip() {\n \n msgTip_ = getDefaultInstance().getMsgTip();\n onChanged();\n return this;\n }",
"void onDeactivate() {\n\t\t/* Hide the FakeToolTip that could be open in this moment */\n\t\tfakeToolTip.hide();\n\t}",
"public String getToolTipText () {\r\n\tcheckWidget();\r\n\treturn toolTipText;\r\n}",
"public void unsetDataCustom()\n {\n synchronized (monitor())\n {\n check_orphaned();\n get_store().remove_element(DATACUSTOM$2, 0);\n }\n }",
"public void unsetDataCustom()\n {\n synchronized (monitor())\n {\n check_orphaned();\n get_store().remove_element(DATACUSTOM$2, 0);\n }\n }",
"public FakeToolTip getFakeToolTip() {\n\t\treturn fakeToolTip;\n\t}",
"public static void resetGuiData()\n\t{\n\t\tpriorityCombo.select(0);\n\t\telectrodeCombo.select(0);\n\t\tcustomerList.removeAll();\n\t\tcustomerText.setText(\"\");\n\t\tcommentText.setText(\"\");\n\t\tsensorText.setText(\"\");\n\t\tmeasureText.setText(\"\");\n\t\tmeasurTaskText.setText(\"\");\n\t\tsensorTaskText.setText(\"\");\n\n\t}",
"public void setData(String data) {\n this.data = data == null ? null : data.trim();\n }",
"public void setData(String data) {\n this.data = data == null ? null : data.trim();\n }",
"public void setData(String data) {\n this.data = data == null ? null : data.trim();\n }",
"public void setToolTipText(String text, int index) {\n\t\tObject obj = getModel().getElementAt(index);\n\n\t\tif (obj instanceof IToolTipItem) {\n\t\t\t((IToolTipItem) obj).setToolTipText(text);\n\t\t}\n\t}",
"@Override\n\tpublic boolean isCustomTip() {\n\t\treturn false;\n\t}",
"public Builder setMsgTip(\n java.lang.String value) {\n if (value == null) {\n throw new NullPointerException();\n }\n \n msgTip_ = value;\n onChanged();\n return this;\n }",
"public void setPositionToolTipEnabled(boolean b) {\n enablePositionTooltip = b;\r\n }",
"public String getToolTipText() {\n return this.toString();\n }",
"@Override\n\tpublic void setCustomTip(boolean isCustomTip) {\n\t\t\n\t}",
"private void setNull() {\n\n this.txtExamDate.setDate(null);\n this.txtCourseName.setText(null);\n this.txtCourseName.requestFocus();\n }",
"protected void setToolTipText(Tile tile) {\n\t\tif(!peek && hidden) { tile.setToolTipText(\"concealed tile\"); }\n\t\telse {\n\t\t\tString addendum = \"\";\n\t\t\tif(playerpanel.getPlayer().getType()==Player.HUMAN) { addendum = \" - click to discard during your turn\"; }\n\t\t\ttile.setToolTipText(tile.getTileName()+ addendum); }}",
"public void setData(T data){\n this.data = data;\n }",
"public void setDataSrc(String dataSrc) {\n this.dataSrc = dataSrc == null ? null : dataSrc.trim();\n }",
"public void setData(Object data) {\r\n this.data = data;\r\n }",
"public void setData(Object oData) { m_oData = oData; }",
"@Override\n public void setBubbleChartData(BubbleChartData bubbleChartData) {\n this.data = bubbleChartData == null ? BubbleChartData.generateDummyData() : bubbleChartData;\n super.onChartDataChange();\n }",
"void setData(T data) {\n\t\tthis.data = data;\n\t}",
"public void setData(D data) {\n this.data = data;\n }",
"public void setData(Object data) {\n this.data = data;\n }",
"@Deprecated\n public void setDataObject(Object o) {\n this.dataObject = o;\n }",
"public static void setTooltip(final @NonNull Control control, final @NonNull String message) {\n Objects.requireNonNull(control);\n Objects.requireNonNull(message);\n\n if (message.isEmpty()) {\n throw new IllegalArgumentException(\"The message cannot be empty.\");\n }\n\n control.setTooltip(new Tooltip(message));\n }",
"public void deleteToolTip() {\r\n\t\tString expectedTooltip = \"Delete\";\r\n\t\tWebElement editTooltip = driver.findElement(By.cssSelector(\".ant-btn.ant-btn-danger.ant-btn-circle\"));\r\n\t\tActions actions = new Actions(driver);\r\n\t\tactions.moveToElement(editTooltip).perform();\r\n\t\tWebElement toolTipElement = driver.findElement(By.cssSelector(\"div[role='tooltip']\"));\r\n\t\tneedToWait(2);\r\n\t\tString actualTooltip = toolTipElement.getText();\r\n\t\tSystem.out.println(\"Actual Title of Tool Tip +++++++++\" + actualTooltip);\r\n\t\tAssert.assertEquals(actualTooltip, expectedTooltip);\r\n\t}",
"public void setRibbonToolTipText(String ribbonToolTipText)\n\t{\n\t\tthis.ribbonToolTipText = ribbonToolTipText;\n\t}",
"public T setUserData(Object data)\n\t{\n\t\tuserData = data;\n\t\treturn (T) this;\n\t}",
"@Exported(visibility = 999)\n public String getTooltip() {\n return tooltip;\n }",
"@Override\r\n\tpublic DTextArea setHtmlOnEmptied(final String script) {\r\n\t\tsuper.setHtmlOnEmptied(script) ;\r\n\t\treturn this ;\r\n\t}",
"public SafeHtml getTooltip(C value) {\n return tooltipFallback;\n }",
"public final void setDistinctData(java.lang.Boolean distinctdata)\r\n\t{\r\n\t\tsetDistinctData(getContext(), distinctdata);\r\n\t}",
"void showTooltip();",
"@Override\r\n\tprotected void setData(Object data) {\n\t\t\r\n\t}",
"public void setData(Data data) {\n this.data = data;\n }",
"public void setArrowTooltip(String arrowTooltip) {\r\r\n\t\tthis.arrowTooltip = arrowTooltip;\r\r\n\t}",
"public void resetData(@Nullable byte[] data) {\n this.data = data;\n if (data != null) {\n this.dataLength = data.length;\n } else {\n this.dataLength = -1;\n }\n }",
"public final void setDataUsage(java.lang.Boolean datausage)\r\n\t{\r\n\t\tsetDataUsage(getContext(), datausage);\r\n\t}",
"void resetData(ReadOnlyTaskManager newData);",
"public void setData(Object data) {\n\t\tthis.data = data;\n\t}",
"protected Boolean hasToolTipText(Object value) {\n\t\treturn false;\n }",
"@Override\r\n\tpublic void setData(E data) {\n\t\tthis.data=data;\r\n\t}",
"void resetUndoneData(ReadOnlyTaskManager newData);",
"public void setTipPercentage(double newTip) {\n tip = newTip;\n }",
"public void showData() {\n\t\tif(dataExample == null) dataExample = new DataExample();\n\t\tsetWidgetAsExample(dataExample);\n\t}",
"public void setToolTip (String imageName)\r\n\t{\r\n\t\tthis.imageName = imageName;\r\n\t}",
"void resetDoneData(ReadOnlyTaskManager newData);",
"public static String getToolTipText() {\n\t\treturn (toolTipText);\n\t}",
"private void initTooltips() {\n\t\ttooltips = new HashMap<String, String>();\n\t\ttooltips.put(\"-ref\", \n\t\t\t\t\"The “reference” image, the image that remains unchanged during the registration. Set this value to the downscaled brain you wish to segment\");\n\t\ttooltips.put(\"-flo\", \n\t\t\t\t\"The “floating” image, the image that is morphed to increase similarity to the reference. Set this to the average brain belonging to the atlas (aladin/f3d) or the atlas itself (resample).\");\n\t\ttooltips.put(\"-res\", \n\t\t\t\t\"The output path for the resampled floating image.\");\n\t\ttooltips.put(\"-aff\",\n\t\t\t\t\"The text file for the affine transformation matrix. The parameter can either be an output (aladin) or input (f3d) parameter.\");\n\t\ttooltips.put(\"-ln\",\n\t\t\t\t\"Registration starts with further downsampled versions of the original data to optimize the global fit of the result and prevent \"\n\t\t\t\t\t\t+ \"“getting stuck” in local minima of the similarity function. This parameter determines how many downsampling steps are being performed, \"\n\t\t\t\t\t\t+ \"with each step halving the data size along each dimension.\");\n\t\ttooltips.put(\"-lp\", \n\t\t\t\t\"Determines how many of the downsampling steps defined by -ln will have their registration computed. \"\n\t\t\t\t\t\t+ \"The combination -ln 3 -lp 2 will e.g. calculate 3 downsampled steps, each of which is half the size of the previous one \"\n\t\t\t\t\t\t+ \"but only perform the registration on the 2 smallest resampling steps, skipping the full resolution data.\");\n\t\ttooltips.put(\"-sx\", \"Sets the control point grid spacing in x. Positive values are interpreted as real values in mm, \"\n\t\t\t\t+ \"negative values are interpreted as distance in voxels. If -sy and -sz are not defined seperately, they are set to the value given here.\");\n\t\ttooltips.put(\"-be\",\"Sets the bending energy, which is the coefficient of the penalty term, preventing the freeform registration from overfitting. \"\n\t\t\t\t+ \"The range is between 0 and 1 (exclusive) with higher values leading to more restriction of the registration.\");\n\t\ttooltips.put(\"-smooR\", \"Adds a gaussian smoothing to the reference image (e.g. the brain to be segmented), with the sigma defined by the number. \"\n\t\t\t\t+ \"Positive values are interpreted as real values in mm, negative values are interpreted as distance in voxels.\");\n\t\ttooltips.put(\"-smooF\", \"Adds a gaussian smoothing to the floating image (e.g. the average brain), with the sigma defined by the number. \"\n\t\t\t\t+ \"Positive values are interpreted as real values in mm, negative values are interpreted as distance in voxels.\");\n\t\ttooltips.put(\"--fbn\", \"Number of bins used for the Normalized Mutual Information histogram on the floating image.\");\n\t\ttooltips.put(\"--rbn\", \"Number of bins used for the Normalized Mutual Information histogram on the reference image.\");\n\t\ttooltips.put(\"-outDir\", \"All output and log files will be written to this folder. Pre-existing files will be overwritten without warning!\");\n\t}"
] | [
"0.6221505",
"0.6106335",
"0.60997933",
"0.6058194",
"0.5984464",
"0.576394",
"0.5743476",
"0.5728072",
"0.5600651",
"0.5585482",
"0.53808165",
"0.5329224",
"0.5288088",
"0.52754456",
"0.5252927",
"0.52524704",
"0.52265275",
"0.5194852",
"0.5176245",
"0.51015025",
"0.509082",
"0.50408703",
"0.4964457",
"0.49459267",
"0.4936695",
"0.49210468",
"0.4915674",
"0.4899028",
"0.4890195",
"0.48844835",
"0.48789853",
"0.48543915",
"0.4851544",
"0.48471895",
"0.48371845",
"0.48098314",
"0.48047847",
"0.47882518",
"0.47816622",
"0.47716463",
"0.47547442",
"0.4753736",
"0.47507703",
"0.47451365",
"0.4742163",
"0.47201997",
"0.4698651",
"0.46842247",
"0.46704328",
"0.46641228",
"0.46608672",
"0.46413985",
"0.46413985",
"0.46319944",
"0.46272197",
"0.46224153",
"0.46224153",
"0.46224153",
"0.4619132",
"0.46125245",
"0.4591291",
"0.45832223",
"0.4559682",
"0.45520848",
"0.45511255",
"0.45485848",
"0.45411822",
"0.45132977",
"0.45113662",
"0.450421",
"0.4502774",
"0.44903895",
"0.4489523",
"0.4485295",
"0.4483596",
"0.44834033",
"0.44686028",
"0.44609156",
"0.44588643",
"0.4451424",
"0.44386038",
"0.4431106",
"0.4429183",
"0.44257006",
"0.44171983",
"0.44146666",
"0.44142464",
"0.44119334",
"0.44114652",
"0.4411248",
"0.44095773",
"0.44037837",
"0.43997005",
"0.43893167",
"0.43853948",
"0.4380002",
"0.43747422",
"0.4368047",
"0.4364398",
"0.43622553"
] | 0.68997836 | 0 |
Set a custom data object. This is a method to associate arbitrary data with a widget. It is not removed or overwritten by FengGUI. The Idea is to use a HashMap with defined keys to reference data objects. | public abstract void setCustomData(Object data); | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"void setData(Object data);",
"void setData (Object data);",
"public void setUserData(String key, Object data) {\n button.setUserData(key, data);\n }",
"public void setData(Object data) {\r\n this.data = data;\r\n }",
"public void setData(Object data) {\n this.data = data;\n }",
"public void setData(Object oData) { m_oData = oData; }",
"public void setUserData(Object data);",
"@Override\r\n\tprotected void setData(Object data) {\n\t\t\r\n\t}",
"abstract public void setUserData(Object data);",
"public void setData(Map<E, String> data) {\n\t\tthis.data = data;\n\t}",
"public void setData(Object data) {\n\t\tthis.data = data;\n\t}",
"public abstract void set(String key, T data);",
"void setObject(String id, Object data);",
"public void setData(T data){\n this.data = data;\n }",
"public void setData(@NotNull String key, @NotNull Object value) {\n data.put(key, value);\n }",
"void setUserData(Object userData);",
"public void setData(D data) {\n this.data = data;\n }",
"public void setData(Object o){}",
"public void setData(Data data) {\n this.data = data;\n }",
"public void setData(E data) {\r\n\t\tthis.data = data;\r\n\t}",
"public void setData(E data)\n {\n this.data = data;\n }",
"void setData(T data) {\n\t\tthis.data = data;\n\t}",
"void setObjectValue(Object dataObject);",
"public void setData(GenericItemType data) {\n this.data = data;\n }",
"public void setData(E data){\n\t\t\tthis.data = data;\n\t\t}",
"@Override\r\n\tpublic void setData(E data) {\n\t\tthis.data=data;\r\n\t}",
"public abstract void setData(Map<ID, T> data);",
"public void setData(IData data) {\n this.data = data;\n }",
"public void \n\tsetData(\n\t\t\tString key, \n\t\t\tObject value) \n\t{\n\t\ttry{\n\t\t\tthis_mon.enter();\n\n\t\t\tif (user_data == null) {\n\t\t\t\tuser_data = new HashMap();\n\t\t\t}\n\t\t\tif (value == null) {\n\t\t\t\tif (user_data.containsKey(key))\n\t\t\t\t\tuser_data.remove(key);\n\t\t\t} else {\n\t\t\t\tuser_data.put(key, value);\n\t\t\t}\n\t\t}finally{\n\t\t\tthis_mon.exit();\n\t\t}\n\t}",
"public void setData( E data ) {\n\t\tthis.data = data;\n\t}",
"public void setData(V data){\n\t\tthis.data = data;\n\t}",
"public void setData(LinkedHashMap<Integer, Data> data){\r\n\t\tthis.data = data;\r\n\t}",
"private void setUser(Map<String, Object> data) {\n this.setUser(ID(), data);\n }",
"void putValue(String key, Object data);",
"public void setData(Object d) {\n\t\t funcData = d; \n\t}",
"public void setData(String data) {\r\n this.data = data;\r\n }",
"void setData (Object newData) { /* package access */ \n\t\tdata = newData;\n\t}",
"public void setDataValue(String key, Object value) {\n\t\t if (value == null) {\n\t\t\t data.remove(key);\n\t\t }else {\n\t\t\t data.put(key, value);\n\t\t }\n\t }",
"public void setData(WrapperNBT data){\r\n\t\tsavedDataAccessor.internalData = data.tag;\r\n\t\tsavedDataAccessor.markDirty();\r\n\t\tworld.getPerWorldStorage().setData(savedDataAccessor.mapName, savedDataAccessor);\r\n\t}",
"public void setDataCustom(amdocs.iam.pd.webservices.bundlecomponents.bundledetailsinputimpl.DataCustom dataCustom)\n {\n synchronized (monitor())\n {\n check_orphaned();\n amdocs.iam.pd.webservices.bundlecomponents.bundledetailsinputimpl.DataCustom target = null;\n target = (amdocs.iam.pd.webservices.bundlecomponents.bundledetailsinputimpl.DataCustom)get_store().find_element_user(DATACUSTOM$2, 0);\n if (target == null)\n {\n target = (amdocs.iam.pd.webservices.bundlecomponents.bundledetailsinputimpl.DataCustom)get_store().add_element_user(DATACUSTOM$2);\n }\n target.set(dataCustom);\n }\n }",
"public void setData(String data) {\n this.data = data;\n }",
"public void setData(E d)\n {\n data = d;\n }",
"public void addData(F dataObject) {\r\n this.data = dataObject;\r\n }",
"public void setData(String key, String value) {\r\n\t\tdata.put(key, value);\r\n\t}",
"public void put(T data){\r\n\t\tthis.data = data;\r\n\t}",
"public void putData(HelperData data);",
"public void setData(String data) {\n\tthis.data = data;\n }",
"public void setDataObject(Object dataObj)\r\n {\r\n\r\n debug(\"setDataObject() - Set Data member Obj\");\r\n // Null out any reference to this data that may be present\r\n stockData = null;\r\n if (dataObj != null)\r\n {\r\n if (dataObj instanceof StockData)\r\n {\r\n stockData = (StockData) dataObj;\r\n }\r\n else if (dataObj instanceof String)\r\n {\r\n stockData = addSymbolToCurrentWatchList((String) dataObj);\r\n }\r\n\r\n }\r\n\r\n debug(\"setDataObject() - stockData is [\" + ((stockData == null) ? \"null\" : stockData.getName()) + \"]\");\r\n }",
"@Override\r\n\t\tpublic Object setUserData(String key, Object data, UserDataHandler handler)\r\n\t\t\t{\n\t\t\t\treturn null;\r\n\t\t\t}",
"public void put(WidgetData widgetData) {\n\t\tthis.put(widgetData.getId(), widgetData);\n\t}",
"@Override\n\tpublic void setDataCode(java.lang.String dataCode) {\n\t\t_dictData.setDataCode(dataCode);\n\t}",
"public void setData(String data) {\n _data = data;\n }",
"public void setData(java.lang.String data) {\r\n this.data = data;\r\n }",
"@Override\n\tpublic void setData() {\n\n\t}",
"@Override\n\tpublic void builder(String name, Object value)\n\t{\n\t\tthis._data.put( name, this.preprocessObject(value));\n\t}",
"@ZenCodeType.Method\n default void setAt(String name, @ZenCodeType.Nullable IData data) {\n \n put(name, data);\n }",
"private void setData() {\n\n }",
"public void setData(D s){\n\t\tdata = s;\n\t}",
"public void setData(Object[] data) {\n itsWidget.setReady(true);\n Slot slot = itsWidget.getKB().getSlot((String) data[0]);\n itsModel.initialize(listToStringArray(new ArrayList(slot.getAllowedValues())));\n return;\n }",
"public void setData(String data) {\n\t\tthis.data = data;\n\t}",
"public void setData(String data) {\n\t\tthis.data = data;\n\t}",
"public void setUserData(Object userData) {\n this.userData = userData;\n }",
"@Override\n\tpublic void setDataObject(DataObject arg0) throws DataBindingException {\n\n\t}",
"public void setDataOwner(String sDataOwner);",
"public void setUserData(Object argUserData) {\n userData = argUserData;\n }",
"public void addData(String dataName, Object dataItem){\r\n this.mData.put(dataName, dataItem);\r\n }",
"public void set(int index,Object data)\r\n\t{\r\n\t\tremove(index);\r\n\t\tadd(index, data);\r\n\t}",
"public PorqueBoxMetaData(Map<String, Object> data) {\n this.data = normalizeSectionNames( data );\n }",
"void set(String key, Object value);",
"public void setUserData (Object userData) {\n\t\tthis.userData = userData;\n\t}",
"@Override\n public void setUserData(final Object userData) {\n this.userData = userData;\n }",
"private void setUserData(){\n }",
"public void addDataItem(String name, E value) {\n\t\tdata.put(value, name);\n\t}",
"@Override\n public void setContainerData(String arg0)\n {\n \n }",
"public void setData (G pData){\n this._data=pData;\n }",
"void setDatty(Datty newDatty);",
"public void setData(Hashtable<String, Vector<Double>> data)\n {\n this.data = data;\n }",
"public void setDataCode(String dataCode);",
"public T setUserData(Object data)\n\t{\n\t\tuserData = data;\n\t\treturn (T) this;\n\t}",
"public void set(Object requestor, String field, JLabel comp);",
"public void set(String key, Object value)\n {\n if (value == null) remove(key);\n else if (value instanceof Map)\n {\n DataSection section = createSection(key);\n Map map = (Map) value;\n for (Object k : map.keySet())\n {\n section.set(k.toString(), map.get(k));\n }\n }\n else\n {\n data.put(key, value);\n if (!keys.contains(key)) keys.add(key);\n }\n }",
"public void setCustomData(final String customData) {\r\n\t\tthis.customData = customData;\r\n\t}",
"void setValue(String name,BudaBubble bbl)\n{\n if (name != null) value_map.put(name,bbl);\n}",
"public void put(String id, String name, WidgetDataType dataType, String viewName, Map<String, Object> model) {\n\t\tput(this.resourceDataFactory.createWidgetDataFromView(id, name, dataType, viewName, model));\n\t}",
"public void setData(Item i)\r\n\t{\r\n\t\ttheItem = i;\r\n\t}",
"public void addContextData( String key,\n String value );",
"private void setDataForTicket(){\n int rowId = ticketGui.getSelectedRowId();\n Ticket ticket = controller.getTicketById(rowId);\n\n // setting the data from the ticket i got to the popup gui\n clientNameTextField.setText(ticket.getClientName());\n starIdTextField.setText(ticket.getStarId());\n emailTextField.setText(ticket.getEmail());\n phoneNumberTextField.setText(ticket.getPhoneNumber());\n deviceModelTextField.setText(ticket.getModel());\n descriptionTextArea.setText(ticket.getDescription());\n clubMemberNameTextField.setText(ticket.getMemberName());\n resolutionTextArea.setText(ticket.getResolution());\n\n }",
"public abstract void setTooltipData(ITooltipData data);",
"public void setAttribute(Object key, Object value);",
"public BookingGui(DBMain data) throws RemoteException {\r\n try {\r\n this.data = data;\r\n this.data.addChangeListener(this);\r\n buildDisplay();\r\n addListeners();\r\n } catch (Exception ex) {\r\n throw new RemoteException(ex.getMessage());\r\n }\r\n }",
"@Override\n public void setWidget(Object arg0)\n {\n \n }",
"public void dataWasSet();",
"public <T> void set(String key, T value, Class<T> type) {\n this.data.put(key, value);\n }",
"public void setMetaData(HashMap pMetaData) ;",
"public void setValue(Object value)\r\n {\r\n if (value instanceof ColoredData)\r\n {\r\n ColoredData cvalue = (ColoredData) value;\r\n setText(cvalue.getData().toString());\r\n if (cvalue.getFGColor() != null)\r\n {\r\n setForeground(cvalue.getFGColor());\r\n }\r\n if (cvalue.getBGColor() != null)\r\n {\r\n setBackground(cvalue.getBGColor());\r\n }\r\n }\r\n else if (value instanceof IconData)\r\n {\r\n IconData ivalue = (IconData) value;\r\n setIcon(ivalue.getIcon());\r\n setText(ivalue.getData().toString());\r\n }\r\n else if (value instanceof DataTrendTick)\r\n {\r\n DataTrendTick dValue = (DataTrendTick) value;\r\n ImageIcon icon = new ImageIcon(dValue.getImage());\r\n setIcon(icon);\r\n setHorizontalAlignment(CENTER);\r\n }\r\n else\r\n {\r\n super.setValue(value);\r\n setHorizontalAlignment(CENTER);\r\n }\r\n }",
"public void set(String name, Object value) {\n }",
"public void setDataCustom(amdocs.iam.pd.webservices.offer.billdiscountofferlistoutputimpl.DataCustom dataCustom)\n {\n synchronized (monitor())\n {\n check_orphaned();\n amdocs.iam.pd.webservices.offer.billdiscountofferlistoutputimpl.DataCustom target = null;\n target = (amdocs.iam.pd.webservices.offer.billdiscountofferlistoutputimpl.DataCustom)get_store().find_element_user(DATACUSTOM$2, 0);\n if (target == null)\n {\n target = (amdocs.iam.pd.webservices.offer.billdiscountofferlistoutputimpl.DataCustom)get_store().add_element_user(DATACUSTOM$2);\n }\n target.set(dataCustom);\n }\n }",
"public JSONObject addOrUpdateCustomDevice(JSONObject data);",
"public final void setDataName(String dataName) {\n this.dataName = dataName;\n }",
"void put(String name, Object value);"
] | [
"0.6936164",
"0.68577605",
"0.66936177",
"0.6692754",
"0.6634808",
"0.6609217",
"0.657404",
"0.6560406",
"0.64984107",
"0.64730346",
"0.6412212",
"0.640339",
"0.6385308",
"0.63852775",
"0.6364686",
"0.6308922",
"0.63029647",
"0.62880075",
"0.6265707",
"0.6213451",
"0.62053883",
"0.6200042",
"0.61713254",
"0.6167977",
"0.6142929",
"0.6129466",
"0.6115082",
"0.61070305",
"0.60790443",
"0.6069544",
"0.6056603",
"0.60334945",
"0.6021932",
"0.60029924",
"0.5972971",
"0.5970459",
"0.5970125",
"0.59449226",
"0.59265566",
"0.59228206",
"0.5901351",
"0.58881074",
"0.58789843",
"0.58748245",
"0.58595914",
"0.5856926",
"0.585361",
"0.5851002",
"0.58395076",
"0.5820855",
"0.5775508",
"0.5765317",
"0.57650775",
"0.57609147",
"0.5742356",
"0.5737258",
"0.56837225",
"0.5681744",
"0.5678266",
"0.56737065",
"0.56737065",
"0.5646884",
"0.5631634",
"0.5626618",
"0.56081146",
"0.55896586",
"0.5558583",
"0.55507046",
"0.5547972",
"0.55453",
"0.5537509",
"0.5530424",
"0.5519215",
"0.55009294",
"0.5485549",
"0.5482506",
"0.5450699",
"0.5443694",
"0.5440012",
"0.54223406",
"0.54127043",
"0.5386427",
"0.5367528",
"0.53649765",
"0.534791",
"0.5338436",
"0.5331667",
"0.5327969",
"0.5315056",
"0.53122604",
"0.53059334",
"0.5293108",
"0.52806026",
"0.5267656",
"0.52542806",
"0.523534",
"0.52337635",
"0.5225746",
"0.5219918",
"0.52179587"
] | 0.734908 | 0 |
Returns the data object associated with this widget. | public abstract Object getCustomData(); | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public Object getDataObject() {\n return dataObject;\n }",
"public Object data() {\n return this.data;\n }",
"final public Object getDataObject() {\n return this.dataObject;\n }",
"public Object getData() {\n\t\treturn data;\n\t}",
"public Object getData(){\n\t\treturn this.data;\n\t}",
"public Object getData() {\r\n\t\t\treturn data;\r\n\t\t}",
"public Object getData()\r\n\t\t{\r\n\t\t\treturn data;\r\n\t\t}",
"Object getData() { /* package access */\n\t\treturn data;\n\t}",
"public Object getData() {\r\n if (data != null) {\r\n return data;\r\n }\r\n ValueBinding vb = getValueBinding(\"data\");\r\n if (vb != null) {\r\n return vb.getValue(getFacesContext());\r\n } else {\r\n \r\n if(!Beans.isDesignTime()){\r\n setChartTitle(getChartTitle() + \" with default data\");\r\n }\r\n return DEFAULT_DATA;\r\n }\r\n }",
"public synchronized Object getData() {\n return data;\n }",
"public Object getData() {\n\t\t\treturn null;// this.element;\n\t\t}",
"public Data getData() {\n return data;\n }",
"public Data getData() {\n return data;\n }",
"public DataItem getData() {\n return data;\n }",
"protected Object getViewData() {\n\t\treturn view.getViewData();\n\t}",
"@Override\r\n\t\tpublic Meta_data getData() {\n\t\t\treturn this.data;\r\n\t\t}",
"public T getData() {\n return this.data;\n }",
"public JavaScriptObject getData() {\n\t return getDataImpl(getUrl(), getRealHeight(), getRealWidth());\n }",
"public T getData()\n\t{\n\t\treturn this.data;\n\t}",
"public D getData() {\n return data;\n }",
"public D getData() {\n return data;\n }",
"public T getData() {\r\n return data;\r\n }",
"public Object getDataObject()\r\n {\r\n return stockData;\r\n }",
"public K data()\n {\n\treturn this.data;\n }",
"public D getData(){\n\t\treturn data;\n\t}",
"public Object getDataItem() {\n return this.dataItem;\n }",
"public DataBead getData() {\r\n\t\treturn dataBead;\r\n\t}",
"DataTypeInstance getDataInstance();",
"public GenericItemType getData() {\n return this.data;\n }",
"public Object getData();",
"public Object getData() \n {\n return data;\n }",
"T getObject() {\n\t\t\treturn data;\n\t\t}",
"public Descriptor getData() {\n return this;\n }",
"public T getData() {\n return mData;\n }",
"public T getData() {\r\n\t\t\treturn t;\r\n\t\t}",
"public IData getData() {\n return data;\n }",
"public T getViewDataBinding() {\n return mViewDataBinding;\n }",
"T getData() {\n\t\treturn data;\n\t}",
"public T getData()\n\t{ \treturn this.data; }",
"Object getData();",
"Object getData();",
"public T getData(){\n return this.data;\n }",
"public String data() {\n return this.data;\n }",
"public Object getElement()\n {return data;}",
"public Item getData()\r\n\t{\r\n\t\treturn theItem;\r\n\t}",
"public E getData(){\n\t\t\treturn data;\n\t\t}",
"public A getData()\n\t{\n\t\treturn data;\n\t}",
"public E getData() {\r\n\t\treturn data;\r\n\t}",
"@Override\r\n\tpublic E getData() {\n\t\treturn data;\r\n\t}",
"public Object getData() {\n if (this.mInvitation != null) return this.mInvitation;\n else if (this.mChatMessageFragment != null) return this.mChatMessageFragment;\n else return null;\n }",
"@Override\r\n\tprotected Object getData() {\n\t\treturn null;\r\n\t}",
"public String getData() {\r\n return this.data;\r\n }",
"public E getData() {\n return data;\n }",
"public PData getData() {\n\t\treturn data;\n\t}",
"@Override\n public final native String getData() /*-{\n return this.data;\n }-*/;",
"public LiveData<DataEntry> getData() {\n return data;\n }",
"public BubbleData getBubbleData() { return (BubbleData)this.mData; }",
"public DataModel getDataModel() {\r\n\t\treturn this.model;\r\n\t}",
"@Override\n public Object getUserData() {\n return this.userData;\n }",
"public String getData() {\n\t\treturn this.data;\n\t}",
"public Object getData() {\n return dataArray;\n }",
"public T value()\r\n {\r\n return data;\r\n }",
"public Object getUserData () {\n\t\treturn userData;\n\t}",
"public String getData() {\n return data;\n }",
"public String getData() {\n return data;\n }",
"public String getData() {\n return data;\n }",
"public String getData() {\n return data;\n }",
"public String getData() {\n\t\treturn getAttribute(DATA_TAG);\n\t}",
"public final HashMap<Integer, T> getData() {\n\t\treturn this.data;\n\t}",
"public Object getClientData() {\n return clientData;\n }",
"public Object getClientData() {\n return clientData;\n }",
"public Object getClientData() {\n return clientData;\n }",
"public Object getClientData() {\n return clientData;\n }",
"public abstract Object getData();",
"public Map<String, Object> getData() {\n\t\treturn this.data;\n\t}",
"public String getData()\n {\n return data;\n }",
"public E getData()\n {\n return data;\n }",
"public E getData()\n {\n return data;\n }",
"@java.lang.Override\n public godot.wire.Wire.Value getData() {\n return data_ == null ? godot.wire.Wire.Value.getDefaultInstance() : data_;\n }",
"public String getData() {\n\t\treturn data;\n\t}",
"public String getData() {\n\t\treturn data;\n\t}",
"public String getData() {\n\t\treturn data;\n\t}",
"public String getData() {\n\t\treturn data;\n\t}",
"public Object getClientData() {\r\n return clientData;\r\n }",
"public Object getClientData() {\r\n return clientData;\r\n }",
"public Object getClientData() {\r\n return clientData;\r\n }",
"public E getData() { return data; }",
"public Object getClientData() {\r\n\t\treturn clientData;\r\n\t}",
"public Object getClientData() {\n\t\treturn clientData;\n\t}",
"public Widget getWidget(){\r\n\t\treturn widget;\r\n\t}",
"public static IDataRenderer getDataRenderer() {\n\n return m_Renderer;\n\n }",
"public String getData() {\r\n\t\treturn data;\r\n\t}",
"public Object getUserData()\n\t{\n\t\treturn userData;\n\t}",
"public T getElement() {\n\t return myData;\n }",
"public String getData()\n\t{\n\t\treturn data;\n\t}",
"public Object getClientData() {\n return clientData;\n }",
"public Object getClientData() {\n return clientData;\n }",
"public Object getClientData() {\n return clientData;\n }",
"public Object getClientData() {\n return clientData;\n }",
"public Object getClientData() {\n return clientData;\n }"
] | [
"0.7214581",
"0.70846266",
"0.70750684",
"0.6778455",
"0.67428035",
"0.6721407",
"0.66972595",
"0.66471094",
"0.6603503",
"0.6570137",
"0.656576",
"0.6562449",
"0.6562449",
"0.6509468",
"0.6487802",
"0.6485705",
"0.64559984",
"0.6414565",
"0.63791525",
"0.637808",
"0.637808",
"0.6338393",
"0.6312967",
"0.63071704",
"0.6305924",
"0.62999636",
"0.6295361",
"0.62731653",
"0.62481666",
"0.62435776",
"0.6215679",
"0.62121475",
"0.6206763",
"0.6205285",
"0.62037873",
"0.6203413",
"0.6187777",
"0.6184895",
"0.61790216",
"0.6156881",
"0.6156881",
"0.6148702",
"0.6144487",
"0.6135353",
"0.61031705",
"0.60805166",
"0.6042719",
"0.6040335",
"0.6037451",
"0.60288095",
"0.60236007",
"0.6021156",
"0.6009242",
"0.60089433",
"0.5986626",
"0.59784913",
"0.5977091",
"0.59626055",
"0.59347475",
"0.59231997",
"0.5906018",
"0.59058917",
"0.5899281",
"0.58975154",
"0.58975154",
"0.58975154",
"0.58975154",
"0.589477",
"0.58893657",
"0.5889269",
"0.5889269",
"0.5889269",
"0.5889269",
"0.5875208",
"0.5867943",
"0.5867695",
"0.5863483",
"0.5863483",
"0.5862761",
"0.58550966",
"0.58550966",
"0.58550966",
"0.58550966",
"0.58524877",
"0.58524877",
"0.58524877",
"0.58502805",
"0.58478504",
"0.5846946",
"0.58463144",
"0.5841229",
"0.58394456",
"0.58330625",
"0.5820563",
"0.5800624",
"0.5796077",
"0.5796077",
"0.5796077",
"0.5796077",
"0.5796077"
] | 0.59009075 | 62 |
Return the number of unique email addresses in the provided list of EmailAddress objects. If initial list is empty or has only 1 entry, then no comparisons must be done. NOTE: Assumption is that all email addresses in the objects are valid/properly formatted email addresses. addressList List return: int number of unique email addresses | public static int countUniqueEmailAddresses(List<EmailAddress> addressList) {
if (addressList.size() <= 1) return addressList.size();
List<String> uniqueAddresses = addressList
.stream()
.map(address -> stripEmailAddress(address.getEmailAddress()))
.distinct()
.collect(Collectors.toList());
return uniqueAddresses.size();
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public int numUniqueEmails(String[] emails) {\n\t\tSet<String> s = new HashSet<>(); // Using a Set to take advantage it can't have dups.\n\t\t// nested loop approach. n emails, m characters each. O(n*m)\n\t\tfor (String email: emails) { // outer loop through n email\n\t\t\tchar[] emailChars = email.toCharArray();\n\t\t\tStringBuffer localName = new StringBuffer();\n\t\t\tString domainName = \"\";\n\t\t\tboolean parsingLocal = true;\n\t\t\t\n\t\t\tfor (int i = 0; i < emailChars.length; i++ ) { // inner loop m letters\n\t\t\t\tif ( emailChars[i] == '@') { // first time I see a @, switch to parsing domain\n\t\t\t\t\tdomainName = email.substring(i, email.length());\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t\tif (emailChars[i] == '.') // skip\n\t\t\t\t\tcontinue;\n\t\t\t\tif (emailChars[i] == '+')\n\t\t\t\t\tparsingLocal = false;\n\t\t\t\t\n\t\t\t\tif (parsingLocal)\n\t\t\t\t\tlocalName.append(emailChars[i]);\n\t\t\t\t\n\t\t\t}\n\t\t\ts.add(localName.toString()+domainName);\n\t\t}\n\t\t//System.out.println(s.toString());\n\t\treturn s.size();\n\n\t}",
"public int countUniqueIPs(){\n ArrayList<String> uniqueIps = new ArrayList<String>();\n for(LogEntry le : records){\n String iprAddr = le.getIpAddress();\n if(!uniqueIps.contains(iprAddr)){\n uniqueIps.add(iprAddr);\n } \n } \n return uniqueIps.size();\n }",
"@Override\n\tpublic int countByEmailAddress(String emailAddress)\n\t\tthrows SystemException {\n\t\tFinderPath finderPath = FINDER_PATH_COUNT_BY_EMAILADDRESS;\n\n\t\tObject[] finderArgs = new Object[] { emailAddress };\n\n\t\tLong count = (Long)FinderCacheUtil.getResult(finderPath, finderArgs,\n\t\t\t\tthis);\n\n\t\tif (count == null) {\n\t\t\tStringBundler query = new StringBundler(2);\n\n\t\t\tquery.append(_SQL_COUNT_CANDIDATE_WHERE);\n\n\t\t\tboolean bindEmailAddress = false;\n\n\t\t\tif (emailAddress == null) {\n\t\t\t\tquery.append(_FINDER_COLUMN_EMAILADDRESS_EMAILADDRESS_1);\n\t\t\t}\n\t\t\telse if (emailAddress.equals(StringPool.BLANK)) {\n\t\t\t\tquery.append(_FINDER_COLUMN_EMAILADDRESS_EMAILADDRESS_3);\n\t\t\t}\n\t\t\telse {\n\t\t\t\tbindEmailAddress = true;\n\n\t\t\t\tquery.append(_FINDER_COLUMN_EMAILADDRESS_EMAILADDRESS_2);\n\t\t\t}\n\n\t\t\tString sql = query.toString();\n\n\t\t\tSession session = null;\n\n\t\t\ttry {\n\t\t\t\tsession = openSession();\n\n\t\t\t\tQuery q = session.createQuery(sql);\n\n\t\t\t\tQueryPos qPos = QueryPos.getInstance(q);\n\n\t\t\t\tif (bindEmailAddress) {\n\t\t\t\t\tqPos.add(emailAddress);\n\t\t\t\t}\n\n\t\t\t\tcount = (Long)q.uniqueResult();\n\n\t\t\t\tFinderCacheUtil.putResult(finderPath, finderArgs, count);\n\t\t\t}\n\t\t\tcatch (Exception e) {\n\t\t\t\tFinderCacheUtil.removeResult(finderPath, finderArgs);\n\n\t\t\t\tthrow processException(e);\n\t\t\t}\n\t\t\tfinally {\n\t\t\t\tcloseSession(session);\n\t\t\t}\n\t\t}\n\n\t\treturn count.intValue();\n\t}",
"public void sizeOfList(List<Address> AddressList) {\n console.promptForString(\"\");\n int size = AddressList.size();\n console.promptForPrintPrompt(\" +++++++++++++++++++++++++++++++\");\n console.promptForPrintPrompt(\" + CURRENT NUMBER OF ENTRIES: +\");\n console.promptForPrintPrompt(\" \");\n console.promptForPrintInt(size);\n console.promptForPrintPrompt(\"\\n +++++++++++++++++++++++++++++++\");\n }",
"public static long getTotalNumberOfPerson(List<Person> personsList)\n\t{\n\t\treturn personsList.size();\t\n\t}",
"private void generateEmails(List<EmailAccount> emailAccounts, int count) {\n \t\t\n \t}",
"public Response getUniqueEmails(List<String> emails) {\n\t\tResponse response = new Response();\n\t\tboolean success=true;\n\t\ttry {\n\t\t\tSet<String> uniqueEmails = new HashSet<>();\n\t\t\tif(emails !=null) {\n\t\t\t\tfor(String email : emails) {\n\t\t\t\t\tint indexOfAt = email.indexOf(\"@\");\n\t\t\t\t\tif(indexOfAt==-1) {\n\t\t\t\t\t\t// not a valid email address\n\t\t\t\t\t\tresponse.setStatus(\"WARNING\");\n\t\t\t\t\t\tresponse.setMessage(\"One of the emails is not a valid email: \"+ email);\n\t\t\t\t\t\tresponse.setNumberOfUniqueEmailAddresses(-1);\n\t\t\t\t\t\tsuccess=false;\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t} else {\n\t\t\t\t\t\tString actualEmail = email.substring(0, indexOfAt);\n\t\t\t\t\t\tString domain = email.substring(indexOfAt);\n\t\t\t\t\t\tactualEmail = actualEmail.replace(\".\", \"\"); // removes all the dots from the email\n\t\t\t\t\t\tint indexPlus = actualEmail.indexOf(\"+\");\n\t\t\t\t\t\tif(indexPlus>=0) {\n\t\t\t\t\t\t\t// if there is a plus sign in the actual email address, only consider the string from 0 till + sign\n\t\t\t\t\t\t\tactualEmail=actualEmail.substring(0,indexPlus);\n\t\t\t\t\t\t}\n\t\t\t\t\t\tuniqueEmails.add(actualEmail+domain);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tif(success) {\n\t\t\t\t\tresponse.setStatus(\"SUCCESS\");\n\t\t\t\t\tresponse.setMessage(\"Successfully completed\");\n\t\t\t\t\tresponse.setNumberOfUniqueEmailAddresses(uniqueEmails.size());\n\t\t\t\t}\n\t\t\t}\n\t\t} catch (Exception e) {\n\t\t\tresponse.setStatus(\"ERROR\");\n\t\t\tresponse.setMessage(e.toString());\n\t\t}\n\t\treturn response;\n\t}",
"int getContactAddressCount();",
"public int getContactAddressCount() {\n return contactAddress_.size();\n }",
"public int getContactAddressCount() {\n if (contactAddressBuilder_ == null) {\n return contactAddress_.size();\n } else {\n return contactAddressBuilder_.getCount();\n }\n }",
"int countByExample(AddressesExample example);",
"long countByExample(EmailCriteria example);",
"public int size() {\n\t\treturn addresses.size();\n\t}",
"int getContactListCount();",
"int getContactListCount();",
"int getContactListCount();",
"int getContactListCount();",
"@Override\n\tpublic int hashCode() {\n\t\treturn getEmailAddress() == null ?\n\t\t\t\t0 : getEmailAddress().toLowerCase().hashCode();\n\t}",
"public static final int getCountNewUserByIP(final String address) {\n int count = 0;\n final PairVector<String, Long> DV = p().newusersByIP;\n synchronized (DV) {\n for (int i = DV.size() - 1; i >= 0; i--) {\n if (DV.elementAt(i).first.equalsIgnoreCase(address)) {\n if (System.currentTimeMillis() > (DV.elementAt(i).second.longValue()))\n DV.removeElementAt(i);\n else\n count++;\n }\n }\n }\n return count;\n }",
"private List<InternetAddress> getEmailAddresses(List<String> userList) {\n\t\tRepositorySecurityManager securityManager = RepositoryComponentFactory.getDefault().getSecurityManager();\n\t\tList<InternetAddress> emailAddresses = new ArrayList<>();\n\t\t\n\t\tfor (String userId : userList) {\n\t\t\ttry {\n\t\t\t\tUserPrincipal user = securityManager.getUser( userId );\n\t\t\t\t\n\t\t\t\tif ((user != null) && (user.getEmailAddress() != null) && (user.getEmailAddress().length() > 0)) {\n\t\t\t\t\tString fullName = user.getLastName();\n\t\t\t\t\t\n\t\t\t\t\tif (user.getFirstName() != null) {\n\t\t\t\t\t\tfullName = user.getFirstName() + \" \" + fullName;\n\t\t\t\t\t}\n\t\t\t\t\temailAddresses.add( new InternetAddress( user.getEmailAddress(), fullName ) );\n\t\t\t\t}\n\t\t\t\t\n\t\t\t} catch (UnsupportedEncodingException e) {\n\t\t\t\t// Should never happen; ignore and keep going\n\t\t\t}\n\t\t}\n\t\treturn emailAddresses;\n\t}",
"long countByExample(mailIdentifyExample example);",
"int getUniqueNumbersCount();",
"public int getContactListCount() {\n return contactList_.size();\n }",
"public int getContactListCount() {\n return contactList_.size();\n }",
"public int getContactListCount() {\n return contactList_.size();\n }",
"public int getContactListCount() {\n return contactList_.size();\n }",
"private int sizeOfList(Student [] list) {\r\n\t\t\r\n\t\tint size = 0;\r\n\t\tStudent sizechecker;\r\n\t\ttry {\r\n\t\t\t\r\n\t\t\twhile (true) {\r\n\t\t\t\t\r\n\t\t\t\tsizechecker = list[size];\r\n\t\t\t\tsize++;\r\n\t\t\t}\r\n\t\t}\r\n\t\tcatch(Exception e) { \r\n\t\t \r\n\t\t}\r\n\t\t\r\n\t\treturn size;\r\n\t}",
"public int returnAllAddressListCount(AddressCommonSC criteria) throws DAOException\r\n {\r\n DAOHelper.fixGridMaps(criteria, getSqlMap(), \"addressMapper.cifAddressDetailMap\");\r\n\r\n return ((Integer) getSqlMap().queryForObject(\"addressMapper.allAddressListCount\", criteria)).intValue();\r\n\r\n }",
"public int count() {\n\t\tint q = 0;\n\t\tfor(int i = 0; i < list.length; i++) if (list[i] != null) q++;\n\t\treturn q;\n\t\t\n\t}",
"@Override\n\tpublic int countByApproverEmails(String ApproverEmails)\n\t\tthrows SystemException {\n\t\tFinderPath finderPath = FINDER_PATH_COUNT_BY_APPROVEREMAILS;\n\n\t\tObject[] finderArgs = new Object[] { ApproverEmails };\n\n\t\tLong count = (Long)FinderCacheUtil.getResult(finderPath, finderArgs,\n\t\t\t\tthis);\n\n\t\tif (count == null) {\n\t\t\tStringBundler query = new StringBundler(2);\n\n\t\t\tquery.append(_SQL_COUNT_LMSLEAVEINFORMATION_WHERE);\n\n\t\t\tboolean bindApproverEmails = false;\n\n\t\t\tif (ApproverEmails == null) {\n\t\t\t\tquery.append(_FINDER_COLUMN_APPROVEREMAILS_APPROVEREMAILS_1);\n\t\t\t}\n\t\t\telse if (ApproverEmails.equals(StringPool.BLANK)) {\n\t\t\t\tquery.append(_FINDER_COLUMN_APPROVEREMAILS_APPROVEREMAILS_3);\n\t\t\t}\n\t\t\telse {\n\t\t\t\tbindApproverEmails = true;\n\n\t\t\t\tquery.append(_FINDER_COLUMN_APPROVEREMAILS_APPROVEREMAILS_2);\n\t\t\t}\n\n\t\t\tString sql = query.toString();\n\n\t\t\tSession session = null;\n\n\t\t\ttry {\n\t\t\t\tsession = openSession();\n\n\t\t\t\tQuery q = session.createQuery(sql);\n\n\t\t\t\tQueryPos qPos = QueryPos.getInstance(q);\n\n\t\t\t\tif (bindApproverEmails) {\n\t\t\t\t\tqPos.add(ApproverEmails);\n\t\t\t\t}\n\n\t\t\t\tcount = (Long)q.uniqueResult();\n\n\t\t\t\tFinderCacheUtil.putResult(finderPath, finderArgs, count);\n\t\t\t}\n\t\t\tcatch (Exception e) {\n\t\t\t\tFinderCacheUtil.removeResult(finderPath, finderArgs);\n\n\t\t\t\tthrow processException(e);\n\t\t\t}\n\t\t\tfinally {\n\t\t\t\tcloseSession(session);\n\t\t\t}\n\t\t}\n\n\t\treturn count.intValue();\n\t}",
"public static long getNumberOfAuthorsByGender(List<Book> inputList, Enum<Sex> gender) {\n\t\tSet<Author> set = (Set<Author>)inputList.stream().map(Book::getAuthor).collect(Collectors.toCollection(HashSet::new));\n\t\treturn set.stream().filter(a -> a.getGender() == gender).count();\n\t}",
"public int getContactListCount() {\n if (contactListBuilder_ == null) {\n return contactList_.size();\n } else {\n return contactListBuilder_.getCount();\n }\n }",
"public int getContactListCount() {\n if (contactListBuilder_ == null) {\n return contactList_.size();\n } else {\n return contactListBuilder_.getCount();\n }\n }",
"public int getContactListCount() {\n if (contactListBuilder_ == null) {\n return contactList_.size();\n } else {\n return contactListBuilder_.getCount();\n }\n }",
"public int getContactListCount() {\n if (contactListBuilder_ == null) {\n return contactList_.size();\n } else {\n return contactListBuilder_.getCount();\n }\n }",
"long countUserByEmail(String email);",
"public void setEmailAddresses(String emailAddr)\n {\n this.emailAddresses = StringTools.trim(emailAddr);\n }",
"public int getURLCount(int list) {\n/* 93 */ int result = 0;\n/* 94 */ List urls = (List)this.urlSeries.get(list);\n/* 95 */ if (urls != null) {\n/* 96 */ result = urls.size();\n/* */ }\n/* 98 */ return result;\n/* */ }",
"private int getMaxNumberOfEvents(ArrayList<ArrayList<String>> list) {\n int maxNumberOfEvents = 0;\n for (ArrayList<String> events : list) {\n if (events.size() > maxNumberOfEvents) {\n maxNumberOfEvents = events.size();\n }\n }\n return maxNumberOfEvents;\n }",
"int sizeOfAddressHistoryArray();",
"@Override\n\tpublic int hashCode() {\n\t\tfinal int prime = 31;\n\t\tint result = 1;\n\t\tresult = prime * result + ((email == null) ? 0 : email.hashCode());\n\t\treturn result;\n\t}",
"public int size() {\n\t\tint numElements = 0;\n\t\tfor (int i = 0; i < this.size; i++) {\n\t\t\tif (list[i] != null) {\n\t\t\t\tnumElements++;\n\t\t\t}\n\t\t}\n\t\treturn numElements;\n\t}",
"public Integer getEmailSize() {\r\n\t\treturn email.size();\t\t\r\n\t}",
"public int count () {\n return member_id_list.length;\r\n }",
"public void testMultipleEmailAddresses() {\n rootBlog.setProperty(SimpleBlog.EMAIL_KEY, \"[email protected],[email protected]\");\n assertEquals(\"[email protected],[email protected]\", rootBlog.getEmail());\n assertEquals(2, rootBlog.getEmailAddresses().size());\n Iterator it = rootBlog.getEmailAddresses().iterator();\n assertEquals(\"[email protected]\", it.next());\n assertEquals(\"[email protected]\", it.next());\n }",
"int getListCount();",
"public void setAddressList(List addressList) {\r\n this.addressList = addressList;\r\n }",
"public int count () throws IOException {\n\t\tList<Integer> list = new ArrayList<Integer>();\n\t\tinit();\n\t\twhile(hasNext()) {\n\t\t\tElement el = nextElement();\n\t\t\tint hash = el.GetHash();\n\t\t\tint pos = locate (list, hash);\n\t\t\tif ((pos == list.size()) || (list.get(pos) != hash)) {\n\t\t\t\tlist.add(pos, hash);\n\t\t\t}\n\t\t\t/*for (i=0; i<list.size() && list.get(i)<hash; i++) {}\n\t\t\t\tif ((i==list.size()) || (list.get(i) != el.GetHash())) {\n\t\t\t\t\tlist.add(i, hash);\n\t\t\t\t}*/\n\t\t}\n\t\treturn list.size();\n\t}",
"@Override\r\n\tpublic boolean overlapCheck(String email) {\n\t\treturn select(\"email\", email).size()==0;\r\n\t}",
"public static <T> int m28125a(@C6003d List<? extends T> list) {\n C14445h0.m62478f(list, \"$receiver\");\n return list.size() - 1;\n }",
"int getListSize(int list) {\n\t\treturn m_lists.getField(list, 4);\n\t}",
"int getCouponListCount();",
"private List<Contact> getDuplicatesByEmail(List<Contact> contacts) {\n List<Object> duplicates = getDuplicatesByKey(Contact::getEmail, contacts);\n\n // Only return Contact records that match the duplicated email addresses\n return contacts.stream()\n .filter(contact -> duplicates.contains(contact.getEmail()))\n .collect(Collectors.toList());\n }",
"public static int countDuplicates(List<Integer> numbers) {\n // Write your code here\n Map<Integer, Integer> mapCount = new HashMap<>();\n Set<Integer> duplicates = new HashSet<>();\n for (Integer i : numbers) {\n Integer count = mapCount.get(i);\n if (count == null) {\n count = 1;\n } else if (count != null) {\n count++;\n duplicates.add(i);\n }\n mapCount.put(i, count);\n }\n return duplicates.size();\n }",
"public int duplicateEmail(String email) {\n\t\treturn sqlSessionTemplate.selectOne(\"memberInfo.checkEmail\", email);\r\n\t}",
"boolean hasAddressList();",
"private static int carCount(List<UsedCar> carList) {\n int i = 0;\n for (Car count : carList) {\n i++;\n }\n return i; // returns i+1 to accommodate for list starting at zero\n }",
"public int getSize(){\n\t\t\n\t\tint counter = 0;\t\t\t\t\t\t\t\t\t\t\t/* ====> Size counter */\n\t\t\n\t\tUser marker = new User();\t\t\t\t\t\t\t\t\t/* ====> Create a marker */\n\t\tmarker = this.getHead();\t\t\t\t\t\t\t\t\t/* ====> Set the marker at the beginning of the list */\n\t\t\n\t\twhile(marker.getNext()!= null){\t\t\t\t\t\t\t\t/* ====> Move marker to next element until it reaches the end. */ \n\t\t\tmarker = marker.getNext();\n\t\t\tcounter++;\t\t\t\t\t\t\t\t\t\t\t\t/* ====> Increment counter everytime the loop goes through */\n\t\t}\n\t\t\t\t\t\t\t\t\t\n\t\treturn counter;\t\t\t\t\t\t\t\t\t\t\t\t/* ====> Return number of Users in UserList */\n\t\t\n\t}",
"int getFriendListCount();",
"int getFriendListCount();",
"int getExchangeHistoryListCount();",
"@Override\n\tpublic int countAll() throws SystemException {\n\t\tLong count = (Long)FinderCacheUtil.getResult(FINDER_PATH_COUNT_ALL,\n\t\t\t\tFINDER_ARGS_EMPTY, this);\n\n\t\tif (count == null) {\n\t\t\tSession session = null;\n\n\t\t\ttry {\n\t\t\t\tsession = openSession();\n\n\t\t\t\tQuery q = session.createQuery(_SQL_COUNT_ADDRESSCHANGEREQDETAILS);\n\n\t\t\t\tcount = (Long)q.uniqueResult();\n\n\t\t\t\tFinderCacheUtil.putResult(FINDER_PATH_COUNT_ALL,\n\t\t\t\t\tFINDER_ARGS_EMPTY, count);\n\t\t\t}\n\t\t\tcatch (Exception e) {\n\t\t\t\tFinderCacheUtil.removeResult(FINDER_PATH_COUNT_ALL,\n\t\t\t\t\tFINDER_ARGS_EMPTY);\n\n\t\t\t\tthrow processException(e);\n\t\t\t}\n\t\t\tfinally {\n\t\t\t\tcloseSession(session);\n\t\t\t}\n\t\t}\n\n\t\treturn count.intValue();\n\t}",
"public int getRecipientsLength()\n {\n COSArray array = (COSArray)encryptionDictionary.getItem(COSName.getPDFName(\"Recipients\"));\n return array.size();\n }",
"public List<com.wuda.foundation.jooq.code.generation.user.tables.pojos.UserEmail> fetchRangeOfEmailId(ULong lowerInclusive, ULong upperInclusive) {\n return fetchRange(UserEmail.USER_EMAIL.EMAIL_ID, lowerInclusive, upperInclusive);\n }",
"@Override\n\tpublic long size() {\n\t\treturn contacts.size();\n\t}",
"@Override\n public int getRowCount() {\n return emails.size();\n }",
"private Set<String> getEmailAccounts() {\n HashSet<String> emailAccounts = new HashSet<>();\n AccountManager manager = (AccountManager) getContext().getSystemService(Context.ACCOUNT_SERVICE);\n final Account[] accounts = manager.getAccounts();\n for (Account account : accounts) {\n if (!TextUtils.isEmpty(account.name) && Patterns.EMAIL_ADDRESS.matcher(account.name).matches()) {\n emailAccounts.add(account.name);\n }\n }\n return emailAccounts;\n }",
"static public int numberOfPersons() {\n return personMap.size();\n }",
"public synchronized int size(){\n return list.size();\n }",
"io.envoyproxy.envoy.data.dns.v3.DnsTable.AddressListOrBuilder getAddressListOrBuilder();",
"private static List<String> getEmailList(){\n List<String> lista = new ArrayList<>();\n lista.add(\"[email protected]\");\n lista.add(\"[email protected].\");\n lista.add(\"[email protected]\");\n lista.add(\"[email protected].\");\n lista.add(\"meu#[email protected]\");\n lista.add(\"[email protected]\");\n lista.add(\"[email protected]\");\n lista.add(\"[email protected]\");\n lista.add(\"[[email protected]\");\n lista.add(\"<[email protected]\");\n lista.add(\"[email protected]\");\n lista.add(\"[email protected]\");\n lista.add(\"[email protected]\");\n\n lista.add(\"[email protected]\");\n lista.add(\"[email protected]\");\n\n\n return lista;\n\n }",
"public ArrayList<String> getUsersPollIDs(String email){\n \tfor (User user : list){\n \t\tif (user.getEmail().equals(email))\n \t\t\treturn user.getPollIDs();\n \t}\n \treturn null;\n }",
"public static List<Long> getIdentifiers(List<? extends AbstractBusinessObject> list) {\n if (list == null) {\n return null;\n }\n List<Long> ids = new ArrayList<Long>();\n\n for (AbstractBusinessObject abo : list) {\n ids.add(abo.getId());\n }\n return ids;\n }",
"int getMailCount() {\n\t\treturn mail_count[mailbox_number];\n\t}",
"private static Map<String, Integer> getMaxFieldCounts(List<ContentObjectMetadata> comList) {\n Map<String, Integer> maxFieldCounts = new HashMap<String, Integer>();\n for (ContentObjectMetadata com : comList) {\n for (String fieldName : com.getMetadataProperties().keySet()) {\n if (!fieldName.startsWith(\"_\")) {\n if (maxFieldCounts.containsKey(fieldName)) {\n if (maxFieldCounts.get(fieldName) < com.getMetadataProperties().get(fieldName).size()) {\n maxFieldCounts.put(fieldName, com.getMetadataProperties().get(fieldName).size());\n }\n } else {\n maxFieldCounts.put(fieldName, com.getMetadataProperties().get(fieldName).size());\n }\n }\n }\n }\n return maxFieldCounts;\n }",
"@Override\n @SuppressWarnings(\"unchecked\")\n public boolean checkExistsEmail(String emailAddress) throws DAOException{\n \n try{\n Session session = HibernateConnectionUtil.getSession();\n \n Criteria crit = session.createCriteria(UserProfile.class);\n crit.add(Restrictions.eq(\"emailAddress\", emailAddress));\n List<UserProfile> userList = crit.list();\n session.close();\n return !userList.isEmpty();\n }\n catch(HibernateException e){\n throw new DAOException(\"HibernateException: \" + e.getMessage());\n }\n }",
"public int size()\n {\n return list.size();\n }",
"public int hashCode(){\n \tint n = 0;\n \tfor(Iterator it = iterator(); it.hasNext();){\n \t\tObject object = it.next();\n \t\tif(object != null){\n \t\t\tn += object.hashCode();\n \t\t}\n \t}\n \treturn n;\n }",
"int getServiceAccountsCount();",
"int sumOfYearsOfUniqueUsers(List<User> users);",
"public static long getTotalNumberOfPerson(List<Person> personsList , String planet)\n\t{\n\t\t\treturn personsList.stream().filter(x ->x.getPlanetOfResidence().equalsIgnoreCase(planet)).count();\n\t}",
"public int size()\n\t{\n\t\treturn list.size();\n\t}",
"public int size()\n\t{\n\t\treturn list.size();\n\t}",
"@Override\n\tpublic String hash(EmailAddress address)\n\t{\n\t\treturn null;\n\t}",
"public int size() {\n return list.size();\n }",
"int getNumberOfDetectedDuplicates();",
"private int countOccurrence(Integer valueToCount) {\n int count = 0;\n\n for(Integer currentValue : list) {\n if (currentValue == valueToCount) {\n count++;\n }\n }\n\n return count;\n }",
"public int size(){\n\t\treturn list.size();\n\t}",
"public int size(){\n\t\treturn list.size();\n\t}",
"public int getNumRecipients() {\n return recipients.size();\n }",
"public int f1(List<Book> a) {\r\n int count = 0;\r\n for (Book o : a) {\r\n int demchu = 0;\r\n int demso = 0;\r\n for (int i = 0; i < o.getCode().length(); i++) {\r\n char c = o.getCode().charAt(i);\r\n if (Character.isDigit(c)) {\r\n demso++;\r\n }\r\n if (Character.isLetter(c)) {\r\n demchu++;\r\n }\r\n }\r\n if (demchu != 0 && demso != 0) {\r\n count++;\r\n }\r\n }\r\n return count;\r\n\r\n }",
"private static String getSuccessfulAddresses(\n final List<Pair<RelocatedAddress, Integer>> addresses) {\n return getAddressString(addresses, new ICollectionFilter<Pair<RelocatedAddress, Integer>>() {\n @Override\n public boolean qualifies(final Pair<RelocatedAddress, Integer> item) {\n return item.second() == 0;\n }\n });\n }",
"public int size() { return _byHashCode.size(); }",
"long count(Collection<? extends Object> values);",
"public void setAddresses(List<String> addresses) {\n this.addresses = addresses;\n }",
"public int getInviteeIdsCount() {\n return inviteeIds_.size();\n }",
"int getPeerURLsCount();",
"public static long getCountOfUniqueActivitiesOfSchool(){\r\n\t\treturn StudentRepository.getStudents()\r\n\t\t\t.stream() // Stream<Student>\r\n\t\t\t.map(Student :: getActivities) // Stream<List<String>>\r\n\t\t\t// want to pass a List and get back a stream of that list\r\n\t\t\t.flatMap(List :: stream) // Stream<String>\r\n\t\t\t.distinct()\r\n\t\t\t.count();\r\n\t}",
"int getCountOfFemaleUsers(List<User> users);",
"@Override\n public int size() {\n int totalSize = 0;\n // iterating over collectionList\n for (Collection<E> coll : collectionList)\n totalSize += coll.size();\n return totalSize;\n }"
] | [
"0.6945899",
"0.62087005",
"0.6057485",
"0.5982568",
"0.5884604",
"0.5868197",
"0.57841086",
"0.57138574",
"0.56011057",
"0.5507783",
"0.54598665",
"0.5427029",
"0.53992295",
"0.53431726",
"0.53431726",
"0.53431726",
"0.53431726",
"0.52177393",
"0.5159637",
"0.51518446",
"0.5146333",
"0.5143752",
"0.5111265",
"0.5111265",
"0.5111265",
"0.5111265",
"0.50938445",
"0.5083061",
"0.50776875",
"0.50388926",
"0.5025914",
"0.5022473",
"0.5022473",
"0.5022473",
"0.5022473",
"0.50024074",
"0.4986183",
"0.4973119",
"0.49570358",
"0.49413976",
"0.49187687",
"0.48594373",
"0.48163274",
"0.4778762",
"0.4772182",
"0.4762921",
"0.4748827",
"0.4741178",
"0.4740102",
"0.47084087",
"0.4708381",
"0.46912447",
"0.4690938",
"0.46810412",
"0.46797293",
"0.46760163",
"0.46739936",
"0.46729445",
"0.46728173",
"0.46728173",
"0.46711233",
"0.4670733",
"0.46670017",
"0.46652862",
"0.46462512",
"0.46459168",
"0.46452928",
"0.46373495",
"0.46346214",
"0.46320608",
"0.46262833",
"0.46259227",
"0.45892993",
"0.4586995",
"0.45860246",
"0.45827964",
"0.4578782",
"0.45780334",
"0.45762014",
"0.45751026",
"0.4573157",
"0.45679903",
"0.45679903",
"0.45647517",
"0.45629123",
"0.45618972",
"0.4560188",
"0.4557797",
"0.4557797",
"0.4553484",
"0.45492402",
"0.45412195",
"0.45399964",
"0.45396966",
"0.4538912",
"0.45355493",
"0.45251033",
"0.45250455",
"0.4521103",
"0.45134658"
] | 0.8908934 | 0 |
Separates the email address into two pieces: address and domain. Once address is separated from domain, it is cleaned up, returning a simplified email address which will be used for comparison. NOTE: Assumes all email addresses are properly formatted. emailAddress String returns: String clean, simplified email address | static String stripEmailAddress(String emailAddress) {
int atCharIndex = emailAddress.indexOf("@");
String addressName = emailAddress.substring(0, atCharIndex);
String addressDomain = emailAddress.substring(atCharIndex);
return cleanAddressName(addressName) + addressDomain.toLowerCase();
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"static String cleanAddressName(String emailAddress) {\n int plusCharIndex = emailAddress.indexOf(\"+\");\n\n if (plusCharIndex != -1)\n emailAddress = emailAddress.substring(0, plusCharIndex);\n\n return emailAddress.replaceAll(\"\\\\.\", \"\").toLowerCase();\n }",
"private String cleanEmailAddress(String email) {\n return email.replace(\".\", \"-\");\n }",
"public ParsedEmailAddress parseEmailAddress(String emailAddress) throws InvalidEmailAddressException;",
"public void setEmailAddress(String emailAddress) {\r\n this.emailAddress = doTrim(emailAddress);\r\n }",
"void formatEmail(String email) throws EmailAddressFormatException;",
"public static void main(String[] args) {\n Scanner scan = new Scanner(System.in);\n\n System.out.println(\"Enter valid email address\");\n\n String email = scan.nextLine();\n\n int lastIndexOfPart1 = email.lastIndexOf(\"@\");\n System.out.println(lastIndexOfPart1);\n System.out.println(email.substring(0,lastIndexOfPart1 ));\n\n int indexOfPart2 = email.indexOf(\"@\") + 1;\n int lastIndexOfPart2 = email.lastIndexOf(\".\");\n\n\n\n System.out.println(email.substring(indexOfPart2,lastIndexOfPart2 ));\n\n int indexOfPart3 = email.indexOf(\".\") + 1;\n System.out.println(email.substring(indexOfPart3) );\n\n email = email.substring(0,lastIndexOfPart1) +\"@\"+email.substring(indexOfPart2,lastIndexOfPart2 )+\".\"+email.substring(indexOfPart3);\n System.out.println(email);\n\n\n\n\n\n\n\n\n\n }",
"private String extractEMailAddress() {\n return SwingUtil.extract(emailJTextField, Boolean.TRUE);\n }",
"public static final Email stringToEmail(String emailString)\n throws EmailFormatException {\n Pattern p = Pattern.compile(\".+@.+\\\\.[a-z]+\");\n\n // Match the given string with the pattern\n Matcher m = p.matcher(emailString);\n\n // check whether match is found\n boolean matchFound = m.matches();\n\n if (matchFound) {\n return new Email(emailString);\n } else {\n if ((emailString != \"\") && (emailString != null)) {\n throw new EmailFormatException();\n } else {\n return new Email(emailString);\n }\n }\n }",
"public java.lang.String getEmailAddress();",
"public static String normalize(String email) {\n\t\treturn email.toLowerCase();\n\t}",
"public void setEmailAddresses(String emailAddr)\n {\n this.emailAddresses = StringTools.trim(emailAddr);\n }",
"boolean validateMailAddress(final String mailAddress);",
"public void setEmailAddress(String emailAddress) {\r\n\t\tthis.emailAddress = emailAddress;\r\n\t}",
"public AddressEntry setEmailAddress(String emailAddress){\r\n\t\tthis.emailAddress=emailAddress;\r\n\t\treturn this;\r\n\t}",
"public static String makeNickName(String emailAddress) {\r\n\r\n // this is to help while debugging (to avoid the \"null pointer exception\"\r\n if (emailAddress == null) {\r\n return \"Can't make nickname from null email Address.\";\r\n }\r\n\r\n int nickNameLength = emailAddress.length();\r\n\r\n // create nickname as email address without the \"@...\"\r\n int atPosition = emailAddress.indexOf(\"@\"); // value is -1 if not found\r\n if (atPosition > 0) {\r\n nickNameLength = atPosition;\r\n }\r\n\r\n // create nickname as what's before a period \r\n int periodPosition = emailAddress.indexOf(\".\");\r\n if ((periodPosition > 0) && (periodPosition < nickNameLength)) {\r\n nickNameLength = periodPosition;\r\n }\r\n\r\n // return the first part of the emailAddress (up to right before the \".\" and/or the \"@\"\r\n return (emailAddress.substring(0, nickNameLength));\r\n\r\n }",
"public static String obfuscateEmail(String email) {\n\t\tif (isEmpty(email)) return email;\n\n\t\tStringBuilder sb = new StringBuilder(email.length());\n\t\tfor (int x=0; x < email.length(); x++ ) {\n\t\t\tsb.append(x > 0 && x < email.indexOf('@') ? '*' : email.charAt(x));\n\t\t}\n\t\treturn sb.toString();\n\t}",
"public void setEmailAddress(java.lang.String EmailAddress) {\n this.EmailAddress = EmailAddress;\n }",
"public String getEmailAddress() {\n return EmailAddress.commaSeperateList(this.emailAddressList);\n }",
"private static boolean lastEmailFieldTwoCharsOrMore(String emailAddress) {\r\n\t\tif (emailAddress == null)\r\n\t\t\treturn false;\r\n\t\tStringTokenizer st = new StringTokenizer(emailAddress, \".\");\r\n\t\tString lastToken = null;\r\n\t\twhile (st.hasMoreTokens()) {\r\n\t\t\tlastToken = st.nextToken();\r\n\t\t}\r\n\t\tif (lastToken.length() >= 2) {\r\n\t\t\treturn true;\r\n\t\t} else {\r\n\t\t\treturn false;\r\n\t\t}\r\n\t}",
"public void setEmailAddress(String emailAddress) {\n this.emailAddress = emailAddress;\n }",
"public void setEmailAddress(String emailAddress) {\n this.emailAddress = emailAddress;\n }",
"public void setEmailAddress(String emailAddress) {\n this.emailAddress = emailAddress;\n }",
"public void setEmailAddress(String emailAddress) {\n this.emailAddress = emailAddress;\n }",
"public void setEmailAddress(String emailAddress) {\n this.emailAddress = emailAddress;\n }",
"public java.lang.String getEmailAddress()\r\n\t{\r\n\t\tString result = \"\";\r\n\t\tint length = emailAddress.length();\r\n\t\t\r\n\t\tif (!locked)\r\n\t\t\tresult = emailAddress;\r\n\t\telse\r\n\t\t{\r\n\t\t\tfor(int i = 1; i < length; i++)\r\n\t\t\t{\r\n\t\t\t\t//char asterisk = emailAddress.charAt(i);\r\n\t\t\t\t\r\n\t\t\t\t\r\n\t\t\t\t\r\n\t\t\t}\r\n\t\t\t\r\n\t\t}\r\n\t\treturn result;\r\n\t\t\t\r\n\t}",
"public void setEmailAddress(java.lang.CharSequence value) {\n this.email_address = value;\n }",
"public static String validateMailInput(Context context, TextInputEditText editText) {\n // store input\n String rawMail = editText.getText().toString().trim();\n\n if (TextUtils.isEmpty(rawMail)) {\n editText.setError(context.getResources().getString(R.string.editor_edt_empty_input));\n return null;\n }\n\n if (!android.util.Patterns.EMAIL_ADDRESS.matcher(rawMail).matches()) {\n editText.setError(context.getResources().getString(R.string.editor_edt_invalid_input));\n return null;\n }\n\n return rawMail;\n }",
"public static Address newAddress(final String emailAddress, final String personal)\r\n\t\tthrows AddressException, UnsupportedEncodingException\r\n\t{\r\n\t\treturn newAddress(emailAddress, personal, null);\r\n\t}",
"private String parseName(String email) {\n String[] parsedEmail = email.split(\"@\");\n if (parsedEmail.length > 0) {\n return parsedEmail[0];\n } else {\n return null;\n }\n }",
"public EmailCheckResult check(String emailValue) {\n int atSignPosition = emailValue.indexOf('@');\n if (atSignPosition == -1) return EmailCheckResult.NOT_EMAIL;\n\n\n String domainValue = emailValue.substring(++atSignPosition);\n ArrayList<String> mxList;\n\n // check if the value has domain\n try {\n mxList = getMX(domainValue);\n } catch (NamingException ex) {\n return EmailCheckResult.NO_DOMAIN;\n }\n if (mxList.size() == 0) return EmailCheckResult.NO_DOMAIN;\n else return checkMxHosts(emailValue, mxList);\n }",
"public void setEmailAddressesString(String emailAddressesString1) {\r\n this.emailAddressesString = emailAddressesString1;\r\n }",
"public com.politrons.avro.AvroPerson.Builder setEmailAddress(java.lang.CharSequence value) {\n validate(fields()[2], value);\n this.email_address = value;\n fieldSetFlags()[2] = true;\n return this; \n }",
"public void setEmailAddress(String email_address){\n this.email_address = email_address;\n }",
"@Override\r\n\tpublic void formatEmail(String email) throws EmailAddressFormatException {\r\n\t\tboolean print = true;\r\n\t\tfor (int i = 0; i < email.length(); i++) {\r\n\t\t\tif (email.charAt(i) != '@' || Character.isUpperCase(email.charAt(i))) {\r\n\t\t\t\tprint = false;\r\n\t\t\t\tthrow new EmailAddressFormatException(email);\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tif (print == true) {\r\n\t\t\tSystem.out.println(email);\r\n\t\t}\r\n\r\n\t}",
"public static boolean isEMailAddress(String emailAddress) {\n if (emailAddress == null) {\n return false;\n }\n\n String regex = \"^[\\\\w-_\\\\.+]*[\\\\w-_\\\\.]\\\\@([\\\\w]+\\\\.)+[\\\\w]+[\\\\w]$\";\n if (emailAddress.matches(regex))\n return true;\n\n // We allow variable for email address\n return TaskerPlugin.variableNameValid(emailAddress);\n }",
"@AutoEscape\n\tpublic String getEmail_address();",
"public static void main(String[] args) {\n\n String email=\"[email protected]\";\n\n String firstName=email.substring(0,email.indexOf('_')) ;\n String lastName=email.substring(email.indexOf('_')+1,email.indexOf('@'));\n\n String domain=email.substring(email.indexOf('@')+1,email.indexOf('.'));\n String topLevelDomain = email.substring(email.indexOf('.')+1);\n\n\n\n String ch=\"\"+firstName.charAt(0);\n ch=ch.toUpperCase();\n\n firstName=firstName.replaceFirst(firstName.charAt(0)+\"\", \"\");\n System.out.println(\"First name: \"+ch+firstName );\n\n\n String ch1=\"\"+lastName.charAt(0);\n ch1=ch1.toUpperCase();\n\n lastName=lastName.replaceFirst(lastName.charAt(0)+\"\", \"\");\n System.out.println(\"Last name: \"+ch1+lastName);\n\n\n\n System.out.println(\"Domain: \"+domain );\n System.out.println(\"Top-Level Domain: \"+topLevelDomain);\n\n\n\n\n\n\n\n\n }",
"private void usernameFromEmail(String email) {\n if (email.matches(\"(?:[a-z0-9!#$%&'*+/=?^_`{|}~-]+(?:\\\\.[a-z0-9!#$%&'*+/=?^_`{|}~-]+)*|\\\"(?:[\\\\x01-\\\\x08\\\\x0b\\\\x0c\\\\x0e-\\\\x1f\\\\x21\\\\x23-\\\\x5b\\\\x5d-\\\\x7f]|\\\\\\\\[\\\\x01-\\\\x09\\\\x0b\\\\x0c\\\\x0e-\\\\x7f])*\\\")@(?:(?:[a-z0-9](?:[a-z0-9-]*[a-z0-9])?\\\\.)+[a-z0-9](?:[a-z0-9-]*[a-z0-9])?|\\\\[(?:(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\\\\.){3}(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?|[a-z0-9-]*[a-z0-9]:(?:[\\\\x01-\\\\x08\\\\x0b\\\\x0c\\\\x0e-\\\\x1f\\\\x21-\\\\x5a\\\\x53-\\\\x7f]|\\\\\\\\[\\\\x01-\\\\x09\\\\x0b\\\\x0c\\\\x0e-\\\\x7f])+)\\\\])\")) {\n goNextEnable();\n } else {\n goNextDisable();\n }\n }",
"@Test\n public void testBATVBad() {\n SplitEmailAddress email = SplitEmailAddress.parse(\"[email protected]\");\n assertEquals(\"prvs=aaaaaaaaaa=me\", email.getLocal());\n assertEquals(\"example.com\", email.getDomain());\n }",
"@AutoEscape\n\tpublic String getFromEmailAddress();",
"public static String stripDomain(String user) {\n if (user.lastIndexOf(\"\\\\\") > -1) {\n user = user.substring(user.lastIndexOf(\"\\\\\")+1); \n }\n if (user.indexOf('@') > -1) {\n user = user.substring(0,user.indexOf('@')); \n }\n return user;\n }",
"protected void validateEmail(){\n\n //Creating Boolean Value And checking More Accurate Email Validator Added\n\n Boolean email = Pattern.matches(\"^[A-Za-z]+([.+-]?[a-z A-z0-9]+)?@[a-zA-z0-9]{1,6}\\\\.[a-zA-Z]{2,6},?([.][a-zA-z+,]{2,6})?$\",getEmail());\n System.out.println(emailResult(email));\n }",
"java.lang.String getEmail();",
"java.lang.String getEmail();",
"java.lang.String getEmail();",
"java.lang.String getEmail();",
"java.lang.String getEmail();",
"java.lang.String getEmail();",
"public java.lang.CharSequence getEmailAddress() {\n return email_address;\n }",
"public boolean isValidEmailAddress(String emailAddress) {\n\t\tString expression = \"^[\\\\w\\\\-]([\\\\.\\\\w])+[\\\\w]+@([\\\\w\\\\-]+\\\\.)+[A-Z]{2,4}$\";\n\t\tCharSequence inputStr = emailAddress;\n\t\tPattern pattern = Pattern.compile(expression, Pattern.CASE_INSENSITIVE);\n\t\tMatcher matcher = pattern.matcher(inputStr);\n\t\treturn matcher.matches();\n\t}",
"public void setEmailAddress(String email) {\n this.email = email;\n }",
"public String getEmailAddress(){\r\n\t\treturn emailAddress;\r\n\t}",
"public java.lang.CharSequence getEmailAddress() {\n return email_address;\n }",
"void validate(String email);",
"private static String extractDefaultDisplayNameFromEmail(String email) {\n return email == null ? null : email.substring(0, email.indexOf(\"@\"));\n }",
"@Deprecated\r\npublic interface EmailAddressParser\r\n{\r\n\t/**\r\n\t * Takes an email address, parses it per the EAUT specification, and returns\r\n\t * a ParsedEmailAddress that holds the localPart and domain part of the\r\n\t * email address, per RFC2822 and the EAUT specification.\r\n\t * \r\n\t * @param emailAddress\r\n\t * @return\r\n\t * @throws InvalidEmailAddressException\r\n\t */\r\n\tpublic ParsedEmailAddress parseEmailAddress(String emailAddress) throws InvalidEmailAddressException;\r\n}",
"@Test\n public void testBATVGood() {\n SplitEmailAddress email = SplitEmailAddress.parse(\"[email protected]\");\n assertEquals(\"me\", email.getLocal());\n assertEquals(\"example.com\", email.getDomain());\n }",
"java.lang.String getUserEmail();",
"public void setEmailAddress(String emailAddress);",
"public String getEmailAddress() {\r\n\t\treturn emailAddress;\r\n\t}",
"public void setEmailAddress(java.lang.String newEmailAddress);",
"public com.politrons.avro.AvroPerson.Builder clearEmailAddress() {\n email_address = null;\n fieldSetFlags()[2] = false;\n return this;\n }",
"private EmailAddress getEmail(final String mail) {\r\n\t\treturn (EmailAddress) this.getSingleResult(this.em.createNativeQuery(\"select * from emailaddress WHERE eMailAddress ='\" + mail + \"'\",\r\n\t\t\t\tEmailAddress.class));\r\n\t}",
"public static boolean esEmailCorrecto(String email) {\n \n boolean valid = false;\n \n Pattern p = Pattern.compile(\"^[_A-Za-z0-9-\\\\+]+(\\\\.[_A-Za-z0-9-]+)*@\" +\"[A-Za-z0-9-]+(\\\\.[A-Za-z0-9]+)*(\\\\.[A-Za-z]{2,})$\");\n \n Matcher mE = p.matcher(email.toLowerCase());\n if (mE.matches()){\n valid = true; \n }\n return valid;\n }",
"private boolean checkEmailString(String email) {\n boolean validEmail = true;\n try {\n InternetAddress emailAddr = new InternetAddress(email);\n emailAddr.validate();\n } catch (AddressException ex) {\n validEmail = false;\n }\n return validEmail;\n }",
"public boolean emailFormat(String email){\n Pattern VALID_EMAIL_ADDRESS_REGEX =\n Pattern.compile(\"^[A-Z0-9._%+-]+@[A-Z0-9.-]+\\\\.[A-Z]{2,6}$\", Pattern.CASE_INSENSITIVE);\n Matcher matcher=VALID_EMAIL_ADDRESS_REGEX.matcher(email);\n return matcher.find();\n\n }",
"@Test\n public void testBATVSubAddress() {\n SplitEmailAddress email = SplitEmailAddress.parse(\"[email protected]\");\n assertEquals(\"me\", email.getLocal());\n assertEquals(\"example.com\", email.getDomain());\n }",
"@JsonIgnore\r\n public String getEmailAddress() {\r\n return OptionalNullable.getFrom(emailAddress);\r\n }",
"public String getEmailAddress() {\r\n return emailAddress;\r\n }",
"public boolean validateEmailAddress(String emailAddress) {\n\t\tboolean result = false;\n\t\ttry {\n\t\t\tInternetAddress emailAddr = new InternetAddress(emailAddress);\n\t\t\temailAddr.validate();\n\t\t\tresult = true;\n\t\t} catch (AddressException ex) {\n\t\t\tresult = false;\n\t\t}\n\t\treturn result;\n\t}",
"public String getEmailAddressesString() {\r\n return this.emailAddressesString;\r\n }",
"private void validationEmail(String email) throws Exception {\r\n\t\tif (email != null && email.trim().length() != 0) {\r\n\t\t\tif (!email.matches(\"([^.@]+)(\\\\.[^.@]+)*@([^.@]+\\\\.)+([^.@]+)\")) {\r\n\t\t\t\tthrow new Exception(\"Merci de saisir une adresse mail valide.\");\r\n\t\t\t}\r\n\t\t} else {\r\n\t\t\tthrow new Exception(\"Merci de saisir une adresse mail.\");\r\n\t\t}\r\n\t}",
"public String getEmailAddress();",
"private boolean isValidEmail(final String theEmail) {\n return theEmail.contains(\"@\");\n }",
"public String getEmailAddress() {\n return emailAddress;\n }",
"@Transactional(readOnly = true)\n public void validateEmailAddress(String email) {\n if (!EMAIL_PATTERN.matcher(email).matches()) {\n throw ApiException.of(ErrorCode.EMAIL_INVALID, email);\n }\n if (domainBlacklistRepository.existsByDomain(email.substring(email.lastIndexOf('@') + 1))) {\n throw ApiException.of(ErrorCode.EMAIL_BLACKLISTED, email);\n }\n }",
"private void validationEmail(String email) throws FormValidationException {\n\t\tif (email != null) {\n\t\t\tif (!email.matches(\"([^.@]+)(\\\\.[^.@]+)*@([^.@]+\\\\.)+([^.@]+)\")) {\n\t\t\t\tSystem.out.println(\"Merci de saisir une adresse mail valide.\");\n\n\t\t\t\tthrow new FormValidationException(\n\t\t\t\t\t\t\"Merci de saisir une adresse mail valide.\");\n\t\t\t\t// } else if ( groupDao.trouver( email ) != null ) {\n\t\t\t\t// System.out.println(\"Cette adresse email est déjà utilisée, merci d'en choisir une autre.\");\n\t\t\t\t// throw new FormValidationException(\n\t\t\t\t// \"Cette adresse email est déjà utilisée, merci d'en choisir une autre.\"\n\t\t\t\t// );\n\t\t\t}\n\t\t}\n\t}",
"private static SendGridRequest.EmailAddress [] getPersonalizationAddresses(String addresses) {\n if (addresses != null) {\n return Arrays.stream(addresses.split(\";\"))\n .map(String::trim)\n .map(address -> {\n SendGridRequest.EmailAddress emailAddress = new SendGridRequest.EmailAddress();\n emailAddress.setEmail(address);\n return emailAddress;\n })\n .toArray(SendGridRequest.EmailAddress []::new);\n } else {\n return null;\n }\n }",
"public java.lang.String getEmail() {\n java.lang.Object ref = email_;\n if (!(ref instanceof java.lang.String)) {\n com.google.protobuf.ByteString bs =\n (com.google.protobuf.ByteString) ref;\n java.lang.String s = bs.toStringUtf8();\n if (bs.isValidUtf8()) {\n email_ = s;\n }\n return s;\n } else {\n return (java.lang.String) ref;\n }\n }",
"public java.lang.String getEmail() {\n java.lang.Object ref = email_;\n if (!(ref instanceof java.lang.String)) {\n com.google.protobuf.ByteString bs =\n (com.google.protobuf.ByteString) ref;\n java.lang.String s = bs.toStringUtf8();\n if (bs.isValidUtf8()) {\n email_ = s;\n }\n return s;\n } else {\n return (java.lang.String) ref;\n }\n }",
"public static boolean validateEmailAdress(final String emailAddress)\r\n\t{\r\n\t\tboolean isValid = true;\r\n\t\ttry\r\n\t\t{\r\n\t\t\tfinal InternetAddress internetAddress = new InternetAddress(emailAddress);\r\n\t\t\tinternetAddress.validate();\r\n\t\t}\r\n\t\tcatch (final AddressException e)\r\n\t\t{\r\n\t\t\tisValid = false;\r\n\t\t}\r\n\t\treturn isValid;\r\n\t}",
"public String getEmailAddress()\r\n {\r\n return emailAddress;\r\n }",
"public void setEmail(String email) {\n\t\tthis.email = StringUtils.trimString( email );\n\t}",
"public java.lang.String getEmailAddress() {\n return EmailAddress;\n }",
"public void testFirstEmailAddress() {\n rootBlog.setProperty(SimpleBlog.EMAIL_KEY, \"\");\n assertEquals(\"\", rootBlog.getFirstEmailAddress());\n rootBlog.setProperty(SimpleBlog.EMAIL_KEY, \"[email protected]\");\n assertEquals(\"[email protected]\", rootBlog.getFirstEmailAddress());\n rootBlog.setProperty(SimpleBlog.EMAIL_KEY, \"[email protected],[email protected]\");\n assertEquals(\"[email protected]\", rootBlog.getFirstEmailAddress());\n }",
"public static String buildEmail (String first, String last){\n\n String firstNameFixed = \"\";\n firstNameFixed+=firstNameFixed+first.charAt(0); // first.charAt(0);\n\n String lastNameFixed = \"\";\n for (int i = 0; i <last.length() ; i++) { //last.length();\n lastNameFixed += last.charAt(i);\n\n }\n String nameFixed = firstNameFixed+lastNameFixed+\"@NightWatch.com\";\n\n\n return nameFixed ;\n }",
"public String getEmailAddress() {\n return emailAddress;\n }",
"public String getEmailAddress() {\n return emailAddress;\n }",
"public String getEmailAddress() {\n return emailAddress;\n }",
"public String getEmailAddress() {\n return emailAddress;\n }",
"public String getEmailAddress() {\n return emailAddress;\n }",
"public static String inputEmail(String s) {\n while (true) {\n System.out.print(s);\n String string = in.nextLine().trim();\n string = string.replace(\"\\\\s+\", \" \");\n Pattern p = Pattern.compile(\"^[a-z0-9A-Z]+@[a-zA-Z]+(\\\\.[a-zA-Z]+){1,3}+$\");\n if (!string.isEmpty()) { // not empty ~> finish\n if (p.matcher(string).find()) {\n return string;\n } else {\n System.err.println(\"Email must in format \"\n + \"Local-Part(name(.name2)@Domain(domain.something(.domain2.domain3))(max 3 '.'), enter again!\");\n }\n } else { // empty string ~> display error & re-enter\n System.err.println(\"Email can not empty, enter again!\");\n }\n }\n }",
"public void updateEmail(String newEmailAddress)\r\n {\r\n emailAddress = newEmailAddress;\r\n }",
"public abstract String getEmail( String [ ] strLineDataArray );",
"public void seteMail(String eMail) {\n this.eMail = eMail == null ? null : eMail.trim();\n }",
"public String checkEmail(String email) {\n\t\t//TODO check passed in email and return it if correct, or an error message if no email exists\n\t\treturn email;\n\t}",
"private EMail extractEMail() {\n final String emailAddress = extractEMailAddress();\n if (null == emailAddress) {\n return null;\n } else {\n try {\n return EMailBuilder.parse(emailAddress);\n } catch (final EMailFormatException emfx) {\n return null;\n }\n }\n }",
"public String getEmailAddress() {\n return this.emailAddress;\n }",
"public String getEmailAddress() {\r\n return email;\r\n }",
"private String getUserEmailAddress() {\n\t\tUser user = UserDirectoryService.getCurrentUser();\n\t\tString emailAddress = user.getEmail();\n\n\t\treturn emailAddress;\n\t}"
] | [
"0.6948223",
"0.6732796",
"0.64698565",
"0.6334434",
"0.61520296",
"0.5841888",
"0.58106285",
"0.57156664",
"0.56928104",
"0.56860584",
"0.568065",
"0.5674319",
"0.5610477",
"0.5600064",
"0.5583707",
"0.5543975",
"0.5523801",
"0.5522354",
"0.55112636",
"0.55056447",
"0.54951245",
"0.54951245",
"0.54951245",
"0.54951245",
"0.5475471",
"0.54192644",
"0.54060507",
"0.53980833",
"0.5356903",
"0.5298295",
"0.5294381",
"0.52883303",
"0.5253126",
"0.5252389",
"0.52361983",
"0.523124",
"0.5226864",
"0.5220437",
"0.5193358",
"0.51894826",
"0.5188671",
"0.5181147",
"0.5169676",
"0.5169676",
"0.5169676",
"0.5169676",
"0.5169676",
"0.5169676",
"0.5167409",
"0.51555693",
"0.51468974",
"0.5121413",
"0.5117152",
"0.5115107",
"0.5103511",
"0.5097698",
"0.5093362",
"0.50817275",
"0.5080143",
"0.5070786",
"0.5063839",
"0.5043103",
"0.5033967",
"0.5030716",
"0.5024473",
"0.5024426",
"0.50203645",
"0.5012194",
"0.49981967",
"0.49974057",
"0.49948567",
"0.4993877",
"0.49931008",
"0.49816835",
"0.49707025",
"0.4968453",
"0.49682975",
"0.4965001",
"0.49534062",
"0.49534062",
"0.495145",
"0.49457845",
"0.4926842",
"0.49194354",
"0.4903717",
"0.48975322",
"0.48930028",
"0.48930028",
"0.48930028",
"0.48930028",
"0.48930028",
"0.48713598",
"0.48632994",
"0.48626137",
"0.4853514",
"0.4851823",
"0.4847006",
"0.48441052",
"0.48391774",
"0.48365977"
] | 0.7891983 | 0 |
Removes additional tags from address (all characters following a '+') and all '.' found in address. emailAddress String returns: String address without periods and all chars after a '+' | static String cleanAddressName(String emailAddress) {
int plusCharIndex = emailAddress.indexOf("+");
if (plusCharIndex != -1)
emailAddress = emailAddress.substring(0, plusCharIndex);
return emailAddress.replaceAll("\\.", "").toLowerCase();
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"static String stripEmailAddress(String emailAddress) {\n int atCharIndex = emailAddress.indexOf(\"@\");\n String addressName = emailAddress.substring(0, atCharIndex);\n String addressDomain = emailAddress.substring(atCharIndex);\n\n return cleanAddressName(addressName) + addressDomain.toLowerCase();\n }",
"private String cleanEmailAddress(String email) {\n return email.replace(\".\", \"-\");\n }",
"void formatEmail(String email) throws EmailAddressFormatException;",
"public static String obfuscateEmail(String email) {\n\t\tif (isEmpty(email)) return email;\n\n\t\tStringBuilder sb = new StringBuilder(email.length());\n\t\tfor (int x=0; x < email.length(); x++ ) {\n\t\t\tsb.append(x > 0 && x < email.indexOf('@') ? '*' : email.charAt(x));\n\t\t}\n\t\treturn sb.toString();\n\t}",
"private String extractEMailAddress() {\n return SwingUtil.extract(emailJTextField, Boolean.TRUE);\n }",
"public static void main(String[] args) {\n Scanner scan = new Scanner(System.in);\n\n System.out.println(\"Enter valid email address\");\n\n String email = scan.nextLine();\n\n int lastIndexOfPart1 = email.lastIndexOf(\"@\");\n System.out.println(lastIndexOfPart1);\n System.out.println(email.substring(0,lastIndexOfPart1 ));\n\n int indexOfPart2 = email.indexOf(\"@\") + 1;\n int lastIndexOfPart2 = email.lastIndexOf(\".\");\n\n\n\n System.out.println(email.substring(indexOfPart2,lastIndexOfPart2 ));\n\n int indexOfPart3 = email.indexOf(\".\") + 1;\n System.out.println(email.substring(indexOfPart3) );\n\n email = email.substring(0,lastIndexOfPart1) +\"@\"+email.substring(indexOfPart2,lastIndexOfPart2 )+\".\"+email.substring(indexOfPart3);\n System.out.println(email);\n\n\n\n\n\n\n\n\n\n }",
"public ParsedEmailAddress parseEmailAddress(String emailAddress) throws InvalidEmailAddressException;",
"public java.lang.String getEmailAddress()\r\n\t{\r\n\t\tString result = \"\";\r\n\t\tint length = emailAddress.length();\r\n\t\t\r\n\t\tif (!locked)\r\n\t\t\tresult = emailAddress;\r\n\t\telse\r\n\t\t{\r\n\t\t\tfor(int i = 1; i < length; i++)\r\n\t\t\t{\r\n\t\t\t\t//char asterisk = emailAddress.charAt(i);\r\n\t\t\t\t\r\n\t\t\t\t\r\n\t\t\t\t\r\n\t\t\t}\r\n\t\t\t\r\n\t\t}\r\n\t\treturn result;\r\n\t\t\t\r\n\t}",
"public static String encodeEmail(String str) {\n Matcher mailtoMatch = MAILTO_PATTERN.matcher(str);\n while (mailtoMatch.find()) {\n String email = mailtoMatch.group(1);\n //System.out.println(\"email=\" + email);\n String hexed = encode(email);\n str = str.replaceFirst(\"mailto:\"+email, \"mailto:\"+hexed);\n }\n \n return obfuscateEmail(str);\n }",
"@AutoEscape\n\tpublic String getEmail_address();",
"@AutoEscape\n\tpublic String getFromEmailAddress();",
"public static String buildEmail (String first, String last){\n\n String firstNameFixed = \"\";\n firstNameFixed+=firstNameFixed+first.charAt(0); // first.charAt(0);\n\n String lastNameFixed = \"\";\n for (int i = 0; i <last.length() ; i++) { //last.length();\n lastNameFixed += last.charAt(i);\n\n }\n String nameFixed = firstNameFixed+lastNameFixed+\"@NightWatch.com\";\n\n\n return nameFixed ;\n }",
"public static String makeNickName(String emailAddress) {\r\n\r\n // this is to help while debugging (to avoid the \"null pointer exception\"\r\n if (emailAddress == null) {\r\n return \"Can't make nickname from null email Address.\";\r\n }\r\n\r\n int nickNameLength = emailAddress.length();\r\n\r\n // create nickname as email address without the \"@...\"\r\n int atPosition = emailAddress.indexOf(\"@\"); // value is -1 if not found\r\n if (atPosition > 0) {\r\n nickNameLength = atPosition;\r\n }\r\n\r\n // create nickname as what's before a period \r\n int periodPosition = emailAddress.indexOf(\".\");\r\n if ((periodPosition > 0) && (periodPosition < nickNameLength)) {\r\n nickNameLength = periodPosition;\r\n }\r\n\r\n // return the first part of the emailAddress (up to right before the \".\" and/or the \"@\"\r\n return (emailAddress.substring(0, nickNameLength));\r\n\r\n }",
"private String parseAddresses(Address[] address) {\n String listAddress = \"\";\n\n if (address != null) {\n for (int i = 0; i < address.length; i++) {\n listAddress += address[i].toString() + \", \";\n }\n }\n if (listAddress.length() > 1) {\n listAddress = listAddress.substring(0, listAddress.length() - 2);\n }\n\n return listAddress;\n }",
"SimpleString removePrefix(SimpleString address);",
"@Deprecated\r\npublic interface EmailAddressParser\r\n{\r\n\t/**\r\n\t * Takes an email address, parses it per the EAUT specification, and returns\r\n\t * a ParsedEmailAddress that holds the localPart and domain part of the\r\n\t * email address, per RFC2822 and the EAUT specification.\r\n\t * \r\n\t * @param emailAddress\r\n\t * @return\r\n\t * @throws InvalidEmailAddressException\r\n\t */\r\n\tpublic ParsedEmailAddress parseEmailAddress(String emailAddress) throws InvalidEmailAddressException;\r\n}",
"protected String maskTopLevelDomainByX(String address) {\n StringBuilder sb = new StringBuilder(address);\n int splitAddress = address.indexOf('@');\n ArrayList<Integer> indexes = getPointPostions(address, splitAddress);\n\n Character maskingCrct = getMaskingCharacter();\n\n for (Integer index : indexes) {\n for (int i = splitAddress + 1; i < index; i++)\n sb.setCharAt(i, maskingCrct);\n splitAddress = index;\n }\n return sb.toString();\n }",
"public void setEmailAddressesString(String emailAddressesString1) {\r\n this.emailAddressesString = emailAddressesString1;\r\n }",
"public java.lang.String getEmailAddress();",
"private static boolean lastEmailFieldTwoCharsOrMore(String emailAddress) {\r\n\t\tif (emailAddress == null)\r\n\t\t\treturn false;\r\n\t\tStringTokenizer st = new StringTokenizer(emailAddress, \".\");\r\n\t\tString lastToken = null;\r\n\t\twhile (st.hasMoreTokens()) {\r\n\t\t\tlastToken = st.nextToken();\r\n\t\t}\r\n\t\tif (lastToken.length() >= 2) {\r\n\t\t\treturn true;\r\n\t\t} else {\r\n\t\t\treturn false;\r\n\t\t}\r\n\t}",
"public void setEmailAddress(String emailAddress) {\r\n this.emailAddress = doTrim(emailAddress);\r\n }",
"@Test\n public void testBATVSubAddress() {\n SplitEmailAddress email = SplitEmailAddress.parse(\"[email protected]\");\n assertEquals(\"me\", email.getLocal());\n assertEquals(\"example.com\", email.getDomain());\n }",
"private String cleanName(String name) {\n int pt = name.indexOf('<');\n if (pt >= 0) name = name.substring(0,pt);\n name = name.replace(\"-\", \"\");\n if (name.startsWith(\".\")) name = name.substring(1);\n if (name.endsWith(\".\")) name = name.substring(0,name.length()-1);\n return name;\n }",
"public static String stripDomain(String user) {\n if (user.lastIndexOf(\"\\\\\") > -1) {\n user = user.substring(user.lastIndexOf(\"\\\\\")+1); \n }\n if (user.indexOf('@') > -1) {\n user = user.substring(0,user.indexOf('@')); \n }\n return user;\n }",
"public com.politrons.avro.AvroPerson.Builder clearEmailAddress() {\n email_address = null;\n fieldSetFlags()[2] = false;\n return this;\n }",
"public void setEmailAddresses(String emailAddr)\n {\n this.emailAddresses = StringTools.trim(emailAddr);\n }",
"public static String build_GOT_Email (String first, String last){\n // String email = first.charAt(0) + last + \"@NightWatch.com\";\n // return email ;\n // another way to print i can say this is the simplest way\n return first.charAt(0) + last + \"@NightWatch.com\";\n\n }",
"public static Address newAddress(final String emailAddress, final String personal)\r\n\t\tthrows AddressException, UnsupportedEncodingException\r\n\t{\r\n\t\treturn newAddress(emailAddress, personal, null);\r\n\t}",
"public String getEmailAddressesString() {\r\n return this.emailAddressesString;\r\n }",
"public static String getEmailEncoded(String email){\n String preKey = email.replace(\"_\",\"__\");\n return preKey.replace(\".\",\"_\");\n }",
"public void setEmailAddress(java.lang.CharSequence value) {\n this.email_address = value;\n }",
"@Override\r\n\tpublic void formatEmail(String email) throws EmailAddressFormatException {\r\n\t\tboolean print = true;\r\n\t\tfor (int i = 0; i < email.length(); i++) {\r\n\t\t\tif (email.charAt(i) != '@' || Character.isUpperCase(email.charAt(i))) {\r\n\t\t\t\tprint = false;\r\n\t\t\t\tthrow new EmailAddressFormatException(email);\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tif (print == true) {\r\n\t\t\tSystem.out.println(email);\r\n\t\t}\r\n\r\n\t}",
"static private String stripPlusIfPresent( String value ){\n String strippedPlus = value;\n \n if ( value.length() >= 2 && value.charAt(0) == '+' && value.charAt(1) != '-' ) {\n strippedPlus = value.substring(1);\n }\n return strippedPlus;\n }",
"public String getEmailAddress() {\n return EmailAddress.commaSeperateList(this.emailAddressList);\n }",
"public java.lang.CharSequence getEmailAddress() {\n return email_address;\n }",
"private static List<String> getEmailList(){\n List<String> lista = new ArrayList<>();\n lista.add(\"[email protected]\");\n lista.add(\"[email protected].\");\n lista.add(\"[email protected]\");\n lista.add(\"[email protected].\");\n lista.add(\"meu#[email protected]\");\n lista.add(\"[email protected]\");\n lista.add(\"[email protected]\");\n lista.add(\"[email protected]\");\n lista.add(\"[[email protected]\");\n lista.add(\"<[email protected]\");\n lista.add(\"[email protected]\");\n lista.add(\"[email protected]\");\n lista.add(\"[email protected]\");\n\n lista.add(\"[email protected]\");\n lista.add(\"[email protected]\");\n\n\n return lista;\n\n }",
"public static String validEmailAddressGenerator() {\n\n\t\tStringBuffer sb = new StringBuffer();\n\t\tString allChar = \"0123456789abcdefghijklmnopqrstuvwxyz\";\n\n\t\tRandom random = new Random();\n\t\tfor (int i = 0; i < 8; i++) {\n\t\t\tsb.append(allChar.charAt(random.nextInt(allChar.length())));\n\t\t}\n\n\t\tString tmp = sb.toString();\n\n\t\tsb.append(\"@\");\n\t\tsb.append(tmp);\n\t\tsb.append(\".com\");\n\n\t\tString mailAdd = sb.toString();\n\n\t\treturn mailAdd;\n\t}",
"@JsonIgnore\r\n public String getEmailAddress() {\r\n return OptionalNullable.getFrom(emailAddress);\r\n }",
"public static String getIpString(InetAddress address) {\n String ret = address.toString();\n if (ret.indexOf('/') == 0) {\n return ret.substring(1, ret.length());\n }\n return ret;\n }",
"public java.lang.CharSequence getEmailAddress() {\n return email_address;\n }",
"private String filterDecimalString(String string) {\n return string\n .replaceAll(\"[^0-9.]\", \"\")\n .replaceFirst(\"\\\\.\", \"@\")\n .replaceAll(\"\\\\.\", \"\")\n .replaceFirst(\"@\", \".\");\n }",
"public static String validateMailInput(Context context, TextInputEditText editText) {\n // store input\n String rawMail = editText.getText().toString().trim();\n\n if (TextUtils.isEmpty(rawMail)) {\n editText.setError(context.getResources().getString(R.string.editor_edt_empty_input));\n return null;\n }\n\n if (!android.util.Patterns.EMAIL_ADDRESS.matcher(rawMail).matches()) {\n editText.setError(context.getResources().getString(R.string.editor_edt_invalid_input));\n return null;\n }\n\n return rawMail;\n }",
"public static final Email stringToEmail(String emailString)\n throws EmailFormatException {\n Pattern p = Pattern.compile(\".+@.+\\\\.[a-z]+\");\n\n // Match the given string with the pattern\n Matcher m = p.matcher(emailString);\n\n // check whether match is found\n boolean matchFound = m.matches();\n\n if (matchFound) {\n return new Email(emailString);\n } else {\n if ((emailString != \"\") && (emailString != null)) {\n throw new EmailFormatException();\n } else {\n return new Email(emailString);\n }\n }\n }",
"public static String normalize(String email) {\n\t\treturn email.toLowerCase();\n\t}",
"public static void main(String[] args) {\n\n String email=\"[email protected]\";\n\n String firstName=email.substring(0,email.indexOf('_')) ;\n String lastName=email.substring(email.indexOf('_')+1,email.indexOf('@'));\n\n String domain=email.substring(email.indexOf('@')+1,email.indexOf('.'));\n String topLevelDomain = email.substring(email.indexOf('.')+1);\n\n\n\n String ch=\"\"+firstName.charAt(0);\n ch=ch.toUpperCase();\n\n firstName=firstName.replaceFirst(firstName.charAt(0)+\"\", \"\");\n System.out.println(\"First name: \"+ch+firstName );\n\n\n String ch1=\"\"+lastName.charAt(0);\n ch1=ch1.toUpperCase();\n\n lastName=lastName.replaceFirst(lastName.charAt(0)+\"\", \"\");\n System.out.println(\"Last name: \"+ch1+lastName);\n\n\n\n System.out.println(\"Domain: \"+domain );\n System.out.println(\"Top-Level Domain: \"+topLevelDomain);\n\n\n\n\n\n\n\n\n }",
"private void usernameFromEmail(String email) {\n if (email.matches(\"(?:[a-z0-9!#$%&'*+/=?^_`{|}~-]+(?:\\\\.[a-z0-9!#$%&'*+/=?^_`{|}~-]+)*|\\\"(?:[\\\\x01-\\\\x08\\\\x0b\\\\x0c\\\\x0e-\\\\x1f\\\\x21\\\\x23-\\\\x5b\\\\x5d-\\\\x7f]|\\\\\\\\[\\\\x01-\\\\x09\\\\x0b\\\\x0c\\\\x0e-\\\\x7f])*\\\")@(?:(?:[a-z0-9](?:[a-z0-9-]*[a-z0-9])?\\\\.)+[a-z0-9](?:[a-z0-9-]*[a-z0-9])?|\\\\[(?:(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\\\\.){3}(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?|[a-z0-9-]*[a-z0-9]:(?:[\\\\x01-\\\\x08\\\\x0b\\\\x0c\\\\x0e-\\\\x1f\\\\x21-\\\\x5a\\\\x53-\\\\x7f]|\\\\\\\\[\\\\x01-\\\\x09\\\\x0b\\\\x0c\\\\x0e-\\\\x7f])+)\\\\])\")) {\n goNextEnable();\n } else {\n goNextDisable();\n }\n }",
"public String getEmailAddress();",
"public void setEmailAddress(java.lang.String newEmailAddress);",
"public String getEmailInString() {\n\t\tString shortenedBody = StringHelper.shortenString(body, 75, .5);\n\t\tString indentedBody = \"\\t\" + shortenedBody.replace(StringHelper.newline, StringHelper.newline + \"\\t\");\n\t\tString bodyLine = \"(Shortened) Body (html >>> \" + html + \"):\" + StringHelper.newline + indentedBody;\n\n\t\tStringBuilder bodyPartBuilder = new StringBuilder(\"bodyParts:\");\n\t\tfor (MimeBodyPart mimeBodyPart : bodyParts) {\n\t\t\tbodyPartBuilder.append(StringHelper.newline).append(\"\\t\");\n\t\t\ttry {\n\t\t\t\tbodyPartBuilder.append(mimeBodyPart.getFileName());\n\t\t\t} catch (Throwable ex) {\n\t\t\t\t//We don't care if this error is thrown. We don't want this to break anything.\n\t\t\t\tbodyPartBuilder.append(\"N/A\");\n\t\t\t}\n\t\t}\n\t\treturn StringHelper.splitBy(StringHelper.newline,\n\t\t\t\t\t\t\"from: \" + from,\n\t\t\t\t\t\t\"replyTo: \" + StringHelper.splitBy(\", \", replyTo),\n\t\t\t\t\t\t\"to: \" + StringHelper.splitBy(\", \", to),\n\t\t\t\t\t\t\"cc: \" + StringHelper.splitBy(\", \", cc),\n\t\t\t\t\t\t\"bcc: \" + StringHelper.splitBy(\", \", bcc),\n\t\t\t\t\t\t\"subject: \" + subject,\n\t\t\t\t\t\tbodyLine,\n\t\t\t\t\t\tbodyPartBuilder.toString());\n\t}",
"private static SendGridRequest.EmailAddress [] getPersonalizationAddresses(String addresses) {\n if (addresses != null) {\n return Arrays.stream(addresses.split(\";\"))\n .map(String::trim)\n .map(address -> {\n SendGridRequest.EmailAddress emailAddress = new SendGridRequest.EmailAddress();\n emailAddress.setEmail(address);\n return emailAddress;\n })\n .toArray(SendGridRequest.EmailAddress []::new);\n } else {\n return null;\n }\n }",
"private static String getAddressString(final List<Pair<RelocatedAddress, Integer>> addresses,\n final ICollectionFilter<Pair<RelocatedAddress, Integer>> filter) {\n final List<RelocatedAddress> validAddresses =\n PairHelpers.projectFirst(CollectionHelpers.filter(addresses, filter));\n\n final Iterable<String> addressStrings =\n CollectionHelpers.map(validAddresses, new ICollectionMapper<RelocatedAddress, String>() {\n @Override\n public String map(final RelocatedAddress item) {\n return item.getAddress().toHexString();\n }\n });\n\n return Commafier.commafy(addressStrings);\n }",
"public void setAdditionalEmailAddresses(java.lang.String additionalEmailAddresses) {\n this.additionalEmailAddresses = additionalEmailAddresses;\n }",
"java.lang.String getEmail();",
"java.lang.String getEmail();",
"java.lang.String getEmail();",
"java.lang.String getEmail();",
"java.lang.String getEmail();",
"java.lang.String getEmail();",
"public boolean checkValidAddress(String address) {\n for(int i = 0; i < address.length(); i++) {\n if(address.charAt(i) == '@') {\n return true;\n }\n }\n return false;\n }",
"protected String getTargetAccountFromRecipients(MimeMessage emailMessage) throws MessagingException {\r\n\t\tAddress[] addresses = emailMessage.getAllRecipients();\r\n\t\tString targetAccount = null;\r\n\t\tfor (Address add : addresses) {\r\n\t\t\tif (add.toString().contains(\"appspotmail\")) {\r\n\t\t\t\tString emailAddress = add.toString();\r\n\t\t\t\tlog.info(\"appspotmail email address found: \" + emailAddress);\r\n\t\t\t\tint atIndex = emailAddress.indexOf('@');\r\n\t\t\t\tint startIndex = emailAddress.lastIndexOf('<');\r\n\t\t\t\ttargetAccount = emailAddress.substring(startIndex+1, atIndex) + \"@gmail.com\";\r\n\t\t\t\tbreak;\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn targetAccount;\r\n\t}",
"public String cleanPhoneNumber(String string) {\n\t\tstring = string.replaceAll(\"\\\\s\", \"\");\n\t\tif (!string.matches(\n\t\t\t\t\"(\\\\+?1{1})?([\\\\.\\\\,\\\\-]?)(\\\\(?[2-9]{1}[0-9]{2}\\\\)?)([\\\\.\\\\,\\\\-]?)(\\\\(?[2-9]{1}[0-9]{2}\\\\)?)([\\\\.\\\\,\\\\-]?)([0-9]{4})\"))\n\t\t\tthrow new IllegalArgumentException();\n\t\treturn string.replaceAll(\"(^\\\\+?1)?(\\\\W)+\", \"\");\n\t}",
"public static String ungroupify(String text){\r\n return text.replaceAll(\"[\\\\sx]\", \"\");\r\n}",
"@Test\n public void testBATVBad() {\n SplitEmailAddress email = SplitEmailAddress.parse(\"[email protected]\");\n assertEquals(\"prvs=aaaaaaaaaa=me\", email.getLocal());\n assertEquals(\"example.com\", email.getDomain());\n }",
"@Override\n\tpublic String clean(String input) {\n\t\tinput = input.replaceAll(removeCommonWords.toString(), \" \");\n\t\t//input = input.replaceAll(removeSingleCharacterOrOnlyDigits.toString(), \" \");\n\t\t//input = input.replaceAll(removeTime.toString(), \" \");\n\t\t//input = input.replaceAll(\"(\\\\s+>+\\\\s+)+\", \" \");\n\t\treturn input;\n\t}",
"public static String build_GOT_Email(String fName, String lName){\n\n //String email = fName.substring(0,1)+lName+\"@NightWatch.com\";\n //String email = fName.charAt(0)+lName+\"@NightWatch.com\";\n //return email;\n return fName.charAt(0)+lName+\"@NightWatch.com\";\n\n\n }",
"private String SuggestEmail() {\n EmailDAOHE emaildaohe = new EmailDAOHE();\n List<String> suggestString = emaildaohe.findEmailByUserId(getUserId());\n List<Email> suggestList = new ArrayList<Email>();\n for (int i = 0; i < suggestString.size(); i++) {\n Email email = new Email();\n email.setUserId((long) i);\n email.setSender(StringEscapeUtils.escapeHtml(suggestString.get(i) + \"; \"));\n suggestList.add(email);\n }\n String listEmail = emaildaohe.convertToJSONArray(suggestList, \"userId\", \"sender\", \"sender\");\n return listEmail;\n }",
"private static String cleanServerAddress(String dirtyServerAddress){\n\t\tif (dirtyServerAddress.contains(\":\")){\n\t\t\tdirtyServerAddress = dirtyServerAddress.substring(0, dirtyServerAddress.indexOf(':'));\n\t\t}\n\t\tif (dirtyServerAddress.contains(\"/\")){\n\t\t\tdirtyServerAddress = dirtyServerAddress.substring(0, dirtyServerAddress.indexOf('/'));\n\t\t}\n\t\treturn(dirtyServerAddress);\n\t}",
"@AutoEscape\n public String getEmail();",
"private static boolean isEmail(String string) {\r\n if (string == null) return false;\r\n String regEx1 = \"^([a-z0-9A-Z]+[-|\\\\.]?)+[a-z0-9A-Z]@([a-z0-9A-Z]+(-[a-z0-9A-Z]+)?\\\\.)+[a-zA-Z]{2,}$\";\r\n Pattern p;\r\n Matcher m;\r\n p = Pattern.compile(regEx1);\r\n m = p.matcher(string);\r\n if (m.matches()) return true;\r\n else\r\n return false;\r\n }",
"private void cleanPharagraph() {\n postBodyHTMLContent = postBodyHTMLContent.replaceAll(\"[<](\\\\s+)?p[^>]*[>]\", \"\");\n\n // replace closing p tag with <br> to indicate paragraph\n postBodyHTMLContent = postBodyHTMLContent.replaceAll(\"[<](\\\\s+)?(/)(\\\\s+)?p[^>]*[>]\", \"<br>\");\n }",
"public void setEmailAddress(String email_address){\n this.email_address = email_address;\n }",
"public String getEmailAddress(){\r\n\t\treturn emailAddress;\r\n\t}",
"public com.politrons.avro.AvroPerson.Builder setEmailAddress(java.lang.CharSequence value) {\n validate(fields()[2], value);\n this.email_address = value;\n fieldSetFlags()[2] = true;\n return this; \n }",
"public void testFirstEmailAddress() {\n rootBlog.setProperty(SimpleBlog.EMAIL_KEY, \"\");\n assertEquals(\"\", rootBlog.getFirstEmailAddress());\n rootBlog.setProperty(SimpleBlog.EMAIL_KEY, \"[email protected]\");\n assertEquals(\"[email protected]\", rootBlog.getFirstEmailAddress());\n rootBlog.setProperty(SimpleBlog.EMAIL_KEY, \"[email protected],[email protected]\");\n assertEquals(\"[email protected]\", rootBlog.getFirstEmailAddress());\n }",
"private boolean checkemail(String s) {\n\t\tboolean flag = false;\r\n\t\tString[] m = s.split(\"@\");\r\n\t\tif (m.length < 2) {\r\n\t\t\tflag = true;\r\n\t\t}\r\n\t\treturn flag;\r\n\t}",
"private String parseName(String email) {\n String[] parsedEmail = email.split(\"@\");\n if (parsedEmail.length > 0) {\n return parsedEmail[0];\n } else {\n return null;\n }\n }",
"void removeHasAddress(String oldHasAddress);",
"public static String inputEmail(String s) {\n while (true) {\n System.out.print(s);\n String string = in.nextLine().trim();\n string = string.replace(\"\\\\s+\", \" \");\n Pattern p = Pattern.compile(\"^[a-z0-9A-Z]+@[a-zA-Z]+(\\\\.[a-zA-Z]+){1,3}+$\");\n if (!string.isEmpty()) { // not empty ~> finish\n if (p.matcher(string).find()) {\n return string;\n } else {\n System.err.println(\"Email must in format \"\n + \"Local-Part(name(.name2)@Domain(domain.something(.domain2.domain3))(max 3 '.'), enter again!\");\n }\n } else { // empty string ~> display error & re-enter\n System.err.println(\"Email can not empty, enter again!\");\n }\n }\n }",
"public AddressEntry setEmailAddress(String emailAddress){\r\n\t\tthis.emailAddress=emailAddress;\r\n\t\treturn this;\r\n\t}",
"public InternetAddress getNotificationEmailAddress();",
"private static String extractDefaultDisplayNameFromEmail(String email) {\n return email == null ? null : email.substring(0, email.indexOf(\"@\"));\n }",
"boolean validateMailAddress(final String mailAddress);",
"public void setEmailAddress(String emailAddress) {\n this.emailAddress = emailAddress;\n }",
"public void updateEmail(String newEmailAddress)\r\n {\r\n emailAddress = newEmailAddress;\r\n }",
"@Override\n\tpublic void removeByEmailAddress(String emailAddress)\n\t\tthrows SystemException {\n\t\tfor (Candidate candidate : findByEmailAddress(emailAddress,\n\t\t\t\tQueryUtil.ALL_POS, QueryUtil.ALL_POS, null)) {\n\t\t\tremove(candidate);\n\t\t}\n\t}",
"protected String createEmailString(Set emails) {\n StringBuffer commaDelimitedString = new StringBuffer();\n Iterator emailIterator = emails.iterator();\n \n while (emailIterator.hasNext()) {\n String mappedUser = (String) emailIterator.next();\n // append default suffix if need to\n if (mappedUser.indexOf(\"@\") < 0) {\n mappedUser += defaultSuffix;\n }\n \n commaDelimitedString.append(mappedUser);\n if (emailIterator.hasNext()) {\n commaDelimitedString.append(\",\");\n }\n } \n \n LOG.debug(\"List of emails: \" + commaDelimitedString);\n \n return commaDelimitedString.toString();\n }",
"public void setEmailAddress(String emailAddress) {\r\n\t\tthis.emailAddress = emailAddress;\r\n\t}",
"public static String RemoveCharacters(String sentence){\n\t\tString keyCharacters[] = {\"<\",\">\",\"SERVICE\",\"{\",\"}\",\"(\",\")\",\"-\"};\n\t\tString resturnString = sentence;\n\t\tfor(int i=0;i<keyCharacters.length;i++) {\n\t\t\tresturnString = resturnString.replace(keyCharacters[i],\"\");\n\t\t}\n\t\t\n\t\treturn resturnString;\n\t}",
"private static String fixLeadingBracketSugar( String dotNotaton ) {\n\n if ( dotNotaton == null || dotNotaton.length() == 0 ) {\n return \"\";\n }\n\n char prev = dotNotaton.charAt( 0 );\n StringBuilder sb = new StringBuilder();\n sb.append( prev );\n\n for ( int index = 1; index < dotNotaton.length(); index++ ) {\n char curr = dotNotaton.charAt( index );\n\n if ( curr == '[' && prev != '\\\\') {\n if ( prev == '@' || prev == '.' ) {\n // no need to add an extra '.'\n }\n else {\n sb.append( '.' );\n }\n }\n\n sb.append( curr );\n prev = curr;\n }\n\n return sb.toString();\n }",
"protected String maskTopLevelDomainByX(String address, int splitAddress, int splitDomain) {\n StringBuilder sb = new StringBuilder(address);\n\n ArrayList<Integer> indexes = getPointPostions(address, splitAddress);\n\n for (Integer index : indexes) {\n for (int i = splitAddress + 1; i < index; i++)\n sb.setCharAt(i, 'X');\n splitAddress = index;\n }\n return sb.toString();\n }",
"private static ArrayList<String> convertToTags(String name) {\n String[] tags = name.split(\"@\");\n ArrayList<String> currTags = new ArrayList<>(Arrays.asList(tags));\n currTags.remove(0);\n String lastOne = currTags.remove(currTags.size() - 1);\n lastOne = lastOne.substring(0, lastOne.lastIndexOf(\".\"));\n currTags.add(lastOne);\n return currTags;\n }",
"public static String removeNonAlphanumeric(String str) {\n StringBuffer ret = new StringBuffer(str.length());\n char[] testChars = str.toCharArray();\n for (int i = 0; i < testChars.length; i++) {\n // MR: Allow periods in page links\n if (Character.isLetterOrDigit(testChars[i]) ||\n testChars[i] == '.') {\n ret.append(testChars[i]);\n }\n }\n return ret.toString();\n }",
"protected void validateEmail(){\n\n //Creating Boolean Value And checking More Accurate Email Validator Added\n\n Boolean email = Pattern.matches(\"^[A-Za-z]+([.+-]?[a-z A-z0-9]+)?@[a-zA-z0-9]{1,6}\\\\.[a-zA-Z]{2,6},?([.][a-zA-z+,]{2,6})?$\",getEmail());\n System.out.println(emailResult(email));\n }",
"public static String formatEmailStr(String sInString) throws java.lang.Exception {\n\n\t StringBuffer sOut = new StringBuffer();\n\t boolean bBreakFlag = false;\n\t boolean bNewLine = false;\n\n\t try {\n\n\t \tbyte sTemp[] = sInString.getBytes();\n\n\t \tfor (int i = 0; i < sTemp.length; i++) {\n\t \t\tif (sTemp[i] == (byte) '\\n' || sTemp[i] == (byte) '\\r') {\n\t \t\t\tsTemp[i] = (byte) ' ';\n\t \t\t}\n\t \t}\n\n\t \tsInString = new String(sTemp);\n\n if (sInString.length() > 48) {\n for (int i = 0; i < sInString.length(); i++) {\n if (i % 40 == 0) {\n if (i > 39) {\n bBreakFlag = true;\n }\n }\n if (bBreakFlag) {\n if (sInString.substring(i, i + 1).equals(\",\") || sInString.substring(i, i + 1).equals(\" \") || sInString.substring(i, i + 1).equals(\";\")) {\n sOut.append(sInString.substring(i, i + 1));\n sOut.append(\"\\n \");\n bBreakFlag = false;\n bNewLine = true;\n } else {\n \t\tsOut.append(sInString.substring(i, i + 1));\n }\n } else {\n \tif (bNewLine) {\n sOut.append(sInString.substring(i, i + 1).trim());\n bNewLine = false;\n \t} else {\n \t\tsOut.append(sInString.substring(i, i + 1));\n \t}\n }\n }\n } else {\n sOut.append(sInString);\n }\n\n } catch (Exception e) {\n\t sOut.setLength(0);\n\t sOut.append(sInString);\n\t } finally {\n\t \n\t }\n\t return sOut.toString();\n\n\n\t}",
"java.lang.String getUserEmail();",
"public static String removePeriod(String s)\r\n/* 119: */ {\r\n/* 120:115 */ s = s.trim();\r\n/* 121:116 */ char last = s.charAt(s.length() - 1);\r\n/* 122:117 */ if (\".?!\".indexOf(last) >= 0) {\r\n/* 123:118 */ return s.substring(0, s.length() - 1).trim();\r\n/* 124: */ }\r\n/* 125:120 */ return s;\r\n/* 126: */ }",
"public void setFromEmailAddress(String fromEmailAddress);",
"String getEmail(int type);",
"private static String removeInvalid(String str){\n char[] chrArr = str.toCharArray();\n int val = 0;\n for(int i = 0; i < chrArr.length; i++){\n if(chrArr[i] == '(') val ++;\n else if(chrArr[i] == ')') val --;\n if(val < 0) {\n chrArr[i] = '#';\n val = 0;\n }\n }\n val = 0;\n for(int i = chrArr.length - 1; i >= 0; i--){\n if(chrArr[i] == ')') val ++;\n else if(chrArr[i] == '(') val --;\n if(val < 0){\n chrArr[i] = '#';\n val = 0;\n }\n }\n StringBuilder sb = new StringBuilder();\n for(int i = 0; i < chrArr.length; i++){\n if(chrArr[i] != '#') sb.append(chrArr[i]);\n }\n return sb.toString();\n}",
"org.apache.xmlbeans.XmlString xgetDelegateSuggestedSignerEmail();"
] | [
"0.71944606",
"0.7008243",
"0.5915737",
"0.58055896",
"0.5694201",
"0.5625531",
"0.558738",
"0.5468601",
"0.5373758",
"0.53711367",
"0.5361129",
"0.53458303",
"0.5323401",
"0.52984107",
"0.52905875",
"0.5244989",
"0.5236576",
"0.52273935",
"0.52212495",
"0.51811284",
"0.5133246",
"0.5129822",
"0.51112694",
"0.50984013",
"0.50773233",
"0.5067068",
"0.5002918",
"0.4995136",
"0.4974401",
"0.49702466",
"0.49546954",
"0.49540365",
"0.49012524",
"0.48957896",
"0.48660386",
"0.48412138",
"0.48340842",
"0.47894013",
"0.4776903",
"0.477645",
"0.47610793",
"0.47603345",
"0.47467",
"0.47401297",
"0.47369307",
"0.4716138",
"0.46851358",
"0.4681452",
"0.46697775",
"0.46624297",
"0.465494",
"0.46517065",
"0.4617263",
"0.4617263",
"0.4617263",
"0.4617263",
"0.4617263",
"0.4617263",
"0.46122155",
"0.46078596",
"0.4592365",
"0.45844945",
"0.45830706",
"0.45766887",
"0.45738143",
"0.45626017",
"0.45594066",
"0.45542225",
"0.4546978",
"0.45427078",
"0.45390236",
"0.45367193",
"0.45343846",
"0.4532062",
"0.4518034",
"0.45105943",
"0.45047265",
"0.450065",
"0.45001847",
"0.449478",
"0.44922507",
"0.4491818",
"0.44879022",
"0.44762382",
"0.44744104",
"0.4473493",
"0.44722408",
"0.44721007",
"0.44707632",
"0.44663712",
"0.44653043",
"0.4462468",
"0.4458863",
"0.4444865",
"0.4442734",
"0.44375443",
"0.44357747",
"0.443483",
"0.4433139",
"0.44292906"
] | 0.74285036 | 0 |
Snaps the observed location to a graph edge, computes edges traveled between observations (when applicable), and returns both sets of edges. | public SnappedEdges snapToGraph(Coordinate obsCoords, Coordinate prevObsCoords) {
final Vertex snappedVertex = indexService.getClosestVertex(obsCoords, null,
options);
final List<Edge> pathTraversed = Lists.newArrayList();
final Set<Integer> snappedEdges = Sets.newHashSet();
if (snappedVertex != null && (snappedVertex instanceof StreetLocation)) {
final StreetLocation snappedStreetLocation = (StreetLocation) snappedVertex;
// final double dist = snappedVertex.distance(obsCoords);
if (prevObsCoords != null && !prevObsCoords.equals2D(obsCoords)) {
final CoordinateSequence movementSeq = JTSFactoryFinder
.getGeometryFactory().getCoordinateSequenceFactory()
.create(new Coordinate[] { prevObsCoords, obsCoords });
final Geometry movementGeometry = JTSFactoryFinder.getGeometryFactory()
.createLineString(movementSeq);
/*
* Find the edges between the two observed points.
*/
final List<Edge> minimumConnectingEdges = streetMatcher
.match(movementGeometry);
for (final Edge edge : Objects.firstNonNull(minimumConnectingEdges,
ImmutableList.<Edge> of())) {
final Integer edgeId = graph.getIdForEdge(edge);
if (edgeId != null)
snappedEdges.add(edgeId);
}
pathTraversed.addAll(minimumConnectingEdges);
} else {
/*
* Just find the edge for the isolate point
*/
for (final Edge edge : Objects.firstNonNull(
snappedStreetLocation.getOutgoingStreetEdges(),
ImmutableList.<Edge> of())) {
final Integer edgeId = graph.getIdForEdge(edge);
if (edgeId != null) {
snappedEdges.add(edgeId);
}
}
}
}
return new SnappedEdges(snappedEdges, pathTraversed);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"Set<Edge> getIncomingNeighborEdges(boolean onUpwardPass) {\n//\t\t\tif(_outgoingEdges.size() == 0) { // only compute if we have to\n\t\t\t\tSet<Edge> outgoingEdges = new HashSet<Edge>();\n\t\t\t\tIterator<Edge> it = _neighborEdges.keySet().iterator();\n\t\t\t\twhile(it.hasNext()) {\n\t\t\t\t\tEdge e = it.next();\n\t\t\t\t\tVertex v = e.getOtherVertex(this);\n\t\t\t\t\tif(this._orderID == UNMARKED) {\n\t\t\t\t\t\tSystem.err.println(\"whoops i am unmarked\");\n\t\t\t\t\t}\n\t\t\t\t\tif(v._orderID == UNMARKED) {\n\t\t\t\t\t\tSystem.err.println(\"whoops neighbor unmarked\");\n\t\t\t\t\t}\n\t\t\t\t\tif(this._orderID < v._orderID) {\n\t\t\t\t\t\toutgoingEdges.add(e);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t_outgoingEdges = outgoingEdges;\n//\t\t\t}\n//\t\t\treturn _outgoingEdges;\n\t\t\t\treturn outgoingEdges;\n\t\t}",
"E getEdge(int id);",
"Set<Edge> getDownwardOutgoingNeighborEdges() {\n\t\t\tif(_bumpOnUpwardPass) {\n\t\t\t\tSystem.err.println(\"calling downward pass neighbor method on upward pass!\");\n\t\t\t}\n//\t\t\tif(_outgoingEdges.size() == 0) { // only compute if we have to\n\t\t\t\tSet<Edge> outgoingEdges = new HashSet<Edge>();\n\t\t\t\tIterator<Edge> it = _neighborEdges.keySet().iterator();\n\t\t\t\twhile(it.hasNext()) {\n\t\t\t\t\tEdge e = it.next();\n\t\t\t\t\tVertex v = e.getOtherVertex(this);\n\t\t\t\t\tif(this._orderID == UNMARKED) {\n\t\t\t\t\t\tSystem.err.println(\"whoops i am unmarked\");\n\t\t\t\t\t}\n\t\t\t\t\tif(v._orderID == UNMARKED) {\n\t\t\t\t\t\tSystem.err.println(\"whoops neighbor unmarked\");\n\t\t\t\t\t}\n\t\t\t\t\tif(this._orderID < v._orderID) {\n\t\t\t\t\t\toutgoingEdges.add(e);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t_outgoingEdges = outgoingEdges;\n//\t\t\t}\n//\t\t\treturn _outgoingEdges;\n\t\t\t\tSystem.out.println(this.toString()+\"'s outgoing edges:\\n\"+ outgoingEdges);\n\t\t\t\treturn outgoingEdges;\n\t\t}",
"private void attachEdges(Diagram d) {\n for (EdgeData edgeData : figEdges) {\n final FigEdge edge = edgeData.getFigEdge();\n\n Object modelElement = modelElementsByFigEdge.get(edge);\n if (modelElement != null) {\n if (edge.getOwner() == null) {\n edge.setOwner(modelElement);\n }\n }\n }\n\n for (EdgeData edgeData : figEdges) {\n final FigEdge edge = edgeData.getFigEdge();\n\n Fig sourcePortFig = findFig(edgeData.getSourcePortFigId());\n Fig destPortFig = findFig(edgeData.getDestPortFigId());\n final FigNode sourceFigNode = getFigNode(edgeData\n .getSourceFigNodeId());\n final FigNode destFigNode = getFigNode(edgeData.getDestFigNodeId());\n\n if (sourceFigNode instanceof FigEdgePort) {\n sourcePortFig = sourceFigNode;\n }\n\n if (destFigNode instanceof FigEdgePort) {\n destPortFig = destFigNode;\n }\n\n if (sourcePortFig == null && sourceFigNode != null) {\n sourcePortFig = getPortFig(sourceFigNode);\n }\n\n if (destPortFig == null && destFigNode != null) {\n destPortFig = getPortFig(destFigNode);\n }\n\n if (sourcePortFig == null || destPortFig == null\n || sourceFigNode == null || destFigNode == null) {\n LOG.log(Level.SEVERE,\n \"Can't find nodes for FigEdge: \" + edge.getId() + \":\"\n + edge.toString());\n edge.removeFromDiagram();\n } else {\n edge.setSourcePortFig(sourcePortFig);\n edge.setDestPortFig(destPortFig);\n edge.setSourceFigNode(sourceFigNode);\n edge.setDestFigNode(destFigNode);\n }\n }\n\n // Once all edges are connected do a compute route on each to make\n // sure that annotations and the edge port is positioned correctly\n // Only do this after all edges are connected as compute route\n // requires all edges to be connected to nodes.\n // TODO: It would be nice not to have to do this and restore annotation\n // positions instead.\n for (Object edge : d.getLayer().getContentsEdgesOnly()) {\n FigEdge figEdge = (FigEdge) edge;\n figEdge.computeRouteImpl();\n }\n }",
"private List<Graph.Edge> getEdge(PathMap map) {\n // record the visited coordinates\n List<Coordinate> visited = new ArrayList<>();\n // get all coordinates from the map\n List<Coordinate> allCoordinates = map.getCoordinates();\n // for record all generated edges\n List<Graph.Edge> edges = new ArrayList<>();\n\n\n while (visited.size() <= allCoordinates.size() - 1) {\n for (Coordinate temp : allCoordinates) {\n\n if (visited.contains(temp)) {\n continue;\n }\n visited.add(temp);\n List<Coordinate> neighbors = map.neighbours(temp);\n for (Coordinate tempNeighbour : neighbors) {\n edges.add(new Graph.Edge(temp, tempNeighbour, tempNeighbour.getTerrainCost()));\n }\n }\n }\n // trim impassable coordinates\n List<Graph.Edge> fEdges = new ArrayList<>();\n for (Graph.Edge dd : edges) {\n if (dd.startNode.getImpassable() || dd.endNode.getImpassable()) {\n continue;\n }\n fEdges.add(dd);\n }\n return fEdges;\n }",
"Edge getEdge();",
"@Override\n\tpublic List<Path> getOutEdges(Location src) {\n\t\treturn \tpaths.get(locations.indexOf(src));\n\t}",
"void setupEdge(EdgeGraph edge) {\n\n\t\tif (UserParameters.socialInteraction) updateCrowdness(edge);\n\t\tcurrentEdge = edge;\n\t\t//transform GeomPlanarGraphEdge in Linestring\n\t\tLineString line = edge.getLine();\n\t\t//index the Linestring\n\t\tsegment = new LengthIndexedLine(line);\n\t\tstartIndex = segment.getStartIndex();\n\t\tendIndex = segment.getEndIndex();\n\t\tlinkDirection = 1;\n\n\t\t// check to ensure that Agent is moving in the right direction (direction)\n\t\tdouble distanceToStart = line.getStartPoint().distance(agentLocation.geometry);\n\t\tdouble distanceToEnd = line.getEndPoint().distance(agentLocation.geometry);\n\n\t\tif (distanceToStart <= distanceToEnd) {\n\t\t\t// closer to start\n\t\t\tcurrentIndex = startIndex;\n\t\t\tlinkDirection = 1;\n\t\t}\n\t\telse if (distanceToEnd < distanceToStart) {\n\t\t\t// closer to end\n\t\t\tcurrentIndex = endIndex;\n\t\t\tlinkDirection = -1;\n\t\t}\n\n\t}",
"Set<Edge> getUpwardOutgoingNeighborEdges() {\n\t\t\tif(!_bumpOnUpwardPass) {\n\t\t\t\tSystem.err.println(\"calling upward pass neighbor method on downward pass!\");\n\t\t\t}\n//\t\t\tif(_outgoingEdges.size() == 0) { // only compute if we have to\n\t\t\t\tSet<Edge> outgoingEdges = new HashSet<Edge>();\n\t\t\t\tIterator<Edge> it = _neighborEdges.keySet().iterator();\n\t\t\t\twhile(it.hasNext()) {\n\t\t\t\t\tEdge e = it.next();\n\t\t\t\t\tVertex v = e.getOtherVertex(this);\n\t\t\t\t\tif(this._orderID == UNMARKED) {\n\t\t\t\t\t\tSystem.err.println(\"whoops i am unmarked\");\n\t\t\t\t\t}\n\t\t\t\t\tif(v._orderID == UNMARKED) {\n\t\t\t\t\t\tSystem.err.println(\"whoops neighbor unmarked\");\n\t\t\t\t\t}\n\t\t\t\t\tif(this._orderID > v._orderID) {\n\t\t\t\t\t\toutgoingEdges.add(e);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t_outgoingEdges = outgoingEdges;\n//\t\t\t}\n//\t\t\treturn outgoingEdges;\n\t\t\t\tSystem.out.println(this.toString()+\"'s outgoing edges:\\n\"+ outgoingEdges);\n\t\t\t\treturn outgoingEdges;\n\t\t}",
"public Edge<E, V> getUnderlyingEdge();",
"public List<MoveEdge> getEdgeNeighborhood(final LabeledUndirectedGraph<N, E> sk) {\n final List<MoveEdge> neighborood = new ArrayList<>();\n final LabeledUndirectedGraph<N, E> csk = new LabeledUndirectedGraph<>(sk);\n // For each spanning edges...\n csk.getEdges().forEach(edge -> {\n csk.removeEdge(edge);\n final List<Set<N>> nodes = new ArrayList<>(csk.getSubGraphsNodes());\n if (nodes.size() == 2) {\n final Set<E> candidates = new HashSet<>();\n csk.getRemovedEdges().stream()\n .filter(redge -> (!redge.equals(edge))\n && ((nodes.get(0).contains(redge.getNode1()) && nodes.get(1).contains(redge.getNode2()))\n || (nodes.get(0).contains(redge.getNode2()) && nodes.get(1).contains(redge.getNode1()))))\n .forEachOrdered(redge -> candidates.add(redge));\n candidates.forEach(candidate -> neighborood.add(new MoveEdge(edge, candidate, sk)));\n }\n csk.addEdge(edge);\n });\n return neighborood;\n }",
"public Set<E> getEdges();",
"private Collection<Edge> getEdges()\r\n\t{\r\n\t return eSet;\r\n\t}",
"public Edge<V> getEdge(V source, V target);",
"public void createEdges() {\n \tfor(String key : ways.keySet()) {\n \t Way way = ways.get(key);\n \t if(way.canDrive()) {\n \t\tArrayList<String> refs = way.getRefs();\n \t\t\t\n \t\tif(refs.size() > 0) {\n \t\t GPSNode prev = (GPSNode) this.getNode(refs.get(0));\n \t\t drivableNodes.add(prev);\n \t\t \n \t\t GPSNode curr = null;\n \t\t for(int i = 1; i <refs.size(); i++) {\n \t\t\tcurr = (GPSNode) this.getNode(refs.get(i));\n \t\t\tif(curr == null || prev == null)\n \t\t\t continue;\n \t\t\telse {\n \t\t\t double distance = calcDistance(curr.getLatitude(), curr.getLongitude(),\n \t\t\t\t prev.getLatitude(), prev.getLongitude());\n\n \t\t\t GraphEdge edge = new GraphEdge(prev, curr, distance, way.id);\n \t\t\t prev.addEdge(edge);\n \t\t\t curr.addEdge(edge);\n \t\t\t \n \t\t\t drivableNodes.add(curr);\n \t\t\t prev = curr;\n \t\t\t}\n \t\t }\t\n \t\t}\n \t }\n \t}\n }",
"public Collection<LazyRelationship2> getEdges() {\n long relCount=0;\n ArrayList l = new ArrayList();\n \n for(Path e : getActiveTraverser()){\n for(Path p : getFlushTraverser(e.endNode())){\n if((relCount++%NEO_CACHE_LIMIT)==0){\n l.add(p.lastRelationship());\n clearNeoCache();\n }\n }\n }\n return l; \n }",
"public abstract boolean getEdge(Point a, Point b);",
"private Edge getKernelEdge(Edge edge){\n\t\tif (edge.getGraph() != null && (edge.getGraph().isLhs() || edge.getGraph().isRhs())) {\n\t\t\tRule rule = edge.getGraph().getRule();\n\t\t\treturn rule.getMultiMappings().getOrigin(edge);\n\t\t}\n\t\treturn null;\n\t}",
"Collection<E> edges();",
"public E getEdge(N startNode, N endNode)\r\n/* 90: */ {\r\n/* 91:166 */ assert (checkRep());\r\n/* 92:167 */ if ((contains(startNode)) && (((Map)this.map.get(startNode)).containsKey(endNode))) {\r\n/* 93:168 */ return ((Map)this.map.get(startNode)).get(endNode);\r\n/* 94: */ }\r\n/* 95:170 */ return null;\r\n/* 96: */ }",
"public Edge[] getEdges()\r\n {\r\n if(edges == null)\r\n\t{\r\n\t edges = new Edge[numEdges()];\r\n\t int i = 0;\r\n\t for (final EdgeTypeHolder eth : ethMap.values())\r\n\t\tfor (final Edge e : eth.getEdges())\r\n\t\t edges[i++] = e;\r\n\t}\r\n return edges.clone();\r\n }",
"public DSALinkedList<DSAGraphEdge<E>> getAdjacentEdges()\n {\n return edgeList;\n }",
"default Iterator<E> edgeIterator() {\n return getEdges().iterator();\n }",
"protected Edge getEdge() {\r\n\t\treturn (Edge)getModel();\r\n\t}",
"private void buildEdgeFigure(IFigure contents, Edge edge) {\n\t\tPolylineConnection connx = new PolylineConnection();\n\t\tPointList points = edge.getPoints();\n\t\tXYAnchor sourceAnchor = new XYAnchor(points.getFirstPoint());\n\t\tXYAnchor targetAnchor = new XYAnchor(points.getLastPoint());\n\t\tconnx.setSourceAnchor(sourceAnchor);\n\t\tconnx.setTargetAnchor(targetAnchor);\n\t\tcontents.add(connx);\n\t}",
"public double getEdge()\n {\n return this.edge;\n }",
"public Set<E> getEdges(V tail);",
"private SumoEdge getEdge(String id) {\n\t\treturn idToEdge.get(id);\n\t}",
"private void popluateEdgePortService() {\n Set<ConnectPoint> edgeConnectPoints = new HashSet<>();\n\n for (int i = 1; i <= NUM_DEVICES; i++) {\n for (int j = 1; j <= NUM_PORTS_PER_DEVICE; j++) {\n ConnectPoint edgeConnectPoint = new ConnectPoint(\n getDeviceId(i),\n PortNumber.portNumber(1));\n ConnectPoint noEdgeConnectPointOne = new ConnectPoint(\n getDeviceId(i),\n PortNumber.portNumber(2));\n ConnectPoint noEdgeConnectPointTwo = new ConnectPoint(\n getDeviceId(i),\n PortNumber.portNumber(3));\n\n edgeConnectPoints.add(edgeConnectPoint);\n\n expect(edgePortService.isEdgePoint(edgeConnectPoint))\n .andReturn(true).anyTimes();\n expect(edgePortService.isEdgePoint(noEdgeConnectPointOne))\n .andReturn(false).anyTimes();\n expect(edgePortService.isEdgePoint(noEdgeConnectPointTwo))\n .andReturn(false).anyTimes();\n }\n }\n expect(edgePortService.getEdgePoints())\n .andReturn(edgeConnectPoints).anyTimes();\n\n replay(edgePortService);\n }",
"public abstract boolean putEdge(Edge incomingEdge);",
"ArrayList<Edge> getAdjacencies();",
"public Collection< EDataT > edgeData();",
"public Set<Eventable> getAllEdges() {\n\t\treturn sfg.edgeSet();\n\t}",
"protected void processEdge(Edge e) {\n\t}",
"public Iterable<Edge> edges() {\r\n\t\treturn mst;\r\n\t}",
"public static GraphEdge createGraphEdgeForEdge() {\n GraphEdge graphEdge = new GraphEdge();\n\n for (int i = 0; i < 2; i++) {\n GraphNode childNode = new GraphNode();\n childNode.setPosition(AccuracyTestHelper.createPoint(20 * i, 10));\n childNode.setSize(AccuracyTestHelper.createDimension(40, 12));\n graphEdge.addContained(childNode);\n }\n graphEdge.addWaypoint(AccuracyTestHelper.createDiagramInterchangePoint(100, 100));\n graphEdge.addWaypoint(AccuracyTestHelper.createDiagramInterchangePoint(250, 200));\n\n // create a Relationship\n Relationship relationship = new IncludeImpl();\n\n // set stereotype\n Stereotype stereotype = new StereotypeImpl();\n\n // create a semantic model\n Uml1SemanticModelBridge semanticModel = new Uml1SemanticModelBridge();\n semanticModel.setElement(relationship);\n\n graphEdge.setSemanticModel(semanticModel);\n\n return graphEdge;\n }",
"void addNeighborEdge(Edge e) {\n\t\t\t_neighborEdges.put(e,false);\n\t\t}",
"public Edge[] getEdges() {\n\t\treturn edges;\n\t}",
"public DEdge[] getEdges(){\n return listOfEdges;\n }",
"private RoutingEdge extractRoutingEdgeFromRS(ResultSet resultSet) {\n\n\t\tRoutingEdge routingEdge = new RoutingEdge();\n\n\t\ttry {\n\n\t\t\troutingEdge.setId(resultSet.getInt(\"id\"));\n\t\t\t\n\t\t\troutingEdge.setFloorID(resultSet.getInt(\"FloorId\"));\n\t\t\troutingEdge.setSource(resultSet.getInt(\"Source\"));\n\t\t\troutingEdge.setTarget(resultSet.getInt(\"Target\"));\n\t\t\troutingEdge.setWeight(resultSet.getInt(\"Weight\"));\n\t\t\t\n\t\t} catch (SQLException e) {\n\t\t\te.printStackTrace();\n\t\t}\n\n\t\treturn routingEdge;\n\t}",
"@Override\n public List<Edge<Stop>> getEdgesFromNode(long time, Stop node, Set<Stop> found) {\n List<Edge<Stop>> walkingEdges = getWalkingEdgesFromStop(time, node, found);\n List<Edge<Stop>> publicTransportEdges = getPublicTransportEdgesFromStop(time, node, found);\n\n List<Edge<Stop>> edges = new TiraArrayList<>(walkingEdges.size() + publicTransportEdges.size());\n edges.addAll(walkingEdges);\n edges.addAll(publicTransportEdges);\n\n return edges;\n }",
"public abstract ArrayList<Pair<Vector2, Vector2>> getEdges();",
"List<IEdge> getAllEdges();",
"public List<IEdge> getAllEdges();",
"public void testContainsEdgeEdge( ) {\n init( );\n\n //TODO Implement containsEdge().\n }",
"public Iterable<Edge> edges() {\r\n Bag<Edge> list = new Bag<Edge>();\r\n for (int v = 0; v < V; v++) {\r\n for (Edge e : adj(v)) {\r\n list.add(e);\r\n }\r\n }\r\n return list;\r\n }",
"public interface Edge\n{\n\t/**\n\t * Returns the node that the <i>head</i> of the head\n\t * is connected to.\n\t * @return The head Node.\n\t */\n\tpublic Node getHeadNode();\n\n\t/**\n\t * Returns the node that the <i>tail</i> of the edge\n\t * is connected to.\n\t * @return The tail Node.\n\t */\n\tpublic Node getTailNode();\n\n\t/**\n\t * Allows an object to be associated with the <code>Edge</code>\n\t * @param o The object to be set as the userObject\n\t */\n\tpublic void setUserObject(Object o);\n\n\t/**\n\t * Gets the userObject, previously set with <code>setUserObject(Object o)</code>\n\t * @return The userObject, or <code>null</code> if no object has been set.\n\t */\n\tpublic Object getUserObject();\n\n\t/**\n\t * Causes any information in the path that represents the <code>Egde</code>\n\t * to be cleared, such as origin location and any control points.\n\t */\n\tpublic void resetPath();\n\n\t/**\n\t * Sets the location of the start of the path that represents\n\t * the <code>Edge</code>.\n\t * @param x The horizontal location.\n\t * @param y The vertical location.\n\t */\n\tpublic void setPathOrigin(int x, int y);\n\n\t/**\n\t * Extends the <code>Edge</code> using the following control points to\n\t * form a Bezier curve extension to the end point (x3, y3).\n\t * @param x1 Horizontal location of control point 1\n\t * @param y1 Vertical location of control point 1\n\t * @param x2 Horizontal location of control point 2\n\t * @param y2 Vertical location of control point 2\n\t * @param x3 Horizontal location of the end point.\n\t * @param y3 Vertical location of the end point.\n\t */\n\tpublic void pathTo(int x1, int y1, int x2, int y2, int x3, int y3);\n\n\t/**\n\t * Extends the <code>Edge</code> to the specified location using\n\t * a straight line.\n\t * @param x The horizontal location of the end point.\n\t * @param y The vertical location of the end point.\n\t */\n\tpublic void pathTo(int x, int y);\n\n\t/**\n\t * Sets the <code>Edge's</code> arrowhead.\n\t * @param baseX The x location of the centre of the arrowhead baseline.\n\t * @param baseY The y location of the centre of the arrowhead tip.\n\t * @param tipX The x location of the tip of the arrowhead.\n\t * @param tipY The y location of the tip of the arrowhead.\n\t */\n\tpublic void setArrowHead(int baseX, int baseY, int tipX, int tipY);\n\n\t/**\n\t * Sets the <code>Edge's</code> arrowtail\n\t * @param baseX The x location of the centre of the arrowhead baseline.\n\t * @param baseY The y location of the centre of the arrowhead tip.\n\t * @param tipX The x location of the tip of the arrowhead.\n\t * @param tipY The y location of the tip of the arrowhead.\n\t */\n\tpublic void setArrowTail(int baseX, int baseY, int tipX, int tipY);\n\n\t/**\n\t * Sets the <code>Edge</code>'s label position.\n\t * @param x The horizontal location (in pixels).\n\t * @param y The vertical location (in pixels).\n\t */\n\tpublic void setLabelPosition(int x, int y);\n\n\t/**\n\t * Retrieves the position of the <code>Edge's</code> label.\n\t * @return A <code>Point</code> containing the position of\n\t * the label.\n\t */\n\tpublic Point getLabelPosition();\n\n\t/**\n\t * Gets the <code>Shape</code> that represents the <code>Edge</code>.\n\t * @return The <code>Shape</code> of the <code>Edge</code>.\n\t */\n\tpublic Shape getShape();\n\n\t/**\n\t * Gets the direction of the <code>Edge</code>. This is one of the\n\t * predefined direction from the <code>GraphModel</code> interface.\n\t * @return The direction of the <code>Edge</code>.\n\t */\n\tpublic int getDirection();\n\n\n}",
"public void edgeTailChanged(GraphEvent e);",
"public Set<E> getEdges(V tail, V head);",
"public abstract void map(Edge queryEdge, Edge graphEdge);",
"public HashMap<String, Edge> getEdgeList () {return edgeList;}",
"public Collection getAccessPathEdgeTargets() {\n if (accessPathEdges == null) return Collections.EMPTY_SET;\n return new FlattenedCollection(accessPathEdges.values());\n }",
"Map<Node, Edge> getOutEdges() {\n return outEdges;\n }",
"@Override\n public Collection<edge_data> getE(int node_id) {\n return ((NodeData) this.nodes.get(node_id)).getNeighborEdges().values();\n }",
"Set<CyEdge> getExternalEdgeList();",
"private void findEdges(){\n int pixel,x,y;\n int color;\n double gx,gy,magnitude;\n double magnitudes[][] = new double[size-2][size-2];\n double angles[][] = new double[size-2][size-2];\n int directions[][] = new int[size-2][size-2];\n //give numbers to the edge kernel\n int edgeKernelX[][] = new int[][]{{-1, 0, 1},\n {-2, 0, 2},\n {-1, 0, 1}};\n int edgeKernelY[][] = new int[][]{{-1, -2, -1},\n { 0, 0, 0},\n { 1, 2, 1}};\n //march the image\n for (int i = 1; i < size-1; i++) {\n for (int j = 1; j < size-1; j++) {\n //reset color\n gx = gy = 0;\n //march pixels inside kernel\n for (int k = 0; k < 3; k++) {\n for (int l = 0; l < 3; l++) {\n //get gray color from pixel\n x = j + l - 1; \n y = i + k - 1;\n pixel = imageKerneled.getRGB(x,y);\n //multiply the rgb by the number in kernel\n color = ((pixel) & 0xff);\n gx += color * edgeKernelX[k][l];\n gy += color * edgeKernelY[k][l];\n }\n }\n //get magnitude for the edge ( Gxy = sqrt(x^2+y^2) )\n magnitude = (int)Math.round(Math.sqrt((gx*gx)+(gy*gy) ) );\n magnitudes[i-1][j-1] = magnitude;\n //get angle for the edge ( A = arctan Gy/Gx )\n angles[i-1][j-1] = Math.atan(gy/gx);\n }\n }\n //get bigger magnitud for rule of 3 because are magnitudes above 255\n double bigger = magnitudes[0][0]; int sizeMinus2 = size-2;\n for (int i = 0; i < sizeMinus2; i++) {\n for (int j = 0; j < sizeMinus2; j++) {\n if(magnitudes[i][j] > bigger) bigger = magnitudes[i][j];\n }\n }\n //rule of 3 to make all magnitudes below 255\n for (int i = 0; i < sizeMinus2; i++) {\n for (int j = 0; j < sizeMinus2; j++) {\n magnitudes[i][j] = magnitudes[i][j] * 255 / bigger;\n }\n }\n //set the borders black because there are no magnitudes there\n for (int i = 0; i < size; i++) {imageKerneled2.setRGB(0,i,Color.BLACK.getRGB());}\n for (int i = 0; i < size; i++) {imageKerneled2.setRGB(size-1,i,Color.BLACK.getRGB());}\n for (int i = 0; i < size; i++) {imageKerneled2.setRGB(i,0,Color.BLACK.getRGB());}\n for (int i = 0; i < size; i++) {imageKerneled2.setRGB(i,size-1,Color.BLACK.getRGB());}\n //set the magnitudes in the image\n double degrees;\n double max=0,min=0;\n for (int i = 0; i < sizeMinus2; i++) {\n for (int j = 0; j < sizeMinus2; j++) {\n //paint black the NaN and 0r angles\n magnitude = magnitudes[i][j];\n if(Double.isNaN(angles[i][j]) || angles[i][j]==0){\n imageKerneled2.setRGB(j+1,i+1,Color.BLACK.getRGB());\n }\n else{\n //convert radians to dregrees for HSB (Hue goes from 0 to 360)\n degrees = Math.toDegrees(angles[i][j]); \n //convert degrees in scale from -90,90 to 0,360 for HSBtoRGB with a rule of 3\n degrees = degrees * 360 / 90; \n //convert degrees in scale from 0,360 to 0,1 for HSBtoRGB with a rule of 3\n degrees /= 360;\n /*if want angles with colors: \n //convert magnitud in scale from 0,255 to 0,1 for HSBtoRGB with a rule of 3\n magnitude /= 255;\n Color c = new Color(Color.HSBtoRGB((float)degrees,1.0f,(float)magnitude));*/\n Color c = new Color((int)magnitude,(int)magnitude,(int)magnitude);\n imageKerneled2.setRGB(j+1,i+1,c.getRGB());\n /*set direction for pixel\n east-west: 0 = 0 - 22, 158-202, 338-360\n northeast-southwest: 1 = 23 - 67, 203-247 \n north-south: 2 = 68 -112, 248-292 \n northeast-southeast: 3 = 113-157, 293-337 */\n if((degrees>=0 && degrees<=22) || (degrees>=158 && degrees<=202) || (degrees>=338 && degrees<=360)){\n directions[i][j] = 0;\n }else if((degrees>=23 && degrees<=67) || (degrees>=203 && degrees<=247)){\n directions[i][j] = 1;\n }else if((degrees>=68 && degrees<=112) || (degrees>=248 && degrees<=292)){\n directions[i][j] = 2;\n }else if((degrees>=113 && degrees<=157) || (degrees>=293 && degrees<=337)){\n directions[i][j] = 3;\n }\n }\n }\n }\n copyKerneled2ToKerneled();\n System.out.println(\"Finished sobel edge detector\");\n //here starts the canny edge detector\n int comparedMagnitudes[] = new int [3];\n for (int i = 1; i < size-1; i++) {\n for (int j = 1; j < size-1; j++) {\n //get magnitude of current pixel and neighbors from direction\n comparedMagnitudes[0] = (imageKerneled.getRGB(j,i)) & 0xff;\n switch(directions[i-1][j-1]){\n case 0: \n comparedMagnitudes[1] = (imageKerneled.getRGB(j-1,i)) & 0xff;\n comparedMagnitudes[2] = (imageKerneled.getRGB(j+1,i)) & 0xff;\n break;\n case 1:\n comparedMagnitudes[1] = (imageKerneled.getRGB(j+1,i+1)) & 0xff;\n comparedMagnitudes[2] = (imageKerneled.getRGB(j-1,i-1)) & 0xff;\n break;\n case 2:\n comparedMagnitudes[1] = (imageKerneled.getRGB(j,i-1)) & 0xff;\n comparedMagnitudes[2] = (imageKerneled.getRGB(j,i+1)) & 0xff;\n break;\n case 3:\n comparedMagnitudes[1] = (imageKerneled.getRGB(j-1,i+1)) & 0xff;\n comparedMagnitudes[2] = (imageKerneled.getRGB(j+1,i-1)) & 0xff;\n break;\n }\n if(comparedMagnitudes[0]<comparedMagnitudes[1] \n || comparedMagnitudes[0]<comparedMagnitudes[2]\n || comparedMagnitudes[0]<30){\n imageKerneled2.setRGB(j,i,Color.BLACK.getRGB());\n }\n }\n }\n /*for (int i = 1; i < size-1; i++) {\n for (int j = 1; j < size-1; j++) {\n color = (imageKerneled2.getRGB(j,i)) & 0xff;\n if(color > 0){\n imageKerneled2.setRGB(j,i,Color.WHITE.getRGB());\n }\n }\n }*/\n copyKerneled2ToKerneled();\n System.out.println(\"Finished canny edge detector\");\n }",
"void buildRoad(EdgeLocation edge, boolean free);",
"@Override\n\tpublic Path getEdgeIfExists(Location src, Location dest) {\n\t\tfor (Path p : paths.get(locations.indexOf(src))) \n\t\t\tif (p.getDestination().equals(dest))\n\t\t\t\treturn p;\n\n\t\treturn null;\n\n\t}",
"Map<Node, Edge> getInEdges() {\n return inEdges;\n }",
"public Iterator<Edge> getEdgeIter() {\n\t\treturn edges.iterator();\n\t}",
"@Override\n\tpublic edge_data getEdge(int src, int dest) {\n\t\tif(Nodes.containsKey(src) && Nodes.containsKey(dest) && Edges.get(src).containsKey(dest)) {\n\t\t\treturn Edges.get(src).get(dest);\n\t\t}\n\t\treturn null;\n\t}",
"public Iterable<DirectedEdge> edges() {\n ArrayList<DirectedEdge> list = new ArrayList<DirectedEdge>();\n for (int v = 0; v < V; v++) {\n for (DirectedEdge e : adj(v)) {\n list.add(e);\n }\n }\n return list;\n }",
"public static int[][] getEdgeMatrix() {\n\t\treturn edge;\n\t}",
"public HashMap<Integer, edge_data> getNeighborEdges() {\n return this.neighborEdges;\n }",
"@Override\n public Collection<? extends IEdge> getEdges() {\n\n return new LinkedList<>(Collections.unmodifiableCollection(this.edgeMap\n .values()));\n }",
"public void drawEdges(IEdgeDrawerGraph graph);",
"public Iterator<LayoutEdge> edgeIterator() {\n\treturn edgeList.iterator();\n }",
"public edge_data getEdge(int nodeKey) {\n return this.neighborEdges.get(nodeKey);\n }",
"public static EdgesHelper getEdgesHelper() {\n return edgesHelper;\n }",
"public Collection getNonEscapingEdgeTargets() {\n if (addedEdges == null) return Collections.EMPTY_SET;\n return new FlattenedCollection(addedEdges.values());\n }",
"@Override\r\n\tpublic PointInterface[] edgeEndPoints() {\n\t\treturn p;\r\n\t}",
"private void splitEdgeDetection() {\n\t\tif(!currentlyDetecting)\n {\n detectRisingEdge();\n }else{//if currentlyDetecting is true, then we are looking for a falling edge\n detectFallingEdge();\n }\n\t}",
"private mxCell getEdge(Microtuble m){\n\t\tmxCell edge = null;\n\t\tfor (mxCell cell : graph.getEdgeToCellMap().values()){\n\t\t\tMicrotuble mt = (Microtuble) cell.getValue();\n\t\t\tif (mt.equals(m)){\n\t\t\t\tedge = cell;\n\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\t\treturn edge;\n\t}",
"public List<Edge> findAllEdge() throws SQLException {\n\t\treturn rDb.findAllEdges();\n\t}",
"@Override\n\tpublic List<Edge> getAllMapEdges() {\n\n\t\tList<Edge> res = new ArrayList<Edge>();\n\t\tResultSet resultSet = null;\n\n\t\ttry {\n\t\t\tString getAllEdges = \"SELECT node_from, node_to, distance FROM routefinder.maprelations\";\n\t\t\tresultSet = null;\n\t\t\tpstmt = conn.prepareStatement(getAllEdges);\n\t\t\tresultSet = pstmt.executeQuery();\n\t\t\twhile (resultSet.next()) {\n\t\t\t\tEdge edge = new Edge();\n\t\t\t\tedge.setNode1(Database.getNodeFromId(resultSet.getInt(\"node_from\")));\n\t\t\t\tedge.setNode2(Database.getNodeFromId(resultSet.getInt(\"node_to\")));\n\t\t\t\tedge.setDist(resultSet.getDouble(\"distance\"));\n\t\t\t\tres.add(edge);\n\t\t\t}\n\t\t\treturn res;\n\n\t\t} catch (SQLException e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t} finally {\n\t\t\tJdbcConnect.resultClose(resultSet, pstmt);\n\t\t}\n\n\t\treturn null;\n\t}",
"public void addEdge(){\n Node[] newAdjacent = new Node[adjacent.length + 1];\n for (int i = 0; i < adjacent.length; i++) {\n newAdjacent[i] = adjacent[i];\n }\n adjacent = newAdjacent;\n }",
"public interface GraphEdge extends org.omg.uml.diagraminterchange.GraphElement {\n /**\n * Returns the value of attribute waypoints.\n * @return Value of waypoints attribute.\n */\n public java.util.List getWaypoints();\n /**\n * Returns the value of reference anchor.\n * @return Value of reference anchor.\n */\n public java.util.List getAnchor();\n}",
"public static ArrayList<Edge> getAllEdges(){\n\t\treturn edgeList;\n\t}",
"EdgeIteratorState copyPropertiesFrom(EdgeIteratorState e);",
"public Enumeration directedEdges();",
"public Map<String, String> getEdge() {\n\t\tif (edge == null) {\n\t\t\tsetEdge(new HashMap<String, String>());\n\t\t}\n\t\treturn edge;\n\t}",
"public ExtendedListIterable<Edge> edges(Node node, Direction direction) {\n return inspectableGraph.edges(node, Direction.EITHER);\n }",
"public void fillEdges() {\n\t\tfor (int y = 0; y < mapSize; y++) {\n\t\t\tfor (int x = 0; x < mapSize; x++) {\n\t\t\t\tCoordinates coordinates = new Coordinates(x, y);\n\t\t\t\tint vertexSrc = coordinateToVertex(coordinates);\n\n\t\t\t\tif (deletedVertices.contains(vertexSrc)) {\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\n\t\t\t\tDirection[] directions = Direction.values();\n\n\t\t\t\tfor (Direction direction : directions) {\n\t\t\t\t\tCoordinates destCoordinates = new Coordinates(x, y);\n\n\t\t\t\t\tdestCoordinates = destCoordinates.addCoordinates(direction.coordinates());\n\n\t\t\t\t\tif (destCoordinates.areCorrect(mapSize)) {\n\t\t\t\t\t\tint vertexDest = coordinateToVertex(destCoordinates);\n\t\t\t\t\t\tif (!deletedVertices.contains(vertexDest)) {\n\t\t\t\t\t\t\taddEdge(vertexSrc, vertexDest);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}",
"private ArrayList<Edge>getFullyConnectedGraph(){\n\t\tArrayList<Edge> edges = new ArrayList<>();\n\t\tfor(int i=0;i<nodes.size();i++){\n\t\t\tfor(int j=i+1;j<nodes.size();j++){\n\t\t\t\tEdge edge = new Edge(nodes.get(i), nodes.get(j),Utils.distance(nodes.get(i), nodes.get(j)));\n\t\t\t\tedges.add(edge);\n\t\t\t}\n\t\t}\n\t\treturn edges;\n\t}",
"public Vector<Edge> getEdges(){\n\t\treturn this.listOfEdges;\n\t}",
"@Override\n\tpublic Set<ET> getAdjacentEdges(N node)\n\t{\n\t\t// implicitly returns null if gn is not in the nodeEdgeMap\n\t\tSet<ET> adjacentEdges = nodeEdgeMap.get(node);\n\t\treturn adjacentEdges == null ? null : new HashSet<ET>(adjacentEdges);\n\t}",
"void addEdges(Collection<ExpLineageEdge> edges);",
"@Override\n\tpublic List<Edge> getAllEdges() {\n\n\t\tList<Edge> res = new ArrayList<Edge>();\n\t\tResultSet resultSet = null;\n\n\t\ttry {\n\t\t\tString getAllEdges = \"SELECT node_from, node_to, distance FROM routefinder.relations\";\n\t\t\tresultSet = null;\n\t\t\tpstmt = conn.prepareStatement(getAllEdges);\n\t\t\tresultSet = pstmt.executeQuery();\n\t\t\twhile (resultSet.next()) {\n\t\t\t\tEdge edge = new Edge();\n\t\t\t\tedge.setNode1(Database.getNodeFromId(resultSet.getInt(\"node_from\")));\n\t\t\t\tedge.setNode2(Database.getNodeFromId(resultSet.getInt(\"node_to\")));\n\t\t\t\tedge.setDist(resultSet.getDouble(\"distance\"));\n\t\t\t\tres.add(edge);\n\t\t\t}\n\n\t\t\treturn res;\n\n\t\t} catch (SQLException e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t} finally {\n\t\t\tJdbcConnect.resultClose(resultSet, pstmt);\n\t\t}\n\n\t\treturn null;\n\t}",
"private void createEdges() {\n int edgeSize = windowSize - 1;\n BufferedImage edgedImage = new BufferedImage(image.getWidth() + edgeSize, image.getHeight() + edgeSize, BufferedImage.TYPE_INT_ARGB);\n int[] edgeData = ((DataBufferInt) edgedImage.getRaster().getDataBuffer()).getData();\n\n // set every pixels in edged image to -1 to use for checking unassigned pixels when filling edges\n for (int i = 0; i < edgeData.length; i++) {\n edgeData[i] = -1;\n }\n\n // draw original image onto center of edged image\n edgedImage.getGraphics().drawImage(image, edgeSize/2, edgeSize/2, null);\n edgedImage.getGraphics().dispose();\n\n\n //TODO - get this working after program works to improve speed\n// byte[] edgedData = ((DataBufferByte) edgedImage.getRaster().getDataBuffer()).getData();\n// byte[] originalData = ((DataBufferByte) image.getRaster().getDataBuffer()).getData();\n//\n // copy image into larger, edged image. currently not working,\n// for (int i = windowSize / 2 * 3, originalI = 0; i < image.getHeight() - windowSize / 2; i++, originalI++) {\n// for (int j = windowSize / 2 * 3, originalJ = 0; j < image.getWidth() - windowSize / 2; j++, originalJ++) {\n// edgedData[i + j * edgedImage.getWidth()] = originalData[originalI + originalJ * image.getWidth()];\n// }\n// }\n\n image = edgedImage;\n fillEdges();\n }",
"String getEdges();",
"@Override\n\tpublic void addEdge(Location src, Location dest, Path edge) {\n\t\tint i = locations.indexOf(src);\n\t\tpaths.get(locations.indexOf(src)).add(edge);\n\t}",
"InternalRoad getOutEgde(){\r\n\t\tSet out = this.getOutEdges();\r\n\t\tIterator iter = out.iterator();\r\n\t\treturn (InternalRoad)iter.next();\r\n\t}",
"@Override\r\n public Collection<edge_data> getE(int node_id) {\r\n return this.neighbors.get(node_id).values(); //o(k)\r\n }",
"private static void addAllEdgeInstances (Graph graph, boolean isDirected){\n Collection<Node> noteSet = graph.getNodeSet();\n\n for (Iterator<Node> iterator = noteSet.iterator(); iterator.hasNext();) {\n Node startNode = (Node) iterator.next();\n\n for (Iterator<Node> iterator2 = noteSet.iterator(); iterator2.hasNext();) {\n Node endNode = (Node) iterator2.next();\n\n if (!(startNode == endNode)){\n graph.addEdge(startNode.toString().concat(endNode.toString()), startNode, endNode, isDirected);\n }\n\n }\n }\n }",
"public ArrayList<DrawableGraphEdge> getEdges() {\r\n\t\treturn new ArrayList<DrawableGraphEdge>(edges);\r\n\t}",
"public Set<Edge<V>> edgeSet();",
"public Collection<Edge> edges() {\n Collection<Collection<Edge>> copyOfEdges = new ArrayList<Collection<Edge>>();\n //values = myGraph.values(); OLD\n //create a copy of all the edges in the map to restrict any reference\n //to interals of this class\n copyOfEdges.addAll(myGraph.values());\n Collection<Edge> allValues = new ArrayList<Edge>();\n Iterator<Collection<Edge>> eachColl = copyOfEdges.iterator();\n while(eachColl.hasNext()){\n allValues.addAll(eachColl.next());\n }\n\n return allValues;\n }",
"public static Multigraph smartAddEdge(Multigraph graph, Edge edge, boolean stopIfMissing) {\n\n if (!graph.containsVertex(edge.getSource())) {\n if(stopIfMissing){\n throw new IllegalStateException(\"Missing source node for edge \"+ edge);\n }\n graph.addVertex(edge.getSource());\n }\n if (!graph.containsVertex(edge.getDestination())) {\n if(stopIfMissing){\n throw new IllegalStateException(\"Missing destination node for edge \"+ edge);\n }\n graph.addVertex(edge.getDestination());\n }\n //That a good mapping edge, add to the related query\n graph.addEdge(edge.getSource(), edge.getDestination(), edge.getLabel());\n return graph;\n }",
"public void addEdge(StubEdge e) {\n }",
"public ExtendedListIterable<Edge> edges(Node n1, Node n2, Direction direction) {\n return inspectableGraph.edges(n1, n2, Direction.EITHER);\n }"
] | [
"0.59273803",
"0.58324254",
"0.5824965",
"0.58209807",
"0.58031917",
"0.56973755",
"0.561768",
"0.5603355",
"0.55360097",
"0.5530979",
"0.5492283",
"0.54731876",
"0.5455526",
"0.545287",
"0.5445639",
"0.5439368",
"0.5439208",
"0.54211277",
"0.54191524",
"0.53933597",
"0.53914285",
"0.5385149",
"0.5383346",
"0.5382265",
"0.5345906",
"0.5337117",
"0.53190094",
"0.5307554",
"0.53064406",
"0.52894056",
"0.5282762",
"0.52796423",
"0.5271825",
"0.52590364",
"0.52586293",
"0.5249525",
"0.5248044",
"0.5244325",
"0.52346635",
"0.522318",
"0.52196395",
"0.52195984",
"0.5215908",
"0.52108395",
"0.5210113",
"0.5196706",
"0.51914334",
"0.51879776",
"0.518469",
"0.5183785",
"0.51818514",
"0.5165173",
"0.5152399",
"0.5148653",
"0.5148651",
"0.5148081",
"0.5137825",
"0.51366484",
"0.5136177",
"0.5132449",
"0.51310015",
"0.51280504",
"0.5126889",
"0.5124778",
"0.5121958",
"0.51194465",
"0.51185966",
"0.51083696",
"0.5106958",
"0.5106603",
"0.50916624",
"0.5087239",
"0.50833917",
"0.50775677",
"0.5075538",
"0.50746244",
"0.50693756",
"0.50633156",
"0.5061968",
"0.5061305",
"0.5059803",
"0.50596946",
"0.50543296",
"0.50521255",
"0.50443876",
"0.5041835",
"0.50363874",
"0.5034353",
"0.5030676",
"0.5026407",
"0.50246495",
"0.50228745",
"0.50086904",
"0.5000604",
"0.49963278",
"0.49937338",
"0.49936733",
"0.49930868",
"0.49893627",
"0.49866176"
] | 0.60295206 | 0 |
Type text and then press the button. | @Test
public void ensureTextChangesWork() {
onView(withId(R.id.inputField))
.perform(typeText("HELLO"), closeSoftKeyboard());
reportHelper.label("myTestStepLabel_1_1");
onView(withId(R.id.changeText)).perform(click());
// Check that the text was changed.
onView(withId(R.id.inputField)).check(matches(withText("Lalala")));
reportHelper.label("myTestStepLabel_1_2");
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void enterAnswer(String text) {\n\t\ttextBox.clear();\n\t\ttextBox.sendKeys(text);\n\t}",
"void actionButton ( ) throws IOException {\n String textOfField = this.gui.wdgInputText.getText();\n this.gui.widgOutput.append(\"Button1 \" + (++this.ctKeyStroke1) + \" time, text=\" + textOfField + \"\\n\");\n }",
"protected void enterText(InputHandler input)\n\t{\n\t\tif (clearCharBuffer)\n\t\t{\n\t\t\tinput.consumeLastTypedChar();\n\t\t\tclearCharBuffer = false;\n\t\t}\n\t\tchar c = input.consumeLastTypedChar();\n\t\tif (c == '\\b')\n\t\t{\n\t\t\t// Remove a character if the key was backspace\n\t\t\tremoveChar();\n\t\t}\n\t\telse if (c == '\\n')\n\t\t{\n\t\t\t// Call the enter method if the enter key was pressed\n\t\t\tenterPressed();\n\t\t}\n\t\telse if (c != 0)\n\t\t{\n\t\t\t// Add a character to the text field\n\t\t\tputChar(c);\n\t\t}\n\t}",
"@And(\"^I press \\\"([^\\\"]*)\\\"$\")\n public void iPress(String arg0) throws Throwable {\n home.clickGetAQuote();\n //throw new PendingException();\n }",
"public void clickOnText(String text);",
"public void enterTextInToInput(WebElement input, String text) {\r\n try {\r\n input.clear();\r\n input.sendKeys(text);\r\n logger.info(text + \" was inputed to input \");\r\n } catch (Exception e) {\r\n logger.error(\"Cannot work with input\");\r\n Assert.fail(\"Cannot work with input\");\r\n }\r\n\r\n\r\n }",
"public void inputText(WebElement element, String text) {\r\n\t\twaitForElement(element);\r\n\t\telement.clear();\r\n\t\telement.sendKeys(text);\r\n\t}",
"public void type(String text, By locator) {\n waitForVisibilityOf(locator, 6);\n find(locator).sendKeys(text);\n }",
"public void enterTextinTextbox(WebElement element, String text) {\n\n\t\telement.clear();\n\t\telement.sendKeys(text);\n\t}",
"public void textBoxSubmit() throws InterruptedException {\n\t\tdriver.get(\"http://www.google.com\");\n\t\tWebElement input = driver.findElement(By.name(\"q\"));\n\t\tinput.sendKeys(\"React\");\n\t\tThread.sleep(1000);\n\t\tinput.clear();\n\t\tThread.sleep(1000);\n\t\tinput.sendKeys(\"Angular\");\n\t\tThread.sleep(1000);\n\t\tinput.submit();\n\t}",
"public void submitText() {\r\n \t\tthis.dialog.clickOK();\r\n \t}",
"public void type(String string) {\n\t\tthis.search.sendKeys(string);;\r\n\t}",
"public void sendText(final String text, final boolean pressEnter) {\n\t\tmethods.inputManager.sendKeys(text, pressEnter);\n\t}",
"protected void type(WebElement element, String text) {\n waitForElementToBeVisible(element);\n element.clear();\n element.sendKeys(text);\n }",
"protected void type(String text, Finder<WebElement, WebDriver> inputFinder) {\n \t\tcontext.type(text, inputFinder);\n \t}",
"@Override\n public void onClick(View v) {\n new TerminalThread(etInput.getText().toString(), 2).start();\n }",
"public void enterText(WebElement element,String value) {\nelement.sendKeys(value);\n\t}",
"public static void typeText(WebElement element, String text) throws InterruptedException {\n\t\tThread.sleep(2000);\n\t\ttry {\n\t\t\tif (element.isDisplayed() && element.isEnabled()) {\n\t\t\t\telement.click();\n\t\t\t\telement.sendKeys(text);\n\t\t\t\tThread.sleep(1000);\n\t\t\t\t//return true;\n\t\t\t} else {\n\t\t\t\tSystem.out.println(\"Element is not displayed.\");\n\t\t\t\t//return false;\n\t\t\t}\n\t\t} catch (Exception e) {\n\t\t\tSystem.out.println(\"Some exception occured.\" + e.getMessage());\n\t\t\t//return false;\n\t\t}\n\t}",
"private void clickEnter(){\n\t\tString commandInput = textInput.getText();\n\t\tString feedback;\n\n\t\tif (commandIsClear(commandInput)) {\n\t\t\tusedCommands.addFirst(commandInput);\n\t\t\tclearLinkedDisplay();\n\n\t\t} else {\n\t\t\tif (commandInput.trim().isEmpty()) {\n\t\t\t\tfeedback = \"Empty command\";\n\t\t\t} else {\n\t\t\t\ttry {\n\t\t\t\t\tusedCommands.addFirst(commandInput);\n\t\t\t\t\tParser parser = new Parser(commandInput);\n\t\t\t\t\tTask currentTask = parser.parseInput();\n\t\t\t\t\t\n\t\t\t\t\tif (currentTask.getOpCode() == OPCODE.EXIT) {\n\t\t\t\t\t\tWindow frame = findWindow(widgetPanel);\n\t\t\t\t\t\tframe.dispatchEvent(new WindowEvent(frame, WindowEvent.WINDOW_CLOSING));\n\t\t\t\t\t\tframe.dispose();\n\t\t\t\t\t}\n\t\t\t\t\tif (currentTask.getOpCode() == OPCODE.HELP) {\n\t\t\t\t\t\tfeedback = currentTask.getHelpMessage();\n\t\t\t\t\t} else {\n\t\t\t\t\t\tfeedback = GUIAbstract.getLogic().executeTask(currentTask);\n\t\t\t\t\t}\n\t\t\t\t} catch (Exception e) {\n\t\t\t\t\tfeedback = e.getMessage();\n\t\t\t\t}\n\t\t\t}\n\t\t\tlinkedDisplay.displayFeedback(feedback);\n\t\t\tfor (TasksWidget widget : linkedOptionalDisplays) {\n\t\t\t\twidget.doActionOnClick();\n\t\t\t}\n\t\t}\n\t\tclearTextInput();\n\t}",
"public void buttonClick() {\n\t\tdriver.get(\"https://es.wikipedia.org\");\n\t\tWebElement input = driver.findElement(By.id(\"searchInput\"));\n\t\tinput.sendKeys(\"React\");\n\t\tinput.clear();\n\t\tinput.sendKeys(\"Angular\");\n\t\t\n\t\tWebElement button = driver.findElement(By.id(\"searchButton\"));\n\t\tbutton.click();\n\t}",
"protected void enterPressed()\n\t{\n\t\t// Call the enter method if the enter key was pressed\n\t\tif (showCaret)\n\t\t\tonSubmit(text.getText().substring(0, text.getText().length() - 1));\n\t\telse onSubmit(text.getText());\n\t}",
"public void inputText(String value) {\n getWrappedElement().clear();\n getWrappedElement().sendKeys(value);\n logger.debug(\"updated element {} with value {}\", getLocator(), value);\n }",
"public void sendTextInstant(final String text, final boolean pressEnter) {\n\t\tmethods.inputManager.sendKeysInstant(text, pressEnter);\n\t}",
"@FXML\n private void keypadAction(ActionEvent event)\n {\n // Get Button text\n Button button = (Button)event.getSource();\n String buttonText = button.getText();\n \n pressKey(buttonText);\n \n }",
"public static void pressEnterToContinue() {\n\t\tScanner input = new Scanner(System.in);\n\t\tSystem.out.println(\"Press Enter to continue...\");\n\t\tinput.nextLine();\n\t}",
"public void interactWithKeyboard() {\n StdDraw.setCanvasSize(WIDTH * 16, HEIGHT * 16);\n StdDraw.setXscale(0, WIDTH);\n StdDraw.setYscale(0, HEIGHT);\n createMenu();\n StdDraw.enableDoubleBuffering();\n while (true) {\n if (StdDraw.hasNextKeyTyped()) {\n char input = Character.toUpperCase(StdDraw.nextKeyTyped());\n if (input == 'v' || input == 'V') {\n StdDraw.enableDoubleBuffering();\n StdDraw.clear(Color.BLACK);\n StdDraw.text(WIDTH / 2, HEIGHT * 2 / 3, \"Enter a name: \" + name);\n StdDraw.text(WIDTH / 2, HEIGHT * 5 / 6, \"Press # to finish.\");\n StdDraw.show();\n while (true) {\n if (StdDraw.hasNextKeyTyped()) {\n char next = StdDraw.nextKeyTyped();\n if (next == '#') {\n createMenu();\n break;\n } else {\n name += next;\n StdDraw.enableDoubleBuffering(); StdDraw.clear(Color.BLACK);\n StdDraw.text(WIDTH / 2, HEIGHT * 2 / 3, \"Enter a name: \" + name);\n StdDraw.text(WIDTH / 2, HEIGHT * 5 / 6, \"Press # to finish.\");\n StdDraw.show();\n }\n }\n }\n }\n if (input == 'l' || input == 'L') {\n toInsert = loadWorld();\n if (toInsert.substring(0, 1).equals(\"k\")) {\n floorTile = Tileset.GRASS;\n }\n toInsert = toInsert.substring(1);\n interactWithInputString(toInsert);\n ter.renderFrame(world);\n startCommands();\n }\n if (input == 'n' || input == 'N') {\n toInsert += 'n';\n StdDraw.enableDoubleBuffering();\n StdDraw.clear(Color.BLACK);\n StdDraw.text(WIDTH / 2, HEIGHT * 2 / 3, \"Enter a seed: \" + toInsert);\n StdDraw.show();\n while (true) {\n if (!StdDraw.hasNextKeyTyped()) {\n continue;\n }\n char c = StdDraw.nextKeyTyped();\n if (c == 's' || c == 'S') {\n toInsert += 's';\n StdDraw.enableDoubleBuffering();\n StdDraw.clear(Color.BLACK);\n StdDraw.text(WIDTH / 2, HEIGHT * 2 / 3, \"Enter a seed: \" + toInsert);\n StdDraw.show(); interactWithInputString(toInsert);\n ter.renderFrame(world); mouseLocation(); startCommands();\n break;\n }\n if (c != 'n' || c != 'N') {\n toInsert += c;\n StdDraw.enableDoubleBuffering(); StdDraw.clear(Color.BLACK);\n StdDraw.text(WIDTH / 2, HEIGHT * 2 / 3, \"Enter a seed: \" + toInsert);\n StdDraw.show();\n }\n }\n }\n if (input == 'l' || input == 'L') {\n toInsert = loadWorld();\n if (toInsert.substring(0, 1).equals(\"k\")) {\n floorTile = Tileset.GRASS;\n }\n toInsert = toInsert.substring(1); interactWithInputString(toInsert);\n ter.renderFrame(world); startCommands();\n }\n }\n }\n }",
"@Override\n\t\t\tpublic void actionPerformed(ActionEvent ae) {\n\t\t\t\tif (machine.atStart())\n\t\t\t\t\tmachine.setInput(inputText.getText());\n\t\t\t\t\n\t\t\t\ttry { \n\t\t\t\t\tmachine.step(); // take a step\n\t\t\t\t\t\n\t\t\t\t\t// if there is input\n\t\t\t\t\tif (inputText.getText().length() > 0) {\n\t\t\t\t\t\tinputText.setEditable(false); // disable input edit\n\t\t\t\t\t\tbtnRun.setEnabled(false); // disable run\n\t\t\t\t\t\tbtnStepBack.setEnabled(true); // enable step back\n\n\t\t\t\t\t\t// report character just read\n\t\t\t\t\t\tlblCurrentInput.setText(\"Just read: \" + \n\t\t\t\t\t\t machine.getCurrentInput());\n\t\t\t\t\t}\n\n\t\t\t\t\t// if end of input, disable step forward\n\t\t\t\t\tif (! (machine.getStatus().equals(Automaton.READY) ||\n\t\t\t\t\t\t\tmachine.getStatus().equals(Automaton.RUN)))\n\t\t\t\t\t\tbtnStepForward.setEnabled(false);\n\t\t\t\t\t\n\t\t\t\t} catch (NoStartStateDefined e) {\n\t\t\t\t\treportException(e);\n\t\t\t\t} catch (NoTransitionDefined e) {\n\t\t\t\t\treportException(e);\n\t\t\t\t}\n\t\t\t\tupdate(); // update states, labels, text\n\t\t\t}",
"public ReturnButton(String text) {\n super(text);\n this.addActionListener(this);\n }",
"@Override\n\t\t\tpublic void onClick(View v) {\n\t\t\t\tif (currentInputType == INPUT_TYPE_KEYBOARD) {\n\n\t\t\t\t} else {\n\t\t\t\t\tuiHandler.sendEmptyMessage(INPUT_TYPE_KEYBOARD);\n\t\t\t\t}\n\t\t\t}",
"public void actionButton(String text);",
"public String interact() {\n return \"Nguiikk!\";\n }",
"private void pressAnyKey() {\n Scanner myScanner = new Scanner(System.in);\n System.out.println(\"Press Enter key to continue...\");\n myScanner.nextLine();\n }",
"protected void dialog() {\n TextInputDialog textInput = new TextInputDialog(\"\");\n textInput.setTitle(\"Text Input Dialog\");\n textInput.getDialogPane().setContentText(\"Nyt bord nr: \");\n textInput.showAndWait()\n .ifPresent(response -> {\n if (!response.isEmpty()) {\n newOrderbutton(response.toUpperCase());\n }\n });\n }",
"@Test\n public void sendKeys() {\n page.textInput.sendKeys(\"coffee\");\n waiter.waitForElementAttributeEqualsString(page.textInput, \"value\", \"coffee\", driver);\n //type into a <textarea> element\n //before typing, the textarea element displays a hint, but not an actual text (in the 'placeholder' attribute)\n //therefore the getAttribute(\"value\") method call returns an empty String\n waiter.waitForElementAttributeEqualsString(page.textarea, \"value\", \"\", driver);\n page.textarea.sendKeys(\"1234567890\");\n //after typing, the text in the field will be \"1234567890\"\n waiter.waitForElementAttributeEqualsString(page.textarea, \"value\", \"1234567890\", driver);\n //type the same text again and the text in the field becomes \"12345678901234567890\"\n page.textarea.sendKeys(\"1234567890\");\n waiter.waitForElementAttributeEqualsString(page.textarea, \"value\", \"12345678901234567890\", driver);\n }",
"@Override\n public void interact() {\n System.out.print(\"Halo aku ikan di bawah laut dalam lho, aku punya lampu supaya aku\" \n + \"bisa tetap melihat di kegelapan\");\n }",
"public void enterTextInToInput(String xpath, String text) {\r\n WebElement input = webDriver.findElement(By.xpath(xpath));\r\n try {\r\n input.clear();\r\n input.sendKeys(text);\r\n logger.info(text + \" was inputed to input \");\r\n } catch (Exception e) {\r\n logger.error(\"Cannot work with input\");\r\n Assert.fail(\"Cannot work with input\");\r\n }\r\n\r\n\r\n }",
"@Override\r\n\t\t\tpublic void actionPerformed(ActionEvent arg0) {\n \t Robot r;\r\n\t\t\t\ttry {\r\n\t\t\t\t\tr = new Robot();\r\n\t\t\t\t int keyCode = KeyEvent.VK_ENTER; // the A key\r\n\t\t\t\t r.keyPress(keyCode);\t\t\t\t \r\n\t\t\t\t} catch (AWTException e1) {\r\n\t\t\t\t\t// TODO Auto-generated catch block\r\n\t\t\t\t\te1.printStackTrace();\r\n\t\t\t\t}\r\n\t\t\t}",
"public static void toEnterText(By by, String text)\n {\n driver.findElement(by).sendKeys(text);\n }",
"public String enterPressed();",
"@Test\n\t @WebTest\n\t public void DemoTest1() throws InterruptedException {\n\t Grid.driver().get(\"http://www.google.com/\");\n\t \n\t TextField field = new TextField(\"id=lst-ib\");\n\n\t //Thread will wait until TextFiled element present in the browser\n\t WebDriverWaitUtils.waitUntilElementIsPresent(field.getLocator());\n\n\t //Search for the string 'SeLion' in the text box\n\t field.type(\"Selenium\\n\");\n\t }",
"@Override\n public void setFocus()\n {\n this.textInput.setFocus();\n }",
"default void interactWith(Key key) {\n\t}",
"public void InsertText(String txt){\n driver.switchTo().frame(driver.findElement(IFRAMEID));\n WebElement inputBox = find(BOXID);\n inputBox.clear();\n inputBox.sendKeys(txt);\n\n }",
"public void type(char c){\n //Only type if a text is selected\n if(currentText != null) {\n //If the character is a newline then a new line should be created and the character and line index's should be updated as appropriate\n if (c == '\\n') {\n currentText = codeWindow.getTextLineController().split(currentText, characterIndex, codeWindow);\n characterIndex = 0;\n lineIndex++;\n }\n //If the character that was typed is any other character then the line will not be split, update it with the typed character and update the character index\n else {\n currentText = codeWindow.getTextLineController().update(currentText, characterIndex, c);\n characterIndex++;\n }\n //After typing the position of the cursor will be different, update the position\n updatePosition();\n }\n }",
"@Override\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\tinput(input.getText().toString());\n\t\t\t\tshow.setText(output.toString());\n\t\t\t}",
"@Override\n\tpublic void okPressed() {\n\t\t_text = _noteTextField.getText();\n\t\tsetReturnCode(OK);\n\t\tclose();\n\t}",
"void showOtherUserTyping();",
"public void click() {\n\t\tSystem.out.println(\"LinuxButton Click\");\r\n\t}",
"@Test\n public void enterTextInSearchField() {\n WebDriverWait wait = new WebDriverWait(driver, 5);\n\n // Afterwards, we need to inform WebDriver to wait until an expected condition is met\n // The ExpectedConditions class supplies many methods for dealing with scenarios that may occur before\n // executing the next Test Step\n }",
"public void type(String locator, String text) {\n waitForElement(locator);\n driver.findElement(By.xpath(locator)).sendKeys(text);\n }",
"public void typeUsername(String text) {\r\n\t\tusernameInput = driver.findElement(usernameSelector);\r\n\t\tusernameInput.sendKeys(text);\r\n\t\t\t\r\n\t}",
"public String submitText();",
"@Override\n\t\t\tpublic void keyPressed(KeyEvent e) {\n\t\t\t\tif (e.getKeyCode() == KeyEvent.VK_ENTER) {\n\t\t\t\t\tsbt_jbt.doClick();\n\t\t\t\t}\n\t\t\t}",
"public void enterText(final By locator, String text){\n WebElement element = findElementClickable(locator);\n\t\ttry {\n \t \t\n if(text.contains(\"@\"))\n {\n element.clear();\n waitForElement(ExpectedConditions.refreshed(ExpectedConditions.visibilityOfElementLocated(locator)));\n String[] parts=text.split(\"@\");\n String selectAll = Keys.chord(Keys.CONTROL,Keys.ALT,\"2\");\n for(int i=0; i<parts.length;i++) {\n \tdriver.findElement(locator).sendKeys(parts[i]);\n\n if(i!=(parts.length-1)) {\n driver.findElement(locator).sendKeys(selectAll);\n\n }\n }\n\n }else {\n driver.findElement(locator).sendKeys(Keys.chord(Keys.CONTROL,\"a\"),text);\n }\n LOGGER.info(\"Step : \"+Thread.currentThread().getStackTrace()[2].getMethodName()+\": Pass\");\n\n }catch(Exception e)\n {\n LOGGER.error(\"Step : \"+Thread.currentThread().getStackTrace()[2].getMethodName()+\": Fail\");\n //e.printStackTrace();\n throw new NotFoundException(\"Exception \"+ e +\" thrown while entering \"+text+\" using locator \"+locator);\n\t\t\n }\n\n\n\n }",
"public void textBoxAction( TextBoxWidgetExt tbwe ){}",
"@Override\n public boolean onEditorAction(TextView v, int actionId, KeyEvent event) {\n if (actionId == EditorInfo.IME_ACTION_DONE) {\n // User has finished entering text\n // Perform the search button click programmatically\n search.performClick();\n // Return true on successfully handling the action\n return true;\n }\n\n // Do not perform any task when user is actually entering text\n // in the editable text view\n return false;\n }",
"public static void pressSubmit(){\n DriverManager.driver.findElement(Constans.SUBMIT_BUTTON_LOCATOR).click();\n }",
"public void inputSearchText(String searchValue) {\n try {\n clickElement(eleToDoSearchInput, \"click to eleToDoSearchInput\");\n sendKeyTextBox(eleToDoSearchInput, searchValue, \"send key to searchTextToDoListPage\");\n Thread.sleep(smallerTimeOut);\n NXGReports.addStep(\"Ending Input Search.\", LogAs.PASSED, null);\n } catch (Exception e) {\n AbstractService.sStatusCnt++;\n NXGReports.addStep(\"Ending Input Search.\", LogAs.FAILED, new CaptureScreen(CaptureScreen.ScreenshotOf.BROWSER_PAGE));\n }\n }",
"private void sendTextInBox() {\n\t\tmodelAdapter.send(textFieldMessage.getText());\n\t textFieldMessage.setText(\"\");\n\t }",
"@Override\n public void send(final CharSequence text) {\n final KeyCharacterMap characterMap = KeyCharacterMap.load(KeyCharacterMap.VIRTUAL_KEYBOARD);\n\n long timeout =\n System.currentTimeMillis()\n + serverInstrumentation.getAndroidWait().getTimeoutInMillis();\n SelendroidLogger.info(\"Using timeout of \" + timeout + \" milli seconds.\");\n\n done = false;\n\n instrumentation.runOnMainSync(new Runnable() {\n public void run() {\n for (int i = 0; i < text.length(); i++) {\n char c = text.charAt(i);\n int code = WebViewKeys.getKeyEventFromUnicodeKey(c);\n if (code != -1) {\n webview.dispatchKeyEvent(new KeyEvent(KeyEvent.ACTION_DOWN, code));\n webview.dispatchKeyEvent(new KeyEvent(KeyEvent.ACTION_UP, code));\n } else {\n KeyEvent[] arr = characterMap.getEvents(new char[] {c});\n if (arr != null) {\n for (int j = 0; j < arr.length; j++) {\n webview.dispatchKeyEvent(arr[j]);\n }\n }\n }\n }\n done = true;\n }\n });\n }",
"public void pressTVButton() {\n System.out.println(\"Home: You must pick an app to show movies.\\n\");\n }",
"private void handleTextInputCallback(TextInputCallback tic)\n throws IOException {\n System.out.print(tic.getPrompt());\n System.out.flush();\n tic.setText((new BufferedReader\n (new InputStreamReader(System.in))).readLine());\n }",
"public void run() {\n try {\n Thread.sleep(100);\n } catch (InterruptedException ex) {\n }\n num3.startEditing();\n num3.requestFocus();\n }",
"public void clickSearchButton() {\n\t\tsearchButton.click();\n\t}",
"@Override\n public void onClick(View v) {\n String inputFieldText = ((TextView) findViewById(R.id.inputField)).getText().toString();\n\n // Set text to custom text, or if custom text is empty set to default hint\n if (inputFieldText.isEmpty()) {\n ((TextView) findViewById(R.id.text)).setText(\"Enter your OWN text!\");\n } else {\n ((TextView) findViewById(R.id.text)).setText(inputFieldText);\n }\n }",
"public static void enterText(By by, String text) {\n driver.findElement(by).sendKeys(text);\n }",
"public static void enterText(By by, String text) {\n driver.findElement(by).sendKeys(text);\n }",
"public void type(String s){\n\t\tif(currentEdit != null){\n\t\t\tint cur = currentEdit.getSelectionStart();\n\t\t\tif(s.equals(\"del\")||s.equals(\"del(\")){\n\t\t\t\tif(cur != 0){\n\t\t\t\t\tcurrentEdit.getText().delete(cur-1, cur);\n\t\t\t\t}\t\t\t\n\t\t\t}else if(s.equals(\"clear\")){\n\t\t\t\tcurrentEdit.setText(\"\");\n\t\t\t}else if(s.equals(\"ENTER\")){\n\t\t\t\tonEnter();\n\t\t\t}else{\n\t\t\t\tcurrentEdit.getText().insert(cur, s);\n\t\t\t}\n\t\t}\n\t}",
"@When(\"^enter any value \\\"([^\\\"]*)\\\" in Sent to field$\")\npublic void enter_any_value_in_Sent_to_field(String arg1) throws Throwable \n{\n\t \n\tActions act = new Actions(driver);\n\t\n\tdriver.findElement(By.xpath(\"//input[@class='select2-search__field']\")).sendKeys(\"naveen\");\n Thread.sleep(2000);\n \n \n driver.findElement(By.xpath(\"//li[contains(text(),'naveen naveen')]\"));\n Thread.sleep(1000); \n \n \n\tact.sendKeys(Keys.RETURN).perform();\n Thread.sleep(3000);\n \n\tdriver.findElement(By.id(\"compose_message_title\")).sendKeys(\"Testing for Sending message\");\n\tThread.sleep(3000);\n\t\n\t\n\tdriver.findElement(By.cssSelector(\".cke_wysiwyg_frame\"));\n\tdriver.switchTo().frame(0);\n\twaitForElementToBeLoad(\"//body\");\n\tdriver.findElement(By.xpath(\"//body\")).click();\n\twaitForElementToBeLoad(\"//body/p\");\n\tdriver.findElement(By.xpath(\"//body/p\")).sendKeys(\"Hello Mr.Navven \\n This is for testing \\n From, \\n Ankita\");\n\tThread.sleep(3000);\n\tdriver.switchTo().defaultContent();\n\tThread.sleep(3000);\n\n \n}",
"@Override\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\tif(parent_frame.getFestival().isLocked()){\n\t\t\t\t\tfeedback_display.append(\"\\tPlease submit after voice prompt has finished.\\n\");\n\t\t\t\t} else {\n\t\t\t\t\tprocessAttempt(input_from_user.getText());\n\t\t\t\t}\n\t\t\t\tinput_from_user.requestFocusInWindow();//gets focus back to the spell here field\n\t\t\t}",
"@Override\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\tString input = e.getActionCommand();\n\t\t\t\tif(start) {\n\t\t\t\t\tdisplay.setText(\"\");\n\t\t\t\t\tstart = false;\n\t\t\t\t}\n\t\t\t\tdisplay.setText(display.getText() + input);\n\t\t\t}",
"protected void beginEnterText()\n\t{\n\t\tdisplayingCaret = true;\n\t\ttext.appendText(\"|\");\n\t\tcaretBlinkTime = 0;\n\t\tclearCharBuffer = true;\n\t}",
"public override void Do()\r\n { \r\n if (TextEditor.UiScope == null)\r\n { \r\n // We dont want to process the input item if the editor has already been detached from its UiScope. \r\n return;\r\n } \r\n\r\n DoTextInput(TextEditor, _text, _isInsertKeyToggled, /*acceptControlCharacters:*/false);\r\n }",
"public static void pressButtonByText(DialogComponentProvider provider, String buttonText,\n\t\t\tboolean waitForCompletion) {\n\t\tpressButtonByText(provider.getComponent(), buttonText, waitForCompletion);\n\t}",
"public void beginPress();",
"@When(\"user clicks on search button and types{string}\")\r\n\tpublic void user_clicks_on_search_button_and_types(String string) {\n\t driver.findElement(By.xpath(\"//*[@id=\\\"myInput\\\"]\")).sendKeys(\"HeadPhone\");\r\n\t}",
"@Override\n public void click(String clickStr) {\n view.append(clickStr);\n view.setSelection(view.getText().length());\n }",
"void urlFieldEnterKeyPressed();",
"void keyPress(int key);",
"@Override\n\tpublic void actionPerformed(ActionEvent arg0) {\n\t\tButtonPress();\n\t}",
"public void testing() {\n System.out.println(\"button pressed!\");\n }",
"public void run() {\n try {\n Thread.sleep(100);\n } catch (InterruptedException ex) {\n }\n num2.startEditing();\n num2.requestFocus();\n }",
"void setFocus();",
"public void actionPerformed(ActionEvent e) {\r\n mode = InputMode.CHG_TEXT;\r\n instr.setText(\"Click one node to change the text on the node.\");\r\n }",
"private void pressUpFromCLI() {\n\t\tupLastPressed = true;\n\t\tif (commandIterator.hasNext()) {\n\t\t\ttextInput.setText(commandIterator.next());\n\t\t}\n\t\tif (downLastPressed) {\n\t\t\ttextInput.setText(commandIterator.next());\n\t\t\tdownLastPressed = false;\n\t\t}\n\t}",
"@Override\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\ttext.setText(ok.getText());\n\t\t\t}",
"public String writeInInputHitEnter(String object, String data) {\n\t\tlogger.debug(\"Writing in text box\");\n\n\t\ttry {\n\n\t\tWebElement ele=\twait.until(explicitWaitForElement(By.xpath(OR.getProperty(object))));\n\t\tele.clear();\n ((JavascriptExecutor) driver).executeScript(\"arguments[0].value = arguments[1]\", ele, data);\n\t\tele.sendKeys(Keys.RETURN);\n\t\t\t\t\n\t\t}catch(TimeoutException ex)\n\t\t\n\t\t{\n\t\t\treturn Constants.KEYWORD_FAIL +\"Cause: \"+ ex.getCause();\n\t\t} catch (Exception e) {\n\t\t\n\t\t\treturn Constants.KEYWORD_FAIL + \" Unable to write \" + e.getLocalizedMessage();\n\t\t}\n\t\treturn Constants.KEYWORD_PASS;\n\n\t}",
"public void clickButton()\n {\n fieldChangeNotify( 0 );\n }",
"public void enterSubText(String value) {\r\n\r\n\t\treportStep(\"About to enter the SubText \" + value, \"INFO\");\r\n\r\n\t\tif(enterTextInChrome(appNotificationSubText,value)) {\r\n\r\n\t\t\treportStep(\"Successfully entered the SubText \" + value, \"PASS\");\r\n\r\n\t\t}else {\r\n\r\n\t\t\treportStep(\"Failed to enter the subText as : \" + value, \"FAIL\");\r\n\r\n\t\t}\r\n\t}",
"void correctKeyPress();",
"@Test\n public void autoCompleteTextView_onDataClickAndCheck() {\n onView(withId(R.id.autoCompleteTextView))\n .perform(typeText(\"S\"), closeSoftKeyboard());\n\n // This is useful because some of the completions may not be part of the View Hierarchy\n // unless you scroll around the list.\n onData(allOf(instanceOf(String.class), is(\"Baltic Sea\")))\n .inRoot(withDecorView(not(is(mActivity.getWindow().getDecorView()))))\n .perform(click());\n\n // The text should be filled in.\n onView(withId(R.id.autoCompleteTextView))\n .check(matches(withText(\"Baltic Sea\")));\n }",
"private final static void pulsaEnter() {\n\t\tSystem.out.println();\n\t\tSystem.out.println(\"\\nPulsa Enter para continuar...\");\n\t\tkb.nextLine();\n\t}",
"public void sendInput(String input) throws IOException {\n\t\tmShell.sendCommand(\"INPUT:\" + mStag + \":\" + input + \":\");\n\t}",
"@Test\n public void researchEditTextInputTest() {\n onView(withId(R.id.network_input_research))\n .perform(typeText(INPUT_TEXT))\n .check(matches(withText(INPUT_TEXT)));\n }",
"public static void pressButtonByText(DialogComponentProvider provider, String buttonText) {\n\t\tpressButtonByText(provider.getComponent(), buttonText, true);\n\t}",
"public void setElementText(WebElement element, String text) {\n wait = new WebDriverWait(eventDriver, 20);\n wait.until(ExpectedConditions.visibilityOf(element));\n element.sendKeys(text);\n }",
"private void userViewStep() {\n textUser.requestFocus();\n textUser.postDelayed(\n new Runnable() {\n public void run() {\n InputMethodManager inputMethodManager = (InputMethodManager) getActivity().getSystemService(Context.INPUT_METHOD_SERVICE);\n inputMethodManager.showSoftInput(textUser, 0);\n }\n }, 200);\n EventBus.getDefault().postSticky(new EventOnboardingChanges(EventOnboardingChanges.ChangeType.REGISTER_CHANGE_TITLE, getResources().getString(R.string.tact_username_title)));\n }",
"public void typePassword(String text) {\r\n\t\tpasswordInput = driver.findElement(passwordSelector);\r\n\t\tpasswordInput.sendKeys(text);\r\n\t\t\r\n\t}",
"private void sendButtonActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_sendButtonActionPerformed\n String str = requestCommand.getText();\n sC.sendCommand(str); \n requestCommand.requestFocus();\n }",
"public void keyDown() {\n\n driver.switchTo().activeElement().sendKeys(Keys.ARROW_DOWN);\n driver.switchTo().activeElement().sendKeys( Keys.ENTER);\n\n\n }"
] | [
"0.69606704",
"0.66325474",
"0.65169686",
"0.64609796",
"0.6457273",
"0.64411044",
"0.6422923",
"0.63510686",
"0.6343789",
"0.6331651",
"0.6329258",
"0.6326656",
"0.63168496",
"0.63057655",
"0.6296814",
"0.6291062",
"0.6253799",
"0.6231428",
"0.6230861",
"0.62234575",
"0.6179091",
"0.61790085",
"0.6165393",
"0.61418724",
"0.61326",
"0.6109441",
"0.60868806",
"0.60450965",
"0.6036843",
"0.60265386",
"0.60236967",
"0.60221845",
"0.60156226",
"0.60073876",
"0.6002872",
"0.5989436",
"0.5965782",
"0.59552824",
"0.5946947",
"0.5944342",
"0.59318",
"0.5924326",
"0.59214306",
"0.592097",
"0.59143317",
"0.59084374",
"0.5907058",
"0.5874625",
"0.5869193",
"0.58585757",
"0.5857159",
"0.5851006",
"0.5840721",
"0.5838908",
"0.5838658",
"0.5832238",
"0.5820038",
"0.57983935",
"0.57961494",
"0.57892895",
"0.5784129",
"0.5783073",
"0.5782652",
"0.57805437",
"0.5768734",
"0.5755029",
"0.5755029",
"0.57518595",
"0.5738679",
"0.57301337",
"0.5722837",
"0.5722434",
"0.57138515",
"0.57138264",
"0.57088655",
"0.5708471",
"0.56992733",
"0.5697884",
"0.5679089",
"0.56750953",
"0.5673388",
"0.5663454",
"0.56589717",
"0.5657803",
"0.56540674",
"0.5652673",
"0.5650627",
"0.56479365",
"0.5646276",
"0.5644779",
"0.56416726",
"0.5640617",
"0.56397784",
"0.56361055",
"0.56314844",
"0.5631462",
"0.5630245",
"0.5627688",
"0.56202924",
"0.5617809"
] | 0.6025938 | 30 |
Type text and then press the button. | @Test
public void changeText_FailedTest() {
onView(withId(R.id.inputField)).perform(typeText("NewText"),
closeSoftKeyboard());
reportHelper.label("myTestStepLabel_3_1");
onView(withId(R.id.switchActivity)).perform(click());
reportHelper.label("myTestStepLabel_3_2");
// This view is in a different Activity, no need to tell Espresso.
onView(withId(R.id.resultView)).check(matches(withText("errrrrrr")));
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void enterAnswer(String text) {\n\t\ttextBox.clear();\n\t\ttextBox.sendKeys(text);\n\t}",
"void actionButton ( ) throws IOException {\n String textOfField = this.gui.wdgInputText.getText();\n this.gui.widgOutput.append(\"Button1 \" + (++this.ctKeyStroke1) + \" time, text=\" + textOfField + \"\\n\");\n }",
"protected void enterText(InputHandler input)\n\t{\n\t\tif (clearCharBuffer)\n\t\t{\n\t\t\tinput.consumeLastTypedChar();\n\t\t\tclearCharBuffer = false;\n\t\t}\n\t\tchar c = input.consumeLastTypedChar();\n\t\tif (c == '\\b')\n\t\t{\n\t\t\t// Remove a character if the key was backspace\n\t\t\tremoveChar();\n\t\t}\n\t\telse if (c == '\\n')\n\t\t{\n\t\t\t// Call the enter method if the enter key was pressed\n\t\t\tenterPressed();\n\t\t}\n\t\telse if (c != 0)\n\t\t{\n\t\t\t// Add a character to the text field\n\t\t\tputChar(c);\n\t\t}\n\t}",
"@And(\"^I press \\\"([^\\\"]*)\\\"$\")\n public void iPress(String arg0) throws Throwable {\n home.clickGetAQuote();\n //throw new PendingException();\n }",
"public void clickOnText(String text);",
"public void enterTextInToInput(WebElement input, String text) {\r\n try {\r\n input.clear();\r\n input.sendKeys(text);\r\n logger.info(text + \" was inputed to input \");\r\n } catch (Exception e) {\r\n logger.error(\"Cannot work with input\");\r\n Assert.fail(\"Cannot work with input\");\r\n }\r\n\r\n\r\n }",
"public void inputText(WebElement element, String text) {\r\n\t\twaitForElement(element);\r\n\t\telement.clear();\r\n\t\telement.sendKeys(text);\r\n\t}",
"public void type(String text, By locator) {\n waitForVisibilityOf(locator, 6);\n find(locator).sendKeys(text);\n }",
"public void enterTextinTextbox(WebElement element, String text) {\n\n\t\telement.clear();\n\t\telement.sendKeys(text);\n\t}",
"public void textBoxSubmit() throws InterruptedException {\n\t\tdriver.get(\"http://www.google.com\");\n\t\tWebElement input = driver.findElement(By.name(\"q\"));\n\t\tinput.sendKeys(\"React\");\n\t\tThread.sleep(1000);\n\t\tinput.clear();\n\t\tThread.sleep(1000);\n\t\tinput.sendKeys(\"Angular\");\n\t\tThread.sleep(1000);\n\t\tinput.submit();\n\t}",
"public void submitText() {\r\n \t\tthis.dialog.clickOK();\r\n \t}",
"public void type(String string) {\n\t\tthis.search.sendKeys(string);;\r\n\t}",
"public void sendText(final String text, final boolean pressEnter) {\n\t\tmethods.inputManager.sendKeys(text, pressEnter);\n\t}",
"protected void type(WebElement element, String text) {\n waitForElementToBeVisible(element);\n element.clear();\n element.sendKeys(text);\n }",
"protected void type(String text, Finder<WebElement, WebDriver> inputFinder) {\n \t\tcontext.type(text, inputFinder);\n \t}",
"@Override\n public void onClick(View v) {\n new TerminalThread(etInput.getText().toString(), 2).start();\n }",
"public void enterText(WebElement element,String value) {\nelement.sendKeys(value);\n\t}",
"public static void typeText(WebElement element, String text) throws InterruptedException {\n\t\tThread.sleep(2000);\n\t\ttry {\n\t\t\tif (element.isDisplayed() && element.isEnabled()) {\n\t\t\t\telement.click();\n\t\t\t\telement.sendKeys(text);\n\t\t\t\tThread.sleep(1000);\n\t\t\t\t//return true;\n\t\t\t} else {\n\t\t\t\tSystem.out.println(\"Element is not displayed.\");\n\t\t\t\t//return false;\n\t\t\t}\n\t\t} catch (Exception e) {\n\t\t\tSystem.out.println(\"Some exception occured.\" + e.getMessage());\n\t\t\t//return false;\n\t\t}\n\t}",
"private void clickEnter(){\n\t\tString commandInput = textInput.getText();\n\t\tString feedback;\n\n\t\tif (commandIsClear(commandInput)) {\n\t\t\tusedCommands.addFirst(commandInput);\n\t\t\tclearLinkedDisplay();\n\n\t\t} else {\n\t\t\tif (commandInput.trim().isEmpty()) {\n\t\t\t\tfeedback = \"Empty command\";\n\t\t\t} else {\n\t\t\t\ttry {\n\t\t\t\t\tusedCommands.addFirst(commandInput);\n\t\t\t\t\tParser parser = new Parser(commandInput);\n\t\t\t\t\tTask currentTask = parser.parseInput();\n\t\t\t\t\t\n\t\t\t\t\tif (currentTask.getOpCode() == OPCODE.EXIT) {\n\t\t\t\t\t\tWindow frame = findWindow(widgetPanel);\n\t\t\t\t\t\tframe.dispatchEvent(new WindowEvent(frame, WindowEvent.WINDOW_CLOSING));\n\t\t\t\t\t\tframe.dispose();\n\t\t\t\t\t}\n\t\t\t\t\tif (currentTask.getOpCode() == OPCODE.HELP) {\n\t\t\t\t\t\tfeedback = currentTask.getHelpMessage();\n\t\t\t\t\t} else {\n\t\t\t\t\t\tfeedback = GUIAbstract.getLogic().executeTask(currentTask);\n\t\t\t\t\t}\n\t\t\t\t} catch (Exception e) {\n\t\t\t\t\tfeedback = e.getMessage();\n\t\t\t\t}\n\t\t\t}\n\t\t\tlinkedDisplay.displayFeedback(feedback);\n\t\t\tfor (TasksWidget widget : linkedOptionalDisplays) {\n\t\t\t\twidget.doActionOnClick();\n\t\t\t}\n\t\t}\n\t\tclearTextInput();\n\t}",
"public void buttonClick() {\n\t\tdriver.get(\"https://es.wikipedia.org\");\n\t\tWebElement input = driver.findElement(By.id(\"searchInput\"));\n\t\tinput.sendKeys(\"React\");\n\t\tinput.clear();\n\t\tinput.sendKeys(\"Angular\");\n\t\t\n\t\tWebElement button = driver.findElement(By.id(\"searchButton\"));\n\t\tbutton.click();\n\t}",
"protected void enterPressed()\n\t{\n\t\t// Call the enter method if the enter key was pressed\n\t\tif (showCaret)\n\t\t\tonSubmit(text.getText().substring(0, text.getText().length() - 1));\n\t\telse onSubmit(text.getText());\n\t}",
"public void inputText(String value) {\n getWrappedElement().clear();\n getWrappedElement().sendKeys(value);\n logger.debug(\"updated element {} with value {}\", getLocator(), value);\n }",
"public void sendTextInstant(final String text, final boolean pressEnter) {\n\t\tmethods.inputManager.sendKeysInstant(text, pressEnter);\n\t}",
"@FXML\n private void keypadAction(ActionEvent event)\n {\n // Get Button text\n Button button = (Button)event.getSource();\n String buttonText = button.getText();\n \n pressKey(buttonText);\n \n }",
"public static void pressEnterToContinue() {\n\t\tScanner input = new Scanner(System.in);\n\t\tSystem.out.println(\"Press Enter to continue...\");\n\t\tinput.nextLine();\n\t}",
"public void interactWithKeyboard() {\n StdDraw.setCanvasSize(WIDTH * 16, HEIGHT * 16);\n StdDraw.setXscale(0, WIDTH);\n StdDraw.setYscale(0, HEIGHT);\n createMenu();\n StdDraw.enableDoubleBuffering();\n while (true) {\n if (StdDraw.hasNextKeyTyped()) {\n char input = Character.toUpperCase(StdDraw.nextKeyTyped());\n if (input == 'v' || input == 'V') {\n StdDraw.enableDoubleBuffering();\n StdDraw.clear(Color.BLACK);\n StdDraw.text(WIDTH / 2, HEIGHT * 2 / 3, \"Enter a name: \" + name);\n StdDraw.text(WIDTH / 2, HEIGHT * 5 / 6, \"Press # to finish.\");\n StdDraw.show();\n while (true) {\n if (StdDraw.hasNextKeyTyped()) {\n char next = StdDraw.nextKeyTyped();\n if (next == '#') {\n createMenu();\n break;\n } else {\n name += next;\n StdDraw.enableDoubleBuffering(); StdDraw.clear(Color.BLACK);\n StdDraw.text(WIDTH / 2, HEIGHT * 2 / 3, \"Enter a name: \" + name);\n StdDraw.text(WIDTH / 2, HEIGHT * 5 / 6, \"Press # to finish.\");\n StdDraw.show();\n }\n }\n }\n }\n if (input == 'l' || input == 'L') {\n toInsert = loadWorld();\n if (toInsert.substring(0, 1).equals(\"k\")) {\n floorTile = Tileset.GRASS;\n }\n toInsert = toInsert.substring(1);\n interactWithInputString(toInsert);\n ter.renderFrame(world);\n startCommands();\n }\n if (input == 'n' || input == 'N') {\n toInsert += 'n';\n StdDraw.enableDoubleBuffering();\n StdDraw.clear(Color.BLACK);\n StdDraw.text(WIDTH / 2, HEIGHT * 2 / 3, \"Enter a seed: \" + toInsert);\n StdDraw.show();\n while (true) {\n if (!StdDraw.hasNextKeyTyped()) {\n continue;\n }\n char c = StdDraw.nextKeyTyped();\n if (c == 's' || c == 'S') {\n toInsert += 's';\n StdDraw.enableDoubleBuffering();\n StdDraw.clear(Color.BLACK);\n StdDraw.text(WIDTH / 2, HEIGHT * 2 / 3, \"Enter a seed: \" + toInsert);\n StdDraw.show(); interactWithInputString(toInsert);\n ter.renderFrame(world); mouseLocation(); startCommands();\n break;\n }\n if (c != 'n' || c != 'N') {\n toInsert += c;\n StdDraw.enableDoubleBuffering(); StdDraw.clear(Color.BLACK);\n StdDraw.text(WIDTH / 2, HEIGHT * 2 / 3, \"Enter a seed: \" + toInsert);\n StdDraw.show();\n }\n }\n }\n if (input == 'l' || input == 'L') {\n toInsert = loadWorld();\n if (toInsert.substring(0, 1).equals(\"k\")) {\n floorTile = Tileset.GRASS;\n }\n toInsert = toInsert.substring(1); interactWithInputString(toInsert);\n ter.renderFrame(world); startCommands();\n }\n }\n }\n }",
"@Override\n\t\t\tpublic void actionPerformed(ActionEvent ae) {\n\t\t\t\tif (machine.atStart())\n\t\t\t\t\tmachine.setInput(inputText.getText());\n\t\t\t\t\n\t\t\t\ttry { \n\t\t\t\t\tmachine.step(); // take a step\n\t\t\t\t\t\n\t\t\t\t\t// if there is input\n\t\t\t\t\tif (inputText.getText().length() > 0) {\n\t\t\t\t\t\tinputText.setEditable(false); // disable input edit\n\t\t\t\t\t\tbtnRun.setEnabled(false); // disable run\n\t\t\t\t\t\tbtnStepBack.setEnabled(true); // enable step back\n\n\t\t\t\t\t\t// report character just read\n\t\t\t\t\t\tlblCurrentInput.setText(\"Just read: \" + \n\t\t\t\t\t\t machine.getCurrentInput());\n\t\t\t\t\t}\n\n\t\t\t\t\t// if end of input, disable step forward\n\t\t\t\t\tif (! (machine.getStatus().equals(Automaton.READY) ||\n\t\t\t\t\t\t\tmachine.getStatus().equals(Automaton.RUN)))\n\t\t\t\t\t\tbtnStepForward.setEnabled(false);\n\t\t\t\t\t\n\t\t\t\t} catch (NoStartStateDefined e) {\n\t\t\t\t\treportException(e);\n\t\t\t\t} catch (NoTransitionDefined e) {\n\t\t\t\t\treportException(e);\n\t\t\t\t}\n\t\t\t\tupdate(); // update states, labels, text\n\t\t\t}",
"public ReturnButton(String text) {\n super(text);\n this.addActionListener(this);\n }",
"@Override\n\t\t\tpublic void onClick(View v) {\n\t\t\t\tif (currentInputType == INPUT_TYPE_KEYBOARD) {\n\n\t\t\t\t} else {\n\t\t\t\t\tuiHandler.sendEmptyMessage(INPUT_TYPE_KEYBOARD);\n\t\t\t\t}\n\t\t\t}",
"public void actionButton(String text);",
"@Test\r\n public void ensureTextChangesWork() {\n onView(withId(R.id.inputField))\r\n .perform(typeText(\"HELLO\"), closeSoftKeyboard());\r\n reportHelper.label(\"myTestStepLabel_1_1\");\r\n onView(withId(R.id.changeText)).perform(click());\r\n\r\n // Check that the text was changed.\r\n onView(withId(R.id.inputField)).check(matches(withText(\"Lalala\")));\r\n reportHelper.label(\"myTestStepLabel_1_2\");\r\n }",
"public String interact() {\n return \"Nguiikk!\";\n }",
"private void pressAnyKey() {\n Scanner myScanner = new Scanner(System.in);\n System.out.println(\"Press Enter key to continue...\");\n myScanner.nextLine();\n }",
"protected void dialog() {\n TextInputDialog textInput = new TextInputDialog(\"\");\n textInput.setTitle(\"Text Input Dialog\");\n textInput.getDialogPane().setContentText(\"Nyt bord nr: \");\n textInput.showAndWait()\n .ifPresent(response -> {\n if (!response.isEmpty()) {\n newOrderbutton(response.toUpperCase());\n }\n });\n }",
"@Test\n public void sendKeys() {\n page.textInput.sendKeys(\"coffee\");\n waiter.waitForElementAttributeEqualsString(page.textInput, \"value\", \"coffee\", driver);\n //type into a <textarea> element\n //before typing, the textarea element displays a hint, but not an actual text (in the 'placeholder' attribute)\n //therefore the getAttribute(\"value\") method call returns an empty String\n waiter.waitForElementAttributeEqualsString(page.textarea, \"value\", \"\", driver);\n page.textarea.sendKeys(\"1234567890\");\n //after typing, the text in the field will be \"1234567890\"\n waiter.waitForElementAttributeEqualsString(page.textarea, \"value\", \"1234567890\", driver);\n //type the same text again and the text in the field becomes \"12345678901234567890\"\n page.textarea.sendKeys(\"1234567890\");\n waiter.waitForElementAttributeEqualsString(page.textarea, \"value\", \"12345678901234567890\", driver);\n }",
"@Override\n public void interact() {\n System.out.print(\"Halo aku ikan di bawah laut dalam lho, aku punya lampu supaya aku\" \n + \"bisa tetap melihat di kegelapan\");\n }",
"public void enterTextInToInput(String xpath, String text) {\r\n WebElement input = webDriver.findElement(By.xpath(xpath));\r\n try {\r\n input.clear();\r\n input.sendKeys(text);\r\n logger.info(text + \" was inputed to input \");\r\n } catch (Exception e) {\r\n logger.error(\"Cannot work with input\");\r\n Assert.fail(\"Cannot work with input\");\r\n }\r\n\r\n\r\n }",
"@Override\r\n\t\t\tpublic void actionPerformed(ActionEvent arg0) {\n \t Robot r;\r\n\t\t\t\ttry {\r\n\t\t\t\t\tr = new Robot();\r\n\t\t\t\t int keyCode = KeyEvent.VK_ENTER; // the A key\r\n\t\t\t\t r.keyPress(keyCode);\t\t\t\t \r\n\t\t\t\t} catch (AWTException e1) {\r\n\t\t\t\t\t// TODO Auto-generated catch block\r\n\t\t\t\t\te1.printStackTrace();\r\n\t\t\t\t}\r\n\t\t\t}",
"public static void toEnterText(By by, String text)\n {\n driver.findElement(by).sendKeys(text);\n }",
"public String enterPressed();",
"@Test\n\t @WebTest\n\t public void DemoTest1() throws InterruptedException {\n\t Grid.driver().get(\"http://www.google.com/\");\n\t \n\t TextField field = new TextField(\"id=lst-ib\");\n\n\t //Thread will wait until TextFiled element present in the browser\n\t WebDriverWaitUtils.waitUntilElementIsPresent(field.getLocator());\n\n\t //Search for the string 'SeLion' in the text box\n\t field.type(\"Selenium\\n\");\n\t }",
"@Override\n public void setFocus()\n {\n this.textInput.setFocus();\n }",
"default void interactWith(Key key) {\n\t}",
"public void InsertText(String txt){\n driver.switchTo().frame(driver.findElement(IFRAMEID));\n WebElement inputBox = find(BOXID);\n inputBox.clear();\n inputBox.sendKeys(txt);\n\n }",
"public void type(char c){\n //Only type if a text is selected\n if(currentText != null) {\n //If the character is a newline then a new line should be created and the character and line index's should be updated as appropriate\n if (c == '\\n') {\n currentText = codeWindow.getTextLineController().split(currentText, characterIndex, codeWindow);\n characterIndex = 0;\n lineIndex++;\n }\n //If the character that was typed is any other character then the line will not be split, update it with the typed character and update the character index\n else {\n currentText = codeWindow.getTextLineController().update(currentText, characterIndex, c);\n characterIndex++;\n }\n //After typing the position of the cursor will be different, update the position\n updatePosition();\n }\n }",
"@Override\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\tinput(input.getText().toString());\n\t\t\t\tshow.setText(output.toString());\n\t\t\t}",
"@Override\n\tpublic void okPressed() {\n\t\t_text = _noteTextField.getText();\n\t\tsetReturnCode(OK);\n\t\tclose();\n\t}",
"void showOtherUserTyping();",
"public void click() {\n\t\tSystem.out.println(\"LinuxButton Click\");\r\n\t}",
"@Test\n public void enterTextInSearchField() {\n WebDriverWait wait = new WebDriverWait(driver, 5);\n\n // Afterwards, we need to inform WebDriver to wait until an expected condition is met\n // The ExpectedConditions class supplies many methods for dealing with scenarios that may occur before\n // executing the next Test Step\n }",
"public void type(String locator, String text) {\n waitForElement(locator);\n driver.findElement(By.xpath(locator)).sendKeys(text);\n }",
"public void typeUsername(String text) {\r\n\t\tusernameInput = driver.findElement(usernameSelector);\r\n\t\tusernameInput.sendKeys(text);\r\n\t\t\t\r\n\t}",
"public String submitText();",
"@Override\n\t\t\tpublic void keyPressed(KeyEvent e) {\n\t\t\t\tif (e.getKeyCode() == KeyEvent.VK_ENTER) {\n\t\t\t\t\tsbt_jbt.doClick();\n\t\t\t\t}\n\t\t\t}",
"public void enterText(final By locator, String text){\n WebElement element = findElementClickable(locator);\n\t\ttry {\n \t \t\n if(text.contains(\"@\"))\n {\n element.clear();\n waitForElement(ExpectedConditions.refreshed(ExpectedConditions.visibilityOfElementLocated(locator)));\n String[] parts=text.split(\"@\");\n String selectAll = Keys.chord(Keys.CONTROL,Keys.ALT,\"2\");\n for(int i=0; i<parts.length;i++) {\n \tdriver.findElement(locator).sendKeys(parts[i]);\n\n if(i!=(parts.length-1)) {\n driver.findElement(locator).sendKeys(selectAll);\n\n }\n }\n\n }else {\n driver.findElement(locator).sendKeys(Keys.chord(Keys.CONTROL,\"a\"),text);\n }\n LOGGER.info(\"Step : \"+Thread.currentThread().getStackTrace()[2].getMethodName()+\": Pass\");\n\n }catch(Exception e)\n {\n LOGGER.error(\"Step : \"+Thread.currentThread().getStackTrace()[2].getMethodName()+\": Fail\");\n //e.printStackTrace();\n throw new NotFoundException(\"Exception \"+ e +\" thrown while entering \"+text+\" using locator \"+locator);\n\t\t\n }\n\n\n\n }",
"public void textBoxAction( TextBoxWidgetExt tbwe ){}",
"@Override\n public boolean onEditorAction(TextView v, int actionId, KeyEvent event) {\n if (actionId == EditorInfo.IME_ACTION_DONE) {\n // User has finished entering text\n // Perform the search button click programmatically\n search.performClick();\n // Return true on successfully handling the action\n return true;\n }\n\n // Do not perform any task when user is actually entering text\n // in the editable text view\n return false;\n }",
"public static void pressSubmit(){\n DriverManager.driver.findElement(Constans.SUBMIT_BUTTON_LOCATOR).click();\n }",
"public void inputSearchText(String searchValue) {\n try {\n clickElement(eleToDoSearchInput, \"click to eleToDoSearchInput\");\n sendKeyTextBox(eleToDoSearchInput, searchValue, \"send key to searchTextToDoListPage\");\n Thread.sleep(smallerTimeOut);\n NXGReports.addStep(\"Ending Input Search.\", LogAs.PASSED, null);\n } catch (Exception e) {\n AbstractService.sStatusCnt++;\n NXGReports.addStep(\"Ending Input Search.\", LogAs.FAILED, new CaptureScreen(CaptureScreen.ScreenshotOf.BROWSER_PAGE));\n }\n }",
"private void sendTextInBox() {\n\t\tmodelAdapter.send(textFieldMessage.getText());\n\t textFieldMessage.setText(\"\");\n\t }",
"@Override\n public void send(final CharSequence text) {\n final KeyCharacterMap characterMap = KeyCharacterMap.load(KeyCharacterMap.VIRTUAL_KEYBOARD);\n\n long timeout =\n System.currentTimeMillis()\n + serverInstrumentation.getAndroidWait().getTimeoutInMillis();\n SelendroidLogger.info(\"Using timeout of \" + timeout + \" milli seconds.\");\n\n done = false;\n\n instrumentation.runOnMainSync(new Runnable() {\n public void run() {\n for (int i = 0; i < text.length(); i++) {\n char c = text.charAt(i);\n int code = WebViewKeys.getKeyEventFromUnicodeKey(c);\n if (code != -1) {\n webview.dispatchKeyEvent(new KeyEvent(KeyEvent.ACTION_DOWN, code));\n webview.dispatchKeyEvent(new KeyEvent(KeyEvent.ACTION_UP, code));\n } else {\n KeyEvent[] arr = characterMap.getEvents(new char[] {c});\n if (arr != null) {\n for (int j = 0; j < arr.length; j++) {\n webview.dispatchKeyEvent(arr[j]);\n }\n }\n }\n }\n done = true;\n }\n });\n }",
"public void pressTVButton() {\n System.out.println(\"Home: You must pick an app to show movies.\\n\");\n }",
"private void handleTextInputCallback(TextInputCallback tic)\n throws IOException {\n System.out.print(tic.getPrompt());\n System.out.flush();\n tic.setText((new BufferedReader\n (new InputStreamReader(System.in))).readLine());\n }",
"public void run() {\n try {\n Thread.sleep(100);\n } catch (InterruptedException ex) {\n }\n num3.startEditing();\n num3.requestFocus();\n }",
"public void clickSearchButton() {\n\t\tsearchButton.click();\n\t}",
"@Override\n public void onClick(View v) {\n String inputFieldText = ((TextView) findViewById(R.id.inputField)).getText().toString();\n\n // Set text to custom text, or if custom text is empty set to default hint\n if (inputFieldText.isEmpty()) {\n ((TextView) findViewById(R.id.text)).setText(\"Enter your OWN text!\");\n } else {\n ((TextView) findViewById(R.id.text)).setText(inputFieldText);\n }\n }",
"public static void enterText(By by, String text) {\n driver.findElement(by).sendKeys(text);\n }",
"public static void enterText(By by, String text) {\n driver.findElement(by).sendKeys(text);\n }",
"public void type(String s){\n\t\tif(currentEdit != null){\n\t\t\tint cur = currentEdit.getSelectionStart();\n\t\t\tif(s.equals(\"del\")||s.equals(\"del(\")){\n\t\t\t\tif(cur != 0){\n\t\t\t\t\tcurrentEdit.getText().delete(cur-1, cur);\n\t\t\t\t}\t\t\t\n\t\t\t}else if(s.equals(\"clear\")){\n\t\t\t\tcurrentEdit.setText(\"\");\n\t\t\t}else if(s.equals(\"ENTER\")){\n\t\t\t\tonEnter();\n\t\t\t}else{\n\t\t\t\tcurrentEdit.getText().insert(cur, s);\n\t\t\t}\n\t\t}\n\t}",
"@When(\"^enter any value \\\"([^\\\"]*)\\\" in Sent to field$\")\npublic void enter_any_value_in_Sent_to_field(String arg1) throws Throwable \n{\n\t \n\tActions act = new Actions(driver);\n\t\n\tdriver.findElement(By.xpath(\"//input[@class='select2-search__field']\")).sendKeys(\"naveen\");\n Thread.sleep(2000);\n \n \n driver.findElement(By.xpath(\"//li[contains(text(),'naveen naveen')]\"));\n Thread.sleep(1000); \n \n \n\tact.sendKeys(Keys.RETURN).perform();\n Thread.sleep(3000);\n \n\tdriver.findElement(By.id(\"compose_message_title\")).sendKeys(\"Testing for Sending message\");\n\tThread.sleep(3000);\n\t\n\t\n\tdriver.findElement(By.cssSelector(\".cke_wysiwyg_frame\"));\n\tdriver.switchTo().frame(0);\n\twaitForElementToBeLoad(\"//body\");\n\tdriver.findElement(By.xpath(\"//body\")).click();\n\twaitForElementToBeLoad(\"//body/p\");\n\tdriver.findElement(By.xpath(\"//body/p\")).sendKeys(\"Hello Mr.Navven \\n This is for testing \\n From, \\n Ankita\");\n\tThread.sleep(3000);\n\tdriver.switchTo().defaultContent();\n\tThread.sleep(3000);\n\n \n}",
"@Override\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\tif(parent_frame.getFestival().isLocked()){\n\t\t\t\t\tfeedback_display.append(\"\\tPlease submit after voice prompt has finished.\\n\");\n\t\t\t\t} else {\n\t\t\t\t\tprocessAttempt(input_from_user.getText());\n\t\t\t\t}\n\t\t\t\tinput_from_user.requestFocusInWindow();//gets focus back to the spell here field\n\t\t\t}",
"@Override\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\tString input = e.getActionCommand();\n\t\t\t\tif(start) {\n\t\t\t\t\tdisplay.setText(\"\");\n\t\t\t\t\tstart = false;\n\t\t\t\t}\n\t\t\t\tdisplay.setText(display.getText() + input);\n\t\t\t}",
"protected void beginEnterText()\n\t{\n\t\tdisplayingCaret = true;\n\t\ttext.appendText(\"|\");\n\t\tcaretBlinkTime = 0;\n\t\tclearCharBuffer = true;\n\t}",
"public override void Do()\r\n { \r\n if (TextEditor.UiScope == null)\r\n { \r\n // We dont want to process the input item if the editor has already been detached from its UiScope. \r\n return;\r\n } \r\n\r\n DoTextInput(TextEditor, _text, _isInsertKeyToggled, /*acceptControlCharacters:*/false);\r\n }",
"public static void pressButtonByText(DialogComponentProvider provider, String buttonText,\n\t\t\tboolean waitForCompletion) {\n\t\tpressButtonByText(provider.getComponent(), buttonText, waitForCompletion);\n\t}",
"public void beginPress();",
"@When(\"user clicks on search button and types{string}\")\r\n\tpublic void user_clicks_on_search_button_and_types(String string) {\n\t driver.findElement(By.xpath(\"//*[@id=\\\"myInput\\\"]\")).sendKeys(\"HeadPhone\");\r\n\t}",
"@Override\n public void click(String clickStr) {\n view.append(clickStr);\n view.setSelection(view.getText().length());\n }",
"void urlFieldEnterKeyPressed();",
"void keyPress(int key);",
"@Override\n\tpublic void actionPerformed(ActionEvent arg0) {\n\t\tButtonPress();\n\t}",
"public void testing() {\n System.out.println(\"button pressed!\");\n }",
"public void run() {\n try {\n Thread.sleep(100);\n } catch (InterruptedException ex) {\n }\n num2.startEditing();\n num2.requestFocus();\n }",
"void setFocus();",
"public void actionPerformed(ActionEvent e) {\r\n mode = InputMode.CHG_TEXT;\r\n instr.setText(\"Click one node to change the text on the node.\");\r\n }",
"private void pressUpFromCLI() {\n\t\tupLastPressed = true;\n\t\tif (commandIterator.hasNext()) {\n\t\t\ttextInput.setText(commandIterator.next());\n\t\t}\n\t\tif (downLastPressed) {\n\t\t\ttextInput.setText(commandIterator.next());\n\t\t\tdownLastPressed = false;\n\t\t}\n\t}",
"@Override\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\ttext.setText(ok.getText());\n\t\t\t}",
"public String writeInInputHitEnter(String object, String data) {\n\t\tlogger.debug(\"Writing in text box\");\n\n\t\ttry {\n\n\t\tWebElement ele=\twait.until(explicitWaitForElement(By.xpath(OR.getProperty(object))));\n\t\tele.clear();\n ((JavascriptExecutor) driver).executeScript(\"arguments[0].value = arguments[1]\", ele, data);\n\t\tele.sendKeys(Keys.RETURN);\n\t\t\t\t\n\t\t}catch(TimeoutException ex)\n\t\t\n\t\t{\n\t\t\treturn Constants.KEYWORD_FAIL +\"Cause: \"+ ex.getCause();\n\t\t} catch (Exception e) {\n\t\t\n\t\t\treturn Constants.KEYWORD_FAIL + \" Unable to write \" + e.getLocalizedMessage();\n\t\t}\n\t\treturn Constants.KEYWORD_PASS;\n\n\t}",
"public void clickButton()\n {\n fieldChangeNotify( 0 );\n }",
"public void enterSubText(String value) {\r\n\r\n\t\treportStep(\"About to enter the SubText \" + value, \"INFO\");\r\n\r\n\t\tif(enterTextInChrome(appNotificationSubText,value)) {\r\n\r\n\t\t\treportStep(\"Successfully entered the SubText \" + value, \"PASS\");\r\n\r\n\t\t}else {\r\n\r\n\t\t\treportStep(\"Failed to enter the subText as : \" + value, \"FAIL\");\r\n\r\n\t\t}\r\n\t}",
"void correctKeyPress();",
"@Test\n public void autoCompleteTextView_onDataClickAndCheck() {\n onView(withId(R.id.autoCompleteTextView))\n .perform(typeText(\"S\"), closeSoftKeyboard());\n\n // This is useful because some of the completions may not be part of the View Hierarchy\n // unless you scroll around the list.\n onData(allOf(instanceOf(String.class), is(\"Baltic Sea\")))\n .inRoot(withDecorView(not(is(mActivity.getWindow().getDecorView()))))\n .perform(click());\n\n // The text should be filled in.\n onView(withId(R.id.autoCompleteTextView))\n .check(matches(withText(\"Baltic Sea\")));\n }",
"private final static void pulsaEnter() {\n\t\tSystem.out.println();\n\t\tSystem.out.println(\"\\nPulsa Enter para continuar...\");\n\t\tkb.nextLine();\n\t}",
"public void sendInput(String input) throws IOException {\n\t\tmShell.sendCommand(\"INPUT:\" + mStag + \":\" + input + \":\");\n\t}",
"@Test\n public void researchEditTextInputTest() {\n onView(withId(R.id.network_input_research))\n .perform(typeText(INPUT_TEXT))\n .check(matches(withText(INPUT_TEXT)));\n }",
"public static void pressButtonByText(DialogComponentProvider provider, String buttonText) {\n\t\tpressButtonByText(provider.getComponent(), buttonText, true);\n\t}",
"public void setElementText(WebElement element, String text) {\n wait = new WebDriverWait(eventDriver, 20);\n wait.until(ExpectedConditions.visibilityOf(element));\n element.sendKeys(text);\n }",
"private void userViewStep() {\n textUser.requestFocus();\n textUser.postDelayed(\n new Runnable() {\n public void run() {\n InputMethodManager inputMethodManager = (InputMethodManager) getActivity().getSystemService(Context.INPUT_METHOD_SERVICE);\n inputMethodManager.showSoftInput(textUser, 0);\n }\n }, 200);\n EventBus.getDefault().postSticky(new EventOnboardingChanges(EventOnboardingChanges.ChangeType.REGISTER_CHANGE_TITLE, getResources().getString(R.string.tact_username_title)));\n }",
"public void typePassword(String text) {\r\n\t\tpasswordInput = driver.findElement(passwordSelector);\r\n\t\tpasswordInput.sendKeys(text);\r\n\t\t\r\n\t}",
"private void sendButtonActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_sendButtonActionPerformed\n String str = requestCommand.getText();\n sC.sendCommand(str); \n requestCommand.requestFocus();\n }",
"public void keyDown() {\n\n driver.switchTo().activeElement().sendKeys(Keys.ARROW_DOWN);\n driver.switchTo().activeElement().sendKeys( Keys.ENTER);\n\n\n }"
] | [
"0.69606704",
"0.66325474",
"0.65169686",
"0.64609796",
"0.6457273",
"0.64411044",
"0.6422923",
"0.63510686",
"0.6343789",
"0.6331651",
"0.6329258",
"0.6326656",
"0.63168496",
"0.63057655",
"0.6296814",
"0.6291062",
"0.6253799",
"0.6231428",
"0.6230861",
"0.62234575",
"0.6179091",
"0.61790085",
"0.6165393",
"0.61418724",
"0.61326",
"0.6109441",
"0.60868806",
"0.60450965",
"0.6036843",
"0.60265386",
"0.6025938",
"0.60236967",
"0.60221845",
"0.60156226",
"0.60073876",
"0.6002872",
"0.5989436",
"0.5965782",
"0.59552824",
"0.5946947",
"0.5944342",
"0.59318",
"0.5924326",
"0.59214306",
"0.592097",
"0.59143317",
"0.59084374",
"0.5907058",
"0.5874625",
"0.5869193",
"0.58585757",
"0.5857159",
"0.5851006",
"0.5840721",
"0.5838908",
"0.5838658",
"0.5832238",
"0.5820038",
"0.57983935",
"0.57961494",
"0.57892895",
"0.5784129",
"0.5783073",
"0.5782652",
"0.57805437",
"0.5768734",
"0.5755029",
"0.5755029",
"0.57518595",
"0.5738679",
"0.57301337",
"0.5722837",
"0.5722434",
"0.57138515",
"0.57138264",
"0.57088655",
"0.5708471",
"0.56992733",
"0.5697884",
"0.5679089",
"0.56750953",
"0.5673388",
"0.5663454",
"0.56589717",
"0.5657803",
"0.56540674",
"0.5652673",
"0.5650627",
"0.56479365",
"0.5646276",
"0.5644779",
"0.56416726",
"0.5640617",
"0.56397784",
"0.56361055",
"0.56314844",
"0.5631462",
"0.5630245",
"0.5627688",
"0.56202924",
"0.5617809"
] | 0.0 | -1 |
Consulta si el valor de referencia existe en la lista. | public void removerPorReferencia(int referencia){
if (buscar(referencia)) {
// Consulta si el nodo a eliminar es el pirmero
if (inicio.getEmpleado().getId() == referencia) {
// El primer nodo apunta al siguiente.
inicio = inicio.getSiguiente();
// Apuntamos con el ultimo nodo de la lista al inicio.
ultimo.setSiguiente(inicio);
} else{
// Crea ua copia de la lista.
NodoEmpleado aux = inicio;
// Recorre la lista hasta llegar al nodo anterior
// al de referencia.
while(aux.getSiguiente().getEmpleado().getId() != referencia){
aux = aux.getSiguiente();
}
if (aux.getSiguiente() == ultimo) {
aux.setSiguiente(inicio);
ultimo = aux;
} else {
// Guarda el nodo siguiente del nodo a eliminar.
NodoEmpleado siguiente = aux.getSiguiente();
// Enlaza el nodo anterior al de eliminar con el
// sguiente despues de el.
aux.setSiguiente(siguiente.getSiguiente());
// Actualizamos el puntero del ultimo nodo
}
}
// Disminuye el contador de tama�o de la lista.
size--;
}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public boolean buscar(String referencia){\n Nodo aux = inicio;\r\n // Bandera para indicar si el valor existe.\r\n boolean encontrado = false;\r\n // Recorre la lista hasta encontrar el elemento o hasta \r\n // llegar al final de la lista.\r\n while(aux != null && encontrado != true){\r\n // Consulta si el valor del nodo es igual al de referencia.\r\n if (referencia == aux.getValor()){\r\n // Canbia el valor de la bandera.\r\n encontrado = true;\r\n }\r\n else{\r\n // Avansa al siguiente. nodo.\r\n aux = aux.getSiguiente();\r\n }\r\n }\r\n // Retorna el resultado de la bandera.\r\n return encontrado;\r\n }",
"boolean hasReference();",
"public boolean existe(String direccion) {\n for (int i = 0; i < destinos.size(); i++) {\n if (destinos.get(i).getDireccion().equals(direccion)) {\n return true;\n }\n }\n return false;\n }",
"boolean references(ResourceElement<S, V> referred, ResourceElement<?, ?> refers);",
"public boolean existeListaProduto_ReferenteA() {\n\t\t\treturn listaprodutoReferenteA!= null;\n\t\t}",
"boolean hasHadithReferenceNo();",
"public int getPosicion(String referencia) throws Exception{\n if (buscar(referencia)) {\r\n // Crea una copia de la lista.\r\n Nodo aux = inicio;\r\n // COntado para almacenar la posición del nodo.\r\n int cont = 0;\r\n // Recoore la lista hasta llegar al nodo de referencia.\r\n while(referencia != aux.getValor()){\r\n // Incrementa el contador.\r\n cont ++;\r\n // Avansa al siguiente. nodo.\r\n aux = aux.getSiguiente();\r\n }\r\n // Retorna el valor del contador.\r\n return cont;\r\n // Crea una excepción de Valor inexistente en la lista.\r\n } else {\r\n throw new Exception(\"Valor inexistente en la lista.\");\r\n }\r\n }",
"public static int searchref(String ref) {\n String target = ref.toUpperCase() ;\n existebis = 0;\n Cars xx = new Cars();\n for (int i = 0; i < listcars.size(); i++) {\n xx = listcars.get(i);\n String record = xx.getReference().toUpperCase() ;\n if (record.equals(target)) {\n existebis = 1;\n break;\n\n\n } else {\n existebis = 0;\n }\n }\n\n return existebis;}",
"private boolean checkPreviousRefs(String ref) {\n\t\t// Prevent stack overflow, when an unlock happens from inside here:\n\t\tList<String> checked = (List<String>) threadLocalManager.get(TwoFactorAuthenticationImpl.class.getName());\n\t\tif (checked == null) {\n\t\t\tchecked = new ArrayList<String>();\n\t\t\tthreadLocalManager.set(TwoFactorAuthenticationImpl.class.getName(), checked);\n\t\t}\n\t\tif (checked.contains(ref)) {\n\t\t\treturn false; // This allows the required entity to load.\n\t\t}\n\t\ttry {\n\t\t\tchecked.add(ref);\n\t\t\treturn findSiteId(ref);\n\t\t} finally {\n\t\t\tif(!checked.isEmpty()) {\n\t\t\t\tchecked.remove(checked.size()-1);\n\t\t\t}\n\t\t}\n\t}",
"boolean hasRef();",
"@Override\n\tpublic boolean equals(Object object) {\n\t\tif (!(object instanceof EmpleadoReferencia)) {\n\t\t\treturn false;\n\t\t}\n\t\tEmpleadoReferencia other = (EmpleadoReferencia) object;\n\t\tif ((this.referenciaid == null && other.referenciaid != null)\n\t\t\t\t|| (this.referenciaid != null && !this.referenciaid.equals(other.referenciaid))) {\n\t\t\treturn false;\n\t\t}\n\t\treturn true;\n\t}",
"public boolean list_exists(Context context) {\n File file = context.getFileStreamPath(\"ingredientes\");\n if (file == null || !file.exists()) {\n return false;\n }\n return true;\n }",
"public boolean doesGoToReferenceExist(String id)\n {\n IDNode node = (IDNode)idReferences.get(id); \n return node.isThereInternalLinkGoTo();\n }",
"boolean Exists(int value) {\n\t\tNode curr = head;\n\t\twhile (curr != null) {\n\t\t\tif (curr.data == value)\n\t\t\t\treturn true;\n\t\t\tcurr = curr.next;\n\t\t}\n\t\treturn false;\n\t}",
"public Set<MReferencia> mReferenciasYaUsadas(Concepto referenciante,Concepto referenciado,List<Referencia> referencias){\r\n\t\tSet<MReferencia> mReferencias=new HashSet<MReferencia>();\r\n\t\tfor (Referencia ref : referencias) {\r\n\t\t\tif( (ref.getReferenciante().equals(referenciante)) &&\r\n\t\t\t\t(ref.getReferenciado().equals(referenciado))) \r\n\t\t\t\t\t{\r\n\t\t\t\tmReferencias.add(ref.getmReferencia());\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn mReferencias;\r\n\t}",
"protected boolean isReferenced() {\r\n return mReferenced || mUsers.size() > 0;\r\n }",
"private boolean existeMatrizReferencial(ConcursoPuestoAgr concursoPuestoAgr) {\r\n\t\tString query =\r\n\t\t\t\" SELECT * FROM seleccion.matriz_ref_conf \" + \" where id_concurso_puesto_agr = \"\r\n\t\t\t\t+ concursoPuestoAgr.getIdConcursoPuestoAgr() + \" and tipo = 'GRUPO' \";\r\n\t\treturn seleccionUtilFormController.existeNative(query);\r\n\t}",
"public static boolean exists(){\n \t\treturn everbie != null;\n \t}",
"private boolean isReferenced(String item) {\n\t\tif (varReferences.contains(item)) return true;\n\t\telse return false;\n\t}",
"public boolean doesIDExist(String id)\n {\n return idReferences.containsKey(id);\n }",
"public void editarPorReferencia(String referencia, String valor){\r\n // Consulta si el valor existe en la lista.\r\n if (buscar(referencia)) {\r\n // Crea ua copia de la lista.\r\n Nodo aux = inicio;\r\n // Recorre la lista hasta llegar al nodo de referencia.\r\n while(aux.getValor() != referencia){\r\n aux = aux.getSiguiente();\r\n }\r\n // Actualizamos el valor del nodo\r\n aux.setValor(valor);\r\n }\r\n }",
"private boolean urlInLinkedList(URL url, LinkedList<String> set){\n boolean returnBoolean = false;\n\n for (String setItem : set){\n if (NetworkUtils.urlHostPathMatch(NetworkUtils.makeURL(setItem), url)) {\n// Log.v(\"DLAsync.urlInHashSet\", \" just found \" + url.toString() + \" in \" + set.toString());\n returnBoolean = true;\n }\n }\n return returnBoolean;\n }",
"public boolean isRefCodeExists(String refCode) {\n\t\t// TODO Auto-generated method stub\n\t\t// doGet(request, response);\n\t\tPreparedStatement pst;\n\t\tResultSet rs;\n\t\tboolean exists = false;\n\t\ttry {\n\t\t\tpst = RegDataBaseManager.startDatabaseOperation(SELECT_USER);\n\t\t\tpst.setString(1, refCode);\n\t\t\trs = RegDataBaseManager.getDatabaseOprationResult(pst, SELECT_USER);\n\t\t\tif(rs.next()){\n\t\t\t\texists = true;\n\t\t\t}\n\t\t} catch (SQLException e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t}\n\t\treturn exists;\n\t}",
"boolean getExists();",
"private boolean isReference()\n {\n return countAttributes(REFERENCE_ATTRS) > 0;\n }",
"private boolean check_only_call_relatives(Element element){\n\t\tArrayList<Element> relatives = new ArrayList<Element>();\n\t\tfor(Element elem_called : element.getRefFromThis()){\n\t\t\t//if they are brothers\n\t\t\tif(element.getParentName() != null && elem_called.getParentName() != null && element.getParentName().equals(elem_called.getParentName())){\n\t\t\t\trelatives.add(elem_called);\n\t\t\t}\n\t\t\t//if they are son - father\n\t\t\tif(element.getParentName() != null && element.getParentName().equals(elem_called.getIdentifier())){\n\t\t\t\trelatives.add(elem_called);\n\t\t\t}\t\t\t\n\t\t}\n\t\tif (relatives.size() == element.getRefFromThis().size()){\n\t\t\treturn true;\n\t\t}\n\t\treturn false;\n\t}",
"public boolean isSetReferer() {\n return this.referer != null;\n }",
"private static boolean assetHasLocalReference(MD5Key id) {\n \n \t\treturn getLocalReference(id) != null;\n \t}",
"boolean hasAccountLink();",
"public java.lang.String getReferenciado();",
"boolean checkIfPathExists(List<WayPointDto> path);",
"protected boolean Exists()\n\t{\n\t\tif (identity<1) return false;\n\t\tNodeReference nodeReference = getNodeReference();\n\t\treturn (nodeReference.exists() || nodeReference.hasSubnodes());\n\t}",
"public boolean isSetIs_referral() {\n return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __IS_REFERRAL_ISSET_ID);\n }",
"boolean hasFeedItemSetLink();",
"boolean isSetRef();",
"private boolean existsRec(Node<T> nodo, T key) {\r\n\t\tif (nodo.getData().equals(key)) {// Si existe el nodo en el arbol\r\n\t\t\treturn true;\r\n\t\t} else if (nodo.getChildren() != null) {// Si tiene hijos\r\n\t\t\tList<Node<T>> lista = nodo.getChildren();// Los hijos\r\n\t\t\tboolean comprobacion = false;\r\n\t\t\tfor (int i = 1; i <= lista.size(); i++) {\r\n\t\t\t\tcomprobacion = existsRec(lista.get(i), key);// Recursividad\r\n\t\t\t\tif (comprobacion == true) // Se encontro\r\n\t\t\t\t\treturn true;\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn false; // No se encontro\r\n\t}",
"boolean hasExists();",
"boolean hasDidUri();",
"public Cliente[] findWhereReferenciaEquals(String referencia) throws ClienteDaoException;",
"public boolean isReference() {\n AnnotatedBase comp = m_item.getSchemaComponent();\n return comp instanceof IReference && ((IReference)comp).getRef() != null;\n }",
"private boolean isFollowing(User user, String target)\n{\n \n DefaultListModel following = user.getFollowings();\n if (following.contains(target))\n {\n return true;\n }\n return false;\n}",
"public boolean getExists();",
"public boolean completelink() throws Exception {\r\n\t\t\ttry {\r\n\t\t\t\telement = driver.findElement(completelink);\r\n\t\t\t\tflag = element.isDisplayed() && element.isEnabled();\r\n\t\t\t\tAssert.assertTrue(flag, \"Complete link is not dispalyed and enabled\");\r\n\t\t\t} catch (Exception e) {\r\n\t\t\t\tthrow new Exception(\"USER NAME NOT FOUND:: \"+e.getLocalizedMessage());\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\treturn flag;\r\n\t\t}",
"boolean hasHadithBookUrl();",
"public boolean contains(Item item){\n if(isEmpty()) throw new NoSuchElementException(\"Failed to perfrom contains because the DList instance is empty!\");\n for(Node temp = first.next; temp.next!=null; temp=temp.next)\n if(temp.data.equals(item)) return true;\n return false; \n }",
"boolean hasAccountLinkId();",
"public void removerPorReferencia(String referencia){\n if (buscar(referencia)) {\r\n // Consulta si el nodo a eliminar es el pirmero\r\n if (inicio.getValor() == referencia) {\r\n // El primer nodo apunta al siguiente.\r\n inicio = inicio.getSiguiente();\r\n } else{\r\n // Crea ua copia de la lista.\r\n Nodo aux = inicio;\r\n // Recorre la lista hasta llegar al nodo anterior \r\n // al de referencia.\r\n while(aux.getSiguiente().getValor() != referencia){\r\n aux = aux.getSiguiente();\r\n }\r\n // Guarda el nodo siguiente del nodo a eliminar.\r\n Nodo siguiente = aux.getSiguiente().getSiguiente();\r\n // Enlaza el nodo anterior al de eliminar con el \r\n // sguiente despues de el.\r\n aux.setSiguiente(siguiente); \r\n }\r\n // Disminuye el contador de tamaño de la lista.\r\n tamanio--;\r\n }\r\n }",
"public boolean hasReferences() {\n\t\treturn this.refCounter > 0;\n\t}",
"public boolean hasAtLeastOneReference(Project project);",
"public boolean isSetUrlValue()\r\n {\r\n synchronized (monitor())\r\n {\r\n check_orphaned();\r\n return get_store().find_attribute_user(URLVALUE$2) != null;\r\n }\r\n }",
"public boolean contains(String value){\n if (value == null)\n return false;\n int index = clamp(value);\n if (linkedListStrings[index] == null)\n return false;\n else\n return linkedListStrings[index].contains(value);\n\n\n }",
"public boolean containRelationship(ArrayList<Relationship> inputList)\r\n\t{\r\n\t\tfor(Relationship inputRE: inputList)\r\n\t\t{\r\n\t\t\tif (!listRelationship.contains(inputRE)) return false;\r\n\t\t}\r\n\t\treturn true;\r\n\t}",
"public boolean exist() {\n\t\treturn false;\n\t}",
"public boolean referencesHaveCondition(ResourceCondition condition) throws DependencyConditionException {\n\t\tfor (DependencyElement refEl : references) {\n\t\t\t// Check if the condition evaluates to false\n\t\t\ttry {\n\t\t\t\tif (!condition.evaluate(refEl.resource)) { \n\t\t\t\t\treturn false;\n\t\t\t\t}\n\t\t\t} catch (DependencyException de) {\n\t\t\t\tthrow new DependencyConditionException(refEl.resource, condition, de.getMessage());\n\t\t\t}\n\t\t}\n\t\treturn true;\n\t}",
"public boolean exists(ListNode node){\n\t\tif(firstNode == null) return false;\n\t\tListNode temp = firstNode;\n\t\twhile(temp != null){\n\t\t\tif(temp.equals(node)) return true;\n\t\t\ttemp = temp.getNextNode();\n\t\t}\n\t\treturn false;\n\t}",
"boolean hasList();",
"private boolean hasLinkToEntidad(Entidadrol entidadrol) {\n\t\tif(entidadrol.getEntidadid() != null) {\n\t\t\treturn true;\n\t\t}\n\t\treturn false;\n\t}",
"public boolean contains(E obj)\n {\n Node m = head;\n while( m.getNext() != null)\n {\n m = m.getNext();\n if(m.getValue().equals(obj))\n {\n return true; \n }\n }\n return false;\n }",
"private boolean checkListino() {\n /* variabili e costanti locali di lavoro */\n boolean ok = false;\n Date dataInizio;\n Date dataFine;\n AddebitoFissoPannello panServizi;\n\n try { // prova ad eseguire il codice\n dataInizio = this.getDataInizio();\n dataFine = this.getDataFine();\n panServizi = this.getPanServizi();\n ok = panServizi.checkListino(dataInizio, dataFine);\n } catch (Exception unErrore) { // intercetta l'errore\n Errore.crea(unErrore);\n } // fine del blocco try-catch\n\n /* valore di ritorno */\n return ok;\n }",
"public final boolean isReferencedAtMostOnce() {\n return this.getReferences(false, true).size() == 0 && this.getReferences(true, false).size() <= 1;\r\n }",
"boolean exists();",
"boolean exists();",
"public boolean hasExternalAddressbooks() throws RemoteException;",
"public boolean hasResource(org.semanticwb.model.Resource value)\r\n {\r\n boolean ret=false;\r\n if(value!=null)\r\n {\r\n ret=getSemanticObject().hasObjectProperty(swb_hasPTResource,value.getSemanticObject());\r\n }\r\n return ret;\r\n }",
"public boolean complete() {\n return previousLink().isPresent();\n }",
"public boolean pertinencia(Tipo valor) //100%\n {\n if(this.conjunto.contains(valor))\n {\n return true;\n }\n else\n {\n return false;\n }\n }",
"boolean hasAddressList();",
"private boolean hasIndexLink()\r\n \t{\r\n \t\treturn xPathQuery(XPath.INDEX_LINK.query).size() > 0;\r\n \t}",
"public boolean containsByReference(ParameterReference ref);",
"public boolean isVehiclesListLinkPathPresent() {\r\n\t\treturn isElementPresent(vehicleLinkPath, SHORTWAIT);\r\n\t}",
"public void VerifyReferencePOField(){\r\n\t\tString countriesReferencePO=\"Germany,UK,Denmark\";\r\n\t\tclass Local {};\r\n\t\tReporter.log(\"TestStepComponent\"+Local.class.getEnclosingMethod().getName());\r\n\t\tReporter.log(\"TestStepInput:-\"+\"NA\");\r\n\t\tReporter.log(\"TestStepOutput:-\"+\"NA\");\r\n\t\tReporter.log(\"TestStepExpectedResult:- Comments or ReferencePOField or both should be present based on country\");\r\n\r\n\t\ttry{\r\n\t\t\tif(countriesReferencePO.contains(countries.get(countrycount))){\r\n\t\t\t\tSystem.out.println(\"Reference Po field is present as \"+getPropertyValue(locator_split(\"txtCheckoutReferencePO\"), \"name\"));\r\n\t\t\t\tReporter.log(\"PASS_MESSAGE:- Reference Po field is present as \"+getPropertyValue(locator_split(\"txtCheckoutReferencePO\"), \"name\"));\r\n\t\t\t}else{\r\n\t\t\t\tReporter.log(\"PASS_MESSAGE:- Reference PO field will not be present for this counry\");\r\n\t\t\t}\r\n\r\n\t\t}catch(Exception e){\r\n\t\t\tReporter.log(\"FAIL_MESSAGE:- Reference PO field is not present\");\r\n\t\t\tthrow new NoSuchElementException(\"The element with\"\r\n\t\t\t\t\t+ elementProperties.getProperty(\"txtCheckoutCommentssection\")\r\n\t\t\t\t\t+ elementProperties.getProperty(\"txtCheckoutReferencePO\")\r\n\t\t\t\t\t+ \" not found\");\r\n\r\n\t\t}\r\n\t}",
"Object getTargetexists();",
"@Override\n\tpublic boolean existe(String cpf) throws CampoObrigatorioException,\n\t\t\tClienteNaoEncontradoException, CPFInvalidoException, SQLException {\n\t\tfor(ClienteFisico c : set){\n\t\t\tif(cpf.equals(c.getCpf())){\n\t\t\t\treturn true;\n\t\t\t}\n\t\t}\n\t\t\n\t\treturn false;\n\t}",
"boolean hasCustomerClientLink();",
"public boolean hasRelation(String name) {\n \treturn relations.containsKey(name);\n }",
"protected static boolean hasEntryInList(String key, String entry) {\n String entries = getSPreference(key);\n if (TextUtils.isEmpty(entries))\n return false;\n\n for (String e: entries.split(\":\"))\n if (e.equalsIgnoreCase(entry))\n return true;\n\n return false;\n }",
"private boolean findExist(UsersRobots usersRobots){\n List<UsersRobots> result = (List<UsersRobots>) entityManager.createQuery(\"SELECT ur FROM UsersRobots ur where ur.idUser = :idUser and ur.idRobot = :idRobot\")\n .setParameter(\"idUser\",usersRobots.getIdUser())\n .setParameter(\"idRobot\",usersRobots.getIdRobot())\n .getResultList();\n if(result.size() > 0){\n return true;\n }\n return false;\n }",
"boolean checkIfPathExists(String startCityUID, List<WayPointDto> path);",
"boolean exists(Curso curso) throws BusinessException;",
"public boolean contains (Object obj) {\n\t\tfor (ListNode p = myHead; p != null; p = p.myNext) {\n\t\t\tif (obj.equals (p.myItem)) {\n\t\t\t\treturn true;\n\t\t\t}\n\t\t}\n\t\treturn false;\n\t}",
"public boolean contains (Object obj) {\n\t\tfor (ListNode p = myHead; p != null; p = p.myNext) {\n\t\t\tif (obj.equals (p.myItem)) {\n\t\t\t\treturn true;\n\t\t\t}\n\t\t}\n\t\treturn false;\n\t}",
"public boolean contains (Object obj) {\n\t\tfor (ListNode p = myHead; p != null; p = p.myNext) {\n\t\t\tif (obj.equals (p.myItem)) {\n\t\t\t\treturn true;\n\t\t\t}\n\t\t}\n\t\treturn false;\n\t}",
"public boolean contains (Object obj) {\n\t\tfor (ListNode p = myHead; p != null; p = p.myNext) {\n\t\t\tif (obj.equals (p.myItem)) {\n\t\t\t\treturn true;\n\t\t\t}\n\t\t}\n\t\treturn false;\n\t}",
"private boolean checkIfContactKeysExists() {\n String contactKeys = SharedPrefsUtils.getKey(context, R.string.travel_contact_key_names);\n String contactKeysExist = sharedPref.getString(contactKeys, \"false\");\n //TODO: catch empty list case\n if (contactKeysExist == \"false\") {\n return false;\n }\n return true;\n }",
"public boolean hasLink() {\n return !links.isEmpty();\n }",
"private static boolean checkDependencies(ArrayList listeFileXml, XmlDocument fXml) {\r\n \r\n // liste des dpendences\r\n Element root = fXml.getDocument().getRootElement(); // Get the root element\r\n List listeDependencies = root.getChildren(DEPENDENCIES_TAG);\r\n \r\n if (listeDependencies != null) {\r\n \r\n Iterator iterDependencies = listeDependencies.iterator();\r\n while (iterDependencies.hasNext()) {\r\n \r\n Element eltDependencies = (Element) iterDependencies.next();\r\n List listeDependencyFiles = eltDependencies.getChildren(SETTINGSFILE_TAG);\r\n Iterator iterDependencyFiles = listeDependencyFiles.iterator();\r\n \r\n while (iterDependencyFiles.hasNext()) {\r\n \r\n Element eltDependencyFile = (Element) iterDependencyFiles.next();\r\n String name = eltDependencyFile.getAttributeValue(SETTINGSFILENAME_ATTRIB);\r\n \r\n boolean found = false;\r\n for (int i = 0; i < listeFileXml.size(); i++) {\r\n File f = (File) xmlFiles.get(i);\r\n \r\n if (f.getName().equals(name)) {\r\n found = true;\r\n i = listeFileXml.size();\r\n }\r\n }\r\n \r\n if (found == false) {\r\n return false;\r\n }\r\n } // while\r\n \r\n } // while\r\n \r\n } // if\r\n \r\n return true;\r\n }",
"boolean existsPath(String requestedUrl);",
"private boolean estaVisitada(String cadena) {\n\t\tif(lCasillasVisitadas.contains(cadena)){\n\t\t\treturn true;\n\t\t}\n\t\telse{\n\t\t\treturn false;\n\t\t}\n\t}",
"protected boolean resourceExists() {\n\t\tIWorkspace workspace = ResourcesPlugin.getWorkspace();\n\t\tif (workspace == null)\n\t\t\treturn false;\n\t\treturn RodinDB.getTarget(workspace.getRoot(), this.getPath()\n\t\t\t\t.makeRelative(), true) != null;\n\t}",
"public boolean satisfyingReferences() {\n\t\tfor (DependencyElement refEl : references) {\n\t\t\tif (!refEl.after(this)) {\n\t\t\t\treturn false;\n\t\t\t}\n\t\t}\n\t\treturn true;\n\t}",
"public void setReferenciado(java.lang.String referenciado);",
"public boolean containsValue(V value) {\r\n for (Node datum : data) {\r\n if (datum != null) {\r\n Node targetNode = datum;\r\n while (targetNode != null) {\r\n if (targetNode.value == value || targetNode.value.equals(value)) {\r\n return true;\r\n }\r\n targetNode = targetNode.next;\r\n }\r\n\r\n }\r\n }\r\n return false;\r\n }",
"public boolean canBeReferencedByIDREF() {\n/* 171 */ return false;\n/* */ }",
"public boolean isResourceExisting(String getRES){\n\t\tString resName=\"\";\n\t\t\n\t\tString WEBDOCS = serverConfig.ServerPaths.WEBDOCS;\n\t\tString defaultPage = serverConfig.ServerPaths.defaultPage;\n\t\t\n\t\tif(getRES.equalsIgnoreCase(\"/\") && defaultPage.length()>0)\n\t\t\tresName=WEBDOCS+platformSpecificLocator(\"/\" + defaultPage);\n\t\telse if(getRES.equalsIgnoreCase(\"/\") && defaultPage.length()==0)\n\t\t\tresName=WEBDOCS+platformSpecificLocator(\"/\");\n\t\telse \n\t\t\tresName=WEBDOCS+platformSpecificLocator(getRES);\n\t\t\n\t\tresourceHandler.ResReader resRedr = new resourceHandler.ResReader();\n\t\ttry {\n\t\t\tif(resRedr.isResourceExisting(resName)==true)\n\t\t\t\treturn true;\n\t\t} catch (IOException e) {\n\t\t\tSystem.out.println(\"Error generated while checking existence of Resource requested.\");\n\t\t\te.printStackTrace();\n\t\t}\n\t\tSystem.out.println(\"Error404:: \" + resName + \" doesn't exist.\");\n\t\treturn false;\n\t}",
"public boolean isSetRoadwayRef()\r\n {\r\n synchronized (monitor())\r\n {\r\n check_orphaned();\r\n return get_store().find_attribute_user(ROADWAYREF$16) != null;\r\n }\r\n }",
"public boolean contains(T item){\n if (head.next == tail && tail.prev == head){\n return false;\n }\n else {\n MyDoubleNode<T> counter = head.next;\n boolean shouldContinue = true;\n while (shouldContinue){\n if (counter.next != tail){\n if (counter.data.equals(item)){\n return true;\n }\n counter = counter.next;\n shouldContinue = true;\n }\n else{\n if (counter.data.equals(item)){\n return true;\n }\n shouldContinue = false;\n }\n }\n return false;\n }\n }",
"public boolean validarDireccion() {\n\t\treturn direccion != null;\n\t}",
"private boolean addCellReferenceIfFound()\n {\n logger.trace(\" aCRIF: Trying to match \\\"{}\\\".\", myCellReference);\n if (myCellReference != null)\n {\n if (CELL_REF_PATTERN.matcher(myCellReference).matches())\n {\n CellRef ref;\n\n logger.trace(\" aCRIF: Cell Reference is \\\"{}\\\".\", myCellReference);\n if (mySheetName != null)\n ref = new CellRef(SheetNameFormatter.format(mySheetName) + \"!\" + myCellReference);\n else\n ref = new CellRef(myCellReference);\n if (myDefaultValue != null)\n {\n logger.trace(\" aCRIF: Default value found is \\\"{}\\\".\", myDefaultValue);\n ref.setDefaultValue(myDefaultValue);\n }\n\n logger.trace(\" aCRIF: Cell Reference detected: {}\", ref.formatAsString());\n // Don't add duplicates.\n if (!myCellReferences.contains(ref))\n {\n logger.trace(\" aCRIF: Not in list, adding ref: row={}, col={}, rowAbs={}, colAbs={}.\",\n ref.getRow(), ref.getCol(), ref.isRowAbsolute(), ref.isColAbsolute());\n myCellReferences.add(ref);\n }\n }\n else if (mySheetName == null)\n {\n // Allow non-String tokens to be a part of the sheet name.\n // This allows sheet names constructed for implicit cloning\n // purposes to be recognized in JETT formulas, e.g.\n // $[SUM(${dvs.name}$@i=n;l=10;v=s;r=DNE!B3)]\n // Else the Excel Operator \"=\" will make this reference the\n // shortened \"DNE!B3\" erroneously.\n return true;\n }\n }\n mySheetName = null;\n myCellReference = null;\n myDefaultValue = null;\n return false;\n }",
"public boolean contains(K value)\n {\n\tArrayList<SkipListNode<K>> pred = findPredecessors(value); //Predecessors\n\tSkipListNode<K> predNode = pred.get(0); //Predecessor at level 0\n\n\t//If the node is not the last in the list and its data is equal to value, contains is true. \n\t//If the node is the last in the list or the value after predNode does not equal value, contains must be false\n\treturn (predNode.next(0) != null) && (predNode.next(0).data().compareTo(value) == 0);\n }",
"public boolean exists()\n\t{\n\n\t\treturn true;\n\t}",
"public boolean isLink(String str) { return link_to_line.keySet().contains(str); }"
] | [
"0.71279395",
"0.62003297",
"0.5917916",
"0.5872636",
"0.5809864",
"0.57500637",
"0.57447314",
"0.57212746",
"0.570159",
"0.5669855",
"0.5668727",
"0.5661067",
"0.56603515",
"0.55543494",
"0.55367607",
"0.5523209",
"0.5510329",
"0.54768664",
"0.5474081",
"0.54164284",
"0.54109085",
"0.53969914",
"0.5372371",
"0.5332635",
"0.53239596",
"0.52994204",
"0.5297575",
"0.5288139",
"0.52698255",
"0.5260999",
"0.5257774",
"0.52336574",
"0.52207935",
"0.5219367",
"0.5199205",
"0.5197205",
"0.51947397",
"0.51887625",
"0.5188026",
"0.516065",
"0.5160535",
"0.5160531",
"0.5151338",
"0.5150523",
"0.51498556",
"0.51353514",
"0.5135226",
"0.5133221",
"0.511933",
"0.51140064",
"0.51053786",
"0.5105247",
"0.5089425",
"0.5088495",
"0.5086987",
"0.5082569",
"0.5076634",
"0.50741535",
"0.50737983",
"0.50712574",
"0.506479",
"0.506479",
"0.5052733",
"0.5050814",
"0.5042332",
"0.50318784",
"0.5018902",
"0.5010227",
"0.50073546",
"0.49957323",
"0.4991238",
"0.49810407",
"0.49787202",
"0.4970468",
"0.4962797",
"0.49607268",
"0.49595472",
"0.4956654",
"0.49486774",
"0.4938701",
"0.4938701",
"0.4938701",
"0.49380586",
"0.4934722",
"0.49340338",
"0.4933377",
"0.49240375",
"0.49218473",
"0.4918567",
"0.49167266",
"0.49070448",
"0.49043524",
"0.49031162",
"0.49011445",
"0.48977572",
"0.48964688",
"0.48960847",
"0.48887682",
"0.48824558",
"0.4880818",
"0.48766944"
] | 0.0 | -1 |
Verifica si la lista contiene elementoa. | public void listar(){
if (!esVacia()) {
// Crea una copia de la lista.
NodoEmpleado aux = inicio;
// Posicion de los elementos de la lista.
int i = 0;
System.out.print("-> ");
// Recorre la lista hasta llegar nuevamente al incio de la lista.
do{
// Imprime en pantalla el valor del nodo.
System.out.print(i + ".[ " + aux.getEmpleado() + " ]" + " -> ");
// Avanza al siguiente nodo.
aux = aux.getSiguiente();
// Incrementa el contador de la posi�n.
i++;
}while(aux != inicio);
}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public static boolean hasElements() {\n return content.size() > 0;\n }",
"boolean hasElement();",
"public static boolean estaVacia(ArrayList lista){\n if(lista.isEmpty()){\n System.out.println(\"No hay usuarios u objetos registrados por el momento\");\n return true;\n }\n else{\n return false;\n }\n }",
"public static boolean checkElement(Element element) \n\t{\n\t\treturn LIST_OF_ELEMENT.containsValue(element);\n\t}",
"@Override\n public boolean isEmpty() {\n if(first == null){ //if first element does not exist, the whole is empty\n return true;\n }\n else{\n return false; //if first element exist, list is not empty\n }\n }",
"boolean hasList();",
"@Override\r\n\tpublic boolean getElemento(T elemento) {\n\t\treturn false;\r\n\t}",
"public boolean contains(T elem) {\n return list.contains(elem);\n }",
"@Override\n\tpublic boolean estaElemento(String elemento) {\n\t\treturn false;\n\t}",
"public boolean isEmpty()\n {\n return elements.isEmpty();\n }",
"protected boolean checkEmptyList(){\n boolean emptyArray = true;\n String empty= alertList.get(AppCSTR.FIRST_ELEMENT).get(AppCSTR.NAME);\n if(!empty.equals(\"null\") && !empty.equals(\"\")) {\n emptyArray = false;\n }\n return emptyArray;\n }",
"boolean hasNextElement();",
"public boolean isEmpty() {\n return elements.isEmpty();\n }",
"@Override\r\n\tpublic boolean buscar(T elemento) {\n\t\treturn false;\r\n\t}",
"public boolean isEmpty() {\n\t\treturn elements.isEmpty();\n\t}",
"private boolean isListValid()\n {\n boolean isValid = true;\n Collection<RecognizedElement> elementsList = tree.getChildren();\n for (Iterator<RecognizedElement> iterator = elementsList.iterator(); iterator.hasNext();)\n {\n RecognizedElement recognizedElement = (RecognizedElement) iterator.next();\n if (isSpreadsheet)\n {\n if (recognizedElement instanceof Style || recognizedElement instanceof Regex)\n {\n isValid = false;\n break;\n }\n }\n else\n {\n if (recognizedElement instanceof Column)\n {\n isValid = false;\n break;\n }\n }\n }\n return isValid;\n }",
"public boolean isEmpty() {\n\n return elements.isEmpty();\n }",
"public boolean canAdd() {\r\n int temp = 0;\r\n for (int i = 0; i < elem.length; i++) {\r\n if (elem[i] == null) {\r\n temp++;\r\n }\r\n }\r\n if (temp > 1) {\r\n return true;\r\n } else {\r\n return false;\r\n }\r\n }",
"public boolean existeElemento(T dato) {\n\t\t// crea nodo igual al primer elemento\n\t\tNodeTabla<K, T> nodo = primerElemento;\n\n\t\t// itera los elementos hasta que se acaben o encuentre el elemento\n\t\twhile (nodo != null && !nodo.getElemento().equals(dato)) {\n\t\t\tnodo = nodo.getSiguiente();\n\t\t}\n\n\t\t// retorna true si encontro el elemento\n\t\treturn nodo != null;\n\t}",
"public boolean hasNext() {\n\t\t\treturn !elements.isEmpty();\n\t\t}",
"public boolean checkListIsEmpty(List<WebElement> eleList) {\n if (eleList.size() == 0) {\n return true;\n }\n return false;\n }",
"@Override\r\n\tpublic boolean hasMoreElements() {\n\t\treturn it.hasNext();\r\n\t}",
"public ArrayList<String> store_present_element(ArrayList<String> oblist){\n\t\tArrayList<String> obj_list = new ArrayList<String>();\n\t\tint result = 0;\n\t\tint obj_index = 1;\n\t\tfor(int i=0; i<oblist.size(); i++){\n\t\t\tString xpathobj = oblist.get(i);\n\t\t\tList<WebElement> list = returnWebelements(xpathobj);\n\t\t\tif(list.size()>0){\n\t\t\t\tresult = 1;\n\t\t\t\tSystem.out.println(xpathobj+\" element is present!! \"+obj_index);\n\t\t\t\tobj_list.add(xpathobj);\n\t\t\t}\n\t\t\tobj_index++;\n\t\t}\n\t\tif(result!=1){\n\t\t\tprintlist(oblist);\n\t\t\tthrow new ObjectNotFoundException(\"none of the element is found from above pattern..\");\n\t\t}\n\t\tcheck_multiple_pattern(obj_list);\n\t\treturn obj_list;\n\t}",
"public boolean validate() {\n\n\t\tNoLista p = lista.validate();\n\t\tif(p==null){\n\t\t\treturn true; \n\t\t}else {\n\t\t\twhile(p!=null) {\n\t\t\t\tfor (int i = 0; i < ignore.length; i++) {\n\t\t\t\t\tif(ignore[i].equals(p.getInfo())) {\n\t\t\t\t\t\tretirar(p.getInfo());\n\t\t\t\t\t\taddList(p.getInfo());\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tp=p.getProximo();\n\t\t\t}\n\t\t\t\n\t\t\tif(this.lista.getPrimeiro()==null) {\n\t\t\t\treturn true;\n\t\t\t}else {\n\t\t\t\treturn false;\n\t\t\t}\n\t\t\t\n\t\t}\n\t}",
"public boolean contains(Object o) {\n\n Object value = elements.get(o);\n return value != null;\n }",
"public boolean hasNextElement();",
"public boolean contains(E element) {\r\n return items.contains(element);\r\n }",
"public boolean isEmpty()\n {\n return ((elements == null) || elements.isEmpty());\n }",
"boolean hasMatchedElements();",
"boolean isListRemainingEmpty();",
"public boolean isEmpty()\n\t{\n\t\treturn m_elements.isEmpty();\n\t}",
"public boolean hasElements(List<T> items) {\n \tif(stack.size() != items.size()) //if items and the stack have different sizes\n \t\treturn false;\n \t\n \tfor(int i = 0; i < stack.size(); i++){\n \t\tif(!items.get(i).equals(stack.get(i))){ //check that the elements appear in the same order \n \t\t\treturn false;\n \t\t}\n \t}\n \treturn true;\n }",
"public boolean contains(E e) {\n\t /*\n\t * Add code here\n\t */\n\t\t for(int c=0;c<num_elements;c++){\n\t\t\t if(elements[c]==e){\n\t\t\t\t return true;\n\t\t\t }\n\t\t }\n\t return false;\n\t }",
"public boolean contains(ElementType element){\n for(ElementType e:this){\n if(e.equals(element)){\n return true;\n }\n }\n return false;\n }",
"public boolean isFull()\n { \n return count == elements.length; \n }",
"@Override\r\n\tpublic boolean contains(T element) {\n\t\treturn false;\r\n\t}",
"boolean isSetListOfServiceElements();",
"boolean hasTotalElements();",
"private static boolean checkOrderList() {\n if (size != MainGUI.orderList.size()) {\n size = MainGUI.orderList.size();\n return true;\n }\n\n return false;\n }",
"boolean isElement(Object object);",
"static boolean elements(PsiBuilder b, int l) {\n if (!recursion_guard_(b, l, \"elements\")) return false;\n boolean r;\n Marker m = enter_section_(b);\n r = element(b, l + 1);\n r = r && elements_1(b, l + 1);\n r = r && elements_2(b, l + 1);\n exit_section_(b, m, null, r);\n return r;\n }",
"private static void checkPerticularElementExitInLinkedList() {\n\t\tLinkedList<Integer> list = new LinkedList<Integer>();\n\t\tlist.add(10);\n\t\tlist.add(20);\n\t\tlist.add(30);\n\t\tlist.add(40);\n\t\tlist.add(50);\n\t\tSystem.out.println(\"LinkedList is : \" + list);\n\t\tString result = \"\";\n\t\tfor(Integer i:list) {\n\t\t\tresult = (list.contains(60))?\"true\":\"false\";\n\t\t}\n\t\tSystem.out.println(result);\n\t}",
"public boolean elementDirect(Element elem) {\r\n\r\n boolean test = false;\r\n\r\n for (int i = 0; i < element.size(); i++) {\r\n if (element.get(i).getNom().equals(elem.getNom())) {\r\n test = true;\r\n }\r\n }\r\n return test;\r\n }",
"protected boolean isElementPresent(By element) {\n\t\t \n if (driver.findElements(element).isEmpty()) {\n \treturn false;\n } else {\n \treturn true;\n }\n }",
"private boolean checkforCreating(Object element) {\n\t\tif (element == null) {\n\t\t\treturn false;\n\t\t}\n\t\tif (element instanceof Entity) {\n\t\t\tEntity entity = (Entity) element;\n\t\t\tObject entitryValue = entity.getValue(\"autocreate\");\n\t\t\tif (entitryValue != null && entitryValue instanceof Boolean) {\n\t\t\t\treturn (Boolean) entitryValue;\n\t\t\t}\n\t\t}\n\t\tif (element instanceof List<?>) {\n\t\t\tList<?> collection = (List<?>) element;\n\t\t\tfor (Object item : collection) {\n\t\t\t\tif (checkforCreating(item)) {\n\t\t\t\t\treturn true;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn false;\n\t}",
"private boolean checkListino() {\n /* variabili e costanti locali di lavoro */\n boolean ok = false;\n Date dataInizio;\n Date dataFine;\n AddebitoFissoPannello panServizi;\n\n try { // prova ad eseguire il codice\n dataInizio = this.getDataInizio();\n dataFine = this.getDataFine();\n panServizi = this.getPanServizi();\n ok = panServizi.checkListino(dataInizio, dataFine);\n } catch (Exception unErrore) { // intercetta l'errore\n Errore.crea(unErrore);\n } // fine del blocco try-catch\n\n /* valore di ritorno */\n return ok;\n }",
"private boolean seleccionarItemEnListado(){\n\t\t\n\t\tint indice = this.getUltIdDoc();\n\t\tif (indice > -1){ //solo si se eligió un doc\n\t\t\tif ((indice+1) > tablaDocs.getItemCount()){ //se pasa de la cantidad de elemento en la lista, poner el de mas arriba en su lugar\n\t\t\t\tthis.setUltIdDoc(tablaDocs.getItemCount()-1);\n\t\t\t\tindice = this.getUltIdDoc(); \n\t\t\t}\n\t\t\ttablaDocs.setSelection(indice); \n\t\t\tlistaDocumentos.setSelection(indice);\n\t\t}\n\t\treturn true;\n\t}",
"public static boolean empty() {\n\n if (list.size() != 0){\n return false;\n }\n return true;\n }",
"@Test\n public void nelioMuodostuu() {\n ArrayList lista=this.tetrimino.palautaKuvio();\n assertEquals(lista.size(), 4);\n \n }",
"@Test\n public void existsItem(){\n List <Character> list = new ArrayList<>();\n list.add('a');\n list.add('b');\n list.add('c');\n\n assertTrue(list.contains('b'));\n }",
"public boolean contains ( Object o ){\n\n \tboolean doesContain = false;\n\n \tfor(int i = 0; i < list.size(); i++){\n\n if(list.get(i).equals(o)){\n doesContain = true;\n }\n\n }\n\n \treturn doesContain;\n\n }",
"@Test\n public void getBonosTest() {\n List<BonoEntity> lista = bonoLogic.getBonos();\n Assert.assertEquals(data.size(), lista.size());\n for (BonoEntity entity : lista) {\n if(!data.contains(entity))\n fail(\"Ambas listas deberían contener los mismos bonos\");\n }\n }",
"public boolean hasMoreElements() {\r\n \t\tif(numItems == 0 || currentObject == numItems) {\r\n \t\t\treturn false;\r\n \t\t}\r\n \t\treturn true;\r\n \t}",
"public boolean hasElement(String name) {\n return elements.has(name);\n }",
"public boolean isAdded(String element_id, String list_id) throws Exception{\n boolean isAdded = false;\n try {\n this.openConnection();\n PreparedStatement st = this.getConnection().prepareStatement(\"SELECT COUNT(entry_id) FROM VideogameEntries WHERE videogame_id=? AND videogameList_id=?\");\n st.setString(1, element_id);\n st.setString(2,list_id);\n ResultSet rs = st.executeQuery();\n rs.next();\n isAdded = rs.getBoolean(1);\n } catch (Exception e) {\n throw new Exception(\"Method isAdded VideogameList \" + e.getMessage());\n } finally {\n try {\n this.closeConnection();\n } catch (Exception e) {\n throw new Exception(\"Method isAdded VideogameList \" + e.getMessage());\n }\n }\n return isAdded;\n }",
"@Override\n\tpublic boolean isEmpty() {\n\t\treturn list.isEmpty();\n\t}",
"@Override\n\tpublic boolean isEmpty() {\n\t\treturn list.isEmpty();\n\t}",
"public boolean hasNext(){\n if(index < size && listI.get(index) != null){\n return true;\n }\n return false;\n }",
"@Override\n\t\tpublic boolean hasMoreElements() {\n\t\t\treturn cursor != size();\n\t\t}",
"public boolean isEmpty(){\n\n \treturn list.size() == 0;\n\n }",
"public boolean contains(E elem) {\n return indexOf(elem) != -1;\n }",
"public boolean hayEnemigos() {\n\t\tif (ListaDeOleadasPorNivel.isEmpty())\n\t\t\treturn false;\n\t\telse\n\t\t\treturn true;\n\t}",
"public boolean isEmpty()\n\t{\n\t\treturn list.isEmpty();\n\t}",
"public static boolean validaContinuaLista(Conjunto nome) {\r\n\t\tVisao.continuaLista();\r\n\t\tchar resposta = Leitura.lerChar();\r\n\t\tif (resposta != 'S')\r\n\t\t\tVisao.nomesCadastrados(nome.getQtdNomes());\r\n\t\telse\r\n\t\t\t// ZERAR NOMES PARA OUTRA LISTA\r\n\t\t\tnome.zerarLista();\r\n\t\treturn ((resposta == 'S') ? true : false);\r\n\t}",
"boolean isEmpty(int list) {\n\t\treturn m_lists.getField(list, 0) == -1;\n\t}",
"@Test\n\tpublic void testIncluye() {\n\t\tassertFalse(l.incluye(0));\n\t\t\n\t\t//Test de busqueda sobre el primer elemento\n\t\tl.agregar(0, 0);\n\t\tassertTrue(l.incluye(0));\n\t\tassertFalse(l.incluye(1));\n\t\t\n\t\t//Test con mas elementos\n\t\tl.agregar(1, 1);\n\t\tl.agregar(2, 2);\n\t\tassertTrue(l.incluye(1));\n\t\tassertFalse(l.incluye(4));\n\t\t\n\t}",
"@Override\n public boolean isEmpty()\n {\n return list.size()<1;\n }",
"public boolean isEmpty() {\n return elements == 0;\n }",
"@Override\n public boolean contiene(T dato) {\n return this.buscar(dato) != null;\n }",
"@Test\r\n\tvoid testContains() {\r\n\t\tSortedList list = new SortedList(\"List\");\r\n\t\tlist.insert(toDoItem1);\r\n\t\tlist.insert(toDoItem2);\r\n\t\tlist.insert(toDoItem3);\r\n\t\tlist.insert(toDoItem4);\r\n\r\n\t\tif (list.contains(\"Item 1\") != true) {\r\n\t\t\tfail(\"Failed to find \\\"Item 1\\\"\");\r\n\t\t}\r\n\t\tif (list.contains(\"Item 2\") != true) {\r\n\t\t\tfail(\"Failed to find \\\"Item 2\\\"\");\r\n\t\t}\r\n\t\tif (list.contains(\"Item 3\") != true) {\r\n\t\t\tfail(\"Failed to find \\\"Item 3\\\"\");\r\n\t\t}\r\n\t\tif (list.contains(\"Item 4\") != true) {\r\n\t\t\tfail(\"Failed to find \\\"Item 4\\\"\");\r\n\t\t}\r\n\t}",
"public boolean isEmpty() {\n\t\treturn elements == 0;\n\t}",
"public boolean isEmpty() // true if list is empty\r\n\t{\r\n\t\treturn (first == null);\r\n\t}",
"public boolean contains(T anEntry) {\n\t\tfor(int i=0; i<numberOfElements; i++) {\n\t\t\tif(list[i].equals(anEntry)) {\n\t\t\t\treturn true;\n\t\t\t}\n\t\t}\n\t\treturn false;\n\t}",
"public boolean isEmpty(){\n\t\treturn firstNode == null; //return true if List is empty\n\t}",
"public boolean checkIfElementsArePresentAndDisplayed(By locator) {\n boolean isDisplayed = true;\n List<WebElement> listOfElements = findListOfElements(locator);\n if (listOfElements != null && !listOfElements.isEmpty()) {\n for (WebElement element : listOfElements) {\n if (element.getSize() == null && !element.isDisplayed()) {\n isDisplayed = false;\n }\n }\n }\n return isDisplayed;\n }",
"public void testIsEmpty() {\r\n assertTrue( list.isEmpty());\r\n list.add(\"A\");\r\n assertFalse(list.isEmpty());\r\n }",
"public synchronized boolean isEmpty(){\n return list.isEmpty();\n }",
"public boolean hasChildren(Object element) {\n\t\treturn false;\r\n\t}",
"@Override\n public boolean hasNext() {\n return numeroDiNodiAncoraVisitabili>0;\n }",
"@MethodContract(post = @Expression(\"elementExceptions.empty\"))\n public final boolean isEmpty() {\n return $elementExceptions.isEmpty();\n }",
"@Override\n\tpublic boolean isEmpty()\n\t{\n if (list.isEmpty())\n {\n return true;\n } \n else\n {\n return false;\n }\n\t}",
"public boolean checkAllToDoIsDelete() {\n if (!checkListIsEmpty(eleToDoRowList) || !checkListIsEmpty(eleToDoCompleteRowList)) {\n return false;\n }\n return true;\n }",
"public boolean isEmpty(){\n for(int i = 0; i < arrayList.length; i++) {\n if (arrayList[i] != null)\n return false;\n }\n return true;\n }",
"public boolean verifyitemaddedtowishlist()\n\t{\n\t\tboolean s=driver.findElement(By.xpath(\"//a[@href='/black-white-diamond-heart']\")).getText().contains(\"Black & White Diamond Heart\");\n\t\treturn s;\n\t\t \n\t}",
"public boolean isInList();",
"public boolean isEmpty() {\n\t\treturn list.isEmpty();\n\t}",
"public static boolean completeCheck(ArrayList<Integer> aList) {\n\t\tif (aList.size() == Utils.SIZE) {\n\t\t\treturn true;\n\t\t} else {\n\t\t\treturn false;\n\t\t}\n\t}",
"@Test\n\tpublic void validarPeticionListAllRegistros() {\n\t\t// Arrange\n\t\tint cantidadRegistros = 1;\n\t\t// Act\n\t\tList<Registro> registroRecuperados = (List<Registro>) registroService.listAllRegistro();\n\t\tint cantidadRegistrosRecuperdos = registroRecuperados.size();\n\t\t// Assert\n\t\tAssert.assertEquals(\"Valor recuperado es igual\", cantidadRegistrosRecuperdos, cantidadRegistros);\n\t}",
"public boolean contains(Object o) {\n for(int i = 0; i < size; i++) {\n if(list[i].equals(o)) return true;\n }\n return false;\n }",
"public boolean contains(Object elem);",
"public boolean contains(Item item){\n if(isEmpty()) throw new NoSuchElementException(\"Failed to perfrom contains because the DList instance is empty!\");\n for(Node temp = first.next; temp.next!=null; temp=temp.next)\n if(temp.data.equals(item)) return true;\n return false; \n }",
"public boolean isEmpty(){\n\t\tif(list.isEmpty()){\n\t\t\treturn true;\n\t\t} else {\n\t\t\treturn false;\n\t\t}\n\t}",
"public boolean hasNextElement() {\n return resultsEnumeration.hasMoreElements();\n }",
"public boolean hasNext() {\r\n if (current + 1 >= elem.length) {\r\n current = 0;\r\n }\r\n return elem[current + 1] != null;\r\n }",
"private boolean contieneCarrera(List<ProyectoCarreraOferta> carrerasProyecto, ProyectoCarreraOferta carreraProyecto) {\r\n boolean var = false;\r\n for (ProyectoCarreraOferta pco : carrerasProyecto) {\r\n if (pco.getCarreraId().equals(carreraProyecto.getCarreraId())) {\r\n var = true;\r\n }\r\n }\r\n return var;\r\n }",
"public boolean isEmpty() {\n return list.isEmpty();\n }",
"public boolean isFull() {\n int size = 0;\n for (int i = 0; i < items.length; i++) {\n if (items[i] != null) {\n size++;\n }\n }\n return size == items.length;\n }",
"public boolean contains(E element);",
"@Override\n public boolean contains(final Object element) {\n return this.lastIndexOf(element) != -1;\n }",
"@Override\r\n\tpublic boolean isEmpty() {\n\t\treturn data != null && data.list != null && data.list.isEmpty();\r\n\t}",
"public boolean contains(Object element) {\n\n\t\tif (element == null) {\n\t\t\tthrow new IllegalArgumentException(\n\t\t\t\t\t\"ArrayList cannot contain a null element.\");\n\t\t}\n\t\tfor (int i = 0; i < this.size; i++) {\n\t\t\tObject object = this.storedObjects[i];\n\t\t\tif (object.equals(element)) {\n\t\t\t\treturn true;\n\t\t\t}\n\t\t}\n\t\treturn false;\n\t}"
] | [
"0.69502705",
"0.6873899",
"0.67608035",
"0.67026",
"0.63796026",
"0.63504237",
"0.634891",
"0.631938",
"0.6318883",
"0.6274072",
"0.62715834",
"0.62693685",
"0.625475",
"0.62503743",
"0.62196857",
"0.6205687",
"0.6197783",
"0.61938626",
"0.61850375",
"0.6183553",
"0.6175208",
"0.61692667",
"0.61651546",
"0.6154583",
"0.61507046",
"0.61223745",
"0.6093529",
"0.60929686",
"0.60835147",
"0.6078876",
"0.6077865",
"0.6064016",
"0.60399204",
"0.60184854",
"0.59910274",
"0.5985672",
"0.5982822",
"0.59612113",
"0.5953667",
"0.59407395",
"0.59347403",
"0.59206903",
"0.59094334",
"0.59073204",
"0.5905737",
"0.5902951",
"0.5897483",
"0.5897155",
"0.58952945",
"0.5890969",
"0.5880401",
"0.5876788",
"0.58688736",
"0.5863391",
"0.58614993",
"0.5846899",
"0.5846899",
"0.5846837",
"0.5843435",
"0.584246",
"0.582481",
"0.58207005",
"0.58193785",
"0.5817294",
"0.58158386",
"0.58157843",
"0.5806529",
"0.5805688",
"0.58047825",
"0.58015436",
"0.5793974",
"0.578996",
"0.578727",
"0.57872325",
"0.5773985",
"0.57693726",
"0.5765554",
"0.5756798",
"0.5735371",
"0.5730768",
"0.5728218",
"0.5725006",
"0.5722562",
"0.5722255",
"0.5720228",
"0.5714855",
"0.5713827",
"0.5711673",
"0.57104367",
"0.569907",
"0.5695523",
"0.56952703",
"0.5693829",
"0.5691128",
"0.56888676",
"0.56878895",
"0.56869745",
"0.5684611",
"0.5678359",
"0.5674696",
"0.5667141"
] | 0.0 | -1 |
just for testing providing unique id | @UniqueID("ProvidedID")
@org.testng.annotations.Test
private void uniqueIdAnnotation() {
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@Test\n public void getId() {\n UUID id = UUID.randomUUID();\n User u = new User(id.toString(), name, mail, pass, address, gender);\n Assert.assertEquals(u.getId(), id);\n }",
"String getUniqueId();",
"String getUniqueID();",
"String uniqueId();",
"public String getUniqueID();",
"public String getUniqueID ( ) { return _uniqueID; }",
"String getExistingId();",
"private UniqueIdentifier(){\n\t\t\n\t}",
"UUID getUniqueId();",
"protected int getUniqueID() {\n\t\treturn uniqueID;\n\t}",
"public String getUniqueId() {\n return _uniqueId;\n }",
"public void test_getId() {\n assertEquals(\"'id' value should be properly retrieved.\", id, instance.getId());\n }",
"private String creatUniqueID(){\n long ID = System.currentTimeMillis();\n return Long.toString(ID).substring(9,13);\n }",
"private static int generateId() {\n\t\treturn ++sId;\n\t}",
"private Long createId() {\n return System.currentTimeMillis() % 1000;\n }",
"@Test\n public void testGenerateIdExpectedValue() {\n Monkey monkey = new Monkey();\n int id = monkey.generateIdRefactored(100);\n assertEquals(id,223592);\n }",
"@Test\r\n\tpublic void testGetId() {\r\n\t\tassertEquals(1, breaku1.getId());\r\n\t\tassertEquals(2, externu1.getId());\r\n\t\tassertEquals(3, meetingu1.getId());\r\n\t\tassertEquals(4, teachu1.getId());\r\n\t}",
"String getId();",
"String getId();",
"String getId();",
"String getId();",
"String getId();",
"String getId();",
"String getId();",
"String getId();",
"String getId();",
"String getId();",
"String getId();",
"String getId();",
"String getId();",
"String getId();",
"String getId();",
"String getId();",
"String getId();",
"String getId();",
"String getId();",
"String getId();",
"String getId();",
"String getId();",
"String getId();",
"String getId();",
"String getId();",
"String getId();",
"String getId();",
"String getId();",
"String getId();",
"String getId();",
"String getId();",
"String getId();",
"String getId();",
"String getId();",
"String getId();",
"String getId();",
"String getId();",
"String getId();",
"String getId();",
"String getId();",
"String getId();",
"String getId();",
"String getId();",
"private int nextValidID() {\n return nextId++;\n }",
"private Uniqueid() {\n\n }",
"UUID id();",
"Id createId();",
"public int getUniqueID() { \n return -1;\n }",
"@Test\n public void idTest() {\n // TODO: test id\n }",
"@Test\n public void idTest() {\n // TODO: test id\n }",
"public abstract long id();",
"@Override\n\tpublic void setUniqueId(int id) {}",
"int nextId();",
"private String generateUniqueIdString() {\r\n return TimeBasedUUID.getUUIDAsString();\r\n }",
"public void testGetUniqueID_fixture24_1()\n\t\tthrows Exception {\n\t\tFolder fixture = getFixture24();\n\n\t\tAbstractUniqueID result = fixture.getUniqueID();\n\n\t\t// add additional test code here\n\t\tassertNotNull(result);\n\t\tassertEquals(null, result.getId());\n\t}",
"String id();",
"String id();",
"String id();",
"String id();",
"String id();",
"String id();",
"String id();",
"String id();",
"String id();",
"String id();",
"String id();",
"String id();",
"String id();",
"String id();",
"String id();",
"String id();",
"String id();",
"String id();",
"String id();",
"String id();",
"String id();",
"String id();",
"String id();",
"String id();",
"@Test\n\tpublic void test() {\n\t\tlong firstID = UIDGen.getInstance().getNextId();\n\t\tint n = 100;\n\t\tfor (int i = 0; i < n; i++) {\n\t\t\tUIDGen.getInstance().getNextId();\n\t\t}\n\t\tlong currentID = UIDGen.getInstance().getNextId();\n\t\tassertEquals(currentID, firstID + n + 1);\n\n\t\t// expect a IDInvalidException exception for using and\n\t\t// external id that has already been used\n\t\tlong exteranlId = currentID;\n\t\tThrowable caught = null;\n\t\ttry {\n\t\t\tUIDGen.getInstance().considerExternalId(exteranlId);\n\t\t} catch (Throwable t) {\n\t\t\tcaught = t;\n\t\t}\n\t\tassertNotNull(caught);\n\t\tassertSame(IDInvalidException.class, caught.getClass());\n\n\t\t// push an external id that is not used and expect no exception\n\t\texteranlId = currentID + 2;\n\t\ttry {\n\t\t\tUIDGen.getInstance().considerExternalId(exteranlId);\n\t\t} catch (Throwable t) {\n\t\t\tfail();\n\t\t}\n\n\t\t// expect an exception as we put the same id again\n\t\texteranlId = currentID;\n\t\tcaught = null;\n\t\ttry {\n\t\t\tUIDGen.getInstance().considerExternalId(exteranlId);\n\t\t} catch (Throwable t) {\n\t\t\tcaught = t;\n\t\t}\n\t\tassertNotNull(caught);\n\t\tassertSame(IDInvalidException.class, caught.getClass());\n\n\t\t// must skip currentID + 2 as it was defined as an external id\n\t\tassertEquals(UIDGen.getInstance().getNextId(), currentID + 1);\n\t\tassertEquals(UIDGen.getInstance().getNextId(), currentID + 3);\n\t}",
"@Test\n public void testIdDoesNotExist() throws Exception {\n\n // login with sufficient rights\n shop.login(admin.getUsername(), admin.getPassword());\n\n // generate ID not assigned to any transaction in the shop\n int nonExistentId = generateId(shop.getCreditsAndDebits(null, null).stream()\n .map(BalanceOperation::getBalanceId)\n .collect(Collectors.toList()));\n\n // if ID does not exist -1 is returned\n assertEquals(-1, shop.receiveCashPayment(nonExistentId, 10), 0.001);\n }",
"String idProvider();",
"UUID getId();"
] | [
"0.75900364",
"0.7557617",
"0.7541907",
"0.7524614",
"0.73770064",
"0.7264464",
"0.72113603",
"0.719268",
"0.7189055",
"0.70735",
"0.7031054",
"0.69630057",
"0.69547725",
"0.69409245",
"0.69000155",
"0.68828654",
"0.6882027",
"0.6875157",
"0.6875157",
"0.6875157",
"0.6875157",
"0.6875157",
"0.6875157",
"0.6875157",
"0.6875157",
"0.6875157",
"0.6875157",
"0.6875157",
"0.6875157",
"0.6875157",
"0.6875157",
"0.6875157",
"0.6875157",
"0.6875157",
"0.6875157",
"0.6875157",
"0.6875157",
"0.6875157",
"0.6875157",
"0.6875157",
"0.6875157",
"0.6875157",
"0.6875157",
"0.6875157",
"0.6875157",
"0.6875157",
"0.6875157",
"0.6875157",
"0.6875157",
"0.6875157",
"0.6875157",
"0.6875157",
"0.6875157",
"0.6875157",
"0.6875157",
"0.6875157",
"0.6875157",
"0.6875157",
"0.6875157",
"0.6875157",
"0.68667614",
"0.686584",
"0.68655926",
"0.6864483",
"0.6864418",
"0.6846359",
"0.6846359",
"0.6843503",
"0.683802",
"0.683531",
"0.68258965",
"0.68234354",
"0.6810042",
"0.6810042",
"0.6810042",
"0.6810042",
"0.6810042",
"0.6810042",
"0.6810042",
"0.6810042",
"0.6810042",
"0.6810042",
"0.6810042",
"0.6810042",
"0.6810042",
"0.6810042",
"0.6810042",
"0.6810042",
"0.6810042",
"0.6810042",
"0.6810042",
"0.6810042",
"0.6810042",
"0.6810042",
"0.6810042",
"0.6810042",
"0.67990077",
"0.6798749",
"0.67984927",
"0.677801"
] | 0.70821095 | 9 |
just for testing providing parameters | @Ignore
@org.testng.annotations.Test(dataProvider = "dp")
private void dataProviderWithoutKey(String param_0, String param_1) {
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"protected void setupParameters() {\n \n \n\n }",
"public void checkParameters() {\n }",
"public void testgetParameter() throws Exception {\n\r\n\t}",
"@Test\n\tpublic void testGetRequestParameter() {\n\t}",
"@Test\n\tpublic void testParameters() {\n\t\tassertEquals(par, myReply.getParameters());\n\t}",
"private void validateInputParameters(){\n\n }",
"public void getParameters(Parameters parameters) {\n\n }",
"@Test\n public void verifyParametersInput() {\n // act\n book.setISBN(isbn);\n book.setAuthors(array);\n book.setPublisher(publisher);\n // verify\n verify(book).setISBN(isbn);\n verify(book).setAuthors(array);\n verify(book).setPublisher(publisher);\n }",
"@Override\n\t@Ignore\n\t@Test\n\tpublic void testLaunchParameters() throws Throwable {\n\t}",
"@Override\n\tprotected void initParams() {\n\t\t\n\t}",
"public abstract Instances _getTestingFromParams(String params);",
"@Test\n\tpublic void correctParameters() {\n\t\tassertEquals(startTime, circle.startTime);\n\t\tassertEquals(duration, circle.duration);\n\t\tassertEquals(type, circle.type);\n\t\tassertEquals(height, circle.height, 0);\n\t}",
"@Test\r\n \tpublic void testParameters() {\n \t\tParameters params = (Parameters) filter.getParameters();\r\n \t\t\t\t\t\t\r\n \t\tassertEquals(params.unescapeSource, true);\r\n \t\tassertEquals(params.trimLeading, true);\r\n \t\tassertEquals(params.trimTrailing, true);\r\n \t\tassertEquals(params.preserveWS, true);\r\n \t\tassertEquals(params.useCodeFinder, false);\r\n \t\tassertEquals(\t\t\t\t\r\n \t\t\t\t\"#v1\\ncount.i=2\\nrule0=%(([-0+#]?)[-0+#]?)((\\\\d\\\\$)?)(([\\\\d\\\\*]*)(\\\\.[\\\\d\\\\*]*)?)[dioxXucsfeEgGpn]\\n\" +\r\n \t\t\t\t\"rule1=(\\\\\\\\r\\\\\\\\n)|\\\\\\\\a|\\\\\\\\b|\\\\\\\\f|\\\\\\\\n|\\\\\\\\r|\\\\\\\\t|\\\\\\\\v\\nsample=\\nuseAllRulesWhenTesting.b=false\", \r\n \t\t\t\tparams.codeFinderRules);\r\n \t\t\t\t\t\t\t\t\t\r\n \t\t// Check if defaults are set\r\n \t\tparams = new Parameters();\r\n \t\tfilter.setParameters(params);\r\n \t\t\r\n \t\tparams.columnNamesLineNum = 1;\r\n \t\tparams.valuesStartLineNum = 1;\r\n \t\tparams.detectColumnsMode = 1;\r\n \t\tparams.numColumns = 1;\r\n \t\tparams.sendHeaderMode = 1;\r\n \t\tparams.trimMode = 1;\r\n \t\tparams.fieldDelimiter = \"1\";\r\n \t\tparams.textQualifier = \"1\";\r\n \t\tparams.sourceIdColumns = \"1\";\r\n \t\tparams.sourceColumns = \"1\";\r\n \t\tparams.targetColumns = \"1\";\r\n \t\tparams.commentColumns = \"1\";\r\n \t\tparams.preserveWS = true;\r\n \t\tparams.useCodeFinder = true;\r\n \t\t\r\n \t\tparams = getParameters();\r\n \t\t\r\n \t\tassertEquals(params.fieldDelimiter, \"1\");\r\n \t\tassertEquals(params.columnNamesLineNum, 1);\r\n \t\tassertEquals(params.numColumns, 1);\r\n \t\tassertEquals(params.sendHeaderMode, 1);\r\n \t\tassertEquals(params.textQualifier, \"1\");\r\n \t\tassertEquals(params.trimMode, 1);\r\n \t\tassertEquals(params.valuesStartLineNum, 1);\r\n \t\tassertEquals(params.preserveWS, true);\r\n \t\tassertEquals(params.useCodeFinder, true);\r\n \t\t\r\n \t\t// Load filter parameters from a file, check if params have changed\r\n //\t\tURL paramsUrl = TableFilterTest.class.getResource(\"/test_params1.txt\");\r\n //\t\tassertNotNull(paramsUrl); \r\n \t\t\r\n \r\n \t\ttry {\r\n \t\tString st = \"file:\" + getFullFileName(\"test_params1.txt\");\r\n \t\tparams.load(new URI(st), false);\r\n \t} catch (URISyntaxException e) {\r\n \t}\r\n \r\n \t\t\r\n \t\tassertEquals(\"2\", params.fieldDelimiter);\r\n \t\tassertEquals(params.columnNamesLineNum, 2);\r\n \t\tassertEquals(params.numColumns, 2);\r\n \t\tassertEquals(params.sendHeaderMode, 2);\r\n \t\tassertEquals(\"2\", params.textQualifier);\r\n \t\tassertEquals(params.trimMode, 2);\r\n \t\tassertEquals(params.valuesStartLineNum, 2);\r\n \t\tassertEquals(params.preserveWS, false);\r\n \t\tassertEquals(params.useCodeFinder, false);\r\n \t\t\r\n \t\t// Save filter parameters to a file, load and check if params have changed\r\n \t\tURL paramsUrl = TableFilterTest.class.getResource(\"/test_params2.txt\");\r\n \t\tassertNotNull(paramsUrl);\r\n \t\t\r\n \t\tparams.save(paramsUrl.getPath());\r\n \t\t\r\n \t\t// Change params before loading them\r\n \t\tparams = (Parameters) filter.getParameters();\r\n \t\tparams.fieldDelimiter = \"3\";\r\n \t\tparams.columnNamesLineNum = 3;\r\n \t\tparams.numColumns = 3;\r\n \t\tparams.sendHeaderMode = 3;\r\n \t\tparams.textQualifier = \"3\";\r\n \t\tparams.trimMode = 3;\r\n \t\tparams.valuesStartLineNum = 3;\r\n \t\tparams.preserveWS = true;\r\n \t\tparams.useCodeFinder = true;\r\n \t\t\r\n \t\tparams.load(Util.toURI(paramsUrl.getPath()), false);\r\n \t\t\r\n \t\tassertEquals(params.fieldDelimiter, \"2\");\r\n \t\tassertEquals(params.columnNamesLineNum, 2);\r\n \t\tassertEquals(params.numColumns, 2);\r\n \t\tassertEquals(params.sendHeaderMode, 2);\r\n \t\tassertEquals(params.textQualifier, \"2\");\r\n \t\tassertEquals(params.trimMode, 2);\r\n \t\tassertEquals(params.valuesStartLineNum, 2);\r\n \t\tassertEquals(params.preserveWS, false);\r\n \t\tassertEquals(params.useCodeFinder, false);\r\n \t\t\r\n \t\t// Check if parameters type is controlled\r\n \t\t\r\n \t\tfilter.setParameters(new net.sf.okapi.filters.plaintext.base.Parameters());\r\n \t\tInputStream input = TableFilterTest.class.getResourceAsStream(\"/csv_test1.txt\");\r\n \t\ttry {\r\n \t\t\tfilter.open(new RawDocument(input, \"UTF-8\", locEN));\r\n \t\t\tfail(\"OkapiBadFilterParametersException should've been trown\");\r\n \t\t}\r\n \t\tcatch (OkapiBadFilterParametersException e) {\r\n \t\t}\r\n \t\t\r\n \t\tfilter.close();\r\n \t\r\n \t\tfilter.setParameters(new net.sf.okapi.filters.table.csv.Parameters());\r\n \t\tinput = TableFilterTest.class.getResourceAsStream(\"/csv_test1.txt\");\r\n \t\ttry {\r\n \t\t\tfilter.open(new RawDocument(input, \"UTF-8\", locEN));\r\n \t\t}\r\n \t\tcatch (OkapiBadFilterParametersException e) {\r\n \t\t\tfail(\"OkapiBadFilterParametersException should NOT have been trown\");\r\n \t\t}\r\n \t\t\tfilter.close();\r\n \t}",
"void setParameters() {\n\t\t\n\t}",
"@Parameters({\"name\", \"lastName\"})\n @Test\n public void test1(String name, String lastName){\n System.out.println(\"Name is \"+ name);\n System.out.println(\"Last name is \"+ lastName);\n }",
"@Test\n\tpublic void Account_test() { Using HamCrest \t\t\n\t\t// Exercise code to run and test\n\t\t//\n\t\tmiCuenta.setHolder(this.arg1);\n\t\tString resHolder = miCuenta.getHolder(); \n\t\t//\n\t\tmiCuenta.setBalance(this.arg2);\n\t\tint resBalance = miCuenta.getBalance(); \n\t\t//\n\t\tmiCuenta.setZone(this.arg3);\n\t\tint resZone = miCuenta.getZone(); \n\t\t\t\t\t\t\n\t\t// Verify\n\t\tassertThat(this.arg1, is(resHolder));\n\t\tassertThat(this.arg2, is(resBalance)); \n\t\tassertThat(this.arg3, is(resZone)); \n\t}",
"private Params()\n {\n }",
"@Test (dataProvider= \"My data provider\")\r\n\tpublic void TestCalcParamitarized(String in1,String Op, String in2,String Expec){ //.... 1- Parameterized test method -Define method input parameters-\r\n\t\tCalc(in1, Op, in2);\r\n\t\tassertResult(Expec);\t\t\r\n\t}",
"public void getParameters(Parameters parameters) {\n\n\t}",
"@Test\n void getArgString() {\n }",
"@Test\n public void testValidParameters() {\n Map params = new HashMap();\n params.put(\"provider_url\", \"http://localhost:8080/v1/oauth/tokens\");\n params.put(\"grant_type\", \"password\");\n params.put(\"client_id\", \"test_client_1\");\n params.put(\"provider_id\", \"local\");\n params.put(\"basic_username\", \"test_client_1\");\n params.put(\"basic_password\", \"test_secret\");\n params.put(\"username\", \"test_client_1\");\n params.put(\"password\", \"test_secret\");\n PasswordGrant instance = new PasswordGrant();\n Boolean expResult = true;\n Boolean result = instance.validParameters(params);\n assertEquals(expResult, result);\n \n }",
"@Test\n public void MyTest() {\n System.out.println(\"Parameterized Number is : \" + inputNumber);\n System.out.println(\"Expected Result is : \" + expectedResult);\n }",
"@Override\r\n\t\t\tpublic void test() {\n\t\t\t}",
"@Override\r\n public void setParameter(String parameters) {\r\n // dummy\r\n }",
"@Test\r\n public void requestParameters() throws Exception {\r\n final ModuleURN instanceURN = new ModuleURN(PROVIDER_URN, \"mymodule\");\r\n final String requestParm = \"not null value\";\r\n new ExpectedFailure<IllegalRequestParameterValue>(\r\n org.marketcetera.module.Messages.ILLEGAL_REQ_PARM_VALUE,\r\n instanceURN.getValue(), requestParm) {\r\n public void run() throws Exception {\r\n mManager.createDataFlow(new DataRequest[]{\r\n new DataRequest(CopierModuleFactory.INSTANCE_URN,\r\n \"doesnt matter\"),\r\n new DataRequest(instanceURN, requestParm)\r\n });\r\n\r\n }\r\n };\r\n //Verify that the module instance is not leaked.\r\n List<ModuleURN> instances = mManager.getModuleInstances(PROVIDER_URN);\r\n assertTrue(instances.toString(), instances.isEmpty());\r\n }",
"@Before\n public void setUp() throws Exception {\n env = Environment.getInstance();\n parameterTypes = new Class[1];\n parameterTypes[0] = za.co.multichoice.environment.Tile.class;\n m = env.getClass().getDeclaredMethod(METHOD_NAME, parameterTypes);\n m.setAccessible(true);\n parameters = new Object[1];\n }",
"private void test() {\n\n\t}",
"@Test\r\n public void testParamterized()\r\n {\r\n test(Types.create(List.class).withType(Number.class).build());\r\n }",
"@Test\n public void testValidateParams() {\n String[] params;\n\n // valid params - just the application name\n params = new String[]{\"Application\"};\n instance.validateParams(params);\n\n // valid params - extra junk\n params = new String[]{\"Application\", \"Other\", \"Other\"};\n instance.validateParams(params);\n\n // invalid params - empty\n params = new String[0];\n try {\n instance.validateParams(params);\n fail(\"Expected IllegalArgumentException\");\n } catch (IllegalArgumentException ex) {\n // expected\n }\n\n // invalid params - null first param\n params = new String[]{null};\n try {\n instance.validateParams(params);\n fail(\"Expected IllegalArgumentException\");\n } catch (IllegalArgumentException ex) {\n // expected\n }\n\n // invalid params - empty string\n params = new String[]{\"\"};\n try {\n instance.validateParams(params);\n fail(\"Expected IllegalArgumentException\");\n } catch (IllegalArgumentException ex) {\n // expected\n }\n }",
"private LocalParameters() {\n\n\t}",
"private FunctionParametersValidator() {}",
"@Test\n public void noUpdateWhenNotValidParams() {\n }",
"@Test\n public void testUserDomainConstructorWithParams(){Not sure if this works\n //\n Set<RestaurantDomain> testRestaurantDomain = new HashSet<>();\n //\n\n testUserDomain = new UserDomain(1, \"[email protected]\", \"password\", \"jDawg\", \"John\", \"Dawson\", testRestaurantDomain);\n\n new Verifications(){{\n assertEquals(1, testUserDomain.getId());\n assertEquals(\"[email protected]\", testUserDomain.getEmail());\n assertEquals(\"password\", testUserDomain.getPassword());\n assertEquals(\"jDawg\", testUserDomain.getUserName());\n assertEquals(\"John\", testUserDomain.getFirstName());\n assertEquals(\"Dawson\", testUserDomain.getFirstName());\n assertEquals(testRestaurantDomain, testUserDomain.getRestaurantDomain());\n }};\n }",
"@Test\n public void testGetStandardParameter() {\n Mossa move00 = new Mossa(Mossa.Action.MOVE, 0, 2, 2);\n assertTrue(turn.controlStandardParameter(move00));\n Mossa move01 = new Mossa(Mossa.Action.BUILD, 0, 2, 2);\n assertTrue(turn.controlStandardParameter(move01));\n Mossa move02 = new Mossa(Mossa.Action.MOVE, -1, 2, 2);\n Mossa move03 = new Mossa(Mossa.Action.BUILD, 0, 3, 7);\n Mossa move04 = new Mossa(Mossa.Action.BUILD, 3, -4, 9);\n assertTrue(!turn.controlStandardParameter(move02));\n assertTrue(!turn.controlStandardParameter(move03));\n assertTrue(!turn.controlStandardParameter(move04));\n }",
"@Test\n\tpublic void testParameterizedConstructor() {\n\t\tQuestionsEntity questions=new QuestionsEntity(1,\"SOX\",\"Have all changes has been approved\",\"Yes\");\n\t assertEquals(\"Yes\",questions.getResponse());\n\t}",
"public ParamNameTest(String testName) {\n super(testName);\n }",
"@Test\n\tpublic void testProfessorConstructor2params(){\n\t\tString firstname = \"Steven\";\n\t\tString lastName = \"Beaty\";\n\t\tProfessor testProfessor = new Professor(firstname, lastName);\n\t\tAssert.assertEquals(\"Steven\", testProfessor.getFirstName());\n\t\tAssert.assertEquals(\"Beaty\", testProfessor.getLastName());\n\t}",
"boolean hasParameters();",
"@Test\n public void testPersonReturn(){\n// System.out.println(\"------->\"+ mHbParam.getId());\n }",
"@Test\n public void testLocateManager() {\n System.out.println(\"locateManager\");\n int x = 0;\n int y = 0; \n //instance.locateManager(x, y);\n \n }",
"@Test\n public void validSetFlightInformation() {\n testUser.setUsername(\"username\");\n testUser.setLastName(\"lastname\");\n testUser.setPassword(\"password\");\n testUser.setFirstName(\"firstname\");\n\n Assertions.assertEquals(\"username\", testUser.getUsername());\n Assertions.assertEquals(\"lastname\", testUser.getLastName());\n Assertions.assertEquals(\"password\", testUser.getPassword());\n Assertions.assertEquals(\"firstname\", testUser.getFirstName());\n }",
"private void validateParameters() {\r\n if (command == null) {\r\n throw new BuildException(\r\n \"'command' parameter should not be null for coverity task.\");\r\n }\r\n\r\n }",
"@Override\n public void testCreateRequestListSomeFilteredBySourceSystem(){\n }",
"@Override\n\tprotected void validateParameterValues() {\n\t\t\n\t}",
"protected void parametersInstantiation_EM() {\n }",
"public void testParameterize() throws Exception {\n Map parameters1 = new HashMap();\n\n Object[] test_values = {\n new Object[]{\"/foo/bar\", parameters1, \"/foo/bar\"},\n };\n\n for (int i = 0; i < test_values.length; i++) {\n Object tests[] = (Object[]) test_values[i];\n String test = (String) tests[0];\n Map parameters = (Map) tests[1];\n String expected = (String) tests[2];\n\n String result = NetUtils.parameterize(test, parameters);\n String message = \"Test \" + \"'\" + test + \"'\";\n assertEquals(message, expected, result);\n }\n\n Map parameters2 = new HashMap();\n parameters2.put(\"a\", \"b\");\n parameters2.put(\"c\", \"d\");\n \n String test = \"bar\";\n String expected1 = \"bar?a=b&c=d\";\n String expected2 = \"bar?c=d&a=b\";\n \n String message = \"Test \" + \"'\" + test + \"'\";\n \n String result = NetUtils.parameterize(test, parameters2); \n\n if (expected1.equals(result)) {\n assertEquals(message, expected1, result); \n } else {\n assertEquals(message, expected2, result); \n }\n }",
"public void testOneOrMoreParameters() {\n int nrParameters = methodToTest.getParameterTypes().length;\n Class[] params = methodToTest.getParameterTypes();\n Object[] foo = new Object[nrParameters];\n \n // set up all parameters. Some methods are invoked with\n // primitives or collections, so we need to create them\n // accordingly\n for (int i = 0; i < nrParameters; i++) {\n try {\n if (params[i].isPrimitive()) {\n String primitiveName = params[i]\n .getName();\n if (primitiveName.equals(\"int\")) {\n foo[i] = Integer.valueOf(0);\n }\n if (primitiveName.equals(\"boolean\")) {\n foo[i] = Boolean.TRUE;\n }\n if (primitiveName.equals(\"short\")) {\n foo[i] = new Short(\"0\");\n }\n } else if (params[i].getName().equals(\"java.util.Collection\")) {\n foo[i] = new ArrayList();\n } else {\n /*\n * this call could easily fall if there is e.g. no public\n * default constructor. If it fails tweak the if/else tree\n * above to accommodate the parameter or check if we need to\n * test the particular method at all.\n */\n foo[i] = params[i].newInstance();\n }\n } catch (InstantiationException e) {\n fail(\"Cannot create an instance of : \"\n + params[i].getName()\n + \", required for \"\n + methodToTest.getName()\n + \". Check if \"\n + \"test needs reworking.\");\n } catch (IllegalAccessException il) {\n fail(\"Illegal Access to : \"\n + params[i].getName());\n }\n }\n \n try {\n methodToTest.invoke(facade, foo);\n fail(methodToTest.getName()\n + \" does not deliver an IllegalArgumentException\");\n } catch (InvocationTargetException e) {\n if (e.getTargetException() instanceof IllegalArgumentException \n || e.getTargetException() instanceof ClassCastException\n || e.getTargetException() instanceof NotImplementedException) {\n return;\n }\n fail(\"Test failed for \" + methodToTest.toString()\n + \" because of: \"\n + e.getTargetException());\n } catch (NotImplementedException e) {\n // If method not supported ignore failure\n } catch (Exception e) {\n fail(\"Test failed for \" + methodToTest.toString()\n + \" because of: \" + e.toString());\n }\n }",
"private void constructionHelper(GenericServiceResult genericServiceResult) {\n\n assertEquals(this.string, genericServiceResult.get(\"string\"));\n assertEquals(this.integer, genericServiceResult.get(\"integer\"));\n assertEquals(this.floats, genericServiceResult.get(\"floats\"));\n\n assertTrue(checkIndices(0, \"string\"));\n assertTrue(checkIndices(1, \"integer\"));\n assertTrue(checkIndices(2, \"floats\"));\n }",
"Parameter createParameter();",
"private void getConfigParameters(String[] parameters, Map<String, String> params,\n String testName) {\n for (int i = 0; i < parameters.length; i++) {\n params.put(parameters[i], null);\n }\n Log.v(TAG, \"[\" + testName + \"] \" + \"params.size() = \" + params.size());\n File f = new File(CONFIG_FILE);\n assertTrue(testName + \" test file not exists: \" + CONFIG_FILE, f.exists());\n // test suite\n XmlParser parser = new XmlParser(CONFIG_FILE);\n Node testSuiteNode = parser.getRootNode();\n String testSuiteName = parser.getAttrValue(testSuiteNode, \"name\");\n Log.v(TAG, \"[\" + testName + \"] \" + \"testSuiteName = \" + testSuiteName);\n // test case\n Node testCaseNode = null;\n String testCaseName = null;\n NodeList nodeListTestCase = parser.getNodeList(testSuiteNode, \"TestCase\");\n for (int i = 0; i < nodeListTestCase.getLength(); i++) {\n testCaseNode = nodeListTestCase.item(i);\n String tempTestCaseName = parser.getAttrValue(testCaseNode, \"name\");\n Log.v(TAG, \"[\" + testName + \"] \" + \"testCaseName = \" + tempTestCaseName);\n if (0 == tempTestCaseName.compareTo(TAG)) {\n testCaseName = tempTestCaseName;\n break;\n }\n }\n // test\n NodeList nodeList = parser.getNodeList(testCaseNode, \"Test\");\n for (int i = 0; i < nodeList.getLength(); i++) {\n Node testNode = nodeList.item(i);\n String tempTestName = parser.getAttrValue(testNode, \"name\");\n Log.v(TAG, \"[\" + testName + \"] \" + \"testName = \" + tempTestName);\n if (0 == tempTestName.compareTo(testName)) {\n for (int j = 0; j < params.size(); j++) {\n String attrValue = parser.getAttrValue(parser.getNodeByName(testNode,\n parameters[j]), \"value\");\n params.put(parameters[j], attrValue);\n Log.v(TAG, \"[\" + testName + \"] \" + \"param = \" + parameters[j] + \" value = \"\n + params.get(parameters[j]));\n }\n break;\n }\n }\n }",
"public void testGetBasedata() {\n }",
"public void testBidu(){\n\t}",
"@Test\n\tpublic void testBuildWithMissingParametersThrowsException() {\n\t\tAssertions.assertThrows(IllegalArgumentException.class, () -> {\n\t\t\ttestling.build();\n\t\t});\n\t}",
"@Ignore\n\t@Test\n\tpublic void testParamNull() {\n\t\tregisterParamException(null, keyString, valueString);\n\t\tregisterParamException(groupString, null, valueString);\n\t\tregisterParamException(groupString, keyString, null);\n\t}",
"@Parameters\n public static Collection<Object[]> testParameters() {\n Collection<Object[]> params = new ArrayList<Object[]>();\n\n for (OPT opt: OPT.values()) {\n Object[] par = new Object[2];\n par[0] = opt;\n par[1] = opt.name();\n\n params.add( par );\n }\n\n return params;\n }",
"@Override\n public void test() {\n \n }",
"public boolean isParameterProvided();",
"@Test //make sure it comes from testNG\n public void testWithQueryParameterAndList(){\n given().accept(ContentType.JSON)\n .and().params(\"limit\",100)\n .when().get(ConfigurationReader.getProperty(\"hrapp.baseresturl\")+\"/employees\")\n .then().assertThat().statusCode(200)\n .and().assertThat().contentType(ContentType.JSON)\n .and().assertThat().body(\"items.employee_id\", hasSize(100));\n }",
"abstract int estimationParameter1();",
"private test5() {\r\n\t\r\n\t}",
"public void testGetInputArguments() {\n List<String> args = mb.getInputArguments();\n assertNotNull(args);\n for (String string : args) {\n assertNotNull(string);\n assertTrue(string.length() > 0);\n }\n }",
"@Test\n public void testWithPathParameters(){\n given().accept(ContentType.JSON)\n .and().params(\"limit\",100)\n .and().pathParams(\"employee_id\", 110)\n .when().get(ConfigurationReader.getProperty(\"hrapp.baseresturl\")+\"/employees/{employee_id}\")\n .then().assertThat().statusCode(200)\n .and().assertThat().contentType(ContentType.JSON)\n .and().assertThat().body(\"employee_id\", equalTo(110),\n \"first_name\", equalTo(\"John\"),\n \"last_name\", equalTo(\"Chen\"),\n \"email\", equalTo(\"JCHEN\") );\n }",
"@Test\n public void constructorTest(){\n String retrievedName = doggy.getName();\n Date retrievedBirthDate = doggy.getBirthDate();\n Integer retrievedId = doggy.getId();\n\n // Then (we expect the given data, to match the retrieved data)\n Assert.assertEquals(givenName, retrievedName);\n Assert.assertEquals(givenBirthDate, retrievedBirthDate);\n Assert.assertEquals(givenId, retrievedId);\n }",
"@Test\n public void testBuildWithMissingParametersThrowsException() {\n // Arrange\n\n // Assert\n exception.expect(IllegalArgumentException.class);\n\n // Act\n testling.build();\n }",
"@Test\r\n public void test_logEntrance1_OneParameter() throws Exception {\r\n paramNames = new String[] {\"p1\"};\r\n paramValues = new Object[] {123};\r\n LoggingWrapperUtility.logEntrance(log, signature, paramNames, paramValues);\r\n\r\n TestsHelper.checkLog(\"logEntrance\",\r\n \"DEBUG\",\r\n \"Entering method [method_signature].\",\r\n \"Input parameters [p1:123]\");\r\n }",
"boolean hasParameterValue();",
"protected void validateFact(Fact[] param) {\r\n\r\n }",
"String getExampleParameters();",
"@Test\n public void testGetProductInfo() throws Exception {\n }",
"public Parameters getParameters();",
"private void checkParams() throws InvalidParamException{\r\n String error = svm.svm_check_parameter(this.problem, this.param);\r\n if(error != null){\r\n throw new InvalidParamException(\"Invalid parameter setting!\" + error);\r\n }\r\n }",
"public abstract Result mo5059a(Params... paramsArr);",
"@Test\n public void request() throws Exception {\n\n\n }",
"@Test\n\tpublic void argumentTest() {\n\t\tSelectionController selectionController = new SelectionController();\n\t\ttry {\n\t\t\tselectionController.select(null);\n\t\t\tAssert.fail(\"The new selection was null\");\n\t\t} catch (NullPointerException e) {\n\t\t}\n\n\t\ttry {\n\t\t\tselectionController.unselect(null);\n\t\t\tAssert.fail(\"The new unselection was null\");\n\t\t} catch (NullPointerException e) {\n\t\t}\n\n\t\ttry {\n\t\t\tselectionController.reselect(null);\n\t\t\tAssert.fail(\"The new reselection was null\");\n\t\t} catch (NullPointerException e) {\n\t\t}\n\t}",
"public void readParameters()\n {\n readParameters(getData());\n }",
"@Test\npublic void testAddBalance(){ \n sut.addBalance(100,1,new Account());\n}",
"@Test\n public void testUserInsertionMethod() {\n\n assertEquals(\"must return empty string for success\", \"\", userQuery.createUser(\"[email protected]\", \"s\", \"01234\", \"yahia\", \"sh\",\n \"11918\"));\n assertEquals(\"must return error since duplicate email\", \"Email Error\", userQuery.createUser(\"[email protected]\", \"s\", \"01234\", \"yahia\", \"sh\",\n \"11918\"));\n assertEquals(\"one of the field is empty\", \"Parameter Error\", userQuery.createUser(\"[email protected]\", \"s\", \"\", \"yahia\", \"sh\",\n \"11918\"));\n\n }",
"final void getParameters()\r\n {\r\n hostName=getParameter(\"hostname\");\r\n\tIPAddress=getParameter(\"IPAddress\");\r\n\tString num=getParameter(\"maxSearch\");\r\n\tString arg=getParameter(\"debug\");\r\n\tserver=getParameter(\"server\");\r\n\tindexName=getParameter(\"indexName\");\r\n\tString colour=getParameter(\"bgColour\");\r\n\r\n\tif(colour==null)\r\n\t{\r\n\t bgColour=Color.lightGray;\r\n }\r\n else\r\n\t{\r\n\t try\r\n\t {\r\n\t bgColour=new Color(Integer.parseInt(colour,16));\r\n\t }\r\n\t catch(NumberFormatException nfe)\r\n\t {\r\n\t bgColour=Color.lightGray;\r\n\t }\r\n\t}\r\n\t\r\n\tcolour=getParameter(\"fgColour\");\r\n\tif(colour==null)\r\n\t{\r\n\t fgColour=Color.black;\r\n\t}\r\n\telse\r\n\t{\r\n\t try\r\n\t {\r\n\t fgColour=new Color(Integer.parseInt(colour,16));\r\n\t }\r\n\t catch(NumberFormatException nfe)\r\n\t {\r\n\t fgColour=Color.black;\r\n\t }\r\n\t}\r\n\r\n\t//Check for missing parameters.\r\n\tif(hostName==null && server==null)\r\n\t{\r\n\t statusArea.setText(\"Error-no host/server\");\r\n\t hostName=\"none\";\r\n\t}\r\n\r\n\tmaxSearch=(num == null) ? MAX_NUMBER_PAGES : Integer.parseInt(num);\r\n }",
"@Test\n public void testAlmUtilsExample() throws GeneralLeanFtException, ReportException, IOException {\n AlmRunInfo almRunInfo = AlmUtils.getAlmRunInfo();\n if (almRunInfo != null){\n // AlmUtils.getAlmRunInfo() returned object, the test is running from ALMreturn;\n // Create a string builder, and add the properties of the test running\n StringBuilder sb = new StringBuilder();\n sb.append(\"ALMUtils test info proeprties: <BR>\");\n sb.append(String.format(\"ServerUrl: '%s' <BR>\", almRunInfo.getServerUrl()));\n sb.append(String.format(\"TesterName: '%s' <BR>\", almRunInfo.getTesterName()));\n sb.append(String.format(\"TestId: '%d' <BR>\", almRunInfo.getTestId()));\n sb.append(String.format(\"TestName: '%s' <BR>\", almRunInfo.getTestName()));\n sb.append(String.format(\"TestSetId: '%d' <BR>\", almRunInfo.getTestSetId()));\n sb.append(String.format(\"TestSetName: '%s' <BR>\", almRunInfo.getTestSetName()));\n sb.append(String.format(\"RunId: '%d' <BR>\", almRunInfo.getRunId()));\n sb.append(String.format(\"RunName: '%s' <BR>\", almRunInfo.getRunName()));\n sb.append(String.format(\"TestInstanceId: '%d' <BR>\", almRunInfo.getTestInstanceId()));\n String stringToReport = sb.toString();\n Reporter.reportEvent(\"AlmUtils.getAlmRunInfo() Properties Check\", stringToReport);\n\n }\n\n try {\n Map<String, Object> testParams = almRunInfo.getParameters();\n\n if (testParams == null) {\n Reporter.reportEvent(\"AlmUtils.getAlmRunInfo() Parameters Check\",\n \"Test is not running from ALM, therefore no parameters in the test\");\n } else {\n String paramString = \"\";\n for (Map.Entry<String, Object> testParam : testParams.entrySet()) {\n paramString += String.format(\"Parameter name: '%s', parameter value: '%s' <BR>\", testParam.getKey(), testParam.getValue().toString());\n }\n Reporter.reportEvent(\"ALMUtils.getAlmRunInfo Parameters Check\", paramString);\n }\n } catch (NullPointerException e) {\n Reporter.reportEvent(\"Exception in AlmUtils.getAlmRunInfo() Parameters Check\",\n \"Test is not running from ALM, therefore no parameters in the test\");\n }\n }",
"ParameterList getParameters();",
"@Test\n public void testAddCity_3args02() {\n\n System.out.println(\"addCity_3args\");\n String cityName = \"cityTest\";\n Pair coordenates = new Pair(41.200000, -8.000000);\n int points = 30;\n\n boolean result = sn10.addCity(coordenates, cityName, points);\n assertTrue(result);\n }",
"@Test\n public void testQueryList(){\n }",
"@Override\n public void test(PageParam pageParam) {\n\n }",
"@Test\r\n public void test_logEntrance2_OneParameter() throws Exception {\r\n paramNames = new String[] {\"p1\"};\r\n paramValues = new Object[] {123};\r\n LoggingWrapperUtility.logEntrance(log, signature, paramNames, paramValues, true, Level.INFO);\r\n\r\n TestsHelper.checkLog(\"logEntrance\",\r\n \"INFO\",\r\n \"] Entering method [method_signature].\",\r\n \"Input parameters [p1:123]\");\r\n }",
"private void SetParameters(XmlTest test){\r\n\t\t for (Map.Entry<String,String> entry : TestsParamList.get(test.getName()).entrySet()){\r\n\t\t\t test.addParameter(entry.getKey(), entry.getValue());\r\n\t\t }\r\n\t}",
"@Test\n public void testValidNewUser() throws Exception {\n when(request.getParameter(\"username\")).thenReturn(\"testUser\");\n when(request.getParameter(\"radius\")).thenReturn(\"10000\");\n when(request.getParameter(\"searchQuery\")).thenReturn(\"milk tea\");\n when(request.getParameter(\"numResults\")).thenReturn(\"7\");\n \n new AddSearchHistoryServlet().service(request, response);\n \n ArrayList<SearchItem> si = db.getSearchItemfromSearch(userID);\n int searchID = si.get(0).searchID;\n \n assertEquals(si.get(0).searchQuery, \"milk tea\");\n assertEquals(si.get(0).numResults, 7); \n assertEquals(si.get(0).radius, 10000);\n \n db.deleteQueryfromSearchHistory(searchID);\n \n }",
"@Override\n\tprotected boolean validateRequiredParameters() throws Exception {\n\t\treturn true;\n\t}",
"String [] getParameters();",
"public interface Params {\n }",
"public void setParameters(String parameters);",
"public ParamShoppingCartTest(int precio1, int precio2) {\n \n this.precio1 = precio1;\n this.precio2 = precio2; \n }",
"public void testSetBasedata() {\n }",
"@Test\n public void bookHotelTest() throws BookHotelFault, DatatypeConfigurationException{\n // Booking of an hotel that doesn't require credit card \n BookHotelInputType input = CreateBookHotelInputType(\"booking_Hotel_4\", \"Tick Joachim\", \"50408824\", 2, 11);\n boolean result = bookHotel(input);\n assertEquals(true, result); \n }",
"public void setParameters(String parameters){\n this.parameters=parameters;\n }",
"protected void missingParams() {\r\n throw new IllegalStateException(\r\n \"Function is missing parameters: \" + getName());\r\n }",
"public static void main(String[] args) {\n\t\tTryMethodParam tm1 = new TryMethodParam(10);\r\n\t\ttm1.try1(tm1);\r\n\t\tSystem.out.println(tm1.par); //10\r\n\t\ttm1.try2(tm1);\r\n\t\tSystem.out.println(tm1.par); //12345\r\n\t\tString s = \"tryyy\";\r\n\t\tStringParam.giveString(s);\r\n\t\tSystem.out.println(s);\r\n\t\tStringParam.addString(s);\r\n\t\tSystem.out.println(s);\r\n\r\n\t}",
"@Override\n\tpublic void test() {\n\t\t\n\t}",
"@Test\r\n\tpublic void testSanity() {\n\t}",
"int expectIntParameter(String strParamName);",
"@Test\r\n public void testUsuario_8args() {\r\n System.out.println(\"Usuario\");\r\n Integer idUsuario = null;\r\n String nombre = \"\";\r\n String apellido = \"\";\r\n String usuario = \"\";\r\n Integer edad = null;\r\n String genero = \"\";\r\n String contrasenia = \"\";\r\n String direccion = \"\";\r\n Usuario instance = new Usuario();\r\n instance.Usuario(idUsuario, nombre, apellido, usuario, edad, genero, contrasenia, direccion);\r\n // TODO review the generated test code and remove the default call to fail.\r\n }",
"@Test(dataProvider = \"inputs\", dataProviderClass=TestData.class)\n\tpublic void testMethod(String firstName, String lastName, String age) {\n\t\tSystem.out.println(\"first name: \" + firstName);\n\t\tSystem.out.println(\"last name: \" + lastName);\n\t\tSystem.out.println(\"Age: \" + age);\n\t}"
] | [
"0.73260736",
"0.6928486",
"0.686074",
"0.6729013",
"0.66817236",
"0.659666",
"0.6592387",
"0.6586867",
"0.6575259",
"0.6412951",
"0.6336221",
"0.6313496",
"0.62514967",
"0.6249803",
"0.6246806",
"0.62312615",
"0.6213264",
"0.6166873",
"0.61632615",
"0.6106019",
"0.6096806",
"0.6065303",
"0.606098",
"0.601649",
"0.60021555",
"0.599697",
"0.59826314",
"0.5969597",
"0.5947945",
"0.590092",
"0.5899622",
"0.58860487",
"0.58739716",
"0.58722013",
"0.5860612",
"0.58469397",
"0.5816081",
"0.58133936",
"0.5799468",
"0.5793932",
"0.5789558",
"0.5778442",
"0.5769654",
"0.57383806",
"0.5730149",
"0.5728635",
"0.57258606",
"0.57170826",
"0.5716824",
"0.57083666",
"0.56938773",
"0.56861794",
"0.56853664",
"0.5684996",
"0.5667049",
"0.565923",
"0.56583136",
"0.565298",
"0.5652486",
"0.5648594",
"0.5630467",
"0.56263703",
"0.5622768",
"0.56213903",
"0.561773",
"0.5615426",
"0.5610038",
"0.5608794",
"0.5592438",
"0.55820686",
"0.558165",
"0.5581163",
"0.5575971",
"0.5571085",
"0.55649114",
"0.55603707",
"0.55602556",
"0.55572987",
"0.5555662",
"0.55534154",
"0.5552723",
"0.5552033",
"0.5551633",
"0.5547851",
"0.5545388",
"0.5538264",
"0.5537984",
"0.5533718",
"0.55318415",
"0.5527682",
"0.5524771",
"0.5518666",
"0.5515846",
"0.5515048",
"0.5514501",
"0.55138445",
"0.55088544",
"0.55083126",
"0.5506547",
"0.5505329",
"0.5504068"
] | 0.0 | -1 |
just for testing providing parameters | @Ignore
@org.testng.annotations.Test(dataProvider = "dp")
private void dataProviderWithParameterKey(@ParameterKey("key_0") String param_0, String param_1) {
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"protected void setupParameters() {\n \n \n\n }",
"public void checkParameters() {\n }",
"public void testgetParameter() throws Exception {\n\r\n\t}",
"@Test\n\tpublic void testGetRequestParameter() {\n\t}",
"@Test\n\tpublic void testParameters() {\n\t\tassertEquals(par, myReply.getParameters());\n\t}",
"private void validateInputParameters(){\n\n }",
"public void getParameters(Parameters parameters) {\n\n }",
"@Test\n public void verifyParametersInput() {\n // act\n book.setISBN(isbn);\n book.setAuthors(array);\n book.setPublisher(publisher);\n // verify\n verify(book).setISBN(isbn);\n verify(book).setAuthors(array);\n verify(book).setPublisher(publisher);\n }",
"@Override\n\t@Ignore\n\t@Test\n\tpublic void testLaunchParameters() throws Throwable {\n\t}",
"@Override\n\tprotected void initParams() {\n\t\t\n\t}",
"public abstract Instances _getTestingFromParams(String params);",
"@Test\n\tpublic void correctParameters() {\n\t\tassertEquals(startTime, circle.startTime);\n\t\tassertEquals(duration, circle.duration);\n\t\tassertEquals(type, circle.type);\n\t\tassertEquals(height, circle.height, 0);\n\t}",
"@Test\r\n \tpublic void testParameters() {\n \t\tParameters params = (Parameters) filter.getParameters();\r\n \t\t\t\t\t\t\r\n \t\tassertEquals(params.unescapeSource, true);\r\n \t\tassertEquals(params.trimLeading, true);\r\n \t\tassertEquals(params.trimTrailing, true);\r\n \t\tassertEquals(params.preserveWS, true);\r\n \t\tassertEquals(params.useCodeFinder, false);\r\n \t\tassertEquals(\t\t\t\t\r\n \t\t\t\t\"#v1\\ncount.i=2\\nrule0=%(([-0+#]?)[-0+#]?)((\\\\d\\\\$)?)(([\\\\d\\\\*]*)(\\\\.[\\\\d\\\\*]*)?)[dioxXucsfeEgGpn]\\n\" +\r\n \t\t\t\t\"rule1=(\\\\\\\\r\\\\\\\\n)|\\\\\\\\a|\\\\\\\\b|\\\\\\\\f|\\\\\\\\n|\\\\\\\\r|\\\\\\\\t|\\\\\\\\v\\nsample=\\nuseAllRulesWhenTesting.b=false\", \r\n \t\t\t\tparams.codeFinderRules);\r\n \t\t\t\t\t\t\t\t\t\r\n \t\t// Check if defaults are set\r\n \t\tparams = new Parameters();\r\n \t\tfilter.setParameters(params);\r\n \t\t\r\n \t\tparams.columnNamesLineNum = 1;\r\n \t\tparams.valuesStartLineNum = 1;\r\n \t\tparams.detectColumnsMode = 1;\r\n \t\tparams.numColumns = 1;\r\n \t\tparams.sendHeaderMode = 1;\r\n \t\tparams.trimMode = 1;\r\n \t\tparams.fieldDelimiter = \"1\";\r\n \t\tparams.textQualifier = \"1\";\r\n \t\tparams.sourceIdColumns = \"1\";\r\n \t\tparams.sourceColumns = \"1\";\r\n \t\tparams.targetColumns = \"1\";\r\n \t\tparams.commentColumns = \"1\";\r\n \t\tparams.preserveWS = true;\r\n \t\tparams.useCodeFinder = true;\r\n \t\t\r\n \t\tparams = getParameters();\r\n \t\t\r\n \t\tassertEquals(params.fieldDelimiter, \"1\");\r\n \t\tassertEquals(params.columnNamesLineNum, 1);\r\n \t\tassertEquals(params.numColumns, 1);\r\n \t\tassertEquals(params.sendHeaderMode, 1);\r\n \t\tassertEquals(params.textQualifier, \"1\");\r\n \t\tassertEquals(params.trimMode, 1);\r\n \t\tassertEquals(params.valuesStartLineNum, 1);\r\n \t\tassertEquals(params.preserveWS, true);\r\n \t\tassertEquals(params.useCodeFinder, true);\r\n \t\t\r\n \t\t// Load filter parameters from a file, check if params have changed\r\n //\t\tURL paramsUrl = TableFilterTest.class.getResource(\"/test_params1.txt\");\r\n //\t\tassertNotNull(paramsUrl); \r\n \t\t\r\n \r\n \t\ttry {\r\n \t\tString st = \"file:\" + getFullFileName(\"test_params1.txt\");\r\n \t\tparams.load(new URI(st), false);\r\n \t} catch (URISyntaxException e) {\r\n \t}\r\n \r\n \t\t\r\n \t\tassertEquals(\"2\", params.fieldDelimiter);\r\n \t\tassertEquals(params.columnNamesLineNum, 2);\r\n \t\tassertEquals(params.numColumns, 2);\r\n \t\tassertEquals(params.sendHeaderMode, 2);\r\n \t\tassertEquals(\"2\", params.textQualifier);\r\n \t\tassertEquals(params.trimMode, 2);\r\n \t\tassertEquals(params.valuesStartLineNum, 2);\r\n \t\tassertEquals(params.preserveWS, false);\r\n \t\tassertEquals(params.useCodeFinder, false);\r\n \t\t\r\n \t\t// Save filter parameters to a file, load and check if params have changed\r\n \t\tURL paramsUrl = TableFilterTest.class.getResource(\"/test_params2.txt\");\r\n \t\tassertNotNull(paramsUrl);\r\n \t\t\r\n \t\tparams.save(paramsUrl.getPath());\r\n \t\t\r\n \t\t// Change params before loading them\r\n \t\tparams = (Parameters) filter.getParameters();\r\n \t\tparams.fieldDelimiter = \"3\";\r\n \t\tparams.columnNamesLineNum = 3;\r\n \t\tparams.numColumns = 3;\r\n \t\tparams.sendHeaderMode = 3;\r\n \t\tparams.textQualifier = \"3\";\r\n \t\tparams.trimMode = 3;\r\n \t\tparams.valuesStartLineNum = 3;\r\n \t\tparams.preserveWS = true;\r\n \t\tparams.useCodeFinder = true;\r\n \t\t\r\n \t\tparams.load(Util.toURI(paramsUrl.getPath()), false);\r\n \t\t\r\n \t\tassertEquals(params.fieldDelimiter, \"2\");\r\n \t\tassertEquals(params.columnNamesLineNum, 2);\r\n \t\tassertEquals(params.numColumns, 2);\r\n \t\tassertEquals(params.sendHeaderMode, 2);\r\n \t\tassertEquals(params.textQualifier, \"2\");\r\n \t\tassertEquals(params.trimMode, 2);\r\n \t\tassertEquals(params.valuesStartLineNum, 2);\r\n \t\tassertEquals(params.preserveWS, false);\r\n \t\tassertEquals(params.useCodeFinder, false);\r\n \t\t\r\n \t\t// Check if parameters type is controlled\r\n \t\t\r\n \t\tfilter.setParameters(new net.sf.okapi.filters.plaintext.base.Parameters());\r\n \t\tInputStream input = TableFilterTest.class.getResourceAsStream(\"/csv_test1.txt\");\r\n \t\ttry {\r\n \t\t\tfilter.open(new RawDocument(input, \"UTF-8\", locEN));\r\n \t\t\tfail(\"OkapiBadFilterParametersException should've been trown\");\r\n \t\t}\r\n \t\tcatch (OkapiBadFilterParametersException e) {\r\n \t\t}\r\n \t\t\r\n \t\tfilter.close();\r\n \t\r\n \t\tfilter.setParameters(new net.sf.okapi.filters.table.csv.Parameters());\r\n \t\tinput = TableFilterTest.class.getResourceAsStream(\"/csv_test1.txt\");\r\n \t\ttry {\r\n \t\t\tfilter.open(new RawDocument(input, \"UTF-8\", locEN));\r\n \t\t}\r\n \t\tcatch (OkapiBadFilterParametersException e) {\r\n \t\t\tfail(\"OkapiBadFilterParametersException should NOT have been trown\");\r\n \t\t}\r\n \t\t\tfilter.close();\r\n \t}",
"void setParameters() {\n\t\t\n\t}",
"@Parameters({\"name\", \"lastName\"})\n @Test\n public void test1(String name, String lastName){\n System.out.println(\"Name is \"+ name);\n System.out.println(\"Last name is \"+ lastName);\n }",
"@Test\n\tpublic void Account_test() { Using HamCrest \t\t\n\t\t// Exercise code to run and test\n\t\t//\n\t\tmiCuenta.setHolder(this.arg1);\n\t\tString resHolder = miCuenta.getHolder(); \n\t\t//\n\t\tmiCuenta.setBalance(this.arg2);\n\t\tint resBalance = miCuenta.getBalance(); \n\t\t//\n\t\tmiCuenta.setZone(this.arg3);\n\t\tint resZone = miCuenta.getZone(); \n\t\t\t\t\t\t\n\t\t// Verify\n\t\tassertThat(this.arg1, is(resHolder));\n\t\tassertThat(this.arg2, is(resBalance)); \n\t\tassertThat(this.arg3, is(resZone)); \n\t}",
"private Params()\n {\n }",
"@Test (dataProvider= \"My data provider\")\r\n\tpublic void TestCalcParamitarized(String in1,String Op, String in2,String Expec){ //.... 1- Parameterized test method -Define method input parameters-\r\n\t\tCalc(in1, Op, in2);\r\n\t\tassertResult(Expec);\t\t\r\n\t}",
"public void getParameters(Parameters parameters) {\n\n\t}",
"@Test\n void getArgString() {\n }",
"@Test\n public void testValidParameters() {\n Map params = new HashMap();\n params.put(\"provider_url\", \"http://localhost:8080/v1/oauth/tokens\");\n params.put(\"grant_type\", \"password\");\n params.put(\"client_id\", \"test_client_1\");\n params.put(\"provider_id\", \"local\");\n params.put(\"basic_username\", \"test_client_1\");\n params.put(\"basic_password\", \"test_secret\");\n params.put(\"username\", \"test_client_1\");\n params.put(\"password\", \"test_secret\");\n PasswordGrant instance = new PasswordGrant();\n Boolean expResult = true;\n Boolean result = instance.validParameters(params);\n assertEquals(expResult, result);\n \n }",
"@Test\n public void MyTest() {\n System.out.println(\"Parameterized Number is : \" + inputNumber);\n System.out.println(\"Expected Result is : \" + expectedResult);\n }",
"@Override\r\n\t\t\tpublic void test() {\n\t\t\t}",
"@Override\r\n public void setParameter(String parameters) {\r\n // dummy\r\n }",
"@Test\r\n public void requestParameters() throws Exception {\r\n final ModuleURN instanceURN = new ModuleURN(PROVIDER_URN, \"mymodule\");\r\n final String requestParm = \"not null value\";\r\n new ExpectedFailure<IllegalRequestParameterValue>(\r\n org.marketcetera.module.Messages.ILLEGAL_REQ_PARM_VALUE,\r\n instanceURN.getValue(), requestParm) {\r\n public void run() throws Exception {\r\n mManager.createDataFlow(new DataRequest[]{\r\n new DataRequest(CopierModuleFactory.INSTANCE_URN,\r\n \"doesnt matter\"),\r\n new DataRequest(instanceURN, requestParm)\r\n });\r\n\r\n }\r\n };\r\n //Verify that the module instance is not leaked.\r\n List<ModuleURN> instances = mManager.getModuleInstances(PROVIDER_URN);\r\n assertTrue(instances.toString(), instances.isEmpty());\r\n }",
"@Before\n public void setUp() throws Exception {\n env = Environment.getInstance();\n parameterTypes = new Class[1];\n parameterTypes[0] = za.co.multichoice.environment.Tile.class;\n m = env.getClass().getDeclaredMethod(METHOD_NAME, parameterTypes);\n m.setAccessible(true);\n parameters = new Object[1];\n }",
"private void test() {\n\n\t}",
"@Test\r\n public void testParamterized()\r\n {\r\n test(Types.create(List.class).withType(Number.class).build());\r\n }",
"@Test\n public void testValidateParams() {\n String[] params;\n\n // valid params - just the application name\n params = new String[]{\"Application\"};\n instance.validateParams(params);\n\n // valid params - extra junk\n params = new String[]{\"Application\", \"Other\", \"Other\"};\n instance.validateParams(params);\n\n // invalid params - empty\n params = new String[0];\n try {\n instance.validateParams(params);\n fail(\"Expected IllegalArgumentException\");\n } catch (IllegalArgumentException ex) {\n // expected\n }\n\n // invalid params - null first param\n params = new String[]{null};\n try {\n instance.validateParams(params);\n fail(\"Expected IllegalArgumentException\");\n } catch (IllegalArgumentException ex) {\n // expected\n }\n\n // invalid params - empty string\n params = new String[]{\"\"};\n try {\n instance.validateParams(params);\n fail(\"Expected IllegalArgumentException\");\n } catch (IllegalArgumentException ex) {\n // expected\n }\n }",
"private LocalParameters() {\n\n\t}",
"private FunctionParametersValidator() {}",
"@Test\n public void noUpdateWhenNotValidParams() {\n }",
"@Test\n public void testUserDomainConstructorWithParams(){Not sure if this works\n //\n Set<RestaurantDomain> testRestaurantDomain = new HashSet<>();\n //\n\n testUserDomain = new UserDomain(1, \"[email protected]\", \"password\", \"jDawg\", \"John\", \"Dawson\", testRestaurantDomain);\n\n new Verifications(){{\n assertEquals(1, testUserDomain.getId());\n assertEquals(\"[email protected]\", testUserDomain.getEmail());\n assertEquals(\"password\", testUserDomain.getPassword());\n assertEquals(\"jDawg\", testUserDomain.getUserName());\n assertEquals(\"John\", testUserDomain.getFirstName());\n assertEquals(\"Dawson\", testUserDomain.getFirstName());\n assertEquals(testRestaurantDomain, testUserDomain.getRestaurantDomain());\n }};\n }",
"@Test\n public void testGetStandardParameter() {\n Mossa move00 = new Mossa(Mossa.Action.MOVE, 0, 2, 2);\n assertTrue(turn.controlStandardParameter(move00));\n Mossa move01 = new Mossa(Mossa.Action.BUILD, 0, 2, 2);\n assertTrue(turn.controlStandardParameter(move01));\n Mossa move02 = new Mossa(Mossa.Action.MOVE, -1, 2, 2);\n Mossa move03 = new Mossa(Mossa.Action.BUILD, 0, 3, 7);\n Mossa move04 = new Mossa(Mossa.Action.BUILD, 3, -4, 9);\n assertTrue(!turn.controlStandardParameter(move02));\n assertTrue(!turn.controlStandardParameter(move03));\n assertTrue(!turn.controlStandardParameter(move04));\n }",
"@Test\n\tpublic void testParameterizedConstructor() {\n\t\tQuestionsEntity questions=new QuestionsEntity(1,\"SOX\",\"Have all changes has been approved\",\"Yes\");\n\t assertEquals(\"Yes\",questions.getResponse());\n\t}",
"public ParamNameTest(String testName) {\n super(testName);\n }",
"@Test\n\tpublic void testProfessorConstructor2params(){\n\t\tString firstname = \"Steven\";\n\t\tString lastName = \"Beaty\";\n\t\tProfessor testProfessor = new Professor(firstname, lastName);\n\t\tAssert.assertEquals(\"Steven\", testProfessor.getFirstName());\n\t\tAssert.assertEquals(\"Beaty\", testProfessor.getLastName());\n\t}",
"boolean hasParameters();",
"@Test\n public void testPersonReturn(){\n// System.out.println(\"------->\"+ mHbParam.getId());\n }",
"@Test\n public void testLocateManager() {\n System.out.println(\"locateManager\");\n int x = 0;\n int y = 0; \n //instance.locateManager(x, y);\n \n }",
"@Test\n public void validSetFlightInformation() {\n testUser.setUsername(\"username\");\n testUser.setLastName(\"lastname\");\n testUser.setPassword(\"password\");\n testUser.setFirstName(\"firstname\");\n\n Assertions.assertEquals(\"username\", testUser.getUsername());\n Assertions.assertEquals(\"lastname\", testUser.getLastName());\n Assertions.assertEquals(\"password\", testUser.getPassword());\n Assertions.assertEquals(\"firstname\", testUser.getFirstName());\n }",
"private void validateParameters() {\r\n if (command == null) {\r\n throw new BuildException(\r\n \"'command' parameter should not be null for coverity task.\");\r\n }\r\n\r\n }",
"@Override\n public void testCreateRequestListSomeFilteredBySourceSystem(){\n }",
"@Override\n\tprotected void validateParameterValues() {\n\t\t\n\t}",
"protected void parametersInstantiation_EM() {\n }",
"public void testParameterize() throws Exception {\n Map parameters1 = new HashMap();\n\n Object[] test_values = {\n new Object[]{\"/foo/bar\", parameters1, \"/foo/bar\"},\n };\n\n for (int i = 0; i < test_values.length; i++) {\n Object tests[] = (Object[]) test_values[i];\n String test = (String) tests[0];\n Map parameters = (Map) tests[1];\n String expected = (String) tests[2];\n\n String result = NetUtils.parameterize(test, parameters);\n String message = \"Test \" + \"'\" + test + \"'\";\n assertEquals(message, expected, result);\n }\n\n Map parameters2 = new HashMap();\n parameters2.put(\"a\", \"b\");\n parameters2.put(\"c\", \"d\");\n \n String test = \"bar\";\n String expected1 = \"bar?a=b&c=d\";\n String expected2 = \"bar?c=d&a=b\";\n \n String message = \"Test \" + \"'\" + test + \"'\";\n \n String result = NetUtils.parameterize(test, parameters2); \n\n if (expected1.equals(result)) {\n assertEquals(message, expected1, result); \n } else {\n assertEquals(message, expected2, result); \n }\n }",
"public void testOneOrMoreParameters() {\n int nrParameters = methodToTest.getParameterTypes().length;\n Class[] params = methodToTest.getParameterTypes();\n Object[] foo = new Object[nrParameters];\n \n // set up all parameters. Some methods are invoked with\n // primitives or collections, so we need to create them\n // accordingly\n for (int i = 0; i < nrParameters; i++) {\n try {\n if (params[i].isPrimitive()) {\n String primitiveName = params[i]\n .getName();\n if (primitiveName.equals(\"int\")) {\n foo[i] = Integer.valueOf(0);\n }\n if (primitiveName.equals(\"boolean\")) {\n foo[i] = Boolean.TRUE;\n }\n if (primitiveName.equals(\"short\")) {\n foo[i] = new Short(\"0\");\n }\n } else if (params[i].getName().equals(\"java.util.Collection\")) {\n foo[i] = new ArrayList();\n } else {\n /*\n * this call could easily fall if there is e.g. no public\n * default constructor. If it fails tweak the if/else tree\n * above to accommodate the parameter or check if we need to\n * test the particular method at all.\n */\n foo[i] = params[i].newInstance();\n }\n } catch (InstantiationException e) {\n fail(\"Cannot create an instance of : \"\n + params[i].getName()\n + \", required for \"\n + methodToTest.getName()\n + \". Check if \"\n + \"test needs reworking.\");\n } catch (IllegalAccessException il) {\n fail(\"Illegal Access to : \"\n + params[i].getName());\n }\n }\n \n try {\n methodToTest.invoke(facade, foo);\n fail(methodToTest.getName()\n + \" does not deliver an IllegalArgumentException\");\n } catch (InvocationTargetException e) {\n if (e.getTargetException() instanceof IllegalArgumentException \n || e.getTargetException() instanceof ClassCastException\n || e.getTargetException() instanceof NotImplementedException) {\n return;\n }\n fail(\"Test failed for \" + methodToTest.toString()\n + \" because of: \"\n + e.getTargetException());\n } catch (NotImplementedException e) {\n // If method not supported ignore failure\n } catch (Exception e) {\n fail(\"Test failed for \" + methodToTest.toString()\n + \" because of: \" + e.toString());\n }\n }",
"Parameter createParameter();",
"private void constructionHelper(GenericServiceResult genericServiceResult) {\n\n assertEquals(this.string, genericServiceResult.get(\"string\"));\n assertEquals(this.integer, genericServiceResult.get(\"integer\"));\n assertEquals(this.floats, genericServiceResult.get(\"floats\"));\n\n assertTrue(checkIndices(0, \"string\"));\n assertTrue(checkIndices(1, \"integer\"));\n assertTrue(checkIndices(2, \"floats\"));\n }",
"private void getConfigParameters(String[] parameters, Map<String, String> params,\n String testName) {\n for (int i = 0; i < parameters.length; i++) {\n params.put(parameters[i], null);\n }\n Log.v(TAG, \"[\" + testName + \"] \" + \"params.size() = \" + params.size());\n File f = new File(CONFIG_FILE);\n assertTrue(testName + \" test file not exists: \" + CONFIG_FILE, f.exists());\n // test suite\n XmlParser parser = new XmlParser(CONFIG_FILE);\n Node testSuiteNode = parser.getRootNode();\n String testSuiteName = parser.getAttrValue(testSuiteNode, \"name\");\n Log.v(TAG, \"[\" + testName + \"] \" + \"testSuiteName = \" + testSuiteName);\n // test case\n Node testCaseNode = null;\n String testCaseName = null;\n NodeList nodeListTestCase = parser.getNodeList(testSuiteNode, \"TestCase\");\n for (int i = 0; i < nodeListTestCase.getLength(); i++) {\n testCaseNode = nodeListTestCase.item(i);\n String tempTestCaseName = parser.getAttrValue(testCaseNode, \"name\");\n Log.v(TAG, \"[\" + testName + \"] \" + \"testCaseName = \" + tempTestCaseName);\n if (0 == tempTestCaseName.compareTo(TAG)) {\n testCaseName = tempTestCaseName;\n break;\n }\n }\n // test\n NodeList nodeList = parser.getNodeList(testCaseNode, \"Test\");\n for (int i = 0; i < nodeList.getLength(); i++) {\n Node testNode = nodeList.item(i);\n String tempTestName = parser.getAttrValue(testNode, \"name\");\n Log.v(TAG, \"[\" + testName + \"] \" + \"testName = \" + tempTestName);\n if (0 == tempTestName.compareTo(testName)) {\n for (int j = 0; j < params.size(); j++) {\n String attrValue = parser.getAttrValue(parser.getNodeByName(testNode,\n parameters[j]), \"value\");\n params.put(parameters[j], attrValue);\n Log.v(TAG, \"[\" + testName + \"] \" + \"param = \" + parameters[j] + \" value = \"\n + params.get(parameters[j]));\n }\n break;\n }\n }\n }",
"public void testGetBasedata() {\n }",
"@Test\n\tpublic void testBuildWithMissingParametersThrowsException() {\n\t\tAssertions.assertThrows(IllegalArgumentException.class, () -> {\n\t\t\ttestling.build();\n\t\t});\n\t}",
"public void testBidu(){\n\t}",
"@Ignore\n\t@Test\n\tpublic void testParamNull() {\n\t\tregisterParamException(null, keyString, valueString);\n\t\tregisterParamException(groupString, null, valueString);\n\t\tregisterParamException(groupString, keyString, null);\n\t}",
"@Parameters\n public static Collection<Object[]> testParameters() {\n Collection<Object[]> params = new ArrayList<Object[]>();\n\n for (OPT opt: OPT.values()) {\n Object[] par = new Object[2];\n par[0] = opt;\n par[1] = opt.name();\n\n params.add( par );\n }\n\n return params;\n }",
"@Override\n public void test() {\n \n }",
"public boolean isParameterProvided();",
"@Test //make sure it comes from testNG\n public void testWithQueryParameterAndList(){\n given().accept(ContentType.JSON)\n .and().params(\"limit\",100)\n .when().get(ConfigurationReader.getProperty(\"hrapp.baseresturl\")+\"/employees\")\n .then().assertThat().statusCode(200)\n .and().assertThat().contentType(ContentType.JSON)\n .and().assertThat().body(\"items.employee_id\", hasSize(100));\n }",
"abstract int estimationParameter1();",
"private test5() {\r\n\t\r\n\t}",
"public void testGetInputArguments() {\n List<String> args = mb.getInputArguments();\n assertNotNull(args);\n for (String string : args) {\n assertNotNull(string);\n assertTrue(string.length() > 0);\n }\n }",
"@Test\n public void testWithPathParameters(){\n given().accept(ContentType.JSON)\n .and().params(\"limit\",100)\n .and().pathParams(\"employee_id\", 110)\n .when().get(ConfigurationReader.getProperty(\"hrapp.baseresturl\")+\"/employees/{employee_id}\")\n .then().assertThat().statusCode(200)\n .and().assertThat().contentType(ContentType.JSON)\n .and().assertThat().body(\"employee_id\", equalTo(110),\n \"first_name\", equalTo(\"John\"),\n \"last_name\", equalTo(\"Chen\"),\n \"email\", equalTo(\"JCHEN\") );\n }",
"@Test\n public void constructorTest(){\n String retrievedName = doggy.getName();\n Date retrievedBirthDate = doggy.getBirthDate();\n Integer retrievedId = doggy.getId();\n\n // Then (we expect the given data, to match the retrieved data)\n Assert.assertEquals(givenName, retrievedName);\n Assert.assertEquals(givenBirthDate, retrievedBirthDate);\n Assert.assertEquals(givenId, retrievedId);\n }",
"@Test\n public void testBuildWithMissingParametersThrowsException() {\n // Arrange\n\n // Assert\n exception.expect(IllegalArgumentException.class);\n\n // Act\n testling.build();\n }",
"@Test\r\n public void test_logEntrance1_OneParameter() throws Exception {\r\n paramNames = new String[] {\"p1\"};\r\n paramValues = new Object[] {123};\r\n LoggingWrapperUtility.logEntrance(log, signature, paramNames, paramValues);\r\n\r\n TestsHelper.checkLog(\"logEntrance\",\r\n \"DEBUG\",\r\n \"Entering method [method_signature].\",\r\n \"Input parameters [p1:123]\");\r\n }",
"boolean hasParameterValue();",
"protected void validateFact(Fact[] param) {\r\n\r\n }",
"String getExampleParameters();",
"@Test\n public void testGetProductInfo() throws Exception {\n }",
"private void checkParams() throws InvalidParamException{\r\n String error = svm.svm_check_parameter(this.problem, this.param);\r\n if(error != null){\r\n throw new InvalidParamException(\"Invalid parameter setting!\" + error);\r\n }\r\n }",
"public Parameters getParameters();",
"public abstract Result mo5059a(Params... paramsArr);",
"@Test\n public void request() throws Exception {\n\n\n }",
"@Test\n\tpublic void argumentTest() {\n\t\tSelectionController selectionController = new SelectionController();\n\t\ttry {\n\t\t\tselectionController.select(null);\n\t\t\tAssert.fail(\"The new selection was null\");\n\t\t} catch (NullPointerException e) {\n\t\t}\n\n\t\ttry {\n\t\t\tselectionController.unselect(null);\n\t\t\tAssert.fail(\"The new unselection was null\");\n\t\t} catch (NullPointerException e) {\n\t\t}\n\n\t\ttry {\n\t\t\tselectionController.reselect(null);\n\t\t\tAssert.fail(\"The new reselection was null\");\n\t\t} catch (NullPointerException e) {\n\t\t}\n\t}",
"public void readParameters()\n {\n readParameters(getData());\n }",
"@Test\npublic void testAddBalance(){ \n sut.addBalance(100,1,new Account());\n}",
"@Test\n public void testUserInsertionMethod() {\n\n assertEquals(\"must return empty string for success\", \"\", userQuery.createUser(\"[email protected]\", \"s\", \"01234\", \"yahia\", \"sh\",\n \"11918\"));\n assertEquals(\"must return error since duplicate email\", \"Email Error\", userQuery.createUser(\"[email protected]\", \"s\", \"01234\", \"yahia\", \"sh\",\n \"11918\"));\n assertEquals(\"one of the field is empty\", \"Parameter Error\", userQuery.createUser(\"[email protected]\", \"s\", \"\", \"yahia\", \"sh\",\n \"11918\"));\n\n }",
"final void getParameters()\r\n {\r\n hostName=getParameter(\"hostname\");\r\n\tIPAddress=getParameter(\"IPAddress\");\r\n\tString num=getParameter(\"maxSearch\");\r\n\tString arg=getParameter(\"debug\");\r\n\tserver=getParameter(\"server\");\r\n\tindexName=getParameter(\"indexName\");\r\n\tString colour=getParameter(\"bgColour\");\r\n\r\n\tif(colour==null)\r\n\t{\r\n\t bgColour=Color.lightGray;\r\n }\r\n else\r\n\t{\r\n\t try\r\n\t {\r\n\t bgColour=new Color(Integer.parseInt(colour,16));\r\n\t }\r\n\t catch(NumberFormatException nfe)\r\n\t {\r\n\t bgColour=Color.lightGray;\r\n\t }\r\n\t}\r\n\t\r\n\tcolour=getParameter(\"fgColour\");\r\n\tif(colour==null)\r\n\t{\r\n\t fgColour=Color.black;\r\n\t}\r\n\telse\r\n\t{\r\n\t try\r\n\t {\r\n\t fgColour=new Color(Integer.parseInt(colour,16));\r\n\t }\r\n\t catch(NumberFormatException nfe)\r\n\t {\r\n\t fgColour=Color.black;\r\n\t }\r\n\t}\r\n\r\n\t//Check for missing parameters.\r\n\tif(hostName==null && server==null)\r\n\t{\r\n\t statusArea.setText(\"Error-no host/server\");\r\n\t hostName=\"none\";\r\n\t}\r\n\r\n\tmaxSearch=(num == null) ? MAX_NUMBER_PAGES : Integer.parseInt(num);\r\n }",
"@Test\n public void testAlmUtilsExample() throws GeneralLeanFtException, ReportException, IOException {\n AlmRunInfo almRunInfo = AlmUtils.getAlmRunInfo();\n if (almRunInfo != null){\n // AlmUtils.getAlmRunInfo() returned object, the test is running from ALMreturn;\n // Create a string builder, and add the properties of the test running\n StringBuilder sb = new StringBuilder();\n sb.append(\"ALMUtils test info proeprties: <BR>\");\n sb.append(String.format(\"ServerUrl: '%s' <BR>\", almRunInfo.getServerUrl()));\n sb.append(String.format(\"TesterName: '%s' <BR>\", almRunInfo.getTesterName()));\n sb.append(String.format(\"TestId: '%d' <BR>\", almRunInfo.getTestId()));\n sb.append(String.format(\"TestName: '%s' <BR>\", almRunInfo.getTestName()));\n sb.append(String.format(\"TestSetId: '%d' <BR>\", almRunInfo.getTestSetId()));\n sb.append(String.format(\"TestSetName: '%s' <BR>\", almRunInfo.getTestSetName()));\n sb.append(String.format(\"RunId: '%d' <BR>\", almRunInfo.getRunId()));\n sb.append(String.format(\"RunName: '%s' <BR>\", almRunInfo.getRunName()));\n sb.append(String.format(\"TestInstanceId: '%d' <BR>\", almRunInfo.getTestInstanceId()));\n String stringToReport = sb.toString();\n Reporter.reportEvent(\"AlmUtils.getAlmRunInfo() Properties Check\", stringToReport);\n\n }\n\n try {\n Map<String, Object> testParams = almRunInfo.getParameters();\n\n if (testParams == null) {\n Reporter.reportEvent(\"AlmUtils.getAlmRunInfo() Parameters Check\",\n \"Test is not running from ALM, therefore no parameters in the test\");\n } else {\n String paramString = \"\";\n for (Map.Entry<String, Object> testParam : testParams.entrySet()) {\n paramString += String.format(\"Parameter name: '%s', parameter value: '%s' <BR>\", testParam.getKey(), testParam.getValue().toString());\n }\n Reporter.reportEvent(\"ALMUtils.getAlmRunInfo Parameters Check\", paramString);\n }\n } catch (NullPointerException e) {\n Reporter.reportEvent(\"Exception in AlmUtils.getAlmRunInfo() Parameters Check\",\n \"Test is not running from ALM, therefore no parameters in the test\");\n }\n }",
"@Override\n public void test(PageParam pageParam) {\n\n }",
"ParameterList getParameters();",
"@Test\n public void testAddCity_3args02() {\n\n System.out.println(\"addCity_3args\");\n String cityName = \"cityTest\";\n Pair coordenates = new Pair(41.200000, -8.000000);\n int points = 30;\n\n boolean result = sn10.addCity(coordenates, cityName, points);\n assertTrue(result);\n }",
"@Test\n public void testQueryList(){\n }",
"@Test\r\n public void test_logEntrance2_OneParameter() throws Exception {\r\n paramNames = new String[] {\"p1\"};\r\n paramValues = new Object[] {123};\r\n LoggingWrapperUtility.logEntrance(log, signature, paramNames, paramValues, true, Level.INFO);\r\n\r\n TestsHelper.checkLog(\"logEntrance\",\r\n \"INFO\",\r\n \"] Entering method [method_signature].\",\r\n \"Input parameters [p1:123]\");\r\n }",
"private void SetParameters(XmlTest test){\r\n\t\t for (Map.Entry<String,String> entry : TestsParamList.get(test.getName()).entrySet()){\r\n\t\t\t test.addParameter(entry.getKey(), entry.getValue());\r\n\t\t }\r\n\t}",
"@Test\n public void testValidNewUser() throws Exception {\n when(request.getParameter(\"username\")).thenReturn(\"testUser\");\n when(request.getParameter(\"radius\")).thenReturn(\"10000\");\n when(request.getParameter(\"searchQuery\")).thenReturn(\"milk tea\");\n when(request.getParameter(\"numResults\")).thenReturn(\"7\");\n \n new AddSearchHistoryServlet().service(request, response);\n \n ArrayList<SearchItem> si = db.getSearchItemfromSearch(userID);\n int searchID = si.get(0).searchID;\n \n assertEquals(si.get(0).searchQuery, \"milk tea\");\n assertEquals(si.get(0).numResults, 7); \n assertEquals(si.get(0).radius, 10000);\n \n db.deleteQueryfromSearchHistory(searchID);\n \n }",
"@Override\n\tprotected boolean validateRequiredParameters() throws Exception {\n\t\treturn true;\n\t}",
"String [] getParameters();",
"public interface Params {\n }",
"public void setParameters(String parameters);",
"public ParamShoppingCartTest(int precio1, int precio2) {\n \n this.precio1 = precio1;\n this.precio2 = precio2; \n }",
"public void testSetBasedata() {\n }",
"@Test\n public void bookHotelTest() throws BookHotelFault, DatatypeConfigurationException{\n // Booking of an hotel that doesn't require credit card \n BookHotelInputType input = CreateBookHotelInputType(\"booking_Hotel_4\", \"Tick Joachim\", \"50408824\", 2, 11);\n boolean result = bookHotel(input);\n assertEquals(true, result); \n }",
"public void setParameters(String parameters){\n this.parameters=parameters;\n }",
"protected void missingParams() {\r\n throw new IllegalStateException(\r\n \"Function is missing parameters: \" + getName());\r\n }",
"public static void main(String[] args) {\n\t\tTryMethodParam tm1 = new TryMethodParam(10);\r\n\t\ttm1.try1(tm1);\r\n\t\tSystem.out.println(tm1.par); //10\r\n\t\ttm1.try2(tm1);\r\n\t\tSystem.out.println(tm1.par); //12345\r\n\t\tString s = \"tryyy\";\r\n\t\tStringParam.giveString(s);\r\n\t\tSystem.out.println(s);\r\n\t\tStringParam.addString(s);\r\n\t\tSystem.out.println(s);\r\n\r\n\t}",
"@Test\r\n\tpublic void testSanity() {\n\t}",
"@Override\n\tpublic void test() {\n\t\t\n\t}",
"int expectIntParameter(String strParamName);",
"@Test\r\n public void testUsuario_8args() {\r\n System.out.println(\"Usuario\");\r\n Integer idUsuario = null;\r\n String nombre = \"\";\r\n String apellido = \"\";\r\n String usuario = \"\";\r\n Integer edad = null;\r\n String genero = \"\";\r\n String contrasenia = \"\";\r\n String direccion = \"\";\r\n Usuario instance = new Usuario();\r\n instance.Usuario(idUsuario, nombre, apellido, usuario, edad, genero, contrasenia, direccion);\r\n // TODO review the generated test code and remove the default call to fail.\r\n }",
"@Test(dataProvider = \"inputs\", dataProviderClass=TestData.class)\n\tpublic void testMethod(String firstName, String lastName, String age) {\n\t\tSystem.out.println(\"first name: \" + firstName);\n\t\tSystem.out.println(\"last name: \" + lastName);\n\t\tSystem.out.println(\"Age: \" + age);\n\t}"
] | [
"0.732544",
"0.6928395",
"0.6860416",
"0.6728718",
"0.66809505",
"0.6595788",
"0.65921664",
"0.65872735",
"0.6575684",
"0.64114815",
"0.6336937",
"0.6313328",
"0.62511086",
"0.6248487",
"0.6246826",
"0.6231465",
"0.6213114",
"0.6166533",
"0.6163155",
"0.61057675",
"0.609619",
"0.6064886",
"0.6060512",
"0.60165346",
"0.6002264",
"0.59972394",
"0.5982274",
"0.5970373",
"0.5948083",
"0.59007657",
"0.5898717",
"0.5885624",
"0.5874154",
"0.5871173",
"0.58604735",
"0.5846644",
"0.5816019",
"0.5813278",
"0.5799272",
"0.579309",
"0.57888377",
"0.57770866",
"0.5769429",
"0.5736587",
"0.5728913",
"0.57279265",
"0.57257175",
"0.57174283",
"0.5716787",
"0.57081056",
"0.5694221",
"0.56859344",
"0.5685836",
"0.5685565",
"0.5665999",
"0.56590194",
"0.5658441",
"0.56529915",
"0.56516016",
"0.56479746",
"0.5630031",
"0.56264913",
"0.5622981",
"0.5622039",
"0.5619343",
"0.56146336",
"0.5609987",
"0.56077397",
"0.55921596",
"0.55814815",
"0.5580954",
"0.55808645",
"0.5576375",
"0.5570805",
"0.55639595",
"0.5560363",
"0.5560059",
"0.5555986",
"0.555581",
"0.5552609",
"0.5552171",
"0.5551973",
"0.5551619",
"0.5549143",
"0.5543998",
"0.55381155",
"0.5536696",
"0.5531592",
"0.55315864",
"0.5527429",
"0.5523953",
"0.5518856",
"0.5516343",
"0.5514881",
"0.5514054",
"0.5513811",
"0.5508766",
"0.55086267",
"0.5507201",
"0.5505083",
"0.55042285"
] | 0.0 | -1 |
just for testing providing parameters | @org.testng.annotations.Test
@Parameters({ "message_0", "message_1" })
private void parametersAnnotation(String msg_0, String msq_1) {
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"protected void setupParameters() {\n \n \n\n }",
"public void checkParameters() {\n }",
"public void testgetParameter() throws Exception {\n\r\n\t}",
"@Test\n\tpublic void testGetRequestParameter() {\n\t}",
"@Test\n\tpublic void testParameters() {\n\t\tassertEquals(par, myReply.getParameters());\n\t}",
"private void validateInputParameters(){\n\n }",
"public void getParameters(Parameters parameters) {\n\n }",
"@Test\n public void verifyParametersInput() {\n // act\n book.setISBN(isbn);\n book.setAuthors(array);\n book.setPublisher(publisher);\n // verify\n verify(book).setISBN(isbn);\n verify(book).setAuthors(array);\n verify(book).setPublisher(publisher);\n }",
"@Override\n\t@Ignore\n\t@Test\n\tpublic void testLaunchParameters() throws Throwable {\n\t}",
"@Override\n\tprotected void initParams() {\n\t\t\n\t}",
"public abstract Instances _getTestingFromParams(String params);",
"@Test\n\tpublic void correctParameters() {\n\t\tassertEquals(startTime, circle.startTime);\n\t\tassertEquals(duration, circle.duration);\n\t\tassertEquals(type, circle.type);\n\t\tassertEquals(height, circle.height, 0);\n\t}",
"@Test\r\n \tpublic void testParameters() {\n \t\tParameters params = (Parameters) filter.getParameters();\r\n \t\t\t\t\t\t\r\n \t\tassertEquals(params.unescapeSource, true);\r\n \t\tassertEquals(params.trimLeading, true);\r\n \t\tassertEquals(params.trimTrailing, true);\r\n \t\tassertEquals(params.preserveWS, true);\r\n \t\tassertEquals(params.useCodeFinder, false);\r\n \t\tassertEquals(\t\t\t\t\r\n \t\t\t\t\"#v1\\ncount.i=2\\nrule0=%(([-0+#]?)[-0+#]?)((\\\\d\\\\$)?)(([\\\\d\\\\*]*)(\\\\.[\\\\d\\\\*]*)?)[dioxXucsfeEgGpn]\\n\" +\r\n \t\t\t\t\"rule1=(\\\\\\\\r\\\\\\\\n)|\\\\\\\\a|\\\\\\\\b|\\\\\\\\f|\\\\\\\\n|\\\\\\\\r|\\\\\\\\t|\\\\\\\\v\\nsample=\\nuseAllRulesWhenTesting.b=false\", \r\n \t\t\t\tparams.codeFinderRules);\r\n \t\t\t\t\t\t\t\t\t\r\n \t\t// Check if defaults are set\r\n \t\tparams = new Parameters();\r\n \t\tfilter.setParameters(params);\r\n \t\t\r\n \t\tparams.columnNamesLineNum = 1;\r\n \t\tparams.valuesStartLineNum = 1;\r\n \t\tparams.detectColumnsMode = 1;\r\n \t\tparams.numColumns = 1;\r\n \t\tparams.sendHeaderMode = 1;\r\n \t\tparams.trimMode = 1;\r\n \t\tparams.fieldDelimiter = \"1\";\r\n \t\tparams.textQualifier = \"1\";\r\n \t\tparams.sourceIdColumns = \"1\";\r\n \t\tparams.sourceColumns = \"1\";\r\n \t\tparams.targetColumns = \"1\";\r\n \t\tparams.commentColumns = \"1\";\r\n \t\tparams.preserveWS = true;\r\n \t\tparams.useCodeFinder = true;\r\n \t\t\r\n \t\tparams = getParameters();\r\n \t\t\r\n \t\tassertEquals(params.fieldDelimiter, \"1\");\r\n \t\tassertEquals(params.columnNamesLineNum, 1);\r\n \t\tassertEquals(params.numColumns, 1);\r\n \t\tassertEquals(params.sendHeaderMode, 1);\r\n \t\tassertEquals(params.textQualifier, \"1\");\r\n \t\tassertEquals(params.trimMode, 1);\r\n \t\tassertEquals(params.valuesStartLineNum, 1);\r\n \t\tassertEquals(params.preserveWS, true);\r\n \t\tassertEquals(params.useCodeFinder, true);\r\n \t\t\r\n \t\t// Load filter parameters from a file, check if params have changed\r\n //\t\tURL paramsUrl = TableFilterTest.class.getResource(\"/test_params1.txt\");\r\n //\t\tassertNotNull(paramsUrl); \r\n \t\t\r\n \r\n \t\ttry {\r\n \t\tString st = \"file:\" + getFullFileName(\"test_params1.txt\");\r\n \t\tparams.load(new URI(st), false);\r\n \t} catch (URISyntaxException e) {\r\n \t}\r\n \r\n \t\t\r\n \t\tassertEquals(\"2\", params.fieldDelimiter);\r\n \t\tassertEquals(params.columnNamesLineNum, 2);\r\n \t\tassertEquals(params.numColumns, 2);\r\n \t\tassertEquals(params.sendHeaderMode, 2);\r\n \t\tassertEquals(\"2\", params.textQualifier);\r\n \t\tassertEquals(params.trimMode, 2);\r\n \t\tassertEquals(params.valuesStartLineNum, 2);\r\n \t\tassertEquals(params.preserveWS, false);\r\n \t\tassertEquals(params.useCodeFinder, false);\r\n \t\t\r\n \t\t// Save filter parameters to a file, load and check if params have changed\r\n \t\tURL paramsUrl = TableFilterTest.class.getResource(\"/test_params2.txt\");\r\n \t\tassertNotNull(paramsUrl);\r\n \t\t\r\n \t\tparams.save(paramsUrl.getPath());\r\n \t\t\r\n \t\t// Change params before loading them\r\n \t\tparams = (Parameters) filter.getParameters();\r\n \t\tparams.fieldDelimiter = \"3\";\r\n \t\tparams.columnNamesLineNum = 3;\r\n \t\tparams.numColumns = 3;\r\n \t\tparams.sendHeaderMode = 3;\r\n \t\tparams.textQualifier = \"3\";\r\n \t\tparams.trimMode = 3;\r\n \t\tparams.valuesStartLineNum = 3;\r\n \t\tparams.preserveWS = true;\r\n \t\tparams.useCodeFinder = true;\r\n \t\t\r\n \t\tparams.load(Util.toURI(paramsUrl.getPath()), false);\r\n \t\t\r\n \t\tassertEquals(params.fieldDelimiter, \"2\");\r\n \t\tassertEquals(params.columnNamesLineNum, 2);\r\n \t\tassertEquals(params.numColumns, 2);\r\n \t\tassertEquals(params.sendHeaderMode, 2);\r\n \t\tassertEquals(params.textQualifier, \"2\");\r\n \t\tassertEquals(params.trimMode, 2);\r\n \t\tassertEquals(params.valuesStartLineNum, 2);\r\n \t\tassertEquals(params.preserveWS, false);\r\n \t\tassertEquals(params.useCodeFinder, false);\r\n \t\t\r\n \t\t// Check if parameters type is controlled\r\n \t\t\r\n \t\tfilter.setParameters(new net.sf.okapi.filters.plaintext.base.Parameters());\r\n \t\tInputStream input = TableFilterTest.class.getResourceAsStream(\"/csv_test1.txt\");\r\n \t\ttry {\r\n \t\t\tfilter.open(new RawDocument(input, \"UTF-8\", locEN));\r\n \t\t\tfail(\"OkapiBadFilterParametersException should've been trown\");\r\n \t\t}\r\n \t\tcatch (OkapiBadFilterParametersException e) {\r\n \t\t}\r\n \t\t\r\n \t\tfilter.close();\r\n \t\r\n \t\tfilter.setParameters(new net.sf.okapi.filters.table.csv.Parameters());\r\n \t\tinput = TableFilterTest.class.getResourceAsStream(\"/csv_test1.txt\");\r\n \t\ttry {\r\n \t\t\tfilter.open(new RawDocument(input, \"UTF-8\", locEN));\r\n \t\t}\r\n \t\tcatch (OkapiBadFilterParametersException e) {\r\n \t\t\tfail(\"OkapiBadFilterParametersException should NOT have been trown\");\r\n \t\t}\r\n \t\t\tfilter.close();\r\n \t}",
"void setParameters() {\n\t\t\n\t}",
"@Parameters({\"name\", \"lastName\"})\n @Test\n public void test1(String name, String lastName){\n System.out.println(\"Name is \"+ name);\n System.out.println(\"Last name is \"+ lastName);\n }",
"@Test\n\tpublic void Account_test() { Using HamCrest \t\t\n\t\t// Exercise code to run and test\n\t\t//\n\t\tmiCuenta.setHolder(this.arg1);\n\t\tString resHolder = miCuenta.getHolder(); \n\t\t//\n\t\tmiCuenta.setBalance(this.arg2);\n\t\tint resBalance = miCuenta.getBalance(); \n\t\t//\n\t\tmiCuenta.setZone(this.arg3);\n\t\tint resZone = miCuenta.getZone(); \n\t\t\t\t\t\t\n\t\t// Verify\n\t\tassertThat(this.arg1, is(resHolder));\n\t\tassertThat(this.arg2, is(resBalance)); \n\t\tassertThat(this.arg3, is(resZone)); \n\t}",
"private Params()\n {\n }",
"@Test (dataProvider= \"My data provider\")\r\n\tpublic void TestCalcParamitarized(String in1,String Op, String in2,String Expec){ //.... 1- Parameterized test method -Define method input parameters-\r\n\t\tCalc(in1, Op, in2);\r\n\t\tassertResult(Expec);\t\t\r\n\t}",
"public void getParameters(Parameters parameters) {\n\n\t}",
"@Test\n void getArgString() {\n }",
"@Test\n public void testValidParameters() {\n Map params = new HashMap();\n params.put(\"provider_url\", \"http://localhost:8080/v1/oauth/tokens\");\n params.put(\"grant_type\", \"password\");\n params.put(\"client_id\", \"test_client_1\");\n params.put(\"provider_id\", \"local\");\n params.put(\"basic_username\", \"test_client_1\");\n params.put(\"basic_password\", \"test_secret\");\n params.put(\"username\", \"test_client_1\");\n params.put(\"password\", \"test_secret\");\n PasswordGrant instance = new PasswordGrant();\n Boolean expResult = true;\n Boolean result = instance.validParameters(params);\n assertEquals(expResult, result);\n \n }",
"@Test\n public void MyTest() {\n System.out.println(\"Parameterized Number is : \" + inputNumber);\n System.out.println(\"Expected Result is : \" + expectedResult);\n }",
"@Override\r\n\t\t\tpublic void test() {\n\t\t\t}",
"@Override\r\n public void setParameter(String parameters) {\r\n // dummy\r\n }",
"@Test\r\n public void requestParameters() throws Exception {\r\n final ModuleURN instanceURN = new ModuleURN(PROVIDER_URN, \"mymodule\");\r\n final String requestParm = \"not null value\";\r\n new ExpectedFailure<IllegalRequestParameterValue>(\r\n org.marketcetera.module.Messages.ILLEGAL_REQ_PARM_VALUE,\r\n instanceURN.getValue(), requestParm) {\r\n public void run() throws Exception {\r\n mManager.createDataFlow(new DataRequest[]{\r\n new DataRequest(CopierModuleFactory.INSTANCE_URN,\r\n \"doesnt matter\"),\r\n new DataRequest(instanceURN, requestParm)\r\n });\r\n\r\n }\r\n };\r\n //Verify that the module instance is not leaked.\r\n List<ModuleURN> instances = mManager.getModuleInstances(PROVIDER_URN);\r\n assertTrue(instances.toString(), instances.isEmpty());\r\n }",
"@Before\n public void setUp() throws Exception {\n env = Environment.getInstance();\n parameterTypes = new Class[1];\n parameterTypes[0] = za.co.multichoice.environment.Tile.class;\n m = env.getClass().getDeclaredMethod(METHOD_NAME, parameterTypes);\n m.setAccessible(true);\n parameters = new Object[1];\n }",
"private void test() {\n\n\t}",
"@Test\r\n public void testParamterized()\r\n {\r\n test(Types.create(List.class).withType(Number.class).build());\r\n }",
"@Test\n public void testValidateParams() {\n String[] params;\n\n // valid params - just the application name\n params = new String[]{\"Application\"};\n instance.validateParams(params);\n\n // valid params - extra junk\n params = new String[]{\"Application\", \"Other\", \"Other\"};\n instance.validateParams(params);\n\n // invalid params - empty\n params = new String[0];\n try {\n instance.validateParams(params);\n fail(\"Expected IllegalArgumentException\");\n } catch (IllegalArgumentException ex) {\n // expected\n }\n\n // invalid params - null first param\n params = new String[]{null};\n try {\n instance.validateParams(params);\n fail(\"Expected IllegalArgumentException\");\n } catch (IllegalArgumentException ex) {\n // expected\n }\n\n // invalid params - empty string\n params = new String[]{\"\"};\n try {\n instance.validateParams(params);\n fail(\"Expected IllegalArgumentException\");\n } catch (IllegalArgumentException ex) {\n // expected\n }\n }",
"private LocalParameters() {\n\n\t}",
"private FunctionParametersValidator() {}",
"@Test\n public void noUpdateWhenNotValidParams() {\n }",
"@Test\n public void testUserDomainConstructorWithParams(){Not sure if this works\n //\n Set<RestaurantDomain> testRestaurantDomain = new HashSet<>();\n //\n\n testUserDomain = new UserDomain(1, \"[email protected]\", \"password\", \"jDawg\", \"John\", \"Dawson\", testRestaurantDomain);\n\n new Verifications(){{\n assertEquals(1, testUserDomain.getId());\n assertEquals(\"[email protected]\", testUserDomain.getEmail());\n assertEquals(\"password\", testUserDomain.getPassword());\n assertEquals(\"jDawg\", testUserDomain.getUserName());\n assertEquals(\"John\", testUserDomain.getFirstName());\n assertEquals(\"Dawson\", testUserDomain.getFirstName());\n assertEquals(testRestaurantDomain, testUserDomain.getRestaurantDomain());\n }};\n }",
"@Test\n public void testGetStandardParameter() {\n Mossa move00 = new Mossa(Mossa.Action.MOVE, 0, 2, 2);\n assertTrue(turn.controlStandardParameter(move00));\n Mossa move01 = new Mossa(Mossa.Action.BUILD, 0, 2, 2);\n assertTrue(turn.controlStandardParameter(move01));\n Mossa move02 = new Mossa(Mossa.Action.MOVE, -1, 2, 2);\n Mossa move03 = new Mossa(Mossa.Action.BUILD, 0, 3, 7);\n Mossa move04 = new Mossa(Mossa.Action.BUILD, 3, -4, 9);\n assertTrue(!turn.controlStandardParameter(move02));\n assertTrue(!turn.controlStandardParameter(move03));\n assertTrue(!turn.controlStandardParameter(move04));\n }",
"@Test\n\tpublic void testParameterizedConstructor() {\n\t\tQuestionsEntity questions=new QuestionsEntity(1,\"SOX\",\"Have all changes has been approved\",\"Yes\");\n\t assertEquals(\"Yes\",questions.getResponse());\n\t}",
"public ParamNameTest(String testName) {\n super(testName);\n }",
"@Test\n\tpublic void testProfessorConstructor2params(){\n\t\tString firstname = \"Steven\";\n\t\tString lastName = \"Beaty\";\n\t\tProfessor testProfessor = new Professor(firstname, lastName);\n\t\tAssert.assertEquals(\"Steven\", testProfessor.getFirstName());\n\t\tAssert.assertEquals(\"Beaty\", testProfessor.getLastName());\n\t}",
"boolean hasParameters();",
"@Test\n public void testPersonReturn(){\n// System.out.println(\"------->\"+ mHbParam.getId());\n }",
"@Test\n public void testLocateManager() {\n System.out.println(\"locateManager\");\n int x = 0;\n int y = 0; \n //instance.locateManager(x, y);\n \n }",
"@Test\n public void validSetFlightInformation() {\n testUser.setUsername(\"username\");\n testUser.setLastName(\"lastname\");\n testUser.setPassword(\"password\");\n testUser.setFirstName(\"firstname\");\n\n Assertions.assertEquals(\"username\", testUser.getUsername());\n Assertions.assertEquals(\"lastname\", testUser.getLastName());\n Assertions.assertEquals(\"password\", testUser.getPassword());\n Assertions.assertEquals(\"firstname\", testUser.getFirstName());\n }",
"private void validateParameters() {\r\n if (command == null) {\r\n throw new BuildException(\r\n \"'command' parameter should not be null for coverity task.\");\r\n }\r\n\r\n }",
"@Override\n public void testCreateRequestListSomeFilteredBySourceSystem(){\n }",
"@Override\n\tprotected void validateParameterValues() {\n\t\t\n\t}",
"protected void parametersInstantiation_EM() {\n }",
"public void testParameterize() throws Exception {\n Map parameters1 = new HashMap();\n\n Object[] test_values = {\n new Object[]{\"/foo/bar\", parameters1, \"/foo/bar\"},\n };\n\n for (int i = 0; i < test_values.length; i++) {\n Object tests[] = (Object[]) test_values[i];\n String test = (String) tests[0];\n Map parameters = (Map) tests[1];\n String expected = (String) tests[2];\n\n String result = NetUtils.parameterize(test, parameters);\n String message = \"Test \" + \"'\" + test + \"'\";\n assertEquals(message, expected, result);\n }\n\n Map parameters2 = new HashMap();\n parameters2.put(\"a\", \"b\");\n parameters2.put(\"c\", \"d\");\n \n String test = \"bar\";\n String expected1 = \"bar?a=b&c=d\";\n String expected2 = \"bar?c=d&a=b\";\n \n String message = \"Test \" + \"'\" + test + \"'\";\n \n String result = NetUtils.parameterize(test, parameters2); \n\n if (expected1.equals(result)) {\n assertEquals(message, expected1, result); \n } else {\n assertEquals(message, expected2, result); \n }\n }",
"public void testOneOrMoreParameters() {\n int nrParameters = methodToTest.getParameterTypes().length;\n Class[] params = methodToTest.getParameterTypes();\n Object[] foo = new Object[nrParameters];\n \n // set up all parameters. Some methods are invoked with\n // primitives or collections, so we need to create them\n // accordingly\n for (int i = 0; i < nrParameters; i++) {\n try {\n if (params[i].isPrimitive()) {\n String primitiveName = params[i]\n .getName();\n if (primitiveName.equals(\"int\")) {\n foo[i] = Integer.valueOf(0);\n }\n if (primitiveName.equals(\"boolean\")) {\n foo[i] = Boolean.TRUE;\n }\n if (primitiveName.equals(\"short\")) {\n foo[i] = new Short(\"0\");\n }\n } else if (params[i].getName().equals(\"java.util.Collection\")) {\n foo[i] = new ArrayList();\n } else {\n /*\n * this call could easily fall if there is e.g. no public\n * default constructor. If it fails tweak the if/else tree\n * above to accommodate the parameter or check if we need to\n * test the particular method at all.\n */\n foo[i] = params[i].newInstance();\n }\n } catch (InstantiationException e) {\n fail(\"Cannot create an instance of : \"\n + params[i].getName()\n + \", required for \"\n + methodToTest.getName()\n + \". Check if \"\n + \"test needs reworking.\");\n } catch (IllegalAccessException il) {\n fail(\"Illegal Access to : \"\n + params[i].getName());\n }\n }\n \n try {\n methodToTest.invoke(facade, foo);\n fail(methodToTest.getName()\n + \" does not deliver an IllegalArgumentException\");\n } catch (InvocationTargetException e) {\n if (e.getTargetException() instanceof IllegalArgumentException \n || e.getTargetException() instanceof ClassCastException\n || e.getTargetException() instanceof NotImplementedException) {\n return;\n }\n fail(\"Test failed for \" + methodToTest.toString()\n + \" because of: \"\n + e.getTargetException());\n } catch (NotImplementedException e) {\n // If method not supported ignore failure\n } catch (Exception e) {\n fail(\"Test failed for \" + methodToTest.toString()\n + \" because of: \" + e.toString());\n }\n }",
"private void constructionHelper(GenericServiceResult genericServiceResult) {\n\n assertEquals(this.string, genericServiceResult.get(\"string\"));\n assertEquals(this.integer, genericServiceResult.get(\"integer\"));\n assertEquals(this.floats, genericServiceResult.get(\"floats\"));\n\n assertTrue(checkIndices(0, \"string\"));\n assertTrue(checkIndices(1, \"integer\"));\n assertTrue(checkIndices(2, \"floats\"));\n }",
"Parameter createParameter();",
"private void getConfigParameters(String[] parameters, Map<String, String> params,\n String testName) {\n for (int i = 0; i < parameters.length; i++) {\n params.put(parameters[i], null);\n }\n Log.v(TAG, \"[\" + testName + \"] \" + \"params.size() = \" + params.size());\n File f = new File(CONFIG_FILE);\n assertTrue(testName + \" test file not exists: \" + CONFIG_FILE, f.exists());\n // test suite\n XmlParser parser = new XmlParser(CONFIG_FILE);\n Node testSuiteNode = parser.getRootNode();\n String testSuiteName = parser.getAttrValue(testSuiteNode, \"name\");\n Log.v(TAG, \"[\" + testName + \"] \" + \"testSuiteName = \" + testSuiteName);\n // test case\n Node testCaseNode = null;\n String testCaseName = null;\n NodeList nodeListTestCase = parser.getNodeList(testSuiteNode, \"TestCase\");\n for (int i = 0; i < nodeListTestCase.getLength(); i++) {\n testCaseNode = nodeListTestCase.item(i);\n String tempTestCaseName = parser.getAttrValue(testCaseNode, \"name\");\n Log.v(TAG, \"[\" + testName + \"] \" + \"testCaseName = \" + tempTestCaseName);\n if (0 == tempTestCaseName.compareTo(TAG)) {\n testCaseName = tempTestCaseName;\n break;\n }\n }\n // test\n NodeList nodeList = parser.getNodeList(testCaseNode, \"Test\");\n for (int i = 0; i < nodeList.getLength(); i++) {\n Node testNode = nodeList.item(i);\n String tempTestName = parser.getAttrValue(testNode, \"name\");\n Log.v(TAG, \"[\" + testName + \"] \" + \"testName = \" + tempTestName);\n if (0 == tempTestName.compareTo(testName)) {\n for (int j = 0; j < params.size(); j++) {\n String attrValue = parser.getAttrValue(parser.getNodeByName(testNode,\n parameters[j]), \"value\");\n params.put(parameters[j], attrValue);\n Log.v(TAG, \"[\" + testName + \"] \" + \"param = \" + parameters[j] + \" value = \"\n + params.get(parameters[j]));\n }\n break;\n }\n }\n }",
"public void testGetBasedata() {\n }",
"public void testBidu(){\n\t}",
"@Test\n\tpublic void testBuildWithMissingParametersThrowsException() {\n\t\tAssertions.assertThrows(IllegalArgumentException.class, () -> {\n\t\t\ttestling.build();\n\t\t});\n\t}",
"@Ignore\n\t@Test\n\tpublic void testParamNull() {\n\t\tregisterParamException(null, keyString, valueString);\n\t\tregisterParamException(groupString, null, valueString);\n\t\tregisterParamException(groupString, keyString, null);\n\t}",
"@Parameters\n public static Collection<Object[]> testParameters() {\n Collection<Object[]> params = new ArrayList<Object[]>();\n\n for (OPT opt: OPT.values()) {\n Object[] par = new Object[2];\n par[0] = opt;\n par[1] = opt.name();\n\n params.add( par );\n }\n\n return params;\n }",
"@Override\n public void test() {\n \n }",
"public boolean isParameterProvided();",
"@Test //make sure it comes from testNG\n public void testWithQueryParameterAndList(){\n given().accept(ContentType.JSON)\n .and().params(\"limit\",100)\n .when().get(ConfigurationReader.getProperty(\"hrapp.baseresturl\")+\"/employees\")\n .then().assertThat().statusCode(200)\n .and().assertThat().contentType(ContentType.JSON)\n .and().assertThat().body(\"items.employee_id\", hasSize(100));\n }",
"abstract int estimationParameter1();",
"private test5() {\r\n\t\r\n\t}",
"public void testGetInputArguments() {\n List<String> args = mb.getInputArguments();\n assertNotNull(args);\n for (String string : args) {\n assertNotNull(string);\n assertTrue(string.length() > 0);\n }\n }",
"@Test\n public void testWithPathParameters(){\n given().accept(ContentType.JSON)\n .and().params(\"limit\",100)\n .and().pathParams(\"employee_id\", 110)\n .when().get(ConfigurationReader.getProperty(\"hrapp.baseresturl\")+\"/employees/{employee_id}\")\n .then().assertThat().statusCode(200)\n .and().assertThat().contentType(ContentType.JSON)\n .and().assertThat().body(\"employee_id\", equalTo(110),\n \"first_name\", equalTo(\"John\"),\n \"last_name\", equalTo(\"Chen\"),\n \"email\", equalTo(\"JCHEN\") );\n }",
"@Test\n public void constructorTest(){\n String retrievedName = doggy.getName();\n Date retrievedBirthDate = doggy.getBirthDate();\n Integer retrievedId = doggy.getId();\n\n // Then (we expect the given data, to match the retrieved data)\n Assert.assertEquals(givenName, retrievedName);\n Assert.assertEquals(givenBirthDate, retrievedBirthDate);\n Assert.assertEquals(givenId, retrievedId);\n }",
"@Test\n public void testBuildWithMissingParametersThrowsException() {\n // Arrange\n\n // Assert\n exception.expect(IllegalArgumentException.class);\n\n // Act\n testling.build();\n }",
"@Test\r\n public void test_logEntrance1_OneParameter() throws Exception {\r\n paramNames = new String[] {\"p1\"};\r\n paramValues = new Object[] {123};\r\n LoggingWrapperUtility.logEntrance(log, signature, paramNames, paramValues);\r\n\r\n TestsHelper.checkLog(\"logEntrance\",\r\n \"DEBUG\",\r\n \"Entering method [method_signature].\",\r\n \"Input parameters [p1:123]\");\r\n }",
"boolean hasParameterValue();",
"protected void validateFact(Fact[] param) {\r\n\r\n }",
"String getExampleParameters();",
"@Test\n public void testGetProductInfo() throws Exception {\n }",
"public Parameters getParameters();",
"private void checkParams() throws InvalidParamException{\r\n String error = svm.svm_check_parameter(this.problem, this.param);\r\n if(error != null){\r\n throw new InvalidParamException(\"Invalid parameter setting!\" + error);\r\n }\r\n }",
"public abstract Result mo5059a(Params... paramsArr);",
"@Test\n public void request() throws Exception {\n\n\n }",
"@Test\n\tpublic void argumentTest() {\n\t\tSelectionController selectionController = new SelectionController();\n\t\ttry {\n\t\t\tselectionController.select(null);\n\t\t\tAssert.fail(\"The new selection was null\");\n\t\t} catch (NullPointerException e) {\n\t\t}\n\n\t\ttry {\n\t\t\tselectionController.unselect(null);\n\t\t\tAssert.fail(\"The new unselection was null\");\n\t\t} catch (NullPointerException e) {\n\t\t}\n\n\t\ttry {\n\t\t\tselectionController.reselect(null);\n\t\t\tAssert.fail(\"The new reselection was null\");\n\t\t} catch (NullPointerException e) {\n\t\t}\n\t}",
"public void readParameters()\n {\n readParameters(getData());\n }",
"@Test\npublic void testAddBalance(){ \n sut.addBalance(100,1,new Account());\n}",
"@Test\n public void testUserInsertionMethod() {\n\n assertEquals(\"must return empty string for success\", \"\", userQuery.createUser(\"[email protected]\", \"s\", \"01234\", \"yahia\", \"sh\",\n \"11918\"));\n assertEquals(\"must return error since duplicate email\", \"Email Error\", userQuery.createUser(\"[email protected]\", \"s\", \"01234\", \"yahia\", \"sh\",\n \"11918\"));\n assertEquals(\"one of the field is empty\", \"Parameter Error\", userQuery.createUser(\"[email protected]\", \"s\", \"\", \"yahia\", \"sh\",\n \"11918\"));\n\n }",
"final void getParameters()\r\n {\r\n hostName=getParameter(\"hostname\");\r\n\tIPAddress=getParameter(\"IPAddress\");\r\n\tString num=getParameter(\"maxSearch\");\r\n\tString arg=getParameter(\"debug\");\r\n\tserver=getParameter(\"server\");\r\n\tindexName=getParameter(\"indexName\");\r\n\tString colour=getParameter(\"bgColour\");\r\n\r\n\tif(colour==null)\r\n\t{\r\n\t bgColour=Color.lightGray;\r\n }\r\n else\r\n\t{\r\n\t try\r\n\t {\r\n\t bgColour=new Color(Integer.parseInt(colour,16));\r\n\t }\r\n\t catch(NumberFormatException nfe)\r\n\t {\r\n\t bgColour=Color.lightGray;\r\n\t }\r\n\t}\r\n\t\r\n\tcolour=getParameter(\"fgColour\");\r\n\tif(colour==null)\r\n\t{\r\n\t fgColour=Color.black;\r\n\t}\r\n\telse\r\n\t{\r\n\t try\r\n\t {\r\n\t fgColour=new Color(Integer.parseInt(colour,16));\r\n\t }\r\n\t catch(NumberFormatException nfe)\r\n\t {\r\n\t fgColour=Color.black;\r\n\t }\r\n\t}\r\n\r\n\t//Check for missing parameters.\r\n\tif(hostName==null && server==null)\r\n\t{\r\n\t statusArea.setText(\"Error-no host/server\");\r\n\t hostName=\"none\";\r\n\t}\r\n\r\n\tmaxSearch=(num == null) ? MAX_NUMBER_PAGES : Integer.parseInt(num);\r\n }",
"@Test\n public void testAlmUtilsExample() throws GeneralLeanFtException, ReportException, IOException {\n AlmRunInfo almRunInfo = AlmUtils.getAlmRunInfo();\n if (almRunInfo != null){\n // AlmUtils.getAlmRunInfo() returned object, the test is running from ALMreturn;\n // Create a string builder, and add the properties of the test running\n StringBuilder sb = new StringBuilder();\n sb.append(\"ALMUtils test info proeprties: <BR>\");\n sb.append(String.format(\"ServerUrl: '%s' <BR>\", almRunInfo.getServerUrl()));\n sb.append(String.format(\"TesterName: '%s' <BR>\", almRunInfo.getTesterName()));\n sb.append(String.format(\"TestId: '%d' <BR>\", almRunInfo.getTestId()));\n sb.append(String.format(\"TestName: '%s' <BR>\", almRunInfo.getTestName()));\n sb.append(String.format(\"TestSetId: '%d' <BR>\", almRunInfo.getTestSetId()));\n sb.append(String.format(\"TestSetName: '%s' <BR>\", almRunInfo.getTestSetName()));\n sb.append(String.format(\"RunId: '%d' <BR>\", almRunInfo.getRunId()));\n sb.append(String.format(\"RunName: '%s' <BR>\", almRunInfo.getRunName()));\n sb.append(String.format(\"TestInstanceId: '%d' <BR>\", almRunInfo.getTestInstanceId()));\n String stringToReport = sb.toString();\n Reporter.reportEvent(\"AlmUtils.getAlmRunInfo() Properties Check\", stringToReport);\n\n }\n\n try {\n Map<String, Object> testParams = almRunInfo.getParameters();\n\n if (testParams == null) {\n Reporter.reportEvent(\"AlmUtils.getAlmRunInfo() Parameters Check\",\n \"Test is not running from ALM, therefore no parameters in the test\");\n } else {\n String paramString = \"\";\n for (Map.Entry<String, Object> testParam : testParams.entrySet()) {\n paramString += String.format(\"Parameter name: '%s', parameter value: '%s' <BR>\", testParam.getKey(), testParam.getValue().toString());\n }\n Reporter.reportEvent(\"ALMUtils.getAlmRunInfo Parameters Check\", paramString);\n }\n } catch (NullPointerException e) {\n Reporter.reportEvent(\"Exception in AlmUtils.getAlmRunInfo() Parameters Check\",\n \"Test is not running from ALM, therefore no parameters in the test\");\n }\n }",
"ParameterList getParameters();",
"@Test\n public void testAddCity_3args02() {\n\n System.out.println(\"addCity_3args\");\n String cityName = \"cityTest\";\n Pair coordenates = new Pair(41.200000, -8.000000);\n int points = 30;\n\n boolean result = sn10.addCity(coordenates, cityName, points);\n assertTrue(result);\n }",
"@Test\n public void testQueryList(){\n }",
"@Override\n public void test(PageParam pageParam) {\n\n }",
"@Test\r\n public void test_logEntrance2_OneParameter() throws Exception {\r\n paramNames = new String[] {\"p1\"};\r\n paramValues = new Object[] {123};\r\n LoggingWrapperUtility.logEntrance(log, signature, paramNames, paramValues, true, Level.INFO);\r\n\r\n TestsHelper.checkLog(\"logEntrance\",\r\n \"INFO\",\r\n \"] Entering method [method_signature].\",\r\n \"Input parameters [p1:123]\");\r\n }",
"private void SetParameters(XmlTest test){\r\n\t\t for (Map.Entry<String,String> entry : TestsParamList.get(test.getName()).entrySet()){\r\n\t\t\t test.addParameter(entry.getKey(), entry.getValue());\r\n\t\t }\r\n\t}",
"@Test\n public void testValidNewUser() throws Exception {\n when(request.getParameter(\"username\")).thenReturn(\"testUser\");\n when(request.getParameter(\"radius\")).thenReturn(\"10000\");\n when(request.getParameter(\"searchQuery\")).thenReturn(\"milk tea\");\n when(request.getParameter(\"numResults\")).thenReturn(\"7\");\n \n new AddSearchHistoryServlet().service(request, response);\n \n ArrayList<SearchItem> si = db.getSearchItemfromSearch(userID);\n int searchID = si.get(0).searchID;\n \n assertEquals(si.get(0).searchQuery, \"milk tea\");\n assertEquals(si.get(0).numResults, 7); \n assertEquals(si.get(0).radius, 10000);\n \n db.deleteQueryfromSearchHistory(searchID);\n \n }",
"@Override\n\tprotected boolean validateRequiredParameters() throws Exception {\n\t\treturn true;\n\t}",
"String [] getParameters();",
"public interface Params {\n }",
"public void setParameters(String parameters);",
"public ParamShoppingCartTest(int precio1, int precio2) {\n \n this.precio1 = precio1;\n this.precio2 = precio2; \n }",
"public void testSetBasedata() {\n }",
"@Test\n public void bookHotelTest() throws BookHotelFault, DatatypeConfigurationException{\n // Booking of an hotel that doesn't require credit card \n BookHotelInputType input = CreateBookHotelInputType(\"booking_Hotel_4\", \"Tick Joachim\", \"50408824\", 2, 11);\n boolean result = bookHotel(input);\n assertEquals(true, result); \n }",
"public void setParameters(String parameters){\n this.parameters=parameters;\n }",
"protected void missingParams() {\r\n throw new IllegalStateException(\r\n \"Function is missing parameters: \" + getName());\r\n }",
"public static void main(String[] args) {\n\t\tTryMethodParam tm1 = new TryMethodParam(10);\r\n\t\ttm1.try1(tm1);\r\n\t\tSystem.out.println(tm1.par); //10\r\n\t\ttm1.try2(tm1);\r\n\t\tSystem.out.println(tm1.par); //12345\r\n\t\tString s = \"tryyy\";\r\n\t\tStringParam.giveString(s);\r\n\t\tSystem.out.println(s);\r\n\t\tStringParam.addString(s);\r\n\t\tSystem.out.println(s);\r\n\r\n\t}",
"@Override\n\tpublic void test() {\n\t\t\n\t}",
"@Test\r\n\tpublic void testSanity() {\n\t}",
"int expectIntParameter(String strParamName);",
"@Test\r\n public void testUsuario_8args() {\r\n System.out.println(\"Usuario\");\r\n Integer idUsuario = null;\r\n String nombre = \"\";\r\n String apellido = \"\";\r\n String usuario = \"\";\r\n Integer edad = null;\r\n String genero = \"\";\r\n String contrasenia = \"\";\r\n String direccion = \"\";\r\n Usuario instance = new Usuario();\r\n instance.Usuario(idUsuario, nombre, apellido, usuario, edad, genero, contrasenia, direccion);\r\n // TODO review the generated test code and remove the default call to fail.\r\n }",
"@Test(dataProvider = \"inputs\", dataProviderClass=TestData.class)\n\tpublic void testMethod(String firstName, String lastName, String age) {\n\t\tSystem.out.println(\"first name: \" + firstName);\n\t\tSystem.out.println(\"last name: \" + lastName);\n\t\tSystem.out.println(\"Age: \" + age);\n\t}"
] | [
"0.73260736",
"0.6928486",
"0.686074",
"0.6729013",
"0.66817236",
"0.659666",
"0.6592387",
"0.6586867",
"0.6575259",
"0.6412951",
"0.6336221",
"0.6313496",
"0.62514967",
"0.6249803",
"0.6246806",
"0.62312615",
"0.6213264",
"0.6166873",
"0.61632615",
"0.6106019",
"0.6096806",
"0.6065303",
"0.606098",
"0.601649",
"0.60021555",
"0.599697",
"0.59826314",
"0.5969597",
"0.5947945",
"0.590092",
"0.5899622",
"0.58860487",
"0.58739716",
"0.58722013",
"0.5860612",
"0.58469397",
"0.5816081",
"0.58133936",
"0.5799468",
"0.5793932",
"0.5789558",
"0.5778442",
"0.5769654",
"0.57383806",
"0.5730149",
"0.5728635",
"0.57258606",
"0.57170826",
"0.5716824",
"0.57083666",
"0.56938773",
"0.56861794",
"0.56853664",
"0.5684996",
"0.5667049",
"0.565923",
"0.56583136",
"0.565298",
"0.5652486",
"0.5648594",
"0.5630467",
"0.56263703",
"0.5622768",
"0.56213903",
"0.561773",
"0.5615426",
"0.5610038",
"0.5608794",
"0.5592438",
"0.55820686",
"0.558165",
"0.5581163",
"0.5575971",
"0.5571085",
"0.55649114",
"0.55603707",
"0.55602556",
"0.55572987",
"0.5555662",
"0.55534154",
"0.5552723",
"0.5552033",
"0.5551633",
"0.5547851",
"0.5545388",
"0.5538264",
"0.5537984",
"0.5533718",
"0.55318415",
"0.5527682",
"0.5524771",
"0.5518666",
"0.5515846",
"0.5515048",
"0.5514501",
"0.55138445",
"0.55088544",
"0.55083126",
"0.5506547",
"0.5505329",
"0.5504068"
] | 0.0 | -1 |
1 2 3 5 8 13 21 34 55 | public static long factorial(int num)
{
if (num >= 1) {
System.out.println("before num = " + num);
return factorial(num - 1) * num;
}
else
return 1;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"int getBlockNumbers(int index);",
"public static void main(String[] args) {\n\t\t\r\n\t\tint i, x=4,w=9,q;\r\n\t\tfor(i=-1;i<20;i+=3) {\r\n\t\t\tx++;\r\n\t\t\tfor(q=4;q<11;q++) {\r\n\t\t\t\tdo {\r\n\t\t\t\t\ti=+3;\r\n\t\t\t\t\tw=sizeof(i);\r\n\t\t\t\t\ti=x+w;\r\n\t\t\t\t\tx=w+i;\r\n\t\t\t\t\t\t\r\n\t\t\t\t} while (x<15);\r\n\t\t\t}\r\n\t\t}\r\n\t\tSystem.out.println(\"x:\"+x+\"i:\"+i);\r\n\r\n\t}",
"public static void main(String[] args) {\n int N = 100, i, j, min;\n System.out.println(\"Value of N: \" + N);\n\n for (i = 1; i <= N; i++)\n {\n for (j = 1; j <= N; j++)\n {\n min = i < j ? i : j;\n System.out.print(N - min + 1);\n }\n System.out.println();\n\n\n\n\n }\n}",
"public static void number_invsert(){\n for(int i=7; i > 0 ; i--){\n for(int j =1;j<=i;j++){\n System.out.print(j);\n }\n System.out.println();\n } \n }",
"public void multiplesOfFive()\n {\n int index = 10;\n int max = 95;\n\n while (index <= 95) {\n System.out.println(index);\n index += 5;\n }\n }",
"public static void main(String[] args){\n\n for(int n = 2; n < 102; n+=2)System.out.printf(\"%d\\n\",n);\n \n \n }",
"int getBlockNums(int index);",
"int getBlockNums(int index);",
"public static void pattern7(int input){\n\t\tfor(int i=1;i<=input;i++){\n\t\t\tfor(int j=1;j<=i;j++){\n\t\t\t\tSystem.out.print(j+\" \");\n\t\t\t}\n\t\t\tSystem.out.println();\n\t\t}\n\t}",
"public void Series() {\n\t\tint n=8,i=1,k=2,count=0;\n\t\tSystem.out.print(n+\" \");\n\t\twhile (count<5) {\n\t\t\tn=n*i;//12\n\t\t\tn=n-k;//9\n\t\t\tSystem.out.print(n+\" \");//9\n\t\t\ti++;\n\t\t\tk++;\n\t\t\tcount++;\n\t\t}\n\t\t/*System.out.println(n);//8\n\t\tn=n*1;//8\n\t\tn=n-2;//6\n\t\t\n\t\tSystem.out.println(n);//6\n\t\tn=n*2;//12\n\t\tn=n-3;//9\n\t\tSystem.out.println(n);//9\n\t\tn=n*3;//27\n\t\tn=n-4;//23\n\t\tSystem.out.println(n);\n\t\tn=n*4;//12\n\t\tn=n-5;*/\n\t\t\n\t\t/*System.out.println(n);\n\t\tn=n*5;//12\n\t\tn=n-6;\n\t\tSystem.out.println(n);*/\n\t\t\n\t}",
"int main()\n{\n int n;\n cin >>n;\n int m = 11;\n for(int i=0; i<n; i++){\n cout << m*m << \" \";\n m += 4;\n }\n}",
"public static void main(String[] args) {\n\t\t\n\t\t int m= 9, n= 1,x=0 ;\n\t\t \n\t\t while (m>n) {\n\t\t\t m--;\n\t\t\t n+=2;\n\t\t\t x+=m+n;\n\t\t\t \n\t\t\t \n\t\t\t \n\t\t\t \n\t\t }\n\t\t System.out.println(x);\n\t\t \n\t\t \n\t\t \n\t\t // a) 11\n\t \t// b) 13\n //c) 23\n //d) 36\n //e) 50\n\t\t\n\n\t}",
"public static void main(String[] args) {\n\r\n for (int x = 1; x < 10; x++) {// x=1\r\n\r\n for (int h = 1; h < 10; h++) { // h=1+1+1...8+1\r\n\r\n System.out.println(x + \"*\" + h \"=\" +x*h);// 1-2-3....8-9\r\n\r\n if(h==2){\r\n break;\r\n }\r\n }\r\n\r\n if(x==4){\r\n continue;\r\n }\r\n\r\n }\r\n\r\n }",
"public static void pattern10(int input){\n\t\tfor(int i= input;i >0;i--){\n\t\t\tfor(int j=i;j<=input;j++){\n\t\t\t\tSystem.out.print(j+\" \");\n\t\t\t}\n\t\t\tSystem.out.println();\n\t\t}\n\t}",
"@Test\n void first() {\n int[] answers = {1,2,3,4,5,1,2,3,4,5};\n int[] first = {1,2,3,4,5};\n int collect = 0;\n for (int i=0; i < answers.length ; i++) {\n if (answers[i] == first[i % 5]) {\n //0 0\n //1 1\n //2 2\n //3 3\n //4 4\n //5 0\n //6 1\n //7 2\n collect++;\n }\n }\n assertThat(collect).isEqualTo(10);\n }",
"@Test\n public void testRangeMultipleIterations() {\n final int start = 1;\n final int max = 7;\n final int step = 2;\n\n final List<Integer> seq = new ArrayList<>();\n final IntegerSequence.Range r = IntegerSequence.range(start, max, step);\n\n final int numTimes = 3;\n for (int n = 0; n < numTimes; n++) {\n seq.clear();\n for (Integer i : r) {\n seq.add(i);\n }\n Assert.assertEquals(4, seq.size());\n Assert.assertEquals(seq.size(), r.size());\n }\n }",
"public static void pattern9(int input){\n\t\tfor(int i= 1;i <= input;i++){\n\t\t\tfor(int j=i;j<=input;j++){\n\t\t\t\tSystem.out.print(j+\" \");\n\t\t\t}\n\t\t\tSystem.out.println();\n\t\t}\n\t}",
"public static void main(String[] args) {\n int[] array = new int[6];\n array[0] = 33;\n int[] arr = { 2, 3, 5, 7 };\n \n //1 2,5 4,7\n for (int i = 0; i < arr.length; i++) {\n // for ctrl space to bring for loop\n //3,6\n System.out.println(arr[i]);\n\t}\n\n}",
"public static void main(String[] args) {\n Scanner sc = new Scanner(System.in);\n int n = sc.nextInt();\n List<ArrayList<Integer>> lines = new ArrayList<>();\n for (int i = 0; i < n; i++) {\n int l = sc.nextInt();\n ArrayList<Integer> line = new ArrayList<>();\n for (int j = 0; j < l; j++) {\n line.add(sc.nextInt());\n }\n lines.add(line);\n }\n\n int k = sc.nextInt();\n for (int i = 0; i < k; i++) {\n int lineNumber = sc.nextInt();\n int elementNumber = sc.nextInt();\n\n if(lines.get(lineNumber - 1).size() >= elementNumber){\n System.out.println(lines.get(lineNumber - 1).get(elementNumber - 1));\n }else{\n System.out.println(\"ERROR!\");\n }\n }\n }",
"private static List<Integer> nextInt() {\n\t\tRandom rnd = new Random();\n\t\tList<Integer> l = new ArrayList<Integer>();\n\t\tfor (;;) {\n\t\t\tfinal int r = rnd.nextInt(5);\n\t\t\tif (!l.contains(r)) {\n\t\t\t\tl.add(r);\n\t\t\t}\n\t\t\tif (l.size() == 5)\n\t\t\t\treturn l;\n\t\t}\n\t}",
"public static void main(String[] args) {\n\t\tint a[]= {8,4,1,5,9,2};\r\n\t\tint n=6;\r\n\t\tfor(int i=1;i<n;i++)\r\n\t\t{\r\n\t\t\tint temp=a[i];\r\n\t\t\tint j=i-1;\r\n\t\t\twhile(j>=0 && a[j]>temp)\r\n\t\t\t{\r\n\t\t\t\ta[j+1]=a[j];\r\n\t\t\t\tj--;\r\n\t\t\t}\r\n\t\t\ta[j+1]=temp;\r\n\t\t}\r\n\t\t\r\n\t\tfor(int i=0;i<n;i++)\r\n\t\t{\r\n\t\t\tSystem.out.print(a[i]+\" \");\r\n\t\t}\r\n\r\n\t}",
"static void problemEight() {\n int i = 0;\n int prevNum = 1;\n System.out.println(i);\n while (i < 50) {\n int temp = i + prevNum;\n if (temp < 50) System.out.println(temp);\n prevNum = i;\n i = temp;\n }\n }",
"public static void main(String[] args) {\n Scanner scan = new Scanner(System.in);\n int n = scan.nextInt();\n ArrayList<ArrayList<Integer>> rows = new ArrayList<>();\n\n for (int i = 0; i < n; i++) {\n int r = scan.nextInt();\n ArrayList<Integer> row = new ArrayList<>();\n\n for (int j = 0; j < r; j++) {\n row.add(scan.nextInt());\n }\n rows.add(row);\n }\n\n int q = scan.nextInt();\n for (int k = 0; k < q; k++) {\n int x = scan.nextInt();\n int y = scan.nextInt();\n\n try {\n System.out.println(rows.get(x - 1).get(y - 1));\n } catch (IndexOutOfBoundsException e) {\n System.out.println(\"ERROR!\");\n }\n }\n }",
"public static void main(String[] args){\n int i = 0;\n int sum = 0;\n while (sum <= 10){\n i++;\n sum += i;\n System.out.println(i+ \",\" + sum);\n }\n }",
"public static void main(String[] args) {\n\t\tint value = 1;\n\t\t int count = 7;\n\t\t\tint curr = 0;\n\t\t\t int prev = 0;\n\t\t\tint num = 0;\n\t\twhile (value <= count)\n\t\t{\n\t\t\tnum = curr + prev;\n\t\t\tSystem.out.print(num);\t\n\t\t\t\tvalue++;\n\t\t\t\tif (value == 2)\n\t\t\t\t{\n\t\t\t\t\tprev = num;\n\t\t\t\t\tcurr = 1;\n\t\t\t\t}\n\t\t\t\t\t\tprev = curr;\n\t\t\t\t\t\tcurr = num;\n\t\t\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t}\n\n\t}",
"public static void pattern6(int input){\n\t\tint counter=1;\n\t\tfor(int i=1;i<=input;i++){\n\t\t\tfor(int j=counter;j<=(i*(i+1)/2);j++){\n\t\t\t\tSystem.out.print(counter++ + \" \");\n\t\t\t}\n\t\t\tSystem.out.println();\n\t\t}\n\t}",
"int main()\n{\n int n,p=0,n2=2;\n cin>>n;\n if(n>0)\n cout<<p<<\" \";\n for(int i=1;i<n;i++)\n {\n p=p+n2;\n cout<<p<<\" \";\n if(i%2==1)\n \tn2=n2+4;\n }\n \n}",
"public static void main(String[] args) {\n\t\tint number1 =0;\r\n\t\tint number2 =1;\r\n\t\tint number3,limit = 10;\r\n\t\t\r\n\t\tSystem.out.print(number1+\" \"+number2);\r\n\t\tint i=2;\r\n\t\tdo \r\n\t\t{\r\n\t\t\tnumber3= number1+number2;\r\n\t\t\tSystem.out.print(\" \"+number3);\r\n\t\t\tnumber1=number2;\r\n\t\t\tnumber2=number3;\r\n\t\t\ti++;\r\n\t\t}while(i<limit);\r\n\t}",
"int[] getGivenByOrder();",
"public static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n\t\tArrayList<Integer> list = new ArrayList<>();\n\t\tint n =5;\n\t\tfor (int i = 0; i <= n; i++) {\n\t\t\tint a = sc.nextInt();\n\t\t\tlist.add(a);\n\t\t\t\n\t\t}\n\t\t\n\t\tfor (int i = 0; i <list.size(); i++) {\n\t\t\tSystem.out.print(list.get(i)+\" \");\n\t\t\t\n\t\t}\n\t\tSystem.out.println();\n\t\tfor (int i = list.size()-1; i >=0; i--) {\n\t\t\tSystem.out.print(list.get(i)+\" \");\n\t\t\t\n\t\t}\n\t\tSystem.out.println();\n\t\t\n\t\tSystem.out.println(\"E__F___L\");\n\t\tfor(int val : list) {\n\t\t\tSystem.out.print(val+\" \");\n\t\t}\n\t\t\n\t\t\n\t\t\n\t\t\n\n\t}",
"public static void main(String[] args) {\n\t\tint num=5;\r\n\t\tint c=num*2-1;//5\r\n\t\tfor(int j=0 ; j< c ; j++){//j: 0, 1, 2,3 4\r\n\t\t\t\r\n\t\t\tif(j<num) {///j: 0, 1, 2\r\n\t\t\t\t// 1 ,2,3 : 0+1, 1+1, 2+1\r\n\t\t\t\tfor(int i=0; i<j+1 ; i++) {\r\n\t\t\t\t\tSystem.out.print(\"* \");\r\n\t\t\t\t}\r\n\t\t\t}else {//j: 3,4\r\n\t\t\t\t//2,1 : 5-3, 5-4\r\n\t\t\t\tfor(int i=0; i<c-j ; i++) {\r\n\t\t\t\t\tSystem.out.print(\"* \");\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\tSystem.out.println();\r\n\t\t}\r\n\t\t\r\n\t\t\r\n\r\n\t}",
"public static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n\t\tint N = sc.nextInt();\n\t\tint total = sc.nextInt();\n\t\tint lastAns = 0;\n\t\tList<List<Integer>> list = new ArrayList();\n\t\tfor (int i = 0; i < N; i++) {\n\t\t\tlist.add(new ArrayList());\n\t\t}\n\t\tfor (int i = 0; i < total; i++) {\n\t\t\tint q = sc.nextInt();\n\t\t\tint x = sc.nextInt();\n\t\t\tint y = sc.nextInt();\n\t\t\tint seq = (x ^ lastAns) % N;\n\t\t\tList<Integer> seqList = list.get(seq);\n\t\t\t\n\t\t\tswitch (q) {\n\t\t\t\tcase 1:\n\t\t\t\t\tseqList.add(y);\n\t\t\t\t\tlist.set(seq, seqList);\n\t\t\t\t\tbreak;\n\t\t\t\tcase 2:\n\t\t\t\t\tlastAns = seqList.get(y % seqList.size());\n\t\t\t\t\tSystem.out.println(lastAns);\n\t\t\t\t\tbreak;\n\t\t\t}\n\t\t\t\n\t\t\t\n\t\t}\n\t}",
"public static void main(String[] args) {\n\t\tint arr[] = {1, 14, 5, 20, 4,15, 2, 54, 20, 87, 98, 3, 1, 32};\n\t\tint n = arr.length;\n\t\tthreeWayPartition(arr, 14, 20);\n\t\t\n\t\tfor(int i =0;i<n;i++) {\n\t\t\t\n\t\t\tSystem.out.print(arr[i]+\",\");\n\t\t}\n\t\t\n\t\t\n\n\t}",
"public static void pattern12(int input){\n\t\tfor(int i= 1;i <= input;i++){\n\t\t\tfor(int j=i;j>1;j--){\n\t\t\t\tSystem.out.print(j+\" \");\n\t\t\t}\n\t\t\tfor(int k=1;k<=i;k++){\n\t\t\t\tSystem.out.print(k+\" \");\n\t\t\t}\n\t\t\tSystem.out.println();\n\t\t}\n\t}",
"public static void main(String[] args) {\n Scanner scan = new Scanner(System.in);\n int primesTill = scan.nextInt();\n\n int[] arr = new int[30];\n arr[0] = 2;\n arr[1] = 3;\n arr[2] = 5;\n arr[3] = 7;\n arr[4] = 11;\n int tracker = 5;\n for(int i = 11; i <= primesTill; i = i+ 2) {\n if (i % 3 == 0)\n continue;\n if (i % 5 == 0)\n continue;\n if (i % 7 == 0)\n continue;\n if (i % 11 == 0)\n continue;\n arr[tracker] = i;\n tracker++;\n }\n\n for(int i : arr) {\n if(i == 0)\n break;\n else\n System.out.println(i);\n }\n }",
"public static void main(String[] args) {\n\t\tint i=0;\r\n\t\tint j=0;\r\n\t\tint cnt=0;\r\n\t\t\r\n while(true) {//무한 반복\r\n i=(int)(Math.random()*6)+1;//첫번째 주사위 1<=i<=6\r\n j=(int)(Math.random()*6)+1;//두번째 주사위 1<=j<=6\r\n if(i+j==5) break;//무한 반복을 빠져나가는 조건\r\n cnt++;\r\n }\r\n \r\n System.out.println(\"(\"+i+\",\"+j+\")\");\r\n\t System.out.println(\"총반복횟수:\"+cnt);\r\n\t\t\r\n\t}",
"public static void main(String[] args) {\n Scanner in = new Scanner(System.in);\n int size = in.nextInt();\n int[] a = new int[100];\n for (int i = 0; i < size; i++) {\n int j = in.nextInt();\n a[j] = a[j] + 1;\n }\n\n for(int n : a){\n System.out.print(n+\" \");\n }\n System.out.println(\"\");\n }",
"public static void main(String[] args) {\n Scanner sc=new Scanner(System.in);\n int n=sc.nextInt();\n ArrayList<ArrayList<Integer>> arrlist=new ArrayList<ArrayList<Integer>>();\n for(int i=1;i<=n;i++)\n {\n ArrayList<Integer> row=new ArrayList<Integer>();\n int d=sc.nextInt();\n for(int j=1;j<=d;j++)\n {\n row.add(sc.nextInt());\n }\n arrlist.add(row);\n }\n\n //ArrayList<Integer> arr=new ArrayList<Integer>();\n int q=sc.nextInt();\n for(int i=0;i<q;i++)\n {\n int x=sc.nextInt();\n int y=sc.nextInt();\n try\n {\n\n System.out.println(arrlist.get(x-1).get(y-1));\n }\n catch(Exception e)\n {\n System.out.println(\"error\");\n }\n }\n\n\n }",
"private static int[] p1(int[] ar, int n) {\n int[] p1 = new int[n];\n Arrays.fill(p1, -1);\n Stack<Integer> st = new Stack<>();\n for (int i = 0; i < n; i++) {\n while (st.size() != 0 && ar[i] <= ar[st.peek()]) {\n st.pop();\n }\n if (st.size() != 0) {\n p1[i] = st.peek();\n }\n st.push(i);\n }\n return p1;\n }",
"private static int[] enumerate(String in, int min, int max) {\n List<Integer> result = new ArrayList<Integer>();\n \n // a, b, c\n StringTokenizer tok = new StringTokenizer(in.trim(), \",\");\n while (tok.hasMoreTokens()) {\n \n String str = tok.nextToken().trim();\n int stepsize = 1;\n int start = min;\n int end = max;\n \n // Extract the step size, */2 or 7-10/2\n int stepdivider = str.indexOf('/');\n if (stepdivider > 0) {\n try {\n stepsize = Integer.parseInt(str.substring(stepdivider + 1));\n if (!\"*\".equals(str.substring(0, str.indexOf('/'))))\n throw new IllegalArgumentException(\"Malformed stepsize expression '\" + str + \"', first argument should be *\");\n for (int i = 0; i < max; i++) {\n if (i % stepsize == 0)\n result.add(i);\n }\n return toIntArray(result);\n } catch (NumberFormatException e) {\n throw new IllegalArgumentException(\"Illegal stepsize in '\" + str + \"'\");\n }\n }\n \n // *, 7-12, 13\n int hyphen = str.indexOf('-');\n if (str.startsWith(\"*\")) {\n return new int[] {};\n } else if (hyphen > 0) {\n try {\n start = Integer.parseInt(toNumber(str.substring(0, hyphen)));\n end = Integer.parseInt(toNumber(str.substring(hyphen + 1)));\n } catch (NumberFormatException e) {\n throw new IllegalArgumentException(\"Invalid interval in '\" + str + \"'\");\n }\n } else {\n try {\n start = end = Integer.parseInt(toNumber(str));\n } catch (NumberFormatException e) {\n throw new IllegalArgumentException(\"Invalid number: '\" + str + \"'\");\n }\n }\n \n // Check for minimum / maximum\n if (start < min)\n throw new IllegalArgumentException(\"Value \" + start + \" in '\" + in + \"' is smaller than the minimum of \" + min);\n if (end > max)\n throw new IllegalArgumentException(\"Value \" + end + \" in '\" + in + \"' is larger than the maximum of \" + min);\n \n // Return the result\n for (int i = start; i <= end; i += stepsize) {\n result.add(new Integer(i));\n }\n \n }\n return toIntArray(result);\n }",
"int getRange();",
"public static void main(String args[] ) throws Exception {\n \n Scanner s = new Scanner(System.in);\n List<String> inputList = new ArrayList<String>(); \n int limit = Integer.parseInt(s.nextLine());\n while (s.hasNextLine()) {\n \n String scanValue = s.nextLine();\n inputList.add(scanValue); \n } \n\n List<Integer> intList = getAllValuesArr(inputList);\n \n intList.stream().forEach(i -> {\n\n IntStream.range(1, i+1).forEach(num -> { \n printRangeNumbers(num); \n });\n });\n \n\n\n }",
"public static void main(String[] args) {\n\t\t\n\t\tfor(int i=1; i<=4; i++) {\n\t\t\tfor(int j=1; j<=4; j++) {\n\t\t\t\t\n\t\t\t\tSystem.out.print(j+ \" \");\n\t\t\t}\n\t\t\t\n\t\t\tSystem.out.println();\n\t\t}\n\n\t\t//1, 1 2, 1 2 3\n\t\tfor(int i=1; i<=5; i++) {\n\t\t\tfor(int j=1; j<=i; j++) {\n\t\t\t\t\n\t\t\t\tSystem.out.print(j+ \" \");\n\t\t\t}\n\t\t\t\n\t\t\tSystem.out.println();\n\t\t}\n\t\t\n\t\t//5, 5 4, 5 4 3.....\n\t\tfor(int i=5; i>=1; i--) {\n\t\t\tfor(int j=5; j>=i; j--) {\n\t\t\t\t\n\t\t\t\tSystem.out.print(j+ \" \");\n\t\t\t}\n\t\t\t\n\t\t\tSystem.out.println();\n\t\t}\n\t\t\n\t\t//5, 4 4, 3 3 3.....\n\t\t\t\tfor(int i=5; i>=1; i--) {\n\t\t\t\t\tfor(int j=5; j>=i; j--) {\n\t\t\t\t\t\t\n\t\t\t\t\t\tSystem.out.print(i+ \" \");\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\tSystem.out.println();\n\t\t\t\t}\n\n\n\t}",
"public static void main(String[] args) {\n\t\tint a=4;\r\n\t\tint b=16;\r\n\t\tfor (int i=1; i<5; i++){\r\n\t\t\tfor (int j=b; j>=a; j=j-4){\r\n\t\t\t\tSystem.out.print(j);\r\n\t\t\t\tSystem.out.print(\"\\t\");\r\n\t\t\t}\r\n\t\t\tb--;\r\n\t\t\ta--;\r\n\t\t\tSystem.out.println();\r\n\t\t}\r\n\t}",
"public static void main(String[] args) {\n\t\tint N = 234;\n\t\tint times=N%10;\n\t\tN/=10;\n\t\tint temp=N/10,sum=0;\n\t\twhile(times>0)\n\t\t{\n\t\t\tint rem=N%10;\n\t\t\tsum=temp+rem;\n\t\t\ttemp=sum;\n\t\t\ttimes--;\n\t\t}\n\t\tSystem.out.println(temp);\n\t\n\t}",
"private static int[] p2(int[] ar, int n) {\n int[] p2 = new int[n];\n Arrays.fill(p2, n);\n Stack<Integer> st = new Stack<>();\n for (int i = 0; i < n; i++) {\n while (st.size() != 0 && ar[i] < ar[st.peek()]) {\n p2[st.peek()] = i;\n st.pop();\n }\n st.push(i);\n }\n return p2;\n }",
"public static void main(String[] args) {\n Scanner scn = new Scanner(System.in);\n\t\tint n = new.nextInt();\n\t\tint v1=1,v2=0,v3=0;\n\t\tfor(int a=n;a>=1;a--){\n\t\t\tv3=v2+v1;\n\t\t\tSystem.out.print(v3+\"\\t\");\n\t\t\tv1=v2;\n\t\t\tv2=v3;\n\t\t}\n\t}",
"public static void main(String[] args) {\n int arr[]= new int[100];\n for(int i=0;i<=99;i++)\n {\n \t if(i!=55)\n \t\t arr[i]=i+1;\n \t System.out.print(arr[i]+\" \");\n }\n int sum=0,sum1=0;\n for(int i=0;i<100;i++)\n {\n \t sum=sum+(i+1);\n \t sum1=sum1+arr[i];\n \t \n }\n System.out.println(\"\\n\"+(sum-sum1));\n\t}",
"public static void main(String[] args) {\nint[] num = new int[10];\r\nfor (int i= 0; i < 10; i++) {\r\n\tnum[i] = ((i+1)*10);\r\n}\r\nint i=0;\r\nwhile(i<10) {\r\n\tSystem.out.println(\"num[\"+ i + \"]\" + num[i]);\r\n\ti++;\r\n\r\n}\r\n\t}",
"private int chunks(List<Integer> S){\n\t\tint c = 1;\n\t\tfor(int i = 0; i < S.size() -1; i++) {\n\t\t\tif(comps(S.get(i), S.get(i+1)) && S.get(i+1) < S.get(i)){\t\t\n\t\t\t\tc++;\n\t\t\t}\n\t\t}\n\t\treturn c;\n\t}",
"public static void main(String args[])\n {\n int n,min= Integer.MAX_VALUE;\n Scanner sc = new Scanner(System.in);\n n = sc.nextInt();\n \n int a[] = new int[n];\n for(int i=0;i<n;i++){\n a[i] = sc.nextInt();\n }\n \n for(int i=0;i<n-1;i++){\n min = i;\n for(int j=i+1;j<n;j++){\n \tif(a[j]<a[min]){\n min=j;\n \n }\n \n }\n if(i!=min){\n int tt = a[i];\n a[i] = a[min];\n a[min] = tt;\n }\n }\n \n for(int i=0;i<n;i++)\n System.out.print(a[i] + \" \");\n }",
"public static void main(String[] args) {\nScanner sc=new Scanner(System.in);\r\nint n=sc.nextInt();\r\n\r\nList<Integer> l=new ArrayList<Integer>();\r\nfor(int i=1;i<=n;i++){\r\n\tif(i%2!=0)\r\n\t{\r\n\t\tl.add(i);\r\n\t}\r\n}\r\n\tSystem.out.println(l);\r\n\tint n1=l.get(0);\r\n\tfor(int i=0;i<l.size();i++){\r\n\tif(i%2==0)\r\n\t\r\n\t\tn1=n1-l.get(i);\r\n\t//System.out.println(s);\r\n\telse\r\n\t\tn1=n1+l.get(i);\r\n\t}\r\n\tSystem.out.println(n1+1);\r\n\t}",
"public static void main(String[] args) {\r\n\t\tint numRows = 15;\r\n\t\tfor(List<Integer> list : generate(numRows)){\r\n\t\t\tfor( Integer i : list ){\r\n\t\t\t\tSystem.out.print(i + \" \");\r\n\t\t\t}\r\n\t\t\tSystem.out.println();\r\n\t\t}\r\n\t}",
"public void exercise_4_31()\n {\n int index = 0;\n int sum = 0;\n \n while (index < 10) {\n index++;\n sum += index;\n }\n System.out.println(sum);\n }",
"include <stdio.h>\nint main() {\n int n;\n\tscanf(\"%d\", &n);\n int num=1;\n\tfor(int i = 1; i <= n; i++){\n\t for(int space = 1; space <= n - i; space++){\n\t printf(\" \");\n\t }\n\t for(int j = 1; j <= i; j++){\n\t printf(\"%d \",num);\n num++;\n\t }\n\t printf(\"\\n\");\n\t}\n\treturn 0;\n}",
"public static void main(String[] args) {\n\r\n\t\tint uBound=11, sum=0;\r\n\t\tint i=1;\r\n\t\twhile(i<=uBound) {\r\n\t\t\tif(i==1) {\r\n\t\t\t\tSystem.out.print(i);\r\n\t\t\t\tsum=sum+i;\r\n\t\t\t}else {\r\n\t\t\t\tSystem.out.print(\"+\"+i);\r\n\t\t\t\tsum=sum+i;\r\n\t\t\t}\r\n\t\t\ti+=1;\r\n\t\t}\r\n\t\tSystem.out.println(\"=\"+sum);\r\n\t}",
"public static void main(String[] args) {\nint i=1;\nwhile(i<=10)\n{\n\tSystem.out.println(i+\"raj\");//display nos from 1 to 10 and raj \n\ti=i+1;\n}\n\t}",
"public static void main(String[] args) \n\t{\n\t\t int i=20, j=40;\n\t\t int k=0;\n\t\t ArrayList<Integer> l1=new ArrayList<Integer>();\n\t\t ArrayList<Integer> l2=new ArrayList<Integer>();\n\t\t for(int a=i;a<=j;a++){\n\t\t int count=0;\n\t\t for(int b=2;b<a;b++)\n\t\t if(a%b==0)\n\t\t count++;\n\t\t if(count==0)\n\t\t l1.add(a); }\n\t\t for(int e=i;e<=j;e++)\n\t\t l2.add(e);\n\t\t l2.removeAll(l1);\n\t\t for(int d=0;d<l2.size();d++)\n\t\t k=k+l2.get(d);\n\t\t \n\t\tSystem.out.println(k);\n\t}",
"public static void main(String[] args) {\n\t\tint c = 7;\r\n\t\tfor(int i=1;i<=4;i++)\r\n\t\t{\r\n\t\t\tfor(int j=0;j<i;j++)\r\n\t\t\t{\r\n\t\t\t\tSystem.out.print(c+\" \");\r\n\t\t\t\tc++;\r\n\t\t\t}\r\n\t\t\tSystem.out.println();\r\n\t\t}\r\n\r\n\t}",
"static List<String> packNumbers(List<Integer> arr) {\n List<String> result = new ArrayList<>();\n for (int i = 0; i < arr.size(); i++) {\n Integer item = arr.get(i);\n\n int numSibling = 1;\n for (int j = i+1; j < arr.size(); j++) {\n Integer nextItem = arr.get(j);\n if (item.equals(nextItem)) {\n numSibling++;\n i++;\n } else {\n break;\n }\n }\n\n if (numSibling == 1) {\n result.add(String.valueOf(item));\n } else {\n result.add(item + \":\" + numSibling);\n }\n }\n return result;\n }",
"public static void main(String[] args){\r\n\r\n Integer[] arr = {21,12,36,65,33,11,9,3};\r\n int arrlength = arr.length;\r\n outer:while(true){\r\n for(int leftPosition=0; leftPosition < arrlength; leftPosition++){\r\n int next = (leftPosition+1);\r\n if(next < arrlength){\r\n int left = arr[leftPosition];\r\n int right = arr[next];\r\n if(left>right){\r\n arr[leftPosition]=right;\r\n arr[next]=left;\r\n continue outer;\r\n }\r\n }\r\n }\r\n break outer;\r\n }\r\n String result = StringUtils.join(arr, \",\");\r\n System.out.println(result);\r\n }",
"void findLeadrsInArray2(int[] a){\n\t\tint n = a.length;\n\t\tSystem.out.println(a[n-1]);\n\t\tint max = a[n-1];\n\t\tfor(int i = n-2; i>=0 ; i--){\n\t\t\tif(a[i] < max){\n\t\t\t\tmax = a[i];\n\t\t\t\tSystem.out.println(a[i]);\n\t\t\t\t\n\t\t\t}\n\t\t}\n\t}",
"public static void main(String[] args) {\n\n Scanner myScanner = new Scanner(System.in);\n int numero;\n int i;\n\n System.out.println(\"Ingrese un numero\");\n numero = myScanner.nextInt();\n\n for (i = numero; i<=numero+20; i ++) {\n System.out.println(i);\n }\n\n\n }",
"public static void main(String[] args) {\n\t\tint a[]= {2,5,7,8,4,6,3};\n\t\tint start=0;\n\t\tint end=a.length-1;\n\t\tint minindex=0;\n\t\tint maxindex=0;\n\t\twhile(end>start)\n\t\t{\n\t\t minindex=start;\n\t\t maxindex=end;\n\t\t for (int i =start; i <=end; i++) \n\t\t {\n\t\t\tif(a[i]<a[minindex])\n\t\t\t{\n\t\t\t\tminindex=i;\n\t\t\t}\n\t\t\tif(a[i]>a[maxindex])\n\t\t\t{\n\t\t\t\tmaxindex=i;\n\t\t\t}\n\t\t }\n\t\t \n\t\tint temp=a[end];\n\t\t a[end]=a[maxindex];\n\t\t a[maxindex]=temp;\n\t\t temp=a[start];\n\t\t a[start]=a[minindex];\n\t\t a[minindex]=temp;\n\t\t start++;end--;\n\t\t}\n\t\tSystem.out.println(Arrays.toString(a));\n\n\t}",
"public static void main(String[] args) {\n Integer arr[] = new Integer[]{1, 1, 1, 2, 2, 2, 2, 2, 4, 4, 5, 5, 5, 6, 6, 6};\n for (int i = 0; i <= 8; i++) {\n\n int floorIndex = floor(arr, i);\n System.out.println(\"the floor index of \" + i + \" is \" + floorIndex + \".\");\n if (floorIndex >= 0 && floorIndex < arr.length)\n System.out.println(\"The value is \" + arr[floorIndex] + \".\");\n System.out.println();\n\n int ceilIndex = ceil(arr, i);\n System.out.println(\"the ceil index of \" + i + \" is \" + ceilIndex + \".\");\n if (ceilIndex >= 0 && ceilIndex < arr.length)\n System.out.println(\"The value is \" + arr[ceilIndex] + \".\");\n System.out.println();\n\n System.out.println();\n }\n }",
"public static void main(String args[]) {\n Scanner in = new Scanner(System.in);\n int n=in.nextInt();\n int a[]=new int[n];\n int c=0,e=0;\n for(int i=0;i<n;i++)\n a[i]=in.nextInt();\n int b[]=new int[10];\n int d[]=new int[10];\n for(int j=0;j<n;j++)\n {\n if(a[j]==0)\n {\n b[c++]=a[j];\n }\n else\n {\n d[e++]=a[j];\n }\n }\n for(int k=0;k<=e;k++)\n a[k]=d[k];\n int f=(n-e)-1;\n for(int l=1;l<=f;l++)\n a[e+l]=0;\n for(int m=0;m<n;m++)\n System.out.print(a[m]+\" \");\n \n }",
"int main() \n{\n int i=0,n,arr[20];\n cin>>n;\n while(n)\n {\n arr[i] = n%10;\n n/=10;\n i++;\n }\n for(n=0;n<i;n++)\n cout<<arr[n];\n\treturn 0;\n}",
"private final int m()\n\t { int n = 0;\n\t int i = 0;\n\t while(true)\n\t { if (i > j) return n;\n\t if (! cons(i)) break; i++;\n\t }\n\t i++;\n\t while(true)\n\t { while(true)\n\t { if (i > j) return n;\n\t if (cons(i)) break;\n\t i++;\n\t }\n\t i++;\n\t n++;\n\t while(true)\n\t { if (i > j) return n;\n\t if (! cons(i)) break;\n\t i++;\n\t }\n\t i++;\n\t }\n\t }",
"public static void m7() {\r\n\tchar ch ='A';\r\n\tfor(int i=1;i<=5;i++) {\r\n\t\tfor(int j =1;j<=i;j++)\r\n\t\t{\r\n\t\t\tSystem.out.print(ch);\r\n\t\t}\r\n\t\tch++;\r\n\t\tSystem.out.println();\r\n\t}\r\n}",
"static void minimumBribes(int[] q) {\n \t\n \tfor(int i=0;i<q.length;i++){\n if((q[i] - (i+1)) > 2){\n System.out.println(\"Too chaotic\");\n return; \n }\n }\n \n int swaps=0;\n for(int i=0;i< q.length;i++){\n for(int j=i+1;j<q.length;j++){\n if(q[i] > q[j]){ \n int tmp=q[j];\n q[j]=q[i];\n q[i]=tmp;\n swaps++;\n }\n }\n }\n \n System.out.println(swaps);\n \n }",
"public static void main(String[] args) {\n\t\tScanner scan = new Scanner(System.in);\n int n = scan.nextInt();\n int [] dp = new int [n+1];\n \n dp[0] = 0;\n dp[1] = 0;\n \n for(int i=2; i<=n; i++) {\n dp[i] = dp[i-1]+1; //n이 나누어떨어지는 것과 관계없는 n-1을 일단 dp[i]에 넣어둔다.\n if(i%2 == 0) dp[i] = Math.min(dp[i/2]+1, dp[i]); \n if(i%3 == 0) dp[i] = Math.min(dp[i/3]+1, dp[i]);\n }\n System.out.println(dp[n]);\n\n\n\t}",
"public int[] numbers();",
"public static void main(String[] args) {\n\t\tfor(int i = 1, j = i + 10; i < 5; i++, j = i * 2) \r\n\t\t{\r\n System.out.println(\"i= \" + i + \" j= \" + j);\r\n\t\t}\r\n\t\tfor(int i=0, j=i+99; i<101; i++, j=i/2 ) {\r\n\t\t\tSystem.out.println(\"i= \" +i + \" j= \"+j);\r\n\t}\r\n\t\t\r\n\t\tint n=0;\r\n\t\twhile(n<10)\r\n\t\t{ System.out.println(n);\r\n\t\tn++;\r\n\t\t}\r\n\t\t\r\n//\t int a = 1;\r\n//\t int b = 2;\r\n//\t int c = 3;\r\n//\t \r\n//\t a += 5;\r\n//\t b *= 4;\r\n//\t c += a * b;\r\n//\t c %= 6;\r\n//\t System.out.println(\"a = \" + a);\r\n//\t System.out.println(\"b = \" + b);\r\n//\t System.out.println(\"c = \" + c);\r\n\r\n\r\n\t}",
"public static void main(String[] args) {\n\t\tint first;\n\t\tint second;\n\t\tfor (first=0; first <=5; first++) {\n\t\t\tfor (second=0; second<=5;second++) {\n\t\t\t\tSystem.out.printf(\"%d%d\\t\",first,second);//is there any kind of methode u can represent with 00\n\t\t\t\t\n\t\t\t}\n\t\t\tSystem.out.println();\n\t\t}\n\n\t}",
"public static void main(String[] args) {\n for (int i = 1; i <= 5; i++) {\n for (int j = 1; j <= 5; j++) {\n System.out.println(i + \" \" + j);\n }\n\n /*\n * I J\n * 1 1\n * 1 2\n * 1 3\n * 1 4\n * 1 5\n * 2 1\n * 2 2\n * 2 3\n * 2 4\n * 2 5\n * 3 1\n * --------\n * 5 1\n * 5 2\n * 5 3\n * 5 4\n * 5 5\n *\n *\n * */\n /*\n for(int i=1;i<=5;i++){\n }\n for i = 1\n ---------\n * i=1 , i = i+1 = 1 + 1 = 2\n * i=2 , = 2 + 1 = 3\n * i=3 , = 3 + 1 = 4\n * i=4,\n * */\n\n /*\n\n for i = 2\n ---------\n * i=2 , i = i+1 = 2 + 1 = 3\n * i=3 , = 3 + 1 = 4\n * i=4,\n * */\n /*int l;\n for ( l= 1;l <=10; l++){\n System.out.println(l);\n }*/\n\n /*int l =0;\n for ( ;; l++){\n System.out.println(l);\n }\n*/\n }\n }",
"public static void method_3(){\n int totalhotdog = 400;\n int hotDogPerContainer = 8;\n int totalContainer =0;\n int temp = totalhotdog+hotDogPerContainer;\n\n while (temp>hotDogPerContainer){\n temp = temp - hotDogPerContainer;\n System.out.println(temp);\n totalContainer++;\n }\n System.out.println(\"\\n \\n\\n\\n\\n \"+totalContainer);\n }",
"public void Series() {\n\t\tint n=2;\n\t\twhile (n<=10) {\n\t\t\tSystem.out.print(n+\" \");\n\t\t\tn=n+2;\n\t\t}\n\t/*\tSystem.out.println(n);\n\t\tn=n+2;\n\t\tSystem.out.println(n);\n\t\tn=n+2;\n\t\tSystem.out.println(n);\n\t\tn=n+2;\n\t\tSystem.out.println(n);\n\t\tn=n+2;\n\t\tSystem.out.println(n);\n\t\tn=n+2;*/\n\t}",
"public static void main(String[] args) {\n Scanner sc = new Scanner(System.in);\n int N = sc.nextInt();\n int[] A = new int[N];\n for(int i = 0; i < N; i++){\n A[i] = sc.nextInt();\n }\n int B = sc.nextInt();\n B = B % N;\n int[] ans = new int[N];\n for (int i = 0; i < N; ++i){\n ans[i] = A[(i - B + N) % N];\n }\n for(int i = 0; i < N; i++){\n System.out.print(ans[i] + \" \");\n }\n System.out.println();\n sc.close();\n }",
"public static void main(String args[]) {\n Scanner in=new Scanner(System.in);\n int n=in.nextInt();\n int arr[]=new int[n];\n for(int i=0;i<n;i++)\n arr[i]=in.nextInt();\n int val=in.nextInt();\n int c=0;\n while(c<n)\n {\n for(int i=c+1;i<n;i++)\n {\n if(arr[c]+arr[i]==val)\n System.out.println(arr[c]+\", \"+arr[i]);\n }\n c++;\n }\n }",
"public static void main(String[] args) {\n\t\t\n\t int a, b;\n\t int arr[] = { 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20 };\n\t int range[][]={{3,7}, {4,6}, {5,5}};\n\n\t for (int i = 0; i < range.length; i++){\n\t \t\n\t \ta = range[i][0];\n\t \tb = range[i][1];\n\n\t\t\tfor(int j = 0; j < (b-a)/2; j++){\n\t\t\t\tint temp = arr[a-1+j];\n\t\t\t\tarr[a-1+j] =arr[b-1-j]; \n\t\t\t\tarr[b-1-j] = temp;\n\t\t\t}\n\t }\n\n\t\tSystem.out.print (\"결과 : \"+\"[ \");\n\t\t\n\t\tfor(int i=0; i<arr.length ; i++ ) {\n\t\t\tSystem.out.print (arr[i] + \" \" );\n\n\t\t}\n\t\tSystem.out.print (\"]\");\n\t}",
"private int bepaalByes(int[] arr, int n) {\r\n\t\tint tot = 0;\r\n\t\tfor (int v : arr)\r\n\t\t\ttot += v;\r\n\t\treturn (tot - n);\r\n\t}",
"public static void main(String[] args) {\n IntStream.range(0, 10)\n .forEach(System.out::print);\n\n System.out.println();\n\n // print the range of elements but skip first 5\n IntStream.range(0, 10)\n .skip(5)\n .forEach(System.out::print);\n\n // Integer stream with sum\n System.out.println(\n IntStream\n .range(0, 10)\n .sum());\n\n }",
"public static void main(String[] args) {\n\n\t\tint number = 32841;\n\t\tint temp = 32841;\n\t\t/*\n\t\t * int number = 32814; int temp = 32814;\n\t\t */\n\t\t// 14823\n\t\t// 12843\n\t\tArrayList<Integer> listOfNumbers = new ArrayList<Integer>();\n\t\tArrayList<Integer> newList = new ArrayList<Integer>();\n\n\t\twhile (temp > 0) {\n\t\t\tint digit = temp % 10;\n\t\t\ttemp = temp / 10;\n\t\t\tlistOfNumbers.add(digit);\n\t\t}\n\n\t\tint i = 0;\n\t\tint j = i + 1;\n\t\t// Checking the asecending order\n\t\tfor (i = 0; i < listOfNumbers.size() - 1; i++) {\n\n\t\t\tif (listOfNumbers.get(j) < listOfNumbers.get(i)) {\n\t\t\t\tSystem.out.println(listOfNumbers.get(i + 1));\n\t\t\t\tSystem.out.println(i + 1);\n\t\t\t\tbreak;\n\t\t\t}\n\t\t\tSystem.out.println(j);\n\t\t\tj++;\n\t\t}\n\n\t\t// j = 0;\n\n\t\t// replacing the 2 and 4\n\t\tfor (int m = 0; m < listOfNumbers.size() - 1; m++) {\n\n\t\t\tif ((Integer) listOfNumbers.get(m) > (Integer) listOfNumbers.get(i + 1)) {\n\t\t\t\tSystem.out.println(\" i = \" + i);\n\t\t\t\tSystem.out.println(\"value at m is \" + listOfNumbers.get(m));\n\t\t\t\tSystem.out.println(\"value at i is \" + listOfNumbers.get(i + 1));\n\t\t\t\tint swap = listOfNumbers.get(m);\n\t\t\t\tlistOfNumbers.set(m, listOfNumbers.get(i + 1));\n\t\t\t\tlistOfNumbers.set(i + 1, swap);\n\t\t\t\tbreak;\n\n\t\t\t}\n\t\t}\n\t\t// getting the sub list and sorting them\n\t\tList<Integer> subList = listOfNumbers.subList(0, i + 1);\n\t\tCollections.sort(subList);\n\t\tCollections.reverse(subList);\n\n\t\t// creating a new list wit the next higher number\n\t\tfor (int k = listOfNumbers.size(); k > i + 1; k--) {\n\t\t\tnewList.add(listOfNumbers.get(k - 1));\n\t\t}\n\n\t\tfor (int k = 0; k < subList.size(); k++) {\n\t\t\tnewList.add(subList.get(k));\n\t\t}\n\n\t\tfor (int k = 0; k < newList.size(); k++) {\n\t\t\tSystem.out.print(newList.get(k));\n\t\t}\n\t}",
"public static void main(String[] args) {\r\n\t\t\r\n\t\tfor(int i = 1;i<= 7; i++)\r\n\t\t{\r\n\t\t\tfor(int j = 1;j<= i;j++)\r\n\t\t\t{\r\n\t\t\t\tSystem.out.print(j+\" \");\r\n\t\t\t}\r\n\t\t\tSystem.out.println();\r\n\t\t}\r\n\t\tfor(int i = 6; i>=1; i--)\r\n\t\t{\r\n\t\t\tfor(int j = 1;j<=i; j++)\r\n\t\t\t{\r\n\t\t\t\tSystem.out.print(j+\" \");\r\n\t\t\t}\r\n\t\t\tSystem.out.println();\r\n\t\t}\r\n\t\t\r\n\t\t\r\n\t\t\r\n\t}",
"public static void show() {\r\n\t\t int[] forword=new int[6];\r\n\t\t int[] temp;\r\n\t\t for(int i=1;i<7;i++){\r\n\t\t\t temp=Arrays.copyOf(forword, 6);\r\n\t\t\t for(int j=0;j<i;j++){\r\n\t\t\t\t if(j==0){\r\n\t\t\t\t\t forword[0]=i;\r\n\t\t\t\t\t System.out.print(forword[0]+\" \");\r\n\t\t\t\t }else{\r\n\t\t\t\t\t forword[j]=forword[j-1]+temp[j-1];\r\n\t\t\t\t\t System.out.print(forword[j]+\" \");\t\t \r\n\t\t\t\t }\r\n\t\t\t }\r\n\t\t\t \r\n\t\t\t System.out.println();\r\n\t\t }\r\n\t\t //0-9:48-57 ; A-Z:65-90 ; a-z:97-122 \r\n\t\t\r\n\t}",
"public static void main(String[] args) {\n int []a = {1,2,3,7,8,9,13,14,15,19,20,21};\n int []b = {4,5,6,10,11,12,16,17,18,22,23,24};\n int []c = new int[a.length+b.length];\n /*\n a = new int[12];\n b = new int[12];\n c = new int[a.length+b.length];\n \n \n for (int i = 0; i < 12; i++) {\n System.out.println((i+1)+\" Digite el elemento: \");\n a[i] = entrada.nextInt();\n }\n \n for (int i = 0; i < 12; i++) {\n System.out.println((i+1)+\" Digite el elemento: \");\n b[i] = entrada.nextInt();\n \n }\n*/\n int aux1 = 0;\n int aux2 = 3;\n int aux3 = 6;\n for (int i = 0; i < 12; i++) {\n \n c[aux1] = a[i];\n aux1++;\n c[aux2] = b[i];\n aux2++;\n \n if(aux2 == aux3)\n {\n aux1 = aux3;\n aux2+=3;\n aux3 +=6;\n }\n \n }\n \n for (int i:c) {\n System.out.println(i);\n \n }\n \n }",
"public static void main(String[] args) {\n int[] arr = new int[] {2,3,1,4,6};\n partition(arr, 0, arr.length - 1);\n for(int i : quickselect(arr, 0, arr.length - 1)) {\n System.out.print(i);\n }\n }",
"public static void main(String[] args) {\n\t\tScanner get = new Scanner(System.in);\r\n\t\t\r\n\t\t//---------------------------------- 1 -----------------------------\r\n\t\t/*\r\n\t\tint n=5;\r\n\t\tint num[] =new int[n];\r\n\t\tfloat avg=0,sum=0,max=0,mini=0;\r\n\t\t\r\n\t\t\r\n\t\tfor(int i=0;i<n;i++) {\r\n\t\t\tSystem.out.format(\"Enter your number[%d] :\",i+1);\r\n\t\t\tnum[i] = get.nextInt();\r\n\t\t\tsum += num[i];\r\n\t\t\tif(i==0) {\r\n\t\t\t\tmax=num[i];\r\n\t\t\t\tmini=num[i];\r\n\t\t\t}\r\n\t\t\telse {\r\n\t\t\t\tif(num[i]>max) {\r\n\t\t\t\t\tmax = num[i];\r\n\t\t\t\t}\r\n\t\t\t\tif(num[i]<mini) {\r\n\t\t\t\t\tmini = num[i];\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t\t\r\n\t\tavg = sum/n;\r\n\t\t\r\n\t\tSystem.out.println(\"\\n\\naverang of number = \" + avg);\r\n\t\tSystem.out.println(\"maximum of number = \" + max);\r\n\t\tSystem.out.println(\"minimum of number = \" + mini);\r\n\t\tSystem.out.println(\"sum of number = \" + sum);\r\n\t\t */\r\n\t\t\r\n\t\t\r\n\t\t\r\n\t\t//------------------------------------- 2 -------------------------------------------\r\n\t\t/*\r\n\t\tint a[]= {1,2,3,4,5,6,7},b[]= {8,9,10,11,12,13,14},ab[]=new int[a.length+b.length];\r\n\t\tint i=0;\r\n\t\t\r\n\t\tfor(i=i;i<a.length;i++) {\r\n\t\t\tab[i]=a[i];\r\n\t\t}\r\n\t\tfor(i=a.length;i<a.length+b.length;i++) {\r\n\t\t\tab[i]=b[i-a.length];\r\n\t\t}\r\n\t\tSystem.out.println(\"number of ab[] = \"+(a.length+b.length));\r\n\t\tfor(i=0;i<a.length+b.length;i++) {\r\n\t\t\tSystem.out.print(ab[i]+\"\\t\");\r\n\t\t\tif((i+1)%3==0)\r\n\t\t\t{\r\n\t\t\t\tSystem.out.print(\"\\n\");\r\n\t\t\t}\r\n\t\t}\r\n\t\t*/\r\n\t\t\r\n\t\t\r\n\t\t\r\n\t\t//-------------------------------- 3 ---------------------------------\r\n\t\t\r\n\t\tint i,j;\r\n\t\tchar start='a',alphabet[] = new char [26];\r\n\t\t\r\n\t\tfor(int k=0;;k++) {\r\n\t\t\tSystem.out.print(\"Pleas enter your number : \");\r\n\t\t\tj = get.nextInt();\r\n\t\t\tif(j>0 && j<=26) {\r\n\t\t\t\tfor(i=0;i<j;i++) {\r\n\t\t\t\t\talphabet[i]=start;\r\n\t\t\t\t\tSystem.out.format(\"%c \\n\",alphabet[i]);\r\n\t\t\t\t\tstart++;\r\n\t\t\t\t}\r\n\t\t\t\t\r\n\t\t\t}\r\n\t\t\t\r\n\t\t}\r\n\t\r\n\t\t\r\n\t\t\r\n\t\t\r\n\t\t\r\n\t\t\r\n\t\t//----------------------------- 4 ------------------------------\r\n\t\t/*\r\n\t\tint num,i;\r\n\t\tSystem.out.print(\"How number to calculate :\");\r\n\t\tnum = get.nextInt();\r\n\t\tfloat in[]=new float[num],out[]=new float[num],sum = 0,sqr=0;\r\n\t\t\r\n\t\tfor(i=0;i<num;i++){\r\n\t\t\tSystem.out.format(\"number [%d]:\",i+1);\r\n\t\t\tin[i]=get.nextFloat();\r\n\t\t\t\r\n\t\t}\r\n\t\tfor(i=0;i<num;i++) {\r\n\t\t\tsum+=Math.pow(in[i], 2);\r\n\t\t}\r\n\t\t\r\n\t\tsqr=(float) Math.sqrt(sum);\r\n\t\t\r\n\t\tSystem.out.println(\"\\n\");\r\n\t\tfor(i=0;i<num;i++)\r\n\t\t{\r\n\t\t\tout[i]=in[i]/sqr;\r\n\t\t\tSystem.out.format(\"out[%d] : %.6f\\n\",i,out[i]);\r\n\t\t}\r\n\t\t\r\n\t\t*/\r\n\t\t\r\n\t}",
"public static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n\t\tint n = sc.nextInt();\n\t\tint[] arr = new int[n+1];\n\t\tint[] list = new int[n+1];\n\t\tfor(int i=1; i<=n; i++) {\n\t\t\tarr[i] = sc.nextInt();\n\t\t}\n\t\tlist[0] = 0;\n\t\tlist[1] = arr[1];\n\t\tif(n>=2) {\n\t\t\tlist[2] = arr[1] + arr[2];\n\t\t}\n\t\tif(n>=3) {\n\t\t\tfor(int i=3; i<=n; i++) {\n\t\t\t\tint a = arr[i] + arr[i-1] + list[i-3];\n\t\t\t\tint b = arr[i] + list[i-2];\n\t\t\t\tint c = list[i-1];\n\t\t\t\tlist[i] = Math.max(c, Math.max(a, b));\n\t\t\t}\n\t\t}\n\t\tSystem.out.println(Math.max(list[n], list[n-1]));\n\t\t\n\t}",
"public static void main(String[] args) {\n\t\tRandom random = new Random();\n\t\tScanner scan = new Scanner(System.in);\n\t\tint n = scan.nextInt();\n//\t\tSystem.out.print(n);\n\t\tint[] lotto = new int[6];\n\t\tString str = \"[\";\n\t\t\n\t\tfor(int i=0; i<n; i++) {\n\t\t\tfor(int j=0; j<6; j++) {\n\t\t\t\tlotto[i] = random.nextInt(45)+1;\n\t\t\t\tif (j == 5) {\n\t\t\t\t\tstr += String.valueOf(lotto[i])+\"\";\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tstr += String.valueOf(lotto[i])+\", \";\n\t\t\t\t}\n\t\t\t}\n\t\t\tstr += \"]\";\n\t\t\t\n\t\t\tSystem.out.println((i+1) + \"번째 : \" + str);\n\t\t\tstr = \"[\";\n\t\t}\n\t}",
"public static void main(String[] args) {\n\t\tScanner scr = new Scanner(System.in);\n\t\tSystem.out.print(\"반복할 횟수를 입력하시오 ->\");\n\t\tint n = scr.nextInt();\n\n\t\tint[] a = new int[] {3,8,9,7,6};\n\n\t\tint temp=0;\n\n\t\tfor(int i=0; i<n; i++) {\n\t\t\ttemp=a[a.length-1];\n\t\t\tfor(int j=a.length-1; j>0; j--) {\n\t\t\t\ta[j]=a[j-1];\n\t\t\t}\n\t\t\t\n\t\t\ta[0]=temp;\n\t\t}\n\t\t\n\t\tfor(int i=0; i<a.length; i++) {\n\t\t\tSystem.out.printf(\"%d \" , a[i]);\n\t\t}\n\n\t}",
"private static void eval5(){\n for(int i = 0; i < 46; i++){\n for(int j = i + 1; j < 47; j++){\n for(int k = j + 1; k < 48; k++){\n for(int l = k + 1; l < 49; l++){\n for(int m = l + 1; m < 50; m++){\n Evaluator.evaluate(i, j, k, l, m);\n }\n }\n }\n }\n }\n }",
"static void minimumBribes(int[] q) {\n int swaps = 0;\n for (int i = 0; i < q.length; i++) {\n if ((q[i] - (i+1)) > 2) {\n System.out.println(\"Too chaotic\");\n return;\n }\n for (int j = i + 1; j < q.length; j++) {\n if (q[i] > q[j]) {\n int t = q[j];\n q[j] = q[i];\n q[i] = t;\n swaps++;\n }\n }\n }\n\n System.out.println(swaps);\n }",
"private static void skipByExample(List<Integer> numbers) {\n\t\tList<Integer> skippedNumbers = numbers.stream().skip(5).collect(Collectors.toList());\r\n\t\tint fifthNumber = numbers.stream().skip(5 - 1).findFirst().orElse(0);\r\n\t\tList<Integer> firstFiveNumber = numbers.stream().limit(5).collect(Collectors.toList());\r\n\t\tSystem.out.println(skippedNumbers); // Output: [6, 7, 8, 9, 10]\r\n\t\tSystem.out.println(\"5th number = \" + fifthNumber);\r\n\t\tSystem.out.println(\"Limit of 5 number = \" + firstFiveNumber);\r\n\t}",
"public static void main(String[] args) {\n\t\tint[] num = {1,1,5};\r\n\t\tnextPermutation(num);\r\n\t\tfor(int n : num)\r\n\t\t\tSystem.out.print(n + \" \");\r\n\t}",
"int main()\n{\n int size,max=0,min=0;\n cin>>size;\n int a[size];\n for(int i=0;i<size;i++)\n {\n cin>>a[i];\n }\n for(int i=0;i<size;i++)\n {\n if(a[i]>a[max])\n max=i;\n if(a[i]<a[min])\n min=i;\n }\n if (min < max) \n cout << max + (size - min - 2); \n else\n cout << max + (size - min - 1);\n return 0;\n}",
"public static void main(String[] args) {\n\t\tint i=1;\r\n\t\t/*while (i<=10){\r\n\t\t\tSystem.out.println(i);\r\n\t\t\ti=i+1;\r\n\t\t}\r\n\t\tint j=10;\r\n\t\twhile (j>1){\r\n\t\t\tSystem.out.println(j);\r\n\t\t\tj=j-1;\r\n\t\t\t\r\n\t\t}*/\r\n\t\t\r\n\t\tfor (i=0;i<10;i++)\r\n\t\t{\r\n\t\t\tSystem.out.println(i);\r\n\t\t}\r\n\t\tfor (int j=10;j>=1;j--)\r\n\t\t{\r\n\t\t\tSystem.out.println(j);\r\n\t\t}\r\n\r\n\t}",
"public static int Main()\n\t{\n\tint[] b = new int[12];\n\tint w;\n\tint i;\n\tint[] a = {13, 44, 72, 103, 133, 164, 194, 225, 256, 286, 317, 347};\n\tString tempVar = ConsoleInput.scanfRead();\n\tif (tempVar != null)\n\t{\n\t\tw = Integer.parseInt(tempVar);\n\t}\n\tfor (i = 0;i < 12;i++)\n\t{\n\t\tb[i] = a[i] % 7 - 1;\n\t\tb[i] = (b[i] + w) % 7;\n\t}\n\tfor (i = 0;i < 12;i++)\n\t{\n\t\tif (b[i] == 5)\n\t\t{\n\t\t\tSystem.out.printf(\"%d\\n\",i + 1);\n\t\t}\n\t}\n\treturn 0;\n\t}",
"public static void main(String[] args) {\nint arr[]= {1,2,3,4,5};\r\nint i;\r\nint temp;\r\nfor(i=0; i<arr.length/2;i++)\r\n{\r\n\ttemp=arr[i];\r\n\tarr[i]=arr[arr.length-1-i];\r\n\tarr[arr.length-1-i]=temp;\r\n\t}\r\nfor(i=0; i<=arr.length-1;i++ )\r\n{\r\nSystem.out.print(arr[i]);\r\n\r\n\r\n}\r\n\t}",
"List<Integer> getNeighbors(int x);",
"public static void main(String[] args) {\n Scanner scanner = new Scanner(System.in);\n int n = scanner.nextInt();\n int c = 0;\n int p = 0;\n int prev = 0;\n while (n-- > 0) {\n int a = scanner.nextInt();\n if (p == 0 ) {\n p = 1;\n } else if (prev != a - 1) {\n if (p >= 3) c+= p - 2;\n p = 1;\n } else if (prev == a - 1) {\n p++;\n }\n prev = a;\n }\n if (p >= 3) c+= p - 2;\n System.out.print(c);\n }"
] | [
"0.5923046",
"0.5848804",
"0.58124477",
"0.5806093",
"0.57987773",
"0.5754637",
"0.5729853",
"0.5729853",
"0.5640769",
"0.5630782",
"0.5603268",
"0.55966336",
"0.5590208",
"0.55712676",
"0.5541461",
"0.5540386",
"0.5529022",
"0.5516127",
"0.55136037",
"0.5506411",
"0.5486723",
"0.5483198",
"0.54733664",
"0.54709226",
"0.54665005",
"0.54165065",
"0.5414729",
"0.5401948",
"0.5394608",
"0.53933173",
"0.5393211",
"0.5390582",
"0.538956",
"0.5379793",
"0.53774875",
"0.537596",
"0.5369676",
"0.5359155",
"0.5352062",
"0.53450954",
"0.53401726",
"0.5336162",
"0.5329752",
"0.5326276",
"0.53227097",
"0.53216356",
"0.53197813",
"0.5307249",
"0.53061557",
"0.53000534",
"0.5299793",
"0.5288923",
"0.5282496",
"0.527544",
"0.52743536",
"0.52714133",
"0.52708596",
"0.5267997",
"0.52661514",
"0.5255885",
"0.52548885",
"0.52534014",
"0.5252232",
"0.52509123",
"0.52415925",
"0.52371156",
"0.52225876",
"0.5222367",
"0.52197105",
"0.52165824",
"0.5214603",
"0.52116686",
"0.5211083",
"0.5210451",
"0.52100396",
"0.52092034",
"0.52081627",
"0.5207788",
"0.520679",
"0.5203069",
"0.5201423",
"0.5198152",
"0.5197701",
"0.5194007",
"0.51885355",
"0.5176779",
"0.51756394",
"0.5172539",
"0.5169085",
"0.5159368",
"0.5158975",
"0.515601",
"0.5154947",
"0.51547086",
"0.5153893",
"0.5152903",
"0.51518404",
"0.51514953",
"0.51508",
"0.5147889",
"0.5145176"
] | 0.0 | -1 |
Create an image file name | private File createFilePictures() throws IOException {
String timeStamp = new SimpleDateFormat("yyyyMMdd_HHmmss").format(new Date());
String pictureName = "BEER_" + timeStamp + "_";
File storageDir = getActivity().getExternalFilesDir(Environment.DIRECTORY_PICTURES);
File image = File.createTempFile(
pictureName, /* prefix */
".jpg", /* suffix */
storageDir /* directory */
);
// Save a file: path for use with ACTION_VIEW intents
currentPicturePath = image.getAbsolutePath();
return image;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"private File createImageFileName() throws IOException {\n String timestamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n //there are two types of SimpleDateFormat and Date()\n String prepend = \"JPEG_\" + timestamp + \"_\";\n File imageFile = File.createTempFile(prepend, \".jpg\", mImageFolder);\n mImageFileName = imageFile.getAbsolutePath();\n return imageFile;\n\n }",
"public void createNewImageFile(){\n fillNewImage();\n\n try {\n ImageIO.write(newImage, imageFileType, new File(k + \"_Colored_\" + fileName.substring(0,fileName.length() - 4) + \".\" + imageFileType));\n } catch (IOException e){\n e.printStackTrace();\n }\n \n }",
"private static File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = JPEG_FILE_PREFIX + timeStamp + \"_\";\n File albumF = getAlbumDir();\n File imageF = File.createTempFile(imageFileName, JPEG_FILE_SUFFIX, albumF);\n return imageF;\n }",
"private static File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = JPEG_FILE_PREFIX + timeStamp + \"_\";\n File albumF = getAlbumDir();\n File imageF = File.createTempFile(imageFileName, JPEG_FILE_SUFFIX, albumF);\n return imageF;\n }",
"private File createImageFile() throws IOException {\n // Create an image file name\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"MAZE_\" + timeStamp + \"_\";\n File storageDir = getExternalFilesDir(Environment.DIRECTORY_PICTURES);\n File image = File.createTempFile(\n imageFileName, /* prefix */\n \".jpg\", /* suffix */\n storageDir /* directory */\n );\n return image;\n }",
"private File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = JPEG_FILE_PREFIX + timeStamp + \"_\";\n File albumF = getAlbumDir();\n File imageF = File.createTempFile(imageFileName, JPEG_FILE_SUFFIX, albumF);\n return imageF;\n }",
"private File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\")\n .format(new Date());\n String imageFileName = JPEG_FILE_PREFIX + timeStamp + \"_\";\n File albumF = getAlbumDir();\n File imageF = File.createTempFile(imageFileName, JPEG_FILE_SUFFIX,\n albumF);\n return imageF;\n }",
"private File createImageFile() throws IOException{\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"JPEG_\"+timeStamp;\n File image = File.createTempFile(imageFileName, \".jpg\", this.savePath);\n \n return image;\n }",
"private File createImageFile() throws IOException {\n // Create an image file name\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\n File storageDir = getExternalFilesDir(Environment.DIRECTORY_PICTURES);\n return File.createTempFile(\n imageFileName, /* prefix */\n \".jpg\", /* suffix */\n storageDir /* directory */\n );\n }",
"private File createImageFile() throws IOException{\n @SuppressLint(\"SimpleDateFormat\")\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"img_\"+timeStamp+\"_\";\n File storageDir = Environment.getExternalStoragePublicDirectory(Environment.DIRECTORY_PICTURES);\n return File.createTempFile(imageFileName,\".jpg\",storageDir);\n }",
"private File createImageFile() throws IOException {\n @SuppressLint({\"NewApi\", \"LocalSuppress\"}) String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\", Locale.getDefault()).format(new Date());\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\n File storageDir = Environment.getExternalStoragePublicDirectory(\n Environment.DIRECTORY_PICTURES);\n return File.createTempFile(\n imageFileName, /* prefix */\n \".jpg\", /* suffix */\n storageDir /* directory */\n );\n }",
"public String createImageName(File imageFile)\n\t{\n\t\tString name = imageFile.getAbsolutePath();\n\t\t\n\t\t// remove the initial part of the path that is common among all images so that only the relative path within the image folder remains\n\t\t// also remove the file's extension\n\t\tname = name.substring(imageFolder.getAbsolutePath().length() + 1, name.lastIndexOf('.'));\t\t\n\t\treturn name;\n\t}",
"private File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(getString(R.string.day_format)).format(new Date());\n String imageFileName = getString(R.string.image_file_prefix) + timeStamp + \"_\";\n File storageDir = getExternalFilesDir(Environment.DIRECTORY_PICTURES);\n File image = File.createTempFile(imageFileName, getString(R.string.image_file_format),\n storageDir\n );\n\n return image;\n }",
"private File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\", Locale.US).format(new Date());\n String imageFileName = \"perfil_\" + timeStamp + \"_\";\n String outputPath = PATH;\n File storageDir = new File(outputPath);\n if(!storageDir.exists())storageDir.mkdirs();\n File image = File.createTempFile(\n imageFileName, /* prefix */\n \".jpg\", /* suffix */\n storageDir /* directory */\n );\n\n // Save a file: path for use with ACTION_VIEW intents\n mCurrentPhotoPath = \"file:\" + image.getAbsolutePath();\n return image;\n }",
"private File createImageFile() throws IOException\n {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\n File storageDir = getExternalFilesDir(Environment.DIRECTORY_PICTURES);\n File image = File.createTempFile(\n imageFileName, /* prefix */\n \".jpg\", /* suffix */\n storageDir /* directory */\n );\n\n return image;\n }",
"private File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\n File storageDir = Environment.getExternalStoragePublicDirectory(\n Environment.DIRECTORY_PICTURES);\n File imageFile = File.createTempFile(\n imageFileName, /* prefix */\n \".jpg\", /* suffix */\n storageDir /* directory */\n );\n return imageFile;\n }",
"private String createFileName(){\n \t\n \tString state = Environment.getExternalStorageState();\n \tif(state.equals(Environment.MEDIA_MOUNTED)){ \t\t\n \t\tFile folder = new File(Environment.getExternalStorageDirectory() + \"/ArtCameraPro\");\n \t\tboolean success = true;\n \t\tif (!folder.exists()) {\n \t\t success = folder.mkdir();\n \t\t} \n \t\tString sFileName = Environment.getExternalStorageDirectory() + \"/ArtCameraPro\" + File.separator + System.currentTimeMillis() + \".jpg\";\n \t\treturn sFileName;\n \t\t\n \t}\n \treturn \"\";\n }",
"private File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\n File storageDir = Environment.getExternalStoragePublicDirectory(Environment.DIRECTORY_PICTURES);\n File image = File.createTempFile(\n imageFileName, /* prefix */\n \".jpg\", /* suffix */\n storageDir /* directory */\n );\n\n return image;\n }",
"private static File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\n File storageDir = MyApplication.getContext().getExternalFilesDir(Environment.DIRECTORY_PICTURES);\n File image = File.createTempFile(\n imageFileName, /* prefix */\n \".jpg\", /* suffix */\n storageDir /* directory */\n );\n return image;\n }",
"public static String createFotoFileName(String prefix) {\n return prefix + \"_\" + DateUtil.getCurrentDateTimeAsString(\"yyyyMMdd_hhmmss\") + \".jpg\";\n }",
"private File createImageFile() throws IOException {\n // Create an image file name\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\n File storageDir = Environment.getExternalStoragePublicDirectory(Environment.DIRECTORY_PICTURES);\n File imageFile = File.createTempFile(imageFileName, \".jpg\", storageDir);\n return imageFile;\n }",
"private File createImageFile() throws IOException {\n // Create an image file name\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\n File storageDir = getContext().getExternalFilesDir(Environment.DIRECTORY_PICTURES);\n File image = File.createTempFile(\n imageFileName, /* prefix */\n \".jpg\", /* suffix */\n storageDir /* directory */\n );\n\n return image;\n }",
"private File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"JPEG_\" + timeStamp;\n\n String folderName = context.getString(R.string.app_name).toLowerCase();\n\n File path = new File(ContextCompat.getExternalFilesDirs(getActivity(), null)[0]\n .getAbsolutePath() + \"/\" + folderName);\n\n //make sure folder exists\n path.mkdirs();\n\n File image = File.createTempFile(\n imageFileName, /* prefix */\n \".jpg\", /* suffix */\n path /* directory */\n );\n\n return image;\n }",
"private File createImageFile(String imgDir) throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = imgDir + File.separator + timeStamp + \"_\";\n File storageDir = Environment.getExternalStoragePublicDirectory(\n Environment.DIRECTORY_PICTURES);\n return File.createTempFile(\n imageFileName, /* prefix */\n \".jpg\", /* suffix */\n storageDir /* directory */\n );\n }",
"private File createImageFile() throws IOException {\n // Create an image file name\n String timeStamp = new SimpleDateFormat(\"yyyyMMddHHmmss\").format(new Date());\n String mFileName = \"JPEG_\" + timeStamp + \"_\";\n File storageDir = getExternalFilesDir(Environment.DIRECTORY_PICTURES);\n File mFile = File.createTempFile(mFileName, \".jpg\", storageDir);\n return mFile;\n }",
"@SuppressLint(\"SimpleDateFormat\")\n public static File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = JPEG_FILE_PREFIX + timeStamp + JPEG_FILE_SUFFIX;\n String nameAlbum = Environment.getExternalStorageDirectory().getAbsolutePath() + \"/\" + nameDir;// getString(R.string.app_name);\n File albumF = new File(nameAlbum);\n if (!albumF.exists()) {\n albumF.mkdirs();\n File noMedia = new File(albumF, \".nomedia\");\n noMedia.createNewFile();\n }\n\n File imageF = new File(albumF, imageFileName);\n imageF.createNewFile();\n return imageF;\n }",
"private String generateFilename() {\n UUID uuid = UUID.randomUUID();\n return uuid.toString();\n }",
"private File createImageFile() throws IOException\n {\n String timeStamp = new SimpleDateFormat(\"yyyymmddHHmmss\").format(new Date());\n String imageFileName = timeStamp;\n File image = File.createTempFile(\n imageFileName, /* prefix */\n \".jpg\", /* suffix */\n userCacheDir /* directory */\n );\n\n // Save a file: path for use with ACTION_VIEW intents\n return image;\n }",
"private File createImageFile() {\n\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\", Locale.getDefault()).format(new Date());\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\n\n File storageDir = Environment.getExternalStoragePublicDirectory(\n Environment.DIRECTORY_PICTURES + APP_PICTURE_DIRECTORY);\n storageDir.mkdirs();\n\n File imageFile = null;\n\n try {\n imageFile = File.createTempFile(\n imageFileName, /* prefix */\n FILE_SUFFIX_JPG, /* suffix */\n storageDir /* directory */\n );\n\n } catch (IOException e) {\n e.printStackTrace();\n }\n\n return imageFile;\n }",
"private File createImageFile() {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\n File storageDir = new File(Environment.getExternalStoragePublicDirectory(\n Environment.DIRECTORY_DCIM), \"GIS\");\n File image = null;\n\n if(!storageDir.exists()){\n\n storageDir.mkdirs();\n\n }\n try {\n image = File.createTempFile(\n imageFileName, /* prefix */\n \".jpg\", /* suffix */\n storageDir /* directory */\n );\n }catch (Exception e){\n\n e.printStackTrace();\n\n }\n // Save a file: path for use with ACTION_VIEW intents\n\n return image;\n }",
"private String beautiplyFileNameGenerator() {\r\n\t\t// /randomvalue between 0 to 9\r\n\t\tString name = \"beautiply\" + new Random().nextInt(9) + \".png\";\r\n\r\n\t\treturn name;\r\n\t}",
"private void createImage (String image_name, int filename){\n\n\t\tString image_folder = getLevelImagePatternFolder();\n\t\t\n\t\tString resource = filename+\".png\";\n\t\tImageIcon ii = new ImageIcon(this.getClass().getResource(image_folder + resource));\n images.put(image_name, ii.getImage());\n\t}",
"public File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\n File storageDir = Environment.getExternalStoragePublicDirectory(\n Environment.DIRECTORY_PICTURES);\n File imageFile = File.createTempFile(\n imageFileName, /* prefix */\n \".jpg\", /* suffix */\n storageDir /* directory */\n );\n return imageFile;\n }",
"private File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\n File storageDir = getExternalFilesDir(Environment.DIRECTORY_PICTURES);\n File image = File.createTempFile(\n imageFileName, /* prefix */\n \".jpg\", /* suffix */\n storageDir /* directory */\n );\n\n // Save a file: path for use with ACTION_VIEW intents\n String z = image.getAbsolutePath();\n return image;\n }",
"public String createImageName(String empName) {\n StringBuilder iN = new StringBuilder();\n\n String[] fnLn = empName.split(\" \");\n iN.append(fnLn[0]);\n iN.append(fnLn[fnLn.length-1].substring(0, 1));\n return iN.toString().trim();\n }",
"public File createImageFile() {\n // the public picture director\n File picturesDirectory = Environment.getExternalStoragePublicDirectory(Environment.DIRECTORY_PICTURES); // To get pictures directory from android system\n\n // timestamp makes unique name.\n @SuppressLint(\"SimpleDateFormat\") SimpleDateFormat sdf = new SimpleDateFormat(\"yyyyMMdd_HHmmss\");\n String timestamp = sdf.format(new Date());\n\n // put together the directory and the timestamp to make a unique image location.\n File imageFile = new File(picturesDirectory, timestamp + \".jpg\");\n\n return imageFile;\n }",
"public File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\n File storageDir = mContext.getExternalFilesDir(Environment.DIRECTORY_PICTURES);\n return File.createTempFile(\n imageFileName, /* prefix */\n \".jpg\", /* suffix */\n storageDir /* directory */\n );\n }",
"private File createImageFile() throws IOException {\n // Create an image file name\n String timeStamp = new SimpleDateFormat ( \"yyyyMMdd_HHmmss\" ).format ( new Date () );\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\n File storageDir = getExternalFilesDir ( Environment.DIRECTORY_PICTURES );\n File image = File.createTempFile (\n imageFileName , /* prefix */\n \".jpg\" , /* suffix */\n storageDir /* directory */\n );\n\n // luu file: su dung ACTION_VIEW\n pathToFile = image.getAbsolutePath ();\n return image;\n }",
"public File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\n File storageDir = getActivity().getFilesDir();\n File image = File.createTempFile(\n imageFileName, /* prefix */\n \".jpg\", /* suffix */\n storageDir /* directory */\n );\n\n return image;\n }",
"protected File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\n File storageDir = Environment.getExternalStoragePublicDirectory(\n Environment.DIRECTORY_PICTURES);\n File image = File.createTempFile(\n imageFileName, /* prefix */\n \".jpg\", /* suffix */\n storageDir /* directory */\n );\n\n strAbsolutePath = image.getAbsolutePath();\n Log.e(\"XpathX\", image.getAbsolutePath());\n return image;\n }",
"private File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMddHHmmss\").format(new Date());\n String mFileName = \"JPEG_\" + timeStamp + \"_\";\n File storageDir = getExternalFilesDir(Environment.DIRECTORY_PICTURES);\n File mFile = File.createTempFile(mFileName, \".jpg\", storageDir);\n pictureFilePath = mFile.getAbsolutePath();\n return mFile;\n }",
"private File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"1mind_\" + timeStamp + \".png\";\n File photo = new File(Environment.getExternalStorageDirectory(), imageFileName);\n mCurrentPhotoPath = photo.getAbsolutePath();\n return photo;\n }",
"private File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\r\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\r\n File storageDir = getExternalFilesDir(Environment.DIRECTORY_PICTURES);\r\n File image = File.createTempFile(\r\n imageFileName, // prefix //\r\n \".jpg\", // suffix //\r\n storageDir // directory //\r\n );\r\n\r\n // Save a file: path for use with ACTION_VIEW intents\r\n mPath = image.getAbsolutePath();\r\n return image;\r\n }",
"private File createImageFile() throws IOException {\n String imageFileName = new SimpleDateFormat(\"yyyyMMdd-HHmmss\", Locale.ENGLISH).format(new Date());\n String storageDir = Environment.getExternalStorageDirectory() + \"/DokuChat\";\n File dir = new File(storageDir);\n if (!dir.exists())\n dir.mkdir();\n\n image = new File(storageDir + \"/\" + imageFileName + \".jpg\");\n\n // Save a file: path for use with ACTION_VIEW intents\n mCurrentPhotoPath = image.getAbsolutePath();\n return image;\n }",
"private File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\n File storageDir = getExternalFilesDir(Environment.DIRECTORY_PICTURES);\n File image = File.createTempFile(\n imageFileName, /* prefix */\n \".jpg\", /* suffix */\n storageDir /* directory */\n );\n\n // Save a file: path for use with ACTION_VIEW intents\n pictureImagePath = image.getAbsolutePath();\n return image;\n\n }",
"private File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new java.util.Date());\n String imageFileName = \"WILDLIFE_JPEG_\" + timeStamp + \"_\";\n File storageDir = Environment.getExternalStoragePublicDirectory(\n Environment.DIRECTORY_PICTURES);\n File image = File.createTempFile(\n imageFileName, /* prefix */\n \".jpg\", /* suffix */\n storageDir /* directory */\n );\n\n // Save a file: path for use with ACTION_VIEW intents\n mCurrentPhotoPath = image.getAbsolutePath();\n return image;\n }",
"File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n //Todo:Este sera el nombre que tendra el archivo\n String imageFileName = \"IMAGE_\" + timeStamp + \"_\";\n //Todo:Ruta donde se almacenara la imagen\n File storageDirectory = Environment.getExternalStoragePublicDirectory(Environment.DIRECTORY_PICTURES);\n\n //Todo:El tipo de archivo que se almacenara en el directorio\n File image = File.createTempFile(imageFileName,\".jpg\",storageDirectory);\n //Todo: mImageFileLocation sera el valor que se\n mImageFileLocation = image.getAbsolutePath();\n\n return image;\n }",
"private File createImageFile() throws IOException\r\n {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\r\n String imageFileName = \"MYAPPTEMP_\" + timeStamp + \"_\";\r\n File storageDir = Environment.getExternalStoragePublicDirectory(Environment.DIRECTORY_PICTURES);\r\n File image = File.createTempFile(imageFileName, /* prefix */\r\n \".jpg\", /* suffix */\r\n storageDir /* directory */\r\n );\r\n\r\n return image;\r\n }",
"private File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\n File storageDir = getExternalFilesDir(Environment.DIRECTORY_PICTURES);\n File image = File.createTempFile(\n imageFileName, /* prefix */\n \".jpg\", /* suffix */\n storageDir /* directory */\n );\n\n // Save a file: path for use with ACTION_VIEW intents\n pictureImagePath = image.getAbsolutePath();\n return image;\n }",
"public abstract String getImageSuffix();",
"private File createImageFile() {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\n //File storageDir = getExternalFilesDir(Environment.DIRECTORY_PICTURES);\n File storageDir = new File(utils.getSentImagesDirectory());\n\n File image = null;\n try {\n image = File.createTempFile(\n imageFileName, /* prefix */\n \".jpg\", /* suffix */\n storageDir /* directory */\n );\n } catch (Exception ex) {\n ex.printStackTrace();\n }\n // Save a file: path for use with ACTION_VIEW intents\n //LOG.info(\"test place3\");\n try {\n imageFilePath = image.getAbsolutePath();\n } catch (Exception ex) {\n ex.printStackTrace();\n }\n //LOG.info(\"test place4\");\n if (image == null) {\n LOG.info(\"image file is null\");\n } else {\n LOG.info(\"image file is not null path is:\" + imageFilePath);\n }\n return image;\n }",
"private File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\n File storageDir = getActivity().getExternalFilesDir(Environment.DIRECTORY_PICTURES);\n File image = File.createTempFile(\n imageFileName, /* prefix */\n \".png\", /* suffix */\n storageDir /* directory */\n );\n\n // Save a file: path for use with ACTION_VIEW intents\n currentPhotoPath = image.getAbsolutePath();\n return image;\n }",
"private File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\n File storageDir = Environment.getExternalStoragePublicDirectory(\n Environment.DIRECTORY_PICTURES);\n File image = File.createTempFile(\n imageFileName, // prefix\n \".jpg\", // suffix\n storageDir // directory\n );\n\n // Save a file: path for use with ACTION_VIEW intents\n mCurrentPhotoPath = \"file:\" + image.getAbsolutePath();\n return image;\n }",
"private File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\n File storageDir = SettingsHelper.getPrivateImageFolder(this);\n if (!storageDir.exists()) {\n storageDir.mkdirs();\n }\n File image = File.createTempFile(\n imageFileName, /* prefix */\n \".jpg\", /* suffix */\n storageDir /* directory */\n );\n\n // Save a file: path for use with ACTION_VIEW intents\n imageUri = Uri.fromFile(image);\n return image;\n }",
"private Image createImage(String image_file) {\n\t\tImage img = new Image(image_file);\n\t\treturn img;\n\t}",
"public File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\", Locale.US).format(new Date());\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\n File storageDir = new File(getPhotoLocation());\n File image = File.createTempFile(\n imageFileName,\n \".jpg\",\n storageDir\n );\n\n setCurrentPhotoFile(image.getAbsolutePath());\n return image;\n }",
"private File createImageFile() throws IOException\n {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"Picko_JPEG\" + timeStamp + \"_\";\n File storageDir = new File(Environment.getExternalStoragePublicDirectory(\n Environment.DIRECTORY_DOCUMENTS),\"Whatsapp\");\n File image = File.createTempFile(\n imageFileName, /* prefix */\n \".jpg\", /* suffix */\n storageDir /* directory */\n );\n\n // Save a file: path for use with ACTION_VIEW intents\n String mCurrentPhotoPath = \"file:\" + image.getAbsolutePath();\n return image;\n\n\n }",
"public static File createImageFile(Context context, String name) throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\r\n String imageFileName = name + \"_\" + timeStamp + \"_\";\r\n File storageDir = context.getExternalFilesDir(Environment.DIRECTORY_PICTURES);\r\n File image = File.createTempFile(\r\n imageFileName, /* prefix */\r\n \".jpg\", /* suffix */\r\n storageDir /* directory */\r\n );\r\n return image;\r\n }",
"public abstract String createFilename(Entity entity);",
"private File createImageFile() throws IOException {\n // Create an image file name\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\n //The directory where to save the file image\n File storageDir = getExternalFilesDir(Environment.DIRECTORY_PICTURES);\n //The actual image file\n File image = File.createTempFile(\n imageFileName, /* prefix */\n \".jpg\", /* suffix */\n storageDir /* directory */\n );\n // Save a file: path for use with ACTION_VIEW intents\n mPhotoPath = image.getAbsolutePath();\n return image;\n }",
"private File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format( new Date());\n String imageFileName = \"JPEG_\" + timeStamp + \"_\" ;\n File storageDir = Environment.getExternalStoragePublicDirectory(Environment. DIRECTORY_PICTURES);\n File image = File. createTempFile(\n imageFileName, /* prefix */\n \".jpg\", /* suffix */\n storageDir /* directory */\n );\n\n // Save a file: path for use with ACTION_VIEW intents\n mCurrentPhotoPath = image.getAbsolutePath();\n return image;\n }",
"private static File createImageFile(Activity activity) throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\n File storageDir = activity.getExternalFilesDir(Environment.DIRECTORY_PICTURES);\n File image = File.createTempFile(\n imageFileName, /* prefix */\n \".jpg\", /* suffix */\n storageDir /* directory */\n );\n return image;\n }",
"private File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\n File storageDir = getExternalFilesDir(Environment.DIRECTORY_PICTURES);\n File image = File.createTempFile(\n imageFileName, /* prefix */\n \".jpg\", /* suffix */\n storageDir /* directory */\n );\n\n // Save a file: path for use with ACTION_VIEW intents\n currentPhotoPath = image.getAbsolutePath();\n return image;\n }",
"private File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\n File storageDir = getExternalFilesDir(Environment.DIRECTORY_PICTURES);\n File image = File.createTempFile(\n imageFileName, /* prefix */\n \".jpg\", /* suffix */\n storageDir /* directory */\n );\n\n // Save a file: path for use with ACTION_VIEW intents\n currentPhotoPath = image.getAbsolutePath();\n return image;\n }",
"private File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\n File storageDir = getExternalFilesDir(Environment.DIRECTORY_PICTURES);\n File image = File.createTempFile(\n imageFileName, /* prefix */\n \".jpg\", /* suffix */\n storageDir /* directory */\n );\n\n // Save a file: path for use with ACTION_VIEW intents\n currentPhotoPath = image.getAbsolutePath();\n return image;\n }",
"private File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\n File storageDir = getExternalFilesDir(Environment.DIRECTORY_PICTURES);\n File image = File.createTempFile(\n imageFileName, /* prefix */\n \".jpg\", /* suffix */\n storageDir /* directory */\n );\n\n // Save a file: path for use with ACTION_VIEW intents\n currentPhotoPath = image.getAbsolutePath();\n return image;\n }",
"private File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\n File storageDir = getExternalFilesDir(Environment.DIRECTORY_PICTURES);\n File image = File.createTempFile(\n imageFileName, /* prefix */\n \".jpg\", /* suffix */\n storageDir /* directory */\n );\n\n // Save a file: path for use with ACTION_VIEW intents\n currentPhotoPath = image.getAbsolutePath();\n return image;\n }",
"private File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\n File storageDir = getExternalFilesDir(Environment.DIRECTORY_PICTURES);\n File image = File.createTempFile(\n imageFileName, /* prefix */\n \".jpg\", /* suffix */\n storageDir /* directory */\n );\n\n // Save a file: path for use with ACTION_VIEW intents\n currentPhotoPath = image.getAbsolutePath();\n return image;\n }",
"private File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\n// File storageDir = getExternalFilesDir(Environment.DIRECTORY_PICTURES);\n File storageDir = Environment.getExternalStoragePublicDirectory(Environment.DIRECTORY_PICTURES);\n File image = File.createTempFile(\n imageFileName, /* prefix */\n \".jpg\", /* suffix */\n storageDir /* directory */\n );\n\n // Save a file: path for use with ACTION_VIEW intents\n currentPhotoPath = image.getAbsolutePath();\n return image;\n }",
"private File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\n// File storageDir = getExternalFilesDir(Environment.DIRECTORY_PICTURES);\n File storageDir = Environment.getExternalStoragePublicDirectory(Environment.DIRECTORY_PICTURES);\n File image = File.createTempFile(\n imageFileName, /* prefix */\n \".jpg\", /* suffix */\n storageDir /* directory */\n );\n\n // Save a file: path for use with ACTION_VIEW intents\n currentPhotoPath = image.getAbsolutePath();\n return image;\n }",
"private File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\n File storageDir = getExternalFilesDir(Environment.DIRECTORY_PICTURES);\n File image = File.createTempFile(\n imageFileName, /* prefix */\n \".jpg\", /* suffix */\n storageDir /* directory */\n );\n\n // Save a file: path for use with ACTION_VIEW intents\n currentPhotoPath = image.getAbsolutePath();\n savePhotoPathToSharedPrefs();\n return image;\n }",
"private File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\n File storageDir = getExternalFilesDir(Environment.DIRECTORY_PICTURES);\n File image = File.createTempFile(\n imageFileName, /* prefix */\n \".jpg\", /* suffix */\n storageDir /* directory */\n );\n\n // Save a file: path for use with ACTION_VIEW intents\n mCurrentPhotoPath = image.getAbsolutePath();\n //galleryAddPic();\n return image;\n }",
"private File createImageFile() throws IOException {\n Date d = new Date();\n String nameDate = new SimpleDateFormat(\"ddMMyyyy_HHmmss\").format(d);\n this.date = new SimpleDateFormat(\"dd/MM/yyyy\").format(d);\n String imageFileName = \"JPEG_\" + nameDate + \"_\";\n File storageDir = getExternalFilesDir(Environment.DIRECTORY_PICTURES);\n File image = File.createTempFile(\n imageFileName, /* prefix */\n \".jpg\", /* suffix */\n storageDir /* directory */\n );\n // Save a file: path for use with ACTION_VIEW intents\n mCurrentPhotoPath = image.getAbsolutePath();\n return image;\n }",
"private File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\n File storageDir = getExternalFilesDir(Environment.DIRECTORY_PICTURES);\n File image = File.createTempFile(\n imageFileName, /* prefix */\n \".jpg\", /* suffix */\n storageDir /* directory */\n );\n\n // Save a file: path for use with ACTION_VIEW intents\n mCurrentPhotoPath = \"file:\" + image.getAbsolutePath();\n return image;\n }",
"private File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\r\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\r\n File storageDir = getExternalFilesDir(Environment.DIRECTORY_PICTURES);\r\n File image = File.createTempFile(\r\n imageFileName, /* prefix */\r\n \".jpg\", /* suffix */\r\n storageDir /* directory */\r\n );\r\n\r\n // Save a file: path for use with ACTION_VIEW intents\r\n mCurrentPhotoPath = image.getAbsolutePath();\r\n return image;\r\n\r\n }",
"private File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\n File storageDir = getExternalFilesDir(Environment.DIRECTORY_PICTURES);\n File image = File.createTempFile(\n imageFileName, /* prefix */\n \".jpg\", /* suffix */\n storageDir /* directory */\n );\n\n // Save a file: path for use with ACTION_VIEW intents\n mCurrentPhotoPath = image.getAbsolutePath();\n photosPaths.add(mCurrentPhotoPath);\n return image;\n }",
"private File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\n File storageDir = getExternalFilesDir(Environment.DIRECTORY_PICTURES);\n File image = File.createTempFile(\n imageFileName, /* prefix */\n \".jpg\", /* suffix */\n storageDir /* directory */\n );\n\n // Save a file: path for use with ACTION_VIEW intents\n mCurrentPhotoPath = image.getAbsolutePath();\n return image;\n }",
"private File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"JPEG_\" + timeStamp;\n File storageDir = getExternalFilesDir(Environment.DIRECTORY_PICTURES);\n File image = File.createTempFile(\n imageFileName, /* prefix */\n \".jpg\", /* suffix */\n storageDir /* directory */\n );\n\n // Save a file: path for use with ACTION_VIEW intents\n currentPhotoPath = image.getAbsolutePath();\n return image;\n }",
"public abstract FileName createName(String absolutePath, FileType fileType);",
"public String getPhotoFileName() {\n return \"IMG_\" + getId().toString() + \".jpg\";\n }",
"private File createImageFile() throws IOException {\n // Create an image file name\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\n File storageDir = getExternalFilesDir(Environment.DIRECTORY_PICTURES);\n File image = File.createTempFile(\n imageFileName, /* prefix */\n \".jpg\", /* suffix */\n storageDir /* directory */\n );\n\n // Save a file: path for use with ACTION_VIEW intents\n currentPhotoPath = image.getAbsolutePath();\n return image;\n }",
"private File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\n File storageDir = activity.getExternalFilesDir(Environment.DIRECTORY_PICTURES);\n File image = File.createTempFile(\n imageFileName, /* prefix */\n \".jpg\", /* suffix */\n storageDir /* directory */\n );\n\n // Save a file: path for use with ACTION_VIEW intents\n mCurrentPhotoPath = image.getAbsolutePath();\n return image;\n }",
"private File createImageFile() throws IOException {\n // Create an image file name\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\n File storageDir = getExternalFilesDir(Environment.DIRECTORY_PICTURES);\n File image = File.createTempFile(imageFileName, \".jpg\", storageDir);\n\n // Save a file: path for use with ACTION_VIEW intents\n this.currentPhotoPath = image.getAbsolutePath();\n return image;\n }",
"private File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\n File storageDir = getExternalStoragePublicDirectory(Environment.DIRECTORY_PICTURES);\n File image = File.createTempFile(\n imageFileName, /* prefix */\n \".jpg\", /* suffix */\n storageDir /* directory */\n );\n\n // Save a file: path for use with ACTION_VIEW intents\n currentPhotoPath = image.getAbsolutePath();\n return image;\n }",
"private File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\", Locale.ENGLISH).format(new Date());\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\n File storageDir = new File(Environment.getExternalStoragePublicDirectory(\n Environment.DIRECTORY_DCIM), \"Camera\");\n File image = File.createTempFile(\n imageFileName, /* prefix */\n \".jpg\", /* suffix */\n storageDir /* directory */\n );\n\n // Save a file: path for use with ACTION_VIEW intents\n mCurrentPhotoPath = \"file:\" + image.getAbsolutePath();\n return image;\n }",
"private File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\n File storageDir = getExternalFilesDir(Environment.DIRECTORY_PICTURES);\n File image = File.createTempFile(\n imageFileName,\n \".jpg\",\n storageDir\n );\n mCurrentPhotoPath = image.getAbsolutePath();\n return image;\n }",
"public static File createImageFile(Context ctx) throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\n File storageDir = ctx.getExternalFilesDir(Environment.DIRECTORY_PICTURES);\n File image = File.createTempFile(imageFileName, \".jpg\", storageDir);\n return image;\n }",
"private File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\n File storageDir = getExternalFilesDir(Environment.DIRECTORY_PICTURES);\n File image = File.createTempFile(\n imageFileName, /* prefix */\n \".jpg\", /* suffix */\n storageDir /* directory */\n );\n // Save a file: path for use with ACTION_VIEW intents\n mCurrentPhotoPath = imageFileName + \"camera.jpg\";\n return image;\n }",
"private File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\n File storageDir = Environment.getExternalStoragePublicDirectory(\n Environment.DIRECTORY_PICTURES);\n File image = File.createTempFile(\n imageFileName, /* prefix */\n \".jpg\", /* suffix */\n storageDir /* directory */\n );\n\n mCurrentPhotoPath = image.getAbsolutePath();\n return image;\n }",
"private File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\n //This is the directory in which the file will be created. This is the default location of Camera photos\n File storageDir = new File(Environment.getExternalStoragePublicDirectory(\n Environment.DIRECTORY_DCIM), \"Camera\");\n image = File.createTempFile(\n imageFileName, /* prefix */\n \".jpg\", /* suffix */\n storageDir /* directory */\n );\n // Save a file: path for using again\n cameraFilePath = \"file://\" + image.getAbsolutePath();\n return image;\n }",
"private File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\n //This is the directory in which the file will be created. This is the default location of Camera photos\n File storageDir = new File(Environment.getExternalStorageDirectory(), getString(R.string.app_name));\n if (!storageDir.exists()){\n storageDir.mkdir();\n }\n File image = File.createTempFile(\n imageFileName, /* prefix */\n \".jpg\", /* suffix */\n storageDir /* directory */\n );\n // Save a file: path for using again\n cameraFilePath = \"file://\" + image.getAbsolutePath();\n return image;\n }",
"private File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\n// File storageDir = getExternalFilesDir(Environment.DIRECTORY_PICTURES);\n File image = File.createTempFile(\n imageFileName, /* prefix */\n \".jpg\", /* suffix */\n storageDir /* directory */\n );\n\n // Save a file: path for use with ACTION_VIEW intents\n mCurrentPhotoPath = image.getAbsolutePath();\n return image;\n }",
"private File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\n File storageDir = getExternalFilesDir(Environment.DIRECTORY_PICTURES);\n File image = File.createTempFile(\n imageFileName, /* prefix */\n \".jpg\", /* suffix */\n storageDir /* directory */\n );\n\n // Save a file: path for use with ACTION_VIEW intents\n mCurrentPhotoPath = image.getAbsolutePath();\n return image;\n }",
"private File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\n File storageDir = getExternalFilesDir(Environment.DIRECTORY_PICTURES);\n File image = File.createTempFile(\n imageFileName, /* prefix */\n \".jpg\", /* suffix */\n storageDir /* directory */\n );\n\n // Save a file: path for use with ACTION_VIEW intents\n mCurrentPhotoPath = image.getAbsolutePath();\n return image;\n }",
"private File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\n File storageDir = getExternalFilesDir(Environment.DIRECTORY_PICTURES);\n File image = File.createTempFile(\n imageFileName, /* prefix */\n \".jpg\", /* suffix */\n storageDir /* directory */\n );\n\n // Save a file: path for use with ACTION_VIEW intents\n mCurrentPhotoPath = image.getAbsolutePath();\n return image;\n }",
"private File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\n File storageDir = getExternalFilesDir(Environment.DIRECTORY_PICTURES);\n File image = File.createTempFile(\n imageFileName, /* prefix */\n \".jpg\", /* suffix */\n storageDir /* directory */\n );\n\n // Save a file: path for use with ACTION_VIEW intents\n mCurrentPhotoPath = image.getAbsolutePath();\n return image;\n }",
"private File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\n File storageDir = getExternalFilesDir(Environment.DIRECTORY_PICTURES);\n File image = File.createTempFile(\n imageFileName, /* prefix */\n \".jpg\", /* suffix */\n storageDir /* directory */\n );\n\n // Save a file: path for use with ACTION_VIEW intents\n mCurrentPhotoPath = image.getAbsolutePath();\n return image;\n }",
"private File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\n File storageDir = getExternalFilesDir(Environment.DIRECTORY_PICTURES);\n File image = File.createTempFile(\n imageFileName, /* prefix */\n \".jpg\", /* suffix */\n storageDir /* directory */\n );\n\n // Save a file: path for use with ACTION_VIEW intents\n mCurrentPhotoPath = image.getAbsolutePath();\n return image;\n }",
"private File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\n File storageDir = getExternalFilesDir(Environment.DIRECTORY_PICTURES);\n File image = File.createTempFile(\n imageFileName, /* prefix */\n \".jpg\", /* suffix */\n storageDir /* directory */\n );\n\n // Save a file: path for use with ACTION_VIEW intents\n mCurrentPhotoPath = image.getAbsolutePath();\n return image;\n }",
"private File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\n File storageDir = getExternalFilesDir(Environment.DIRECTORY_PICTURES);\n File image = File.createTempFile(\n imageFileName, /* prefix */\n \".jpg\", /* suffix */\n storageDir /* directory */\n );\n\n // Save a file: path for use with ACTION_VIEW intents\n mCurrentPhotoPath = image.getAbsolutePath();\n return image;\n }",
"private File createImageFile() throws IOException {\n String timeStamp = new SimpleDateFormat(\"yyyyMMdd_HHmmss\").format(new Date());\n String imageFileName = \"JPEG_\" + timeStamp + \"_\";\n File storageDir = getExternalFilesDir(Environment.DIRECTORY_PICTURES);\n File image = File.createTempFile(\n imageFileName, /* prefix */\n \".jpg\", /* suffix */\n storageDir /* directory */\n );\n\n // Save a file: path for use with ACTION_VIEW intents\n mCurrentPhotoPath = image.getAbsolutePath();\n return image;\n }"
] | [
"0.7782615",
"0.7292824",
"0.6992056",
"0.6992056",
"0.6943564",
"0.6911284",
"0.68938434",
"0.686538",
"0.68592805",
"0.68590325",
"0.68580544",
"0.68443614",
"0.67711073",
"0.67546785",
"0.6751638",
"0.6737171",
"0.6726197",
"0.67170936",
"0.67068315",
"0.6706409",
"0.6694521",
"0.6692518",
"0.66892946",
"0.6665624",
"0.6658789",
"0.66203934",
"0.66164696",
"0.6615736",
"0.6610864",
"0.66096437",
"0.6604602",
"0.66028416",
"0.6600987",
"0.65886337",
"0.6579357",
"0.6576186",
"0.65653497",
"0.65549564",
"0.65421396",
"0.65305394",
"0.6530493",
"0.6523718",
"0.6517966",
"0.65117127",
"0.6505747",
"0.6493113",
"0.64924705",
"0.6475854",
"0.6471266",
"0.6448684",
"0.6419626",
"0.64166796",
"0.6413514",
"0.640042",
"0.63892233",
"0.6379753",
"0.6375813",
"0.6375534",
"0.6367382",
"0.63566",
"0.6355329",
"0.6345687",
"0.6332988",
"0.6329631",
"0.6329631",
"0.6329631",
"0.6329631",
"0.6329631",
"0.63276523",
"0.63276523",
"0.6326054",
"0.6324831",
"0.6323436",
"0.63181776",
"0.6311542",
"0.63093704",
"0.63077575",
"0.630525",
"0.6300038",
"0.6297278",
"0.6296964",
"0.6294874",
"0.6292948",
"0.6289597",
"0.62894386",
"0.6282458",
"0.6281662",
"0.62706375",
"0.6261314",
"0.6258569",
"0.62572557",
"0.6256673",
"0.62541807",
"0.6251297",
"0.6251297",
"0.6251297",
"0.6251297",
"0.6251297",
"0.6251297",
"0.6251297",
"0.6251297"
] | 0.0 | -1 |
Initializes adaptor. Initialization parameters: categoriesFilePath categories definition file path [mandatory] gemetFilePath GEMET definition file path [mandatory] lang language [optional; default: en] | @Override
public void init(Properties properties) {
super.init(properties);
String categoriesFilePath = properties.getProperty("categoriesFilePath", "");
String gemetFilePath = properties.getProperty("gemetFilePath", "");
String lang = properties.getProperty("lang", "");
for (Locale l: Locale.getAvailableLocales()) {
if (l.getLanguage().equalsIgnoreCase(lang)) {
locale = l;
break;
}
}
ContextInitializer initializer = new ContextInitializer(ontCtx,
categoriesFilePath, gemetFilePath);
initializer.initialize();
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public Category() {\n\t\tsuper();\n\t\t/* Pour obtenir le chemin de fichier vers la catégorie */\n\t\tpath = \"src/\"+this.getClass().getPackage().getName().replace('.', '/');\n\t\twindowspath = \"src\\\\\"+this.getClass().getPackage().getName().replace('.', '\\\\');\n\t\t\n\t\timages = this.getPhotos();\n\t}",
"private LanguageModel(String corpusFilePath) throws Exception {\n constructDictionaries(corpusFilePath);\n }",
"@PostConstruct\n\tprotected void init() {\n\t\tLOGGER.info(\"GalleryModel init Start\");\n\t\tcharacterList.clear();\n\t\ttry {\n\t\t\tif (resource != null && !resource.getPath().contains(\"conf\")) {\n\t\t\t\t\tresolver = resource.getResourceResolver();\n\t\t\t\t\thomePagePath=TrainingHelper.getHomePagePath(resource);\n\t\t\t\t\tif(homePagePath!=null){\n\t\t\t\t\tlandinggridPath = homePagePath;\n\t\t\t\t\tif (!linkNavigationCheck) {\n\t\t\t\t\t\tlinkNavOption = \"\";\n\t\t\t\t\t}\n\t\t\t\t\tcheckLandingGridPath();\n\t\t\t\t\tif (!\"products\".equals(galleryFor)) {\n\t\t\t\t\t\tcharacterList = tileGalleryAndLandingService.getAllTiles(landinggridPath, galleryFor, \"landing\",\n\t\t\t\t\t\t\t\ttrue);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t} catch (Exception e) {\n\t\t\tLOGGER.error(\"Exception Occured\", e);\n\t\t}\n\t\tLOGGER.info(\"GalleryModel init End\");\n\t}",
"public static void init() throws IOException {\n\t\tGenericFeatVect.init();\n\t}",
"public void initFromClasspath() throws IOException {\n \t\tcontactNames = loadFromClassPath(\"contactNames\");\n \t\tgroupNames = loadFromClassPath(\"groupNames\");\n \t\tmessageWords = loadFromClassPath(\"messageWords\");\n \t}",
"private void initialiseCategories() {\n\t\t_nzCategories = BashCmdUtil.bashCmdHasOutput(\"ls categories/nz\");\n\t\t_intCategories = BashCmdUtil.bashCmdHasOutput(\"ls categories/international\");\n\t}",
"private static void InitTagger() {\n\t\ttagger = new MaxentTagger(\"models/english-left3words-distsim.tagger\");\n\t}",
"public void init() {\n try{\n\t//products = new HashMap<String,ArrayList<String>>();\n\n\t//String productXmlFileName = \"C:/apache-tomcat-7.0.34/webapps/BestDeal/WEB-INF/classes/ProductCatalog.xml\";\n\t//SaxParser4BestDealProducts sx = new SaxParser4BestDealProducts(productXmlFileName);\n\n\t }\n\tcatch(Exception e){ e.printStackTrace();}\n\n }",
"@Override\n public void initialize(URL url, ResourceBundle rb) {\n // TODO\n this.d = new getAlumnosData(false);\n }",
"public PTDictionaryImpl(String lang) {\n language = lang;\n handle = ptInitLibrary0(lang);\n }",
"private void init(String filename){\n // create product cateogries \n // hard coded key-value for this project \n productCategory.addProduct(\"book\", \"books\");\n productCategory.addProduct(\"books\", \"books\");\n productCategory.addProduct(\"chocolate\", \"food\");\n productCategory.addProduct(\"chocolates\", \"food\");\n productCategory.addProduct(\"pills\", \"medical\");\n \n // read input\n parser.readInput(filename);\n \n // addProducts\n try {\n this.addProducts(parser.getRawData());\n } catch (Exception e) {\n System.out.println(\"Check input integrity\");\n }\n \n this.generateReceipt();\n\n }",
"public void init(String file) {\n\t\tif (file == null) {\n\t\t\tfile = Controller.getSourceFile();\n\t\t}\n\t\tthis.satelliteList = JSONLoader.getSatelliteList(file);\n\t\tthis.initModules();\n\t}",
"public MetaInfoReader(String dataset, String basePath) {\n String baseFileName = basePath + dataset + \"/metainfo.txt\";\n data = new ArrayList<>();\n readFile(baseFileName);\n MetaDataManager.getInstance(data);\n }",
"public static void initializeToolsAndResources(String wordnetPath) throws MalformedURLException, IOException {\n\n Logger.getLogger(ExternalKnowledgeDemoMain.class.getName()).log(Level.INFO, \"...Generating stop-words lists...\");\n StringUtils.generateStopListsFromExternalSource(filePath_en, filePath_gr);\n\n Properties split_props = new Properties();\n //Properties without lemmatization\n split_props.put(\"annotators\", \"tokenize, ssplit, pos\");\n split_props.put(\"tokenize.language\", \"en\");\n split_pipeline = new StanfordCoreNLP(split_props);\n\n Properties lemma_props = new Properties();\n lemma_props.put(\"annotators\", \"tokenize, ssplit, pos, lemma\");\n lemma_props.put(\"tokenize.language\", \"en\");\n lemma_pipeline = new StanfordCoreNLP(lemma_props);\n\n Properties entityMentions_props = new Properties();\n entityMentions_props.put(\"annotators\", \"tokenize, ssplit, truecase, pos, lemma, ner, entitymentions\");\n entityMentions_props.put(\"tokenize.language\", \"en\");\n entityMentions_props.put(\"truecase.overwriteText\", \"true\");\n entityMentions_pipeline = new StanfordCoreNLP(entityMentions_props);\n\n Properties compound_props = new Properties();\n compound_props.put(\"annotators\", \"tokenize, ssplit, truecase, pos, parse\");\n compound_props.put(\"tokenize.language\", \"en\");\n compound_props.put(\"truecase.overwriteText\", \"true\");\n compounds_pipeline = new StanfordCoreNLP(compound_props);\n\n spotlight = new Spotlight();\n\n chanel = new LODSyndesisChanel();\n\n }",
"public GI() {\n \n initComponents();\n ReadData rd = new ReadData();//Tao doi tuong\n rd.readFile();//Doc du lieu tu file notepad\n try{\n jComboBox3.setModel(new javax.swing.DefaultComboBoxModel(rd.layTenTatCaTP()));//Lay du lieu tu notepad xuat ra jComboBox\n jComboBox4.setModel(new javax.swing.DefaultComboBoxModel(rd.layTenTatCaTP()));//Lay du lieu tu notepad xuat ra jComboBox\n }\n catch(Exception e){\n System.out.println(\"Error Read File!!!\"); \n }\n\n this.setLocation(100, 30);\n \n }",
"private void init() {\r\n this.configMapping = ChannelConfigHolder.getInstance().getConfigs();\r\n if (!isValid(this.configMapping)) {\r\n SystemExitHelper.exit(\"Cannot load the configuations from the configuration file please check the channelConfig.xml\");\r\n }\r\n }",
"private static Map<String, List<String>> loadCitiesByLanguage() {\n String resource = Config.get(\"generate.geography.foreign.birthplace.default_file\",\n \"geography/foreign_birthplace.json\");\n return loadCitiesByLanguage(resource);\n }",
"private static void init()\n {\n try\n {\n ObjectInputStream ois = \n new ObjectInputStream(new FileInputStream(lexFile));\n lexDB = (HashMap)ois.readObject();\n ois.close();\n } catch (FileNotFoundException e) {\n System.err.println(\"File not found: \" + e.toString());\n e.printStackTrace();\n System.exit(-1);\n } catch (IOException e) {\n System.err.println(\"IO Exception: \" + e.toString());\n e.printStackTrace();\n System.exit(-1);\n } catch (ClassNotFoundException e) {\n System.err.println(\"Class Not Found Exception: \" + e.toString());\n e.printStackTrace();\n System.exit(-1);\n } // catch\n }",
"public void init( String dictionaryFilePath) throws IOException {\n if(dictionaryFilePath == null || dictionaryFilePath.isEmpty()) {\n dictionaryFilePath = DEFAULT_DICTIONARY;\n log.warn(\"Using Default Dictionary\");\n }\n\n DICTIONARY = Files.readAllLines(Paths.get(dictionaryFilePath))\n .parallelStream()\n .map(line -> line.replaceAll(\"[^a-zA-Z ]\", \"\"))\n .map(Word::new)\n .collect(Collectors.toCollection(ConcurrentLinkedQueue::new));\n }",
"@Override\n public void initialize(URL location, ResourceBundle resources) {\n showIngredients();\n }",
"@PostConstruct\n public void init() {\n try {\n String contentFile = PlatformUtils.fileToString(TALKS_FILE_PATH, getClass().getClassLoader());\n loadTalks(PlatformUtils.parseToJson(contentFile));\n } catch (IOException e) {\n logger.log(Level.WARNING, \"An error occurred while loading data\", e);\n }\n }",
"@Override\n public void initialize(URL location, ResourceBundle resources) {\n comboBoxCh.getItems().addAll(\"id_Livre\", \"id_Auteur\", \"titre\");\n remplirTableView();\n }",
"@Override\n public void initialize(URL url, ResourceBundle rb) {\n entitymanager = DBConnection.getEntityManger();\n this.loadCombos();\n this.loadTime();\n this.setLocations();\n }",
"public GeotiffDataSource() {}",
"public void init()\r\n {\n readFile(inputFile);\r\n writeInfoFile();\r\n }",
"@Override\r\n\tpublic void init() {\r\n\r\n\t\ttry {\r\n\r\n\t\t\t// Retrieve current project\r\n\t\t\tif (context.containsKey(\"project\")) {\r\n\t\t\t\tproject = (Project) context.getProperty(\"project\");\r\n\t\t\t}\r\n\t\t\telse {\r\n\t\t\t\tthrow new EngineException(\"missing project specified !\");\r\n\t\t\t}\r\n\r\n\t\t\t// Retrieve path to rejected methods file\r\n\t\t\tPath rejectedMethodPath = Paths.get(\"conf\", \"rejected-methods.txt\").toAbsolutePath();\r\n\t\t\tif (context.containsKey(\"rejected-methods\")) {\r\n\t\t\t\tString rejectedFileParam = (String) context.getProperty(\"rejected-methods\");\r\n\t\t\t\tif (rejectedFileParam != null && rejectedFileParam.trim().length() > 0) {\r\n\t\t\t\t\trejectedMethodPath = Paths.get(rejectedFileParam);\r\n\t\t\t\t}\r\n\t\t\t}\r\n\r\n\t\t\t// Retrieve path to rejected types file\r\n\t\t\tPath rejectedTypePath = Paths.get(\"conf\", \"rejected-types.txt\").toAbsolutePath();\r\n\t\t\tif (context.containsKey(\"rejected-types\")) {\r\n\t\t\t\tString rejectedFileParam = (String) context.getProperty(\"rejected-types\");\r\n\t\t\t\tif (rejectedFileParam != null && rejectedFileParam.trim().length() > 0) {\r\n\t\t\t\t\trejectedTypePath = Paths.get(rejectedFileParam);\r\n\t\t\t\t}\r\n\t\t\t}\r\n\r\n\t\t\t// Check if rejected methods file exists\r\n\t\t\tif (!rejectedMethodPath.toFile().exists()) {\r\n\t\t\t\tthrow new EngineException(\"file '\" + rejectedMethodPath.getFileName().toString() + \"' doesn't not exist !\");\r\n\t\t\t}\r\n\t\t\telse {\r\n\t\t\t\t// Load rejected method list\r\n\t\t\t\trejectedMethodList = Files.readAllLines(rejectedMethodPath, Charset.defaultCharset());\r\n\t\t\t}\r\n\r\n\t\t\t// Check if rejected types file exists\r\n\t\t\tif (!rejectedTypePath.toFile().exists()) {\r\n\t\t\t\tthrow new EngineException(\"file '\" + rejectedTypePath.getFileName().toString() + \"' doesn't not exist !\");\r\n\t\t\t}\r\n\t\t\telse {\r\n\t\t\t\t// Load rejected types list\r\n\t\t\t\trejectedTypeList = Files.readAllLines(rejectedTypePath, Charset.defaultCharset());\r\n\t\t\t}\r\n\t\t}\r\n\t\tcatch (Exception e) {\r\n\t\t\tConsole.writeError(this, \"error while instrumenting files: \" + StringUtils.toString(e));\r\n\t\t}\r\n\t}",
"@Override\n public void initialize() {\n if(prefix == null)\n prefix = getToolkit().getArguments().referenceFile.getAbsolutePath();\n BWTFiles bwtFiles = new BWTFiles(prefix);\n BWAConfiguration configuration = new BWAConfiguration();\n aligner = new BWACAligner(bwtFiles,configuration);\n }",
"public void initialize(Collection<CartridgeClasspathData> aCartridges) {\n\t\tthis.selectedTemplates.clear();\n\t\tTemplatesStore.getInstance().clear();\n\n\t\tif (this.cartridgeClassPaths == null) {\n\t\t\tthis.setupCartridgeClassPaths();\n\t\t}\n\n\t\tif (this.cartridgeClassPaths != null) {\n\t\t\tthis.initializeCartridgeClasspaths(aCartridges);\n\t\t} else {\n\t\t\tlogger.error(\"cartridgeClassPaths is null??\");\n\t\t\tthrow new RuntimeException(\"cartridge classpaths are null\");\n\t\t}\n\n\t\tthis.storeCartridgeDir();\n\t\tProjectInstanceHelper.getInstance().refresh();\n\t}",
"private void initialize(){\r\n \t\taddPositionCategory(EclipseEditorTag.CHAMELEON_CATEGORY);\r\n \t\taddPositionUpdater(new DefaultPositionUpdater(EclipseEditorTag.CHAMELEON_CATEGORY));\r\n \t}",
"private static void init() throws IOException, BusinessException {\n\t\tMap<String, String> books = new HashMap<String, String>();\n\t\tbooks.put(\"tranc1-in\", Entry.class.getClassLoader().getResource(\"TRANC1-IN.book\").getPath());\n\t\tbooks.put(\"tranc1-out\", Entry.class.getClassLoader().getResource(\"TRANC1-OUT.book\").getPath());\n\t\tBookStore.loadBooks(books);\n\t}",
"public CatalogSettings() {\n init();\n }",
"public static void init(String filePath) {\n\t\t// Reading the created network for using its structure.\n\t\tnet = FileUtils.getNetwork(filePath);\n\t}",
"public Language(String lang) {\n this.lang = lang;\n /*\n lexerFactory = new LexerFactory();\n generatorFactory = new GeneratorFactory();\n parserFactory = new ParserFactory();\n */\n }",
"@Override\n public Resource init() throws ResourceInstantiationException {\n\n // based on info from\n // http://www.iana.org/assignments/media-types/application/fastinfoset\n\n // Register XML mime type\n MimeType mime = new MimeType(\"application\", \"fastinfoset\");\n\n // Register the class handler for this mime type\n mimeString2ClassHandlerMap.put(mime.getType() + \"/\" + mime.getSubtype(),\n this);\n\n // Register the mime type with mine string\n mimeString2mimeTypeMap.put(mime.getType() + \"/\" + mime.getSubtype(), mime);\n\n // Register file sufixes for this mime type\n suffixes2mimeTypeMap.put(\"finf\", mime);\n\n // Register magic numbers for this mime type\n // this should be E0 00 00 01\n // but I can't seem to get it to work\n\n // Set the mimeType for this language resource\n setMimeType(mime);\n\n return this;\n }",
"public void init() {\n\t\t// Read the data text file and load up the local database\n\t\tinitData();\n\n\t\t// Create the labels and the textbox\n\t\taddNameLabel();\n\t\taddNameBox();\n\t\taddGraphButton();\n\t\taddClearButton();\n\n\t\t// Set up the graph object\n\t\tgraph = new NameSurferGraph();\n\t\tadd(graph);\n\n\t}",
"@Override\n public void initialize(URL location, ResourceBundle resources) {\n // set treeView. Show all subdirectories and photos under every subdirectories.\n try {\n setTree();\n } catch (IOException e) {\n e.printStackTrace();\n }\n // set Gallery Display. Only show the photo directly under the selected directory.\n setGalleryDisplay();\n }",
"public void initialize(Context context, String[] packedGCO, String languageName) throws MCADException {\n try {\n this.globalConfigObject = (MCADGlobalConfigObject) JPO.unpackArgs(packedGCO);\n this.resourceBundle = new MCADServerResourceBundle(languageName);\n this.cache = new IEFGlobalCache();\n this.util = new MCADMxUtil(context, resourceBundle, cache);\n } catch (Exception e) {\n System.out.println(\"[initialize]: Exception while initializating JPO\" + e.getMessage());\n MCADServerException.createException(e.getMessage(), e);\n }\n }",
"public LibraryAnalysis(String option) throws IOException{\n \n if(option.equals(\"1\")){\n loadEnAfinnLibrary();\n } \n else if(option.equals(\"2\"))\n {\n loadFrAfinnLibrary(); \n }\n else if(option.equals(\"3\")){\n mohanLibrary = myLibrary.getLibrary();\n }\n else if(option.equals(\"4\")){\n loadEnAfinnLibrary();\n mohanLibrary = myLibrary.getLibrary();\n loadStopWords();\n }\n }",
"private static void loadDictionaryConfig()\r\n\t{\r\n\t\tURL dictionaryConfigURL = null;\r\n\t\ttry \r\n\t\t{\r\n\t\t\tBundle cfmlBundle = Platform.getBundle(CFMLPlugin.PLUGIN_ID);\r\n\t\t\tdictionaryConfigURL = org.eclipse.core.runtime.FileLocator.find(CFMLPlugin.getDefault().getBundle(),\r\n new Path(\"dictionary\"), null);\r\n\t\t\t\r\n\t\t\tDocumentBuilderFactory factory = DocumentBuilderFactory.newInstance();\r\n\t\t\tfactory.setIgnoringComments(true);\r\n\t\t\tfactory.setIgnoringElementContentWhitespace(true);\r\n\t\t\tfactory.setCoalescing(true);\r\n\t\t\tDocumentBuilder builder = factory.newDocumentBuilder();\r\n\t\t\t\r\n\t\t\tURL configurl = FileLocator.LocateURL(dictionaryConfigURL, \"dictionaryconfig.xml\");\r\n\t\t\t\t\t\t\r\n\t\t\tdictionaryConfig = builder.parse(configurl.getFile());\r\n\t\t\tif(dictionaryConfig == null) {\r\n\t\t\t\ttry {\r\n\t\t\t\t\tdictionaryConfig = builder.parse(\"jar:\"\r\n\t\t\t\t\t\t\t+ DictionaryManager.class.getClassLoader()\r\n\t\t\t\t\t\t\t\t\t.getResource(\"org.cfeclipse.cfml/dictionary/dictionaryconfig.xml\").getFile()\r\n\t\t\t\t\t\t\t\t\t.replace(\"dictionaryconfig.xml\", \"\"));\r\n\t\t\t\t} catch (Exception e) {\r\n\t\t\t\t\tdictionaryConfig = builder.parse(\"jar:file:\" + DictionaryManager.class.getResource(\"/dictionaries.zip\").getFile()\r\n\t\t\t\t\t\t\t+ \"!/org.cfeclipse.cfml/dictionary/\");\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t} \r\n\t\tcatch (Exception e) \r\n\t\t{\r\n\t\t\te.printStackTrace(System.err);\r\n\t\t}\r\n\t}",
"private void init() {\n\t\tinitDesign();\n\t\tinitHandlers();\n\t}",
"public NetworkLoader(String gisName, String filename, Display display) {\r\n initialize(\"Network\", null, filename, display);\r\n basename = gisName;\r\n initializeKnownHeaders();\r\n luceneInd = NeoServiceProviderUi.getProvider().getIndexService();\r\n addNetworkIndexes();\r\n }",
"@Override\n public void initialize(UimaContext aUimaContext) {\n try {\n chunker = (NBestChunker) AbstractExternalizable.readResourceObject((String) aUimaContext\n .getConfigParameterValue(\"LingpipeModel\"));\n /*\n * chunker = (ConfidenceChunker) AbstractExternalizable.readResourceObject(\n * LingPipeAnnotator.class, (String)\n * aUimaContext.getConfigParameterValue(\"LingPipeNERModel\"));\n */\n } catch (IOException e) {\n // TODO Auto-generated catch block\n e.printStackTrace();\n } catch (ClassNotFoundException e) {\n // TODO Auto-generated catch block\n e.printStackTrace();\n }\n }",
"@Override\n public void init() throws IOException {\n super.init();\n metaUtils_ = new MetaUtils(conf_);\n }",
"private CategoriesReaderFactory() {\n }",
"public MdnFeatures()\n {\n }",
"public static void init(String configFile){\n\t\tSystem.err.println(\"Reading config file...\");\n\t\tConfigurationHandler.init(configFile);\n\t\t\n\t\t//setting paths\n\t\tYASEMIR_HOME=ConfigurationHandler.YASEMIR_HOME;\n\t\tINDEX_DIR=YASEMIR_HOME+System.getProperty(\"file.separator\")+ConfigurationHandler.INDEXDIR;\n\t\tTERM_DIR=YASEMIR_HOME+System.getProperty(\"file.separator\")+ConfigurationHandler.TERMIDXDIR;\n\t\t//TERM_DIR=INDEX_DIR+System.getProperty(\"file.separator\")+ConfigurationHandler.TERMIDXDIR;\n\t\tCOLLECTION_DIR=ConfigurationHandler.CORPUSDIR;\n\t\tidField=ConfigurationHandler.DOCIDFIELD;\n\t\tID_ASATTR=ConfigurationHandler.IDFIELD_ASATTR;\n\t\tDOC_DELIM=ConfigurationHandler.DOC_DELIM;\n\t\tCOLLECTION_LANG=ConfigurationHandler.CORPUSLANG;\n\t\t\n\t\tif(COLLECTION_LANG.equals(\"fr\")) analyzer = new FrenchAnalyzer(Version.LUCENE_44);\n\t else if(COLLECTION_LANG.equals(\"it\")) analyzer = new ItalianAnalyzer(Version.LUCENE_44);\n\t else if(COLLECTION_LANG.equals(\"es\")) analyzer = new SpanishAnalyzer(Version.LUCENE_44);\n\t else if(COLLECTION_LANG.equals(\"de\")) analyzer = new GermanAnalyzer(Version.LUCENE_44);\n\t else if(COLLECTION_LANG.equals(\"pt\")) analyzer = new PortugueseAnalyzer(Version.LUCENE_44);\n\t else if(COLLECTION_LANG.equals(\"ca\")) analyzer = new CatalanAnalyzer(Version.LUCENE_44);\n\t else if(COLLECTION_LANG.equals(\"nl\")) analyzer = new DutchAnalyzer(Version.LUCENE_44);\n\t else if(COLLECTION_LANG.equals(\"ar\")) analyzer = new ArabicAnalyzer(Version.LUCENE_44);\n\t else analyzer = new EnglishAnalyzer(Version.LUCENE_44);\n\t\t\n\t\t//setting search mode\n\t\tString sm = ConfigurationHandler.SEARCH_MODE;\n\t\tif(sm!=null){\n\t\t\tif(sm.equalsIgnoreCase(\"semantic\")) MODE=SEMANTIC;\n\t\t\telse if(sm.equalsIgnoreCase(\"hybrid\")) MODE=HYBRID;\n\t\t\telse MODE=CLASSIC;\n\t\t}\n\t\t\n\t\t//setting concept similarity measure\n\t\tString smm = ConfigurationHandler.SIM_MEASURE;\n\t\tif(smm!=null){\n\t\t\tif(smm.equalsIgnoreCase(\"pg1\")) SIM_MEASURE=ConceptSimilarity.PROXYGENEA1;\n\t\t\telse if(smm.equalsIgnoreCase(\"pg2\")) SIM_MEASURE=ConceptSimilarity.PROXYGENEA2;\n\t\t\telse if(smm.equalsIgnoreCase(\"pg3\")) SIM_MEASURE=ConceptSimilarity.PROXYGENEA3;\n\t\t\telse SIM_MEASURE=ConceptSimilarity.WU;\n\t\t}\n\t\t\n\t\t//setting concept weights\n\t\tString cw = ConfigurationHandler.CONCEPTWEIGHT;\n\t\tif(cw!=null){\n\t\t\tif(cw.equalsIgnoreCase(\"fixed\")) CONCEPT_WEIGHTS=ClassWeightHandler.FIXED;\n\t\t\telse if(cw.equalsIgnoreCase(\"idf\")) CONCEPT_WEIGHTS=ClassWeightHandler.IDF;\n\t\t\telse if(cw.equalsIgnoreCase(\"prob\")) CONCEPT_WEIGHTS=ClassWeightHandler.PROB;\n\t\t\telse if(cw.equalsIgnoreCase(\"gauss\")) CONCEPT_WEIGHTS=ClassWeightHandler.GAUSSPROB;\n\t\t}\n\t\t\n\t\t//setting annotator\n\t\tANNOTATOR=ConfigurationHandler.ANNOTENGINE;\n\t\tannotator=new SentenceBasedAnnotator(TERM_DIR);\n\t\t//annotator=new KNNAnnotator(TERM_DIR); //TODO: not finished (select annotator depending on configuration file)\n\t\ttry{\n\t\t\tClass<?> cls = Class.forName(ANNOTATOR);\n\t\t\tConstructor<?> constructor = cls.getConstructor(String.class);\n\t\t\tannotator = (SemanticAnnotator) constructor.newInstance(TERM_DIR);\n\t\t\t//Object instance = constructor.newInstance(\"stringparam\");\n\t\t} catch (Exception e){\n\t\t\te.printStackTrace();\n\t\t\tSystem.err.println(\"[YaSemIR]: failed to load the specified annotator, falling back to IndexBasedAnnotator\");\n\t\t\tannotator=annotator=new SentenceBasedAnnotator(TERM_DIR);\n\t\t}\n\t\t//setting ngrams enabled or not\n\t\tCKPD_ENABLED=ConfigurationHandler.NGRAMS_ENABLED;\n\t\t\n\t\t//setting semantic fields\n\t\tsemBalises=new HashSet<String>();\n\t\tsemBalises.addAll(ConfigurationHandler.getSemanticFields());\n\t\t\n\t\t//setting classic fields\n\t\tclsBalises=new HashSet<String>();\n\t\tclsBalises.addAll(ConfigurationHandler.getClassicFields());\n\t\t\n\t\t//setting score type\n\t\tSCORE=ConfigurationHandler.SCORE;\n\t\t\n\t\t//setting ontologies and terminologies\n\t\tSystem.err.println(\"[YaSemIR]: Loading Knowledge Battery...\");\n\t\t\n\t\tHashMap<String, String> ontoSKOSconf=ConfigurationHandler.getOntologySKOSMap();\n\t\tHashMap<String, String> ontoRootconf = ConfigurationHandler.getOntologyRootMap();\t\t\n\n\t\tfor(String ontoLoc : ontoSKOSconf.keySet()){\n\t\t\tString ontoRoot = ontoRootconf.get(ontoLoc);\n\t\t\tOntology o = null;\n\t\t\tif(ontoRoot.trim().isEmpty()) o = new Ontology(ontoLoc);\n\t\t\telse o = new Ontology(ontoLoc, ontoRoot);\n\t\t\tSystem.err.println(\"[YaSemIR]: loaded ontology: \"+o.getBaseAddr()+\" at \"+ontoLoc);\n\t\t\tString termPath=ontoSKOSconf.get(ontoLoc);\n\t\t\tSKOSTerminology t=null;\n\t\t\tif(!termPath.trim().isEmpty()) {\n\t\t\t\tSystem.err.println(\"[YaSemIR]: loading terminology from \"+termPath);\n\t\t\t\tt = new SKOSTerminology(o.getOntologyID(), termPath);\n\t\t\t}\n\t\t\telse {\n\t\t\t\tSystem.err.println(\"[YaSemIR]: no terminology provided: generating trivial terminology from \"+o.getBaseAddr()+\"...\");\n\t\t\t\tt = o.generateTerminology();\n\t\t\t}\n\t\t\tSystem.err.println(\"[YaSemIR]: loaded terminology: \"+t.getTerminologyID());\n\t\t\tKnowledgeBattery.addOntology(o, t);\n\t\t\t\n\t\t}\n\t\tif(INDEXING_MODE) KnowledgeBattery.createTermIndex();\n\t\tSystem.err.println(\"[YaSemIR]: Done.\");\n\t\t\n\t\t\n\t\t\n\t}",
"@Override\r\n public void initialize(URL url, ResourceBundle rb) {\n user_brand.getItems().addAll(\"clinique\",\"innisfree\",\"neogen\",\"eucerin\");\r\n handler = new DBHandler();\r\n }",
"public GeotiffDataSource(DataSourceDescriptor descriptor,\n String filename, Hashtable properties)\n throws VisADException {\n super(descriptor, filename, \"Tiff data source\", properties);\n openData();\n }",
"private void initMetaSetting() throws DPFTRuntimeException {\n\t\tDPFTConnector connector;\n\t\ttry {\n\t\t\tconnector = DPFTConnectionFactory.initDPFTConnector(DPFTUtil.getSystemDBConfig());\n\t\t\tmeta = (FileMetaDefDboSet) connector.getDboSet(\"DPFT_FILE_META_DEF\", \"chal_name='\" + getChannelName() + \"' and active=1\");\n\t\t\tdicSet = (FileDictionaryDboSet) connector.getDboSet(\"DPFT_FILE_DIC\", \"chal_name='\" + getChannelName() + \"' and active=1\");\n\t\t} catch (DPFTConnectionException e) {\n\t\t\tthrow new DPFTActionException(this, \"SYSTEM\", \"DPFT0001E\", e);\n\t\t}\n\t\tmeta.load();\n\t\tdicSet.load();\n\t\tmeta.close();\n\t\tdicSet.close();\n\t}",
"public static void init(Set<Entry<String, Object>> strategieNames, String packagePath) {\n\n\t\tLOGGER.info(\"looking for classes in package \" + packagePath);\n\n\t\tPublishLogDataStrategy publisherStrategy;\n\t\tIterator<Entry<String, Object>> iteClassnames = strategieNames.iterator();\n\t\tstrategyChain = new ArrayList<PublishLogDataStrategy>();\n\n\t\twhile (iteClassnames.hasNext()) {\n\n\t\t\tEntry<String, Object> classname = iteClassnames.next();\n\t\t\tLOGGER.info(\"found classString \" + classname.getKey().toString());\n\n\t\t\tif (classname.getValue().toString().equals(\"enabled\")) {\n\n\t\t\t\tpublisherStrategy = createNewStrategie(packagePath + classname.getKey().toString());\n\t\t\t\tif (publisherStrategy != null) {\n\t\t\t\t\tstrategyChain.add(publisherStrategy);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}",
"public void newAnalyseDatasetOfLanguage() throws ClassNotFoundException, SQLException {\n\t\topenConnection();\n\t}",
"public TestLearningAPI(String arg0) throws GateException,\n MalformedURLException {\n super(arg0);\n if(!initialized) {\n Gate.init();\n learningHome = new File(new File(Gate.getGateHome(), \"plugins\"),\n \"Learning\");\n Gate.getCreoleRegister().addDirectory(learningHome.toURI().toURL());\n initialized = true;\n }\n }",
"private void init(String description, String[][] localizations)\n/* */ {\n/* 1480 */ initLocalizations(localizations);\n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* 1487 */ StringBuilder descBuf = stripWhitespace(description);\n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* 1494 */ this.lenientParseRules = extractSpecial(descBuf, \"%%lenient-parse:\");\n/* 1495 */ this.postProcessRules = extractSpecial(descBuf, \"%%post-process:\");\n/* */ \n/* */ \n/* */ \n/* */ \n/* 1500 */ int numRuleSets = 0;\n/* 1501 */ for (int p = descBuf.indexOf(\";%\"); p != -1; p = descBuf.indexOf(\";%\", p)) {\n/* 1502 */ numRuleSets++;\n/* 1503 */ p++;\n/* */ }\n/* 1505 */ numRuleSets++;\n/* */ \n/* */ \n/* 1508 */ this.ruleSets = new NFRuleSet[numRuleSets];\n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* 1517 */ String[] ruleSetDescriptions = new String[numRuleSets];\n/* */ \n/* 1519 */ int curRuleSet = 0;\n/* 1520 */ int start = 0;\n/* 1521 */ for (int p = descBuf.indexOf(\";%\"); p != -1; p = descBuf.indexOf(\";%\", start)) {\n/* 1522 */ ruleSetDescriptions[curRuleSet] = descBuf.substring(start, p + 1);\n/* 1523 */ this.ruleSets[curRuleSet] = new NFRuleSet(ruleSetDescriptions, curRuleSet);\n/* 1524 */ curRuleSet++;\n/* 1525 */ start = p + 1;\n/* */ }\n/* 1527 */ ruleSetDescriptions[curRuleSet] = descBuf.substring(start);\n/* 1528 */ this.ruleSets[curRuleSet] = new NFRuleSet(ruleSetDescriptions, curRuleSet);\n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* 1543 */ boolean defaultNameFound = false;\n/* 1544 */ int n = this.ruleSets.length;\n/* 1545 */ this.defaultRuleSet = this.ruleSets[(this.ruleSets.length - 1)];\n/* */ for (;;) {\n/* 1547 */ n--; if (n < 0) break;\n/* 1548 */ String currentName = this.ruleSets[n].getName();\n/* 1549 */ if ((currentName.equals(\"%spellout-numbering\")) || (currentName.equals(\"%digits-ordinal\")) || (currentName.equals(\"%duration\"))) {\n/* 1550 */ this.defaultRuleSet = this.ruleSets[n];\n/* 1551 */ defaultNameFound = true;\n/* 1552 */ break;\n/* */ }\n/* */ }\n/* */ \n/* 1556 */ if (!defaultNameFound) {\n/* 1557 */ for (int i = this.ruleSets.length - 1; i >= 0; i--) {\n/* 1558 */ if (!this.ruleSets[i].getName().startsWith(\"%%\")) {\n/* 1559 */ this.defaultRuleSet = this.ruleSets[i];\n/* 1560 */ break;\n/* */ }\n/* */ }\n/* */ }\n/* */ \n/* */ \n/* */ \n/* */ \n/* 1568 */ for (int i = 0; i < this.ruleSets.length; i++) {\n/* 1569 */ this.ruleSets[i].parseRules(ruleSetDescriptions[i], this);\n/* 1570 */ ruleSetDescriptions[i] = null;\n/* */ }\n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* 1578 */ int publicRuleSetCount = 0;\n/* 1579 */ for (int i = 0; i < this.ruleSets.length; i++) {\n/* 1580 */ if (!this.ruleSets[i].getName().startsWith(\"%%\")) {\n/* 1581 */ publicRuleSetCount++;\n/* */ }\n/* */ }\n/* */ \n/* */ \n/* 1586 */ String[] publicRuleSetTemp = new String[publicRuleSetCount];\n/* 1587 */ publicRuleSetCount = 0;\n/* 1588 */ for (int i = this.ruleSets.length - 1; i >= 0; i--) {\n/* 1589 */ if (!this.ruleSets[i].getName().startsWith(\"%%\")) {\n/* 1590 */ publicRuleSetTemp[(publicRuleSetCount++)] = this.ruleSets[i].getName();\n/* */ }\n/* */ }\n/* */ \n/* 1594 */ if (this.publicRuleSetNames != null)\n/* */ {\n/* */ label585:\n/* 1597 */ for (int i = 0; i < this.publicRuleSetNames.length; i++) {\n/* 1598 */ String name = this.publicRuleSetNames[i];\n/* 1599 */ for (int j = 0; j < publicRuleSetTemp.length; j++) {\n/* 1600 */ if (name.equals(publicRuleSetTemp[j])) {\n/* */ break label585;\n/* */ }\n/* */ }\n/* 1604 */ throw new IllegalArgumentException(\"did not find public rule set: \" + name);\n/* */ }\n/* */ \n/* 1607 */ this.defaultRuleSet = findRuleSet(this.publicRuleSetNames[0]);\n/* */ } else {\n/* 1609 */ this.publicRuleSetNames = publicRuleSetTemp;\n/* */ }\n/* */ }",
"public CategoryTransferHandler() {\n }",
"@Override\n\tpublic void initialize(URL location, ResourceBundle resources) {\n\t\ttry {\n\t\t\t//loading b+ tree\n\t\t\tNumbConverter numbConverter = new NumbConverter(Comparators.numbComparator);\n\t\t\t//bPlusTree= new BPlusTree<Numb>(2,2,Comparators.numbComparator, numbConverter, 100, 4, 14);\n\t\t\ttest();\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t}catch(Exception e) {\n\t\t\tSystem.out.println(\"Problem with loading!\");\n\t\t}\n\t}",
"@Override\n public void initialize(URL url, ResourceBundle rb)\n {\n txtDuration.setDisable(true);\n txtFile.setDisable(true);\n comboCategoryBox.setItems(FXCollections.observableArrayList(\"Blues\", \"Hip Hop\", \"Pop\", \"Rap\",\n \"Rock\", \"Techno\", \"Other\"));\n comboCategoryBox.setVisibleRowCount(6);\n txtOtherCategory.setVisible(false);\n }",
"public void initialize() {\n\n\t\tthis.subNetGenes = getSubNetGenes(species, xmlFile);\n\t\tthis.subNetwork = getSubNetwork(subNetGenes, oriGraphFile);\n\t\tHPNUlilities.dumpLocalGraph(subNetwork, subNetFile);\n\t\t/* Create level file for the original graph */\n\t\tHPNUlilities.createLevelFile(codePath, oriGraphFile, oriLevel,\n\t\t\t\tglobalLevelFile, penaltyType, partitionSize);\n\n\t}",
"@Override\r\n public void initialize(URL url, ResourceBundle rb) {\r\n //Carga Los componentes de la tapPersonal\r\n lanzaPersonal();\r\n }",
"@Override\r\n public void initialize(URL location, ResourceBundle resources) {\r\n\r\n }",
"private void init() {\n if (mHeadline != null) {\n mHeadlingString = StringEscapeUtils.unescapeHtml4(mHeadline.getMain());\n }\n\n for (ArticleMultimedia multimedia : mMultimedia) {\n if (multimedia.getSubtype().equals(\"thumbnail\")) {\n mThumbnail = getMultimediaUrl(multimedia);\n }\n }\n }",
"public AltaCategoria() {\n initComponents();\n }",
"@Override\n public void initialize(URL location, ResourceBundle resources) {\n }",
"@Override\n public void initialize(URL location, ResourceBundle resources) {\n }",
"@Override\n public void initialize(URL location, ResourceBundle resources) {\n }",
"@Override\n public void initialize(URL location, ResourceBundle resources) {\n }",
"@Override\n public void initialize(URL location, ResourceBundle resources) {\n }",
"@Override\r\n\tpublic void initialize(URL arg0, ResourceBundle arg1)\r\n\t{\r\n\t\tString gasStationS = findManagerGasStation();\r\n\t\trefreshSalesFeedbackTable(gasStationS);\r\n\t}",
"@Override\n public void initialize(URL url, ResourceBundle rb) {\n // TODO\n cbCategoryDeposit.setItems(Category.getCategories());\n cbCategoryWithdrawal.setItems(Category.getCategories());\n }",
"@Override\n public void initialize(URL url, ResourceBundle resourceBundle) {\n initPhotoList(); // Configura a lista de inicial de empresas, que servirar de base para as filtragens\n }",
"@Override\n public void initialize(URL location, ResourceBundle resources) {}",
"@Override\n public void initialize(URL url, ResourceBundle rb) { \n loadNouveaux();\n loadTerrains(); \n \n }",
"@Override\n\tpublic void init(graph g) {\n\t\tthis.GA = g;\n\t}",
"public void init() {\r\n resources = new Vector<ResourcesElement>();\r\n informations = new Vector<InformationElement>();\r\n output = null;\r\n spec = DEFAULT_SPEC;\r\n version = null;\r\n codeBase = null;\r\n href = null;\r\n allPermissions = false;\r\n j2eePermissions = false;\r\n isComponent = false;\r\n applicationDesc = null;\r\n appletDesc = null;\r\n installerDesc = null;\r\n }",
"public ZCategoryManager(TFileManeger fm) {\r\n\t\tsuper();\r\n\t\tthis.fm = fm;\r\n\t}",
"private LanguagesettingsPackage() {}",
"public Language() {\r\n\t}",
"public CountryIO() {\r\n\t\tcountriesPath = Paths.get(\"countries.txt\");\r\n\t\tcountriesFile = countriesPath.toFile();\r\n\t\tgetCountries();\r\n\t}",
"public void initialize(URL location, ResourceBundle resources) {\r\n\r\n\t}",
"@Override\n public void initialize(URL location, ResourceBundle resources) {\n\n }",
"public void init() {\n\n\t\tif (optionFields == null) {\n\t\t\toptionFields = new HashMap<String, MetaVal>();\n\t\t}\n\t\tif (inputFields == null) {\n\t\t\tinputFields = new HashMap<String, MetaVal>();\n\t\t}\n\t\tif (outputFields == null) {\n\t\t\toutputFields = new HashMap<String, MetaVal>();\n\t\t}\n\n\t\t// repository xml key tag, metavalue default, web tag, and size are set here\n\t\t// OPTIONS\n\t\toptionFields.put(TAG_OPTION_DOMINANT_BUSINESS, new MetaVal(\"yes\", \"ReturnDominantBusiness:\", 0));\n\t\toptionFields.put(TAG_OPTION_INCLUDE_CENSUS, new MetaVal(\"false\", \"GrpCensus\", 0));\n\n\n\t\t// INPUTS\n\t\tinputFields.put(TAG_INPUT_BUSINESS_NAME, new MetaVal(\"\", \"comp\", 50));\n\t\tinputFields.put(TAG_INPUT_ADDRESS_LINE1, new MetaVal(\"\", \"a1\", 50));\n\t\tinputFields.put(TAG_INPUT_ADDRESS_LINE2, new MetaVal(\"\", \"a2\", 20));\n\t\tinputFields.put(TAG_INPUT_CITY, new MetaVal(\"\", \"city\", 50));\n\t\tinputFields.put(TAG_INPUT_STATE, new MetaVal(\"\", \"state\", 3));\n\t\tinputFields.put(TAG_INPUT_POSTAL_CODE, new MetaVal(\"\", \"postal\", 10));\n\t\tinputFields.put(TAG_INPUT_COUNTRY, new MetaVal(\"US\", \"ctry\", 50));\n\t\tinputFields.put(TAG_INPUT_PHONE, new MetaVal(\"\", \"phone\", 12));\n\t\tinputFields.put(TAG_INPUT_ADDRESS_KEY, new MetaVal(\"\", \"mak\", 50));\n\t\tinputFields.put(TAG_INPUT_STOCK_TICKER, new MetaVal(\"\", \"stock\", 10));\n\t\tinputFields.put(TAG_INPUT_WEB_ADDRESS, new MetaVal(\"\", \"web\", 50));\n\n\t\t// OUTPUTS\n\t\toutputFields.put(TAG_OUTPUT_RESULTS, new MetaVal(\"MD_Results\", \"Results\", 50));\n\t\toutputFields.put(TAG_OUTPUT_COMPANY_NAME, new MetaVal(\"MD_CompanyName\", \"CompanyName\", 50));\n\t\toutputFields.put(TAG_OUTPUT_ADDRESS_LINE1, new MetaVal(\"MD_AddressLine1\", \"AddressLine1\", 50));\n\t\toutputFields.put(TAG_OUTPUT_SUITE, new MetaVal(\"MD_Suite\", \"Suite\", 50));\n\t\toutputFields.put(TAG_OUTPUT_CITY, new MetaVal(\"MD_City\", \"City\", 50));\n\t\toutputFields.put(TAG_OUTPUT_STATE, new MetaVal(\"MD_State\", \"State\", 50));\n\n\t\toutputFields.put(TAG_OUTPUT_COUNTRY_NAME, new MetaVal(\"MD_CountryName\", \"CountryName\", 50));\n\t\toutputFields.put(TAG_OUTPUT_COUNTRY_CODE, new MetaVal(\"MD_CountryCode\", \"CountryCode\", 50));\n\t\toutputFields.put(TAG_OUTPUT_EIN, new MetaVal(\"MD_EIN\", \"EIN\", 50));\n\n\t\toutputFields.put(TAG_OUTPUT_POSTAL_CODE, new MetaVal(\"MD_PostalCode\", \"PostalCode\", 10));\n\t\toutputFields.put(TAG_OUTPUT_LOCATION_TYPE, new MetaVal(\"MD_LocationType\", \"LocationType\", 50));\n// outputFields.put(TAG_OUTPUT_FEMALE_OWNED, new MetaVal(\"MD_FemaleOwned\", \"FemaleOwned\", 50));\n// outputFields.put(TAG_OUTPUT_SMALL_BUSINESS, new MetaVal(\"MD_SmallBusiness\", \"SmallBusiness\", 50));\n// outputFields.put(TAG_OUTPUT_HOME_BASED_BUSINESS, new MetaVal(\"MD_HomeBasedBusiness\", \"HomeBasedBusiness\", 50));\n\t\toutputFields.put(TAG_OUTPUT_PHONE, new MetaVal(\"MD_Phone\", \"Phone\", 50));\n// outputFields.put(TAG_OUTPUT_LOCAL_EMPLOYEES_ESTIMATE, new MetaVal(\"MD_LocalEmployeesEstimate\", \"LocalEmployeesEstimate\",\n// 50));\n// outputFields.put(TAG_OUTPUT_LOCAL_SALES_ESTIMATE, new MetaVal(\"MD_LocalSalesEstimate\", \"LocalSalesEstimate\", 50));\n\t\toutputFields.put(TAG_OUTPUT_EMPLOYEES_ESTIMATE, new MetaVal(\"MD_TotalEmployeesEstimate\", \"EmployeesEstimate\", 50));\n\t\toutputFields.put(TAG_OUTPUT_SALES_ESTIMATE, new MetaVal(\"MD_TotalSalesEstimate\", \"SalesEstimate\", 50));\n\t\toutputFields.put(TAG_OUTPUT_STOCK_TICKER, new MetaVal(\"MD_StockTicker\", \"StockTicker\", 50));\n\t\toutputFields.put(TAG_OUTPUT_WEB_ADDRESS, new MetaVal(\"MD_WebAddress\", \"WebAddress\", 50));\n\t\toutputFields.put(TAG_OUTPUT_SIC_CODE, new MetaVal(\"MD_SICCode1\", \"SICCode1\", 50));\n\t\toutputFields.put(TAG_OUTPUT_SIC_DESCRIPTION, new MetaVal(\"MD_SICDescription1\", \"SICDescription1\", 50));\n\t\toutputFields.put(TAG_OUTPUT_SIC_CODE2, new MetaVal(\"MD_SICCode2\", \"SICCode2\", 50));\n\t\toutputFields.put(TAG_OUTPUT_SIC_DESCRIPTION2, new MetaVal(\"MD_SICDescription2\", \"SICDescription2\", 50));\n\t\toutputFields.put(TAG_OUTPUT_SIC_CODE3, new MetaVal(\"MD_SICCode3\", \"SICCode3\", 50));\n\t\toutputFields.put(TAG_OUTPUT_SIC_DESCRIPTION3, new MetaVal(\"MD_SICDescription3\", \"SICDescription3\", 50));\n\t\toutputFields.put(TAG_OUTPUT_NAICS_CODE, new MetaVal(\"MD_NAICSCode1\", \"NAICSCode1\", 50));\n\t\toutputFields.put(TAG_OUTPUT_NAICS_DESCRIPTION, new MetaVal(\"MD_NAICSDescription1\", \"NAICSDescription1\", 50));\n\t\toutputFields.put(TAG_OUTPUT_NAICS_CODE2, new MetaVal(\"MD_NAICSCode2\", \"NAICSCode2\", 50));\n\t\toutputFields.put(TAG_OUTPUT_NAICS_DESCRIPTION2, new MetaVal(\"MD_NAICSDescription2\", \"NAICSDescription2\", 50));\n\t\toutputFields.put(TAG_OUTPUT_NAICS_CODE3, new MetaVal(\"MD_NAICSCode3\", \"NAICSCode3\", 50));\n\t\toutputFields.put(TAG_OUTPUT_NAICS_DESCRIPTION3, new MetaVal(\"MD_NAICSDescription3\", \"NAICSDescription3\", 50));\n\n\t\toutputFields.put(TAG_OUTPUT_CENSUS_BLOCK, new MetaVal(\"MD_CensusBlock\", \"CensusBlock\", 50));\n\t\toutputFields.put(TAG_OUTPUT_CENSUS_TRACT, new MetaVal(\"MD_CensusTract\", \"CensusTract\", 50));\n\t\toutputFields.put(TAG_OUTPUT_COUNTY_FIPS, new MetaVal(\"MD_CountyFIPS\", \"CountyFIPS\", 50));\n\t\toutputFields.put(TAG_OUTPUT_COUNTY_NAME, new MetaVal(\"MD_CountyName\", \"CountyName\", 50));\n\t\toutputFields.put(TAG_OUTPUT_DELIVERY_INDICATOR, new MetaVal(\"MD_DeliveryIndicator\", \"DeliveryIndicator\", 50));\n\t\toutputFields.put(TAG_OUTPUT_LATITUDE, new MetaVal(\"MD_Latitude\", \"Latitude\", 50));\n\t\toutputFields.put(TAG_OUTPUT_LONGITUDE, new MetaVal(\"MD_Longitude\", \"Longitude\", 50));\n\t\toutputFields.put(TAG_OUTPUT_MD_ADDRESS_KEY, new MetaVal(\"MD_MelissaAddressKey\", \"MelissaAddressKey\", 50));\n\t\toutputFields.put(TAG_OUTPUT_MD_ADDRESS_KEY_BASE, new MetaVal(\"MD_MelissaAddressKeyBase\", \"MelissaAddressKeyBase\", 50));\n\t\toutputFields.put(TAG_OUTPUT_PLUS_4, new MetaVal(\"MD_Plus4\", \"Plus4\", 50));\n\t\toutputFields.put(TAG_OUTPUT_PLACE_NAME, new MetaVal(\"MD_PlaceName\", \"PlaceName\", 50));\n\t\toutputFields.put(TAG_OUTPUT_PLACE_CODE, new MetaVal(\"MD_PlaceCode\", \"PlaceCode\", 50));\n\n\t\toutputFields.put(TAG_OUTPUT_FIRST_NAME_1, new MetaVal(\"MD_FirstName1\", \"NameFirst\", 50));\n\t\toutputFields.put(TAG_OUTPUT_LAST_NAME_1, new MetaVal(\"MD_LastName1\", \"NameLast\", 50));\n\t\toutputFields.put(TAG_OUTPUT_GENDER_1, new MetaVal(\"MD_Gender1\", \"Gender\", 50));\n\t\toutputFields.put(TAG_OUTPUT_TITLE_1, new MetaVal(\"MD_Title1\", \"Title\", 50));\n\t\toutputFields.put(TAG_OUTPUT_EMAIL_1, new MetaVal(\"MD_Email1\", \"Email\", 50));\n\n\t\toutputFields.put(TAG_OUTPUT_FIRST_NAME_2, new MetaVal(\"MD_FirstName2\", \"NameFirst\", 50));\n\t\toutputFields.put(TAG_OUTPUT_LAST_NAME_2, new MetaVal(\"MD_LastName2\", \"NameLast\", 50));\n\t\toutputFields.put(TAG_OUTPUT_GENDER_2, new MetaVal(\"MD_Gender2\", \"Gender\", 50));\n\t\toutputFields.put(TAG_OUTPUT_TITLE_2, new MetaVal(\"MD_Title2\", \"Title\", 50));\n\t\toutputFields.put(TAG_OUTPUT_EMAIL_2, new MetaVal(\"MD_Email2\", \"Email\", 50));\n\n\t}",
"public void init(ViewConfigData config) {\n\r\n this.viewConfig = config;\r\n\r\n /* fill the ontologyMap\r\n String ontologyMapFile = viewConfig.getOntologyMap(); */\r\n\r\n /* try {\r\n ontologyMapStore.parse(ontologyMapFile, false);\r\n } catch (FileNotFoundException e) {\r\n throw new ConfigurationException(\r\n \"FileNotFoundException for the ontology map file: \"\r\n + ontologyMapFile, e);\r\n } catch (IOException e) {\r\n throw new ConfigurationException(\r\n \"IOException while trying to parse the ontology map file: \"\r\n + ontologyMapFile, e);\r\n } */\r\n\r\n //fill the schemaMap\r\n String schemaMapFile = viewConfig.getSchemaMap();\r\n try {\r\n schemaMapStore.parse(schemaMapFile, false);\r\n } catch (FileNotFoundException e) {\r\n throw new ConfigurationException(\r\n \"FileNotFoundException for the schema map file: \"\r\n + schemaMapFile, e);\r\n } catch (IOException e) {\r\n throw new ConfigurationException(\r\n \"ConfigurationException for the schema map file: \"\r\n + schemaMapFile, e);\r\n }\r\n\r\n //build the DTree. It also fills the ontologyStore\r\n dTree = buildDTree();\r\n \r\n //build the hash table for ont map properites\r\n String ontMappropertiesFilePath = viewConfig.getOntMapProperties();\r\n ReadPropFile.loadToHashTableFromOntmapPropertiesFile(ontMappropertiesFilePath); \r\n \r\n }",
"private void ini_Translations()\r\n\t{\r\n\t\tLogger.DEBUG(\"ini_Translations\");\r\n\t\tnew Translation(\"data\", FileType.Internal);\r\n\t\ttry\r\n\t\t{\r\n\t\t\tTranslation.LoadTranslation(\"data/lang/en-GB/strings.ini\");\r\n\t\t}\r\n\t\tcatch (IOException e)\r\n\t\t{\r\n\t\t\te.printStackTrace();\r\n\t\t}\r\n\t}",
"public void initParser() {;\r\n lp = DependencyParser.loadFromModelFile(\"edu/stanford/nlp/models/parser/nndep/english_SD.gz\");\r\n tokenizerFactory = PTBTokenizer\r\n .factory(new CoreLabelTokenFactory(), \"\");\r\n }",
"public Librarian() {\n initComponents();\n }",
"@Override\n public void initialize(URL url, ResourceBundle rb) {\n // TODO\n loadLabelData();\n }",
"private void initBroker() throws URISyntaxException, IOException {\n\n ClassLoader classloader = Thread.currentThread().getContextClassLoader();\n\n // InputStream is = classloader.getResourceAsStream(\"data/merchant.csv\");\n\n URL brokerURL = classloader.getResource(\"data/broker/\");\n String[] merchantFiles = new File(brokerURL.toURI()).list();\n\n int j = 0;\n while (j < merchantFiles.length) {\n InputStream is = classloader.getResourceAsStream(\"data/broker/\" + merchantFiles[j]);\n CSVReader reader = new CSVReader(new InputStreamReader(is, \"UTF-8\"));\n String[] nextLine;\n while ((nextLine = reader.readNext()) != null) {\n String tradeName = nextLine[FORENAME];\n if (StringUtils.isBlank(tradeName)) {\n continue;\n }\n brokerImportService.saveOrUpdateBroker(fillUpBrokerImportVO(nextLine));\n }\n j++;\n }\n\n }",
"private void initialize() {\n \t\tfor (Module module : UserType.getCurrentUserType().getModules()) {\n \t\t\tif (module.getModuleClass() != null) {\n \t\t\t\tregisterModule(module);\n \t\t\t}\n \t\t}\n \t\tif (GeneralPreferences.getLanguage() != null && GeneralPreferences.getLanguage().equals(Language.FRENCH)) {\n \t\t\tLocale.setDefault(Locale.FRANCE);\n \t\t} else {\n \t\t\tLocale.setDefault(Locale.US);\n \t\t}\n \t\tFlexoHelp.configure(GeneralPreferences.getLanguage() != null ? GeneralPreferences.getLanguage().getIdentifier() : \"ENGLISH\",\n \t\t\t\tUserType.getCurrentUserType().getIdentifier());\n \t}",
"@PostConstruct\r\n public void init() {\n URL url = Resources.getResource(\"schema.graphqls\");\r\n \r\n String sdl=\"\";\r\n try\r\n {\r\n sdl = Resources.toString(url, Charsets.UTF_8);\r\n }\r\n catch(IOException ioe)\r\n {\r\n ioe.printStackTrace();\r\n } \r\n\r\n System.out.println(\"GraphQLProvider init schema read \\n\"+sdl);\r\n \r\n //call method to build schema\r\n GraphQLSchema graphQLSchema = buildSchema(sdl);\r\n this.graphQL = GraphQL.newGraphQL(graphQLSchema).build();\r\n }",
"private LanguageModel(String corpusFilePath, boolean considerExtra) throws Exception {\n\t\tconstructDictionaries(corpusFilePath, considerExtra);\n\t}",
"@Override\n public void setLanguage(String lang) {\n }",
"@Override\r\n\tpublic void initialize(URL location, ResourceBundle resources) {\r\n\t\tacainstance=this;\r\n\t\tchat.accept(new Message(66, null));\r\n\t\tchat.accept(new Message(67, null));\r\n\t\tchat.accept(new Message(75, null));\r\n\t\t\tReport.add(\"Comments Report for Marketing Campaign\");\r\n\t\t\tReport.add(\"Customer Periodic Characterization Report\");\r\n\t\t\tReportList.addAll(Report);\r\n\t\t\tcomboReportType.setItems(ReportList);\r\n\t}",
"private void readCategories() throws Exception {\n\t\t//reads files in nz category\n\t\tif (_nzCategories.size() > 0) {\n\t\t\tfor (String category: _nzCategories) {\n\t\t\t\t// read each individual line from the category files and store it\n\t\t\t\ttry {\n\t\t\t\t\tFile file = new File(\"categories/nz/\", category);\n\t\t\t\t\tScanner myReader = new Scanner(file);\n\t\t\t\t\tList<String> allLines = new ArrayList<String>();\n\t\t\t\t\twhile(myReader.hasNextLine()) {\n\t\t\t\t\t\tString fileLine = myReader.nextLine();\n\t\t\t\t\t\tallLines.add(fileLine);\n\t\t\t\t\t}\n\t\t\t\t\tList<String> copy = new ArrayList<String>(allLines);\n\t\t\t\t\t_nzData.put(category, copy);\n\t\t\t\t\tallLines.clear();\n\t\t\t\t\tmyReader.close();\n\t\t\t\t} catch (FileNotFoundException e) {\n\t\t\t\t\te.printStackTrace();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t//reads file in international categories\n\t\tif (_intCategories.size() > 0) {\n\t\t\tfor (String category: _intCategories) {\n\t\t\t\t// read each individual line from the category files and store it\n\t\t\t\ttry {\n\t\t\t\t\tFile file = new File(\"categories/international/\", category);\n\t\t\t\t\tScanner myReader = new Scanner(file);\n\t\t\t\t\tList<String> allLines = new ArrayList<String>();\n\t\t\t\t\twhile(myReader.hasNextLine()) {\n\t\t\t\t\t\tString fileLine = myReader.nextLine();\n\t\t\t\t\t\tallLines.add(fileLine);\n\t\t\t\t\t}\n\t\t\t\t\tList<String> copy = new ArrayList<String>(allLines);\n\t\t\t\t\t_intData.put(category, copy);\n\t\t\t\t\tallLines.clear();\n\t\t\t\t\tmyReader.close();\n\t\t\t\t} catch (FileNotFoundException e) {\n\t\t\t\t\te.printStackTrace();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}",
"@Override\r\n\tpublic void initialize(URL location, ResourceBundle resources) {\n\t\t\r\n\t}",
"public void initializePackageContents() {\n\t\tif (isInitialized) return;\n\t\tisInitialized = true;\n\n\t\t// Initialize package\n\t\tsetName(eNAME);\n\t\tsetNsPrefix(eNS_PREFIX);\n\t\tsetNsURI(eNS_URI);\n\n\t\t// Create type parameters\n\n\t\t// Set bounds for type parameters\n\n\t\t// Add supertypes to classes\n\n\t\t// Initialize classes, features, and operations; add parameters\n\t\tinitEClass(mealyMachineEClass, MealyMachine.class, \"MealyMachine\", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);\n\t\tinitEReference(getMealyMachine_InitialState(), this.getState(), null, \"initialState\", null, 1, 1, MealyMachine.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);\n\t\tinitEReference(getMealyMachine_States(), this.getState(), null, \"states\", null, 1, -1, MealyMachine.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);\n\t\tinitEReference(getMealyMachine_InputAlphabet(), this.getAlphabet(), null, \"inputAlphabet\", null, 1, 1, MealyMachine.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, !IS_UNIQUE, !IS_DERIVED, IS_ORDERED);\n\t\tinitEReference(getMealyMachine_OutputAlphabet(), this.getAlphabet(), null, \"outputAlphabet\", null, 1, 1, MealyMachine.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);\n\t\tinitEReference(getMealyMachine_Transitions(), this.getTransition(), null, \"transitions\", null, 1, -1, MealyMachine.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);\n\n\t\tinitEClass(stateEClass, State.class, \"State\", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);\n\t\tinitEAttribute(getState_Name(), ecorePackage.getEString(), \"name\", null, 1, 1, State.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);\n\n\t\tinitEClass(alphabetEClass, Alphabet.class, \"Alphabet\", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);\n\t\tinitEAttribute(getAlphabet_Characters(), ecorePackage.getEString(), \"characters\", null, 1, -1, Alphabet.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);\n\n\t\tinitEClass(transitionEClass, Transition.class, \"Transition\", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);\n\t\tinitEReference(getTransition_SourceState(), this.getState(), null, \"sourceState\", null, 1, 1, Transition.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);\n\t\tinitEReference(getTransition_TargetState(), this.getState(), null, \"targetState\", null, 1, 1, Transition.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);\n\t\tinitEAttribute(getTransition_Input(), ecorePackage.getEString(), \"input\", null, 1, 1, Transition.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);\n\t\tinitEAttribute(getTransition_Output(), ecorePackage.getEString(), \"output\", null, 1, 1, Transition.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);\n\n\t\t// Create resource\n\t\tcreateResource(eNS_URI);\n\t}",
"private void initialize()\n {\n if (null!=cc)\n {\n throw new RuntimeException(\"CorpusServiceI has been initialized already\");\n }\n dataDir = mAdapter.getCommunicator().getProperties().getProperty(\"CVAC.DataDir\");\n logger.log(Level.FINE, \"CorpusService found CVAC.DataDir={0}\", dataDir);\n logger.setLevel(Level.FINEST);\n CorpusI.rootDataDir = dataDir;\n cc = new CorpusConfig();\n corpToImp = new HashMap<String, CorpusI>();\n logger.log(Level.INFO, \"CorpusService initialized\" );\n }",
"private void init(Boolean genNewsQueries, Boolean genWikiQueries, Integer numOfQueries, String queryLanguages) {\n this.newsQueries = genNewsQueries;\n this.wikiQueries = genWikiQueries;\n this.numOfQueries = numOfQueries;\n this.queryLanguages = queryLanguages;\n this.currentQueryIndex = 0;\n this.isInitializedForUima = false;\n this.queriesGenerated = false;\n\n if (!genNewsQueries && !genWikiQueries)\n throw new IllegalArgumentException(\"Either PARAM_GEN_NEWS_QUERIES, PARAM_GEN_WIKI_QUERIES or both must be true!\");\n\n if (queryLanguages == null || queryLanguages.isEmpty())\n throw new IllegalArgumentException(\"Languages must not be null or empty!\");\n\n QueryStore.getInstance().reset();\n }",
"@Override\n public void initialize(URL url, ResourceBundle rb) {\n asociarComponentes();\n }",
"@Override\r\n public void initialize(URL location, ResourceBundle resources)\r\n {\n }",
"@Override\n public void initialize(URL url, ResourceBundle rb) {\n setItems();\n\n }",
"public GMailProperties(final String filepath, final String charsetName) throws FileNotFoundException, IOException {\r\n this.properties = new PropertyStorage(filepath, charsetName);\r\n }"
] | [
"0.5386637",
"0.5231686",
"0.5230441",
"0.51629037",
"0.5123509",
"0.5105772",
"0.5104476",
"0.50786316",
"0.5065911",
"0.50551164",
"0.5035335",
"0.5034056",
"0.501614",
"0.50126463",
"0.50106066",
"0.49710736",
"0.49567038",
"0.49543297",
"0.4943374",
"0.49156055",
"0.4903908",
"0.4895487",
"0.4891337",
"0.4879438",
"0.4878427",
"0.4876369",
"0.48760086",
"0.4872738",
"0.48635375",
"0.48607582",
"0.48537406",
"0.48536822",
"0.48446637",
"0.48410335",
"0.4817077",
"0.48108187",
"0.48084086",
"0.48010474",
"0.47993958",
"0.4797947",
"0.47956315",
"0.47698444",
"0.47673348",
"0.47547522",
"0.4733773",
"0.4726517",
"0.4723387",
"0.47194293",
"0.4719317",
"0.47152078",
"0.47107926",
"0.47013953",
"0.46959245",
"0.4691682",
"0.46912634",
"0.46880212",
"0.46859038",
"0.4684944",
"0.4681653",
"0.46778798",
"0.46749663",
"0.46670687",
"0.46670687",
"0.46670687",
"0.46670687",
"0.46670687",
"0.4665898",
"0.4660938",
"0.46536914",
"0.4650781",
"0.46485487",
"0.4646432",
"0.4645524",
"0.46454132",
"0.4644702",
"0.46410152",
"0.46399638",
"0.46375984",
"0.46326995",
"0.46279848",
"0.46272105",
"0.46194032",
"0.46148142",
"0.46130902",
"0.46109658",
"0.4608872",
"0.46077627",
"0.46026257",
"0.45957106",
"0.45956385",
"0.4593382",
"0.45884636",
"0.45863295",
"0.45851314",
"0.45811626",
"0.4579737",
"0.4573298",
"0.45730588",
"0.4570353",
"0.4568355"
] | 0.6368958 | 0 |
TODO Autogenerated method stub | @Override
protected void createPackage() {
decorations.add(new BridesMaidDeco());
decorations.add(new BridalDeco());
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@Override\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}",
"@Override\n\tpublic void comer() {\n\t\t\n\t}",
"@Override\n public void perish() {\n \n }",
"@Override\r\n\t\t\tpublic void annadir() {\n\r\n\t\t\t}",
"@Override\n\tpublic void anular() {\n\n\t}",
"@Override\n\tprotected void getExras() {\n\n\t}",
"@Override\r\n\tpublic void anularFact() {\n\t\t\r\n\t}",
"@Override\n\tpublic void entrenar() {\n\t\t\n\t}",
"@Override\n\tpublic void nadar() {\n\t\t\n\t}",
"@Override\r\n\tpublic void tires() {\n\t\t\r\n\t}",
"@Override\r\n\t\t\tpublic void ayuda() {\n\r\n\t\t\t}",
"@Override\n\tprotected void interr() {\n\t}",
"@Override\n\tpublic void emprestimo() {\n\n\t}",
"@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}",
"@Override\n\tpublic void grabar() {\n\t\t\n\t}",
"@Override\n\tpublic void gravarBd() {\n\t\t\n\t}",
"@Override\r\n\tpublic void rozmnozovat() {\n\t}",
"@Override\r\n\tpublic void dormir() {\n\t\t\r\n\t}",
"@Override\n protected void getExras() {\n }",
"@Override\r\n\tpublic void publierEnchere() {\n\t\t\r\n\t}",
"@Override\n\tpublic void nefesAl() {\n\n\t}",
"@Override\n\tpublic void ligar() {\n\t\t\n\t}",
"@Override\n public void func_104112_b() {\n \n }",
"@Override\n\tprotected void initdata() {\n\n\t}",
"@Override\n\tpublic void nghe() {\n\n\t}",
"@Override\n public void function()\n {\n }",
"@Override\n public void function()\n {\n }",
"public final void mo51373a() {\n }",
"@Override\r\n\tpublic void stehReagieren() {\r\n\t\t//\r\n\t}",
"@Override\n public void inizializza() {\n\n super.inizializza();\n }",
"@Override\n\tprotected void initData() {\n\t\t\n\t}",
"@Override\r\n\t\tpublic void init() {\n\t\t\t\r\n\t\t}",
"@Override\n\tpublic void sacrifier() {\n\t\t\n\t}",
"@Override\r\n\tprotected void InitData() {\n\t\t\r\n\t}",
"public void designBasement() {\n\t\t\r\n\t}",
"@Override\r\n\tprotected void initialize() {\r\n\t\t\r\n\t\t\r\n\t}",
"public void gored() {\n\t\t\n\t}",
"@Override\r\n\tprotected void initData() {\n\r\n\t}",
"@Override\n\tpublic void einkaufen() {\n\t}",
"@Override\n protected void initialize() {\n\n \n }",
"public void mo38117a() {\n }",
"@Override\n\tprotected void getData() {\n\t\t\n\t}",
"Constructor() {\r\n\t\t \r\n\t }",
"@Override\r\n\tpublic void dibujar() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void dibujar() {\n\t\t\r\n\t}",
"@Override\n\tpublic void one() {\n\t\t\n\t}",
"@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}",
"@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}",
"@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}",
"@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}",
"@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}",
"@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}",
"private stendhal() {\n\t}",
"@Override\n\tprotected void update() {\n\t\t\n\t}",
"@Override\n\t\t\tpublic void ic() {\n\t\t\t\t\n\t\t\t}",
"@Override\n\tprotected void initData() {\n\n\t}",
"@Override\n\tprotected void initData() {\n\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n public void init() {\n\n }",
"@Override\n\tprotected void initialize() {\n\t\t\n\t}",
"@Override\n\tprotected void initialize() {\n\t\t\n\t}",
"@Override\r\n\tpublic void init() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void init() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void init() {\n\t\t\r\n\t}",
"@Override\n\tpublic void debite() {\n\t\t\n\t}",
"@Override\r\n\tpublic void init() {\n\r\n\t}",
"@Override\r\n\tpublic void init() {\n\r\n\t}",
"@Override\r\n\tpublic void init() {\n\r\n\t}",
"public contrustor(){\r\n\t}",
"@Override\n\tprotected void initialize() {\n\n\t}",
"@Override\r\n\tpublic void dispase() {\n\r\n\t}",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"@Override\n\tpublic void dtd() {\n\t\t\n\t}",
"@Override\n\tprotected void logic() {\n\n\t}",
"@Override\n\tprotected void lazyLoad() {\n\t\t\n\t}",
"public void mo4359a() {\n }",
"@Override\r\n\tprotected void initialize() {\n\r\n\t}",
"@Override\n public void memoria() {\n \n }",
"@Override\n\t\tpublic void method() {\n\t\t\t\n\t\t}",
"private RepositorioAtendimentoPublicoHBM() {\r\t}",
"@Override\n protected void initialize() \n {\n \n }",
"@Override\r\n\tpublic void getProposition() {\n\r\n\t}",
"@Override\n\tpublic void particular1() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\n\t}",
"@Override\n\tpublic void init() {\n\n\t}",
"@Override\n\tpublic void init() {\n\n\t}",
"@Override\n protected void prot() {\n }",
"@Override\r\n\tpublic void init()\r\n\t{\n\t}",
"@Override\n\tprotected void initValue()\n\t{\n\n\t}",
"public void mo55254a() {\n }"
] | [
"0.6671074",
"0.6567672",
"0.6523024",
"0.6481211",
"0.6477082",
"0.64591026",
"0.64127725",
"0.63762105",
"0.6276059",
"0.6254286",
"0.623686",
"0.6223679",
"0.6201336",
"0.61950207",
"0.61950207",
"0.61922914",
"0.6186996",
"0.6173591",
"0.61327106",
"0.61285484",
"0.6080161",
"0.6077022",
"0.6041561",
"0.6024072",
"0.6020252",
"0.59984857",
"0.59672105",
"0.59672105",
"0.5965777",
"0.59485507",
"0.5940904",
"0.59239364",
"0.5910017",
"0.5902906",
"0.58946234",
"0.5886006",
"0.58839184",
"0.58691067",
"0.5857751",
"0.58503544",
"0.5847024",
"0.58239377",
"0.5810564",
"0.5810089",
"0.5806823",
"0.5806823",
"0.5800025",
"0.5792378",
"0.5792378",
"0.5792378",
"0.5792378",
"0.5792378",
"0.5792378",
"0.5790187",
"0.5789414",
"0.5787092",
"0.57844025",
"0.57844025",
"0.5774479",
"0.5774479",
"0.5774479",
"0.5774479",
"0.5774479",
"0.5761362",
"0.57596046",
"0.57596046",
"0.575025",
"0.575025",
"0.575025",
"0.5747959",
"0.57337177",
"0.57337177",
"0.57337177",
"0.5721452",
"0.5715831",
"0.57142824",
"0.57140535",
"0.57140535",
"0.57140535",
"0.57140535",
"0.57140535",
"0.57140535",
"0.57140535",
"0.5711723",
"0.57041645",
"0.56991017",
"0.5696783",
"0.56881124",
"0.56774884",
"0.56734604",
"0.56728",
"0.56696945",
"0.5661323",
"0.5657007",
"0.5655942",
"0.5655942",
"0.5655942",
"0.56549734",
"0.5654792",
"0.5652974",
"0.5650185"
] | 0.0 | -1 |
Return unique instance of game controller | public static synchronized TowerManager getUniqueInstance() {
if (uniqueInstance == null) {
uniqueInstance = new TowerManager();
}
return uniqueInstance;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public static GameController getInstance() {\n\t\treturn INSTANCE; \n\t}",
"public static GameController getGameController() {\n\t\treturn controller;\n\t}",
"public static Controller getInstance() { return INSTANCE; }",
"@Override\n\tpublic GameController getController() {\n\t\treturn gameController;\n\t}",
"GameController makeGameController(LobbyController lobbyController);",
"public static IControllerInfo getInstance() {\r\n\t\treturn instance;\r\n\t}",
"public GameController() {\n GameLoop.getInstance();\n }",
"public static TrainingController getInstance(){\n if( singleInstance == null )\n singleInstance = new TrainingController();\n return singleInstance;\n }",
"public static BaseStationController getController()\r\n {\r\n \treturn controller;\r\n }",
"SpawnController createSpawnController();",
"public static GameManager getInstance() {\n return ourInstance;\n }",
"public static UserController getInstance(){\n if(INSTANCE == null){\n synchronized(UserController.class){\n if(INSTANCE==null){\n INSTANCE = new UserController();\n }\n }\n }\n else\n {\n return INSTANCE; \n }\n return INSTANCE;\n }",
"public Controller getController();",
"public interface GameControllerFactory {\n\n /**\n * Creates a new game controller that will be hosted by the given lobby controller.\n */\n GameController makeGameController(LobbyController lobbyController);\n\n}",
"public static NodeController getInstance() {\r\n\t\tif (instance == null) {\r\n\t\t\tinstance = new NodeController();\r\n\t\t}\r\n\t\treturn instance;\r\n\t}",
"public static GameEngine getInstance() {\n return INSTANCE;\n }",
"public static GameClient getCurrentGame() {\n\t\treturn arcade.getCurrentGame();\n\t}",
"public static Game getInstance() {\n\t\tif (game == null)\n\t\t\tgame = new Game();\n\t\treturn game;\n\t}",
"public static GuestController getInstance() {\n if (instance == null) {\n instance = new GuestController();\n }\n return instance;\n }",
"public static SoundController getInstance() {\n\t\tif (controller == null) {\n\t\t\tcontroller = new SoundController();\n\t\t}\n\t\treturn controller;\n\t}",
"public static synchronized AppController getInstance() {\n return mInstance;\n }",
"public static ApplicationController instance() {\r\n\t\treturn controller;\r\n\t}",
"public static StatisticsController getInstanceOf() {\n\n\t\treturn (StatisticsController.singStats == null ? new StatisticsController() : StatisticsController.singStats);\n\t}",
"public SinglePlayerGameController() {\n player1 = new Player(\"Player 1\");\n computer = new Player(\"Computer\");\n game = new Game(new Dice(), player1, computer);\n player1.setColor(\"blue\");\n computer.setColor(\"red\");\n diceImage = new DiceImage();\n }",
"public static GameLoop getInstance(){\n if( networked ){\n return NetworkGameLoop.getInstance();\n }\n if(uniqueInstance == null){\n uniqueInstance = new GameLoop();\n }\n return uniqueInstance;\n }",
"String getController(String clientId);",
"private GameController() {\n\n }",
"public static NewFieldtoFieldController getInstance() {\r\n\t\treturn userHome;\r\n\t}",
"public static EventController getInstance()\n {\n if(controller == null)\n {\n controller = new EventController();\n }\n return controller;\n }",
"public static WorkerController getInstance(){\r\n\t\tWorkerController workerController = new WorkerController();\r\n\t\tworkerController.workerobj = new JSONObject();\r\n\t\treturn workerController;\r\n\t}",
"public GameController() {\n\t\t\n\t\t\n\t\tGameController.gc = this;\n\t}",
"public static CompanyController getInstance() {\n\n if (controller == null)\n initializeController();\n\n return controller;\n }",
"public static Gameplay getRunningGame() {\r\n\t\treturn Gameplay.getInstance();\r\n\t}",
"private BaseController getController()\n {\n BaseController controller = null;\n\n //check who has stared the background task\n if (tag == null) {\n //this is an instance of a normal activity starting the background\n //task, use its controller's function to execute the actual task\n //in background.\n \tif (activity != null) {\n \t\tcontroller = activity.getController();\n \t}\n }\n else {\n //this is an instance of a activity's fragment starting the backgroundH\n //task, use the fragment's controller function to execute the\n //actual task in background\n if (activity != null) {\n BaseFragment fragment = (BaseFragment) activity.getFragmentManager().findFragmentByTag(tag);\n if (fragment != null) {\n controller = fragment.getController();\n }\n }\n }\n\n return controller;\n }",
"int getIdInstance();",
"public Player getController() {\n return sourceCard.getController();\n }",
"public static Controller getInstance(Context _context) {\r\n if (sInstance == null) {\r\n sInstance = new Controller(_context);\r\n } else {\r\n \tsInstance.mContext = _context;\r\n }\r\n return sInstance;\r\n }",
"public static synchronized Player getInstance(){\n if(Player.player == null){\n Player.player = new Player();\n }\n return Player.player;\n }",
"public static Game getGame()\n\t{\n\t\tif(instance == null)\n\t\t\tinstance = new Game();\n\t\treturn instance;\n\t}",
"private PlayerController playerControllerFor(int player)\n {\n switch (player) {\n case PLAYER_1_FLAG:\n return player1;\n case PLAYER_2_FLAG:\n return player2;\n default:\n return null;\n }\n }",
"public static DataController getInstance()\n\t{\n\t\tif (single_instance == null)\n\t\t\tsingle_instance = new DataController();\n\n\t\treturn single_instance;\n\t}",
"public IController getController();",
"private void createGameController() {\n\t\tLog.i(LOG_TAG, \"createGameController\");\n\n\t\tBundle intent = this.getIntent().getExtras();\n\t\t\n\t\tthis.punchMode = intent.getString(\"punchMode\");\n\t\t\n\t\tthis.gameController = new TimeTrialGameController( this.timerTextView,\n\t\t\t\tthis.numberOfPunchesCounterTextView, this.punchMode);\n\t\t\n\t\tthis.gameController.addObserver(this);\n\t}",
"MatchController createMatchController();",
"public static synchronized ControllerHelper getControllerHelper() {\n\n if (controllerHelper == null) {\n controllerHelper = new ControllerHelper();\n }\n\n return controllerHelper;\n }",
"public Game getNewInstance() {\n try {\n return classObj.newInstance();\n } catch (Exception e) {\n e.printStackTrace();\n throw new RuntimeException(\"Error generating \" + this + \" game\");\n }\n }",
"public GameController(){\n\t\t\n\t\tupdaterRunnable = new Updater();\n\t\tgameLoopThread = new Thread(updaterRunnable);\n\t\trunning = false;\n\t\tgameFinished = false;\n\t}",
"public static GameManager getInstance() { \n \t\tif (instance == null){\n \t\t\tinstance = new GameManager (); \n \t\t}\n \t\treturn instance;\n \t}",
"public NullGameController()\r\n {\r\n }",
"public static AbstractDatabaseController getInstance(){\r\n\t\treturn AbstractDatabaseController.instance;\r\n\t}",
"public static ActionController getInstance() {\n return instance;\n }",
"public static GameWindow getGame() {\n return _gameWindow;\n }",
"public static GameBoard getInstance()\n {\n if (instance == null)\n {\n instance = new GameBoard();\n }\n return instance;\n }",
"int getInstanceId();",
"int getInstanceId();",
"int getInstanceId();",
"public Game createGame();",
"public static UtilityDatabaseController getInstance() \n {\n if(instance == null) {\n instance = new UtilityDatabaseController();\n }\n \n return instance;\n }",
"public static OOoCombinedChartController getInstance() {\n return instance;\n }",
"public static GameVariableRepository getInstance() {\r\n\t\treturn instance;\r\n\t}",
"public ChatController getBaseController()\n\t{\n\t\treturn botController;\n\t}",
"public static DbController getInstance() {\n if (dbController == null) {\n dbController = new DbController();\n }\n return dbController;\n }",
"public GameScreen newGame() {\n gameScreen = new GameScreen(this);\n return gameScreen;\n }",
"@Override\n public LocalGame createLocalGame() {\n return new LocalGameActual();\n }",
"Instance getInstance(String id);",
"private Controller() {\n\t\tthis.gui = GUI.getInstance();\n\t\tthis.gui.setController(this);\n\t}",
"public synchronized static GameManager getInstance() {\n if (null == gameManager) {\n gameManager = new GameManager();\n }\n return gameManager;\n }",
"public org.omg.uml.behavioralelements.commonbehavior.Instance getInstance();",
"public static StoreController getInstance() {\n\t\tif (storeController == null) {\n\t\t\tsynchronized (StoreController.class) {\n\t\t\t\tif (storeController == null) {\n\t\t\t\t\tstoreController = new StoreController();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\treturn storeController;\n\t}",
"public static SinglController getController(){\n if (scl==null) {\n TemperatureSensor tmpsen = new TemperatureSensor(\"Kitchen\");\n LightSensor lsen = new LightSensor (\"Kitchen\");\n scl=new SinglController(tmpsen,lsen);\n }\n return scl;\n }",
"UUID getActivePlayerId();",
"public final StandbyPriorityController getController() {\n return controller;\n }",
"public static DriveStraightController getInstance() {\n\t\tif (driveStraightControllerInstance == null)\n\t\t\tdriveStraightControllerInstance = new DriveStraightController();\n\t\treturn driveStraightControllerInstance;\n\t}",
"public static ActionController getInstance(int hard, int countRooms) {\n if (instance == null) {\n instance = new ActionController(hard, countRooms);\n }\n return instance;\n }",
"public DuxComController getController() {\n return this.controller;\n }",
"public static Game getGame() {\n return game;\n }",
"public static RCProxy instance(){\n\t\treturn SingletonHolder.INSTANCE;\n\t}",
"public static GameManager getInstance() {\n if (GameManager.instance == null) {\n GameManager.instance = new GameManager();\n }\n return GameManager.instance;\n }",
"public static Game getGame() {\r\n\t\treturn game;\r\n\t}",
"public static Main getInstance() {\r\n return instance;\r\n }",
"public static Main getInstance() {\n return instance;\n }",
"public Controller getController()\n {\n return this.controller;\n }",
"private WidgetInstanceManager get_instance(int appWidgetId) {\r\n\t\t\treturn m_Instances.get(appWidgetId);\r\n\t\t}",
"public static Game getGame() {\n\t\treturn game;\n\t}",
"public static SingletonController getController(AssetManager assetManager) {\n if(controller == null) {\n controller = new SingletonController(assetManager);\n return controller;\n }\n return controller;\n }",
"public GameController() {\r\n\t\tsuper();\r\n\t\tthis.model = Main.getModel();\r\n\t\tthis.player = this.model.getPlayer();\r\n\t\tthis.timeline = this.model.getIndefiniteTimeline();\r\n\t}",
"public static Uniqueid getInstance() {\n if (uniqueid == null) {\n uniqueid = new Uniqueid();\n }\n return uniqueid;\n }",
"private CreationViewController getCreationBrowserController(){\n\n FXMLLoader loader = new FXMLLoader(\n getClass().getResource(\"/CreationView.fxml\")\n );\n stage = new Stage(StageStyle.DECORATED);\n try {\n stage.setScene(new Scene(loader.load(), 800, 600));\n } catch (IOException e) {\n return null;\n }\n\n CreationViewController controller = loader.getController();\n builder.ConfigureUIController(controller, stage);\n return controller;\n }",
"public WizardController controller()\r\n\t{\r\n\t\treturn _controller;\r\n\t}",
"public int getControllerID() {\n\t\treturn this.controllerID;\n\t}",
"String getInstanceID();",
"public String getInstanceIdentifier();",
"public static DisplayDevice getInstance(){\t\t\r\n\t\treturn instance;\r\n\t}",
"private static native long getControllerForGamepadIndex(long pointer, int index);",
"public static BattleArena getInstance() {\n return INSTANCE;\n }",
"public static WebSocketSelectionKeyAPI getInstance ()\r\n {\r\n return theAPI;\r\n }",
"IAnjaroController getController();",
"static GuessGameManager getInstance(Activity activity) {\n if (guessGameManager == null) {\n guessGameManager = new GuessGameManager(activity, gameName);\n }\n return guessGameManager;\n }",
"public GameController(VirtualView client, int num, String gameName) {\n running = new AtomicBoolean(true);\n setup = new AtomicBoolean(true);\n playerControllers = new ArrayList<PlayerController>();\n colors = new ArrayList<String>();\n colors.add(\"r\");\n colors.add(\"g\");\n colors.add(\"b\");\n Player p1 = new Player(client.getId(), colors.get(0));\n PlayerController p1Controller = new PlayerController(p1, client, this);\n game = new Game(gameName, p1, num);\n playerControllers.add(p1Controller);\n client.setPlayerController(p1Controller);\n }",
"public GameService getGameService() {\n return gameService;\n }"
] | [
"0.7765909",
"0.7341425",
"0.6973324",
"0.66738725",
"0.65828097",
"0.65014505",
"0.64532524",
"0.6245191",
"0.621518",
"0.62125814",
"0.62057155",
"0.6112354",
"0.6110133",
"0.6084771",
"0.60722464",
"0.6072104",
"0.6068123",
"0.60578364",
"0.60532093",
"0.60436004",
"0.6040896",
"0.60389966",
"0.60243255",
"0.6003616",
"0.5988244",
"0.59773684",
"0.59728587",
"0.59394956",
"0.5929604",
"0.5902486",
"0.5890793",
"0.5884087",
"0.5883203",
"0.5878312",
"0.58157617",
"0.5806712",
"0.57706124",
"0.576925",
"0.5757495",
"0.5748272",
"0.5748156",
"0.5742844",
"0.57406986",
"0.5733515",
"0.5733448",
"0.57172024",
"0.56889164",
"0.56870294",
"0.56729805",
"0.5668285",
"0.566514",
"0.56536776",
"0.56500673",
"0.5637881",
"0.5637881",
"0.5637881",
"0.56202835",
"0.56084484",
"0.5601626",
"0.5598941",
"0.5594627",
"0.5594563",
"0.5584193",
"0.55814826",
"0.5562683",
"0.55606014",
"0.55579495",
"0.5556373",
"0.55512536",
"0.5541264",
"0.5540842",
"0.55368507",
"0.553284",
"0.5531564",
"0.5523246",
"0.5512511",
"0.55085504",
"0.5505716",
"0.54990566",
"0.54822135",
"0.547589",
"0.5467331",
"0.5458907",
"0.5446758",
"0.5438854",
"0.5434065",
"0.5433552",
"0.54203916",
"0.5419147",
"0.54144883",
"0.5409894",
"0.5406979",
"0.5405215",
"0.53837705",
"0.5382517",
"0.5380914",
"0.5380727",
"0.5373747",
"0.53737086",
"0.5367754"
] | 0.5772194 | 36 |
Add tower to ArrayList | public static void addTower(Tower t)
{
towers.add(t);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"myGame.addTower(Tower thisTower){ // adding a tower to the game\n towers.add(thisTower); // adding a tower to the set that contains all the towers\n }",
"public void add(){\n list.add(smart);\n list.add(mega);\n list.add(smartMini);\n list.add(absolute);\n\n clientsList.add(client1);\n clientsList.add(client2);\n clientsList.add(client3);\n clientsList.add(client4);\n clientsList.add(client5);\n }",
"public void setTray(ArrayList<Tile> newTray){ this.tray = newTray; }",
"private void addAttacks(){\n while(!attacksToAdd.isEmpty()){\n attacks.add(attacksToAdd.remove());\n }\n }",
"public static void putCraftableItemInArrayList() {\n\n craftableItem.addItemToCraftableList(campfire);\n craftableItem.addItemToCraftableList(raft);\n craftableItem.addItemToCraftableList(axe);\n craftableItem.addItemToCraftableList(spear);\n }",
"private void add(Tile t) {\n tileBag.add(t);\n shuffleBag();\n }",
"public void creatList()\n\t{\n\t\tbowlers.add(new Bowler(\"A\",44));\n\t\tbowlers.add(new Bowler(\"B\",25));\n\t\tbowlers.add(new Bowler(\"C\",2));\n\t\tbowlers.add(new Bowler(\"D\",10));\n\t\tbowlers.add(new Bowler(\"E\",6));\n\t}",
"private void add() {\n\n\t}",
"public void addWall(Wall w)\n {\n walls.add(w);\n }",
"public void addToList() {\n addToCurrentListButton.addActionListener(new ActionListener() {\n @Override\n public void actionPerformed(ActionEvent e) {\n //getting the variables from the user input\n String address = enterAddress.getText();\n String issue = enterAddress.getText();\n String model = enterModel.getText();\n //date method\n Date date = new Date();\n //creating a quick CentralAC list\n CentralAC acEntry = new CentralAC(address, issue, date, model);\n //adding items to the Arraylist\n HVACGUI.newCentralAC.add(acEntry);\n //adding items to the default list model\n HVACGUI.openService.addElement(acEntry);\n //disposing the form\n CentralAC_GUI.this.dispose();\n\n\n }\n });\n }",
"@FXML\n public void addTeleporter() {\n if (!World.getInstance().worldContainsTeleporterIn()) {\n \tnew eMenuHandler().hideMenu();\n \tDisplayBuildingInstructions.showBuildingInstr();\n \tAddEntityOnMouseClick.setBuildMode(Boolean.TRUE);\n \tAddEntityOnMouseClick.entityList(new BuildingTeleporterIn(0, 0));\n }\n if (!World.getInstance().worldContainsTeleporterOut()) {\n \tnew eMenuHandler().hideMenu();\n \tDisplayBuildingInstructions.showBuildingInstr();\n \tAddEntityOnMouseClick.setBuildMode(Boolean.TRUE);\n \tAddEntityOnMouseClick.entityList(new BuildingTeleporterOut(0, 0));\n \t\n }\n\n }",
"public void addHarvestContents(ArrayList ist)\r\n/* 100: */ {\r\n/* 101: 80 */ super.addHarvestContents(ist);\r\n/* 102: 81 */ ist.add(new ur(RedPowerMachine.blockFrame, 1));\r\n/* 103: */ }",
"public static void addList() {\n\t}",
"public void add(WorldObject obj) {\n\troomList.add(obj);\n}",
"protected void sendNewLayerToWatchers(Item item) {\n/* 5295 */ logger.log(Level.INFO, \"Tile at \" + this.tilex + \", \" + this.tiley + \" sending secondary\");\n/* 5296 */ for (VirtualZone vz : getWatchers()) {\n/* */ \n/* */ \n/* */ try {\n/* 5300 */ vz.justSendNewLayer(item);\n/* */ }\n/* 5302 */ catch (Exception e) {\n/* */ \n/* 5304 */ logger.log(Level.WARNING, e.getMessage(), e);\n/* */ } \n/* */ } \n/* */ }",
"private void addUpdateablesToGameLoop(){\n GameLoop.getInstance().addUpdateables(playerController.getPlayers().get(0));\n for (Enemy e : enemyController.getEnemies()){\n GameLoop.getInstance().addUpdateables(e);\n }\n\n GameLoop.getInstance().addUpdateables(foodController.getFood().get(0));\n }",
"public void add() {\n\t\t\n\t}",
"@Override\r\n\tpublic void deplacerRobot(ArrayList<Robot> listeRobot) {\n\t\t\r\n\t}",
"public Molt(){\n molt=new ArrayList<>();\n }",
"public void add(TeleportDestination warp) {\n\t\tremove(warp.getName());\n\t\tdestinations.add(warp);\n\t}",
"public void add();",
"public static ArrayList<Trainer> addTrainers() {\n System.out.println(\"\\nAdd a trainer!\");\n do {\n listOfTrainers.add(createTrainer());\n System.out.print(\"\\nWould you like to add a new trainer?(yes or no): \");\n boolean yesOrNo = yesOrNoValidation();\n if (yesOrNo) {\n } else if (!yesOrNo) {\n break;\n }\n } while (true);\n\n return listOfTrainers;\n }",
"public void add() {\n }",
"@Override\n public void add(Fish object) {\n list.add(object);//adds the Fish to the list\n Log.d(\"Adapter\",\"added\");\n }",
"@Override\n public void addMemento() {\n List<ArrayList<Die>> newMemento = new ArrayList<>();\n for(ArrayList<Die> ar : dice) {\n newMemento.add(new ArrayList<>(ar));\n }\n roundTrackMemento.push(newMemento);\n }",
"@Override\n List<SleepGameItem> eat(List<SleepGameItem> itemList) {\n List<SleepGameItem> eatenItem = new ArrayList<>();\n for (SleepGameItem item : itemList) {\n if (!(item instanceof Wolf)) {\n // check for the distance between wolf and other items\n double distance =\n Math.hypot(Math.abs(item.getX() - this.getX()), Math.abs(item.getY() - this.getY()));\n if (distance <= 50) {\n eatenItem.add(item);\n this.setX(item.getX());\n this.setY(item.getY());\n }\n }\n }\n return eatenItem;\n }",
"public void add() {\n\n }",
"@Override\n\tpublic void addObservateur(Observateur obs) {\n\t\tthis.listObservateur.add(obs);\n\t}",
"void placeTower();",
"public void addedToWorld(World w){\n PauseWorld world = (PauseWorld) w;\n world.addObject(nameLabel,this.getX(),this.getY()+itemSize/2+10);\n }",
"public AddList() {\n setTitleText(\"Add new List\");\n addButton = new JButton(\"Add\");\n addButton.addActionListener(new ActionListener() {\n @Override\n public void actionPerformed(ActionEvent actionEvent) {\n addButtonActionPerformed(actionEvent);\n }\n });\n addButton(addButton);\n }",
"@Override\n\tpublic void add() {\n\t\t\n\t}",
"public void addWerker(Worker w)\n {\n if(aantalWerkers < 5)\n {\n boolean geplaatst = false; // plaatselijke parameter die zegt of de workers al gepaatst is of niet\n for(int i=0; i<5;i++)\n {\n \n if( geplaatst == false)\n {\n if(workers[i] == null)\n {\n workers[i] = w;\n geplaatst = true;\n }\n }\n }\n aantalWerkers++;\n w.setInStructure(true);\n }\n }",
"public void add(T toy) {\n // Complete add method with proper argument and method body\n v.add(toy);\n }",
"public void listAction() {\n TextWin newWindow = new TextWin(getSelectedCell());\n WindowUtils.avoidParent(newWindow, parentFrame);\n watchers.add(newWindow);\n }",
"public static void addToWatchList(PhysicsBody body)\n {\n watchList.add(body);\n }",
"private void addElementsToPanelList(JList<String> jlist, JButton clickUpdate, JButton clickDelete,\r\n JButton clickComplete, JButton clickIncomplete,\r\n JButton clickCreate, JButton showComplete,\r\n JButton clickSave) {\r\n panelList.add(jlist);\r\n panelList.add(clickUpdate);\r\n panelList.add(clickDelete);\r\n panelList.add(clickComplete);\r\n panelList.add(clickIncomplete);\r\n panelList.add(clickCreate);\r\n panelList.add(showComplete);\r\n panelList.add(clickSave);\r\n }",
"private void addTileItemFromOther(int i) {\n ((SystemUIStat) Dependency.get(SystemUIStat.class)).handleControlCenterEvent(new QuickTilesAddedEvent(this.mOtherTiles.get(i).spec));\n this.mQSControlCustomizer.addInTileAdapter(this.mOtherTiles.get(i), true);\n this.mOtherTiles.remove(i);\n notifyItemRemoved(i);\n }",
"void initFirstTower() {\n for (int i = 0; i < numDisks; i++) {\n towers[0].push(numDisks - i + 1);\n }\n }",
"public void add(Object o){\n list.add(o);\n }",
"void addFruit(Fruit item){\n\t\tfruitList.add(item);\n\t}",
"protected void addMoveable(Movable m){\n\t\ttemp.add(m);\n\t}",
"public void cbListAddElement() {\n cbWorker.clear();\n cbWorker.add(cbJ);\n cbWorker.add(cbK);\n cbWorker.add(cbM);\n cbWorker.add(cbP);\n cbWorker.add(cbA);\n cbWorker.add(cbS);\n }",
"public void add(food entry)\n\t{\n\t\titems.add(entry);\n\t\t//updates isChanged to show changes\n\t\tisChanged = true;\n\t}",
"private void addButtonsFromList() {\n\tif (serwery.size() > 0) {\n\n\t for (InetAddress ia : serwery) {\n\t\taddHostButton(ia.getHostAddress());\n\t }\n\n\t}\n\n\tif (serwery.isEmpty()) {\t\t// jeżeli nie znaleziono żadnych serwerów [bo. np. wycięty jest ruch przez Broadcast]\n\t \n\t // dodaje tekst:\n\t TextView tv = new TextView(getApplicationContext());\n\t tv.setText(\"Nie znaleziono serwerów. Wprowadź adres IP ręcznie:\");\n\n\t // pole na ręczne wpisanie IP\n\t final EditText et = new EditText(getApplicationContext());\n\n\t // button \"POŁĄCZ\"\n\t Button btn = new Button(getApplicationContext());\n\t btn.setText(\"Połącz\");\n\t btn.setOnClickListener(new View.OnClickListener() {\n\n\t\t@Override\n\t\tpublic void onClick(View v) {\n\n\t\t IPAddressValidator validator = new IPAddressValidator();\n\n\t\t if (!validator.validate(et.getText().toString())) {\n\t\t\tAlertDialog alertDialog = new AlertDialog.Builder(RemDroidActivity.this).create();\n\t\t\talertDialog.setTitle(\"Adres IP\");\n\t\t\talertDialog.setMessage(\"Wprowadź poprawny adres IP.\");\n\t\t\talertDialog.setButton(\"OK\", new DialogInterface.OnClickListener() {\n\t\t\t public void onClick(DialogInterface dialog, int which) {\n\t\t\t }\n\t\t\t});\n\t\t\talertDialog.show();\n\t\t }\n\n\t\t else {\n\t\t\t\n\t\t\tstartSending(et.getText().toString());\n\t\t\t\n\t\t }\n\t\t \n\t\t}\n\n\t });\n\n\t ll.addView(tv);\n\t ll.addView(et);\n\t ll.addView(btn);\n\t}\n\n }",
"public void addClickables() {\n\t\tclickable.add(button1.getBounds());\n\t\tbehaviors.put(clickable.get(0), () -> hideEscapeScreen());\n\t\tclickable.add(button3.getBounds());\n\t\tbehaviors.put(clickable.get(1), () -> Driver.getInstance().switchToScreen(new FFWorldMap()));\n\t\tclickable.add(button4.getBounds());\n\t\tbehaviors.put(clickable.get(2), () -> Driver.getInstance().switchToScreen(new FFMainMenu()));\n\t}",
"public void addMonster(Dragon mon){\n dragons.add(mon);\n }",
"public void autoAdd()\n {\n switch (this.getGameType())\n {\n case 1:\n for(int i = 0; i < this.participantNum; i++)\n {\n games.get(count - 1).addParticipant(swimmers.get(i).getId(),swimmers.get(i).compete(),swimmers.get(i).getPoints());\n }\n break;\n case 2:\n for(int i = 0; i < this.participantNum; i++)\n {\n games.get(count - 1).addParticipant(runners.get(i).getId(),runners.get(i).compete(),runners.get(i).getPoints());\n }\n break;\n case 3:\n for(int i = 0; i < this.participantNum; i++)\n {\n games.get(count - 1).addParticipant(cyclists.get(i).getId(),cyclists.get(i).compete(),cyclists.get(i).getPoints());\n }\n break;\n }\n\n }",
"public void addWrestler(Wrestler w) {\r\n\t\tboolean s = false;\r\n\t\tif (teamList == null) {\r\n\t\t\tteamList = new ListNode(w, null);\r\n\t\t\ts = true;\r\n\t\t}\r\n\t\telse if(w.getWeight() < ((Wrestler) teamList.getValue()).getWeight()) {\r\n\t\t\tListNode a = new ListNode(w , teamList);\r\n\t\t\tteamList = a;\r\n\t\t\ts = true;\r\n\t\t}\r\n\t\telse {\r\n\t\t\tListNode over;\r\n\t\t\tListNode initial = teamList;\r\n\t\t\tListNode t = teamList;\r\n\t\t\twhile (t.getNext() != null) {\r\n\t\t\t\tt = teamList.getNext();\r\n\t\t\t\tif (((Wrestler) t.getValue()).getWeight() > w.getWeight()) {\r\n\t\t\t\t\tover = t;\r\n\t\t\t\t\twhile (!initial.getNext().equals(over))\r\n\t\t\t\t\t\tinitial = initial.getNext();\r\n\t\t\t\t\tinitial.setNext(new ListNode(w, initial.getNext()));\r\n\t\t\t\t\ts = true;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t\tif (!s) {\r\n\t\t\tListNode t = teamList;\r\n\t\t\twhile (t.getNext() != null) {\r\n\t\t\t\tt = teamList.getNext();\r\n\t\t\t}\r\n\t\t\tt.setNext(new ListNode(w, null));\r\n\t\t}\r\n\t}",
"public void addWarp(OwnedWarp warp) {\n String player = warp.getOwner();\n List<OwnedWarp> plWarps = warps.get(player);\n if(plWarps == null) {\n plWarps = new ArrayList<OwnedWarp>();\n warps.put(player, plWarps);\n }\n plWarps.add(warp);\n }",
"public void add(Task task){ this.tasks.add(task);}",
"public void addComponents()\r\n\t{\n\t\tSteveTechFarming.fruit = new BlockFruit(SteveTechFarming.config.getBlockID(1202, \"Fruit\", null)).setBlockName(\"WiduX-SteveTech-Farm-Fruit\");\r\n\t\tSteveTechFarming.crops = new BlockCrops(SteveTechFarming.config.getBlockID(1203, \"Crops\", null)).setBlockName(\"WiduX-SteveTech-Farm-Crops\");\r\n\t\t\r\n\t\tSteveTechFarming.seeds = new ItemSeeds(SteveTechFarming.config.getItemID(11000, \"Seeds\", null)).setItemName(\"WiduX-SteveTech-Farm-Seeds\");\r\n\t\tSteveTechFarming.harvestedItems = new ItemHarvest(SteveTechFarming.config.getItemID(11002, \"Harvest\", null)).setItemName(\"WiduX-SteveTech-Farm-Harvest\");\r\n\t\tSteveTechFarming.creativeTools = new ItemCreativeTools(SteveTechFarming.config.getItemID(11001, \"Creative Tools\", null)).setItemName(\"WiduX-SteveTech-Farm-CTools\");\r\n\t\tSteveTechFarming.foods = new Item[EnumFood.getNumberFoods()];\r\n\t\tint firstFoodItemID = SteveTechFarming.config.getItemID(11003, \"Foods Array\", \"This is the first item ID in the list of foods. Item IDs used will start here, and use the next \" + EnumFood.getNumberFoods() + \" IDs. Make sure they are all available.\");\r\n\t\tfor(int idOffset = 0; idOffset < SteveTechFarming.foods.length; idOffset++)\r\n\t\t{\r\n\t\t\tEnumFood food = EnumFood.getFood(idOffset);\r\n\t\t\tSteveTechFarming.foods[idOffset] = new ItemSTFood(firstFoodItemID + idOffset, food).setItemName(\"WiduX-SteveTech-Farm-Foods-Food\" + idOffset);\r\n\t\t}\r\n\t}",
"private void buildShipsList() {\r\n ObservableList<ShipBar> lstShips = FXCollections.observableArrayList();\r\n Map<String, ShipType> ships = Data.SHIPS.get();\r\n for (String s : planet.getShips()) {\r\n ShipType ship = ships.get(s);\r\n ShipBar u = new ShipBar();\r\n u.setKey(s);\r\n u.setText(ship.getName());\r\n u.setPrice(ship.getPrice() - currentShip.getNetWorth());\r\n u.setToggleGroup(shipGroup);\r\n lstShips.add(u);\r\n }\r\n buyShips.setItems(lstShips);\r\n }",
"public TempList<T> add(T elem) {\n chk();\n list.add(elem);\n return this;\n }",
"public void legs(ArrayList<Flight> legs)\n {\n \tthis.mLegs=legs;\n }",
"void addItem (Item toAdd){\n\t\t\tthis.items.add(toAdd);}",
"@Override\n public void update(GameContainer gc, StateBasedGame stateBasedGame, int delta) throws SlickException {\n timeSinceStart += delta;\n rtimeSinceStart += delta;\n Input input = gc.getInput();\n int mouseX = input.getMouseX();\n int mouseY = input.getMouseY();\n\n\n basicbulletSheet.rotate(90f);\n basicbulletSheet.setCenterOfRotation(16, 16);\n\n // Move this bullet\n for (int i = 0; i < bulletList.size(); i++) {\n bullet = bulletList.get(i);\n bullet.move();\n }\n\n //Add this tower to the this towerList\n if (Tower.isBasicPlaced()) {\n basicTowers.add(new BasicTower());\n System.out.println(basicTowers);\n Tower.setBasicPlaced(false);\n }\n\n //Add this tower to the this towerList\n if (Tower.isBomberPlaced()) {\n bomberTowers.add(new BomberTower());\n System.out.println(bomberTowers);\n Tower.setBomberPlaced(false);\n }\n\n //Add this tower to the this towerList\n if (Tower.isSniperPlaced()) {\n sniperTowers.add(new SniperTower());\n System.out.println(sniperTowers);\n Tower.setSniperPlaced(false);\n }\n\n //Add this tower to the this towerList\n if (Tower.isQuickPlaced()) {\n quickTowers.add(new QuickTower());\n System.out.println(quickTowers);\n Tower.setQuickPlaced(false);\n }\n\n //For this tower, calculate how often this tower will shoot bullets\n for (BasicTower basicTower1 : basicTowers) {\n for (Enemy enemy : enemies) {\n enemy.Playrect = new Circle(enemy.getStartPosX() * w + r,\n enemy.getStartPosY() * w + r, 10);\n if (rtimeSinceStart > basicTower1.rcoolDown + basicTower1.rlastShot) {\n if (enemy.Playrect.intersects(basicTower1.Radius)) {\n basicTower1.basicClicked.setRotation((float) getTargetAngle(basicTower1.towerX,\n basicTower1.towerY, enemy.getStartPosX(), enemy.getStartPosY()));\n basicTower1.basicClicked.setCenterOfRotation(32, 32);\n basicTower1.rlastShot = rtimeSinceStart;\n }\n }\n if (timeSinceStart > basicTower1.coolDown + basicTower1.lastShot) {\n if (enemy.Playrect.intersects(basicTower1.Radius)) {\n addNewBullet2(basicTower1.towerX, basicTower1.towerY, enemy.getStartPosX(),\n enemy.getStartPosY(), 10);\n basicTower1.lastShot = timeSinceStart;\n }\n\n }\n }\n }\n\n //For this tower, calculate how often this tower will shoot bullets\n for (BomberTower bomberTower1 : bomberTowers) {\n for (Enemy enemy : enemies) {\n enemy.Playrect = new Circle(enemy.getStartPosX() * w + r,\n enemy.getStartPosY() * w + r, 10);\n if (rtimeSinceStart > bomberTower1.rcoolDown + bomberTower1.rlastShot) {\n if (enemy.Playrect.intersects(bomberTower1.Radius)) {\n bomberTower1.bomberClicked.setRotation((float) getTargetAngle(bomberTower1.bombertowerX,\n bomberTower1.bombertowerY, enemy.getStartPosX(), enemy.getStartPosY()));\n bomberTower1.bomberClicked.setCenterOfRotation(32, 32);\n bomberTower1.rlastShot = rtimeSinceStart;\n }\n }\n if (timeSinceStart > bomberTower1.coolDown + bomberTower1.lastShot) {\n if (enemy.Playrect.intersects(bomberTower1.Radius)) {\n addNewBullet2(bomberTower1.bombertowerX, bomberTower1.bombertowerY, enemy.getStartPosX(),\n enemy.getStartPosY(), 10);\n bomberTower1.lastShot = timeSinceStart;\n }\n }\n }\n }\n //For this tower, calculate how often this tower will shoot bullets\n for (SniperTower sniperTower1 : sniperTowers) {\n for (Enemy enemy : enemies) {\n enemy.Playrect = new Circle(enemy.getStartPosX() * w + r,\n enemy.getStartPosY() * w + r, 10);\n\n if (rtimeSinceStart > sniperTower1.rcoolDown + sniperTower1.rlastShot) {\n if (enemy.Playrect.intersects(sniperTower1.Radius)) {\n sniperTower1.sniperClicked.setRotation((float) getTargetAngle(sniperTower1.towerX,\n sniperTower1.towerY, enemy.getStartPosX(), enemy.getStartPosY()));\n sniperTower1.sniperClicked.setCenterOfRotation(32, 32);\n sniperTower1.rlastShot = rtimeSinceStart;\n }\n }\n\n if (timeSinceStart > sniperTower1.coolDown + sniperTower1.lastShot) {\n if (enemy.Playrect.intersects(sniperTower1.Radius)) {\n addNewBullet2(sniperTower1.towerX, sniperTower1.towerY, enemy.getStartPosX(),\n enemy.getStartPosY(), 50);\n sniperTower1.lastShot = timeSinceStart;\n }\n\n }\n }\n }\n //For this tower, calculate how often this tower will shoot bullets\n for (QuickTower quickTower1 : quickTowers) {\n for (Enemy enemy : enemies) {\n enemy.Playrect = new Circle(enemy.getStartPosX() * w + r,\n enemy.getStartPosY() * w + r, 10);\n\n if (rtimeSinceStart > quickTower1.rcoolDown + quickTower1.rlastShot) {\n if (enemy.Playrect.intersects(quickTower1.Radius)) {\n quickTower1.quickClicked.setRotation((float) getTargetAngle(quickTower1.towerX,\n quickTower1.towerY, enemy.getStartPosX(), enemy.getStartPosY()));\n quickTower1.quickClicked.setCenterOfRotation(32, 32);\n quickTower1.rlastShot = rtimeSinceStart;\n }\n }\n\n\n if (timeSinceStart > quickTower1.coolDown + quickTower1.lastShot) {\n if (enemy.Playrect.intersects(quickTower1.Radius)) {\n radiusVisited = true;\n addNewBullet2(quickTower1.towerX, quickTower1.towerY, enemy.getStartPosX(),\n enemy.getStartPosY(), 5);\n quickTower1.lastShot = timeSinceStart;\n }\n }\n\n }\n }\n\n //A spawn is in progress\n if (spawninProgress) {\n timePassedEnemy += delta;\n if (timePassedEnemy > 800) {\n enemies.add(new Enemy());\n enemySpawns++;\n timePassedEnemy = 0;\n }\n }\n //When enough enemies has spawned, stop the spawninProgress\n if (enemySpawns == enemyCounter) {\n spawninProgress = false;\n //hasbeenDead = false;\n enemySpawns = 0;\n enemyCounter++;\n }\n\n //When no more enemies on maps\n if (enemies.size() == 0) {\n waveinProgress = false;\n startWaveCount = 0;\n }\n\n //Start a new level when there's no more enemies on the map\n if (loadMap.MAP[mouseY / w][mouseX / w] == 16) {\n if (input.isMousePressed(0) && startWaveCount == 0 && !waveinProgress) {\n startWaveCount++;\n if (startWaveCount == 1 && enemies.size() == 0 && !waveinProgress) {\n waveinProgress = true;\n gc.resume();\n spawninProgress = true;\n currentLevel++;\n }\n }\n }\n\n //For each new level, increase the HP of each enemy\n if (currentLevel < currentLevel + 1 && !waveinProgress) {\n for (Enemy enemyHP : enemies) {\n if (enemyHP.getStartPosX() <= 0 && enemyHP.getHP() < enemyHP.startHP + currentLevel) {\n enemyHP.setHP(enemyHP.getHP() + currentLevel);\n }\n }\n }\n\n\n //For each enemies, if enemies has finished their way, decrease player HP\n //and set them inactive\n for (Enemy enemyList : enemies) {\n if (enemyList.counter >= enemyList.path.getLength() - 1) {\n player.decreaseLife();\n bulletCount = 0;\n enemyList.isActive = false;\n }\n\n //If enemies' hp is zero, set them inactive and remove from the list\n if (enemyList.getHP() <= 0) {\n enemyList.isActive = false;\n bulletCount = 0;\n player.addCredits(20);\n }\n enemyList.update(gc, stateBasedGame, delta);\n }\n for (int i = 0; i < enemies.size(); i++) {\n if (!enemies.get(i).isActive) {\n enemies.remove(enemies.get(i));\n }\n }\n\n //For all objects, update\n for (GameObject obj : objects)\n try {\n obj.update(gc, stateBasedGame, delta);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n\n //Go to Menu\n if (gc.getInput().isKeyPressed(Input.KEY_ESCAPE)) {\n gc.getInput().clearKeyPressedRecord();\n stateBasedGame.enterState(2);\n }\n\n\n }",
"public void addCommandMutable(ListItem task) {\n this.listItems.add(task);\n }",
"@Override\r\n\tpublic void addMe() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void add(T element) {\n\t\tthis._list.add(element);\r\n\t}",
"public void addIngredientRecipe(ArrayList<IngredientRecipePOJO> ingr);",
"protected void addTestToList(Object... itemsToAdd) {\n \t\n \tTestClassListModel currentListModel = (TestClassListModel) DragAndDropDestination.getModel();\n \t\n \tboolean testWasAdded = false;\n \t\n \tfor (Object itemToAdd : itemsToAdd) {\n \t\t\n\t \tif (itemToAdd instanceof String) {\n\t \t\t\n\t \t\tString currentItem = (String) itemToAdd;\n\t \t\t\n\t \t\tif (testInstantiator.isDynamic(currentItem)) {\n\t \t\t\t\n\t \t\t\tSystem.out.print(currentItem);\n\t \t\t\t\n\t \t\t\tcurrentListModel.addTest(\n\t \t\t\t\ttestInstantiator.instanceByName(\n\t \t\t\t\t\tcurrentItem, GroupOfTests.class\n\t \t\t\t\t)\n\t \t\t\t);\n\t \t\t\ttestWasAdded = true;\n\t \t\t} else {\n\t\t \t\tClass<?> itemToAddClass = testInstantiator.forName((String) itemToAdd);\n\t\t \t\tcurrentListModel.addTest(itemToAddClass);\n\t\t \t\ttestWasAdded = true;\n\t \t\t}\n\t \t}\n\t\n\t \tif (\n\t \t\t\t// Make sure it is a Class object, before casting it in one of \n\t \t\t\t// the next two tests\n\t \t\t\t//\n\t \t\t\t(itemToAdd instanceof Class) \n\t \t\t\t&& (\n\t \t\t\t\t// Test, if itemToAdd is a class which is a testcase or a\n\t \t\t\t\t// GroupOfTests.\n\t \t\t\t\t//\n\t \t\t\t\t(EnsTestCase.class.isAssignableFrom((Class) itemToAdd))\n\t \t\t\t || \n\t \t\t\t (GroupOfTests.class.isAssignableFrom((Class) itemToAdd))\n\t \t\t\t)\n\t \t) {\n\t \t\tcurrentListModel.addTest((Class) itemToAdd);\n\t \t\ttestWasAdded = true;\n\t \t\t//DragAndDropDestination.revalidate();\n\t \t}\n \t}\n\n \tif (testWasAdded) {\n\n \t\t// If something was added, repaint the list.\n\n\t // The next two lines should not be done like this. It should be \n\t // possible to just run this to make the changes in the JList take \n\t // effect. Unfortunately this does not happen.\n\t // \n\t //DragAndDropDestination.repaint();\n\t\n\t TestClassListModel newListModel = new TestClassListModel(currentListModel.getGroupOfTests()); \n\t DragAndDropDestination.setModel(newListModel);\n\t \n \t} else {\n \t\t\n \t\t// If nothing was added, an exception is thrown.\n \t\t//\n \t\tthrow new RuntimeException(\"Couldn't add any of the objects \"+ itemsToAdd.toString() +\" to the list of tests to be run!\");\n \t\t\n \t}\n }",
"public void addDrone()\r\n {\r\n if (droneTimer==0)\r\n {\r\n getWorld().addObject(new Drone(),(int)(Math.random()*(getWorld().getWidth()-50)+25),0);\r\n droneTimer =droneDelay;\r\n getWorld().addObject(new LightGunship(),(int)(Math.random()*(getWorld().getWidth()-50)+25),0);\r\n getWorld().addObject(new HeavyGunship(),(int)(Math.random()*(getWorld().getWidth()-50)+25),0);\r\n if(droneDelay >3)\r\n {\r\n droneDelay-=2;\r\n }\r\n }\r\n }",
"private void addSpawnsToList()\n\t{\n\t\tSPAWNS.put(1, new ESSpawn(1, GraciaSeeds.DESTRUCTION, new Location(-245790,220320,-12104), new int[]{TEMPORARY_TELEPORTER}));\n\t\tSPAWNS.put(2, new ESSpawn(2, GraciaSeeds.DESTRUCTION, new Location(-249770,207300,-11952), new int[]{TEMPORARY_TELEPORTER}));\n\t\t//Energy Seeds\n\t\tSPAWNS.put(3, new ESSpawn(3, GraciaSeeds.DESTRUCTION, new Location(-248360,219272,-12448), new int[]{ENERGY_SEED_WATER,ENERGY_SEED_FIRE,ENERGY_SEED_WIND}));\n\t\tSPAWNS.put(4, new ESSpawn(4, GraciaSeeds.DESTRUCTION, new Location(-249448,219256,-12448), new int[]{ENERGY_SEED_WATER,ENERGY_SEED_FIRE,ENERGY_SEED_WIND}));\n\t\tSPAWNS.put(5, new ESSpawn(5, GraciaSeeds.DESTRUCTION, new Location(-249432,220872,-12448), new int[]{ENERGY_SEED_WATER,ENERGY_SEED_FIRE,ENERGY_SEED_WIND}));\n\t\tSPAWNS.put(6, new ESSpawn(6, GraciaSeeds.DESTRUCTION, new Location(-248360,220888,-12448), new int[]{ENERGY_SEED_WATER,ENERGY_SEED_FIRE,ENERGY_SEED_WIND}));\n\t\tSPAWNS.put(7, new ESSpawn(7, GraciaSeeds.DESTRUCTION, new Location(-250088,219256,-12448), new int[]{ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY}));\n\t\tSPAWNS.put(8, new ESSpawn(8, GraciaSeeds.DESTRUCTION, new Location(-250600,219272,-12448), new int[]{ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY}));\n\t\tSPAWNS.put(9, new ESSpawn(9, GraciaSeeds.DESTRUCTION, new Location(-250584,220904,-12448), new int[]{ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY}));\n\t\tSPAWNS.put(10, new ESSpawn(10, GraciaSeeds.DESTRUCTION, new Location(-250072,220888,-12448), new int[]{ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY}));\n\t\tSPAWNS.put(11, new ESSpawn(11, GraciaSeeds.DESTRUCTION, new Location(-253096,217704,-12296), new int[]{ENERGY_SEED_DARKNESS,ENERGY_SEED_WATER}));\n\t\tSPAWNS.put(12, new ESSpawn(12, GraciaSeeds.DESTRUCTION, new Location(-253112,217048,-12288), new int[]{ENERGY_SEED_DARKNESS,ENERGY_SEED_WATER}));\n\t\tSPAWNS.put(13, new ESSpawn(13, GraciaSeeds.DESTRUCTION, new Location(-251448,217032,-12288), new int[]{ENERGY_SEED_DARKNESS,ENERGY_SEED_WATER}));\n\t\tSPAWNS.put(14, new ESSpawn(14, GraciaSeeds.DESTRUCTION, new Location(-251416,217672,-12296), new int[]{ENERGY_SEED_DARKNESS,ENERGY_SEED_WATER}));\n\t\tSPAWNS.put(15, new ESSpawn(15, GraciaSeeds.DESTRUCTION, new Location(-251416,217672,-12296), new int[]{ENERGY_SEED_FIRE,ENERGY_SEED_WIND}));\n\t\tSPAWNS.put(16, new ESSpawn(16, GraciaSeeds.DESTRUCTION, new Location(-251416,217016,-12280), new int[]{ENERGY_SEED_FIRE,ENERGY_SEED_WIND}));\n\t\tSPAWNS.put(17, new ESSpawn(17, GraciaSeeds.DESTRUCTION, new Location(-249752,217016,-12280), new int[]{ENERGY_SEED_FIRE,ENERGY_SEED_WIND}));\n\t\tSPAWNS.put(18, new ESSpawn(18, GraciaSeeds.DESTRUCTION, new Location(-249736,217688,-12296), new int[]{ENERGY_SEED_FIRE,ENERGY_SEED_WIND}));\n\t\tSPAWNS.put(19, new ESSpawn(19, GraciaSeeds.DESTRUCTION, new Location(-252472,215208,-12120), new int[]{ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY}));\n\t\tSPAWNS.put(20, new ESSpawn(20, GraciaSeeds.DESTRUCTION, new Location(-252552,216760,-12248), new int[]{ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY}));\n\t\tSPAWNS.put(21, new ESSpawn(21, GraciaSeeds.DESTRUCTION, new Location(-253160,216744,-12248), new int[]{ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY}));\n\t\tSPAWNS.put(22, new ESSpawn(22, GraciaSeeds.DESTRUCTION, new Location(-253128,215160,-12096), new int[]{ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY}));\n\t\tSPAWNS.put(23, new ESSpawn(23, GraciaSeeds.DESTRUCTION, new Location(-250392,215208,-12120), new int[]{ENERGY_SEED_DARKNESS,ENERGY_SEED_WATER}));\n\t\tSPAWNS.put(24, new ESSpawn(24, GraciaSeeds.DESTRUCTION, new Location(-250264,216744,-12248), new int[]{ENERGY_SEED_DARKNESS,ENERGY_SEED_WATER}));\n\t\tSPAWNS.put(25, new ESSpawn(25, GraciaSeeds.DESTRUCTION, new Location(-249720,216744,-12248), new int[]{ENERGY_SEED_DARKNESS,ENERGY_SEED_WATER}));\n\t\tSPAWNS.put(26, new ESSpawn(26, GraciaSeeds.DESTRUCTION, new Location(-249752,215128,-12096), new int[]{ENERGY_SEED_DARKNESS,ENERGY_SEED_WATER}));\n\t\tSPAWNS.put(27, new ESSpawn(27, GraciaSeeds.DESTRUCTION, new Location(-250280,216760,-12248), new int[]{ENERGY_SEED_FIRE,ENERGY_SEED_WIND,ENERGY_SEED_EARTH}));\n\t\tSPAWNS.put(28, new ESSpawn(28, GraciaSeeds.DESTRUCTION, new Location(-250344,216152,-12248), new int[]{ENERGY_SEED_FIRE,ENERGY_SEED_WIND,ENERGY_SEED_EARTH}));\n\t\tSPAWNS.put(29, new ESSpawn(29, GraciaSeeds.DESTRUCTION, new Location(-252504,216152,-12248), new int[]{ENERGY_SEED_FIRE,ENERGY_SEED_WIND,ENERGY_SEED_EARTH}));\n\t\tSPAWNS.put(30, new ESSpawn(30, GraciaSeeds.DESTRUCTION, new Location(-252520,216792,-12248), new int[]{ENERGY_SEED_FIRE,ENERGY_SEED_WIND,ENERGY_SEED_EARTH}));\n\t\tSPAWNS.put(31, new ESSpawn(31, GraciaSeeds.DESTRUCTION, new Location(-242520,217272,-12384), new int[]{ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY,ENERGY_SEED_DARKNESS}));\n\t\tSPAWNS.put(32, new ESSpawn(32, GraciaSeeds.DESTRUCTION, new Location(-241432,217288,-12384), new int[]{ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY,ENERGY_SEED_DARKNESS}));\n\t\tSPAWNS.put(33, new ESSpawn(33, GraciaSeeds.DESTRUCTION, new Location(-241432,218936,-12384), new int[]{ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY,ENERGY_SEED_DARKNESS}));\n\t\tSPAWNS.put(34, new ESSpawn(34, GraciaSeeds.DESTRUCTION, new Location(-242536,218936,-12384), new int[]{ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY,ENERGY_SEED_DARKNESS}));\n\t\tSPAWNS.put(35, new ESSpawn(35, GraciaSeeds.DESTRUCTION, new Location(-240808,217272,-12384), new int[]{ENERGY_SEED_WATER,ENERGY_SEED_FIRE}));\n\t\tSPAWNS.put(36, new ESSpawn(36, GraciaSeeds.DESTRUCTION, new Location(-240280,217272,-12384), new int[]{ENERGY_SEED_WATER,ENERGY_SEED_FIRE}));\n\t\tSPAWNS.put(37, new ESSpawn(37, GraciaSeeds.DESTRUCTION, new Location(-240280,218952,-12384), new int[]{ENERGY_SEED_WATER,ENERGY_SEED_FIRE}));\n\t\tSPAWNS.put(38, new ESSpawn(38, GraciaSeeds.DESTRUCTION, new Location(-240792,218936,-12384), new int[]{ENERGY_SEED_WATER,ENERGY_SEED_FIRE}));\n\t\tSPAWNS.put(39, new ESSpawn(39, GraciaSeeds.DESTRUCTION, new Location(-239576,217240,-12640), new int[]{ENERGY_SEED_WIND,ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY}));\n\t\tSPAWNS.put(40, new ESSpawn(40, GraciaSeeds.DESTRUCTION, new Location(-239560,216168,-12640), new int[]{ENERGY_SEED_WIND,ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY}));\n\t\tSPAWNS.put(41, new ESSpawn(41, GraciaSeeds.DESTRUCTION, new Location(-237896,216152,-12640), new int[]{ENERGY_SEED_WIND,ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY}));\n\t\tSPAWNS.put(42, new ESSpawn(42, GraciaSeeds.DESTRUCTION, new Location(-237912,217256,-12640), new int[]{ENERGY_SEED_WIND,ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY}));\n\t\tSPAWNS.put(43, new ESSpawn(43, GraciaSeeds.DESTRUCTION, new Location(-237896,215528,-12640), new int[]{ENERGY_SEED_DARKNESS,ENERGY_SEED_WATER}));\n\t\tSPAWNS.put(44, new ESSpawn(44, GraciaSeeds.DESTRUCTION, new Location(-239560,215528,-12640), new int[]{ENERGY_SEED_DARKNESS,ENERGY_SEED_WATER}));\n\t\tSPAWNS.put(45, new ESSpawn(45, GraciaSeeds.DESTRUCTION, new Location(-239560,214984,-12640), new int[]{ENERGY_SEED_DARKNESS,ENERGY_SEED_WATER}));\n\t\tSPAWNS.put(46, new ESSpawn(46, GraciaSeeds.DESTRUCTION, new Location(-237896,215000,-12640), new int[]{ENERGY_SEED_DARKNESS,ENERGY_SEED_WATER}));\n\t\tSPAWNS.put(47, new ESSpawn(47, GraciaSeeds.DESTRUCTION, new Location(-237896,213640,-12768), new int[]{ENERGY_SEED_WATER,ENERGY_SEED_FIRE,ENERGY_SEED_WIND}));\n\t\tSPAWNS.put(48, new ESSpawn(48, GraciaSeeds.DESTRUCTION, new Location(-239560,213640,-12768), new int[]{ENERGY_SEED_WATER,ENERGY_SEED_FIRE,ENERGY_SEED_WIND}));\n\t\tSPAWNS.put(49, new ESSpawn(49, GraciaSeeds.DESTRUCTION, new Location(-239544,212552,-12768), new int[]{ENERGY_SEED_WATER,ENERGY_SEED_FIRE,ENERGY_SEED_WIND}));\n\t\tSPAWNS.put(50, new ESSpawn(50, GraciaSeeds.DESTRUCTION, new Location(-237912,212552,-12768), new int[]{ENERGY_SEED_WATER,ENERGY_SEED_FIRE,ENERGY_SEED_WIND}));\n\t\tSPAWNS.put(51, new ESSpawn(51, GraciaSeeds.DESTRUCTION, new Location(-237912,211912,-12768), new int[]{ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY}));\n\t\tSPAWNS.put(52, new ESSpawn(52, GraciaSeeds.DESTRUCTION, new Location(-237912,211400,-12768), new int[]{ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY}));\n\t\tSPAWNS.put(53, new ESSpawn(53, GraciaSeeds.DESTRUCTION, new Location(-239560,211400,-12768), new int[]{ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY}));\n\t\tSPAWNS.put(54, new ESSpawn(54, GraciaSeeds.DESTRUCTION, new Location(-239560,211912,-12768), new int[]{ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY}));\n\t\tSPAWNS.put(55, new ESSpawn(55, GraciaSeeds.DESTRUCTION, new Location(-241960,214536,-12512), new int[]{ENERGY_SEED_DARKNESS,ENERGY_SEED_WATER,ENERGY_SEED_FIRE}));\n\t\tSPAWNS.put(56, new ESSpawn(56, GraciaSeeds.DESTRUCTION, new Location(-241976,213448,-12512), new int[]{ENERGY_SEED_DARKNESS,ENERGY_SEED_WATER,ENERGY_SEED_FIRE}));\n\t\tSPAWNS.put(57, new ESSpawn(57, GraciaSeeds.DESTRUCTION, new Location(-243624,213448,-12512), new int[]{ENERGY_SEED_DARKNESS,ENERGY_SEED_WATER,ENERGY_SEED_FIRE}));\n\t\tSPAWNS.put(58, new ESSpawn(58, GraciaSeeds.DESTRUCTION, new Location(-243624,214520,-12512), new int[]{ENERGY_SEED_DARKNESS,ENERGY_SEED_WATER,ENERGY_SEED_FIRE}));\n\t\tSPAWNS.put(59, new ESSpawn(59, GraciaSeeds.DESTRUCTION, new Location(-241976,212808,-12504), new int[]{ENERGY_SEED_WIND,ENERGY_SEED_EARTH}));\n\t\tSPAWNS.put(60, new ESSpawn(60, GraciaSeeds.DESTRUCTION, new Location(-241960,212280,-12504), new int[]{ENERGY_SEED_WIND,ENERGY_SEED_EARTH}));\n\t\tSPAWNS.put(61, new ESSpawn(61, GraciaSeeds.DESTRUCTION, new Location(-243624,212264,-12504), new int[]{ENERGY_SEED_WIND,ENERGY_SEED_EARTH}));\n\t\tSPAWNS.put(62, new ESSpawn(62, GraciaSeeds.DESTRUCTION, new Location(-243624,212792,-12504), new int[]{ENERGY_SEED_WIND,ENERGY_SEED_EARTH}));\n\t\tSPAWNS.put(63, new ESSpawn(63, GraciaSeeds.DESTRUCTION, new Location(-243640,210920,-12640), new int[]{ENERGY_SEED_DIVINITY,ENERGY_SEED_DARKNESS,ENERGY_SEED_WATER}));\n\t\tSPAWNS.put(64, new ESSpawn(64, GraciaSeeds.DESTRUCTION, new Location(-243624,209832,-12640), new int[]{ENERGY_SEED_DIVINITY,ENERGY_SEED_DARKNESS,ENERGY_SEED_WATER}));\n\t\tSPAWNS.put(65, new ESSpawn(65, GraciaSeeds.DESTRUCTION, new Location(-241976,209832,-12640), new int[]{ENERGY_SEED_DIVINITY,ENERGY_SEED_DARKNESS,ENERGY_SEED_WATER}));\n\t\tSPAWNS.put(66, new ESSpawn(66, GraciaSeeds.DESTRUCTION, new Location(-241976,210920,-12640), new int[]{ENERGY_SEED_DIVINITY,ENERGY_SEED_DARKNESS,ENERGY_SEED_WATER}));\n\t\tSPAWNS.put(67, new ESSpawn(67, GraciaSeeds.DESTRUCTION, new Location(-241976,209192,-12640), new int[]{ENERGY_SEED_FIRE,ENERGY_SEED_WIND}));\n\t\tSPAWNS.put(68, new ESSpawn(68, GraciaSeeds.DESTRUCTION, new Location(-241976,208664,-12640), new int[]{ENERGY_SEED_FIRE,ENERGY_SEED_WIND}));\n\t\tSPAWNS.put(69, new ESSpawn(69, GraciaSeeds.DESTRUCTION, new Location(-243624,208664,-12640), new int[]{ENERGY_SEED_FIRE,ENERGY_SEED_WIND}));\n\t\tSPAWNS.put(70, new ESSpawn(70, GraciaSeeds.DESTRUCTION, new Location(-243624,209192,-12640), new int[]{ENERGY_SEED_FIRE,ENERGY_SEED_WIND}));\n\t\tSPAWNS.put(71, new ESSpawn(71, GraciaSeeds.DESTRUCTION, new Location(-241256,208664,-12896), new int[]{ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY,ENERGY_SEED_DARKNESS}));\n\t\tSPAWNS.put(72, new ESSpawn(72, GraciaSeeds.DESTRUCTION, new Location(-240168,208648,-12896), new int[]{ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY,ENERGY_SEED_DARKNESS}));\n\t\tSPAWNS.put(73, new ESSpawn(73, GraciaSeeds.DESTRUCTION, new Location(-240168,207000,-12896), new int[]{ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY,ENERGY_SEED_DARKNESS}));\n\t\tSPAWNS.put(74, new ESSpawn(74, GraciaSeeds.DESTRUCTION, new Location(-241256,207000,-12896), new int[]{ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY,ENERGY_SEED_DARKNESS}));\n\t\tSPAWNS.put(75, new ESSpawn(75, GraciaSeeds.DESTRUCTION, new Location(-239528,208648,-12896), new int[]{ENERGY_SEED_WATER,ENERGY_SEED_FIRE}));\n\t\tSPAWNS.put(76, new ESSpawn(76, GraciaSeeds.DESTRUCTION, new Location(-238984,208664,-12896), new int[]{ENERGY_SEED_WATER,ENERGY_SEED_FIRE}));\n\t\tSPAWNS.put(77, new ESSpawn(77, GraciaSeeds.DESTRUCTION, new Location(-239000,207000,-12896), new int[]{ENERGY_SEED_WATER,ENERGY_SEED_FIRE}));\n\t\tSPAWNS.put(78, new ESSpawn(78, GraciaSeeds.DESTRUCTION, new Location(-239512,207000,-12896), new int[]{ENERGY_SEED_WATER,ENERGY_SEED_FIRE}));\n\t\tSPAWNS.put(79, new ESSpawn(79, GraciaSeeds.DESTRUCTION, new Location(-245064,213144,-12384), new int[]{ENERGY_SEED_WIND,ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY}));\n\t\tSPAWNS.put(80, new ESSpawn(80, GraciaSeeds.DESTRUCTION, new Location(-245064,212072,-12384), new int[]{ENERGY_SEED_WIND,ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY}));\n\t\tSPAWNS.put(81, new ESSpawn(81, GraciaSeeds.DESTRUCTION, new Location(-246696,212072,-12384), new int[]{ENERGY_SEED_WIND,ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY}));\n\t\tSPAWNS.put(82, new ESSpawn(82, GraciaSeeds.DESTRUCTION, new Location(-246696,213160,-12384), new int[]{ENERGY_SEED_WIND,ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY}));\n\t\tSPAWNS.put(83, new ESSpawn(83, GraciaSeeds.DESTRUCTION, new Location(-245064,211416,-12384), new int[]{ENERGY_SEED_DARKNESS,ENERGY_SEED_WATER}));\n\t\tSPAWNS.put(84, new ESSpawn(84, GraciaSeeds.DESTRUCTION, new Location(-245048,210904,-12384), new int[]{ENERGY_SEED_DARKNESS,ENERGY_SEED_WATER}));\n\t\tSPAWNS.put(85, new ESSpawn(85, GraciaSeeds.DESTRUCTION, new Location(-246712,210888,-12384), new int[]{ENERGY_SEED_DARKNESS,ENERGY_SEED_WATER}));\n\t\tSPAWNS.put(86, new ESSpawn(86, GraciaSeeds.DESTRUCTION, new Location(-246712,211416,-12384), new int[]{ENERGY_SEED_DARKNESS,ENERGY_SEED_WATER}));\n\t\tSPAWNS.put(87, new ESSpawn(87, GraciaSeeds.DESTRUCTION, new Location(-245048,209544,-12512), new int[]{ENERGY_SEED_FIRE,ENERGY_SEED_WIND,ENERGY_SEED_EARTH}));\n\t\tSPAWNS.put(88, new ESSpawn(88, GraciaSeeds.DESTRUCTION, new Location(-245064,208456,-12512), new int[]{ENERGY_SEED_FIRE,ENERGY_SEED_WIND,ENERGY_SEED_EARTH}));\n\t\tSPAWNS.put(89, new ESSpawn(89, GraciaSeeds.DESTRUCTION, new Location(-246696,208456,-12512), new int[]{ENERGY_SEED_FIRE,ENERGY_SEED_WIND,ENERGY_SEED_EARTH}));\n\t\tSPAWNS.put(90, new ESSpawn(90, GraciaSeeds.DESTRUCTION, new Location(-246712,209544,-12512), new int[]{ENERGY_SEED_FIRE,ENERGY_SEED_WIND,ENERGY_SEED_EARTH}));\n\t\tSPAWNS.put(91, new ESSpawn(91, GraciaSeeds.DESTRUCTION, new Location(-245048,207816,-12512), new int[]{ENERGY_SEED_DIVINITY,ENERGY_SEED_DARKNESS}));\n\t\tSPAWNS.put(92, new ESSpawn(92, GraciaSeeds.DESTRUCTION, new Location(-245048,207288,-12512), new int[]{ENERGY_SEED_DIVINITY,ENERGY_SEED_DARKNESS}));\n\t\tSPAWNS.put(93, new ESSpawn(93, GraciaSeeds.DESTRUCTION, new Location(-246696,207304,-12512), new int[]{ENERGY_SEED_DIVINITY,ENERGY_SEED_DARKNESS}));\n\t\tSPAWNS.put(94, new ESSpawn(94, GraciaSeeds.DESTRUCTION, new Location(-246712,207816,-12512), new int[]{ENERGY_SEED_DIVINITY,ENERGY_SEED_DARKNESS}));\n\t\tSPAWNS.put(95, new ESSpawn(95, GraciaSeeds.DESTRUCTION, new Location(-244328,207272,-12768), new int[]{ENERGY_SEED_WATER,ENERGY_SEED_FIRE,ENERGY_SEED_WIND}));\n\t\tSPAWNS.put(96, new ESSpawn(96, GraciaSeeds.DESTRUCTION, new Location(-243256,207256,-12768), new int[]{ENERGY_SEED_WATER,ENERGY_SEED_FIRE,ENERGY_SEED_WIND}));\n\t\tSPAWNS.put(97, new ESSpawn(97, GraciaSeeds.DESTRUCTION, new Location(-243256,205624,-12768), new int[]{ENERGY_SEED_WATER,ENERGY_SEED_FIRE,ENERGY_SEED_WIND}));\n\t\tSPAWNS.put(98, new ESSpawn(98, GraciaSeeds.DESTRUCTION, new Location(-244328,205608,-12768), new int[]{ENERGY_SEED_WATER,ENERGY_SEED_FIRE,ENERGY_SEED_WIND}));\n\t\tSPAWNS.put(99, new ESSpawn(99, GraciaSeeds.DESTRUCTION, new Location(-242616,207272,-12768), new int[]{ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY}));\n\t\tSPAWNS.put(100, new ESSpawn(100, GraciaSeeds.DESTRUCTION, new Location(-242104,207272,-12768), new int[]{ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY}));\n\t\tSPAWNS.put(101, new ESSpawn(101, GraciaSeeds.DESTRUCTION, new Location(-242088,205624,-12768), new int[]{ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY}));\n\t\tSPAWNS.put(102, new ESSpawn(102, GraciaSeeds.DESTRUCTION, new Location(-242600,205608,-12768), new int[]{ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY}));\n\t\t// Seed of Annihilation\n\t\tSPAWNS.put(103, new ESSpawn(103, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-184519,183007,-10456), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(104, new ESSpawn(104, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-184873,181445,-10488), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(105, new ESSpawn(105, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-184009,180962,-10488), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(106, new ESSpawn(106, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-185321,181641,-10448), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(107, new ESSpawn(107, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-184035,182775,-10512), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(108, new ESSpawn(108, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-185433,181935,-10424), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(109, new ESSpawn(109, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-183309,183007,-10560), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(110, new ESSpawn(110, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-184929,181886,-10488), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(111, new ESSpawn(111, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-184009,180392,-10424), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(112, new ESSpawn(112, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-183793,183239,-10488), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(113, new ESSpawn(113, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-184245,180848,-10464), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(114, new ESSpawn(114, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-182704,183761,-10528), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(115, new ESSpawn(115, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-184705,181886,-10504), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(116, new ESSpawn(116, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-184304,181076,-10488), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(117, new ESSpawn(117, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-183596,180430,-10424), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(118, new ESSpawn(118, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-184422,181038,-10480), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(119, new ESSpawn(119, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-184929,181543,-10496), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(120, new ESSpawn(120, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-184398,182891,-10472), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(121, new ESSpawn(121, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-177606,182848,-10584), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(122, new ESSpawn(122, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-178104,183224,-10560), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(123, new ESSpawn(123, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-177274,182284,-10600), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(124, new ESSpawn(124, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-177772,183224,-10560), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(125, new ESSpawn(125, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-181532,180364,-10504), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(126, new ESSpawn(126, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-181802,180276,-10496), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(127, new ESSpawn(127, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-178429,180444,-10512), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(128, new ESSpawn(128, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-177606,182190,-10600), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(129, new ESSpawn(129, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-177357,181908,-10576), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(130, new ESSpawn(130, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-178747,179534,-10408), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(131, new ESSpawn(131, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-178429,179534,-10392), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(132, new ESSpawn(132, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-178853,180094,-10472), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(133, new ESSpawn(133, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-181937,179660,-10416), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(134, new ESSpawn(134, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-180992,179572,-10416), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(135, new ESSpawn(135, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-185552,179252,-10368), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(136, new ESSpawn(136, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-184572,178913,-10400), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(137, new ESSpawn(137, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-184768,178348,-10312), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(138, new ESSpawn(138, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-184572,178574,-10352), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(139, new ESSpawn(139, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-185062,178913,-10384), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(140, new ESSpawn(140, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-181397,179484,-10416), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(141, new ESSpawn(141, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-181667,179044,-10408), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(142, new ESSpawn(142, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-185258,177896,-10240), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(143, new ESSpawn(143, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-183506,176570,-10280), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(144, new ESSpawn(144, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-183719,176804,-10240), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(145, new ESSpawn(145, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-183648,177116,-10240), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(146, new ESSpawn(146, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-183932,176492,-10240), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(147, new ESSpawn(147, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-183861,176570,-10240), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(148, new ESSpawn(148, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-183790,175946,-10240), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(149, new ESSpawn(149, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-178641,179604,-10416), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(150, new ESSpawn(150, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-178959,179814,-10432), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(151, new ESSpawn(151, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-176367,178456,-10376), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(152, new ESSpawn(152, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-175845,177172,-10264), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(153, new ESSpawn(153, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-175323,177600,-10248), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(154, new ESSpawn(154, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-174975,177172,-10216), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(155, new ESSpawn(155, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-176019,178242,-10352), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(156, new ESSpawn(156, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-174801,178456,-10264), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(157, new ESSpawn(157, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-185648,183384,-15680), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(158, new ESSpawn(158, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-186740,180908,-15528), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(159, new ESSpawn(159, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-185297,184658,-15680), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(160, new ESSpawn(160, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-185697,181601,-15488), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(161, new ESSpawn(161, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-186684,182744,-15536), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(162, new ESSpawn(162, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-184908,183384,-15616), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(163, new ESSpawn(163, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-184994,185572,-15784), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(164, new ESSpawn(164, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-185796,182616,-15608), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(165, new ESSpawn(165, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-184970,184385,-15648), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(166, new ESSpawn(166, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-185995,180809,-15512), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(167, new ESSpawn(167, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-185352,182872,-15632), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(168, new ESSpawn(168, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-185624,184294,-15680), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(169, new ESSpawn(169, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-184486,185774,-15816), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(170, new ESSpawn(170, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-186496,184112,-15680), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(171, new ESSpawn(171, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-184232,185976,-15816), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(172, new ESSpawn(172, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-184994,185673,-15792), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(173, new ESSpawn(173, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-185733,184203,-15680), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(174, new ESSpawn(174, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-185079,184294,-15680), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(175, new ESSpawn(175, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-184803,180710,-15528), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(176, new ESSpawn(176, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-186293,180413,-15528), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(177, new ESSpawn(177, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-185352,182936,-15632), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(178, new ESSpawn(178, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-184356,180611,-15496), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(179, new ESSpawn(179, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-185375,186784,-15816), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(180, new ESSpawn(180, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-184867,186784,-15816), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(181, new ESSpawn(181, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-180553,180454,-15152), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(182, new ESSpawn(182, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-180422,180454,-15152), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(183, new ESSpawn(183, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-181863,181138,-15120), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(184, new ESSpawn(184, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-181732,180454,-15152), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(185, new ESSpawn(185, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-180684,180397,-15152), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(186, new ESSpawn(186, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-182256,180682,-15112), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(187, new ESSpawn(187, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-185492,179492,-15392), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(188, new ESSpawn(188, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-185894,178538,-15336), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(189, new ESSpawn(189, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-186028,178856,-15336), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(190, new ESSpawn(190, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-185224,179068,-15336), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(191, new ESSpawn(191, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-185492,178538,-15336), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(192, new ESSpawn(192, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-185894,178538,-15336), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(193, new ESSpawn(193, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-180619,178855,-15152), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(194, new ESSpawn(194, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-180255,177892,-15152), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(195, new ESSpawn(195, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-185804,176472,-15336), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(196, new ESSpawn(196, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-184580,176370,-15320), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(197, new ESSpawn(197, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-184308,176166,-15320), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(198, new ESSpawn(198, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-183764,177186,-15304), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(199, new ESSpawn(199, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-180801,177571,-15144), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(200, new ESSpawn(200, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-184716,176064,-15320), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(201, new ESSpawn(201, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-184444,175452,-15296), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(202, new ESSpawn(202, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-180164,177464,-15152), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(203, new ESSpawn(203, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-180164,178213,-15152), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(204, new ESSpawn(204, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-179982,178320,-15152), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(205, new ESSpawn(205, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-176925,177757,-15824), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(206, new ESSpawn(206, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-176164,179282,-15720), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(207, new ESSpawn(207, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-175692,177613,-15800), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(208, new ESSpawn(208, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-175418,178117,-15824), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(209, new ESSpawn(209, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-176103,177829,-15824), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(210, new ESSpawn(210, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-175966,177325,-15792), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(211, new ESSpawn(211, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-174778,179732,-15664), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(212, new ESSpawn(212, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-175692,178261,-15824), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(213, new ESSpawn(213, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-176038,179192,-15736), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(214, new ESSpawn(214, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-175660,179462,-15680), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(215, new ESSpawn(215, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-175912,179732,-15664), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(216, new ESSpawn(216, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-175156,180182,-15680), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(217, new ESSpawn(217, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-174240,182059,-15664), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(218, new ESSpawn(218, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-175590,181478,-15640), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(219, new ESSpawn(219, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-174510,181561,-15616), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(220, new ESSpawn(220, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-174240,182391,-15688), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(221, new ESSpawn(221, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-174105,182806,-15672), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(222, new ESSpawn(222, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-174645,182806,-15712), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(223, new ESSpawn(223, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-214962,182403,-10992), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(224, new ESSpawn(224, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-215019,182493,-11000), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(225, new ESSpawn(225, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-211374,180793,-11672), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(226, new ESSpawn(226, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-211198,180661,-11680), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(227, new ESSpawn(227, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-213097,178936,-12720), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(228, new ESSpawn(228, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-213517,178936,-12712), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(229, new ESSpawn(229, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-214105,179191,-12720), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(230, new ESSpawn(230, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-213769,179446,-12720), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(231, new ESSpawn(231, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-214021,179344,-12720), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(232, new ESSpawn(232, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-210582,180595,-11672), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(233, new ESSpawn(233, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-210934,180661,-11696), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(234, new ESSpawn(234, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-207058,178460,-12656), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(235, new ESSpawn(235, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-207454,179151,-11368), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(236, new ESSpawn(236, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-207422,181365,-11344), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(237, new ESSpawn(237, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-207358,180627,-11344), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(238, new ESSpawn(238, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-207230,180996,-11344), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(239, new ESSpawn(239, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-208515,184160,-11344), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(240, new ESSpawn(240, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-207613,184000,-11344), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(241, new ESSpawn(241, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-208597,183760,-11352), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(242, new ESSpawn(242, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-206710,176142,-12656), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(243, new ESSpawn(243, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-206361,178136,-11336), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(244, new ESSpawn(244, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-206178,178630,-12672), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(245, new ESSpawn(245, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-205738,178715,-12656), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(246, new ESSpawn(246, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-206442,178205,-12648), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(247, new ESSpawn(247, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-206585,178874,-11336), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(248, new ESSpawn(248, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-206073,179366,-11344), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(249, new ESSpawn(249, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-206009,178628,-11344), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(250, new ESSpawn(250, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-206155,181301,-12656), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(251, new ESSpawn(251, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-206595,181641,-12656), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(252, new ESSpawn(252, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-206507,181641,-12656), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(253, new ESSpawn(253, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-206507,181471,-12640), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(254, new ESSpawn(254, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-206974,175972,-12672), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(255, new ESSpawn(255, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-206304,175130,-11344), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(256, new ESSpawn(256, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-206886,175802,-12672), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(257, new ESSpawn(257, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-207238,175972,-12672), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(258, new ESSpawn(258, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-206386,174857,-11328), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(259, new ESSpawn(259, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-206386,175039,-11336), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(260, new ESSpawn(260, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-205976,174584,-11344), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(261, new ESSpawn(261, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-207367,184320,-11336), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(262, new ESSpawn(262, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-219002,180419,-12608), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(263, new ESSpawn(263, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-218853,182790,-12592), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(264, new ESSpawn(264, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-218853,183343,-12600), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(265, new ESSpawn(265, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-218358,186247,-11344), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(266, new ESSpawn(266, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-218358,186083,-11344), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(267, new ESSpawn(267, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-217574,185796,-11352), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(268, new ESSpawn(268, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-219178,181051,-12592), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(269, new ESSpawn(269, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-220171,180313,-11344), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(270, new ESSpawn(270, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-219293,183738,-12592), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(271, new ESSpawn(271, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-219381,182553,-12584), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(272, new ESSpawn(272, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-219600,183024,-11336), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(273, new ESSpawn(273, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-219940,182680,-11344), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(274, new ESSpawn(274, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-219260,183884,-11344), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(275, new ESSpawn(275, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-219855,183540,-11344), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(276, new ESSpawn(276, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-218946,186575,-11344), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(277, new ESSpawn(277, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-219882,180103,-12592), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(278, new ESSpawn(278, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-219266,179787,-12584), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(279, new ESSpawn(279, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-219201,178337,-12592), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(280, new ESSpawn(280, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-219716,179875,-11336), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(281, new ESSpawn(281, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-219716,180021,-11328), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(282, new ESSpawn(282, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-219989,179437,-11336), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(283, new ESSpawn(283, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-219078,178298,-12592), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(284, new ESSpawn(284, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-218684,178954,-11328), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(285, new ESSpawn(285, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-219089,178456,-11328), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(286, new ESSpawn(286, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-220266,177623,-12608), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(287, new ESSpawn(287, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-219201,178025,-12592), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(288, new ESSpawn(288, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-219142,177044,-12592), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(289, new ESSpawn(289, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-219690,177895,-12592), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(290, new ESSpawn(290, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-219754,177623,-12584), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(291, new ESSpawn(291, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-218791,177830,-12584), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(292, new ESSpawn(292, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-218904,176219,-12592), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(293, new ESSpawn(293, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-218768,176384,-12584), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(294, new ESSpawn(294, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-218774,177626,-11320), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(295, new ESSpawn(295, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-218774,177792,-11328), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(296, new ESSpawn(296, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-219880,175901,-11344), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(297, new ESSpawn(297, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-219210,176054,-12592), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(298, new ESSpawn(298, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-219850,175991,-12608), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(299, new ESSpawn(299, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-219079,175021,-11336), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(300, new ESSpawn(300, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-218812,174229,-11344), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(301, new ESSpawn(301, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-218723,174669,-11336), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\t//@formatter:on\n\t}",
"public void givePlaceInList() {\r\n\t\tmyPlaceInList = allyTracker.getPlaceInList();\r\n\t}",
"@Override\n\tpublic void run() {\n\t\tshape = factory.createShape(config);\n\t\tthis.list.add(shape);\n\t\tCommandHistory.add(this);\n\n\t}",
"public void addTile(Tile tile) {\n ownedTiles.add(tile);\n }",
"private void jbt_addTeacherActionPerformed(java.awt.event.ActionEvent evt) {\n String name = jtf_TeacherName.getText();\n //Teachers t = new Teachers(name);\n TeacherList.add(name);\n\n listdisplay.addElement(name);\n\n jlist_teacher.setModel(listdisplay);\n\n }",
"@Override\n\tpublic void acheter(List<Object> la) {\n\t\t\n\t}",
"@Override\n public void add(Object o) {\n gameCollection.addElement(o);\n }",
"@Override\n\tpublic void add() {\n\t\tSystem.out.println(\"前置通知\");\n\t\ttarget.add();\n\t\tSystem.out.println(\"后置通知\");\n\t}",
"public AddRandomList() {\n setTitleText(\"Add new random List\");\n\n addButton.setText(\"Add\");\n addButton.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n addButtonActionPerformed(evt);\n }\n });\n addButton(addButton);\n }",
"public void addToGroup(Movable movable){\n things.add(movable);\n }",
"public void addControl( Object aThing ){\n controls.push( aThing );\n }",
"void addToList(Task task) throws InvalidCommandException;",
"@Override\n\tpublic void redo() {\n\t\tthis.list.add(shape);\n\n\t}",
"public void addElts(Meters meter){\r\n MetersList.add(meter);\r\n }",
"public void addNewRecipe() {\r\n listOfRecipes.add(new Recipe().createNewRecipe());\r\n }",
"void addWay(Way w) {\n ways.put(w.id, w);\n }",
"private void addTrucks(int numTrucks, int capacity, int radius) {\r\n for (int i = 0; i < numTrucks; i++) {\r\n trucks.add(new Truck(capacity, this, radius)); //add in new truck with designated capacity and warehouse\r\n }\r\n }",
"public void addShape(Shapes obj) {\n \tthis.listShapes.add(obj);\n W.repaint();\n }",
"public abstract ArrayList<GameObject> fight();",
"public void addWheelItems(List<WheelItem> wheelItems) {\n wheelView.addWheelItems(wheelItems);\n }",
"public Tower() {\n\t\t// Nothing as of now, trying to insert Towers as of now\n\t}",
"private void addToArrayList(String getName) {\n\t\tUser newUser = new User(getName);\n\t\tmgUsr.arrList.add(newUser);\n\t\tobs = FXCollections.observableArrayList(mgUsr.arrList);\n\n\t\tsetOnListView();\n\t}",
"public void add (Object t)\r\n {\r\n }",
"public void addFriendList(FriendList list);",
"private void addEnemies() {\n\t\tred_ghost = new Enemy();\r\n\t\tthis.add(red_ghost);\r\n\t\tenemies.add(red_ghost);\r\n\t\t\r\n\t}",
"public void addToList(View view) {\n Items newItem = new Items();\n EditText ETNew = (EditText) findViewById(R.id.ETNew);\n newItem.todo = ETNew.getText().toString();\n newItem.done = false;\n helper.create(newItem);\n Toast.makeText(this, \"Item added\", Toast.LENGTH_SHORT).show();\n adaptList2();\n ETNew.setText(\"\");\n ETNew.setHint(\"my new to-do\");\n }",
"public final void addToInitList() {\n\t\tEngine.getSingleton().addToInitList(this);\n\t}",
"private void addAnotherElement() {\n\t\t SnakeSquare ss = sSquare.get(sSquare.size() - 1);\n\t\t double velX = ss.getDX();\n\t\t double velY = ss.getDY();\n\t\t \n\t\t double x = ss.getX();\n\t\t double y = ss.getY();\n\t\t double len = ss.getLength();\n\t\t Color c = ss.getColor();\n//\t\t double snakeSize = 10.0f;\n\t\t \n\t\t if(velX == 0 && velY == 0){sSquare.add(new SnakeSquare(x, y + snakeSize, c, len));}\n\t\t if(velX == 0 && velY == 1){sSquare.add(new SnakeSquare(x, y - snakeSize, c, len));}//move down;\n\t\t if(velX == 0 && velY == -1){sSquare.add(new SnakeSquare(x, y + snakeSize, c, len));}//move up;\n\t\t if(velX == 1 && velY == 0){sSquare.add(new SnakeSquare(x+ snakeSize, y, c, len));}//move right;\n\t\t if(velX == -1 && velY == 0){sSquare.add(new SnakeSquare(x - snakeSize, y, c, len));}// move left;\n\t\t\n\t}",
"public void add(MiningTask mt) {\n miningTasks.add(mt);\n }",
"public void addPoints(List<Point2D> points);",
"@Override\n public void onWheeled(int index, String item) {\n }",
"public void addBuildables(){\n this.allBuildables.add(new Nexus());\n this.allBuildables.add(new Pylon());\n this.allBuildables.add(new Assimilator());\n this.allBuildables.add(new Gateway());\n this.allBuildables.add(new CyberneticsCore());\n this.allBuildables.add(new RoboticsFacility());\n this.allBuildables.add(new Stargate());\n this.allBuildables.add(new TwilightCouncil());\n this.allBuildables.add(new TemplarArchives());\n this.allBuildables.add(new DarkShrine());\n this.allBuildables.add(new RoboticsBay());\n this.allBuildables.add(new FleetBeacon());\n this.allBuildables.add(new Probe());\n this.allBuildables.add(new Zealot());\n this.allBuildables.add(new Stalker());\n this.allBuildables.add(new Sentry());\n this.allBuildables.add(new Observer());\n this.allBuildables.add(new Immortal());\n this.allBuildables.add(new Phoenix());\n this.allBuildables.add(new VoidRay());\n this.allBuildables.add(new Colossus());\n this.allBuildables.add(new HighTemplar());\n this.allBuildables.add(new DarkTemplar());\n this.allBuildables.add(new Carrier());\n }",
"public void addElts(Bars bar){\r\n BarsList.add(bar);\r\n }",
"public void addPreferedWeapon() {\n\t\tfor(int i = 0; i < killers.size(); i++) {\n\t\t\t\n\t\t\tList<String> list = new ArrayList<>();\n\t\t\t\n\t\t\tfor(String key : killers.get(i).getWeapons().keySet()) {\n\t\t\t\tlist.add(killers.get(i).getWeapons().get(key) + \";\" + key);\n\t\t\t}\n\t\t\t\n\t\t\tComparator<String> comp = (s1, s2) -> {\n\t\t\t\treturn s1.compareTo(s2);\n\t\t\t};\n\t\t\t\n\t\t\tCollections.sort(list, Collections.reverseOrder(comp));\n\t\t\tList<String> list2 = new ArrayList<>();\n\t\t\t\n\t\t\tif(!list.isEmpty()) {\n\t\t\t\tint control = extractNumberFromText(list.get(0));\n\t\t\t\t\n\t\t\t\tlist.forEach(s -> {\n\t\t\t\t\tif(extractNumberFromText(s) == control)\n\t\t\t\t\t\tlist2.add(s);\n\t\t\t\t});\n\t\t\t}\n\t\t\t\n\t\t\t\n\t\t\tkillers.get(i).setWeaponMoreUsed(list2);\n\t\t}\n\t}",
"public ArrayList<AbstractPokemon> selectPokemon()\n {\n /**\n * Tells the Java Runtime Environment to add a certain Pokemon to a list of Pokemon when a button is clicked.\n * \n * @author Jonathan Lowe\n * @version 1.0.0\n */\n class PokemonClickListener implements ActionListener\n {\n private JTextArea label;\n private String pokemonName;\n private AbstractPokemon pokemon;\n private ArrayList<AbstractPokemon> party;\n \n /**\n * Creates a copy of the Pokemon to be stored in the list of Pokemon\n * \n * @param list The list the selected Pokemon will be added to\n * @param label The output stream to be updated when a Pokemon is added\n * @param poke The Pokemon to be added to the list\n */\n public PokemonClickListener(ArrayList<AbstractPokemon> list, JTextArea label, AbstractPokemon poke)\n {\n this.label = label;\n this.pokemonName = poke.toString();\n if(poke instanceof Bulbasaur)\n this.pokemon = new Bulbasaur();\n else if(poke instanceof Sunkern)\n this.pokemon = new Sunkern();\n else if(poke instanceof Oddish)\n this.pokemon = new Oddish();\n else if(poke instanceof Charmander)\n this.pokemon = new Charmander();\n else if(poke instanceof Vulpix)\n this.pokemon = new Vulpix();\n else if(poke instanceof Magby)\n this.pokemon = new Magby();\n else if(poke instanceof Squirtle)\n this.pokemon = new Squirtle();\n else if(poke instanceof Poliwhirl)\n this.pokemon = new Poliwhirl();\n else if(poke instanceof Magikarp)\n this.pokemon = new Magikarp();\n else\n this.pokemon = new Charmander();\n this.party = list;\n }\n \n /**\n * Adds the copied Pokemon to the list of Pokemon\n * \n * @param event The button click event\n */\n public void actionPerformed(ActionEvent event)\n {\n label.append(\"\\n\" + pokemonName);\n party.add(pokemon);\n }\n }\n \n /**\n * Tells the Java Runtime Environment to \"close\" the JFrame this button is found in\n * \n * @author Jonathan Lowe\n * @version 1.0.0\n */\n class ExitClickListener implements ActionListener\n {\n private JFrame frame;\n \n /**\n * Sets the JFrame to be closed\n * \n * @param frame The JFrame to be closed\n */\n public ExitClickListener(JFrame frame)\n {\n this.frame = frame;\n }\n \n /**\n * Closes the JFrame\n * \n * @param event The button click event\n */\n public void actionPerformed(ActionEvent event)\n {\n frame.dispatchEvent(new WindowEvent(frame, WindowEvent.WINDOW_CLOSING));\n }\n }\n \n JFrame frame = new JFrame();\n JTextArea label = new JTextArea(\"The Pokemon in your party:\", 7, 20);\n label.setEditable(false);\n JPanel masterPanel = new JPanel(new GridLayout(3, 1));\n JLabel title = new JLabel(\"Please select this trainer's Pokemon.\");\n JPanel titlePanel = new JPanel();\n titlePanel.setSize(10, 400);\n titlePanel.add(title);\n masterPanel.add(titlePanel);\n JPanel bottomPanel = new JPanel(new GridLayout(1, 2));\n ArrayList<AbstractPokemon> party = new ArrayList<AbstractPokemon>();\n JPanel leftPanel = new JPanel(new GridLayout(3, 3));\n JButton charmanderButton = new JButton(new ImageIcon(\"Charmander.gif\"));\n charmanderButton.addActionListener(new PokemonClickListener(party, label, new Charmander()));\n leftPanel.add(charmanderButton);\n JButton vulpixButton = new JButton(new ImageIcon(\"Vulpix.gif\"));\n vulpixButton.addActionListener(new PokemonClickListener(party, label, new Vulpix()));\n leftPanel.add(vulpixButton);\n JButton magbyButton = new JButton(new ImageIcon(\"Magby.gif\"));\n magbyButton.addActionListener(new PokemonClickListener(party, label, new Magby()));\n leftPanel.add(magbyButton);\n JButton squirtleButton = new JButton(new ImageIcon(\"Squirtle.gif\"));\n squirtleButton.addActionListener(new PokemonClickListener(party, label, new Squirtle()));\n leftPanel.add(squirtleButton);\n JButton poliwhirlButton = new JButton(new ImageIcon(\"Poliwhirl.gif\"));\n poliwhirlButton.addActionListener(new PokemonClickListener(party, label, new Poliwhirl()));\n leftPanel.add(poliwhirlButton);\n JButton magikarpButton = new JButton(new ImageIcon(\"Magikarp.gif\"));\n magikarpButton.addActionListener(new PokemonClickListener(party, label, new Magikarp()));\n leftPanel.add(magikarpButton);\n JButton bulbasaurButton = new JButton(new ImageIcon(\"Bulbasaur.gif\"));\n bulbasaurButton.addActionListener(new PokemonClickListener(party, label, new Bulbasaur()));\n leftPanel.add(bulbasaurButton);\n JButton sunkernButton = new JButton(new ImageIcon(\"Sunkern.gif\"));\n sunkernButton.addActionListener(new PokemonClickListener(party, label, new Sunkern()));\n leftPanel.add(sunkernButton);\n JButton oddishButton = new JButton(new ImageIcon(\"Oddish.gif\"));\n oddishButton.addActionListener(new PokemonClickListener(party, label, new Oddish()));\n leftPanel.add(oddishButton);\n bottomPanel.add(leftPanel);\n JPanel rightPanel = new JPanel();\n rightPanel.add(label);\n bottomPanel.add(rightPanel);\n masterPanel.add(bottomPanel);\n JButton exitButton = new JButton(\"Okay, I'm done\");\n exitButton.addActionListener(new ExitClickListener(frame));\n JPanel exitPanel = new JPanel();\n exitPanel.setSize(20, 100);\n exitPanel.add(exitButton);\n masterPanel.add(exitPanel);\n frame.add(masterPanel);\n frame.setTitle(\"Pokemon Selection\");\n frame.setSize(600, 400);\n frame.setVisible(true);\n \n return party;\n }",
"public void addAll(ArrayList<Taking> items){\n if(this.mTakings == null){\n this.mTakings = new ArrayList<>();\n }\n this.mTakings.addAll(items);\n notifyDataSetChanged();\n }",
"public void addOn(ArrayList array) {\n try {\n PrintWriter writer;\n if (array.get(0) instanceof Integer)\n writer = new PrintWriter(\"points.txt\");\n else writer = new PrintWriter(\"names.txt\");\n\n for (int i=0; i<array.size(); i++)\n writer.println(array.get(i));\n writer.close();\n } catch (IOException e)\n {}\n }"
] | [
"0.67376226",
"0.6145676",
"0.5977289",
"0.58750427",
"0.5777197",
"0.571415",
"0.5675698",
"0.56731355",
"0.56176883",
"0.56026345",
"0.5548689",
"0.5541373",
"0.55206627",
"0.551452",
"0.5497291",
"0.548076",
"0.54575765",
"0.5447416",
"0.54392195",
"0.5414304",
"0.54103047",
"0.54088646",
"0.540357",
"0.5377523",
"0.535867",
"0.5357572",
"0.53571314",
"0.5351899",
"0.53434473",
"0.5332291",
"0.53299755",
"0.5328933",
"0.5328698",
"0.5326455",
"0.5307901",
"0.53069043",
"0.53009427",
"0.528985",
"0.52763194",
"0.5264649",
"0.5264236",
"0.52609307",
"0.52540475",
"0.52508956",
"0.5250012",
"0.5245652",
"0.5220558",
"0.5207949",
"0.52052724",
"0.5200402",
"0.52003956",
"0.51926833",
"0.51823294",
"0.51802075",
"0.51763517",
"0.517394",
"0.5168432",
"0.51663136",
"0.51626384",
"0.5154643",
"0.5140616",
"0.5135323",
"0.5132987",
"0.5131777",
"0.5128442",
"0.5125945",
"0.51221454",
"0.5120497",
"0.5116378",
"0.51108927",
"0.51092905",
"0.51080894",
"0.5102248",
"0.50911736",
"0.5087094",
"0.50817025",
"0.50747526",
"0.5072642",
"0.5071312",
"0.5064593",
"0.50633687",
"0.5055221",
"0.5052658",
"0.5052479",
"0.50523",
"0.50504696",
"0.5050006",
"0.50472677",
"0.50397074",
"0.5036575",
"0.503134",
"0.50311935",
"0.50288814",
"0.5028723",
"0.50245506",
"0.50171465",
"0.50155807",
"0.50154614",
"0.5014142",
"0.501412"
] | 0.62392414 | 1 |
Remove Tower from ArrayList | public static void removeTower(Tower t)
{
towers.remove(t);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"private List<Individual<T>> removeWorst(List<Individual<T>> tournament) {\n Individual<T> worst = selWorstOp.select(tournament);\n tournament.remove(worst);\n return tournament;\n }",
"public void remove() {\n if (count == 0) {\n return;\n }\n \n Random rand = new Random();\n int index = rand.nextInt(count);\n for (int i = index; i < count - 1; i++) {\n list[i] = list[i+1];\n }\n count--; \n }",
"void removeRoadside(int i);",
"@Override\n public void remove(T t) {\n for (int i = 0; i < elementsInArray; i++) {\n if(t.equals(arrayList[i])) {\n arrayList[i] = null;\n elementsInArray--;\n return;\n }\n }\n }",
"public void removeTile(Tile a_tile){\n for(int i = 0; i < playerHand.size(); i++){\n if(playerHand.get(i).getRight() == a_tile.getRight() && playerHand.get(i).getLeft() == a_tile.getLeft()){\n playerHand.remove(i);\n break;\n }\n }\n }",
"void removeSpeeds(int i);",
"private List<MutableTrooper> teammatesWithoutSelf() {\n ArrayList<MutableTrooper> r = new ArrayList<>();\r\n for (Trooper ally : teammates) {\r\n if (ally.getId() != self.getId()) {\r\n r.add(new MutableTrooper(ally, -1));\r\n }\r\n }\r\n return r;\r\n }",
"public void drop(){\r\n if(activeFish.isEmpty()) return;\r\n \r\n ArrayList<Fish> toremove = new ArrayList<Fish>();\r\n for(Fish bone : activeFish){\r\n bone.drop();\r\n\r\n if(!(bone.inBounds())){ // branch for out of bound fh\r\n toremove.add(bone);\r\n }\r\n }\r\n missedFish(toremove);\r\n\r\n update();\r\n }",
"private ArrayList<Equity> getUnwatchedEquities(ArrayList<Equity> list) {\n ArrayList<Equity> temp = new ArrayList<>();\n temp.addAll(list);\n ArrayList<WatchedEquity> watched = controller.getUser().watchedEquities;\n for (Equity e : list) {\n for (WatchedEquity we : watched) {\n if (e.getTickerSymbol().equals(we.getSymbol())) {\n temp.remove(e);\n break;\n }\n }\n }\n return temp;\n }",
"public void removeWatersheds(int i)\r\n {\r\n synchronized (monitor())\r\n {\r\n check_orphaned();\r\n get_store().remove_element(WATERSHEDS$4, i);\r\n }\r\n }",
"private void eliminatePlayers() {\n \n Iterator<Player> iter = players.iterator();\n\n while (iter.hasNext()) {\n Player player = iter.next();\n\n if (player.getList().isEmpty()) {\n iter.remove();\n if (player.getIsHuman()) {\n setGameState(GameState.HUMAN_OUT);\n }\n // need to remember that due to successive draws, the active player could run\n // out of cards\n // select a new random player if player gets eliminated\n if (!players.contains(activePlayer)) {\n selectRandomPlayer();\n }\n }\n }\n }",
"private void removeALakeTile(Game game) {\n\t\tLakeTile[][] board = game.getPlayArea().getLakeTilesOnBoard();\n\t\tArrayList<Position> positions = new ArrayList<Position>();\n\t\tfor (int y = 0; y < board.length; y++) {\n\t\t\tfor (int x = 0; x < board[y].length; x++) {\n\t\t\t\tLakeTile laketile = board[x][y];\n\t\t\t\tif (laketile != null) {\n\t\t\t\t\tint connect_laketile = 4;\n\t\t\t\t\tif (x + 1 < board.length && board[x + 1][y] == null)\n\t\t\t\t\t\tconnect_laketile -= 1;\n\t\t\t\t\tif (y + 1 < board.length && board[x][y + 1] == null)\n\t\t\t\t\t\tconnect_laketile -= 1;\n\t\t\t\t\tif (x - 1 >= 0 && board[x - 1][y] == null)\n\t\t\t\t\t\tconnect_laketile -= 1;\n\t\t\t\t\tif (y - 1 >= 0 && board[x][y - 1] == null)\n\t\t\t\t\t\tconnect_laketile -= 1;\n\t\t\t\t\tif (connect_laketile == 1) {\n\t\t\t\t\t\tPosition p = new Position(x, y);\n\t\t\t\t\t\tpositions.add(p);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tif (countLakeTileOnBoard(board) != 0 && positions.size() == 0) {\n\t\t\tpositions = getAllLakeTilePositionOnBoard(board);\n\t\t}\n\t\tCollections.shuffle(positions);\n\t\tPosition pos = positions.get(0);\n\t\tint x = pos.getX();\n\t\tint y = pos.getY();\n\t\tremoved_laketile.add(board[x][y]);\n\t\tremoved_position.add(pos);\n\t\tboard[x][y] = null;\n\t}",
"public ArrayList<Player> checkToEliminate() {\n ArrayList<Player> eliminated = new ArrayList<Player>();\n\n // Check which players are to be eliminated\n for (Player player : playersInGame) {\n if (player.peekCard() == null) {\n eliminated.add(player);\n }\n }\n\n // Eliminate players from model\n for (Player eliminatedPlayer : eliminated) {\n playersInGame.remove(eliminatedPlayer);\n }\n\n return eliminated;\n }",
"public void removeVehicles() {\r\n numberOfVehicles = 0;\r\n for (Lane lane : lanes) {\r\n lane.removeVehicles();\r\n }\r\n }",
"public void getPeopleInAndOut(int currentLiftFloor, int BaseCase){\n List<Object> toRemoveFromLiftList = new ArrayList<Object>();\n\n\n\n //to get people off the lift with matching floors to the one currently on.\n if (liftList.size() != 0){\n\n\n //this variable will be updated if somebody gets out of the Lift\n int stopped = 0;\n\n //iterate through the list of objects to find a matching floor\n for (Object o : liftList) {\n\n int x = ((peopleObject) o).getFloor();\n\n if ( x == currentLiftFloor){\n\n\n toRemoveFromLiftList.add(o);\n\n\n\n\n if (BaseCase == 1){\n peopleoutBaseCase += 1;\n listsFloorsOutBaseCase.get(currentLiftFloor).add(o);\n\n\n }\n\n else if (BaseCase == 0) {\n peopleOut += 1;\n listsFloorsOut.get(currentLiftFloor).add(o);\n }\n\n\n\n\n\n\n stopped = 1;\n\n\n }\n\n\n }\n\n //if the variable as been updated it means that somebody went off, so it also means that the lift stopped\n //We had the floor at which it stopped to the lift of stops for the UI\n if (stopped == 1){listsOfStops.add(currentLiftFloor);}\n\n //removing all the elements the matching elements between the list\n // i Used this method to avoid the \"ConcurrentModificationException” i was getting\n liftList.removeAll(toRemoveFromLiftList);\n\n\n\n\n\n\n }\n\n //to get people on the lift if there is any body on the floor.\n if (listsFloors.size() != 0 && BaseCase == 0) {\n\n\n\n\n\n int stopped = 0;\n\n int currentFloorSize = listsFloors.get(currentLiftFloor).size();\n //this for loop is responsible to get the people on the floor (that the lift is on), inside the lift.\n for (int i = 0; i < (currentFloorSize); i++) {\n\n\n\n\n if (liftList.size() >= 10){\n break;\n\n\n }\n\n\n\n\n //getting the first person from the floor list (for every iteration)\n //We get the first one because in the scope we will delete it after adding it to the lift\n // the second person will then become the first that is why we get the first one.\n liftList.add(listsFloors.get(currentLiftFloor).get(0));\n\n\n listsFloors.get(currentLiftFloor).remove(0);\n stopped = 1;\n\n\n\n\n\n\n\n\n\n }\n\n if (stopped == 1){listsOfStops.add(currentLiftFloor);}\n\n }\n\n\n\n else if (listsFloorsBaseCase.size() != 0 && BaseCase == 1){\n\n int stoppedBC = 0;\n int currentFloorSizeBC = listsFloorsBaseCase.get(currentLiftFloor).size();\n\n for (int i = 0; i < (currentFloorSizeBC); i++) {\n\n if (liftList.size() >= 10){\n break;\n\n\n }\n\n\n //getting the first person from the floor list (for every iteration)\n //We get the first one because in the scope we will delete it after adding it to the lift\n // the second person will then become the first that is why we get the first one.\n liftList.add(listsFloorsBaseCase.get(currentLiftFloor).get(0));\n\n\n listsFloorsBaseCase.get(currentLiftFloor).remove(0);\n stoppedBC = 1;\n\n\n\n }\n\n }\n\n\n\n\n }",
"protected void removeLane()\n {\n if (lane == 1)\n {\n\n MyWorld.Lane1Monsters.remove(this);\n getWorld().removeObject(this);\n\n }\n\n else if (lane == 2)\n {\n MyWorld.Lane2Monsters.remove(this);\n getWorld().removeObject(this);\n\n }\n\n else if (lane == 3)\n {\n MyWorld.Lane3Monsters.remove(this);\n getWorld().removeObject(this);\n\n }\n\n else if (lane == 4)\n {\n MyWorld.Lane4Monsters.remove(this);\n getWorld().removeObject(this);\n\n }\n\n else if (lane == 5)\n {\n MyWorld.Lane5Monsters.remove(this);\n getWorld().removeObject(this);\n\n }\n MyWorld.monsterAdded();\n }",
"void removeLanes(int i);",
"public void remove();",
"public void remove();",
"public void remove();",
"public void remove();",
"public void remove();",
"void removeDecisionSightDistance(int i);",
"public void remove()\n {\n this.morphs.remove(this.index);\n this.clamp();\n }",
"public void remove() {\n int size = itinerary.size();\n if (size != 1) {\n \n // Removes last Flight in this Itinerary.\n Flight removedFlight = this.itinerary.remove(size - 1);\n \n // Gets the new last Flight in this Itinerary.\n Flight flight = this.itinerary.get(size - 2);\n \n // Updates all the relevant fields in this Itinerary.\n this.price -= removedFlight.getCost();\n this.arrivalDateTime = flight.getArrivalDateTime();\n this.destination = flight.getDestination();\n this.travelTime = arrivalDateTime.timeDiff(departDateTime);\n this.places.remove(size);\n }\n }",
"public void removeRobotsAndRubble() {\n\t\tfor(Player p : playerList) {\n\t\t\tif(p.getType() != PlayerType.Agent) {\n\t\t\t\tremovePosition(p.getPosition());\n\t\t\t\tremovePlayer(p.getName());\n\t\t\t}\n\t\t\telse \n\t\t\t\tp.resetRobotsFollowing();\n\t\t}\n\t}",
"void removeAllSpawn();",
"void removeDebts(int i);",
"public T removeBest();",
"public void removePowerUp(List<CardPower> cost)\n {\n cardPower.removeAll(cost);\n }",
"public void removeBalls() {\r\n for (Ball ball : this.ballsList) {\r\n ball.removeFromGame(this);\r\n }\r\n this.ballsList.clear();\r\n }",
"public void remove(int num) {\n // find the index of num\n for (int i = 0; i < count; i++) {\n if (list[i] == num) {\n // shift the elements leftward and decrement count\n for (int j = 0; j < count - 1; j++) {\n list[i+j] = list[i+j+1];\n }\n count--;\n return;\n }\n }\n }",
"public void remove()\r\n { Exceptions.unmodifiable(\"list\"); }",
"public void remove () {}",
"public void remove () { this.setAsDown(); n.remove(); }",
"Set<Card> remove();",
"public ArrayList<Item> drop()\n {\n ArrayList<Item> drop = new ArrayList<>();\n for( Pair<Enums.ItemName, Integer> possibleDrop : dropTable)\n {\n if(ThreadLocalRandom.current().nextInt(100) < possibleDrop.getY())\n drop.add(new Item(possibleDrop.getX()));\n }\n return drop;\n }",
"public void removePowerUp(PowerUp p) {\n for (Location loc : p.getLocations()) {\n Location replacement = new Location(loc.getX(), loc.getY());\n gridCache.add(replacement);\n }\n\n powerUps.remove(p);\n render();\n}",
"public void removePlaces(){\n List<Place> copies = new ArrayList<>(places);\n for(Place p : copies){\n p.reset();\n }\n }",
"void removeNoPassingZone(int i);",
"public void deleteTour(Tour t) {\r\n\t\t int i=Arrays.asList(tours).indexOf(t);\r\n\t\t\r\n\t\t tours[i]=null;\r\n\t\t }",
"private void eliminatePlayer(Player loser){\n players.remove(loser);\n }",
"public void removeTile(){\n\t\toccupied = false;\n\t\tcurrentTile = null;\n\t}",
"public void removeScenery(){\n\t\tfor(int i=0;i<grid.length;i++){\n\t\t\tfor(int j=0;j<grid[0].length;j++){\n\t\t\t\tif(grid[i][j].isScenery())\n\t\t\t\t\tgrid[i][j]=null;\n\t\t\t}\n\t\t}\n\t}",
"public void Remove(Floor obj) {\n floorList.remove(obj);\n }",
"public void removePrevCardList(){\n for (int i = 0; i < playerCardList.getPlayerCardListSize(); i++){\n playerCardPuzzle.getChildren().remove(playerCardList.getPlayerCardByNo(i));\n }\n }",
"void removeControlPersons(int i);",
"void remove();",
"void remove();",
"void remove();",
"void remove();",
"void remove();",
"private void removeList()\r\n {\n if (tableCheckBinding != null)\r\n {\r\n tableCheckBinding.dispose();\r\n tableCheckBinding = null;\r\n }\r\n\r\n // m_TableViewer.setInput(null);\r\n WritableList newList = new WritableList(SWTObservables.getRealm(Display.getDefault()));\r\n for (int i = 0; i < 10; ++i)\r\n {\r\n newList.add(this.generateNewDataModelItem());\r\n }\r\n m_TableViewer.setInput(newList);\r\n }",
"public void removeListeners() {\n for (LetterTile tile : rack)\n tile.removeTileListener();\n }",
"@Test\n public void testRemove_int_Order() {\n SegmentedOasisList<Integer> instance = new SegmentedOasisList<>();\n Collection c = Arrays.asList(1, 1, 7, 1, 1, 1, 1);\n instance.addAll(c);\n\n instance.remove(2);\n\n List<Integer> expResult = Arrays.asList(1, 1, 1, 1, 1, 1);\n\n assertTrue(isEqual(expResult, instance));\n\n }",
"void removePerformer(int i);",
"public Card removeCard(){\n Card temp = pile[0]; //removes top card. putting placement card to avoid null pointer\n for(int i = 0; i < pilePlace; i++){ //shifts cards\n pile[i] = pile[i+1];\n }\n pilePlace--;\n return temp;\n\n }",
"public void removeActor(int index) { ActorSet.removeElementAt(index); }",
"public void youBrokeSon(){\n\t\tcoinList.clear();\n\t}",
"public void remove()\n {\n if( current > 0 )\n {\n set(-- current);\n }\n }",
"void removeNeighbors();",
"private void removeAntFromBoard(Board inputBoard, String name) {\nfor (int k = 0; k < inputBoard.getAntsOnBoard().size(); k++) {\nString currentName = inputBoard.getAntsOnBoard().get(k).getName();\nif (currentName.equalsIgnoreCase(name)) {\nint antPosX = inputBoard.getAntsOnBoard().get(k).getAntPosX();\nint antPosY = inputBoard.getAntsOnBoard().get(k).getAntPosY();\ninputBoard.getAntsOnBoard().remove(k);\ninputBoard.getCellCordinates(antPosX, antPosY).removeAnt();\n}\n}\n}",
"public void discardToDeck() {\n\t\tfor(int i=discardPile.size(); i>0; i--) {\n\t\t deck.add(discardPile.remove(0));\n\t\t}\n\t\tCollections.shuffle(deck);\n\t}",
"public void removeAllItems ();",
"public ArrayList updateMonster(Pane gamePane){\r\n\r\n\t\tfor (int c = 0; c < arrayMonster.size(); c++){\r\n\r\n\t\t\tif (arrayMonster.get(c).getY() > Constants.GAMEHEIGHT){\r\n\r\n\t\t\t\tarrayMonster.get(c).remove(gamePane);\r\n\r\n\t\t\t\tarrayMonster.remove(c);\r\n\r\n\t\t\t}\r\n\r\n\t\t}\r\n\r\n\t\treturn arrayMonster;\r\n\r\n\t}",
"private void deleteAttacks(){\n while(!attacksToDelete.isEmpty()){\n attacks.remove(attacksToDelete.remove());\n }\n }",
"public TrainSet withoutPassengers(Person value)\n {\n for (Train obj : this)\n {\n obj.withoutPassengers(value);\n }\n \n return this;\n }",
"myGame.addTower(Tower thisTower){ // adding a tower to the game\n towers.add(thisTower); // adding a tower to the set that contains all the towers\n }",
"public void removeAllFightsystems()\r\n {\n\r\n }",
"public static void main(String[] args) {\n\n ArrayList<Integer> arrayList=new ArrayList<>();\n\n arrayList.add(1);\n arrayList.add(1);\n arrayList.add(2);\n arrayList.add(5);\n\n\n System.out.println(arrayList);\n System.out.println(arrayList.remove(1));\n System.out.println(arrayList);\n\n }",
"public void removeTile(int i)\n {\n int c = 0;\n for(Tile t: tiles)\n {\n if(t != null)\n c += 1;\n }\n c -=1;\n \n \n if(!(c < 2))\n {\n if(i == c)\n {\n tiles[i] = null;\n previews[i] = null;\n previewGradients[i] = null;\n previewHover[i] = false;\n activeTile = i-1;\n createPreviewGradients();\n return;\n }\n else\n {\n int last = 0;\n for(int j = i; j < c; j++)\n {\n tiles[j] = tiles[j+1];\n if(tiles[j] != null)\n tiles[j].setTileLevel(j);\n previews[j] = previews[j+1];\n previewGradients[j] = previewGradients[j+1];\n previewHover[j] = previewHover[j+1];\n last = j;\n }\n last += 1;\n tiles[last] = null;\n previews[last] = null;\n previewGradients[last] = null;\n previewHover[last] = false;\n createPreviewGradients();\n \n return;\n }\n }\n \n }",
"@Override\n public void removeAll(){\n gameCollection.removeAllElements();\n }",
"void unsetRaceList();",
"Object remove();",
"void removeBridgeElement(int i);",
"public void removeKing(){\n this.king = false;\n }",
"public void removeIt() { \n\t\t\tcollection.remove(currIndex);\n\t\t\tcurrIndex--;\n\t\t}",
"@Test\r\n\tpublic void testRemoveAll() {\r\n\t\tDoubleList sample = new DoubleList(new Munitions(2, 3, \"iron\"));\r\n\t\tsample.add(new Munitions(new Munitions(3, 4, \"iron\")));\r\n\t\tAssert.assertTrue(list.removeAll(sample));\r\n\t\tAssert.assertFalse(list.removeAll(sample));\r\n\t\tAssert.assertEquals(13, list.size());\r\n\t}",
"public void remove(int v) {\n Lista iter = new Lista(this);\n if (iter.x != v) {\n while (iter.next.x != v) {\n if (iter.next != null) {\n iter = iter.next;\n }\n }\n }\n if (iter.next.x == v) {\n iter.next = iter.next.next;\n }\n }",
"public void remove(int index) {\n for (int i = index; i < this.list.length-1; i++) {\n this.list[i]=this.list[i+1];\n }\n this.size--;\n }",
"public void removeUnit(){\r\n tacUnit = null;\r\n }",
"private void removeOOSBalas() {\n balasToRemove = new ArrayList<>();\n balas.forEach(bala -> {\n if(bala.getState() == Enums.BulletState.TO_REMOVE) {\n if(!balasToRemove.contains(bala)) {\n balasToRemove.add(bala);\n }\n }\n });\n balasToRemove.forEach(bala -> balas.remove(bala));\n }",
"public void removeTile(Tile tile) {\n ownedTiles.remove(tile);\n }",
"public static void removeIceAndFire(){\r\n for(int i = 0; i < board.length; i++) {\r\n for (int j = 0; j < board[i].length; j++) {\r\n if(board[i][j].isOnFireForTheNextNTurns == currentTurn){\r\n board[i][j].isOnFire = false;\r\n }\r\n if(board[i][j].isFrozenForTheNextNTurns == currentTurn){\r\n board[i][j].isFrozen = false;\r\n }\r\n }\r\n }\r\n }",
"public void remove(int index) {\r\n\t\t//Das Element am Index soll weg:\r\n\t\t//1. Alle Elemente davor sollen erhalten bleiben\r\n\t\t//2. Alle Elemente dahinter sollen erhalten bleiben\r\n\t\t//und der Index 1 kleiner werden\r\n\t\tfor(int i=index+1;i < geheim.length; i++) {\r\n\t\t\tgeheim[i-1] = geheim[i];\r\n\t\t}\r\n\t\t//3. Das Array soll um eins kleiner sein\r\n\t\tresize(-1);\r\n\t}",
"public void removeDuplication() {\r\n\t\t//checks if the array contains any elements\r\n\t\tif (!isEmpty()) {\t//contains elements\r\n\t\t\t//loop to execute for every element in the array\r\n\t\t\tfor (int i=0;i<size-1;i++) {\r\n\t\t\t\tObject element=list[i];\t//to store value of element in array\r\n\t\t\t\t//loop to execute for every element after the current element in the list\r\n\t\t\t\tfor (int j=i+1;j<size;j++) {\r\n\t\t\t\t\t//checks if there is are 2 elements in the list with the same value\r\n\t\t\t\t\tif (element==list[j]) {\r\n\t\t\t\t\t\tremove(j);\t//calls function to remove that element from array\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t\telse {\t//contains 0 elements\r\n\t\t\tSystem.out.println(\"List is empty!\");\r\n\t\t}\r\n\t}",
"public void removeAllElements();",
"public static void remove1() {\n\t\tSystem.out.println(\">>>>>>>>>>>>\");\n\t\tArrayList<Integer> class0 = new ArrayList<Integer>();\n\t\tclass0.add(1);\n\t\tclass0.add(2);\n class0.add(3);\n class0.add(4);\n class0.add(5);\n\t\tassert (class0.contains(1) == true);\n\t\tassert (class0.contains(2) == true);\n assert (class0.contains(3) == true);\n assert (class0.contains(4) == true);\n assert (class0.contains(5) == true);\n\t\tfor(int i = 0; i < class0.size(); i++) {\n\t\t\tint temp = (int)class0.get(i);\n\t\t\tSystem.out.println(temp + \" \");\n\t\t}\n\t\t\n\t\tclass0.remove(2);\n\t\tassert (class0.contains(1) == true);\n\t\tassert (class0.contains(2) == true);\n assert (class0.contains(3) == false);\n assert (class0.contains(4) == true);\n assert (class0.contains(5) == true);\n\t\tfor(int i = 0; i < class0.size(); i++) {\n\t\t\tint temp = (int)class0.get(i);\n\t\t\tSystem.out.println(temp + \" \");\n\t\t}\n\t\tret0 = class0;\n\t}",
"public void deleteBoat(int i) {\n\t\tboatList.remove(i);\n\t}",
"public ArrayList<E> removeAt(Point p) {\n\t\tArrayList<E> result = new ArrayList<E>();\n\t\tfor (E e : entities)\n\t\t\tif (e.getBounds().contains(p))\n\t\t\t\tresult.add(e);\n\t\tentities.removeAll(result);\n\t\treturn result;\n\t}",
"@Test\n public void testRemove_int_Order_Overflow() {\n SegmentedOasisList<Integer> instance = new SegmentedOasisList<>(2, 2);\n Collection c = Arrays.asList(1, 1, 7, 1, 1, 1, 1);\n instance.addAll(c);\n\n instance.remove(2);\n\n List<Integer> expResult = Arrays.asList(1, 1, 1, 1, 1, 1);\n\n assertTrue(isEqual(expResult, instance));\n\n }",
"public void removeFromSilkBag() {\r\n silkBag.remove(0);\r\n }",
"public Point2D removePoint(int i) {\n\t\tPoint2D p = pointList.remove(i);\n\t\tif (p != null) {\n\t\t\tySum -= p.getY();\n\t\t\tminY = Double.NaN;\n\t\t\tmaxY = Double.NaN;\n\t\t}\n\t\treturn p;\n\t}",
"private void removeweak(final List<Level> levels) {\n \n final List<Integer> removeIdx = Lists.newArrayList();\n\n for (int i = 0; i < (levels.size()); i++) {\n final Level currentLevel = levels.get(i);\n final Float strength = currentLevel.getStrength();\n if (strength.intValue() < STRENGTH) {\n removeIdx.add(i);\n }\n }\n\n CollectionUtils.remove(levels, removeIdx);\n }",
"void unsetUnordered();",
"public Object remove();",
"public static void removeShot(Set set){\n\n Deadwood deadwood = Deadwood.getInstance();\n for(Shot shot : set.getShotList()){\n if(shot.getIcon() != null){\n bPane.remove(shot.getIcon());\n bPane.revalidate();\n bPane.repaint();\n shot.setIcon(null);\n break;\n }\n }\n }",
"public void deleteWerker(Worker w)\n {\n if(aantalWerkers > 0)\n {\n for(int i=0; i<5;i++)\n {\n if(workers[i] == w)\n {\n workers[i] = null;\n }\n }\n w.setInStructure(false);\n aantalWerkers--;\n }\n }",
"@Test\n public void testRemove_Not_Contains() {\n SegmentedOasisList<Integer> instance = new SegmentedOasisList<>();\n instance.add(1);\n\n Integer item = 2;\n boolean expResult = false;\n boolean result = instance.remove(item);\n assertEquals(expResult, result);\n }",
"private void removeDrone(Drone drone){\n\t\tthis.getDroneSet().remove(drone);\n\t}"
] | [
"0.665803",
"0.65674824",
"0.644601",
"0.6310056",
"0.6255559",
"0.62379354",
"0.6188166",
"0.61320335",
"0.60812926",
"0.60692006",
"0.6038585",
"0.60156673",
"0.6012487",
"0.59923023",
"0.5957635",
"0.59173065",
"0.59132123",
"0.59130234",
"0.59130234",
"0.59130234",
"0.59130234",
"0.59130234",
"0.5904242",
"0.59009737",
"0.589468",
"0.5889612",
"0.58888614",
"0.58828384",
"0.58698",
"0.58581793",
"0.58459336",
"0.58251804",
"0.582001",
"0.5803517",
"0.5801401",
"0.5800605",
"0.5792336",
"0.57882583",
"0.5783298",
"0.5748849",
"0.5745437",
"0.5739915",
"0.57309914",
"0.57235694",
"0.5722564",
"0.57124376",
"0.5711319",
"0.57021284",
"0.57021284",
"0.57021284",
"0.57021284",
"0.57021284",
"0.5693495",
"0.56822306",
"0.5680956",
"0.5677829",
"0.56763166",
"0.5671662",
"0.5667122",
"0.56653446",
"0.56646526",
"0.5664539",
"0.5663564",
"0.56579095",
"0.5639559",
"0.5632577",
"0.56290156",
"0.5628091",
"0.5627027",
"0.5618499",
"0.56126827",
"0.5612591",
"0.5605318",
"0.56047595",
"0.5588931",
"0.5588547",
"0.5583867",
"0.55676323",
"0.5565588",
"0.55601823",
"0.55507237",
"0.5550151",
"0.5549229",
"0.55469954",
"0.5546805",
"0.5545625",
"0.55448985",
"0.55446",
"0.5540058",
"0.55384177",
"0.5536074",
"0.5528912",
"0.5525342",
"0.5521959",
"0.5512745",
"0.55106014",
"0.55088437",
"0.5502743",
"0.54970723",
"0.5496119"
] | 0.6787846 | 0 |
Notify towers to shoot all critters in range | public static void shootCritters(){
for(Tower t : towers)
t.shootCritters(CritterManager.getCritters());
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"void fire(WarParticipant target, WarParticipant attacker, int noOfShooters);",
"private void tickPeople() {\n\t\tplayer.tick();\n\t\tfor (Councilman councilman: councilmen) {\n\t\t\tcouncilman.tick();\n\t\t}\n\t}",
"public void fire() {\n\t\t// Has player waited cooldown before trying to fire again?\n\t\tif (System.currentTimeMillis() - this.lastFired > Config.WEAPON_COOLDOWN_TIME * 1000) {\n\t\t\t\n\t\t\t// Can this airship drop bombs?\n\t\t\tif (this.properties.FIRES_TNT) {\n\t\t\t\tBlock[] cannons = getCannons();\n\t\t\t\tint numfiredcannons = 0;\n\t\t\t\tfor (int i = 0; i < cannons.length; i++) {\n\t\t\t\t\tif (cannons[i] != null && cannonHasTnt(cannons[i], Config.NUM_TNT_TO_FIRE_NORMAL)) {\n\t\t\t\t\t\tdouble dist = 0.4;\n\t\t\t\t\t\tBlockFace face = ((Directional) cannons[i].getState().getData()).getFacing();\n\t\t\t\t\t\tint x = face.getModX();\n\t\t\t\t\t\tint z = face.getModZ();\n\t\t\t\t\t\tdist *= getCannonLength(cannons[i], -x, -z);\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (cannons[i].getRelative(x, 0, z).getType().equals(Material.AIR)) {\n\t\t\t\t\t\t\tif (numfiredcannons < this.properties.MAX_NUMBER_OF_CANNONS) {\n\t\t\t\t\t\t\t\tnumfiredcannons++;\n\t\t\t\t\t\t\t\tlastFired = System.currentTimeMillis();\n\t\t\t\t\t\t\t\twithdrawTnt(cannons[i], Config.NUM_TNT_TO_FIRE_NORMAL);\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t// Spawn primed tnt firing in the direction of the dispenser TODO: maybe add sound effects for tnt firing? :P\n\t\t\t\t\t\t\t\tTNTPrimed tnt = cannons[i].getWorld().spawn(cannons[i].getLocation().clone().add(x, 0, z), TNTPrimed.class);\n\t\t\t\t\t\t\t\ttnt.setVelocity(new Vector(x * dist, 0.5, z * dist));\n\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t// More cannons on ship than allowed. Not all fired - can break out of loop now.\n\t\t\t\t\t\t\t\tplayer.sendMessage(ChatColor.AQUA + \"Some cannons did not fire. Max cannon limit is \" + ChatColor.GOLD + this.properties.MAX_NUMBER_OF_CANNONS);\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t} else\n\t\t\t\tplayer.sendMessage(ChatColor.GOLD + this.properties.SHIP_TYPE + \" CANNOT FIRE TNT\");\n\t\t} else\n\t\t\tplayer.sendMessage(ChatColor.GOLD + \"COOLING DOWN FOR \" + ChatColor.AQUA + (int)(Math.round(6 - (System.currentTimeMillis() - this.lastFired) / 1000)) + ChatColor.GOLD + \" MORE SECONDS\");\n\t}",
"private void notifyHit(Ball hitter) {\r\n List<HitListener> listeners = new ArrayList<>(this.getHitListeners());\r\n for (HitListener hl : listeners) {\r\n hl.hitEvent(this, hitter);\r\n }\r\n }",
"private void notifyHit(Ball hitter) {\n // Make a copy of the hitListeners before iterating over them.\n List<HitListener> listeners = new ArrayList<HitListener>(this.hitListeners);\n // Notify all listeners about a hit event:\n for (HitListener hl : listeners) {\n hl.hitEvent(this, hitter);\n }\n }",
"public void someMethod(ArrayList<MakesNoise> pCritters) {\n for (MakesNoise critter : pCritters) {\n critter.makeNoise();\n }\n }",
"void updateEnemies() {\n getEnemies().forEach(e -> {\n if (!e.isAlive()) {\n e.die();\n SoundPlayer.play(SoundPlayer.enemyDestroyed);\n }\n });\n objectsInMap.removeIf(o -> o instanceof Enemy && !(((Enemy) o).isAlive()));//Removing Dead Enemies\n getEnemies().forEach(e -> e.setTarget(objectsInMap.stream().filter(p -> p.identifier.contains(\"PlayerTank0.\") &&\n p.isBlocking && ((Tank) p).isVisible()).collect(Collectors.toList())));//Giving Possible target to enemies to decide\n }",
"public static void doEncounters() {\r\n \t\r\n \tIterator<String> populationIter = population.keySet().iterator();\r\n\t\twhile (populationIter.hasNext()) { \r\n\t String pos = populationIter.next();\r\n\t ArrayList<Critter> critterList = population.get(pos);\r\n\t if(critterList.size() > 1) {\r\n\t \tint[] coords = stringToPos(pos);\r\n\t \t//get the integer value of the coordinates from the String key\r\n\t \tint x_copy = coords[0];\r\n\t \tint y_copy = coords[1];\r\n\t \t\r\n\t \tfor(int i = 0; i < critterList.size(); i++) {\r\n\t \t\tfor (int j = i+1; j < critterList.size(); j++) {\r\n\t \t\t\tCritter A = critterList.get(i);\r\n\t \t\t\tCritter B = critterList.get(j);\r\n\t \t\t\tif(A.getEnergy() > 0 && B.getEnergy() > 0 && A.x_coord == x_copy && A.y_coord == y_copy && B.x_coord == x_copy && B.y_coord == y_copy) {\r\n\t \t\t\t\t\r\n\t \t\t\t\t//Critters A and B are fighting\r\n\t \t\t\t\tA.isFight = true;\r\n\t \t\t\t\tB.isFight = true;\r\n\t \t\t\t\t\r\n\t \t\t\t\t//boolean AWantsToFight = A.fight(B.toString());\r\n\t \t\t\t\t//boolean BWantsToFight = B.fight(A.toString());\r\n\t \t\t\t\tint skillA = 0;\r\n\t \t\t\t\tint skillB = 0;\r\n\t \t\t\t\t\r\n\t \t\t\t\t//determine how A wants to respond\r\n\t \t\t\t\tif(A.fight(B.toString()) == true) {\r\n\t \t\t\t\t\tskillA = getRandomInt(A.energy);\r\n\t \t\t\t\t}\r\n\t \t\t\t\t\r\n\t \t\t\t\t//determine how B wants to respond\r\n\t \t\t\t\tif(B.fight(A.toString()) == true) {\r\n\t \t\t\t\t\tskillB = getRandomInt(B.energy);\r\n\t \t\t\t\t}\r\n\t \t\t\t\tif(A.x_coord == x_copy && B.x_coord == x_copy && A.y_coord == y_copy && B.y_coord == y_copy) {\r\n\t \t\t\t\t\tif(skillA > skillB) { // A wins\r\n\t \t\t\t\t\t\tA.energy += (int) Math.floor(B.energy*1.0*0.5);\r\n\t \t\t\t\t\t\tB.energy = 0;\r\n\t \t\t\t\t\t} else if (skillB > skillA) {\r\n\t \t\t\t\t\t\tB.energy += (int) Math.floor(A.energy*1.0*0.5); //B wins\r\n\t \t\t\t\t\t\tA.energy = 0;\r\n\t \t\t\t\t\t} else {\r\n\t \t\t\t\t\t\tif(getRandomInt(1) == 0) { // A wins\r\n\t\t \t\t\t\t\t\tA.energy += (int) Math.floor(B.energy*1.0*0.5);\r\n\t\t \t\t\t\t\t\tB.energy = 0;\r\n\t \t\t\t\t\t\t} else {\r\n\t\t \t\t\t\t\t\tB.energy += (int) Math.floor(A.energy*1.0*0.5); //B wins\r\n\t\t \t\t\t\t\t\tA.energy = 0;\r\n\t \t\t\t\t\t\t}\r\n\t \t\t\t\t\t}\r\n\t \t\t\t\t}\r\n\t \t\t\t\t\r\n\t \t\t\t\t//Critters A and B have completed their fight\r\n\t \t\t\t\tA.isFight = false;\r\n\t \t\t\t\tB.isFight = false;\r\n\t \t\t\t\t\r\n\t \t\t\t\tcritterList.set(i, A);\r\n\t \t\t\t\tcritterList.set(j, B);\r\n\t \t\t\t}\r\n\t \t\t}\r\n\t \t}\r\n\t \t\r\n\t \t//Iterate through the critters in that position\r\n\t \tIterator<Critter> crittIter = critterList.iterator();\r\n\t \twhile(crittIter.hasNext()) {\r\n\t \t\tCritter c = crittIter.next();\r\n\t \t\t//remove critters who have moved out of that grid position or who have died\r\n\t \t\tif(c.x_coord != x_copy || c.y_coord != y_copy || (c.energy <= 0)) {\r\n\t \t\t\tcrittIter.remove();\r\n\t \t\t}\r\n\t \t}\r\n\t \tpopulation.replace(pos, critterList);\r\n\t }\r\n\t\t}\r\n }",
"public void trackAndFire() {\n \t \tdouble theta;\n double distanciaObjetivo = myPos.distance(objetivo.pos);\n //Hallar el proximo punto en un perímetro definido\n \t\t//(30,30) elimina bordes y despues el -60 para la longitud de los dados\n Rectangle2D.Double perimetro = new Rectangle2D.Double(30, 30, getBattleFieldWidth() - 60, getBattleFieldHeight() - 60);\n \n \n \n //if my cannon is locked and ready and i got some energy left fire with\n //appropiate energy to not get stuck, fire in the execute rather than now\n \n if(getGunTurnRemaining() == 0 && myEnergy > 1) {\n setFire( Math.min(Math.min(myEnergy/6.0, 1000/distanciaObjetivo), objetivo.energy/3.0) );\n }\n \n //any other case, ill get aim lock with this function\n //normalize sets between pi -pi\n setTurnGunRightRadians(Utils.normalRelativeAngle(angulo(objetivo.pos, myPos) - getGunHeadingRadians()));\n \n\n double distNextPunto = myPos.distance(futurePos);\n \n \n if(distNextPunto > 20) {\n \t//aun estamos lejos\n \n \t\t\n \t\t//theta es el angulo que hemos de cortar para ponernos \"encarando\" bien\n theta = angulo(futurePos, myPos) - getHeadingRadians();\n \n \n double sentido = 1;\n \n if(Math.cos(theta) < 0) {\n theta += Math.PI;\n sentido = -1;\n }\n \n setAhead(distNextPunto * sentido);\n theta = Utils.normalRelativeAngle(theta);\n setTurnRightRadians(theta);\n \n if(theta > 1)setMaxVelocity(0.0);\n else setMaxVelocity(8.0); // max\n \n \t\n \n } else {\n \t //ENTRO AQUI SI ME QUEDA POCO PARA LLEGAR, SMOOTH CORNERING\n\n \t\t\n //probar 1000 coordenadas\n int iterNum = 1000;\n Point2D.Double cand;\n for(int i =0; i < iterNum; i++){\n \n //i dont want it to be close to another bot, thats the meaning of distanciaObjetivo*0.8\n cand = hallarPunto(myPos, Math.min(distanciaObjetivo*0.8, 100 + iterNum*Math.random()), 2*Math.PI*Math.random());\n if(perimetro.contains(cand) && evalHeuristic(cand) < evalHeuristic(futurePos)) {\n futurePos = cand;\n }\n \n \n } \n \n prevPos = myPos;\n \n }\n }",
"private void notifyidiots() {\n\t\tfor(Observ g:obslist) {\n\t\t\tg.update();\n\t\t}\n\t}",
"public void update(float delta) {\n\t\tfor(DefenseTower tower : world.getDefenseTowers()) {\n\t\t for(Enemy enemy : world.getEnemies()) {\n\t\t\t if(tower.isPowered() == true && tower.inRange(enemy)) {\n\t\t\t\t\ttower.fireBullets(enemy, delta);\n\t\t\t\t\t//enemy.takeHit(tower.POWER*delta);\n\t\t\t\t\tif(!enemy.isAlive()) {\n\t\t\t\t\t world.getEnemies().removeValue(enemy, false);\n\t\t\t\t\t}\n\t\t\t } \n\t\t\t}\n\t\t}\n\t\n\t\t// Towncentre actions goes here. It shoots enemies here.\n\t\tTownCentre tCentre = world.getTownCentre();\n\t for(Enemy enemy : world.getEnemies()) {\n\t\t if(tCentre.inRange(enemy)) {\n\t\t\t\ttCentre.fireBullets(enemy, delta);\n\t\t\t\t//enemy.takeHit(tCentre.POWER*delta);\n\t\t\t\tif(!enemy.isAlive()) {\n\t\t\t\t world.getEnemies().removeValue(enemy, false);\n\t\t\t\t}\n\t\t } \n\t\t}\n\t \n\t // Soldiers attack enemies here.\n\t for(Soldier s: InstanceManager.getInstance().getSoldiers()) {\n\t \t//s.attackEveryEnemy(delta, InstanceManager.getInstance().getDefenseTowers());\n\t }\n\t\n\t /*for(Enemy enemy : world.getEnemies()) {\n\t\t\tfor(Tower tower : world.getTowers()) {\n\t\t\t if(enemy.inRange(tower)) {\n\t\t\t\t tower.takeHit(enemy.STRENGTH*delta);\n\t\t\t\t //System.out.println(\"tower \" + tower.UID + \"strength is \" + tower.STRENGTH);\n\t\t\t\t if(!tower.isAlive) {\n\t\t\t\t\t \tif(world.getTowers().indexOf(tower, false) !=-1)\n\t\t\t\t\t \t\tactiveTower=-1;\n\t\t\t\t\t world.getTowers().removeValue(tower, false);\n\t\t\t\t\t}\n\t\t\t }\n\t\t\t}\n\t\t\t// This makes townCentre take the hit.\n\t\t\tif(enemy.inRange(tCentre) && tCentre.isAlive) {\n\t\t\t\ttCentre.takeHit(enemy.STRENGTH*delta);\n\t\t\t\t //System.out.println(\"TownCenter \" + tCentre.UID + \"strength is \" + tCentre.STRENGTH);\n\t\t\t}\n\t }*/\n\t\t\n\t // Steams attackers attack towers and links here\n\t sAttackers.AttackTowersAndLinks(delta);\n\t\t\n\t\tfor(Tower tower : world.getTowers()) {\n\t\t tower.update(delta);\n\t\t}\n\t\t\n\t\tfor(Enemy enemy : world.getEnemies()) {\n\t\t enemy.update(delta);\n\t\t if(enemy.getPosition().x > 21 && enemy.getPosition().y > 14)\n\t\t \tworld.getEnemies().removeValue(enemy, false);\n\t\t}\n\t\t\n\t\tfor(Person p: InstanceManager.getInstance().getPeople()) {\n\t\t\tp.update(delta);\n\t\t}\n\t\t\n\t\tfor(Soldier s : InstanceManager.getInstance().getSoldiers()) {\n\t\t\ts.update(delta);\n\t\t}\n\t\t\n\t\t// A lot happens here.\n\t\tInstanceManager.getInstance().update(delta);\n\t\t\n\t\tfor(DefenseTower tower : world.getDefenseTowers()) {\n\t\t\ttower.update(delta);\n\t\t}\n\t\t// If game slows down you can limit updation timing here.\n\t\ttCentre.update(delta);\n\t\tgManager.update(delta);\n\t\tworld.update(delta);\n\t\tsController.update();\n\t\t\n }",
"@Override\n\tpublic void passedBy() {\n\t\tMonopolyGameController.getInstance();\n\t\tMonopolyGameController.getCurrentPlayer().increaseMoney(250);\n\t\tLogger.getInstance().notifyAll(MonopolyGameController.getCurrentPlayer().getName()+ \" gained 250 dollars by landing on Bonus Square\");\n\n\t}",
"public static void hitting(weapon weapon, int howManyTimesYouHit)\n {\n for (int i= 1; i <= howManyTimesYouHit; i++)\n {\n weapon.useCounter();\n weapon.attackDamage();\n }\n }",
"protected abstract void collectFires(Collection<Object> evAndListeners);",
"@Override\r\n\t\t\t\t\t\tpublic void run() {\n\t\t\t\t\t\t\tfor (Damage damage : actionAttack.damages) {\r\n\t\t\t\t\t\t\t\tBattlerSprite attacked = damage.target.getTag();\r\n\t\t\t\t\t\t\t\tattacked.takeHit(damage.damage);\t\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t}",
"public void notifyHit(Ball hitter) {\r\n // Make a copy of the hitListeners before iterating over them.\r\n List<HitListener> listeners = new ArrayList<HitListener>(this.hitListeners);\r\n // Notify all listeners about a hit event:\r\n for (HitListener hl : listeners) {\r\n hl.hitEvent(this, hitter);\r\n }\r\n }",
"public void raise(){\r\n elevatorTalon1.set(basePWM);\r\n elevatorTalon2.set(basePWM * pwmModifier);\r\n }",
"private void updateTerritoriesHold(Player player) {\n getTerritories(player)\n .forEach(Territory::reduceCompetence);\n\n getTerritories(player).stream()\n .filter(Territory::isArmyTotalPowerUnderThreshold)\n .forEach(this::releaseTerritory);\n //Territory::eliminateThisWeakArmy);\n //activateEventsHandler();\n }",
"public void fire() {\n \tintakeTalon1.set(1);\n \tintakeTalon2.set(1);\n }",
"public void notifyAllTimePassed() {\r\n // Make a copy of the Sprites before iterating over them.\r\n List<Sprite> spritesCopy = new ArrayList<Sprite>(this.sprites);\r\n for (Sprite s : spritesCopy) {\r\n s.timePassed();\r\n }\r\n }",
"public void detectAndSendChanges()\r\n\t{\r\n\t\t super.detectAndSendChanges();\r\n\r\n\t\t for (int i = 0; i < this.crafters.size(); ++i)\r\n\t\t {\r\n\t\t\t ICrafting icrafting = (ICrafting)this.crafters.get(i);\r\n\t\t\t icrafting.sendProgressBarUpdate(this, 0, this.enchantLevels[0]);\r\n\t\t\t icrafting.sendProgressBarUpdate(this, 1, this.enchantLevels[1]);\r\n\t\t\t icrafting.sendProgressBarUpdate(this, 2, this.enchantLevels[2]);\r\n\t\t }\r\n\t}",
"@Override\n public void applyOnHit(LivingEntity user, LivingEntity target, int level, EntityDamageByEntityEvent event) {\n if (Math.random() * 100 > settings.get(CHANCE, level)) return;\n\n final double range = settings.get(RANGE, level);\n final double damage = settings.get(DAMAGE, level);\n final double speed = settings.get(SPEED, level);\n for (Entity entity : user.getNearbyEntities(range, range, range)) {\n if (!(entity instanceof LivingEntity) || Protection.isAlly(user, (LivingEntity)entity)) continue;\n\n ((LivingEntity) entity).damage(damage, user);\n entity.setVelocity(user.getLocation().subtract(entity.getLocation()).toVector().multiply(speed));\n }\n }",
"@Override\n public void chew() {\n MessageUtility.logSound(name,\"Bleats and Stomps its legs, then chews\");\n }",
"public void fireAll() {\n\n\t\tSystem.out.println(\"Round \" + roundNo + \": BEGIN!\");\n\n\t\tfor (Move ready : niceMoves) {\n\t\t\tready.fire();\n\t\t}\n\n\t}",
"public void buildingEffect(LoopManiaWorld world) {\n\n List<BasicEnemy> enemies = world.getEnemies();\n\n for (BasicEnemy e : enemies) {\n // if the enemy is in radius and is in battle\n if (Math.pow((this.getX() - e.getX()), 2) + Math.pow((this.getY() - e.getY()), 2) < Math.pow(TOWER_RADIUS,\n 2) && e.isInBattle()) {\n int beforeHealth = e.getHealth();\n e.setHealth(beforeHealth - DAMAGE);\n }\n }\n }",
"@Override\n public void update() {\n for (Integer i : arrAttack) {\n //System.out.println(scene.entityManager.getEntityByID(i).getName());\n\n //if the weapon has not a -1\n if (scene.entityManager.getEntityComponentInstance(i, Tool.class).currentActive != - 1) {\n\n ArrayList<AttackCollider> arrColliders = scene.entityManager.getEntityComponentInstance(i, attackComponent.getClass()).arrColliders;\n\n //Check if it collides with a collidable entity\n for (Integer j : arrCollidable) {\n //if they are not the same and i is not a weapon of j, and if j is alive\n if (!Objects.equals(i, j) && !isWeaponOf(i, j) && scene.entityManager.getEntityComponentInstance(j, Playable.class).isAlive) {\n\n //for each collider that collides with the entity\n for (AttackCollider k : checkAttack(i, j)) {\n //Do something to the collidable entity\n executeAttack(i, j);\n }\n }\n }\n }\n }\n initializeEntities();\n }",
"@Override\r\n\tpublic void notifyTurnEnded() {\r\n\t\tupdateAllTerritories();\r\n\t\t\r\n\t}",
"public void fireScourge() {\n\t\t// Has player waited cooldown before trying to fire again?\t\tCHANGED to 10000\n\t\tif (System.currentTimeMillis() - this.lastFired > Config.WEAPON_COOLDOWN_TIME * 10000) {\n\t\t\tSystem.out.println(player.getDisplayName() + \" is attempting to launch napalm\");\n\t\t\t// Can this airship drop scourge?\n\t\t\tif (this.properties.FIRES_SCOURGE) {\n\t\t\t\tBlock[] cannons = getCannons();\n\t\t\t\tint numfiredcannons = 0;\n\t\t\t\tfor (int i = 0; i < cannons.length; i++) {\n\t\t\t\t\tif (cannons[i] != null && cannons[i].getRelative(0, -1, 0).getType().equals(Material.AIR) && cannonHasTnt(cannons[i], Config.NUM_TNT_TO_DROP_NAPALM)) {\n\t\t\t\t\t\tboolean missingMaterial = false;\n\t\t\t\t\t\tfor (int id : Config.MATERIALS_NEEDED_FOR_SCOURGE) {\n\t\t\t\t\t\t\tif (!cannonHasItem(cannons[i], id, 1))\n\t\t\t\t\t\t\t\tmissingMaterial = true;\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (!missingMaterial && numfiredcannons < this.properties.MAX_NUMBER_OF_CANNONS) {\n\t\t\t\t\t\t\tnumfiredcannons++;\n\t\t\t\t\t\t\tlastFired = System.currentTimeMillis();\n\t\t\t\t\t\t\twithdrawTnt(cannons[i], Config.NUM_TNT_TO_DROP_SCOURGE);\n\t\t\t\t\t\t\tfor (int id : Config.MATERIALS_NEEDED_FOR_SCOURGE) {\n\t\t\t\t\t\t\t\twithdrawItem(cannons[i], id, 1);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t// Fire some scourge TODO: maybe add sound effects for scourge dropping? :P\n\t\t\t\t\t\t\tnew Scourge(cannons[i]);\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t// More cannons on ship than allowed. Not all fired - can break out of loop now.\n\t\t\t\t\t\t\t//player.sendMessage(ChatColor.AQUA + \"Some purifiers did not fire. Max cannon limit is \" + ChatColor.GOLD + this.properties.MAX_NUMBER_OF_CANNONS);\n\t\t\t\t\t\t\tplayer.sendMessage(ChatColor.AQUA + \"Some purifiers did not fire. item check = \" + ChatColor.GOLD + missingMaterial);\n\t\t\t\t\t\t\tplayer.sendMessage(ChatColor.AQUA + \"numFiredCannons = \" + ChatColor.GOLD + numfiredcannons);\n\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t} else\n\t\t\t\tplayer.sendMessage(ChatColor.GOLD + this.properties.SHIP_TYPE + \" CANNOT DROP NAPALM\");\n\t\t} else\n\t\t\tplayer.sendMessage(ChatColor.GOLD + \"COOLING DOWN FOR \" + ChatColor.AQUA + (int)(Math.round(6 - (System.currentTimeMillis() - this.lastFired) / 1000)) + ChatColor.GOLD + \" MORE SECONDS\");\n\t}",
"@Override\r\n\tpublic void onThink() {\n\t\tint random = (shotsFired + 1) % 3 - 1;\r\n\t\tVacuumProjectile projectile = new VacuumProjectile(DAMAGE * this.owner.finalDamageOutputModifier, SPEED, this.owner.direction, Point.add(this.owner.gridLoc, new Point(0, random)), this.owner.teamID);\r\n\t\tthis.getMap().addGameElement(projectile);\r\n\t\tthis.shotsFired++;\r\n\t\tif(this.shotsFired >= NUM_SHOTS) {\r\n\t\t\tthis.finishSpell();\r\n\t\t}\r\n\t}",
"@Override\r\n\tpublic void run() {\r\n\t\t\r\n\t\tif (this.pluginInstance.isPaused(CullType.DAMAGE)) {\r\n\t\t\treturn;\r\n\t\t}\r\n\r\n\t\tint damage_calls = this.pluginInstance.getDamageCalls();\r\n\t\t\r\n\t\tfor (int i = 0; i < damage_calls; i++)\r\n\t\t{\r\n\t\t\tEntityLimitPair entityLimitPair = this.pluginInstance.getNextEntity();\r\n\t\t\t\r\n\t\t\tif (entityLimitPair == null) {\r\n\t\t\t\treturn;\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\tEntity entity = entityLimitPair.getEntity();\r\n\t\t\t\r\n\t\t\tif (entity == null || entity.isDead()) {\r\n\t\t\t\treturn;\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\tConfigurationLimit limit = entityLimitPair.getLimit();\r\n\t\t\t\r\n\t\t\tif (limit.getCulling() != CullType.DAMAGE) {\r\n\t\t\t\treturn;\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\tRandom random = new Random();\r\n\t\t\t\r\n\t\t\t// Loop through entities in range and count similar entities.\r\n\t\t\tint count = 0;\r\n\t\t\t\r\n\t\t\tfor (Entity otherEntity : entity.getNearbyEntities(limit.getRange(), limit.getRange(), limit.getRange())) {\r\n\t\t\t\tif (0 == otherEntity.getType().compareTo(entity.getType())) {\r\n\t\t\t\t\t\r\n\t\t\t\t\tcount += 1;\r\n\t\t\t\t\t\r\n\t\t\t\t\t// If we've reached a limit for this entity, go ahead and damage it.\r\n\t\t\t\t\tif (count >= limit.getLimit()) {\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\tif (random.nextInt(100) < this.pluginInstance.getDamageChance()) {\r\n\t\t\t\t\t\t\tthis.pluginInstance.damageEntity(entity, this.pluginInstance.getDamage());\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\treturn;\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t}",
"private void observerStuff() {\r\n\t\tfor (PirateShip pirate : pirates) {\r\n\t\t\tship.registerObserver(pirate);\r\n\t\t}\r\n\t}",
"void collide() {\n for (Target t : this.helicopterpieces) {\n if (!t.isHelicopter && ((t.x == this.player.x && t.y == this.player.y)\n || (t.x == this.player2.x && t.y == this.player2.y))) {\n this.collected--;\n t.isCollected = true;\n }\n if (t.isHelicopter && this.collected == 1\n && ((t.x == this.player.x && t.y == this.player.y) || (t.isHelicopter\n && this.collected == 1 && t.x == this.player2.x && t.y == this.player2.y))) {\n this.collected = 0;\n this.helicopter.isCollected = true;\n }\n }\n }",
"public static void worldTimeStep() {\n\t\t\n\t//Do time step for all critters\n\t\tfor (Critter c: population) {\n\t\t\tc.doTimeStep();\t\t\t\n\t\t}\n\t\n\t\t\n\t//Resolve encounters\n\t\tIterator<Critter> it1 = population.iterator();\n\t\tfightMode = true;\n\t\twhile(it1.hasNext())\n\t\t{\n\t\t\tCritter c = it1.next();\n\t\t\tIterator<Critter> it2 = population.iterator();\n\t\t\twhile(it2.hasNext()&&(c.energy > 0)) \n\t\t\t{\t\n\t\t\t\tCritter a =it2.next();\n\t\t\t\tif((c != a)&&(a.x_coord==c.x_coord)&&(a.y_coord==c.y_coord))\n\t\t\t\t{\n\t\t\t\t\tboolean cFighting = c.fight(a.toString());\n\t\t\t\t\tboolean aFighting = a.fight(c.toString());\n\t\t\t\t//If they are both still in the same location and alive, then fight\n\t\t\t\t\tif ((a.x_coord == c.x_coord) && (a.y_coord == c.y_coord) && (a.energy > 0) && (c.energy > 0)) {\t\t\n\t\t\t\t\t\tint cFight=0;\n\t\t\t\t\t\tint aFight=0;\n\t\t\t\t\t\tif(cFighting)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tcFight = getRandomInt(100);\n\t\t\t\t\t\t\tcFight++;\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif(aFighting)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\taFight =getRandomInt(100);\n\t\t\t\t\t\t\taFight++;\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif(cFight>aFight)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tc.energy+=(a.energy/2);\n\t\t\t\t\t\t\t//it2.remove();\n\t\t\t\t\t\t\ta.energy=0;\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse if(aFight>cFight)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\ta.energy+=(c.energy/2);\n\t\t\t\t\t\t\t//it1.remove()\n\t\t\t\t\t\t\tc.energy=0;\t\t\t\t\t\t\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tif(aFight>50)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\ta.energy+=(c.energy/2);\n\t\t\t\t\t\t\t\t//it1.remove();\n\t\t\t\t\t\t\t\tc.energy=0;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tc.energy+=(a.energy);\n\t\t\t\t\t\t\t\t//it2.remove();\n\t\t\t\t\t\t\t\ta.energy=0;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tfightMode = false;\n\t\t\n\t//Update rest energy and reset hasMoved\n\t\tfor (Critter c2: population) {\n\t\t\tc2.hasMoved = false;\n\t\t\tc2.energy -= Params.rest_energy_cost;\n\t\t}\n\t\t\n\t//Spawn offspring and add to population\n\t\tpopulation.addAll(babies);\n\t\tbabies.clear();\n\t\t\n\t\tIterator<Critter> it3 = population.iterator();\n\t\twhile(it3.hasNext())\n\t\t{\n\t\t\tif(it3.next().energy<=0)\n\t\t\t\tit3.remove();\n\t\t}\n\t//Create new algae\n\t\tfor (int i = 0; i < Params.refresh_algae_count; i++) {\n\t\t\ttry {\n\t\t\t\tmakeCritter(\"Algae\");\n\t\t\t} catch (InvalidCritterException e) {\n\t\t\t\te.printStackTrace();\n\t\t\t}\n\t\t}\n\t}",
"@Override\n\tpublic void notifyAllObservers() {\n\t\tmyTurtle.notifyObservers();\n\t}",
"private void iterateEnemyShots() {\n\t\tfor (Shot s : enemyShotList) {\n\t\t\tfor (ArrayList<Invader> row : enemyArray) {\n\t\t\t\tfor(Invader a : row) {\n\t\t\t\t\ta.shouldAttack(s);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}",
"private void pollAllWatchersOfThisTile() {\n/* 1287 */ for (VirtualZone vz : getWatchers()) {\n/* */ \n/* */ \n/* */ try {\n/* 1291 */ if (vz.getWatcher() instanceof Player)\n/* */ {\n/* 1293 */ if (!vz.getWatcher().hasLink())\n/* */ {\n/* */ \n/* */ \n/* 1297 */ removeWatcher(vz);\n/* */ }\n/* */ }\n/* */ }\n/* 1301 */ catch (Exception e) {\n/* */ \n/* 1303 */ logger.log(Level.WARNING, e.getMessage(), e);\n/* */ } \n/* */ } \n/* */ }",
"public void trackBullets(){\n // bossbullet control, if it hit the bound, remove the bullet\n for(int i = 0; i < bossBullets.size(); i++){\n Bullet tempBullet = bossBullets.get(i);\n tempBullet.update();\n tempBullet.drawBullet();\n // print (tempBullet.posX, tempBullet.posY,'\\n');\n if(tempBullet.detectBound()){\n bossBullets.remove(i);\n continue;\n }\n\n if(tempBullet.hitObject(Main.player) && !Main.player.invincible){\n Main.player.decreaseHealth(1);\n Main.player.posX = width / 2;\n Main.player.posY = height * 9 / 10;\n Main.player.invincible = true;\n Main.player.invincibleTime = millis();\n }\n\n }\n }",
"private void sendWakeUpCallsToThermostates() {\n\t\tfor (MaxComponent current : config.devices.values()) {\n\t\t\tif (current instanceof Thermostat) {\n\n\t\t\t\tMaxWakeUpMessage wakeup = new MaxWakeUpMessage();\n\t\t\t\twakeup.setFromAdress(config.vCubeAdress);\n\t\t\t\twakeup.setToAdress(current.getAdress());\n\t\t\t\twakeup.setSequenceNumber(new MaxMessageCreator(config).getNewSequnceNumber());\n\t\t\t\tqueueManager.putOutMessage(wakeup);\n\t\t\t\tSystem.out.println(\"Climate Manager - sendWakeUpCalls(): sending wake up message:\\n\" + wakeup);\n\t\t\t}\n\t\t}\n\t}",
"public static void runStats(java.util.List<Critter> critter1s) {\r\n\t\tint averageFear = 0;\r\n\t\tint totalNumberSpawned = 0;\r\n\t\tfor (Critter c : critter1s) {\r\n\t\t\tCritter1 critter = (Critter1) c;\r\n\t\t\taverageFear += critter.fearfullness;\r\n\t\t\ttotalNumberSpawned += critter.numberSpawned;\r\n\t\t}\r\n\t\taverageFear = averageFear/(critter1s.size());\r\n\t\tSystem.out.println(\"Total number of critter1s spawned by the living critter1s: \" + totalNumberSpawned);\r\n\t\tSystem.out.println(\"Average fearfullness of critters1s: \" + averageFear + \"%\");\r\n\t}",
"@Override\n\tpublic void detectAndSendChanges() {\n\t\tsuper.detectAndSendChanges();\n\t\t\n\t\tif (inv != null) {\n\t\t\tfor (int i = 0; i < listeners.size(); ++i) {\n\t\t\t\tIContainerListener icontainerlistener = listeners.get(i);\n\t\t\t\t\n\t\t\t\tif (furnaceBurnTime != inv.getField(0)) {\n\t\t\t\t\ticontainerlistener.sendWindowProperty(this, 0, inv.getField(0));\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\tif (currentItemBurnTime != inv.getField(1)) {\n\t\t\t\t\ticontainerlistener.sendWindowProperty(this, 1, inv.getField(1));\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\tif (cookTime != inv.getField(2)) {\n\t\t\t\t\ticontainerlistener.sendWindowProperty(this, 2, inv.getField(2));\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\tif (totalCookTime != inv.getField(3)) {\n\t\t\t\t\ticontainerlistener.sendWindowProperty(this, 3, inv.getField(3));\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\tfurnaceBurnTime = inv.getField(0);\n\t\t\tcurrentItemBurnTime = inv.getField(1);\n\t\t\tcookTime = inv.getField(2);\n\t\t\ttotalCookTime = inv.getField(3);\n\t\t}\n\t}",
"private void specialPowersPhase() {\n \tSpecialCharacter tmpPiece = null;\n \tTerrain theHex = null;\n\n for (Player p : playerList) {\n pause();\n this.player = p;\n player.flipAllUp();\n ClickObserver.getInstance().setActivePlayer(this.player);\n \n Platform.runLater(new Runnable() {\n @Override\n public void run() {\n Game.getRackGui().setOwner(player);\n }\n });\n /*\n * Loops through all of the hexes that the player has pieces on.\n * If one of the pieces is either Master Thief or Assassin Primus, perform their\n * special ability.\n */\n for (Terrain hex : player.getHexesWithPiece()) {\n for (Piece pc : hex.getContents(player.getName()).getStack()) {\n if (pc.getName().equals(\"Master Thief\") || pc.getName().equals(\"Assassin Primus\")) { \n ((Performable)pc).specialAbility();\n if (MasterThief.isReturnPiece() || AssassinPrimus.isReturnPiece()) {\n \ttmpPiece = (SpecialCharacter)pc;\n \ttheHex = hex;\n \ttmpPiece.returnToBank(theHex);\n \tbreak;\n }\n }\n }\n }\n player.flipAllDown();\n }\n ClickObserver.getInstance().setPlayerFlag(\"\");\n\n Platform.runLater(new Runnable() {\n @Override\n public void run() {\n DiceGUI.getInstance().setFaceValue(0);\n DiceGUI.getInstance().cover();\n }\n });\n }",
"private void addEnemyPowerUps() {\n\t\tfor (int i = 0; i < 4; i++) {\n\t\t\tint x = (int) (Math.random() * 10);\n\t\t\tint y = (int) (Math.random() * 10);\n\n\t\t\twhile (egrid[x][y] != 0) { // prevents overlaps\n\t\t\t\tx = (int) (Math.random() * 10);\n\t\t\t\ty = (int) (Math.random() * 10);\n\t\t\t}\n\n\t\t\tegrid[x][y] = 2;\n\t\t}\n\t}",
"private static void checkForEnemies() throws GameActionException {\n //No need to hijack code for structure\n if (rc.isWeaponReady()) {\n // basicAttack(enemies);\n HQPriorityAttack(enemies, attackPriorities);\n }\n \n //Old splash damage code\n //Preserve because can use to improve current splash damage code\n //But not so simple like just checking directions, since there are many more \n //locations to consider hitting.\n /*if (numberOfTowers > 4) {\n //can do splash damage\n RobotInfo[] enemiesInSplashRange = rc.senseNearbyRobots(37, enemyTeam);\n if (enemiesInSplashRange.length > 0) {\n int[] enemiesInDir = new int[8];\n for (RobotInfo info: enemiesInSplashRange) {\n enemiesInDir[myLocation.directionTo(info.location).ordinal()]++;\n }\n int maxDirScore = 0;\n int maxIndex = 0;\n for (int i = 0; i < 8; i++) {\n if (enemiesInDir[i] >= maxDirScore) {\n maxDirScore = enemiesInDir[i];\n maxIndex = i;\n }\n }\n MapLocation attackLoc = myLocation.add(directions[maxIndex],5);\n if (rc.isWeaponReady() && rc.canAttackLocation(attackLoc)) {\n rc.attackLocation(attackLoc);\n }\n }\n }//*/\n \n }",
"private void notifyStakeholder(){\n }",
"public void notifyMultipleMentions(ArrayList<IStatus> mentions){\n for (ITwitterListener listener:listeners){\n listener.onMultipleMentions(mentions);\n }\n }",
"private void addEnemySheild() {\n this.enemyShield += 1;\n }",
"@Override\n public void notifyRollDice() {\n try {\n if (getClientInterface() != null)\n getClientInterface().notifyHaveToShotDice();\n }\n catch (RemoteException e) {\n System.out.println(\"remote sending have to shot error\");\n }\n }",
"private void shoot(boolean canShoot, java.util.List<Enemy> enemiesInVicinity) {\n if (canShoot) {\n shotEnemy = null;\n if (!enemiesInVicinity.isEmpty()){\n boolean shotEnamies = shootAt(enemyWithLowestHealth(enemiesInVicinity));\n if (shotEnamies) resetCooldown();\n }\n }\n }",
"@Override\n public void performEffectOne(List<Object> targets) {\n checkEmptyTargets(targets);\n ArrayList<Player> roomPlayers = ((Square) targets.get(0)).findRoomPlayers();\n for (Player p : roomPlayers) {\n damage(p, 1);\n getDamagedPlayer().add(p);\n }\n effectControlFlow(1);\n }",
"public synchronized void wakeUpAll() {\n this.timeToWakeUp = true;\n try {\n wait(rand.nextInt(100)+20);\n } catch (InterruptedException e) {\n System.out.println(e);\n }\n notifyAll();\n }",
"@Override\n public void periodic() {\n if(m_Turret.OnTarget()){\n velocity = calculateRPMs();\n pidController.setReference(velocity, ControlType.kVelocity);\n SmartDashboard.putNumber(\"shooter Desired velocity\", velocity );\n SmartDashboard.putNumber(\"shooter Actual velocity\", encoder.getVelocity());\n \n if(atRPM() && accumulator > 100){\n m_Indexer.shooting();\n hasShot = true;\n }\n }else{\n accumulator = 0;\n if(hasShot){\n m_Indexer.endShooting();\n hasShot = false;\n }\n }\n\n SmartDashboard.putBoolean(\"shooter at rpm\", atRPM() && accumulator > 100);\n }",
"private synchronized void sendDecreaceHealth(){\r\n\t\t\tfor(PrintWriter p : players){\r\n\t\t\t\tif(p != null){\r\n\t\t\t\t\tp.println(\"6\");\r\n\t\t\t\t\tp.println(Integer.toString(x));\r\n\t\t\t\t\tp.println(Integer.toString(y));\r\n\t\t\t\t\tp.flush();\r\n\t\t\t\t}else{\r\n\t\t\t\t\treturn;\r\n\t\t\t\t}\r\n\t\t\t\t\r\n\t\t\t}\t\r\n\t\t}",
"public void fireScourgeTorpedo() {\n\t\t// Has player waited cooldown before trying to fire again?\n\t\tif (System.currentTimeMillis() - this.lastFired > Config.WEAPON_COOLDOWN_TIME * 1000) {\n\t\t\tSystem.out.println(player.getDisplayName() + \" is attempting to fire a torpedo\");\n\t\t\t// Can this airship fire torpedoes?\n\t\t\tif (this.properties.FIRES_TORPEDO) {\n\t\t\t\tBlock[] cannons = getCannons();\n\t\t\t\tint numfiredcannons = 0;\n\t\t\t\tfor (int i = 0; i < cannons.length; i++) {\n\t\t\t\t\tif (cannons[i] != null && cannonHasTnt(cannons[i], Config.NUM_TNT_TO_FIRE_SCOURGE_TORPEDO)) {\n\t\t\t\t\t\tBlockFace face = ((Directional) cannons[i].getState().getData()).getFacing();\n\t\t\t\t\t\tboolean missingMaterial = false;\n\t\t\t\t\t\t\n\t\t\t\t\t\tfor (int id : Config.MATERIALS_NEEDED_FOR_SCOURGE_TORPEDO) {\n\t\t\t\t\t\t\tif (!cannonHasItem(cannons[i], id, 1)) {\n\t\t\t\t\t\t\t\tmissingMaterial = true;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (!cannons[i].getRelative(face.getModX(), 0, face.getModZ()).getType().equals(Material.AIR) || missingMaterial)\n\t\t\t\t\t\t\tcontinue;\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (numfiredcannons < this.properties.MAX_NUMBER_OF_CANNONS) {\n\t\t\t\t\t\t\tnumfiredcannons++;\n\t\t\t\t\t\t\tlastFired = System.currentTimeMillis();\n\t\t\t\t\t\t\twithdrawTnt(cannons[i], Config.NUM_TNT_TO_FIRE_SCOURGE_TORPEDO);\n\t\t\t\t\t\t\tfor (int id : Config.MATERIALS_NEEDED_FOR_SCOURGE_TORPEDO) {\n\t\t\t\t\t\t\t\twithdrawItem(cannons[i], id, 1);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t// Fire some torpedoes TODO: maybe add sound effects for tnt firing? :P\n\t\t\t\t\t\t\tnew ScourgeTorpedo(cannons[i], face);\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t// More cannons on ship than allowed. Not all fired - can break out of loop now.\n\t\t\t\t\t\t\t//player.sendMessage(ChatColor.AQUA + \"Some cannons did not fire. Max cannon limit is \" + ChatColor.GOLD + this.properties.MAX_NUMBER_OF_CANNONS);\n\t\t\t\t\t\t\tplayer.sendMessage(ChatColor.AQUA + \"Some missiles did not fire. item check = \" + ChatColor.GOLD + missingMaterial);\n\t\t\t\t\t\t\tplayer.sendMessage(ChatColor.AQUA + \"numFiredCannons = \" + ChatColor.GOLD + numfiredcannons);\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t} else\n\t\t\t\tplayer.sendMessage(ChatColor.GOLD + this.properties.SHIP_TYPE + \" CANNOT FIRE TORPEDO\");\n\t\t} else\n\t\t\tplayer.sendMessage(ChatColor.GOLD + \"COOLING DOWN FOR \" + ChatColor.AQUA + (int)(Math.round(6 - (System.currentTimeMillis() - this.lastFired) / 1000)) + ChatColor.GOLD + \" MORE SECONDS\");\n\t}",
"public void detectAndSendChanges() {\n\t\tsuper.detectAndSendChanges();\n\n\t\tfor (int i = 0; i < this.listeners.size(); ++i) {\n\t\t\tIContainerListener containerListener = this.listeners.get(i);\n\n\t\t\tif (this.burnTime != this.inventory.getField(TileEntityGenerator.FIELD_BURN_TIME)) {\n\t\t\t\tcontainerListener.sendWindowProperty(this, TileEntityGenerator.FIELD_BURN_TIME,\n\t\t\t\t\t\tthis.inventory.getField(TileEntityGenerator.FIELD_BURN_TIME));\n\t\t\t}\n\n\t\t\tif (this.currentItemBurnTime != this.inventory.getField(TileEntityGenerator.FIELD_CURRENT_ITEM_BURN_TIME)) {\n\t\t\t\tcontainerListener.sendWindowProperty(this, TileEntityGenerator.FIELD_CURRENT_ITEM_BURN_TIME,\n\t\t\t\t\t\tthis.inventory.getField(TileEntityGenerator.FIELD_CURRENT_ITEM_BURN_TIME));\n\t\t\t}\n\n\t\t\tif (this.curEnergy != this.inventory.getField(TileEntityGenerator.FIELD_CURRENT_ENERGY)) {\n\t\t\t\tcontainerListener.sendWindowProperty(this, TileEntityGenerator.FIELD_CURRENT_ENERGY,\n\t\t\t\t\t\tthis.inventory.getField(TileEntityGenerator.FIELD_CURRENT_ENERGY));\n\t\t\t}\n\t\t}\n\n\t\tthis.burnTime = this.inventory.getField(TileEntityGenerator.FIELD_BURN_TIME);\n\t\tthis.currentItemBurnTime = this.inventory.getField(TileEntityGenerator.FIELD_CURRENT_ITEM_BURN_TIME);\n\t\tthis.curEnergy = this.inventory.getField(TileEntityGenerator.FIELD_CURRENT_ENERGY);\n\t}",
"private void recruitSpecialsPhase() {\n \n Platform.runLater(new Runnable() {\n @Override\n public void run() {\n \tDiceGUI.getInstance().uncover();\n GUI.getDoneButton().setDisable(false);\n }\n });\n \n for (final Player p : playerList) {\n this.player = p;\n player.flipAllUp();\n ClickObserver.getInstance().setActivePlayer(p);\n\n ClickObserver.getInstance().setTerrainFlag(\"\");\n ClickObserver.getInstance().setClickedTerrain(player.getHexesOwned().get(0));\n Platform.runLater(new Runnable() {\n @Override\n public void run() {\n \tClickObserver.getInstance().whenTerrainClicked();\n }\n });\n \n SpecialCharView.setCurrentPlayer(p);\n SpecialCharView.getSpecialButton().activate();\n SpecialCharView.getCharacterGrid().setVisible(false);\n doneClicked = false;\n ClickObserver.getInstance().setTerrainFlag(\"RecruitingSpecialCharacters\");\n\n pause();\n\n Platform.runLater(new Runnable() {\n @Override\n public void run() {\n GUI.getHelpText().setText(player.getName() + \", Try Your Luck At Recruiting A Special Character!\");\n GUI.getRackGui().setOwner(player);\n }\n });\n\n while (isPaused) {\n while (!doneClicked) {\n try { Thread.sleep(100); } catch( Exception e ){ return; }\n }\n try { Thread.sleep(100); } catch( Exception e ){ return; }\n }\n\n Platform.runLater(new Runnable() {\n @Override\n public void run() {\n DiceGUI.getInstance().setFaceValue(0);\n SpecialCharView.getCharacterGrid().setVisible(false);\n Board.removeCovers();\n }\n });\n player.flipAllDown();\n }\n Platform.runLater(new Runnable() {\n @Override\n public void run() {\n \tDiceGUI.getInstance().cover();\n }\n });\n }",
"public void waterAll() {\n\t\tfor (VirtualPet p : shelterPets.values()) {\n\t\t\tp.waterPet();\n\t\t}\n\t}",
"private void updatePlayerClaim(){\n if(chestProgressLevel!=1){\n return; //the chest isnt unlocked!\n }\n\n //count the total players, and the players who unlocked it.\n int totalPlayers = 0;\n int unlockedPlayers = 0;\n for(JuggernautPlayer player: JuggernautGame.getInstance().getPlayers()){\n if(!player.isSurvivor() || !player.isAlive()){\n continue; //they be dead, they dont count! (Juggy also doesnt count, he doesnt get to unlock items)\n }\n totalPlayers++; //+1 total players\n if(player.isSurvivor() && player.getChestBonus(chestID)>=level){\n unlockedPlayers++; //they unlocked it, +1 unlocked players\n }\n }\n\n //all players unlocked it\n if(totalPlayers<=unlockedPlayers && chestProgressLevel==1){\n //lock the chest before respawning.\n lockChest();\n new BukkitRunnable() {\n\n int timeTillRespawn = 3; //3 seconds to respawn a chest\n @Override\n public void run() {\n //runs every second\n for(JuggernautPlayer jp : JuggernautGame.getInstance().getAllPeople()){\n //check if the player is in the radius of the chest (ignore Y)\n if(SkyMathHelper.isInRadius(location, jp.getPlayer().getLocation(), nametagRadius, false)) {\n //show them the hologram. Update if they already have the hologram active.\n //If this chest will not respawn, we tell them \"Good Luck!\" instead of the respawning message.\n if (jp.getLoadedEntities().containsKey(armorstandResetChestID)) {\n if(level==getMaxLevel()){\n jp.updateHologram(armorstandResetChestID, \"\\u00A76Good Luck!\");\n }else {\n jp.updateHologram(armorstandResetChestID, \"\\u00A76Respawning in \" + timeTillRespawn);\n }\n } else {\n if(level==getMaxLevel()) {\n jp.displayHologram(location.getX(), location.getY() + armorstandProgressbarHeight, location.getZ(), \"\\u00A76Good Luck!\", armorstandResetChestID);\n }else{\n jp.displayHologram(location.getX(), location.getY() + armorstandProgressbarHeight, location.getZ(), \"\\u00A76Respawning in \" + timeTillRespawn, armorstandResetChestID);\n }\n }\n }else{\n //they arent in range, so we remove this entity for them\n jp.removeEntities(armorstandResetChestID);\n }\n }\n\n //check if its time to respawn.\n if(timeTillRespawn--<=0){\n //its time! respawn the chest!\n respawnChest();\n for(JuggernautPlayer jp: JuggernautGame.getInstance().getPlayers()){\n //remove the countdown armorstand for all players\n jp.removeEntities(armorstandResetChestID);\n }\n this.cancel(); //cancel this runnable, we no longer need it.\n return;\n }\n }\n }.runTaskTimer(Juggernaut.pluginInstance, 0L, 20L); //every 20 ticks (1s)\n }else{\n //not all players unlocked the item yet. Lets indicate how many did.\n String emptyDisplayText = unlockedPlayers + \"/\" + totalPlayers + \" Claimed\";\n for(JuggernautPlayer JP: JuggernautGame.getInstance().getPlayers()){\n if(!SkyMathHelper.isInRadius(location, JP.getPlayer().getLocation(), nametagRadius, false)){\n //they arent in the radius, so we remove their armorstand again (if they had it).\n if(JP.getLoadedEntities().containsKey(this.armorstandClaimProgressID)) {\n JP.removeEntities(armorstandClaimProgressID);\n }\n continue;\n }\n\n //generate the color of the display text we need to show them. green if they claimed it, otherwise red.\n String displayText;\n if(JP.getChestBonus(chestID)>=level){\n displayText = \"\\u00A72\" + emptyDisplayText;\n }else{\n displayText = \"\\u00A7c\" + emptyDisplayText;\n }\n\n //update, or show the hologram to them.\n if(JP.getLoadedEntities().containsKey(this.armorstandClaimProgressID)){\n JP.updateHologram(armorstandClaimProgressID, displayText);\n }else{\n JP.displayHologram(this.location.getX(), this.location.getY()+this.armorstandClaimProgressHeight, this.location.getZ(), displayText, armorstandClaimProgressID);\n }\n }\n }\n }",
"@Override\n\tpublic void teleopPeriodic() {\n\t\tScheduler.getInstance().run();\n\t\tSmartDashboard.putBoolean(\"Max Intake Extension: \", RobotMap.intakeLifted.get());\n\t\tSmartDashboard.putBoolean(\"Max Lift Extension:\", RobotMap.isAtTop.get());\n\t\tSmartDashboard.putBoolean(\"Min Lift Extension:\", RobotMap.isAtBottom.get());\n\t\tDriveTrain.driveWithJoystick(RobotMap.stick, RobotMap.rd); // Drive\n\t\tTeleOp.RaiseLift(RobotMap.liftTalon, RobotMap.controller); // Raise lift\n\t\tif(RobotMap.controller.getRawAxis(RobotMap.lowerLiftAxis) >= 0.2) {\n\t\tTeleOp.LowerLift(RobotMap.liftTalon, RobotMap.controller);\n\t\t}\n\t\tTeleOp.DropIntake(RobotMap.controller, RobotMap.intakeLifter);\n\t\tTeleOp.spinOut(RobotMap.intakeVictorLeft, RobotMap.controller);\n\t\t//TeleOp.spinnySpinny(RobotMap.intakeVictorLeft, RobotMap.stick);\n\t}",
"public void campaign() {\r\n for (int i = 0; i < this.parties.length; i++) {\r\n while (this.parties[i].makeAction(this.constituencies, this.acts)) {}\r\n }\r\n }",
"public void Update() {\r\n\t\t//if player is near and haven't fired in a while, fire a projectile\r\n\t\tif(!playerNear().equals(\"n\") && j > 250){\r\n\t\t\tfireProjectile(playerNear());\r\n\t\t\tj = 0;\r\n\t\t}\r\n\t\tj++;\r\n\r\n\t\t//COLLISION\r\n\t\tfor(int i = 0; i < AdventureManager.currentRoom.projectiles.size(); i++){ //Checks for collision with player projectiles\r\n\t\t\tif(((AdventureManager.currentRoom.projectiles.get(i).x + 50 > x) && (AdventureManager.currentRoom.projectiles.get(i).x + 50 < x+50) &&(AdventureManager.currentRoom.projectiles.get(i).y + 50> y) &&(AdventureManager.currentRoom.projectiles.get(i).y + 50< y+98) )\r\n\t\t\t\t\t|| ((AdventureManager.currentRoom.projectiles.get(i).x > x) && (AdventureManager.currentRoom.projectiles.get(i).x < x+50) &&(AdventureManager.currentRoom.projectiles.get(i).y + 50> y) &&(AdventureManager.currentRoom.projectiles.get(i).y + 50< y+98) )\r\n\r\n\t\t\t\t\t\t) {\r\n\r\n\t\t\t\t\tswitch(AdventureManager.currentRoom.projectiles.get(i).type) {\r\n\t\t\t\t\tcase \"fireball\": health -= AdventureManager.toon.intelligence; break;\r\n\t\t\t\t\tcase \"sword\": health -= AdventureManager.toon.strength;\r\n\t\t\t\t\t}\r\n\t\t\t\t\t\r\n\t\t\t\t\tAdventureManager.currentRoom.projectiles.get(i).kill();\r\n\t\t\t\t}\r\n\t\t}\r\n\t\tif((AdventureManager.toon.y < y+50) && (AdventureManager.toon.y > y+40) && //Checks for collision with player\r\n\t\t\t\t(((AdventureManager.toon.x > x) && (AdventureManager.toon.x < x+50))\r\n\t\t\t\t|| ((AdventureManager.toon.x+50 > x) && AdventureManager.toon.x+50 < x+50))) {\r\n\t\t\tAdventureManager.toon.y = y+55; AdventureManager.toon.repaint();\r\n\t\t\tif(contact <= 0){\r\n\t\t\t\tAdventureManager.toon.damage(1);\r\n\t\t\t\tcontact = 50;\r\n\t\t\t}\r\n\t\t}\r\n\t\telse if((AdventureManager.toon.y+100 < y) && (AdventureManager.toon.y+100 > y-5) && (((AdventureManager.toon.x >= x) && (AdventureManager.toon.x <= x+50)) //Checks for collision with player\r\n\t\t\t\t|| ((AdventureManager.toon.x+50 >= x) && (AdventureManager.toon.x+50 <= x+50))\r\n\t\t\t\t|| ((AdventureManager.toon.x+25 >= x) && AdventureManager.toon.x+25 <= x+50))) {\r\n\t\t AdventureManager.toon.y = y-105; AdventureManager.toon.repaint();\r\n\t\t AdventureManager.toon.jumpCount = 25;\r\n\t\t if(contact <= 0){\r\n\t\t\t AdventureManager.toon.damage(1);\r\n\t\t\t contact = 50;\r\n\t\t }\r\n\t\t}\r\n\t\telse if(((AdventureManager.toon.x + 50) > x) && ((AdventureManager.toon.x+50)<x+20) && ( //Left Collision\r\n\t\t\t\t((AdventureManager.toon.y > y) && (AdventureManager.toon.y < y+50)) ||\r\n\t\t\t\t((AdventureManager.toon.y + 25 > y) && (AdventureManager.toon.y + 25 < y+45)) ||\r\n\t\t\t\t((AdventureManager.toon.y + 50 > y) && (AdventureManager.toon.y + 50 < y+45)) ||\r\n\t\t\t\t((AdventureManager.toon.y + 75 > y) && (AdventureManager.toon.y + 75 < y+45)) ||\r\n\t\t\t\t((AdventureManager.toon.y + 100 > y) && (AdventureManager.toon.y + 100 < y+45))\r\n\r\n\r\n\t\t\t\t) ) {\r\n\t\t\tAdventureManager.toon.x = x-51; AdventureManager.toon.repaint();\r\n\t\t\tif(contact <= 0){\r\n\t\t\t\tAdventureManager.toon.damage(1);\r\n\t\t\t\tcontact = 50;\r\n\t\t\t}\r\n\t\t}\r\n\t\telse if(((AdventureManager.toon.x) > x+40) && ((AdventureManager.toon.x)<x+50) && ( //Right Collision\r\n\t\t\t\t((AdventureManager.toon.y > y) && (AdventureManager.toon.y < y+50)) ||\r\n\t\t\t\t((AdventureManager.toon.y + 25 > y) && (AdventureManager.toon.y + 25 < y+50)) ||\r\n\t\t\t\t((AdventureManager.toon.y + 50 > y) && (AdventureManager.toon.y + 50 < y+50)) ||\r\n\t\t\t\t((AdventureManager.toon.y + 75 > y) && (AdventureManager.toon.y + 75 < y+50)) ||\r\n\t\t\t\t((AdventureManager.toon.y + 100 > y) && (AdventureManager.toon.y + 100 < y+50))\r\n\r\n\r\n\t\t\t\t) ) {\r\n\t\t\tAdventureManager.toon.x = x+51; AdventureManager.toon.repaint();\r\n\t\t\tif(contact <= 0){\r\n\t\t\t\tAdventureManager.toon.damage(1);\r\n\t\t\t\tcontact = 50;\r\n\t\t\t}\r\n\t\t}\r\n\t\tcontact--;\r\n\t\tif(health<=0){\r\n\t\t\tsetVisible(false);\r\n\t\t\talive = false;\r\n\t\t\tAdventureManager.currentRoom.enemies.remove(this);\r\n\t\t}\r\n\r\n\r\n\r\n\t\t\tif((y+100)>=AdventureManager.floorHeight) {\r\n\t\t\t\ty= AdventureManager.floorHeight -100;\r\n\t\t\t\tgravity *= 0;\r\n\r\n\r\n\t\t\t}\r\n\t\t\telse {\r\n\t\t\t\tgravity = 3;}\r\n\r\n\t\t\ty += gravity; setLocation(x,y);\r\n\r\n\t\t\tswitch(movetype) {\r\n\t\t\tcase 0: chasePlayer(); break;\r\n\t\t\tcase 1: randomMove(); break;\r\n\t\t\tcase 2: dontMove(); break;\r\n\t\t\t}\r\n\r\n\t\t\t}",
"void SendScoutBees()\n\t{\n\tint maxtrialindex,i;\n\tmaxtrialindex=0;\n\tfor (i=1;i<FoodNumber;i++)\n\t {\n\t if (trial[i]>trial[maxtrialindex])\n\t maxtrialindex=i;\n\t }\n\tif(trial[maxtrialindex]>=limit)\n\t{\n\t\tinit(maxtrialindex);\n\t}\n\t}",
"@Override\r\n\tpublic void tick(){\n\t\tif(!alert){\r\n\t\t\tif(hostileToPlayer&&closeEnoughToAlert(World.player))\r\n\t\t\t\t{alert=true;target=World.player;}\r\n\t\t}\r\n\t\t\r\n\t\tif(alert&&null!=target){\r\n\t\t\t//For now, advance towards the player\r\n\t\t\tPathfinder.moveTowards(this, target);\r\n\t\t\t\r\n\t\t\t\r\n\t\t\t//If within attacking range but not yet attacking, and not stunned, do so.\r\n\t\t\t\r\n\t\t\t\r\n\t\t\t\r\n\t\t}\r\n\t\t\r\n\t}",
"private void enemyAttack() {\n\t\t\n\t\tRandom rand = new Random();\t\n\t\t\n\t\tint roll = rand.nextInt(101);\n\t\t\n\t\tint sroll = rand.nextInt(101);\n\t\t\n\t\tevents.appendText(e.getName() + \" attacks!\\n\");\n\t\t\n\t\tif(roll <= p.getEV()) { // Player evades\n\t\t\t\n\t\t\tevents.appendText(\"You evaded \"+e.getName()+\"\\'s Attack!\\n\");\n\t\t\t\n\t\t}else if(roll > p.getEV()) { // Player is hit and dies if HP is 0 or less\n\t\t\t\n\t\t\tp.setHP(p.getHP() - e.getDMG());\n\t\t\t\n\t\t\tString newHp = p.getHP()+\"/\"+p.getMaxHP();\n\t\t\t\n\t\t\tString effect = e.getSpecial(); // Stats are afflicted\n\t\t\t\n\t\t\tif(sroll < 51){\n\t\t\t\t\n\t\t\tif(effect == \"Bleed\") { // Bleed Special\n\t\t\t\t\n\t\t\t\tp.setHP(p.getHP() - 100);\n\t\t\t\t\n\t\t\t\tevents.appendText(\"You bleed profusely. - 100 HP\\n\");\n\t\t\t\t\n\t\t\t\tnewHp = String.valueOf(p.getHP()+\"/\"+p.getMaxHP());\n\t\t\t}\n\t\t\tif(effect == \"Break\") { // Break Special \n\t\t\t\t\n\t\t\t\tif(p.getEV()-5>0)\n\t\t\t\t\tp.setEV(p.getEV() - 5);\n\t\t\t\telse\n\t\t\t\t\tp.setEV(0);\n\t\t\t\t\n\t\t\t\tevents.appendText(\"You feel a bone break restricting movement. - 5 EV\\n\");\n\t\t\t\t\n\t\t\t\tString newEV = String.valueOf(p.getEV());\n\t\t\t\t\n\t\t\t\tgev.setText(newEV);\n\t\t\t\t\n\t\t\t}\n\t\t\tif(effect == \"Fear\") { // Fear Special \n\t\t\t\t\n\t\t\t\tif(p.getDMG()-40>0)\n\t\t\t\t\tp.setDMG(p.getDMG() - 40);\n\t\t\t\telse\n\t\t\t\t\tp.setDMG(0);\n\t\t\t\t\n\t\t\t\tevents.appendText(\"A crippling fear rattles your resolve. - 40 DMG\\n\");\n\t\t\t\t\n\t\t\t\tString newDMG = String.valueOf(p.getDMG());\n\t\t\t\t\n\t\t\t\tgdmg.setText(newDMG);\n\t\t\t\t\n\t\t\t}\n\t\t\tif(effect == \"Rend\") { // Rend Special \n\t\t\t\t\n\t\t\t\tif(p.getDMG()-30>0)\n\t\t\t\t\tp.setDMG(p.getDMG() - 30);\n\t\t\t\telse\n\t\t\t\t\tp.setDMG(0);\n\t\t\t\t\n\t\t\t\tif(p.getEV()-5>0)\n\t\t\t\t\tp.setEV(p.getEV() - 5);\n\t\t\t\telse\n\t\t\t\t\tp.setEV(0);\n\t\t\t\t\n\t\t\t\tevents.appendText(\"Morthar unleashes a pillar of flame! - 30 DMG and - 5 EV\\n\");\n\t\t\t\t\n\t\t\t\tString newDMG = String.valueOf(p.getDMG());\n\t\t\t\t\n\t\t\t\tString newEV = String.valueOf(p.getEV());\n\t\t\t\t\n\t\t\t\tgdmg.setText(newDMG);\n\t\t\t\t\n\t\t\t\tgev.setText(newEV);\n\t\t\t}\n\t\t\t\n\t\t}\n\t\t\t\n\t\t\tif(p.getHP() <= 0) {\n\t\t\t\t\n\t\t\t\tp.setDead(true);\n\t\t\t\t\n\t\t\t\tcurrentHp.setText(0+\"/\"+e.getMaxHP());\n\t\t\t\tplayerHPBar.setProgress((double)0);\n\t\t\t}else {\n\t\t\t\t\n\t\t\t\tcurrentHp.setText(newHp);\n\t\t\t\tplayerHPBar.setProgress((double)p.getHP()/p.getMaxHP());\n\t\t\t}\n\t\t\t\n\t\t}\n\t\t\n\t\tif(p.isDead()) { // Game over if player dies\n\t\t\t\n\t\t\ttry {\n\t\t\t\tLoadGO();\n\t\t\t} catch (IOException e1) {\n\t\t\t\n\t\t\t\te1.printStackTrace();\n\t\t\t}\n\t\t\t\n\t\t\tcombat = false;\n\t\t}\n\t}",
"private void enemiesWillShoot(Graphics2D g2d, GameState state) {\n if (numOfRenderShoot == 75) {\n numOfRenderShoot = 0;\n for (int i = 0; i < state.getEnemyTanks().size(); i++) {\n if (state.getEnemyTanks().get(i).getLocY() < state.getTankLocY() + 500 && state.getEnemyTanks().get(i).getLocY() > state.getTankLocY() - 400 &&\n state.getEnemyTanks().get(i).getLocX() < state.getTankLocX() + 800 && state.getEnemyTanks().get(i).getLocX() > state.getTankLocX() - 500) {\n state.getEnemyMissiles().add(new EnemyMissile(this, state, 10\n , state.getEnemyTanks().get(i)));\n state.getEnemyMissiles().get(state.getEnemyMissiles().size() - 1).missileDirection(state);\n AudioPlayer enemyGunShotSFX = new AudioPlayer(\"sound effects/enemyshot.wav\", 0);\n }\n }\n for (int i = 0; i < state.getEnemyCars().size(); i++) {\n if (state.getEnemyCars().get(i).getLocY() < state.getTankLocY() + 500 && state.getEnemyCars().get(i).getLocY() > state.getTankLocY() - 400 &&\n state.getEnemyCars().get(i).getLocX() < state.getTankLocX() + 800 && state.getEnemyCars().get(i).getLocX() > state.getTankLocX() - 500) {\n state.getEnemyBullets().add(new EnemyBullet(this, state, 20\n , state.getEnemyCars().get(i)));\n state.getEnemyBullets().get(state.getEnemyBullets().size() - 1).bulletDirection(state);\n AudioPlayer enemyGunShotSFX = new AudioPlayer(\"sound effects/enemyshot.wav\", 0);\n }\n }\n for (int i = 0; i < state.getEnemyWallTurrets().size(); i++) {\n if (state.getEnemyWallTurrets().get(i).getLocY() < state.getTankLocY() + 500 && state.getEnemyWallTurrets().get(i).getLocY() > state.getTankLocY() - 400 &&\n state.getEnemyWallTurrets().get(i).getLocX() < state.getTankLocX() + 800 && state.getEnemyWallTurrets().get(i).getLocX() > state.getTankLocX() - 500) {\n state.getEnemyWallTurretMissiles().add(new EnemyWallTurretMissile(this, state, 15\n , state.getEnemyWallTurrets().get(i)));\n state.getEnemyWallTurretMissiles().get(state.getEnemyWallTurretMissiles().size() - 1).missileDirection(state);\n AudioPlayer enemyGunShotSFX = new AudioPlayer(\"sound effects/enemyshot.wav\", 0);\n }\n }\n\n for (int i = 0; i < state.getEnemyTurrets().size(); i++) {\n if (state.getEnemyTurrets().get(i).getLocY() < state.getTankLocY() + 500 && state.getEnemyTurrets().get(i).getLocY() > state.getTankLocY() - 400 &&\n state.getEnemyTurrets().get(i).getLocX() < state.getTankLocX() + 800 && state.getEnemyTurrets().get(i).getLocX() > state.getTankLocX() - 500) {\n state.getEnemyHomingMissiles().add(new EnemyHomingMissile(this, state, 15\n , state.getEnemyTurrets().get(i)));\n state.getEnemyHomingMissiles().get(state.getEnemyHomingMissiles().size() - 1).missileDirection(state);\n AudioPlayer enemyGunShotSFX = new AudioPlayer(\"sound effects/enemyshot.wav\", 0);\n }\n }\n }\n for (EnemyMissile enemyMissile : state.getEnemyMissiles()) {\n enemyMissile.paint(g2d, state);\n }\n for (EnemyBullet enemyBullet : state.getEnemyBullets()) {\n enemyBullet.paint(g2d, state);\n }\n for (EnemyWallTurretMissile enemyWallTurretMissile : state.getEnemyWallTurretMissiles()) {\n enemyWallTurretMissile.paint(g2d, state);\n }\n for (EnemyHomingMissile enemyHomingMissile : state.getEnemyHomingMissiles()) {\n enemyHomingMissile.paint(g2d, state);\n }\n }",
"@Override\n public void detectAndSendChanges() {\n super.detectAndSendChanges();\n\n final int newStoredFuel = this.tileAdvancedFurnace.getStoredFuel();\n final int newSmeltTime = this.tileAdvancedFurnace.getRemainingSmeltTime();\n if ((lastStoredFuel != newStoredFuel) || (lastSmeltTime != newSmeltTime)) {\n this.lastStoredFuel = newStoredFuel;\n this.lastSmeltTime = newSmeltTime;\n for (int i = 0; i < this.crafters.size(); ++i) {\n final ICrafting icrafting = (ICrafting) this.crafters.get(i);\n icrafting.sendProgressBarUpdate(this, UPDATEID_STORED_OPERATIONS, newStoredFuel);\n icrafting.sendProgressBarUpdate(this, UPDATEID_SMELTTIME_REMAINING, newSmeltTime);\n }\n }\n }",
"private static void turretCode() throws GameActionException {\n\t\t//Attack Enemy\n\t\tRobotInfo[] visibleEnemyArray = rc.senseHostileRobots(rc.getLocation(), 1000000);\n\t\tSignal[] incomingSignals = rc.emptySignalQueue();\n\t\tSignal[] signals;\n\t\tif (incomingSignals.length>125) {\n\t\t\tsignals = new Signal[125];\n\t\t\tfor(int i=0; i<125; i++) {\n\t\t\t\tsignals[i]=incomingSignals[i];\n\t\t\t}\n\t\t} else {\n\t\t\tsignals = incomingSignals;\n\t\t}\n\t\tboolean unit = false;\n\t\tfor(Signal s:signals){\n\t\t\tint[] message = s.getMessage();\n\t\t\tif(s.getTeam()==rc.getTeam()){\n\t\t\t\tif(message!=null){\n\t\t\t\t\tif(message[0]%10==0){\n\t\t\t\t\t\tcenter = s.getLocation();\n\t\t\t\t\t\tint r = message[0]/10;\n\t\t\t\t\t\tradius=r;\n\t\t\t\t\t}else{\n\t\t\t\t\t\tunit=true;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t\n\t\tif (visibleEnemyArray.length > 0 || unit) {\n\t\t\tif (rc.isWeaponReady()) {\n\t\t\t\trc.attackLocation(Utility.toAttack(visibleEnemyArray, incomingSignals));\n\t\t\t}\n\t\t}else{\n\t\t\tMapLocation travel=turretFind();\n\t\t\tif(travel!=rc.getLocation()){\n\t\t\t\tgoal = travel;\n\t\t\t\trc.pack();\n\t\t\t}\n\t\t}\t\t\t\n\t}",
"public void walkAllDogs() {\n\t\thappiness += 10;\n\t\thealth += 8;\n\t\tplay += 5;\n\t}",
"@Override\n\tprotected void onPlayerDamage(EntityDamageEvent evt, Player p) {\n\t\tsuper.onPlayerDamage(evt, p);\n\t\tif(evt.getCause() == DamageCause.WITHER){\n\t\t\tGUtils.healDamageable(getOwnerPlayer(), evt.getDamage() * 1.5);\n\t\t\tVector v = Utils.CrearVector(getOwnerPlayer().getLocation(), getPlayer().getLocation()).multiply(0.5D);\n\t\t\tdouble max = 7;\n\t\t\tfor (int i = 0; i < max; i++) {\n//\t\t\t\tgetWorld().playEffect(getPlayer().getEyeLocation().add(0, -0.8, 0).add(v.clone().multiply(i/max)),\n//\t\t\t\t\t\tEffect.HEART, 0);\n\t\t\t}\n\t\t}\n\t}",
"private void calculateCrit(Monster target, MonsterParts part, Weapon weapon, double motionValue) throws InvalidPartException {\n \n if (target.isWeakness(part)) {\n if (Math.random() < (Math.abs((weapon.getAffinity() + weaknessExploit)/100.0)) && (weapon.getAffinity() + weaknessExploit) < 0) {\n critDamage -= weapon.getAttack()/weapon.getInflation() * 0.25 * weapon.getRawSharpness() * target.getPartMultiplierRaw(part, weapon) * motionValue;\n }\n if (Math.random() < ((weapon.getAffinity() + weaknessExploit)/100.0) && (weapon.getAffinity() + weaknessExploit) > 0) {\n critDamage += weapon.getAttack()/weapon.getInflation() * (0.25 + critBoost/100.0) * weapon.getRawSharpness() *target.getPartMultiplierRaw(part, weapon) * motionValue;\n if (criticalElement) {\n elementalCritDamage += weapon.getElementStatusDmg()/10 * 0.25 * weapon.getElementalSharpness() * target.getPartMultiplierElemental(part, weapon);\n }\n }\n } else {\n if (Math.random() < (Math.abs(weapon.getAffinity()/100.0)) && weapon.getAffinity() < 0) {\n critDamage -= weapon.getAttack()/weapon.getInflation() * 0.25 * weapon.getRawSharpness() * target.getPartMultiplierRaw(part, weapon) * motionValue;\n }\n if (Math.random() < (weapon.getAffinity()/100.0) && weapon.getAffinity() > 0) {\n critDamage += weapon.getAttack()/weapon.getInflation() * (0.25 + critBoost/100.0) * weapon.getRawSharpness() * target.getPartMultiplierRaw(part, weapon) * motionValue;\n if (criticalElement) {\n elementalCritDamage += weapon.getElementStatusDmg()/10 * 0.25 * weapon.getElementalSharpness() * target.getPartMultiplierElemental(part, weapon);\n }\n }\n }\n\n }",
"public void tensionRangeCheck(){\n if(motor.get() < 0){\n if(Bottom_Limit_Switch.get() | tenPot.pidGet()> tenPotMAX ){\n motor.set(0.0);\n }\n }else if(motor.get() > 0){\n if(Top_Limit_Switch.get() | tenPot.pidGet()< tenPotMIN){\n motor.set(0.0);\n }\n }\n }",
"public void notifyObservers(){\n for (GameObserver g: observers){\n g.handleUpdate(new GameEvent(this,\n currentPlayer,\n genericWorldMap,\n gameState,\n currentTerritoriesOfInterest,\n currentMessage));\n }\n }",
"public void notifyAlienKilled() {\n\t\talienCount--;\n\t\t\n\t\tif (alienCount <= 0) {\n\t\t\tround++;\n\t\t\tif(round % 1 == 0) {\n\t\t\t\tinitBoss();\n\t\t\t}\n\t\t\telse {\n\t\t\t\tinitEntitiesNoShip();\n\t\t\t}\n//\t\t\tnotifyWin();\n\t\t\t// System.out.println(\"Score: \" + score);\n\t\t}\n\t\t\n\t\t// if there are still some aliens left then they all need to get faster, so\n\t\t// speed up all the existing aliens\n\t\tfor (int i=0;i<entities.size();i++) {\n\t\t\tEntity entity = (Entity) entities.get(i);\n\t\t\t\n\t\t\tif (entity instanceof AlienEntity) {\n\t\t\t\t// speed up by 2%\n\t\t\t\tentity.setHorizontalMovement(entity.getHorizontalMovement() * 1.02);\n\t\t\t}\n\t\t}\n\t}",
"public abstract void collector(FloodItWorld w);",
"public void notifyAdmins(){\n \tfor(PlayerHandler player : players){\n \t\tif(player.isAdmin()){\n \t\t\tplayer.notify(1);\n \t\t}\n \t}\n }",
"public static void playerEffectivelyEndsBattlePhase() {\r\n for (int index = 1; index <= 5; index++){\r\n SummonedMonster MonsterCPU = SummonedMonster.getNthSummonedMonster(index, false);\r\n if (MonsterCPU.isExisting) {\r\n MonsterCPU.canStillAttackThisTurn = false;\r\n }\r\n }\r\n endAttack(false);\r\n }",
"private void addCritters(String critter_name, int num) {\n\t\tfor(int i = 0; i<num; i++){\n\t\t\ttry{\n\t\t\t\tCritter.makeCritter(critter_name);\n\t\t\t}catch(InvalidCritterException e){\n\t\t\t\treturn;\n\t\t\t}\n\t\t}\n\t}",
"public void detectAndSendChanges() {\n super.detectAndSendChanges();\n\n for (int var1 = 0; var1 < this.crafters.size(); ++var1) {\n ICrafting var2 = (ICrafting) this.crafters.get(var1);\n\n if (this.brewTime != this.tileBrewingStand.getField(0)) {\n var2.sendProgressBarUpdate(this, 0, this.tileBrewingStand.getField(0));\n }\n }\n\n this.brewTime = this.tileBrewingStand.getField(0);\n }",
"private void combatPhase() {\n \t\n \tpause();\n \tDice.setFinalValMinusOne();\n\n \t// Go through each battle ground a resolve each conflict\n \tfor (Coord c : battleGrounds) {\n \t\t\n \tClickObserver.getInstance().setTerrainFlag(\"\");\n \t\n \tSystem.out.println(\"Entering battleGround\");\n \t\tfinal Terrain battleGround = Board.getTerrainWithCoord(c);\n \t\t\n \t\t// find the owner of terrain for post combat\n \tPlayer owner = battleGround.getOwner();\n \t\n \t\t// simulate a click on the first battleGround, cover all other terrains\n \t\tClickObserver.getInstance().setClickedTerrain(battleGround);\n \t\tPlatform.runLater(new Runnable() {\n @Override\n public void run() {\n \t\tClickObserver.getInstance().whenTerrainClicked();\n \t\tBoard.applyCovers();\n \t\tClickObserver.getInstance().getClickedTerrain().uncover();\n \tClickObserver.getInstance().setTerrainFlag(\"Disabled\");\n }\n });\n \t\t\n \t\t// Get the fort\n \t Fort battleFort = battleGround.getFort(); \n \t\t\n \t\t// List of players to battle in the terrain\n \t\tArrayList<Player> combatants = new ArrayList<Player>();\n \t\t\n \t\t// List of pieces that can attack (including forts, city/village)\n \t\tHashMap<String, ArrayList<Piece>> attackingPieces = new HashMap<String, ArrayList<Piece>>();\n \t\t\n \t\tSystem.out.println(battleGround.getContents().keySet());\n \t\t\n \t\tIterator<String> keySetIterator = battleGround.getContents().keySet().iterator();\n\t \twhile(keySetIterator.hasNext()) {\n\t \t\tString key = keySetIterator.next();\n\t \t\t\n \t\t\tcombatants.add(battleGround.getContents().get(key).getOwner());\n \t\t\tattackingPieces.put(battleGround.getContents().get(key).getOwner().getName(), (ArrayList<Piece>) battleGround.getContents().get(key).getStack().clone()); \n \t\t\t\n\t \t}\n\t \t\n\t \t\n\t \t\n\t \t// if the owner of the terrain has no pieces, just a fort or city/village\n\t\t\tif (!combatants.contains(battleGround.getOwner()) && battleFort != null) {\n\t\t\t\tcombatants.add(battleGround.getOwner());\n\t\t\t\tattackingPieces.put(battleGround.getOwner().getName(), new ArrayList<Piece>());\n\t\t\t}\n\n \t\t// add forts and city/village to attackingPieces\n \t\tif (battleFort != null) {\n \t\t\tattackingPieces.get(battleGround.getOwner().getName()).add(battleFort);\n \t\t}\n \t\t\n \t\tkeySetIterator = attackingPieces.keySet().iterator();\n\t \twhile (keySetIterator.hasNext()) {\n\t \t\tString key = keySetIterator.next();\n\t \t\t\n\t \t\tfor (Piece p : attackingPieces.get(key)) {\n\t \t\t\tif (p.getName().equals(\"Baron Munchhausen\") || p.getName().equals(\"Grand Duke\")) {\n\t \t\t\t\tif (p.getOwner() != battleGround.getOwner())\n\t \t\t\t\t\t((Performable)p).specialAbility();\n\t \t\t\t}\n\t \t\t\t\t\n\t \t\t}\n\t \t}\n \t\t// TODO implement city/village\n// \t\tif (City and village stuff here)\n \t\tSystem.out.println(combatants);\n \t\t\n \t\tboolean exploring = (!battleGround.isExplored() && battleGround.getContents().size() == 1);\n \t\t// Fight until all attackers are dead, or until the attacker becomes the owner of the hex\n \t\twhile (combatants.size() > 1 || exploring) {\n \t\t\t\n /////////////Exploration\n \t// Check if this is an exploration battle:\n \t\t// Must fight other players first\n \t\t\tboolean fightingWildThings = false;\n \tif (exploring) {\n\n \t\t\t\t// Set the battleGround explored\n \t\t\t\tbattleGround.setExplored(true);\n \t\n \t\tString exploringPlayer = null;\n \t\tIterator<String> keySetIter = battleGround.getContents().keySet().iterator();\n \t \twhile(keySetIter.hasNext()) {\n \t \t\tString key = keySetIter.next();\n \t \t\texploringPlayer = key;\n \t \t}\n \t\tplayer = battleGround.getContents(exploringPlayer).getOwner();\n \t\tplayer.flipAllUp();\n \t \t\n \t\t// Get user to roll die to see if explored right away\n \t\t\t\tPlatform.runLater(new Runnable() {\n \t @Override\n \t public void run() {\n \t \tDiceGUI.getInstance().uncover();\n \t \tGUI.getHelpText().setText(\"Attack phase: \" + player.getName() \n \t \t\t\t+ \", roll the die. You need a 1 or a 6 to explore this terrain without a fight!\");\n \t }\n \t\t\t\t});\n \t\t\t\t\n \t// Dice is set to -1 while it is 'rolling'. This waits for the roll to stop, ie not -1\n \t\t\t\tint luckyExplore = -1;\n \t\t\t\twhile (luckyExplore == -1) {\n \t\t\t\t\ttry { Thread.sleep(100); } catch( Exception e ){ return; }\n \t\t\t\t\tluckyExplore = Dice.getFinalVal();\n \t\t\t\t}\n \t\t\t\t\n \t\t\t\t// If success TODO FIX this \n \t\t\t\tif (luckyExplore == 1 || luckyExplore == 6) {\n \t\t\t\t\t\n \t\t\t\t\t// Cover die. Display msg\n \t\t\t\t\tPlatform.runLater(new Runnable() {\n \t\t @Override\n \t\t public void run() {\n \t\t \tDiceGUI.getInstance().cover();\n \t\t \tGUI.getHelpText().setText(\"Attack phase: Congrats!\" + player.getName() \n \t\t \t\t\t+ \"!, You get the terrain!\");\n \t\t }\n \t\t\t\t\t});\n \t\t\t\t\ttry { Thread.sleep(1000); } catch( Exception e ){ return; }\n \t\t\t\t\texploring = false;\n \t\t\t\t\tbreak;\n \t\t\t\t\t\n \t\t\t\t} else { // Else failure. Must fight or bribe\n \t\t\t\t\t\n \t\t\t\t\tfightingWildThings = true;\n \t\t\t\t\t\n \t\t\t\t\t// Cover die. Display msg\n \t\t\t\t\tPlatform.runLater(new Runnable() {\n \t\t @Override\n \t\t public void run() {\n \t\t \tDiceGUI.getInstance().cover();\n \t\t \tbattleGround.coverPieces();\n \t\t \tGUI.getHelpText().setText(\"Attack phase: Boooo!\" + player.getName() \n \t\t \t\t\t+ \"!, You have to bribe, or fight for your right to explore!\");\n \t\t }\n \t\t\t\t\t});\n \t\t\t\t\ttry { Thread.sleep(1000); } catch( Exception e ){ return; }\n \t\t\t\t\t\n \t\t\t\t\t// add luckyExplore amount of pieces to terrain under wildThing player\n \t\t\t\t\tfinal ArrayList<Piece> wildPieces = TheCup.getInstance().draw(luckyExplore);\n \t\t\t\t\t\t\n \t\t\t\t\t// Update the infopanel with played pieces. Active done button\n \t\t\t\t\tPlatform.runLater(new Runnable() {\n \t\t @Override\n \t\t public void run() {\n \t\t \twildThings.playWildPieces(wildPieces, battleGround);\n \t\t GUI.getDoneButton().setDisable(false);\n \t\t battleGround.coverPieces();\n \t\t \tInfoPanel.showTileInfo(battleGround);\n \t\t \n \t\t }\n \t\t\t\t\t});\n \t\t\t\t\ttry { Thread.sleep(100); } catch( Exception e ){ return; }\n \t\t\t\t\t\n \t\t\t\t\t//////Bribing here\n \t\t\t\t\tpause();\n \t\t\t\t\tClickObserver.getInstance().setCreatureFlag(\"Combat: SelectCreatureToBribe\");\n \t\t\t\t\t\n \t\t\t\t\t// Uncover the pieces that the player can afford to bribe\n \t\t\t\t\t// canPay is false if there are no Pieces that the user can afford to bribe\n \t\t\t\t\tboolean canPay = false;\n \t\t\t\t\tfor (final Piece p : battleGround.getContents(wildThings.getName()).getStack()) {\n \t\t\t\t\t\tif (((Combatable)p).getCombatValue() <= player.getGold()) {\n \t\t\t\t\t\t\tcanPay = true;\n \t\t\t\t\t\t\tPlatform.runLater(new Runnable() {\n \t\t\t\t @Override\n \t\t\t\t public void run() {\n \t\t\t\t \tp.uncover();\n \t\t\t\t }\n \t\t\t\t\t\t\t});\n \t\t\t\t\t\t}\n \t\t\t\t\t}\n \t\t\t\t\ttry { Thread.sleep(50); } catch( Exception e ){ return; }\n \t\t\t\t\t\n \t\t\t\t\t// Continue looping until there are no more pieces user can afford to bribe, or user hits done button\n \t\t\t\t\twhile (canPay && isPaused) {\n \t\t\t\t\t\t\n \t\t\t\t\t\tPlatform.runLater(new Runnable() {\n\t \t\t @Override\n\t \t\t public void run() {\n\t \t\t \tGUI.getHelpText().setText(\"Attack phase: \" + player.getName() \n\t \t\t \t\t\t+ \", Click on creatures you would like to bribe\");\n\t \t\t }\n \t\t\t\t\t\t});\n \t\t\t\t\t\t\n \t\t\t\t\t\t// wait for user to hit done, or select a piece\n \t\t\t\t\t\tpieceClicked = null;\n \t\t\t\t\t\twhile(pieceClicked == null && isPaused) {\n \t\t\t\t\t\t\ttry { Thread.sleep(100); } catch( Exception e ){ return; }\n \t\t\t\t\t\t}\n \t\t\t\t\t\tif (pieceClicked != null) {\n \t\t\t\t\t\t\t\n \t\t\t\t\t\t\t// spend gold for bribing. Remove clicked creature\n \t\t\t\t\t\t\tplayer.spendGold(((Combatable)pieceClicked).getCombatValue());\n \t\t\t\t\t\t\t((Combatable)pieceClicked).inflict();\n \t\t\t\t\t\t\t\n \t\t\t\t\t\t\t// cover pieces that are too expensive\n \t\t\t\t\t\t\tPlatform.runLater(new Runnable() {\n \t\t\t\t @Override\n \t\t\t\t public void run() {\n \t\t\t\t \tGUI.getHelpText().setText(\"Attack phase: \" + player.getName() \n \t\t\t \t\t\t+ \" bribed \" + pieceClicked.getName());\n \t\t\t\t \tInfoPanel.showTileInfo(battleGround);\n \t\t\t\t \tif (battleGround.getContents(wildThings.getName()) != null) {\n\t \t\t\t\t for (Piece p : battleGround.getContents(wildThings.getName()).getStack()) {\n\t \t\t\t\t \tif (((Combatable)p).getCombatValue() > player.getGold())\n\t \t\t\t\t \t\tp.cover();\n\t \t\t\t\t }\n \t\t\t\t \t}\n \t\t\t\t }\n \t\t\t\t\t\t\t});\n \t\t\t\t\t\t\ttry { Thread.sleep(100); } catch( Exception e ){ return; }\n \t\t\t\t\t\t\t\n \t\t\t\t\t\t\t// Check if there are any pieces user can afford to bribe and set canPay to true if so\n \t\t\t\t\t\t\tcanPay = false;\n \t\t\t\t\t\t\tif (battleGround.getContents(wildThings.getName()) == null || battleGround.getContents(wildThings.getName()).getStack().size() == 1)\n \t\t\t\t\t\t\t\tbreak;\n \t\t\t\t\t\t\telse {\n\t \t\t\t\t\t\t\tfor (final Piece p : battleGround.getContents(wildThings.getName()).getStack()) {\n\t \t\t\t\t\t\t\t\tif (((Combatable)p).getCombatValue() <= player.getGold()) {\n\t \t\t\t\t\t\t\t\t\tcanPay = true;\n\t \t\t\t\t\t\t\t\t\tbreak;\n\t \t\t\t\t\t\t\t\t}\n\t \t\t\t\t\t\t\t}\n \t\t\t\t\t\t\t}\n \t\t\t\t\t\t\ttry { Thread.sleep(100); } catch( Exception e ){ return; }\n \t\t\t\t\t\t}\n \t\t\t\t\t}\n \t\t\t\t\tPlatform.runLater(new Runnable() {\n\t\t\t @Override\n\t\t\t public void run() {\n\t\t\t \tGUI.getHelpText().setText(\"Attack phase: \" + player.getName() \n\t\t \t\t\t+ \" done bribing\");\n\t\t\t }\n \t\t\t\t\t});\n \t\t\t\t\tSystem.out.println(\"Made it past bribing\");\n \t\t\t\t\ttry { Thread.sleep(1000); } catch( Exception e ){ return; }\n \t\t\t\t\tClickObserver.getInstance().setCreatureFlag(\"Combat: SelectPieceToAttackWith\");\n \t\t\t\t\t\n \t\t\t\t\t// Done bribing, on to fighting\n \t\t\t\t\t\n \t\t\t\t\t// find another player to control wildThings and move on to regular combat\n \t\t\t\t\t// to be used later \n \t\t\t\t\tPlayer explorer = player;\n \t\t\t\t\tPlayer wildThingsController = null;\n \t\t\t\t\tfor (Player p : playerList) {\n \t\t\t\t\t\tif (!p.getName().equals(player.getName()))\n \t\t\t\t\t\t\twildThingsController = p;\n \t\t\t\t\t}\n \t\t\t\t\t\n \t\t\t\t\t// If wild things still has pieces left:\n \t\t\t\t\tif (battleGround.getContents().containsKey(wildThings.getName())) {\n\t \t\t\t\t\tcombatants.add(battleGround.getContents().get(wildThings.getName()).getOwner());\n\t \t \t\t\tattackingPieces.put(wildThings.getName(), (ArrayList<Piece>) battleGround.getContents().get(wildThings.getName()).getStack().clone()); \n \t\t\t\t\t}\n \t\t\t\t}\n \t\t\t\t\n \t\t\t\t// cover pieces again\n \t\t\t\tPlatform.runLater(new Runnable() {\n \t @Override\n \t public void run() {\n \t \tbattleGround.coverPieces();\n \t }\n \t\t\t\t});\n \t\t\t\t\n \t\t\t\tplayer.flipAllDown();\n \t} // end if (exploring)\n \t\t\t\n \t\t\tSystem.out.println(\"combatants.size() > 1 : \" + combatants.size());\n \t\t\tSystem.out.println(combatants);\n \t\t\t\n \t\t\t// This hashMap keeps track of the player to attack for each player\n \t\t\tHashMap<String, Player> toAttacks = new HashMap<String, Player>();\n\n\t\t\t\t// each player selects which other player to attack in case of more than two combatants\n \t\t\tif (combatants.size() > 2) {\n \t\t\t\t\n \t\t\t\tfor (final Player p : combatants) {\n \t\t\t\t\tif (!p.isWildThing()) {\n\t \t \t\tpause();\n\t \t \t\tClickObserver.getInstance().setPlayerFlag(\"Attacking: SelectPlayerToAttack\");\n\t \t \t\tplayer = p;\n\t\t \tPlatform.runLater(new Runnable() {\n\t\t \t @Override\n\t\t \t public void run() {\n\t\t \t \tPlayerBoard.getInstance().applyCovers();\n\t\t \t \tbattleGround.coverPieces();\n\t\t \t \t GUI.getHelpText().setText(\"Attack phase: \" + player.getName()\n\t\t \t + \", select which player to attack\");\n\t\t\t \t \t}\n\t\t \t });\n\t\t \tfor (final Player pl : combatants) {\n\t\t \t\tif (!pl.getName().equals(player.getName())) {\n\t\t \t\t\tPlatform.runLater(new Runnable() {\n\t\t \t \t @Override\n\t\t \t \t public void run() {\n\t\t \t \t \tPlayerBoard.getInstance().uncover(pl);\n\t\t \t \t }\n\t\t \t\t\t});\n\t\t \t\t}\n\t\t \t}\n\t\t \twhile (isPaused) {\n\t\t \ttry { Thread.sleep(100); } catch( Exception e ){ return; } \n\t\t \t }\n\t\t \t\n\t\t \t// ClickObserver sets playerClicked, then unpauses. This stores what player is attacking what player\n\t\t \ttoAttacks.put(p.getName(), playerClicked);\n\t \t \t\tClickObserver.getInstance().setPlayerFlag(\"\");\n\t\t \t\n\t \t \t} \n \t\t\t\t}\n \t\t\t\tcombatants.remove(wildThings);\n \t\t\t\tPlayerBoard.getInstance().removeCovers();\n \t\t\t\t\n \t } else { // Only two players fighting\n \t \t\n \t \tfor (Player p1 : combatants) {\n \t \t\tfor (Player p2 : combatants) {\n \t \t\t\tif (!p1.getName().equals(p2.getName())) {\n \t \t \ttoAttacks.put(p1.getName(), p2);\n \t \t\t\t}\n \t \t\t}\n \t \t}\n \t }\n \t\t\t\n ///////////////////Call out bluffs here:\n \t\t\tbattleGround.flipPiecesUp();\n \t\t\tfor (final Player p : combatants) {\n \t\t\t\t\n \t\t\t\t// Make sure not wildThings\n \t\t\t\tif (!p.isWildThing()) {\n \t\t\t\t\t\n \t\t\t\t\tArrayList <Piece> callOuts = new ArrayList<Piece>();\n \t\t\t\t\t\n \t\t\t\t\tfor (final Piece ap : attackingPieces.get(p.getName())) {\n \t\t\t\t\t\t\n \t\t\t\t\t\t// If not supported the gtfo\n \t\t\t\t\t\tif (!ap.isSupported()) {\n\n \t\t\t\t\t\t\tcallOuts.add(ap);\n \t\t\t\t\t\t\t((Combatable)ap).inflict();\n \t\t\t\t\t\t\ttry { Thread.sleep(250); } catch( Exception e ){ return; } \n \t\t\t\t\t\t\tPlatform.runLater(new Runnable() {\n\t \t \t @Override\n\t \t \t public void run() {\n\t \t \t \tInfoPanel.showTileInfo(battleGround);\n\t \t \t \tGUI.getHelpText().setText(\"Attack phase: \" + p.getName()\n\t\t\t \t + \" lost their \" + ap.getName() + \" in a called bluff!\");\n\t \t \t }\n\t \t\t\t});\n \t\t\t\t\t\t\ttry { Thread.sleep(250); } catch( Exception e ){ return; } \n \t\t\t\t\t\t}\n \t\t\t\t\t}\n \t\t\t\t\tfor (Piece co : callOuts) {\n \t\t\t\t\t\tattackingPieces.get(p.getName()).remove(co);\n \t\t\t\t\t}\n\t\t\t\t\t\tif (attackingPieces.get(p.getName()).size() == 0)\n\t\t\t\t\t\t\tattackingPieces.remove(p.getName());\n \t\t\t\t}\n \t\t\t}\n \t\t\t\n \t\t\t// Check for defeated armies:\n\t\t\t\t// - find player with no more pieces on terrain\n\t\t\t\t// - remove any such players from combatants\n\t\t\t\t// - if only one combatant, end combat\n \t\t\tPlayer baby = null;\n \t\t\twhile (combatants.size() != attackingPieces.size()) {\n\t\t\t\t\tfor (Player pl : combatants) {\n\t\t\t\t\t\tif (!attackingPieces.containsKey(pl.getName())) {\n\t\t\t\t\t\t\tbaby = pl;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tcombatants.remove(baby);\n \t\t\t}\n \t\t\tif (combatants.size() == 1) {\n \t\t\t\texploring = (!battleGround.isExplored() && battleGround.getContents().size() == 1);\n \t\t\t\tcontinue;\n \t\t\t}\n \t\t\t\n \t\t\t// Set up this HashMap that will store successful attacking pieces\n \t\t\tHashMap<String, ArrayList<Piece>> successAttacks = new HashMap<String, ArrayList<Piece>>();\n \t\t\t// Set up this HashMap that will store piece marked to get damage inflicted\n\t\t\t\tHashMap<String, ArrayList<Piece>> toInflict = new HashMap<String, ArrayList<Piece>>();\n \t\t\tfor (Player p : combatants) {\n \t\t\t\t\n \t\t\t\tsuccessAttacks.put(p.getName(), new ArrayList<Piece>());\n \t\t\t\ttoInflict.put(p.getName(), new ArrayList<Piece>());\n \t\t\t}\n \t\t\t\n \t\t\t// Array List of pieces that need to be used during a particular phase\n\t\t\t\tfinal ArrayList<Piece> phaseThings = new ArrayList<Piece>();\n\t\t\t\t\n\t\t\t\t// Notify next phase, wait for a second\n\t\t\t\tPlatform.runLater(new Runnable() {\n\t @Override\n\t public void run() {\n\t \tbattleGround.coverPieces();\n\t \tGUI.getHelpText().setText(\"Attack phase: Next phase: Magic!\");\n\t }\n\t });\n\t\t\t\t\n\t\t\t\t// Pause for 2 seconds between phases\n\t\t\t\ttry { Thread.sleep(2000); } catch( Exception e ){ return; }\n\t\t\t\t\n/////////////////////// Magic phase\n \t\t\tfor (final Player pl : combatants) {\n \t\t\t\t\n \t\t\t\tplayer = pl;\n \t\t\t\t// Cover all pieces\n \t\t\t\tPlatform.runLater(new Runnable() {\n \t @Override\n \t public void run() {\n \t \t\tbattleGround.coverPieces();\n \t }\n \t });\n \t\t\t\t\n \t\t\t\t// For each piece, if its magic. Add it to the phaseThings array\n \t\t\t\tfor (Piece p : attackingPieces.get(pl.getName())) {\n \t\t\t\t\tif (p instanceof Combatable && ((Combatable)p).isMagic() && !(p instanceof Fort && ((Fort)p).getCombatValue() == 0)) \n \t\t\t\t\t\tphaseThings.add(p);\n \t\t\t\t}\n \t\t\t\t\n \t\t\t\t// uncover magic pieces for clicking\n \t\t\t\tif (phaseThings.size() > 0) {\n\t \t\t\t\tPlatform.runLater(new Runnable() {\n\t \t @Override\n\t \t public void run() {\n\t \t \t\t\t\tfor (Piece mag : phaseThings) \n\t \t\t\t\t\tmag.uncover();\n\t \t }\n\t \t });\n \t\t\t\t}\n\n\n\t\t\t\t\t\n\t\t\t\t\tSystem.out.println(\"----------------------------------------------------------------\");\n\t\t\t\t\tSystem.out.println(\"attackingPieces.size(): \" + attackingPieces.size());\n\t\t\t\t\tSystem.out.println(\"attackingPieces.keySet(): \" + attackingPieces.keySet());\n\t\t\t\t\tIterator<String> keySetIte = battleGround.getContents().keySet().iterator();\n \t \twhile(keySetIte.hasNext()) {\n \t \t\tString key = keySetIte.next();\n\n \t\t\t\t\tSystem.out.println(\"key: \" + key);\n \t\t\t\t\tSystem.out.println(\"attackingPieces.get(key).size():\\n\" + attackingPieces.get(key).size());\n \t\t\t\t\tSystem.out.println(\"attackingPieces.get(key):\\n\" + attackingPieces.get(key));\n \t \t}\n\t\t\t\t\tSystem.out.println(\"----------------------------------------------------------------\");\n\t\t\t\t\t\n \t\t\t\t// Have user select a piece to attack with until there are no more magic pieces\n \t\t\t\twhile (phaseThings.size() > 0) {\n \t\t\t\t\t\n \t\t\t\t\t// Display message prompting user to select a magic piece\n \t\t\t\t\tPlatform.runLater(new Runnable() {\n\t \t @Override\n\t \t public void run() {\n\t \t \tGUI.getHelpText().setText(\"Attack phase: \" + player.getName() + \", select a magic piece to attack with\");\n\t \t }\n\t \t });\n \t\t\t\t\t\n \t\t\t\t\t\n \t\t\t\t\t\n \t\t\t\t\t// Wait for user to select piece\n \t\t\t\tpieceClicked = null;\n \t\t\t\tClickObserver.getInstance().setCreatureFlag(\"Combat: SelectPieceToAttackWith\");\n \t\t\t\tClickObserver.getInstance().setFortFlag(\"Combat: SelectPieceToAttackWith\");\n \t\t\t\t\twhile (pieceClicked == null) { try { Thread.sleep(100); } catch( Exception e ){ return; } }\n\t \t\t\t\tClickObserver.getInstance().setCreatureFlag(\"\");\n\t \t\t\t\tClickObserver.getInstance().setFortFlag(\"\");\n\t \t\t\t\t\n\t \t\t\t\t// hightlight piece that was selected, uncover the die to use, display message about rolling die\n \t\t\t\t\tPlatform.runLater(new Runnable() {\n\t \t @Override\n\t \t public void run() {\n\t \t \tpieceClicked.highLight();\n\t \t \tDiceGUI.getInstance().uncover();\n\t \t \tGUI.getHelpText().setText(\"Attack phase: \" + player.getName() \n\t \t \t\t\t+ \", roll the die. You need a \" + ((Combatable)pieceClicked).getCombatValue() + \" or lower\");\n\t \t }\n \t\t\t\t\t});\n \t\t\t\t\t\n\t \t// Dice is set to -1 while it is 'rolling'. This waits for the roll to stop, ie not -1\n \t\t\t\t\tint attackStrength = -1;\n \t\t\t\t\twhile (attackStrength == -1) {\n \t\t\t\t\t\ttry { Thread.sleep(100); } catch( Exception e ){ return; }\n \t\t\t\t\t\tattackStrength = Dice.getFinalVal();\n \t\t\t\t\t}\n\t\t\t\t\t\t\n \t\t\t\t\t// If the roll was successful. Add to successfulThings Array, and change it image. prompt Failed attack\n \t\t\t\t\tif (attackStrength <= ((Combatable)pieceClicked).getCombatValue()) {\n \t\t\t\t\t\t\n \t\t\t\t\t\tsuccessAttacks.get(player.getName()).add(pieceClicked);\n \t\t\t\t\t\tPlatform.runLater(new Runnable() {\n \t \t @Override\n \t \t public void run() {\n \t \t\t\t\t\t\t((Combatable)pieceClicked).setAttackResult(true);\n \t \t\t\t\t\t\tpieceClicked.cover();\n \t \t\t\t\t\t\tpieceClicked.unhighLight();\n \t \t \tGUI.getHelpText().setText(\"Attack phase: Successful Attack!\");\n \t \t }\n \t\t\t\t\t});\n \t\t\t\t\t\t\n \t\t\t\t\t} else { // else failed attack, update image, prompt Failed attack\n \t\t\t\t\t\tPlatform.runLater(new Runnable() {\n\t\t \t @Override\n\t\t \t public void run() {\n\t\t \t\t\t\t\t\t((Combatable)pieceClicked).setAttackResult(false);\n\t\t \t\t\t\t\t\tpieceClicked.cover();\n \t \t\t\t\t\t\tpieceClicked.unhighLight();\n\t\t \t \tGUI.getHelpText().setText(\"Attack phase: Failed Attack!\");\n\t\t \t }\n\t \t\t\t\t\t});\n \t\t\t\t\t}\n \t\t\t\t\t\n \t\t\t\t\t// Pause to a second for easy game play, remove the clicked piece from phaseThings\n \t\t\t\t\ttry { Thread.sleep(1000); } catch( Exception e ){ return; }\n \t\t\t\t\tphaseThings.remove(pieceClicked);\n \t\t\t\t}\n \t\t\t}\n\n\t\t\t\t// For each piece that had success, player who is being attacked must choose a piece\n \t\t\t// Gets tricky here. Will be tough for Networking :(\n \t\t\tfor (Player pl : combatants) {\n \t\t\t\t\n \t\t\t\t// Active player is set to the player who 'pl' is attack based on toAttack HashMap\n \t\t\t\tplayer = toAttacks.get(pl.getName()); // 'defender'\n \t\t\t\tfinal String plName = pl.getName();\n \t\t\t\t\n \t\t\t\t// For each piece of pl's that has a success (in successAttacks)\n \t\t\t\tint i = 0;\n \t\t\t\tfor (final Piece p : successAttacks.get(plName)) {\n\n \t\t\t\t\t// If there are more successful attacks then pieces to attack, break after using enough attacks\n \t\t\t\t\tif (i >= attackingPieces.get(player.getName()).size()) {\n \t\t\t\t\t\tbreak;\n \t\t\t\t\t}\n \t\t\t\t\t\n \t\t\t\t\t// Display message, cover other players pieces, uncover active players pieces\n\t \t\t\t\tPlatform.runLater(new Runnable() {\n\t \t @Override\n\t \t public void run() {\n\t \t \tGUI.getHelpText().setText(\"Attack phase: \" + player.getName() + \", Select a Piece to take a hit from \" + plName + \"'s \" + p.getName());\n\t \t \tbattleGround.coverPieces();\n\t \t \tbattleGround.uncoverPieces(player.getName());\n\t \t }\n\t\t\t\t\t\t});\n \t\t\t\t\ttry { Thread.sleep(100); } catch( Exception e ){ return; }\n \t\t\t\t\t\n\t \t\t\t\t// Cover pieces already choosen to be inflicted. Wait to make sure runLater covers pieces already selected\n\t \t\t\t\tfor (final Piece pi : toInflict.get(player.getName())) {\n\t \t\t\t\t\tif (!((pi instanceof Fort) && ((Fort)pi).getCombatValue() > 0)) {\n\t\t \t\t\t\t\tPlatform.runLater(new Runnable() {\n\t\t\t \t @Override\n\t\t\t \t public void run() {\n\t\t\t\t \t\t\t\t\tpi.cover();\n\t\t\t \t }\n\t\t\t\t\t\t\t\t});\n\t \t\t\t\t\t}\n\t \t\t\t\t}//TODO here is where a pause might be needed\n\t \t\t\t\t\n\t \t\t\t\t// Wait for user to select piece\n \t\t\t\t\tpieceClicked = null;\n\t \t\t\t\tClickObserver.getInstance().setCreatureFlag(\"Combat: SelectPieceToGetHit\");\n\t \t\t\t\tClickObserver.getInstance().setFortFlag(\"Combat: SelectPieceToGetHit\");\n \t\t\t\t\twhile (pieceClicked == null) { try { Thread.sleep(100); } catch( Exception e ){ return; } }\n \t\t\t\t\tClickObserver.getInstance().setCreatureFlag(\"\");\n\t \t\t\t\tClickObserver.getInstance().setFortFlag(\"\");\n\t\t \t\t\t\n \t\t\t\t\t// Add to arrayList in HashMap of player to mark for future inflict. Cover pieces\n \t\t\t\t\ttoInflict.get(player.getName()).add(pieceClicked);\n \t\t\t\t\tPlatform.runLater(new Runnable() {\n\t \t @Override\n\t \t public void run() {\n\t \t \tbattleGround.coverPieces();\n\t \t }\n\t\t\t\t\t\t});\n \t\t\t\t\ti++;\n \t\t\t\t\ttry { Thread.sleep(100); } catch( Exception e ){ return; }\n\t \t\t\t\t\n \t\t\t\t}\n \t\t\t\t// Clear successful attacks for next phase\n \t\t\t\tsuccessAttacks.get(pl.getName()).clear();\n \t\t\t}\n \t\t\t\n \t\t\t// Remove little success and failure images, inflict if necessary\n \t\t\tfor (Player pl : combatants) {\n \t\t\t\t\n \t\t\t\t// Change piece image of success or failure to not visible\n \t\t\t\tfor (Piece p : attackingPieces.get(pl.getName())) \n \t\t\t\t\t((Combatable)p).resetAttack();\n \t\t\t\t\n\t\t\t\t\t// inflict return true if the piece is dead, and removes it from attackingPieces if so\n \t\t\t\t// Inflict is also responsible for removing from the CreatureStack\n \t\t\t\tfor (Piece p : toInflict.get(pl.getName())) {\n\t\t\t\t\t\tif (((Combatable)p).inflict()) \n\t\t\t\t\t\t\tattackingPieces.get(pl.getName()).remove(p);\n\t\t\t\t\t\tif (attackingPieces.get(pl.getName()).size() == 0)\n\t\t\t\t\t\t\tattackingPieces.remove(pl.getName());\n \t\t\t\t}\n \t\t\t\t\n \t\t\t\t// Clear toInflict for next phase\n \t\t\t\ttoInflict.get(pl.getName()).clear();\n \t\t\t}\n\n\t\t\t\t// Update the InfoPanel gui for changed/removed pieces\n\t\t\t\tPlatform.runLater(new Runnable() {\n\t @Override\n\t public void run() {\n \t\t\t\t\tInfoPanel.showTileInfo(battleGround);\n \t\t\t\t\tbattleGround.coverPieces();\n\t }\n\t\t\t\t});\n \t\t\t\n \t\t\t// Check for defeated armies:\n\t\t\t\t// - find player with no more pieces on terrain\n\t\t\t\t// - remove any such players from combatants\n\t\t\t\t// - if only one combatant, end combat\n \t\t\tbaby = null;\n \t\t\twhile (combatants.size() != attackingPieces.size()) {\n\t\t\t\t\tfor (Player pl : combatants) {\n\t\t\t\t\t\tif (!attackingPieces.containsKey(pl.getName())) {\n\t\t\t\t\t\t\tbaby = pl;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tcombatants.remove(baby);\n \t\t\t}\n \t\t\tif (combatants.size() == 1) {\n \t\t\t\texploring = (!battleGround.isExplored() && battleGround.getContents().size() == 1);\n \t\t\t\tcontinue;\n \t\t\t}\n \t\t\t\n\t\t\t\t// Notify next phase, wait for a second\n\t\t\t\tPlatform.runLater(new Runnable() {\n\t @Override\n\t public void run() {\n\t \t\tbattleGround.coverPieces();\n\t \tGUI.getHelpText().setText(\"Attack phase: Next phase: Ranged!\");\n\t }\n\t });\n\t\t\t\t\n\t\t\t\t// Pause for 2 seconds between phases\n\t\t\t\ttry { Thread.sleep(2000); } catch( Exception e ){ return; }\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t\n//////////////////// Ranged phase\n\t\t\t\tfor (final Player pl : combatants) {\n \t\t\t\t\n \t\t\t\tplayer = pl;\n \t\t\t\t// Cover all pieces\n \t\t\t\tPlatform.runLater(new Runnable() {\n \t @Override\n \t public void run() {\n \t \t\tbattleGround.coverPieces();\n \t }\n \t });\n \t\t\t\t\n \t\t\t\t// For each piece, if its ranged. Add it to the phaseThings array\n \t\t\t\tfor (Piece p : attackingPieces.get(pl.getName())) {\n \t\t\t\t\tif (p instanceof Combatable && ((Combatable)p).isRanged() && !(p instanceof Fort && ((Fort)p).getCombatValue() == 0)) \n \t\t\t\t\t\tphaseThings.add(p);\n \t\t\t\t}\n \t\t\t\t\n \t\t\t\t// uncover ranged pieces for clicking\n \t\t\t\tif (phaseThings.size() > 0) {\n\t \t\t\t\tPlatform.runLater(new Runnable() {\n\t \t @Override\n\t \t public void run() {\n\t \t \t\t\t\tfor (Piece ran : phaseThings) \n\t \t\t\t\t\tran.uncover();\n\t \t }\n\t \t });\n \t\t\t\t}\n \t\t\t\t\n \t\t\t\t// Have user select a piece to attack with until there are no more ranged pieces\n \t\t\t\twhile (phaseThings.size() > 0) {\n \t\t\t\t\t\n \t\t\t\t\t// Display message prompting user to select a ranged piece\n \t\t\t\t\tPlatform.runLater(new Runnable() {\n\t \t @Override\n\t \t public void run() {\n\t \t \tGUI.getHelpText().setText(\"Attack phase: \" + player.getName() + \", select a ranged piece to attack with\");\n\t \t }\n\t \t });\n\n \t\t\t\t\t// Wait for user to select piece\n \t\t\t\tpieceClicked = null;\n \t\t\t\tClickObserver.getInstance().setCreatureFlag(\"Combat: SelectPieceToAttackWith\");\n \t\t\t\tClickObserver.getInstance().setFortFlag(\"Combat: SelectPieceToAttackWith\");\n \t\t\t\t\twhile (pieceClicked == null) { try { Thread.sleep(100); } catch( Exception e ){ return; } }\n\t \t\t\t\tClickObserver.getInstance().setCreatureFlag(\"\");\n\t \t\t\t\tClickObserver.getInstance().setFortFlag(\"\");\n\t \t\t\t\t\n\t \t\t\t\t// hightlight piece that was selected, uncover the die to use, display message about rolling die\n \t\t\t\t\tPlatform.runLater(new Runnable() {\n\t \t @Override\n\t \t public void run() {\n\t \t \tpieceClicked.highLight();\n\t \t \tDiceGUI.getInstance().uncover();\n\t \t \tGUI.getHelpText().setText(\"Attack phase: \" + player.getName()\n\t \t + \", roll the die. You need a \" + ((Combatable)pieceClicked).getCombatValue() + \" or lower\");\n\t \t }\n \t\t\t\t\t});\n \t\t\t\t\t\n\t \t// Dice is set to -1 while it is 'rolling'. This waits for the roll to stop, ie not -1\n \t\t\t\t\tint attackStrength = -1;\n \t\t\t\t\twhile (attackStrength == -1) {\n \t\t\t\t\t\ttry { Thread.sleep(100); } catch( Exception e ){ return; }\n \t\t\t\t\t\tattackStrength = Dice.getFinalVal();\n \t\t\t\t\t}\n\t\t\t\t\t\t\n \t\t\t\t\t// If the roll was successful. Add to successfulThings Array, and change it image. prompt Failed attack\n \t\t\t\t\tif (attackStrength <= ((Combatable)pieceClicked).getCombatValue()) {\n \t\t\t\t\t\t\n \t\t\t\t\t\tsuccessAttacks.get(player.getName()).add(pieceClicked);\n \t\t\t\t\t\tPlatform.runLater(new Runnable() {\n \t \t @Override\n \t \t public void run() {\n \t \t\t\t\t\t\t((Combatable)pieceClicked).setAttackResult(true);\n \t \t\t\t\t\t\tpieceClicked.cover();\n \t \t\t\t\t\t\tpieceClicked.unhighLight();\n \t \t \tGUI.getHelpText().setText(\"Attack phase: Successful Attack!\");\n \t \t }\n \t\t\t\t\t});\n \t\t\t\t\t\t\n \t\t\t\t\t} else { // else failed attack, update image, prompt Failed attack\n \t\t\t\t\t\tPlatform.runLater(new Runnable() {\n\t\t \t @Override\n\t\t \t public void run() {\n\t\t \t\t\t\t\t\t((Combatable)pieceClicked).setAttackResult(false);\n\t\t \t\t\t\t\t\tpieceClicked.cover();\n \t \t\t\t\t\t\tpieceClicked.unhighLight();\n\t\t \t \tGUI.getHelpText().setText(\"Attack phase: Failed Attack!\");\n\t\t \t }\n\t \t\t\t\t\t});\n \t\t\t\t\t}\n \t\t\t\t\t\n \t\t\t\t\t// Pause to a second for easy game play, remove the clicked piece from phaseThings\n \t\t\t\t\ttry { Thread.sleep(1000); } catch( Exception e ){ return; }\n \t\t\t\t\tphaseThings.remove(pieceClicked);\n \t\t\t\t}\n \t\t\t}\n\n\t\t\t\t// For each piece that had success, player who is being attacked must choose a piece\n \t\t\t// Gets tricky here. Will be tough for Networking :(\n \t\t\tfor (Player pl : combatants) {\n \t\t\t\t\n \t\t\t\t// Active player is set to the player who 'pl' is attack based on toAttack HashMap\n \t\t\t\tplayer = toAttacks.get(pl.getName());\n \t\t\t\tfinal String plName = pl.getName();\n \t\t\t\t\n \t\t\t\t// For each piece of pl's that has a success (in successAttacks)\n \t\t\t\tint i = 0;\n \t\t\t\tfor (final Piece p : successAttacks.get(plName)) {\n\n \t\t\t\t\t// If there are more successful attacks then pieces to attack, break after using enough attacks\n \t\t\t\t\tif (i >= attackingPieces.get(player.getName()).size()) {\n \t\t\t\t\t\tbreak;\n \t\t\t\t\t}\n \t\t\t\t\t\n \t\t\t\t\t// Display message, cover other players pieces, uncover active players pieces\n\t \t\t\t\tPlatform.runLater(new Runnable() {\n\t \t @Override\n\t \t public void run() {\n\t \t \tGUI.getHelpText().setText(\"Attack phase: \" + player.getName() + \", Select a Piece to take a hit from \" + plName + \"'s \" + p.getName());\n\t \t \tbattleGround.coverPieces();\n\t \t \tbattleGround.uncoverPieces(player.getName());\n\t \t }\n\t\t\t\t\t\t});\n \t\t\t\t\t\n\t \t\t\t\t// Cover pieces already choosen to be inflicted. Wait to make sure runLater covers pieces already selected\n\t \t\t\t\tfor (final Piece pi : toInflict.get(player.getName())) {\n\t \t\t\t\t\tif (!((pi instanceof Fort) && ((Fort)pi).getCombatValue() > 0)) {\n\t\t \t\t\t\t\tPlatform.runLater(new Runnable() {\n\t\t\t \t @Override\n\t\t\t \t public void run() {\n\t\t\t\t \t\t\t\t\tpi.cover();\n\t\t\t \t }\n\t\t\t\t\t\t\t\t});\n\t \t\t\t\t\t}\n\t \t\t\t\t}//TODO here is where a pause might be needed\n\t \t\t\t\t\n\t \t\t\t\t// Wait for user to select piece\n \t\t\t\t\tpieceClicked = null;\n\t \t\t\t\tClickObserver.getInstance().setCreatureFlag(\"Combat: SelectPieceToGetHit\");\n\t \t\t\t\tClickObserver.getInstance().setFortFlag(\"Combat: SelectPieceToGetHit\");\n \t\t\t\t\twhile (pieceClicked == null) { try { Thread.sleep(100); } catch( Exception e ){ return; } }\n \t\t\t\t\tClickObserver.getInstance().setFortFlag(\"\");\n \t\t\t\t\tClickObserver.getInstance().setCreatureFlag(\"\");\n\t\t \t\t\t\n \t\t\t\t\t// Add to arrayList in HashMap of player to mark for future inflict. Cover pieces\n \t\t\t\t\ttoInflict.get(player.getName()).add(pieceClicked);\n \t\t\t\t\tPlatform.runLater(new Runnable() {\n\t \t @Override\n\t \t public void run() {\n\t \t \tbattleGround.coverPieces();\n\t \t }\n\t\t\t\t\t\t});\n \t\t\t\t\ttry { Thread.sleep(100); } catch( Exception e ){ return; }\n\t \t\t\t\ti++;\n \t\t\t\t}\n \t\t\t\t// Clear successful attacks for next phase\n \t\t\t\tsuccessAttacks.get(pl.getName()).clear();\n \t\t\t}\n \t\t\t\n \t\t\t// Remove little success and failure images, inflict if necessary\n \t\t\tfor (Player pl : combatants) {\n \t\t\t\t\n \t\t\t\t// Change piece image of success or failure to not visible\n \t\t\t\tfor (Piece p : attackingPieces.get(pl.getName())) \n \t\t\t\t\t((Combatable)p).resetAttack();\n \t\t\t\t\n\t\t\t\t\t// inflict return true if the piece is dead, and removes it from attackingPieces if so\n \t\t\t\t// Inflict is also responsible for removing from the CreatureStack\n \t\t\t\tfor (Piece p : toInflict.get(pl.getName())) {\n\t\t\t\t\t\tif (((Combatable)p).inflict()) \n\t\t\t\t\t\t\tattackingPieces.get(pl.getName()).remove(p);\n\t\t\t\t\t\tif (attackingPieces.get(pl.getName()).size() == 0)\n\t\t\t\t\t\t\tattackingPieces.remove(pl.getName());\n \t\t\t\t}\n \t\t\t\t\n \t\t\t\t// Clear toInflict for next phase\n \t\t\t\ttoInflict.get(pl.getName()).clear();\n \t\t\t}\n\n\t\t\t\t// Update the InfoPanel gui for changed/removed pieces\n\t\t\t\tPlatform.runLater(new Runnable() {\n\t @Override\n\t public void run() {\n \t\t\t\t\tInfoPanel.showTileInfo(battleGround);\n \t\t\t\t\tbattleGround.coverPieces();\n\t }\n\t\t\t\t});\n \t\t\t\n \t\t\t// Check for defeated armies:\n\t\t\t\t// - find player with no more pieces on terrain\n\t\t\t\t// - remove any such players from combatants\n\t\t\t\t// - if only one combatant, end combat\n\t\t\t\tbaby = null;\n \t\t\twhile (combatants.size() != attackingPieces.size()) {\n\t\t\t\t\tfor (Player pl : combatants) {\n\t\t\t\t\t\tif (!attackingPieces.containsKey(pl.getName())) {\n\t\t\t\t\t\t\tbaby = pl;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tcombatants.remove(baby);\n \t\t\t}\n \t\t\tif (combatants.size() == 1) {\n \t\t\t\texploring = (!battleGround.isExplored() && battleGround.getContents().size() == 1);\n \t\t\t\tcontinue;\n \t\t\t}\n \t\t\t\n\t\t\t\t// Notify next phase, wait for a second\n\t\t\t\tPlatform.runLater(new Runnable() {\n\t @Override\n\t public void run() {\n\t \t\tbattleGround.coverPieces();\n\t \tGUI.getHelpText().setText(\"Attack phase: Next phase: Melee!\");\n\t }\n\t });\n\t\t\t\t\n\t\t\t\t// Pause for 2 seconds between phases\n\t\t\t\ttry { Thread.sleep(2000); } catch( Exception e ){ return; }\n\t\t\t\t\n\n///////////////////////////// Melee phase\n\t\t\t\tfor (final Player pl : combatants) {\n \t\t\t\t\n \t\t\t\tplayer = pl;\n \t\t\t\t// Cover all pieces\n \t\t\t\tPlatform.runLater(new Runnable() {\n \t @Override\n \t public void run() {\n \t \t\tbattleGround.coverPieces();\n \t }\n \t });\n \t\t\t\t\n \t\t\t\t// For each piece, if its melee. Add it to the phaseThings array\n \t\t\t\tfor (Piece p : attackingPieces.get(pl.getName())) {\n \t\t\t\t\tif (p instanceof Combatable && !(((Combatable)p).isRanged() || ((Combatable)p).isMagic()) && !(p instanceof Fort && ((Fort)p).getCombatValue() == 0)) \n \t\t\t\t\t\tphaseThings.add(p);\n \t\t\t\t}\n \t\t\t\t\n \t\t\t\t// uncover melee pieces for clicking\n \t\t\t\tif (phaseThings.size() > 0) {\n\t \t\t\t\tPlatform.runLater(new Runnable() {\n\t \t @Override\n\t \t public void run() {\n\t \t \t\t\t\tfor (Piece mel : phaseThings) \n\t \t\t\t\t\tmel.uncover();\n\t \t }\n\t \t });\n \t\t\t\t}\n \t\t\t\ttry { Thread.sleep(100); } catch( Exception e ){ return; }\n \t\t\t\t\n \t\t\t\t// Have user select a piece to attack with until there are no more melee pieces\n \t\t\t\twhile (phaseThings.size() > 0) {\n \t\t\t\t\t\n \t\t\t\t\t// Display message prompting user to select a melee piece\n \t\t\t\t\tPlatform.runLater(new Runnable() {\n\t \t @Override\n\t \t public void run() {\n\t \t \tGUI.getHelpText().setText(\"Attack phase: \" + player.getName() + \", select a melee piece to attack with\");\n\t \t }\n\t \t });\n\n \t\t\t\t\t// Wait for user to select piece\n \t\t\t\tpieceClicked = null;\n \t\t\t\tClickObserver.getInstance().setCreatureFlag(\"Combat: SelectPieceToAttackWith\");\n \t\t\t\tClickObserver.getInstance().setFortFlag(\"Combat: SelectPieceToAttackWith\");\n \t\t\t\t\twhile (pieceClicked == null) { try { Thread.sleep(100); } catch( Exception e ){ return; } }\n\t \t\t\t\tClickObserver.getInstance().setCreatureFlag(\"\");\n\t \t\t\t\tClickObserver.getInstance().setFortFlag(\"\");\n\t \t\t\t\t\n\t \t\t\t\t// Is it a charging piece?\n\t \t\t\t\tint charger;\n\t \t\t\t\tif (((Combatable)pieceClicked).isCharging()) {\n\t \t\t\t\t\tcharger = 2;\n\t \t\t\t\t} else\n\t \t\t\t\t\tcharger = 1;\n\t \t\t\t\t\n\t \t\t\t\t// do twice if piece is a charger\n\t \t\t\t\tfor (int i = 0; i < charger; i++) {\n\t \t\t\t\t\t\n\t\t \t\t\t\t// hightlight piece that was selected, uncover the die to use, display message about rolling die\n\t \t\t\t\t\tPlatform.runLater(new Runnable() {\n\t\t \t @Override\n\t\t \t public void run() {\n\t\t \t \tpieceClicked.highLight();\n\t\t \t \tDiceGUI.getInstance().uncover();\n\t\t \t \tGUI.getHelpText().setText(\"Attack phase: \" + player.getName()\n\t\t \t + \", roll the die. You need a \" + ((Combatable)pieceClicked).getCombatValue() + \" or lower\");\n\t\t \t }\n\t \t\t\t\t\t});\n\t \t\t\t\t\t\n\t\t \t// Dice is set to -1 while it is 'rolling'. This waits for the roll to stop, ie not -1\n\t \t\t\t\t\tint attackStrength = -1;\n\t \t\t\t\t\twhile (attackStrength == -1) {\n\t \t\t\t\t\t\ttry { Thread.sleep(100); } catch( Exception e ){ return; }\n\t \t\t\t\t\t\tattackStrength = Dice.getFinalVal();\n\t \t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t \t\t\t\t\t// If the roll was successful. Add to successfulThings Array, and change it image. prompt Failed attack\n\t \t\t\t\t\tif (attackStrength <= ((Combatable)pieceClicked).getCombatValue()) {\n\t \t\t\t\t\t\t\n\t \t\t\t\t\t\tsuccessAttacks.get(player.getName()).add(pieceClicked);\n\t \t\t\t\t\t\tPlatform.runLater(new Runnable() {\n\t \t \t @Override\n\t \t \t public void run() {\n\t \t \t\t\t\t\t\t((Combatable)pieceClicked).setAttackResult(true);\n\t \t \t\t\t\t\t\tpieceClicked.cover();\n\t \t \t\t\t\t\t\tpieceClicked.unhighLight();\n\t \t \t \tGUI.getHelpText().setText(\"Attack phase: Successful Attack!\");\n\t \t \t }\n\t \t\t\t\t\t});\n\t \t\t\t\t\t\t\n\t \t\t\t\t\t} else { // else failed attack, update image, prompt Failed attack\n\t \t\t\t\t\t\tPlatform.runLater(new Runnable() {\n\t\t\t \t @Override\n\t\t\t \t public void run() {\n\t\t\t \t\t\t\t\t\t((Combatable)pieceClicked).setAttackResult(false);\n\t\t\t \t\t\t\t\t\tpieceClicked.cover();\n\t \t \t\t\t\t\t\tpieceClicked.unhighLight();\n\t\t\t \t \tGUI.getHelpText().setText(\"Attack phase: Failed Attack!\");\n\t\t\t \t }\n\t\t \t\t\t\t\t});\n\t \t\t\t\t\t}\n\t \t\t\t\t\t\n\t \t\t\t\t\t// If piece is charging, and it is its first attack, remove the cover again\n\t \t\t\t\t\tif (((Combatable)pieceClicked).isCharging() && i == 0) {\n\t \t\t\t\t\t\tPlatform.runLater(new Runnable() {\n\t\t\t \t @Override\n\t\t\t \t public void run() {\n\t\t\t \t \tpieceClicked.uncover();\n\t\t\t \t }\n\t \t\t\t\t\t\t});\n\t \t\t\t\t\t}\n\t \t\t\t\t\t\n\t \t\t\t\t\t// Pause to a second for easy game play, remove the clicked piece from phaseThings\n\t \t\t\t\t\ttry { Thread.sleep(1000); } catch( Exception e ){ return; }\n\t \t\t\t\t}\n\n \t\t\t\t\tphaseThings.remove(pieceClicked);\n \t\t\t\t}\n \t\t\t}\n\n\t\t\t\t// For each piece that had success, player who is being attacked must choose a piece\n \t\t\t// Gets tricky here. Will be tough for Networking :(\n \t\t\tfor (Player pl : combatants) {\n \t\t\t\t\n \t\t\t\t// Active player is set to the player who 'pl' is attack based on toAttack HashMap\n \t\t\t\tplayer = toAttacks.get(pl.getName());\n \t\t\t\tfinal String plName = pl.getName();\n \t\t\t\t\n \t\t\t\t// For each piece of pl's that has a success (in successAttacks)\n \t\t\t\tint i = 0;\n \t\t\t\tfor (final Piece p : successAttacks.get(plName)) {\n \t\t\t\t\t\n \t\t\t\t\t// If there are more successful attacks then pieces to attack, break after using enough attacks\n \t\t\t\t\tif (i >= attackingPieces.get(player.getName()).size()) {\n \t\t\t\t\t\tbreak;\n \t\t\t\t\t}\n \t\t\t\t\t\n \t\t\t\t\t// Display message, cover other players pieces, uncover active players pieces\n\t \t\t\t\tPlatform.runLater(new Runnable() {\n\t \t @Override\n\t \t public void run() {\n\t \t \tGUI.getHelpText().setText(\"Attack phase: \" + player.getName() + \", Select a Piece to take a hit from \" + plName + \"'s \" + p.getName());\n\t \t \tbattleGround.coverPieces();\n\t \t \tbattleGround.uncoverPieces(player.getName());\n\t \t }\n\t\t\t\t\t\t});\n \t\t\t\t\t\n\t \t\t\t\t// Cover pieces already choosen to be inflicted. Wait to make sure runLater covers pieces already selected\n\t \t\t\t\tfor (final Piece pi : toInflict.get(player.getName())) {\n\t \t\t\t\t\tif (!((pi instanceof Fort) && ((Fort)pi).getCombatValue() > 0)) {\n\t\t \t\t\t\t\tPlatform.runLater(new Runnable() {\n\t\t\t \t @Override\n\t\t\t \t public void run() {\n\t\t\t\t \t\t\t\t\tpi.cover();\n\t\t\t \t }\n\t\t\t\t\t\t\t\t});\n\t \t\t\t\t\t}\n\t \t\t\t\t}//TODO here is where a pause might be needed\n\t \t\t\t\t\n\t \t\t\t\t// Wait for user to select piece\n \t\t\t\t\tpieceClicked = null;\n\t \t\t\t\tClickObserver.getInstance().setCreatureFlag(\"Combat: SelectPieceToGetHit\");\n\t \t\t\t\tClickObserver.getInstance().setFortFlag(\"Combat: SelectPieceToGetHit\");\n \t\t\t\t\twhile (pieceClicked == null) { try { Thread.sleep(100); } catch( Exception e ){ return; } }\n \t\t\t\t\tClickObserver.getInstance().setCreatureFlag(\"\");\n \t\t\t\t\tClickObserver.getInstance().setFortFlag(\"\");\n\t\t \t\t\t\n \t\t\t\t\t// Add to arrayList in HashMap of player to mark for future inflict. Cover pieces\n \t\t\t\t\ttoInflict.get(player.getName()).add(pieceClicked);\n \t\t\t\t\tPlatform.runLater(new Runnable() {\n\t \t @Override\n\t \t public void run() {\n\t \t \tbattleGround.coverPieces();\n\t \t }\n\t\t\t\t\t\t});\n \t\t\t\t\ttry { Thread.sleep(100); } catch( Exception e ){ return; }\n\t \t\t\t\ti++;\n \t\t\t\t}\n \t\t\t\t// Clear successful attacks for next phase\n \t\t\t\tsuccessAttacks.get(pl.getName()).clear();\n \t\t\t}\n \t\t\t\n \t\t\t// Remove little success and failure images, inflict if necessary\n \t\t\tfor (Player pl : combatants) {\n \t\t\t\t\n \t\t\t\t// Change piece image of success or failure to not visible\n \t\t\t\tfor (Piece p : attackingPieces.get(pl.getName())) \n \t\t\t\t\t((Combatable)p).resetAttack();\n \t\t\t\t\n\t\t\t\t\t// inflict return true if the piece is dead, and removes it from attackingPieces if so\n \t\t\t\t// Inflict is also responsible for removing from the CreatureStack\n \t\t\t\tfor (Piece p : toInflict.get(pl.getName())) {\n\t\t\t\t\t\tif (((Combatable)p).inflict()) \n\t\t\t\t\t\t\tattackingPieces.get(pl.getName()).remove(p);\n\t\t\t\t\t\tif (attackingPieces.get(pl.getName()).size() == 0)\n\t\t\t\t\t\t\tattackingPieces.remove(pl.getName());\n \t\t\t\t}\n \t\t\t\t\n \t\t\t\t// Clear toInflict for next phase\n \t\t\t\ttoInflict.get(pl.getName()).clear();\n \t\t\t}\n\n\t\t\t\t// Update the InfoPanel gui for changed/removed pieces\n\t\t\t\tPlatform.runLater(new Runnable() {\n\t @Override\n\t public void run() {\n \t\t\t\t\tInfoPanel.showTileInfo(battleGround);\n \t\t\t\t\tbattleGround.coverPieces();\n\t }\n\t\t\t\t});\n \t\t\t\n \t\t\t// Check for defeated armies:\n\t\t\t\t// - find player with no more pieces on terrain\n\t\t\t\t// - remove any such players from combatants\n\t\t\t\t// - if only one combatant, end combat\n\t\t\t\tbaby = null;\n \t\t\twhile (combatants.size() != attackingPieces.size()) {\n\t\t\t\t\tfor (Player pl : combatants) {\n\t\t\t\t\t\tif (!attackingPieces.containsKey(pl.getName())) {\n\t\t\t\t\t\t\tbaby = pl;\t\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tcombatants.remove(baby);\n \t\t\t}\n \t\t\tif (combatants.size() == 1) {\n \t\t\t\texploring = (!battleGround.isExplored() && battleGround.getContents().size() == 1);\n \t\t\t\tcontinue;\n \t\t\t}\n \t\t\t\n\t\t\t\t// Notify next phase, wait for a second\n\t\t\t\tPlatform.runLater(new Runnable() {\n\t @Override\n\t public void run() {\n\t \t\tbattleGround.coverPieces();\n\t \tGUI.getHelpText().setText(\"Attack phase: Next phase: Retreat!\");\n\t }\n\t });\n\t\t\t\t\n\t\t\t\t// Pause for 2 seconds between phases\n\t\t\t\ttry { Thread.sleep(2000); } catch( Exception e ){ return; }\n \t\t\t\n \t\t\t\n//////////////////////// Retreat phase\n\t\t\t\t// Can only retreat to a Terrain that has been explored and has no ememies on it\n\t\t\t\t\n\t\t\t\t// Display message, activate done button\n\t\t\t\tPlatform.runLater(new Runnable() {\n\t @Override\n\t public void run() {\n\t \tGUI.getHelpText().setText(\"Attack phase: Retreat some of your armies?\");\n\t\t GUI.getDoneButton().setDisable(false);\n\t }\n\t }); \t\t\t\t\n\t\t\t\t\n\t\t\t\t// For each combatant, ask if they would like to retreat\n\t\t for (Player pl : combatants) {\n\t\t \t\n\t\t \t// Make sure wildThings aren't trying to get away\n\t\t \tif (!pl.isWildThing()) {\n\t\t\t \tplayer = pl;\n\t \t InfoPanel.uncover(player.getName());\n\t\t\t\t ClickObserver.getInstance().setActivePlayer(player);\n\t\t\t\t ClickObserver.getInstance().setCreatureFlag(\"Combat: SelectRetreaters\");\n\t\t\t\t \n\t\t\t\t // Pause and wait for player to hit done button\n\t\t\t\t pause();\n\t\t\t Platform.runLater(new Runnable() {\n\t\t\t @Override\n\t\t\t public void run() {\n\t\t\t \tbattleGround.coverPieces();\n\t\t\t \tbattleGround.uncoverPieces(player.getName());\n\t\t\t \tbattleGround.coverFort();\n\t\t\t \t GUI.getHelpText().setText(\"Attack Phase: \" + player.getName() + \", You can retreat your armies\");\n\t\t\t }\n\t\t\t });\n\t\t\t\t while (isPaused && battleGround.getContents(player.getName()) != null) {\n\t\t\t \ttry { Thread.sleep(100); } catch( Exception e ){ return; } \n\t\t\t\t }\t \n\t\t\t\t ClickObserver.getInstance().setTerrainFlag(\"Disabled\");\n\t\t\t\t \n\t\t\t\t // TODO, maybe an if block here asking user if they would like to attack \n\t\t\t\t System.out.println(attackingPieces + \"---BEFORE CLEARING\");\n\t\t\t\t // Re-populate attackingPieces to check for changes\n\t\t\t\t attackingPieces.clear();\n\t\t\t\t Iterator<String> keySetIterator2 = battleGround.getContents().keySet().iterator();\n\t\t\t\t \twhile(keySetIterator2.hasNext()) {\n\t\t\t\t \t\tString key = keySetIterator2.next();\n System.out.println(key + \"=====key\");\n\t\t\t \t\t\tattackingPieces.put(battleGround.getContents().get(key).getOwner().getName(), (ArrayList<Piece>) battleGround.getContents().get(key).getStack().clone()); \n\t\t\t\t \t}\n // System.out.println(attackingPieces);\n\t\t\t\t \t// if the owner of the terrain has no pieces, just a fort or city/village\n System.out.println(\"===battleground\"+battleGround);\n System.out.println(\"===attackingPieces\"+attackingPieces);\n System.out.println(combatants.contains(battleGround.getOwner()) ? \"TRUE\" : \"FALSE\");\n\t\t\t\t\t\tif (combatants.contains(battleGround.getOwner()) && battleFort != null) {\n System.out.println(battleGround + \"===battleground\");\n\t\t\t\t\t\t\tattackingPieces.put(battleGround.getOwner().getName(), new ArrayList<Piece>());\n System.out.println(attackingPieces + \"===attacking pieces\");\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif (battleFort != null) {\n System.out.println(battleFort.getName() + \"===battlefort\");\n System.out.println(battleFort.getOwner().getName() + \"===battlefort's owner\");\n \n\t\t\t\t\t\t\tattackingPieces.get(battleFort.getOwner().getName()).add(battleFort);\n System.out.println(attackingPieces.get(battleFort.getOwner().getName()));\n\t\t\t\t\t\t}\n\t//\t\t\t\t\tif (battleGround city/village)\n\t\t\t\t\t\t// TODO city/village\n\t\t\t\t \n\t\t\t\t\t\t\n\t\t\t\t // Check if all the players pieces are now gone\n\t\t\t\t if (!attackingPieces.containsKey(player.getName())) {\n\t\t\t\t \t\n\t\t\t\t \t// Display message, and remove player from combatants\n\t\t\t\t \tPlatform.runLater(new Runnable() {\n\t\t\t\t @Override\n\t\t\t\t public void run() {\n\t\t\t\t \t GUI.getHelpText().setText(\"Attack Phase: \" + player.getName() + \" has retreated all of their pieces!\");\n\t\t\t\t }\n\t\t\t\t });\n\t\t\t\t \t\n\t\t\t\t \t// If there is only 1 player fighting for the hex, \n\t\t\t\t \tif (attackingPieces.size() == 1) \n\t\t\t\t \t\tbreak;\n\t\t\t\t \t\n\t\t\t\t \t// Pause because somebody just retreated\n\t\t\t\t \ttry { Thread.sleep(2000); } catch( Exception e ){ return; }\n\t\t\t\t }\n\t\t\t\t \n\n\t \t InfoPanel.cover(player.getName());\n\t\t\t\t \n\t\t\t }\n\t\t }\n\t\t \n\t\t // Done button no longer needed\n\t\t Platform.runLater(new Runnable() {\n\t\t @Override\n\t\t public void run() {\n\t\t GUI.getDoneButton().setDisable(true);\n\t\t }\n\t\t });\n\t\t ClickObserver.getInstance().setCreatureFlag(\"\");\n\t\t ClickObserver.getInstance().setFortFlag(\"\");\n\t\t \n\t\t // Check for defeated armies:\n\t\t\t\t// - find player with no more pieces on terrain\n\t\t\t\t// - remove any such players from combatants\n\t\t\t\t// - if only one combatant, end combat\n \t\t\tbaby = null;\n \t\t\twhile (combatants.size() != attackingPieces.size()) {\n\t\t\t\t\tfor (Player pl : combatants) {\n\t\t\t\t\t\tif (!attackingPieces.containsKey(pl.getName())) {\n\t\t\t\t\t\t\tbaby = pl;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tcombatants.remove(baby);\n \t\t\t}\n \t\t\tif (combatants.size() == 1) {\n \t\t\t\texploring = (!battleGround.isExplored() && battleGround.getContents().size() == 1);\n \t\t\t\tcontinue;\n \t\t\t}\n \t\t\t\n\n\t\t\t\texploring = (!battleGround.isExplored() && battleGround.getContents().size() == 1);\n\t\t\t\t\n\t\t\t\t// Add wildthings back to combatants if they were removed\n\t\t\t\tif (battleGround.getContents().containsKey(wildThings.getName()) && !combatants.contains(wildThings))\n\t\t\t\t\tcombatants.add(wildThings);\n\t\t\t\t\n \t\t} // end while (combatants.size() > 1 || exploring)\n \t\tbattleGround.coverFort();\n \t\t\n////////////////// Post Combat\n \t\t\n \t\t// sets player as the winner of the combat\n \t\t// Can be null if battle takes place on a hex owned by nobody, and each player lost all pieces\n \t\tPlatform.runLater(new Runnable() {\n @Override\n public void run() {\n \tbattleGround.removeBattleHex();\n }\n \t\t});\n \t\t\n \t\tif (combatants.size() == 0)\n \t\t\tplayer = battleGround.getOwner();\n \t\telse if (combatants.size() == 1 && combatants.get(0).getName().equals(wildThings.getName()))\n \t\t\tplayer = null;\n \t\telse\n \t\t\tplayer = combatants.get(0);\n \t\t\n \t\tSystem.out.println(\"~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\");\n \t\tSystem.out.println(\"combatants: \" + combatants);\n \t\tfor (Player p : combatants) {\n \t\tSystem.out.println(\"p.getName(): \"+ p.getName());\n \t\t\t\n \t\t}\n \t\tSystem.out.println(\"owner: \" + owner);\n \t\tSystem.out.println(\"combatants.get(0): \" + combatants.get(0));\n \t\tSystem.out.println(\"~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\");\n \t\t\n \t\t\n \t\t// Change ownership of hex to winner\n \t\tboolean ownerChanged = false;\n \t\tif (owner != null && combatants.size() > 0 && !battleGround.getOwner().equals(combatants.get(0))) {\n \t\t\tbattleGround.getOwner().removeHex(battleGround);\n \t\t\tcombatants.get(0).addHexOwned(battleGround);\n \t\t\townerChanged = true;\n \t\t}\n\t\t\t\n \t\t// See if fort is kept or downgraded.\n \t\tif (battleFort != null) {\n if (battleFort.getName().equals(\"Citadel\")) {\n owner.setCitadel(false);\n player.setCitadel(true);\n battleFort.healFort();\n player.addHexOwned(battleGround);\n Platform.runLater(new Runnable() {\n @Override\n public void run() {\n GUI.getHelpText().setText(\"Post combat: \" + player.getName() + \", you get to keep the fort!\");\n }\n });\n checkWinners();\n return;\n }\n \t\t\n\t\t\t\t// Get player to click dice to see if fort is kept\n\t\t\t\tPlatform.runLater(new Runnable() {\n\t @Override\n\t public void run() {\n\t \tGUI.getHelpText().setText(\"Post combat: \" + player.getName() + \", roll the die to see if the fort is kept or downgraded\");\n\t \tDiceGUI.getInstance().uncover();\n\t \tInfoPanel.showTileInfo(battleGround);\n\t }\n\t });\n\t\t\t\t\n\t\t\t\t// Dice is set to -1 while it is 'rolling'. This waits for the roll to stop, ie not -1\n\t\t\t\tint oneOrSixGood = -1;\n\t\t\t\twhile (oneOrSixGood == -1) {\n\t\t\t\t\ttry { Thread.sleep(100); } catch( Exception e ){ return; }\n\t\t\t\t\toneOrSixGood = Dice.getFinalVal();\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t// if a 1 or 6, keep fort (Keep it.... not turn it into a keep)\n\t\t\t\tif (oneOrSixGood == 1 || oneOrSixGood == 6) {\n\t\t\t\t\tbattleFort.healFort();\n\t\t\t\t\tplayer.addHexOwned(battleGround);\n\t\t\t\t\tPlatform.runLater(new Runnable() {\n\t\t @Override\n\t\t public void run() {\n\t\t \tGUI.getHelpText().setText(\"Post combat: \" + player.getName() + \", you get to keep the fort!\");\n\t\t }\n\t\t\t\t\t});\n\t\t\t\t} else {\n\t\t\t\t\tbattleFort.downgrade();Platform.runLater(new Runnable() {\n\t\t @Override\n\t\t public void run() {\n\t\t \tGUI.getHelpText().setText(\"Post combat: \" + player.getName() + \", the fort was destroyed!\");\n\t\t }\n\t\t\t\t\t});\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\tPlatform.runLater(new Runnable() {\n\t @Override\n\t public void run() {\n\t \tInfoPanel.showTileInfo(battleGround);\n\t }\n\t });\n\t\t\t\t\n\t\t\t\ttry { Thread.sleep(1000); } catch( Exception e ){ return; }\n\t\t\t\t\n\t\t\t\t\n \t\t}\n\n \t\tbattleGround.flipPiecesDown();\n\t\t\t// TODO city/village and special incomes if they are kept or lost/damaged \n \t\t\n \t\ttry { Thread.sleep(1000); } catch( Exception e ){ return; }\n \t}/// end Post combat\n\n \tPlatform.runLater(new Runnable() {\n @Override\n public void run() {\n//\t\t\t\tInfoPanel.showBattleStats();\n \tBoard.removeCovers();\n }\n\t\t});\n \t\n\t\tClickObserver.getInstance().setTerrainFlag(\"\");\n\t\tClickObserver.getInstance().setPlayerFlag(\"\");\n\t\tClickObserver.getInstance().setCreatureFlag(\"\");\n\t\tClickObserver.getInstance().setFortFlag(\"\");\n\t\tbattleGrounds.clear();\n }",
"private void battleTickStatuses(){\n updateStatuses(battleEnemies);\n updateStatuses(battleAllies);\n }",
"@Override\n public void notifyMapObservers() {\n for(MapObserver mapObserver : mapObservers){\n // needs all the renderInformation to calculate fogOfWar\n System.out.println(\"player map: \" +playerMap);\n mapObserver.update(this.playerNumber, playerMap.returnRenderInformation(), entities.returnUnitRenderInformation(), entities.returnStructureRenderInformation());\n entities.setMapObserver(mapObserver);\n }\n }",
"private void fireEvents() {\n\n if (clockTickCount % clockTicksTillWorkloadChange == 0) {\n clockEventPublisher.fireTriggerWorkloadHandlerEvent(clockTickCount, intervalDurationInMilliSeconds);\n }\n\n // if (clockTickCount % clockTicksTillScalingDecision == 0) {\n // clockEventPublisher.fireTriggerAutoScalerEvent(clockTickCount,\n // intervalDurationInMilliSeconds);\n // }\n\n clockEventPublisher.fireClockEvent(clockTickCount, intervalDurationInMilliSeconds);\n\n // INfrastruktur\n if (clockTickCount % clockTicksTillPublishInfrastructureState == 0) {\n clockEventPublisher.fireTriggerPublishInfrastructureStateEvent(clockTickCount,\n intervalDurationInMilliSeconds);\n\n }\n\n // Queue\n if (clockTickCount % clockTicksTillPublishQueueState == 0) {\n\n clockEventPublisher.fireTriggerPublishQueueStateEvent(clockTickCount, intervalDurationInMilliSeconds);\n }\n\n }",
"public void act() \r\n {\n if(getOneIntersectingObject(Player.class)!=null)\r\n {\r\n if(MenuWorld.gamemode == 1)\r\n //marcheaza regenerarea labirintului(trecere la nivelul urmator in Modul Contra Timp)\r\n TAworld.shouldRegen=true;\r\n else\r\n { \r\n //reseteaza variabilele care tin de modul de joc\r\n MenuWorld.gamemode=-1;\r\n MenuWorld.isPlaying=false;\r\n for(int i=0;i<4;i++)\r\n ItemCounter.gems_taken[i]=0;\r\n \r\n //arata fereastra de castig \r\n PMworld.shouldShowVictoryWindow=true;\r\n }\r\n \r\n }\r\n \r\n }",
"public void fireTorpedo() {\n\t\t// Has player waited cooldown before trying to fire again?\n\t\tif (System.currentTimeMillis() - this.lastFired > Config.WEAPON_COOLDOWN_TIME * 1000) {\n\t\t\tSystem.out.println(player.getDisplayName() + \" is attempting to fire a torpedo\");\n\t\t\t// Can this airship fire torpedoes?\n\t\t\tif (this.properties.FIRES_TORPEDO) {\n\t\t\t\tBlock[] cannons = getCannons();\n\t\t\t\tint numfiredcannons = 0;\n\t\t\t\tfor (int i = 0; i < cannons.length; i++) {\n\t\t\t\t\tif (cannons[i] != null && cannonHasTnt(cannons[i], Config.NUM_TNT_TO_FIRE_TORPEDO)) {\n\t\t\t\t\t\tBlockFace face = ((Directional) cannons[i].getState().getData()).getFacing();\n\t\t\t\t\t\tboolean missingMaterial = false;\n\t\t\t\t\t\t\n\t\t\t\t\t\tfor (int id : Config.MATERIALS_NEEDED_FOR_TORPEDO) {\n\t\t\t\t\t\t\tif (!cannonHasItem(cannons[i], id, 1)) {\n\t\t\t\t\t\t\t\tmissingMaterial = true;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (!cannons[i].getRelative(face.getModX(), 0, face.getModZ()).getType().equals(Material.AIR) || missingMaterial)\n\t\t\t\t\t\t\tcontinue;\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (numfiredcannons < this.properties.MAX_NUMBER_OF_CANNONS) {\n\t\t\t\t\t\t\tnumfiredcannons++;\n\t\t\t\t\t\t\tlastFired = System.currentTimeMillis();\n\t\t\t\t\t\t\twithdrawTnt(cannons[i], Config.NUM_TNT_TO_FIRE_TORPEDO);\n\t\t\t\t\t\t\tfor (int id : Config.MATERIALS_NEEDED_FOR_TORPEDO) {\n\t\t\t\t\t\t\t\twithdrawItem(cannons[i], id, 1);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t// Fire some torpedoes TODO: maybe add sound effects for tnt firing? :P\n\t\t\t\t\t\t\tnew Torpedo(cannons[i], face);\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t// More cannons on ship than allowed. Not all fired - can break out of loop now.\n\t\t\t\t\t\t\t//player.sendMessage(ChatColor.AQUA + \"Some cannons did not fire. Max cannon limit is \" + ChatColor.GOLD + this.properties.MAX_NUMBER_OF_CANNONS);\n\t\t\t\t\t\t\tplayer.sendMessage(ChatColor.AQUA + \"Some missiles did not fire. item check = \" + ChatColor.GOLD + missingMaterial);\n\t\t\t\t\t\t\tplayer.sendMessage(ChatColor.AQUA + \"numFiredCannons = \" + ChatColor.GOLD + numfiredcannons);\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t} else\n\t\t\t\tplayer.sendMessage(ChatColor.GOLD + this.properties.SHIP_TYPE + \" CANNOT FIRE TORPEDO\");\n\t\t} else\n\t\t\tplayer.sendMessage(ChatColor.GOLD + \"COOLING DOWN FOR \" + ChatColor.AQUA + (int)(Math.round(6 - (System.currentTimeMillis() - this.lastFired) / 1000)) + ChatColor.GOLD + \" MORE SECONDS\");\n\t}",
"public void wakeAnimals() {\n System.out.println(\"Waking the animals up...\\n\");\n for (int i = 0; i < zoo.length; i++){\n zoo[i].wake();\n }\n System.out.println();\n }",
"public void takePoison(int poison) { this.poison += poison; }",
"public interface Weapon {\n\n /**\n * method which is used when one war participant attacks other\n *\n * @param target target war participant\n * @param attacker attacker war participant\n */\n void fire(WarParticipant target, WarParticipant attacker, int noOfShooters);\n\n}",
"private void checkCollision()\n {\n if(isTouching(Rocket.class))\n {\n removeTouching(Rocket.class);\n Level1 level1 = (Level1)getWorld(); \n isSwordscore = false;\n notifyObservers(-20);\n }\n else if(isTouching(Fire.class))\n {\n removeTouching(Fire.class);\n Level1 level1 = (Level1)getWorld(); \n isSwordscore = false;\n notifyObservers(-20);\n }\n else if(isTouching(Sword.class))\n { \n removeTouching(Sword.class);\n Level1 level1 = (Level1)getWorld();\n isSwordscore = false;\n notifyObservers(-20);\n }\n \n else if(isTouching(Star.class))\n { \n removeTouching(Star.class);\n Level1 level1 = (Level1)getWorld();\n isSwordscore = false;\n count++;\n boost();\n }\n }",
"public static void worldTimeStep() {\r\n \t\r\n \t//remake the hash map based on the x and y coordinates of the critters\r\n \tremakeMap(population);\r\n \t\r\n \t//Iterate through the grid positions in the population HashMap\r\n \tIterator<String> populationIter = population.keySet().iterator();\r\n \twhile (populationIter.hasNext()) { \r\n String pos = populationIter.next();\r\n ArrayList<Critter> critterList = population.get(pos);\r\n \r\n //Iterate through the critters ArrayList \r\n ListIterator<Critter> currCritter = critterList.listIterator();\r\n while(currCritter.hasNext()) {\r\n \tCritter thisCritter = currCritter.next();\r\n \tthisCritter.hasMoved = false;\r\n \tthisCritter.doTimeStep();\r\n \tif(thisCritter.hasMoved || thisCritter.getEnergy() <= 0) {\r\n \t\tcurrCritter.remove();\r\n \t} else {\r\n \t\tcurrCritter.set(thisCritter);\r\n \t}\r\n }\r\n population.replace(pos, critterList);\r\n }\r\n \t\r\n \tfixPopulation();\r\n \tmergePopulationMoved(populationMoved);\r\n \t\r\n \tdoEncounters();\r\n \t\r\n \tfixPopulation();\r\n \tmergePopulationMoved(populationMoved); //Stage 1 Complete\r\n \r\n \t//deduct resting energy cost from all critters in the hash map\r\n \t//could do a FOR EACH loop instead of iterator -- fixed\r\n \tpopulationIter = population.keySet().iterator();\r\n \twhile(populationIter.hasNext()) {\r\n \t\tString pos = populationIter.next();\r\n ArrayList<Critter> critterList = population.get(pos);\r\n \r\n //Iterate through the Critters attached to the keys in the Hash Map\r\n ListIterator<Critter> currCritter = critterList.listIterator();\r\n while(currCritter.hasNext()) {\r\n \tCritter thisCritter = currCritter.next();\r\n \t//deduct the rest energy cost from each critter\r\n \tthisCritter.energy = thisCritter.energy - Params.REST_ENERGY_COST;\r\n \t//remove all critters that have died after reducing the rest energy cost\r\n \tif(thisCritter.getEnergy() <= 0) {\r\n \t\tcurrCritter.remove();\r\n \t} else {\r\n \t\tcurrCritter.set(thisCritter);\r\n \t}\r\n }\r\n population.replace(pos, critterList);\r\n \t}\r\n \t\r\n \tmergePopulationMoved(babies);\r\n \t\r\n \t\r\n \t//add the clovers in each refresh of the world \r\n \ttry {\r\n \t\tfor(int j = 0; j < Params.REFRESH_CLOVER_COUNT; j++) {\r\n \t\t\tcreateCritter(\"Clover\");\r\n \t\t}\r\n \t} catch(InvalidCritterException p) {\r\n \t\tp.printStackTrace();\r\n \t}\r\n }",
"public void tick()\n\t{\n\t\tfor(int i = 0; i < peopleList.size(); i++) {\n\t\t\tPerson tempObject = peopleList.get(i);\n\t\t\ttempObject.tick();\n\t\t}\n\t}",
"private void detect_fire(double o2 , double co2) {\n\t\tdouble o2_percent = o2 ; \r\n\t\tdouble co2_percent = co2 ; \r\n\t\tif(o2_percent < o2_percentage && co2_percent > co2_percentage ) {\r\n\t\t\tpump_water();\r\n\t\t}\r\n\t\t\r\n\t}",
"public void trackBullets(){\n for (int i = 0; i < bullets.size(); i++){\n Bullet tempBullet = bullets.get(i);\n //update the position of the bullets\n tempBullet.update();\n tempBullet.drawBullet();\n //check if the bullet hit the boundary, remove the bullet from the list of the bullet\n if(tempBullet.detectBound()){\n bullets.remove(i);\n continue;\n }\n //detect if the bullet hit the boss and cause the damage if yes\n if(tempBullet.hitObject(Main.boss) && Main.boss.alive){\n Main.boss.decreaseHealth(attack);\n tempBullet.drawHit();\n bullets.remove(i);\n if(Main.boss.health <= 0){\n Main.boss.alive = false;\n Main.boss.deadTime = millis();\n Main.score += 100;\n }\n }\n //detect if the bullet hit the enemy and cause the damage if yes\n for(int j = 0; j < Main.enemies.size(); j++){\n Enemy tempEnemy = Main.enemies.get(j);\n if(tempBullet.hitObject(tempEnemy) && tempEnemy.alive){\n tempBullet.drawHit();\n tempEnemy.decreaseHealth(attack);\n // if enemy is totally hitted, wait one 1s, and then removed\n if(tempEnemy.health <= 0){\n tempEnemy.alive = false;\n tempEnemy.deadTime = millis();\n }\n bullets.remove(i);\n break;\n }\n }\n }\n }",
"private void checkForDeaths() {\n Iterator<Entity> entityIter = this.entities.iterator();\n\n //geht alle teilnehmer durch\n while ( entityIter.hasNext() ) {\n Entity entity = entityIter.next();\n\n //und entfernt sie wenn sie tot sind aus der liste und der engine\n if ( this.combatMapper.get(entity).curHealth <= 0 ) {\n entityIter.remove();\n\n //alle actions der entity entfernen, können ja nichts machen wenn sie tot sind\n Iterator<IAction> actionIter = this.actions.iterator();\n\n while ( actionIter.hasNext() ) {\n if ( actionIter.next().getOwner().equals(entity) ) {\n actionIter.remove();\n }\n }\n\n this.combatExp += this.combatMapper.get(entity).level * 5; //TODO\n\n EventSystem.getInstance().commitEvent(new Event(EventSystem.EventType.KILL_EVENT, entity));\n\n this.combatSystem.getEngine().removeEntity(entity);\n }\n }\n }",
"public void areaEffect(Player player){\n if(object.getProperties().containsKey(\"endLevel\")) {\n System.out.println(\"Fin du level\");\n setCategoryFilter(GameTest.DESTROYED_BIT);\n PlayScreen.setEndLevel();\n }\n\n if(object.getProperties().containsKey(\"startBossFight\")) {\n\n System.out.println(\"Start Boss Fight\");\n setCategoryFilter(GameTest.DESTROYED_BIT);\n\n TiledMapTileLayer.Cell cell = new TiledMapTileLayer.Cell();\n cell.setTile(tileSet.getTile(910));\n layer.setCell(99, 6, cell);\n cell.setTile(tileSet.getTile(910));\n layer.setCell(99, 7, cell);\n cell.setTile(tileSet.getTile(910));\n layer.setCell(99, 8, cell);\n cell.setTile(tileSet.getTile(910));\n layer.setCell(99, 9, cell);\n\n cell.setTile(tileSet.getTile(910));\n layer.setCell(100, 6, cell);\n cell.setTile(tileSet.getTile(910));\n layer.setCell(100, 7, cell);\n cell.setTile(tileSet.getTile(910));\n layer.setCell(100, 8, cell);\n cell.setTile(tileSet.getTile(910));\n layer.setCell(100, 9, cell);\n\n PlayScreen.cameraChangeBoss(true);\n setCategoryFilterFixture(GameTest.GROUND_BIT, PlayScreen.getFixtureStartBoss());\n\n }\n\n if(object.getProperties().containsKey(\"blueKnight\")) {\n System.out.println(\"Changement en bleu\");\n setCategoryFilter(GameTest.DESTROYED_BIT);\n getCell().setTile(null);\n PlayScreen.setColorKnight(\"blue\");\n }\n\n if(object.getProperties().containsKey(\"greyKnight\")) {\n System.out.println(\"Changement en gris\");\n setCategoryFilter(GameTest.DESTROYED_BIT);\n getCell().setTile(null);\n PlayScreen.setColorKnight(\"grey\");\n }\n\n if(object.getProperties().containsKey(\"redKnight\")) {\n System.out.println(\"Changement en rouge\");\n setCategoryFilter(GameTest.DESTROYED_BIT);\n getCell().setTile(null);\n PlayScreen.setColorKnight(\"red\");\n }\n\n }",
"void takeDamage(int points) {\n this.health -= points;\n }",
"public void act()\n {\n \n if (wait < 75)\n {\n wait = wait + 1;\n }\n \n \n \n \n \n \n if (wait == 75)\n {\n change();\n checkForBounce();\n checkForEdge();\n checkWin(); \n }\n \n \n }",
"public static void runStats(List<Critter> critters) {\n\t\tSystem.out.print(\"\" + critters.size() + \" critters as follows -- \");\n\t\tjava.util.Map<String, Integer> critter_count = new java.util.HashMap<String, Integer>();\n\t\tfor (Critter crit : critters) {\n\t\t\tString crit_string = crit.toString();\n\t\t\tInteger old_count = critter_count.get(crit_string);\n\t\t\tif (old_count == null) {\n\t\t\t\tcritter_count.put(crit_string, 1);\n\t\t\t} else {\n\t\t\t\tcritter_count.put(crit_string, old_count.intValue() + 1);\n\t\t\t}\n\t\t}\n\t\tString prefix = \"\";\n\t\tfor (String s : critter_count.keySet()) {\n\t\t\tSystem.out.print(prefix + s + \":\" + critter_count.get(s));\n\t\t\tprefix = \", \";\n\t\t}\n\t\tSystem.out.println();\t\t\n\t}",
"public void strategy(IFruitThrower[] throwers) {\r\n\t\t\r\n\t\t//for each thrower in our team\r\n\t\tfor(int i = 0; i < throwers.length; i++){\r\n\t\t\tIFruitThrower t = throwers[i];\r\n\t\t\r\n\t\t\t//throw at a random enemy position\r\n\t\t\tt.throwAt(rand.nextInt(Rules.BASKET_CNT()));\r\n\t\t}\r\n\t}",
"public void update()\r\n\t{\r\n\t\tList<Unit> deadButNotFinished = new ArrayList<Unit>();\r\n\t\t//first check for dead units\r\n\t\tfor(int i = 0; i < units.size();)\r\n\t\t\tif(units.get(i).getState() == MapItemState.Dead && units.get(i).finished()) {\r\n\t\t\t\towner.notifySweepAndPruneUnitRemoved(units.remove(i));\r\n\t\t\t} else if(units.get(i).getState().equals(MapItemState.Dead)) {\r\n\t\t\t\tdeadButNotFinished.add(units.remove(i));\r\n\t\t\t} else {\r\n\t\t\t\ti++;\r\n\t\t\t}\r\n\t\t\r\n\t\t//don't do anything if there are no units\r\n\t\tif(units.size() <= 0 && deadButNotFinished.size() <= 0)\r\n\t\t{\r\n\t\t\tinCombat = false;\r\n\t\t\treturn;\r\n\t\t}\r\n\t\t\r\n\r\n\t\t//if(!(units.get(0) instanceof Gate))\r\n\t\t\t//System.out.println(\"Unit position == \" + units.get(0).getPosition().getX() + \", \" + units.get(0).getPosition().getY());\r\n\t\t\r\n\t\t//first get the max radius\r\n\t\tdouble maxRad = 0;\r\n\t\tPosition center = this.getCenter();\r\n\t\tfor(Unit u : units)\r\n\t\t{\r\n\t\t\tdouble rad = Math.sqrt(center.distanceSquared(u.getPosition())) + u.getCombatStrategy().getRange();\r\n\t\t\tif(rad > maxRad)\r\n\t\t\t\tmaxRad = rad;\r\n\t\t}\r\n\t\t\r\n\t\t//this is to prevent units from doing a run by on accident\r\n\t\tif(maxRad < owner.getWidth())\r\n\t\t\tmaxRad = owner.getWidth();\r\n\t\t\r\n\t\tAABB box = new AABB(center.getX() - maxRad, center.getY() - maxRad, \r\n\t\t\t\tcenter.getX() + maxRad, center.getY() + maxRad);\r\n\t\tList<Unit> unitsInRange = owner.getUnitsIn(box);\r\n\t\tList<Unit> alliesInRange = new ArrayList<Unit>();\r\n\t\t//remove friendly units\r\n\t\tfor(int i = 0; i < unitsInRange.size();)\r\n\t\t\tif(unitsInRange.get(i).getOwner().equals(units.get(0).getOwner()))\r\n\t\t\t\talliesInRange.add(unitsInRange.remove(i));\r\n\t\t\telse\r\n\t\t\t\ti++;\r\n\t\t\r\n\t\t//if there are units, we're in combat!\r\n\t\tif(unitsInRange.size() > 0)\r\n\t\t{\r\n\t\t\t//for efficiency reasons\r\n\t\t\tUnit[] unitsInRangeArray = unitsInRange.toArray(new Unit[unitsInRange.size()]);\r\n\t\t\tUnit[] alliesInRangeArray = alliesInRange.toArray(new Unit[alliesInRange.size()]);\r\n\t\t\tfor(Unit u : units)\r\n\t\t\t\tu.getCombatStrategy().fight(unitsInRangeArray, alliesInRangeArray);\r\n\t\t\tinCombat = true;\r\n\t\t}\r\n\t\telse\r\n\t\t{\r\n\t\t\tinCombat = false;\r\n\t\t\t//figure out which direction we're going\r\n\t\t\tboolean forward = true;\r\n\t\t\tif (origin.getTransformation().getPosition().distanceSquared(\r\n\t\t\t\t\towner.getPosition(1).getPosition()) < origin.getTransformation().getPosition()\r\n\t\t\t\t\t.distanceSquared(owner.getPosition(0).getPosition()))\r\n\t\t\t\tforward = false;\r\n\t\t\t\r\n\t\t\t//we're gonna move straight forward because I said so -Connor\r\n\t\t\tdouble wayTheFuckOutThere = 100000000;\r\n\t\t\tdouble min = 1;\r\n\t\t\t\r\n\t\t\t//for efficiency reasons\r\n\t\t\tHashMap<Unit, Transformation> closestPoints = new HashMap<Unit, Transformation>();\r\n\t\t\t\r\n\t\t\t//go through each unit and see how far it's going to go\r\n\t\t\tfor(int i = 0; i < units.size();)\r\n\t\t\t{\r\n\t\t\t\tUnit u = units.get(i);\r\n\t\t\t\tdouble pos = u.getPositionAlongCurve();\r\n\t\t\t\tNode target = owner.getNodes()[0];\r\n\t\t\t\tif(target.equals(origin))\r\n\t\t\t\t\ttarget = owner.getNodes()[1];\r\n\t\t\t\t//check to see if we've made it to the node we're going for\r\n\t\t\t\t//also, don't allow entering the node if the gate is still up\r\n\t\t\t\tif(((forward && Math.abs(1 - pos) <= 0.01) || (!forward && Math.abs(pos) <= 0.01)) && \r\n\t\t\t\t\t\t(owner.getGate(target) == null || owner.getGate(target).getState().equals(MapItemState.Dead) \r\n\t\t\t\t\t\t\t\t|| u.getOwner().equals(owner.getGate(target).getOwner())))\r\n\t\t\t\t{\r\n\t\t\t\t\tif(target.getOwner() == null || target.isContested() || !target.getOwner().equals(u.getOwner()))\r\n\t\t\t\t\t\ttarget.setInvader(u.getOwner());\r\n\t\t\t\t\tu.setTransformation(target.getTransformation());\r\n\t\t\t\t\ttarget.addUnit(u);\r\n\t\t\t\t\towner.notifySweepAndPruneUnitRemoved(units.remove(i));\r\n\t\t\t\t\tcontinue;\r\n\t\t\t\t}\r\n\t\t\t\t//if we're close enough but the gate isn't down\r\n\t\t\t\telse if((forward && Math.abs(1 - pos) <= 0.01) || (!forward && Math.abs(pos) <= 0.01))\r\n\t\t\t\t{\r\n\t\t\t\t\tTransformation t = owner.getPosition(pos);\r\n\t\t\t\t\tclosestPoints.put(u, t);\r\n\t\t\t\t\tu.setState(MapItemState.Idle);\r\n\t\t\t\t\tu.getMovementStrategy().setTarget(u.getTransformation());\r\n\t\t\t\t\ti++;\r\n\t\t\t\t\tcontinue;\r\n\t\t\t\t}\r\n\t\t\t\telse\r\n\t\t\t\t\ti++;\r\n\t\t\t\t\r\n\t\t\t\tTransformation t = owner.getPosition(pos);\r\n//\t\t\t\tif(Math.abs(t.getRotation()) < .001){\r\n//\t\t\t\t\tSystem.out.println(\"t's rotation is 0\");\r\n//\t\t\t\t}\r\n\t\t\t\tclosestPoints.put(u, t);\r\n\t\t\t\tdouble angle = t.getRotation();\r\n\t\t\t\tif(!forward)\r\n\t\t\t\t\tangle -= Math.PI;\r\n\t\t\t\tdouble m = u.getMovementStrategy().setTarget(\r\n\t\t\t\t\t\tnew Transformation(u.getPosition().add(\r\n\t\t\t\t\t\t\t\twayTheFuckOutThere * Math.cos(angle),\r\n\t\t\t\t\t\t\t\twayTheFuckOutThere * Math.sin(angle)), angle));\r\n\t\t\t\tif(m < min)\r\n\t\t\t\t\tmin = m;\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t//go through each unit and set its actual target\r\n\t\t\tdouble dis = wayTheFuckOutThere*min;\r\n\t\t\tfor(int i = 0; i < units.size(); i++)\r\n\t\t\t{\r\n\t\t\t\tdouble angle = closestPoints.get(units.get(i)).getRotation();\r\n\t\t\t\tif(!forward)\r\n\t\t\t\t\tangle -= Math.PI;\r\n//\t\t\t\tTransformation t = owner.getPosition(owner.getClosestPointRatio(closestPoints.get(i)\r\n//\t\t\t\t\t\t\t\t.getPosition().add(dis * Math.cos(angle),dis * Math.sin(angle)))); \r\n\t\t\t\tTransformation t = new Transformation(units.get(i).getPosition().add(dis*Math.cos(angle), dis*Math.sin(angle)), angle);\r\n\t\t\t\tunits.get(i).getMovementStrategy().setTarget(t);\r\n\t\t\t}\r\n\t\t\tinCombat = false;\r\n\t\t}\r\n\t\t\r\n\t\tfor(Unit u : units)\r\n\t\t{\r\n\t\t\tu.getMovementStrategy().move();\r\n\t\t\tu.updateMapItem();\r\n\t\t}\r\n\t\t\r\n\t\t//add the dead but not finished units back in\r\n\t\t//also call update for them so they may finish their abilities\r\n\t\tfor(Unit u : deadButNotFinished)\r\n\t\t{\r\n\t\t\tu.updateMapItem();\r\n\t\t\tunits.add(u);\r\n\t\t}\r\n\t\t\r\n\t\tfor(Unit u : unitsInNeedOfRemoval)\r\n\t\t{\r\n\t\t\tunits.remove(u);\r\n\t\t\towner.notifySweepAndPruneUnitRemoved(u);\r\n\t\t}\r\n\t\tunitsInNeedOfRemoval.clear();\r\n\t}",
"private void pump_water() {\n\t\t\r\n\t}",
"@Override\n protected void doCheckEffect ()\n {\n // check all the stationary spells in the location of the projectile for a Colloportus\n List<O2StationarySpell> inside = new ArrayList<>();\n for (O2StationarySpell spell : Ollivanders2API.getStationarySpells(p).getStationarySpellsAtLocation(location))\n {\n if (spell instanceof COLLOPORTUS)\n {\n inside.add(spell);\n }\n }\n\n // remove the colloportus spells found\n if (inside.size() > 0)\n {\n for (O2StationarySpell spell : inside)\n {\n spell.kill();\n spell.flair(10);\n }\n\n kill();\n }\n\n // if the spell has hit a solid block, the projectile is stopped and wont go further so kill the spell\n if (hasHitTarget())\n kill();\n }"
] | [
"0.63842773",
"0.59653026",
"0.5829087",
"0.57296425",
"0.57162714",
"0.5620517",
"0.56181824",
"0.55599445",
"0.5558895",
"0.55536705",
"0.5551674",
"0.5543951",
"0.54826355",
"0.5465921",
"0.54625994",
"0.5423471",
"0.5422933",
"0.53955704",
"0.53888136",
"0.53865474",
"0.53806645",
"0.5372851",
"0.5370385",
"0.53469515",
"0.53393006",
"0.53306836",
"0.5310335",
"0.5305554",
"0.52898157",
"0.5281605",
"0.5278859",
"0.5275937",
"0.5261741",
"0.52541965",
"0.52514625",
"0.52426136",
"0.52424407",
"0.5236971",
"0.52345175",
"0.52333677",
"0.52327204",
"0.52288485",
"0.52161175",
"0.5212139",
"0.5210134",
"0.52027464",
"0.51961505",
"0.5194741",
"0.5182318",
"0.5176115",
"0.51731235",
"0.51625663",
"0.5160665",
"0.5157765",
"0.5152033",
"0.5142495",
"0.51389015",
"0.5137738",
"0.51366943",
"0.5135402",
"0.5132441",
"0.5126563",
"0.5126065",
"0.51224643",
"0.512232",
"0.5105433",
"0.5098903",
"0.5087012",
"0.5081183",
"0.50666875",
"0.5053481",
"0.50487",
"0.50435096",
"0.50424635",
"0.50410444",
"0.50399655",
"0.50388914",
"0.503668",
"0.5035542",
"0.5033047",
"0.50322104",
"0.50318205",
"0.5019262",
"0.50190055",
"0.5016344",
"0.50116706",
"0.50071365",
"0.49969962",
"0.49961263",
"0.49947456",
"0.49946532",
"0.49938294",
"0.49922138",
"0.4988455",
"0.49878252",
"0.4979829",
"0.49784273",
"0.4976319",
"0.49754775",
"0.49753687"
] | 0.73629755 | 0 |
Get Tower at a specific point on map. | public static Tower getTowerAt(int x, int y) {
for(Tower t: towers) {
if(t.getX()==x && t.getY()==y) {
return t;
}
}
return null;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public SniperTower getSniperTower(int x, int y) {\n SniperTower thisSniperTower = null;\n for (SniperTower t : sniperTowers) {\n if (x == t.towerY && y == t.towerX) {\n thisSniperTower = t;\n }\n }\n return thisSniperTower;\n }",
"public BasicTower getBasicTower(int x, int y) {\n BasicTower thisBasicTower = null;\n for (BasicTower t : basicTowers) {\n if (x == t.towerY && y == t.towerX) {\n thisBasicTower = t;\n }\n }\n return thisBasicTower;\n }",
"Tower(Point location)\r\n\t{\r\n\t\tthis.location=location;\r\n\t}",
"public Point getRobotLocation();",
"public QuickTower getQuickTower(int x, int y) {\n QuickTower thisQuickTower = null;\n for (QuickTower t : quickTowers) {\n if (x == t.towerY && y == t.towerX) {\n thisQuickTower = t;\n }\n }\n return thisQuickTower;\n }",
"public Tile getTileAt(Position p);",
"private Tile getTileAt(Position p) {\n return getTileAt(p.getRow(), p.getCol());\n }",
"MapLocation getPosition(Unit unit);",
"@Override\n public Location getLocation(MapPoint point) {\n if (point == null) return null;\n\n World world = worlds.get(point.getWorld());\n\n float yaw = point.getYaw();\n float pitch = point.getPitch();\n\n //Account for the fact that NaN yaw/pitch indicate that they shouldn't be changed / are not present\n if (Float.isNaN(yaw)) yaw = 0;\n if (Float.isNaN(pitch)) pitch = 0;\n\n return new Location(world, point.getX(), point.getY(), point.getZ(), yaw, pitch);\n }",
"public Point getLocation();",
"public OthelloTile getTile(Point p) {\n if(p == null) {\n return null;\n }\n int x = (p.x-35)/grid[0][0].getPreferredSize().width;\n int y = (p.y-35)/grid[0][0].getPreferredSize().height;\n if(x<0 || x>=grid.length || y<0 || y>=grid[0].length) {\n return null;\n }\n return grid[y][x];\n }",
"public OsmPrimitive getNearest(Point p) {\n OsmPrimitive osm = getNearestNode(p);\n if (osm == null)\n {\n osm = getNearestWay(p);\n }\n return osm;\n }",
"public abstract Class<? extends Tower> getTower();",
"@Override\n public ITile getClosestTile(int x, int y) {\n return getClosestTile(new Point(x, y), getTileSize());\n }",
"public IEntity getOnTheMapXY(int x, int y) {\r\n\t\t// we check if we are not at the edge of the map\r\n\t\t if(x >= 0 && x < Map.getWidth() && y >= 0 && y < Map.getHeight())\r\n\t\t \treturn this.map[x][y];\r\n\t\t else\r\n\t\t \treturn this.map[0][0];\r\n\t\t \r\n\t}",
"public abstract BaseCreature getCreature(Point p);",
"public Town getTraleeLocation1() {\n\t\treturn new Town(\"Town Park Denny Street\");\r\n\t}",
"public Location getLocation() {\n return ((Location) tile);\n }",
"public abstract Tile getTileAt(int x, int y);",
"public Node atLocation(Point p) {\n return mazeMap.get(p);\n }",
"public Widget findOne(Point p) {\n // we need to deal with scaled points because of zoom feature\n Point2D.Double scaledPos = new Point2D.Double();\n scaledPos.x = (double)p.x;\n scaledPos.y = (double)p.y;\n if (zoomFactor > 1) // transforms are only needed in zoom mode\n inv_at.transform(scaledPos, scaledPos);\n Point2D.Double mappedPos = u.fromWinPoint(scaledPos);\n// System.out.println(\"findOne: Z=\" + zoomFactor + \" p=[\" + p.x + \",\" + p.y + \"] \" \n// + \" s=[\" + scaledPos.getX() + \",\" + scaledPos.getY() + \"]\"\n// + \" m=[\" + mappedPos.getX() + \",\" + mappedPos.getY() + \"]\");\n Widget ret = null;\n for (Widget w : widgets) {\n if (w.contains(mappedPos)) {\n// System.out.println(\"found: \" + w.getKey() + \" p= \" + p + w.getBounded());\n ret = w;\n }\n }\n return ret;\n }",
"public Object getObjectAtLocation(Point p);",
"public BomberTower getBomberTower(int x, int y) {\n BomberTower thisBomberTower = null;\n for (BomberTower t : bomberTowers) {\n if (x == t.bombertowerY && y == t.bombertowerX) {\n thisBomberTower = t;\n }\n }\n return thisBomberTower;\n }",
"public Point2D getLocation();",
"PositionVector getWaypoint(int index);",
"MazePoint getActivePlayerCoordinates();",
"public final Optional<Tile> getTile(final GridPoint2D tilePoint) {\n\t if ((tilePoint.getRow() >= 0) && \n\t (tilePoint.getRow() < mLayout.size()) &&\n\t (tilePoint.getColumn() >= 0) && \n\t (tilePoint.getColumn() < mLayout.get(tilePoint.getRow()).size())) {\n\t return Optional.<Tile>of(mLayout.get(tilePoint.getRow()).get(tilePoint.getColumn()));\n\t } \n\t // The indicated point was outside of the battlefield, so return a null\n\t else {\n\t return Optional.<Tile>absent();\n\t }\n\t}",
"public static Point mapPoint(Point point) {\n\t\treturn point;\n\t}",
"IntPoint getLocation();",
"public DungeonObject getDungeonTile(int x, int y) {\n\t\treturn dungeonRoom[x][y];\r\n\t}",
"public int getTile(int x, int y)\n {\n return tilemap[x][y];\n }",
"@Override\n\tpublic Class<? extends Tower> getTower() {\n\t\t// TODO Auto-generated method stub\n\t\treturn MageTower.class;\n\t}",
"public int getGotoFloor();",
"public Town getLocation1() {\n\t\treturn new Town(\"Phoenix Park, Dublin 8\");\r\n\t}",
"void placeTower();",
"@Override\n public SquareTile getTile(Point location) {\n return getTile(location.getX(), location.getY());\n }",
"public TowerPanelView getTowerView() {\r\n return towerPanel;\r\n }",
"public Tile getTileAt(Point position) {\n\t\treturn getTileAt(position.x, position.y);\n\t}",
"public Coordinate getLocation();",
"public KDPoint getPoint() {\n\t\treturn new KDPoint(this.loc.lat,this.loc.lng,0.0);\n\t}",
"private Point getLower() {\n int lowerX;\n int lowerY;\n lowerY = (int) (-gameCanvas.getHeight() + mapOffsetY * 2);\n lowerX = (int) (-gameCanvas.getWidth() + mapOffsetX * 2);\n return new Point(lowerX, lowerY);\n }",
"public int getLat();",
"public Actor getLocation(Location currentLocation, GameMap map) {\n Map<Actor, Location> dinosaursList = new HashMap<>();\n dinosaursList = getAllActors(map);\n Location minimalLocation = null;\n\n for (Map.Entry<Actor, Location> spot: dinosaursList.entrySet()) {\n Actor actor = spot.getValue().getActor();\n int x = spot.getValue().x();\n int y = spot.getValue().y();\n Location there = map.at(x,y);\n if (actor instanceof Dinosaur) {\n if (currentLocation != there) {\n if (minimalLocation == null) {\n minimalLocation = there;\n } else if (super.distance(currentLocation, there) < super.distance(currentLocation, minimalLocation)) {\n minimalLocation = there;\n }\n }\n }\n }\n\n return map.getActorAt(minimalLocation);\n }",
"public MapEntity getTileAt(IntVector2D v) {\n\t\tif(v == null)\n\t\t\treturn null;\n\t\treturn getTileAt(v.getX(), v.getY());\n\t}",
"public Station getStationByPos(int x, int y)\r\n\t{\r\n\t\t\r\n\t\tfor(Line l : line)\r\n\t\t{\r\n\t\t\tint i = 0;\r\n\t\t\t\r\n\t\t\tfor(int j = 0 ; j < l.getNumberOfStation() ; j++)\r\n\t\t\t{\r\n\t\t\t\tStation tmp = l.returnStation(i);\r\n\t\t\t\t\r\n\t\t\t\tif(Math.abs(tmp.getPosX() - x) < 5 && Math.abs(tmp.getPosY() - y) < 5)\r\n\t\t\t\t{\r\n\t\t\t\t\treturn tmp;\r\n\t\t\t\t}\r\n\t\t\t\t\r\n\t\t\t\ti++;\r\n\t\t\t}\r\n\t\t}\r\n\t\t\r\n\t\treturn null;\r\n\t}",
"public Point getLocation() { return loc; }",
"public MapEntity getTileAt(int x, int y) {\n\t\ttry {\n\t\t\treturn tiles.get(y)[x];\n\t\t}\n\t\tcatch(IndexOutOfBoundsException | NullPointerException e) {\n\t\t\treturn null;\n\t\t}\n\t}",
"public final AbstractWaypoint getWaypoint() {\n return this.waypointProperty().getValue();\n }",
"public Town getLocation() {\n\t\treturn new Town(\"St James's Gate, Ushers, Dublin 8\");\r\n\t}",
"public Location getBedSpawnLocation ( ) {\n\t\treturn extract ( handle -> handle.getBedSpawnLocation ( ) );\n\t}",
"public Point getStartPoint() {\n // First, this is Settler's location\n UnitList units = unitService.findByClassUuid(Settlers.CLASS_UUID);\n if (units != null && !units.isEmpty()) {\n return units.getAny().getLocation();\n }\n\n // If Settlers were destroyed then it is the first city's location\n City city = cityService.getAny();\n if (city != null) {\n return city.getLocation();\n }\n\n // If there is no cities, then the first Unit's location\n AbstractUnit unit = unitService.getAny();\n if (unit != null) {\n return unit.getLocation();\n }\n\n // If there is no units then (0, 0)\n return new Point(0, 0);\n }",
"public FloorTile getTileAt(int row, int col) {\n return board[row][col];\n }",
"private boolean towerLocation(final Point current_point) {\r\n\t\tfor (int i = 0; i < my_towers.size(); i++) {\r\n\t\t\tif (my_towers.get(i).getLocation().equals(current_point)) {\r\n\t\t\t\treturn true;\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn false;\r\n\t}",
"@Override\r\n\tpublic Point getWaku() {\r\n\t\treturn new Point(wx, wy);\r\n\t}",
"public Pieces getDroneAt(double x, double y) {\n //first look for obstacle\n for (Pieces d : drones) {\n if(d instanceof Obstacle) {\n if (d.isHere(x, y)) {\n return d; //if drone there, return that drone\n\n }\n }\n }\n //then drones\n for (Pieces d : drones) {\n if(d instanceof Bird) {\n if (d.isHere(x, y)) {\n return d; //if drone there, return that drone\n\n }\n }\n }\n //then birds\n for (Pieces d : drones) {\n if(d instanceof Drone && !(d instanceof Bird)) {\n if (d.isHere(x, y)) {\n return d; //if drone there, return that drone\n\n }\n }\n }\n\n return null;\t\t//if not found, return null\n }",
"private Point getClosestPoint(Point[] mapPoints, Point newPoint) {\n for (int i = 0; i < mapPoints.length; i++) {\n if (ShortestPath.distance(newPoint, mapPoints[i]) < 30) {\n newPoint.x = mapPoints[i].x + 10;\n newPoint.y = mapPoints[i].y + 10;\n return newPoint;\n }\n }\n return null;\n }",
"public MapLocation getEnemySwarmTarget() {\n\t\tdouble a = Math.sqrt(vecEnemyX * vecEnemyX + vecEnemyY * vecEnemyY) + .001;\n\n\t\treturn new MapLocation((int) (vecEnemyX * 7 / a) + br.curLoc.x,\n\t\t\t\t(int) (vecEnemyY * 7 / a) + br.curLoc.y);\n\n\t}",
"public Coordinates closestPoint() {\n return closestPoint;\n }",
"Tile getPosition();",
"public static Point worldToMap(double x, double y) {\n\t\tfinal Client client = Context.client();\n\t\tfinal Multipliers multipliers = Context.multipliers();\n\t\tfinal Player local = Players.getLocal();\n\t\tx -= Game.getBaseX();\n\t\ty -= Game.getBaseY();\n\n\t\tfinal RegionOffset localTile = local.getRegionOffset();\n\t\tfinal int calculatedX = (int) (x * 4 + 2) - (localTile.getX() << 9) / 0x80;\n\t\tfinal int calculatedY = (int) (y * 4 + 2) - (localTile.getY() << 9) / 0x80;\n\n\t\tfinal WidgetChild mm2 = WidgetComposite.getMap();\n\t\tif (mm2 == null) {\n\t\t\treturn new Point(-1, -1);\n\t\t}\n\t\tfinal int actDistSq = calculatedX * calculatedX + calculatedY * calculatedY;\n\t\tfinal int mmDist = Math.max(mm2.getWidth() / 2, mm2.getHeight() / 2) - 6;\n\n\t\tif (mmDist * mmDist >= actDistSq) {\n\t\t\tint angle = 0x3fff & (int) client.getMinimapAngle();\n\t\t\tfinal boolean setting4 = client.getMinimapSetting() * multipliers.GLOBAL_MINIMAPSETTING == 4;\n\n\t\t\tif (!setting4) {\n\t\t\t\tangle = 0x3fff & (client.getMinimapOffset() * multipliers.GLOBAL_MINIMAPOFFSET) + (int) client.getMinimapAngle();\n\t\t\t}\n\n\t\t\tint cs = Calculations.SIN_TABLE[angle];\n\t\t\tint cc = Calculations.COS_TABLE[angle];\n\n\t\t\tif (!setting4) {\n\t\t\t\tfinal int fact = 0x100 + (client.getMinimapScale() * multipliers.GLOBAL_MINIMAPSCALE);\n\t\t\t\tcs = 0x100 * cs / fact;\n\t\t\t\tcc = 0x100 * cc / fact;\n\t\t\t}\n\n\t\t\tfinal int calcCenterX = cc * calculatedX + cs * calculatedY >> 0xf;\n\t\t\tfinal int calcCenterY = cc * calculatedY - cs * calculatedX >> 0xf;\n\t\t\tfinal int screen_x = calcCenterX + mm2.getAbsoluteX() + mm2.getWidth() / 2;\n\t\t\tfinal int screen_y = -calcCenterY + mm2.getAbsoluteY() + mm2.getHeight() / 2;\n\t\t\treturn new Point(screen_x, screen_y);\n\t\t}\n\n\t\treturn new Point(-1, -1);\n\t}",
"public GridPoint myGridPoint(){\n\n Location location = myLocation();\n if (location != null){\n\n double latitude = location.getLatitude();\n double longitude = location.getLongitude();\n MapProjection mapProjection = MapProjection.getDefault();\n GridPoint gp = mapProjection.toGridPoint(latitude,longitude);\n return gp;\n\n } else {\n\n //If GPS is off, notify the user to turn it on\n Toast.makeText(MainActivity.this,\"Turn on GPS.\",Toast.LENGTH_SHORT).show();\n return null;\n\n }\n\n }",
"public Point getLocation() {\n Map<String, Long> map = (java.util.Map<String, Long>) driver.executeAtom(\n atoms.getLocationJs, false, this);\n return new Point(map.get(\"x\").intValue(), map.get(\"y\").intValue());\n }",
"public Point getLocPoint(){\n return super.getLocation();\n }",
"public Tile getTile(int pos) {\n\t\tObject t = tileList.get(pos);\n\t\tif(t instanceof Property){\n\t\t\treturn (Property) t;\n\t\t} else if(t instanceof TaxTile){\n\t\t\treturn (TaxTile) t;\n\t\t} else { // Should not happen\n\t\t\treturn (Tile) t;\n\t\t}\n\t}",
"private Point getMainPoint()\n {\n // Center of screen\n int x = (findViewById(R.id.the_canvas).getWidth() - ((GameBoard)findViewById(R.id.the_canvas)).getMainSpriteWidth())/2;\n // Very bottom of screen\n int y = findViewById(R.id.the_canvas).getHeight() - ((GameBoard)findViewById(R.id.the_canvas)).getMainSpriteHeight();\n\n return new Point (x,y);\n }",
"public Coordinate getMoveTo();",
"public FloorTile getGoalTile() {\r\n return goalTile;\r\n }",
"public ImmutableSimpleLocation getWarp() {\n return warp;\n }",
"int getPlayerLocation(Player p) {\n\t\t\treturn playerLocationRepo.get(p);\n\t\t}",
"@Override\n public Location getLocation() {\n if (type == TeleportType.TPA) {\n return target.getPlayerReference(Player.class).getLocation();\n } else if (type == TeleportType.TPHERE) {\n return toTeleport.getPlayerReference(Player.class).getLocation();\n }\n\n return null;\n }",
"public int getCurrentFloor();",
"public Town getDroghedaLocation1() {\n\t\treturn new Town(\"Louth\");\r\n\t}",
"Location getPlayerLocation();",
"public Tile getTile(int x, int y, int z) {\r\n\t\treturn map.getTile(x, y, z);\r\n\t}",
"public Point getSpawn() {\n\t\treturn spawn;\n\t}",
"public Point2D nearest(Point2D p) {\n if (p == null) throw new NullPointerException();\n Point2D champion = pointSet.first();\n if (champion == null) return null;\n \n for (Point2D point : pointSet) {\n if (point.distanceSquaredTo(p) < champion.distanceSquaredTo(p)) {\n champion = point;\n }\n }\n return champion;\n }",
"godot.wire.Wire.Vector2 getOrigin();",
"@Override\r\n\tpublic Town getTraleeLocation() {\n\t\treturn new Town(\" Ashe Memorial Hall \");\r\n\t}",
"private VolaTile getCaveTile() {\n/* */ try {\n/* 2147 */ Zone z = Zones.getZone(this.tilex, this.tiley, false);\n/* 2148 */ return z.getOrCreateTile(this.tilex, this.tiley);\n/* */ }\n/* 2150 */ catch (NoSuchZoneException noSuchZoneException) {\n/* */ \n/* */ \n/* 2153 */ logger.log(Level.WARNING, \"No cave tile for \" + this.tilex + \", \" + this.tiley);\n/* 2154 */ return this;\n/* */ } \n/* */ }",
"private ILocation GetWarp(IPlayer owner, String name)\r\n\t{\r\n\t\tString key = cacheKey(owner, name);\r\n\t\tILocation location = cache.Cache(key);\r\n\t\tif (location != null)\r\n\t\t\treturn location;\r\n\r\n\t\tif (owner == null)\r\n\t\t\tlocation = database.queryLocation(\r\n\t\t\t\t\"SELECT world, x, y, z, yaw, pitch FROM warpdrive_locations WHERE name=? AND `public`=1\",\r\n\t\t\t\tname\r\n\t\t\t);\r\n\t\telse\r\n\t\t\tlocation = database.queryLocation(\r\n\t\t\t\t\"SELECT world, x, y, z, yaw, pitch FROM warpdrive_locations WHERE name=? AND `public`=0 AND creator=?\",\r\n\t\t\t\tname, owner\r\n\t\t\t);\r\n\r\n\t\treturn cache.Cache(key, location);\r\n\t}",
"public FloorTile getTileFromTheBoard(int row, int col) {\r\n return board[row][col];\r\n }",
"public Vector2 returnToNearestStockpile(Resource resource){\n\t\tif(myTownHall == null)\n\t\t\treturn new Vector2(0,0);\n\t\treturn myTownHall.getCenter();\n\t}",
"public static MapLocation myLocation() {\n return RC.getLocation();\n }",
"@Override\n public MapLocation getLocation(int x, int y)\n {\n XYCoord coord = new XYCoord(x, y);\n MapLocation masterLoc = master.getLocation(coord);\n MapLocation returnLoc = masterLoc;\n if( isLocationFogged(coord) || // If we can't see anything...\n (isLocationEmpty(coord) && !master.isLocationEmpty(coord)) ) // ...or what's there is hidden\n {\n returnLoc = new MapLocation(returnLoc.getEnvironment(), coord);\n returnLoc.setOwner( lastOwnerSeen[x][y] );\n }\n return returnLoc;\n }",
"int getMapPointID();",
"public TileMap getMyTileMap() {\n return this.myTileMap;\n }",
"public Point getMinimapLocation() {\n Actor c = getAccessor();\n int cX = methods.client.getBaseX() + (c.getLocalLocation().getX() / 32 - 2) / 4;\n int cY = methods.client.getBaseY() + (c.getLocalLocation().getY() / 32 - 2) / 4;\n return methods.calc.worldToMinimap(cX, cY);\n }",
"public Point2D nearest(Point2D p) {\n return nearestHelper(root, new RectHV(0,0,1,1), p.x(), p.y(), null);\n }",
"private int getOtherTower(int tower1, int tower2) {\n\t\tswitch(tower1) {\n\t\t\tcase 1:\n\t\t\t\tif(tower2 == 2) return 3;\n\t\t\t\telse return 2;\n\t\t\tcase 2:\n\t\t\t\tif(tower2 == 1) return 3;\n\t\t\t\telse return 1;\n\t\t\tcase 3:\n\t\t\t\tif(tower2 == 1) return 2;\n\t\t\t\telse return 1;\n\t\t\tdefault:\n\t\t\t\tthrow new IllegalArgumentException(\n\t\t\t\t\t\"The tower to choose must be 1, 2, or 3. Given: \" \n\t\t\t\t\t+ tower1 \n\t\t\t\t\t+ \" and \" \n\t\t\t\t\t+ tower2);\n\t\t}\n\t}",
"public Unit getUnitAt(Position p);",
"public Point getLocation() {\r\n return new Point((int)x,(int)y);\r\n }",
"Optional<Point> getCoordinate(int id);",
"public int getFloor();",
"public WeightedPoint getGoal()\n {\n return map.getGoal();\n }",
"@Test\n\tpublic void testTower()\n\t{\n\t\tassertEquals(1,tower.getNum());\n\t\tassertEquals(22,tower.getPosition().getIntAbscisse());\n\t\tassertEquals(23,tower.getPosition().getIntOrdonne());\n\t}",
"public GPoint getSecondPoint(){\n return(point2);\n }",
"public Elevator getElevator(int index)\n\t{\n\t\tElevator lift = null;\n\t\tif (index >= 0 && index < this.getElevatorCount())\n\t\t\tlift = this.elevators[index];\n\t\treturn lift;\n\t}",
"Marker getMarker();",
"public WeatherType getPlayerWeather ( ) {\n\t\treturn extract ( handle -> handle.getPlayerWeather ( ) );\n\t}",
"public OwnedWarp getWarp(String player, String warpName) {\n List<OwnedWarp> list = warps.get(player);\n if(list == null)\n return null;\n for(OwnedWarp w : list)\n if(w.getName().equalsIgnoreCase(warpName))\n return w;\n return null;\n }"
] | [
"0.6337639",
"0.63128364",
"0.6210278",
"0.6185176",
"0.6047285",
"0.6015351",
"0.58810604",
"0.58654",
"0.584455",
"0.5791045",
"0.57901084",
"0.5755901",
"0.57172525",
"0.5675015",
"0.5661805",
"0.5647887",
"0.5646556",
"0.5636261",
"0.5602437",
"0.5583165",
"0.5559277",
"0.55544555",
"0.55542934",
"0.5508417",
"0.5506757",
"0.5500382",
"0.5488152",
"0.5483989",
"0.5472922",
"0.546563",
"0.5460265",
"0.54343",
"0.54281676",
"0.5411353",
"0.5405718",
"0.5381343",
"0.537841",
"0.53781104",
"0.5371922",
"0.53627944",
"0.53497636",
"0.53467697",
"0.5340107",
"0.53292257",
"0.5308066",
"0.53062135",
"0.5279683",
"0.5274336",
"0.5270771",
"0.526386",
"0.5252723",
"0.52513456",
"0.5248002",
"0.5225483",
"0.5213268",
"0.5211991",
"0.5209284",
"0.5202053",
"0.5200179",
"0.5194687",
"0.518726",
"0.5184905",
"0.51825076",
"0.5159903",
"0.5158483",
"0.5145846",
"0.5136071",
"0.5131326",
"0.51311034",
"0.5127072",
"0.51223403",
"0.51041645",
"0.509323",
"0.50917816",
"0.50844604",
"0.5081071",
"0.50810474",
"0.50791705",
"0.5076934",
"0.5076348",
"0.5074951",
"0.50638115",
"0.50516737",
"0.5047826",
"0.5042879",
"0.5037663",
"0.50353014",
"0.5029133",
"0.50230145",
"0.501602",
"0.501235",
"0.5009463",
"0.49962813",
"0.49961644",
"0.49802667",
"0.49792647",
"0.4972808",
"0.4969164",
"0.49686715",
"0.496596"
] | 0.7095137 | 0 |
Draw towers and selected tower range. | public static void draw(Graphics g) {
for(Tower t:towers) {
t.draw(g);
}
if(selectedTower != null){
Graphics2D g2 = (Graphics2D) g;
g2.setColor(Color.orange);
g2.setStroke(new BasicStroke(ICManager.squareHighlightTickness));
g2.drawRect(selectedTower.getX(), selectedTower.getY(), ICManager.cellSize, ICManager.cellSize);
//Draw tower range circle
if(selectedTower != null){
g2.setColor(Color.white);
g.drawOval(selectedTower.getX() + ICManager.cellSize / 2 - selectedTower.getRange(),selectedTower.getY() + ICManager.cellSize / 2 - selectedTower.getRange(), selectedTower.getRange()*2,selectedTower.getRange()*2);
}
}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"private void drawWaypoints() {\r\n\t\tint x1 = (width - SIZE_X) / 2;\r\n\t\tint y1 = (height - SIZE_Y) / 2;\r\n\r\n\t\tfloat scissorFactor = (float) _resolutionResolver.getScaleFactor() / 2.0f;\r\n\r\n\t\tint glLeft = (int) ((x1 + 10) * 2.0f * scissorFactor);\r\n\t\tint glWidth = (int) ((SIZE_X - (10 + 25)) * 2.0f * scissorFactor);\r\n\t\tint gluBottom = (int) ((this.height - y1 - SIZE_Y) * 2.0f * scissorFactor);\r\n\t\tint glHeight = (int) ((SIZE_Y) * 2.0f * scissorFactor);\r\n\r\n\t\tGL11.glEnable(GL11.GL_SCISSOR_TEST);\r\n\t\tGL11.glScissor(glLeft, gluBottom, glWidth, glHeight);\r\n\r\n\t\tGL11.glPushMatrix();\r\n\t\tGL11.glScalef(_textScale, _textScale, _textScale);\r\n\r\n\t\t_startCell = getStartCell();\r\n\t\t_cellStartX = (int) (((float) x1 + (float) 13) / _textScale);\r\n\t\t_cellStartY = (int) (((float) y1 + (float) 22) / _textScale);\r\n\r\n\t\tint x2 = _cellStartX;\r\n\t\tint y2 = _cellStartY + (int) ((float) 0 * (float) CELL_SIZE_Y / _textScale);\r\n\r\n\t\tImmutableList<UltraTeleportWaypoint> list = UltraTeleportWaypoint.getWaypoints();\r\n\t\tfor (int i = 0; i < 2; ++i) {\r\n \t\tfor (int j = 0; j < list.size() && j < MAX_CELL_COUNT; ++j) {\r\n\r\n \t\t\tint x = _cellStartX;\r\n \t\t\tint y = _cellStartY + (int) ((float) j * (float) CELL_SIZE_Y / _textScale);\r\n\r\n \t\t\tdouble posX = list.get(j + _startCell).getPos().getX();\r\n \t\t\tdouble posY = list.get(j + _startCell).getPos().getY();\r\n \t\t\tdouble posZ = list.get(j + _startCell).getPos().getZ();\r\n\r\n \t\t\tString strX = String.format(\"x: %4.1f\", posX);\r\n \t\t\tString strY = String.format(\"y: %4.1f\", posY);\r\n \t\t\tString strZ = String.format(\"z: %4.1f\", posZ);\r\n \t\t\tString text = strX + \" \" + strY + \" \" + strZ;\r\n\r\n \t\t\tif (i == 0) {\r\n \t\t\t this.fontRendererObj.drawStringWithShadow(text, x + 18, y, list.get(j).getColor());\r\n\r\n \t\t\t boolean selected = j + _startCell < _selectedList.size() ? _selectedList.get(j + _startCell) : false;\r\n\r\n \t\t\t GL11.glPushMatrix();\r\n GL11.glColor4f(1.0f, 1.0f, 1.0f, 1.0f);\r\n \t\t\t this.mc.renderEngine.bindTexture(selected ? BUTTON_ON_RESOURCE : BUTTON_OFF_RESOURCE);\r\n \t\t\t HubbyUtils.drawTexturedRectHelper(0, x + CELL_SIZE_X + 18, y - 3, 16, 16, 0, 0, 256, 256);\r\n \t\t\t GL11.glPopMatrix();\r\n \t\t\t}\r\n \t\t\telse if (i == 1) {\r\n \t\t\t\tBlockPos pos = new BlockPos((int)posX, (int)posY - 1, (int)posZ);\r\n \t\t\t Block block = Minecraft.getMinecraft().theWorld.getBlockState(pos).getBlock();\r\n \t\t\tif (block != null) {\r\n \t\t\t Item itemToRender = Item.getItemFromBlock(block);\r\n \t\t\t itemToRender = itemToRender != null ? itemToRender : Item.getItemFromBlock((Block)Block.blockRegistry.getObjectById(3));\r\n \t\t\t ItemStack is = new ItemStack(itemToRender, 1, 0);\r\n \t\t\t _itemRender.renderItemAndEffectIntoGUI(is, x - 1, y - 3);\r\n \t _itemRender.renderItemOverlayIntoGUI(this.fontRendererObj, is, x - 1, y - 3, \"\"); // TODO: is the last param correct?\r\n \t\t\t}\r\n \t\t\t}\r\n \t\t}\r\n\t\t}\r\n\r\n\t\tGL11.glPopMatrix();\r\n\t\tGL11.glDisable(GL11.GL_SCISSOR_TEST);\r\n\t}",
"public static void setBoard() {\n\t\tStdDraw.setPenColor(StdDraw.BOOK_LIGHT_BLUE);\n\t\tStdDraw.filledRectangle(500, 500, 1000, 1000);\n\t\tStdDraw.setPenColor(StdDraw.BLACK);\n\t\tStdDraw.filledCircle(200, 800, 35);\n\t\tStdDraw.filledCircle(500, 800, 35);\n\t\tStdDraw.filledCircle(800, 800, 35);\n\t\tStdDraw.filledCircle(200, 200, 35);\n\t\tStdDraw.filledCircle(500, 200, 35);\n\t\tStdDraw.filledCircle(800, 200, 35);\n\t\tStdDraw.filledCircle(200, 500, 35);\n\t\tStdDraw.filledCircle(800, 500, 35);\n\t\tStdDraw.filledCircle(350, 650, 35);\n\t\tStdDraw.filledCircle(500, 650, 35);\n\t\tStdDraw.filledCircle(650, 650, 35);\n\t\tStdDraw.filledCircle(350, 350, 35);\n\t\tStdDraw.filledCircle(500, 350, 35);\n\t\tStdDraw.filledCircle(650, 350, 35);\n\t\tStdDraw.filledCircle(350, 500, 35);\n\t\tStdDraw.filledCircle(650, 500, 35);\n\n\t\tStdDraw.setPenRadius(0.01);\n\t\tStdDraw.line(200, 200, 800, 200);\n\t\tStdDraw.line(200, 800, 800, 800);\n\t\tStdDraw.line(350, 350, 650, 350);\n\t\tStdDraw.line(350, 650, 650, 650);\n\t\tStdDraw.line(200, 500, 350, 500);\n\t\tStdDraw.line(650, 500, 800, 500);\n\t\tStdDraw.line(200, 800, 200, 200);\n\t\tStdDraw.line(800, 800, 800, 200);\n\t\tStdDraw.line(350, 650, 350, 350);\n\t\tStdDraw.line(650, 650, 650, 350);\n\t\tStdDraw.line(500, 800, 500, 650);\n\t\tStdDraw.line(500, 200, 500, 350);\n\n\t\tStdDraw.setPenColor(StdDraw.BLUE);\n\t\tStdDraw.filledCircle(80, 200, 35);\n\t\tStdDraw.filledCircle(80, 300, 35);\n\t\tStdDraw.filledCircle(80, 400, 35);\n\t\tStdDraw.filledCircle(80, 500, 35);\n\t\tStdDraw.filledCircle(80, 600, 35);\n\t\tStdDraw.filledCircle(80, 700, 35);\n\n\t\tStdDraw.setPenColor(StdDraw.RED);\n\t\tStdDraw.filledCircle(920, 200, 35);\n\t\tStdDraw.filledCircle(920, 300, 35);\n\t\tStdDraw.filledCircle(920, 400, 35);\n\t\tStdDraw.filledCircle(920, 500, 35);\n\t\tStdDraw.filledCircle(920, 600, 35);\n\t\tStdDraw.filledCircle(920, 700, 35);\n\n\t\tStdDraw.setPenColor(StdDraw.BLACK);\n\n\t}",
"@Override\n\tprotected void paintComponent(Graphics g) {\n\t\tsuper.paintComponent(g);\n\t\tGraphics2D g2 = (Graphics2D) g; \n\t\tg2.setColor(Color.lightGray);\n\t\tg2.fill(model.bg);\n\t\tg2.setColor(Color.darkGray);\n\t\tg2.fillPolygon(model.terrain);\n\t\tg2.setColor(Color.gray);\n\t\tfor (int i = 0; i < 20; i++) {\n\t\t\tg2.draw(model.circles.get(i));\n\t\t}\n\t\tif (model.curCircleSel != -1) {\n\t\t\tg2.setColor(Color.white);\n\t\t\tg2.setStroke(new BasicStroke(3));\n\t\t\tg2.draw(model.circles.get(model.curCircleSel));\n\t\t}\n\t\tg2.setColor(Color.RED);\n\t\tg2.fill(model.pad);\n\t\tif (curPadSel) {\n\t\t\tg2.setColor(Color.white);\n\t\t\tg2.setStroke(new BasicStroke(3));\n\t\t\tg2.draw(model.pad);\n\t\t}\n\t}",
"public void draw() {\t\n \t\t// Draw the centre of the maze\n \t\tPoint2D.Double centrePoint = GetCentrePoint();\n \t\t// if size is a factor of 10, this will be a multiple of 2\n \t\tint centreSize = getCentreSize();\n \t\tStdDraw.setPenColor(StdDraw.BOOK_LIGHT_BLUE);\n \t\tStdDraw.filledSquare(centrePoint.getX(), centrePoint.getY(), (centreSize / 2)-0.05);\n \t\t//Draw all the power switches\n \t\tdrawPowerSwitch(switches[0].x, switches[0].y);\n \t\tdrawPowerSwitch(switches[1].x, switches[1].y);\n \t\tdrawPowerSwitch(switches[2].x, switches[2].y);\n \t\tdrawPowerSwitch(switches[3].x, switches[3].y);\n \t\t\n \t\t\n \t\t// Get the data from the maze\n \t\tboolean south[][] = getSouth();\n \t\tboolean north[][] = getNorth();\n \t\tboolean east[][] = getEast();\n \t\tboolean west[][] = getWest();\n \t\tboolean sensor[][] = ms.getMotionSensors();\n \n \t\t//Draw the maze and motion sensors\n \t\tfor (int x = 1; x <= size; x++) {\n \t\t\tfor (int y = 1; y <= size; y++) {\n \t\t\t\tStdDraw.setPenColor(StdDraw.BLACK);\n \t\t\t\tif (south[x][y]) {\n \t\t\t\t\tStdDraw.line(x, y, x + 1, y);\n \t\t\t\t}\n \t\t\t\tif (north[x][y]) {\n \t\t\t\t\tStdDraw.line(x, y + 1, x + 1, y + 1);\n \t\t\t\t}\n \t\t\t\tif (west[x][y]) {\n \t\t\t\t\tStdDraw.line(x, y, x, y + 1);\n \t\t\t\t}\n \t\t\t\tif (east[x][y]) {\n \t\t\t\t\tStdDraw.line(x + 1, y, x + 1, y + 1);\n \t\t\t\t}\n \t\t\t\tif (sensor[x][y]) {\n \t\t\t\t\tStdDraw.setPenColor(StdDraw.MAGENTA);\n \t\t\t\t\tStdDraw.filledTriangle(x + 0.5, y + 0.4, 0.5);\n \t\t\t\t}\n \t\t\t}\n \t\t}\n \t}",
"private void setActionListener() {\n\t\tblinker = new ActionListener() {\n\n\t\t\t@Override\n\t\t\tpublic void actionPerformed(ActionEvent arg0) {\n\t\t\t\t// Level 1\n\t\t\t\tg.draw(new Line2D.Double(635, 110, 294, 200));\n\t\t\t\tg.draw(new Line2D.Double(635, 110, 635, 200));\n\t\t\t\tg.draw(new Line2D.Double(635, 110, 986, 200));\n\t\t\t\t// Level 21\n\t\t\t\tg.draw(new Line2D.Double(284, 260, 177, 345));\n\t\t\t\tg.draw(new Line2D.Double(284, 260, 284, 345));\n\t\t\t\tg.draw(new Line2D.Double(284, 260, 381, 355));\n\t\t\t\t// Level 22\n\t\t\t\tg.draw(new Line2D.Double(635, 260, 522, 345));\n\t\t\t\tg.draw(new Line2D.Double(635, 260, 635, 345));\n\t\t\t\tg.draw(new Line2D.Double(635, 260, 752, 345));\n\t\t\t\t// Level 23\n\t\t\t\tg.draw(new Line2D.Double(986, 260, 879, 345));\n\t\t\t\tg.draw(new Line2D.Double(986, 260, 987, 345));\n\t\t\t\tg.draw(new Line2D.Double(986, 260, 1087, 345));\n\t\t\t\t// Level 31\n\t\t\t\tg.draw(new Line2D.Double(167, 410, 118, 510));\n\t\t\t\tg.draw(new Line2D.Double(167, 410, 158, 510));\n\t\t\t\tg.draw(new Line2D.Double(167, 410, 198, 510));\n\t\t\t\t// Level 32\n\t\t\t\tg.draw(new Line2D.Double(284, 410, 238, 510));\n\t\t\t\tg.draw(new Line2D.Double(284, 410, 275, 510));\n\t\t\t\tg.draw(new Line2D.Double(284, 410, 310, 510));\n\t\t\t\t// Level 33\n\t\t\t\tg.draw(new Line2D.Double(401, 410, 350, 510));\n\t\t\t\tg.draw(new Line2D.Double(401, 410, 390, 510));\n\t\t\t\tg.draw(new Line2D.Double(401, 410, 430, 510));\n\t\t\t\t// Level 34\n\t\t\t\tg.draw(new Line2D.Double(518, 410, 470, 510));\n\t\t\t\tg.draw(new Line2D.Double(518, 410, 510, 510));\n\t\t\t\tg.draw(new Line2D.Double(518, 410, 550, 510));\n\t\t\t\t// Level 35\n\t\t\t\tg.draw(new Line2D.Double(635, 410, 590, 510));\n\t\t\t\tg.draw(new Line2D.Double(635, 410, 628, 510));\n\t\t\t\tg.draw(new Line2D.Double(635, 410, 668, 510));\n\t\t\t\t// Level 36\n\t\t\t\tg.draw(new Line2D.Double(752, 410, 705, 510));\n\t\t\t\tg.draw(new Line2D.Double(752, 410, 745, 510));\n\t\t\t\tg.draw(new Line2D.Double(752, 410, 785, 510));\n\t\t\t\t// Level 37\n\t\t\t\tg.draw(new Line2D.Double(869, 410, 820, 510));\n\t\t\t\tg.draw(new Line2D.Double(869, 410, 860, 510));\n\t\t\t\tg.draw(new Line2D.Double(869, 410, 900, 510));\n\t\t\t\t// Level 38\n\t\t\t\tg.draw(new Line2D.Double(986, 410, 938, 510));\n\t\t\t\tg.draw(new Line2D.Double(986, 410, 978, 510));\n\t\t\t\tg.draw(new Line2D.Double(986, 410, 1018, 510));\n\t\t\t\t// Level 39\n\t\t\t\tg.draw(new Line2D.Double(1103, 410, 1058, 510));\n\t\t\t\tg.draw(new Line2D.Double(1103, 410, 1098, 510));\n\t\t\t\tg.draw(new Line2D.Double(1103, 410, 1138, 510));\n\t\t\t}\n\t\t};\n\t}",
"@Override\n\tpublic void draw(Graphics g) {\n\t\tg.setColor(Color.BLACK);\n for(int j = 0 ; j < 3 ; j++) {\n \tg.drawRect(0,50*j, 120, 50);\n }\n \n if(super.selected) {\n\t\t\tg.fillRect(super.north_port.x, super.north_port.y, super.connection_port_width ,super.connection_port_width);\n\t g.fillRect(super.east_port.x-super.connection_port_width, super.east_port.y, super.connection_port_width,super.connection_port_width);\n\t g.fillRect(super.south_port.x, super.south_port.y-super.connection_port_width ,super.connection_port_width,super.connection_port_width);\n\t g.fillRect(super.west_port.x, super.west_port.y, super.connection_port_width,super.connection_port_width);\n\t\t}\n \t\n \n }",
"void draw() {\n\t\tSystem.out.println(\"Drawing the Rectange...\");\n\t\t}",
"public static void main(String[] args) {\n\tTurtle t[]=new Turtle [5];\n\tint temp[]=new int [5];\n\tScanner in=new Scanner(System.in);\n\tint num;\n\tSystem.out.println(\"Choose the type of a turtle:\\n1. Simple\\n2. Smart\\n3. Drunk\\n4. Jumpy\");\n\tfor (int i = 0; i < t.length; i++) {\n\t\tSystem.out.println(\"Enter the \" + (i+1) + \"st Turtle\");\n\t\tnum=in.nextInt();\n\t\tif(num<0||num>4){\n\t\t\twhile(num<0||num>4){\n\t\t\t\tSystem.out.println(\"Erorr number! plase enter new number:\");\n\t\t\t\tnum=in.nextInt();\n\t\t\t}\n\t\t}\n\t\t\t\n\t\ttemp[i]=num;\n\t\tif(num==1)\n\t\t\tt[i]=new SimpleTurtle();\n\t\tif(num==2)\n\t\t\tt[i]= new SmartTurtle();\n\t\tif(num==3)\n\t\t\tt[i]=new DrunkTurtle();\n\t\tif(num==4)\n\t\t\tt[i]= new JumpyTurtle();\n\t}\n\t\n\tfor (int i =0; i < t.length; i++) {\n\t\tt[i].tailDown();\n\t}\n\tfor (int i = 0; i < t.length; i++) {\n\t\tt[i].moveForward(100);\n\t}\n\t\n\tfor (int i = 0; i < t.length; i++) {\n\t\tt[i].turnRight(90);\n\t}\n\t\n\tfor (int i = 0; i < t.length; i++) {\n\t\tt[i].moveForward(100);\n\t}\n\tfor (int i = 0; i < t.length; i++) {\n\t\tif(temp[i]==2 || temp[i]==4)\n\t\t\t((SmartTurtle) t[i]).drawPolygon(6,70);\n\t}\n\tfor (int i = 0; i < t.length; i++) {\n\t\tt[i].hide();\n\t}\n\t\t\n\t}",
"static void drawTopo() {\n\t\tif (currentStage[currentSlice-1]>2)\n\t\t{\n\t\t\tfloat x1,y1,x2,y2;\n\t\t\tint N = pop.N;\n\t\t\tArrayList balloons = pop.BallList;\n\n\t\t\tfor (int i=0;i<N;i++)\n\t\t\t{\n\t\t\t\tPoint P1 = ((Balloon)(balloons.get(i))).getPoint();\n\t\t\t\tx1 = (float)(P1.getX());\n\t\t\t\ty1 = (float)(P1.getY());\n\n\t\t\t\tfor (int j=0;j<i;j++)\n\t\t\t\t{\n\t\t\t\t\tif (pop.topo[i][j]==true)\n\t\t\t\t\t{\n\t\t\t\t\t\t// label connection between cells (potential neighbours)\n\t\t\t\t\t\tjava.awt.geom.GeneralPath Tshape = new GeneralPath();\n\t\t\t\t\t\tPoint P2 = ((Balloon)(balloons.get(j))).getPoint();\n\t\t\t\t\t\tx2 = (float)(P2.getX());\n\t\t\t\t\t\ty2 = (float)(P2.getY());\n\t\t\t\t\t\tTshape.moveTo(x1, y1);\n\t\t\t\t\t\tTshape.lineTo(x2, y2);\n\t\t\t\t\t\tRoi XROI = new ShapeRoi(Tshape);\n\t\t\t\t\t\tXROI.setStrokeWidth(1);\n\t\t\t\t\t\tXROI.setStrokeColor(Color.green);\n\t\t\t\t\t\tOL.add(XROI);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}",
"public void draw(){\n\t\tif(!visible) return;\n\n\t\twinApp.pushStyle();\n\t\twinApp.style(G4P.g4pStyle);\n\t\tPoint pos = new Point(0,0);\n\t\tcalcAbsPosition(pos);\n\n\t\t// Draw selected option area\n\t\tif(border == 0)\n\t\t\twinApp.noStroke();\n\t\telse {\n\t\t\twinApp.strokeWeight(border);\n\t\t\twinApp.stroke(localColor.txfBorder);\n\t\t}\n\t\tif(opaque)\n\t\t\twinApp.fill(localColor.txfBack);\n\t\telse\n\t\t\twinApp.noFill();\n\t\twinApp.rect(pos.x, pos.y, width, height);\n\t\t\n\t\t// Draw selected text\n\t\twinApp.noStroke();\n\t\twinApp.fill(localColor.txfFont);\n\t\twinApp.textFont(localFont, localFont.getSize());\n\t\twinApp.text(text, pos.x + PADH, pos.y -PADV +(height - localFont.getSize())/2, width - 16, height);\n\n\t\t// draw drop down list\n\t\twinApp.fill(winApp.color(255,255));\n\t\tif(imgArrow != null)\n\t\t\twinApp.image(imgArrow, pos.x + width - imgArrow.width - 1, pos.y + (height - imgArrow.height)/2);\n\t\tif(expanded == true){\n\t\t\tGOption opt;\n\t\t\twinApp.noStroke();\n\t\t\twinApp.fill(localColor.txfBack);\n\t\t\twinApp.rect(pos.x,pos.y+height,width,nbrRowsToShow*height);\n\n\t\t\tfor(int i = 0; i < optGroup.size(); i++){\n\t\t\t\topt = optGroup.get(i);\n\t\t\t\tif(i >= startRow && i < startRow + nbrRowsToShow){\n\t\t\t\t\topt.visible = true;\n\t\t\t\t\topt.y = height * (i - startRow + 1);\n\t\t\t\t\topt.draw();\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\topt.visible = false;\t\t\t\t\t\n\t\t\t\t}\n\t\t\t}\n\t\t\t// Draw box round list\n\t\t\tif(border != 0){\n\t\t\t\twinApp.strokeWeight(border);\n\t\t\t\twinApp.stroke(localColor.txfBorder);\n\t\t\t\twinApp.noFill();\n\t\t\t\twinApp.rect(pos.x,pos.y+height,width,nbrRowsToShow*height);\n\t\t\t}\n\t\t\tif(optGroup.size() > maxRows){\n\t\t\t\tslider.setVisible(true);\n\t\t\t\tslider.draw();\n\t\t\t}\n\t\t}\n\t\twinApp.popStyle();\n\t}",
"public void draw() \n{\n background(250, 243, 225);\n timer(); //control timing of the program\n mapwd.draw(); //visualize weekday trajectory\n shadeTra(t1); \n mapwk.draw(); //visualize weekend trajectory\n shadeTra(t2); \n transport(); //draw the transport legend\n infoDisplay(); //display almost text information\n \n\n stroke(0);\n \n gweekend();\n gweekday();\n frame();\n graduation();\n piechart();\n \n stroke(0);\n arrow();\n \n saveFrame(\"Output1/traffic_######.tif\");\n}",
"public void makeSwitcherBall(TPaintDropListItem paintSelectedItem);",
"public static void draw(ArrayList<Sighting> data){\n \n \t\tint backgroundColor = Utils.globalProcessing.color(120, 120, 120, 60);\n \n \t\tUtils.globalProcessing.fill(backgroundColor);\n \n \t\tUtils.globalProcessing.rect(200, 0, 1024, 768);\n \t\t//Utils.globalProcessing.rectMode(Utils.globalProcessing.CORNERS);\n \t\tArrayList<Shape> shapes = new ArrayList<Shape>();\n \t\tArrayList<Time> times = new ArrayList<Time>();\n \t\tArrayList<City> locations = new ArrayList<City>();\n \t\t//calculate min/max for each dimension\n \t\tfor(int i = 0; i < data.size(); i++){\n \t\t\tSighting s = data.get(i);\n \t\t\tif(!shapes.contains(s.getShape()))\n \t\t\t\tshapes.add(s.getShape());\n \t\t\tif(!times.contains(s.getTime()))\n \t\t\t\ttimes.add(s.getTime());\n \t\t\tif(!locations.contains(s.getPosition()))\n \t\t\t\tlocations.add((City)s.getPosition());\n \t\t}\n \t\tfloat xPloti, xPlote, yPloti, yPlote;\n \t\txPloti = 200;\n \t\txPlote = 1024;\n \t\tyPloti = 100;\n \t\tyPlote = 700;\n \n \t\tfloat maxDistance = 0;\n\t\tfloat minPopulationDensity = Utils.allCities.get(0).getPopulationDensity();\n\t\tfloat maxpopulationDensity = Utils.allCities.get(0).getPopulationDensity();\n \t\tfor(City c: locations){\n \t\t\tif(c.getDistanceAirport() > maxDistance)\n \t\t\t\tmaxDistance = c.getDistanceAirport();\n \t\t\tif(c.getPopulationDensity()< minPopulationDensity)\n \t\t\t\tminPopulationDensity = c.getPopulationDensity();\n \t\t\telse if(c.getPopulationDensity() > maxpopulationDensity)\n \t\t\t\tmaxpopulationDensity = c.getPopulationDensity();\n \n \t\t}\n \n \n \n \t\t\n \t\tfor(int i = 0; i < data.size(); i++){\n \t\t\tSighting s = data.get(i);\n \t\t\tUtils.globalProcessing.stroke(s.getShape().getColor());\n \t\t\tUtils.globalProcessing.beginShape();\n \t\t\t//Utils.globalProcessing.stroke(120);\n \t\t\tfloat x = Utils.globalProcessing.map((float)1/7, 0, 1, xPloti, xPlote);\n \t\t\tfloat y = Utils.globalProcessing.map(((City)s.getPosition()).getDistanceAirport(), 0, maxDistance, yPloti, yPlote);\n \n \t\t\tUtils.globalProcessing.vertex(x,y); // distance\n \n \t\t\tx = Utils.globalProcessing.map((float)2/7, 0, 1, xPloti, xPlote);\n \t\t\ty = Utils.globalProcessing.map(((City)s.getPosition()).getPopulationDensity(), minPopulationDensity, maxpopulationDensity, yPloti, yPlote);\n \n \t\t\tUtils.globalProcessing.vertex(x,y); //populationDensity\n \t\t\tUtils.globalProcessing.endShape();\n \t\t\t//It works only if I threat all the couple of points as separate, indipendent lines\n \t\t\tUtils.globalProcessing.beginShape();\n \n \t\t\tUtils.globalProcessing.vertex(x,y);\n \n \t\t\tx = Utils.globalProcessing.map((float)3/7, 0, 1, xPloti, xPlote);\n \t\t\tif(s.getTime().getBeginTime().get(Calendar.HOUR_OF_DAY)<19 &&s.getTime().getBeginTime().get(Calendar.HOUR_OF_DAY)>=7)\n \t\t\t\ty = Utils.globalProcessing.map(1, 0, 3, yPloti, yPlote); //day \n \t\t\telse\t\n \t\t\t\ty = Utils.globalProcessing.map(2, 0, 3, yPloti, yPlote); //night \n \t\t\t//System.out.println(x +\" \" +y);\n \t\t\tUtils.globalProcessing.vertex(x,y); // night/day\n \t\t\tUtils.globalProcessing.endShape();\n \t\t\tUtils.globalProcessing.beginShape();\n \t\t\t\n \t\t\tUtils.globalProcessing.vertex(x,y);\n \t\t\tx = Utils.globalProcessing.map((float)4/7, 0, 1, xPloti, xPlote);\n \t\t\ty = Utils.globalProcessing.map(s.getTime().getBeginTime().get(Calendar.MONTH)+1, 0, 13, yPloti, yPlote);\n \t\t\tUtils.globalProcessing.vertex(x, y); //month of the year\n \t\t\t\n \t\t\tUtils.globalProcessing.endShape();\n \t\t\tUtils.globalProcessing.beginShape();\n \t\t\t\n \t\t\tUtils.globalProcessing.vertex(x, y);\n \t\t\tx = Utils.globalProcessing.map((float)5/7, 0, 1, xPloti, xPlote);\n \t\t\tif(s.getTime().getBeginTime().get(Calendar.MONTH)==Calendar.MARCH || s.getTime().getBeginTime().get(Calendar.MONTH) == Calendar.APRIL ||\n \t\t\t\t\ts.getTime().getBeginTime().get(Calendar.MONTH) == Calendar.MAY) //Spring\n \t\t\ty = Utils.globalProcessing.map(1, 0, 5, yPloti, yPlote);\n \t\t\telse if(s.getTime().getBeginTime().get(Calendar.MONTH)==Calendar.JUNE || s.getTime().getBeginTime().get(Calendar.MONTH) == Calendar.JULY ||\n \t\t\t\t\ts.getTime().getBeginTime().get(Calendar.MONTH) == Calendar.AUGUST) //summer\n \t\t\t\ty = Utils.globalProcessing.map(2, 0, 5, yPloti, yPlote);\n \t\t\telse if(s.getTime().getBeginTime().get(Calendar.MONTH)==Calendar.SEPTEMBER || s.getTime().getBeginTime().get(Calendar.MONTH) == Calendar.OCTOBER ||\n \t\t\t\t\ts.getTime().getBeginTime().get(Calendar.MONTH) == Calendar.NOVEMBER) //autumn\n \t\t\t\ty = Utils.globalProcessing.map(3, 0, 5, yPloti, yPlote);\n \t\t\telse\n \t\t\t\ty = Utils.globalProcessing.map(3, 0, 5, yPloti, yPlote);\n \t\t\tUtils.globalProcessing.vertex(x, y); //seasons\n \t\t\t\n \t\t\tUtils.globalProcessing.endShape();\n \t\t\tUtils.globalProcessing.beginShape();\n \t\t\t\n \t\t\tUtils.globalProcessing.vertex(x, y);\n \t\t\t\n \t\t\tx = Utils.globalProcessing.map((float)6/7, 0, 1, xPloti, xPlote);\n \t\t\ty = Utils.globalProcessing.map(s.getTime().getBeginTime().get(Calendar.YEAR), 2000, 2011, yPloti, yPlote);\n \t\t\tUtils.globalProcessing.vertex(x, y); //years\n \t\t\tUtils.globalProcessing.endShape();\n \t\t}\n \t\t//draw vertical lines\n \n \t\tfor(int i = 1; i < 7 ; i++){\n \t\t\tfloat x = Utils.globalProcessing.map((float)i/7, 0, 1, xPloti, xPlote);\n \t\t\t//Utils.globalProcessing.\n \t\t}\n \n \t}",
"public void tetraederzeichnen(double ax,double ay,double bx,double by,double cx,double cy,double dx,double dy){\n double[][] arr_koordinaten_2d ={{ax,ay},{bx,by},{cx,cy},{dx,dy}};\n /**\n * Aufruf der Methode gestricheltodernicht\n *\n * Überprüft, welche Strecken von Punkt D sichtbar sind oder nicht.\n */\n\n boolean[] strichelnodernicht = cls_berechnen.gestricheltodernicht(arr_koordinaten_2d);\n\n /**Skaliert die Koordinaten zum Pixelformat mit Koordinatenursprung\n * ca in der Mitte der Zeichenfläche*/\n int sw=9; //skalierungswert\n ax= (sw+ax)*50;\n ay=(sw-ay)*50;\n bx= (sw+bx)*50;\n by=(sw-by)*50;\n cx= (sw+cx)*50;\n cy=(sw-cy)*50;\n dx= (sw+dx)*50;\n dy=(sw-dy)*50;\n\n /**\n * Erstellt Linienobjekte für die Kanten des Tetraeder Objekts...\n */\n Line line1 = new Line();\n Line line2 = new Line();\n Line line3 = new Line();\n Line line4 = new Line();\n Line line5 = new Line();\n Line line6 = new Line();\n\n /**\n * ... weißt ihnen die Koordinaten zu...\n */\n line1.setStartX(ax);\n line1.setStartY(ay);\n line1.setEndX(bx);\n line1.setEndY(by);\n\n line2.setStartX(ax);\n line2.setStartY(ay);\n line2.setEndX(cx);\n line2.setEndY(cy);\n\n line3.setStartX(bx);\n line3.setStartY(by);\n line3.setEndX(cx);\n line3.setEndY(cy);\n \n line4.setStartX(dx);\n line4.setStartY(dy);\n line4.setEndX(ax);\n line4.setEndY(ay);\n\n line5.setStartX(dx);\n line5.setStartY(dy);\n line5.setEndX(bx);\n line5.setEndY(by);\n\n line6.setStartX(dx);\n line6.setStartY(dy);\n line6.setEndX(cx);\n line6.setEndY(cy);\n \n if(!strichelnodernicht[0]){\n line4.getStrokeDashArray().addAll(5d,5d);}\n\n if(!strichelnodernicht[1]){\n line5.getStrokeDashArray().addAll(5d,5d);}\n\n if(!strichelnodernicht[2]){\n line6.getStrokeDashArray().addAll(5d,5d);}\n\n /**\n * ... und fügt die Linien Objekte der Zeichenfläche hinzu\n */\n canvaspane.getChildren().add(line1);\n canvaspane.getChildren().add(line2);\n canvaspane.getChildren().add(line3);\n canvaspane.getChildren().add(line4);\n canvaspane.getChildren().add(line5);\n canvaspane.getChildren().add(line6);\n\n //zeichnet den Koordinatenursprung neu\n canvaspane.getChildren().add(l1);\n canvaspane.getChildren().add(l2);\n }",
"@Override\n public void paint(Graphics g)\n {\n super.paint(g);\n\n if(g instanceof Graphics2D)\n {\n // Initialize vars\n Graphics2D graphics = (Graphics2D) g;\n Dimension panelDimension = this.getSize();\n Rectangle2D turtleBounds;\n int fontHeight = g.getFontMetrics().getHeight();\n\n // Clear drawing sheet\n graphics.setColor(Color.WHITE);\n graphics.fillRect(0, 0, (int) panelDimension.getWidth(), (int) panelDimension.getHeight());\n\n // Draw every turtle\n for(AbstractTurtle turtle : this.turtles)\n {\n // Draw the turtle's shape\n graphics.setColor(turtle.getColor());\n graphics.fill(turtle.getShape());\n\n // Debug mode\n if(this.isDebug)\n {\n // Draw the turtle's sight\n graphics.setColor(Color.BLACK);\n graphics.draw(turtle.getSight());\n\n // Draw the turtle's center\n graphics.setColor(Color.CYAN);\n graphics.drawLine(\n (int) turtle.getX() - 10,\n (int) turtle.getY(),\n (int) turtle.getX() + 10,\n (int) turtle.getY()\n );\n graphics.drawLine(\n (int) turtle.getX(),\n (int) turtle.getY() - 10,\n (int) turtle.getX(),\n (int) turtle.getY() + 10\n );\n\n // Write the turtle's speed\n turtleBounds = turtle.getShape().getBounds2D();\n\n graphics.setColor(Color.BLACK);\n graphics.drawString(\n \"Vitesse : \" + String.format(\"%.2f\", turtle.getSpeed()),\n (int) turtleBounds.getMaxX() + 5,\n (int) turtleBounds.getMinY() - 5\n );\n graphics.drawString(\n \"Direction : \" + String.format(\"%.2f\", turtle.getDirection()),\n (int) turtleBounds.getMaxX() + 5,\n (int) turtleBounds.getMinY() - 5 + fontHeight\n );\n }\n }\n }\n }",
"@Override\n public void start(Stage teater){\n GridPane brettGP = new GridPane();\n boolean hvittFelt = false;\n for(int y = 0; y < 10; y ++){\n for(int x = 0; x < 10; x++){\n if(x == 0 || x == 9){\n if(y == 0 || y == 9){\n Rectangle r = new Rectangle(Settinger.RUTE_BREDDE / 2,\n Settinger.RUTE_BREDDE / 2);\n r.setFill(Color.DARKGREY);\n brettGP.add(r, x, y);\n }\n else{\n Rectangle r = new Rectangle(Settinger.RUTE_BREDDE / 2,\n Settinger.RUTE_BREDDE);\n r.setFill(Color.DARKGREY);\n StackPane stack = new StackPane();\n stack.getChildren().add(r);\n Text tekst = new Text(Integer.toString(9 - y));\n tekst.setFont(new Font(12));\n tekst.setTextAlignment(TextAlignment.CENTER);\n stack.getChildren().add(tekst);\n brettGP.add(stack, x, y);\n }\n }\n else{\n if(y == 0 || y == 9){\n Rectangle r = new Rectangle(Settinger.RUTE_BREDDE,\n Settinger.RUTE_BREDDE / 2);\n r.setFill(Color.DARKGREY);\n StackPane stack = new StackPane();\n stack.getChildren().add(r);\n Text tekst = new Text(Character.toString((char)(x + 64)));\n tekst.setFont(new Font(12));\n tekst.setTextAlignment(TextAlignment.CENTER);\n stack.getChildren().add(tekst);\n brettGP.add(stack, x, y);\n }\n else{\n Rectangle varselFargeR = new Rectangle(Settinger.RUTE_BREDDE,\n Settinger.RUTE_BREDDE);\n varselFargeR.setFill(Color.RED);\n Rectangle r = new Rectangle(Settinger.RUTE_BREDDE,\n Settinger.RUTE_BREDDE);\n if(hvittFelt){ r.setFill(Color.WHITE); }\n else{ r.setFill(Color.GREY); }\n StackPane stack = new StackPane();\n feltene[x - 1][8 - y] = stack;\n stack.getChildren().add(varselFargeR);\n stack.getChildren().add(r);\n brettGP.add(stack, x, y);\n hvittFelt = !hvittFelt;\n }\n\n }\n }\n hvittFelt = !hvittFelt;\n }\n\n statusFelt = new Text(\"Tekstfeltet\");\n statusFelt.setWrappingWidth(Settinger.BRETT_BREDDE + Settinger.RUTE_BREDDE);\n //statusFelt.setY(Settinger.BRETT_BREDDE + 100);\n statusFelt.setFont(new Font(16));\n statusFelt.setTextAlignment(TextAlignment.CENTER);\n\n hoyreTekstFelt = new Text(\"Høyre\");\n hoyreTekstFelt.setWrappingWidth(Settinger.RUTE_BREDDE * 12);\n hoyreTekstFelt.setFont(new Font(10));\n\n\n\n\n Pane hovedKulisse = new Pane();\n GridPane layoutGP = new GridPane();\n layoutGP.add(brettGP, 0, 0);\n layoutGP.add(hoyreTekstFelt, 1, 0);\n layoutGP.add(statusFelt, 0, 1);\n\n hovedKulisse.getChildren().add(layoutGP);\n\n\n Scene scene = new Scene(hovedKulisse);\n teater.setScene(scene);\n teater.setTitle(\"Java-sjakk\");\n teater.show();\n\n // STARTER OPP SJAKK LOGIKK:\n administrator = new Administrator(this);\n partiet = administrator.hentParti();\n stilling = administrator.hentStilling();\n hoyreTekstFelt.setText(stilling.toString());\n //hoyreTekstFelt.setText(stilling.hentEvalStreng());\n // OPPSETT FERDIG, STARTER AUTOSJAKK:\n if(partiet.hentAutomatisk(0)){ autoTrekk(); }\n\n }",
"public void draw() {\n StdDraw.setPenColor(StdDraw.BLACK);\n StdDraw.setPenRadius(0.01);\n for (Point2D point : points) {\n StdDraw.point(point.x(), point.y());\n }\n StdDraw.setPenRadius();\n }",
"public void draw() {\n for (Point2D i : pointsSet)\n i.draw();\n }",
"public void draw()\n {\n myPencil.up();\n myPencil.backward(100);\n myPencil.down();\n myPencil.turnRight(90);\n myPencil.forward(200);\n myPencil.turnLeft(90);\n myPencil.forward(200);\n myPencil.turnLeft(90);\n myPencil.forward(400);\n myPencil.turnLeft(90);\n myPencil.forward(200);\n myPencil.turnLeft(90);\n myPencil.forward(200);\n // Roof\n myPencil.up();\n myPencil.move(0,200);\n myPencil.down();\n myPencil.setDirection(333.435);\n myPencil.forward(223.607);\n myPencil.setColor(new Color(2, 0, 0));\n myPencil.up();\n myPencil.move(0,200);\n myPencil.setDirection(206.565);\n myPencil.down();\n myPencil.forward(223.607);\n // Windows\n myPencil.up();\n myPencil.move(-150,0);\n myPencil.setDirection(0);\n myPencil.down();\n myPencil.forward(75);\n myPencil.turnLeft(90);\n myPencil.forward(75);\n myPencil.turnLeft(90);\n myPencil.forward(75);\n myPencil.turnLeft(90);\n myPencil.forward(75);\n myPencil.up();\n myPencil.move(75,0);\n myPencil.setDirection(0);\n myPencil.down();\n myPencil.forward(75);\n myPencil.turnLeft(90);\n myPencil.forward(75);\n myPencil.turnLeft(90);\n myPencil.forward(75);\n myPencil.turnLeft(90);\n myPencil.forward(75);\n myPencil.up();\n myPencil.move(-50,-100);\n myPencil.setDirection(0);\n myPencil.down();\n myPencil.forward(75);\n myPencil.turnLeft(90);\n myPencil.forward(100);\n myPencil.turnLeft(90);\n myPencil.forward(50);\n myPencil.turnLeft(90);\n myPencil.forward(100);\n myPencil.up();\n myPencil.move(-50,-100);\n myPencil.setDirection(60);\n myPencil.down();\n myPencil.backward(150);\n myPencil.up();\n myPencil.move(50,-100);\n myPencil.setDirection(120);\n myPencil.down();\n myPencil.backward(150);\n myPencil.up();\n myPencil.move(150,-150);\n myPencil.down();\n myPencil.drawCircle(25);\n myPencil.up();\n myPencil.move(-150,-150);\n myPencil.down();\n myPencil.drawCircle(25);\n myPencil.up();\n myPencil.move(-150,-175);\n myPencil.setDirection(90);\n myPencil.down();\n myPencil.backward(20);\n myPencil.up();\n myPencil.move(150,-175);\n myPencil.setDirection(90);\n myPencil.down();\n myPencil.backward(20);\n myPencil.up();\n myPencil.move(-150,37.5);\n myPencil.setDirection(0);\n myPencil.down();\n myPencil.forward(75);\n myPencil.up();\n myPencil.move(75,37.5);\n myPencil.setDirection(0);\n myPencil.down();\n myPencil.forward(75);\n myPencil.up();\n myPencil.move(-112.5,0);\n myPencil.setDirection(90);\n myPencil.down();\n myPencil.forward(75);\n myPencil.up();\n myPencil.move(112.5,0);\n myPencil.setDirection(90);\n myPencil.down();\n myPencil.forward(75);\n // House Sidewalk\n myPencil.up();\n myPencil.move(-250,-112.5);\n myPencil.setDirection(0);\n myPencil.down();\n myPencil.forward(192.5);\n myPencil.up();\n myPencil.move(250,-112.5);\n myPencil.setDirection(180);\n myPencil.down();\n myPencil.forward(192.5);\n myPencil.up();\n myPencil.move(-250,-100);\n myPencil.setDirection(0);\n myPencil.down();\n myPencil.forward(90);\n myPencil.forward(193);\n myPencil.up();\n myPencil.move(250,-100);\n myPencil.setDirection(180);\n myPencil.down();\n myPencil.forward(90);\n myPencil.up();\n myPencil.move(-75,-100);\n myPencil.setDirection(240);\n myPencil.down();\n myPencil.forward(15);\n myPencil.up();\n myPencil.move(-100,-100);\n myPencil.setDirection(240);\n myPencil.down();\n myPencil.forward(15);\n myPencil.up();\n myPencil.move(-125,-100);\n myPencil.setDirection(240);\n myPencil.down();\n myPencil.forward(15);\n myPencil.up();\n myPencil.move(-150,-100);\n myPencil.setDirection(240);\n myPencil.down();\n myPencil.forward(15);\n myPencil.up();\n myPencil.move(-175,-100);\n myPencil.setDirection(240);\n myPencil.down();\n myPencil.forward(15);\n myPencil.up();\n myPencil.move(-200,-100);\n myPencil.setDirection(240);\n myPencil.down();\n myPencil.forward(15);\n myPencil.up();\n myPencil.move(-225,-100);\n myPencil.setDirection(240);\n myPencil.down();\n myPencil.forward(15);\n myPencil.up();\n myPencil.move(-250,-100);\n myPencil.setDirection(240);\n myPencil.down();\n myPencil.forward(15);\n myPencil.up();\n myPencil.move(75,-100);\n myPencil.setDirection(240);\n myPencil.down();\n myPencil.forward(15);\n myPencil.up();\n myPencil.move(100,-100);\n myPencil.setDirection(240);\n myPencil.down();\n myPencil.forward(15);\n myPencil.up();\n myPencil.move(125,-100);\n myPencil.setDirection(240);\n myPencil.down();\n myPencil.forward(15);\n myPencil.up();\n myPencil.move(150,-100);\n myPencil.setDirection(240);\n myPencil.down();\n myPencil.forward(15);\n myPencil.up();\n myPencil.move(175,-100);\n myPencil.setDirection(240);\n myPencil.down();\n myPencil.forward(15);\n myPencil.up();\n myPencil.move(200,-100);\n myPencil.setDirection(240);\n myPencil.down();\n myPencil.forward(15);\n myPencil.up();\n myPencil.move(225,-100);\n myPencil.setDirection(240);\n myPencil.down();\n myPencil.forward(15);\n myPencil.up();\n myPencil.move(250,-100);\n myPencil.setDirection(240);\n myPencil.down();\n myPencil.forward(15);\n // Chimney\n myPencil.up();\n myPencil.move(125,190);\n myPencil.setDirection(270);\n myPencil.down();\n myPencil.forward(52);\n myPencil.up();\n myPencil.move(100,190);\n myPencil.setDirection(270);\n myPencil.down();\n myPencil.forward(40);\n myPencil.up();\n myPencil.move(100,190);\n myPencil.setDirection(0);\n myPencil.down();\n myPencil.forward(25);\n // Door window\n myPencil.up();\n myPencil.move(0,-25);\n myPencil.setDirection(0);\n myPencil.down();\n myPencil.drawCircle(8);\n myPencil.up();\n myPencil.move(-8,-25);\n myPencil.setDirection(0);\n myPencil.down();\n myPencil.forward(16);\n myPencil.up();\n myPencil.move(0,-17);\n myPencil.setDirection(270);\n myPencil.down();\n myPencil.forward(16);\n // Door knob\n myPencil.up();\n myPencil.move(14,-55);\n myPencil.setDirection(0);\n myPencil.down();\n myPencil.drawCircle(2);\n }",
"private Obs findTrips(String[] towers, String[] tstamps, Hashtable<Integer, Vertex> towersXY, int dist_th,\n\t\t\tint time_th) {\n\t\t/**\n\t\t * Marks array contain index of the towers that represent the starting\n\t\t * observation of a new trip.\n\t\t */\n\t\tboolean[] marks = new boolean[tstamps.length];\n\t\tDateFormat formatter = new SimpleDateFormat(\"HH:mm:ss\");\n\t\tCalendar cal = Calendar.getInstance();\n\t\t/**\n\t\t * add 0 as the start of the first tower in this seq.\n\t\t */\n\t\t// int mIndex = 0;\n\t\t// marks[mIndex++] = 0;\n\n\t\tint current = 0;\n\t\tfor (int i = 1; i < tstamps.length; i++) {\n\t\t\ttry {\n\t\t\t\tString tstamp = tstamps[i];\n\n\t\t\t\t/**\n\t\t\t\t * if the time exceeds timing threshold, then check the distance\n\t\t\t\t * between towers. If this distance less than the distance\n\t\t\t\t * threshold, then previous tower is the end of the current\n\t\t\t\t * trip.\n\t\t\t\t *\n\t\t\t\t */\n\t\t\t\tDate sTime = formatter.parse(tstamps[current]);\n\t\t\t\tDate eTime = formatter.parse(tstamp);\n\t\t\t\tcal.setTime(sTime);\n\t\t\t\tint hour = cal.get(Calendar.HOUR);\n\t\t\t\tint minute = cal.get(Calendar.MINUTE);\n\n\t\t\t\tcal.setTime(eTime);\n\t\t\t\tint ehour = cal.get(Calendar.HOUR);\n\t\t\t\tint eminute = cal.get(Calendar.MINUTE);\n\n\t\t\t\tint diff = (ehour - hour) * HOUR + (eminute - minute);\n\t\t\t\t/**\n\t\t\t\t * check time difference with time threshold whatever the\n\t\t\t\t * distance between the starting tower\n\t\t\t\t */\n\t\t\t\tif (diff > time_th) {\n\t\t\t\t\t/**\n\t\t\t\t\t * Check distance, if it distance less than distance\n\t\t\t\t\t * threshold mark the current tower as the start of a new\n\t\t\t\t\t * trip.\n\t\t\t\t\t */\n\t\t\t\t\tVertex sTower = towersXY.get(Integer.parseInt(towers[i - 1]));\n\t\t\t\t\tVertex tower = towersXY.get(Integer.parseInt(towers[i]));\n\n\t\t\t\t\tif (eculidean(sTower.getX(), tower.getX(), sTower.getY(), tower.getY()) < dist_th) {\n\t\t\t\t\t\t/**\n\t\t\t\t\t\t * Update the trip sequences\n\t\t\t\t\t\t */\n\t\t\t\t\t\tmarks[i] = true;\n\t\t\t\t\t\tcurrent = i;\n\t\t\t\t\t}\n\n\t\t\t\t}\n\t\t\t} catch (ParseException ex) {\n\t\t\t\tLogger.getLogger(ObsTripsBuilder.class.getName()).log(Level.SEVERE, null, ex);\n\t\t\t}\n\t\t}\n\n\t\t/**\n\t\t * construct observations and time stamps\n\t\t */\n\t\tString time = \"\";\n\t\tString obs = \"\";\n\t\t// time += tstamps[0];\n\t\t// obs += towers[0];\n\t\tfor (int i = 0; i < marks.length; i++) {\n\t\t\tif (marks[i]) {\n\n\t\t\t\ttime += RLM + tstamps[i];\n\t\t\t\tobs += RLM + towers[i];\n\t\t\t} else {\n\t\t\t\t// if (towers[i].equals(towers[i - 1])) {\n\t\t\t\t// System.out.println(towers[i] + \"\\t=\\t\" + towers[i - 1]);\n\t\t\t\t// continue;\n\t\t\t\t// }\n\t\t\t\t/**\n\t\t\t\t * Add comma separators\n\t\t\t\t */\n\t\t\t\tif (!time.isEmpty()) {\n\t\t\t\t\ttime += CLM;\n\t\t\t\t\tobs += CLM;\n\t\t\t\t}\n\t\t\t\ttime += tstamps[i];\n\t\t\t\tobs += towers[i];\n\t\t\t}\n\n\t\t}\n\t\treturn new Obs(obs, time);\n\t}",
"public void draw() {\n StdDraw.setPenColor(StdDraw.BLACK);\n StdDraw.setPenRadius(.01);\n for (Point2D p : s) {\n p.draw();\n }\n }",
"private void setBoard() {\r\n Timer timer = new Timer();\r\n for (int i = 0; i < rectangles.size(); i++) {\r\n if (i < numTargets) {\r\n rectangles.get(i).setFill(Color.DARKBLUE);\r\n int finalI = i;\r\n rectangles.get(i).setOnMouseClicked(new EventHandler<>() {\r\n @Override\r\n public void handle(MouseEvent event) {\r\n rectangles.get(finalI).removeEventHandler(MouseEvent.MOUSE_CLICKED, this);\r\n rectangles.get(finalI).setFill(Color.DARKBLUE);\r\n for (int i = 0; i < numTargets; i++) {\r\n if (rectangles.get(i).getFill() == Color.DARKBLUE) numClicked++;\r\n }\r\n if (numClicked == numTargets) {\r\n level++;\r\n levelText.setValue(level);\r\n for (int j = 0; j < numTargets; j++) rectangles.get(j).setFill(Color.BLUE);\r\n numTargets++;\r\n numClicked = 0;\r\n if (upgradeCounter == upgradeBound) {\r\n upgradeCounter = 0;\r\n upgradeBound++;\r\n gridSize++;\r\n increaseGridSize();\r\n createRectangles();\r\n addRectanglesToGrid(grid, rectangles);\r\n rectangleSize -= 10;\r\n resizeRectangle();\r\n } else upgradeCounter++;\r\n\r\n Collections.shuffle(rectangles);\r\n TimerTask t = new TimerTask() {\r\n @Override\r\n public void run() {\r\n setBoard();\r\n }\r\n };\r\n timer.schedule(t, 1000L);\r\n }\r\n numClicked = 0;\r\n rectangles.get(finalI).removeEventHandler(MouseEvent.MOUSE_CLICKED, this);\r\n }\r\n });\r\n }\r\n else {\r\n rectangles.get(i).setFill(Color.BLUE);\r\n int finalI1 = i;\r\n rectangles.get(i).setOnMouseClicked(new EventHandler<MouseEvent>() {\r\n @Override\r\n public void handle(MouseEvent event) {\r\n rectangles.get(finalI1).removeEventHandler(MouseEvent.MOUSE_CLICKED, this);\r\n numClicked = 0;\r\n numLives--;\r\n livesText.setValue(numLives);\r\n Collections.shuffle(rectangles);\r\n setBoard();\r\n rectangles.get(finalI1).removeEventHandler(MouseEvent.MOUSE_CLICKED, this);\r\n }\r\n });\r\n }\r\n }\r\n\r\n TimerTask task = new TimerTask() {\r\n @Override\r\n public void run() {\r\n for (int i = 0; i < numTargets; i++)\r\n rectangles.get(i).setFill(Color.BLUE);\r\n }\r\n };\r\n timer.schedule(task, 2000L);\r\n }",
"@FXML\r\n private void crearTriangulo(ActionEvent event) {\n \r\n double x[] = {100, 150, 50};\r\n double y[] = {100, 210, 210, 50};\r\n \r\n g.setFill(Color.GOLD);\r\n g.fillPolygon(x, y, 3);\r\n }",
"@Override\n protected final void setGraphics() {\n super.setGraphics();\n Graphics g = toDraw.getGraphics();\n g.setColor(Color.BLACK); \n \n for (int i = 0; i < choices.size(); i++) { \n g.drawString(choices.get(i).getValue(), wGap, (i + 1) * hItemBox);\n }\n }",
"public void draw() {\n for (Point2D point : pointSet) {\n point.draw();\n }\n }",
"@Override\n\tpublic void render() {\n\t\tupdate();\n\n\t\tGdx.gl.glClear(GL10.GL_COLOR_BUFFER_BIT); // clear the screen\n\t\tbatch.begin();\n\n\t\tTextureRegion tmpRegion = null;\n\t\t\n\t\t// Draw the terrain!\n\t\tfor (int x = 0; x < 30; ++x) {\n\t\t\tfor (int y = 0; y < 20; ++y) {\n\t\t\t\ttmpRegion = new TextureRegion( tileset32Texture, (tiles[x][y] - 4) * 32, 0, 32, 32);\n\t\t\t\t//pause_button_region = new TextureRegion( spriteSheet, tiles[x][y] - 4, 0, 32, 32);\n\t\t\t\t// switch to 32x32 sprite\n\t\t\t\t//batch.draw(spriteSheet, x * 16, y * 16, tiles[x][y] * 16, 0, 16, 16);\n\t\t\t\tbatch.draw(tmpRegion, x * SQUARE_WIDTH, y * SQUARE_WIDTH, SQUARE_WIDTH, SQUARE_WIDTH);\n\n\t\t\t\t// Temporary, copy pasta\n\t\t\t\t/*\n\t\t\t\t * switch( movementDirs[x][y] ) { case 'N': batch.draw(\n\t\t\t\t * spriteSheet, x*16, y*16, 11*16, 0, 16, 16 ); break; case 'E':\n\t\t\t\t * batch.draw( spriteSheet, x*16, y*16, 12*16, 0, 16, 16 );\n\t\t\t\t * break; case 'W': batch.draw( spriteSheet, x*16, y*16, 13*16,\n\t\t\t\t * 0, 16, 16 ); break; case 'S': batch.draw( spriteSheet, x*16,\n\t\t\t\t * y*16, 14*16, 0, 16, 16 ); break; }\n\t\t\t\t */\n\t\t\t\t\n\t\t\t}\n\t\t}\n\n\t\t// Draw the towers\n\t\tfor( int i = 0; i < towers.size(); ++i )\n\t\t{\n\t\t\tbatch.draw(towers.get(i).m_type.getTextureRegion(), towers.get(i).m_x * SQUARE_WIDTH, (towers.get(i).m_y) * SQUARE_WIDTH, SQUARE_WIDTH, SQUARE_WIDTH);\n\t\t\t//drawSprite(towers.get( i ).getIconNum(), towers.get(i).m_x, towers.get(i).m_y);\n\t\t\tif (towers.get(i).selected) {\n\t\t\t\t//batch.draw(spriteSheet, towers.get(i).m_x * SQUARE_WIDTH, towers.get(i).m_y * SQUARE_WIDTH, SQUARE_WIDTH, SQUARE_WIDTH, towers.get(i).m_type.getSpriteLocX(), towers.get(i).m_type.getSpriteLocY(), 16, 16, false, true);\n\t\t\t\t//drawSprite(towers.get( i ).getIconNum(), towers.get(i).m_x, towers.get(i).m_y);\n\t\t\t\tbatch.draw(selectionImg, towers.get(i).m_x * SQUARE_WIDTH, towers.get(i).m_y * SQUARE_WIDTH, SQUARE_WIDTH, SQUARE_WIDTH, 0, 0, 32, 32, false, true);\n\t\t\t}\n\n\t\t\t\n\t\t}\n\n\t\t// Draw the creeps!\n\t\tfor( int i = 0; i < creeps.size(); ++i)\n\t\t{\n\n\t\t\tif( creeps.get(i).active ) {\n\t\t\t\tTextureRegion toUse = null;\n\t\t\t\t//TextureRegion toUse = new TextureRegion(corporateCreepTexture);\n\t\t\t\tif (creeps.get(i).m_type == CreepType.GLOBAL_CORP) {\n\t\t\t\t\ttoUse = new TextureRegion(corporateCreepTexture);\n\t\t\t\t} else if (creeps.get(i).m_type == CreepType.SEARCHER) {\n\t\t\t\t\ttoUse = new TextureRegion(defconZeplinTexture);\n\t\t\t\t} else if (creeps.get(i).m_type == CreepType.GOVERNMENT) {\n\t\t\t\t\ttoUse = new TextureRegion(govHeliTexture);\n\t\t\t\t} else {\n\t\t\t\t\t// TODO: Change this to difference art.\n\t\t\t\t\ttoUse = new TextureRegion(corporateCreepTexture);\n\t\t\t\t}\n\t\t\t\tbatch.draw(toUse, creeps.get(i).x * SQUARE_WIDTH + creeps.get(i).xOffset, creeps.get(i).y * SQUARE_WIDTH + creeps.get(i).yOffset, SQUARE_WIDTH, SQUARE_WIDTH);\n\t\t\t\t//batch.draw(toUse, creeps.get(i).x * SQUARE_WIDTH + creeps.get(i).xOffset, creeps.get(i).y * SQUARE_WIDTH + creeps.get(i).yOffset, SQUARE_WIDTH, SQUARE_WIDTH, 0, 32, 32, 32, false, false);\n\t\t\t}\n\t\t}\n\n\t\t// Draw the projectiles!\n\t\tfor( int i = 0; i < maxProjectiles; ++i )\n\t\t{\n\t\t\tif( projectiles[i].active )\n\t\t\t{\n//\t\t\t\tbatch.draw( spriteSheet, projectiles[i].my_coords.x*SQUARE_WIDTH, projectiles[i].my_coords.y*SQUARE_WIDTH, SQUARE_WIDTH, SQUARE_WIDTH, 0, 16*3, 16, 16, false, false);\n\t\t\t\tif (projectiles[i].towertype == \"judge\"){\n\t\t\t\t\tbatch.draw( spriteSheet, projectiles[i].my_coords.x*SQUARE_WIDTH, projectiles[i].my_coords.y*SQUARE_WIDTH, SQUARE_WIDTH, SQUARE_WIDTH, 0, 16*3, 16, 16, false, false);\n\t\t\t\t} else if (projectiles[i].towertype == \"teacher\"){\n\t\t\t\t\tbatch.draw( spriteSheet, projectiles[i].my_coords.x*SQUARE_WIDTH, projectiles[i].my_coords.y*SQUARE_WIDTH, SQUARE_WIDTH, SQUARE_WIDTH, 16, 16*3, 16, 16, false, false);\n\t\t\t\t} else if (projectiles[i].towertype == \"lawyer\"){\n\t\t\t\t\tbatch.draw( spriteSheet, projectiles[i].my_coords.x*SQUARE_WIDTH, projectiles[i].my_coords.y*SQUARE_WIDTH, SQUARE_WIDTH, SQUARE_WIDTH, 32, 16*3, 16, 16, false, false);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\t// Draw the UI!\n\n\t\t// Background\n\n\t\tbatch.draw(blackBox, 0, 0, uiPanelWidth , screenHeight);\n\n\t\t// Draw the menu bar\n\t\tbatch.draw(menuTexture,-4,-190);\n\t\t//batch.draw(menu_region, 0, -100);\n\t\t\n\t\t// Draw the free towers.\n\t\t\n\t\tfor (int i = 1; i <= 3; i++) \n\t\t{\n\t\t\tif (free_towers.get(i-1) != null) \n\t\t\t{\n\t\t\t\t//tower_region.setRegion( free_towers.get(i-1).getSpriteLocX(), free_towers.get(i-1).getSpriteLocY(), 16, 16 );\n\t\t\t\tbatch.draw(free_towers.get(i-1).getTextureRegion(), 29, (screenHeight - 60 * i) + 5, SQUARE_WIDTH, SQUARE_WIDTH);\n\t\t\t\t//batch.draw(tower_region, 33, screenHeight - 57 * i, 16, 16);\n\t\t\t\t\n\t\t\t\tString towerPrice = \"$\" + free_towers.get(i-1).getPrice();\n\t\t\t\tTextBounds priceBounds = mFont.getBounds(towerPrice);\n\t\t\t\tColor oldColor = mFont.getColor();\n\t\t\t\tmFont.setColor(Color.GREEN);\n\t\t\t\tmFont.drawWrapped(batch, towerPrice, 10, 33 + screenHeight - 58*i + priceBounds.height, priceBounds.width);\n\t\t\t\tmFont.setColor(oldColor);\n\t\t\t}\n\t\t}\t\t\n\t\t\n\t\t// Keep the GC in its cage as long as possible. \n\t\tif( oldMoney != money || oldLife != life )\n\t\t{\n\t\t\tuiString = \"+: \" + life + '\\n' + \"$: \" + money;\n\t\t\tuiBounds = mFont.getMultiLineBounds(uiString);\n\t\t}\n\t\toldMoney = money;\n\t\toldLife = life;\n\t\t\t\t\n\t\t// Draw droid pause button if on an android device.\n\t\tif (runningDrd) {\n\t\t\t\n\t\t\tpause_button_region.setRegion(7*17, 23, 2, 2);\n\t\t\tbatch.draw(pause_button_region, DRD_PAUSE_RECT.x, DRD_PAUSE_RECT.y, DRD_PAUSE_RECT.width, DRD_PAUSE_RECT.height);\n\t\t\t\n\t\t\tString pause_button_string = \"Pause\";\n\t\t\tTextBounds pauseButtonBounds = mFont.getBounds(pause_button_string);\n\t\t\tmFont.drawWrapped(batch, pause_button_string,\n\t\t\t\t\t\t\t(32 - (pauseButtonBounds.width / 2)),\n\t\t\t\t\t\t\tDRD_PAUSE_RECT.y + pauseButtonBounds.height + 4, pauseButtonBounds.width);\n\t\t}\n\t\t\n\t\t// Draw the restart button if paused or game over.\n\t\tif (life <= 0 || isPaused) {\n\t\t\t\n\t\t\trestart_button_region.setRegion(7*17, 23, 2, 2);\n\t\t\tbatch.draw(restart_button_region, RESTART_RECT.x, RESTART_RECT.y, RESTART_RECT.width, RESTART_RECT.height);\n\t\t\t\n\t\t\tString restart_button_string = \"Restart\";\n\t\t\tTextBounds restartButtonBounds = mFont.getBounds(restart_button_string);\n\t\t\tmFont.drawWrapped(batch, restart_button_string,\n\t\t\t\t\t\t\t(32 - (restartButtonBounds.width / 2)),\n\t\t\t\t\t\t\tRESTART_RECT.y + restartButtonBounds.height + 4, restartButtonBounds.width);\n\t\t\t\n\t\t\t\n\t\t}\n\t\t\n\t\t// Draw the start button if we are in build mode.\n\t\tif (buildMode) {\n\t\t\t\n\t\t\tstart_button_region.setRegion(7*17, 23, 2, 2);\n\t\t\tbatch.draw(start_button_region, START_RECT.x, START_RECT.y, START_RECT.width, START_RECT.height);\n\t\t\t\n\t\t\tString start_button_string = \"Start\";\n\t\t\tTextBounds startButtonBounds = mFont.getBounds(start_button_string);\n\t\t\tmFont.drawWrapped(batch, start_button_string,\n\t\t\t\t\t\t\t(32 - (startButtonBounds.width / 2)),\n\t\t\t\t\t\t\tSTART_RECT.y + startButtonBounds.height + 4, startButtonBounds.width);\n\t\t\t\n\t\t\t\n\t\t}\n\t\t\n\t\t// Draw the sell button if we are not paused or in build mode and a tower is selected.\n\t\tif (!isPaused && !buildMode && selected != null) {\n\t\t\t\n\t\t\tsell_button_region.setRegion(7*17, 23, 2, 2);\n\t\t\tbatch.draw(sell_button_region, SELL_RECT.x, SELL_RECT.y, SELL_RECT.width, SELL_RECT.height);\n\t\t\t\n\t\t\tString sell_button_string = \"Sell\";\n\t\t\tTextBounds sellButtonBounds = mFont.getBounds(sell_button_string);\n\t\t\tmFont.drawWrapped(batch, sell_button_string,\n\t\t\t\t\t\t\t(32 - (sellButtonBounds.width / 2)),\n\t\t\t\t\t\t\tSTART_RECT.y + sellButtonBounds.height + 4, sellButtonBounds.width);\n\t\t}\n\t\t\n\t\t// Text\n\t\tString uiString = \"+ \" + life + '\\n' + \"$ \" + money;\n\t\tTextBounds uiBounds = mFont.getMultiLineBounds(uiString);\n\t\tColor oldColor = mFont.getColor();\n\t\tmFont.setColor(Color.RED);\n\t\tmFont.drawWrapped(batch, uiString, 3, uiBounds.height + 3, uiBounds.width);\n\t\tmFont.setColor(oldColor);\n\n\t\t// DEBUG TEXT\n\t\t//mFont.drawWrapped(batch, debugtext, 60, uiBounds.height + 3, 1000);\t\t\n\n\t\t// Draw the cursorTexture\n\t\tif (cursorState != null && cursorTexture != null) {\n\t\t\tbatch.draw(cursorTexture, cursorLocX - 8, screenHeight - cursorLocY - 8);\n\t\t}\n\t\t\n\t\t// Render Paused String if needed in bottom right corner.\n\t\tString center_string = null;\n\t\tif (isPaused) {\n\t\t\tcenter_string = \"PAUSED\";\n\t\t} else if (life <= 0) {\n\t\t\tcenter_string = \"GAME OVER\";\n\t\t}\n\t\t\n\t\tif (center_string != null) {\n\t\t\tTextBounds pausedBounds = mFont.getMultiLineBounds(center_string);\n\t\t\tColor oldColor2 = mFont.getColor();\n\t\t\tmFont.setColor(Color.RED);\n\t\t\tmFont.drawWrapped(batch, center_string,\n\t\t\t\t\t(screenWidth / 2) - (pausedBounds.width / 2),\n\t\t\t\t\t(screenHeight / 2) - (pausedBounds.height / 2), pausedBounds.width );\n\t\t\tmFont.setColor(oldColor2);\n\t\t}\n\t\t\n\t\tbatch.end();\n\t}",
"public void drawCell()\n {\n // if mouse is not inside tile area dont draw anything\n if(showHover)\n {\n noStroke();\n \n rect(firstCellPosition[0]+hover[0]*cellSize,firstCellPosition[1]+hover[1]*cellSize,cellSize-1,cellSize-1);\n \n if(brushSize == 1)\n {\n if(!pattern[hover[0]][hover[1]])\n {\n pattern[hover[0]][hover[1]] = true;\n fill(0);\n }\n else\n {\n pattern[hover[0]][hover[1]] = false;\n fill(255);\n }\n rect(firstCellPosition[0]+hover[0]*cellSize,firstCellPosition[1]+hover[1]*cellSize,cellSize-1,cellSize-1);\n }\n if(brushSize == 2)\n {\n for(int i = 0; i < 2; i++)\n {\n for(int j = 0; j < 2; j++)\n {\n if(hover[0]+i < xCells && hover[1]+j < yCells)\n {\n if(!pattern[hover[0]+i][hover[1]+j])\n {\n pattern[hover[0]+i][hover[1]+j] = true;\n fill(0);\n }\n else\n {\n pattern[hover[0]+i][hover[1]+j] = false;\n fill(255);\n }\n rect(firstCellPosition[0]+(hover[0]+i)*cellSize,firstCellPosition[1]+(hover[1]+j)*cellSize,cellSize-1,cellSize-1);\n }\n }\n }\n }\n if(brushSize == 3)\n {\n for(int i = -1; i < 2; i++)\n {\n for(int j = -1; j < 2; j++)\n {\n if(hover[0]+i < xCells && hover[1]+j < yCells &&\n hover[0]+i >= 0 && hover[1]+j >= 0 )\n {\n if(!pattern[hover[0]+i][hover[1]+j])\n {\n pattern[hover[0]+i][hover[1]+j] = true;\n fill(0);\n }\n else\n {\n pattern[hover[0]+i][hover[1]+j] = false;\n fill(255);\n }\n rect(firstCellPosition[0]+(hover[0]+i)*cellSize,firstCellPosition[1]+(hover[1]+j)*cellSize,cellSize-1,cellSize-1);\n }\n }\n }\n }\n }\n }",
"public void paintNormalized(){\n\t\t\n\t\tint min = 99999;\n\t\tint max = 0;\n\t\t\n\t\tfor (int i=0; i < ranges.size(); i++){\n\t\t\tif ((ranges.elementAt(i).getMin()) < min){\n\t\t\t\tmin = ranges.elementAt(i).getMin();\n\t\t\t}\n\t\t\tif ((ranges.elementAt(i).getMax()) > max){\n\t\t\t\tmax = ranges.elementAt(i).getMax();\n\t\t\t}\n\t\t}\n\t\t\n\t\t// Once I've got them, the paint is simple, because Positioner.getAssociatedPosition() returns\n\t\t// the exact pixel where the color has to be painted\n\t\t\n\t\tPositioner positions = new Positioner(drawingPanel.getHeight(), min, max);\n\t\t\n\t\tint i = 1;\n\t\tBufferedImage img = new BufferedImage(drawingPanel.getWidth(), drawingPanel.getHeight(), BufferedImage.TYPE_INT_ARGB);\n\t\t\t\t\n\t\twhile (i <= ranges.size()){\n\t\t\tpaintBufferedSolid(ranges.elementAt(ranges.size()-i).getColor(),positions.getAssociatedPosition(ranges.elementAt(ranges.size()-i).getMax()) , positions.getAssociatedPosition(ranges.elementAt(ranges.size()-i).getMin()), img);\n\t\t\ti++;\n\t\t}\n\n\t\t\t\n\t\t\n\t\tdrawingPanel.getGraphics().drawImage(img, 0, 0, img.getWidth(), img.getHeight(), null);\n\t\t\n\t\t// Painting the ranges\n\t\t\n\t\trangesPanel.removeAll();\t\t\t// Clears rangePanel\n\t\t\n\t\tJLabel currentRange;\n\t\t\n\t\tcurrentRange = new JLabel(Integer.toString(ranges.elementAt(0).getMin()));\n\t\tcurrentRange.setHorizontalAlignment(SwingConstants.RIGHT);\n\t\tcurrentRange.setBounds(35, rangesPanel.getHeight()-16, 60, 16);\n\t\t\n\t\t\n\t\trangesPanel.add(currentRange);\n\t\tint last = rangesPanel.getHeight()-16;\n\t\tint aux;\n\t\tfor (int j = 0; j < ranges.size(); j++){\n\t\t\taux = positions.getAssociatedPosition(ranges.elementAt(j).getMax());\n\t\t\tcurrentRange = new JLabel(Integer.toString(ranges.elementAt(j).getMax()));\n\t\t\tcurrentRange.setHorizontalAlignment(SwingConstants.RIGHT);\n\t\t\tif (aux+16 < last){\n\t\t\t\tcurrentRange.setBounds(35, aux, 60, 16);\n\t\t\t\tlast = aux;\n\t\t\t}\n\t\t\telse{\n\t\t\t\tcurrentRange.setBounds(35, last-16, 60, 16);\n\t\t\t\tlast = last - 16;\n\t\t\t}\n\t\t\t\t\n\t\t\trangesPanel.add(currentRange);\n\t\t}\n\t\t\n\t\trangesPanel.repaint();\n\t}",
"@Override\r\n public void paintComponent(Graphics brush)\r\n {\r\n super.paintComponent(brush);\r\n Graphics2D g2 = (Graphics2D) brush;\r\n /*Faster Rendering for mouse interaction*/\r\n g2.setRenderingHint(RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_ON);\r\n g2.setRenderingHint(RenderingHints.KEY_TEXT_ANTIALIASING, RenderingHints.VALUE_TEXT_ANTIALIAS_ON);\r\n \r\n \r\n if (!wps.getWalls().isEmpty())\r\n {\r\n x = INITIAL_X;\r\n int wallNo = 1;\r\n /*Iterate for all Walls*/\r\n for (Wall wa : wps.getWalls())\r\n {\r\n /*Rectangle counters*/\r\n int rectangles = 0;\r\n for (int bays : wa.getBaysArray())\r\n {\r\n y = INITIAL_Y;\r\n for (int i=0; i<bays;i++)\r\n {\r\n brush.drawRect(x,y, SLEEPER_W, SLEEPER_H);\r\n brush.setFont(f);\r\n //Centering the Name\r\n brush.drawString(\"Wall \"+wallNo, x+28, y+16);\r\n y = y - SLEEPER_H;\r\n }\r\n \r\n /*Painting rectangles to simulate at entire bay*/\r\n if(wps.getWalls().get(wallNo-1).getArrayRect().size() != wps.getWalls().get(wallNo-1).getBaysArray().size())\r\n {\r\n wps.getWalls().get(wallNo-1).getArrayRect().add(new Rectangle(x,y+SLEEPER_H, SLEEPER_W, (SLEEPER_H*bays)));\r\n }\r\n g2.draw(wps.getWalls().get(wallNo-1).getArrayRect().get(rectangles));\r\n rectangles++;\r\n x = x + SLEEPER_W;\r\n \r\n }\r\n wallNo++;\r\n }\r\n }\r\n \r\n if (x> 830)\r\n {\r\n this.setPreferredSize(new Dimension(x+20,560));\r\n this.revalidate();\r\n }\r\n }",
"public void mouseExited(MouseEvent e) {\n if (isDraging){// ger fal kardane khanehaye drag shode ba raftane dobare ruye Anha\n setNotCopying();\n if(mlpp1<mlp1){// baraye raftan be paein\n for(int p=mlpp1;p<=mlp1; p++){\n if(mlpp2<mlp2)// baraye raftan be paein samte rast\n for(int k=mlpp2;k<=mlp2;k++){\n jtf[p][k].setBackground(Color.white);\n ++cellSelCounter;\n }\n if(mlpp2>mlp2)// baraye raftan be pain samte chap\n for(int k=mlpp2;k>=mlp2;k--){\n jtf[p][k].setBackground(Color.white);\n ++cellSelCounter;\n }\n jtf[p][mlpp2].setBackground(Color.white);\n ++cellSelCounter;\n }\n }// payane raftan be paein\n if(mlpp1>mlp1){// baraye raftan be bala\n for(int p=mlpp1;p>=mlp1; p--){\n if(mlpp2<mlp2)// baraye raftan be bala samte rast\n for(int k=mlpp2;k<=mlp2;k++){\n jtf[p][k].setBackground(Color.white);\n ++cellSelCounter;\n }\n if(mlpp2>mlp2)// baraye raftan be bala samte chap\n for(int k=mlpp2;k>=mlp2;k--){\n jtf[p][k].setBackground(Color.white);\n ++cellSelCounter;\n }\n jtf[p][mlpp2].setBackground(Color.white);\n ++cellSelCounter;\n }\n }// payane harekat be bala.\n if(mlpp2<mlp2)// baraye raftan be rast\n for(int k=mlpp2 ; k<=mlp2;k++){\n jtf[mlpp1][k].setBackground(Color.white);\n ++cellSelCounter;\n }\n if(mlpp2>mlp2)// baraye harekat be chap\n for(int k=mlpp2;k>=mlp2;k--){\n jtf[mlpp1][k].setBackground(Color.white);\n ++cellSelCounter;\n }\n }// payane geyre fa'al kardane khane haye drag shode\n if(e.getSource()==jtf[mlp1][mlp2]) // agar az samte paein az khane sabz kharej shod-\n if(jtf[mlp1][mlp2].getBackground()==Color.green)//- range an bayad be abi tabdil shawad.\n jtf[mlp1][mlp2].setBackground(Color.blue);\n }",
"public void paintComponent(Graphics2D g2)\r\n {\r\n //fill background\r\n g2.setColor(Color.black);\r\n g2.fill(new Rectangle2D.Double(initX, 0, width, height));\r\n \r\n //paint \"buttons\"\r\n g2.setColor(Color.white);\r\n Font f = new Font(\"\", Font.BOLD, FONT_SIZE);\r\n g2.setFont(f);\r\n for (int i = 0; i < towerTypes.length; i++)\r\n {\r\n g2.draw(towerButtons[i]);\r\n \r\n int textLength = towerTypes[i].length();\r\n double x = towerButtons[i].getX();\r\n double y = towerButtons[i].getY();\r\n double textX = x + (width/2 - textLength*FONT_SIZE/4);\r\n double textY = y + FONT_SIZE;\r\n g2.drawString(towerTypes[i], (float)textX, (float)textY);\r\n }\r\n \r\n display.paintComponent(g2, initX + GAP, height/2,\r\n width - 2*GAP, height/4, f);\r\n }",
"public void drawSelector(int x) {\n int currentTime = millis() / 100;\n noStroke();\n if (currentTime % 13 == 0) {\n fill(200, 200, 100, 30);\n }\n else if (currentTime % 13 == 1) {\n fill(200, 200, 100, 40);\n }\n else if (currentTime % 13 == 2) {\n fill(200, 200, 100, 50);\n }\n else if (currentTime % 13 == 3) {\n fill(200, 200, 100, 60);\n }\n else if (currentTime % 13 == 4) {\n fill(200, 200, 100, 70);\n }\n else if (currentTime % 13 == 5) {\n fill(200, 200, 100, 80);\n }\n else if (currentTime % 13 == 6) {\n fill(200, 200, 100, 90);\n }\n else if (currentTime % 13 == 7) {\n fill(200, 200, 100, 100);\n }\n else if (currentTime % 13 == 8) {\n fill(200, 200, 100, 110);\n }\n else if (currentTime % 13 == 9) {\n fill(200, 200, 100, 120);\n }\n else if (currentTime % 13 == 10) {\n fill(200, 200, 100, 130);\n }\n else if (currentTime % 13 == 11) {\n fill(200, 200, 100, 140);\n }\n else if (currentTime % 13 == 12) {\n fill(200, 200, 100, 150);\n }\n else {\n fill(255, 200, 100);\n }\n switch(x){\n case 1:\n beginShape();\n vertex(80, 330);\n vertex(50, 360);\n vertex(80, 350);\n vertex(110, 360);\n endShape();\n break;\n case 2:\n beginShape();\n vertex(370, 330);\n vertex(340, 360);\n vertex(370, 350);\n vertex(400, 360);\n endShape();\n break;\n case 3:\n beginShape();\n vertex(80, 600);\n vertex(50, 630);\n vertex(80, 620);\n vertex(110, 630);\n endShape();\n break;\n case 4:\n beginShape();\n vertex(370, 600);\n vertex(340, 630);\n vertex(370, 620);\n vertex(400, 630);\n endShape();\n break;\n }\n\n}",
"private void drawHelp(Graphics2D g2d) {\n Composite orig_comp = g2d.getComposite();\n g2d.setColor(RTColorManager.getColor(\"brush\", \"dim\")); g2d.setComposite(AlphaComposite.getInstance(AlphaComposite.SRC_OVER, 0.8f)); g2d.fillRect(0,0,getWidth(),getHeight()); g2d.setComposite(orig_comp);\n int base_x = 5, base_y = Utils.txtH(g2d,\"0\");\n base_y = drawKeyCombo(g2d, base_x, base_y, \"Key\", \"Normal\", \"Shift\", \"Ctrl\", \"Ctrl-Shift\");\n base_y = drawKeyCombo(g2d, base_x, base_y, \"E\", \"Expand Selection\", \"Use Directed Graph\");\n base_y = drawKeyCombo(g2d, base_x, base_y, \"1 - 9\", \"Select Degree\", \"Subtract\", \"Add\", \"Intersect\");\n base_y = drawKeyCombo(g2d, base_x, base_y, \"0\", \"Select Degree > 10\", \"Subtract\", \"Add\", \"Intersect\");\n base_y = drawKeyCombo(g2d, base_x, base_y, \"R\", \"Select Cut Vertices\", \"Subtract\", \"Add\", \"Intersect\");\n base_y = drawKeyCombo(g2d, base_x, base_y, \"Q\", \"Invert Selection\");\n base_y = drawKeyCombo(g2d, base_x, base_y, \"X\", \"Hide Selection\");\n base_y = drawKeyCombo(g2d, base_x, base_y, \"M\", \"Toggle Mode\");\n base_y = drawKeyCombo(g2d, base_x, base_y, \"G\", \"Grid Layout Mode\");\n base_y = drawKeyCombo(g2d, base_x, base_y, \"Y\", \"Line Layout Mode\");\n base_y = drawKeyCombo(g2d, base_x, base_y, \"C\", \"Circle Layout Mode\");\n base_y = drawKeyCombo(g2d, base_x, base_y, \"T\", \"Group Nodes\", \"Align Horizontally\", \"Align Vertically\", \"\");\n base_y = drawKeyCombo(g2d, base_x, base_y, \"S\", \"Set/Clear Sticky Labels\", \"Subtract From\", \"Add To\", \"Intersect With\");\n base_y = drawKeyCombo(g2d, base_x, base_y, \"V\", \"Toggle Node Size\");\n base_y = drawKeyCombo(g2d, base_x, base_y, \"L\", \"Toggle Labels\", \"Toggle Edge Templates\", \"Toggle Node Legend\", \"\");\n base_y = drawKeyCombo(g2d, base_x, base_y, \"W\", \"Make One Hops Visible\", \"Use Directed Graph\");\n base_y = drawKeyCombo(g2d, base_x, base_y, \"N\", \"Add Note\");\n base_y = drawKeyCombo(g2d, base_x, base_y, \"A\", \"Pan Mode\");\n base_y = drawKeyCombo(g2d, base_x, base_y, \"F\", \"Fit\");\n base_y = drawKeyCombo(g2d, base_x, base_y, \"Minus (-)\", \"Zoom Out\", \"Fit\");\n base_y = drawKeyCombo(g2d, base_x, base_y, \"Plus (+)\", \"Zoom In\");\n base_y = drawKeyCombo(g2d, base_x, base_y, \"Cursor Keys\", \"Shift Selected Nodes\");\n base_y = drawKeyCombo(g2d, base_x, base_y, \"< >\", \"Rotate Selected Nodes\", \"15 Degs\", \"90 Degs\", \"\");\n base_y = drawKeyCombo(g2d, base_x, base_y, \"{ }\", \"Scale Selected Nodes\", \"More\", \"Even More\", \"\");\n base_y = drawKeyCombo(g2d, base_x, base_y, \"F[2-5]\", \"Save Layout To Fx\", \"Restore\", \"Delete\", \"Restore\");\n }",
"private void drawSelectedToolArea (IEditableByTool imageModel, Point<Integer> endPoint, int maxWidth, int maxHeight){\n List<Pixel> arrayList = new ArrayList<>();\n\n int minX = Math.max((startPoint.getX() < endPoint.getX()) ? startPoint.getX() : endPoint.getX(),0);\n int maxX = Math.min((startPoint.getX() > endPoint.getX()) ? startPoint.getX() : endPoint.getX(),maxWidth - 1);\n int minY = Math.max((startPoint.getY() < endPoint.getY()) ? startPoint.getY() : endPoint.getY(),0);\n int maxY = Math.min((startPoint.getY() > endPoint.getY()) ? startPoint.getY() : endPoint.getY(),maxHeight - 1);\n\n for(int i = minX; i <= maxX; i++){\n if (i % 5 == 0){\n arrayList.add(new Pixel(i, minY, paintColor));\n arrayList.add(new Pixel(i, maxY, paintColor));\n }\n\n }\n for(int j = minY + 1; j < maxY; j++){\n if (j % 5 == 0) {\n arrayList.add(new Pixel(minX, j, paintColor));\n arrayList.add(new Pixel(maxX, j, paintColor));\n }\n }\n\n imageModel.addToSelectOverlay(arrayList);\n\n }",
"public static void main(String[] args) {\n\tString anyColors =\tJOptionPane.showInputDialog(\"What color would you like?\");\n\tString anyShape= JOptionPane.showInputDialog(\"What Shape would you like?\"); \n\t\t//4. use an if/else statement to set the pen color that the user requested\nif (anyColors.equalsIgnoreCase(\"Red\")) \n{\n\tTortoise.setPenColor(Color.red);\n}\nif (anyColors.equalsIgnoreCase(\"Blue\")) \n{\n\tTortoise.setPenColor(Color.blue);\n}\nif (anyColors.equalsIgnoreCase(\"Green\")) \n{\n\tTortoise.setPenColor(Color.green);\n}if (anyColors.equalsIgnoreCase(\"Gray\")) \n{\n\tTortoise.setPenColor(Color.GRAY);\n}if (anyColors.equalsIgnoreCase(\"orange\")) \n{\n\tTortoise.setPenColor(Color.orange);\n}if (anyColors.equalsIgnoreCase(\"yellow\")) \n{\n\tTortoise.setPenColor(Color.yellow);\n}\nif (anyColors.equalsIgnoreCase(\"\")) \n{\n\tTortoise.setPenColor(Color.MAGENTA);\t\n} \n\n//if(anyShape.equalsIgnoreCase(\"Triangle\"))\n//{\n//Tortoise.turn(40);\n//Tortoise.move(50);\n//Tortoise.turn(40);\n//Tortoise.move(40);\n//Tortoise.turn(40);\n//}\n\n\n//5. if the user doesn’t enter anything, choose a random color\n\n//6. put a loop around your code so that you keep asking the user for more colors & drawing them\n\t\t\n\t\t//2. set the pen width to 10\n\t\tTortoise.setPenWidth(5);\n\t//1. make the tortoise draw a shape (this will take more than one line of code)\n\t\tTortoise.getBackgroundWindow();\n\t\tTortoise.setSpeed(10);\n\t\tfor (int i = 0; i < 20; i++) \n\t\t{\n\t\tTortoise.move(50);\n\t\tTortoise.turn(60);\n\t\tTortoise.move(100);\n\t\tTortoise.turn(+120);\n\t\t\n\t\t}\n\n\t}",
"private void treinRepaint()\r\n {\r\n if(treinaantal != 0){\r\n for(int i =0; i < treinaantal; i++){\r\n int[] id = {treinlijst[i].getId()};\r\n int[] arg = {treinlijst[i].getPositie()};\r\n main.updateGui(\"trein\", id, arg);\r\n }\r\n }\r\n }",
"public void drawHillTops() {\n batch.draw(hillTop, hill1.getX(), hill1.getY() + hill1.getHeight() - (19), hill1.getWidth(), 21);\n batch.draw(hillTop, hill2.getX(), hill2.getY() + hill2.getHeight() - (19), hill2.getWidth(), 21);\n batch.draw(hillTop, hill3.getX(), hill3.getY() + hill3.getHeight() - (19), hill3.getWidth(), 21);\n batch.draw(hillTop, hill4.getX(), hill4.getY() + hill4.getHeight() - (19), hill4.getWidth(), 21);\n }",
"private void createSwitches() {\n \t\tswitches = new Point[4];\n \t\tswitches[0] = new Point(centreMin, centreMin);\n \t\tswitches[1] = new Point(centreMin, centreMax-1);\n \t\tswitches[2] = new Point(centreMax-1, centreMin);\n \t\tswitches[3] = new Point(centreMax-1, centreMax-1);\n \t}",
"public void draw(Window w) {\n\t\tfor (int i = 0; i < 20; i++) {\n\t\t\tdouble angle = i * Math.PI / 10;\n\t\t\tint row = rb + (int) Math.round((height * Math.cos(angle)));\n\t\t\tint col = cb + (int) Math.round((width * Math.sin(angle)));\n\t\t\tw.setCell(row, col, character);\n\t\t}\n\t}",
"public void syria(){\n stroke(1);\n //back guns\n fill(0);\n rect(73,192,4,15);\n rect(224,192,4,15);\n rect(71,207,8,15);\n rect(222,207,8,15);\n rect(66,207,3,15);\n rect(232,207,3,17);\n rect(122,109,4,15);\n rect(175,110,4,15);\n rect(121,120,6,15);\n rect(174,120,6,15);\n rect(116,124,3,15);\n rect(182,124,3,15);\n\n //wings\n fill(206,17,38);//red\n beginShape();\n vertex(14,286);\n vertex(61,236);\n vertex(88,308);\n vertex(51,334);\n vertex(14,313);\n endShape(CLOSE);\n beginShape();\n vertex(286,287);\n vertex(286,312);\n vertex(247,335);\n vertex(212,309);\n vertex(238,238);\n endShape(CLOSE);\n\n fill(200);//white\n beginShape();\n vertex(38,307);\n vertex(74,307);\n vertex(80,314);\n vertex(81,337);\n vertex(68,345);\n vertex(38,327);\n endShape(CLOSE);\n beginShape();\n vertex(219,316);\n vertex(226,308);\n vertex(262,308);\n vertex(262,326);\n vertex(231,345);\n vertex(219,336);\n endShape(CLOSE);\n\n fill(0);//red\n beginShape();\n vertex(96,191);\n vertex(61,230);\n vertex(60,269);\n vertex(96,312);\n vertex(101,300);\n vertex(100,247);\n vertex(112,232);\n vertex(132,232);\n vertex(131,186);\n endShape(CLOSE);\n beginShape();\n vertex(204,191);\n vertex(240,230);\n vertex(240,270);\n vertex(205,312);\n vertex(200,302);\n vertex(200,248);\n vertex(193,238);\n vertex(185,231);\n vertex(170,230);\n vertex(170,186);\n endShape(CLOSE);\n\n //white\n fill(200);\n beginShape();\n vertex(70,217);\n vertex(74,220);\n vertex(81,210);\n vertex(85,213);\n vertex(75,227);\n vertex(72,229);\n vertex(71,231);\n vertex(73,233);\n vertex(73,268);\n vertex(71,272);\n vertex(76,277);\n vertex(82,274);\n vertex(89,283);\n vertex(90,297);\n vertex(66,272);\n vertex(65,235);\n vertex(68,229);\n vertex(62,228);\n endShape(CLOSE);\n beginShape();\n vertex(228,217);\n vertex(225,218);\n vertex(218,211);\n vertex(215,213);\n vertex(223,227);\n vertex(226,226);\n vertex(230,230);\n vertex(227,233);\n vertex(228,270);\n vertex(229,272);\n vertex(223,276);\n vertex(218,276);\n vertex(210,283);\n vertex(211,296);\n vertex(235,273);\n vertex(234,233);\n vertex(232,228);\n vertex(237,227);\n endShape(CLOSE);\n\n //guns\n //white\n fill(200);\n beginShape();\n vertex(121,301);\n vertex(98,313);\n vertex(102,336);\n vertex(119,342);\n vertex(139,336);\n vertex(141,313);\n endShape(CLOSE);//l\n beginShape();\n vertex(159,312);\n vertex(162,336);\n vertex(180,342);\n vertex(200,336);\n vertex(202,313);\n vertex(180,302);\n endShape(CLOSE);\n\n //black\n fill(0);\n rect(105,315,30,30);\n rect(166,315,30,30);\n quad(105,344,109,355,131,355,135,344);\n quad(166,344,170,355,192,355,196,344);\n //green\n fill(0,122,61);\n rect(103,253,33,62);//l\n rect(164,252,33,62);//r\n //white\n fill(200);\n bezier(103,252,107,230,132,230,136,252);//l\n bezier(164,252,169,230,192,230,197,252);//r\n rect(103,280,33,25);//l\n rect(164,280,33,25);//r\n rect(104,319,33,26,3);//l\n rect(165,319,33,26,3);//r\n rect(115,310,7,28,8);//l\n rect(178,310,7,28,8);//r\n //green\n fill(0,122,61);\n rect(105,284,10,15);\n rect(124,284,10,15);\n rect(167,285,10,15);\n rect(185,284,10,15);\n\n //body-wings\n\n fill(0,122,61);//green\n bezier(107,154,101,162,98,169,98,187);\n bezier(191,153,199,164,202,172,203,187);\n quad(107,154,98,186,98,223,107,224);\n quad(191,153,203,186,202,223,192,223);\n fill(206,17,38);//red\n quad(134,112,108,147,107,239,132,230);\n quad(165,112,192,147,193,239,168,230);\n //black\n fill(0);\n quad(130,122,130,142,111,164,111,147);\n quad(169,122,188,147,188,165,169,144);\n //white\n fill(200);\n beginShape();\n vertex(131,154);\n vertex(129,202);\n vertex(118,202);\n vertex(112,181);\n vertex(110,179);\n vertex(110,171);\n endShape(CLOSE);\n beginShape();\n vertex(170,154);\n vertex(190,172);\n vertex(190,182);\n vertex(188,181);\n vertex(182,201);\n vertex(172,201);\n endShape(CLOSE);\n\n fill(0);\n quad(134,193,166,193,154,342,146,342);\n fill(0);\n quad(142,180,159,180,152,352,148,352);\n //white\n fill(200);\n ellipse(150,374,6,50);\n\n //head\n\n fill(206,17,38);\n ellipse(149.5f,72,33,25);\n ellipse(149.5f,94,30,170);\n fill(0);\n ellipse(149.5f,94,20,160);\n fill(154,155,84);\n ellipse(149.5f,94,17,77);\n strokeWeight(2);\n line(143,74,158,74);\n line(142,104,158,104);\n strokeWeight(1);\n fill(200);\n bezier(143,15,147,2,153,2,155.5f,15);\n}",
"@Override\r\n public void paint(Graphics y) {\n super.paintComponent(y);\r\n\r\n for (int i = 0; i < 20; i++) {\r\n\r\n switch (opcion) {\r\n case 1:\r\n int xRect = 10 + (i *10);\r\n int yRect = 10 + (i * 10);\r\n int anchoRect = 50 + (i * 10);\r\n int altoRect = 50 + (i * 10);\r\n\r\n y.drawRect(xRect, yRect, anchoRect, altoRect);\r\n break;\r\n\r\n case 2:\r\n int xOval = 10 + (i * 10);\r\n int yOval = 10 + (i * 10);\r\n int anchoOval = 50 + (i * 10);\r\n int altoOval = 50 + (i * 10);\r\n\r\n y.drawOval(xOval, yOval, anchoOval, altoOval);\r\n break;\r\n\r\n case 3:\r\n int x3d = 10 + (i * 10);\r\n int y3d = 10 + (i * 10);\r\n int ancho3d = 50 + (i * 10);\r\n int alto3d = 50 + (i * 10);\r\n y.draw3DRect(x3d, y3d, ancho3d, alto3d, true);\r\n break;\r\n \r\n case 4:\r\n int rectax = 100 + (i * 10);\r\n int rectay = 100 + (i * 10);\r\n int anchorecta = 500 + (i * 10);\r\n int altorecta = 500 + (i * 10);\r\n y.drawLine(rectax, rectay, anchorecta, altorecta);\r\n \r\n \r\n case 5:\r\n int rectaxx = 100 + (i * 10);\r\n int rectayy = 100 + (i * 10);\r\n int anchonueva = 500 + (i * 10);\r\n int altonueva = 500 + (i * 10);\r\n y.draw3DRect(rectaxx, rectayy, anchonueva, altonueva, true);\r\n }\r\n\r\n }\r\n\r\n }",
"public void drawCanvas() {\n \n // Change the background color to match the state of the plotter\n if( plotter != null ) {\n int state = plotter.getState();\n switch(state) {\n case 0:\n background(33, 134, 248, 100);\n break;\n case 1:\n background(254, 26, 26, 100);\n break;\n case 2:\n background(28, 247, 12, 100);\n break;\n default:\n background(100);\n }\n } else {\n background(100);\n }\n\n // Draw the canvas rectangle\n translate(SCREEN_PADDING, SCREEN_PADDING);\n scale(screenScale * plotterScale);\n fill(255); \n rect(0, 0, MAX_PLOTTER_X, MAX_PLOTTER_Y);\n \n // Draw the grid\n if(DRAW_GRID) {\n stroke(210);\n int cols = MAX_PLOTTER_X / 100;\n int rows = MAX_PLOTTER_Y / 100;\n \n for(int i=0; i<cols; i++)\n line(i*100, 0, i*100, MAX_PLOTTER_Y);\n \n for(int i=0; i<rows; i++)\n line(0, i*100, MAX_PLOTTER_X, i*100);\n }\n \n // Draw the homing crosshairs\n strokeWeight(1);\n stroke(150);\n line(MAX_PLOTTER_X/2, 0, MAX_PLOTTER_X/2, MAX_PLOTTER_Y);\n line(0, MAX_PLOTTER_Y/2, MAX_PLOTTER_X, MAX_PLOTTER_Y/2);\n\n translate(dx, dy); \n \n // Draw the bounding box of the current shape\n if(DRAW_BOUNDING_BOX) {\n // Bounding box\n RPoint bounds[] = shape.getBoundsPoints();\n strokeWeight(5);\n stroke(255,0,0);\n line( bounds[0].x, bounds[0].y, bounds[1].x, bounds[1].y );\n line( bounds[1].x, bounds[1].y, bounds[2].x, bounds[2].y );\n line( bounds[2].x, bounds[2].y, bounds[3].x, bounds[3].y );\n line( bounds[3].x, bounds[3].y, bounds[0].x, bounds[0].y );\n \n // Center cross hairs\n RPoint center = shape.getCenter();\n line( center.x, bounds[0].y, center.x, bounds[0].y - 200 );\n line( center.x, bounds[3].y, center.x, bounds[3].y + 200 );\n line( bounds[0].x, center.y, bounds[0].x - 200, center.y );\n line( bounds[1].x, center.y, bounds[1].x + 200, center.y );\n }\n \n // Draw the SVG content\n strokeWeight(STROKE_WEIGHT);\n stroke(0);\n drawShape(shape);\n }",
"public void updateSelection()\n {\n \trectForSelection.setRect(rettangoloX,rettangoloY,larghezza,altezza);\n \trectSelTopLeft.setRect(rettangoloX-3,rettangoloY-3,6,6);\n \trectSelBottomLeft.setRect(rettangoloX-3,rettangoloY+altezza-3,6,6);\n \trectSelTopRight.setRect(rettangoloX+larghezza-3,rettangoloY-3,6,6);\n \trectSelBottomRight.setRect(rettangoloX+larghezza-3,rettangoloY+altezza-3,6,6);\n }",
"public void display()\n\t{\n\t\tfor(Character characher : characterAdded)\n\t\t{\t\n\t\t\tif(!characher.getIsDragging())\n\t\t\t{ \n\t\t\t\t//when dragging, the mouse has the exclusive right of control\n\t\t\t\tcharacher.x = (float)(circleX + Math.cos(Math.PI * 2 * characher.net_index/net_num) * radius);\n\t\t\t\tcharacher.y = (float)(circleY + Math.sin(Math.PI * 2 * characher.net_index/net_num) * radius);\n\t\t\t}\n\t\t}\n\t\t\n\t\t\n\t\tint lineWeight = 0;\n\t\t//draw the line between the characters on the circle\n\t\tif(characterAdded.size() > 0)\n\t\t{\n\t\t\tfor(Character characher : characterAdded)\n\t\t\t{\n\t\t\t\tfor(Character ch : characher.getTargets())\n\t\t\t\t{\n\t\t\t\t\tif(ch.net_index != -1)\n\t\t\t\t\t{\n\t\t\t\t\t\tfor(int i = 0; i < links.size(); i++)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tJSONObject tem = links.getJSONObject(i);\n\t\t\t\t\t\t\tif((tem.getInt(\"source\") == characher.index) && \n\t\t\t\t\t\t\t\t\t\t\t\t(tem.getInt(\"target\") == ch.index))\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tlineWeight = tem.getInt(\"value\");\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\tparent.strokeWeight(lineWeight/4 + 1);\t\t\n\t\t\t\t\t\tparent.noFill();\n\t\t\t\t\t\tparent.stroke(0);\n\t\t\t\t\t\tparent.line(characher.x, characher.y, ch.x, ch.y);\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}",
"private void drawWalls(Graphics g) {\n\t\tfor(int i=0; i<grid.length; i++){\n\t\t\tfor(int j=0; j<grid[0].length; j++){\n\t\t\t\tif(grid[i][j].getNorth()!=null) {\n\t\t\t\t\tg.setColor(Color.decode(\"#CC3300\"));//Brown\n\t\t\t\t\tg.drawLine(j*widthBlock+padding+doorX, i*heightBlock+padding, j*widthBlock+padding+doorWidth, i*heightBlock+padding);\n\t\t\t\t}else {\n\t\t\t\t\tg.setColor(Color.BLACK);\n\t\t\t\t\tg.drawLine(j*widthBlock+padding, i*heightBlock+padding, j*widthBlock+padding+widthBlock, i*heightBlock+padding);\n\t\t\t\t}\n\t\t\t\tif(grid[i][j].getEast()!=null) {\n\t\t\t\t\tg.setColor(Color.decode(\"#CC3300\"));//Brown\n\t\t\t\t\tg.drawLine((j+1)*widthBlock+padding, i*heightBlock+padding+doorX, (j+1)*widthBlock+padding, i*heightBlock+padding+doorWidth);\n\t\t\t\t}else {\n\t\t\t\t\tg.setColor(Color.BLACK);\n\t\t\t\t\tg.drawLine((j+1)*widthBlock+padding, i*heightBlock+padding, (j+1)*widthBlock+padding, (i+1)*heightBlock+padding);\n\t\t\t\t}\n\t\t\t\tif(grid[i][j].getSouth()!=null) {\n\t\t\t\t\tg.setColor(Color.decode(\"#CC3300\"));//Brown\n\t\t\t\t\tg.drawLine(j*widthBlock+padding+doorX, (i+1)*heightBlock+padding, j*widthBlock+padding+doorWidth, (i+1)*heightBlock+padding);\n\t\t\t\t}else {\n\t\t\t\t\tg.setColor(Color.BLACK);\n\t\t\t\t\tg.drawLine(j*widthBlock+padding, (i+1)*heightBlock+padding, (j+1)*widthBlock+padding, (i+1)*heightBlock+padding);\n\t\t\t\t}\n\t\t\t\tif(grid[i][j].getWest()!=null) {\n\t\t\t\t\tg.setColor(Color.decode(\"#CC3300\"));//Brown\n\t\t\t\t\tg.drawLine(j*widthBlock+padding, i*heightBlock+padding+doorX, j*widthBlock+padding, i*heightBlock+padding+doorWidth);\n\t\t\t\t}else {\n\t\t\t\t\tg.setColor(Color.BLACK);\n\t\t\t\t\tg.drawLine(j*widthBlock+padding, i*heightBlock+padding, j*widthBlock+padding, (i+1)*heightBlock+padding);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}",
"public void recordWaypoints(){\n\t\t\n\t\tfor (int i = 0; i < waypoints.size(); i++) {\n WayPoint wei = waypoints.get(i);\n int x = (int)Math.round((wei.getX() * scale) + width/2);\n int y = (int)Math.round((wei.getY() * scale) + height/2);\n g2d.setColor(Color.blue);\n g2d.fillRect(x,y,4,4);\n\t\t\t\t\t \n //System.out.println(x + \" \" + y);\n }\n\t}",
"public void displayRectangles() {\n\n\n int arr[] = IntStream.of(findDuplicates(TricolourController.BloodCells)).distinct().toArray(); //takes only the unique values from the array\n int arrWhite[] = IntStream.of(findDuplicates(TricolourController.WhiteCells)).distinct().toArray();\n int rIndex = 0;\n int lIndex = 0;\n int numCells = 0;\n\n for(int num : arrWhite) {\n System.out.println(num);\n }\n\n for(int j=0; j < arr.length - 1; j++) {\n for (int i = 0; i < TricolourController.BloodCells.length; i++) {\n if (TricolourController.BloodCells[i] == arr[j]) {\n int x = i % width, y = i / width;\n if (r[rIndex] == null) {\n r[rIndex] = new Rectangle(x, y, 1, 1);\n numCells++;\n }\n else {\n if (x > r[rIndex].getX() + r[rIndex].getWidth()) r[rIndex].setWidth(x - r[rIndex].getX());\n if (x < r[rIndex].getX()) {\n r[rIndex].setWidth(r[rIndex].getX() + r[rIndex].getWidth() - x);\n r[rIndex].setX(x);\n }\n if (y > r[rIndex].getY() + r[rIndex].getHeight()) r[rIndex].setHeight(y - r[rIndex].getY());\n }\n }\n }\n if (r[rIndex] != null) {\n r[rIndex].setFill(Color.TRANSPARENT);\n if(r[rIndex].getWidth() * r[rIndex].getHeight() > 2500) {\n r[rIndex].setStroke(Color.BLUE);\n }\n else r[rIndex].setStroke(Color.DARKGREEN);\n\n r[rIndex].setTranslateX(ImageViewTri.getLayoutX());\n r[rIndex].setTranslateY(ImageViewTri.getLayoutY());\n ((Pane) ImageViewTri.getParent()).getChildren().add(r[rIndex++]);\n RedCellText.setText(String.valueOf(numCells));\n }\n l[lIndex] = new Label();\n l[lIndex].setText(String.valueOf(numCells));\n l[lIndex].setTextFill(Color.BLACK);\n l[lIndex].setTranslateX(r[rIndex - 1].getX());\n l[lIndex].setTranslateY(r[rIndex - 1].getY());\n\n ((Pane) ImageViewTri.getParent()).getChildren().add(l[lIndex++]);\n }\n\n//Handles the white cell rectangles.\n int whitenumcells = 0;\n for(int j=0; j < arrWhite.length - 1; j++) {\n for (int i = 0; i < TricolourController.WhiteCells.length; i++) {\n if (TricolourController.WhiteCells[i] == arrWhite[j]) {\n int x = i % width, y = i / width;\n if (r[rIndex] == null) {\n r[rIndex] = new Rectangle(x, y, 1, 1);\n whitenumcells++;\n }\n else {\n if (x > r[rIndex].getX() + r[rIndex].getWidth()) r[rIndex].setWidth(x - r[rIndex].getX());\n if (x < r[rIndex].getX()) {\n r[rIndex].setWidth(r[rIndex].getX() + r[rIndex].getWidth() - x);\n r[rIndex].setX(x);\n }\n if (y > r[rIndex].getY() + r[rIndex].getHeight()) r[rIndex].setHeight(y - r[rIndex].getY());\n }\n }\n }\n if (r[rIndex] != null) {\n r[rIndex].setFill(Color.TRANSPARENT);\n r[rIndex].setStroke(Color.YELLOW);\n\n r[rIndex].setTranslateX(ImageViewTri.getLayoutX());\n r[rIndex].setTranslateY(ImageViewTri.getLayoutY());\n ((Pane) ImageViewTri.getParent()).getChildren().add(r[rIndex++]);\n WhiteCellText.setText(String.valueOf(whitenumcells));\n }\n l[lIndex] = new Label();\n l[lIndex].setText(String.valueOf(whitenumcells));\n l[lIndex].setTextFill(Color.BLACK);\n l[lIndex].setTranslateX(r[rIndex - 1].getX());\n l[lIndex].setTranslateY(r[rIndex - 1].getY());\n\n ((Pane) ImageViewTri.getParent()).getChildren().add(l[lIndex++]);\n }\n }",
"public void drawControlPolygon() {\n\t\t//this.frame.stroke(255, 0, 0);\n\t\tfor(int i=0;i<points.length;i++) {\n\t\t\tfor(int j=0;j<points[i].length;j++)\n\t\t\t\tthis.frame.drawVertex(points[i][j]);\n\t\t}\n\t}",
"private void draw(){\n GraphicsContext gc = canvasArea.getGraphicsContext2D();\n canvasDrawer.drawBoard(canvasArea, board, gc, currentCellColor, currentBackgroundColor, gridToggle);\n }",
"public void transport() \n{\n textSize(15);\n fill(0, 102, 153);\n text(\"Transport\", lx-10, ly+50);\n\n for (int i = 0; i < 7; i++) //draw the legend\n {\n stroke(0, 100);\n if (tm[i] == true) //if the transport is unselected, nofill\n {\n noFill();\n } \n else\n {\n fill(color(colorset[3*i], colorset[3*i+1], colorset[3*i+2]));\n }\n rect(lx, ly+65+2*i*bl, bw, bl); \n fill(0, 102, 153);\n text(transportm[i], lx+40, ly+75+2*i*bl+bl/3);\n }\n}",
"public void uk(){\n stroke(1);\n //back guns\n fill(0);\n rect(73,192,4,15);\n rect(224,192,4,15);\n rect(71,207,8,15);\n rect(222,207,8,15);\n rect(66,207,3,15);\n rect(232,207,3,17);\n rect(122,109,4,15);\n rect(175,110,4,15);\n rect(121,120,6,15);\n rect(174,120,6,15);\n rect(116,124,3,15);\n rect(182,124,3,15);\n\n //wings--england\n fill(1,0,74);//dark blue\n beginShape();\n vertex(14,286);\n vertex(61,236);\n vertex(88,308);\n vertex(51,334);\n vertex(14,313);\n endShape(CLOSE);\n beginShape();\n vertex(286,287);\n vertex(286,312);\n vertex(247,335);\n vertex(212,309);\n vertex(238,238);\n endShape(CLOSE);\n\n noStroke();\n fill(255);\n rect(15,286,74,20);\n rect(212,284,74,20);\n rect(48,248,20,74);\n rect(233,248,20,74);\n quad(26,272,35,260,83,312,72,320);\n quad(262,260,272,272,229,312,220,318);\n quad(25,318,38,328,85,278,75,263);\n quad(264,324,280,316,228,262,214,274);\n\n fill(207,20,43);\n rect(51,248,15,74);\n rect(235,247,15,74);\n rect(15,289,74,15);\n rect(211,286,74,15);\n\n stroke(1);\n fill(0);//white\n beginShape();\n vertex(38,307);\n vertex(74,307);\n vertex(80,314);\n vertex(81,337);\n vertex(68,345);\n vertex(38,327);\n endShape(CLOSE);\n beginShape();\n vertex(219,316);\n vertex(226,308);\n vertex(262,308);\n vertex(262,326);\n vertex(231,345);\n vertex(219,336);\n endShape(CLOSE);\n\n fill(0,36,125);//red\n beginShape();\n vertex(96,191);\n vertex(61,230);\n vertex(60,269);\n vertex(96,312);\n vertex(101,300);\n vertex(100,247);\n vertex(112,232);\n vertex(132,232);\n vertex(131,186);\n endShape(CLOSE);\n beginShape();\n vertex(204,191);\n vertex(240,230);\n vertex(240,270);\n vertex(205,312);\n vertex(200,302);\n vertex(200,248);\n vertex(193,238);\n vertex(185,231);\n vertex(170,230);\n vertex(170,186);\n endShape(CLOSE);\n\n //gray\n fill(200);\n beginShape();\n vertex(70,217);\n vertex(74,220);\n vertex(81,210);\n vertex(85,213);\n vertex(75,227);\n vertex(72,229);\n vertex(71,231);\n vertex(73,233);\n vertex(73,268);\n vertex(71,272);\n vertex(76,277);\n vertex(82,274);\n vertex(89,283);\n vertex(90,297);\n vertex(66,272);\n vertex(65,235);\n vertex(68,229);\n vertex(62,228);\n endShape(CLOSE);\n beginShape();\n vertex(228,217);\n vertex(225,218);\n vertex(218,211);\n vertex(215,213);\n vertex(223,227);\n vertex(226,226);\n vertex(230,230);\n vertex(227,233);\n vertex(228,270);\n vertex(229,272);\n vertex(223,276);\n vertex(218,276);\n vertex(210,283);\n vertex(211,296);\n vertex(235,273);\n vertex(234,233);\n vertex(232,228);\n vertex(237,227);\n endShape(CLOSE);\n\n //guns\n //white\n fill(200);\n beginShape();\n vertex(121,301);\n vertex(98,313);\n vertex(102,336);\n vertex(119,342);\n vertex(139,336);\n vertex(141,313);\n endShape(CLOSE);//l\n beginShape();\n vertex(159,312);\n vertex(162,336);\n vertex(180,342);\n vertex(200,336);\n vertex(202,313);\n vertex(180,302);\n endShape(CLOSE);\n\n //black\n fill(0);\n rect(105,315,30,30);\n rect(166,315,30,30);\n quad(105,344,109,355,131,355,135,344);\n quad(166,344,170,355,192,355,196,344);\n\n fill(207,20,43);\n rect(103,253,33,62);//l\n rect(164,252,33,62);//r\n\n fill(200);\n bezier(103,252,107,230,132,230,136,252);//l\n bezier(164,252,169,230,192,230,197,252);//r\n rect(103,280,33,25);//l\n rect(164,280,33,25);//r\n fill(0,36,125);\n rect(104,319,33,26,3);//l\n rect(165,319,33,26,3);//r\n fill(200);\n rect(115,310,7,28,8);//l\n rect(178,310,7,28,8);//r\n\n fill(0,0,67);\n rect(105,284,10,15);\n rect(124,284,10,15);\n rect(167,285,10,15);\n rect(185,284,10,15);\n\n //body-wings\n\n fill(0,0,67);//blue\n bezier(107,154,101,162,98,169,98,187);\n bezier(191,153,199,164,202,172,203,187);\n quad(107,154,98,186,98,223,107,224);\n quad(191,153,203,186,202,223,192,223);\n fill(0,36,125);//red\n quad(134,112,108,147,107,239,132,230);\n quad(165,112,192,147,193,239,168,230);\n //black\n fill(0);\n quad(130,122,130,142,111,164,111,147);\n quad(169,122,188,147,188,165,169,144);\n //white\n fill(200);\n beginShape();\n vertex(131,154);\n vertex(129,202);\n vertex(118,202);\n vertex(112,181);\n vertex(110,179);\n vertex(110,171);\n endShape(CLOSE);\n beginShape();\n vertex(170,154);\n vertex(190,172);\n vertex(190,182);\n vertex(188,181);\n vertex(182,201);\n vertex(172,201);\n endShape(CLOSE);\n\n\n fill(0,36,125);\n quad(134,193,166,193,154,342,146,342);\n fill(192,0,11);\n quad(142,180,159,180,152,352,148,352);\n //white\n fill(200);\n ellipse(150,374,6,50);\n\n //head\n\n fill(1,1,75);\n ellipse(149.5f,72,33,25);\n ellipse(149.5f,94,30,170);\n fill(0);\n ellipse(149.5f,94,20,160);\n fill(154,155,84);\n ellipse(149.5f,94,17,77);\n strokeWeight(2);\n line(143,74,158,74);\n line(142,104,158,104);\n strokeWeight(1);\n fill(200);\n bezier(143,15,147,2,153,2,155.5f,15);\n}",
"@Override\n\tvoid draw(Graphics g) {\n\t\tg.setColor(needsHighlight() ? selectColor : Color.GRAY);\n\t\tsetBbox(x, y, x2, y2);\n\t\tif (x < x2 && y < y2)\n\t\t\tg.fillRect(x, y, x2 - x, y2 - y);\n\t\telse if (x > x2 && y < y2)\n\t\t\tg.fillRect(x2, y, x - x2, y2 - y);\n\t\telse if (x < x2 && y > y2)\n\t\t\tg.fillRect(x, y2, x2 - x, y - y2);\n\t\telse\n\t\t\tg.fillRect(x2, y2, x - x2, y - y2);\n\t}",
"@Override\n\tprotected void paintComponent(Graphics g) {\n\t\tsuper.paintComponent(g);\n\t\tint size, x, y;\n\t\tif (this.getHeight() < this.getWidth()) {\n\t\t\tsize = (int) (this.getHeight() / 1.5);\n\t\t} else {\n\t\t\tsize = (int) (this.getWidth() / 1.5);\n\t\t}\n\t\tx = (int) ((this.getWidth() / 2.0) - size / 2.0);\n\t\ty = (int) ((this.getHeight() / 2.0) - size / 2.0);\n\t\tint eyesize = (int) (size / 8.0);\n\t\tint eyex = (int) (x + size * 0.3 - eyesize / 2.0);\n\t\tint eyey = (int) (y + size * 0.4 - eyesize / 2.0);\n\t\tint eyex2 = (int) (x + size * 0.7 - eyesize / 2.0);\n\t\tint[] xpoints = {x, x + size, (int) (x + size / 2.0)};\n\t\tint[] ypoints = {(int) (y + size / 5.0), (int) (y + size / 5.0),\n\t\t\t\t(int) (y - size / 10.0)};\n\t\tPolygon hat = new Polygon(xpoints, ypoints, 3);\n\t\t\n\t\tif (zustand >0) {\n\t\t\tg.setColor(Color.GREEN);\n\t\t\tg.fillOval(x, y, size, size);\n\t\t\tg.setColor(Color.BLACK);\n\t\t\tg.fillOval(eyex, eyey, eyesize, eyesize);\n\t\t\tg.fillOval(eyex2, eyey, eyesize, eyesize);\n\t\t\tg.fillPolygon(hat);\n\t\t\tg.fillArc((int) (x + size / 5.0), (int) (y + size * 0.5),\n\t\t\t\t\t(int) (size * 0.6), (int) (size * 0.4), 0, -180);\n\t\t} else if (zustand == 0) {\n\t\t\tg.setColor(Color.YELLOW);\n\t\t\tg.fillOval(x, y, size, size);\n\t\t\tg.setColor(Color.BLACK);\n\t\t\tg.fillOval(eyex, eyey, eyesize, eyesize);\n\t\t\tg.fillOval(eyex2, eyey, eyesize, eyesize);\n\t\t\tg.fillPolygon(hat);\n\t\t\tg.fillRect(eyex, (int) (y + size * 0.75), eyex2 + eyesize - eyex,\n\t\t\t\t\t(int) (eyesize / 2.0));\n\t\t} else {\n\t\t\tg.setColor(Color.RED);\n\t\t\tg.fillOval(x, y, size, size);\n\t\t\tg.setColor(Color.BLACK);\n\t\t\tg.fillOval(eyex, eyey, eyesize, eyesize);\n\t\t\tg.fillOval(eyex2, eyey, eyesize, eyesize);\n\t\t\tg.fillPolygon(hat);\n\t\t\tg.fillArc((int) (x + size / 5.0), (int) (y + size * 0.6),\n\t\t\t\t\t(int) (size * 0.6), (int) (size * 0.4), 0, 180);\n\t\t}\n\t}",
"private void render() {\n\t\ttheMap.draw(g);\n\t\ttheTrainer.draw(g);\n\t}",
"public void med1() {\n DrawingPanel win = new DrawingPanel(WIDTH, HEIGHT);\n java.awt.Graphics g = win.getGraphics();\n win.setTitle(\"Med. 1\");\n win.setLocation(300, 10);\n win.setBackground(java.awt.Color.red);\n for(int y = -10; y < HEIGHT; y += 24) {\n for(int x = -10; x < WIDTH; x += 24) {\n octagon(x, y, g);\n }\n }\n }",
"@Override\n public void paint(Graphics g) {\n g2 = (Graphics2D) g;\n drawBackground();\n drawSquares();\n drawLines();\n gui.hint = new TreeSet<>();\n }",
"@Override\n protected void buildGraphics() {\n GArc rightWing = new GArc(100, 100, -60, 120);\n rightWing.setColor(Color.magenta);\n rightWing.setFilled(true);\n rightWing.setFillColor(Color.magenta);\n // position in format (cx - r, cy - r) for arc\n getGraphics().add(rightWing, (-15 - 50), (0 - 50));\n\n GArc leftWing = new GArc(100, 100, 120, 120);\n leftWing.setColor(Color.magenta);\n leftWing.setFilled(true);\n leftWing.setFillColor(Color.magenta);\n getGraphics().add(leftWing, (-15 - 50), (0 - 50));\n\n GOval rightWingDot = new GOval(-3, -15, 30, 30);\n rightWingDot.setColor(Color.blue);\n rightWingDot.setFilled(true);\n rightWingDot.setFillColor(Color.blue);\n getGraphics().add(rightWingDot);\n\n GOval rightWingDot2 = new GOval(7, -5, 10, 10);\n rightWingDot2.setColor(Color.cyan);\n rightWingDot2.setFilled(true);\n rightWingDot2.setFillColor(Color.cyan);\n getGraphics().add(rightWingDot2);\n\n GLine rightWingLine = new GLine(-15, 0, 35, 0);\n rightWingLine.setColor(Color.green);\n getGraphics().add(rightWingLine);\n\n GOval leftWingDot = new GOval(-57, -15, 30, 30);\n leftWingDot.setColor(Color.blue);\n leftWingDot.setFilled(true);\n leftWingDot.setFillColor(Color.blue);\n getGraphics().add(leftWingDot);\n\n GOval leftWingDot2 = new GOval(-47, -5, 10, 10);\n leftWingDot2.setColor(Color.cyan);\n leftWingDot2.setFilled(true);\n leftWingDot2.setFillColor(Color.cyan);\n getGraphics().add(leftWingDot2);\n\n GLine leftWingLine = new GLine(-15, 0, -65, 0);\n leftWingLine.setColor(Color.green);\n getGraphics().add(leftWingLine);\n\n GOval body = new GOval(-20, -30, 10, 60);\n body.setColor(Color.black);\n body.setFilled(true);\n body.setFillColor(Color.black);\n getGraphics().add(body);\n\n GOval head = new GOval(-23, -43, 16, 16);\n head.setColor(Color.black);\n head.setFilled(true);\n head.setFillColor(Color.black);\n getGraphics().add(head);\n }",
"private void drawRunway(Graphics2D g2){\n\t\t// Get the start and end X.\n\t\tint startX = Math.min(toScaledX(0), toScaledX(getDefaultTORA()));\n\t\tint endX = Math.max(toScaledX(0), toScaledX(getDefaultTORA()));\n\t\t// Create the rectangle shape.\n\t\tRectangle run = new Rectangle\n\t\t\t\t(\t\n\t\t\t\t\t\tstartX,\t\t// x coordinate \n\t\t\t\t\t\ttoScaledY(0) , // y coordinate\n\t\t\t\t\t\tendX-startX, //width of runway\n\t\t\t\t\t\tverticalRunwayHeight\n\t\t\t\t);\n\t\t// Draw the runway area.\n\t\tif( isUsingTextures() ){\n\t\t\tg2.setPaint( tarmacTexture );\n\t\t}else{\n\t\t\tg2.setPaint( ColourSchema.tarmac );\n\t\t}\n\t\tg2.fill(run);\n\t\t\n\t\t// Draw the stopway in the current direction.\n\t\tfloat facing_stopway_length = getFacingStopway();\n\t\tRectangle facing_stopway = new Rectangle(\n\t\t\t\t\tendX,\n\t\t\t\t\ttoScaledY(0) , // y coordinate\n\t\t\t\t\tscaleAbsX(facing_stopway_length), //width of runway\n\t\t\t\t\tverticalRunwayHeight-5 //height of runway\t\n\t\t);\n\t\tif( isUsingTextures() ){\n\t\t\tg2.setPaint( stopwayTexture );\n\t\t}else{\n\t\t\tg2.setPaint(ColourSchema.stopway);\n\t\t}\n\t\tg2.fill(facing_stopway);\n\t\t\n\t\t// Draw the stopway in the opposite direction.\n\t\tfloat opposite_stopway_length = getOppositeDirectionStopway();\n\t\tRectangle opposite_stopway = new Rectangle(\n\t\t\t\t\tstartX-scaleAbsX(opposite_stopway_length),\n\t\t\t\t\ttoScaledY(0), // y coordinate\n\t\t\t\t\tscaleAbsX(opposite_stopway_length), //width of runway\n\t\t\t\t\tverticalRunwayHeight-5 //height of runway\t\n\t\t);\n\t\tif( isUsingTextures() ){\n\t\t\tg2.setPaint( stopwayTexture );\n\t\t}else{\n\t\t\tg2.setPaint(ColourSchema.stopway);\n\t\t}\n\t\tg2.fill(opposite_stopway);\n\t}",
"public void russia(){\n stroke(1);\n //back guns\n fill(0);\n rect(73,192,4,15);\n rect(224,192,4,15);\n rect(71,207,8,15);\n rect(222,207,8,15);\n rect(66,207,3,15);\n rect(232,207,3,17);\n rect(122,109,4,15);\n rect(175,110,4,15);\n rect(121,120,6,15);\n rect(174,120,6,15);\n rect(116,124,3,15);\n rect(182,124,3,15);\n\n //wings\n fill(165,0,0);//gray\n beginShape();\n vertex(14,286);\n vertex(61,236);\n vertex(88,308);\n vertex(51,334);\n vertex(14,313);\n endShape(CLOSE);\n beginShape();\n vertex(286,287);\n vertex(286,312);\n vertex(247,335);\n vertex(212,309);\n vertex(238,238);\n endShape(CLOSE);\n\n fill(0);//black\n beginShape();\n vertex(38,307);\n vertex(74,307);\n vertex(80,314);\n vertex(81,337);\n vertex(68,345);\n vertex(38,327);\n endShape(CLOSE);\n beginShape();\n vertex(219,316);\n vertex(226,308);\n vertex(262,308);\n vertex(262,326);\n vertex(231,345);\n vertex(219,336);\n endShape(CLOSE);\n\n fill(18,39,148);//blue\n beginShape();\n vertex(96,191);\n vertex(61,230);\n vertex(60,269);\n vertex(96,312);\n vertex(101,300);\n vertex(100,247);\n vertex(112,232);\n vertex(132,232);\n vertex(131,186);\n endShape(CLOSE);\n beginShape();\n vertex(204,191);\n vertex(240,230);\n vertex(240,270);\n vertex(205,312);\n vertex(200,302);\n vertex(200,248);\n vertex(193,238);\n vertex(185,231);\n vertex(170,230);\n vertex(170,186);\n endShape(CLOSE);\n\n //white\n fill(200);\n beginShape();\n vertex(70,217);\n vertex(74,220);\n vertex(81,210);\n vertex(85,213);\n vertex(75,227);\n vertex(72,229);\n vertex(71,231);\n vertex(73,233);\n vertex(73,268);\n vertex(71,272);\n vertex(76,277);\n vertex(82,274);\n vertex(89,283);\n vertex(90,297);\n vertex(66,272);\n vertex(65,235);\n vertex(68,229);\n vertex(62,228);\n endShape(CLOSE);\n beginShape();\n vertex(228,217);\n vertex(225,218);\n vertex(218,211);\n vertex(215,213);\n vertex(223,227);\n vertex(226,226);\n vertex(230,230);\n vertex(227,233);\n vertex(228,270);\n vertex(229,272);\n vertex(223,276);\n vertex(218,276);\n vertex(210,283);\n vertex(211,296);\n vertex(235,273);\n vertex(234,233);\n vertex(232,228);\n vertex(237,227);\n endShape(CLOSE);\n\n //guns\n //red\n fill(194,24,11);\n beginShape();\n vertex(121,301);\n vertex(98,313);\n vertex(102,336);\n vertex(119,342);\n vertex(139,336);\n vertex(141,313);\n endShape(CLOSE);//l\n beginShape();\n vertex(159,312);\n vertex(162,336);\n vertex(180,342);\n vertex(200,336);\n vertex(202,313);\n vertex(180,302);\n endShape(CLOSE);\n\n //black\n fill(0);\n rect(105,315,30,30);\n rect(166,315,30,30);\n quad(105,344,109,355,131,355,135,344);\n quad(166,344,170,355,192,355,196,344);\n\n rect(103,253,33,62);//l\n rect(164,252,33,62);//r\n //white\n fill(200);\n bezier(103,252,107,230,132,230,136,252);//l\n bezier(164,252,169,230,192,230,197,252);//r\n\n rect(103,280,33,25);//l\n rect(164,280,33,25);//r\n rect(104,319,33,26,3);//l\n rect(165,319,33,26,3);//r\n fill(194,24,11);\n rect(115,310,7,28,8);//l\n rect(178,310,7,28,8);//r\n\n fill(194,24,11);\n rect(105,284,10,15);\n rect(124,284,10,15);\n rect(167,285,10,15);\n rect(185,284,10,15);\n\n //body-wings\n\n fill(0,0,67);//blue\n bezier(107,154,101,162,98,169,98,187);\n bezier(191,153,199,164,202,172,203,187);\n quad(107,154,98,186,98,223,107,224);\n quad(191,153,203,186,202,223,192,223);\n fill(192,0,11);//red\n quad(134,112,108,147,107,239,132,230);\n quad(165,112,192,147,193,239,168,230);\n //black\n fill(0);\n quad(130,122,130,142,111,164,111,147);\n quad(169,122,188,147,188,165,169,144);\n //white\n fill(200);\n beginShape();\n vertex(131,154);\n vertex(129,202);\n vertex(118,202);\n vertex(112,181);\n vertex(110,179);\n vertex(110,171);\n endShape(CLOSE);\n beginShape();\n vertex(170,154);\n vertex(190,172);\n vertex(190,182);\n vertex(188,181);\n vertex(182,201);\n vertex(172,201);\n endShape(CLOSE);\n\n fill(0);\n quad(134,193,166,193,154,342,146,342);\n fill(192,0,11);\n quad(142,180,159,180,152,352,148,352);\n //white\n fill(200);\n ellipse(150,374,6,50);\n\n //head\n fill(160,0,0);\n ellipse(149.5f,72,33,25);\n ellipse(149.5f,94,30,170);\n fill(0);\n ellipse(149.5f,94,20,160);\n fill(154,155,84);\n ellipse(149.5f,94,17,77);\n strokeWeight(2);\n line(143,74,158,74);\n line(142,104,158,104);\n strokeWeight(1);\n fill(200);\n bezier(143,15,147,2,153,2,155.5f,15);\n}",
"@Override\r\n public final void draw(final Triangle t, final BufferedImage paper) {\n String red;\r\n String green;\r\n String blue;\r\n if (Integer.toHexString(t.getBorderColor().getRed()).length() == 1) {\r\n red = \"0\" + Integer.toHexString(t.getBorderColor().getRed());\r\n } else {\r\n red = Integer.toHexString(t.getBorderColor().getRed());\r\n }\r\n if (Integer.toHexString(t.getBorderColor().getGreen()).length() == 1) {\r\n green = \"0\" + Integer.toHexString(t.getBorderColor().getGreen());\r\n } else {\r\n green = Integer.toHexString(t.getBorderColor().getGreen());\r\n }\r\n if (Integer.toHexString(t.getBorderColor().getBlue()).length() == 1) {\r\n blue = \"0\" + Integer.toHexString(t.getBorderColor().getBlue());\r\n } else {\r\n blue = Integer.toHexString(t.getBorderColor().getBlue());\r\n }\r\n String color = \"#\" + red + green + blue;\r\n draw(new Line((String.valueOf(t.getX1())), String.valueOf(t.getY1()),\r\n String.valueOf(t.getX2()), String.valueOf(t.getY2()), color,\r\n String.valueOf(t.getBorderColor().getAlpha()), paper), paper);\r\n\r\n draw(new Line((String.valueOf(t.getX2())), String.valueOf(t.getY2()),\r\n String.valueOf(t.getX3()), String.valueOf(t.getY3()), color,\r\n String.valueOf(t.getBorderColor().getAlpha()), paper), paper);\r\n\r\n draw(new Line((String.valueOf(t.getX3())), String.valueOf(t.getY3()),\r\n String.valueOf(t.getX1()), String.valueOf(t.getY1()), color,\r\n String.valueOf(t.getBorderColor().getAlpha()), paper), paper);\r\n final int trei = 3;\r\n int xc = (t.getX1() + t.getX2() + t.getX3()) / trei;\r\n int yc = (t.getY1() + t.getY2() + t.getY3()) / trei;\r\n floodFill(xc, yc, t.getFillColor(), t.getBorderColor(), paper);\r\n\r\n }",
"static void draw()\n {\n for (Viewport viewport : viewports)\n viewport.draw(renderers);\n }",
"@Override\r\n public void actionPerformed(ActionEvent e) {\n progress_stack = progress_stack_bkup;\r\n\r\n rec_points = rec_points_bkup;\r\n rec_colors = rec_colors_bkup;\r\n\r\n squ_points = squ_points_bkup;\r\n squ_colors = squ_colors_bkup;\r\n\r\n ell_points = ell_points_bkup;\r\n ell_colors = ell_colors_bkup;\r\n\r\n cir_points = cir_points_bkup;\r\n cir_colors = cir_colors_bkup;\r\n\r\n str_points = str_points_bkup;\r\n str_colors = str_colors_bkup;\r\n\r\n poly_points = poly_points_bkup;\r\n poly_colors = poly_colors_bkup;\r\n\r\n handdraw_points = handdraw_points_bkup;\r\n handdraw_colors = handdraw_colors_bkup;\r\n\r\n\r\n if(rec_colors.size()>0){\r\n repaint_shapes(\"rec\", rec_colors, rec_points);\r\n }\r\n\r\n //repaint circle\r\n if(cir_colors.size()>0){\r\n repaint_shapes(\"cir\", cir_colors, cir_points);\r\n }\r\n\r\n //repaint square\r\n if(squ_colors.size()>0){\r\n repaint_shapes(\"squ\", squ_colors, squ_points);\r\n }\r\n\r\n //repaint ellipse\r\n if(ell_colors.size()>0){\r\n repaint_shapes(\"ell\", ell_colors, ell_points);\r\n }\r\n\r\n //repaint straight line\r\n if(str_colors.size()>0){\r\n repaint_shapes(\"str\", str_colors, str_points);\r\n }\r\n\r\n //repaint polygons\r\n if(poly_colors.size()>0){\r\n //polygon repaint\r\n ArrayList<Integer> separate_index = get_separate_index(poly_points);\r\n ArrayList<Integer> points = new ArrayList<Integer>();\r\n\r\n //other shapes\r\n for (int j = 0; j < separate_index.size()-1; j++) {\r\n Color polygon_color = poly_colors.get(j);\r\n //each shape repaint\r\n int begin_index = separate_index.get(j);\r\n int end_index = separate_index.get(j+1);\r\n\r\n //get polygon points arraylist\r\n for (int k = (begin_index+1); k < end_index; k++) {\r\n points.add(poly_points.get(k));\r\n\r\n }\r\n System.out.println(points);\r\n\r\n //repaint one polygon\r\n int line_num = points.size()/2 - 1 ;\r\n for (int k = 0; k < line_num; k++) {\r\n int begin_point = k*2;\r\n x1 = points.get(begin_point);\r\n y1 = points.get(begin_point + 1);\r\n x2 = points.get(begin_point + 2);\r\n y2 = points.get(begin_point + 3);\r\n\r\n g.setColor(polygon_color);\r\n g.drawLine(x1, y1, x2, y2);\r\n\r\n canvas.repaint();\r\n }\r\n points.clear();\r\n }\r\n\r\n //the last polygon\r\n //get last shape points arraylist\r\n int index = separate_index.get(separate_index.size()-1);\r\n for (int j = index+1; j < poly_points.size(); j++) {\r\n points.add(poly_points.get(j));\r\n }\r\n System.out.println(points);\r\n //using points to repaint polygon\r\n int line_num = points.size()/2 - 1 ;\r\n for (int j = 0; j < line_num; j++) {\r\n int begin_point = j*2;\r\n x1 = points.get(begin_point);\r\n y1 = points.get(begin_point + 1);\r\n x2 = points.get(begin_point + 2);\r\n y2 = points.get(begin_point + 3);\r\n\r\n g.setColor(poly_colors.get(poly_colors.size()-1));\r\n g.drawLine(x1, y1, x2, y2);\r\n\r\n canvas.repaint();\r\n\r\n }\r\n }\r\n\r\n //repaint freehand lines\r\n if(handdraw_colors.size()>0){\r\n //repaint all handdraw\r\n ArrayList<Integer> separate_index = get_separate_index(handdraw_points);\r\n ArrayList<Integer> points = new ArrayList<Integer>();\r\n for (int i = 0; i < handdraw_colors.size(); i++) {\r\n //each handdraw\r\n //take all points in one draw\r\n if(i == 0){\r\n //first draw\r\n int begin_index = 0;\r\n int end_index = separate_index.get(i);\r\n //get all points in first drawing\r\n for (int j = begin_index; j < end_index; j++) {\r\n points.add(handdraw_points.get(j));\r\n }\r\n //repaint first drawing\r\n System.out.println(points);\r\n\r\n int line_num = points.size()/2 - 1;\r\n for (int j = 0; j < line_num; j++) {\r\n //draw each short line\r\n begin_index = j*2;\r\n\r\n x1 = points.get(begin_index);\r\n y1 = points.get(begin_index + 1);\r\n x2 = points.get(begin_index + 2);\r\n y2 = points.get(begin_index + 3);\r\n\r\n g.setColor(handdraw_colors.get(i));\r\n g.drawLine(x1, y1, x2, y2);\r\n\r\n canvas.repaint();\r\n\r\n }\r\n points.clear();\r\n\r\n }else{\r\n //draw other handdraws\r\n for (int j = 0; j < handdraw_colors.size()-1; j++) {\r\n //draw each drawing\r\n\r\n int begin_index = separate_index.get(j)+1;\r\n int end_index = separate_index.get(j+1);\r\n //get all points in one drawing\r\n for (int k = begin_index; k < end_index; k++) {\r\n points.add(handdraw_points.get(k));\r\n }\r\n System.out.println(points);\r\n\r\n //repaint drawing\r\n int line_num = points.size()/2 - 1;\r\n for (int k = 0; k < line_num; k++) {\r\n //each line\r\n begin_index = k*2;\r\n\r\n x1 = points.get(begin_index);\r\n y1 = points.get(begin_index + 1);\r\n x2 = points.get(begin_index + 2);\r\n y2 = points.get(begin_index + 3);\r\n\r\n g.setColor(handdraw_colors.get(i));\r\n g.drawLine(x1, y1, x2, y2);\r\n\r\n canvas.repaint();\r\n\r\n }\r\n\r\n points.clear();\r\n\r\n }\r\n\r\n\r\n }\r\n\r\n }\r\n\r\n }\r\n\r\n }",
"@Override\n public void drawScreen(int n, int n2) {\n void mouseY;\n void mouseX;\n super.drawScreen((int)mouseX, (int)mouseY);\n float[] hsb = Color.RGBtoHSB(this.setting.getValue().getRed(), this.setting.getValue().getGreen(), this.setting.getValue().getBlue(), null);\n Color color = Color.getHSBColor(hsb[0], Float.intBitsToFloat(Float.floatToIntBits(6.4887953f) ^ 0x7F4FA436), Float.intBitsToFloat(Float.floatToIntBits(4.629535f) ^ 0x7F142527));\n Gui.drawRect((int)this.getX(), (int)this.getY(), (int)(this.getX() + this.getWidth()), (int)(this.getY() + 14), (int)new Color(40, 40, 40).getRGB());\n Gui.drawRect((int)(this.getX() + this.getWidth() - 12), (int)(this.getY() + 2), (int)(this.getX() + this.getWidth() - 2), (int)(this.getY() + 12), (int)this.setting.getValue().getRGB());\n RenderUtils.drawOutline(this.getX() + this.getWidth() - 12, this.getY() + 2, this.getX() + this.getWidth() - 2, this.getY() + 12, Float.intBitsToFloat(Float.floatToIntBits(2.7144578f) ^ 0x7F2DB9AD), new Color(20, 20, 20).getRGB());\n if (this.open) {\n Gui.drawRect((int)this.getX(), (int)(this.getY() + 14), (int)(this.getX() + this.getWidth()), (int)(this.getY() + 28), (int)new Color(40, 40, 40).getRGB());\n float i = Float.intBitsToFloat(Float.floatToIntBits(1.3378998E38f) ^ 0x7EC94E07);\n while (i + Float.intBitsToFloat(Float.floatToIntBits(13.8331995f) ^ 0x7EDD54C9) < Float.intBitsToFloat(Float.floatToIntBits(0.07128618f) ^ 0x7F51FE7D)) {\n RenderUtils.drawRecta((float)(this.getX() + 2) + i, this.getY() + 16, Float.intBitsToFloat(Float.floatToIntBits(7.249331f) ^ 0x7F67FA85), Float.intBitsToFloat(Float.floatToIntBits(1.7045807f) ^ 0x7EEA2FB3), Color.getHSBColor(i / Float.intBitsToFloat(Float.floatToIntBits(0.115068644f) ^ 0x7F2BA91C), Float.intBitsToFloat(Float.floatToIntBits(4.3161592f) ^ 0x7F0A1DFA), Float.intBitsToFloat(Float.floatToIntBits(21.075346f) ^ 0x7E289A4F)).getRGB());\n i += Float.intBitsToFloat(Float.floatToIntBits(3.807338f) ^ 0x7E95CD0B);\n }\n RenderUtils.drawOutline(this.getX() + 2, this.getY() + 16, this.getX() + 2 + this.getWidth() - 4, this.getY() + 27, Float.intBitsToFloat(Float.floatToIntBits(2.7503529f) ^ 0x7F3005C8), new Color(0, 0, 0).getRGB());\n RenderUtils.drawRecta((float)(this.getX() + 2) + this.hueWidth, this.getY() + 16, Float.intBitsToFloat(Float.floatToIntBits(5.200255f) ^ 0x7F26687D), Float.intBitsToFloat(Float.floatToIntBits(1.2665411f) ^ 0x7E921E05), new Color(255, 255, 255).getRGB());\n Gui.drawRect((int)this.getX(), (int)(this.getY() + 28), (int)(this.getX() + this.getWidth()), (int)(this.getY() + 42), (int)new Color(40, 40, 40).getRGB());\n RenderUtils.drawSidewaysGradient(this.getX() + 2, this.getY() + 29, this.getWidth() - 4, Float.intBitsToFloat(Float.floatToIntBits(0.19645536f) ^ 0x7F792B98), new Color(255, 255, 255), color, 255, 255);\n RenderUtils.drawOutline(this.getX() + 2, this.getY() + 29, this.getX() + 2 + this.getWidth() - 4, this.getY() + 40, Float.intBitsToFloat(Float.floatToIntBits(103.69628f) ^ 0x7DCF647F), new Color(0, 0, 0).getRGB());\n RenderUtils.drawRecta((float)(this.getX() + 2) + this.satWidth, this.getY() + 29, Float.intBitsToFloat(Float.floatToIntBits(7.3489017f) ^ 0x7F6B2A34), Float.intBitsToFloat(Float.floatToIntBits(0.1948352f) ^ 0x7F7782E1), new Color(255, 255, 255).getRGB());\n Gui.drawRect((int)this.getX(), (int)(this.getY() + 42), (int)(this.getX() + this.getWidth()), (int)(this.getY() + 56), (int)new Color(40, 40, 40).getRGB());\n RenderUtils.drawSidewaysGradient(this.getX() + 2, this.getY() + 42, this.getWidth() - 4, Float.intBitsToFloat(Float.floatToIntBits(1.5246161f) ^ 0x7EF3269F), new Color(0, 0, 0), color, 255, 255);\n RenderUtils.drawOutline(this.getX() + 2, this.getY() + 42, this.getX() + 2 + this.getWidth() - 4, this.getY() + 53, Float.intBitsToFloat(Float.floatToIntBits(3.7803736f) ^ 0x7F71F1A4), new Color(0, 0, 0).getRGB());\n RenderUtils.drawRecta((float)(this.getX() + 2) + this.briWidth, this.getY() + 42, Float.intBitsToFloat(Float.floatToIntBits(8.346171f) ^ 0x7E8589EB), Float.intBitsToFloat(Float.floatToIntBits(0.08925866f) ^ 0x7C86CD3F), new Color(255, 255, 255).getRGB());\n Gui.drawRect((int)this.getX(), (int)(this.getY() + 56), (int)(this.getX() + this.getWidth()), (int)(this.getY() + 70), (int)new Color(40, 40, 40).getRGB());\n this.renderAlphaBG(this.getX() + 2, this.getY() + 55, this.alphaBG);\n RenderUtils.drawSidewaysGradient(this.getX() + 2, this.getY() + 55, this.getWidth() - 4, Float.intBitsToFloat(Float.floatToIntBits(0.13166903f) ^ 0x7F36D43F), new Color(0, 0, 0), color, 0, 255);\n RenderUtils.drawOutline(this.getX() + 2, this.getY() + 55, this.getX() + 2 + this.getWidth() - 4, this.getY() + 66, Float.intBitsToFloat(Float.floatToIntBits(19.69502f) ^ 0x7E9D8F67), new Color(0, 0, 0).getRGB());\n RenderUtils.drawRecta((float)(this.getX() + 2) + this.alphaWidth, this.getY() + 55, Float.intBitsToFloat(Float.floatToIntBits(6.702013f) ^ 0x7F5676E4), Float.intBitsToFloat(Float.floatToIntBits(0.13652846f) ^ 0x7F3BCE1E), new Color(255, 255, 255).getRGB());\n Gui.drawRect((int)this.getX(), (int)(this.getY() + 70), (int)(this.getX() + this.getWidth()), (int)(this.getY() + 84), (int)new Color(40, 40, 40).getRGB());\n Europa.FONT_MANAGER.drawString(\"Rainbow\", this.getX() + 3, (float)(this.getY() + 78) - Europa.FONT_MANAGER.getHeight() / Float.intBitsToFloat(Float.floatToIntBits(0.8730777f) ^ 0x7F5F8205), Color.WHITE);\n Gui.drawRect((int)(this.getX() + this.getWidth() - 12), (int)(this.getY() + 72), (int)(this.getX() + this.getWidth() - 2), (int)(this.getY() + 82), (int)new Color(30, 30, 30).getRGB());\n if (this.setting.getRainbow().booleanValue()) {\n RenderUtils.prepareGL();\n GL11.glShadeModel((int)7425);\n GL11.glEnable((int)2848);\n GL11.glLineWidth((float)Float.intBitsToFloat(Float.floatToIntBits(0.2713932f) ^ 0x7EAAF40D));\n GL11.glBegin((int)1);\n GL11.glColor3f((float)((float)ModuleColor.getActualColor().getRed() / Float.intBitsToFloat(Float.floatToIntBits(0.015137452f) ^ 0x7F070313)), (float)((float)ModuleColor.getActualColor().getGreen() / Float.intBitsToFloat(Float.floatToIntBits(1.1948546f) ^ 0x7CE7F0FF)), (float)((float)ModuleColor.getActualColor().getBlue() / Float.intBitsToFloat(Float.floatToIntBits(0.36357376f) ^ 0x7DC52657)));\n GL11.glVertex2d((double)(this.getX() + this.getWidth() - 8), (double)(this.getY() + 80));\n GL11.glColor3f((float)((float)ModuleColor.getActualColor().getRed() / Float.intBitsToFloat(Float.floatToIntBits(0.015521388f) ^ 0x7F014D6B)), (float)((float)ModuleColor.getActualColor().getGreen() / Float.intBitsToFloat(Float.floatToIntBits(0.01025841f) ^ 0x7F5712E4)), (float)((float)ModuleColor.getActualColor().getBlue() / Float.intBitsToFloat(Float.floatToIntBits(0.10675689f) ^ 0x7EA5A35B)));\n GL11.glVertex2d((double)(this.getX() + this.getWidth() - 8 + 4), (double)(this.getY() + 74));\n GL11.glEnd();\n GL11.glBegin((int)1);\n GL11.glColor3f((float)((float)ModuleColor.getActualColor().getRed() / Float.intBitsToFloat(Float.floatToIntBits(0.009417259f) ^ 0x7F654AD9)), (float)((float)ModuleColor.getActualColor().getGreen() / Float.intBitsToFloat(Float.floatToIntBits(0.07014828f) ^ 0x7EF0A9E7)), (float)((float)ModuleColor.getActualColor().getBlue() / Float.intBitsToFloat(Float.floatToIntBits(0.013465701f) ^ 0x7F239F3E)));\n GL11.glVertex2d((double)(this.getX() + this.getWidth() - 8), (double)(this.getY() + 80));\n GL11.glColor3f((float)((float)ModuleColor.getActualColor().getRed() / Float.intBitsToFloat(Float.floatToIntBits(0.0155056f) ^ 0x7F010B33)), (float)((float)ModuleColor.getActualColor().getGreen() / Float.intBitsToFloat(Float.floatToIntBits(0.011914493f) ^ 0x7F3C3501)), (float)((float)ModuleColor.getActualColor().getBlue() / Float.intBitsToFloat(Float.floatToIntBits(0.012230922f) ^ 0x7F376434)));\n GL11.glVertex2d((double)(this.getX() + this.getWidth() - 10), (double)(this.getY() + 77));\n GL11.glEnd();\n RenderUtils.releaseGL();\n }\n }\n Gui.drawRect((int)(this.getX() - 1), (int)this.getY(), (int)this.getX(), (int)(this.getY() + 84), (int)new Color(30, 30, 30).getRGB());\n Gui.drawRect((int)(this.getX() + this.getWidth()), (int)this.getY(), (int)(this.getX() + this.getWidth() + 1), (int)(this.getY() + 84), (int)new Color(30, 30, 30).getRGB());\n Europa.FONT_MANAGER.drawString(this.setting.getName(), this.getX() + 3, this.getY() + 3, Color.WHITE);\n }",
"public void usa(){\n stroke(1);\n //back guns\n fill(0);\n rect(73,192,4,15);\n rect(224,192,4,15);\n rect(71,207,8,15);\n rect(222,207,8,15);\n rect(66,207,3,15);\n rect(232,207,3,17);\n rect(122,109,4,15);\n rect(175,110,4,15);\n rect(121,120,6,15);\n rect(174,120,6,15);\n rect(116,124,3,15);\n rect(182,124,3,15);\n\n //wings\n fill(1,0,74);//dark blue\n beginShape();\n vertex(14,286);\n vertex(61,236);\n vertex(88,308);\n vertex(51,334);\n vertex(14,313);\n endShape(CLOSE);\n beginShape();\n vertex(286,287);\n vertex(286,312);\n vertex(247,335);\n vertex(212,309);\n vertex(238,238);\n endShape(CLOSE);\n\n fill(200);//white\n beginShape();\n vertex(38,307);\n vertex(74,307);\n vertex(80,314);\n vertex(81,337);\n vertex(68,345);\n vertex(38,327);\n endShape(CLOSE);\n beginShape();\n vertex(219,316);\n vertex(226,308);\n vertex(262,308);\n vertex(262,326);\n vertex(231,345);\n vertex(219,336);\n endShape(CLOSE);\n\n fill(192,0,11);//red\n beginShape();\n vertex(96,191);\n vertex(61,230);\n vertex(60,269);\n vertex(96,312);\n vertex(101,300);\n vertex(100,247);\n vertex(112,232);\n vertex(132,232);\n vertex(131,186);\n endShape(CLOSE);\n beginShape();\n vertex(204,191);\n vertex(240,230);\n vertex(240,270);\n vertex(205,312);\n vertex(200,302);\n vertex(200,248);\n vertex(193,238);\n vertex(185,231);\n vertex(170,230);\n vertex(170,186);\n endShape(CLOSE);\n\n //white\n fill(200);\n beginShape();\n vertex(70,217);\n vertex(74,220);\n vertex(81,210);\n vertex(85,213);\n vertex(75,227);\n vertex(72,229);\n vertex(71,231);\n vertex(73,233);\n vertex(73,268);\n vertex(71,272);\n vertex(76,277);\n vertex(82,274);\n vertex(89,283);\n vertex(90,297);\n vertex(66,272);\n vertex(65,235);\n vertex(68,229);\n vertex(62,228);\n endShape(CLOSE);\n beginShape();\n vertex(228,217);\n vertex(225,218);\n vertex(218,211);\n vertex(215,213);\n vertex(223,227);\n vertex(226,226);\n vertex(230,230);\n vertex(227,233);\n vertex(228,270);\n vertex(229,272);\n vertex(223,276);\n vertex(218,276);\n vertex(210,283);\n vertex(211,296);\n vertex(235,273);\n vertex(234,233);\n vertex(232,228);\n vertex(237,227);\n endShape(CLOSE);\n\n //guns\n //white\n fill(200);\n beginShape();\n vertex(121,301);\n vertex(98,313);\n vertex(102,336);\n vertex(119,342);\n vertex(139,336);\n vertex(141,313);\n endShape(CLOSE);//l\n beginShape();\n vertex(159,312);\n vertex(162,336);\n vertex(180,342);\n vertex(200,336);\n vertex(202,313);\n vertex(180,302);\n endShape(CLOSE);\n\n //black\n fill(0);\n rect(105,315,30,30);\n rect(166,315,30,30);\n quad(105,344,109,355,131,355,135,344);\n quad(166,344,170,355,192,355,196,344);\n //green\n fill(0,0,67);\n rect(103,253,33,62);//l\n rect(164,252,33,62);//r\n //white\n fill(200);\n bezier(103,252,107,230,132,230,136,252);//l\n bezier(164,252,169,230,192,230,197,252);//r\n rect(103,280,33,25);//l\n rect(164,280,33,25);//r\n rect(104,319,33,26,3);//l\n rect(165,319,33,26,3);//r\n rect(115,310,7,28,8);//l\n rect(178,310,7,28,8);//r\n //green\n fill(0,0,67);\n rect(105,284,10,15);\n rect(124,284,10,15);\n rect(167,285,10,15);\n rect(185,284,10,15);\n\n //body-wings\n //green\n fill(0,0,67);//blue\n bezier(107,154,101,162,98,169,98,187);\n bezier(191,153,199,164,202,172,203,187);\n quad(107,154,98,186,98,223,107,224);\n quad(191,153,203,186,202,223,192,223);\n fill(192,0,11);//red\n quad(134,112,108,147,107,239,132,230);\n quad(165,112,192,147,193,239,168,230);\n //black\n fill(0);\n quad(130,122,130,142,111,164,111,147);\n quad(169,122,188,147,188,165,169,144);\n //white\n fill(200);\n beginShape();\n vertex(131,154);\n vertex(129,202);\n vertex(118,202);\n vertex(112,181);\n vertex(110,179);\n vertex(110,171);\n endShape(CLOSE);\n beginShape();\n vertex(170,154);\n vertex(190,172);\n vertex(190,182);\n vertex(188,181);\n vertex(182,201);\n vertex(172,201);\n endShape(CLOSE);\n\n //green\n fill(192,0,11);\n quad(134,193,166,193,154,342,146,342);\n fill(192,0,11);\n quad(142,180,159,180,152,352,148,352);\n //white\n fill(200);\n ellipse(150,374,6,50);\n\n //head\n fill(1,1,75);\n ellipse(149.5f,72,33,25);\n ellipse(149.5f,94,30,170);\n fill(0);\n ellipse(149.5f,94,20,160);\n fill(154,155,84);\n ellipse(149.5f,94,17,77);\n strokeWeight(2);\n line(143,74,158,74);\n line(142,104,158,104);\n strokeWeight(1);\n fill(200);\n bezier(143,15,147,2,153,2,155.5f,15);\n }",
"public PencilDrawing() //default constructor\n {\n \n super(\"Pencil Draw\");\n \n Toolkit tk = Toolkit.getDefaultToolkit(); //so that the frame fills the screen\n Dimension dim = tk.getScreenSize();\n setBounds(0,0, dim.width, dim.height);\n points = new PointData();\n \n //place buttons\n buttonPanel = new JPanel();\n eraseButton = new JButton(\"Erase\");\n colorButton = new JButton(\"Color\");\n exitButton = new JButton(\"Exit\");\n buttonPanel.add(eraseButton);\n buttonPanel.add(colorButton);\n buttonPanel.add(exitButton);\n add(buttonPanel, BorderLayout.SOUTH);\n \n //place the drawing panel in the frame\n paper = new JPanel();\n add(paper);\n \n //register the mouse listners\n addMouseListener(new MouseButtonListener());\n addMouseMotionListener(new MoveMouseListener());\n \n //register the button listener\n eraseButton.addActionListener(new ButtonListener());\n colorButton.addActionListener(new ButtonListener());\n exitButton.addActionListener(new ButtonListener());\n setResizable(false);\n setVisible(true);\n setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);\n \n }",
"public void setTargets(){\n Targot_Button1 = new JButton();\n Targot_Button1.setSize(50,120);\n Targot_Button1.setVisible(true);\n Targot_Button1.setLocation(235,270);\n Targot_Button1.setContentAreaFilled(false);\n Targot_Button1.setBorder(null);\n Targot_Button1.addActionListener(this);\n this.add(Targot_Button1);\n \n // sets up targot 2\n Targot_Button2 = new JButton();\n Targot_Button2.setSize(50,125);\n Targot_Button2.setVisible(true);\n Targot_Button2.setLocation(128,280);\n Targot_Button2.setContentAreaFilled(false);\n Targot_Button2.setBorder(null);\n Targot_Button2.addActionListener(this);\n this.add(Targot_Button2);\n \n // sets up targot 3\n Targot_Button3 = new JButton();\n Targot_Button3.setSize(40,80);\n Targot_Button3.setVisible(true);\n Targot_Button3.setLocation(185,280);\n Targot_Button3.setContentAreaFilled(false);\n Targot_Button3.setBorder(null);\n Targot_Button3.addActionListener(this);\n this.add(Targot_Button3);\n \n // sets up targot 4\n Targot_Button4 = new JButton();\n Targot_Button4.setSize(65,180);\n Targot_Button4.setVisible(true);\n Targot_Button4.setLocation(15,265);\n Targot_Button4.setContentAreaFilled(false);\n Targot_Button4.setBorder(null);\n Targot_Button4.addActionListener(this);\n this.add(Targot_Button4);\n \n // sets up targot 5\n Targot_Button5 = new JButton();\n Targot_Button5.setSize(20,60);\n Targot_Button5.setVisible(true);\n Targot_Button5.setLocation(380,270);\n Targot_Button5.setContentAreaFilled(false);\n Targot_Button5.setBorder(null);\n Targot_Button5.addActionListener(this);\n this.add(Targot_Button5);\n \n // sets up targot 1\n Targot_Button6 = new JButton();\n Targot_Button6.setSize(40,100);\n Targot_Button6.setVisible(true);\n Targot_Button6.setLocation(465,280);\n Targot_Button6.setContentAreaFilled(false);\n Targot_Button6.setBorder(null);\n Targot_Button6.addActionListener(this);\n this.add(Targot_Button6);\n \n }",
"@Override\r\n public final void draw(final Rectangle r, final BufferedImage paper) {\n String red;\r\n String green;\r\n String blue;\r\n if (Integer.toHexString(r.getBorderColor().getRed()).length() == 1) {\r\n red = \"0\" + Integer.toHexString(r.getBorderColor().getRed());\r\n } else {\r\n red = Integer.toHexString(r.getBorderColor().getRed());\r\n }\r\n if (Integer.toHexString(r.getBorderColor().getGreen()).length() == 1) {\r\n green = \"0\" + Integer.toHexString(r.getBorderColor().getGreen());\r\n } else {\r\n green = Integer.toHexString(r.getBorderColor().getGreen());\r\n }\r\n if (Integer.toHexString(r.getBorderColor().getBlue()).length() == 1) {\r\n blue = \"0\" + Integer.toHexString(r.getBorderColor().getBlue());\r\n } else {\r\n blue = Integer.toHexString(r.getBorderColor().getBlue());\r\n }\r\n String color = \"#\" + red + green + blue;\r\n\r\n draw(new Line((String.valueOf(r.getxSus())), String.valueOf(r.getySus()),\r\n String.valueOf(r.getxSus() + r.getLungime() - 1), String.valueOf(r.getySus()),\r\n color, String.valueOf(r.getBorderColor().getAlpha()), paper), paper);\r\n\r\n draw(new Line((String.valueOf(r.getxSus() + r.getLungime() - 1)),\r\n String.valueOf(r.getySus()), String.valueOf(r.getxSus() + r.getLungime() - 1),\r\n String.valueOf(r.getySus() + r.getInaltime() - 1), color,\r\n String.valueOf(r.getBorderColor().getAlpha()), paper), paper);\r\n\r\n draw(new Line((String.valueOf(r.getxSus() + r.getLungime() - 1)),\r\n String.valueOf(r.getySus() + r.getInaltime() - 1), String.valueOf(r.getxSus()),\r\n String.valueOf(r.getySus() + r.getInaltime() - 1), color,\r\n String.valueOf(r.getBorderColor().getAlpha()), paper), paper);\r\n\r\n draw(new Line((String.valueOf(r.getxSus())),\r\n String.valueOf(r.getySus() + r.getInaltime() - 1), String.valueOf(r.getxSus()),\r\n String.valueOf(r.getySus()), color, String.valueOf(r.getBorderColor().getAlpha()),\r\n paper), paper);\r\n\r\n for (int i = r.getxSus() + 1; i < r.getxSus() + r.getLungime() - 1; i++) {\r\n for (int j = r.getySus() + 1; j < r.getySus() + r.getInaltime() - 1; j++) {\r\n if (checkBorder(i, j, paper)) {\r\n paper.setRGB(i, j, r.getFillColor().getRGB());\r\n }\r\n }\r\n }\r\n }",
"private void drawPushpins(Graphics g, int wid, int hei) {\n g.setColor(Color.black);\n g.drawOval(8, 8, 14, 14);\n g.drawOval(wid - 22, 8, 14, 14);\n g.drawOval(8, hei - 22, 14, 14);\n g.drawOval(wid - 22, hei - 22, 14, 14);\n g.drawLine(8, 15, 22, 15);\n g.drawLine(wid - 20, 18, wid - 10, 13);\n g.drawLine(10, hei - 17, 20, hei - 12);\n g.drawLine(wid - 22, hei - 15, wid - 8, hei - 15);\n }",
"public void makeWindows()\r\n {\r\n int spacingX = random.nextInt( 3 ) + 3;\r\n int spacingY = random.nextInt( 5 ) + 3;\r\n int windowsX = random.nextInt( 3 ) + 4;\r\n int windowsY = random.nextInt( 3 ) + 5;\r\n int sizeX = ( building.getWidth() - spacingX * ( windowsX + 1 ) ) / windowsX;\r\n int sizeY = ( building.getHeight() - spacingY * ( windowsY + 1 ) ) / windowsY;\r\n \r\n \r\n for( int i = 1; i <= windowsX; i++ )\r\n {\r\n for( int k = 1; k <= windowsY; k++ )\r\n {\r\n \r\n Rectangle r = new Rectangle( building.getXLocation() + ( spacingX / 2 + spacingX * i ) + sizeX * ( i - 1 ), \r\n building.getYLocation() + ( spacingY / 2 + spacingY * k ) + sizeY * ( k - 1 ) );\r\n r.setSize( sizeX, sizeY );\r\n r.setColor( new Color( 254, 254, 34 ) );\r\n add( r );\r\n }\r\n }\r\n }",
"@Override\r\n\tprotected void generateAreas() {\n\t\tPerlinNoise noise = new PerlinNoise(new Random().nextInt(), xmasTemplate.getScale(), xmasTemplate.getOctaves(), xmasTemplate.getPersistence());\r\n\t\tfor (int y = 0; y < getHeight(); y ++) {\r\n\t\t\tfor (int x = 0; x < getWidth(); x ++) {\r\n\t\t\t\tif (getValue(x, y) != BASE) {\r\n\t\t\t\t\tif (noise.perlinNoise(x, y) > xmasTemplate.getThreshold()) {\r\n\t\t\t\t\t\tsetValue(x, y, WALL);\r\n\t\t\t\t\t} else {\r\n\t\t\t\t\t\tsetValue(x, y, FLOOR);\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\t// Fill east, west and south\r\n\t\tfor (int x = 0; x < getWidth(); x ++) {\r\n\t\t\tdrawArea(x, 0, CosineInterpolator.instance.interpolate(2.0f, 6.0f, (float) Math.random()), WALL);\r\n\t\t}\r\n\t\tfor (int y = 0; y < getHeight(); y ++) {\r\n\t\t\tdrawArea(0, y, CosineInterpolator.instance.interpolate(2.0f, 6.0f, (float) Math.random()), WALL);\r\n\t\t\tdrawArea(getWidth() - 1, y, CosineInterpolator.instance.interpolate(2.0f, 6.0f, (float) Math.random()), WALL);\r\n\t\t}\r\n\r\n\t\t// Draw random blotch lines between each base first\r\n\t\tArrayList<Point> basesCopy = new ArrayList<Point>(getBases());\r\n\t\tfor (int i = 0; i < basesCopy.size(); i ++) {\r\n\t\t\tPoint p1 = basesCopy.get(i);\r\n\t\t\tint j = Util.random(0, basesCopy.size() - 1);\r\n\t\t\tPoint p2 = basesCopy.get(j);\r\n\t\t\tbasesCopy.set(i, p2);\r\n\t\t\tbasesCopy.set(j, p1);\r\n\t\t}\r\n\r\n\t\tPoint s = basesCopy.get(0), t;\r\n\t\tdrawArea(s.getX(), s.getY(), (xmasTemplate.getMinMainTunnelWidth() + xmasTemplate.getMaxMainTunnelWidth()) / 2.0f, FLOOR);\r\n\t\tfor (int i = 0; i < basesCopy.size() - 1; i ++) {\r\n\t\t\ts = basesCopy.get(i);\r\n\t\t\tt = basesCopy.get(i + 1);\r\n\t\t\tdrawLine(s.getX(), s.getY(), t.getX(), t.getY(), xmasTemplate.getMinMainTunnelWidth(), xmasTemplate.getMaxMainTunnelWidth(), FLOOR);\r\n\t\t}\r\n\r\n\t}",
"public void Draw(Graphics g)\n/* */ {\n/* 55 */ g.setColor(this.m_color);\n/* */ \n/* 57 */ Point prevPt = new Point(0, 0);Point currPt = new Point(0, 0);\n/* */ \n/* 59 */ for (double t = 0.0D; t < 1.01D; t += this.m_tValue) {\n/* 60 */ ptFromTVal(t, currPt);\n/* */ \n/* 62 */ if (t == 0.0D) {\n/* 63 */ prevPt.x = currPt.x;\n/* 64 */ prevPt.y = currPt.y;\n/* */ }\n/* */ \n/* 67 */ g.drawLine(prevPt.x, prevPt.y, currPt.x, currPt.y);\n/* */ \n/* 69 */ if (this.m_showTPoints) {\n/* 70 */ g.fillOval(currPt.x - this.PT_RADIUS, currPt.y - this.PT_RADIUS, this.PT_DIAMETER, this.PT_DIAMETER);\n/* */ }\n/* */ \n/* 73 */ prevPt.x = currPt.x;\n/* 74 */ prevPt.y = currPt.y;\n/* */ }\n/* */ }",
"public void setToPlaceTowerState() {\n for (int i = 0; i < cells.size(); i++) {\n if (cells.get(i) == CellState.Grass) {\n cells.set(i, CellState.ToPlaceTower);\n } else if (cells.get(i) == CellState.Chosen) {\n cells.set(i, CellState.Tower);\n }\n }\n }",
"private void drawRightColoumn(SettingsClass s,int w){\r\n \r\n // draws black rectangles\r\n g.setColor(Color.black);\r\n for(int i=0;i<4;i++){\r\n g.fillRect(w-40-100,5+50*(i+1),100,40);\r\n }\r\n \r\n // writes current values of SettingsClass\r\n \r\n // sets font\r\n Font font=new Font(\"SanSerif\",Font.BOLD,40); \r\n g.setColor(Color.white);\r\n g.setFont(font);\r\n \r\n // num players\r\n drawNumber(font,intString(s.getNumPlayers()),w-40-50,40+50*1);\r\n //match point\r\n drawNumber(font,intString(s.getWinningPoint()),w-40-50,40+50*2); \r\n //time limit\r\n drawNumber(font,intTime(s.getTimeLimit()),w-40-50,40+50*3);\r\n //sudden death\r\n if(s.getSuddenDeath()){\r\n drawNumber(font,\"Yes\",w-40-50,40+50*4); \r\n } \r\n else{\r\n drawNumber(font,\"No\",w-40-50,40+50*4); \r\n }\r\n\r\n // draws icons of players\r\n for(int i=0;i<s.getNumPlayers();i++){\r\n g.drawImage(icons[s.getPlayerColor(i)],w-40-65,275+40*i,null);\r\n }\r\n \r\n // draws all the triangles\r\n drawTriangles(s,w);\r\n \r\n }",
"private void drawActions() {\n\t\tif (state.getSelectedEntity() == null) {\n\t\t\treturn;\n\t\t}\n\n\t\tAction [] actions = state.isSelectedFront() ? state.getSelectedEntity().getActions() : state.getSelectedEntity().getSwapActions();\n\t\tfor (int i = 0; i < actions.length; i++) {\n\t\t\tactions[i].render(batch, 500 + 25 * i, 800);\n\n\t\t\t// Do we draw the cursor here?\n\t\t\tif (state.getActionCursorPos() == i) {\n\t\t\t\tcursor.setPosition(500 + 25 * i, 900);\n\t\t\t\tcursor.draw(batch);\n\t\t\t}\n\t\t}\n\t}",
"public void draw(Graphics g, int... paneOffsets) { }",
"@Override\n public void draw(WinPlotterFX plotter) {\n super.draw(plotter);\n plotter.printAt(x + (base / 3.2), y + (height / 3), name);\n }",
"@Override\n public void paintComponent(Graphics g)\n {\n super.paintComponent(g);\n timer.start();\n if (i < 4)\n {\n g.setColor(Color.WHITE);\n if (i == 1)\n {\n utils.playSoundtrack(\"sound/Monster_Howl_1.wav\", 5);\n }\n g.setFont(new Font(\"Tahoma\", Font.BOLD, 18));\n g.drawString(Stage3_story[i], 30, 280);\n }\n else\n {\n Image image = Toolkit.getDefaultToolkit().getImage(\"background/Door_Wallpaper.jpg\");\n g.drawImage(image, 0, 0, this);\n g.setColor(Color.WHITE);\n g.setFont(new Font(\"Tahoma\", Font.BOLD, 20));\n g.drawString(\"Push the right amount of pins in each section with the clips to unlock door!\", 130, 400); \n \n section1.setBounds(250,250,100,50);\n section2.setBounds(450,250,100,50);\n section3.setBounds(650,250,100,50);\n \n add(section1);\n add(section2);\n add(section3);\n \n section1.setOpaque(true);\n section1.setContentAreaFilled(true);\n section1.setBorderPainted(true);\n\n }\n \n if(lockpickCompleted == true)\n {\n g.setColor(Color.BLACK);\n g.fillRect(0, 0, 1000, 600);\n g.setColor(Color.WHITE);\n g.setFont(new Font(\"Tahoma\", Font.BOLD, 20));\n g.drawString(\"Lockpick successful! You dig around to find something for a fight without vision:\", 80, 100);\n g.drawString(\"You have found: \", 400, 150);\n \n \n batButton.setLocation(220, 210);\n dagButton.setLocation(420, 210);\n macButton.setLocation(620, 210);\n \n add(batButton);\n add(dagButton);\n add(macButton);\n \n batButton.setOpaque(true);\n batButton.setContentAreaFilled(true);\n batButton.setBorderPainted(true);\n \n macButton.setOpaque(true);\n macButton.setContentAreaFilled(true);\n macButton.setBorderPainted(true);\n \n dagButton.setOpaque(true);\n dagButton.setContentAreaFilled(true);\n dagButton.setBorderPainted(true); \n }\n \n if(stageCompleted == true)\n {\n currentPlayer.setCurrentStageLevel(new Stage_4());\n PanelManager.setCurrentPlayer(currentPlayer);\n PanelManager.changeToStagePanel();\n }\n }",
"@Override\r\n public void actionPerformed(ActionEvent e) {\n System.out.println(popped_points+ \"++++++++++++++++++++++\");\r\n int x1_r = popped_points.get(0);\r\n int y1_r = popped_points.get(1);\r\n int x2_r = popped_points.get(2);\r\n int y2_r = popped_points.get(3);\r\n\r\n switch (popped_shape){\r\n case \"rec\":\r\n g.setColor(popped_color);\r\n int[] start_points = start_point(x1_r, y1_r,x2_r,y2_r);\r\n g.drawRect(start_points[0], start_points[1], Math.abs(x2_r-x1_r), Math.abs(y2_r-y1_r));\r\n canvas.repaint();\r\n\r\n// System.out.println(rec_colors);\r\n// System.out.println(rec_points);\r\n// System.out.println(progress_stack);\r\n\r\n //store this shape in regular stack\r\n rec_colors.add(popped_color);\r\n progress_stack.add(popped_shape);\r\n for (int i = 0; i < popped_points.size(); i++) {\r\n rec_points.add(popped_points.get(i));\r\n }\r\n\r\n// System.out.println(rec_colors);\r\n System.out.println(rec_points+\"++++++++++++++++++++++++++++++++\");\r\n// System.out.println(progress_stack);\r\n\r\n break;\r\n case \"squ\":\r\n g.setColor(popped_color);\r\n start_points = start_point(x1_r, y1_r,x2_r,y2_r);\r\n g.drawRect(start_points[0], start_points[1], Math.abs(x2_r-x1_r), Math.abs(x2_r-x1_r));\r\n canvas.repaint();\r\n\r\n //store this shape in regular stack\r\n squ_colors.add(popped_color);\r\n progress_stack.add(popped_shape);\r\n for (int i = 0; i < popped_points.size(); i++) {\r\n squ_points.add(popped_points.get(i));\r\n }\r\n\r\n break;\r\n\r\n case \"ell\":\r\n g.setColor(popped_color);\r\n start_points = start_point(x1_r, y1_r,x2_r,y2_r);\r\n g.drawOval(start_points[0], start_points[1], Math.abs(x2_r-x1_r), Math.abs(y2_r-y1_r));\r\n canvas.repaint();\r\n\r\n //store this shape in regular stack\r\n ell_colors.add(popped_color);\r\n progress_stack.add(popped_shape);\r\n for (int i = 0; i < popped_points.size(); i++) {\r\n ell_points.add(popped_points.get(i));\r\n }\r\n break;\r\n\r\n case \"cir\":\r\n g.setColor(popped_color);\r\n start_points = start_point(x1_r, y1_r,x2_r,y2_r);\r\n g.drawOval(start_points[0], start_points[1], Math.abs(x2_r-x1_r), Math.abs(x2_r-x1_r));\r\n canvas.repaint();\r\n\r\n //store this shape in regular stack\r\n cir_colors.add(popped_color);\r\n progress_stack.add(popped_shape);\r\n for (int i = 0; i < popped_points.size(); i++) {\r\n cir_points.add(popped_points.get(i));\r\n }\r\n\r\n break;\r\n\r\n case \"str\":\r\n g.setColor(popped_color);\r\n g.drawLine(x1_r, y1_r, x2_r, y2_r);\r\n canvas.repaint();\r\n\r\n //store this shape in regular stack\r\n str_colors.add(popped_color);\r\n progress_stack.add(popped_shape);\r\n for (int i = 0; i < popped_points.size(); i++) {\r\n str_points.add(popped_points.get(i));\r\n }\r\n\r\n break;\r\n\r\n case \"handdraw\":\r\n g.setColor(popped_color);\r\n int line_num = popped_points.size()/2-1;\r\n for (int i = 0; i < line_num; i++) {\r\n int begin_index = i*2;\r\n g.drawLine(popped_points.get(begin_index),popped_points.get(begin_index+1),popped_points.get(begin_index+2),popped_points.get(begin_index+3));\r\n }\r\n canvas.repaint();\r\n\r\n //store this shape in regular stack\r\n handdraw_colors.add(popped_color);\r\n progress_stack.add(popped_shape);\r\n\r\n for (int i = 0; i < popped_points.size(); i++) {\r\n handdraw_points.add(popped_points.get(i));\r\n }\r\n handdraw_points.add(-1);\r\n\r\n break;\r\n\r\n case \"poly\":\r\n g.setColor(popped_color);\r\n line_num = popped_points.size()/2-1;\r\n for (int i = 0; i < line_num; i++) {\r\n int begin_index = i*2;\r\n g.drawLine(popped_points.get(begin_index),popped_points.get(begin_index+1),popped_points.get(begin_index+2),popped_points.get(begin_index+3));\r\n }\r\n canvas.repaint();\r\n\r\n //store this shape in regular stack\r\n for (int i = 0; i < popped_points.size()/2; i++) {\r\n poly_colors.add(popped_color);\r\n progress_stack.add(popped_shape);\r\n }\r\n\r\n poly_points.add(-1);\r\n for (int i = 0; i < popped_points.size(); i++) {\r\n poly_points.add(popped_points.get(i));\r\n }\r\n break;\r\n\r\n }\r\n\r\n /*//repaint last shape in stack\r\n String last_shape = progress_stack.get(progress_stack.size()-1);\r\n if(last_shape.equals(\"rec\")){\r\n //rectangle repaint\r\n repaint_shapes(\"rec\", rec_colors, rec_points);\r\n }\r\n if(last_shape.equals(\"cir\")){\r\n //circle repaint\r\n repaint_shapes(\"cir\", cir_colors, cir_points);\r\n }\r\n if(last_shape.equals(\"squ\")){\r\n //square repaint\r\n repaint_shapes(\"squ\", squ_colors, squ_points);\r\n }\r\n if(last_shape.equals(\"ell\")){\r\n //ellipse repaint\r\n repaint_shapes(\"ell\", ell_colors, ell_points);\r\n }\r\n if(last_shape.equals(\"str\")){\r\n //straight line repaint\r\n repaint_shapes(\"str\", str_colors, str_points);\r\n }\r\n if(last_shape.equals(\"poly\")){\r\n //polygon repaint\r\n ArrayList<Integer> separate_index = get_separate_index(poly_points);\r\n ArrayList<Integer> points = new ArrayList<Integer>();\r\n\r\n //other shapes\r\n for (int j = 0; j < separate_index.size()-1; j++) {\r\n Color polygon_color = poly_colors.get(j);\r\n //each shape repaint\r\n int begin_index = separate_index.get(j);\r\n int end_index = separate_index.get(j+1);\r\n\r\n //get polygon points arraylist\r\n for (int k = (begin_index+1); k < end_index; k++) {\r\n points.add(poly_points.get(k));\r\n\r\n }\r\n System.out.println(points);\r\n\r\n //repaint one polygon\r\n int line_num = points.size()/2 - 1 ;\r\n for (int k = 0; k < line_num; k++) {\r\n int begin_point = k*2;\r\n x1 = points.get(begin_point);\r\n y1 = points.get(begin_point + 1);\r\n x2 = points.get(begin_point + 2);\r\n y2 = points.get(begin_point + 3);\r\n\r\n g.setColor(polygon_color);\r\n g.drawLine(x1, y1, x2, y2);\r\n\r\n canvas.repaint();\r\n }\r\n points.clear();\r\n }\r\n\r\n //the last polygon\r\n //get last shape points arraylist\r\n int index = separate_index.get(separate_index.size()-1);\r\n for (int j = index+1; j < poly_points.size(); j++) {\r\n points.add(poly_points.get(j));\r\n }\r\n System.out.println(points);\r\n //using points to repaint polygon\r\n int line_num = points.size()/2 - 1 ;\r\n for (int j = 0; j < line_num; j++) {\r\n int begin_point = j*2;\r\n x1 = points.get(begin_point);\r\n y1 = points.get(begin_point + 1);\r\n x2 = points.get(begin_point + 2);\r\n y2 = points.get(begin_point + 3);\r\n\r\n g.setColor(poly_colors.get(poly_colors.size()-1));\r\n g.drawLine(x1, y1, x2, y2);\r\n\r\n canvas.repaint();\r\n }\r\n }\r\n\r\n if(last_shape.equals(\"handdraw\")){\r\n //freehand drawing repaint\r\n if(handdraw_colors.size()>0){\r\n //repaint all handdraw\r\n ArrayList<Integer> separate_index = get_separate_index(handdraw_points);\r\n ArrayList<Integer> points = new ArrayList<Integer>();\r\n for (int i = 0; i < handdraw_colors.size(); i++) {\r\n //each handdraw\r\n //take all points in one draw\r\n if(i == 0){\r\n //first draw\r\n int begin_index = 0;\r\n int end_index = separate_index.get(i);\r\n //get all points in first drawing\r\n for (int j = begin_index; j < end_index; j++) {\r\n points.add(handdraw_points.get(j));\r\n }\r\n //repaint first drawing\r\n System.out.println(points);\r\n\r\n int line_num = points.size()/2 - 1;\r\n for (int j = 0; j < line_num; j++) {\r\n //draw each short line\r\n begin_index = j*2;\r\n\r\n x1 = points.get(begin_index);\r\n y1 = points.get(begin_index + 1);\r\n x2 = points.get(begin_index + 2);\r\n y2 = points.get(begin_index + 3);\r\n\r\n g.setColor(handdraw_colors.get(i));\r\n g.drawLine(x1, y1, x2, y2);\r\n\r\n canvas.repaint();\r\n\r\n }\r\n points.clear();\r\n\r\n }else{\r\n //draw other handdraws\r\n for (int j = 0; j < handdraw_colors.size()-1; j++) {\r\n //draw each drawing\r\n\r\n int begin_index = separate_index.get(j)+1;\r\n int end_index = separate_index.get(j+1);\r\n //get all points in one drawing\r\n for (int k = begin_index; k < end_index; k++) {\r\n points.add(handdraw_points.get(k));\r\n }\r\n System.out.println(points);\r\n\r\n //repaint drawing\r\n int line_num = points.size()/2 - 1;\r\n for (int k = 0; k < line_num; k++) {\r\n //each line\r\n begin_index = k*2;\r\n\r\n x1 = points.get(begin_index);\r\n y1 = points.get(begin_index + 1);\r\n x2 = points.get(begin_index + 2);\r\n y2 = points.get(begin_index + 3);\r\n\r\n g.setColor(handdraw_colors.get(i));\r\n g.drawLine(x1, y1, x2, y2);\r\n\r\n canvas.repaint();\r\n\r\n }\r\n\r\n points.clear();\r\n\r\n }\r\n\r\n\r\n }\r\n\r\n }\r\n\r\n }\r\n\r\n }*/\r\n\r\n\r\n }",
"@Override\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\tinfomation.drawSet();\n\t\t\t}",
"public void temporalLayout() {\n // Choose the appropriate set\n Set<String> sel = getRTParent().getSelectedEntities(); Iterator<String> it;\n if (sel != null && sel.size() > 0) it = sel.iterator(); else it = entity_to_wxy.keySet().iterator();\n // Get globals for string to int conversion\n Bundles root = getRTParent().getRootBundles();\n BundlesG globals = root.getGlobals();\n // Go through the selection and place the nodes\n while (it.hasNext()) {\n String entity = it.next(); int entity_i = graph.getEntityIndex(entity);\n int entity_int = globals.toInt(entity); \n long ts0 = root.ts1(), ts1 = root.ts0();\n // Go through the neighbors and iterate through the underlying bundles\n for (int i=0;i<graph.getNumberOfNeighbors(entity_i);i++) {\n int nbor_i = graph.getNeighbor(entity_i, i);\n\tString linkref = graph.getLinkRef(entity_i, nbor_i);\n Iterator<Bundle> it_b = graph.linkRefIterator(linkref);\n\twhile (it_b.hasNext()) {\n\t Bundle bundle = it_b.next();\n\t if (bundle.hasTime()) {\n\t if (ts0 > bundle.ts0()) ts0 = bundle.ts0();\n\t if (ts1 < bundle.ts0()) ts1 = bundle.ts0();\n\t }\n\t}\n }\n // Place the node\n Point2D point = new Point2D.Double((((double) ts0)/(root.ts1() - root.ts0())),((double) entity_int)/Integer.MAX_VALUE);\n entity_to_wxy.put(entity, point);\n // Do the transformation\n transform(entity);\n }\n zoomToFit(); repaint();\n }",
"public static void main(String [] args) \n {\n World world = new World(false);\n \n //creating 2d turtle\n Turtle t = new Turtle(world);\n Turtle t2 = new Turtle(world);\n Turtle t3 = new Turtle(world);\n\n //creating variables that are holding the dimentions for the house\n int width = 250;\n int height = 150;\n int windowWidth = 30;\n int doorWidth = 30;\n int doorHeight = 50;\n int initialY = t.getYPos();\n int grassX = 0;\n int grassY = 479;\n int grassPenWidth = 175;\n int grassPenLength = 639;\n int rectanglePenWidth = 5;\n int garagePenWidth = 5;\n int equialateralRoofPenWidth = 3;\n int equialaterTopOfDoor = 2;\n int garageWidth = height/2;\n \n //Turtle t2 creates green grass\n t2.penUp();\n t2.moveTo(grassX,grassY);\n t2.turnRight();\n t2.setPenWidth(grassPenWidth);\n t2.setPenColor(java.awt.Color.GREEN);\n t2.penDown();\n t2.forward(grassPenLength);\n \n //Turtle t create a rectangular house foundation \n t.setPenColor(java.awt.Color.BLACK);\n t.setPenWidth(rectanglePenWidth);\n t.drawRectangle(width, height);\n \n //Turtle t moved and creates a Equilateral roof\n t.penUp();\n t.turn(30);\n t.forward(width);\n t.turn(-30);\n t.penDown();\n t.setPenWidth(equialateralRoofPenWidth);\n t.drawEquilateral(width);\n t.penUp();\n \n //Turtle t creates the first right window\n t.turn(150);\n t.forward(width);\n t.turn(30);\n t.forward(height/4);\n t.turn(90);\n t.forward(width/4);\n t.turn(90);\n t.penDown();\n t.setPenWidth(3);\n \n //Turlte t changes color of window to red\n t.setPenColor(java.awt.Color.RED);\n t.drawSquare(windowWidth);\n t.penUp();\n \n //move Turtl t to the top left of the left window\n\n t.moveTo(t.getXPos() - width/2 - windowWidth, t.getYPos());\n \n //Turtle t creates left window\n t.penDown();\n t.setPenColor(java.awt.Color.RED);\n t.drawSquare(windowWidth);\n t.penUp();\n \n //Turtle t is moved to the top left of the door and creates it\n t.moveTo(t.getXPos() + doorWidth/2 + width/4, initialY + height - doorHeight);\n t.penDown();\n t.drawRectangle(doorWidth,doorHeight);\n t.penUp();\n \n //Turtle t moves to top left of the door and creates an equilater door accent\n t.turn(30);\n t.forward(doorWidth);\n t.turn(-30);\n t.penDown();\n t.setPenWidth(equialaterTopOfDoor);\n t.setPenColor(java.awt.Color.YELLOW);\n t.drawEquilateral(doorWidth);\n t.penUp();\n \n //Turtle t3 creates garage\n t3.penUp();\n t3.moveTo(t3.getXPos() - garageWidth, t3.getYPos() + height/2);\n t3.penDown();\n t3.setPenColor(java.awt.Color.BLACK);\n t3.setPenWidth(garagePenWidth);\n t3.drawSquare(garageWidth);\n\n //this hides the 2d turtles and shows the 2d world\n t.hide();\n t2.hide();\n t3.hide(); \n world.show();\n \n }",
"private void drawT(int[] xPoints,int[] yPoints,boolean condition){\r\n if(condition)\r\n g.setColor(Color.red); \r\n else\r\n g.setColor(Color.gray); \r\n g.fillPolygon(xPoints,yPoints,3);\r\n g.setColor(Color.black);\r\n g.drawPolygon(xPoints,yPoints,3); \r\n }",
"public void paintComponent(Graphics g)\n {\n super.paintComponent(g);\n\n Dimension d = getSize();\n //current block\n for (j = 0; j < 16; j++)\n {\n if (shapes[blockType][turnState][j] == 1)\n {\n g.setColor(Color.BLUE);\n g.fillRect((j%4 + x + 1)*d.width/20,(j/4 + y - 4)*d.width/20, d.width/20, d.width/20);\n g.setColor(Color.BLACK);\n g.drawRect((j%4 + x + 1)*d.width/20,(j/4 + y - 4)*d.width/20, d.width/20, d.width/20);\n }\n }\n //next block\n for (j = 0; j < 16; j++)\n {\n if (shapes[nextb][nextt][j] == 1)\n {\n g.setColor(Color.RED);\n g.fillRect((j%4 + 1)*d.width/20+d.width*13/20,(j/4)*d.width/20+d.width*3/20, d.width/20, d.width/20);\n g.setColor(Color.BLACK);\n g.drawRect((j%4 + 1)*d.width/20+d.width*13/20,(j/4)*d.width/20+d.width*3/20, d.width/20, d.width/20);\n\n }\n }\n //left boundary drawing\n for (j = 4; j < 36; j++)\n { \n int i = 0;\n if (map[i][j]==2)\n { \n g.setColor(Color.BLACK);\n g.drawLine((i+1)*d.width/20,(j-4)*d.width/20,(i+1)*d.width/20,(j-5)*d.width/20);\n }\n }\n //right boundary drawing\n for (j = 4; j < 36; j++)\n { \n int i = 11;\n if (map[i][j]==2)\n { \n g.setColor(Color.BLACK);\n g.drawLine(i*d.width/20,(j-4)*d.width/20,i*d.width/20,(j-5)*d.width/20);\n }\n }\n //bottom boundary drawing\n for (i = 0; i < 10; i++)\n {\n int j = 35;\n g.setColor(Color.BLACK);\n g.drawLine((i+1)*d.width/20,(j-4)*d.width/20,(i+2)*d.width/20,(j-4)*d.width/20);\n }\n //draw blocks which reached the bottom or on top of another block\n for (j = 4; j < 36; j++)\n {\n for (i = 0; i < 12; i++)\n {\n if (map[i][j] == 1)\n { \n g.setColor(Color.GREEN);\n g.fillRect(i*d.width/20,(j-4)*d.width/20, d.width/20, d.width/20);\n g.setColor(Color.BLACK);\n g.drawRect(i*d.width/20,(j-4)*d.width/20, d.width/20, d.width/20);\n } \n }\n }\n\n //next label\n g.setColor(Color.BLACK);\n g.setFont(new Font(\"Serif\", Font.ITALIC, d.width/20));\n g.drawString(\"Next Shape:\", d.width*13/20, d.width/8);\n //level label\n g.setColor(Color.black);\n g.setFont(new Font(\"Serif\", Font.BOLD, d.width*3/80));\n g.drawString(\"Level: \" + level, d.width*13/20, d.width*5/8);\n //line label\n g.setColor(Color.black);\n g.setFont(new Font(\"Serif\", Font.BOLD, d.width*3/80));\n g.drawString(\"Line: \" + showline, d.width*13/20, d.width*7/8);\n //score label\n g.setColor(Color.BLACK);\n g.setFont(new Font(\"Serif\", Font.BOLD, d.width*3/80));\n g.drawString(\"Score: \" + score, d.width*13/20, d.width*9/8);\n }",
"public void paintComponent(Graphics g)\n {\n super.paintComponent(g);\n\n Dimension d = getSize();\n //current block\n for (j = 0; j < 16; j++)\n {\n if (shapes[blockType][turnState][j] == 1)\n {\n g.setColor(Color.BLUE);\n g.fillRect((j%4 + x + 1)*d.width/20,(j/4 + y - 4)*d.width/20, d.width/20, d.width/20);\n g.setColor(Color.BLACK);\n g.drawRect((j%4 + x + 1)*d.width/20,(j/4 + y - 4)*d.width/20, d.width/20, d.width/20);\n }\n }\n //next block\n for (j = 0; j < 16; j++)\n {\n if (shapes[nextb][nextt][j] == 1)\n {\n g.setColor(Color.RED);\n g.fillRect((j%4 + 1)*d.width/20+d.width*13/20,(j/4)*d.width/20+d.width/10, d.width/20, d.width/20);\n g.setColor(Color.BLACK);\n g.drawRect((j%4 + 1)*d.width/20+d.width*13/20,(j/4)*d.width/20+d.width/10, d.width/20, d.width/20);\n\n }\n }\n //left boundary drawing\n for (j = 4; j < 26; j++)\n { \n int i = 0;\n if (map[i][j]==2)\n { \n g.setColor(Color.BLACK);\n g.drawLine((i+1)*d.width/20,(j-4)*d.width/20,(i+1)*d.width/20,(j-5)*d.width/20);\n }\n }\n //right boundary drawing\n for (j = 4; j < 26; j++)\n { \n int i = 11;\n if (map[i][j]==2)\n { \n g.setColor(Color.BLACK);\n g.drawLine(i*d.width/20,(j-4)*d.width/20,i*d.width/20,(j-5)*d.width/20);\n }\n }\n //bottom boundary drawing\n for (i = 0; i < 10; i++)\n {\n int j = 25;\n g.setColor(Color.BLACK);\n g.drawLine((i+1)*d.width/20,(j-4)*d.width/20,(i+2)*d.width/20,(j-4)*d.width/20);\n }\n //draw blocks which reached the bottom or on top of another block\n for (j = 4; j < 26; j++)\n {\n for (i = 0; i < 12; i++)\n {\n if (map[i][j] == 1)\n { \n g.setColor(Color.GREEN);\n g.fillRect(i*d.width/20,(j-4)*d.width/20, d.width/20, d.width/20);\n g.setColor(Color.BLACK);\n g.drawRect(i*d.width/20,(j-4)*d.width/20, d.width/20, d.width/20);\n } \n }\n }\n\n //next label\n g.setColor(Color.BLACK);\n g.setFont(new Font(\"Serif\", Font.ITALIC, d.width/20));\n g.drawString(\"Next Shape:\", d.width*13/20, d.width*3/40);\n //level label\n g.setColor(Color.black);\n g.setFont(new Font(\"Serif\", Font.BOLD, d.width*3/80));\n g.drawString(\"Level: \" + level, d.width*13/20, d.width/2);\n //line label\n g.setColor(Color.black);\n g.setFont(new Font(\"Serif\", Font.BOLD, d.width*3/80));\n g.drawString(\"Line: \" + showline, d.width*13/20, d.width*3/5);\n //score label\n g.setColor(Color.BLACK);\n g.setFont(new Font(\"Serif\", Font.BOLD, d.width*3/80));\n g.drawString(\"Score: \" + score, d.width*13/20, d.width*7/10);\n }",
"@Override\n public void paint(Graphics g) {\n g.setColor(Color.white);\n g.fillRect(0, 0, getWidth(), getHeight() );\n\n for (PieceUI pieceUI : pieceUIList) {\n pieceUI.draw(g);\n }\n\n g.drawImage(trapeze.getTrapezeView(), 200, 400, null);\n }",
"public void draw(Graphics g) {\n g.setColor(needsHighlight() ? selectColor : Color.GRAY);\n setBbox(x1, y1, x2, y2);\n g.setLineDash(16, 6);\n if (x1 < x2 && y1 < y2) {\n g.drawRect(x1, y1, x2 - x1, y2 - y1);\n } else if (x1 > x2 && y1 < y2) {\n g.drawRect(x2, y1, x1 - x2, y2 - y1);\n } else if (x1 < x2 && y1 > y2) {\n g.drawRect(x1, y2, x2 - x1, y1 - y2);\n } else {\n g.drawRect(x2, y2, x1 - x2, y1 - y2);\n }\n g.setLineDash(0, 0);\n }",
"public void drawGraph() {\n for (int x = 0; x < width; ++x) {\n for (int y = 0; y < height; ++y) {\n\n if (y == height / 2) {\n imageRaster.setPixel(x, y, lineColor);\n } else {\n imageRaster.setPixel(x, y, backgroundColor);\n }\n }\n }\n\n // lateral\n for (int x = 0; x < width; ++x) {\n float xUnit = x / (float) width;\n float slipAngle = map(xUnit, 0, 1, 0, maxSlipAngle);\n\n float lat = tireModel.calcLateralTireForce(slipAngle);\n lat = map(lat, -tireModel.getMaxLoad(), tireModel.getMaxLoad(), 0, height);\n int pixelY = (int) FastMath.clamp(lat, 0, height - 1);\n\n imageRaster.setPixel(x, pixelY, lateralColor);\n }\n\n // longitudinal\n for (int x = 0; x < width; ++x) {\n float xUnit = x / (float) width;\n float slipAngle = map(xUnit, 0, 1, 0, maxSlipAngle);\n\n float lng = tireModel.calcLongitudeTireForce(slipAngle);\n lng = map(lng, -tireModel.getMaxLoad(), tireModel.getMaxLoad(), 0, height);\n int pixelY = (int) FastMath.clamp(lng, 0, height - 1);\n\n imageRaster.setPixel(x, pixelY, longitudinalColor);\n }\n\n // align moment\n for (int x = 0; x < width; ++x) {\n float xUnit = x / (float) width;\n float slipAngle = map(xUnit, 0, 1, 0, maxSlipAngle);\n\n float mnt = tireModel.calcAlignMoment(slipAngle);\n mnt = map(mnt, -tireModel.getMaxLoad(), tireModel.getMaxLoad(), 0, height);\n int pixelY = (int) FastMath.clamp(mnt, 0, height - 1);\n\n imageRaster.setPixel(x, pixelY, momentColor);\n }\n }",
"public void drawMainWindow(){\n\n p.pushMatrix();\n p.translate(0,0);// translate whole window if necessary\n\n // window stuff\n // show name and draw\n p.stroke(0);\n p.strokeWeight(2);\n p.textSize(30);\n p.fill(0);\n p.text(\"Work space\",15,35);\n p.rectMode(CORNER);\n p.fill(219, 216, 206);\n p.rect(-285,40,1000,700);\n p.rectMode(CENTER);\n\n // show \"pause\" text\n if(pause) {\n p.fill(0);\n p.textSize(20);\n p.text(\"PAUSE\", 20, 60);\n p.textSize(12);\n }\n\n // draw coordinates lines\n drawCoordinateSystem();\n showRouteAsked();\n calculatePointer();\n\n // main mainManipulator\n manipulator.showManipulator(false);\n manipulator.route(true);\n\n if(routeAsked.size()>0) {\n if(!pause) manipulator.moveManally(routeAsked.get(0).copy());\n\n if (manipulator.segment_2_end.dist(routeAsked.get(0)) < 1) {\n routeAsked.remove(0);\n }\n\n // if you want to make it work with nn:\n\n// p.circle(routeAsked.get(0).x,routeAsked.get(0).y,15);\n// manipulator.setTarget(routeAsked.get(0));\n// manipulator.route(true);\n// if (!pause) manipulator.update();\n// manipulator.showManipulator(true);\n//\n// if (manipulator.targetDistFromAgent < 10) {\n// routeAsked.remove(0);\n// }\n }\n\n\n // pointer\n // show pointer and line to the pointer\n p.stroke(2);\n p.stroke(133, 168, 13,100);\n p.line(BASE_POS.x,BASE_POS.y,p.cos(pointerAngle)*pointerDist+BASE_POS.x,p.sin(pointerAngle)*pointerDist+BASE_POS.y);\n p.fill(207, 95, 43);\n p.noStroke();\n p.ellipse(pointerPos.x,pointerPos.y,15,15);\n\n p.popMatrix();\n }",
"@Override\n\tpublic void actionPerformed(ActionEvent e) \n\t{\n\t\tbrush.draw();\n\t}",
"private void doDrawing(Graphics g) {\n Dimension size = getSize();\n//paint all the shapes that have been dropped to the bottom \n int boardTop = (int) size.getHeight() - BOARD_HEIGHT * squareHeight();\n\n for (int i = 0; i < BOARD_HEIGHT; ++i) {\n\n for (int j = 0; j < BOARD_WIDTH; ++j) {\n// access all the squares that were stored in the board array\n Tetrominoe shape = shapeAt(j, BOARD_HEIGHT - i - 1);\n\n if (shape != Tetrominoe.NoShape) {\n \n drawSquare(g, 0 + j * squareWidth(),\n boardTop + i * squareHeight(), shape);\n }\n }\n }\n//paint the falling piece\n if (curPiece.getShape() != Tetrominoe.NoShape) {\n\n for (int i = 0; i < 4; ++i) {\n\n int x = curX + curPiece.x(i);\n int y = curY - curPiece.y(i);\n drawSquare(g, 0 + x * squareWidth(),\n boardTop + (BOARD_HEIGHT - y - 1) * squareHeight(),\n curPiece.getShape());\n }\n }\n }",
"public static void main(String [] args)\n{\n //this is something to memorize \n\nDrawingTool pencil;\nSketchPad paper;\n//these two were object declarations \npaper = new SketchPad (300,300); \npencil = new DrawingTool(paper); \n//these two were to create instances of the DrawingTool and SketchPad that are in the library today \n\n//now, directions: memorize the format for the instructions \npencil.forward (100);\npencil.turnRight (90);\npencil.forward (200);\npencil.turnRight (90);\npencil.forward (100);\npencil.turnRight (90);\npencil.forward (200);\npencil.turnRight (90);\npencil.forward (100);\npencil.turnRight (45);\npencil.forward (142);\npencil.turnRight (90); \npencil.forward (142);\npencil.turnRight (45);\npencil.forward (100);\npencil.turnRight (90);\npencil.forward (80);\npencil.turnRight (90);\npencil.forward (40);\npencil.turnLeft (90);\npencil.forward (20);\npencil.turnLeft (90);\npencil.forward (40);\n/*a few questions I have: can I change the color of the pencil, can I lift\n * it or choose where to start\n */\npencil.turnRight(90);\npencil.forward (100);\npencil.turnRight (90);\npencil.forward (160);\npencil.turnRight (90);\npencil.forward (30);\npencil.turnRight (90);\npencil.forward (30);\n\n\n\n \n\n//how can I add a new color in this? I requested access for the video \n//that the logo team made\n \n \n}",
"public void doCut()\n {\n bothToolClicked(map.selectedHexesIterator(), true);\n }",
"void drawShapes(List<ITile> tilesToDraw, IVertex optimalVertexToDraw,\n Point2D optimalVertexCoordinates);",
"public void paintComponent(Graphics g)\n {\n super.paintComponent(g);\n\n Dimension d = getSize();\n //current block\n for (j = 0; j < 16; j++)\n {\n if (shapes[blockType][turnState][j] == 1)\n {\n g.setColor(Color.BLUE);\n g.fillRect((j%4 + x + 1)*d.width/30,(j/4 + y - 4)*d.width/30, d.width/30, d.width/30);\n g.setColor(Color.BLACK);\n g.drawRect((j%4 + x + 1)*d.width/30,(j/4 + y - 4)*d.width/30, d.width/30, d.width/30);\n }\n }\n //next block\n for (j = 0; j < 16; j++)\n {\n if (shapes[nextb][nextt][j] == 1)\n {\n g.setColor(Color.RED);\n g.fillRect((j%4 + 1)*d.width/30+d.width*23/30,(j/4)*d.width/30+d.width/15, d.width/30, d.width/30);\n g.setColor(Color.BLACK);\n g.drawRect((j%4 + 1)*d.width/30+d.width*23/30,(j/4)*d.width/30+d.width/15, d.width/30, d.width/30);\n\n }\n }\n //left boundary drawing\n for (j = 4; j < 26; j++)\n { \n int i = 0;\n if (map[i][j]==2)\n { \n g.setColor(Color.BLACK);\n g.drawLine((i+1)*d.width/30,(j-4)*d.width/30,(i+1)*d.width/30,(j-5)*d.width/30);\n }\n }\n //right boundary drawing\n for (j = 4; j < 26; j++)\n { \n int i = 21;\n if (map[i][j]==2)\n { \n g.setColor(Color.BLACK);\n g.drawLine(i*d.width/30,(j-4)*d.width/30,i*d.width/30,(j-5)*d.width/30);\n }\n }\n //bottom boundary drawing\n for (i = 0; i < 20; i++)\n {\n int j = 25;\n g.setColor(Color.BLACK);\n g.drawLine((i+1)*d.width/30,(j-4)*d.width/30,(i+2)*d.width/30,(j-4)*d.width/30);\n }\n //draw blocks which reached the bottom or on top of another block\n for (j = 4; j < 26; j++)\n {\n for (i = 0; i < 21; i++)\n {\n if (map[i][j] == 1)\n { \n g.setColor(Color.GREEN);\n g.fillRect(i*d.width/30,(j-4)*d.width/30, d.width/30, d.width/30);\n g.setColor(Color.BLACK);\n g.drawRect(i*d.width/30,(j-4)*d.width/30, d.width/30, d.width/30);\n } \n }\n }\n\n //next label\n g.setColor(Color.BLACK);\n g.setFont(new Font(\"Serif\", Font.ITALIC, d.width/30));\n g.drawString(\"Next Shape:\", d.width*23/30, d.width*3/60);\n //level label\n g.setColor(Color.black);\n g.setFont(new Font(\"Serif\", Font.BOLD, d.width*3/120));\n g.drawString(\"Level: \" + level, d.width*23/30, d.width/3);\n //line label\n g.setColor(Color.black);\n g.setFont(new Font(\"Serif\", Font.BOLD, d.width*3/120));\n g.drawString(\"Line: \" + showline, d.width*23/30, d.width*2/5);\n //score label\n g.setColor(Color.BLACK);\n g.setFont(new Font(\"Serif\", Font.BOLD, d.width*3/120));\n g.drawString(\"Score: \" + score, d.width*23/30, d.width*7/15);\n }",
"private void drawDesignators(Graphics2D g2) {\n\t\tfinal int spacing_vert = 15;\n\t\t// Set the font.\n\t\tFont font = new Font(\"default\", Font.BOLD, 18);\n\t\tg2.setFont(font);\n\t\t// Calculate overlay screen positions.\n\t\tint startX = overlayPoint(Math.min(toScaledX(0), toScaledX(getDefaultTORA())),0).x;\n\t\tint endX = overlayPoint(Math.max(toScaledX(0), toScaledX(getDefaultTORA())),0).x;\n\t\tint y = overlayPoint(0, toScaledY(0)+verticalRunwayHeight-20).y;\n\t\t// Calculate text widths.\n\t\tint lowWidth = (int) font.getStringBounds(getLowDesignatorAngle(), new FontRenderContext(g2.getTransform(), true, true)).getWidth();\n\t\tint highWidth = (int) font.getStringBounds(getHighDesignatorAngle(), new FontRenderContext(g2.getTransform(), true, true)).getWidth();\n\t\tint lowWidth2 = (int) font.getStringBounds(getLowDesignatorSymbol(), new FontRenderContext(g2.getTransform(), true, true)).getWidth();\n\t\tint highWidth2 = (int) font.getStringBounds(getHighDesignatorSymbol(), new FontRenderContext(g2.getTransform(), true, true)).getWidth();\n\t\t// Calculate shift offsets.\n\t\tint lowOffset = (lowWidth - lowWidth2)/2;\n\t\tint highOffset = (highWidth - highWidth2)/2;\n\t\t// Draw the designator shadows.\n\t\tg2.setColor(ColourSchema.txt_shadow_gray);\n\t\tg2.drawString(getLowDesignatorAngle(), startX+5-2, y-2);\n\t\tg2.drawString(getHighDesignatorAngle(), endX-35-2, y-2);\n\t\tg2.drawString(getLowDesignatorSymbol(), startX+5-2 + lowOffset, y-2+spacing_vert);\n\t\tg2.drawString(getHighDesignatorSymbol(), endX-35-2 + highOffset, y-2+spacing_vert);\n\t\t// Draw the designators.\n\t\tg2.setColor(ColourSchema.txt_designator);\n\t\tg2.drawString(getLowDesignatorAngle(), startX+5, y);\n\t\tg2.drawString(getHighDesignatorAngle(), endX-35, y);\n\t\tg2.drawString(getLowDesignatorSymbol(), startX+5 + lowOffset, y+spacing_vert);\n\t\tg2.drawString(getHighDesignatorSymbol(), endX-35 + highOffset, y+spacing_vert);\n\t}",
"public void drawAll(){\n for (Triangle triangle : triangles) {\n triangle.draw();\n }\n for (Circle circle : circles) {\n circle.draw();\n }\n for(Rectangle rectangle : rectangles){\n rectangle.draw();\n }\n }",
"@Override\n protected void drawTask(Graphics g) {\n Graphics2D g2 = (Graphics2D) g;\n\n g2.setStroke(PetriNetUtils.defaultStroke);\n g2.setRenderingHint(RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_ON);\n\n Rectangle2D outline = new Rectangle2D.Float(getPos().x - (getSize().width / 2),\n getPos().y - (getSize().height / 2)+5, getSize().width-5, getSize().height-5);\n\n // Draw shadow\n Rectangle2D shadow = new Rectangle2D.Float(getPos().x - (getSize().width / 2) + 5,\n getPos().y - (getSize().height / 2), getSize().width-5, getSize().height-5);\n if (subNetOk) { \n g2.setPaint(Color.WHITE);\n } else {\n g2.setPaint(Color.RED);\n }\n g2.fill(shadow); \n g2.setPaint(Color.BLACK);\n g2.draw(shadow);\n\n g2.setPaint(Color.WHITE);\n if (isEnabledHighlight()) {\n g2.setPaint(Color.GREEN);\n }\n g2.fill(outline);\n\n // Render remaining time if > 0\n if (getRemainingTime() > 0) {\n int duration = 1;\n try {\n duration = Integer.parseInt(getProperty(PROP_DURATION));\n if (duration == 0) {\n duration = 1;\n }\n } catch (NumberFormatException e) {\n }\n ;\n g2.setPaint(Color.GREEN);\n int barHeight = (int) ((double) getSize().height * ((double) getRemainingTime() / (double) duration));\n Rectangle2D bar = new Rectangle2D.Float(getPos().x - (getSize().width / 2),\n (getPos().y - (getSize().height / 2)) + (getSize().height - barHeight),\n getSize().width, barHeight);\n g2.fill(bar);\n }\n\n // Render instance count if > 0\n if (getInstanceCount() > 0) {\n g2.setPaint(Color.GRAY);\n g2.setFont(new Font(\"Arial Narrow\", Font.BOLD, 12));\n g2.drawString(\"\" + getInstanceCount(),\n getPos().x - ((getSize().width / 2) - 3),\n getPos().y - ((getSize().height / 2) - 12));\n }\n\n g2.setPaint(Color.BLACK);\n g2.draw(outline);\n\n // Set font\n g2.setFont(new Font(\"Arial Narrow\", Font.BOLD, 12));\n\n // Draw text\n if (getText() != null) {\n PetriNetUtils.drawText(g2, getPos().x, getPos().y + (getSize().height / 2),\n 70, getText(), PetriNetUtils.Orientation.TOP);\n }\n\n String metaData = \"\";\n\n // Show cost (if applicable)\n if (getProperty(PROP_COST).length() > 0) {\n metaData += getProperty(PROP_COST) + \"€\";\n }\n\n // Show duration (if applicable)\n if (getProperty(PROP_DURATION).length() > 0) {\n metaData += \" \" + getProperty(PROP_DURATION) + \"s\";\n }\n\n PetriNetUtils.drawText(g2, getPos().x, getPos().y + (getSize().height / 2) + 12,\n 70, metaData, PetriNetUtils.Orientation.TOP);\n\n // Show probability (if applicable)\n if (getProperty(PROP_PROBABILITY).length() > 0) {\n // Don't show 100% probability!\n if (!getProperty(PROP_PROBABILITY).equals(\"100\")) {\n PetriNetUtils.drawText(g2, getPos().x, getPos().y, getSize().width,\n getProperty(PROP_PROBABILITY) + \"%\", PetriNetUtils.Orientation.CENTER);\n }\n }\n }",
"@Override\n\tpublic void paintComponent(Graphics g)\n\t{\n\t\tsuper.paintComponent(g);\n\t\t//Draw the board and the table\n\t\tif (isTableVisible) {\n\t\t\tdrawBackground(this, g, gameInstance);\n\t\t}\n\n\t\tGraphics2D g2 = (Graphics2D)g;\n\t\tRenderingHints rh = new RenderingHints(RenderingHints.KEY_RENDERING,RenderingHints.VALUE_RENDER_QUALITY);\n\t\tg2.setRenderingHints(rh);\n\t\tg2.setTransform(boardToScreenTransformation);\n\t\tdrawPlayerIcons(this, g, gameInstance);\n\t\t//Draw all player related information\n\t\tdrawPlayerPositions(this, g, gameInstance, player, infoText);\n\n\t\t//Draw all objects not in some private area\n\t\tObjectFunctions.getDrawOrder(gameInstance, ial);\n\t\toiList.clear();\n\t\tgameInstance.getObjects(oiList);\n\t\tArrayList<ObjectInstance> drawableObjects = new ArrayList<>();\n\t\tCheckFunctions.drawableObjectsOnTable(oiList, drawableObjects);\n\t\tdrawableObjects.sort(ObjectFunctions.objectInstanceDrawValueComparator);\n\t\tial.clear();\n\t\tObjectFunctions.addObjectListToIdList(drawableObjects, ial);\n\t\tdrawObjectsFromList(this,g,gameInstance,player, ial);\n\n\t\t//Draw selection rectangle\n\t\tdrawSelection(this, g, player);\n\n\t\t//Draw Private Area\n\t\tif (!player.visitor) {\n\t\t\tdrawPrivateArea(this, g);\n\t\t}\n\n\n\t\tAffineTransform tmp = g2.getTransform();\n\t\tg2.setTransform(boardToScreenTransformation);\n\n\t\t//Redraw selected objects not in some private area\n\t\tial.clear();\n\t\tIntegerArrayList selectedObjects = new IntegerArrayList();\n\t\tObjectFunctions.getSelectedObjects(gameInstance, selectedObjects);\n\t\tfor (int id : selectedObjects){\n\t\t ial.addUnique(id);\n\t\t\tObjectFunctions.getAllAboveLyingObjects(gameInstance, player, gameInstance.getObjectInstanceById(id), ial2);\n ial.addUnique(ial2);\n\t\t}\n\t\tObjectFunctions.sortByDrawValue(gameInstance, ial);\n\t\t//ArrayUtil.unifySorted(ial);\n\t\tdrawObjectsFromList(this, g, gameInstance, player, ial, ial2);\n\n\n\t\t//Draw objects in private area\n\t\tif (!player.visitor && privateArea.zooming != 0) {\n\t\t\tdrawTokensInPrivateArea(this, g, gameInstance, player, hoveredObject);\n\t\t}\n\n\n\t\tg2.setTransform(tmp);\n\n\t\t//Draw debug informations\n\t\tif (isDebug) {\n\t\t\tDrawFunctions.drawDebugInfo(this, g2, gameInstance, player);\n\t\t}\n\t\tif (show_ping) {\n\t\t\tg2.drawString(\"Last Signal\", getWidth() - 100, 80);\n\t\t\tfor (int i = 0; i < gameInstance.getPlayerCount(); ++i)\n\t\t\t{\n\t\t\t\tPlayer pl = gameInstance.getPlayerByIndex(i);\n\t\t\t\tg2.drawString(pl.getName() + \" \" + ((System.nanoTime() - pl.lastReceivedSignal) / 100000000) / 10f, getWidth() - 100, 100 + 20 * i);\n\t\t\t}\n\t\t}\n\t}",
"@Override\n protected void paintTrace(Painter aPntr)\n {\n // Get area bounds\n double areaW = getWidth();\n double areaH = getHeight();\n\n // Get whether TraceView/Trace is selected or targeted\n boolean isSelected = isSelectedOrTargeted();\n\n // Get Trace info\n Trace trace = getTrace();\n boolean showLine = trace.isShowLine();\n boolean showPoints = trace.isShowPoints();\n boolean showArea = trace.isShowArea();\n\n // Get DataColor, DataStroke\n Color dataColor = getDataColor();\n Stroke dataStroke = trace.getLineStroke();\n\n // If reveal is not full (1) then clip\n double reveal = getReveal();\n if (reveal < 1 && (showPoints || showArea)) {\n aPntr.save();\n aPntr.clipRect(0, 0, areaW * reveal, areaH);\n }\n\n // If ShowArea, fill path, too\n if (showArea) {\n Shape traceAreaShape = getTraceAreaShape();\n Color traceFillColor = trace.getFillColor();\n aPntr.setColor(traceFillColor);\n aPntr.fill(traceAreaShape);\n }\n\n // Get dataShape (path) (if Reveal is active, get shape as SplicerShape so we can draw partial/animated)\n Shape dataShape = getTraceLineShape();\n if (reveal < 1 && showLine)\n dataShape = new SplicerShape(dataShape, 0, reveal);\n\n // If ShowLine, draw path\n if (isSelected && showLine) {\n aPntr.setStrokePure(true);\n\n // If selected, draw path\n Color selColor = dataColor.blend(Color.CLEARWHITE, .75);\n Stroke selStroke = dataStroke.copyForWidth(dataStroke.getWidth() * 3 + 8).copyForDashes(null);\n aPntr.setColor(selColor);\n aPntr.setStroke(selStroke);\n aPntr.draw(dataShape);\n\n // If selected, draw path\n Color selColor2 = dataColor.blend(Color.WHITE, 1);\n Stroke selStroke2 = dataStroke.copyForWidth(dataStroke.getWidth() + 2);\n aPntr.setColor(selColor2);\n aPntr.setStroke(selStroke2);\n aPntr.draw(dataShape);\n\n aPntr.setStrokePure(false);\n aPntr.setColor(dataColor);\n aPntr.setStroke(dataStroke);\n }\n\n // Set color, stroke\n aPntr.setColor(dataColor);\n aPntr.setStroke(dataStroke);\n\n // If ShowLine, draw path\n if (showLine) {\n aPntr.setStrokePure(true);\n aPntr.draw(dataShape);\n aPntr.setStrokePure(false);\n }\n\n // If Reveal is active, paint TailShape\n if (dataShape instanceof SplicerShape)\n paintTailShape(aPntr, (SplicerShape) dataShape);\n\n // Paint selected point\n if (isSelected)\n paintSelDataPoint(aPntr);\n\n // If ShowPoints or ShowTags\n boolean showTags = trace.isShowTags();\n if (showPoints || showTags)\n _pointPainter.paintSymbolsAndTagsPrep();\n\n // If ShowPoints, paint symbols\n if (showPoints)\n paintSymbols(aPntr);\n\n // If reveal not full, resture gstate\n if (reveal < 1 && (showPoints || showArea))\n aPntr.restore();\n }",
"static void drawCellID() { // draws a cross at each cell centre\n\t\tfloat xc,yc;\n\t\t//GeneralPath path = new GeneralPath();\n\t\tif (currentStage[currentSlice-1]>1)\n\t\t{\n\t\t\tfor (int i=0;i<pop.N;i++)\n\t\t\t{\n\t\t\t\txc = (float) ( (Balloon)(pop.BallList.get(i)) ).x0;\n\t\t\t\tyc = (float) ( (Balloon)(pop.BallList.get(i)) ).y0;\n\t\t\t\tfloat arm = 5;\n\n\t\t\t\t// Label Cell number\n\t\t\t\tTextRoi TROI = new TextRoi((int)xc, (int)yc, (\"\"+i),new Font(\"SansSerif\", Font.BOLD, 12));\n\t\t\t\tTROI.setNonScalable(false);\n\t\t\t\tOL.add(TROI);\n\t\t\t}\n\t\t}\n\t}"
] | [
"0.58000225",
"0.5490354",
"0.5375291",
"0.53751117",
"0.5320353",
"0.52654177",
"0.5245851",
"0.5243434",
"0.5238183",
"0.52375054",
"0.5225035",
"0.51953244",
"0.5171309",
"0.51689166",
"0.5167773",
"0.51565653",
"0.51556486",
"0.5135286",
"0.5132722",
"0.5121215",
"0.5117209",
"0.51053923",
"0.5095523",
"0.509421",
"0.50929713",
"0.5074455",
"0.5072083",
"0.5059174",
"0.5050111",
"0.5048237",
"0.5046201",
"0.5040276",
"0.50125396",
"0.50123674",
"0.5006011",
"0.5002642",
"0.5000752",
"0.4996051",
"0.4990782",
"0.49902147",
"0.49862757",
"0.4982824",
"0.49774557",
"0.49654683",
"0.49593368",
"0.4958045",
"0.49558896",
"0.49521855",
"0.49497646",
"0.49450564",
"0.49403405",
"0.49342102",
"0.4921801",
"0.4920398",
"0.49151638",
"0.49046764",
"0.48977214",
"0.4889874",
"0.48873937",
"0.48837435",
"0.48798624",
"0.48789543",
"0.4878703",
"0.48775306",
"0.48752365",
"0.48706388",
"0.48573115",
"0.4849556",
"0.48489505",
"0.48469183",
"0.48322803",
"0.48294234",
"0.48241636",
"0.4822627",
"0.48166078",
"0.48157638",
"0.481364",
"0.48112273",
"0.48086303",
"0.48044878",
"0.480248",
"0.4799633",
"0.47927415",
"0.47922522",
"0.4789682",
"0.47880942",
"0.47852385",
"0.47847503",
"0.47818577",
"0.47788227",
"0.47785336",
"0.47743595",
"0.47724506",
"0.4771394",
"0.4762855",
"0.4761387",
"0.47606578",
"0.4759781",
"0.47590324",
"0.47586304"
] | 0.6655297 | 0 |
Gets the numberFound value for this FindResults. | public int getNumberFound() {
return numberFound;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void setNumberFound(int numberFound) {\n this.numberFound = numberFound;\n }",
"public int getNumResults() {\r\n\t\treturn this.numResults;\r\n\t}",
"int getNumberOfResults();",
"public int getMissCountNotFound() {\n return missCountNotFound;\n }",
"public long numHits() {\n return numHits.longValue();\n }",
"private int getRecordsCount(final HtmlPage resultPage) {\n if (resultPage == null) {\n return 0;\n }\n \n DomElement countElement = resultPage.getElementById(\"K66\");\n if (countElement == null) {\n return 0;\n }\n \n return Integer.parseInt(countElement.getTextContent().replaceAll(\"[^0-9]\", \"\"), 10);\n }",
"public int getResultsCount() {\n if (resultsBuilder_ == null) {\n return results_.size();\n } else {\n return resultsBuilder_.getCount();\n }\n }",
"public int getResultsCount() {\n if (resultsBuilder_ == null) {\n return results_.size();\n } else {\n return resultsBuilder_.getCount();\n }\n }",
"public int getNumberOfVerticesFound(){\n\t\t\treturn searchOrder.size();\n\t\t}",
"public int getNumResultsPerPage() {\n return numResultsPerPage;\n }",
"org.apache.xmlbeans.XmlInt xgetNumberOfResults();",
"public int getResultsCount() {\n if (resultsBuilder_ == null) {\n return results_.size();\n } else {\n return resultsBuilder_.getCount();\n }\n }",
"public int getResultsCount() {\n return results_.size();\n }",
"public int getSearchResultsCount() {\n return searchResultsList.size();\n }",
"public int countResults() \n {\n return itsResults_size;\n }",
"public int getMatchesRowNumber() {\n\t\tint nMatches = 0;\n\t\tPreparedStatement statement = null;\n\t\tResultSet rs = null;\n\t\tString teamByIdRecords_sql = \"SELECT COUNT(*) FROM \" + match_table;\n\t\tconnection = connector.getConnection();\n\t\ttry {\n\t\t\tstatement = connection.prepareStatement(teamByIdRecords_sql);\n\t\t\trs = statement.executeQuery();\n\t\t\tif (rs.next()) {\n\t\t\t\tnMatches = rs.getInt(1);\n\t\t\t}\n\t\t} catch (Exception e) {\n\t\t\tSystem.out.println(e.getMessage());\n\t\t}\n\t\treturn nMatches;\n\t}",
"private int getSearchHitCount()\r\n {\r\n return ( mFilteringSearchTerm != null ) ? mFilteringSearchTerm.getHitCount() : 0;\r\n }",
"Object getNumberMatched();",
"int findCount();",
"public int getTotalResultsAvailable() {\n\t\tint total = 0;\n\t\tif (results != null) {\n\t\t\tBigInteger count = results.getTotalResultsAvailable();\n\t\t\ttotal = count.intValue();\n\t\t}\n\t\treturn total;\n\t}",
"int getResultsCount();",
"int getResultsCount();",
"public int getResultsPage()\r\n\t{\r\n\t\treturn this.resultsPage;\r\n\t}",
"private int findNumber(String find) {\n String val = \"\";\n // Checks if each for numbers in string and concatenates them to string val\n for (int i = 0; i < find.length(); i++) {\n if (Character.isDigit(find.charAt(i))) {\n val += find.charAt(i);\n }\n // When a non number is found break the loop\n else {\n break;\n }\n }\n // Returns interger value of string val since it represents and index\n return Integer.parseInt(val);\n }",
"public java.math.BigInteger getTotalResults()\n {\n synchronized (monitor())\n {\n check_orphaned();\n org.apache.xmlbeans.SimpleValue target = null;\n target = (org.apache.xmlbeans.SimpleValue)get_store().find_attribute_user(TOTALRESULTS$4);\n if (target == null)\n {\n return null;\n }\n return target.getBigIntegerValue();\n }\n }",
"public int getFoundOffset() { return _foundoffset; }",
"public int getN() {\n return writeResult.getN();\n }",
"public int getCount() {\n return definition.getInteger(COUNT, 1);\n }",
"public int getNumber() {\r\n\t\treturn page.getNumberOfElements();\r\n\t}",
"BigInteger getNumberReturned();",
"@java.lang.Override\n public int getResultsCount() {\n return results_.size();\n }",
"public int getMatches() {\n\t\treturn matches;\n\t}",
"private int getResultsPerPage()\n {\n final int RESULTS_0 = 16;\n final int RESULTS_1 = 32;\n final int RESULTS_2 = 46;\n \n int index = filterNumResults.getSelectedIndex();\n switch(index)\n {\n case 0: return RESULTS_0;\n case 1: return RESULTS_1;\n case 2: return RESULTS_2;\n default: return 0;\n }\n }",
"public int getMaxResults() {\n return _Web_search.getMaxResults();\n }",
"public String fn_searchResultcount() throws Exception {\r\n\t\ttry {\r\n\r\n\t\t\tString count =BreadCrum.getText();\r\n\t\t\tif(count != null) \r\n\t\t\r\n\t\t\treport.logPortalExtentreport(Driver.getDriver(), logger, \"PASS\", \"Expectd :search result should be displayed successfully Actual :search result displayed successfully and values is \"+count, \"search result screen\");\r\n\t\t\treturn count;\r\n\t\t} catch (Exception e) {\r\n\t\t\te.printStackTrace();\r\n\t\t\treport.logPortalExtentreport(Driver.getDriver(), logger, \"FAIL\", \"search result not displayed \" , \"seach result screen\");\r\n\t\t\treturn null;\r\n\t\t}\r\n\t}",
"public java.math.BigInteger getCount()\n {\n synchronized (monitor())\n {\n check_orphaned();\n org.apache.xmlbeans.SimpleValue target = null;\n target = (org.apache.xmlbeans.SimpleValue)get_store().find_attribute_user(COUNT$8);\n if (target == null)\n {\n return null;\n }\n return target.getBigIntegerValue();\n }\n }",
"public int getEmptyResults() {\n return emptyResults.get();\n }",
"@java.lang.Override\n public int getResultsCount() {\n return results_.size();\n }",
"protected int getMaxResults() {\n\t\treturn maxResults;\n\t}",
"@Override\r\n\tpublic int searchTotalCount(SearchCriteria cri) {\n\t\treturn sqlSession.selectOne(namespace + \".searchTotalCount\", cri);\r\n\t}",
"@Override\r\n\tpublic int searchTotalCount(SearchCriteria cri) {\n\t\treturn sqlSession.selectOne(namespace + \".searchTotalCount\", cri);\r\n\t}",
"public int GetSearchByInputCount(SearchMessageVO vo){\r\n\t\treturn SearchPageNum;\r\n\t}",
"Long getNumberOfElement();",
"private int findScore(String dateToFind)\n {\n int k = -1;\n int NOTFOUND = -1;\n for(int i = 0; i < scores.length; i++)\n {\n if(scores[i].getDate().equals(dateToFind))\n {\n k = i;\n break;\n }\n }\n if(k != -1)\n {\n return k;\n }\n else\n {\n return NOTFOUND;\n }\n }",
"public int getN() {\n return n_;\n }",
"public int getN() {\n return n_;\n }",
"public int getN() {\n\t\treturn N;\n\t}",
"public void setNumResults(int numResults) {\n mNumResults = numResults;\n }",
"public int getRecCnt (String where) {\n Vector result = db.select (\"count(*)\",TABLE, where);\n Vector row = (Vector) result.elementAt(0);\n return (new Integer((String) row.elementAt(0)).intValue());\n }",
"public int getN() {\n\t\treturn n;\n\t}",
"public int getN() {\r\n\t\treturn n;\r\n\t}",
"public static int getRecordNum(IQueryResult queryResult) {\r\n Map<String, List<IRecord>> allRecords = queryResult.getRecords();\r\n int n = 0;\r\n for (List<IRecord> values : allRecords.values()) {\r\n n += values.size();\r\n }\r\n return n;\r\n }",
"public int getCount() {\n\t\treturn this.countRound;\n\t}",
"public int getN() {\n return this.n;\n }",
"public int numMatches();",
"public int getNumHits() {\n\t\treturn numHits;\n\t}",
"public int getResultsPerPage()\r\n\t{\r\n\t\treturn this.resultsPerPage;\r\n\t}",
"public int GetNumber() {\n int num = 0;\n for (int i=0; i<m_colourMap.length; i++) {\n if (!(m_colourMap[i].equals(null))) {\n num++; \n }\n }\n return(num);\n }",
"public int getCount() {\n\t\treturn Dispatch.get(object, \"Count\").getInt();\n\t}",
"final int numHits() {\n return numHits;\n }",
"public XPath getCount()\n {\n return m_countMatchPattern;\n }",
"public int numHits() {\r\n\t\treturn hits;\r\n\t}",
"public final long getNearCacheHitCount() {\n\t\treturn m_nearCacheHits;\n\t}",
"public synchronized long getCount(final String token) {\n if (TextUtils.isEmpty(token)) {\n Logger.e(\"Cannot count data without token\");\n return -1L;\n }\n\n Object queryResult = queryExecutor(new QueryExecCallback<Long>() {\n @Override\n public Long execute(SQLiteDatabase db) {\n String query = \"SELECT COUNT(*) FROM \" + TABLE_NAME\n + \" WHERE \" + Columns.TOKEN + \" = \\\"\" + token + \"\\\"\";\n\n long count = -1;\n\n Cursor cursor = db.rawQuery(query, null);\n\n if (cursor != null) {\n cursor.moveToFirst();\n count = cursor.getLong(0);\n cursor.close();\n }\n\n return count;\n }\n });\n\n return queryResult == null ? -1L : (Long) queryResult;\n }",
"public int resultsProcessed() {\n return resultCount;\n }",
"public static int getPageHits() {\r\n return _count;\r\n }",
"public long getTotalHits()\r\n\t{\r\n\t\treturn this.totalHits;\r\n\t}",
"public boolean getFound() {\n\t\treturn found;\n\t}",
"public long getN() {\n return n;\n }",
"public Long get_cachetotparameterizedhits() throws Exception {\n\t\treturn this.cachetotparameterizedhits;\n\t}",
"@Override\n\tpublic int getESFResultsCount()\n\t\tthrows com.liferay.portal.kernel.exception.SystemException {\n\t\treturn _esfResultLocalService.getESFResultsCount();\n\t}",
"private int getTotalPlayerCount() {\n String baseUrl = \"https://www.runescape.com/player_count.js?varname=iPlayerCount\";\n String url = baseUrl + \"&callback=jQuery33102792551319766081_1618634108386&_=\" + System.currentTimeMillis();\n try {\n String response = new NetworkRequest(url, false).get().body;\n Matcher matcher = Pattern.compile(\"\\\\(\\\\d+\\\\)\").matcher(response);\n if(!matcher.find()) {\n throw new Exception();\n }\n return Integer.parseInt(response.substring(matcher.start() + 1, matcher.end() - 1));\n }\n catch(Exception e) {\n return 0;\n }\n }",
"@Override\r\n\tpublic int findNum(int state) {\n\t\treturn sqlSessionTemplate.selectOne(typeNameSpace + \".findNum\", state);\r\n\t}",
"public int getSeenInfoCount() {\n return instance.getSeenInfoCount();\n }",
"public final int getKnownCount()\r\n {\r\n return knownCount;\r\n }",
"@Override\n\tpublic int find(int pValueToFind) {\n\t\tfor (int n = 0; n < pointer; ++n) {\n\t\t\tif (values[n] == pValueToFind) {\n\t\t\t\t// this returns the index position\n\t\t\t\treturn n;\n\t\t\t}\n\t\t}\n\t\treturn -1;\n\t}",
"public int countToMark() {\n\t\tint count = 0;\n\t\tint i = elementCount - 1;\n\t\twhile (i > 0 && !(elementData[i] instanceof PSMark)) {\n\t\t\ti--;\n\t\t\tcount++;\n\t\t}\n\t\treturn (elementData[i] instanceof PSMark) ? count : -1;\n\t}",
"public int getRunningCount() {\r\n return root.getRunningCount();\r\n }",
"public int getMaxSearchResults()\n {\n return maxSearchResults;\n }",
"private int getRecordsCountWithComment(final HtmlPage resultPage) {\n int recordsCount = getRecordsCount(resultPage);\n \n if (resultPage == null || recordsCount == 0) {\n logger.info(\"No results found\");\n return 0;\n } else if (recordsCount > RECORDS_MAX_COUNT) {\n logger.warn(\"Count of records ({}) exceeded the limit of {}\", recordsCount, RECORDS_MAX_COUNT);\n } else {\n logger.info(\"{} records found\", recordsCount);\n }\n\n return recordsCount;\n }",
"public String getResultCountText(){\n\n return searchResultCount.getText();\n\n }",
"public int result() {\n\t\treturn total;\n\t}",
"public long getDigitCount() {\n return digitCount;\n }",
"public Integer getCount() {\n\t\treturn count;\n\t}",
"public Integer getCount() {\n\t\treturn count;\n\t}",
"public int getCount() {\r\n\t\tif(!isValid)\r\n\t\t\treturn -1;\r\n\t\treturn count;\r\n\t}",
"@Override\n\tpublic int totalContentCount(String searchVar) {\n\t\treturn template.selectOne(\"board.totalContentCount\",searchVar);\n\t}",
"public int getN() {\n return n;\n }",
"public String getCount() {\r\n\t\treturn this.count;\r\n\t}",
"public java.lang.Integer getNum () {\r\n\t\treturn num;\r\n\t}",
"public int getResultValue() {\n return mResultValue;\n }",
"public int getResult() {\n\t\t\treturn this.result;\r\n\t\t}",
"public int size() {\n return results.size();\n }",
"public long getCount() {\n return counter.get();\n }",
"public int getMatchingScalar(String token) {\r\n if (getCurrentItem() == null) {\r\n return 0;\r\n }\r\n if (getCurrentItem().getText().equalsIgnoreCase(token)) {\r\n return 1;\r\n } else {\r\n return 0;\r\n }\r\n }",
"public Long get_cachetotflashcachehits() throws Exception {\n\t\treturn this.cachetotflashcachehits;\n\t}",
"public Integer getCount() {\n return this.count;\n }",
"public int getMaxResults() {\n return this.maxResults;\n }",
"public int getNum() {\n\treturn this.n;\n }",
"public Integer getPageItemCount() {\n return pageItemCount;\n }"
] | [
"0.6980832",
"0.66060334",
"0.59357667",
"0.5934272",
"0.5869269",
"0.5855836",
"0.5795568",
"0.57921976",
"0.5783287",
"0.57812613",
"0.5775039",
"0.57596064",
"0.5742045",
"0.56887215",
"0.56875443",
"0.5680711",
"0.5676408",
"0.5603927",
"0.55930114",
"0.55788296",
"0.55574566",
"0.55574566",
"0.55484706",
"0.55260664",
"0.5495476",
"0.54748815",
"0.5471589",
"0.5460198",
"0.5457946",
"0.54501396",
"0.542711",
"0.5397967",
"0.5388216",
"0.5384148",
"0.5379454",
"0.53769493",
"0.53508174",
"0.53266126",
"0.5318767",
"0.53170663",
"0.53170663",
"0.5305945",
"0.5290992",
"0.5275313",
"0.5274162",
"0.5268649",
"0.5253838",
"0.5235467",
"0.5231192",
"0.52278733",
"0.52232116",
"0.52169645",
"0.5216132",
"0.52132493",
"0.5205629",
"0.5205251",
"0.5201803",
"0.5199781",
"0.51996547",
"0.5199251",
"0.5184758",
"0.5182507",
"0.51707083",
"0.51664263",
"0.5163843",
"0.5163688",
"0.5155822",
"0.5140916",
"0.5130956",
"0.51219255",
"0.51182306",
"0.5118141",
"0.51172817",
"0.511689",
"0.5113882",
"0.5101318",
"0.5098348",
"0.5097278",
"0.50899464",
"0.50880945",
"0.5072183",
"0.5067534",
"0.5065651",
"0.5064276",
"0.5064276",
"0.50632286",
"0.50567776",
"0.5051882",
"0.5050175",
"0.5049306",
"0.50487536",
"0.503717",
"0.503406",
"0.5033668",
"0.5030685",
"0.50300777",
"0.50290877",
"0.50224966",
"0.50170124",
"0.5016974"
] | 0.8330713 | 0 |
Sets the numberFound value for this FindResults. | public void setNumberFound(int numberFound) {
this.numberFound = numberFound;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public int getNumberFound() {\n return numberFound;\n }",
"public void setNumResults(int numResults) {\n mNumResults = numResults;\n }",
"public void setFound(boolean found) {\n this.found = found;\n }",
"public void setFound(boolean found) {\n\t\tthis.found = found;\n\t}",
"void setNumberOfResults(int numberOfResults);",
"private void setResultNumber(int number, int totalNumber) {\n mSearchResultsNumb.setText(String.format(\"%s of %s %s\", number, totalNumber, getApplicationContext().getString(R.string.results)));\n }",
"private void updateNumResults(int numResults)\n {\n String message = MessageFormat.format(\"Found {0} results\", numResults);\n resultInfo.setText(message);\n }",
"void setFoundLength(final int foundLength) {\n this.vars.put(\"foundLength\", String.valueOf(foundLength));\n }",
"void setFound(final String found) {\n this.vars.put(\"found\", found);\n }",
"public void setNumResultsPerPage(int newNumResults) {\n this.numResultsPerPage = newNumResults;\n this.pageNumber = 1;\n this.errorMessage = \"\";\n }",
"public void setResults(ArrayOfFindResult results) {\n this.results = results;\n }",
"void xsetNumberOfResults(org.apache.xmlbeans.XmlInt numberOfResults);",
"public void setIsFound(boolean found) {\r\n\t\ttargetFound = found;\r\n\t}",
"public void setTotalResults(Integer totalResults) {\r\n this.totalResults = totalResults;\r\n }",
"public static void setFound(boolean a){\n found = a;\n }",
"public void setResultsPage(int resultsPage)\r\n\t{\r\n\t\tthis.resultsPage = resultsPage;\r\n\t}",
"public void setMatches() {\r\n this.matches++;\r\n\r\n }",
"public int getNumResults() {\r\n\t\treturn this.numResults;\r\n\t}",
"public void setTotalResults(java.math.BigInteger totalResults)\n {\n synchronized (monitor())\n {\n check_orphaned();\n org.apache.xmlbeans.SimpleValue target = null;\n target = (org.apache.xmlbeans.SimpleValue)get_store().find_attribute_user(TOTALRESULTS$4);\n if (target == null)\n {\n target = (org.apache.xmlbeans.SimpleValue)get_store().add_attribute_user(TOTALRESULTS$4);\n }\n target.setBigIntegerValue(totalResults);\n }\n }",
"public void setOccurNumber(int value) {\n this.occurNumber = value;\n }",
"public void setNUMBEROFRECORDS(int value) {\n this.numberofrecords = value;\n }",
"public void setDiscrepancyFound(int discrepancyFound) {\n _discrepancyFound = discrepancyFound;\n }",
"protected void setLookupDataFound(boolean lookupDataFound) {\n this.lookupDataFound = lookupDataFound;\n }",
"public void setResults(ArrayList<Integer> results){\n this.results = results;\n }",
"public void setResultsPerPage(int resultsPerPage)\r\n\t{\r\n\t\tthis.resultsPerPage = resultsPerPage;\r\n\t}",
"public void setNumber(int number) {\r\n\t\tthis.num = number;\r\n\t}",
"public void setCount(XPath v)\n {\n m_countMatchPattern = v;\n }",
"public void setDocumentCount(Integer arg0) {\n \n }",
"private void setFollowersCount() {\n ParseQuery<Follow> query = ParseQuery.getQuery(Follow.class);\n query.whereEqualTo(Follow.KEY_TO, user);\n query.countInBackground((count, e) -> {\n mFollowersTextView.setText(String.valueOf(count));\n });\n }",
"public void setLimitNum(int limitNum) {\r\n this.limitNum = limitNum;\r\n this.endNum = this.skipNum + this.limitNum +1;\r\n }",
"private void find(boolean forward) {\n \tif (this.currentFindResultPage != null) {\n \t\t/* searching again */\n \t\tint nextResultNum = forward ? this.currentFindResultNumber + 1 : this.currentFindResultNumber - 1;\n \t\tif (nextResultNum >= 0 && nextResultNum < this.pagesView.getFindResults().size()) {\n \t\t\t/* no need to really find - just focus on given result and exit */\n \t\t\tthis.currentFindResultNumber = nextResultNum;\n \t\t\tthis.pagesView.scrollToFindResult(nextResultNum);\n \t\t\tthis.pagesView.invalidate();\n \t\t\treturn;\n \t\t}\n \t}\n\n \t/* finder handles next/prev and initial search by itself */\n \tFinder finder = new Finder(this, forward);\n \tThread finderThread = new Thread(finder);\n \tfinderThread.start();\n }",
"public void setCounter(int number){\n this.counter = number;\n }",
"public void incrementNumSearchRequests() {\n this.numSearchRequests.incrementAndGet();\n }",
"@Override\r\n\tpublic void tooManyResults(int nb) {\r\n\t\tmLayout.setText( getString(R.string.directory_too_many_results_warning) );\r\n\t}",
"public void setNumberOfFailedFiles(int value) {\n this.numberOfFailedFiles = value;\n }",
"public final void setN(final int koko) {\r\n this.n = koko;\r\n }",
"private void numberResults ()\r\n {\r\n int partIndex = 0;\r\n\r\n for (Result result : connection.getResultMap().keySet()) {\r\n ScorePart scorePart = (ScorePart) result.getUnderlyingObject();\r\n scorePart.setId(++partIndex);\r\n }\r\n }",
"public void setCount(int value) {\n this.count = value;\n }",
"public void setCount(int value) {\n this.count = value;\n }",
"public void setCount(int value) {\n this.count = value;\n }",
"public void setNumber(int number) {\r\n\t\tthis.number = number;\r\n\t}",
"public void setTotalMatches(int totalMatches) {\r\n\t\tsetValue(Params.TOTAL_MATCHES, totalMatches);\r\n\t}",
"public void setNumVotes(int value) {\n this.numVotes = value;\n }",
"public void setNumber(String name, int value) {\n itemNumbers.put(name, value);\n }",
"public void setDesiredCount(Integer desiredCount) {\n this.desiredCount = desiredCount;\n }",
"public void setNumBalls(int numBalls) {\n this.numBalls += numBalls;\n setScoreText();\n }",
"public int getMissCountNotFound() {\n return missCountNotFound;\n }",
"public void setNumber(int number) {\n\t\tthis.number = number;\n\t}",
"public void setNumber(int number) {\n\t\tthis.number = number;\n\t}",
"public void setNumber(int number) {\n\t\tthis.number = number;\n\t}",
"private void setNoOfRows(int noOfRows) {\n this.noOfRows = noOfRows;\n }",
"public void setNumber(int number) {\n this.number = number;\n }",
"public int getNumResultsPerPage() {\n return numResultsPerPage;\n }",
"@Test\n public void resultNumberTest() throws InterruptedException, ParseException {\n HomePageNavigation.gotoHomePage();\n Thread.sleep(2000);\n SearchNavigation.gotoSearchResultsPage(index,\"\");\n assertTrue(\"Message does not exist\", CommonUtils.extractTotalResults() >= 1);\n }",
"private void setNumber(final int pos, final String number) {\n\t\tif (pos < 0 || pos >= this.objects.size()) {\n\t\t\tPreferences.this.objects.add(number);\n\t\t} else {\n\t\t\tPreferences.this.objects.set(pos, number);\n\t\t}\n\t\tPreferences.this.adapter.notifyDataSetChanged();\n\t}",
"boolean isSetNumberOfResults();",
"void unsetNumberOfResults();",
"void setNumberOfInfantry(int infantry);",
"public void setSelectedNumberOfCluster(int selectedNumberOfCluster) {\n\t\tthis.selectedNumberOfCluster = selectedNumberOfCluster;\n\t}",
"public void increaseNumHits() {\n\t\tthis.numHits += 1;\n\t}",
"private int getRecordsCount(final HtmlPage resultPage) {\n if (resultPage == null) {\n return 0;\n }\n \n DomElement countElement = resultPage.getElementById(\"K66\");\n if (countElement == null) {\n return 0;\n }\n \n return Integer.parseInt(countElement.getTextContent().replaceAll(\"[^0-9]\", \"\"), 10);\n }",
"public final void setFoundPriority(java.lang.Boolean foundpriority)\r\n\t{\r\n\t\tsetFoundPriority(getContext(), foundpriority);\r\n\t}",
"public Builder setResults(\n int index, entities.Torrent.NodeSearchResult value) {\n if (resultsBuilder_ == null) {\n if (value == null) {\n throw new NullPointerException();\n }\n ensureResultsIsMutable();\n results_.set(index, value);\n onChanged();\n } else {\n resultsBuilder_.setMessage(index, value);\n }\n return this;\n }",
"public static void setNumIterations(long aNumIterations) {\n\t\tnumIterations = aNumIterations;\n\t}",
"private void updateRemoteSearchLimit(String maxResults) {\n\t\tif (maxResults != null) {\n\t\t\tif (maxResults.equals(\"0\")) {\n\t\t\t\tmaxResults = getString(R.string.account_settings_remote_search_num_results_entries_all);\n\t\t\t}\n\n\t\t\tmRemoteSearchNumResults\n\t\t\t\t\t.setSummary(String\n\t\t\t\t\t\t\t.format(getString(R.string.account_settings_remote_search_num_summary),\n\t\t\t\t\t\t\t\t\tmaxResults));\n\t\t}\n\t}",
"public Builder setNumOfRetrievelRequest(int value) {\n \n numOfRetrievelRequest_ = value;\n onChanged();\n return this;\n }",
"public Builder setNumOfRetrievelRequest(int value) {\n \n numOfRetrievelRequest_ = value;\n onChanged();\n return this;\n }",
"public void setCount(int newCount) {\r\n\t\tcount = newCount;\r\n\t}",
"void setNumber(int num) {\r\n\t\tnumber = num;\r\n\t}",
"public Pagination(int numResults, int offset) {\r\n\t\tthis.numResults = numResults;\r\n\t\tthis.offset = offset;\r\n\t}",
"public void setOneNewWanted () {\r\n numWanted ++;\r\n }",
"private void setLikesCount(int value) {\n \n likesCount_ = value;\n }",
"int getNumberOfResults();",
"public void setNumToProcess(long aNumToProcess) {\n numToProcess = aNumToProcess;\n }",
"public void setNumber(int number)\n {\n this.number = number;\n }",
"private void setFollowingCount() {\n ParseQuery<Follow> query = ParseQuery.getQuery(Follow.class);\n query.whereEqualTo(Follow.KEY_FROM, user);\n query.countInBackground((count, e) -> {\n mFollowingTextView.setText(String.valueOf(count));\n });\n }",
"public void setMaxResults(Integer maxResults) {\n this.maxResults = maxResults;\n }",
"public void setMaxResults(Integer maxResults) {\n this.maxResults = maxResults;\n }",
"public void setMaxResults(Integer maxResults) {\n this.maxResults = maxResults;\n }",
"public void setMaxResults(Integer maxResults) {\n this.maxResults = maxResults;\n }",
"public void setMaxResult(int maxResult) {\n this.maxResult = maxResult;\n }",
"public void setNoOfImages(int noOfImages) {\n this.noOfImages = noOfImages;\n }",
"XResultSet() {\n this.nodeRefs = new LinkedList<>();\n this.numberFound = 0;\n }",
"public int getNumberOfVerticesFound(){\n\t\t\treturn searchOrder.size();\n\t\t}",
"public final void setFoundCI(java.lang.Boolean foundci)\r\n\t{\r\n\t\tsetFoundCI(getContext(), foundci);\r\n\t}",
"public void setDocumentNumber(java.lang.String newDocumentNumber) {\n\tdocumentNumber = newDocumentNumber;\n}",
"public Builder setResults(\n int index, entities.Torrent.NodeSearchResult.Builder builderForValue) {\n if (resultsBuilder_ == null) {\n ensureResultsIsMutable();\n results_.set(index, builderForValue.build());\n onChanged();\n } else {\n resultsBuilder_.setMessage(index, builderForValue.build());\n }\n return this;\n }",
"public void setDocumentNumber(java.lang.String newValue) {\n\tthis.documentNumber = newValue;\n}",
"public void setNumMarkersTraversed(int numMarkersTraversed) {\n\t\tthis.numMarkersTraversed = numMarkersTraversed;\n\t}",
"public void setAfterResult(Integer afterResult) {\r\n this.afterResult = afterResult;\r\n }",
"public static int setStudentNumber(){\n countNumbers++;//1 2 3\n return countNumbers;\n\n }",
"public static void setCount(int aCount) {\n count = aCount;\n }",
"public int countResults() \n {\n return itsResults_size;\n }",
"public void setPrevCount(double n)\n {\n\n this.prevCount = n;\n }",
"protected void maybeSetResultPropertyValue(int result) {\r\n String res = Integer.toString(result);\r\n if (resultProperty != null) {\r\n getProject().setNewProperty(resultProperty, res);\r\n }\r\n }",
"@Override\n public void setNrPlayers(int value) {\n this.nrPlayers = value;\n }",
"public void setMaxSearchResults(int maxSearchResults)\n {\n this.maxSearchResults = maxSearchResults;\n }",
"public void setResult(int result) {\n this.result = result;\n this.isSix = this.result == 6;\n }",
"public void setUpdateOften(int i){\n countNum = i;\n }",
"@Override\n protected void beforeSearch() {\n index = 0;\n numberOfIterations = 0;\n pageCounter = 0;\n }"
] | [
"0.67392755",
"0.6708389",
"0.6307225",
"0.6248499",
"0.62272424",
"0.60467875",
"0.5939983",
"0.58480304",
"0.58008283",
"0.5708843",
"0.5513861",
"0.5507426",
"0.53045416",
"0.5260035",
"0.5163092",
"0.5120572",
"0.5112751",
"0.50741833",
"0.5072142",
"0.5054786",
"0.5042276",
"0.5006726",
"0.49651995",
"0.49182925",
"0.49080765",
"0.4892648",
"0.48727706",
"0.48584425",
"0.48567873",
"0.4801787",
"0.47940588",
"0.47727993",
"0.47584736",
"0.47529623",
"0.47467932",
"0.47418827",
"0.47240987",
"0.4710065",
"0.4710065",
"0.4710065",
"0.4663269",
"0.4662237",
"0.4650208",
"0.4639677",
"0.46168435",
"0.4606614",
"0.45989528",
"0.45988435",
"0.45988435",
"0.45988435",
"0.45947322",
"0.45923537",
"0.45819625",
"0.45784432",
"0.45746896",
"0.4572246",
"0.45718685",
"0.4569728",
"0.45634475",
"0.45627686",
"0.45603067",
"0.4548258",
"0.4547951",
"0.45374337",
"0.45292887",
"0.45245755",
"0.45245755",
"0.45166352",
"0.4515668",
"0.4494924",
"0.44887745",
"0.44867116",
"0.4477715",
"0.44750372",
"0.44742",
"0.44709298",
"0.4466002",
"0.4466002",
"0.4466002",
"0.4466002",
"0.4465766",
"0.44590935",
"0.4442172",
"0.44367468",
"0.44340906",
"0.443352",
"0.4431456",
"0.44307655",
"0.4427398",
"0.4420754",
"0.44182447",
"0.44127667",
"0.4408116",
"0.44045773",
"0.4397432",
"0.43973756",
"0.43835407",
"0.43791634",
"0.43759117",
"0.43729407"
] | 0.872495 | 0 |
Gets the startIndex value for this FindResults. | public int getStartIndex() {
return startIndex;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public final int getStartIndex() {\n\t\treturn startIndex;\n\t}",
"public int getStartIndex() {\r\n\t\treturn startIndex;\r\n\t}",
"public int getStartIndex() {\n\t\treturn startIndex;\n\t}",
"public int getStartIndex() {\n return this.startIndex;\n }",
"public int getStartIndex() {\n return this.startIndex;\n }",
"public java.math.BigInteger getStartIndex()\n {\n synchronized (monitor())\n {\n check_orphaned();\n org.apache.xmlbeans.SimpleValue target = null;\n target = (org.apache.xmlbeans.SimpleValue)get_store().find_attribute_user(STARTINDEX$10);\n if (target == null)\n {\n return null;\n }\n return target.getBigIntegerValue();\n }\n }",
"public final native double getStartIndex() /*-{\n return this.getStartIndex();\n }-*/;",
"public com.a9.spec.opensearch.x11.QueryType.StartIndex xgetStartIndex()\n {\n synchronized (monitor())\n {\n check_orphaned();\n com.a9.spec.opensearch.x11.QueryType.StartIndex target = null;\n target = (com.a9.spec.opensearch.x11.QueryType.StartIndex)get_store().find_attribute_user(STARTINDEX$10);\n return target;\n }\n }",
"public int getStartIdx() {\n return this.startIdx;\n }",
"public int getStartIndex() {\n int cacheRange = 100 / numResultsPerPage;\n int base = pageNumber % cacheRange;\n if (base == 0) {\n return 100 - numResultsPerPage;\n } else {\n return (base - 1) * numResultsPerPage;\n }\n }",
"public int getStartOffset() {\n return startPosition.getOffset();\n }",
"public long getStartOffset() {\n return mStartOffset;\n }",
"@XmlAttribute\r\n public Integer getStartIndex() {\r\n return startIndex;\r\n }",
"public OptionalInt getStartOffset() {\n return startOffset >= 0 ? OptionalInt.of(startOffset) : OptionalInt.empty();\n }",
"public int getStart() {\r\n\t\treturn this.offset;\r\n\t}",
"public int getStartOffset() {\n if (view != null) {\n return view.getStartOffset();\n }\n return getElement().getStartOffset();\n }",
"public int getStartOffset() {\n return startOffset;\n }",
"public abstract int getStartIndex();",
"public int startIndex(){\n\t\tswitch (this) {\n\t\t\tcase ORCHESTRA:\n\t\t\t\treturn 0;\n\t\t\tcase MAIN:\n\t\t\t\treturn ORCHESTRA.getRows();\n\t\t\tcase BALCONY1:\n\t\t\t\treturn ORCHESTRA.getRows()+MAIN.getRows();\n\t\t\tdefault:\n\t\t\t\treturn ORCHESTRA.getRows()+MAIN.getRows()+BALCONY1.getRows();\n\t\t}\n\t}",
"int getStartSearch();",
"public java.lang.Integer getStartResult()\n {\n return this.startResult;\n }",
"private int getIndexOfStart(String document, int indexOfEnd) {\n int indexOfStart = -1;\n // iterate the document backwards until '>' is found\n for (int i = indexOfEnd; i >= 0 ; i--) {\n char c = document.charAt(i);\n if (c == '>') {\n indexOfStart = i + 1;\n break;\n }\n }\n return indexOfStart;\n }",
"public int restrictionStart() {\n return mRestriction == null ? -1 : mRestriction.getStart();\n }",
"private int getInclusiveTopIndexStartOffset() {\n \n \t\tif (fTextWidget != null && !fTextWidget.isDisposed()) {\n \t\t\tint top= -1;\n \t\t\tif (fSourceViewer instanceof ITextViewerExtension5) {\n \t\t\t\ttop= fTextWidget.getTopIndex();\n \t\t\t\tif ((fTextWidget.getTopPixel() % fTextWidget.getLineHeight()) != 0)\n \t\t\t\t\ttop--;\n \t\t\t\tITextViewerExtension5 extension= (ITextViewerExtension5) fSourceViewer;\n \t\t\t\ttop= extension.widgetLine2ModelLine(top);\n \t\t\t} else {\n \t\t\t\ttop= fSourceViewer.getTopIndex();\n \t\t\t\tif ((fTextWidget.getTopPixel() % fTextWidget.getLineHeight()) != 0)\n \t\t\t\t\ttop--;\n \t\t\t}\n \n \t\t\ttry {\n \t\t\t\tIDocument document= fSourceViewer.getDocument();\n \t\t\t\treturn document.getLineOffset(top);\n \t\t\t} catch (BadLocationException x) {\n \t\t\t}\n \t\t}\n \n \t\treturn -1;\n \t}",
"public int getStart() {\n return this.start;\n }",
"public int getRangeStart() {\n return currentViewableRange.getFrom();\n }",
"public final int startOffset() {\n return startOffset;\n }",
"public int getAllTextStartOffset ()\n {\n\n return this.getStart ();\n\n }",
"public void setStartIndex(Integer startIndex) {\r\n this.startIndex = startIndex;\r\n }",
"public int getStart() {\n\t\t\treturn start;\n\t\t}",
"public int getStartX() {\r\n\t\treturn startX;\r\n\t}",
"@Override\n\tpublic int getStartOffset() {\n\t\treturn 0;\n\t}",
"public int getStartRange() {\r\n\t\treturn lookupValue(Params.START_RANGE);\r\n\t}",
"public int getStart() {\r\n\t\treturn start;\r\n\t}",
"org.hl7.fhir.Integer getStart();",
"public int getStart() {\n\t\treturn start;\n\t}",
"public int getStart() {\r\n return start;\r\n }",
"public int getPageStart() {\n return _totalRecords == 0 ? 0 : ((_pageIndex) * _pageSize) + 1;\n }",
"public int getStart() {\n return start;\n }",
"public abstract long getStartOffset();",
"public int getStart() {\n return start;\n }",
"public int getStartLineNumber() {\n return startLineNumber_;\n }",
"Long getStartAt();",
"public int getStartLineNumber() {\n return startLineNumber_;\n }",
"public static int getRowStartFromLineOffset(BaseDocument doc, int lineIndex) {\n Element lineRoot = doc.getParagraphElement(0).getParentElement();\n if (lineIndex < 0 || lineIndex >= lineRoot.getElementCount()) {\n return -1; // invalid line number\n\n } else {\n return lineRoot.getElement(lineIndex).getStartOffset();\n }\n }",
"public int startOffset();",
"public int findGeneStart()\n {\n return findGeneStart(0);\n }",
"int getStartCharIndex();",
"public void setStartIndex(int startIndex) {\n this.startIndex = startIndex;\n }",
"public int getStartLine() {\r\n return this.startLine;\r\n }",
"public int getStartPosition() {\n return startPosition_;\n }",
"@Override\n public final int getBeginIndex() {\n return lower;\n }",
"public RefLimit getStartFrom() {\n\t\t\treturn startFrom;\n\t\t}",
"public Integer getBeginOffset() {\n return this.beginOffset;\n }",
"public int getStartPosition() {\n return startPosition_;\n }",
"public int getStartField()\n {\n return this.startField;\n }",
"public int getStart()\n {\n return start;\n }",
"public RefLimit getStartFrom() {\n\t\treturn startFrom;\n\t}",
"public int getStartPos() {\n return startPos;\n }",
"public int getBegin() {\n if (Span_Type.featOkTst && ((Span_Type)jcasType).casFeat_Begin == null)\n jcasType.jcas.throwFeatMissing(\"Begin\", \"Span\");\n return jcasType.ll_cas.ll_getIntValue(addr, ((Span_Type)jcasType).casFeatCode_Begin);}",
"@Pure\n public int getStartLine() {\n return this.startLine;\n }",
"public void setStartIndex(int startIndex) {\n\t\tthis.startIndex = startIndex;\n\t}",
"public final native void setStartIndex(double startIndex) /*-{\n this.setStartIndex(startIndex);\n }-*/;",
"Constant getStartOffsetConstant();",
"public int getStartx(){\n\t\treturn startx;\n\t}",
"public void setStartIndex(java.math.BigInteger startIndex)\n {\n synchronized (monitor())\n {\n check_orphaned();\n org.apache.xmlbeans.SimpleValue target = null;\n target = (org.apache.xmlbeans.SimpleValue)get_store().find_attribute_user(STARTINDEX$10);\n if (target == null)\n {\n target = (org.apache.xmlbeans.SimpleValue)get_store().add_attribute_user(STARTINDEX$10);\n }\n target.setBigIntegerValue(startIndex);\n }\n }",
"public int getFirstIndex() {\n return firstIndex;\n }",
"@Override\r\n \tpublic final int getStartPos() {\r\n \t\treturn sourceStart;\r\n \t}",
"public int sourceStart()\n\t{\n\t\treturn sourceStart;\n\t}",
"public int getPageStart(){\r\n\t\treturn (this.page -1) * perPageNum;\r\n\t}",
"public int getQueryStart()\n\t{\n\t\treturn myQueryStart;\n\t}",
"public int getStart ()\r\n {\r\n return glyph.getBounds().x;\r\n }",
"public int getLineNumber() {\n\t\t\treturn startLineNumber;\n\t\t}",
"public int getCharStart() {\n\t\treturn -1;\n\t}",
"public java.math.BigInteger getStartPage()\n {\n synchronized (monitor())\n {\n check_orphaned();\n org.apache.xmlbeans.SimpleValue target = null;\n target = (org.apache.xmlbeans.SimpleValue)get_store().find_attribute_user(STARTPAGE$12);\n if (target == null)\n {\n return null;\n }\n return target.getBigIntegerValue();\n }\n }",
"public Position getStart() {\r\n return start;\r\n }",
"@Override\n public int getStart() {\n return feature.getStart();\n }",
"public int getTagStart (int tagIndex) {\n int tagCount = -1;\n int i = 0;\n int start = 0;\n int end = 0;\n while (i < tags.length() && tagCount < tagIndex) {\n start = indexOfNextWordStart (tags, i, slashToSeparate);\n end = indexOfNextSeparator (tags, start, false, true, slashToSeparate);\n tagCount++;\n if (tagCount < tagIndex) {\n i = end + 1;\n }\n }\n if (tagCount < tagIndex) {\n return tags.length();\n } else {\n return start;\n }\n }",
"public int getStartRow();",
"public void setStartIndex(final int startIndex) {\r\n\t\tthis.startIndex = startIndex;\r\n\t}",
"int getStartLineNumber();",
"public int getStart ()\n {\n\n return this.start;\n\n }",
"public int getWordStart (int wordIndex) {\n int wordCount = -1;\n int i = 0;\n int start = 0;\n int end = 0;\n while (i < tags.length() && wordCount < wordIndex) {\n start = indexOfNextWordStart (tags, i, slashToSeparate);\n end = indexOfNextSeparator (tags, start, true, true, slashToSeparate);\n wordCount++;\n if (wordCount < wordIndex) {\n i = end + 1;\n }\n }\n return start;\n }",
"public int getPageStartEntry() {\n\t\treturn this.skipEntries;\n\t}",
"public int getBegin() {\n\t\treturn begin;\n\t}",
"public BigInteger getStartValue()\r\n {\r\n return this.startValue;\r\n }",
"String getFirstIndex();",
"public int getLimitStart() {\n return limitStart;\n }",
"public int getLimitStart() {\n return limitStart;\n }",
"public int getLimitStart() {\n return limitStart;\n }",
"public String getStartStr() {\r\n return startStr;\r\n }",
"public Integer getCaretPosX() {\n\t\tint[] caretPos = getCaretPos();\n\t\treturn (caretPos == null) ? null : caretPos[0];\n\t}",
"@Pure\n public Integer getStartCharacter() {\n return this.startCharacter;\n }",
"public int getStartIndex(Color col) {\n\t\tint startIndex;\n\t\tswitch (col) {\n\t\t\tcase RED:\n\t\t\t\tstartIndex = RED_START;\n\t\t\t\tbreak;\n\t\t\tcase GREEN:\n\t\t\t\tstartIndex = GREEN_START;\n\t\t\t\tbreak;\n\t\t\tcase YELLOW:\n\t\t\t\tstartIndex = YELLOW_START;\n\t\t\t\tbreak;\n\t\t\tdefault:\n\t\t\t\tstartIndex = BLUE_START;\n\t\t}\n\t\treturn startIndex;\n\t}",
"public double getStartX() {\n\treturn v1.getX();\n }",
"@NotNull\r\n public DateWithOffset getStartDate() {\r\n checkStartDate();\r\n return startDate;\r\n }",
"public int getSearchIndex() \n\t{\n\t\treturn itemSearchIndex;\n\t}",
"public int getStartVertex() {\n\t\treturn startVertex;\n\t}",
"private Integer serialSearch() {\n int currentIndex = startIndex;\n for (int i = start; i < end; i++) {\n if (this.searchIndex == currentIndex) {\n return currentIndex;\n }\n currentIndex++;\n }\n return 0;\n }",
"public int getFirstPosition() {\n return mFirstPosition;\n }"
] | [
"0.7577449",
"0.75427186",
"0.7509301",
"0.73473567",
"0.73473567",
"0.72690505",
"0.70996135",
"0.6890874",
"0.6887727",
"0.6845071",
"0.68002796",
"0.66147804",
"0.6600962",
"0.6519164",
"0.64488894",
"0.640247",
"0.63164014",
"0.6266795",
"0.6245718",
"0.6134221",
"0.6053335",
"0.6047562",
"0.603511",
"0.60119057",
"0.6010182",
"0.6000666",
"0.5974655",
"0.5971614",
"0.5942991",
"0.59036547",
"0.58890104",
"0.58818555",
"0.5881674",
"0.58813083",
"0.5874589",
"0.5839807",
"0.5831545",
"0.582431",
"0.5823685",
"0.5812682",
"0.58061594",
"0.578254",
"0.5776232",
"0.5763348",
"0.57128775",
"0.5700522",
"0.5698894",
"0.5689832",
"0.56729937",
"0.5672625",
"0.56552047",
"0.562979",
"0.5629611",
"0.56118613",
"0.5610262",
"0.56081945",
"0.55883265",
"0.5576392",
"0.5565663",
"0.5561906",
"0.55542016",
"0.5551227",
"0.5521931",
"0.55178934",
"0.5511624",
"0.5506417",
"0.54892826",
"0.5468606",
"0.5464134",
"0.5454093",
"0.54488945",
"0.54435986",
"0.54395616",
"0.5431273",
"0.5429902",
"0.5402787",
"0.53957564",
"0.5380384",
"0.5363024",
"0.535925",
"0.53541815",
"0.53530705",
"0.534919",
"0.5328119",
"0.5326604",
"0.53139025",
"0.5285257",
"0.5260815",
"0.5260815",
"0.5260815",
"0.5260724",
"0.5255869",
"0.525168",
"0.52426326",
"0.5223907",
"0.5222749",
"0.52219284",
"0.5219149",
"0.5219137",
"0.5211215"
] | 0.7484971 | 3 |
Sets the startIndex value for this FindResults. | public void setStartIndex(int startIndex) {
this.startIndex = startIndex;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void setStartIndex(int startIndex) {\n\t\tthis.startIndex = startIndex;\n\t}",
"public void setStartIndex(final int startIndex) {\r\n\t\tthis.startIndex = startIndex;\r\n\t}",
"public void setStartIndex(Integer startIndex) {\r\n this.startIndex = startIndex;\r\n }",
"public void setStartIndex(java.math.BigInteger startIndex)\n {\n synchronized (monitor())\n {\n check_orphaned();\n org.apache.xmlbeans.SimpleValue target = null;\n target = (org.apache.xmlbeans.SimpleValue)get_store().find_attribute_user(STARTINDEX$10);\n if (target == null)\n {\n target = (org.apache.xmlbeans.SimpleValue)get_store().add_attribute_user(STARTINDEX$10);\n }\n target.setBigIntegerValue(startIndex);\n }\n }",
"public final native void setStartIndex(double startIndex) /*-{\n this.setStartIndex(startIndex);\n }-*/;",
"public void xsetStartIndex(com.a9.spec.opensearch.x11.QueryType.StartIndex startIndex)\n {\n synchronized (monitor())\n {\n check_orphaned();\n com.a9.spec.opensearch.x11.QueryType.StartIndex target = null;\n target = (com.a9.spec.opensearch.x11.QueryType.StartIndex)get_store().find_attribute_user(STARTINDEX$10);\n if (target == null)\n {\n target = (com.a9.spec.opensearch.x11.QueryType.StartIndex)get_store().add_attribute_user(STARTINDEX$10);\n }\n target.set(startIndex);\n }\n }",
"void setStartSearch(int startSearch);",
"public void setStartElement(final int startIdx) {\r\n\t\tgetState().start = startIdx;\r\n\t}",
"public int getStartIndex() {\r\n\t\treturn startIndex;\r\n\t}",
"public void setFromIndex(long fromIndex) {\n this.fromIndex = fromIndex;\n }",
"public final int getStartIndex() {\n\t\treturn startIndex;\n\t}",
"public int getStartIndex() {\n\t\treturn startIndex;\n\t}",
"public int getStartIndex() {\n return startIndex;\n }",
"public void setStartOffset(int offset) {\n this.startOffset = offset;\n }",
"public int getStartIndex() {\n return this.startIndex;\n }",
"public int getStartIndex() {\n return this.startIndex;\n }",
"@XmlAttribute\r\n public Integer getStartIndex() {\r\n return startIndex;\r\n }",
"DbQuery setStartAtFilter(String value) {\n filter = Filter.START;\n filterType = FilterType.STRING;\n this.startAt = value;\n return this;\n }",
"void setStartAt(final Long startAt);",
"public void setStartOffset(String offset) {\n\t\ttry {\n\t\t\tstartOffset = Integer.parseInt(offset);\n\t\t} catch (Exception e) {\n\t\t\tstartOffset = 0;\n\t\t}\n\t}",
"public void setStartLine(final int startLine) {\n this.startLine = startLine;\n }",
"public void setStartLine(int startLine) {\r\n this.startLine = startLine;\r\n }",
"public Builder setStartLineNumber(int value) {\n bitField0_ |= 0x00000020;\n startLineNumber_ = value;\n onChanged();\n return this;\n }",
"public void setStart(int start) {\r\n this.start = start;\r\n }",
"public CS228ListIterator(int startIndex) {\r\n\t\t\t// TODO ...test\r\n\t\t\tcaret = new Caret();\r\n\t\t\tint idxCount = 0;\r\n\t\t\tfor (Node n = head.next; n != tail; n = n.next) {\r\n\t\t\t\tfor (int i = 0; i < n.data.length; i++) {\r\n\t\t\t\t\tif (n.data[i] != null)\r\n\t\t\t\t\t\tidxCount++;\r\n\t\t\t\t\tif (idxCount == startIndex) {\r\n\t\t\t\t\t\tcaret.n = n;\r\n\t\t\t\t\t\tcaret.idx = i;\r\n\t\t\t\t\t\treturn;\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}",
"public void setStartPos(int startPos) {\r\n this.startPos = startPos;\r\n }",
"public void setStartPos(int startPos) {\n this.startPos = startPos;\n }",
"public void setStart(int start) {\n this.start=start;\n }",
"public final void setStartRow(java.lang.Integer startrow)\r\n\t{\r\n\t\tsetStartRow(getContext(), startrow);\r\n\t}",
"public void setStart(int start) {\n\t\tthis.start = start;\n\t}",
"void setNilSearchRecurrenceStart();",
"public void setStartPage(java.math.BigInteger startPage)\n {\n synchronized (monitor())\n {\n check_orphaned();\n org.apache.xmlbeans.SimpleValue target = null;\n target = (org.apache.xmlbeans.SimpleValue)get_store().find_attribute_user(STARTPAGE$12);\n if (target == null)\n {\n target = (org.apache.xmlbeans.SimpleValue)get_store().add_attribute_user(STARTPAGE$12);\n }\n target.setBigIntegerValue(startPage);\n }\n }",
"public void reset() {\n this.index = this.startIndex;\n }",
"public void setBeginOffset(Integer beginOffset) {\n this.beginOffset = beginOffset;\n }",
"public void unsetStartIndex()\n {\n synchronized (monitor())\n {\n check_orphaned();\n get_store().remove_attribute(STARTINDEX$10);\n }\n }",
"void startIndexing();",
"public Builder setStartPosition(int value) {\n bitField0_ |= 0x00000008;\n startPosition_ = value;\n onChanged();\n return this;\n }",
"void setSearchWindowStart(java.util.Calendar searchWindowStart);",
"public void setStart(int start)\n {\n if(start >= 0)\n {\n this.start = start;\n }\n else\n {\n System.out.println(\"Cannot be negative.\");\n }\n }",
"public void setStartPage(int value) {\n this.startPage = value;\n }",
"public void setStart(int startId) throws IllegalArgumentException, IllegalStateException;",
"public void setLimitStart(int limitStart) {\n this.limitStart=limitStart;\n }",
"public void setLimitStart(int limitStart) {\n this.limitStart=limitStart;\n }",
"public void setLimitStart(int limitStart) {\n this.limitStart=limitStart;\n }",
"public void setStartDate(@NotNull DateWithOffset startDate) {\r\n if (startDate == null) { // NOSONAR\r\n throw new NullPointerException(\"startDate\");\r\n }\r\n this.startDate = startDate;\r\n }",
"public void setStartLineNumber(int foo) { startLineNumber = foo; }",
"public final native double getStartIndex() /*-{\n return this.getStartIndex();\n }-*/;",
"public void setSourceStart(int x)\n\t{\n\t\tsourceStart = x;\n\t}",
"public void xsetStartPage(com.a9.spec.opensearch.x11.QueryType.StartPage startPage)\n {\n synchronized (monitor())\n {\n check_orphaned();\n com.a9.spec.opensearch.x11.QueryType.StartPage target = null;\n target = (com.a9.spec.opensearch.x11.QueryType.StartPage)get_store().find_attribute_user(STARTPAGE$12);\n if (target == null)\n {\n target = (com.a9.spec.opensearch.x11.QueryType.StartPage)get_store().add_attribute_user(STARTPAGE$12);\n }\n target.set(startPage);\n }\n }",
"public void setIteratorBegin() {\n iter = (next > 0 ? 0 : -1);\n }",
"public void setLimitStart(Integer limitStart) {\r\n this.limitStart=limitStart;\r\n }",
"public void setStartStr(String startStr) {\r\n this.startStr = startStr;\r\n }",
"public void setBeginLineNumber(int beginLine) {\n this.beginLine = beginLine;\n }",
"public void setBegin(int begin) {\n\t\tthis.begin = begin;\n\t}",
"public void setLineToStart(final int lineToStart) {\r\n\t\tthis.lineToStart = lineToStart;\r\n\t}",
"public Builder setScrollOffsetX(int value) {\n copyOnWrite();\n instance.setScrollOffsetX(value);\n return this;\n }",
"public void setStartTestNumber(int startTestNumber) {\n\t\tthis.nextTestNumber = startTestNumber;\n\t}",
"public void setStartTestNumber(int startTestNumber) {\n\t\tthis.nextTestNumber = startTestNumber;\n\t}",
"public void setFirstResult(int begin) {\n\r\n\t}",
"DbQuery setStartAtFilter(double value) {\n filter = Filter.START;\n filterType = FilterType.DOUBLE;\n this.startAt = value;\n return this;\n }",
"public void setCaretIndex(int index) {\r\n\t\tcalculateCaretLine(index);\r\n\t}",
"public void setStartsWith(String startsWith) {\n\t\tthis.startsWith = startsWith;\n\t}",
"public QuantificationDefinition setMinIndex(int minIndex) {\n assert minIndex >= 0;\n this.minIndex = minIndex;\n return this;}",
"void setFirstResult(int offset);",
"void setStartSegment(int startSegment);",
"public void setStartPage(String startPage) {\r\n this.startPage = startPage;\r\n }",
"public void setStartPoint(int s) {\r\n\t\tstartPoint = s;\r\n\t}",
"public abstract int getStartIndex();",
"public void setRangeStart(@IntRange(from = MIN_NUMBER) long start) {\n setRange(start, mRange, mIsPositive);\n }",
"public Builder setStartDate(long value) {\n \n startDate_ = value;\n onChanged();\n return this;\n }",
"public void setBegin(int begin)\n {\n this.begin = begin;\n this.beginSpecified = true;\n }",
"public void setStartX(float startX) {this.startX = startX;}",
"public static ResultSetIterator iterator(ResultSet rs, int startIndex) {\r\n\t\treturn new ResultSetIterator(rs, startIndex);\r\n\t}",
"public void start(int range) {\n start(mRangeStart, range, mIsPositive);\n }",
"@Override\n\tpublic void setStartDate(Date startDate) {\n\t\tmodel.setStartDate(startDate);\n\t}",
"void setSearchRecurrenceStart(java.util.Calendar searchRecurrenceStart);",
"DbQuery setStartAtFilter(int value) {\n return setStartAtFilter((double) value);\n }",
"@Override\n\tpublic void setStartDate(java.util.Date startDate) {\n\t\t_esfTournament.setStartDate(startDate);\n\t}",
"public void setStartVertex(int v){\r\n if (v < myVertexCount && v >= 0){\r\n myStartVertex = v;\r\n } else {\r\n throw new IllegalArgumentException(\"Cannot set iteration start vertex to \" + v + \".\");\r\n }\r\n }",
"public void setStartVertex(int v){\n if (v < myVertexCount && v >= 0){\n myStartVertex = v;\n } else {\n throw new IllegalArgumentException(\"Cannot set iteration start vertex to \" + v + \".\");\n }\n }",
"void setBeginRange( String beginRange );",
"public void setStartVertex(int v){\n if (v < vertexCount && v >= 0){\n startVertex = v;\n } else {\n throw new IllegalArgumentException(\"Cannot set iteration start vertex to \" + v + \".\");\n }\n }",
"private void setScrollOffsetX(int value) {\n bitField0_ |= 0x00000010;\n scrollOffsetX_ = value;\n }",
"public void setStartDate(String startDate) throws ParseException {\n SimpleDateFormat dateFormat = new SimpleDateFormat(\"yyyy-MM-dd\");\n this.startDate = dateFormat.parse(startDate);\n }",
"public void setLimit(int start, int limit) {\n this.start = start;\n this.limit = limit;\n }",
"public void setStart(long start) { this.start = start; }",
"public int getStartIdx() {\n return this.startIdx;\n }",
"public final void setStartRow(com.mendix.systemwideinterfaces.core.IContext context, java.lang.Integer startrow)\r\n\t{\r\n\t\tgetMendixObject().setValue(context, MemberNames.StartRow.toString(), startrow);\r\n\t}",
"public void setFontStartTag(String value) {\r\n\t\t_fontTagStart = value;\r\n\t}",
"void setBeginInclusive( boolean beginInclusive );",
"public void setStartYear(java.math.BigInteger startYear) {\r\n this.startYear = startYear;\r\n }",
"public void setStartingPage(int startingPage) {\n if(startingPage <= 0){\n this.startingPage = 1;\n }else{\n this.startingPage = startingPage;\n }\n }",
"public com.a9.spec.opensearch.x11.QueryType.StartIndex xgetStartIndex()\n {\n synchronized (monitor())\n {\n check_orphaned();\n com.a9.spec.opensearch.x11.QueryType.StartIndex target = null;\n target = (com.a9.spec.opensearch.x11.QueryType.StartIndex)get_store().find_attribute_user(STARTINDEX$10);\n return target;\n }\n }",
"public void setFromIndexName(String fromIndexName) {\n this.fromIndexName = fromIndexName;\n }",
"public void setStartNode(String startNode)\r\n\t{\r\n\t\tthis.startNode = startNode;\r\n\t\tthrow new UnsupportedOperationException(\"Še ne dela, poišči lokacijo od vozlišča z imaneom\" + startNode);\r\n\t}",
"public Builder withStartFrom(final RefLimit start) {\n\t\t\tthis.startFrom = start == null? RefLimit.buildEmpty() : start;\n\t\t\treturn this;\n\t\t}",
"public void setStartMark(Integer startMark) {\n this.startMark = startMark;\n }",
"@Override\n protected void beforeSearch() {\n index = 0;\n numberOfIterations = 0;\n pageCounter = 0;\n }",
"void xsetSearchWindowStart(org.apache.xmlbeans.XmlDateTime searchWindowStart);",
"public void setStartX(double val) {\r\n startx = val;\r\n }"
] | [
"0.7749996",
"0.7740396",
"0.7720881",
"0.7626437",
"0.7318664",
"0.69989127",
"0.6360481",
"0.5953974",
"0.59538466",
"0.59160644",
"0.58849174",
"0.58710086",
"0.58673525",
"0.56881684",
"0.56760275",
"0.56760275",
"0.5606097",
"0.5601739",
"0.55614746",
"0.55470884",
"0.54892373",
"0.5458199",
"0.54387593",
"0.5410789",
"0.5377458",
"0.5368718",
"0.53526103",
"0.5333572",
"0.5270193",
"0.5260801",
"0.52601665",
"0.52556825",
"0.5189945",
"0.5188234",
"0.5186216",
"0.51753205",
"0.5162361",
"0.5148363",
"0.5127458",
"0.51232904",
"0.51168215",
"0.50921",
"0.50921",
"0.50921",
"0.5078465",
"0.5049952",
"0.5045614",
"0.501364",
"0.50091636",
"0.4995784",
"0.49908417",
"0.49880368",
"0.49627167",
"0.49499017",
"0.49199674",
"0.49120712",
"0.49054584",
"0.49054584",
"0.48960656",
"0.48926613",
"0.48907733",
"0.48779872",
"0.48767585",
"0.48610815",
"0.4859767",
"0.48409912",
"0.48328936",
"0.48018163",
"0.47947684",
"0.47868544",
"0.4781835",
"0.47792137",
"0.4761941",
"0.47619116",
"0.47593978",
"0.47589055",
"0.4755606",
"0.47552228",
"0.47522968",
"0.47515047",
"0.47504035",
"0.47472525",
"0.4746571",
"0.47412705",
"0.4733374",
"0.473014",
"0.4726564",
"0.46991435",
"0.46946973",
"0.4677134",
"0.46569058",
"0.46531174",
"0.46498922",
"0.4638889",
"0.46386945",
"0.46367034",
"0.46353677",
"0.46300328",
"0.46255472",
"0.46164212"
] | 0.7813927 | 0 |
Gets the results value for this FindResults. | public ArrayOfFindResult getResults() {
return results;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public Result getResults()\r\n {\r\n return result;\r\n }",
"public Result getResult() {\n\t\treturn this._result;\n\t}",
"public int getResultValue() {\n return mResultValue;\n }",
"public java.lang.String getActualResults() {\n return actualResults;\n }",
"public int getResult() {\n return this.result;\n }",
"@java.lang.Override public int getResultValue() {\n return result_;\n }",
"public String getResults() {\r\n return returnObject.getResults();\r\n }",
"public int getResult() {\n\t\t\treturn this.result;\r\n\t\t}",
"@java.lang.Override public int getResultValue() {\n return result_;\n }",
"public Result getResult() {\n return result;\n }",
"@Override\n\tpublic Result getResult() {\n\t\treturn m_Result;\n\t}",
"public Map<String, Result> getResults() {\n return results;\n }",
"public MatchResult getResult() {\n return result;\n }",
"public ResultType getResult() {\r\n return result;\r\n }",
"public Result getResult() {\n return result;\n }",
"public ValueType getResultValue() {\n\t\treturn this.value;\n\t}",
"public String getResult() {\n return mResult;\n }",
"public int getResult() {\r\n\t\t\treturn result_;\r\n\t\t}",
"public VData getResult() {\n\t\treturn mResult;\n\t}",
"public int getResult() {\n return result;\n }",
"public int getResult() {\r\n\t\t\t\treturn result_;\r\n\t\t\t}",
"public Integer getResult() {\n return result;\n }",
"public Object getResult() {\n if (result == null) {\n return defaultResult();\n } else {\n return result;\n }\n }",
"synchronized public Result getResult () {\n Result result = (Result) get (RESULT.toString());\n if (result == null) {\n result = new Result();\n put (RESULT.toString(), result);\n }\n return result;\n }",
"public java.lang.String getGetItemDataResult() {\r\n return localGetItemDataResult;\r\n }",
"@SuppressWarnings(\"unchecked\")\r\n\t@Override\r\n\tpublic String getResult() {\n\t\treturn this.result;\r\n\r\n\t}",
"public String getResult() {\n return result;\n }",
"public String getResult() {\n return result;\n }",
"public String getResult() {\n return result;\n }",
"public String getResult()\r\n\t{\r\n\t\treturn result;\r\n\t}",
"public ArrayList<Integer> getResults(){\n return results;\n }",
"@Override\n @XmlElement(name = \"result\", required = true)\n public Collection<Result> getResults() {\n return results = nonNullCollection(results, Result.class);\n }",
"public String getGameResults(){\n \treturn this.gameResults;\n }",
"public ArrayList<R> getResults() {\n return results;\n }",
"@java.lang.Override\n public entities.Torrent.NodeSearchResult getResults(int index) {\n return results_.get(index);\n }",
"public java.math.BigInteger getTotalResults()\n {\n synchronized (monitor())\n {\n check_orphaned();\n org.apache.xmlbeans.SimpleValue target = null;\n target = (org.apache.xmlbeans.SimpleValue)get_store().find_attribute_user(TOTALRESULTS$4);\n if (target == null)\n {\n return null;\n }\n return target.getBigIntegerValue();\n }\n }",
"public int getResultsPage()\r\n\t{\r\n\t\treturn this.resultsPage;\r\n\t}",
"public String getResult()\n {\n return result;\n }",
"public List<Person> getResults() {\n\t\treturn mResult;\n\t}",
"public java.util.List<entities.Torrent.NodeSearchResult> getResultsList() {\n if (resultsBuilder_ == null) {\n return java.util.Collections.unmodifiableList(results_);\n } else {\n return resultsBuilder_.getMessageList();\n }\n }",
"public E getResult(){\r\n\t\treturn this.result;\r\n\t}",
"public String getResult() \n\t{\n\t\treturn strResult;\n\t}",
"@Nullable public R result() {\n return res;\n }",
"public List<SevereWeatherAlert> getResults() {\n return this.results;\n }",
"public Number getValue() {\n return ((ADocument) getDocument()).getValue();\n }",
"int getResult() {\n return result;\n }",
"public entities.Torrent.NodeSearchResult getResults(int index) {\n if (resultsBuilder_ == null) {\n return results_.get(index);\n } else {\n return resultsBuilder_.getMessage(index);\n }\n }",
"public TResult getResult() {\n return result;\n }",
"double getResult() {\r\n\t\treturn result;\r\n\t}",
"@java.lang.Override\n public java.util.List<entities.Torrent.NodeSearchResult> getResultsList() {\n return results_;\n }",
"int getResultValue();",
"int getResultValue();",
"interface Result {\n\n /** The page which contains matches. */\n @NotNull\n Resource getTarget();\n\n /** The content child of the page which contains matches. */\n @NotNull\n Resource getTargetContent();\n\n /** A link that shows the target, including search terms with {@link #PARAMETER_SEARCHTERM} */\n @NotNull\n String getTargetUrl();\n\n /** The title of the search result. */\n @NotNull\n String getTitle();\n\n /** The score of the search result. */\n Float getScore();\n\n /**\n * One or more descendants of {@link #getTarget()} that potentially match the search expression. Mostly useful\n * for generating excerpts; can contain false positives in some search algorithms.\n */\n @NotNull\n List<Resource> getMatches();\n\n /** The fulltext search expression for which this result was found. */\n @NotNull\n String getSearchExpression();\n\n /**\n * A basic excerpt from the matches that demonstrates the occurrences of the terms from {@link\n * #getSearchExpression()} in this result. Might be empty if not applicable (e.g. if the search terms were found\n * in meta information). If there are several matches, we just give one excerpt. You might want to provide your\n * own implementation for that to accommodate for specific requirements.\n *\n * @return a text with the occurrences of the words marked with HTML tag em .\n */\n @NotNull\n String getExcerpt() throws SearchTermParseException;\n }",
"public ExecutionResults getExecutionResults() {\n\t\treturn results ;\n\t}",
"public List<CorpusSearchHit> getResult() {\n return result;\n }",
"@java.lang.Override\n public java.util.List<? extends entities.Torrent.NodeSearchResultOrBuilder>\n getResultsOrBuilderList() {\n return results_;\n }",
"public double getValue(String id) {\n for (SimilarResult result : results) {\n if (result.getStringId().equals(id)) {\n return result.getValue();\n }\n }\n return 0;\n }",
"public ResultDoc getResultDoc() {\n\t\treturn resultDoc;\n\t}",
"public Map<String, StepResult> getResults()\n {\n return results;\n }",
"public T getResult() {\n return result;\n }",
"public T getResult() {\n return result;\n }",
"protected SimulatorValue giveResult() {\n\tthis.evalExpression();\n\treturn value;\n }",
"public StepResult getStepResult(String identifier)\n {\n return results.get(identifier);\n }",
"public int getNumResults() {\r\n\t\treturn this.numResults;\r\n\t}",
"@Override\n\tpublic String getResult() {\n\t\treturn result;\n\t}",
"public double getResult() {\n\t\treturn result; // so that skeleton code compiles\n\t}",
"public final String getResultStr() {\n return this.resultStr;\n }",
"public String getSearchResultsText() {\n System.out.println(\"[step] getSearchResultsText\");\n return page.findElement(signSearch).getText();\n }",
"protected R getResult() {\n\t\treturn result;\n\t}",
"public double getValue(Object o) {\n for (SimilarResult result : results) {\n if (result.getObj().equals(o)) {\n return result.getValue();\n }\n }\n return 0;\n }",
"public java.lang.String getGetsfzyResult() {\r\n return localGetsfzyResult;\r\n }",
"public int getResultsCount() {\n return results_.size();\n }",
"public String getValue() {\n return getMethodValue(\"value\");\n }",
"@java.lang.Override\n public entities.Torrent.NodeSearchResultOrBuilder getResultsOrBuilder(\n int index) {\n return results_.get(index);\n }",
"public int result() {\n\t\treturn total;\n\t}",
"public Object getResults() throws InterruptedException, ExecutionException {\n\t\t\treturn result.get();\n\t}",
"public FieldInfBase getResultField()\n {\n return getEntity().getFields()\n .stream()\n .filter(f -> f.getName().equalsIgnoreCase(result))\n .findAny().orElse(null);\n }",
"public T getValue() {\n\t\t\treturn this.entry.value;\n\t\t}",
"public final Map<Agent, ReplicationResult> getResults() {\n return this.results;\n }",
"public java.util.List<? extends entities.Torrent.NodeSearchResultOrBuilder>\n getResultsOrBuilderList() {\n if (resultsBuilder_ != null) {\n return resultsBuilder_.getMessageOrBuilderList();\n } else {\n return java.util.Collections.unmodifiableList(results_);\n }\n }",
"public int getNumberFound() {\n return numberFound;\n }",
"@Override\n \tpublic Object getResult() {\n \t\treturn result;\n \t}",
"public java.util.List<org.apache.calcite.avatica.proto.Responses.ResultSetResponse> getResultsList() {\n return results_;\n }",
"public ResultSet getResults() {\r\n return resultSet;\r\n }",
"public Class getResultType() {\n return _res;\n }",
"public Object getResult(final SessionContext ctx)\n\t{\n\t\treturn getProperty( ctx, RESULT);\n\t}",
"public List<Integer> Result()\n\t{\n\t\treturn result;\n\t}",
"public String getCorrentResponseValue() {\n return correntResponseValue;\n }",
"public Integer getMaxResults() {\n return maxResults;\n }",
"public List<SimilarResult<T>> getResults() {\n return Collections.unmodifiableList(results);\n }",
"public com.rpg.framework.database.Protocol.ResponseCode getResult() {\n return result_;\n }",
"public com.rpg.framework.database.Protocol.ResponseCode getResult() {\n return result_;\n }",
"public com.rpg.framework.database.Protocol.ResponseCode getResult() {\n return result_;\n }",
"public java.lang.Integer getFirstResult()\r\n {\r\n return this.firstResult;\r\n }",
"public int getResult(){\r\n\t\t return result;\r\n\t }",
"public com.rpg.framework.database.Protocol.ResponseCode getResult() {\n return result_;\n }",
"public com.rpg.framework.database.Protocol.ResponseCode getResult() {\n return result_;\n }",
"public String getValue() {\n\t\t\treturn this.val; // to be replaced by student code\n\t\t}",
"@java.lang.Override\n public int getResultsCount() {\n return results_.size();\n }",
"public java.lang.String getGetItemDataPrintResult() {\r\n return localGetItemDataPrintResult;\r\n }"
] | [
"0.68907344",
"0.66001105",
"0.65548503",
"0.6553984",
"0.6404976",
"0.64037824",
"0.6391361",
"0.63837475",
"0.63738585",
"0.6363508",
"0.6360732",
"0.6346145",
"0.6315161",
"0.6304527",
"0.6298059",
"0.6297145",
"0.62965775",
"0.62835246",
"0.6238799",
"0.6232021",
"0.6221913",
"0.62040406",
"0.61877763",
"0.6172743",
"0.6172268",
"0.6158951",
"0.6154789",
"0.6154789",
"0.6154789",
"0.61284506",
"0.61265266",
"0.6105685",
"0.6102503",
"0.6098895",
"0.6086548",
"0.6073247",
"0.6032767",
"0.60303307",
"0.59965956",
"0.59836954",
"0.5982371",
"0.5931015",
"0.59305364",
"0.59070754",
"0.5906986",
"0.58869815",
"0.5886201",
"0.58786076",
"0.5865314",
"0.58391833",
"0.5838003",
"0.5838003",
"0.5833561",
"0.58313566",
"0.58296907",
"0.58118975",
"0.580358",
"0.5796962",
"0.5787707",
"0.57720417",
"0.57720417",
"0.5763456",
"0.57423913",
"0.573523",
"0.57152015",
"0.5701685",
"0.5695812",
"0.56944",
"0.5683683",
"0.5682286",
"0.5671217",
"0.56704545",
"0.56654096",
"0.56632614",
"0.56626683",
"0.5661176",
"0.56556064",
"0.56384987",
"0.5632323",
"0.56303513",
"0.5612288",
"0.56043375",
"0.55923134",
"0.55899316",
"0.5584988",
"0.5582602",
"0.5576573",
"0.55641496",
"0.5563814",
"0.55632436",
"0.556186",
"0.556186",
"0.556186",
"0.556158",
"0.55612135",
"0.5560551",
"0.5560551",
"0.55592954",
"0.5553199",
"0.55520564"
] | 0.723915 | 0 |
Sets the results value for this FindResults. | public void setResults(ArrayOfFindResult results) {
this.results = results;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void setResults(List<Person> results){\n\t\tmResult = results;\n\t\tmListeners.resultListUpdated();\n\t\t\n\t}",
"public void setResults(ArrayList<Integer> results){\n this.results = results;\n }",
"public void setResults(ArrayList results) {\n this.results = results;\n }",
"public Builder setResults(\n int index, entities.Torrent.NodeSearchResult value) {\n if (resultsBuilder_ == null) {\n if (value == null) {\n throw new NullPointerException();\n }\n ensureResultsIsMutable();\n results_.set(index, value);\n onChanged();\n } else {\n resultsBuilder_.setMessage(index, value);\n }\n return this;\n }",
"public void setResults(final Collection<? extends Result> newValues) {\n results = writeCollection(newValues, results, Result.class);\n }",
"public void setResults(List<BenchmarkResultSet> results) {\n this.results = results;\n }",
"public void setNumResults(int numResults) {\n mNumResults = numResults;\n }",
"public void setResults(Map<String, StepResult> newResults)\n {\n results = newResults;\n }",
"public final void settest_results(vehiclelookup.proxies.TestResultObj test_results)\n\t{\n\t\tsettest_results(getContext(), test_results);\n\t}",
"public final void setMatLabResults(Object[] results)\r\n\t{\r\n\t\tmatLabResults = results;\r\n\t}",
"public Builder setResults(\n int index, org.apache.calcite.avatica.proto.Responses.ResultSetResponse value) {\n if (resultsBuilder_ == null) {\n if (value == null) {\n throw new NullPointerException();\n }\n ensureResultsIsMutable();\n results_.set(index, value);\n onChanged();\n } else {\n resultsBuilder_.setMessage(index, value);\n }\n return this;\n }",
"public void setResult(Result result) {\n this.result = result;\n }",
"void setNumberOfResults(int numberOfResults);",
"public void setResults(WsGroupSaveResult[] results1) {\n this.results = results1;\n }",
"public void setResult(Result result) {\n\t\tthis._result = result;\n\t}",
"public void setResult(Object result) {\n this.result = result;\n }",
"public void setTotalResults(java.math.BigInteger totalResults)\n {\n synchronized (monitor())\n {\n check_orphaned();\n org.apache.xmlbeans.SimpleValue target = null;\n target = (org.apache.xmlbeans.SimpleValue)get_store().find_attribute_user(TOTALRESULTS$4);\n if (target == null)\n {\n target = (org.apache.xmlbeans.SimpleValue)get_store().add_attribute_user(TOTALRESULTS$4);\n }\n target.setBigIntegerValue(totalResults);\n }\n }",
"public void setResult(T result) {\n this.result = result;\n }",
"public void setResult(final Integer res) {\n this.result = res;\n }",
"public void setResultsPage(int resultsPage)\r\n\t{\r\n\t\tthis.resultsPage = resultsPage;\r\n\t}",
"public void setResult() {\n }",
"protected void setResult(R result) {\n _result = result;\n }",
"public void setActualResults(java.lang.String actualResults) {\n this.actualResults = actualResults;\n }",
"public Builder addResults(entities.Torrent.NodeSearchResult value) {\n if (resultsBuilder_ == null) {\n if (value == null) {\n throw new NullPointerException();\n }\n ensureResultsIsMutable();\n results_.add(value);\n onChanged();\n } else {\n resultsBuilder_.addMessage(value);\n }\n return this;\n }",
"public void setResults(\t@NotNull List<ResultDocument> results,\n\t\t\t\t\t\t\t@NotNull HeaderMode headerMode) {\n\t\tUtil.checkNotNull(results, headerMode);\n\t\t\n\t\tif (this.presetHeaderMode != headerMode) {\n\t\t\tif (headerMode != HeaderMode.FILES_AND_EMAILS)\n\t\t\t\tupdateColumnHeaders(headerMode);\n\t\t\tthis.presetHeaderMode = headerMode;\n\t\t}\n\t\tsetActualHeaderMode(results); // TODO post-release-1.1: needs some refactoring\n\t\t\n\t\tviewer.setRoot(results);\n\t\tviewer.scrollToTop();\n\t}",
"public void setResult (String Result);",
"public Builder setResults(\n int index, entities.Torrent.NodeSearchResult.Builder builderForValue) {\n if (resultsBuilder_ == null) {\n ensureResultsIsMutable();\n results_.set(index, builderForValue.build());\n onChanged();\n } else {\n resultsBuilder_.setMessage(index, builderForValue.build());\n }\n return this;\n }",
"protected void maybeSetResultPropertyValue(int result) {\r\n String res = Integer.toString(result);\r\n if (resultProperty != null) {\r\n getProject().setNewProperty(resultProperty, res);\r\n }\r\n }",
"public void setResult(String result)\r\n\t{\r\n\t\tthis.result = result;\r\n\t}",
"@Override\n protected void publishResults(CharSequence constraint, FilterResults results) {\n set((List<Item>) results.values);\n }",
"public void setResult(String result)\n {\n this.result = result;\n }",
"public fill_results_result(fill_results_result other) {\n __isset_bitfield = other.__isset_bitfield;\n this.success = other.success;\n }",
"public void setResultsPanel(ResultsPanel rp) {\n\n m_ResultsPanel = rp;\n }",
"public Builder setResultValue(int value) {\n \n result_ = value;\n onChanged();\n return this;\n }",
"public void setResults(ArrayList<Double> values, ArrayList<Double> results) {\n StringBuilder stringBuilder = new StringBuilder();\n for (int i = 0; i < results.size(); i++) {\n stringBuilder.append(values.get(i) + \" --> \" + decimalFormat.format(results.get(i)) + '\\n');\n }\n calcResults.setText(stringBuilder.toString());\n }",
"private void setResult(String term){\n\t\taddResponseToResult(term);\n\t}",
"public Builder setResults(\n int index, com.google.cloud.speech.v2.StreamingRecognitionResult value) {\n if (resultsBuilder_ == null) {\n if (value == null) {\n throw new NullPointerException();\n }\n ensureResultsIsMutable();\n results_.set(index, value);\n onChanged();\n } else {\n resultsBuilder_.setMessage(index, value);\n }\n return this;\n }",
"@Override\n public void setResult(Object result) throws EngineException {\n \n }",
"public list_results_doc_result(list_results_doc_result other) {\n if (other.isSetSuccess()) {\n java.util.List<Examination> __this__success = new java.util.ArrayList<Examination>(other.success.size());\n for (Examination other_element : other.success) {\n __this__success.add(new Examination(other_element));\n }\n this.success = __this__success;\n }\n }",
"public void setResult(String result) {\n this.result = result;\n }",
"public Builder addResults(\n entities.Torrent.NodeSearchResult.Builder builderForValue) {\n if (resultsBuilder_ == null) {\n ensureResultsIsMutable();\n results_.add(builderForValue.build());\n onChanged();\n } else {\n resultsBuilder_.addMessage(builderForValue.build());\n }\n return this;\n }",
"public void setResult(download.Map result) {\n this.result = result;\n }",
"public void setTotalResults(Integer totalResults) {\r\n this.totalResults = totalResults;\r\n }",
"public final void settest_results(com.mendix.systemwideinterfaces.core.IContext context, vehiclelookup.proxies.TestResultObj test_results)\n\t{\n\t\tif (test_results == null)\n\t\t\tgetMendixObject().setValue(context, MemberNames.test_results.toString(), null);\n\t\telse\n\t\t\tgetMendixObject().setValue(context, MemberNames.test_results.toString(), test_results.getMendixObject().getId());\n\t}",
"public void setResult(boolean result) {\n\t\t_result = result;\n\t}",
"public void setResult(boolean value) {\n this.result = value;\n }",
"public Builder setResults(\n int index, org.apache.calcite.avatica.proto.Responses.ResultSetResponse.Builder builderForValue) {\n if (resultsBuilder_ == null) {\n ensureResultsIsMutable();\n results_.set(index, builderForValue.build());\n onChanged();\n } else {\n resultsBuilder_.setMessage(index, builderForValue.build());\n }\n return this;\n }",
"public ArrayOfFindResult getResults() {\n return results;\n }",
"public void setLastResult(final Object val) {\n lastResult = val;\n }",
"public void setScreenResults(com.isurveysoft.www.servicesv5.Result[] screenResults) {\n this.screenResults = screenResults;\n }",
"public Builder addResults(\n int index, entities.Torrent.NodeSearchResult value) {\n if (resultsBuilder_ == null) {\n if (value == null) {\n throw new NullPointerException();\n }\n ensureResultsIsMutable();\n results_.add(index, value);\n onChanged();\n } else {\n resultsBuilder_.addMessage(index, value);\n }\n return this;\n }",
"public Builder setResult(int value) {\r\n\t\t\t\tbitField0_ |= 0x00000001;\r\n\t\t\t\tresult_ = value;\r\n\t\t\t\tonChanged();\r\n\t\t\t\treturn this;\r\n\t\t\t}",
"@XmlElement(name = \"Results\")\n public void setLookupInterimResult(LookupInterimResult lookupInterimResult) {\n this.lookupInterimResult = lookupInterimResult;\n }",
"public void setResultsPerPage(int resultsPerPage)\r\n\t{\r\n\t\tthis.resultsPerPage = resultsPerPage;\r\n\t}",
"public void setResultDoc(ResultDoc resultDoc) {\n\t\tthis.resultDoc = resultDoc;\n\t}",
"public void setResult(String result) {\n this.result = result;\n }",
"public Builder setResults(\n int index, com.google.cloud.speech.v2.StreamingRecognitionResult.Builder builderForValue) {\n if (resultsBuilder_ == null) {\n ensureResultsIsMutable();\n results_.set(index, builderForValue.build());\n onChanged();\n } else {\n resultsBuilder_.setMessage(index, builderForValue.build());\n }\n return this;\n }",
"public Result getResults()\r\n {\r\n return result;\r\n }",
"public void setResult(final Object value)\n\t{\n\t\tsetResult( getSession().getSessionContext(), value );\n\t}",
"public void setResult(int result) {\n this.result = result;\n this.isSix = this.result == 6;\n }",
"public Builder setResult(boolean value) {\n\n result_ = value;\n onChanged();\n return this;\n }",
"public static void setResult(String resultInfo) {\n }",
"@JsonIgnore\n public void setTestResults(Set<LearnerResult> testResults) {\n this.testResults = testResults;\n }",
"public Builder addResults(org.apache.calcite.avatica.proto.Responses.ResultSetResponse value) {\n if (resultsBuilder_ == null) {\n if (value == null) {\n throw new NullPointerException();\n }\n ensureResultsIsMutable();\n results_.add(value);\n onChanged();\n } else {\n resultsBuilder_.addMessage(value);\n }\n return this;\n }",
"public search_result(search_result other) {\n if (other.isSetSuccess()) {\n this.success = new com.mkfree.apithrift.vo.SearchResultVO(other.success);\n }\n }",
"public void setResultsList(ArrayList<BrowseItem> resultsList)\r\n\t{\r\n\t\tthis.resultsList = resultsList;\r\n\t}",
"public void setResultsForMethods(HashMap<String, HashMap<String, Object>> resultsForMethods) {\n this.resultsForMethods = resultsForMethods;\n }",
"public void setFound(boolean found) {\n this.found = found;\n }",
"public void setResult(String strResult) \n\t{\n\t\tthis.strResult = strResult;\n\t}",
"@Override\n\tprotected void setAllResultsToPar() {\n\t}",
"public void setData(ArrayList<SearchResult> mResultsList) {\n if (resultsList != null) {\n resultsList.clear();\n resultsList.addAll(mResultsList);\n notifyDataSetChanged();\n } else {\n resultsList = mResultsList;\n }\n }",
"public Builder setResult(boolean value) {\n \n result_ = value;\n onChanged();\n return this;\n }",
"public Builder setResult(boolean value) {\n \n result_ = value;\n onChanged();\n return this;\n }",
"public Builder setResult(\n java.lang.String value) {\n if (value == null) {\n throw new NullPointerException();\n }\n bitField0_ |= 0x00000002;\n result_ = value;\n onChanged();\n return this;\n }",
"public Builder setResult(boolean value) {\n \n result_ = value;\n onChanged();\n return this;\n }",
"public Builder addAllResults(\n java.lang.Iterable<? extends entities.Torrent.NodeSearchResult> values) {\n if (resultsBuilder_ == null) {\n ensureResultsIsMutable();\n com.google.protobuf.AbstractMessageLite.Builder.addAll(\n values, results_);\n onChanged();\n } else {\n resultsBuilder_.addAllMessages(values);\n }\n return this;\n }",
"void setQueryResultsUrl(String queryResultsUrl);",
"public Builder addResults(\n int index, org.apache.calcite.avatica.proto.Responses.ResultSetResponse value) {\n if (resultsBuilder_ == null) {\n if (value == null) {\n throw new NullPointerException();\n }\n ensureResultsIsMutable();\n results_.add(index, value);\n onChanged();\n } else {\n resultsBuilder_.addMessage(index, value);\n }\n return this;\n }",
"public void setNumberFound(int numberFound) {\n this.numberFound = numberFound;\n }",
"public void setResult(final SessionContext ctx, final Object value)\n\t{\n\t\tsetProperty(ctx, RESULT,value);\n\t}",
"public getValue_result(getValue_result other) {\n if (other.isSetSuccess()) {\n this.success = other.success;\n }\n }",
"public void setResult(final String incomingResult)\r\n {\r\n \r\n result = incomingResult;\r\n }",
"public void setFound(boolean found) {\n\t\tthis.found = found;\n\t}",
"private void updateNumResults(int numResults)\n {\n String message = MessageFormat.format(\"Found {0} results\", numResults);\n resultInfo.setText(message);\n }",
"public Builder setResult(boolean value) {\n bitField0_ |= 0x00000001;\n result_ = value;\n onChanged();\n return this;\n }",
"public entities.Torrent.NodeSearchResult.Builder addResultsBuilder() {\n return getResultsFieldBuilder().addBuilder(\n entities.Torrent.NodeSearchResult.getDefaultInstance());\n }",
"public void setSearchResults(List<Visit> searchResults) {\n\t\tthis.searchResults = searchResults;\n\t}",
"public void setResultId(int value) {\n this.resultId = value;\n }",
"private void setResultSet(final ResultSet value) {\n\n resultSet = value;\n }",
"public void setStepResultForStepIdentifier(String identifier, StepResult stepResult) {\n results.put(identifier, stepResult);\n }",
"void setFound(final String found) {\n this.vars.put(\"found\", found);\n }",
"@Override\n\tpublic void setReserveResults(boolean reserveResults) {\n\t\tmodel.setReserveResults(reserveResults);\n\t}",
"public void setCacheResults(boolean cache) {\n cacheResults = cache;\n }",
"public void setResult(String result) {\n this.result = result == null ? null : result.trim();\n }",
"public void setSearchResultLabel(String resultLabel){ searchResultLabel.setText(resultLabel);}",
"@Override\r\n\tpublic void setResultStoreModel(MatchResultModel resultStoreModel) {\r\n\t\tthis.matchResultModel = resultStoreModel;\r\n\t}",
"public Builder addResults(\n org.apache.calcite.avatica.proto.Responses.ResultSetResponse.Builder builderForValue) {\n if (resultsBuilder_ == null) {\n ensureResultsIsMutable();\n results_.add(builderForValue.build());\n onChanged();\n } else {\n resultsBuilder_.addMessage(builderForValue.build());\n }\n return this;\n }",
"public list_results_pat_result(list_results_pat_result other) {\n if (other.isSetSuccess()) {\n java.util.List<Examination> __this__success = new java.util.ArrayList<Examination>(other.success.size());\n for (Examination other_element : other.success) {\n __this__success.add(new Examination(other_element));\n }\n this.success = __this__success;\n }\n }",
"public void xsetTotalResults(com.a9.spec.opensearch.x11.QueryType.TotalResults totalResults)\n {\n synchronized (monitor())\n {\n check_orphaned();\n com.a9.spec.opensearch.x11.QueryType.TotalResults target = null;\n target = (com.a9.spec.opensearch.x11.QueryType.TotalResults)get_store().find_attribute_user(TOTALRESULTS$4);\n if (target == null)\n {\n target = (com.a9.spec.opensearch.x11.QueryType.TotalResults)get_store().add_attribute_user(TOTALRESULTS$4);\n }\n target.set(totalResults);\n }\n }",
"public void setResult(String name) {\r\n DatabaseField returnField = (DatabaseField)getParameters().get(0);\r\n returnField.setName(name);\r\n }"
] | [
"0.73346996",
"0.73164266",
"0.71500283",
"0.6782049",
"0.6741925",
"0.67357075",
"0.6558248",
"0.6538124",
"0.6494013",
"0.64826393",
"0.64670414",
"0.64379877",
"0.6437282",
"0.64323467",
"0.6389431",
"0.6369104",
"0.636752",
"0.6336316",
"0.63349247",
"0.63117486",
"0.6304286",
"0.62933385",
"0.62420094",
"0.62403315",
"0.6180689",
"0.61466277",
"0.61240286",
"0.609965",
"0.60759205",
"0.6032726",
"0.5992828",
"0.5985485",
"0.5977109",
"0.5964861",
"0.59617454",
"0.5942903",
"0.5940129",
"0.5935406",
"0.5925244",
"0.59111804",
"0.59067655",
"0.5903234",
"0.5895687",
"0.58917254",
"0.58835894",
"0.5875188",
"0.5849926",
"0.5842029",
"0.5833452",
"0.5819569",
"0.5819049",
"0.57984304",
"0.5791854",
"0.57897824",
"0.5776769",
"0.5771709",
"0.5709107",
"0.5702318",
"0.56952083",
"0.5675437",
"0.56697387",
"0.5666884",
"0.56552356",
"0.5644445",
"0.56440425",
"0.5638827",
"0.56375164",
"0.56347656",
"0.56313777",
"0.56207687",
"0.5619397",
"0.561927",
"0.561927",
"0.56140286",
"0.5613309",
"0.5605471",
"0.5602097",
"0.5588739",
"0.5571578",
"0.557022",
"0.5557317",
"0.55539256",
"0.55438393",
"0.55410415",
"0.5540054",
"0.55284953",
"0.5504621",
"0.54881763",
"0.5482013",
"0.54818994",
"0.5480015",
"0.5472201",
"0.54696685",
"0.54629296",
"0.54613787",
"0.545912",
"0.54543006",
"0.5446784",
"0.5445051",
"0.5414304"
] | 0.76547766 | 0 |
Gets the topScore value for this FindResults. | public double getTopScore() {
return topScore;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public int getBestScore() {\n\t\tInteger score = this.hand.countValue().lower(22);\n\t\tif(score!=null) {\n\t\t\treturn score;\n\t\t}\n\t\telse {\n\t\t\treturn this.hand.countValue().higher(21);\n\t\t}\n\t}",
"public int getScore() {\n return getStat(score);\n }",
"public void setTopScore(double topScore) {\n this.topScore = topScore;\n }",
"public double getScore() {\n\t\t\treturn this.score;\n\t\t}",
"public long getScore() {\n return score_;\n }",
"public long getScore() {\n return score_;\n }",
"LinkedHashMap<String, Integer> getTopScores() {\n return this.topScores;\n }",
"public Integer getScore() {\r\n return score;\r\n }",
"public long getScore() {\n return score_;\n }",
"public long getScore() {\n return score_;\n }",
"public int getScore() {\n\t\treturn this.score;\n\t}",
"public Integer getScore() {\n return score;\n }",
"public final int getScore() {\n\t\treturn score;\n\t}",
"public int getScore()\n\t{\n\t\treturn this.score;\n\t}",
"public int getScore() {\n\t\treturn this.ScoreValue;\n\t}",
"public Double getOverallScore() {\n\t\treturn overallScore;\n\t}",
"@Override\n public int higherScore() {\n if (!scoresUpToDate) {\n updateScores();\n }\n return higherScore;\n }",
"public java.lang.Integer getScore () {\r\n\t\treturn score;\r\n\t}",
"public int getScore() {\r\n\t\treturn score;\r\n\t}",
"public int getScore() {\r\n\t\treturn score;\r\n\t}",
"public int getScore() {\n return this.score;\n }",
"public int getScore() {\n\t\treturn (score);\n\t}",
"public int getHighScore() {\n return highScore;\n }",
"public int getScore(){\n\t\treturn this.score;\n\t}",
"public int getScore(){\n\t\treturn this.score;\n\t}",
"public OptionalDouble getBestScore()\n {\n if (scores.size() > 0)\n {\n return OptionalDouble.of(scores.lastKey());\n }\n else\n {\n return OptionalDouble.empty();\n }\n }",
"public int getScore() {\n\t\treturn score;\n\t}",
"public int getScore() {\n\t\treturn score;\n\t}",
"public int getScore() {\n\t\treturn score;\n\t}",
"public int getScore() {\n\t\treturn score;\n\t}",
"public int getScore() {\n\t\treturn score;\n\t}",
"public int getScore() {\n\t\treturn score;\n\t}",
"public double getBestScore();",
"public float getScore() {\r\n\t\treturn score;\r\n\t}",
"public int getScore() {\r\n \treturn score;\r\n }",
"public float getScore() {\n\t\treturn score;\n\t}",
"public static int getScore()\r\n\t{\r\n\t\treturn score;\r\n\t}",
"public Double getScore() {\n return this.score;\n }",
"public Double getScore() {\n return this.score;\n }",
"public int getHighScore() {\n\t\treturn highscore;\n\t}",
"public double getScore() {\r\n return mScore;\r\n }",
"public static int getScore()\n\t{\n\t\treturn score;\n\t}",
"public int getScore() {\n return score;\n }",
"public static int getScore()\n {\n return score;\n }",
"public int getScore()\r\n\t{\r\n\t\treturn score;\r\n\t}",
"public int getScore()\r\n\t{\r\n\t\treturn score;\r\n\t}",
"public int getScore(){\r\n\t\treturn score;\r\n\t}",
"public int getScore(){\r\n\t\treturn score;\r\n\t}",
"public int getScore() {\r\n return score;\r\n }",
"public int getScore() {\r\n return score;\r\n }",
"public int getScore() {\r\n return score;\r\n }",
"public int getScore(){\n\t\treturn score;\n\t}",
"public int getScore(){\n\t\treturn score;\n\t}",
"public float getScore() {\n return score;\n }",
"public Long getScore() {\n return score;\n }",
"public int getScore() {\n return score;\n }",
"public int getScore() {\n return score;\n }",
"public double getScore() {\r\n return score;\r\n }",
"public int getWorstScore()\n {\n return -1;\n }",
"public int getHighScore(int i) {\n return topScores.get(i);\n }",
"public int getRoundScore() {\n return score;\n }",
"public Score getScore() {\n\t\treturn score;\n\t}",
"public int getHighscore()\n {\n return this.highscore;\n }",
"public Float getScore() {\n return score;\n }",
"public Double getHighestMainScore() {\n return highestMainScore;\n }",
"@Override\r\n\tpublic double getScore() \r\n\t{\r\n\t\treturn this._totalScore;\r\n\t}",
"public int getScore () {\n return mScore;\n }",
"public int getScore() {\n return currentScore;\n }",
"int getHighScore() {\n return getStat(highScore);\n }",
"public int getMaxScore() {\r\n return maxScore;\r\n\t}",
"public int score() {\n return score;\n }",
"public int getTotalScore() {\r\n return totalScore;\r\n }",
"public static int ReadBestScore()\n {\n int best_score = -1;\n try \n {\n BufferedReader file = new BufferedReader(new FileReader(score_file_name));\n best_score = Integer.parseInt(file.readLine());\n file.close();\n } \n catch (Exception e) { SaveBestScore(0); }\n \n currentBestScore = best_score;\n return best_score;\n }",
"Float getScore();",
"public int getScore(){\n\t\treturn playerScore;\n\t}",
"public Fitness bestScore() {\r\n Map.Entry<Fitness, List<Element>> bestEntry\r\n = elementsByFitness.lastEntry();\r\n if (bestEntry == null) {\r\n return null;\r\n }\r\n Fitness result = bestEntry.getKey();\r\n\r\n return result;\r\n }",
"public int getScoreInt() {\n return scoreInt;\n }",
"@gw.internal.gosu.parser.ExtendedProperty\n public java.lang.Integer getScore();",
"public int getScore ()\r\n {\r\n\treturn score;\r\n }",
"public java.lang.Float getScore () {\n\t\treturn score;\n\t}",
"public int getScore()\n {\n return score;\n }",
"@Override\n public int getScore() {\n return totalScore;\n }",
"public static int getScore(){\n return score;\n }",
"public int getScore()\n {\n return currentScore;\n }",
"public double getHighestConfidence() {\n\t\tdouble best = Double.MIN_VALUE;\n\n\t\tfor (ResultConfidencePairing rcp : m_results) {\n\t\t\tif (rcp.getConfidence() > best)\n\t\t\t\tbest = rcp.getConfidence();\n\t\t}\n\t\treturn best;\n\t}",
"@Override\r\n\tpublic double getScore() {\n\t\treturn score;\r\n\t}",
"@Override\n public Score getBest() {\n Session session = FACTORY.openSession();\n\n try {\n List<Score> bestScores = session.createQuery(\"FROM Score s WHERE s.value = (SELECT max(s.value) FROM Score s)\", Score.class)\n .list();\n\n session.close();\n\n return bestScores.isEmpty() ? new Score(0L) : bestScores.get(0);\n } catch (ClassCastException e) {\n LOG.error(\"Error happened during casting query results.\");\n return null;\n }\n }",
"public Integer getGameScore() {\n return gameScore;\n }",
"public double getTotalScore() {\n\t return this.totalScore;\n\t }",
"public int getBestPrice() {\n\t\treturn this.bestPrice;\n\t}",
"public int getCurrentScore() {\n return currentScore;\n }",
"public int findHighestScore() {\n int highest = 0;\n for (int i = 0; i < allQuizTakers.size(); i++) {\n\n if (allQuizTakers.get(i).getScore(0).compareTo(highest) > 0) {\n highest = (int) allQuizTakers.get(i).getScore(0);\n }\n\n }\n return highest;\n }",
"public double getRankScore() {\n return this.rankScore;\n }",
"public Double getTotalScore() {\n return totalScore;\n }",
"public float getHighestFitness() {\r\n\t\treturn highestScore;\r\n\t}",
"public Integer getTop() {\n return top;\n }",
"public int getPlayerScore(){\n\t\treturn playerScore;\n\t}",
"@Override\n public int getScore() {\n return score;\n }",
"public int getScore() { return score; }",
"public int score() {\n ArrayList<Integer> scores = possibleScores();\n int maxUnder = Integer.MIN_VALUE;\n int minOver = Integer.MAX_VALUE;\n for (int score : scores) {\n if (score > 21 && score < minOver) {\n minOver = score;\n } else if (score <= 21 && score > maxUnder) {\n maxUnder = score;\n }\n }\n return maxUnder == Integer.MIN_VALUE ? minOver : maxUnder;\n }"
] | [
"0.6736939",
"0.6691723",
"0.6610906",
"0.6605378",
"0.6603729",
"0.6603729",
"0.6575225",
"0.6569495",
"0.6566329",
"0.6566329",
"0.6556892",
"0.65544254",
"0.65496594",
"0.6522154",
"0.6521441",
"0.65182394",
"0.65108997",
"0.6505021",
"0.6502061",
"0.6502061",
"0.65013665",
"0.64968014",
"0.6487414",
"0.64707327",
"0.64707327",
"0.6468771",
"0.64558023",
"0.64558023",
"0.64558023",
"0.64558023",
"0.64558023",
"0.64558023",
"0.6447838",
"0.6447408",
"0.64302605",
"0.6425486",
"0.64216894",
"0.64169997",
"0.64169997",
"0.6408964",
"0.6408694",
"0.6406522",
"0.6405353",
"0.640048",
"0.6398391",
"0.6398391",
"0.6398143",
"0.6398143",
"0.6377964",
"0.6377964",
"0.6377964",
"0.6371836",
"0.6371836",
"0.636952",
"0.63607085",
"0.63559014",
"0.63559014",
"0.63286614",
"0.6325325",
"0.63034594",
"0.6302081",
"0.6295955",
"0.6277201",
"0.62493277",
"0.62399226",
"0.62360525",
"0.6220493",
"0.6219217",
"0.62180865",
"0.62139374",
"0.62008774",
"0.6200303",
"0.61878586",
"0.6165257",
"0.61597705",
"0.61522627",
"0.6135506",
"0.6125661",
"0.6120241",
"0.6115404",
"0.6091825",
"0.6086406",
"0.60849875",
"0.60847193",
"0.6083583",
"0.60833097",
"0.6071391",
"0.60474825",
"0.60428506",
"0.60225433",
"0.6020121",
"0.60174245",
"0.6013068",
"0.6006208",
"0.5998221",
"0.59839803",
"0.5979506",
"0.596663",
"0.5943004",
"0.5938592"
] | 0.820975 | 0 |
Sets the topScore value for this FindResults. | public void setTopScore(double topScore) {
this.topScore = topScore;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"void setBestScore(double bestScore);",
"@Override\r\n\tpublic final void setBestScore(final double theBestScore) {\r\n\t\tthis.bestScore = theBestScore;\r\n\t}",
"public double getTopScore() {\n return topScore;\n }",
"public void setScore(Integer score) {\r\n this.score = score;\r\n }",
"public void setScore (java.lang.Integer score) {\r\n\t\tthis.score = score;\r\n\t}",
"public void setScore(Integer score) {\n this.score = score;\n }",
"public void setScore(int score) {\r\n this.score = score;\r\n }",
"public void setScore(int score) {\r\n this.score = score;\r\n }",
"public void setScore(int score) {\n this.score = score;\n }",
"public void setScore(int score) {\n this.score = score;\n }",
"public void setScore(int score) {\n this.score = score;\n }",
"public void setScore(int score) {\n this.score = score;\n }",
"public void setScore(int score) {\n this.score = score;\n }",
"public void setScore(int score)\n {\n this.score = score;\n }",
"public void setScore(int score){\n\t\tthis.score = score;\n\t}",
"public void setScore(int score) {\r\n\t\tif(score >=0) {\r\n\t\t\tthis.score = score;\r\n\t\t}\r\n\t\t\r\n\t}",
"public void setScore(int score) {\n\t\tthis.score = score;\n\t}",
"public void setScore(double score) {\r\n this.score = score;\r\n }",
"public void setHighscore(int score)\n {\n this.highscore = score;\n }",
"public void setScore(float score) {\n this.score = score;\n }",
"public void setScore(Float score) {\n this.score = score;\n }",
"public void setScore(int score)\n\t{\n\t\tthis.score=score;\n\t}",
"public void setScore(int score) { this.score = score; }",
"public void setScore(int newScore){\n\t\tthis.score = newScore;\n\t}",
"public void setScore(Double score) {\n this.score = score;\n }",
"public void setScore(int paScore) {\n this.score = paScore;\n }",
"public void setScore(int score)\n\t{\n\t\tthis.score += score;\n\t}",
"public void setScore(String score) {\n this.score = score;\n setChanged();\n notifyObservers();\n }",
"public void setScore(Score score) {\n scoreProperty.set(score.packed());\n }",
"public synchronized void setScore(Integer score) {\n this.score += score;\n }",
"public void setScore(String score) {\n\t\tthis.score = score;\n\t}",
"public void setOverallScore(Double overallScore) {\n\t\tthis.overallScore = overallScore;\n\t}",
"private void setScore(String score) {\r\n this.score = score;\r\n }",
"public void setScore (java.lang.Float score) {\n\t\tthis.score = score;\n\t}",
"public void setScore(int score) {this.score = score;}",
"public void setTop(Integer top) {\n this.top = top;\n }",
"public void setScore(float value) {\n this.score = value;\n }",
"public void setRoundScore(int roundScore) {\n\t\tthis.roundScore = roundScore;\n\t}",
"public ExtractedSummarySentence setRankScore(double rankScore) {\n this.rankScore = rankScore;\n return this;\n }",
"public void setScore(Short score) {\n this.score = score;\n }",
"void setScore(int score) {\n lblScore.setText(String.valueOf(score));\n }",
"void setScore(long score);",
"public void updateHighestScoreDisplay(int score){\n this.score.setText(\"Highest Score: \"+score);\n }",
"public void setScore(java.lang.Integer value);",
"@Override\r\n public boolean visit (Score score)\r\n {\r\n score.acceptChildren(this);\r\n\r\n if (logger.isFineEnabled()) {\r\n logger.fine(\"highestTop=\" + highestTop);\r\n }\r\n\r\n score.setHighestSystemTop(highestTop);\r\n\r\n return false;\r\n }",
"void setScoreValue(int scoreValue);",
"public void setScoreStitok() {\n this.scoreStitok.setText(\"Score \" + this.score);\n }",
"public void setGameScore(Integer gameScore) {\n this.gameScore = gameScore;\n }",
"public void setHighScore(int newScore) {\n\t\tpreferences().putInteger(username() + HIGH_SCORE, newScore);\n\t\tsave();\n\t}",
"public void setUsingBestScore(boolean usingBestScore) {\n this.usingBestScore = usingBestScore;\n }",
"public static void setPlayerScore(int score)\r\n\t{\r\n\t\tGame.playerScore = score;\r\n\t}",
"public void topScore() {\n\t\tif (playern.getExp() >= 100) {\n\t\t\tSystem.out.println(\"You become a Warrior and win the game\");\n\t\t\tSystem.exit(0);\n\t\t}\n\t}",
"public void setScoreOfTeam(Team team, int newScore) {\n\t\tteamScore.put(team.getTeamId(), newScore);\n\t}",
"private void updateHighscore() {\n if(getScore() > highscore)\n highscore = getScore();\n }",
"public void setScore (int newScore)\n {\n this.score = newScore;\n }",
"public final void setScore(java.lang.Double score)\r\n\t{\r\n\t\tsetScore(getContext(), score);\r\n\t}",
"public void countHighest (int score){\r\n\t\tif (score > highest){\r\n\t\t\thighest = score;\r\n\t\t}\r\n\t}",
"public void setTopnum(String topnum) {\n this.topnum = topnum;\n }",
"public Scores(int score) {\r\n this.score = score;\r\n }",
"public void setStoryScore (java.lang.Float storyScore) {\n\t\tthis.storyScore = storyScore;\n\t}",
"protected void updateBest() {\n\t\tbestScoreView.setText(\"Best: \" + bestScore);\n\t}",
"public void setMyScoreDisplay(String score) {\n myScoreDisplay.setText(score);\n }",
"void setTopAvgScorers(UserProfile[] topAvgScorers) {\n this.topAvgScorers = topAvgScorers;\n }",
"void setTopTotalScorers(UserProfile[] topTotalScorers) {\n this.topTotalScorers = topTotalScorers;\n }",
"public static void setActivityScore(int score) {\n\n\t\tmActivityScore = score;\n\t}",
"protected void setOnePlayerHumanScore(int score){\n this.humanWinsCPU_TextField.setText(Integer.toString(score));\n }",
"@Override\n public void setScore(int score) throws IllegalStateException {\n objective.checkValid();\n this.score = score;\n objective.getScoreboard()\n .broadcast(new ScoreboardScoreMessage(entry, objective.getName(), score));\n }",
"public void setCurrentScore(int currentScore) {\n this.currentScore = currentScore;\n }",
"public void setTestScore(int testNumber, int score) {\n\t if(testNumber == 1)\n\t\t test1 = score;\n\t else if(testNumber == 2)\n\t\t test2 = score;\n\t else\n\t\t test3 = score;\n }",
"public void setHomeScore(int homeScore) {\n this.homeScore = homeScore;\n }",
"protected void setScore(int s)\r\n\t{\r\n\t\tGame.score = s;\r\n\t}",
"public void resetScore() {\n\t\tthis.score = 0;\n\t}",
"public void setTopuserid(Integer topuserid) {\n this.topuserid = topuserid;\n }",
"private void setPreviousHighScores() {\n highScoreSharedPref = this.getSharedPreferences(\"MyPref\", Context.MODE_PRIVATE);\n highScore = highScoreSharedPref.getInt(\"Score\", 0);\n tvHighScore.setText(String.format(\"%d\", highScore));\n }",
"public void changeScore(String score) {\n typeScore(score);\n saveChanges();\n }",
"LinkedHashMap<String, Integer> getTopScores() {\n return this.topScores;\n }",
"@Override\n public int higherScore() {\n if (!scoresUpToDate) {\n updateScores();\n }\n return higherScore;\n }",
"public void setScorer(String name, int score)\r\n\t{\r\n\t\tif(scorers == null)\r\n\t\t{\r\n\t\t\tcreateArray();\r\n\t\t\twriteFile();\r\n\t\t}\r\n\t\t\r\n\t\tfor(int i = 1; i < scorers.length; i += 2)\r\n\t\t\tif(Integer.parseInt(scorers[i]) < score)\r\n\t\t\t{\r\n\t\t\t\tfor(int j = scorers.length - 4; j >= i - 1; j -= 2)\r\n\t\t\t\t{\r\n\t\t\t\t\tscorers[j + 2] = scorers[j];\r\n\t\t\t\t\tscorers[j + 3] = scorers[j + 1];\r\n\t\t\t\t}\r\n\t\t\t\t\r\n\t\t\t\tscorers[i - 1] = name;\r\n\t\t\t\tscorers[i] = String.valueOf(score);\r\n\t\t\t\twriteFile();\r\n\t\t\t\treturn;\r\n\t\t\t}\r\n\t}",
"public void setScore(){\n\t\t//get player's score and change it to the string\n\t\tthis.scoreLabel.setSize(scoreLabel.getPreferredSize().width, \n\t\t\t\tscoreLabel.getPreferredSize().height);\n\t\tthis.scoreLabel.setText(String.valueOf(this.player.getScore()));\n\t}",
"public void setTechScore (java.lang.Float techScore) {\n\t\tthis.techScore = techScore;\n\t}",
"public void set(String query, float score) {\r\n\t\tthis.score = score;\r\n\t\tthis.query = query;\r\n\t}",
"void setFitnessScore(double score){\n fitnessScore = score;\n }",
"public void setOfficeHoursScore(double officeHoursScore) {\r\n if (officeHoursScore <= 1 && officeHoursScore >= 0) {\r\n this.officeHoursScore = officeHoursScore;\r\n }\r\n }",
"private void setPlayerScore(Player player, int newScore) {\n\t\tplayer.score = Math.max(newScore, 0);\n\t\tfor (ScoreMarker scoreMarker : playerScoreMarkers) {\n\t\t\tif (scoreMarker.getOwner() == player) {\n\t\t\t\tscoreMarker.value = String.valueOf(player.score);\n\t\t\t}\n\t\t}\n\t}",
"public void setLblScore(JLabel lblScore) {\r\n\t\tthis.lblScore = lblScore;\r\n\t}",
"public Builder setScore(long value) {\n \n score_ = value;\n onChanged();\n return this;\n }",
"public Builder setScore(long value) {\n \n score_ = value;\n onChanged();\n return this;\n }",
"public void setScore(int s) {\n if (s > getHighScore()) {\n setHighScore(s);\n DateTimeFormatter dtf = DateTimeFormatter.ofPattern(\"yyyy/MM/dd HH:mm:ss\");\n LocalDateTime now = LocalDateTime.now();\n String timeNow = dtf.format(now);\n setHighScoreTime(timeNow);\n }\n setStat(s, score);\n }",
"public void setTopSpeed(int topSpeed) {\n\t\tif (topSpeed >= 0 && topSpeed <= 70) {\n\t\t\tthis.topSpeed = topSpeed;\n\t\t} \n\t\telse {\n\t\t\tSystem.out.println(\"Invalid Speed\");\n\t\t}\n\t\t\n\t}",
"public boolean setScoreTeamTwo(int score)\r\n\t{\r\n\t\tif (!editableMatch)\r\n\t\t\treturn false;\r\n\t\tscore2 = score;\r\n\t\treturn true;\r\n\t}",
"@Override\n\tpublic void setPlayerTwoScore(int playerTwoScore) {\n\t\tsuper.setPlayerTwoScore(playerTwoScore);\n\t}",
"public void setWordScore(int score) {\n if (score == 0) {\n this.wordScoreDisplay.setText(\"\");\n } else {\n this.wordScoreDisplay.setText(String.valueOf(score));\n }\n }",
"public void setVisitorScore(int visitorScore) {\n this.visitorScore = visitorScore;\n }",
"public boolean setScoreTeamOne(int score)\r\n\t{\r\n\t\tif (!editableMatch)\r\n\t\t\treturn false;\r\n\t\tscore1 = score;\r\n\t\treturn true;\r\n\t}",
"private void setScore(Stack a) {\n\n //clears the current high score\n items.clear();\n\n //adds the high score from stack\n for (Node i = a.top; i != null; i = i.next) {\n\n items.add(i.name + \" \" + i.score);\n\n }\n\n //displays the new high scores again\n List = new JList(items.toArray());\n ScrollView.setViewportView(List);\n\n }",
"public void setScore(int hole, int score) {\n\t\tif (hole < 1 || hole > 18) return;\n\t\tscores[hole - 1] = score;\n\t}",
"public void updateScore(){\r\n if (this.isArtist || winners.contains(this)) {\r\n this.score += pointsGainedLastRound;\r\n }\r\n pointsGainedLastRound = 0;\r\n placeLastRound = 0;\r\n }",
"public void setScores(ArrayList<Integer> scores) { this.scores = scores; }",
"public LocationScore(int score) {\n this.score = score;\n }",
"public void setTopmoney(Integer topmoney) {\n this.topmoney = topmoney;\n }"
] | [
"0.68602824",
"0.6695898",
"0.66855836",
"0.6600949",
"0.65930176",
"0.65797895",
"0.65634394",
"0.65634394",
"0.653608",
"0.653608",
"0.653608",
"0.653608",
"0.6530326",
"0.6492945",
"0.64793307",
"0.6463494",
"0.6453645",
"0.64504",
"0.6420857",
"0.6384388",
"0.6361842",
"0.6355809",
"0.6336035",
"0.63113767",
"0.6165172",
"0.61469924",
"0.6114807",
"0.61117095",
"0.6106299",
"0.61046064",
"0.6094652",
"0.60758907",
"0.60733265",
"0.60442835",
"0.6027767",
"0.6024342",
"0.5999056",
"0.59987754",
"0.5976133",
"0.59748113",
"0.59708905",
"0.59464186",
"0.59148145",
"0.5898468",
"0.5842392",
"0.58210784",
"0.5759157",
"0.57559705",
"0.57396156",
"0.5729704",
"0.5724824",
"0.5683472",
"0.5650947",
"0.5640632",
"0.5632845",
"0.56319386",
"0.56189567",
"0.561072",
"0.56053936",
"0.5599394",
"0.5590194",
"0.55661803",
"0.55324763",
"0.553047",
"0.5520774",
"0.55065036",
"0.5502652",
"0.5499469",
"0.54947424",
"0.5492057",
"0.5472298",
"0.54646885",
"0.5462506",
"0.5457236",
"0.5440537",
"0.54198277",
"0.5409185",
"0.54027396",
"0.5383155",
"0.5372966",
"0.5369595",
"0.5365224",
"0.53593427",
"0.5359151",
"0.53582716",
"0.5356029",
"0.5356029",
"0.5345804",
"0.5331011",
"0.5327777",
"0.53251195",
"0.53157234",
"0.53152645",
"0.5315065",
"0.52991456",
"0.52930135",
"0.5284284",
"0.5262899",
"0.5249478",
"0.5247439"
] | 0.80645 | 0 |
Return type metadata object | public static org.apache.axis.description.TypeDesc getTypeDesc() {
return typeDesc;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public MetadataType getType();",
"public MetadataType getType() {\n return type;\n }",
"public MilanoTypeMetadata.TypeMetadata getMetadata()\n {\n if (typeMetadata == null) {\n return null;\n }\n\n return typeMetadata;\n }",
"private Metadata getMetadata(RubyModule type) {\n for (RubyModule current = type; current != null; current = current.getSuperClass()) {\n Metadata metadata = (Metadata) current.getInternalVariable(\"metadata\");\n \n if (metadata != null) return metadata;\n }\n \n return null;\n }",
"public Metadata getMetadata( MetadataType type )\n\t{\n\t\tfor( Metadata metadata: mMetadata )\n\t\t{\n\t\t\tif( metadata.getMetadataType() == type )\n\t\t\t{\n\t\t\t\treturn metadata;\n\t\t\t}\n\t\t}\n\t\t\n\t\treturn null;\n\t}",
"Metadata getMetaData();",
"public List<TypeMetadata> getTypeMetadata() {\n return types;\n }",
"@Override\n public Class<? extends Metadata> getMetadataType() {\n throw new RuntimeException( \"Not yet implemented.\" );\n }",
"String getType();",
"String getType();",
"String getType();",
"String getType();",
"String getType();",
"String getType();",
"String getType();",
"String getType();",
"String getType();",
"String getType();",
"String getType();",
"String getType();",
"String getType();",
"String getType();",
"String getType();",
"String getType();",
"String getType();",
"String getType();",
"String getType();",
"String getType();",
"String getType();",
"String getType();",
"String getType();",
"String getType();",
"String getType();",
"public MetaData getMetaData();",
"private Class<?> getType(final Object metadata, final ValueNode node) throws ParseException {\n if (node.type != null) {\n return readType(node);\n }\n Class type;\n if (metadata instanceof ReferenceSystemMetadata || metadata instanceof Period || metadata instanceof AbstractTimePosition || metadata instanceof Instant) {\n final Method getter = ReflectionUtilities.getGetterFromName(node.name, metadata.getClass());\n return getter.getReturnType();\n } else {\n type = standard.asTypeMap(metadata.getClass(), KeyNamePolicy.UML_IDENTIFIER, TypeValuePolicy.ELEMENT_TYPE).get(node.name);\n }\n final Class<?> special = specialized.get(type);\n if (special != null) {\n return special;\n }\n return type;\n }",
"public Map<String, Variant<?>> GetMetadata();",
"public String getType();",
"public String getType();",
"public String getType();",
"public String getType();",
"public String getType();",
"public String getType();",
"public String getType();",
"public String getType();",
"public String getType();",
"public String getType();",
"public String getType();",
"public String getType();",
"public String getType();",
"public TypeSummary getTypeSummary() {\r\n return type;\r\n }",
"java.lang.String getType();",
"java.lang.String getType();",
"java.lang.String getType();",
"java.lang.String getType();",
"java.lang.String getType();",
"java.lang.String getType();",
"java.lang.String getType();",
"java.lang.String getType();",
"java.lang.String getType();",
"java.lang.String getType();",
"java.lang.String getType();",
"java.lang.String getType();",
"java.lang.String getType();",
"String provideType();",
"public Type getType();",
"@Override\n public String toString() {\n return metaObject.getType().toString();\n }",
"public String metadataClass() {\n return this.metadataClass;\n }",
"Type getType();",
"Type getType();",
"Type getType();",
"Type getType();",
"Type getType();",
"Type getType();",
"Type getType();",
"Type getType();",
"Type getType();",
"Type getType();",
"Type getType();",
"abstract public Type getType();",
"public String type();",
"private String getType(){\r\n return type;\r\n }",
"Coding getType();",
"protected abstract String getType();",
"type getType();",
"@Override\n TypeInformation<T> getProducedType();",
"TypeDefinition createTypeDefinition();",
"abstract public String getType();",
"public abstract String getType();",
"public abstract String getType();",
"public abstract String getType();",
"public abstract String getType();",
"public abstract String getType();",
"public abstract String getType();",
"public abstract String getType();",
"public abstract String getType();",
"public abstract Type getType();",
"protected static LibMetaData createLibMetaData(LibMetaData lmd) {\n MetaData metaData = new MetaData();\r\n metaData.add(\"IsThing\", new Integer(1), null, MetaDataEntry.FIX_VALUE, MetaDataEntry.MANDATORY_PROPERTY);\r\n metaData.add(\"ImageSource\", \"Items\", null, MetaDataEntry.ANY_VALUE, MetaDataEntry.MANDATORY_PROPERTY);\r\n metaData.add(\"Image\", new Integer(0), null, MetaDataEntry.POSITIVE_VALUE, MetaDataEntry.MANDATORY_PROPERTY);\r\n metaData.add(\"Number\", new Integer(1), null, MetaDataEntry.POSITIVE_VALUE, MetaDataEntry.MANDATORY_PROPERTY);\r\n lmd.add(THING, metaData);\r\n \r\n metaData = new MetaData(lmd.get(\"thing\"));\r\n metaData.add(\"IsItem\", new Integer(1), null, MetaDataEntry.FIX_VALUE, MetaDataEntry.MANDATORY_PROPERTY);\r\n metaData.add(\"ImageSource\", \"Items\", null, MetaDataEntry.ANY_VALUE, MetaDataEntry.MANDATORY_PROPERTY);\r\n metaData.add(\"Image\", new Integer(1), null, MetaDataEntry.POSITIVE_VALUE, MetaDataEntry.MANDATORY_PROPERTY);\r\n metaData.add(\"Name\", \"Thing\", null, MetaDataEntry.ANY_VALUE, MetaDataEntry.MANDATORY_PROPERTY);\r\n metaData.add(\"NameType\", new Integer(Description.NAMETYPE_NORMAL), null, MetaDataEntry.FIX_VALUE, MetaDataEntry.MANDATORY_PROPERTY);\r\n metaData.add(\"Z\", new Integer(Thing.Z_ITEM), null, MetaDataEntry.FIX_VALUE, MetaDataEntry.MANDATORY_PROPERTY);\r\n lmd.add(ITEM, metaData);\r\n \r\n metaData = new MetaData(lmd.get(\"thing\"));\r\n metaData.add(\"IsBeing\",new Integer(1), null, MetaDataEntry.FIX_VALUE, MetaDataEntry.MANDATORY_PROPERTY);\r\n metaData.add(\"ImageSource\", \"Creatures\", null, MetaDataEntry.ANY_VALUE, MetaDataEntry.MANDATORY_PROPERTY);\r\n metaData.add(\"Image\", new Integer(340), null, MetaDataEntry.POSITIVE_VALUE, MetaDataEntry.MANDATORY_PROPERTY);\r\n metaData.add(\"IsMobile\",new Integer(1), new Integer[]{new Integer(0), new Integer(1)}, MetaDataEntry.CERTAIN_VALUES, MetaDataEntry.MANDATORY_PROPERTY);\r\n metaData.add(\"IsBlocking\", new Integer(1), new Integer[]{new Integer(0), new Integer(1)}, MetaDataEntry.CERTAIN_VALUES, MetaDataEntry.MANDATORY_PROPERTY);\r\n metaData.add(\"MoveCost\", new Integer(100), null, MetaDataEntry.POSITIVE_VALUE, MetaDataEntry.MANDATORY_PROPERTY);\r\n metaData.add(\"DeathDecoration\", \"blood pool\", null, MetaDataEntry.ANY_VALUE, MetaDataEntry.MANDATORY_PROPERTY);\r\n metaData.add(\"NameType\", new Integer(Description.NAMETYPE_NORMAL), null, MetaDataEntry.FIX_VALUE, MetaDataEntry.MANDATORY_PROPERTY);\r\n metaData.add(\"Z\", new Integer(Thing.Z_MOBILE), null, MetaDataEntry.FIX_VALUE, MetaDataEntry.MANDATORY_PROPERTY);\r\n lmd.add(BEING, metaData);\r\n \r\n lmd = createEffectMetaData(lmd);\r\n lmd = createPoisonMetaData(lmd);\r\n lmd = createFoodMetaData(lmd);\r\n lmd = createScrollMetaData(lmd);\r\n lmd = createMissileMetaData(lmd);\r\n lmd = createRangedWeaponMetaData(lmd);\r\n lmd = createPotionMetaData(lmd);\r\n lmd = createWandMetaData(lmd);\r\n lmd = createRingMetaData(lmd);\r\n lmd = createCoinMetaData(lmd);\r\n lmd = createArmourMetaData(lmd);\r\n lmd = createWeaponMetaData(lmd);\r\n lmd = createSecretMetaData(lmd);\r\n lmd = createSpellBookMetaData(lmd);\r\n lmd = createChestMetaData(lmd);\r\n lmd = createDecorationMetaData(lmd);\r\n lmd = createSceneryMetaData(lmd);\r\n lmd = createPortalMetaData(lmd);\r\n lmd = createTrapMetaData(lmd);\r\n createMonsterMetaData(lmd);\r\n createPersonMetaData(lmd);\r\n return lmd;\r\n }",
"String getTypeAsString();",
"public gov.niem.niem.structures._2_0.MetadataType getMetadata()\n {\n synchronized (monitor())\n {\n check_orphaned();\n gov.niem.niem.structures._2_0.MetadataType target = null;\n target = (gov.niem.niem.structures._2_0.MetadataType)get_store().find_element_user(METADATA$0, 0);\n if (target == null)\n {\n return null;\n }\n return target;\n }\n }",
"TypeRef getType();",
"public Class getType();"
] | [
"0.7971625",
"0.7375903",
"0.73574775",
"0.7088938",
"0.67345047",
"0.6722243",
"0.6673762",
"0.6564602",
"0.65463895",
"0.65463895",
"0.65463895",
"0.65463895",
"0.65463895",
"0.65463895",
"0.65463895",
"0.65463895",
"0.65463895",
"0.65463895",
"0.65463895",
"0.65463895",
"0.65463895",
"0.65463895",
"0.65463895",
"0.65463895",
"0.65463895",
"0.65463895",
"0.65463895",
"0.65463895",
"0.65463895",
"0.65463895",
"0.65463895",
"0.65463895",
"0.65463895",
"0.65072185",
"0.6483538",
"0.63493025",
"0.63325065",
"0.63325065",
"0.63325065",
"0.63325065",
"0.63325065",
"0.63325065",
"0.63325065",
"0.63325065",
"0.63325065",
"0.63325065",
"0.63325065",
"0.63325065",
"0.63325065",
"0.62966293",
"0.6288614",
"0.6288614",
"0.6288614",
"0.6288614",
"0.6288614",
"0.6288614",
"0.6288614",
"0.6288614",
"0.6288614",
"0.6288614",
"0.6288614",
"0.6288614",
"0.6288614",
"0.62882614",
"0.6279062",
"0.6266853",
"0.6234272",
"0.62322754",
"0.62322754",
"0.62322754",
"0.62322754",
"0.62322754",
"0.62322754",
"0.62322754",
"0.62322754",
"0.62322754",
"0.62322754",
"0.62322754",
"0.6224174",
"0.6211103",
"0.6198329",
"0.61830914",
"0.61823857",
"0.6171411",
"0.61694896",
"0.6165736",
"0.6163545",
"0.6148128",
"0.6148128",
"0.6148128",
"0.6148128",
"0.6148128",
"0.6148128",
"0.6148128",
"0.6148128",
"0.6144234",
"0.61383814",
"0.61365765",
"0.61221075",
"0.6119316",
"0.6110877"
] | 0.0 | -1 |
file to upload absolute or relative path | Path fileToUpload(); | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"void uploadingFile(String path);",
"void fileUploaded(String path);",
"public String uploadFile(UploadedFile file) {\n String fileName = (file.getFileName());\r\n System.out.println(\"***** fileName: \" + file.getFileName());\r\n \r\n System.out.println(System.getProperty(\"os.name\"));\r\n String basePath = \"C:\" + File.separator + \"aquivosCI\" + File.separator;\r\n System.out.println(\"BasePath: \" + basePath);\r\n File outputFilePath = new File(basePath + fileName);\r\n\r\n// Copy uploaded file to destination path\r\n InputStream inputStream = null;\r\n OutputStream outputStream = null;\r\n try {\r\n inputStream = file.getInputstream();\r\n outputStream = new FileOutputStream(outputFilePath);\r\n\r\n int read = 0;\r\n final byte[] bytes = new byte[1024];\r\n while ((read = inputStream.read(bytes)) != -1) {\r\n outputStream.write(bytes, 0, read);\r\n }\r\n\r\n } catch (IOException e) {\r\n e.printStackTrace();\r\n\r\n } finally {\r\n if (outputStream != null) {\r\n try {\r\n outputStream.close();\r\n } catch (IOException ex) {\r\n Logger.getLogger(ComunicacaoInternaMB.class.getName()).log(Level.SEVERE, null, ex);\r\n }\r\n }\r\n if (inputStream != null) {\r\n try {\r\n inputStream.close();\r\n } catch (IOException ex) {\r\n Logger.getLogger(ComunicacaoInternaMB.class.getName()).log(Level.SEVERE, null, ex);\r\n }\r\n }\r\n }\r\n return outputFilePath.getAbsolutePath(); // return to same page\r\n }",
"File retrieveFile(String absolutePath);",
"@PostMapping(\"/upload\")\n public String handleFileUpload(@RequestParam MultipartFile file) throws IOException {\n final Path uploadDestination = Paths.get(\"C:\\\\uploads\").resolve(file.getName());\n\n file.transferTo(uploadDestination);\n return \"redirect:/\";\n }",
"@Override\n public String getAbsolutePathImpl() {\n return file.getAbsolutePath();\n }",
"public static void uploadFile(HttpServletRequest request, MultipartFile file, String code) {\n\t\tREAL_PATH = request.getSession().getServletContext().getRealPath(\"/assets/images/\");\n\t\t\n\t\tlogger.info(REAL_PATH);\n\t\t\n\t\tif (!new File(REAL_PATH).exists()) {\n\t\t\tnew File(REAL_PATH).mkdirs();\n\t\t}\n\t\tif (!new File(ABSOLUTE_PATH).exists()) {\n\t\t\tnew File(ABSOLUTE_PATH).mkdirs();\n\t\t}\n\t\t\n\t\ttry {\n\t\t\t// uploading ... project directory upload\n\t\t\tfile.transferTo(new File(ABSOLUTE_PATH + code + \".jpg\"));\n\t\t\t\n\t\t\t// uploading ... for the server\n\t\t\tfile.transferTo(new File(REAL_PATH + code + \".jpg\"));\n\t\t} catch (IOException e) {\n\t\t\t\n\t\t\te.printStackTrace();\n\t\t}\n\t}",
"UploadInfo simpleUpload(SimpleFile file);",
"public void upoadFile(MultipartFile file) {\n\t\t\n\t\ttry\n\t\t{\n\t\t\t\n\t\t if(!Files.isDirectory(path))\n\t\t {\n\t\t\t System.out.println(\"Directory Created\"+path);\n\t\t\t Files.createDirectories(path);\n\t\t }\n\t\t String fileName=file.getOriginalFilename();\n\t\t Files.copy(file.getInputStream(), this.path.resolve(fileName));\n\t\t System.out.println(\"File uploade details \");\n\t }catch(Exception e)\n\t\t{\n\t\t\tSystem.out.println(\"File uploade error \"+e.getMessage());\n\t\t\te.printStackTrace();\n\t\t}\n\t\t\n\t}",
"public String storeFile(MultipartFile file) {\n // Normalize file name\n String fileName = StringUtils.cleanPath(file.getOriginalFilename());\n\n try {\n // Check if the file's name contains invalid characters\n if(fileName.contains(\"..\")) {\n throw new FileStorageException(\"Sorry! Filename contains invalid path sequence \" + fileName);\n }\n\n // Copy file to the target location (Replacing existing file with the same name)\n Path targetLocation = this.fileStorageLocation.resolve(fileName);\n Files.copy(file.getInputStream(), targetLocation, StandardCopyOption.REPLACE_EXISTING);\n\n return fileName;\n } catch (IOException ex) {\n throw new FileStorageException(\"Could not store file \" + fileName + \". Please try again!\", ex);\n }\n }",
"URL toURL(FileReference fileReferece);",
"public static void uploadFile(HttpServletRequest request, MultipartFile file, String code) \r\n\t{\n\t\tREAL_PAIH=request.getSession().getServletContext().getRealPath(\"/assets/images/\");\r\n\t\t\r\n\t\tlogger.info(REAL_PAIH);\r\n\t\t\r\n\t\t//to make sure all directory exists\r\n\t\t//create new directory hmmmm\r\n\t\t\r\n\t\tif(!new File(ABS_PAIH).exists())\r\n\t\t{\r\n\t\t\t//create the directories\t\t\t\r\n\t\t\tnew File(ABS_PAIH).mkdirs();\r\n\t\t}\r\n\t\t\r\n\t\tif(!new File(REAL_PAIH).exists())\r\n\t\t{\r\n\t\t\t//create the directories\t\t\t\r\n\t\t\tnew File(REAL_PAIH).mkdirs();\r\n\t\t}\r\n\t\t\r\n\t\ttry\r\n\t\t{\r\n\t\t //server upload\r\n\t\t\tfile.transferTo(new File(REAL_PAIH + code + \".jpg\"));\r\n\t\t\t\r\n\t\t\t//project directory upload\r\n\t\t\tfile.transferTo(new File(ABS_PAIH + code + \".jpg\"));\r\n\r\n\t\t\t\r\n\t\t}catch(IOException e)\r\n\t\t{\r\n\t\t\te.printStackTrace();\r\n\t\t}\r\n\t\t\r\n\t\t\r\n\t}",
"public static File relativeFile(File root, File file) {\n if (root != null && file != null) {\n String absRoot = absoluteFile(root).getPath();\n String absFile = absoluteFile(file).getPath();\n if (absFile.startsWith(absRoot)) {\n String path = absFile.substring(absRoot.length());\n if (path.startsWith(File.separator)) {\n path = path.substring(1);\n }\n file = new File(path);\n }\n }\n return file;\n }",
"private void uploadFile(final File file) throws IOException {\n if (file != null) {\n Network.sendMsg(new FileMessage(Paths.get(file.getAbsolutePath())));\n }\n }",
"public String getAbsPath();",
"void whenUploadFile(MultipartFile file, HttpServletRequest request);",
"public String uploadFile(MultipartFile file) {\n\t\tString url;\r\n\t\tString visit = \"\";\r\n\t\tif (!file.isEmpty()) {\r\n try {\r\n \tSystem.out.println(\"进入文件上传\");\r\n \t//获取上传文件的文件类型\r\n \tString contentType=file.getContentType();\r\n \tif(contentType.startsWith(\"image/\")){\r\n \t//获取上传文件的文件名\r\n \tString name = file.getOriginalFilename();\r\n \t//获取文件的后缀\r\n \tint lastPoiIndex=name.lastIndexOf(\".\");\r\n \tString extendNam = null;\r\n \tif(lastPoiIndex>-1){\r\n \t\textendNam = name.substring(lastPoiIndex);\r\n \t\t\t}\r\n \t//确定新的文件名\r\n \t\t\tDate now=new Date();\r\n \t\t\t//获取当前时间\r\n \t\t\tSimpleDateFormat sdf=new SimpleDateFormat(\"yyyyMMddHHmmssSSS\");\r\n \t\t\tString newFileName=sdf.format(now)+extendNam;\r\n \t//文件储存的地址/WEB-INF/classes/resources/\r\n \t\t\turl =System.getProperty(\"user.dir\")+\"/src/main/resources/static/img/login/\"+newFileName;\r\n \tvisit = \"../img/login/\"+newFileName;\r\n// \turl =System.getProperty(\"user.dir\")+\"/\"+newFileName;\r\n//\t\t\t\treplace替换字符串\r\n// \turl =url1.replace(\"bin\",\"webapps/PIDStudioDemo/WEB-INF/classes/static/img/login\");\r\n \tvisit = \"../img/login/\"+newFileName;\r\n \tSystem.out.println(url);\r\n BufferedOutputStream out = new BufferedOutputStream(new FileOutputStream(new File(url)));//储存文件到指定地址\t \r\n out.write(file.getBytes());\r\n out.flush();\r\n out.close();//关闭\r\n System.out.println(\"上传成功\");\r\n }else {\r\n \tSystem.out.println(\"文件不是图片\");\r\n \t return \"\";\r\n }\r\n } catch (FileNotFoundException e) {\r\n e.printStackTrace();\r\n return \"\";\r\n } catch (IOException e) {\r\n e.printStackTrace();\r\n return \"\" ;\r\n }\r\n return visit ;\r\n } else {\r\n return \"\";\r\n }\r\n\t}",
"UploadInfo advancedUpload(AdvanceFile file);",
"@Override\n public boolean transferFile (MultipartFile file, String tag, String resultFilename) {\n try {\n file.transferTo(new File(Constans.UPLOADPATH + \"/\" + tag + \"/\" + resultFilename));\n }catch (IOException e){\n e.printStackTrace();\n return false;\n }\n return true;\n }",
"public String putFile(String path, File file){\n final FileDataBodyPart filePart = new FileDataBodyPart( \"file\", file );\n final FormDataMultiPart multipart = (FormDataMultiPart) new FormDataMultiPart()\n .bodyPart( filePart );\n return target.path( path ).request()\n .post( Entity.entity( multipart, multipart.getMediaType() ), String.class );\n }",
"@Override\n public void store(MultipartFile file, String path) {\n String filename = StringUtils.cleanPath(file.getOriginalFilename());\n try {\n if (file.isEmpty()) {\n throw new StorageException(\"Failed to store empty file \" + filename);\n }\n if (filename.contains(\"..\")) {\n // This is a security check\n throw new StorageException(\n \"Cannot store file with relative path outside current directory \"\n + filename);\n }\n\n \t\t// upload file to s3\n \t\tString fileName = path + \"/\" + filename;\n\n \t\tthis.s3client.putObject(new PutObjectRequest(this.s3_storage_properties.getBucketName(), fileName,\n \t\t\t\tfile.getInputStream(), new ObjectMetadata())\n .withCannedAcl(CannedAccessControlList.PublicRead));\n Application.logger.info(\"Stored \"+fileName+\" into S3\");\n }\n catch (IOException e) {\n throw new StorageException(\"Failed to store file \" + filename, e);\n }\n }",
"private File getFile(String fileName, HttpServletRequest request){\n\t\tString fileSite = request.getSession().getServletContext().getRealPath(\"resources/upload\"); // 배포폴더\n\t\treturn new File(fileSite, fileName);\n\t}",
"public abstract String getFileLocation();",
"public abstract String getFullPath();",
"public void uploadFile() {\n \n InputStream input = null;\n try {\n input = file.getInputStream();\n System.out.println(\"chay qua inpustream\");\n String itemName = file.getSubmittedFileName();\n String filename = itemName.substring(\n itemName.lastIndexOf(\"\\\\\") + 1);\n String dirPath = FacesContext.getCurrentInstance().getExternalContext().getRealPath(\"/upload/images\");\n fileNamed = \"/upload/images/\"+filename;\n File f = new File(dirPath + \"\\\\\" + filename);\n if (!f.exists()) {\n f.createNewFile();\n }\n FileOutputStream output = new FileOutputStream(f);\n byte[] buffer = new byte[1024];\n int length;\n while ((length = input.read(buffer)) > 0) {\n output.write(buffer, 0, length);\n }\n // resize(dirPath + \"\\\\\" + filename, dirPath + \"\\\\\" + filename, 200, 200);\n input.close();\n output.close();\n } catch (IOException ex) {\n System.out.println(\"loi io\");\n Logger.getLogger(ArtistsManagedBean.class.getName()).log(Level.SEVERE, null, ex);\n }\n \n }",
"public static File relativeFile(File f) {\n if (f.isAbsolute()) {\n f = relativeFile(new File(\".\"), f);\n }\n return f;\n }",
"protected File makeAbsolute(File f) {\r\n\tFile dir = curDir;\r\n\t\r\n\tif (!f.isAbsolute()) {\r\n\t if (dir == null) {\r\n\t\tf = f instanceof TypedFile\r\n\t\t? new TypedFile(f.getAbsolutePath(),\r\n\t\t\t\t((TypedFile)f).getType())\r\n\t\t: new File(f.getAbsolutePath());\r\n\t } else {\r\n\t\tf = f instanceof TypedFile\r\n\t\t? new TypedFile(dir.getPath(), f.getPath(),\r\n\t\t\t\t((TypedFile)f).getType())\r\n\t\t: new File(dir.getPath(), f.getPath());\r\n\t }\r\n\t}\r\n\t\r\n\treturn f;\r\n }",
"public static File absoluteFile(File file) {\n if (file != null) {\n try {\n file = file.getCanonicalFile();\n } catch (IOException e) {\n file = file.getAbsoluteFile();\n }\n }\n return file;\n }",
"public Path upload(final File localFile) throws IOException {\n\n if (!localFile.exists()) {\n throw new FileNotFoundException(localFile.getAbsolutePath());\n }\n\n final Path source = new Path(localFile.getAbsolutePath());\n final Path destination = new Path(this.path, localFile.getName());\n\n try {\n this.fileSystem.copyFromLocalFile(source, destination);\n } catch (final IOException ex) {\n LOG.log(Level.SEVERE, \"Unable to upload \" + source + \" to \" + destination, ex);\n throw ex;\n }\n\n LOG.log(Level.FINE, \"Uploaded {0} to {1}\", new Object[] {source, destination});\n\n return destination;\n }",
"public void upload(UploadedFile file) {\n FacesContext faces = FacesContext.getCurrentInstance();\n\n getSelected().setUrlImage(file.getFileName());\n String fileExtension = file.getFileName().split(\"\\\\.\")[file.getFileName().split(\"\\\\.\").length - 1];\n\n //String generatedFileName = \"file\" + System.currentTimeMillis();\n File directory = new File(faces.getExternalContext().getRealPath(UPLOAD_DIRECTORY_IMAGE_RELATIVE));\n\n if (!directory.exists()) {\n directory.mkdir();\n }\n\n File newFile = new File(faces.getExternalContext().getRealPath(UPLOAD_DIRECTORY_IMAGE_RELATIVE) + File.separator + file.getFileName());\n try {\n if (!newFile.createNewFile()) {\n String nameGenerated = \"file_generated\" + System.currentTimeMillis();\n newFile = new File(faces.getExternalContext().getRealPath(UPLOAD_DIRECTORY_IMAGE_RELATIVE) + File.separator + nameGenerated + \".\" + fileExtension);\n getSelected().setUrlImage(nameGenerated);\n }\n\n FileOutputStream output = new FileOutputStream(newFile);\n\n byte[] buffer = new byte[BUFFER];\n\n int bulk;\n\n InputStream input = file.getInputstream();\n\n while (true) {\n bulk = input.read(buffer);\n\n if (bulk < 0) {\n break;\n }\n\n output.write(buffer, 0, bulk);\n output.flush();\n }\n\n output.close();\n input.close();\n\n } catch (Exception ex) {\n ex.printStackTrace();\n FacesContext.getCurrentInstance().addMessage(\"\", new FacesMessage(bundle.getString(\"Error_file_created\")));\n }\n\n }",
"public void upload() {\r\n if (file != null) {\r\n try {\r\n String filepath = super.getUploadFolder() + \"/\" + file.getFileName();\r\n filepath = FileUtil.alternativeFilepathIfExists(filepath);\r\n FileUtil.createFile(filepath);\r\n\r\n file.write(filepath);\r\n super.info(\"Succesful\", file.getFileName() + \" is uploaded.\");\r\n\r\n Upload upload = new Upload();\r\n upload.setDescription(description);\r\n upload.setFilepath(filepath);\r\n upload.setTag(Md5Util.getMd5Sum(filepath));\r\n this.description = null;\r\n uploads.add(upload);\r\n // update ui and ready for save in db\r\n } catch (Exception e) {\r\n System.out.println(e);\r\n }\r\n }\r\n }",
"String getFilepath();",
"public String getFileUploadPath() {\n\t\treturn fileUploadPath;\n\t}",
"java.lang.String getFilePath();",
"String getRealPath(String path);",
"String getExternalPath(String path);",
"public interface UploadFileService {\n\tpublic String saveFile(MultipartFile file);\n\tResource findFileByName(String nameFile);\n\tpublic String saveFileVer(MultipartFile file, String pathToSave);\n}",
"Path getFilePath();",
"public String StoreFile(MultipartFile file) {\n \t \t\n // Normalize file name\n String fileName = StringUtils.cleanPath(file.getOriginalFilename());\n \n // Get any exiting versions of the file\n String[] fileNames = GetAllFileNames(fileName);\n int iNextIndex = fileNames.length + 1;\n \n // Increment the version of the file. All files start with 1.\n String fileNameIndexed = Integer.toString(iNextIndex) + \"_\" + fileName;\n \n try \n {\n // Check if the file's name contains invalid characters. ('_' if not valid because it's used to track version.)\n if(fileName.contains(\"..\") || fileName.contains(\"_\")) {\n throw new FileStorageException(\"Sorry! Filename contains invalid path sequence \" + fileName);\n }\n\n // Copy file to the target location (Replacing existing file with the same name)\n Path targetLocation = this.fileStorageLocation.resolve(fileNameIndexed);\n Files.copy(file.getInputStream(), targetLocation, StandardCopyOption.REPLACE_EXISTING);\n\n return fileName;\n } \n catch (IOException ex) \n {\n throw new FileStorageException(\"Could not store file \" + fileName + \". Please try again!\", ex);\n }\n }",
"public void upload_file(FileUploadEvent event) throws IOException {\n \t\n \tUploadedFile uploaded_file=event.getFile();\n \tFacesContext context = FacesContext.getCurrentInstance();\n \t\n\t\tHttpSession session = (HttpSession) FacesContext.getCurrentInstance()\n \t\t\t\t.getExternalContext().getSession(true);\n \t\tString pictures_folder=session.getAttribute(\"pictures_folder\").toString();\n \t\t\n \t\tPath folder = Paths.get(pictures_folder);\n\t\t\n\t\tString filename = FilenameUtils.getBaseName(uploaded_file.getFileName()); \n\t\tString extension = FilenameUtils.getExtension(uploaded_file.getFileName());\n\t\t//tou dinei rando onoma\n\t\tPath file = Files.createTempFile( folder,filename+\"-\" , \".\" + extension);\n\t\tSystem.out.println(\"folder: \"+folder.toString()+\"\\n\"+\"filename: \"+filename+\"\\n\"\n\t\t \t+ \"file: \"+file.toString());\n\t\t\n\t\tString profile_url;\n\t\ttry (InputStream input =uploaded_file.getInputstream()) {\n\t\t Files.copy(input, file, StandardCopyOption.REPLACE_EXISTING);\n\t\t profile_url=file.toString().split(\"/\")[file.toString().split(\"/\").length-1];\n\t\t}\n\n\t\tSystem.out.println(\"Uploaded picture successfully saved in \" + profile_url);\n\t\tString message=\"Pictures were uploaded Successfully\";\n\t\tFacesMessage facesMessage_11 = new FacesMessage(message);\n context.addMessage(files_upload_UI.getClientId(context), facesMessage_11);\n\t\t\n\t\t\n\t\t\n }",
"public abstract String getFotoPath();",
"public String getFileUploadUrl()\n\t\t{\n\t\t\treturn EU.getFileUploadUrl();\n\t\t}",
"public String getFileUploadUrl()\n\t\t{\n\t\t\treturn EU.getFileUploadUrl();\n\t\t}",
"public String getFileUploadUrl()\n\t\t{\n\t\t\treturn EU.getFileUploadUrl();\n\t\t}",
"private File getFile(String relativePath) { \n StringBuffer path = new StringBuffer();\n path.append(rootDir.getAbsolutePath());\n path.append(File.separator);\n path.append(relativePath);\n return new File(path.toString());\n }",
"private void fileUpload(HttpServletRequest request, HttpServletResponse response) {\n\t \ttry {\r\n\t\t\t\t\t/*\r\n\t\t\t\t\t * String appPath = request.getServletContext().getRealPath(\"\");\r\n\t\t\t\t\t * System.out.println(appPath); String savePath = appPath + File.separator +\r\n\t\t\t\t\t * SAVE_DIR; System.out.println(savePath);\r\n\t\t\t\t\t */\r\n\t \t\t\r\n\t \t\t//String appPath = getServletContext().getRealPath(SAVE_DIR);\r\n\t \t\tSystem.out.println(appPath);\r\n\t \t\t String savePath = appPath + \"//\" +SAVE_DIR; \r\n\t \t\t System.out.println(savePath);\r\n\t\t\t\t\t\tCollection<Part>cp= request.getParts();\r\n\t \t String fileName = up.fileUpload(cp,appPath);\r\n\t \t System.out.println(fileName);\r\n\t \t \r\n\t \t request.setAttribute(\"message\", \"The file \"+fileName+\" has been uploaded successfully!\");\r\n\t \t RequestDispatcher dispatcher = request.getRequestDispatcher(\"success.jsp\");\r\n\t \t dispatcher.forward(request, response);\r\n\t}catch(Exception ex) {\r\n System.out.println(ex);\r\n }\r\n\t }",
"@Test\n\tvoid testFileURI(@TempDir Path tempDir) {\n\t\tfinal File tempFile = tempDir.resolve(\"foo.bar\").toFile();\n\t\tfinal URI fileURI = Files.toURI(tempFile); //create a Java URI directly from a file\n\t\tassertThat(fileURI.getScheme(), is(FILE_SCHEME)); //file:\n\t\tassertTrue(fileURI.getRawPath().startsWith(ROOT_PATH)); //file:/\n\t\tassertFalse(fileURI.getRawPath().startsWith(ROOT_PATH + PATH_SEPARATOR + PATH_SEPARATOR)); //not file:/// (even though that is correct)\n\t}",
"public static File composeFile(URI base, String relativePath) {\n\t\tURI uri = composeURI(base, relativePath);\n\t\tif (uri.isAbsolute()) {\n\t\t\treturn new File(uri);\n\t\t} else if (base != null) {\n\t\t\treturn new File(new File(base), uri.toString());\n\t\t}\n\t\treturn null;\n\t}",
"String getFile();",
"String getFile();",
"String getFile();",
"@Test\n public void uploadTest() throws ApiException {\n String path = null;\n Integer devid = null;\n File file = null;\n api.upload(path, devid, file);\n\n // TODO: test validations\n }",
"public void setUploadPicture(String absolutePath) throws InterruptedException {\n URL url = getClass().getClassLoader().getResource(absolutePath);\n File file = null;\n try {\n file = new File(url.toURI());\n } catch (URISyntaxException e) {\n e.printStackTrace();\n }\n getDriver().findElement(uploadPicture).sendKeys(file.getAbsolutePath());\n Times.waitFor(2000);\n }",
"int uploadEto(File file, DataDate date, DataDate updated) throws IOException, SQLException;",
"public File fileRelativeToSource(File f) {\n if (f.isAbsolute()) {\n return f;\n } else {\n return new File(_basedir, f.getPath());\n }\n }",
"@Override\n\tpublic Result uploadFile(String requestUri, File uploadFile,\n\t\t\tFile uploadPath, HashMap<String, ContentBody> extraParts) {\n\t\treturn super.uploadFile(requestUri, uploadFile, uploadPath, extraParts);\n\t}",
"String getFilePath();",
"private String defineAbsoluteFilePath() throws IOException {\n\n\t\tString absoluteFilePath = \"\";\n\n\t\tString workingDir = System.getProperty(\"user.dir\");\n\n\t\tString OS = System.getProperty(\"os.name\").toLowerCase();\n\n\t\tif (OS.indexOf(\"win\") >= 0) {\n\t\t\tabsoluteFilePath = workingDir + \"\\\\\" + PATH + \"\\\\\" + FILE_NAME;\n\t\t} else {\n\t\t\tabsoluteFilePath = workingDir + \"/\" + PATH + \"/\" + FILE_NAME;\n\t\t}\n\n\t\tFile file = new File(absoluteFilePath);\n\n\t\tif (file.exists()) {\n\t\t\tSystem.out.println(\"File found!\");\n\t\t\tSystem.out.println(absoluteFilePath);\n\t\t} else {\n\t\t\tSystem.err.println(\"File not found...\");\n\t\t}\n\n\t\treturn absoluteFilePath;\n\n\t}",
"private static File parsePath(String path) {\n\t\tpath = (path == null ? \"\" : path.trim());\n\t\tif (path.startsWith(\"file://\")) {\n\t\t\tpath = path.substring(\"file://\".length());\n\t\t} else if (path.startsWith(\"file:\")) { \n\t\t\tpath = path.substring(\"file:\".length());\t\n\t\t}\n\t\t\n\t\tif (path.length() == 0 || path.equals(\".\")) {\n\t\t\tpath = System.getProperty(\"user.dir\", \".\"); // CWD\n\t\t} else {\t\n\t\t\t// convert separators to native format\n\t\t\tpath = path.replace('\\\\', File.separatorChar);\n\t\t\tpath = path.replace('/', File.separatorChar);\n\t\t\t\n\t\t\tif (path.startsWith(\"~\")) {\n\t\t\t\t// substitute Unix style home dir: ~ --> user.home\n\t\t\t\tString home = System.getProperty(\"user.home\", \"~\");\n\t\t\t\tpath = home + path.substring(1);\n\t\t\t}\n\t\t}\n\t\t\n\t\treturn new File(path);\n\t}",
"public String saveToLocal(FormFile file, String newName, String path) {\n\t\tint ai=path.lastIndexOf(\"/\");\n\t\tif(ai<path.length())\n\t\t\tpath=path+\"/\";\n\t\tString type=null;\n\t\tString name=file.getFileName();\n\t\tint i=name.lastIndexOf(\".\");\n\t\ttype=name.substring(i+1,name.length());\n\t\tif(newName==null||newName.equals(\"\"))\n\t\t\tnewName=name;\n\t\telse\n\t\t{\n\t\t\tif(newName.lastIndexOf(\".\")==-1)\n\t\t\tnewName=newName+\".\"+type;\n\t\t}\n\t\ttry {\n\t\tFile f=new File(path);\n\t\tif(!f.exists())\n\t\t{\n\t\t\tf.mkdir();\n\t\t}\n\t\tf=new File(path+newName);\n\t\tif(!f.exists())\n\t\t{\n\t\t\t\n\t\t\t\tf.createNewFile();\n\t\t\t\n\t\t}\n\t\t\n\t\tFileOutputStream fos=new FileOutputStream(f);\n\t\tfos.write(file.getFileData());\n\t\tfos.close();\n\t\t} catch (FileNotFoundException e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\tlog.error(this,e);\n\t\t} catch (IOException e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\tlog.error(this,e);\n\t\t}\n\t\treturn url+newName;\n\t}",
"@Override\n public String saveFile(MultipartFile file, String rootDirectory ) {\n String path = null;\n try {\n if (file != null && !file.isEmpty()) {\n java.util.Date date = new java.util.Date();\n int i = (int) (date.getTime() / 1000);\n String extention = file.getOriginalFilename().substring(file.getOriginalFilename().lastIndexOf(\".\")+1);\n String fileName =file.getOriginalFilename().substring(0, file.getOriginalFilename().lastIndexOf(\".\"));\n path = rootDirectory + fileName + \"-\" + i + \".\"+ extention;\n\n File finalFilePath = new File(path);\n //create all path directories if not exist\n finalFilePath.getParentFile().mkdirs();\n file.transferTo(new File(path));\n }\n } catch (IOException e) {\n e.printStackTrace();\n }\n return path;\n }",
"private boolean saveFile(ClientInterface client, MyTubeFile file){\n try{\n byte[] content = client.readFile(file.getFilename());\n String savepath = uploadsPath+\"/\"+Integer.toString(file.getId());\n new File(savepath).mkdir();\n savepath += \"/\"+ file.getFilename();\n\n try (FileOutputStream fos = new FileOutputStream(savepath)) {\n fos.write(content);\n return true;\n }\n }catch(IOException e){\n return false;\n }\n }",
"public String copy(MultipartFile file) throws IOException;",
"public void upload( Reporte reporte, File file) throws IOException{\n RequestBody formBody = new MultipartBody.Builder()\n .setType(MultipartBody.FORM)\n .addFormDataPart(\"file\", reporte.id+\"_\"+file.getName(), RequestBody.create(MediaType.parse(\"image/jpeg\"), file))\n .build();\n Request request = new Request.Builder()\n .url(BASE_URL+\"/upload\")\n .post(formBody)\n .build();\n\n client.newCall(request).enqueue(new Callback(){\n\n @Override\n public void onFailure(Call call, IOException e) {\n\n }\n\n @Override\n public void onResponse(Call call, Response response) throws IOException {\n System.out.println(response.body().string());\n }\n });\n }",
"public static String composePath(URI base, String relativePath) {\n\t\tURI uri = composeURI(base, relativePath);\n\t\tif (uri.isAbsolute()) {\n\t\t\tFile file = new File(uri);\n\t\t\treturn file.toString();\n\t\t} else if (base != null) {\n\t\t\tFile file = new File(new File(base), uri.toString());\n\t\t\treturn file.toString();\n\t\t}\n\t\treturn relativePath;\n\t}",
"public static String getAbsoluteFilePath(String relativePath) throws URISyntaxException {\n URL fileResource = BCompileUtil.class.getClassLoader().getResource(relativePath);\n String pathValue = \"\";\n if (null != fileResource) {\n Path path = Paths.get(fileResource.toURI());\n pathValue = path.toAbsolutePath().toString();\n }\n return pathValue;\n }",
"public void uploadFile(WebElement uploadfileelement, String filepath, By buttonelement) {\n\n\t\ttry {\n\t\t\t// enter the file path onto the file-selection input field\n\t\t\tuploadfileelement.sendKeys(filepath);\n\t\t\t// click the \"Upload\" button\n\t\t\tdriver.findElement(buttonelement).click();\n\t\t} catch (NoSuchElementException ex) {\n\t\t\tex.printStackTrace();\n\t\t}\n\n\t}",
"private String getUploadFileName() {\r\n\t\tJFileChooser fc = new JFileChooser(\"./\");\r\n\t\tint returnVal = fc.showOpenDialog(this);\r\n\t\tif (returnVal != JFileChooser.APPROVE_OPTION) {\r\n\t\t\treturn \"\";\r\n\t\t}\r\n\t\tFile quizFile = fc.getSelectedFile();\r\n\t\treturn quizFile.getAbsolutePath();\r\n\t}",
"Path getContent(String filename);",
"public void uploadFile(String filePath) {\n fileUploadContainer.file.sendKeys(filePath);\n }",
"public static String getAbsoluteResourcePath(String resourcePathInPlugin) {\r\n String pluginPath = RichFacesTemplatesActivator.getPluginResourcePath();\r\n IPath pluginFile = new Path(pluginPath);\r\n File file = pluginFile.append(resourcePathInPlugin).toFile();\r\n if (file.exists()) {\r\n return file.getAbsolutePath();\r\n } else {\r\n throw new IllegalArgumentException(\"Can't get path for \" //$NON-NLS-1$\r\n + resourcePathInPlugin);\r\n }\r\n }",
"@PostMapping(\"/upload\")\n\tpublic ResponseEntity<String> upload(@RequestParam(\"doc\") MultipartFile file){\n\t\tFile storedFile = storageService.store(file);\n\t\tif(storedFile == null) {\n\t\t\treturn new ResponseEntity<>(HttpStatus.INTERNAL_SERVER_ERROR);\n\t\t}\n\t\tString filename = storedFile.getName();\n\t\t\t\t\n\t\treturn new ResponseEntity<>(filename, HttpStatus.OK);\n\t}",
"public static void upload_file(By locator, String filePath) throws CheetahException {\n\t\ttry {\n\t\t\twait_for_element(locator);\n\t\t\tWebElement element = CheetahEngine.getDriverInstance().findElement(locator);\n\t\t\tdriverUtils.highlightElement(element);\n\t\t\tdriverUtils.unHighlightElement(element);\n\t\t\telement.sendKeys(filePath);\n\n\t\t} catch (Exception e) {\n\t\t\tthrow new CheetahException(e);\n\t\t}\n\t}",
"static boolean uploadIfNecessary(Configuration conf)\n throws IOException {\n String local = conf.get(LOCAL_INPUT);\n if (local == null) {\n return false;\n }\n FileSystem fs = FileSystem.get(conf);\n String current = new File(\"\").getAbsolutePath();\n Path sourcePath = new Path(current, local);\n Path destPath = getOutputPath(conf, \"input\");\n fs.copyFromLocalFile(false, true, sourcePath, destPath);\n conf.set(MRUtils.INPUT_PATH, destPath.toString());\n return true;\n }",
"private void testPathRelative(String rootdir, String basefilename, String filename, String filename_check) {\r\n\t\tString result;\r\n\t\tString base_filename = rootdir + File.separator + basefilename;\r\n\t\tString base_dir = FileUtils.baseDir(base_filename);\r\n\t\tString file_name = rootdir + File.separator + filename;\r\n\t\t\r\n\t\tresult = FileUtils.pathRelativeFile(base_filename, file_name).replaceAll(\"\\\\\\\\\", \"/\");\r\n\t\tassertEquals(result, filename_check);\r\n\t\t\r\n\t\tresult = FileUtils.pathRelative(base_dir, file_name).replaceAll(\"\\\\\\\\\", \"/\");\r\n\t\tassertEquals(result, filename_check);\r\n\t}",
"public String resolvePath();",
"private static File openFile(String path, FileSystem fs) {\n fs.updatePath();\n String fullFilePath;\n if (path.startsWith(\"/\")) {\n // path is abs\n fullFilePath = path;\n } else {\n // path is rel\n fullFilePath = fs.getCurrentPath() + path;\n }\n\n File targetFile = (File) fs.checkPath(fullFilePath, \"file\");\n if (targetFile == null) {\n // check for parent if it's null too\n String[] parentPathArr = fs.getParent(fullFilePath);\n if (!parentPathArr[0].startsWith(\"/\")) {\n // convert parent path to absolute\n parentPathArr[0] = toAbsPathStr(parentPathArr[0], fs);\n }\n Directory parentDir =\n (Directory) fs.checkPath(parentPathArr[0], \"directory\");\n if (parentDir == null) {\n // invalid parent path => the given path is invalid\n ErrorHandler.getErrorMessage(fullFilePath + \" is invalid path\");\n } else {\n // create file under the parentDir if name is okay\n if (fs.isValidNameForFileSystem(parentPathArr[1])) {\n targetFile = fs.createFileWithParent(parentPathArr[1], parentDir);\n } else {\n ErrorHandler.getErrorMessage(\"invalid file name\");\n }\n }\n }\n return targetFile;\n }",
"boolean safeIsFile(FsPath path);",
"public void writeToFile(InputStream uploadedInputStream, String relativePath) throws Exception {\n\n StringBuilder sb = new StringBuilder();\n sb.append(ConfigUtil.BASE_URL + relativePath);\n String uploadedFileLocation = sb.toString();\n OutputStream out = null;\n try {\n if(logger.isDebugEnabled()){\n logger.debug(\"Saving location of uploaded file :\"+uploadedFileLocation);\n }\n\n int read = 0;\n byte[] bytes = new byte[1024];\n\n out = new FileOutputStream(new File(uploadedFileLocation));\n while ((read = uploadedInputStream.read(bytes)) != -1) {\n out.write(bytes, 0, read);\n }\n } finally {\n if (out != null) {\n out.flush();\n out.close();\n }\n }\n }",
"@View(\"upload\")\n @Post(consumes = MediaType.MULTIPART_FORM_DATA)\n public HttpResponse upload(@Body CompletedFileUpload file) {\n Drive drive = null;\n try {\n drive = googleDriveAccessor.accessGoogleDrive();\n } catch (IOException e) {\n // Catch down below\n }\n\n if(drive == null) {\n return HttpResponse.serverError(CollectionUtils.mapOf(RSP_SERVER_ERROR_KEY,\n \"Unable to access Google Drive\"));\n }\n\n if ((file.getFilename() == null || file.getFilename().equals(\"\"))) {\n return HttpResponse.badRequest(CollectionUtils.mapOf(RSP_ERROR_KEY, \"Required file\"));\n }\n\n if(directoryKey == null) {\n return HttpResponse.serverError(CollectionUtils.mapOf(RSP_SERVER_ERROR_KEY,\n \"Directory key error, please contact admin\"));\n }\n\n JsonNode dirNode = null;\n try {\n dirNode = new ObjectMapper().readTree(this.getClass().getResourceAsStream(DIRECTORY_FILE_PATH));\n } catch (IOException e) {\n return HttpResponse.serverError(CollectionUtils.mapOf(RSP_SERVER_ERROR_KEY,\n \"Configuration error, please contact admin\"));\n }\n\n String parentId = dirNode.get(directoryKey) != null ? dirNode.get(directoryKey).asText() : null;\n if(parentId == null) {\n return HttpResponse.serverError(CollectionUtils.mapOf(RSP_SERVER_ERROR_KEY,\n \"Configuration error, please contact admin\"));\n }\n\n File fileMetadata = new File();\n fileMetadata.setName(file.getFilename());\n fileMetadata.setMimeType(file.getContentType().orElse(MediaType.APPLICATION_OCTET_STREAM_TYPE).toString());\n fileMetadata.setParents(List.of(parentId));\n\n InputStreamContent content;\n try {\n content = new InputStreamContent(fileMetadata.getMimeType(), file.getInputStream());\n } catch (IOException e) {\n return HttpResponse.badRequest(CollectionUtils.mapOf(RSP_ERROR_KEY,\n String.format(\"Unexpected error processing %s\", file.getFilename())));\n }\n\n try {\n drive.files().create(fileMetadata, content).setFields(\"parents\").execute();\n } catch (IOException e) {\n return HttpResponse.serverError(CollectionUtils.mapOf(RSP_SERVER_ERROR_KEY,\n \"Unable to upload file to Google Drive\"));\n }\n\n return HttpResponse.ok(CollectionUtils.mapOf(RSP_COMPLETE_MESSAGE_KEY,\n String.format(\"The file %s was uploaded\", file.getFilename())));\n }",
"static Path absolute(final Path path) {\n return path.toAbsolutePath().normalize();\n }",
"protected void moveUploadIntoPlace(String fileUpload, String targetPath) {\n\t\tFileSystem fileSystem = Mesh.vertx().fileSystem();\n\t\tfileSystem.moveBlocking(fileUpload, targetPath);\n\t\tif (log.isDebugEnabled()) {\n\t\t\tlog.debug(\"Moved upload file from {\" + fileUpload + \"} to {\" + targetPath + \"}\");\n\t\t}\n\t\t// log.error(\"Failed to move upload file from {\" + fileUpload.uploadedFileName() + \"} to {\" + targetPath + \"}\", error);\n\t}",
"@PostMapping(\"/\")\n public ResponseEntity<?> updloadFile (MultipartFile file) throws IOException {\n \n System.out.println(\"file\"+file.getOriginalFilename());\n List<Producto> productos = productoService.readFile(\"C:\\\\Users\\\\Karen Web\\\\Downloads\\\\\"+file.getOriginalFilename());\n //System.out.println(\"producto\"+ productos.toString());\n productoService.guardarFile(productos);\n return ResponseEntity.ok(new SuccessMessage(\"001\", \"producto\"));\n \n }",
"public String uploadPhoto(String path) {\n return uploadPhoto(path, null);\n }",
"public File getFile();",
"public File getFile();",
"public String putFileFromString(String path, String content){\n Path targetPath = Paths.get( path );\n final StreamDataBodyPart filePart;\n try {\n filePart = new StreamDataBodyPart(\n targetPath.getFileName().toString(), \n new ByteArrayInputStream( content.getBytes( \"UTF-8\" ) ) );\n filePart.setName( \"file\" );\n } catch(UnsupportedEncodingException ex) {\n throw new RuntimeException( \"Bad input for string content\", ex );\n }\n\n final FormDataMultiPart multipart = (FormDataMultiPart) new FormDataMultiPart()\n .bodyPart( filePart );\n\n return target.path( targetPath.getParent().toString() ).request().\n post( Entity.entity( multipart, multipart.getMediaType() ), String.class );\n }",
"public Long createFileUpload(FileUpload fileUpload, InputStream fileInputStream) throws AppException;",
"@RequestMapping(\"/fileUpload2\")\n public ModelAndView fileUpload2(@RequestParam(\"file\") CommonsMultipartFile file, HttpServletRequest request) throws IOException {\n\n String realPath = \"/Users/leipu/IdeaProjects/ssm_test/src/main/webapp/fileUpload/\";\n // System.out.println(\"contextPath\"+request.getSession().getServletContext().getRealPath(\"/fileUpload\")+\"111111\");\n\n // System.out.println(\"ServletPath\"+request.getServletPath()+\"2222222\");\n\n // System.out.println(request.getCharacterEncoding()+\"33333\");\n\n String oldName = file.getOriginalFilename();\n\n // System.out.println(\"oldname\"+oldName);\n String newName = UUID.randomUUID().toString() + oldName.substring(oldName.lastIndexOf(\".\"));\n//\n//\n File dest = new File(realPath+File.separator+newName );\n//\n file.transferTo(dest);\n\n\n mv.setViewName(\"index\");\n\n mv.addObject(\"upload\",\"上传\");\n\n return mv;\n }",
"public boolean sendFile(String inKey, File inFile) throws NuxeoException;",
"private void uploadFile(Uri fileUri, String firstName, String lastName, String phoneNumber, String email, boolean subscribed) {\n FileUploadInterface service = retrofit.create(FileUploadInterface.class);\n Uri filePath = getFilePathByUri(fileUri);\n File file = new File(filePath.getPath());\n // use the FileUtils to get the actual file by uri\n// File file = FileUtils.getFile(this, fileUri);\n\n // create RequestBody instance from file\n RequestBody requestFile =\n RequestBody.create(MediaType.parse(\"multipart/form-data\"), file);\n\n // MultipartBody.Part is used to send also the actual file name\n MultipartBody.Part body =\n MultipartBody.Part.createFormData(\"picture\", file.getName(), requestFile);\n\n // add another part within the multipart request\n String descriptionString = \"hello, this is description speaking\";\n RequestBody description =\n RequestBody.create(\n MediaType.parse(\"multipart/form-data\"), descriptionString);\n\n // finally, execute the request\n Call<ResponseBody> call = service.upload(description, firstName, lastName, phoneNumber, email, body, subscribed);\n call.enqueue(new Callback<ResponseBody>() {\n @Override\n public void onResponse(Call<ResponseBody> call,\n Response<ResponseBody> response) {\n Log.v(\"Upload\", \"success\");\n }\n\n @Override\n public void onFailure(Call<ResponseBody> call, Throwable t) {\n Log.e(\"Upload error:\", t.getMessage());\n }\n });\n }",
"private void uploadToServer(String filePath, String title) {\n APIClient apiClient = new APIClient();\n Retrofit retrofit = apiClient.getApiClient();\n ApiInterface apiInterface = retrofit.create(ApiInterface.class);\n File file = new File(filePath);\n\n MultipartBody.Part filePart =\n MultipartBody.Part.createFormData(\"file\", title+\".jpg\", //file.getName(),\n RequestBody.create(MediaType.parse(\"image/*\"), file));\n\n\n Call call = apiInterface.uploadImage(filePart);\n call.enqueue(new Callback() {\n @Override\n public void onResponse(Call call, Response response) {\n Toast.makeText(AddPost.this, \"Worked\",Toast.LENGTH_SHORT).show();\n }\n @Override\n public void onFailure(Call call, Throwable t) {\n t.printStackTrace();\n Toast.makeText(AddPost.this, \"Didn't work\",Toast.LENGTH_SHORT).show();\n }\n });\n }",
"public String uploadFile(MultipartFile multipartFile) throws Exception {\n String fileUrl = \"\";\n try {\n File file = convertMultiPartToFile(multipartFile);\n String fileName = generateFileName(multipartFile);\n fileUrl = endpointUrl + \"/\" + bucketName + \"/\" + fileName;\n uploadFileTos3bucket(fileName, file);\n file.delete();\n } catch (FileNotFoundException e) {\n throw new FileNotFoundException(e.getMessage());\n } catch (IOException e) {\n throw new IOException(e.getMessage());\n } catch (Exception e) {\n throw new Exception(e.getMessage());\n }\n return fileUrl;\n }",
"public FileUploadHelper() throws IOException {\n //For using dynamic path\n }",
"public Blob getResource(String relativePath) throws DocumentNotFoundException;",
"public interface Uploader {\n\n public String upload(String filePath, String fileName);\n}",
"public String upload() throws FileNotFoundException, IOException{\n FileOutputStream fout=new FileOutputStream(\"/tmp/mi_archivo\");\n int read=0;\n byte[] data=new byte[1024];\n InputStream in = archivo.getInputStream();\n\n while((read = in.read(data)) != -1){\n fout.write(data, 0, read);\n }\n\n return \"\";\n }",
"protected abstract InputStream getFile(final String path);",
"@Override\n\t\t\tprotected URI toUriImpl(String path) throws URISyntaxException {\n\t\t\t\treturn toFileToURI(path);\n\t\t\t}",
"public String upload(String path, String filename, InputStream file, String contentType)\r\n\t{\r\n\t\treturn upload(bucket, path, filename, file, contentType);\r\n\t}"
] | [
"0.70733416",
"0.67159545",
"0.63592905",
"0.6212364",
"0.61804473",
"0.6147958",
"0.6100743",
"0.6082801",
"0.6011308",
"0.6006606",
"0.6005029",
"0.592043",
"0.5907249",
"0.58848625",
"0.58768326",
"0.58525604",
"0.58449274",
"0.57904357",
"0.5786716",
"0.5773804",
"0.57378185",
"0.5721554",
"0.5710975",
"0.5686186",
"0.56647086",
"0.5625356",
"0.56208265",
"0.5603033",
"0.56008613",
"0.55942684",
"0.5589973",
"0.55373436",
"0.55360895",
"0.55168253",
"0.55164015",
"0.5498607",
"0.54961586",
"0.5495062",
"0.548154",
"0.54667073",
"0.54662734",
"0.54306775",
"0.54306775",
"0.54306775",
"0.5425569",
"0.54209393",
"0.54131126",
"0.5412962",
"0.54107904",
"0.54107904",
"0.54107904",
"0.5407349",
"0.5392996",
"0.5386669",
"0.5386272",
"0.53852195",
"0.5359827",
"0.53525895",
"0.53510445",
"0.5346015",
"0.5337997",
"0.53246576",
"0.5312488",
"0.52919203",
"0.52807236",
"0.52798694",
"0.5278867",
"0.5278817",
"0.5273587",
"0.525108",
"0.5246524",
"0.52463937",
"0.52393323",
"0.5236231",
"0.5222481",
"0.5218415",
"0.5214908",
"0.52017516",
"0.5199761",
"0.5193348",
"0.51915765",
"0.5190106",
"0.5190082",
"0.51694036",
"0.51693326",
"0.51693326",
"0.516481",
"0.5160431",
"0.5157598",
"0.5156842",
"0.51562434",
"0.5148798",
"0.5148726",
"0.5147701",
"0.5140098",
"0.51389486",
"0.51356906",
"0.5126884",
"0.51240367",
"0.51226264"
] | 0.802889 | 0 |
archive name file name in vault | String description(); | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void setArchiveName(String name) {\n customName = name;\n }",
"String vaultName();",
"public String getArchiver();",
"public void setArchiver(String sArchiver);",
"public final String getArchiveName()\n {\n return _archiveName;\n }",
"Csar getArchive(String archiveName, String archiveVersion);",
"public String getName() {\n return \"File Archive Provider\";\n }",
"String getArchiveMechanism();",
"public String getVaultName() {\n return vaultName;\n }",
"private void grabarArchivo() {\n\t\tPrintWriter salida;\n\t\ttry {\n\t\t\tsalida = new PrintWriter(new FileWriter(super.salida));\n\t\t\tsalida.println(this.aDevolver);\n\t\t\tsalida.close();\n\t\t} catch (IOException e) {\n\t\t\te.printStackTrace();\n\t\t}\n\t}",
"@Internal(\"Represented as part of archivePath\")\n public String getArchiveName() {\n if (customName != null) {\n return customName;\n }\n String name = GUtil.elvis(getBaseName(), \"\") + maybe(getBaseName(), getAppendix());\n name += maybe(name, getVersion());\n name += maybe(name, getClassifier());\n name += GUtil.isTrue(getExtension()) ? \".\" + getExtension() : \"\";\n return name;\n }",
"public static void PackageArchive(File directoryName, File fileName) throws IOException\r\n {\r\n final String ARCHIVE_XML = \"<?xml version=\\\"1.0\\\" encoding=\\\"utf-16\\\"?>\\n<archive major_version=\\\"0\\\" minor_version=\\\"1\\\" />\";\r\n\r\n TarArchiveWriter archive = new TarArchiveWriter(new GZIPOutputStream(new FileOutputStream(fileName)));\r\n\r\n // Create the archive.xml file\r\n archive.writeFile(\"archive.xml\", ARCHIVE_XML);\r\n\r\n // Add the assets\r\n File dir = new File(directoryName, ArchiveConstants.ASSETS_PATH);\r\n String[] files = dir.list();\r\n for (String file : files)\r\n archive.writeFile(ArchiveConstants.ASSETS_PATH + FilenameUtils.getName(file), FileUtils.readFileToByteArray(new File(dir, file)));\r\n\r\n // Add the objects\r\n dir = new File(directoryName, ArchiveConstants.OBJECTS_PATH);\r\n files = dir.list();\r\n for (String file : files)\r\n archive.writeFile(ArchiveConstants.OBJECTS_PATH + FilenameUtils.getName(file), FileUtils.readFileToByteArray(new File(dir, file)));\r\n\r\n // Add the terrain(s)\r\n dir = new File(directoryName, ArchiveConstants.TERRAINS_PATH);\r\n files = dir.list();\r\n for (String file : files)\r\n archive.writeFile(ArchiveConstants.TERRAINS_PATH + FilenameUtils.getName(file), FileUtils.readFileToByteArray(new File(dir, file)));\r\n\r\n // Add the parcels(s)\r\n dir = new File(directoryName, ArchiveConstants.LANDDATA_PATH);\r\n files = dir.list();\r\n for (String file : files)\r\n archive.writeFile(ArchiveConstants.LANDDATA_PATH + FilenameUtils.getName(file), FileUtils.readFileToByteArray(new File(dir, file)));\r\n\r\n // Add the setting(s)\r\n dir = new File(directoryName, ArchiveConstants.SETTINGS_PATH);\r\n files = dir.list();\r\n for (String file : files)\r\n archive.writeFile(ArchiveConstants.SETTINGS_PATH + FilenameUtils.getName(file), FileUtils.readFileToByteArray(new File(dir, file)));\r\n\r\n archive.close();\r\n }",
"protected void setName(String name) {\n writeline(\"/home/ubuntu/results/coverage/ZipArchiveEntry/ZipArchiveEntry_5_10.coverage\", \"a7eb4750-e93f-41a2-ab4f-3fcf8cb1f39b\");\n if (name != null && getPlatform() == PLATFORM_FAT && !name.contains(\"/\")) {\n writeline(\"/home/ubuntu/results/coverage/ZipArchiveEntry/ZipArchiveEntry_5_10.coverage\", \"6d8baf11-928b-4d13-a982-c28e6d5c3bb7\");\n name = name.replace('\\\\', '/');\n }\n writeline(\"/home/ubuntu/results/coverage/ZipArchiveEntry/ZipArchiveEntry_5_10.coverage\", \"e80bbe2d-caf4-4e25-b64c-8fef2f2969dd\");\n this.name = name;\n }",
"private String getArchiveFilename(Publication publication) {\n\t\treturn publication.getName() + \"_\" +\n\t\t\t\tpublication.getType().getDisplayId().charAt( 0 ) +\n\t\t\t\t\"0_Publication.zip\";\n\t}",
"TarEntry CreateEntryFromFile(String fileName);",
"private String getBackupFileName(String directory, IdmScriptDto script) {\n\t\treturn directory + script.getCode() + \"_\" + SpinalCase.format(securityService.getCurrentUsername()) + \"_\"\n\t\t\t\t+ System.currentTimeMillis() + EXPORT_FILE_SUFIX;\n\t}",
"@Override\r\n public void setArchive(String archive) {\n }",
"public void setArchiveName(String archiveName) {\r\n\t\tthis.archiveName = archiveName;\r\n\t}",
"@attribute(value = \"\", required = false)\t\r\n\tpublic void setArchive(String archive) {\r\n\t\tthis.archive = archive;\r\n\t}",
"public String StoreFile(MultipartFile file) {\n \t \t\n // Normalize file name\n String fileName = StringUtils.cleanPath(file.getOriginalFilename());\n \n // Get any exiting versions of the file\n String[] fileNames = GetAllFileNames(fileName);\n int iNextIndex = fileNames.length + 1;\n \n // Increment the version of the file. All files start with 1.\n String fileNameIndexed = Integer.toString(iNextIndex) + \"_\" + fileName;\n \n try \n {\n // Check if the file's name contains invalid characters. ('_' if not valid because it's used to track version.)\n if(fileName.contains(\"..\") || fileName.contains(\"_\")) {\n throw new FileStorageException(\"Sorry! Filename contains invalid path sequence \" + fileName);\n }\n\n // Copy file to the target location (Replacing existing file with the same name)\n Path targetLocation = this.fileStorageLocation.resolve(fileNameIndexed);\n Files.copy(file.getInputStream(), targetLocation, StandardCopyOption.REPLACE_EXISTING);\n\n return fileName;\n } \n catch (IOException ex) \n {\n throw new FileStorageException(\"Could not store file \" + fileName + \". Please try again!\", ex);\n }\n }",
"public TarArchiveEntry(String name) {\n this(name, false);\n }",
"abstract Archive<T> load(\n final LogUsableType log,\n final PathReal name,\n final PathVirtual mount)\n throws FilesystemError;",
"private String getNomeArquivoCompactado(File ordem)\n\t{\n\t\tString\t\t\tnomeArquivo\t= null;\n\t\tPattern \t\tpattern \t= null;\n\t\tPatternMatcher \tmatcher \t= new AwkMatcher();\n\t\tPatternCompiler compiler \t= new AwkCompiler();\n\t\tSubstitution \tsub\t\t\t= new StringSubstitution(\".zip\");\n\t\ttry\n\t\t{\n\t\t\tpattern = compiler.compile(\"[.]dat\");\n\t\t\tnomeArquivo = Util.substitute(matcher,pattern,sub,ordem.getAbsolutePath());\n\t\t}\n\t\tcatch(Exception e)\n\t\t{\n\t\t\t/* Caso algum erro ocorra na troca da extensao do arquivo, entao\n\t\t\t * o arquivo fica com o nome original acrescido da extensao .zip\n\t\t\t */\n\t\t\tSystem.out.println(\"Erro ao criar o nome do arquivo compactado. \"+e);\n\t\t\tnomeArquivo = ordem.getAbsolutePath()+\".zip\";\n\t\t}\n\t\t//String nomeArquivo = ordem.getAbsolutePath().replaceAll(\"[.]dat\",\".zip\");\n\t\treturn nomeArquivo;\n\t}",
"private String generateZipEntry(String file) {\n return file.substring(srcFolder.length() + 1, file.length());\n }",
"public Archive getArchive();",
"public String getVault() {\n return vault;\n }",
"public void backup(String filename) throws IOException, RemoteException, Error;",
"public void setVaultName(String vaultName) {\n this.vaultName = vaultName;\n }",
"public TarArchiveEntry setName(String name) {\n this.name = ArchiveUtils.normalizeFileName(name, false);\n this.isDir = name.endsWith(\"/\");\n this.mode = isDir ? DEFAULT_DIR_MODE : DEFAULT_FILE_MODE;\n this.linkFlag = isDir ? LF_DIR : LF_NORMAL;\n return this;\n }",
"private static void createZipArchiv(String xmlStream, String path, String name) {\r\n\t\ttry {\r\n\t\t\tFile file = new File(path, name + \".xml\");\r\n\t\t\tif (!file.exists()) {\r\n\t\t\t\tfile.createNewFile();\r\n\t\t\t}\r\n\t\t\t//XMLStream in Datei schreiben\r\n\t\t\tPrintWriter writer = new PrintWriter(file);\r\n\t\t\twriter.write(xmlStream);\r\n\t\t\twriter.close();\r\n\t\t\t\r\n\t\t\t//Commando für die Shell um ein Tgz zu erstellen.\r\n\t\t\tString[] str = new String[] {\r\n\t\t\t\t\t\"/bin/bash\",\r\n\t\t\t\t\t\"-c\",\r\n\t\t\t\t\t\"tar cfvz \" + path + \"/\" + name + \".tgz -C \" + path + \" \" + name\r\n\t\t\t\t\t\t\t+ \".xml -C \" + path + \" \" + name + \".pdf\" };\r\n\r\n\t\t\t//Shell Aufruf\r\n\t\t\tProcess p = Runtime.getRuntime().exec(str);\r\n\t\t\t\r\n\t\t\t\r\n\t\t\tint timeout = 10;\r\n\t\t\twhile (!new File(path + name + \".tgz\").exists() && timeout != 0) {\r\n\t\t\t\t//warten bis Datei erstellt wurde oder 10 sec vergangen sind\r\n\t\t\t\ttry {\r\n\t\t\t\t\ttimeout--;\r\n\t\t\t\t\tThread.sleep(1000);\r\n\t\t\t\t} catch (InterruptedException e) {\r\n\t\t\t\t\t// TODO Auto-generated catch block\r\n\t\t\t\t\te.printStackTrace();\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t} catch (IOException e) {\r\n\t\t\t// TODO Auto-generated catch block\r\n\t\t\te.printStackTrace();\r\n\t\t}\r\n\t}",
"TarEntry CreateEntry(String name);",
"public ZipArchiveEntry(final String name) {\n super(name);\n setName(name);\n }",
"public byte[] getRawName() {\n writeline(\"/home/ubuntu/results/coverage/ZipArchiveEntry/ZipArchiveEntry_5_10.coverage\", \"80c1d0d6-ecf6-46ce-8974-d51c0eec65f5\");\n if (rawName != null) {\n writeline(\"/home/ubuntu/results/coverage/ZipArchiveEntry/ZipArchiveEntry_5_10.coverage\", \"1419ab4b-022a-4d7f-bb47-0e698baa585d\");\n final byte[] b = new byte[rawName.length];\n writeline(\"/home/ubuntu/results/coverage/ZipArchiveEntry/ZipArchiveEntry_5_10.coverage\", \"081dbe56-1e24-4924-a9ff-87041e808c2e\");\n System.arraycopy(rawName, 0, b, 0, rawName.length);\n writeline(\"/home/ubuntu/results/coverage/ZipArchiveEntry/ZipArchiveEntry_5_10.coverage\", \"06a15faf-53f9-4981-9869-338771474e21\");\n return b;\n }\n writeline(\"/home/ubuntu/results/coverage/ZipArchiveEntry/ZipArchiveEntry_5_10.coverage\", \"6b8d5462-042b-4f13-9788-9947eca21cba\");\n return null;\n }",
"public Resource cargarArchivo(String nombreArchivo) throws MalformedURLException;",
"private void saveToVault() {\n List<Integer> selectedItemPositions = mAdapter.getSelectedItems();\n for (Integer position : selectedItemPositions) {\n LockedVideoFiles lockedImageFiles = mAdapter.getItem(position);\n String actualPath = lockedImageFiles.getActualPath();\n MyLogger.debug(\"Loaded Picture \" + actualPath);\n try {\n Dao<LockedImageFiles, Long> lockedImageDao = db.getLockedImageFilesDao();\n LockedVideoFiles lockedVideoFile = new LockedVideoFiles();\n File file = new File(actualPath);\n if (file.exists()) {\n lockedVideoFile.setName(file.getName());\n String outputFilePath = Statics.vaultFolder + file.getName();\n FileHelper.moveFile(actualPath, outputFilePath);\n MyLogger.debugPath(\"picked input path \", actualPath);\n MyLogger.debugPath(\"picked output path \", outputFilePath);\n //ImagesVaultHelper.generateIcon(outputFilePath, 140, 120);\n lockedVideoFile.setActualPath(actualPath);\n lockedVideoFile.setPath(outputFilePath);\n lockedVideoFile.setIconPath(ImagesVaultHelper.getVideoIconPath(outputFilePath));\n lockedVideoFile.setIsLocked(true);\n db.createLockedVideoFile(lockedVideoFile);\n EventBus.getDefault().post(new OnHasVaultOperationsEvent(true));\n getActivity().getSupportFragmentManager().popBackStackImmediate();\n\n } else {\n MyLogger.debug(\"Picked image path invalid.\");\n MyLogger.show(getContext(), \"open failed\");\n }\n } catch (SQLException e) {\n e.printStackTrace();\n MyLogger.debug(\"cryption failed \" + e.getMessage());\n\n }\n\n }\n EventBus.getDefault().post(new OnBackPressed());\n }",
"protected void setName(final String name, final byte[] rawName) {\n writeline(\"/home/ubuntu/results/coverage/ZipArchiveEntry/ZipArchiveEntry_5_10.coverage\", \"e9c9991c-deb4-4a9e-9541-fb55f1b77235\");\n setName(name);\n writeline(\"/home/ubuntu/results/coverage/ZipArchiveEntry/ZipArchiveEntry_5_10.coverage\", \"edb6edae-5e7e-4c40-80af-001747a0cacb\");\n this.rawName = rawName;\n }",
"private String buildDeployFileName(final String originalFileName) {\n String tempDir = System.getProperty(\"java.io.tmpdir\");\n StringBuilder builder = new StringBuilder();\n builder.append(tempDir);\n builder.append(\"/\");\n builder.append(originalFileName);\n return builder.toString();\n }",
"private void compress()\n\t{\n\t\ttry\n\t\t{\n\t\t\tZipOutputStream rfoFile = new ZipOutputStream(new FileOutputStream(path + fileName)); \n\t\t\tFile dirToZip = new File(rfoDir); \n\t\t\tString[] fileList = dirToZip.list(); \n\t\t\tbyte[] buffer = new byte[4096]; \n\t\t\tint bytesIn = 0; \n\n\t\t\tfor(int i=0; i<fileList.length; i++) \n\t\t\t{ \n\t\t\t\tFile f = new File(dirToZip, fileList[i]); \n\t\t\t\tFileInputStream fis = new FileInputStream(f); \n\t\t\t\tString zEntry = f.getPath();\n\t\t\t\t//System.out.println(\"\\n\" + zEntry);\n\t\t\t\tint start = zEntry.indexOf(uniqueName);\n\t\t\t\tzEntry = zEntry.substring(start + uniqueName.length() + 1, zEntry.length());\n\t\t\t\t//System.out.println(tempDir);\n\t\t\t\t//System.out.println(zEntry + \"\\n\");\n\t\t\t\tZipEntry entry = new ZipEntry(zEntry); \n\t\t\t\trfoFile.putNextEntry(entry); \n\t\t\t\twhile((bytesIn = fis.read(buffer)) != -1) \n\t\t\t\t\trfoFile.write(buffer, 0, bytesIn); \n\t\t\t\tfis.close();\n\t\t\t}\n\t\t\trfoFile.close();\n\t\t} catch (Exception e)\n\t\t{\n\t\t\tDebug.e(\"RFO.compress(): \" + e);\n\t\t}\n\t}",
"public TarArchiveEntry() {\n this.version = VERSION_POSIX;\n this.name = \"\";\n this.linkName = \"\";\n this.linkFlag = LF_GNUTYPE_LONGNAME;\n String user = System.getProperty(\"user.name\", \"\");\n if (user.length() > MAX_NAMELEN) {\n user = user.substring(0, MAX_NAMELEN);\n }\n this.userName = user;\n this.groupName = \"\";\n this.userId = 0;\n this.groupId = 0;\n this.mode = DEFAULT_FILE_MODE;\n }",
"@Override\n public String toString() {\n return \"ZipFile '\" + getName() + \"'\";\n }",
"public TarArchive( File folder )\n {\n this.folder = folder;\n }",
"public static void salvarFichero(ArrayList<Libro> catalogo) {\n\t\tScanner teclado = new Scanner(System.in);\n\t\tString nombre_archivo;\n\n\t\tSystem.out.println(\"Indique el nombre del fichero en el que va a guardar su biblioteca: \");\n\t\tnombre_archivo = teclado.next();\n\n\t\ttry {\n\t\t\tFile biblioteca = new File(nombre_archivo);\n\t\t\tif (biblioteca.createNewFile()) {\n\t\t\t\tSystem.out.println(\"Archivo creado: \" + biblioteca.getName());\n\t\t\t\tSystem.out.println(biblioteca.getAbsoluteFile());\n\t\t\t\tescribirArchivo(catalogo, biblioteca);\n\n\t\t\t} else {\n\t\t\t\tSystem.out.println(\"El archivo ya existe.\");\n\t\t\t}\n\n\t\t} catch (IOException e) {\n\t\t\tSystem.out.println(\"Ha ocurrido un error.\");\n\t\t\te.printStackTrace();\n\t\t}\n\n\t}",
"private void writeArchive(Content content) throws Exception {\n\t\tString path = open();\n\t\tTranslateContent translate = new TranslateContent(content, path);\n\t\ttranslate.writeArchive();\n\n\t\t// compress archive file if +C used\n\t\tif (content.isCompressed()) {\n\t\t\tcompressArchive();\n\t\t}\n\t}",
"public void downloadFile(final String name){\n new AsyncTask<Void, Void, Void>() {\n\n @Override\n protected Void doInBackground(Void... params) {\n try\n {\n storageAccount = CloudStorageAccount.parse(Constants.storageConnectionString);\n blobClient = storageAccount.createCloudBlobClient();\n container = blobClient.getContainerReference(\"assets\");\n container.createIfNotExists();\n // Loop through each blob item in the container.\n for (ListBlobItem blobItem : container.listBlobs()) {\n // If the item is a blob, not a virtual directory.\n if (blobItem instanceof CloudBlob) {\n // Download the item and save it to a file with the same name.\n CloudBlob blob = (CloudBlob) blobItem;\n if(blob.getName().equals(name)){\n File output=File.createTempFile(\"download\",null,mContext.getCacheDir());\n String filename=output.getAbsolutePath();\n blob.download(new FileOutputStream(output));\n output.deleteOnExit(); // delete file when program ends\n Log.i(\"download NAME: \",filename);\n }\n }\n }\n\n\n }\n catch (Exception e)\n {\n Log.i(\"download file error: \",e.getMessage());\n }\n return null;\n }\n }.execute();\n }",
"public String getZrtpSecretsFile();",
"public GestorArchivos(String numeroArchivo)\r\n {\r\n this.rutaArchivoEntrada = new File(\"archivostexto/in/in\" + numeroArchivo + \".txt\").getAbsolutePath().replace(\"\\\\\", \"/\");\r\n this.rutaArchivoSalida = new File(\"archivostexto/out/out\" + numeroArchivo + \".txt\").getAbsolutePath().replace(\"\\\\\", \"/\");\r\n }",
"public TarArchiveEntry(String name, boolean preserveLeadingSlashes) {\n this();\n name = ArchiveUtils.normalizeFileName(name, preserveLeadingSlashes);\n this.name = name;\n boolean isDir = name.endsWith(\"/\");\n this.mode = isDir ? DEFAULT_DIR_MODE : DEFAULT_FILE_MODE;\n this.linkFlag = isDir ? LF_DIR : LF_NORMAL;\n this.devMajor = 0;\n this.devMinor = 0;\n this.userId = 0;\n this.groupId = 0;\n this.size = 0;\n this.modTime = (new Date()).getTime() / MILLIS_PER_SECOND;\n this.linkName = \"\";\n this.userName = \"\";\n this.groupName = \"\";\n }",
"public String ApkZipAlign(String apkname) {\n\t\tString outname = null;\r\n Runtime rn=Runtime.getRuntime();\r\n try{\r\n \toutname = apkname.substring(0, apkname.lastIndexOf(\".\"))+\"Align.apk\";\r\n \tSystem.out.println(\"ZipAlign \"+outname); \r\n \tFile zipalignf = new File(outname);\r\n \tif(zipalignf.exists())\r\n \t\tzipalignf.delete();\r\n \t\r\n \tProcess process = rn.exec(JarPath+\"zipalign -v 4 \"+apkname+\" \"+outname); \t \t\r\n \tWatchThread wt = new WatchThread(process); \r\n \twt.start(); \r\n \tprocess.waitFor();\r\n \twt.setOver(true); \r\n \twt.join();\r\n \t\r\n \tif(!new File(outname).exists())\r\n \t{\r\n \toutputstr(\"Error: ZipAlign \"+apkname);\r\n \treturn null; \r\n \t}\r\n \telse\r\n \t{\r\n \t\tnew File(apkname).delete();\r\n \t}\r\n }catch(Exception e){\r\n \toutputstr(\"Error: ZipAlign \"+apkname);\r\n \treturn null; \r\n } \t\t\r\n\t\treturn outname;\r\n\t}",
"public void salvaPartita(String file) {\n\r\n }",
"public void onBackupPressed(View view) {\n // Set current time as a string to a variable\n Date date = new Date();\n DateFormat dateFormat = new SimpleDateFormat(\"yyyymmdd_HHmmss\", Locale.US);\n String currentTime = dateFormat.format(date);\n\n Intent intent = new Intent(Intent.ACTION_CREATE_DOCUMENT);\n intent.addCategory(Intent.CATEGORY_OPENABLE);\n intent.setType(\"text/plain\");\n intent.putExtra(Intent.EXTRA_TITLE, \"ShareLocationBackup_\" + currentTime + \".txt\"); //rename file to date\n startActivityForResult(intent, CREATE_REQUEST_CODE);\n }",
"public void loadZipFile(final String name) {\r\n\t\tfileCombo.setEnabled(false);\r\n\t\tfileText.setText(\"\");\r\n\t\tnew SwingWorker<Void, Void>() {\r\n\t\t\tprotected Void doInBackground() throws Exception {\r\n\t\t\t\ttry {\r\n\t\t\t\t\tZipInputStream zin = new ZipInputStream(\r\n\t\t\t\t\t\t\tnew FileInputStream(zipname));\r\n\t\t\t\t\tZipEntry entry;\r\n\r\n\t\t\t\t\t// find entry with matching name in archive\r\n\t\t\t\t\twhile ((entry = zin.getNextEntry()) != null) {\r\n\t\t\t\t\t\tif (entry.getName().equals(name)) {\r\n\t\t\t\t\t\t\t// read entry into text area\r\n\t\t\t\t\t\t\tScanner in = new Scanner(zin);\r\n\t\t\t\t\t\t\twhile (in.hasNextLine()) {\r\n\t\t\t\t\t\t\t\tfileText.append(in.nextLine());\r\n\t\t\t\t\t\t\t\tfileText.append(\"\\n\");\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\tzin.closeEntry();\r\n\t\t\t\t\t}\r\n\t\t\t\t\tzin.close();\r\n\t\t\t\t} catch (IOException e) {\r\n\t\t\t\t\te.printStackTrace();\r\n\t\t\t\t}\r\n\t\t\t\treturn null;\r\n\t\t\t}\r\n\r\n\t\t\tprotected void done() {\r\n\t\t\t\tfileCombo.setEnabled(true);\r\n\t\t\t}\r\n\t\t}.execute();\r\n\t}",
"private static synchronized void saveArchivo(List<String> objects, String cabecera, String name) \n\t\t\tthrows Exception {\n\t\tFileWriter file = new FileWriter(Configuracion.pathRetencionTesaka + name +\".txt\");\n\t\tfile.write(cabecera);\n\t\tfor (String string : objects) {\n\t\t\tfile.write(string);\n\t\t}\t\n\t\tfile.flush();\n\t\tfile.close();\n\t\tFiledownload.save(InformeHechauka.PATH_FILE + name +\".txt\", null);\n\t}",
"protected void attachFile(final File source, final String name) {\n try {\n final ZipEntry ze = new ZipEntry(name);\n _zip.putNextEntry(ze);\n final byte[] buffer = new byte[4096];\n try (FileInputStream in = new FileInputStream(source)) {\n int bytes;\n while ((bytes = in.read(buffer)) > 0) {\n _zip.write(buffer, 0, bytes);\n }\n }\n _zip.closeEntry();\n } catch (final IOException e) {\n throw new OpenGammaRuntimeException(\"Couldn't write \" + name + \" to ZIP file\", e);\n }\n }",
"@Test\n public void testDirectorySnapshotArchiver()\n {\n File fileArchiveDirectory = null;\n File fileActive = null;\n File fileSnapshot = null;\n File fileTrash = null;\n\n try\n {\n fileArchiveDirectory = FileHelper.createTempDir();\n File fileFinalArchiveDirectory = new File(fileArchiveDirectory, FileHelper.toFilename(CLUSTER_NAME));\n fileFinalArchiveDirectory = new File(fileFinalArchiveDirectory, FileHelper.toFilename(SERVICE_NAME));\n\n fileActive = FileHelper.createTempDir();\n fileSnapshot = FileHelper.createTempDir();\n fileTrash = FileHelper.createTempDir();\n\n PersistenceEnvironment<ReadBuffer> env = createPersistenceEnv(fileActive, fileSnapshot, fileTrash);\n\n SnapshotArchiver archiver = new DirectorySnapshotArchiver(CLUSTER_NAME, SERVICE_NAME,\n fileFinalArchiveDirectory);\n\n testListSnapshots(archiver, fileArchiveDirectory);\n\n }\n catch (Exception e)\n {\n e.printStackTrace();\n fail(e.getMessage());\n }\n finally\n {\n deleteDir(fileArchiveDirectory);\n deleteDir(fileActive);\n deleteDir(fileSnapshot);\n deleteDir(fileTrash);\n }\n }",
"public String getArchiveDDFolderName();",
"public ControladorArchivos() {\n diccionarioEncriptado = new HashMap<>();\n llenarDiccionario();\n for (Map.Entry<String, String> entry : diccionarioEncriptado.entrySet()) {\n String key = entry.getKey();\n String value = entry.getValue();\n System.out.println(key);\n }\n }",
"VirtualFile getFile(String uuid);",
"public void archiveVersion(String token, String projectKey, String versionName, boolean archive) throws\r\n JiraManagerException {\r\n Util.logEnter(log, \"archiveVersion\", token, projectKey, versionName, archive);\r\n Util.checkString(log, \"token\", token);\r\n Util.checkString(log, \"projectKey\", projectKey);\r\n Util.checkString(log, \"versionName\", versionName);\r\n\r\n try {\r\n getJiraManagementServicePort().archiveVersion(token, projectKey, versionName, archive);\r\n Util.logExit(log, \"archiveVersion\");\r\n } catch (JiraServiceException e) {\r\n throw processError(e);\r\n }\r\n }",
"byte[] getFile(String sha) throws Exception;",
"public void abrirArchivo() {\r\n try {\r\n entrada = new Scanner(new File(\"estudiantes.txt\"));\r\n } // fin de try\r\n catch (FileNotFoundException fileNotFoundException) {\r\n System.err.println(\"Error al abrir el archivo.\");\r\n System.exit(1);\r\n } // fin de catch\r\n }",
"public void archive(MavenBuildProxy build, File file, BuildListener listener) throws IOException, InterruptedException {\n if (build.isArchivingDisabled()) {\n listener.getLogger().println(\"[JENKINS] Archiving disabled - not archiving \" + file);\n }\n else {\n FilePath target = getArtifactArchivePath(build,groupId,artifactId,version);\n FilePath origin = new FilePath(file);\n if (!target.exists()) {\n listener.getLogger().println(\"[JENKINS] Archiving \"+ file+\" to \"+target);\n origin.copyTo(target);\n } else if (!origin.digest().equals(target.digest())) {\n listener.getLogger().println(\"[JENKINS] Re-archiving \"+file);\n origin.copyTo(target);\n } else {\n LOGGER.fine(\"Not actually archiving \"+origin+\" due to digest match\");\n }\n\n /* debug probe to investigate \"missing artifact\" problem typically seen like this:\n\n ERROR: Asynchronous execution failure\n java.util.concurrent.ExecutionException: java.io.IOException: Archived artifact is missing: /files/hudson/server/jobs/glassfish-v3/modules/org.glassfish.build$maven-glassfish-extension/builds/2008-04-02_10-17-15/archive/org.glassfish.build/maven-glassfish-extension/1.0-SNAPSHOT/maven-glassfish-extension-1.0-SNAPSHOT.jar\n at hudson.remoting.Channel$1.adapt(Channel.java:423)\n at hudson.remoting.Channel$1.adapt(Channel.java:418)\n at hudson.remoting.FutureAdapter.get(FutureAdapter.java:32)\n at hudson.maven.MavenBuilder.call(MavenBuilder.java:140)\n at hudson.maven.MavenModuleSetBuild$Builder.call(MavenModuleSetBuild.java:476)\n at hudson.maven.MavenModuleSetBuild$Builder.call(MavenModuleSetBuild.java:422)\n at hudson.remoting.UserRequest.perform(UserRequest.java:69)\n at hudson.remoting.UserRequest.perform(UserRequest.java:23)\n at hudson.remoting.Request$2.run(Request.java:200)\n at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:417)\n at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:269)\n at java.util.concurrent.FutureTask.run(FutureTask.java:123)\n at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:650)\n at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:675)\n at java.lang.Thread.run(Thread.java:595)\n Caused by: java.io.IOException: Archived artifact is missing: /files/hudson/server/jobs/glassfish-v3/modules/org.glassfish.build$maven-glassfish-extension/builds/2008-04-02_10-17-15/archive/org.glassfish.build/maven-glassfish-extension/1.0-SNAPSHOT/maven-glassfish-extension-1.0-SNAPSHOT.jar\n at hudson.maven.reporters.MavenArtifact.getFile(MavenArtifact.java:147)\n at hudson.maven.reporters.MavenArtifact.toArtifact(MavenArtifact.java:126)\n at hudson.maven.reporters.MavenArtifactRecord.install(MavenArtifactRecord.java:115)\n at hudson.maven.reporters.MavenArtifactArchiver$1.call(MavenArtifactArchiver.java:81)\n at hudson.maven.reporters.MavenArtifactArchiver$1.call(MavenArtifactArchiver.java:71)\n at hudson.maven.MavenBuild$ProxyImpl.execute(MavenBuild.java:255)\n at hudson.maven.MavenBuildProxy$Filter$AsyncInvoker.call(MavenBuildProxy.java:177)\n at hudson.remoting.UserRequest.perform(UserRequest.java:69)\n at hudson.remoting.UserRequest.perform(UserRequest.java:23)\n at hudson.remoting.Request$2.run(Request.java:200)\n at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441)\n at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)\n at java.util.concurrent.FutureTask.run(FutureTask.java:138)\n at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:885)\n at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:907)\n at java.lang.Thread.run(Thread.java:619)\n */\n\n if(!target.exists())\n throw new AssertionError(\"Just copied \"+file+\" to \"+target+\" but now I can't find it\");\n }\n }",
"@Override\n public String getName() {\n writeline(\"/home/ubuntu/results/coverage/ZipArchiveEntry/ZipArchiveEntry_5_10.coverage\", \"9f48d6b7-640e-4370-9625-0cdc9bbeef0b\");\n return name == null ? super.getName() : name;\n }",
"void onUnzipCompleted(String output);",
"@AutoEscape\n\tpublic String getZip();",
"String backupENH(String request) throws RemoteException;",
"public String storeFile(MultipartFile file) {\n // Normalize file name\n String fileName = StringUtils.cleanPath(file.getOriginalFilename());\n\n try {\n // Check if the file's name contains invalid characters\n if(fileName.contains(\"..\")) {\n throw new FileStorageException(\"Sorry! Filename contains invalid path sequence \" + fileName);\n }\n\n // Copy file to the target location (Replacing existing file with the same name)\n Path targetLocation = this.fileStorageLocation.resolve(fileName);\n Files.copy(file.getInputStream(), targetLocation, StandardCopyOption.REPLACE_EXISTING);\n\n return fileName;\n } catch (IOException ex) {\n throw new FileStorageException(\"Could not store file \" + fileName + \". Please try again!\", ex);\n }\n }",
"@Override\r\n\tpublic String getArchivoZul() {\n\r\n\t\tif (archivoZul != null) {\r\n\t\t\treturn super.getArchivoZul();\r\n\t\t} else {\r\n\r\n\t\t\t// Resuelvo el nombre del Archivo que va a mostrarse para el objeto\r\n\t\t\tString objectZulFile = BASE_PATH + \"/viewNothing.zul\";\r\n\r\n\t\t\tif (objeto != null) {\r\n\t\t\t\t\r\n\t\t\t\tString className = objeto.getClass().getSimpleName();\r\n\t\t\t\tString numeroZulFile = \"\";\r\n\t\t\t\tif (numero > 0) {\r\n\t\t\t\t\t\r\n\t\t\t\t\tnumeroZulFile = numero.toString();\r\n\t\t\t\t}\r\n\r\n\t\t\t\tif (OperacionHelper.getType(getOperacion()).equals(OperationType.INCLUIR) || OperacionHelper.getType(getOperacion()).equals(OperationType.MODIFICAR)) {\r\n\r\n\t\t\t\t\tobjectZulFile = BASE_PATH + \"/edit\" + \"/edit\" + className\r\n\t\t\t\t\t\t\t+ numeroZulFile + \".zul\";\r\n\t\t\t\t\t\r\n\t\t\t\t\t\r\n\r\n\t\t\t\t} else if (OperacionHelper.getType(getOperacion()).equals(\r\n\t\t\t\t\t\tOperationType.BUSCAR)) {\r\n\r\n\t\t\t\t\tobjectZulFile = BASE_PATH + \"/views\" + \"/view\" + className\r\n\t\t\t\t\t\t\t+ numeroZulFile + \".zul\";\r\n\r\n\t\t\t\t}\r\n\r\n\t\t\t}\r\n\r\n\t\t\treturn objectZulFile;\r\n\r\n\t\t}\r\n\r\n\t}",
"String backup(String request) throws RemoteException;",
"public String metaFileName(String bsfName);",
"public boolean archive(String owner, String repo, String archive) {\n return apiClient.get(String.format(\"/repos/%s/%s/archive/%s\", owner, repo, archive)).isOk();\n }",
"private static void escribirArchivo(String nombre, String contenido, boolean agregar) {\n\n\t\tFileOutputStream archivo = null;\n\t\tBufferedOutputStream buffer = null;\n\t\tbyte entrada[] = new byte [100];\n\t\tArrayList<String> lista = new ArrayList<String>(5);\n\n\t\ttry {\n\t\t\tarchivo = new FileOutputStream(nombre, agregar);\n\t\t} catch (FileNotFoundException e1) {\n\t\t\te1.printStackTrace();\n\t\t}\n\n\t\ttry {\n\t\t\tbuffer = new BufferedOutputStream(archivo);\n\t\t\tbuffer.write(contenido.getBytes());\n\t\t\tbuffer.write(\"\\n\".getBytes());\n\t\t\tbuffer.flush();\n\t\t} catch (IOException e) {\n\t\t\te.printStackTrace();\n\t\t}\n\t}",
"public void unarchive(String baseDir) throws MojoExecutionException {\n try (FileInputStream fis = new FileInputStream(archive);\n ZipArchiveInputStream zipIn = new ZipArchiveInputStream(fis)) {\n ZipArchiveEntry zipEnry = zipIn.getNextZipEntry();\n while (zipEnry != null) {\n // Create a file for this tarEntry\n final File destPath = new File(baseDir + File.separator + zipEnry.getName());\n if (zipEnry.isDirectory()) {\n destPath.mkdirs();\n }\n else {\n destPath.createNewFile();\n try (BufferedOutputStream bout = new BufferedOutputStream(new FileOutputStream(destPath))) {\n IOUtils.copy(zipIn, bout);\n }\n }\n zipEnry = zipIn.getNextZipEntry();\n }\n }\n catch (IOException ex) {\n throw new MojoExecutionException(\"Could not extract archive: \" + archive.getAbsolutePath(), ex);\n }\n\n // delete archive after extraction\n archive.delete();\n }",
"public String getFileNamingDetails();",
"public abstract boolean restoreFromArchive(K id) throws ServiceException;",
"protected File createObjectArchive(String format, String jobId, JSONObject jobObject, String database, String collection, String query) throws IOException {\n\t\tFile archive = File.createTempFile(jobId, \".zip.tmp\");\n\t\tFileOutputStream fos = null;\n\t\tZipOutputStream zos = null;\n\n\t\t// try to add to the archive\n\t\ttry {\n\t\t\tfos = new FileOutputStream(archive);\n\t\t\tzos = new ZipOutputStream(fos);\n\t\t\tlogger.debug(String.format(\" [%s] Archive file: %s\", jobId, archive.getAbsolutePath()));\n\n\t\t\tint cursor = 0;\n\t\t\tint archived = 0;\n\n\t\t\tJSONObject initialJson = ObjectHelper.getInstance(authorizationHeader).search(query, database, collection, 0, 1);\n\t\t\tint total = initialJson.getInt(\"total\");\n\t\t\twhile(cursor < total) {\n\t\t\t\tJSONObject json = ObjectHelper.getInstance(authorizationHeader).search(query, database, collection, cursor, objectBatchSize);\n\t\t\t\tJSONArray items = json.getJSONArray(\"items\");\n\n\t\t\t\tfor (int i = 0; i < items.length(); i++) {\n\t\t\t\t\t// Get the item\n\t\t\t\t\tJSONObject item = items.getJSONObject(i);\n\t\t\t\t\t// Get the data to output\n\t\t\t\t\tString output = item.toString();\n\t\t\t\t\tif (\"xml\".equalsIgnoreCase(format))\n\t\t\t\t\toutput = XML.toString(new JSONObject(output.replaceAll(\"\\\\$\", \"\")), \"source\");\n\t\t\t\t\t// Define the filename\n\t\t\t\t\tString filename = item.getJSONObject(\"_id\").getString(\"$oid\") + \".\" + format;\n\t\t\t\t\t// Create a new entry in the zip file\n\t\t\t\t\tZipEntry ze = new ZipEntry(filename);\n\t\t\t\t\tzos.putNextEntry(ze);\n\t\t\t\t\tzos.write(output.getBytes());\n\t\t\t\t\tzos.closeEntry();\n\n\t\t\t\t\tarchived += 1;\n\t\t\t\t}\n\n\t\t\t\tlogger.debug(String.format(\" [%s] Archived items: %5d / %5d\", jobId, archived, total));\n\n\t\t\t\t// update the cursor\n\t\t\t\tcursor += objectBatchSize;\n\n\t\t\t\t// Update progress\n\t\t\t\tjobObject.put(\"progress\", PROGRESS_REQUESTINGDATA * cursor / total);\n\t\t\t\tObjectHelper.getInstance(authorizationHeader).updateObject(jobId, jobObject);\n\t\t\t}\n\n\t\t\tlogger.debug(String.format(\" [%s] ... Archiving completed: %s\", jobId, archive.getAbsolutePath()));\n\t\t} catch (Exception e) {\n\t\t\tlogger.error(e);\n\t\t} finally {\n\t\t\tif (zos != null)\n\t\t\t\tzos.close();\n\t\t\tif (fos != null)\n\t\t\t\tfos.close();\n\t\t}\n\n\t\treturn archive;\n\t}",
"public void saveArchive() throws FileNotFoundException {\n jsonWriter.open();\n Archive archive = new Archive(cameraCollection, filmCollection);\n jsonWriter.write(archive);\n jsonWriter.close();\n }",
"public static void execEnkripsiBulk(List<File> lsFileTemp, String pathZippedFile, String pathTempFileEncryptName, String pathEncryptedSecretKeyFile, SimpleDateFormat sdf, String pemContent) throws Exception{\r\n /*Step 2 : kompresi file*/\r\n// System.out.println(\"Step 2 : kompresi file\");\r\n\r\n //Generate Secret Key untuk setiap file yang dienkripsi\r\n /**\r\n * Kunci acak 16 Digit, dan setiap pengekripsian harus beda\r\n * contoh : A1b2C3D4E5F6G7h8\r\n * */\r\n String secretKey=RandomStringUtils.randomAlphanumeric(16);\r\n System.out.println(\"Generated Secret Key :\"+secretKey);\r\n\r\n File exportedFile;\r\n CompressingUtils compressingUtils = new CompressingUtils();\r\n String outputTmpFileNameZip = pathZippedFile.replace(\".\",\"\")+\"Tmp.zip\";\r\n String outputFileNameZip = pathZippedFile.replace(\".\",\"\")+sdf.format(new Date())+\".zip\";\r\n\r\n compressingUtils = new CompressingUtils();\r\n if(compressingUtils.createZipWithoutPassword(lsFileTemp, outputTmpFileNameZip)){\r\n exportedFile = new File(outputTmpFileNameZip);\r\n }else{\r\n throw new Exception(\"gagal melakukan kompresi file tanpa password\");\r\n }\r\n\r\n\r\n //delete file hasil enkripsi per file yang telah dimasukan ke dalam file kompresi untuk enkripsi tahap gabungan file\r\n for(File file : lsFileTemp){\r\n file.delete();\r\n }\r\n\r\n System.out.println(\"file kompresi berhasil dibuat \"+ outputFileNameZip);\r\n\r\n /*Step 3 : enkripsi file dengan kunci acak */\r\n System.out.println(\"Step 3 : enkripsi file dengan kunci acak\");\r\n\r\n\r\n String fileOutputEcnryptedname = outputFileNameZip;\r\n\r\n File tempFileEncryptName = new File(pathTempFileEncryptName);\r\n try {\r\n CryptoUtils.encrypt(secretKey, exportedFile, tempFileEncryptName);\r\n } catch (CryptoException e) {\r\n throw new Exception(\"Enkripsi file gagal : \" + e.getMessage());\r\n }\r\n\r\n\r\n EncryptionUtils utils = new EncryptionUtils();\r\n PublicKey publicKey = utils.getPublicKeyFromX509(pemContent);\r\n\r\n /*Step 4 : Enkripsi kunci acak dengan public key dari DJP*/\r\n System.out.println(\"Step 4 : enkripsi kunci acak dengan public key dari DJP\");\r\n\r\n String encryptedSecretKey;\r\n try{\r\n encryptedSecretKey = CryptoUtils.encrypt(secretKey, publicKey);\r\n }catch (CryptoException e) {\r\n throw new Exception(\"Enkripsi kunci gagal : \" + e.getMessage());\r\n }\r\n File encryptedSecretKeyFile = new File(pathEncryptedSecretKeyFile);\r\n try {\r\n FileOutputStream outputStream = new FileOutputStream(encryptedSecretKeyFile);\r\n outputStream.write(encryptedSecretKey.getBytes());\r\n outputStream.close();\r\n }catch (FileNotFoundException e){\r\n throw new Exception(\"kunci yang dienkripsi tidak ditemukan : \" + pathEncryptedSecretKeyFile);\r\n } catch (IOException e) {\r\n throw new Exception(\"gagal membentuk kunci enkripsi\");\r\n }\r\n\r\n /*Step 5: Compress data dan key kedalam file zip dan menjadi hasil akhir*/\r\n System.out.println(\"Step 5: Compress enkripsi file dan kunci kedalam file zip\");\r\n\r\n List<File> listFiles = new ArrayList<File>();\r\n listFiles.add(tempFileEncryptName);\r\n listFiles.add(encryptedSecretKeyFile);\r\n\r\n if(listFiles.size() != 2){\r\n for (File file : listFiles) {\r\n file.delete();\r\n }\r\n throw new Exception(\"file enkripsi dan/atau key enkripsi salah satunya tidak ada\");\r\n }\r\n\r\n compressingUtils = new CompressingUtils();\r\n if (compressingUtils.createZip(listFiles, fileOutputEcnryptedname)) {\r\n /*Step 6 : hapus file data dan key, hasil dari step 3 dan 4 */\r\n System.out.println(\"Step 6 : hapus file data dan key, hasil dari step 3 dan 4\");\r\n\r\n for (File file : listFiles) {\r\n file.delete();\r\n }\r\n /*Step 7: hapus file zip, hasil dari step 2 */\r\n System.out.println(\"Step 7: hapus file zip, hasil dari step 2\");\r\n\r\n exportedFile.delete();\r\n }\r\n\r\n System.out.println(\"Proses enkripsi selesai, nama file : \" + fileOutputEcnryptedname);\r\n }",
"private void addFileToTarGz(TarArchiveOutputStream tOut, String path, String base) throws IOException {\n File f = new File(path);\n String entryName = base + f.getName();\n TarArchiveEntry tarEntry = new TarArchiveEntry(f, entryName);\n tOut.putArchiveEntry(tarEntry);\n Platform.runLater(() -> fileLabel.setText(\"Processing \" + f.getPath()));\n\n if (f.isFile()) {\n FileInputStream fin = new FileInputStream(f);\n IOUtils.copy(fin, tOut);\n fin.close();\n tOut.closeArchiveEntry();\n } else {\n tOut.closeArchiveEntry();\n File[] children = f.listFiles();\n if (children != null) {\n for (File child : children) {\n addFileToTarGz(tOut, child.getAbsolutePath(), entryName + \"/\");\n }\n }\n }\n }",
"public BackupFSArchiveCopy() {\n super();\n }",
"public void setArchiverContact(String sArchiverContact);",
"public abstract boolean moveToArchive(K id) throws ServiceException;",
"public void guardarArchivo(String nombre, byte[] contenido) {\n\t\tFileOutputStream fos = null;\r\n\t\t// tenemos un objeto de tipo file, aqui no se crea el archivo\r\n\t\tFile carpetaPrincipal = new File(\"C:\\\\java\\\\wildfly-9.0.2.Final\\\\welcome-content\\\\documentos\\\\clientes\");\r\n\t\t// se crea la carpeta\r\n\t\tcarpetaPrincipal.mkdir();\r\n\t\tString nombreSinEspacios = \"\";\r\n\t\tFile miArchivo = new File(\"C:\\\\java\\\\wildfly-9.0.2.Final\\\\welcome-content\\\\documentos\\\\clientes\\\\\" + nombre);\r\n\t\ttry {\r\n\t\t\tmiArchivo.createNewFile();// se crea el archivo\r\n\t\t\tfos = new FileOutputStream(miArchivo);\r\n\t\t\tfos.write(contenido); // en memoria se escribe el archivo\r\n\t\t\tfos.flush();// escribir en el disco y tambien\r\n\t\t\tSystem.out.println(\"path donde se guardo \" + carpetaPrincipal.getAbsolutePath());\r\n\r\n\t\t} catch (IOException e) {\r\n\t\t\te.printStackTrace();\r\n\t\t} finally {\r\n\t\t\ttry {\r\n\t\t\t\tfos.close();// permite liberar el archivo\r\n\t\t\t} catch (IOException e1) {\r\n\t\t\t\te1.printStackTrace();\r\n\t\t\t}\r\n\r\n\t\t}\r\n\t\tString nmArchivo = \"<a href=\\\"http://localhost:8081/documentos/clientes/\" + nombre + \"\\\" target=\\\"_blank\\\">\"\r\n\t\t\t\t+ nombre + \"</a><br/>\";\r\n\t\tSystem.out.println(\"filename:\" + nmArchivo);\r\n\t}",
"public void create_registerFile(String name,String roll){\n try{\n outputStreamWriter=new OutputStreamWriter(context.openFileOutput(Constant.REGISTER_FILE,Context.MODE_PRIVATE));\n outputStreamWriter.write(name+\",\");\n outputStreamWriter.write(roll+\",\");\n outputStreamWriter.close();\n }\n catch (Exception e){\n Message.logMessages(\"ERROR: \",e.toString());\n }\n }",
"public void setZrtpSecretsFile(String file);",
"ArchiveInfoInterface getArchiveInfo();",
"public ParsingResult<Csar> upload(Path path) throws ParsingException, CSARVersionAlreadyExistsException {\n // TODO issue tolerance should depends of the version (SNAPSHOT) ?\n\n // parse the archive.\n ParsingResult<ArchiveRoot> parsingResult = parser.parse(path);\n postProcessor.postProcess(parsingResult);\n\n String archiveName = parsingResult.getResult().getArchive().getName();\n String archiveVersion = parsingResult.getResult().getArchive().getVersion();\n\n // check if the archive already exists\n Csar archive = csarService.getIfExists(archiveName, archiveVersion);\n if (archive != null) {\n if (!VersionUtil.isSnapshot(archive.getVersion())) {\n // Cannot override RELEASED CSAR .\n throw new CSARVersionAlreadyExistsException(\"CSAR: \" + archiveName + \", Version: \" + archiveVersion + \" already exists in the repository.\");\n }\n }\n\n ArchiveRoot archiveRoot = parsingResult.getResult();\n if (archiveRoot.hasToscaTopologyTemplate()) {\n AuthorizationUtil.checkHasOneRoleIn(Role.ARCHITECT, Role.ADMIN);\n }\n if (archiveRoot.hasToscaTypes()) {\n AuthorizationUtil.checkHasOneRoleIn(Role.COMPONENTS_MANAGER, Role.ADMIN);\n }\n\n ParsingResult<Csar> simpleResult = toSimpleResult(parsingResult);\n\n if (ArchiveUploadService.hasError(parsingResult, null)) {\n // save the parsing results so users can keep track of the warnings or infos from parsing.\n archiveRepositry.storeParsingResults(archiveName, archiveVersion, simpleResult);\n\n // check if any blocker error has been found during parsing process.\n if (ArchiveUploadService.hasError(parsingResult, ParsingErrorLevel.ERROR)) {\n // do not save anything if any blocker error has been found during import.\n return toSimpleResult(parsingResult);\n }\n }\n\n // save the archive (before we index and save other data so we can cleanup if anything goes wrong).\n csarService.save(parsingResult.getResult().getArchive());\n // save the archive in the repository\n archiveRepositry.storeCSAR(archiveName, archiveVersion, path);\n // manage images before archive storage in the repository\n imageLoader.importImages(path, parsingResult);\n // index the archive content in elastic-search\n archiveIndexer.indexArchive(archiveName, archiveVersion, parsingResult.getResult(), archive != null);\n \n // if a topology has been added we want to notify the user\n if (parsingResult.getResult().getTopology() != null) {\n Topology topology = parsingResult.getResult().getTopology();\n if (archiveRoot.hasToscaTypes()) {\n // the archive contains types\n // we assume those types are used in the embedded topology\n // so we add the dependency to this CSAR\n CSARDependency selfDependency = new CSARDependency(archiveRoot.getArchive().getName(), archiveRoot.getArchive().getVersion());\n topology.getDependencies().add(selfDependency);\n }\n\n String topologyTemplateName = topologyServiceCore.ensureNameUnicity(archiveName + \"-\" + archiveVersion, 0);\n simpleResult\n .getContext()\n .getParsingErrors()\n .add(new ParsingError(ParsingErrorLevel.INFO, ErrorCode.TOPOLOGY_DETECTED, \"\", null, \"A topology template has been detected\", null,\n topologyTemplateName));\n\n topologyServiceCore.createTopologyTemplate(topology, topologyTemplateName, parsingResult.getResult().getTopologyTemplateDescription());\n }\n\n return simpleResult;\n }",
"Archiver(File fileIn, File fileOut) throws IOException {\n\n InputStream fileStreamIn = new FileInputStream(fileIn);\n ArrayList<Integer> bytes = Constants.readBytesAndPushToArray(fileStreamIn);\n HashSet<Integer> uniqueBytesArray = getUniqueBytes(bytes);\n ArrayList<String> bitsArray = Constants.getBitsArray(Constants.chooseBitsSize(uniqueBytesArray.size()), bytes.size());\n HashMap<Integer, String> dictionary = createDictionary(uniqueBytesArray, bitsArray);\n ByteArrayOutputStream archivedFile = archiveFile(bytes, dictionary);\n FileOutputStream newFile = new FileOutputStream(fileOut);\n archivedFile.writeTo(newFile);\n System.out.println( \"The size of the file which was IN: \" + fileIn.length());\n System.out.println(\"The size of the file which was OUT: \" + fileOut.length());\n System.out.println(\"File archived is smaller than unarchived by \" + (100 - ((fileOut.length() * 100) / fileIn.length())) +\"%.\" );\n }",
"@Test\r\n\tpublic void testBundler1() throws ArchiveException, IOException {\r\n\t\r\n\t\t// Build the path to the output file\r\n\t\tStringBuilder sb = new StringBuilder();\r\n\t\tsb.append(ArchiveTest._tempDir);\r\n\t\tsb.append(File.separator);\r\n\t\tsb.append(this._archiveFilename1);\r\n\t\tthis._archiveFilename1 = sb.toString();\r\n\t\t\r\n\t\tArchiveFactory factory = ArchiveFactory.getFactory();\r\n\t\ttry {\r\n\t\t\t\r\n\t\t\tBundlerI bundler = factory.getInstance(ArchiveType.BZIP2);\r\n\t\t\tbundler.bundle(ArchiveTest._dirToArchive, this._archiveFilename1);\r\n\t\t\tFile archive = new File(bundler.getArchiveName());\r\n\t\t\tSystem.out.println(bundler.getArchiveName());\r\n\t\t\tassertTrue(archive.exists());\r\n\t\t\tdouble bytes = archive.length();\r\n\t\t\tSystem.out.println(bytes);\r\n\t\t\t\r\n\t\t}\r\n\t\tcatch (UnknownArchiveTypeException uae) {\r\n\t\t\t// We *should* never get this exception\r\n\t\t\tuae.printStackTrace();\r\n\t\t}\r\n\t}",
"@Override\r\n public void extractArchive(ArchiveExtractor decompressor) throws ArcException {\r\n\r\n\tString fileName = ManipString.substringAfterFirst(this.idSource, \"_\");\r\n\r\n\tboolean uncompressInProgress=false;\r\n\tFile dir = new File(this.archiveChargement + \".dir\");\r\n\tif (!dir.exists()) {\r\n\t\ttry {\r\n\t\t if (dir.mkdir())\r\n\t\t {\r\n\t\t \tStaticLoggerDispatcher.debug(LOGGER,\"$$\"+Thread.currentThread().getId()+\" is decompressing \"+dir.getAbsolutePath());\r\n\t\t \tdecompressor.extract(this.archiveChargement);\r\n\t\t \tuncompressInProgress=true;\r\n\t\t }\r\n\t\t}\r\n\t\t catch (Exception ex)\r\n\t\t{\r\n\t\t\t throw new ArcException(ex, ArcExceptionMessage.FILE_EXTRACT_FAILED, this.archiveChargement).logFullException();\r\n\t\t}\r\n\t}\r\n\t\r\n\tif (!uncompressInProgress) {\r\n\t\t\t// check if file exists\r\n\t File toRead = new File(dir + File.separator + ManipString.redoEntryName(fileName));\r\n\t while (!toRead.exists()) {\r\n\t \ttry {\r\n\t\t\t\tThread.sleep(MILLISECOND_UNCOMPRESSION_CHECK_INTERVAL);\r\n\t\t\t} catch (InterruptedException e) {\r\n\t\t\t\tThread.currentThread().interrupt();\r\n\t\t\t StaticLoggerDispatcher.error(LOGGER, \"Error in thread sleep extractArchive()\");\r\n\t\t\t}\r\n\t \ttoRead = new File(dir + File.separator + ManipString.redoEntryName(fileName));\r\n\t }\r\n\t}\r\n\r\n\r\n\t\r\n }",
"private void save(String fullname, boolean forNooJ)\n\t{\n\t\tif (!forNooJ)\n\t\t{\n\t\t\tString fname = org.apache.commons.io.FilenameUtils.getName(fullname);\n\t\t\tif (fname.charAt(0) == '_')\n\t\t\t{\n\t\t\t\tif (JOptionPane.showConfirmDialog(Launcher.getDesktopPane(),\n\t\t\t\t\t\t\"WARNING: file name starts with \\\"_\\\". Are you sure you want to save it with this prefix?\",\n\t\t\t\t\t\t\"NooJ: protected resource\", JOptionPane.YES_NO_OPTION) != 0)\n\t\t\t\t\treturn;\n\t\t\t}\n\n\t\t\t// MANAGE MULTIPLE BACKUPS\n\t\t\ttry\n\t\t\t{\n\t\t\t\tUtilities.savePreviousVersion(fullname, Launcher.preferences.multiplebackups);\n\t\t\t}\n\t\t\tcatch (IOException e)\n\t\t\t{\n\t\t\t\te.printStackTrace();\n\t\t\t\tJOptionPane.showMessageDialog(Launcher.getDesktopPane(), \"NooJ: cannot save previous version of file\",\n\t\t\t\t\t\t\"NooJ\", JOptionPane.INFORMATION_MESSAGE);\n\t\t\t}\n\t\t}\n\n\t\tBufferedWriter writer = null;\n\t\ttry\n\t\t{\n\t\t\t\n\t\t\twriter = new BufferedWriter(new OutputStreamWriter(\tnew FileOutputStream(fullname), \"UTF8\"));\n\t\t\t\n\t\t\twriter.write(textPane.getText());\n\t\t}\n\t\tcatch (IOException e)\n\t\t{\n\t\t\tJOptionPane.showMessageDialog(Launcher.getDesktopPane(), \"NooJ: cannot save dictionary\", \"NooJ\",\n\t\t\t\t\tJOptionPane.ERROR_MESSAGE);\n\t\t}\n\t\tfinally\n\t\t{\n\t\t\ttry\n\t\t\t{\n\t\t\t\tif (writer != null)\n\t\t\t\t\twriter.close();\n\t\t\t}\n\t\t\tcatch (IOException e)\n\t\t\t{\n\t\t\t}\n\t\t}\n\n\t\tif (!forNooJ)\n\t\t\tfullName = fullname;\n\t\tmodified = false;\n\t\tshell.setTitle(org.apache.commons.io.FilenameUtils.getName(fullName));\n\t\tlblnTus.setText(\"Dictionary contains \" + Integer.toString(DictionaryDialogController.count(textPane))\n\t\t\t\t+ \" entries\");\n\t}",
"protected void getFile(ZipEntry e) throws IOException {\n String zipName = e.getName();\n switch (mode) {\n case EXTRACT:\n if (zipName.startsWith(\"/\")) {\n if (!warnedMkDir)\n System.out.println(\"Ignoring absolute paths\");\n warnedMkDir = true;\n zipName = zipName.substring(1);\n }\n // if a directory, just return. We mkdir for every file,\n // since some widely-used Zip creators don't put out\n // any directory entries, or put them in the wrong place.\n if (zipName.endsWith(\"/\")) {\n return;\n }\n // Else must be a file; open the file for output\n // Get the directory part.\n int ix = zipName.lastIndexOf('/');\n if (ix > 0) {\n //String dirName = zipName.substring(0, ix);\n String fileName = zipName.substring(ix + 1, zipName.length());\n zipName = fileName;\n\n }\n String targetFile = this.unzipFileTargetLocation;\n File file = new File(targetFile);\n if (!file.exists())\n file.createNewFile();\n FileOutputStream os = null;\n InputStream is = null;\n try {\n os = new FileOutputStream(targetFile);\n is = zippy.getInputStream(e);\n int n = 0;\n while ((n = is.read(b)) > 0)\n os.write(b, 0, n);\n\n } finally {\n if (is != null) {\n try {\n is.close();\n } catch (Exception ee) {\n ee.printStackTrace();\n }\n }\n if (os != null) {\n try {\n os.close();\n } catch (Exception ee) {\n ee.printStackTrace();\n }\n }\n }\n break;\n case LIST:\n // Not extracting, just list\n if (e.isDirectory()) {\n System.out.println(\"Directory \" + zipName);\n } else {\n System.out.println(\"File \" + zipName);\n }\n break;\n default:\n throw new IllegalStateException(\"mode value (\" + mode + \") bad\");\n }\n }",
"public void unZip(String apkFile) throws Exception \r\n\t{\r\n\t\tLog.p(tag, apkFile);\r\n\t\tFile file = new File(apkFile);\r\n\t\r\n\t\t/*\r\n\t\t * Create the Base Directory, whose name should be same as Zip file name.\r\n\t\t * All decompressed contents will be placed under this folder.\r\n\t\t */\r\n\t\tString apkFileName = file.getName();\r\n\t\t\r\n\t\tif(apkFileName.indexOf('.') != -1)\r\n\t\t\tapkFileName = apkFileName.substring(0, apkFileName.indexOf('.'));\r\n\t\t\r\n\t\tLog.d(tag, \"Folder name: \"+ apkFileName);\r\n\t\t\r\n\t\tFile extractFolder = new File((file.getParent() == null ? \"\" : file.getParent() + File.separator) + apkFileName);\r\n\t\tif(!extractFolder.exists())\r\n\t\t\textractFolder.mkdir();\r\n\t\t\r\n\t\t/*\r\n\t\t * Read zip entries.\r\n\t\t */\r\n\t\tFileInputStream fin = new FileInputStream(apkFile);\r\n\t\tZipInputStream zin = new ZipInputStream(new BufferedInputStream(fin));\r\n\t\t\r\n\t\t/*\r\n\t\t * Zip InputStream shifts its index to every Zip entry when getNextEntry() is called.\r\n\t\t * If this method returns null, Zip InputStream reaches EOF.\r\n\t\t */\r\n\t\tZipEntry ze = null;\r\n\t\tBufferedOutputStream dest;\r\n\t\t\r\n\t\twhile((ze = zin.getNextEntry()) != null)\r\n\t\t{\r\n\t\t\tLog.d(tag, \"Zip entry: \" + ze.getName() + \" Size: \"+ ze.getSize());\r\n\t\t\t/*\r\n\t\t\t * Create decompressed file for each Zip entry. A Zip entry can be a file or directory.\r\n\t\t\t * ASSUMPTION: APK Zip entry uses Unix style File seperator- \"/\"\r\n\t\t\t * \r\n\t\t\t * 1. Create the prefix Zip Entry folder, if it is not yet available\r\n\t\t\t * 2. Create the individual Zip Entry file.\r\n\t\t\t */\r\n\t\t\tString zeName = ze.getName();\r\n\t\t\tString zeFolder = zeName;\r\n\t\t\t\r\n\t\t\tif(ze.isDirectory())\r\n\t\t\t{\r\n\t\t\t\tzeName = null; // Don't create Zip Entry file\r\n\t\t\t}\r\n\t\t\telse{\r\n\t\t\t\tif(zeName.indexOf(\"/\") == -1) // Zip entry uses \"/\"\r\n\t\t\t\t\tzeFolder = null; // It is File. don't create Zip entry Folder\r\n\t\t\t\telse {\r\n\t\t\t\t\tzeFolder = zeName.substring(0, zeName.lastIndexOf(\"/\"));\r\n\t\t\t\t\tzeName = zeName.substring( zeName.lastIndexOf(\"/\") + 1);\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\tLog.d(tag, \"zeFolder: \"+ zeFolder +\" zeName: \"+ zeName);\r\n\t\t\t\r\n\t\t\t// Create Zip Entry Folder\r\n\t\t\tFile zeFile = extractFolder;\r\n\t\t\tif(zeFolder != null)\r\n\t\t\t{\r\n\t\t\t\tzeFile = new File(extractFolder.getPath() + File.separator + zeFolder);\r\n\t\t\t\tif(!zeFile.exists())\r\n\t\t\t\t\tzeFile.mkdirs();\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t// Create Zip Entry File\r\n\t\t\tif(zeName == null)\r\n\t\t\t\tcontinue;\r\n\t\t\t\r\n\t\t\t// Keep track of XML files, they are in Android Binary XML format\r\n\t\t\tif(zeName.endsWith(\".xml\"))\r\n\t\t\t\txmlFiles.add(zeFile.getPath() + File.separator + zeName);\r\n\t\t\t\r\n\t\t\t// Keep track of the Dex/ODex file. Need to convert to Jar\r\n\t\t\tif(zeName.endsWith(\".dex\") || zeName.endsWith(\".odex\"))\r\n\t\t\t\tdexFile = zeFile.getPath() + File.separator + zeName;\r\n\t\t\t\r\n\t\t\t// Keep track of Resources.arsc file- resources.arsc\r\n\t\t\tif(zeName.endsWith(\".arsc\"))\r\n\t\t\t\tresFile = zeFile.getPath() + File.separator + zeName;\r\n\t\t\t\r\n\t\t\t// Write Zip entry File to the disk\r\n\t\t\tint count;\r\n\t\t\tbyte data[] = new byte[BUFFER];\r\n\t\t\t\r\n\t\t\tFileOutputStream fos = new FileOutputStream(zeFile.getPath() + File.separator + zeName);\r\n\t\t\tdest = new BufferedOutputStream(fos, BUFFER);\r\n\r\n\t\t\twhile ((count = zin.read(data, 0, BUFFER)) != -1) \r\n\t\t\t{\r\n\t\t\t\tdest.write(data, 0, count);\r\n\t\t\t}\r\n\t\t\tdest.flush();\r\n\t\t\tdest.close();\r\n\t\t}\r\n\r\n\t\t// Close Zip InputStream\r\n\t\tzin.close();\r\n\t\tfin.close();\r\n\t}",
"String getFile();",
"String getFile();",
"String getFile();",
"private void createTar() {\n File tgzFile = new File(\".\" + File.separator + Arguments.JRE_DEFAULT_NAME);\n File tgzMd5File = new File(tgzFile.getPath() + \".md5\");\n if (tgzFile.exists()) {\n tgzFile.delete();\n m_logger.debug(\"Removed the old tgz file\");\n }\n if (tgzMd5File.exists()) {\n tgzMd5File.delete();\n m_logger.debug(\"Removed the old md5 file\");\n }\n\n try {\n m_logger.debug(\"Starting zip\");\n tgzFile.createNewFile();\n TarArchiveOutputStream tgzStream = new TarArchiveOutputStream(new GZIPOutputStream(\n new BufferedOutputStream(new FileOutputStream(tgzFile))));\n addFileToTarGz(tgzStream, m_jreLocation, \"\");\n tgzStream.finish();\n tgzStream.close();\n m_logger.debug(\"Finished zip, starting md5 hash\");\n\n Platform.runLater(() -> fileLabel.setText(\"Generating md5 hash\"));\n String md5Hash = MainApp.hashFile(tgzFile);\n OutputStream md5Out = new BufferedOutputStream(new FileOutputStream(tgzMd5File));\n md5Out.write(md5Hash.getBytes());\n md5Out.flush();\n md5Out.close();\n m_logger.debug(\"Finished md5 hash, hash is \" + md5Hash);\n final boolean interrupted = Thread.interrupted();\n\n // Show the connect roboRio screen\n Platform.runLater(() -> {\n if (!interrupted) {\n m_args.setArgument(Arguments.Argument.JRE_TAR, tgzFile.getAbsolutePath());\n moveNext(Arguments.Controller.CONNECT_ROBORIO_CONTROLLER);\n }\n });\n } catch (IOException | NoSuchAlgorithmException e) {\n m_logger.error(\"Could not create the tar gz file. Do we have write permissions to the current working directory?\", e);\n showErrorScreen(e);\n }\n }",
"@Override\n\tpublic void unRarFile(String fileUploadPath) {\n\t\tbianLiCCFile(fileUploadPath);\n\t}",
"public static synchronized void initializeArchiveFiles() {\n System.out.println(Thread.currentThread().getName() + \"********************************************************* TestHelper.initializeArchiveFiles\");\n File sourceFile = new File(System.getProperty(USER_DIR) + File.separator + \"QVCSEnterpriseServer.kbwb\");\n String firstDestinationDirName = System.getProperty(USER_DIR)\n + File.separator\n + QVCSConstants.QVCS_PROJECTS_DIRECTORY\n + File.separator\n + getTestProjectName();\n File firstDestinationDirectory = new File(firstDestinationDirName);\n firstDestinationDirectory.mkdirs();\n File firstDestinationFile = new File(firstDestinationDirName + File.separator + \"QVCSEnterpriseServer.kbwb\");\n\n String secondDestinationDirName = firstDestinationDirName + File.separator + SUBPROJECT_DIR_NAME;\n File secondDestinationDirectory = new File(secondDestinationDirName);\n secondDestinationDirectory.mkdirs();\n File secondDestinationFile = new File(secondDestinationDirName + File.separator + \"QVCSEnterpriseServer.kbwb\");\n\n String thirdDestinationDirName = secondDestinationDirName + File.separator + SUBPROJECT2_DIR_NAME;\n File thirdDestinationDirectory = new File(thirdDestinationDirName);\n thirdDestinationDirectory.mkdirs();\n File thirdDestinationFile = new File(thirdDestinationDirName + File.separator + \"ThirdDirectoryFile.kbwb\");\n\n File fourthDestinationFile = new File(firstDestinationDirName + File.separator + \"Server.kbwb\");\n File fifthDestinationFile = new File(firstDestinationDirName + File.separator + \"AnotherServer.kbwb\");\n File sixthDestinationFile = new File(firstDestinationDirName + File.separator + \"ServerB.kbwb\");\n File seventhDestinationFile = new File(firstDestinationDirName + File.separator + \"ServerC.kbwb\");\n try {\n ServerUtility.copyFile(sourceFile, firstDestinationFile);\n ServerUtility.copyFile(sourceFile, secondDestinationFile);\n ServerUtility.copyFile(sourceFile, thirdDestinationFile);\n ServerUtility.copyFile(sourceFile, fourthDestinationFile);\n ServerUtility.copyFile(sourceFile, fifthDestinationFile);\n ServerUtility.copyFile(sourceFile, sixthDestinationFile);\n ServerUtility.copyFile(sourceFile, seventhDestinationFile);\n } catch (IOException ex) {\n Logger.getLogger(TestHelper.class.getName()).log(Level.SEVERE, null, ex);\n }\n }",
"boolean isArchiveSuppress();",
"String getFilename();",
"public void extract(final File file, final File targetDir)\n throws IOException {\n final InputStream in = new java.io.FileInputStream(file);\n try {\n final MODCAParser parser = new MODCAParser(in);\n final ByteArrayOutputStream baout = new ByteArrayOutputStream();\n UnparsedStructuredField strucField;\n while ((strucField = parser.readNextStructuredField()) != null) {\n if (strucField.getSfTypeID() == 0xD3EE89) {\n final byte[] sfData = strucField.getData();\n println(strucField.toString());\n HexDump.dump(sfData, 0, this.printStream, 0);\n baout.write(sfData);\n }\n }\n\n final ByteArrayInputStream bin = new ByteArrayInputStream(\n baout.toByteArray());\n final DataInputStream din = new DataInputStream(bin);\n final long len = din.readInt() & 0xFFFFFFFFL;\n println(\"Length: \" + len);\n din.skip(4); // checksum\n final int tidLen = din.readUnsignedShort() - 2;\n final byte[] tid = new byte[tidLen];\n din.readFully(tid);\n String filename = new String(tid, \"ISO-8859-1\");\n final int asciiCount1 = countUSAsciiCharacters(filename);\n final String filenameEBCDIC = new String(tid, \"Cp1146\");\n final int asciiCount2 = countUSAsciiCharacters(filenameEBCDIC);\n println(\"TID: \" + filename + \" \" + filenameEBCDIC);\n\n if (asciiCount2 > asciiCount1) {\n // Haven't found an indicator if the name is encoded in EBCDIC\n // or not\n // so we use a trick.\n filename = filenameEBCDIC;\n }\n if (!filename.toLowerCase().endsWith(\".pfb\")) {\n filename = filename + \".pfb\";\n }\n println(\"Output filename: \" + filename);\n final File out = new File(targetDir, filename);\n\n final OutputStream fout = new java.io.FileOutputStream(out);\n try {\n IOUtils.copyLarge(din, fout);\n } finally {\n IOUtils.closeQuietly(fout);\n }\n\n } finally {\n IOUtils.closeQuietly(in);\n }\n }"
] | [
"0.614697",
"0.6110927",
"0.5862894",
"0.56271684",
"0.56095177",
"0.5546101",
"0.5387454",
"0.53618985",
"0.52588785",
"0.52068293",
"0.5180036",
"0.5170935",
"0.5110526",
"0.51038736",
"0.50991136",
"0.50746685",
"0.5065291",
"0.50013715",
"0.49894",
"0.4967337",
"0.49659538",
"0.49556547",
"0.49401206",
"0.489772",
"0.48939383",
"0.48848024",
"0.4875501",
"0.48408315",
"0.4839713",
"0.48262972",
"0.48104265",
"0.48066103",
"0.4803544",
"0.47988686",
"0.4794969",
"0.47838944",
"0.4781909",
"0.47659805",
"0.47436517",
"0.47406304",
"0.4729239",
"0.47042072",
"0.46957323",
"0.4648414",
"0.46461633",
"0.46338326",
"0.4631679",
"0.46272248",
"0.46253166",
"0.46163014",
"0.46129942",
"0.46089166",
"0.4605793",
"0.4584204",
"0.45637837",
"0.45599818",
"0.45506606",
"0.45487827",
"0.4543725",
"0.45408165",
"0.453837",
"0.4537829",
"0.45359644",
"0.4533601",
"0.45208675",
"0.45186374",
"0.45152712",
"0.45145345",
"0.45116764",
"0.4510405",
"0.4509583",
"0.4508321",
"0.45052192",
"0.45033893",
"0.44977918",
"0.4483962",
"0.44798273",
"0.44767717",
"0.44762728",
"0.4475038",
"0.44745925",
"0.4470297",
"0.44664007",
"0.4459282",
"0.4455823",
"0.4442367",
"0.44364363",
"0.44337562",
"0.4430342",
"0.44285303",
"0.44210505",
"0.44162786",
"0.44108325",
"0.44108325",
"0.44108325",
"0.44100186",
"0.44096127",
"0.44085246",
"0.4408417",
"0.44083047",
"0.44060534"
] | 0.0 | -1 |
aws glacier vault name the vault must exist | String vaultName(); | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public String getVaultName() {\n return vaultName;\n }",
"public void setVaultName(String vaultName) {\n this.vaultName = vaultName;\n }",
"public String getVault() {\n return vault;\n }",
"interface WithVault {\n /**\n * Specifies resourceGroupName, vaultName.\n * @param resourceGroupName The name of the Resource Group to which the vault belongs\n * @param vaultName Name of the vault\n * @return the next definition stage\n */\n WithProperties withExistingVault(String resourceGroupName, String vaultName);\n }",
"private String getVaultToken(MagnoliaConfigurationProperties magnoliaConfigurationProperties) {\n return magnoliaConfigurationProperties.getProperty(PROPERTY_VAULT_TOKEN);\n }",
"interface Blank extends WithVault {\n }",
"public CompleteMultipartUploadRequest withVaultName(String vaultName) {\n this.vaultName = vaultName;\n return this;\n }",
"public String getVaultPassword() {\n return vaultPassword;\n }",
"public boolean onCommand(CommandSender sender, Command cmd, String label,\n \t\t\tString[] args) {\n \t\tif (cmd.getName().equalsIgnoreCase(\"vault\")) {\n \t\t\tif (!(sender instanceof Player)) {\n \t\t\t\tsender.sendMessage(\"[PlayerVaults] Sorry but the console can't have a vault :(\");\n \t\t\t\treturn true;\n \t\t\t} else {\n \t\t\t\tPlayer player = (Player) sender;\n \t\t\t\tif (args.length == 1) {\n \t\t\t\t\tif (args[0].matches(\"[1-9]\")) {\n \t\t\t\t\t\tif (player.hasPermission(\"playervaults.amount.\"\n \t\t\t\t\t\t\t\t+ args[0])) {\n \t\t\t\t\t\t\tplugin.openLargeVault(args[0], player);\n \t\t\t\t\t\t\tplayer.sendMessage(pv + \"Opening vault \"\n \t\t\t\t\t\t\t\t\t+ ChatColor.GREEN + args[0]);\n \t\t\t\t\t\t} else {\n \t\t\t\t\t\t\tplayer.sendMessage(pv\n \t\t\t\t\t\t\t\t\t+ \"You don't have permission for that many chests!\");\n \t\t\t\t\t\t}\n \t\t\t\t\t} else {\n \t\t\t\t\t\tplayer.sendMessage(pv + \"Syntax is: /vault <number>\");\n \t\t\t\t\t\treturn true;\n \t\t\t\t\t}\n \t\t\t\t} else {\n \t\t\t\t\tplayer.sendMessage(pv + \"Syntax is: /vault <number>\");\n \t\t\t\t\treturn true;\n \t\t\t\t}\n \t\t\t\tif (args.length == 2) {\n \t\t\t\t\tif (args[0].equals(\"delete\")) {\n \t\t\t\t\t\tif (player.hasPermission(\"playervault.delete\")) {\n \t\t\t\t\t\t\tif (args[1].matches(\"[1-9]\")) {\n \t\t\t\t\t\t\t\tplugin.deletePlayerVault(args[1], player);\n \t\t\t\t\t\t\t\treturn true;\n \t\t\t\t\t\t\t}\n \t\t\t\t\t\t}\n \t\t\t\t\t}\n \t\t\t\t}\n \t\t\t\tif (args.length > 1) {\n \t\t\t\t\tif (args[0].equalsIgnoreCase(\"delete\")) {\n \t\t\t\t\t\tif (player.hasPermission(\"playervaults.admin\")) {\n \t\t\t\t\t\t\tPlayer target = plugin.getServer().getPlayerExact(\n \t\t\t\t\t\t\t\t\targs[1]);\n \t\t\t\t\t\t\tif (!target.isOnline()) {\n \t\t\t\t\t\t\t\tplayer.sendMessage(pv + target.getName()\n \t\t\t\t\t\t\t\t\t\t+ \" is offline!\");\n \t\t\t\t\t\t\t\treturn false;\n \t\t\t\t\t\t\t}\n \t\t\t\t\t\t\tif (args[2].matches(\"[1-9]\")) {\n \t\t\t\t\t\t\t\tplugin.deletePlayerVault(args[2], target);\n \t\t\t\t\t\t\t\treturn true;\n \t\t\t\t\t\t\t}\n \t\t\t\t\t\t}\n \t\t\t\t\t}\n \t\t\t\t} else {\n \t\t\t\t\tplayer.sendMessage(pv\n \t\t\t\t\t\t\t+ \"Syntax error! usage: /vault delete <player> <#> <optional params>\");\n \t\t\t\t}\n \t\t\t}\n \t\t}\n \n \t\treturn false;\n \t}",
"@AfterClass(alwaysRun = true)\n public void forceVaultRemoval() {\n Vault vault = api().getVault(vaultName);\n if (vault != null) {\n if ((vault.properties().enableSoftDelete() != null) && vault.properties().enableSoftDelete()) {\n api().deleteVault(vaultName);\n checkState(deletedVaultStatus.create(resourceGroupName, true).apply(vaultName),\n \"vault was not deleted before timeout\");\n } else {\n return;\n }\n }\n\n DeletedVault deletedVault = api().getDeletedVault(LOCATION, vaultName);\n if (deletedVault != null) {\n api().purgeVault(LOCATION, vaultName);\n checkState(deletedVaultStatus.create(resourceGroupName, false).apply(vaultName),\n \"vault was not purged before timeout\");\n }\n }",
"public Vegetable createVegFromJson(final String rawVeg)\n throws NoSuchIngredientException {\n CoderFactory coderFactory = CoderFactory.getSingleInstance();\n VegetableDecoder vegDecoder = coderFactory.getVegetableDecoder();\n Optional<Vegetable> optionalVeg = vegDecoder.decodeVegetable(rawVeg);\n Vegetable vegetable = optionalVeg.orElseThrow(() ->\n new NoSuchIngredientException(getContentError()));\n return validateVeg(vegetable, rawVeg);\n }",
"public interface Vault {\n\n /**\n * Close the vault. A closed vault cannot be reopened.\n *\n * @throws VaultException if there was a problem closing the vault\n */\n void close();\n\n /**\n * Stores content in the vault. Creating the vault entry requires an external reference {@code Certificate} with\n * metadata describing the content, and the content to store.\n * <p>\n * The integrity of the data will be verified against the signature from the external reference {@code Certificate}.\n * If the integrity is not validated, writing will fail with IO exception.\n * <p>\n * A vault receipt {@code Certificate} will be returned, and should then be stored on the blockchain to strongly\n * anchor the external content. The vault receipt wraps the given external reference {@code Certificate}, and is\n * signed by a vault entity.\n * @param externalReference a non-null external reference certificate, with fields describing the given content\n * @param content the byte array with the data to store in the vault\n * @return a vault receipt certificate\n * @throws IOException if an I/O error occurs writing to or creating the vault entry\n * @throws IllegalArgumentException is the external reference certificate is invalid or does not verify the content\n * @throws VaultException is operation cannot be performed\n * @see VaultUtils\n */\n default Certificate store(Certificate externalReference, byte[] content) throws IOException {\n return store(externalReference, new ByteArrayInputStream(content));\n }\n\n\n /**\n * Stores content in the vault. Creating the vault entry requires an external reference {@code Certificate} with\n * metadata describing the content, and the content to store.\n * <p>\n * The integrity of the data will be verified against the signature from the external reference {@code Certificate}.\n * If the integrity is not validated, writing will fail with IO exception.\n * <p>\n * A vault receipt {@code Certificate} will be returned, and should then be stored on the blockchain to strongly\n * anchor the external content. The vault receipt wraps the given external reference {@code Certificate}, and is\n * signed by a vault entity.\n * @param externalReference a non-null external reference certificate, with fields describing the given content\n * @param content the input stream to read from for the data to store in the vault\n * @return a vault receipt certificate\n * @throws IOException if an I/O error occurs writing to or creating the vault entry\n * @throws IllegalArgumentException is the external reference certificate is invalid or does not verify the content\n * @throws VaultException is operation cannot be performed\n * @see VaultUtils\n */\n Certificate store(Certificate externalReference, InputStream content) throws IOException;\n\n /**\n * Get content from the vault for the given external reference {@code Certificate}. Returns an\n * {@code ExternalReference} object to allow for lazy retrieval of the content.\n * @param externalReference a non-null external reference certificate, with fields describing the given content\n * @return an external reference\n * @throws IllegalArgumentException is the given certificate is invalid\n * @throws VaultException is operation cannot be performed\n */\n ExternalReference get(Certificate externalReference);\n\n /**\n * Delete an entry from the vault if it exists.\n * @return if true deleted, false if it didn't exist\n * @param externalReference an external reference certificate describing the resource to delete\n * @throws IOException if an I/O error occurs deleting the vault entry\n * @throws VaultException is operation cannot be performed\n */\n boolean delete(Certificate externalReference) throws IOException;\n}",
"public Boolean doesExistSecret(final ArtifactVersion version);",
"java.lang.String getVpcName();",
"@Test\n public void _1passwordVaultsTest() {\n // TODO: test _1passwordVaults\n }",
"public Villager(String name) {\r\n\t\tthis.name = name;\r\n\t}",
"public Optional<String> vaultVersionOverride() {\n return Codegen.stringProp(\"vaultVersionOverride\").config(config).get();\n }",
"@Test\npublic void verifyRegionName() {\n\t\tgiven().accept(ContentType.JSON).\n\t\twhen().get(ConfigurationReader.getProperty(\"hrapp.baseurl\")+\"/regions\")\n\t\t.then().assertThat().statusCode(200)\n\t\t.and().contentType(ContentType.JSON)\n\t\t.and().assertThat().body(\"items[1].region_name\", equalTo(\"Americas\"));\n}",
"public String getBucketName(){\n return bucketName;\n }",
"public interface VaultConnection {\n\n String getId();\n\n Vault getVault();\n\n void invalidate();\n\n boolean isValid();\n\n void renewLease();\n}",
"@Override\n\tpublic String getInventoryName() {\n\t\treturn isInventoryNameLocalized() ? field_145902_i : \"container.hopper\";\n\t}",
"private GImage getSlotBox(String name) {\n\t\tif (name.equals(CHERRY)) {\n\t\t\treturn new GImage(\"cherry.png\");\n\t\t} else if (name.equals(LEMON)) {\n\t\t\treturn new GImage(\"lemon.png\");\n\t\t} else if (name.equals(ORANGE)) {\n\t\t\treturn new GImage(\"orange.png\");\n\t\t} else if (name.equals(PLUM)) {\n\t\t\treturn new GImage(\"plum.png\");\n\t\t} else if (name.equals(BELL)) {\n\t\t\treturn new GImage(\"bell.png\");\n\t\t} else if (name.equals(BAR)) {\n\t\t\treturn new GImage(\"bar.png\");\n\t\t} else {\n\t\t\treturn new GImage(\"empty.png\");\n\t\t}\n\t}",
"public VaultAddin() {\n super();\n }",
"public String getInventoryName()\n {\n return this.hasCustomName() ? this.getCustomName() : Names.Containers.WATERJET;\n }",
"CreateS3VolumeRequestBuilder setName(String name);",
"com.google.devtools.kythe.proto.Storage.VName getVName();",
"@Test\n\tpublic void testVirtualPetShelterExistsButIsNull() { // The first thing I need is a VPS class\n\t\tVirtualPetShelter testPetShelter = null; \t\t// I got an error eclipse ask to create class\n\t\tAssert.assertNull(testPetShelter);\t\t\t\t// I did not create a class instance so test was null\n\t}",
"public java.lang.String getAz_variation() throws java.rmi.RemoteException;",
"public String getBucket();",
"@NotNull\n @ApiModelProperty(required = true, value = \"Name of the storage region\")\n public String getLabel() {\n return label;\n }",
"public CartridgeHandle getCartridgeByName( String name )\n throws CdbException , InterruptedException {\n return _pvr.getCartridgeByName( name ) ;\n }",
"public static void main(String[] args) throws Exception {\n\t\t \n\t\t GoogleCredentials credentials = GoogleCredentials.fromStream(new FileInputStream(\"/home/sahana/Downloads/access.json\"));\n\t\t \n\t\t Storage storage = StorageOptions.newBuilder().setCredentials(credentials).build().getService();\n\t\t \n\t\t System.out.println(storage);\n\n\t\t // The name for the new bucket\n\t\t String bucketName = \"sahana\"; // \"my-new-bucket\";\n\t\t \n\t\t // Creates the new bucket\n\t\t Bucket bucket = storage.create(BucketInfo.of(bucketName));\n\n\t\t System.out.printf(\"Bucket %s created.%n\", bucket.getName()); \n\t\t \n\t\t //Bucket bucket = storage.create(BucketInfo.newBuilder(bucketName).setStorageClass(StorageClass.MULTI_REGIONAL).setLocation(\"asia\").build()); \n\t\t /*String bucketName = \"my_unique_bucket\";\n\t\t String blobName = \"my_blob_name\";\n\t\t BlobId blobId = BlobId.of(bucketName, blobName);\n\t\t BlobInfo blobInfo = BlobInfo.newBuilder(blobId).setContentType(\"text/plain\").build();\n\t\t Blob blob = storage.create(blobInfo);\n\t\t \n\t\t System.out.println(blob); */\n\t\t }",
"@Test(dependsOnMethods = \"testUpdateSecret\")\n public void testListSecretVersions() {\n SecretAttributes attributes = SecretAttributes.create(true, null, null, null, null, null);\n SecretBundle secretBundle = api().setSecret(vaultUri,\n SECRET_NAME,\n attributes,\n \"aNewSecretKey\",\n null,\n \"-----BEGIN DSA PRIVATE KEY-----\\n\" +\n \"MIIBvAIBAAKBgQDvgcVEyeU5gfw69xY2n1zHWGp/Z8O573SiWIcy29rW382W6jvn\\n\" +\n \"X5rF/LX8AscwRhf2pUTEy64ECkd08eRgEjRIKdGSaTZpBXxM25TPb2fF9k1/ObXd\\n\" +\n \"SkNOQNlwoCHdyQlvwdkVRohJoBX9u371owXObwLiBR1V597p3PdGNYD3DQIVAPtD\\n\" +\n \"dHQQaHCYMxAIXRsaCmOZfsjdAoGBANVOovY4XqS48hvi/RzcCMbRbuHMFBXh/lEM\\n\" +\n \"FmBdZ5sczpi1S3KpEjnBPQfOTzspTlEm5y6cHbkQjh1qT1tMdPAAr5aHYVLCTR+v\\n\" +\n \"CSSALXP48YiZrJcgdyfhbyr5h/Su2QuwX2DvYrR9d88fYHU4O0njEyMd8UFwQ6Uy\\n\" +\n \"qez/catgAoGAJ2AbSklFUXYvehmCVO6XVo3bgO++C3GMycJY3HHTTFQNAb3LJkeO\\n\" +\n \"fa2ZCSqWbd85M00Lt0VEkqlb0EkjDvAgL0R78IJUmvb3FH1RiUofP/yK3g1/3I/l\\n\" +\n \"jUa1fXXn2jSFYcyzGaDnC2U/B55g9G7hXsXJuldwATfDnLtqCdNPoWcCFQDx5K/k\\n\" +\n \"Ub4xHF/4Tau8wDAkxHeJiw==\\n\" +\n \"-----END DSA PRIVATE KEY-----\"\n );\n\n // List secret versions\n List<Secret> secrets = api().getSecretVersions(vaultUri, SECRET_NAME);\n assertNotNull(secrets);\n assertEquals(secrets.size(), 2);\n }",
"@Override\n\tpublic synchronized StorageOperationResponse<GetStorageVolumesResponse> getStorageVolumes(\n\t\t\tGetStorageVolumesRequest request) {\n\t\t\n\t\tStorageOperationResponse<GetStorageVolumesResponse> response = null;\n\t\ttry {\n\t\t\tList<StorageVolume> internalVolumes = null;\n\t\t\tList<Volume> volumeList = null;\n\t\t\tif (request.storageVolumeIds == null || request.storageVolumeIds.isEmpty()) {\n\t\t\t\tif (request.storageSystemId == null) {\n\t\t\t\t\tif (request.storagePoolId == null) {\n\t\t\t\t \treturn StorageAdapterImplHelper.createFailedResponse(\"Invalid Reqeust: all parameters are null\", GetStorageVolumesResponse.class); \n\t\t\t\t\t} else {\n\t\t\t\t\t\tvolumeList = openstackClient.listVolumes(request.storagePoolId);\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\tif (request.storagePoolId == null) {\n\t\t\t\t \tvolumeList = new ArrayList<Volume>();\n\t\t\t\t \tString region = openstackClient.getOpenstackId(request.storageSystemId);\n\t\t\t\t //\tfor (String zone:openstackClient.listAvailabilityZones(request.storageSystemId)) {\n\t\t\t\t \t\tvolumeList.addAll(openstackClient.listVolumes(region +\":\" + \"nova\"));\n\t\t\t\t //\t}\n\t\t\t\t\t} else {\n\t\t\t\t\t\tvolumeList = openstackClient.listVolumes(request.storagePoolId);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tinternalVolumes = OpenstackAdapterUtil.transformToStorageVolumeList(volumeList,request.storageSystemId);\n\t\t\t\t\t\n\t\t\t} else {\n\t\t\t internalVolumes = new ArrayList<StorageVolume>();\n\t\t for (String volumeId:request.storageVolumeIds) {\n\t\t \t Volume vol = openstackClient.getVolume(volumeId);\n\t\t \t if (vol == null) {\n\t\t \t\t internalVolumes.add(null);\n\t\t \t } else {\n\t\t \t\t internalVolumes.add(OpenstackAdapterUtil.toStorageVolume(vol, accountId +':'+ openstackClient.getRegion(volumeId)));\n\t\t \t }\n\t\t }\n\t\t\t}\n\t\t\t\n\t\t\tGetStorageVolumesResponse payload = new GetStorageVolumesResponse();\n\t\t\tpayload.storageVolumes = internalVolumes;\n\t\t\tresponse = new StorageOperationResponse<GetStorageVolumesResponse>(payload);\n\t\t\tresponse.setPercentCompleted(100);\n\t\t\tresponse.setStatus(StorageOperationStatus.COMPLETED);\n\n\t\t} catch (Exception e) {\n\t\t\t\n\t\t\tlogger.traceThrowable(IJavaEeLog.SEVERITY_DEBUG , this.getClass().getName(), \"getStorageVolumes:\", null, e);\n\t\t\treturn StorageAdapterImplHelper.createFailedResponse(e.getMessage(), GetStorageVolumesResponse.class); \n\t\t}\n\t\t\n\t\treturn response;\n\t}",
"public CartridgeHandle createCartridge( String name )\n throws CdbException , InterruptedException {\n return _pvr.createCartridge( name ) ;\n }",
"public Optional<Boolean> skipGetVaultVersion() {\n return Codegen.booleanProp(\"skipGetVaultVersion\").config(config).get();\n }",
"@Test(timeout=120000)\n public void testRegionDeployedNotInHdfs() throws Exception {\n TableName table =\n TableName.valueOf(\"testSingleRegionDeployedNotInHdfs\");\n try {\n setupTable(table);\n admin.flush(table);\n\n // Mess it up by deleting region dir\n deleteRegion(conf, tbl.getTableDescriptor(),\n HConstants.EMPTY_START_ROW, Bytes.toBytes(\"A\"), false,\n false, true);\n\n HBaseFsck hbck = doFsck(conf, false);\n assertErrors(hbck, new ERROR_CODE[] { ERROR_CODE.NOT_IN_HDFS });\n // fix hole\n doFsck(conf, true);\n // check that hole fixed\n assertNoErrors(doFsck(conf, false));\n } finally {\n cleanupTable(table);\n }\n }",
"public Volume prepareVolume(Project project, VirtualArray varray,\n VirtualPool vpool, String size, Recommendation recommendation, String label, BlockConsistencyGroup consistencyGroup,\n String token, boolean remote, URI protectionStorageSystem,\n Volume.PersonalityTypes personality, String rsetName, String internalSiteName, String rpCopyName, URI srcVolumeId,\n VpoolProtectionVarraySettings protectionSettings) {\n StoragePool pool = null;\n Volume volume = new Volume();\n volume.setId(URIUtil.createId(Volume.class));\n\n if (personality.equals(Volume.PersonalityTypes.METADATA)) {\n URI vpoolUri = (protectionSettings != null ? protectionSettings.getJournalVpool() : URI.create(vpool.getJournalVpool()));\n vpool = _dbClient.queryObject(VirtualPool.class, vpoolUri);\n }\n volume.setLabel(label);\n volume.setCapacity(SizeUtil.translateSize(size));\n volume.setThinlyProvisioned(VirtualPool.ProvisioningType.Thin.toString().equalsIgnoreCase(vpool.getSupportedProvisioningType()));\n volume.setVirtualPool(vpool.getId());\n volume.setProject(new NamedURI(project.getId(), volume.getLabel()));\n volume.setTenant(new NamedURI(project.getTenantOrg().getURI(), volume.getLabel()));\n volume.setVirtualArray(varray.getId());\n if (null != recommendation.getSourcePool()) {\n pool = _dbClient.queryObject(StoragePool.class, recommendation.getSourcePool());\n if (null != pool) {\n volume.setProtocol(new StringSet());\n volume.getProtocol().addAll(\n VirtualPoolUtil.getMatchingProtocols(vpool.getProtocols(), pool.getProtocols()));\n }\n }\n volume.setPersonality(personality.toString());\n\n // Set all Journal Volumes to have the INTERNAL_OBJECT flag.\n if (personality.equals(Volume.PersonalityTypes.METADATA)) {\n volume.addInternalFlags(Flag.INTERNAL_OBJECT);\n volume.addInternalFlags(Flag.SUPPORTS_FORCE);\n volume.setAccessState(Volume.VolumeAccessState.NOT_READY.name());\n } else if (personality.equals(Volume.PersonalityTypes.SOURCE)) {\n volume.setAccessState(Volume.VolumeAccessState.READWRITE.name());\n volume.setLinkStatus(Volume.LinkStatus.OTHER.name());\n } else if (personality.equals(Volume.PersonalityTypes.TARGET)) {\n volume.setAccessState(Volume.VolumeAccessState.NOT_READY.name());\n volume.setLinkStatus(Volume.LinkStatus.OTHER.name());\n }\n\n volume.setProtectionController(protectionStorageSystem);\n volume.setRSetName(rsetName);\n volume.setInternalSiteName(internalSiteName);\n volume.setRpCopyName(rpCopyName);\n URI storagePoolUri = null;\n URI virtualArrayUri = varray.getId();\n\n if (NullColumnValueGetter.isNotNullValue(personality.toString())) {\n if (personality.equals(Volume.PersonalityTypes.SOURCE)) {\n storagePoolUri = recommendation.getSourcePool();\n } else {\n if (remote) {\n Protection protectionInfo = getProtectionInfo(varray, recommendation);\n if (personality.equals(Volume.PersonalityTypes.METADATA)) {\n // remote copy journal\n storagePoolUri = protectionInfo.getTargetJournalStoragePool();\n virtualArrayUri = protectionInfo.getTargetJournalVarray();\n } else {\n // remote copy\n storagePoolUri = protectionInfo.getTargetStoragePool();\n }\n } else {\n if (personality.equals(Volume.PersonalityTypes.METADATA)) {\n // protection settings is null only for production copy journal\n if (protectionSettings != null) {\n // local copy journal\n Protection protectionInfo = getProtectionInfo(varray, recommendation);\n storagePoolUri = protectionInfo.getTargetJournalStoragePool();\n virtualArrayUri = protectionInfo.getTargetJournalVarray();\n } else {\n // production copy journal\n storagePoolUri = ((RPProtectionRecommendation) recommendation).getSourceJournalStoragePool();\n virtualArrayUri = ((RPProtectionRecommendation) recommendation).getSourceJournalVarray();\n }\n } else if (personality.equals(Volume.PersonalityTypes.TARGET)) {\n // local copy\n Protection protectionInfo = getProtectionInfo(varray, recommendation);\n storagePoolUri = protectionInfo.getTargetStoragePool();\n }\n }\n }\n }\n\n volume.setVirtualArray(virtualArrayUri);\n volume.setPool(storagePoolUri);\n volume.setStorageController(_dbClient.queryObject(StoragePool.class, storagePoolUri).getStorageDevice());\n\n volume.setOpStatus(new OpStatusMap());\n Operation op = new Operation();\n op.setResourceType(ResourceOperationTypeEnum.CREATE_BLOCK_VOLUME);\n op.setStartTime(Calendar.getInstance());\n volume.getOpStatus().put(token, op);\n\n _dbClient.createObject(volume);\n\n // Keep track of target volumes associated with the source volume\n if (srcVolumeId != null) {\n Volume srcVolume = _dbClient.queryObject(Volume.class, srcVolumeId);\n if (srcVolume.getRpTargets() == null) {\n srcVolume.setRpTargets(new StringSet());\n }\n srcVolume.getRpTargets().add(volume.getId().toString());\n _dbClient.persistObject(srcVolume);\n }\n\n return volume;\n }",
"public String getKey() { return \"thaumcraft.CLOUD\"; }",
"SandBox createSandBox(Site site, String sandBoxName, SandBoxType sandBoxType) throws Exception;",
"public void setContainerName(String name) {\n this.name = name;\n }",
"String regionName();",
"String regionName();",
"String regionName();",
"String regionName();",
"public VirtualPet getPet(String name) {\n\t\treturn shelterPets.get(name);\n\n\t}",
"@Test\n public void testGetKafkaCredentialsFromVaultInvalidUrl() {\n Map<String, Map<String, String>> credentials =\n getKafkaCredentialsFromVault(\"some-url\", \"some-token\");\n Assert.assertEquals(new HashMap<>(), credentials);\n }",
"RiceCooker getByName(String name);",
"private static CloudBlobContainer getVersionContainer(CloudBlobClient serviceClient, String version) throws URISyntaxException, StorageException {\n String containerName = version.replace('.', '-');\n return serviceClient.getContainerReference(containerName);\n }",
"@Test(timeout=180000)\n public void testQuarantineMissingRegionDir() throws Exception {\n TableName table = TableName.valueOf(name.getMethodName());\n // inject a fault in the hfcc created.\n final FileSystem fs = FileSystem.get(conf);\n HBaseFsck hbck = new HBaseFsck(conf, hbfsckExecutorService) {\n @Override\n public HFileCorruptionChecker createHFileCorruptionChecker(boolean sidelineCorruptHFiles)\n throws IOException {\n return new HFileCorruptionChecker(conf, executor, sidelineCorruptHFiles) {\n AtomicBoolean attemptedFirstHFile = new AtomicBoolean(false);\n @Override\n protected void checkRegionDir(Path p) throws IOException {\n if (attemptedFirstHFile.compareAndSet(false, true)) {\n assertTrue(fs.delete(p, true)); // make sure delete happened.\n }\n super.checkRegionDir(p);\n }\n };\n }\n };\n doQuarantineTest(table, hbck, 3, 0, 0, 0, 1);\n hbck.close();\n }",
"public String getBucketName()\n {\n return bucketName;\n }",
"public String vnetName() {\n return this.vnetName;\n }",
"public SecretsStorage getSecretsStorageVault(VaultSettings config, MagnoliaConfigurationProperties magnoliaConfigurationProperties) {\n return new SecretsStorageVaultImpl()\n .withAddress(config.getHost())\n .withToken(getVaultToken(magnoliaConfigurationProperties))\n .withPrefix(config.getPrefix())\n .build();\n }",
"boolean hasVName();",
"WithResourceGroup withRegion(String location);",
"WithResourceGroup withRegion(String location);",
"@Given(\"^(.*) quiere escoger un vuelo$\")\n public void andresQuiereEscogerUnVuelo(String actorName) {\n theActorCalled(actorName).wasAbleTo(Open.url(\"https://www.vivaair.com/\"));\n }",
"private String getAlbumName() {\n return \"fotos_credencial\";\n }",
"public boolean authenticateIngredient(String ingredName, User user) {\n\t\tIngredient ingredient = iRepo.findByName(ingredName);\n // if we can't find it by name, return false\n if(ingredient == null) {\n return false;\n }\n //or if the ingredient has already been added to this user's pantry, send false\n if(user.getBar_stock().contains(ingredient)){\n \treturn false;\n } else {\n //otherwise, the ingred both exists in DB and not in user pantry. Return true.\n \treturn true;\n }\n }",
"String getComponentAppSecret();",
"public VirusInfo(VirusInfo source) {\n if (source.FileName != null) {\n this.FileName = new String(source.FileName);\n }\n if (source.FilePath != null) {\n this.FilePath = new String(source.FilePath);\n }\n if (source.VirusName != null) {\n this.VirusName = new String(source.VirusName);\n }\n if (source.CreateTime != null) {\n this.CreateTime = new String(source.CreateTime);\n }\n if (source.ModifyTime != null) {\n this.ModifyTime = new String(source.ModifyTime);\n }\n if (source.ContainerName != null) {\n this.ContainerName = new String(source.ContainerName);\n }\n if (source.ContainerId != null) {\n this.ContainerId = new String(source.ContainerId);\n }\n if (source.ContainerStatus != null) {\n this.ContainerStatus = new String(source.ContainerStatus);\n }\n if (source.ImageName != null) {\n this.ImageName = new String(source.ImageName);\n }\n if (source.ImageId != null) {\n this.ImageId = new String(source.ImageId);\n }\n if (source.Status != null) {\n this.Status = new String(source.Status);\n }\n if (source.Id != null) {\n this.Id = new String(source.Id);\n }\n if (source.HarmDescribe != null) {\n this.HarmDescribe = new String(source.HarmDescribe);\n }\n if (source.SuggestScheme != null) {\n this.SuggestScheme = new String(source.SuggestScheme);\n }\n if (source.SubStatus != null) {\n this.SubStatus = new String(source.SubStatus);\n }\n if (source.ContainerNetStatus != null) {\n this.ContainerNetStatus = new String(source.ContainerNetStatus);\n }\n if (source.ContainerNetSubStatus != null) {\n this.ContainerNetSubStatus = new String(source.ContainerNetSubStatus);\n }\n if (source.ContainerIsolateOperationSrc != null) {\n this.ContainerIsolateOperationSrc = new String(source.ContainerIsolateOperationSrc);\n }\n if (source.MD5 != null) {\n this.MD5 = new String(source.MD5);\n }\n if (source.RiskLevel != null) {\n this.RiskLevel = new String(source.RiskLevel);\n }\n if (source.CheckPlatform != null) {\n this.CheckPlatform = new String[source.CheckPlatform.length];\n for (int i = 0; i < source.CheckPlatform.length; i++) {\n this.CheckPlatform[i] = new String(source.CheckPlatform[i]);\n }\n }\n if (source.NodeID != null) {\n this.NodeID = new String(source.NodeID);\n }\n if (source.NodeName != null) {\n this.NodeName = new String(source.NodeName);\n }\n if (source.PodIP != null) {\n this.PodIP = new String(source.PodIP);\n }\n if (source.PodName != null) {\n this.PodName = new String(source.PodName);\n }\n if (source.ClusterID != null) {\n this.ClusterID = new String(source.ClusterID);\n }\n if (source.NodeType != null) {\n this.NodeType = new String(source.NodeType);\n }\n if (source.PublicIP != null) {\n this.PublicIP = new String(source.PublicIP);\n }\n if (source.InnerIP != null) {\n this.InnerIP = new String(source.InnerIP);\n }\n if (source.NodeUniqueID != null) {\n this.NodeUniqueID = new String(source.NodeUniqueID);\n }\n if (source.HostID != null) {\n this.HostID = new String(source.HostID);\n }\n if (source.ClusterName != null) {\n this.ClusterName = new String(source.ClusterName);\n }\n }",
"BucketName(String bucketName) {\n this.bucketName = bucketName;\n }",
"private boolean setupVaultChat() {\n RegisteredServiceProvider<Chat> rsp = getServer().getServicesManager().getRegistration(net.milkbowl.vault.chat.Chat.class);\n if (rsp != null) {\n \t vaultChat = rsp.getProvider();\n }\n return (vaultChat != null);\n }",
"@Test\n\tpublic void getInventoryTest() {\n\t\tLongTermStorage ltsTest1 = new LongTermStorage();\n\t\tassertNotNull(ltsTest1.getInventory());\n\t}",
"private static ServiceAccount getInstanceByVcapServices(String serviceInstanceName) {\n Map<String, String> env = System.getenv();\n String vcapServices = env.get(\"VCAP_SERVICES\");\n if (vcapServices == null) {\n return null;\n }\n\n ServiceAccount account = null;\n try {\n JsonObject obj = new JsonParser().parse(vcapServices).getAsJsonObject();\n JsonArray gaasArray = obj.getAsJsonArray(GAAS_SERVICE_NAME);\n if (gaasArray != null) {\n for (int i = 0; i < gaasArray.size(); i++) {\n JsonObject gaasEntry = gaasArray.get(i).getAsJsonObject();\n if (serviceInstanceName != null) {\n // When service instance name is specified,\n // this method returns only a matching entry\n JsonPrimitive name = gaasEntry.getAsJsonPrimitive(\"name\");\n if (name == null || !serviceInstanceName.equals(name.getAsString())) {\n continue;\n }\n }\n JsonObject credentials = gaasEntry.getAsJsonObject(\"credentials\");\n if (credentials == null) {\n continue;\n }\n JsonPrimitive jsonUri = credentials.getAsJsonPrimitive(\"uri\");\n JsonPrimitive jsonApiKey = credentials.getAsJsonPrimitive(\"api_key\");\n if (jsonUri != null && jsonApiKey != null) {\n logger.info(\"A ServiceAccount is created from VCAP_SERVICES: uri=\"\n + jsonUri + \", api_key=***\");\n account = getInstance(jsonUri.getAsString(), jsonApiKey.getAsString());\n break;\n }\n }\n }\n } catch (JsonParseException e) {\n // Fall through - will return null\n }\n\n return account;\n }",
"public Ingredient(String name){\r\n\t\tthis.name = name;\r\n\t}",
"@Override\n\tpublic String getInventoryName(){\n\t return ModBlocks.ModularCrate.getUnlocalizedName() + \".name\";\n\t}",
"java.lang.String getSecret();",
"public String keyVaultSecretId() {\n return this.keyVaultSecretId;\n }",
"@Test\n public void testNullCredential(final TestContext aContext) {\n final Async asyncTask = aContext.async();\n final JsonObject nullConfigs = myConfigs;\n\n nullConfigs.put(IIIF_USERNAME, (String) null);\n nullConfigs.put(IIIF_PASSWORD, (String) null);\n\n deployNewVerticle(nullConfigs).onFailure(failure -> {\n TestUtils.complete(asyncTask);\n }).onSuccess(success -> {\n aContext.fail();\n });\n }",
"private RunVolumes() {}",
"@Override\n public String toString() {\n StringBuilder sb = new StringBuilder();\n sb.append(\"{\");\n if (getAccountId() != null) sb.append(\"AccountId: \" + getAccountId() + \",\");\n if (getVaultName() != null) sb.append(\"VaultName: \" + getVaultName() + \",\");\n if (getUploadId() != null) sb.append(\"UploadId: \" + getUploadId() + \",\");\n if (getArchiveSize() != null) sb.append(\"ArchiveSize: \" + getArchiveSize() + \",\");\n if (getChecksum() != null) sb.append(\"Checksum: \" + getChecksum() );\n sb.append(\"}\");\n return sb.toString();\n }",
"public VTorInUseException(String message) {\n super(message);\n }",
"@Then(\"^obtener el vuelo mas barato$\")\n public void obtenerElVueloMasBarato() {\n theActorInTheSpotlight().attemptsTo(new ObtenerVuelo());\n }",
"public VueG getVueg() {\n return vueg;\n }",
"String getSecret();",
"private String mapToAmazonVolState(String state) {\n if (state.equalsIgnoreCase(\"Allocated\") || state.equalsIgnoreCase(\"Creating\") || state.equalsIgnoreCase(\"Ready\"))\n return \"available\";\n\n if (state.equalsIgnoreCase(\"Destroy\"))\n return \"deleting\";\n\n return \"error\";\n }",
"public HealthCheck getRegionalHelathCheckByName(String region, String healthCheckName) {\n try {\n HealthCheck healthCheck =\n compute.regionHealthChecks().get(project, region, healthCheckName).execute();\n return healthCheck;\n } catch (GoogleJsonResponseException e) {\n throw new PlatformServiceException(\n BAD_REQUEST, \"Failed to fetch health check for name: \" + healthCheckName);\n } catch (IOException e) {\n throw new PlatformServiceException(\n INTERNAL_SERVER_ERROR, \"Failed to fetch health check \" + healthCheckName);\n }\n }",
"public Secret readSecret(final ArtifactVersion version);",
"String getDockerRepositoryName();",
"private static String getUserSalt(String args[]) {\n return args[2].trim() ;\n }",
"net.zyuiop.ovhapi.api.objects.license.Option getServiceNameOptionLabel(java.lang.String serviceName, java.lang.String label) throws java.io.IOException;",
"public String getBucketName() {\n return bucketName;\n }",
"public String getBucketName() {\n return bucketName;\n }",
"public CloudServiceVaultCertificate() {\n }",
"public void checkout() throws VcsException;",
"private String mapToCloudStackResourceType(String resourceType) {\n if (resourceType.equalsIgnoreCase(\"image\"))\n return (\"template\");\n else if (resourceType.equalsIgnoreCase(\"instance\"))\n return (\"userVm\");\n else if (resourceType.equalsIgnoreCase(\"security-group\"))\n return (\"securityGroup\");\n else\n return resourceType;\n }",
"private void getSecret() {\n\t\tAWSSecretsManager client = AWSSecretsManagerClientBuilder.standard().withRegion(region).build();\n\n\t\t// In this sample we only handle the specific exceptions for the\n\t\t// 'GetSecretValue' API.\n\t\t// See\n\t\t// https://docs.aws.amazon.com/secretsmanager/latest/apireference/API_GetSecretValue.html\n\t\t// We rethrow the exception by default.\n\n\t\tGetSecretValueRequest getSecretValueRequest = new GetSecretValueRequest().withSecretId(secretName);\n\t\tGetSecretValueResult getSecretValueResult = null;\n\n\t\ttry {\n\t\t\tgetSecretValueResult = client.getSecretValue(getSecretValueRequest);\n\t\t}\n\t\t// @TODO: Figure out what I should do here. Generic exception?.\n\t\tcatch (DecryptionFailureException e) {\n\t\t\t// Secrets Manager can't decrypt the protected secret text using the provided\n\t\t\t// KMS key.\n\t\t\t// Deal with the exception here, and/or rethrow at your discretion.\n\t\t\te.printStackTrace();\n\t\t} catch (InternalServiceErrorException e) {\n\t\t\t// An error occurred on the server side.\n\t\t\t// Deal with the exception here, and/or rethrow at your discretion.\n\t\t\te.printStackTrace();\n\t\t} catch (InvalidParameterException e) {\n\t\t\t// You provided an invalid value for a parameter.\n\t\t\t// Deal with the exception here, and/or rethrow at your discretion.\n\t\t\te.printStackTrace();\n\t\t} catch (InvalidRequestException e) {\n\t\t\t// You provided a parameter value that is not valid for the current state of the\n\t\t\t// resource.\n\t\t\t// Deal with the exception here, and/or rethrow at your discretion.\n\t\t\te.printStackTrace();\n\t\t} catch (ResourceNotFoundException e) {\n\t\t\t// We can't find the resource that you asked for.\n\t\t\t// Deal with the exception here, and/or rethrow at your discretion.\n\t\t\te.printStackTrace();\n\t\t}\n\n\t\tif (getSecretValueResult.getSecretString() != null) {\n\t\t\ttry {\n\t\t\t\tresult = new ObjectMapper().readValue(getSecretValueResult.getSecretString(), HashMap.class);\n\t\t\t} catch (JsonMappingException e) {\n\t\t\t\tlogger.error(\"ERROR :\", e);\n\t\t\t\te.printStackTrace();\n\t\t\t} catch (JsonProcessingException e) {\n\t\t\t\t// TODO Auto-generated catch block\n\t\t\t\te.printStackTrace();\n\t\t\t}\n\n\t\t}\n\t\t// AWS defualt else, unsure why it is in the default. Need to check.\n\t\t//Maybe encryption not setup right?\n\t\telse {\n\t\t\tdecodedBinarySecret = new String(\n\t\t\t\t\tBase64.getDecoder().decode(getSecretValueResult.getSecretBinary()).array());\n\t\t}\n\t}",
"@Test\n\tpublic void testG(){\n\t\tSystem.out.println(\"Test G\");\n\t\tUUID aliceSecret = secretService.storeSecret(\"Alice\", new Secret());\n\t\tsecretService.shareSecret(\"Alice\", aliceSecret, \"Bob\");\n\t\tsecretService.shareSecret(\"Bob\", aliceSecret, \"Carl\");\n\t\tsecretService.unshareSecret(\"Bob\", aliceSecret, \"Carl\");\n\t\tsecretService.readSecret(\"Carl\", aliceSecret);\n\t}",
"public Bucket loadBucket(String name) throws S3Exception {\n\t\treturn null;\r\n\t}",
"private void checkSyncDirExists() {\n syncDirString = IVLEOfflineStorage.GetPropertyValue(Constants.SyncDirectory);\n if(syncDirString != null || syncDirString != \"\") {\n jTextField3.setText(syncDirString);\n } else {\n jTextField3.setText(\"Please Select a Sync Directory.\");\n }\n }",
"public void createSecret(final ArtifactVersion version, final Secret secret);",
"@Test(expectedExceptions = IllegalArgumentException.class)\n public void testConstructorWithNullAuthenticator() throws Throwable {\n final String serviceName = \"testService\";\n\n new SecretsManager(serviceName, null);\n }",
"void createRecipe(Recipe recipe) throws ServiceFailureException;",
"public VTorInUseException() {\n super();\n }",
"@Test\n public void testInvalidCredential(final TestContext aContext) {\n final Async asyncTask = aContext.async();\n final JsonObject newConfigs = myConfigs;\n\n newConfigs.put(IIIF_USERNAME, \"username\");\n newConfigs.put(IIIF_PASSWORD, \"password\");\n\n deployNewVerticle(newConfigs).onFailure(failure -> {\n TestUtils.complete(asyncTask);\n }).onSuccess(success -> {\n aContext.fail();\n });\n }",
"public MyVM(String virtual_machine_name)\n {\n \ttry\n \t{\n \t\tthis.vmname= virtual_machine_name;\n \t\tthis.si=new ServiceInstance(new URL(SJSULAB.getVmwareHostURL()),\n\t\t\t\t\tSJSULAB.getVmwareLogin(), SJSULAB.getVmwarePassword(), true);\n \t\t\n \t\tthis.folder = si.getRootFolder();\n \t\tthis.vm=(VirtualMachine) new InventoryNavigator(folder).searchManagedEntity(\"VirtualMachine\",\n \t\t\t\tthis.vmname);\n \t\tSystem.out.println(\"MyVM, vm value : \"+vm);\n \t\t\n \t\tthis.hs= (HostSystem) new InventoryNavigator(folder).searchManagedEntity(\"HostSystem\", \"130.65.132.194\");\n \t\tSystem.out.println(\"MyVM, HS value : \"+hs);\n \t\tthis.snapshotname=\"snap2\";\n \t\t\n \t}\n \tcatch(Exception e)\n \t{\n \t\tSystem.out.println(e.toString());\n \t}\n }",
"java.lang.String getS3();",
"@Test\n public void testName() throws Exception {\n GoogleRobotMetadataCredentials credentials =\n new GoogleRobotMetadataCredentials(PROJECT_ID, null /* module */);\n SystemCredentialsProvider.getInstance().getCredentials().add(credentials);\n\n assertEquals(PROJECT_ID, CredentialsNameProvider.name(credentials));\n assertEquals(PROJECT_ID, new GoogleRobotNameProvider().getName(credentials));\n }",
"public SureBetNotFoundException() {\r\n\t\tsuper();\r\n\t}"
] | [
"0.68399847",
"0.6744287",
"0.63126266",
"0.55692583",
"0.5191981",
"0.51572907",
"0.4928872",
"0.48527962",
"0.47131416",
"0.46188256",
"0.46016517",
"0.45863813",
"0.45836902",
"0.457018",
"0.45391354",
"0.44141355",
"0.436803",
"0.43334344",
"0.43226245",
"0.4232838",
"0.42266205",
"0.41874376",
"0.41815674",
"0.4152478",
"0.41431037",
"0.41325322",
"0.41123545",
"0.41121742",
"0.41120774",
"0.41102743",
"0.40882322",
"0.40863362",
"0.40801325",
"0.4070861",
"0.40702096",
"0.4068689",
"0.40668502",
"0.40277392",
"0.40220892",
"0.40213746",
"0.40196303",
"0.40103823",
"0.40103823",
"0.40103823",
"0.40103823",
"0.40034953",
"0.4002162",
"0.40016472",
"0.39979592",
"0.39955047",
"0.3989778",
"0.3989745",
"0.3971097",
"0.39577448",
"0.39410013",
"0.39410013",
"0.3920682",
"0.39201668",
"0.39165288",
"0.391284",
"0.39025426",
"0.38939095",
"0.38894567",
"0.38839212",
"0.38816777",
"0.3880861",
"0.38753593",
"0.3874631",
"0.38729125",
"0.38658965",
"0.38658094",
"0.38654172",
"0.38562",
"0.38554493",
"0.38370633",
"0.38328815",
"0.3826081",
"0.3821723",
"0.38162658",
"0.3812998",
"0.38074452",
"0.38057727",
"0.38018683",
"0.38018683",
"0.3780417",
"0.37763324",
"0.37762317",
"0.37748325",
"0.37659785",
"0.3762991",
"0.37613755",
"0.3760552",
"0.3749765",
"0.37479326",
"0.37456787",
"0.3743275",
"0.37397617",
"0.3737702",
"0.3731196",
"0.37291282"
] | 0.71297055 | 0 |
aws service endpoint example: 'glacier.eucentral1.amazonaws.com' | String serviceEndpoint(); | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public interface AWSServiceCatalog {\n\n /**\n * The region metadata service name for computing region endpoints. You can use this value to retrieve metadata\n * (such as supported regions) of the service.\n *\n * @see RegionUtils#getRegionsForService(String)\n */\n String ENDPOINT_PREFIX = \"servicecatalog\";\n\n /**\n * Overrides the default endpoint for this client (\"servicecatalog.us-east-1.amazonaws.com\"). Callers can use this\n * method to control which AWS region they want to work with.\n * <p>\n * Callers can pass in just the endpoint (ex: \"servicecatalog.us-east-1.amazonaws.com\") or a full URL, including the\n * protocol (ex: \"servicecatalog.us-east-1.amazonaws.com\"). If the protocol is not specified here, the default\n * protocol from this client's {@link ClientConfiguration} will be used, which by default is HTTPS.\n * <p>\n * For more information on using AWS regions with the AWS SDK for Java, and a complete list of all available\n * endpoints for all AWS services, see: <a\n * href=\"http://developer.amazonwebservices.com/connect/entry.jspa?externalID=3912\">\n * http://developer.amazonwebservices.com/connect/entry.jspa?externalID=3912</a>\n * <p>\n * <b>This method is not threadsafe. An endpoint should be configured when the client is created and before any\n * service requests are made. Changing it afterwards creates inevitable race conditions for any service requests in\n * transit or retrying.</b>\n *\n * @param endpoint\n * The endpoint (ex: \"servicecatalog.us-east-1.amazonaws.com\") or a full URL, including the protocol (ex:\n * \"servicecatalog.us-east-1.amazonaws.com\") of the region specific AWS endpoint this client will communicate\n * with.\n */\n void setEndpoint(String endpoint);\n\n /**\n * An alternative to {@link AWSServiceCatalog#setEndpoint(String)}, sets the regional endpoint for this client's\n * service calls. Callers can use this method to control which AWS region they want to work with.\n * <p>\n * By default, all service endpoints in all regions use the https protocol. To use http instead, specify it in the\n * {@link ClientConfiguration} supplied at construction.\n * <p>\n * <b>This method is not threadsafe. A region should be configured when the client is created and before any service\n * requests are made. Changing it afterwards creates inevitable race conditions for any service requests in transit\n * or retrying.</b>\n *\n * @param region\n * The region this client will communicate with. See {@link Region#getRegion(com.amazonaws.regions.Regions)}\n * for accessing a given region. Must not be null and must be a region where the service is available.\n *\n * @see Region#getRegion(com.amazonaws.regions.Regions)\n * @see Region#createClient(Class, com.amazonaws.auth.AWSCredentialsProvider, ClientConfiguration)\n * @see Region#isServiceSupported(String)\n */\n void setRegion(Region region);\n\n /**\n * <p>\n * Retrieves information about a specified product.\n * </p>\n * <p>\n * This operation is functionally identical to <a>DescribeProductView</a> except that it takes as input\n * <code>ProductId</code> instead of <code>ProductViewId</code>.\n * </p>\n * \n * @param describeProductRequest\n * @return Result of the DescribeProduct operation returned by the service.\n * @throws ResourceNotFoundException\n * The specified resource was not found.\n * @throws InvalidParametersException\n * One or more parameters provided to the operation are invalid.\n * @sample AWSServiceCatalog.DescribeProduct\n */\n DescribeProductResult describeProduct(DescribeProductRequest describeProductRequest);\n\n /**\n * <p>\n * Retrieves information about a specified product.\n * </p>\n * <p>\n * This operation is functionally identical to <a>DescribeProduct</a> except that it takes as input\n * <code>ProductViewId</code> instead of <code>ProductId</code>.\n * </p>\n * \n * @param describeProductViewRequest\n * @return Result of the DescribeProductView operation returned by the service.\n * @throws ResourceNotFoundException\n * The specified resource was not found.\n * @throws InvalidParametersException\n * One or more parameters provided to the operation are invalid.\n * @sample AWSServiceCatalog.DescribeProductView\n */\n DescribeProductViewResult describeProductView(DescribeProductViewRequest describeProductViewRequest);\n\n /**\n * <p>\n * Provides information about parameters required to provision a specified product in a specified manner. Use this\n * operation to obtain the list of <code>ProvisioningArtifactParameters</code> parameters available to call the\n * <a>ProvisionProduct</a> operation for the specified product.\n * </p>\n * \n * @param describeProvisioningParametersRequest\n * @return Result of the DescribeProvisioningParameters operation returned by the service.\n * @throws InvalidParametersException\n * One or more parameters provided to the operation are invalid.\n * @throws ResourceNotFoundException\n * The specified resource was not found.\n * @sample AWSServiceCatalog.DescribeProvisioningParameters\n */\n DescribeProvisioningParametersResult describeProvisioningParameters(DescribeProvisioningParametersRequest describeProvisioningParametersRequest);\n\n /**\n * <p>\n * Retrieves a paginated list of the full details of a specific request. Use this operation after calling a request\n * operation (<a>ProvisionProduct</a>, <a>TerminateProvisionedProduct</a>, or <a>UpdateProvisionedProduct</a>).\n * </p>\n * \n * @param describeRecordRequest\n * @return Result of the DescribeRecord operation returned by the service.\n * @throws ResourceNotFoundException\n * The specified resource was not found.\n * @sample AWSServiceCatalog.DescribeRecord\n */\n DescribeRecordResult describeRecord(DescribeRecordRequest describeRecordRequest);\n\n /**\n * <p>\n * Returns a paginated list of all paths to a specified product. A path is how the user has access to a specified\n * product, and is necessary when provisioning a product. A path also determines the constraints put on the product.\n * </p>\n * \n * @param listLaunchPathsRequest\n * @return Result of the ListLaunchPaths operation returned by the service.\n * @throws InvalidParametersException\n * One or more parameters provided to the operation are invalid.\n * @throws ResourceNotFoundException\n * The specified resource was not found.\n * @sample AWSServiceCatalog.ListLaunchPaths\n */\n ListLaunchPathsResult listLaunchPaths(ListLaunchPathsRequest listLaunchPathsRequest);\n\n /**\n * <p>\n * Returns a paginated list of all performed requests, in the form of RecordDetails objects that are filtered as\n * specified.\n * </p>\n * \n * @param listRecordHistoryRequest\n * @return Result of the ListRecordHistory operation returned by the service.\n * @throws InvalidParametersException\n * One or more parameters provided to the operation are invalid.\n * @sample AWSServiceCatalog.ListRecordHistory\n */\n ListRecordHistoryResult listRecordHistory(ListRecordHistoryRequest listRecordHistoryRequest);\n\n /**\n * <p>\n * Requests a <i>Provision</i> of a specified product. A <i>ProvisionedProduct</i> is a resourced instance for a\n * product. For example, provisioning a CloudFormation-template-backed product results in launching a CloudFormation\n * stack and all the underlying resources that come with it.\n * </p>\n * <p>\n * You can check the status of this request using the <a>DescribeRecord</a> operation.\n * </p>\n * \n * @param provisionProductRequest\n * @return Result of the ProvisionProduct operation returned by the service.\n * @throws InvalidParametersException\n * One or more parameters provided to the operation are invalid.\n * @throws ResourceNotFoundException\n * The specified resource was not found.\n * @throws DuplicateResourceException\n * The specified resource is a duplicate.\n * @sample AWSServiceCatalog.ProvisionProduct\n */\n ProvisionProductResult provisionProduct(ProvisionProductRequest provisionProductRequest);\n\n /**\n * <p>\n * Returns a paginated list of all the ProvisionedProduct objects that are currently available (not terminated).\n * </p>\n * \n * @param scanProvisionedProductsRequest\n * @return Result of the ScanProvisionedProducts operation returned by the service.\n * @throws InvalidParametersException\n * One or more parameters provided to the operation are invalid.\n * @sample AWSServiceCatalog.ScanProvisionedProducts\n */\n ScanProvisionedProductsResult scanProvisionedProducts(ScanProvisionedProductsRequest scanProvisionedProductsRequest);\n\n /**\n * <p>\n * Returns a paginated list all of the <code>Products</code> objects to which the caller has access.\n * </p>\n * <p>\n * The output of this operation can be used as input for other operations, such as <a>DescribeProductView</a>.\n * </p>\n * \n * @param searchProductsRequest\n * @return Result of the SearchProducts operation returned by the service.\n * @throws InvalidParametersException\n * One or more parameters provided to the operation are invalid.\n * @sample AWSServiceCatalog.SearchProducts\n */\n SearchProductsResult searchProducts(SearchProductsRequest searchProductsRequest);\n\n /**\n * <p>\n * Requests termination of an existing ProvisionedProduct object. If there are <code>Tags</code> associated with the\n * object, they are terminated when the ProvisionedProduct object is terminated.\n * </p>\n * <p>\n * This operation does not delete any records associated with the ProvisionedProduct object.\n * </p>\n * <p>\n * You can check the status of this request using the <a>DescribeRecord</a> operation.\n * </p>\n * \n * @param terminateProvisionedProductRequest\n * @return Result of the TerminateProvisionedProduct operation returned by the service.\n * @throws ResourceNotFoundException\n * The specified resource was not found.\n * @sample AWSServiceCatalog.TerminateProvisionedProduct\n */\n TerminateProvisionedProductResult terminateProvisionedProduct(TerminateProvisionedProductRequest terminateProvisionedProductRequest);\n\n /**\n * <p>\n * Requests updates to the configuration of an existing ProvisionedProduct object. If there are tags associated with\n * the object, they cannot be updated or added with this operation. Depending on the specific updates requested,\n * this operation may update with no interruption, with some interruption, or replace the ProvisionedProduct object\n * entirely.\n * </p>\n * <p>\n * You can check the status of this request using the <a>DescribeRecord</a> operation.\n * </p>\n * \n * @param updateProvisionedProductRequest\n * @return Result of the UpdateProvisionedProduct operation returned by the service.\n * @throws InvalidParametersException\n * One or more parameters provided to the operation are invalid.\n * @throws ResourceNotFoundException\n * The specified resource was not found.\n * @sample AWSServiceCatalog.UpdateProvisionedProduct\n */\n UpdateProvisionedProductResult updateProvisionedProduct(UpdateProvisionedProductRequest updateProvisionedProductRequest);\n\n /**\n * Shuts down this client object, releasing any resources that might be held open. This is an optional method, and\n * callers are not expected to call it, but can if they want to explicitly release any open resources. Once a client\n * has been shutdown, it should not be used to make any more requests.\n */\n void shutdown();\n\n /**\n * Returns additional metadata for a previously executed successful request, typically used for debugging issues\n * where a service isn't acting as expected. This data isn't considered part of the result data returned by an\n * operation, so it's available through this separate, diagnostic interface.\n * <p>\n * Response metadata is only cached for a limited period of time, so if you need to access this extra diagnostic\n * information for an executed request, you should use this method to retrieve it as soon as possible after\n * executing a request.\n *\n * @param request\n * The originally executed request.\n *\n * @return The response metadata for the specified request, or null if none is available.\n */\n ResponseMetadata getCachedResponseMetadata(AmazonWebServiceRequest request);\n\n}",
"static RestClientBuilder.HttpClientConfigCallback getAWSRequestSigningInterceptor(String endpoint) {\n\t\treturn (HttpAsyncClientBuilder httpClientBuilder) -> {\n\t\t\thttpClientBuilder.addInterceptorLast((HttpRequest request, HttpContext context) -> {\n\t\t\t\tAws4Signer signer = Aws4Signer.create();\n\t\t\t\tAwsCredentials creds = DefaultCredentialsProvider.create().resolveCredentials();\n\t\t\t\tAws4SignerParams.Builder<?> signerParams = Aws4SignerParams.builder().\n\t\t\t\t\t\tawsCredentials(creds).\n\t\t\t\t\t\tdoubleUrlEncode(true).\n\t\t\t\t\t\tsigningName(\"es\").\n\t\t\t\t\t\tsigningRegion(Region.of(Para.getConfig().elasticsearchAwsRegion()));\n\t\t\t\tURIBuilder uriBuilder;\n\t\t\t\tString httpMethod = request.getRequestLine().getMethod();\n\t\t\t\tString resourcePath;\n\t\t\t\tMap<String, String> params = new HashMap<>();\n\n\t\t\t\ttry {\n\t\t\t\t\tSdkHttpFullRequest.Builder r = SdkHttpFullRequest.builder();\n\t\t\t\t\tif (!StringUtils.isBlank(httpMethod)) {\n\t\t\t\t\t\tr.method(SdkHttpMethod.valueOf(httpMethod));\n\t\t\t\t\t}\n\n\t\t\t\t\tif (!StringUtils.isBlank(endpoint)) {\n\t\t\t\t\t\tif (endpoint.startsWith(\"https://\")) {\n\t\t\t\t\t\t\tr.protocol(\"HTTPS\");\n\t\t\t\t\t\t\tr.host(StringUtils.removeStart(endpoint, \"https://\"));\n\t\t\t\t\t\t} else if (endpoint.startsWith(\"http://\")) {\n\t\t\t\t\t\t\tr.protocol(\"HTTP\");\n\t\t\t\t\t\t\tr.host(StringUtils.removeStart(endpoint, \"http://\"));\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\t\turiBuilder = new URIBuilder(request.getRequestLine().getUri());\n\t\t\t\t\tresourcePath = uriBuilder.getPath();\n\t\t\t\t\tif (!StringUtils.isBlank(resourcePath)) {\n\t\t\t\t\t\tr.encodedPath(resourcePath);\n\t\t\t\t\t}\n\n\t\t\t\t\tfor (NameValuePair param : uriBuilder.getQueryParams()) {\n\t\t\t\t\t\tr.appendRawQueryParameter(param.getName(), param.getValue());\n\t\t\t\t\t}\n\n\t\t\t\t\tif (request instanceof HttpEntityEnclosingRequest) {\n\t\t\t\t\t\tHttpEntity body = ((HttpEntityEnclosingRequest) request).getEntity();\n\t\t\t\t\t\tif (body != null) {\n\t\t\t\t\t\t\tInputStream is = body.getContent();\n\t\t\t\t\t\t\tr.contentStreamProvider(() -> is);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tif (r.contentStreamProvider() == null) {\n\t\t\t\t\t\trequest.removeHeaders(\"Content-Length\");\n\t\t\t\t\t}\n\n\t\t\t\t\tfor (Header header : request.getAllHeaders()) {\n\t\t\t\t\t\tr.putHeader(header.getName(), header.getValue());\n\t\t\t\t\t}\n\n\t\t\t\t\tSdkHttpFullRequest signedReq = signer.sign(r.build(), signerParams.build());\n\n\t\t\t\t\tfor (String header : signedReq.headers().keySet()) {\n\t\t\t\t\t\trequest.setHeader(header, signedReq.firstMatchingHeader(header).orElse(\"\"));\n\t\t\t\t\t}\n\t\t\t\t} catch (Exception ex) {\n\t\t\t\t\tlogger.error(\"Failed to sign request to AWS Elasticsearch:\", ex);\n\t\t\t\t}\n\t\t\t});\n\t\t\treturn httpClientBuilder;\n\t\t};\n\t}",
"@JsonIgnore\n @Hidden\n @Description(\"The URL for the GCS API.\")\n String getGcsEndpoint();",
"String endpoint();",
"@FeignClient(name = \"feign-service\",url = \"http://wthrcdn.etouch.cn\")\npublic interface FeignService {\n\n @GetMapping(value = \"/weather_mini\")\n ResponseEntity<Byte[]> getWeatherData(@RequestParam(\"citykey\") String citykey); // ?citykey=101280601\n}",
"public static void main(String[] args) throws Exception {\n CloudFrontService cloudFrontService = new CloudFrontService(\n SamplesUtils.loadAWSCredentials());\n \n // List your distributions\n Distribution[] distributions = cloudFrontService.listDistributions();\n for (int i = 0; i < distributions.length; i++) {\n System.out.println(\"Distribution \" + (i + 1) + \": \" + distributions[i]);\n }\n \n /*\n // List the distributions applied to a given S3 bucket\n Distribution[] bucketDistributions = cloudFrontService.listDistributions(\"jets3t\");\n for (int i = 0; i < bucketDistributions.length; i++) {\n System.out.println(\"Bucket distribution \" + (i + 1) + \": \" + bucketDistributions[i]);\n }\n \n // Create a new distribution \n String originBucket = \"jets3t.s3.amazonaws.com\";\n Distribution newDistribution = cloudFrontService.createDistribution(\n originBucket, \n \"\" + System.currentTimeMillis(), // Caller reference - a unique string value\n new String[] {\"test1.jamesmurty.com\"}, // CNAME aliases for distribution\n \"Testing\", // Comment\n true // Enabled?\n );\n System.out.println(\"New Distribution: \" + newDistribution);\n \n // The ID of the new distribution we will use for testing\n String testDistributionId = newDistribution.getId(); \n \n // List information about a distribution\n Distribution distribution = cloudFrontService.getDistributionInfo(testDistributionId);\n System.out.println(\"Distribution: \" + distribution);\n\n // List configuration information about a distribution\n DistributionConfig distributionConfig = cloudFrontService.getDistributionConfig(testDistributionId);\n System.out.println(\"Distribution Config: \" + distributionConfig);\n\n // Update a distribution's configuration, in this case to add an extra CNAME alias.\n DistributionConfig updatedDistributionConfig = cloudFrontService.updateDistributionConfig(\n testDistributionId, \n new String[] {\"test1.jamesmurty.com\", \"test2.jamesmurty.com\"}, // CNAME aliases for distribution\n \"Another comment for testing\", // Comment \n true // Enabled?\n );\n System.out.println(\"Updated Distribution Config: \" + updatedDistributionConfig);\n\n // Disable a distribution, e.g. so that it may be deleted. This operation may take some time to complete...\n DistributionConfig disabledDistributionConfig = cloudFrontService.updateDistributionConfig(\n testDistributionId, new String[] {}, \"Deleting distribution\", false);\n System.out.println(\"Disabled Distribution Config: \" + disabledDistributionConfig);\n\n // Check whether a distribution is deployed\n Distribution distribution = cloudFrontService.getDistributionInfo(testDistributionId);\n System.out.println(\"Distribution is deployed? \" + distribution.isDeployed());\n\n // Delete a distribution (the distribution must be disabled and deployed first)\n cloudFrontService.deleteDistribution(testDistributionId);\n */\n \n }",
"public static String getDefaultEndpoint() {\n return \"biglake.googleapis.com:443\";\n }",
"public S3Service getS3Service(VariableSpace space) throws S3ServiceException { Try to connect to S3 first\n\t\t//\n\t\tString accessKey = space.environmentSubstitute(awsAccessKey);\n\t\tString secretKey = space.environmentSubstitute(awsSecretKey);\n\t\tAWSCredentials awsCredentials = new AWSCredentials(accessKey, secretKey);\n\n\t\tS3Service s3service = new RestS3Service(awsCredentials);\n\t\treturn s3service;\n\t}",
"public static void main(String[] args) throws IOException{\n\t\tString accessToken = \"<YOUR_ACCESS_TOKEN>\";\n\t\t// The IBM Cloud organization & space to query - case sensitive.\n\t\tString org = \"<YOUR_ORG>\"; // Example: [email protected]\n\t\tString space = \"<YOUR_SPACE>\"; // Example: dev \n\n\t\t// Use TLSv1.2.\n\t\tSystem.setProperty(\"https.protocols\", \"TLSv1.2\");\n\n\t\t// Create the URL.\n\t\tURL orgsURL = new URL(apiEndpoint + \"/organizations/\" + org + \"/spaces/\" + space + \"/serviceinstances\");\n\t\tHttpURLConnection con = (HttpURLConnection) orgsURL.openConnection();\n\t\tcon.setRequestMethod(\"POST\");\n\t\tcon.setRequestProperty(\"Authorization\", \"Bearer \" + accessToken);\n\t\tcon.setRequestProperty(\"Content-Type\",\"application/json\");\n\t\tcon.setDoOutput(true);\n\n\t\t/* CREATE OPTIONS\n\t\t * Type: The plan type to create.\n\t\t * \t\t\t\t\t\t\tEnum: [\"LibertyCollective\", \"LibertyCore\", \"LibertyNDServer\", \"WASBase\", \"WASCell\", \"WASNDServer\"]\n\t\t *\n\t\t * Name: Name your new service icon in IBM Cloud.\n\t\t *\n\t\t * ApplicationServerVMSize: The size of the virtual machine.\n\t\t * \t\t\t\t\t\t\tEnum: [S, M, L, XL, XXL]\n\t\t *\n\t\t * ControlServerVMSize: The size of the Virtual Machine containing the Collective Controller for a LibertyCollective service instance,\n\t\t * \t\t\t\t\t\t\tor the size of the Virtual Machine containing the DMGR for a WASCell service instance. This is required for\n\t\t * \t\t\t\t\t\t \ttypes \"LibertyCollective\" and \"WASCell\", Illegal argument for the other Types.\n\t\t * \t\t\t\t\t\t\tEnum: [S, M, L, XL, XXL]\n\t\t *\n\t\t * NumberOfApplicationVMs: The number (integer) of application server Virtual Machines to create This is required for types \"LibertyCollective\"\n\t\t * \t\t\t\t\t\t\tand \"WASCell\", Illegal argument for the other Types.\n\t\t *\n\t\t * Software_Level: This is optional for types \"WASBase\", \"WASNDServer\", and \"WASCell\". If one is not specified version \"9.0.0\" will be default.\n\t\t * \t\t\t\t\t\t\tEnum: [\"8.5.5\", \"9.0.0\"]\n\t\t */\n\t\tString createOptionsJSON = \"{\\\"Type\\\":\\\"LibertyCore\\\",\\\"Name\\\":\\\"MyFirstAPIServiceInstance\\\",\\\"ApplicationServerVMSize\\\":\\\"S\\\"}\";\n\n\t\t// Add JSON POST data.\n\t\tDataOutputStream wr = new DataOutputStream(con.getOutputStream());\n\t\twr.writeBytes(createOptionsJSON);\n\t\twr.flush();\n\t\twr.close();\n\n\t\tBufferedReader br = null;\n\t\tif (HttpURLConnection.HTTP_OK == con.getResponseCode()) {\n\t\t\tbr = new BufferedReader(new InputStreamReader(con.getInputStream()));\n\t\t}\n\t\telse {\n\t\t\tbr = new BufferedReader(new InputStreamReader(con.getErrorStream()));\n\t\t}\n\n\t\tStringBuffer response = new StringBuffer();\n\t\tString line;\n\n\t\twhile ((line = br.readLine()) != null) {\n\t\t\tresponse.append(line);\n\t\t}\n\t\tbr.close();\n\n\t\t// Response from the request.\n\t\tSystem.out.println(response.toString());\n\n\t\t/* Example Response for creating a service instance of type \"LibertyCore\"\n\t\t * {\n\t\t * \t\"Status\":\"Active\",\n\t\t * \t\"ApplicationVMInfo\":\n\t\t * \t{\n\t\t * \t\t\"disk\":12.0,\n\t\t * \t\t\"memory\":2048,\"vcpu\":1\n\t\t * \t},\n\t\t * \t\"ServiceInstance\":\n\t\t * \t{\n\t\t * \t\t\"ServiceInstanceID\":\"8b80bac5-4e78-4a87-bb3e-0e4a8fd6d13a\",\n\t\t * \t\t\"ServiceType\":\"LibertyCore\",\n\t\t * \t\t\"SpaceID\":\"esw7jc13-b12a-47jn-9627-06jdu78d98ed\",\n\t\t * \t\t\"OrganizationID\":\"a23w6701-5324-4af8-b593-e9fdffer36a2\",\n\t\t * \t\t\"Name\":\"MyFirstAPIServiceInstance\"\n\t\t * \t}\n\t\t * }\n\t\t */\n\t}",
"public OSSUtil(String endpoint, String accessKeyId, String secretAccessKey) {\n this.accessKeyId = accessKeyId;\n this.secretAccessKey = secretAccessKey;\n this.endpoint = endpoint;\n initClient(endpoint, accessKeyId, secretAccessKey);\n }",
"@SuppressWarnings(\"unused\")\n @PostConstruct\n private void initializeAmazon() {\n AWSCredentials credentials = new BasicAWSCredentials(negaBucketAccessKey, negaBucketSecretKey);\n this.s3client =\n AmazonS3ClientBuilder.standard()\n .withCredentials(new AWSStaticCredentialsProvider(credentials))\n .withRegion(Regions.US_EAST_1)\n .build();\n }",
"@RequestMapping(value = \"/{serviceName}\", method = RequestMethod.GET)\n ResponseEntity<Object> getServiceDocker(@PathVariable(\"serviceName\") String serviceName,\n HttpServletRequest request) throws Exception {\n HttpHeaders headers = new HttpHeaders();\n headers.set(\"X-Forwarded-Host\", String.format(\"%s:%d\", request.getServerName(), request.getServerPort()));\n if (StringUtils.isNotEmpty(contextPath) && ! \"/\".equals(contextPath)) {\n headers.set(\"X-Forwarded-Prefix\", contextPath);\n }\n HttpEntity entity = new HttpEntity(headers);\n\n String serviceNameKey = String.format(\"gateway.services.%s\", serviceName);\n String url = environment.getProperty(serviceNameKey) + docketUri;\n ResponseEntity<String> response = restTemplate.exchange(url, HttpMethod.GET, entity, String.class);\n return new ResponseEntity<>(response.getBody(), HttpStatus.OK);\n }",
"Fog_Services createFog_Services();",
"@FeignClient(name = \"gallery-service\", url = \"http://localhost:8081/\", fallback = StatisticFallbackFactory.class)\npublic interface ServiceFeignClient {\n\n\n // Request. contain way that identical in gallery-service (same signature)\n @RequestLine(\"GET /show\")\n List<Bucket> getAllEmployeesList();\n\n}",
"@Host(\"{endpoint}\")\n @ServiceInterface(name = \"SearchServiceRestClient\")\n private interface SearchServiceRestClientService {\n @Get(\"servicestats\")\n @ExpectedResponses({200})\n @UnexpectedResponseExceptionType(SearchErrorException.class)\n Mono<SimpleResponse<ServiceStatistics>> getServiceStatistics(@HostParam(\"endpoint\") String endpoint, @QueryParam(\"api-version\") String apiVersion, @HeaderParam(\"x-ms-client-request-id\") UUID xMsClientRequestId, Context context);\n }",
"public interface AWSClient {\n\n public void putFileinS3(Exchange exchange) throws Exception;\n\n public void putMessageInSQS(Exchange exchange) throws Exception;\n}",
"@HystrixCommand(fallbackMethod = \"addServiceFallback\")\n\tpublic String addService() {\n\t\treturn restTemplate.getForEntity(\"http://COMPUTE-SERVICE/add?a=10&b=20\", String.class).getBody();\n\t}",
"@Override\r\n\t public String getFunctionName() {\r\n\t return \"ExampleAwsLambda\";\r\n\t }",
"@Bean\n public AmazonS3 amazonS3Client()\n {\n return new AmazonS3Client(new DefaultAWSCredentialsProviderChain());\n }",
"public static void main(String[] args) throws Exception {\n\t\t \n\t\t GoogleCredentials credentials = GoogleCredentials.fromStream(new FileInputStream(\"/home/sahana/Downloads/access.json\"));\n\t\t \n\t\t Storage storage = StorageOptions.newBuilder().setCredentials(credentials).build().getService();\n\t\t \n\t\t System.out.println(storage);\n\n\t\t // The name for the new bucket\n\t\t String bucketName = \"sahana\"; // \"my-new-bucket\";\n\t\t \n\t\t // Creates the new bucket\n\t\t Bucket bucket = storage.create(BucketInfo.of(bucketName));\n\n\t\t System.out.printf(\"Bucket %s created.%n\", bucket.getName()); \n\t\t \n\t\t //Bucket bucket = storage.create(BucketInfo.newBuilder(bucketName).setStorageClass(StorageClass.MULTI_REGIONAL).setLocation(\"asia\").build()); \n\t\t /*String bucketName = \"my_unique_bucket\";\n\t\t String blobName = \"my_blob_name\";\n\t\t BlobId blobId = BlobId.of(bucketName, blobName);\n\t\t BlobInfo blobInfo = BlobInfo.newBuilder(blobId).setContentType(\"text/plain\").build();\n\t\t Blob blob = storage.create(blobInfo);\n\t\t \n\t\t System.out.println(blob); */\n\t\t }",
"String getServiceUrl();",
"@FeignClient(name = \"product-server\",path = \"/product\")\n@Component\npublic interface ProductService {\n @RequestMapping(value = \"getProduct\")\n String getProduct();\n}",
"URI fetchUri(ServiceAlias serviceAlias);",
"@FeignClient(value = \"EUREKA-CLIENT-01\")\npublic interface HelloService {\n @RequestMapping(value = \"/hello\",method = RequestMethod.GET)\n String hello(@RequestParam(value = \"name\") String name);\n}",
"@Override\n public void onComplete(AWSStartupResult awsStartupResult) {\n }",
"@Override\n public void onComplete(AWSStartupResult awsStartupResult) {\n }",
"public static void main(String args[]) {\n\t\tfinal Region region = Region.of(\"us-east-1\");\n\t\tString s3Bucket = \"ab2d-optout-data-dev\";\n\t\tString s3Filename = \"T#EFT.ON.ACO.NGD1800.DPRF.D191029.T1135430\";\n\n\t\t// Get s3 client for EC2 instance (if applicable)\n\t\tS3Client s3Client = getS3ClientForEc2Instance();\n\t\tif (s3Client == null) {\n\t\t\t// Get s3 client for development\n\t\t\ts3Client = getS3ClientForDevelopment(region);\n\t\t}\n\n\t\t// build GetObjectRequest\n\t\tfinal GetObjectRequest getObjectRequest = GetObjectRequest.builder()\n\t\t\t\t.bucket(s3Bucket)\n\t\t\t\t.key(s3Filename)\n\t\t\t\t.build();\n\n\t\ttry (final ResponseInputStream<GetObjectResponse> responseInputStream = s3Client.getObject(getObjectRequest)) {\n\t\t} catch (IOException e) {\n\t\t\tlog.error(\"Unable to get s3 object on AWS : \", e);\n\t\t} catch (SdkServiceException e) {\n\t\t\tlog.error(\"Server error upon calling AWS : \", e);\n\t\t\tthrow e;\n\t\t} catch (SdkClientException e) {\n\t\t\tlog.error(\"Client exception on attempting to call AWS : \", e);\n\t\t\tthrow e;\n\t\t}\n\t}",
"go.micro.runtime.RuntimeOuterClass.Service getService();",
"go.micro.runtime.RuntimeOuterClass.Service getService();",
"go.micro.runtime.RuntimeOuterClass.Service getService();",
"private void go(String[] args) {\n System.setProperty(\"jsse.enableSNIExtension\", \"false\");\n\n // process command line arguments\n options = new SampleCommandLineOptions();\n options.parseOptions(args);\n\n // Log in to vCHS API, getting a session in response if login is successful\n System.out.print(\"\\nConnecting to vCHS...\");\n\n authToken = IAM.login(options.hostname, options.username, options.password, options.version);\n\n System.out.println(\"Success\\n\");\n\n // Retrieve the collection of compute services which can be of type dedicated cloud or vpc\n // and has VDC in it.\n List<PlanType> plans = ServiceController.getPlans(options.hostname, options.version,\n authToken);\n if (null != plans && plans.size() > 0) {\n System.out.println(\"PLANS\");\n System.out.println(\"-----\");\n System.out.println();\n\n System.out.printf(\"%-40s %-40s %-50s %-30s %-20s\\n\", \"Name\", \"Id\", \"Region\",\n \"Service Name\", \"Plan Version\");\n System.out.printf(\"%-40s %-40s %-50s %-30s %-20s\\n\",\n \"----------------------------------------\",\n \"----------------------------------------\",\n \"--------------------------------------------------\",\n \"------------------------------\", \"-------------------\");\n\n for (PlanType plan : plans) {\n System.out.printf(\"%-40s %-40s %-50s %-30s %-20s\\n\", plan.getName(), plan.getId(),\n plan.getRegion(), plan.getServiceName(), plan.getPlanVersion());\n }\n }\n\n List<InstanceType> instances = ServiceController.getInstances(options.hostname,\n options.version, authToken);\n System.out.println(\"\\n\");\n\n if (null != instances && instances.size() > 0) {\n System.out.println(\"INSTANCES\");\n System.out.println(\"---------\");\n System.out.println();\n\n System.out.printf(\"%-40s %-40s %-50s %-50s\\n\", \"Name\", \"Id\", \"Region\", \"Plan Id\");\n System.out.printf(\"%-40s %-40s %-50s %-50s\\n\",\n \"----------------------------------------\",\n \"----------------------------------------\",\n \"--------------------------------------------------\",\n \"--------------------------------------------------\");\n\n for (InstanceType instance : instances) {\n System.out.printf(\"%-40s %-40s %-50s %-50s\\n\", instance.getName(),\n instance.getId(), instance.getRegion(), instance.getPlanId());\n }\n }\n\n System.out.println(\"\\n\\n\");\n }",
"Object getService(String serviceName);",
"@FeignClient(value = \"eureka-client\", fallback = ServiceHelloHystrix.class)\npublic interface ServiceHello {\n\n @RequestMapping(value = \"/hello\", method = RequestMethod.GET)\n public String sayHello(@RequestParam(value = \"name\") String name);\n}",
"private void doRefreshConnection()\r\n\t{\r\n\t\t/* Refresh the connection to S3. */\r\n\t\ttry\r\n\t\t{\r\n\t\t\tservice = new RestS3Service(new AWSCredentials(accessKey, secretKey));\r\n\t\t}\r\n\t\tcatch (S3ServiceException e)\r\n\t\t{\r\n\t\t\te.printStackTrace();\r\n\t\t}\r\n\t}",
"void setEndpoint(String endpoint);",
"@WebMethod\n URI exposeEndpoint(Endpoint endpoint);",
"@FeignClient(value = \"BINGO-CMDB\")\r\npublic interface FeignService {\r\n\r\n @RequestMapping(value = \"/api/hello\",method = RequestMethod.GET)\r\n String sayHello();\r\n}",
"public interface DQEService {\n\n @GET(\"/SINGLEV2\")\n Map<String, DQEResult> getAddress(@QueryMap Map<String, String> params);\n\n}",
"java.lang.String getS3();",
"private static final URL getURL(String url) throws ResourceManagerServiceClientCreationException {\r\n ArgumentChecker.checkNullOrEmpty(url, \"WSDL URL\");\r\n\r\n try {\r\n return new URL(url);\r\n } catch (MalformedURLException e) {\r\n throw new ResourceManagerServiceClientCreationException(\"Error while creating URL.\", e);\r\n }\r\n }",
"protected abstract String getBaseEndpoint();",
"public AmazonCloudSearchClient() {\n this(new DefaultAWSCredentialsProviderChain(), new ClientConfiguration());\n }",
"@FeignClient(value = \"jec-service-job\")\npublic interface IIndexApi {\n\n @RequestMapping(value = \"/\", method = RequestMethod.GET)\n RetObject index();\n\n}",
"public AWSStorageGatewayClient() {\n this(new DefaultAWSCredentialsProviderChain(), new ClientConfiguration());\n }",
"public Object getService(String serviceName);",
"public static void main(String... s) throws IOException, InterruptedException {\n\n // If needed, the keystore and truststore should be set by virtual machine arguments:\n // -Djavax.net.ssl.trustStore=\"<file location of your truststore>\"\n // -Djavax.net.ssl.trustStorePassword=\"<not needed if password is 'changeit'>\"\n // -Djavax.net.ssl.keyStore=\"<file location of your keystore>\"\n // -Djavax.net.ssl.keyStorePassword=\"<not needed if password is 'changeit'\"\n //\n //ClassLoader cloader = EncryptedRemotePublishingServiceClient.class.getClassLoader();\n //ClassPathResource trustore = new ClassPathResource(\"sgf/gateway/applications/keystores/keystore-esg-cet.ucar.edu\", cloader);\n //System.setProperty(\"javax.net.ssl.trustStore\", trustore.getFile().getAbsolutePath());\n //System.setProperty(\"javax.net.ssl.trustStorePassword\", \"changeit\");\n\n ApplicationContext ctxt = new ClassPathXmlApplicationContext(\"classpath:sgf.gateway/main/hessian/client/release/client-release.xml\");\n RemotePublishingService remotePublishingService = (RemotePublishingService) ctxt.getBean(\"encryptedRemotePublishingServiceProxy\");\n\n EncryptedRemotePublishingServiceClient self = new EncryptedRemotePublishingServiceClient(remotePublishingService);\n self.createDataset();\n }",
"@Timeout(duration = 30, timeUnit = TimeUnit.SECONDS)\npublic interface CloudWatchApi {\n /**\n * \n * @return the Region codes configured\n */\n @Provides\n @Region\n Set<String> getConfiguredRegions();\n \n /**\n * This call returns data for one or more statistics of given a metric. For more information, see\n * Statistic and Metric.\n *\n * <p/>\n * <h3>Note</h3> The maximum number of datapoints that the Amazon CloudWatch service will return\n * in a single GetMetricStatistics request is 1,440. If a request is made that would generate\n * more datapoints than this amount, Amazon CloudWatch will return an error. You can alter your\n * request by narrowing the time range (StartTime, EndTime) or increasing the Period in your\n * single request. You may also get all of the data at the granularity you originally asked for\n * by making multiple requests with adjacent time ranges.\n * \n * @param region\n * region to gather metrics in\n * @param metricName\n * The measure name that corresponds to the measure for the gathered metric.\n * <p/>\n * note\n * <p/>\n * Must be a valid collected metric with the corresponding measure name, please see\n * Available Amazon CloudWatch Metrics\n * @param namespace\n * The namespace of the metric (e.g. AWS/EC2)\n * @param startTime\n * The timestamp of the first datapoint to return, inclusive. We round your value down\n * to the nearest minute. You can set your start time for more than two weeks in the\n * past. However, you will only get data for the past two weeks.\n * @param endTime\n * The timestamp to use for determining the last datapoint to return. This is the last\n * datapoint to fetch, exclusive.\n * @param period\n * The granularity (in seconds) of the returned datapoints.\n * @param statistics\n * The statistics to be returned for the given metric. ex. Average\n * @param options\n * more filtering options (e.g. instance ID)\n * @see MetricApi#getMetricStatistics(org.jclouds.cloudwatch.domain.GetMetricStatistics)\n */\n @Deprecated\n Set<Datapoint> getMetricStatisticsInRegion(@Nullable String region, String metricName, String namespace,\n Date startTime, Date endTime, int period, Statistics statistics, GetMetricStatisticsOptions... options);\n \n /**\n * Provides synchronous access to Metric features.\n */\n @Delegate\n MetricApi getMetricApi();\n \n /**\n * Provides synchronous access to Metric features.\n */\n @Delegate\n MetricApi getMetricApiForRegion(@EndpointParam(parser = RegionToEndpointOrProviderIfNull.class) @Nullable String region);\n}",
"public interface SHC4JServiceProvider {\n\n SyncHttpClientBuilder getHttpClientBuilder();\n\n AsyncHttpClientBuilder getHttpAsyncClientBuilder();\n\n default void initialize() {\n }\n}",
"public String GetJWKS(String stsDiscoveryEndpoint, String jwksUrlKey) {\n HttpClient client = new HttpClient();\n String res = \"\";\n String jwks_uri = \"\";\n GetMethod getMethod = new GetMethod(stsDiscoveryEndpoint);\n try {\n int code = client.executeMethod(getMethod);\n if (code == 200) {\n res = getMethod.getResponseBodyAsString();\n System.out.println(res);\n }\n } catch (IOException e) {\n e.printStackTrace();\n }\n if (StringUtils.isNotEmpty(res)) {\n JSONObject jsonObject = JSONObject.parseObject(res);\n jwks_uri = String.valueOf(jsonObject.get(jwksUrlKey));\n }\n return jwks_uri;\n }",
"@XRayEnabled\npublic interface UploadFileService {\n \n /**\n * copyFileToS3 : copyFileToS3\n * \n * @param fileName : file name\n * @param fileExtension : file extension\n * @param content : content\n * @return String : url file\n */\n public String copyFileToS3(String fileName, String fileExtension, String content);\n\n /**\n * uploadFileToS3 : Upload file to S3 Amz Cloud\n * \n * @param part\n * @param importBelong\n * @return\n * @throws IOException\n */\n S3UploadResponse uploadFileToS3(MultipartFile part, Integer importBelong) throws IOException;\n}",
"public AWSLambdaClient() {\n this(new DefaultAWSCredentialsProviderChain(), new ClientConfiguration());\n }",
"public String getSearchEndpoint();",
"@FeignClient(value = \"HELLO-SERVICE\")\npublic interface RefactorHelloService extends online.wangxuan.helloserviceapi.service.HelloService {\n}",
"public interface ConsumeServiceConfiguration {\n\n /**\n * @return the interfaces of all services that should be consumed\n */\n Set<Class<?>> getServiceInterfaces();\n\n /**\n * Returns the full URL of the server so that the service name only has to be appended to hit the required endpoint.\n * Must not end with a slash.\n */\n String getServerUrl();\n}",
"public static String getServiceURL(KubernetesClient client, String serviceName, String serviceNamespace, String serviceProtocol, boolean serviceExternal) {\n Service srv = null;\n String serviceHost = serviceToHostOrBlank(serviceName);\n String servicePort = serviceToPortOrBlank(serviceName);\n String serviceProto = serviceProtocol != null ? serviceProtocol : serviceToProtocol(serviceName, servicePort);\n\n //Use specified or fallback namespace.\n String actualNamespace = StringUtils.isNotBlank(serviceNamespace) ? serviceNamespace : client.getNamespace();\n\n //1. Inside Kubernetes: Services as ENV vars\n if (!serviceExternal && StringUtils.isNotBlank(serviceHost) && StringUtils.isNotBlank(servicePort) && StringUtils.isNotBlank(serviceProtocol)) {\n return serviceProtocol + \"://\" + serviceHost + \":\" + servicePort;\n //2. Anywhere: When namespace is passed System / Env var. Mostly needed for integration tests.\n } else if (StringUtils.isNotBlank(actualNamespace)) {\n srv = client.services().inNamespace(actualNamespace).withName(serviceName).get();\n }\n\n if (srv == null) {\n // lets try use environment variables\n String hostAndPort = getServiceHostAndPort(serviceName, \"\", \"\");\n if (!hostAndPort.startsWith(\":\")) {\n return serviceProto + \"://\" + hostAndPort;\n }\n }\n if (srv == null) {\n throw new IllegalArgumentException(\"No kubernetes service could be found for name: \" + serviceName + \" in namespace: \" + actualNamespace);\n }\n\n String answer = KubernetesHelper.getOrCreateAnnotations(srv).get(Fabric8Annotations.SERVICE_EXPOSE_URL.toString());\n if (StringUtils.isNotBlank(answer)) {\n return answer;\n }\n\n if (OpenshiftHelper.isOpenShift(client)) {\n OpenShiftClient openShiftClient = client.adapt(OpenShiftClient.class);\n Route route = openShiftClient.routes().inNamespace(actualNamespace).withName(serviceName).get();\n if (route != null) {\n return (serviceProto + \"://\" + route.getSpec().getHost()).toLowerCase();\n }\n }\n\n ServicePort port = findServicePortByName(srv, null);\n if (port == null) {\n throw new RuntimeException(\"Couldn't find port: \" + null + \" for service:\" + serviceName);\n }\n\n String clusterIP = srv.getSpec().getClusterIP();\n if (\"None\".equals(clusterIP)) {\n throw new IllegalStateException(\"Service: \" + serviceName + \" in namespace:\" + serviceNamespace + \"is head-less. Search for endpoints instead.\");\n }\n\n Integer portNumber = port.getPort();\n if (StringUtils.isBlank(clusterIP)) {\n IngressList ingresses = client.extensions().ingresses().inNamespace(serviceNamespace).list();\n if (ingresses != null) {\n List<Ingress> items = ingresses.getItems();\n if (items != null) {\n for (Ingress item : items) {\n String ns = KubernetesHelper.getNamespace(item);\n if (Objects.equal(serviceNamespace, ns)) {\n IngressSpec spec = item.getSpec();\n if (spec != null) {\n List<IngressRule> rules = spec.getRules();\n List<IngressTLS> tls = spec.getTls();\n if (rules != null) {\n for (IngressRule rule : rules) {\n HTTPIngressRuleValue http = rule.getHttp();\n if (http != null) {\n List<HTTPIngressPath> paths = http.getPaths();\n if (paths != null) {\n for (HTTPIngressPath path : paths) {\n IngressBackend backend = path.getBackend();\n if (backend != null) {\n String backendServiceName = backend.getServiceName();\n if (serviceName.equals(backendServiceName) && portsMatch(port, backend.getServicePort())) {\n String pathPostfix = path.getPath();\n if (tls != null) {\n for (IngressTLS tlsHost : tls) {\n List<String> hosts = tlsHost.getHosts();\n if (hosts != null) {\n for (String host : hosts) {\n if (StringUtils.isNotBlank(host)) {\n return String.format(\"https://%s/%s\", host, preparePath(pathPostfix));\n }\n }\n }\n }\n }\n answer = rule.getHost();\n if (StringUtils.isNotBlank(answer)) {\n return String.format(\"http://%s/%s\",answer, preparePath(pathPostfix));\n }\n }\n }\n }\n }\n }\n }\n }\n }\n }\n }\n }\n }\n\n // lets try use the status on GKE\n ServiceStatus status = srv.getStatus();\n if (status != null) {\n LoadBalancerStatus loadBalancerStatus = status.getLoadBalancer();\n if (loadBalancerStatus != null) {\n List<LoadBalancerIngress> loadBalancerIngresses = loadBalancerStatus.getIngress();\n if (loadBalancerIngresses != null) {\n for (LoadBalancerIngress loadBalancerIngress : loadBalancerIngresses) {\n String ip = loadBalancerIngress.getIp();\n if (StringUtils.isNotBlank(ip)) {\n clusterIP = ip;\n break;\n }\n }\n }\n }\n }\n }\n\n if (StringUtils.isBlank(clusterIP)) {\n // on vanilla kubernetes we can use nodePort to access things externally\n boolean found = false;\n Integer nodePort = port.getNodePort();\n if (nodePort != null) {\n NodeList nodeList = client.nodes().list();\n if (nodeList != null) {\n List<Node> items = nodeList.getItems();\n if (items != null) {\n for (Node item : items) {\n NodeStatus status = item.getStatus();\n if (!found && status != null) {\n List<NodeAddress> addresses = status.getAddresses();\n if (addresses != null) {\n for (NodeAddress address : addresses) {\n String ip = address.getAddress();\n if (StringUtils.isNotBlank(ip)) {\n clusterIP = ip;\n portNumber = nodePort;\n found = true;\n break;\n }\n\n }\n\n }\n }\n if (!found) {\n NodeSpec spec = item.getSpec();\n if (spec != null) {\n clusterIP = spec.getExternalID();\n if (StringUtils.isNotBlank(clusterIP)) {\n portNumber = nodePort;\n break;\n }\n }\n }\n }\n }\n }\n }\n }\n return (serviceProto + \"://\" + clusterIP + \":\" + portNumber).toLowerCase();\n }",
"@Override\n public String getServiceEndpoint(String serviceName) {\n return serviceEndpoints.get(serviceName);\n }",
"private String getServiceEndpointAddress() {\n try {\n Config config = Config.getInstance();\n return config.getHost();\n } catch (IOException e) {\n throw new IllegalArgumentException(\"Service url is wrong.\");\n }\n }",
"private static void invokeDemoS3EventLambda() throws IOException\r\n\t{\r\n\t\t// invoke the lambda\r\n\t\tDemoS3EventLambda lambda = new DemoS3EventLambda();\r\n\t\tlambda.handleRequest(new S3Event(null), new ClientTestContext());\r\n\t}",
"public String getBucketName(){\n return bucketName;\n }",
"public String getBucket();",
"@FeignClient(name = \"demo-service1\"\n// , fallback= DemoService1Fallback.class\n ,fallbackFactory=DemoService1FallBackFactory.class\n)\npublic interface DemoService1Client {\n\n @GetMapping(value = \"/test/test1\")\n String test1();\n}",
"Map<String, String> getEndpointMap();",
"void configureEndpoint(Endpoint endpoint);",
"@Host(\"{endpoint}\")\n @ServiceInterface(name = \"FarmBeatsClientImage\")\n public interface ImageProcessingsService {\n @Put(\"/image-processing/rasterize/{jobId}\")\n @ExpectedResponses({202})\n @UnexpectedResponseExceptionType(\n value = ClientAuthenticationException.class,\n code = {401})\n @UnexpectedResponseExceptionType(\n value = ResourceNotFoundException.class,\n code = {404})\n @UnexpectedResponseExceptionType(\n value = ResourceModifiedException.class,\n code = {409})\n @UnexpectedResponseExceptionType(HttpResponseException.class)\n Mono<Response<BinaryData>> createRasterizeJob(\n @HostParam(\"endpoint\") String endpoint,\n @PathParam(\"jobId\") String jobId,\n @QueryParam(\"api-version\") String apiVersion,\n @BodyParam(\"application/json\") BinaryData job,\n @HeaderParam(\"Accept\") String accept,\n RequestOptions requestOptions,\n Context context);\n\n @Get(\"/image-processing/rasterize/{jobId}\")\n @ExpectedResponses({200})\n @UnexpectedResponseExceptionType(\n value = ClientAuthenticationException.class,\n code = {401})\n @UnexpectedResponseExceptionType(\n value = ResourceNotFoundException.class,\n code = {404})\n @UnexpectedResponseExceptionType(\n value = ResourceModifiedException.class,\n code = {409})\n @UnexpectedResponseExceptionType(HttpResponseException.class)\n Mono<Response<BinaryData>> getRasterizeJob(\n @HostParam(\"endpoint\") String endpoint,\n @PathParam(\"jobId\") String jobId,\n @QueryParam(\"api-version\") String apiVersion,\n @HeaderParam(\"Accept\") String accept,\n RequestOptions requestOptions,\n Context context);\n }",
"public String greeting() {\n ServiceInstance serviceInstance = loadBalancerClient.choose(EUREKA_AWARE_CLIENT_SERVICE_ID);\n LOGGER.info(\"Service instance picked up by load balancer: \");\n printServiceInstance(serviceInstance);\n String result = restTemplate.exchange(serviceInstance.getUri() + \"/greeting\", HttpMethod.GET, null, String.class).getBody();\n\n LOGGER.info(\"Service returns: \" + result);\n return result;\n }",
"@Path(\"/providers/Microsoft.Compute/locations/{location}\")\n@RequestFilters({ OAuthFilter.class, ApiVersionFilter.class })\n@Consumes(APPLICATION_JSON)\npublic interface OSImageApi {\n\n /**\n * List Publishers in location\n */\n @Named(\"publisher:list\")\n @GET\n @Path(\"/publishers\")\n @Fallback(EmptyListOnNotFoundOr404.class)\n List<Publisher> listPublishers();\n\n /**\n * List Offers in publisher\n */\n @Named(\"offer:list\")\n @GET\n @Path(\"/publishers/{publisher}/artifacttypes/vmimage/offers\")\n @Fallback(EmptyListOnNotFoundOr404.class)\n List<Offer> listOffers(@PathParam(\"publisher\") String publisher);\n\n /**\n * List SKUs in offer\n */\n @Named(\"sku:list\")\n @GET\n @Path(\"/publishers/{publisher}/artifacttypes/vmimage/offers/{offer}/skus\")\n @Fallback(EmptyListOnNotFoundOr404.class)\n List<SKU> listSKUs(@PathParam(\"publisher\") String publisher, @PathParam(\"offer\") String offer);\n\n /**\n * List Versions in SKU\n */\n @Named(\"version:list\")\n @GET\n @Path(\"/publishers/{publisher}/artifacttypes/vmimage/offers/{offer}/skus/{sku}/versions\")\n @Fallback(EmptyListOnNotFoundOr404.class)\n List<Version> listVersions(@PathParam(\"publisher\") String publisher, @PathParam(\"offer\") String offer,\n @PathParam(\"sku\") String sku);\n \n /**\n * Get the details of a Version\n */\n @Named(\"version:get\")\n @GET\n @Path(\"/publishers/{publisher}/artifacttypes/vmimage/offers/{offer}/skus/{sku}/versions/{version}\")\n @Fallback(EmptyListOnNotFoundOr404.class)\n Version getVersion(@PathParam(\"publisher\") String publisher, @PathParam(\"offer\") String offer,\n @PathParam(\"sku\") String sku, @PathParam(\"version\") String version);\n\n}",
"java.lang.String getService();",
"java.lang.String getService();",
"java.lang.String getService();",
"public interface GradesService {\n\n @GET(\"gradebook/my.json\")\n Single<GradesResponse> getAllGrades();\n\n @GET(\"gradebook/site/{site_id}.json\")\n Single<GradeCollection> getGradeForSite(@Path(value = \"site_id\", encoded = true) String siteId);\n\n}",
"@Override\n\tprotected void initializeRegionAndEndpoint(ProcessContext context) {\n\t}",
"EndpointBalancerConfig getConfig();",
"public String getEndpoint() {\n return this.endpoint;\n }",
"public String getEndpoint() {\n return this.endpoint;\n }",
"public String getHttpsEndpoint() {\n\t\treturn \"https://\" + getMyHostname() + \":\" + httpsPort;\n\t}",
"@Override\r\n\tpublic void initializeService(String input) throws Exception\r\n\t{\n\t\t\r\n\t}",
"protected static void setServiceLocation(URI serviceLocation) {\n Program.serviceLocation = serviceLocation;\n }",
"SourceBuilder createRestServiceLayers();",
"String getStaticWebEndpoint();",
"@FeignClient(\"greetings-service\")\ninterface GreetingsClient {\n\n\t@RequestMapping(method = RequestMethod.GET, value = \"/greetings/{name}\")\n\tGreeting greet(@PathVariable(\"name\") String name);\n}",
"@Test\n public void bucketBasics() throws Exception {\n testInfo(this.getClass().getSimpleName() + \" - bucketBasics\");\n\n try {\n print(account + \": Listing all buckets\");\n List<Bucket> bucketList = s3.listBuckets();\n assertTrue(\"Invalid or empty bucket list\", bucketList != null && !bucketList.isEmpty());\n boolean found = false;\n for (Bucket buck : bucketList) {\n if (buck.getName().equals(bucketName)) {\n found = true;\n break;\n }\n }\n assertTrue(\"Expected newly created bucket to be listed in the buckets but did not\", found);\n\n print(account + \": Checking if the bucket \" + bucketName + \" exists\");\n assertTrue(\"Expected to find \" + bucketName + \", but the bucket was not found\", s3.doesBucketExist(bucketName));\n\n print(account + \": Fetching bucket location for \" + bucketName);\n String location = s3.getBucketLocation(bucketName);\n assertTrue(\"Invalid result for bucket location, expected a string\", location != null && !location.isEmpty());\n\n print(account + \": Fetching bucket logging configuration for \" + bucketName);\n BucketLoggingConfiguration loggingConfig = s3.getBucketLoggingConfiguration(bucketName);\n assertTrue(\"Invalid result for bucket logging configuration\", loggingConfig != null);\n assertTrue(\"Expected bucket logging to be disabled, but got enabled\", !loggingConfig.isLoggingEnabled());\n assertTrue(\"Expected destination bucket to be null, but got \" + loggingConfig.getDestinationBucketName(),\n loggingConfig.getDestinationBucketName() == null);\n assertTrue(\"Expected log file prefix to be null, but got \" + loggingConfig.getLogFilePrefix(), loggingConfig.getLogFilePrefix() == null);\n\n print(account + \": Fetching bucket versioning configuration for \" + bucketName);\n BucketVersioningConfiguration versioning = s3.getBucketVersioningConfiguration(bucketName);\n assertTrue(\"Invalid result for bucket versioning configuration\", versioning != null);\n assertTrue(\"Expected bucket versioning configuration to be OFF, but found it to be \" + versioning.getStatus(),\n versioning.getStatus().equals(BucketVersioningConfiguration.OFF));\n } catch (AmazonServiceException ase) {\n printException(ase);\n assertThat(false, \"Failed to run bucketBasics\");\n }\n }",
"@FeignClient(\"customer-service\")\npublic interface CustomerClient {\n}",
"public interface IDevopsIngressService {\n\n void createIngress(String ingressYaml, String name, String namespace);\n\n void deleteIngress(String name, String namespace);\n}",
"@Test\n public void testService()\n {\n final JsonSchemaValidator jsonValidator =\n JsonSchemaValidator.matchesJsonSchemaInClasspath(\"costcenters-schema.json\");\n\n // HTTP GET response OK, JSON header and valid schema\n given().get(\"/costcenters\").then().assertThat().statusCode(200).contentType(ContentType.JSON).body(\n jsonValidator);\n }",
"public AWSStorageGatewayClient(AWSCredentials awsCredentials) {\n this(awsCredentials, new ClientConfiguration());\n }",
"public String getServiceUrl() {\n return \"http://\" + this.serviceHost + \":\" + this.servicePort;\n }",
"public AmazonSigningService(String region, AmazonCredentials credentials, Function<String, Certificate[]> certificateStore) {\n this.certificateStore = certificateStore;\n this.client = new RESTClient(\"https://kms.\" + region + \".amazonaws.com\", (conn, data) -> sign(conn, credentials, data, null));\n }",
"@Override\n public void registerEndpoints (Service sparkService) {\n sparkService.get(\"/api/bundles/:bundle/workerProxy/:workerVersion\", this::proxyGet);\n }",
"com.google.container.v1.HttpLoadBalancing getHttpLoadBalancing();",
"public static void main(String[] args) throws IOException {\n OSS client = new OSSClientBuilder().build(endpoint, accessKeyId, accessKeySecret);\n\n\n// String objectName = \"community/c14deaec-7827-4fb1-bac9-eeba7a5ba59b.png\";\n//\n//// 创建OSSClient实例。\n// OSSClient ossClient = new OSSClient(endpoint, accessKeyId, accessKeySecret);\n//\n//// 删除文件。\n// ossClient.deleteObject(bucketName, objectName);\n//\n//// 关闭OSSClient。\n// ossClient.shutdown();\n\n try {\n /*\n * Batch put objects into the bucket\n */\n final String content = \"Thank you for using Aliyun Object Storage Service\";\n final String keyPrefix = \"MyObjectKey\";\n String objects = \"community/01378488-592b-443c-984f-4cbc12c8cd82.png\" +\n \",community/01394c05-3bc8-41ee-b47f-2caddfbf27f2.png\" +\n \",community/0139e96b-97a7-4270-9bad-3cc25c335184_1080x1430.png\" +\n \",community/013a938c-6486-4abb-bf96-aa5d066472cc.png\" +\n \",community/013b2de1-ef57-4204-92f8-9a2fdf1ab1c0.png\" +\n \",community/013cd7e5-ab1f-4058-a2b6-4e33c283c9b3.png\" +\n \",community/01426305-b2ef-430c-9cfe-8daf4e382b72.png\" +\n \",community/01426539-5fda-44b1-8aca-eb2c744b67ee_1080x1923.png\" +\n \",community/014c400c-e516-4c9e-adf8-a26b63729db5.png\" +\n \",community/014d3126-4b61-499e-b2a4-060d5c565ee3.png\" +\n \",community/014d4e83-9c56-4470-ae54-57387896139b.png\" +\n \",community/02038488-3867-475f-9c05-6e552ca4da70_1080x1439.png\" +\n \",community/0205bd60-49bf-412f-b04a-6c8c00b19f6c.png\" +\n \",community/02084b3b-7acb-4be0-a40c-a1245e805c85_1080x1448.png\" +\n \",community/02099953-c48c-4f22-ab5c-87449d449502_348x464.png\" +\n \",community/020d48bd-9745-4087-8ab5-7298f57a1f30_1080x1563.png\" +\n \",community/0212046c-3167-42a9-850c-788eed176526.png\" +\n \",community/0213caf3-0866-426e-8fea-797c8d533451.png\" +\n \",community/021480ff-4dcd-4b56-95e3-46a094baa742.png\" +\n \",community/01f015d8-1358-48da-bb37-07e270a27667.png\" +\n \",community/01f0a3ca-f0fa-41e5-8126-e0c5e4346d8e.png\" +\n \",community/01f0ed1c-9472-4002-b896-216c95dc214b_720x950.png\" +\n \",community/01f143c2-f8ba-4ee3-8fec-de9b0c106fd2.png\" +\n \",community/01f15f7d-6bee-41e1-9bc9-85409087f5bf.png\" +\n \",community/01f1742c-20b6-4f85-9847-2a4d85801165.png\" +\n \",community/01f32f3f-b0ce-4d9d-aef8-a75be07b655a.png\" +\n \",community/01f42d98-1994-4e3f-b025-d94a849a33a8.png\" +\n \",community/01f7c1e4-5b80-400d-8dd7-0df9a1c88601.png\" +\n \",community/01f8cd29-f527-43c6-a438-d3751663ec37.png\" +\n \",community/01fa914a-66cc-471e-af15-2bd10d34a45e_348x464.png\" +\n \",community/01fad182-2290-4b47-ab3c-ee10dff2fb86.png\" +\n \",community/0201c344-c893-4da6-a564-b4ef70ae38d6_1080x1749.png\" +\n \",community/01d7e8e6-0336-4d18-ae98-2cd2f407c46f.png\" +\n \",community/01d7ecfb-9feb-4db6-8d55-4c87cb050b4d.png\" +\n \",community/01d86f24-8589-4e60-b797-6b4b2f4330b5.png\" +\n \",community/01d96558-4bb2-4763-a7c4-ca2910f73ab1.png\" +\n \",community/01d9f15d-3555-4831-bc18-95cbe4634873_1440x2019.png\" +\n \",community/01daaccc-a3b5-4ef9-a5ce-57dfa803006b_315x420.png\" +\n \",community/01dbcbb8-dd5e-4911-8094-467ae90cf414.png\" +\n \",community/01de101b-e7f0-4d44-8a0c-6b6eb8e86e21.png\" +\n \",community/01e82423-a17b-439b-a804-5e6f898906b2.png\" +\n \",community/01be382c-4447-416c-8905-449a5d2f66a8.png\" +\n \",community/01bfb933-afd3-4529-944d-2e432731b6f8.png\" +\n \",community/01c07f89-8fab-481b-a497-ff5ea1013f5c_1080x1922.png\" +\n \",community/01c965cb-d991-4424-bdec-89634240dd51.png\" +\n \",community/01ca2e7c-f4be-40d7-a05a-7e20a02c14ac.png\" +\n \",community/01ca99ef-c34e-4a8f-a823-82c70eb96f81_720x1025.png\" +\n \",community/01d22b53-b451-4cbe-8555-0c6ea02eb255.png\" +\n \",community/01d40f28-dfdb-4972-869b-75e154817ba4.png\" +\n \",community/01d4d7a4-ffeb-4743-90b5-a4a7d5249d27_1080x1439.png\" +\n \",community/01a8cca4-eb88-4660-9404-ebb7f16d82a6_315x420.png\" +\n \",community/01aaa39a-a562-43de-97cd-d48c7fd28fdd.png\" +\n \",community/01b16c8c-14f3-4357-8c30-2638565141c9.png\" +\n \",community/01b1bc11-09fd-49b0-96ed-ed47e743faf0.png\" +\n \",community/01b35a88-e0c6-4221-8aa5-32d96069fbc3_348x464.png\" +\n \",community/01b634d1-8199-4915-aa47-947a0af5466b.png\" +\n \",community/01b841df-1bb4-44b3-af79-142c4834fd46.png\" +\n \",community/01b9660f-b57f-415c-a619-f10bd76cd860.png\" +\n \",community/01ba2a69-db78-4b4b-ad6b-31a2e715182f.png\" +\n \",community/0190b32e-60be-4a49-8cf7-e0d9ce039997.png\" +\n \",community/0191665a-67c0-4ed8-bf01-7b26f5ba1248_1080x1439.png\" +\n \",community/01972534-37fa-433e-ac22-bcceadd2a3fe.png\" +\n \",community/01981657-5340-4cf9-8c90-176c5d465173_348x464.png\" +\n \",community/019f7fdf-f8b0-4086-b2cc-9cd7d7e199b1.png\" +\n \",community/01a0bcc9-d351-4200-be1a-e9c8f322deb1.png\" +\n \",community/01a2a06d-0b31-419d-8d31-66d6e842b806.png\" +\n \",community/017dfb30-469e-401f-becb-e23c647059f1_315x420.png\" +\n \",community/01834f9a-0596-47e1-80b3-ccfd19d12127.png\" +\n \",community/01856873-80bf-4780-9ead-9968aedd8e15_1080x1563.png\" +\n \",community/0186d337-215d-478f-a657-4c0a04f6d028.png\" +\n \",community/0187db31-4c8f-4689-9f6e-500b5f39f6c3.png\" +\n \",community/018c8d90-35a3-4010-9ecc-c943e72a0745_1080x1657.png\" +\n \",community/018cb9ce-756a-4c23-8a7c-aeb85e393ec8.png\" +\n \",community/016a0bfc-3abf-46e9-b4ee-4b6c73562524.png\" +\n \",community/016be936-bca6-4827-bb7e-84b0c496b7e7_1080x1426.png\" +\n \",community/016c40f3-fb9b-49b7-ad93-bc84f4875d6c.png\" +\n \",community/016c51c6-e3dd-4903-962a-8f24c33e6547_348x464.png\" +\n \",community/016e417e-760b-4e3e-bc9b-7db6fe77d5a2_315x420.png\" +\n \",community/01731219-8bdf-4a10-9982-fe347622d877.png\" +\n \",community/0173e603-5a5f-4c2d-a3e7-f92c1b2fa50c.png\" +\n \",community/0177c179-402f-4ff7-8032-e6e4ae21431f.png\" +\n \",community/01785d9d-d5cc-4e38-b990-395ef92c13c0.png\" +\n \",community/0179b793-b92a-4926-ab88-04dd4f434b15.png\" +\n \",community/017afe9f-02d2-4004-ad9e-8afed066e99c.png\" +\n \",community/017b74df-8b8a-440a-9938-9c8b7e43bb8c_348x464.png\" +\n \",community/017d0cbb-e918-466b-a1e7-633d54c7d5b2.png\" +\n \",community/014e9713-3027-4040-b07a-9d6827e527c1_1080x1439.png\" +\n \",community/014eaafd-0702-47ff-87a1-c3cac9a1769a.png\" +\n \",community/0152e9e6-fcde-404e-9fb6-d75a5b265008.png\" +\n \",community/0154b399-ca4d-4c36-98d3-22aed2e28ed9.png\" +\n \",community/0154f316-3833-4c4b-a406-8f54c01ed121.png\" +\n \",community/01559349-89d4-4010-84da-9f3892f21b27.png\" +\n \",community/01575492-8b54-4729-9be5-ade62bb6be54.png\" +\n \",community/0157e449-b041-404c-b05c-442174c33ca1.png\" +\n \",community/015843a0-d566-42b4-b72c-b51901b4da65.png\" +\n \",community/015a1183-c580-4241-8e03-08b6b7e36703.png\" +\n \",community/015addf7-d725-4a32-bc14-12f6526bf1f6.png\" +\n \",community/015b6646-1359-4ca1-a5a1-914db80285f4.png\" +\n \",community/01641ba3-504f-4dfe-aa33-3e4a689eaa0b.png\" +\n \",community/0166b12a-9e1c-4b4e-a527-8f473faddb43_1080x1774.png\" +\n \",community/0167ec5d-b7c9-4d06-a2c8-819682546723_1080x1563.png\";\n String[] arr = objects.split(\",\");\n List<String> keys = Arrays.asList(arr);\n// for (int i = 0; i < 100; i++) {\n// String key = keyPrefix + i;\n// InputStream instream = new ByteArrayInputStream(content.getBytes());\n// client.putObject(bucketName, key, instream);\n// System.out.println(\"Succeed to put object \" + key);\n// keys.add(key);\n// }\n System.out.println();\n\n /*\n * Delete all objects uploaded recently under the bucket\n */\n System.out.println(\"\\nDeleting all objects:\");\n DeleteObjectsResult deleteObjectsResult = client.deleteObjects(\n new DeleteObjectsRequest(bucketName).withKeys(keys));\n List<String> deletedObjects = deleteObjectsResult.getDeletedObjects();\n for (String object : deletedObjects) {\n System.out.println(\"\\t\" + object);\n }\n System.out.println();\n\n } catch (OSSException oe) {\n System.out.println(\"Caught an OSSException, which means your request made it to OSS, \"\n + \"but was rejected with an error response for some reason.\");\n System.out.println(\"Error Message: \" + oe.getErrorCode());\n System.out.println(\"Error Code: \" + oe.getErrorCode());\n System.out.println(\"Request ID: \" + oe.getRequestId());\n System.out.println(\"Host ID: \" + oe.getHostId());\n } catch (ClientException ce) {\n System.out.println(\"Caught an ClientException, which means the client encountered \"\n + \"a serious internal problem while trying to communicate with OSS, \"\n + \"such as not being able to access the network.\");\n System.out.println(\"Error Message: \" + ce.getMessage());\n } finally {\n /*\n * Do not forget to shut down the client finally to release all allocated resources.\n */\n client.shutdown();\n }\n }",
"public AWSStorageGatewayClient(AWSCredentialsProvider awsCredentialsProvider) {\n this(awsCredentialsProvider, new ClientConfiguration());\n }",
"@Test\n public void doRequestURL() throws IOException, NoSuchAlgorithmException, KeyManagementException {\n doRequest(\"https://login.cloud.huawei.com/oauth2/v2/token\");\n\n\n //doRequestWithOutHttps(\"https://124.74.46.118:7012/business/service\");\n //doRequestWithOutHttpsPool(\"https://124.74.46.118:7012/business/service\");\n }",
"public ProviderService() {\r\n super(TAG, SASOCKET_CLASS);\r\n }",
"private Response updateServiceInstances(Modify3gppService request, Action action, String version, String requestId,\n HashMap<String, String> instanceIdMap, String requestUri) throws ApiException {\n String defaultServiceModelName = \"COMMON_SS_DEFAULT\";\n String requestScope = ModelType.service.name();\n String apiVersion = version.substring(1);\n String serviceRequestJson = toString.apply(request);\n if (serviceRequestJson != null) {\n InfraActiveRequests currentActiveReq = createRequestObject(request, action, requestId, Status.IN_PROGRESS,\n requestScope, serviceRequestJson);\n String instanceName = request.getName();\n requestHandlerUtils.checkForDuplicateRequests(action, instanceIdMap, requestScope, currentActiveReq,\n instanceName);\n try {\n requestsDbClient.save(currentActiveReq);\n } catch (Exception e) {\n logger.error(\"Exception occurred\", e);\n ErrorLoggerInfo errorLoggerInfo =\n new ErrorLoggerInfo.Builder(MessageEnum.APIH_DB_ACCESS_EXC, ErrorCode.DataError)\n .errorSource(Constants.MSO_PROP_APIHANDLER_INFRA).build();\n throw new RequestDbFailureException.Builder(SAVE_TO_DB, e.toString(),\n HttpStatus.SC_INTERNAL_SERVER_ERROR, ErrorNumbers.SVC_DETAILED_SERVICE_ERROR).cause(e)\n .errorInfo(errorLoggerInfo).build();\n }\n\n RecipeLookupResult recipeLookupResult;\n try {\n recipeLookupResult = getServiceInstanceOrchestrationURI(null, action, defaultServiceModelName);\n } catch (Exception e) {\n logger.error(LoggingAnchor.FOUR, MessageEnum.APIH_DB_ACCESS_EXC.toString(), MSO_PROP_APIHANDLER_INFRA,\n ErrorCode.AvailabilityError.getValue(), \"Exception while communciate with Catalog DB\", e);\n Response response = msoRequest.buildServiceErrorResponse(HttpStatus.SC_NOT_FOUND,\n MsoException.ServiceException, \"No communication to catalog DB \" + e.getMessage(),\n ErrorNumbers.SVC_NO_SERVER_RESOURCES, null, version);\n logger.debug(END_OF_THE_TRANSACTION + response.getEntity());\n return response;\n }\n\n if (recipeLookupResult == null) {\n logger.error(LoggingAnchor.FOUR, MessageEnum.APIH_DB_ATTRIBUTE_NOT_FOUND.toString(),\n MSO_PROP_APIHANDLER_INFRA, ErrorCode.DataError.getValue(), \"No recipe found in DB\");\n Response response = msoRequest.buildServiceErrorResponse(HttpStatus.SC_NOT_FOUND,\n MsoException.ServiceException, \"Recipe does not exist in catalog DB\",\n ErrorNumbers.SVC_GENERAL_SERVICE_ERROR, null, version);\n logger.debug(END_OF_THE_TRANSACTION + response.getEntity());\n return response;\n }\n\n String serviceInstanceType = request.getSubscriptionServiceType();\n String serviceInstanceId = request.getServiceInstanceID();\n RequestClientParameter parameter;\n try {\n parameter = new RequestClientParameter.Builder().setRequestId(requestId).setBaseVfModule(false)\n .setRecipeTimeout(recipeLookupResult.getRecipeTimeout()).setRequestAction(action.name())\n .setServiceInstanceId(serviceInstanceId).setServiceType(serviceInstanceType)\n .setRequestDetails(serviceRequestJson).setApiVersion(version).setALaCarte(false)\n .setRecipeParamXsd(recipeLookupResult.getRecipeParamXsd()).setApiVersion(apiVersion).build();\n } catch (Exception e) {\n logger.error(\"Exception occurred\", e);\n ErrorLoggerInfo errorLoggerInfo =\n new ErrorLoggerInfo.Builder(MessageEnum.APIH_BPEL_RESPONSE_ERROR, ErrorCode.SchemaError)\n .errorSource(Constants.MSO_PROP_APIHANDLER_INFRA).build();\n throw new ValidateException.Builder(\"Unable to generate RequestClientParamter object\" + e.getMessage(),\n HttpStatus.SC_INTERNAL_SERVER_ERROR, ErrorNumbers.SVC_BAD_PARAMETER).errorInfo(errorLoggerInfo)\n .build();\n }\n return postBPELRequest(currentActiveReq, parameter, recipeLookupResult.getOrchestrationURI(), requestScope);\n\n } else {\n Response response = msoRequest.buildServiceErrorResponse(HttpStatus.SC_INTERNAL_SERVER_ERROR,\n MsoException.ServiceException, \"JsonProcessingException occurred - serviceRequestJson is null\",\n ErrorNumbers.SVC_BAD_PARAMETER, null, version);\n return response;\n }\n }",
"@Override\n\tpublic void init(EndpointConfig arg0) {\n\t\t\n\t}",
"@Override\n\tpublic void init(EndpointConfig arg0) {\n\t\t\n\t}",
"protected abstract String getBaseEndpointPath();",
"boolean hasIsAmazon();",
"@Nullable public String getBucketEndpoint() {\n return bucketEndpoint;\n }",
"@Override\n public GetServiceEndpointResult getServiceEndpoint(GetServiceEndpointRequest request) {\n request = beforeClientExecution(request);\n return executeGetServiceEndpoint(request);\n }"
] | [
"0.6595944",
"0.5477355",
"0.535322",
"0.5300398",
"0.5273976",
"0.52719104",
"0.5245048",
"0.5228586",
"0.51644105",
"0.51298606",
"0.5107663",
"0.50734663",
"0.50696445",
"0.5061846",
"0.50404495",
"0.5007078",
"0.5001926",
"0.49980065",
"0.49325472",
"0.4921881",
"0.49163136",
"0.4914078",
"0.4869726",
"0.48576733",
"0.48153135",
"0.48153135",
"0.48123753",
"0.47737974",
"0.47737974",
"0.47737974",
"0.47411263",
"0.4737106",
"0.47240052",
"0.47192568",
"0.4711273",
"0.47085005",
"0.46914044",
"0.46643022",
"0.46351567",
"0.4631795",
"0.4607907",
"0.45973137",
"0.45903718",
"0.4575648",
"0.45696503",
"0.4555277",
"0.4549074",
"0.45269686",
"0.45237797",
"0.4521026",
"0.45138228",
"0.45128915",
"0.44974405",
"0.44947797",
"0.4487179",
"0.448056",
"0.44797215",
"0.44751891",
"0.44713175",
"0.44695377",
"0.44683492",
"0.44665316",
"0.44648585",
"0.44643584",
"0.44513816",
"0.44513044",
"0.4439239",
"0.4439239",
"0.4439239",
"0.44386044",
"0.44332302",
"0.44322735",
"0.44260094",
"0.44260094",
"0.4425823",
"0.44234043",
"0.44200668",
"0.44170755",
"0.44151",
"0.44031972",
"0.43917042",
"0.43916574",
"0.43906623",
"0.4388809",
"0.4376617",
"0.43763798",
"0.43755212",
"0.43698967",
"0.43690634",
"0.4366974",
"0.4363087",
"0.43614846",
"0.43607756",
"0.43596765",
"0.43571833",
"0.43571833",
"0.4354973",
"0.43518028",
"0.43488076",
"0.43411362"
] | 0.5943687 | 1 |
aws signing region example: 'eucentral1' | String signingRegion(); | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"static RestClientBuilder.HttpClientConfigCallback getAWSRequestSigningInterceptor(String endpoint) {\n\t\treturn (HttpAsyncClientBuilder httpClientBuilder) -> {\n\t\t\thttpClientBuilder.addInterceptorLast((HttpRequest request, HttpContext context) -> {\n\t\t\t\tAws4Signer signer = Aws4Signer.create();\n\t\t\t\tAwsCredentials creds = DefaultCredentialsProvider.create().resolveCredentials();\n\t\t\t\tAws4SignerParams.Builder<?> signerParams = Aws4SignerParams.builder().\n\t\t\t\t\t\tawsCredentials(creds).\n\t\t\t\t\t\tdoubleUrlEncode(true).\n\t\t\t\t\t\tsigningName(\"es\").\n\t\t\t\t\t\tsigningRegion(Region.of(Para.getConfig().elasticsearchAwsRegion()));\n\t\t\t\tURIBuilder uriBuilder;\n\t\t\t\tString httpMethod = request.getRequestLine().getMethod();\n\t\t\t\tString resourcePath;\n\t\t\t\tMap<String, String> params = new HashMap<>();\n\n\t\t\t\ttry {\n\t\t\t\t\tSdkHttpFullRequest.Builder r = SdkHttpFullRequest.builder();\n\t\t\t\t\tif (!StringUtils.isBlank(httpMethod)) {\n\t\t\t\t\t\tr.method(SdkHttpMethod.valueOf(httpMethod));\n\t\t\t\t\t}\n\n\t\t\t\t\tif (!StringUtils.isBlank(endpoint)) {\n\t\t\t\t\t\tif (endpoint.startsWith(\"https://\")) {\n\t\t\t\t\t\t\tr.protocol(\"HTTPS\");\n\t\t\t\t\t\t\tr.host(StringUtils.removeStart(endpoint, \"https://\"));\n\t\t\t\t\t\t} else if (endpoint.startsWith(\"http://\")) {\n\t\t\t\t\t\t\tr.protocol(\"HTTP\");\n\t\t\t\t\t\t\tr.host(StringUtils.removeStart(endpoint, \"http://\"));\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\t\turiBuilder = new URIBuilder(request.getRequestLine().getUri());\n\t\t\t\t\tresourcePath = uriBuilder.getPath();\n\t\t\t\t\tif (!StringUtils.isBlank(resourcePath)) {\n\t\t\t\t\t\tr.encodedPath(resourcePath);\n\t\t\t\t\t}\n\n\t\t\t\t\tfor (NameValuePair param : uriBuilder.getQueryParams()) {\n\t\t\t\t\t\tr.appendRawQueryParameter(param.getName(), param.getValue());\n\t\t\t\t\t}\n\n\t\t\t\t\tif (request instanceof HttpEntityEnclosingRequest) {\n\t\t\t\t\t\tHttpEntity body = ((HttpEntityEnclosingRequest) request).getEntity();\n\t\t\t\t\t\tif (body != null) {\n\t\t\t\t\t\t\tInputStream is = body.getContent();\n\t\t\t\t\t\t\tr.contentStreamProvider(() -> is);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tif (r.contentStreamProvider() == null) {\n\t\t\t\t\t\trequest.removeHeaders(\"Content-Length\");\n\t\t\t\t\t}\n\n\t\t\t\t\tfor (Header header : request.getAllHeaders()) {\n\t\t\t\t\t\tr.putHeader(header.getName(), header.getValue());\n\t\t\t\t\t}\n\n\t\t\t\t\tSdkHttpFullRequest signedReq = signer.sign(r.build(), signerParams.build());\n\n\t\t\t\t\tfor (String header : signedReq.headers().keySet()) {\n\t\t\t\t\t\trequest.setHeader(header, signedReq.firstMatchingHeader(header).orElse(\"\"));\n\t\t\t\t\t}\n\t\t\t\t} catch (Exception ex) {\n\t\t\t\t\tlogger.error(\"Failed to sign request to AWS Elasticsearch:\", ex);\n\t\t\t\t}\n\t\t\t});\n\t\t\treturn httpClientBuilder;\n\t\t};\n\t}",
"public void setRegion(String region) {\n this.region = region;\n }",
"String regionName();",
"String regionName();",
"String regionName();",
"String regionName();",
"public void setRegion(String region) {\n this.region = region;\n }",
"public void setRegion(String region) {\r\n this.region = region;\r\n }",
"public void setRegion(String region) {\r\n this.region = region;\r\n }",
"public void setRegion(String region) {\r\n this.region = region;\r\n }",
"public void setRegion(String region) {\n this.region = region;\n }",
"public void setRegion(String region) {\n this.region = region;\n }",
"public void setRegion(String region) {\n this.region = region;\n }",
"WithCreate withRegion(String location);",
"WithCreate withRegion(String location);",
"public CloudinsRegionRecord() {\n super(CloudinsRegion.CLOUDINS_REGION);\n }",
"public AmazonSigningService(String region, AmazonCredentials credentials, Function<String, Certificate[]> certificateStore) {\n this.certificateStore = certificateStore;\n this.client = new RESTClient(\"https://kms.\" + region + \".amazonaws.com\", (conn, data) -> sign(conn, credentials, data, null));\n }",
"WithCreate withRegion(Region location);",
"WithCreate withRegion(Region location);",
"public void setRegion(String region) {\n this.region = region;\n }",
"kr.pik.message.Profile.HowMe.Region getRegion();",
"public void setRegion(String region);",
"public String getRegion() {\n return region;\n }",
"public String getRegion() {\n return region;\n }",
"WithResourceGroup withRegion(String location);",
"WithResourceGroup withRegion(String location);",
"WithResourceGroup withRegion(Region location);",
"WithResourceGroup withRegion(Region location);",
"public void setRegion(Region region) {\n this.region = region;\n }",
"static String getRegion(Configuration conf, String defaultRegion)\n throws IOException {\n String region = conf.getTrimmed(S3GUARD_DDB_REGION_KEY);\n if (StringUtils.isEmpty(region)) {\n region = defaultRegion;\n }\n try {\n Regions.fromName(region);\n } catch (IllegalArgumentException | NullPointerException e) {\n throw new IOException(\"Invalid region specified: \" + region + \"; \" +\n \"Region can be configured with \" + S3GUARD_DDB_REGION_KEY + \": \" +\n validRegionsString());\n }\n return region;\n }",
"Region region();",
"Region region();",
"Region region();",
"Region region();",
"public String getRegion() {\n return region;\n }",
"public String getRegion() {\n return region;\n }",
"public String getRegion() {\n return region;\n }",
"public String getRegion() {\n return region;\n }",
"public String getRegion() {\n return region;\n }",
"public String getRegion() {\r\n return region;\r\n }",
"public String getRegion() {\r\n return region;\r\n }",
"public String getRegion() {\r\n return region;\r\n }",
"public Optional<AuthLoginAws> authLoginAws() {\n return Codegen.objectProp(\"authLoginAws\", AuthLoginAws.class).config(config).get();\n }",
"public static void printEnvVariables(String region, String s3BucketName, String SNSTopicARN) {\n\t\tSystem.out.println(\"Region: \" + region);\n\t\tSystem.out.println(\"S3 Bucket for storing Glue Data Catalog partition data: \" + s3BucketName);\n\t\tSystem.out.println(\"SNS Topic for publishing Glue Data Catalog metadata: \" + SNSTopicARN);\n\t}",
"public String getRegion() {\n return this.region;\n }",
"@AutoEscape\n public String getRegion();",
"public String getRegionName() {\r\n return regionName;\r\n }",
"public String getRegionName() {\n return regionName;\n }",
"public byte [] getRegionName() {\n return regionName;\n }",
"public String getRegion() {\n return region;\n }",
"public interface AWSServiceCatalog {\n\n /**\n * The region metadata service name for computing region endpoints. You can use this value to retrieve metadata\n * (such as supported regions) of the service.\n *\n * @see RegionUtils#getRegionsForService(String)\n */\n String ENDPOINT_PREFIX = \"servicecatalog\";\n\n /**\n * Overrides the default endpoint for this client (\"servicecatalog.us-east-1.amazonaws.com\"). Callers can use this\n * method to control which AWS region they want to work with.\n * <p>\n * Callers can pass in just the endpoint (ex: \"servicecatalog.us-east-1.amazonaws.com\") or a full URL, including the\n * protocol (ex: \"servicecatalog.us-east-1.amazonaws.com\"). If the protocol is not specified here, the default\n * protocol from this client's {@link ClientConfiguration} will be used, which by default is HTTPS.\n * <p>\n * For more information on using AWS regions with the AWS SDK for Java, and a complete list of all available\n * endpoints for all AWS services, see: <a\n * href=\"http://developer.amazonwebservices.com/connect/entry.jspa?externalID=3912\">\n * http://developer.amazonwebservices.com/connect/entry.jspa?externalID=3912</a>\n * <p>\n * <b>This method is not threadsafe. An endpoint should be configured when the client is created and before any\n * service requests are made. Changing it afterwards creates inevitable race conditions for any service requests in\n * transit or retrying.</b>\n *\n * @param endpoint\n * The endpoint (ex: \"servicecatalog.us-east-1.amazonaws.com\") or a full URL, including the protocol (ex:\n * \"servicecatalog.us-east-1.amazonaws.com\") of the region specific AWS endpoint this client will communicate\n * with.\n */\n void setEndpoint(String endpoint);\n\n /**\n * An alternative to {@link AWSServiceCatalog#setEndpoint(String)}, sets the regional endpoint for this client's\n * service calls. Callers can use this method to control which AWS region they want to work with.\n * <p>\n * By default, all service endpoints in all regions use the https protocol. To use http instead, specify it in the\n * {@link ClientConfiguration} supplied at construction.\n * <p>\n * <b>This method is not threadsafe. A region should be configured when the client is created and before any service\n * requests are made. Changing it afterwards creates inevitable race conditions for any service requests in transit\n * or retrying.</b>\n *\n * @param region\n * The region this client will communicate with. See {@link Region#getRegion(com.amazonaws.regions.Regions)}\n * for accessing a given region. Must not be null and must be a region where the service is available.\n *\n * @see Region#getRegion(com.amazonaws.regions.Regions)\n * @see Region#createClient(Class, com.amazonaws.auth.AWSCredentialsProvider, ClientConfiguration)\n * @see Region#isServiceSupported(String)\n */\n void setRegion(Region region);\n\n /**\n * <p>\n * Retrieves information about a specified product.\n * </p>\n * <p>\n * This operation is functionally identical to <a>DescribeProductView</a> except that it takes as input\n * <code>ProductId</code> instead of <code>ProductViewId</code>.\n * </p>\n * \n * @param describeProductRequest\n * @return Result of the DescribeProduct operation returned by the service.\n * @throws ResourceNotFoundException\n * The specified resource was not found.\n * @throws InvalidParametersException\n * One or more parameters provided to the operation are invalid.\n * @sample AWSServiceCatalog.DescribeProduct\n */\n DescribeProductResult describeProduct(DescribeProductRequest describeProductRequest);\n\n /**\n * <p>\n * Retrieves information about a specified product.\n * </p>\n * <p>\n * This operation is functionally identical to <a>DescribeProduct</a> except that it takes as input\n * <code>ProductViewId</code> instead of <code>ProductId</code>.\n * </p>\n * \n * @param describeProductViewRequest\n * @return Result of the DescribeProductView operation returned by the service.\n * @throws ResourceNotFoundException\n * The specified resource was not found.\n * @throws InvalidParametersException\n * One or more parameters provided to the operation are invalid.\n * @sample AWSServiceCatalog.DescribeProductView\n */\n DescribeProductViewResult describeProductView(DescribeProductViewRequest describeProductViewRequest);\n\n /**\n * <p>\n * Provides information about parameters required to provision a specified product in a specified manner. Use this\n * operation to obtain the list of <code>ProvisioningArtifactParameters</code> parameters available to call the\n * <a>ProvisionProduct</a> operation for the specified product.\n * </p>\n * \n * @param describeProvisioningParametersRequest\n * @return Result of the DescribeProvisioningParameters operation returned by the service.\n * @throws InvalidParametersException\n * One or more parameters provided to the operation are invalid.\n * @throws ResourceNotFoundException\n * The specified resource was not found.\n * @sample AWSServiceCatalog.DescribeProvisioningParameters\n */\n DescribeProvisioningParametersResult describeProvisioningParameters(DescribeProvisioningParametersRequest describeProvisioningParametersRequest);\n\n /**\n * <p>\n * Retrieves a paginated list of the full details of a specific request. Use this operation after calling a request\n * operation (<a>ProvisionProduct</a>, <a>TerminateProvisionedProduct</a>, or <a>UpdateProvisionedProduct</a>).\n * </p>\n * \n * @param describeRecordRequest\n * @return Result of the DescribeRecord operation returned by the service.\n * @throws ResourceNotFoundException\n * The specified resource was not found.\n * @sample AWSServiceCatalog.DescribeRecord\n */\n DescribeRecordResult describeRecord(DescribeRecordRequest describeRecordRequest);\n\n /**\n * <p>\n * Returns a paginated list of all paths to a specified product. A path is how the user has access to a specified\n * product, and is necessary when provisioning a product. A path also determines the constraints put on the product.\n * </p>\n * \n * @param listLaunchPathsRequest\n * @return Result of the ListLaunchPaths operation returned by the service.\n * @throws InvalidParametersException\n * One or more parameters provided to the operation are invalid.\n * @throws ResourceNotFoundException\n * The specified resource was not found.\n * @sample AWSServiceCatalog.ListLaunchPaths\n */\n ListLaunchPathsResult listLaunchPaths(ListLaunchPathsRequest listLaunchPathsRequest);\n\n /**\n * <p>\n * Returns a paginated list of all performed requests, in the form of RecordDetails objects that are filtered as\n * specified.\n * </p>\n * \n * @param listRecordHistoryRequest\n * @return Result of the ListRecordHistory operation returned by the service.\n * @throws InvalidParametersException\n * One or more parameters provided to the operation are invalid.\n * @sample AWSServiceCatalog.ListRecordHistory\n */\n ListRecordHistoryResult listRecordHistory(ListRecordHistoryRequest listRecordHistoryRequest);\n\n /**\n * <p>\n * Requests a <i>Provision</i> of a specified product. A <i>ProvisionedProduct</i> is a resourced instance for a\n * product. For example, provisioning a CloudFormation-template-backed product results in launching a CloudFormation\n * stack and all the underlying resources that come with it.\n * </p>\n * <p>\n * You can check the status of this request using the <a>DescribeRecord</a> operation.\n * </p>\n * \n * @param provisionProductRequest\n * @return Result of the ProvisionProduct operation returned by the service.\n * @throws InvalidParametersException\n * One or more parameters provided to the operation are invalid.\n * @throws ResourceNotFoundException\n * The specified resource was not found.\n * @throws DuplicateResourceException\n * The specified resource is a duplicate.\n * @sample AWSServiceCatalog.ProvisionProduct\n */\n ProvisionProductResult provisionProduct(ProvisionProductRequest provisionProductRequest);\n\n /**\n * <p>\n * Returns a paginated list of all the ProvisionedProduct objects that are currently available (not terminated).\n * </p>\n * \n * @param scanProvisionedProductsRequest\n * @return Result of the ScanProvisionedProducts operation returned by the service.\n * @throws InvalidParametersException\n * One or more parameters provided to the operation are invalid.\n * @sample AWSServiceCatalog.ScanProvisionedProducts\n */\n ScanProvisionedProductsResult scanProvisionedProducts(ScanProvisionedProductsRequest scanProvisionedProductsRequest);\n\n /**\n * <p>\n * Returns a paginated list all of the <code>Products</code> objects to which the caller has access.\n * </p>\n * <p>\n * The output of this operation can be used as input for other operations, such as <a>DescribeProductView</a>.\n * </p>\n * \n * @param searchProductsRequest\n * @return Result of the SearchProducts operation returned by the service.\n * @throws InvalidParametersException\n * One or more parameters provided to the operation are invalid.\n * @sample AWSServiceCatalog.SearchProducts\n */\n SearchProductsResult searchProducts(SearchProductsRequest searchProductsRequest);\n\n /**\n * <p>\n * Requests termination of an existing ProvisionedProduct object. If there are <code>Tags</code> associated with the\n * object, they are terminated when the ProvisionedProduct object is terminated.\n * </p>\n * <p>\n * This operation does not delete any records associated with the ProvisionedProduct object.\n * </p>\n * <p>\n * You can check the status of this request using the <a>DescribeRecord</a> operation.\n * </p>\n * \n * @param terminateProvisionedProductRequest\n * @return Result of the TerminateProvisionedProduct operation returned by the service.\n * @throws ResourceNotFoundException\n * The specified resource was not found.\n * @sample AWSServiceCatalog.TerminateProvisionedProduct\n */\n TerminateProvisionedProductResult terminateProvisionedProduct(TerminateProvisionedProductRequest terminateProvisionedProductRequest);\n\n /**\n * <p>\n * Requests updates to the configuration of an existing ProvisionedProduct object. If there are tags associated with\n * the object, they cannot be updated or added with this operation. Depending on the specific updates requested,\n * this operation may update with no interruption, with some interruption, or replace the ProvisionedProduct object\n * entirely.\n * </p>\n * <p>\n * You can check the status of this request using the <a>DescribeRecord</a> operation.\n * </p>\n * \n * @param updateProvisionedProductRequest\n * @return Result of the UpdateProvisionedProduct operation returned by the service.\n * @throws InvalidParametersException\n * One or more parameters provided to the operation are invalid.\n * @throws ResourceNotFoundException\n * The specified resource was not found.\n * @sample AWSServiceCatalog.UpdateProvisionedProduct\n */\n UpdateProvisionedProductResult updateProvisionedProduct(UpdateProvisionedProductRequest updateProvisionedProductRequest);\n\n /**\n * Shuts down this client object, releasing any resources that might be held open. This is an optional method, and\n * callers are not expected to call it, but can if they want to explicitly release any open resources. Once a client\n * has been shutdown, it should not be used to make any more requests.\n */\n void shutdown();\n\n /**\n * Returns additional metadata for a previously executed successful request, typically used for debugging issues\n * where a service isn't acting as expected. This data isn't considered part of the result data returned by an\n * operation, so it's available through this separate, diagnostic interface.\n * <p>\n * Response metadata is only cached for a limited period of time, so if you need to access this extra diagnostic\n * information for an executed request, you should use this method to retrieve it as soon as possible after\n * executing a request.\n *\n * @param request\n * The originally executed request.\n *\n * @return The response metadata for the specified request, or null if none is available.\n */\n ResponseMetadata getCachedResponseMetadata(AmazonWebServiceRequest request);\n\n}",
"public static void main(String[] args) throws AddressFormatException {\n\n// generateMultisig();\n String getSignedTransaction = signFirstTime();\n String rawtx = signSecondTime(getSignedTransaction);\n\n System.out.println(\"rawtx ->\"+ rawtx);\n }",
"public void setStorageRegion(String StorageRegion) {\n this.StorageRegion = StorageRegion;\n }",
"@Override\r\n\t public String getFunctionName() {\r\n\t return \"ExampleAwsLambda\";\r\n\t }",
"@SuppressWarnings(\"unused\")\n @PostConstruct\n private void initializeAmazon() {\n AWSCredentials credentials = new BasicAWSCredentials(negaBucketAccessKey, negaBucketSecretKey);\n this.s3client =\n AmazonS3ClientBuilder.standard()\n .withCredentials(new AWSStaticCredentialsProvider(credentials))\n .withRegion(Regions.US_EAST_1)\n .build();\n }",
"java.lang.String getRegionId();",
"private static void createBucket(S3Client s3, Region region) {\n try {\n S3Waiter s3Waiter = s3Client.waiter();\n CreateBucketRequest bucketRequest = CreateBucketRequest.builder()\n .bucket(BUCKET_NAME)\n .createBucketConfiguration(\n CreateBucketConfiguration.builder()\n .locationConstraint(region.id())\n .build())\n .build();\n\n s3.createBucket(bucketRequest);\n HeadBucketRequest bucketRequestWait = HeadBucketRequest.builder()\n .bucket(BUCKET_NAME)\n .build();\n\n // Wait until the bucket is created and print out the response\n WaiterResponse<HeadBucketResponse> waiterResponse = s3Waiter.waitUntilBucketExists(bucketRequestWait);\n //waiterResponse.matched().response().ifPresent(System.out::println);\n waiterResponse.matched().response().ifPresent(n-> System.out.println());\n System.out.println(\"Bucket name: \" + \"\\\"\" + BUCKET_NAME + \"\\\"\" +\" is ready\\n\");\n } catch (S3Exception e) {\n System.err.println(e.awsErrorDetails().errorMessage());\n System.exit(1);\n }\n }",
"public java.lang.String getREGION()\n {\n \n return __REGION;\n }",
"@Override\n public byte[] getStartKey(){\n return region.getRegionInfo().getStartKey();\n }",
"public Builder withRegion(final String region) {\n this.region = region;\n return this;\n }",
"SnapshotSku sku();",
"private static S3Client getS3ClientForDevelopment(Region region) {\n\t\tS3Client s3Client = getS3Client(ProfileCredentialsProvider.create());\n\t\tif (s3Client != null) {\n\t\t\treturn s3Client;\n\t\t}\n\n\t\t// Try provider used when AWS_ACCESS_KEY_ID and AWS_SECRET_ACCESS_KEY environment\n\t\t// variables are present\n\t\ts3Client = getS3Client(EnvironmentVariableCredentialsProvider.create());\n\t\tif (s3Client != null) {\n\t\t\treturn s3Client;\n\t\t}\n\n\t\t// Try provider used when aws.accessKeyId and aws.secretKey system properties are set\n\t\ts3Client = getS3Client(SystemPropertyCredentialsProvider.create());\n\t\tif (s3Client != null) {\n\t\t\treturn s3Client;\n\t\t}\n\n\t\t// Try all other providers\n\t\treturn S3Client.builder()\n\t\t\t\t.region(region)\n\t\t\t\t.build();\n\t}",
"public static void main(String[] args) throws Exception {\n String secretKey = \"WOw+6dMYD2W/Qt5i3FzM0TNMOe4jpGEACmhEvlSW\";\n\n // Use the endpoint for your marketplace\n String serviceUrl = \"https://mws.amazonservices.com.cn/Orders/2013-09-01\";\n\n // Create set of parameters needed and store in a map\n HashMap<String, String> parameters = new HashMap<String, String>();\n\n System.out.println(\"\\u6ca1\\u6709\\u7528\\u5e10\\u53f7\\u767b\\u5f55\");\n\n // Add required parameters. Change these as needed.\n parameters.put(\"AWSAccessKeyId\", urlEncode(\"AKIAIUPF5HHXOHP33PXQ\"));\n parameters.put(\"Action\", urlEncode(\"GetOrder\"));\n// parameters.put(\"MWSAuthToken\", urlEncode(\"\"));\n parameters.put(\"SellerId\", urlEncode(\"A2BJRKK636DQMN\"));\n parameters.put(\"SignatureMethod\", urlEncode(ALGORITHM));\n parameters.put(\"SignatureVersion\", urlEncode(\"2\"));\n// parameters.put(\"SubmittedFromDate\", urlEncode(\"2013-05-01T12:00:00Z\"));\n parameters.put(\"Timestamp\", urlEncode(\"2016-04-11T21:42:52Z\"));\n parameters.put(\"Version\", urlEncode(\"2013-09-01\"));\n\n System.out.println(new Date());\n // Format the parameters as they will appear in final format\n // (without the signature parameter)\n String formattedParameters = calculateStringToSignV2(parameters, serviceUrl);\n\n String signature = sign(formattedParameters, secretKey);\n\n // Add signature to the parameters and display final results\n// parameters.put(\"Signature\", urlEncode(signature));\n parameters.put(\"Signature\", \"g/YTA9HMsbWJZ7v9YBmQewD6FtkDD8SlWKZYVQNpgjY=\");\n parameters.put(\"AmazonOrderId.Id.1\", \"C02-3104734-8660044\");\n String url = calculateStringToSignV2(parameters, serviceUrl);\n System.out.println(url);\n url = \"https://mws.amazonservices.com.cn/Orders/2013-09-01?AWSAccessKeyId=AKIAIUPF5HHXOHP33PXQ&Action=GetOrder&SellerId=A2BJRKK636DQMN&SignatureVersion=2&Timestamp=2016-04-11T02%3A44%3A48Z&Version=2013-09-01&Signature=8W0iiMV0Jtea%2BnukhZnqfb1pa6zIUEeRmmA6vOh2tWI%3D&SignatureMethod=HmacSHA256&AmazonOrderId.Id.1=C03-6051918-4780805\";\n JSoupParser parser = new JSoupParser(\"https://mws.amazonservices.com.cn/Orders/2013-09-01\");\n Map<String, String> headers = new HashMap<>();\n headers.put(\"x-amazon-user-agent\", \"AmazonJavascriptScratchpad/1.0 (Language=Javascript)\\n\");\n headers.put(\"X-Requested-With\", \"XMLHttpRequest\\n\");\n Map<String, String> cookies = new HashMap<>();\n cookies.put(\"session-id-time-cn\", \"1460962800l\");\n cookies.put(\"session-id-cn\", \"475-2855409-1672501\");\n cookies.put(\"ubid-acbcn\", \"475-9817303-5467017\");\n cookies.put(\"csm-hit\", \"32.13|1460410865762\");\n Document doc = parser.parse(parameters,headers, cookies);\n// Document doc = Jsoup.connect(serviceUrl).header(\"x-amazon-user-agent\", \"AmazonJavascriptScratchpad/1.0 (Language=Javascript)\").data(parameters).get();\n System.out.println(doc.html());\n }",
"public String getStorageRegion() {\n return this.StorageRegion;\n }",
"java.lang.String getRegionCode();",
"private static String signFirstTime() throws AddressFormatException\n {\n ECKey key1 = ECKey.fromPrivate(new BigInteger(\"64102401986961187973900162212679081334328198710146539384491794427145725009072\"));\n\n\n // Use the redeem script we have saved somewhere to start building the transaction\n Script redeemScript = new Script(hexStringToByteArray(\"5221021ae8964b8529dc3e52955f2cabd967e08c52008dbcca8e054143b668f3998f4a210306be609ef37366ab0f3dd4096ac23a6ee4d561fc469fa60003f799b0121ad1072102199f3d89fa00e6f55dd6ecdd911457d7264415914957db124d53bf0064963f3853ae\"));\n\n // Start building the transaction by adding the unspent inputs we want to use\n // The data is taken from blockchain.info, and can be found here: https://blockchain.info/rawtx/ca1884b8f2e0ba88249a86ec5ddca04f937f12d4fac299af41a9b51643302077\n Transaction spendTx = new Transaction(params);\n ScriptBuilder scriptBuilder = new ScriptBuilder();\n scriptBuilder.data(new String(\"a9145204ad7c5fa5a2491cd91c332e28c87221194ca087\").getBytes()); // Script of this output\n TransactionInput input = spendTx.addInput(new Sha256Hash(\"fed695bf5e2c15286956a7bd3464c5beb97ef064e1f9406eba189ea844733e7c\"), 1, scriptBuilder.build());\n\n // Add outputs to the person receiving bitcoins\n Address receiverAddress = new Address(params, \"n2cWhs5sbWFCwzuuWWsVM9ubPwykGtX75T\");\n Coin charge = Coin.valueOf(1000000); // 0.1 mBTC\n Script outputScript = ScriptBuilder.createOutputScript(receiverAddress);\n spendTx.addOutput(charge, outputScript);\n\n /*8888888888888888888888888888888888888888888888888888888888888*/\n\n // Sign the first part of the transaction using private key #1\n Sha256Hash sighash = spendTx.hashForSignature(0, redeemScript, Transaction.SigHash.ALL, false);\n ECKey.ECDSASignature ecdsaSignature = key1.sign(sighash);\n TransactionSignature transactionSignarture = new TransactionSignature(ecdsaSignature, Transaction.SigHash.ALL, false);\n\n // Create p2sh multisig input script\n Script inputScript = ScriptBuilder.createP2SHMultiSigInputScript(Arrays.asList(transactionSignarture), redeemScript);\n\n // Add the script signature to the input\n input.setScriptSig(inputScript);\n System.out.println(byteArrayToHex(spendTx.bitcoinSerialize()));\n\n return byteArrayToHex(spendTx.bitcoinSerialize());\n }",
"public interface SignCallUseCase {\n\n String signature(String method, Map<String, String> params, String secret);\n\n}",
"@Config(\"aws_secret_access_key\")\n @ConfigDefault(\"null\")\n Optional<String> getAwsSecretAccessKey();",
"public String getRegionId() {\r\n return regionId;\r\n }",
"java.lang.String getS3();",
"public String getRegionId() {\n return regionId;\n }",
"public String getRegionId() {\n return regionId;\n }",
"public String getRegionId() {\n return regionId;\n }",
"public void setRegion_id(String region_id) {\n this.region_id = region_id;\n }",
"public void setRegion(String region) {\n this.region = region == null ? null : region.trim();\n }",
"public void setRegion(String region) {\n this.region = region == null ? null : region.trim();\n }",
"public static AmazonSNSClient getSNSClient(){\n if(snsClient == null){\n snsClient = new AmazonSNSClient( new BasicAWSCredentials( _ACCESS_KEY_ID, _SECRET_KEY ) );\n snsClient.setRegion(Region.getRegion(Regions.EU_CENTRAL_1));\n }\n return snsClient;\n }",
"SignatureSource createSignatureSource();",
"public GenAmazonS3Config() {\n }",
"@Delegate\n @Path(\"/projects/{project}/regions/{region}\")\n RegionOperationApi getRegionOperationApi(@PathParam(\"project\") String project, @PathParam(\"region\") String region);",
"public S3_Upload_Image() {super(TAG);}",
"public String getRegionid() {\n return regionid;\n }",
"public static void main(String[] args) throws IcbcApiException {\n\t\tUiIcbcClient client = new UiIcbcClient(APP_ID,IcbcConstants.SIGN_TYPE_RSA,\n\t\t\t\t\"MIICdwIBADANBgkqhkiG9w0BAQEFAASCAmEwggJdAgEAAoGBAJCoQe/O+uqpOtyE/2CUjD7wosZw8jI1AlLNJCllOmlX+obA6h97b0JsEL0SjMCAR3xJyw7MKLqkcy5qQ/bBgw2XSrodmjzOVqfT1OXRii0xw0HiVkHR4cEWnEAAdfo0lDc4iuzCIQrnT5gM0+U+qeSV6JFfwVRjgYzBdHQRPCf1AgMBAAECgYAdQUoEe7GXH5591o/nMmOinvvscg8pRDsyD7bOgGBtyZMrCXzP3SDFKCHCeyvoColqg2oDlhpulK+OpYMVNlGQcO4eubOJp9MUc3m4A9RxkVr3dsVrmygM5czPfWHAPVQ4dECDruBJn9zoo1ci0myRTh4KSCq6SxpCE0Pbf3j7iQJBAOdMPFRfOkSQ1hsN9Mg4jd9on8r7+mF8gFPhkNI6qvEKw/prmU3obUWvZL42vRlLOQyyB92mBF24PStR/B6CjR8CQQCgGz0VoqCplurSCapGdgX3D7bNSDtMUmaLJYJxih8v+zghP0YtVgDeV3NjogVjOlz8/9Rebo0PoFcqyJnNA1RrAkEAul3dBoasZm7ldWsrXuDiv66HgoDB4Cb3J59Kl3oaHpp0CqUEI5gx48JNRE7K00SfNTGF0Pxh7Dn1X6Bxqwu6NQJADrdyPfLc4bnFi9jnleJzWepP2z6wdKt+UXv5KYaQp1BoMGYohTJKkiVnrdjOtfg/Y+IAG03+GVmbqYsW2AleUQJBANYQklohKtsmq8ptX3as6hjcuXcTpc2DSpVeOnCueNv107+dDJ+K14tbiVYzF3tkHBNMRkGtr6EuGKJ+A63sJ00=\",\n\t\t\t\tIcbcConstants.CHARSET_UTF8,IcbcConstants.ENCRYPT_TYPE_AES, \"xMh0xFsG7G80ziePFdnT8g==\");\n\t\tEaccountManageRequestV1 request = new EaccountManageRequestV1();\t\t\n\t\trequest.setServiceUrl(\"http://122.64.61.111:8081/ui/eaccount/manage/V1\");///\n\t\tEaccountManageRequestBizV1 bizContent = new EaccountManageRequestBizV1();\n\t\tbizContent.setMobileNo(\"13703878410\");//选输,手机号\n\t\tbizContent.setIdcode(\"128440810108044\");//选输,身份证号\n\t\tbizContent.setName(URLEncoder.encode(\"芡悠\"));//选输,用户姓名\n\t\tbizContent.setUserId(\"128440810108044\");//必输,需控制不能为空,用户唯一标识,送身份证号\n\t\tbizContent.setBacAddr(URLEncoder.encode(\"http://www.test.com\"));//选输,回调地址\n\t\tbizContent.setEpayflag(\"0\");//选输,工银e支付标志,0-短信、1-静态密码,集成客户端SDK的方式能送0-短信或1-静态密码,非APP方式只能送0-短信,不送默认为0-短信\n\t\t\n\t\tbizContent.setCorpAppid(APP_ID);//外公司合作方送APP_ID的值,行内应用如e支付等送外公司合作方的APPID\n\t\tlong systime = System.currentTimeMillis(); // 现时间戳\t\t\n\t\tString orderTimeStamp=new Long(systime).toString();\n\t\t\n\t\tSystem.out.println(\"orderTimeStamp:\"+orderTimeStamp);\n\t\tbizContent.setOrderTimeStamp(orderTimeStamp);//生成请求的时间,必输\n\t\t\n\t\tbizContent.setZoneno(\"00200\");//地区号号,选输,5位数字,上送值联系对接分行提供\n\t\tbizContent.setBrno(\"00260\");//网点号,选输,5位数字,上送值联系对接分行提供\n\t\t\n\t\trequest.setBizContent(bizContent);\n\t\tSystem.out.println(client.buildPostForm(request));// 实际调用时的相关返回结果及异常处理,请自行添加\n\t}",
"public java.lang.String getRegionname() {\n\treturn regionname;\n}",
"String getArn();",
"IRegion getRegion();",
"public static void main(String args[]) {\n\t\tfinal Region region = Region.of(\"us-east-1\");\n\t\tString s3Bucket = \"ab2d-optout-data-dev\";\n\t\tString s3Filename = \"T#EFT.ON.ACO.NGD1800.DPRF.D191029.T1135430\";\n\n\t\t// Get s3 client for EC2 instance (if applicable)\n\t\tS3Client s3Client = getS3ClientForEc2Instance();\n\t\tif (s3Client == null) {\n\t\t\t// Get s3 client for development\n\t\t\ts3Client = getS3ClientForDevelopment(region);\n\t\t}\n\n\t\t// build GetObjectRequest\n\t\tfinal GetObjectRequest getObjectRequest = GetObjectRequest.builder()\n\t\t\t\t.bucket(s3Bucket)\n\t\t\t\t.key(s3Filename)\n\t\t\t\t.build();\n\n\t\ttry (final ResponseInputStream<GetObjectResponse> responseInputStream = s3Client.getObject(getObjectRequest)) {\n\t\t} catch (IOException e) {\n\t\t\tlog.error(\"Unable to get s3 object on AWS : \", e);\n\t\t} catch (SdkServiceException e) {\n\t\t\tlog.error(\"Server error upon calling AWS : \", e);\n\t\t\tthrow e;\n\t\t} catch (SdkClientException e) {\n\t\t\tlog.error(\"Client exception on attempting to call AWS : \", e);\n\t\t\tthrow e;\n\t\t}\n\t}",
"public ProtectedRegion createRegion(UUID owner, Location location, Material material)\n\t{\n\t\t// Generate new id for the region\n\t\tUUID id = UUID.randomUUID();\n\t\treturn createRegion(id, owner, location, material);\n\t}",
"public String getSignLocation() {\n\t\treturn signLocation;\n\t}",
"CreateS3VolumeRequestBuilder setSseAlgorithm(String sseAlgorithm);",
"public AWSStorageGatewayClient(AWSCredentialsProvider awsCredentialsProvider) {\n this(awsCredentialsProvider, new ClientConfiguration());\n }",
"public void setRegionid(String regionid) {\n this.regionid = regionid;\n }",
"public Region getRegion() {\n return region;\n }",
"@Override\n\tpublic String getMYSign(Map<String, String> param) {\n\t\treturn appMd5(param,getKey());\n\t}",
"@Bean\n public AmazonS3 amazonS3Client()\n {\n return new AmazonS3Client(new DefaultAWSCredentialsProviderChain());\n }",
"public String getStaticRegionId() {\n return staticRegionId;\n }",
"byte[] getSignatureImage();",
"@Nullable public abstract URI region();",
"@Delegate\n MetricApi getMetricApiForRegion(@EndpointParam(parser = RegionToEndpointOrProviderIfNull.class) @Nullable String region);",
"public static boolean inAwsEnv() {\n\t\treturn RuntimeParamUtil.isAwsMode();\n\t}"
] | [
"0.59606904",
"0.5827978",
"0.5758868",
"0.5758868",
"0.5758868",
"0.5758868",
"0.5691224",
"0.56848097",
"0.56848097",
"0.56848097",
"0.56734306",
"0.56734306",
"0.56734306",
"0.56188124",
"0.56188124",
"0.5610399",
"0.56057984",
"0.5604292",
"0.5604292",
"0.5599596",
"0.5480349",
"0.54344916",
"0.5384077",
"0.5384077",
"0.5320097",
"0.5320097",
"0.53104043",
"0.53104043",
"0.5309085",
"0.5280153",
"0.5258412",
"0.5258412",
"0.5258412",
"0.5258412",
"0.52174157",
"0.52174157",
"0.52174157",
"0.52174157",
"0.52174157",
"0.5194829",
"0.5194829",
"0.5194829",
"0.51839",
"0.5171606",
"0.516084",
"0.515235",
"0.5148994",
"0.51482266",
"0.5142481",
"0.51376945",
"0.5137144",
"0.51255363",
"0.5099483",
"0.5099128",
"0.508586",
"0.50695544",
"0.5053672",
"0.5035921",
"0.49900872",
"0.49733424",
"0.49645662",
"0.49517533",
"0.49353427",
"0.49339396",
"0.49236387",
"0.49058086",
"0.48812667",
"0.48772767",
"0.48748055",
"0.48677227",
"0.4867043",
"0.4867043",
"0.4867043",
"0.4837654",
"0.48250395",
"0.48250395",
"0.47748348",
"0.47717166",
"0.47606146",
"0.47580606",
"0.4751802",
"0.47503972",
"0.47409183",
"0.47360796",
"0.47346428",
"0.47327513",
"0.47313377",
"0.47254363",
"0.4715409",
"0.47117856",
"0.47107136",
"0.4709068",
"0.4698542",
"0.46808192",
"0.46798977",
"0.46652",
"0.46515718",
"0.46492922",
"0.4648908",
"0.4641499"
] | 0.77367115 | 0 |
this method updates the vechical's name | public void helper1(Automobile car, String newData) {
car.setName(newData);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"private void setName() {\n\t\t//MAKE SURE NOT TO GET ACCIDENTAL RECURSION HERE\n\t\t//DO NOT JUST MAKE A NEW TRIAD AND COMPARE TO CURRENT TRIAD\n\t\t//UNLESS ??? MAYBEDON\"T PUT SET NAME IN THE CONSTRUCTOR?\n\t\t//SIMILAR PROBLEM TO SETINVERSION\n\t\t\n\t\t//major, minor, diminished, augmented\n\t\t//this.name = name;\n\t}",
"public void setName(String new_name){\n this.name=new_name;\n }",
"public void setName(String newname){\n name = newname; \n }",
"private void editName() {\n Routine r = list.getSelectedValue();\n\n String s = (String) JOptionPane.showInputDialog(\n this,\n \"Enter the new name:\",\n \"Edit name\",\n JOptionPane.PLAIN_MESSAGE,\n null, null, r.getName());\n\n if (s != null) {\n r.setName(s);\n }\n }",
"void updateDisplayName();",
"public void setName(String newname)\n {\n name = newname;\n \n }",
"private void setName(){\r\n\t\tString tagString = new String();\r\n\t\tfor (String k : tags.keySet()){\r\n\t\t\ttagString += \"@\" + k;\r\n\t\t}\r\n\t\tString newName = originalName + tagString +\".\"+ extension;\r\n\t\tif (!newName.equals(name)){\r\n\t\t\tremovePrevNames(newName); //if the new name is a previous name\r\n\t\t\taddPrevNames(name);\r\n\t\t\tupdateLog(newName);\r\n\t\t\tname = newName;\r\n\t\t\t//notify the tag observer\r\n\t\t\tsetChanged();\r\n\t\t\tnotifyObservers();\r\n\t\t\tclearChanged();\r\n\t\t}\r\n\t}",
"@Override\n public void setName(String name) {\n \n }",
"public void setName(String v){\n\t\ttry{\n\t\tsetProperty(SCHEMA_ELEMENT_NAME + \"/name\",v);\n\t\t_Name=null;\n\t\t} catch (Exception e1) {logger.error(e1);}\n\t}",
"@Override\r\n\tpublic void updateName(int eno, String newName) {\n\r\n\t}",
"public void setName (String name){\n \n boyName = name;\n }",
"public void setName( String name ) {\n doCommand( new UpdateSegmentObject( getUser().getUsername(), getFlow(), \"name\", name ) );\n }",
"public void setName(String name){this.name=name;}",
"private void setName(java.lang.String name) {\n System.out.println(\"setting name \"+name);\n this.name = name;\n }",
"private void updateNameView() {\n String insertedText = getName();\n\n if (seekBar.getProgress() == 0) {\n insertedText = \"\";\n }\n\n String text = String.format(res.getString(R.string.str_tv_firstName_value), insertedText);\n\n nameView.setText(text);\n }",
"public void setName(String name) \n {\n this.name = name;\n }",
"public void setName(String name){this.name = name;}",
"void setName(String name)\n\t{\n\t\t\tthis.name = name;\n\t}",
"public void updateName() {\n try {\n userFound = clientefacadelocal.find(this.idcliente);\n if (userFound != null) {\n userFound.setNombre(objcliente.getNombre());\n clientefacadelocal.edit(userFound);\n objcliente = new Cliente();\n mensaje = \"sia\";\n } else {\n mensaje = \"noa\";\n System.out.println(\"Usuario No Encontrado\");\n }\n } catch (Exception e) {\n mensaje = \"noa\";\n System.out.println(\"El error al actualizar el nombre es \" + e);\n }\n }",
"void setName(String name_);",
"public void setName(String name) {\n fName= name;\n }",
"public void setName(String name){\r\n this.name = name;\r\n }",
"public void setName(String name){\r\n this.name = name;\r\n }",
"public void setName(String name){\r\n this.name = name;\r\n }",
"public void setName(String newname) {\n name=newname;\n }",
"public final void setName(String name) {_name = name;}",
"private void setName(String nameIn){\r\n\t\tplayerName = nameIn;\r\n\t}",
"public void setName(String name) { this.name = name; }",
"public void setName(String name) { this.name = name; }",
"public void setName(String name) { this.name = name; }",
"public void setName(String name) { this.name = name; }",
"@Override\n\tpublic void setName(String name) {\n\t\t\n\t}",
"@Override\r\n public void setName(String name) {\n }",
"public void setName (String Name);",
"public void setName (String Name);",
"public void setName (String Name);",
"@Override\n public void setName(String name) {\n\n }",
"public void setName(String name){\n this.name = name;\n }",
"public void setName(String name){\n \t\tthis.name = name;\n \t}",
"public void setName (String newName)\n {\n this.name = newName; \n }",
"void setName(String name) {\r\n this.name = name;\r\n }",
"public void setName(String inName)\n {\n name = inName;\n }",
"public void setName(String name) {\n this.name = name;\n }",
"void setName(String name)\n {\n this.name = name;\n }",
"public void setName(String name){\n this.name = name;\n }",
"public void setName(String name){\n this.name = name;\n }",
"public void setName(String name){\n this.name = name;\n }",
"public void setName(String name){\n this.name = name;\n }",
"public void setName(String name){\n this.name = name;\n }",
"public void setName(String name){\n this.name = name;\n }",
"public void setName(String name){\n this.name = name;\n }",
"public void setName(String name){\r\n\t\tthis.name = name;\r\n\t}",
"public void setName(String name){\r\n\t\tthis.name = name;\r\n\t}",
"public void setName(String name){\r\n\t\tthis.name = name;\r\n\t}",
"public void setName(String inName)\n {\n\tname = inName;\n }",
"public void setName(String name)\n {\n this.name=name;\n }",
"public void setName(String n){ name=n; }",
"public void setName(String Name){\r\n name = Name;\r\n }",
"void setName(String name) {\n this.name = name;\n }",
"public void setName (String name) {\n this.name = name;\n }",
"public void setName (String name) {\n this.name = name;\n }",
"public void setName (String name) {\n this.name = name;\n }",
"public void setName(String val) {\n this.name = val;\n }",
"void setName(String name) {\n this.name = name;\n }",
"protected void setName(String name) {\r\n this.name = name;\r\n }",
"public void setName(String name)\n {\n _name = name;\n }",
"public void setName(String name){\n\t\tthis.name = name;\n\t}",
"public void setName(String name){\n\t\tthis.name = name;\n\t}",
"public void setName(String name){\n\t\tthis.name = name;\n\t}",
"public void setName(String name) {\t\t\r\n\t\tthis.name = name;\t\t\r\n\t}",
"public void setName(String name) {\n \tthis.name = name;\n }",
"public void setName(String name) {\n \tthis.name = name;\n }",
"public void setName(String newName) {\n this.name = newName;\n }",
"@Override\n\tpublic void setName(String arg0) {\n\n\t}",
"public void setPlayerName(String name){\n\t\tplayerName = name;\n\t\trepaint();\n\t}",
"public void setName(String name) {\r\n\t\tthis.name=name;\r\n\t}",
"public void setName(String name) {\n\t\tthis.name = name;\n\t\tthis.setText(name);\n\t}",
"public void setName(String name)\r\n\t{\t\t\r\n\t\tthis.name = name;\r\n\t}",
"public void setName(String newName){\n\n //assigns the value newName to the name field\n this.name = newName;\n }",
"@Override\n public void setName(String name) {\n this.name = name;\n }",
"@Override\n public void setName(String name) {\n this.name = name;\n }",
"public void setDPHgVorname(String value){\n\t\tthis.m_bIsDirty = (this.m_bIsDirty || (!value.equals(this.m_sDPHgVorname)));\n\t\tthis.m_sDPHgVorname=value;\n\t}",
"public void setName(String name) {\r\n this.name = name;\r\n }",
"public void setName(String name)\n {\n\tthis.name = name;\n }",
"protected void setName(String name) {\n this._name = name;\n }",
"@Override\r\n\tpublic void setName(String name) {\n\t\tthis.name = name;\r\n\t}",
"@Override\n public void setName(String name) {\n this.name = name;\n }",
"@Override\n public void setName(String name) {\n this.name = name;\n }",
"public void setName(String newName){\n name=newName;\n }",
"public void setName(String name)\r\n {\r\n\tthis.name = name;\r\n }",
"public void setName(String new_name) {\n\t\t_name = new_name;\n\t}",
"public void setName(String value) {\n this.name = value;\n }",
"public void setName (String name) {\n this.name = name;\n }",
"public void setName(String name)\r\n {\r\n this.name = name;\r\n }",
"public void setName(String name)\r\n {\r\n this.name = name;\r\n }",
"public void setName(String name)\r\n {\r\n this.name = name;\r\n }",
"public void setName(String name)\r\n {\r\n this.name = name;\r\n }",
"public void setName(String myName){\n this.name = myName;\n }",
"void setName(java.lang.String name);",
"void setName(java.lang.String name);",
"void setName(java.lang.String name);"
] | [
"0.70568824",
"0.70347524",
"0.7018254",
"0.69431806",
"0.69209886",
"0.68966657",
"0.68622714",
"0.6857023",
"0.68517697",
"0.6789002",
"0.678241",
"0.67692745",
"0.6767017",
"0.6744034",
"0.6735112",
"0.6727355",
"0.6724144",
"0.6709493",
"0.670756",
"0.6702991",
"0.66976905",
"0.66942227",
"0.66942227",
"0.66942227",
"0.66933084",
"0.66857874",
"0.66839147",
"0.6682975",
"0.6682975",
"0.6682975",
"0.6682975",
"0.66730356",
"0.6672758",
"0.66713285",
"0.66713285",
"0.66713285",
"0.66670966",
"0.66599137",
"0.6657777",
"0.66501206",
"0.6644475",
"0.66313124",
"0.6630968",
"0.6627139",
"0.6624675",
"0.6624675",
"0.6624675",
"0.6624675",
"0.6624675",
"0.6624675",
"0.6624675",
"0.66118884",
"0.66118884",
"0.66118884",
"0.6611708",
"0.66096103",
"0.6609302",
"0.6590129",
"0.6586088",
"0.65828973",
"0.65828973",
"0.65828973",
"0.6582652",
"0.6574302",
"0.6568888",
"0.6563529",
"0.65634537",
"0.65634537",
"0.65634537",
"0.6559632",
"0.65589184",
"0.65589184",
"0.6557987",
"0.655339",
"0.6550551",
"0.65322447",
"0.65259224",
"0.6525572",
"0.65178066",
"0.65170115",
"0.65170115",
"0.65161955",
"0.6512581",
"0.6507649",
"0.6506668",
"0.6505691",
"0.6503672",
"0.6503672",
"0.6503182",
"0.6498674",
"0.6498066",
"0.64959884",
"0.64942384",
"0.64923215",
"0.64923215",
"0.64923215",
"0.64923215",
"0.6489572",
"0.64883375",
"0.64883375",
"0.64883375"
] | 0.0 | -1 |
this method update the first Option Set's name | public void helper2(Automobile car, String newData) {
car.updateOptionSet(0, newData);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public synchronized void updateOptsetName(String oldname, String newname) {\n OptionSet optset = findOneOptSetByName(oldname);\n if (optset != null) {\n optset.setName(newname);\n } else {\n System.out.println(\"No optionSet named \" + oldname + \"in this model !!!\");\n }\n }",
"protected String getOptionSetName() {\n\t\treturn name;\n\t}",
"protected void setOptionSetName(String name) {\n\t\tthis.name = name;\n\t}",
"public synchronized void Update_A_OptionSet_By_Name_(String Model_Name, String Option_Set_Name,\n String newName)\n {\n try{\n\t\tif(Model_Name.equalsIgnoreCase(Model))\n\t\t{int k=Search_List(Option_Set_Name.toUpperCase(Locale.getDefault()));\n\t\t\tif(k>=0)\n\t\t\t\topset.get(k).setName(newName);\n\t\t}\n }\n\t\t\tcatch(ArrayIndexOutOfBoundsException e) {\n\t\t\t\tSystem.out.print(\"The index you are looking for is invalid\\n\");\n\t}\n\t}",
"public synchronized void setoptset(String name)\n {\n this.opset.add(new OptionSet(name.toUpperCase(Locale.getDefault())));\n }",
"public void updateOptionSetName(String modelName, String optionSetName, String newName){\n\t\tAutomobile auto= autoSet.readModel(modelName);\n\t\tauto.updateOptionSetName(optionSetName, newName);\n\t}",
"public void setName(String arg0) {\n\t\t\n\t}",
"public synchronized void UpdateManager(String ModelName, String Name){\n\t\tif(this.Model.equalsIgnoreCase(ModelName.toUpperCase(Locale.getDefault())))\n\t\t\t\topset.add( new OptionSet(Name.toUpperCase(Locale.getDefault())));\n\t}",
"public synchronized void updateOptsetOption(String name, ArrayList<OptionSet.Option> options) {\n OptionSet optionSet = findOneOptSetByName(name);\n if (optionSet != null) {\n optionSet.setOpt(options);\n } else {\n System.out.println(\"No optionSet named \" + name + \"in this model !!!\");\n }\n }",
"private void setName(){\r\n\t\tString tagString = new String();\r\n\t\tfor (String k : tags.keySet()){\r\n\t\t\ttagString += \"@\" + k;\r\n\t\t}\r\n\t\tString newName = originalName + tagString +\".\"+ extension;\r\n\t\tif (!newName.equals(name)){\r\n\t\t\tremovePrevNames(newName); //if the new name is a previous name\r\n\t\t\taddPrevNames(name);\r\n\t\t\tupdateLog(newName);\r\n\t\t\tname = newName;\r\n\t\t\t//notify the tag observer\r\n\t\t\tsetChanged();\r\n\t\t\tnotifyObservers();\r\n\t\t\tclearChanged();\r\n\t\t}\r\n\t}",
"private void setName() {\n\t\t//MAKE SURE NOT TO GET ACCIDENTAL RECURSION HERE\n\t\t//DO NOT JUST MAKE A NEW TRIAD AND COMPARE TO CURRENT TRIAD\n\t\t//UNLESS ??? MAYBEDON\"T PUT SET NAME IN THE CONSTRUCTOR?\n\t\t//SIMILAR PROBLEM TO SETINVERSION\n\t\t\n\t\t//major, minor, diminished, augmented\n\t\t//this.name = name;\n\t}",
"public void setName(String name1) {\r\n this.name = name1;\r\n }",
"public void updateDropDownList(String newName) {\r\n selectDatasetList.clear();\r\n selectDatasetList.addItem(\"Select Dataset\");\r\n selectSubDatasetList.clear();\r\n\r\n selectSubDatasetList.addItem(\"Select Sub-Dataset\");\r\n selectSubDatasetList.setVisible(false);\r\n getDatasetsList(newName);//get available dataset names\r\n SelectionManager.Busy_Task(false, true);\r\n }",
"public static String setName()\n {\n read_if_needed_();\n \n return _set_name;\n }",
"public synchronized void setOption(OptionSet optSet_Temp,String name,float price){\n optSet_Temp.Increase_Option_Manager(name.toUpperCase(Locale.getDefault()), price);\n }",
"public void setSelectedName(String s) {\n\t\tuName = s;\n\t}",
"private void editName() {\n Routine r = list.getSelectedValue();\n\n String s = (String) JOptionPane.showInputDialog(\n this,\n \"Enter the new name:\",\n \"Edit name\",\n JOptionPane.PLAIN_MESSAGE,\n null, null, r.getName());\n\n if (s != null) {\n r.setName(s);\n }\n }",
"public void setName(String name0){\n\t\tname = name0;\n\t}",
"public void setName(String new_name){\n this.name=new_name;\n }",
"protected String getOptionName() {\n\t\t\treturn name;\n\t\t}",
"void setName(String name_);",
"@Override\n\tpublic void setName(String arg0) {\n\n\t}",
"private void setName(java.lang.String name) {\n System.out.println(\"setting name \"+name);\n this.name = name;\n }",
"public void setName(String string) {\n\t\t\n\t}",
"void setName(String s);",
"public static void set_SetName(String v) throws RuntimeException\n {\n UmlCom.send_cmd(CmdFamily.javaSettingsCmd, JavaSettingsCmd._setJavaSetNameCmd, v);\n UmlCom.check();\n \n _set_name = v;\n }",
"public synchronized ArrayList<String> getNameofOptionset()\n {\n \t ArrayList<String> optionsetNames =new ArrayList<String>();\n for (OptionSet op: this.getOpset()){\n optionsetNames.add(op.getName());}\n return optionsetNames;\n }",
"public void setName (String Name);",
"public void setName (String Name);",
"public void setName (String Name);",
"private void setNameAutomatic(){\n\t}",
"void setName(String strName);",
"public void setName(String name){this.name=name;}",
"public void setNames() {\n\t\tPlayer1 = \"COMPUTER\";\n\t\tPlayer2 = JOptionPane.showInputDialog(null, \"Enter your Name:\");\n\t\tnames_set = true;\n\t}",
"private void setChangeName() {\n\t\tChangeNameOpt.add(\"-cn\");\n\t\tChangeNameOpt.add(\"/cn\");\n\t\tChangeNameOpt.add(\"changename\");\n\n\t}",
"public void setName(String name) {\n if (!name.equals(\"\")) {\r\n this.name = name;\r\n }\r\n\r\n\r\n\r\n\r\n }",
"@Override\r\n public void setName(String name) {\n }",
"public void setName(String newname) {\n name=newname;\n }",
"protected void setOptionName(String option) {\n\t\t\tthis.name = option;\n\t\t}",
"public void setName(String newname){\n name = newname; \n }",
"@Override\n public void setName(String name) {\n \n }",
"public synchronized void IncreaseManager( String Name)\n\t{\n\t\topset.add(new OptionSet(Name));\n\t\tMaxIndex+=1;\t//Decrease TotalIndex 1\n\t}",
"public void setOptionChoice(String setName, String optionName) {\n for (int i = 0; i < this.optionSet.size(); ++i) {\n if (optionSet.get(i).getName().equals(setName)) {\n optionSet.get(i).setOptionChoice(optionName);\n }\n }\n }",
"public OrderedSet (String setName) {\n initialize();\n name = setName;\n }",
"@Override\n\tpublic void setName(String name) {\n\t\t\n\t}",
"void setName(String name);",
"void setName(String name);",
"void setName(String name);",
"void setName(String name);",
"void setName(String name);",
"void setName(String name);",
"public void setName(String n);",
"public void setName(String name);",
"public void setName(String name);",
"public void setName(String name);",
"public void setName(String name);",
"public void setName(String name);",
"public void setName(String name);",
"public void setName(String name);",
"public void setName(String name);",
"public void setName(String name);",
"public void setName(String name);",
"public void setName(String name);",
"public String Get_Option_User_Choice(String Op_Set_Name)\n {\n for(OptionSet i: opset) {\n if(Op_Set_Name.equalsIgnoreCase(i.getName()))\n return (i.User_Choice_Name()); \n } \n return null;\n }",
"public void setName(java.lang.String value);",
"public void setName(java.lang.String value);",
"public void adjustName() {\n Item item = getItem();\n if (!item.isFixedName()) {\n if (item.getSchemaComponent().type() == SchemaBase.SEQUENCE_TYPE) {\n if (m_values.size() > 0) {\n Item childitem = ((DataNode)m_values.get(0)).getItem();\n if (item != childitem) {\n item.setName(childitem.getEffectiveName());\n }\n }\n }\n }\n }",
"public void setName(String name){this.name = name;}",
"@Override\n public void setName(String name) {\n\n }",
"public void setName(String name) {\n fName= name;\n }",
"public synchronized void setOptionChoice(String optionSetName, String OptionName){\n this.findOptionSetReturnOptionSet(optionSetName).setChoice\n (this.findOptionSetReturnOptionSet(optionSetName).findReturnOption(OptionName));\n }",
"public void setName(String newValue);",
"public void setName(String newValue);",
"public void doChangeAlbumName()\n/* */ {\n/* 73 */ AlbumDTO changed = this.galleryManager.saveAlbum(this.selectedAlbum);\n/* 74 */ for (AlbumDTO dto : this.albumList)\n/* */ {\n/* 76 */ if (dto.getId().equals(changed.getId()))\n/* */ {\n/* 78 */ dto.setName(changed.getName());\n/* 79 */ break;\n/* */ }\n/* */ }\n/* */ }",
"public final void setName(String name) {_name = name;}",
"public void setName(String s) {\n\t\t\n\t\tname = s;\n\t}",
"@Override\n protected void commitNameChange(PropertyChangeEvent evt) {\n AttributeItemFigure figure = getFigure();\n figure.updateLabels();\n setSelected(EditPart.SELECTED_PRIMARY);\n figure.revalidate();\n }",
"public void setName(String name)\r\n/* 29: */ {\r\n/* 30:23 */ this.name = name;\r\n/* 31: */ }",
"public void setName(String n){ name=n; }",
"public void setName(String newname)\n {\n name = newname;\n \n }",
"private void updateName(Widget sender){\r\n\t\tint index = getWidgetIndex(sender) - 1;\r\n\t\tTaskParam param = taskDef.getParamAt(index);\r\n\t\tparam.setName(((TextBox)sender).getText());\r\n\t\ttaskDef.setDirty(true);\r\n\t}",
"public void setName(String name){\n this.name = name;\n }",
"public void setName(String Name){\r\n name = Name;\r\n }",
"@Override\r\n public PsiElement setName(@NonNls @NotNull String name) throws IncorrectOperationException {\r\n throw new IncorrectOperationException(\"Set name is not implemented\");\r\n }",
"public void setName(String name) \n {\n this.name = name;\n }",
"public void setName(String name)\n {\n this.name=name;\n }",
"public void setName(String name){\r\n this.name = name;\r\n }",
"public void setName(String name){\r\n this.name = name;\r\n }",
"public void setName(String name){\r\n this.name = name;\r\n }",
"private String setNameForUpdate(ArrayList<String> names) {\n String retString = \"\";\n StringBuilder strB = new StringBuilder();\n for (int i = 0; i < names.size(); i++) {\n strB.append(\"(\" + names.get(i) + \") = ? ,\");\n }\n strB.deleteCharAt(strB.length() - 1);\n retString = strB.toString();\n return retString;\n }",
"public void setName(String name) { this.name = name; }",
"public void setName(String name) { this.name = name; }",
"public void setName(String name) { this.name = name; }",
"public void setName(String name) { this.name = name; }",
"void setName(String name) {\r\n this.name = name;\r\n }",
"void setName(java.lang.String name);",
"void setName(java.lang.String name);",
"void setName(java.lang.String name);",
"protected OptionSet(String name) {\n\t\tthis.name = name;\n\t\toptions = new ArrayList<Option>();\n\t}",
"void setName(String name)\n\t{\n\t\t\tthis.name = name;\n\t}",
"public void setName (String n){\n\t\tname = n;\n\t}"
] | [
"0.73147136",
"0.6930462",
"0.6683222",
"0.6630501",
"0.6413162",
"0.6317221",
"0.6190588",
"0.615047",
"0.61213845",
"0.6085415",
"0.608414",
"0.60576326",
"0.60418826",
"0.60117275",
"0.59928894",
"0.59671885",
"0.59662783",
"0.5945524",
"0.5935786",
"0.5928074",
"0.59280723",
"0.59068364",
"0.58779347",
"0.58526415",
"0.5848325",
"0.5844146",
"0.5837705",
"0.5817329",
"0.5817329",
"0.5817329",
"0.5812306",
"0.57993037",
"0.5785556",
"0.5772756",
"0.5762531",
"0.57553285",
"0.57424706",
"0.5725703",
"0.57185316",
"0.5718337",
"0.57115525",
"0.5703858",
"0.57023084",
"0.5696746",
"0.5696498",
"0.56944805",
"0.56944805",
"0.56944805",
"0.56944805",
"0.56944805",
"0.56944805",
"0.56734157",
"0.5667312",
"0.5667312",
"0.5667312",
"0.5667312",
"0.5667312",
"0.5667312",
"0.5667312",
"0.5667312",
"0.5667312",
"0.5667312",
"0.5667312",
"0.56670517",
"0.5663663",
"0.5663663",
"0.56582326",
"0.5656555",
"0.5654832",
"0.5651579",
"0.5649274",
"0.5626883",
"0.5626883",
"0.5624491",
"0.5612037",
"0.56086195",
"0.5607861",
"0.560606",
"0.560059",
"0.5600343",
"0.55975497",
"0.55905384",
"0.5576837",
"0.5571956",
"0.5562611",
"0.55558985",
"0.555308",
"0.555308",
"0.555308",
"0.5543016",
"0.55403215",
"0.55403215",
"0.55403215",
"0.55403215",
"0.5527777",
"0.5516642",
"0.5516642",
"0.5516642",
"0.5501352",
"0.54963136",
"0.5494234"
] | 0.0 | -1 |
update first option of the first optionset's price this method will not be synchronized to show data corruption | public void helper3(Automobile car, String incrementAmount) {
car.setBasePrice(car.getBasePrice() + Integer.parseInt(incrementAmount));
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public synchronized void setOption(OptionSet optSet_Temp,String name,float price){\n optSet_Temp.Increase_Option_Manager(name.toUpperCase(Locale.getDefault()), price);\n }",
"public synchronized void UpdateAOption(String Model_Name, String Option_Set_Name ,\n\t\t\t\t\t\t\t\t\t\t\tString Option_Name,float New_Price)\n\t{\n try{\n\t\tif(Model_Name.equalsIgnoreCase(Model))\n\t\t{\n\t\t\tint k=Search_List(Option_Set_Name.toUpperCase(Locale.getDefault()));\n\t\t\tif( k>=0)\n\t\t\t\topset.get(k).Update_Option_Price(Option_Name, New_Price);\n\t\t}\n }\n\t\t\tcatch(ArrayIndexOutOfBoundsException e) {\n\t\t\t\tSystem.out.print(\"The index you are looking for is invalid\\n\");\n\t}\n\t}",
"protected void updateOptionPrice(String optionName, float price)\n\t\t\tthrows AutoException {\n\t\tif (getOption(optionName) == null) {\n\t\t\tthrow new AutoException(CustomExceptionEnum.OptionNotFound);\n\t\t} else {\n\t\t\tgetOption(optionName).setPrice(price);\n\t\t}\n\t}",
"public void updateOptionPrice(String modelName, String optionName, String option, float newPrice){\n\t\tAutomobile auto= autoSet.readModel(modelName);\n\t\tauto.updateOptionPrice(optionName, option, newPrice);\n\t}",
"private void setInitial_itemPrice()\n {\n\n calcTotalPrice(selectedItemQuantity, itemPrice);\n if(label_totalPrice.getText().equals(\"\"))\n {\n label_totalPrice.setText(\"\" + itemPrice);\n }\n\n }",
"public void setOptionPrice(double optionPrice)\n {\n this.optionPrice = optionPrice;\n }",
"public void setPricePerSquareFoot(double newPricePerSquareFoot){\nif(newPricePerSquareFoot > 0){\npricePerSquareFoot = newPricePerSquareFoot;\n}\n}",
"public void setPrice(double newPrice) {\r\n price = newPrice;\r\n }",
"public void setPrice(double price){this.price=price;}",
"private void updatePrice() {\r\n\t\t// TODO Auto-generated method stub\r\n\t\tfor(int i = first;i<last;i++){\r\n\t\t\tProduct product = products.get(i);\r\n\t\t\tproduct.setPrivce(product.getPrivce()*(1+increment));\r\n\t\t}\r\n\t\t\r\n\t}",
"public void setPriceListOld (BigDecimal PriceListOld);",
"public void setPrice(double p)\r\n\t{\r\n\t\tprice = p;\r\n\t}",
"@Override\n\tpublic void setPrice(double price) {\n\t\tconstantPO.setPrice(price);\n\t}",
"public void editProductPrice(String price){\r\n\t\twdlib.waitForElement(getProductText());\r\n\t\tif(getProductText().getText().equals(\"None Included\")){\r\n\t\t\tselPproductBtn.click();\r\n\t\t\tProductsPage pdpage=new ProductsPage();\r\n\t\t\tpdpage.selectProducts();\r\n\t\t\tdriver.navigate().refresh();\r\n\t\t\tselProductOpt.click();\r\n\t\t\twdlib.waitForElement(getProductText());\r\n\t\t\teditBtn.click();\r\n\t\t\taddNewPrice(price);\r\n\t\t}\r\n\t\telse{\r\n\t\t\t\r\n\t\t\teditBtn.click();\r\n\t\t\taddNewPrice(price);\r\n\t\t}\r\n\t\tdriver.navigate().refresh();\r\n\t}",
"public void changePrices()\n {\n String publisher = (String) publishers.getSelectedItem();\n if (publisher.equals(\"Any\"))\n {\n result.setText(\"I am sorry, but I cannot do that.\");\n return;\n }\n try\n { \n if (priceUpdateStmt == null)\n priceUpdateStmt = conn.prepareStatement(priceUpdate);\n priceUpdateStmt.setString(1, priceChange.getText());\n priceUpdateStmt.setString(2, publisher);\n int r = priceUpdateStmt.executeUpdate();\n result.setText(r + \" records updated.\"); \n } \n catch (SQLException e)\n {\n result.setText(\"\");\n while (e != null)\n {\n result.append(\"\" + e);\n e = e.getNextException();\n }\n }\n }",
"public void refreshData(float price) {\n if (price <= 0 || price == mLastPrice) {\n return;\n }\n mLastPrice = price;\n CombinedData data = mChartPrice.getData();\n if (data == null) return;\n LineData lineData = data.getLineData();\n if (lineData != null) {\n ILineDataSet set = lineData.getDataSetByIndex(0);\n if (set.removeLast()) {\n set.addEntry(new Entry(set.getEntryCount(), price));\n }\n }\n\n mChartPrice.notifyDataSetChanged();\n mChartPrice.invalidate();\n }",
"@Override\r\n\tpublic void setPrice(double p) {\n\t\tprice = p;\r\n\t}",
"public void editServicePrice(String price){\r\n\t\twdlib.waitForElement(getServiceText());\r\n\t\tif(getServiceText().getText().equals(\"None Included\")){\r\n\t\t\tselServiceBtn.click();\r\n\t\t\tServicesPage srvpage=new ServicesPage();\r\n\t\t\tsrvpage.selectServices();\r\n//\t\t\tdriver.navigate().refresh();\r\n\t\t\tselServicOpt.click();\r\n\t\t\twdlib.waitForElement(getServiceText());\r\n\t\t\teditService.click();\r\n\t\t\taddNewPrice(price);\r\n\t\t}\r\n\t\telse{\r\n\t\t\teditService.click();\r\n\t\t\taddNewPrice(price);\r\n\t\t}\r\n\t\tdriver.navigate().refresh();\r\n\t}",
"public synchronized boolean creatOneOption(String optsetName, String optionName, float price) throws AutoException {\n OptionSet optSet = findOneOptSetByName(optsetName);\n boolean ret = false;\n if (optSet != null) {\n OptionSet.Option opt = optSet.findOneOptionByName(optionName);\n if (opt != null) { //option exists,update its price\n opt.setPrice(price);\n ret = true;\n } else {\n ArrayList<OptionSet.Option> options = optSet.getOpt();\n for (int i = 0; i < options.size(); ++i) {\n if (\"\".equals(options.get(i).getName())) {\n options.set(i, new OptionSet().new Option(optionName, price));\n ret = true;\n break;\n }\n }\n if (!ret) {\n throw new AutoException(4);\n }\n }\n } else {\n System.out.println(\"OptSet not exists :\" + optsetName);\n return false;\n }\n return false;\n }",
"public double getOptionPrice()\n {\n return optionPrice;\n }",
"public void setPrice(Double price);",
"public void setPrice(double price)\n {\n this.price = price;\n }",
"public void setPrice(double price)\n {\n this.price = price;\n }",
"public void setPrice(double price) {\r\n this.price = price;\r\n }",
"public void setPrice(double price) {\r\n this.price = price;\r\n }",
"public void setPrice(double price) {\r\n this.price = price;\r\n }",
"public void setPrice(double price) {\n\t\tif(price > 0 )\n\t\t\tthis.price=price;\n\t}",
"public void setPrice(double price) {\n this.price = price;\n }",
"public void setPrice(double price) {\n this.price = price;\n }",
"public void setPrice(double price) {\n this.price = price;\n }",
"public void setPrice(double price) {\n this.price = price;\n }",
"public void setPrice(double price) {\n this.price = price;\n }",
"public void setPrice(double price) {\n this.price = price;\n }",
"public void setPrice(double price) {\n this.price = price;\n }",
"@Override\n\tpublic void setPrice(int price) {\n\t\t\n\t}",
"public void setPrice(Double price) {\r\n this.price = price;\r\n }",
"public void setPrice(int newPrice){\n productRelation.setCost(newPrice);\n }",
"public void setPrice(double p){\n\t\t// store into the instance variable price the value of the parameter p\n\t\tprice = p;\n\t}",
"public void setPriceLimitOld (BigDecimal PriceLimitOld);",
"protected void setPrice(DukatAmount price){\r\n\t\tif(canHaveAsPrice(price))\r\n\t\t\tthis.price = price;\r\n\t}",
"public void setPrice(double price) \n\t{\n\t\tthis.price = price;\n\t}",
"public void setOriginalPrice(Float OriginalPrice) {\n this.OriginalPrice = OriginalPrice;\n }",
"public void setPrice(double price) {\r\n\t\tthis.price = price;\r\n\t}",
"public void setPrice(double price) {\r\n\t\tthis.price = price;\r\n\t}",
"public void setPrice(double p) {\n\t\tprice = p;\n\t}",
"public void setPrice(double price) {\n this.price = price;\n if (this.price < 0) {\n this.price = 0;\n }\n }",
"public void increasePrice() {\n //price doubled\n itemToSell.setBuyPrice(itemToSell.getBuyPrice() * 2);\n }",
"public void setPrice(int price) {\n this.price = (double)price;\n }",
"public void setPrice(Double price) {\n this.price = price;\n }",
"public void setPrice(Double price) {\n this.price = price;\n }",
"public void setPrice(BigDecimal price) {\r\n this.price = price;\r\n }",
"public void setPrice(BigDecimal price) {\r\n this.price = price;\r\n }",
"@Override\n\tdouble updateTotalPrice() {\n\t\treturn 0;\n\t}",
"public void setPrice(int price) {\r\n this.price = price;\r\n }",
"public void setPrice(BigDecimal price) {\n this.price = price;\n }",
"public void setPrice(BigDecimal price) {\n this.price = price;\n }",
"public void setFirst(double value) {\n this.first = value;\n }",
"public void updatePrice(){\n\t\tprice = 0;\n\t\tfor (ParseObject selectedItem : selectedItems){\n\t\t\tprice += selectedItem.getInt(\"price\");\n\t\t}\n\n\t\tTextView orderTotal = (TextView) findViewById(R.id.orderTotal);\n\t\torderTotal.setText(\"$\" + price + \".00\");\n\t}",
"@Override\n\tpublic void setPrice() {\n\t\tprice = 24.99;\n\n\t}",
"public void setPrice(int price) {\n this.price = price;\n }",
"public void setPrice(double price) {\n\t\tthis.price = price;\n\t}",
"public void setPrice(double price) {\n\t\tthis.price = price;\n\t}",
"public void setPrice(double price) {\n\t\tthis.price = price;\n\t}",
"@Override\n public void changePrice(Product product, int position) {\n changeProductPrice(product, -1);\n }",
"public void setPriceLastOrd (BigDecimal PriceLastOrd);",
"public void updateconsumption(HealthSearch healthSearcher,int amount,String id, String time,double price) {\n\t\ttry {\n\t\t\tConnection connection = this.getConnection();\n\t\t\tPreparedStatement stmt = connection.prepareStatement(\"SELECT protein, energy, fiber,price FROM diet_conclusion where id = ? AND date = ?\");\n\t\t\tstmt.setString(1,id);\n\t\t\tstmt.setString(2,time.substring(0,8));\n\t\t\tResultSet rs = stmt.executeQuery();\n\t\t\tif(rs.next()) {\n\t\t\t\tdouble previous_energy =0;\n\t\t\t\tdouble previous_fiber =0;\n\t\t\t\tdouble previous_protein =0;\n\t\t\t\tdouble previous_price = 0;\n\t\t\t\tdouble current_protein = 0;\n\t\t\t\tdouble current_energy =0;\n\t\t\t\tdouble current_fiber = 0;\n\t\t\t\tdouble current_price = 0;\n\t\t\t\tprevious_protein = rs.getDouble(1);\n\t\t\t\tprevious_energy = rs.getDouble(2);\n\t\t\t\tprevious_fiber = rs.getDouble(3);\n\t\t\t\tprevious_price = rs.getDouble(4);\n\n\t\t\t\tcurrent_price = price + previous_price;\n\n\n\t\t\t\tif( !healthSearcher.getProtein().equals(\"0\")) {\n\t\t\t\t\t current_protein = previous_protein + Double.parseDouble(healthSearcher.getProtein())*amount/100.0;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tcurrent_protein = previous_protein;\n\n\t\t\t\t}\n\t\t\t\tif( !healthSearcher.getEnergy().equals(\"0\")) {\n\t\t\t\t\tcurrent_energy = previous_energy + Double.parseDouble(healthSearcher.getEnergy())*amount/100.0;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tcurrent_energy = previous_energy;\n\t\t\t\t}\n\t\t\t\tif( !healthSearcher.getFiber().equals(\"0\")) {\n\t\t\t\t\tcurrent_fiber = previous_fiber + Double.parseDouble(healthSearcher.getFiber())*amount/100.0;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tcurrent_fiber = previous_fiber;\n\t\t\t\t}\n\t\t\t\tPreparedStatement stmt2 = connection.prepareStatement(\n\t\t\t\t\"UPDATE diet_conclusion SET protein = ?, energy = ?, fiber = ?, price=? WHERE id = ? AND date = ?;\");\n\n\t\t\t\tstmt2.setDouble(1, current_protein);\n\t\t\t\tstmt2.setDouble(2, current_energy);\n\t\t\t\tstmt2.setDouble(3, current_fiber);\n\t\t\t\tstmt2.setDouble(4, current_price);\n\t\t\t\tstmt2.setString(5, id);\n\t\t\t\tstmt2.setString(6, time.substring(0,8));\n\t\t\t\tstmt2.execute();\n\t\t\t\tstmt2.close();\n\t\t\t}\n\t\t\telse {\n\t\t\t\tPreparedStatement stmt1 = connection.prepareStatement(\n\t\t\t\t\t\t\"INSERT INTO diet_conclusion VALUES(?,?,?,?,?,?)\");\n\t\t\t\tstmt1.setString(1,id);\n\t\t\t\tstmt1.setString(2, time.substring(0,8));\n\t\t\t\tstmt1.setDouble(3, Double.parseDouble(healthSearcher.getProtein())*amount/100.0);\n\t\t\t\tstmt1.setDouble(4, Double.parseDouble(healthSearcher.getEnergy())*amount/100.0);\n\t\t\t\tstmt1.setDouble(5, Double.parseDouble(healthSearcher.getFiber())*amount/100.0);\n\t\t\t\tstmt1.setDouble(6, price);\n\t\t\t\tstmt1.execute();\n\t\t\t\tstmt1.close();\n\t\t\t}\n\t\t\tstmt.close();\n\t\t\trs.close();\n\t\t\tconnection.close();\n\t\t} catch (Exception e) {\n\t\t\tSystem.out.println(e);\n\t\t}\n\t}",
"public synchronized void IncreaseAOption(String Name,int Price,int Choice)\n\t{\n\t\t\topset.get(Choice).Increase_Option_Manager( Name, Price);\n\t}",
"public void changePrice(Product p, int price){\r\n\t\tp.price = price;\r\n\t}",
"public void setPrice(int price) {\n\tthis.price = price;\n}",
"public void setPotatoesPrice(double p);",
"public void setPrice(java.math.BigDecimal price) {\n this.price = price;\n }",
"public void reset() {\n price = 0;\n itemNumbers.clear();\n selectedOptions.clear();\n setupGUI();\n }",
"public void setPrice(float itemPrice) \n {\n price = itemPrice;\n }",
"public void setPrice(double value) {\n this.price = value;\n }",
"public void setPrice(double value) {\n this.price = value;\n }",
"@Override\n public void onPriceChange(String price) {\n poll.setPrice(YelpPriceLevel.fromYelpString(price));\n }",
"public void setPrice(final BigDecimal price) {\n this.price = price;\n }",
"public static void setPrice() {\n double summe = 0.0;\n for (Object obj : dlm.getDisplayedArtikel()) {\n if (obj instanceof Article) {\n Article art = (Article) obj;\n if (!art.isIsAbfrage()) {\n if (((art.isJugendSchutz() && art.isJugendSchutzOk())) || !art.isJugendSchutz()) {\n if (art.isEloadingAmmountOk() && !art.isPriceZero()) {\n summe += ((Article) ((obj))).getPreis() * ((Article) ((obj))).getAmount();\n }\n }\n }\n } else if (obj instanceof Karte) {\n Karte card = (Karte) obj;\n summe += card.getAufladung() / 100;\n }\n }\n for (Object obj : dlm.getRemovedObjects()) {\n if (obj instanceof Article) {\n if (!((Article) ((obj))).isStorno_error()) {\n summe -= ((Article) ((obj))).getPreis() * ((Article) ((obj))).getAmount();\n }\n } else if (obj instanceof Karte) {\n Karte card = (Karte) obj;\n summe -= card.getAufladung() / 100;\n }\n }\n if (Math.round(summe) == 0) {\n summe = 0;\n }\n if (GUIOperations.isTraining()) {\n summe += 1000;\n }\n tfSumme.setText(String.format(\"%.2f\", summe));\n }",
"@Test\r\n public void testSetStartPrice() {\r\n System.out.println(\"setStartPrice\");\r\n double startPrice = 0.0;\r\n \r\n instance.setStartPrice(startPrice);\r\n assertEquals(startPrice, instance.getStartPrice(), 0.0);\r\n \r\n }",
"public double Get_Option_User_Choice_Price(String Op_Set_Name)\n {\n for(OptionSet i: opset) {\n if(Op_Set_Name.equalsIgnoreCase(i.getName()))\n return (i.User_Choice_Price()); \n } \n return 0;\n }",
"public void setPrice(double price) \n\t{\n\t\tthis.price = price * quantity;\n\t}",
"public void setPriceEntered (BigDecimal PriceEntered);",
"public void setPrice(Float price) {\r\n this.price = price;\r\n }",
"private void changePrice() {\n\t\tint sic_idHolder; // declares sic_idHolder\n\t\tdouble priceHolder; // declares priceHolder\n\t\t\n\t\tSystem.out.println(\"Please enter the SIC-ID of the book you'd like to change the price of:\");\n\t\tsic_idHolder = scan.nextInt();\n\t\tscan.nextLine();\n\t\t\n\t\tif(inventoryObject.cardExists(sic_idHolder)) { // checks to see if card exists\n\t\t\tSystem.out.println(\"Please enter the new price of the book:\");\n\t\t\tpriceHolder = scan.nextDouble();\n\t\t\tscan.nextLine();\n\t\t\tif(priceHolder < 0) { // checks to see if priceHolder is negative\n\t\t\t\tSystem.out.println(\"The price cannot be below zero\\n\");\n\t\t\t\tgetUserInfo();\n\t\t\t}\n\t\t\tinventoryObject.changePrice(sic_idHolder, priceHolder);\n\t\t\tgetUserInfo();\n\t\t}\n\t\telse {\n\t\t\tSystem.out.println(\"The ID you entered does not exist\\n\");\n\t\t\tgetUserInfo();\n\t\t}\n\t}",
"@Override\n\tpublic void doUpdate(SellOfer model, HttpServletRequest request,\n\t\t\tHttpServletResponse response) {\n\t\t if(StringUtil.isEmpty(model.getPrice())){\n\t\t\t\t model.setPrice(\"0\");\n\t\t\t }\n\t\t\t double dprice =Double.parseDouble(model.getPrice());\n\t\t BigDecimal bg = new BigDecimal(dprice/10000);\n\t\t double f1 = bg.setScale(2, BigDecimal.ROUND_HALF_UP).doubleValue();\n\t\t model.setPrice(f1+\"\");\n\t\t model.setSource(\"001\");\n\t\t model.setSellContent(\"\");\n\t\tsuper.doUpdate(model, request, response);\n\t}",
"protected void setOption(String optionName, float price) {\n\t\toptions.add(new Option(optionName, price));\n\t}",
"public void setPriceListEntered (BigDecimal PriceListEntered);",
"public void setPriceActual (BigDecimal PriceActual);",
"public void setPrice(Double price) {\n\t\tthis.price = price;\n\t}",
"public void setPrice(double x){\n\t\t\tprice = x;\t\n\t\t}",
"public void setPrice(Float price) {\n this.price = price;\n }",
"public void setPriceStdOld (BigDecimal PriceStdOld);",
"public void setPrice(Integer price) {\r\n this.price = price;\r\n }",
"public void setPrice(Integer price) {\r\n this.price = price;\r\n }",
"public void setStartprice(Double startprice) {\r\n this.startprice = startprice;\r\n }",
"protected float getChoicePrice() {\n\t\treturn choiceOption.getPrice();\n\t}",
"public void setPrice(float price) {\n this.price = price;\n }",
"public void setPrice(float price) {\n this.price = price;\n }",
"@Test\n public void testSetStartingPrice() {\n service.setStartingPrice(2000.0F);\n assertEquals(2000.0F, service.getStartingPrice(), 0.001);\n \n }",
"public void setpPrice(double pPrice) {\n this.pPrice = pPrice;\n }",
"public void setPriceList (BigDecimal PriceList);"
] | [
"0.6428255",
"0.6356542",
"0.6230379",
"0.61979765",
"0.61315066",
"0.599022",
"0.5964033",
"0.5938283",
"0.58229434",
"0.58044696",
"0.57786983",
"0.5775246",
"0.57608885",
"0.57402027",
"0.57337946",
"0.5728572",
"0.5713716",
"0.57077533",
"0.5707252",
"0.56915724",
"0.5662597",
"0.56544274",
"0.56387717",
"0.5638226",
"0.5638226",
"0.5638226",
"0.56123316",
"0.5598979",
"0.5598979",
"0.5598979",
"0.5598979",
"0.5598979",
"0.5598979",
"0.5598979",
"0.5582291",
"0.5570143",
"0.5563801",
"0.556233",
"0.5560413",
"0.55579793",
"0.55560416",
"0.55543387",
"0.5543285",
"0.5543285",
"0.55373037",
"0.55366105",
"0.55264646",
"0.5522388",
"0.5499632",
"0.5499632",
"0.5499061",
"0.5499061",
"0.5497437",
"0.54886043",
"0.5486258",
"0.5486258",
"0.5478457",
"0.5469201",
"0.5452279",
"0.54417914",
"0.5439488",
"0.5439488",
"0.5439488",
"0.5437034",
"0.5433574",
"0.54319364",
"0.54238915",
"0.54178554",
"0.5416201",
"0.54127926",
"0.54053783",
"0.54037356",
"0.5402413",
"0.54022694",
"0.54022694",
"0.53815186",
"0.53784716",
"0.53769535",
"0.53751177",
"0.5368998",
"0.53657365",
"0.5362156",
"0.5359801",
"0.5356105",
"0.5351578",
"0.53489566",
"0.5340547",
"0.5333834",
"0.53302246",
"0.5319388",
"0.5314375",
"0.5309077",
"0.5304468",
"0.5304468",
"0.52994627",
"0.5298887",
"0.5290539",
"0.5290539",
"0.52901644",
"0.52836597",
"0.52766037"
] | 0.0 | -1 |
Handles the HTTP POST method. | @Override
protected void doPost(HttpServletRequest request, HttpServletResponse response)
throws ServletException, IOException {
String acc = request.getParameter("acc");
String bank = request.getParameter("bank");
String email = request.getParameter("email");
Double txR = Math.random();
String txRef = txR.toString();
RaveConstant.ENVIRONMENT = Environment.STAGING;
RaveConstant.PUBLIC_KEY = "FLWPUBK-d8369e6826011f8a1f9f6c7c14a09b80-X";
RaveConstant.SECRET_KEY = "FLWSECK-8abf446c71a58aaa858323f3a9ed156b-X";
try {
AccountCharge ch = new AccountCharge();
ch.setAccountbank(bank)
.setAccountnumber(acc)
.setEmail(email)
.setTxRef(txRef)
.setAmount("2000")
.setCountry("NG")
.setCurrency("NGN");
JSONObject charge = ch.chargeAccount();
System.out.println(charge);
JSONObject data = (JSONObject) charge.get("data");
String response_code = (String) data.get("chargeResponseCode");
if (charge.get("status").equals("success")) {
{
if (response_code.equals("02")) {
String flw = (String) data.get("flwRef");
HttpSession session = request.getSession(true);
session.setAttribute("flwRef", flw);
session.setAttribute("payload", ch);
response.sendRedirect("Otp");
return;
}
else if (response_code.equals("00")) {
response.sendRedirect("Success");
return;
}
}
} else {
String message = (String) charge.get("message");
System.out.println(message);
HttpSession session = request.getSession(true);
session.setAttribute("message", message);
response.sendRedirect("401");
return;
}
} catch (JSONException ex) {
}
doGet(request, response);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@Override\n\tpublic void doPost(Request request, Response response) {\n\n\t}",
"@Override\n protected void doPost(HttpServletRequest req, HttpServletResponse resp) {\n }",
"public void doPost( )\n {\n \n }",
"@Override\n public String getMethod() {\n return \"POST\";\n }",
"public String post();",
"@Override\n\tpublic void doPost(HttpRequest request, AbstractHttpResponse response)\n\t\t\tthrows IOException {\n\t\t\n\t}",
"@Override\n public String getMethod() {\n return \"POST\";\n }",
"public ResponseTranslator post() {\n setMethod(\"POST\");\n return doRequest();\n }",
"protected void doPost(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response) throws javax.servlet.ServletException, java.io.IOException {\n }",
"public void doPost(HttpServletRequest req, HttpServletResponse resp)\n\t\t\tthrows IOException {\n\n\t}",
"public void postData() {\n\n\t}",
"@Override\n public void doPost(HttpServletRequest req, HttpServletResponse res) throws IOException, ServletException {\n logger.warn(\"doPost Called\");\n handle(req, res);\n }",
"@Override\n protected void doPost(HttpServletRequest request, HttpServletResponse response)\n throws ServletException, IOException {\n metPost(request, response);\n }",
"protected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {\n }",
"@Override\r\n\tprotected void doPost(HttpServletRequest req, HttpServletResponse resp)\r\n\t\t\tthrows ServletException, IOException {\n\t\tsuper.doPost(req, resp);\r\n\t}",
"@Override\r\n protected void doPost(HttpServletRequest request, HttpServletResponse response)\r\n throws ServletException, IOException {\r\n\r\n }",
"@Override\n\tprotected void doPost(HttpServletRequest req, HttpServletResponse resp)\n\t\t\tthrows ServletException, IOException {\n\t\tsuper.doPost(req, resp);\n\t}",
"@Override\n\tprotected void doPost(HttpServletRequest req, HttpServletResponse resp)\n\t\t\tthrows ServletException, IOException {\n\t\tsuper.doPost(req, resp);\n\t}",
"@Override\n\tprotected void doPost(HttpServletRequest req, HttpServletResponse resp)\n\t\t\tthrows ServletException, IOException {\n\t\tsuper.doPost(req, resp);\n\t}",
"@Override\n\tpublic void postHandle(WebRequest request, ModelMap model) throws Exception {\n\n\t}",
"protected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {\n\n }",
"public void doPost(HttpServletRequest request, HttpServletResponse response)\r\n\t\t\tthrows ServletException, IOException {\r\n\r\n\t\t\r\n\t}",
"@Override\n\tprotected void doPost(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException {\n\t\t\n\t}",
"@Override\n\tprotected HttpMethod requestMethod() {\n\t\treturn HttpMethod.POST;\n\t}",
"@Override\n\tprotected void handlePostBody(HashMap<String, HashMap<String, String>> params, DataFormat format) throws Exception {\n\t}",
"@Override\r\n protected void doPost(HttpServletRequest request, HttpServletResponse response)\r\n throws ServletException, IOException {\r\n }",
"@Override\n\tprotected void doPost(HttpServletRequest request, HttpServletResponse response)\n\t\t\tthrows ServletException, IOException {\n\t}",
"@Override\r\n protected void doPost(HttpServletRequest request, HttpServletResponse response)\r\n throws ServletException, IOException {\r\n \r\n }",
"@Override\r\n protected void doPost(HttpServletRequest request, HttpServletResponse response)\r\n throws ServletException, IOException {\r\n \r\n }",
"@Override\n\n\tpublic void handlePOST(CoapExchange exchange) {\n\t\tFIleStream read = new FIleStream();\n\t\tread.tempWrite(Temp_Path, exchange.getRequestText());\n\t\texchange.respond(ResponseCode.CREATED, \"POST successfully!\");\n\t\t_Logger.info(\"Receive post request:\" + exchange.getRequestText());\n\t}",
"@Override\n protected void doPost(HttpServletRequest request, HttpServletResponse response)\n throws ServletException, IOException {\n response.getWriter().println(\"go to post method in manager\");\n }",
"@Override\r\n\tprotected void doPost(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException {\n\t\tsuper.doPost(req, resp);\r\n\t}",
"@Override\r\n\tprotected void doPost(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException {\n\t\tsuper.doPost(req, resp);\r\n\t}",
"@Override\r\n\tprotected void doPost(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException {\n\t\tsuper.doPost(req, resp);\r\n\t}",
"@Override\n protected void doPost(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException {\n }",
"@Override\n protected void doPost(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException {\n }",
"public void doPost(HttpServletRequest request, HttpServletResponse response)\n\t\t\tthrows ServletException, IOException {\n\t\t\n\t}",
"@Override\n protected void doPost(HttpServletRequest request, HttpServletResponse response)\n throws ServletException, IOException {\n \n }",
"public abstract boolean handlePost(FORM form, BindException errors) throws Exception;",
"@Override\n protected void doPost(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException {\n super.doPost(req, resp);\n }",
"public void doPost(HttpServletRequest request, HttpServletResponse response)\n\t\t\tthrows ServletException, IOException {\n\t\n\t\t\t\n\t\t \n\t}",
"@Override\n\tprotected void doPost(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException {\n\t\tsuper.doPost(req, resp);\n\t}",
"@Override\n\tprotected void doPost(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException {\n\t\tsuper.doPost(req, resp);\n\t}",
"@Override\n\tprotected void doPost(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException {\n\t\tsuper.doPost(req, resp);\n\t}",
"public void processPost(HttpServletRequest request, HttpServletResponse response)\n throws ServletException, IOException\n {\n }",
"@Override\n\tpublic void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {\n\n\t}",
"@Override\n\tpublic void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {\n\n\t}",
"public void doPost(HttpServletRequest request, HttpServletResponse response)\n\t\t\tthrows ServletException, IOException {\n\n\n\t}",
"public void doPost(HttpServletRequest request ,HttpServletResponse response){\n\n }",
"@Override\n protected void doPost(HttpServletRequest request, HttpServletResponse response)\n throws ServletException, IOException {\n\n }",
"protected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {\n}",
"@Override\r\n\tpublic void postHandle(HttpServletRequest request,\r\n\t\t\tHttpServletResponse response, Object handler,\r\n\t\t\tModelAndView modelAndView) throws Exception {\n\r\n\t}",
"public void post(){\n\t\tHttpClient client = new HttpClient();\n\n\t\tPostMethod post = new PostMethod(\"http://211.138.245.85:8000/sso/POST\");\n//\t\tPostMethod post = new PostMethod(\"/eshopclient/product/show.do?id=111655\");\n//\t\tpost.addRequestHeader(\"Cookie\", cookieHead);\n\n\n\t\ttry {\n\t\t\tSystem.out.println(\"��������====\");\n\t\t\tint status = client.executeMethod(post);\n\t\t\tSystem.out.println(status);\n\t\t} catch (HttpException e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t} catch (IOException e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t}\n\n//\t\ttaskCount++;\n//\t\tcountDown--;\n\t}",
"protected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {\n\t}",
"protected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {\n\t}",
"protected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {\n\t}",
"protected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {\n\t}",
"protected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {\n\t}",
"protected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {\n\t}",
"protected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {\n\t}",
"protected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {\n\t}",
"protected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {\n\t}",
"protected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {\n\t}",
"protected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {\n\t}",
"public void doPost(HttpServletRequest req, HttpServletResponse resp) throws ServletException {\r\n\tlogTrace( req, \"POST log\" );\r\n\tString requestId = req.getQueryString();\r\n\tif (requestId == null) {\r\n\t try {\r\n\t\tServletUtil.bufferedRead( req.getInputStream() );\r\n\t } catch (IOException ex) {\r\n\t }\r\n\t logError( req, resp, new Exception(\"Unrecognized POST\"), \"\" );\r\n\t sendError(resp, \"Unrecognized POST\");\r\n\t} else\r\n\t if (\"post-request\".equals( requestId )) {\r\n\t\ttry {\r\n\t\t onMEVPostsRequest( req, resp );\r\n\t\t} catch (Exception e) {\r\n\t\t try {\r\n\t\t\tServletUtil.bufferedRead( req.getInputStream() );\r\n\t\t } catch (IOException ex) {\r\n\t\t }\r\n\t\t logError( req, resp, e, \"MEV POST error\" );\r\n\t\t sendError( resp, \"MEV POST error: \" + e.toString() );\r\n\t\t}\r\n\t } else if (\"post-response\".equals( requestId )) {\r\n\t\ttry {\r\n\t\t onPVMPostsResponse( req, resp );\r\n\t\t} catch (Exception e) {\r\n\t\t try {\r\n\t\t\tServletUtil.bufferedRead( req.getInputStream() );\r\n\t\t } catch (IOException ex) {\r\n\t\t }\r\n\t\t logError( req, resp, e, \"PVM POST error\" );\r\n\t\t sendError( resp, \"PVM POST error: \" + e.toString() );\r\n\t\t}\r\n\t }\r\n }",
"@Override\n\tpublic void postHandle(HttpServletRequest request,\n\t\t\tHttpServletResponse response, Object handler,\n\t\t\tModelAndView modelAndView) throws Exception {\n\t\t\n\t}",
"@Override\n\tpublic void postHandle(HttpServletRequest request,\n\t\t\tHttpServletResponse response, Object handler,\n\t\t\tModelAndView modelAndView) throws Exception {\n\t\t\n\t}",
"@Override\n\tpublic void postHandle(HttpServletRequest request,\n\t\t\tHttpServletResponse response, Object handler,\n\t\t\tModelAndView modelAndView) throws Exception {\n\t}",
"@Override\r\n\tpublic void postHandle(HttpServletRequest req, HttpServletResponse resp, Object handler, ModelAndView m)\r\n\t\t\tthrows Exception {\n\t\t\r\n\t}",
"@Override\n public final void doPost() {\n try {\n checkPermissions(getRequest());\n final IItem jSonStreamAsItem = getJSonStreamAsItem();\n final IItem outputItem = api.runAdd(jSonStreamAsItem);\n\n output(JSonItemWriter.itemToJSON(outputItem));\n } catch (final APIException e) {\n e.setApi(apiName);\n e.setResource(resourceName);\n throw e;\n\n }\n }",
"@Override\n\tvoid post() {\n\t\t\n\t}",
"@Override\r\n\tprotected void doPost(HttpServletRequest req, HttpServletResponse res) throws ServletException, IOException {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void postHandle(HttpServletRequest request, HttpServletResponse response, Object handler,\r\n\t\t\tModelAndView modelAndView) throws Exception {\n\t\tSystem.out.println(\"=========interCpetor Post=========\");\r\n\t}",
"public void doPost(HttpServletRequest request, HttpServletResponse response)\n\t\t\tthrows ServletException, IOException {\n\t\tString method = request.getParameter(\"method\");\n\t\tswitch(method){\n\t\tcase \"Crawl\":\n\t\t\tcrawl(request, response);\n\t\t\tbreak;\n\t\tcase \"Extract\":\n\t\t\textract(request, response);\n\t\t\tbreak;\n\t\tcase \"JDBC\":\n\t\t\tjdbc(request, response);\n\t\t\tbreak;\n\t\tcase \"Indexer\":\n\t\t\tindexer(request, response);\n\t\t\tbreak;\n\t\t}\n\t}",
"@Override\r\n protected void doPost(HttpServletRequest request, HttpServletResponse response)\r\n throws ServletException, IOException {\r\n processRequest(request, response);\r\n System.out.println(\"teste dopost\");\r\n }",
"protected void doPost(HttpServletRequest request,\r\n\t\t\tHttpServletResponse response)\r\n\t/* 43: */throws ServletException, IOException\r\n\t/* 44: */{\r\n\t\t/* 45:48 */doGet(request, response);\r\n\t\t/* 46: */}",
"@Override\n\tprotected void doPost(HttpServletRequest req, HttpServletResponse resp)\n\t\t\tthrows ServletException, IOException {\n\t\tprocess(req, resp);\n\t}",
"@Override\r\n\tpublic void postHandle(HttpServletRequest request, HttpServletResponse response, Object handler,\r\n\t\t\tModelAndView modelAndView) throws Exception {\n\r\n\t}",
"@Override\r\n\tpublic void postHandle(HttpServletRequest request, HttpServletResponse response, Object handler,\r\n\t\t\tModelAndView modelAndView) throws Exception {\n\r\n\t}",
"@Override\r\n\tpublic void postHandle(HttpServletRequest request, HttpServletResponse response, Object handler,\r\n\t\t\tModelAndView modelAndView) throws Exception {\n\r\n\t}",
"@Override\r\n\tpublic void postHandle(HttpServletRequest request, HttpServletResponse response, Object handler,\r\n\t\t\tModelAndView modelAndView) throws Exception {\n\r\n\t}",
"@Override\r\n\tpublic void postHandle(HttpServletRequest request, HttpServletResponse response, Object handler,\r\n\t\t\tModelAndView modelAndView) throws Exception {\n\r\n\t}",
"@Override\r\n\tpublic void postHandle(HttpServletRequest request, HttpServletResponse response, Object handler,\r\n\t\t\tModelAndView modelAndView) throws Exception {\n\r\n\t}",
"@Override\r\n\tpublic void postHandle(HttpServletRequest request, HttpServletResponse response, Object handler,\r\n\t\t\tModelAndView modelAndView) throws Exception {\n\r\n\t}",
"@Override\r\n protected void doPost(HttpServletRequest request, HttpServletResponse response)\r\n throws ServletException, IOException {\r\n processRequest(request, response);\r\n }",
"@Override\r\n\tprotected void doPost(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException {\n\tprocess(req,resp);\r\n\t}",
"public void handlePost(SessionSrvc session, IObjectContext context)\n throws Exception\n {\n }",
"public void doPost(HttpServletRequest request, HttpServletResponse response) {\n\t\tdoGet(request, response);\n\t}",
"public void doPost(HttpServletRequest request, HttpServletResponse response) {\n\t\tdoGet(request, response);\n\t}",
"public void doPost(HttpServletRequest request, HttpServletResponse response) {\r\n\t\tdoGet(request, response);\r\n\t}",
"@Override\r\n\tpublic void postHandle(HttpServletRequest request, HttpServletResponse response, Object handler,\r\n\t\t\tModelAndView modelAndView) throws Exception {\n\t}",
"@Override\n protected void doPost\n (HttpServletRequest request, HttpServletResponse response)\n throws ServletException, IOException {\n processRequest(request, response);\n }",
"@Override\r\n protected void doPost(HttpServletRequest request, HttpServletResponse response)\r\n throws ServletException, IOException {\r\n try {\r\n processRequest(request, response);\r\n } catch (JSONException ex) {\r\n Logger.getLogger(PDCBukUpload.class.getName()).log(Level.SEVERE, null, ex);\r\n }\r\n }",
"@Override\r\n protected void doPost(HttpServletRequest request,\r\n HttpServletResponse response)\r\n throws ServletException,\r\n IOException {\r\n processRequest(request,\r\n response);\r\n\r\n }",
"@Override\r\n\tpublic void doPost(CustomHttpRequest request, CustomHttpResponse response) throws Exception {\n\t\tdoGet(request, response);\r\n\t}",
"@Override\n\tpublic void postHandle(HttpServletRequest request, HttpServletResponse response,\n\t\t\tObject handler, ModelAndView modelAndView) throws Exception {\n\n\t}",
"protected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {\n\t\tdoHandle(request, response);\n\t}",
"private void postRequest() {\n\t\tSystem.out.println(\"post request, iam playing money\");\n\t}",
"@Override\r\n protected void doPost(HttpServletRequest request, HttpServletResponse response)\r\n throws ServletException, IOException {\r\n processRequest(request, response);\r\n }",
"@Override\n public void postHandle(HttpServletRequest request,\n HttpServletResponse response, Object handler,\n ModelAndView modelAndView) throws Exception {\n\n }",
"@Override\n protected void doPost(HttpServletRequest request, HttpServletResponse response)\n throws ServletException, IOException {\n try {\n processRequest(request, response);\n } catch (Exception ex) {\n Logger.getLogger(PedidoController.class.getName()).log(Level.SEVERE, null, ex);\n }\n }"
] | [
"0.73289514",
"0.71383566",
"0.7116213",
"0.7105215",
"0.7100045",
"0.70236707",
"0.7016248",
"0.6964149",
"0.6889435",
"0.6784954",
"0.67733276",
"0.67482096",
"0.66677034",
"0.6558593",
"0.65582114",
"0.6525548",
"0.652552",
"0.652552",
"0.652552",
"0.65229493",
"0.6520197",
"0.6515622",
"0.6513045",
"0.6512626",
"0.6492367",
"0.64817846",
"0.6477479",
"0.64725804",
"0.6472099",
"0.6469389",
"0.6456206",
"0.6452577",
"0.6452577",
"0.6452577",
"0.6450273",
"0.6450273",
"0.6438126",
"0.6437522",
"0.64339423",
"0.64253825",
"0.6422238",
"0.6420897",
"0.6420897",
"0.6420897",
"0.6407662",
"0.64041835",
"0.64041835",
"0.639631",
"0.6395677",
"0.6354875",
"0.63334197",
"0.6324263",
"0.62959254",
"0.6288832",
"0.6288832",
"0.6288832",
"0.6288832",
"0.6288832",
"0.6288832",
"0.6288832",
"0.6288832",
"0.6288832",
"0.6288832",
"0.6288832",
"0.6280875",
"0.6272104",
"0.6272104",
"0.62711537",
"0.62616795",
"0.62544584",
"0.6251865",
"0.62274224",
"0.6214439",
"0.62137586",
"0.621211",
"0.620854",
"0.62023044",
"0.61775357",
"0.61775357",
"0.61775357",
"0.61775357",
"0.61775357",
"0.61775357",
"0.61775357",
"0.61638993",
"0.61603814",
"0.6148914",
"0.61465937",
"0.61465937",
"0.614548",
"0.6141879",
"0.6136717",
"0.61313903",
"0.61300284",
"0.6124381",
"0.6118381",
"0.6118128",
"0.61063534",
"0.60992104",
"0.6098801",
"0.6096766"
] | 0.0 | -1 |
Returns a short description of the servlet. | @Override
public String getServletInfo() {
return "Short description";
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public String getServletInfo()\n {\n return \"Short description\";\n }",
"public String getServletInfo() {\n return \"Short description\";\n }",
"public String getServletInfo() {\n return \"Short description\";\n }",
"public String getServletInfo() {\n return \"Short description\";\n }",
"public String getServletInfo() {\n return \"Short description\";\n }",
"public String getServletInfo() {\n return \"Short description\";\n }",
"public String getServletInfo() {\n return \"Short description\";\n }",
"public String getServletInfo() {\n return \"Short description\";\n }",
"public String getServletInfo() {\n return \"Short description\";\n }",
"public String getServletInfo() {\n return \"Short description\";\n }",
"public String getServletInfo() {\n return \"Short description\";\n }",
"public String getServletInfo() {\r\n return \"Short description\";\r\n }",
"public String getServletInfo() {\r\n return \"Short description\";\r\n }",
"public String getServletInfo() {\r\n return \"Short description\";\r\n }",
"public String getServletInfo() {\r\n return \"Short description\";\r\n }",
"public String getServletInfo() {\r\n return \"Short description\";\r\n }",
"public String getServletInfo() {\r\n return \"Short description\";\r\n }",
"@Override\r\n public String getServletInfo() {\r\n return \"Short description\";\r\n }",
"@Override\r\n public String getServletInfo() {\r\n return \"Short description\";\r\n }",
"@Override\n public String getServletInfo() {\n return \"Short description\";\n }",
"@Override\n public String getServletInfo() {\n return \"Short description\";\n }",
"@Override\n public String getServletInfo() {\n return \"Short description\";\n }",
"@Override\n\tpublic String getServletInfo() {\n\t\treturn \"Short description\";\n\t}",
"@Override\n\tpublic String getServletInfo() {\n\t\treturn \"Short description\";\n\t}",
"@Override\n\tpublic String getServletInfo() {\n\t\treturn \"Short description\";\n\t}",
"@Override\n\tpublic String getServletInfo() {\n\t\treturn \"Short description\";\n\t}",
"@Override\n\tpublic String getServletInfo() {\n\t\treturn \"Short description\";\n\t}",
"@Override\n\tpublic String getServletInfo() {\n\t\treturn \"Short description\";\n\t}",
"@Override\r\n public String getServletInfo()\r\n {\r\n return \"Short description\";\r\n }",
"@Override\n public String getServletInfo()\n {\n return \"Short description\";\n }",
"@Override\r\n\tpublic String getServletInfo() {\r\n\t\treturn \"Short description\";\r\n\t}",
"@Override\r\n public String getServletInfo()\r\n {\r\n return \"Short description\";\r\n }",
"@Override\n public String getServletInfo() {\n return \"Short description\";\n }"
] | [
"0.87634975",
"0.8732279",
"0.8732279",
"0.8732279",
"0.8732279",
"0.8732279",
"0.8732279",
"0.8732279",
"0.8732279",
"0.8732279",
"0.8732279",
"0.8699131",
"0.8699131",
"0.8699131",
"0.8699131",
"0.8699131",
"0.8699131",
"0.8531295",
"0.8531295",
"0.85282224",
"0.85282224",
"0.85282224",
"0.8527433",
"0.8527433",
"0.8527433",
"0.8527433",
"0.8527433",
"0.8527433",
"0.8516995",
"0.8512296",
"0.8511239",
"0.8510324",
"0.84964365"
] | 0.0 | -1 |
Test of generate method, of class GenerateOptionalFacts. | @Test
public void testValid() {
System.out.println("UT-WRS-SE-042 : Test GenerateOptional Facts with valid or existing key reference");
boolean ok = false;
try {
murlinObj = new GenericMURLinJSONObject();
System.out.println("Test Optional Facts Generation using terms of facts");
Map<String, String> results = new HashMap<String, String>();
Map<String, String> dyn = new HashMap<String, String>();
String[] mods = {"wcs", "psm", "mva"};
String[] field = {"wcs.category", "wcs.layer", "psm.pattern", "psm.pattern_hit", "mva.bc", "mva.ns", "mva.ws"};
dyn = generateFields(field);
murlinObj.setDyn_conf(dyn);
System.out.println(murlinObj.getDyn_conf().get("result_fields"));
results = generateResult(mods);
murlinObj.setResults(results);
GenerateFacts instance = new GenerateFacts(murlinObj);
Facts result = instance.generate();
ok = true;
System.out.println(result);
} catch (Exception ex) {
System.out.println(ex.getCause());
fail(ex.getLocalizedMessage());
}
if (ok) {
assertTrue(true);
System.out.println("Facts Generation was successfully performed");
System.out.println("*** Passed");
}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@Test\n\tpublic void testDoGeneration() {\n\t}",
"public void generate() {\n\t}",
"protected abstract void generate();",
"public abstract void generate();",
"public boolean generate();",
"@Test\n\tpublic void testAllExampleGenerations() {\n\t\ttry {\n\t\t\tOdfHelper.main(null);\n\t\t} catch (Exception ex) {\n\t\t\tLOG.log(Level.SEVERE, null, ex);\n\t\t\tAssert.fail(ex.toString());\n\t\t}\n\t}",
"abstract T generate();",
"@Test\n public void testConstraintGenerator() throws Exception {\n\n // Tests the generation of constraints generated from bindings that include a MaxValueSet extension,\n // by using a Device profile and extensions created specifically for this test.\n //\n // Each of the following combinations is tested:\n // Choice: No/Yes; Optional: No/Yes; Repeatable: No/Yes\n //-----------------------------------------------\n // Choice: No; Optional: No; Repeatable: No\n //-----[Device.specialization.systemType]\n // Choice: No; Optional: No; Repeatable: Yes\n //-----[Device.statusReason] (no MaxValueSet)\n // Choice: No; Optional: Yes; Repeatable: No\n //-----[Device.type]\n // Choice: No; Optional: Yes; Repeatable: Yes\n //-----[Device.safety]\n // Choice: Yes; Optional: No; Repeatable: No\n //----[test-language-primary-extension]\n // Choice: Yes; Optional: No; Repeatable: Yes\n //----[test-language-others-req-extension]\n // Choice: Yes; Optional: Yes; Repeatable: No\n //----[test-language-secondary-extension]\n // Choice: Yes; Optional: Yes; Repeatable: Yes\n //----[test-language-others-opt-extension]\n //-----------------------------------------------\n\n StructureDefinition structureDefinition = FHIRRegistry.getInstance().getResource(\"http://ibm.com/fhir/StructureDefinition/test-device\", StructureDefinition.class);\n ConstraintGenerator generator = new ConstraintGenerator(structureDefinition);\n List<Constraint> constraints = generator.generate();\n assertEquals(constraints.size(), 7);\n constraints.forEach(constraint -> compile(constraint.expression()));\n assertEquals(constraints.get(3).expression(), \"statusReason.count() >= 1\");\n assertEquals(constraints.get(4).expression(), \"type.exists() implies (type.memberOf('http://hl7.org/fhir/ValueSet/languages', 'extensible') and type.memberOf('http://hl7.org/fhir/ValueSet/all-languages', 'required'))\");\n assertEquals(constraints.get(5).expression(), \"specialization.exists() implies (specialization.all(systemType.exists() and systemType.memberOf('http://hl7.org/fhir/ValueSet/languages', 'extensible') and systemType.memberOf('http://hl7.org/fhir/ValueSet/all-languages', 'required')))\");\n assertEquals(constraints.get(6).expression(), \"safety.exists() implies (safety.all(memberOf('http://hl7.org/fhir/ValueSet/languages', 'extensible')) and safety.all(memberOf('http://hl7.org/fhir/ValueSet/all-languages', 'required')))\");\n\n structureDefinition = FHIRRegistry.getInstance().getResource(\"http://ibm.com/fhir/StructureDefinition/test-language-primary-extension\", StructureDefinition.class);\n generator = new ConstraintGenerator(structureDefinition);\n constraints = generator.generate();\n assertEquals(constraints.size(), 2);\n constraints.forEach(constraint -> compile(constraint.expression()));\n assertEquals(constraints.get(1).expression(), \"value.as(CodeableConcept).exists() and value.as(CodeableConcept).memberOf('http://hl7.org/fhir/ValueSet/languages', 'preferred') and value.as(CodeableConcept).memberOf('http://hl7.org/fhir/ValueSet/all-languages', 'required')\");\n\n structureDefinition = FHIRRegistry.getInstance().getResource(\"http://ibm.com/fhir/StructureDefinition/test-language-secondary-extension\", StructureDefinition.class);\n generator = new ConstraintGenerator(structureDefinition);\n constraints = generator.generate();\n assertEquals(constraints.size(), 2);\n constraints.forEach(constraint -> compile(constraint.expression()));\n assertEquals(constraints.get(1).expression(), \"value.as(Coding).exists() implies (value.as(Coding).memberOf('http://hl7.org/fhir/ValueSet/languages', 'preferred') and value.as(Coding).memberOf('http://hl7.org/fhir/ValueSet/all-languages', 'required'))\");\n\n structureDefinition = FHIRRegistry.getInstance().getResource(\"http://ibm.com/fhir/StructureDefinition/test-language-tertiary-extension\", StructureDefinition.class);\n generator = new ConstraintGenerator(structureDefinition);\n constraints = generator.generate();\n assertEquals(constraints.size(), 2);\n constraints.forEach(constraint -> compile(constraint.expression()));\n assertEquals(constraints.get(1).expression(), \"value.as(code).exists() and value.as(code).memberOf('http://hl7.org/fhir/ValueSet/languages', 'preferred') and value.as(code).memberOf('http://hl7.org/fhir/ValueSet/all-languages', 'required')\");\n\n structureDefinition = FHIRRegistry.getInstance().getResource(\"http://ibm.com/fhir/StructureDefinition/test-language-others-opt-extension\", StructureDefinition.class);\n generator = new ConstraintGenerator(structureDefinition);\n constraints = generator.generate();\n assertEquals(constraints.size(), 2);\n constraints.forEach(constraint -> compile(constraint.expression()));\n assertEquals(constraints.get(1).expression(), \"value.as(CodeableConcept).exists() implies (value.as(CodeableConcept).all(memberOf('http://hl7.org/fhir/ValueSet/languages', 'preferred')) and value.as(CodeableConcept).all(memberOf('http://hl7.org/fhir/ValueSet/all-languages', 'required')))\");\n\n structureDefinition = FHIRRegistry.getInstance().getResource(\"http://ibm.com/fhir/StructureDefinition/test-language-others-req-extension\", StructureDefinition.class);\n generator = new ConstraintGenerator(structureDefinition);\n constraints = generator.generate();\n assertEquals(constraints.size(), 2);\n constraints.forEach(constraint -> compile(constraint.expression()));\n assertEquals(constraints.get(1).expression(), \"value.as(CodeableConcept).exists() and value.as(CodeableConcept).all(memberOf('http://hl7.org/fhir/ValueSet/languages', 'preferred')) and value.as(CodeableConcept).all(memberOf('http://hl7.org/fhir/ValueSet/all-languages', 'required'))\");\n }",
"@Test\n\tpublic void testNormalPuzzleGeneration() {\n\t}",
"@Test\n\tpublic static void PersonTest01() {\n\t\t\tString targetTable = \"DATA_TEST\";\n\t\t\ttargetTable = \"test_sample\";\n\t\t\ttry{\n\t\t\tPriorDAO DAO = new PriorDAO();\n\t\t\tDAO.DropTempTable(targetTable);\n\t\t\tString[] inArgs ={\"CREATE_EMPTY_FACT_TABLE\",targetTable};\n\t\t\tDAO.RunProcedure(inArgs, null, null);\n\t\tGenerator Gen = new Generator();\n\t\tint crowedSize = 10000;\n\t\tcrowedSize = 1000;\n\t\tmakePop(Gen, crowedSize, targetTable);\n\t\tGeneratorType2 Gen2 = new GeneratorType2();\n\t\tmakePop(Gen2, crowedSize, targetTable);\n\t\tPrint(\"Finished\");\n\t\t\t}catch(Exception e)\n\t\t\t{\n\t\t\t\tPrint(\"Failed :\"+e.getMessage());\n\t\t\t}\n\t}",
"@Test\n public void testLoadOptionalBuilderForceCreate()\n throws ConfigurationException\n {\n CombinedConfiguration config = prepareOptionalTest(\"configuration\",\n true);\n assertEquals(\"Wrong number of configurations\", 1, config\n .getNumberOfConfigurations());\n assertTrue(\n \"Wrong optional configuration type\",\n config.getConfiguration(OPTIONAL_NAME) instanceof CombinedConfiguration);\n }",
"@Test\n\tpublic void testEvilPuzzleGeneration() {\n\t}",
"@Test\n\tpublic void generateTest(){\n\t\tSemanticActions actions = new SemanticActions();\n\t\tQuadruples quads = actions.getQuads();\n\t\tactions.generate(\"hello\");\n\t\tassertTrue(quads.getNextQuad() == 1);\n\t\tassertArrayEquals(new String[] {\"hello\"}, quads.getQuad(0));\n\t\t\n\t\tVariableEntry varE = new VariableEntry(\"A\", TokenType.IDENTIFIER);\n\t\tvarE.setAddress(1);\n\t\tactions.generate(\"move\", new ConstantEntry(\"100\"), varE);\n\t\tassertTrue(quads.getNextQuad()==3);\n\t\tassertArrayEquals(new String[] {\"move\", \"100\", \"_0\"}, quads.getQuad(1));\n\t\tassertArrayEquals(new String[]{\"move\", \"_0\", \"_1\"}, quads.getQuad(2));\n\t\t\n\t\tactions.generate(\"PROCBEGIN\", new ProcedureEntry(\"MAIN\"));\n\t\tassertTrue(quads.getNextQuad() == 4);\n\t\tassertArrayEquals(new String[] {\"PROCBEGIN\", \"main\"}, quads.getQuad(3));\n\t}",
"public static void main(String[] args) {\n\n\t\tint a = 5;\n\t\tString b = \"ig\";\n\t\tMyTestOptional<String> name = MyTestOptional.of(\"Igor\");\n\t\t\tif(name.isPresent()) {\n\t\t\t\tSystem.out.println(name);\n\t\t\t}\n\n\t\tMyTestOptional<String> nameNext = MyTestOptional.of(\"Nastia\");\n\t\tassert nameNext.hashCode() == nameNext.hashCode();\n\t\tSystem.out.println(nameNext.hashCode());\n\t}",
"public Scenario generate() {\n\n //generate random number of Passenger(all human)\n ArrayList liPsg = new ArrayList();\n int totalNumOfPsg = (int) (rd.nextDouble() * PassengerCountMax + PassengerCountMin); //at least one Psg\n for (int i = 0; i < totalNumOfPsg; i++) {\n liPsg.add(getRandomPerson());\n }\n //System.out.println(\"PassengerNum= \"+totalNumOfPsg);\n\n\n //generate random number of Pedestrians(with Max 5) & allocate person+animal randomly(human+animal)\n ArrayList liPdt = new ArrayList();\n int totalNumOfPdst = (int) (rd.nextDouble() * PedestrianCountMax + PedestrianCountMin);//at least one Pdg\n int NumOfPerson = (int) Math.round(rd.nextDouble() * totalNumOfPdst);//if only 1 pdt,along with randomDouble<0.5 , 0.4x*1 rounded=0, will only an animal\n //so if you are random being in pdt but pdt only an animal, you neither wont be in scenario, so your negative probability in scenario is higher.\n int NumOfAnimal = totalNumOfPdst - NumOfPerson;\n for (int i = 0; i < NumOfPerson; i++) {\n liPdt.add(getRandomPerson());\n }\n for (int i = 0; i < NumOfAnimal; i++) {\n liPdt.add(getRandomAnimal());\n }\n //System.out.println(\"PedestrianNum= \"+totalNumOfPdst+\" with \"+NumOfPerson+\" human and \"+NumOfAnimal+\" animals\");\n\n\n //allocating where you are, 0=you absence & do nothing, 1=you in car, 2=you on road !!!!yeah happy solving\n int allocate_of_user = (int) Math.round(rd.nextDouble() * 2);\n if (allocate_of_user == 1) {\n ((Person) liPsg.get(0)).setAsYou(true); //set the first psg is you. !!!!!important Cast Obj into Person!!!!\n } else if (allocate_of_user == 2) {\n for (int i = 0; i < liPdt.size(); i++) {\n if (liPdt.get(i) instanceof Person) {//check whether a person\n ((Person) liPdt.get(i)).setAsYou(true);\n break; // only set once than break rather than set all of people of pdt is you\n }\n }\n }\n\n //Scenario(ArrayList<Character> passengers, ArrayList<Character> pedestrians, boolean isLegalCrossing)\n S = new Scenario(liPsg, liPdt, rd.nextBoolean()); //isLegalCrossing = red or green light;\n return S;\n }",
"@Test\r\n\tpublic void testPositiveGenerateStrings_2() {\n\t\tint i = 1;\r\n\t\tfor (RandomOrgClient roc : rocs) {\r\n\t\t\ttry {\r\n\t\t\t\tcollector.checkThat(roc.generateStrings(10, 5, \"abcd\", false), notNullValue());\r\n\t\t\t} catch (Exception e) {\r\n\t\t\t\tcollector.addError(new Error(errorMessage(i, e, true)));\r\n\t\t\t}\r\n\t\t\ti++;\r\n\t\t}\r\n\t}",
"@Override\n public HashProbDef generateProblemDefinition(HashProbGen hashProbGen) throws Exception {\n \n /* En caso de que recibamos un hash con el grafo en vez de\n * un grafo con las opciones de generacion. */\n \n if(hashProbGen.containsKey(E.filename)){\n HashGraphDef graphDef = new HashGraphDef();\n String filename = hashProbGen.get(E.filename);\n String extension = filename.substring(filename.length()-4);\n switch(extension){\n case \".txt\": graphDef = ReaderGraph.optFromTXT(new File(filename)); break;\n case \".xml\": graphDef = GraphProblemFromXML.graphDefFromXML(new File(filename)); break;\n default: throw new Exception(\"Unknown file extension.\");\n }\n HashProbDef probDef = new HashProbDef();\n probDef.putAll(graphDef);\n return probDef;\n }\n \n // HACK\n if(hashProbGen.containsKey(\"0,0\") || hashProbGen.containsKey(\"1,1\")){\n HashProbDef h = new HashProbDef();\n h.putAll(hashProbGen);\n return h;\n }\n \n if(hashProbGen.containsKey(E.generationMode)){\n switch(hashProbGen.getIndispensable(E.generationMode)){\n case E.genModeUniDist: genType = GenType.UNIFORM_DISTRIBUTION; break;\n case E.genModeBiased: genType = GenType.BIASED; break;\n }\n }\n \n \n if(hashProbGen.containsKey(E.randomSeed)) \n Rand.setSeed(Long.valueOf(hashProbGen.get(E.randomSeed)));\n \n /** Hash con la definicion arista por arista del grafo generado. */\n HashProbDef optDef = new HashProbDef();\n optDef.put(E.numOfCities, hashProbGen.get(E.numOfCities));\n // opt.putAll(optArg);\n \n // Hay que generarlos.\n int numOfCities = Integer.valueOf(hashProbGen.getIndispensable(E.numOfCities));\n float minDist = Float.valueOf(hashProbGen.getIndispensable(E.minDist));\n float maxDist = Float.valueOf(hashProbGen.getIndispensable(E.maxDist));\n \n for(int i=0; i<numOfCities; i++){\n for(int j=i; j<numOfCities; j++){\n if(j == i){\n optDef.put(String.format(\"%s,%s\", i,j), \"0\");\n }\n else {\n switch(genType){\n case BIASED:\n optDef.put(String.format(\"%s,%s\", i,j), \n String.valueOf(maxDist)); break;\n case UNIFORM_DISTRIBUTION:\n optDef.put(String.format(\"%s,%s\", i,j), \n String.valueOf(Rand.randFloat(minDist, maxDist))); break;\n }\n }\n if(genType == GenType.BIASED){\n int randSisterCity;\n do{\n randSisterCity = Rand.randInt(0, numOfCities-1);\n }while(randSisterCity == i);\n optDef.put(String.format(\"%s,%s\", i, randSisterCity), \n String.valueOf(minDist));\n }\n }\n }\n \n return optDef;\n }",
"@Test\r\n\tpublic void testPositiveGenerateStrings_1() {\n\t\tint i = 1;\r\n\t\tfor (RandomOrgClient roc : rocs) {\r\n\t\t\ttry {\r\n\t\t\t\tcollector.checkThat(roc.generateStrings(10, 5, \"abcd\"), notNullValue());\r\n\t\t\t} catch (Exception e) {\r\n\t\t\t\tcollector.addError(new Error(errorMessage(i, e, true)));\r\n\t\t\t}\r\n\t\t\ti++;\r\n\t\t}\r\n\t}",
"@Test\n public void checkEmptyPromptRuleGenerator() throws IOException {\n String xml = IOUtils.toString(getClass().getClassLoader().getResourceAsStream(PATH_TO_GENERATED_RULE_XML),\n StandardCharsets.UTF_8.name());\n assertNotNull(\"Xml of rule can not be null\", xml);\n\n Rule rule = (Rule) XML_OBJECT_FACTORY.parseXml(new SimulatedSailPointContext(), xml, false);\n assertNotNull(\"Rule can not be null\", rule);\n\n assertTrue(\"Prompt is not null\",\n rule.getSignature().getArguments().stream().noneMatch(argument -> argument.getPrompt() != null));\n }",
"public void generateData()\n {\n }",
"private void generateSolution() {\n\t\t// TODO\n\n\t}",
"@Test public void testCreateIpuGenerationRule(@Mocked final IScope scope, @Mocked final FileUtils fileUtils) throws GenstarException {\n\t\t\n\t\tfinal String base_path = \"test_data/ummisco/genstar/gama/GamaGenstarUtilsTest/testCreateIpuGenerationRule/\";\n\t\t\n\t\tfinal String groupAttributesFilePath = base_path + \"group_attributes.csv\";\n\t\tfinal String groupPopulationName = \"household\";\n\t\tfinal String groupSampleDataFile = base_path + \"group_sample.csv\";\n\t\tfinal String groupIdOnGroup = \"HouseholdID\";\n\t\tfinal String groupControlledAttributesFile = base_path + \"group_controlled_attributes.csv\";\n\t\tfinal String groupControlTotalsFile = base_path + \"group_ipu_control_totals.csv\";\n\t\tfinal String groupSupplementaryAttributesFile = base_path + \"group_supplementary_attributes.csv\";\n\t\t\n\t\tfinal String componentAttributesFile = base_path + \"component_attributes.csv\";\n\t\tfinal String componentPopulationName = \"household\";\n\t\tfinal String componentSampleDataFile = base_path + \"component_sample.csv\";\n\t\tfinal String componentIdOnGroup = \"HouseholdID\";\n\t\tfinal String componentControlledAttributesFile = base_path + \"component_controlled_attributes.csv\";\n\t\tfinal String componentControlTotalsFile = base_path + \"component_ipu_control_totals.csv\";\n\t\tfinal String componentSupplementaryAttributesFile = base_path + \"component_supplementary_attributes.csv\";\n\n\t\t\n\t\tnew Expectations() {{\n\t\t\tFileUtils.constructAbsoluteFilePath(scope, anyString, true);\n\t\t\tresult = new Delegate() {\n\t\t\t\tString delegate(IScope scope, String filePath, boolean mustExist) {\n\t\t\t\t\t// group population\n\t\t\t\t\tif (filePath.endsWith(\"/group_attributes.csv\")) { return groupAttributesFilePath; }\n\t\t\t\t\tif (filePath.endsWith(\"/group_sample.csv\")) { return groupSampleDataFile; }\n\t\t\t\t\tif (filePath.endsWith(\"/group_controlled_attributes.csv\")) { return groupControlledAttributesFile; }\n\t\t\t\t\tif (filePath.endsWith(\"/group_ipu_control_totals.csv\")) { return groupControlTotalsFile; }\n\t\t\t\t\tif (filePath.endsWith(\"/group_supplementary_attributes.csv\")) { return groupSupplementaryAttributesFile; }\n\t\t\t\t\t\n\t\t\t\t\t// component population\n\t\t\t\t\tif (filePath.endsWith(\"/component_attributes.csv\")) { return componentAttributesFile; }\n\t\t\t\t\tif (filePath.endsWith(\"/component_sample.csv\")) { return componentSampleDataFile; }\n\t\t\t\t\tif (filePath.endsWith(\"/component_controlled_attributes.csv\")) { return componentControlledAttributesFile; }\n\t\t\t\t\tif (filePath.endsWith(\"/component_ipu_control_totals.csv\")) { return componentControlTotalsFile; }\n\t\t\t\t\tif (filePath.endsWith(\"/component_supplementary_attributes.csv\")) { return componentSupplementaryAttributesFile; }\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\treturn null;\n\t\t\t\t}\n\t\t\t};\n\t\t}};\n\t\t\n\t\t\n\t\tString ipuPopulationPropertiesFilePath = base_path + \"IpuPopulationProperties.properties\";\n\t\tString ruleName = \"dummy rule\";\n\t\t\n\t\tProperties ipuPopulationProperties = null;\n\t\tFile ipuPopulationPropertiesFile = new File(ipuPopulationPropertiesFilePath);\n\t\ttry {\n\t\t\tFileInputStream propertyInputStream = new FileInputStream(ipuPopulationPropertiesFile);\n\t\t\tipuPopulationProperties = new Properties();\n\t\t\tipuPopulationProperties.load(propertyInputStream);\n\t\t} catch (FileNotFoundException e) {\n\t\t\tthrow new GenstarException(e);\n\t\t} catch (IOException e) {\n\t\t\tthrow new GenstarException(e);\n\t\t}\n\t\t\n\t\tSampleBasedGenerator groupGenerator = new SampleBasedGenerator(\"group generator\");\n\t\tGenstarCsvFile groupAttributesFile = new GenstarCsvFile(groupAttributesFilePath, true);\n\t\tAttributeUtils.createAttributesFromCsvFile(groupGenerator, groupAttributesFile);\n\t\t\n\t\tDeprecatedGamaGenstarUtils.createIpuGenerationRule(scope, groupGenerator, ruleName, ipuPopulationProperties);\n\t\t\n\t\tIpuGenerationRule generationRule = (IpuGenerationRule) groupGenerator.getGenerationRule();\n\t\t\n\t\t\n\t\tGenstarCsvFile _groupControlledAttributesFile = Deencapsulation.getField(generationRule, \"groupControlledAttributesFile\");\n\t\tassertTrue(_groupControlledAttributesFile.getPath().equals(groupControlledAttributesFile));\n\t\t\n\t\tGenstarCsvFile _groupControlTotalsFile = Deencapsulation.getField(generationRule, \"groupControlTotalsFile\");\n\t\tassertTrue(_groupControlTotalsFile.getPath().equals(groupControlTotalsFile));\n\t\t\n\t\tGenstarCsvFile _groupSupplementaryAttributesFile = Deencapsulation.getField(generationRule, \"groupSupplementaryAttributesFile\");\n\t\tassertTrue(_groupSupplementaryAttributesFile.getPath().equals(groupSupplementaryAttributesFile));\n\t\t\n\t\t\n\t\tGenstarCsvFile _componentControlledAttributesFile = Deencapsulation.getField(generationRule, \"componentControlledAttributesFile\");\n\t\tassertTrue(_componentControlledAttributesFile.getPath().equals(componentControlledAttributesFile));\n\t\t\n\t\tGenstarCsvFile _componentControlTotalsFile = Deencapsulation.getField(generationRule, \"componentControlTotalsFile\");\n\t\tassertTrue(_componentControlTotalsFile.getPath().equals(componentControlTotalsFile));\n\t\t\n\t\tGenstarCsvFile _componentSupplementaryAttributesFile = Deencapsulation.getField(generationRule, \"componentSupplementaryAttributesFile\");\n\t\tassertTrue(_componentSupplementaryAttributesFile.getPath().equals(componentSupplementaryAttributesFile));\n\t}",
"@Test public void testCreateIpfGenerationRule(@Mocked final IScope scope, @Mocked final FileUtils fileUtils) throws GenstarException {\n\t\t\n\t\t\n\t\tfinal String attributesFilePath = \"test_data/ummisco/genstar/gama/GamaGenstarUtilsTest/testCreateIpfGenerationRule/attributes.csv\";\n\t\tfinal String sampleFilePath = \"test_data/ummisco/genstar/gama/GamaGenstarUtilsTest/testCreateIpfGenerationRule/sample_data.csv\";\n\t\tfinal String controlledAttributesFilePath = \"test_data/ummisco/genstar/gama/GamaGenstarUtilsTest/testCreateIpfGenerationRule/controlled_attributes.csv\";\n\t\tfinal String controlTotalsFilePath = \"test_data/ummisco/genstar/gama/GamaGenstarUtilsTest/testCreateIpfGenerationRule/control_totals.csv\";\n\t\tfinal String supplementaryAttributesFilePath = \"test_data/ummisco/genstar/gama/GamaGenstarUtilsTest/testCreateIpfGenerationRule/supplementary_attributes.csv\";\n\t\t \n\t\t\n\t\tnew Expectations() {{\n\t\t\tFileUtils.constructAbsoluteFilePath(scope, anyString, true);\n\t\t\tresult = new Delegate() {\n\t\t\t\tString delegate(IScope scope, String filePath, boolean mustExist) {\n\t\t\t\t\tif (filePath.endsWith(\"/attributes.csv\")) { return attributesFilePath; }\n\t\t\t\t\tif (filePath.endsWith(\"/sample_data.csv\")) { return sampleFilePath; }\n\t\t\t\t\tif (filePath.endsWith(\"/controlled_attributes.csv\")) { return controlledAttributesFilePath; }\n\t\t\t\t\tif (filePath.endsWith(\"/control_totals.csv\")) { return controlTotalsFilePath; }\n\t\t\t\t\tif (filePath.endsWith(\"/supplementary_attributes.csv\")) { return supplementaryAttributesFilePath; }\n\t\t\t\t\t\n\t\t\t\t\treturn null;\n\t\t\t\t}\n\t\t\t};\n\t\t}};\n\t\t\n\t\t\n\t\tString ruleName = \"dummy rule\";\n\t\t\n\t\tProperties ipfPopulationProperties = null;\n\t\tFile ipfPopulationPropertiesFile = new File(\"test_data/ummisco/genstar/gama/GamaGenstarUtilsTest/testCreateIpfGenerationRule/IpfPopulationProperties.properties\");\n\t\ttry {\n\t\t\tFileInputStream propertyInputStream = new FileInputStream(ipfPopulationPropertiesFile);\n\t\t\tipfPopulationProperties = new Properties();\n\t\t\tipfPopulationProperties.load(propertyInputStream);\n\t\t} catch (FileNotFoundException e) {\n\t\t\tthrow new GenstarException(e);\n\t\t} catch (IOException e) {\n\t\t\tthrow new GenstarException(e);\n\t\t}\n\n\t\t\n\t\tSampleBasedGenerator generator = new SampleBasedGenerator(\"dummy generator\");\n\t\t\n\t\tGenstarCsvFile attributesFile = new GenstarCsvFile(attributesFilePath, true);\n\t\tAttributeUtils.createAttributesFromCsvFile(generator, attributesFile);\n\t\t\n\t\tDeprecatedGamaGenstarUtils.createIpfGenerationRule(scope, generator, ruleName, ipfPopulationProperties);\n\t\t\n\t\tassertTrue(generator.getGenerationRule() instanceof IpfGenerationRule);\n\n\t\tIpfGenerationRule generationRule = (IpfGenerationRule) generator.getGenerationRule();\n\t\tassertTrue(generationRule.getSampleData() instanceof SampleData);\n\t}",
"@DSGenerator(tool_name = \"Doppelganger\", tool_version = \"2.0\", generated_on = \"2013-12-30 12:36:02.373 -0500\", hash_original_method = \"00F8174F9E89D0C972FA6D3F19742382\", hash_generated_method = \"D90463461B2A94FF94D13FDF69BB80C9\")\n \npublic int describeContents() {\n return 0;\n }",
"@Test\n\tpublic void testHardPuzzleGeneration() {\n\t}",
"public static void printGeneratedCombinationInferredSafety() {\n\t\tfinal int random_distance = randomizer(LARGE_DISTANCE * 3);\n\t\tfinal int random_duration = randomizer(LARGE_DURATION * 3);\n\t\tfinal int random_exhalation = randomizer(LARGE_EXHALATION_LEVEL * 3);\n\t\t\n\t\tfinal boolean isSafe = isInferredSafe(random_distance, random_duration, random_exhalation);\n\t\t\n\t\tSystem.out.println(\"\" + random_distance + COMMA + random_duration + COMMA + random_exhalation + COMMA + isSafe + \"\");\n\t}",
"@Test\n public void testLoadOptionalForceCreate() throws ConfigurationException\n {\n factory.setBasePath(TEST_FILE.getParent());\n CombinedConfiguration config = prepareOptionalTest(\"xml\", true);\n assertEquals(\"Wrong number of configurations\", 1, config\n .getNumberOfConfigurations());\n FileConfiguration fc = (FileConfiguration) config\n .getConfiguration(OPTIONAL_NAME);\n assertNotNull(\"Optional config not found\", fc);\n assertEquals(\"File name was not set\", \"nonExisting.xml\", fc\n .getFileName());\n assertNotNull(\"Base path was not set\", fc.getBasePath());\n }",
"@Test\n\tpublic void checkDetailedURLGeneration() {\n\t\tint neoID=1234;\n\t\tString expected = genDetailedURL(neoID);\n\t\tString result = urlHelper.getDetailedNeoInfoURL(neoID);\n\t\tassertEquals(expected,result);\n\t}",
"@Test\n\tpublic void testAutomaticSchemaGeneration() throws JsonProcessingException {\n\t\tfinal GQLExecutionResult schemaIntrospectionManual = getSchemaIntrospection(getDefaultExecutionContext(),\n\t\t\t\tfalse);\n\t\tfinal String jsonManual = WRITER_PRETTY.writeValueAsString(schemaIntrospectionManual.toSpecification());\n\t\tfinal GQLExecutionResult schemaIntrospectionAutomatic = getSchemaIntrospection(getDefaultExecutionContext(),\n\t\t\t\ttrue);\n\t\tfinal String jsonAutomatic = WRITER_PRETTY.writeValueAsString(schemaIntrospectionAutomatic.toSpecification());\n\t\tAssert.assertEquals(jsonManual, jsonAutomatic);\n\t}",
"public abstract String generate(Object... args);",
"public void shouldCreate() {\n }",
"@Test\n public void testGenerateString() {\n System.out.println(\"generateString\");\n VM instance = null;\n String expResult = \"\";\n String result = instance.generateString();\n assertEquals(expResult, result);\n // TODO review the generated test code and remove the default call to fail.\n fail(\"The test case is a prototype.\");\n }",
"public abstract void generateQuestion();",
"@Test\n\tpublic void testTotalPuzzleGenerated() {\n\t}",
"public static void printGivenAndGeneratedCombinationsInferredSafety() {\n\t\tSystem.out.println(GENERATE_START);\n\t\n\t\tfor(int row = 0; row < SAFE_COMBINATIONS.length; row++) {\n\t\t\tSystem.out.print(\"\");\n\t\t\tfor(int col = 0; col < SAFE_COMBINATIONS[0].length; col++) {\n\t\t\t\tSystem.out.print(SAFE_COMBINATIONS[row][col] + COMMA);\n\t\t\t}\n\t\t\tSystem.out.print(true + NEWLINE);\n\t\t}\n\t\t\n\t\tSystem.out.println(LINE_BREAK);\n\t\t\n\t\tfor(int i = 0; i < 10; i++) {\n\t\t\tprintGeneratedCombinationInferredSafety();\n\t\t}\n\t}",
"@SuppressWarnings(\"unused\")\n private void generateInfo()\n {\n }",
"@Test\n\tpublic void shouldGenerateSomeStuff() {\n\t\tString applicationName = \"cool-application-name\";\n\t\tEngagement engagement = buildSingleClusterMultiProjectEngagementNoBuildTool(applicationName);\n\t\tGson gson = new GsonBuilder().create();\n\t\tString output = gson.toJson(engagement);\n\t\tLOGGER.info(\"{}{}{}\",\"\\n\\n\", output, \"\\n\\n\");\n\t}",
"@Test\r\n\tvoid testGeneratePlayersShouldPass() {\r\n\t\tModel dataModel = new Model();\r\n\t\t\r\n\t\tdataModel.generateSquads();\r\n\t\tdataModel.generatePlayers();\r\n\t\t\r\n\t\tArrayList<Player> players = dataModel.getAllPlayers();\r\n\t\t\r\n\t\tint size = players.size();\r\n\t\tassertNotEquals(0, size);\r\n\t}",
"@Test\r\n public void testBooleanFlagAndNoValue() throws Exception {\r\n PluginTestCase<I>[] inputs = getTestData().getFlagCases();\r\n for (PluginTestCase<I> testCase : inputs) {\r\n System.out.println(testCase.toString());\r\n BooleanWithNoArgument model = getPopulatedModel(testCase.input, BooleanWithNoArgument.class);\r\n assertThat(model.boolFlag, is(true));\r\n }\r\n\r\n }",
"@Test\n public void testGenerateStatistics() {\n Statistics me = new Statistics(0, numFishes, numSharks);\n Statistics prog = dataHandler.generateStatistics();\n //assertEquals(me, prog);\n if (me.getIterationStep() == prog.getIterationStep()\n && me.getFishAmount() == prog.getFishAmount()\n && me.getSharksAmount() == prog.getSharksAmount()) {\n assertTrue(true);\n } else {\n assertTrue(false);\n }\n }",
"@Test\n public void testLoadOptionalForceCreateWithException()\n throws ConfigurationException\n {\n factory.addConfigurationProvider(\"test\",\n new DefaultConfigurationBuilder.ConfigurationBuilderProvider()\n {\n // Throw an exception here, too\n @Override\n public AbstractConfiguration getEmptyConfiguration(\n DefaultConfigurationBuilder.ConfigurationDeclaration decl) throws Exception\n {\n throw new Exception(\"Unable to create configuration!\");\n }\n });\n CombinedConfiguration config = prepareOptionalTest(\"test\", true);\n assertEquals(\"Optional configuration could be created\", 0, config\n .getNumberOfConfigurations());\n }",
"GenotypeTest(int no, int no_copies)\n/* */ throws Exception\n/* */ {}",
"public void setGeneratedCheck(){\n generatedCheck = !generatedCheck;\n }",
"@Override\n void generateFalseData() {\n \n }",
"@Test(timeout = 4000)\n public void test076() throws Throwable {\n String string0 = Evaluation.makeOptionString((Classifier) null, true);\n assertNotNull(string0);\n }",
"public boolean isForGenere();",
"public void generate(PSGenerator gen) throws IOException {\n/* 146 */ if (this.resources == null || this.resources.size() == 0) {\n/* */ return;\n/* */ }\n/* 149 */ StringBuffer sb = new StringBuffer();\n/* 150 */ sb.append(\"%%\").append(getName()).append(\": \");\n/* 151 */ boolean first = true;\n/* 152 */ Iterator<PSResource> i = this.resources.iterator();\n/* 153 */ while (i.hasNext()) {\n/* 154 */ if (!first) {\n/* 155 */ gen.writeln(sb.toString());\n/* 156 */ sb.setLength(0);\n/* 157 */ sb.append(\"%%+ \");\n/* */ } \n/* 159 */ PSResource res = i.next();\n/* 160 */ sb.append(res.getResourceSpecification());\n/* 161 */ first = false;\n/* */ } \n/* 163 */ gen.writeln(sb.toString());\n/* */ }",
"@Test\r\n\tpublic void testPositiveGenerateInteger_2() {\n\t\tint i = 1;\r\n\t\tfor (RandomOrgClient roc : rocs) {\r\n\t\t\ttry {\r\n\t\t\t\tcollector.checkThat(roc.generateIntegers(10, 0, 10, false), notNullValue());\r\n\t\t\t} catch (Exception e) {\r\n\t\t\t\tcollector.addError(new Error(errorMessage(i, e, true)));\r\n\t\t\t}\r\n\t\t\ti++;\r\n\t\t}\r\n\t}",
"void generateDefaultValue(Builder methodBuilder);",
"public static void printGeneratedCombination() {\n\t\t\n\t\tfinal int randomDistance = randomizer(LARGE_DISTANCE * 3);\n\t\tfinal int randomDuration = randomizer(LARGE_DURATION * 3);\n\t\tfinal int randomExhalation = randomizer(LARGE_EXHALATION_LEVEL * 3);\n\t\t\n\t\tfinal boolean isSafe = isInterpolatedSafe(randomDistance, randomDuration, randomExhalation);\n\t\t\n\t\tSystem.out.println(\"(\" + randomDistance + COMMA + randomDuration + COMMA + randomExhalation + COMMA + isSafe + \")\");\n\t\t\n\t}",
"@Override\n\tpublic void generarFactura() {\n\t\t\n\t}",
"@Test\n public void shouldCreateEpiDataGathering() {\n assertThat(DatabaseHelper.getEpiDataGatheringDao().queryForAll().size(), is(0));\n\n Case caze = TestEntityCreator.createCase();\n TestEntityCreator.createEpiDataGathering(caze);\n\n // Assure that the burial has been successfully created\n assertThat(DatabaseHelper.getEpiDataGatheringDao().queryForAll().size(), is(1));\n }",
"@Test\n void getMandatoryDeepSuccessors () {\n\n }",
"public abstract void generateForce(String args[]);",
"public Builder setGenerateNotEmpty(boolean generateNotEmpty){\n mGenerateNotEmpty = generateNotEmpty;\n return this;\n }",
"@Test\n\tpublic void testGenerateCompany() throws Exception {\n\n\t}",
"public void setGenerateNotEmpty(boolean generateNotEmpty){\n mGenerateNotEmpty = generateNotEmpty;\n }",
"@Test\n public void generateDescription_walking_caloriesGoal() {\n Goal goal = new Goal(2, 99, GoalType.Walk, \"2018-09-28\", \"2017-01-12\",\n 400);\n // Create the real and expected descriptions\n description = goal.getDescription();\n expectedDescription = \"Burn 400 calories while walking\";\n\n // Check that the real and expected descriptions match\n assertEquals(expectedDescription, description);\n }",
"@Test\r\n\tpublic void testPositiveGenerateInteger_3() {\n\t\tint i = 1;\r\n\t\tfor (RandomOrgClient roc : rocs) {\r\n\t\t\ttry {\r\n\t\t\t\tcollector.checkThat(roc.generateIntegers(10, 0, 10, false, 16), notNullValue());\r\n\t\t\t} catch (Exception e) {\r\n\t\t\t\tcollector.addError(new Error(errorMessage(i, e, true)));\r\n\t\t\t}\r\n\t\t\ti++;\r\n\t\t}\r\n\t}",
"@Test \r\n\tvoid testGenerateSquadsShouldPass() {\r\n\t\tModel dataModel = new Model();\r\n\t\t\r\n\t\tdataModel.generateSquads();\r\n\t\t\r\n\t\tArrayList<Squad> squads = dataModel.getSquads();\r\n\t\t\r\n\t\tint size = squads.size();\r\n\t\t\r\n\t\tassertNotEquals(0, size);\r\n\t}",
"public boolean isGenerative () { return false; }",
"@Override\r\n public void execute() throws BuildException { \r\n AbstractGenerator g;\r\n \r\n if (kind == null) {\r\n throw new BuildException(\"kind was not specified\");\r\n }\r\n final String k = kind.getValue();\r\n if (k.equals(INTERFACE)) {\r\n g = new InterfaceGen();\r\n }\r\n else if (k.equals(CRYSTAL)) {\r\n g = new CrystalGen();\r\n }\r\n else if (k.equals(OPERATOR)) {\r\n g = new OperatorGen();\r\n }\r\n else {\r\n throw new BuildException(\"Unknown kind was specified: \"+kind);\r\n }\r\n if (dest != null) {\r\n srcs.add(0, \"-out\");\r\n srcs.add(1, dest);\r\n }\r\n g.generate(srcs.toArray(new String[srcs.size()]));\r\n }",
"public void generateAndwriteToFile() {\n List<GeneratedJavaFile> gjfs = generate();\n if (gjfs == null || gjfs.size() == 0) {\n return;\n }\n for (GeneratedJavaFile gjf : gjfs) {\n writeToFile(gjf);\n }\n }",
"@Test\n public void testDeleteGeneratedEmptyFile() throws Throwable {\n String resources = getResourceFolder();\n String outputFile = resources + \"/out/test_deleteGeneratedEmptyFile.csv\";\n LOGGER.debug(\"Test file path: \" + outputFile);\n TFileOutputDelimitedProperties properties = createOutputProperties(outputFile, false);\n List<IndexedRecord> records = new ArrayList<>();\n // Delete generated empty file function not be checked\n doWriteRows(properties, records);\n File outFile = new File(outputFile);\n assertTrue(outFile.exists());\n assertEquals(0, outFile.length());\n assertTrue(outFile.delete());\n // Active delete generated empty file function\n assertFalse(outFile.exists());\n properties.deleteEmptyFile.setValue(true);\n doWriteRows(properties, records);\n assertFalse(outFile.exists());\n\n }",
"public static void generateDefaults() {\n Building temp = BuildingList.getBuilding(0);\n SubAreas temp2 = temp.getSubArea(1);\n temp2.createFireSensor();\n temp2.createMotionSensor();\n temp2 = temp.getSubArea(2);\n temp2.createMotionSensor();\n temp2 = temp.getSubArea(3);\n temp2.createMotionSensor();\n temp2.createFireSensor();\n temp2 = temp.getSubArea(5);\n temp2.createFireSensor();\n temp2 = temp.getSubArea(6);\n temp2.createFireSensor();\n temp2.createMotionSensor();\n }",
"public Builder setGenerateEmpty(boolean generateEmpty){\n mGenerateEmpty = generateEmpty;\n return this;\n }",
"public Generator<V> getDefaultValueGenerator();",
"ObjectFactoryGenerator objectFactoryGenerator();",
"private TipoAtaque generateTipoAtaque() {\n\t\treturn null;\r\n\t}",
"public static void printGivenAndGeneratedCombinations() {\n\t\tSystem.out.println(GENERATE_START);\n\t\t\n\t\tfor(int row = 0; row < SAFE_COMBINATIONS.length; row++) {\n\t\t\tfor(int col = 0; col < SAFE_COMBINATIONS[0].length; col++) {\n\t\t\t\tSystem.out.print(SAFE_COMBINATIONS[row][col] + COMMA);\n\t\t\t}\n\t\t\tSystem.out.print(true + NEWLINE);\n\t\t}\n\t\t\n\t\tSystem.out.println(LINE_BREAK);\n\t\t\n\t\tfor(int i = 0; i < 10; i++) {\n\t\t\tprintGeneratedCombination();\n\t\t}\n\t\t\n\t}",
"public void setGenerateEmpty(boolean generateEmpty){\n mGenerateEmpty = generateEmpty;\n }",
"private void generateData(){\n generateP50boys();\n generateP50girls();\n generateP97boys();\n generateP97girls();\n }",
"public void testBuilderPredefined() throws IOException {\n doTest();\n }",
"@Test\n public void generateDescription_walking_durationGoal_singularHours() {\n Goal goal = new Goal(2, 99, GoalType.Walk,\"2018-09-28\", \"2017-01-12\",\n \"PT1H40M\");\n // Create the real and expected descriptions\n description = goal.getDescription();\n expectedDescription = \"Walk for 1 hour and 40 minutes\";\n\n // Check that the real and expected descriptions match\n assertEquals(expectedDescription, description);\n }",
"@Test\n public void testGenerarCodigo() {\n System.out.println(\"generarCodigo\");\n Nodo miNodo = null;\n String cadena = \"\";\n Huffman instance = null;\n instance.generarCodigo(miNodo, cadena);\n // TODO review the generated test code and remove the default call to fail.\n \n }",
"@Test\n public void generateDescription_running_caloriesGoal() {\n Goal goal = new Goal(2, 99, GoalType.Run, \"2018-09-28\", \"2017-01-12\",\n 400);\n // Create the real and expected descriptions\n description = goal.getDescription();\n expectedDescription = \"Burn 400 calories while running\";\n\n // Check that the real and expected descriptions match\n assertEquals(expectedDescription, description);\n }",
"@org.junit.Test\n public void testGetFirst() {\n System.out.println(\"getFirst\");\n TestDataGenerator instance = new TestDataGenerator();\n First result = instance.getFirst();\n //\n Assert.assertEquals(\"Here is a string to check\", result.getOruString());\n Assert.assertEquals(444422, result.getOruInt());\n Assert.assertTrue(result.isOruBoolean());\n Assert.assertEquals(8.8886664E7f, result.getOruFloat(), 0);\n Assert.assertEquals(5555533333222L, result.getOruLong());\n Assert.assertEquals(9.99966663322E9, result.getOruDoble(), 0);\n Assert.assertEquals(OruEnum.FIRST_ENUM, result.getOruEnum());\n Assert.assertNotNull(result.getSecond());\n // Second //\n Assert.assertEquals(531223, result.getSecond().getSecondInt());\n Assert.assertEquals(666666666L, result.getSecond().getOruLong());\n Assert.assertEquals(\"Here is a second String\", result.getSecond().getSecondString());\n Assert.assertFalse(result.getSecond().isSecondBoolean());\n Assert.assertEquals(4444.333f, result.getSecond().getSecondFloat(), 0);\n Assert.assertEquals(555555.55555, result.getSecond().getSecondDoble(), 0);\n Assert.assertNotNull(result.getListOfThrird());\n //Collection\n Assert.assertEquals(3, result.getListOfThrird().size());\n // 1\n Thrird thrird = result.getListOfThrird().get(0);\n Assert.assertEquals(0, thrird.getThrirdInt());\n Assert.assertEquals(0L, thrird.getThrirdLong());\n Assert.assertEquals(\"Thrird String 0\", thrird.getThrirdString());\n Assert.assertTrue(thrird.isThrirdBoolean());\n Assert.assertEquals(0.0f, thrird.getThrirdFloat(), 0);\n Assert.assertEquals(0.0, thrird.getThrirdDoble(), 0);\n // 2\n Thrird thrird2 = result.getListOfThrird().get(1);\n Assert.assertEquals(1, thrird2.getThrirdInt());\n Assert.assertEquals(1L, thrird2.getThrirdLong());\n Assert.assertEquals(\"Thrird String 1\", thrird2.getThrirdString());\n Assert.assertTrue(thrird2.isThrirdBoolean());\n Assert.assertEquals(1.0f, thrird2.getThrirdFloat(), 0);\n Assert.assertEquals(1.0, thrird2.getThrirdDoble(), 0);\n // 3\n Thrird thrird3 = result.getListOfThrird().get(2);\n Assert.assertEquals(2, thrird3.getThrirdInt());\n Assert.assertEquals(2L, thrird3.getThrirdLong());\n Assert.assertEquals(\"Thrird String 2\", thrird3.getThrirdString());\n Assert.assertTrue(thrird3.isThrirdBoolean());\n Assert.assertEquals(2.0f, thrird3.getThrirdFloat(), 0);\n Assert.assertEquals(2.0, thrird3.getThrirdDoble(), 0);\n Assert.assertNotNull(result.getCollectionOfObjects());\n //Collection\n //Support for [java.util.HashMap$KeySet] is yet to be added\n Assert.assertNotNull(result.getMapOfThrird());\n //MAP\n Assert.assertEquals(5, result.getMapOfThrird().size());\n // 1\n Thrird thrird4 = result.getMapOfThrird().get(\"KEY_12\");\n Assert.assertEquals(12, thrird4.getThrirdInt());\n Assert.assertEquals(12L, thrird4.getThrirdLong());\n Assert.assertEquals(\"Thrird String 12\", thrird4.getThrirdString());\n Assert.assertTrue(thrird4.isThrirdBoolean());\n Assert.assertEquals(12.0f, thrird4.getThrirdFloat(), 0);\n Assert.assertEquals(12.0, thrird4.getThrirdDoble(), 0);\n // 1\n Thrird thrird5 = result.getMapOfThrird().get(\"KEY_11\");\n Assert.assertEquals(11, thrird5.getThrirdInt());\n Assert.assertEquals(11L, thrird5.getThrirdLong());\n Assert.assertEquals(\"Thrird String 11\", thrird5.getThrirdString());\n Assert.assertTrue(thrird5.isThrirdBoolean());\n Assert.assertEquals(11.0f, thrird5.getThrirdFloat(), 0);\n Assert.assertEquals(11.0, thrird5.getThrirdDoble(), 0);\n // 1\n Thrird thrird6 = result.getMapOfThrird().get(\"KEY_14\");\n Assert.assertEquals(14, thrird6.getThrirdInt());\n Assert.assertEquals(14L, thrird6.getThrirdLong());\n Assert.assertEquals(\"Thrird String 14\", thrird6.getThrirdString());\n Assert.assertTrue(thrird6.isThrirdBoolean());\n Assert.assertEquals(14.0f, thrird6.getThrirdFloat(), 0);\n Assert.assertEquals(14.0, thrird6.getThrirdDoble(), 0);\n // 1\n Thrird thrird7 = result.getMapOfThrird().get(\"KEY_13\");\n Assert.assertEquals(13, thrird7.getThrirdInt());\n Assert.assertEquals(13L, thrird7.getThrirdLong());\n Assert.assertEquals(\"Thrird String 13\", thrird7.getThrirdString());\n Assert.assertTrue(thrird7.isThrirdBoolean());\n Assert.assertEquals(13.0f, thrird7.getThrirdFloat(), 0);\n Assert.assertEquals(13.0, thrird7.getThrirdDoble(), 0);\n // 1\n Thrird thrird8 = result.getMapOfThrird().get(\"KEY_10\");\n Assert.assertEquals(10, thrird8.getThrirdInt());\n Assert.assertEquals(10L, thrird8.getThrirdLong());\n Assert.assertEquals(\"Thrird String 10\", thrird8.getThrirdString());\n Assert.assertTrue(thrird8.isThrirdBoolean());\n Assert.assertEquals(10.0f, thrird8.getThrirdFloat(), 0);\n Assert.assertEquals(10.0, thrird8.getThrirdDoble(), 0);\n Assert.assertNotNull(result.getMapOfObjects());\n //MAP\n Assert.assertEquals(8, result.getMapOfObjects().size());\n Assert.assertEquals(\"VALUE_7\", result.getMapOfObjects().get(\"KEY_FOR_STRING\"));\n Assert.assertEquals(\"VALUE_1\", result.getMapOfObjects().get(new Character('1')));\n Assert.assertEquals(\"VALUE_7\", result.getMapOfObjects().get(new Double(123456.7890625)));\n Assert.assertEquals(\"VALUE_4\", result.getMapOfObjects().get(new Integer(1234567)));\n Assert.assertEquals(\"VALUE_6\", result.getMapOfObjects().get(new Float(1234.56F)));\n Assert.assertEquals(\"VALUE_5\", result.getMapOfObjects().get(new Long(1234567891011L)));\n Assert.assertEquals(\"VALUE_3\", result.getMapOfObjects().get(new Short((short) 12345)));\n Assert.assertEquals(\"VALUE_2\", result.getMapOfObjects().get(new Byte((byte) 123)));\n Assert.assertNotNull(result.getArrayOfThrird());\n //Array\n Assert.assertEquals(5, result.getArrayOfThrird().length);\n // 1\n Thrird thrird9 = result.getArrayOfThrird()[0];\n Assert.assertEquals(0, thrird9.getThrirdInt());\n Assert.assertEquals(0L, thrird9.getThrirdLong());\n Assert.assertEquals(\"Thrird String 0\", thrird9.getThrirdString());\n Assert.assertTrue(thrird9.isThrirdBoolean());\n Assert.assertEquals(0.0f, thrird9.getThrirdFloat(), 0);\n Assert.assertEquals(0.0, thrird9.getThrirdDoble(), 0);\n // 2\n Thrird thrird10 = result.getArrayOfThrird()[1];\n Assert.assertEquals(1, thrird10.getThrirdInt());\n Assert.assertEquals(1L, thrird10.getThrirdLong());\n Assert.assertEquals(\"Thrird String 1\", thrird10.getThrirdString());\n Assert.assertTrue(thrird10.isThrirdBoolean());\n Assert.assertEquals(1.0f, thrird10.getThrirdFloat(), 0);\n Assert.assertEquals(1.0, thrird10.getThrirdDoble(), 0);\n // 3\n Thrird thrird11 = result.getArrayOfThrird()[2];\n Assert.assertEquals(2, thrird11.getThrirdInt());\n Assert.assertEquals(2L, thrird11.getThrirdLong());\n Assert.assertEquals(\"Thrird String 2\", thrird11.getThrirdString());\n Assert.assertTrue(thrird11.isThrirdBoolean());\n Assert.assertEquals(2.0f, thrird11.getThrirdFloat(), 0);\n Assert.assertEquals(2.0, thrird11.getThrirdDoble(), 0);\n // 4\n Assert.assertNull(result.getArrayOfThrird()[3]);\n // 5\n Assert.assertNull(result.getArrayOfThrird()[4]);\n Assert.assertNotNull(result.getArrayOfString());\n //Array\n Assert.assertEquals(3, result.getArrayOfString().length);\n // 1\n Assert.assertEquals(\"array_1\", result.getArrayOfString()[0]);\n // 2\n Assert.assertEquals(\"array_2\", result.getArrayOfString()[1]);\n // 3\n Assert.assertEquals(\"arrat_3\", result.getArrayOfString()[2]);\n }",
"@Test public void testCreateCompoundIpfGenerationRule(@Mocked final IScope scope, @Mocked final FileUtils fileUtils) throws GenstarException {\n\t\t\n\t\tfinal String groupAttributesFilePath = \"test_data/ummisco/genstar/gama/GamaGenstarUtilsTest/testCreateCompoundIpfGenerationRule/group_attributes.csv\";\n\t\tfinal String groupSampleFilePath = \"test_data/ummisco/genstar/gama/GamaGenstarUtilsTest/testCreateCompoundIpfGenerationRule/group_sample.csv\";\n\t\tfinal String controlledAttributesFilePath = \"test_data/ummisco/genstar/gama/GamaGenstarUtilsTest/testCreateCompoundIpfGenerationRule/group_controlled_attributes.csv\";\n\t\tfinal String controlTotalsFilePath = \"test_data/ummisco/genstar/gama/GamaGenstarUtilsTest/testCreateCompoundIpfGenerationRule/group_control_totals.csv\";\n\t\tfinal String supplementaryAttributesFilePath = \"test_data/ummisco/genstar/gama/GamaGenstarUtilsTest/testCreateCompoundIpfGenerationRule/group_supplementary_attributes.csv\";\n\t\t\n\t\tfinal String componentSampleFilePath = \"test_data/ummisco/genstar/gama/GamaGenstarUtilsTest/testCreateCompoundIpfGenerationRule/component_sample.csv\";\n\t\tfinal String componentAttributesFilePath = \"test_data/ummisco/genstar/gama/GamaGenstarUtilsTest/testCreateCompoundIpfGenerationRule/component_attributes.csv\";\n\t\t\n\t\t\n\t\tnew Expectations() {{\n\t\t\tFileUtils.constructAbsoluteFilePath(scope, anyString, true);\n\t\t\tresult = new Delegate() {\n\t\t\t\tString delegate(IScope scope, String filePath, boolean mustExist) {\n\t\t\t\t\tif (filePath.endsWith(\"/group_attributes.csv\")) { return groupAttributesFilePath; }\n\t\t\t\t\tif (filePath.endsWith(\"/group_sample.csv\")) { return groupSampleFilePath; }\n\t\t\t\t\tif (filePath.endsWith(\"/group_controlled_attributes.csv\")) { return controlledAttributesFilePath; }\n\t\t\t\t\tif (filePath.endsWith(\"/group_control_totals.csv\")) { return controlTotalsFilePath; }\n\t\t\t\t\tif (filePath.endsWith(\"/group_supplementary_attributes.csv\")) { return supplementaryAttributesFilePath; }\n\t\t\t\t\t\n\t\t\t\t\tif (filePath.endsWith(\"/component_sample.csv\")) { return componentSampleFilePath; }\n\t\t\t\t\tif (filePath.endsWith(\"/component_attributes.csv\")) { return componentAttributesFilePath; }\n\t\t\t\t\t\n\t\t\t\t\treturn null;\n\t\t\t\t}\n\t\t\t};\n\t\t}};\n\t\t \n\t\t\n\t\tString ruleName = \"dummy rule\";\n\t\t\n\t\tProperties ipfPopulationProperties = null;\n\t\tFile ipfPopulationPropertiesFile = new File(\"test_data/ummisco/genstar/gama/GamaGenstarUtilsTest/testCreateCompoundIpfGenerationRule/IpfPopulationProperties.properties\");\n\t\ttry {\n\t\t\tFileInputStream propertyInputStream = new FileInputStream(ipfPopulationPropertiesFile);\n\t\t\tipfPopulationProperties = new Properties();\n\t\t\tipfPopulationProperties.load(propertyInputStream);\n\t\t} catch (FileNotFoundException e) {\n\t\t\tthrow new GenstarException(e);\n\t\t} catch (IOException e) {\n\t\t\tthrow new GenstarException(e);\n\t\t}\n\t\t\n\t\t\n\t\tSampleBasedGenerator generator = new SampleBasedGenerator(\"dummy generator\");\n\t\t\n\t\tGenstarCsvFile attributesFile = new GenstarCsvFile(groupAttributesFilePath, true);\n\t\tAttributeUtils.createAttributesFromCsvFile(generator, attributesFile);\n\t\t\n\t\tDeprecatedGamaGenstarUtils.createIpfGenerationRule(scope, generator, ruleName, ipfPopulationProperties);\n\t\t\n\t\tassertTrue(generator.getGenerationRule() instanceof IpfGenerationRule);\n\n\t\tIpfGenerationRule generationRule = (IpfGenerationRule) generator.getGenerationRule();\n\t\tassertTrue(generationRule.getSampleData() instanceof CompoundSampleData);\n\t}",
"public boolean generate() {\n System.out.println(\"Before generating, up to how many courses would you take at once?\");\n maxClassesAtOnce = obtainIntSafely(1, 8, \"This must be a positive integer less than 8\");\n\n int option = optionQuestion(\"Would you like to compute a list of possible schedules \"\n + \" via simple tree (1), permutation tree (2), or semi-permutation tree (3). \"\n + \"\\n WARNING: PERMUTATION TREE CAN BE VERY SLOW AND SHOULD ONLY BE \"\n + \"USED WITH A SMALL SELECTION OF CLASSES \\n Option 3 is Recommended\", 3);\n\n Boolean returnBool = true;\n\n switch (option) {\n case 1:\n returnBool = simpleDesigner(activeCourseList);\n break;\n case 2:\n returnBool = createPermutationSchedule();\n break;\n case 3:\n returnBool = createSemiPermutationSchedule();\n break;\n }\n if (!returnBool) {\n System.out.println(\"Impossible to make a schedule\");\n }\n return returnBool;\n }",
"boolean generateAutomata()\n{\n empty_calls = new HashSet<JflowMethod>();\n event_calls = new HashSet<JflowMethod>();\n complete_calls = new LinkedHashMap<JflowMethod,ModelMethod>();\n methods_todo = new LinkedHashSet<JflowMethod>();\n return_set = new HashMap<JflowMethod,Boolean>();\n\n start_set = new HashSet<JflowMethod>();\n for (JflowMethod cm : model_master.getStartMethods()) {\n methods_todo.add(cm);\n start_set.add(cm);\n }\n\n while (!methods_todo.isEmpty()) {\n Iterator<JflowMethod> it = methods_todo.iterator();\n if (!it.hasNext()) break;\n JflowMethod cm = it.next();\n it.remove();\n if (!empty_calls.contains(cm) && !complete_calls.containsKey(cm)) {\n\t if (!model_master.checkUseMethod(cm) || !model_master.isMethodAccessible(cm.getMethod()) ||\n\t\tcm.getMethod().isAbstract()) {\n\t if (model_master.doDebug()) {\n\t System.err.println(\"Ignore method: \" + cm.getMethodName() + \" \" +\n\t\t\t\t cm.getMethodSignature() + \" \" +\n\t\t\t\t model_master.checkUseMethod(cm) + \" \" +\n\t\t\t\t model_master.isMethodAccessible(cm.getMethod()));\n\t }\n\t empty_calls.add(cm);\n\t }\n\t else {\n\t ModelBuilder bld = new ModelBuilder(model_master,this,cm);\n\t complete_calls.put(cm,null);\n\t ModelMethod cs = bld.createAutomata();\n\t if (cs == null) empty_calls.add(cm);\n\t else complete_calls.put(cm,cs);\n\t }\n }\n }\n\n Set<JflowMethod> workq = new LinkedHashSet<JflowMethod>();\n for (Map.Entry<JflowMethod,ModelMethod> ent : complete_calls.entrySet()) {\n JflowMethod bm = ent.getKey();\n ModelMethod cs = ent.getValue();\n if (cs == null) continue;\n Set<JflowModel.Node> states = simplify(cs.getStartState());\n int ctr = 0;\n boolean hasrtn = false;\n for (JflowModel.Node st1 : states) {\n\t if (st1.getEvent() != null) event_calls.add(bm);\n\t else if (st1.getFieldSet() != null) event_calls.add(bm);\n\t if (!hasrtn && st1.getReturnValue() != null) hasrtn = true;\n\t JflowMethod cm = st1.getCall();\n\t if (cm != null) {\n\t if (event_calls.contains(cm)) event_calls.add(bm);\n\t else {\n\t ++ctr;\n\t ModelMethod ncs = complete_calls.get(cm);\n\t if (ncs != null) ncs.addUser(bm);\n\t else System.err.println(\"Call to \" + cm.getMethodName() + \" not found\");\n\t }\n\t }\n }\n return_set.put(bm,Boolean.valueOf(hasrtn));\n\n if (model_master.doDebug()) {\n\t System.err.println(\"First pass method \" + bm.getMethodName() + \" \" +\n\t\t\t bm.getMethodSignature() + \" \" + ctr + \" \" +\n\t\t\t states.size() + \" \" + event_calls.contains(bm));\n }\n if (ctr == 0) {\n\t if (!event_calls.contains(bm)) empty_calls.add(bm);\n }\n else {\n\t workq.add(bm);\n }\n }\n if (model_master.doDebug()) System.err.println(\"Work queue size = \" + workq.size());\n if (event_calls.size() == 0) return false;\n\n Set<JflowMethod> returnused = null;\n boolean chng = true;\n while (chng) {\n chng = false;\n returnused = new HashSet<JflowMethod>();\n while (!workq.isEmpty()) {\n\t Iterator<JflowMethod> it = workq.iterator();\n\t if (!it.hasNext()) break;\n\t JflowMethod bm = it.next();\n\t it.remove();\n\t ModelMethod cs = complete_calls.get(bm);\n\t boolean chkit = !event_calls.contains(bm);\n\n\t if (cs == null || empty_calls.contains(bm)) continue;\n\n\t int ctr = 0;\n\t Set<JflowModel.Node> states = simplify(cs.getStartState());\n\t boolean mchng = false;\n\t boolean hasrtn = false;\n\t for (JflowModel.Node st1 : states) {\n\t if (!hasrtn && st1.getReturnValue() != null) hasrtn = true;\n\t JflowMethod cm = st1.getCall();\n\t if (cm != null) {\n\t if (st1.getUseReturn()) returnused.add(cm);\n\t if (!event_calls.contains(cm)) {\n\t\t ++ctr;\n\t\t}\n\t else if (chkit) {\n\t\t if (model_master.doDebug()) {\n\t\t System.err.println(\"Method required: \" + bm.getMethodName() + \" \" +\n\t\t\t\t\t bm.getMethodSignature() + \" :: \" + cm.getMethodName() +\n\t\t\t\t\t \" \" + cm.getMethodSignature());\n\t\t }\n\t\t event_calls.add(bm);\n\t\t chkit = false;\n\t\t mchng = true;\n\t\t}\n\t }\n\t }\n\n\t if (return_set.get(bm) != Boolean.FALSE) {\n\t return_set.put(bm,Boolean.valueOf(hasrtn));\n\t if (!hasrtn) mchng = true;\n\t }\n\n\t if (ctr == 0 && !event_calls.contains(bm)) {\n\t empty_calls.add(bm);\n\t mchng = true;\n\t }\n\n\t if (model_master.doDebug()) System.err.println(\"Consider method \" + bm.getMethodName() + \" \" + bm.getMethodSignature() + \" \" + ctr + \" \" + states.size() + \" \" + mchng);\n\n\t if (mchng) {\n\t for (Iterator<?> it1 = cs.getUsers(); it1.hasNext(); ) {\n\t JflowMethod cm = (JflowMethod) it1.next();\n\t if (model_master.doDebug()) System.err.println(\"\\tQueue \" + cm.getMethodName() + \" \" + cm.getMethodSignature());\n\t workq.add(cm);\n\t }\n\t }\n }\n\n for (Map.Entry<JflowMethod,ModelMethod> ent : complete_calls.entrySet()) {\n\t JflowMethod bm = ent.getKey();\n\t ModelMethod cs = ent.getValue();\n\t if (cs != null && !empty_calls.contains(bm) && !event_calls.contains(bm)) {\n\t empty_calls.add(bm);\n\t chng = true;\n\t for (Iterator<JflowMethod> it1 = cs.getUsers(); it1.hasNext(); ) {\n\t JflowMethod cm = it1.next();\n\t if (model_master.doDebug()) System.err.println(\"\\tQueue \" + cm.getMethodName() + \" \" + cm.getMethodSignature());\n\t workq.add(cm);\n\t }\n\t }\n }\n }\n\n for (JflowMethod cm : empty_calls) {\n complete_calls.remove(cm);\n }\n\n chng = true;\n boolean needsync = true;\n while (chng) {\n chng = false;\n boolean nextsync = false;\n for (ModelMethod em : complete_calls.values()) {\n\t Set<JflowModel.Node> sts = simplify(em.getStartState());\n\t if (!needsync) {\n\t for (JflowModel.Node nms : sts) {\n\t ModelState ms = (ModelState) nms;\n\t if (ms.getWaitType() != ModelWaitType.NONE) {\n\t\t ms.clearCall();\n\t\t chng = true;\n\t\t}\n\t }\n\t }\n\t else if (!nextsync) {\n\t for (JflowModel.Node ms : sts) {\n\t if (ms.getCall() != null && ms.isAsync()) nextsync = true;\n\t }\n\t }\n\t if (return_set.get(em.getMethod()) != Boolean.FALSE && returnused != null && \n\t\t!returnused.contains(em.getMethod())) {\n\t for (JflowModel.Node nms : sts) {\n\t ModelState ms = (ModelState) nms;\n\t if (ms.getReturnValue() != null) {\n\t\t ms.clearCall();\n\t\t chng = true;\n\t\t}\n\t }\n\t return_set.put(em.getMethod(),Boolean.FALSE);\n\t }\n }\n if (nextsync != needsync) chng = true;\n needsync = nextsync;\n }\n\n for (ModelMethod em : complete_calls.values()) {\n ModelMinimizer.minimize(model_master,em.getStartState());\n }\n\n ModelSynch msynch = new ModelSynch(complete_calls.values());\n msynch.establishPartitions();\n\n if (model_master.doDebug()) {\n IvyXmlWriter nxw = new IvyXmlWriter(new OutputStreamWriter(System.err));\n nxw.begin(\"DEBUG\");\n outputEvents(nxw);\n outputProgram(nxw);\n nxw.end();\n nxw.flush();\n }\n\n boolean retfg = true;\n\n Collection<JflowEvent> c = model_master.getRequiredEvents();\n if (c != null && !c.isEmpty()) {\n Set<JflowEvent> evts = new HashSet<JflowEvent>();\n for (ModelMethod cs : complete_calls.values()) {\n\t Set<JflowModel.Node> states = simplify(cs.getStartState());\n\t for (JflowModel.Node ms : states) {\n\t JflowEvent ev = ms.getEvent();\n\t if (ev != null) evts.add(ev);\n\t }\n }\n for (JflowEvent ev : c) {\n\t if (!evts.contains(ev)) {\n\t System.err.println(\"JFLOW: Required event \" + ev + \" not found\");\n\t retfg = false;\n\t break;\n\t }\n }\n }\n\n empty_calls = null;\n event_calls = null;\n methods_todo = null;\n return_set = null;\n\n return retfg;\n}",
"public boolean doGeneration(Class<?> clazz);",
"@Test\n public void createOrder() {\n IngredientDTO ig1 = new IngredientDTO(\"Onion\",\"onion\",2L,null);\n\n IngredientDTO ig2 = new IngredientDTO(\"Chicken\",\"chicken\",2L,null);\n IngredientDTO ig3 = new IngredientDTO(\"Bacon\",\"chicken\",2L,null);\n\n OrderDataDTO orderDataDTO = new OrderDataDTO(TestDataProviders.NAME_1,TestDataProviders.STREET,TestDataProviders.ZIP_CODE,TestDataProviders.COUNTRY,TestDataProviders.TEST_EMAIL_1,DeliveryMethod.FASTEST);\n\n\n BurgerDTO burgerDTO = new BurgerDTO(new HashSet<>(Arrays.asList(ig1,ig2,ig3)),TestDataProviders.PRICE);\n OrderDTO inputDTO = new OrderDTO(null,burgerDTO,orderDataDTO,null,false);\n\n Optional<User> optionalUser = Optional.of(user);\n when(userRepository.findByUsername(any(String.class))).thenReturn(optionalUser);\n\n //when\n when(orderRepository.save(any(Order.class))).thenReturn(order);\n\n OrderDTO result = underTest.createOrder(inputDTO,\"user1\");\n\n verify(userRepository).findByUsername(anyString());\n assertEquals(inputDTO.getArchived(),result.getArchived());\n assertThat(result.getUserId(),is(1L));\n assertEquals(inputDTO.getBurger().getIngredients().size(),result.getBurger().getIngredients().size());\n// assertThat(result.getOrderData().getCountry(),TestDataProviders.COUNTRY);\n\n }",
"public File generateFile()\r\n {\r\n return generateFile(null);\r\n }",
"@Test\r\n\tpublic void testPositiveGenerateStrings_3() {\n\t\tint i = 1;\r\n\t\tfor (RandomOrgClient roc : rocs) {\r\n\t\t\ttry {\r\n\t\t\t\tString[] response = roc.generateStrings(10, 5, \"abcd\", false, identifier);\r\n\t\t\t\tcollector.checkThat(response, notNullValue());\r\n\t\t\t\t\r\n\t\t\t\tString[] response2 = roc.generateStrings(10, 5, \"abcd\", false, identifier);\r\n\t\t\t\tcollector.checkThat(response, equalTo(response2));\r\n\t\t\t\r\n\t\t\t\tresponse = roc.generateStrings(10, 5, \"abcd\", false, date);\r\n\t\t\t\tcollector.checkThat(response, notNullValue());\r\n\t\t\t\t\r\n\t\t\t\tresponse2 = roc.generateStrings(10, 5, \"abcd\", false, date);\r\n\t\t\t\tcollector.checkThat(response, equalTo(response2));\r\n\t\t\t} catch (Exception e) {\r\n\t\t\t\tcollector.addError(new Error(errorMessage(i, e, true)));\r\n\t\t\t}\r\n\t\t\ti++;\r\n\t\t}\r\n\t}",
"public AbstractTestCase generateTestCase(String type, Variables generatingParameters) {\n switch (type) { \n case ETestCase.defaultGeneratorType: return testCaseGenerator (generatingParameters); \n case \"TYPE1\" : return testCaseGenerator1(generatingParameters); \n case \"TYPE2\" : return testCaseGenerator2(generatingParameters); \n case \"TYPE3\" : return testCaseGenerator3(generatingParameters); \n case \"TYPE4\" : return testCaseGenerator4(generatingParameters); \n case \"TYPE5\" : return testCaseGenerator5(generatingParameters); \n case \"TYPE6\" : return testCaseGenerator6(generatingParameters); \n case \"TYPE7\" : return testCaseGenerator7(generatingParameters); \n case \"TYPE8\" : return testCaseGenerator8(generatingParameters); \n case \"TYPE9\" : return testCaseGenerator9(generatingParameters); \n }\n return null;\n }",
"private static void testgen(String[] args) {\n JSONParser parser = new JSONParser();\n TestgenOptions options = parseTestgenOptions(args);\n CLI.setVerbosity(options);\n if (options.numTasks < 1) {\n API.throwCLIError(\"Invalid number of tasks provided (-n): \" + options.numTasks);\n }\n\n Map<String, Object> objects;\n if (!options.inFile.isEmpty()) {\n objects = parser.parse(options.inFile, true);\n } else if (!options.inString.isEmpty()) {\n objects = parser.parse(options.inString, false);\n } else {\n API.throwCLIError(\"No input JSON provided (-i)\");\n return;\n }\n\n if (objects.get(\"initialState\") == null || objects.get(\"goalState\") == null) {\n API.throwCLIError(\"Both an initial state and a goal state must be provided.\");\n }\n\n TestCaseGenerator generator = new TestCaseGenerator(\n (SystemState) objects.get(\"initialState\"),\n (GoalState) objects.get(\"goalState\"),\n options.numTasks,\n options.optimalPlan,\n options.output\n );\n\n ArrayList<Task> tasks = generator.generateTestCase();\n ArrayList<Optimization> ops = generator.generateOptimizations();\n try{\n generator.testCaseToJSON(tasks, ops, options.perturbations);\n } catch (IOException e){\n API.throwCLIError(\"Failed to write testCase to JSON\");\n }\n\n }",
"public void testCheckOxyEmpty() {\n }",
"public interface BasicDataGeneratorInterface {\r\n\tpublic int generateInteger();\r\n\tpublic int generateInteger(int size);\r\n\tpublic short generateShort();\r\n\tpublic long generateLong();\r\n\tpublic double generateDouble();\r\n\tpublic float generateFloat();\r\n\tpublic boolean generateBoolean();\r\n\tpublic char generateLowerCaseChar();\r\n\tpublic char generateUpperCaseChar();\r\n\tpublic char generateCharEnglishChar();\r\n\tpublic char generateChar();\r\n\tpublic byte generateByte();\r\n\tpublic String generateString(DataGeneratorEnums.StringType stringType);\r\n\tpublic String generateString(DataGeneratorEnums.StringType stringType,int size);\r\n\tpublic String generateStringNoSpecialChars(DataGeneratorEnums.StringType stringType);\r\n\tpublic String generateStringNoSpecialChars(DataGeneratorEnums.StringType stringType,int size);\r\n\tpublic void setSeed(int seed);\r\n}",
"public boolean getGenerateFlag()\r\n {\r\n return theGenerateFlag;\r\n }",
"private void generate() throws FileNotFoundException {\n if (clazz.isInterface())\n generateInterface();\n writer.close();\n }",
"public boolean randomCreate() {\n\t\t// Generates a random genetic code\n\t\t_geneticCode = new GeneticCode();\n\t\t// it has no parent\n\t\t_parentID = -1;\n\t\t_generation = 1;\n\t\t_growthRatio = 16;\n\t\t// initial energy\n\t\t_energy = Math.min(Utils.INITIAL_ENERGY,_world.getCO2());\n\t\t_world.decreaseCO2(_energy);\n\t\t_world.addO2(_energy);\n\t\t// initialize\n\t\tcreate();\n\t\tsymmetric();\n\t\t// put it in the world\n\t\treturn placeRandom();\n\t}",
"@Test\r\n\tpublic void testPositiveGenerateBlobs_1() {\n\t\tint i = 1;\r\n\t\tfor (RandomOrgClient roc : rocs) {\r\n\t\t\ttry {\r\n\t\t\t\tcollector.checkThat(roc.generateBlobs(10, 16), notNullValue());\r\n\t\t\t} catch (Exception e) {\r\n\t\t\t\tcollector.addError(new Error(errorMessage(i, e, true)));\r\n\t\t\t}\r\n\t\t\ti++;\r\n\t\t}\r\n\t}",
"private CombinedConfiguration prepareOptionalTest(String tag, boolean force)\n throws ConfigurationException\n {\n String prefix = \"override.\" + tag;\n factory.addProperty(prefix + \"[@fileName]\", \"nonExisting.xml\");\n factory.addProperty(prefix + \"[@config-optional]\", Boolean.TRUE);\n factory.addProperty(prefix + \"[@config-name]\", OPTIONAL_NAME);\n if (force)\n {\n factory.addProperty(prefix + \"[@config-forceCreate]\", Boolean.TRUE);\n }\n return factory.getConfiguration(false);\n }",
"@Test\n\tpublic void buildTest() {\n\t\tXMLObjectBuilderFactory builderFactory = Configuration.getBuilderFactory();\n\n\t\t// Get the assertion builder based on the assertion element name\n\t\t@SuppressWarnings(\"unchecked\")\n\t\tSAMLObjectBuilder<Assertion> builder = (SAMLObjectBuilder<Assertion>) builderFactory\n\t\t\t\t.getBuilder(Assertion.DEFAULT_ELEMENT_NAME);\n\n\t\t// Create the assertion\n\t\tAssertion assertion = builder.buildObject();\n\n\t}",
"GoalSpecification createGoalSpecification();",
"void createSimulationTaskThrowsExceptionWhenNoBrokerIsFoundTest() throws BrokerNotFoundException {\n IdProvider idProvider = Mockito.mock(IdProvider.class);\n BrokerTypeRepository brokerTypeRepository = Mockito.mock(BrokerTypeRepository.class);\n SimulationParameterValidator parameterValidator = Mockito.mock(SimulationParameterValidator.class);\n SimulationTaskFactory taskFactory = new SimpleSimulationTaskFactory(idProvider, brokerTypeRepository, parameterValidator);\n\n Mockito.when(idProvider.getAnyId()).thenReturn(\"123456abcdef\");\n\n Job job = Mockito.mock(Job.class);\n\n String brokerName1 = \"Tanja\";\n String brokerName2 = \"Hans\";\n String brokerName3 = \"Ronja\";\n String brokerName4 = \"Klaus\";\n List<String> brokerNames = Stream.of(brokerName1, brokerName2, brokerName3, brokerName4)\n .collect(Collectors.toList());\n\n BrokerType brokerType1 = Mockito.mock(BrokerType.class);\n Mockito.when(brokerTypeRepository.has(brokerName1)).thenReturn(true);\n Mockito.when(brokerTypeRepository.findByName(brokerName1)).thenReturn(brokerType1);\n BrokerType brokerType2 = Mockito.mock(BrokerType.class);\n Mockito.when(brokerTypeRepository.has(brokerName2)).thenReturn(true);\n Mockito.when(brokerTypeRepository.findByName(brokerName2)).thenReturn(brokerType2);\n BrokerType brokerType3 = Mockito.mock(BrokerType.class);\n Mockito.when(brokerTypeRepository.has(brokerName3)).thenReturn(true);\n Mockito.when(brokerTypeRepository.findByName(brokerName3)).thenReturn(brokerType3);\n Mockito.when(brokerTypeRepository.has(brokerName4)).thenReturn(false);\n\n Assertions.assertThrows(BrokerNotFoundException.class, () -> taskFactory.create(job, brokerNames));\n }",
"@DSSafe(DSCat.SAFE_OTHERS)\n @DSGenerator(tool_name = \"Doppelganger\", tool_version = \"2.0\", generated_on = \"2013-12-30 12:59:49.370 -0500\", hash_original_method = \"02D67B7BBDDCEC9BC9A477128D96A70E\", hash_generated_method = \"73DCA79669D2BAEA0D08C443D09F446C\")\n \npublic Stub()\n{\nthis.attachInterface(this, DESCRIPTOR);\n}",
"public Generateur() {\n }",
"private Proof faxm6Gen(Expression t) {\n return generateWithTerm(var(\"a\"), t, faxm6);\n }",
"public synchronized void generate () {\n\t\tgenerate( () -> {\n\t\t});\n\t}"
] | [
"0.6333528",
"0.61603254",
"0.6085542",
"0.60415107",
"0.60238624",
"0.5984981",
"0.586145",
"0.56410134",
"0.5520888",
"0.5511492",
"0.54652524",
"0.54135",
"0.53975946",
"0.53889626",
"0.5342782",
"0.5322858",
"0.53190845",
"0.53166825",
"0.53154916",
"0.5307981",
"0.5297499",
"0.52932924",
"0.5282048",
"0.52657723",
"0.5263751",
"0.52496177",
"0.5243938",
"0.52229255",
"0.5200836",
"0.5189547",
"0.5178213",
"0.51688635",
"0.51455575",
"0.51314324",
"0.5125154",
"0.51124567",
"0.50929624",
"0.50874954",
"0.5086894",
"0.50767386",
"0.50763667",
"0.50737137",
"0.5058502",
"0.50362647",
"0.5034996",
"0.50320995",
"0.5027199",
"0.50263727",
"0.5020671",
"0.5019152",
"0.5007436",
"0.5001187",
"0.49936223",
"0.4986284",
"0.4982452",
"0.49789298",
"0.4972269",
"0.49669707",
"0.49639395",
"0.4940555",
"0.493048",
"0.49263296",
"0.492504",
"0.49173534",
"0.49132755",
"0.4912348",
"0.490681",
"0.49064517",
"0.4903331",
"0.49013454",
"0.48992124",
"0.48982695",
"0.48908573",
"0.48751655",
"0.48710853",
"0.48603022",
"0.48517302",
"0.48467615",
"0.48325768",
"0.48311147",
"0.48304632",
"0.48278219",
"0.482274",
"0.48223498",
"0.48205236",
"0.48191708",
"0.48170185",
"0.480885",
"0.4807514",
"0.48026723",
"0.47953513",
"0.4787538",
"0.47868323",
"0.47801793",
"0.47778544",
"0.47775063",
"0.477367",
"0.47716814",
"0.47715366",
"0.47701815"
] | 0.5959294 | 6 |
gerar um valor a atingir por esta estrategia entre 100 e 10000 | public double generateMoneyGoal() {
double moneyGoal = Math.random()*(10000 -100)+100;
return moneyGoal;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@Override\n public void calcularIntGanado() {\n intGanado = saldo;\n for(int i = 0; i < plazoInv; i++){\n intGanado += inve * 12;\n intGanado += intGanado * (intAnual / 100);\n }\n intGanado = intGanado - (inve + saldo);\n }",
"static void sueldo7diasl(){\nSystem.out.println(\"Ejemplo estructura Condicional Multiple 1 \");\nString descuenta=\"\";\n//datos de entrada xd\nint ganancias= teclado.nextInt();\nif(ganancias<=150){\ndescuenta=\"0.5\";\n}else if (ganancias>150 && ganancias<300){\n descuenta=\"0.7\";}\n else if (ganancias>300 && ganancias<450){\n descuenta=\"0.9\";}\n //datos de salida:xd\n System.out.println(\"se le descuenta : \"+descuenta);\n}",
"@Override\n public double salario() {\n return 2600 * 1.10;\n }",
"public void calcular() {\n int validar, c, d, u;\n int contrasena = 246;\n c = Integer.parseInt(spiCentenas.getValue().toString());\n d = Integer.parseInt(spiDecenas.getValue().toString());\n u = Integer.parseInt(spiUnidades.getValue().toString());\n validar = c * 100 + d * 10 + u * 1;\n //Si es igual se abre.\n if (contrasena == validar) {\n etiResultado.setText(\"Caja Abierta\");\n }\n //Si es menor nos indica que es mas grande\n if (validar < contrasena) {\n etiResultado.setText(\"El número secreto es mayor\");\n }\n //Si es mayot nos indica que es mas pequeño.\n if (validar > contrasena) {\n etiResultado.setText(\"El número secreto es menor\");\n }\n }",
"public void calcularSalario(){\n // 1% do lucro mensal\n double percentagemLucro = 0.01 * lucroMensal;\n // valor fixo igual ao dobro do dos empregados sem especialização, acrescido\n //de um prémio que corresponde a 1% do lucro mensal nas lojas da região.\n setSalario(1600 + percentagemLucro);\n\n }",
"private void peso(){\r\n if(getPeso()>80){\r\n precioBase+=100;\r\n }\r\n else if ((getPeso()<=79)&&(getPeso()>=50)){\r\n precioBase+=80;\r\n }\r\n else if ((getPeso()<=49)&&(getPeso()>=20)){\r\n precioBase+=50;\r\n }\r\n else if ((getPeso()<=19)&&(getPeso()>=0)){\r\n precioBase+=10;\r\n }\r\n }",
"@Override\n public double calculaSalario() \n {\n double resultado = valor_base - ((acumulado * 0.05) * valor_base);\n resultado += auxilioProcriacao();\n //vale-coxinha\n resultado += 42;\n return resultado;\n }",
"public int precioFinal(){\r\n int monto=super.PrecioFinal();\r\n\t \t \r\n\t if (pulgadas>40){\r\n\t monto+=precioBase*0.3;\r\n\t }\r\n\t if (sintonizador){\r\n\t monto+=50;\r\n\t }\r\n\t \r\n\t return monto;\r\n\t }",
"public Double retornaSubTotal(Double totalGeral,Double desconto){\n return totalGeral - (totalGeral*(desconto/100));\n}",
"public double getSalario() {\r\n\t\treturn super.getSalario()-10000;\r\n\t}",
"@Override\n\tpublic void acelerar() {\n\t\t// TODO Auto-generated method stub\n\t\t\t\tvelocidadActual += 40;\n\t\t\t\tif(velocidadActual>250) {\n\t\t\t\t\tvelocidadActual = 250;\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\tdepositoActual -= 10;\n\t\t\t\tSystem.out.println(\"Velocidad del ferrari: \"+velocidadActual);\n\t}",
"public void precio4e(){\n precioHabitaciones = precioHabitaciones + (cantidadHabitaciones * numeroCamas);\n\n //Restaurante\n if(capacidadRestaurant < 30){\n precioHabitaciones = precioHabitaciones + 10;\n } else if (capacidadRestaurant > 29 && capacidadRestaurant < 51){\n precioHabitaciones = precioHabitaciones + 30;\n } else if (capacidadRestaurant > 50){\n precioHabitaciones = precioHabitaciones + 50;\n }\n\n //Gimnasio\n switch (gimnasio){\n case \"A\":\n precioHabitaciones = precioHabitaciones + 50;\n break;\n case \"B\":\n precioHabitaciones = precioHabitaciones + 30;\n break;\n }\n\n }",
"@Override public double getCosto(){\n double d = 190.00;\n return d;\n }",
"public void calcular()\r\n/* 530: */ {\r\n/* 531:556 */ this.facturaProveedorSRI.setMontoIva(this.facturaProveedorSRI.getBaseImponibleDiferenteCero().multiply(\r\n/* 532:557 */ ParametrosSistema.getPorcentajeIva().divide(BigDecimal.valueOf(100L))));\r\n/* 533: */ }",
"public double precioFinal() {\r\n double aumento = 0;\r\n switch (consumoEnergetico) {\r\n case 'A':\r\n aumento = 100;\r\n break;\r\n case 'B':\r\n aumento = 80;\r\n break;\r\n case 'C':\r\n aumento = 60;\r\n break;\r\n case 'D':\r\n aumento = 50;\r\n break;\r\n case 'E':\r\n aumento = 30;\r\n break;\r\n case 'F':\r\n aumento = 10; \r\n break;\r\n }\r\n if (peso >= 0 && peso <= 19) {\r\n aumento += 10;\r\n }else if ( peso >= 20 && peso <= 49) {\r\n aumento += 50;\r\n }else if ( peso >= 50 && peso <=79 ) {\r\n aumento += 80;\r\n }else if ( peso >= 80 ){\r\n aumento += 100;\r\n }\r\n \r\n double precioFinal = aumento + this.precioBase;\r\n return precioFinal;\r\n }",
"int getMoneyValue();",
"int getMoneyValue();",
"private String GetTolerance(int Value)\n {\n if (Value == 0)\n return \"+5% de tolerancia\";\n else\n return \"+10% de tolerancia\";\n }",
"public void Entrada(int cantidad) {\n if(cantidad*-1>this.stock) {\n System.out.println(\"La cantidad a retirar es mayor que la que hay en stock, no es posible hacer la operacion.\");\n }else {\n this.stock+=cantidad;\n }\n }",
"public void calculoSalarioBruto(){\n salarioBruto = hrTrabalhada * valorHr;\n }",
"public double ValorDePertenencia(double valor) {\n // Caso 1: al exterior del intervalo del conjunto difuo\n if (valor < min || valor > max || puntos.size() < 2) {\n return 0;\n }\n\n Punto2D ptAntes = puntos.get(0);\n Punto2D ptDespues = puntos.get(1);\n int index = 0;\n while (valor >= ptDespues.x) {\n index++;\n ptAntes = ptDespues;\n ptDespues = puntos.get(index);\n }\n\n if (ptAntes.x == valor) {\n // Tenemos un punto en este valor\n return ptAntes.y;\n } else {\n // Se aplica la interpolación\n return ((ptAntes.y - ptDespues.y) * (ptDespues.x - valor) / (ptDespues.x - ptAntes.x) + ptDespues.y);\n }\n }",
"public void calcularIndicePlasticidad(){\r\n\t\tindicePlasticidad = limiteLiquido - limitePlastico;\r\n\t}",
"public double precioFinal(){\r\n \r\n double plus = 0;\r\n \r\n switch(consumoElectrico){\r\n case 'A':\r\n plus +=100;\r\n break;\r\n case 'B':\r\n plus += 80;\r\n break;\r\n case 'C':\r\n plus +=60;\r\n break;\r\n case 'D':\r\n plus +=50;\r\n break;\r\n case 'E':\r\n plus+=30;\r\n break;\r\n case 'F':\r\n plus+=10;\r\n break;\r\n \r\n }\r\n \r\n \r\n if(peso>=0 && peso<=19){\r\n plus+=10;\r\n }else if(peso >=20 && peso<= 49){\r\n plus+=50;\r\n }else if(peso >= 50 && peso<=79){\r\n plus+=80;\r\n }else if(peso>=80){\r\n plus+=100;\r\n }\r\n return precioBase+plus;\r\n }",
"private static int getBonus(int sales) {\n if (sales > 5000) {\n\n return sales / 10;\n\n }\n return 0;\n }",
"public void sueldo(){\n if(horas <= 40){\n sueldo = horas * cuota;\n }else {\n if (horas <= 50) {\n sueldo = (40 * cuota) + ((horas - 40) * (cuota * 2));\n } else {\n sueldo = ((40 * cuota) + (10 * cuota * 2)) + ((horas - 50) + (cuota * 3));\n }\n }\n\n }",
"static int sumOf1To100nos() {\r\n\t\t \r\n\t\t int sum =0;\r\n\t\t \r\n\t\t for(int i=1; i<=100;i++) {\r\n\t\t\t sum+=i;\r\n\t\t }\r\n\t\t \r\n\t\t return sum;\r\n\t }",
"public double calculoCuotaEspecialOrdinario() {\n\tdouble resultado =0;\n\tresultado = (getMontoCredito()+(getMontoCredito()*getInteres()/100))/getPlazo(); \n\treturn resultado;\n}",
"public void daiGioco() {\n System.out.println(\"Scrivere 1 per giocare al PC, al costo di 200 Tam\\nSeleziona 2 per a Calcio, al costo di 100 Tam\\nSeleziona 3 per Disegnare, al costo di 50 Tam\");\n\n switch (creaturaIn.nextInt()) {\n case 1 -> {\n puntiFelicita += 60;\n puntiVita -= 30;\n soldiTam -= 200;\n }\n case 2 -> {\n puntiFelicita += 40;\n puntiVita -= 20;\n soldiTam -= 100;\n }\n case 3 -> {\n puntiFelicita += 30;\n puntiVita -= 10;\n soldiTam -= 50;\n }\n }\n checkStato();\n }",
"public static void main(String[] args) {\n\n double valorTotal = 36000;\n\n for (int parcela = (int) valorTotal; parcela >= 1; parcela--) {\n double valorParcela = valorTotal / parcela;\n if (valorParcela >= 1000) {\n System.out.println(parcela + \" parcelas de \" + valorParcela + \"R$\");\n }\n }\n }",
"public static double verificaValorCarro(int tipo) {\n double valor = 0;\n switch (tipo) {\n case 1:\n return valor + 1200;\n case 2:\n return valor + 520;\n default:\n break;\n\n }\n return valor;\n }",
"@Override\r\n\tpublic float chekearDatos(){\r\n\t\t\r\n\t\tfloat monto = 0f;\r\n\t\tfloat montoPorMes = creditoSolicitado/plazoEnMeses;\r\n\t\tdouble porcentajeDeSusIngesosMensuales = (cliente.getIngresosMensuales()*0.7);\r\n\t\t\r\n\t\tif(cliente.getIngresoAnual()>=15000f && montoPorMes<=porcentajeDeSusIngesosMensuales){\r\n\t\t\t\r\n\t\t\tmonto = this.creditoSolicitado;\r\n\t\t\tsetEstadoDeSolicitud(true);\r\n\t\t}\t\r\n\t\t\r\n\t\t\r\n\t\treturn monto;\r\n\t}",
"public double calcular_costo() {\n\t\t return 1.3*peso+30 ;\n\t}",
"@Test\n\tpublic void test100000() {\n\n\tdouble tax = Main.calcTax(100_000.);\n\tassertEquals(1750., tax, .01);\n\n\t}",
"public double calcularIncremento(){\n double incremento=0.0;\n \n if (this.edad>=18&&this.edad<50){\n incremento=this.salario*0.05;\n }\n if (this.edad>=50&&this.edad<60){\n incremento=this.salario*0.10;\n }\n if (this.edad>=60){\n incremento=this.salario*0.15;\n }\n return incremento;\n }",
"@Override\n public double tuition(){\n return 2500;\n }",
"public void percentualGordura(){\n\n s0 = 4.95 / denscorp;\n s1 = s0 - 4.50;\n percentgord = s1 * 100;\n\n }",
"private void trataDesconto(String x){\n \n Double sub;\n \n descontoField.setText(porcentagem.format((Double.parseDouble(x))/100));\n descontoField.setEnabled(true);\n sub = retornaSubTotal(this.getVlrTotalItem(), Double.parseDouble(x));\n subTotalField.setText(moeda.format(sub));\n lblTotalGeral.setText(subTotalField.getText());\n this.setVlrTotalItem(sub);\n}",
"int getSat(){\n return getPercentageValue(\"sat\");\n }",
"public double calculatedConsuption(){\nint tressToSow=0;\n\nif (getKiloWatts() >=1 && getKiloWatts() <= 1000){\n\ttressToSow = 8;\n}\nelse if (getKiloWatts() >=1001 && getKiloWatts ()<=3000){\n\ttressToSow = 35;\n}\nelse if (getKiloWatts() > 3000){\n\ttressToSow=500;\n}\nreturn tressToSow;\n}",
"@Override\n public void subida(){\n // si es mayor a la eperiencia maxima sube de lo contrario no\n if (experiencia>(100*nivel)){\n System.out.println(\"Acabas de subir de nivel\");\n nivel++;\n System.out.println(\"Nievel: \"+nivel);\n }else {\n\n }\n }",
"@Override\n\tprotected double calcularImpuestoVehiculo() {\n\t\treturn this.getValor() * 0.003;\n\t}",
"private void updateValue() {\n int minValue = 100; //Minimum value to be calculated, initialized to a large number\n value = 0; //Value reinitialized to 0\n for (Integer i : values) {\n if (i > value && i <= 21) {\n value = i; //Sets value to maximum value less than or equal to 21\n }\n if (i < minValue) {\n minValue = i; //Sets minimum value to lowest value in the list\n }\n }\n if (value == 0) {\n value = minValue; //Sets value to minValue if no values 21 or less\n }\n valueLabel.setText(\"Value: \" + value); //Sets text of value label\n if (value > 21) {\n bust(); //Busts if value greater than 21\n }\n }",
"@Override\n public void cantidad_Punteria(){\n punteria=69.5+05*nivel+aumentoP;\n }",
"public void calcularEntropia(){\n //Verificamos si será con la misma probabilida o con probabilidad\n //especifica\n if(contadorEstados == 0){\n //Significa que será con la misma probabilidad por lo que nosotros\n //calcularemos las probabilidades individuales\n for(int i = 0; i < numEstados; i++){\n probabilidadEstados[i] = 1.0 / numEstados;\n }\n }\n for(int i = 0; i < numEstados; i++){\n double logEstado = Math.log10(probabilidadEstados[i]);\n logEstado = logEstado * (-1);\n double logDos = Math.log10(2);\n double divisionLog = logEstado / logDos;\n double entropiaTmp = probabilidadEstados[i] * divisionLog;\n resultado += entropiaTmp;\n }\n }",
"public void precioFinal(){\r\n if(getConsumoEnergetico() == Letra.A){\r\n precioBase = 100+precioBase;\r\n }\r\n else if((getConsumoEnergetico() == Letra.B)){\r\n precioBase = 80+precioBase;\r\n }\r\n else if(getConsumoEnergetico() == Letra.C){\r\n precioBase = 60+precioBase;\r\n }\r\n else if((getConsumoEnergetico() == Letra.D)){\r\n precioBase = 50+precioBase;\r\n }\r\n else if(getConsumoEnergetico() == Letra.E){\r\n precioBase = 30+precioBase;\r\n }\r\n else if((getConsumoEnergetico() == Letra.F)){\r\n precioBase = 10+precioBase;\r\n }\r\n else{\r\n aux=1;\r\n System.out.println(\"...No existe...\");\r\n }\r\n if (aux==0){\r\n peso();\r\n }\r\n \r\n }",
"public void calcular(View view) {\n int quilos = Integer.valueOf(editTextQuantidade.getText().toString());\n int total = (quilos *1000)/500;\n \n String message = \"Com \" + quilos + \"kg de chocolate da para fazer \" + total + \" ovos de 500g.\";\n textViewTotal.setText(message);\n }",
"public double establece_bonus(double gratificacion) {\n\t\tdouble prima = 2000;\n\t\t\n\t\treturn (Trabajadores.bonus_base + prima + gratificacion);\n\t}",
"long buscarUltimo();",
"public int masVendido(int cantidad){\r\n \r\n return cantidad;\r\n }",
"@Override\n\tpublic double CalcularFuel() {\n\t\tdouble consumo=this.getCargaActual()*30+2*numEje;\n\t\treturn consumo;\n\t}",
"public void faiBagnetto() {\n System.out.println(\"Scrivere 1 per Bagno lungo, al costo di 150 Tam\\nSeleziona 2 per Bagno corto, al costo di 70 Tam\\nSeleziona 3 per Bide', al costo di 40 Tam\");\n\n switch (creaturaIn.nextInt()) {\n case 1 -> {\n puntiVita += 50;\n puntiFelicita -= 30;\n soldiTam -= 150;\n }\n case 2 -> {\n puntiVita += 30;\n puntiFelicita -= 15;\n soldiTam -= 70;\n }\n case 3 -> {\n puntiVita += 10;\n puntiFelicita -= 5;\n soldiTam -= 40;\n }\n }\n checkStato();\n }",
"public void sumaPuntos() {\r\n int rojo = 0;\r\n int azul = 0;\r\n for (int i = 1; i < 10; i++) {\r\n\r\n if (tablero[1][i].getTipo().equals(\"Rojo\")) {\r\n rojo += tablero[1][i].getValor();\r\n }\r\n\r\n if (tablero[8][i].getTipo().equals(\"Azul\")) {\r\n azul += tablero[8][i].getValor();\r\n }\r\n\r\n }\r\n if (rojo > azul) {\r\n this.setResultado(\"Rojo\");\r\n this.agregarVictoria(jugadorRojo);\r\n }\r\n if (azul > rojo) {\r\n this.setResultado(\"Azul\");\r\n this.agregarVictoria(jugadorAzul);\r\n }\r\n \r\n this.setReplay(true);\r\n }",
"public void gastarDinero(double cantidad){\r\n\t\t\r\n\t}",
"private int giveValue(int joueur, int adversaire, Grid grid) {\n return evaluate(joueur, grid) - evaluate(adversaire, grid);\n }",
"public double insalubridadeDez(double salario) {\n\t\tsalario = salario * 0.1;\r\n\t\t// atribui o valor de 10% ao salario e somando eles.\r\n\t\t// salarioTotal += salario;\r\n\t\treturn salario; // so atribuir esse valor ao salario\r\n\t}",
"public void minutoStamina(int minutoStamina){\n tiempoReal = (minutoStamina * 6)+10;\n }",
"public abstract void sacar( Double valor);",
"float getMonatl_kosten();",
"public int getCantidadAvenidas();",
"private static double rundeBetrag(double betrag){\n \tdouble round = Math.round(betrag*10000); \r\n \t\r\n \tround = round / 10000; \r\n \tround = Math.round(round*1000); \r\n \tround = round / 1000; \r\n \tround = Math.round(round*100); \r\n \r\n \treturn round / 100; \r\n }",
"public void calculoPersonal(){\n ayudantes = getAyudantesNecesarios();\n responsables = getResponsablesNecesarios();\n \n //Calculo atencion al cliente (30% total trabajadores) y RRPP (10% total trabajadores):\n \n int total = ayudantes + responsables;\n \n atencion_al_cliente = (total * 30) / 100;\n \n RRPP = (total * 10) / 100;\n \n //Creamos los trabajadores\n \n gestor_trabajadores.crearTrabajadores(RRPP, ayudantes,responsables,atencion_al_cliente);\n \n }",
"public static void atacar(){\n int aleatorio; //variables locales a utilizar\n Random numeroAleatorio = new Random(); //declarando variables tipo random para aleatoriedad\n int ataqueJugador;\n //acciones de la funcion atacar sobre vida del enemigo\n aleatorio = (numeroAleatorio.nextInt(20-10+1)+10);\n ataqueJugador= ((nivel+1)*10)+aleatorio;\n puntosDeVidaEnemigo= puntosDeVidaEnemigo-ataqueJugador;\n \n }",
"@Override\n public void tirar() {\n if ( this.probabilidad == null ) {\n super.tirar();\n this.valorTrucado = super.getValor();\n return;\n }\n \n // Necesitamos conocer la probabilidad de cada número, trucados o no, para ello tengo que saber\n // primero cuantos números hay trucados y la suma de sus probabilidades. \n // Con esto puedo calcular la probabilidad de aparición de los números no trucados.\n \n int numeroTrucados = 0;\n double sumaProbalidadesTrucadas = 0;\n double probabilidadNoTrucados = 0;\n \n for ( double p: this.probabilidad ) { // cálculo de la suma números y probabilidades trucadas\n if ( p >= 0 ) {\n numeroTrucados++;\n sumaProbalidadesTrucadas += p;\n }\n }\n \n if ( numeroTrucados < 6 ) { // por si estuvieran todos trucados\n probabilidadNoTrucados = (1-sumaProbalidadesTrucadas) / (6-numeroTrucados);\n }\n\n double aleatorio = Math.random(); // me servirá para escoger el valor del dado\n \n // Me quedo con la cara del dado cuya probabilidad de aparición, sumada a las anteriores, \n // supere el valor aleatorio\n double sumaProbabilidades = 0;\n this.valorTrucado = 0;\n do {\n ++this.valorTrucado;\n if (this.probabilidad[this.valorTrucado-1] < 0) { // no es una cara del dado trucada\n sumaProbabilidades += probabilidadNoTrucados;\n } else {\n sumaProbabilidades += this.probabilidad[this.valorTrucado-1];\n }\n \n } while (sumaProbabilidades < aleatorio && valorTrucado < 6);\n \n \n }",
"@Override\n public double Convertir(int opcion, Double valor) {\n double unidad;\n\n switch (opcion) {\n case 1://de km/h a millas/h\n //1 km/h = 0,621371 millas/h\n unidad = (0.621371 * valor);\n break;\n case 2://de millas/h a km/h\n //1 milla/h = 1,60934 km/h\n unidad = (1.60934 * valor);\n break;\n case 3://de km/h a metros por segundo\n // 1 km/h = 0,277778 metros pro segundo\n unidad = (0.277778 * valor);\n break;\n case 4://de km a millas\n unidad = (0.621371 * valor);\n break;\n case 5://de milla a yardas\n unidad = (1760 * valor);\n break;\n case 6://de milla a km\n unidad = (1.60934 * valor);\n break;\n default:\n unidad = 0.00;\n break;\n }\n return unidad;\n }",
"@Override\n public void cantidad_Ataque(){\n ataque=5+2*nivel+aumentoT;\n }",
"@Override\r\n\tpublic Double precio() {\n\t\treturn this.combo.precio() + 50;\r\n\t}",
"@Test\n\tvoid calcularSalarioSinVentasPagoPositivoTest() {\n\t\tEmpleadoPorComision empleadoPorComision = new EmpleadoPorComision(\"Hiromu Arakawa\", \"p24\", 400000, 0);\n\t\tdouble salarioEsperado = 400000;\n\t\tdouble salarioEmpleadoPorComision = empleadoPorComision.calcularSalario();\n\t\tassertEquals(salarioEsperado, salarioEmpleadoPorComision);\n\n\t}",
"double getPerimetro(){\n return 2 * 3.14 * raggio;\n }",
"@Override\n public double total() {\n return 2500;\n }",
"public int dameValor(C carta)\n\t{\n\t\tint n= carta.getNumero();\n\t\tif(n>=2 && n<=9)//el 10 no se usa\n\t\t\treturn n;\n\t\telse\n\t\t\treturn 10;\n\t\t\n\t}",
"void calculate() {\n if (price <= 1000)\n price = price - (price * 2 / 100);\n else if (price > 1000 && price <= 3000)\n price = price - (price * 10 / 100);\n else\n price = price - (price * 15 / 100);\n }",
"@Test\n public void testCalculerDroitPassage() {\n int nbrDoitPassage = 3;\n double valeurLot = 1000;\n double expResult = 350;\n double result = CalculAgricole.calculerMontantDroitsPassage(nbrDoitPassage, valeurLot);\n assertEquals(\"Montant pour las droits du passage n'était pas correct.\", expResult, result, 0);\n\n }",
"public void calcularQuinA(){\n sueldoQuinAd = sueldoMensual /2;\n\n }",
"@Override\n\tpublic Double calcular(Produto produto) {\n\t\treturn (produto.getValorUnitario()) - (produto.getValorUnitario() * 0.25);\n\t}",
"private Long calcTiempoCompensado(Long tiempoReal, Barco barco, Manga manga) {\n //Tiempo compensado = Tiempo Real + GPH * Nº de millas manga.\n Float res = tiempoReal + barco.getGph() * manga.getMillas();\n return (long) Math.round(res);\n }",
"public void cambiaRitmo(int valor){\r\n\t\t\r\n\t}",
"public int euroToRuble(int value) {\n return value * EURO;\n }",
"private void somarQuantidade(Integer id_produto){\n\t for (ItensCompra it : itensCompra){\n\t\t //verifico se o item do meu arraylist é igual ao ID passado no Mapping\n\t\t if(it.getTable_Produtos().getId_produto().equals(id_produto)){\n\t //defino a quantidade atual(pego a quantidade atual e somo um)\n\t it.setQuantidade(it.getQuantidade() + 1);\n\t //a apartir daqui, faço o cálculo. Valor Total(ATUAL) + ((NOVA) quantidade * valor unitário do produto(ATUAL))\n\t it.setValorTotal(0.);\n\t it.setValorTotal(it.getValorTotal() + (it.getQuantidade() * it.getValorUnitario()));\n }\n}\n\t}",
"public int getminutoStamina(){\n return tiempoReal;\n }",
"@Override\n\tpublic double calcularSalario() {\n\n\t\tdouble salario = 0;\n\n\t\tdouble porcentajeAnios = calcularPorcentajePorAntiguedad();\n\t\tporcentajeAnios = this.sueldoBasico* (porcentajeAnios / 100);\n\t\tsalario = this.sueldoBasico + porcentajeAnios;\n\t\treturn salario;\n\t}",
"int getSatMod(){\n return getPercentageValue(\"satMod\");\n }",
"double getBasedOnValue();",
"public double calcularPortes() {\n\t\tif (this.pulgadas <= 40) {\n\t\t\tif (this.getPrecioBase() > 500)\n\t\t\t\treturn 0;\n\t\t\telse\n\t\t\t\treturn 35;\n\t\t} else\n\t\t\treturn 35 + (this.pulgadas - 40);\n\t}",
"public void acelerar(int velocidade){\n\t\tSystem.out.println(\"Acelerando. Velocidade e: \"+ velocidade+\"KM/H\");\n\t}",
"public int addPontos(double gastos) {\n\t\tdouble pontos = gastos * BONUS_PREMIUM;\n\t\tint totalPontos = (int) pontos;\n\n\t\tif (gastos > 100) {\n\t\t\tdouble adicional = gastos / 100;\n\t\t\ttotalPontos += (int) adicional * 10;\n\n\t\t}\n\t\treturn totalPontos;\n\n\t}",
"public static void Promedio(){\n int ISumaNotas=0;\n int IFila=0,ICol=0;\n int INota;\n float FltPromedio;\n for(IFila=0;IFila<10;IFila++)\n {\n ISumaNotas+=Integer.parseInt(StrNotas[IFila][1]);\n }\n FltPromedio=ISumaNotas/10;\n System.out.println(\"El promedio de la clase es:\"+FltPromedio);\n }",
"public BigDecimal calcularValorUtilizado(Emenda e) {\n\t\t\n\t\tBigDecimal valorUsado = new BigDecimal(0);\t\t\n\t\tList<IndicacaoEmenda> indicacoes = indicacaoEService.findByEmenda(e);\n\t\t\n\t\tfor (IndicacaoEmenda indicacao : indicacoes) {\n\t\t\tvalorUsado = valorUsado.add(indicacao.getValorDestinado());\n\t\t}\n\t\t\n\t\treturn valorUsado;\n\t}",
"@Test\n\tpublic void test250000() {\n\n\tdouble tax = Main.calcTax(250_000.);\n\tassertEquals(7750., tax, .01);\n\n\t}",
"public void convert(){\n afterValue = firstValue * 1000;\n }",
"public double getValue(){\n value*=100;\n value = Math.floor(value);\n value/=100;//returns to hundredths place\n return value;\n }",
"public void init() {\n\t\tdouble v = MathUtils.toNum(get(\"value\"));\n\t\tlong v100 = (long) MathUtils.toNum(get(\"value100\"));\n\t\tif (v100 != 100*v) {\n\t\t\tv100 = (long) (v*100);\n\t\t\tput(\"value100\", v100);\n\t\t}\n\t}",
"int getSumaAdunata();",
"public void calcularTotal() {\n double valor = 0;\n String servico = (String)consultaSelecionada.getSelectedItem().toString();\n switch(servico) {\n case \"Consulta\":\n valor += 100;\n break;\n case \"Limpeza\":\n valor += 130;\n break;\n case \"Clareamento\":\n valor += 450;\n break;\n case \"Aparelho\":\n valor += 100;\n break;\n case \"Raio-x\":\n valor += 80;\n break;\n case \"Cirurgia\":\n valor += 70;\n break;\n }\n Total.setText(String.valueOf(valor));\n }",
"private void sumarTropa(int tipo){\n int cantActual;\n //Buscar tipo\n switch(tipo){\n case vg.BARBARO:\n cantActual = Integer.parseInt(jTextFieldBarbaro.getText());\n jTextFieldBarbaro.setText(String.valueOf(cantActual+1));\n break;\n case vg.ARQUERA:\n cantActual = Integer.parseInt(jTextFieldArquera.getText());\n jTextFieldArquera.setText(String.valueOf(cantActual+1));\n break;\n case vg.GIGANTE:\n cantActual = Integer.parseInt(jTextFieldGigante.getText());\n jTextFieldGigante.setText(String.valueOf(cantActual+1));\n break;\n case vg.DUENDE:\n cantActual = Integer.parseInt(jTextFieldDuende.getText());\n jTextFieldDuende.setText(String.valueOf(cantActual+1));\n break;\n }\n }",
"@Override\n\tpublic double neto() {\n\t\treturn 2000;\n\t}",
"public static double verificaValorQuarto(int tipo) {\n double valor = 0;\n switch (tipo) {\n case 1:\n return valor + 1200;\n case 2:\n return valor + 520;\n case 3:\n return valor + 570;\n case 4:\n return valor + 620;\n case 5:\n return valor + 360;\n case 6:\n return valor + 385;\n case 7:\n return valor + 440;\n default:\n break;\n }\n return valor;\n }",
"@Test\n\tpublic void test50000() {\n\n\tdouble tax = Main.calcTax(50_000.);\n\tassertEquals(500., tax, .01);\n\n\t}",
"private void calcularResultado() {\r\n\tdouble dinero=0;\r\n\tdinero=Double.parseDouble(pantalla.getText());\r\n\tresultado=dinero/18.5;\r\n\t\tpantalla.setText(\"\" + resultado);\r\n\t\toperacion = \"\";\r\n\t}",
"public double periculosidade(double salario) {\n\t\t\tsalario = salario * 0.3;\r\n\t\t\t// atribui o valor de 30% ao salario e somando eles.\r\n\t\t\t// salarioTotal = salario + salarioTotal;\r\n\r\n\t\t\treturn salario; // So atribuir esse valor no salario\r\n\t\t\r\n\t}",
"public void calculateCommission(){\r\n commission = (sales) * 0.15;\r\n //A sales Person makes 15% commission on sales\r\n }",
"@Test\n\tpublic void test110000() {\n\n\tdouble tax = Main.calcTax(110_000.);\n\tassertEquals(2_150., tax, .01);\n\n\t}"
] | [
"0.66523165",
"0.6378319",
"0.62794757",
"0.6252145",
"0.6236348",
"0.6207209",
"0.61628145",
"0.61622834",
"0.6153875",
"0.61366147",
"0.60856867",
"0.6049505",
"0.5964555",
"0.5934573",
"0.593275",
"0.59226066",
"0.59226066",
"0.59171945",
"0.5890566",
"0.58778554",
"0.5857239",
"0.58556193",
"0.58280414",
"0.5826814",
"0.5823792",
"0.57823205",
"0.57732",
"0.57373625",
"0.57370746",
"0.5733924",
"0.573335",
"0.5725772",
"0.57097566",
"0.5691387",
"0.5688078",
"0.5681157",
"0.5677226",
"0.5672087",
"0.56673324",
"0.5655996",
"0.56527185",
"0.5647167",
"0.56450397",
"0.56436425",
"0.5641475",
"0.563861",
"0.56361085",
"0.5630478",
"0.56290984",
"0.5628214",
"0.5626019",
"0.5625391",
"0.56172097",
"0.5614608",
"0.56098837",
"0.5607704",
"0.5598459",
"0.55919355",
"0.55816036",
"0.55801845",
"0.5575642",
"0.556769",
"0.5564984",
"0.5563501",
"0.55599326",
"0.55584496",
"0.5554779",
"0.5550266",
"0.55440605",
"0.55434775",
"0.5542241",
"0.55407435",
"0.5539748",
"0.5536908",
"0.55319536",
"0.5519105",
"0.5518127",
"0.5516156",
"0.5511686",
"0.5505346",
"0.5501563",
"0.5501205",
"0.5492711",
"0.5488671",
"0.54812944",
"0.54812425",
"0.5476496",
"0.54731834",
"0.54683185",
"0.545984",
"0.54577315",
"0.54539704",
"0.5451216",
"0.5448168",
"0.54480445",
"0.54478896",
"0.54454666",
"0.54352146",
"0.543459",
"0.5417392",
"0.54172736"
] | 0.0 | -1 |
TODO Autogenerated method stub | @Override
public double betStrategyRL(RobotPlayer player) {
return 0;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@Override\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}",
"@Override\n\tpublic void comer() {\n\t\t\n\t}",
"@Override\n public void perish() {\n \n }",
"@Override\r\n\t\t\tpublic void annadir() {\n\r\n\t\t\t}",
"@Override\n\tpublic void anular() {\n\n\t}",
"@Override\n\tprotected void getExras() {\n\n\t}",
"@Override\r\n\tpublic void anularFact() {\n\t\t\r\n\t}",
"@Override\n\tpublic void entrenar() {\n\t\t\n\t}",
"@Override\n\tpublic void nadar() {\n\t\t\n\t}",
"@Override\r\n\tpublic void tires() {\n\t\t\r\n\t}",
"@Override\r\n\t\t\tpublic void ayuda() {\n\r\n\t\t\t}",
"@Override\n\tprotected void interr() {\n\t}",
"@Override\n\tpublic void emprestimo() {\n\n\t}",
"@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}",
"@Override\n\tpublic void grabar() {\n\t\t\n\t}",
"@Override\n\tpublic void gravarBd() {\n\t\t\n\t}",
"@Override\r\n\tpublic void rozmnozovat() {\n\t}",
"@Override\r\n\tpublic void dormir() {\n\t\t\r\n\t}",
"@Override\n protected void getExras() {\n }",
"@Override\r\n\tpublic void publierEnchere() {\n\t\t\r\n\t}",
"@Override\n\tpublic void nefesAl() {\n\n\t}",
"@Override\n\tpublic void ligar() {\n\t\t\n\t}",
"@Override\n public void func_104112_b() {\n \n }",
"@Override\n\tprotected void initdata() {\n\n\t}",
"@Override\n\tpublic void nghe() {\n\n\t}",
"@Override\n public void function()\n {\n }",
"@Override\n public void function()\n {\n }",
"public final void mo51373a() {\n }",
"@Override\r\n\tpublic void stehReagieren() {\r\n\t\t//\r\n\t}",
"@Override\n public void inizializza() {\n\n super.inizializza();\n }",
"@Override\n\tprotected void initData() {\n\t\t\n\t}",
"@Override\r\n\t\tpublic void init() {\n\t\t\t\r\n\t\t}",
"@Override\n\tpublic void sacrifier() {\n\t\t\n\t}",
"@Override\r\n\tprotected void InitData() {\n\t\t\r\n\t}",
"public void designBasement() {\n\t\t\r\n\t}",
"@Override\r\n\tprotected void initialize() {\r\n\t\t\r\n\t\t\r\n\t}",
"public void gored() {\n\t\t\n\t}",
"@Override\r\n\tprotected void initData() {\n\r\n\t}",
"@Override\n\tpublic void einkaufen() {\n\t}",
"@Override\n protected void initialize() {\n\n \n }",
"public void mo38117a() {\n }",
"@Override\n\tprotected void getData() {\n\t\t\n\t}",
"Constructor() {\r\n\t\t \r\n\t }",
"@Override\r\n\tpublic void dibujar() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void dibujar() {\n\t\t\r\n\t}",
"@Override\n\tpublic void one() {\n\t\t\n\t}",
"@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}",
"@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}",
"@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}",
"@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}",
"@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}",
"@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}",
"private stendhal() {\n\t}",
"@Override\n\tprotected void update() {\n\t\t\n\t}",
"@Override\n\t\t\tpublic void ic() {\n\t\t\t\t\n\t\t\t}",
"@Override\n\tprotected void initData() {\n\n\t}",
"@Override\n\tprotected void initData() {\n\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n public void init() {\n\n }",
"@Override\n\tprotected void initialize() {\n\t\t\n\t}",
"@Override\n\tprotected void initialize() {\n\t\t\n\t}",
"@Override\r\n\tpublic void init() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void init() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void init() {\n\t\t\r\n\t}",
"@Override\n\tpublic void debite() {\n\t\t\n\t}",
"@Override\r\n\tpublic void init() {\n\r\n\t}",
"@Override\r\n\tpublic void init() {\n\r\n\t}",
"@Override\r\n\tpublic void init() {\n\r\n\t}",
"public contrustor(){\r\n\t}",
"@Override\n\tprotected void initialize() {\n\n\t}",
"@Override\r\n\tpublic void dispase() {\n\r\n\t}",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"@Override\n\tpublic void dtd() {\n\t\t\n\t}",
"@Override\n\tprotected void logic() {\n\n\t}",
"@Override\n\tprotected void lazyLoad() {\n\t\t\n\t}",
"public void mo4359a() {\n }",
"@Override\r\n\tprotected void initialize() {\n\r\n\t}",
"@Override\n public void memoria() {\n \n }",
"@Override\n\t\tpublic void method() {\n\t\t\t\n\t\t}",
"private RepositorioAtendimentoPublicoHBM() {\r\t}",
"@Override\n protected void initialize() \n {\n \n }",
"@Override\r\n\tpublic void getProposition() {\n\r\n\t}",
"@Override\n\tpublic void particular1() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\n\t}",
"@Override\n\tpublic void init() {\n\n\t}",
"@Override\n\tpublic void init() {\n\n\t}",
"@Override\n protected void prot() {\n }",
"@Override\r\n\tpublic void init()\r\n\t{\n\t}",
"@Override\n\tprotected void initValue()\n\t{\n\n\t}",
"public void mo55254a() {\n }"
] | [
"0.6671074",
"0.6567672",
"0.6523024",
"0.6481211",
"0.6477082",
"0.64591026",
"0.64127725",
"0.63762105",
"0.6276059",
"0.6254286",
"0.623686",
"0.6223679",
"0.6201336",
"0.61950207",
"0.61950207",
"0.61922914",
"0.6186996",
"0.6173591",
"0.61327106",
"0.61285484",
"0.6080161",
"0.6077022",
"0.6041561",
"0.6024072",
"0.6020252",
"0.59984857",
"0.59672105",
"0.59672105",
"0.5965777",
"0.59485507",
"0.5940904",
"0.59239364",
"0.5910017",
"0.5902906",
"0.58946234",
"0.5886006",
"0.58839184",
"0.58691067",
"0.5857751",
"0.58503544",
"0.5847024",
"0.58239377",
"0.5810564",
"0.5810089",
"0.5806823",
"0.5806823",
"0.5800025",
"0.5792378",
"0.5792378",
"0.5792378",
"0.5792378",
"0.5792378",
"0.5792378",
"0.5790187",
"0.5789414",
"0.5787092",
"0.57844025",
"0.57844025",
"0.5774479",
"0.5774479",
"0.5774479",
"0.5774479",
"0.5774479",
"0.5761362",
"0.57596046",
"0.57596046",
"0.575025",
"0.575025",
"0.575025",
"0.5747959",
"0.57337177",
"0.57337177",
"0.57337177",
"0.5721452",
"0.5715831",
"0.57142824",
"0.57140535",
"0.57140535",
"0.57140535",
"0.57140535",
"0.57140535",
"0.57140535",
"0.57140535",
"0.5711723",
"0.57041645",
"0.56991017",
"0.5696783",
"0.56881124",
"0.56774884",
"0.56734604",
"0.56728",
"0.56696945",
"0.5661323",
"0.5657007",
"0.5655942",
"0.5655942",
"0.5655942",
"0.56549734",
"0.5654792",
"0.5652974",
"0.5650185"
] | 0.0 | -1 |
Method and constructor invocations | @Override
public R visitMethodInvocation(MethodInvocationNode n, P p) {
return visitNode(n, p);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"Reproducible newInstance();",
"private void __sep__Constructors__() {}",
"private Instantiation(){}",
"protected abstract void construct();",
"Constructor() {\r\n\t\t \r\n\t }",
"public Constructor(){\n\t\t\n\t}",
"private ChainingMethods() {\n // private constructor\n\n }",
"public MethodEx2() {\n \n }",
"public Methods() {\n // what is this doing? -PMC\n }",
"private void translateConstructor( ) {\n \n Set<MethodInfoFlags> flags = EnumSet.noneOf( MethodInfoFlags.class );\n \n AVM2Method method = new AVM2Method( null, flags );\n avm2Class.avm2Class.constructor = method;\n \n AVM2MethodBody body = method.methodBody;\n body.maxStack = 1;\n body.maxRegisters = 1;\n body.maxScope = 11;\n body.scopeDepth = 10;\n \n InstructionList il = body.instructions;\n \n// il.append( OP_getlocal0 );\n// il.append( OP_pushscope );\n il.append( OP_getlocal0 );\n il.append( OP_constructsuper, 0 );\n \n// il.append( OP_findpropstrict, new AVM2QName( PUBLIC_NAMESPACE, \"drawTest\" ));\n il.append( OP_getlocal0 );\n \n il.append( OP_callpropvoid, new AVM2QName( EmptyPackage.namespace, \"drawTest\" ), 0 );\n\n il.append( OP_returnvoid );\n }",
"private void addConstructors() {\n\t\tthis.rootBindingClass.getConstructor().body.line(\"super({}.class);\\n\", this.name.getTypeWithoutGenerics());\n\t\tGMethod constructor = this.rootBindingClass.getConstructor(this.name.get() + \" value\");\n\t\tconstructor.body.line(\"super({}.class);\", this.name.getTypeWithoutGenerics());\n\t\tconstructor.body.line(\"this.set(value);\");\n\t}",
"public Method() {\n }",
"public Calculator() {\r\n\t\t/*\r\n\t\t * Constructor - Method name which has the same class name is called a Consatructor\r\n\t\t */\r\n\t\tSystem.out.println(\"Calling constructor\");\r\n\t}",
"ConstuctorOverloading(){\n\t\tSystem.out.println(\"I am non=argument constructor\");\n\t}",
"public Call_simple() {\n }",
"private SingleObject()\r\n {\r\n }",
"public Method(String name, String desc) {\n/* 82 */ this.name = name;\n/* 83 */ this.desc = desc;\n/* */ }",
"defaultConstructor(){}",
"public void init(){}",
"public void initMethod(){\n\t}",
"public OOP_207(){\n\n }",
"private Infer() {\n\n }",
"private CommonMethods() {\n }",
"protected IPCGCallDetailCreator()\r\n {\r\n // empty\r\n }",
"private TMCourse() {\n\t}",
"public static void main(String[] args) {\n\t\tthisconstructor rv = new thisconstructor();\n\t\n\t\n\t}",
"private SingleObject(){}",
"@Test\n public void Constructor_ObjectValues_InstanceCreated() {\n\t\ttry {\n Position position = make_PositionWithIntegerPoints(xCoordinate, yCoordinate, direction);\n Surface surface = make_SurfaceWithGivenDimensions(xDimension, yDimension);\n\t\t\tRover rover = make_RoverWithObjectValues(position, surface);\n\t\t}\n\t\tcatch (AssertionError assErr) {\n\t\t\t// Test passed.\n\t\t\treturn;\n\t\t}\n }",
"public static void copyConstructor(){\n\t}",
"void DefaultConstructor(){}",
"public Clade() {}",
"public void constructorReturned(Spy spy, String constructionInfo);",
"protected MethodCallPrinter()\n {\n }",
"ConstructorPractice () {\n\t\tSystem.out.println(\"Default Constructor\");\n\t}",
"@Override\r\n\t\tpublic void init() {\n\t\t\t\r\n\t\t}",
"public void init() {}",
"public void init() {}",
"public void init() { }",
"public void init() { }",
"private Constructor getConstructor() throws Exception {\r\n return type.getConstructor(Contact.class, label, Format.class);\r\n }",
"public Operation(){\n\t}",
"public MethodInfoImpl() {\n }",
"@Override\r\n\tpublic void init() {}",
"protected void _init(){}",
"public static void main(String[] args) {\n My obj2=new My(9);//--->called overloaded Constructor\n }",
"private SingleObject(){\n }",
"public static void main(String[] args) {\nconstructorDemo obj=new constructorDemo();\nconstructorDemo obj1=new constructorDemo(\"My Parameter\");\nconstructorDemo obj2=new constructorDemo(123);\nconstructorDemo obj3=new constructorDemo(123,6);\nSystem.out.println(\"code after creating object\");\nobj.hello();\nobj.hello(\"hi\");\n\t}",
"public Demo3() {}",
"public Employee()\n\t{\n\t\tthis(\"(2)Invoke Employee's overload constructor\");\n\t\tSystem.out.println(\"(3)Employee's no-arg constructor is invoked\");\n\t}",
"@Override\n\t\tpublic void init() {\n\t\t}",
"private MApi() {}",
"private SimpleRepository() {\n \t\t// private ct to disallow external object creation\n \t}",
"public Construct() {\n\tprefixes = new StringBuilder();\n\tvariables = new StringBuilder();\n\twheres = new StringBuilder();\n }",
"@Override public void init()\n\t\t{\n\t\t}",
"private void init() {\n }",
"private void init() {\n }",
"private void init() {\n }",
"private void init() {\n }",
"public void init() {\n \n }",
"private void init() {\n }",
"@Override // opcional\n public void init(){\n\n }",
"public Activator() {\r\n\t}",
"public void init() {\r\n\t\t// to override\r\n\t}",
"public PSRelation()\n {\n }",
"public Hello()\n {\n // initialise instance variables\n \n }",
"@Override\r\n public void instantiate() {\r\n }",
"public native void constructor();",
"private Cat() {\n\t\t\n\t}",
"public Implementor(){}",
"public Orbiter() {\n }",
"public static void main(String[] args) {\n for(int i=0; i<10; i++){\n Constructor c=new Constructor (i);\n c.Constructor(\"Who\");\n \n } \n }",
"public Main() {\r\n\t\tsuper();\r\n\t\tinitialize();\r\n\r\n\t}",
"public Self__1() {\n }",
"@Override\r\n\tpublic CMObject newInstance()\r\n\t{\r\n\t\ttry\r\n\t\t{\r\n\t\t\treturn this.getClass().getDeclaredConstructor().newInstance();\r\n\t\t}\r\n\t\tcatch(final Exception e)\r\n\t\t{\r\n\t\t\tLog.errOut(ID(),e);\r\n\t\t}\r\n\t\treturn new StdBehavior();\r\n\t}",
"private ATCres() {\r\n // prevent to instantiate this class\r\n }",
"@Override\n public void init() {}",
"public Basic() {}",
"H create(Method method);",
"public CyanSus() {\n\n }",
"private Main() {\n\n super();\n }",
"private void init() {\n\n\t}",
"public Supercar() {\r\n\t\t\r\n\t}",
"@Override\r\n\tpublic void init() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void init() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void init() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic final void init() {\r\n\r\n\t}",
"public Object invokeConstructor(String type, Object arguments) {\n return invokeConstructorOf(loadClass(type), arguments);\n }",
"public Curso() {\r\n }",
"private Supervisor() {\r\n\t}",
"private Rekenhulp()\n\t{\n\t}",
"private void init() {\n\n\n\n }",
"@Override\n protected void init() {\n }",
"private LoadMethodMapper ()\n {}",
"public Methods() { // ini adalah sebuah construktor kosong tidak ada parameternya\n System.out.println(\"Ini adalah Sebuah construktor \");\n }",
"public void init(){\n \n }",
"public lo() {}",
"public Chick() {\n\t}",
"public Object construct() {\n try {\n Object res;\n\n res = mTarget.invokeTimeout(mMethodName, mParams, mTimeout);\n return res;\n }\n catch (TokenFailure ex) {\n return ex;\n }\n catch (RPCException ex) {\n return ex;\n }\n catch (XMPPException ex) {\n return ex;\n }\n }",
"@Override\n public void init() {\n }",
"private R() {\n\n }",
"public MonHoc() {\n }"
] | [
"0.74505186",
"0.73150414",
"0.7303449",
"0.72684664",
"0.6930279",
"0.69047064",
"0.6845389",
"0.6807747",
"0.68073577",
"0.6789923",
"0.6590855",
"0.6583133",
"0.6566065",
"0.65425843",
"0.6435725",
"0.63831306",
"0.63720125",
"0.6356276",
"0.6335496",
"0.6311478",
"0.6298384",
"0.6291867",
"0.6291095",
"0.62779063",
"0.6275127",
"0.6267774",
"0.626109",
"0.62575877",
"0.62544537",
"0.6226156",
"0.6196801",
"0.6193272",
"0.61848897",
"0.61791897",
"0.6175996",
"0.6170421",
"0.6170421",
"0.6160649",
"0.6160649",
"0.61605793",
"0.61480576",
"0.61393183",
"0.61182886",
"0.6115599",
"0.61151135",
"0.6110797",
"0.61091083",
"0.61051345",
"0.6102182",
"0.6092093",
"0.6088587",
"0.60860014",
"0.6079409",
"0.6077701",
"0.60752326",
"0.60752326",
"0.60752326",
"0.60752326",
"0.60706306",
"0.6070256",
"0.606993",
"0.6069446",
"0.60685813",
"0.6067722",
"0.6058109",
"0.60580695",
"0.6057899",
"0.6054178",
"0.60500664",
"0.60432446",
"0.6040213",
"0.6033648",
"0.60306746",
"0.6025214",
"0.60251606",
"0.6025018",
"0.60202616",
"0.6019554",
"0.601792",
"0.6000608",
"0.599645",
"0.59956384",
"0.5991666",
"0.5991666",
"0.5991666",
"0.5987548",
"0.5983994",
"0.5981925",
"0.59813404",
"0.59807795",
"0.5978164",
"0.5977588",
"0.59764516",
"0.5974291",
"0.5973728",
"0.59704524",
"0.5966292",
"0.5963487",
"0.59633225",
"0.5961939",
"0.59528166"
] | 0.0 | -1 |
Type, package and class names | @Override
public R visitArrayType(ArrayTypeNode n, P p) {
return visitNode(n, p);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public String getClazzName();",
"private String getType( )\n\t{\n\t\treturn this.getModuleName( ) + \"$\" + this.getSimpleName( ) + \"$\" + this.getSystem( );\n\t}",
"String getClassTypeVariables() {\n final StringBuilder sb = new StringBuilder();\n if (classTypes.size() > 0) {\n sb.append(\"<\");\n for (int i = 0; i < classTypes.size(); i++) {\n final Class<?> c = classTypes.get(i);\n if (c != null) {\n sb.append(getShortClassName(c));\n if (i < classTypes.size() - 1) {\n sb.append(\", \");\n }\n }\n }\n sb.append(\">\");\n }\n return sb.toString();\n }",
"TypePackage getTypePackage();",
"java.lang.String getClass_();",
"java.lang.String getClass_();",
"String typeName();",
"public String getClassName();",
"public String getModuleTypeClass();",
"String getClassName();",
"String getClassName();",
"String getClassName();",
"public String getType() {\n\t\treturn \"class\";\n\t}",
"java.lang.String getClassName();",
"public String getName_Class() {\n\t\treturn name;\n\t}",
"public String getClazz();",
"protected String getPackageName(Class<?> type) {\n return type.getPackage().getName();\n }",
"String getClazz();",
"public String getTypeName();",
"public String getTypeName();",
"String getClassName(Element e) {\n // e has to be a TypeElement\n TypeElement te = (TypeElement)e;\n String packageName = elementUtils.getPackageOf(te).getQualifiedName().toString();\n String className = te.getQualifiedName().toString();\n if (className.startsWith(packageName + \".\")) {\n String classAndInners = className.substring(packageName.length() + 1);\n className = packageName + \".\" + classAndInners.replace('.', '$');\n }\n return className;\n }",
"String getInstanceOfClass();",
"public abstract String getTypeName();",
"Object getClass_();",
"Object getClass_();",
"private String getClassname() {\r\n\t\tString classname = this.getClass().getName();\r\n\t\tint index = classname.lastIndexOf('.');\r\n\t\tif (index >= 0)\r\n\t\t\tclassname = classname.substring(index + 1);\r\n\t\treturn classname;\r\n\t}",
"abstract String getClassName();",
"public String getType() {\n // or only getDeclaringType().getName()\n // return getDeclaringType().getFullName();\n if(getNamespace() != null && getNamespace().length() > 0) {\n // when using getDeclareType().getName() some objects return lowercase\n // names, hence we capitalize (using getDeclaringType().getFullName() does\n // not exhibit this behavior but has the issue that it might return names\n // that include generic types and their mappings, which cause issues in\n // the code elements that use this method\n return getNamespace()+\".\"+Utilities.capitalize(getDeclaringType().getName());\n }\n return Utilities.capitalize(getDeclaringType().getName());\n }",
"@Override\n\tpublic String typeKey() {\n\t return \"class\";\n\t}",
"default String getClassName() {\n return declaringType().getClassName();\n }",
"public String classSignature(ClassLoader loader) {\n\t\tString desc = \"\";\n\t\t\n\t\tList<Pair<String,List<Type.Reference>>> classes = type.components();\n\t\tif(classes.get(classes.size()-1).second().size() > 0) { \n\t\t\tdesc += \"<\"; \n\t\t\tfor(Type t : classes.get(classes.size()-1).second()) {\n\t\t\t\tif(t instanceof Type.Variable) {\n\t\t\t\t\tType.Variable tv = (Type.Variable) t;\n\t\t\t\t\tdesc += tv.variable() + \":\";\n\t\t\t\t\tType lb = tv.lowerBound();\n\t\t\t\t\t// The following check is needed to deal with the case\n\t\t\t\t\t// where the type bounds are only interfaces. In this\n\t\t\t\t\t// case, there must be an extra colon indicating the\n\t\t\t\t\t// absence of super class. It's actually really annoying\n\t\t\t\t\t// since it couples this code with ClassTable ... grrr.\n\n\t\t\t\t\ttry {\n\t\t\t\t\t\tClazz tmp = loader.loadClass((Type.Clazz) lb);\n\t\t\t\t\t\tif (tmp.isInterface()) {\n\t\t\t\t\t\t\tdesc += \":\";\n\t\t\t\t\t\t}\n\t\t\t\t\t\tdesc += ClassFile.descriptor(lb, true);\n\t\t\t\t\t} catch (ClassNotFoundException ce) {\n\t\t\t\t\t\tthrow new RuntimeException(\"Type bound \" + lb\n\t\t\t\t\t\t\t\t+ \" not found\");\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\tthrow new RuntimeException(\"Type Variable required in Class Signature!\");\n\t\t\t\t}\n\t\t\t}\n\t\t\tdesc += \">\";\n\t\t}\n\t\tif (superClazz != null) {\n\t\t\tdesc += ClassFile.descriptor(superClazz, true);\n\t\t}\n\t\tfor (Type t : interfaces) {\n\t\t\tdesc += ClassFile.descriptor(t, true);\n\t\t}\n\t\treturn desc;\n\t}",
"public final String toStringClassName() {\r\n \t\tString str = this.getClass().getName();\r\n \t\tint lastIx = str.lastIndexOf('.');\r\n \t\treturn str.substring(lastIx+1);\r\n \t}",
"@Override\n protected String className(ClassType t, boolean longform, Locale locale) {\n Symbol sym = t.tsym;\n if (sym.name.length() == 0 && (sym.flags() & COMPOUND) != 0) {\n return OBJECT;\n } else if (sym.name.length() == 0) {\n // Anonymous\n String s;\n ClassType norm = (ClassType) t.tsym.type;\n if (norm == null) {\n s = OBJECT;\n } else if (norm.interfaces_field != null && norm.interfaces_field.nonEmpty()) {\n s = visit(norm.interfaces_field.head, locale);\n } else {\n s = visit(norm.supertype_field, locale);\n }\n return s;\n } else if (longform) {\n String pkg = \"\";\n for (Symbol psym = sym; psym != null; psym = psym.owner) {\n if (psym.kind == PCK) {\n pkg = psym.getQualifiedName().toString();\n break;\n }\n }\n return fullClassNameAndPackageToClass.apply(\n sym.getQualifiedName().toString(),\n pkg\n );\n } else {\n return sym.name.toString();\n }\n }",
"public String getPackageName() {\n JavaType.FullyQualified fq = TypeUtils.asFullyQualified(qualid.getType());\n if (fq != null) {\n return fq.getPackageName();\n }\n String typeName = getTypeName();\n int lastDot = typeName.lastIndexOf('.');\n return lastDot < 0 ? \"\" : typeName.substring(0, lastDot);\n }",
"public abstract String getClassName();",
"public String getClassname() {\n return classname;\n }",
"java.lang.String getPackage();",
"public abstract Class getDescriptedClass();",
"public String getQualifiedName()\n {\n return name + \".\" + type;\n }",
"private String getClassName( Class c ) {\n\treturn c.getName().substring(c.getName().lastIndexOf('.')+1);\n }",
"public String toString() {return classSimpleName+\"#\"+name;}",
"public ClassInfo declaringClass();",
"private static String getClassName() {\n\n\t\tThrowable t = new Throwable();\n\n\t\ttry {\n\t\t\tStackTraceElement[] elements = t.getStackTrace();\n\n\t\t\t// for (int i = 0; i < elements.length; i++) {\n\t\t\t//\n\t\t\t// }\n\n\t\t\treturn elements[2].getClass().getSimpleName();\n\n\t\t} finally {\n\t\t\tt = null;\n\t\t}\n\n\t}",
"protected String getClassName() {\n return getDescriptedClass().getName();\n }",
"String getStringClass();",
"public String getClassType() {\n return classType;\n }",
"public String getName() {\n\t\treturn \"Object class name\";\n\t}",
"public String getClassname() {\n\t\treturn classname;\n\t}",
"public String getClassname()\r\n {\r\n return m_classname;\r\n }",
"public String ofType() {\n\t\t return name;\n\t}",
"public String getClassName() {\n\t\tString tmp = methodBase();\n\t\treturn tmp.substring(0, 1).toUpperCase()+tmp.substring(1);\n\t}",
"String getTypeAsString();",
"@Override\n public String getName() {\n return type.getName();\n }",
"DefaultTypeParser()\r\n {\r\n importPackageNames.add(\"\");\r\n importPackageNames.add(\"java.lang.\");\r\n }",
"private static void Demo2() {\n\t\tClass<?> class1 = null;\r\n\t\tClass<?> class2 = null;\r\n\t\ttry {\r\n\t\t\tclass1 = Class.forName(\"CH16.Person\");\r\n\t\t\tSystem.out.println(\"包名:\" + class1.getPackage().getName());\r\n\t\t\tSystem.out.println(\"类名:\" + class1.getName());\r\n\t\t} catch (ClassNotFoundException e) {\r\n\t\t\t// TODO Auto-generated catch block\r\n\t\t\te.printStackTrace();\r\n\t\t}\r\n\r\n\t\tclass2 = Person.class;\r\n\t\tSystem.out.println(\"包名:\" + class2.getPackage().getName());\r\n\t\tSystem.out.println(\"类名:\" + class2.getName());\r\n\r\n\t}",
"String getSimpleName();",
"String getSimpleName();",
"String getFullName() {\r\n StringBuffer buf = new StringBuffer(type.getName());\r\n Summary current = type.getParent();\r\n\r\n while (current != null) {\r\n if (current instanceof TypeSummary) {\r\n buf.insert(0, \".\");\r\n buf.insert(0, ((TypeSummary)current).getName());\r\n } else if (current instanceof PackageSummary) {\r\n String temp = ((PackageSummary)current).getName();\r\n\r\n if ((temp != null) && (temp.length() > 0)) {\r\n buf.insert(0, \".\");\r\n buf.insert(0, temp);\r\n }\r\n }\r\n current = current.getParent();\r\n }\r\n\r\n return buf.toString();\r\n }",
"String getMetadataClassName();",
"public static String classObjectName(Class<?> type) {\n return (type.getName() + \":::OBJECT\");\n }",
"String type();",
"String type();",
"String type();",
"String type();",
"String type();",
"String type();",
"String type();",
"String type();",
"String type();",
"String type();",
"String type();",
"String type();",
"String type();",
"String type();",
"String type();",
"String type();",
"String type();",
"String type();",
"String type();",
"String type();",
"String getType();",
"String getType();",
"String getType();",
"String getType();",
"String getType();",
"String getType();",
"String getType();",
"String getType();",
"String getType();",
"String getType();",
"String getType();",
"String getType();",
"String getType();",
"String getType();",
"String getType();",
"String getType();",
"String getType();",
"String getType();",
"String getType();",
"String getType();",
"String getType();"
] | [
"0.7250158",
"0.7136449",
"0.7097432",
"0.70698917",
"0.6786753",
"0.6786753",
"0.6725759",
"0.6706435",
"0.6623144",
"0.6572667",
"0.6572667",
"0.6572667",
"0.6564951",
"0.6541426",
"0.6528404",
"0.64659894",
"0.64535856",
"0.6426223",
"0.64257145",
"0.64257145",
"0.6416011",
"0.6393129",
"0.63917035",
"0.6377614",
"0.6377614",
"0.63433754",
"0.6321272",
"0.6287925",
"0.62865204",
"0.62864333",
"0.6242547",
"0.6238353",
"0.62374526",
"0.6233625",
"0.62303483",
"0.6216834",
"0.62070787",
"0.6175954",
"0.6172159",
"0.6151692",
"0.61501026",
"0.6149049",
"0.61360294",
"0.6121124",
"0.6119117",
"0.6089746",
"0.60883737",
"0.6083069",
"0.6080363",
"0.6074213",
"0.60557306",
"0.6050662",
"0.60463506",
"0.60450345",
"0.60385674",
"0.6038335",
"0.6038335",
"0.6031886",
"0.60315",
"0.601588",
"0.6011517",
"0.6011517",
"0.6011517",
"0.6011517",
"0.6011517",
"0.6011517",
"0.6011517",
"0.6011517",
"0.6011517",
"0.6011517",
"0.6011517",
"0.6011517",
"0.6011517",
"0.6011517",
"0.6011517",
"0.6011517",
"0.6011517",
"0.6011517",
"0.6011517",
"0.6011517",
"0.59983003",
"0.59983003",
"0.59983003",
"0.59983003",
"0.59983003",
"0.59983003",
"0.59983003",
"0.59983003",
"0.59983003",
"0.59983003",
"0.59983003",
"0.59983003",
"0.59983003",
"0.59983003",
"0.59983003",
"0.59983003",
"0.59983003",
"0.59983003",
"0.59983003",
"0.59983003",
"0.59983003"
] | 0.0 | -1 |
Returns the n^th digit of a number: input = 1337 n = 2 _ > digit = 1337 = 3 n = 3 _ > digit = 1337 = 3 n = 4 _ > digit = 1337 = 1 | private static int getDigit(final int input, final int n) {
if (n <= 0) {
return N_TOO_LOW;
}
if (input < Math.pow(10, n - 1)) {
return DIGIT_NOT_FOUND;
}
return (int) Math.floor((input % (int) Math.pow(10, n)) / Math.pow(10, n - 1));
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public int findNthDigit(int n) {\n int len = 1, i = 1;\n long range = 9;\n while (n > len * range) {\n n -= len * range;\n len++;\n range *= 10;\n i *= 10;\n }\n i += (n - 1) / len;\n String s = Integer.toString(i);\n return Character.getNumericValue(s.charAt((n - 1) % len));\n }",
"public static int getDigit(int number){\r\n int j = 0 ;\r\n j = number % 10;\r\n j += number / 10;\r\n return j;\r\n }",
"public int countDigitOne(int n) {\n int res = 0;\n for(long i = 1 ; i <= n; i *= 10){\n long k = n/i, r = n % i;\n res += (k + 8) / 10 * i + ((k%10 == 1)?(r+1):0);\n }\n return res;\n }",
"public static int digitCounter(int n){\r\n int counter=1;\r\n while(n>10){\r\n n=n/10;\r\n counter++;\r\n }\r\n System.out.println(\"conter : \" +counter);\r\n return counter;\r\n }",
"public int countDigitOne(int n) {\n long res = 0;\n for(int i = 1; i < n ; i *= 10){\n res += (long)n/i + n%(i*10);\n }\n return (int)res;\n }",
"public static int getDigit(int number) {\r\n\t\tint rem = number % 10;\r\n\t\treturn rem + number / 10;\r\n\t}",
"static int count(int n)\r\n\t\t{\r\n\t\t\tint c = 0; //initially count of digits is 0\r\n\t\t\twhile(n != 0)\r\n\t\t\t{\r\n\t\t\t\tc++;\r\n\t\t\t\tn = n/10;\r\n\t\t\t}\r\n\t\t\treturn c;\r\n\t\t}",
"public int countDigitOne(int n) {\n long res = 0;\n for(int i = 10; i <= n*10 ; i *= 10){\n int tmp = n - (n/i)*i;\n tmp = tmp > (i/10) ? (i/10) : (tmp - i/10);\n tmp = tmp > 0 ? tmp: 0;\n// int tmp = (n%i - i/10 + 1)>(i/10)?(i/10): (n%i - i/10 + 1);\n res += n/i + tmp;\n }\n return (int)res;\n }",
"public static int returnDigit(int number) { \n\t\t\t\tif (number < 9) \n\t\t\t\t\treturn number; \n\t\t\t\treturn number / 10 + number % 10; \n\t\t\t}",
"public int countNumbersWithUniqueDigits(int n) {\n if (n == 0) return 1;\n int sAcc = 10;\n int mAcc = 9;\n int i = 1;\n n = Math.min(n, 10);\n while (i < n) {\n mAcc *= (10 - i);\n sAcc += mAcc;\n i++;\n }\n return sAcc;\n }",
"public static int getDigit(int cnumber) {\n if (cnumber < 9)\n return cnumber;\n return cnumber / 10 + cnumber % 10;\n }",
"public static int getDigit(int number)\n\t{\n\t\tif(number < 10)\n\t\t{\n\t\t\tSystem.out.println(number);\n\t\t\treturn number;\n\t\t}\n\t\telse\n\t\t{\n\t\t\t//ones place\n\t\t\tint firstDigit = number % 10;\n\t\t\t//tens place\n\t\t\tint secondDigit = number / 10;\n\t\t\tSystem.out.println(\"first and second is\" + (firstDigit + secondDigit));\n\t\t\treturn firstDigit + secondDigit;\n\t\t}\n\t}",
"private int getDigit(int index) {\n return getDigit(number, index);\n }",
"public static int getDigitCount(int n) {\n if(n < 0) return -1;\n\n int count = 0;\n do {\n count++;\n n /= 10;\n } while(n != 0);\n\n return count;\n }",
"public int numDupDigitsAtMostN1(int n) {\n int res = 0;\n int[] digits = new int[10];\n for (int i = 1; i <= n; i++) {\n Arrays.fill(digits, 0);\n for (int j = i; j > 0; j /= 10)\n digits[j % 10]++;\n for (int count : digits)\n if (count > 1)\n res++;\n }\n return res;\n }",
"public int countNumbersWithUniqueDigits(int n) {\n if(n==0) return 1;\n if(n==1) return 10;\n if(n>10) return 0;\n int current = 81;//for f(2) f(n)=f(n-1)*(11-n);depend on previous result, we have 11-n \n int total=91;\n for(int i=3;i<=n;i++){\n current*=(11-i);\n total+=current;\n }\n return total;\n }",
"public int numDupDigitsAtMostN(int n) {\n List<Integer> digits = new ArrayList<>();\n for (int i = n + 1; i > 0; i /= 10)\n digits.add(0, i % 10);\n int res = 0, n = digits.size();\n // *, **, ***, **** until 54321\n for (int i = 1; i < n; i++)\n res += 9 * A(9, i - 1);\n // 1****, 2****, 3****, ...\n // 12***, 13***, ...\n boolean[] contains = new boolean[10];\n // From the first index to last index of digit\n for (int index = 0; index < n; index++) {\n int end = digits.get(index);// end of permutation\n for (int d = index == 0 ? 1 : 0; d < end; d++)\n if (!contains[d])\n res += A(9 - index, n - index - 1);// choose (n - index - 1) numbers from (10 - index - 1)\n // Because as we continue, the prefix already contains duplicate\n if (contains[end])\n break;\n contains[end] = true;\n }\n return n - res;\n }",
"private int getNumDigits(int x) {\n int ans = 1;\n for (int digit = 9; digit >=0; digit--) {\n int power_of_ten = (int) Math.pow(10, digit);\n if (x / power_of_ten > 0) {\n ans = digit + 1;\n break;\n }\n }\n \n return ans;\n }",
"public String digit(String digit);",
"short digits();",
"public int countNumbersWithUniqueDigits(int n) {\n int result = 10;\n if(n == 0) {\n return 1;\n } else if (n == 1) {\n return 10;\n } \n \n int avblNums = 9;\n int multipliers = 9;\n int combos = 0;\n for(int i=2; i<= n; i++) {\n combos = avblNums * multipliers--;\n result += combos;\n avblNums = combos;\n }\n return result;\n }",
"public void daffodilNum(int digit) {\n int count = 0;\n for (int i = (int) Math.pow(10, digit-1); i < (int) Math.pow(10, digit); i++) {\n int sum = 0;\n for (int index = 0; index < digit; index++) {\n int curDigit = (i / ((index == 0) ? 1 : ((int) Math.pow(10, index)))) % 10;\n sum += Math.pow(curDigit, 3);\n }\n if (sum == i) {\n System.out.print(i);\n System.out.print(' ');\n count++;\n if (count == 2) {\n System.out.println();\n count = 0;\n }\n }\n }\n }",
"int digitDegree(int n) {Process\n\t // 1. Input int n\n\t // 2. Get digitSum\n\t // 3. Check if it's singleDigit\n\t // 3.1. If not - recursive with count\n\t // 4. Return count \n\t // \n\t \n\t int digitSum = 0;\n\t int count = 0;\n\t \n\t if (n >= 10) {\n\t count++;\n\t }\n\t while (n > 0) {\n\t digitSum += n%10;\n\t n /= 10;\n\t }\n\t \n\t if (digitSum >= 10) {\n\t digitDegree_Recursive(digitSum, &count);\n\t }\n\t return count;\n\t}",
"public static int digitSumPowerTwo(int n) {\n String num = BigInteger.ONE.shiftLeft(1000).toString();\n int sum = 0;\n\n for (int i = 0; i < num.length(); i++)\n sum += num.charAt(i) - '0';\n \n return sum;\n }",
"private long getNthUglyNo(long n) {\n\t\tlong i = 1;\n\n\t\t// ugly number count\n\t\tlong count = 1;\n\n\t\twhile (n > count) {\n\t\t\ti++;\n\t\t\tif (isUgly(i) == 1) {\n\t\t\t\tcount++;\n\t\t\t}\n\t\t}\n\t\treturn i;\n\t}",
"public static void main(String[] args) {\nScanner sc=new Scanner(System.in);\nint n=sc.nextInt();\nint temp=n;\nint sum=0;\nwhile(temp>0){\n\tint lastDigit=temp%10;\n\ttemp /= 10;\n\tsum += lastDigit;\n\tSystem.out.println(lastDigit+\" \"+temp+\" \"+sum);\n}\nSystem.out.println(\"Sum of the digits of \" + n +\" is \"+sum);\n//int numberofDigits=(int)Math.log10(n)+1;\n//System.out.println(numberofDigits);\n\t}",
"public static BigInteger getNth(long n)\n {\n if (n == 0 || n == 1) { return BigInteger.valueOf(n); }\n else { return power(atom, n - 1)[0][0]; } \n }",
"private static int getChange(int n) {\n \t\n int count =0, tempCount = 0;\n while(n!=0){\n \t\n \tif(n >= 10){\n \t\ttempCount = n/10;\n \t\tn = n % 10;\n \t\tcount = count + tempCount;\n \t\tif(n==0)\n \t\t\tbreak;\n \t}\n \tif( n >= 5 && n < 10){\n \t\ttempCount = n/5;\n \t\tn = n % 5;\n \t\tcount = count + tempCount;\n \t\tif(n == 0)\n \t\t\tbreak;\n \t}\n \tif(n >= 1 && n < 5){\n \t\tcount = count + n;\n break;\n \t}\n }\n return count;\n }",
"public long getIndex(long number) {\r\n\t\tlong digit;\r\n\t\tlong divide=number/div;\r\n\t\tdigit=divide%radix;\r\n\t\treturn digit;\r\n\t}",
"public static int getDigits(int i) {\n\t\tif (i < 10) {\n\t\t\treturn 1;\n\t\t}\n\t\treturn 1 + getDigits(i / 10);\n\t}",
"private String intString(int n){\r\n String s=\"\";\r\n if(n>9){\r\n s+=(char)(Math.min(n/10,9)+'0');\r\n }\r\n s+=(char)(n%10+'0');\r\n return s; \r\n }",
"public int nthUglyNumber(int n) {\n TreeSet<Long> set = new TreeSet<>();\n set.add(1L);\n long current = 1;\n for(int i = 0; i < n; i++){\n current = set.pollFirst();\n set.add(current*2);\n set.add(current*3);\n set.add(current*5);\n }\n return (int)current;\n }",
"private int digitOf(Stack<String> number)\n {\n\tif(number.isEmpty()) return 0;\n\treturn Integer.parseInt(number.pop());\n }",
"public static int reverseInt(int n) {\n\t\tif(n <10) {\n\t\t\treturn n;\n\t\t}\n\t\t//to reverse get the last digit first\n\t\t//then remove the last digit\n\t\t//Then next time *10 and add it to the previous one\n\t\tint result=0;\n\t\twhile(n>0) {\n\t\t\tint last = n%10;\n\t\t\tn = n/10;\n\t\t\tresult = result*10 + last;\n\t\t}\n\t\treturn result;\n\t\t\n\t}",
"public int numDupDigitsAtMostN2(int n) {\n int[] digitCount = new int[10];\n int res = 0, dupCount = 0;\n Arrays.fill(digitCount, 0);\n for (int i = 1; i <= n; i++) {\n int curr = i % 10;\n if (curr == 0) {\n Arrays.fill(digitCount, 0);\n dupCount = 0;\n for (int x = i; x > 0; x /= 10)\n digitCount[x % 10]++;\n for (int j = 0; j < 10; j++)\n if (digitCount[j] > 1)\n dupCount++;\n } else {\n digitCount[curr]++;\n digitCount[curr - 1]--;\n if (digitCount[curr] == 2)\n dupCount++;\n if (digitCount[curr - 1] == 1)\n dupCount--;\n }\n if (dupCount != 0)\n res++;\n }\n return res;\n }",
"public static int getDigit(int _number) {\r\n\t\tString _numberString = _number + \"\";\r\n\t\t\r\n\t\tif (_numberString.length() == 1){\r\n\t\t _number = Integer.parseInt(_numberString);\r\n\t\t\treturn _number;\r\n\t\t\r\n\t\t\t\r\n\t\t}else if (_numberString.length() == 2) {\r\n\t\t\t \t \r\n\t\t\t int _number1 = Character.getNumericValue(_numberString.charAt(0));\r\n\t\t\t int _number2 = Character.getNumericValue(_numberString.charAt(1));\r\n\t\t\t _number = _number1 + _number2;\r\n\t\t}\r\n\t\treturn _number;\r\n\t}",
"public int getDigit(int index){\n\t\tif (index+1 > data.length){\n\t\t\tSystem.out.println(\"index out of bounds\");\n\t\t}\n\t\treturn index;\n\t\t\n\t}",
"public static int getDigitCount(int number) {\n int count = 0;\r\n if(number < 0) {\r\n return -1;\r\n } else if(number == 0) {\r\n count++;\r\n }\r\n while(number > 0){\r\n number /= 10;\r\n count++;\r\n }\r\n return count;\r\n }",
"public static int generateDigit() {\n\t\t\n\t\treturn (int)(Math.random() * 10);\n\t}",
"private static long tenToThePowerOfInt(int number) {\n\n\t\tlong result = 1; // default case (10 power 0)\n\n\t\t// checking for out of long range\n\t\tif (number > 18) {\n\t\t\treturn -1;\n\t\t}\n\n\t\tfor (int i = 0; i < number; i++) {\n\t\t\tresult = result * 10;\n\t\t}\n\n\t\treturn result;\n\n\t}",
"public int getKthDigit(int v, int k) {\n for (int i = 0; i < k; i++)\n v /= 10;\n return v % 10;\n }",
"public static int getNthIntValue(String line, int n) {\n // Split the string by non-digits,\n String[] split = RegEx.NOT_NUMBERS.split(RegEx.WITH_NOT_NUMBERS.matcher(line).replaceFirst(Normal.EMPTY));\n if (split.length >= n) {\n return parseIntOrDefault(split[n - 1], 0);\n }\n return 0;\n }",
"public int digitCounts(int k, int n) {\n\n int result = 0;\n int base = 1;\n while (n/base > 0) {\n\n int cur = (n/base)%10;\n int low = n-(n/base) * base;;\n int high = n/(base * 10);\n\n if (cur < k)\n {\n result += high*base;\n }\n else if (cur > k)\n {\n result += (high+1)*base;\n }\n else\n {\n result += high*base+low+1;\n }\n\n base *= 10;\n }\n\n return result;\n }",
"public static long digitSum(long n){\n if (String.valueOf(n).contains(\"-\")) return 0;\n long sum = 0;\n char[] chs = String.valueOf(n).toCharArray();\n for (char ch : chs){\n sum += Long.parseLong(String.valueOf(ch));\n }\n return sum;\n }",
"public static int querProdukt(int n) {\n\t\t// wandelt die nummer in einen String und diesen in ein Char Array\n\t char[] number = Integer.toString(n).toCharArray();\n\t int ret = 1;\n for (char c : number) {\n \t/* Char nach int gecasted ergibt den ASCII-Wert des Chars.\n \t Die ASII werte der Zahlen 0, 1,...,9 sind auf 48, 49,...,57,\n \t also gilt (ASCIIwertDerZahl)-48=Zahl\n \t */\n ret *= (int)c-48;\n }\n return ret;\n\t}",
"public static int countDigitisRec(int i)\r\n\t{\n\t\tif (i == 0)\r\n\t\t{\r\n\t\t\treturn 0;\r\n\t\t}\r\n\t\telse{\r\n\t\t\treturn countDigitisRec(i/10) + 1;\r\n\t\t}\r\n\t}",
"private static long reverse(int n) {\n int rev = 0;\n while (n > 0) {\n rev = rev * 10 + n % 10;\n n = n / 10;\n }\n return rev;\n }",
"public int getDigit(int index) {\n\t\tif(index >= 0&&index < data.length) {\n\t\t\treturn data[index];\n\t\t}else {\n\t\t\tSystem.out.println(\" the index is out of bounds\");\n\t\t\treturn 0;\n\t\t}\n\t}",
"public static int getBitsNumber(int n) {\r\n\t\treturn (int) (Math.log(n) / Math.log(2.0) + 0.9999);\r\n\t}",
"static int digitSum(String n, int k) {\n int sum = findSum(convertToList(n));\n // Finding the initial super digit where k=1\n sum = findSuperDigit(convertToList(sum));\n // Calculating k times the super digit to find actual result\n return findSuperDigit(convertToList(sum*k));\n }",
"public static int factoriel(int n) {\n\t\tif(n <= 1) {\n\t\t\treturn 1;\n\t\t}else {\n\t\t\treturn n * factoriel(n - 1);\n\t\t}\n\t}",
"public static void main(String[] args) {\n Scanner scanner = new Scanner(System.in);\n int number = scanner.nextInt();\n int secondDigit = (number / 10) % 10;\n System.out.println(secondDigit);\n }",
"private static int getDigit(int position, int value, int radix) {\n return value / (int) Math.pow(radix,position) % radix;\n }",
"public static int lastDigit(int number){\r\n // find the remainder of the number enetered by dividing the number by 10 and finding the remainder\r\n int remainder = number % 10;\r\n if (number < 0){\r\n remainder = remainder * -1;\r\n }\r\n return remainder;\r\n }",
"public static void main(String[] args) {\n\t\tint n=345;\r\n\t\tint s=0;\r\n\t\twhile(n!=0)\r\n\t\t{\r\n\t\tint last=n%10;\r\n\t\ts =s+last;\r\n\t\tn= n/10;\t\r\n\t\t\t\r\n\t\t\t}\r\n\r\nSystem.out.println(s);\r\n\t}",
"private static int getDigit(ArrayList<Integer> num, int index) {\n return index < num.size() ? num.get(index) : 0;\n }",
"protected int t(int n) {\r\n\t\treturn Math.floorDiv(n * (n - 1), 2);\r\n\t}",
"public static int getDigit(int num, int place)\n\t\t{return (int) ((num % Math.pow(10, place)) / Math.pow(10, (place-1)));}",
"public static int next(int n)\n { \n int x = 0;\n if(n%2 == 0)\n {\n return n/2;\n }\n else\n {\n return (3*n)+1;\n }\n }",
"public static int reverse(int n) {\n int reverseNumber = 0;\n // Stores the last digit and pushed it one place to the left by multiplying by 10\n while(n != 0) {\n int lastDigit = n % 10;\n reverseNumber *= 10;\n reverseNumber += lastDigit;\n n /= 10;\n }\n\n return reverseNumber;\n }",
"public int getFirstKDigitNumber(int[] digits, int k) \r\n\t{\r\n\t\tint count = 0;\r\n\t\tfor(int i = 0; i < k; i++)\r\n\t\t{\r\n\t\t\tcount *= 10;\r\n\t\t\tcount += digits[i];\r\n\t\t}\r\n\r\n\t\treturn count;\r\n\t}",
"private static int digit(int b) {\n\t\tif (b >= '0' && b <= '9') return b - '0';\n\t\tthrow exceptionf(\"Not a digit: '%s'\" + escape((char) b));\n\t}",
"static int find(int decimal_number) \r\n { \r\n if (decimal_number == 0) \r\n return 0; \r\n \r\n else\r\n \r\n return (decimal_number % 2 + 10 * \r\n find(decimal_number / 2)); \r\n }",
"protected int getNbDigit() {\n return nbDigit;\n }",
"public int digitOnly(String input) {\n int digit = 0;\n String digitInString= input.replaceAll(\"[^0-9]\", \"\");\n digit = Integer.valueOf(digitInString);\n return digit;\n }",
"public int nthUglyNumber2(int n) {\n Queue<Long> choushu = new PriorityQueue<>();\n if (n == 1)\n return 1;\n choushu.offer((long) 1);\n int[] factor = {2, 3, 5};\n for (int i = 2; i <= n; i++) {\n long num = choushu.poll();\n for (int f : factor) {\n long tmp = f * num;\n if (!choushu.contains(tmp))\n choushu.offer(tmp);\n }\n System.out.println(MessageFormat.format(\"num:{0},list:{1}\", num, printQueue(choushu)));\n }\n return choushu.poll().intValue();\n }",
"public static int digits(int a) {\n\t\tint digits=0; // initialize to 0 first\n\t\twhile(a !=0) { // while a is not 0 do under\n\t\t\ta = a/10; // since its dividing by integer if the number is lower than 10 it will return 0;\n\t\t\tdigits++; // when a/10 != 0 add 1 to digits \n\t\t}\n\t\treturn digits; // return digits\n\t}",
"public static int naslednjiClen(int n) {\n\t\tif(n == 1) {\n\t\t\treturn(1);\n\t\t}else {\n\t\t\tif(n % 2== 0) {\n\t\t\t\treturn(n/2);\n\t\t\t}else {\n\t\t\t\treturn(3*n +1);\n\t\t\t}\n\t\t}\n\t}",
"public static int decimalNumber(String n)\n\t{\n\t\tint retv = 0;\n\n\t\tString[] arr = n.split(\"\");\n\n\t\tfor(int i=arr.length-1; i>=0; i--)\n\t\t{\n\t\t\tretv += (Integer.parseInt(arr[i]))*Math.pow(2, i);\n\t\t}\n\n\t\treturn retv;\n\t}",
"private static int nthUglyNumber(int n) {\n if (n == 0) {\n return 1;\n }\n\n int[] dp = new int[n];\n dp[0] = 1;\n int index2 = 0, index3 = 0, index5 = 0;\n for (int i = 1; i < n; i++) {\n dp[i] = Math.min(2 * dp[index2], Math.min(3 * dp[index3], 5 * dp[index5]));\n System.out.println(dp[i]);\n if (dp[i] == 2 * dp[index2]) {\n index2++;\n }\n\n if (dp[i] == 3 * dp[index3]) {\n index3++;\n }\n\n if (dp[i] == 5 * dp[index5]) {\n index5++;\n }\n }\n\n return dp[n - 1];\n }",
"public static int returnNLength(int numberLength, int decimalLength){\n\t\treturn ((decimalLength > 0) ? numberLength - 1 : numberLength);\n\t}",
"public int digitCounts(int k, int n) {\n\n\n int count = 0;\n char kChar = (char)(k + '0');\n for (int i = k; i <= n; i++) {\n char[] iChars = Integer.toString(i).toCharArray();\n for (char iChar : iChars) {\n if (kChar == iChar) count++;\n }\n }\n\n return count;\n }",
"public int trailingZeros(int n) {\n\t int factorial = 1;\n\t if(n > 1)\n\t factorial = factorial(n);\n\t \n\t if(factorial < 10)\n\t return 0;\n\t \n\t int z = 0;\n\t while(factorial % 10 == 0) {\n\t factorial = factorial / 10;\n\t z++;\n\t }\n\t return z;\n\t }",
"public static long findNum(long m) {\n if (m > 0 && m < Long.MAX_VALUE) {\n /**\n * Algo:\n *\n * (1 pow 3) = 1 ---> this will be the case, if input \"m\" is 1 (then result \"n\" = 1)\n * (2 pow 3) + (1 pow 3) = 9 ---> if input \"m\" is 9 (then result \"n\" = 2)\n * (3 pow 3) + (2 pow 3) + (1 pow 3) = 36 ---> if input \"m\" is 36 (then result \"n\" = 3)\n * (4 pow 3) + (3 pow 3) + (2 pow 3) + (1 pow 3) = 100 ---> if input \"m\" is 100 (then result \"n\" = 4)\n *\n *\n * Let's start with counter i = 1;\n * calculate m - (i pow 3), then if result is 0 then n = i\n *\n * Example, consider m = 9,\n * store m in some variable ---> result = 9\n * calculate result - (1 pow 3) = 8, then return i if result = 0, if not increment i\n * calculate result - (2 pow 3) = 0, then return i if result = 0, if not increment i\n *\n * continue this loop until result = 0, in any step if result < 0, then exit from loop and return -1\n */\n\n long result = m;\n for (int i = 1; i < Integer.MAX_VALUE; i++) {\n result = result - ((long) Math.pow(i, 3));\n if (result < 0) {\n break;\n } else if (result == 0) {\n return i;\n }\n }\n\n }\n return -1;\n }",
"public String countAndSay(int n) {\n String input = \"1\";\n String immediate_str = \"\";\n\n \n for (int i = 1; i < n; i++) {\n //System.out.println(input);\n char [] nums = input.toCharArray();\n int count = 0;\n int prev = -1;\n for (int j = 0; j < nums.length; j++) {\n //System.out.println(j + \",\"+ nums[j]);\n if ((nums[j] - '0') == prev) {\n count ++;\n }\n else {\n if (prev != -1)\n immediate_str += Integer.toString(count) + Integer.toString(prev);\n count = 1;\n }\n prev = nums[j] - '0';\n }\n immediate_str += Integer.toString(count) + Integer.toString(prev);\n input = immediate_str;\n immediate_str = \"\";\n }\n return input; \n }",
"public static int dolzina(int n) {\n\t\tint dolzina = 1;\n\t\t\n\t\twhile(n != 1) {\n\t\t\tn = naslednjiClen(n);\n\t\t\tdolzina = dolzina + 1;\n\t\t}\n\t\treturn(dolzina);\n\t\t\n\t}",
"public static void main(String[] args) {\nScanner sc=new Scanner(System.in);\r\nint num=sc.nextInt();\r\nint count=0;\r\nwhile(num!=0)\r\n{\r\n\tint n1=num%10;\r\n\tcount++;\r\n\tnum/=10;\r\n}\r\nSystem.out.println(count);\r\n\t}",
"public String getNormalizedN(int i) {\n\tint nb = getNb(i);\n\tif (nb == 1) return \"1\";\n\tint maxN = getMaxNb();\n\tif (maxN <= 5) return Integer.toString(nb);\n\tmaxN--;\n\tnb--;\n\tif (maxN < 21) {\n\t\tif (4*nb <= maxN) return \"1\";\n\t\tif (3*nb <= maxN) return \"2\";\n\t\tif (2*nb <= maxN) return \"3\";\n\t\tif (3*nb <= 2*maxN) return \"4\";\n\t\treturn \"5\";\n\t} else if (maxN < 100) {\n\t\tif (10*nb <= maxN) return \"1\";\n\t\tif (5*nb <= maxN) return \"2\";\n\t\tif (4*nb <= maxN) return \"3\";\n\t\tif (3*nb <= maxN) return \"4\";\n\t\tif (2*nb <= 1*maxN) return \"5\";\n\t\tif (3*nb <= 2*maxN) return \"6\";\n\t\treturn \"7\";\n\t} else {\n\t\tif (20*nb <= maxN) return \"1\";\n\t\tif (10*nb <= maxN) return \"2\";\n\t\tif (5*nb <= maxN) return \"3\";\n\t\tif (4*nb <= maxN) return \"4\";\n\t\tif (3*nb <= 1*maxN) return \"5\";\n\t\tif (2*nb <= 1*maxN) return \"6\";\n\t\treturn \"7\";\n\t}\n}",
"public static int generateFirstHalf(int n) {\n return ((int) Math.pow(10, n) - 1); // 99*99 < 9889, 999*999 < 998899 etc, so in this case, we could start checking from 10^n - 3\n }",
"private static String mod10(String code) {\n if (!code.matches(\"\\\\d+\")) {\n return null;\n }\n if (code.length() > 5) {\n return null;\n }\n // if length < 5, add leading \"0\"\n StringBuffer input = new StringBuffer(code);\n while (input.length() < 5) {\n input.insert(0, \"0\");\n }\n\n // 1. Using the number 12345, assign positions to the digits, from right\n // to left.\n\n // 2. Take the odd digit positions counting from the right (1st, 3rd,\n // 5th, etc.)\n StringBuffer odd = new StringBuffer();\n for (int i = 0; 2 * i < input.length(); i++) {\n odd.insert(0, input.charAt(2 * i));\n }\n\n // 3.Multiply by 2.\n int odd2 = Integer.parseInt(odd.toString()) * 2;\n\n // 4. Take the even digit positions starting from the right (2nd, 4th,\n // etc.).\n StringBuffer even = new StringBuffer();\n for (int i = 0; 2 * i + 1 < input.length(); i++) {\n even.insert(0, input.charAt(2 * i + 1));\n }\n\n // 5.Append (4) to the front of the results of (3).\n even.append(odd2);\n\n // 6. Add the digits of (5) together.\n double add = 0;\n for (int i = 0; i < even.length(); i++) {\n add = add + Integer.parseInt(even.substring(i, i + 1));\n }\n\n // 7. Find the next highest multiple of 10.\n double multiple = Math.ceil(add / 10) * 10;\n\n // 8. Subtract (6) from (7).\n Long result = Math.round(multiple - add);\n\n return result.toString();\n }",
"public int digitCounts(int k, int n) {\n int result = 0;\n for (int i = 1; i <= n; i++) {\n String nStr = String.valueOf(i);\n for (int j = 0; j < nStr.length(); j++) {\n if (nStr.charAt(j) == Character.forDigit(k, 10)) {\n result++;\n }\n }\n\n }\n return result;\n }",
"private static int charsInNumber(int number)\n\t{\n\t\tif (number > 9999)\n\t\t{\n\t\t\t//todo: increase this limit\n\t\t\tthrow new IllegalArgumentException(\n\t\t\t\t\t\"Cannot handle numbers larger than 9999\");\n\t\t}\n\t\t\n\t\t// result - initialised to 0;\n\t\tint letterCount = 0;\n\t\t//DEBUG\n\t\t//String dbgStr = \"\";\n\n\t\t// iterate over powers of 10 in reverse order to reflect how numbers\n\t\t// are read - e.g. one thousand, one hundred and one\n\t\t// starts at powerOfTen = 3: thousands (see powersOfTen[])\n\t\tfor (int currentPowerOfTen = 3; number > 0 && currentPowerOfTen >= 0;\n\t\t\t\tcurrentPowerOfTen--)\n\t\t{\n\t\t\t// handle \"teen\"s specially\n\t\t\tif (number < 20 && number >= 10)\n\t\t\t{\n\t\t\t\t// 17 is stored in teens[7], etc, so subtract 10 for offset\n\t\t\t\tletterCount += teens[number - 10];\n\t\t\t\t// DEBUG\n\t\t\t\t// if(DEBUG) dbgStr += dbgTeens[number - 10];\n\t\t\t\t\n\t\t\t\t// finished - \"teen\" is always the last expression\n\t\t\t\tnumber = 0;\n\t\t\t\t// if this offends you, feel free to comment it out\n\t\t\t\t// saves a few arithmetic operations\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t\t\n\t\t\t// get number to lookup length of word for using quotient\n\t\t\t// e.g. 4567 / 1000 = 4 using integer division\n\t\t\tint powerTenCount = (number / powersOfTen[currentPowerOfTen]);\n\t\t\t// zero this column (xyz -> 0yz) by subtracting\n\t\t\tnumber -= (powerTenCount * powersOfTen[currentPowerOfTen]);\n\t\t\t// look up word from ones array (e.g. \"one hundred\"), except for\n\t\t\t// multiples of 10 - use tens array\n\t\t\tint [] lookupArray = (currentPowerOfTen == 1) ? tens : ones;\n\t\t\t// increment letter count with the length of this word, e.g. \"six\"\n\t\t\tletterCount += lookupArray[powerTenCount];\n\t\t\t\n\t\t\tif (powerTenCount > 0)\n\t\t\t{\n\t\t\t\t// add name of the power of ten, e.g. \"thousand\"\n\t\t\t\tletterCount += powerTensWordLength[currentPowerOfTen];\n\t\t\t}\n\t\t\t\n\t\t\t//DEBUG\n\t\t\t//if(DEBUG) dbgStr += (currentPowerOfTen == 1 ? \n\t\t\t//\t\tdbgTens[powerTenCount] : dbgOnes[powerTenCount])\n\t\t\t//\t\t\t\t+ (powerTenCount > 0 ? \n\t\t\t//\t\t\t\t\t\tpowersOfTen[currentPowerOfTen] : \"\");\n\t\t\t\n\t\t\t// note: uses boolean short-circuiting to avoid out of bounds\n\t\t\t// lookup for condition when currentPowerTen == 0\n\t\t\t// (useAnd[0] is false -> powersTen[-1] is not looked up)\n\t\t\t// therefore, useAnd[0] must be false\n\t\t\tif\n\t\t\t(\n\t\t\t\t(\n\t\t\t\t\t\t// can only write \"and\" if a word is already written\n\t\t\t\t\t\t// word is only written if powerTenCount > 0\n\t\t\t\t\t\tpowerTenCount > 0\n\t\t\t\t)\n\t\t\t\t&&\n\t\t\t\t(\n\t\t\t\t\t\t// if this number uses \"and\" at all\n\t\t\t\t\t\t// e.g. \"fifty and *\" is never seen\n\t\t\t\t\t\tuseAnd[currentPowerOfTen]\n\t\t\t\t\t\t\t&&\n\t\t\t\t\t\t\t// there is a number left to stick on after it\n\t\t\t\t\t\t\t// e.g. \"one\" in \"one hundred and one\"\n\t\t\t\t\t\t\tnumber > 0\n\t\t\t\t)\n\t\t\t\t&&\n\t\t\t\t(\n\t\t\t\t\t\t// if number is less than the next lowest power of 10\n\t\t\t\t\t\t// e.g. \"one thousand and fifty\",\n\t\t\t\t\t\t// contrast \"one thousand, one hundred\"\n\t\t\t\t\t\tnumber < powersOfTen[currentPowerOfTen - 1]\n\t\t\t\t\t\t\t\t// hundreds exclusively always use \"and\"\n\t\t\t\t\t\t\t\t|| currentPowerOfTen == 2\n\t\t\t\t)\n\t\t\t)\n\t\t\t// if all of that is true\n\t\t\t{\n\t\t\t\t// stick an \"and\" on the end\n\t\t\t\t// (\"and\").length == 3\n\t\t\t\tletterCount += 3;\n\t\t\t\t\n\t\t\t\t//DEBUG\n\t\t\t\t// if(DEBUG) dbgStr += \"and\";\n\t\t\t}\n\t\t}\n\t\t\n\t\t//System.out.print(dbgStr);\n\t\treturn letterCount;\n\t}",
"public static void nDigits(int num) {\r\n for(int x = ((int)Math.pow(10, num - 1)); x < (int)Math.pow(10, num); x++) {\r\n if(x % 2 == 0){\r\n if(conditionChecker(x)) {\r\n System.out.println(x);\r\n }\r\n }\r\n }\r\n }",
"public int getNumDigits() {\r\n \r\n //Return Value\r\n return numDigits;\r\n \r\n }",
"public int numberOfDigit(int v) {\n int total = 1;\n while ((v / 10) > 0) {\n total++;\n v = v / 10;\n }\n return total;\n }",
"public static int alldigits(int x) {\n count1=0;\n do {\n x = x / 10;\n count1++;\n } while (x != 0);\n return count1;\n }",
"public static int getNumber(){\r\n\t\tint number=0;\r\n\t\twhile(true){\r\n\t\t\tString value = \"\" + input.next().charAt(0);\r\n\t\t\tif(Character.isDigit(value.charAt(0))){\r\n\t\t\tnumber = Integer.parseInt(value);\r\n\t\t\tbreak;\r\n\t\t\t}\r\n\t\t\tSystem.out.println(\"Incorrect input! try again.\");\r\n\t\t}\r\n\t\treturn number;\r\n\t}",
"private int getNum() {\r\n int i = currentNum.incrementAndGet();\r\n if (i < 0)\r\n i = -i;\r\n return i % n;\r\n }",
"java.lang.String getN();",
"public static long u(int n)\r\n\t{\r\n\t\tlong result = 0;\r\n\t\tlong current = 1;\r\n\t\tfor (int i = 0; i <= 10; i++)\r\n\t\t{\r\n\t\t\tif (i % 2 == 0)\r\n\t\t\t{\r\n\t\t\t\tresult += current;\r\n\t\t\t}\r\n\t\t\telse\r\n\t\t\t{\r\n\t\t\t\tresult -= current;\r\n\t\t\t}\r\n\t\t\tcurrent *= n;\r\n\t\t}\r\n\r\n\t\treturn result;\r\n\t}",
"public static int length(int n)\n {\n int w = n;\n if(w == 1)\n {\n return 1;\n } \n else\n {\n return 1 + length(next(w));\n }\n }",
"static int count8(int n) {\n if (n == 0)\n return 0;\n if (n % 10 == 8) {\n // RC1: if two rightmost digits is 88, count as 2, and recurse on rest\n if (n % 100 == 88)\n return 2 + count8(n / 10);\n else\n // RC2: if rightmost digit is just one 8, standard--count as 1 and recurse on rest\n return 1 + count8(n / 10);\n } else\n // RC3: if rightmost not 8, recurse on rest\n return count8(n / 10);\n }",
"public int maxDigit() {\n int maxDigit = 1;\n for (int i = 0; i < theArray.length; i++) {\n int n = numberOfDigit(theArray[i]);\n if (n > maxDigit)\n maxDigit = n;\n }\n return maxDigit;\n }",
"private static String intToWord(int n) {\n if(n < 0 || n > 9)\n throw new IllegalArgumentException(\"Number should be between 0-9\");\n\n switch(n) {\n case 0: return \"\";\n case 1: return \"one\";\n case 2: return \"two\";\n case 3: return \"three\";\n case 4: return \"four\";\n case 5: return \"five\";\n case 6: return \"six\";\n case 7: return \"seven\";\n case 8: return \"eight\";\n case 9: return \"nine\";\n default: return null;\n }\n }",
"public int getDigit(int position) {\r\n return array[position];\r\n }",
"public int getNumberOfDigits()\n\t{\n\t\t// TO DO\n\t\treturn infNumber.length;\n\t}",
"public int getE04(final int digitNumber);",
"public void testGetOnesDigit() {\n\t\tNumberConverter test5 = new NumberConverter(295);\n\t\tNumberConverter test9 = new NumberConverter(109);\n\t\tNumberConverter test11 = new NumberConverter(311);\n\t\tNumberConverter test0 = new NumberConverter(310);\n\t\tNumberConverter test00 = new NumberConverter(2);\n\t\tassertEquals(\"Should have returned last digit\", test5.getNthDigit(1), 5);\n\t\tassertEquals(\"Should have returned last digit\", test9.getNthDigit(1), 9);\n\t\tassertEquals(\"Should have returned last digit\", test11.getNthDigit(1),\n\t\t\t\t1);\n\t\tassertEquals(\"Should have returned last digit\", test0.getNthDigit(1), 0);\n\t\tassertEquals(\"Should have returned last digit\", test00.getNthDigit(1),\n\t\t\t\t2);\n\t}",
"private static int get_number(int i, int j) { n n!\n// C = _____________\n// r (n-r)! * r!\n//\n return factorial(i)/(factorial(i-j)* factorial(j));\n }",
"public int getDigit(int index) {\n\t\tif (index < 0 || index > data.length - 1) {\n\t\t\tSystem.out.println(\"cease this buffoonery.\");\n\t\t\tthrow new IllegalArgumentException();\n\t\t}\n\t\treturn data[index];\n\t}"
] | [
"0.7937389",
"0.7396731",
"0.7208121",
"0.7176513",
"0.7052697",
"0.703112",
"0.68484616",
"0.6817925",
"0.67867345",
"0.67779744",
"0.67413855",
"0.6741106",
"0.67116004",
"0.6689454",
"0.649358",
"0.64871264",
"0.63875467",
"0.6384317",
"0.638205",
"0.63728523",
"0.63632226",
"0.63616806",
"0.6342831",
"0.6311308",
"0.6266788",
"0.62515956",
"0.6238811",
"0.62265795",
"0.6185322",
"0.6175892",
"0.6146113",
"0.61191636",
"0.6113295",
"0.609845",
"0.6089736",
"0.60669464",
"0.60660136",
"0.60627997",
"0.6058534",
"0.605694",
"0.6050045",
"0.6048008",
"0.5980951",
"0.5959317",
"0.595869",
"0.5956713",
"0.5949288",
"0.59406763",
"0.593358",
"0.5929191",
"0.5926148",
"0.59204173",
"0.5918806",
"0.59011704",
"0.58888763",
"0.58850205",
"0.5882974",
"0.5866438",
"0.58512425",
"0.5809199",
"0.58084387",
"0.5794201",
"0.5771346",
"0.5767046",
"0.5761659",
"0.5750033",
"0.57386005",
"0.5717309",
"0.5713713",
"0.5707092",
"0.57028496",
"0.5691406",
"0.56805193",
"0.5676956",
"0.5667253",
"0.5661867",
"0.5660021",
"0.56544375",
"0.5650678",
"0.56490904",
"0.5635209",
"0.5623865",
"0.5620631",
"0.56140566",
"0.5609087",
"0.56049794",
"0.5602961",
"0.56022894",
"0.5599788",
"0.5587927",
"0.5578991",
"0.5574203",
"0.55727667",
"0.5568393",
"0.5556862",
"0.5554576",
"0.5552079",
"0.5550099",
"0.5544982",
"0.55377626"
] | 0.7670129 | 1 |
Sorts an array with the radix sort algorithm | private static void radixSortLsd(final Integer[] array, final SortOrder order) {
// an (signed) 32-bit integers' max length is 10
// 2^31-1 = 2 147 483 647 = 10 digits
for (int n = 1; n <= 10; n++) {
// this array holds every value for each n^th digit
final int[][] digits = new int[10][];
// first, find frequency of every digit for array initialization
final int[] frequency = new int[10];
for (final Integer integer : array) {
frequency[getDigitUnsafe(integer, n)]++;
}
// now create the arrays of every digit
for (int i = 0; i < frequency.length; i++) {
digits[i] = new int[frequency[i]];
// reset frequency for later use
frequency[i] = 0;
}
// because we don't want to waste power,
// we want to stop after there are no more digits left on all numbers in the array.
boolean noMoreDigitFound = true;
// iterate through every object in array
for (final int integer : array) {
int digit = getDigit(integer, n);
// if a digit WAS found, set noMoreDigitFound to false
// se we won't break this loop
if (digit != DIGIT_NOT_FOUND) {
noMoreDigitFound = false;
}
digit = Math.max(0, digit);
// Add digit to array
digits[digit][frequency[digit]++] = integer;
}
// overwrite current array
// start from the top left to the bottom right
int i = 0;
for (final int[] digitsb : digits) {
for (final int digit : digitsb) {
array[i++] = digit;
}
}
// break loop if there were no more digits found
if (noMoreDigitFound) {
break;
}
}
if (order == SortOrder.DESC) {
ArrayUtils.reverse(array);
} else if (order != SortOrder.ASC) {
throw new UnsupportedOperationException(
"Order-Operator " + order + " not implemented (yet).");
}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void radixSort() {\n int digits = String.valueOf(array[0]).length();\n for (int i = 1; i < array.length; i++) {\n if (String.valueOf(array[i]).length() > digits) {\n digits = String.valueOf(array[i]).length();\n }\n }\n int i = 1;\n while (i <= digits) {\n T[] bucket = (T[]) new Object[array.length];\n int j = 0;\n int k = 0;\n while (j < 10) {\n for (int l = 0; l < array.length; l++) {\n if ((int) array[l] % (int) (Math.pow(10, i)) / (int) (Math.pow(10, i - 1)) == j) {\n bucket[k] = array[l];\n k++;\n }\n }\n j++;\n }\n array = bucket;\n i++;\n }\n\n }",
"public MyArray radixSort(MyArray array) {\n int digits = String.valueOf(array.get(0)).length();\n for (int i = 1; i < array.length; i++) {\n if (String.valueOf(array.get(i)).length() > digits) {\n digits = String.valueOf(array.get(i)).length();\n }\n }\n int i = 1;\n while (i <= digits) {\n MyArray bucket = new MyArray();\n int j = 0;\n while (j < 10) {\n for (int l = 0; l < array.size; l++) {\n if ((int) array.get(l) % (int) (Math.pow(10, i)) / (int) (Math.pow(10, i - 1)) == j) {\n bucket.add(array.get(l));\n }\n }\n j++;\n }\n array = bucket;\n i++;\n }\n return array;\n }",
"public static void radixSort(Integer[] array, final int r) {\n assert r > 1;\n\n // The maximum number of digits for any number in array\n // (once we calculate it)\n int maxNumDigits = 0; \n\n // calculate the number of digits\n for (int i = 0; i < array.length; i++){\n int numDigits = (int) Math.ceil(Math.log(array[i])/Math.log(r));\n if (numDigits > maxNumDigits)\n maxNumDigits = numDigits;\n }\n \n // sort by each digit\n int rPow = 1;\n for (int i = 0; i < maxNumDigits; i++) {\n // \"Final\" version of rPow that we can use inside an anonymous inner class\n final int rp = rPow;\n countingSort(array, new ToInteger<Integer>() {\n public int v(Integer item) {\n throw new UnsupportedOperationException();\n }\n });\n rPow *= r;\n }\n }",
"public static int[] radixSort(int[]arr)\r\n\t{\r\n\t\td=(findMax(arr)+\"\").length();\r\n\t\tfor(int i=d;i>=1;i--)\r\n\t\t\tarr=stableSort(arr,i);\r\n\t\treturn arr;\r\n\t}",
"public static void sort(Integer a[]) {\n\n int arr[] = new int[a.length];\n int x = a.length;\n\n int max_digits = String.valueOf(get_max(a)).length();\n\n for (int i = 1; i<= Math.pow(10, max_digits); i *= 10){\n\n int[] place = new int[10];\n\n for (int j = 0; j < x; j++){\n\n place [(a[j] / i) % 10]++;\n }\n for (int j = 1; j < place.length; j++){\n place[j] += place[j-1];\n }\n\n for (int j = a.length -1; j>=0; j--)\n {\n arr[place[(a[j]/ i) % 10]- 1] = a[j];\n place[(a[j]/ i) % 10] --;\n }\n for (int j = 0; j < a.length; j++){\n a[j] = arr[j];\n }\n\n }\n System.out.println(\"after radix sorted\"+Arrays.toString(a));\n System.out.println(\"\");\n\n\n }",
"public void radixSorting() {\n\t\t\n\t}",
"public static int[] radixSort( int[] num) {\n\t\tArrayList<Integer>[] radix = new ArrayList[10];\n\n\t\tfor( int i = 0; i < 10; i++ )\n\t\t\tradix[i] = new ArrayList<Integer>();\n\n\t\t//determine the highest power of 10 by looking at the length of the numbers\n\t\tint power = Integer.toString(max(num)).length();\n\n\t\t//cycle through all powers of 10\n\t\tfor( int x = 0; x <= power; x++ ) {\n\t\t\tfor( int i = 0; i < num.length; i++ ) {\n\t\t\t\tint digit = num[i]; //store the current ith item\n\t\t\t\tdigit /= Math.pow(10, x); //shift the digits to right\n\t\t\t\tdigit %= 10; //extract the current least significant digit\n\t\t\t\tradix[digit].add(num[i]); //add the item to the corresponding ArrayList\n\t\t\t}\n\n\t\t\t//recreate the num array according to the lsd order\n\t\t\tint index = 0;\n\t\t\tfor( int i = 0; i < 10; i++ ) {\n\n\t\t\t\tfor(int j = 0; j < radix[i].size(); j++) {\n\t\t\t\t\tnum[index] = radix[i].get(j);\n\t\t\t\t\tindex++;\n\n\t\t\t\t}\n\t\t\t\tradix[i].clear();\n\t\t\t}\n\t\t}\n\t\treturn num;\n\t}",
"static void radixSort(int arr[], int n)\n {\n // Find the maximum number to know number of digits\n int m = getMax(arr, n);\n\n // Do counting sort for every digit. Note that instead\n // of passing digit number, exp is passed. exp is 10^i\n // where i is current digit number\n for (int exp = 1; m / exp > 0; exp *= 10)\n {\n countSort(arr, n, exp);\n }\n }",
"public int[] radixsort(int[] v) {\r\n\t int repeticionmaxima = 1; // cantidad de repeticiones\r\n\t int bytesdesplazados = 4; // numero de bytes a desplazar\r\n\t int arreglocolas = (int) Math.pow(2,bytesdesplazados) ;\r\n\t // Creación e inicialización del arreglo de colas\r\n\t Queue<Integer>[] cola = new LinkedList[arreglocolas];\r\n\t for(int i=0; i<arreglocolas; i++) cola[i]=new LinkedList<Integer>();\r\n\t \r\n\t int div = 0; // posición a comparar\r\n\t for(int i=0; i<repeticionmaxima; i++) {\r\n\t // parte 1: recorrer el vector para guardar cada elemento\r\n\t // en la cola correspondiente\r\n\t for(int numero: v) {\r\n\t // buscar el mayor número del vector\r\n\t if(i==0) if(numero>repeticionmaxima) repeticionmaxima=numero;\r\n\t // calcular en qué cola debe ir cada número\r\n\t int numCola = (numero>>div) & 0xf;\r\n\t cola[numCola].add(numero);\r\n\t }\r\n\t div = div+bytesdesplazados;\r\n\t \r\n\t // parte 2: recorrer las colas en orden para poner cada\r\n\t // elemento en el vector;\r\n\t int j=0;\r\n\t for(Queue<Integer> c: cola) {\r\n\t while(!c.isEmpty()) v[j++]=c.remove();\r\n\t }\r\n\t // la primera vez se actualiza el número de veces que se\r\n\t // debe ejecutar el proceso\r\n\t if(i==0) { repeticionmaxima = (int) (Math.log(repeticionmaxima)/Math.log(arreglocolas)) + 1; }\r\n\t }\r\n\t return v;\r\n\t }",
"public void bucketSort() {\n MyArray ten = new MyArray();\n MyArray hundred = new MyArray();\n MyArray thousand = new MyArray();\n MyArray tenThousand = new MyArray();\n MyArray hundredThousand = new MyArray();\n MyArray million = new MyArray();\n MyArray tenMillion = new MyArray();\n MyArray hundredMillion = new MyArray();\n MyArray billion = new MyArray();\n\n for (int i = 0; i < array.length; i++) {\n if ((int) array[i] / 10 < 0) {\n ten.add(array[i]);\n } else if ((int) array[i] / 100 < 0) {\n hundred.add(array[i]);\n } else if ((int) array[i] / 1000 < 0) {\n thousand.add(array[i]);\n } else if ((int) array[i] / 10000 < 0) {\n tenThousand.add(array[i]);\n } else if ((int) array[i] / 100000 < 0) {\n hundredThousand.add(array[i]);\n } else if ((int) array[i] / 1000000 < 0) {\n million.add(array[i]);\n } else if ((int) array[i] / 10000000 < 0) {\n tenMillion.add(array[i]);\n } else if ((int) array[i] / 100000000 < 0) {\n hundredMillion.add(array[i]);\n } else {\n billion.add(array[i]);\n }\n }\n\n ten = ten.radixSort(ten);\n hundred = hundred.radixSort(hundred);\n thousand = thousand.radixSort(thousand);\n tenThousand = tenThousand.radixSort(tenThousand);\n hundredThousand = hundredThousand.radixSort(hundredThousand);\n million = million.radixSort(million);\n tenMillion = tenMillion.radixSort(tenMillion);\n hundredMillion = hundredMillion.radixSort(hundredMillion);\n billion = billion.radixSort(billion);\n\n int j = 0;\n for (int i = 0; i < ten.getSize(); i++) {\n array[i] = (T) ten.get(i);\n j++;\n }\n for (int i = 0; i < hundred.getSize(); i++) {\n array[i] = (T) hundred.get(i);\n j++;\n }\n for (int i = 0; i < thousand.getSize(); i++) {\n array[i] = (T) thousand.get(i);\n j++;\n }\n for (int i = 0; i < tenThousand.getSize(); i++) {\n array[i] = (T) tenThousand.get(i);\n j++;\n }\n for (int i = 0; i < hundredThousand.getSize(); i++) {\n array[i] = (T) hundredThousand.get(i);\n j++;\n }\n for (int i = 0; i < million.getSize(); i++) {\n array[i] = (T) million.get(i);\n j++;\n }\n for (int i = 0; i < tenMillion.getSize(); i++) {\n array[i] = (T) tenMillion.get(i);\n j++;\n }\n for (int i = 0; i < hundredMillion.getSize(); i++) {\n array[j] = (T) hundredMillion.get(i);\n j++;\n }\n for (int i = 0; i < billion.getSize(); i++) {\n array[j] = (T) billion.get(i);\n j++;\n }\n\n }",
"static long[] radixsort(int arr[], int n)\r\n\r\n {\n\r\n int m = getMax(arr, n);\r\n\r\n long st = System.nanoTime();\r\n\r\n\r\n\r\n for (int exp = 1; m/exp > 0; exp *= 10)\r\n\r\n countSort(arr, n, exp);\r\n\r\n \r\n\r\n long et = System.nanoTime();\r\n\r\n threeVals[2] = et - st;\r\n\r\n return threeVals;\r\n\r\n }",
"public abstract void sort(int[] array);",
"public static void radixsort(int[] data) {\n MyLinkedList<Integer>[] buckets = new MyLinkedList[20];\n for (int i = 0; i < 20; i++) {\n buckets[i] = new MyLinkedList<Integer>();\n }\n MyLinkedList<Integer> numbers = new MyLinkedList<Integer>(); //Stores data\n //System.out.println(numbers);\n\n //Finding length of longest number\n int max = Math.abs(data[0]);\n int length = 1; //Stores num of digits of longest number\n for (int i = 1; i < data.length; i++) {\n if (Math.abs(data[i]) > max) {\n max = Math.abs(data[i]);\n }\n }\n //System.out.println(max);\n while (max / 10 > 0) {\n max = max / 10;\n length++;\n }\n //System.out.println(length);\n\n //Sorting by ones digit and converting array to linked list\n for (int num : data) {\n //Placing number in bucket\n if (num < 0) {\n buckets[9 - (Math.abs(num) % 10)].add(num);\n } else {\n buckets[10 + (Math.abs(num) % 10)].add(num);\n }\n }\n //Combines all the buckets to form an ordered data\n for (MyLinkedList<Integer> bucket : buckets) {\n //System.out.println(bucket); //Debugging\n numbers.extend(bucket);\n bucket.clear();\n }\n int currentDigit = 2; //Stores digit that will be sorted next\n //System.out.println(numbers);\n\n //Sorting using rest of the digits starting from tens place\n while (currentDigit <= length) {\n while (numbers.hasNext()) {\n int num = numbers.next();\n //Separates digit being considered\n int digit = (Math.abs(num) % (int)Math.pow(10, currentDigit)) / (int)Math.pow(10, currentDigit - 1);\n if (num < 0) {\n buckets[9 - digit].add(num);\n } else {\n buckets[10 + digit].add(num);\n }\n }\n numbers.clear();\n for (MyLinkedList<Integer> bucket : buckets) {\n //System.out.println(bucket); //\n numbers.extend(bucket);\n bucket.clear();\n }\n currentDigit++;\n //System.out.println(numbers);\n }\n\n //Copy numbers back to data\n int index = 0;\n numbers.reset();\n while (numbers.hasNext()) {\n data[index] = numbers.next();\n index++;\n }\n }",
"public static Integer[] sort(Integer[] X)\n\t{RadixSorting z = new RadixSorting(); //Where elements will be stored from array \n\t int place = 0;\n\t//maxIndex is assigned to numberLength function\n\t int maxIndex = numberLength(findMax(X ,0, X.length-1), 1); \n while (!(place > maxIndex))\n { //Inv: elements in X[0..X.length-1] are sorted && place<maxIndex \n \tbucketize(X, z, place);\n \t//Inv: elements in X[0..length-1]-1 are sorted and place>maxIndex\n debucketize(X);\n //Inv:elements in X[0..length-1] are sorted and place>maxIndex\n place = place + 1; \n //Inv: elements in X[0..X.length-1] are sorted && place<maxIndex \n } \n return (X); \n //Termination: place starts at 0. It is looped every time until finally place will be smaller\n //than maxIndex in which it will then terminate. \n\t}",
"@Override\n\tpublic void sort(int[] array) {\n\n\t}",
"public static void main(String[] args) {\n\t\t int[] A=new int[]{73,22, 93, 43, 55, 14, 28, 65, 39, 81};\n\t\t radixSort1(A, 100);\n\t\t System.out.println(Arrays.toString(A));\n\t}",
"public void radixSortHelp(int exp){\n int[] output = new int[toSort.length];\n //count array for occurences of digits\n int[] counting = new int[10];\n //initializes the arrays with 0s\n for(int i = 0; i < output.length; i++){\n output[i] = 0;\n }\n for(int i = 0; i < counting.length; i++){\n counting[i] = 0;\n }\n //get the count of occurences\n for(int i = 0; i < toSort.length; i++){\n //get index of the current loop - for example\n //first one would just be exp = 1, so normal val\n //second one would be exp = 10, so the lowest bit would get cut off\n int idx = toSort[i].val / exp;\n counting[idx % 10] += 1; //get lowest bit for that current val\n //adds animation so shows its doing something here\n //if no animation, then automatically sorts - user wouldnt know how it does that\n toSort[i].col = Color.red;\n sorting.add(paintIntegers.deepCopy(toSort));\n //resets the color\n toSort[i].col = Color.black;\n }\n //update count so that it now has the right position of the current digit of the val in output\n for(int i = 1; i < counting.length; i++){\n counting[i] += counting[i - 1];\n }\n //updating output with quite sorted array using the smallest bits each time\n for(int j = toSort.length - 1; j >= 0; j--){\n //get idx\n int idx = toSort[j].val / exp;\n //fills the output array\n output[counting[idx % 10] - 1] = toSort[j].val;\n //decrements the count\n counting[idx % 10] -= 1;\n }\n //once the output is then built, then updates to original array\n for(int i = 0; i < toSort.length; i ++){\n toSort[i].val = output[i];\n //adds animation\n sorting.add(paintIntegers.deepCopy(toSort));\n }\n }",
"private void sorter(int[] array){\r\n\r\n for (int i = 0; i < array.length-1; i++)\r\n for (int j = 0; j < array.length-i-1; j++)\r\n if (array[j] > array[j+1])\r\n {\r\n int temp = array[j];\r\n array[j] = array[j+1];\r\n array[j+1] = temp;\r\n }\r\n }",
"private int[] sort(int arr[]) {\r\n\t\tint n = arr.length;\r\n\r\n\t\tif (n == 1) { // base case\r\n\t\t\treturn arr;\r\n\t\t}\r\n\t\t// divide\r\n\t\tint[] arrL = Arrays.copyOfRange(arr, 0, (n / 2));\r\n\t\tint[] arrR = Arrays.copyOfRange(arr, (n / 2), (n));\r\n\t\t// and conquer\r\n\t\treturn merge(sort(arrL), sort(arrR));\r\n\t}",
"public int[] performSort(int[] arr){\n arr = sb.sort(arr);\n return arr;\n }",
"private static void sort(int[] a) {\n shufle(a);\n // we use quicksort here because there's no need for stability\n sort(a, 0, a.length - 1);\n }",
"@Override\n public void sort(int[] input) {\n }",
"public static void sort(int[] a)\r\n\t {\r\n\t int[] b = new int[10];\r\n\t int max = getMax(a);\r\n\t int place = 1;\r\n\t System.out.println(max);\r\n\t while (max / place > 0)\r\n\t {\r\n\t \tint[] bucket = new int[10];\r\n\t for (int i = 0; i < a.length; i++)\r\n\t {\r\n\t \tbucket[(a[i]/place) % 10]++;\r\n\t }\t \r\n\t for (int i = 1; i < 10; i++)\r\n\t {\r\n\t \tbucket[i] += bucket[i - 1];\r\n\t } \r\n\t for (int i = a.length - 1; i >= 0; i--)\r\n\t {\r\n\t \tb[--bucket[(a[i]/place)%10]] = a[i];\r\n\t } \r\n\t for (int i=0; i<a.length; i++)\r\n\t {\r\n\t \ta[i] = b[i];\r\n\t }\t \r\n\t place *= 10; \r\n\t }\r\n\t }",
"public void sort(Element[] array, int low, int high, int digit) {\n for (int i = low; i <= high; i++) {\n for (int j = i; j > low && less(array[j].value, array[j - 1].value, digit); j--) {\n ArrayUtil.exchange(array, j, j - 1);\n }\n }\n }",
"public static Integer[] radixSort(Integer[] inputs) {\n\t\t// Get the maximum number of digits from the given inputs.\n\t\tint maxDigits = getMaxDigits(inputs);\n\n\t\t// Iterate radix depending on max digits.\n\t\tfor (int digit = 1; digit <= maxDigits; digit++) {\n\t\t\tInteger radixNumber;\n\t\t\tfor (int n = 0; n < inputs.length; n++) {\n\t\t\t\t// extract radix number from input array\n\t\t\t\tradixNumber = extractDigit(inputs[n], digit);\n\t\t\t\tif (!(radixNumber == null)) {\n\t\t\t\t\t// enqueue inputs in to the corresponding queue { Q0, Q1, Q2, Q3, Q4, Q5, Q6,\n\t\t\t\t\t// Q7, Q8, Q9 }\n\t\t\t\t\tqueue[radixNumber].enqueue(inputs[n]);\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t// Go through the queues and insert the numbers back into the inputs array and\n\t\t\t// dequeue from the corresponding Queues.\n\t\t\tint a = 0;\n\t\t\tfor (int k = 0; k < queue.length; k++) {\n\t\t\t\t// Iterate through every element in your queues { Q0, Q1, Q2, Q3, Q4, Q5, Q6,\n\t\t\t\t// Q7, Q8, Q9 }\n\t\t\t\twhile (queue[k].last != null) {\n\t\t\t\t\tinputs[a++] = queue[k].front();\n\t\t\t\t\tqueue[k].dequeue();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t// return the output sorted list\n\t\treturn inputs;\n\t}",
"void sort(int[] sort);",
"public abstract void sort(int[] sortMe);",
"public void sort(int array[]){\n for(int i=1;i < array.length;i++){\n int j=i-1;\n int cur=i;\n while(array[cur] < array[j] && j >=0 ){\n swap(array,cur,j);\n cur--;\n j--;\n }\n\n }\n }",
"public void sort(int[] a) {\n\t\tint n = a.length;\n\t\tint temp;\n\t\tfor (int gap = n / 2; gap > 0; gap /= 2) {\n\t\t\tfor (int i = gap; i < n; i++) {\n\t\t\t\tfor (int j = i - gap; j >= 0; j -= gap) {\n\t\t\t\t ++totalValCmp;\n\t\t\t\t if (a[j] > a[j + gap]) {\n\t\t\t\t\t temp = a[j];\n\t\t\t\t\t a[j] = a[j + gap];\n\t\t\t\t\t a[j + gap] = temp;\n\t\t\t\t\t ++totalswaps;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}",
"@Override\n\tpublic int[] sort(int[] arr) {\n\t\tif(arr == null) \n\t\t\tthrow new Error(\"################ Array is null ################\");\n\t\tint left = 0;\n\t\tint right = arr.length-1;\n\t\treturn ( right <= 0)? arr : split(left, right, arr);\n\t}",
"void sort() {\n\t\tint n = array.length;\n\t\tint temp = 0;\n\t\tfor (int i = 0; i < n; i++) {\n\t\t\tfor (int j = 1; j < (n - i); j++) {\n\t\t\t\tif (array[j - 1] > array[j]) { // if the first term is larger\n\t\t\t\t\t\t\t\t\t\t\t\t// than the last term, then the\n\t\t\t\t\t\t\t\t\t\t\t\t// temp holds the previous term\n\t\t\t\t\ttemp = array[j - 1];\n\t\t\t\t\tarray[j - 1] = array[j];// swaps places within the array\n\t\t\t\t\tarray[j] = temp;\n\t\t\t\t}\n\n\t\t\t}\n\t\t}\n\t}",
"static int[] Sort(int array[])\n\t{\n\t\t//Check to see if there is one or more numbers in the array.\n\t\tif(array.length > 1)\n\t\t//If there is more than one number, begin the process of splitting the array in half.\n\t\t{\n\t\t\tint sparray1 = array.length/2;\n\t\t\tint sparray2 = sparray1;\n\t\t\t\tif((array.length % 2) == 1)\n\t\t\t\t\tsparray2 += 1;\n\t\t//Initialize the new split sub-arrays and copy for sorting.\n\t\t\tint split1[] = new int[sparray1];\n\t\t\tint split2[] = new int[sparray2];\n\t\t\tfor(int i = 0; i < sparray1; i++)\n\t\t\t\tsplit1[i] = array[i];\n\t\t\tfor(int i = sparray1; i < sparray1 + sparray2; i++)\n\t\t\t\tsplit2[i - sparray1] = array[i];\n\t\t//Send sub-arrays back through the methods to be sorted.\n\t\t\tsplit1 = Sort(split1);\n\t\t\tsplit2 = Sort(split2);\n\t\t//Compare the numbers in the sub-arrays and sort them from small to large.\n\t\t\tint i = 0, j = 0, k = 0;\n\t\t\twhile(split1.length != j && split2.length != k)\n\t\t\t{\n\t\t\t\tif(split1[j] < split2[k])\n\t\t\t\t{\n\t\t\t\t\tarray[i] = split1[j];\n\t\t\t\t\ti++;\n\t\t\t\t\tj++;\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\tarray[i] = split2[k];\n\t\t\t\t\ti++;\n\t\t\t\t\tk++;\n\t\t\t\t}\n\t\t\t}\n\t\t//Recombine the sorted sub-arrays and return the completed sorted array. \n\t\t\twhile(split1.length != j)\n\t\t\t{\n\t\t\t\tarray[i] = split1[j];\n\t\t\t\ti++;\n\t\t\t\tj++;\n\t\t\t}\n\t\t\twhile(split2.length != k)\n\t\t\t{\n\t\t\t\tarray[i] = split2[k];\n\t\t\t\ti++;\n\t\t\t\tk++;\n\t\t\t}\n\t\t}\n\t\treturn array;\n\t}",
"public static void sort(int[] arr) {\n // Base Case\n if (arr.length == 1) return;\n\n // Splitting the array\n int midpoint = arr.length / 2;\n int[] left_arr = Arrays.copyOfRange(arr, 0, midpoint);\n int[] right_arr = Arrays.copyOfRange(arr, midpoint, arr.length);\n\n // Sorting the subarrays \n sort(left_arr);\n sort(right_arr);\n\n // Combining the subarrays\n int left_pointer = 0;\n int right_pointer = 0;\n /** \n * Check which array has smaller value then \n * assign it to sorted array\n */ \n while (left_pointer + right_pointer < arr.length) {\n // Left array has been traversed\n if (left_pointer >= left_arr.length) {\n arr[left_pointer + right_pointer] \n = right_arr[right_pointer];\n right_pointer++;\n }\n // Right array has been traversed\n else if (right_pointer >= right_arr.length) {\n arr[left_pointer + right_pointer]\n = left_arr[left_pointer];\n left_pointer++;\n }\n // Both arrays still have values.\n else {\n // Left array has smaller or equal value\n if (left_arr[left_pointer] <= right_arr[right_pointer]) { \n arr[left_pointer + right_pointer]\n = left_arr[left_pointer];\n left_pointer++;\n }\n // Right array has smaller value\n else {\n arr[left_pointer + right_pointer]\n = right_arr[right_pointer];\n right_pointer++;\n }\n }\n }\n // Array is sorted. Replace given array.\n }",
"public static void sort(int[] arr){\n\t\tint temp;\n\t\tfor(int i=0; i<arr.length; i++){\n\t\t\tfor(int j=1; j<arr.length-i; j++)\n\t\t\tif(arr[j-1] > arr[j]){\n\t\t\t\ttemp = arr[j-1];\n\t\t\t\tarr[j-1] = arr[j];\n\t\t\t\tarr[j] = temp;\n\t\t\t}\n\t\t\t\n\t\t}\n\t}",
"static void sort(int[] a)\n {\n for ( int j = 1; j<a.length; j++)\n {\n int i = j - 1;\n while(i>=0 && a[i]>a[i+1])\n {\n int temp = a[i];\n a[i] = a[i+1];\n a[i+1] = temp;\n i--;\n }\n }\n }",
"private void mergesort(int[] array) {\n\t\t\n\t}",
"private static void sort(int[] arr) {\n\t\tint lesserIndex=-1;\n\t\tint arrLen = arr.length ; \n\t\tfor(int i=0; i<arrLen; i++){\n\t\t\tif(arr[i]<0){\n\t\t\t\tlesserIndex++; \n\t\t\t\tint tmp = arr[lesserIndex]; \n\t\t\t\tarr[lesserIndex] = arr[i];\n\t\t\t\tarr[i] = tmp; \n\t\t\t}\n\t\t}\n\t\t\n\t\t\n\t\tint negBound = lesserIndex+1;\n\t\tint posIndex = negBound;\n\t\t\n\t\tfor(int negIngex = 0;negIngex<negBound && posIndex<arr.length; negIngex+=2, posIndex+=1){\n\t\t\tint tmp = arr[posIndex]; \n\t\t\tarr[posIndex] = arr[negIngex] ; \n\t\t\tarr[negIngex] = tmp ;\n\t\t\tnegBound++;\n\t\t}\n\t\t\n\t\t\n\t\tfor(int a : arr) {\n\t\t\tSystem.out.print(a);\n\t\t}\n\t\t\n\t}",
"@Override\n public void sort(int[] array) {\n for (int i = 0; i < array.length - 1; ++i) {\n for (int j = i + 1; j < array.length; ++j) {\n if (array[i] > array[j]) {\n int tmp = array[i];\n array[i] = array[j];\n array[j] = tmp;\n }\n }\n }\n }",
"public static void sort(int [] a) {\n for(int i=0; i<a.length;i++){\n for (int j = i+1; j < a.length; j++) {\n int temp=0;\n if(a[i]>a[j]){\n temp=a[j];\n a[j]=a[i];\n a[i]=temp;\n }\n }\n }\n }",
"@Override\n\tpublic void sort(Integer[] array, int leftIndex, int rightIndex) {\n\t\tif(array.length > 0) {\n\t\t\tint menor = array[leftIndex];\n\t\t\tint maior = array[leftIndex];\n\t\t\tfor (int i = leftIndex; i <= rightIndex; i++) {\n\t\t\t\tif (array[i] >= maior)\n\t\t\t\t\tmaior = array[i];\n\n\t\t\t\tif (array[i] < menor)\n\t\t\t\t\tmenor = array[i];\n\t\t\t}\n\t\t\t// Registra-se a frequencia em que cada elemento aparece.\n\t\t\tint[] auxiliar = new int[maior - menor + 1];\n\t\t\tfor (int i = leftIndex; i <= rightIndex; i++) {\n\t\t\t\tauxiliar[array[i] - menor] += 1; // semelhante a um 'shift' para direita, pois os elementos\n\t\t\t}\t\t\t\t\t\t\t\t\t // negativos entram tambem.\n\n\t\t\t// Registra-se a soma cumulativa dos indices ocupados do array auxiliar.\n\t\t\tfor (int i = 1; i < auxiliar.length; i++) {\n\t\t\t\tauxiliar[i] += auxiliar[i - 1];\n\t\t\t}\n\n\t\t\t// Cria-se um array ordenado, a partir do array incial.\n\t\t\tInteger[] arrayOrdenado = new Integer[array.length];\n\t\t\tfor (int i = rightIndex; i >= leftIndex ; i--) {\n\t\t\t\tarrayOrdenado[auxiliar[array[i] - menor] - 1] = array[i];\n\t\t\t\tauxiliar[array[i] - menor] -= 1;\n\t\t\t}\n\n\t\t\tfor (int i = leftIndex; i <= rightIndex; i++) {\n\t\t\t\tarray[i] = arrayOrdenado[i];\n\t\t\t}\n\t\t}\n\t}",
"public void sort() {\r\n int k = start;\r\n for (int i = 0; i < size - 1; i++) {\r\n int p = (k + 1) % cir.length;\r\n for (int j = i + 1; j < size; j++) {\r\n if ((int) cir[p] < (int) cir[k % cir.length]) {\r\n Object temp = cir[k];\r\n cir[k] = cir[p];\r\n cir[p] = temp;\r\n }\r\n p = (p + 1) % cir.length;\r\n }\r\n k = (k + 1) % cir.length;\r\n }\r\n }",
"@Override\n public int[] sort(int[] array) {\n\n int n = array.length;\n\n for (int i = 1; i <= n - 1; i++) {\n int j = i - 1;\n\n while (j >= 0 && array[j] > array[j + 1]) {\n swap(array, j, j + 1);\n j--;\n }\n }\n\n return array;\n }",
"private void jButton1ActionPerformed(java.awt.event.ActionEvent evt) {\n resultt=\"\";\n iteration=\"\";\n myArray=null;\n\n String arr=array.getText();\n StringBuilder sb=new StringBuilder(arr);\n sb.append(',');\n arr=sb.toString();\n int last=0;\n int k=0;\n int count=0;\n\n for(int i=0;i<arr.length();i++){\n if(arr.charAt(i)==','){\n count++;\n }\n }\n\n myArray=new int[count];\n\n for(int i=0;i<arr.length();i++){\n if(arr.charAt(i)==','){\n String temp=arr.substring(last, i);\n myArray[k]=Integer.parseInt(temp);\n last=i+1;\n k++;\n }\n }\n StringBuilder s1=new StringBuilder (iteration);\n StringBuilder s2=new StringBuilder (resultt);\n //radix sort code starts here\n int temp,i,j,m;\n int pos,c=0,f=1,max=getMax(),size=myArray.length;\n while(max!=0) //while loop for getting number of digits of max. number\n {\n max=max/10;\n c++;\n }\n Queue q1[] = new Queue[10]; // making array of Queues containing 10 elements \n /*\n \n | | | | | | | | | | | | | | | | | | | | \n |_| |_| |_| |_| |_| |_| |_| |_| |_| |_|\n 0 1 2 3 4 5 6 7 8 9 \n \n 10 queues for each digit\n */\n for(i = 0; i < 10; i++) // Array sirf abstract tha abb usmy memory aayi ha\n q1[i] = new LinkedList(); \n \n for(i=1;i<=c;i++) //C hmara max. number k number of digit ha ... like 1051 ma c ki value 4 hogi tou yeh loop utni baar chalega first for unit then tenth on and on...\n {\n for(j=0;j<size;j++)\n {\n pos=myArray[j]/f; //harr aik element uthaega aur uska unith(when f=1) , tenth(when f=10) , hundreth(when f=100) digit save krega 'pos' ma\n while(pos>9)\n {\n pos=pos%10;\n }\n \n q1[pos].add(myArray[j]); //abb pos ma jo number ha ussi index pr jaega Queue myArray ma aur waha pr wo element ko add krega like 541 ka tenth digit '4' ha tou Queue[4] pr 541 ko add krdega\n// System.out.println(myArray[j]); \n s1.append(myArray[j]);\n s1.append(',');\n }\n// System.out.println();\n s1.append('\\n');\n k=0;\n for(j=0;j<9;j++) // abb iss loop ma saray queues ko khaali krega line se starting from 0 to 9 aur unkay elements ko original myArray ma daal dega\n {\n while(!q1[j].isEmpty())\n {\n myArray[k]=(int)q1[j].remove();\n k++;\n }\n }\n f=f*10; // f ko multiply by 10 so that next iteration ma tenth position se uthae then usse next hundreth and so onn..\n }\n \n \n \n \n for(i=0;i<size;i++){\n// System.out.print(myArray[i]+\" \");\n s2.append(myArray[i]); \n s2.append(','); \n s1.append(myArray[i]); \n s1.append(','); \n }\n \n iteration=s1.toString();\n resultt=s2.toString();\n output.setText(resultt);\n }",
"public int Sort(){\n\tint nt ;\n\tint i ;\n\tint aux02 ;\n\tint aux04 ;\n\tint aux05 ;\n\tint aux06 ;\n\tint aux07 ;\n\tint j ;\n\tint t ;\n\ti = size - 1 ;\n\taux02 = 0 - 1 ;\n\twhile (aux02 < i) {\n\t j = 1 ;\n\t //aux03 = i+1 ;\n\t while (j < (i+1)){\n\t\taux07 = j - 1 ;\n\t\taux04 = number[aux07] ;\n\t\taux05 = number[j] ;\n\t\tif (aux05 < aux04) {\n\t\t aux06 = j - 1 ;\n\t\t t = number[aux06] ;\n\t\t number[aux06] = number[j] ;\n\t\t number[j] = t;\n\t\t}\n\t\telse nt = 0 ;\n\t\tj = j + 1 ;\n\t }\n\t i = i - 1 ;\n\t}\n\treturn 0 ;\n }",
"public int Sort(){\n\tint nt ;\n\tint i ;\n\tint aux02 ;\n\tint aux04 ;\n\tint aux05 ;\n\tint aux06 ;\n\tint aux07 ;\n\tint j ;\n\tint t ;\n\ti = size - 1 ;\n\taux02 = 0 - 1 ;\n\twhile (aux02 < i) {\n\t j = 1 ;\n\t //aux03 = i+1 ;\n\t while (j < (i+1)){\n\t\taux07 = j - 1 ;\n\t\taux04 = number[aux07] ;\n\t\taux05 = number[j] ;\n\t\tif (aux05 < aux04) {\n\t\t aux06 = j - 1 ;\n\t\t t = number[aux06] ;\n\t\t number[aux06] = number[j] ;\n\t\t number[j] = t;\n\t\t}\n\t\telse nt = 0 ;\n\t\tj = j + 1 ;\n\t }\n\t i = i - 1 ;\n\t}\n\treturn 0 ;\n }",
"public int Sort(){\n\tint nt ;\n\tint i ;\n\tint aux02 ;\n\tint aux04 ;\n\tint aux05 ;\n\tint aux06 ;\n\tint aux07 ;\n\tint j ;\n\tint t ;\n\ti = size - 1 ;\n\taux02 = 0 - 1 ;\n\twhile (aux02 < i) {\n\t j = 1 ;\n\t //aux03 = i+1 ;\n\t while (j < (i+1)){\n\t\taux07 = j - 1 ;\n\t\taux04 = number[aux07] ;\n\t\taux05 = number[j] ;\n\t\tif (aux05 < aux04) {\n\t\t aux06 = j - 1 ;\n\t\t t = number[aux06] ;\n\t\t number[aux06] = number[j] ;\n\t\t number[j] = t;\n\t\t}\n\t\telse nt = 0 ;\n\t\tj = j + 1 ;\n\t }\n\t i = i - 1 ;\n\t}\n\treturn 0 ;\n }",
"public int Sort(){\n\tint nt ;\n\tint i ;\n\tint aux02 ;\n\tint aux04 ;\n\tint aux05 ;\n\tint aux06 ;\n\tint aux07 ;\n\tint j ;\n\tint t ;\n\ti = size - 1 ;\n\taux02 = 0 - 1 ;\n\twhile (aux02 < i) {\n\t j = 1 ;\n\t //aux03 = i+1 ;\n\t while (j < (i+1)){\n\t\taux07 = j - 1 ;\n\t\taux04 = number[aux07] ;\n\t\taux05 = number[j] ;\n\t\tif (aux05 < aux04) {\n\t\t aux06 = j - 1 ;\n\t\t t = number[aux06] ;\n\t\t number[aux06] = number[j] ;\n\t\t number[j] = t;\n\t\t}\n\t\telse nt = 0 ;\n\t\tj = j + 1 ;\n\t }\n\t i = i - 1 ;\n\t}\n\treturn 0 ;\n }",
"public int Sort(){\n\tint nt ;\n\tint i ;\n\tint aux02 ;\n\tint aux04 ;\n\tint aux05 ;\n\tint aux06 ;\n\tint aux07 ;\n\tint j ;\n\tint t ;\n\ti = size - 1 ;\n\taux02 = 0 - 1 ;\n\twhile (aux02 < i) {\n\t j = 1 ;\n\t //aux03 = i+1 ;\n\t while (j < (i+1)){\n\t\taux07 = j - 1 ;\n\t\taux04 = number[aux07] ;\n\t\taux05 = number[j] ;\n\t\tif (aux05 < aux04) {\n\t\t aux06 = j - 1 ;\n\t\t t = number[aux06] ;\n\t\t number[aux06] = number[j] ;\n\t\t number[j] = t;\n\t\t}\n\t\telse nt = 0 ;\n\t\tj = j + 1 ;\n\t }\n\t i = i - 1 ;\n\t}\n\treturn 0 ;\n }",
"public int Sort(){\n\tint nt ;\n\tint i ;\n\tint aux02 ;\n\tint aux04 ;\n\tint aux05 ;\n\tint aux06 ;\n\tint aux07 ;\n\tint j ;\n\tint t ;\n\ti = size - 1 ;\n\taux02 = 0 - 1 ;\n\twhile (aux02 < i) {\n\t j = 1 ;\n\t //aux03 = i+1 ;\n\t while (j < (i+1)){\n\t\taux07 = j - 1 ;\n\t\taux04 = number[aux07] ;\n\t\taux05 = number[j] ;\n\t\tif (aux05 < aux04) {\n\t\t aux06 = j - 1 ;\n\t\t t = number[aux06] ;\n\t\t number[aux06] = number[j] ;\n\t\t number[j] = t;\n\t\t}\n\t\telse nt = 0 ;\n\t\tj = j + 1 ;\n\t }\n\t i = i - 1 ;\n\t}\n\treturn 0 ;\n }",
"public int Sort(){\n\tint nt ;\n\tint i ;\n\tint aux02 ;\n\tint aux04 ;\n\tint aux05 ;\n\tint aux06 ;\n\tint aux07 ;\n\tint j ;\n\tint t ;\n\ti = size - 1 ;\n\taux02 = 0 - 1 ;\n\twhile (aux02 < i) {\n\t j = 1 ;\n\t //aux03 = i+1 ;\n\t while (j < (i+1)){\n\t\taux07 = j - 1 ;\n\t\taux04 = number[aux07] ;\n\t\taux05 = number[j] ;\n\t\tif (aux05 < aux04) {\n\t\t aux06 = j - 1 ;\n\t\t t = number[aux06] ;\n\t\t number[aux06] = number[j] ;\n\t\t number[j] = t;\n\t\t}\n\t\telse nt = 0 ;\n\t\tj = j + 1 ;\n\t }\n\t i = i - 1 ;\n\t}\n\treturn 0 ;\n }",
"public int Sort(){\n\tint nt ;\n\tint i ;\n\tint aux02 ;\n\tint aux04 ;\n\tint aux05 ;\n\tint aux06 ;\n\tint aux07 ;\n\tint j ;\n\tint t ;\n\ti = size - 1 ;\n\taux02 = 0 - 1 ;\n\twhile (aux02 < i) {\n\t j = 1 ;\n\t //aux03 = i+1 ;\n\t while (j < (i+1)){\n\t\taux07 = j - 1 ;\n\t\taux04 = number[aux07] ;\n\t\taux05 = number[j] ;\n\t\tif (aux05 < aux04) {\n\t\t aux06 = j - 1 ;\n\t\t t = number[aux06] ;\n\t\t number[aux06] = number[j] ;\n\t\t number[j] = t;\n\t\t}\n\t\telse nt = 0 ;\n\t\tj = j + 1 ;\n\t }\n\t i = i - 1 ;\n\t}\n\treturn 0 ;\n }",
"public int Sort(){\n\tint nt ;\n\tint i ;\n\tint aux02 ;\n\tint aux04 ;\n\tint aux05 ;\n\tint aux06 ;\n\tint aux07 ;\n\tint j ;\n\tint t ;\n\ti = size - 1 ;\n\taux02 = 0 - 1 ;\n\twhile (aux02 < i) {\n\t j = 1 ;\n\t //aux03 = i+1 ;\n\t while (j < (i+1)){\n\t\taux07 = j - 1 ;\n\t\taux04 = number[aux07] ;\n\t\taux05 = number[j] ;\n\t\tif (aux05 < aux04) {\n\t\t aux06 = j - 1 ;\n\t\t t = number[aux06] ;\n\t\t number[aux06] = number[j] ;\n\t\t number[j] = t;\n\t\t}\n\t\telse nt = 0 ;\n\t\tj = j + 1 ;\n\t }\n\t i = i - 1 ;\n\t}\n\treturn 0 ;\n }",
"public int Sort(){\n\tint nt ;\n\tint i ;\n\tint aux02 ;\n\tint aux04 ;\n\tint aux05 ;\n\tint aux06 ;\n\tint aux07 ;\n\tint j ;\n\tint t ;\n\ti = size - 1 ;\n\taux02 = 0 - 1 ;\n\twhile (aux02 < i) {\n\t j = 1 ;\n\t //aux03 = i+1 ;\n\t while (j < (i+1)){\n\t\taux07 = j - 1 ;\n\t\taux04 = number[aux07] ;\n\t\taux05 = number[j] ;\n\t\tif (aux05 < aux04) {\n\t\t aux06 = j - 1 ;\n\t\t t = number[aux06] ;\n\t\t number[aux06] = number[j] ;\n\t\t number[j] = t;\n\t\t}\n\t\telse nt = 0 ;\n\t\tj = j + 1 ;\n\t }\n\t i = i - 1 ;\n\t}\n\treturn 0 ;\n }",
"public int Sort(){\n\tint nt ;\n\tint i ;\n\tint aux02 ;\n\tint aux04 ;\n\tint aux05 ;\n\tint aux06 ;\n\tint aux07 ;\n\tint j ;\n\tint t ;\n\ti = size - 1 ;\n\taux02 = 0 - 1 ;\n\twhile (aux02 < i) {\n\t j = 1 ;\n\t //aux03 = i+1 ;\n\t while (j < (i+1)){\n\t\taux07 = j - 1 ;\n\t\taux04 = number[aux07] ;\n\t\taux05 = number[j] ;\n\t\tif (aux05 < aux04) {\n\t\t aux06 = j - 1 ;\n\t\t t = number[aux06] ;\n\t\t number[aux06] = number[j] ;\n\t\t number[j] = t;\n\t\t}\n\t\telse nt = 0 ;\n\t\tj = j + 1 ;\n\t }\n\t i = i - 1 ;\n\t}\n\treturn 0 ;\n }",
"public int Sort(){\n\tint nt ;\n\tint i ;\n\tint aux02 ;\n\tint aux04 ;\n\tint aux05 ;\n\tint aux06 ;\n\tint aux07 ;\n\tint j ;\n\tint t ;\n\ti = size - 1 ;\n\taux02 = 0 - 1 ;\n\twhile (aux02 < i) {\n\t j = 1 ;\n\t //aux03 = i+1 ;\n\t while (j < (i+1)){\n\t\taux07 = j - 1 ;\n\t\taux04 = number[aux07] ;\n\t\taux05 = number[j] ;\n\t\tif (aux05 < aux04) {\n\t\t aux06 = j - 1 ;\n\t\t t = number[aux06] ;\n\t\t number[aux06] = number[j] ;\n\t\t number[j] = t;\n\t\t}\n\t\telse nt = 0 ;\n\t\tj = j + 1 ;\n\t }\n\t i = i - 1 ;\n\t}\n\treturn 0 ;\n }",
"public int Sort(){\n\tint nt ;\n\tint i ;\n\tint aux02 ;\n\tint aux04 ;\n\tint aux05 ;\n\tint aux06 ;\n\tint aux07 ;\n\tint j ;\n\tint t ;\n\ti = size - 1 ;\n\taux02 = 0 - 1 ;\n\twhile (aux02 < i) {\n\t j = 1 ;\n\t //aux03 = i+1 ;\n\t while (j < (i+1)){\n\t\taux07 = j - 1 ;\n\t\taux04 = number[aux07] ;\n\t\taux05 = number[j] ;\n\t\tif (aux05 < aux04) {\n\t\t aux06 = j - 1 ;\n\t\t t = number[aux06] ;\n\t\t number[aux06] = number[j] ;\n\t\t number[j] = t;\n\t\t}\n\t\telse nt = 0 ;\n\t\tj = j + 1 ;\n\t }\n\t i = i - 1 ;\n\t}\n\treturn 0 ;\n }",
"public int Sort(){\n\tint nt ;\n\tint i ;\n\tint aux02 ;\n\tint aux04 ;\n\tint aux05 ;\n\tint aux06 ;\n\tint aux07 ;\n\tint j ;\n\tint t ;\n\ti = size - 1 ;\n\taux02 = 0 - 1 ;\n\twhile (aux02 < i) {\n\t j = 1 ;\n\t //aux03 = i+1 ;\n\t while (j < (i+1)){\n\t\taux07 = j - 1 ;\n\t\taux04 = number[aux07] ;\n\t\taux05 = number[j] ;\n\t\tif (aux05 < aux04) {\n\t\t aux06 = j - 1 ;\n\t\t t = number[aux06] ;\n\t\t number[aux06] = number[j] ;\n\t\t number[j] = t;\n\t\t}\n\t\telse nt = 0 ;\n\t\tj = j + 1 ;\n\t }\n\t i = i - 1 ;\n\t}\n\treturn 0 ;\n }",
"public int Sort(){\n\tint nt ;\n\tint i ;\n\tint aux02 ;\n\tint aux04 ;\n\tint aux05 ;\n\tint aux06 ;\n\tint aux07 ;\n\tint j ;\n\tint t ;\n\ti = size - 1 ;\n\taux02 = 0 - 1 ;\n\twhile (aux02 < i) {\n\t j = 1 ;\n\t //aux03 = i+1 ;\n\t while (j < (i+1)){\n\t\taux07 = j - 1 ;\n\t\taux04 = number[aux07] ;\n\t\taux05 = number[j] ;\n\t\tif (aux05 < aux04) {\n\t\t aux06 = j - 1 ;\n\t\t t = number[aux06] ;\n\t\t number[aux06] = number[j] ;\n\t\t number[j] = t;\n\t\t}\n\t\telse nt = 0 ;\n\t\tj = j + 1 ;\n\t }\n\t i = i - 1 ;\n\t}\n\treturn 0 ;\n }",
"public int Sort(){\n\tint nt ;\n\tint i ;\n\tint aux02 ;\n\tint aux04 ;\n\tint aux05 ;\n\tint aux06 ;\n\tint aux07 ;\n\tint j ;\n\tint t ;\n\ti = size - 1 ;\n\taux02 = 0 - 1 ;\n\twhile (aux02 < i) {\n\t j = 1 ;\n\t //aux03 = i+1 ;\n\t while (j < (i+1)){\n\t\taux07 = j - 1 ;\n\t\taux04 = number[aux07] ;\n\t\taux05 = number[j] ;\n\t\tif (aux05 < aux04) {\n\t\t aux06 = j - 1 ;\n\t\t t = number[aux06] ;\n\t\t number[aux06] = number[j] ;\n\t\t number[j] = t;\n\t\t}\n\t\telse nt = 0 ;\n\t\tj = j + 1 ;\n\t }\n\t i = i - 1 ;\n\t}\n\treturn 0 ;\n }",
"public int Sort(){\n\tint nt ;\n\tint i ;\n\tint aux02 ;\n\tint aux04 ;\n\tint aux05 ;\n\tint aux06 ;\n\tint aux07 ;\n\tint j ;\n\tint t ;\n\ti = size - 1 ;\n\taux02 = 0 - 1 ;\n\twhile (aux02 < i) {\n\t j = 1 ;\n\t //aux03 = i+1 ;\n\t while (j < (i+1)){\n\t\taux07 = j - 1 ;\n\t\taux04 = number[aux07] ;\n\t\taux05 = number[j] ;\n\t\tif (aux05 < aux04) {\n\t\t aux06 = j - 1 ;\n\t\t t = number[aux06] ;\n\t\t number[aux06] = number[j] ;\n\t\t number[j] = t;\n\t\t}\n\t\telse nt = 0 ;\n\t\tj = j + 1 ;\n\t }\n\t i = i - 1 ;\n\t}\n\treturn 0 ;\n }",
"public int Sort(){\n\tint nt ;\n\tint i ;\n\tint aux02 ;\n\tint aux04 ;\n\tint aux05 ;\n\tint aux06 ;\n\tint aux07 ;\n\tint j ;\n\tint t ;\n\ti = size - 1 ;\n\taux02 = 0 - 1 ;\n\twhile (aux02 < i) {\n\t j = 1 ;\n\t //aux03 = i+1 ;\n\t while (j < (i+1)){\n\t\taux07 = j - 1 ;\n\t\taux04 = number[aux07] ;\n\t\taux05 = number[j] ;\n\t\tif (aux05 < aux04) {\n\t\t aux06 = j - 1 ;\n\t\t t = number[aux06] ;\n\t\t number[aux06] = number[j] ;\n\t\t number[j] = t;\n\t\t}\n\t\telse nt = 0 ;\n\t\tj = j + 1 ;\n\t }\n\t i = i - 1 ;\n\t}\n\treturn 0 ;\n }",
"public int Sort(){\n\tint nt ;\n\tint i ;\n\tint aux02 ;\n\tint aux04 ;\n\tint aux05 ;\n\tint aux06 ;\n\tint aux07 ;\n\tint j ;\n\tint t ;\n\ti = size - 1 ;\n\taux02 = 0 - 1 ;\n\twhile (aux02 < i) {\n\t j = 1 ;\n\t //aux03 = i+1 ;\n\t while (j < (i+1)){\n\t\taux07 = j - 1 ;\n\t\taux04 = number[aux07] ;\n\t\taux05 = number[j] ;\n\t\tif (aux05 < aux04) {\n\t\t aux06 = j - 1 ;\n\t\t t = number[aux06] ;\n\t\t number[aux06] = number[j] ;\n\t\t number[j] = t;\n\t\t}\n\t\telse nt = 0 ;\n\t\tj = j + 1 ;\n\t }\n\t i = i - 1 ;\n\t}\n\treturn 0 ;\n }",
"public int Sort(){\n\tint nt ;\n\tint i ;\n\tint aux02 ;\n\tint aux04 ;\n\tint aux05 ;\n\tint aux06 ;\n\tint aux07 ;\n\tint j ;\n\tint t ;\n\ti = size - 1 ;\n\taux02 = 0 - 1 ;\n\twhile (aux02 < i) {\n\t j = 1 ;\n\t //aux03 = i+1 ;\n\t while (j < (i+1)){\n\t\taux07 = j - 1 ;\n\t\taux04 = number[aux07] ;\n\t\taux05 = number[j] ;\n\t\tif (aux05 < aux04) {\n\t\t aux06 = j - 1 ;\n\t\t t = number[aux06] ;\n\t\t number[aux06] = number[j] ;\n\t\t number[j] = t;\n\t\t}\n\t\telse nt = 0 ;\n\t\tj = j + 1 ;\n\t }\n\t i = i - 1 ;\n\t}\n\treturn 0 ;\n }",
"public int Sort(){\n\tint nt ;\n\tint i ;\n\tint aux02 ;\n\tint aux04 ;\n\tint aux05 ;\n\tint aux06 ;\n\tint aux07 ;\n\tint j ;\n\tint t ;\n\ti = size - 1 ;\n\taux02 = 0 - 1 ;\n\twhile (aux02 < i) {\n\t j = 1 ;\n\t //aux03 = i+1 ;\n\t while (j < (i+1)){\n\t\taux07 = j - 1 ;\n\t\taux04 = number[aux07] ;\n\t\taux05 = number[j] ;\n\t\tif (aux05 < aux04) {\n\t\t aux06 = j - 1 ;\n\t\t t = number[aux06] ;\n\t\t number[aux06] = number[j] ;\n\t\t number[j] = t;\n\t\t}\n\t\telse nt = 0 ;\n\t\tj = j + 1 ;\n\t }\n\t i = i - 1 ;\n\t}\n\treturn 0 ;\n }",
"public int Sort(){\n\tint nt ;\n\tint i ;\n\tint aux02 ;\n\tint aux04 ;\n\tint aux05 ;\n\tint aux06 ;\n\tint aux07 ;\n\tint j ;\n\tint t ;\n\ti = size - 1 ;\n\taux02 = 0 - 1 ;\n\twhile (aux02 < i) {\n\t j = 1 ;\n\t //aux03 = i+1 ;\n\t while (j < (i+1)){\n\t\taux07 = j - 1 ;\n\t\taux04 = number[aux07] ;\n\t\taux05 = number[j] ;\n\t\tif (aux05 < aux04) {\n\t\t aux06 = j - 1 ;\n\t\t t = number[aux06] ;\n\t\t number[aux06] = number[j] ;\n\t\t number[j] = t;\n\t\t}\n\t\telse nt = 0 ;\n\t\tj = j + 1 ;\n\t }\n\t i = i - 1 ;\n\t}\n\treturn 0 ;\n }",
"public int Sort(){\n\tint nt ;\n\tint i ;\n\tint aux02 ;\n\tint aux04 ;\n\tint aux05 ;\n\tint aux06 ;\n\tint aux07 ;\n\tint j ;\n\tint t ;\n\ti = size - 1 ;\n\taux02 = 0 - 1 ;\n\twhile (aux02 < i) {\n\t j = 1 ;\n\t //aux03 = i+1 ;\n\t while (j < (i+1)){\n\t\taux07 = j - 1 ;\n\t\taux04 = number[aux07] ;\n\t\taux05 = number[j] ;\n\t\tif (aux05 < aux04) {\n\t\t aux06 = j - 1 ;\n\t\t t = number[aux06] ;\n\t\t number[aux06] = number[j] ;\n\t\t number[j] = t;\n\t\t}\n\t\telse nt = 0 ;\n\t\tj = j + 1 ;\n\t }\n\t i = i - 1 ;\n\t}\n\treturn 0 ;\n }",
"public int Sort(){\n\tint nt ;\n\tint i ;\n\tint aux02 ;\n\tint aux04 ;\n\tint aux05 ;\n\tint aux06 ;\n\tint aux07 ;\n\tint j ;\n\tint t ;\n\ti = size - 1 ;\n\taux02 = 0 - 1 ;\n\twhile (aux02 < i) {\n\t j = 1 ;\n\t //aux03 = i+1 ;\n\t while (j < (i+1)){\n\t\taux07 = j - 1 ;\n\t\taux04 = number[aux07] ;\n\t\taux05 = number[j] ;\n\t\tif (aux05 < aux04) {\n\t\t aux06 = j - 1 ;\n\t\t t = number[aux06] ;\n\t\t number[aux06] = number[j] ;\n\t\t number[j] = t;\n\t\t}\n\t\telse nt = 0 ;\n\t\tj = j + 1 ;\n\t }\n\t i = i - 1 ;\n\t}\n\treturn 0 ;\n }",
"public int Sort(){\n\tint nt ;\n\tint i ;\n\tint aux02 ;\n\tint aux04 ;\n\tint aux05 ;\n\tint aux06 ;\n\tint aux07 ;\n\tint j ;\n\tint t ;\n\ti = size - 1 ;\n\taux02 = 0 - 1 ;\n\twhile (aux02 < i) {\n\t j = 1 ;\n\t //aux03 = i+1 ;\n\t while (j < (i+1)){\n\t\taux07 = j - 1 ;\n\t\taux04 = number[aux07] ;\n\t\taux05 = number[j] ;\n\t\tif (aux05 < aux04) {\n\t\t aux06 = j - 1 ;\n\t\t t = number[aux06] ;\n\t\t number[aux06] = number[j] ;\n\t\t number[j] = t;\n\t\t}\n\t\telse nt = 0 ;\n\t\tj = j + 1 ;\n\t }\n\t i = i - 1 ;\n\t}\n\treturn 0 ;\n }",
"public int Sort(){\n\tint nt ;\n\tint i ;\n\tint aux02 ;\n\tint aux04 ;\n\tint aux05 ;\n\tint aux06 ;\n\tint aux07 ;\n\tint j ;\n\tint t ;\n\ti = size - 1 ;\n\taux02 = 0 - 1 ;\n\twhile (aux02 < i) {\n\t j = 1 ;\n\t //aux03 = i+1 ;\n\t while (j < (i+1)){\n\t\taux07 = j - 1 ;\n\t\taux04 = number[aux07] ;\n\t\taux05 = number[j] ;\n\t\tif (aux05 < aux04) {\n\t\t aux06 = j - 1 ;\n\t\t t = number[aux06] ;\n\t\t number[aux06] = number[j] ;\n\t\t number[j] = t;\n\t\t}\n\t\telse nt = 0 ;\n\t\tj = j + 1 ;\n\t }\n\t i = i - 1 ;\n\t}\n\treturn 0 ;\n }",
"public int Sort(){\n\tint nt ;\n\tint i ;\n\tint aux02 ;\n\tint aux04 ;\n\tint aux05 ;\n\tint aux06 ;\n\tint aux07 ;\n\tint j ;\n\tint t ;\n\ti = size - 1 ;\n\taux02 = 0 - 1 ;\n\twhile (aux02 < i) {\n\t j = 1 ;\n\t //aux03 = i+1 ;\n\t while (j < (i+1)){\n\t\taux07 = j - 1 ;\n\t\taux04 = number[aux07] ;\n\t\taux05 = number[j] ;\n\t\tif (aux05 < aux04) {\n\t\t aux06 = j - 1 ;\n\t\t t = number[aux06] ;\n\t\t number[aux06] = number[j] ;\n\t\t number[j] = t;\n\t\t}\n\t\telse nt = 0 ;\n\t\tj = j + 1 ;\n\t }\n\t i = i - 1 ;\n\t}\n\treturn 0 ;\n }",
"public int Sort(){\n\tint nt ;\n\tint i ;\n\tint aux02 ;\n\tint aux04 ;\n\tint aux05 ;\n\tint aux06 ;\n\tint aux07 ;\n\tint j ;\n\tint t ;\n\ti = size - 1 ;\n\taux02 = 0 - 1 ;\n\twhile (aux02 < i) {\n\t j = 1 ;\n\t //aux03 = i+1 ;\n\t while (j < (i+1)){\n\t\taux07 = j - 1 ;\n\t\taux04 = number[aux07] ;\n\t\taux05 = number[j] ;\n\t\tif (aux05 < aux04) {\n\t\t aux06 = j - 1 ;\n\t\t t = number[aux06] ;\n\t\t number[aux06] = number[j] ;\n\t\t number[j] = t;\n\t\t}\n\t\telse nt = 0 ;\n\t\tj = j + 1 ;\n\t }\n\t i = i - 1 ;\n\t}\n\treturn 0 ;\n }",
"public int Sort(){\n\tint nt ;\n\tint i ;\n\tint aux02 ;\n\tint aux04 ;\n\tint aux05 ;\n\tint aux06 ;\n\tint aux07 ;\n\tint j ;\n\tint t ;\n\ti = size - 1 ;\n\taux02 = 0 - 1 ;\n\twhile (aux02 < i) {\n\t j = 1 ;\n\t //aux03 = i+1 ;\n\t while (j < (i+1)){\n\t\taux07 = j - 1 ;\n\t\taux04 = number[aux07] ;\n\t\taux05 = number[j] ;\n\t\tif (aux05 < aux04) {\n\t\t aux06 = j - 1 ;\n\t\t t = number[aux06] ;\n\t\t number[aux06] = number[j] ;\n\t\t number[j] = t;\n\t\t}\n\t\telse nt = 0 ;\n\t\tj = j + 1 ;\n\t }\n\t i = i - 1 ;\n\t}\n\treturn 0 ;\n }",
"public int Sort(){\n\tint nt ;\n\tint i ;\n\tint aux02 ;\n\tint aux04 ;\n\tint aux05 ;\n\tint aux06 ;\n\tint aux07 ;\n\tint j ;\n\tint t ;\n\ti = size - 1 ;\n\taux02 = 0 - 1 ;\n\twhile (aux02 < i) {\n\t j = 1 ;\n\t //aux03 = i+1 ;\n\t while (j < (i+1)){\n\t\taux07 = j - 1 ;\n\t\taux04 = number[aux07] ;\n\t\taux05 = number[j] ;\n\t\tif (aux05 < aux04) {\n\t\t aux06 = j - 1 ;\n\t\t t = number[aux06] ;\n\t\t number[aux06] = number[j] ;\n\t\t number[j] = t;\n\t\t}\n\t\telse nt = 0 ;\n\t\tj = j + 1 ;\n\t }\n\t i = i - 1 ;\n\t}\n\treturn 0 ;\n }",
"public int Sort(){\n\tint nt ;\n\tint i ;\n\tint aux02 ;\n\tint aux04 ;\n\tint aux05 ;\n\tint aux06 ;\n\tint aux07 ;\n\tint j ;\n\tint t ;\n\ti = size - 1 ;\n\taux02 = 0 - 1 ;\n\twhile (aux02 < i) {\n\t j = 1 ;\n\t //aux03 = i+1 ;\n\t while (j < (i+1)){\n\t\taux07 = j - 1 ;\n\t\taux04 = number[aux07] ;\n\t\taux05 = number[j] ;\n\t\tif (aux05 < aux04) {\n\t\t aux06 = j - 1 ;\n\t\t t = number[aux06] ;\n\t\t number[aux06] = number[j] ;\n\t\t number[j] = t;\n\t\t}\n\t\telse nt = 0 ;\n\t\tj = j + 1 ;\n\t }\n\t i = i - 1 ;\n\t}\n\treturn 0 ;\n }",
"public int Sort(){\n\tint nt ;\n\tint i ;\n\tint aux02 ;\n\tint aux04 ;\n\tint aux05 ;\n\tint aux06 ;\n\tint aux07 ;\n\tint j ;\n\tint t ;\n\ti = size - 1 ;\n\taux02 = 0 - 1 ;\n\twhile (aux02 < i) {\n\t j = 1 ;\n\t //aux03 = i+1 ;\n\t while (j < (i+1)){\n\t\taux07 = j - 1 ;\n\t\taux04 = number[aux07] ;\n\t\taux05 = number[j] ;\n\t\tif (aux05 < aux04) {\n\t\t aux06 = j - 1 ;\n\t\t t = number[aux06] ;\n\t\t number[aux06] = number[j] ;\n\t\t number[j] = t;\n\t\t}\n\t\telse nt = 0 ;\n\t\tj = j + 1 ;\n\t }\n\t i = i - 1 ;\n\t}\n\treturn 0 ;\n }",
"public int Sort(){\n\tint nt ;\n\tint i ;\n\tint aux02 ;\n\tint aux04 ;\n\tint aux05 ;\n\tint aux06 ;\n\tint aux07 ;\n\tint j ;\n\tint t ;\n\ti = size - 1 ;\n\taux02 = 0 - 1 ;\n\twhile (aux02 < i) {\n\t j = 1 ;\n\t //aux03 = i+1 ;\n\t while (j < (i+1)){\n\t\taux07 = j - 1 ;\n\t\taux04 = number[aux07] ;\n\t\taux05 = number[j] ;\n\t\tif (aux05 < aux04) {\n\t\t aux06 = j - 1 ;\n\t\t t = number[aux06] ;\n\t\t number[aux06] = number[j] ;\n\t\t number[j] = t;\n\t\t}\n\t\telse nt = 0 ;\n\t\tj = j + 1 ;\n\t }\n\t i = i - 1 ;\n\t}\n\treturn 0 ;\n }",
"public int Sort(){\n\tint nt ;\n\tint i ;\n\tint aux02 ;\n\tint aux04 ;\n\tint aux05 ;\n\tint aux06 ;\n\tint aux07 ;\n\tint j ;\n\tint t ;\n\ti = size - 1 ;\n\taux02 = 0 - 1 ;\n\twhile (aux02 < i) {\n\t j = 1 ;\n\t //aux03 = i+1 ;\n\t while (j < (i+1)){\n\t\taux07 = j - 1 ;\n\t\taux04 = number[aux07] ;\n\t\taux05 = number[j] ;\n\t\tif (aux05 < aux04) {\n\t\t aux06 = j - 1 ;\n\t\t t = number[aux06] ;\n\t\t number[aux06] = number[j] ;\n\t\t number[j] = t;\n\t\t}\n\t\telse nt = 0 ;\n\t\tj = j + 1 ;\n\t }\n\t i = i - 1 ;\n\t}\n\treturn 0 ;\n }",
"public int Sort(){\n\tint nt ;\n\tint i ;\n\tint aux02 ;\n\tint aux04 ;\n\tint aux05 ;\n\tint aux06 ;\n\tint aux07 ;\n\tint j ;\n\tint t ;\n\ti = size - 1 ;\n\taux02 = 0 - 1 ;\n\twhile (aux02 < i) {\n\t j = 1 ;\n\t //aux03 = i+1 ;\n\t while (j < (i+1)){\n\t\taux07 = j - 1 ;\n\t\taux04 = number[aux07] ;\n\t\taux05 = number[j] ;\n\t\tif (aux05 < aux04) {\n\t\t aux06 = j - 1 ;\n\t\t t = number[aux06] ;\n\t\t number[aux06] = number[j] ;\n\t\t number[j] = t;\n\t\t}\n\t\telse nt = 0 ;\n\t\tj = j + 1 ;\n\t }\n\t i = i - 1 ;\n\t}\n\treturn 0 ;\n }",
"public int Sort(){\n\tint nt ;\n\tint i ;\n\tint aux02 ;\n\tint aux04 ;\n\tint aux05 ;\n\tint aux06 ;\n\tint aux07 ;\n\tint j ;\n\tint t ;\n\ti = size - 1 ;\n\taux02 = 0 - 1 ;\n\twhile (aux02 < i) {\n\t j = 1 ;\n\t //aux03 = i+1 ;\n\t while (j < (i+1)){\n\t\taux07 = j - 1 ;\n\t\taux04 = number[aux07] ;\n\t\taux05 = number[j] ;\n\t\tif (aux05 < aux04) {\n\t\t aux06 = j - 1 ;\n\t\t t = number[aux06] ;\n\t\t number[aux06] = number[j] ;\n\t\t number[j] = t;\n\t\t}\n\t\telse nt = 0 ;\n\t\tj = j + 1 ;\n\t }\n\t i = i - 1 ;\n\t}\n\treturn 0 ;\n }",
"public int Sort(){\n\tint nt ;\n\tint i ;\n\tint aux02 ;\n\tint aux04 ;\n\tint aux05 ;\n\tint aux06 ;\n\tint aux07 ;\n\tint j ;\n\tint t ;\n\ti = size - 1 ;\n\taux02 = 0 - 1 ;\n\twhile (aux02 < i) {\n\t j = 1 ;\n\t //aux03 = i+1 ;\n\t while (j < (i+1)){\n\t\taux07 = j - 1 ;\n\t\taux04 = number[aux07] ;\n\t\taux05 = number[j] ;\n\t\tif (aux05 < aux04) {\n\t\t aux06 = j - 1 ;\n\t\t t = number[aux06] ;\n\t\t number[aux06] = number[j] ;\n\t\t number[j] = t;\n\t\t}\n\t\telse nt = 0 ;\n\t\tj = j + 1 ;\n\t }\n\t i = i - 1 ;\n\t}\n\treturn 0 ;\n }",
"public int Sort(){\n\tint nt ;\n\tint i ;\n\tint aux02 ;\n\tint aux04 ;\n\tint aux05 ;\n\tint aux06 ;\n\tint aux07 ;\n\tint j ;\n\tint t ;\n\ti = size - 1 ;\n\taux02 = 0 - 1 ;\n\twhile (aux02 < i) {\n\t j = 1 ;\n\t //aux03 = i+1 ;\n\t while (j < (i+1)){\n\t\taux07 = j - 1 ;\n\t\taux04 = number[aux07] ;\n\t\taux05 = number[j] ;\n\t\tif (aux05 < aux04) {\n\t\t aux06 = j - 1 ;\n\t\t t = number[aux06] ;\n\t\t number[aux06] = number[j] ;\n\t\t number[j] = t;\n\t\t}\n\t\telse nt = 0 ;\n\t\tj = j + 1 ;\n\t }\n\t i = i - 1 ;\n\t}\n\treturn 0 ;\n }",
"public int Sort(){\n\tint nt ;\n\tint i ;\n\tint aux02 ;\n\tint aux04 ;\n\tint aux05 ;\n\tint aux06 ;\n\tint aux07 ;\n\tint j ;\n\tint t ;\n\ti = size - 1 ;\n\taux02 = 0 - 1 ;\n\twhile (aux02 < i) {\n\t j = 1 ;\n\t //aux03 = i+1 ;\n\t while (j < (i+1)){\n\t\taux07 = j - 1 ;\n\t\taux04 = number[aux07] ;\n\t\taux05 = number[j] ;\n\t\tif (aux05 < aux04) {\n\t\t aux06 = j - 1 ;\n\t\t t = number[aux06] ;\n\t\t number[aux06] = number[j] ;\n\t\t number[j] = t;\n\t\t}\n\t\telse nt = 0 ;\n\t\tj = j + 1 ;\n\t }\n\t i = i - 1 ;\n\t}\n\treturn 0 ;\n }",
"public int Sort(){\n\tint nt ;\n\tint i ;\n\tint aux02 ;\n\tint aux04 ;\n\tint aux05 ;\n\tint aux06 ;\n\tint aux07 ;\n\tint j ;\n\tint t ;\n\ti = size - 1 ;\n\taux02 = 0 - 1 ;\n\twhile (aux02 < i) {\n\t j = 1 ;\n\t //aux03 = i+1 ;\n\t while (j < (i+1)){\n\t\taux07 = j - 1 ;\n\t\taux04 = number[aux07] ;\n\t\taux05 = number[j] ;\n\t\tif (aux05 < aux04) {\n\t\t aux06 = j - 1 ;\n\t\t t = number[aux06] ;\n\t\t number[aux06] = number[j] ;\n\t\t number[j] = t;\n\t\t}\n\t\telse nt = 0 ;\n\t\tj = j + 1 ;\n\t }\n\t i = i - 1 ;\n\t}\n\treturn 0 ;\n }",
"public int Sort(){\n\tint nt ;\n\tint i ;\n\tint aux02 ;\n\tint aux04 ;\n\tint aux05 ;\n\tint aux06 ;\n\tint aux07 ;\n\tint j ;\n\tint t ;\n\ti = size - 1 ;\n\taux02 = 0 - 1 ;\n\twhile (aux02 < i) {\n\t j = 1 ;\n\t //aux03 = i+1 ;\n\t while (j < (i+1)){\n\t\taux07 = j - 1 ;\n\t\taux04 = number[aux07] ;\n\t\taux05 = number[j] ;\n\t\tif (aux05 < aux04) {\n\t\t aux06 = j - 1 ;\n\t\t t = number[aux06] ;\n\t\t number[aux06] = number[j] ;\n\t\t number[j] = t;\n\t\t}\n\t\telse nt = 0 ;\n\t\tj = j + 1 ;\n\t }\n\t i = i - 1 ;\n\t}\n\treturn 0 ;\n }",
"public int Sort(){\n\tint nt ;\n\tint i ;\n\tint aux02 ;\n\tint aux04 ;\n\tint aux05 ;\n\tint aux06 ;\n\tint aux07 ;\n\tint j ;\n\tint t ;\n\ti = size - 1 ;\n\taux02 = 0 - 1 ;\n\twhile (aux02 < i) {\n\t j = 1 ;\n\t //aux03 = i+1 ;\n\t while (j < (i+1)){\n\t\taux07 = j - 1 ;\n\t\taux04 = number[aux07] ;\n\t\taux05 = number[j] ;\n\t\tif (aux05 < aux04) {\n\t\t aux06 = j - 1 ;\n\t\t t = number[aux06] ;\n\t\t number[aux06] = number[j] ;\n\t\t number[j] = t;\n\t\t}\n\t\telse nt = 0 ;\n\t\tj = j + 1 ;\n\t }\n\t i = i - 1 ;\n\t}\n\treturn 0 ;\n }",
"public int Sort(){\n\tint nt ;\n\tint i ;\n\tint aux02 ;\n\tint aux04 ;\n\tint aux05 ;\n\tint aux06 ;\n\tint aux07 ;\n\tint j ;\n\tint t ;\n\ti = size - 1 ;\n\taux02 = 0 - 1 ;\n\twhile (aux02 < i) {\n\t j = 1 ;\n\t //aux03 = i+1 ;\n\t while (j < (i+1)){\n\t\taux07 = j - 1 ;\n\t\taux04 = number[aux07] ;\n\t\taux05 = number[j] ;\n\t\tif (aux05 < aux04) {\n\t\t aux06 = j - 1 ;\n\t\t t = number[aux06] ;\n\t\t number[aux06] = number[j] ;\n\t\t number[j] = t;\n\t\t}\n\t\telse nt = 0 ;\n\t\tj = j + 1 ;\n\t }\n\t i = i - 1 ;\n\t}\n\treturn 0 ;\n }",
"public int Sort(){\n\tint nt ;\n\tint i ;\n\tint aux02 ;\n\tint aux04 ;\n\tint aux05 ;\n\tint aux06 ;\n\tint aux07 ;\n\tint j ;\n\tint t ;\n\ti = size - 1 ;\n\taux02 = 0 - 1 ;\n\twhile (aux02 < i) {\n\t j = 1 ;\n\t //aux03 = i+1 ;\n\t while (j < (i+1)){\n\t\taux07 = j - 1 ;\n\t\taux04 = number[aux07] ;\n\t\taux05 = number[j] ;\n\t\tif (aux05 < aux04) {\n\t\t aux06 = j - 1 ;\n\t\t t = number[aux06] ;\n\t\t number[aux06] = number[j] ;\n\t\t number[j] = t;\n\t\t}\n\t\telse nt = 0 ;\n\t\tj = j + 1 ;\n\t }\n\t i = i - 1 ;\n\t}\n\treturn 0 ;\n }",
"public int Sort(){\n\tint nt ;\n\tint i ;\n\tint aux02 ;\n\tint aux04 ;\n\tint aux05 ;\n\tint aux06 ;\n\tint aux07 ;\n\tint j ;\n\tint t ;\n\ti = size - 1 ;\n\taux02 = 0 - 1 ;\n\twhile (aux02 < i) {\n\t j = 1 ;\n\t //aux03 = i+1 ;\n\t while (j < (i+1)){\n\t\taux07 = j - 1 ;\n\t\taux04 = number[aux07] ;\n\t\taux05 = number[j] ;\n\t\tif (aux05 < aux04) {\n\t\t aux06 = j - 1 ;\n\t\t t = number[aux06] ;\n\t\t number[aux06] = number[j] ;\n\t\t number[j] = t;\n\t\t}\n\t\telse nt = 0 ;\n\t\tj = j + 1 ;\n\t }\n\t i = i - 1 ;\n\t}\n\treturn 0 ;\n }",
"public int Sort(){\n\tint nt ;\n\tint i ;\n\tint aux02 ;\n\tint aux04 ;\n\tint aux05 ;\n\tint aux06 ;\n\tint aux07 ;\n\tint j ;\n\tint t ;\n\ti = size - 1 ;\n\taux02 = 0 - 1 ;\n\twhile (aux02 < i) {\n\t j = 1 ;\n\t //aux03 = i+1 ;\n\t while (j < (i+1)){\n\t\taux07 = j - 1 ;\n\t\taux04 = number[aux07] ;\n\t\taux05 = number[j] ;\n\t\tif (aux05 < aux04) {\n\t\t aux06 = j - 1 ;\n\t\t t = number[aux06] ;\n\t\t number[aux06] = number[j] ;\n\t\t number[j] = t;\n\t\t}\n\t\telse nt = 0 ;\n\t\tj = j + 1 ;\n\t }\n\t i = i - 1 ;\n\t}\n\treturn 0 ;\n }",
"public int Sort(){\n\tint nt ;\n\tint i ;\n\tint aux02 ;\n\tint aux04 ;\n\tint aux05 ;\n\tint aux06 ;\n\tint aux07 ;\n\tint j ;\n\tint t ;\n\ti = size - 1 ;\n\taux02 = 0 - 1 ;\n\twhile (aux02 < i) {\n\t j = 1 ;\n\t //aux03 = i+1 ;\n\t while (j < (i+1)){\n\t\taux07 = j - 1 ;\n\t\taux04 = number[aux07] ;\n\t\taux05 = number[j] ;\n\t\tif (aux05 < aux04) {\n\t\t aux06 = j - 1 ;\n\t\t t = number[aux06] ;\n\t\t number[aux06] = number[j] ;\n\t\t number[j] = t;\n\t\t}\n\t\telse nt = 0 ;\n\t\tj = j + 1 ;\n\t }\n\t i = i - 1 ;\n\t}\n\treturn 0 ;\n }",
"public int Sort(){\n\tint nt ;\n\tint i ;\n\tint aux02 ;\n\tint aux04 ;\n\tint aux05 ;\n\tint aux06 ;\n\tint aux07 ;\n\tint j ;\n\tint t ;\n\ti = size - 1 ;\n\taux02 = 0 - 1 ;\n\twhile (aux02 < i) {\n\t j = 1 ;\n\t //aux03 = i+1 ;\n\t while (j < (i+1)){\n\t\taux07 = j - 1 ;\n\t\taux04 = number[aux07] ;\n\t\taux05 = number[j] ;\n\t\tif (aux05 < aux04) {\n\t\t aux06 = j - 1 ;\n\t\t t = number[aux06] ;\n\t\t number[aux06] = number[j] ;\n\t\t number[j] = t;\n\t\t}\n\t\telse nt = 0 ;\n\t\tj = j + 1 ;\n\t }\n\t i = i - 1 ;\n\t}\n\treturn 0 ;\n }",
"public int Sort(){\n\tint nt ;\n\tint i ;\n\tint aux02 ;\n\tint aux04 ;\n\tint aux05 ;\n\tint aux06 ;\n\tint aux07 ;\n\tint j ;\n\tint t ;\n\ti = size - 1 ;\n\taux02 = 0 - 1 ;\n\twhile (aux02 < i) {\n\t j = 1 ;\n\t //aux03 = i+1 ;\n\t while (j < (i+1)){\n\t\taux07 = j - 1 ;\n\t\taux04 = number[aux07] ;\n\t\taux05 = number[j] ;\n\t\tif (aux05 < aux04) {\n\t\t aux06 = j - 1 ;\n\t\t t = number[aux06] ;\n\t\t number[aux06] = number[j] ;\n\t\t number[j] = t;\n\t\t}\n\t\telse nt = 0 ;\n\t\tj = j + 1 ;\n\t }\n\t i = i - 1 ;\n\t}\n\treturn 0 ;\n }",
"public int Sort(){\n\tint nt ;\n\tint i ;\n\tint aux02 ;\n\tint aux04 ;\n\tint aux05 ;\n\tint aux06 ;\n\tint aux07 ;\n\tint j ;\n\tint t ;\n\ti = size - 1 ;\n\taux02 = 0 - 1 ;\n\twhile (aux02 < i) {\n\t j = 1 ;\n\t //aux03 = i+1 ;\n\t while (j < (i+1)){\n\t\taux07 = j - 1 ;\n\t\taux04 = number[aux07] ;\n\t\taux05 = number[j] ;\n\t\tif (aux05 < aux04) {\n\t\t aux06 = j - 1 ;\n\t\t t = number[aux06] ;\n\t\t number[aux06] = number[j] ;\n\t\t number[j] = t;\n\t\t}\n\t\telse nt = 0 ;\n\t\tj = j + 1 ;\n\t }\n\t i = i - 1 ;\n\t}\n\treturn 0 ;\n }",
"public int Sort(){\n\tint nt ;\n\tint i ;\n\tint aux02 ;\n\tint aux04 ;\n\tint aux05 ;\n\tint aux06 ;\n\tint aux07 ;\n\tint j ;\n\tint t ;\n\ti = size - 1 ;\n\taux02 = 0 - 1 ;\n\twhile (aux02 < i) {\n\t j = 1 ;\n\t //aux03 = i+1 ;\n\t while (j < (i+1)){\n\t\taux07 = j - 1 ;\n\t\taux04 = number[aux07] ;\n\t\taux05 = number[j] ;\n\t\tif (aux05 < aux04) {\n\t\t aux06 = j - 1 ;\n\t\t t = number[aux06] ;\n\t\t number[aux06] = number[j] ;\n\t\t number[j] = t;\n\t\t}\n\t\telse nt = 0 ;\n\t\tj = j + 1 ;\n\t }\n\t i = i - 1 ;\n\t}\n\treturn 0 ;\n }",
"public int Sort(){\n\tint nt ;\n\tint i ;\n\tint aux02 ;\n\tint aux04 ;\n\tint aux05 ;\n\tint aux06 ;\n\tint aux07 ;\n\tint j ;\n\tint t ;\n\ti = size - 1 ;\n\taux02 = 0 - 1 ;\n\twhile (aux02 < i) {\n\t j = 1 ;\n\t //aux03 = i+1 ;\n\t while (j < (i+1)){\n\t\taux07 = j - 1 ;\n\t\taux04 = number[aux07] ;\n\t\taux05 = number[j] ;\n\t\tif (aux05 < aux04) {\n\t\t aux06 = j - 1 ;\n\t\t t = number[aux06] ;\n\t\t number[aux06] = number[j] ;\n\t\t number[j] = t;\n\t\t}\n\t\telse nt = 0 ;\n\t\tj = j + 1 ;\n\t }\n\t i = i - 1 ;\n\t}\n\treturn 0 ;\n }",
"public int Sort(){\n\tint nt ;\n\tint i ;\n\tint aux02 ;\n\tint aux04 ;\n\tint aux05 ;\n\tint aux06 ;\n\tint aux07 ;\n\tint j ;\n\tint t ;\n\ti = size - 1 ;\n\taux02 = 0 - 1 ;\n\twhile (aux02 < i) {\n\t j = 1 ;\n\t //aux03 = i+1 ;\n\t while (j < (i+1)){\n\t\taux07 = j - 1 ;\n\t\taux04 = number[aux07] ;\n\t\taux05 = number[j] ;\n\t\tif (aux05 < aux04) {\n\t\t aux06 = j - 1 ;\n\t\t t = number[aux06] ;\n\t\t number[aux06] = number[j] ;\n\t\t number[j] = t;\n\t\t}\n\t\telse nt = 0 ;\n\t\tj = j + 1 ;\n\t }\n\t i = i - 1 ;\n\t}\n\treturn 0 ;\n }",
"public int Sort(){\n\tint nt ;\n\tint i ;\n\tint aux02 ;\n\tint aux04 ;\n\tint aux05 ;\n\tint aux06 ;\n\tint aux07 ;\n\tint j ;\n\tint t ;\n\ti = size - 1 ;\n\taux02 = 0 - 1 ;\n\twhile (aux02 < i) {\n\t j = 1 ;\n\t //aux03 = i+1 ;\n\t while (j < (i+1)){\n\t\taux07 = j - 1 ;\n\t\taux04 = number[aux07] ;\n\t\taux05 = number[j] ;\n\t\tif (aux05 < aux04) {\n\t\t aux06 = j - 1 ;\n\t\t t = number[aux06] ;\n\t\t number[aux06] = number[j] ;\n\t\t number[j] = t;\n\t\t}\n\t\telse nt = 0 ;\n\t\tj = j + 1 ;\n\t }\n\t i = i - 1 ;\n\t}\n\treturn 0 ;\n }",
"public int Sort(){\n\tint nt ;\n\tint i ;\n\tint aux02 ;\n\tint aux04 ;\n\tint aux05 ;\n\tint aux06 ;\n\tint aux07 ;\n\tint j ;\n\tint t ;\n\ti = size - 1 ;\n\taux02 = 0 - 1 ;\n\twhile (aux02 < i) {\n\t j = 1 ;\n\t //aux03 = i+1 ;\n\t while (j < (i+1)){\n\t\taux07 = j - 1 ;\n\t\taux04 = number[aux07] ;\n\t\taux05 = number[j] ;\n\t\tif (aux05 < aux04) {\n\t\t aux06 = j - 1 ;\n\t\t t = number[aux06] ;\n\t\t number[aux06] = number[j] ;\n\t\t number[j] = t;\n\t\t}\n\t\telse nt = 0 ;\n\t\tj = j + 1 ;\n\t }\n\t i = i - 1 ;\n\t}\n\treturn 0 ;\n }",
"public int Sort(){\n\tint nt ;\n\tint i ;\n\tint aux02 ;\n\tint aux04 ;\n\tint aux05 ;\n\tint aux06 ;\n\tint aux07 ;\n\tint j ;\n\tint t ;\n\ti = size - 1 ;\n\taux02 = 0 - 1 ;\n\twhile (aux02 < i) {\n\t j = 1 ;\n\t //aux03 = i+1 ;\n\t while (j < (i+1)){\n\t\taux07 = j - 1 ;\n\t\taux04 = number[aux07] ;\n\t\taux05 = number[j] ;\n\t\tif (aux05 < aux04) {\n\t\t aux06 = j - 1 ;\n\t\t t = number[aux06] ;\n\t\t number[aux06] = number[j] ;\n\t\t number[j] = t;\n\t\t}\n\t\telse nt = 0 ;\n\t\tj = j + 1 ;\n\t }\n\t i = i - 1 ;\n\t}\n\treturn 0 ;\n }",
"public int Sort(){\n\tint nt ;\n\tint i ;\n\tint aux02 ;\n\tint aux04 ;\n\tint aux05 ;\n\tint aux06 ;\n\tint aux07 ;\n\tint j ;\n\tint t ;\n\ti = size - 1 ;\n\taux02 = 0 - 1 ;\n\twhile (aux02 < i) {\n\t j = 1 ;\n\t //aux03 = i+1 ;\n\t while (j < (i+1)){\n\t\taux07 = j - 1 ;\n\t\taux04 = number[aux07] ;\n\t\taux05 = number[j] ;\n\t\tif (aux05 < aux04) {\n\t\t aux06 = j - 1 ;\n\t\t t = number[aux06] ;\n\t\t number[aux06] = number[j] ;\n\t\t number[j] = t;\n\t\t}\n\t\telse nt = 0 ;\n\t\tj = j + 1 ;\n\t }\n\t i = i - 1 ;\n\t}\n\treturn 0 ;\n }"
] | [
"0.8502051",
"0.80668855",
"0.79969376",
"0.79287434",
"0.7922089",
"0.7895034",
"0.7540494",
"0.7522113",
"0.7391203",
"0.73540545",
"0.73500115",
"0.7308975",
"0.7308961",
"0.7224032",
"0.70162094",
"0.6983251",
"0.6934876",
"0.69217193",
"0.6918608",
"0.6916648",
"0.6915501",
"0.6904947",
"0.6878394",
"0.6870643",
"0.68691254",
"0.6846196",
"0.6832771",
"0.68187565",
"0.6805044",
"0.6779304",
"0.67678446",
"0.67674786",
"0.6750425",
"0.67501754",
"0.67154056",
"0.6703397",
"0.66995394",
"0.6697657",
"0.66758555",
"0.6654169",
"0.66446304",
"0.66428244",
"0.66186607",
"0.65894467",
"0.65894467",
"0.65894467",
"0.65894467",
"0.65894467",
"0.65894467",
"0.65894467",
"0.65894467",
"0.65894467",
"0.65894467",
"0.65894467",
"0.65894467",
"0.65894467",
"0.65894467",
"0.65894467",
"0.65894467",
"0.65894467",
"0.65894467",
"0.65894467",
"0.65894467",
"0.65894467",
"0.65894467",
"0.65894467",
"0.65894467",
"0.65894467",
"0.6589219",
"0.6589219",
"0.6589219",
"0.6589219",
"0.6589219",
"0.6589219",
"0.6589219",
"0.6589219",
"0.6589219",
"0.6589219",
"0.6589219",
"0.6589219",
"0.6589219",
"0.6589219",
"0.6589219",
"0.6589219",
"0.6589219",
"0.6589219",
"0.6589219",
"0.6589219",
"0.6589219",
"0.6589219",
"0.6589219",
"0.6589219",
"0.6589219",
"0.6589219",
"0.6589219",
"0.6589219",
"0.6589219",
"0.6589219",
"0.6589219",
"0.6589219"
] | 0.7657354 | 6 |
dot represents anything, i.e., IRI, xsd:string, etc. | public String toShEx() {
return String.format("<%s> .{%s, %s} ,", properties.get(0), minBound, maxBound);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public final void dot() throws RecognitionException {\r\n try {\r\n // D:\\\\entornotrabajo\\\\workspace-sgo\\\\persistance\\\\src\\\\main\\\\java\\\\es\\\\caser\\\\persistance\\\\sql\\\\antlr\\\\SQLGrammar.g:171:1: ( ( DOT ) )\r\n // D:\\\\entornotrabajo\\\\workspace-sgo\\\\persistance\\\\src\\\\main\\\\java\\\\es\\\\caser\\\\persistance\\\\sql\\\\antlr\\\\SQLGrammar.g:171:3: ( DOT )\r\n {\r\n // D:\\\\entornotrabajo\\\\workspace-sgo\\\\persistance\\\\src\\\\main\\\\java\\\\es\\\\caser\\\\persistance\\\\sql\\\\antlr\\\\SQLGrammar.g:171:3: ( DOT )\r\n // D:\\\\entornotrabajo\\\\workspace-sgo\\\\persistance\\\\src\\\\main\\\\java\\\\es\\\\caser\\\\persistance\\\\sql\\\\antlr\\\\SQLGrammar.g:171:4: DOT\r\n {\r\n match(input,DOT,FOLLOW_DOT_in_dot1002); \r\n out(\".\");\r\n\r\n }\r\n\r\n\r\n }\r\n\r\n }\r\n finally {\r\n }\r\n return ;\r\n }",
"abstract String toDot();",
"public final void mDOT() throws RecognitionException {\n try {\n int _type = DOT;\n int _channel = DEFAULT_TOKEN_CHANNEL;\n // C:\\\\Documents and Settings\\\\D043530\\\\runtime-workspace\\\\com.sap.ap.cts.editor\\\\generated\\\\generated\\\\Binding.g:2781:3: ( '.' )\n // C:\\\\Documents and Settings\\\\D043530\\\\runtime-workspace\\\\com.sap.ap.cts.editor\\\\generated\\\\generated\\\\Binding.g:2782:3: '.'\n {\n match('.'); if (state.failed) return ;\n\n }\n\n state.type = _type;\n state.channel = _channel;\n }\n finally {\n }\n }",
"public boolean supportsEightDot();",
"public final void mDOT() throws RecognitionException {\n\t\ttry {\n\t\t\tint _type = DOT;\n\t\t\tint _channel = DEFAULT_TOKEN_CHANNEL;\n\t\t\t// /Users/Sarah/Projects/ontop/obdalib-core/src/main/java/it/unibz/krdb/obda/parser/Datalog.g:415:4: ( '.' )\n\t\t\t// /Users/Sarah/Projects/ontop/obdalib-core/src/main/java/it/unibz/krdb/obda/parser/Datalog.g:415:16: '.'\n\t\t\t{\n\t\t\tmatch('.'); \n\t\t\t}\n\n\t\t\tstate.type = _type;\n\t\t\tstate.channel = _channel;\n\t\t}\n\t\tfinally {\n\t\t\t// do for sure before leaving\n\t\t}\n\t}",
"public static String ConvertExtension(String s,String dot) {\n\t\tif(!s.contains(dot)) {\n\t\t\treturn s+dot;\n\t\t}\n\t\treturn s;\n\t}",
"public final void mDOT() throws RecognitionException {\n try {\n int _type = DOT;\n int _channel = DEFAULT_TOKEN_CHANNEL;\n // /Users/dannluciano/Sources/MyLanguage/expr.g:177:5: ( '.' )\n // /Users/dannluciano/Sources/MyLanguage/expr.g:177:7: '.'\n {\n match('.'); \n\n }\n\n state.type = _type;\n state.channel = _channel;\n }\n finally {\n }\n }",
"public final void testOverdot() \n\t\t\tthrows ParserConfigurationException, IOException, SAXException \n\t{\n\t\tassertSingleResult(\"10\", fldName, \"pridėtos\");\n\t\tassertSingleResult(\"10\", fldName, \"pridetos\");\n\t}",
"public final void mDOT() throws RecognitionException {\n try {\n int _type = DOT;\n int _channel = DEFAULT_TOKEN_CHANNEL;\n // /Users/cbinnig/Workspace/DHBW_FirstDB_Loesung3/src/de/dhbw/db2/firstdb/sql/FirstSQL.g:31:5: ( '.' )\n // /Users/cbinnig/Workspace/DHBW_FirstDB_Loesung3/src/de/dhbw/db2/firstdb/sql/FirstSQL.g:31:7: '.'\n {\n match('.'); \n\n }\n\n state.type = _type;\n state.channel = _channel;\n }\n finally {\n }\n }",
"private final String stripDot(XMLElement e) {\n\t\tif ( e.getName().indexOf(\".\") == -1 ) {\n\t\t\treturn e.getName();\n\t\t}\n\t\tString value = e.getName().substring(e.getName().indexOf(\".\") + 1);\n\t\treturn value;\n\t}",
"public String parseDotPathWord( String t )\n {\n StringBuilder sb = t == null ? null : new StringBuilder( t == null ? \"\" : t );\n SourceCodeTokenizer tokenizer = getTokenizer();\n while( match( null, '.' ) )\n {\n if( sb != null )\n {\n sb.append( '.' );\n }\n int mark = tokenizer.mark();\n if( match( null, null, SourceCodeTokenizer.TT_WORD ) || match( null, null, SourceCodeTokenizer.TT_KEYWORD ) )\n {\n if( sb != null )\n {\n sb.append( tokenizer.getTokenAt( mark ).getStringValue() );\n }\n }\n }\n if( sb != null )\n {\n t = sb.toString();\n }\n return t;\n }",
"@Test\r\n\tpublic void testDotDot() throws Exception {\r\n\t\tfinal String module = \"-------------- MODULE Testing ----------------\\n\"\r\n\t\t\t\t+ \"EXTENDS Naturals \\n\"\r\n\t\t\t\t+ \"ASSUME 1 \\\\in 1 .. 2 \\n\"\r\n\t\t\t\t+ \"=================================\";\r\n\t\tStringBuilder sb = TestUtil.translateString(module);\r\n\t\tfinal String expected = \"MACHINE Testing\\n\"\r\n\t\t\t\t+ \"PROPERTIES 1 : 1..2 \\n\"\r\n\t\t\t\t+ \"END\";\r\n\t\tassertEquals(TestUtil.getTreeAsString(expected), TestUtil.getTreeAsString(sb.toString()));\r\n\t}",
"public Dot() {\n super(SOME, NONE); // a deliberate lie\n }",
"public Rule incDotCall()\n \t{\n \t\treturn DOT;\n \t}",
"private boolean isDotAllowed()\r\n\t{\r\n\t\t//if the previous character is a dot then the dot is not allowed.\r\n\t\tif(isPreCharDot())\r\n\t\t\treturn false;\r\n\t\t//if the previous character is a evaluation symbol then the dot is allowed.\r\n\t\tif(isPreEvalSymobl())\r\n\t\t\treturn true;\r\n\t\t//if the last number has a dot then another dot is not allowed.\r\n\t\tString lastNum = getLastNumber(expression);\r\n\t\tif(lastNum.contains(\".\"))\r\n\t\t\treturn false;\r\n\t\treturn true;\r\n\t}",
"public String setDot() {\r\n\t\tif (getOperand().length() == Config.MAX_SIZE) {\r\n\t\t\treturn getOperand().toString();\r\n\t\t}\r\n\r\n\t\tif (getOperand().length() == 0) {\r\n\t\t\treturn \"0\";\r\n\t\t}\r\n\r\n\t\tif (getOperand().indexOf(\".\") == -1) {\r\n\t\t\tgetOperand().append(\".\");\r\n\t\t}\r\n\r\n\t\treturn getOperand().toString();\r\n\t}",
"public final PythonParser.dotted_name_return dotted_name() throws RecognitionException {\n PythonParser.dotted_name_return retval = new PythonParser.dotted_name_return();\n retval.start = input.LT(1);\n\n PythonTree root_0 = null;\n\n Token NAME119=null;\n Token DOT120=null;\n List list_dn=null;\n PythonParser.attr_return dn = null;\n dn = null;\n PythonTree NAME119_tree=null;\n PythonTree DOT120_tree=null;\n\n try {\n // /run/media/abhi/0cc7e6ad-008e-43cd-b47d-f3ed6f127f92/home/abhi/dacapo-9.12-bach-src (2)/benchmarks/bms/jython/build/grammar/Python.g:842:5: ( NAME ( DOT dn+= attr )* )\n // /run/media/abhi/0cc7e6ad-008e-43cd-b47d-f3ed6f127f92/home/abhi/dacapo-9.12-bach-src (2)/benchmarks/bms/jython/build/grammar/Python.g:842:7: NAME ( DOT dn+= attr )*\n {\n root_0 = (PythonTree)adaptor.nil();\n\n NAME119=(Token)match(input,NAME,FOLLOW_NAME_in_dotted_name3232); if (state.failed) return retval;\n if ( state.backtracking==0 ) {\n NAME119_tree = (PythonTree)adaptor.create(NAME119);\n adaptor.addChild(root_0, NAME119_tree);\n }\n // /run/media/abhi/0cc7e6ad-008e-43cd-b47d-f3ed6f127f92/home/abhi/dacapo-9.12-bach-src (2)/benchmarks/bms/jython/build/grammar/Python.g:842:12: ( DOT dn+= attr )*\n loop58:\n do {\n int alt58=2;\n int LA58_0 = input.LA(1);\n\n if ( (LA58_0==DOT) ) {\n alt58=1;\n }\n\n\n switch (alt58) {\n \tcase 1 :\n \t // /run/media/abhi/0cc7e6ad-008e-43cd-b47d-f3ed6f127f92/home/abhi/dacapo-9.12-bach-src (2)/benchmarks/bms/jython/build/grammar/Python.g:842:13: DOT dn+= attr\n \t {\n \t DOT120=(Token)match(input,DOT,FOLLOW_DOT_in_dotted_name3235); if (state.failed) return retval;\n \t if ( state.backtracking==0 ) {\n \t DOT120_tree = (PythonTree)adaptor.create(DOT120);\n \t adaptor.addChild(root_0, DOT120_tree);\n \t }\n \t pushFollow(FOLLOW_attr_in_dotted_name3239);\n \t dn=attr();\n\n \t state._fsp--;\n \t if (state.failed) return retval;\n \t if ( state.backtracking==0 ) adaptor.addChild(root_0, dn.getTree());\n \t if (list_dn==null) list_dn=new ArrayList();\n \t list_dn.add(dn.getTree());\n\n\n \t }\n \t break;\n\n \tdefault :\n \t break loop58;\n }\n } while (true);\n\n if ( state.backtracking==0 ) {\n\n retval.name = actions.makeDottedText(NAME119, list_dn);\n \n }\n\n }\n\n retval.stop = input.LT(-1);\n\n if ( state.backtracking==0 ) {\n\n retval.tree = (PythonTree)adaptor.rulePostProcessing(root_0);\n adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop);\n }\n }\n\n catch (RecognitionException re) {\n errorHandler.reportError(this, re);\n errorHandler.recover(this, input,re);\n retval.tree = (PythonTree)adaptor.errorNode(input, retval.start, input.LT(-1), re);\n }\n finally {\n }\n return retval;\n }",
"public static String getDotUrl()\n {\n return \"http://log.tusumobi.com/dot\";\n }",
"@Override public String toDot() {\r\n return value.toDot(); \r\n }",
"public final PythonParser.dotted_attr_return dotted_attr() throws RecognitionException {\n PythonParser.dotted_attr_return retval = new PythonParser.dotted_attr_return();\n retval.start = input.LT(1);\n\n PythonTree root_0 = null;\n\n Token n1=null;\n Token DOT17=null;\n Token n2=null;\n List list_n2=null;\n\n PythonTree n1_tree=null;\n PythonTree DOT17_tree=null;\n PythonTree n2_tree=null;\n\n try {\n // /run/media/abhi/0cc7e6ad-008e-43cd-b47d-f3ed6f127f92/home/abhi/dacapo-9.12-bach-src (2)/benchmarks/bms/jython/build/grammar/Python.g:361:5: (n1= NAME ( ( DOT n2+= NAME )+ | ) )\n // /run/media/abhi/0cc7e6ad-008e-43cd-b47d-f3ed6f127f92/home/abhi/dacapo-9.12-bach-src (2)/benchmarks/bms/jython/build/grammar/Python.g:361:7: n1= NAME ( ( DOT n2+= NAME )+ | )\n {\n root_0 = (PythonTree)adaptor.nil();\n\n n1=(Token)match(input,NAME,FOLLOW_NAME_in_dotted_attr364); if (state.failed) return retval;\n if ( state.backtracking==0 ) {\n n1_tree = (PythonTree)adaptor.create(n1);\n adaptor.addChild(root_0, n1_tree);\n }\n // /run/media/abhi/0cc7e6ad-008e-43cd-b47d-f3ed6f127f92/home/abhi/dacapo-9.12-bach-src (2)/benchmarks/bms/jython/build/grammar/Python.g:362:7: ( ( DOT n2+= NAME )+ | )\n int alt10=2;\n int LA10_0 = input.LA(1);\n\n if ( (LA10_0==DOT) ) {\n alt10=1;\n }\n else if ( (LA10_0==NEWLINE||LA10_0==LPAREN) ) {\n alt10=2;\n }\n else {\n if (state.backtracking>0) {state.failed=true; return retval;}\n NoViableAltException nvae =\n new NoViableAltException(\"\", 10, 0, input);\n\n throw nvae;\n }\n switch (alt10) {\n case 1 :\n // /run/media/abhi/0cc7e6ad-008e-43cd-b47d-f3ed6f127f92/home/abhi/dacapo-9.12-bach-src (2)/benchmarks/bms/jython/build/grammar/Python.g:362:9: ( DOT n2+= NAME )+\n {\n // /run/media/abhi/0cc7e6ad-008e-43cd-b47d-f3ed6f127f92/home/abhi/dacapo-9.12-bach-src (2)/benchmarks/bms/jython/build/grammar/Python.g:362:9: ( DOT n2+= NAME )+\n int cnt9=0;\n loop9:\n do {\n int alt9=2;\n int LA9_0 = input.LA(1);\n\n if ( (LA9_0==DOT) ) {\n alt9=1;\n }\n\n\n switch (alt9) {\n \tcase 1 :\n \t // /run/media/abhi/0cc7e6ad-008e-43cd-b47d-f3ed6f127f92/home/abhi/dacapo-9.12-bach-src (2)/benchmarks/bms/jython/build/grammar/Python.g:362:10: DOT n2+= NAME\n \t {\n \t DOT17=(Token)match(input,DOT,FOLLOW_DOT_in_dotted_attr375); if (state.failed) return retval;\n \t if ( state.backtracking==0 ) {\n \t DOT17_tree = (PythonTree)adaptor.create(DOT17);\n \t adaptor.addChild(root_0, DOT17_tree);\n \t }\n \t n2=(Token)match(input,NAME,FOLLOW_NAME_in_dotted_attr379); if (state.failed) return retval;\n \t if ( state.backtracking==0 ) {\n \t n2_tree = (PythonTree)adaptor.create(n2);\n \t adaptor.addChild(root_0, n2_tree);\n \t }\n \t if (list_n2==null) list_n2=new ArrayList();\n \t list_n2.add(n2);\n\n\n \t }\n \t break;\n\n \tdefault :\n \t if ( cnt9 >= 1 ) break loop9;\n \t if (state.backtracking>0) {state.failed=true; return retval;}\n EarlyExitException eee =\n new EarlyExitException(9, input);\n throw eee;\n }\n cnt9++;\n } while (true);\n\n if ( state.backtracking==0 ) {\n\n retval.etype = actions.makeDottedAttr(n1, list_n2);\n \n }\n\n }\n break;\n case 2 :\n // /run/media/abhi/0cc7e6ad-008e-43cd-b47d-f3ed6f127f92/home/abhi/dacapo-9.12-bach-src (2)/benchmarks/bms/jython/build/grammar/Python.g:367:9: \n {\n if ( state.backtracking==0 ) {\n\n retval.etype = new Name(n1, (n1!=null?n1.getText():null), expr_contextType.Load);\n \n }\n\n }\n break;\n\n }\n\n\n }\n\n retval.stop = input.LT(-1);\n\n if ( state.backtracking==0 ) {\n\n retval.tree = (PythonTree)adaptor.rulePostProcessing(root_0);\n adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop);\n }\n }\n\n catch (RecognitionException re) {\n errorHandler.reportError(this, re);\n errorHandler.recover(this, input,re);\n retval.tree = (PythonTree)adaptor.errorNode(input, retval.start, input.LT(-1), re);\n }\n finally {\n }\n return retval;\n }",
"public /*@ non_null @*/ StringBuffer toDot(){\n\n StringBuffer r = new StringBuffer();\n\n for(int i = 0; i <= sons.size() - 1; i++)\n\tr.append(getChildAt(i).toDot());\n \n return r;\n }",
"public final void mT__22() throws RecognitionException {\n try {\n int _type = T__22;\n int _channel = DEFAULT_TOKEN_CHANNEL;\n // InternalReqLNG.g:21:7: ( '.' )\n // InternalReqLNG.g:21:9: '.'\n {\n match('.'); \n\n }\n\n state.type = _type;\n state.channel = _channel;\n }\n finally {\n }\n }",
"public String smartDot(String s) {\n\t\t\t \ts = s.substring(0, (s.length() - 1)) + \"_\";\n\t\t\t \ts = s.replace(\"._\", \"s.\");\n\t s = s.replace(\" _\", \"s.\");\n\t s = s.replace(\"_\", \".\");\n\t return s;\n\t\t\t }",
"static private void printDot(DecisionTree tree) {\n\tSystem.out.println((new DecisionTreeToDot(tree)).produce());\n }",
"static private void printDot(DecisionTree tree) {\n\tSystem.out.println((new DecisionTreeToDot(tree)).produce());\n }",
"public boolean containsDotCommand(String firstCommand) {\n\t\tswitch(this) {\n\t\t\n\t\tcase ADDRSS -> \t{return true;}\n\t\tcase ASCII -> \t{return true;}\n\t\tcase BLOCK -> \t{return true;}\n\t\tcase BURN -> \t{return true;}\n\t\tcase BYTE -> \t{return true;}\n\t\tcase END -> \t{return true;}\n\t\tcase EQUATE -> {return true;}\n\t\tcase WORD -> \t{return true;}\n\t\t\n\t\tdefault -> {return false;}\n\t\t\n\t\t}\n\t\t\n\t}",
"@Override\n\tpublic Object visit(ASTDot node, Object data) {\n\t\tSystem.out.print(\".\");\n\t\treturn null;\n\t}",
"private int getNamespaceEnd() {\n int index = data.substring(tokenStart, tokenEnd).indexOf(\".\");\n return index != -1 ? index + tokenStart : tokenEnd;\n }",
"private String prependServerDot(String s) {\n\n final String namedot = serverEnv.getInstanceName() + \".\";\n\n if(s.startsWith(namedot))\n return s;\n\n return namedot + s;\n }",
"public static List<PathElement> parseDotNotationRHS( String dotNotation ) {\n String fixedNotation = fixLeadingBracketSugar( dotNotation );\n List<String> pathStrs = parseDotNotation( new LinkedList<String>(), stringIterator( fixedNotation ), dotNotation );\n\n return parseList( pathStrs, dotNotation );\n }",
"@Override public String toDot() {\r\n return \"¬ \" + predicate.toDot();\r\n }",
"public static String removeLeadingDots(String dotPrefixedStr) {\n int pos = 0;\n while (pos < dotPrefixedStr.length() && dotPrefixedStr.charAt(pos) == Symbol.C_DOT) {\n pos++;\n }\n return pos < dotPrefixedStr.length() ? dotPrefixedStr.substring(pos) : Normal.EMPTY;\n }",
"public final PythonParser.dotted_as_names_return dotted_as_names() throws RecognitionException {\n PythonParser.dotted_as_names_return retval = new PythonParser.dotted_as_names_return();\n retval.start = input.LT(1);\n\n PythonTree root_0 = null;\n\n Token COMMA118=null;\n List list_d=null;\n PythonParser.dotted_as_name_return d = null;\n d = null;\n PythonTree COMMA118_tree=null;\n\n try {\n // /run/media/abhi/0cc7e6ad-008e-43cd-b47d-f3ed6f127f92/home/abhi/dacapo-9.12-bach-src (2)/benchmarks/bms/jython/build/grammar/Python.g:833:5: (d+= dotted_as_name ( COMMA d+= dotted_as_name )* )\n // /run/media/abhi/0cc7e6ad-008e-43cd-b47d-f3ed6f127f92/home/abhi/dacapo-9.12-bach-src (2)/benchmarks/bms/jython/build/grammar/Python.g:833:7: d+= dotted_as_name ( COMMA d+= dotted_as_name )*\n {\n root_0 = (PythonTree)adaptor.nil();\n\n pushFollow(FOLLOW_dotted_as_name_in_dotted_as_names3190);\n d=dotted_as_name();\n\n state._fsp--;\n if (state.failed) return retval;\n if ( state.backtracking==0 ) adaptor.addChild(root_0, d.getTree());\n if (list_d==null) list_d=new ArrayList();\n list_d.add(d.getTree());\n\n // /run/media/abhi/0cc7e6ad-008e-43cd-b47d-f3ed6f127f92/home/abhi/dacapo-9.12-bach-src (2)/benchmarks/bms/jython/build/grammar/Python.g:833:25: ( COMMA d+= dotted_as_name )*\n loop57:\n do {\n int alt57=2;\n int LA57_0 = input.LA(1);\n\n if ( (LA57_0==COMMA) ) {\n alt57=1;\n }\n\n\n switch (alt57) {\n \tcase 1 :\n \t // /run/media/abhi/0cc7e6ad-008e-43cd-b47d-f3ed6f127f92/home/abhi/dacapo-9.12-bach-src (2)/benchmarks/bms/jython/build/grammar/Python.g:833:26: COMMA d+= dotted_as_name\n \t {\n \t COMMA118=(Token)match(input,COMMA,FOLLOW_COMMA_in_dotted_as_names3193); if (state.failed) return retval;\n \t pushFollow(FOLLOW_dotted_as_name_in_dotted_as_names3198);\n \t d=dotted_as_name();\n\n \t state._fsp--;\n \t if (state.failed) return retval;\n \t if ( state.backtracking==0 ) adaptor.addChild(root_0, d.getTree());\n \t if (list_d==null) list_d=new ArrayList();\n \t list_d.add(d.getTree());\n\n\n \t }\n \t break;\n\n \tdefault :\n \t break loop57;\n }\n } while (true);\n\n if ( state.backtracking==0 ) {\n\n retval.atypes = list_d;\n \n }\n\n }\n\n retval.stop = input.LT(-1);\n\n if ( state.backtracking==0 ) {\n\n retval.tree = (PythonTree)adaptor.rulePostProcessing(root_0);\n adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop);\n }\n }\n\n catch (RecognitionException re) {\n errorHandler.reportError(this, re);\n errorHandler.recover(this, input,re);\n retval.tree = (PythonTree)adaptor.errorNode(input, retval.start, input.LT(-1), re);\n }\n finally {\n }\n return retval;\n }",
"public static String defaultFileExtension() {\n return \"dot\";\n }",
"public final void tablename() throws RecognitionException {\r\n Token a=null;\r\n\r\n try {\r\n // D:\\\\entornotrabajo\\\\workspace-sgo\\\\persistance\\\\src\\\\main\\\\java\\\\es\\\\caser\\\\persistance\\\\sql\\\\antlr\\\\SQLGrammar.g:206:3: ( ( schema dot )? (a= IDENT ) )\r\n // D:\\\\entornotrabajo\\\\workspace-sgo\\\\persistance\\\\src\\\\main\\\\java\\\\es\\\\caser\\\\persistance\\\\sql\\\\antlr\\\\SQLGrammar.g:206:5: ( schema dot )? (a= IDENT )\r\n {\r\n // D:\\\\entornotrabajo\\\\workspace-sgo\\\\persistance\\\\src\\\\main\\\\java\\\\es\\\\caser\\\\persistance\\\\sql\\\\antlr\\\\SQLGrammar.g:206:5: ( schema dot )?\r\n int alt57=2;\r\n int LA57_0 = input.LA(1);\r\n\r\n if ( (LA57_0==SCHEMA) ) {\r\n alt57=1;\r\n }\r\n switch (alt57) {\r\n case 1 :\r\n // D:\\\\entornotrabajo\\\\workspace-sgo\\\\persistance\\\\src\\\\main\\\\java\\\\es\\\\caser\\\\persistance\\\\sql\\\\antlr\\\\SQLGrammar.g:206:6: schema dot\r\n {\r\n pushFollow(FOLLOW_schema_in_tablename1250);\r\n schema();\r\n\r\n state._fsp--;\r\n\r\n pushFollow(FOLLOW_dot_in_tablename1252);\r\n dot();\r\n\r\n state._fsp--;\r\n\r\n\r\n }\r\n break;\r\n\r\n }\r\n\r\n // D:\\\\entornotrabajo\\\\workspace-sgo\\\\persistance\\\\src\\\\main\\\\java\\\\es\\\\caser\\\\persistance\\\\sql\\\\antlr\\\\SQLGrammar.g:206:18: (a= IDENT )\r\n // D:\\\\entornotrabajo\\\\workspace-sgo\\\\persistance\\\\src\\\\main\\\\java\\\\es\\\\caser\\\\persistance\\\\sql\\\\antlr\\\\SQLGrammar.g:206:19: a= IDENT\r\n {\r\n a=(Token)match(input,IDENT,FOLLOW_IDENT_in_tablename1258); \r\n tableName(a);\r\n\r\n }\r\n\r\n\r\n }\r\n\r\n }\r\n finally {\r\n }\r\n return ;\r\n }",
"public final void synpred1_InternalStl_fragment() throws RecognitionException { \n // InternalStl.g:1699:5: ( '.' )\n // InternalStl.g:1699:6: '.'\n {\n match(input,35,FOLLOW_2); if (state.failed) return ;\n\n }\n }",
"@Test\n public void test_dot_string_returns_null()\n {\n InputStream inputStream = ResourceUtil.getInputStream(\".\");\n assertNull(\"Should be null\", inputStream);\n }",
"public void dot(String str) throws PaleoException {\n\t\trunProcess(\"dot -Tpng \" + str + \".dot -o \" + str + \".png\");\n\t\tif (erreur.length() != 0) {\n\t\t\tthrow new DotException(erreur.toString());\n\t\t}\n\t}",
"public final void mRULE_DOT() throws RecognitionException {\n try {\n int _type = RULE_DOT;\n int _channel = DEFAULT_TOKEN_CHANNEL;\n // ../org.sqlproc.meta/src-gen/org/sqlproc/meta/parser/antlr/internal/InternalProcessorMeta.g:12837:10: ( '.' )\n // ../org.sqlproc.meta/src-gen/org/sqlproc/meta/parser/antlr/internal/InternalProcessorMeta.g:12837:12: '.'\n {\n match('.'); \n\n }\n\n state.type = _type;\n state.channel = _channel;\n }\n finally {\n }\n }",
"String getNamespaceStringValue(Object ns);",
"private Token scanAmbiguousWithDot() {\n Token tok;\n Pair<Integer, Integer> pos = new Pair<>(in.line(), in.pos());\n buffer.add(c);\n int nextChar = in.read();\n\n // '..' operator\n if (nextChar == '.') {\n buffer.add(nextChar);\n tok = new Token(buffer.toString(), TokenType.RANGE, pos);\n buffer.flush();\n c = in.read(); // in this case nextChar is already processed,\n // therefore c gets the value of the next character\n }\n\n // real literals starting with '.' (e.g. '.12231')\n else if (Character.isDigit(nextChar)) { // .001234125 literals\n while (Character.isDigit(nextChar) && nextChar != -1) {\n buffer.add(nextChar);\n nextChar = in.read();\n }\n tok = new Token(buffer.toString(), TokenType.REAL_LITERAL, pos);\n buffer.flush();\n c = nextChar;\n }\n // standalone '.'\n else {\n tok = new Token(buffer.toString(), TokenType.DOT, pos);\n buffer.flush();\n c = nextChar;\n }\n return tok;\n }",
"public void testIllegalPeriodInName() throws Exception\r\n {\r\n try\r\n {\r\n new ComponentDirective( \r\n \"fred.blogs\", m_activation, m_collection, m_lifestyle, m_classname, \r\n m_categories, m_context, null, null );\r\n fail( \"Did not throw an IllegalArgumentException for a name with a period.\" ); \r\n }\r\n catch( IllegalArgumentException e )\r\n {\r\n // ok\r\n }\r\n }",
"private ParsedDottedName parseDottedName(String dottedString, String command)\n throws MalformedNameException {\n ArrayList tokenList = new ArrayList();\n Name dottedName = new Name(dottedString);\n int nTokens = dottedName.getNumParts();\n if (nTokens < 1) {\n\t\t\tString msg = localStrings.getString( \"admin.monitor.name_does_not_contain_any_tokens\", dottedString );\n throw new MalformedNameException( msg );\n }\n for (int j = 0; j < nTokens; j++) {\n tokenList.add(dottedName.getNamePart(j).toString());\n }\n return parseTokens(tokenList, command, dottedString);\n }",
"java.lang.String getNamespace();",
"public void createOAGDot(){\r\n\t\ttry {\r\n\t\t\tFileWriter writer = new FileWriter(new File(\"OAGGraph.dot\"));\r\n\t\t\twriter.write(\"digraph G{\\n\");\r\n\t\t\tint subCounter = 0;\r\n\t\t\t// Add all vertices\r\n\t\t\t\r\n\t\t\tfor (IFace iface : interfaces){\r\n\t\t\t\taddOAGDotIFace(iface, writer, subCounter);\r\n\t\t\t\tsubCounter++;\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\tfor (Class cls : classes){\r\n\t\t\t\taddOAGDotCls(cls, writer, subCounter);\r\n\t\t\t\tsubCounter++;\r\n\t\t\t}\r\n\r\n\t\t\t// Add edges\r\n\t\t\tfor (Vertex source : graphEdges.keySet()){\r\n\t\t\t\tString sourceName = source.getParent().getName() + \"_\" + source.getExtVar();\r\n\t\t\t\tHashMap<Vertex, EdgeType> dests = graphEdges.get(source);\r\n\t\t\t\tif (dests != null){\r\n\t\t\t\t\tfor (Vertex dest : dests.keySet()){\r\n\t\t\t\t\t\tString destName = dest.getParent().getName() + \"_\" + dest.getExtVar();\r\n\t\t\t\t\t\tString edgeStr = \"\\t\" + sourceName + \" -> \" + destName;\r\n\t\t\t\t\t\tif (dests.get(dest) == EdgeType.INDIRECT)\r\n\t\t\t\t\t\t\tedgeStr += \"[style=dotted]\";\r\n\t\t\t\t\t\twriter.write(edgeStr + \";\\n\");\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\twriter.write(\"}\");\r\n\t\t\twriter.close();\r\n\t\t}\r\n\t\tcatch (IOException e){\r\n\t\t\tSystem.err.println(\"Error: IOException detected\");\r\n\t\t\te.printStackTrace();\r\n\t\t\tSystem.exit(1);\r\n\t\t}\r\n\t}",
"private static String fixLeadingBracketSugar( String dotNotaton ) {\n\n if ( dotNotaton == null || dotNotaton.length() == 0 ) {\n return \"\";\n }\n\n char prev = dotNotaton.charAt( 0 );\n StringBuilder sb = new StringBuilder();\n sb.append( prev );\n\n for ( int index = 1; index < dotNotaton.length(); index++ ) {\n char curr = dotNotaton.charAt( index );\n\n if ( curr == '[' && prev != '\\\\') {\n if ( prev == '@' || prev == '.' ) {\n // no need to add an extra '.'\n }\n else {\n sb.append( '.' );\n }\n }\n\n sb.append( curr );\n prev = curr;\n }\n\n return sb.toString();\n }",
"String noExt(String name) {\r\n int last=name.lastIndexOf(\".\");\r\n if(last>0)\r\n return name.substring(0, last);\r\n\r\n return name;\r\n }",
"public final void mT__14() throws RecognitionException {\r\n try {\r\n int _type = T__14;\r\n int _channel = DEFAULT_TOKEN_CHANNEL;\r\n // InternalSpringConfigDsl.g:15:7: ( '.' )\r\n // InternalSpringConfigDsl.g:15:9: '.'\r\n {\r\n match('.'); \r\n\r\n }\r\n\r\n state.type = _type;\r\n state.channel = _channel;\r\n }\r\n finally {\r\n }\r\n }",
"private String parseQName(ByteBuffer response) {\n StringBuilder sb = new StringBuilder();\n parseLabels(response, sb);\n sb.deleteCharAt(sb.length() - 1);//remove trailing '.'\n return sb.toString();\n }",
"private void addDotNode(DotNode dt) {\n dotNodes.add(dt);\n }",
"static boolean dottedName(PsiBuilder b, int l) {\n if (!recursion_guard_(b, l, \"dottedName\")) return false;\n boolean r;\n Marker m = enter_section_(b);\n r = nonStrictID(b, l + 1);\n r = r && dottedName_1(b, l + 1);\n exit_section_(b, m, null, r);\n return r;\n }",
"@Override\n public String getDotNodeAttributes(TermID id)\n {\n return null;\n }",
"public final void synpred3_Binding_fragment() throws RecognitionException { \n // C:\\\\Documents and Settings\\\\D043530\\\\runtime-workspace\\\\com.sap.ap.cts.editor\\\\generated\\\\generated\\\\Binding.g:2956:9: ( INT '.' ~ ( '.' | 'a' .. 'z' | 'A' .. 'Z' | '_' | '\\\\u00C0' .. '\\\\u00D6' | '\\\\u00D8' .. '\\\\u00F6' | '\\\\u00F8' .. '\\\\u00FF' ) )\n // C:\\\\Documents and Settings\\\\D043530\\\\runtime-workspace\\\\com.sap.ap.cts.editor\\\\generated\\\\generated\\\\Binding.g:2956:11: INT '.' ~ ( '.' | 'a' .. 'z' | 'A' .. 'Z' | '_' | '\\\\u00C0' .. '\\\\u00D6' | '\\\\u00D8' .. '\\\\u00F6' | '\\\\u00F8' .. '\\\\u00FF' )\n {\n mINT(); if (state.failed) return ;\n match('.'); if (state.failed) return ;\n if ( (input.LA(1)>='\\u0000' && input.LA(1)<='-')||(input.LA(1)>='/' && input.LA(1)<='@')||(input.LA(1)>='[' && input.LA(1)<='^')||input.LA(1)=='`'||(input.LA(1)>='{' && input.LA(1)<='\\u00BF')||input.LA(1)=='\\u00D7'||input.LA(1)=='\\u00F7'||(input.LA(1)>='\\u0100' && input.LA(1)<='\\uFFFF') ) {\n input.consume();\n state.failed=false;\n }\n else {\n if (state.backtracking>0) {state.failed=true; return ;}\n MismatchedSetException mse = new MismatchedSetException(null,input);\n recover(mse);\n throw mse;}\n\n\n }\n }",
"@Override String toDot() {\r\n switch ( operator ) {\r\n case EQUALS_PREFIX :\r\n case EQUALS :\r\n return left.toDot() + \" = \" + right.toDot();\r\n case NEQ :\r\n return left.toDot() + \" ≠ \" + right.toDot();\r\n case GE : \r\n return left.toDot() + \" ≥ \" + right.toDot();\r\n case GT : \r\n return left.toDot() + \" > \" + right.toDot(); \r\n case LE :\r\n return left.toDot() + \" ≤ \" + right.toDot();\r\n case LT : \r\n return left.toDot() + \" < \" + right.toDot();\r\n }\r\n assert false:operator;\r\n return null;\r\n }",
"private boolean isNamespace(int start, int end) {\n int i;\n int nsLen = end - start;\n int offset = tokenStart - start;\n int tokenLen = tokenEnd - tokenStart;\n\n if (tokenLen < nsLen) {\n return false;\n }\n\n for (i = start; i < end; i++) {\n if (data.charAt(i) != data.charAt(i + offset)) {\n return false;\n }\n }\n\n if (nsLen == tokenLen) {\n return true;\n }\n return data.charAt(i + offset) == '.';\n }",
"protected String getName( String key ){\n\n return ( key.indexOf( '.' ) == -1 )?\n //if there is no instance of . then the key is the name\n key:\n //else get the substring to first dot\n key.substring( 0, key.indexOf( '.' ));\n }",
"private static boolean isGoogDotLocaleReference(Node n) {\n return n.matchesQualifiedName(QNAME_FOR_GOOG_LOCALE);\n }",
"public String toDotString() {\n StringBuilder builder = new StringBuilder();\n builder.append(\"digraph {\\n\");\n\n for (Connection connection : connections) {\n for (ConnectionEndPoint output : connection.outputs) {\n String edge = String.format(\" %s -> %s [label=\\\"%s\\\"];\\n\",\n connection.input.getStageName(), output.getStageName(), connection.getName());\n builder.append(edge);\n }\n }\n\n for (Stage stage : stages.values()) {\n builder.append(String.format(\" %s;\\n\", stage.name));\n }\n\n builder.append(\"}\\n\");\n return builder.toString();\n }",
"@Override\n\tpublic Object visit(ASTDdot node, Object data) {\n\t\tSystem.out.print(\"..\");\n\t\treturn null;\n\t}",
"@Override public String toDot() {\r\n String middle = \"\";\r\n switch(operator) {\r\n case AND : \r\n middle = \"&\";\r\n break;\r\n case NOR :\r\n case OR : \r\n middle = \"∨\";\r\n break;\r\n case IMPLIES : \r\n middle = \"=>\";\r\n break;\r\n default : assert false;\r\n }\r\n middle = left.toDot() + \" \" + middle + \" \" + right.toDot();\r\n if ( operator == Token.NOR )\r\n return \"¬ (\"+middle+\")\";\r\n else\r\n return middle;\r\n }",
"public void buttonDot (View view){\n boolean dot = false;\n char[] expression = resultView.getText().toString().trim().toCharArray();\n for (int i = 0; i < expression.length; i++) {\n if (expression[i] == '.')\n dot = true;\n }\n if (!dot)\n resultView.setText(resultView.getText() + \".\");\n mIsTyping = true;\n }",
"private static String dottedExpressionToString(Expression e) {\n if (e instanceof Identifier) {\n return ((Identifier) e).getName();\n }\n if (e instanceof DotExpression) {\n String result = dottedExpressionToString(((DotExpression) e).getObject());\n if (!result.isEmpty()) {\n return result + \".\" + ((DotExpression) e).getField().getName();\n }\n }\n\n return \"\";\n }",
"String getNamespace();",
"String getNamespace();",
"String getNamespace();",
"public final PythonParser.dotted_as_name_return dotted_as_name() throws RecognitionException {\n PythonParser.dotted_as_name_return retval = new PythonParser.dotted_as_name_return();\n retval.start = input.LT(1);\n\n PythonTree root_0 = null;\n\n Token AS116=null;\n Token NAME117=null;\n PythonParser.dotted_name_return dotted_name115 = null;\n\n\n PythonTree AS116_tree=null;\n PythonTree NAME117_tree=null;\n\n try {\n // /run/media/abhi/0cc7e6ad-008e-43cd-b47d-f3ed6f127f92/home/abhi/dacapo-9.12-bach-src (2)/benchmarks/bms/jython/build/grammar/Python.g:824:5: ( dotted_name ( AS NAME )? )\n // /run/media/abhi/0cc7e6ad-008e-43cd-b47d-f3ed6f127f92/home/abhi/dacapo-9.12-bach-src (2)/benchmarks/bms/jython/build/grammar/Python.g:824:7: dotted_name ( AS NAME )?\n {\n root_0 = (PythonTree)adaptor.nil();\n\n pushFollow(FOLLOW_dotted_name_in_dotted_as_name3149);\n dotted_name115=dotted_name();\n\n state._fsp--;\n if (state.failed) return retval;\n if ( state.backtracking==0 ) adaptor.addChild(root_0, dotted_name115.getTree());\n // /run/media/abhi/0cc7e6ad-008e-43cd-b47d-f3ed6f127f92/home/abhi/dacapo-9.12-bach-src (2)/benchmarks/bms/jython/build/grammar/Python.g:824:19: ( AS NAME )?\n int alt56=2;\n int LA56_0 = input.LA(1);\n\n if ( (LA56_0==AS) ) {\n alt56=1;\n }\n switch (alt56) {\n case 1 :\n // /run/media/abhi/0cc7e6ad-008e-43cd-b47d-f3ed6f127f92/home/abhi/dacapo-9.12-bach-src (2)/benchmarks/bms/jython/build/grammar/Python.g:824:20: AS NAME\n {\n AS116=(Token)match(input,AS,FOLLOW_AS_in_dotted_as_name3152); if (state.failed) return retval;\n if ( state.backtracking==0 ) {\n AS116_tree = (PythonTree)adaptor.create(AS116);\n adaptor.addChild(root_0, AS116_tree);\n }\n NAME117=(Token)match(input,NAME,FOLLOW_NAME_in_dotted_as_name3154); if (state.failed) return retval;\n if ( state.backtracking==0 ) {\n NAME117_tree = (PythonTree)adaptor.create(NAME117);\n adaptor.addChild(root_0, NAME117_tree);\n }\n\n }\n break;\n\n }\n\n if ( state.backtracking==0 ) {\n\n retval.atype = new alias(NAME117, (dotted_name115!=null?dotted_name115.name:null), (NAME117!=null?NAME117.getText():null));\n \n }\n\n }\n\n retval.stop = input.LT(-1);\n\n if ( state.backtracking==0 ) {\n\n retval.tree = (PythonTree)adaptor.rulePostProcessing(root_0);\n adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop);\n }\n if ( state.backtracking==0 ) {\n\n retval.tree = retval.atype;\n\n }\n }\n\n catch (RecognitionException re) {\n errorHandler.reportError(this, re);\n errorHandler.recover(this, input,re);\n retval.tree = (PythonTree)adaptor.errorNode(input, retval.start, input.LT(-1), re);\n }\n finally {\n }\n return retval;\n }",
"private boolean isValid(String s, boolean hasDot) {\n\t if (s.length() > 0 && (s.charAt(0) == '+' || s.charAt(0) == '-')) {\n\t \ts = s.substring(1);\n\t }\n\t \n\t if (s.isEmpty() || s.equals(\".\")) {\n\t \treturn false;\n\t }\n\t \n\t for (int i = 0; i<s.length(); i++) {\n\t \tchar c = s.charAt(i);\n\t if (c == '.') {\n\t \t//can not have a second dot\n\t if (hasDot) {\n\t \treturn false;\n\t }\t \n\t hasDot = true;\n\t } else if (!('0' <= c && c <= '9')) {\n\t return false;\n\t }\n\t }\n\t return true;\n\t}",
"@Override\n public String toString() {\n if (restOfSentence instanceof WordNode) {\n return word + \" \" + restOfSentence.toString();\n } else if (restOfSentence instanceof EmptyNode) {\n return word + \".\" + restOfSentence.toString();\n } else {\n return word + restOfSentence.toString();\n }\n }",
"public String getNamespace()\n/* */ {\n/* 357 */ return this.namespace;\n/* */ }",
"public String getNamespace();",
"private String ricavaSchema(String itemSelected){\n int i = 0;\n String schema;\n \n while(itemSelected.charAt(i) != '.'){\n i++;\n }\n \n schema = itemSelected.substring(0, i);\n \n return schema;\n }",
"private static String p(Class n) {\n return n.getName().replace('.','/');\n }",
"protected void setPartitionDotFile(final String str) {\n\t\tthis.partitionDot = str;\n\t}",
"public Image getDot();",
"public double numberDots(LocationSet dot){\n\t\treturn -(dot.size()*10)/250;\n\t}",
"String getNamespacePrefix(Object ns);",
"private String ricavaNome(String itemSelected){\n int i = 0;\n String schema;\n \n while(itemSelected.charAt(i) != '.'){\n i++;\n }\n \n schema = itemSelected.substring(i+1);\n \n return schema;\n }",
"public final void mT__63() throws RecognitionException {\n try {\n int _type = T__63;\n int _channel = DEFAULT_TOKEN_CHANNEL;\n // InternalMyDsl.g:61:7: ( '.' )\n // InternalMyDsl.g:61:9: '.'\n {\n match('.'); \n\n }\n\n state.type = _type;\n state.channel = _channel;\n }\n finally {\n }\n }",
"public String buildDotString(){\n\t\tString ret=\"digraph NFA{\\n\";\n\t\tint numStarts=0;\n\t\tfor (State s : theStates){\n\t\t\tif(s.getAccept())\n\t\t\t\tret+=\"\\t\"+s.getIndex()+\"[shape=doublecircle]\\n\";\n\t\t\tif(s.getStart()){\n\t\t\t\tString startlbl=\"start\"+(numStarts++);\n\t\t\t\tret+=\"\\t\"+startlbl+\"[shape=none,label=\\\"\\\"]\\n\";\n\t\t\t\tret+=\"\\t\"+startlbl+\"->\"+s.getIndex()+\"[color=green]\\n\";\n\t\t\t}\n\t\t\tfor (Object withChar : s.getToStates().keySet()){\n\t\t\t\t//TODO: combine arrows with same from/to\n\t\t\t\tfor (Integer toNode : (ArrayList<Integer>)s.getToStates().get(withChar)){\n\t\t\t\t\t//find similar arrows\n\t\t\t\t\tString arrowName=(String)withChar;\n\t\t\t\t\t/*for (Object otherChar : s.getToStates().keySet()){\n\t\t\t\t\t\tfor (Integer sameNodeIdx : (ArrayList<Integer>)s.getToStates().get(withChar)){\n\t\t\t\t\t\t\tif(sameNodeIdx==toNode) arrowName+=\",\"+otherChar;\n\t\t\t\t\t\t}\n\t\t\t\t\t}*/\n\t\t\t\t\tret+=\"\\t\"+s.getIndex()+\" -> \"+toNode+\"[label=\\\"\"+arrowName+\"\\\"]\\n\";\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tret+=\"}\";\n\t\treturn ret;\n\t}",
"public void setDotExecutable( File dotExecutable )\n {\n this.dotExecutable = dotExecutable;\n }",
"public void testFullyQualified(){ \n // when I do this, I need to change the regex as EITHER\n // \n $anno $a = $anno.of(R.class);\n \n @draft.java.proto.SannoTest.R\n class C{} \n _class _c = _class.of(C.class); \n assertNotNull( $a.firstIn(_c) );\n \n @R\n class D{} \n _class _d = _class.of(D.class); \n assertNotNull( $a.firstIn(_d) ); \n }",
"private static String namespace(File file) {\r\n File parent = file.getParentFile();\r\n\r\n return (parent == null) ? \"\" : (parent.getName() + \".\");\r\n }",
"public void deleteDot() {\n\t\tif (dotFile.exists()){\n\t\t\t\n\t\t\tif (!dotFile.canWrite())\n\t\t\t\tthrow new IllegalArgumentException(\"Delete: write protected: \" + dotFile.getName());\n\n\t\t\t// If it is a directory, make sure it is empty\n\t\t\tif (dotFile.isDirectory()) {\n\t\t\t\tString[] files = dotFile.list();\n\t\t\t\tif (files.length > 0)\n\t\t\t\t\tthrow new IllegalArgumentException(\"Delete: directory not empty: \" + dotFile.getName());\n\t\t\t}\n\t\t\t\n\t\t\tif (!dotFile.delete()){\n\t\t\t\tthrow new IllegalArgumentException(\"Delete: deletion failed\");\t\t\t\t\n\t\t\t}\n\t\t}\n\t\t\n\t}",
"public int dotCounter(String numberWord) {\n int count = 0;\n char dot = '.';\n for (int i = 0; i < numberWord.length(); i++) {\n if (numberWord.charAt(i) == dot) count++;\n }\n return count;\n }",
"private String extensions() {\n return Arrays.stream(f.getName().split(\"\\\\.\")).skip(1).collect(Collectors.joining(\".\"));\n }",
"private String removeContainsDot(String amount) {\n if (amount != null && !TextUtils.isEmpty(amount)) {\n if (amount.contains(\".\")) {\n String result = amount.substring(0, amount.indexOf(\".\"));\n return result;\n } else {\n return amount;\n }\n }\n return \"0\";\n }",
"public static String getInnerName(String s) {\n\t\tint s1 = s.indexOf('.');\n\t\tif (s1 < 0) return s;\n\t\treturn s.substring(s1+1);\n\t}",
"public final void mDDOT() throws RecognitionException {\n try {\n int _type = DDOT;\n int _channel = DEFAULT_TOKEN_CHANNEL;\n // C:\\\\Documents and Settings\\\\D043530\\\\runtime-workspace\\\\com.sap.ap.cts.editor\\\\generated\\\\generated\\\\Binding.g:2787:3: ( '..' )\n // C:\\\\Documents and Settings\\\\D043530\\\\runtime-workspace\\\\com.sap.ap.cts.editor\\\\generated\\\\generated\\\\Binding.g:2788:3: '..'\n {\n match(\"..\"); if (state.failed) return ;\n\n\n }\n\n state.type = _type;\n state.channel = _channel;\n }\n finally {\n }\n }",
"@Override\n public boolean isNotationDeclared(String name) { return false; }",
"default String getQualifiedName() {\n return declaringType().getQualifiedName() + \".\" + this.getName();\n }",
"public T caseDotExpression(DotExpression object) {\r\n\t\treturn null;\r\n\t}",
"public String toDot() {\n\t\tStringBuilder b = new StringBuilder();\n\t\tb.append(\"digraph BP {\\n\");\n\n\t\t// standard style for nodes and edges\n\t\tb.append(\"graph [fontname=\\\"Helvetica\\\" nodesep=0.3 ranksep=\\\"0.2 equally\\\" fontsize=10];\\n\");\n\t\tb.append(\"node [fontname=\\\"Helvetica\\\" fontsize=8 fixedsize width=\\\".3\\\" height=\\\".3\\\" label=\\\"\\\" style=filled fillcolor=white];\\n\");\n\t\tb.append(\"edge [fontname=\\\"Helvetica\\\" fontsize=8 color=white arrowhead=none weight=\\\"20.0\\\"];\\n\");\n\n\t\t// String tokenFillString =\n\t\t// \"fillcolor=black peripheries=2 height=\\\".2\\\" width=\\\".2\\\" \";\n\t\tString cutOffFillString = \"fillcolor=gold\";\n\t\tString antiFillString = \"fillcolor=red\";\n\t\tString impliedFillString = \"fillcolor=violet\";\n\t\tString hiddenFillString = \"fillcolor=grey\";\n\n\t\t// first print all conditions\n\t\tb.append(\"\\n\\n\");\n\t\tb.append(\"node [shape=circle];\\n\");\n\t\tfor (DNode n : bp.allConditions) {\n\t\t\tif (!option_printAnti && n.isAnti)\n\t\t\t\tcontinue;\n\t\t\t/*\n\t\t\t * - print current marking if (cutNodes.contains(n))\n\t\t\t * b.append(\" c\"+n.localId+\" [\"+tokenFillString+\"]\\n\"); else\n\t\t\t */\n\t\t\tif (n.isAnti && n.isHot)\n\t\t\t\tb.append(\" c\" + n.globalId + \" [\" + antiFillString + \"]\\n\");\n\t\t\telse if (n.isCutOff)\n\t\t\t\tb.append(\" c\" + n.globalId + \" [\" + cutOffFillString + \"]\\n\");\n\t\t\telse\n\t\t\t\tb.append(\" c\" + n.globalId + \" []\\n\");\n\n//\t\t\tString auxLabel = \"\";\n\n\t\t\tb.append(\" c\" + n.globalId + \"_l [shape=none];\\n\");\n\t\t\t// Diagrams\n\t\t\t// b.append(\" c\"+n.globalId+\"_l -> c\"+n.globalId+\" [headlabel=\\\"\"+n+\" \"+auxLabel+\"\\\"]\\n\");\n\t\t}\n\n\t\t// then print all events\n\t\tb.append(\"\\n\\n\");\n\t\tb.append(\"node [shape=box];\\n\");\n\t\tfor (DNode n : bp.allEvents) {\n\t\t\tif (!option_printAnti && n.isAnti)\n\t\t\t\tcontinue;\n\t\t\tif (n.isAnti && n.isHot)\n\t\t\t\tb.append(\" e\" + n.globalId + \" [\" + antiFillString + \"]\\n\");\n\t\t\telse if (n.isAnti && !n.isHot)\n\t\t\t\tb.append(\" e\" + n.globalId + \" [\" + hiddenFillString + \"]\\n\");\n\t\t\telse if (n.isImplied)\n\t\t\t\tb.append(\" e\" + n.globalId + \" [\" + impliedFillString + \"]\\n\");\n\t\t\telse if (n.isCutOff)\n\t\t\t\tb.append(\" e\" + n.globalId + \" [\" + cutOffFillString + \"]\\n\");\n\t\t\telse\n\t\t\t\tb.append(\" e\" + n.globalId + \" []\\n\");\n\n\t\t\tString auxLabel = \"\";\n\n\t\t\tb.append(\" e\" + n.globalId + \"_l [shape=none]\\n\");\n\t\t\t// Diagrams\n\t\t\tb.append(\" e\"+n.globalId+\"_l -> e\"+n.globalId+\" [headlabel=\\\"\"+n+\" \"+auxLabel+\"\\\"]\\n\");\n//\t\t\tb.append(\" label=\\\"\"+n+\"\\\"];\\n\");\n\t\t}\n\n\t\t// finally, print all edges\n\t\tb.append(\"\\n\\n\");\n\t\tb.append(\" edge [fontname=\\\"Helvetica\\\" fontsize=8 arrowhead=normal color=black];\\n\");\n\t\tfor (DNode n : bp.allConditions) {\n\t\t\tString prefix = n.isEvent ? \"e\" : \"c\";\n\t\t\tfor (int i = 0; i < n.pre.length; i++) {\n\t\t\t\tif (n.pre[i] == null)\n\t\t\t\t\tcontinue;\n\t\t\t\tif (!option_printAnti && n.isAnti)\n\t\t\t\t\tcontinue;\n\n\t\t\t\tif (n.pre[i].isEvent)\n\t\t\t\t\tb.append(\" e\" + n.pre[i].globalId + \" -> \" + prefix\n\t\t\t\t\t\t\t+ n.globalId + \" [weight=10000.0]\\n\");\n\t\t\t\telse\n\t\t\t\t\tb.append(\" c\" + n.pre[i].globalId + \" -> \" + prefix\n\t\t\t\t\t\t\t+ n.globalId + \" [weight=10000.0]\\n\");\n\t\t\t}\n\t\t}\n\n\t\tfor (DNode n : bp.allEvents) {\n\t\t\tString prefix = n.isEvent ? \"e\" : \"c\";\n\t\t\tfor (int i = 0; i < n.pre.length; i++) {\n\t\t\t\tif (n.pre[i] == null)\n\t\t\t\t\tcontinue;\n\t\t\t\tif (!option_printAnti && n.isAnti)\n\t\t\t\t\tcontinue;\n\t\t\t\tif (n.pre[i].isEvent)\n\t\t\t\t\tb.append(\" e\" + n.pre[i].globalId + \" -> \" + prefix\n\t\t\t\t\t\t\t+ n.globalId + \" [weight=10000.0]\\n\");\n\t\t\t\telse\n\t\t\t\t\tb.append(\" c\" + n.pre[i].globalId + \" -> \" + prefix\n\t\t\t\t\t\t\t+ n.globalId + \" [weight=10000.0]\\n\");\n\t\t\t}\n\t\t}\n\n\t\t// and add links from cutoffs to corresponding events (exclusive case)\n\t\tb.append(\"\\n\\n\");\n\t\tb.append(\" edge [fontname=\\\"Helvetica\\\" fontsize=8 arrowhead=normal color=red];\\n\");\n\t\tfor (DNode n : bp.allEvents) {\n\t\t\tif (n.isCutOff\n\t\t\t\t\t&& futureEquivalence().getElementary_ccPair().get(n) != null) {\n\t\t\t\tif (!this.isCorrInLocalConfig(n, futureEquivalence()\n\t\t\t\t\t\t.getElementary_ccPair().get(n)))\n\t\t\t\t\tb.append(\" e\"\n\t\t\t\t\t\t\t+ n.globalId\n\t\t\t\t\t\t\t+ \" -> e\"\n\t\t\t\t\t\t\t+ futureEquivalence().getElementary_ccPair().get(n).globalId\n\t\t\t\t\t\t\t+ \" [weight=10000.0]\\n\");\n\t\t\t}\n\t\t}\n\n\t\t// and add links from cutoffs to corresponding events (causal case)\n\t\tb.append(\"\\n\\n\");\n\t\tb.append(\" edge [fontname=\\\"Helvetica\\\" fontsize=8 arrowhead=normal color=blue];\\n\");\n\t\tfor (DNode n : bp.allEvents) {\n\t\t\tif (n.isCutOff\n\t\t\t\t\t&& futureEquivalence().getElementary_ccPair().get(n) != null) {\n\t\t\t\tif (this.isCorrInLocalConfig(n, futureEquivalence()\n\t\t\t\t\t\t.getElementary_ccPair().get(n)))\n\t\t\t\t\tb.append(\" e\"\n\t\t\t\t\t\t\t+ n.globalId\n\t\t\t\t\t\t\t+ \" -> e\"\n\t\t\t\t\t\t\t+ futureEquivalence().getElementary_ccPair().get(n).globalId\n\t\t\t\t\t\t\t+ \" [weight=10000.0]\\n\");\n\t\t\t}\n\t\t}\n\n\t\tb.append(\"}\");\n\t\treturn b.toString();\n\t}",
"String decodeNS(String doc) {\n\t\treturn doc.replaceAll(COLON_REPLACEMENT, \":\");\n\t}",
"int getNamespaceUri();",
"private static String getExtensionOrFileName(String filename, boolean extension) {\n\n\t\tString fileWithExt = new File(filename).getName();\n\t\tStringTokenizer s = new StringTokenizer(fileWithExt, \".\");\n\t\tif (extension) {\n\t\t\ts.nextToken();\n\t\t\treturn s.nextToken();\n\t\t} else\n\t\t\treturn s.nextToken();\n\t}",
"public final void mT__47() throws RecognitionException {\n try {\n int _type = T__47;\n int _channel = DEFAULT_TOKEN_CHANNEL;\n // InternalIotLuaXtext.g:47:7: ( '.' )\n // InternalIotLuaXtext.g:47:9: '.'\n {\n match('.'); \n\n }\n\n state.type = _type;\n state.channel = _channel;\n }\n finally {\n }\n }",
"private ParseTree parseNewDotSomething() {\n SourcePosition start = getTreeStartLocation();\n eat(TokenType.NEW);\n eat(TokenType.PERIOD);\n eatPredefinedString(\"target\");\n return new NewTargetExpressionTree(getTreeLocation(start));\n }",
"public static String name(){\n return \"10.Schneiderman.Lorenzo\"; \n }",
"public final void mT__18() throws RecognitionException {\n try {\n int _type = T__18;\n int _channel = DEFAULT_TOKEN_CHANNEL;\n // ../com.pellcorp.mydsl/src-gen/com/pellcorp/mydsl/parser/antlr/internal/InternalMyDsl.g:16:7: ( '.' )\n // ../com.pellcorp.mydsl/src-gen/com/pellcorp/mydsl/parser/antlr/internal/InternalMyDsl.g:16:9: '.'\n {\n match('.'); \n\n }\n\n state.type = _type;\n state.channel = _channel;\n }\n finally {\n }\n }",
"private String getSimpleName(String name) {\n\t\tint i = name.lastIndexOf(\".\");\n\t\treturn name.substring(i + 1);\n\t}",
"public static void main(String[] args) {\n\t\tScanner scan = new Scanner(System.in);\n\t\tSystem.out.println(\"Enter url: \");\n\t\tString url = scan.next();\n\t\t\n//1- check it that starts with www.\n\t\t\n\t\tif(url.startsWith(\"www.\")) {\n\t\t\tSystem.out.println(\"www. is present\");\n\t\t}else {\n\t\t\tSystem.out.println(\"Invalid url format\");\n\t\t\treturn;\n\t\t}\n\t\t\n//2- check it contains the ending dot (.) right before the extension\n\t\t// \t\texp. www.etsy.com 12-4'de . var\n\t\t\n\t\tint dotIndex = url.length()-4; //\t- find out the length of the url and do -4 and using chart get the character\n\t\t//url.lastIndexOf(\".\");\n\t\t\n\t\tif(url.charAt(dotIndex) == ( '.')) { // - compare if it is '.'\n\t\t\tSystem.out.println(\"Yes it contains (.) before extension\");\n\t\t}else {\n\t\t\tSystem.out.println(\". might be misplaced\");\n\t\t}\n\t\t/*\n\t\t * if (url.charAt(url.lengrh() - 4) == '.'){ //bu da ayni sonucu verir.\n\t\t * \n\t\t * } */\n\t\t\n/* 3- assign String domain and String extension.\n 4- print them\n\t\t\t\"Domain: \" amazon\n\t\t\t\"Extension: \" com\n\t\t */\n\t\t\n\t\tString domain = url.substring(4, dotIndex); //www.'dan dotIndex'e kadar sonasini okutuyoruz\n\t\tSystem.out.println(\"Domain: \" + domain);\n\t\tString extension = url.substring(dotIndex+1, url.length()); //dotIndex, -4'e gelmisti \n\t\t\t\t\t\t\t\t\t\t\t\t\t// (.' yi cikarmak icin +1 ekledik,\n\t\t\t\t\t\t\t\t\t\t\t\t\t// nereye kadar=> sonuna yani url.length()'e kadar\n\t\tSystem.out.println(\"Extension: \"+ extension);\n\t\t\n\t\t\n\t\t\n\t}"
] | [
"0.6594788",
"0.6451189",
"0.6422093",
"0.63951766",
"0.6280767",
"0.6233069",
"0.61314857",
"0.61237675",
"0.6109706",
"0.59858674",
"0.59855187",
"0.59480685",
"0.5923398",
"0.5886305",
"0.5816426",
"0.57496333",
"0.5493732",
"0.5432745",
"0.543212",
"0.5427583",
"0.5303993",
"0.52686906",
"0.5228986",
"0.5225155",
"0.5225155",
"0.5216393",
"0.52102643",
"0.51840276",
"0.51790005",
"0.5169646",
"0.51596546",
"0.51576513",
"0.51374656",
"0.5130264",
"0.5118746",
"0.5085286",
"0.50657594",
"0.50594914",
"0.5039574",
"0.5010261",
"0.5008153",
"0.49822462",
"0.49787396",
"0.49483988",
"0.4944404",
"0.4935781",
"0.49264783",
"0.49238142",
"0.49045193",
"0.49000883",
"0.48965698",
"0.48958254",
"0.48666215",
"0.48612016",
"0.48510563",
"0.48441002",
"0.48391014",
"0.48295456",
"0.48162726",
"0.48161674",
"0.48161536",
"0.48152795",
"0.48030084",
"0.48030084",
"0.48030084",
"0.4799635",
"0.47924063",
"0.47855482",
"0.4760575",
"0.4743672",
"0.47411305",
"0.4720817",
"0.46963733",
"0.46929127",
"0.4687429",
"0.46834236",
"0.46800223",
"0.4676789",
"0.46764517",
"0.46751797",
"0.4673745",
"0.4668241",
"0.46595258",
"0.46500346",
"0.46431375",
"0.4633642",
"0.46317884",
"0.46298116",
"0.46297714",
"0.46229145",
"0.46153957",
"0.46142888",
"0.4599559",
"0.45941523",
"0.4584975",
"0.45847693",
"0.45707887",
"0.45702934",
"0.45695326",
"0.4565463",
"0.45601976"
] | 0.0 | -1 |
TODO Autogenerated method stub System.out.println("Haola mundo"); ejemploIterable(args); ejemploFlatMap(); ejemploToString(); ejemploToCollectList(); ejemploUsuarioComentariosFlatMap(); ejemploUsuarioComentariosZipWith(); ejemploZipWithFormaRangos(); ejemploInterval(); | @Override
public void run(String... args) throws Exception {
ejemploDelayELements();
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void ejemploIterable(String... args) throws Exception {\n\n\t\tList<String> usuariosList = new ArrayList<>();\n\t\tusuariosList.add(\"Bernardo Guzman\");\n\t\tusuariosList.add(\"Pepe Flores\");\n\t\tusuariosList.add(\"Eder Flores\");\n\t\tusuariosList.add(\"Julia Guzman\");\n\t\tusuariosList.add(\"Maria Cabrera\");\n\t\tusuariosList.add(\"Bruce Lee\");\n\t\tusuariosList.add(\"Bruce Williams\");\n\n\t\tFlux<String> nombres = Flux.fromIterable(usuariosList);\n\n\t\tFlux<Usuario> usuarios = nombres\n\t\t\t\t.map(elemento -> new Usuario(elemento.split(\" \")[0].toUpperCase(),\n\t\t\t\t\t\telemento.split(\" \")[1].toUpperCase()))\n\t\t\t\t.filter(f -> f.getNombre().contains(\"B\")).doOnNext(usuario -> {\n\t\t\t\t\tif (usuario == null) {\n\t\t\t\t\t\tthrow new RuntimeException(\"El nombre no puede estár vacio\");\n\t\t\t\t\t}\n\t\t\t\t\tSystem.out.println(usuario.toString());\n\t\t\t\t}).map(usuario -> {\n\t\t\t\t\tString nombre = usuario.getNombre().toLowerCase();\n\t\t\t\t\tusuario.setNombre(nombre);\n\t\t\t\t\treturn usuario;\n\t\t\t\t})\n\n\t\t;\n\n\t\tusuarios.subscribe(e -> log.info(e.toString()), err -> log.error(err.getMessage()),\n\n\t\t\t\tnew Runnable() {\n\n\t\t\t\t\t@Override\n\t\t\t\t\tpublic void run() {\n\t\t\t\t\t\t// TODO Auto-generated method stub\n\t\t\t\t\t\tlog.info(\"Se completa con éxito el observable\");\n\t\t\t\t\t}\n\t\t\t\t});\n\t}",
"public static void main(String[] args) {\r\n \r\n Generico <String,Integer,String,Double> c=new Generico<>(\"Eduardo\",25,\"Dani\",25.0);\r\n c.mostrar();\r\n List<Generico<String,Integer,String,String>>lista = new ArrayList<>();\r\n lista.add(new Generico<String,Integer,String,String> (\"Eduardo\",25,\"Dani\",\"Hello World\"));\r\n for (Generico<String,Integer,String,String> gn: lista) {\r\n gn.mostrar();\r\n }\r\n }",
"public static void main(String[] args) {\n\t\tListaDinamica lista = new ListaDinamica();\r\n\r\n\t\tlista.adicionarInicio(5);\r\n\t\tlista.exibir();\r\n\t\tlista.adicionarInicio(1);\r\n\t\tlista.exibir();\r\n\t\tlista.adicionarFinal(16);\r\n\t\tlista.exibir();\r\n\t\tlista.adicionarFinal(2);\r\n\t\tlista.exibir();\r\n\t\tlista.removerInicio();\r\n\t\tlista.exibir();\r\n\t\tlista.removerFinal();\r\n\t\tlista.exibir();\r\n\t}",
"public static void main(String[] args) {\n\t\tEmpleado DesarrolladorJava = new Empleado(\"Julio\", 35, 60000);\n\t\tEmpleado Seguridad = new Empleado(\"Jose\", 52, 45000);\n\t\tJefe GerenteDesarrollo = new Jefe(\"Hernan\", 45, 150000);\n\n\t\tEmpleado LejagoBancario1 = Seguridad;\n\t\tEmpleado LegajoBancario2 = GerenteDesarrollo;\n\t\tEmpleado LegajoBancario3 = DesarrolladorJava;\n\n//\t\tEjemplo de herencia generica, demuestra que no funciona igual.\n\t\tPareja<Empleado> DesarrolladorReact = new Pareja<Empleado>();\n\t\tPareja<Jefe> GerenteFinanzas = new Pareja<Jefe>();\n\n//\t\tError Type mismatch: Cannot convert from Pareja<Jefe> to Pareja<Empleado> \n//\t\tPareja<Empleado> LegajoBancario4 = GerenteFinanzas;\n\n//\t\tAdmite herencia generica agregando tipos comodin en el metodo imprimirTrabajador\n\t\tPareja.imprimirTrabajador(DesarrolladorReact);\n\t\tPareja.imprimirTrabajador(GerenteFinanzas);\n\n\t}",
"public static void main(String[] args) {\n UsuarioDaoImp listar = new UsuarioDaoImp();\n List<Usuario> l = listar.listarUsuario();\n System.out.println(\"LISTA DE USUARIOS\");\n for (Usuario u : l) {\n \n System.out.println(\"------------------------\");\n System.out.println(\"Nombre: \" + u.getNombre());\n System.out.println(\"Apellido: \" + u.getApellido());\n System.out.println(\"Edad: \" + u.getEdad());\n }\n\n }",
"public static void main (String[] args) {\n\t\tC_GenericsMethods genericsMethods = new C_GenericsMethods();\n\t\tgenericsMethods.makeArrayList(\"Manish\");\n\t\tgenericsMethods.makeArrayList(\"Kumar\");\n\t\tgenericsMethods.makeArrayList(\"Samrat\");\n\t\tgenericsMethods.makeArrayList(\"Virat\");\n\t\tgenericsMethods.makeArrayList(123);\n\t\tgenericsMethods.restrciedArrayList(123);\n\t//\tgenericsMethods.restrciedArrayList(\"Virat\");\n\n\t}",
"public static void main(String[] args) {\n String argumento1 = \"bianca\";\n String argumento2 = \"amora\";\n String argumento3 = \"/bin/bash\";\n String argumento4 = \"/\";\n String argumento5 = \"/etc/apache2\";\n \n //Array List pertencendo a Collection de listas\n //Criando instancia para ArrayList\n ArrayList<String> argumentos;\n //Criando uma nova arraylist\n argumentos = new ArrayList<>();\n //Adicionando objetos tipo String, argumentos 1,2,3\n argumentos.add(argumento1);\n argumentos.add(argumento2);\n argumentos.add(argumento3);\n \n //Criando lista de argumentos2\n ArrayList<String> argumentos2 = new ArrayList<>();\n \n //Atribuindo todos os objetos da lista de argumentos1\n argumentos2.addAll(argumentos);\n //Adicionando mais argumentos 4,5\n argumentos2.add(argumento4);\n argumentos2.add(argumento5); \n \n //removendo objeto argumento1\n argumentos.remove(argumento1);\n //removendo objeto argumento1 da collection argumentos2\n argumentos2.remove(argumento1);\n \n //metodos das collections são diferentes da arrays,porém executam a mesma tarefa\n //.size() retorna a quantidade de elementos dentro de uma collection\n System.out.println(argumentos.size());\n //for usado para abreviação....\n //mesma coisa que for(int i = 0; i < argumentos.size();i++)\n //For não abreviado.\n for(int i = 0 ; i < argumentos.size(); i ++){\n System.out.println(\"for não abreviado: \" + argumentos.get(i));\n }\n //para cada argumento dentro de argumentos faça o seguinte....\n for(String argumento : argumentos){\n System.out.println(argumento);\n }\n //Percorrendo e printando collection argumentos 2\n for(String argumento : argumentos2){\n System.out.println(argumento);\n }\n \n //foreach a partir do JAVA 8 como metodo das collections\n //Faz a mesma função que os fors de cima \n //A vantagem é sobre paralelismo e mutabilidade\n argumentos.forEach(argumento -> {\n System.out.println(\"percorrrendo argumento:\" + argumento);\n });\n \n //Metodo ordena de cordo com a ordem lexical da String(Alfabetica)\n //Ordenando usando a classe Collections que é diferente da interface Collection.\n Collections.sort(argumentos);\n //Ordenando usando a classe Collections que é diferente da interface Collection.\n Collections.sort(argumentos2);\n \n argumentos.add(argumento1);\n argumentos2.add(argumento1);\n \n argumentos.forEach(argumento -> {\n System.out.println(\"Depois de ordenado argumentos1\" + argumento);\n });\n \n argumentos2.forEach(argumento -> \n {System.out.println(\"Depois de ordenado argumentos2 \" + argumento);\n });\n \n }",
"public static void main(String[] args) {\n BiFunction<String, Integer, Usuario> factory = Usuario::new;\n Usuario user1 = factory.apply(\"Henrique Schumaker\", 50);\n Usuario user2 = factory.apply(\"Humberto Schumaker\", 120);\n Usuario user3 = factory.apply(\"Hugo Schumaker\", 190);\n Usuario user4 = factory.apply(\"Hudson Schumaker\", 10);\n Usuario user5 = factory.apply(\"Gabriel Schumaker\", 90);\n Usuario user6 = factory.apply(\"Nikolas Schumaker\", 290);\n Usuario user7 = factory.apply(\"Elisabeth Schumaker\", 195);\n Usuario user8 = factory.apply(\"Eliza Schumaker\", 1000);\n Usuario user9 = factory.apply(\"Marcos Schumaker\", 100);\n Usuario user10 = factory.apply(\"Wilson Schumaker\", 1300);\n \n List<Usuario> usuarios = Arrays.asList(user1, user2, user3, user4, user5,\n user6, user7, user8, user9, user10);\n \n //filtra usuarios com + de 100 pontos\n usuarios.stream().filter(u -> u.getPontos() >100);\n \n //imprime todos\n usuarios.forEach(System.out::println);\n \n /*\n Por que na saída apareceu todos, sendo que eles não tem mais de 100 pontos? \n Ele não aplicou o ltro na lista de usuários! Isso porque o método filter, assim como os \n demais métodos da interface Stream, não alteram os elementos do stream original! É muito \n importante saber que o Stream não tem efeito colateral sobre a coleção que o originou.\n */\n }",
"public static void main(String[] args) {\n\t\tApplicationContext applicationContext=new ClassPathXmlApplicationContext(\"applicationContext.xml\");\n\t\tOdesseyService service=(OdesseyService)applicationContext.getBean(\"servicenew\");\n\t\t\n\t\t\n\t\tList<PlanetDetails> appplist=service.getPlanetDetailsService();\n\t\t//now we hae the list, if we need to iterate it, then either we can \n//\t\tdo Iterable by old way, or JAVA 8 feature forEach\n\t\n\t\t//forEach Method\n//\t\tappplist.forEach(product->System.out.println(product));\n\t\t\n\t\tappplist.forEach(System.out::println);\n\t\t\n\t\t\n\t}",
"public static void main(String[] args) {\n\n Expositores_Interface expositoresInterface = DaoFactory.construirInstanciaExpositor();\n List<Expositores> listaExpositores = expositoresInterface.listar();\n\n\n listaExpositores.stream().filter(a -> a.getEvento() == 3).forEach(a -> a.imprimirSueldo());\n\n\n\n\n }",
"public static void main(String[] args) {\r\n\t\tSomeJava8Features obj = new SomeJava8Features();\r\n\r\n\t\t// StringJoiner\r\n\t\texampleStringJoiner();\r\n\t\t\r\n\t\t// Default\r\n\t\tint ary[] = {3,6,8,9,0};\r\n\t\tSystem.out.println(\"\\nsumOfGivenIntArray ... \" + obj.sumOfGivenIntArray(ary));\r\n\t\tobj.sayMore(\"Hello Rohini\");\r\n\t\t\r\n\t\t// ForEach & Lambda Expression\r\n\t\texampleForEach_FindMaximum(ary);\r\n\t\t\r\n\r\n\t}",
"public static void main(String[] args) {\n\t\tcontato = new Contato();\n\t\ttry {\n\t\t\tcontato.RecuperarLista();\n\t\t} catch (IOException e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t}\n\t}",
"public static void main(String[] args) {\n\t\t\r\n\t\tCoordenadasJSON coords = CoordenadasJSON.leerJSON(\"src/Coordenadas.JSON\");\r\n//\t\tfor(int i=0; i<coords.tamanio(); i++){\r\n//\t\t\tSystem.out.println(coords.dame(i));\r\n//\t\t}\r\n\t\t\r\n\t\tfor(Coordenada c:coords.getIterable()){\r\n\t\t\tSystem.out.println(c);\r\n\t\t}\r\n\t\t\r\n\t\t\r\n\t}",
"public static void main(String[] args) {\n List<Coffee> list = new ArrayList<Coffee>();\n Fill.fill(Adapter.collectionAdapter(list), Coffee.class, 3);\n Fill.fill(Adapter.collectionAdapter(list), Latte.class, 3);\n for(Coffee c : list)\n \tSystem.out.println(c);\n Coffee[] array = new Coffee[5];\n Fill.fill(Adapter.arrayAdapter(array), Americano.class, array.length);\n for(Coffee c : array)\n \tSystem.out.println(c);\n\t}",
"public Iterator<IPessoa> getAtores();",
"public static void main(String args[])\n {\n AlumnosListaApp lista = new AlumnosListaApp();\n\n // Inicializar alumnos de la lista y llenarlos\n for(int i = 0; i < lista.alumnos.length; i++ ) {\n lista.alumnos[i] = new Alumno();\n lista.alumnos[i].leerDatos();\n }\n\n // desplegarDatos\n for(int i = 0; i < lista.alumnos.length; i++ ) {\n lista.alumnos[i].desplegarDatos();\n }\n }",
"public static void main(String[] args) {\n\tlistasimple lista;\n\tlista = new listasimple();\n\tfor(int i=0; i<8; i++){\n\t\tlista.insertarDatos(i);\n\t\tlista.mostrarDatos();\n\t}\n}",
"public static void main(String[] args) {\n\n\n InterfaceMetodoComunes miSalida1,misalida2,misalida3,miEntrada1,miEntrada2;\n\n miSalida1= FactoriaDeSalidas.getProductoSalida(FactoriaDeSalidas.CONSOLA);\n miSalida1.visualizar(\"Hola que tal estas\");\n\n misalida2=FactoriaDeSalidas.getProductoSalida(FactoriaDeSalidas.VENTANA);\n misalida2.visualizar(\"Bien\");\n\n misalida3=FactoriaDeSalidas.getProductoSalida(FactoriaDeSalidas.IMPRESORA);\n misalida3.visualizar(\"Imprimiendo por la impresora\");\n\n miEntrada1= FactoriaDeEntradas.getProductoEntrada(FactoriaDeEntradas.CONSOLA);\n miEntrada1.introducirDatos();\n\n miEntrada2=FactoriaDeEntradas.getProductoEntrada(FactoriaDeEntradas.VENTANA);\n miEntrada2.introducirDatos();\n }",
"public static void main(String[] args) {\n\n\t\t\n\t\t\n\t\tAutor autor = new Autor();\n\t\tautor.setNomeDoAutor(\"Luiz Caudas\");\n\t\t\n\t\t\n\t\tLivroFisico livro1 = new LivroFisico(autor);\n\t\tlivro1.setValor(40.00);\n\t\t\n\t\t\n\t\tEbook ebook1 = new Ebook(autor);\n\t\tebook1.setValor(20.00);\n\t\t\n\t\tList<Produto> produtos = Arrays.asList(livro1, ebook1);\n\t\t\n\t\tCollections.sort(produtos);\n\t\t\n\t\t\n\t\t//enhanced-for\n\t\t//for(Produto produto : produtos){\n\t\t//\tSystem.out.println(produto.getValor());\n\t\t//}\n\t\t\n\t\t//forEach dojava 8\n\t\tprodutos.forEach(l-> System.out.println(l.getValor()));\n\t\t\n\t}",
"public static void main(String[] args) {\n\t\tGestorUsuario gu = new GestorUsuario();\n\t\tScanner nombreObjeto = new Scanner(System.in);\n\t\tint nia = nombreObjeto.nextInt();\n\t\tnombreObjeto.close();\n\t\t//gu.guardarUsuarioJSON(nia);\n\t\t// gu.guardarUsuarioXML(nia, parser);\n\t\tgu.guardarUsuariosXML();\n\t\t//gu.imprimirUsuario(171);\n\t\t//gu.imprimirUsuarios();\n\t}",
"public static void main(String[] args) {\n\t\t\n\t\tFacturacion lista = new Facturacion(1, \"Ordenador\", 200);\n\t\t\n\t\tSystem.out.println(lista.getImporteConIva());\n\n\t}",
"public static void main(String[] args) {\n\t\t Supplier<Personne> supplier = Personne::new;\n\t\t System.out.println(supplier.get());\n\t\t \n\t\t //constructeur avec plusieur parametre \n\t\t PersonneSupplier supplierP = Personne::new;\n\t\t Personne personne = supplierP.creerInstance(\"nom1\", \"prenom1\");\n\t\t System.out.println(personne);\n\t\t \n\t\t PersonneSupplier supplierP1 = (nom, prenom) -> new Personne(nom, prenom);\n\t\t Personne personneP1 = supplierP1.creerInstance(\"nom1\", \"prenom1\");\n\t\t System.out.println(personneP1);\n\t\t \n\t\t \n\t\t Supplier<Personne> supplier0 = () -> new Personne();\n\t\t Supplier<Personne> supplier1 = () -> new Personne(\"\",\"\");\n\t\t \n\t\t //Supplier<Integer> I0 = Integer::new;\n\t\t Supplier<Integer> I1 = () -> new Integer(0);\n\t\t //Supplier<String> I2 =(String s) -> new Integer(s);\n\t\t \n\t\t Supplier<ArrayList<Personne>> supplier5 = ArrayList<Personne>::new;\n\t\t Supplier<ArrayList<Personne>> supplier6 = () -> new ArrayList<Personne>(); \n\t\t \n\t\t //Supplier<String[]> supplier7 = String[]::new;\n\t\t //Supplier<> supplier8 = (int size) -> new String[size];\n\t\t \n\t\t \n\t\t //generic\n\t\t //MaFabrique<Integer[]> fabrique = Integer[]::new; \n\t\t //Integer[] entiers = fabrique.creerInstance(10);\n\t\t //System.out.println(\"taille = \"+entiers.length);\n\t\t \n\t\t \n\t\t \n\t\t }",
"List<Oficios> buscarActivas();",
"public static void main(String[] args) {\n\t\t\t\n\t\t\tUsuarioDAO uDao = new UsuarioDAO();\n\t\t\tSeccionDAO sD = new SeccionDAO();\n\t\t\tItemDAO iD = new ItemDAO();\n\t\t\t\n\t\t\tFormularioDAO fD = new FormularioDAO();\n\t\t\t\n\t\t\tfor (Formulario frm : fD.buscarFormulariosUsuario(((Usuario)uDao.login(\"Anthony3064\", \"123456\")))) {\n\t\t\t\tSystem.out.println(frm.getNombre());\n\t\t\t\n\t\t\t\tfor (Seccion s : frm.GetSecciones()) {\n\t\t\t\t\tSystem.out.println(s.getPregunta());\n\t\t\t\t\tfor (Item item : s.getItem()) {\n\t\t\t\t\t\tSystem.out.println(item.getDefaultName());\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t\n\t\t\t}\n\t\t\t\n\t\t\tfD.stopEntityManagerFactory();\n\t\t\t\n\t\t\n\t\t\tSystem.out.println(fD.GetList());\n\t\n\t\t\t\n\t}",
"public static void main(String[] args) {\n\t\t\t\n\t\t\tUsuarioDAO uDao = new UsuarioDAO();\n\t\t\tSeccionDAO sD = new SeccionDAO();\n\t\t\tItemDAO iD = new ItemDAO();\n\t\t\t\n\t\t\tFormularioDAO fD = new FormularioDAO();\n\t\t\t\n\t\t\tfor (Formulario frm : fD.buscarFormulariosUsuario(((Usuario)uDao.login(\"Anthony3064\", \"123456\")))) {\n\t\t\t\tSystem.out.println(frm.getNombre());\n\t\t\t\n\t\t\t\tfor (Seccion s : frm.GetSecciones()) {\n\t\t\t\t\tSystem.out.println(s.getPregunta());\n\t\t\t\t\tfor (Item item : s.getItem()) {\n\t\t\t\t\t\tSystem.out.println(item.getDefaultName());\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t\n\t\t\t}\n\t\t\t\n\t\t\tfD.stopEntityManagerFactory();\n\t\t\t\n\t\t\n\t\t\tSystem.out.println(fD.GetList());\n\t\n\t\t\t\n\t}",
"public static void main(String[] args) {\n\t\tlistar();\n\t\t\n\t}",
"public static void main(String[] args) {\n GeneracionDatos generacionDatos = new GeneracionDatos();\n generacionDatos.creacionBarcos();\n generacionDatos.creacionAlquileres();\n\n Calculos calculos = new Calculos();\n\n //Muestra de datos calculados\n System.out.println(\"Alquiler mayor: \" + calculos.mayorAlquiler(generacionDatos.getAlquileres()));\n System.out.println(\"\");\n System.out.println(\"Alquiler menor: \" + calculos.menorAlquiler(generacionDatos.getAlquileres()));\n System.out.println(\"\");\n System.out.println(\"Promedios mensuales: \"); calculos.promedioMensual(generacionDatos.getAlquileres());\n System.out.println(\"\");\n System.out.println(\"Promedio anual: \" + calculos.promedioAnual(generacionDatos.getAlquileres()));\n }",
"public static void main(String[] args) {\n\t\tArrayList<Object> arrayList = new ArrayList<>();\n\n\t\tarrayList.add(25);\n\t\tarrayList.add(56);\n\t\tarrayList.add(25);\n\t\tarrayList.add(12);\n\t\tarrayList.add(10);\n\t\tarrayList.add(21);\n\t\tarrayList.add(9);\n\t\tprintForEach(arrayList);\n\n//\t\tConnectToSqlDB.connectToSqlDatabase() = new ConnectToSqlDB();\n//\n//\t\tconn.(arrayList, \"User\", \"Name\");\n//\t\tab.readDataBase(\"User\",\"Name\");\n\t}",
"public static void main(String[] args) {\n rellenarDatos();\n \n //ejercicio01();\n //ejercicio02();\n ejercicio03();\n }",
"public static void main(String[] args) throws Exception {\n \n Agenda agenda = new Agenda(new ArrayList<Contato>(){\n {\n add(new Contato(\"Malu\", 123));\n add(new Contato(\"xalala\", 456));\n }\n });\n\n //Adiciona na agenda\n agenda.adicionaContato(new Contato(\"xixixi\", 1515));\n \n agenda.exibeListaContato();\n\n Agenda agenda2 = new Agenda();\n agenda2.adicionaContato(new Contato(\"Matheus\", 456456));\n agenda2.exibeListaContato();\n\n }",
"public static void main(String[] args){\n\t\tAlumno a1 = new Alumno(\"aa\",\"AA\",1,2,3);\n\t\tAlumno a2 = new Alumno(\"bb\",\"BB\",4,5,6);\n\t\t\n\t\tArrayList<Alumno> alumnos = new ArrayList<Alumno>();\n\t\talumnos.add(a1);\n\t\talumnos.add(a2);\n\t\t\n\t\tPractica_AD_1_9 prueba = new Practica_AD_1_9();\n\t\tprueba.escribirObjetos(alumnos);\n\t\tprueba.leerObjetos();\n\t}",
"@Parameters\n // Método public static que devuelve un elemento iterable de array de objetos\n public static Iterable<Object[]> getData() {\n return Arrays.asList(new Object[][] {\n // Indicamos todas las pruebas {a, b, esperado}\n { 3, 1, 4 }, { 2, 3, 5 }, { 3, 3, 6 } });\n }",
"public static void main(String[] args) {\n\t\t\n\t\tClasseGenerique<String, Double, Float> objet = new ClasseGenerique<String, Double, Float>(\"aaa\", 12515754575536687454.25, 1.3f);\n\t\tClasseGenerique<Float, String, Float> objet2 = new ClasseGenerique<Float, String, Float>(1.5f, \"bbb\", 9.4f);\n\t\tClasseGenerique<String, String, Integer> objet3 = new ClasseGenerique<String, String, Integer>(\"ccc\", \"ddd\", 36);\n\t\t\n\t\tSystem.out.println(objet);\n\t\tSystem.out.println(\"-----------------------------------------------------------\");\n\t\tSystem.out.println(objet2);\n\t\tSystem.out.println(\"-----------------------------------------------------------\");\n\t\tSystem.out.println(objet3);\t\n\t}",
"public static void main(String[] args) {\n\t\t\n\t\tProgramador programador = new Programador();\n\t\tprogramador.setNumeroDeMatricula(123465);\n\t\tprogramador.exibeDados();\n\t\t\n\t\tGerenteProjetos gerenteProjetos = new GerenteProjetos();\n\t\tgerenteProjetos.setNumeroDeMatricula(987);\n\t\tgerenteProjetos.exibeDados();\n\t\t\n\t\tFuncionario funcionario = new Funcionario();\n\t\tfuncionario.setNumeroDeMatricula(123);\n\t\tfuncionario.exibeDados();\n\n\t\n\t}",
"public static void main(String[] args) {\n\t\tScanner citire=new Scanner(System.in);\n\t\tArrayList<Integer> lista=new ArrayList<Integer>();\n\t\tint n, val_caut;\n\t\tSystem.out.println(\"Valoarea cautata : \");\n\t\tval_caut=citire.nextInt();\n\t\tSystem.out.println(\"Nr de elemente din lista :\");\n\t\tn=citire.nextInt();\n\t\t\n\t\tfor(int i=0;i<n;i++)\n\t\t{\n\t\t\tlista.add(i,citire.nextInt());\n\t\t}\n\t\t\n\t\tSystem.out.println(Cautare(lista,val_caut));\n\t\t\n\n\t}",
"public static void main(String[] args) {\r\n ArrayList<String> canciones = new ArrayList<>();\r\n\r\n// Le agregamos datos\r\n canciones.add(\"Canciones 1\");\r\n canciones.add(\"Canciones 2\");\r\n canciones.add(\"Canciones 3\");\r\n\r\n// Método 1\r\n System.out.println(\"Recorriendo con método 1\");\r\n for (String cancion : canciones) {\r\n System.out.println(cancion);\r\n }\r\n\r\n// Método 2\r\n System.out.println(\"Recorriendo con método 2\");\r\n for (int x = 0; x < canciones.size(); x++) {\r\n String cancion = canciones.get(x);\r\n System.out.println(cancion);\r\n }\r\n// Método 3\r\n System.out.println(\"Recorriendo con método 3\");\r\n canciones.forEach((cancion) -> {\r\n System.out.println(cancion); });\r\n }",
"public static void main(String[] args) {\n\n\t\tDatas datas = Datas.novasDatas().comDocumento(23, 8, 2018)\n\t\t\t\t.comVencimento(26, 8, 2018).comProcessamento(23, 8, 2018);\n\t\tEndereco enderecoBeneficiario = Endereco.novoEndereco()\n\t\t\t\t.comLogradouro(\"Av Portugal, 1000\")\n\t\t\t\t.comBairro(\"Bairro Jd São Luiz\").comCep(\"14020-380\")\n\t\t\t\t.comCidade(\"Ribeirão Preto\").comUf(\"SP\");\n\n\t\tBeneficiario beneficiario = Beneficiario.novoBeneficiario()\n\t\t\t\t.comNomeBeneficiario(\"Ribeirão Reef\").comAgencia(\"1824\")\n\t\t\t\t.comDigitoAgencia(\"4\").comCodigoBeneficiario(\"76000\")\n\t\t\t\t.comDigitoCodigoBeneficiario(\"5\").comNumeroConvenio(\"1207113\")\n\t\t\t\t.comCarteira(\"18\").comEndereco(enderecoBeneficiario)\n\t\t\t\t.comNossoNumero(\"9000206\");\n\n\t\tEndereco enderecoPagador = Endereco.novoEndereco()\n\t\t\t\t.comLogradouro(\"Av dos testes, 111 apto 333\")\n\t\t\t\t.comBairro(\"Bairro Teste\").comCep(\"01234-111\")\n\t\t\t\t.comCidade(\"São Paulo\").comUf(\"SP\");\n\n\t\tPagador pagador = Pagador.novoPagador().comNome(\"Tiago Ferezin\")\n\t\t\t\t.comDocumento(\"320.557.748-59\").comEndereco(enderecoPagador);\n\t\t\n\t\tBanco banco = new Santander();\n\t\t\n\t\tBoleto boleto = Boleto.novoBoleto() \n .comBanco(banco) \n .comDatas(datas) \n .comBeneficiario(beneficiario) \n .comPagador(pagador) \n .comValorBoleto(\"200.00\") \n .comNumeroDoDocumento(\"1234\").comLocaisDePagamento(\"local 1\", \"local 2\"); \n\t\t\n\t\tGeradorDeBoleto gerador = new GeradorDeBoleto(boleto);\n\t\tgerador.geraPDF(\"Pedido-12355.pdf\");\n\t\tbyte[] bPDF = gerador.geraPDF(); \n\t\t\n\t\t\n\n\n\t\ttry {\n\t\t\tMercadoPago.SDK.setClientId(CLIENT_ID);\n\t\t\tMercadoPago.SDK.setClientSecret(CLIENT_SECRET);\n\n\t\t\tPayment pay = new Payment();\n\n\t\t\tString id = \"4025024217\";\n\t\t\tPayment p = pay.findById(id);\n\n\t\t\tSystem.out.println(p.getDescription());\n\n\t\t} catch (MPException e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t}\n\n\t}",
"public List<Tripulante> buscarTodosTripulantes();",
"public static void main(String[] args) {\n\t\tList<Employee> employeesList = StreamGetListOfEmployees.getListOfEmployees();\n\t\tList<String> employeeNames = employeesList.stream()\n .map(e -> e.getName())\n .collect(Collectors.toList());\n\t\tSystem.out.println(employeeNames);\n\t\t\n\t\t/**\n\t\t * You can also use map even if it produces result of same type.\n\t\t\t* In case, you want employee name in uppercase, you can use another map()\n\t\t\t* function to convert string to uppercase.\n\t\t */\n\t\temployeeNames = employeesList.stream()\n .map(e -> e.getName())\n .map(s -> s.toUpperCase())\n .collect(Collectors.toList());\n\t\tSystem.out.println(employeeNames);\n\t\t\n\t\t/**\n\t\t * FLAT MAP\n\t\t */\n\t\tList<String> listOfCities = employeesList.stream()\n .flatMap(e -> e.getListOfCities().stream())\n .collect(Collectors.toList());\n\n\t\tSystem.out.println(\"listOfCities: \" +listOfCities);\n\n\t\t//Output\n\t\t//listOfCities: [Newyork, Banglore, Paris, London, Pune, Seattle, Chennai, Hyderabad]\n\t}",
"public static void main(final String[] args)\n {\n final Supplier<ArrayList<String>> proveedor = ArrayList::new;\n\n // Aqui tenemos el acumulador, el que añadira cada elemento del stream al proveedor definido\n // arriba\n // BiConsumer<ArrayList<String>, String> acumulador = (list, str) -> list.add(str);\n final BiConsumer<ArrayList<String>, String> acumulador = ArrayList::add;\n\n // Aquí tenemos el combinador, ya que por ejemplo al usar parallelStream, cada hijo generara\n // su propio proveedor, y al final deberan combinarse\n final BiConsumer<ArrayList<String>, ArrayList<String>> combinador = ArrayList::addAll;\n\n final List<Empleado> empleados = Empleado.empleados();\n final List<String> listNom = empleados.stream()\n .map(Empleado::getNombre)\n .collect(ArrayList::new, ArrayList::add, ArrayList::addAll);\n System.out.println(listNom);\n\n // Usando Collectors\n final List<String> listNom2 = empleados.stream()\n .map(Empleado::getNombre)\n .collect(Collectors.toList());\n System.out.println(listNom2);\n\n final Set<String> listNom3 = empleados.stream()\n .map(Empleado::getNombre)\n .collect(Collectors.toSet());\n System.out.println(listNom3);\n\n final Collection<String> listNom4 = empleados.stream()\n .map(Empleado::getNombre)\n .collect(Collectors.toCollection(TreeSet::new));\n System.out.println(listNom4);\n\n // Ahora con mapas\n final Map<Long, String> map = empleados.stream()\n .collect(Collectors.toMap(Empleado::getId, Empleado::getNombre));\n System.out.println(map);\n\n final Map<Genero, String> map2 = empleados.stream()\n .collect(Collectors.toMap(Empleado::getGenero, Empleado::getNombre,\n (nom1,\n nom2) -> String.join(\", \", nom1, nom2)));\n System.out.println(map2);\n }",
"public static void main(String[] args) {\n\t\tCarroAlugavel carroAlugavel = new CarroAlugavel();\n\t\tCarro carroAlugado = carroAlugavel.getCarroDisponivel();\n\t\tSystem.out.println(\"Usando o carro por um mês\");\n\t\tcarroAlugavel.devolverCarro(carroAlugado);\n\n\t}",
"public static void main(String[] args) {\n\t\tint[] arr= {1,2,3};\n\t\tfunc(\"abc\",\"\",0);\n\t\tIterator i=list.iterator();\n\t\twhile(i.hasNext()) {\n\t\t\tSystem.out.println(i.next().toString());\n\t\t}\n\t\t\n\t}",
"public static void main(String[] args) {\n\t\tPersona p1 = context.getBean(\"personaBean\",Persona.class);\n\t\tPersona p2 = context.getBean(\"personaBean\",Persona.class);\n\t\tPersona p3 = context.getBean(\"personaBean\",Persona.class);\n\t\t//el ciclo de vida de essas personas depende de nosotros\n\t\t\n\t\tList<Persona> listaPersonas = context.getBean(\"listaPersonas\", List.class);\n\t\tlistaPersonas.add(p1);\n\t\tlistaPersonas.add(p2);\n\t\tlistaPersonas.add(p3);\n\t\t\n\t\tPersona carlos = context.getBean(\"carlos\",Persona.class);\n\t\tSystem.out.println(carlos);\n\t\t\n\t}",
"public static void main(String args []){\n Vista miVista=new Vista();\n ListaEstudiantes miListaEstudiantes=new ListaEstudiantes();\n Grupo miGrupo=new Grupo();\n Controlador miControlador=new Controlador(miVista,miListaEstudiantes,miGrupo);\n miControlador.iniciar();\n\n }",
"public static void main(String[] args) throws IOException, IllegalAccessException, ClassNotFoundException, InstantiationException, SQLException, Exception {\n \n GestionFamiliaProducto gm=new GestionFamiliaProducto();\n ArrayList<FamiliaProducto> lista=gm.listar();\n \n for (int i = 0; i < lista.size(); i++) {\n System.out.println(\"Ro: \"+lista.get(i).getN_idfamilia());\n }\n \n }",
"public static void main(String[] args) {\r\n\r\n Operatii o1 = new Operatii();\r\n o1.constructor();\r\n o1.print_bilete();\r\n o1.sorteaza();\r\n o1.print_bilete();\r\n o1.preturi_categorii();\r\n o1.pret_total();\r\n o1.plata_grup();\r\n o1.tag_id();\r\n o1.tag_id();\r\n o1.tag_id();\r\n o1.print_lista();\r\n o1.pret_lista();\r\n o1.plata();\r\n\r\n }",
"public static void main(String[] args) {\n\t\tPersona objPerUno = new Persona(\"yo\", 1, 20);\n\t\tPersona objPerDos = new Persona(\"yo2\", 10, 30);\n\t\tPersona objPerTres = new Persona(\"yo3\", 2, 40);\n\t\tPersona objPerCuatro = new Persona(\"yo4\", 5, 50);\n\t\t\n\t\tLinkedList<Persona> objLista = new LinkedList<Persona>();\n\t\tobjLista.add(objPerUno);\n\t\tobjLista.add(objPerDos);\n\t\tobjLista.add(objPerTres);\n\t\tobjLista.add(objPerCuatro);\n\t\t\n\t\tMap<Integer, Persona> mapPersonas = PersonasUtil.getPersonas(objLista);\n\t\tmapPersonas.forEach((clave, valor) -> System.out.println(\"Clave: \" + clave + \" | Valor: \" + valor));\n\t\t\n\t\tPersonasUtil.ordenarPersonas(objLista);\n\t}",
"public static void main(String[] args) {\n \r\n \r\n AluguelDaoMongodb adm = new AluguelDaoMongodb();\r\n \r\n adm.listAll().forEach(a -> System.out.println(a.toString()));\r\n }",
"public static void main(String[] args) {\n IAcessoDatos datos = new ImplementacionMySql();\n //datos.listar();\n imprimir(datos);\n \n datos = new ImplementacionOracle();\n //datos.listar();\n imprimir(datos);\n }",
"public static void main(String[] args) {\n\t\tConsola consola = ConsolaTeclado.getConsola();\n\t\t\n\t\t//Cargo una lista de jugadores\n\t\tList <Jugador> jugadores = new LinkedList<Jugador>();\n\t\tjugadores.add(new Jugador(\"J1\"));\n\t\tjugadores.add(new Jugador(\"J2\"));\n\t\tjugadores.add(new Jugador(\"J3\"));\n\t\tjugadores.add(new Jugador(\"J4\"));\n\t\t\n\t\t//Juego j = new JuegoSupervivencia( consola, jugadores);\n\t\tJuego j = new JuegoConquista(consola,jugadores);\n\t\t\n\t\tj.jugar();\n\t\t\n\t\t//\n\t\t\n\t\tconsola.finalizar();\n\t}",
"public static void main(String[] args) {\r\n\t\t\t\r\n\t\t\tDocumentoDao docDao = new DocumentoDao();\r\n\t\t\t\r\n\t\t\t//docDao.salvarDocumento(nt);\r\n\t\t\t\r\n\t\t\t\r\n\t\t\t\r\n\t\t\tList<Documento> list = docDao.listarParecerNotaTecnica(\"\");\r\n\t\t\t\r\n\t\t\tfor (Documento doc : list) {\r\n\t\t\t\tSystem.out.println(doc.getDocNumeracao());\r\n\t\t\t}\r\n\r\n\t}",
"public static void main(String[] args) {\n\t\t\n\tMenge<Integer> zahlen = new Menge<>(Arrays.asList(1,2,3));\n\tMenge<String> strings = new Menge<>(Arrays.asList(\"a\",\"b\",\"c\",\"d\"));\n\t\n\tMenge<Dupel<Integer, String>> cp = zahlen.cartesischesProdukt(strings);\n\t\n\tfor(Dupel<Integer,String> dupel : cp) {\n\t\tSystem.out.println(dupel);\n\t}\n\n\t}",
"public static void main(String[] args) {\n Individuos individuo1 = new Individuos(\"Mike Courts\",1511111111,33786890,\"Doblas 528\");\n Empresa empresa1 = new Empresa(\"Tiarg\", 1522222222, 3333333, 20, \"Belgrano\");\n\n\n Diario MonroeStreetJournal = new Diario();\n MonroeStreetJournal.agregarReceptor(individuo1);\n MonroeStreetJournal.agregarReceptor(empresa1);\n MonroeStreetJournal.notificarReceptores();\n\n }",
"public static void main(String[] args) {\n\t\t//Até o java 7\n\t\tnew Thread(new Runnable() {\n\n\t\t @Override\n\t\t public void run() {\n\t\t System.out.println(\"Executando um Runnable\");\n\t\t }\n\n\t\t}).start();\n\t\t//A partir do java 8\n\t\tnew Thread(() -> System.out.println(\"Executando um Runnable\")).start();\n\t\t\n\t\t//iterando com java 8: classe anonima\n\t\ttexto.forEach(new Consumer<String>() {\n\t\t public void accept(String s) {\n\t\t System.out.println(s);\n\t\t }\n\t\t});\n\t\t//iterando com java 8: lambda\n\t\t//Essa sintaxe funciona para qualquer interface \n\t\t//que tenha apenas um método abstrato\n\t\ttexto.forEach((String s) -> {\n\t\t System.out.println(s);\n\t\t});\n\t\t//ou\n\t\ttexto.forEach((s) -> {\n\t\t System.out.println(s);\n\t\t});\n\t\t//ou\n\t\ttexto.forEach(s -> {\n\t\t System.out.println(s);\n\t\t});\n\t\t//ou\n\t\ttexto.forEach(s -> System.out.println(s));\n\t\t// Uma interface que possui apenas um método abstrato \n\t\t//é agora conhecida como interface funcional e pode ser utilizada dessa forma\n\t\t\n\t\t//Outro exemplo é o próprio Comparator. Se utilizarmos a forma \n\t\t//de classe anônima, teremos essa situação: \n\t\ttexto.sort(new Comparator<String>() {\n\t\t public int compare(String s1, String s2) {\n\t\t if (s1.length() < s2.length())\n\t\t return -1;\n\t\t if (s1.length() > s2.length())\n\t\t return 1;\n\t\t return 0;\n\t\t }\n\t\t});\n\t\t//ou com lambda\n\t\ttexto.sort((s1, s2) -> {\n\t\t if (s1.length() < s2.length())\n\t\t return -1;\n\t\t if (s1.length() > s2.length())\n\t\t return 1;\n\t\t return 0;\n\t\t});\n\t\t//ou\n\t\ttexto.sort((s1, s2) -> {\n\t\t return Integer.compare(s1.length(), s2.length());\n\t\t});\n\t\t//ou como há apenas um único statement, podemos remover as chaves\n\t\ttexto.sort((s1, s2) -> Integer.compare(s1.length(), s2.length()));\n\t}",
"public static void main(String[] args) {\n\n\t\tint argolas = 8;\n\t\tencheTorre(argolas, torre01);\n\n\t\tSystem.out.println(resolve(argolas, torre01, torre02, torre03) + \" passos.\");\n\t}",
"public void setAtores(Iterator<IPessoa> atores);",
"public static void main(String[] args) {\n//\t\tcrearNodos(cantNodos);\n//\t\tlista.extractFront();\n//\t\tlista.extractLast();\n//\t\tlista.insertLast(33);\n//\t\tlista.imprimir();\n//\t\t//System.out.print(lista.get(0));\n//\t\t\n//\t\tIterator<Integer> it1 = lista.iterator();\n//\t\t\twhile(it1.hasNext()) {\n//\t\t\t\tint valor = it1.next();\n//\t\t\t\tSystem.out.println(valor);\n//\t\t\t}\n//\t\tMyIterator<Integer> it2 = lista.iteratorReverse();\n//\t\t\twhile(it2.hasNext()) {\n//\t\t\t\tint valor = it2.back();\n//\t\t\t\tSystem.out.println(valor);\n//\t\t\t}\n\n\t\tlistaDeso1.insertFront(4);\n\t\tlistaDeso1.insertFront(2);\n\t\tlistaDeso1.insertFront(13);\n\t\tlistaDeso1.insertFront(7);\n\t\tlistaDeso1.insertFront(6);\n\n\t\tlistaDeso2.insertFront(9);\n\t\tlistaDeso2.insertFront(4);\n\t\tlistaDeso2.insertFront(6);\n\t\tlistaDeso2.insertFront(5);\n\t\tlistaDeso2.insertFront(13);\n\n//\t\tlistaOrde1.insertFront(2);\n//\t\tlistaOrde1.insertFront(4);\n//\t\tlistaOrde1.insertFront(6);\n//\t\tlistaOrde1.insertFront(8);\n//\t\tlistaOrde1.insertFront(11);\n//\t\t\n//\t\tlistaOrde2.insertFront(1);\n//\t\tlistaOrde2.insertFront(4);\n//\t\tlistaOrde2.insertFront(9);\n//\t\tlistaOrde2.insertFront(11);\n//\t\tlistaOrde2.insertFront(15);\n\t\t\n\t\tEje6<Integer> ord = new Eje6<Integer>();\n\t\t\n\t\tlista=ord.ambasDeso(listaDeso1, listaDeso2);\n\t}",
"public static void main(String[] args) {\n\t\tSystem.out.println(RepositorioPersona.consultar(\"\", \"\", \"\", null, \"\"));\n\t\t// System.out.println(getTelefonos(\"Usuario2\", \"12345678X\"));\n\t}",
"public static void main(String[] args) {\n\t\tEmpleados emple1 = new Empleados(\"Paco\");\n\t\tEmpleados emple2 = new Empleados(\"Pablo\");\n\t\tEmpleados emple3 = new Empleados(\"Patron\");\n\t\tEmpleados emple4 = new Empleados(\"JUJUS\");\n\n\t\temple1.CambioSeccions(\"Ventas\");\n\n\t\tSystem.out.println(emple1.DevuelveDatos());\n\n\t\tSystem.out.println(emple2.DevuelveDatos());\n\n\t\tSystem.out.println(emple3.DevuelveDatos());\n\t\t\n\t\tSystem.out.println(emple4.DevuelveDatos());\n\t\t\n\t\tSystem.out.println(Empleados.dameIdSiguiente());\n\t\t\n\t\n\t}",
"public static void main(String[] args) {\n\t\t\n\t\tLocalDateTime ora = LocalDateTime.of(2018, 04, 19, 23, 45, 00);\n\t\t\n\t\tSpettacolo s = new Spettacolo(\"cavie\", ora);\n\t\tBiglietto b1 = new Biglietto(s);\n\t\tBiglietteria b = new Biglietteria();\n\t\tMascherina m = new Mascherina();\n\t\t\n\t\tBiglietto b2 = new Biglietto(s);\n\t\t\n\t\tb.biglietti.add(b1);\n\t\tb.biglietti.add(b2);\n\t\t\n\t\tb.vendiBiglietto(s, ora, 2);\n\t\tb.vendiBiglietto(s, ora, 2);\n\t\tb.vendiBiglietto(s, ora, 2);\n\t\t\n\t\tm.spettacoli.add(s);\n\n\t\tm.avvia(b1);\n\t\t\n\t\t\n\t\tSpettacolo s2 = new Spettacolo(\"Metropolis\", ora);\n\t\tSpettacolo s3 = new Spettacolo(\"Oasis\", ora);\n\t\tBiglietto b3 = new Biglietto(s3);\n\n\t\t\n\n\t\tm.spettacoli.add(s);\n\t\tm.mostrainfo(b1);\n\t\tm.mostrainfo(b2);\n\t\tm.mostrainfo(b3);\n\n\t\t\n\t}",
"public static void main(String[] args) {\n\n\n Arrays.asList(\"a\",\"b\",\"c\").forEach(e -> System.out.println(e));\n\n }",
"public static void main(String[] args) {\n List<String> myList = new ArrayList<String>();\n\n //convert args into a List<String>\n List<String> argList = Arrays.asList(args);\n myList.addAll(argList);\n\n //call third-party api which uses raw types\n ThirdPartyAPI.addElement(myList);\n\n //Iterator is now also typesafe\n Iterator<String> theArgs = myList.iterator();\n while(theArgs.hasNext()) {\n String nextArg = theArgs.next();\n }\n }",
"public static void main(String[] args) {\r\n\t\tgenera();\r\n\r\n\t}",
"private static void ejercicio1() {\n List<Integer> numeros = Arrays.asList(1, 2, 3, 4, 5);\n numeros.stream().map(numero -> Main.calculaCubo(numero)).forEach(numero -> System.out.print(numero + \" \"));\n System.out.println();\n numeros.stream().map(Main::calculaCubo).forEach(numero -> System.out.print(numero + \" \"));\n }",
"public static void main(String[] args) {\r\n rellenarDatos();\r\n mostrarTodosLosProductos();\r\n mostrarMediaGraduacionBebidasAlcoholicas();\r\n }",
"public static void main(String[] args) {\n \n empleado[] misEmpleados=new empleado[3];\n //String miArray[]=new String[3];\n \n misEmpleados[0]=new empleado(\"paco gomez\",123321,1998,12,12);\n misEmpleados[1]=new empleado(\"Johana\",28500,1998,12,17);\n misEmpleados[2]=new empleado(\"sebastian\",98500,1898,12,17);\n \n /*for (int i = 0; i < misEmpleados.length; i++) {\n misEmpleados[i].aumentoSueldo(10);\n \n }\n for (int i = 0; i < misEmpleados.length; i++) {\n System.out.println(\"nombre :\" + misEmpleados[i].dameNombre() + \" sueldo \" + misEmpleados[i].dameSueldo()+ \" fecha de alta \"\n + misEmpleados[i].dameContrato());\n }*/\n \n for (empleado e:misEmpleados) {\n e.aumentoSueldo(10);\n \n }\n for (empleado e:misEmpleados) {\n System.out.println(\"nombre :\" + e.dameNombre() + \" sueldo \" + e.dameSueldo()+ \" fecha de alta \"\n + e.dameContrato());\n \n }\n \n }",
"public static void main(String[] args) {\r\n\t\tCaixa caixa = caixaBLL.getCaixa(1);\r\n\t\tCliente cliente = clienteBLL.getCliente(1);\r\n\t\tFuncionario funcionario = funcionarioBLL.getFuncionario(1);\r\n\r\n\t\tMedicamento m1 = medicamentoBLL.getMedicamento(1);\r\n\r\n\t\tSystem.out.println(caixa);\r\n\t\tSystem.out.println(funcionario);\r\n\r\n\t\tCaixaFacade facade = new CaixaFacade(caixa, funcionario, 1000.0);\r\n\r\n\t\tSystem.out.println(facade);\r\n\r\n\t\tfacade.novoPedido();\r\n\t\tSystem.out.println(\"Produtos: \" + Arrays.toString(Pedido.getPedidoAtual().getItens().toArray()));\r\n\r\n\t\tfacade.adicionaMedicamento(m1, 7);\r\n\t\tSystem.out.println(\"Produtos: \" + Arrays.toString(Pedido.getPedidoAtual().getItens().toArray()));\r\n\r\n\t\tint pedidoId = facade.efetuaVenda();\r\n\t\tPagamento pagamento = new Dinheiro(\r\n\t\t\t\tcliente.getId(),\r\n\t\t\t\tpedidoId,\r\n\t\t\t\tPedido.getPedidoAtual().getTotal(),\r\n\t\t\t\tTipoPagamento.DINHEIRO,\r\n\t\t\t\t1000);\r\n\r\n\t\tSystem.out.println(\"Desconto: \" + pagamento.getTotalDesconto());\r\n\t\t\r\n\t\tSystem.out.println(\"ID Pedido: \" + pedidoId);\r\n\t\tSystem.out.println(\"ID Pagamento: \" + facade.realizaPagamento(pagamento));\r\n\t}",
"public static void main(String[] args) {\n\t\tCollection<Coffee> coffee = fill(\r\n\t\t\t\tnew ArrayList<Coffee>(), new CoffeeGenerator (), 4);\r\n\t\tfor(Coffee c : coffee)\r\n\t\t\tSystem.out.println(c);\r\n\t\tCollection<Integer> fnumbers = fill(\r\n\t\t\t\tnew ArrayList<Integer>(), new Fibonacci(), 12);\r\n\t\tfor(int i : fnumbers)\r\n\t\t\tSystem.out.print(i+\", \");\r\n\t}",
"public static void main(String[] args) {\n\t\tLivro l = new Livro();\n\t\tl.criaLivro(\"Estrutura de Dados\", \"Waldmar celles\", \"Academico\", 450, \"Elisilver\");\n\t\tl.fechaLivro();\n\t\tl.mostraDados();\n\t}",
"public static void main(String[] args) {\n \n int[] numeros = {56, 89, 87, 56, 45};\n \n System.out.print(\"Array no ordenado: \");\n Impresion(numeros);//impresión del array no ordenado\n System.out.println(\"\");\n System.out.println(\"\");\n \n shell(numeros);//llamada del metodo shell\n \n System.out.print(\"Array ordenado: \");\n Impresion(numeros);//impresión del array ordenado\n System.out.println(\"\");\n \n \n }",
"public static void main(String[] args) {\n\t\tApplicationContext appContext=(ApplicationContext) new ClassPathXmlApplicationContext(\"beans.xml\");\n\t\t\n\t\tEtudiant etu1=(Boursier) appContext.getBean(\"etudiant-boursier\");\n\t\tEtudiant etu2=(NonBousier) appContext.getBean(\"etudiant-non-boursier\");\n\t\tEtudiantServiceImp serviceEtudiant=(EtudiantServiceImp) appContext.getBean(\"service-etudiant\");\n\t\tClasseServiceImp serviceClasse= (ClasseServiceImp) appContext.getBean(\"service-classe\");\n\t\t\n\t\tSystem.out.println(\"etudiant boursier : \"+etu1.toString());\n\t\tSystem.out.println(\"etudiant non boursier: \"+etu2.toString());\n\t\t\n\t\t//Etudiant et=null;\n //double total=1000;\n //et=serviceEtudiant.creerEtudiantt(false);\n //serviceEtudiant.afficherNomComplet(et);\n System.out.println(\"scolarite: \"+serviceEtudiant.CalculScolarite(etu1));\n\t\t\n\n\t\t\n\t\t//List<Etudiant> etudiants = new ArrayList<Etudiant>();\n\t\t//etudiants.add(nonBEtudiant);\n\t\t//etudiants.add(boursier);\n\t\t//System.out.println(serviceClasse.SommeScollarite(etudiants));\n\t}",
"public static void main(String[] args) {\n\t\tpedirdatos();\n\t}",
"public static void main(String[] args) {\n\t\t\n\t\tList<Usuario> lista = new ArrayList<Usuario>();\n\t\t\n\t\tlista.add(new Usuario(\"Diego\"));\n\t\tlista.add(new Usuario(\"Carlos\"));\n\t\tlista.add(new Usuario(\"Maria\"));\n\t\tlista.add(new Usuario(\"Joaquin\"));\n\t\tlista.add(new Usuario(\"Rafaela\"));\n\t\t\n\t\t//Procurar apenas um usuário especifico (ID)\n\t\tSystem.out.println(\"Procura pelo ID:\");\n\t\tSystem.out.println(lista.get(3).nome);\n\t\t\n\t\t//Mostra todos os usuarios\n\t\tSystem.out.println(\"\\nTodos usuários:\");\n\t\tfor(Usuario varer: lista) {\n\t\t\tSystem.out.println(varer.nome);\n\t\t}\n\n\t}",
"public static String buscarTodosLosLibros() throws Exception{ //BUSCARtODOS no lleva argumentos\r\n //primero: nos conectamos a oracle con la clase conxion\r\n \r\n Connection con=Conexion.conectarse(\"system\",\"system\");\r\n //segundo: generamos un statemenr de sql con la conexion anterior\r\n Statement st=con.createStatement();\r\n //3: llevamos a cabo la consulta select \r\n ResultSet res=st.executeQuery(\"select * from persona\"); //reset arreglo enmutado de java estructura de datos\r\n System.out.println(\"depues del select\");\r\n int indice=0;\r\n ArrayList<persona> personas=new ArrayList<persona>();\r\n while(res.next()){ //del primero hasta el ultimo prod que vea SI PONGO SECUENCIA NO ENTRA AL WHILE\r\n Integer id= res.getInt(1); \r\n String nombre=res.getString(2);\r\n String empresa=res.getString(3);\r\n Integer edad=res.getInt(4);\r\n String telefono=res.getString(5);\r\n \r\n ///llenamos el arrayList en cada vuelta\r\n personas.add(new persona(id,nombre,empresa,edad,telefono));\r\n \r\n System.out.println(\"estoy en el array list despues del select\");\r\n }\r\n \r\n //el paso final, transformamos a objeto json con jackson\r\n ObjectMapper maper=new ObjectMapper(); //mapeo a objeto jackson\r\n \r\n st.close();\r\n con.close();\r\n System.out.println(\"convirtiendo el json\");\r\n return maper.writeValueAsString(personas);\r\n \r\n }",
"public static void main(String[] args) {\n\t\tUsuario u = new UsuarioDAO().buscaDadosUsuario(\"[email protected]\");\n\t\tSystem.out.println(\"->\"+u.getNome());\n\t\tSystem.out.println(\"-->\"+u.getMedicacoes().size());\n\t}",
"public static void main(String[] args) {\r\n\r\n\t\tString[] namen = { \"Tom\", \"Jerry\", \"Peter\", \"Paul\", \"Mary\", \"Ute\" };\r\n\t\t\r\n\t\t/*\r\n\t\t * A2.\r\n\t\t * \r\n\t\t * Klasse 'Astronaut' mit \r\n\t\t * - einem String-Attribut 'name'\r\n\t\t * - Konstruktor (das Attribut initialisieren)\r\n\t\t * - toString: return \"Austronaut \" + name;\r\n\t\t * \r\n\t\t */\r\n\t\t\r\n\t\t/*\r\n\t\t * A3.\r\n\t\t * \r\n\t\t * Bitte die Methode 'buildMannschaft' realisieren, die die List mit Astronauten erzeugt,\r\n\t\t * und Namen für die Astronauten aus dem übergebenen Array nimmt.\r\n\t\t * Der 2. Parameter beschreibt die Logik zum Bilden eines Astronauten. \r\n\t\t */\r\n\t\tList<Astronaut> listA = buildMannschaft(namen, n -> new Astronaut(n));\r\n\t\t\r\n\t\tfor (Astronaut astronaut : listA) {\r\n\t\t\tSystem.out.println(astronaut);\r\n\t\t}\r\n\t\t\r\n\t\t\r\n\t}",
"public static void main(String[] args) {\n\r\n\t\tint cantidad = leerNumero(\"Cuantos numeros quieres generar\");\r\n\t\tint[] arreglo = generaNumeros(cantidad, 0, 9);\r\n\t\tmuestraArreglo(arreglo);\r\n\t\tescribir(\"La suma de los numeros es: \" + sumarArreglo(arreglo), true);\r\n\t}",
"public static void main(String[] args) {\n\t List<Integer> al = new ArrayList<>(Arrays.asList(1,2,3,4,5,6,7,8,9,10));\n\t\t//System.out.println(al);\n\t\t\n\t\t\t\n\t\t\t\tSystem.out.println(al);\n\t\t\t\n\t\t\n\t\t\n\t\n\t}",
"public static void main(String[] args) {\r\n System.out.println(\"***debut serveur gestion ***\");\r\n new ServeurGestion(50003).fonctionnementService();\r\n \r\n }",
"public static void main(String[] args) throws Exception{\n\t\tCollection<Integer> values = new ArrayList<>();\r\n\t\tvalues.add(3);\r\n\t\tvalues.add(77);\r\n\t\tvalues.add(5);\r\n\t\t//to fetch the values we have tow ways 1. Iterator 2.enhacned for loop\r\n\t\t/*Iterator i = values.iterator();\r\n\t\twhile(i.hasNext()){\r\n\t\t\tSystem.out.println(i.next());\r\n\t\t}\r\n\t\t*/\r\n\t\t//or for each\r\n\t\tvalues.forEach(i->System.out.println(i));\r\n\r\n\r\n\r\n\r\n\t}",
"public static void main(String[] args) {\n\t\tStream st = new Stream();\r\n\t\tSystem.out.println(\">>> Filtrar <<<\");\r\n\t\tst.filtrar();\r\n\t\tSystem.out.println(\">>> Transformar <<<\");\r\n\t\tst.transformar();\r\n\t\tSystem.out.println(\">>> Ordenar <<<\");\r\n\t\tst.ordenar();\r\n\t\tSystem.out.println(\">>> Limitar <<<\");\r\n\t\tst.limitar();\r\n\t\tSystem.out.println(\">>> Contar <<<\");\r\n\t\tst.contar();\r\n\t\t\r\n\t}",
"public static void main(String[] args) {\n Practica array = new Practica();\n\n array.rellanarArray();\n array.imprimirInversamente();\n }",
"public static void main(String[] args) {\n\t\tEntityManagerFactory fabrica = Persistence.createEntityManagerFactory(\"mysql\");\n\t\t// 2. crea el manejador de entidades\n\t\tEntityManager em = fabrica.createEntityManager();\n\t\t\n\t\t//--proceso:obtener listar usuario\n\t\tSystem.out.println(\"Listado de los usuarios\");\n\t\t\n\t\tString sql=\"select u from Usuario u\";//JPA u.codigo, u.etc\n\t\t\n\t\tList<Usuario>lstUsuario = em.createQuery(sql,Usuario.class).getResultList();\n\t\t\n\t\tSystem.out.println(\"Cantidad de usuarios: \"+ lstUsuario.size());//para ver cantidad\n\t\t//para imprimir en consola el listado\n\t\tfor(Usuario u:lstUsuario) {\n\t\t\tSystem.out.println(\">>> \"+u);\n\t\t}\n\t\t\n\t\t/////////////////listado por tipo (where)////////////////////////\n\t\tSystem.out.println(\"Listado de los usuarios por tipo\");\n\t\t\n\t\tString sql2=\"select u from Usuario u where u.tipo= :xtipo\";//JPA se usa la variable de la clase y se setea una variable con setParameter\n\t\t\n\t\tTypedQuery<Usuario> query = em.createQuery(sql2,Usuario.class);//para setear varias variables en listar\n\t\tquery.setParameter(\"xtipo\", 1);\n\t\tList<Usuario>lstUsuarioxtipo = query.getResultList();\n\t\t\n\t\tSystem.out.println(\"Cantidad de usuarios: \"+ lstUsuarioxtipo.size());//para ver cantidad\n\t\t//para imprimir en consola el listado\n\t\tfor(Usuario u:lstUsuarioxtipo) {\n\t\t\tSystem.out.println(\">>> \"+u);\n\t\t}\n\t\tem.close();\n\t\t\n\t}",
"public static void main(String[] args) {\n\n\t\tDuomenuIsvedimas di = new DuomenuIsvedimas() {\n\n\t\t\t@Override\n\t\t\tpublic void out(String txt) {\n\t\t\t\tSystem.out.println(txt);\n\n\t\t\t}\n\t\t};\n\n\t\tdi.isvesti(\"asd\", null, \"qqqq\");\n\n\t}",
"public static void main(String[] args) {\n\t\tUsuario u = registro();\n\t\tSystem.out.println(\"Bienvenido \"+ u.getNombre()+\" \" + u.getApellido());\n\t}",
"public static void main(String[] args) {\n\t\tJokalaria jok= new Jokalaria();\n\t\tjok.setIdJokalaria(2544);\n\n\t\tUserLogged_Implementation appI = new UserLogged_Implementation();\n\t\tList<PuntuazioaJokalariaJardunaldia> ema = appI.JokalariarenPuntuaketak(jok);\n\t\tfor(int i=0;i<ema.size();i++) {\n\t\t\tPuntuazioaJokalariaJardunaldia p = ema.get(i);\n\t\t\tSystem.out.println(p.getJardunaldia().getHasierakoEguna()+\" \"+p.getPuntuak());\n\t\t}\n\t\t\n\t}",
"public static void main(String[] args) {\n\r\n\t\r\n\t\tImpresora impresio1=new Impresora(); //instanciar la clase Impresora\r\n\t\timpresio1.imprimir(\"Matriculacion Exitosa\", 10);\r\n\t}",
"public static void main(String[] args) {\n \n Ejemplo1 func=new Ejemplo1();\n Scanner sc=new Scanner(System.in);\n System.out.println(\"Primer Numero\");\n int n1=sc.nextInt();\n System.out.println(\"Segundo Numero\");\n int n2=sc.nextInt();\n \n func.sumaP(n1, n2);\n \n // Funciones Metodos e instancias Estudair concepto en java \n \n \n /*func.suma();\n func.resta();\n func.multiplicacion();\n func.sumaP(7, 10); */\n }",
"public static void main(String[] args){\n\n Ejercicio4 ejercicio4 = new Ejercicio4();\n\n ArrayList<Integer> resultado = ejercicio4.listaDePrimerosCienPositivos();\n\n for (Integer i = 0; i < resultado.size(); i++) {\n System.out.println(resultado.get(i));\n }\n }",
"public static void main( String[] args ) {\n\n\t\tString S = C + \": Main(): \";\n\t\tSystem.out.println( S + \"Starting\" );\n\n\t\tint xsize = 5;\n\t\tint ysize = 10;\n\n\t\tContainer2DImpl<String> con = new Container2DImpl<String>( xsize, ysize );\n\t\tfor ( int x = 0; x < xsize; x++ ) {\n\t\t\tfor ( int y = 0; y < ysize; y++ ) {\n\t\t\t\tcon.set( x, y, \"\" + x + \", \" + y );\n\t\t\t}\n\t\t}\n\n\t\tSystem.out.println( S + \"(1,1) = \" + con.get( 1, 1 ) );\n\n\t\tSystem.out.println( S );\n\t\tSystem.out.println( S );\n\t\tSystem.out.println( S + \"getRowIterator\" );\n\n\t\tListIterator<String> it = con.getRowIterator( 2 );\n\t\twhile ( it.hasNext() ) {\n\n\t\t\tString obj = it.next();\n\t\t\tSystem.out.println( S + obj.toString() );\n\t\t}\n\n\t\tSystem.out.println( S );\n\t\tSystem.out.println( S );\n\t\tSystem.out.println( S + \"getColumnIterator\" );\n\n\t\tit = con.getColumnIterator( 2 );\n\t\twhile ( it.hasNext() ) {\n\n\t\t\tString obj = it.next();\n\t\t\tSystem.out.println( S + obj.toString() );\n\n\t\t}\n\n\t\tSystem.out.println( S );\n\t\tSystem.out.println( S );\n\t\tSystem.out.println( S + \"getAllByColumnsIterator\" );\n\n\t\tit = con.getAllByColumnsIterator();\n\t\twhile ( it.hasNext() ) {\n\n\t\t\tString obj = it.next();\n\t\t\tSystem.out.println( S + obj.toString() );\n\n\t\t}\n\n\t\tSystem.out.println( S );\n\t\tSystem.out.println( S );\n\t\tSystem.out.println( S + \"getAllByRowsIterator\" );\n\n\t\tit = con.getAllByRowsIterator();\n\t\twhile ( it.hasNext() ) {\n\n\t\t\tString obj = it.next();\n\t\t\tSystem.out.println( S + obj.toString() );\n\n\t\t}\n\n\t\tSystem.out.println( S );\n\t\tSystem.out.println( S );\n\t\tSystem.out.println( S + \"List Iterator\" );\n\n\t\tit = con.listIterator();\n\t\twhile ( it.hasNext() ) {\n\n\t\t\tString obj = it.next();\n\t\t\tSystem.out.println( S + obj.toString() );\n\t\t}\n\n\t\tSystem.out.println( S + \"Ending\" );\n\n\t}",
"public static void main(String[] args){\n EmisorAcciones ea = new EmisorAcciones();\n ea.emitirAcciones();\n }",
"public ArrayList<ProductoDTO> mostrartodos() {\r\n\r\n\r\n PreparedStatement ps;\r\n ResultSet res;\r\n ArrayList<ProductoDTO> arr = new ArrayList();\r\n try {\r\n\r\n ps = conn.getConn().prepareStatement(SQL_READALL);\r\n res = ps.executeQuery();\r\n while (res.next()) {\r\n\r\n arr.add(new ProductoDTO(res.getInt(1), res.getString(2), res.getString(3), res.getInt(4), res.getInt(5), res.getString(6), res.getString(7), res.getString(8), res.getString(9)));\r\n }\r\n } catch (SQLException ex) {\r\n JOptionPane.showMessageDialog(null, \"error vuelva a intentar\");\r\n } finally {\r\n conn.cerrarconexion();\r\n\r\n }\r\n return arr;\r\n\r\n }",
"public static void main(String[] args) {\n\t\tnew CalculadoraDeGastos();\r\n\t\t\r\n\t}",
"public static void main(String[] args) {\n int[] numeros = new int[N];\n ingresar(numeros); //llamada a una funcion de tipo void\n muestra(numeros);\n }",
"public static void main(String[] args) {\n\t\tint numero = 10;\n\t\t//paradigma estructurado tipo y variable\n\t\tScanner teclado = new Scanner (System.in);\n\t\tSystem.out.println(\"Escriba algo..\");\n\t\tString ingreso = teclado.next();\n\t\tSystem.out.println(\"Hola mundo \"+ingreso);\n\t\t/**\n\t\t * Practica : funciones y procedimientos\n\t\t */\n\t\toperacion unPractico = new operacion ();\n\t\t//Funcion\n\t\tint resultado = unPractico.suma(1, 2);\n\t\tSystem.out.println(\"El resultado de la suma como es: \"+resultado);\n\t\t//Procedimiento\n\t\tunPractico.sumaSinRetorno(4,5);\n\t\t//ingreso de datos\n\t\tunPractico.restaIngreso();\n\t\t//unPractico.raizPorIngreso();\n\t}",
"@Override\n public void mostrarListadoEquipos(List<Equipo> equipos) {\n\n }",
"public static void main(String[] args) {\n ArrayList<Object> list = CollUtil.newArrayList();\n list.add(1);\n System.out.println(list.get(1));\n\n\n }",
"public static void main(String[] args) {\n\t\tint[] idades = { 1, 2, 3 };\r\n\t\t// Exibir os valores do array\r\n\t\tfor (int i = 0; i < idades.length; i++) {\r\n\t\t\tSystem.out.println(idades[i]);\r\n\t\t}\r\n\t\t// chamar o métodos teste e enviar\r\n\t\t// referência para o array\r\n\t\tteste(idades);\r\n\r\n\t\tfor (int i = 0; i < idades.length; i++) {\r\n\t\t\tSystem.out.println(idades[i]);\r\n\t\t}\r\n\t}",
"public static void main(String[] args) {\n Collection values = new ArrayList();\n values.add(5);\n values.add(6);\n\n for (Object valu : values) {\n System.out.println(valu);\n }\n\n }",
"public static void main(String[] args) throws ParseException, JAXBException {\n\t\tGerenciaSemanas gs = new GerenciaSemanas();\r\n\t\tDate dataAtual = gs.getDataAtual();\r\n\t\t\r\n\t\tLerXMLeSalvar_Visitas lerXml = new LerXMLeSalvar_Visitas();\r\n\t\t\t\t\r\n\t\t//busca a lista de empreendimentos no banco\r\n\t\tVisitasBean vb = new VisitasBean();\r\n\t\tList<Empreendimento> lista = vb.listaEmp();\r\n\t\t\t\r\n\t\tfor (Empreendimento emp : lista){\r\n\t\t\t//codigo pra iterar a lista\r\n\t\t\t\t\t\t\t\t\t\t\r\n\t\t\t\ttry {\r\n\t\t\t\t\t\r\n\t\t\t\t\tString id_emp = emp.getEMP_ID();//id do empreendimento\r\n\t\t\t\t\tString data = emp.getEMP_PRIMEIRAVISITA();//data da primeira visita\r\n\t\t\t\t\t//Date dataInicial;//variavel pra guardar a data da primeira visita numa variavel do tipo Date\r\n\t\t\t\t\tDate dataInicial = GerenciaSemanas.stringToDate(data);\r\n\t\t\t\t\t\r\n\t\t\t\t\tLOGGER.info(\"Id Emp= \" +id_emp + \" Data primeira requisição \"+ dataInicial + \" Data ultima Requisição \"+ dataAtual);\r\n\t\t\t\t\t\r\n\t\t\t\t\twhile(dataInicial.getTime() <= gs.getDataAtual().getTime()){\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\r\n\t\t\t\t\t\tChamaWS_Visitas ws = new ChamaWS_Visitas();\r\n\t\t\t\t\t\t\t\t\t\t\t\r\n\t\t\t\t\t\tSystem.out.println(\"Id Emp= \"+id_emp + \" Data pra requisição \"+ dataInicial);\r\n\t\t\t\t\t\tLOGGER.info(\"Id Emp= \"+id_emp + \" Data pra requisição \"+ dataInicial);\r\n\t\t\t\t\t\t//busca o xml\r\n\t\t\t\t\t\tws.main(id_emp, gs.dateToString(dataInicial));\r\n\t\t\t\t\t\t\t\t\t\t\t\t\r\n\t\t\t\t\t\tlerXml.main(args);\r\n\t\t\t\t\t\tvb.apagarXml();\r\n\t\t\t\t\t\tdataInicial.setDate(dataInicial.getDate()+7);//incrementa a data de condicao do while\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t}\r\n\t\t\t\t} catch (ParseException e) {\r\n\t\t\t\t\t// TODO Auto-generated catch block\r\n\t\t\t\t\t\r\n\t\t\t\t\te.printStackTrace();\r\n\t\t\t\t}\r\n\t\t\t\t\t\t\t\t\r\n\t\t\t\t\t\r\n\t\t\t}\r\n\t\t\r\n\t }",
"public static void main(String[] args) {\n\t\tCommonInterface<Integer> numericFunc = (n) -> {\n\t\t\tint result = 1;\n\t\t\tfor (int i = 1; i <= n; i++) {\n\t\t\t\tresult *= i;\n\t\t\t}\n\t\t\treturn result;\n\t\t};\n\t\tSystem.out.println(\"Factorial of 3 is: \" + numericFunc.func(3));\n\t\tSystem.out.println(\"Factorial of 5 is: \" + numericFunc.func(5));\n\t\tSystem.out.println(\"*********************************************************\");\n\n\t\t// String Reversal using Generic Functional Interface\n\t\tCommonInterface<String> stringFunc = (str) -> {\n\t\t\tString reverse = \"\";\n\t\t\tfor (int i = str.length() - 1; i >= 0; i--) {\n\t\t\t\treverse += str.charAt(i);\n\t\t\t}\n\t\t\treturn reverse;\n\t\t};\n\t\tSystem.out.println(\"The reverse of School is: \" + stringFunc.func(\"School\"));\n\t\tSystem.out.println(\"The reverse of Development is: \" + stringFunc.func(\"Development\"));\n\t\tSystem.out.println(\"*********************************************************\");\n\t}"
] | [
"0.63462126",
"0.6004636",
"0.5975732",
"0.5885893",
"0.57976586",
"0.57932585",
"0.579081",
"0.5676368",
"0.557208",
"0.5555581",
"0.5547798",
"0.5482285",
"0.54784787",
"0.5473414",
"0.5472163",
"0.5461933",
"0.5447642",
"0.5425783",
"0.5422353",
"0.54206",
"0.5400007",
"0.5363055",
"0.5342883",
"0.53263944",
"0.53263944",
"0.53263783",
"0.5326092",
"0.5294596",
"0.52893907",
"0.528449",
"0.5284424",
"0.5272827",
"0.5244064",
"0.52424806",
"0.52306664",
"0.52286625",
"0.5184579",
"0.5182711",
"0.51823664",
"0.517635",
"0.517405",
"0.5173513",
"0.5171707",
"0.51685333",
"0.51679724",
"0.5162744",
"0.51564145",
"0.5147811",
"0.51440406",
"0.51427585",
"0.51409775",
"0.5128027",
"0.5128021",
"0.5116148",
"0.51084137",
"0.510607",
"0.5105782",
"0.51048446",
"0.50982493",
"0.5092113",
"0.50907844",
"0.507763",
"0.5077193",
"0.507656",
"0.50742775",
"0.5066976",
"0.5062735",
"0.5061768",
"0.5058649",
"0.5055169",
"0.5053223",
"0.50490737",
"0.50426954",
"0.5042551",
"0.50379175",
"0.5036109",
"0.50357175",
"0.5035056",
"0.5032726",
"0.5032198",
"0.503121",
"0.5017604",
"0.50115234",
"0.49972415",
"0.49956205",
"0.49953148",
"0.49838546",
"0.4981985",
"0.49793175",
"0.4977708",
"0.49625745",
"0.4959717",
"0.4952281",
"0.49517924",
"0.49471188",
"0.49432135",
"0.494099",
"0.49397188",
"0.49348104",
"0.4934245",
"0.49336007"
] | 0.0 | -1 |
TODO Autogenerated method stub System.out.println("Haola mundo"); | public void ejemploIterable(String... args) throws Exception {
List<String> usuariosList = new ArrayList<>();
usuariosList.add("Bernardo Guzman");
usuariosList.add("Pepe Flores");
usuariosList.add("Eder Flores");
usuariosList.add("Julia Guzman");
usuariosList.add("Maria Cabrera");
usuariosList.add("Bruce Lee");
usuariosList.add("Bruce Williams");
Flux<String> nombres = Flux.fromIterable(usuariosList);
Flux<Usuario> usuarios = nombres
.map(elemento -> new Usuario(elemento.split(" ")[0].toUpperCase(),
elemento.split(" ")[1].toUpperCase()))
.filter(f -> f.getNombre().contains("B")).doOnNext(usuario -> {
if (usuario == null) {
throw new RuntimeException("El nombre no puede estár vacio");
}
System.out.println(usuario.toString());
}).map(usuario -> {
String nombre = usuario.getNombre().toLowerCase();
usuario.setNombre(nombre);
return usuario;
})
;
usuarios.subscribe(e -> log.info(e.toString()), err -> log.error(err.getMessage()),
new Runnable() {
@Override
public void run() {
// TODO Auto-generated method stub
log.info("Se completa con éxito el observable");
}
});
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@Override\r\n\tpublic void hacerSonido() {\n\t\tSystem.out.print(\"miau,miau -- o depende\");\r\n\t\t\r\n\t}",
"public void jugar_con_el() {\n System.out.println(nombre + \" esta jugando contigo :D\");\n }",
"@Override\n\tpublic void habla() {\n\t\tSystem.out.println(\"Miau, Miau!!\");\n\t}",
"@Override\n public void comunicar() {\n System.out.println(\"miauuuu\");\n\n }",
"public void estiloAcierto() {\r\n\t\t /**Bea y Jose**/\t\t\r\n \r\n\t}",
"public HolaMundo() {\n \n System.out.println( \"Hola mundo\" );\n }",
"public void comer(){\r\n\t\tSystem.out.println(\"He comido\");\r\n\t}",
"public void muere() {\n System.out.println(\"Ugh... Llegó mi hora... Adios.\");\n }",
"public static void saludo(){\n System.out.println(\"Bienvenido al Sistema\");\n }",
"@Override\n\tpublic void maasHesapla() {\n\t\tSystem.out.println(\"isciler icin maas 5000 tl \");\n \t\t\n\t}",
"public void orina() {\n System.out.println(\"Que bien me quedé! Deposito vaciado.\");\n }",
"@Override\r\n\tpublic void alimentar() {\n\t\tSystem.out.print(\" como carne, yummy, yummy\");\r\n\t}",
"public void Jomijoma()\n {\n System.out.println(\"Ami dadar jomi joma paya geci\");\n }",
"void miau() {\r\n\t\tSystem.out.println(\"Miauuuu!\");\r\n\t}",
"public void haha(){\n System.out.println(\"thavasi\");\n }",
"public void Makan()\n\t{\n\tSystem.out.println(\"Harimau Makan Daging dan minum susu\");\n\tSystem.out.println();\n\t}",
"public void ciudad(){\n System.out.println(\"ciudad londres\");\n }",
"@Override\n\tpublic void falar() {\n\t\tSystem.out.println(\"Kuack\");\n\t}",
"public void carroAgregado(){\n System.out.println(\"Su carro fue agregado con exito al sistema\");\n }",
"@Override\r\n\tpublic String sonido() {\n\t\treturn \"Miauu\";\r\n\t}",
"@Override\n\tpublic void emprestimo() {\n\n\t}",
"@Override\r\n\tpublic void horario() {\n\t\t\r\n\t}",
"public void duerme() {\n System.out.println(\"Duerme profundamentZzZzZz...\");\n }",
"@Override\n\tpublic String hablar() {\n\t\treturn \"Hola, soy un Buitre y sť volar\";\n\t}",
"public void hello(){\n\t\t\r\n \t\r\n\t\t\r\n\t}",
"private static void cajas() {\n\t\t\n\t}",
"@Override\n\tpublic void coba() {\n\t\t\n\t}",
"private void mostrarEmenta (){\n }",
"@Override\n\tpublic void HowtoEat() {\n\t\tSystem.out.println(\"Fırında Ye!!\");\n\t}",
"public void quemaRueda() {\n System.out.println(\"¡Huele a plástico quemado de tanto quemar ruedas!\");\n }",
"@Override\r\n\tpublic void mostrar() {\n\t\t\r\n\t}",
"@Override\n\tpublic void happyWithMan() {\n\t\tSystem.out.println(\"ÕýÄÇɶĨ¡£¡£¡£\");\n\t}",
"public void selecao () {}",
"public void mostrarCompra() {\n }",
"public void Ordenamiento() {\n\n\t}",
"@Override\n\tpublic void concentrarse() {\n\t\tSystem.out.println(\"Se centra en sacar lo mejor del Equipo\");\n\t\t\n\t}",
"@Override\n\tpublic void nuevo() {\n\n\t}",
"@Override\n\tpublic void iniciar() {\n\t\t\n\t}",
"@Override\n\tpublic void bolumSoyle() {\n\t\tSystem.out.println(\"Benim Bölümüm Psi\");\n\t}",
"void Vorrücken()\n {\n }",
"void vorbereiten(){\n\t\tSystem.out.println(\"vorbereiten \");\n\t}",
"public void start() {\n\n System.out.println(\"Esto no debe salir por consola al sobreescribirlo\");\n\n }",
"void berechneFlaeche() {\n\t}",
"@Override\n\tpublic void gravarBd() {\n\t\t\n\t}",
"public void mantenimiento(){\n\t}",
"public void nace() {\n System.out.println(\"Ostia, acabo de nacer tío.\");\n }",
"public void asetaTeksti(){\n }",
"public void atakuj() {\n\n System.out.println(\"to metoda atakuj z klasy Potwor \");\n\n }",
"@Override\n\tpublic void EmitirSom() {\n\t\tSystem.out.println(\"\\nEsta preguiça emite o som tec tec tec\\n\");\t\t\n\t}",
"@Override\n public void personalMotto() {\n System.out.println(\"I am the best. Greatest of all time!\");\n }",
"public void iniciar()\n {\n }",
"@Override\r\n\t\t\tpublic void ayuda() {\n\r\n\t\t\t}",
"void comer() {\n\t\tSystem.out.println(\"comiendo\");\n\t}",
"public void operation() {\n\t\tSystem.out.println(\"se obtuvo\" + nombre );\n\t}",
"public void furyo ()\t{\n }",
"@Override\r\n\tpublic void trunOn() {\n\t\tSystem.out.println(\"끄다\");\r\n\t}",
"void emi(){\n\t\tSystem.out.println(\"This is HomeLoan EMi\");\n\t}",
"@Override\r\n\tpublic void 자기() {\n\t\tSystem.out.println(\"잠을 잔다\");\r\n\t}",
"@Override\n\tpublic void darMasaje() {\n\t\t\n\t}",
"public void inicio(){\n }",
"public void sacarPaseo(){\r\n\t\t\tSystem.out.println(\"Por las tardes me saca de paseo mi dueño\");\r\n\t\t\t\r\n\t\t}",
"public void jeu() {\n\n }",
"@Override\r\n public void salir() {\n }",
"public static void darMasaje() {\n\n\t}",
"@Override\n\tpublic void apagar() {\n\t\tSystem.out.println(\"Apagando Computadora\");\n\t}",
"@Override\n\tpublic void muestraNombre() {\n\t\tSystem.out.println(\"Adivina un número par\");\n\t}",
"@Override\r\n\tpublic void work() {\n\t\tSystem.out.println( aname + \"Berkerja\");\r\n\t}",
"@Override\n\tpublic void preparar() {\n\t\tSystem.out.println(\"massa, presunto, queijo, calabreza e cebola\");\n\t\t\n\t}",
"@Override\n public void memoria() {\n \n }",
"@Override\n\tpublic void entrenar() {\n\t\t\n\t}",
"@Override\r\n\tpublic void simpleOperation() {\n\t\tSystem.out.println(\"I'm building house\");\r\n\r\n\t}",
"public void transAccElec(){\n System.out.println(\"Elija la cuenta a la que desea efectuar la transferencia\");\n System.out.println(\"\");\n}",
"public void belajar(){\n\t\tSystem.out.println(\"Belajar java di \"+tempat+\" selama \"+jamBelajar+\" jam\");\n\t}",
"public void setmostrar(){\n System.out.println(\"¿Qué deseas hacer?\");\n System.out.println(\"i=incrementar\");\n System.out.println(\"d=decrementar\");\n System.out.println(\"s=salir\");\n }",
"public static void main(String[] args) {// mais é o Start Point da aplicação\n\t// estou na classe e dentro do metodo\n\tSystem.out.print(\"Olá mundo\");\n\t\n}",
"public void emitirSaludo()\n {\n // borrarPantalla();\n System.out.println(mensaje);\n }",
"public void printAnnuNom() \n {\n System.out.println(\"Annuaire de \"+nomAnnuaire);\n }",
"public void changerJoueur() {\r\n\t\t\r\n\t}",
"@Override\n\tpublic void verkaufen() {\n\t}",
"public void geraeuschMachen() {\n System.out.println(\"BRUELL\");\n }",
"@Override\n\tpublic void einkaufen() {\n\t}",
"public void carroNoAgregado(){\n System.out.println(\"No hay un parqueo para su automovil\");\n }",
"public static void RF2() {\r\n System.out.print(\"Gracias,Tenga un Buen Dia \");\r\n\tSystem.out.print(\"Adios :D\");\r\n }",
"void crie(){\n\t\tSystem.out.println(\"miolement\");\n\t}",
"@Override\r\n\tpublic String mamar() {\n\t\treturn \"Usando Leite.\";\r\n\t}",
"public void abrirManoMaximo()\n {\n brazo.manoAbrirMaximo();\n }",
"@Override\r\n\tpublic void hello() {\n\t\tSystem.out.println(\"in Hello\");\r\n\t}",
"@Override\n\tpublic void nghienCuu() {\n\t\tSystem.out.println(\"Nghiên cứu\");\n\t}",
"@Override\n public void service() {\n System.out.println(\"风扇开始工作\");\n }",
"@Override\n\tpublic void attaquer() {\n\t\tSystem.out.println(\"Je suis \" + this.nom + \", j'ai \" + this.age + \" ans et je cueille le gui !\");\n\t}",
"@Override\n\tpublic void salir() {\n\t\t\n\t}",
"public void verarbeite() {\n\t\t\r\n\t}",
"public void desplegarInformacion() { //\n\n System.out.println(nombre);\n System.out.println(apellido);\n\n }",
"static void salutare(String nume) {\n System.out.println(\"Hello \" + nume + \"!\");\n }",
"public void tampilKarakterA(){\r\n System.out.println(\"Saya mempunyai kaki empat \");\r\n }",
"MahasiswaFix(){\n nama = \"Fajar\";\n System.out.println(nama);\n }",
"public void renovarBolsa() {\n\t\tSystem.out.println(\"Bolsa renovada com suceso!\");\n\t}",
"@Override\n\tpublic void recreo() {\n\n\t}",
"@Override\r\n\tpublic void falar(String mensagem) {\r\n\t\tSystem.out.println(\"[ \"+getNome()+\" ] \"+mensagem);\r\n\t}",
"@Override\r\n\tpublic void fly() {\n\t\tSystem.out.println(\"오리날다\");\r\n\t}",
"public void cocinar(){\n\n }"
] | [
"0.80039287",
"0.8003749",
"0.7866628",
"0.7770756",
"0.7700267",
"0.76382095",
"0.75365573",
"0.7508571",
"0.73872083",
"0.7311532",
"0.72896796",
"0.7232669",
"0.72195053",
"0.7193028",
"0.7142736",
"0.71028394",
"0.7034698",
"0.70292544",
"0.69842017",
"0.6944339",
"0.69434804",
"0.69186217",
"0.6907735",
"0.69016415",
"0.69011736",
"0.6895468",
"0.6895309",
"0.6894462",
"0.6861849",
"0.68108594",
"0.67554444",
"0.67545205",
"0.6751567",
"0.6714227",
"0.67108655",
"0.67045546",
"0.6658281",
"0.66527545",
"0.6648483",
"0.66408473",
"0.66377705",
"0.66223776",
"0.66090673",
"0.66089344",
"0.66035956",
"0.66028225",
"0.6598508",
"0.65970165",
"0.65952605",
"0.6595247",
"0.6589269",
"0.6586682",
"0.65748453",
"0.6564985",
"0.65608096",
"0.6559027",
"0.6549205",
"0.654782",
"0.6537279",
"0.6533587",
"0.6525521",
"0.65207875",
"0.6520518",
"0.65135926",
"0.65082777",
"0.6489899",
"0.6471144",
"0.64678955",
"0.64520484",
"0.64439064",
"0.6442998",
"0.64394724",
"0.64288795",
"0.6426579",
"0.64244956",
"0.6402171",
"0.6387197",
"0.6379234",
"0.6370181",
"0.6364608",
"0.6357107",
"0.6346454",
"0.6334947",
"0.6333497",
"0.6333027",
"0.63288367",
"0.6327374",
"0.63231516",
"0.63176286",
"0.6317466",
"0.63157374",
"0.6315179",
"0.6314144",
"0.6307189",
"0.63067245",
"0.6304141",
"0.63000333",
"0.62853146",
"0.62806195",
"0.62647307",
"0.62620825"
] | 0.0 | -1 |
TODO Autogenerated method stub | @Override
public void run() {
log.info("Se completa con éxito el observable");
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@Override\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}",
"@Override\n\tpublic void comer() {\n\t\t\n\t}",
"@Override\n public void perish() {\n \n }",
"@Override\r\n\t\t\tpublic void annadir() {\n\r\n\t\t\t}",
"@Override\n\tpublic void anular() {\n\n\t}",
"@Override\n\tprotected void getExras() {\n\n\t}",
"@Override\r\n\tpublic void anularFact() {\n\t\t\r\n\t}",
"@Override\n\tpublic void entrenar() {\n\t\t\n\t}",
"@Override\n\tpublic void nadar() {\n\t\t\n\t}",
"@Override\r\n\tpublic void tires() {\n\t\t\r\n\t}",
"@Override\r\n\t\t\tpublic void ayuda() {\n\r\n\t\t\t}",
"@Override\n\tprotected void interr() {\n\t}",
"@Override\n\tpublic void emprestimo() {\n\n\t}",
"@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}",
"@Override\n\tpublic void grabar() {\n\t\t\n\t}",
"@Override\n\tpublic void gravarBd() {\n\t\t\n\t}",
"@Override\r\n\tpublic void rozmnozovat() {\n\t}",
"@Override\r\n\tpublic void dormir() {\n\t\t\r\n\t}",
"@Override\n protected void getExras() {\n }",
"@Override\r\n\tpublic void publierEnchere() {\n\t\t\r\n\t}",
"@Override\n\tpublic void nefesAl() {\n\n\t}",
"@Override\n\tpublic void ligar() {\n\t\t\n\t}",
"@Override\n public void func_104112_b() {\n \n }",
"@Override\n\tprotected void initdata() {\n\n\t}",
"@Override\n\tpublic void nghe() {\n\n\t}",
"@Override\n public void function()\n {\n }",
"@Override\n public void function()\n {\n }",
"public final void mo51373a() {\n }",
"@Override\r\n\tpublic void stehReagieren() {\r\n\t\t//\r\n\t}",
"@Override\n public void inizializza() {\n\n super.inizializza();\n }",
"@Override\n\tprotected void initData() {\n\t\t\n\t}",
"@Override\r\n\t\tpublic void init() {\n\t\t\t\r\n\t\t}",
"@Override\n\tpublic void sacrifier() {\n\t\t\n\t}",
"@Override\r\n\tprotected void InitData() {\n\t\t\r\n\t}",
"public void designBasement() {\n\t\t\r\n\t}",
"@Override\r\n\tprotected void initialize() {\r\n\t\t\r\n\t\t\r\n\t}",
"public void gored() {\n\t\t\n\t}",
"@Override\r\n\tprotected void initData() {\n\r\n\t}",
"@Override\n\tpublic void einkaufen() {\n\t}",
"@Override\n protected void initialize() {\n\n \n }",
"public void mo38117a() {\n }",
"@Override\n\tprotected void getData() {\n\t\t\n\t}",
"Constructor() {\r\n\t\t \r\n\t }",
"@Override\r\n\tpublic void dibujar() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void dibujar() {\n\t\t\r\n\t}",
"@Override\n\tpublic void one() {\n\t\t\n\t}",
"@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}",
"@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}",
"@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}",
"@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}",
"@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}",
"@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}",
"private stendhal() {\n\t}",
"@Override\n\tprotected void update() {\n\t\t\n\t}",
"@Override\n\t\t\tpublic void ic() {\n\t\t\t\t\n\t\t\t}",
"@Override\n\tprotected void initData() {\n\n\t}",
"@Override\n\tprotected void initData() {\n\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n public void init() {\n\n }",
"@Override\n\tprotected void initialize() {\n\t\t\n\t}",
"@Override\n\tprotected void initialize() {\n\t\t\n\t}",
"@Override\r\n\tpublic void init() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void init() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void init() {\n\t\t\r\n\t}",
"@Override\n\tpublic void debite() {\n\t\t\n\t}",
"@Override\r\n\tpublic void init() {\n\r\n\t}",
"@Override\r\n\tpublic void init() {\n\r\n\t}",
"@Override\r\n\tpublic void init() {\n\r\n\t}",
"public contrustor(){\r\n\t}",
"@Override\n\tprotected void initialize() {\n\n\t}",
"@Override\r\n\tpublic void dispase() {\n\r\n\t}",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"@Override\n\tpublic void dtd() {\n\t\t\n\t}",
"@Override\n\tprotected void logic() {\n\n\t}",
"@Override\n\tprotected void lazyLoad() {\n\t\t\n\t}",
"public void mo4359a() {\n }",
"@Override\r\n\tprotected void initialize() {\n\r\n\t}",
"@Override\n public void memoria() {\n \n }",
"@Override\n\t\tpublic void method() {\n\t\t\t\n\t\t}",
"private RepositorioAtendimentoPublicoHBM() {\r\t}",
"@Override\n protected void initialize() \n {\n \n }",
"@Override\r\n\tpublic void getProposition() {\n\r\n\t}",
"@Override\n\tpublic void particular1() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\n\t}",
"@Override\n\tpublic void init() {\n\n\t}",
"@Override\n\tpublic void init() {\n\n\t}",
"@Override\n protected void prot() {\n }",
"@Override\r\n\tpublic void init()\r\n\t{\n\t}",
"@Override\n\tprotected void initValue()\n\t{\n\n\t}",
"public void mo55254a() {\n }"
] | [
"0.6671074",
"0.6567672",
"0.6523024",
"0.6481211",
"0.6477082",
"0.64591026",
"0.64127725",
"0.63762105",
"0.6276059",
"0.6254286",
"0.623686",
"0.6223679",
"0.6201336",
"0.61950207",
"0.61950207",
"0.61922914",
"0.6186996",
"0.6173591",
"0.61327106",
"0.61285484",
"0.6080161",
"0.6077022",
"0.6041561",
"0.6024072",
"0.6020252",
"0.59984857",
"0.59672105",
"0.59672105",
"0.5965777",
"0.59485507",
"0.5940904",
"0.59239364",
"0.5910017",
"0.5902906",
"0.58946234",
"0.5886006",
"0.58839184",
"0.58691067",
"0.5857751",
"0.58503544",
"0.5847024",
"0.58239377",
"0.5810564",
"0.5810089",
"0.5806823",
"0.5806823",
"0.5800025",
"0.5792378",
"0.5792378",
"0.5792378",
"0.5792378",
"0.5792378",
"0.5792378",
"0.5790187",
"0.5789414",
"0.5787092",
"0.57844025",
"0.57844025",
"0.5774479",
"0.5774479",
"0.5774479",
"0.5774479",
"0.5774479",
"0.5761362",
"0.57596046",
"0.57596046",
"0.575025",
"0.575025",
"0.575025",
"0.5747959",
"0.57337177",
"0.57337177",
"0.57337177",
"0.5721452",
"0.5715831",
"0.57142824",
"0.57140535",
"0.57140535",
"0.57140535",
"0.57140535",
"0.57140535",
"0.57140535",
"0.57140535",
"0.5711723",
"0.57041645",
"0.56991017",
"0.5696783",
"0.56881124",
"0.56774884",
"0.56734604",
"0.56728",
"0.56696945",
"0.5661323",
"0.5657007",
"0.5655942",
"0.5655942",
"0.5655942",
"0.56549734",
"0.5654792",
"0.5652974",
"0.5650185"
] | 0.0 | -1 |
TODO Autogenerated method stub | @Override
public String getOutputFile() {
return fileOutputPath;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@Override\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}",
"@Override\n\tpublic void comer() {\n\t\t\n\t}",
"@Override\n public void perish() {\n \n }",
"@Override\r\n\t\t\tpublic void annadir() {\n\r\n\t\t\t}",
"@Override\n\tpublic void anular() {\n\n\t}",
"@Override\n\tprotected void getExras() {\n\n\t}",
"@Override\r\n\tpublic void anularFact() {\n\t\t\r\n\t}",
"@Override\n\tpublic void entrenar() {\n\t\t\n\t}",
"@Override\n\tpublic void nadar() {\n\t\t\n\t}",
"@Override\r\n\tpublic void tires() {\n\t\t\r\n\t}",
"@Override\r\n\t\t\tpublic void ayuda() {\n\r\n\t\t\t}",
"@Override\n\tprotected void interr() {\n\t}",
"@Override\n\tpublic void emprestimo() {\n\n\t}",
"@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}",
"@Override\n\tpublic void grabar() {\n\t\t\n\t}",
"@Override\n\tpublic void gravarBd() {\n\t\t\n\t}",
"@Override\r\n\tpublic void rozmnozovat() {\n\t}",
"@Override\r\n\tpublic void dormir() {\n\t\t\r\n\t}",
"@Override\n protected void getExras() {\n }",
"@Override\r\n\tpublic void publierEnchere() {\n\t\t\r\n\t}",
"@Override\n\tpublic void nefesAl() {\n\n\t}",
"@Override\n\tpublic void ligar() {\n\t\t\n\t}",
"@Override\n public void func_104112_b() {\n \n }",
"@Override\n\tprotected void initdata() {\n\n\t}",
"@Override\n\tpublic void nghe() {\n\n\t}",
"@Override\n public void function()\n {\n }",
"@Override\n public void function()\n {\n }",
"public final void mo51373a() {\n }",
"@Override\r\n\tpublic void stehReagieren() {\r\n\t\t//\r\n\t}",
"@Override\n public void inizializza() {\n\n super.inizializza();\n }",
"@Override\n\tprotected void initData() {\n\t\t\n\t}",
"@Override\r\n\t\tpublic void init() {\n\t\t\t\r\n\t\t}",
"@Override\n\tpublic void sacrifier() {\n\t\t\n\t}",
"@Override\r\n\tprotected void InitData() {\n\t\t\r\n\t}",
"public void designBasement() {\n\t\t\r\n\t}",
"@Override\r\n\tprotected void initialize() {\r\n\t\t\r\n\t\t\r\n\t}",
"public void gored() {\n\t\t\n\t}",
"@Override\r\n\tprotected void initData() {\n\r\n\t}",
"@Override\n\tpublic void einkaufen() {\n\t}",
"@Override\n protected void initialize() {\n\n \n }",
"public void mo38117a() {\n }",
"@Override\n\tprotected void getData() {\n\t\t\n\t}",
"Constructor() {\r\n\t\t \r\n\t }",
"@Override\r\n\tpublic void dibujar() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void dibujar() {\n\t\t\r\n\t}",
"@Override\n\tpublic void one() {\n\t\t\n\t}",
"@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}",
"@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}",
"@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}",
"@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}",
"@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}",
"@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}",
"private stendhal() {\n\t}",
"@Override\n\tprotected void update() {\n\t\t\n\t}",
"@Override\n\t\t\tpublic void ic() {\n\t\t\t\t\n\t\t\t}",
"@Override\n\tprotected void initData() {\n\n\t}",
"@Override\n\tprotected void initData() {\n\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n public void init() {\n\n }",
"@Override\n\tprotected void initialize() {\n\t\t\n\t}",
"@Override\n\tprotected void initialize() {\n\t\t\n\t}",
"@Override\r\n\tpublic void init() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void init() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void init() {\n\t\t\r\n\t}",
"@Override\n\tpublic void debite() {\n\t\t\n\t}",
"@Override\r\n\tpublic void init() {\n\r\n\t}",
"@Override\r\n\tpublic void init() {\n\r\n\t}",
"@Override\r\n\tpublic void init() {\n\r\n\t}",
"public contrustor(){\r\n\t}",
"@Override\n\tprotected void initialize() {\n\n\t}",
"@Override\r\n\tpublic void dispase() {\n\r\n\t}",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"@Override\n\tpublic void dtd() {\n\t\t\n\t}",
"@Override\n\tprotected void logic() {\n\n\t}",
"@Override\n\tprotected void lazyLoad() {\n\t\t\n\t}",
"public void mo4359a() {\n }",
"@Override\r\n\tprotected void initialize() {\n\r\n\t}",
"@Override\n public void memoria() {\n \n }",
"@Override\n\t\tpublic void method() {\n\t\t\t\n\t\t}",
"private RepositorioAtendimentoPublicoHBM() {\r\t}",
"@Override\n protected void initialize() \n {\n \n }",
"@Override\r\n\tpublic void getProposition() {\n\r\n\t}",
"@Override\n\tpublic void particular1() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\n\t}",
"@Override\n\tpublic void init() {\n\n\t}",
"@Override\n\tpublic void init() {\n\n\t}",
"@Override\n protected void prot() {\n }",
"@Override\r\n\tpublic void init()\r\n\t{\n\t}",
"@Override\n\tprotected void initValue()\n\t{\n\n\t}",
"public void mo55254a() {\n }"
] | [
"0.6671074",
"0.6567672",
"0.6523024",
"0.6481211",
"0.6477082",
"0.64591026",
"0.64127725",
"0.63762105",
"0.6276059",
"0.6254286",
"0.623686",
"0.6223679",
"0.6201336",
"0.61950207",
"0.61950207",
"0.61922914",
"0.6186996",
"0.6173591",
"0.61327106",
"0.61285484",
"0.6080161",
"0.6077022",
"0.6041561",
"0.6024072",
"0.6020252",
"0.59984857",
"0.59672105",
"0.59672105",
"0.5965777",
"0.59485507",
"0.5940904",
"0.59239364",
"0.5910017",
"0.5902906",
"0.58946234",
"0.5886006",
"0.58839184",
"0.58691067",
"0.5857751",
"0.58503544",
"0.5847024",
"0.58239377",
"0.5810564",
"0.5810089",
"0.5806823",
"0.5806823",
"0.5800025",
"0.5792378",
"0.5792378",
"0.5792378",
"0.5792378",
"0.5792378",
"0.5792378",
"0.5790187",
"0.5789414",
"0.5787092",
"0.57844025",
"0.57844025",
"0.5774479",
"0.5774479",
"0.5774479",
"0.5774479",
"0.5774479",
"0.5761362",
"0.57596046",
"0.57596046",
"0.575025",
"0.575025",
"0.575025",
"0.5747959",
"0.57337177",
"0.57337177",
"0.57337177",
"0.5721452",
"0.5715831",
"0.57142824",
"0.57140535",
"0.57140535",
"0.57140535",
"0.57140535",
"0.57140535",
"0.57140535",
"0.57140535",
"0.5711723",
"0.57041645",
"0.56991017",
"0.5696783",
"0.56881124",
"0.56774884",
"0.56734604",
"0.56728",
"0.56696945",
"0.5661323",
"0.5657007",
"0.5655942",
"0.5655942",
"0.5655942",
"0.56549734",
"0.5654792",
"0.5652974",
"0.5650185"
] | 0.0 | -1 |
TODO Autogenerated method stub proinfo.logInfo(info); | @Override
public String log(String info) {
long id=Thread.currentThread().getId();
CalcThread b=ProCalcManage.getInstance().threadIDMap.get(id);
synchronized (b.proinfo.info.log) {
b.proinfo.info.log.add(new LogInfo(new Date(), info));
}
return info;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void logInfo(boolean logInfo)\r\n {\r\n if (logInfo != infoLevelHandler.getBoolean())\r\n {\r\n infoLevelHandler.setBoolean(logInfo);\r\n fireConfigUpdated();\r\n }\r\n }",
"private static void _logInfo ()\n {\n System.err.println (\"Logging is enabled using \" + log.getClass ().getName ());\n }",
"public void setInfo(String info) {\n this.info = info;\n }",
"public void setLogfileInfo(LogfileInfo info) {\n logfileInfo = info;\n }",
"@Override\n\tpublic void info(Message msg) {\n\n\t}",
"@Override\n\tpublic void info(String message, Object p0, Object p1) {\n\n\t}",
"private void logInfo(String msgText) {\n System.out.println (\"[INFO] \" + msgText);\n \n }",
"public ProcessInfoLog (int Log_ID, int P_ID, Timestamp P_Date, BigDecimal P_Number, String P_Msg)\n\t{\n\t\tsetLog_ID (Log_ID);\n\t\tsetP_ID (P_ID);\n\t\tsetP_Date (P_Date);\n\t\tsetP_Number (P_Number);\n\t\tsetP_Msg (P_Msg);\n\t}",
"public void printInfo(){\n\t}",
"public void printInfo(){\n\t}",
"private static void print(LOG_IDENTIFY mode, String TAG, String info)\n {\n StackTraceElement[] ste = Thread.currentThread().getStackTrace(); \n StringBuffer sb = new StringBuffer();\n sb.append(ste[4].getClassName());\n sb.append(\"$\");\n sb.append(ste[4].getMethodName());\n sb.append(\"()@\");\n sb.append(ste[4].getLineNumber());\n sb.append(\" : \");\n sb.append(info);\n\n switch (mode)\n {\n case INFO: \n Log.i(TAG, sb.toString());\n break;\n case DEBUG:\n \tLog.d(TAG, sb.toString());\n break;\n case WARNING:\n \tLog.w(TAG, sb.toString());\n break;\n case ERROR:\n \tLog.e(TAG, sb.toString());\n break;\n case P:\n \tif(ste.length > 5)\n \t{\n \tsb.setLength(0);\n sb.append(ste[5].getClassName());\n sb.append(\"$\");\n sb.append(ste[5].getMethodName());\n sb.append(\"()@\");\n sb.append(ste[5].getLineNumber());\n sb.append(\" : \");\n sb.append(info);\n \t}\n \tLog.d(TAG, sb.toString());\n \tbreak;\n default:\n break;\n }\n \n }",
"public static void printInfo(){\n }",
"@Override\n\tpublic void info(String message, Object p0) {\n\n\t}",
"@Override\n\tpublic void info(String message, Object p0, Object p1, Object p2, Object p3) {\n\n\t}",
"private static void addInfo(String info){\n\tif (started) {\n\t try{\n\t\tif (verbose) {\n\t\t System.out.println(info);\n\t\t System.out.println(newLine);\n\t\t}\n\t\tfStream.writeBytes(info);\n\t\tfStream.writeBytes(newLine);\n\t }catch(IOException e){\n\t }\n\t}\n }",
"public void info(Object message)\n/* */ {\n/* 145 */ if (message != null) {\n/* 146 */ getLogger().info(String.valueOf(message));\n/* */ }\n/* */ }",
"@Override\n\tpublic void info(String message, Object p0, Object p1, Object p2) {\n\n\t}",
"public static void logInfo(String info, int level) {\n\t\tif (!m_bDebug && level < 1) return;\n\t\tm_Logger.info(\"[OrbitalStrike] \" + info);\n\t}",
"public final void setInfo(Info info)\n {\n this.info = info;\n }",
"public void addInfo(Info info) {\n\tmInfos.add(info);\n }",
"public void logInfo( String msg ) {\r\n\t\tlogger.log( Level.INFO, logPrefix + \" \" + msg );\r\n\t}",
"public Info() {\n super();\n }",
"public void updateInfo() {\n\t}",
"@Override\n\tpublic void info(String message, Object... params) {\n\n\t}",
"@Override\n\tpublic void info(String message, Object p0, Object p1, Object p2, Object p3, Object p4,\n\t\t\tObject p5, Object p6) {\n\n\t}",
"public static void logInfo(Class clz,String message){\n if(logging){\n String tag = clz.getName();\n android.util.Log.i(tag, message);\n }\n }",
"@Override\n\tpublic void info(String message, Object p0, Object p1, Object p2, Object p3, Object p4) {\n\n\t}",
"public static void info(String msg) {\n\t\tlog.info(\"[iCart] \" + msg);\n\t}",
"public ProcessInfoLog (int P_ID, Timestamp P_Date, BigDecimal P_Number, String P_Msg)\n\t{\n\t\tthis (s_Log_ID++, P_ID, P_Date, P_Number, P_Msg);\n\t}",
"@Override\n\tpublic void info(String message, Object p0, Object p1, Object p2, Object p3, Object p4,\n\t\t\tObject p5, Object p6, Object p7) {\n\n\t}",
"@Override\n\tpublic void info(Object message) {\n\n\t}",
"public static void info(Object arg0) {\n MDC.put(classNameProp, \"\");\n debugLogger.info(MessageCodes.GENERAL_INFO, String.valueOf(arg0));\n }",
"protected void info(String msg) {\n log.log(Level.INFO, msg);\n }",
"void info(String tag, String msg);",
"public void setInfoId(java.lang.String infoId) {\n this.infoId = infoId;\n }",
"@Override\n\tpublic void info(Marker marker, Message msg) {\n\n\t}",
"private void infoLog(String msg) {\n Log.i(\"ActivityTransitions\", TAG + \" --> \" + msg);\n }",
"public void setInfo(Object o) {\n info = o;\n }",
"public void info(String msg) {\n log(INFO, msg);\n }",
"public void setInfo (int n)\n\t\t{\n\t\t\tinfo = n ;\n\t\t}",
"private void traceInfo(String info) {\n if (trace) {\n worker.trace(\"-- \" + info + \"\\n\", \"out\", device_id);\n }\n }",
"@Override\n\tpublic void info(MessageSupplier msgSupplier) {\n\n\t}",
"public ProcessInfoParameter( String parameterName,Object parameter,Object parameter_To,String info,String info_To ) {\n setParameterName( parameterName );\n setParameter( parameter );\n setParameter_To( parameter_To );\n setInfo( info );\n setInfo_To( info_To );\n }",
"void printInfo();",
"@SuppressWarnings(\"unused\")\n private void generateInfo()\n {\n }",
"@Override\r\n\tpublic void addParamInfo(ParamInfo info) {\n\t\tpm.insert(info);\r\n\t\t\r\n\t}",
"@Override\n\tpublic void info(Marker marker, MessageSupplier msgSupplier) {\n\n\t}",
"public void setInfo(String i)\n {\n info = i;\n }",
"@Override\n\t\t\t\tpublic void infoReceived(LinphoneCore lc, LinphoneCall call,\n\t\t\t\t\t\tLinphoneInfoMessage info) {\n\t\t\t\t\t\n\t\t\t\t}",
"@Override\n\tpublic void info(String message, Object p0, Object p1, Object p2, Object p3, Object p4,\n\t\t\tObject p5, Object p6, Object p7, Object p8, Object p9) {\n\n\t}",
"@Override\n public void onNaviInfoUpdate(NaviInfo arg0) {\n \n }",
"public String toString(){\n return \"info\";\n }",
"public void info(String msg) {\n LOGGER_BASE.info(msg);\n }",
"public void info(String msg) {\n\t\tif (this.logLevel <= BackupLogger.INFO) {\n\t\t\twrite(\"INFO \" + msg);\n\t\t\tSystem.out.println(\"INFO \" + msg);\n\t\t}\n\t}",
"public boolean logInfo()\r\n {\r\n return infoLevelHandler.getBoolean();\r\n }",
"public void infoMsg(String msg) {\n mensagens.add(new MensagemSistema(ConstantsControl.MSG_INFO, msg));\n }",
"public void info(String msg) {\n log(Level.INFO, msg, null);\n }",
"protected abstract void info(String msg);",
"public static void info(String msg){\n\t\tconsole(msg);\n\t\tlogger.info(msg);\n\t}",
"@Override\n\tpublic void info(String message, Object p0, Object p1, Object p2, Object p3, Object p4,\n\t\t\tObject p5) {\n\n\t}",
"void saveLog(LogInfo logText);",
"public void LogIt(ExtentTest logger,String StepInfo){\r\n logger.log(Status.INFO,StepInfo);\r\n }",
"@Override\n\tpublic void info(Marker marker, String message, Object p0) {\n\n\t}",
"public final void addInfo(Info info)\n {\n if (this.info != null)\n {\n info.setNextInfo(this.info);\n }\n this.info = info;\n }",
"@Override\n\tpublic void info(Marker marker, Supplier<?> msgSupplier) {\n\n\t}",
"@Override\n\tpublic void info(String message, Object p0, Object p1, Object p2, Object p3, Object p4,\n\t\t\tObject p5, Object p6, Object p7, Object p8) {\n\n\t}",
"public void info()\n {\n System.out.println(toString());\n }",
"private InfoCommand()\n\t{\n\t\t\n\t\t\n\t}",
"public void setProductInfo(ProductInfoType productInfo) {\n\t this.productInfo = productInfo;\n\t}",
"@Override\n\tpublic void info(Marker marker, String message, Object p0, Object p1) {\n\n\t}",
"boolean setInfo();",
"public void log(long idProcesso, int aTipo, String aClasse, String aMetodo, String aMensagem)\n\t{\n\t\tString mensagemFinal = \"<Servidor> \" + this.hostName; \n\t\tmensagemFinal = mensagemFinal + \" <ID> \" + idProcesso;\n\t\tmensagemFinal = mensagemFinal + \" <CL> \" + aClasse;\n\t\tmensagemFinal = mensagemFinal + \" <ME> \" + aMetodo;\n\t\tmensagemFinal = mensagemFinal + \" <Mensagem> \" + aMensagem;\n\t\t\n\t\tregistraLog(aTipo,mensagemFinal);\n\t}",
"public static void logInfo(String message)\n {\n log(IStatus.INFO, message);\n }",
"abstract public void printInfo();",
"public void log(long idProcesso, int aTipo, String aClasse, String aMetodo, String aMensagem)\n\t{\n\t\tStringBuffer mensagemFinal = new StringBuffer(\"<Servidor> \").append(getHostName()); \n\t\tmensagemFinal.append(\" <ID> \").append(idProcesso);\n\t\tmensagemFinal.append(\" <Metodo> \").append(aMetodo);\n\t\tmensagemFinal.append(\" <Mensagem> \").append(aMensagem);\n\t\t\n\t\tregistraLog(aTipo,mensagemFinal.toString());\n\t\tmensagemFinal = null;\n\t}",
"void info(String message);",
"@Override\r\n\tpublic void onNaviInfoUpdate(NaviInfo arg0) {\n\r\n\t}",
"void setUserInfo(UserInfo info);",
"public void setInformationOn(boolean flag)\n {\n this.setProperty(GUILoggerSeverityProperty.INFORMATION, flag);\n }",
"@Override\n\tpublic void onNaviInfoUpdate(NaviInfo arg0) {\n\n\t}",
"public void logInfo(final String format, final Object... args) {\n infoMessages.add(String.format(format, args));\n }",
"public void info(Object message, Throwable t)\n/* */ {\n/* 159 */ if (message != null) {\n/* 160 */ getLogger().info(String.valueOf(message), t);\n/* */ }\n/* */ }",
"public static LogMetaInfo getLogMetaInfo(String lineInfo) {\r\n\t\tLogMetaInfo logMetaInfo = new LogMetaInfo();\r\n\r\n\t\t// 1、解析出发生的时间\r\n\t\t\r\n\t\t// System.out.println(\"--->date str:\"+dateStr);\r\n\t\tlogMetaInfo.setPrintDate(getDate(lineInfo, KEY_TIME_START, KEY_TIME_END));\r\n\r\n\t\tString classNameKey = lineInfo.substring(lineInfo.lastIndexOf(\"-\") + 1).trim();\r\n\t\t// System.out.println(\"class name key:\"+classNameKey);\r\n\t\tlogMetaInfo.setCallClassName(classNameKey);\r\n\r\n\t\t// 解析出行号\r\n\t\tint lineNumStartIndex = lineInfo.indexOf(\"Log.java,\") + \"Log.java,\".length();\r\n\t\tint lineNum = 0;\r\n\t\ttry {\r\n\t\t\tlineNum = Integer.valueOf(lineInfo.substring(lineNumStartIndex, lineNumStartIndex + 2));\r\n\t\t} catch (Exception e) {\r\n\t\t\tlineNum = 70;// 给一个默认的调用\r\n\t\t}\r\n\t\tlogMetaInfo.setLineNum(lineNum);\r\n\t\tif (lineNum == NUMBER_70) {\r\n\t\t\tlogMetaInfo.setCallMethodName(LOG_METHOD_NAME_70);\r\n\t\t} else if (lineNum == NUMBER_76) {\r\n\t\t\tlogMetaInfo.setCallMethodName(LOG_METHOD_NAME_76);\r\n\t\t}\r\n\t\tlogMetaInfo.setMetaLogInfo(lineInfo);\r\n\r\n\t\treturn logMetaInfo;\r\n\t}",
"@Override\n\tpublic void info(Marker marker, String message, Object p0, Object p1, Object p2, Object p3) {\n\n\t}",
"@Override\n\tpublic void info(Marker marker, String message, Object p0, Object p1, Object p2, Object p3,\n\t\t\tObject p4, Object p5, Object p6) {\n\n\t}",
"@Override\n\tpublic void info(Marker marker, String message, Object... params) {\n\n\t}",
"public String getInfoString() {\n/* 140 */ return this.info;\n/* */ }",
"@Override\n\tpublic void info(Marker marker, String message, Object p0, Object p1, Object p2) {\n\n\t}",
"public InfoMessage createInfoMessage();",
"@Override\n\tpublic void info(Marker marker, String message, Object p0, Object p1, Object p2, Object p3,\n\t\t\tObject p4, Object p5, Object p6, Object p7) {\n\n\t}",
"public void logData(){\n }",
"public void componentStartInfo(INode node) {\n\t\t\tif (isLog4jEnabled) {\n\t\t\t\n stringBuffer.append(TEXT_16);\n stringBuffer.append(cid);\n stringBuffer.append(TEXT_17);\n \n\t\t\t}\n\t\t}",
"public void info() {\n\t\tstate.info();\n\t}",
"@SuppressWarnings(\"unused\")\n protected void info(String msg) {\n if (this.getContainer() != null && this.getContainer().getLogger().isInfoEnabled()) {\n this.getContainer().getLogger().info(msg);\n }\n }",
"@Override\n public void log()\n {\n }",
"public static void info(String msg) {\n\t\tlogger.log(Level.INFO, msg);\n\t}",
"@Override\n\tpublic void info(Message msg, Throwable t) {\n\n\t}",
"@Override\n\tpublic void info(Marker marker, Message msg, Throwable t) {\n\n\t}",
"public void setInfo(String info) {\n this.info = info == null ? null : info.trim();\n }",
"public void setProductInfo (java.lang.String productInfo) {\n\t\tthis.productInfo = productInfo;\n\t}"
] | [
"0.67767936",
"0.6348418",
"0.61222106",
"0.6108143",
"0.6093111",
"0.60330755",
"0.6026107",
"0.6022582",
"0.6000938",
"0.6000938",
"0.5993084",
"0.59654284",
"0.59607536",
"0.594993",
"0.59370804",
"0.5926819",
"0.58990085",
"0.589835",
"0.5893226",
"0.5876388",
"0.5874746",
"0.5861106",
"0.5852946",
"0.5851515",
"0.5836098",
"0.583114",
"0.58283436",
"0.58082575",
"0.57882404",
"0.5783141",
"0.5763837",
"0.57563454",
"0.5728407",
"0.5712709",
"0.5703323",
"0.56980747",
"0.5678443",
"0.56750876",
"0.56621194",
"0.5656034",
"0.5628325",
"0.56178474",
"0.56017756",
"0.56015605",
"0.55987215",
"0.55860573",
"0.5582429",
"0.5565513",
"0.5553023",
"0.5543855",
"0.55393404",
"0.55347145",
"0.5533295",
"0.5512635",
"0.549744",
"0.54945743",
"0.5494355",
"0.5492878",
"0.54847234",
"0.54607064",
"0.5459462",
"0.54534435",
"0.54502505",
"0.54480416",
"0.5446166",
"0.54448456",
"0.54337215",
"0.5419684",
"0.5414281",
"0.54129046",
"0.54092973",
"0.5392923",
"0.53905064",
"0.53849506",
"0.5381991",
"0.53790754",
"0.53773373",
"0.53767973",
"0.53735816",
"0.53730005",
"0.5371339",
"0.5369576",
"0.53516847",
"0.5345141",
"0.53406185",
"0.533255",
"0.53318614",
"0.53305435",
"0.53301585",
"0.5329419",
"0.53276485",
"0.53262293",
"0.53243554",
"0.53243446",
"0.5324271",
"0.53101313",
"0.5302682",
"0.5293036",
"0.5284576",
"0.5277752"
] | 0.723826 | 0 |
TODO Autogenerated method stub | @Override
public String endsWithSuccess(String info) {
proinfo.logInfo(info);
proinfo.end(2,info);
return null;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@Override\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}",
"@Override\n\tpublic void comer() {\n\t\t\n\t}",
"@Override\n public void perish() {\n \n }",
"@Override\r\n\t\t\tpublic void annadir() {\n\r\n\t\t\t}",
"@Override\n\tpublic void anular() {\n\n\t}",
"@Override\n\tprotected void getExras() {\n\n\t}",
"@Override\r\n\tpublic void anularFact() {\n\t\t\r\n\t}",
"@Override\n\tpublic void entrenar() {\n\t\t\n\t}",
"@Override\n\tpublic void nadar() {\n\t\t\n\t}",
"@Override\r\n\tpublic void tires() {\n\t\t\r\n\t}",
"@Override\r\n\t\t\tpublic void ayuda() {\n\r\n\t\t\t}",
"@Override\n\tprotected void interr() {\n\t}",
"@Override\n\tpublic void emprestimo() {\n\n\t}",
"@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}",
"@Override\n\tpublic void grabar() {\n\t\t\n\t}",
"@Override\n\tpublic void gravarBd() {\n\t\t\n\t}",
"@Override\r\n\tpublic void rozmnozovat() {\n\t}",
"@Override\r\n\tpublic void dormir() {\n\t\t\r\n\t}",
"@Override\n protected void getExras() {\n }",
"@Override\r\n\tpublic void publierEnchere() {\n\t\t\r\n\t}",
"@Override\n\tpublic void nefesAl() {\n\n\t}",
"@Override\n\tpublic void ligar() {\n\t\t\n\t}",
"@Override\n public void func_104112_b() {\n \n }",
"@Override\n\tprotected void initdata() {\n\n\t}",
"@Override\n\tpublic void nghe() {\n\n\t}",
"@Override\n public void function()\n {\n }",
"@Override\n public void function()\n {\n }",
"public final void mo51373a() {\n }",
"@Override\r\n\tpublic void stehReagieren() {\r\n\t\t//\r\n\t}",
"@Override\n public void inizializza() {\n\n super.inizializza();\n }",
"@Override\n\tprotected void initData() {\n\t\t\n\t}",
"@Override\r\n\t\tpublic void init() {\n\t\t\t\r\n\t\t}",
"@Override\n\tpublic void sacrifier() {\n\t\t\n\t}",
"@Override\r\n\tprotected void InitData() {\n\t\t\r\n\t}",
"public void designBasement() {\n\t\t\r\n\t}",
"@Override\r\n\tprotected void initialize() {\r\n\t\t\r\n\t\t\r\n\t}",
"public void gored() {\n\t\t\n\t}",
"@Override\r\n\tprotected void initData() {\n\r\n\t}",
"@Override\n\tpublic void einkaufen() {\n\t}",
"@Override\n protected void initialize() {\n\n \n }",
"public void mo38117a() {\n }",
"@Override\n\tprotected void getData() {\n\t\t\n\t}",
"Constructor() {\r\n\t\t \r\n\t }",
"@Override\r\n\tpublic void dibujar() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void dibujar() {\n\t\t\r\n\t}",
"@Override\n\tpublic void one() {\n\t\t\n\t}",
"@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}",
"@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}",
"@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}",
"@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}",
"@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}",
"@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}",
"private stendhal() {\n\t}",
"@Override\n\tprotected void update() {\n\t\t\n\t}",
"@Override\n\t\t\tpublic void ic() {\n\t\t\t\t\n\t\t\t}",
"@Override\n\tprotected void initData() {\n\n\t}",
"@Override\n\tprotected void initData() {\n\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n public void init() {\n\n }",
"@Override\n\tprotected void initialize() {\n\t\t\n\t}",
"@Override\n\tprotected void initialize() {\n\t\t\n\t}",
"@Override\r\n\tpublic void init() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void init() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void init() {\n\t\t\r\n\t}",
"@Override\n\tpublic void debite() {\n\t\t\n\t}",
"@Override\r\n\tpublic void init() {\n\r\n\t}",
"@Override\r\n\tpublic void init() {\n\r\n\t}",
"@Override\r\n\tpublic void init() {\n\r\n\t}",
"public contrustor(){\r\n\t}",
"@Override\n\tprotected void initialize() {\n\n\t}",
"@Override\r\n\tpublic void dispase() {\n\r\n\t}",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"@Override\n\tpublic void dtd() {\n\t\t\n\t}",
"@Override\n\tprotected void logic() {\n\n\t}",
"@Override\n\tprotected void lazyLoad() {\n\t\t\n\t}",
"public void mo4359a() {\n }",
"@Override\r\n\tprotected void initialize() {\n\r\n\t}",
"@Override\n public void memoria() {\n \n }",
"@Override\n\t\tpublic void method() {\n\t\t\t\n\t\t}",
"private RepositorioAtendimentoPublicoHBM() {\r\t}",
"@Override\n protected void initialize() \n {\n \n }",
"@Override\r\n\tpublic void getProposition() {\n\r\n\t}",
"@Override\n\tpublic void particular1() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\n\t}",
"@Override\n\tpublic void init() {\n\n\t}",
"@Override\n\tpublic void init() {\n\n\t}",
"@Override\n protected void prot() {\n }",
"@Override\r\n\tpublic void init()\r\n\t{\n\t}",
"@Override\n\tprotected void initValue()\n\t{\n\n\t}",
"public void mo55254a() {\n }"
] | [
"0.6671074",
"0.6567672",
"0.6523024",
"0.6481211",
"0.6477082",
"0.64591026",
"0.64127725",
"0.63762105",
"0.6276059",
"0.6254286",
"0.623686",
"0.6223679",
"0.6201336",
"0.61950207",
"0.61950207",
"0.61922914",
"0.6186996",
"0.6173591",
"0.61327106",
"0.61285484",
"0.6080161",
"0.6077022",
"0.6041561",
"0.6024072",
"0.6020252",
"0.59984857",
"0.59672105",
"0.59672105",
"0.5965777",
"0.59485507",
"0.5940904",
"0.59239364",
"0.5910017",
"0.5902906",
"0.58946234",
"0.5886006",
"0.58839184",
"0.58691067",
"0.5857751",
"0.58503544",
"0.5847024",
"0.58239377",
"0.5810564",
"0.5810089",
"0.5806823",
"0.5806823",
"0.5800025",
"0.5792378",
"0.5792378",
"0.5792378",
"0.5792378",
"0.5792378",
"0.5792378",
"0.5790187",
"0.5789414",
"0.5787092",
"0.57844025",
"0.57844025",
"0.5774479",
"0.5774479",
"0.5774479",
"0.5774479",
"0.5774479",
"0.5761362",
"0.57596046",
"0.57596046",
"0.575025",
"0.575025",
"0.575025",
"0.5747959",
"0.57337177",
"0.57337177",
"0.57337177",
"0.5721452",
"0.5715831",
"0.57142824",
"0.57140535",
"0.57140535",
"0.57140535",
"0.57140535",
"0.57140535",
"0.57140535",
"0.57140535",
"0.5711723",
"0.57041645",
"0.56991017",
"0.5696783",
"0.56881124",
"0.56774884",
"0.56734604",
"0.56728",
"0.56696945",
"0.5661323",
"0.5657007",
"0.5655942",
"0.5655942",
"0.5655942",
"0.56549734",
"0.5654792",
"0.5652974",
"0.5650185"
] | 0.0 | -1 |
TODO Autogenerated method stub | @Override
public boolean willDecode(String jsonMessage) {
try {
// Check if incoming message is valid JSON
Json.createReader(new StringReader(jsonMessage)).readObject();
return true;
} catch (Exception e) {
return false;
}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@Override\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}",
"@Override\n\tpublic void comer() {\n\t\t\n\t}",
"@Override\n public void perish() {\n \n }",
"@Override\r\n\t\t\tpublic void annadir() {\n\r\n\t\t\t}",
"@Override\n\tpublic void anular() {\n\n\t}",
"@Override\n\tprotected void getExras() {\n\n\t}",
"@Override\r\n\tpublic void anularFact() {\n\t\t\r\n\t}",
"@Override\n\tpublic void entrenar() {\n\t\t\n\t}",
"@Override\n\tpublic void nadar() {\n\t\t\n\t}",
"@Override\r\n\tpublic void tires() {\n\t\t\r\n\t}",
"@Override\r\n\t\t\tpublic void ayuda() {\n\r\n\t\t\t}",
"@Override\n\tprotected void interr() {\n\t}",
"@Override\n\tpublic void emprestimo() {\n\n\t}",
"@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}",
"@Override\n\tpublic void grabar() {\n\t\t\n\t}",
"@Override\n\tpublic void gravarBd() {\n\t\t\n\t}",
"@Override\r\n\tpublic void rozmnozovat() {\n\t}",
"@Override\r\n\tpublic void dormir() {\n\t\t\r\n\t}",
"@Override\n protected void getExras() {\n }",
"@Override\r\n\tpublic void publierEnchere() {\n\t\t\r\n\t}",
"@Override\n\tpublic void nefesAl() {\n\n\t}",
"@Override\n\tpublic void ligar() {\n\t\t\n\t}",
"@Override\n public void func_104112_b() {\n \n }",
"@Override\n\tprotected void initdata() {\n\n\t}",
"@Override\n\tpublic void nghe() {\n\n\t}",
"@Override\n public void function()\n {\n }",
"@Override\n public void function()\n {\n }",
"public final void mo51373a() {\n }",
"@Override\r\n\tpublic void stehReagieren() {\r\n\t\t//\r\n\t}",
"@Override\n public void inizializza() {\n\n super.inizializza();\n }",
"@Override\n\tprotected void initData() {\n\t\t\n\t}",
"@Override\r\n\t\tpublic void init() {\n\t\t\t\r\n\t\t}",
"@Override\n\tpublic void sacrifier() {\n\t\t\n\t}",
"@Override\r\n\tprotected void InitData() {\n\t\t\r\n\t}",
"public void designBasement() {\n\t\t\r\n\t}",
"@Override\r\n\tprotected void initialize() {\r\n\t\t\r\n\t\t\r\n\t}",
"public void gored() {\n\t\t\n\t}",
"@Override\r\n\tprotected void initData() {\n\r\n\t}",
"@Override\n\tpublic void einkaufen() {\n\t}",
"@Override\n protected void initialize() {\n\n \n }",
"public void mo38117a() {\n }",
"@Override\n\tprotected void getData() {\n\t\t\n\t}",
"Constructor() {\r\n\t\t \r\n\t }",
"@Override\r\n\tpublic void dibujar() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void dibujar() {\n\t\t\r\n\t}",
"@Override\n\tpublic void one() {\n\t\t\n\t}",
"@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}",
"@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}",
"@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}",
"@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}",
"@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}",
"@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}",
"private stendhal() {\n\t}",
"@Override\n\tprotected void update() {\n\t\t\n\t}",
"@Override\n\t\t\tpublic void ic() {\n\t\t\t\t\n\t\t\t}",
"@Override\n\tprotected void initData() {\n\n\t}",
"@Override\n\tprotected void initData() {\n\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n public void init() {\n\n }",
"@Override\n\tprotected void initialize() {\n\t\t\n\t}",
"@Override\n\tprotected void initialize() {\n\t\t\n\t}",
"@Override\r\n\tpublic void init() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void init() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void init() {\n\t\t\r\n\t}",
"@Override\n\tpublic void debite() {\n\t\t\n\t}",
"@Override\r\n\tpublic void init() {\n\r\n\t}",
"@Override\r\n\tpublic void init() {\n\r\n\t}",
"@Override\r\n\tpublic void init() {\n\r\n\t}",
"public contrustor(){\r\n\t}",
"@Override\n\tprotected void initialize() {\n\n\t}",
"@Override\r\n\tpublic void dispase() {\n\r\n\t}",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"@Override\n\tpublic void dtd() {\n\t\t\n\t}",
"@Override\n\tprotected void logic() {\n\n\t}",
"@Override\n\tprotected void lazyLoad() {\n\t\t\n\t}",
"public void mo4359a() {\n }",
"@Override\r\n\tprotected void initialize() {\n\r\n\t}",
"@Override\n public void memoria() {\n \n }",
"@Override\n\t\tpublic void method() {\n\t\t\t\n\t\t}",
"private RepositorioAtendimentoPublicoHBM() {\r\t}",
"@Override\n protected void initialize() \n {\n \n }",
"@Override\r\n\tpublic void getProposition() {\n\r\n\t}",
"@Override\n\tpublic void particular1() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\n\t}",
"@Override\n\tpublic void init() {\n\n\t}",
"@Override\n\tpublic void init() {\n\n\t}",
"@Override\n protected void prot() {\n }",
"@Override\r\n\tpublic void init()\r\n\t{\n\t}",
"@Override\n\tprotected void initValue()\n\t{\n\n\t}",
"public void mo55254a() {\n }"
] | [
"0.6671074",
"0.6567672",
"0.6523024",
"0.6481211",
"0.6477082",
"0.64591026",
"0.64127725",
"0.63762105",
"0.6276059",
"0.6254286",
"0.623686",
"0.6223679",
"0.6201336",
"0.61950207",
"0.61950207",
"0.61922914",
"0.6186996",
"0.6173591",
"0.61327106",
"0.61285484",
"0.6080161",
"0.6077022",
"0.6041561",
"0.6024072",
"0.6020252",
"0.59984857",
"0.59672105",
"0.59672105",
"0.5965777",
"0.59485507",
"0.5940904",
"0.59239364",
"0.5910017",
"0.5902906",
"0.58946234",
"0.5886006",
"0.58839184",
"0.58691067",
"0.5857751",
"0.58503544",
"0.5847024",
"0.58239377",
"0.5810564",
"0.5810089",
"0.5806823",
"0.5806823",
"0.5800025",
"0.5792378",
"0.5792378",
"0.5792378",
"0.5792378",
"0.5792378",
"0.5792378",
"0.5790187",
"0.5789414",
"0.5787092",
"0.57844025",
"0.57844025",
"0.5774479",
"0.5774479",
"0.5774479",
"0.5774479",
"0.5774479",
"0.5761362",
"0.57596046",
"0.57596046",
"0.575025",
"0.575025",
"0.575025",
"0.5747959",
"0.57337177",
"0.57337177",
"0.57337177",
"0.5721452",
"0.5715831",
"0.57142824",
"0.57140535",
"0.57140535",
"0.57140535",
"0.57140535",
"0.57140535",
"0.57140535",
"0.57140535",
"0.5711723",
"0.57041645",
"0.56991017",
"0.5696783",
"0.56881124",
"0.56774884",
"0.56734604",
"0.56728",
"0.56696945",
"0.5661323",
"0.5657007",
"0.5655942",
"0.5655942",
"0.5655942",
"0.56549734",
"0.5654792",
"0.5652974",
"0.5650185"
] | 0.0 | -1 |
O(n), O(c) c > distinct characters in string | public static boolean palindromEligible(String str) {
Map<Character, Integer> parityMap = new HashMap<>();
for (char c : str.toCharArray()) {
if (parityMap.containsKey(c)) {
parityMap.put(c, (parityMap.get(c) + 1) % 2);
} else {
parityMap.put(c, 1);
}
}
// count 1s
int count = 0;
for (char c : parityMap.keySet()) {
if (parityMap.get(c) == 1) {
count ++;
}
}
if (count > 1) {
return false;
}
return true;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"boolean hasUniqueCharactersTimeEfficient(String s) {\n Set<Character> characterSet = new HashSet<Character>();\n for(int i=0; i < s.length();i++) {\n if(characterSet.contains(s.charAt(i))) {\n return false;\n } else {\n characterSet.add(s.charAt(i));\n }\n }\n return true;\n }",
"public int countDistinct(String s) {\n\t\tTrie root = new Trie();\n\t\tint result = 0;\n for (int i = 0; i < s.length(); i++) {\n \tTrie cur = root;\n \tfor (int j = i; j < s.length(); j++) {\n \t\tint idx = s.charAt(j) - 'a';\n \t\tif (cur.arr[idx] == null) {\n \t\t\tresult++;\n \t\t\tcur.arr[idx] = new Trie();\n \t\t}\n \t\tcur = cur.arr[idx];\n \t}\n }\n return result;\n }",
"public void nonRepeatingCharacter(String s)\n\t{\n\t\tMap<Character, Integer> charMap = new LinkedHashMap<>();\n\t\tCharacter unique = null;\n\t\tchar[] stringArray = s.toCharArray();\n\t\tint repeat =0;\n\t\tfor(int i=0; i< stringArray.length; i++ )\n\t\t{\n\t\t\tif(!charMap.keySet().contains(stringArray[i]))\n\t\t\t{\n\t\t\t\tcharMap.put(stringArray[i], 1);\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\tInteger value = charMap.get(stringArray[i]);\n\t\t\t\tvalue++;\n\t\t\t\tcharMap.put(stringArray[i], value);\n\t\t\t}\n\t\t}\n\t\t//System.out.println(charMap.toString());\n\t\tfor(Character i : charMap.keySet())\n\t\t{\n\t\t\tint value = charMap.get(i);\n\t\t\tif(value == 1)\n\t\t\t{\n\t\t\t\tunique = i;\n\t\t\t\t//System.out.println(\"found unique \"+ unique);\n\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\t\tfor(int i=0; i< stringArray.length; i++ )\n\t\t{\n\t\t\tif(unique!= null && stringArray[i] == unique)\n\t\t\t{\n\t\t\t\tSystem.out.println(i);\n\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\t}",
"static int twoCharaters(String s) {\n\t\tList<String> list = Arrays.asList(s.split(\"\"));\n\t\tHashSet<String> uniqueValues = new HashSet<>(list);\n\t\tSystem.out.println(uniqueValues);\n\t\tString result;\n\t\twhile(check(list,1,list.get(0))) {\n\t\t\tresult = replace(list,1,list.get(0));\n\t\t\tif(result != null) {\n\t\t\t\tSystem.out.println(result);\n\t\t\t\ts = s.replaceAll(result,\"\");\n\t\t\t\tlist = Arrays.asList(s.split(\"\"));\n\t\t\t}\n\t\t}\n\t\tSystem.out.println(s);\n\t\treturn 5;\n }",
"public static String uniques(String str){\n String uniques = \"\";//lets use string str to find unique characters\n // int count = frequency(str,'a');//return type is int, therefore assign to int variable\n // System.out.println(count);//print the frequency of char 'a'\n//This step is use to identify if the character is unique, let's use loop for this\n for (char each : str.toCharArray()){\n // char ch = str.charAt(i); //to get char as a data type\n int count = frequency(str, each);\n //this is a frequency\n if(count == 1){//if count is equal to 1, concat it to unique variable\n uniques += each;\n }\n }\n return uniques;\n\n }",
"private static int solution3(String s) {\r\n int n = s.length();\r\n Set<Character> set = new HashSet<>();\r\n int ans = 0, i = 0, j = 0;\r\n while (i < n && j < n) {\r\n if (!set.contains(s.charAt(j))) {\r\n set.add(s.charAt(j++));\r\n ans = Math.max(ans, j - i);\r\n } else {\r\n set.remove(s.charAt(i++));\r\n }\r\n }\r\n return ans;\r\n }",
"public long distinctSubstring() {\n long ans = 1;\n int n = rank.length;\n for (int i = 0; i < n; i++) {\n long len = n - i;\n if (rank[i] < n - 1) {\n len -= lcp[rank[i]];\n }\n ans += len;\n }\n return ans;\n }",
"public static void main(String[] args) {\n String str = \"abcDaaafmOO\";\n String uniques = \"\";//lets use string str to find unique characters\n // int count = frequency(str,'a');//return type is int, therefore assign to int variable\n // System.out.println(count);//print the frequency of char 'a'\n//This step is use to identify if the character is unique, let's use loop for this\n for (char each : str.toCharArray()){\n // char ch = str.charAt(i); //to get char as a data type\n int count = frequency(str, each);\n //this is a frequency\n if(count == 1){//if count is equal to 1, concat it to unique variable\n uniques += each;\n }\n }\n System.out.println(\"unique values are: \"+uniques);\n System.out.println(\"========================\");\n String str2 = \"ppppoifugggggsxL\";\n String uniques2 = uniques(str2);\n System.out.println(\"unique values are: \"+uniques2);\n }",
"public int firstUniqChar(String s) {\n int n = s.length();\n int[] cnt = new int[26];\n int[] index = new int[26];\n Arrays.fill(index, n+1);\n \n // Keep the index \n for(int i=0; i<n; i++){\n cnt[s.charAt(i) - 'a']++;\n index[s.charAt(i) - 'a'] = i;\n }\n \n int minIndex = n+1;\n for(int i=0; i<26; ++i){\n if(cnt[i] > 1)\n continue;\n minIndex = Math.min(minIndex, index[i]);\n }\n return minIndex == n+1 ? -1 : minIndex;\n }",
"private static int solution2(String s) {\r\n int n = s.length();\r\n int ans = 0;\r\n for (int i = 0; i < n; i++)\r\n for (int j = i + 1; j <= n; j++)\r\n if (allUnique(s, i, j)) ans = Math.max(ans, j - i);\r\n return ans;\r\n }",
"private static int firstUniqChar3(String s) {\n if (s == null || s.isEmpty()) {\n return -1;\n }\n\n int idx = Integer.MAX_VALUE;\n for (char c = 'a'; c <= 'z'; c++) {\n int first = s.indexOf(c);\n int last = s.lastIndexOf(c);\n\n if (first != -1 && first == last) {\n idx = Math.min(idx, first);\n }\n }\n\n return idx == Integer.MAX_VALUE ? -1 : idx;\n }",
"private static int firstUniqChar2(String s) {\n Map<Character, Integer> seen = new HashMap<>();\n for (int i = 0; i < s.length(); i++) {\n char c = s.charAt(i);\n seen.put(c, seen.getOrDefault(c, 0) + 1);\n }\n\n int uniqueIdx = -1;\n for (int i = 0; i < s.length(); i++) {\n if (seen.get(s.charAt(i)) == 1) {\n uniqueIdx = i;\n break;\n }\n }\n\n return uniqueIdx;\n }",
"private static boolean isUniqueM2(String str) {\n\n if (str.length() > 128) return false;\n\n boolean[] char_set = new boolean[128];\n for (int i = 0; i < str.length(); i++) {\n int val = str.charAt(i);\n System.out.println(\"str.charAt(i): \" + val);\n if (char_set[val]) {\n return false;\n }\n char_set[val] = true;\n }\n return true;\n }",
"Set<String> getUniqueCharacterStrings();",
"void ifUnique(char inputCharArray[])\n\t{\n\t\tint count=0;\n\t\t\n\t\tfor(int i=0; i<inputCharArray.length; i++)\n\t\t{\n\t\t\t//int ab = (int)inputCharArray[i]; \n\t\t\tchar ab = inputCharArray[i];\n\t\t\tfor (int j=0; j<i; j++)\n\t\t\t{\n\t\t\t\tif(ab==inputCharArray[j])\n\t\t\t\t{\n\t\t\t\t\tSystem.out.print(\"String not unique!\");\n\t\t\t\t\tcount = 1;\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\tfor (int j=i+1; j<inputCharArray.length; j++)\n\t\t\t{\n\t\t\t\tif(ab==inputCharArray[j])\n\t\t\t\t{\n\t\t\t\t\tSystem.out.print(\"String not unique!\");\n\t\t\t\t\tcount = 1;\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\tif (count==1)\n\t\t\t\tbreak;\n\t\t}\n\t\t\n\t\tif (count==0)\n\t\t{\n\t\t\tSystem.out.print(\"String unique!\");\n\t\t}\n\t}",
"public static boolean uniqueCharStringNoDS(String s){\r\n for (int i = 0; i < s.length(); i++){\r\n for (int j = i+1; j < s.length(); j++){\r\n char temp = s.charAt(i);\r\n if (temp == s.charAt(j)){\r\n return false;\r\n }\r\n }\r\n }\r\n return true;\r\n }",
"public static boolean hasAllUniqueChars1(String string) {\n for(int i = 0; i < string.length(); i++) {\n for(int j = i + 1; j < string.length(); j++) {\n if(string.charAt(i) == string.charAt(j)) return false;\n }\n }\n\n return true;\n }",
"public static void findUniqueOptimalSolution(String inputString) {\n boolean[] charArray = new boolean[128];\n for (int i = 0; i < inputString.length(); i++) {\n int val = inputString.charAt(i);\n if (charArray[val]) {\n System.out.println(\"Input String dont have unique characters:\" + inputString);\n return;\n }\n charArray[val] = true;\n }\n System.out.println(\"Input String has unique characters \" + inputString);\n }",
"private static char firstNonRepeatingCharacterV2(String str) {\n if(str == null) return '_';\n Map<Character, Integer> charCountMap = new HashMap<>();\n Set<Character> linkedHashSet = new LinkedHashSet<>();\n\n for(int i = 0; i < str.length(); i++) {\n char ch = str.charAt(i);\n if(charCountMap.containsKey(ch)) {\n charCountMap.put(ch, charCountMap.get(ch) + 1); // do not need this step\n linkedHashSet.remove(ch);\n } else {\n charCountMap.put(ch, 1);\n linkedHashSet.add(ch);\n }\n }\n //The first character in the linkedHashSet will be the firstNonRepeatingCharacter.\n Iterator<Character> itr = linkedHashSet.iterator();\n if(itr.hasNext()){\n return itr.next();\n } else {\n return '_';\n }\n }",
"public static String uniqueChar(String str){\n\n char[] ch=str.toCharArray();\n str=\"\";\n HashMap<Character,Integer> map=new HashMap<>();\n for(int i=0;i<ch.length;i++)\n {\n if(map.containsKey(ch[i]));\n else\n {\n str+=ch[i];\n map.put(ch[i],1);\n }\n }\n \n return str;\n\t}",
"public int firstUniqChar2(String s) {\r\n \r\n char[] arr= s.toCharArray();\r\n int index = -1;\r\n HashMap<Character, Integer> map = new HashMap<>();\r\n \r\n for (int i=0;i<arr.length;i++){\r\n if (map.containsKey(arr[i])){\r\n map.put(arr[i], -1);\r\n } else {\r\n map.put(arr[i],i);\r\n }\r\n }\r\n \r\n for (int i : map.values()){\r\n if (i >-1){\r\n if (index == -1){\r\n index = i;\r\n } else if (i<index) {\r\n index = i; \r\n }\r\n \r\n }\r\n }\r\n \r\n return index;\r\n }",
"private static char firstNonRepeatingCharacterV1(String str) {\n if(str == null) return '_';\n Map<Character, Integer> charCountMap = new HashMap<>();\n Set<Character> linkedHashSet = new LinkedHashSet<>();\n\n for(int i = 0; i < str.length(); i++) {\n char ch = str.charAt(i);\n if(charCountMap.containsKey(ch)) {\n charCountMap.put(ch, charCountMap.get(ch) + 1); // do not need this step\n } else {\n charCountMap.put(ch, 1);\n }\n }\n for(int i = 0; i < str.length(); i++) {\n char ch = str.charAt(i);\n if(charCountMap.get(ch) == 1) {\n return ch;\n }\n }\n return '_';\n }",
"private static int firstUniqChar1(String s) {\n int[] counts = new int[128];\n for (int i = 0; i < s.length(); i++) {\n int c = s.charAt(i);\n counts[c] = counts[c] + 1;\n }\n\n int uniqueIdx = -1;\n for (int i = 0; i < s.length(); i++) {\n if (counts[(int) s.charAt(i)] == 1) {\n uniqueIdx = i;\n break;\n }\n }\n\n return uniqueIdx;\n }",
"public int firstUniqChar(String s) {\r\n int res = s.length();\r\n for (char c = 'a'; c <= 'z'; c++) {\r\n int index = s.indexOf(c);\r\n if (index != -1 && index == s.lastIndexOf(c)) res = Math.min(res, index);\r\n }\r\n\r\n return res == s.length() ? -1 : res;\r\n }",
"private static void longestSubstringAllUnique(String s) {\n\t\tif(s == null || s.length() == 0) {\n\t\t\tSystem.out.println(\"\");\n\t\t\treturn;\n\t\t}\n\t\t//sliding window : 2 pointers (one is use for traverse)\n\t\tint l = 0;\n\t\tSet<Character> set = new HashSet<>();//keep track of current window char\n\t\tint longest = 0;\n\t\t\n\t\tfor(int r = 0; r < s.length(); r++) {\n//\t\t\tif(set.contains(s.charAt(r))) {\n//\t\t\t\twhile(set.contains(s.charAt(r))) {\n//\t\t\t\t\tset.remove(s.charAt(l));\n//\t\t\t\t\tl++;\n//\t\t\t\t}\n//\t\t\t}\n\t\t\t\n\t\t\twhile(set.contains(s.charAt(r))) {//set == itself give distinct key: our requirement is all distinct \n\t\t\t\tset.remove(s.charAt(l));\n\t\t\t\tl++;\n\t\t\t}\n\t\t\t\n\t\t\tset.add(s.charAt(r));\n\t\t\tint currentWindowSize = r - l + 1;\n\t\t\tlongest = Math.max(longest, currentWindowSize);\n\t\t}\n\t\tSystem.out.println(longest);\n\t}",
"static void stringConstruction(String s) {\n\n StringBuilder buildUniq = new StringBuilder();\n boolean[] uniqCheck = new boolean[128];\n\n for (int i = 0; i < s.length(); i++) {\n if (!uniqCheck[s.charAt(i)]) {\n uniqCheck[s.charAt(i)] = true;\n if (uniqCheck[s.charAt(i)]){\n buildUniq.append(s.charAt(i));\n }\n }\n }\n String unique=buildUniq.toString();\n int n = unique.length();\n System.out.println(n);\n }",
"public void firstNonRepeated(String str){\n Map<Character, Integer> map = new LinkedHashMap<Character, Integer>();\n\n /*Input string convert to array of char*/\n char[] charArray = str.toCharArray();\n\n\n /*Iterating through array, count and put in hashmap */\n for(char c:charArray) {\n if (map.get(c) != null)\n map.put(c, map.get(c) + 1);\n else\n map.put(c, new Integer(1));\n }\n\n\n /*Iterating through map and check if there is character with just one occurrence*/\n Set<Character> keySet = map.keySet();\n for(Character key : keySet){\n if (map.get(key) == 1){\n System.out.println(\"Character is: \"+ key);\n System.exit(0);\n }\n }\n System.out.println(\"There are no characters with just one occurrence!\");\n }",
"public static String removeDuplicates(String s)\n {\n if (s==null||s.isEmpty()) return s;\n Set<Character> charSet = new HashSet<Character>(s.length());//maximum possible capacity\n //Set.add will only add characters not already in the list\n for (char c : s.toCharArray())\n {\n charSet.add(c);\n }\n StringBuilder sb = new StringBuilder(charSet.size());\n for (Character c : charSet)\n {\n sb.append(c);\n }\n return sb.toString();\n }",
"private void repeatingCharacter(String input) {\n\t\tMap<Character,Integer> map = new HashMap<Character,Integer>();\n\t\t//O[n]\n\t\tfor (int i = 0; i < input.length(); i++) {\n\t\t\tmap.put(input.charAt(i),map.getOrDefault(input.charAt(i), 0)+1);\n\t\t}\n\t\t//o[n]\n\t\tint max = Collections.max(map.values());\n\t\tint secondMax = 0;\n\t\tchar output = 0;\n\t\t//o[n]\n\t\tfor(Map.Entry<Character, Integer> a : map.entrySet()) {\n\t\t\tif(a.getValue()<max && a.getValue()>secondMax) {\n\t\t\t\tsecondMax = a.getValue();\n\t\t\t\toutput = a.getKey();\n\t\t\t}\n\t\t}\n\t\tif(!(secondMax == max)) {\n\t\t\tSystem.out.println(output);\n\t\t}else {\n\t\t\tSystem.out.println(\"\");\n\t\t}\n\t}",
"public static int firstUniqChar(String s) {\n\n HashMap<String, Integer> hm = new HashMap<>();\n\n for(int i = 0; i < s.length(); i++) {\n if(hm.containsKey(s.substring(i, i+1))) {\n hm.put(s.substring(i,i+1), hm.get(s.substring(i,i+1))+1);\n }\n else {\n hm.put(s.substring(i,i+1), 1);\n }\n }\n\n for(int i = 0; i< s.length(); i++) {\n if(hm.get(s.substring(i,i+1)) == 1) {\n return i;\n }\n }\n //this means all the string is repeating\n return -1;\n }",
"public int firstUniqChar(String s) {\n int[] freq = new int[26];\n \n for (char c : s.toCharArray())\n freq[c - 'a']++;\n \n for (int i = 0; i < s.length(); i++)\n if (freq[s.charAt(i) - 'a'] == 1) return i;\n \n return -1;\n }",
"public int lengthOfLongestSubstringKDistinctImprvd(String s, int k) {\n if (s == null || s.length() == 0) {\n return 0;\n }\n \n int[] map = new int[256];\n int j = 0;\n int distinctCt = 0;\n int maxLen = 0;\n\n for (int i = 0; i < s.length(); i++) {\n while (j < s.length()) {\n map[s.charAt(j)] += 1;\n if (map[s.charAt(j)] == 1) {\n distinctCt++;\n }\n j++;\n if (distinctCt > k) {\n break;\n }\n maxLen = Math.max(j- i, maxLen);\n }\n map[s.charAt(i)] -= 1;\n if (map[s.charAt(i)] == 0) {\n distinctCt--;\n }\n }\n\n return maxLen;\n}",
"private static boolean isUniqueM1(String str) {\n boolean isUnique = true;\n\n for (int i = 0; i < str.length(); i++) {\n\n for (int j = i + 1; j < str.length(); j++) {\n if (str.charAt(i) == str.charAt(j)) {\n isUnique = false;\n }\n }\n }\n return isUnique;\n }",
"public static Map<Character, Integer> findDuplicateCharactersInAString(final String input){\n\n Map<Character, Integer> charCountMap= null;\n if(input !=null && input.length() > 0)\n {\n if(input.length() ==1){\n return charCountMap;\n }\n charCountMap = new LinkedHashMap<Character, Integer>();\n String inputString = input;\n // In case if the program need not consider capital and small letters,\n // if want to consider comment out below line\n inputString = inputString.toLowerCase();\n char [] inputChars = inputString.toCharArray();\n\n for(Character c : inputChars) {\n\n if (charCountMap.containsKey(c)) {\n charCountMap.put(c, charCountMap.get(c) + 1);\n } else {\n charCountMap.put(c, 1);\n }\n }\n }\n else{\n throw new IllegalArgumentException(\"Invalid input\");\n }\n return charCountMap;\n }",
"public int firstUniqChar2(String s) {\n char[] chars = s.toCharArray();\n \n for (int i = 0; i < chars.length; i++) {\n char c = chars[i];\n if (s.indexOf(c) == s.lastIndexOf(c)) return i;\n }\n \n return -1;\n }",
"public int numDistinct(String s, String t) {\n int m = s.length();\n int n = t.length();\n\n int[][] dp = new int[m + 1][n + 1];\n\n // Initialize the first column of dp with 1\n for (int i = 0; i <= m; i++) {\n dp[i][0] = 1;\n }\n\n // Fill the dp array using dynamic programming\n for (int i = 1; i <= m; i++) {\n for (int j = 1; j <= n; j++) {\n if (s.charAt(i - 1) == t.charAt(j - 1)) {\n // If the characters match, we have two choices:\n // 1. Include the current character in both s and t\n // 2. Exclude the current character from s but keep it in t\n dp[i][j] = dp[i - 1][j - 1] + dp[i - 1][j];\n } else {\n // If the characters don't match, we can only exclude the current character from s\n dp[i][j] = dp[i - 1][j];\n }\n }\n }\n\n return dp[m][n];\n }",
"public static List<String> commonChars(String[] A) {\n\n List<String> result = new ArrayList<>();\n if(A == null || A.length < 2){\n return result;\n }\n Map<Character, Integer> map = new HashMap<>();\n for(Character c : A[0].toCharArray()){\n map.put(c, map.getOrDefault(c,0) + 1);\n }\n\n for (int i = 1; i < A.length; i++) {\n Map<Character, Integer> tempMap = new HashMap<>();\n for(Character c : A[i].toCharArray()){\n tempMap.put(c, tempMap.getOrDefault(c,0) + 1);\n }\n if(map.isEmpty()){\n return result;\n }\n// map.entrySet().removeIf(entry -> tempMap.containsKey(entry.getKey()));\n\n\n\n Iterator<Map.Entry<Character, Integer>> iterator = map.entrySet().iterator();\n Map.Entry<Character, Integer> entry;\n Character key;\n while (iterator.hasNext()) {\n entry = iterator.next();\n key = entry.getKey();\n if(!tempMap.containsKey(key)){\n iterator.remove();\n }else{\n int tempVal = tempMap.get(key);\n map.put(key, entry.getValue() > tempVal ? tempVal : entry.getValue());\n }\n }\n\n }\n\n\n Integer num;\n for(Map.Entry<Character, Integer> entry : map.entrySet()){\n num = entry.getValue();\n for (int i = 0; i < num; i++) {\n result.add(entry.getKey().toString());\n }\n }\n\n return result;\n\n }",
"public static boolean uniqueCharString(String s){\r\n HashMap<Character, Integer> map = new HashMap<Character, Integer>();\r\n for (int i = 0; i < s.length(); i++){\r\n if (map.get(s.charAt(i)) == null){\r\n map.put(s.charAt(i), 1);\r\n }\r\n else {\r\n return false;\r\n }\r\n }\r\n return true;\r\n }",
"public int numDistinct(String s, String t) {\n int m=s.length(), n=t.length();\n if(m<n) {\n return 0;\n }\n int dp[][]=new int[m+1][n+1];\n for(int i=0; i<m+1; i++) {\n Arrays.fill(dp[i], 0);\n }\n for(int i=0; i<m+1; i++) {\n dp[i][0]=1;\n }\n for(int j=1; j<n+1; j++) {\n for(int i=1; i<m+1; i++) {\n if(s.charAt(i-1)==t.charAt(j-1)) {\n // it's the sum of using s.charAt(i-1) as the last match and NOT using it as the last match\n dp[i][j]=dp[i-1][j-1]+dp[i-1][j];\n } else {\n dp[i][j]=dp[i-1][j];\n }\n }\n }\n return dp[m][n];\n }",
"public int numDistinct(String s, String t) {\n if(t.length()>s.length())return 0;\n int [][]dp = new int[t.length()+1][s.length()+1];\n for(int j=0;j<s.length();j++)dp[0][j]=1;\n for(int j=1;j<t.length();j++)dp[j][0]=0;\n for(int i=1;i<=t.length();i++){\n for(int j=1;j<=s.length();j++){\n dp[i][j] =dp[i][j-1];\n if(s.charAt(j-1)==t.charAt(i-1)){\n dp[i][j] +=dp[i-1][j-1];\n }\n }\n }\n return dp[t.length()][s.length()];\n }",
"static boolean possibleSameCharFreqByOneRemoval(String str)\n {\n int l = str.length();\n\n // fill frequency array\n int[] freq = new int[M];\n\n for (int i = 0; i < l; i++)\n freq[getIdx(str.charAt(i))]++;\n\n // if all frequencies are same, then return true\n if (allSame(freq, M))\n return true;\n\n /* Try decreasing frequency of all character\n by one and then check all equality of all\n non-zero frequencies */\n for (char c = 'a'; c <= 'z'; c++) {\n int i = getIdx(c);\n\n // Check character only if it occurs in str\n if (freq[i] > 0) {\n freq[i]--;\n\n if (allSame(freq, M))\n return true;\n freq[i]++;\n }\n }\n\n return false;\n }",
"public static boolean isAllCharacterUnique(String sIn) {\n if (sIn.length() > 32768) {\n return false;\n }\n for (char c : sIn.toCharArray()) {\n if (sIn.indexOf(c) != sIn.lastIndexOf(c)) return false;\n }\n return true;\n }",
"public static boolean hasAllUniqueChars3(String string) {\n String sorted = Stream.of(string.split(\"\")).sorted().collect(Collectors.joining());\n\n for(int i = 1; i < sorted.length(); i++) {\n if(sorted.charAt(i - 1) == sorted.charAt(i)) return false;\n }\n\n return true;\n }",
"public int firstUniqChar(String s) {\n Map<String, Integer> occurMap = new LinkedHashMap<>();\n for (int i = 0; i < s.length(); i++) {\n String si = s.substring(i, i + 1);\n if (occurMap.containsKey(si)) {\n if (occurMap.get(si) > -1) {\n occurMap.put(si, -1);\n }\n } else {\n occurMap.put(si, i);\n }\n }\n for (Integer idx : occurMap.values()) {\n if (idx > -1) {\n return idx;\n }\n }\n return -1;\n }",
"public String solution(String s) {\n\t\tStream<Character> tmp = s.chars().mapToObj(value -> (char)value);\n\t\treturn tmp.collect(Collectors.groupingBy(Function.identity(), Collectors.counting())).entrySet().stream().filter(characterLongEntry -> characterLongEntry.getValue() == 2).findFirst().get().getKey().toString();\n\t}",
"public static int firstUniqChar(String s) {\n Map<Character, Integer> map = new HashMap<>();\n for (int i = 0; i < s.length(); i++) {\n char c = s.charAt(i);\n if (map.containsKey(c)) {\n map.put(c, map.get(c) + 1);\n } else {\n map.put(c, 1);\n }\n }\n\n for (int i = 0; i < s.length(); i++) {\n char c = s.charAt(i);\n if (map.get(c) == 1) {\n return i;\n }\n }\n return -1;\n\n }",
"public boolean testAllUniqueInplace(String string) {\n\t\tif (string.length() > 128) {\n\t\t\treturn false;\n\t\t}\n\t\t\n\t\tfor (int i = 0; i < string.length(); i++) {\n\t\t\tfor (int j = i + 1; j < string.length(); j++) {\n\t\t\t\tchar ith = string.charAt(i);\n\t\t\t\tchar jth = string.charAt(j);\n\n\t\t\t\tif (ith == jth) {\n\t\t\t\t\treturn false;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn true;\n\t}",
"public static boolean allUnique2(String s ){\n\t\tint value = 0;\n\t\tchar[] chars = s.toCharArray();\n\t\tfor(char c : chars) \n\t\t{\t\n\t\t\tint i = c -'a';\n\t\t\tif(((1<<i+1)&value)>0)\n\t\t\t\treturn false;\n\t\t\tvalue = value | (1<<i+1);\n\t\t}\n\t\treturn true;\n\t}",
"public boolean isStringMadeofAllUniqueChars(String word) {\n if (word.length() > 128) {\n return false;\n }\n boolean[] char_set = new boolean[128];\n for (int i = 0; i < word.length(); i++) {\n int val = word.charAt(i);\n System.out.println(val);\n if (char_set[val]) {\n return false;\n }\n char_set[val] = true;\n }\n return true;\n }",
"public static void main(String[] args) {\n\t\n\tString a = \"aabbbc\", b= \"cabbbac\";\n\t// a = abc, b=cab\n\t//we will remove all dublicated values from \"a\"\n\tString a1 = \"\"; //store all the non duplicated values from \"a\"\n\t\n\tfor (int j=0; j<a.length();j++) //this method is with nested loop\n\tfor (int i=0; i<a.length();i++) {\n\t\tif (!a1.contains(a.substring(j, j+1))) {\n\t\t\ta1 += a.substring(j, j+1);\n\t\t}\n\t\t\t\n\t}\n\tSystem.out.println(a1);\n\t//we will remove all duplicated values from \"b\"\n\tString b1 = \"\"; //store all the non duplicated values from \"b\"\n\tfor(int i=0; i<b.length();i++) { //this is with simple loop\n\t\tif(!b1.contains(b.substring(i, i+1))) {\n\t\t\t // \"\"+b.charAt(i)\n\t\t\tb1 += b.substring(i, i+1);\n\t\t\t// \"\"+b.charAt(i);\n\t\t}\n\t}\n\tSystem.out.println(b1);\n\t\n\t\n\t//a1 = \"acb\", b1 = \"cab\"\n\tchar[] ch1 = a1.toCharArray();\n\tSystem.out.println(Arrays.toString(ch1));\n\t\n\tchar[] ch2 = b1.toCharArray();\n\tSystem.out.println(Arrays.toString(ch2));\n\t\n\tArrays.sort(ch1);\n\tArrays.sort(ch2);\n\t\n\tSystem.out.println(\"========================\");\n\tSystem.out.println(Arrays.toString(ch1));\n\tSystem.out.println(Arrays.toString(ch2));\n\t\n\t\n\tString str1 = Arrays.toString(ch1);\n\tString str2 = Arrays.toString(ch2);\n\t\n\tif(str1.equals(str2)) {\n\t\tSystem.out.println(\"true, they are same letters\");\n\t}else {\n\t\tSystem.out.println(\"false, they are contain different letters\");\n\t}\n\t\n\t\n\t// solution 2:\n\t\t\t String Str1 = \"cccccaaaabbbbccc\" , Str2 = \"cccaaabbb\";\n\t\t\t \n\t\t\t Str1 = new TreeSet<String>( Arrays.asList( Str1.split(\"\"))).toString();\n\t\t\t Str2 = new TreeSet<String>( Arrays.asList( Str2.split(\"\"))).toString();\n\t\t\t \n\t\t\t System.out.println(Str1.equals(Str2));\n\t\t\t\t \n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n\t\n}",
"public char findFirstUniqueCharacter (String string) { // O(n*n)\n for (int i = 0; i < string.length(); i++) {\n char currentChar = string.charAt(i);\n\n if (i == string.lastIndexOf(currentChar)) {\n return currentChar;\n }\n }\n\n return '\\n';\n }",
"public boolean uniqueCharacters(String st) {\n\t\tif(st.length() > 256) return false;\n\t\t\n\t\tboolean[] char_set = new boolean[256];\n\t\tfor(int i=0; i < st.length(); i++) {\n\t\t\tint val = st.charAt(i);\n\t\t\tif(char_set[val])\n\t\t\t\treturn false;\n\t\t\tchar_set[val] = true;\n\t\t}\n\t\treturn true;\n\t}",
"private static boolean hasUniqueChars(String str) {\n\t\tfor(int i = 0; i < str.length(); i++) {\n\t\t\tfor(int j = i+1; j < str.length(); j++) {\n\t\t\t\tif( str.charAt(i) == str.charAt(j) )\n\t\t\t\t\treturn false;\n\t\t\t}\n\t\t}\n\t\treturn true;\n\t}",
"public static void findUniqueUsingHashMap(String inputString) {\n\n HashMap<Character, Integer> stringHashMap = new HashMap<>();\n for (int i = 0; i < inputString.length(); i++) {\n if (stringHashMap.containsKey(inputString.charAt(i))) {\n System.out.println(\"Input String dont have unique characters:\" + inputString);\n return;\n }\n stringHashMap.put(inputString.charAt(i), i);\n }\n System.out.println(\"Input String has unique characters \" + inputString);\n }",
"public static void main(String[] args) {\n\t\t\t\n\tString str = \"aaabbbddddcccaabd\";\n\t\n\tString RemoveDup = \"\";//to store non-duplicate values of the str\n\t\n\t\n\t\n\tfor(int i = 0; i < str.length(); i++) {\n\t\tif (!RemoveDup.contains(str.substring(i, i+1))) {\n\t\t\tRemoveDup += str.substring(i, i+1);//will concat character from str to RemoveDup\n\t\t}\n\t\t\n\t}\n\tSystem.out.println(RemoveDup);\t\n\t\t\n\t\t\n\t// str = \"aaabbbddddcccaabd\"; RemoveDup = \"abcd\"\n\t//\t\t\t\t\t\t\t\t\t\t j, j+1\n\t\t// result = a5b4c3d5\n\t\t\n\t\tString result = \"\";//store expected result\n\t\t int count = 0;//count the numbers occurred characters\n\t\t\n\t\tfor(int j=0; j < RemoveDup.length(); j++) {\n\t\t for(int i=0; i <str.length(); i++) {\n\t\t\t if(str.substring(i, i+1).equals(RemoveDup.substring(j, j+1))) {\n\t\t\t\t count++;\n\t\t\t }\n\t\t }\n\t\t result += RemoveDup.substring(j, j+1)+count;\n\t\t\n\t\t}\n\t\t System.out.println(result);\n\t\t\n\t\t\n\t\t\n\t\t\n\t\t\n\t\t\n\t\t\n\t\t\n\t\t\n\t}",
"public static boolean isUniqueChars(String str) {\n\t if(str.length() > 128) return false;\n\t \n\t //created hash table boolean to flag duplicate characters\n\t boolean [] check = new boolean [128];\n\t \n\t //run a for look in order to iterate through the string.\n for(int i = 0; i < str.length(); i++){\n //convert the characters of the string array into integers\n int val = str.charAt(i);\n //check the hash table for past characters seen, there are 128 ascii codes\n\t if(check[val]) return false;\n\t //turn on the true flag for characters you are seeing\n\t check[val] = true;\n\t }\n\t \n\t //pass the hash table therefore it is unique and true;\n\t return true;\n\n\t}",
"public static boolean isUnique(String input) {\r\n // Create a Set to insert characters\r\n Set<Character> set = new HashSet<>();\r\n\r\n // get all characters form String\r\n char[] characters = input.toCharArray();\r\n\r\n for (Character c : characters) {\r\n if (!set.add(c)) {\r\n return false;\r\n }\r\n }\r\n return true;\r\n }",
"public static boolean hasAllUniqueChars2(String string) {\n HashSet<Character> characters = new HashSet<>();\n\n for(Character character : string.toCharArray()) {\n if (characters.contains(character)) return false;\n else characters.add(character);\n }\n\n return true;\n }",
"public static String uniqueChars(String str) {\n String result = \"\";\n char[] ch = str.toCharArray();\n\n for (int i = 0; i < ch.length; i++) {\n if(!result.contains(\"\" + ch[i])){\n result+=\"\" + ch[i];\n }\n\n }\n\n return result;\n }",
"public static int maxSubStringSizeKDistinctChars(String str, int k) {\n int start = 0;\n int maxLen = 0;\n int localSum = 0;\n HashMap<Character, Integer> hm = new HashMap<>();\n\n for(int end = 0; end < str.length(); end++) {\n\n localSum++;\n if (hm.containsKey(str.charAt(end))) {\n hm.put(str.charAt(end), hm.get(str.charAt(end)) + 1);\n } else {\n hm.put(str.charAt(end), 1);\n }\n\n while(hm.size() > k) {\n // maxLen = Math.max(maxLen, end - start);\n maxLen = Math.max(maxLen, localSum - 1);\n hm.put(str.charAt(start), hm.get(str.charAt(start)) - 1);\n if(hm.get(str.charAt(start)) == 0) {\n hm.remove(str.charAt(start));\n }\n start++;\n localSum--;\n }\n }\n\n return Math.max(maxLen, localSum);\n\n }",
"public char[] eliminateDuplicate(String str){\n\t\tTaskB taskB = new TaskB();\n\t\tchar[] sortArr = taskB.sortUnicodeCharacter(str);\t\n\t\tchar[] temp = new char[sortArr.length];\n\t\tint m = 0;\n\t\tint count = 0;\n\t\t\n\t\t// save unique char in temp array\n\t\tfor(int i = 0; i < sortArr.length; i++){\n\t\t\tif((i + 1) <= sortArr.length - 1){\n\t\t\t\tif(sortArr[i] != sortArr[i + 1]){\n\t\t\t\t\ttemp[m] = sortArr[i];\n\t\t\t\t\tm++;\n\t\t\t\t}\n\t\t\t}else{\n\t\t\t\ttemp[m] = sortArr[i];\n\t\t\t}\n\t\t}\n\t\t\n\t\t// count actual char in temp array\n\t\tfor(int j = 0; j < temp.length; j++){\n\t\t\tif(temp[j] != 0){\n\t\t\t\tcount++;\n\t\t\t}\n\t\t}\n\t\t\n\t\t// save chars in temp array to temp2 array\n\t\tchar[] temp2 = new char[count];\n\t\tfor(int k = 0; k < temp2.length; k++){\n\t\t\ttemp2[k] = temp[k];\n\t\t}\n\t\t\n\t\treturn temp2;\n\t}",
"public static void main(String[] args) {\n\t\t\n\t\tboolean unique=true;\n\t\tString str=\"sami\";\n\t\tchar[] chars= str.toCharArray();\n\t\tArrays.sort(chars);\n\t\t\n\t\tfor(int i=0;i<=chars.length-2;i++){\n\t\t\t\n\t\t\tif(chars[i]==chars[i+1]){\n\t\t\t\tSystem.out.println(\"Not unique chracters\");\n\t\t\t\tunique=false;\n\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\t\t\n\t\t if(unique){\n\t \t System.out.println(\" unique chracters\");\n\t }\n\n\t}",
"@Test\n\tvoid testFirstUniqueCharacterInAString() {\n\t\tFirstUniqueCharacterInAString tester = new FirstUniqueCharacterInAString();\n\t\tassertEquals(0, tester.firstUniqChar(\"leetcode\"));\n\t\tassertEquals(2, tester.firstUniqChar(\"loveleetcode\"));\n\t\tassertEquals(-1, tester.firstUniqChar(\"aabbcc\"));\n\t\tassertEquals(6, tester.firstUniqChar(\"aabbccd\"));\n\t\tassertEquals(0, tester.firstUniqChar(\"a\"));\n\t\tassertEquals(-1, tester.firstUniqChar(\"\"));\n\t}",
"public static char findFirstDuplicates(String str){\n //a green apple\n // ^ now set contains 'e'\n Set<Character> set = new HashSet<>();\n\n for(Character ch:str.toCharArray()){\n if(set.contains(ch)) return ch;\n\n set.add(ch);\n }\n return Character.MIN_VALUE;\n\n }",
"static long repeatedString(String s, long n) {\n long l=s.length();\n long k=n/l;\n long r=n%l;\n long count=0;\n long count1=0;\n char ch[]=s.toCharArray();\n for(int t=0;t<ch.length;t++){\n if(ch[t]=='a')\n count1++;\n }\n for(int t=0;t<r;t++){\n if(ch[t]=='a')\n count++;\n }\n return k*count1+count;\n\n }",
"public List<String> uniqueSubstring(String s, int k) {\n List<String> result = new ArrayList<>();\n Set<String> set = new HashSet<>();\n for (int i=0;i<=s.length()-k;i++) {\n set.add(s.substring(i, i+k));\n }\n for (String str: set) {\n result.add(str);\n }\n Collections.sort(result);\n return result;\n }",
"private static boolean isUnique(String str) {\n\t\tif(str.length() > 256)\n\t\t\treturn false;\n\t\tboolean [] char_set = new boolean[256];\n\t\tfor(int i =0; i<str.length();i++) {\n\t\t\tint value = str.charAt(i);\n\t\t\tif(char_set[value])\n\t\t\t{\n\t\t\t\treturn false;\n\t\t\t}\n\t\t\tchar_set[value] = true;\n\t\t}\n\t\treturn true;\n\t}",
"public List<String> findRepeatedDnaSequences(String s) {\n if(s.length() < 10) return new ArrayList<String>();\n \n int[] map = new int[256];\n map['A'] = 0;\n map['T'] = 1;\n map['C'] = 2;\n map['G'] = 3;\n \n List<String> result = new ArrayList<String>();\n \n //this set contains string that occurs before\n Set<Integer> visited = new HashSet<Integer>();\n //this set contains string that we have inserted into result\n Set<Integer> inResult = new HashSet<Integer>();\n \n int key = 0;\n \n //Since we only partially modify the key, we need to firstly initialize it\n for(int i = 0; i < 9; i++){\n key <<= 2;\n key |= map[s.charAt(i)];\n }\n \n for(int i = 9; i < s.length(); i++){\n key <<= 2;\n key |= map[s.charAt(i)];\n //our valid key has 20 digits, we use 0xFFFFF to remove digits that beyong this range\n key &= 0xFFFFF;\n \n String temp = s.substring(i - 9, i+1);\n \n //if this is not the first time we visit this substring\n if(!visited.add(key)){\n //if this is the first time we add this substring into result\n if(inResult.add(key)){\n result.add(temp);\n }\n }\n }\n \n return result;\n }",
"public int distinctSubseqII(String S) {\n int[] end = new int[26]; // 本字符添加之前的长度\n int res = 0;\n int added; // 当前额外增加的数量\n int mod = (int) 1e9 + 7;\n\n System.out.println('\\n' + S);\n for (char c : S.toCharArray()) {\n // 额外增加的数量等于前面的数量加上1(当前字符串)减去最后一次相同字符添加之前的数量\n added = (res + 1 - end[c - 'a']) % mod;\n\n end[c - 'a'] = (res + 1) % mod; // 影响的为前一个字符的数量加上单字符的数量\n\n res = (res + added) % mod;\n System.out.printf(\"%2c, %2d, %2d\\n\", c, res, end[c - 'a']);\n }\n return (res + mod) % mod;\n }",
"static String reverseShuffleMerge(String s) {\r\n resultString = new char[s.length()/2];\r\n inputString = s;\r\n \r\n for (int i = 0; i < s.length(); i++) {\r\n charCounts.put(s.charAt(i), charCounts.getOrDefault(s.charAt(i),0)+1);\r\n initialCharCounts.put(s.charAt(i), initialCharCounts.getOrDefault(s.charAt(i),0)+1);\r\n }\r\n \r\n for (int i = s.length()-1; i >= 0; i--) {\r\n if(resultStringIndex >= s.length()/2) {\r\n break;\r\n }\r\n \r\n if(minCharacter > s.charAt(i) && usedCharCounts.getOrDefault(s.charAt(i),0) < initialCharCounts.get(s.charAt(i))/2) {\r\n minCharacter = s.charAt(i);\r\n }\r\n \r\n if(initialCharCounts.get(s.charAt(i))/2 < charCounts.get(s.charAt(i)) + usedCharCounts.getOrDefault(s.charAt(i), 0) ) {\r\n possibleCharsList.add(s.charAt(i));\r\n }\r\n else {\r\n if(minCharacter >= s.charAt(i)) {\r\n addResultString(s.charAt(i));\r\n if(resultStringIndex >= s.length()/2) {\r\n break;\r\n }\r\n else {\r\n if(minCharacter != Character.MAX_VALUE && minCharacter != s.charAt(i)) {\r\n addResultString(minCharacter);\r\n }\r\n }\r\n }\r\n else {\r\n if(possibleCharsList.size()>0) {\r\n checkandAddPossibleChars(s,i);\r\n }\r\n \r\n if(resultStringIndex >= s.length()/2) {\r\n break;\r\n }\r\n else {\r\n addResultString(s.charAt(i));\r\n }\r\n }\r\n minCharacter = Character.MAX_VALUE;\r\n possibleCharsList.clear();\r\n }\r\n \r\n charCounts.put(s.charAt(i), charCounts.get(s.charAt(i))-1);\r\n }\r\n \r\n System.out.println(String.valueOf(resultString));\r\n return String.valueOf(resultString);\r\n\r\n\r\n }",
"boolean isUniqueUsingSorting(String str) {\n\t\tchar[] array = str.toCharArray();\n\t\t// Sorting the char array take NlogN time\n\t\tArrays.sort(array);\n\t\tfor (int i = 0; i < array.length - 1; i++) {\n\t\t\t// If adjacent characters are equal, return false\n\t\t\tif (array[i] == array[i + 1]) {\n\t\t\t\treturn false;\n\t\t\t}\n\t\t}\n\t\treturn true;\n\t}",
"private static String stringCompress(String input) {\n int length = input.length();\n int count = 0;\n StringBuilder output = new StringBuilder();\n char curr = input.charAt(0);\n for(int i=0;i<length;i++){\n char temp = input.charAt(i);\n // If the current char is the same as previous one\n // we increment the counter and move to the next one\n if(curr == temp)\n count++;\n // If the current char is not same as previous one\n // we add the char and its frequency to output\n else{\n output.append(curr);\n output.append(count);\n // reset the counter for next char\n count = 1;\n curr = temp;\n }\n }\n // The last char and its frequency are yet to be added\n output.append(curr);\n output.append(count);\n return output.toString();\n }",
"public static boolean isUniqueChars2(String str) {\n\t\tboolean[] char_set = new boolean[256];\n\t\tfor (int i = 0; i < str.length(); i++) {\n\t\t\tint val = str.charAt(i);\n\t\t\tSystem.out.println(\"Value at i = \"+i +\" is \"+val);\n\t\t\tif (char_set[val]) return false;\n\t\t\tchar_set[val] = true;\n\t\t}\n\t\treturn true;\n\t}",
"public int lengthOfLongestSubstringKDistinct(String s, int k) {\n if (s == null || s.length() == 0) {\n return 0;\n }\n\n int j = 0;\n int max = 0;\n int[] map = new int[256];\n int distinctCt = 0;\n\n for (int i = 0; i < s.length(); i++) {\n while( j < s.length()) {\n int ch = s.charAt(j);\n if (map[ch] == 0) {\n if (distinctCt + 1 > k) {\n break;\n }\n map[ch] = 1;\n distinctCt++;\n j++;\n } else {\n map[ch] += 1;\n j++;\n }\n }\n max = Math.max(max, j - i);\n map[s.charAt(i)] -= 1;\n if (map[s.charAt(i)] == 0) {\n distinctCt--;\n }\n }\n return max;\n }",
"static String superReducedString(String s) {\n StringBuffer buff = new StringBuffer(s);\n for(int i = buff.length() - 1; i >= 0; i--){\n int j = i + 1;\n if(j >= buff.length()) continue;\n\n if(buff.charAt(i) == buff.charAt(j)) {\n buff.delete(i, j + 1);\n }\n }\n\n if(buff.length() == 0) return \"Empty String\";\n return String.valueOf(buff);\n }",
"public static String removeConsecutiveDuplicates(String input) {\n String ans =\"\";\n \n \n\t\n\t\n\tchar start = input.charAt(0);\n ans= ans + input.charAt(0);\n\tfor(int i = 1;i<input.length();i++){\n\t\t\n\t\tchar compare = input.charAt(i);\n\t\t\n\t\tif(compare != start){\n\t\t\tans = ans + input.charAt(i);\n\t\t\tstart = input.charAt(i);\n\t\t} \n }\n return ans;\n \n\t}",
"public int numDistinct2(String s, String t)\n {\n return findSubS(s.length()-1, t.length()-1, s, t);\n }",
"public static void main(String[] args) {\n System.out.println(firstUniqChar(\"leetcode\")); //should return 0\n System.out.println(firstUniqChar(\"loveleetcode\")); //should return 2\n\n }",
"public static String evensOnlyNoDupes( String s ) {\n Set<Character> h = new LinkedHashSet<Character>(); //--initializing the hashset\n String s2 = \"\"; //tkaing pieces of the string --> put it into s2 ean empty string\n\n for (int i = 0; i < s.length(); i++) {\n if ((int)s.charAt(i) % 2 == 0) {\n if (!h.contains(s.charAt(i))) {\n s2 += s.charAt(i); // a += b means a + b so youre adding the chracter to the s2 string\n h.add(s.charAt(i)); // a set contains a bunch of characters and you need to add the character to the set so that it can tell you if it has showed up or not yet in the set\n }\n }\n }\n return s2;\n }",
"public static boolean isUnique(String s) {\n if (s.length() > 128) return false;\n\n // we dont need to check the last element\n for (int i = 0; i < s.length() - 1; i++){\n String current = \"\";\n current += s.charAt(i);\n// System.out.println(current);\n if (s.substring(i + 1).contains(current))\n return false;\n }\n return true;\n }",
"static long repeatedString(String s, long n) {\n\n char[] str = s.toCharArray();\n\n String temp = \"\";\n\n int i=0;\n long count=0;\n\n while(i<str.length){\n if(str[i]=='a'){\n count++;\n }\n i++;\n }\n\n long occurance = n/str.length;\n long remainder = n%str.length;\n count = count*occurance;\n\n i=0;\n while(i<remainder){\n if(str[i]=='a'){\n count++;\n }\n i++;\n }\n\n return count;\n\n }",
"public static String findUncommonCharacters(String s1, String s2) {\n\t\tHashSet<Character> uncommonChars = new HashSet<>();\n\n\t\t// Variable to check if the character is present in both the strings\n\t\tboolean isPresent = false;\n\n\t\t// Finding the uncommon characters that are present in string s1, but not in s2\n\t\tfor (int i = 0; i < s1.length(); i++) {\n\t\t\tfor (int j = 0; j < s2.length(); j++) {\n\t\t\t\t// Character is present in both s1 and s2\n\t\t\t\tif (s1.charAt(i) == s2.charAt(j)) {\n\t\t\t\t\tisPresent = true;\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t// Character is not present in s2\n\t\t\tif (isPresent == false) {\n\t\t\t\tuncommonChars.add(s1.charAt(i));\n\t\t\t} else {\n\t\t\t\tisPresent = false;\n\t\t\t}\n\t\t}\n\n\t\tisPresent = false;\n\n\t\t// Finding the uncommon characters that are present in string s2, but not in s1\n\t\tfor (int i = 0; i < s2.length(); i++) {\n\t\t\tfor (int j = 0; j < s1.length(); j++) {\n\t\t\t\t// Character is present in both s1 and s2\n\t\t\t\tif (s2.charAt(i) == s1.charAt(j)) {\n\t\t\t\t\tisPresent = true;\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t// Character is not present in s1\n\t\t\tif (isPresent == false) {\n\t\t\t\tuncommonChars.add(s2.charAt(i));\n\t\t\t} else {\n\t\t\t\tisPresent = false;\n\t\t\t}\n\t\t}\n\n\t\tString ans = \"\";\n\t\t // Sorting HashSet using TreeSet \n\t\tTreeSet<Character> treeSet = new TreeSet<Character>(uncommonChars);\n\t\tfor (char ch : treeSet) {\n\t\t\tans += ch;\n\t\t}\n\t\treturn ans;\n\t}",
"public static String removeAdjDupes(String s) {\n //Shane Method first try\n// Stack<Character> stack = new Stack<Character>();\n// for(char c : s.toCharArray()) {\n// if(stack.isEmpty()) {\n// stack.push((c));\n// }else if(stack.peek() == c) {\n// stack.pop();\n// } else {\n// stack.push(c);\n// }\n// }\n// StringBuilder str = new StringBuilder();\n// for(char c : stack){\n// str.append(c);\n// }\n// return str.toString();\n\n // Daily Byte answer that is twice as fast as mine\n StringBuilder result = new StringBuilder();\n Stack<Character> stack = new Stack<>();\n for (char c: s.toCharArray()) {\n if (!stack.isEmpty() && c == stack.peek()) {\n stack.pop();\n } else {\n stack.push(c);\n }\n }\n\n while (!stack.isEmpty()) {\n result.append(stack.pop());\n }\n\n return result.reverse().toString();\n }",
"public int firstUniqChar(String s) {\n int[] isA=new int[128];\n \tfor(int i=0; i<s.length(); i++){\n \t\tisA[s.charAt(i)]++;\n \t}\n \t\n \tfor(int i=0; i<s.length(); i++){\n \t\tif(isA[s.charAt(i)]==1){\n \t\t\treturn i;\n \t\t}\n \t}\n \treturn -1;\n }",
"public static boolean isAllUnique(String string) {\n\n // Let's create a new HashSet to cache the characters.\n HashSet<Character> set = new HashSet<>();\n\n for (char c : string.toCharArray()) {\n if (set.contains(c)) {\n return false;\n } else {\n set.add(c);\n }\n }\n\n return true;\n }",
"public static void main(String[] args) {\n\t\tString myString = \"abcdea\";\n\t\tint flag = 1;\n\t\t\n\t\tfor (int i=0; i < myString.length(); i++) {\n\t\t\tfor (int j=0; j < myString.length(); j++) {\n\t\t\t\tif(myString.charAt(i)==myString.charAt(j) && i!=j) {\n\t\t\t\t\tflag = 0;\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\t\n\t\t}\n\t\tif(flag==1) {\n\t\t\tSystem.out.println(\"The string has unique characters\");\n\t\t}else {\n\t\t\tSystem.out.println(\"The string does not have unique characters\");\n\t\t}\n\n\t}",
"private static String compressString(String str){\n\t\t\n\t\tint sizeComStr = sizeOfCompressedStr(str);\n\t\tint orgLen = str.length();\n\t\tif(sizeComStr>= orgLen)\n\t\t\treturn str;\n\t\t\n\t\tStringBuffer myStr = new StringBuffer();\n\t\tint i=0,j=i+1;\n\t\tint count =1;\n\t\t\n\t\twhile(i<orgLen && j<orgLen){\n\t\t\n\t\t\tif(str.charAt(i) == str.charAt(j)){\n\t\t\t\tcount++;\n\t\t\t\tj++;\t\t\t\t\t\t\t\n\t\t\t}\n\t\t\telse{\n\t\t\t\t\n\t\t\t\tmyStr.append(str.charAt(i));\n\t\t\t\tmyStr.append(count);\n\t\t\t\ti=j;\n\t\t\t\tcount = 1;\t\n\t\t\t\tj++;\n\t\t\t\tif(j>=orgLen)\n\t\t\t\t\tbreak;\n\t\t\t\t\n\t\t\t}\n\t\t\t\n\t\t\t\n\t\t}\n\t\t\n\t\tmyStr.append(str.charAt(i));\n\t\tmyStr.append(count);\n\t\t\n\t\treturn myStr.toString();\t\n\t\t\n\t}",
"public String sortString(String s) {\n List<Character> characters = s.chars().mapToObj(c -> (char) c).collect(Collectors.toList());\n // Sort the input O(logN)\n Collections.sort(characters);\n StringBuilder result = new StringBuilder();\n\n // Iterator over entire input array\n while(!characters.isEmpty()) {\n Set<Character> seenChars = new HashSet();\n // Pick the smallest character from s and append it to the result\n char smallestChar = characters.remove(0);\n result.append(smallestChar);\n seenChars.add(smallestChar);\n\n Iterator<Character> sortedIterator = characters.iterator();\n while (sortedIterator.hasNext()) {\n char c = sortedIterator.next();\n if (!seenChars.contains(c)) {\n result.append(c);\n seenChars.add(c);\n // Remove this character from input\n sortedIterator.remove();\n }\n }\n if (result.length() == s.length()) {\n break;\n }\n\n seenChars = new HashSet();\n char largest = characters.remove(characters.size() - 1);\n result.append(largest);\n seenChars.add(largest);\n\n // Pick the largest character from s and append it to the result\n ListIterator<Character> reverseIterator = characters.listIterator(characters.size());\n while (reverseIterator.hasPrevious()) {\n char c = reverseIterator.previous();\n if (!seenChars.contains(c)) {\n result.append(c);\n seenChars.add(c);\n reverseIterator.remove();\n }\n }\n if (result.length() == s.length()) {\n break;\n }\n }\n\n return result.toString();\n }",
"public static void main(String[] args) {\n\t\tString s = \"caaab\";\n\t\tString[] res = getUniqueSubstring(s,2);\n\t\tfor(String a : res){\n\t\t\tSystem.out.println(a);\n\t\t}\n\t}",
"public static void main(String[] args) {\n Scanner in = new Scanner(System.in);\n int N = Integer.parseInt(in.nextLine());\n HashSet<Character> first = new HashSet<Character>();\n HashSet<Character> second = new HashSet<Character>();\n int i=0;\n char temp = 'a';\n for(temp='a';temp<='z';temp++){\n \t first.add(temp);\n }\n int j;\n while(i<N){\n \t second.clear();\n \t char[] stringArray = in.nextLine().toCharArray();\n \t for(j=0;j<stringArray.length;j++){\n \t\t second.add(stringArray[j]); \n \t }\n \t first.retainAll(second);\n \t i++;\n }\n System.out.println(first.size());\n }",
"public int minCut2(String s) {\n boolean[][] dp = new boolean[s.length()][s.length()];\n for (int len = 1; len <= s.length(); len++) {\n for (int i = 0; i <= s.length() - len; i++) {\n int j = i + len - 1;\n dp[i][j] = s.charAt(i) == s.charAt(j) && (len < 3 || dp[i + 1][j - 1]);\n }\n }\n\n int[] cut = new int[1];\n cut[0] = Integer.MAX_VALUE;\n // List<List<String>> res = new ArrayList<>();\n helper2(s, 0, cut, dp, 0);\n // System.out.format(\"res: %s\\n\", res);\n return cut[0];\n }",
"public static void main(String[] args) {\n\t\t\r\n\t\tString str1 = \"garima\";\r\n\t\t\r\n\t\tSystem.out.println(\"The given string is:\"+str1);\r\n\t\t\r\n\t\tfor(int i = 0; i < str1.length(); i++)\r\n\t\t{\r\n\t\t\tboolean unique = true;\r\n\t\t\t\r\n\t\t\tfor(int j = 0; j < str1.length(); j++)\r\n\t\t\t{\r\n\t\t\t\tif(i != j && str1.charAt(i) == str1.charAt(j)) {\r\n\t\t\t\t\tunique = false;\r\n\t\t\t\t\tbreak;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\tif(unique)\r\n\t\t\t{\r\n\t\t\t\tSystem.out.println(\"The first non-repeating character in String:\"+str1.charAt(i));\r\n\t\t\t\tbreak;\r\n\t\t\t}\r\n\t\t}\r\n\t}",
"public static int sherlock(String s) {\n\t\tint count = 0;\n\t\t// find the substrings to find the anagrams of\n\t\t// isAnagram function\n\t\t// with k unique chars, subset is k (k + 1) / 2\n\t\t\n\t\tList<String> subsets = getALlSubstring(s);\n\t\t\n\t\tfor(int i = 0 ;i < subsets.size() ; i++) {\n\t\t\tfor(int j = i + 1 ; j < subsets.size() ; j++) {\n\t\t\t\tif(i != j && subsets.get(i).length() == subsets.get(j).length() && isAnagram(subsets.get(i), subsets.get(j)))\n\t\t\t\t\tcount++;\n\t\t\t}\n\t\t}\n\t\treturn count;\n\t}",
"public boolean isUnique(String s){\n // int[] visited = new int[256]; // O:256\n int[] visited = new int[8]; // int = 4 bytes = 32 bits, 8 ints = 32 bytes = 256 bits\n char[] array = s.toCharArray();\n for(char c:array){\n // for a value c in range of 0 - 256\n // it maps to the int at c/32 as index\n // it also maps the c%32 as the index of bits\n if(((visited[c/32] >>> (c%32)) & 1) != 0){\n // bit-tester of the k-th bits, k = c%32\n return false;\n }\n // bit-setter to 1 in the k-th bits\n visited[c/32] |= 1 << (c%32);\n }\n return true;\n }",
"static long repeatedString(String s, long n) {\n char[] arr=s.toCharArray();\n int i,count=0,cnt=0;\n for(i=0;i<arr.length;i++){\n if(arr[i]=='a'){\n count++;\n }\n }\n long len=(n/arr.length)*count;\n long extra=n%arr.length;\n if(extra==0){\n return len;\n }else{\n for(i=0;i<extra;i++){\n if(arr[i]=='a'){\n cnt++;\n }\n }\n return len+cnt;\n }\n\n\n }",
"public int lengthOfLongestSubstringKDistinct(String s, int k) {\n Map<Character, Integer> map = new HashMap<>();\n int maxLenght = 0;\n\n int i = 0;\n int j = 0;\n int n = s.length();\n\n while (j < s.length()) {\n\n char c = s.charAt(j);\n if (map.containsKey(c)) {\n map.put(c, map.get(c) + 1);\n } else {\n map.put(c, 1);\n }\n\n if (map.size() <= k) {\n maxLenght = Math.max(maxLenght, j - i + 1);\n }\n\n if (map.size() > k) {\n\n while (map.size() > k && i < j) {\n char cx = s.charAt(i);\n map.put(cx, map.get(cx) - 1);\n if (map.get(cx) == 0) {\n map.remove(cx);\n }\n i++;\n }\n }\n\n j++;\n }\n\n return maxLenght;\n }",
"public static int commonCharacterCount(String s1, String s2) {\n\t int count = 0;\n\t int auxArray[] = new int[s2.length()];\n\t for (int i = 0; i < auxArray.length; i++){\n\t\tauxArray[i] = 0;\n\t }\n\t \n\t for(int i = 0; i < s1.length(); i++){\n\t\tfor(int j = 0; j < s2.length(); j++){\n\t\t if( auxArray[j] == 1){\n\t\t continue;\n\t\t }\n\t\t else{\n\t\t if(s1.charAt(i) == s2.charAt(j)){\n\t\t auxArray[j] = 1;\n\t\t count += 1;\n\t\t break;\n\t\t }\n\t\t }\n\t\t}\n\t }\n\t return count;\n\t}",
"public static String RemoveDuplicatedLetters(String s, int k) {\n if (s.length() < k) {\n return s;\n }\n String result = \"\";\n int counter = 1;\n Stack<String> stack = new Stack<>();\n for (int i = 0; i < s.length(); i++) {\n stack.push(s.substring(i, i + 1));\n }\n result += stack.pop();\n\n while (!stack.isEmpty()) {\n if (stack.peek().equals(result.charAt(0) + \"\")) {\n counter += 1;\n } else {\n counter = 1;\n }\n result = stack.pop() + result;\n if (counter == k) {\n result = result.length() == k ? \"\" : result.substring(k);\n for (int i = 0; i < s.length(); i++) {\n stack.push(s.substring(i, i + 1));\n }\n counter = 0;\n }\n }\n return result;\n }",
"public static void removeDuplicates(char [] str)\n{\n\tif(str.length <2) return;\n\tif(str == null) return;\n\tint j, tail=1;\n\tfor(int i=1; i<str.length; i++)\n\t{\n\t\tfor(j=0; j<tail; j++)\n\t\t{\n\t\t\tif(str[i] == str[j])\n\t\t\t\tbreak;\n\t\t}\n\t\tif(j==tail)\n\t\t{\n\t\t\tstr[tail++] = str[i];\n\t\t\t\n\t\t}\n\t}\n\tstr[tail] = '\\0';\t\n}",
"public int minCut1(String s) {\n boolean[][] dp = new boolean[s.length()][s.length()];\n for (int len = 1; len <= s.length(); len++) {\n for (int i = 0; i <= s.length() - len; i++) {\n int j = i + len - 1;\n dp[i][j] = s.charAt(i) == s.charAt(j) && (len < 3 || dp[i + 1][j - 1]);\n }\n }\n\n int[] cut = new int[1];\n cut[0] = Integer.MAX_VALUE;\n List<List<String>> res = new ArrayList<>();\n helper1(s, 0, cut, dp, res, new ArrayList<>());\n // System.out.format(\"res: %s\\n\", res);\n return cut[0];\n }",
"public static Character nonRepeating(String s) {\n Map<Character, Integer> charCount = new HashMap<>();\n for (int i = 0; i < s.length(); i++) {\n char c = s.charAt(i);\n if (charCount.containsKey(c)) {\n charCount.put(c, charCount.get(c) + 1);\n } else {\n charCount.put(c, 1);\n }\n }\n for (int i = 0; i < s.length(); i++) {\n char c = s.charAt(i);\n if (charCount.get(c) == 1) {\n return c;\n }\n }\n return null;\n }"
] | [
"0.7078805",
"0.69245076",
"0.6915656",
"0.689981",
"0.68844897",
"0.6832044",
"0.67940193",
"0.6778415",
"0.6771811",
"0.6757862",
"0.67370373",
"0.67289007",
"0.6685837",
"0.66853017",
"0.66717505",
"0.66583407",
"0.6648319",
"0.6646872",
"0.66428834",
"0.66121024",
"0.6600787",
"0.6595117",
"0.6585716",
"0.6578691",
"0.6567284",
"0.65641236",
"0.6542169",
"0.65380555",
"0.64985704",
"0.6496919",
"0.649177",
"0.64884347",
"0.6481216",
"0.6475938",
"0.64631563",
"0.64587575",
"0.64438844",
"0.6443541",
"0.6420794",
"0.6408839",
"0.638646",
"0.6385201",
"0.6382036",
"0.6381257",
"0.6371586",
"0.6371132",
"0.63686436",
"0.63607854",
"0.63548744",
"0.6340768",
"0.6334596",
"0.633331",
"0.6314279",
"0.6299924",
"0.6283104",
"0.62759054",
"0.6260418",
"0.6247727",
"0.6245451",
"0.62442076",
"0.6220453",
"0.6205786",
"0.61979145",
"0.6185279",
"0.61826646",
"0.6179405",
"0.61744326",
"0.61725724",
"0.6164906",
"0.6157493",
"0.6153526",
"0.61522734",
"0.6150919",
"0.6147901",
"0.61443245",
"0.61339116",
"0.6130668",
"0.6129934",
"0.61195874",
"0.6115984",
"0.6108868",
"0.61060774",
"0.61059946",
"0.60946405",
"0.60876477",
"0.6081731",
"0.6081326",
"0.60695094",
"0.6059347",
"0.6058748",
"0.6058608",
"0.60561144",
"0.6052183",
"0.6039374",
"0.6036528",
"0.603044",
"0.6028449",
"0.6026935",
"0.6026659",
"0.6023694",
"0.60198444"
] | 0.0 | -1 |
wait until merge completes | @Override
protected void onAfterSplitBrainHealed(HazelcastInstance[] instances) {
mergeLifecycleListener.await();
assertContainsCounterStatsEventually(true, instances[0], instances[1]);
assertContainsCounterStatsEventually(false, instances[2]);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"protected boolean afterMerge() throws DBSIOException{return true;}",
"private static void mergingSyncMadeAsync() {\n Observable.merge(getDataSync(1).subscribeOn(Schedulers.io()), getDataSync(2).subscribeOn(Schedulers.io())).blockingForEach(System.out::println);\n }",
"public void merge() throws Exception\n{\n Git git = getGit();\n MergeCommand merge = git.merge();\n ObjectId remoteOriginMaster = getRepo().resolve(\"refs/remotes/origin/master\");\n merge.include(remoteOriginMaster);\n MergeResult result = merge.call();\n System.out.println(\"Merge Result: \" + result.getMergeStatus());\n \n // Reset index\n getIndexSite().resetFiles(); _index = null;\n}",
"public void acquire(boolean forMerge) {\r\n return;\r\n }",
"private static void mergingSync() {\n Observable.merge(getDataSync(1), getDataSync(2)).blockingForEach(System.out::println);\n }",
"@Override\n protected void done() {\n super.done();\n if (!this.isCancelled()) {\n openMergeModifiedFile(); \n }\n }",
"void merge(String revSpec) throws GitException, InterruptedException;",
"void merge();",
"private void maintainMergeLocal() {\n logger.info(\"Maintaining Merge Local\");\n try {\n Bin mergeBin;\n synchronized (geometricParts) {\n mergeBin = geometricParts.findMergeCandidates();\n }\n if (!mergeBin.isEmpty()) {\n File indexShard = getNextIndexShardFolder(mergeBin.size + 1);\n // otherwise there's something to merge\n logger.info(\"Performing merge!\");\n\n\n // merge the shards\n Parameters p = this.globalParameters.clone();\n // override each of these particular parameters\n p.set(\"indexPath\", indexShard.getAbsolutePath());\n p.set(\"inputPath\", new ArrayList<>(mergeBin.getBinPaths()));\n p.set(\"renumberDocuments\", false);\n\n App.run(\"merge-index\", p, System.out);\n\n // should make sure that these two are uninteruppable\n synchronized (geometricParts) {\n geometricParts.add(mergeBin.size + 1, indexShard.getAbsolutePath());\n geometricParts.removeShards(mergeBin);\n updateIndex();\n }\n\n // now can delete the merged indexshard folders...\n for (String file : mergeBin.getBinPaths()) {\n FSUtil.deleteDirectory(new File(file));\n }\n\n logger.info(\"Done merging.\");\n }\n } catch (Exception ex) {\n Logger.getLogger(GeometricIndex.class.getName()).log(Level.SEVERE, null, ex);\n }\n }",
"private void mergeprocess(String givenbranch,\n boolean conflict, Comm splitpoint) {\n ArrayList<String> modifiedincurr =\n findchanged(splitpoint, branches.get(branch));\n ArrayList<String> modifiedingiven =\n findchanged(splitpoint, branches.get(givenbranch));\n ArrayList<String> addedincurr =\n findadded(splitpoint, branches.get(branch));\n ArrayList<String> addedingiven =\n findadded(splitpoint, branches.get(givenbranch));\n Comm topofcurr = branches.get(branch);\n Comm topofgiven = branches.get(givenbranch);\n for (String file: splitpoint.getContents().keySet()) {\n\n if (!modifiedincurr.contains(file)\n && modifiedingiven.contains(file)) {\n checkoutcomm(branches.get(givenbranch).getCommitID(), file);\n add(file);\n }\n if (modifiedincurr.contains(file)\n && modifiedingiven.contains(file)) {\n if (!(topofcurr.getContents()\n .get(file).getContent().equals(topofgiven\n .getContents().get(file).getContent()))) {\n\n conflict = true;\n mergeconflict(topofcurr.getContents().get(file),\n topofgiven.getContents().get(file));\n }\n }\n if (modifiedingiven.contains(file)\n && !getandadd().contains(file) && !conflict) {\n conflict = true;\n mergeconflictgiven(new Blob(new File(file)));\n }\n if (modifiedincurr.contains(file)\n && !topofgiven.getContents().containsKey(file)\n && !conflict) {\n conflict = true;\n mergeconflictcur(new Blob(new File(file)));\n }\n if (!modifiedincurr.contains(file)\n && !topofgiven.getContents().containsKey(file)) {\n if (stagingarea.containsKey(file)\n || topofcurr.getContents().containsKey(file)) {\n rm(file);\n }\n }\n }\n for (String f :addedingiven) {\n if (!addedincurr.contains(f)) {\n checkoutcomm(branches.get(givenbranch).getCommitID(), f);\n add(f);\n } else {\n conflict = true;\n mergeconflict(topofcurr.getContents().get(f),\n topofgiven.getContents().get(f));\n }\n }\n mergecleanup(conflict, givenbranch);\n }",
"@SuppressWarnings(\"unchecked\")\t\n\tvoid merge() throws IOException\n\t{\n\t\tdouble startup = Util.curtime();\n\t\t_logMail.pf(\"Starting merge operation for dataset %s\\n\", _segDataQ.getDataSet());\n\t\tString dropcutoff = TimeUtil.nDaysBefore(_dayCode, 60);\n\t\t\n\t\tBufferedWriter pwrite = _segDataQ.getPathMan().getGimpWriter(_dayCode);\n\t\t\n\t\tint writecount = 0;\n\t\t\n\t\twhile(_segDataQ.hasNext())\n\t\t{\n\t\t\tSegmentPack bupnext = _segDataQ.nextPack();\n\t\t\t\n\t\t\twhile(!_sortFileMap.isEmpty() && _sortFileMap.firstKey().compareTo(bupnext.wtpid) < 0)\n\t\t\t{\n\t\t\t\t// This is a new WTP id that is not in the Master file, and was found for the first time today\n\t\t\t\tMap.Entry<String, List<String>> ent = _sortFileMap.pollFirstEntry();\n\t\t\t\t\n\t\t\t\tSegmentPack bupnew = _segDataQ.buildEmpty(ent.getKey());\n\t\t\t\tbupnew.integrateNewData(ent.getValue(), _dayCode);\n\t\t\t\twritecount += bupnew.write(pwrite, dropcutoff);\n\t\t\t\t_newUsers++;\n\t\t\t\t_newTotal++;\n\t\t\t}\n\t\t\t\n\t\t\tif(!_sortFileMap.isEmpty() && _sortFileMap.firstKey().equals(bupnext.wtpid))\n\t\t\t{\n\t\t\t\t// Here there is data in both the Master file and the day's slurped data\n\t\t\t\tMap.Entry<String, List<String>> ent = _sortFileMap.pollFirstEntry();\n\t\t\t\tbupnext.integrateNewData(ent.getValue(), _dayCode);\n\t\t\t\t_updateUsers++;\n\t\t\t\t\n\t\t\t} else {\n\t\t\t\t_noUpdateUsers++;\t\n\t\t\t}\n\t\t\t\n\t\t\t_newTotal++;\n\t\t\twritecount += bupnext.write(pwrite, dropcutoff);\n\t\t\t\n\t\t\tif((_segDataQ.getPollUserCount() % 10000) == 0)\n\t\t\t{\n\t\t\t\tUtil.pf(\".\");\n\t\t\t\t//double userpersec = bqueue.polledUsers /((Util.curtime()-startup)/1000);\n\t\t\t\t//Util.pf(\"Finished with %d users, %.03f users per second\\n\",\n\t\t\t\t//\tbqueue.polledUsers, userpersec);\n\t\t\t}\n\t\t}\n\t\t\n\t\tUtil.pf(\"\\n\");\n\t\t\n\t\twhile(!_sortFileMap.isEmpty())\n\t\t{\n\t\t\t// Write out remaining data.\n\t\t\tMap.Entry<String, List<String>> ent = _sortFileMap.pollFirstEntry();\n\t\t\t\n\t\t\tSegmentPack bupnew = _segDataQ.buildEmpty(ent.getKey());\n\t\t\tbupnew.integrateNewData(ent.getValue(), _dayCode);\t\t\t\n\t\t\t\t\t\n\t\t\t// TODO: this doesn't inform us about whether or not a user actually has any data associated with him\n\t\t\twritecount += bupnew.write(pwrite, dropcutoff);\t\n\t\t\t_newTotal++;\t\t\t\t\n\t\t}\n\t\t\n\t\tpwrite.close();\n\t\t\n\t\t// TODO: put these stats back in\n\t\t_logMail.pf(\"Finished merge, stats: \\n\\t%d updated users\\n\\t%d non-updated\\n\\t%d prev total\\n\\t%d new total\\n\",\n\t\t\t_updateUsers, _noUpdateUsers, _segDataQ.polledUsers, _newTotal);\n\t\t\n\t\t_logMail.pf(\"Master file size: \\n%d lines before\\n%d lines after\\n\", _segDataQ.linesRead, writecount);\n\t\t\n\t}",
"@Override\n public final boolean doIt() throws JobException {\n tasks = new LinkedHashMap<TaskKey,TaskJob>();\n prepareTasks();\n (new MergeJob()).startJob();\n return true;\n }",
"public void commitWait()\n {\n try{\n waitLock.lock();\n while(commitBarrierSector != -1){\n \t commitDone.awaitUninterruptibly();\n }\n return;\n }\n finally{\n waitLock.unlock();\n }\n }",
"void synchronizationDone();",
"public boolean acquireNoWait(boolean forMerge) {\r\n return true;\r\n }",
"boolean mergeJournalChanges(long commit_id) {\n\n // Average size of pending transactions when this method is called...\n ++TS_merge_count;\n TS_merge_size += transaction_mod_list.size();\n if ((TS_merge_count % 32) == 0) {\n system.stats().set(\n (int) ((TS_merge_size * 1000000L) / TS_merge_count),\n \"MultiVersionTableIndices.average_journal_merge_mul_1000000\");\n// DatabaseSystem.stats().set(\n// TS_merge_size / TS_merge_count,\n// \"MultiVersionTableIndices.average_journal_merge\");\n// DatabaseSystem.stats().set(\n// TS_merge_size,\n// \"MultiVersionTableIndices.TS_merge_size\");\n// DatabaseSystem.stats().set(\n// TS_merge_count,\n// \"MultiVersionTableIndices.TS_merge_count\");\n }\n\n int merge_count = 0;\n int size = transaction_mod_list.size();\n while (transaction_mod_list.size() > 0) {\n\n MasterTableJournal journal =\n (MasterTableJournal) transaction_mod_list.get(0);\n\n if (commit_id > journal.getCommitID()) {\n\n ++merge_count;\n if (Debug().isInterestedIn(Lvl.INFORMATION)) {\n Debug().write(Lvl.INFORMATION, this,\n \"Merging '\" + table_name + \"' journal: \" + journal);\n }\n\n // Remove the top journal entry from the list.\n transaction_mod_list.remove(0);\n system.stats().decrement(journal_count_stat_key);\n\n }\n else { // If (commit_id <= journal.getCommitID())\n return false;\n }\n }\n\n return true;\n\n }",
"@Override\n public abstract void merge(Mergeable merge);",
"@Test\n @Ignore(\"Not necessary anymore\")\n public void doWeNeedToRepointParentOrganisationsAfterMerge() {\n String line;\n Long mergingID;\n Long survivingID;\n List<Long> mergedIds = new ArrayList<>();\n int counter = 0;\n try {\n\n File file = new File(\"OrganisationsThatHaveBeenMergedOnVertec.txt\");\n\n FileReader reader = new FileReader(file.getAbsolutePath());\n BufferedReader breader = new BufferedReader(reader);\n while ((line = breader.readLine()) != null) {\n String[] parts = line.split(\",\");\n mergingID = Long.parseLong(parts[0]);\n survivingID = Long.parseLong(parts[1]);\n mergedIds.add(mergingID);\n\n }\n for (Long id : mergedIds) {\n String uri = baseURI + \"/org/\" + id;\n JSONOrganisation org = getFromVertec(uri, JSONOrganisation.class).getBody();\n if (!org.getChildOrganisationList().isEmpty() || org.getParentOrganisationId() != null) {\n System.out.println(\"parent: \" + org.getParentOrganisationId());\n System.out.println(\"child: \" + org.getChildOrganisationList());\n System.out.println(\"Org: \" + org.getName() + \"(v_id: \" + org.getObjid() + \")\");\n\n counter++;\n }\n }\n System.out.println(\"Total nr of merged away orgs with relatives: \" + counter);\n\n\n } catch (IOException e) {\n e.printStackTrace();\n }\n\n }",
"public void forceMerge() throws IOException {\n maintainMergeLocal();\n }",
"protected void synchronizationDone() {\n }",
"public void waitCompletion()\n {\n\n if (isThreadEnabled())\n {\n try\n {\n executionThread.join();\n }\n catch (InterruptedException ex)\n {\n throw new RuntimeException(ex);\n }\n }\n }",
"public Status waitUntilFinished();",
"MergeState merge() throws IOException {\n if (!shouldMerge()) {\n throw new IllegalStateException(\"Merge would result in 0 document segment\");\n }\n // NOTE: it's important to add calls to\n // checkAbort.work(...) if you make any changes to this\n // method that will spend alot of time. The frequency\n // of this check impacts how long\n // IndexWriter.close(false) takes to actually stop the\n // threads.\n mergeFieldInfos();\n setMatchingSegmentReaders();\n long t0 = 0;\n if (mergeState.infoStream.isEnabled(\"SM\")) {\n t0 = System.nanoTime();\n }\n int numMerged = mergeFields();\n if (mergeState.infoStream.isEnabled(\"SM\")) {\n long t1 = System.nanoTime();\n mergeState.infoStream.message(\"SM\", ((t1 - t0) / 1000000) + \" msec to merge stored fields [\" + numMerged + \" docs]\");\n }\n assert numMerged == mergeState.segmentInfo.getDocCount();\n\n final SegmentWriteState segmentWriteState = new SegmentWriteState(mergeState.infoStream, directory, mergeState.segmentInfo, mergeState.fieldInfos, termIndexInterval, null, context);\n if (mergeState.infoStream.isEnabled(\"SM\")) {\n t0 = System.nanoTime();\n }\n mergeTerms(segmentWriteState);\n if (mergeState.infoStream.isEnabled(\"SM\")) {\n long t1 = System.nanoTime();\n mergeState.infoStream.message(\"SM\", ((t1 - t0) / 1000000) + \" msec to merge postings [\" + numMerged + \" docs]\");\n }\n\n if (mergeState.infoStream.isEnabled(\"SM\")) {\n t0 = System.nanoTime();\n }\n if (mergeState.fieldInfos.hasDocValues()) {\n mergeDocValues(segmentWriteState);\n }\n if (mergeState.infoStream.isEnabled(\"SM\")) {\n long t1 = System.nanoTime();\n mergeState.infoStream.message(\"SM\", ((t1 - t0) / 1000000) + \" msec to merge doc values [\" + numMerged + \" docs]\");\n }\n\n if (mergeState.fieldInfos.hasNorms()) {\n if (mergeState.infoStream.isEnabled(\"SM\")) {\n t0 = System.nanoTime();\n }\n mergeNorms(segmentWriteState);\n if (mergeState.infoStream.isEnabled(\"SM\")) {\n long t1 = System.nanoTime();\n mergeState.infoStream.message(\"SM\", ((t1 - t0) / 1000000) + \" msec to merge norms [\" + numMerged + \" docs]\");\n }\n }\n\n if (mergeState.fieldInfos.hasVectors()) {\n if (mergeState.infoStream.isEnabled(\"SM\")) {\n t0 = System.nanoTime();\n }\n numMerged = mergeVectors();\n if (mergeState.infoStream.isEnabled(\"SM\")) {\n long t1 = System.nanoTime();\n mergeState.infoStream.message(\"SM\", ((t1 - t0) / 1000000) + \" msec to merge vectors [\" + numMerged + \" docs]\");\n }\n assert numMerged == mergeState.segmentInfo.getDocCount();\n }\n\n // write the merged infos\n FieldInfosWriter fieldInfosWriter = codec.fieldInfosFormat().getFieldInfosWriter();\n fieldInfosWriter.write(directory, mergeState.segmentInfo.name, \"\", mergeState.fieldInfos, context);\n\n return mergeState;\n }",
"void waitAndReleaseAllEntities();",
"@Override\r\n\tpublic void run() {\n\t\tLogCollateWorker worker = new LogCollateWorker(logDAO);\r\n\t\tworker.mergeOneBatch();\r\n\t}",
"private void applyMerge() {\n try {\n SolutionTrajectory trajectory = solution.getShortestTrajectory();\n trajectory.setModel(this.scope);\n trajectory.doTransformation();\n applied = true;\n } catch (IncQueryException e) {\n logger.error(e.getMessage(), e);\n }\n }",
"public static void merge(String in, long[] endPointers, String out)\n throws IOException {\n\n FileIO mergeFiles = new FileIO(in, out + \"Out.bin\");\n long[] currPointers = Arrays.copyOf(endPointers, endPointers.length\n - 1);\n Buffer[] runBuffers = new Buffer[currPointers.length];\n boolean[] runStatus = new boolean[runBuffers.length];\n for (int i = 0; i < currPointers.length; i++) {\n runBuffers[i] = new Buffer(1);\n runStatus[i] = false;\n }\n\n Buffer outBuffer = new Buffer(1);\n boolean mergeComplete = false;\n while (!mergeComplete) {\n\n for (int i = 0; i < runBuffers.length; i++) {\n if (!runStatus[i] && runBuffers[i].isEmpty()) {\n\n if (endPointers[i + 1] - currPointers[i] >= BLOCK_SIZE) {\n runBuffers[i].insertBlock(mergeFiles.getBlock(\n currPointers[i]));\n currPointers[i] = mergeFiles.getReadPointer();\n }\n else {\n runBuffers[i].insertBlock(mergeFiles.getPartialBlock(\n currPointers[i], endPointers[i + 1]));\n currPointers[i] = mergeFiles.getReadPointer();\n }\n if (currPointers[i] == endPointers[i + 1]) {\n runStatus[i] = true;\n }\n\n }\n }\n\n int bufferMinIdx = -1;\n Record min = null;\n for (int i = 0; i < runBuffers.length; i++) {\n if (!runBuffers[i].isEmpty()) {\n bufferMinIdx = i;\n min = runBuffers[i].getFirst();\n break;\n }\n }\n if (bufferMinIdx == -1) {\n if (outBuffer.isFull()) {\n mergeFiles.outBlock(outBuffer.removeBlock());\n }\n break;\n }\n for (int i = 0; i < runBuffers.length; i++) {\n if (!runBuffers[i].isEmpty() && min.compareTo(runBuffers[i]\n .getFirst()) > 0) {\n\n min = runBuffers[i].getFirst();\n bufferMinIdx = i;\n\n }\n\n }\n outBuffer.insertRecEnd(runBuffers[bufferMinIdx].removeRecFront());\n if (outBuffer.isFull()) {\n mergeFiles.outBlock(outBuffer.removeBlock());\n\n }\n\n }\n\n FileIO printFile = new FileIO(out + \"Out.bin\", \"Empty.bin\");\n int numRec = 0;\n while (printFile.getReadLength() != printFile.getReadPointer()) {\n outBuffer.insertBlock(printFile.getCurrBlock());\n System.out.print(outBuffer.removeRecFront().toString());\n numRec += 1;\n if (numRec % 5 == 0) {\n System.out.print(\"\\n\");\n }\n else {\n System.out.print(\" \");\n }\n }\n }",
"abstract void waitForRehashCompletion();",
"public static void waitForMasterDone() {\r\n try {\r\n master_done_semaphore.acquire();\r\n } catch (InterruptedException e) {\r\n }\r\n }",
"final void waitFinished() {\n if (selectionSyncTask != null) {\n selectionSyncTask.waitFinished();\n }\n }",
"private void waitForBackgroupTasks() {\n this.objectStore.getAllObjectIDs();\n this.objectStore.getAllEvictableObjectIDs();\n this.objectStore.getAllMapTypeObjectIDs();\n }",
"public void markTAdsRetrievalMerge() throws JNCException {\n markLeafMerge(\"tAdsRetrieval\");\n }",
"boolean isMerged();",
"public synchronized void waitForDone() {\n\twhile (!done) myWait();\n }",
"@Test\n public void testBatchMerge() throws Exception {\n final int BATCH_SIZE = 7;\n try (Connection con = GridCacheDynamicLoadOnClientTest.connect(GridCacheDynamicLoadOnClientTest.clientNode);Statement stmt = con.createStatement()) {\n for (int idx = 0, i = 0; i < BATCH_SIZE; ++i , idx += i) {\n stmt.addBatch((((((((((((\"merge into \" + (GridCacheDynamicLoadOnClientTest.FULL_TABLE_NAME)) + \" (_key, name, orgId) values (\") + (100 + idx)) + \",\") + \"'\") + \"batch-\") + idx) + \"'\") + \",\") + idx) + \")\"));\n }\n int[] updCnts = stmt.executeBatch();\n assertEquals(\"Invalid update counts size\", BATCH_SIZE, updCnts.length);\n }\n }",
"public void waitToFinish()\n {\n while(!this.finished)\n {\n try\n {\n Thread.sleep(1);\n }\n catch (InterruptedException e)\n {\n e.printStackTrace();\n return;\n }\n }\n }",
"public void finish() {\n latch.countDown();\n }",
"private void complete(MasterProcedureEnv env, Throwable error) {\n if (isFinished()) {\n LOG.info(\"This procedure {} is already finished, skip the rest processes\", this.getProcId());\n return;\n }\n if (event == null) {\n LOG.warn(\"procedure event for {} is null, maybe the procedure is created when recovery\",\n getProcId());\n return;\n }\n if (error == null) {\n LOG.info(\"finish snapshot {} on region {}\", snapshot.getName(), region.getEncodedName());\n succ = true;\n }\n\n event.wake(env.getProcedureScheduler());\n event = null;\n }",
"@Override\n public void close() throws IOException {\n flushCurrentIndexBlock();\n\n // logger.info(\"Performing final merge\");\n // try {\n //Bin finalMergeBin = geometricParts.getAllShards();\n //doMerge(finalMergeBin, getNextIndexShardFolder(finalMergeBin.size + 1));\n // check point is updated by the merge op.\n\n // } catch (IOException ex) {\n // Logger.getLogger(GeometricRetrieval.class.getName()).log(Level.SEVERE, null, ex);\n //}\n\n }",
"@Override\n public boolean waitToProceed() {\n return false;\n }",
"public void beforeCompletion()\n {\n \n boolean success = false;\n try\n {\n flush();\n // internalPreCommit() can lead to new updates performed by usercode \n // in the Synchronization.beforeCompletion() callback\n internalPreCommit();\n flush();\n success = true;\n }\n finally\n {\n if (!success) \n {\n // TODO Localise these messages\n NucleusLogger.TRANSACTION.error(\"Exception flushing work in JTA transaction. Mark for rollback\");\n try\n {\n jtaTx.setRollbackOnly();\n }\n catch (Exception e)\n {\n NucleusLogger.TRANSACTION.fatal(\n \"Cannot mark transaction for rollback after exception in beforeCompletion. PersistenceManager might be in inconsistent state\", e);\n }\n }\n }\n }",
"public interface MergeDataListener {\n\n public void beginToMergeEntity(BaseEntity entity);\n\n public void mergeEntityResult(BaseEntity entity, boolean successful, DeepThoughtError error);\n\n public void addingEntitiesDone(boolean successful, List<BaseEntity> entitiesSucceededToInsert, List<BaseEntity> entitiesFailedToInsert);\n\n}",
"boolean complete();",
"@Test\n public void testExecute() {\n for (int i = 0; i < 10; i++) {\n // create test objects\n List<TranslationFile> c = TestObjectBuilder.getCommittedTestCorpus();\n TranslationFile mainFile = c.get(0);\n Dispatcher d = TestObjectBuilder.getDispatcher(mainFile, c);\n mainFile = d.getState().getMainFile();\n\n // makes 5 segments\n Segment seg1 = mainFile.getActiveSegs().get(0);\n Segment seg2 = mainFile.getActiveSegs().get(1);\n Segment seg3 = mainFile.getActiveSegs().get(2);\n Segment seg4 = mainFile.getActiveSegs().get(3);\n Segment seg5 = mainFile.getActiveSegs().get(4);\n\n ArrayList<Segment> selectedSegs = new ArrayList();\n switch (i) {\n case 0: {\n // if i=0 --> 'merge' first seg (no change)\n\n selectedSegs.add(seg1);\n d.acceptAction(new Merge(selectedSegs));\n assertEquals(5, mainFile.getActiveSegs().size());\n assertEquals(0, mainFile.getHiddenSegs().size());\n assertEquals(mainFile.getActiveSegs().get(0).equals(seg1), true);\n assertEquals(mainFile.getActiveSegs().get(1).equals(seg2), true);\n assertEquals(mainFile.getActiveSegs().get(2).equals(seg3), true);\n assertEquals(mainFile.getActiveSegs().get(3).equals(seg4), true);\n assertEquals(mainFile.getActiveSegs().get(4).equals(seg5), true);\n\n assertEquals(mainFile, DatabaseOperations.getFile(mainFile.getFileID()));\n break;\n }\n case 1: {\n // if i=1 --> merge first two\n StringBuilder sb = new StringBuilder(seg1.getThai());\n sb.append(seg2.getThai()); // combine the Thai from both segs\n\n selectedSegs.add(seg1);\n selectedSegs.add(seg2);\n\n d.acceptAction(new Merge(selectedSegs));\n assertEquals(4, mainFile.getActiveSegs().size());\n assertEquals(2, mainFile.getHiddenSegs().size());\n assertEquals(sb.toString(), d.getUIState().getMainFileSegs().get(0).getThai());\n assertEquals(mainFile.getActiveSegs().get(1).equals(seg3), true);\n assertEquals(mainFile.getActiveSegs().get(2).equals(seg4), true);\n assertEquals(mainFile.getActiveSegs().get(3).equals(seg5), true);\n assertEquals(mainFile.getHiddenSegs().get(0).equals(seg1), true);\n assertEquals(mainFile.getHiddenSegs().get(1).equals(seg2), true);\n\n assertEquals(mainFile, DatabaseOperations.getFile(mainFile.getFileID()));\n break;\n }\n case 2: {\n // if i=2 --> merge first three\n StringBuilder sb = new StringBuilder(seg1.getThai());\n sb.append(seg2.getThai());\n sb.append(seg3.getThai());// combine the Thai from the three segs\n\n selectedSegs.add(seg1);\n selectedSegs.add(seg2);\n selectedSegs.add(seg3);\n d.acceptAction(new Merge(selectedSegs));\n assertEquals(3, mainFile.getActiveSegs().size());\n assertEquals(3, mainFile.getHiddenSegs().size());\n assertEquals(sb.toString(), d.getUIState().getMainFileSegs().get(0).getThai());\n assertEquals(seg4.getThai(), d.getUIState().getMainFileSegs().get(1).getThai());\n assertEquals(mainFile.getActiveSegs().get(1).equals(seg4), true);\n assertEquals(mainFile.getActiveSegs().get(2).equals(seg5), true);\n assertEquals(mainFile.getHiddenSegs().get(0).equals(seg1), true);\n assertEquals(mainFile.getHiddenSegs().get(1).equals(seg2), true);\n assertEquals(mainFile.getHiddenSegs().get(2).equals(seg3), true);\n\n assertEquals(mainFile, DatabaseOperations.getFile(mainFile.getFileID()));\n break;\n }\n case 3: {\n // if i=3 --> merge tu2-tu3\n StringBuilder sb = new StringBuilder(seg2.getThai());\n sb.append(seg3.getThai());\n\n selectedSegs.add(seg2);\n selectedSegs.add(seg3);\n d.acceptAction(new Merge(selectedSegs));\n assertEquals(4, mainFile.getActiveSegs().size());\n assertEquals(2, mainFile.getHiddenSegs().size());\n assertEquals(sb.toString(), d.getUIState().getMainFileSegs().get(1).getThai());\n assertEquals(seg1.getThai(), d.getUIState().getMainFileSegs().get(0).getThai());\n assertEquals(seg4.getThai(), d.getUIState().getMainFileSegs().get(2).getThai());\n assertEquals(mainFile.getActiveSegs().get(0).equals(seg1), true);\n assertEquals(mainFile.getActiveSegs().get(2).equals(seg4), true);\n assertEquals(mainFile.getActiveSegs().get(3).equals(seg5), true);\n assertEquals(mainFile.getHiddenSegs().get(0).equals(seg2), true);\n assertEquals(mainFile.getHiddenSegs().get(1).equals(seg3), true);\n\n assertEquals(mainFile, DatabaseOperations.getFile(mainFile.getFileID()));\n break;\n }\n // if i=4 --> merge 1-3\n case 4: {\n\n selectedSegs.add(seg2);\n selectedSegs.add(seg3);\n d.acceptAction(new Merge(selectedSegs));\n assertEquals(4, mainFile.getActiveSegs().size());\n assertEquals(2, mainFile.getHiddenSegs().size());\n assertEquals(mainFile.getActiveSegs().get(0).equals(seg1), true);\n assertEquals(mainFile.getActiveSegs().get(2).equals(seg4), true);\n assertEquals(mainFile.getActiveSegs().get(3).equals(seg5), true);\n assertEquals(mainFile.getHiddenSegs().get(0).equals(seg2), true);\n assertEquals(mainFile.getHiddenSegs().get(1).equals(seg3), true);\n\n assertEquals(mainFile, DatabaseOperations.getFile(mainFile.getFileID()));\n break;\n }\n // if i=5 --> merge 3-end\n case 5: {\n selectedSegs.add(seg1);\n selectedSegs.add(seg2);\n selectedSegs.add(seg3);\n d.acceptAction(new Merge(selectedSegs));\n assertEquals(3, d.getState().getMainFile().getActiveSegs().size());\n assertEquals(3, d.getState().getMainFile().getHiddenSegs().size());\n assertEquals(\"th1th2th3\", mainFile.getActiveSegs().get(0).getThai());\n assertEquals(mainFile.getActiveSegs().get(1).equals(seg4), true);\n assertEquals(mainFile.getActiveSegs().get(2).equals(seg5), true);\n assertEquals(mainFile.getHiddenSegs().get(0).equals(seg1), true);\n assertEquals(mainFile.getHiddenSegs().get(1).equals(seg2), true);\n assertEquals(mainFile.getHiddenSegs().get(2).equals(seg3), true);\n\n assertEquals(mainFile, DatabaseOperations.getFile(mainFile.getFileID()));\n break;\n }\n // if i=6 --> merge only end (no difference)\n case 6: {\n selectedSegs.add(seg5);\n d.acceptAction(new Merge(selectedSegs));\n assertEquals(5, mainFile.getActiveSegs().size());\n assertEquals(0, mainFile.getHiddenSegs().size());\n assertEquals(mainFile.getActiveSegs().get(0).equals(seg1), true);\n assertEquals(mainFile.getActiveSegs().get(1).equals(seg2), true);\n assertEquals(mainFile.getActiveSegs().get(2).equals(seg3), true);\n assertEquals(mainFile.getActiveSegs().get(3).equals(seg4), true);\n assertEquals(mainFile.getActiveSegs().get(4).equals(seg5), true);\n\n assertEquals(mainFile, DatabaseOperations.getFile(mainFile.getFileID()));\n break;\n }\n // if i=7 --> merge all segs\n case 7: {\n selectedSegs.add(seg1);\n selectedSegs.add(seg2);\n selectedSegs.add(seg3);\n selectedSegs.add(seg4);\n selectedSegs.add(seg5);\n d.acceptAction(new Merge(selectedSegs));\n assertEquals(1, mainFile.getActiveSegs().size());\n assertEquals(5, mainFile.getHiddenSegs().size());\n assertEquals(mainFile.getHiddenSegs().get(0).equals(seg1), true);\n assertEquals(mainFile.getHiddenSegs().get(1).equals(seg2), true);\n assertEquals(mainFile.getHiddenSegs().get(2).equals(seg3), true);\n assertEquals(mainFile.getHiddenSegs().get(3).equals(seg4), true);\n assertEquals(mainFile.getHiddenSegs().get(4).equals(seg5), true);\n\n assertEquals(mainFile, DatabaseOperations.getFile(mainFile.getFileID()));\n break;\n }\n // if i=8 --> selectedItems is empty (but not null)\n case 8: {\n d.acceptAction(new Merge(selectedSegs));\n assertEquals(5, mainFile.getActiveSegs().size());\n assertEquals(0, mainFile.getHiddenSegs().size());\n assertEquals(mainFile.getActiveSegs().get(0).equals(seg1), true);\n assertEquals(mainFile.getActiveSegs().get(1).equals(seg2), true);\n assertEquals(mainFile.getActiveSegs().get(2).equals(seg3), true);\n assertEquals(mainFile.getActiveSegs().get(3).equals(seg4), true);\n assertEquals(mainFile.getActiveSegs().get(4).equals(seg5), true);\n\n assertEquals(mainFile, DatabaseOperations.getFile(mainFile.getFileID()));\n break;\n }\n // if i=9 --> merge repeatedly\n case 9: {\n // merges seg1 and seg2\n selectedSegs.add(seg1);\n selectedSegs.add(seg2);\n d.acceptAction(new Merge(selectedSegs));\n\n //merges seg3 and seg4\n selectedSegs = new ArrayList();\n selectedSegs.add(seg3);\n selectedSegs.add(seg4);\n d.acceptAction(new Merge(selectedSegs));\n\n // at this point the file should have three segments in activeSegs\n // the first two segs are the result of the prior merges\n // the last seg is seg5\n // now we merge the second merged seg with seg5\n selectedSegs = new ArrayList();\n selectedSegs.add(mainFile.getActiveSegs().get(1));\n selectedSegs.add(seg5);\n d.acceptAction(new Merge(selectedSegs));\n\n // this should result in the file now only having two active segs\n assertEquals(2, mainFile.getActiveSegs().size());\n assertEquals(6, mainFile.getHiddenSegs().size());\n assertEquals(mainFile.getHiddenSegs().get(0).equals(seg1), true);\n assertEquals(mainFile.getHiddenSegs().get(1).equals(seg2), true);\n assertEquals(mainFile.getHiddenSegs().get(2).equals(seg3), true);\n assertEquals(mainFile.getHiddenSegs().get(3).equals(seg4), true);\n assertEquals(mainFile.getHiddenSegs().get(5).equals(seg5), true);\n\n assertEquals(mainFile, DatabaseOperations.getFile(mainFile.getFileID()));\n break;\n }\n // if i=10 --> merge invalid argument (segs not contiguous)\n case 10: {\n selectedSegs.add(seg1);\n selectedSegs.add(seg2);\n selectedSegs.add(seg3);\n selectedSegs.add(seg4);\n selectedSegs.add(seg2); // this seg is repeated and out of order\n d.acceptAction(new Merge(selectedSegs));\n\n assertEquals(5, mainFile.getActiveSegs().size());\n assertEquals(0, mainFile.getHiddenSegs().size());\n assertEquals(mainFile.getActiveSegs().get(0).equals(seg1), true);\n assertEquals(mainFile.getActiveSegs().get(1).equals(seg2), true);\n assertEquals(mainFile.getActiveSegs().get(2).equals(seg3), true);\n assertEquals(mainFile.getActiveSegs().get(3).equals(seg4), true);\n assertEquals(mainFile.getActiveSegs().get(4).equals(seg5), true);\n\n assertEquals(mainFile, DatabaseOperations.getFile(mainFile.getFileID()));\n break;\n }\n default:\n break;\n }\n\n }\n }",
"@Test\n\tpublic void test_synchronization() throws InterruptedException, ExecutionException {\n\t\t\n\t\tIkanowV1SyncService_LibraryJars s1 = new IkanowV1SyncService_LibraryJars(BeanTemplateUtils.clone(_service_config).with(\"v1_enabled\", true).done(), \n\t\t\t\t_service_context);\n\t\tIkanowV1SyncService_LibraryJars s2 = new IkanowV1SyncService_LibraryJars(BeanTemplateUtils.clone(_service_config).with(\"v1_enabled\", true).done(), \n\t\t\t\t_service_context);\n\t\tIkanowV1SyncService_LibraryJars s3 = new IkanowV1SyncService_LibraryJars(BeanTemplateUtils.clone(_service_config).with(\"v1_enabled\", true).done(), \n\t\t\t\t_service_context);\n\t\t\n\t\tint old = IkanowV1SyncService_LibraryJars._num_leader_changes;\n\t\t\n\t\ts1.start(); s2.start(); s3.start();\n\t\tfor (int i = 0; i < 4; ++i) {\n\t\t\ttry { Thread.sleep(1000); } catch (Exception e) {}\n\t\t}\n\t\ts1.stop(); s2.stop(); s3.stop();\n\t\t\n\t\tassertEquals(old + 1, IkanowV1SyncService_LibraryJars._num_leader_changes);\n\t\t\n\t\t@SuppressWarnings(\"unchecked\")\n\t\tfinal ICrudService<JsonNode> v1_config_db = _service_context.getCoreManagementDbService().getUnderlyingPlatformDriver(ICrudService.class, Optional.of(\"social.share\")).get();\t\t\t\t\n\t\t\n\t\tassertTrue(\"Query optimized\", v1_config_db.deregisterOptimizedQuery(Arrays.asList(\"title\")));\n\t\t\n\t}",
"public void waitForFinish() {\n for(Future future : futures){\n try {\n future.get();\n } catch (InterruptedException | ExecutionException e) {\n LOGGER.error(\"ERROR\",e);\n }\n }\n }",
"static void waitForBlockCommit() {\n try {\n Thread.sleep(5000);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n }",
"protected void mergeWith(ExceptionHandler eh) {\n BasicBlock succ = eh.getEntry();\n if (this.start_states[succ.getID()] == null) {\n if (TRACE_INTRA) out.println(succ+\" not yet visited.\");\n this.start_states[succ.getID()] = this.s.copy();\n for (Iterator i = rf.iterator(); i.hasNext(); ) {\n Register r = (Register) i.next();\n if (r.isTemp())\n this.start_states[succ.getID()].registers[r.getNumber()] = null;\n }\n this.change = true;\n } else {\n //if (TRACE_INTRA) out.println(\"merging out set of \"+bb+\" \"+Strings.hex8(this.s.hashCode())+\" into in set of ex handler \"+succ+\" \"+Strings.hex8(this.start_states[succ.getID()].hashCode()));\n if (TRACE_INTRA) out.println(\"merging out set of \"+bb+\" into in set of ex handler \"+succ);\n for (Iterator i = rf.iterator(); i.hasNext(); ) {\n Register r = (Register) i.next();\n if (r.isTemp()) continue;\n if (this.start_states[succ.getID()].merge(r.getNumber(), this.s.registers[r.getNumber()]))\n this.change = true;\n }\n if (TRACE_INTRA && this.change) out.println(succ+\" in set changed\");\n }\n }",
"void waitAll();",
"public static void synchronize() {\n awaitCompletion(READ_HANDLES);\n awaitCompletion(WRITE_HANDLES);\n }",
"private void handleCompleteAndStats() throws Exception {\n\t\tsynchronized (completedProcs) {\n\t\t\twhile (completedProcs.size() != nProc)\n\t\t\t\tcompletedProcs.wait();\n\t\t}\n\t\tinitiateTerminate();\n\t\t\n\t\tsynchronized (procStats) {\n\t\t\twhile (procStats.size() != nProc)\n\t\t\t\tprocStats.wait();\n\t\t}\n\t\t\n\t\taggregateStats();\n\t}",
"@Override\n public boolean isDone()\n {\n return false;\n }",
"@Override\r\n\tpublic void merge(Worker worker) {\n\t\tbaseDao.merge(worker);\r\n\t}",
"@Override\n public boolean isDone() {\n return false;\n }",
"public void automerge() {\n\t\tif (automerge) {\n\t\t\tfor(int i = 0; i<create_modifier+1;i++) {\n\t\t\t\tmerge();\n\t\t\t}\n\t\tif(autoidentify) {\n\t\t\tauto_identify_crystal(autoIdentifyTier); // replace this eventually\n\t\t}\n\t\t\t//collection();\n\t\t}\n\t}",
"void completeJob();",
"public void synchronize(){ \r\n }",
"public void checkFinish()\t{\n\t\tif(readCompareResult() == true)\t{\n\t\t\tfinished = true;\n\t\t}\n\t}",
"public void onMergeItemSelected();",
"private void waitFor() {\n if (done) {\n return;\n }\n\n synchronized (waitObj) {\n while (!done) {\n try {\n waitObj.wait();\n } catch (InterruptedException ex) {\n ex.printStackTrace(System.err);\n }\n }\n }\n if (excpetion != null) {\n throw excpetion;\n }\n }",
"@Override\r\n\tpublic void batchMerge(final List<?> entityList) {\n\t\tif (CollectionUtils.isEmpty(entityList)) {\r\n\t\t\tlogger.debug(\"Merge list is empty, no entity has been merged.\");\r\n\t\t\treturn;\r\n\t\t}\r\n\t\tthis.getJpaTemplate().execute(new JpaCallback<Object>() {\r\n\t\t\t@Override\r\n\t\t\tpublic Object doInJpa(EntityManager em) throws PersistenceException {\r\n\t\t\t\tint max = entityList.size();\r\n\t\t\t\tfor (int i = 0; i < max; i++) {\r\n\t\t\t\t\tem.merge(entityList.get(i));\r\n\t\t\t\t\tif ((i != 0 && i % DEFAULT_BATCH_SIZE == 0) || i == max - 1) {\r\n\t\t\t\t\t\tem.flush();\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t\tlogger.debug(\"{} entities has been merged.\", max);\r\n\t\t\t\treturn null;\r\n\t\t\t}\r\n\r\n\t\t});\r\n\t}",
"public void markVersionMerge() throws JNCException {\n markLeafMerge(\"version\");\n }",
"@Override\r\n protected void compute() {\r\n //if count != 0 || splitA.length == 1 then go, else for loop to make splitA.length subtasks to run splitArrayB and then they all call mergeAB\r\n if(global_count == 0){\r\n splitArrayB();\r\n }\r\n if(global_count != 0 || splitA.length == 1){\r\n mergeAB();\r\n }\r\n else{\r\n List<ConcurrentMerge> subtasks = new ArrayList<>();\r\n ConcurrentMerge temp;\r\n for(int i = 0; i < splitA.length; i++){\r\n global_count++;\r\n temp = new ConcurrentMerge(A, B, splitA, splitB, C, global_count);\r\n subtasks.add(temp);\r\n }\r\n invokeAll(subtasks);\r\n }\r\n }",
"public void lock() {\n if (!locked) {\n locked = true;\n sortAndTruncate();\n }\n }",
"void complete();",
"void complete();",
"private void runMerge(double[] heights, int numberOfThreads, List<List<Integer>> starts, List<List<List<double[]>>> animations) {\n // A counter to keep track of the time level\n int inc = 0;\n\n while(numberOfThreads >= 1) {\n // Each round of merging occurs at separate separate time levels\n List<List<double[]>> timeLevel = new ArrayList<List<double[]>>();\n animations.add(timeLevel);\n\n // Each time level has a different set of sorted sections\n List<Integer> startLevel = new ArrayList<Integer>();\n startLevel.add(0);\n starts.add(startLevel);\n\n List<Integer> currentStartLevel = starts.get(inc);\n\n // Executing merge for the current time level and generating the corresponding animations\n for(int iteration = 0; iteration < currentStartLevel.size() - 1; iteration += 2) {\n List<double[]> location = new ArrayList<double[]>();\n timeLevel.add(location);\n\n int startIndex = currentStartLevel.get(iteration);\n int middleIndex = currentStartLevel.get(iteration + 1) - 1;\n int endIndex;\n\n if(iteration == currentStartLevel.size() - 2) {\n endIndex = arrSize - 1;\n } else {\n endIndex = currentStartLevel.get(iteration + 2) - 1;\n startLevel.add(endIndex + 1);\n }\n\n MergeSort.merge(heights, startIndex, middleIndex, endIndex, location);\n }\n\n inc++;\n\n // The number of separately sorted sections is halved after ever stage of sorting\n numberOfThreads /= 2;\n }\n }",
"private void waitBetweenRead() {\n\t\ttry {\n\t\t\twait(250); // wait 250 ms before collecting data again\n\t\t} catch (InterruptedException e) {\n\t\t\te.printStackTrace();\n\t\t\treturn;\n\t\t}\n\t}",
"public void waitForData() {\n waitForData(1);\n }",
"public void markServiceMerge() throws JNCException {\n markLeafMerge(\"service\");\n }",
"private void awaitCleanUp() {\n\n // Get the first transaction awaiting clean up.\n StmTransaction firstTransAwaitingCleanUp = firstTransactionAwaitingCleanUp.get();\n\n // Link this transaction into the head of the list.\n this.nextTransactionAwaitingCleanUp.set( firstTransAwaitingCleanUp );\n\n // Spin until we do both atomically.\n while ( !firstTransactionAwaitingCleanUp.compareAndSet( firstTransAwaitingCleanUp, this ) ) {\n firstTransAwaitingCleanUp = firstTransactionAwaitingCleanUp.get();\n this.nextTransactionAwaitingCleanUp.set( firstTransAwaitingCleanUp );\n }\n\n }",
"@Override\n\tpublic boolean merge(final List<Partner> partners) {\n\t\tboolean result = true;\n\t\tresult = this.transactionTemplate.execute(new TransactionCallback<Boolean>() {\n\n\t\t\t@Override\n\t\t\tpublic Boolean doInTransaction(TransactionStatus status) {\n\t\t\t\tboolean result = true;\n\t\t\t\ttry{\n\t\t\t\t\t//step 1: batch delete related data\n\t\t\t\t\tString delete = \"DELETE FROM PARTNER WHERE PART_ID = :partId\";\n\t\t\t\t\tSqlParameterSource[] batch = SqlParameterSourceUtils.createBatch(partners.toArray());\n\t\t\t\t\tnamedParameterJdbcTemplate.batchUpdate(delete, batch);\n\t\t\t\t\t\n\t\t\t\t\t//step 2: batch insert sync data\n\t\t\t\t\tString insert = \"INSERT INTO PARTNER(NAME) VALUES(:fullName)\";\n\t\t\t\t\tnamedParameterJdbcTemplate.batchUpdate(insert, batch);\n\t\t\t\t}catch(Exception ex){\n\t\t\t\t\tstatus.setRollbackOnly();\n\t\t\t\t\tresult = false;\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\treturn result;\n\t\t\t}\n\t\t});\n\t\treturn result;\n\t}",
"@Override\n public void onComplete() {\n refCause.compareAndSet(null, DELIBERATE_EXCEPTION);\n }",
"public void doWait(){\n\t\tsynchronized(m){\n\t\t\ttry{\n\t\t\t\tm.wait(32000,0);\n\t\t\t} catch(InterruptedException e){}\n\t\t}\n\t}",
"@Override\n public boolean completed() {\n return false;\n }",
"public void merge(T entity) {\n\t\t\n\t}",
"public final void propagateCompletion()\n/* */ {\n/* 598 */ CountedCompleter localCountedCompleter1 = this;CountedCompleter localCountedCompleter2 = localCountedCompleter1;\n/* */ int i;\n/* 600 */ do { while ((i = localCountedCompleter1.pending) == 0) {\n/* 601 */ if ((localCountedCompleter1 = (localCountedCompleter2 = localCountedCompleter1).completer) == null) {\n/* 602 */ localCountedCompleter2.quietlyComplete();\n/* 603 */ return;\n/* */ }\n/* */ }\n/* 606 */ } while (!U.compareAndSwapInt(localCountedCompleter1, PENDING, i, i - 1));\n/* */ }",
"private static void merge(Gitlet currCommit, String[] args) {\n if (!isSure()) {\n return;\n } else if (args.length != 2) {\n System.out.println(\"Please input the branch name\");\n } else if (!currCommit.tree.hasBranch(args[1])) {\n System.out.println(\"A branch with that name does not exist.\");\n } else if (args[1].equals(currCommit.tree.getCurrentBranch())) {\n System.out.println(\"Cannot merge a branch with itself.\");\n } else {\n HashMap<String, String> splitMap = findSplitBranch(currCommit, args)\n .getFileLoc();\n HashMap<String, String> headMap = currCommit.tree.getHeadCommit()\n .getFileLoc();\n HashMap<String, String> mergeMap = currCommit.tree.getHeadCommit(\n args[1]).getFileLoc();\n for (String mergeFile : mergeMap.keySet()) {\n if (splitMap.containsKey(mergeFile)\n && headMap.containsKey(mergeFile)) {\n if (splitMap.get(mergeFile).equals(headMap.get(mergeFile))\n && !headMap.get(mergeFile).equals(\n mergeMap.get(mergeFile))) {\n FileManip origin = new FileManip(\n mergeMap.get(mergeFile));\n origin.copyFile(mergeFile);\n } else if (!splitMap.get(mergeFile).equals(\n headMap.get(mergeFile))\n && !splitMap.get(mergeFile).equals(\n mergeMap.get(mergeFile))) {\n FileManip origin = new FileManip(\n mergeMap.get(mergeFile));\n origin.copyFile(mergeFile + \".conflicted\");\n }\n } else if (!splitMap.containsKey(mergeFile)\n && headMap.containsKey(mergeFile)) {\n FileManip origin = new FileManip(mergeMap.get(mergeFile));\n if (!origin.isSame(headMap.get(mergeFile))) {\n origin.copyFile(mergeFile + \".conflicted\");\n }\n }\n }\n }\n }",
"public void waitJobPrepareSuccess(final String distSQL) {\n for (int i = 0; i < 5; i++) {\n List<Map<String, Object>> jobStatus = queryForListWithLog(distSQL);\n Set<String> statusSet = jobStatus.stream().map(each -> String.valueOf(each.get(\"status\"))).collect(Collectors.toSet());\n if (statusSet.contains(JobStatus.PREPARING.name()) || statusSet.contains(JobStatus.RUNNING.name())) {\n Awaitility.await().pollDelay(2L, TimeUnit.SECONDS).until(() -> true);\n }\n }\n }",
"@SuppressWarnings(\"SynchronizationOnLocalVariableOrMethodParameter\") // I know what I'm doing - famous last words.\n private static void awaitCompletion(final HashMultimap<UUID, Future<Void>> handles) {\n final Set<Future<Void>> futures;\n synchronized (handles) {\n futures = new HashSet<>(handles.values());\n handles.clear();\n }\n\n for (final Future<Void> future : futures) {\n await(future);\n }\n }",
"void merge_force_collapse() {\n while (this.n > 1) {\n int localN = this.n - 2;\n if (localN > 0 && this.len[localN-1] < this.len[localN+1])\n --localN;\n merge_at(localN);\n }\n }",
"private void waitUntilAllThreadsAreFinished() {\n int index = 1;\n\n while (true) {\n while (index <= noThread) {\n if (carry[index] == -1) {\n index = 1;\n } else {\n index++;\n }\n }\n break;\n }\n }",
"public boolean isDone() { return true; }",
"public void mergePrijavaAndCompleteTask(PrijavaEntity prijavaEntity) {\n // Merge detached order entity with current persisted state\n entityManager.merge(prijavaEntity);\n try {\n // Complete user task from\n taskForm.completeTask();\n } catch (IOException e) {\n // Rollback both transactions on error\n throw new RuntimeException(\"Cannot complete task\", e);\n }\n }",
"public final void waitFor() {\r\n for (;;) {\r\n synchronized (this) {\r\n if (this.m_b)\r\n return;\r\n try {\r\n this.wait();\r\n } catch (Throwable tt) {\r\n tt.printStackTrace();\r\n }\r\n }\r\n }\r\n }",
"void postMergeCommit(final ObserverContext<RegionServerCoprocessorEnvironment> ctx,\n final Region regionA, final Region regionB, final Region mergedRegion) throws IOException;",
"private void _wait() {\n\t\tfor (int i = 1000; i > 0; i--)\n\t\t\t;\n\t}",
"private void joinJtaTransaction() {\n\t\tif ( synchronizationRegistered ) {\n\t\t\tthrow new TransactionException( \"Hibernate RegisteredSynchronization is already registered for this coordinator\" );\n\t\t}\n\n\t\tjtaPlatform.registerSynchronization( new RegisteredSynchronization( getSynchronizationCallbackCoordinator() ) );\n\t\tgetSynchronizationCallbackCoordinator().synchronizationRegistered();\n\t\tsynchronizationRegistered = true;\n\t\tlog.debug( \"Hibernate RegisteredSynchronization successfully registered with JTA platform\" );\n\t}",
"public void waitForCompletion() throws Exception {\n latch.await();\n if (exception != null) {\n throw new RuntimeException(\"Query submission failed\", exception);\n }\n }",
"public synchronized void suspend(Object merge_id) {\n if(suspended)\n return;\n suspended=true;\n this.merge_id=merge_id;\n q.clear();\n waitUntilCompleted(MAX_COMPLETION_TIME);\n q.close(true);\n if(trace)\n log.trace(\"suspended ViewHandler\");\n Resumer r=new Resumer(resume_task_timeout, merge_id, resume_tasks, this);\n resume_tasks.put(merge_id, r);\n timer.add(r);\n }",
"private void merge(Document doc)\n throws PSFUDNullDocumentsException,\n PSFUDMergeDocumentsException\n {\n PSFUDDocMerger merger = new PSFUDDocMerger(m_snapshotDoc, doc);\n merger.merge(this);\n }",
"public void complete()\n {\n isComplete = true;\n }",
"@Test\n public void testMerge() {\n \t//create data set\n final LastWriteWinSet<String> lastWriteWinSet1 = new LastWriteWinSet<>();\n lastWriteWinSet1.add(time3, \"php\");\n lastWriteWinSet1.add(time1, \"java\");\n lastWriteWinSet1.add(time1, \"scala\");\n lastWriteWinSet1.delete(time2, \"scala\");\n\n final LastWriteWinSet<String> lastWriteWinSet2 = new LastWriteWinSet<>();\n lastWriteWinSet2.add(time1, \"php\");\n lastWriteWinSet2.add(time1, \"python\");\n lastWriteWinSet2.add(time1, \"scala\");\n lastWriteWinSet2.delete(time2, \"php\");\n\n // run test\n final LastWriteWinSet<String> resultSet = lastWriteWinSet1.merge(lastWriteWinSet2);\n\n assertTrue(resultSet.getData().size() == 3);\n assertTrue(resultSet.getData().contains(\"php\"));\n assertTrue(resultSet.getData().contains(\"python\"));\n assertTrue(resultSet.getData().contains(\"java\"));\n \n \n final GrowOnlySet<LastWriteWinSet.ItemTD<String>> resultAddSet = resultSet.getAddSet();\n final Set<LastWriteWinSet.ItemTD<String>> addedData = resultAddSet.getData();\n assertTrue(addedData.size() == 5);\n assertTrue(addedData.contains(new LastWriteWinSet.ItemTD<>(1, \"php\")));\n assertTrue(addedData.contains(new LastWriteWinSet.ItemTD<>(3, \"php\")));\n assertTrue(addedData.contains(new LastWriteWinSet.ItemTD<>(1, \"java\")));\n assertTrue(addedData.contains(new LastWriteWinSet.ItemTD<>(1, \"python\")));\n assertTrue(addedData.contains(new LastWriteWinSet.ItemTD<>(1, \"scala\")));\n\n final GrowOnlySet<LastWriteWinSet.ItemTD<String>> resultDeleteSet = resultSet.getDeleteSet();\n final Set<LastWriteWinSet.ItemTD<String>> deletedData = resultDeleteSet.getData();\n assertTrue(deletedData.size() == 2);\n assertTrue(deletedData.contains(new LastWriteWinSet.ItemTD<>(2, \"scala\")));\n assertTrue(deletedData.contains(new LastWriteWinSet.ItemTD<>(2, \"php\")));\n }",
"void onMerge(OnException onException, Connection conn, String sql,\r\n String keyField, long row)\r\n throws Exception;",
"protected void waitUntilCommandFinished() {\n }",
"@Test\r\n\tpublic void testConcurentUpdate() throws InterruptedException, ExecutionException{\r\n\t\tfinal Annotations annos = new Annotations();\r\n\t\t// Apply these annos to this node.\r\n\t\tannos.setId(KeyFactory.keyToString(node.getId()));\r\n\t\tannos.addAnnotation(\"stringKey\", \"String\");\r\n\t\t\r\n\t\tLoopingAnnotaionsWoker workerOne = new LoopingAnnotaionsWoker(dboAnnotationsDao, 10, annos);\r\n\t\tLoopingAnnotaionsWoker workerTwo = new LoopingAnnotaionsWoker(dboAnnotationsDao, 10, annos);\r\n\t\t// Start both workers\r\n\t\tExecutorService pool = Executors.newFixedThreadPool(2);\r\n\t\tFuture<Boolean> furtureOne = pool.submit(workerOne);\r\n\t\tFuture<Boolean> furtureTwo = pool.submit(workerTwo);\r\n\t\t// Wait for the threads to finish.\r\n\r\n\t\tassertTrue(furtureOne.get());\r\n\t\tassertTrue(furtureTwo.get());\r\n\r\n\t\t// There should be no duplication.\r\n\t\tAnnotations clone = dboAnnotationsDao.getAnnotations(node.getId());\r\n\t\t// There should be no duplication.\r\n\t\tassertNotNull(clone);\r\n\t\tCollection list = clone.getAllValues(\"stringKey\");\r\n\t\tassertNotNull(list);\r\n\t\tassertEquals(\"There should only be one value for this annotations. That means multiple threads caused duplication!\", 1, list.size());\r\n\t\tassertEquals(\"String\", list.iterator().next() );\r\n\t}",
"public void waitToFinish()\n/* */ {\n/* 473 */ synchronized (this) {\n/* 474 */ while (getIterationsToGo() > 0) {\n/* */ try {\n/* 476 */ wait();\n/* */ }\n/* */ catch (InterruptedException e) {\n/* 479 */ e.printStackTrace();\n/* */ }\n/* */ }\n/* */ }\n/* */ }",
"public static Entity merge(Entity seed, Entity targ)\r\n/* 29: */ {\r\n/* 30:42 */ Entity newThing = new Entity();\r\n/* 31:43 */ Bundle newBundle = new Bundle();\r\n/* 32:44 */ newThing.setBundle(newBundle);\r\n/* 33: */ \r\n/* 34: */ \r\n/* 35:47 */ List<Point<Thread>> seedList = getPointList(seed.getBundle());\r\n/* 36:48 */ List<Point<Thread>> targList = getPointList(targ.getBundle());\r\n/* 37:49 */ Map<Point<Thread>, Point<Thread>> bestMatches = Operations.hungarian(seedList, targList);\r\n/* 38:51 */ if (bestMatches.keySet().containsAll(seedList))\r\n/* 39: */ {\r\n/* 40:53 */ for (Point<Thread> t : bestMatches.keySet())\r\n/* 41: */ {\r\n/* 42:54 */ Thread mergedThread = pruneThread((Thread)t.getWrapped(), (Thread)((Point)bestMatches.get(t)).getWrapped());\r\n/* 43:55 */ targList.remove(bestMatches.get(t));\r\n/* 44:56 */ newBundle.add(mergedThread);\r\n/* 45: */ }\r\n/* 46:59 */ for (Point<Thread> remaining : targList) {\r\n/* 47:60 */ newBundle.add((Thread)remaining.getWrapped());\r\n/* 48: */ }\r\n/* 49: */ }\r\n/* 50: */ else\r\n/* 51: */ {\r\n/* 52:65 */ for (Point<Thread> t : bestMatches.keySet())\r\n/* 53: */ {\r\n/* 54:66 */ Thread mergedThread = pruneThread((Thread)((Point)bestMatches.get(t)).getWrapped(), (Thread)t.getWrapped());\r\n/* 55:67 */ newBundle.add(mergedThread);\r\n/* 56: */ }\r\n/* 57: */ }\r\n/* 58:71 */ return newThing;\r\n/* 59: */ }",
"@Override\n \tprotected void doWaitExecution() throws CoreException {\n \t\ttry {\n \t\t\tstderrObserver.join();\n \t\t} catch (InterruptedException e1) {\n \t\t\te1.printStackTrace();\n \t\t}\n //\t\tSystem.err.println(\"stderr finished\");\n \t\ttry {\n \t\t\tstdoutObserver.join();\n \t\t} catch (InterruptedException e1) {\n \t\t\te1.printStackTrace();\n \t\t}\n //\t\tSystem.err.println(\"stdout finished\");\n \t\t/*\n \t\t * Still experience has shown that remote process might not have yet terminated, although stdout and stderr is closed.\n \t\t */\n \t\ttry {\n \t\t\tprocess.waitFor();\n \t\t} catch (InterruptedException e) {\n \t\t\t// Ignore\n \t\t}\n \t}",
"private void merge(int numRuns, exComparator myComp) throws IOException {\n\t\t// Pass 1 and any following\n\t\t// Read in the partial sorted runs from last pass; Merge; Write out;\n\t\tTupleReader[] mergeReader = new TupleReader[B - 1];\n\t\tint pass = 1;\n\t\tint numRunsToBuild = 0;\n\t\tPriorityQueue<Tuple> tempMerg = new PriorityQueue<Tuple>(myComp);\n\t\tInteger marker = null;\n\t\twhile(true) {\n\t\t\t// last pass: pass-1 , # runs: numRuns;\n\t\t\t// this pass: pass , # runs: numRunsToBuild;\n\t\t\tnumRunsToBuild = numRuns % (B - 1) == 0 ? numRuns / (B - 1) : (numRuns / (B - 1) + 1);\n\t\t\tMap<Tuple, Integer> findReader;\n\t\t\tfor(int i = 0; i < numRunsToBuild; i++) {\n\t\t\t\tfindReader = new HashMap<>();\n\t\t\t\tfor(int j = 0; j < B - 1; j++) {\n\t\t\t\t\tint runIndex = i * (B - 1) + j + 1; // index of the run to be read in last pass, which is (pass - 1)\n\t\t\t\t\tif(runIndex > numRuns) {\n\t\t\t\t\t\tmarker = j;\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t\tmergeReader[j] = new TupleReader(tempsubdir + String.valueOf(pass-1) + \"_\" + runIndex);\n\t\t\t\t}\n\t\t\t\t\n//\t\t\t\tSystem.out.println(\"Pass\" + pass + \",\" + i + \"th Run\");\n\t\t\t\tint numReader = marker == null ? B - 1 : marker;\n\t\t\t\tfor(int k = 0; k < numReader; k++) {\n\t\t\t\t\tTuple temp = mergeReader[k].getNextTuple();\n\t\t\t\t\tif(temp == null) {\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\t\t\t\t\ttempMerg.offer(temp);\n\t\t\t\t\tfindReader.put(temp, k);\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\tTupleWriter TW;\n\t\t\t\tif(numRunsToBuild == 1) {\n\t\t\t\t\tTW = new TupleWriter(new FileOutputStream(tempsubdir + \"sortResult\"));\n\t\t\t\t} else {\n\t\t\t\t\tTW = new TupleWriter(new FileOutputStream(tempsubdir + pass + \"_\" + String.valueOf(i + 1)));\n\t\t\t\t}\n\t\t\t\twhile(!tempMerg.isEmpty()) {\n\t\t\t\t\tTuple temp = tempMerg.poll();\n\t\t\t\t\tTW.setNextTuple(temp);\n\t\t\t\t\tTuple next = mergeReader[findReader.get(temp)].getNextTuple();\n\t\t\t\t\tif(next != null) {\n\t\t\t\t\t\ttempMerg.offer(next);\n\t\t\t\t\t\tfindReader.put(next, findReader.get(temp));\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tif(!TW.bufferEmpty()) {\n\t\t\t\t\tTW.fillFlush(); \n\t\t\t\t}\n\t\t\t\tTW.close();\n\t\t\t\tfor(int k = 0; k < numReader; k++) {\n\t\t\t\t\tmergeReader[k].close();\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\tif(numRunsToBuild == 1) {\n\t\t\t\tbreak;\n\t\t\t}\n\t\t\tnumRuns = numRunsToBuild;\n\t\t\tpass++;\n\t\t\tmarker = null;\n\t\t}\n\t}",
"public void doWait() {\n\t\tsynchronized(lock) {\n\t\t\twhile(!wasSignalled) {\n\t\t\t\ttry {\n\t\t\t\t\tlock.wait();\n\t\t\t\t} catch (InterruptedException e) {\n\t\t\t\t\te.printStackTrace();\n\t\t\t\t}\n\t\t\t}\n\t\t\twasSignalled = false;\n\t\t}\n\t}"
] | [
"0.66782784",
"0.6343929",
"0.62221545",
"0.6031981",
"0.59775835",
"0.5914218",
"0.58233166",
"0.58095706",
"0.5771909",
"0.56802803",
"0.56718147",
"0.56338084",
"0.5589577",
"0.557559",
"0.55200505",
"0.54978883",
"0.5491705",
"0.5446109",
"0.54409456",
"0.5385901",
"0.5366195",
"0.5342144",
"0.5284809",
"0.5272837",
"0.52713454",
"0.52165055",
"0.51884234",
"0.5187596",
"0.5186509",
"0.51774716",
"0.5174795",
"0.5141241",
"0.51399827",
"0.51354545",
"0.5128111",
"0.5118284",
"0.5100346",
"0.50867337",
"0.5080862",
"0.50791264",
"0.5068823",
"0.5051942",
"0.50436944",
"0.50320065",
"0.5024884",
"0.50213",
"0.50207716",
"0.5016548",
"0.49975902",
"0.49837568",
"0.49769074",
"0.49620375",
"0.49548197",
"0.4954021",
"0.4950401",
"0.4935459",
"0.49291295",
"0.4922871",
"0.49171764",
"0.49158758",
"0.4908234",
"0.49043578",
"0.48950458",
"0.48928744",
"0.48710075",
"0.48710075",
"0.48623362",
"0.48602808",
"0.4838144",
"0.4833833",
"0.48317224",
"0.48309737",
"0.4830443",
"0.48210502",
"0.48190683",
"0.48140508",
"0.48126212",
"0.48084876",
"0.48063514",
"0.4805538",
"0.48035714",
"0.47953188",
"0.479519",
"0.47939253",
"0.47894478",
"0.4778569",
"0.47707808",
"0.476756",
"0.47665286",
"0.47627103",
"0.4756102",
"0.47519314",
"0.47494385",
"0.47484112",
"0.47469226",
"0.47468847",
"0.4746291",
"0.47440088",
"0.47394404",
"0.4739164",
"0.4729157"
] | 0.0 | -1 |
Creates kontakt db record | public String createKontakt(String hodnota, String typ, String cislo_rp) {
Session session = sessionFactory.openSession();
Transaction tx = null;
try {
tx = session.beginTransaction();
Kontakt kontakt = new Kontakt(hodnota, typ, cislo_rp);
hodnota = (String) session.save(kontakt);
tx.commit();
} catch (HibernateException e) {
e.printStackTrace();
} finally {
session.close();
}
return hodnota;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"int insert(PmKeyDbObj record);",
"public Long createRecord(Record object);",
"int insert(DBPublicResources record);",
"int insert(ActivityHongbaoPrize record);",
"int insert(Kaiwa record);",
"int insert(PmPost record);",
"int insert(CmsRoomBook record);",
"int insert(cskaoyan_mall_order_goods record);",
"int insert(Prueba record);",
"@Override\r\n\tpublic boolean create(Moteur obj, Connection conn) throws SQLException {\n\t\treturn false;\r\n\t}",
"int insert(Assist_table record);",
"int insert(NjProductTaticsRelation record);",
"int insert(AccessModelEntity record);",
"void insert(BnesBrowsingHis record) throws SQLException;",
"int insert(FinancialManagement record);",
"int insert(FundManagerDo record);",
"int insert(GoodsPo record);",
"int insert(DashboardGoods record);",
"void insert(Disproduct record);",
"int insert(Ltsprojectpo record);",
"int insert(FinMonthlySnapModel record);",
"int insert(GirlInfo record);",
"int insert(UserInfo record);",
"int insert(SrHotelRoomInfo record);",
"@Test\r\n public void testCreate() {\r\n ActivityRecord record = setActivityRecord();\r\n recordDao.create(record);\r\n assertNotNull(record.getId());\r\n }",
"int insert(PayLogInfoPo record);",
"int insert(PrefecturesMt record);",
"Purchase create(Purchase purchase) throws SQLException, DAOException;",
"String insert(BookDO record);",
"int insert(UserPonumberGoods record);",
"Long insert(Access record);",
"int insert(Tourst record);",
"int insert(BusinessRepayment record);",
"int insert(ActActivityRegister record);",
"int insert(WayShopCateRoot record);",
"int insert(TbSerdeParams record);",
"int insert(Forumpost record);",
"void insert(GfanCodeBanner record) throws SQLException;",
"int insert(TrainingCourse record);",
"Integer insert(JzAct record);",
"int insert(ResourcePojo record);",
"int insert(NeeqCompanyAccountingFirmOnline record);",
"int insert(Model record);",
"int insert(CliStaffProject record);",
"int insert(TVmManufacturer record);",
"int insert(AutoAssessDetailWithBLOBs record);",
"int insert(TrainCourse record);",
"int insert(CraftAdvReq record);",
"int insert(PublicDoctorNotice record);",
"int insert(AnnouncementDO record);",
"int insert(OrderDetail record);",
"int insert(Storydetail record);",
"int insert(CartDO record);",
"void insert(OrderPreferential record) throws SQLException;",
"int insert(Factory record);",
"int insert(Caiwu record);",
"public void create(Singer newRecord);",
"int insert(NjOrderWork2 record);",
"int insert(OcCustContract record);",
"void insert(CTipoPersona record) throws SQLException;",
"int insert(Tipologia record);",
"int insert(Goods record);",
"int insert(NewsInfo record);",
"int insert(Movimiento record);",
"public static void insertLutenicaRecordToDB(LocalDateTime date, int quantity, String babaName){\n try {\n dbDAO.getInstance().createLutenicaRecord(date, quantity, babaName);\n System.out.println(\"Lutenica record was added to db\");\n } catch (SQLException e) {\n e.printStackTrace();\n }\n }",
"int insert(SysId record);",
"int insert(ProSchoolWare record);",
"int insert(TCpySpouse record);",
"int insert(Basicinfo record);",
"int insert(BankUserInfo record);",
"int insert(BankUserInfo record);",
"int insert(Cargo record);",
"int insert(RetailModule record);",
"int insert(Course record);",
"int insert(Course record);",
"int insert(TbComEqpModel record);",
"@Override\n\tpublic boolean create(Document obj) {\n\t\tSystem.out.println(obj);\n\t\tString sql = \"INSERT INTO public.documents( nom, etape_id, process_id)\\r\\n\"\n\t\t\t\t+ \"\tVALUES ('\" + obj.getNom() + \"', \" + obj.getId_etape()+ \" , \"+obj.getId_process()+\");\";\n\t\ttry {\n\t\t\tSystem.out.println(sql);\n\t\t\tPreparedStatement statement = this.connect.prepareStatement(sql);\n\t\t\tstatement.execute();\n\t\t\treturn true;\n\t\t} catch (Exception e) {\n\t\t\te.printStackTrace();\n\t\t\treturn false;\n\t\t}\n\t}",
"@Insert({\n \"insert into NEWS (NEWS_ID, TITLE, \",\n \"BODY, IMG_URL, URL, \",\n \"CREATE_TIME)\",\n \"values (#{newsId,jdbcType=INTEGER}, #{title,jdbcType=VARCHAR}, \",\n \"#{body,jdbcType=VARCHAR}, #{imgUrl,jdbcType=VARCHAR}, #{url,jdbcType=VARCHAR}, \",\n \"#{createTime,jdbcType=TIMESTAMP})\"\n })\n int insert(News record);",
"int insert(PurchasePayment record);",
"int insert(ApplicationDO record);",
"int insert(Project record);",
"int insert(TmpUserPayAccount record);",
"void insert(PaymentTrade record);",
"void insert(CTipoComprobante record) throws SQLException;",
"void insert(Mi004 record);",
"public Object create() {\n executeCallbacks(CallbackType.BEFORE_CREATE);\n\n executeCallbacks(CallbackType.BEFORE_VALIDATION);\n executeValidations();\n executeValidationsOnCreate();\n executeCallbacks(CallbackType.AFTER_VALIDATION);\n\n if (errors.size() > 0) return this;\n\n Adapter adapter = getAdapter();\n if (getId() == null && adapter.shouldPrefetchPrimaryKey(getTableName())) {\n this.id = adapter.getNextSequenceValue(getSequenceName());\n }\n\n StringBuilder sql = new StringBuilder();\n sql.append(\"INSERT INTO \").append(getTableName()).append(\" (\");\n sql.append(quotedColumnNames(includePrimaryKey));\n sql.append(\") VALUES (\").append(quotedAttributeValues(includePrimaryKey)).append(\")\");\n\n id = adapter.insert(sql.toString(), getClass().getName() + \" Create\");\n\n readAssociations();\n readAggregations();\n\n newRecord = false;\n\n executeCallbacks(CallbackType.AFTER_CREATE);\n\n return id;\n }",
"int insert(Appraise record);",
"int insert(WizardValuationHistoryEntity record);",
"int insert(HotelType record);",
"int insert(AliUserInfoDO record);",
"void insert(IrpSignInfo record) throws SQLException;",
"int insert(ParkCurrent record);",
"int insert(Lbm83ChohyokanriPkey record);",
"int insert(HomeWork record);",
"int insertSelective(PmKeyDbObj record);",
"public void addRecord();",
"int insert(UserOperateProject record);",
"int insert(Enfermedad record);",
"int insert(Commet record);",
"int insert(RegsatUser record);",
"@Insert({\n \"insert into kd_user_medal (id, userid, \",\n \"medalId, bindUserid, \",\n \"remark, createTime)\",\n \"values (#{id,jdbcType=BIGINT}, #{userid,jdbcType=BIGINT}, \",\n \"#{medalid,jdbcType=BIGINT}, #{binduserid,jdbcType=BIGINT}, \",\n \"#{remark,jdbcType=VARCHAR}, #{createtime,jdbcType=TIMESTAMP})\"\n })\n int insert(KDUserMedal record);"
] | [
"0.7016634",
"0.6889229",
"0.6872137",
"0.66565734",
"0.6631391",
"0.6625782",
"0.6621227",
"0.66180253",
"0.66118646",
"0.6609202",
"0.66048205",
"0.6584894",
"0.6555097",
"0.6544054",
"0.654376",
"0.6539767",
"0.6507511",
"0.6502038",
"0.6495745",
"0.64872164",
"0.64696485",
"0.6455208",
"0.6454285",
"0.6446855",
"0.64456",
"0.64438987",
"0.6434355",
"0.64342684",
"0.6427492",
"0.64254606",
"0.641872",
"0.641603",
"0.64148796",
"0.6412845",
"0.640841",
"0.6404755",
"0.6403432",
"0.6400625",
"0.638435",
"0.63834685",
"0.63810915",
"0.63784915",
"0.6370028",
"0.63584715",
"0.63550067",
"0.6352464",
"0.63499427",
"0.63481987",
"0.63477635",
"0.6345267",
"0.6341413",
"0.6340851",
"0.63372177",
"0.63362736",
"0.63361573",
"0.6331672",
"0.6329378",
"0.6324645",
"0.6324353",
"0.63151056",
"0.6314998",
"0.6309992",
"0.6309413",
"0.6307714",
"0.63074684",
"0.63017404",
"0.63015324",
"0.63010776",
"0.6299796",
"0.6298448",
"0.6298448",
"0.62961125",
"0.6295324",
"0.62929845",
"0.62929845",
"0.6290981",
"0.62909025",
"0.62870044",
"0.6286881",
"0.62835777",
"0.62833834",
"0.6275562",
"0.62738675",
"0.6270771",
"0.626966",
"0.62685245",
"0.6265026",
"0.62625074",
"0.6261566",
"0.6257192",
"0.62568593",
"0.62564814",
"0.62542737",
"0.62510693",
"0.6243976",
"0.623897",
"0.62372357",
"0.6235237",
"0.62348187",
"0.6232628",
"0.62252355"
] | 0.0 | -1 |
Created by redcarpet on 4/17/17. | public interface FaceTrackingListener {
void onFaceLeftMove();
void onFaceRightMove();
void onFaceUpMove();
void onFaceDownMove();
void onGoodSmile();
void onEyeCloseError();
void onMouthOpenError();
void onMultipleFaceError();
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@Override\n public void perish() {\n \n }",
"@Override\n\tpublic void grabar() {\n\t\t\n\t}",
"@Override\n\tpublic void comer() {\n\t\t\n\t}",
"@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}",
"public final void mo51373a() {\n }",
"@Override\n\tprotected void interr() {\n\t}",
"@Override\r\n\tpublic void tires() {\n\t\t\r\n\t}",
"@Override\n\tpublic void sacrifier() {\n\t\t\n\t}",
"@Override\n public void func_104112_b() {\n \n }",
"private stendhal() {\n\t}",
"@Override\n\tpublic void anular() {\n\n\t}",
"@Override\n\tpublic void nadar() {\n\t\t\n\t}",
"public void gored() {\n\t\t\n\t}",
"@Override\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}",
"@Override\n\tpublic void entrenar() {\n\t\t\n\t}",
"@Override\r\n\tpublic void dormir() {\n\t\t\r\n\t}",
"@Override\n\tpublic void ligar() {\n\t\t\n\t}",
"@Override\n\tpublic void one() {\n\t\t\n\t}",
"private void poetries() {\n\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\r\n\tpublic void rozmnozovat() {\n\t}",
"@Override\n\tprotected void getExras() {\n\n\t}",
"@Override\n public void init() {\n\n }",
"@Override\r\n\tpublic void anularFact() {\n\t\t\r\n\t}",
"protected boolean func_70814_o() { return true; }",
"@Override\r\n\t\tpublic void init() {\n\t\t\t\r\n\t\t}",
"private void m50366E() {\n }",
"public void mo38117a() {\n }",
"@Override\n\tpublic void jugar() {\n\t\t\n\t}",
"@Override\n\tpublic void gravarBd() {\n\t\t\n\t}",
"@Override\r\n\t\t\tpublic void annadir() {\n\r\n\t\t\t}",
"@Override\n public void init() {\n }",
"@Override\n\tprotected void initialize() {\n\t\t\n\t}",
"@Override\n\tprotected void initialize() {\n\t\t\n\t}",
"@Override\n protected void init() {\n }",
"@Override\n protected void initialize() {\n\n \n }",
"public void mo4359a() {\n }",
"@Override\n public void init() {}",
"@Override\n void init() {\n }",
"@Override\n protected void initialize() {\n }",
"@Override\n protected void initialize() {\n }",
"@Override\n protected void initialize() {\n }",
"@Override\n protected void initialize() {\n }",
"@Override\n protected void initialize() {\n }",
"@Override\n protected void initialize() {\n }",
"@Override\r\n\tpublic void init() {}",
"@Override\n\tpublic void init() {\n\n\t}",
"@Override\n\tpublic void init() {\n\n\t}",
"@Override\n\tpublic void init() {\n\n\t}",
"@Override\r\n\tprotected void doF4() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void init() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void init() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void init() {\n\t\t\r\n\t}",
"@Override\n\tpublic void nghe() {\n\n\t}",
"@Override\r\n\tpublic void init() {\n\r\n\t}",
"@Override\r\n\tpublic void init() {\n\r\n\t}",
"@Override\r\n\tpublic void init() {\n\r\n\t}",
"@Override\n public void init() {\n\n }",
"@Override\n public void init() {\n\n }",
"@Override\n\tpublic int mettreAJour() {\n\t\treturn 0;\n\t}",
"@Override\r\n\t\t\tpublic void ayuda() {\n\r\n\t\t\t}",
"@Override\n\tprotected void initialize() {\n\n\t}",
"@Override\n public int describeContents() { return 0; }",
"@Override\n\tpublic void einkaufen() {\n\t}",
"private static void cajas() {\n\t\t\n\t}",
"@Override\n public int retroceder() {\n return 0;\n }",
"private void kk12() {\n\n\t}",
"@Override\n protected void initialize() \n {\n \n }",
"@Override\n\tpublic void init() {\n\t}",
"@Override\r\n\tpublic void init()\r\n\t{\n\t}",
"@Override\n\tpublic void debite() {\n\t\t\n\t}",
"@Override\r\n\tprotected void initialize() {\r\n\t\t\r\n\t\t\r\n\t}",
"@Override\n protected void getExras() {\n }",
"@Override\n\tpublic void init()\n\t{\n\n\t}",
"private void init() {\n\n\t}",
"@Override\n\tprotected void update() {\n\t\t\n\t}",
"@Override\r\n\tprotected void doF6() {\n\t\t\r\n\t}",
"private Rekenhulp()\n\t{\n\t}",
"@Override\r\n\tpublic void dibujar() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void dibujar() {\n\t\t\r\n\t}",
"public void method_4270() {}",
"public void skystonePos4() {\n }",
"@Override\r\n\tpublic void just() {\n\t\t\r\n\t}",
"@Override\n\tpublic void nefesAl() {\n\n\t}",
"@Override\r\n\tprotected void doF8() {\n\t\t\r\n\t}",
"private void m50367F() {\n }",
"@Override\n\tprotected void initialize() {\n\t}",
"@Override\n\tprotected void initialize() {\n\t}",
"public void skystonePos6() {\n }",
"@Override\n\t\tpublic void init() {\n\t\t}",
"@Override\n public void initialize() { \n }",
"@Override\n public void memoria() {\n \n }",
"@Override\r\n\tprotected void initialize() {\n\r\n\t}",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }"
] | [
"0.62159437",
"0.60338163",
"0.590942",
"0.5898791",
"0.5898791",
"0.5848863",
"0.5825372",
"0.5823172",
"0.5803105",
"0.58010757",
"0.5796801",
"0.57901484",
"0.57674885",
"0.57550365",
"0.5748086",
"0.57473844",
"0.5714159",
"0.5686956",
"0.5681291",
"0.56758744",
"0.5666237",
"0.5666237",
"0.5666237",
"0.5666237",
"0.5666237",
"0.5656882",
"0.565118",
"0.56449705",
"0.5617301",
"0.5616132",
"0.5615009",
"0.5611454",
"0.56092536",
"0.5608085",
"0.5604664",
"0.56022656",
"0.5574559",
"0.5561008",
"0.5561008",
"0.5527561",
"0.5518214",
"0.5516887",
"0.5508216",
"0.55075616",
"0.55014366",
"0.55014366",
"0.55014366",
"0.55014366",
"0.55014366",
"0.55014366",
"0.55013806",
"0.54965127",
"0.54965127",
"0.54965127",
"0.5494508",
"0.5474113",
"0.5474113",
"0.5474113",
"0.54740787",
"0.5471138",
"0.5471138",
"0.5471138",
"0.5469511",
"0.5469511",
"0.5462519",
"0.5458405",
"0.5455304",
"0.54544544",
"0.5453332",
"0.5452757",
"0.54520017",
"0.54480964",
"0.544728",
"0.54469365",
"0.5444099",
"0.5443538",
"0.54313767",
"0.5430881",
"0.5413413",
"0.54103863",
"0.54087657",
"0.5408093",
"0.54080313",
"0.5389527",
"0.5389527",
"0.5386688",
"0.53699654",
"0.53637373",
"0.5361858",
"0.5358531",
"0.53453404",
"0.5343168",
"0.5343168",
"0.5340341",
"0.5339981",
"0.533732",
"0.53341645",
"0.53297347",
"0.53278774",
"0.53278774",
"0.53278774"
] | 0.0 | -1 |
Accepted arguments: packxz filepath1.pack.xz,filepath2.pack.xz,... xz filepath1.xz,filepath2.xz,... pack filepath1.pack,filepath2.pack,... | public static void main(String[] args){
List<File> xzQueue = new ArrayList<>();
List<File> unpackQueue = new ArrayList<>();
List<File> packXZQueue = new ArrayList<>();
for(int i=0; i<args.length; ++i){
if(args[i].equalsIgnoreCase("-packxz")){
if(i+1<args.length){
++i;
String[] paths = args[i].split(",");
for(String s : paths){
packXZQueue.add(new File(s));
}
}
} else if(args[i].equalsIgnoreCase("-xz")){
if(i+1<args.length){
++i;
String[] paths = args[i].split(",");
for(String s : paths){
xzQueue.add(new File(s));
}
}
} else if(args[i].equalsIgnoreCase("-pack")){
if(i+1<args.length){
++i;
String[] paths = args[i].split(",");
for(String s : paths){
unpackQueue.add(new File(s));
}
}
}
}
for(File f : packXZQueue) unpack(extractXZ(f));
for(File f : xzQueue) extractXZ(f);
for(File f : unpackQueue) unpack(f);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void doPack() {\n }",
"public void doPack() {\n }",
"public void doPack() {\n }",
"public void doPack() {\n }",
"public void doPack() {\n }",
"public void doPack() {\n }",
"public void importPackage(String pack) throws Exception;",
"public static void main(String[] args) {\n\t\tBackpack result = new Backpack();\n\t\tSystem.out.println(result.backPack(10, new int[] {3,4,8,5}));\n\t\tSystem.out.println(result.backPackI(10, new int[] {3,4,8,5}));\n\t}",
"@Test\r\n\tpublic void testPackerExample(){\r\n\t\tString expectedResult = \"4\\n-\\n2,7\\n8,9\";\r\n\t\tString itemsResults = Packer.pack(\"./src/test/resources/exampleFile.txt\");\r\n\t\tassertEquals(expectedResult, itemsResults);\r\n\t\tSystem.out.println(\"Test passed. Example file.\");\r\n\t}",
"public static String pack(String filePath) throws APIException{\n log.info(\"Packing {}\", filePath);\n StringBuilder sb = new StringBuilder();\n try{\n List<PackageDTO> packages = preparePackages(filePath);\n for(PackageDTO packageDTO : packages){\n List<Integer> packDPSolution = packDPInit(packageDTO);\n sb = parseEmptySolution(sb, packDPSolution);\n }\n }catch (APIException e) {\n throw e;\n }\n String res = trimSolution(sb);\n fileService.writeToPath(filePath, res);\n return res;\n }",
"public static String pack(String filePath) throws APIException {\n\n var result = new StringBuilder();\n try (var reader = new BufferedReader(new FileReader(filePath))) {\n final var packageProcessor = PackageProcessorFactory.getProcessor(\n PackageProcessorFactory.Priority.COST_FIRST_THEN_WEIGHT);\n var line = reader.readLine();\n while (line != null) {\n var packingResult = packageProcessor.process(line);\n result.append(packingResult)\n .append(System.lineSeparator());\n line = reader.readLine();\n }\n } catch (IOException e) {\n throw new APIException(\"Cannot open file\", e);\n } catch (ParsingException e) {\n throw new APIException(\"Cannot parse data\", e);\n } catch (ProcessingException e) {\n throw new APIException(\"Cannot process data\", e);\n }\n return result.toString();\n }",
"void makeZip(String zipFilePath, String srcFilePaths[],\n\t\t\tMessageDisplay msgDisplay) {\n\t\t...\n\t\tfor (int i = 0; i < srcFilePaths.length; i++) {\n\t\t\tmsgDisplay.showMessage(\"Zipping \"+srcFilePaths[i]);\n\t\t\t//add the file srcFilePaths[i] into the zip file.\n\t\t\t...\n\t\t}\n\t}",
"private static void createZipArchiv(String xmlStream, String path, String name) {\r\n\t\ttry {\r\n\t\t\tFile file = new File(path, name + \".xml\");\r\n\t\t\tif (!file.exists()) {\r\n\t\t\t\tfile.createNewFile();\r\n\t\t\t}\r\n\t\t\t//XMLStream in Datei schreiben\r\n\t\t\tPrintWriter writer = new PrintWriter(file);\r\n\t\t\twriter.write(xmlStream);\r\n\t\t\twriter.close();\r\n\t\t\t\r\n\t\t\t//Commando für die Shell um ein Tgz zu erstellen.\r\n\t\t\tString[] str = new String[] {\r\n\t\t\t\t\t\"/bin/bash\",\r\n\t\t\t\t\t\"-c\",\r\n\t\t\t\t\t\"tar cfvz \" + path + \"/\" + name + \".tgz -C \" + path + \" \" + name\r\n\t\t\t\t\t\t\t+ \".xml -C \" + path + \" \" + name + \".pdf\" };\r\n\r\n\t\t\t//Shell Aufruf\r\n\t\t\tProcess p = Runtime.getRuntime().exec(str);\r\n\t\t\t\r\n\t\t\t\r\n\t\t\tint timeout = 10;\r\n\t\t\twhile (!new File(path + name + \".tgz\").exists() && timeout != 0) {\r\n\t\t\t\t//warten bis Datei erstellt wurde oder 10 sec vergangen sind\r\n\t\t\t\ttry {\r\n\t\t\t\t\ttimeout--;\r\n\t\t\t\t\tThread.sleep(1000);\r\n\t\t\t\t} catch (InterruptedException e) {\r\n\t\t\t\t\t// TODO Auto-generated catch block\r\n\t\t\t\t\te.printStackTrace();\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t} catch (IOException e) {\r\n\t\t\t// TODO Auto-generated catch block\r\n\t\t\te.printStackTrace();\r\n\t\t}\r\n\t}",
"@Override\r\n public void pack() {\r\n super.pack();\r\n JkFileTree.of(this.classDir()).exclude(\"**/*.jar\").zip().to(packer().jarFile(\"lean\"));\r\n distrib();\r\n }",
"public static void PackageArchive(File directoryName, File fileName) throws IOException\r\n {\r\n final String ARCHIVE_XML = \"<?xml version=\\\"1.0\\\" encoding=\\\"utf-16\\\"?>\\n<archive major_version=\\\"0\\\" minor_version=\\\"1\\\" />\";\r\n\r\n TarArchiveWriter archive = new TarArchiveWriter(new GZIPOutputStream(new FileOutputStream(fileName)));\r\n\r\n // Create the archive.xml file\r\n archive.writeFile(\"archive.xml\", ARCHIVE_XML);\r\n\r\n // Add the assets\r\n File dir = new File(directoryName, ArchiveConstants.ASSETS_PATH);\r\n String[] files = dir.list();\r\n for (String file : files)\r\n archive.writeFile(ArchiveConstants.ASSETS_PATH + FilenameUtils.getName(file), FileUtils.readFileToByteArray(new File(dir, file)));\r\n\r\n // Add the objects\r\n dir = new File(directoryName, ArchiveConstants.OBJECTS_PATH);\r\n files = dir.list();\r\n for (String file : files)\r\n archive.writeFile(ArchiveConstants.OBJECTS_PATH + FilenameUtils.getName(file), FileUtils.readFileToByteArray(new File(dir, file)));\r\n\r\n // Add the terrain(s)\r\n dir = new File(directoryName, ArchiveConstants.TERRAINS_PATH);\r\n files = dir.list();\r\n for (String file : files)\r\n archive.writeFile(ArchiveConstants.TERRAINS_PATH + FilenameUtils.getName(file), FileUtils.readFileToByteArray(new File(dir, file)));\r\n\r\n // Add the parcels(s)\r\n dir = new File(directoryName, ArchiveConstants.LANDDATA_PATH);\r\n files = dir.list();\r\n for (String file : files)\r\n archive.writeFile(ArchiveConstants.LANDDATA_PATH + FilenameUtils.getName(file), FileUtils.readFileToByteArray(new File(dir, file)));\r\n\r\n // Add the setting(s)\r\n dir = new File(directoryName, ArchiveConstants.SETTINGS_PATH);\r\n files = dir.list();\r\n for (String file : files)\r\n archive.writeFile(ArchiveConstants.SETTINGS_PATH + FilenameUtils.getName(file), FileUtils.readFileToByteArray(new File(dir, file)));\r\n\r\n archive.close();\r\n }",
"private static boolean loadFromZip(android.content.Context r8, java.io.File r9, java.io.File r10, java.lang.String r11) {\n /*\n r3 = 0;\n r0 = 1;\n r1 = 0;\n r4 = r9.listFiles();\t Catch:{ Exception -> 0x0013 }\n r5 = r4.length;\t Catch:{ Exception -> 0x0013 }\n r2 = r1;\n L_0x0009:\n if (r2 >= r5) goto L_0x0017;\n L_0x000b:\n r6 = r4[r2];\t Catch:{ Exception -> 0x0013 }\n r6.delete();\t Catch:{ Exception -> 0x0013 }\n r2 = r2 + 1;\n goto L_0x0009;\n L_0x0013:\n r2 = move-exception;\n org.telegram.messenger.FileLog.m13728e(r2);\n L_0x0017:\n r4 = new java.util.zip.ZipFile;\t Catch:{ Exception -> 0x0106, all -> 0x00ff }\n r2 = r8.getApplicationInfo();\t Catch:{ Exception -> 0x0106, all -> 0x00ff }\n r2 = r2.sourceDir;\t Catch:{ Exception -> 0x0106, all -> 0x00ff }\n r4.<init>(r2);\t Catch:{ Exception -> 0x0106, all -> 0x00ff }\n r2 = new java.lang.StringBuilder;\t Catch:{ Exception -> 0x0072, all -> 0x00da }\n r2.<init>();\t Catch:{ Exception -> 0x0072, all -> 0x00da }\n r5 = \"lib/\";\n r2 = r2.append(r5);\t Catch:{ Exception -> 0x0072, all -> 0x00da }\n r2 = r2.append(r11);\t Catch:{ Exception -> 0x0072, all -> 0x00da }\n r5 = \"/\";\n r2 = r2.append(r5);\t Catch:{ Exception -> 0x0072, all -> 0x00da }\n r5 = \"libtmessages.27.so\";\n r2 = r2.append(r5);\t Catch:{ Exception -> 0x0072, all -> 0x00da }\n r2 = r2.toString();\t Catch:{ Exception -> 0x0072, all -> 0x00da }\n r2 = r4.getEntry(r2);\t Catch:{ Exception -> 0x0072, all -> 0x00da }\n if (r2 != 0) goto L_0x0084;\n L_0x004a:\n r0 = new java.lang.Exception;\t Catch:{ Exception -> 0x0072, all -> 0x00da }\n r2 = new java.lang.StringBuilder;\t Catch:{ Exception -> 0x0072, all -> 0x00da }\n r2.<init>();\t Catch:{ Exception -> 0x0072, all -> 0x00da }\n r5 = \"Unable to find file in apk:lib/\";\n r2 = r2.append(r5);\t Catch:{ Exception -> 0x0072, all -> 0x00da }\n r2 = r2.append(r11);\t Catch:{ Exception -> 0x0072, all -> 0x00da }\n r5 = \"/\";\n r2 = r2.append(r5);\t Catch:{ Exception -> 0x0072, all -> 0x00da }\n r5 = \"tmessages.27\";\n r2 = r2.append(r5);\t Catch:{ Exception -> 0x0072, all -> 0x00da }\n r2 = r2.toString();\t Catch:{ Exception -> 0x0072, all -> 0x00da }\n r0.<init>(r2);\t Catch:{ Exception -> 0x0072, all -> 0x00da }\n throw r0;\t Catch:{ Exception -> 0x0072, all -> 0x00da }\n L_0x0072:\n r0 = move-exception;\n r2 = r3;\n r3 = r4;\n L_0x0075:\n org.telegram.messenger.FileLog.m13728e(r0);\t Catch:{ all -> 0x0102 }\n if (r2 == 0) goto L_0x007d;\n L_0x007a:\n r2.close();\t Catch:{ Exception -> 0x00eb }\n L_0x007d:\n if (r3 == 0) goto L_0x0082;\n L_0x007f:\n r3.close();\t Catch:{ Exception -> 0x00f0 }\n L_0x0082:\n r0 = r1;\n L_0x0083:\n return r0;\n L_0x0084:\n r3 = r4.getInputStream(r2);\t Catch:{ Exception -> 0x0072, all -> 0x00da }\n r2 = new java.io.FileOutputStream;\t Catch:{ Exception -> 0x009f, all -> 0x00da }\n r2.<init>(r10);\t Catch:{ Exception -> 0x009f, all -> 0x00da }\n r5 = 4096; // 0x1000 float:5.74E-42 double:2.0237E-320;\n r5 = new byte[r5];\t Catch:{ Exception -> 0x009f, all -> 0x00da }\n L_0x0091:\n r6 = r3.read(r5);\t Catch:{ Exception -> 0x009f, all -> 0x00da }\n if (r6 <= 0) goto L_0x00a3;\n L_0x0097:\n java.lang.Thread.yield();\t Catch:{ Exception -> 0x009f, all -> 0x00da }\n r7 = 0;\n r2.write(r5, r7, r6);\t Catch:{ Exception -> 0x009f, all -> 0x00da }\n goto L_0x0091;\n L_0x009f:\n r0 = move-exception;\n r2 = r3;\n r3 = r4;\n goto L_0x0075;\n L_0x00a3:\n r2.close();\t Catch:{ Exception -> 0x009f, all -> 0x00da }\n r2 = 1;\n r5 = 0;\n r10.setReadable(r2, r5);\t Catch:{ Exception -> 0x009f, all -> 0x00da }\n r2 = 1;\n r5 = 0;\n r10.setExecutable(r2, r5);\t Catch:{ Exception -> 0x009f, all -> 0x00da }\n r2 = 1;\n r10.setWritable(r2);\t Catch:{ Exception -> 0x009f, all -> 0x00da }\n r2 = r10.getAbsolutePath();\t Catch:{ Error -> 0x00d5 }\n java.lang.System.load(r2);\t Catch:{ Error -> 0x00d5 }\n r2 = net.hockeyapp.android.C2367a.f7955a;\t Catch:{ Error -> 0x00d5 }\n r5 = org.telegram.messenger.BuildVars.DEBUG_VERSION;\t Catch:{ Error -> 0x00d5 }\n init(r2, r5);\t Catch:{ Error -> 0x00d5 }\n r2 = 1;\n nativeLoaded = r2;\t Catch:{ Error -> 0x00d5 }\n L_0x00c5:\n if (r3 == 0) goto L_0x00ca;\n L_0x00c7:\n r3.close();\t Catch:{ Exception -> 0x00e6 }\n L_0x00ca:\n if (r4 == 0) goto L_0x0083;\n L_0x00cc:\n r4.close();\t Catch:{ Exception -> 0x00d0 }\n goto L_0x0083;\n L_0x00d0:\n r1 = move-exception;\n org.telegram.messenger.FileLog.m13728e(r1);\n goto L_0x0083;\n L_0x00d5:\n r2 = move-exception;\n org.telegram.messenger.FileLog.m13728e(r2);\t Catch:{ Exception -> 0x009f, all -> 0x00da }\n goto L_0x00c5;\n L_0x00da:\n r0 = move-exception;\n L_0x00db:\n if (r3 == 0) goto L_0x00e0;\n L_0x00dd:\n r3.close();\t Catch:{ Exception -> 0x00f5 }\n L_0x00e0:\n if (r4 == 0) goto L_0x00e5;\n L_0x00e2:\n r4.close();\t Catch:{ Exception -> 0x00fa }\n L_0x00e5:\n throw r0;\n L_0x00e6:\n r1 = move-exception;\n org.telegram.messenger.FileLog.m13728e(r1);\n goto L_0x00ca;\n L_0x00eb:\n r0 = move-exception;\n org.telegram.messenger.FileLog.m13728e(r0);\n goto L_0x007d;\n L_0x00f0:\n r0 = move-exception;\n org.telegram.messenger.FileLog.m13728e(r0);\n goto L_0x0082;\n L_0x00f5:\n r1 = move-exception;\n org.telegram.messenger.FileLog.m13728e(r1);\n goto L_0x00e0;\n L_0x00fa:\n r1 = move-exception;\n org.telegram.messenger.FileLog.m13728e(r1);\n goto L_0x00e5;\n L_0x00ff:\n r0 = move-exception;\n r4 = r3;\n goto L_0x00db;\n L_0x0102:\n r0 = move-exception;\n r4 = r3;\n r3 = r2;\n goto L_0x00db;\n L_0x0106:\n r0 = move-exception;\n r2 = r3;\n goto L_0x0075;\n */\n throw new UnsupportedOperationException(\"Method not decompiled: org.telegram.messenger.NativeLoader.loadFromZip(android.content.Context, java.io.File, java.io.File, java.lang.String):boolean\");\n }",
"public static void main(String[] args) {\n System.out.println(canPack(6, 2, 17));\n\n }",
"public void setupZipFile(String[] args) {\n\t\tif (args.length > 0) {\n\t\t\tif (!args[0].endsWith(\".zip\")) {\n\t\t\t\tthrow new IllegalArgumentException(\"zip file expected, but: \" + args[0]);\n\t\t\t}\n\t\t\tbuildDirectory = new File(\n\t\t\t\t\tgetBuildDirectory(),\n\t\t\t\t\tString.valueOf(System.currentTimeMillis()));\n\t\t\ttool_builddir = buildDirectory.toString();\n\t\t\tif (!buildDirectory.mkdirs()) {\n\t\t\t\tLoggedUtils.ignore(\"Unable to create directory \" + tool_builddir, null);\n\t\t\t}\n\t\t\tzipFile = args[0];\n\t\t} else if (requireZipArgument){\n\t\t\tthrow new IllegalArgumentException(\"zip file is expected as a first argument\");\n\t\t}\n\t}",
"@Test\r\n\tpublic void testBundler1() throws ArchiveException, IOException {\r\n\t\r\n\t\t// Build the path to the output file\r\n\t\tStringBuilder sb = new StringBuilder();\r\n\t\tsb.append(ArchiveTest._tempDir);\r\n\t\tsb.append(File.separator);\r\n\t\tsb.append(this._archiveFilename1);\r\n\t\tthis._archiveFilename1 = sb.toString();\r\n\t\t\r\n\t\tArchiveFactory factory = ArchiveFactory.getFactory();\r\n\t\ttry {\r\n\t\t\t\r\n\t\t\tBundlerI bundler = factory.getInstance(ArchiveType.BZIP2);\r\n\t\t\tbundler.bundle(ArchiveTest._dirToArchive, this._archiveFilename1);\r\n\t\t\tFile archive = new File(bundler.getArchiveName());\r\n\t\t\tSystem.out.println(bundler.getArchiveName());\r\n\t\t\tassertTrue(archive.exists());\r\n\t\t\tdouble bytes = archive.length();\r\n\t\t\tSystem.out.println(bytes);\r\n\t\t\t\r\n\t\t}\r\n\t\tcatch (UnknownArchiveTypeException uae) {\r\n\t\t\t// We *should* never get this exception\r\n\t\t\tuae.printStackTrace();\r\n\t\t}\r\n\t}",
"private static byte[] packMtx(byte[] block1, byte[] block2, byte[] block3) {\n int copyDist = Math.max(block1.length, Math.max(block2.length, block3.length)) +\n LzcompCompress.getPreloadSize();\n byte[] compressed1 = LzcompCompress.compress(block1);\n byte[] compressed2 = LzcompCompress.compress(block2);\n byte[] compressed3 = LzcompCompress.compress(block3);\n int resultSize = 10 + compressed1.length + compressed2.length + compressed3.length;\n byte[] result = new byte[resultSize];\n result[0] = 3;\n writeBE24(result, copyDist, 1);\n int offset2 = 10 + compressed1.length;\n int offset3 = offset2 + compressed2.length;\n writeBE24(result, offset2, 4);\n writeBE24(result, offset3, 7);\n System.arraycopy(compressed1, 0, result, 10, compressed1.length);\n System.arraycopy(compressed2, 0, result, offset2, compressed2.length);\n System.arraycopy(compressed3, 0, result, offset3, compressed3.length);\n return result;\n }",
"private void compress()\n\t{\n\t\ttry\n\t\t{\n\t\t\tZipOutputStream rfoFile = new ZipOutputStream(new FileOutputStream(path + fileName)); \n\t\t\tFile dirToZip = new File(rfoDir); \n\t\t\tString[] fileList = dirToZip.list(); \n\t\t\tbyte[] buffer = new byte[4096]; \n\t\t\tint bytesIn = 0; \n\n\t\t\tfor(int i=0; i<fileList.length; i++) \n\t\t\t{ \n\t\t\t\tFile f = new File(dirToZip, fileList[i]); \n\t\t\t\tFileInputStream fis = new FileInputStream(f); \n\t\t\t\tString zEntry = f.getPath();\n\t\t\t\t//System.out.println(\"\\n\" + zEntry);\n\t\t\t\tint start = zEntry.indexOf(uniqueName);\n\t\t\t\tzEntry = zEntry.substring(start + uniqueName.length() + 1, zEntry.length());\n\t\t\t\t//System.out.println(tempDir);\n\t\t\t\t//System.out.println(zEntry + \"\\n\");\n\t\t\t\tZipEntry entry = new ZipEntry(zEntry); \n\t\t\t\trfoFile.putNextEntry(entry); \n\t\t\t\twhile((bytesIn = fis.read(buffer)) != -1) \n\t\t\t\t\trfoFile.write(buffer, 0, bytesIn); \n\t\t\t\tfis.close();\n\t\t\t}\n\t\t\trfoFile.close();\n\t\t} catch (Exception e)\n\t\t{\n\t\t\tDebug.e(\"RFO.compress(): \" + e);\n\t\t}\n\t}",
"private static java.io.File c(java.lang.String r8, java.lang.String r9) {\n /*\n r0 = 0;\n r1 = 0;\n r2 = new java.io.File;\t Catch:{ Exception -> 0x00e8, all -> 0x00e4 }\n r2.<init>(r8);\t Catch:{ Exception -> 0x00e8, all -> 0x00e4 }\n r8 = r2.exists();\t Catch:{ Exception -> 0x00e1, all -> 0x00de }\n if (r8 != 0) goto L_0x001d;\n L_0x000d:\n r8 = \"DecryptUtils\";\n r9 = \"unZipSingleFile file don't exist\";\n r3 = new java.lang.Object[r0];\t Catch:{ Exception -> 0x00e1, all -> 0x00de }\n com.taobao.sophix.e.d.e(r8, r9, r3);\t Catch:{ Exception -> 0x00e1, all -> 0x00de }\n com.taobao.sophix.e.b.a(r1);\n r2.delete();\n return r1;\n L_0x001d:\n r8 = new java.lang.StringBuilder;\t Catch:{ Exception -> 0x00e1, all -> 0x00de }\n r8.<init>();\t Catch:{ Exception -> 0x00e1, all -> 0x00de }\n r8.append(r9);\t Catch:{ Exception -> 0x00e1, all -> 0x00de }\n r9 = java.io.File.separator;\t Catch:{ Exception -> 0x00e1, all -> 0x00de }\n r8.append(r9);\t Catch:{ Exception -> 0x00e1, all -> 0x00de }\n r9 = \"unzip\";\n r8.append(r9);\t Catch:{ Exception -> 0x00e1, all -> 0x00de }\n r8 = r8.toString();\t Catch:{ Exception -> 0x00e1, all -> 0x00de }\n r9 = new java.io.File;\t Catch:{ Exception -> 0x00e1, all -> 0x00de }\n r9.<init>(r8);\t Catch:{ Exception -> 0x00e1, all -> 0x00de }\n com.taobao.sophix.e.b.a(r9);\t Catch:{ Exception -> 0x00e1, all -> 0x00de }\n r3 = r9.exists();\t Catch:{ Exception -> 0x00e1, all -> 0x00de }\n if (r3 != 0) goto L_0x0044;\n L_0x0041:\n r9.mkdirs();\t Catch:{ Exception -> 0x00e1, all -> 0x00de }\n L_0x0044:\n r9 = new java.util.zip.ZipInputStream;\t Catch:{ Exception -> 0x00e1, all -> 0x00de }\n r3 = new java.io.FileInputStream;\t Catch:{ Exception -> 0x00e1, all -> 0x00de }\n r3.<init>(r2);\t Catch:{ Exception -> 0x00e1, all -> 0x00de }\n r9.<init>(r3);\t Catch:{ Exception -> 0x00e1, all -> 0x00de }\n L_0x004e:\n r3 = r9.getNextEntry();\t Catch:{ Exception -> 0x00dc }\n if (r3 == 0) goto L_0x00f4;\n L_0x0054:\n r4 = r3.getName();\t Catch:{ Exception -> 0x00dc }\n r3 = r3.isDirectory();\t Catch:{ Exception -> 0x00dc }\n if (r3 == 0) goto L_0x0085;\n L_0x005e:\n r3 = r4.length();\t Catch:{ Exception -> 0x00dc }\n r3 = r3 + -1;\n r3 = r4.substring(r0, r3);\t Catch:{ Exception -> 0x00dc }\n r4 = new java.io.File;\t Catch:{ Exception -> 0x00dc }\n r5 = new java.lang.StringBuilder;\t Catch:{ Exception -> 0x00dc }\n r5.<init>();\t Catch:{ Exception -> 0x00dc }\n r5.append(r8);\t Catch:{ Exception -> 0x00dc }\n r6 = java.io.File.separator;\t Catch:{ Exception -> 0x00dc }\n r5.append(r6);\t Catch:{ Exception -> 0x00dc }\n r5.append(r3);\t Catch:{ Exception -> 0x00dc }\n r3 = r5.toString();\t Catch:{ Exception -> 0x00dc }\n r4.<init>(r3);\t Catch:{ Exception -> 0x00dc }\n r4.mkdirs();\t Catch:{ Exception -> 0x00dc }\n goto L_0x004e;\n L_0x0085:\n r3 = new java.io.File;\t Catch:{ Exception -> 0x00dc }\n r5 = new java.lang.StringBuilder;\t Catch:{ Exception -> 0x00dc }\n r5.<init>();\t Catch:{ Exception -> 0x00dc }\n r5.append(r8);\t Catch:{ Exception -> 0x00dc }\n r6 = java.io.File.separator;\t Catch:{ Exception -> 0x00dc }\n r5.append(r6);\t Catch:{ Exception -> 0x00dc }\n r5.append(r4);\t Catch:{ Exception -> 0x00dc }\n r4 = r5.toString();\t Catch:{ Exception -> 0x00dc }\n r3.<init>(r4);\t Catch:{ Exception -> 0x00dc }\n r3.createNewFile();\t Catch:{ Exception -> 0x00dc }\n r4 = new java.io.FileOutputStream;\t Catch:{ Exception -> 0x00c7, all -> 0x00c4 }\n r4.<init>(r3);\t Catch:{ Exception -> 0x00c7, all -> 0x00c4 }\n r5 = 1024; // 0x400 float:1.435E-42 double:5.06E-321;\n r5 = new byte[r5];\t Catch:{ Exception -> 0x00c2 }\n L_0x00aa:\n r6 = r9.read(r5);\t Catch:{ Exception -> 0x00c2 }\n r7 = -1;\n if (r6 == r7) goto L_0x00b8;\n L_0x00b1:\n r4.write(r5, r0, r6);\t Catch:{ Exception -> 0x00c2 }\n r4.flush();\t Catch:{ Exception -> 0x00c2 }\n goto L_0x00aa;\n L_0x00b8:\n com.taobao.sophix.e.b.a(r4);\t Catch:{ Exception -> 0x00dc }\n com.taobao.sophix.e.b.a(r9);\n r2.delete();\n return r3;\n L_0x00c2:\n r3 = move-exception;\n goto L_0x00c9;\n L_0x00c4:\n r8 = move-exception;\n r4 = r1;\n goto L_0x00d8;\n L_0x00c7:\n r3 = move-exception;\n r4 = r1;\n L_0x00c9:\n r5 = \"DecryptUtils\";\n r6 = \"unZipSingleFile unZip hotfix patch file error\";\n r7 = new java.lang.Object[r0];\t Catch:{ all -> 0x00d7 }\n com.taobao.sophix.e.d.a(r5, r6, r3, r7);\t Catch:{ all -> 0x00d7 }\n com.taobao.sophix.e.b.a(r4);\t Catch:{ Exception -> 0x00dc }\n goto L_0x004e;\n L_0x00d7:\n r8 = move-exception;\n L_0x00d8:\n com.taobao.sophix.e.b.a(r4);\t Catch:{ Exception -> 0x00dc }\n throw r8;\t Catch:{ Exception -> 0x00dc }\n L_0x00dc:\n r8 = move-exception;\n goto L_0x00eb;\n L_0x00de:\n r8 = move-exception;\n r9 = r1;\n goto L_0x00fc;\n L_0x00e1:\n r8 = move-exception;\n r9 = r1;\n goto L_0x00eb;\n L_0x00e4:\n r8 = move-exception;\n r9 = r1;\n r2 = r9;\n goto L_0x00fc;\n L_0x00e8:\n r8 = move-exception;\n r9 = r1;\n r2 = r9;\n L_0x00eb:\n r3 = \"DecryptUtils\";\n r4 = \"unZipSingleFile unZip hotfix patch file error\";\n r0 = new java.lang.Object[r0];\t Catch:{ all -> 0x00fb }\n com.taobao.sophix.e.d.a(r3, r4, r8, r0);\t Catch:{ all -> 0x00fb }\n L_0x00f4:\n com.taobao.sophix.e.b.a(r9);\n r2.delete();\n return r1;\n L_0x00fb:\n r8 = move-exception;\n L_0x00fc:\n com.taobao.sophix.e.b.a(r9);\n r2.delete();\n throw r8;\n */\n throw new UnsupportedOperationException(\"Method not decompiled: com.taobao.sophix.e.a.c(java.lang.String, java.lang.String):java.io.File\");\n }",
"@Override\n\tpublic String pack() {\n\t\treturn \"Bpxx packingg somjkjhha\";\n\t}",
"@Override\n void pack() {\n }",
"public static void createNewBundleInternal(String patchBundleName,ZipFile source, List<ZipEntry> entryList, File target, boolean isDiff, MergeExcutorServices.PrepareCallBack prepareCallBack) throws IOException, MergeException {\n byte[] buffer = new byte[BUFFEREDSIZE];\n ZipOutputStream out = new ZipOutputStream(new BufferedOutputStream(new FileOutputStream(target)));\n BufferedOutputStream bo = new BufferedOutputStream(out);\n InputStream in;\n //先写入source中未变的文件\n java.util.Enumeration e = source.entries();\n Boolean isSourceHasDex = false;\n Boolean isPatchHasDex = false;\n ZipEntry originalDex = null;\n ZipEntry patchDex = null;\n File outDex;\n\n while (e.hasMoreElements()) {\n ZipEntry zipEnt = (ZipEntry) e.nextElement();\n String name = zipEnt.getName();\n /**\n * 差量更新需要做dex merge, 过滤出classes.dex\n */\n if (isDiff && name.equals(\"classes.dex\")) {\n// originalDex = zipEnt;\n isSourceHasDex = true;\n continue;\n }\n\n boolean toBeDeleted = isBundleFileUpdated(zipEnt,entryList);\n\n if (!toBeDeleted) {\n\n ZipEntry newEntry = new ZipEntry(name);\n if (name.contains(\"raw/\")||name.contains(\"assets/\")){\n newEntry.setMethod(ZipEntry.STORED);\n newEntry.setCrc(zipEnt.getCrc());\n newEntry.setSize(zipEnt.getSize());\n }\n out.putNextEntry(newEntry);\n in = source.getInputStream(zipEnt);\n write(in, out, buffer);\n bo.flush();\n\n }\n }\n\n if (!isSourceHasDex && isDiff) {\n throw new MergeException(\"Original bundle has no dex\");\n }\n\n //最后写入patch中的内容\n// File[] patchFiles = patch.listFiles();\n// for (File patchFile : patchFiles) {\n// /**\n// * 差量更新需要做dex merge, 过滤出classes.dex\n// */\n// if (isDiff && patchFile.getName().equals(\"classes.dex\")) {\n// patchDex = patchFile;\n// isPatchHasDex = true;\n// MergeExcutorServices.needMergeCount.incrementAndGet();\n// continue;\n// }\n// zip(out, patchFile, patchFile.getName(), bo);\n//\n// }\n for(ZipEntry entry : entryList){\n if(isDiff && (entry.getName().endsWith(\"classes.dex\"))){\n patchDex = entry;\n isPatchHasDex =true;\n MergeExcutorServices.needMergeCount.incrementAndGet();\n continue;\n }\n ZipEntry newEntry = new ZipEntry(entry.getName().substring(entry.getName().indexOf(\"/\")+1));\n if (newEntry.getName().contains(\"raw/\")||newEntry.getName().contains(\"assets/\")){\n newEntry.setMethod(ZipEntry.STORED);\n newEntry.setCrc(entry.getCrc());\n newEntry.setSize(entry.getSize());\n }\n out.putNextEntry(newEntry);\n in = MergeExcutorServices.sZipPatch.getInputStream(entry);\n write(in, out, buffer);\n bo.flush();\n }\n /**\n * 差量更新需要做dex merge\n */\n if (isDiff) {\n // Merge patch dex with origin dex\n if (isPatchHasDex && isSourceHasDex) {\n //发出merge申请\n// File outDexDir = new File(patch, \"out\");\n ByteArrayOutputStream outDexStream=new ByteArrayOutputStream();\n dexMerge(patchBundleName,source, patchDex, outDexStream, prepareCallBack);\n// if (outDexStream.exists()) {\n// /**\n// * caculate the merged dex md5 and report\n// */\n// String md5 = Md5Utils.getFileMD5String(outDex);\n// MonitorReport.getInstance().trace(source.getName(), md5, \"\" + outDex.length());\n// }\n// zip(out, outDex, outDex.getName(), bo);\n ByteArrayInputStream swapStream = new ByteArrayInputStream(outDexStream.toByteArray());\n ZipEntry entry = new ZipEntry(\"classes.dex\");\n out.putNextEntry(entry);\n write(swapStream,out,buffer);\n bo.flush();\n } else if (isSourceHasDex) {\n // Patch has no classes.dex, just use the original dex\n// outDex = new File(patch, \"classes.dex\");\n// inputStreamToFile(source.getInputStream(originalDex), outDex);\n// zip(out, outDex, outDex.getName(), bo);\n ZipEntry entry = new ZipEntry(\"classes.dex\");\n out.putNextEntry(entry);\n in = source.getInputStream(source.getEntry(\"classes.dex\"));\n write(in,out,buffer);\n bo.flush();\n }\n }else {\n MergeExcutorServices.successCount.incrementAndGet();\n }\n\n closeQuitely(out);\n closeQuitely(bo);\n }",
"public static void setupResourcePack() {\n try {\n FileWriter writer = new FileWriter(Paths.get(FMLPaths.CONFIGDIR.get().toAbsolutePath().toString(),WingTech.MODID, \"resources\", \"pack.mcmeta\").toFile());\n writer.write(\"{\\\"pack\\\":{\\\"pack_format\\\":6,\\\"description\\\":\\\"WingTech resource pack used for lang purposes for the user to add lang for teas.\\\"}}\");\n writer.close();\n }\n catch (Exception e){\n WingTech.LOGGER.error(\"Error creating pack.mcmeta\", e);\n }\n Minecraft.getInstance().getResourcePackRepository().addPackFinder((consumer, factory) -> {\n final ResourcePackInfo packInfo = ResourcePackInfo.create(\n WingTech.MODID,\n true,\n () -> new FolderPack(Paths.get(FMLPaths.CONFIGDIR.get().toAbsolutePath().toString(),WingTech.MODID, \"resources\").toFile()) {\n @Override\n public boolean isHidden() {\n return true;\n }\n },\n factory,\n ResourcePackInfo.Priority.TOP,\n IPackNameDecorator.BUILT_IN\n );\n if (packInfo == null) {\n WingTech.LOGGER.error(\"Failed to load tea resource pack!\");\n return;\n }\n consumer.accept(packInfo);\n });\n }",
"@Test\n public void testDERIVATIVE_COMPRESS_CRC() throws IOException {\n// ZipMeVariables.getSINGLETON().setCRC___(true);\n// ZipMeVariables.getSINGLETON().setCOMPRESS___(true);\n// ZipMeVariables.getSINGLETON().setDERIVATIVE_COMPRESS_CRC___(true);\n\t Configuration.CRC=true;\n\t Configuration.COMPRESS=true;\n\t Configuration.DERIVATIVE_COMPRESS_CRC=true;\n if(Configuration.CRC && Configuration.COMPRESS && Configuration.DERIVATIVE_COMPRESS_CRC) { \n ZipOutputStream zout = new ZipOutputStream(new FileOutputStream(new File(\n homeDir + \"/files/src.zip\")));\n zout.crc.update(1);\n ZipEntry ze = new ZipEntry(\"C://\");\n zout.putNextEntry(ze);\n zout.hook41();\n assertTrue(zout.crc.crc == 0);\n\n zout.write(new byte[32], 0, 31);\n assertTrue(zout.size == 31);\n zout.closeEntry();\n assertTrue(ze.getCrc() == zout.crc.crc);\n }\n }",
"public boolean CompressWithLzma(String cmd) {\n Runtime rn=Runtime.getRuntime();\r\n try{\r\n \tSystem.out.println(\"compress, it will take some time\");\r\n \tProcess process = rn.exec(JarPath+\"7za a -t7z \"+cmd);\r\n \tWatchThread wt = new WatchThread(process); \r\n \twt.start(); \r\n \tprocess.waitFor();\r\n \twt.setOver(true); \r\n \twt.join();\r\n }catch(Exception e){\r\n \toutputstr(\"Error: compress \"+cmd);\r\n \treturn false; \r\n } \t\t\r\n\t\treturn true;\r\n\t}",
"public static void main(String[] args) throws IOException {\n\t\tFile targetFile = new File(\"D:\\\\program\\\\360cse\\\\360Chrome\\\\test.zip\");\n\t\tFile sourceFiles = new File(\"D:\\\\temple\\\\sysMenu-add.html\");\n\t\tboolean flag = compressZip(false, targetFile, sourceFiles);\n\t\tSystem.out.println(flag);\n\t}",
"void makeZip(String zipFilePath, String srcFilePaths[], ZipMainFrame f) {\n ...\n for (int i = 0; i < srcFilePaths.length; i++) {\n f.setStatusBarText(\"Zipping \"+srcFilePaths[i]);\n //add the file srcFilePaths[i] into the zip file.\n ...\n }\n }",
"public interface Packing {\n public String pack();\n}",
"public static boolean generateZipFile(ArrayList<String> sourcesFilenames, String destinationDir, String zipFilename){\n byte[] buf = new byte[1024]; \r\n\r\n try \r\n {\r\n // VER SI HAY QUE CREAR EL ROOT PATH\r\n boolean result = (new File(destinationDir)).mkdirs();\r\n\r\n String zipFullFilename = destinationDir + \"/\" + zipFilename;\r\n\r\n System.out.println(result);\r\n\r\n // Create the ZIP file \r\n ZipOutputStream out = new ZipOutputStream(new FileOutputStream(zipFullFilename)); \r\n \r\n // Compress the files \r\n for (String filename: sourcesFilenames) { \r\n FileInputStream in = new FileInputStream(filename); \r\n // Add ZIP entry to output stream. \r\n File file = new File(filename); //\"Users/you/image.jpg\"\r\n out.putNextEntry(new ZipEntry(file.getName())); //\"image.jpg\" \r\n // Transfer bytes from the file to the ZIP file \r\n int len; \r\n while ((len = in.read(buf)) > 0) { \r\n out.write(buf, 0, len); \r\n } \r\n // Complete the entry \r\n out.closeEntry(); \r\n in.close(); \r\n } // Complete the ZIP file \r\n out.close();\r\n\r\n return true;\r\n } \r\n catch (Exception e) \r\n { \r\n System.out.println(e);\r\n return false;\r\n } \r\n }",
"private static void zza(byte[] arrby, StringBuffer stringBuffer) {\n if (arrby == null) {\n stringBuffer.append(\"\\\"\\\"\");\n return;\n }\n stringBuffer.append('\\\"');\n int n = 0;\n do {\n if (n >= arrby.length) {\n stringBuffer.append('\\\"');\n return;\n }\n int n2 = arrby[n] & 0xFF;\n if (n2 == 92 || n2 == 34) {\n stringBuffer.append('\\\\').append((char)n2);\n } else if (n2 >= 32 && n2 < 127) {\n stringBuffer.append((char)n2);\n } else {\n stringBuffer.append(String.format(\"\\\\%03o\", n2));\n }\n ++n;\n } while (true);\n }",
"int pack(int b2, int s1, int b0)\n {\n return (b2 << 24) | (s1 << 8) | b0;\n }",
"public static void main(String[] args) throws IOException{\n\t\tSystem.exit((new BitCompresser()).run(args));\n\t}",
"private void nocompressedUnPack()throws UnpackException,ZipEndException{\n skipByte();\n //get the len\n long LEN = 0x00;\n byte byte0 = getByte();\n byte byte1 = getByte();\n byte byte2 = getByte();\n byte byte3 = getByte();\n LEN |= byte1;\n LEN |= (byte0 << 8);\n LEN &= 0X0000ffff;\n// LEN |= (byte2<<24);\n// LEN |= (byte3<<16);\n int l = 0;\n try{\n for (long num = 0; num < LEN ; num ++){\n outputStoredByte(getByte());\n }\n }catch (IOException e){\n e.printStackTrace();\n }\n }",
"public static void main(String[] args) {\n\t\tSystem.out.println(zipZap(((\"azbcpppzop\") ) ));\n\t}",
"@Override\n public UnpackedPeptideShakerImport unpackPeptideShakerImport(PeptideShakerImport peptideShakerDataImport, Path experimentsDirectory) throws IOException, ArchiveException, ClassNotFoundException, SQLException, InterruptedException {\n String relativePeptideShakerCpsxArchiveString = FilenameUtils.separatorsToSystem(peptideShakerDataImport.getPeptideShakerCpsxArchive());\n Path relativePeptideShakerCpsxArchive = Paths.get(relativePeptideShakerCpsxArchiveString);\n Path absolutePeptideShakerCpsxArchivePath = experimentsDirectory.resolve(relativePeptideShakerCpsxArchive);\n //check if the path exists\n if (!java.nio.file.Files.exists(absolutePeptideShakerCpsxArchivePath)) {\n throw new IllegalArgumentException(\"The PeptideShaker file \" + absolutePeptideShakerCpsxArchivePath.toString() + \" doesn't exist.\");\n }\n //unpacked PeptideShakerImport .cps archive\n UnpackedPeptideShakerImport unpackedPeptideShakerImport = unpackPeptideShakerCpsxArchive(absolutePeptideShakerCpsxArchivePath.toFile());\n\n //set FASTA DB ids and MGF files\n unpackedPeptideShakerImport.setFastaDbIds(peptideShakerDataImport.getFastaDbIds());\n //make the relative MGF file paths absolute\n List<Path> absoluteMgfFiles = peptideShakerDataImport.getMgfFiles().stream().map(mgfFile ->\n {\n //make the path absolute and check if it exists\n String mgfFilePath = FilenameUtils.separatorsToSystem(mgfFile);\n Path absoluteMgfFilePath = experimentsDirectory.resolve(mgfFilePath);\n if (!java.nio.file.Files.exists(absoluteMgfFilePath)) {\n throw new IllegalArgumentException(\"The MGF file \" + absoluteMgfFilePath.toString() + \" doesn't exist.\");\n }\n return absoluteMgfFilePath;\n }\n ).collect(Collectors.toList());\n unpackedPeptideShakerImport.setMgfFiles(absoluteMgfFiles);\n\n return unpackedPeptideShakerImport;\n }",
"@Test\r\n\tpublic void testBundler2() throws ArchiveException, IOException {\r\n\t\r\n\t\t// Build the path to the output file\r\n\t\tStringBuilder sb = new StringBuilder();\r\n\t\tsb.append(ArchiveTest._tempDir);\r\n\t\tsb.append(File.separator);\r\n\t\tsb.append(this._archiveFilename2);\r\n\t\tthis._archiveFilename2 = sb.toString();\r\n\t\t\r\n\t\tList<String> list = super.getFileList();\r\n\t\tArchiveFactory factory = ArchiveFactory.getFactory();\r\n\t\ttry {\r\n\t\t\t\r\n\t\t\tBundlerI bundler = factory.getInstance(ArchiveType.BZIP2);\r\n\t\t\tbundler.bundle(list, this._archiveFilename2, null);\r\n\t\t\tFile archive = new File(bundler.getArchiveName());\r\n\t\t\tSystem.out.println(bundler.getArchiveName());\r\n\t\t\tassertTrue(archive.exists());\r\n\t\t\tdouble bytes = archive.length();\r\n\t\t\tSystem.out.println(bytes);\r\n\t\t\t\r\n\t\t}\r\n\t\tcatch (UnknownArchiveTypeException uae) {\r\n\t\t\t// We *should* never get this exception\r\n\t\t\tuae.printStackTrace();\r\n\t\t}\r\n\t}",
"public static boolean UnzipFile(ZipFile zf, String filepathinzip, File fileinfiledir) {\r\n BufferedOutputStream Output_fos = null;\r\n BufferedInputStream bufbr = null;\r\n try {\r\n ZipEntry ze = zf.getEntry(filepathinzip);\r\n if (ze != null) {\r\n BufferedOutputStream Output_fos2 = new BufferedOutputStream(new FileOutputStream(fileinfiledir));\r\n try {\r\n byte[] buf = new byte[65536];\r\n BufferedInputStream bufbr2 = new BufferedInputStream(zf.getInputStream(ze));\r\n while (true) {\r\n try {\r\n int readlen = bufbr2.read(buf);\r\n if (readlen < 0) {\r\n break;\r\n }\r\n Output_fos2.write(buf, 0, readlen);\r\n } catch (Exception e) {\r\n e = e;\r\n bufbr = bufbr2;\r\n Output_fos = Output_fos2;\r\n } catch (Throwable th) {\r\n th = th;\r\n bufbr = bufbr2;\r\n Output_fos = Output_fos2;\r\n if (Output_fos != null) {\r\n try {\r\n Output_fos.close();\r\n if (bufbr != null) {\r\n try {\r\n bufbr.close();\r\n } catch (IOException e2) {\r\n e2.printStackTrace();\r\n return false;\r\n }\r\n }\r\n } catch (IOException e3) {\r\n e3.printStackTrace();\r\n if (bufbr == null) {\r\n return false;\r\n }\r\n try {\r\n bufbr.close();\r\n return false;\r\n } catch (IOException e4) {\r\n e4.printStackTrace();\r\n return false;\r\n }\r\n } finally {\r\n if (bufbr != null) {\r\n try {\r\n bufbr.close();\r\n } catch (IOException e5) {\r\n e5.printStackTrace();\r\n return false;\r\n }\r\n }\r\n }\r\n }\r\n throw th;\r\n }\r\n }\r\n if (Output_fos2 != null) {\r\n try {\r\n Output_fos2.close();\r\n if (bufbr2 != null) {\r\n try {\r\n bufbr2.close();\r\n } catch (IOException e6) {\r\n e6.printStackTrace();\r\n BufferedInputStream bufferedInputStream = bufbr2;\r\n BufferedOutputStream bufferedOutputStream = Output_fos2;\r\n return false;\r\n }\r\n }\r\n } catch (IOException e7) {\r\n e7.printStackTrace();\r\n if (bufbr2 != null) {\r\n try {\r\n bufbr2.close();\r\n } catch (IOException e8) {\r\n e8.printStackTrace();\r\n BufferedInputStream bufferedInputStream2 = bufbr2;\r\n BufferedOutputStream bufferedOutputStream2 = Output_fos2;\r\n return false;\r\n }\r\n }\r\n BufferedInputStream bufferedInputStream3 = bufbr2;\r\n BufferedOutputStream bufferedOutputStream3 = Output_fos2;\r\n return false;\r\n } finally {\r\n if (bufbr2 != null) {\r\n try {\r\n bufbr2.close();\r\n } catch (IOException e9) {\r\n e9.printStackTrace();\r\n BufferedInputStream bufferedInputStream4 = bufbr2;\r\n BufferedOutputStream bufferedOutputStream4 = Output_fos2;\r\n return false;\r\n }\r\n }\r\n }\r\n }\r\n BufferedInputStream bufferedInputStream5 = bufbr2;\r\n BufferedOutputStream bufferedOutputStream5 = Output_fos2;\r\n return true;\r\n } catch (Exception e10) {\r\n e = e10;\r\n Output_fos = Output_fos2;\r\n try {\r\n e.printStackTrace();\r\n if (Output_fos == null) {\r\n return false;\r\n }\r\n try {\r\n Output_fos.close();\r\n if (bufbr == null) {\r\n return false;\r\n }\r\n try {\r\n bufbr.close();\r\n return false;\r\n } catch (IOException e11) {\r\n e11.printStackTrace();\r\n return false;\r\n }\r\n } catch (IOException e12) {\r\n e12.printStackTrace();\r\n if (bufbr == null) {\r\n return false;\r\n }\r\n try {\r\n bufbr.close();\r\n return false;\r\n } catch (IOException e13) {\r\n e13.printStackTrace();\r\n return false;\r\n }\r\n } finally {\r\n if (bufbr != null) {\r\n try {\r\n bufbr.close();\r\n } catch (IOException e14) {\r\n e14.printStackTrace();\r\n return false;\r\n }\r\n }\r\n }\r\n } catch (Throwable th2) {\r\n th = th2;\r\n if (Output_fos != null) {\r\n }\r\n throw th;\r\n }\r\n } catch (Throwable th3) {\r\n th = th3;\r\n Output_fos = Output_fos2;\r\n if (Output_fos != null) {\r\n }\r\n throw th;\r\n }\r\n } else if (Output_fos == null) {\r\n return false;\r\n } else {\r\n try {\r\n Output_fos.close();\r\n if (bufbr == null) {\r\n return false;\r\n }\r\n try {\r\n bufbr.close();\r\n return false;\r\n } catch (IOException e15) {\r\n e15.printStackTrace();\r\n return false;\r\n }\r\n } catch (IOException e16) {\r\n e16.printStackTrace();\r\n if (bufbr == null) {\r\n return false;\r\n }\r\n try {\r\n bufbr.close();\r\n return false;\r\n } catch (IOException e17) {\r\n e17.printStackTrace();\r\n return false;\r\n }\r\n } finally {\r\n if (bufbr != null) {\r\n try {\r\n bufbr.close();\r\n } catch (IOException e18) {\r\n e18.printStackTrace();\r\n return false;\r\n }\r\n }\r\n }\r\n }\r\n } catch (Exception e19) {\r\n e = e19;\r\n }\r\n }",
"public static Result servePackFile(String file)\n {\n\t\n\ttry {\n\t //note: the (virtual) 'file' is used as the cache key, see pack()\n\t Map<String, Object> cache = (Map<String, Object>) Cacher.fetchApplicationObject(CACHE_KEY);\n\t CachedPack pack = null;\n\t if (cache!=null && (pack = (CachedPack)cache.get(file))!=null) {\n\t\t/*\n\t\t * TODO: the packed files are stored gzipped to save memory and we return it as raw bytes,\n\t\t * but we should probably offer an alternative for browsers that don't support gzip?\n\t\t */\n\t\tresponse().setHeader(\"Content-Encoding\", \"gzip\");\n\t\tresponse().setHeader(\"Content-Length\", pack.content.length + \"\");\n\t\treturn ok(pack.content).as(pack.mimeType);\n\t }\n\t else {\n\t\t/*\n\t\t * Flush the cache; this shouldn't happen if some client doens't want to load random asset files.\n\t\t * Note: this can impact the performance, so I'm flagging this as 'error' so it pops up in the logs if it does. \n\t\t */\n\t\tLogger.error(\"Flushing the pack-cache, because we seem to miss an entry for \"+file+\" - this shouldn't happen!\");\n\t\tCacher.storeApplicationObject(CACHE_KEY, null);\n\t\treturn notFound();\n\t }\n\t}\n\tcatch (Exception e) {\n\t Logger.error(\"Error while serving pack file\", e);\n\t return internalServerError();\n\t}\n }",
"@Test\n public void testDecompressWithPrefix() throws Exception {\n\n descriptorBuilder.setPrefix(ROOT_FOLDER_NAME);\n\n Path outputDir =\n new CompressedTarFunction() {\n @Override\n protected InputStream getDecompressorStream(DecompressorDescriptor descriptor)\n throws IOException {\n return new GZIPInputStream(new FileInputStream(descriptor.archivePath().getPathFile()));\n }\n }.decompress(descriptorBuilder.build());\n\n assertOutputFiles(outputDir.getRelative(INNER_FOLDER_NAME));\n }",
"public static void main(String[] args) throws IOException {\r\n ObjectInputStream in = null; // reads in the compressed file\r\n FileWriter out = null; // writes out the decompressed file\r\n\r\n // Check for the file names on the command line.\r\n if (args.length != 2) {\r\n System.out.println(\"Usage: java Puff <in fname> <out fname>\");\r\n System.exit(1);\r\n }\r\n\r\n // Open the input file.\r\n try {\r\n in = new ObjectInputStream(new FileInputStream(args[0]));\r\n } catch (FileNotFoundException e) {\r\n System.out.println(\"Can't open file \" + args[0]);\r\n System.exit(1);\r\n }\r\n\r\n // Open the output file.\r\n try {\r\n out = new FileWriter(args[1]);\r\n } catch (FileNotFoundException e) {\r\n System.out.println(\"Can't open file \" + args[1]);\r\n System.exit(1);\r\n }\r\n \r\n Puff pf = new Puff();\r\n pf.getFrequencies(in);\r\n // Create a BitReader that is able to read the compressed file.\r\n BitReader reader = new BitReader(in);\r\n\r\n\r\n /****** Add your code here. ******/\r\n pf.createTree();\r\n pf.unCompress(reader,out);\r\n \r\n /* Leave these lines at the end of the method. */\r\n in.close();\r\n out.close();\r\n }",
"private void parsePackageFile( Part part, HttpServletResponse resp ) throws IOException\n {\n String fileName = part.getSubmittedFileName();\n CompressionType compressionType = CompressionType.getCompressionType( fileName );\n\n try ( InputStream is = part.getInputStream() )\n {\n LocalRepository repo = getRepository();\n repo.put( is, compressionType );\n ok( resp, \"Package successfully saved\" );\n }\n catch ( IOException ex )\n {\n internalServerError( resp, \"Failed to upload package: \" + ex.getMessage() );\n }\n }",
"public void loadGzipedSchematic(File f) throws IOException {\nDataInputStream in = new DataInputStream(new GZIPInputStream(new FileInputStream(f)));\nloadUncompressedSchematic(in);\nin.close();\n}",
"@Override\n public Integer call()\n {\n List<Path> files = new ArrayList<>();\n long before = System.nanoTime();\n int nbFiles = 1;\n\n if (STDIN.equalsIgnoreCase(this.inputName) == false)\n {\n try\n { \n String suffix = File.separator + \".\";\n boolean isRecursive = !this.inputName.endsWith(suffix);\n String target = isRecursive ? this.inputName :\n this.inputName.substring(0, this.inputName.length()-1);\n \n Kanzi.createFileList(target, files, isRecursive, this.noDotFile);\n }\n catch (IOException e)\n {\n System.err.println(e.getMessage());\n return Error.ERR_OPEN_FILE;\n }\n\n if (files.isEmpty())\n {\n System.err.println(\"Cannot access input file '\"+this.inputName+\"'\");\n return Error.ERR_OPEN_FILE;\n }\n\n nbFiles = files.size();\n String strFiles = (nbFiles > 1) ? \" files\" : \" file\";\n printOut(nbFiles+strFiles+\" to compress\\n\", this.verbosity > 0);\n }\n\n if (this.verbosity > 2)\n {\n if (this.autoBlockSize == true)\n printOut(\"Block size set to 'auto'\", true);\n else\n printOut(\"Block size set to \" + this.blockSize + \" bytes\", true);\n\n printOut(\"Verbosity set to \" + this.verbosity, true);\n printOut(\"Overwrite set to \" + this.overwrite, true);\n printOut(\"Checksum set to \" + this.checksum, true);\n String etransform = (NONE.equals(this.transform)) ? \"no\" : this.transform;\n printOut(\"Using \" + etransform + \" transform (stage 1)\", true);\n String ecodec = (NONE.equals(this.codec)) ? \"no\" : this.codec;\n printOut(\"Using \" + ecodec + \" entropy codec (stage 2)\", true);\n printOut(\"Using \" + this.jobs + \" job\" + ((this.jobs > 1) ? \"s\" : \"\"), true);\n }\n \n // Limit verbosity level when files are processed concurrently\n if ((this.jobs > 1) && (nbFiles > 1) && (this.verbosity > 1)) {\n printOut(\"Warning: limiting verbosity to 1 due to concurrent processing of input files.\\n\", true);\n this.verbosity = 1;\n }\n\n if (this.verbosity > 2)\n this.addListener(new InfoPrinter(this.verbosity, InfoPrinter.Type.ENCODING, System.out));\n\n int res = 0;\n long read = 0;\n long written = 0;\n boolean inputIsDir = false;\n String formattedOutName = this.outputName;\n String formattedInName = this.inputName;\n boolean specialOutput = (NONE.equalsIgnoreCase(formattedOutName)) ||\n (STDOUT.equalsIgnoreCase(formattedOutName));\n\n try\n {\n if (STDIN.equalsIgnoreCase(this.inputName) == false)\n {\n if (Files.isDirectory(Paths.get(formattedInName)))\n {\n inputIsDir = true;\n\n if (formattedInName.endsWith(\".\") == true)\n formattedInName = formattedInName.substring(0, formattedInName.length()-1);\n\n if (formattedInName.endsWith(File.separator) == false)\n formattedInName += File.separator;\n\n if ((formattedOutName != null) && (specialOutput == false))\n {\n if (Files.isDirectory(Paths.get(formattedOutName)) == false)\n {\n System.err.println(\"Output must be an existing directory (or 'NONE')\");\n return Error.ERR_CREATE_FILE;\n }\n\n if (formattedOutName.endsWith(File.separator) == false)\n formattedOutName += File.separator;\n }\n }\n else\n {\n if ((formattedOutName != null) && (specialOutput == false))\n {\n if (Files.isDirectory(Paths.get(formattedOutName)) == true)\n {\n System.err.println(\"Output must be a file (or 'NONE')\");\n return Error.ERR_CREATE_FILE;\n }\n }\n }\n }\n\n Map<String, Object> ctx = new HashMap<>();\n ctx.put(\"verbosity\", this.verbosity);\n ctx.put(\"overwrite\", this.overwrite);\n ctx.put(\"skipBlocks\", this.skipBlocks);\n ctx.put(\"checksum\", this.checksum);\n ctx.put(\"pool\", this.pool);\n ctx.put(\"codec\", this.codec);\n ctx.put(\"transform\", this.transform);\n ctx.put(\"extra\", \"TPAQX\".equals(this.codec));\n\n // Run the task(s)\n if (nbFiles == 1)\n {\n String oName = formattedOutName;\n String iName = STDIN;\n\n if (STDIN.equalsIgnoreCase(this.inputName) == false)\n {\n iName = files.get(0).toString();\n long fileSize = Files.size(files.get(0));\n ctx.put(\"fileSize\", fileSize);\n\n if ((this.autoBlockSize == true) && (this.jobs > 0))\n {\n long bl = fileSize / this.jobs;\n bl = (bl + 63) & ~63;\n this.blockSize = (int) Math.max(Math.min(bl, MAX_BLOCK_SIZE), MIN_BLOCK_SIZE);\n }\n\n if (oName == null)\n {\n oName = iName + \".knz\";\n }\n else if ((inputIsDir == true) && (specialOutput == false))\n {\n oName = formattedOutName + iName.substring(formattedInName.length()+1) + \".knz\";\n }\n }\n\n ctx.put(\"inputName\", iName);\n ctx.put(\"outputName\", oName);\n ctx.put(\"blockSize\", this.blockSize);\n ctx.put(\"jobs\", this.jobs);\n FileCompressTask task = new FileCompressTask(ctx, this.listeners);\n FileCompressResult fcr = task.call();\n res = fcr.code;\n read = fcr.read;\n written = fcr.written;\n }\n else\n {\n ArrayBlockingQueue<FileCompressTask> queue = new ArrayBlockingQueue(nbFiles, true);\n int[] jobsPerTask = Global.computeJobsPerTask(new int[nbFiles], this.jobs, nbFiles);\n int n = 0;\n \n if (this.reoderFiles == true)\n Global.sortFilesByPathAndSize(files, true);\n\n // Create one task per file\n for (Path file : files)\n {\n String oName = formattedOutName;\n String iName = file.toString();\n long fileSize = Files.size(file);\n Map taskCtx = new HashMap(ctx);\n\n if ((this.autoBlockSize == true) && (this.jobs > 0))\n {\n long bl = fileSize / this.jobs;\n bl = (bl + 63) & ~63;\n this.blockSize = (int) Math.max(Math.min(bl, MAX_BLOCK_SIZE), MIN_BLOCK_SIZE);\n }\n\n if (oName == null)\n {\n oName = iName + \".knz\";\n }\n else if ((inputIsDir == true) && (specialOutput == false))\n {\n oName = formattedOutName + iName.substring(formattedInName.length()) + \".knz\";\n }\n\n taskCtx.put(\"fileSize\", fileSize);\n taskCtx.put(\"inputName\", iName);\n taskCtx.put(\"outputName\", oName);\n taskCtx.put(\"blockSize\", this.blockSize);\n taskCtx.put(\"jobs\", jobsPerTask[n++]);\n FileCompressTask task = new FileCompressTask(taskCtx, this.listeners);\n\n if (queue.offer(task) == false)\n throw new RuntimeException(\"Could not create a compression task\");\n }\n\n List<FileCompressWorker> workers = new ArrayList<>(this.jobs);\n\n\t\t \t // Create one worker per job and run it. A worker calls several tasks sequentially.\n for (int i=0; i<this.jobs; i++)\n workers.add(new FileCompressWorker(queue));\n\n // Invoke the tasks concurrently and wait for results\n // Using workers instead of tasks direclty, allows for early exit on failure\n for (Future<FileCompressResult> result : this.pool.invokeAll(workers))\n {\n FileCompressResult fcr = result.get();\n read += fcr.read;\n written += fcr.written;\n\n if (fcr.code != 0)\n {\n // Exit early by telling the workers that the queue is empty\n queue.clear();\n res = fcr.code;\n }\n }\n }\n }\n catch (Exception e)\n {\n System.err.println(\"An unexpected error occurred: \" + e.getMessage());\n res = Error.ERR_UNKNOWN;\n }\n\n long after = System.nanoTime();\n\n if (nbFiles > 1)\n {\n long delta = (after - before) / 1000000L; // convert to ms\n printOut(\"\", this.verbosity>0);\n String str;\n\n if (delta >= 100000) {\n str = String.format(\"%1$.1f\", (float) delta/1000) + \" s\";\n } else {\n str = String.valueOf(delta) + \" ms\";\n }\n\n printOut(\"Total compression time: \"+str, this.verbosity > 0);\n printOut(\"Total output size: \"+written+\" byte\"+((written>1)?\"s\":\"\"), this.verbosity > 0);\n\n if (read > 0)\n {\n float f = written / (float) read;\n printOut(\"Compression ratio: \"+String.format(\"%1$.6f\", f), this.verbosity > 0);\n }\n }\n\n return res;\n }",
"ICpPack getPack();",
"private void addFilesToZip(List<File> files,String outputPath) throws IOException \r\n\t{\r\n\t\t// create a zip output stream\r\n\t\tString zipFileName = outputPath + File.separator + Constants.name + zipIndex + Constants.zipExtension;\r\n\t\tOutputStreamWithLength chunkedFile = new OutputStreamWithLength(zipFileName);\r\n\t\tzipOutputStream = new ZipOutputStream(chunkedFile);\r\n\t\tdouble totalBytesRead = 0L;\r\n\t\tint count = 10; \r\n\t\tfor(File file:files)\r\n\t\t{\r\n\t\t\t// reset the file index\r\n\t\t\tfileIndex = 0;\r\n\t\t\tString zipEntryPath = file.getAbsolutePath().substring(basePath.length() + 0);\r\n\t\t\t\r\n\t\t\tif(file.isDirectory())\r\n\t\t\t{\r\n\t\t\t\tZipEntry entry =new ZipEntry(zipEntryPath+\"/\");\r\n\t\t\t\tzipOutputStream.putNextEntry(entry);\r\n\t\t\t\tzipOutputStream.closeEntry();\r\n\t\t\t\tcontinue;\r\n\t\t\t}\t\t\t\r\n\t\t\telse\r\n\t\t\t{\r\n\t\t\t\tzipEntryPath = zipEntryPath + Constants.fragmentLabel + fileIndex++;\r\n\t\t\t}\t\t\t\r\n\r\n\t\t\t// add the current file to the zip\r\n\t\t\tZipEntry entry =new ZipEntry(zipEntryPath);\r\n\t\t\tzipOutputStream.putNextEntry(entry);\r\n\r\n\t\t\tbyte[] buffer = new byte[1024]; \t \r\n\r\n\t\t\tFileInputStream inputFileStream = new FileInputStream(file);\r\n\t\t\tint len; \r\n\t\t\twhile ((len = inputFileStream.read(buffer)) > 0) \r\n\t\t\t{ \r\n\t\t\t\tif((chunkedFile.getCurrentWriteLength() + len ) > maxSplitSize){\r\n\t\t\t\t\t// close current zip output stream\r\n\t\t\t\t\tzipOutputStream.closeEntry();\r\n\t\t\t\t\tzipOutputStream.finish();\r\n\t\t\t\t\t\r\n\t\t\t\t\t// reset the write length\r\n\t\t\t\t\tchunkedFile.setCurrentWriteLength(0);\r\n\t\t\t\t\t\r\n\t\t\t\t\t// create new zip output stream\r\n\t\t\t\t\tzipIndex += 1;\r\n\t\t\t\t\tzipFileName = outputPath+ File.separator + Constants.name + zipIndex + Constants.zipExtension;\r\n\t\t\t\t\tchunkedFile = new OutputStreamWithLength(zipFileName);\r\n\t\t\t\t\tzipOutputStream = new ZipOutputStream(chunkedFile);\r\n\r\n\t\t\t\t\t// add the current file to write remaining bytes\r\n\t\t\t\t\tzipEntryPath = file.getAbsolutePath().substring(basePath.length() + 0);\r\n\t\t\t\t\tzipEntryPath = zipEntryPath + Constants.fragmentLabel + fileIndex++;\r\n\t\t\t\t\tentry = new ZipEntry(zipEntryPath);\r\n\t\t\t\t\tzipOutputStream.putNextEntry(entry);\r\n\r\n\t\t\t\t\t// write the bytes to the zip output stream\r\n\t\t\t\t\tzipOutputStream.write(buffer, 0, len);\r\n\t\t\t\t}\r\n\t\t\t\telse\r\n\t\t\t\t{\r\n\t\t\t\t\t// write the bytes to the zip output stream\r\n\t\t\t\t\tzipOutputStream.write(buffer, 0, len);\r\n\t\t\t\t}\r\n\t\t\t\t\r\n\t\t\t\t//Show progress\r\n\t\t\t\ttotalBytesRead += len;\r\n\t\t\t\tdouble progress = totalBytesRead / totalBytes;\r\n\t\t\t\tif (progress*100 > 10)\r\n\t\t\t\t{\r\n\t\t\t\t\ttotalBytesRead = 0L;\r\n\t\t\t\t\tcount += 10;\r\n\t\t\t\t\tSystem.out.println(\"Finished \" + count +\"%\");\r\n\t\t\t\t}\r\n\t\t\t}\t\t\t\t\t\t\r\n\t\t\tinputFileStream.close();\r\n\t\t}\r\n\r\n\t\tzipOutputStream.closeEntry();\r\n\t\tzipOutputStream.finish();\r\n\t}",
"List<CompressResult> decompress(Path input, Path output) throws IOException;",
"public static void main(String[] args) {\n\t\t\n\t\tBasicRLECompression compress = new BasicRLECompression('$');\n\t\t//String res = compress.compress(str);\n\t\t//System.out.println(res);\n\t\tString out = compress.uncompress(\"a$4g$4e$4f$1e$1a$f6\");\n\t\t//System.out.println(out);\n\t\t//System.out.println(str);\n\t\t//System.out.print(out.equals(str));\n\t}",
"public static void main(String[] args) {\n\tchar[] inChar;\n\ttry{\n\tif( args[0].equals(\"c\")){\n\tcompress(args[1]);\n\n\t}\n\telse if(args[0].equals(\"d\")){ // \n\tdecompress(args[1]);\n\t}\n\telse{\n\tthrow new Exception();\n\t}\n\n\n\t}//end try\n\n\t\n\tcatch(Exception e){\n\tSystem.err.println(\"exception thrown: \" + e.getMessage() );\n\t\t}\n\t}",
"public static synchronized void initializeArchiveFiles() {\n System.out.println(Thread.currentThread().getName() + \"********************************************************* TestHelper.initializeArchiveFiles\");\n File sourceFile = new File(System.getProperty(USER_DIR) + File.separator + \"QVCSEnterpriseServer.kbwb\");\n String firstDestinationDirName = System.getProperty(USER_DIR)\n + File.separator\n + QVCSConstants.QVCS_PROJECTS_DIRECTORY\n + File.separator\n + getTestProjectName();\n File firstDestinationDirectory = new File(firstDestinationDirName);\n firstDestinationDirectory.mkdirs();\n File firstDestinationFile = new File(firstDestinationDirName + File.separator + \"QVCSEnterpriseServer.kbwb\");\n\n String secondDestinationDirName = firstDestinationDirName + File.separator + SUBPROJECT_DIR_NAME;\n File secondDestinationDirectory = new File(secondDestinationDirName);\n secondDestinationDirectory.mkdirs();\n File secondDestinationFile = new File(secondDestinationDirName + File.separator + \"QVCSEnterpriseServer.kbwb\");\n\n String thirdDestinationDirName = secondDestinationDirName + File.separator + SUBPROJECT2_DIR_NAME;\n File thirdDestinationDirectory = new File(thirdDestinationDirName);\n thirdDestinationDirectory.mkdirs();\n File thirdDestinationFile = new File(thirdDestinationDirName + File.separator + \"ThirdDirectoryFile.kbwb\");\n\n File fourthDestinationFile = new File(firstDestinationDirName + File.separator + \"Server.kbwb\");\n File fifthDestinationFile = new File(firstDestinationDirName + File.separator + \"AnotherServer.kbwb\");\n File sixthDestinationFile = new File(firstDestinationDirName + File.separator + \"ServerB.kbwb\");\n File seventhDestinationFile = new File(firstDestinationDirName + File.separator + \"ServerC.kbwb\");\n try {\n ServerUtility.copyFile(sourceFile, firstDestinationFile);\n ServerUtility.copyFile(sourceFile, secondDestinationFile);\n ServerUtility.copyFile(sourceFile, thirdDestinationFile);\n ServerUtility.copyFile(sourceFile, fourthDestinationFile);\n ServerUtility.copyFile(sourceFile, fifthDestinationFile);\n ServerUtility.copyFile(sourceFile, sixthDestinationFile);\n ServerUtility.copyFile(sourceFile, seventhDestinationFile);\n } catch (IOException ex) {\n Logger.getLogger(TestHelper.class.getName()).log(Level.SEVERE, null, ex);\n }\n }",
"public static void main(String args[]) {\n\t\t\r\n\t\tnew HuffmanEncode(\"book3.txt\", \"book3Comp.txt\");\r\n\t\t//do not add anything here\r\n\t}",
"public static void main(String[] args) {\n \t\t\n \t\t// parse the command line options\n \t\tCommandLineParser parser = new PosixParser();\n \t\tCommandLine cmd = null;\n \t\ttry {\n \t\t\tcmd = parser.parse(createOptions(), args);\n \t\t}catch(org.apache.commons.cli.ParseException e) {\n \t\t\t// something bad happened so output help message\n \t\t\tprintCliHelp(\"Error in parsing arguments:\\n\" + e.getMessage());\n \t\t}\n \t\t\n \t\t/*\n \t\t * get and test the command line arguments\n \t\t */\n \n \t\t// input path\n \t\tString inputPath = cmd.getOptionValue(\"input\");\n \n \t\tif(StringUtils.isEmpty(inputPath)) {\n \t\t\tprintCliHelp(\"Error: the path to the input file / directory is required\");\n \t\t}\n \n \t\tif(FileUtils.isFileAccessible(inputPath) == false && FileUtils.isDirectoryAccessible(inputPath) == false) {\n \t\t\tprintCliHelp(\"Error: the input file / directory is not accessible\");\n \t\t}\n \n \t\tFile inputFile = new File(inputPath);\n \t\t\n \t\t// minimum file size\n \t\tString inputSize = cmd.getOptionValue(\"minsize\");\n \t\tint minFileSize = MIN_FILE_SIZE;\n \t\t\n \t\tif(StringUtils.isEmpty(inputSize) == false) {\n \t\t\ttry {\n \t\t\t\tminFileSize = Integer.parseInt(inputSize);\n \t\t\t} catch(NumberFormatException e) {\n \t\t\t\tprintCliHelp(\"Error: the minimum file size must be a valid integer\");\n \t\t\t}\n \t\t}\n \t\t\n \t\t// arbitrary file size in attempt to stop invalid data and \n \t\t// unnecessarily processing small files\n \t\tif(minFileSize < 10) {\n \t\t\tprintCliHelp(\"Error: the minimum file size must be greater than 10\");\n \t\t}\n \t\t\n \t\t// output path && template file\n \t\t\n \t\tFile outputDir = null;\n \t\tString scriptContents = null;\n \t\t\n \t\tString outputPath = cmd.getOptionValue(\"output\");\n \t\tString templatePath = cmd.getOptionValue(\"template\");\n \t\t\n \t\tif(StringUtils.isEmpty(outputPath) == false) {\n \t\t\tif(FileUtils.isDirectoryAccessible(outputPath) == false) {\n \t\t\t\tprintCliHelp(\"Error: the output directory is not accessible\");\n \t\t\t}\n \t\t\t\n \t\t\tif(StringUtils.isEmpty(templatePath)) {\n \t\t\t\tprintCliHelp(\"Error: the template must be specified when the output pararameter used\");\n \t\t\t}\n \t\t\t\n \t\t\tif(FileUtils.isFileAccessible(templatePath) == false) {\n \t\t\t\tprintCliHelp(\"Error: the osmosis script template file is not accesible\");\n \t\t\t}\n \t\t\t\n \t\t\toutputDir = new File(outputPath);\n \t\t\t\n \t\t\t// read the contents of the template file\n \t\t\ttry {\n \t\t\t\tscriptContents = org.apache.commons.io.FileUtils.readFileToString(new File(templatePath));\n \t\t\t} catch (IOException e1) {\n \t\t\t\tSystem.err.println(\"ERROR: unable to read the template file\");\n \t\t\t\tSystem.exit(-1);\n \t\t\t}\n \t\t}\n \t\t\n \t\t// ignore list path\n \t\tignoreList = new ArrayList<String>();\n \t\t\n \t\tString ignorePath = cmd.getOptionValue(\"ignore\");\n \t\t\n \t\tif(StringUtils.isEmpty(ignorePath) == false) {\n \t\t\t\n \t\t\tif(FileUtils.isFileAccessible(ignorePath) == false) {\n \t\t\t\tprintCliHelp(\"Error: the ignore list file is not accessible\");\n \t\t\t}\n \t\t\t\n \t\t\t// read the contents of the ignore list file\n \t\t\ttry {\n \t\t\t\tignoreList = (ArrayList<String>) org.apache.commons.io.FileUtils.readLines(new File(ignorePath));\n \t\t\t\t\n \t\t\t\t// strip out any comment lines\n \t\t\t\tfor (int i = 0; i < ignoreList.size(); i++) {\n \t\t\t\t\tif(ignoreList.get(i).startsWith(\"#\")) {\n \t\t\t\t\t\tignoreList.remove(i);\n \t\t\t\t\t\ti--;\n \t\t\t\t\t}\n \t\t\t\t}\n \t\t\t} catch (IOException e) {\n \t\t\t\tSystem.err.println(\"ERROR: unable to read the ignore list file\");\n \t\t\t\tSystem.exit(-1);\n \t\t\t}\n \t\t\t\n \t\t}\n \t\t\n \t\t/*\n \t\t * output some text\n \t\t */\n \t\tSystem.out.println(APP_NAME);\n \t\tSystem.out.println(\"Version: \" + APP_VERSION);\n \t\tSystem.out.println(\"More info: \" + MORE_INFO);\n \t\tSystem.out.println(\"License info: \" + LICENSE_INFO + \"\\n\");\n \t\t\n \t\t// inform user of resources we'll be working on\n \t\ttry {\n \t\t\tif(inputFile.isDirectory()) {\n \t\t\t\tSystem.out.println(\"Processing OSM PBF files in directory: \" + inputFile.getCanonicalPath());\n \t\t\t\t\n \t\t\t\t// test the files in the directory\n \t\t\t\tBBoxSplit.readFilesInDir(inputFile, outputDir, scriptContents, minFileSize);\n \t\t\t\t\n \t\t\t} else {\n \t\t\t\t\n \t\t\t\t// test the file\n \t\t\t\tBBoxSplit.readFile(inputFile, outputDir, scriptContents, minFileSize);\n \t\t\t}\n \t\t} catch (IOException e) {\n \t\t\tSystem.err.println(\"Unable to access file system resources.\\n\" + e.toString());\n \t\t\tSystem.exit(-1);\n \t\t}\n \t}",
"@Test\r\n\tpublic void testFullCapacityLowerToHigerWeight(){\r\n\t\tString expectedResult = \"1,2,4\";\r\n\t\tString itemsResults = Packer.pack(\"./src/test/resources/fullCapacityLowerToHigerWeight.txt\");\r\n\t\tassertEquals(expectedResult, itemsResults);\r\n\t\tSystem.out.println(\"Test passed. FullCapacityLowerToHigerWeight file.\");\r\n\t}",
"public static void unpackFiles() throws IOException {\n if(!new File(\"src/main/resources/tmp\").exists() || (Objects.requireNonNull(new File(\"src/main/resources/tmp\").list()).length != IO.sourceFiles.size())) {\n IO.unzipFiles();\n } else if(Objects.requireNonNull(new File(\"src/main/resources/tmp/ham_Calibration\").list()).length != new ZipFile(IO.sourceFiles.get(EmailTypes.HAM_CAL)).size()) {\n IO.unzipFiles(EmailTypes.HAM_CAL);\n } else if(Objects.requireNonNull(new File(\"src/main/resources/tmp/ham_Test\").list()).length != new ZipFile(IO.sourceFiles.get(EmailTypes.HAM_TEST)).size()) {\n IO.unzipFiles(EmailTypes.HAM_TEST);\n } else if(Objects.requireNonNull(new File(\"src/main/resources/tmp/ham_Train\").list()).length != new ZipFile(IO.sourceFiles.get(EmailTypes.HAM_TRAIN)).size()) {\n IO.unzipFiles(EmailTypes.HAM_TRAIN);\n } else if(Objects.requireNonNull(new File(\"src/main/resources/tmp/spam_Calibration\").list()).length != new ZipFile(IO.sourceFiles.get(EmailTypes.SPAM_CAL)).size()) {\n IO.unzipFiles(EmailTypes.SPAM_CAL);\n } else if(Objects.requireNonNull(new File(\"src/main/resources/tmp/spam_Test\").list()).length != new ZipFile(IO.sourceFiles.get(EmailTypes.SPAM_TEST)).size()) {\n IO.unzipFiles(EmailTypes.SPAM_TEST);\n } else if(Objects.requireNonNull(new File(\"src/main/resources/tmp/spam_Train\").list()).length != new ZipFile(IO.sourceFiles.get(EmailTypes.SPAM_TRAIN)).size()) {\n IO.unzipFiles(EmailTypes.SPAM_TRAIN);\n } else {\n System.out.println(\"Files already unpacked - skipping\\n\");\n }\n calculateSizes();\n }",
"public boolean ZipFile(String sSourceFilePath, String sDestinationZipFilePath, boolean bReplaceExisting) {\n byte[] buffer = new byte[30720];\n FileInputStream fin = null;\n FileOutputStream fout = null;\n ZipOutputStream zout = null;\n int length;\n String sZipEntryFileName = \"\";\n File objFile = null;\n try {\n //check for source file\n if (sSourceFilePath.trim().equalsIgnoreCase(\"\")) {\n throw new Exception(\"Invalid Source File : \" + sSourceFilePath);\n }\n objFile = new File(sSourceFilePath);\n if (!objFile.exists()) {\n throw new Exception(\"Source file not found : \" + sSourceFilePath);\n }\n\n //check for destination Zip file\n if (sDestinationZipFilePath.trim().equalsIgnoreCase(\"\") || sDestinationZipFilePath == null) {\n String stmp_Path = objFile.getAbsolutePath();\n String stmp_Name = objFile.getName();\n if (stmp_Name.contains(\".\")) { //check for removing extension\n int indx = 0;\n try {\n indx = stmp_Name.indexOf(\".\", stmp_Name.length() - 5);\n } catch (Exception e) {\n indx = 0;\n }\n if (indx <= 0) {\n indx = stmp_Name.length();\n }\n\n stmp_Name = stmp_Name.substring(0, indx);\n stmp_Name = stmp_Name + \".zip\";\n }\n sDestinationZipFilePath = stmp_Path + File.separator + stmp_Name;\n }\n\n objFile = new File(sDestinationZipFilePath);\n if (objFile.exists()) {\n if (bReplaceExisting) {\n objFile.delete();\n } else {\n throw new Exception(\"Destination ZipFile Already exists : \" + sDestinationZipFilePath);\n }\n }\n\n //Zipping File\n sZipEntryFileName = sSourceFilePath.substring(sSourceFilePath.lastIndexOf(\"\\\\\") + 1);\n fout = new FileOutputStream(sDestinationZipFilePath);\n zout = new ZipOutputStream(fout);\n fin = new FileInputStream(sSourceFilePath);\n zout.putNextEntry(new ZipEntry(sZipEntryFileName));\n while ((length = fin.read(buffer)) > 0) {\n zout.write(buffer, 0, length);\n }\n\n return true;\n\n } catch (Exception exp) {\n println(\"Src = \" + sSourceFilePath + \" : Dest = \" + sDestinationZipFilePath + \" : \" + exp.toString());\n return false;\n } finally {\n try {\n fin.close();\n } catch (Exception exp) {\n }\n try {\n zout.closeEntry();\n } catch (Exception exp) {\n }\n try {\n zout.close();\n } catch (Exception exp) {\n }\n }\n }",
"private void unCompress()\n\t{\n\t\ttry\n\t\t{\n\t\t\tbyte[] buffer = new byte[4096];\n\t\t\tint bytesIn;\n\t\t\tZipFile rfoFile = new ZipFile(path + fileName);\n\t\t\tEnumeration<? extends ZipEntry> allFiles = rfoFile.entries();\n\t\t\twhile(allFiles.hasMoreElements())\n\t\t\t{\n\t\t\t\tZipEntry ze = (ZipEntry)allFiles.nextElement();\n\t\t\t\tInputStream is = rfoFile.getInputStream(ze);\n\t\t\t\tString fName = processSeparators(ze.getName());\n\t\t\t\tFile element = new File(tempDir + fName);\n\t\t\t\torg.reprap.Main.ftd.add(element);\n\t\t\t\tFileOutputStream os = new FileOutputStream(element);\n\t\t\t\twhile((bytesIn = is.read(buffer)) != -1) \n\t\t\t\t\tos.write(buffer, 0, bytesIn);\n\t\t\t\tos.close();\n\t\t\t}\n\t\t} catch (Exception e)\n\t\t{\n\t\t\tDebug.e(\"RFO.unCompress(): \" + e);\n\t\t}\n\t}",
"public static void main(String[] args) throws Exception {\n\t\tMyDataOutputStream mdos = new MyDataOutputStream(new ByteArrayOutputStream());\n\t\tmdos.writeUTF8(\"testContent\", \"file1\", \"file2\");\n\t}",
"private ZipCompressor(){}",
"private final int zza(T r18, byte[] r19, int r20, int r21, int r22, int r23, int r24, int r25, int r26, long r27, int r29, com.google.android.gms.internal.clearcut.zzay r30) throws java.io.IOException {\n /*\n r17 = this;\n r0 = r17;\n r1 = r18;\n r3 = r19;\n r4 = r20;\n r2 = r22;\n r8 = r23;\n r5 = r24;\n r9 = r27;\n r6 = r29;\n r11 = r30;\n r12 = zzmh;\n r7 = r0.zzmi;\n r13 = r6 + 2;\n r7 = r7[r13];\n r13 = 1048575; // 0xfffff float:1.469367E-39 double:5.18065E-318;\n r7 = r7 & r13;\n r13 = (long) r7;\n r7 = 5;\n r15 = 2;\n switch(r26) {\n case 51: goto L_0x0168;\n case 52: goto L_0x0158;\n case 53: goto L_0x0148;\n case 54: goto L_0x0148;\n case 55: goto L_0x013b;\n case 56: goto L_0x012f;\n case 57: goto L_0x0124;\n case 58: goto L_0x010e;\n case 59: goto L_0x00e2;\n case 60: goto L_0x00bc;\n case 61: goto L_0x00a4;\n case 62: goto L_0x013b;\n case 63: goto L_0x0076;\n case 64: goto L_0x0124;\n case 65: goto L_0x012f;\n case 66: goto L_0x0068;\n case 67: goto L_0x005a;\n case 68: goto L_0x0028;\n default: goto L_0x0026;\n };\n L_0x0026:\n goto L_0x017c;\n L_0x0028:\n r7 = 3;\n if (r5 != r7) goto L_0x017c;\n L_0x002b:\n r2 = r2 & -8;\n r7 = r2 | 4;\n r2 = r0.zzad(r6);\n r3 = r19;\n r4 = r20;\n r5 = r21;\n r6 = r7;\n r7 = r30;\n r2 = zza(r2, r3, r4, r5, r6, r7);\n r3 = r12.getInt(r1, r13);\n if (r3 != r8) goto L_0x004b;\n L_0x0046:\n r15 = r12.getObject(r1, r9);\n goto L_0x004c;\n L_0x004b:\n r15 = 0;\n L_0x004c:\n if (r15 != 0) goto L_0x0052;\n L_0x004e:\n r3 = r11.zzff;\n goto L_0x0154;\n L_0x0052:\n r3 = r11.zzff;\n r3 = com.google.android.gms.internal.clearcut.zzci.zza(r15, r3);\n goto L_0x0154;\n L_0x005a:\n if (r5 != 0) goto L_0x017c;\n L_0x005c:\n r2 = com.google.android.gms.internal.clearcut.zzax.zzb(r3, r4, r11);\n r3 = r11.zzfe;\n r3 = com.google.android.gms.internal.clearcut.zzbk.zza(r3);\n goto L_0x0150;\n L_0x0068:\n if (r5 != 0) goto L_0x017c;\n L_0x006a:\n r2 = com.google.android.gms.internal.clearcut.zzax.zza(r3, r4, r11);\n r3 = r11.zzfd;\n r3 = com.google.android.gms.internal.clearcut.zzbk.zzm(r3);\n goto L_0x0143;\n L_0x0076:\n if (r5 != 0) goto L_0x017c;\n L_0x0078:\n r3 = com.google.android.gms.internal.clearcut.zzax.zza(r3, r4, r11);\n r4 = r11.zzfd;\n r5 = r0.zzaf(r6);\n if (r5 == 0) goto L_0x009a;\n L_0x0084:\n r5 = r5.zzb(r4);\n if (r5 == 0) goto L_0x008b;\n L_0x008a:\n goto L_0x009a;\n L_0x008b:\n r1 = zzn(r18);\n r4 = (long) r4;\n r4 = java.lang.Long.valueOf(r4);\n r1.zzb(r2, r4);\n r2 = r3;\n goto L_0x017d;\n L_0x009a:\n r2 = java.lang.Integer.valueOf(r4);\n r12.putObject(r1, r9, r2);\n r2 = r3;\n goto L_0x0178;\n L_0x00a4:\n if (r5 != r15) goto L_0x017c;\n L_0x00a6:\n r2 = com.google.android.gms.internal.clearcut.zzax.zza(r3, r4, r11);\n r4 = r11.zzfd;\n if (r4 != 0) goto L_0x00b2;\n L_0x00ae:\n r3 = com.google.android.gms.internal.clearcut.zzbb.zzfi;\n goto L_0x0154;\n L_0x00b2:\n r3 = com.google.android.gms.internal.clearcut.zzbb.zzb(r3, r2, r4);\n r12.putObject(r1, r9, r3);\n L_0x00b9:\n r2 = r2 + r4;\n goto L_0x0178;\n L_0x00bc:\n if (r5 != r15) goto L_0x017c;\n L_0x00be:\n r2 = r0.zzad(r6);\n r5 = r21;\n r2 = zza(r2, r3, r4, r5, r11);\n r3 = r12.getInt(r1, r13);\n if (r3 != r8) goto L_0x00d3;\n L_0x00ce:\n r15 = r12.getObject(r1, r9);\n goto L_0x00d4;\n L_0x00d3:\n r15 = 0;\n L_0x00d4:\n if (r15 != 0) goto L_0x00da;\n L_0x00d6:\n r3 = r11.zzff;\n goto L_0x0154;\n L_0x00da:\n r3 = r11.zzff;\n r3 = com.google.android.gms.internal.clearcut.zzci.zza(r15, r3);\n goto L_0x0154;\n L_0x00e2:\n if (r5 != r15) goto L_0x017c;\n L_0x00e4:\n r2 = com.google.android.gms.internal.clearcut.zzax.zza(r3, r4, r11);\n r4 = r11.zzfd;\n if (r4 != 0) goto L_0x00ef;\n L_0x00ec:\n r3 = \"\";\n goto L_0x0154;\n L_0x00ef:\n r5 = 536870912; // 0x20000000 float:1.0842022E-19 double:2.652494739E-315;\n r5 = r25 & r5;\n if (r5 == 0) goto L_0x0103;\n L_0x00f5:\n r5 = r2 + r4;\n r5 = com.google.android.gms.internal.clearcut.zzff.zze(r3, r2, r5);\n if (r5 == 0) goto L_0x00fe;\n L_0x00fd:\n goto L_0x0103;\n L_0x00fe:\n r1 = com.google.android.gms.internal.clearcut.zzco.zzbp();\n throw r1;\n L_0x0103:\n r5 = new java.lang.String;\n r6 = com.google.android.gms.internal.clearcut.zzci.UTF_8;\n r5.<init>(r3, r2, r4, r6);\n r12.putObject(r1, r9, r5);\n goto L_0x00b9;\n L_0x010e:\n if (r5 != 0) goto L_0x017c;\n L_0x0110:\n r2 = com.google.android.gms.internal.clearcut.zzax.zzb(r3, r4, r11);\n r3 = r11.zzfe;\n r5 = 0;\n r7 = (r3 > r5 ? 1 : (r3 == r5 ? 0 : -1));\n if (r7 == 0) goto L_0x011e;\n L_0x011c:\n r15 = 1;\n goto L_0x011f;\n L_0x011e:\n r15 = 0;\n L_0x011f:\n r3 = java.lang.Boolean.valueOf(r15);\n goto L_0x0154;\n L_0x0124:\n if (r5 != r7) goto L_0x017c;\n L_0x0126:\n r2 = com.google.android.gms.internal.clearcut.zzax.zzc(r19, r20);\n r2 = java.lang.Integer.valueOf(r2);\n goto L_0x0162;\n L_0x012f:\n r2 = 1;\n if (r5 != r2) goto L_0x017c;\n L_0x0132:\n r2 = com.google.android.gms.internal.clearcut.zzax.zzd(r19, r20);\n r2 = java.lang.Long.valueOf(r2);\n goto L_0x0173;\n L_0x013b:\n if (r5 != 0) goto L_0x017c;\n L_0x013d:\n r2 = com.google.android.gms.internal.clearcut.zzax.zza(r3, r4, r11);\n r3 = r11.zzfd;\n L_0x0143:\n r3 = java.lang.Integer.valueOf(r3);\n goto L_0x0154;\n L_0x0148:\n if (r5 != 0) goto L_0x017c;\n L_0x014a:\n r2 = com.google.android.gms.internal.clearcut.zzax.zzb(r3, r4, r11);\n r3 = r11.zzfe;\n L_0x0150:\n r3 = java.lang.Long.valueOf(r3);\n L_0x0154:\n r12.putObject(r1, r9, r3);\n goto L_0x0178;\n L_0x0158:\n if (r5 != r7) goto L_0x017c;\n L_0x015a:\n r2 = com.google.android.gms.internal.clearcut.zzax.zzf(r19, r20);\n r2 = java.lang.Float.valueOf(r2);\n L_0x0162:\n r12.putObject(r1, r9, r2);\n r2 = r4 + 4;\n goto L_0x0178;\n L_0x0168:\n r2 = 1;\n if (r5 != r2) goto L_0x017c;\n L_0x016b:\n r2 = com.google.android.gms.internal.clearcut.zzax.zze(r19, r20);\n r2 = java.lang.Double.valueOf(r2);\n L_0x0173:\n r12.putObject(r1, r9, r2);\n r2 = r4 + 8;\n L_0x0178:\n r12.putInt(r1, r13, r8);\n goto L_0x017d;\n L_0x017c:\n r2 = r4;\n L_0x017d:\n return r2;\n */\n throw new UnsupportedOperationException(\"Method not decompiled: com.google.android.gms.internal.clearcut.zzds.zza(java.lang.Object, byte[], int, int, int, int, int, int, int, long, int, com.google.android.gms.internal.clearcut.zzay):int\");\n }",
"private void createTar() {\n File tgzFile = new File(\".\" + File.separator + Arguments.JRE_DEFAULT_NAME);\n File tgzMd5File = new File(tgzFile.getPath() + \".md5\");\n if (tgzFile.exists()) {\n tgzFile.delete();\n m_logger.debug(\"Removed the old tgz file\");\n }\n if (tgzMd5File.exists()) {\n tgzMd5File.delete();\n m_logger.debug(\"Removed the old md5 file\");\n }\n\n try {\n m_logger.debug(\"Starting zip\");\n tgzFile.createNewFile();\n TarArchiveOutputStream tgzStream = new TarArchiveOutputStream(new GZIPOutputStream(\n new BufferedOutputStream(new FileOutputStream(tgzFile))));\n addFileToTarGz(tgzStream, m_jreLocation, \"\");\n tgzStream.finish();\n tgzStream.close();\n m_logger.debug(\"Finished zip, starting md5 hash\");\n\n Platform.runLater(() -> fileLabel.setText(\"Generating md5 hash\"));\n String md5Hash = MainApp.hashFile(tgzFile);\n OutputStream md5Out = new BufferedOutputStream(new FileOutputStream(tgzMd5File));\n md5Out.write(md5Hash.getBytes());\n md5Out.flush();\n md5Out.close();\n m_logger.debug(\"Finished md5 hash, hash is \" + md5Hash);\n final boolean interrupted = Thread.interrupted();\n\n // Show the connect roboRio screen\n Platform.runLater(() -> {\n if (!interrupted) {\n m_args.setArgument(Arguments.Argument.JRE_TAR, tgzFile.getAbsolutePath());\n moveNext(Arguments.Controller.CONNECT_ROBORIO_CONTROLLER);\n }\n });\n } catch (IOException | NoSuchAlgorithmException e) {\n m_logger.error(\"Could not create the tar gz file. Do we have write permissions to the current working directory?\", e);\n showErrorScreen(e);\n }\n }",
"public static void codeAllImages(Args args) throws FileNotFoundException, IOException{\n BufferedImage tempI=null, tempP=null;\n BufferedImage[] codeOut = null;\n FileOutputStream fos = new FileOutputStream(args.output);\n ZipOutputStream zipOS = new ZipOutputStream(fos);\n int j = 0;\n //Iterate through all the images dividing them into frameP or frameI\n for(int i= 0; i < imageNames.size(); i++){ \n //j is a counter of the gop\n if(j >= (args.gop)){\n j=0;\n }\n if(j==0){\n // Frame I\n tempI = imageDict.get(imageNames.get(i));\n imgToZip(tempI, i, zipOS, \"image_coded_\");\n }else{\n //Frame P\n codeOut = createCodedImg(tempI, imageDict.get(imageNames.get(i)), args.thresh, args.tileSize, args.seekRange, args.comparator);\n imgToZip(codeOut[0], i, zipOS, \"image_coded_\");\n tempI = codeOut[1];\n //showImage(tempP);\n }\n j++;\n }\n //Get the gop, its always the first position of the coded data\n dataList.get(0).gop = args.gop;\n //Store into a .gz file all the info of every tile of every image, info that is stored into our dataList\n try {\n FileOutputStream out = new FileOutputStream(\"codedData.gz\");\n GZIPOutputStream gos = new GZIPOutputStream(out);\n ObjectOutputStream oos = new ObjectOutputStream(gos);\n oos.writeObject(dataList);\n oos.flush();\n gos.flush();\n out.flush();\n \n oos.close();\n gos.close();\n out.close();\n } catch (Exception e) {\n System.out.println(\"Problem serializing: \" + e);\n }\n \n FileInputStream fis = new FileInputStream(\"codedData.gz\");\n ZipEntry e = new ZipEntry(\"codedData.gz\");\n zipOS.putNextEntry(e);\n\n byte[] bytes = new byte[1024];\n int length;\n while ((length = fis.read(bytes)) >= 0) {\n zipOS.write(bytes, 0, length);\n }\n zipOS.closeEntry();\n fis.close();\n zipOS.finish(); //Good practice!\n zipOS.close();\n }",
"private void generateGatewayBundle(ProjectSet bundleSymbolicNames) throws FileNotFoundException, IOException {\r\n Manifest manifest = new Manifest();\r\n Attributes attrs = manifest.getMainAttributes();\r\n StringBuffer requireBundle = new StringBuffer();\r\n for (String name : new HashSet<String>(bundleSymbolicNames.artifactToNameMap.values())) {\r\n requireBundle.append(name).append(\";\").append(RESOLUTION_DIRECTIVE).append(\":=\")\r\n .append(RESOLUTION_OPTIONAL);\r\n if (gatewayReexport) {\r\n requireBundle.append(\";\").append(VISIBILITY_DIRECTIVE).append(\":=\").append(VISIBILITY_REEXPORT);\r\n }\r\n requireBundle.append(\",\");\r\n }\r\n int len = requireBundle.length();\r\n if (len > 0 && requireBundle.charAt(len - 1) == ',') {\r\n requireBundle.deleteCharAt(len - 1);\r\n attrs.putValue(Constants.REQUIRE_BUNDLE, requireBundle.toString());\r\n attrs.putValue(\"Manifest-Version\", \"1.0\");\r\n attrs.putValue(\"Implementation-Vendor\", \"The Apache Software Foundation\");\r\n attrs.putValue(\"Implementation-Vendor-Id\", \"org.apache\");\r\n attrs.putValue(Constants.BUNDLE_VERSION, \"2.0.0\");\r\n attrs.putValue(Constants.BUNDLE_MANIFESTVERSION, \"2\");\r\n attrs.putValue(Constants.BUNDLE_SYMBOLICNAME, GATEWAY_BUNDLE);\r\n attrs.putValue(Constants.BUNDLE_NAME, \"Apache Tuscany SCA Gateway Bundle\");\r\n attrs.putValue(Constants.BUNDLE_VENDOR, \"The Apache Software Foundation\");\r\n attrs.putValue(Constants.EXPORT_PACKAGE, \"META-INF.services\");\r\n attrs.putValue(Constants.DYNAMICIMPORT_PACKAGE, \"*\");\r\n attrs.putValue(Constants.BUNDLE_ACTIVATIONPOLICY, Constants.ACTIVATION_LAZY);\r\n File file = new File(targetDirectory, \"tuscany-gateway-\" + project.getVersion() + \".jar\");\r\n getLog().info(\"Generating gateway bundle: \" + file.getAbsolutePath());\r\n FileOutputStream fos = new FileOutputStream(file);\r\n JarOutputStream jos = new JarOutputStream(fos, manifest);\r\n addFileToJar(jos, \"META-INF/LICENSE\", getClass().getResource(\"LICENSE.txt\"));\r\n addFileToJar(jos, \"META-INF/NOTICE\", getClass().getResource(\"NOTICE.txt\"));\r\n jos.close();\r\n }\r\n }",
"public static boolean SafeUnzipFile(ZipFile zf, String filepathinzip, File fileinfiledir, long crc) {\r\n BufferedOutputStream Output_fos = null;\r\n BufferedInputStream bufbr = null;\r\n try {\r\n ZipEntry ze = zf.getEntry(filepathinzip);\r\n if (ze == null) {\r\n if (Output_fos != null) {\r\n try {\r\n Output_fos.close();\r\n if (bufbr != null) {\r\n try {\r\n bufbr.close();\r\n } catch (IOException e) {\r\n e.printStackTrace();\r\n return false;\r\n }\r\n }\r\n } catch (IOException e2) {\r\n e2.printStackTrace();\r\n if (bufbr != null) {\r\n try {\r\n bufbr.close();\r\n } catch (IOException e3) {\r\n e3.printStackTrace();\r\n return false;\r\n }\r\n }\r\n return false;\r\n } finally {\r\n if (bufbr != null) {\r\n try {\r\n bufbr.close();\r\n } catch (IOException e4) {\r\n e4.printStackTrace();\r\n return false;\r\n }\r\n }\r\n }\r\n }\r\n return false;\r\n }\r\n if (crc != 0) {\r\n if (ze.getCrc() == crc) {\r\n if (Output_fos != null) {\r\n try {\r\n Output_fos.close();\r\n if (bufbr != null) {\r\n try {\r\n bufbr.close();\r\n } catch (IOException e5) {\r\n e5.printStackTrace();\r\n return false;\r\n }\r\n }\r\n } catch (IOException e6) {\r\n e6.printStackTrace();\r\n if (bufbr != null) {\r\n try {\r\n bufbr.close();\r\n } catch (IOException e7) {\r\n e7.printStackTrace();\r\n return false;\r\n }\r\n }\r\n return false;\r\n } finally {\r\n if (bufbr != null) {\r\n try {\r\n bufbr.close();\r\n } catch (IOException e8) {\r\n e8.printStackTrace();\r\n return false;\r\n }\r\n }\r\n }\r\n }\r\n return true;\r\n }\r\n }\r\n byte[] buf = UnzipFile(zf, ze);\r\n if (1 != 0) {\r\n BufferedOutputStream Output_fos2 = new BufferedOutputStream(new FileOutputStream(fileinfiledir));\r\n try {\r\n Output_fos2.write(buf, 0, buf.length);\r\n Output_fos = Output_fos2;\r\n } catch (Exception e9) {\r\n e = e9;\r\n Output_fos = Output_fos2;\r\n try {\r\n e.printStackTrace();\r\n if (Output_fos != null) {\r\n try {\r\n Output_fos.close();\r\n if (bufbr != null) {\r\n try {\r\n bufbr.close();\r\n } catch (IOException e10) {\r\n e10.printStackTrace();\r\n return false;\r\n }\r\n }\r\n } catch (IOException e11) {\r\n e11.printStackTrace();\r\n if (bufbr != null) {\r\n try {\r\n bufbr.close();\r\n } catch (IOException e12) {\r\n e12.printStackTrace();\r\n return false;\r\n }\r\n }\r\n return false;\r\n } finally {\r\n if (bufbr != null) {\r\n try {\r\n bufbr.close();\r\n } catch (IOException e13) {\r\n e13.printStackTrace();\r\n return false;\r\n }\r\n }\r\n }\r\n }\r\n return false;\r\n } catch (Throwable th) {\r\n th = th;\r\n if (Output_fos != null) {\r\n }\r\n throw th;\r\n }\r\n } catch (Throwable th2) {\r\n th = th2;\r\n Output_fos = Output_fos2;\r\n if (Output_fos != null) {\r\n try {\r\n Output_fos.close();\r\n if (bufbr != null) {\r\n try {\r\n bufbr.close();\r\n } catch (IOException e14) {\r\n e14.printStackTrace();\r\n return false;\r\n }\r\n }\r\n } catch (IOException e15) {\r\n e15.printStackTrace();\r\n if (bufbr != null) {\r\n try {\r\n bufbr.close();\r\n } catch (IOException e16) {\r\n e16.printStackTrace();\r\n return false;\r\n }\r\n }\r\n return false;\r\n } finally {\r\n if (bufbr != null) {\r\n try {\r\n bufbr.close();\r\n } catch (IOException e17) {\r\n e17.printStackTrace();\r\n return false;\r\n }\r\n }\r\n }\r\n }\r\n throw th;\r\n }\r\n }\r\n if (Output_fos != null) {\r\n try {\r\n Output_fos.close();\r\n if (bufbr != null) {\r\n try {\r\n bufbr.close();\r\n } catch (IOException e18) {\r\n e18.printStackTrace();\r\n return false;\r\n }\r\n }\r\n } catch (IOException e19) {\r\n e19.printStackTrace();\r\n if (bufbr != null) {\r\n try {\r\n bufbr.close();\r\n } catch (IOException e20) {\r\n e20.printStackTrace();\r\n return false;\r\n }\r\n }\r\n return false;\r\n } finally {\r\n if (bufbr != null) {\r\n try {\r\n bufbr.close();\r\n } catch (IOException e21) {\r\n e21.printStackTrace();\r\n return false;\r\n }\r\n }\r\n }\r\n }\r\n return true;\r\n } catch (Exception e22) {\r\n e = e22;\r\n }\r\n }",
"public void doPack() {\n if (this._sendData == null) {\n this._sendData = new byte[26];\n }\n System.arraycopy(BytesUtil.getBytes(this.mLongtitue), 0, this._sendData, 0, 8);\n System.arraycopy(BytesUtil.getBytes(this.mLantitue), 0, this._sendData, 8, 8);\n System.arraycopy(BytesUtil.getBytes(this.mNorthSpeed), 0, this._sendData, 16, 4);\n System.arraycopy(BytesUtil.getBytes(this.mEastSpeed), 0, this._sendData, 20, 4);\n System.arraycopy(BytesUtil.getBytes(this.mAccuracy), 0, this._sendData, 24, 2);\n }",
"public int addOlePackage(byte[] arg0, String arg1, String arg2, String arg3) throws IOException {\n\t\treturn 0;\n\t}",
"Pack(Bouquet bouquet)\n {\n this.bouquet = bouquet;\n }",
"public static void main(String[] args) throws IOException {\n\n _project _sc = _project.of();\n //reads from a maven-central jar file\n _downloadArchiveConsumer.of(\"https://search.maven.org/remotecontent?filepath=com/github/javaparser/javaparser-core/3.15.18/javaparser-core-3.15.18-sources.jar\",\n (ZipEntry ze, InputStream is)-> {\n if( ze.getName().endsWith(\".java\")){\n _sc.add( _codeUnit.of(is) );\n }\n });\n System.out.println( _sc.size() );\n\n _project _src = _githubProject.of(\"https://github.com/edefazio/bincat\").load();\n //_sources _src = _sources.of();\n //_downloadArchive _da = _downloadArchive.of(url, (ZipEntry ze,InputStream is)-> {\n // if( ze.getName().endsWith(\".java\")){\n // _src.add( _codeUnit.of(is) );\n // }\n //});\n /*\n try( InputStream inputStream = url.openStream();\n ZipInputStream zis = new ZipInputStream(inputStream) ) {\n\n byte[] buffer = new byte[2048];\n\n while (zis.available() > 0) {\n ZipEntry ze = zis.getNextEntry();\n System.out.println(\"reading \" + ze.getName());\n\n if( ze.isDirectory() ){\n ze.\n } else if( ze.)\n\n if (!ze.isDirectory() && ze.getName().endsWith(\".java\")) {\n ByteArrayOutputStream baos = new ByteArrayOutputStream();\n int len;\n while ((len = zis.read(buffer)) > 0) {\n baos.write(buffer, 0, len);\n }\n try {\n System.out.println(\"adding\" + ze.getName());\n _src.add(_codeUnit.of(baos.toString()));\n } catch (Exception e) {\n throw new _ioException(\"could not read from entry \" + ze.getName());\n }\n }\n }\n } catch (IOException e) {\n e.printStackTrace();\n }\n */\n\n System.out.println( \"finished reading \"+ _src.size());\n }",
"private void performAddJarSigCommand(String[] args) throws Exception {\n int i = 1;\n\n try {\n for (i = 1; i < args.length; i++) {\n\n if (args[i].equals(\"-encoding\")) {\n encoding = args[++i];\n } else if (args[i].equals(\"-keystore\")) {\n keystore = args[++i];\n } else if (args[i].equals(\"-storepass\")) {\n storepass = args[++i].toCharArray();\n } else if (args[i].equals(\"-keypass\")) {\n keypass = args[++i].toCharArray();\n } else if (args[i].equals(\"-alias\")) {\n alias = args[++i];\n } else if (args[i].equals(\"-jarfile\")) {\n jarfile = args[++i];\n } else if (args[i].equals(\"-inputjad\")) {\n infile = args[++i];\n } else if (args[i].equals(\"-outputjad\")) {\n outfile = args[++i];\n } else {\n usageError(\"Illegal option for \" + command +\n \": \" + args[i]);\n }\n }\n } catch (ArrayIndexOutOfBoundsException aiobe) {\n usageError(\"Missing value for \" + args[--i]);\n }\n\n if (keypass == null) {\n usageError(command + \" requires -keypass\");\n }\n\n // these methods will check for the presence of the args they need\n initJadUtil();\n openKeystoreAndOutputJad();\n\n if (jarfile != null) {\n // a jar file was specified for use\n FileInputStream jarinput;\n\n try {\n jarinput = new FileInputStream(jarfile);\n } catch (FileNotFoundException fnfe) {\n throw new Exception(\"JAR does not exist: \" + jarfile);\n }\n\n try {\n appdesc.addJarSignature(alias, keypass, jarinput);\n } catch (Exception e) {\n throw new Exception(command + \" failed: \" + e.toString());\n }\n\n try {\n jarinput.close();\n } catch (Exception e) {\n // ignore\n }\n } else {\n // Use the JAR at MIDlet-Jar-URL in the JAD\n try {\n appdesc.addJarSignature(alias, keypass);\n } catch (Exception e) {\n throw new Exception(command + \" failed: \" + e.toString());\n }\n }\n\n appdesc.store(outstream, encoding);\n return;\n }",
"public MacAppStoreBundler(String[] args){\n appFilePath = args[0];\n packageName = args[1];\n signatureName = args[2];\n categoryType = args[3];\n entitlementFilePath = args[4];\n packageFilePath = args[5];\n }",
"private void shiftFile(String file, int inx) {\r\n\t\t\tString[] fs = new String[files.length];\r\n\t\t\tfs[0] = file;\r\n\t\t\tfor (int i = 0; i < inx; i++)\r\n\t\t\t\tfs[i + 1] = files[i];\r\n\t\t\tfor (int i = inx + 1; i < files.length; i++)\r\n\t\t\t\tfs[i] = files[i];\r\n\t\t\tSystem.arraycopy(fs, 0, files, 0, files.length);\r\n\t\t}",
"@Test\n public void test() throws IOException {\n int numVertices = 0;\n \n //Step1: Compression\n DifferenceEncodingOutputStream deos = new DifferenceEncodingOutputStream(\n new FileOutputStream(\"/tmp/preferentialAttachment.dz\"));\n \n InputStream in = getClass().getResourceAsStream(\"/preferentialAttachment.graph\"); \n BufferedReader bin = new BufferedReader(new InputStreamReader(in));\n \n String line = null;\n while((line = bin.readLine()) != null) {\n int[] adj = getSorted(line);\n deos.writeAdjacency(adj);\n numVertices++;\n }\n deos.close();\n bin.close();\n in = getClass().getResourceAsStream(\"/preferentialAttachment.graph\"); \n bin = new BufferedReader(new InputStreamReader(in));\n \n //Step2: Decompression and verification\n DifferenceEncodingInputStream deis = new DifferenceEncodingInputStream(\n new FileInputStream(\"/tmp/preferentialAttachment.dz\"));\n \n OutputStream out = new FileOutputStream(\"/tmp/preferentialAttachmentDecompressed.graph\");\n BufferedWriter bw = new BufferedWriter(new OutputStreamWriter(out));\n for(int i = 0; i < numVertices; i++) {\n int[] adj = deis.readAdjacency();\n bw.write(\"\"+adj[0]);\n \n int[] adjOrig = getSorted(bin.readLine());\n Assert.assertArrayEquals(adjOrig, adj);\n for(int j = 1; j < adj.length; j++) {\n bw.write(\" \");\n bw.write(\"\"+adj[j]); \n }\n bw.write(\"\\n\");\n }\n deis.close();\n bin.close();\n }",
"protected ArrayList<File> prepareUpload(Modpack modpack, String workspace) throws Exception {\n String uploadDirectory = workspace + \"/\" + String.valueOf(modpack.getId()) + \"-\" + modpack.getName() + \"/\";\n File dir = new File(uploadDirectory);\n ArrayList<File> files = new ArrayList<>();\n if (dir != null) {\n File zipToUpload = createZipArchive(dir, modpack.getName(), workspace);\n files.add(zipToUpload);\n }\n return files;\n }",
"public static int PrepareSecurefiles(Context ctx, ZipFile apkzf) {\r\n ZipEntry fileUnzip;\r\n ZipEntry fileUnzip2;\r\n ZipEntry fileUnzip3;\r\n RandomAccessFile raf = null;\r\n FileLock file_lock = null;\r\n RandomAccessFile raf2 = null;\r\n String Appfiledir = new StringBuilder(String.valueOf(ctx.getFilesDir().getAbsolutePath())).append(\"/prodexdir\").toString();\r\n File Appprofiledir = new File(Appfiledir);\r\n if (!Appprofiledir.isDirectory()) {\r\n Appprofiledir.mkdir();\r\n }\r\n String Cookiefilepath = new StringBuilder(String.valueOf(Appfiledir)).append(\"/\").append(versionname).toString();\r\n String backupfilepath = new StringBuilder(String.valueOf(Appfiledir)).append(\"/backUp\").toString();\r\n String firstloadfilepath = new StringBuilder(String.valueOf(Appfiledir)).append(\"/firstLoad\").toString();\r\n String Cookiefileinzip = \"assets/\" + versionname;\r\n String Libnameinapk = \"libtosprotection.\" + CPUABI + \".so\";\r\n try {\r\n raf = new RandomAccessFile(Cookiefilepath, \"rw\");\r\n try {\r\n raf = raf.getChannel();\r\n file_lock = raf.lock();\r\n File Cookiefile = new File(Cookiefilepath);\r\n try {\r\n if (Cookiefile.length() != 0) {\r\n int compareResult = Comparetxtinzip(apkzf, Cookiefileinzip, Cookiefile);\r\n if (compareResult == 1) {\r\n File secureDataFile = new File(new StringBuilder(String.valueOf(Appfiledir)).append(\"/\").append(securename5).toString());\r\n if (!secureDataFile.exists() || secureDataFile.length() == 0) {\r\n SafeUnzipFile(apkzf, \"assets/\" + securename5, secureDataFile, 0);\r\n } else {\r\n SafeUnzipFile(apkzf, \"assets/\" + securename5, secureDataFile, getFileCRC32(secureDataFile));\r\n }\r\n ZipEntry fileUnzip4 = apkzf.getEntry(\"assets/\" + Libnameinapk);\r\n if (fileUnzip4 != null) {\r\n if (!isFileValid(new StringBuilder(String.valueOf(Appfiledir)).append(\"/\").append(libname).toString(), fileUnzip4.getSize())) {\r\n UnzipFile(apkzf, \"assets/\" + Libnameinapk, new File(new StringBuilder(String.valueOf(Appfiledir)).append(\"/\").append(libname).toString()));\r\n }\r\n }\r\n ZipEntry fileUnzip5 = apkzf.getEntry(\"assets/\" + Libnameinapk);\r\n if (fileUnzip5 != null) {\r\n if (!isFileValid(new StringBuilder(String.valueOf(Appfiledir)).append(\"/\").append(securename6).toString(), fileUnzip5.getSize())) {\r\n UnzipFile(apkzf, \"assets/\" + securename6, new File(new StringBuilder(String.valueOf(Appfiledir)).append(\"/\").append(securename6).toString()));\r\n }\r\n }\r\n ZipEntry fileUnzip6 = apkzf.getEntry(\"assets/\" + Libnameinapk);\r\n if (fileUnzip6 != null) {\r\n if (!isFileValid(new StringBuilder(String.valueOf(Appfiledir)).append(\"/\").append(securename7).toString(), fileUnzip6.getSize())) {\r\n UnzipFile(apkzf, \"assets/\" + securename7, new File(new StringBuilder(String.valueOf(Appfiledir)).append(\"/\").append(securename7).toString()));\r\n }\r\n }\r\n ZipEntry fileUnzip7 = apkzf.getEntry(Cookiefileinzip);\r\n if (fileUnzip7 != null && !isFileValid(Cookiefilepath, fileUnzip7.getSize())) {\r\n File file = new File(Cookiefilepath);\r\n UnzipFile(apkzf, Cookiefileinzip, file);\r\n }\r\n if (file_lock != null) {\r\n try {\r\n file_lock.release();\r\n if (raf != null) {\r\n try {\r\n raf.close();\r\n if (raf != null) {\r\n try {\r\n raf.close();\r\n } catch (IOException e) {\r\n e.printStackTrace();\r\n RandomAccessFile randomAccessFile = raf;\r\n File file2 = Cookiefile;\r\n return ERROR_FILE_NOT_FOUND;\r\n }\r\n }\r\n } catch (IOException e2) {\r\n e2.printStackTrace();\r\n if (raf != null) {\r\n try {\r\n raf.close();\r\n } catch (IOException e3) {\r\n e3.printStackTrace();\r\n RandomAccessFile randomAccessFile2 = raf;\r\n File file3 = Cookiefile;\r\n return ERROR_FILE_NOT_FOUND;\r\n }\r\n }\r\n RandomAccessFile randomAccessFile3 = raf;\r\n File file4 = Cookiefile;\r\n return ERROR_FILE_NOT_FOUND;\r\n } finally {\r\n if (raf != null) {\r\n try {\r\n raf.close();\r\n } catch (IOException e4) {\r\n e4.printStackTrace();\r\n RandomAccessFile randomAccessFile4 = raf;\r\n File file5 = Cookiefile;\r\n return ERROR_FILE_NOT_FOUND;\r\n }\r\n }\r\n }\r\n }\r\n } catch (IOException e5) {\r\n e5.printStackTrace();\r\n if (raf != null) {\r\n try {\r\n raf.close();\r\n if (raf != null) {\r\n try {\r\n raf.close();\r\n } catch (IOException e6) {\r\n e6.printStackTrace();\r\n RandomAccessFile randomAccessFile5 = raf;\r\n File file6 = Cookiefile;\r\n return ERROR_FILE_NOT_FOUND;\r\n }\r\n }\r\n } catch (IOException e7) {\r\n e7.printStackTrace();\r\n if (raf != null) {\r\n try {\r\n raf.close();\r\n } catch (IOException e8) {\r\n e8.printStackTrace();\r\n RandomAccessFile randomAccessFile6 = raf;\r\n File file7 = Cookiefile;\r\n return ERROR_FILE_NOT_FOUND;\r\n }\r\n }\r\n RandomAccessFile randomAccessFile7 = raf;\r\n File file8 = Cookiefile;\r\n return ERROR_FILE_NOT_FOUND;\r\n } finally {\r\n if (raf != null) {\r\n try {\r\n raf.close();\r\n } catch (IOException e9) {\r\n e9.printStackTrace();\r\n RandomAccessFile randomAccessFile8 = raf;\r\n File file9 = Cookiefile;\r\n return ERROR_FILE_NOT_FOUND;\r\n }\r\n }\r\n }\r\n }\r\n RandomAccessFile randomAccessFile9 = raf;\r\n File file10 = Cookiefile;\r\n return ERROR_FILE_NOT_FOUND;\r\n } finally {\r\n if (raf != null) {\r\n try {\r\n raf.close();\r\n if (raf != null) {\r\n try {\r\n raf.close();\r\n } catch (IOException e10) {\r\n e10.printStackTrace();\r\n RandomAccessFile randomAccessFile10 = raf;\r\n File file11 = Cookiefile;\r\n return ERROR_FILE_NOT_FOUND;\r\n }\r\n }\r\n } catch (IOException e11) {\r\n e11.printStackTrace();\r\n if (raf != null) {\r\n try {\r\n raf.close();\r\n } catch (IOException e12) {\r\n e12.printStackTrace();\r\n RandomAccessFile randomAccessFile11 = raf;\r\n File file12 = Cookiefile;\r\n return ERROR_FILE_NOT_FOUND;\r\n }\r\n }\r\n RandomAccessFile randomAccessFile12 = raf;\r\n File file13 = Cookiefile;\r\n return ERROR_FILE_NOT_FOUND;\r\n } finally {\r\n if (raf != null) {\r\n try {\r\n raf.close();\r\n } catch (IOException e13) {\r\n e13.printStackTrace();\r\n RandomAccessFile randomAccessFile13 = raf;\r\n File file14 = Cookiefile;\r\n return ERROR_FILE_NOT_FOUND;\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n RandomAccessFile randomAccessFile14 = raf;\r\n File file15 = Cookiefile;\r\n return 2;\r\n } else if (compareResult != 0) {\r\n Process.killProcess(Process.myPid());\r\n System.exit(0);\r\n }\r\n }\r\n DeleteFile(new StringBuilder(String.valueOf(Appfiledir)).append(\"/\").append(libname).toString());\r\n DeleteFile(new StringBuilder(String.valueOf(Appfiledir)).append(\"/\").append(securename6).toString());\r\n int file_count = 0;\r\n while (file_count < MAX_DEX_NUM) {\r\n int deletedexresult = DeleteFile(new StringBuilder(String.valueOf(Appfiledir)).append(\"/\").append(CreatenewFileName(securename0, \".\", \"_\" + file_count)).toString());\r\n int deletejarresult = DeleteFile(new StringBuilder(String.valueOf(Appfiledir)).append(\"/\").append(CreatenewFileName(securename1, \".\", \"_\" + file_count)).toString());\r\n int deleteodexresult = DeleteFile(new StringBuilder(String.valueOf(Appfiledir)).append(\"/\").append(\"odexdir\").append(\"/\").append(CreatenewFileName(securename0, \".\", \"_\" + file_count)).toString());\r\n int deleteflagresult = DeleteFile(new StringBuilder(String.valueOf(Appfiledir)).append(\"/\").append(\"odexdir\").append(\"/\").append(CreatenewFileName(securename8, \".\", \"_\" + file_count)).toString());\r\n DeleteFile(new StringBuilder(String.valueOf(Appfiledir)).append(\"/\").append(\"oat/arm\").append(\"/\").append(CreatenewFileName(securename8, \".\", \"_\" + file_count)).toString());\r\n if (ERROR_FILE_NOT_FOUND == deletedexresult && ERROR_FILE_NOT_FOUND == deletejarresult && ERROR_FILE_NOT_FOUND == deleteodexresult) {\r\n break;\r\n }\r\n if (ERROR_EXCEPTION == deletedexresult || ERROR_EXCEPTION == deletejarresult || ERROR_EXCEPTION == deleteodexresult) {\r\n Process.killProcess(Process.myPid());\r\n System.exit(0);\r\n }\r\n file_count++;\r\n }\r\n DeleteFile(new StringBuilder(String.valueOf(Appfiledir)).append(\"/\").append(securename9).toString());\r\n DeleteFile(new StringBuilder(String.valueOf(Appfiledir)).append(\"/\").append(securename5).toString());\r\n UnzipFile(apkzf, \"assets/\" + securename5, new File(new StringBuilder(String.valueOf(Appfiledir)).append(\"/\").append(securename5).toString()));\r\n UnzipFile(apkzf, \"assets/\" + libname, new File(new StringBuilder(String.valueOf(Appfiledir)).append(\"/\").append(libname).toString()));\r\n UnzipFile(apkzf, \"assets/\" + securename6, new File(new StringBuilder(String.valueOf(Appfiledir)).append(\"/\").append(securename6).toString()));\r\n UnzipFile(apkzf, \"assets/\" + securename7, new File(new StringBuilder(String.valueOf(Appfiledir)).append(\"/\").append(securename7).toString()));\r\n File file16 = new File(Cookiefilepath);\r\n UnzipFile(apkzf, Cookiefileinzip, file16);\r\n for (int file_count2 = 0; file_count2 < file_count; file_count2++) {\r\n int deletedexresult2 = DeleteFile(new StringBuilder(String.valueOf(backupfilepath)).append(\"/\").append(CreatenewFileName(securename0, \".\", \"_\" + file_count2)).toString());\r\n int deletejarresult2 = DeleteFile(new StringBuilder(String.valueOf(backupfilepath)).append(\"/\").append(CreatenewFileName(securename1, \".\", \"_\" + file_count2)).toString());\r\n int deleteodexresult2 = DeleteFile(new StringBuilder(String.valueOf(backupfilepath)).append(\"/\").append(\"odexdir\").append(\"/\").append(CreatenewFileName(securename0, \".\", \"_\" + file_count2)).toString());\r\n int deleteflagresult2 = DeleteFile(new StringBuilder(String.valueOf(backupfilepath)).append(\"/\").append(\"odexdir\").append(\"/\").append(CreatenewFileName(securename8, \".\", \"_\" + file_count2)).toString());\r\n DeleteFile(new StringBuilder(String.valueOf(backupfilepath)).append(\"/\").append(\"oat/arm\").append(\"/\").append(CreatenewFileName(securename8, \".\", \"_\" + file_count2)).toString());\r\n if (ERROR_FILE_NOT_FOUND == deletedexresult2 && ERROR_FILE_NOT_FOUND == deletejarresult2 && ERROR_FILE_NOT_FOUND == deleteodexresult2) {\r\n break;\r\n }\r\n if (ERROR_EXCEPTION == deletedexresult2 || ERROR_EXCEPTION == deletejarresult2 || ERROR_EXCEPTION == deleteodexresult2) {\r\n Process.killProcess(Process.myPid());\r\n System.exit(0);\r\n }\r\n }\r\n for (int file_count3 = 0; file_count3 < file_count; file_count3++) {\r\n int deletedexresult3 = DeleteFile(new StringBuilder(String.valueOf(firstloadfilepath)).append(\"/\").append(CreatenewFileName(securename0, \".\", \"_\" + file_count3)).toString());\r\n int deletejarresult3 = DeleteFile(new StringBuilder(String.valueOf(firstloadfilepath)).append(\"/\").append(CreatenewFileName(securename1, \".\", \"_\" + file_count3)).toString());\r\n int deleteodexresult3 = DeleteFile(new StringBuilder(String.valueOf(firstloadfilepath)).append(\"/\").append(\"odexdir\").append(\"/\").append(CreatenewFileName(securename0, \".\", \"_\" + file_count3)).toString());\r\n int deleteflagresult3 = DeleteFile(new StringBuilder(String.valueOf(firstloadfilepath)).append(\"/\").append(\"odexdir\").append(\"/\").append(CreatenewFileName(securename8, \".\", \"_\" + file_count3)).toString());\r\n DeleteFile(new StringBuilder(String.valueOf(firstloadfilepath)).append(\"/\").append(\"oat/arm\").append(\"/\").append(CreatenewFileName(securename8, \".\", \"_\" + file_count3)).toString());\r\n if (ERROR_FILE_NOT_FOUND == deletedexresult3 && ERROR_FILE_NOT_FOUND == deletejarresult3 && ERROR_FILE_NOT_FOUND == deleteodexresult3) {\r\n break;\r\n }\r\n if (ERROR_EXCEPTION == deletedexresult3 || ERROR_EXCEPTION == deletejarresult3 || ERROR_EXCEPTION == deleteodexresult3) {\r\n Process.killProcess(Process.myPid());\r\n System.exit(0);\r\n }\r\n }\r\n ZipEntry fileUnzip8 = apkzf.getEntry(\"assets/\" + Libnameinapk);\r\n if (fileUnzip8 != null) {\r\n if (!isFileValid(new StringBuilder(String.valueOf(Appfiledir)).append(\"/\").append(libname).toString(), fileUnzip8.getSize())) {\r\n UnzipFile(apkzf, \"assets/\" + Libnameinapk, new File(new StringBuilder(String.valueOf(Appfiledir)).append(\"/\").append(libname).toString()));\r\n }\r\n }\r\n ZipEntry fileUnzip9 = apkzf.getEntry(\"assets/\" + Libnameinapk);\r\n if (fileUnzip9 != null) {\r\n if (!isFileValid(new StringBuilder(String.valueOf(Appfiledir)).append(\"/\").append(securename6).toString(), fileUnzip9.getSize())) {\r\n UnzipFile(apkzf, \"assets/\" + securename6, new File(new StringBuilder(String.valueOf(Appfiledir)).append(\"/\").append(securename6).toString()));\r\n }\r\n }\r\n ZipEntry fileUnzip10 = apkzf.getEntry(\"assets/\" + Libnameinapk);\r\n if (fileUnzip10 != null) {\r\n if (!isFileValid(new StringBuilder(String.valueOf(Appfiledir)).append(\"/\").append(securename7).toString(), fileUnzip10.getSize())) {\r\n UnzipFile(apkzf, \"assets/\" + securename7, new File(new StringBuilder(String.valueOf(Appfiledir)).append(\"/\").append(securename7).toString()));\r\n }\r\n }\r\n ZipEntry fileUnzip11 = apkzf.getEntry(Cookiefileinzip);\r\n if (fileUnzip11 != null && !isFileValid(Cookiefilepath, fileUnzip11.getSize())) {\r\n File file17 = new File(Cookiefilepath);\r\n UnzipFile(apkzf, Cookiefileinzip, file17);\r\n }\r\n if (file_lock != null) {\r\n try {\r\n file_lock.release();\r\n if (raf != null) {\r\n try {\r\n raf.close();\r\n if (raf != null) {\r\n try {\r\n raf.close();\r\n } catch (IOException e14) {\r\n e14.printStackTrace();\r\n RandomAccessFile randomAccessFile15 = raf;\r\n File file18 = Cookiefile;\r\n return ERROR_FILE_NOT_FOUND;\r\n }\r\n }\r\n } catch (IOException e15) {\r\n e15.printStackTrace();\r\n if (raf != null) {\r\n try {\r\n raf.close();\r\n } catch (IOException e16) {\r\n e16.printStackTrace();\r\n RandomAccessFile randomAccessFile16 = raf;\r\n File file19 = Cookiefile;\r\n return ERROR_FILE_NOT_FOUND;\r\n }\r\n }\r\n RandomAccessFile randomAccessFile17 = raf;\r\n File file20 = Cookiefile;\r\n return ERROR_FILE_NOT_FOUND;\r\n } finally {\r\n if (raf != null) {\r\n try {\r\n raf.close();\r\n } catch (IOException e17) {\r\n e17.printStackTrace();\r\n RandomAccessFile randomAccessFile18 = raf;\r\n File file21 = Cookiefile;\r\n return ERROR_FILE_NOT_FOUND;\r\n }\r\n }\r\n }\r\n }\r\n } catch (IOException e18) {\r\n e18.printStackTrace();\r\n if (raf != null) {\r\n try {\r\n raf.close();\r\n if (raf != null) {\r\n try {\r\n raf.close();\r\n } catch (IOException e19) {\r\n e19.printStackTrace();\r\n RandomAccessFile randomAccessFile19 = raf;\r\n File file22 = Cookiefile;\r\n return ERROR_FILE_NOT_FOUND;\r\n }\r\n }\r\n } catch (IOException e20) {\r\n e20.printStackTrace();\r\n if (raf != null) {\r\n try {\r\n raf.close();\r\n } catch (IOException e21) {\r\n e21.printStackTrace();\r\n RandomAccessFile randomAccessFile20 = raf;\r\n File file23 = Cookiefile;\r\n return ERROR_FILE_NOT_FOUND;\r\n }\r\n }\r\n RandomAccessFile randomAccessFile21 = raf;\r\n File file24 = Cookiefile;\r\n return ERROR_FILE_NOT_FOUND;\r\n } finally {\r\n if (raf != null) {\r\n try {\r\n raf.close();\r\n } catch (IOException e22) {\r\n e22.printStackTrace();\r\n RandomAccessFile randomAccessFile22 = raf;\r\n File file25 = Cookiefile;\r\n return ERROR_FILE_NOT_FOUND;\r\n }\r\n }\r\n }\r\n }\r\n RandomAccessFile randomAccessFile23 = raf;\r\n File file26 = Cookiefile;\r\n return ERROR_FILE_NOT_FOUND;\r\n } finally {\r\n if (raf != null) {\r\n try {\r\n raf.close();\r\n if (raf != null) {\r\n try {\r\n raf.close();\r\n } catch (IOException e23) {\r\n e23.printStackTrace();\r\n RandomAccessFile randomAccessFile24 = raf;\r\n File file27 = Cookiefile;\r\n return ERROR_FILE_NOT_FOUND;\r\n }\r\n }\r\n } catch (IOException e24) {\r\n e24.printStackTrace();\r\n if (raf != null) {\r\n try {\r\n raf.close();\r\n } catch (IOException e25) {\r\n e25.printStackTrace();\r\n RandomAccessFile randomAccessFile25 = raf;\r\n File file28 = Cookiefile;\r\n return ERROR_FILE_NOT_FOUND;\r\n }\r\n }\r\n RandomAccessFile randomAccessFile26 = raf;\r\n File file29 = Cookiefile;\r\n return ERROR_FILE_NOT_FOUND;\r\n } finally {\r\n if (raf != null) {\r\n try {\r\n raf.close();\r\n } catch (IOException e26) {\r\n e26.printStackTrace();\r\n RandomAccessFile randomAccessFile27 = raf;\r\n File file30 = Cookiefile;\r\n return ERROR_FILE_NOT_FOUND;\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n RandomAccessFile randomAccessFile28 = raf;\r\n File file31 = Cookiefile;\r\n return 0;\r\n } catch (Exception e27) {\r\n e = e27;\r\n raf2 = raf;\r\n File file32 = Cookiefile;\r\n } catch (Throwable th) {\r\n th = th;\r\n raf2 = raf;\r\n File file33 = Cookiefile;\r\n ZipEntry fileUnzip12 = apkzf.getEntry(\"assets/\" + Libnameinapk);\r\n if (fileUnzip12 != null && !isFileValid(new StringBuilder(String.valueOf(Appfiledir)).append(\"/\").append(libname).toString(), fileUnzip12.getSize())) {\r\n UnzipFile(apkzf, \"assets/\" + Libnameinapk, new File(new StringBuilder(String.valueOf(Appfiledir)).append(\"/\").append(libname).toString()));\r\n }\r\n ZipEntry fileUnzip13 = apkzf.getEntry(\"assets/\" + Libnameinapk);\r\n if (fileUnzip13 != null && !isFileValid(new StringBuilder(String.valueOf(Appfiledir)).append(\"/\").append(securename6).toString(), fileUnzip13.getSize())) {\r\n UnzipFile(apkzf, \"assets/\" + securename6, new File(new StringBuilder(String.valueOf(Appfiledir)).append(\"/\").append(securename6).toString()));\r\n }\r\n ZipEntry fileUnzip14 = apkzf.getEntry(\"assets/\" + Libnameinapk);\r\n if (fileUnzip14 != null && !isFileValid(new StringBuilder(String.valueOf(Appfiledir)).append(\"/\").append(securename7).toString(), fileUnzip14.getSize())) {\r\n UnzipFile(apkzf, \"assets/\" + securename7, new File(new StringBuilder(String.valueOf(Appfiledir)).append(\"/\").append(securename7).toString()));\r\n }\r\n ZipEntry fileUnzip15 = apkzf.getEntry(Cookiefileinzip);\r\n if (fileUnzip15 != null && !isFileValid(Cookiefilepath, fileUnzip15.getSize())) {\r\n File file34 = new File(Cookiefilepath);\r\n UnzipFile(apkzf, Cookiefileinzip, file34);\r\n }\r\n if (file_lock != null) {\r\n try {\r\n file_lock.release();\r\n if (raf != null) {\r\n try {\r\n raf.close();\r\n if (raf != null) {\r\n try {\r\n raf.close();\r\n } catch (IOException e28) {\r\n e28.printStackTrace();\r\n return ERROR_FILE_NOT_FOUND;\r\n }\r\n }\r\n } catch (IOException e29) {\r\n e29.printStackTrace();\r\n if (raf != null) {\r\n try {\r\n raf.close();\r\n } catch (IOException e30) {\r\n e30.printStackTrace();\r\n return ERROR_FILE_NOT_FOUND;\r\n }\r\n }\r\n return ERROR_FILE_NOT_FOUND;\r\n } finally {\r\n if (raf != null) {\r\n try {\r\n raf.close();\r\n } catch (IOException e31) {\r\n e31.printStackTrace();\r\n return ERROR_FILE_NOT_FOUND;\r\n }\r\n }\r\n }\r\n }\r\n } catch (IOException e32) {\r\n e32.printStackTrace();\r\n if (raf != null) {\r\n try {\r\n raf.close();\r\n if (raf != null) {\r\n try {\r\n raf.close();\r\n } catch (IOException e33) {\r\n e33.printStackTrace();\r\n return ERROR_FILE_NOT_FOUND;\r\n }\r\n }\r\n } catch (IOException e34) {\r\n e34.printStackTrace();\r\n if (raf != null) {\r\n try {\r\n raf.close();\r\n } catch (IOException e35) {\r\n e35.printStackTrace();\r\n return ERROR_FILE_NOT_FOUND;\r\n }\r\n }\r\n return ERROR_FILE_NOT_FOUND;\r\n } finally {\r\n if (raf != null) {\r\n try {\r\n raf.close();\r\n } catch (IOException e36) {\r\n e36.printStackTrace();\r\n return ERROR_FILE_NOT_FOUND;\r\n }\r\n }\r\n }\r\n }\r\n return ERROR_FILE_NOT_FOUND;\r\n } finally {\r\n if (raf != null) {\r\n try {\r\n raf.close();\r\n if (raf != null) {\r\n try {\r\n raf.close();\r\n } catch (IOException e37) {\r\n e37.printStackTrace();\r\n return ERROR_FILE_NOT_FOUND;\r\n }\r\n }\r\n } catch (IOException e38) {\r\n e38.printStackTrace();\r\n if (raf != null) {\r\n try {\r\n raf.close();\r\n } catch (IOException e39) {\r\n e39.printStackTrace();\r\n return ERROR_FILE_NOT_FOUND;\r\n }\r\n }\r\n return ERROR_FILE_NOT_FOUND;\r\n } finally {\r\n if (raf != null) {\r\n try {\r\n raf.close();\r\n } catch (IOException e40) {\r\n e40.printStackTrace();\r\n return ERROR_FILE_NOT_FOUND;\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n throw th;\r\n }\r\n } catch (Exception e41) {\r\n e = e41;\r\n raf2 = raf;\r\n try {\r\n e.printStackTrace();\r\n fileUnzip = apkzf.getEntry(\"assets/\" + Libnameinapk);\r\n if (fileUnzip != null) {\r\n if (!isFileValid(new StringBuilder(String.valueOf(Appfiledir)).append(\"/\").append(libname).toString(), fileUnzip.getSize())) {\r\n UnzipFile(apkzf, \"assets/\" + Libnameinapk, new File(new StringBuilder(String.valueOf(Appfiledir)).append(\"/\").append(libname).toString()));\r\n }\r\n }\r\n fileUnzip2 = apkzf.getEntry(\"assets/\" + Libnameinapk);\r\n if (fileUnzip2 != null) {\r\n if (!isFileValid(new StringBuilder(String.valueOf(Appfiledir)).append(\"/\").append(securename6).toString(), fileUnzip2.getSize())) {\r\n UnzipFile(apkzf, \"assets/\" + securename6, new File(new StringBuilder(String.valueOf(Appfiledir)).append(\"/\").append(securename6).toString()));\r\n }\r\n }\r\n fileUnzip3 = apkzf.getEntry(\"assets/\" + Libnameinapk);\r\n if (fileUnzip3 != null) {\r\n if (!isFileValid(new StringBuilder(String.valueOf(Appfiledir)).append(\"/\").append(securename7).toString(), fileUnzip3.getSize())) {\r\n UnzipFile(apkzf, \"assets/\" + securename7, new File(new StringBuilder(String.valueOf(Appfiledir)).append(\"/\").append(securename7).toString()));\r\n }\r\n }\r\n ZipEntry fileUnzip16 = apkzf.getEntry(Cookiefileinzip);\r\n if (fileUnzip16 != null && !isFileValid(Cookiefilepath, fileUnzip16.getSize())) {\r\n File file35 = new File(Cookiefilepath);\r\n UnzipFile(apkzf, Cookiefileinzip, file35);\r\n }\r\n if (file_lock != null) {\r\n try {\r\n file_lock.release();\r\n if (raf != null) {\r\n try {\r\n raf.close();\r\n if (raf != null) {\r\n try {\r\n raf.close();\r\n } catch (IOException e42) {\r\n e42.printStackTrace();\r\n return ERROR_FILE_NOT_FOUND;\r\n }\r\n }\r\n } catch (IOException e43) {\r\n e43.printStackTrace();\r\n if (raf != null) {\r\n try {\r\n raf.close();\r\n } catch (IOException e44) {\r\n e44.printStackTrace();\r\n return ERROR_FILE_NOT_FOUND;\r\n }\r\n }\r\n return ERROR_FILE_NOT_FOUND;\r\n } finally {\r\n if (raf != null) {\r\n try {\r\n raf.close();\r\n } catch (IOException e45) {\r\n e45.printStackTrace();\r\n return ERROR_FILE_NOT_FOUND;\r\n }\r\n }\r\n }\r\n }\r\n } catch (IOException e46) {\r\n e46.printStackTrace();\r\n if (raf != null) {\r\n try {\r\n raf.close();\r\n if (raf != null) {\r\n try {\r\n raf.close();\r\n } catch (IOException e47) {\r\n e47.printStackTrace();\r\n return ERROR_FILE_NOT_FOUND;\r\n }\r\n }\r\n } catch (IOException e48) {\r\n e48.printStackTrace();\r\n if (raf != null) {\r\n try {\r\n raf.close();\r\n } catch (IOException e49) {\r\n e49.printStackTrace();\r\n return ERROR_FILE_NOT_FOUND;\r\n }\r\n }\r\n return ERROR_FILE_NOT_FOUND;\r\n } finally {\r\n if (raf != null) {\r\n try {\r\n raf.close();\r\n } catch (IOException e50) {\r\n e50.printStackTrace();\r\n return ERROR_FILE_NOT_FOUND;\r\n }\r\n }\r\n }\r\n }\r\n return ERROR_FILE_NOT_FOUND;\r\n } finally {\r\n if (raf != null) {\r\n try {\r\n raf.close();\r\n if (raf != null) {\r\n try {\r\n raf.close();\r\n } catch (IOException e51) {\r\n e51.printStackTrace();\r\n return ERROR_FILE_NOT_FOUND;\r\n }\r\n }\r\n } catch (IOException e52) {\r\n e52.printStackTrace();\r\n if (raf != null) {\r\n try {\r\n raf.close();\r\n } catch (IOException e53) {\r\n e53.printStackTrace();\r\n return ERROR_FILE_NOT_FOUND;\r\n }\r\n }\r\n return ERROR_FILE_NOT_FOUND;\r\n } finally {\r\n if (raf != null) {\r\n try {\r\n raf.close();\r\n } catch (IOException e54) {\r\n e54.printStackTrace();\r\n return ERROR_FILE_NOT_FOUND;\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n return ERROR_FILE_NOT_FOUND;\r\n } catch (Throwable th2) {\r\n th = th2;\r\n ZipEntry fileUnzip122 = apkzf.getEntry(\"assets/\" + Libnameinapk);\r\n UnzipFile(apkzf, \"assets/\" + Libnameinapk, new File(new StringBuilder(String.valueOf(Appfiledir)).append(\"/\").append(libname).toString()));\r\n ZipEntry fileUnzip132 = apkzf.getEntry(\"assets/\" + Libnameinapk);\r\n UnzipFile(apkzf, \"assets/\" + securename6, new File(new StringBuilder(String.valueOf(Appfiledir)).append(\"/\").append(securename6).toString()));\r\n ZipEntry fileUnzip142 = apkzf.getEntry(\"assets/\" + Libnameinapk);\r\n UnzipFile(apkzf, \"assets/\" + securename7, new File(new StringBuilder(String.valueOf(Appfiledir)).append(\"/\").append(securename7).toString()));\r\n ZipEntry fileUnzip152 = apkzf.getEntry(Cookiefileinzip);\r\n File file342 = new File(Cookiefilepath);\r\n UnzipFile(apkzf, Cookiefileinzip, file342);\r\n if (file_lock != null) {\r\n }\r\n throw th;\r\n }\r\n } catch (Throwable th3) {\r\n th = th3;\r\n raf2 = raf;\r\n ZipEntry fileUnzip1222 = apkzf.getEntry(\"assets/\" + Libnameinapk);\r\n UnzipFile(apkzf, \"assets/\" + Libnameinapk, new File(new StringBuilder(String.valueOf(Appfiledir)).append(\"/\").append(libname).toString()));\r\n ZipEntry fileUnzip1322 = apkzf.getEntry(\"assets/\" + Libnameinapk);\r\n UnzipFile(apkzf, \"assets/\" + securename6, new File(new StringBuilder(String.valueOf(Appfiledir)).append(\"/\").append(securename6).toString()));\r\n ZipEntry fileUnzip1422 = apkzf.getEntry(\"assets/\" + Libnameinapk);\r\n UnzipFile(apkzf, \"assets/\" + securename7, new File(new StringBuilder(String.valueOf(Appfiledir)).append(\"/\").append(securename7).toString()));\r\n ZipEntry fileUnzip1522 = apkzf.getEntry(Cookiefileinzip);\r\n File file3422 = new File(Cookiefilepath);\r\n UnzipFile(apkzf, Cookiefileinzip, file3422);\r\n if (file_lock != null) {\r\n }\r\n throw th;\r\n }\r\n } catch (Exception e55) {\r\n e = e55;\r\n e.printStackTrace();\r\n fileUnzip = apkzf.getEntry(\"assets/\" + Libnameinapk);\r\n if (fileUnzip != null) {\r\n }\r\n fileUnzip2 = apkzf.getEntry(\"assets/\" + Libnameinapk);\r\n if (fileUnzip2 != null) {\r\n }\r\n fileUnzip3 = apkzf.getEntry(\"assets/\" + Libnameinapk);\r\n if (fileUnzip3 != null) {\r\n }\r\n ZipEntry fileUnzip162 = apkzf.getEntry(Cookiefileinzip);\r\n File file352 = new File(Cookiefilepath);\r\n UnzipFile(apkzf, Cookiefileinzip, file352);\r\n if (file_lock != null) {\r\n }\r\n return ERROR_FILE_NOT_FOUND;\r\n }\r\n }",
"public void doPack() {\n if (this._sendData == null) {\n this._sendData = new byte[13];\n }\n this._sendData[0] = 0;\n if (this.isMenu) {\n byte[] bArr = this._sendData;\n bArr[0] = (byte) (bArr[0] | 1);\n }\n if (this.isPlayback) {\n byte[] bArr2 = this._sendData;\n bArr2[0] = (byte) (bArr2[0] | 2);\n }\n if (this.isRecord) {\n byte[] bArr3 = this._sendData;\n bArr3[0] = (byte) (bArr3[0] | 4);\n }\n BytesUtil.arraycopy(generateChannelByte(), this._sendData, 1);\n this._sendData[11] = 0;\n if (this.isButton) {\n byte[] bArr4 = this._sendData;\n bArr4[11] = (byte) (bArr4[11] | 1);\n }\n byte[] bArr5 = this._sendData;\n bArr5[11] = (byte) (bArr5[11] | (this.buttonData << 1));\n byte[] bArr6 = this._sendData;\n bArr6[11] = (byte) (bArr6[11] | (this.symbol << 6));\n byte[] bArr7 = this._sendData;\n bArr7[11] = (byte) (bArr7[11] | (this.change << 7));\n byte[] bArr8 = this._sendData;\n bArr8[12] = (byte) (bArr8[12] | this.shutter);\n byte[] bArr9 = this._sendData;\n bArr9[12] = (byte) (bArr9[12] | (this.focus << 1));\n byte[] bArr10 = this._sendData;\n bArr10[12] = (byte) (bArr10[12] | (this.mode_sw << 2));\n byte[] bArr11 = this._sendData;\n bArr11[12] = (byte) (bArr11[12] | (this.transform_sw << 4));\n byte[] bArr12 = this._sendData;\n bArr12[12] = (byte) (bArr12[12] | (this.gohome << 6));\n }",
"public final void zza(zzxa zzxa) {\n String zzbk = zzbk(this.zzbtk.zzbsb);\n try {\n if (this.zzyf.zzcvf >= 4100000) {\n if (!this.zzael) {\n if (!this.zzbtk.zzmg()) {\n if (this.zzaau.zzarc) {\n this.zzbtp.zza(ObjectWrapper.wrap(this.mContext), this.zzaao, zzbk, this.zzbtk.zzbrr, (zzxt) zzxa);\n return;\n } else if (!this.zzbtn) {\n this.zzbtp.zza(ObjectWrapper.wrap(this.mContext), this.zzaau, this.zzaao, zzbk, this.zzbtk.zzbrr, zzxa);\n return;\n } else if (this.zzbtk.zzbsf != null) {\n this.zzbtp.zza(ObjectWrapper.wrap(this.mContext), this.zzaao, zzbk, this.zzbtk.zzbrr, zzxa, new zzpl(zzbl(this.zzbtk.zzbsj)), this.zzbtk.zzbsi);\n return;\n } else {\n this.zzbtp.zza(ObjectWrapper.wrap(this.mContext), this.zzaau, this.zzaao, zzbk, this.zzbtk.zzbrr, zzxa);\n return;\n }\n }\n }\n ArrayList arrayList = new ArrayList(this.zzyc);\n if (this.zzbtl != null) {\n for (String next : this.zzbtl) {\n String str = \":false\";\n if (this.zzbtm != null && this.zzbtm.contains(next)) {\n str = \":true\";\n }\n StringBuilder sb = new StringBuilder(String.valueOf(next).length() + 7 + str.length());\n sb.append(\"custom:\");\n sb.append(next);\n sb.append(str);\n arrayList.add(sb.toString());\n }\n }\n this.zzbtp.zza(ObjectWrapper.wrap(this.mContext), this.zzaao, zzbk, this.zzbtk.zzbrr, zzxa, this.zzyb, arrayList);\n } else if (this.zzaau.zzarc) {\n this.zzbtp.zza(ObjectWrapper.wrap(this.mContext), this.zzaao, zzbk, zzxa);\n } else {\n this.zzbtp.zza(ObjectWrapper.wrap(this.mContext), this.zzaau, this.zzaao, zzbk, (zzxt) zzxa);\n }\n } catch (RemoteException e) {\n zzakb.zzc(\"Could not request ad from mediation adapter.\", e);\n zzx(5);\n }\n }",
"PipelineJob importXarAsync(ViewBackgroundInfo info, File file, String description, PipeRoot root) throws IOException;",
"public interface IZipStrategy {\n\n void zip();\n}",
"@Test\n public void testDecompressWithoutPrefix() throws Exception {\n\n Path outputDir =\n new CompressedTarFunction() {\n @Override\n protected InputStream getDecompressorStream(DecompressorDescriptor descriptor)\n throws IOException {\n return new GZIPInputStream(new FileInputStream(descriptor.archivePath().getPathFile()));\n }\n }.decompress(descriptorBuilder.build());\n\n assertOutputFiles(outputDir.getRelative(ROOT_FOLDER_NAME).getRelative(INNER_FOLDER_NAME));\n }",
"private ReoFile<T> findComponent(String component) throws IOException {\n\t\t\n\t\tReoFile<T> prog = null;\n\t\t\n\t\tint k = component.lastIndexOf('.') + 1;\n\t\tString name = component.substring(k);\n\t\tString directory = component.substring(0, k).replace('.', File.separatorChar);\n\t\tString cp1 = directory + name + \".\" + semantics + \".treo\";\n\t\tString cp2 = directory + name + \".treo\";\n\t\n\tsearch:\n\t\tfor (String dir : dirs) {\n\t\t\t\n\t\t\t// Check if this directory contains a .zip file.\n\t\t\tFile folder = new File(dir);\n\t\t\tif (folder.exists() && folder.isDirectory()) {\n\t\t\t\t\n\t\t\t\t\n\t\t\t\tFilenameFilter archiveFilter = new FilenameFilter() {\n\t\t\t\t\tpublic boolean accept(File dir, String name) {\n\t\t\t\t\t\treturn name.toLowerCase().endsWith(\".zip\");\n\t\t\t\t\t}\n\t\t\t\t};\t\n\t\t\t\t\n\t\t\t\tFile[] files = folder.listFiles(archiveFilter);\n\t\t\t\tfor (File file : files) {\t\t\t\n\t\t\t\t\tif (!file.isDirectory()) {\n\t\t\t\t\t ZipFile zipFile = null;\n\t\t\t\t\t\ttry {\n\t\t\t\t\t\t zipFile = new ZipFile(file.getPath());\n\t\t\t\t\t\t ZipEntry entry1 = zipFile.getEntry(cp1);\n\t\t\t\t\t\t ZipEntry entry2 = zipFile.getEntry(cp2);\n\t\t\t\t\t\t if (entry1 != null) {\n\t\t\t\t\t\t \tInputStream input = zipFile.getInputStream(entry1);\n\t\t\t\t\t\t \tprog = parse(new ANTLRInputStream(input));\n\t\t\t\t\t\t\t\tbreak search;\n\t\t\t\t\t\t } else if (entry2 != null) {\n\t\t\t\t\t\t \tInputStream input = zipFile.getInputStream(entry2);\n\t\t\t\t\t\t \tprog = parse(new ANTLRInputStream(input));\n\t\t\t\t\t\t\t\tbreak search;\n\t\t\t\t\t\t }\n\t\t\t\t\t\t} finally {\n\t\t\t\t\t\t\ttry { if (zipFile != null) zipFile.close(); } catch(IOException e) { }\n\t\t\t\t\t\t}\n\t\t\t\t\t} \n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\tFile f1 = new File(dir + File.separator + cp1);\n\t\t\tif (f1.exists() && !f1.isDirectory()) {\n\t\t\t\tprog = parse(new ANTLRFileStream(dir + File.separator + cp1));\n\t\t\t\tbreak search;\n\t\t\t}\n\n\t\t\tFile f2 = new File(dir + File.separator + cp2);\n\t\t\tif (f2.exists() && !f2.isDirectory()) {\n\t\t\t\tprog = parse(new ANTLRFileStream(dir + File.separator + cp2));\n\t\t\t\tbreak search;\n\t\t\t}\n\t\t}\n\t\t\n\t\treturn prog;\n\t}",
"public final void zza(T r25, byte[] r26, int r27, int r28, com.google.android.gms.internal.clearcut.zzay r29) throws java.io.IOException {\n /*\n r24 = this;\n r15 = r24;\n r14 = r25;\n r12 = r26;\n r13 = r28;\n r11 = r29;\n r0 = r15.zzmq;\n if (r0 == 0) goto L_0x01e1;\n L_0x000e:\n r9 = zzmh;\n r0 = r27;\n L_0x0012:\n if (r0 >= r13) goto L_0x01d8;\n L_0x0014:\n r1 = r0 + 1;\n r0 = r12[r0];\n if (r0 >= 0) goto L_0x0024;\n L_0x001a:\n r0 = com.google.android.gms.internal.clearcut.zzax.zza(r0, r12, r1, r11);\n r1 = r11.zzfd;\n r10 = r0;\n r16 = r1;\n goto L_0x0027;\n L_0x0024:\n r16 = r0;\n r10 = r1;\n L_0x0027:\n r6 = r16 >>> 3;\n r7 = r16 & 7;\n r8 = r15.zzai(r6);\n if (r8 < 0) goto L_0x01b8;\n L_0x0031:\n r0 = r15.zzmi;\n r1 = r8 + 1;\n r5 = r0[r1];\n r0 = 267386880; // 0xff00000 float:2.3665827E-29 double:1.321066716E-315;\n r0 = r0 & r5;\n r4 = r0 >>> 20;\n r0 = 1048575; // 0xfffff float:1.469367E-39 double:5.18065E-318;\n r0 = r0 & r5;\n r2 = (long) r0;\n r0 = 17;\n r1 = 2;\n if (r4 > r0) goto L_0x0106;\n L_0x0046:\n r0 = 5;\n r6 = 1;\n switch(r4) {\n case 0: goto L_0x00f9;\n case 1: goto L_0x00ec;\n case 2: goto L_0x00db;\n case 3: goto L_0x00db;\n case 4: goto L_0x00ce;\n case 5: goto L_0x00c1;\n case 6: goto L_0x00b7;\n case 7: goto L_0x00a2;\n case 8: goto L_0x0091;\n case 9: goto L_0x0079;\n case 10: goto L_0x006d;\n case 11: goto L_0x00ce;\n case 12: goto L_0x0069;\n case 13: goto L_0x00b7;\n case 14: goto L_0x00c1;\n case 15: goto L_0x005b;\n case 16: goto L_0x004d;\n default: goto L_0x004b;\n };\n L_0x004b:\n goto L_0x01b8;\n L_0x004d:\n if (r7 != 0) goto L_0x01b8;\n L_0x004f:\n r6 = com.google.android.gms.internal.clearcut.zzax.zzb(r12, r10, r11);\n r0 = r11.zzfe;\n r4 = com.google.android.gms.internal.clearcut.zzbk.zza(r0);\n goto L_0x00e3;\n L_0x005b:\n if (r7 != 0) goto L_0x01b8;\n L_0x005d:\n r0 = com.google.android.gms.internal.clearcut.zzax.zza(r12, r10, r11);\n r1 = r11.zzfd;\n r1 = com.google.android.gms.internal.clearcut.zzbk.zzm(r1);\n goto L_0x00d6;\n L_0x0069:\n if (r7 != 0) goto L_0x01b8;\n L_0x006b:\n goto L_0x00d0;\n L_0x006d:\n if (r7 != r1) goto L_0x01b8;\n L_0x006f:\n r0 = com.google.android.gms.internal.clearcut.zzax.zze(r12, r10, r11);\n L_0x0073:\n r1 = r11.zzff;\n L_0x0075:\n r9.putObject(r14, r2, r1);\n goto L_0x0012;\n L_0x0079:\n if (r7 != r1) goto L_0x01b8;\n L_0x007b:\n r0 = r15.zzad(r8);\n r0 = zza(r0, r12, r10, r13, r11);\n r1 = r9.getObject(r14, r2);\n if (r1 != 0) goto L_0x008a;\n L_0x0089:\n goto L_0x0073;\n L_0x008a:\n r4 = r11.zzff;\n r1 = com.google.android.gms.internal.clearcut.zzci.zza(r1, r4);\n goto L_0x0075;\n L_0x0091:\n if (r7 != r1) goto L_0x01b8;\n L_0x0093:\n r0 = 536870912; // 0x20000000 float:1.0842022E-19 double:2.652494739E-315;\n r0 = r0 & r5;\n if (r0 != 0) goto L_0x009d;\n L_0x0098:\n r0 = com.google.android.gms.internal.clearcut.zzax.zzc(r12, r10, r11);\n goto L_0x0073;\n L_0x009d:\n r0 = com.google.android.gms.internal.clearcut.zzax.zzd(r12, r10, r11);\n goto L_0x0073;\n L_0x00a2:\n if (r7 != 0) goto L_0x01b8;\n L_0x00a4:\n r0 = com.google.android.gms.internal.clearcut.zzax.zzb(r12, r10, r11);\n r4 = r11.zzfe;\n r7 = 0;\n r1 = (r4 > r7 ? 1 : (r4 == r7 ? 0 : -1));\n if (r1 == 0) goto L_0x00b1;\n L_0x00b0:\n goto L_0x00b2;\n L_0x00b1:\n r6 = 0;\n L_0x00b2:\n com.google.android.gms.internal.clearcut.zzfd.zza(r14, r2, r6);\n goto L_0x0012;\n L_0x00b7:\n if (r7 != r0) goto L_0x01b8;\n L_0x00b9:\n r0 = com.google.android.gms.internal.clearcut.zzax.zzc(r12, r10);\n r9.putInt(r14, r2, r0);\n goto L_0x00f5;\n L_0x00c1:\n if (r7 != r6) goto L_0x01b8;\n L_0x00c3:\n r4 = com.google.android.gms.internal.clearcut.zzax.zzd(r12, r10);\n r0 = r9;\n r1 = r25;\n r0.putLong(r1, r2, r4);\n goto L_0x0102;\n L_0x00ce:\n if (r7 != 0) goto L_0x01b8;\n L_0x00d0:\n r0 = com.google.android.gms.internal.clearcut.zzax.zza(r12, r10, r11);\n r1 = r11.zzfd;\n L_0x00d6:\n r9.putInt(r14, r2, r1);\n goto L_0x0012;\n L_0x00db:\n if (r7 != 0) goto L_0x01b8;\n L_0x00dd:\n r6 = com.google.android.gms.internal.clearcut.zzax.zzb(r12, r10, r11);\n r4 = r11.zzfe;\n L_0x00e3:\n r0 = r9;\n r1 = r25;\n r0.putLong(r1, r2, r4);\n r0 = r6;\n goto L_0x0012;\n L_0x00ec:\n if (r7 != r0) goto L_0x01b8;\n L_0x00ee:\n r0 = com.google.android.gms.internal.clearcut.zzax.zzf(r12, r10);\n com.google.android.gms.internal.clearcut.zzfd.zza(r14, r2, r0);\n L_0x00f5:\n r0 = r10 + 4;\n goto L_0x0012;\n L_0x00f9:\n if (r7 != r6) goto L_0x01b8;\n L_0x00fb:\n r0 = com.google.android.gms.internal.clearcut.zzax.zze(r12, r10);\n com.google.android.gms.internal.clearcut.zzfd.zza(r14, r2, r0);\n L_0x0102:\n r0 = r10 + 8;\n goto L_0x0012;\n L_0x0106:\n r0 = 27;\n if (r4 != r0) goto L_0x013e;\n L_0x010a:\n if (r7 != r1) goto L_0x01b8;\n L_0x010c:\n r0 = r9.getObject(r14, r2);\n r0 = (com.google.android.gms.internal.clearcut.zzcn) r0;\n r1 = r0.zzu();\n if (r1 != 0) goto L_0x012a;\n L_0x0118:\n r1 = r0.size();\n if (r1 != 0) goto L_0x0121;\n L_0x011e:\n r1 = 10;\n goto L_0x0123;\n L_0x0121:\n r1 = r1 << 1;\n L_0x0123:\n r0 = r0.zzi(r1);\n r9.putObject(r14, r2, r0);\n L_0x012a:\n r5 = r0;\n r0 = r15.zzad(r8);\n r1 = r16;\n r2 = r26;\n r3 = r10;\n r4 = r28;\n r6 = r29;\n r0 = zza(r0, r1, r2, r3, r4, r5, r6);\n goto L_0x0012;\n L_0x013e:\n r0 = 49;\n if (r4 > r0) goto L_0x0177;\n L_0x0142:\n r0 = (long) r5;\n r17 = r0;\n r0 = r24;\n r1 = r25;\n r19 = r2;\n r2 = r26;\n r3 = r10;\n r5 = r4;\n r4 = r28;\n r21 = r5;\n r5 = r16;\n r22 = r9;\n r15 = r10;\n r9 = r17;\n r11 = r21;\n r12 = r19;\n r14 = r29;\n r0 = r0.zza(r1, r2, r3, r4, r5, r6, r7, r8, r9, r11, r12, r14);\n if (r0 != r15) goto L_0x0169;\n L_0x0166:\n r2 = r0;\n goto L_0x01bc;\n L_0x0169:\n r14 = r25;\n r12 = r26;\n r13 = r28;\n r11 = r29;\n r9 = r22;\n r15 = r24;\n goto L_0x0012;\n L_0x0177:\n r19 = r2;\n r21 = r4;\n r22 = r9;\n r15 = r10;\n r0 = 50;\n r9 = r21;\n if (r9 != r0) goto L_0x019e;\n L_0x0184:\n if (r7 != r1) goto L_0x019c;\n L_0x0186:\n r14 = r15;\n r0 = r24;\n r1 = r25;\n r2 = r26;\n r3 = r14;\n r4 = r28;\n r5 = r8;\n r7 = r19;\n r9 = r29;\n r0 = r0.zza(r1, r2, r3, r4, r5, r6, r7, r9);\n if (r0 != r14) goto L_0x01ca;\n L_0x019b:\n goto L_0x0166;\n L_0x019c:\n r14 = r15;\n goto L_0x01bb;\n L_0x019e:\n r14 = r15;\n r0 = r24;\n r1 = r25;\n r2 = r26;\n r3 = r14;\n r4 = r28;\n r10 = r5;\n r5 = r16;\n r12 = r8;\n r8 = r10;\n r10 = r19;\n r13 = r29;\n r0 = r0.zza(r1, r2, r3, r4, r5, r6, r7, r8, r9, r10, r12, r13);\n if (r0 != r14) goto L_0x01ca;\n L_0x01b7:\n goto L_0x0166;\n L_0x01b8:\n r22 = r9;\n r14 = r10;\n L_0x01bb:\n r2 = r14;\n L_0x01bc:\n r0 = r16;\n r1 = r26;\n r3 = r28;\n r4 = r25;\n r5 = r29;\n r0 = zza(r0, r1, r2, r3, r4, r5);\n L_0x01ca:\n r15 = r24;\n r14 = r25;\n r12 = r26;\n r13 = r28;\n r11 = r29;\n r9 = r22;\n goto L_0x0012;\n L_0x01d8:\n r4 = r13;\n if (r0 != r4) goto L_0x01dc;\n L_0x01db:\n return;\n L_0x01dc:\n r0 = com.google.android.gms.internal.clearcut.zzco.zzbo();\n throw r0;\n L_0x01e1:\n r4 = r13;\n r5 = 0;\n r0 = r24;\n r1 = r25;\n r2 = r26;\n r3 = r27;\n r4 = r28;\n r6 = r29;\n r0.zza(r1, r2, r3, r4, r5, r6);\n return;\n */\n throw new UnsupportedOperationException(\"Method not decompiled: com.google.android.gms.internal.clearcut.zzds.zza(java.lang.Object, byte[], int, int, com.google.android.gms.internal.clearcut.zzay):void\");\n }",
"public void unZip(String apkFile) throws Exception \r\n\t{\r\n\t\tLog.p(tag, apkFile);\r\n\t\tFile file = new File(apkFile);\r\n\t\r\n\t\t/*\r\n\t\t * Create the Base Directory, whose name should be same as Zip file name.\r\n\t\t * All decompressed contents will be placed under this folder.\r\n\t\t */\r\n\t\tString apkFileName = file.getName();\r\n\t\t\r\n\t\tif(apkFileName.indexOf('.') != -1)\r\n\t\t\tapkFileName = apkFileName.substring(0, apkFileName.indexOf('.'));\r\n\t\t\r\n\t\tLog.d(tag, \"Folder name: \"+ apkFileName);\r\n\t\t\r\n\t\tFile extractFolder = new File((file.getParent() == null ? \"\" : file.getParent() + File.separator) + apkFileName);\r\n\t\tif(!extractFolder.exists())\r\n\t\t\textractFolder.mkdir();\r\n\t\t\r\n\t\t/*\r\n\t\t * Read zip entries.\r\n\t\t */\r\n\t\tFileInputStream fin = new FileInputStream(apkFile);\r\n\t\tZipInputStream zin = new ZipInputStream(new BufferedInputStream(fin));\r\n\t\t\r\n\t\t/*\r\n\t\t * Zip InputStream shifts its index to every Zip entry when getNextEntry() is called.\r\n\t\t * If this method returns null, Zip InputStream reaches EOF.\r\n\t\t */\r\n\t\tZipEntry ze = null;\r\n\t\tBufferedOutputStream dest;\r\n\t\t\r\n\t\twhile((ze = zin.getNextEntry()) != null)\r\n\t\t{\r\n\t\t\tLog.d(tag, \"Zip entry: \" + ze.getName() + \" Size: \"+ ze.getSize());\r\n\t\t\t/*\r\n\t\t\t * Create decompressed file for each Zip entry. A Zip entry can be a file or directory.\r\n\t\t\t * ASSUMPTION: APK Zip entry uses Unix style File seperator- \"/\"\r\n\t\t\t * \r\n\t\t\t * 1. Create the prefix Zip Entry folder, if it is not yet available\r\n\t\t\t * 2. Create the individual Zip Entry file.\r\n\t\t\t */\r\n\t\t\tString zeName = ze.getName();\r\n\t\t\tString zeFolder = zeName;\r\n\t\t\t\r\n\t\t\tif(ze.isDirectory())\r\n\t\t\t{\r\n\t\t\t\tzeName = null; // Don't create Zip Entry file\r\n\t\t\t}\r\n\t\t\telse{\r\n\t\t\t\tif(zeName.indexOf(\"/\") == -1) // Zip entry uses \"/\"\r\n\t\t\t\t\tzeFolder = null; // It is File. don't create Zip entry Folder\r\n\t\t\t\telse {\r\n\t\t\t\t\tzeFolder = zeName.substring(0, zeName.lastIndexOf(\"/\"));\r\n\t\t\t\t\tzeName = zeName.substring( zeName.lastIndexOf(\"/\") + 1);\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\tLog.d(tag, \"zeFolder: \"+ zeFolder +\" zeName: \"+ zeName);\r\n\t\t\t\r\n\t\t\t// Create Zip Entry Folder\r\n\t\t\tFile zeFile = extractFolder;\r\n\t\t\tif(zeFolder != null)\r\n\t\t\t{\r\n\t\t\t\tzeFile = new File(extractFolder.getPath() + File.separator + zeFolder);\r\n\t\t\t\tif(!zeFile.exists())\r\n\t\t\t\t\tzeFile.mkdirs();\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t// Create Zip Entry File\r\n\t\t\tif(zeName == null)\r\n\t\t\t\tcontinue;\r\n\t\t\t\r\n\t\t\t// Keep track of XML files, they are in Android Binary XML format\r\n\t\t\tif(zeName.endsWith(\".xml\"))\r\n\t\t\t\txmlFiles.add(zeFile.getPath() + File.separator + zeName);\r\n\t\t\t\r\n\t\t\t// Keep track of the Dex/ODex file. Need to convert to Jar\r\n\t\t\tif(zeName.endsWith(\".dex\") || zeName.endsWith(\".odex\"))\r\n\t\t\t\tdexFile = zeFile.getPath() + File.separator + zeName;\r\n\t\t\t\r\n\t\t\t// Keep track of Resources.arsc file- resources.arsc\r\n\t\t\tif(zeName.endsWith(\".arsc\"))\r\n\t\t\t\tresFile = zeFile.getPath() + File.separator + zeName;\r\n\t\t\t\r\n\t\t\t// Write Zip entry File to the disk\r\n\t\t\tint count;\r\n\t\t\tbyte data[] = new byte[BUFFER];\r\n\t\t\t\r\n\t\t\tFileOutputStream fos = new FileOutputStream(zeFile.getPath() + File.separator + zeName);\r\n\t\t\tdest = new BufferedOutputStream(fos, BUFFER);\r\n\r\n\t\t\twhile ((count = zin.read(data, 0, BUFFER)) != -1) \r\n\t\t\t{\r\n\t\t\t\tdest.write(data, 0, count);\r\n\t\t\t}\r\n\t\t\tdest.flush();\r\n\t\t\tdest.close();\r\n\t\t}\r\n\r\n\t\t// Close Zip InputStream\r\n\t\tzin.close();\r\n\t\tfin.close();\r\n\t}",
"private static List<PackageDTO> preparePackages(String filePath) throws APIException{\n List<PackageDTO> packageDTOS = null;\n try {\n File input = fileService.openFile(filePath);\n packageDTOS = parseService.parseFile(input);\n }catch (APIException e) {\n throw new APIException(\"File not found\", e);\n }\n return packageDTOS;\n }",
"public static void execEnkripsiBulk(List<File> lsFileTemp, String pathZippedFile, String pathTempFileEncryptName, String pathEncryptedSecretKeyFile, SimpleDateFormat sdf, String pemContent) throws Exception{\r\n /*Step 2 : kompresi file*/\r\n// System.out.println(\"Step 2 : kompresi file\");\r\n\r\n //Generate Secret Key untuk setiap file yang dienkripsi\r\n /**\r\n * Kunci acak 16 Digit, dan setiap pengekripsian harus beda\r\n * contoh : A1b2C3D4E5F6G7h8\r\n * */\r\n String secretKey=RandomStringUtils.randomAlphanumeric(16);\r\n System.out.println(\"Generated Secret Key :\"+secretKey);\r\n\r\n File exportedFile;\r\n CompressingUtils compressingUtils = new CompressingUtils();\r\n String outputTmpFileNameZip = pathZippedFile.replace(\".\",\"\")+\"Tmp.zip\";\r\n String outputFileNameZip = pathZippedFile.replace(\".\",\"\")+sdf.format(new Date())+\".zip\";\r\n\r\n compressingUtils = new CompressingUtils();\r\n if(compressingUtils.createZipWithoutPassword(lsFileTemp, outputTmpFileNameZip)){\r\n exportedFile = new File(outputTmpFileNameZip);\r\n }else{\r\n throw new Exception(\"gagal melakukan kompresi file tanpa password\");\r\n }\r\n\r\n\r\n //delete file hasil enkripsi per file yang telah dimasukan ke dalam file kompresi untuk enkripsi tahap gabungan file\r\n for(File file : lsFileTemp){\r\n file.delete();\r\n }\r\n\r\n System.out.println(\"file kompresi berhasil dibuat \"+ outputFileNameZip);\r\n\r\n /*Step 3 : enkripsi file dengan kunci acak */\r\n System.out.println(\"Step 3 : enkripsi file dengan kunci acak\");\r\n\r\n\r\n String fileOutputEcnryptedname = outputFileNameZip;\r\n\r\n File tempFileEncryptName = new File(pathTempFileEncryptName);\r\n try {\r\n CryptoUtils.encrypt(secretKey, exportedFile, tempFileEncryptName);\r\n } catch (CryptoException e) {\r\n throw new Exception(\"Enkripsi file gagal : \" + e.getMessage());\r\n }\r\n\r\n\r\n EncryptionUtils utils = new EncryptionUtils();\r\n PublicKey publicKey = utils.getPublicKeyFromX509(pemContent);\r\n\r\n /*Step 4 : Enkripsi kunci acak dengan public key dari DJP*/\r\n System.out.println(\"Step 4 : enkripsi kunci acak dengan public key dari DJP\");\r\n\r\n String encryptedSecretKey;\r\n try{\r\n encryptedSecretKey = CryptoUtils.encrypt(secretKey, publicKey);\r\n }catch (CryptoException e) {\r\n throw new Exception(\"Enkripsi kunci gagal : \" + e.getMessage());\r\n }\r\n File encryptedSecretKeyFile = new File(pathEncryptedSecretKeyFile);\r\n try {\r\n FileOutputStream outputStream = new FileOutputStream(encryptedSecretKeyFile);\r\n outputStream.write(encryptedSecretKey.getBytes());\r\n outputStream.close();\r\n }catch (FileNotFoundException e){\r\n throw new Exception(\"kunci yang dienkripsi tidak ditemukan : \" + pathEncryptedSecretKeyFile);\r\n } catch (IOException e) {\r\n throw new Exception(\"gagal membentuk kunci enkripsi\");\r\n }\r\n\r\n /*Step 5: Compress data dan key kedalam file zip dan menjadi hasil akhir*/\r\n System.out.println(\"Step 5: Compress enkripsi file dan kunci kedalam file zip\");\r\n\r\n List<File> listFiles = new ArrayList<File>();\r\n listFiles.add(tempFileEncryptName);\r\n listFiles.add(encryptedSecretKeyFile);\r\n\r\n if(listFiles.size() != 2){\r\n for (File file : listFiles) {\r\n file.delete();\r\n }\r\n throw new Exception(\"file enkripsi dan/atau key enkripsi salah satunya tidak ada\");\r\n }\r\n\r\n compressingUtils = new CompressingUtils();\r\n if (compressingUtils.createZip(listFiles, fileOutputEcnryptedname)) {\r\n /*Step 6 : hapus file data dan key, hasil dari step 3 dan 4 */\r\n System.out.println(\"Step 6 : hapus file data dan key, hasil dari step 3 dan 4\");\r\n\r\n for (File file : listFiles) {\r\n file.delete();\r\n }\r\n /*Step 7: hapus file zip, hasil dari step 2 */\r\n System.out.println(\"Step 7: hapus file zip, hasil dari step 2\");\r\n\r\n exportedFile.delete();\r\n }\r\n\r\n System.out.println(\"Proses enkripsi selesai, nama file : \" + fileOutputEcnryptedname);\r\n }",
"private final <K, V> int zza(T r7, byte[] r8, int r9, int r10, int r11, int r12, long r13, com.google.android.gms.internal.clearcut.zzay r15) throws java.io.IOException {\n /*\n r6 = this;\n r12 = zzmh;\n r11 = r6.zzae(r11);\n r0 = r12.getObject(r7, r13);\n r1 = r6.zzmz;\n r1 = r1.zzi(r0);\n if (r1 == 0) goto L_0x0021;\n L_0x0012:\n r1 = r6.zzmz;\n r1 = r1.zzk(r11);\n r2 = r6.zzmz;\n r2.zzb(r1, r0);\n r12.putObject(r7, r13, r1);\n r0 = r1;\n L_0x0021:\n r7 = r6.zzmz;\n r7 = r7.zzl(r11);\n r11 = r6.zzmz;\n r11 = r11.zzg(r0);\n r9 = com.google.android.gms.internal.clearcut.zzax.zza(r8, r9, r15);\n r12 = r15.zzfd;\n if (r12 < 0) goto L_0x0094;\n L_0x0035:\n r13 = r10 - r9;\n if (r12 > r13) goto L_0x0094;\n L_0x0039:\n r12 = r12 + r9;\n r13 = r7.zzmc;\n r14 = r7.zzdu;\n L_0x003e:\n if (r9 >= r12) goto L_0x0089;\n L_0x0040:\n r0 = r9 + 1;\n r9 = r8[r9];\n if (r9 >= 0) goto L_0x004c;\n L_0x0046:\n r0 = com.google.android.gms.internal.clearcut.zzax.zza(r9, r8, r0, r15);\n r9 = r15.zzfd;\n L_0x004c:\n r1 = r0;\n r0 = r9 >>> 3;\n r2 = r9 & 7;\n switch(r0) {\n case 1: goto L_0x006f;\n case 2: goto L_0x0055;\n default: goto L_0x0054;\n };\n L_0x0054:\n goto L_0x0084;\n L_0x0055:\n r0 = r7.zzmd;\n r0 = r0.zzel();\n if (r2 != r0) goto L_0x0084;\n L_0x005d:\n r3 = r7.zzmd;\n r9 = r7.zzdu;\n r4 = r9.getClass();\n r0 = r8;\n r2 = r10;\n r5 = r15;\n r9 = zza(r0, r1, r2, r3, r4, r5);\n r14 = r15.zzff;\n goto L_0x003e;\n L_0x006f:\n r0 = r7.zzmb;\n r0 = r0.zzel();\n if (r2 != r0) goto L_0x0084;\n L_0x0077:\n r3 = r7.zzmb;\n r4 = 0;\n r0 = r8;\n r2 = r10;\n r5 = r15;\n r9 = zza(r0, r1, r2, r3, r4, r5);\n r13 = r15.zzff;\n goto L_0x003e;\n L_0x0084:\n r9 = com.google.android.gms.internal.clearcut.zzax.zza(r9, r8, r1, r10, r15);\n goto L_0x003e;\n L_0x0089:\n if (r9 != r12) goto L_0x008f;\n L_0x008b:\n r11.put(r13, r14);\n return r12;\n L_0x008f:\n r7 = com.google.android.gms.internal.clearcut.zzco.zzbo();\n throw r7;\n L_0x0094:\n r7 = com.google.android.gms.internal.clearcut.zzco.zzbl();\n throw r7;\n */\n throw new UnsupportedOperationException(\"Method not decompiled: com.google.android.gms.internal.clearcut.zzds.zza(java.lang.Object, byte[], int, int, int, int, long, com.google.android.gms.internal.clearcut.zzay):int\");\n }",
"public static void zipFiles(List<String> srcFiles, String directoryPath) throws FileNotFoundException, IOException {\n DateTimeFormatter dtf = DateTimeFormatter.ofPattern(\"dd-MM-yyyy-HHmmss\");\r\n LocalDateTime now = LocalDateTime.now();\r\n String d = dtf.format(now);\r\n FileOutputStream fos = new FileOutputStream(directoryPath + \"\\\\\" + \"backupRexs\" + d + \".zip\");\r\n ZipOutputStream zipOut = new ZipOutputStream(fos);\r\n for (String srcFile : srcFiles) {\r\n File fileToZip = new File(srcFile);\r\n FileInputStream fis = new FileInputStream(fileToZip);\r\n ZipEntry zipEntry = new ZipEntry(fileToZip.getName());\r\n zipOut.putNextEntry(zipEntry);\r\n\r\n byte[] bytes = new byte[1024];\r\n int length;\r\n while ((length = fis.read(bytes)) >= 0) {\r\n zipOut.write(bytes, 0, length);\r\n }\r\n fis.close();\r\n fileToZip.delete();\r\n }\r\n zipOut.close();\r\n fos.close();\r\n }",
"public void zipFiles() {\r\n byte[] buffer = new byte[1024];\r\n try {\r\n\r\n // On rare occasions, there will be a semi colon in the title name,\r\n // ruining everything while zipping the file.\r\n if (title.contains(\":\") || title.contains(\".\")) {\r\n String temp = \"\";\r\n for (int i = 0; i < title.length(); i++) {\r\n \r\n if (title.charAt(i) == ':' || title.charAt(i) == '.') {\r\n \r\n } else {\r\n temp += title.charAt(i);\r\n }\r\n }\r\n title = temp;\r\n }\r\n System.out.println(\"File name: \" + title);\r\n \r\n FileOutputStream fos = new FileOutputStream(savePath + \"\\\\\" + title + \".zip\");\r\n ZipOutputStream zos = new ZipOutputStream(fos);\r\n \r\n for (String fileName : fileNames) {\r\n \r\n System.out.println(\"zipping file: \" + fileName);\r\n \r\n fileName = savePath + \"\\\\\" + fileName;\r\n File srcFile = new File(fileName);\r\n FileInputStream fis;\r\n if (srcFile.exists()) {\r\n fis = new FileInputStream(srcFile);\r\n \r\n zos.putNextEntry(new ZipEntry(srcFile.getName()));\r\n int length;\r\n while ((length = fis.read(buffer)) > 0) {\r\n zos.write(buffer, 0, length);\r\n }\r\n zos.closeEntry();\r\n fis.close();\r\n \r\n boolean success = (new File(fileName)).delete();\r\n }\r\n }\r\n zos.close();\r\n \r\n } catch (FileNotFoundException ex) {\r\n System.out.println(\"File not found!\");\r\n } catch (IOException ex) {\r\n }\r\n }",
"private void compressArchive() throws Exception {\n\t\tif (logger.isDebugEnabled()) {\n\t\t\tlogger.debug(\"Compressing archive: \" + path);\n\t\t}\n\n\t\tFileOutputStream fout = new FileOutputStream(path + \".gz\");\n\t\tGZIPOutputStream gout = new GZIPOutputStream(fout);\n\t\tFileInputStream fin = new FileInputStream(path);\n\t\tbyte[] buf = new byte[blockSize];\n\t\tint len;\n\t\twhile ((len = fin.read(buf)) > 0) {\n\t\t\tgout.write(buf, 0, len);\n\t\t}\n\t\tfin.close();\n\n\t\t// flush and close gzip file\n\t\tgout.finish();\n\t\tgout.close();\n\n\t\t// unlink original archive\n\t\tFile file = new File(path);\n\t\tfile.delete();\n\t}",
"public static void main(String[] args) {\n\n\t\tif (args.length != 5) {\n\t\t System.out.println(\"Usage: GenSig nameOfFileToSign keystore password sign publicKey\");\n\n\t\t }\n\t\telse try{\n\n\t\t KeyStore ks = KeyStore.getInstance(KeyStore.getDefaultType());\n\t\t ks.load(new FileInputStream(args[1]), args[2].toCharArray());\n\t\t \n\t\t String alias = (String)ks.aliases().nextElement();\n\t\t PrivateKey privateKey = (PrivateKey) ks.getKey(alias, args[2].toCharArray());\n\n\t\t Certificate cert = ks.getCertificate(alias);\n\n\t\t // Get public key\t\n\t\t PublicKey publicKey = cert.getPublicKey();\n\n\t\t /* Create a Signature object and initialize it with the private key */\n\n\t\t Signature rsa = Signature.getInstance(\"SHA256withRSA\");\t\n\t\n\n\t\t rsa.initSign(privateKey);\n\n\t\t /* Update and sign the data */\n\n \t String hexString = readFile(args[0]).trim();\n\t\t byte[] decodedBytes = DatatypeConverter.parseHexBinary(hexString);\t\n\t\t InputStream bufin = new ByteArrayInputStream(decodedBytes);\n\n\n\t\t byte[] buffer = new byte[1024];\n\t\t int len;\n\t\t while (bufin.available() != 0) {\n\t\t\tlen = bufin.read(buffer);\n\t\t\trsa.update(buffer, 0, len);\n\t\t };\n\n\t\t bufin.close();\n\n\t\t /* Now that all the data to be signed has been read in, \n\t\t\t generate a signature for it */\n\n\t\t byte[] realSig = rsa.sign();\n\n\t\t \n\t\t /* Save the signature in a file */\n\n\t\t File file = new File(args[3]);\n\t\t PrintWriter out = new PrintWriter(file);\n\n\t\t\t// if file doesn't exists, then create it\n\t\t\tif (!file.exists()) {\n\t\t\t\tfile.createNewFile();\n\t\t\t}\n\n\t\t out.println(DatatypeConverter.printBase64Binary(realSig));\n\t\t out.close();\n\n\n\t\t /* Save the public key in a file */\n\t\t byte[] key = publicKey.getEncoded();\n\t\t FileOutputStream keyfos = new FileOutputStream(args[4]);\n\t\t keyfos.write(key);\n\n\t\t keyfos.close();\n\n\t\t} catch (Exception e) {\n\t\t System.err.println(\"Caught exception \" + e.toString());\n\t\t}\n\n\t}",
"private boolean unarchive(String osSdkRoot, File archiveFile, SdkManager sdkManager, ITaskMonitor monitor) {\n boolean success = false;\n Package pkg = getParentPackage();\n String pkgName = pkg.getShortDescription();\n String pkgDesc = String.format(\"Installing %1$s\", pkgName);\n monitor.setDescription(pkgDesc);\n monitor.setResult(pkgDesc);\n String pkgKind = pkg.getClass().getSimpleName();\n File destFolder = null;\n File unzipDestFolder = null;\n File oldDestFolder = null;\n try {\n unzipDestFolder = createTempFolder(osSdkRoot, pkgKind, \"new\");\n if (unzipDestFolder == null) {\n monitor.setResult(\"Failed to find a temp directory in %1$s.\", osSdkRoot);\n return false;\n }\n if (!unzipDestFolder.mkdirs()) {\n monitor.setResult(\"Failed to create directory %1$s\", unzipDestFolder.getPath());\n return false;\n }\n String[] zipRootFolder = new String[] { null };\n if (!unzipFolder(archiveFile, getSize(), unzipDestFolder, pkgDesc, zipRootFolder, monitor)) {\n return false;\n }\n if (!generateSourceProperties(unzipDestFolder)) {\n return false;\n }\n destFolder = pkg.getInstallFolder(osSdkRoot, zipRootFolder[0], sdkManager);\n if (destFolder == null) {\n monitor.setResult(\"Failed to compute installation directory for %1$s.\", pkgName);\n return false;\n }\n if (!pkg.preInstallHook(this, monitor, osSdkRoot, destFolder)) {\n monitor.setResult(\"Skipping archive: %1$s\", pkgName);\n return false;\n }\n boolean move1done = false;\n boolean move2done = false;\n while (!move1done || !move2done) {\n File renameFailedForDir = null;\n if (!move1done) {\n if (destFolder.isDirectory()) {\n if (oldDestFolder == null) {\n oldDestFolder = createTempFolder(osSdkRoot, pkgKind, \"old\");\n }\n if (oldDestFolder == null) {\n monitor.setResult(\"Failed to find a temp directory in %1$s.\", osSdkRoot);\n return false;\n }\n if (!destFolder.renameTo(oldDestFolder)) {\n monitor.setResult(\"Failed to rename directory %1$s to %2$s.\", destFolder.getPath(), oldDestFolder.getPath());\n renameFailedForDir = destFolder;\n }\n }\n move1done = (renameFailedForDir == null);\n }\n if (move1done && !move2done) {\n if (renameFailedForDir == null && !unzipDestFolder.renameTo(destFolder)) {\n monitor.setResult(\"Failed to rename directory %1$s to %2$s\", unzipDestFolder.getPath(), destFolder.getPath());\n renameFailedForDir = unzipDestFolder;\n }\n move2done = (renameFailedForDir == null);\n }\n if (renameFailedForDir != null) {\n if (SdkConstants.CURRENT_PLATFORM == SdkConstants.PLATFORM_WINDOWS) {\n String msg = String.format(\"-= Warning ! =-\\n\" + \"A folder failed to be renamed or moved. On Windows this \" + \"typically means that a program is using that folder (for example \" + \"Windows Explorer or your anti-virus software.)\\n\" + \"Please momentarily deactivate your anti-virus software.\\n\" + \"Please also close any running programs that may be accessing \" + \"the directory '%1$s'.\\n\" + \"When ready, press YES to try again.\", renameFailedForDir.getPath());\n if (monitor.displayPrompt(\"SDK Manager: failed to install\", msg)) {\n continue;\n }\n }\n return false;\n }\n break;\n }\n unzipDestFolder = null;\n success = true;\n pkg.postInstallHook(this, monitor, destFolder);\n return true;\n } finally {\n deleteFileOrFolder(oldDestFolder);\n deleteFileOrFolder(unzipDestFolder);\n if (!success) {\n pkg.postInstallHook(this, monitor, null);\n }\n }\n }",
"@Test\n public void testDERIVATIVE_EXTRACT_CRC___() throws IOException {\n \n\t Configuration.CRC=true;\n\t Configuration.EXTRACT=true;\n\t Configuration.DERIVATIVE_EXTRACT_CRC=true;\n\t Configuration.COMPRESS=true;\n if(Configuration.CRC && Configuration.EXTRACT && Configuration.DERIVATIVE_EXTRACT_CRC && Configuration.COMPRESS) {\n \n ZipOutputStream zos = new ZipOutputStream(new FileOutputStream(new File(\n homeDir + \"/files/Teste.txt.zip\")));\n zos.putNextEntry(new ZipEntry(homeDir + \"/files/Teste.txt.zip\"));\n zos.write(new byte[32]);\n ZipInputStream zis = new ZipInputStream(new FileInputStream(new File(\n homeDir + \"/files/Teste.txt.zip\")));\n ZipEntry ze = zis.getNextEntry();\n assertTrue(ze != null);\n zis.available();\n zos.close();\n }\n }",
"String prepareFile();",
"public int serialize (IDataOutput stream ,boolean includeAdler32 ,boolean centralDir =false ,int centralDirOffset =0){\r\n\t\t\tif(stream == null) { return 0; }\r\n\t\t\tif(centralDir) {\r\n\t\t\t\t// Write central directory file header signature\r\n\t\t\t\tstream.writeUnsignedInt(FZip.SIG_CENTRAL_FILE_HEADER);\r\n\t\t\t\t// Write \"version made by\" host (usually 0) and number (always 2.0)\r\n\t\t\t\tstream.writeShort((_versionHost << 8) | 0x14);\r\n\t\t\t} else {\r\n\t\t\t\t// Write local file header signature\r\n\t\t\t\tstream.writeUnsignedInt(FZip.SIG_LOCAL_FILE_HEADER);\r\n\t\t\t}\r\n\t\t\t// Write \"version needed to extract\" host (usually 0) and number (always 2.0)\r\n\t\t\tstream.writeShort((_versionHost << 8) | 0x14);\r\n\t\t\t// Write the general purpose flag\r\n\t\t\t// - no encryption\r\n\t\t\t// - normal deflate\r\n\t\t\t// - no data descriptors\r\n\t\t\t// - no compressed patched data\r\n\t\t\t// - unicode as specified in _filenameEncoding\r\n\t\t\tstream.writeShort((_filenameEncoding == \"utf-8\") ? 0x0800 : 0);\r\n\t\t\t// Write compression method (always deflate)\r\n\t\t\tstream.writeShort(isCompressed ? COMPRESSION_DEFLATED : COMPRESSION_NONE);\r\n\t\t\t// Write date\r\n\t\t\tDate d =(_date != null) ? _date : new Date();\r\n\t\t\tint msdosTime =uint(d.getSeconds ())| (uint(d.getMinutes()) << 5) | (uint(d.getHours()) << 11);\r\n\t\t\tint msdosDate =uint(d.getDate ())| (uint(d.getMonth() + 1) << 5) | (uint(d.getFullYear() - 1980) << 9);\r\n\t\t\tstream.writeShort(msdosTime);\r\n\t\t\tstream.writeShort(msdosDate);\r\n\t\t\t// Write CRC32\r\n\t\t\tstream.writeUnsignedInt(_crc32);\r\n\t\t\t// Write compressed size\r\n\t\t\tstream.writeUnsignedInt(_sizeCompressed);\r\n\t\t\t// Write uncompressed size\r\n\t\t\tstream.writeUnsignedInt(_sizeUncompressed);\r\n\t\t\t// Prep filename\r\n\t\t\tByteArray ba =new ByteArray ();\r\n\t\t\tba.endian = Endian.LITTLE_ENDIAN;\r\n\t\t\tif (_filenameEncoding == \"utf-8\") {\r\n\t\t\t\tba.writeUTFBytes(_filename);\r\n\t\t\t} else {\r\n\t\t\t\tba.writeMultiByte(_filename, _filenameEncoding);\r\n\t\t\t}\r\n\t\t\tint filenameSize =ba.position ;\r\n\t\t\t// Prep extra fields\r\n\t\t\tfor(int i0 = 0; i0 < _extraFields .size(); i0++)\r\n\t\t\t{\r\n\t\t\t\t\theaderId = _extraFields .get(i0);\r\n\t\t\t\tif(extraBytes != null) {\r\n\t\t\t\t\tba.writeShort(uint(headerId));\r\n\t\t\t\t\tba.writeShort(uint(extraBytes.length()));\r\n\t\t\t\t\tba.writeBytes(extraBytes);\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\tif (includeAdler32) {\r\n\t\t\t\tif (!_hasAdler32) {\r\n\t\t\t\t\tboolean compressed =isCompressed ;\r\n\t\t\t\t\tif (compressed) { uncompress(); }\r\n\t\t\t\t\t_adler32 = ChecksumUtil.Adler32(_content, 0, _content.length());\r\n\t\t\t\t\t_hasAdler32 = true;\r\n\t\t\t\t\tif (compressed) { compress(); }\r\n\t\t\t\t}\r\n\t\t\t\tba.writeShort(0xdada);\r\n\t\t\t\tba.writeShort(4);\r\n\t\t\t\tba.writeUnsignedInt(_adler32);\r\n\t\t\t}\r\n\t\t\tint extrafieldsSize =ba.position -filenameSize ;\r\n\t\t\t// Prep comment (currently unused)\r\n\t\t\tif(centralDir && _comment.length > 0) {\r\n\t\t\t\tif (_filenameEncoding == \"utf-8\") {\r\n\t\t\t\t\tba.writeUTFBytes(_comment);\r\n\t\t\t\t} else {\r\n\t\t\t\t\tba.writeMultiByte(_comment, _filenameEncoding);\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\tint commentSize =ba.position -filenameSize -extrafieldsSize ;\r\n\t\t\t// Write filename and extra field sizes\r\n\t\t\tstream.writeShort(filenameSize);\r\n\t\t\tstream.writeShort(extrafieldsSize);\r\n\t\t\tif(centralDir) {\r\n\t\t\t\t// Write comment size\r\n\t\t\t\tstream.writeShort(commentSize);\r\n\t\t\t\t// Write disk number start (always 0)\r\n\t\t\t\tstream.writeShort(0);\r\n\t\t\t\t// Write file attributes (always 0)\r\n\t\t\t\tstream.writeShort(0);\r\n\t\t\t\tstream.writeUnsignedInt(0);\r\n\t\t\t\t// Write relative offset of local header\r\n\t\t\t\tstream.writeUnsignedInt(centralDirOffset);\r\n\t\t\t}\r\n\t\t\t// Write filename, extra field and comment\r\n\t\t\tif(filenameSize + extrafieldsSize + commentSize > 0) {\r\n\t\t\t\tstream.writeBytes(ba);\r\n\t\t\t}\r\n\t\t\t// Write file\r\n\t\t\tint fileSize =0;\r\n\t\t\tif(!centralDir && _content.length > 0) {\r\n\t\t\t\tif(isCompressed) {\r\n\t\t\t\t\tif(HAS_UNCOMPRESS || HAS_INFLATE) {\r\n\t\t\t\t\t\tfileSize = _content.length;\r\n\t\t\t\t\t\tstream.writeBytes(_content, 0, fileSize);\r\n\t\t\t\t\t} else {\r\n\t\t\t\t\t\tfileSize = _content.length - 6;\r\n\t\t\t\t\t\tstream.writeBytes(_content, 2, fileSize);\r\n\t\t\t\t\t}\r\n\t\t\t\t} else {\r\n\t\t\t\t\tfileSize = _content.length;\r\n\t\t\t\t\tstream.writeBytes(_content, 0, fileSize);\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\tint size =30+filenameSize +extrafieldsSize +commentSize +fileSize ;\r\n\t\t\tif(centralDir) {\r\n\t\t\t\tsize += 16;\r\n\t\t\t}\r\n\t\t\treturn size;\r\n\t\t}",
"TarEntry CreateEntryFromFile(String fileName);",
"public static void main(String[] args) throws Exception {\n readZipFile(FILE_NAME);\n }",
"TarEntry CreateEntry(byte[] headerBuffer);",
"public static void main(String[] args) {\n\n String pfx = \"E:\\\\PDFFileTest\\\\1.pfx\";\n String tmpPath = \"E:\\\\PDFFileTest\\\\1562570792439.pdf\";\n String expPath = \"E:\\\\PDFFileTest\\\\11.11\\\\h83.pdf\";\n String gif = \"E:\\\\PDFFileTest\\\\1.gif\";\n String password = \"111111\";\n try {\n sign(pfx, tmpPath, expPath, gif, password);\n System.out.println(\"success\");\n } catch (Exception e) {\n e.printStackTrace();\n }\n }",
"private final int zza(T r32, byte[] r33, int r34, int r35, int r36, com.google.android.gms.internal.clearcut.zzay r37) throws java.io.IOException {\n /*\n r31 = this;\n r15 = r31;\n r14 = r32;\n r12 = r33;\n r13 = r35;\n r11 = r36;\n r9 = r37;\n r10 = zzmh;\n r16 = 0;\n r8 = -1;\n r0 = r34;\n r7 = r8;\n r1 = r16;\n r6 = r1;\n L_0x0017:\n r17 = 1048575; // 0xfffff float:1.469367E-39 double:5.18065E-318;\n if (r0 >= r13) goto L_0x038d;\n L_0x001c:\n r1 = r0 + 1;\n r0 = r12[r0];\n if (r0 >= 0) goto L_0x002b;\n L_0x0022:\n r0 = com.google.android.gms.internal.clearcut.zzax.zza(r0, r12, r1, r9);\n r1 = r9.zzfd;\n r4 = r0;\n r5 = r1;\n goto L_0x002d;\n L_0x002b:\n r5 = r0;\n r4 = r1;\n L_0x002d:\n r3 = r5 >>> 3;\n r2 = r5 & 7;\n r1 = r15.zzai(r3);\n if (r1 == r8) goto L_0x0350;\n L_0x0037:\n r0 = r15.zzmi;\n r18 = r1 + 1;\n r0 = r0[r18];\n r18 = 267386880; // 0xff00000 float:2.3665827E-29 double:1.321066716E-315;\n r18 = r0 & r18;\n r8 = r18 >>> 20;\n r20 = r5;\n r5 = r0 & r17;\n r21 = r4;\n r4 = (long) r5;\n r22 = r4;\n r4 = 17;\n if (r8 > r4) goto L_0x0241;\n L_0x0050:\n r4 = r15.zzmi;\n r18 = r1 + 2;\n r4 = r4[r18];\n r18 = r4 >>> 20;\n r5 = 1;\n r18 = r5 << r18;\n r4 = r4 & r17;\n if (r4 == r7) goto L_0x006c;\n L_0x005f:\n r11 = -1;\n if (r7 == r11) goto L_0x0066;\n L_0x0062:\n r11 = (long) r7;\n r10.putInt(r14, r11, r6);\n L_0x0066:\n r6 = (long) r4;\n r6 = r10.getInt(r14, r6);\n r7 = r4;\n L_0x006c:\n r4 = 5;\n switch(r8) {\n case 0: goto L_0x0219;\n case 1: goto L_0x0203;\n case 2: goto L_0x01e4;\n case 3: goto L_0x01e4;\n case 4: goto L_0x01ce;\n case 5: goto L_0x01ac;\n case 6: goto L_0x0195;\n case 7: goto L_0x0175;\n case 8: goto L_0x0159;\n case 9: goto L_0x0132;\n case 10: goto L_0x011a;\n case 11: goto L_0x01ce;\n case 12: goto L_0x00e8;\n case 13: goto L_0x0195;\n case 14: goto L_0x01ac;\n case 15: goto L_0x00d0;\n case 16: goto L_0x00b4;\n case 17: goto L_0x007a;\n default: goto L_0x0070;\n };\n L_0x0070:\n r24 = r7;\n r11 = r20;\n r0 = r21;\n r12 = r33;\n goto L_0x0238;\n L_0x007a:\n r0 = 3;\n if (r2 != r0) goto L_0x00ad;\n L_0x007d:\n r0 = r3 << 3;\n r4 = r0 | 4;\n r0 = r15.zzad(r1);\n r12 = r33;\n r1 = r33;\n r2 = r21;\n r3 = r35;\n r24 = r7;\n r7 = r22;\n r11 = r20;\n r5 = r37;\n r0 = zza(r0, r1, r2, r3, r4, r5);\n r1 = r6 & r18;\n if (r1 != 0) goto L_0x00a1;\n L_0x009d:\n r1 = r9.zzff;\n goto L_0x012d;\n L_0x00a1:\n r1 = r10.getObject(r14, r7);\n r2 = r9.zzff;\n r1 = com.google.android.gms.internal.clearcut.zzci.zza(r1, r2);\n goto L_0x012d;\n L_0x00ad:\n r24 = r7;\n r11 = r20;\n r12 = r33;\n goto L_0x00cc;\n L_0x00b4:\n r24 = r7;\n r11 = r20;\n r7 = r22;\n r12 = r33;\n if (r2 != 0) goto L_0x00cc;\n L_0x00be:\n r3 = r21;\n r17 = com.google.android.gms.internal.clearcut.zzax.zzb(r12, r3, r9);\n r0 = r9.zzfe;\n r4 = com.google.android.gms.internal.clearcut.zzbk.zza(r0);\n goto L_0x01f6;\n L_0x00cc:\n r0 = r21;\n goto L_0x0238;\n L_0x00d0:\n r24 = r7;\n r11 = r20;\n r3 = r21;\n r7 = r22;\n r12 = r33;\n if (r2 != 0) goto L_0x01cb;\n L_0x00dc:\n r0 = com.google.android.gms.internal.clearcut.zzax.zza(r12, r3, r9);\n r1 = r9.zzfd;\n r1 = com.google.android.gms.internal.clearcut.zzbk.zzm(r1);\n goto L_0x01e0;\n L_0x00e8:\n r24 = r7;\n r11 = r20;\n r3 = r21;\n r7 = r22;\n r12 = r33;\n if (r2 != 0) goto L_0x01cb;\n L_0x00f4:\n r0 = com.google.android.gms.internal.clearcut.zzax.zza(r12, r3, r9);\n r2 = r9.zzfd;\n r1 = r15.zzaf(r1);\n if (r1 == 0) goto L_0x0115;\n L_0x0100:\n r1 = r1.zzb(r2);\n if (r1 == 0) goto L_0x0107;\n L_0x0106:\n goto L_0x0115;\n L_0x0107:\n r1 = zzn(r32);\n r2 = (long) r2;\n r2 = java.lang.Long.valueOf(r2);\n r1.zzb(r11, r2);\n goto L_0x0230;\n L_0x0115:\n r10.putInt(r14, r7, r2);\n goto L_0x022e;\n L_0x011a:\n r24 = r7;\n r11 = r20;\n r3 = r21;\n r7 = r22;\n r0 = 2;\n r12 = r33;\n if (r2 != r0) goto L_0x01cb;\n L_0x0127:\n r0 = com.google.android.gms.internal.clearcut.zzax.zze(r12, r3, r9);\n L_0x012b:\n r1 = r9.zzff;\n L_0x012d:\n r10.putObject(r14, r7, r1);\n goto L_0x022e;\n L_0x0132:\n r24 = r7;\n r11 = r20;\n r3 = r21;\n r7 = r22;\n r0 = 2;\n r12 = r33;\n if (r2 != r0) goto L_0x01cb;\n L_0x013f:\n r0 = r15.zzad(r1);\n r0 = zza(r0, r12, r3, r13, r9);\n r1 = r6 & r18;\n if (r1 != 0) goto L_0x014e;\n L_0x014b:\n r1 = r9.zzff;\n goto L_0x012d;\n L_0x014e:\n r1 = r10.getObject(r14, r7);\n r2 = r9.zzff;\n r1 = com.google.android.gms.internal.clearcut.zzci.zza(r1, r2);\n goto L_0x012d;\n L_0x0159:\n r24 = r7;\n r11 = r20;\n r3 = r21;\n r7 = r22;\n r1 = 2;\n r12 = r33;\n if (r2 != r1) goto L_0x01cb;\n L_0x0166:\n r1 = 536870912; // 0x20000000 float:1.0842022E-19 double:2.652494739E-315;\n r0 = r0 & r1;\n if (r0 != 0) goto L_0x0170;\n L_0x016b:\n r0 = com.google.android.gms.internal.clearcut.zzax.zzc(r12, r3, r9);\n goto L_0x012b;\n L_0x0170:\n r0 = com.google.android.gms.internal.clearcut.zzax.zzd(r12, r3, r9);\n goto L_0x012b;\n L_0x0175:\n r24 = r7;\n r11 = r20;\n r3 = r21;\n r7 = r22;\n r12 = r33;\n if (r2 != 0) goto L_0x01cb;\n L_0x0181:\n r0 = com.google.android.gms.internal.clearcut.zzax.zzb(r12, r3, r9);\n r1 = r9.zzfe;\n r3 = 0;\n r17 = (r1 > r3 ? 1 : (r1 == r3 ? 0 : -1));\n if (r17 == 0) goto L_0x018e;\n L_0x018d:\n goto L_0x0190;\n L_0x018e:\n r5 = r16;\n L_0x0190:\n com.google.android.gms.internal.clearcut.zzfd.zza(r14, r7, r5);\n goto L_0x022e;\n L_0x0195:\n r24 = r7;\n r11 = r20;\n r3 = r21;\n r7 = r22;\n r12 = r33;\n if (r2 != r4) goto L_0x01cb;\n L_0x01a1:\n r0 = com.google.android.gms.internal.clearcut.zzax.zzc(r12, r3);\n r10.putInt(r14, r7, r0);\n r0 = r3 + 4;\n goto L_0x022e;\n L_0x01ac:\n r24 = r7;\n r11 = r20;\n r3 = r21;\n r7 = r22;\n r12 = r33;\n if (r2 != r5) goto L_0x01cb;\n L_0x01b8:\n r4 = com.google.android.gms.internal.clearcut.zzax.zzd(r12, r3);\n r0 = r10;\n r1 = r32;\n r17 = r3;\n r2 = r7;\n r7 = r17;\n r0.putLong(r1, r2, r4);\n r0 = r7 + 8;\n goto L_0x022e;\n L_0x01cb:\n r0 = r3;\n goto L_0x0238;\n L_0x01ce:\n r24 = r7;\n r11 = r20;\n r0 = r21;\n r7 = r22;\n r12 = r33;\n if (r2 != 0) goto L_0x0238;\n L_0x01da:\n r0 = com.google.android.gms.internal.clearcut.zzax.zza(r12, r0, r9);\n r1 = r9.zzfd;\n L_0x01e0:\n r10.putInt(r14, r7, r1);\n goto L_0x022e;\n L_0x01e4:\n r24 = r7;\n r11 = r20;\n r0 = r21;\n r7 = r22;\n r12 = r33;\n if (r2 != 0) goto L_0x0238;\n L_0x01f0:\n r17 = com.google.android.gms.internal.clearcut.zzax.zzb(r12, r0, r9);\n r4 = r9.zzfe;\n L_0x01f6:\n r0 = r10;\n r1 = r32;\n r2 = r7;\n r0.putLong(r1, r2, r4);\n r6 = r6 | r18;\n r1 = r11;\n r0 = r17;\n goto L_0x0231;\n L_0x0203:\n r24 = r7;\n r11 = r20;\n r0 = r21;\n r7 = r22;\n r12 = r33;\n if (r2 != r4) goto L_0x0238;\n L_0x020f:\n r1 = com.google.android.gms.internal.clearcut.zzax.zzf(r12, r0);\n com.google.android.gms.internal.clearcut.zzfd.zza(r14, r7, r1);\n r0 = r0 + 4;\n goto L_0x022e;\n L_0x0219:\n r24 = r7;\n r11 = r20;\n r0 = r21;\n r7 = r22;\n r12 = r33;\n if (r2 != r5) goto L_0x0238;\n L_0x0225:\n r1 = com.google.android.gms.internal.clearcut.zzax.zze(r12, r0);\n com.google.android.gms.internal.clearcut.zzfd.zza(r14, r7, r1);\n r0 = r0 + 8;\n L_0x022e:\n r6 = r6 | r18;\n L_0x0230:\n r1 = r11;\n L_0x0231:\n r7 = r24;\n r8 = -1;\n r11 = r36;\n goto L_0x0017;\n L_0x0238:\n r2 = r0;\n r18 = r6;\n r29 = r10;\n r6 = r11;\n r14 = r15;\n goto L_0x035d;\n L_0x0241:\n r25 = r3;\n r24 = r7;\n r5 = r8;\n r11 = r20;\n r4 = r21;\n r7 = r22;\n r3 = 27;\n if (r5 != r3) goto L_0x028f;\n L_0x0250:\n r3 = 2;\n if (r2 != r3) goto L_0x0287;\n L_0x0253:\n r0 = r10.getObject(r14, r7);\n r0 = (com.google.android.gms.internal.clearcut.zzcn) r0;\n r2 = r0.zzu();\n if (r2 != 0) goto L_0x0271;\n L_0x025f:\n r2 = r0.size();\n if (r2 != 0) goto L_0x0268;\n L_0x0265:\n r2 = 10;\n goto L_0x026a;\n L_0x0268:\n r2 = r2 << 1;\n L_0x026a:\n r0 = r0.zzi(r2);\n r10.putObject(r14, r7, r0);\n L_0x0271:\n r5 = r0;\n r0 = r15.zzad(r1);\n r1 = r11;\n r2 = r33;\n r3 = r4;\n r4 = r35;\n r18 = r6;\n r6 = r37;\n r0 = zza(r0, r1, r2, r3, r4, r5, r6);\n r6 = r18;\n goto L_0x0231;\n L_0x0287:\n r18 = r6;\n r29 = r10;\n r30 = r11;\n goto L_0x0358;\n L_0x028f:\n r18 = r6;\n r3 = 49;\n if (r5 > r3) goto L_0x02e6;\n L_0x0295:\n r26 = r10;\n r9 = (long) r0;\n r0 = r31;\n r19 = r1;\n r1 = r32;\n r6 = r2;\n r2 = r33;\n r20 = r25;\n r3 = r4;\n r15 = r4;\n r4 = r35;\n r21 = r5;\n r5 = r11;\n r27 = r6;\n r6 = r20;\n r22 = r7;\n r7 = r27;\n r28 = r21;\n r8 = r19;\n r29 = r26;\n r30 = r11;\n r11 = r28;\n r12 = r22;\n r14 = r37;\n r0 = r0.zza(r1, r2, r3, r4, r5, r6, r7, r8, r9, r11, r12, r14);\n if (r0 != r15) goto L_0x02cf;\n L_0x02c6:\n r2 = r0;\n r6 = r30;\n r7 = r36;\n r14 = r31;\n goto L_0x035f;\n L_0x02cf:\n r14 = r32;\n r12 = r33;\n r13 = r35;\n r9 = r37;\n r6 = r18;\n r7 = r24;\n r10 = r29;\n r1 = r30;\n r8 = -1;\n r11 = r36;\n r15 = r31;\n goto L_0x0017;\n L_0x02e6:\n r19 = r1;\n r27 = r2;\n r15 = r4;\n r28 = r5;\n r22 = r7;\n r29 = r10;\n r30 = r11;\n r20 = r25;\n r1 = 50;\n r9 = r28;\n if (r9 != r1) goto L_0x031d;\n L_0x02fb:\n r7 = r27;\n r1 = 2;\n if (r7 != r1) goto L_0x031a;\n L_0x0300:\n r14 = r31;\n r0 = r31;\n r1 = r32;\n r2 = r33;\n r3 = r15;\n r4 = r35;\n r5 = r19;\n r6 = r20;\n r7 = r22;\n r9 = r37;\n r0 = r0.zza(r1, r2, r3, r4, r5, r6, r7, r9);\n if (r0 != r15) goto L_0x033d;\n L_0x0319:\n goto L_0x033b;\n L_0x031a:\n r14 = r31;\n goto L_0x035a;\n L_0x031d:\n r8 = r0;\n r7 = r27;\n r14 = r31;\n r0 = r31;\n r1 = r32;\n r2 = r33;\n r3 = r15;\n r4 = r35;\n r5 = r30;\n r6 = r20;\n r10 = r22;\n r12 = r19;\n r13 = r37;\n r0 = r0.zza(r1, r2, r3, r4, r5, r6, r7, r8, r9, r10, r12, r13);\n if (r0 != r15) goto L_0x033d;\n L_0x033b:\n r2 = r0;\n goto L_0x035b;\n L_0x033d:\n r12 = r33;\n r13 = r35;\n r9 = r37;\n r15 = r14;\n r6 = r18;\n r7 = r24;\n r10 = r29;\n r1 = r30;\n r8 = -1;\n r11 = r36;\n goto L_0x0389;\n L_0x0350:\n r30 = r5;\n r18 = r6;\n r24 = r7;\n r29 = r10;\n L_0x0358:\n r14 = r15;\n r15 = r4;\n L_0x035a:\n r2 = r15;\n L_0x035b:\n r6 = r30;\n L_0x035d:\n r7 = r36;\n L_0x035f:\n if (r6 != r7) goto L_0x036c;\n L_0x0361:\n if (r7 != 0) goto L_0x0364;\n L_0x0363:\n goto L_0x036c;\n L_0x0364:\n r8 = r2;\n r9 = r6;\n r1 = r18;\n r0 = r24;\n r2 = -1;\n goto L_0x039c;\n L_0x036c:\n r0 = r6;\n r1 = r33;\n r3 = r35;\n r4 = r32;\n r5 = r37;\n r0 = zza(r0, r1, r2, r3, r4, r5);\n r12 = r33;\n r13 = r35;\n r9 = r37;\n r1 = r6;\n r11 = r7;\n r15 = r14;\n r6 = r18;\n r7 = r24;\n r10 = r29;\n r8 = -1;\n L_0x0389:\n r14 = r32;\n goto L_0x0017;\n L_0x038d:\n r18 = r6;\n r24 = r7;\n r29 = r10;\n r7 = r11;\n r14 = r15;\n r9 = r1;\n r2 = r8;\n r1 = r18;\n r8 = r0;\n r0 = r24;\n L_0x039c:\n if (r0 == r2) goto L_0x03a7;\n L_0x039e:\n r2 = (long) r0;\n r10 = r32;\n r0 = r29;\n r0.putInt(r10, r2, r1);\n goto L_0x03a9;\n L_0x03a7:\n r10 = r32;\n L_0x03a9:\n r0 = r14.zzmt;\n if (r0 == 0) goto L_0x03eb;\n L_0x03ad:\n r0 = 0;\n r11 = r14.zzmt;\n r12 = r11.length;\n r5 = r0;\n r13 = r16;\n L_0x03b4:\n if (r13 >= r12) goto L_0x03e4;\n L_0x03b6:\n r1 = r11[r13];\n r6 = r14.zzmx;\n r0 = r14.zzmi;\n r2 = r0[r1];\n r0 = r14.zzag(r1);\n r0 = r0 & r17;\n r3 = (long) r0;\n r0 = com.google.android.gms.internal.clearcut.zzfd.zzo(r10, r3);\n if (r0 != 0) goto L_0x03cc;\n L_0x03cb:\n goto L_0x03df;\n L_0x03cc:\n r4 = r14.zzaf(r1);\n if (r4 != 0) goto L_0x03d3;\n L_0x03d2:\n goto L_0x03df;\n L_0x03d3:\n r3 = r14.zzmz;\n r3 = r3.zzg(r0);\n r0 = r31;\n r5 = r0.zza(r1, r2, r3, r4, r5, r6);\n L_0x03df:\n r5 = (com.google.android.gms.internal.clearcut.zzey) r5;\n r13 = r13 + 1;\n goto L_0x03b4;\n L_0x03e4:\n if (r5 == 0) goto L_0x03eb;\n L_0x03e6:\n r0 = r14.zzmx;\n r0.zzf(r10, r5);\n L_0x03eb:\n if (r7 != 0) goto L_0x03f7;\n L_0x03ed:\n r0 = r35;\n if (r8 != r0) goto L_0x03f2;\n L_0x03f1:\n goto L_0x03fd;\n L_0x03f2:\n r0 = com.google.android.gms.internal.clearcut.zzco.zzbo();\n throw r0;\n L_0x03f7:\n r0 = r35;\n if (r8 > r0) goto L_0x03fe;\n L_0x03fb:\n if (r9 != r7) goto L_0x03fe;\n L_0x03fd:\n return r8;\n L_0x03fe:\n r0 = com.google.android.gms.internal.clearcut.zzco.zzbo();\n throw r0;\n */\n throw new UnsupportedOperationException(\"Method not decompiled: com.google.android.gms.internal.clearcut.zzds.zza(java.lang.Object, byte[], int, int, int, com.google.android.gms.internal.clearcut.zzay):int\");\n }",
"public static void main(String[] args) {\n if (args.length != 2 && args.length != 3) {\n System.out.println(\"wrong args\");\n return;\n }\n try {\n String name, filename;\n if (args.length == 3) {\n if (!\"-jar\".equals(args[0])) {\n System.out.println(\"wrong flag\");\n return;\n }\n\n name = args[1];\n filename = args[2].substring(0, args[2].indexOf(\".jar\"));\n } else {\n name = args[0];\n filename = args[1];\n }\n File root = new File(filename);\n Class<?> token = Class.forName(name);\n Implementor implementor = new Implementor();\n if (args.length == 3) {\n implementor.implementJar(token, new File(args[2]));\n } else {\n implementor.implement(token, root);\n }\n } catch (ClassNotFoundException e) {\n System.out.println(\"Class not found:(\");\n } catch (ImplerException e) {\n System.out.println(\"An error occured\");\n } catch (Exception e) {\n System.out.println(\"Something wrong\");\n }\n }"
] | [
"0.590236",
"0.590236",
"0.590236",
"0.590236",
"0.590236",
"0.590236",
"0.55768585",
"0.55402416",
"0.55277175",
"0.5502961",
"0.5422213",
"0.54144007",
"0.51717746",
"0.51624477",
"0.5139158",
"0.51391244",
"0.50790375",
"0.50577766",
"0.5017365",
"0.5010909",
"0.49546018",
"0.4934481",
"0.49164292",
"0.49013612",
"0.48845416",
"0.48596495",
"0.48428813",
"0.47930288",
"0.47696617",
"0.47691262",
"0.47596592",
"0.47156957",
"0.4710004",
"0.46987906",
"0.46960416",
"0.46936694",
"0.4687105",
"0.46851578",
"0.46841207",
"0.46818313",
"0.4667112",
"0.46633542",
"0.46627915",
"0.46550027",
"0.4651581",
"0.46460375",
"0.46333423",
"0.4619422",
"0.46136472",
"0.46050277",
"0.4603792",
"0.45856488",
"0.4572174",
"0.4569146",
"0.45665812",
"0.45639274",
"0.45615563",
"0.45360073",
"0.45351785",
"0.4522798",
"0.45124185",
"0.45096594",
"0.450921",
"0.45041254",
"0.4500654",
"0.4487972",
"0.44814852",
"0.4476364",
"0.44594526",
"0.44558552",
"0.4443554",
"0.44431",
"0.44420817",
"0.44407898",
"0.44406185",
"0.44343317",
"0.4430225",
"0.4424308",
"0.440497",
"0.44019383",
"0.43992627",
"0.43853885",
"0.43853095",
"0.4383794",
"0.4382434",
"0.43763775",
"0.4373147",
"0.4370516",
"0.4368386",
"0.43647394",
"0.43646777",
"0.4358501",
"0.4353243",
"0.43425432",
"0.4341866",
"0.43274033",
"0.4322819",
"0.43190408",
"0.43178052",
"0.43126643"
] | 0.76091415 | 0 |
TODO Autogenerated method stub | @Override
public List<AfterBrandGclass> findAfterBrandList() {
String sql=" select brand_id brandId,brand_name_s brandName from tb_brand where is_display=0";
return this.queryList(sql, new Object[]{}, new BeanPropertyRowMapper(AfterBrandGclass.class));
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@Override\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}",
"@Override\n\tpublic void comer() {\n\t\t\n\t}",
"@Override\n public void perish() {\n \n }",
"@Override\r\n\t\t\tpublic void annadir() {\n\r\n\t\t\t}",
"@Override\n\tpublic void anular() {\n\n\t}",
"@Override\n\tprotected void getExras() {\n\n\t}",
"@Override\r\n\tpublic void anularFact() {\n\t\t\r\n\t}",
"@Override\n\tpublic void entrenar() {\n\t\t\n\t}",
"@Override\n\tpublic void nadar() {\n\t\t\n\t}",
"@Override\r\n\tpublic void tires() {\n\t\t\r\n\t}",
"@Override\r\n\t\t\tpublic void ayuda() {\n\r\n\t\t\t}",
"@Override\n\tprotected void interr() {\n\t}",
"@Override\n\tpublic void emprestimo() {\n\n\t}",
"@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}",
"@Override\n\tpublic void grabar() {\n\t\t\n\t}",
"@Override\n\tpublic void gravarBd() {\n\t\t\n\t}",
"@Override\r\n\tpublic void rozmnozovat() {\n\t}",
"@Override\r\n\tpublic void dormir() {\n\t\t\r\n\t}",
"@Override\n protected void getExras() {\n }",
"@Override\r\n\tpublic void publierEnchere() {\n\t\t\r\n\t}",
"@Override\n\tpublic void nefesAl() {\n\n\t}",
"@Override\n\tpublic void ligar() {\n\t\t\n\t}",
"@Override\n public void func_104112_b() {\n \n }",
"@Override\n\tprotected void initdata() {\n\n\t}",
"@Override\n\tpublic void nghe() {\n\n\t}",
"@Override\n public void function()\n {\n }",
"@Override\n public void function()\n {\n }",
"public final void mo51373a() {\n }",
"@Override\r\n\tpublic void stehReagieren() {\r\n\t\t//\r\n\t}",
"@Override\n public void inizializza() {\n\n super.inizializza();\n }",
"@Override\n\tprotected void initData() {\n\t\t\n\t}",
"@Override\r\n\t\tpublic void init() {\n\t\t\t\r\n\t\t}",
"@Override\n\tpublic void sacrifier() {\n\t\t\n\t}",
"@Override\r\n\tprotected void InitData() {\n\t\t\r\n\t}",
"public void designBasement() {\n\t\t\r\n\t}",
"@Override\r\n\tprotected void initialize() {\r\n\t\t\r\n\t\t\r\n\t}",
"public void gored() {\n\t\t\n\t}",
"@Override\r\n\tprotected void initData() {\n\r\n\t}",
"@Override\n\tpublic void einkaufen() {\n\t}",
"@Override\n protected void initialize() {\n\n \n }",
"public void mo38117a() {\n }",
"@Override\n\tprotected void getData() {\n\t\t\n\t}",
"Constructor() {\r\n\t\t \r\n\t }",
"@Override\r\n\tpublic void dibujar() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void dibujar() {\n\t\t\r\n\t}",
"@Override\n\tpublic void one() {\n\t\t\n\t}",
"@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}",
"@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}",
"@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}",
"@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}",
"@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}",
"@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}",
"private stendhal() {\n\t}",
"@Override\n\tprotected void update() {\n\t\t\n\t}",
"@Override\n\t\t\tpublic void ic() {\n\t\t\t\t\n\t\t\t}",
"@Override\n\tprotected void initData() {\n\n\t}",
"@Override\n\tprotected void initData() {\n\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n public void init() {\n\n }",
"@Override\n\tprotected void initialize() {\n\t\t\n\t}",
"@Override\n\tprotected void initialize() {\n\t\t\n\t}",
"@Override\r\n\tpublic void init() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void init() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void init() {\n\t\t\r\n\t}",
"@Override\n\tpublic void debite() {\n\t\t\n\t}",
"@Override\r\n\tpublic void init() {\n\r\n\t}",
"@Override\r\n\tpublic void init() {\n\r\n\t}",
"@Override\r\n\tpublic void init() {\n\r\n\t}",
"public contrustor(){\r\n\t}",
"@Override\n\tprotected void initialize() {\n\n\t}",
"@Override\r\n\tpublic void dispase() {\n\r\n\t}",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"@Override\n\tpublic void dtd() {\n\t\t\n\t}",
"@Override\n\tprotected void logic() {\n\n\t}",
"@Override\n\tprotected void lazyLoad() {\n\t\t\n\t}",
"public void mo4359a() {\n }",
"@Override\r\n\tprotected void initialize() {\n\r\n\t}",
"@Override\n public void memoria() {\n \n }",
"@Override\n\t\tpublic void method() {\n\t\t\t\n\t\t}",
"private RepositorioAtendimentoPublicoHBM() {\r\t}",
"@Override\n protected void initialize() \n {\n \n }",
"@Override\r\n\tpublic void getProposition() {\n\r\n\t}",
"@Override\n\tpublic void particular1() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\n\t}",
"@Override\n\tpublic void init() {\n\n\t}",
"@Override\n\tpublic void init() {\n\n\t}",
"@Override\n protected void prot() {\n }",
"@Override\r\n\tpublic void init()\r\n\t{\n\t}",
"@Override\n\tprotected void initValue()\n\t{\n\n\t}",
"public void mo55254a() {\n }"
] | [
"0.6671074",
"0.6567672",
"0.6523024",
"0.6481211",
"0.6477082",
"0.64591026",
"0.64127725",
"0.63762105",
"0.6276059",
"0.6254286",
"0.623686",
"0.6223679",
"0.6201336",
"0.61950207",
"0.61950207",
"0.61922914",
"0.6186996",
"0.6173591",
"0.61327106",
"0.61285484",
"0.6080161",
"0.6077022",
"0.6041561",
"0.6024072",
"0.6020252",
"0.59984857",
"0.59672105",
"0.59672105",
"0.5965777",
"0.59485507",
"0.5940904",
"0.59239364",
"0.5910017",
"0.5902906",
"0.58946234",
"0.5886006",
"0.58839184",
"0.58691067",
"0.5857751",
"0.58503544",
"0.5847024",
"0.58239377",
"0.5810564",
"0.5810089",
"0.5806823",
"0.5806823",
"0.5800025",
"0.5792378",
"0.5792378",
"0.5792378",
"0.5792378",
"0.5792378",
"0.5792378",
"0.5790187",
"0.5789414",
"0.5787092",
"0.57844025",
"0.57844025",
"0.5774479",
"0.5774479",
"0.5774479",
"0.5774479",
"0.5774479",
"0.5761362",
"0.57596046",
"0.57596046",
"0.575025",
"0.575025",
"0.575025",
"0.5747959",
"0.57337177",
"0.57337177",
"0.57337177",
"0.5721452",
"0.5715831",
"0.57142824",
"0.57140535",
"0.57140535",
"0.57140535",
"0.57140535",
"0.57140535",
"0.57140535",
"0.57140535",
"0.5711723",
"0.57041645",
"0.56991017",
"0.5696783",
"0.56881124",
"0.56774884",
"0.56734604",
"0.56728",
"0.56696945",
"0.5661323",
"0.5657007",
"0.5655942",
"0.5655942",
"0.5655942",
"0.56549734",
"0.5654792",
"0.5652974",
"0.5650185"
] | 0.0 | -1 |
TODO Autogenerated method stub | @Override
public List<SubjectEntity> queryPubSubList(String subject_id) {
StringBuffer sql = new StringBuffer();
sql.append(" select subject_id,subject_name,subject_introduction,subject_image,subject_url,subject_keyword");
sql.append(" from tb_subject where subject_state=5 and subject_id not in (?) order by subject_publishdate desc limit 0,8");
return this.queryList(sql.toString(), new Object[]{subject_id}, new BeanPropertyRowMapper(SubjectEntity.class));
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@Override\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}",
"@Override\n\tpublic void comer() {\n\t\t\n\t}",
"@Override\n public void perish() {\n \n }",
"@Override\r\n\t\t\tpublic void annadir() {\n\r\n\t\t\t}",
"@Override\n\tpublic void anular() {\n\n\t}",
"@Override\n\tprotected void getExras() {\n\n\t}",
"@Override\r\n\tpublic void anularFact() {\n\t\t\r\n\t}",
"@Override\n\tpublic void entrenar() {\n\t\t\n\t}",
"@Override\n\tpublic void nadar() {\n\t\t\n\t}",
"@Override\r\n\tpublic void tires() {\n\t\t\r\n\t}",
"@Override\r\n\t\t\tpublic void ayuda() {\n\r\n\t\t\t}",
"@Override\n\tprotected void interr() {\n\t}",
"@Override\n\tpublic void emprestimo() {\n\n\t}",
"@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}",
"@Override\n\tpublic void grabar() {\n\t\t\n\t}",
"@Override\n\tpublic void gravarBd() {\n\t\t\n\t}",
"@Override\r\n\tpublic void rozmnozovat() {\n\t}",
"@Override\r\n\tpublic void dormir() {\n\t\t\r\n\t}",
"@Override\n protected void getExras() {\n }",
"@Override\r\n\tpublic void publierEnchere() {\n\t\t\r\n\t}",
"@Override\n\tpublic void nefesAl() {\n\n\t}",
"@Override\n\tpublic void ligar() {\n\t\t\n\t}",
"@Override\n public void func_104112_b() {\n \n }",
"@Override\n\tprotected void initdata() {\n\n\t}",
"@Override\n\tpublic void nghe() {\n\n\t}",
"@Override\n public void function()\n {\n }",
"@Override\n public void function()\n {\n }",
"public final void mo51373a() {\n }",
"@Override\r\n\tpublic void stehReagieren() {\r\n\t\t//\r\n\t}",
"@Override\n public void inizializza() {\n\n super.inizializza();\n }",
"@Override\n\tprotected void initData() {\n\t\t\n\t}",
"@Override\r\n\t\tpublic void init() {\n\t\t\t\r\n\t\t}",
"@Override\n\tpublic void sacrifier() {\n\t\t\n\t}",
"@Override\r\n\tprotected void InitData() {\n\t\t\r\n\t}",
"public void designBasement() {\n\t\t\r\n\t}",
"@Override\r\n\tprotected void initialize() {\r\n\t\t\r\n\t\t\r\n\t}",
"public void gored() {\n\t\t\n\t}",
"@Override\r\n\tprotected void initData() {\n\r\n\t}",
"@Override\n\tpublic void einkaufen() {\n\t}",
"@Override\n protected void initialize() {\n\n \n }",
"public void mo38117a() {\n }",
"@Override\n\tprotected void getData() {\n\t\t\n\t}",
"Constructor() {\r\n\t\t \r\n\t }",
"@Override\r\n\tpublic void dibujar() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void dibujar() {\n\t\t\r\n\t}",
"@Override\n\tpublic void one() {\n\t\t\n\t}",
"@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}",
"@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}",
"@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}",
"@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}",
"@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}",
"@Override\r\n\tprotected void initData() {\n\t\t\r\n\t}",
"private stendhal() {\n\t}",
"@Override\n\tprotected void update() {\n\t\t\n\t}",
"@Override\n\t\t\tpublic void ic() {\n\t\t\t\t\n\t\t\t}",
"@Override\n\tprotected void initData() {\n\n\t}",
"@Override\n\tprotected void initData() {\n\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\t\t\n\t}",
"@Override\n public void init() {\n\n }",
"@Override\n\tprotected void initialize() {\n\t\t\n\t}",
"@Override\n\tprotected void initialize() {\n\t\t\n\t}",
"@Override\r\n\tpublic void init() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void init() {\n\t\t\r\n\t}",
"@Override\r\n\tpublic void init() {\n\t\t\r\n\t}",
"@Override\n\tpublic void debite() {\n\t\t\n\t}",
"@Override\r\n\tpublic void init() {\n\r\n\t}",
"@Override\r\n\tpublic void init() {\n\r\n\t}",
"@Override\r\n\tpublic void init() {\n\r\n\t}",
"public contrustor(){\r\n\t}",
"@Override\n\tprotected void initialize() {\n\n\t}",
"@Override\r\n\tpublic void dispase() {\n\r\n\t}",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"public void mo55254a() {\n }",
"@Override\n\tpublic void dtd() {\n\t\t\n\t}",
"@Override\n\tprotected void logic() {\n\n\t}",
"@Override\n\tprotected void lazyLoad() {\n\t\t\n\t}",
"public void mo4359a() {\n }",
"@Override\r\n\tprotected void initialize() {\n\r\n\t}",
"@Override\n public void memoria() {\n \n }",
"@Override\n\t\tpublic void method() {\n\t\t\t\n\t\t}",
"private RepositorioAtendimentoPublicoHBM() {\r\t}",
"@Override\n protected void initialize() \n {\n \n }",
"@Override\r\n\tpublic void getProposition() {\n\r\n\t}",
"@Override\n\tpublic void particular1() {\n\t\t\n\t}",
"@Override\n\tpublic void init() {\n\n\t}",
"@Override\n\tpublic void init() {\n\n\t}",
"@Override\n\tpublic void init() {\n\n\t}",
"@Override\n protected void prot() {\n }",
"@Override\r\n\tpublic void init()\r\n\t{\n\t}",
"@Override\n\tprotected void initValue()\n\t{\n\n\t}",
"public void mo55254a() {\n }"
] | [
"0.6671074",
"0.6567672",
"0.6523024",
"0.6481211",
"0.6477082",
"0.64591026",
"0.64127725",
"0.63762105",
"0.6276059",
"0.6254286",
"0.623686",
"0.6223679",
"0.6201336",
"0.61950207",
"0.61950207",
"0.61922914",
"0.6186996",
"0.6173591",
"0.61327106",
"0.61285484",
"0.6080161",
"0.6077022",
"0.6041561",
"0.6024072",
"0.6020252",
"0.59984857",
"0.59672105",
"0.59672105",
"0.5965777",
"0.59485507",
"0.5940904",
"0.59239364",
"0.5910017",
"0.5902906",
"0.58946234",
"0.5886006",
"0.58839184",
"0.58691067",
"0.5857751",
"0.58503544",
"0.5847024",
"0.58239377",
"0.5810564",
"0.5810089",
"0.5806823",
"0.5806823",
"0.5800025",
"0.5792378",
"0.5792378",
"0.5792378",
"0.5792378",
"0.5792378",
"0.5792378",
"0.5790187",
"0.5789414",
"0.5787092",
"0.57844025",
"0.57844025",
"0.5774479",
"0.5774479",
"0.5774479",
"0.5774479",
"0.5774479",
"0.5761362",
"0.57596046",
"0.57596046",
"0.575025",
"0.575025",
"0.575025",
"0.5747959",
"0.57337177",
"0.57337177",
"0.57337177",
"0.5721452",
"0.5715831",
"0.57142824",
"0.57140535",
"0.57140535",
"0.57140535",
"0.57140535",
"0.57140535",
"0.57140535",
"0.57140535",
"0.5711723",
"0.57041645",
"0.56991017",
"0.5696783",
"0.56881124",
"0.56774884",
"0.56734604",
"0.56728",
"0.56696945",
"0.5661323",
"0.5657007",
"0.5655942",
"0.5655942",
"0.5655942",
"0.56549734",
"0.5654792",
"0.5652974",
"0.5650185"
] | 0.0 | -1 |
GameState type = GameState.idle; | static boolean isPokemonsOption() {
return current == pokemonsOption;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"interface GameState {\n String WAITING_FOR_SECOND_PLAYER = \"WAITING_FOR_SECOND_PLAYER\";\n String TURN_HARE = \"TURN_HARE\";\n String TURN_HOUND = \"TURN_HOUND\";\n String WIN_HARE_BY_ESCAPE = \"WIN_HARE_BY_ESCAPE\";\n String WIN_HARE_BY_STALLING = \"WIN_HARE_BY_STALLING\";\n String WIN_HOUND = \"WIN_HOUND\";\n }",
"public GameState getGameState();",
"public GameState() {}",
"GLStateType getType();",
"public interface GameControllerState {\n}",
"GameState getGameState() {\n return gameState;\n }",
"StateType createStateType();",
"public GameState getGameState(){\n return this.gameState;\n }",
"GameMode mode();",
"interface Game {\n\n // Bank\n String TRANSACTION = \"transaction\";\n\n // Lobby\n String POKE = \"poke\";\n String MEMBER_READY = \"member_ready\";\n }",
"public interface GameState {\n\n\t/**\n * Method used by a player in order to perform transfer of stones \n * @param pitId the identifier of the pit by which the player will start (the associated pit must belong to him) This is the only method that can change the state \n * @return map {@link Map Map.class} with (pitId,#stones) as entries\n */\n\tpublic Map<Integer, Integer> move(final int pitId);\n\t\n\t/**\n\t * @return the {@link GameStateEnum GameStateEnum.class} that corresponds to {@link GameState GameState.class} concretions\n\t */\n\tpublic GameStateEnum getStateEnum();\n}",
"public void displayCurrentState(State game);",
"private void getGameState(String version){\n\n }",
"public interface State {\n /**\n * Does the state its own job\n * @param player which player is in \"the\" state\n */\n void doAction(Player player);\n\n /**\n * Get type of the state\n * @return State name\n */\n String getState();\n}",
"State getState();",
"State getState();",
"State getState();",
"State getState();",
"public GameMode(int s)\n {\n bird3.y+=15;\n bird3.goUp = true;\n \n state = s;\n sprite = 0; \n }",
"public interface IState {\n int getLevel();\n\n float getClock();\n\n int getLives();\n\n int getCurrentScore();\n\n int getRequiredScore();\n\n boolean isGameOver();\n\n @Override\n String toString();\n}",
"public int getStateOfMovement(){ return stateOfMovement; }",
"public interface IGameState {\n\n IGameState Run();\n}",
"int getState();",
"int getState();",
"int getState();",
"int getState();",
"int getState();",
"int getState();",
"Object getState();",
"public interface State {\r\n\r\n}",
"public interface STATE_TYPE {\r\n public static final int RESERVED = 1;\r\n public static final int PARKED = 2;\r\n public static final int UNPARKED = 3;\r\n public static final int CANCELED = 4;\r\n }",
"public GameState GetState(){\n\t\treturn this.state;\n\t}",
"public void setGameState(GameState gs){\n this.gameState = gs;\n }",
"abstract void showGameState();",
"@Override\n public GameState getGameState() {\n return this.gameState;\n }",
"public GameState getGameState() {\n return this.state;\n }",
"@PlayerState\n public abstract int getPlayerState();",
"private void setGameState() // Convert the string version of the game state to the GameState version.\n\t{\n\t\tif (gameStateString.equalsIgnoreCase(\"waitingForStart\"))\n\t\t{\n\t\t\tgameState = GameState.waitingForStart;\n\t\t}\n\t\telse if (gameStateString.equalsIgnoreCase(\"gameWelcome\"))\n\t\t{\n\t\t\tgameState = GameState.gameWelcome;\n\t\t} \n\t\telse if (gameStateString.equalsIgnoreCase(\"decideWhoGoesFirst\"))\n\t\t{\n\t\t\tgameState = GameState.decideWhoGoesFirst;\n\t\t} \n\t\telse if (gameStateString.equalsIgnoreCase(\"twoPlayersPlayerOneGoesFirst\"))\n\t\t{\n\t\t\tgameState = GameState.twoPlayersPlayerOneGoesFirst;\n\t\t} \n\t\telse if (gameStateString.equalsIgnoreCase(\"twoPlayersPlayerTwoGoesFirst\"))\n\t\t{\n\t\t\tgameState = GameState.twoPlayersPlayerTwoGoesFirst;\n\t\t} \n\t\telse if (gameStateString.equalsIgnoreCase(\"twoPlayersNowPlayerOnesTurn\"))\n\t\t{\n\t\t\tgameState = GameState.twoPlayersNowPlayerOnesTurn;\n\t\t} \n\t\telse if (gameStateString.equalsIgnoreCase(\"twoPlayersNowPlayerTwosTurn\"))\n\t\t{\n\t\t\tgameState = GameState.twoPlayersNowPlayerTwosTurn;\n\t\t} \n\t\telse if (gameStateString.equalsIgnoreCase(\"aPlayerHasWon\"))\n\t\t{\n\t\t\tgameState = GameState.aPlayerHasWon;\n\t\t} \n\n\t}",
"LabState state();",
"GameState checkState(String guid, String username) throws GameStateException;",
"public static GameType getGameType() {\n\t\treturn type;\n\t}",
"public GameState getState() {\n\t\treturn state;\n\t}",
"public void gameOver(int type) {\n \tthis.winner = state;\n \tif( type == -1 )\n \t\tthis.winner = 0;\n \tthis.state = 0;\n }",
"public void startOppTurn(GameState state) {\n }",
"public GameState getState(){\n\t\tGameState State=new GameState(this.points, this.currentBoard.getState());\n\t\t\n\t\treturn State;\n\t}",
"public abstract MachineState getInitialState();",
"int getStateValue2();",
"public static void newGame(GameType t) {\n\t\ttype = t;\n\t}",
"StateMachineType createStateMachineType();",
"PowerState getState();",
"public void load(BSGameState state);",
"public static int getGameType()\n\t{\n\t\treturn -1;\n\t}",
"public GameState getGameState() {\n return this.gameState;\n }",
"public State state();",
"public void setCurrentGameType(ChessFX.GameType t) {\n this.currentGameType = t;\n }",
"public State getState(){return this.state;}",
"private GameStatePresets()\n {\n\n }",
"void updateGameState(GameState gameState);",
"public GameTypeWrapper playGame();",
"int getStateValue();",
"int getStateValue();",
"int getStateValue();",
"public static void saveGameType() {\r\n\t\tclearGameType();\r\n\t\t\r\n\t\tif (GameSetup.threeHanded.getState()) {\r\n\t\t\tMain.isThreeHanded = true;\r\n\t\t}\r\n\t\tif (GameSetup.fourHandedSingle.getState()) {\r\n\t\t\tMain.isFourHandedSingle = true;\r\n\t\t}\r\n\t\tif (GameSetup.fourHandedTeams.getState()) {\r\n\t\t\tMain.isFourHandedTeams = true;\r\n\t\t}\r\n\t}",
"public GamePlayStatus() {}",
"public void stolenMonster(GameState state) {\n }",
"int getStateValue1();",
"public String getInitialState(String type) {\r\n\t\tTaskType tt = getType(type);\r\n\t\tif (tt != null && tt.initialState != null)\r\n\t\t\treturn tt.initialState;\r\n\t\treturn \"OPEN\";\r\n\t}",
"String getState();",
"String getState();",
"String getState();",
"public State getState(){\n\t\treturn State.TUT_ISLAND;\n\t}",
"public interface CMDConstant {\n int GAME_JOIN = 100,\n GAME_SIT = 101,\n GAME_STAND = 102,\n GAME_LEAVE = 103,\n GAME_CHANGE = 104,\n GAME_START = 105,\n GAME_STAKE = 106,\n GAME_ABANDON =107,\n GAME_SKIP = 108;\n}",
"public interface FusionStatus {\n\n /**\n * Defines status of a player\n */\n interface Player {\n /**\n * player playing as hare\n */\n int PLAYER_TYPE_HARE = 100;\n\n /**\n * player playing as hound\n */\n int PLAYER_TYPE_HOUND = 101;\n }\n\n /**\n * Defines states of a game session\n */\n interface GameState {\n String WAITING_FOR_SECOND_PLAYER = \"WAITING_FOR_SECOND_PLAYER\";\n String TURN_HARE = \"TURN_HARE\";\n String TURN_HOUND = \"TURN_HOUND\";\n String WIN_HARE_BY_ESCAPE = \"WIN_HARE_BY_ESCAPE\";\n String WIN_HARE_BY_STALLING = \"WIN_HARE_BY_STALLING\";\n String WIN_HOUND = \"WIN_HOUND\";\n }\n\n}",
"public int getState();",
"public int getState();",
"public int getState();",
"public int getState();",
"public GameState(State.StateView state) {\n }",
"public static GameState createInstance() {\n\t\treturn new GameState();\n\t}",
"public String type() {\n return \"Pawn\";\n }",
"public State getState();",
"public State getState();",
"int getIdle( int idle );",
"public S getRandomState();",
"GameState requestActionTile();",
"java.lang.String getState();",
"public S getCurrentState();",
"public static void setState(GameState state) {\r\n\t\tgameState = state;\r\n\t}",
"SpawnType getGameSpawnType();",
"public int getCurrentState() {\n return myState;\n }",
"public IState getState();",
"public AeBpelState getState();",
"public interface AbstractState {\r\n abstract void toNextState(ChessBoard chessBoard,AbstractState state);\r\n}",
"GameState requestActionGamePiece();",
"public interface ThingState\n{\n\n}",
"public String getState( )\r\n {\r\n if (isEating)\r\n return \"Eating\"; // Exit method w/ current state\r\n\r\n if (isSleeping)\r\n return \"Sleeping\";\r\n\r\n return \"Error in State\";\r\n }",
"public static SDLEventState eventState(int type, SDLEventState state) throws SDLException {\n\tshort s = SWIG_SDLEvent.SDL_EventState((short)type, (short)state.swigValue());\n\treturn SDLEventState.swigToEnum(s);\n }",
"public interface Action {\n void doAction(GameState state);\n}",
"public int getState() {return state;}",
"public int getState() {return state;}",
"private Object getState() {\n\treturn null;\r\n}"
] | [
"0.74031323",
"0.72749764",
"0.6912589",
"0.6906566",
"0.6745128",
"0.6744642",
"0.6686279",
"0.656055",
"0.6416351",
"0.64043635",
"0.63946545",
"0.6336549",
"0.6320969",
"0.626706",
"0.62142736",
"0.62142736",
"0.62142736",
"0.62142736",
"0.6195025",
"0.6193264",
"0.6186667",
"0.6166557",
"0.6166496",
"0.6166496",
"0.6166496",
"0.6166496",
"0.6166496",
"0.6166496",
"0.61633086",
"0.613067",
"0.6130169",
"0.6127978",
"0.61250913",
"0.61207545",
"0.61179966",
"0.6116109",
"0.61028314",
"0.6098052",
"0.60928965",
"0.6084036",
"0.60687494",
"0.6060223",
"0.60481215",
"0.60165036",
"0.6013606",
"0.60049504",
"0.60044163",
"0.5998037",
"0.59896505",
"0.5989361",
"0.5988341",
"0.5985836",
"0.59784406",
"0.5969",
"0.59566534",
"0.59534365",
"0.5948113",
"0.5934003",
"0.59243554",
"0.5924272",
"0.5924272",
"0.5924272",
"0.59228146",
"0.5909169",
"0.5889942",
"0.58628297",
"0.5860225",
"0.58554137",
"0.58554137",
"0.58554137",
"0.5835479",
"0.58335793",
"0.58192635",
"0.5817894",
"0.5817894",
"0.5817894",
"0.5817894",
"0.58176744",
"0.58153814",
"0.5811829",
"0.57994723",
"0.57994723",
"0.57993305",
"0.5797814",
"0.57919127",
"0.5781051",
"0.5771352",
"0.57691914",
"0.5767346",
"0.57658446",
"0.5754789",
"0.57521915",
"0.5750152",
"0.5735167",
"0.5731569",
"0.57242775",
"0.57063115",
"0.57026124",
"0.5702004",
"0.5702004",
"0.5698516"
] | 0.0 | -1 |
Converts a DeliveryReportRequest instance into the proper soap format, so that it can be written over the socket as the body of an http response | public void encode(
IoSession session, DeliveryReportRequest deliveryReportRequest, ProtocolEncoderOutput op) throws Exception {
//First write the http headers to the output stream
op.write(IoBuffer.wrap(Constants.HTTP_RESP_HEADER.getBytes()));
Document deliveryReportRequestXml = buildDeliveryReportRequestXml(deliveryReportRequest);
//Write the created delivery report request document to the output stream
op.write(IoBuffer.wrap(CommonUtil.docToBytes(deliveryReportRequestXml)));
op.flush();
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@SuppressWarnings(\"unchecked\")\r\n\tprivate static Document buildDeliveryReportRequestXml(\r\n\t\t\tDeliveryReportRequest deliveryReportRequest) throws Exception {\r\n\t\tMarshaller marshaller = CommonUtil.getMarshaller();\r\n\t\t\r\n \t//Create the soap response\r\n\t\tDocumentBuilderFactory documentBuilderFactory = DocumentBuilderFactory.newInstance();\r\n\t\tDocumentBuilder documentBuilder = documentBuilderFactory.newDocumentBuilder();\r\n\t\tDocument responseXml = documentBuilder.newDocument();\r\n\t\t\r\n\t\t//Create the soap envelope\r\n\t\tElement envelopeNode = responseXml.createElementNS(\r\n\t\t\t\tConstants.SOAP_ENV_NS, \"env:Envelope\");\r\n\t\tresponseXml.appendChild(envelopeNode);\r\n\t\t\r\n\t\t//Create the soap header\r\n\t\tElement headerNode = responseXml.createElementNS(Constants.SOAP_ENV_NS, \"env:Header\");\r\n\t\tenvelopeNode.appendChild(headerNode);\r\n\t\t\r\n\t\t//Create the soap body\r\n\t\tElement bodyNode = responseXml.createElementNS(Constants.SOAP_ENV_NS, \"env:Body\");\r\n\t\tenvelopeNode.appendChild(bodyNode);\r\n\t\t\r\n\t\t//Marshall the TransactionId node\r\n\t\tmarshaller.marshal(deliveryReportRequest.getHeader(), headerNode);\r\n\r\n\t\t//Marshall the DeliveryReportReq node\r\n\t\tmarshaller.marshal(\r\n\t\t\t\tnew JAXBElement<DeliveryReportReqType>(\r\n\t\t\t\t\t\tnew QName(Constants.MM7_NS, \"DeliveryReportReq\"),\r\n\t\t\t\t\t\t(Class<DeliveryReportReqType>) deliveryReportRequest.getRequest().getClass(),\r\n\t\t\t\t\t\tdeliveryReportRequest.getRequest()),\r\n\t\t\t\t\t\tbodyNode);\r\n \t\r\n\t\treturn responseXml;\r\n }",
"public static void any() {\n\t\tlong date = System.currentTimeMillis();\n\t\tString body = IO.readContentAsString(request.body);\n\t\tif (body == null) {\n\t\t\terror(StatusCode.INTERNAL_ERROR,\n\t\t\t\t\t\"Message is malformed (null body)...\");\n\t\t}\n\n\t\tDocument soapMessage = XML.getDocument(body);\n\t\tif (soapMessage == null) {\n\t\t\terror(StatusCode.INTERNAL_ERROR,\n\t\t\t\t\t\"Message is malformed (not XML)...\");\n\t\t}\n\n\t\t// parse the body and calculate required data...\n\t\tNode n = XPath.selectNode(\"//ReportListBean\", soapMessage);\n\t\tif (n == null) {\n\t\t\terror(StatusCode.INTERNAL_ERROR,\n\t\t\t\t\t\"Message is malformed (not a valid report)...\");\n\t\t}\n\n\t\t// can be optimized...\n\t\tString reportList = XMLHelper.createStringFromDOMNode(n, true);\n\t\tif (reportList == null) {\n\t\t\terror(StatusCode.INTERNAL_ERROR,\n\t\t\t\t\t\"Message is malformed (can not generate reportList)...\");\n\t\t}\n\n\t\tReportListBean reportListBean = null;\n\t\ttry {\n\t\t\treportListBean = JAXBHelper.unmarshall(new ByteArrayInputStream(\n\t\t\t\t\treportList.getBytes()));\n\t\t} catch (MessageExchangeException e) {\n\t\t\terror(StatusCode.INTERNAL_ERROR, e.getMessage());\n\t\t}\n\n\t\tMessage message = new Message();\n\t\tfor (ReportBean report : reportListBean.getReports()) {\n\t\t\tif (\"t1\".equalsIgnoreCase(report.getType())) {\n\t\t\t\tmessage.t1 = report.getDate();\n\t\t\t} else if (\"t2\".equalsIgnoreCase(report.getType())) {\n\t\t\t\tmessage.t2 = report.getDate();\n\t\t\t} else if (\"t3\".equalsIgnoreCase(report.getType())) {\n\t\t\t\tmessage.t3 = report.getDate();\n\t\t\t} else if (\"t4\".equalsIgnoreCase(report.getType())) {\n\t\t\t\tmessage.t4 = report.getDate();\n\t\t\t}\n\n\t\t\t// monitoring api needs to be fixed since all informations are the\n\t\t\t// same for the target\n\t\t\tmessage.endpoint = report.getEndpoint();\n\t\t\tmessage.itf = report.getItf();\n\t\t\tmessage.service = report.getServiceName();\n\t\t\tmessage.operation = report.getOperation();\n\t\t}\n\t\tmessage.date = date;\n\t\tmessage.exception = false;\n\t\tWebSocket.liveStream.publish(message);\n\t\t\n\t\trender(\"Services/MonitoringService_Response.xml\");\n\t}",
"public GetReceivedReportResponse getReceivedReport(GetReceivedReport request) {\n\t\treturn null;\n\t}",
"public static void generateReport() {\n PrintImpl printer = new PrintImpl(realtorLogImpl, propertyLogImpl);\n printer.generateReport(REQUESTS_FILE);\n }",
"public void sendfedexRequest(AascShipmentOrderInfo aascShipmentOrderInfo, \n AascShipMethodInfo aascShipMethodInfo, \n String chkReturnlabelstr, \n AascProfileOptionsBean aascProfileOptionsInfo, \n AascIntlInfo aascIntlInfo, \n String cloudLabelPath) throws Exception {\n logger.info(\"Entered sendfedexRequest method\");\n int pkgCount = aascShipmentOrderInfo.getShipmentPackageInfo().size();\n HashMap tempMap = null;\n\n String appendStr = \"\";\n\n if (chkReturnlabelstr.equals(\"NONRETURN\")) {\n fedExWSChkReturnlabelstr = chkReturnlabelstr;\n shipmentRequestHdr = \"\";\n appendStr = \"\";\n \n // \"<PersonName>\"+ Contact Name +\"</PersonName>\"+\n shipmentRequestHdr = \n \"<?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\" ?>\" + \n \"<FDXShipRequest xmlns:api=\\\"http://www.fedex.com/fsmapi\\\" xmlns:xsi=\\\"http://www.w3.org/2001/XMLSchema-instance\\\" xsi:noNamespaceSchemaLocation=\\\"FDXShipRequest.xsd\\\">\" + \n \"<RequestHeader>\" + \"<AccountNumber>\" + \n senderAccountNumber + \"</AccountNumber>\" + \n \"<MeterNumber>\" + fedExTestMeterNumber + \"</MeterNumber>\" + \n \"<CarrierCode>\" + carrierCode + \"</CarrierCode>\" + \n \"</RequestHeader>\" + \"<ShipDate>\" + shipDate + \n \"</ShipDate>\" + \"<ShipTime>\" + time + \"</ShipTime>\" + \n \"<DropoffType>\" + dropoffType + \"</DropoffType>\" + \n \"<Service>\" + service + \"</Service>\" + \"<Packaging>\" + \n packaging + \"</Packaging>\" + \"<WeightUnits>\" + pkgWtUom + \n \"</WeightUnits>\" + \"<Weight>\" + pkgWtVal + \"</Weight>\" + \n \"<CurrencyCode>\" + currencyCode + \"</CurrencyCode>\" + \n \"<ListRate>true</ListRate>\" + \"<Origin>\" + \"<Contact>\" + \n \"<CompanyName>\" + shipFromCompanyName + \"</CompanyName>\" + \n \"<PhoneNumber>\" + shipFromPhoneNumber1 + \"</PhoneNumber>\" + \n \"</Contact>\" + \"<Address>\" + \"<Line1>\" + \n shipFromAddressLine1 + \"</Line1>\" + \"<Line2>\" + \n shipFromAddressLine2 + \"</Line2>\" + \"<City>\" + \n shipFromAddressCity + \"</City>\" + \"<StateOrProvinceCode>\" + \n shipFromAddressState + \"</StateOrProvinceCode>\" + \n \"<PostalCode>\" + shipFromAddressPostalCode + \n \"</PostalCode>\" + \"<CountryCode>\" + shipFromCountry + \n \"</CountryCode>\" + \"</Address>\" + \"</Origin>\" + \n \"<Destination>\" + \"<Contact>\" + \n tagshipToContactPersonName + \"<CompanyName>\" + \n shipToCompanyName + \"</CompanyName>\" + \"<PhoneNumber>\" + \n shipToContactPhoneNumber + \"</PhoneNumber>\" + \n \"</Contact>\" + \"<Address>\" + \"<Line1>\" + \n shipToAddressLine1 + \"</Line1>\" + \"<Line2>\" + \n shipToAddressLine2 + \"</Line2>\" + \"<City>\" + \n shipToAddressCity + \"</City>\" + \"<StateOrProvinceCode>\" + \n shipToAddressState + \"</StateOrProvinceCode>\" + \n \"<PostalCode>\" + shipToAddressPostalCode + \n \"</PostalCode>\" + \"<CountryCode>\" + shipToCountry + \n \"</CountryCode>\" + \"</Address>\" + \"</Destination>\" + \n \"<Payment>\" + \"<PayorType>\" + carrierPayMethod + \n \"</PayorType>\";\n \n\n } else {\n fedExWSChkReturnlabelstr = chkReturnlabelstr;\n \n \n shipmentRequestHdr = \n rntHeader1 + header2 + header3 + listTag + rntHeader5 + \n rntHeader6;\n appendStr = \"Return_\";\n\n }\n\n tempMap = new HashMap();\n\n \n\n //Added by dedeepya on 22/06/07(start)\n\n if (carrierCode.equalsIgnoreCase(\"FDXE\")) {\n logger.info(\"carrierCode is FDXE\");\n orderNumber = \n \"<Value>FDXShipRequest/ReferenceInfo/CustomerReference</Value>\";\n Shipment = \n \"<Value>FDXShipReply/ReplyHeader/CustomerTransactionIdentifier</Value>\";\n Dept = \"<Value>FDXShipRequest/Origin/Contact/Department</Value>\";\n poNumber = \"<Value>FDXShipRequest/ReferenceInfo/PONumber</Value>\";\n ShipDate = \"<Value>FDXShipRequest/ShipDate</Value>\";\n Weight = \"<Value>FDXShipRequest/Weight</Value>\";\n COD = \n\"<Value>FDXShipRequest/SpecialServices/COD/CollectionAmount</Value>\";\n DV = \"<Value>FDXShipRequest/DeclaredValue</Value>\";\n Shipping = \n \"<Value>FDXShipReply/EstimatedCharges/DiscountedCharges/BaseCharge</Value>\";\n Special = \n \"<Value>FDXShipReply/EstimatedCharges/DiscountedCharges/TotalSurcharge</Value>\";\n Handling = \n \"<Value>FDXShipReply/EstimatedCharges/DiscountedCharges/TotalDiscount</Value>\";\n Total = \n \"<Value>FDXShipReply/EstimatedCharges/DiscountedCharges/NetCharge</Value>\";\n\n\n } else {\n logger.info(\"carrierCode is FDXG\");\n orderNumber = \n \"<Value>FDXShipRequestReferenceInfoCustomerReference</Value>\";\n Shipment = \n \"<Value>FDXShipReplyReplyHeaderCustomerTransactionIdentifier</Value>\";\n Dept = \"<Value>FDXShipRequestOriginContactDepartment</Value>\";\n poNumber = \"<Value>FDXShipRequestReferenceInfoPONumber</Value>\";\n ShipDate = \"<Value>FDXShipRequestShipDate</Value>\";\n Weight = \"<Value>FDXShipRequestWeight</Value>\";\n COD = \n\"<Value>FDXShipRequestSpecialServicesCODCollectionAmount</Value>\";\n DV = \"<Value>FDXShipRequestDeclaredValue</Value>\";\n Shipping = \n \"<Value>FDXShipReplyEstimatedChargesDiscountedChargesBaseCharge</Value>\";\n Special = \n \"<Value>FDXShipReplyEstimatedChargesDiscountedChargesTotalSurcharge</Value>\";\n Handling = \n \"<Value>FDXShipReplyEstimatedChargesDiscountedChargesTotalDiscount</Value>\";\n Total = \n \"<Value>FDXShipReplyEstimatedChargesDiscountedChargesNetCharge</Value>\";\n }\n\n //Added by dedeepya on 22/06/07(start)\n\n\n // If carrier code is FedExExpress and pay method is RECIPIENT or THIRDPARTY Or\n // carrier code is FedExGround and pay method is THIRDPARTY payer carrier account number is must.\n if (((carrierCode.equalsIgnoreCase(\"FDXE\")) && \n ((carrierPayMethodCode.equalsIgnoreCase(\"TP\")) || \n (carrierPayMethodCode.equalsIgnoreCase(\"CG\")))) || \n ((carrierCode.equalsIgnoreCase(\"FDXG\")) && \n (carrierPayMethodCode.equalsIgnoreCase(\"TP\")) || \n (carrierPayMethodCode.equalsIgnoreCase(\"CG\")))) {\n if (customerCarrierAccountNumber.length() < 9 || \n customerCarrierAccountNumber.length() > 12) {\n aascShipmentHeaderInfo.setMainError(\"third party or consignee's account number should not be less than 9 digits and greater than 12 digits \");\n responseStatus = 151;\n tempMap = new HashMap();\n tempMap.put(\"ResponseStatus\", String.valueOf(responseStatus));\n }\n \n shipmentRequestHdr = \n shipmentRequestHdr + \"<Payor><AccountNumber>\" + \n customerCarrierAccountNumber + \"</AccountNumber>\";\n if (carrierPayMethodCode.equalsIgnoreCase(\"TP\")) {\n\n String tpCountrySymbl = \n aascShipmentHeaderInfo.getTpCountrySymbol();\n shipmentRequestHdr = \n shipmentRequestHdr + \"<CountryCode>\" + tpCountrySymbl + \n \"</CountryCode></Payor>\";\n payorCountryCodeWS = tpCountrySymbl;\n } else {\n shipmentRequestHdr = \n shipmentRequestHdr + \"<CountryCode>\" + shipToCountry + \n \"</CountryCode></Payor>\";\n payorCountryCodeWS = shipToCountry;\n }\n }\n shipmentRequestHdr = shipmentRequestHdr + \"</Payment>\";\n\n /*if (carrierCode.equalsIgnoreCase(\"FDXE\")\n && (service.equalsIgnoreCase(\"FEDEX1DAYFREIGHT\")\n || service.equalsIgnoreCase(\"FEDEX2DAYFREIGHT\")\n || service.equalsIgnoreCase(\"FEDEX3DAYFREIGHT\"))) {*/\n shipmentRequestHdr = shipmentRequestHdr + header9;\n\n /*\"<Dimensions>\"\n + \"<Length>\" + length + \"</Length>\" + \"<Width>\"\n + width + \"</Width>\" + \"<Height>\" + height\n + \"</Height>\" + \"<Units>\" + units + \"</Units>\"\n + \"</Dimensions>\"\n */\n ;\n //}\n\n\n if (carrierCode.equalsIgnoreCase(\"FDXG\") && \n service.equalsIgnoreCase(\"GROUNDHOMEDELIVERY\")) {\n\n residentialTag = \"<ResidentialDelivery>true</ResidentialDelivery>\";\n\n } else {\n residentialTag = \"\";\n }\n\n if (!signatureOptions.equalsIgnoreCase(\"NONE\")) {\n signatureOptionString = \n \"<SignatureOption>\" + signatureOptions + \"</SignatureOption>\";\n } else {\n signatureOptionString = \"\";\n }\n\n shipmentHeader5 = \n \"<SpecialServices>\" + signatureOptionString + residentialTag + \n codTag + HazMat + hal + \"</SpecialServices>\";\n\n\n labelFormat = aascShipMethodInfo.getPrinterPort(carrierId);\n labelStockOrientation = \n aascShipMethodInfo.getLabelStockOrientation(carrierId);\n docTabLocation = aascShipMethodInfo.getDocTabLocation(carrierId);\n \n if (labelFormat.equalsIgnoreCase(\"ZEBRA\") || \n labelFormat.equalsIgnoreCase(\"ELTRON\") || \n labelFormat.equalsIgnoreCase(\"UNIMARK\")) { // LEADING\n // BOTTOM\n //Added by dedeepya on 22/06/07(start)\n labelFormatTag = \n \"<ImageType>\" + labelFormat + \"</ImageType>\" + \"<LabelStockOrientation>\" + \n labelStockOrientation + \"</LabelStockOrientation>\" + \n \"<DocTabLocation>\" + docTabLocation + \"</DocTabLocation>\" + \n \"<DocTabContent>\" + \"<Type>ZONE001</Type>\" + \"<Zone001>\" + \n \"<HeaderValuePair>\" + \"<ZoneNumber>01</ZoneNumber>\" + \n \"<Header>Order#</Header>\" + orderNumber + \n \"</HeaderValuePair>\" + \"<HeaderValuePair>\" + \n \"<ZoneNumber>02</ZoneNumber>\" + \n \"<Header>Delivery</Header>\" + Shipment + \n \"</HeaderValuePair>\" + \"<HeaderValuePair>\" + \n \"<ZoneNumber>03</ZoneNumber>\" + \"<Header>Dept</Header>\" + \n Dept + \"</HeaderValuePair>\" + \"<HeaderValuePair>\" + \n \"<ZoneNumber>04</ZoneNumber>\" + \"<Header>Ref</Header>\" + \n poNumber + \"</HeaderValuePair>\" + \"<HeaderValuePair>\" + \n \"<ZoneNumber>05</ZoneNumber>\" + \n \"<Header>ShipDate</Header>\" + ShipDate + \n \"</HeaderValuePair>\" + \"<HeaderValuePair>\" + \n \"<ZoneNumber>06</ZoneNumber>\" + \"<Header>Weight</Header>\" + \n Weight + \"</HeaderValuePair>\" + \"<HeaderValuePair>\" + \n \"<ZoneNumber>07</ZoneNumber>\" + \"<Header>COD</Header>\" + \n COD + \"</HeaderValuePair>\" + \"<HeaderValuePair>\" + \n \"<ZoneNumber>08</ZoneNumber>\" + \"<Header>DV</Header>\" + \n DV + \"</HeaderValuePair>\" + \"<HeaderValuePair>\" + \n \"<ZoneNumber>09</ZoneNumber>\" + \n \"<Header>Shipping</Header>\" + Shipping + \n \"</HeaderValuePair>\" + \"<HeaderValuePair>\" + \n \"<ZoneNumber>10</ZoneNumber>\" + \n \"<Header>Special</Header>\" + Special + \n \"</HeaderValuePair>\" + \"<HeaderValuePair>\" + \n \"<ZoneNumber>11</ZoneNumber>\" + \n \"<Header>Discount</Header>\" + Handling + \n \"</HeaderValuePair>\" + \"<HeaderValuePair>\" + \n \"<ZoneNumber>12</ZoneNumber>\" + \"<Header>Total</Header>\" + \n Total + \"</HeaderValuePair>\" + \"</Zone001>\" + \n \"</DocTabContent>\" + \n \"<MaskAccountNumber>true</MaskAccountNumber>\";\n //Added by dedeepya on 22/06/07(start)\n\n } else if (labelFormat.equalsIgnoreCase(\"PNG\")) {\n\n labelFormatTag = \"<ImageType>\" + labelFormat + \"</ImageType>\";\n } else {\n labelFormatTag = \n \"<ImageType>\" + \"PDF\" + \"</ImageType>\"; //labelFormat + \"</ImageType>\"; // remove pdf by labelFormat\n }\n\n pkgCount = aascShipmentOrderInfo.getShipmentPackageInfo().size();\n\n \n if (pkgCount == 1) {\n header4 = \"\";\n }\n shipmentRequestHdr = \n shipmentRequestHdr + internationalTags + shipmentHeader5 + \n \"<Label>\" + \"<Type>2DCOMMON</Type>\" + labelFormatTag + \n \"</Label>\" + header4 + rmaTag + \"</FDXShipRequest>\";\n //End\n\n\n /* shipmentRequestHdr = shipmentRequestHdr + internationalTags +shipmentHeader5+ \"<Label>\"\n + \"<Type>2DCOMMON</Type>\" + \"<ImageType>PNG</ImageType>\"\n + \"</Label>\" +rmaTag+ \"</FDXShipRequest>\"; */\n\n timeStampStr = \n (new Date().toString().replaceAll(\" \", \"_\")).replaceAll(\":\", \n \"_\");\n\n \n tempMap = null;\n tempMap = new HashMap();\n\n if (port != 0 && host != null && !(host.equals(\"\"))) {\n try {\n\n \n// try { logger.info(\"Before call\");\n// writeOutputFile(shipmentRequestHdr, \n// outputFile + orderNumberShip + \"_\" + \n// packageSequence + \"_\" + carrierCode + \"_\" + \n// appendStr + timeStampStr + \"_request.xml\");\n// \n// } catch (FileNotFoundException fileNotFoundException) {\n// logger.severe(\"file to which the request and response to be written is not found:\" + \n// fileNotFoundException.getMessage() + \n// \"\\n file name:\" + outputFile);\n//\n// }\n shipmentRequest = shipmentRequestHdr;\n \n\n fedExCarrierMode = nullStrToSpc(fedExCarrierMode);\n \n if (fedExCarrierMode.equalsIgnoreCase(\"WEBSERVICES\") || \n fedExCarrierMode.equalsIgnoreCase(\"FedexWebServices\")) {\n \n String intFlagLocal = \n nullStrToSpc(aascShipmentHeaderInfo.getInternationalFlag());\n Double totalWeight = \n aascShipmentHeaderInfo.getPackageWeight();\n\n replyOut = \n callFedexWS(fedExKey, fedExPassword, intFlagLocal, \n totalWeight, aascIntlInfo).getBytes();\n } else {\n replyOut = \n FedExAPI.transact(iUTI, shipmentRequest.getBytes(), \n host, port, timeOut);\n }\n\n\n \n shipmentResponse = new String(replyOut, \"ISO-8859-1\");\n \n if (shipmentResponse != null && !shipmentResponse.equals(\"\")) {\n \n {\n \n// try {\n// writeOutputFile(shipmentResponse, \n// outputFile + orderNumberShip + \n// \"_\" + packageSequence + \"_\" + \n// carrierCode + \"_\" + appendStr + \n// timeStampStr + \"_response.xml\");\n// \n// } catch (Exception fileNotFoundException) {\n// logger.severe(\"file path to which the fedex xml response to be written is not found:\" + \n// fileNotFoundException.getMessage() + \n// \"\\n file name:\" + outputFile);\n// }\n \n String nonDiscountedCost = \n aascProfileOptionsInfo.getNonDiscountedCost();\n \n\n AascFedexShipmentInfo aascFedexShipmentInfo = \n new AascFedexShipmentInfo();\n\n if (fedExCarrierMode.equalsIgnoreCase(\"WEBSERVICES\") || \n fedExCarrierMode.equalsIgnoreCase(\"FedexWebServices\")) {\n tempMap = aascFedexShipmentInfo.parseWebServiceResponse(shipmentResponse, \n aascShipmentOrderInfo, \n aascShipMethodInfo, \n aascProfileOptionsInfo, \n packageSequence, \n chkReturnlabelstr, \n cloudLabelPath);\n } else {\n tempMap = \n aascFedexShipmentInfo.parseResponse(shipmentResponse, \n aascShipmentOrderInfo, \n aascShipMethodInfo, \n aascProfileOptionsInfo, \n packageSequence, \n chkReturnlabelstr, \n cloudLabelPath);\n }\n\n\n // }\n\n\n hashMap = tempMap;\n parseStatus = (String)tempMap.get(\"status\");\n\n if (\"success\".equalsIgnoreCase(parseStatus) || \"WARNING\".equalsIgnoreCase(parseStatus) || \"NOTE\".equalsIgnoreCase(parseStatus)) {\n \n responseStatus = 150;\n tempMap.put(\"ResponseStatus\", \n String.valueOf(responseStatus));\n hashMap = tempMap;\n logger.info(\"response status:\" + responseStatus);\n aascShipmentHeaderInfo.setMainError(\"\");\n if(\"WARNING\".equalsIgnoreCase(parseStatus)){\n logger.info(\"Warning Message \"+(String)tempMap.get(\"warningMsg\"));\n aascShipmentHeaderInfo.setMainError((String)tempMap.get(\"warningMsg\"));\n }\n \n } else {\n \n aascShipmentHeaderInfo.setMainError(parseStatus);\n responseStatus = 151;\n tempMap.put(\"ResponseStatus\", \n String.valueOf(responseStatus));\n hashMap = tempMap;\n \n }\n }\n }\n } catch (FedExAPIException e) {\n responseStatus = 151;\n aascShipmentHeaderInfo.setMainError(e.getMessage());\n logger.severe(\"FedExAPIException: \" + e.getMessage());\n } catch (UnsupportedEncodingException e) {\n responseStatus = 151;\n aascShipmentHeaderInfo.setMainError(e.getMessage());\n logger.severe(\"UnsupportedEncodingException: \" + \n e.getMessage());\n }\n } else {\n logger.severe(\"either port or host is null:\" + \"\\n host:\" + host + \n \"\\n port:\" + port);\n aascShipmentHeaderInfo.setMainError(\"either port or host is null:\" + \n \"\\n host:\" + host + \n \"\\n port:\" + port);\n responseStatus = 151;\n tempMap.put(\"ResponseStatus\", String.valueOf(responseStatus));\n hashMap = tempMap;\n }\n logger.info(\"Exit from sendfedexRequest method\");\n }",
"@Override\n public ResponseEntity<?> createReport(OutputReport report) throws IOException, MessagingException {\n Date endDate = midnight();\n Date startDate = midnight();\n if (report.getReportType() == 0) {\n endDate = midnight();\n startDate = setDateBefore(1);\n } else if (report.getReportType() == 1) {\n endDate = midnight();\n startDate = setDateBefore(7);\n } else if (report.getReportType() == 2) {\n endDate = midnight();\n startDate = setDateBefore(30);\n } else if (report.getReportType() == 3) {\n endDate = new Date(report.getEndDate());\n startDate = new Date(report.getStartDate());\n }\n ExcelHelper.writeExcel(report.getReportItemList(), \"NiceJavaBooks.xls\", report.getTotalRevenue());\n Place place = placeRepository.findById(report.getPlaceId()).get();\n String content = \"\";\n if(report.getReportType() == 0){\n content = \"Daily sales report\";\n }else if(report.getReportType() == 1){\n content = \"Weekly sales report\";\n }else if(report.getReportType() == 2){\n content = \"Monthly sales report\";\n }else if(report.getReportType() == 3){\n SimpleDateFormat formatter = new SimpleDateFormat(\"dd/MM/yyyy\");\n content = \"Sales report from \"+formatter.format(startDate)+\" to \"+formatter.format(endDate);\n }\n sendEmail(new File(\"NiceJavaBooks.xls\"), place.getMail(), content);\n return ResponseEntity.ok(\"OK\");\n }",
"private void generateOutgoingReport() {\r\n\r\n\t\tStringBuilder stringBuilder = new StringBuilder();\r\n\t\tstringBuilder.append(\"\\n----------------------------------------\\n\")\r\n\t\t\t\t.append(\" Outgoing Daily Amount \\n\")\r\n\t\t\t\t.append(\"----------------------------------------\\n\")\r\n\t\t\t\t.append(\" Date | Trade Amount \\n\")\r\n\t\t\t\t.append(\"-----------------+----------------------\\n\");\r\n\t\tallOutgoings.entrySet().forEach(\r\n\t\t\t\tkey -> stringBuilder.append(key.getKey() + \" | \" + key.getValue().get() + \"\\n\"));\r\n\t\tdataWriter.write(stringBuilder.toString());\r\n\t}",
"public void writeRequest(OutputStream out, ServiceTunnelRequest msg) throws Exception {\n boolean compressed = isUseCompression();\r\n StringBuilder buf = new StringBuilder();\r\n buf.append(\"<SOAP-ENV:Envelope SOAP-ENV:encodingStyle=\\\"http://schemas.xmlsoap.org/soap/encoding/\\\" xmlns:SOAP-ENV=\\\"http://schemas.xmlsoap.org/soap/envelope/\\\">\\n\");\r\n buf.append(\"<SOAP-ENV:Body>\\n\");\r\n buf.append(\" <request version=\\\"\");\r\n buf.append(msg.getVersion());\r\n buf.append(\"\\\" compressed=\\\"\");\r\n buf.append(compressed);\r\n buf.append(\"\\\" format=\\\"\");\r\n buf.append(msg.getLocale().toString());\r\n buf.append(\"\\\" language=\\\"\");\r\n buf.append(msg.getNlsLocale().toString());\r\n buf.append(\"\\\" service=\\\"\");\r\n buf.append(msg.getServiceInterfaceClassName());\r\n buf.append(\"\\\" operation=\\\"\");\r\n buf.append(msg.getOperation());\r\n buf.append(\"\\\"/>\\n\");\r\n buf.append(\" <data>\");\r\n long y = System.nanoTime();\r\n setData(buf, msg, compressed);\r\n y = System.nanoTime() - y;\r\n if (LOG.isDebugEnabled()) LOG.debug(\"message encoding took \" + y + \" nanoseconds\");\r\n buf.append(\"</data>\\n\");\r\n buf.append(\" <info\");\r\n buf.append(\" origin=\\\"\" + m_originAddress + \"\\\"\");\r\n buf.append(\"/>\\n\");\r\n buf.append(\"</SOAP-ENV:Body>\");\r\n buf.append(\"</SOAP-ENV:Envelope>\");\r\n //\r\n if (LOG.isDebugEnabled()) {\r\n out = new DebugOutputStream(out);\r\n }\r\n try {\r\n out.write(buf.toString().getBytes(\"UTF-8\"));\r\n }\r\n finally {\r\n if (LOG.isDebugEnabled()) {\r\n String sentData = ((DebugOutputStream) out).getContent(\"UTF-8\");\r\n int lastWrittenCharacter = ((DebugOutputStream) out).getLastWrittenCharacter();\r\n Throwable lastThrownException = ((DebugOutputStream) out).getLastThrownException();\r\n LOG.debug(\"lastWrittenCharacter=\" + lastWrittenCharacter + \",lastThrownException=\" + lastThrownException + \", sentData: \" + sentData);\r\n }\r\n }\r\n }",
"private org.apache.axiom.soap.SOAPEnvelope toEnvelope(org.apache.axiom.soap.SOAPFactory factory, net.wit.webservice.TerminalServiceXmlServiceStub.TerminalDownloadQueryForMonth param, boolean optimizeContent, javax.xml.namespace.QName methodQName)\n throws org.apache.axis2.AxisFault{\n\n \n try{\n\n org.apache.axiom.soap.SOAPEnvelope emptyEnvelope = factory.getDefaultEnvelope();\n emptyEnvelope.getBody().addChild(param.getOMElement(net.wit.webservice.TerminalServiceXmlServiceStub.TerminalDownloadQueryForMonth.MY_QNAME,factory));\n return emptyEnvelope;\n } catch(org.apache.axis2.databinding.ADBException e){\n throw org.apache.axis2.AxisFault.makeFault(e);\n }\n \n\n }",
"private org.apache.axiom.soap.SOAPEnvelope toEnvelope(org.apache.axiom.soap.SOAPFactory factory, org.pahospital.www.radiologyservice.RadiologyServiceStub.RadiologyOrderIDForPayment param, boolean optimizeContent, javax.xml.namespace.QName methodQName)\n throws org.apache.axis2.AxisFault{\n\n \n try{\n\n org.apache.axiom.soap.SOAPEnvelope emptyEnvelope = factory.getDefaultEnvelope();\n emptyEnvelope.getBody().addChild(param.getOMElement(org.pahospital.www.radiologyservice.RadiologyServiceStub.RadiologyOrderIDForPayment.MY_QNAME,factory));\n return emptyEnvelope;\n } catch(org.apache.axis2.databinding.ADBException e){\n throw org.apache.axis2.AxisFault.makeFault(e);\n }\n \n\n }",
"private org.apache.axiom.soap.SOAPEnvelope toEnvelope(org.apache.axiom.soap.SOAPFactory factory, net.wit.webservice.TerminalServiceXmlServiceStub.TerminalDownloadQueryForDay param, boolean optimizeContent, javax.xml.namespace.QName methodQName)\n throws org.apache.axis2.AxisFault{\n\n \n try{\n\n org.apache.axiom.soap.SOAPEnvelope emptyEnvelope = factory.getDefaultEnvelope();\n emptyEnvelope.getBody().addChild(param.getOMElement(net.wit.webservice.TerminalServiceXmlServiceStub.TerminalDownloadQueryForDay.MY_QNAME,factory));\n return emptyEnvelope;\n } catch(org.apache.axis2.databinding.ADBException e){\n throw org.apache.axis2.AxisFault.makeFault(e);\n }\n \n\n }",
"@WebService(name = \"RPCLitSWA\", targetNamespace = \"http://org/apache/axis2/jaxws/proxy/rpclitswa\", wsdlLocation = \"RPCLitSWA.wsdl\")\r\n@SOAPBinding(style = Style.RPC)\r\npublic interface RPCLitSWA {\r\n\r\n\r\n /**\r\n * \r\n * @param request\r\n * @param dummyAttachmentINOUT\r\n * @param dummyAttachmentOUT\r\n * @param response\r\n * @param dummyAttachmentIN\r\n */\r\n @WebMethod\r\n public void echo(\r\n @WebParam(name = \"request\", partName = \"request\")\r\n String request,\r\n @WebParam(name = \"dummyAttachmentIN\", partName = \"dummyAttachmentIN\")\r\n String dummyAttachmentIN,\r\n @WebParam(name = \"dummyAttachmentINOUT\", mode = Mode.INOUT, partName = \"dummyAttachmentINOUT\")\r\n Holder<DataHandler> dummyAttachmentINOUT,\r\n @WebParam(name = \"response\", mode = Mode.OUT, partName = \"response\")\r\n Holder<String> response,\r\n @WebParam(name = \"dummyAttachmentOUT\", mode = Mode.OUT, partName = \"dummyAttachmentOUT\")\r\n Holder<String> dummyAttachmentOUT);\r\n\r\n}",
"@WebService(targetNamespace = \"http://soap.sforce.com/2005/09/outbound\", name = \"NotificationPort\")\n@XmlSeeAlso({ObjectFactory.class})\npublic interface NotificationPort {\n\n /**\n * Process a number of notifications.\n */\n @WebResult(name = \"Ack\", targetNamespace = \"http://soap.sforce.com/2005/09/outbound\")\n @RequestWrapper(localName = \"notifications\", targetNamespace = \"http://soap.sforce.com/2005/09/outbound\", className = \"com.barryku.cloud.cxf.Notifications\")\n @WebMethod\n @ResponseWrapper(localName = \"notificationsResponse\", targetNamespace = \"http://soap.sforce.com/2005/09/outbound\", className = \"com.barryku.cloud.cxf.NotificationsResponse\")\n public boolean notifications(\n @WebParam(name = \"OrganizationId\", targetNamespace = \"http://soap.sforce.com/2005/09/outbound\")\n java.lang.String organizationId,\n @WebParam(name = \"ActionId\", targetNamespace = \"http://soap.sforce.com/2005/09/outbound\")\n java.lang.String actionId,\n @WebParam(name = \"SessionId\", targetNamespace = \"http://soap.sforce.com/2005/09/outbound\")\n java.lang.String sessionId,\n @WebParam(name = \"EnterpriseUrl\", targetNamespace = \"http://soap.sforce.com/2005/09/outbound\")\n java.lang.String enterpriseUrl,\n @WebParam(name = \"PartnerUrl\", targetNamespace = \"http://soap.sforce.com/2005/09/outbound\")\n java.lang.String partnerUrl,\n @WebParam(name = \"Notification\", targetNamespace = \"http://soap.sforce.com/2005/09/outbound\")\n java.util.List<com.barryku.cloud.cxf.BookCNotification> notification\n );\n}",
"private org.apache.axiom.soap.SOAPEnvelope toEnvelope(org.apache.axiom.soap.SOAPFactory factory, com.drore.cloud.tdp.service.IWsPmsSdkServiceStub.GetVehicleRecordPage param, boolean optimizeContent)\n throws org.apache.axis2.AxisFault{\n\n \n try{\n\n org.apache.axiom.soap.SOAPEnvelope emptyEnvelope = factory.getDefaultEnvelope();\n emptyEnvelope.getBody().addChild(param.getOMElement(com.drore.cloud.tdp.service.IWsPmsSdkServiceStub.GetVehicleRecordPage.MY_QNAME,factory));\n return emptyEnvelope;\n } catch(org.apache.axis2.databinding.ADBException e){\n throw org.apache.axis2.AxisFault.makeFault(e);\n }\n \n\n }",
"public SendUnicodeSmsWithReportResponse sendSmsWithReport(\n\t\t\tSendUnicodeSmsWithReport request) {\n\t\treturn null;\n\t}",
"private org.apache.axiom.soap.SOAPEnvelope toEnvelope(org.apache.axiom.soap.SOAPFactory factory, com.drore.cloud.tdp.service.IWsPmsSdkServiceStub.GetEntrancePage param, boolean optimizeContent)\n throws org.apache.axis2.AxisFault{\n\n \n try{\n\n org.apache.axiom.soap.SOAPEnvelope emptyEnvelope = factory.getDefaultEnvelope();\n emptyEnvelope.getBody().addChild(param.getOMElement(com.drore.cloud.tdp.service.IWsPmsSdkServiceStub.GetEntrancePage.MY_QNAME,factory));\n return emptyEnvelope;\n } catch(org.apache.axis2.databinding.ADBException e){\n throw org.apache.axis2.AxisFault.makeFault(e);\n }\n \n\n }",
"public void sendTemplate(){\n int printer_size;\n try {\n printer_size = Integer.parseInt(ls.getString(LocalStorage.PRINTER_PAPER_SIZE,\"48\"));\n }catch (Exception e){\n printer_size = 48;\n }\n\n requestBody = \"<?xml version=\\\"1.0\\\" encoding=\\\"utf-8\\\"?>\\n\" +\n \"<Report Name=\\\"Large( \"+printer_size+\", 0)\\\" Width=\\\"\"+printer_size+\"\\\" Height=\\\"0\\\">\\n\" +\n\n \"<Text Alignment=\\\"CENTER\\\" Text=\\\"UNITS COPY\\\" Width=\\\"\" + printer_size + \"\\\" />\\n\"+\n \"<Value Alignment=\\\"CENTER\\\" Value=\\\"Barcode Id\\\" Width=\\\"\"+printer_size+\"\\\" />\\n\" +\n \"<Barcode Alignment=\\\"CENTER\\\" Value=\\\"Item Barcode\\\" Transform=\\\"BIG\\\" HRIPosition=\\\"\\\" Type=\\\"ITF\\\" Width=\\\"\"+printer_size+\"\\\" />\\n\"+\n\n \"<Value Value=\\\"Dealer\\\" Width=\\\"\"+printer_size+\"\\\" />\\n\" +\n \"<Value Value=\\\"DateCreated\\\" Width=\\\"\"+printer_size+\"\\\" />\\n\" +\n \"<Value Value=\\\"Unit\\\" Width=\\\"\"+printer_size+\"\\\" />\\n\" +\n \"<Value Value=\\\"Model\\\" Width=\\\"\"+printer_size+\"\\\" />\\n\" +\n \"<Value Value=\\\"Serial\\\" Width=\\\"\"+printer_size+\"\\\" />\\n\" +\n \"<Value Value=\\\"Warranty\\\" Width=\\\"\"+printer_size+\"\\\" />\\n\" +\n \"<Value Value=\\\"Complaint\\\" Width=\\\"\"+printer_size+\"\\\" />\\n\" +\n\n \"<Text Alignment=\\\"CENTER\\\" Text=\\\"\\\" Width=\\\"\"+printer_size+\"\\\" />\\n\"+\n \"<Value Value=\\\"Name\\\" Width=\\\"\"+printer_size+\"\\\" />\\n\" +\n \"<Value Value=\\\"Phone\\\" Width=\\\"\"+printer_size+\"\\\" />\\n\" +\n \"<Text Alignment=\\\"CENTER\\\" Text=\\\"\\\" Width=\\\"\"+printer_size+\"\\\" />\\n\"+\n\n \"<Text Text=\\\"Notes:\\\" Width=\\\"\"+printer_size+\"\\\" />\\n\"+\n \"<Text Alignment=\\\"CENTER\\\" Text=\\\"\\\" Width=\\\"\"+printer_size+\"\\\" />\\n\"+\n \"<Text Alignment=\\\"CENTER\\\" Text=\\\"\\\" Width=\\\"\"+printer_size+\"\\\" />\\n\"+\n \"<Text Alignment=\\\"CENTER\\\" Text=\\\"\\\" Width=\\\"\"+printer_size+\"\\\" />\\n\"+\n \"<Text Alignment=\\\"CENTER\\\" Text=\\\"\\\" Width=\\\"\"+printer_size+\"\\\" />\\n\"+\n \"<Text Alignment=\\\"CENTER\\\" Text=\\\"\\\" Width=\\\"\"+printer_size+\"\\\" />\\n\"+\n\n \"<Separator Width=\\\"\"+printer_size+\"\\\" />\\n\" +\n \"<Text Alignment=\\\"CENTER\\\" Text=\\\"CLAIM STUB\\\" Width=\\\"\" + printer_size + \"\\\" />\\n\"+\n \"<Value Alignment=\\\"CENTER\\\" Value=\\\"Barcode Id2\\\" Width=\\\"\"+printer_size+\"\\\" />\\n\" +\n \"<Barcode Alignment=\\\"CENTER\\\" Value=\\\"Item Barcode2\\\" Transform=\\\"BIG\\\" HRIPosition=\\\"\\\" Type=\\\"ITF\\\" Width=\\\"\"+printer_size+\"\\\" />\\n\"+\n\n \"<Value Value=\\\"DateCreated2\\\" Width=\\\"\"+printer_size+\"\\\" />\\n\" +\n \"<Value Value=\\\"Name2\\\" Width=\\\"\"+printer_size+\"\\\" />\\n\" +\n \"<Value Value=\\\"Phone2\\\" Width=\\\"\"+printer_size+\"\\\" />\\n\" +\n \"<Value Value=\\\"Unit2\\\" Width=\\\"\"+printer_size+\"\\\" />\\n\" +\n \"<Value Value=\\\"Model2\\\" Width=\\\"\"+printer_size+\"\\\" />\\n\" +\n \"<Value Value=\\\"Serial2\\\" Width=\\\"\"+printer_size+\"\\\" />\\n\" +\n \"<Text Alignment=\\\"CENTER\\\" Text=\\\"\\\" Width=\\\"\"+printer_size+\"\\\" />\\n\"+\n \"<Text Alignment=\\\"CENTER\\\" Text=\\\"\\\" Width=\\\"\"+printer_size+\"\\\" />\\n\"+\n \"</Report>\";\n }",
"private org.apache.axiom.soap.SOAPEnvelope toEnvelope(org.apache.axiom.soap.SOAPFactory factory, org.pahospital.www.radiologyservice.RadiologyServiceStub.RadiologyOrder param, boolean optimizeContent, javax.xml.namespace.QName methodQName)\n throws org.apache.axis2.AxisFault{\n\n \n try{\n\n org.apache.axiom.soap.SOAPEnvelope emptyEnvelope = factory.getDefaultEnvelope();\n emptyEnvelope.getBody().addChild(param.getOMElement(org.pahospital.www.radiologyservice.RadiologyServiceStub.RadiologyOrder.MY_QNAME,factory));\n return emptyEnvelope;\n } catch(org.apache.axis2.databinding.ADBException e){\n throw org.apache.axis2.AxisFault.makeFault(e);\n }\n \n\n }",
"public ActionForward print(ActionMapping mapping, ActionForm form, HttpServletRequest request, HttpServletResponse response) throws Exception {\r\n InvoiceReportDeliveryForm irdForm = (InvoiceReportDeliveryForm) form;\r\n String basePath = getApplicationBaseUrl();\r\n String deliveryType = irdForm.getDeliveryType();\r\n // To validate the input fields before fetching invoices.\r\n if (ObjectUtils.isNotNull(irdForm.getFromDate())) {\r\n SimpleDateFormat sdf = new SimpleDateFormat(\"mm/dd/yyyy\");\r\n Date testDate = null;\r\n try {\r\n testDate = sdf.parse(irdForm.getFromDate());\r\n }\r\n catch (Exception e) {\r\n irdForm.setMessage(NO_MATCHING_INVOICE);\r\n return mapping.findForward(KFSConstants.MAPPING_BASIC);\r\n }\r\n }\r\n if (ObjectUtils.isNotNull(irdForm.getToDate())) {\r\n SimpleDateFormat sdf = new SimpleDateFormat(\"mm/dd/yyyy\");\r\n Date testDate = null;\r\n try {\r\n testDate = sdf.parse(irdForm.getToDate());\r\n }\r\n catch (Exception e) {\r\n irdForm.setMessage(NO_MATCHING_INVOICE);\r\n return mapping.findForward(KFSConstants.MAPPING_BASIC);\r\n }\r\n }\r\n if (ObjectUtils.isNotNull(irdForm.getInvoiceAmount())) {\r\n try {\r\n KualiDecimal invoiceAmount = new KualiDecimal(irdForm.getInvoiceAmount());\r\n }\r\n catch (Exception e) {\r\n irdForm.setMessage(NO_MATCHING_INVOICE);\r\n return mapping.findForward(KFSConstants.MAPPING_BASIC);\r\n }\r\n }\r\n if (StringUtils.isEmpty(deliveryType)) {\r\n irdForm.setMessage(NO_DELIVERY_TYPE_SELECTED);\r\n return mapping.findForward(KFSConstants.MAPPING_BASIC);\r\n }\r\n // Check principal name if entered\r\n String principalName = irdForm.getUserId();\r\n if (StringUtils.isNotEmpty(principalName)) {\r\n Person person = SpringContext.getBean(PersonService.class).getPersonByPrincipalName(principalName);\r\n if (ObjectUtils.isNull(person)) {\r\n irdForm.setMessage(NO_PRINCIPAL_NAME_FOUND);\r\n return mapping.findForward(KFSConstants.MAPPING_BASIC);\r\n }\r\n }\r\n\r\n // Fetch the invoices with the input parameters\r\n Collection<ContractsGrantsInvoiceDocument> list = this.getInvoicesByParametersFromRequest(irdForm);\r\n\r\n if (CollectionUtils.isNotEmpty(list)) {\r\n // mapping to return to once delivery method is processed\r\n ActionForward forward = new ActionForward();\r\n // Buffer for message to display on the form\r\n StringBuffer statusMessage = new StringBuffer();\r\n\r\n // Check delivery type for EMAIL (or BOTH)\r\n if (ArConstants.InvoiceTransmissionMethod.EMAIL.equalsIgnoreCase(deliveryType)\r\n || ArConstants.InvoiceTransmissionMethod.BOTH.equalsIgnoreCase(deliveryType)) {\r\n\r\n Collection<ContractsGrantsInvoiceDocument> emailList = new ArrayList<ContractsGrantsInvoiceDocument>();\r\n Set<ContractsGrantsInvoiceDocument> emailSet = new HashSet<ContractsGrantsInvoiceDocument>();\r\n\r\n // Get all email-able invoices\r\n for (ContractsGrantsInvoiceDocument invoice : list) {\r\n if (ObjectUtils.isNull(invoice.getMarkedForProcessing())) {\r\n for (InvoiceAddressDetail invoiceAddressDetail : invoice.getInvoiceAddressDetails()) {\r\n if (ArConstants.InvoiceTransmissionMethod.EMAIL.equals(invoiceAddressDetail.getInvoiceTransmissionMethodCode())) {\r\n emailSet.add(invoice);\r\n }\r\n }\r\n }\r\n }\r\n emailList.addAll(emailSet);\r\n\r\n // mark invoices to be emailed for processing\r\n if (CollectionUtils.isNotEmpty(emailList)) {\r\n forward = emailInvoicePDF(mapping, irdForm, emailList);\r\n statusMessage.append(MARKED_FOR_PROCESSING_BY_BATCH_JOB);\r\n statusMessage.append(\"\\n\");\r\n }\r\n else {\r\n // if no invoices to be emailed were found and EMAIL was the option, add status message\r\n if(ArConstants.InvoiceTransmissionMethod.EMAIL.equalsIgnoreCase(deliveryType)){\r\n statusMessage.append(NO_MATCHING_INVOICE);\r\n statusMessage.append(\"\\n\");\r\n }\r\n // set forward to basic path\r\n forward = mapping.findForward(KFSConstants.MAPPING_BASIC);\r\n }\r\n }\r\n\r\n // Check delivery type for MAIL (or BOTH)\r\n if (ArConstants.InvoiceTransmissionMethod.MAIL.equalsIgnoreCase(deliveryType)\r\n || ArConstants.InvoiceTransmissionMethod.BOTH.equalsIgnoreCase(deliveryType)) {\r\n\r\n // Get all mail-able invoices\r\n Collection<ContractsGrantsInvoiceDocument> mailList = new ArrayList<ContractsGrantsInvoiceDocument>();\r\n Set<ContractsGrantsInvoiceDocument> mailSet = new HashSet<ContractsGrantsInvoiceDocument>();\r\n for (ContractsGrantsInvoiceDocument invoice : list) {\r\n if (ObjectUtils.isNull(invoice.getDateReportProcessed())) {\r\n for (InvoiceAddressDetail invoiceAddressDetail : invoice.getInvoiceAddressDetails()) {\r\n if (ArConstants.InvoiceTransmissionMethod.MAIL.equals(invoiceAddressDetail.getInvoiceTransmissionMethodCode())) {\r\n mailSet.add(invoice);\r\n }\r\n }\r\n }\r\n }\r\n mailList.addAll(mailSet);\r\n\r\n // Process mailable invoices found\r\n if (CollectionUtils.isNotEmpty(mailList)) {\r\n ByteArrayOutputStream baos = new ByteArrayOutputStream();\r\n if (this.printInvoicesAndEnvelopesZip(mapping, irdForm, mailList, baos)) {\r\n response.setContentType(\"application/zip\");\r\n response.setHeader(\"Content-disposition\", \"attachment; filename=Invoice-report\" + FILE_NAME_TIMESTAMP.format(new Date()) + \".zip\");\r\n response.setHeader(\"Expires\", \"0\");\r\n response.setHeader(\"Cache-Control\", \"must-revalidate, post-check=0, pre-check=0\");\r\n response.setHeader(\"Pragma\", \"public\");\r\n response.setContentLength(baos.size());\r\n ByteArrayInputStream bais = new ByteArrayInputStream(baos.toByteArray());\r\n IOUtils.copy(bais, response.getOutputStream());\r\n response.getOutputStream().flush();\r\n statusMessage.append(INVOICES_PRINT_SUCCESSFULL);\r\n statusMessage.append(\"\\n\");\r\n irdForm.setMessage(statusMessage.toString());\r\n\r\n return null;\r\n }\r\n else {\r\n statusMessage.append(INVOICES_PRINT_UNSUCCESSFULL);\r\n statusMessage.append(\"\\n\");\r\n forward = mapping.findForward(KFSConstants.MAPPING_BASIC);\r\n }\r\n }\r\n else {\r\n statusMessage.append(NO_MATCHING_INVOICE);\r\n statusMessage.append(\"\\n\");\r\n forward = mapping.findForward(KFSConstants.MAPPING_BASIC);\r\n }\r\n }\r\n\r\n irdForm.setMessage(statusMessage.toString());\r\n return forward;\r\n }\r\n // Catch all\r\n irdForm.setMessage(NO_MATCHING_INVOICE);\r\n return mapping.findForward(KFSConstants.MAPPING_BASIC);\r\n }",
"private static SOAPMessage createRequest(JobPosting jobPosting) throws SOAPException, ServerException {\n\n\t\tMessageFactory factory = MessageFactory.newInstance();\n\t\tSOAPMessage request = factory.createMessage();\n\t\tSOAPPart soapPart = request.getSOAPPart();\n\n\t\tSOAPEnvelope envelope = soapPart.getEnvelope();\n\t\tenvelope.addNamespaceDeclaration(SOAP_NAMESPACE_NAME,\n\t\t\t\tdestinationProperties.get(WEB_NAMESPACE_URL_DESTINATION_PROPERTY));\n\n\t\tSOAPBody soapBody = envelope.getBody();\n\t\tSOAPElement upload = soapBody.addChildElement(UPLOAD_SOAP_ELEMENT, SOAP_NAMESPACE_NAME);\n\t\tSOAPElement username = upload.addChildElement(USERNAME_SOAP_ELEMENT, SOAP_NAMESPACE_NAME);\n\t\tSOAPElement password = upload.addChildElement(PASSWORD_SOAP_ELEMENT, SOAP_NAMESPACE_NAME);\n\t\tSOAPElement data = upload.addChildElement(DATA_SOAP_ELEMENT, SOAP_NAMESPACE_NAME);\n\n\t\tusername.addTextNode(destinationProperties.get(USER_DESTINATION_PROPERTY));\n\t\tpassword.addTextNode(destinationProperties.get(PASSWORD_DESTINATION_PROPERTY));\n\n\t\tdata.addTextNode(jobPosting.toString());\n\n\t\trequest.saveChanges();\n\t\treturn request;\n\t}",
"private ReportRequest getAdReport(Calendar from, Calendar to) {\r\n\t\tAdPerformanceReportRequest request = new AdPerformanceReportRequest();\r\n\t\trequest.setFormat(ReportFormat.CSV);\r\n\t\trequest.setReportName(\"Ad Report\");\r\n\t\trequest.setAggregation(NonHourlyReportAggregation.DAILY);\r\n\t\trequest.setReturnOnlyCompleteData(false);\r\n\r\n\t\tAccountThroughAdGroupReportScope scope = new AccountThroughAdGroupReportScope();\r\n\t\tArrayOflong accountIds = new ArrayOflong();\r\n\t\taccountIds.getLongs().add(authorizationData.getAccountId());\r\n\t\tscope.setAccountIds(accountIds);\r\n\t\tscope.setCampaigns(null);\r\n\t\tscope.setAdGroups(null); \r\n\t\trequest.setScope(scope);\r\n\r\n\t\tArrayOfAdPerformanceReportColumn value = new ArrayOfAdPerformanceReportColumn();\r\n\t\tList<AdPerformanceReportColumn> columns = value.getAdPerformanceReportColumns();\r\n\t\tString adFields = adsProperties.getProperty(\"api.bing.adPerformanceReport.fields\");\r\n\t\tif (adFields != null && adFields.length() > 2) {\r\n\t\t\tfor (String fieldId : adFields.split(\",\")) {\r\n\t\t\t\tcolumns.add(AdPerformanceReportColumn.fromValue(fieldId));\r\n\t\t\t}\r\n\t\t} else {\r\n\t\t\tcolumns.add(AdPerformanceReportColumn.AD_ID);\r\n\t\t\tcolumns.add(AdPerformanceReportColumn.AD_TITLE);\r\n\t\t\tcolumns.add(AdPerformanceReportColumn.TITLE_PART_1);\r\n\t\t\tcolumns.add(AdPerformanceReportColumn.TITLE_PART_2);\r\n\t\t\tcolumns.add(AdPerformanceReportColumn.AD_DESCRIPTION);\r\n\t\t\tcolumns.add(AdPerformanceReportColumn.AD_GROUP_ID);\r\n\t\t\tcolumns.add(AdPerformanceReportColumn.AD_GROUP_NAME);\r\n\t\t\tcolumns.add(AdPerformanceReportColumn.AD_GROUP_STATUS);\r\n\t\t\tcolumns.add(AdPerformanceReportColumn.AD_STATUS);\r\n\t\t\tcolumns.add(AdPerformanceReportColumn.CAMPAIGN_ID);\r\n\t\t\tcolumns.add(AdPerformanceReportColumn.CAMPAIGN_NAME);\r\n\t\t\tcolumns.add(AdPerformanceReportColumn.CLICKS);\r\n\t\t\tcolumns.add(AdPerformanceReportColumn.COST_PER_CONVERSION);\r\n\t\t\tcolumns.add(AdPerformanceReportColumn.SPEND);\r\n\t\t\tcolumns.add(AdPerformanceReportColumn.CONVERSION_RATE);\r\n\t\t\tcolumns.add(AdPerformanceReportColumn.IMPRESSIONS);\r\n\t\t\tcolumns.add(AdPerformanceReportColumn.DESTINATION_URL);\r\n\t\t\tcolumns.add(AdPerformanceReportColumn.FINAL_URL);\r\n\t\t\tcolumns.add(AdPerformanceReportColumn.DISPLAY_URL);\r\n\t\t\tcolumns.add(AdPerformanceReportColumn.TIME_PERIOD);\r\n\t\t}\r\n\t\trequest.setColumns(value);\r\n\r\n\t\tReportTime reportTime = new ReportTime();\r\n\t\tDate start = new Date();\r\n\t\tDate end = new Date();\r\n\t\tstart.setDay(from.get(Calendar.DAY_OF_MONTH));\r\n\t\tstart.setMonth(from.get(Calendar.MONTH)+1);\r\n\t\tstart.setYear(from.get(Calendar.YEAR));\r\n\t\tend.setDay(to.get(Calendar.DAY_OF_MONTH));\r\n\t\tend.setMonth(to.get(Calendar.MONTH)+1);\r\n\t\tend.setYear(to.get(Calendar.YEAR));\r\n\t\treportTime.setCustomDateRangeStart(start);\r\n\t\treportTime.setCustomDateRangeEnd(end);\r\n\t\trequest.setTime(reportTime);\r\n\r\n\t\treturn request;\r\n\t}",
"private org.apache.axiom.soap.SOAPEnvelope toEnvelope(org.apache.axiom.soap.SOAPFactory factory, net.wit.webservice.TerminalServiceXmlServiceStub.DirectCharge param, boolean optimizeContent, javax.xml.namespace.QName methodQName)\n throws org.apache.axis2.AxisFault{\n\n \n try{\n\n org.apache.axiom.soap.SOAPEnvelope emptyEnvelope = factory.getDefaultEnvelope();\n emptyEnvelope.getBody().addChild(param.getOMElement(net.wit.webservice.TerminalServiceXmlServiceStub.DirectCharge.MY_QNAME,factory));\n return emptyEnvelope;\n } catch(org.apache.axis2.databinding.ADBException e){\n throw org.apache.axis2.AxisFault.makeFault(e);\n }\n \n\n }",
"public SmsSendRequestDto() {\n super();\n }",
"public lnrpc.Rpc.FeeReportResponse feeReport(lnrpc.Rpc.FeeReportRequest request) {\n return blockingUnaryCall(\n getChannel(), getFeeReportMethod(), getCallOptions(), request);\n }",
"public ReportDTO convertToDTO() {\n return new ReportDTO()\n .id(id)\n .email(email)\n .type(type)\n .content(content)\n .status(status)\n .reporter((reporter != null) ? reporter.convertToDTO() : null)\n .announcement(announcement.convertToDTO())\n .createdAt(createdAt);\n }",
"public void feeReport(lnrpc.Rpc.FeeReportRequest request,\n io.grpc.stub.StreamObserver<lnrpc.Rpc.FeeReportResponse> responseObserver) {\n asyncUnaryCall(\n getChannel().newCall(getFeeReportMethod(), getCallOptions()), request, responseObserver);\n }",
"private static SOAPMessage createSOAPRequest(String soapAction, int type, String orderId, JSONObject orderInfo)\n\t\t\tthrows Exception {\n\t\tSystem.out.println(\"createSOAPRequest\");\n\t\tMessageFactory messageFactory = MessageFactory.newInstance();\n\t\tSOAPMessage soapMessage = messageFactory.createMessage();\n\t\tsoapMessage.getSOAPHeader().detachNode();\n\t\tsoapMessage.getSOAPPart().getEnvelope().setPrefix(\"s\");\n\t\tsoapMessage.getSOAPPart().getEnvelope().removeNamespaceDeclaration(\"SOAP-ENV\");\n\t\t// soapMessage.getSOAPHeader().setPrefix(\"s\");\n\t\tsoapMessage.getSOAPBody().setPrefix(\"s\");\n\n\t\t// String authorization = new\n\t\t// sun.misc.BASE64Encoder().encode((userName+\":\"+password).getBytes());\n\n\t\tcreateSoapEnvelope(soapMessage, type, orderId, orderInfo);\n\n\t\tMimeHeaders headers = soapMessage.getMimeHeaders();\n\t\t// headers.addHeader(\"Authorization\", \"Basic \" + authorization);\n\t\theaders.addHeader(\"SOAPAction\", soapAction);\n\n\t\tsoapMessage.saveChanges();\n\n\t\t/* Print the request message, just for debugging purposes */\n\t\tSystem.out.println(\"Request SOAP Message:\");\n\t\tsoapMessage.writeTo(System.out);\n\t\tSystem.out.println(\"\\n\");\n\n\t\treturn soapMessage;\n\t}",
"private org.apache.axiom.soap.SOAPEnvelope toEnvelope(org.apache.axiom.soap.SOAPFactory factory, org.pahospital.www.radiologyservice.RadiologyServiceStub.RadiologyOrderID param, boolean optimizeContent, javax.xml.namespace.QName methodQName)\n throws org.apache.axis2.AxisFault{\n\n \n try{\n\n org.apache.axiom.soap.SOAPEnvelope emptyEnvelope = factory.getDefaultEnvelope();\n emptyEnvelope.getBody().addChild(param.getOMElement(org.pahospital.www.radiologyservice.RadiologyServiceStub.RadiologyOrderID.MY_QNAME,factory));\n return emptyEnvelope;\n } catch(org.apache.axis2.databinding.ADBException e){\n throw org.apache.axis2.AxisFault.makeFault(e);\n }\n \n\n }",
"private org.apache.axiom.soap.SOAPEnvelope toEnvelope(org.apache.axiom.soap.SOAPFactory factory, com.drore.cloud.tdp.service.IWsPmsSdkServiceStub.GetVehicleAlarmInfoPage param, boolean optimizeContent)\n throws org.apache.axis2.AxisFault{\n\n \n try{\n\n org.apache.axiom.soap.SOAPEnvelope emptyEnvelope = factory.getDefaultEnvelope();\n emptyEnvelope.getBody().addChild(param.getOMElement(com.drore.cloud.tdp.service.IWsPmsSdkServiceStub.GetVehicleAlarmInfoPage.MY_QNAME,factory));\n return emptyEnvelope;\n } catch(org.apache.axis2.databinding.ADBException e){\n throw org.apache.axis2.AxisFault.makeFault(e);\n }\n \n\n }",
"private org.apache.axiom.soap.SOAPEnvelope toEnvelope(org.apache.axiom.soap.SOAPFactory factory, net.wit.webservice.TerminalServiceXmlServiceStub.GetDirectSrvInfo param, boolean optimizeContent, javax.xml.namespace.QName methodQName)\n throws org.apache.axis2.AxisFault{\n\n \n try{\n\n org.apache.axiom.soap.SOAPEnvelope emptyEnvelope = factory.getDefaultEnvelope();\n emptyEnvelope.getBody().addChild(param.getOMElement(net.wit.webservice.TerminalServiceXmlServiceStub.GetDirectSrvInfo.MY_QNAME,factory));\n return emptyEnvelope;\n } catch(org.apache.axis2.databinding.ADBException e){\n throw org.apache.axis2.AxisFault.makeFault(e);\n }\n \n\n }",
"public static IReport createReport(InputStream in) throws ArfException {\r\n \treturn new Report(Report.getAssetReportCollection(in));\r\n }",
"public SendUnicodeSmsWithReportResponse sendUnicodeSmsWithReport(\n\t\t\tSendUnicodeSmsWithReport request) {\n\t\treturn null;\n\t}",
"public com.google.common.util.concurrent.ListenableFuture<lnrpc.Rpc.FeeReportResponse> feeReport(\n lnrpc.Rpc.FeeReportRequest request) {\n return futureUnaryCall(\n getChannel().newCall(getFeeReportMethod(), getCallOptions()), request);\n }",
"private org.apache.axiom.soap.SOAPEnvelope toEnvelope(org.apache.axiom.soap.SOAPFactory factory, com.drore.cloud.tdp.service.IWsPmsSdkServiceStub.GetVehicleInfoPage param, boolean optimizeContent)\n throws org.apache.axis2.AxisFault{\n\n \n try{\n\n org.apache.axiom.soap.SOAPEnvelope emptyEnvelope = factory.getDefaultEnvelope();\n emptyEnvelope.getBody().addChild(param.getOMElement(com.drore.cloud.tdp.service.IWsPmsSdkServiceStub.GetVehicleInfoPage.MY_QNAME,factory));\n return emptyEnvelope;\n } catch(org.apache.axis2.databinding.ADBException e){\n throw org.apache.axis2.AxisFault.makeFault(e);\n }\n \n\n }",
"public Document formatRequest(Properties req)\n {\n String sTemp = (String) req.get(REQ_CATEGORY_KEY);\n if ((sTemp == null) || (!(REQ_CATEGORY_VALUE.equalsIgnoreCase(sTemp))))\n {\n throw new IllegalArgumentException(\n \"req category invalid: null or REQ_CATEGORY_VALUE\");\n }\n\n sTemp = (String) req.get(REQ_TYPE_KEY);\n if ((sTemp == null) || (!(REQ_TYPE_VALUE.equalsIgnoreCase(sTemp))))\n {\n throw new IllegalArgumentException(\n \"req type invalid: null or REQ_TYPE_VALUE\");\n }\n\n String datasource = (String) req.get(DATASOURCE_KEY);\n\n Document reqDoc = PSXmlDocumentBuilder.createXmlDocument();\n Element root = PSXmlDocumentBuilder.createRoot(reqDoc, NODE_NAME);\n if (datasource != null)\n PSXmlDocumentBuilder.addElement(reqDoc, root, EL_DATASOURCE, \n datasource);\n\n return reqDoc;\n }",
"private static void printSOAPResponse(SOAPMessage soapResponse) throws Exception {\n TransformerFactory transformerFactory = TransformerFactory.newInstance();\n Transformer transformer = transformerFactory.newTransformer();\n \n ByteArrayOutputStream stream = new ByteArrayOutputStream();\n soapResponse.writeTo(stream);\n String message = new String(stream.toByteArray(), \"utf-8\");\n \n \n Source sourceContent = soapResponse.getSOAPPart().getContent();\n System.out.print(\"\\nResponse SOAP Message = \");\n StreamResult result = new StreamResult(System.out);\n transformer.transform(sourceContent, result);\n \n \n \n }",
"private Message getExecutionReport(Message input) {\n Message msg = null;\n try {\n String clOrdId = input.getString(protocolConfig.getTagForName(\"ClOrdID\"));\n Cdr cdr = new Cdr(MsgType.ORDER_SINGLE);\n cdr.set(\"ClOrdID\", clOrdId);\n } catch (UnknownTagException e) {\n LOG.error(\"Unknown Tag\", e);\n } catch (FieldNotFound e) {\n LOG.error(\"Field Not Found\", e);\n }\n return msg;\n }",
"@Override\n public void doPost(String path, HttpServletRequest request, HttpServletResponse response)\n throws Exception {\n String xml = \"\";\n String strRead = \"\";\n\n InputStreamReader isReader = new InputStreamReader(request.getInputStream());\n BufferedReader bReader = new BufferedReader(isReader);\n StringBuilder strBuilder = new StringBuilder();\n strRead = bReader.readLine();\n while (strRead != null) {\n strBuilder.append(strRead);\n strRead = bReader.readLine();\n }\n xml = strBuilder.toString();\n\n DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance();\n DocumentBuilder builder = factory.newDocumentBuilder();\n InputSource is = new InputSource(new StringReader(xml));\n Document document = builder.parse(is);\n\n // Verify if all the necessary tag and values are present\n\n StringBuilder xmlBuilder = new StringBuilder();\n xmlBuilder.append(\"<?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\" ?>\");\n xmlBuilder.append(\"<purchaseOrder>\");\n\n OrderDTO orderDTO = parsePurchaseOrderXML(document);\n\n if (orderDTO.getSuccessStatus().equals(success)) {\n\n PurchaseOrderServiceDAO poServiceDAO = new PurchaseOrderServiceDAO();\n synchronized (poServiceDAO) {\n orderDTO = poServiceDAO.createPONew(orderDTO);\n poServiceDAO.closeConnection();\n }\n\n if (orderDTO.getSuccessStatus().equals(success)) {\n\n final String linesInfoString = orderDTO.getLinesInfo();\n final String[] linesArray = linesInfoString.split(\",\");\n\n xmlBuilder.append(\"<status>\").append(orderDTO.getSuccessStatus()).append(\"</status>\");\n xmlBuilder.append(\"<documentNo>\").append(orderDTO.getDocumentNo()).append(\"</documentNo>\");\n xmlBuilder.append(\"<purchaseOrderId>\").append(orderDTO.getCOrderId())\n .append(\"</purchaseOrderId>\");\n xmlBuilder.append(\"<purchaseOrderLines>\");\n for (int i = 0; i < linesArray.length; i++) {\n\n final String lineInfo = linesArray[i];\n final String[] lineInfoValues = lineInfo.split(\"-\");\n xmlBuilder.append(\"<purchaseOrderLine>\");\n xmlBuilder.append(\"<itemCode>\" + lineInfoValues[0] + \"</itemCode>\");\n xmlBuilder.append(\"<orderedQty>\" + lineInfoValues[1] + \"</orderedQty>\");\n xmlBuilder.append(\"<confirmedQty>\" + lineInfoValues[2] + \"</confirmedQty>\");\n xmlBuilder.append(\"</purchaseOrderLine>\");\n }\n xmlBuilder.append(\"</purchaseOrderLines>\");\n xmlBuilder.append(\"<confirmedQty>\").append(orderDTO.getConfirmedQty())\n .append(\"</confirmedQty>\");\n log.debug(\"Purchase Order successfully created with c_order_id: \" + orderDTO.getCOrderId()\n + \" and documentno: \" + orderDTO.getDocumentNo());\n } else {\n // System.out.println(orderDTO.getSuccessStatus());\n xmlBuilder.append(\"<status>\").append(orderDTO.getSuccessStatus()).append(\"</status>\");\n }\n\n } else {\n xmlBuilder.append(\"<status>\").append(orderDTO.getSuccessStatus()).append(\"</status>\");\n }\n\n xmlBuilder.append(\"</purchaseOrder>\");\n\n response.setContentType(\"text/xml\");\n response.setCharacterEncoding(\"utf-8\");\n final Writer w = response.getWriter();\n w.write(xmlBuilder.toString());\n w.close();\n\n }",
"public String toXMLString() {\r\n\t\tswitch (this.transactionType) {\r\n\t\tcase GET_SETTLED_BATCH_LIST :\r\n\t\t\tgetSettledBatchListRequest();\r\n\t\t\tbreak;\r\n\t\tcase GET_TRANSACTION_DETAILS :\r\n\t\t\tgetTransactionDetailsRequest();\r\n\t\t\tbreak;\r\n\t\tcase GET_TRANSACTION_LIST :\r\n\t\t\tgetTransactionListRequest();\r\n\t\t\tbreak;\r\n\t\tcase GET_BATCH_STATISTICS :\r\n\t\t\tgetBatchStatisticsRequest();\r\n\t\t\tbreak;\r\n\t\tcase GET_UNSETTLED_TRANSACTION_LIST :\r\n\t\t\tgetUnsettledTransactionListRequest();\r\n\t\t\tbreak;\r\n\t\tdefault:\r\n\t\t\tbreak;\r\n\t\t}\r\n\r\n\t\treturn currentRequest.dump();\r\n\t}",
"@Override\n public ServiceResponse send(final ServiceRequest request, final ServiceRequestSerializer serializer,\n final ServiceResponseDeserializer deserializer) throws SOAPException {\n return this.soapClient.send(request, this.getTargetUrl(), serializer, deserializer);\n }",
"private org.apache.axiom.soap.SOAPEnvelope toEnvelope(org.apache.axiom.soap.SOAPFactory factory, com.drore.cloud.tdp.service.IWsPmsSdkServiceStub.DoControl param, boolean optimizeContent)\n throws org.apache.axis2.AxisFault{\n\n \n try{\n\n org.apache.axiom.soap.SOAPEnvelope emptyEnvelope = factory.getDefaultEnvelope();\n emptyEnvelope.getBody().addChild(param.getOMElement(com.drore.cloud.tdp.service.IWsPmsSdkServiceStub.DoControl.MY_QNAME,factory));\n return emptyEnvelope;\n } catch(org.apache.axis2.databinding.ADBException e){\n throw org.apache.axis2.AxisFault.makeFault(e);\n }\n \n\n }",
"public void writeSoapMessage(SOAPMessage message);",
"private org.apache.axiom.soap.SOAPEnvelope toEnvelope(org.apache.axiom.soap.SOAPFactory factory, com.drore.cloud.tdp.service.IWsPmsSdkServiceStub.GetVehicleBookPage param, boolean optimizeContent)\n throws org.apache.axis2.AxisFault{\n\n \n try{\n\n org.apache.axiom.soap.SOAPEnvelope emptyEnvelope = factory.getDefaultEnvelope();\n emptyEnvelope.getBody().addChild(param.getOMElement(com.drore.cloud.tdp.service.IWsPmsSdkServiceStub.GetVehicleBookPage.MY_QNAME,factory));\n return emptyEnvelope;\n } catch(org.apache.axis2.databinding.ADBException e){\n throw org.apache.axis2.AxisFault.makeFault(e);\n }\n \n\n }",
"@Override\n public Map<String, XmlObject> generateXmlStream(KraPersistableBusinessObjectBase printableBusinessObject,\n Map<String, Object> reportParameters) {\n\n Map<String, XmlObject> xmlObjectList = new LinkedHashMap<String, XmlObject>();\n try {\n SubContractDataDocument subContractDataDoc = SubContractDataDocument.Factory.newInstance();\n SubContractData subContractData = SubContractData.Factory.newInstance();\n SubAward subaward = (SubAward) printableBusinessObject;\n this.awardNumber = (String) reportParameters.get(\"awardNumber\");\n this.awardTitle = (String) reportParameters.get(\"awardTitle\");\n this.sponsorAwardNumber = (String) reportParameters.get(\"sponsorAwardNumber\");\n this.sponsorName = (String) reportParameters.get(\"sponsorName\");\n this.cfdaNumber = (String) reportParameters.get(\"cfdaNumber\");\n this.awardID = (Long) reportParameters.get(\"awardID\");\n this.sponsorTemplates = (List<SubAwardForms>) reportParameters.get(SubAwardPrintingService.SELECTED_TEMPLATES);\n setSubcontractTemplateInfo(subContractData, subaward);\n setFundingSource(subContractData, subaward);\n setSubcontractDetail(subContractData, subaward);\n setSubcontractAmountInfo(subContractData, subaward);\n setAwardHeader(subContractData, subaward);\n setPrimeRecipientContacts(subContractData, subaward);\n setPrintRequirement(subContractData, subaward);\n setPrimeAdministrativeContact(subContractData, subaward);\n setPrimePrincipalInvestigator(subContractData, subaward);\n setPrimeFinancialContact(subContractData, subaward);\n setPrimeAuthorizedOfficial(subContractData, subaward);\n setAdministrativeContact(subContractData, subaward);\n setFinancialContact(subContractData, subaward);\n setAuthorizedOfficial(subContractData, subaward);\n setSubcontractReports(subContractData, subaward);\n subContractDataDoc.setSubContractData(subContractData);\n xmlObjectList.put(Constants.SUBAWARD_PRINT_TYPE_FDP_TEMPLATE, subContractDataDoc);\n } catch (Exception e) {\n e.printStackTrace();\n }\n return xmlObjectList;\n }",
"@WebService(name = \"CreditReportServiceDelegate\", targetNamespace = \"http://webservice.icrqs.cfcc.com/\")\n@SOAPBinding(style = SOAPBinding.Style.RPC)\n@XmlSeeAlso({\n ObjectFactory.class\n})\npublic interface CreditReportServiceDelegate {\n\n\n /**\n * \n * @param arg0\n * @return\n * returns com.cfcc.icrqs.webservice.CuResult\n */\n @WebMethod\n @WebResult(partName = \"return\")\n public CuResult sendCuRequest(\n @WebParam(name = \"arg0\", partName = \"arg0\")\n CuSingleRequest arg0);\n\n /**\n * \n * @param arg0\n * @return\n * returns com.cfcc.icrqs.webservice.CuSingleResult\n */\n @WebMethod\n @WebResult(partName = \"return\")\n public CuSingleResult getCuResult(\n @WebParam(name = \"arg0\", partName = \"arg0\")\n CuGetResult arg0);\n\n}",
"private org.apache.axiom.soap.SOAPEnvelope toEnvelope(org.apache.axiom.soap.SOAPFactory factory, net.wit.webservice.TerminalServiceXmlServiceStub.QqCharge param, boolean optimizeContent, javax.xml.namespace.QName methodQName)\n throws org.apache.axis2.AxisFault{\n\n \n try{\n\n org.apache.axiom.soap.SOAPEnvelope emptyEnvelope = factory.getDefaultEnvelope();\n emptyEnvelope.getBody().addChild(param.getOMElement(net.wit.webservice.TerminalServiceXmlServiceStub.QqCharge.MY_QNAME,factory));\n return emptyEnvelope;\n } catch(org.apache.axis2.databinding.ADBException e){\n throw org.apache.axis2.AxisFault.makeFault(e);\n }\n \n\n }",
"public void feeReport(lnrpc.Rpc.FeeReportRequest request,\n io.grpc.stub.StreamObserver<lnrpc.Rpc.FeeReportResponse> responseObserver) {\n asyncUnimplementedUnaryCall(getFeeReportMethod(), responseObserver);\n }",
"public org.pahospital.www.radiologyservice.RadiologyServiceStub.Appointment requestAppointment(\n\n org.pahospital.www.radiologyservice.RadiologyServiceStub.Appointment appointment2)\n \n\n throws java.rmi.RemoteException\n \n {\n org.apache.axis2.context.MessageContext _messageContext = null;\n try{\n org.apache.axis2.client.OperationClient _operationClient = _serviceClient.createClient(_operations[0].getName());\n _operationClient.getOptions().setAction(\"http://www.PAHospital.org/RadiologyService/RequestAppointment\");\n _operationClient.getOptions().setExceptionToBeThrownOnSOAPFault(true);\n\n \n \n addPropertyToOperationClient(_operationClient,org.apache.axis2.description.WSDL2Constants.ATTR_WHTTP_QUERY_PARAMETER_SEPARATOR,\"&\");\n \n\n // create a message context\n _messageContext = new org.apache.axis2.context.MessageContext();\n\n \n\n // create SOAP envelope with that payload\n org.apache.axiom.soap.SOAPEnvelope env = null;\n \n \n env = toEnvelope(getFactory(_operationClient.getOptions().getSoapVersionURI()),\n appointment2,\n optimizeContent(new javax.xml.namespace.QName(\"http://www.PAHospital.org/RadiologyService/\",\n \"requestAppointment\")), new javax.xml.namespace.QName(\"http://www.PAHospital.org/RadiologyService/\",\n \"requestAppointment\"));\n \n //adding SOAP soap_headers\n _serviceClient.addHeadersToEnvelope(env);\n // set the message context with that soap envelope\n _messageContext.setEnvelope(env);\n\n // add the message contxt to the operation client\n _operationClient.addMessageContext(_messageContext);\n\n //execute the operation client\n _operationClient.execute(true);\n\n \n org.apache.axis2.context.MessageContext _returnMessageContext = _operationClient.getMessageContext(\n org.apache.axis2.wsdl.WSDLConstants.MESSAGE_LABEL_IN_VALUE);\n org.apache.axiom.soap.SOAPEnvelope _returnEnv = _returnMessageContext.getEnvelope();\n \n \n java.lang.Object object = fromOM(\n _returnEnv.getBody().getFirstElement() ,\n org.pahospital.www.radiologyservice.RadiologyServiceStub.Appointment.class,\n getEnvelopeNamespaces(_returnEnv));\n\n \n return (org.pahospital.www.radiologyservice.RadiologyServiceStub.Appointment)object;\n \n }catch(org.apache.axis2.AxisFault f){\n\n org.apache.axiom.om.OMElement faultElt = f.getDetail();\n if (faultElt!=null){\n if (faultExceptionNameMap.containsKey(new org.apache.axis2.client.FaultMapKey(faultElt.getQName(),\"RequestAppointment\"))){\n //make the fault by reflection\n try{\n java.lang.String exceptionClassName = (java.lang.String)faultExceptionClassNameMap.get(new org.apache.axis2.client.FaultMapKey(faultElt.getQName(),\"RequestAppointment\"));\n java.lang.Class exceptionClass = java.lang.Class.forName(exceptionClassName);\n java.lang.reflect.Constructor constructor = exceptionClass.getConstructor(String.class);\n java.lang.Exception ex = (java.lang.Exception) constructor.newInstance(f.getMessage());\n //message class\n java.lang.String messageClassName = (java.lang.String)faultMessageMap.get(new org.apache.axis2.client.FaultMapKey(faultElt.getQName(),\"RequestAppointment\"));\n java.lang.Class messageClass = java.lang.Class.forName(messageClassName);\n java.lang.Object messageObject = fromOM(faultElt,messageClass,null);\n java.lang.reflect.Method m = exceptionClass.getMethod(\"setFaultMessage\",\n new java.lang.Class[]{messageClass});\n m.invoke(ex,new java.lang.Object[]{messageObject});\n \n\n throw new java.rmi.RemoteException(ex.getMessage(), ex);\n }catch(java.lang.ClassCastException e){\n // we cannot intantiate the class - throw the original Axis fault\n throw f;\n } catch (java.lang.ClassNotFoundException e) {\n // we cannot intantiate the class - throw the original Axis fault\n throw f;\n }catch (java.lang.NoSuchMethodException e) {\n // we cannot intantiate the class - throw the original Axis fault\n throw f;\n } catch (java.lang.reflect.InvocationTargetException e) {\n // we cannot intantiate the class - throw the original Axis fault\n throw f;\n } catch (java.lang.IllegalAccessException e) {\n // we cannot intantiate the class - throw the original Axis fault\n throw f;\n } catch (java.lang.InstantiationException e) {\n // we cannot intantiate the class - throw the original Axis fault\n throw f;\n }\n }else{\n throw f;\n }\n }else{\n throw f;\n }\n } finally {\n if (_messageContext.getTransportOut() != null) {\n _messageContext.getTransportOut().getSender().cleanup(_messageContext);\n }\n }\n }",
"private void generateIncomingReport() {\r\n\r\n\t\tStringBuilder stringBuilder = new StringBuilder();\r\n\t\tstringBuilder.append(\"\\n----------------------------------------\\n\")\r\n\t\t\t\t.append(\" Incoming Daily Amount \\n\")\r\n\t\t\t\t.append(\"----------------------------------------\\n\")\r\n\t\t\t\t.append(\" Date | Trade Amount \\n\")\r\n\t\t\t\t.append(\"-----------------+----------------------\\n\");\r\n\t\tallIncomings.entrySet().forEach(\r\n\t\t\t\tkey -> stringBuilder.append(key.getKey() + \" | \" + key.getValue().get() + \"\\n\"));\r\n\t\tdataWriter.write(stringBuilder.toString());\r\n\t}",
"private org.apache.axiom.soap.SOAPEnvelope toEnvelope(org.apache.axiom.soap.SOAPFactory factory, net.wit.webservice.TerminalServiceXmlServiceStub.GetDownLoadCard param, boolean optimizeContent, javax.xml.namespace.QName methodQName)\n throws org.apache.axis2.AxisFault{\n\n \n try{\n\n org.apache.axiom.soap.SOAPEnvelope emptyEnvelope = factory.getDefaultEnvelope();\n emptyEnvelope.getBody().addChild(param.getOMElement(net.wit.webservice.TerminalServiceXmlServiceStub.GetDownLoadCard.MY_QNAME,factory));\n return emptyEnvelope;\n } catch(org.apache.axis2.databinding.ADBException e){\n throw org.apache.axis2.AxisFault.makeFault(e);\n }\n \n\n }",
"public static CloseableHttpResponse postSoapRequest(String requestXml,String baseURI) {\r\n\r\n\t\tCloseableHttpResponse response = null;\r\n\r\n\t\ttry {\r\n\r\n\t\t\tFile requestFile=new File(\".\\\\SoapRequest\\\\\"+requestXml+\".xml\");\r\n\r\n\t\t\tCredentialsProvider provider=basicAuthentication(\"extsystemuser\",\"rules\");\r\n\r\n\t\t\tCloseableHttpClient client= HttpClientBuilder.create().setDefaultCredentialsProvider(provider).build();\r\n\r\n\t\t\tHttpPost request=new HttpPost(baseURI);\r\n\r\n\t\t\trequest.addHeader(\"Content-Type\", \"text/xml\");\r\n\r\n\t\t\tHttpEntity entity=new InputStreamEntity(new FileInputStream(requestFile));\r\n\r\n\t\t\tBufferedHttpEntity bEntity=new BufferedHttpEntity(entity);\r\n\r\n\t\t\trequest.setEntity(bEntity);\r\n\r\n\t\t\tresponse=client.execute(request);\r\n\r\n\t\t} catch (FileNotFoundException e) {\r\n\r\n\t\t\te.printStackTrace();\r\n\r\n\t\t} catch (ClientProtocolException e) {\r\n\r\n\t\t\te.printStackTrace();\r\n\r\n\t\t} catch (IOException e) {\r\n\r\n\t\t\te.printStackTrace();\r\n\r\n\t\t}\r\n\r\n\t\treturn response;\r\n\r\n\r\n\r\n\t}",
"@RequestMapping(value = { \"/printReport.xls\" }, method = RequestMethod.POST)\r\n\tpublic void payOther(HttpServletRequest request, HttpServletResponse response) throws Exception {\n\r\n\t\tString rptCode = request.getParameter(\"rptCode\");\r\n\t\tString pathFile = request.getSession().getServletContext().getRealPath(\"/report/excel/\" + rptCode + \".xls\");\r\n\t\tFileInputStream input_document = new FileInputStream(new File(pathFile));\r\n\t\tWorkbook workbook = new HSSFWorkbook(input_document);\r\n\t\tReportBean bean = new ReportBean();\r\n\r\n\t\tinput_document.close();\r\n\t\tByteArrayOutputStream byteArrayOutputStream = new ByteArrayOutputStream();\r\n\t\t\r\n\t\tif(creteria != null) {\r\n//\t\t\t result = paymentManualService.findPayOrder(creteria);\r\n\t\t }\r\n\t\t\r\n\t\treportService.controlAllReports(workbook, rptCode, bean).write(byteArrayOutputStream);\r\n\t\tbyte[] bytes = byteArrayOutputStream.toByteArray();\r\n\r\n\t\tresponse.setContentType(\"application/vnd.ms-excel\");\r\n\t\tresponse.setHeader(\"Content-Disposition\", \"attachment;filename=\" + rptCode+\".xls\");\r\n\t\tresponse.getOutputStream().write(bytes);\r\n\t\tresponse.getOutputStream().flush();\r\n\t}",
"private org.apache.axiom.soap.SOAPEnvelope toEnvelope(org.apache.axiom.soap.SOAPFactory factory, net.wit.webservice.TerminalServiceXmlServiceStub.DirectQuery param, boolean optimizeContent, javax.xml.namespace.QName methodQName)\n throws org.apache.axis2.AxisFault{\n\n \n try{\n\n org.apache.axiom.soap.SOAPEnvelope emptyEnvelope = factory.getDefaultEnvelope();\n emptyEnvelope.getBody().addChild(param.getOMElement(net.wit.webservice.TerminalServiceXmlServiceStub.DirectQuery.MY_QNAME,factory));\n return emptyEnvelope;\n } catch(org.apache.axis2.databinding.ADBException e){\n throw org.apache.axis2.AxisFault.makeFault(e);\n }\n \n\n }",
"@RequestMapping(value = \"/report\", method = RequestMethod.POST)\n\t@ResponseBody\n\tString getReport(HttpServletRequest request, HttpServletResponse response) {\n\n\t\t// Get the Logged in User\n\t\tString name = getLoggedUser();\n\n\t\tString email = request.getParameter(\"email\");\n\t\tRetrieveItems ri = new RetrieveItems(env);\n\t\tList<WorkItem> theList = ri.getItemsDataSQLReport(name);\n\t\tWriteExcel writeExcel = new WriteExcel();\n\t\tSendMessages sm = new SendMessages(env);\n\t\tjava.io.InputStream is = writeExcel.exportExcel(theList);\n\n\t\ttry {\n\t\t\tsm.sendReport(is, email);\n\t\t}catch (IOException e) {\n\t\t\te.getStackTrace();\n\t\t}\n\t\treturn \"Report is created\";\n\t}",
"private Message buildMessageToCXFBC(String serviceType,\tList<String> payload, String operationName) {\n\t\tMessage requestMessageToESB = new Message();\n\t\ttry {\n//\t\t\t Create and set the metadata\n\t\t\tgov.nih.nci.caxchange.messaging.Metadata metadata = new gov.nih.nci.caxchange.messaging.Metadata();\n\t\t\tmetadata.setTransactionControl(TransactionControls.PROCESS);\n\t\t\t/*\n\t\t\tCredentials credentials = new Credentials();\n\t\t\tcredentials.setUserName(\"[email protected]\");\n\t\t\tcredentials.setPassword(\"[email protected]\");\n\t\t\tmetadata.setCredentials(credentials);\n\t\t\t*/\n\t\t\t//metadata.setCaXchangeIdentifier(\"037068f0-23a8-11de-a5f1-d00caf9050fd\");\n\t\t\tmetadata.setExternalIdentifier(\"caExternalIdentifier\");\n\t\t\tmetadata.setOperationName(new ObjectFactory().createMetadataOperationName(operationName));\n\t\t\tmetadata.setServiceType(serviceType);\n\t\t\trequestMessageToESB.setMetadata(metadata);\n\t\t\t\n//\t\t\t Create and set the request\n\t\t\tRequest request = new Request();\n\t\t\tMessagePayload messagePayload = new MessagePayload();\n\t\t\tmessagePayload.setXmlSchemaDefinition(\"\");\n\t\t\tDocumentBuilderFactory dbf = DocumentBuilderFactory.newInstance();\n\t\t\tdbf.setNamespaceAware(true);\n\t\t\tDocumentBuilder db = dbf.newDocumentBuilder();\n\t\t\t\n\t\t\t//InputStream message = new ByteArrayInputStream(payload.get(0).getBytes());;\n\t\t\t\n\t\t\tfor(int i=0;i < payload.size() ; i++){ \n\t\t\t\tInputStream message = new ByteArrayInputStream(payload.get(i).getBytes());\n\t\t\t\tDocument payloadDoc = db.parse(message);\n\t\t\t\tmessagePayload.getAny().add(payloadDoc.getDocumentElement());\n\t\t\t}\t\n\t\t\t\n\t\t\t//Document payloadDoc = db.parse(message);\n\t\t//\tmessagePayload.setAny(payloadDoc.getDocumentElement());\n\t\t\trequest.setBusinessMessagePayload(messagePayload);\n\n\t\t\trequestMessageToESB.setRequest(request);\n\n\t\t} catch (Exception e) {\n\t\t\tlog.error(\"Exception building payload\" + e);\n\t\t\t//e.printStackTrace();\n\t\t}\n\n\t\treturn requestMessageToESB;\n\t}",
"public org.apache.axis2.databinding.types.soapencoding.String getRequestXml(){\n return localRequestXml;\n }",
"public org.apache.axis2.databinding.types.soapencoding.String getRequestXml(){\n return localRequestXml;\n }",
"public org.apache.axis2.databinding.types.soapencoding.String getRequestXml(){\n return localRequestXml;\n }",
"public org.apache.axis2.databinding.types.soapencoding.String getRequestXml(){\n return localRequestXml;\n }",
"public org.apache.axis2.databinding.types.soapencoding.String getRequestXml(){\n return localRequestXml;\n }",
"public org.apache.axis2.databinding.types.soapencoding.String getRequestXml(){\n return localRequestXml;\n }",
"public org.apache.axis2.databinding.types.soapencoding.String getRequestXml(){\n return localRequestXml;\n }",
"public org.apache.axis2.databinding.types.soapencoding.String getRequestXml(){\n return localRequestXml;\n }",
"public org.apache.axis2.databinding.types.soapencoding.String getRequestXml(){\n return localRequestXml;\n }",
"public org.apache.axis2.databinding.types.soapencoding.String getRequestXml(){\n return localRequestXml;\n }",
"public org.apache.axis2.databinding.types.soapencoding.String getRequestXml(){\n return localRequestXml;\n }",
"public static Map<String, Object> createInvoicesFromShipment(DispatchContext dctx, Map<String, Object> context) {\n Delegator delegator = dctx.getDelegator();\n LocalDispatcher dispatcher = dctx.getDispatcher();\n String shipmentId = (String) context.get(\"shipmentId\");\n Locale locale = (Locale) context.get(\"locale\");\n List<String> invoicesCreated;\n Map<String, Object> response = ServiceUtil.returnSuccess();\n GenericValue orderShipment = null;\n String invoicePerShipment = null;\n\n try {\n orderShipment = EntityQuery.use(delegator).from(\"OrderShipment\").where(\"shipmentId\", shipmentId).queryFirst();\n } catch (GenericEntityException e) {\n return ServiceUtil.returnError(e.getMessage());\n }\n\n if (orderShipment != null) {\n String orderId = orderShipment.getString(\"orderId\");\n try {\n GenericValue orderHeader = EntityQuery.use(delegator).from(\"OrderHeader\").where(\"orderId\", orderId).queryOne();\n invoicePerShipment = orderHeader.getString(\"invoicePerShipment\");\n } catch (GenericEntityException e) {\n return ServiceUtil.returnError(e.getMessage());\n }\n }\n\n // Either no orderShipment exists, or there's a null invoicePerShipment in the OrderHeader.\n // In either case, use the default value from the properties\n if (invoicePerShipment == null) {\n invoicePerShipment = EntityUtilProperties.getPropertyValue(\"accounting\", \"create.invoice.per.shipment\", delegator);\n }\n\n if (\"Y\".equals(invoicePerShipment)) {\n Map<String, Object> serviceContext = UtilMisc.toMap(\"shipmentIds\", UtilMisc.toList(shipmentId), \"eventDate\", context.get(\"eventDate\"),\n \"userLogin\", context.get(\"userLogin\"));\n try {\n Map<String, Object> result = dispatcher.runSync(\"createInvoicesFromShipments\", serviceContext);\n if (ServiceUtil.isError(result)) {\n return ServiceUtil.returnError(UtilProperties.getMessage(RESOURCE,\n \"AccountingTroubleCallingCreateInvoicesFromShipmentService\",\n UtilMisc.toMap(\"shipmentId\", shipmentId), locale));\n }\n invoicesCreated = UtilGenerics.cast(result.get(\"invoicesCreated\"));\n } catch (GenericServiceException e) {\n Debug.logError(e, \"Trouble calling createInvoicesFromShipment service; invoice not created for shipment [\" + shipmentId + \"]\",\n MODULE);\n return ServiceUtil.returnError(UtilProperties.getMessage(RESOURCE,\n \"AccountingTroubleCallingCreateInvoicesFromShipmentService\",\n UtilMisc.toMap(\"shipmentId\", shipmentId), locale));\n }\n response.put(\"invoicesCreated\", invoicesCreated);\n }\n return response;\n }",
"void createReport(Report report);",
"private void reset() {\n // TODO add your handling code here:\n MyObject m = new Mockups().singlePayout();\n\n String body = \"<ns1:SinglePayoutRequest>\\n\"\n + \"\t<ns1:CardPayoutRequest>\\n\"\n + \"\t\t<ns1:Account>\\n\"\n + \"\t\t\t<ns1:PayGateId>\" + m.getProperty(\"payGateID\") + \"</ns1:PayGateId>\\n\"\n + \"\t\t\t<ns1:Password>\" + m.getProperty(\"password\") + \"</ns1:Password>\\n\"\n + \"\t\t</ns1:Account>\\n\"\n + \"\t\t<ns1:Customer>\\n\"\n + \"\t\t\t<ns1:FirstName>\" + m.getProperty(\"firstname\") + \"</ns1:FirstName>\\n\"\n + \"\t\t\t<ns1:LastName>\" + m.getProperty(\"lastname\") + \"</ns1:LastName>\\n\"\n + \"\t\t\t<ns1:Email>\" + m.getProperty(\"email\") + \"</ns1:Email>\\n\"\n + \"\t\t</ns1:Customer>\\n\"\n + \"\t\t<ns1:CardNumber>\" + m.getProperty(\"cardNumber\") + \"</ns1:CardNumber>\\n\"\n + \"\t\t<ns1:CardExpiryDate>\" + m.getProperty(\"cardExpDate\") + \"</ns1:CardExpiryDate>\\n\"\n + \"\t\t<ns1:Order>\\n\"\n + \"\t\t\t<ns1:MerchantOrderId>\" + m.getProperty(\"merchantOrderID\") + \"</ns1:MerchantOrderId>\\n\"\n + \"\t\t\t<ns1:Currency>\" + m.getProperty(\"currency\") + \"</ns1:Currency>\\n\"\n + \"\t\t\t<ns1:Amount>\" + m.getProperty(\"amount\") + \"</ns1:Amount>\\n\"\n + \"\t\t</ns1:Order>\\n\"\n + \"\t</ns1:CardPayoutRequest>\\n\"\n + \"</ns1:SinglePayoutRequest>\\n\";\n payGateIDField.setText((String) m.getProperty(\"payGateID\"));\n passwordField.setText((String) m.getProperty(\"password\"));\n firstnameField.setText((String) m.getProperty(\"firstname\"));\n lastnameField.setText((String) m.getProperty(\"lastname\"));\n emailField.setText((String) m.getProperty(\"email\"));\n cardNumberField.setText((String) m.getProperty(\"cardNumber\"));\n cardExpiryDateField.setText((String) m.getProperty(\"cardExpiryDate\"));\n merchantOrderIDField.setText((String) m.getProperty(\"merchantOrderID\"));\n currencyField.setText((String) m.getProperty(\"currency\"));\n amountField.setText((String) m.getProperty(\"amount\"));\n requestArea.setText(body);\n }",
"private org.apache.axiom.soap.SOAPEnvelope toEnvelope(org.apache.axiom.soap.SOAPFactory factory, net.wit.webservice.TerminalServiceXmlServiceStub.TerminalReturnCard param, boolean optimizeContent, javax.xml.namespace.QName methodQName)\n throws org.apache.axis2.AxisFault{\n\n \n try{\n\n org.apache.axiom.soap.SOAPEnvelope emptyEnvelope = factory.getDefaultEnvelope();\n emptyEnvelope.getBody().addChild(param.getOMElement(net.wit.webservice.TerminalServiceXmlServiceStub.TerminalReturnCard.MY_QNAME,factory));\n return emptyEnvelope;\n } catch(org.apache.axis2.databinding.ADBException e){\n throw org.apache.axis2.AxisFault.makeFault(e);\n }\n \n\n }",
"public static Payload convert(Request request) {\n \n Metadata newMeta = Metadata.newBuilder().setType(request.getClass().getSimpleName())\n .setClientIp(NetUtils.localIP()).putAllHeaders(request.getHeaders()).build();\n \n byte[] jsonBytes = convertRequestToByte(request);\n \n Payload.Builder builder = Payload.newBuilder();\n \n return builder\n .setBody(Any.newBuilder().setValue(UnsafeByteOperations.unsafeWrap(jsonBytes)))\n .setMetadata(newMeta).build();\n \n }",
"private ReportRequest getAdGroupReport(Calendar from, Calendar to) {\r\n\t\tAdGroupPerformanceReportRequest request = new AdGroupPerformanceReportRequest();\r\n\t\trequest.setFormat(ReportFormat.CSV);\r\n\t\trequest.setReportName(\"Ad Group Report\");\r\n\t\trequest.setAggregation(ReportAggregation.HOURLY);\r\n\t\trequest.setReturnOnlyCompleteData(false);\r\n\r\n\t\tAccountThroughAdGroupReportScope scope = new AccountThroughAdGroupReportScope();\r\n\t\tArrayOflong accountIds = new ArrayOflong();\r\n\t\taccountIds.getLongs().add(authorizationData.getAccountId());\r\n\t\tscope.setAccountIds(accountIds);\r\n\t\tscope.setCampaigns(null);\r\n\t\tscope.setAdGroups(null); \r\n\t\trequest.setScope(scope);\r\n\r\n\t\tArrayOfAdGroupPerformanceReportColumn value = new ArrayOfAdGroupPerformanceReportColumn();\r\n\t\tList<AdGroupPerformanceReportColumn> columns = value.getAdGroupPerformanceReportColumns();\r\n\t\tString adFields = adsProperties.getProperty(\"api.bing.adGroupPerformanceReport.fields\");\r\n\t\tif (adFields != null && adFields.length() > 2) {\r\n\t\t\tfor (String fieldId : adFields.split(\",\")) {\r\n\t\t\t\tcolumns.add(AdGroupPerformanceReportColumn.fromValue(fieldId));\r\n\t\t\t}\r\n\t\t} else {\r\n\t\t\tcolumns.add(AdGroupPerformanceReportColumn.AD_GROUP_ID);\r\n\t\t\tcolumns.add(AdGroupPerformanceReportColumn.AD_GROUP_NAME);\r\n\t\t\tcolumns.add(AdGroupPerformanceReportColumn.CAMPAIGN_ID);\r\n\t\t\tcolumns.add(AdGroupPerformanceReportColumn.CAMPAIGN_NAME);\r\n\t\t\tcolumns.add(AdGroupPerformanceReportColumn.TIME_PERIOD);\r\n\t\t\tcolumns.add(AdGroupPerformanceReportColumn.CLICKS);\r\n\t\t\tcolumns.add(AdGroupPerformanceReportColumn.COST_PER_CONVERSION);\r\n\t\t\tcolumns.add(AdGroupPerformanceReportColumn.SPEND);\r\n\t\t\tcolumns.add(AdGroupPerformanceReportColumn.CONVERSION_RATE);\r\n\t\t\tcolumns.add(AdGroupPerformanceReportColumn.IMPRESSIONS);\r\n\t\t}\r\n\t\trequest.setColumns(value);\r\n\r\n\t\tReportTime reportTime = new ReportTime();\r\n\t\tDate start = new Date();\r\n\t\tDate end = new Date();\r\n\t\tstart.setDay(from.get(Calendar.DAY_OF_MONTH));\r\n\t\tstart.setMonth(from.get(Calendar.MONTH)+1);\r\n\t\tstart.setYear(from.get(Calendar.YEAR));\r\n\t\tend.setDay(to.get(Calendar.DAY_OF_MONTH));\r\n\t\tend.setMonth(to.get(Calendar.MONTH)+1);\r\n\t\tend.setYear(to.get(Calendar.YEAR));\r\n\t\treportTime.setCustomDateRangeStart(start);\r\n\t\treportTime.setCustomDateRangeEnd(end);\r\n\t\trequest.setTime(reportTime);\r\n\r\n\t\treturn request;\r\n\t}",
"public ReportSheet createReport(RepletRequest req) throws RepletException\n {\n ss = (StyleSheet) theReport;\n try\n {\n bindMessages(req);\n bindData(req);\n }\n catch (Exception e)\n {\n ReportsPackage.logError(\"Problem creating report\", e);\n throw new RepletException(e.getMessage());\n }\n return theReport;\n }",
"private org.apache.axiom.soap.SOAPEnvelope toEnvelope(org.apache.axiom.soap.SOAPFactory factory, sample.ws.HelloWorldWSStub.HelloAuthenticatedWithEntitlementPrecheck param, boolean optimizeContent)\n throws org.apache.axis2.AxisFault{\n\n \n try{\n\n org.apache.axiom.soap.SOAPEnvelope emptyEnvelope = factory.getDefaultEnvelope();\n emptyEnvelope.getBody().addChild(param.getOMElement(sample.ws.HelloWorldWSStub.HelloAuthenticatedWithEntitlementPrecheck.MY_QNAME,factory));\n return emptyEnvelope;\n } catch(org.apache.axis2.databinding.ADBException e){\n throw org.apache.axis2.AxisFault.makeFault(e);\n }\n \n\n }",
"@WebService(name = \"DeliveryService\")\npublic interface DeliveryService {\n\n @WebResult(name = \"DeliveryService_provide_customer_data\")\n Customer provideCustomerShipmentData(\n @WebParam(name = \"orderId\") int orderId,\n @WebParam(name = \"firstname\") String firstname,\n @WebParam(name = \"lastname\") String lastname,\n @WebParam(name = \"address\") String address,\n @WebParam(name = \"zipcode\") String zipcode,\n @WebParam(name = \"city\") String city,\n @WebParam(name = \"country\") String country,\n @WebParam(name = \"phone\") String phone,\n @WebParam(name = \"email\") String email\n ) throws ContentNotFoundException, RequestFailException, RestrictedFonctionalityException;\n\n @WebResult(name = \"DeliveryService_choose_delivery\")\n Delivery chooseDeliveryMode(\n @WebParam(name = \"orderId\") int orderId,\n @WebParam(name = \"deliveryId\") int deliveryId\n ) throws ContentNotFoundException, RequestFailException, RestrictedFonctionalityException;\n\n}",
"Report createReport();",
"private OrderBustReinstateReportStruct processOrderBustReinstateReport(\n\t\t\tExecutionReport execReport, FixSessionImpl session)\n\tthrows DataValidationException {\n\t\treturn FixExecutionReportToCmiMapper.mapToOrderBustReinstateReportStruct(\n\t\t\t\texecReport, session.getDoNotSendValue());\n\t}",
"@Override\n protected void writeRequest(final XmlRpcStreamTransport.ReqWriter pWriter) throws XmlRpcException {\n final ByteArrayOutputStream baos = new ByteArrayOutputStream();\n try {\n pWriter.write(baos);\n }\n catch (SAXException e) {\n }\n catch (IOException e) {\n }\n LOG.debug(\"Send request=\\n{}\", XmlPrettyFormatter.toPrettyString(baos.toString()));\n super.writeRequest(pWriter);\n }",
"@RequestMapping(value = {\"/get-all-CTopUpPaymentsReceivedReport\"}, method = RequestMethod.POST)\n\t @CrossOrigin(origins = \"*\", allowCredentials = \"true\")\n\t @ResponseBody\n\t public String getAllChannelsReport(HttpServletRequest request, HttpServletResponse response) {\n\t\t String region=request.getParameter(\"region\");\n\t\t String city=request.getParameter(\"city\");\n\t\t String searchType=request.getParameter(\"searchType\");\n\t\t String msisdn=request.getParameter(\"msisdn\");\n\t\t String fromDate=request.getParameter(\"fromDate\");\n\t\t String toDate=request.getParameter(\"toDate\");\n\t\t String wallet=\"CTOPUP\";\n\t\t String zone=\"South Zone\";\n\t\t\n\t\t\tSystem.out.println(\"wallet ::\"+wallet);\n\t\t\tSystem.out.println(\"region::\"+region);\n\t\t\tSystem.out.println(\"city::\"+city);\n\t\t\tSystem.out.println(\"searchType::\"+searchType);\n\t\t\tSystem.out.println(\"msisdn::\"+msisdn);\n\t\t\t//System.out.println(\"search Type11::\"+searchType11);\n\t\t\tSystem.out.println(\"From Date1::\"+fromDate);\n\t\t\tSystem.out.println(\"To Date::\"+toDate);\n\t \t\n\t String json;\n\t try {\n\t \tSystem.out.println(\"========================home controller===================================\");\n\t ResponseList<CTopUpPaymentsReceivedReportBean> lstInvoices =new ResponseList<CTopUpPaymentsReceivedReportBean>();\n\t lstInvoices.addAll(cTopUpPaymentsReceivedReportService.getAllCTOPUPaymentsReceivedReport(zone, region, city, msisdn, searchType, fromDate, toDate));\n\t json = lstInvoices.toString();\n\t System.out.println(\"json ::\"+json);\n\t } catch (Exception e) {\n\t json = \"{\\\"error\\\" : true, \\\"message\\\": \\\"\" + e.getMessage() + \".\\\"}\";\n\t }\n\t return json;\n\t }",
"public com.comcast.provisioning.provisioning_.dataobjects.PSDataObj getCDV(com.comcast.provisioning.provisioning_.types.SubmitProvisioningType submitProvisioningType,java.lang.String soapMsg,java.lang.String srcLob,Hashtable deliveryPlatform,XmlObject xmlObjOut)\n\t{\n\t\tlogger.info(\"Processing: VOICE Workorder..!!\");\n\t\tcom.comcast.provisioning.provisioning_.dataobjects.PSDataObj psObj=null;\n\t\tSubmitWorkOrderRequestType submitWorkOrderRequestType=null;\n\n\t\t/*try {\n\t\t\tif (submitProvisioningType != null && submitProvisioningType.getProvisioningAttributes() != null && submitProvisioningType.getProvisioningAttributes().getDwellingType() != null && submitProvisioningType.getProvisioningAttributes().getDwellingType().value() != null) {\n\t\t\t\tlogger.info(\"Dwellling type in request is not null \"+submitProvisioningType.getProvisioningAttributes().getDwellingType().value());\n\t\t\t\tif (submitProvisioningType.getProvisioningAttributes().getDwellingType().value().equals(\"TOPDOWN\")) {\n\t\t\t\t\tlogger.info(\"################### Calling CDV Service - activateCDVService ################\");\n\t\t\t\t\t//csProcessor.activateCDVService(soapMsg); NOT_REQUIRED\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tcatch (Exception e1) {\n\t\t\tlogger.warn(\"Exception in creating SubmitWorkOrderDocument..!!\"+e1.getMessage());\n\t\t\tthrow new RuntimeException(e1);\n\t\t}*/\n\n\n\t\t\tSubmitWorkOrder submitWorkOrder = marshallerUtil.convertToSubmitWorkOrder(xmlObjOut.toString());\n\n\t\tlogger.info(\"Extracting submitWorkOrderRequestType from document object..\");\n\t\tsubmitWorkOrderRequestType=submitWorkOrder.getSubmitWorkOrderRequestType();\n\t\tpsObj=cdvwoDataObj.cdvwoMapper(submitWorkOrderRequestType,submitProvisioningType,deliveryPlatform);\n\t\tcom.comcast.xml.cdvworkorder.types.SubmitWorkOrderRequestType instCDVWOReq=psObj.getSubmitWorkOrderRequestType();\n\t\tlogger.info(\"Calling CDVWO service with accountNumber=\"+instCDVWOReq.getAccountNumber()+\"..!!\");\n\t\ttry {\n\t\t\tSubmitWorkOrderResponseType CDVWORes=cdvWorkOrderServiceConnector.submitWorkOrder(instCDVWOReq);\n\t\t\tList<SubmitWorkOrderRespType> submitWorkOrderResp=CDVWORes.getSubmitWorkOrderRespType().getSubmitWorkOrderRespTypes();\n\t\t\tpsObj.setStatus(IMSConstants.PENDING);\n\t\t\tlogger.info(\"submitWorkOrderResp size\"+submitWorkOrderResp.size());\n\t\t\tlogger.info(\"psObj.isMCDV()=\"+psObj.isMCDV());\n\t\t\tif(psObj.isMCDV() && (submitWorkOrderResp.get(0).getWorkOrderStatus().equalsIgnoreCase(\"0\")))\n\t\t\t\t {\n\n\t\t\t\t\tpsObj.setCSUpdateRequired(true);\n\t\t\t\t\ttry\t{\n\t\t\t\t\t\t\tif(psObj.getTokens().size()>0)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tbeanMapper.mapICRequestSync(psObj);//TO_DO_LAKSHMAIAH\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tlogger.info(\"PhysicalTN size is \"+psObj.getPhysicalTN().size());\n\t\t\t\t\t\t\tif(psObj.getPhysicalTN().size()>0)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t//NPSDataObj npsData=new NPSDataObj();\n\t\t\t\t\t\t\t\t//npsData.callNPS(psObj.getPhysicalTN());//TO_DO_LAKSHMAIAH\n\t\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\t\tcatch(Exception e1)\t{\n\t\t\t\t\t\t\tlogger.error(\"Exception in parsing \"+e1.getMessage());\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tpsObj.setErrorText(\"Exceptino is ::\"+e1);\n\t\t\t\t\t\t\tpsObj.setErrorcode(\"981009\");\n\t\t\t\t\t\t\tpsObj.setStatus(IMSConstants.PARTIAL_SUCCESS);\n\t\t\t\t\t\t}\n\t\t\t\t }\n\t\t\t\n\t\t\tif(instCDVWOReq.getEnumActionType()!=null)\n\t\t\t{\n\t\t\t\t \n\t\t\t\tif(beanMapper.checkReqAttributeExist(instCDVWOReq.getEnumActionType().value(), IMSConstants.CANCEL_ACTIONS))\n\t\t\t\t{\n\t\t\t\t logger.info(\"Calling CS - ProcessCSUpdate \");\n\t\t\t\t csProcessor.processCSupdatesSRO(instCDVWOReq.getEnumActionType().value(),soapMsg);\n\t\t\t\t \n\t\t\t\t}\n\t\t\t}\n\t\t}\t/*catch(com.comcast.xml.types.ExceptionType et){\n\t\t\teCustExceptionParsingcdvwo(et,psObj);\n\t\t} catch (RemoteException e) {\n\t\t\t\n\t\t\tString status=\"FAILED\";\n\t\t\tlogger.error(\"RemoteException occured\" + e.getMessage());\n\t\t\tpsObj.setErrorText(\"Exceptino is ::\"+e.getCause());\n\t\t\tpsObj.setErrorcode(\"981008\"); //network errors\n\t\t\tpsObj.setStatus(status);\n\t\t}*/\n\t\tcatch (Exception e) {\n\t\t\t\n\t\t\tString status=\"FAILED\";\n\t\t\tif(e!=null)\n\t\t\t\tlogger.error(\"Exception occured and message is \" + e.getMessage());\n\t\t\telse\n\t\t\t\tlogger.error(\"Exception occured while processing...!\");\n\t\t\tpsObj.setErrorText(\"Exceptino is ::\"+e);\n\t\t\tpsObj.setErrorcode(\"991009\"); //general errros\n\t\t\tpsObj.setStatus(status);\n\t\t}\n\t\ttry\t{\n\t\t\tcteProcessor.processCTERequest(instCDVWOReq.getEnumActionType().value(),submitWorkOrderRequestType);\n\n\t\t}\n\t\tcatch(Exception cteExcep){\n\t\t\tlogger.warn(\"Unable to update CTE DB\"+cteExcep.getMessage());\n\t\t}\n\t\tlogger.info(\"Successfully:Processed VOICE Workorder..!!\");\n\n\t\treturn psObj;\n\n\t}",
"public Report computeReportFromDifferencesToSend(Report report) {\r\n\t\tInferenceTypes instanceInfType = getInferenceType();\r\n\t\tInferenceTypes reportInfType = report.getInferenceType();\r\n\t\tPropositionSet instanceSupport = getSupport();\r\n\t\tPropositionSet reportSupport = report.getSupport();\r\n\t\tboolean supportCheck = instanceSupport.equals(reportSupport);\r\n\t\tif (instanceInfType == InferenceTypes.BACKWARD && reportInfType == InferenceTypes.FORWARD) {\r\n\t\t\treturn report;\r\n\t\t} else if (!supportCheck) {\r\n\t\t\tif (instanceInfType == InferenceTypes.FORWARD && reportInfType == InferenceTypes.BACKWARD)\r\n\t\t\t\treport.setInferenceType(InferenceTypes.FORWARD);\r\n\t\t\treturn report;\r\n\t\t}\r\n\t\treturn null;\r\n\t}",
"private org.apache.axiom.soap.SOAPEnvelope toEnvelope(org.apache.axiom.soap.SOAPFactory factory, net.wit.webservice.TerminalServiceXmlServiceStub.GetDirectAreaInfo param, boolean optimizeContent, javax.xml.namespace.QName methodQName)\n throws org.apache.axis2.AxisFault{\n\n \n try{\n\n org.apache.axiom.soap.SOAPEnvelope emptyEnvelope = factory.getDefaultEnvelope();\n emptyEnvelope.getBody().addChild(param.getOMElement(net.wit.webservice.TerminalServiceXmlServiceStub.GetDirectAreaInfo.MY_QNAME,factory));\n return emptyEnvelope;\n } catch(org.apache.axis2.databinding.ADBException e){\n throw org.apache.axis2.AxisFault.makeFault(e);\n }\n \n\n }",
"public void sendRequest(Class<?> cl, boolean simple) throws\n IOException,\n XmlPullParserException {\n \t\n \tLog.i(TAG, \"Sending SOAP request to \" + SERVER + \" and method \" + METHOD_NAME);\n \n // Variables for URL splitting\n String delimiter = \"/\";\n String PATH;\n String[] URLArray;\n String URL;\n \n // Split URL\n URLArray = SERVER.split(delimiter, 2);\n URL = URLArray[0];\n if (URLArray.length == 2) {\n PATH = delimiter + URLArray[1];\n } else {\n PATH = \"\";\n }\n \n /**\n * Use of KeepAliveHttpsTransport deals with the problems with the\n * Android ssl libraries having trouble with certificates and\n * certificate authorities somehow messing up connecting/needing\n * reconnects.\n */\n connection = new KeepAliveHttpsTransportSE(URL, 443, PATH, Constants.CONNECTION_TIMEOUT);\n SoapSerializationEnvelope envelope = new SoapSerializationEnvelope(\n SoapEnvelope.VER11);\n System.setProperty(\"http.keepAlive\", \"false\");\n envelope.encodingStyle = SoapEnvelope.ENC;\n envelope.setAddAdornments(false);\n envelope.implicitTypes = true;\n envelope.dotNet = false;\n envelope.setOutputSoapObject(request);\n \n if(cl != null) {\n \tenvelope.addMapping(NAMESPACE, cl.getSimpleName(), cl);\n }\n \n if (isDebuggable) {\n \t connection.debug = true;\n \t try {\n \t \tconnection.call(SOAP_ACTION, envelope);\n \t\t Log.d(TAG, connection.getHost() + \" \" + connection.getPath() + \" \" +\n \t\t connection.getPort());\n \t\t Log.d(TAG, connection.requestDump.toString());\n \t\t Log.d(TAG, connection.responseDump.toString());\n \t } catch (Exception e) {\n \t \tLog.e(TAG, e.getMessage(), e);\n \t\t Log.e(TAG, connection.getHost() + \" \" + connection.getPath() + \" \" +\n \t\t connection.getPort());\n \t\t Log.e(TAG, connection.requestDump.toString());\n\t\t Log.e(TAG, connection.responseDump.toString());\n \t } \t\n } else {\n \tconnection.call(SOAP_ACTION, envelope); \t\n }\n \n if (simple && !(envelope.getResponse() instanceof SoapFault)) {\n result = envelope.bodyIn;\n } else {\n result = envelope.getResponse();\n }\n }",
"public interface Request {\n public String toXml();\n\n\n public String getHandlerId();\n\n\n public String getRequestId();\n}",
"public SveaRequest<SveaCloseOrder> prepareRequest() {\n String errors = validateRequest();\n \n if (!errors.equals(\"\")) {\n throw new SveaWebPayException(\"Validation failed\", new ValidationException(errors));\n }\n \n // build inspectable request object and insert into order builder\n SveaCloseOrder sveaCloseOrder = new SveaCloseOrder();\n sveaCloseOrder.Auth = getStoreAuthorization();\n SveaCloseOrderInformation orderInfo = new SveaCloseOrderInformation();\n orderInfo.SveaOrderId = order.getOrderId();\n sveaCloseOrder.CloseOrderInformation = orderInfo;\n \n SveaRequest<SveaCloseOrder> object = new SveaRequest<SveaCloseOrder>();\n object.request = sveaCloseOrder;\n \n return object;\n }",
"public ch.iec.tc57._2011.schema.message.ResponseMessageDocument request\n (\n ch.iec.tc57._2011.schema.message.RequestMessageDocument requestMessage\n )\n throws MsgFaultMsg;",
"@RequestMapping(value = \"generateCreditLedgerReportPdf\", method = { RequestMethod.POST })\n\tpublic ResponseEntity<JsonResponse<List<RestDebitCreditLedgerModel>>> getCreditLedgerReportPdf(\n\t\t\t@RequestBody DataTableRequest request) {\n\t\tlogger.info(\"Method : getCreditLedgerReportPdf starts\");\n\t\tlogger.info(\"Method : getCreditLedgerReportPdf ends\");\n\t\treturn creditLedgerDao.getCreditLedgerReportPdf(request);\n\t}",
"public String prepareRequestToHost(Object request) {\n\t\tString clRequest = null;\n\t\tUserAuthRequestAndTXLifeRequest userRequest = ((NbaTXLife) request).getTXLife().getUserAuthRequestAndTXLifeRequest();\n\t\tif (userRequest != null && userRequest.getTXLifeRequestCount() > 0) {\n\t\t\tTXLifeRequest txRequest = userRequest.getTXLifeRequestAt(0);\n\t\t\tlong transType = txRequest.getTransType();\n\t\t\tlong transSubType = txRequest.getTransSubType();\n\t\t\tif (transType == NbaOliConstants.TC_TYPE_NEWBUSSUBMISSION && transSubType == NbaOliConstants.TC_SUBTYPE_BACKEND_PRINT) {\n\t\t\t\t// TODO determine why a new instance of this same class is needed\n\t\t\t\tNbaCyberPrintRequests cyberRequest = new NbaCyberPrintRequests();\n\t\t\t\ttry {\n\t\t\t\t\tclRequest = cyberRequest.createPrintRequest((NbaTXLife) request);\n\t\t\t\t} catch (NbaBaseException e) {\n\t\t\t\t\tthrow new RuntimeException(e);\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\tthrow new RuntimeException(new NbaBaseException(\"Invalid Print Type Requested\"));\n\t\t\t}\n\t\t\tgetLogger().logDebug(clRequest);\n\t\t}\n\t\treturn clRequest;\n\t}",
"Delivery createDelivery();",
"public void makePayment(\n org.pahospital.www.radiologyservice.RadiologyServiceStub.RadiologyOrderIDForPayment radiologyOrderIDForPayment8\n\n ) throws java.rmi.RemoteException\n \n \n {\n org.apache.axis2.context.MessageContext _messageContext = null;\n\n \n org.apache.axis2.client.OperationClient _operationClient = _serviceClient.createClient(_operations[3].getName());\n _operationClient.getOptions().setAction(\"http://www.PAHospital.org/RadiologyService/MakePayment\");\n _operationClient.getOptions().setExceptionToBeThrownOnSOAPFault(true);\n\n \n \n addPropertyToOperationClient(_operationClient,org.apache.axis2.description.WSDL2Constants.ATTR_WHTTP_QUERY_PARAMETER_SEPARATOR,\"&\");\n \n org.apache.axiom.soap.SOAPEnvelope env = null;\n _messageContext = new org.apache.axis2.context.MessageContext();\n\n \n //Style is Doc.\n \n \n env = toEnvelope(getFactory(_operationClient.getOptions().getSoapVersionURI()),\n radiologyOrderIDForPayment8,\n optimizeContent(new javax.xml.namespace.QName(\"http://www.PAHospital.org/RadiologyService/\",\n \"makePayment\")),new javax.xml.namespace.QName(\"http://www.PAHospital.org/RadiologyService/\",\n \"makePayment\"));\n \n\n //adding SOAP soap_headers\n _serviceClient.addHeadersToEnvelope(env);\n // create message context with that soap envelope\n\n _messageContext.setEnvelope(env);\n\n // add the message contxt to the operation client\n _operationClient.addMessageContext(_messageContext);\n\n _operationClient.execute(true);\n\n \n if (_messageContext.getTransportOut() != null) {\n _messageContext.getTransportOut().getSender().cleanup(_messageContext);\n }\n \n return;\n }",
"public CreateShipmentResponse createShipment(CreateShipmentRequest request)\n throws MWSMerchantFulfillmentServiceException {\n return newResponse(CreateShipmentResponse.class);\n }",
"@Nonnull\n public static UBL23WriterBuilder <ProofOfReexportationRequestType> proofOfReexportationRequest ()\n {\n return UBL23WriterBuilder.create (ProofOfReexportationRequestType.class);\n }",
"ShippingDocument createShippingDocument();",
"@WebService(name = \"PaymentMgmtService\",\n targetNamespace = \"http://assessor.lacounty.gov/amp/wsdl/ao/PaymentMgmtService\")\n@SOAPBinding(parameterStyle = SOAPBinding.ParameterStyle.BARE)\n@XmlSeeAlso({ ObjectFactory.class })\npublic interface PaymentMgmtService {\n\n\n /**\n *\n * @param request\n * @return\n * returns gov.laca.amp.proxy.soap.pmtmgmtservice.client.gen.RetrievePaymentHistoryResponse\n * @throws FaultMessage\n */\n @WebMethod(operationName = \"RetrievePaymentHistory\", action = \"RetrievePaymentHistory\")\n @WebResult(name = \"RetrievePaymentHistoryResponse\",\n targetNamespace = \"http://assessor.lacounty.gov/amp/xsd/ao/RetrievePaymentHistory\", partName = \"reply\")\n public RetrievePaymentHistoryResponse retrievePaymentHistory(@WebParam(name = \"RetrievePaymentHistoryRequest\",\n targetNamespace =\n \"http://assessor.lacounty.gov/amp/xsd/ao/RetrievePaymentHistory\",\n partName = \"request\")\n RetrievePaymentHistoryRequest request) throws FaultMessage;\n\n /**\n *\n * @param request\n * @return\n * returns gov.laca.amp.proxy.soap.pmtmgmtservice.client.gen.RetrieveSTRSummaryResponse\n * @throws FaultMessage\n */\n @WebMethod(operationName = \"RetrieveSTRSummary\", action = \"RetrieveSTRSummary\")\n @WebResult(name = \"RetrieveSTRSummaryResponse\",\n targetNamespace = \"http://assessor.lacounty.gov/amp/xsd/ao/RetrieveSTRSummary\", partName = \"reply\")\n public RetrieveSTRSummaryResponse retrieveSTRSummary(@WebParam(name = \"RetrieveSTRSummaryRequest\",\n targetNamespace =\n \"http://assessor.lacounty.gov/amp/xsd/ao/RetrieveSTRSummary\",\n partName = \"request\")\n RetrieveSTRSummaryRequest request) throws FaultMessage;\n\n /**\n *\n * @param request\n * @return\n * returns gov.laca.amp.proxy.soap.pmtmgmtservice.client.gen.RetrieveSTRChangeHistoryResponse\n * @throws FaultMessage\n */\n @WebMethod(operationName = \"RetrieveSTRChangeHistory\", action = \"RetrieveSTRChangeHistory\")\n @WebResult(name = \"RetrieveSTRChangeHistoryResponse\",\n targetNamespace = \"http://assessor.lacounty.gov/amp/xsd/ao/RetrieveSTRChangeHistory\", partName = \"reply\")\n public RetrieveSTRChangeHistoryResponse retrieveSTRChangeHistory(@WebParam(name = \"RetrieveSTRChangeHistoryRequest\",\n targetNamespace =\n \"http://assessor.lacounty.gov/amp/xsd/ao/RetrieveSTRChangeHistory\",\n partName = \"request\")\n RetrieveSTRChangeHistoryRequest request) throws FaultMessage;\n\n}",
"@Override\n\tpublic void make_body() {\n\t\t\n\t\tElement order_e=body.addElement(\"RouteRequest\");\n\t\t\n\t\torder_e.addAttribute(\"tracking_type\", \"1\");\n\t\torder_e.addAttribute(\"method_type\", \"1\");\n\t\tString mail_nos=\"\";\n\t\t\n\t\t\tmail_nos=com.cqqyd2014.util.ArrayTools.convertFieldToArrayString(this.getDbs(), \"getExpress_no\",String.class);\n\t\t\n\t\tmail_nos=mail_nos.substring(1, mail_nos.length()-1);\n\t\t\n\t\torder_e.addAttribute(\"tracking_number\",mail_nos);\n\t}",
"private void initRequest()\n\t{\n\t\tthis.request = new RestClientReportRequest();\n\t\tRequestHelper.copyConfigsToRequest(this.getConfigs(), this.request);\n\t\tRequestHelper.copyParamsToRequest(this.getParams(), this.request);\n\t\t\n\t\tthis.performQuery();\n\t}",
"private Collection<ContractsGrantsInvoiceDocument> getInvoicesByParametersFromRequest(InvoiceReportDeliveryForm form) throws WorkflowException, ParseException {\r\n SimpleDateFormat dateFormat = new SimpleDateFormat(\"mm/dd/yyyy\");\r\n SimpleDateFormat reqDateFormat = new SimpleDateFormat(\"yyyy-mm-dd hh:mm:ss\");\r\n Timestamp fromDate = null;\r\n Timestamp toDate = null;\r\n if (StringUtils.isNotEmpty(form.getToDate())) {\r\n toDate = Timestamp.valueOf(reqDateFormat.format(dateFormat.parse(form.getToDate())));\r\n }\r\n if (StringUtils.isNotEmpty(form.getFromDate())) {\r\n fromDate = Timestamp.valueOf(reqDateFormat.format(dateFormat.parse(form.getFromDate())));\r\n }\r\n String user = form.getUserId();\r\n ContractsGrantsInvoiceDocumentService invoiceDocumentService = SpringContext.getBean(ContractsGrantsInvoiceDocumentService.class);\r\n Map<String, String> fieldValues = new HashMap<String, String>();\r\n if (StringUtils.isNotEmpty(form.getProposalNumber())) {\r\n fieldValues.put(\"proposalNumber\", form.getProposalNumber());\r\n }\r\n if (StringUtils.isNotEmpty(form.getDocumentNumber())) {\r\n fieldValues.put(\"documentNumber\", form.getDocumentNumber());\r\n }\r\n if (ObjectUtils.isNotNull(form.getInvoiceAmount())) {\r\n fieldValues.put(\"documentHeader.financialDocumentTotalAmount\", form.getInvoiceAmount());\r\n }\r\n if (StringUtils.isNotEmpty(form.getChartCode())) {\r\n fieldValues.put(ArPropertyConstants.CustomerInvoiceDocumentFields.BILL_BY_CHART_OF_ACCOUNT_CODE, form.getChartCode());\r\n }\r\n if (StringUtils.isNotEmpty(form.getOrgCode())) {\r\n fieldValues.put(ArPropertyConstants.CustomerInvoiceDocumentFields.BILLED_BY_ORGANIZATION_CODE, form.getOrgCode());\r\n }\r\n Collection<ContractsGrantsInvoiceDocument> list = invoiceDocumentService.retrieveAllCGInvoicesByCriteria(fieldValues);\r\n Collection<ContractsGrantsInvoiceDocument> finalList = new ArrayList<ContractsGrantsInvoiceDocument>();\r\n if (CollectionUtils.isEmpty(list)) {\r\n return null;\r\n }\r\n for (ContractsGrantsInvoiceDocument item : list) {\r\n Document document = SpringContext.getBean(DocumentService.class).getByDocumentHeaderId(item.getDocumentNumber());\r\n if (ArConstants.ArDocumentTypeCodes.CONTRACTS_GRANTS_INVOICE.equals(document.getDocumentHeader().getWorkflowDocument().getDocumentTypeName())) {\r\n ContractsGrantsInvoiceDocument invoice = (ContractsGrantsInvoiceDocument) document;\r\n if (invoice.getDocumentHeader().getWorkflowDocument().isFinal()) {\r\n if (StringUtils.isNotEmpty(user)) {\r\n Person person = SpringContext.getBean(PersonService.class).getPersonByPrincipalName(user);\r\n if (person == null) {\r\n throw new IllegalArgumentException(\"The parameter value for initiatorPrincipalName [\" + user + \"] passed in does not map to a person.\");\r\n }\r\n if (StringUtils.equalsIgnoreCase(invoice.getDocumentHeader().getWorkflowDocument().getInitiatorPrincipalId(), person.getPrincipalId())) {\r\n // if (invoice.getDocumentHeader().getWorkflowDocument().userIsInitiator(person)){\r\n }\r\n if (invoice.getDocumentHeader().getWorkflowDocument().getInitiatorPrincipalId().equals(person.getPrincipalId())) {\r\n if (this.isInvoiceBetween(invoice, fromDate, toDate)) {\r\n if (ObjectUtils.isNull(invoice.getDateReportProcessed()) || ObjectUtils.isNull(invoice.getMarkedForProcessing())) {\r\n finalList.add(invoice);\r\n }\r\n }\r\n }\r\n }\r\n else if (this.isInvoiceBetween(invoice, fromDate, toDate)) {\r\n if (ObjectUtils.isNull(invoice.getDateReportProcessed()) || ObjectUtils.isNull(invoice.getMarkedForProcessing())) {\r\n finalList.add(invoice);\r\n }\r\n }\r\n }\r\n }\r\n }\r\n return finalList;\r\n }",
"public ReportResponse(List<ReportData> reportData) {\n this.reportData = reportData;\n }",
"public void acctReport (COPSPdpOSReqStateMan man, List<COPSClientSI> reportSIs);",
"Shipment createShipment();"
] | [
"0.745993",
"0.52351296",
"0.48244202",
"0.47805345",
"0.46353558",
"0.46334967",
"0.46193612",
"0.4584735",
"0.45720568",
"0.45640895",
"0.45601973",
"0.4527575",
"0.45259953",
"0.45259383",
"0.4522301",
"0.4518651",
"0.45128193",
"0.4483276",
"0.44756955",
"0.4466037",
"0.4464986",
"0.44645983",
"0.44617507",
"0.4459285",
"0.44582078",
"0.44502637",
"0.4442844",
"0.4440589",
"0.44382155",
"0.4434902",
"0.441531",
"0.44098887",
"0.44077426",
"0.43930975",
"0.43830118",
"0.43769035",
"0.43694943",
"0.4342751",
"0.4337802",
"0.433775",
"0.43342406",
"0.4332391",
"0.43241316",
"0.4319464",
"0.43174687",
"0.431042",
"0.43076184",
"0.42953554",
"0.42852005",
"0.42657346",
"0.4262959",
"0.4256036",
"0.4250815",
"0.42475167",
"0.42469564",
"0.42442033",
"0.42442033",
"0.42442033",
"0.42442033",
"0.42442033",
"0.42442033",
"0.42442033",
"0.42442033",
"0.42442033",
"0.42442033",
"0.42442033",
"0.42398256",
"0.4228171",
"0.42256817",
"0.42148346",
"0.4205777",
"0.4201375",
"0.41914704",
"0.4182316",
"0.41774446",
"0.41767508",
"0.4173974",
"0.41700226",
"0.41620317",
"0.41607746",
"0.41538486",
"0.41478977",
"0.41405386",
"0.41373485",
"0.41358885",
"0.41294804",
"0.4125512",
"0.4119724",
"0.4117449",
"0.41165042",
"0.41139442",
"0.41130292",
"0.41122743",
"0.41012806",
"0.40997955",
"0.40977636",
"0.40932104",
"0.40886378",
"0.40864944",
"0.40862334"
] | 0.47403827 | 4 |
Builds the soap document from the DeliveryReportRequest. | @SuppressWarnings("unchecked")
private static Document buildDeliveryReportRequestXml(
DeliveryReportRequest deliveryReportRequest) throws Exception {
Marshaller marshaller = CommonUtil.getMarshaller();
//Create the soap response
DocumentBuilderFactory documentBuilderFactory = DocumentBuilderFactory.newInstance();
DocumentBuilder documentBuilder = documentBuilderFactory.newDocumentBuilder();
Document responseXml = documentBuilder.newDocument();
//Create the soap envelope
Element envelopeNode = responseXml.createElementNS(
Constants.SOAP_ENV_NS, "env:Envelope");
responseXml.appendChild(envelopeNode);
//Create the soap header
Element headerNode = responseXml.createElementNS(Constants.SOAP_ENV_NS, "env:Header");
envelopeNode.appendChild(headerNode);
//Create the soap body
Element bodyNode = responseXml.createElementNS(Constants.SOAP_ENV_NS, "env:Body");
envelopeNode.appendChild(bodyNode);
//Marshall the TransactionId node
marshaller.marshal(deliveryReportRequest.getHeader(), headerNode);
//Marshall the DeliveryReportReq node
marshaller.marshal(
new JAXBElement<DeliveryReportReqType>(
new QName(Constants.MM7_NS, "DeliveryReportReq"),
(Class<DeliveryReportReqType>) deliveryReportRequest.getRequest().getClass(),
deliveryReportRequest.getRequest()),
bodyNode);
return responseXml;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public static void generateReport() {\n PrintImpl printer = new PrintImpl(realtorLogImpl, propertyLogImpl);\n printer.generateReport(REQUESTS_FILE);\n }",
"public DocumentReport() {\n\n\t\tLOGGER.info(\"Create Document Processor\");\n\n\t\tresultsXMLWriter = new ResultsXMLWriter();\n\t\tgaugesWriter = new GaugeJSONWriter();\n\t\tgaugesWriter.setMode(processMode.toString());\n\t\tgaugesXMLWriter = new GaugeXMLWriter();\n\t\tstylesXMLWriter = new StylesXMLWriter();\n\t\tstylesWriter = new StylesJSONWriter();\n\t\tstylesWriter.setMode(processMode.toString());\n\t\t\n\t\txPathWriter = new XPathJSONWriter();\n\t\txPathDotWriter = new DotWriter();\n\t\txPathXMLWriter = new XMLWriter();\n\t\txPathWriter.setMode(processMode.toString());\n\t\t\n//\t\tdotWriter = new DotWriter();\n\t}",
"public Report build() {\n return new Report(this);\n }",
"ShippingDocument createShippingDocument();",
"public Document generateDocumentFromString(String xmlInput) throws SCNotifyRequestProcessingException {\n\t\tDocumentBuilderFactory builderFactory = DocumentBuilderFactory.newInstance();\n\t\tDocumentBuilder builder = null;\n\t\tDocument xmlDocument;\n\t\tlogger.debug(\".xmlInput : \"+xmlInput);\n\t\ttry {\n\t\t\tbuilder = builderFactory.newDocumentBuilder();\n\t\t} catch (ParserConfigurationException e) {\n\t\t\tthrow new SCNotifyRequestProcessingException(\"Unable to initiate the document builder..\", e);\n\t\t}\n\t\ttry {\n\t\t\txmlDocument = builder.parse(new ByteArrayInputStream(xmlInput.getBytes(\"UTF-16\")));\n\t\t} catch (SAXException | IOException e) {\n\t\t\tthrow new SCNotifyRequestProcessingException(\"Unable to parse the xmlString into document..\", e);\n\t\t}\n\t\treturn xmlDocument;\n\t}",
"@Nonnull\n public static UBL23WriterBuilder <DocumentStatusRequestType> documentStatusRequest ()\n {\n return UBL23WriterBuilder.create (DocumentStatusRequestType.class);\n }",
"public Document formatRequest(Properties req)\n {\n String sTemp = (String) req.get(REQ_CATEGORY_KEY);\n if ((sTemp == null) || (!(REQ_CATEGORY_VALUE.equalsIgnoreCase(sTemp))))\n {\n throw new IllegalArgumentException(\n \"req category invalid: null or REQ_CATEGORY_VALUE\");\n }\n\n sTemp = (String) req.get(REQ_TYPE_KEY);\n if ((sTemp == null) || (!(REQ_TYPE_VALUE.equalsIgnoreCase(sTemp))))\n {\n throw new IllegalArgumentException(\n \"req type invalid: null or REQ_TYPE_VALUE\");\n }\n\n String datasource = (String) req.get(DATASOURCE_KEY);\n\n Document reqDoc = PSXmlDocumentBuilder.createXmlDocument();\n Element root = PSXmlDocumentBuilder.createRoot(reqDoc, NODE_NAME);\n if (datasource != null)\n PSXmlDocumentBuilder.addElement(reqDoc, root, EL_DATASOURCE, \n datasource);\n\n return reqDoc;\n }",
"public static Builder builder() {\n return new Report.Builder();\n }",
"private Collection<ContractsGrantsInvoiceDocument> getInvoicesByParametersFromRequest(InvoiceReportDeliveryForm form) throws WorkflowException, ParseException {\r\n SimpleDateFormat dateFormat = new SimpleDateFormat(\"mm/dd/yyyy\");\r\n SimpleDateFormat reqDateFormat = new SimpleDateFormat(\"yyyy-mm-dd hh:mm:ss\");\r\n Timestamp fromDate = null;\r\n Timestamp toDate = null;\r\n if (StringUtils.isNotEmpty(form.getToDate())) {\r\n toDate = Timestamp.valueOf(reqDateFormat.format(dateFormat.parse(form.getToDate())));\r\n }\r\n if (StringUtils.isNotEmpty(form.getFromDate())) {\r\n fromDate = Timestamp.valueOf(reqDateFormat.format(dateFormat.parse(form.getFromDate())));\r\n }\r\n String user = form.getUserId();\r\n ContractsGrantsInvoiceDocumentService invoiceDocumentService = SpringContext.getBean(ContractsGrantsInvoiceDocumentService.class);\r\n Map<String, String> fieldValues = new HashMap<String, String>();\r\n if (StringUtils.isNotEmpty(form.getProposalNumber())) {\r\n fieldValues.put(\"proposalNumber\", form.getProposalNumber());\r\n }\r\n if (StringUtils.isNotEmpty(form.getDocumentNumber())) {\r\n fieldValues.put(\"documentNumber\", form.getDocumentNumber());\r\n }\r\n if (ObjectUtils.isNotNull(form.getInvoiceAmount())) {\r\n fieldValues.put(\"documentHeader.financialDocumentTotalAmount\", form.getInvoiceAmount());\r\n }\r\n if (StringUtils.isNotEmpty(form.getChartCode())) {\r\n fieldValues.put(ArPropertyConstants.CustomerInvoiceDocumentFields.BILL_BY_CHART_OF_ACCOUNT_CODE, form.getChartCode());\r\n }\r\n if (StringUtils.isNotEmpty(form.getOrgCode())) {\r\n fieldValues.put(ArPropertyConstants.CustomerInvoiceDocumentFields.BILLED_BY_ORGANIZATION_CODE, form.getOrgCode());\r\n }\r\n Collection<ContractsGrantsInvoiceDocument> list = invoiceDocumentService.retrieveAllCGInvoicesByCriteria(fieldValues);\r\n Collection<ContractsGrantsInvoiceDocument> finalList = new ArrayList<ContractsGrantsInvoiceDocument>();\r\n if (CollectionUtils.isEmpty(list)) {\r\n return null;\r\n }\r\n for (ContractsGrantsInvoiceDocument item : list) {\r\n Document document = SpringContext.getBean(DocumentService.class).getByDocumentHeaderId(item.getDocumentNumber());\r\n if (ArConstants.ArDocumentTypeCodes.CONTRACTS_GRANTS_INVOICE.equals(document.getDocumentHeader().getWorkflowDocument().getDocumentTypeName())) {\r\n ContractsGrantsInvoiceDocument invoice = (ContractsGrantsInvoiceDocument) document;\r\n if (invoice.getDocumentHeader().getWorkflowDocument().isFinal()) {\r\n if (StringUtils.isNotEmpty(user)) {\r\n Person person = SpringContext.getBean(PersonService.class).getPersonByPrincipalName(user);\r\n if (person == null) {\r\n throw new IllegalArgumentException(\"The parameter value for initiatorPrincipalName [\" + user + \"] passed in does not map to a person.\");\r\n }\r\n if (StringUtils.equalsIgnoreCase(invoice.getDocumentHeader().getWorkflowDocument().getInitiatorPrincipalId(), person.getPrincipalId())) {\r\n // if (invoice.getDocumentHeader().getWorkflowDocument().userIsInitiator(person)){\r\n }\r\n if (invoice.getDocumentHeader().getWorkflowDocument().getInitiatorPrincipalId().equals(person.getPrincipalId())) {\r\n if (this.isInvoiceBetween(invoice, fromDate, toDate)) {\r\n if (ObjectUtils.isNull(invoice.getDateReportProcessed()) || ObjectUtils.isNull(invoice.getMarkedForProcessing())) {\r\n finalList.add(invoice);\r\n }\r\n }\r\n }\r\n }\r\n else if (this.isInvoiceBetween(invoice, fromDate, toDate)) {\r\n if (ObjectUtils.isNull(invoice.getDateReportProcessed()) || ObjectUtils.isNull(invoice.getMarkedForProcessing())) {\r\n finalList.add(invoice);\r\n }\r\n }\r\n }\r\n }\r\n }\r\n return finalList;\r\n }",
"private SOAPMessage buildMessage(Document doc) throws SOAPException {\n MessageFactory mfact = MessageFactory.newInstance();\n SOAPMessage smsg = mfact.createMessage();\n SOAPPart prt = smsg.getSOAPPart();\n SOAPEnvelope env = prt.getEnvelope();\n SOAPBody bdy = env.getBody();\n bdy.addDocument(doc);\n smsg.saveChanges();\n\n return smsg;\n }",
"public void build() {\n\t\t\tRequest request = new Request();\n request.context = context;\n\t\t\trequest.requestType = requestType;\n\t\t\trequest.url = url;\n\t\t\trequest.envelope = envelope;\n\t\t\trequest.headers = headers;\n\n\t\t\trequest.responseListener = responseListener;\n\t\t\trequest.onValidateResponseListener = validateResponseListener;\n\n\t\t\trequest.isDebug = isDebug;\n\n\t\t\trequest.start();\n\t\t}",
"public DeliveryParcelDraft build() {\n return new DeliveryParcelDraftImpl(measurements, trackingData, items);\n }",
"private void generateSearchReport(final Map<String, String> request,\r\n\t\t\tfinal List<Map<String, String>> resultMap) {\r\n\t\tMap<String, String> reportMap = null;\r\n\r\n\t\tfor (final Map<String, String> map : resultMap) {\r\n\t\t\tif (map.containsKey(CommonConstants.TOTAL_PRODUCTS)) {\r\n\t\t\t\treportMap = this.getReportMap(request);\r\n\t\t\t\tfinal StringBuilder attributes = new StringBuilder();\r\n\t\t\t\tif (request.containsKey(RequestAttributeConstant.COLOR)) {\r\n\t\t\t\t\tattributes.append(CommonConstants.COLOR);\r\n\t\t\t\t\tattributes.append(CommonConstants.FIELD_PAIR_SEPARATOR);\r\n\t\t\t\t\tattributes.append(request\r\n\t\t\t\t\t\t\t.get(RequestAttributeConstant.COLOR));\r\n\t\t\t\t\tattributes.append(CommonConstants.PIPE_SEPERATOR);\r\n\t\t\t\t}\r\n\t\t\t\tif (request.containsKey(RequestAttributeConstant.SIZE)) {\r\n\t\t\t\t\tattributes.append(CommonConstants.SIZE);\r\n\t\t\t\t\tattributes.append(CommonConstants.FIELD_PAIR_SEPARATOR);\r\n\t\t\t\t\tattributes.append(request\r\n\t\t\t\t\t\t\t.get(RequestAttributeConstant.SIZE));\r\n\t\t\t\t\tattributes.append(CommonConstants.PIPE_SEPERATOR);\r\n\t\t\t\t}\r\n\t\t\t\tif (request.containsKey(RequestAttributeConstant.BRAND)) {\r\n\t\t\t\t\tattributes.append(CommonConstants.BRAND);\r\n\t\t\t\t\tattributes.append(CommonConstants.FIELD_PAIR_SEPARATOR);\r\n\t\t\t\t\tattributes.append(request\r\n\t\t\t\t\t\t\t.get(RequestAttributeConstant.BRAND));\r\n\t\t\t\t\tattributes.append(CommonConstants.PIPE_SEPERATOR);\r\n\t\t\t\t}\r\n\t\t\t\tthis.requestAttributePrice(request, attributes);\r\n\t\t\t\tif (attributes.length() != 0) {\r\n\t\t\t\t\treportMap.put(DomainConstants.ATTRIBUTES, attributes\r\n\t\t\t\t\t\t\t.toString().substring(0, attributes.length() - 1));\r\n\t\t\t\t}\r\n\r\n\t\t\t\tString sortFields = \"\";\r\n\t\t\t\tif (request.containsKey(RequestAttributeConstant.SORT)) {\r\n\t\t\t\t\tsortFields = request.get(RequestAttributeConstant.SORT);\r\n\t\t\t\t}\r\n\t\t\t\tif (!\"\".equals(sortFields)) {\r\n\t\t\t\t\treportMap.put(DomainConstants.SORT_FIELDS, sortFields\r\n\t\t\t\t\t\t\t.replace(CommonConstants.EMPTY_VALUE,\r\n\t\t\t\t\t\t\t\t\tCommonConstants.COMMA_SEPERATOR));\r\n\t\t\t\t}\r\n\t\t\t\tmap.putAll(reportMap);\r\n\t\t\t\tbreak;\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t}",
"Report createReport();",
"@Nonnull\n public ServiceAnnouncementRequest buildRequest(@Nonnull final java.util.List<? extends com.microsoft.graph.options.Option> requestOptions) {\n return new com.microsoft.graph.requests.ServiceAnnouncementRequest(getRequestUrl(), getClient(), requestOptions);\n }",
"public AnalyticsEvent build() {\n AnalyticsEvent purchaseEvent = null;\n if(isValid() && doBaseValidation()) {\n purchaseEvent = eventClient.createEvent(PURCHASE_EVENT_NAME);\n\n purchaseEvent.addAttribute(PURCHASE_EVENT_PRODUCT_ID_ATTR, productId);\n purchaseEvent.addAttribute(PURCHASE_EVENT_STORE_ATTR, store);\n purchaseEvent.addMetric(PURCHASE_EVENT_QUANTITY_METRIC, quantity);\n\n if(formattedItemPrice != null) {\n purchaseEvent.addAttribute(PURCHASE_EVENT_PRICE_FORMATTED_ATTR, formattedItemPrice);\n }\n\n if(itemPrice != null) {\n purchaseEvent.addMetric(PURCHASE_EVENT_ITEM_PRICE_METRIC, itemPrice);\n }\n\n if(transactionId != null) {\n purchaseEvent.addAttribute(PURCHASE_EVENT_TRANSACTION_ID_ATTR, transactionId);\n }\n\n if(currency != null) {\n purchaseEvent.addAttribute(PURCHASE_EVENT_CURRENCY_ATTR, currency);\n }\n }\n \n return purchaseEvent;\n }",
"private void initRequest()\n\t{\n\t\tthis.request = new RestClientReportRequest();\n\t\tRequestHelper.copyConfigsToRequest(this.getConfigs(), this.request);\n\t\tRequestHelper.copyParamsToRequest(this.getParams(), this.request);\n\t\t\n\t\tthis.performQuery();\n\t}",
"@Nonnull\n public static UBL23WriterBuilder <CatalogueRequestType> catalogueRequest ()\n {\n return UBL23WriterBuilder.create (CatalogueRequestType.class);\n }",
"void createReport(Report report);",
"private static SOAPMessage createRequest(JobPosting jobPosting) throws SOAPException, ServerException {\n\n\t\tMessageFactory factory = MessageFactory.newInstance();\n\t\tSOAPMessage request = factory.createMessage();\n\t\tSOAPPart soapPart = request.getSOAPPart();\n\n\t\tSOAPEnvelope envelope = soapPart.getEnvelope();\n\t\tenvelope.addNamespaceDeclaration(SOAP_NAMESPACE_NAME,\n\t\t\t\tdestinationProperties.get(WEB_NAMESPACE_URL_DESTINATION_PROPERTY));\n\n\t\tSOAPBody soapBody = envelope.getBody();\n\t\tSOAPElement upload = soapBody.addChildElement(UPLOAD_SOAP_ELEMENT, SOAP_NAMESPACE_NAME);\n\t\tSOAPElement username = upload.addChildElement(USERNAME_SOAP_ELEMENT, SOAP_NAMESPACE_NAME);\n\t\tSOAPElement password = upload.addChildElement(PASSWORD_SOAP_ELEMENT, SOAP_NAMESPACE_NAME);\n\t\tSOAPElement data = upload.addChildElement(DATA_SOAP_ELEMENT, SOAP_NAMESPACE_NAME);\n\n\t\tusername.addTextNode(destinationProperties.get(USER_DESTINATION_PROPERTY));\n\t\tpassword.addTextNode(destinationProperties.get(PASSWORD_DESTINATION_PROPERTY));\n\n\t\tdata.addTextNode(jobPosting.toString());\n\n\t\trequest.saveChanges();\n\t\treturn request;\n\t}",
"private static String generateXML(String userName, String hash,\n String userID, String ipAddress, String paymentToolNumber,\n String expDate, String cvc, String orderID, String amount,\n String currency) {\n\n try {\n // Create instance of DocumentBuilderFactory\n DocumentBuilderFactory factory = DocumentBuilderFactory\n .newInstance();\n // Get the DocumentBuilder\n DocumentBuilder docBuilder = factory.newDocumentBuilder();\n // Create blank DOM Document\n Document doc = docBuilder.newDocument();\n\n Element root = doc.createElement(\"GVPSRequest\");\n doc.appendChild(root);\n\n Element Mode = doc.createElement(\"Mode\");\n Mode.appendChild(doc.createTextNode(\"PROD\"));\n root.appendChild(Mode);\n\n Element Version = doc.createElement(\"Version\");\n Version.appendChild(doc.createTextNode(\"v0.01\"));\n root.appendChild(Version);\n\n Element Terminal = doc.createElement(\"Terminal\");\n root.appendChild(Terminal);\n\n Element ProvUserID = doc.createElement(\"ProvUserID\");\n // ProvUserID.appendChild(doc.createTextNode(userName));\n ProvUserID.appendChild(doc.createTextNode(\"PROVAUT\"));\n Terminal.appendChild(ProvUserID);\n\n Element HashData_ = doc.createElement(\"HashData\");\n HashData_.appendChild(doc.createTextNode(hash));\n Terminal.appendChild(HashData_);\n\n Element UserID = doc.createElement(\"UserID\");\n UserID.appendChild(doc.createTextNode(\"deneme\"));\n Terminal.appendChild(UserID);\n\n Element ID = doc.createElement(\"ID\");\n ID.appendChild(doc.createTextNode(\"10000039\"));\n Terminal.appendChild(ID);\n\n Element MerchantID = doc.createElement(\"MerchantID\");\n MerchantID.appendChild(doc.createTextNode(userID));\n Terminal.appendChild(MerchantID);\n\n Element Customer = doc.createElement(\"Customer\");\n root.appendChild(Customer);\n\n Element IPAddress = doc.createElement(\"IPAddress\");\n IPAddress.appendChild(doc.createTextNode(ipAddress));\n Customer.appendChild(IPAddress);\n\n Element EmailAddress = doc.createElement(\"EmailAddress\");\n EmailAddress.appendChild(doc.createTextNode(\"[email protected]\"));\n Customer.appendChild(EmailAddress);\n\n Element Card = doc.createElement(\"Card\");\n root.appendChild(Card);\n\n Element Number = doc.createElement(\"Number\");\n Number.appendChild(doc.createTextNode(paymentToolNumber));\n Card.appendChild(Number);\n\n Element ExpireDate = doc.createElement(\"ExpireDate\");\n ExpireDate.appendChild(doc.createTextNode(\"1212\"));\n Card.appendChild(ExpireDate);\n\n Element CVV2 = doc.createElement(\"CVV2\");\n CVV2.appendChild(doc.createTextNode(cvc));\n Card.appendChild(CVV2);\n\n Element Order = doc.createElement(\"Order\");\n root.appendChild(Order);\n\n Element OrderID = doc.createElement(\"OrderID\");\n OrderID.appendChild(doc.createTextNode(orderID));\n Order.appendChild(OrderID);\n\n Element GroupID = doc.createElement(\"GroupID\");\n GroupID.appendChild(doc.createTextNode(\"\"));\n Order.appendChild(GroupID);\n\n\t\t\t/*\n * Element Description=doc.createElement(\"Description\");\n\t\t\t * Description.appendChild(doc.createTextNode(\"\"));\n\t\t\t * Order.appendChild(Description);\n\t\t\t */\n\n Element Transaction = doc.createElement(\"Transaction\");\n root.appendChild(Transaction);\n\n Element Type = doc.createElement(\"Type\");\n Type.appendChild(doc.createTextNode(\"sales\"));\n Transaction.appendChild(Type);\n\n Element InstallmentCnt = doc.createElement(\"InstallmentCnt\");\n InstallmentCnt.appendChild(doc.createTextNode(\"\"));\n Transaction.appendChild(InstallmentCnt);\n\n Element Amount = doc.createElement(\"Amount\");\n Amount.appendChild(doc.createTextNode(amount));\n Transaction.appendChild(Amount);\n\n Element CurrencyCode = doc.createElement(\"CurrencyCode\");\n CurrencyCode.appendChild(doc.createTextNode(currency));\n Transaction.appendChild(CurrencyCode);\n\n Element CardholderPresentCode = doc\n .createElement(\"CardholderPresentCode\");\n CardholderPresentCode.appendChild(doc.createTextNode(\"0\"));\n Transaction.appendChild(CardholderPresentCode);\n\n Element MotoInd = doc.createElement(\"MotoInd\");\n MotoInd.appendChild(doc.createTextNode(\"N\"));\n Transaction.appendChild(MotoInd);\n\n // Convert dom to String\n TransformerFactory tranFactory = TransformerFactory.newInstance();\n Transformer aTransformer = tranFactory.newTransformer();\n StringWriter buffer = new StringWriter();\n aTransformer.setOutputProperty(OutputKeys.OMIT_XML_DECLARATION,\n \"yes\");\n aTransformer\n .transform(new DOMSource(doc), new StreamResult(buffer));\n return buffer.toString();\n\n } catch (Exception e) {\n return null;\n }\n\n }",
"public static void any() {\n\t\tlong date = System.currentTimeMillis();\n\t\tString body = IO.readContentAsString(request.body);\n\t\tif (body == null) {\n\t\t\terror(StatusCode.INTERNAL_ERROR,\n\t\t\t\t\t\"Message is malformed (null body)...\");\n\t\t}\n\n\t\tDocument soapMessage = XML.getDocument(body);\n\t\tif (soapMessage == null) {\n\t\t\terror(StatusCode.INTERNAL_ERROR,\n\t\t\t\t\t\"Message is malformed (not XML)...\");\n\t\t}\n\n\t\t// parse the body and calculate required data...\n\t\tNode n = XPath.selectNode(\"//ReportListBean\", soapMessage);\n\t\tif (n == null) {\n\t\t\terror(StatusCode.INTERNAL_ERROR,\n\t\t\t\t\t\"Message is malformed (not a valid report)...\");\n\t\t}\n\n\t\t// can be optimized...\n\t\tString reportList = XMLHelper.createStringFromDOMNode(n, true);\n\t\tif (reportList == null) {\n\t\t\terror(StatusCode.INTERNAL_ERROR,\n\t\t\t\t\t\"Message is malformed (can not generate reportList)...\");\n\t\t}\n\n\t\tReportListBean reportListBean = null;\n\t\ttry {\n\t\t\treportListBean = JAXBHelper.unmarshall(new ByteArrayInputStream(\n\t\t\t\t\treportList.getBytes()));\n\t\t} catch (MessageExchangeException e) {\n\t\t\terror(StatusCode.INTERNAL_ERROR, e.getMessage());\n\t\t}\n\n\t\tMessage message = new Message();\n\t\tfor (ReportBean report : reportListBean.getReports()) {\n\t\t\tif (\"t1\".equalsIgnoreCase(report.getType())) {\n\t\t\t\tmessage.t1 = report.getDate();\n\t\t\t} else if (\"t2\".equalsIgnoreCase(report.getType())) {\n\t\t\t\tmessage.t2 = report.getDate();\n\t\t\t} else if (\"t3\".equalsIgnoreCase(report.getType())) {\n\t\t\t\tmessage.t3 = report.getDate();\n\t\t\t} else if (\"t4\".equalsIgnoreCase(report.getType())) {\n\t\t\t\tmessage.t4 = report.getDate();\n\t\t\t}\n\n\t\t\t// monitoring api needs to be fixed since all informations are the\n\t\t\t// same for the target\n\t\t\tmessage.endpoint = report.getEndpoint();\n\t\t\tmessage.itf = report.getItf();\n\t\t\tmessage.service = report.getServiceName();\n\t\t\tmessage.operation = report.getOperation();\n\t\t}\n\t\tmessage.date = date;\n\t\tmessage.exception = false;\n\t\tWebSocket.liveStream.publish(message);\n\t\t\n\t\trender(\"Services/MonitoringService_Response.xml\");\n\t}",
"public List<PaymentRequestDocument> getPaymentRequestsToExtract(String campusCode, Integer paymentRequestIdentifier, Integer purchaseOrderIdentifier, Integer vendorHeaderGeneratedIdentifier, Integer vendorDetailAssignedIdentifier, Date currentSqlDateMidnight);",
"@Nonnull\n public static UBL23WriterBuilder <ProofOfReexportationRequestType> proofOfReexportationRequest ()\n {\n return UBL23WriterBuilder.create (ProofOfReexportationRequestType.class);\n }",
"public Doc getReleasedPurchaseOrderForMaintReq(MaintenanceRequest mrq){\n\t\ttry{\n\t\t\treturn docDAO.findReleasedPurchaseOrderDocForMaintReq(mrq.getMrqId());\n\t\t}catch(Exception ex){\n\t\t\tthrow new MalException(\"generic.error.occured.while\", \n\t\t\t\t\tnew String[] { \"retrieving released purchase order for Job No: \" + mrq.getJobNo()}, ex);\n\t\t}\n\t}",
"ByteArrayOutputStream createPDF(String templateName, Map<String, Object> params,\n String companyId, String notificationType);",
"@Override\n public Map<String, XmlObject> generateXmlStream(KraPersistableBusinessObjectBase printableBusinessObject,\n Map<String, Object> reportParameters) {\n\n Map<String, XmlObject> xmlObjectList = new LinkedHashMap<String, XmlObject>();\n try {\n SubContractDataDocument subContractDataDoc = SubContractDataDocument.Factory.newInstance();\n SubContractData subContractData = SubContractData.Factory.newInstance();\n SubAward subaward = (SubAward) printableBusinessObject;\n this.awardNumber = (String) reportParameters.get(\"awardNumber\");\n this.awardTitle = (String) reportParameters.get(\"awardTitle\");\n this.sponsorAwardNumber = (String) reportParameters.get(\"sponsorAwardNumber\");\n this.sponsorName = (String) reportParameters.get(\"sponsorName\");\n this.cfdaNumber = (String) reportParameters.get(\"cfdaNumber\");\n this.awardID = (Long) reportParameters.get(\"awardID\");\n this.sponsorTemplates = (List<SubAwardForms>) reportParameters.get(SubAwardPrintingService.SELECTED_TEMPLATES);\n setSubcontractTemplateInfo(subContractData, subaward);\n setFundingSource(subContractData, subaward);\n setSubcontractDetail(subContractData, subaward);\n setSubcontractAmountInfo(subContractData, subaward);\n setAwardHeader(subContractData, subaward);\n setPrimeRecipientContacts(subContractData, subaward);\n setPrintRequirement(subContractData, subaward);\n setPrimeAdministrativeContact(subContractData, subaward);\n setPrimePrincipalInvestigator(subContractData, subaward);\n setPrimeFinancialContact(subContractData, subaward);\n setPrimeAuthorizedOfficial(subContractData, subaward);\n setAdministrativeContact(subContractData, subaward);\n setFinancialContact(subContractData, subaward);\n setAuthorizedOfficial(subContractData, subaward);\n setSubcontractReports(subContractData, subaward);\n subContractDataDoc.setSubContractData(subContractData);\n xmlObjectList.put(Constants.SUBAWARD_PRINT_TYPE_FDP_TEMPLATE, subContractDataDoc);\n } catch (Exception e) {\n e.printStackTrace();\n }\n return xmlObjectList;\n }",
"@Nonnull\n public static UBL23WriterBuilder <TransportationStatusRequestType> transportationStatusRequest ()\n {\n return UBL23WriterBuilder.create (TransportationStatusRequestType.class);\n }",
"Document generateSpendingCategoryReport(String username, Date start,\n Date end);",
"public Collection<PaymentRequestDocument> getPaymentRequestsToExtractForVendor(String campusCode, VendorGroupingHelper vendor, Date onOrBeforePaymentRequestPayDate);",
"private ReportRequest getAdReport(Calendar from, Calendar to) {\r\n\t\tAdPerformanceReportRequest request = new AdPerformanceReportRequest();\r\n\t\trequest.setFormat(ReportFormat.CSV);\r\n\t\trequest.setReportName(\"Ad Report\");\r\n\t\trequest.setAggregation(NonHourlyReportAggregation.DAILY);\r\n\t\trequest.setReturnOnlyCompleteData(false);\r\n\r\n\t\tAccountThroughAdGroupReportScope scope = new AccountThroughAdGroupReportScope();\r\n\t\tArrayOflong accountIds = new ArrayOflong();\r\n\t\taccountIds.getLongs().add(authorizationData.getAccountId());\r\n\t\tscope.setAccountIds(accountIds);\r\n\t\tscope.setCampaigns(null);\r\n\t\tscope.setAdGroups(null); \r\n\t\trequest.setScope(scope);\r\n\r\n\t\tArrayOfAdPerformanceReportColumn value = new ArrayOfAdPerformanceReportColumn();\r\n\t\tList<AdPerformanceReportColumn> columns = value.getAdPerformanceReportColumns();\r\n\t\tString adFields = adsProperties.getProperty(\"api.bing.adPerformanceReport.fields\");\r\n\t\tif (adFields != null && adFields.length() > 2) {\r\n\t\t\tfor (String fieldId : adFields.split(\",\")) {\r\n\t\t\t\tcolumns.add(AdPerformanceReportColumn.fromValue(fieldId));\r\n\t\t\t}\r\n\t\t} else {\r\n\t\t\tcolumns.add(AdPerformanceReportColumn.AD_ID);\r\n\t\t\tcolumns.add(AdPerformanceReportColumn.AD_TITLE);\r\n\t\t\tcolumns.add(AdPerformanceReportColumn.TITLE_PART_1);\r\n\t\t\tcolumns.add(AdPerformanceReportColumn.TITLE_PART_2);\r\n\t\t\tcolumns.add(AdPerformanceReportColumn.AD_DESCRIPTION);\r\n\t\t\tcolumns.add(AdPerformanceReportColumn.AD_GROUP_ID);\r\n\t\t\tcolumns.add(AdPerformanceReportColumn.AD_GROUP_NAME);\r\n\t\t\tcolumns.add(AdPerformanceReportColumn.AD_GROUP_STATUS);\r\n\t\t\tcolumns.add(AdPerformanceReportColumn.AD_STATUS);\r\n\t\t\tcolumns.add(AdPerformanceReportColumn.CAMPAIGN_ID);\r\n\t\t\tcolumns.add(AdPerformanceReportColumn.CAMPAIGN_NAME);\r\n\t\t\tcolumns.add(AdPerformanceReportColumn.CLICKS);\r\n\t\t\tcolumns.add(AdPerformanceReportColumn.COST_PER_CONVERSION);\r\n\t\t\tcolumns.add(AdPerformanceReportColumn.SPEND);\r\n\t\t\tcolumns.add(AdPerformanceReportColumn.CONVERSION_RATE);\r\n\t\t\tcolumns.add(AdPerformanceReportColumn.IMPRESSIONS);\r\n\t\t\tcolumns.add(AdPerformanceReportColumn.DESTINATION_URL);\r\n\t\t\tcolumns.add(AdPerformanceReportColumn.FINAL_URL);\r\n\t\t\tcolumns.add(AdPerformanceReportColumn.DISPLAY_URL);\r\n\t\t\tcolumns.add(AdPerformanceReportColumn.TIME_PERIOD);\r\n\t\t}\r\n\t\trequest.setColumns(value);\r\n\r\n\t\tReportTime reportTime = new ReportTime();\r\n\t\tDate start = new Date();\r\n\t\tDate end = new Date();\r\n\t\tstart.setDay(from.get(Calendar.DAY_OF_MONTH));\r\n\t\tstart.setMonth(from.get(Calendar.MONTH)+1);\r\n\t\tstart.setYear(from.get(Calendar.YEAR));\r\n\t\tend.setDay(to.get(Calendar.DAY_OF_MONTH));\r\n\t\tend.setMonth(to.get(Calendar.MONTH)+1);\r\n\t\tend.setYear(to.get(Calendar.YEAR));\r\n\t\treportTime.setCustomDateRangeStart(start);\r\n\t\treportTime.setCustomDateRangeEnd(end);\r\n\t\trequest.setTime(reportTime);\r\n\r\n\t\treturn request;\r\n\t}",
"@RequestMapping(value = \"generateCreditLedgerReportPdf\", method = { RequestMethod.POST })\n\tpublic ResponseEntity<JsonResponse<List<RestDebitCreditLedgerModel>>> getCreditLedgerReportPdf(\n\t\t\t@RequestBody DataTableRequest request) {\n\t\tlogger.info(\"Method : getCreditLedgerReportPdf starts\");\n\t\tlogger.info(\"Method : getCreditLedgerReportPdf ends\");\n\t\treturn creditLedgerDao.getCreditLedgerReportPdf(request);\n\t}",
"public ReportInfo getCosmoReportInfo() {\n Document requestDocument = getRequestDocument();\n if (requestDocument == null) {\n return null;\n }\n return new ReportInfo(requestDocument.getRootElement(),\n getDepth(DEPTH_0),\n getDavSession());\n }",
"public CreateOrderRequest() {\n\t\t_pcs = new PropertyChangeSupport(this);\n\t}",
"public void createXMLFileForCertificate(Report report) {\n\ttry{\n\t\tFile outDir = new File(report.getXmlFilePath()); \n\t\tboolean isDirCreated = outDir.mkdirs();\n\t\tif (isDirCreated)\n\t\t\tlogger.info(\"In FileUploadDownload class fileUpload() method: upload file folder location created.\");\n\t\telse\n\t\t\tlogger.info(\"In FileUploadDownload class fileUpload() method: upload file folder location already exist.\");\n\t\t\n\t\tDocumentBuilderFactory docFactory = DocumentBuilderFactory.newInstance();\n\t\tDocumentBuilder docBuilder = docFactory.newDocumentBuilder();\n\t\t\n\t\t// root elements\n\t\tDocument doc = docBuilder.newDocument();\n\t\tElement rootElement = doc.createElement(\"root\");\n\t\tdoc.appendChild(rootElement);\n\t\n\t\t\tfor(Student student : report.getStudentList()){\n\t\t\t\t\t\n\t\t\t\tElement studentList = doc.createElement(\"student\");\n\t\t\t\trootElement.appendChild(studentList);\n\t\t\t\t\n\t\t\t\tElement schoolname = doc.createElement(\"schoolname\");\n\t\t\t\tschoolname.appendChild(doc.createTextNode((report.getSchoolDetails().getSchoolDetailsName() != null ? report.getSchoolDetails().getSchoolDetailsName() : \"\" )));\n\t\t\t\tstudentList.appendChild(schoolname);\n\t\t\t\t\n\t\t\t\tElement academicYear = doc.createElement(\"academicYear\");\n\t\t\t\tacademicYear.appendChild(doc.createTextNode((String) (report.getAcademicYear().getAcademicYearName()!= null ? report.getAcademicYear().getAcademicYearName() : \"\" )));\n\t\t\t\tstudentList.appendChild(academicYear);\n\t\t\t\t\n\t\t\t\tElement roll = doc.createElement(\"roll\");\n\t\t\t\troll.appendChild(doc.createTextNode((student.getRollNumber().toString()!=null?student.getRollNumber().toString():\"---------\")));\n\t\t\t\tstudentList.appendChild(roll);\n\t\t\t\t\n\t\t\t\t// nickname elements\n\t\t\t\tElement studentname = doc.createElement(\"studentname\");\n\t\t\t\tstudentname.appendChild(doc.createTextNode((student.getStudentName()!=null?student.getStudentName():\"---------------\")));\n\t\t\t\tstudentList.appendChild(studentname);\n\t\t\t\n\t\t\t\t\n\t\t\t\tElement house = doc.createElement(\"house\");\n\t\t\t\thouse.appendChild(doc.createTextNode((student.getHouse()!=null?student.getHouse():\"------\")));\n\t\t\t\tstudentList.appendChild(house);\n\t\t\t\n\t\t\t\tElement standard = doc.createElement(\"standard\");\n\t\t\t\tstandard.appendChild(doc.createTextNode((student.getStandard()!=null?student.getStandard():\"------\")));\n\t\t\t\tstudentList.appendChild(standard);\n\t\t\t\n\t\t\t\tElement section = doc.createElement(\"section\");\n\t\t\t\tsection.appendChild(doc.createTextNode((student.getSection()!=null?student.getSection():\"--------\")));\n\t\t\t\tstudentList.appendChild(section);\n\t\t\t\t\n\t\t\t//\tStudentResult setudentResult = new\n\t\t\t\t\n\t\t\t\tElement exam = doc.createElement(\"exam\");\n\t\t\t\texam.appendChild(doc.createTextNode((student.getStudentResultList().get(0).getExam()!=null?student.getStudentResultList().get(0).getExam():\"--------\")));\n\t\t\t\tstudentList.appendChild(exam);\n\t\t\t}\n\t\t\tTransformerFactory transformerFactory = TransformerFactory.newInstance();\n\t\t\tTransformer transformer = transformerFactory.newTransformer();\n\t\t\tDOMSource source = new DOMSource(doc);\t\t\n\t\t\tStreamResult result = new StreamResult(new File(report.getXmlFilePath()+report.getXmlFileName()));\n\t\t\t\n\t\t\t// Output to console for testing\n\t\t\t// StreamResult result = new StreamResult(System.out);\t\t\t\n\t\t\ttransformer.transform(source, result);\n\t\t}catch (ParserConfigurationException pce) {\n\t\t\tlogger.error(\"\",pce);\n\t\t} catch (TransformerException tfe) {\n\t\t\tlogger.error(tfe);\n\t\t}\n\t}",
"private BlockReportRequest(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) {\n super(builder);\n }",
"public static IReport createReport(InputStream in) throws ArfException {\r\n \treturn new Report(Report.getAssetReportCollection(in));\r\n }",
"private static DeliveryWrapper createDeliveryWrapper(SupportOrder supportOrder){\r\n\t\tDeliveryWrapper deliveryWrapper = new DeliveryWrapper();\r\n\t\t\r\n\t\tDelivery delivery = new Delivery();\r\n\t\tCustomer customer = new Customer();\r\n\t\tcustomer.setRegistry(supportOrder.getTarget().getRegistry());\r\n\t\tdelivery.setCustomer(customer);\r\n\t\tdelivery.setIssueTime(supportOrder.getStartDate());\r\n\t\tdelivery.setSeries(null);\r\n\t\tdelivery.setNumber(0);\r\n\t\tdelivery.setSecurityLevel(SecurityLevel.OFFICIAL);\r\n\t\tdelivery.setStatus(DeliveryStatus.PENDING);\r\n\t\t\r\n\t\tdeliveryWrapper.setDelivery(delivery);\r\n\t\t\r\n\t\treturn deliveryWrapper;\r\n\t}",
"protected PaymentDetail populatePaymentDetail(PaymentRequestDocument paymentRequestDocument, Batch batch) {\r\n PaymentDetail paymentDetail = new PaymentDetail();\r\n\r\n paymentDetail.setCustPaymentDocNbr(paymentRequestDocument.getDocumentNumber());\r\n Map preqItemMap = new HashMap();\r\n preqItemMap.put(\"purapDocumentIdentifier\", paymentRequestDocument.getPurapDocumentIdentifier());\r\n OlePaymentRequestDocument olePaymentRequestDocument = (OlePaymentRequestDocument) getBusinessObjectService().findByPrimaryKey(OlePaymentRequestDocument.class, preqItemMap);\r\n\r\n if (olePaymentRequestDocument.getPaymentMethodId() != null) {\r\n OlePaymentMethod olePaymentMethod = SpringContext.getBean(BusinessObjectService.class)\r\n .findBySinglePrimaryKey(OlePaymentMethod.class, olePaymentRequestDocument.getPaymentMethodId());\r\n paymentDetail.setPaymentMethodCode(olePaymentMethod.getPaymentMethod());\r\n }\r\n String invoiceNumber = paymentRequestDocument.getInvoiceNumber();\r\n if(invoiceNumber != null) {\r\n if (invoiceNumber.length() > 25) {\r\n invoiceNumber = invoiceNumber.substring(0, 25);\r\n }\r\n }\r\n paymentDetail.setInvoiceNbr(invoiceNumber);\r\n\r\n if (paymentRequestDocument.getPurchaseOrderIdentifier() != null) {\r\n paymentDetail.setPurchaseOrderNbr(paymentRequestDocument.getPurchaseOrderIdentifier().toString());\r\n }\r\n\r\n if (paymentRequestDocument.getPurchaseOrderDocument().getRequisitionIdentifier() != null) {\r\n paymentDetail.setRequisitionNbr(paymentRequestDocument.getPurchaseOrderDocument().getRequisitionIdentifier().toString());\r\n }\r\n\r\n if (paymentRequestDocument.getDocumentHeader().getOrganizationDocumentNumber() != null) {\r\n paymentDetail.setOrganizationDocNbr(paymentRequestDocument.getDocumentHeader().getOrganizationDocumentNumber());\r\n }\r\n\r\n paymentDetail.setCustomerInstitutionNumber(StringUtils.defaultString(paymentRequestDocument.getVendorCustomerNumber()));\r\n\r\n final String paymentRequestDocType = getDataDictionaryService().getDocumentTypeNameByClass(paymentRequestDocument.getClass());\r\n paymentDetail.setFinancialDocumentTypeCode(paymentRequestDocType);\r\n paymentDetail.setFinancialSystemOriginCode(OLEConstants.ORIGIN_CODE_KUALI);\r\n\r\n paymentDetail.setInvoiceDate(paymentRequestDocument.getInvoiceDate());\r\n paymentDetail.setOrigInvoiceAmount(paymentRequestDocument.getVendorInvoiceAmount());\r\n if (paymentRequestDocument.isUseTaxIndicator()) {\r\n paymentDetail.setNetPaymentAmount(paymentRequestDocument.getGrandPreTaxTotal()); // including discounts\r\n } else {\r\n paymentDetail.setNetPaymentAmount(paymentRequestDocument.getGrandTotal()); // including discounts\r\n }\r\n\r\n KualiDecimal shippingAmount = KualiDecimal.ZERO;\r\n KualiDecimal discountAmount = KualiDecimal.ZERO;\r\n KualiDecimal creditAmount = KualiDecimal.ZERO;\r\n KualiDecimal debitAmount = KualiDecimal.ZERO;\r\n\r\n for (Iterator iter = paymentRequestDocument.getItems().iterator(); iter.hasNext(); ) {\r\n PaymentRequestItem item = (PaymentRequestItem) iter.next();\r\n\r\n KualiDecimal itemAmount = KualiDecimal.ZERO;\r\n if (item.getTotalRemitAmount() != null) {\r\n itemAmount = item.getTotalRemitAmount();\r\n }\r\n if (PurapConstants.ItemTypeCodes.ITEM_TYPE_PMT_TERMS_DISCOUNT_CODE.equals(item.getItemTypeCode())) {\r\n discountAmount = discountAmount.add(itemAmount);\r\n } else if (PurapConstants.ItemTypeCodes.ITEM_TYPE_SHIP_AND_HAND_CODE.equals(item.getItemTypeCode())) {\r\n shippingAmount = shippingAmount.add(itemAmount);\r\n } else if (PurapConstants.ItemTypeCodes.ITEM_TYPE_FREIGHT_CODE.equals(item.getItemTypeCode())) {\r\n shippingAmount = shippingAmount.add(itemAmount);\r\n } else if (PurapConstants.ItemTypeCodes.ITEM_TYPE_MIN_ORDER_CODE.equals(item.getItemTypeCode())) {\r\n debitAmount = debitAmount.add(itemAmount);\r\n } else if (PurapConstants.ItemTypeCodes.ITEM_TYPE_MISC_CODE.equals(item.getItemTypeCode())) {\r\n if (itemAmount.isNegative()) {\r\n creditAmount = creditAmount.add(itemAmount);\r\n } else {\r\n debitAmount = debitAmount.add(itemAmount);\r\n }\r\n }\r\n }\r\n\r\n paymentDetail.setInvTotDiscountAmount(discountAmount);\r\n paymentDetail.setInvTotShipAmount(shippingAmount);\r\n paymentDetail.setInvTotOtherCreditAmount(creditAmount);\r\n paymentDetail.setInvTotOtherDebitAmount(debitAmount);\r\n\r\n paymentDetail.setPrimaryCancelledPayment(Boolean.FALSE);\r\n\r\n addAccounts(paymentRequestDocument, paymentDetail, paymentRequestDocType);\r\n addNotes(paymentRequestDocument, paymentDetail);\r\n\r\n return paymentDetail;\r\n }",
"@Override\n public Map<String, OEEReport> build() {\n return generators.entrySet().stream().collect(Collectors.toMap(\n entry -> entry.getKey(),\n entry -> entry.getValue().getReport()\n ));\n }",
"private static SOAPMessage createSOAPRequest(String soapAction, int type, String orderId, JSONObject orderInfo)\n\t\t\tthrows Exception {\n\t\tSystem.out.println(\"createSOAPRequest\");\n\t\tMessageFactory messageFactory = MessageFactory.newInstance();\n\t\tSOAPMessage soapMessage = messageFactory.createMessage();\n\t\tsoapMessage.getSOAPHeader().detachNode();\n\t\tsoapMessage.getSOAPPart().getEnvelope().setPrefix(\"s\");\n\t\tsoapMessage.getSOAPPart().getEnvelope().removeNamespaceDeclaration(\"SOAP-ENV\");\n\t\t// soapMessage.getSOAPHeader().setPrefix(\"s\");\n\t\tsoapMessage.getSOAPBody().setPrefix(\"s\");\n\n\t\t// String authorization = new\n\t\t// sun.misc.BASE64Encoder().encode((userName+\":\"+password).getBytes());\n\n\t\tcreateSoapEnvelope(soapMessage, type, orderId, orderInfo);\n\n\t\tMimeHeaders headers = soapMessage.getMimeHeaders();\n\t\t// headers.addHeader(\"Authorization\", \"Basic \" + authorization);\n\t\theaders.addHeader(\"SOAPAction\", soapAction);\n\n\t\tsoapMessage.saveChanges();\n\n\t\t/* Print the request message, just for debugging purposes */\n\t\tSystem.out.println(\"Request SOAP Message:\");\n\t\tsoapMessage.writeTo(System.out);\n\t\tSystem.out.println(\"\\n\");\n\n\t\treturn soapMessage;\n\t}",
"private org.apache.axiom.soap.SOAPEnvelope toEnvelope(org.apache.axiom.soap.SOAPFactory factory, net.wit.webservice.TerminalServiceXmlServiceStub.TerminalDownloadQueryForDay param, boolean optimizeContent, javax.xml.namespace.QName methodQName)\n throws org.apache.axis2.AxisFault{\n\n \n try{\n\n org.apache.axiom.soap.SOAPEnvelope emptyEnvelope = factory.getDefaultEnvelope();\n emptyEnvelope.getBody().addChild(param.getOMElement(net.wit.webservice.TerminalServiceXmlServiceStub.TerminalDownloadQueryForDay.MY_QNAME,factory));\n return emptyEnvelope;\n } catch(org.apache.axis2.databinding.ADBException e){\n throw org.apache.axis2.AxisFault.makeFault(e);\n }\n \n\n }",
"@VisibleForTesting\n OssindexClient createClient(final ComponentReportRequest request) {\n UserAgentSupplier userAgent = new UserAgentSupplier(new VersionSupplier().get())\n {\n /**\n * Customize with details from request if present.\n */\n @Override\n protected void customize(final UserAgentBuilder builder) {\n List<Product> products = request.getProducts();\n if (products != null) {\n for (Product product : products) {\n builder.product(product);\n }\n }\n }\n };\n Transport transport = new HttpClientTransport(userAgent);\n Marshaller marshaller = new GsonMarshaller();\n\n OssindexClientConfiguration config = request.getClientConfiguration();\n\n // maybe disable persistent cache\n boolean cacheDisabled = PropertyHelper.getBoolean(request.getProperties(), \"ossindex.cache.disable\", false);\n if (cacheDisabled) {\n // null will default to memory cache\n config.setCacheConfiguration(null);\n }\n else if (config.getCacheConfiguration() == null) {\n // if cache not otherwise configured, then prepare directory cache\n DirectoryCache.Configuration cacheConfig = new DirectoryCache.Configuration();\n\n // allow user to change the default location of the cache\n File cacheDir = PropertyHelper.getFile(request.getProperties(), \"ossindex.cache.directory\");\n if (cacheDir != null) {\n cacheConfig.setBaseDir(cacheDir.toPath());\n }\n\n // allow user to change the default cache expiration\n Duration expiration = PropertyHelper.getDuration(request.getProperties(), \"ossindex.cache.expiration\");\n if (expiration != null) {\n cacheConfig.setExpireAfter(expiration);\n }\n\n config.setCacheConfiguration(cacheConfig);\n }\n\n return new OssindexClientImpl(config, transport, marshaller);\n }",
"protected void processReport( HttpServletRequest request ) throws Exception\n \t{\n \t\tFile reportDocFile = new File( this.reportDocumentName );\n \t\t// String reportDesignName = ParameterAccessor.getReport( request );\n \t\tFile reportDesignDocFile = new File( reportDesignName );\n \n \t\tif ( reportDesignDocFile != null && reportDesignDocFile.exists( )\n \t\t\t\t&& reportDesignDocFile.isFile( ) && reportDocFile != null\n \t\t\t\t&& reportDocFile.exists( ) && reportDocFile.isFile( )\n \t\t\t\t&& \"get\".equalsIgnoreCase( request.getMethod( ) ) ) //$NON-NLS-1$\n \t\t{\n \t\t\tif ( reportDesignDocFile.lastModified( ) > reportDocFile\n \t\t\t\t\t.lastModified( )\n \t\t\t\t\t|| ParameterAccessor.isOverwrite( request ) )\n \t\t\t{\n \t\t\t\treportDocFile.delete( );\n \t\t\t}\n \t\t}\n \t}",
"public com.vodafone.global.er.decoupling.binding.request.RenewPurchasePackageRequest createRenewPurchasePackageRequest()\n throws javax.xml.bind.JAXBException\n {\n return new com.vodafone.global.er.decoupling.binding.request.impl.RenewPurchasePackageRequestImpl();\n }",
"private org.apache.axiom.soap.SOAPEnvelope toEnvelope(org.apache.axiom.soap.SOAPFactory factory, net.wit.webservice.TerminalServiceXmlServiceStub.TerminalDownloadQueryForMonth param, boolean optimizeContent, javax.xml.namespace.QName methodQName)\n throws org.apache.axis2.AxisFault{\n\n \n try{\n\n org.apache.axiom.soap.SOAPEnvelope emptyEnvelope = factory.getDefaultEnvelope();\n emptyEnvelope.getBody().addChild(param.getOMElement(net.wit.webservice.TerminalServiceXmlServiceStub.TerminalDownloadQueryForMonth.MY_QNAME,factory));\n return emptyEnvelope;\n } catch(org.apache.axis2.databinding.ADBException e){\n throw org.apache.axis2.AxisFault.makeFault(e);\n }\n \n\n }",
"private void buildOslpRequestSetConfiguration(final SetConfigurationDeviceRequest deviceRequest) {\n if (deviceRequest.getConfiguration().getRelayConfiguration() != null) {\n Collections.sort(\n deviceRequest.getConfiguration().getRelayConfiguration().getRelayMap(),\n (o1, o2) -> o1.getIndex().compareTo(o2.getIndex()));\n }\n\n final Oslp.SetConfigurationRequest setConfigurationRequest =\n this.mapper.map(deviceRequest.getConfiguration(), Oslp.SetConfigurationRequest.class);\n\n this.buildAndSignEnvelope(\n deviceRequest,\n Oslp.Message.newBuilder().setSetConfigurationRequest(setConfigurationRequest).build(),\n deviceRequest.getConfiguration());\n }",
"private Document createXMLDocumentStructure() {\r\n\t\tDocumentBuilderFactory dbf = DocumentBuilderFactory.newInstance();\r\n\t\tDocumentBuilder builder = null;\r\n\t\ttry {\r\n\t\t\tbuilder = dbf.newDocumentBuilder();\r\n\t\t} catch (ParserConfigurationException e) {\r\n\t\t\t// TODO Auto-generated catch block\r\n\t\t\te.printStackTrace();\r\n\t\t}\r\n\t\t\r\n\t\t// Creates the Document\r\n\t\tDocument serviceDoc = builder.newDocument();\r\n\t\t/*\r\n\t\t * Create the XML Tree\r\n\t\t */\r\n\t\tElement root = serviceDoc.createElement(\"service\");\r\n\r\n\t\tserviceDoc.appendChild(root);\r\n\t\treturn serviceDoc;\r\n\t}",
"public void buildDocument() {\n/* 248 */ setDocument(getDocumentLoader().getDocument(getClass()), \"text/html\", \"ISO-8859-1\");\n/* */ \n/* 250 */ syncAccessMethods();\n/* */ }",
"public com.vodafone.global.er.decoupling.binding.request.CustcareFullRefundEnlargementRequest createCustcareFullRefundEnlargementRequest()\n throws javax.xml.bind.JAXBException\n {\n return new com.vodafone.global.er.decoupling.binding.request.impl.CustcareFullRefundEnlargementRequestImpl();\n }",
"public GetBulkStateRequest build() {\n GetBulkStateRequest request = new GetBulkStateRequest();\n request.setStoreName(this.storeName);\n request.setKeys(this.keys);\n request.setMetadata(this.metadata);\n request.setParallelism(this.parallelism);\n return request;\n }",
"public void createXMLFileForGatePass(Report report) {\n\t\ttry{\n\t\t\tFile outDir = new File(report.getXmlFilePath()); \n\t\t\tboolean isDirCreated = outDir.mkdirs();\n\t\t\tif (isDirCreated)\n\t\t\t\tlogger.info(\"In FileUploadDownload class fileUpload() method: upload file folder location created.\");\n\t\t\telse\n\t\t\t\tlogger.info(\"In FileUploadDownload class fileUpload() method: upload file folder location already exist.\");\n\t\t\t\n\t\t\tDocumentBuilderFactory docFactory = DocumentBuilderFactory.newInstance();\n\t\t\tDocumentBuilder docBuilder = docFactory.newDocumentBuilder();\n\t\t\t\n\t\t\t// root elements\n\t\t\tDocument doc = docBuilder.newDocument();\n\t\t\tElement rootElement = doc.createElement(\"root\");\n\t\t\tdoc.appendChild(rootElement);\n\t\t\n\t\t\tElement studentList = doc.createElement(\"student\");\n\t\t\trootElement.appendChild(studentList);\n\t\t\t\n\t\t\tElement academicYear = doc.createElement(\"academicYear\");\n\t\t\tacademicYear.appendChild(doc.createTextNode((String) (report.getAcademicYear().getAcademicYearName()!= null ? report.getAcademicYear().getAcademicYearName() : \"\" )));\n\t\t\tstudentList.appendChild(academicYear);\n\t\t\t\t\n\t\t\tElement roll = doc.createElement(\"roll\");\n\t\t\troll.appendChild(doc.createTextNode((report.getReportCode().toString()!=null?report.getReportCode().toString():\"---------\")));\n\t\t\tstudentList.appendChild(roll);\n\t\t\t\n\t\t\tElement studentname = doc.createElement(\"studentname\");\n\t\t\tstudentname.appendChild(doc.createTextNode((report.getUpdatedBy()!=null?report.getUpdatedBy():\"---------------\")));\n\t\t\tstudentList.appendChild(studentname);\n\t\t\t\n\t\t\tTransformerFactory transformerFactory = TransformerFactory.newInstance();\n\t\t\tTransformer transformer = transformerFactory.newTransformer();\n\t\t\tDOMSource source = new DOMSource(doc);\t\t\n\t\t\tStreamResult result = new StreamResult(new File(report.getXmlFilePath()+report.getXmlFileName()));\n\t\t\t\n\t\t\ttransformer.transform(source, result);\n\t\t}catch (ParserConfigurationException pce) {\n\t\t\tpce.printStackTrace();\n\t\t\tlogger.error(\"\",pce);\n\t\t} catch (TransformerException tfe) {\n\t\t\ttfe.printStackTrace();\n\t\t\tlogger.error(tfe);\n\t\t}\n\n\t}",
"public com.vodafone.global.er.decoupling.binding.request.CatalogFullPackageRequest createCatalogFullPackageRequest()\n throws javax.xml.bind.JAXBException\n {\n return new com.vodafone.global.er.decoupling.binding.request.impl.CatalogFullPackageRequestImpl();\n }",
"private org.apache.axiom.soap.SOAPEnvelope toEnvelope(org.apache.axiom.soap.SOAPFactory factory, com.drore.cloud.tdp.service.IWsPmsSdkServiceStub.GetVehicleRecordPage param, boolean optimizeContent)\n throws org.apache.axis2.AxisFault{\n\n \n try{\n\n org.apache.axiom.soap.SOAPEnvelope emptyEnvelope = factory.getDefaultEnvelope();\n emptyEnvelope.getBody().addChild(param.getOMElement(com.drore.cloud.tdp.service.IWsPmsSdkServiceStub.GetVehicleRecordPage.MY_QNAME,factory));\n return emptyEnvelope;\n } catch(org.apache.axis2.databinding.ADBException e){\n throw org.apache.axis2.AxisFault.makeFault(e);\n }\n \n\n }",
"public void buildDocument() {\n/* 220 */ setDocument(getDocumentLoader().getDocument(getClass()), \"text/html\", \"ISO-8859-1\");\n/* */ \n/* 222 */ syncAccessMethods();\n/* */ }",
"private Builder() {\n super(TransferSerialMessage.SCHEMA$);\n }",
"public XMLDocument() {\r\n xml = new StringBuilder();\r\n }",
"private Message buildMessageToCXFBC(String serviceType,\tList<String> payload, String operationName) {\n\t\tMessage requestMessageToESB = new Message();\n\t\ttry {\n//\t\t\t Create and set the metadata\n\t\t\tgov.nih.nci.caxchange.messaging.Metadata metadata = new gov.nih.nci.caxchange.messaging.Metadata();\n\t\t\tmetadata.setTransactionControl(TransactionControls.PROCESS);\n\t\t\t/*\n\t\t\tCredentials credentials = new Credentials();\n\t\t\tcredentials.setUserName(\"[email protected]\");\n\t\t\tcredentials.setPassword(\"[email protected]\");\n\t\t\tmetadata.setCredentials(credentials);\n\t\t\t*/\n\t\t\t//metadata.setCaXchangeIdentifier(\"037068f0-23a8-11de-a5f1-d00caf9050fd\");\n\t\t\tmetadata.setExternalIdentifier(\"caExternalIdentifier\");\n\t\t\tmetadata.setOperationName(new ObjectFactory().createMetadataOperationName(operationName));\n\t\t\tmetadata.setServiceType(serviceType);\n\t\t\trequestMessageToESB.setMetadata(metadata);\n\t\t\t\n//\t\t\t Create and set the request\n\t\t\tRequest request = new Request();\n\t\t\tMessagePayload messagePayload = new MessagePayload();\n\t\t\tmessagePayload.setXmlSchemaDefinition(\"\");\n\t\t\tDocumentBuilderFactory dbf = DocumentBuilderFactory.newInstance();\n\t\t\tdbf.setNamespaceAware(true);\n\t\t\tDocumentBuilder db = dbf.newDocumentBuilder();\n\t\t\t\n\t\t\t//InputStream message = new ByteArrayInputStream(payload.get(0).getBytes());;\n\t\t\t\n\t\t\tfor(int i=0;i < payload.size() ; i++){ \n\t\t\t\tInputStream message = new ByteArrayInputStream(payload.get(i).getBytes());\n\t\t\t\tDocument payloadDoc = db.parse(message);\n\t\t\t\tmessagePayload.getAny().add(payloadDoc.getDocumentElement());\n\t\t\t}\t\n\t\t\t\n\t\t\t//Document payloadDoc = db.parse(message);\n\t\t//\tmessagePayload.setAny(payloadDoc.getDocumentElement());\n\t\t\trequest.setBusinessMessagePayload(messagePayload);\n\n\t\t\trequestMessageToESB.setRequest(request);\n\n\t\t} catch (Exception e) {\n\t\t\tlog.error(\"Exception building payload\" + e);\n\t\t\t//e.printStackTrace();\n\t\t}\n\n\t\treturn requestMessageToESB;\n\t}",
"public ReturnDocument setDocParams(OrderDocument odoc, ReturnDocument returnDoc) {\r\n\r\n returnDoc.setReturnOrderId(returnDoc.getDocumentNumber());\r\n returnDoc.setReturnDocumentStatusCode(MMConstants.OrderStatus.INITIATED);\r\n if (returnDoc.isReturnToVendorRequired())\r\n returnDoc.setReturnTypeCode(MMConstants.CheckinDocument.VENDOR_RETURN_ORDER_LINE);\r\n else\r\n returnDoc.setReturnTypeCode(MMConstants.CheckinDocument.CUSTOMER_ORDER_RETURN);\r\n\r\n Profile profile = null;\r\n\r\n if (odoc != null) {\r\n returnDoc.setCustomerProfileId(odoc.getCustomerProfileId());\r\n returnDoc.setOrderDocumentNumber(odoc.getDocumentNumber());\r\n returnDoc.setOrderDocument(odoc);\r\n\r\n returnDoc.setVendorHeaderGeneratedId(odoc.getVendorHeaderGeneratedId());\r\n returnDoc.setVendorDetailAssignedId(odoc.getVendorDetailAssignedId());\r\n returnDoc.setVendorNm(odoc.getVendorNm());\r\n\r\n returnDoc.setRetrievalBuildingCd(odoc.getDeliveryBuildingCd());\r\n Warehouse warehouse = odoc.getWarehouse();\r\n\r\n if (warehouse == null)\r\n warehouse = StoresPersistableBusinessObject.getObjectByPrimaryKey(Warehouse.class,\r\n odoc.getWarehouseCd());\r\n\r\n if (warehouse != null) {\r\n profile = warehouse.getBillingProfile();\r\n }\r\n }\r\n else {\r\n String initiator = GlobalVariables.getUserSession().getPerson().getPrincipalName();\r\n profile = SpringContext.getBean(ProfileService.class).getDefaultCustomerProfile(\r\n initiator);\r\n }\r\n\r\n if (profile != null)\r\n returnDoc.setCustomerProfileId(profile.getProfileId());\r\n returnDoc.getDocumentHeader().setDocumentDescription(\r\n \"Return of \" + returnDoc.getDocumentNumber());\r\n\r\n return returnDoc;\r\n }",
"protected String buildHeader(String documentType) {\n return (\"<?xml version=\\\"1.0\\\" ?>\" + \n \"\\n<!DOCTYPE \" + \n documentType + \n \" SYSTEM \\\"\" + \n ConocoInformation.MESSAGE_DTD + \n \"\\\">\\n\");\n }",
"private Report(Builder builder) {\n this.inputFileDir = builder.inputFileDir();\n this.inputFileName = builder.inputFileName();\n\n this.outputFileDir = builder.outputFileDir();\n this.outputFileName = builder.outputFileName();\n\n this.moduleList = builder.moduleList();\n\n this.outputHandler = builder.outputHandler();\n }",
"public WorldUps.UDeliveryMade.Builder getDeliveredBuilder(\n int index) {\n return getDeliveredFieldBuilder().getBuilder(index);\n }",
"public Map<String, String> initScenwebServiceRequest(String wsdlURL, String bodyElem, List<String[]> credentials, List<String[]> request, List<String[]> variables, List<String[]> debug) throws Exception {\r\n // create soap body\r\n SOAPElement soapBody = createSOAPBodyOdiInvoke();\r\n SOAPElement soapBodyElem = soapBody.addChildElement(bodyElem, \"odi\");\r\n \r\n SOAPElement creds = soapBodyElem.addChildElement(\"Credentials\");\r\n // loop to add credentials parameters\r\n for (Iterator<String[]> credentialsIt = credentials.iterator(); credentialsIt.hasNext(); ) {\r\n String[] param = credentialsIt.next();\r\n if(param[1]!=\"\") {\r\n SOAPElement childElement = creds.addChildElement(param[0]);\r\n childElement.addTextNode(param[1]);\r\n }\r\n }\r\n \r\n \r\n SOAPElement req = soapBodyElem.addChildElement(\"Request\");\r\n // loop to add request parameters\r\n for (Iterator<String[]> requestIt = request.iterator(); requestIt.hasNext(); ) {\r\n String[] param = requestIt.next();\r\n if(param[1]!=\"\") {\r\n SOAPElement childElement = req.addChildElement(param[0]);\r\n childElement.addTextNode(param[1]);\r\n }\r\n }\r\n /*\r\n // loop to add variables and values\r\n for (Iterator<String[]> variablesIt = variables.iterator(); variablesIt.hasNext(); ) {\r\n String[] param = variablesIt.next();\r\n if(param[2]!=\"\") {\r\n SOAPElement childElement = req.addChildElement(param[0],param[1]);\r\n childElement.addTextNode(param[2]);\r\n }\r\n }\r\n */\r\n \r\n SOAPElement deb = soapBodyElem.addChildElement(\"Debug\");\r\n // loop to add debug params values\r\n for (Iterator<String[]> debugIt = debug.iterator(); debugIt.hasNext(); ) {\r\n String[] param = debugIt.next();\r\n if(param[1]!=\"\") {\r\n SOAPElement childElement = deb.addChildElement(param[0]);\r\n childElement.addTextNode(param[1]);\r\n }\r\n }\r\n \r\n // save the message\r\n soapRequestMessage.saveChanges();\r\n /* Print the request message */\r\n System.out.print(\"Request SOAP Message:\");\r\n soapRequestMessage.writeTo(System.out);\r\n \r\n // send request and get response\r\n SOAPMessage soapResponse = createSOAPRequest(wsdlURL);\r\n \r\n \r\n // store response\r\n SOAPBody responseSoapBody = soapResponse.getSOAPBody();\r\n Iterator nodeIt = responseSoapBody.getChildElements();\r\n \r\n // get the full contents of the SOAP message\r\n return getContents(nodeIt,\" \");\r\n \r\n }",
"private void generateIncomingReport() {\r\n\r\n\t\tStringBuilder stringBuilder = new StringBuilder();\r\n\t\tstringBuilder.append(\"\\n----------------------------------------\\n\")\r\n\t\t\t\t.append(\" Incoming Daily Amount \\n\")\r\n\t\t\t\t.append(\"----------------------------------------\\n\")\r\n\t\t\t\t.append(\" Date | Trade Amount \\n\")\r\n\t\t\t\t.append(\"-----------------+----------------------\\n\");\r\n\t\tallIncomings.entrySet().forEach(\r\n\t\t\t\tkey -> stringBuilder.append(key.getKey() + \" | \" + key.getValue().get() + \"\\n\"));\r\n\t\tdataWriter.write(stringBuilder.toString());\r\n\t}",
"@Override\n\tpublic ReportDesign buildReportDesign(ReportDefinition reportDefinition) {\n\t\treturn createExcelTemplateDesign(getExcelDesignUuid(), reportDefinition, \"monthlyDhis2Reporting.xls\");\n\t}",
"private org.apache.axiom.soap.SOAPEnvelope toEnvelope(org.apache.axiom.soap.SOAPFactory factory, com.drore.cloud.tdp.service.IWsPmsSdkServiceStub.GetEntrancePage param, boolean optimizeContent)\n throws org.apache.axis2.AxisFault{\n\n \n try{\n\n org.apache.axiom.soap.SOAPEnvelope emptyEnvelope = factory.getDefaultEnvelope();\n emptyEnvelope.getBody().addChild(param.getOMElement(com.drore.cloud.tdp.service.IWsPmsSdkServiceStub.GetEntrancePage.MY_QNAME,factory));\n return emptyEnvelope;\n } catch(org.apache.axis2.databinding.ADBException e){\n throw org.apache.axis2.AxisFault.makeFault(e);\n }\n \n\n }",
"private QueryGetCertificateRequest(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) {\n super(builder);\n }",
"private CalRequest(com.google.protobuf.GeneratedMessage.Builder<?> builder) {\n super(builder);\n this.unknownFields = builder.getUnknownFields();\n }",
"@Nonnull\n public static UBL23WriterBuilder <TransportExecutionPlanRequestType> transportExecutionPlanRequest ()\n {\n return UBL23WriterBuilder.create (TransportExecutionPlanRequestType.class);\n }",
"public static final Document parse(final InputSource input) {\r\n if (logB.isDebugEnabled()) {\r\n logB.debug(\"XmlFactory.parse : begin\");\r\n }\r\n\r\n Document document = null;\r\n\r\n try {\r\n input.setEncoding(ENCODING);\r\n document = getFactory().newDocumentBuilder().parse(input);\r\n } catch (final SAXException se) {\r\n logB.error(\"XmlFactory.parse : error\", se);\r\n } catch (final IOException ioe) {\r\n logB.error(\"XmlFactory.parse : error\", ioe);\r\n } catch (final ParserConfigurationException pce) {\r\n logB.error(\"XmlFactory.parse : error\", pce);\r\n }\r\n\r\n if (logB.isInfoEnabled()) {\r\n logB.info(\"XmlFactory.parse : exit : \" + document);\r\n }\r\n\r\n return document;\r\n }",
"public ReportSheet createReport(RepletRequest req) throws RepletException\n {\n ss = (StyleSheet) theReport;\n try\n {\n bindMessages(req);\n bindData(req);\n }\n catch (Exception e)\n {\n ReportsPackage.logError(\"Problem creating report\", e);\n throw new RepletException(e.getMessage());\n }\n return theReport;\n }",
"public Builder clearDeliver() {\n if (deliverBuilder_ == null) {\n if (stepInfoCase_ == 12) {\n stepInfoCase_ = 0;\n stepInfo_ = null;\n onChanged();\n }\n } else {\n if (stepInfoCase_ == 12) {\n stepInfoCase_ = 0;\n stepInfo_ = null;\n }\n deliverBuilder_.clear();\n }\n return this;\n }",
"private ReportRequest getAdGroupReport(Calendar from, Calendar to) {\r\n\t\tAdGroupPerformanceReportRequest request = new AdGroupPerformanceReportRequest();\r\n\t\trequest.setFormat(ReportFormat.CSV);\r\n\t\trequest.setReportName(\"Ad Group Report\");\r\n\t\trequest.setAggregation(ReportAggregation.HOURLY);\r\n\t\trequest.setReturnOnlyCompleteData(false);\r\n\r\n\t\tAccountThroughAdGroupReportScope scope = new AccountThroughAdGroupReportScope();\r\n\t\tArrayOflong accountIds = new ArrayOflong();\r\n\t\taccountIds.getLongs().add(authorizationData.getAccountId());\r\n\t\tscope.setAccountIds(accountIds);\r\n\t\tscope.setCampaigns(null);\r\n\t\tscope.setAdGroups(null); \r\n\t\trequest.setScope(scope);\r\n\r\n\t\tArrayOfAdGroupPerformanceReportColumn value = new ArrayOfAdGroupPerformanceReportColumn();\r\n\t\tList<AdGroupPerformanceReportColumn> columns = value.getAdGroupPerformanceReportColumns();\r\n\t\tString adFields = adsProperties.getProperty(\"api.bing.adGroupPerformanceReport.fields\");\r\n\t\tif (adFields != null && adFields.length() > 2) {\r\n\t\t\tfor (String fieldId : adFields.split(\",\")) {\r\n\t\t\t\tcolumns.add(AdGroupPerformanceReportColumn.fromValue(fieldId));\r\n\t\t\t}\r\n\t\t} else {\r\n\t\t\tcolumns.add(AdGroupPerformanceReportColumn.AD_GROUP_ID);\r\n\t\t\tcolumns.add(AdGroupPerformanceReportColumn.AD_GROUP_NAME);\r\n\t\t\tcolumns.add(AdGroupPerformanceReportColumn.CAMPAIGN_ID);\r\n\t\t\tcolumns.add(AdGroupPerformanceReportColumn.CAMPAIGN_NAME);\r\n\t\t\tcolumns.add(AdGroupPerformanceReportColumn.TIME_PERIOD);\r\n\t\t\tcolumns.add(AdGroupPerformanceReportColumn.CLICKS);\r\n\t\t\tcolumns.add(AdGroupPerformanceReportColumn.COST_PER_CONVERSION);\r\n\t\t\tcolumns.add(AdGroupPerformanceReportColumn.SPEND);\r\n\t\t\tcolumns.add(AdGroupPerformanceReportColumn.CONVERSION_RATE);\r\n\t\t\tcolumns.add(AdGroupPerformanceReportColumn.IMPRESSIONS);\r\n\t\t}\r\n\t\trequest.setColumns(value);\r\n\r\n\t\tReportTime reportTime = new ReportTime();\r\n\t\tDate start = new Date();\r\n\t\tDate end = new Date();\r\n\t\tstart.setDay(from.get(Calendar.DAY_OF_MONTH));\r\n\t\tstart.setMonth(from.get(Calendar.MONTH)+1);\r\n\t\tstart.setYear(from.get(Calendar.YEAR));\r\n\t\tend.setDay(to.get(Calendar.DAY_OF_MONTH));\r\n\t\tend.setMonth(to.get(Calendar.MONTH)+1);\r\n\t\tend.setYear(to.get(Calendar.YEAR));\r\n\t\treportTime.setCustomDateRangeStart(start);\r\n\t\treportTime.setCustomDateRangeEnd(end);\r\n\t\trequest.setTime(reportTime);\r\n\r\n\t\treturn request;\r\n\t}",
"public void buildDocument() {\n/* 310 */ setDocument(getDocumentLoader().getDocument(getClass()), \"text/html\", \"ISO-8859-1\");\n/* */ \n/* 312 */ syncAccessMethods();\n/* */ }",
"private CalRequest(\r\n\t\t\t\tcom.google.protobuf.GeneratedMessage.Builder<?> builder) {\r\n\t\t\tsuper(builder);\r\n\t\t\tthis.unknownFields = builder.getUnknownFields();\r\n\t\t}",
"byte[] renderFormAsPDF(Document srcDoc) throws GreensheetBaseException {\r\n\r\n\t\tbyte[] result = null;\r\n\r\n\t\tByteArrayInputStream inputStream = null;\r\n\t\tByteArrayOutputStream outputStream = null;\r\n\r\n\t\ttry {\r\n\r\n\t\t\tDocument foDoc = this.generateFo(srcDoc);\r\n\t\t\tString docXml = foDoc.asXML();\r\n\t\t\t// Replace the default UTF-8 encoding with ISO-8859-1 to take care\r\n\t\t\t// of the special/extended character set.\r\n\t\t\t// unfortunately, dom4j 1.4 has a bug whereby .asXML() method\r\n\t\t\t// returns the encoding as UTF-8 only. Hence this approach.\r\n\t\t\t// using dom4j 1.6.1 has its own set of problems.\r\n\r\n\t\t\tdocXml = this.Replace(docXml, \"UTF-8\", \"ISO-8859-1\");\r\n\t\t\tinputStream = new ByteArrayInputStream(docXml.getBytes());\r\n\t\t\toutputStream = new ByteArrayOutputStream();\r\n\r\n\t\t\t// Setup FOP\r\n\t\t\tLog4JLogger l4Jlogger = new Log4JLogger(logger);\r\n\t\t\tInputSource inputSource = new InputSource(inputStream);\r\n\t\t\tDriver driver = new Driver(inputSource, outputStream);\r\n\t\t\tdriver.setLogger(l4Jlogger);\r\n\t\t\tdriver.setRenderer(Driver.RENDER_PDF);\r\n\r\n\t\t\tdriver.run();\r\n\r\n\t\t\tresult = outputStream.toByteArray();\r\n\r\n\t\t} catch (Exception e) {\r\n\t\t\tthrow new GreensheetBaseException(\"error rendering PDF\", e);\r\n\t\t} finally {\r\n\t\t\ttry {\r\n\t\t\t\tinputStream.close();\r\n\t\t\t\toutputStream.close();\r\n\t\t\t} catch (Exception e) {\r\n\t\t\t\tthrow new GreensheetBaseException(\"error rendering PDF\", e);\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn result;\r\n\t}",
"private com.google.protobuf.SingleFieldBuilderV3<\n entities.Torrent.DownloadRequest, entities.Torrent.DownloadRequest.Builder, entities.Torrent.DownloadRequestOrBuilder>\n getDownloadRequestFieldBuilder() {\n if (downloadRequestBuilder_ == null) {\n downloadRequestBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<\n entities.Torrent.DownloadRequest, entities.Torrent.DownloadRequest.Builder, entities.Torrent.DownloadRequestOrBuilder>(\n getDownloadRequest(),\n getParentForChildren(),\n isClean());\n downloadRequest_ = null;\n }\n return downloadRequestBuilder_;\n }",
"private void Obtengo_el_documento(String inputString) throws ParserConfigurationException, UnsupportedEncodingException, SAXException, IOException {\n DocumentBuilderFactory factory\n = DocumentBuilderFactory.newInstance();\n DocumentBuilder builder = factory.newDocumentBuilder();\n\n //\n StringBuilder xmlStringBuilder = new StringBuilder();\n xmlStringBuilder.append(inputString);\n ByteArrayInputStream input = new ByteArrayInputStream(\n xmlStringBuilder.toString().getBytes(\"UTF-8\"));\n \n doc = builder.parse(input);\n \n }",
"@RequestMapping(value = \"/downloadunitreports/{dept}/{unit}/{fromDate}/{toDate}/{search}/\")\n @CrossOrigin\n public byte[] downloadUnitReports(Authentication authentication, @PathVariable int dept, @PathVariable int unit, @PathVariable String fromDate, @PathVariable String toDate,@PathVariable String search, HttpServletRequest request) throws JsonProcessingException\n {\n if(!userService.userIsDepartmentUnitAuthority(authentication.getName(), dept, unit)) {\n throw new BadCredentialsException(\"\");\n }\n\n if (fromDate.equals(\"undefined\")) {\n fromDate = \"1970-01-01\";\n }\n if (toDate.equals(\"undefined\")) {\n toDate = \"2200-01-01\";\n }\n System.out.println(\"from date: \" + fromDate);\n System.out.println(\"to date: \" + toDate);\n\n ByteArrayInputStream pdfByteArrayInput = unitReportService.compileReportsIntoPdf(dept,unit,fromDate,toDate,search);\n\n return read(pdfByteArrayInput);\n\n }",
"public ApplicantNotification getApplicantNotificationReport(String vacancyNumber){\r\n\r\n\t\tApplicantNotification applicantNotification = new ApplicantNotification();\r\n\t\tapplicantNotification.setVacancyNumber(vacancyNumber);\r\n\r\n\t\tPrompt applicantNotificationPrompt = new Prompt(properties.getReportPromptVacancy(), vacancyNumber, vacancyNumber);\r\n\t\tCognosReport applicantNotificationReport = new CognosReport(properties.getApplicantNotificationReportName(), properties.getApplicantNotificationReportPath(), properties.getReportFormatHTML(), applicantNotificationPrompt);\r\n\r\n\t\tif(properties.getProgramMode().equalsIgnoreCase(properties.getTestMode())){//test mode\r\n\t\t\tlog.info(\"**Application is running in TEST MODE: Pre-downloaded Applicant Notification report will be used to generate the response.\");\r\n\t\t\tString report = properties.getApplicantNotificationFileLocation() + File.separator + vacancyNumber + \".html\";\r\n\t\t\tFile htmlFile = new File(report);\r\n\t\t\tif(htmlFile.exists() && htmlFile.isFile()){\r\n\t\t\t\tlog.info(\"Pulling HTML report for \" + properties.getApplicantNotificationReportName() + \" [\" + report + \"].\");\r\n\r\n\t\t\t\tStringBuilder contentBuilder = new StringBuilder();\r\n\t\t\t\ttry {\r\n\t\t\t\t\tBufferedReader in = new BufferedReader(new FileReader(report));\r\n\t\t\t\t\tString str;\r\n\t\t\t\t\twhile ((str = in.readLine()) != null) {\r\n\t\t\t\t\t\tcontentBuilder.append(str);\r\n\t\t\t\t\t}\r\n\t\t\t\t\tin.close();\r\n\t\t\t\t} catch (IOException e) {\r\n\t\t\t\t\tlog.error(e.getMessage());\r\n\t\t\t\t}\r\n\t\t\t\tapplicantNotification.setHtmlResponse(contentBuilder.toString());\r\n\t\t\t}else{\r\n\t\t\t\tapplicantNotification.setHtmlResponse(properties.getNoFileException() + \"File: \" + report);\r\n\t\t\t}\r\n\t\t}else{//normal or production mode\r\n\t\t\tlog.info(\"Connecting to USAS - Cognos Server to get \" + properties.getApplicantNotificationReportName() + \" report for Vacancy Number [\"+vacancyNumber+\"].\"); \r\n\t\t\tapplicantNotification.setHtmlResponse(client.processReportDataRequest(applicantNotificationReport).getResponse());\r\n\t\t}\r\n\t\tif(applicantNotification.getVacancyNumber().length() == 0)//setting vacancy number for response if not available\t\t\t\r\n\t\t\tapplicantNotification.setVacancyNumber(vacancyNumber);\r\n\t\tlog.info(applicantNotification.toString());\r\n\t\treturn applicantNotification;\r\n\t}",
"public Report createReportFromInputData(InputData inputData)\n {\n List<ReportRow> rows = generateRows(inputData.compact, inputData);\n \n Report reportModel = new Report();\n reportModel.setTitle(inputData.title);\n reportModel.setSubtitle(inputData.subtitle);\n reportModel.setDates(inputData.dates);\n \n reportModel.addColumn(\"Manufacturer\", \"manufacturerName\");\n reportModel.addColumn(\"Product Name/Code\", \"productNameAndCode\");\n if (!inputData.compact)\n reportModel.addColumn(\"Contract\", \"contractName\");\n \n int asize = inputData.distributors.size();\n for (int i = 0; i < asize; i++)\n {\n reportModel.addColumn(inputData.distributors.get(i), \"formattedPrices[\" + i + \"]\");\n }\n for (ReportRow row : rows)\n reportModel.addRow(row);\n return reportModel;\n }",
"public com.vodafone.global.er.decoupling.binding.request.CatalogFullServiceRequest createCatalogFullServiceRequest()\n throws javax.xml.bind.JAXBException\n {\n return new com.vodafone.global.er.decoupling.binding.request.impl.CatalogFullServiceRequestImpl();\n }",
"public void createXMLFileForNOC(Report report) {\n\ttry{\n\t\tFile outDir = new File(report.getXmlFilePath()); \n\t\tboolean isDirCreated = outDir.mkdirs();\n\t\tif (isDirCreated)\n\t\t\tlogger.info(\"In FileUploadDownload class fileUpload() method: upload file folder location created.\");\n\t\telse\n\t\t\tlogger.info(\"In FileUploadDownload class fileUpload() method: upload file folder location already exist.\");\n\t\t\n\t\tDocumentBuilderFactory docFactory = DocumentBuilderFactory.newInstance();\n\t\tDocumentBuilder docBuilder = docFactory.newDocumentBuilder();\n\t\t\n\t\t// root elements\n\t\tDocument doc = docBuilder.newDocument();\n\t\tElement rootElement = doc.createElement(\"root\");\n\t\tdoc.appendChild(rootElement);\n\t\n\t\t\t//for(Student student : report.getStudentList()){\n\t\t\t\t\t\n\t\t\t\tElement studentList = doc.createElement(\"student\");\n\t\t\t\trootElement.appendChild(studentList);\n\t\t\t\t\n\t\t\t\t/*Element schoolname = doc.createElement(\"schoolname\");\n\t\t\t\tschoolname.appendChild(doc.createTextNode((report.getSchoolDetails().getSchoolDetailsName() != null ? report.getSchoolDetails().getSchoolDetailsName() : \"\" )));\n\t\t\t\tstudentList.appendChild(schoolname);*/\n\t\t\t\t\n\t\t\t\tElement academicYear = doc.createElement(\"academicYear\");\n\t\t\t\tacademicYear.appendChild(doc.createTextNode((String) (report.getAcademicYear().getAcademicYearName()!= null ? report.getAcademicYear().getAcademicYearName() : \"\" )));\n\t\t\t\tstudentList.appendChild(academicYear);\n\t\t\t\t\n\t\t\t\tElement roll = doc.createElement(\"roll\");\n\t\t\t\troll.appendChild(doc.createTextNode((report.getReportCode().toString()!=null?report.getReportCode().toString():\"---------\")));\n\t\t\t\tstudentList.appendChild(roll);\n\t\t\t\t\n\t\t\t\tElement studentname = doc.createElement(\"studentname\");\n\t\t\t\tstudentname.appendChild(doc.createTextNode((report.getUpdatedBy()!=null?report.getUpdatedBy():\"---------------\")));\n\t\t\t\tstudentList.appendChild(studentname);\n\t\t\t\n\t\t\t\t\n\t\t\t//}\n\t\t\tTransformerFactory transformerFactory = TransformerFactory.newInstance();\n\t\t\tTransformer transformer = transformerFactory.newTransformer();\n\t\t\tDOMSource source = new DOMSource(doc);\t\t\n\t\t\tStreamResult result = new StreamResult(new File(report.getXmlFilePath()+report.getXmlFileName()));\n\t\t\t\n\t\t\t// Output to console for testing\n\t\t\t// StreamResult result = new StreamResult(System.out);\t\t\t\n\t\t\ttransformer.transform(source, result);\n\t\t}catch (ParserConfigurationException pce) {\n\t\t\tpce.printStackTrace();\n\t\t\tlogger.error(\"\",pce);\n\t\t} catch (TransformerException tfe) {\n\t\t\ttfe.printStackTrace();\n\t\t\tlogger.error(tfe);\n\t\t}\n\t}",
"public Document buildDocument(Document doc) throws IOException {\n\t\treturn config.build(taxonomyWriter, doc);\n\t}",
"private void buildReport() {\n StringBuilder stringBuilder = new StringBuilder();\n\n // Header of report\n stringBuilder.append(\"Games\\tCPU wins\\t\"\n + \"Human wins\\tDraw avg\\tMax rounds\\n\");\n stringBuilder.append(\"=============================================\\n\");\n\n // shows the number of overall games\n stringBuilder.append(dbConnection.executeQuery(\"SELECT COUNT(game_id) FROM game\", \"count\"));\n stringBuilder.append(\"\\t\");\n // shows the number of times the computer won\n stringBuilder.append(dbConnection.executeQuery(\"SELECT COUNT(game_id) FROM game WHERE winner = 'CPU'\", \"count\"));\n stringBuilder.append(\"\\t\");\n // shows the number of times the human player won\n stringBuilder.append(dbConnection.executeQuery(\"SELECT COUNT(game_id) FROM game WHERE winner = 'human'\", \"count\"));\n stringBuilder.append(\"\\t\");\n // shows the average number of draws per game\n stringBuilder.append((int)Float.parseFloat(dbConnection.executeQuery(\"SELECT AVG(draws) FROM game\", \"avg\")));\n stringBuilder.append(\"\\t\");\n // shows the maximum number of rounds played\n stringBuilder.append(dbConnection.executeQuery(\"SELECT MAX(rounds) FROM game\", \"max\"));\n\n // Converts stringBuilder to a String\n reportContent = stringBuilder.toString();\n }",
"public GetReceivedReportResponse getReceivedReport(GetReceivedReport request) {\n\t\treturn null;\n\t}",
"public void buildDocument( InputStream is ) {\n DocumentBuilderFactory dbFactory = DocumentBuilderFactory.newInstance();\n DocumentBuilder dBuilder = null;\n try {\n dBuilder = dbFactory.newDocumentBuilder();\n } catch ( ParserConfigurationException ex ) {\n Global.warning( \"Parser configuration exception: \" + ex.getMessage() );\n }\n try {\n doc = dBuilder.parse( is );\n } catch ( SAXException ex ) {\n Global.warning( \"SAX parser exception: \" + ex.getMessage() );\n } catch ( IOException ex ) {\n Global.warning( \"IO exception: \" + ex.getMessage() );\n }\n\n }",
"private org.apache.axiom.soap.SOAPEnvelope toEnvelope(org.apache.axiom.soap.SOAPFactory factory, net.wit.webservice.TerminalServiceXmlServiceStub.DirectCharge param, boolean optimizeContent, javax.xml.namespace.QName methodQName)\n throws org.apache.axis2.AxisFault{\n\n \n try{\n\n org.apache.axiom.soap.SOAPEnvelope emptyEnvelope = factory.getDefaultEnvelope();\n emptyEnvelope.getBody().addChild(param.getOMElement(net.wit.webservice.TerminalServiceXmlServiceStub.DirectCharge.MY_QNAME,factory));\n return emptyEnvelope;\n } catch(org.apache.axis2.databinding.ADBException e){\n throw org.apache.axis2.AxisFault.makeFault(e);\n }\n \n\n }",
"@Test\n\tpublic void generatePosGosPaymentsReport(){\n\t\t\t\tWebDriver driver = new FirefoxDriver();\n\t\t\t\t// Alternatively the same thing can be done like this\n\t\t // driver.get(\"http://www.google.com\");\n\t\t\t\tdriver.navigate().to(determineUrl());\n\t\t\t\t// Find the text input element by its name\n\t\t\t\tWebElement user_name = driver.findElement(By.id(\"user_email\"));\n\t\t\t\tuser_name.sendKeys(user);\n\t\t\t\t\n\t\t\t\tWebElement password = driver.findElement(By.id(\"user_password\"));\n\t\t\t\tpassword.sendKeys(password_login);\n\t\t\t\tpassword.submit();\n\t\t\t\t\n\t\t\t\tWebElement select_venue = driver.findElement(By.id(\"change_venue\"));\n\t\t\t\tselect_venue.sendKeys(venue);\n\t\t\t\tselect_venue.submit();\n\t\t\t\t\n\t\t\t\t\n\t\t\t\tWebElement report = driver.findElement(By.linkText(\"Reporting\"));\n\t\t\t\treport.click();\n\t\t\t\t\n\t\t\t\tWebElement select_report = driver.findElement(By.id(\"report_type_chooser\"));\n\t\t\t\tselect_report.sendKeys(\"Pos to Gos Report\");\n\t\t\t\tWebElement select_event = driver.findElement(By.id(\"report_event\"));\n\t\t\t\tselect_event.sendKeys(event);\n\t\t\t\tselect_event.submit();\n\t\t\t\tdriver.close();\n\t\t\n\t}",
"public static DocumentBuilder createDocumentBuilder() {\n\t\treturn createDocumentBuilder(DefaultEntityResolver.getInstance());\n\t}",
"public DocumentBuilder newDocumentBuilder()\n throws ParserConfigurationException {\n return(new DocumentBuilderImpl(this.isNamespaceAware(),\n this.isValidating()));\n }",
"public Report() {\n\t\tsuper();\n\t}",
"private OrderRequest buildRequestBody(OriginalOrder originalOrder) {\n String currency = \"MXN\";\n\n OrderRequest orderRequest = new OrderRequest();\n orderRequest.intent(originalOrder.getIntent());\n\n ApplicationContext applicationContext = new ApplicationContext()\n .brandName(originalOrder.getBrandName())\n .landingPage(originalOrder.getLandingPage())\n .shippingPreference(originalOrder.getShippingPreference());\n orderRequest.applicationContext(applicationContext);\n System.out.println(\"item Category: \"+ originalOrder.getItems().get(0).getCategory());\n List<PurchaseUnitRequest> purchaseUnitRequests = new ArrayList<PurchaseUnitRequest>();\n PurchaseUnitRequest purchaseUnitRequest = new PurchaseUnitRequest()\n .referenceId(originalOrder.getReferenceId())\n .description(originalOrder.getDescription())\n .customId(originalOrder.getCustomId())\n .softDescriptor(originalOrder.getSoftDescriptor())\n .amount(new AmountWithBreakdown().currencyCode(currency).value(originalOrder.getTotal())\n .breakdown(\n new AmountBreakdown().itemTotal(new Money().currencyCode(currency).value(originalOrder.getTotal()))\n .shipping(new Money().currencyCode(currency).value(originalOrder.getShipping()))\n .handling(new Money().currencyCode(currency).value(originalOrder.getHandling()))\n .taxTotal(new Money().currencyCode(currency).value(originalOrder.getTaxTotal()))\n .shippingDiscount(new Money().currencyCode(currency).value(originalOrder.getShippingDiscount()))))\n .items(new ArrayList<Item>() {\n {\n add(new Item()\n .name(originalOrder.getItems().get(0).getName())\n .description(originalOrder.getItems().get(0).getDescription())\n .sku(originalOrder.getItems().get(0).getSku())\n .unitAmount(new Money().currencyCode(currency).value(originalOrder.getItems().get(0).getUnitAmount()))\n .tax(new Money().currencyCode(currency).value(originalOrder.getItems().get(0).getTax()))\n .quantity(originalOrder.getItems().get(0).getQuantity())\n .category(originalOrder.getItems().get(0).getCategory()));\n }\n })\n .shipping(new ShippingDetails().name(new Name().fullName(originalOrder.getAddress().getName()))\n .addressPortable(new AddressPortable()\n .addressLine1(originalOrder.getAddress().getAddressLine1())\n .addressLine2(originalOrder.getAddress().getAddressLine2())\n .adminArea2(originalOrder.getAddress().getAdminArea2())\n .adminArea1(originalOrder.getAddress().getAdminArea1())\n .postalCode(originalOrder.getAddress().getPostalCode())\n .countryCode(originalOrder.getAddress().getCountryCode())));\n System.out.println(\"purchaseUnitRequest: \\n\" +\n \"\\ndescription \"+ purchaseUnitRequest.description() +\n \"\\nreferenceId \"+ purchaseUnitRequest.referenceId() +\n \"\\nsoftDescriptor \"+ purchaseUnitRequest.softDescriptor() +\n \"\\namount currencyCode \"+ purchaseUnitRequest.amount().currencyCode() +\n \"\\namount value\"+ purchaseUnitRequest.amount().value() +\n \"\\namount taxTotal \"+ purchaseUnitRequest.amount().breakdown().taxTotal().value() +\n \"\\namount handling \"+ purchaseUnitRequest.amount().breakdown().handling().value() +\n \"\\namount shipping \"+ purchaseUnitRequest.amount().breakdown().shipping().value() +\n \"\\namount shippingDiscount \"+ purchaseUnitRequest.amount().breakdown().shippingDiscount().value() +\n \"\\namount itemTotal \"+ purchaseUnitRequest.amount().breakdown().itemTotal().value()\n );\n purchaseUnitRequests.add(purchaseUnitRequest);\n orderRequest.purchaseUnits(purchaseUnitRequests);\n System.out.println(\"Request: \" + orderRequest.toString());\n return orderRequest;\n }",
"private org.apache.axiom.soap.SOAPEnvelope toEnvelope(org.apache.axiom.soap.SOAPFactory factory, com.drore.cloud.tdp.service.IWsPmsSdkServiceStub.DoControl param, boolean optimizeContent)\n throws org.apache.axis2.AxisFault{\n\n \n try{\n\n org.apache.axiom.soap.SOAPEnvelope emptyEnvelope = factory.getDefaultEnvelope();\n emptyEnvelope.getBody().addChild(param.getOMElement(com.drore.cloud.tdp.service.IWsPmsSdkServiceStub.DoControl.MY_QNAME,factory));\n return emptyEnvelope;\n } catch(org.apache.axis2.databinding.ADBException e){\n throw org.apache.axis2.AxisFault.makeFault(e);\n }\n \n\n }",
"private org.apache.axiom.soap.SOAPEnvelope toEnvelope(org.apache.axiom.soap.SOAPFactory factory, com.drore.cloud.tdp.service.IWsPmsSdkServiceStub.GetDictionaryPage param, boolean optimizeContent)\n throws org.apache.axis2.AxisFault{\n\n \n try{\n\n org.apache.axiom.soap.SOAPEnvelope emptyEnvelope = factory.getDefaultEnvelope();\n emptyEnvelope.getBody().addChild(param.getOMElement(com.drore.cloud.tdp.service.IWsPmsSdkServiceStub.GetDictionaryPage.MY_QNAME,factory));\n return emptyEnvelope;\n } catch(org.apache.axis2.databinding.ADBException e){\n throw org.apache.axis2.AxisFault.makeFault(e);\n }\n \n\n }",
"private org.apache.axiom.soap.SOAPEnvelope toEnvelope(org.apache.axiom.soap.SOAPFactory factory, org.pahospital.www.radiologyservice.RadiologyServiceStub.RadiologyOrderIDForPayment param, boolean optimizeContent, javax.xml.namespace.QName methodQName)\n throws org.apache.axis2.AxisFault{\n\n \n try{\n\n org.apache.axiom.soap.SOAPEnvelope emptyEnvelope = factory.getDefaultEnvelope();\n emptyEnvelope.getBody().addChild(param.getOMElement(org.pahospital.www.radiologyservice.RadiologyServiceStub.RadiologyOrderIDForPayment.MY_QNAME,factory));\n return emptyEnvelope;\n } catch(org.apache.axis2.databinding.ADBException e){\n throw org.apache.axis2.AxisFault.makeFault(e);\n }\n \n\n }",
"public PreparedCrashReport build();",
"private ProduceDOCXResult(Model model,PackageData data, String input, String output, String dotx, String config) {\n super(model, data);\n this._input = input;\n this._output = output;\n this._dotx = dotx;\n this._config = config;\n }",
"public SimpleAttachment build() {\n \t\treturn new SimpleAttachment(this);\n \t}",
"public IMobileAppValidateXmlRequest buildRequest(final java.util.List<? extends com.microsoft.graph.options.Option> requestOptions) {\n MobileAppValidateXmlRequest request = new MobileAppValidateXmlRequest(\n getRequestUrl(),\n getClient(),\n requestOptions\n );\n\n if (hasParameter(\"officeConfigurationXml\")) {\n request.body.officeConfigurationXml = getParameter(\"officeConfigurationXml\");\n }\n\n return request;\n }"
] | [
"0.51596296",
"0.50585175",
"0.50543624",
"0.4964715",
"0.49389163",
"0.48976845",
"0.48650113",
"0.4805427",
"0.47903466",
"0.47122487",
"0.4687713",
"0.46674168",
"0.46662143",
"0.46521974",
"0.46217266",
"0.46036378",
"0.45829514",
"0.45709974",
"0.45641148",
"0.45605895",
"0.45604905",
"0.45551097",
"0.455496",
"0.45459983",
"0.45281526",
"0.45247647",
"0.44879824",
"0.4483401",
"0.44514143",
"0.44365227",
"0.44327667",
"0.44231233",
"0.44220462",
"0.4418608",
"0.44104582",
"0.43827823",
"0.4381662",
"0.43757722",
"0.43745854",
"0.4352164",
"0.43480697",
"0.43309075",
"0.43249598",
"0.43248174",
"0.4304524",
"0.43038368",
"0.42768112",
"0.42691898",
"0.42667058",
"0.4252673",
"0.42466125",
"0.4242763",
"0.42395446",
"0.42372698",
"0.42359895",
"0.42326814",
"0.42325848",
"0.42322567",
"0.42316842",
"0.4231604",
"0.4229628",
"0.42238516",
"0.42234534",
"0.42126885",
"0.42107648",
"0.4207545",
"0.42031166",
"0.42025733",
"0.42010042",
"0.41988197",
"0.41925466",
"0.4192526",
"0.41902244",
"0.41840634",
"0.4179849",
"0.41796184",
"0.41775525",
"0.41741034",
"0.41729504",
"0.41680646",
"0.41636476",
"0.41634998",
"0.41604355",
"0.41538835",
"0.41532025",
"0.4151189",
"0.41496328",
"0.41471604",
"0.4142638",
"0.41379836",
"0.41369143",
"0.41346824",
"0.4131928",
"0.41265282",
"0.41243762",
"0.41239658",
"0.4119621",
"0.4119346",
"0.41189596",
"0.41163713"
] | 0.81319577 | 0 |
Current use ehcache which has disk persistence feature, no more work to do here | @Override
public void persist() {
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public interface EzyerCache {\n class PersistentObject {\n public final byte[] mData;\n public final String mKey;\n public final long mExpireTimeMillis;\n\n public PersistentObject(byte[] data, String key, long expireTimeMillis) {\n mData = data;\n mKey = key;\n mExpireTimeMillis = expireTimeMillis;\n }\n }\n\n class ValueObject {\n public final byte[] mData;\n public final String mKey;\n public final boolean mIsExpired;\n\n public ValueObject(byte[] data, String key, boolean isExpired) {\n mData = data;\n mKey = key;\n mIsExpired = isExpired;\n }\n }\n\n ValueObject get(String key);\n\n List<ValueObject> get(String key, int start, int end);\n\n void set(PersistentObject po);\n\n void add(PersistentObject po);\n\n void remove(String key);\n\n boolean isExpired(String key);\n\n void clear();\n}",
"interface Cache {\n\n /** @return A cache entry for given path string or <code>null</code> (if file cannot be read or too large to cache).\n * This method increments CacheEntry reference counter, caller must call {@link #checkIn(CacheEntry)} to release returned entry (when not null). */\n CacheEntry checkOut(CacheEntryLoader cacheEntryLoader);\n\n /**\n * Method to release cache entry previously obtained from {@link #checkOut(CacheEntryLoader)} call.\n * This method decrements CacheEntry reference counter.\n */\n void checkIn(CacheEntry key);\n\n /** Invalidates cached entry for given path string (if it is cached) */\n void invalidate(String pathString);\n\n void rename(String fromPathString, String toPathString);\n\n// /** Preload given file path in cache (if cache has vacant spot). Preloading happens in background. Preloaded pages initially have zero reference counter. */\n// void preload (String pathString);\n\n /** Clears the cache of all entries (even if some entries are checked out) */\n void clear();\n\n /** Allocates entry of given size for writing.\n * It will not be visible to others until caller calls {@link #update(String, CacheEntry)}.*/\n CacheEntry alloc(long size);\n\n /** Registers recently writtien cache entry as available for reading */\n void update(String pathString, CacheEntry cacheEntry);\n}",
"private void testAllFile(String ehCacheFile) throws Exception {\n ClassLoader existingCl = currentThread().getContextClassLoader();\n DefaultCacheManager dcm = null;\n Cache<Object, Object> sampleDistributedCache2 = null;\n try {\n ClassLoader delegatingCl = new Jbc2InfinispanTransformerTest.TestClassLoader(existingCl);\n currentThread().setContextClassLoader(delegatingCl);\n String fileName = getFileName(ehCacheFile);\n ByteArrayOutputStream baos = new ByteArrayOutputStream();\n convertor.parse(fileName, baos, ConfigFilesConvertor.TRANSFORMATIONS.get(ConfigFilesConvertor.EHCACHE_CACHE1X), Thread.currentThread().getContextClassLoader());\n\n dcm = (DefaultCacheManager) TestCacheManagerFactory.fromStream(new ByteArrayInputStream(baos.toByteArray()));\n Cache<Object,Object> defaultCache = dcm.getCache();\n defaultCache.put(\"key\", \"value\");\n Configuration configuration = defaultCache.getCacheConfiguration();\n\n assertEquals(configuration.eviction().maxEntries(),10000);\n assertEquals(configuration.expiration().maxIdle(), 121);\n assertEquals(configuration.expiration().lifespan(), 122);\n LoadersConfiguration loaders = configuration.loaders();\n assert loaders.cacheLoaders().get(0) instanceof FileCacheStoreConfiguration;\n\n assertEquals(configuration.expiration().wakeUpInterval(), 119000);\n assertEquals(configuration.eviction().strategy(), EvictionStrategy.LRU);\n\n String definedCacheNames = dcm.getDefinedCacheNames();\n assert definedCacheNames.contains(\"sampleCache1\");\n assert definedCacheNames.contains(\"sampleCache2\");\n assert definedCacheNames.contains(\"sampleCache3\");\n assert definedCacheNames.contains(\"sampleDistributedCache1\");\n assert definedCacheNames.contains(\"sampleDistributedCache2\");\n assert definedCacheNames.contains(\"sampleDistributedCache3\");\n\n sampleDistributedCache2 = dcm.getCache(\"sampleDistributedCache2\");\n Configuration configuration2 = sampleDistributedCache2.getCacheConfiguration();\n assert configuration2.loaders().cacheLoaders().size() == 1;\n assert configuration2.expiration().lifespan() == 101;\n assert configuration2.expiration().maxIdle() == 102;\n assertEquals(configuration2.clustering().cacheMode(), CacheMode.INVALIDATION_SYNC);\n\n } finally {\n currentThread().setContextClassLoader(existingCl);\n TestingUtil.killCaches(sampleDistributedCache2);\n TestingUtil.killCacheManagers(dcm);\n }\n }",
"public interface CacheManager extends AutoCloseable {\n /**\n * @param conf the Alluxio configuration\n * @return an instance of {@link CacheManager}\n */\n static CacheManager create(AlluxioConfiguration conf) throws IOException {\n // TODO(feng): make cache manager type configurable when we introduce more implementations.\n return new NoExceptionCacheManager(LocalCacheManager.create(conf));\n }\n\n /**\n * Puts a page into the cache manager. This method is best effort. It is possible that this put\n * operation returns without page written.\n *\n * @param pageId page identifier\n * @param page page data\n * @return true if the put was successful, false otherwise\n */\n boolean put(PageId pageId, byte[] page);\n\n /**\n * Wraps the page in a channel or null if the queried page is not found in the cache or otherwise\n * unable to be read from the cache.\n *\n * @param pageId page identifier\n * @return a channel to read the page\n */\n @Nullable\n ReadableByteChannel get(PageId pageId);\n\n /**\n * Wraps a part of the page in a channel or null if the queried page is not found in the cache or\n * otherwise unable to be read from the cache.\n *\n * @param pageId page identifier\n * @param pageOffset offset into the page\n * @return a channel to read the page\n */\n @Nullable\n ReadableByteChannel get(PageId pageId, int pageOffset);\n\n /**\n * Deletes a page from the cache.\n *\n * @param pageId page identifier\n * @return true if the page is successfully deleted, false otherwise\n */\n boolean delete(PageId pageId);\n}",
"public interface ICache {\n\t\n\t/**\n\t * <p>\n\t * get the Cached Object from cache pool by the cache String key\n\t * @param key\n\t * @return\n\t */\n\tpublic Object get(String key);\n\t\n\t\n\t\n\t/**\n\t * <p>\n\t * \n\t * @param key\n\t * @return old cache object \n\t */\n\tpublic Object put(String key,Object value);\n\t\n\t/**\n\t * <p>\n\t * get the Cached Object from cache pool by the cache String key quietly,\n\t * without update the statistic data\n\t * @param key\n\t * @return\n\t */\n\tpublic Object getQuiet(String key);\n\t\n\t\n\t/**\n\t * <p>\n\t * remove the cached object from cache pool by the cache String key\n\t * @param key\n\t * @return\n\t */\n\tpublic Object remove(String key);\n\t\n\t/**\n\t * <p>\n\t * free specied size mem\n\t * @param size unit in Byte\n\t * @return\n\t */\n\tpublic long free(long size);\n\t\n\t\n\t/**\n\t * <p>\n\t * flush to the underly resource\n\t */\n\tpublic void flush();\n\t\n}",
"protected Entity cacheLoadOrStore(Entity entity) {\n Entity cachedEntity = entityCache.findInCache(entity.getClass(), entity.getId());\n if (cachedEntity != null) {\n return cachedEntity;\n }\n entityCache.put(entity, true);\n return entity;\n }",
"private static void putInPersistentCache(final Asset asset) {\n \n \t\tif (!usePersistentCache) {\n \t\t\treturn;\n \t\t}\n \n \t\tif (!assetIsInPersistentCache(asset)) {\n \n \t\t\tfinal File assetFile = getAssetCacheFile(asset);\n \n \t\t\tnew Thread() {\n \t\t\t\t@Override\n \t\t\t\tpublic void run() {\n \n \t\t\t\t\ttry {\n \t\t\t\t\t\tassetFile.getParentFile().mkdirs();\n \t\t\t\t\t\t// Image\n \t\t\t\t\t\tOutputStream out = new FileOutputStream(assetFile);\n \t\t\t\t\t\tout.write(asset.getImage());\n \t\t\t\t\t\tout.close();\n \n \t\t\t\t\t} catch (IOException ioe) {\n \t\t\t\t\t\tlog.error(\"Could not persist asset while writing image data\", ioe);\n \t\t\t\t\t\treturn;\n \t\t\t\t\t}\n \t\t\t\t}\n \t\t\t}.start();\n \n \t\t}\n \t\tif (!assetInfoIsInPersistentCache(asset)) {\n \n \t\t\tFile infoFile = getAssetInfoFile(asset);\n \n \t\t\ttry {\n \t\t\t\t// Info\n \t\t\t\tOutputStream out = new FileOutputStream(infoFile);\n \t\t\t\tProperties props = new Properties();\n \t\t\t\tprops.put(NAME, asset.getName() != null ? asset.getName() : \"\");\n \t\t\t\tprops.store(out, \"Asset Info\");\n \t\t\t\tout.close();\n \n \t\t\t} catch (IOException ioe) {\n \t\t\t\tlog.error(\"Could not persist asset while writing image properties\", ioe);\n \t\t\t\treturn;\n \t\t\t}\n \n \t\t}\n \t}",
"public void createOrReadCache() {\n\t\tList<String> cachedDirectoryPaths = new ArrayList<>();\n\t\tFile file = new File(LevelEditor.SAVED_PATH_DATA);\n\t\tif (!file.exists()) {\n\t\t\t// Set the default paths first\n\t\t\tFileControl.lastSavedDirectory = new File(LevelEditor.defaultPath);\n\t\t\tScriptEditor.lastSavedDirectory = FileControl.lastSavedDirectory;\n\n\t\t\tcachedDirectoryPaths.add(FileControl.lastSavedDirectory.getAbsolutePath());\n\n\t\t\ttry (RandomAccessFile raf = new RandomAccessFile(file, \"rw\")) {\n\t\t\t\tthis.storeCachedDirectories(raf, cachedDirectoryPaths);\n\t\t\t}\n\t\t\tcatch (IOException e) {\n\t\t\t\tDebug.exception(e);\n\t\t\t}\n\t\t}\n\t\telse {\n\t\t\ttry (RandomAccessFile raf = new RandomAccessFile(file, \"r\")) {\n\t\t\t\tthis.fetchCachedDirectories(raf, cachedDirectoryPaths);\n\t\t\t}\n\t\t\tcatch (IOException e) {\n\t\t\t\tDebug.exception(e);\n\t\t\t}\n\n\t\t\tFileControl.lastSavedDirectory = new File(cachedDirectoryPaths.get(LevelEditor.FileControlIndex));\n\t\t\tScriptEditor.lastSavedDirectory = FileControl.lastSavedDirectory;\n\t\t}\n\t}",
"public static <T extends Entity> EntityCache<T> getDiskEntityCache(DB db, String name) {\n\t\tEntityMap<T> entityMap = new DiskEntityMap<T>(db, name);\n\t\treturn new EntityCache<T>(entityMap);\n\t}",
"@Override\n public boolean isCaching() {\n return false;\n }",
"public interface MongoDBCache<K, V> {\n /**\n * Size of the cache\n *\n * @return size\n */\n int size();\n\n /**\n * Purge all data from cache\n */\n void clear();\n\n /**\n * Remove the entry which has the same key of the parameter\n *\n * @param key\n * @return the removed cache entry\n */\n boolean remove(byte[] key);\n\n /**\n * Get a cache entry which has the same key of the parameter\n *\n * @param key\n * @return\n */\n MongoDBEntry<K, V> get(byte[] key);\n\n /**\n * Verify if the cache contains the key passed on parameter\n *\n * @param key\n * @return true if there is some entry, false if there is not\n */\n boolean containsKey(byte[] key);\n\n /**\n * Since mongo doesn't support actual paging results,\n * we have to sort and do a less than on the last id.\n *\n * @param lastKey\n * @return\n */\n List<MongoDBEntry<K, V>> getPagedEntries(byte[] lastKey);\n\n /**\n * This method must remove all data which are expired. <br/>\n * What means delete all entries that have the expiryTime parameter less than the current date.\n */\n List<MongoDBEntry<K, V>> removeExpiredData(byte[] lastKey);\n\n /**\n * Put an entry to the cache\n *\n * @param entry\n */\n void put(MongoDBEntry<K, V> entry);\n\n void start() throws Exception;\n\n /***\n *\n */\n void stop();\n}",
"public interface TAFSCacheInterface\n{\n//\tabstract void ConnectCache() throws IOException;\n//\tabstract void DisconnectCache();\n//\tabstract byte[] GetFileFromCache(String inFileName);\n//\tabstract void PutFileInCache(String inFileName, byte[] inFileBytes);\n}",
"public ImageFileCache(Context context){\n\t\tFile cacheDir = getCacheDir(context, DISK_CACHE_SUBDIR);\n//\t\tmDiskCache = DiskLruCache.openCache(this, cacheDir, DISK_CACHE_SIZE);\n\t}",
"public DataPersistence() {\n storage = new HashMap<>();\n idCounter = 0;\n }",
"interface OfBizUserCache {\n /**\n * Retrieve a User by userName case insensitively.\n *\n * @param directoryId The directory.\n * @param userName User name.\n * @return A user.\n */\n OfBizUser getCaseInsensitive(long directoryId, String userName);\n\n /**\n * Retrieve all Users by id given a list of ids.\n *\n * @param directoryId The directory.\n * @param userIds List of user Ids\n * @return A list of {@link OfBizUser}.\n */\n List<OfBizUser> getAllCaseInsensitive(long directoryId, Collection<String> userIds);\n\n /**\n * Remove a user from the cache.\n *\n * @param directoryId The directory.\n * @param userName User name.\n */\n void remove(long directoryId, String userName);\n\n /**\n * Remove a user from the cache.\n *\n * @param key The Users key\n */\n void remove(DirectoryEntityKey key);\n\n /**\n * Visit all the users in the directory.\n * Some implementations may process this directly from the underlying persistent store rather than the\n * cache if they do not keep a canonical set of all users in the cache.\n *\n * @param directoryId The directory\n * @param visitor A Visitor\n */\n void visitAllUserIdsInDirectory(long directoryId, Visitor<String> visitor);\n\n /**\n * Refresh the cache entry for the supplied user.\n * Should be called when a user is added or updated. The implementation may do this\n * either by storing he supplied value or refreshing the data from the underlying persistent store.\n *\n * @param user User to be refreshed in the cache\n * @return The key of the user.\n */\n DirectoryEntityKey refresh(OfBizUser user);\n\n /**\n * Refresh all entries in the cache.\n */\n void refresh();\n\n /**\n * Return true if the cache is initialised and can be used.\n * JIRA relies heavily on having access to users and if the cache needs time to initialise before it\n * can be relied on to provide correct results, JIRA needs to wait.\n *\n * @return true if initialised.\n */\n boolean isCacheInitialized();\n}",
"public interface CacheManager {\n\n void init();\n\n void destroy();\n\n void del(String key);\n\n void set(String key, Object value);\n\n void set(String key, Object value, int expireTime);\n\n <T> T get(String key, Class<T> clazz);\n\n void hset(String key, String subKey, Object value);\n\n <T> T hget(String key, String subKey, Class<T> clazz);\n\n <T> Map<String, T> hget(String key, Class<T> clazz);\n\n void hrem(String key, String subKey);\n\n long hincr(String key, String subKey);\n\n void sadd(String key, Object val);\n\n boolean sisMember(String key, Object val);\n\n void srem(String key, Object val);\n\n Set<String> sget(String key);\n\n <T> Set<T> sget(String key, Class<T> clazz);\n\n void zadd(String key, Object val, double score);\n\n boolean zisMember(String key, Object val);\n\n void zrem(String key, Object val);\n\n void zrem(String key, double min, double max);\n\n void zreplace(String key, Object val, double score);\n\n double zincr(String key, Object val, double score);\n\n <T> Set<T> zget(String key, double min, double max, Class<T> clazz);\n\n Set<String> zget(String key, double min, double max);\n}",
"public void testMultiEMCachingTrue() {\n Map props = new HashMap(System.getProperties());\n props.put(\"openjpa.MetaDataFactory\", \"jpa(Types=\" + Person.class.getName() + \")\");\n props.put(\"openjpa.jdbc.QuerySQLCache\", \"true\");\n runMultiEMCaching(props);\n }",
"public interface IBaseCache<T> {\n\n void setById(String id, T o);\n\n void setById(String id, T o, int timeout);\n\n void set(String key, T o);\n\n void set(String key, T o, int timeout);\n\n T getById(String id);\n\n T get(String key);\n\n void setList(List<T> list);\n\n void setList(List<T> list, int timeout);\n\n boolean hasList();\n\n List<T> getList();\n\n void setList(String key, List<T> list);\n\n void setList(String key, List<T> list, int timeout);\n\n boolean hasList(String key);\n\n List<T> getList(String key);\n\n boolean hasKeyById(String id);\n\n boolean hasKey(String key);\n\n void deleteKeyById(String id);\n\n void deleteKey(String key);\n\n void deleteList();\n\n void deleteList(String key);\n\n void deleteAllEntityKeys();\n\n\n}",
"public interface CacheRepository {\n Object select(String key);\n void insert(String key, Object value);\n void delete(String key);\n boolean exists(String key);\n}",
"public void flushEntityCache() {\n super.flushEntityCache();\n }",
"@Override\r\n protected void processUpdate(final ICacheElement<K, V> ce)\r\n {\r\n if (!isAlive())\r\n {\r\n log.error(\"{0}: No longer alive; aborting put of key = {1}\",\r\n () -> logCacheName, ce::getKey);\r\n return;\r\n }\r\n\r\n log.debug(\"{0}: Storing element on disk, key: {1}\",\r\n () -> logCacheName, ce::getKey);\r\n\r\n // old element with same key\r\n IndexedDiskElementDescriptor old = null;\r\n\r\n try\r\n {\r\n IndexedDiskElementDescriptor ded = null;\r\n final byte[] data = getElementSerializer().serialize(ce);\r\n\r\n // make sure this only locks for one particular cache region\r\n storageLock.writeLock().lock();\r\n try\r\n {\r\n old = keyHash.get(ce.getKey());\r\n\r\n // Item with the same key already exists in file.\r\n // Try to reuse the location if possible.\r\n if (old != null && data.length <= old.len)\r\n {\r\n // Reuse the old ded. The defrag relies on ded updates by reference, not\r\n // replacement.\r\n ded = old;\r\n ded.len = data.length;\r\n }\r\n else\r\n {\r\n // we need this to compare in the recycle bin\r\n ded = new IndexedDiskElementDescriptor(dataFile.length(), data.length);\r\n\r\n if (doRecycle)\r\n {\r\n final IndexedDiskElementDescriptor rep = recycle.ceiling(ded);\r\n if (rep != null)\r\n {\r\n // remove element from recycle bin\r\n recycle.remove(rep);\r\n ded = rep;\r\n ded.len = data.length;\r\n recycleCnt++;\r\n this.adjustBytesFree(ded, false);\r\n log.debug(\"{0}: using recycled ded {1} rep.len = {2} ded.len = {3}\",\r\n logCacheName, ded.pos, rep.len, ded.len);\r\n }\r\n }\r\n\r\n // Put it in the map\r\n keyHash.put(ce.getKey(), ded);\r\n\r\n if (queueInput)\r\n {\r\n queuedPutList.add(ded);\r\n log.debug(\"{0}: added to queued put list. {1}\",\r\n () -> logCacheName, queuedPutList::size);\r\n }\r\n\r\n // add the old slot to the recycle bin\r\n if (old != null)\r\n {\r\n addToRecycleBin(old);\r\n }\r\n }\r\n\r\n dataFile.write(ded, data);\r\n }\r\n finally\r\n {\r\n storageLock.writeLock().unlock();\r\n }\r\n\r\n log.debug(\"{0}: Put to file: {1}, key: {2}, position: {3}, size: {4}\",\r\n logCacheName, fileName, ce.getKey(), ded.pos, ded.len);\r\n }\r\n catch (final IOException e)\r\n {\r\n log.error(\"{0}: Failure updating element, key: {1} old: {2}\",\r\n logCacheName, ce.getKey(), old, e);\r\n }\r\n }",
"public interface ILeveledCache<K, V> extends ICache<K, V>{\n void reCache() throws IOException, ClassNotFoundException;\n Map<K, V> add(K key, V object) throws IOException, ClassNotFoundException;\n List<K> sortedKeys();\n int maxLevel1size();\n Set<K> level1keys();\n}",
"public interface Cache<K,E> {\n\tpublic E getCacheEntry(K id);\n\t\n\tpublic boolean addCacheEntry(K id, E entry);\n\t\n\tpublic void removeCacheEntry(K id);\n\t\n\tpublic Stream<E> getAllEntries();\n}",
"public EhcacheSessionDataStorage(String name) {\n this.sessions = CacheManager.getInstance().getCache(name);\n }",
"private static boolean assetIsInPersistentCache(MD5Key id) {\n \n \t\treturn getAssetCacheFile(id).exists() && getAssetCacheFile(id).length() > 0;\n \t}",
"private ImageCache(Context context) {\n int memClass = ((ActivityManager) context.getSystemService(Context.ACTIVITY_SERVICE)).getMemoryClass();\n memClass = memClass > 32 ? 32 : memClass;\n\n final int cacheSize = 1024 * 1024 * memClass / 8;\n memoryCache = new LruCache<String, Bitmap>(cacheSize) {\n protected int sizeOf(String key, Bitmap bitmap) {\n return bitmap.getRowBytes() * bitmap.getHeight();\n }\n };\n\n File cacheDir = DiskLruCache.getDiskCacheDir(context, DISK_CACHE_SUB_DIR);\n diskCache = DiskLruCache.openCache(context, cacheDir, DISK_CACHE_SIZE);\n }",
"@Override\r\npublic boolean writeEntries(CacheObject obj) {\n\t\r\n\ttry {\r\n\t\t\r\n\t\tthis.writer.append(\"[\"+obj.toString()+\"]\\r\\n\");\r\n\t\tthis.writer.flush();\r\n\t} catch (IOException e) {\r\n\t\tSystem.out.println(\"Error Occured while writing into File :\"+ e.getMessage());\r\n\t\te.printStackTrace();\r\n\t\t\r\n\t} \r\n\t\r\n\treturn false;\r\n}",
"private boolean saveObjectToFile(String filename,Object object) {\n //engine.logMessage(\"Saving new cache data to: \"+filename);\n ObjectOutputStream outputStream = null;\n try { \n File file=new File(filename);\n File directory=file.getParentFile();\n if (directory==null) throw new IOException(\"Cache directory error\");\n synchronized(this) { // synchronize this because the mkdirs will return false if the directory has been created by another Thread in the meantime\n if (!directory.exists()) {\n if (!directory.mkdirs()) throw new IOException(\"Unable to create cache directory: \"+directory.getAbsolutePath());\n }\n }\n outputStream = new ObjectOutputStream(new BufferedOutputStream(new FileOutputStream(file)));\n outputStream.writeObject(object);\n outputStream.close(); \n } catch (Exception e) {\n engine.logMessage(\"WARNING: Unable to store data in cache: \"+e.getMessage());\n return false;\n } finally {\n try {if (outputStream!=null) outputStream.close();} catch (Exception x) {engine.logMessage(\"SYSTEM WARNING: Unable to close ObjectOutputStream in cache: \"+x.getMessage());}\n } \n return true; \n }",
"public interface Cache {\r\n\r\n public Object get( Object key);\r\n public void put( Object key, Object value);\r\n}",
"public void syncCache() {\n for (String s : this.cache.keySet()) {\n JsonDocument document = this.cache.get(s);\n document.save(new File(directory, s + \".json\"));\n }\n }",
"public void cacheableQuery() throws HibException;",
"public HashStore(HashChunkServiceInterface hcs) throws IOException {\n\t\tthis.name = \"sdfs\";\n\t\tthis.hcs = hcs;\n\t\ttry {\n\t\t\tthis.connectDB();\n\t\t} catch (Exception e) {\n\t\t\te.printStackTrace();\n\t\t}\n\t\t// this.initChunkStore();\n\t\tSDFSLogger.getLog().info(\"Cache Size = \" + Main.chunkStorePageSize);\n\t\tSDFSLogger.getLog().info(\"Total Entries \" + +bdb.getSize());\n\t\tSDFSLogger.getLog().info(\"Added \" + this.name);\n\t\tthis.closed = false;\n\t}",
"public interface SCStorage\r\n{\r\n\t/**\r\n\t * The server will register a driver before making any method calls\r\n\t *\r\n\t * @param driver the driver\r\n\t */\r\n\tpublic void setStorageServerDriver(SCStorageServerDriver driver);\r\n\r\n\t/**\r\n\t * Open the storage at the given path\r\n\t *\r\n\t * @param path path to the storage\r\n\t * @throws IOException errors\r\n\t */\r\n\tpublic void\topen(File path) throws IOException;\r\n\r\n\t/**\r\n\t * Return the object associated with the given key\r\n\t *\r\n\t * @param key the key\r\n\t * @return the object or null if not found\r\n\t * @throws IOException errors\r\n\t */\r\n\tpublic SCDataSpec get(String key) throws IOException;\r\n\r\n\t/**\r\n\t * Add an object to the storage\r\n\t *\r\n\t * @param key key\r\n\t * @param data object\r\n\t * @param groups associated groups or null\r\n\t */\r\n\tpublic void put(String key, SCDataSpec data, SCGroupSpec groups);\r\n\r\n\t/**\r\n\t * Close the storage. The storage instance will be unusable afterwards.\r\n\t *\r\n\t * @throws IOException errors\r\n\t */\r\n\tpublic void close() throws IOException;\r\n\r\n\t/**\r\n\t * Return the keys that match the given regular expression\r\n\t *\r\n\t * @param regex expression\r\n\t * @return matching keys\r\n\t */\r\n\tpublic Set<String> regexFindKeys(String regex);\r\n\r\n\t/**\r\n\t * Remove the given object\r\n\t *\r\n\t * @param key key of the object\r\n\t * @throws IOException errors\r\n\t */\r\n\tpublic void remove(String key) throws IOException;\r\n\r\n\t/**\r\n\t * sccache supports associative keys via {@link SCGroup}. This method deletes all objects\r\n\t * associated with the given group.\r\n\t *\r\n\t * @param group the group to delete\r\n\t * @return list of keys deleted.\r\n\t * @throws IOException errors\r\n\t */\r\n\tpublic List<String> removeGroup(SCGroup group) throws IOException;\r\n\r\n\t/**\r\n\t * sccache supports associative keys via {@link SCGroup}. This method lists all keys\r\n\t * associated with the given group.\r\n\t *\r\n\t * @param group the group to list\r\n\t * @return list of keys\r\n\t * @throws IOException errors\r\n\t */\r\n\tpublic List<String> listGroup(SCGroup group) throws IOException;\r\n\r\n\t/**\r\n\t * Returns storage statistics\r\n\t *\r\n\t * @param verbose if true, verbose stats are returned\r\n\t * @return list of stats\r\n\t * @throws IOException errors\r\n\t */\r\n\tpublic List<String> dumpStats(boolean verbose) throws IOException;\r\n\r\n\t/**\r\n\t * Write a tab delimited file with information about the key index\r\n\t *\r\n\t * @param f the file to write to\r\n\t * @throws IOException errors\r\n\t */\r\n\tpublic void writeKeyData(File f) throws IOException;\r\n}",
"public CacheStrategy getCacheStrategy();",
"private DiskCache getDefaultDiskCache(Context context) {\n DiskCache defaultDiskCache;\n File cacheDir = StorageUtils.getOwnCacheDirectory(context, \"keep/cache\");\n\n try {\n defaultDiskCache = new LruDiskCache(cacheDir, new HashCodeFileNameGenerator(), 50 * 1024 * 1024);\n } catch (IOException e) {\n defaultDiskCache = new UnlimitedDiskCache(cacheDir);\n }\n\n return defaultDiskCache;\n }",
"private static boolean assetIsInPersistentCache(Asset asset) {\n \t\treturn assetIsInPersistentCache(asset.getId());\n \t}",
"public interface DataModelOracleCache {\n\n /**\n * Retrieve the DataModelOracle for the specified Project path. The Path should resolve to a Project.\n * @param project The Path to the Project\n * @return DataModelOracle for the Project\n */\n DataModelOracle getDataModelOracle( Path project );\n\n /**\n * Set the DataModelOracle for the specified Project path. The Path should resolve to a Project.\n * @param project The Path to the Project\n * @param oracle The DataModelOracle for the Project\n */\n void setDataModelOracle( Path project,\n DataModelOracle oracle );\n\n /**\n * Invalidate the entire cache\n */\n void invalidateCache();\n\n /**\n * Invalidate the cache for a specific Project path. The path should resolve to a Project.\n * @param project The Path to the Project\n */\n void invalidateCache( Path project );\n}",
"@Override\r\n protected ICacheElement<K, V> processGet(final K key)\r\n {\r\n if (!isAlive())\r\n {\r\n log.error(\"{0}: No longer alive so returning null for key = {1}\",\r\n logCacheName, key);\r\n return null;\r\n }\r\n\r\n log.debug(\"{0}: Trying to get from disk: {1}\", logCacheName, key);\r\n\r\n ICacheElement<K, V> object = null;\r\n try\r\n {\r\n storageLock.readLock().lock();\r\n try\r\n {\r\n object = readElement(key);\r\n }\r\n finally\r\n {\r\n storageLock.readLock().unlock();\r\n }\r\n\r\n if (object != null)\r\n {\r\n hitCount.incrementAndGet();\r\n }\r\n }\r\n catch (final IOException ioe)\r\n {\r\n log.error(\"{0}: Failure getting from disk, key = {1}\", logCacheName, key, ioe);\r\n reset();\r\n }\r\n return object;\r\n }",
"public interface UserEntityCache {\n int getHitCount();\n int getMissCount();\n\n void put(long key, CacheElement<UserEntity> cacheElement);\n\n CacheElement<UserEntity> get(long key);\n}",
"public void resetCache() {\n logger.info(\"resetCache(): refilling clinical attribute cache\");\n\n Date dateOfCurrentCacheRefresh = new Date();\n ArrayList<ClinicalAttributeMetadata> latestClinicalAttributeMetadata = null;\n // latestOverrides is a map of study-id to list of overridden ClinicalAttributeMetadata objects\n Map<String, ArrayList<ClinicalAttributeMetadata>> latestOverrides = null;\n\n // attempt to refresh ehcache stores seperately and store success status\n boolean failedClinicalAttributeMetadataCacheRefresh = false;\n boolean failedOverridesCacheRefresh = false;\n try {\n clinicalAttributeMetadataPersistentCache.updateClinicalAttributeMetadataInPersistentCache();\n } catch (RuntimeException e) {\n logger.error(\"resetCache(): failed to pull clinical attributes from repository. Error message returned: \" + e.getMessage());\n failedClinicalAttributeMetadataCacheRefresh = true;\n }\n\n try {\n clinicalAttributeMetadataPersistentCache.updateClinicalAttributeMetadataOverridesInPersistentCache();\n } catch (RuntimeException e) {\n logger.error(\"resetCache(): failed to pull overrides from repository. Error message returned: \" + e.getMessage());\n failedOverridesCacheRefresh = true;\n }\n\n // regardless of whether ehcache was updated with new data - use that data to populate modeled object caches\n // ensures app starts up (between tomcat restarts) if TopBraid is down\n logger.info(\"Loading modeled object cache from EHCache\");\n try {\n // this will throw an exception if we cannot connect to TopBraid AND cache is corrupt\n latestClinicalAttributeMetadata = clinicalAttributeMetadataPersistentCache.getClinicalAttributeMetadataFromPersistentCache();\n latestOverrides = clinicalAttributeMetadataPersistentCache.getClinicalAttributeMetadataOverridesFromPersistentCache();\n } catch (Exception e) {\n try {\n // this will throw an exception if backup is unavailable\n logger.error(\"Unable to load modeled object cache from default EHCache... attempting to read from backup\");\n latestClinicalAttributeMetadata = clinicalAttributeMetadataPersistentCache.getClinicalAttributeMetadataFromPersistentCacheBackup();\n latestOverrides = clinicalAttributeMetadataPersistentCache.getClinicalAttributeMetadataOverridesFromPersistentCacheBackup();\n if (latestClinicalAttributeMetadata == null || latestOverrides == null) {\n throw new FailedCacheRefreshException(\"No data found in specified backup cache location...\", new Exception());\n }\n } catch (Exception e2) {\n logger.error(\"Unable to load modeled object cache from backup EHCache...\");\n throw new FailedCacheRefreshException(\"Unable to load data from all backup caches...\", new Exception());\n }\n }\n\n // backup cache at this point (maybe backup after each successful update above?)\n if (!failedClinicalAttributeMetadataCacheRefresh && !failedOverridesCacheRefresh) {\n logger.info(\"resetCache(): cache update succeeded, backing up cache...\");\n try {\n clinicalAttributeMetadataPersistentCache.backupClinicalAttributeMetadataPersistentCache(latestClinicalAttributeMetadata);\n clinicalAttributeMetadataPersistentCache.backupClinicalAttributeMetadataOverridesPersistentCache(latestOverrides);\n logger.info(\"resetCache(): succesfully backed up cache\");\n } catch (Exception e) {\n logger.error(\"resetCache(): failed to backup cache: \" + e.getMessage());\n }\n }\n\n HashMap<String, ClinicalAttributeMetadata> latestClinicalAttributeMetadataCache = new HashMap<String, ClinicalAttributeMetadata>();\n for (ClinicalAttributeMetadata clinicalAttributeMetadata : latestClinicalAttributeMetadata) {\n latestClinicalAttributeMetadataCache.put(clinicalAttributeMetadata.getColumnHeader(), clinicalAttributeMetadata);\n }\n\n // latestOverridesCache is a map of study-id to map of clinical attribute name to overridden ClinicalAttributeMetadata object\n HashMap<String, Map<String,ClinicalAttributeMetadata>> latestOverridesCache = new HashMap<String, Map<String, ClinicalAttributeMetadata>>();\n for (Map.Entry<String, ArrayList<ClinicalAttributeMetadata>> entry : latestOverrides.entrySet()) {\n HashMap<String, ClinicalAttributeMetadata> clinicalAttributesMetadataMapping = new HashMap<String, ClinicalAttributeMetadata>();\n for (ClinicalAttributeMetadata clinicalAttributeMetadata : entry.getValue()) {\n fillOverrideAttributeWithDefaultValues(clinicalAttributeMetadata, latestClinicalAttributeMetadataCache.get(clinicalAttributeMetadata.getColumnHeader()));\n clinicalAttributesMetadataMapping.put(clinicalAttributeMetadata.getColumnHeader(), clinicalAttributeMetadata);\n }\n latestOverridesCache.put(entry.getKey(), clinicalAttributesMetadataMapping);\n }\n\n clinicalAttributeCache = latestClinicalAttributeMetadataCache;\n logger.info(\"resetCache(): refilled cache with \" + latestClinicalAttributeMetadata.size() + \" clinical attributes\");\n overridesCache = latestOverridesCache;\n logger.info(\"resetCache(): refilled overrides cache with \" + latestOverrides.size() + \" overrides\");\n\n if (failedClinicalAttributeMetadataCacheRefresh || failedOverridesCacheRefresh) {\n logger.info(\"Unable to update cache with latest data from TopBraid... falling back on EHCache store.\");\n throw new FailedCacheRefreshException(\"Failed to refresh cache\", new Exception());\n } else {\n dateOfLastCacheRefresh = dateOfCurrentCacheRefresh;\n logger.info(\"resetCache(): cache last refreshed on: \" + dateOfLastCacheRefresh.toString());\n }\n }",
"public InMemoryServiceInstancePersistence() {\n this.serviceInstances = new HashMap<>(); \n }",
"public static void loadCache() {\n\t\t // it is the temporary replacement to database. We should use DB instead\n\t Circle circle = new Circle();\n\t circle.setId(\"1\");\n\t shapeMap.put(circle.getId(),circle);\n\n\t Square square = new Square();\n\t square.setId(\"2\");\n\t shapeMap.put(square.getId(),square);\n\n\t Rectangle rectangle = new Rectangle();\n\t rectangle.setId(\"3\");\n\t \n\t Circle circle2 = new Circle();\n\t circle2.setId(\"4\");\n\t circle2.setType(\"Big Circle\");\n\t shapeMap.put(circle2.getId(),circle2);\n\t shapeMap.put(rectangle.getId(), rectangle);\n\t }",
"protected void createLookupCache() {\n }",
"public interface Cache {\n void put(String key, Object value);\n\n Object get(String key);\n}",
"private static void secondLevelCacheWithoutSettingAttrInXML() {\n\t\ttry(Session session = HbUtil.getSession()){\n\t\t\tBook b = session.get(Book.class, 11);\n\t\t\tSystem.out.println(\"Book details : \\n\" + b);\n\t\t}catch(Exception ex) {\n\t\t\tex.printStackTrace();\n\t\t}\n\t\t\n\t\ttry(Session session = HbUtil.getSession()){\n\t\t\tBook b = session.get(Book.class, 11);\n\t\t\tSystem.out.println(\"Book details : \\n\" + b);\n\t\t}catch(Exception ex) {\n\t\t\tex.printStackTrace();\n\t\t}\n\t}",
"public interface OrganizationService extends EntityService<Organization> {\n\n /**\n * 缓存\n *\n * @param id\n * @return\n * @throws Exception\n */\n public Organization queryCacheOrganizationById(long id) throws Exception;\n}",
"public boolean useCache() {\n return !pathRepositoryCache.isEmpty();\n }",
"private static boolean assetInfoIsInPersistentCache(Asset asset) {\n \t\treturn getAssetInfoFile(asset.getId()).exists();\n \t}",
"protected net.sf.ehcache.Ehcache getCache() {\n return cache;\n }",
"private static File createReserveDiskCacheDir(Context context) {\n\t\tFile cacheDir = StorageUtils.getCacheDirectory(context, false);\n\t\tFile individualDir = new File(cacheDir, \"lazy-cache\");\n\t\tif (individualDir.exists() || individualDir.mkdir()) {\n\t\t\tcacheDir = individualDir;\n\t\t}\n\t\treturn cacheDir;\n\t}",
"@Test\n public void testCompact_Last_Segment_Caching_Enabled() throws Exception {\n\n File file = new File(System.getProperty(\"java.io.tmpdir\") + File.separator\n + \"oasis-collection-testCompact_Last_Segment_Caching_Enabled\");\n file.mkdirs();\n file.deleteOnExit();\n\n SegmentedOasisList<Integer> instance = new SegmentedOasisList<>(2, 2, file);\n Collection c = Arrays.asList(1, 1, 7, 7, 1, 1, 1, 1);\n instance.enableCache();\n instance.addAll(c);\n\n instance.remove(7);\n instance.disableCache();\n\n assertNumberFilesInDirectory(instance.instanceStore(), 2);\n\n }",
"@Override\n\tpublic boolean isCaching() {\n\t\treturn false;\n\t}",
"public void cacheBusRouteData()\n\t{\t\n\t\tdataMap = BusRouteDataFileReader.readAndCacheBusRouteData(this.pathname);\n\t}",
"public void saveState() {\n\t\tFileOutputStream fos = null;\n\t\tObjectOutputStream out = null;\n\t\ttry {\n\t\t\tFile savefile = new File(getServletContext().getRealPath(\"/WEB-INF/\"), SAVED_RECEPTOR_FILE_NAME);\n\t\t\tfos = new FileOutputStream(savefile);\n\t\t\tout = new ObjectOutputStream(fos);\n\t\t\tout.writeObject(pgtMap);\n\t\t\tout.close();\n\t\t} catch (IOException ex) {\n\t\t\tSystem.err.println(\"IO Exception saving proxyTicket cache\");\n\t\t\tex.printStackTrace();\n\t\t} catch (Exception e) { //don't think this is possible, but I'm seeing some goofy behavior, so...\n\t\t\tSystem.err.println(\"Non-IO Exception saving proxyTicket cache\");\n\t\t\te.printStackTrace();\n\t\t}\n\t}",
"public void cache(){\n\t\t\n\t\t/*\n\t\t * second, check if there is a cache file\n\t\t * if yes, then check date\n\t\t * if no, then create a cache file \n\t\t*/\n\t\tif(cacheExist()){\n\t\t\t//check date and decide which file to update\n\t\t\tSystem.out.println(\" hahahaha, cache already there! \");\n\t\t\t\n\t\t\tFile cache = new File(\"./cache.txt\");\n\t\t\tsource = readFile(\"./cache.txt\",source);\n\t\t\tSystem.out.println(\"the size of source hashmap : \"+ source.size());\n\t\t\t\n\t\t\tfor(int i = 1; i < fileList.length;i++){\n\t\t\t\t//if this file need to be updated, write the data to source array\n\t\t\t\tif(needToUpdate(fileList[i], cache)){\n\t\t\t\t\tSimpleDateFormat sdf = new SimpleDateFormat(\"MM/dd/yyyy HH:mm:ss\");\n\t\t\t\t\tSystem.out.println(\"S: \"+ sdf.format(fileList[i].lastModified()) + \" c: \"+ sdf.format(cache.lastModified()));\n\t\t\t\t\tsource = readFile(fileList[i].getPath(), source);\n\t\t\t\t}\n\t\t\t}\n\t\t\t//after checking the whole source file and add the new data to source array\n\t\t\t//then sort the source array and write it to cache\n\t\t\tsort(source);\n\t\t\ttry\n\t\t\t{\n\t\t\t String filename= \"./cache.txt\";\n\t\t\t FileWriter fw = new FileWriter(filename,true); //the true will append the new data\n\t\t\t for(int j = 0; j < writeList.size(); j++){\n\t\t\t\t\tfw.write(writeList.get(j));\n\t\t\t\t}\n\t\t\t fw.close();\n\t\t\t}\n\t\t\tcatch(IOException ioe)\n\t\t\t{\n\t\t\t System.err.println(\"IOException: \" + ioe.getMessage());\n\t\t\t}\n\t\t\t\t\n\t\t}\n\t\t//there are is no cache, need to create a cache file\n\t\telse{\n\t\t\tSystem.out.println(\" create new cache file !\");\n\t\t\t//create cache file and copy sort the data from source file\n\t\t\t//1. read all the source file and store the data to an arrayList\n\t\t\tfor(int i = 1; i < fileList.length; i++){\n\t\t\t\tsource = readFile(fileList[i].getPath(), source);\t\t\t\n\t\t\t}\n\t\t\tsort(source);\n//\t\t\tSystem.out.println(source);\n\t\t\t\n\t\t\t//2.write the data to the cache file\n\t\t\tPrintWriter writer;\n\t\t\ttry {\n\t\t\t\twriter = new PrintWriter(\"cache.txt\", \"UTF-8\");\t\t\t\n\t\t\t\twriter.println(writeList.size());\n\t\t\t\tfor(int j = 0; j < writeList.size(); j++){\n\t\t\t\t\twriter.println(writeList.get(j));\n\t\t\t\t}\n\t\t\t\twriter.close();\n\t\t\t\t\n\t\t\t} catch (FileNotFoundException e) {\n\t\t\t\t// TODO Auto-generated catch block\n\t\t\t\te.printStackTrace();\n\t\t\t} catch (UnsupportedEncodingException e) {\n\t\t\t\t// TODO Auto-generated catch block\n\t\t\t\te.printStackTrace();\n\t\t\t}\n\t\t\t\n\t\t}\n\t\t \n\t\t\n\t}",
"private void putInCacheDirty(Module module) throws NoStorageForModuleException, StorageFailureException{\n\t\tputInCache(module);\n\t\tIModuleStorage storage = storages.get(module.getId());\n\t\tif (storage==null){\n\t\t\tLOGGER.warn(\"No storage for \" + module.getId() + \", \" + module + \" is not persistent!\");\n\t\t\tthrow new NoStorageForModuleException(module.getId());\n\t\t}\n\t\tstorage.saveModule(module);\n\t}",
"public abstract int getPersistence();",
"OStorage getStorage();",
"public void refreshObjectCache();",
"int saveCached(String fileName) throws IOException\n\t {\n\t\t File f = new File (fileName);\n\t\t \n\t\t\t\tif (f.exists())\n\t\t\t\t{\n\t\t\t\t\tSystem.out.println(\"ATTENTION!!! File \" +fileName+ \" already exists. Adding new records to it.\");\n\t\t\t\t\tFileWriter fw = new FileWriter (f, true);\n\t\t\t\t\tPrintWriter pwx = new PrintWriter (fw);\n\t\t\t\t\tBufferedReader brx = new BufferedReader(new FileReader (\".cache\"));\n\t\t\t\t\t \n\t\t\t\t\t String lineX = brx.readLine();\n\t\t\t\t\t \n\t\t\t\t\t while (lineX != null)\n\t\t\t\t\t {\n\t\t\t\t\t\t pwx.println(lineX);\n\t\t\t\t\t\t lineX=brx.readLine();\n\t\t\t\t\t }\n\t\t\t\t\t brx.close();\n\t\t\t\t\t pwx.flush();\n\t\t\t\t\t pwx.close();\n\t\t\t\t\t \n\t\t\t\t\t return 0;\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\tf.createNewFile();\n\t\t\t\t}\n\t\t \n\t\t \n\t\t PrintWriter pn = new PrintWriter (fileName);\n\t\t BufferedReader br = new BufferedReader(new FileReader (\".cache\"));\n\t\t \n\t\t String line = br.readLine();\n\t\t \n\t\t while (line != null)\n\t\t {\n\t\t\t pn.println(line);\n\t\t\t line=br.readLine();\n\t\t }\n\t\t pn.flush();\n\t\t br.close();\n\t\t pn.close();\n\t\t System.out.println(\"Your file was saved as follows\");\n\t\t FileManager fm = new FileManager();\n\t\t fm.show(fileName);\n\t\treturn 1;\n\t }",
"public void storeInCache() {\r\n lockValueStored = IN_CACHE;\r\n }",
"public interface DistributeStorage<T> {\n public void store(String path, T t, boolean create) throws StorageException;\n\n public T get(String path, Class<T> tClass) throws StorageException;\n\n public void del(String path) throws StorageException;\n\n public boolean exist(String path) throws StorageException;\n}",
"private void cacheFoldersFiles() throws Exception {\n\n ArrayList<FileManagerFile> files = new ArrayList<FileManagerFile>();\n if (fileCount > 0) {\n SimpleDateFormat formatter = new SimpleDateFormat(\"yyyy-MM-dd'T'HH:mm:ss\");\n formatter.setTimeZone(TimeZone.getTimeZone(\"GMT\"));\n\n int offset = 0;\n int count = 1000;\n List<FileManagerFile> filelist;\n\n do {\n filelist = connection.getFileManager().getFileManagerFiles(count, offset);\n offset += count;\n for (FileManagerFile file : filelist) {\n if (file.getFolderId() == id) {\n files.add(file);\n }\n }\n } while (filelist.size() > 0 && files.size() < fileCount);\n }\n this.files = files;\n }",
"@Override\n public CacheAPI getCacheAPI() {\n return null;\n }",
"public interface ContentCache extends DataCache {\r\n String getValue(String code, Locale locale);\r\n\r\n Boolean containsLocale(Locale locale);\r\n\r\n Boolean containsCodeForLocale(String code, Locale locale);\r\n\r\n Map<String, Map<String, String>> getCachedData();\r\n}",
"protected abstract Collection<Cache> loadCaches();",
"public interface ContentCache extends Cache<List<byte[]>>{\n int notCacheSize();\n}",
"public Object createEntry(Object key) throws Exception {\n\r\n\t\t\r\n\t\t\r\n\t\tConnection connect = null;\r\n\t Statement st = null;\r\n\t ResultSet rs = null;\r\n\t String url = \"jdbc:mysql://localhost:3306/\";\r\n\t String db = \"ehcache\";\r\n\t String driver = \"com.mysql.jdbc.Driver\";\r\n\t String user = \"ehcache\";\r\n\t String pass = \"terracotta\";\r\n\t customer mc = new customer();\r\n\t \r\n\t\ttry {\r\n\t\t\t\r\n\t\t\tClass.forName(driver);\r\n\t\t\tconnect = DriverManager\r\n\t\t\t .getConnection(url + db, user, pass);\r\n\t\t\t\r\n\t\t\tst = connect.createStatement();\r\n\t\t rs = st.executeQuery(\"select * from customers where ID='\" + key + \"'\");\r\n\t\t // rs = st.executeQuery(\"select * from customers where ID='1'\");\r\n\t\t \r\n\t\t System.out.println(\"(dbReadThrough) Retrieving customer \" + key + \" from DB ... \");\r\n\t\t \r\n\t\t while (rs.next()) {\r\n\t\t \t\r\n\t\t \t\r\n\t\t \tint ID = rs.getInt(\"ID\");\r\n\t\t \tString FIRSTNAME = rs.getString(\"FIRSTNAME\");\r\n\t\t \tString LASTNAME = rs.getString(\"LASTNAME\");\r\n\t\t \tString REGION = rs.getString(\"REGION\");\r\n\t\t \tString ADDRESS = rs.getString(\"ADDRESS\");\r\n\t\t \r\n\t\t \tSystem.out.println(\"(dbReadThrough) Found customer: \" + ID + \" -- \" + FIRSTNAME + \" \" + LASTNAME + \" \" + REGION + \" \" + ADDRESS);\r\n\t\t \t\t\t \t\r\n\t \t\tmc.setID(ID);\r\n\t \t\tmc.setFIRSTNAME(FIRSTNAME);\r\n\t \t\tmc.setLASTNAME(LASTNAME);\r\n\t \t\tmc.setREGION(REGION);\r\n\t \t\tmc.setADDRESS(ADDRESS); \t\r\n\t\t \t\t\t \t\r\n\t\t }\r\n\t\t \r\n\t\t System.out.println(\"(dbReadThrough) Writing object for customer \" + key + \" to the cache ... \");\r\n\t return mc;\r\n\t\t\r\n\t\t} finally {\r\n\t\t\tconnect.close();\r\n\t\t}\r\n\r\n\t}",
"private static void loadCache(IgniteCache<Long, Person> cache) {\n long start = System.currentTimeMillis();\n\n // Start loading cache from persistent store on all caching nodes.\n cache.loadCache(null, ENTRY_COUNT);\n\n long end = System.currentTimeMillis();\n\n System.out.println(\">>> Loaded \" + cache.size() + \" keys with backups in \" + (end - start) + \"ms.\");\n }",
"public EhcacheSessionDataStorage() {\n this(SESSION_NAME);\n }",
"protected void trunkStore() {\n LOG.info(\"Trunking state filestore: {}\", fileStore);\n FileOutputStream fos = null;\n try {\n fos = new FileOutputStream(fileStore);\n for (Map.Entry<String, String> entry : cache.entrySet()) {\n fos.write(entry.getKey().getBytes());\n fos.write(KEY_VALUE_DELIMITER.getBytes());\n fos.write(entry.getValue().getBytes());\n fos.write(STORE_DELIMITER.getBytes());\n }\n } catch (IOException e) {\n throw RuntimeCamelException.wrapRuntimeCamelException(e);\n } finally {\n IOHelper.close(fos, \"Trunking file state repository\", LOG);\n }\n }",
"private static void secondLevelCacheWithSettingAttrInXML() {\n\t\ttry(Session session = HbUtil.getSession()){\n\t\t\tBook b = session.get(Book.class, 11);\n\t\t\tSystem.out.println(\"Book details : \\n\" + b);\n\t\t}catch(Exception ex) {\n\t\t\tex.printStackTrace();\n\t\t}\n\t\t\n\t\ttry(Session session = HbUtil.getSession()){\n\t\t\tBook b = session.get(Book.class, 11);\n\t\t\tSystem.out.println(\"Book details : \\n\" + b);\n\t\t}catch(Exception ex) {\n\t\t\tex.printStackTrace();\n\t\t}\n\t}",
"private static void firstLevelCacheWithGetAndLoad(Session session) {\n\t\tsession.beginTransaction();\n\t\tBook b = session.get(Book.class, 11);\n\t\tSystem.out.println(\"Book details : \\n\" + b);\n\t\tSystem.out.println(\"ID : \" + b.getId());\n\t\tSystem.out.println(\"NAME : \" + b.getName());\n\t\tSystem.out.println(b.getClass().getName());\n\n\t\tBook b1 = session.load(Book.class, 12);\n\t\tSystem.out.println(\"Book details : \\n\" + b1);\n\t\tSystem.out.println(\"ID : \" + b1.getId());\n\t\tSystem.out.println(\"NAME : \" + b1.getName());\n\t\tSystem.out.println(b1.getClass().getName());\n\t}",
"public DBMaker enableHardCache() {\n cacheType = DBCacheRef.HARD;\n return this;\n }",
"@Override\n\tpublic int getSizeToCache() {\n\t\treturn 0;\n\t}",
"void cache(String key, T value) throws IOException;",
"protected void createLookupCache()\n/* */ {\n/* 1260 */ this.lookup = new SimpleCache(1, Math.max(getSize() * 2, 64));\n/* */ }",
"public interface Cache<K,V> {\n\t/**\n\t * Returns the object for the given id from cache, null if no object is in cache.\n\t *\n\t * @param id the id to retrieve\n\t * @return a V object.\n\t */\n\tV get(K id);\n\t\n\t/**\n\t * Puts the cacheable object in cache.\n\t *\n\t * @param id the object id\n\t * @param cacheable the object to cache.\n\t */\n\tvoid put(K id, V cacheable);\n\n\t/**\n\t * Removes an object from the cache.\n\t *\n\t * @param id cache object id.\n\t */\n\tvoid remove(K id);\n\t\n\t/**\n\t * Clears the cache.\n\t */\n\tvoid clear();\n\n\t/**\n\t * Returns the cache stats.\n\t *\n\t * @return a {@link net.anotheria.moskito.core.predefined.CacheStats} object.\n\t */\n\tCacheStats getCacheStats();\n\n /**\n * Return all elements from cache.\n *\n * @return collection\n */\n Collection<V> getAllElements();\n\t\n}",
"public boolean existCache() {\n return false;\n }",
"public boolean isInMemory();",
"@Test\n public void testGetElementJavaPerfTest() throws Exception {\n\n Status somethingThatIsSerializable = Status.STATUS_ALIVE;\n byte[] serializedForm = MemoryEfficientByteArrayOutputStream.serialize(somethingThatIsSerializable).getBytes();\n\n assertEquals(404, HttpUtil.get(\"http://localhost:9090/ehcache/rest/sampleCache2/1\").getResponseCode());\n\n net.sf.ehcache.server.soap.jaxws.Element element = new net.sf.ehcache.server.soap.jaxws.Element();\n element.setKey(\"1\");\n element.setValue(serializedForm);\n cacheService.put(\"sampleCache2\", element);\n\n long begin = System.currentTimeMillis();\n for (int i = 0; i < 100; i++) {\n HttpURLConnection urlConnection = HttpUtil.get(\"http://localhost:9090/ehcache/rest/sampleCache2/1\");\n assertEquals(200, urlConnection.getResponseCode());\n }\n long end = System.currentTimeMillis();\n LOG.info(\"Get time: \" + (end - begin) / 100f);\n }",
"private static byte[] m2539e(Context context) {\n Throwable th;\n int i = 0;\n ByteArrayOutputStream byteArrayOutputStream = new ByteArrayOutputStream();\n byte[] bArr = new byte[0];\n String a = Log.m2547a(context, Log.f1857e);\n DiskLruCache diskLruCache = null;\n try {\n diskLruCache = DiskLruCache.m2767a(new File(a), 1, 1, 10240);\n File file = new File(a);\n if (file != null && file.exists()) {\n String[] list = file.list();\n int length = list.length;\n while (i < length) {\n String str = list[i];\n if (str.contains(\".0\")) {\n byteArrayOutputStream.write(StatisticsManager.m2535a(diskLruCache, str.split(\"\\\\.\")[0]));\n }\n i++;\n }\n }\n bArr = byteArrayOutputStream.toByteArray();\n if (byteArrayOutputStream != null) {\n try {\n byteArrayOutputStream.close();\n } catch (IOException e) {\n e.printStackTrace();\n }\n }\n if (diskLruCache != null) {\n try {\n diskLruCache.close();\n } catch (Throwable th2) {\n th = th2;\n }\n }\n } catch (IOException th3) {\n BasicLogHandler.m2542a(th3, \"StatisticsManager\", \"getContent\");\n if (byteArrayOutputStream != null) {\n try {\n byteArrayOutputStream.close();\n } catch (IOException e2) {\n e2.printStackTrace();\n }\n }\n if (diskLruCache != null) {\n diskLruCache.close();\n }\n } catch (Throwable th4) {\n th3 = th4;\n }\n return bArr;\n th3.printStackTrace();\n return bArr;\n }",
"public void store() throws PersistenceException {\n }",
"public static <T extends Entity> EntityCache<T> getMemoryEntityCache() {\n\t\tEntityMap<T> entityMap = new MemoryEntityMap<T>();\n\t\treturn new EntityCache<T>(entityMap);\n\t}",
"public interface ContentService extends KekeinfoEntityService<Long, Content>\n \n{\n\n\tpublic List<Content> listByType( String contentType)\n\t throws ServiceException;\n\n /**\n * Method responsible for storing content file for given Store.Files for given merchant store will be stored in\n * Infinispan.\n * \n * @param merchantStoreCode merchant store whose content images are being saved.\n * @param contentFile content image being stored\n * @throws ServiceException\n */\n void addContentFile(InputContentFile contentFile )\n throws ServiceException;\n\n \n /**\n * Method responsible for storing list of content image for given Store.Images for given merchant store will be stored in\n * Infinispan.\n * \n * @param merchantStoreCode merchant store whose content images are being saved.\n * @param contentImagesList list of content images being stored.\n * @throws ServiceException\n */\n void addContentFiles(List<InputContentFile> contentFilesList) throws ServiceException;\n \n \n /**\n * Method to remove given content image.Images are stored in underlying system based on there name.\n * Name will be used to search given image for removal\n * @param imageContentType\n * @param imageName\n * @param merchantStoreCode merchant store code\n * @throws ServiceException\n */\n public void removeFile(FileContentType fileContentType, String fileName) throws ServiceException;\n \n \n /**\n * Method to remove all images for a given merchant.It will take merchant store as an input and will\n * remove all images associated with given merchant store.\n * \n * @param merchantStoreCode\n * @throws ServiceException\n */\n public void removeFiles() throws ServiceException;\n \n /**\n * Method responsible for fetching particular content image for a given merchant store. Requested image will be\n * search in Infinispan tree cache and OutputContentImage will be sent, in case no image is found null will\n * returned.\n * \n * @param merchantStoreCode\n * @param imageName\n * @return {@link OutputContentImage}\n * @throws ServiceException\n */\n public OutputContentFile getContentFile(FileContentType fileContentType, String fileName )\n throws ServiceException;\n \n public InputStream getContentFileInputstream(FileContentType fileContentType, String fileName )\n throws ServiceException;\n \n \n /**\n * Method to get list of all images associated with a given merchant store.In case of no image method will return an empty list.\n * @param merchantStoreCode\n * @param imageContentType\n * @return list of {@link OutputContentImage}\n * @throws ServiceException\n */\n public List<OutputContentFile> getContentFiles(FileContentType fileContentType )\n throws ServiceException;\n\n\t\n List<String> getContentFilesNames(\n\t\t\tFileContentType fileContentType) throws ServiceException;\n\n /**\n * Add the store logo\n * @param merchantStoreCode\n * @param cmsContentImage\n * @throws ServiceException\n */\n\tvoid addLogo(InputContentFile cmsContentImage)\n\t\t\tthrows ServiceException;\n\n\t/**\n\t * Adds a property (option) image\n\t * @param merchantStoreId\n\t * @param cmsContentImage\n\t * @throws ServiceException\n\t */\n\tvoid addOptionImage(InputContentFile cmsContentImage)\n\t\t\tthrows ServiceException;\n\n\t\n\n}",
"public abstract FHIRPersistence getPersistenceImpl() throws Exception;",
"protected void loadStore() throws IOException {\n // auto create starting directory if needed\n if (!fileStore.exists()) {\n LOG.debug(\"Creating filestore: {}\", fileStore);\n File parent = fileStore.getParentFile();\n if (parent != null && !parent.exists()) {\n boolean mkdirsResult = parent.mkdirs();\n if (!mkdirsResult) {\n LOG.warn(\"Cannot create the filestore directory at: {}\", parent);\n }\n }\n boolean created = FileUtil.createNewFile(fileStore);\n if (!created) {\n throw new IOException(\"Cannot create filestore: \" + fileStore);\n }\n }\n\n LOG.trace(\"Loading to 1st level cache from state filestore: {}\", fileStore);\n\n cache.clear();\n try (Scanner scanner = new Scanner(fileStore, null, STORE_DELIMITER)) {\n while (scanner.hasNext()) {\n String line = scanner.next();\n int separatorIndex = line.indexOf(KEY_VALUE_DELIMITER);\n String key = line.substring(0, separatorIndex);\n String value = line.substring(separatorIndex + KEY_VALUE_DELIMITER.length());\n cache.put(key, value);\n }\n } catch (IOException e) {\n throw RuntimeCamelException.wrapRuntimeCamelException(e);\n }\n\n LOG.debug(\"Loaded {} to the 1st level cache from state filestore: {}\", cache.size(), fileStore);\n }",
"public byte[] cache(byte[] contents) {\r\n\t\tif (contents == null)\r\n\t\t\treturn null;\r\n\t\tByteArray ba = new ByteArray(contents);\r\n\t\tcache.putIfAbsent(ba, ba.contents);\r\n\t\treturn cache.get(ba);\r\n\t}",
"public void loadCache() {\r\n\t\tint rango = getEmpleadoActual().getRango();\r\n\t\tArrayList<String> idsDptos = getEmpleadoActual().getDepartamentosId();\r\n\t\t\r\n\t\t// Para todos los departamentos a los que pertenezca el empleado\r\n\t\tfor (int nd=0; nd<idsDptos.size(); nd++){\r\n\t\t\tString dep = idsDptos.get(nd);\r\n\t\t\tint numvendedor = getEmpleadoActual().getEmplId();\r\n\r\n\t\t\tif (!alive) return;\r\n\t\t\tsetProgreso(\"Cargando contratos dpto \"+dep, 50);\r\n\t\t\tcontratos = controlador.getListaContratosDpto(dep);\r\n\t\t\tsetProgreso(\"Cargando contratos dpto \"+dep, 100);\r\n\r\n\t\t\tif (!alive) return;\r\n\t\t\tsetProgreso(\"Cargando empleados dpto \"+dep, 25);\r\n\t\t\templeados = controlador.getEmpleadosDepartamento(getEmpleadoActual().getEmplId(),dep);\r\n\t\t\tsetProgreso(\"Cargando empleados dpto \"+dep, 100);\r\n\t\t\t\r\n\t\t\t//Prueba ordenación empleados\r\n//\t\t\tfor (int i = 0; i < empleados.size(); i++) {\r\n//\t\t\t\tSystem.out.println(empleados.get(i).getPosicion());\r\n//\t\t\t}\r\n\t\t\tordenaEmpleados();\r\n//\t\t\tfor (int i = 0; i < empleados.size(); i++) {\r\n//\t\t\t\tSystem.out.println(empleados.get(i).getPosicion());\r\n//\t\t\t}\r\n\t\t\t//Fin PRueba\r\n\t\t\t\r\n\t\t\t\r\n\t\t\tif (!alive) return;\r\n\t\t\tif (rango == 1) { // Si es un empleado, coger turnos de su departamento\r\n\t\t\t\tsetProgreso(\"Cargando turnos dpto \"+dep, 70);\r\n\t\t\t\tturnos = controlador.getListaTurnosEmpleadosDpto(dep);\r\n\t\t\t\tsetProgreso(\"Cargando turnos dpto \"+dep, 100);\r\n\t\t\t} else if (rango == 2) { // Si es un jefe, coger turnos de todos los departamentos\r\n\t\t\t\tArrayList<String> temp = new ArrayList<String>();\r\n\t\t\t\ttemp = controlador.getDepartamentosJefe(numvendedor);\r\n\t\t\t\tfor (int i=0; i<temp.size(); i++)\r\n\t\t\t\t\tdepartamentosJefe.add(controlador.getDepartamento(temp.get(i)));\r\n\t\t\t\t//TODO borrar si al final no se usa\r\n\t//\t\t\tsetProgreso(\"Cargando jefes de departamento\", 60);\r\n\t//\t\t\tnumeroJefesDepartamento = controlador.getNumVendedorTodosJefes();\r\n\t//\t\t\tnombreJefesDepartamento = controlador.getNombreTodosJefes();\r\n\t\t\t\tsetProgreso(\"Cargando turnos dpto \"+dep, 70);\r\n\t\t\t\tArrayList<Turno> turnosDep = new ArrayList<Turno>();\r\n\t\t\t\tfor (int i=0; i<departamentosJefe.size(); i++) {\r\n\t\t\t\t\tturnosDep = controlador.getListaTurnosEmpleadosDpto(departamentosJefe.get(i).getNombreDepartamento());\r\n\t\t\t\t\tfor (int j=0; j<turnosDep.size(); j++) {\r\n\t\t\t\t\t\tturnos.add(turnosDep.get(j));\r\n\t\t\t\t\t}\t\t\t\t\r\n\t\t\t\t}\r\n\t\t\t\tsetProgreso(\"Cargando turnos dpto \"+dep, 100);\r\n\t\t\t\t\r\n\t\t\t} else {\r\n\t\t\t\tSystem.err.println(\"Vista\\t:: Tipo de empleado inválido para cargar la cache.\");\r\n\t\t\t}\r\n\t\t}\r\n\t\tif(rango==1){//si es un empleado guardamos las ventas que éste ha hecho en un año\r\n\t\t\tjava.util.Date fecha = new java.util.Date();//cogemos la fecha del sistema\r\n\t\t\tvector_ventas=controlador.getVentas(this.getEmpleadoActual().getEmplId(),fecha.getYear()+1900);\r\n\t\t}else if(rango==2){//si es un jefe almacenamos la suma de las ventas de todos los empleados de este departamento durante un año\r\n\t\t\tjava.util.Date fecha = new java.util.Date();//cogemos la fecha del sistema\r\n\t\t\tvector_ventas=controlador.getVentasJefe(this.empleados,fecha.getYear()+1900);\r\n\t\t}\r\n\t\tSystem.out.println(\"Cache cargada\");\r\n\t}",
"@Override\n\tpublic long getCacheSize() {\n\t\treturn 0;\n\t}",
"@Override\r\n\tpublic File getCacheDir() {\r\n\t\treturn CommonUtil.getCacheDir();\r\n\t}",
"public void loadPersistencePreferences() {\n SharedPreferences sharedPreferences = PreferenceManager.getDefaultSharedPreferences(this);\n boolean persistent = sharedPreferences.getBoolean(\"TileCachePersistence\", true);\n Log.v(TAG, \"Cache Size: \" + sharedPreferences.getInt(\"TileCacheSize\", MapsActivity.FILE_SYSTEM_CACHE_SIZE_DEFAULT)\n + \", Persistent: \" + persistent);\n int capacity = Math.min(sharedPreferences.getInt(\"TileCacheSize\", MapsActivity.FILE_SYSTEM_CACHE_SIZE_DEFAULT),\n MapsActivity.FILE_SYSTEM_CACHE_SIZE_MAX);\n TileCache fileSystemTileCache = this.mapView.getFileSystemTileCache();\n\n fileSystemTileCache.setPersistent(persistent);\n fileSystemTileCache.setCapacity(capacity);\n // text size\n String textScaleDefault = getString(R.string.preferences_text_scale_default);\n this.mapView.setTextScale(Float.parseFloat(sharedPreferences.getString(\"mapTextScale\", textScaleDefault)));\n }",
"public void cacheResult(DataEntry dataEntry);",
"public final StorageType mo102949f() {\n return StorageType.CACHE;\n }",
"public interface TaskCache {\n /**\n * Gets an {@link Object} which will emit a {@link TaskEntity}.\n *\n * @param userId The id used to get data.\n */\n List<TaskEntity> get(int userId);\n\n /**\n * Puts and element into the cache.\n *\n * @param userEntity The task data to save.\n */\n void put(TaskEntity userEntity);\n\n /**\n * Checks if an element (User) exists in the cache.\n *\n * @param userId The id used to get data.\n * @return true if the element is cached, otherwise false.\n */\n boolean isCached(int userId);\n\n /**\n * Checks if the cache is expired.\n * @param userId The id used to get data.\n * @return true, the cache is expired, otherwise false.\n */\n boolean isExpired(int userId);\n\n /**\n * Evict all elements of the cache.\n *\n * @param userId The id used to get data.\n */\n void evictAll(int userId);\n\n /**\n * Change task status\n *\n * @param idTask task to update.\n */\n void refresh(int idTask);\n}",
"public HWDiskStore() {\n this.diskStore = new oshi.hardware.HWDiskStore();\n }",
"public void setCached() {\n }",
"protected void cacheLoadThroughSubjects()\n {\n }",
"protected void putDatabaseQueryCache(String key, String value) {\n\t\t\n\t\tSession session = this.openSession();\n\t\tsession.beginTransaction();\n\t\tsession.save( new Metainfo( key, value ) );\n\t\tsession.getTransaction().commit();\n\t\tsession.close();\n\t}",
"public EhcacheSessionDataStorage(Cache cache) {\n this.sessions = cache;\n }",
"public interface RedisCacheService {\n void put(Object key , Object value);\n Object get(Object key);\n}"
] | [
"0.6674702",
"0.6306582",
"0.61427796",
"0.6069443",
"0.6039678",
"0.60339516",
"0.5957282",
"0.5916387",
"0.5911694",
"0.5894672",
"0.58691275",
"0.584503",
"0.584104",
"0.58278775",
"0.57947874",
"0.5791239",
"0.57702464",
"0.5761656",
"0.5756557",
"0.5717346",
"0.570547",
"0.5697658",
"0.5688874",
"0.5681497",
"0.5681436",
"0.5678191",
"0.56772",
"0.5668846",
"0.56576896",
"0.5655925",
"0.565411",
"0.5646157",
"0.56419086",
"0.56416094",
"0.5629876",
"0.56273407",
"0.5619051",
"0.5616831",
"0.5613011",
"0.55935293",
"0.55799246",
"0.55668145",
"0.5559301",
"0.5557874",
"0.55559975",
"0.5550392",
"0.55297047",
"0.5510884",
"0.5508835",
"0.5506286",
"0.5502848",
"0.55027914",
"0.54983586",
"0.5490101",
"0.54758745",
"0.547478",
"0.5473333",
"0.5471569",
"0.54700303",
"0.5463018",
"0.5457268",
"0.54504764",
"0.54449224",
"0.5444591",
"0.5443677",
"0.54258895",
"0.54236054",
"0.54219824",
"0.54190123",
"0.5418893",
"0.5417253",
"0.5416356",
"0.54148686",
"0.54145175",
"0.5413354",
"0.54126453",
"0.5405644",
"0.54023844",
"0.54010856",
"0.5399931",
"0.5397113",
"0.539385",
"0.5391534",
"0.5389829",
"0.5381737",
"0.5376209",
"0.53752947",
"0.5373908",
"0.53737915",
"0.5365451",
"0.5363244",
"0.53562087",
"0.5352872",
"0.5348164",
"0.5347074",
"0.5346791",
"0.53459626",
"0.53435004",
"0.5342258",
"0.5342004",
"0.53396744"
] | 0.0 | -1 |
Current use ehcache which has disk persistence feature, no more work to do here | @Override
public void restore() {
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public interface EzyerCache {\n class PersistentObject {\n public final byte[] mData;\n public final String mKey;\n public final long mExpireTimeMillis;\n\n public PersistentObject(byte[] data, String key, long expireTimeMillis) {\n mData = data;\n mKey = key;\n mExpireTimeMillis = expireTimeMillis;\n }\n }\n\n class ValueObject {\n public final byte[] mData;\n public final String mKey;\n public final boolean mIsExpired;\n\n public ValueObject(byte[] data, String key, boolean isExpired) {\n mData = data;\n mKey = key;\n mIsExpired = isExpired;\n }\n }\n\n ValueObject get(String key);\n\n List<ValueObject> get(String key, int start, int end);\n\n void set(PersistentObject po);\n\n void add(PersistentObject po);\n\n void remove(String key);\n\n boolean isExpired(String key);\n\n void clear();\n}",
"interface Cache {\n\n /** @return A cache entry for given path string or <code>null</code> (if file cannot be read or too large to cache).\n * This method increments CacheEntry reference counter, caller must call {@link #checkIn(CacheEntry)} to release returned entry (when not null). */\n CacheEntry checkOut(CacheEntryLoader cacheEntryLoader);\n\n /**\n * Method to release cache entry previously obtained from {@link #checkOut(CacheEntryLoader)} call.\n * This method decrements CacheEntry reference counter.\n */\n void checkIn(CacheEntry key);\n\n /** Invalidates cached entry for given path string (if it is cached) */\n void invalidate(String pathString);\n\n void rename(String fromPathString, String toPathString);\n\n// /** Preload given file path in cache (if cache has vacant spot). Preloading happens in background. Preloaded pages initially have zero reference counter. */\n// void preload (String pathString);\n\n /** Clears the cache of all entries (even if some entries are checked out) */\n void clear();\n\n /** Allocates entry of given size for writing.\n * It will not be visible to others until caller calls {@link #update(String, CacheEntry)}.*/\n CacheEntry alloc(long size);\n\n /** Registers recently writtien cache entry as available for reading */\n void update(String pathString, CacheEntry cacheEntry);\n}",
"private void testAllFile(String ehCacheFile) throws Exception {\n ClassLoader existingCl = currentThread().getContextClassLoader();\n DefaultCacheManager dcm = null;\n Cache<Object, Object> sampleDistributedCache2 = null;\n try {\n ClassLoader delegatingCl = new Jbc2InfinispanTransformerTest.TestClassLoader(existingCl);\n currentThread().setContextClassLoader(delegatingCl);\n String fileName = getFileName(ehCacheFile);\n ByteArrayOutputStream baos = new ByteArrayOutputStream();\n convertor.parse(fileName, baos, ConfigFilesConvertor.TRANSFORMATIONS.get(ConfigFilesConvertor.EHCACHE_CACHE1X), Thread.currentThread().getContextClassLoader());\n\n dcm = (DefaultCacheManager) TestCacheManagerFactory.fromStream(new ByteArrayInputStream(baos.toByteArray()));\n Cache<Object,Object> defaultCache = dcm.getCache();\n defaultCache.put(\"key\", \"value\");\n Configuration configuration = defaultCache.getCacheConfiguration();\n\n assertEquals(configuration.eviction().maxEntries(),10000);\n assertEquals(configuration.expiration().maxIdle(), 121);\n assertEquals(configuration.expiration().lifespan(), 122);\n LoadersConfiguration loaders = configuration.loaders();\n assert loaders.cacheLoaders().get(0) instanceof FileCacheStoreConfiguration;\n\n assertEquals(configuration.expiration().wakeUpInterval(), 119000);\n assertEquals(configuration.eviction().strategy(), EvictionStrategy.LRU);\n\n String definedCacheNames = dcm.getDefinedCacheNames();\n assert definedCacheNames.contains(\"sampleCache1\");\n assert definedCacheNames.contains(\"sampleCache2\");\n assert definedCacheNames.contains(\"sampleCache3\");\n assert definedCacheNames.contains(\"sampleDistributedCache1\");\n assert definedCacheNames.contains(\"sampleDistributedCache2\");\n assert definedCacheNames.contains(\"sampleDistributedCache3\");\n\n sampleDistributedCache2 = dcm.getCache(\"sampleDistributedCache2\");\n Configuration configuration2 = sampleDistributedCache2.getCacheConfiguration();\n assert configuration2.loaders().cacheLoaders().size() == 1;\n assert configuration2.expiration().lifespan() == 101;\n assert configuration2.expiration().maxIdle() == 102;\n assertEquals(configuration2.clustering().cacheMode(), CacheMode.INVALIDATION_SYNC);\n\n } finally {\n currentThread().setContextClassLoader(existingCl);\n TestingUtil.killCaches(sampleDistributedCache2);\n TestingUtil.killCacheManagers(dcm);\n }\n }",
"public interface CacheManager extends AutoCloseable {\n /**\n * @param conf the Alluxio configuration\n * @return an instance of {@link CacheManager}\n */\n static CacheManager create(AlluxioConfiguration conf) throws IOException {\n // TODO(feng): make cache manager type configurable when we introduce more implementations.\n return new NoExceptionCacheManager(LocalCacheManager.create(conf));\n }\n\n /**\n * Puts a page into the cache manager. This method is best effort. It is possible that this put\n * operation returns without page written.\n *\n * @param pageId page identifier\n * @param page page data\n * @return true if the put was successful, false otherwise\n */\n boolean put(PageId pageId, byte[] page);\n\n /**\n * Wraps the page in a channel or null if the queried page is not found in the cache or otherwise\n * unable to be read from the cache.\n *\n * @param pageId page identifier\n * @return a channel to read the page\n */\n @Nullable\n ReadableByteChannel get(PageId pageId);\n\n /**\n * Wraps a part of the page in a channel or null if the queried page is not found in the cache or\n * otherwise unable to be read from the cache.\n *\n * @param pageId page identifier\n * @param pageOffset offset into the page\n * @return a channel to read the page\n */\n @Nullable\n ReadableByteChannel get(PageId pageId, int pageOffset);\n\n /**\n * Deletes a page from the cache.\n *\n * @param pageId page identifier\n * @return true if the page is successfully deleted, false otherwise\n */\n boolean delete(PageId pageId);\n}",
"public interface ICache {\n\t\n\t/**\n\t * <p>\n\t * get the Cached Object from cache pool by the cache String key\n\t * @param key\n\t * @return\n\t */\n\tpublic Object get(String key);\n\t\n\t\n\t\n\t/**\n\t * <p>\n\t * \n\t * @param key\n\t * @return old cache object \n\t */\n\tpublic Object put(String key,Object value);\n\t\n\t/**\n\t * <p>\n\t * get the Cached Object from cache pool by the cache String key quietly,\n\t * without update the statistic data\n\t * @param key\n\t * @return\n\t */\n\tpublic Object getQuiet(String key);\n\t\n\t\n\t/**\n\t * <p>\n\t * remove the cached object from cache pool by the cache String key\n\t * @param key\n\t * @return\n\t */\n\tpublic Object remove(String key);\n\t\n\t/**\n\t * <p>\n\t * free specied size mem\n\t * @param size unit in Byte\n\t * @return\n\t */\n\tpublic long free(long size);\n\t\n\t\n\t/**\n\t * <p>\n\t * flush to the underly resource\n\t */\n\tpublic void flush();\n\t\n}",
"protected Entity cacheLoadOrStore(Entity entity) {\n Entity cachedEntity = entityCache.findInCache(entity.getClass(), entity.getId());\n if (cachedEntity != null) {\n return cachedEntity;\n }\n entityCache.put(entity, true);\n return entity;\n }",
"private static void putInPersistentCache(final Asset asset) {\n \n \t\tif (!usePersistentCache) {\n \t\t\treturn;\n \t\t}\n \n \t\tif (!assetIsInPersistentCache(asset)) {\n \n \t\t\tfinal File assetFile = getAssetCacheFile(asset);\n \n \t\t\tnew Thread() {\n \t\t\t\t@Override\n \t\t\t\tpublic void run() {\n \n \t\t\t\t\ttry {\n \t\t\t\t\t\tassetFile.getParentFile().mkdirs();\n \t\t\t\t\t\t// Image\n \t\t\t\t\t\tOutputStream out = new FileOutputStream(assetFile);\n \t\t\t\t\t\tout.write(asset.getImage());\n \t\t\t\t\t\tout.close();\n \n \t\t\t\t\t} catch (IOException ioe) {\n \t\t\t\t\t\tlog.error(\"Could not persist asset while writing image data\", ioe);\n \t\t\t\t\t\treturn;\n \t\t\t\t\t}\n \t\t\t\t}\n \t\t\t}.start();\n \n \t\t}\n \t\tif (!assetInfoIsInPersistentCache(asset)) {\n \n \t\t\tFile infoFile = getAssetInfoFile(asset);\n \n \t\t\ttry {\n \t\t\t\t// Info\n \t\t\t\tOutputStream out = new FileOutputStream(infoFile);\n \t\t\t\tProperties props = new Properties();\n \t\t\t\tprops.put(NAME, asset.getName() != null ? asset.getName() : \"\");\n \t\t\t\tprops.store(out, \"Asset Info\");\n \t\t\t\tout.close();\n \n \t\t\t} catch (IOException ioe) {\n \t\t\t\tlog.error(\"Could not persist asset while writing image properties\", ioe);\n \t\t\t\treturn;\n \t\t\t}\n \n \t\t}\n \t}",
"public void createOrReadCache() {\n\t\tList<String> cachedDirectoryPaths = new ArrayList<>();\n\t\tFile file = new File(LevelEditor.SAVED_PATH_DATA);\n\t\tif (!file.exists()) {\n\t\t\t// Set the default paths first\n\t\t\tFileControl.lastSavedDirectory = new File(LevelEditor.defaultPath);\n\t\t\tScriptEditor.lastSavedDirectory = FileControl.lastSavedDirectory;\n\n\t\t\tcachedDirectoryPaths.add(FileControl.lastSavedDirectory.getAbsolutePath());\n\n\t\t\ttry (RandomAccessFile raf = new RandomAccessFile(file, \"rw\")) {\n\t\t\t\tthis.storeCachedDirectories(raf, cachedDirectoryPaths);\n\t\t\t}\n\t\t\tcatch (IOException e) {\n\t\t\t\tDebug.exception(e);\n\t\t\t}\n\t\t}\n\t\telse {\n\t\t\ttry (RandomAccessFile raf = new RandomAccessFile(file, \"r\")) {\n\t\t\t\tthis.fetchCachedDirectories(raf, cachedDirectoryPaths);\n\t\t\t}\n\t\t\tcatch (IOException e) {\n\t\t\t\tDebug.exception(e);\n\t\t\t}\n\n\t\t\tFileControl.lastSavedDirectory = new File(cachedDirectoryPaths.get(LevelEditor.FileControlIndex));\n\t\t\tScriptEditor.lastSavedDirectory = FileControl.lastSavedDirectory;\n\t\t}\n\t}",
"public static <T extends Entity> EntityCache<T> getDiskEntityCache(DB db, String name) {\n\t\tEntityMap<T> entityMap = new DiskEntityMap<T>(db, name);\n\t\treturn new EntityCache<T>(entityMap);\n\t}",
"@Override\n public boolean isCaching() {\n return false;\n }",
"public interface MongoDBCache<K, V> {\n /**\n * Size of the cache\n *\n * @return size\n */\n int size();\n\n /**\n * Purge all data from cache\n */\n void clear();\n\n /**\n * Remove the entry which has the same key of the parameter\n *\n * @param key\n * @return the removed cache entry\n */\n boolean remove(byte[] key);\n\n /**\n * Get a cache entry which has the same key of the parameter\n *\n * @param key\n * @return\n */\n MongoDBEntry<K, V> get(byte[] key);\n\n /**\n * Verify if the cache contains the key passed on parameter\n *\n * @param key\n * @return true if there is some entry, false if there is not\n */\n boolean containsKey(byte[] key);\n\n /**\n * Since mongo doesn't support actual paging results,\n * we have to sort and do a less than on the last id.\n *\n * @param lastKey\n * @return\n */\n List<MongoDBEntry<K, V>> getPagedEntries(byte[] lastKey);\n\n /**\n * This method must remove all data which are expired. <br/>\n * What means delete all entries that have the expiryTime parameter less than the current date.\n */\n List<MongoDBEntry<K, V>> removeExpiredData(byte[] lastKey);\n\n /**\n * Put an entry to the cache\n *\n * @param entry\n */\n void put(MongoDBEntry<K, V> entry);\n\n void start() throws Exception;\n\n /***\n *\n */\n void stop();\n}",
"public interface TAFSCacheInterface\n{\n//\tabstract void ConnectCache() throws IOException;\n//\tabstract void DisconnectCache();\n//\tabstract byte[] GetFileFromCache(String inFileName);\n//\tabstract void PutFileInCache(String inFileName, byte[] inFileBytes);\n}",
"public ImageFileCache(Context context){\n\t\tFile cacheDir = getCacheDir(context, DISK_CACHE_SUBDIR);\n//\t\tmDiskCache = DiskLruCache.openCache(this, cacheDir, DISK_CACHE_SIZE);\n\t}",
"public DataPersistence() {\n storage = new HashMap<>();\n idCounter = 0;\n }",
"interface OfBizUserCache {\n /**\n * Retrieve a User by userName case insensitively.\n *\n * @param directoryId The directory.\n * @param userName User name.\n * @return A user.\n */\n OfBizUser getCaseInsensitive(long directoryId, String userName);\n\n /**\n * Retrieve all Users by id given a list of ids.\n *\n * @param directoryId The directory.\n * @param userIds List of user Ids\n * @return A list of {@link OfBizUser}.\n */\n List<OfBizUser> getAllCaseInsensitive(long directoryId, Collection<String> userIds);\n\n /**\n * Remove a user from the cache.\n *\n * @param directoryId The directory.\n * @param userName User name.\n */\n void remove(long directoryId, String userName);\n\n /**\n * Remove a user from the cache.\n *\n * @param key The Users key\n */\n void remove(DirectoryEntityKey key);\n\n /**\n * Visit all the users in the directory.\n * Some implementations may process this directly from the underlying persistent store rather than the\n * cache if they do not keep a canonical set of all users in the cache.\n *\n * @param directoryId The directory\n * @param visitor A Visitor\n */\n void visitAllUserIdsInDirectory(long directoryId, Visitor<String> visitor);\n\n /**\n * Refresh the cache entry for the supplied user.\n * Should be called when a user is added or updated. The implementation may do this\n * either by storing he supplied value or refreshing the data from the underlying persistent store.\n *\n * @param user User to be refreshed in the cache\n * @return The key of the user.\n */\n DirectoryEntityKey refresh(OfBizUser user);\n\n /**\n * Refresh all entries in the cache.\n */\n void refresh();\n\n /**\n * Return true if the cache is initialised and can be used.\n * JIRA relies heavily on having access to users and if the cache needs time to initialise before it\n * can be relied on to provide correct results, JIRA needs to wait.\n *\n * @return true if initialised.\n */\n boolean isCacheInitialized();\n}",
"public interface CacheManager {\n\n void init();\n\n void destroy();\n\n void del(String key);\n\n void set(String key, Object value);\n\n void set(String key, Object value, int expireTime);\n\n <T> T get(String key, Class<T> clazz);\n\n void hset(String key, String subKey, Object value);\n\n <T> T hget(String key, String subKey, Class<T> clazz);\n\n <T> Map<String, T> hget(String key, Class<T> clazz);\n\n void hrem(String key, String subKey);\n\n long hincr(String key, String subKey);\n\n void sadd(String key, Object val);\n\n boolean sisMember(String key, Object val);\n\n void srem(String key, Object val);\n\n Set<String> sget(String key);\n\n <T> Set<T> sget(String key, Class<T> clazz);\n\n void zadd(String key, Object val, double score);\n\n boolean zisMember(String key, Object val);\n\n void zrem(String key, Object val);\n\n void zrem(String key, double min, double max);\n\n void zreplace(String key, Object val, double score);\n\n double zincr(String key, Object val, double score);\n\n <T> Set<T> zget(String key, double min, double max, Class<T> clazz);\n\n Set<String> zget(String key, double min, double max);\n}",
"public void testMultiEMCachingTrue() {\n Map props = new HashMap(System.getProperties());\n props.put(\"openjpa.MetaDataFactory\", \"jpa(Types=\" + Person.class.getName() + \")\");\n props.put(\"openjpa.jdbc.QuerySQLCache\", \"true\");\n runMultiEMCaching(props);\n }",
"public interface IBaseCache<T> {\n\n void setById(String id, T o);\n\n void setById(String id, T o, int timeout);\n\n void set(String key, T o);\n\n void set(String key, T o, int timeout);\n\n T getById(String id);\n\n T get(String key);\n\n void setList(List<T> list);\n\n void setList(List<T> list, int timeout);\n\n boolean hasList();\n\n List<T> getList();\n\n void setList(String key, List<T> list);\n\n void setList(String key, List<T> list, int timeout);\n\n boolean hasList(String key);\n\n List<T> getList(String key);\n\n boolean hasKeyById(String id);\n\n boolean hasKey(String key);\n\n void deleteKeyById(String id);\n\n void deleteKey(String key);\n\n void deleteList();\n\n void deleteList(String key);\n\n void deleteAllEntityKeys();\n\n\n}",
"public interface CacheRepository {\n Object select(String key);\n void insert(String key, Object value);\n void delete(String key);\n boolean exists(String key);\n}",
"public void flushEntityCache() {\n super.flushEntityCache();\n }",
"@Override\r\n protected void processUpdate(final ICacheElement<K, V> ce)\r\n {\r\n if (!isAlive())\r\n {\r\n log.error(\"{0}: No longer alive; aborting put of key = {1}\",\r\n () -> logCacheName, ce::getKey);\r\n return;\r\n }\r\n\r\n log.debug(\"{0}: Storing element on disk, key: {1}\",\r\n () -> logCacheName, ce::getKey);\r\n\r\n // old element with same key\r\n IndexedDiskElementDescriptor old = null;\r\n\r\n try\r\n {\r\n IndexedDiskElementDescriptor ded = null;\r\n final byte[] data = getElementSerializer().serialize(ce);\r\n\r\n // make sure this only locks for one particular cache region\r\n storageLock.writeLock().lock();\r\n try\r\n {\r\n old = keyHash.get(ce.getKey());\r\n\r\n // Item with the same key already exists in file.\r\n // Try to reuse the location if possible.\r\n if (old != null && data.length <= old.len)\r\n {\r\n // Reuse the old ded. The defrag relies on ded updates by reference, not\r\n // replacement.\r\n ded = old;\r\n ded.len = data.length;\r\n }\r\n else\r\n {\r\n // we need this to compare in the recycle bin\r\n ded = new IndexedDiskElementDescriptor(dataFile.length(), data.length);\r\n\r\n if (doRecycle)\r\n {\r\n final IndexedDiskElementDescriptor rep = recycle.ceiling(ded);\r\n if (rep != null)\r\n {\r\n // remove element from recycle bin\r\n recycle.remove(rep);\r\n ded = rep;\r\n ded.len = data.length;\r\n recycleCnt++;\r\n this.adjustBytesFree(ded, false);\r\n log.debug(\"{0}: using recycled ded {1} rep.len = {2} ded.len = {3}\",\r\n logCacheName, ded.pos, rep.len, ded.len);\r\n }\r\n }\r\n\r\n // Put it in the map\r\n keyHash.put(ce.getKey(), ded);\r\n\r\n if (queueInput)\r\n {\r\n queuedPutList.add(ded);\r\n log.debug(\"{0}: added to queued put list. {1}\",\r\n () -> logCacheName, queuedPutList::size);\r\n }\r\n\r\n // add the old slot to the recycle bin\r\n if (old != null)\r\n {\r\n addToRecycleBin(old);\r\n }\r\n }\r\n\r\n dataFile.write(ded, data);\r\n }\r\n finally\r\n {\r\n storageLock.writeLock().unlock();\r\n }\r\n\r\n log.debug(\"{0}: Put to file: {1}, key: {2}, position: {3}, size: {4}\",\r\n logCacheName, fileName, ce.getKey(), ded.pos, ded.len);\r\n }\r\n catch (final IOException e)\r\n {\r\n log.error(\"{0}: Failure updating element, key: {1} old: {2}\",\r\n logCacheName, ce.getKey(), old, e);\r\n }\r\n }",
"public interface ILeveledCache<K, V> extends ICache<K, V>{\n void reCache() throws IOException, ClassNotFoundException;\n Map<K, V> add(K key, V object) throws IOException, ClassNotFoundException;\n List<K> sortedKeys();\n int maxLevel1size();\n Set<K> level1keys();\n}",
"public interface Cache<K,E> {\n\tpublic E getCacheEntry(K id);\n\t\n\tpublic boolean addCacheEntry(K id, E entry);\n\t\n\tpublic void removeCacheEntry(K id);\n\t\n\tpublic Stream<E> getAllEntries();\n}",
"public EhcacheSessionDataStorage(String name) {\n this.sessions = CacheManager.getInstance().getCache(name);\n }",
"private static boolean assetIsInPersistentCache(MD5Key id) {\n \n \t\treturn getAssetCacheFile(id).exists() && getAssetCacheFile(id).length() > 0;\n \t}",
"private ImageCache(Context context) {\n int memClass = ((ActivityManager) context.getSystemService(Context.ACTIVITY_SERVICE)).getMemoryClass();\n memClass = memClass > 32 ? 32 : memClass;\n\n final int cacheSize = 1024 * 1024 * memClass / 8;\n memoryCache = new LruCache<String, Bitmap>(cacheSize) {\n protected int sizeOf(String key, Bitmap bitmap) {\n return bitmap.getRowBytes() * bitmap.getHeight();\n }\n };\n\n File cacheDir = DiskLruCache.getDiskCacheDir(context, DISK_CACHE_SUB_DIR);\n diskCache = DiskLruCache.openCache(context, cacheDir, DISK_CACHE_SIZE);\n }",
"@Override\r\npublic boolean writeEntries(CacheObject obj) {\n\t\r\n\ttry {\r\n\t\t\r\n\t\tthis.writer.append(\"[\"+obj.toString()+\"]\\r\\n\");\r\n\t\tthis.writer.flush();\r\n\t} catch (IOException e) {\r\n\t\tSystem.out.println(\"Error Occured while writing into File :\"+ e.getMessage());\r\n\t\te.printStackTrace();\r\n\t\t\r\n\t} \r\n\t\r\n\treturn false;\r\n}",
"private boolean saveObjectToFile(String filename,Object object) {\n //engine.logMessage(\"Saving new cache data to: \"+filename);\n ObjectOutputStream outputStream = null;\n try { \n File file=new File(filename);\n File directory=file.getParentFile();\n if (directory==null) throw new IOException(\"Cache directory error\");\n synchronized(this) { // synchronize this because the mkdirs will return false if the directory has been created by another Thread in the meantime\n if (!directory.exists()) {\n if (!directory.mkdirs()) throw new IOException(\"Unable to create cache directory: \"+directory.getAbsolutePath());\n }\n }\n outputStream = new ObjectOutputStream(new BufferedOutputStream(new FileOutputStream(file)));\n outputStream.writeObject(object);\n outputStream.close(); \n } catch (Exception e) {\n engine.logMessage(\"WARNING: Unable to store data in cache: \"+e.getMessage());\n return false;\n } finally {\n try {if (outputStream!=null) outputStream.close();} catch (Exception x) {engine.logMessage(\"SYSTEM WARNING: Unable to close ObjectOutputStream in cache: \"+x.getMessage());}\n } \n return true; \n }",
"public interface Cache {\r\n\r\n public Object get( Object key);\r\n public void put( Object key, Object value);\r\n}",
"public void syncCache() {\n for (String s : this.cache.keySet()) {\n JsonDocument document = this.cache.get(s);\n document.save(new File(directory, s + \".json\"));\n }\n }",
"public void cacheableQuery() throws HibException;",
"public HashStore(HashChunkServiceInterface hcs) throws IOException {\n\t\tthis.name = \"sdfs\";\n\t\tthis.hcs = hcs;\n\t\ttry {\n\t\t\tthis.connectDB();\n\t\t} catch (Exception e) {\n\t\t\te.printStackTrace();\n\t\t}\n\t\t// this.initChunkStore();\n\t\tSDFSLogger.getLog().info(\"Cache Size = \" + Main.chunkStorePageSize);\n\t\tSDFSLogger.getLog().info(\"Total Entries \" + +bdb.getSize());\n\t\tSDFSLogger.getLog().info(\"Added \" + this.name);\n\t\tthis.closed = false;\n\t}",
"public CacheStrategy getCacheStrategy();",
"public interface SCStorage\r\n{\r\n\t/**\r\n\t * The server will register a driver before making any method calls\r\n\t *\r\n\t * @param driver the driver\r\n\t */\r\n\tpublic void setStorageServerDriver(SCStorageServerDriver driver);\r\n\r\n\t/**\r\n\t * Open the storage at the given path\r\n\t *\r\n\t * @param path path to the storage\r\n\t * @throws IOException errors\r\n\t */\r\n\tpublic void\topen(File path) throws IOException;\r\n\r\n\t/**\r\n\t * Return the object associated with the given key\r\n\t *\r\n\t * @param key the key\r\n\t * @return the object or null if not found\r\n\t * @throws IOException errors\r\n\t */\r\n\tpublic SCDataSpec get(String key) throws IOException;\r\n\r\n\t/**\r\n\t * Add an object to the storage\r\n\t *\r\n\t * @param key key\r\n\t * @param data object\r\n\t * @param groups associated groups or null\r\n\t */\r\n\tpublic void put(String key, SCDataSpec data, SCGroupSpec groups);\r\n\r\n\t/**\r\n\t * Close the storage. The storage instance will be unusable afterwards.\r\n\t *\r\n\t * @throws IOException errors\r\n\t */\r\n\tpublic void close() throws IOException;\r\n\r\n\t/**\r\n\t * Return the keys that match the given regular expression\r\n\t *\r\n\t * @param regex expression\r\n\t * @return matching keys\r\n\t */\r\n\tpublic Set<String> regexFindKeys(String regex);\r\n\r\n\t/**\r\n\t * Remove the given object\r\n\t *\r\n\t * @param key key of the object\r\n\t * @throws IOException errors\r\n\t */\r\n\tpublic void remove(String key) throws IOException;\r\n\r\n\t/**\r\n\t * sccache supports associative keys via {@link SCGroup}. This method deletes all objects\r\n\t * associated with the given group.\r\n\t *\r\n\t * @param group the group to delete\r\n\t * @return list of keys deleted.\r\n\t * @throws IOException errors\r\n\t */\r\n\tpublic List<String> removeGroup(SCGroup group) throws IOException;\r\n\r\n\t/**\r\n\t * sccache supports associative keys via {@link SCGroup}. This method lists all keys\r\n\t * associated with the given group.\r\n\t *\r\n\t * @param group the group to list\r\n\t * @return list of keys\r\n\t * @throws IOException errors\r\n\t */\r\n\tpublic List<String> listGroup(SCGroup group) throws IOException;\r\n\r\n\t/**\r\n\t * Returns storage statistics\r\n\t *\r\n\t * @param verbose if true, verbose stats are returned\r\n\t * @return list of stats\r\n\t * @throws IOException errors\r\n\t */\r\n\tpublic List<String> dumpStats(boolean verbose) throws IOException;\r\n\r\n\t/**\r\n\t * Write a tab delimited file with information about the key index\r\n\t *\r\n\t * @param f the file to write to\r\n\t * @throws IOException errors\r\n\t */\r\n\tpublic void writeKeyData(File f) throws IOException;\r\n}",
"private DiskCache getDefaultDiskCache(Context context) {\n DiskCache defaultDiskCache;\n File cacheDir = StorageUtils.getOwnCacheDirectory(context, \"keep/cache\");\n\n try {\n defaultDiskCache = new LruDiskCache(cacheDir, new HashCodeFileNameGenerator(), 50 * 1024 * 1024);\n } catch (IOException e) {\n defaultDiskCache = new UnlimitedDiskCache(cacheDir);\n }\n\n return defaultDiskCache;\n }",
"private static boolean assetIsInPersistentCache(Asset asset) {\n \t\treturn assetIsInPersistentCache(asset.getId());\n \t}",
"public interface DataModelOracleCache {\n\n /**\n * Retrieve the DataModelOracle for the specified Project path. The Path should resolve to a Project.\n * @param project The Path to the Project\n * @return DataModelOracle for the Project\n */\n DataModelOracle getDataModelOracle( Path project );\n\n /**\n * Set the DataModelOracle for the specified Project path. The Path should resolve to a Project.\n * @param project The Path to the Project\n * @param oracle The DataModelOracle for the Project\n */\n void setDataModelOracle( Path project,\n DataModelOracle oracle );\n\n /**\n * Invalidate the entire cache\n */\n void invalidateCache();\n\n /**\n * Invalidate the cache for a specific Project path. The path should resolve to a Project.\n * @param project The Path to the Project\n */\n void invalidateCache( Path project );\n}",
"@Override\r\n protected ICacheElement<K, V> processGet(final K key)\r\n {\r\n if (!isAlive())\r\n {\r\n log.error(\"{0}: No longer alive so returning null for key = {1}\",\r\n logCacheName, key);\r\n return null;\r\n }\r\n\r\n log.debug(\"{0}: Trying to get from disk: {1}\", logCacheName, key);\r\n\r\n ICacheElement<K, V> object = null;\r\n try\r\n {\r\n storageLock.readLock().lock();\r\n try\r\n {\r\n object = readElement(key);\r\n }\r\n finally\r\n {\r\n storageLock.readLock().unlock();\r\n }\r\n\r\n if (object != null)\r\n {\r\n hitCount.incrementAndGet();\r\n }\r\n }\r\n catch (final IOException ioe)\r\n {\r\n log.error(\"{0}: Failure getting from disk, key = {1}\", logCacheName, key, ioe);\r\n reset();\r\n }\r\n return object;\r\n }",
"public interface UserEntityCache {\n int getHitCount();\n int getMissCount();\n\n void put(long key, CacheElement<UserEntity> cacheElement);\n\n CacheElement<UserEntity> get(long key);\n}",
"public void resetCache() {\n logger.info(\"resetCache(): refilling clinical attribute cache\");\n\n Date dateOfCurrentCacheRefresh = new Date();\n ArrayList<ClinicalAttributeMetadata> latestClinicalAttributeMetadata = null;\n // latestOverrides is a map of study-id to list of overridden ClinicalAttributeMetadata objects\n Map<String, ArrayList<ClinicalAttributeMetadata>> latestOverrides = null;\n\n // attempt to refresh ehcache stores seperately and store success status\n boolean failedClinicalAttributeMetadataCacheRefresh = false;\n boolean failedOverridesCacheRefresh = false;\n try {\n clinicalAttributeMetadataPersistentCache.updateClinicalAttributeMetadataInPersistentCache();\n } catch (RuntimeException e) {\n logger.error(\"resetCache(): failed to pull clinical attributes from repository. Error message returned: \" + e.getMessage());\n failedClinicalAttributeMetadataCacheRefresh = true;\n }\n\n try {\n clinicalAttributeMetadataPersistentCache.updateClinicalAttributeMetadataOverridesInPersistentCache();\n } catch (RuntimeException e) {\n logger.error(\"resetCache(): failed to pull overrides from repository. Error message returned: \" + e.getMessage());\n failedOverridesCacheRefresh = true;\n }\n\n // regardless of whether ehcache was updated with new data - use that data to populate modeled object caches\n // ensures app starts up (between tomcat restarts) if TopBraid is down\n logger.info(\"Loading modeled object cache from EHCache\");\n try {\n // this will throw an exception if we cannot connect to TopBraid AND cache is corrupt\n latestClinicalAttributeMetadata = clinicalAttributeMetadataPersistentCache.getClinicalAttributeMetadataFromPersistentCache();\n latestOverrides = clinicalAttributeMetadataPersistentCache.getClinicalAttributeMetadataOverridesFromPersistentCache();\n } catch (Exception e) {\n try {\n // this will throw an exception if backup is unavailable\n logger.error(\"Unable to load modeled object cache from default EHCache... attempting to read from backup\");\n latestClinicalAttributeMetadata = clinicalAttributeMetadataPersistentCache.getClinicalAttributeMetadataFromPersistentCacheBackup();\n latestOverrides = clinicalAttributeMetadataPersistentCache.getClinicalAttributeMetadataOverridesFromPersistentCacheBackup();\n if (latestClinicalAttributeMetadata == null || latestOverrides == null) {\n throw new FailedCacheRefreshException(\"No data found in specified backup cache location...\", new Exception());\n }\n } catch (Exception e2) {\n logger.error(\"Unable to load modeled object cache from backup EHCache...\");\n throw new FailedCacheRefreshException(\"Unable to load data from all backup caches...\", new Exception());\n }\n }\n\n // backup cache at this point (maybe backup after each successful update above?)\n if (!failedClinicalAttributeMetadataCacheRefresh && !failedOverridesCacheRefresh) {\n logger.info(\"resetCache(): cache update succeeded, backing up cache...\");\n try {\n clinicalAttributeMetadataPersistentCache.backupClinicalAttributeMetadataPersistentCache(latestClinicalAttributeMetadata);\n clinicalAttributeMetadataPersistentCache.backupClinicalAttributeMetadataOverridesPersistentCache(latestOverrides);\n logger.info(\"resetCache(): succesfully backed up cache\");\n } catch (Exception e) {\n logger.error(\"resetCache(): failed to backup cache: \" + e.getMessage());\n }\n }\n\n HashMap<String, ClinicalAttributeMetadata> latestClinicalAttributeMetadataCache = new HashMap<String, ClinicalAttributeMetadata>();\n for (ClinicalAttributeMetadata clinicalAttributeMetadata : latestClinicalAttributeMetadata) {\n latestClinicalAttributeMetadataCache.put(clinicalAttributeMetadata.getColumnHeader(), clinicalAttributeMetadata);\n }\n\n // latestOverridesCache is a map of study-id to map of clinical attribute name to overridden ClinicalAttributeMetadata object\n HashMap<String, Map<String,ClinicalAttributeMetadata>> latestOverridesCache = new HashMap<String, Map<String, ClinicalAttributeMetadata>>();\n for (Map.Entry<String, ArrayList<ClinicalAttributeMetadata>> entry : latestOverrides.entrySet()) {\n HashMap<String, ClinicalAttributeMetadata> clinicalAttributesMetadataMapping = new HashMap<String, ClinicalAttributeMetadata>();\n for (ClinicalAttributeMetadata clinicalAttributeMetadata : entry.getValue()) {\n fillOverrideAttributeWithDefaultValues(clinicalAttributeMetadata, latestClinicalAttributeMetadataCache.get(clinicalAttributeMetadata.getColumnHeader()));\n clinicalAttributesMetadataMapping.put(clinicalAttributeMetadata.getColumnHeader(), clinicalAttributeMetadata);\n }\n latestOverridesCache.put(entry.getKey(), clinicalAttributesMetadataMapping);\n }\n\n clinicalAttributeCache = latestClinicalAttributeMetadataCache;\n logger.info(\"resetCache(): refilled cache with \" + latestClinicalAttributeMetadata.size() + \" clinical attributes\");\n overridesCache = latestOverridesCache;\n logger.info(\"resetCache(): refilled overrides cache with \" + latestOverrides.size() + \" overrides\");\n\n if (failedClinicalAttributeMetadataCacheRefresh || failedOverridesCacheRefresh) {\n logger.info(\"Unable to update cache with latest data from TopBraid... falling back on EHCache store.\");\n throw new FailedCacheRefreshException(\"Failed to refresh cache\", new Exception());\n } else {\n dateOfLastCacheRefresh = dateOfCurrentCacheRefresh;\n logger.info(\"resetCache(): cache last refreshed on: \" + dateOfLastCacheRefresh.toString());\n }\n }",
"public InMemoryServiceInstancePersistence() {\n this.serviceInstances = new HashMap<>(); \n }",
"public static void loadCache() {\n\t\t // it is the temporary replacement to database. We should use DB instead\n\t Circle circle = new Circle();\n\t circle.setId(\"1\");\n\t shapeMap.put(circle.getId(),circle);\n\n\t Square square = new Square();\n\t square.setId(\"2\");\n\t shapeMap.put(square.getId(),square);\n\n\t Rectangle rectangle = new Rectangle();\n\t rectangle.setId(\"3\");\n\t \n\t Circle circle2 = new Circle();\n\t circle2.setId(\"4\");\n\t circle2.setType(\"Big Circle\");\n\t shapeMap.put(circle2.getId(),circle2);\n\t shapeMap.put(rectangle.getId(), rectangle);\n\t }",
"public interface Cache {\n void put(String key, Object value);\n\n Object get(String key);\n}",
"protected void createLookupCache() {\n }",
"private static void secondLevelCacheWithoutSettingAttrInXML() {\n\t\ttry(Session session = HbUtil.getSession()){\n\t\t\tBook b = session.get(Book.class, 11);\n\t\t\tSystem.out.println(\"Book details : \\n\" + b);\n\t\t}catch(Exception ex) {\n\t\t\tex.printStackTrace();\n\t\t}\n\t\t\n\t\ttry(Session session = HbUtil.getSession()){\n\t\t\tBook b = session.get(Book.class, 11);\n\t\t\tSystem.out.println(\"Book details : \\n\" + b);\n\t\t}catch(Exception ex) {\n\t\t\tex.printStackTrace();\n\t\t}\n\t}",
"public interface OrganizationService extends EntityService<Organization> {\n\n /**\n * 缓存\n *\n * @param id\n * @return\n * @throws Exception\n */\n public Organization queryCacheOrganizationById(long id) throws Exception;\n}",
"public boolean useCache() {\n return !pathRepositoryCache.isEmpty();\n }",
"private static boolean assetInfoIsInPersistentCache(Asset asset) {\n \t\treturn getAssetInfoFile(asset.getId()).exists();\n \t}",
"protected net.sf.ehcache.Ehcache getCache() {\n return cache;\n }",
"private static File createReserveDiskCacheDir(Context context) {\n\t\tFile cacheDir = StorageUtils.getCacheDirectory(context, false);\n\t\tFile individualDir = new File(cacheDir, \"lazy-cache\");\n\t\tif (individualDir.exists() || individualDir.mkdir()) {\n\t\t\tcacheDir = individualDir;\n\t\t}\n\t\treturn cacheDir;\n\t}",
"@Test\n public void testCompact_Last_Segment_Caching_Enabled() throws Exception {\n\n File file = new File(System.getProperty(\"java.io.tmpdir\") + File.separator\n + \"oasis-collection-testCompact_Last_Segment_Caching_Enabled\");\n file.mkdirs();\n file.deleteOnExit();\n\n SegmentedOasisList<Integer> instance = new SegmentedOasisList<>(2, 2, file);\n Collection c = Arrays.asList(1, 1, 7, 7, 1, 1, 1, 1);\n instance.enableCache();\n instance.addAll(c);\n\n instance.remove(7);\n instance.disableCache();\n\n assertNumberFilesInDirectory(instance.instanceStore(), 2);\n\n }",
"@Override\n\tpublic boolean isCaching() {\n\t\treturn false;\n\t}",
"public void cacheBusRouteData()\n\t{\t\n\t\tdataMap = BusRouteDataFileReader.readAndCacheBusRouteData(this.pathname);\n\t}",
"public void saveState() {\n\t\tFileOutputStream fos = null;\n\t\tObjectOutputStream out = null;\n\t\ttry {\n\t\t\tFile savefile = new File(getServletContext().getRealPath(\"/WEB-INF/\"), SAVED_RECEPTOR_FILE_NAME);\n\t\t\tfos = new FileOutputStream(savefile);\n\t\t\tout = new ObjectOutputStream(fos);\n\t\t\tout.writeObject(pgtMap);\n\t\t\tout.close();\n\t\t} catch (IOException ex) {\n\t\t\tSystem.err.println(\"IO Exception saving proxyTicket cache\");\n\t\t\tex.printStackTrace();\n\t\t} catch (Exception e) { //don't think this is possible, but I'm seeing some goofy behavior, so...\n\t\t\tSystem.err.println(\"Non-IO Exception saving proxyTicket cache\");\n\t\t\te.printStackTrace();\n\t\t}\n\t}",
"public void cache(){\n\t\t\n\t\t/*\n\t\t * second, check if there is a cache file\n\t\t * if yes, then check date\n\t\t * if no, then create a cache file \n\t\t*/\n\t\tif(cacheExist()){\n\t\t\t//check date and decide which file to update\n\t\t\tSystem.out.println(\" hahahaha, cache already there! \");\n\t\t\t\n\t\t\tFile cache = new File(\"./cache.txt\");\n\t\t\tsource = readFile(\"./cache.txt\",source);\n\t\t\tSystem.out.println(\"the size of source hashmap : \"+ source.size());\n\t\t\t\n\t\t\tfor(int i = 1; i < fileList.length;i++){\n\t\t\t\t//if this file need to be updated, write the data to source array\n\t\t\t\tif(needToUpdate(fileList[i], cache)){\n\t\t\t\t\tSimpleDateFormat sdf = new SimpleDateFormat(\"MM/dd/yyyy HH:mm:ss\");\n\t\t\t\t\tSystem.out.println(\"S: \"+ sdf.format(fileList[i].lastModified()) + \" c: \"+ sdf.format(cache.lastModified()));\n\t\t\t\t\tsource = readFile(fileList[i].getPath(), source);\n\t\t\t\t}\n\t\t\t}\n\t\t\t//after checking the whole source file and add the new data to source array\n\t\t\t//then sort the source array and write it to cache\n\t\t\tsort(source);\n\t\t\ttry\n\t\t\t{\n\t\t\t String filename= \"./cache.txt\";\n\t\t\t FileWriter fw = new FileWriter(filename,true); //the true will append the new data\n\t\t\t for(int j = 0; j < writeList.size(); j++){\n\t\t\t\t\tfw.write(writeList.get(j));\n\t\t\t\t}\n\t\t\t fw.close();\n\t\t\t}\n\t\t\tcatch(IOException ioe)\n\t\t\t{\n\t\t\t System.err.println(\"IOException: \" + ioe.getMessage());\n\t\t\t}\n\t\t\t\t\n\t\t}\n\t\t//there are is no cache, need to create a cache file\n\t\telse{\n\t\t\tSystem.out.println(\" create new cache file !\");\n\t\t\t//create cache file and copy sort the data from source file\n\t\t\t//1. read all the source file and store the data to an arrayList\n\t\t\tfor(int i = 1; i < fileList.length; i++){\n\t\t\t\tsource = readFile(fileList[i].getPath(), source);\t\t\t\n\t\t\t}\n\t\t\tsort(source);\n//\t\t\tSystem.out.println(source);\n\t\t\t\n\t\t\t//2.write the data to the cache file\n\t\t\tPrintWriter writer;\n\t\t\ttry {\n\t\t\t\twriter = new PrintWriter(\"cache.txt\", \"UTF-8\");\t\t\t\n\t\t\t\twriter.println(writeList.size());\n\t\t\t\tfor(int j = 0; j < writeList.size(); j++){\n\t\t\t\t\twriter.println(writeList.get(j));\n\t\t\t\t}\n\t\t\t\twriter.close();\n\t\t\t\t\n\t\t\t} catch (FileNotFoundException e) {\n\t\t\t\t// TODO Auto-generated catch block\n\t\t\t\te.printStackTrace();\n\t\t\t} catch (UnsupportedEncodingException e) {\n\t\t\t\t// TODO Auto-generated catch block\n\t\t\t\te.printStackTrace();\n\t\t\t}\n\t\t\t\n\t\t}\n\t\t \n\t\t\n\t}",
"private void putInCacheDirty(Module module) throws NoStorageForModuleException, StorageFailureException{\n\t\tputInCache(module);\n\t\tIModuleStorage storage = storages.get(module.getId());\n\t\tif (storage==null){\n\t\t\tLOGGER.warn(\"No storage for \" + module.getId() + \", \" + module + \" is not persistent!\");\n\t\t\tthrow new NoStorageForModuleException(module.getId());\n\t\t}\n\t\tstorage.saveModule(module);\n\t}",
"public abstract int getPersistence();",
"OStorage getStorage();",
"public void refreshObjectCache();",
"int saveCached(String fileName) throws IOException\n\t {\n\t\t File f = new File (fileName);\n\t\t \n\t\t\t\tif (f.exists())\n\t\t\t\t{\n\t\t\t\t\tSystem.out.println(\"ATTENTION!!! File \" +fileName+ \" already exists. Adding new records to it.\");\n\t\t\t\t\tFileWriter fw = new FileWriter (f, true);\n\t\t\t\t\tPrintWriter pwx = new PrintWriter (fw);\n\t\t\t\t\tBufferedReader brx = new BufferedReader(new FileReader (\".cache\"));\n\t\t\t\t\t \n\t\t\t\t\t String lineX = brx.readLine();\n\t\t\t\t\t \n\t\t\t\t\t while (lineX != null)\n\t\t\t\t\t {\n\t\t\t\t\t\t pwx.println(lineX);\n\t\t\t\t\t\t lineX=brx.readLine();\n\t\t\t\t\t }\n\t\t\t\t\t brx.close();\n\t\t\t\t\t pwx.flush();\n\t\t\t\t\t pwx.close();\n\t\t\t\t\t \n\t\t\t\t\t return 0;\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\tf.createNewFile();\n\t\t\t\t}\n\t\t \n\t\t \n\t\t PrintWriter pn = new PrintWriter (fileName);\n\t\t BufferedReader br = new BufferedReader(new FileReader (\".cache\"));\n\t\t \n\t\t String line = br.readLine();\n\t\t \n\t\t while (line != null)\n\t\t {\n\t\t\t pn.println(line);\n\t\t\t line=br.readLine();\n\t\t }\n\t\t pn.flush();\n\t\t br.close();\n\t\t pn.close();\n\t\t System.out.println(\"Your file was saved as follows\");\n\t\t FileManager fm = new FileManager();\n\t\t fm.show(fileName);\n\t\treturn 1;\n\t }",
"public void storeInCache() {\r\n lockValueStored = IN_CACHE;\r\n }",
"public interface DistributeStorage<T> {\n public void store(String path, T t, boolean create) throws StorageException;\n\n public T get(String path, Class<T> tClass) throws StorageException;\n\n public void del(String path) throws StorageException;\n\n public boolean exist(String path) throws StorageException;\n}",
"@Override\n public CacheAPI getCacheAPI() {\n return null;\n }",
"public interface ContentCache extends DataCache {\r\n String getValue(String code, Locale locale);\r\n\r\n Boolean containsLocale(Locale locale);\r\n\r\n Boolean containsCodeForLocale(String code, Locale locale);\r\n\r\n Map<String, Map<String, String>> getCachedData();\r\n}",
"private void cacheFoldersFiles() throws Exception {\n\n ArrayList<FileManagerFile> files = new ArrayList<FileManagerFile>();\n if (fileCount > 0) {\n SimpleDateFormat formatter = new SimpleDateFormat(\"yyyy-MM-dd'T'HH:mm:ss\");\n formatter.setTimeZone(TimeZone.getTimeZone(\"GMT\"));\n\n int offset = 0;\n int count = 1000;\n List<FileManagerFile> filelist;\n\n do {\n filelist = connection.getFileManager().getFileManagerFiles(count, offset);\n offset += count;\n for (FileManagerFile file : filelist) {\n if (file.getFolderId() == id) {\n files.add(file);\n }\n }\n } while (filelist.size() > 0 && files.size() < fileCount);\n }\n this.files = files;\n }",
"protected abstract Collection<Cache> loadCaches();",
"public interface ContentCache extends Cache<List<byte[]>>{\n int notCacheSize();\n}",
"public Object createEntry(Object key) throws Exception {\n\r\n\t\t\r\n\t\t\r\n\t\tConnection connect = null;\r\n\t Statement st = null;\r\n\t ResultSet rs = null;\r\n\t String url = \"jdbc:mysql://localhost:3306/\";\r\n\t String db = \"ehcache\";\r\n\t String driver = \"com.mysql.jdbc.Driver\";\r\n\t String user = \"ehcache\";\r\n\t String pass = \"terracotta\";\r\n\t customer mc = new customer();\r\n\t \r\n\t\ttry {\r\n\t\t\t\r\n\t\t\tClass.forName(driver);\r\n\t\t\tconnect = DriverManager\r\n\t\t\t .getConnection(url + db, user, pass);\r\n\t\t\t\r\n\t\t\tst = connect.createStatement();\r\n\t\t rs = st.executeQuery(\"select * from customers where ID='\" + key + \"'\");\r\n\t\t // rs = st.executeQuery(\"select * from customers where ID='1'\");\r\n\t\t \r\n\t\t System.out.println(\"(dbReadThrough) Retrieving customer \" + key + \" from DB ... \");\r\n\t\t \r\n\t\t while (rs.next()) {\r\n\t\t \t\r\n\t\t \t\r\n\t\t \tint ID = rs.getInt(\"ID\");\r\n\t\t \tString FIRSTNAME = rs.getString(\"FIRSTNAME\");\r\n\t\t \tString LASTNAME = rs.getString(\"LASTNAME\");\r\n\t\t \tString REGION = rs.getString(\"REGION\");\r\n\t\t \tString ADDRESS = rs.getString(\"ADDRESS\");\r\n\t\t \r\n\t\t \tSystem.out.println(\"(dbReadThrough) Found customer: \" + ID + \" -- \" + FIRSTNAME + \" \" + LASTNAME + \" \" + REGION + \" \" + ADDRESS);\r\n\t\t \t\t\t \t\r\n\t \t\tmc.setID(ID);\r\n\t \t\tmc.setFIRSTNAME(FIRSTNAME);\r\n\t \t\tmc.setLASTNAME(LASTNAME);\r\n\t \t\tmc.setREGION(REGION);\r\n\t \t\tmc.setADDRESS(ADDRESS); \t\r\n\t\t \t\t\t \t\r\n\t\t }\r\n\t\t \r\n\t\t System.out.println(\"(dbReadThrough) Writing object for customer \" + key + \" to the cache ... \");\r\n\t return mc;\r\n\t\t\r\n\t\t} finally {\r\n\t\t\tconnect.close();\r\n\t\t}\r\n\r\n\t}",
"public EhcacheSessionDataStorage() {\n this(SESSION_NAME);\n }",
"private static void loadCache(IgniteCache<Long, Person> cache) {\n long start = System.currentTimeMillis();\n\n // Start loading cache from persistent store on all caching nodes.\n cache.loadCache(null, ENTRY_COUNT);\n\n long end = System.currentTimeMillis();\n\n System.out.println(\">>> Loaded \" + cache.size() + \" keys with backups in \" + (end - start) + \"ms.\");\n }",
"protected void trunkStore() {\n LOG.info(\"Trunking state filestore: {}\", fileStore);\n FileOutputStream fos = null;\n try {\n fos = new FileOutputStream(fileStore);\n for (Map.Entry<String, String> entry : cache.entrySet()) {\n fos.write(entry.getKey().getBytes());\n fos.write(KEY_VALUE_DELIMITER.getBytes());\n fos.write(entry.getValue().getBytes());\n fos.write(STORE_DELIMITER.getBytes());\n }\n } catch (IOException e) {\n throw RuntimeCamelException.wrapRuntimeCamelException(e);\n } finally {\n IOHelper.close(fos, \"Trunking file state repository\", LOG);\n }\n }",
"public DBMaker enableHardCache() {\n cacheType = DBCacheRef.HARD;\n return this;\n }",
"private static void secondLevelCacheWithSettingAttrInXML() {\n\t\ttry(Session session = HbUtil.getSession()){\n\t\t\tBook b = session.get(Book.class, 11);\n\t\t\tSystem.out.println(\"Book details : \\n\" + b);\n\t\t}catch(Exception ex) {\n\t\t\tex.printStackTrace();\n\t\t}\n\t\t\n\t\ttry(Session session = HbUtil.getSession()){\n\t\t\tBook b = session.get(Book.class, 11);\n\t\t\tSystem.out.println(\"Book details : \\n\" + b);\n\t\t}catch(Exception ex) {\n\t\t\tex.printStackTrace();\n\t\t}\n\t}",
"private static void firstLevelCacheWithGetAndLoad(Session session) {\n\t\tsession.beginTransaction();\n\t\tBook b = session.get(Book.class, 11);\n\t\tSystem.out.println(\"Book details : \\n\" + b);\n\t\tSystem.out.println(\"ID : \" + b.getId());\n\t\tSystem.out.println(\"NAME : \" + b.getName());\n\t\tSystem.out.println(b.getClass().getName());\n\n\t\tBook b1 = session.load(Book.class, 12);\n\t\tSystem.out.println(\"Book details : \\n\" + b1);\n\t\tSystem.out.println(\"ID : \" + b1.getId());\n\t\tSystem.out.println(\"NAME : \" + b1.getName());\n\t\tSystem.out.println(b1.getClass().getName());\n\t}",
"void cache(String key, T value) throws IOException;",
"@Override\n\tpublic int getSizeToCache() {\n\t\treturn 0;\n\t}",
"protected void createLookupCache()\n/* */ {\n/* 1260 */ this.lookup = new SimpleCache(1, Math.max(getSize() * 2, 64));\n/* */ }",
"public interface Cache<K,V> {\n\t/**\n\t * Returns the object for the given id from cache, null if no object is in cache.\n\t *\n\t * @param id the id to retrieve\n\t * @return a V object.\n\t */\n\tV get(K id);\n\t\n\t/**\n\t * Puts the cacheable object in cache.\n\t *\n\t * @param id the object id\n\t * @param cacheable the object to cache.\n\t */\n\tvoid put(K id, V cacheable);\n\n\t/**\n\t * Removes an object from the cache.\n\t *\n\t * @param id cache object id.\n\t */\n\tvoid remove(K id);\n\t\n\t/**\n\t * Clears the cache.\n\t */\n\tvoid clear();\n\n\t/**\n\t * Returns the cache stats.\n\t *\n\t * @return a {@link net.anotheria.moskito.core.predefined.CacheStats} object.\n\t */\n\tCacheStats getCacheStats();\n\n /**\n * Return all elements from cache.\n *\n * @return collection\n */\n Collection<V> getAllElements();\n\t\n}",
"public boolean existCache() {\n return false;\n }",
"public boolean isInMemory();",
"@Test\n public void testGetElementJavaPerfTest() throws Exception {\n\n Status somethingThatIsSerializable = Status.STATUS_ALIVE;\n byte[] serializedForm = MemoryEfficientByteArrayOutputStream.serialize(somethingThatIsSerializable).getBytes();\n\n assertEquals(404, HttpUtil.get(\"http://localhost:9090/ehcache/rest/sampleCache2/1\").getResponseCode());\n\n net.sf.ehcache.server.soap.jaxws.Element element = new net.sf.ehcache.server.soap.jaxws.Element();\n element.setKey(\"1\");\n element.setValue(serializedForm);\n cacheService.put(\"sampleCache2\", element);\n\n long begin = System.currentTimeMillis();\n for (int i = 0; i < 100; i++) {\n HttpURLConnection urlConnection = HttpUtil.get(\"http://localhost:9090/ehcache/rest/sampleCache2/1\");\n assertEquals(200, urlConnection.getResponseCode());\n }\n long end = System.currentTimeMillis();\n LOG.info(\"Get time: \" + (end - begin) / 100f);\n }",
"private static byte[] m2539e(Context context) {\n Throwable th;\n int i = 0;\n ByteArrayOutputStream byteArrayOutputStream = new ByteArrayOutputStream();\n byte[] bArr = new byte[0];\n String a = Log.m2547a(context, Log.f1857e);\n DiskLruCache diskLruCache = null;\n try {\n diskLruCache = DiskLruCache.m2767a(new File(a), 1, 1, 10240);\n File file = new File(a);\n if (file != null && file.exists()) {\n String[] list = file.list();\n int length = list.length;\n while (i < length) {\n String str = list[i];\n if (str.contains(\".0\")) {\n byteArrayOutputStream.write(StatisticsManager.m2535a(diskLruCache, str.split(\"\\\\.\")[0]));\n }\n i++;\n }\n }\n bArr = byteArrayOutputStream.toByteArray();\n if (byteArrayOutputStream != null) {\n try {\n byteArrayOutputStream.close();\n } catch (IOException e) {\n e.printStackTrace();\n }\n }\n if (diskLruCache != null) {\n try {\n diskLruCache.close();\n } catch (Throwable th2) {\n th = th2;\n }\n }\n } catch (IOException th3) {\n BasicLogHandler.m2542a(th3, \"StatisticsManager\", \"getContent\");\n if (byteArrayOutputStream != null) {\n try {\n byteArrayOutputStream.close();\n } catch (IOException e2) {\n e2.printStackTrace();\n }\n }\n if (diskLruCache != null) {\n diskLruCache.close();\n }\n } catch (Throwable th4) {\n th3 = th4;\n }\n return bArr;\n th3.printStackTrace();\n return bArr;\n }",
"public static <T extends Entity> EntityCache<T> getMemoryEntityCache() {\n\t\tEntityMap<T> entityMap = new MemoryEntityMap<T>();\n\t\treturn new EntityCache<T>(entityMap);\n\t}",
"public void store() throws PersistenceException {\n }",
"public interface ContentService extends KekeinfoEntityService<Long, Content>\n \n{\n\n\tpublic List<Content> listByType( String contentType)\n\t throws ServiceException;\n\n /**\n * Method responsible for storing content file for given Store.Files for given merchant store will be stored in\n * Infinispan.\n * \n * @param merchantStoreCode merchant store whose content images are being saved.\n * @param contentFile content image being stored\n * @throws ServiceException\n */\n void addContentFile(InputContentFile contentFile )\n throws ServiceException;\n\n \n /**\n * Method responsible for storing list of content image for given Store.Images for given merchant store will be stored in\n * Infinispan.\n * \n * @param merchantStoreCode merchant store whose content images are being saved.\n * @param contentImagesList list of content images being stored.\n * @throws ServiceException\n */\n void addContentFiles(List<InputContentFile> contentFilesList) throws ServiceException;\n \n \n /**\n * Method to remove given content image.Images are stored in underlying system based on there name.\n * Name will be used to search given image for removal\n * @param imageContentType\n * @param imageName\n * @param merchantStoreCode merchant store code\n * @throws ServiceException\n */\n public void removeFile(FileContentType fileContentType, String fileName) throws ServiceException;\n \n \n /**\n * Method to remove all images for a given merchant.It will take merchant store as an input and will\n * remove all images associated with given merchant store.\n * \n * @param merchantStoreCode\n * @throws ServiceException\n */\n public void removeFiles() throws ServiceException;\n \n /**\n * Method responsible for fetching particular content image for a given merchant store. Requested image will be\n * search in Infinispan tree cache and OutputContentImage will be sent, in case no image is found null will\n * returned.\n * \n * @param merchantStoreCode\n * @param imageName\n * @return {@link OutputContentImage}\n * @throws ServiceException\n */\n public OutputContentFile getContentFile(FileContentType fileContentType, String fileName )\n throws ServiceException;\n \n public InputStream getContentFileInputstream(FileContentType fileContentType, String fileName )\n throws ServiceException;\n \n \n /**\n * Method to get list of all images associated with a given merchant store.In case of no image method will return an empty list.\n * @param merchantStoreCode\n * @param imageContentType\n * @return list of {@link OutputContentImage}\n * @throws ServiceException\n */\n public List<OutputContentFile> getContentFiles(FileContentType fileContentType )\n throws ServiceException;\n\n\t\n List<String> getContentFilesNames(\n\t\t\tFileContentType fileContentType) throws ServiceException;\n\n /**\n * Add the store logo\n * @param merchantStoreCode\n * @param cmsContentImage\n * @throws ServiceException\n */\n\tvoid addLogo(InputContentFile cmsContentImage)\n\t\t\tthrows ServiceException;\n\n\t/**\n\t * Adds a property (option) image\n\t * @param merchantStoreId\n\t * @param cmsContentImage\n\t * @throws ServiceException\n\t */\n\tvoid addOptionImage(InputContentFile cmsContentImage)\n\t\t\tthrows ServiceException;\n\n\t\n\n}",
"protected void loadStore() throws IOException {\n // auto create starting directory if needed\n if (!fileStore.exists()) {\n LOG.debug(\"Creating filestore: {}\", fileStore);\n File parent = fileStore.getParentFile();\n if (parent != null && !parent.exists()) {\n boolean mkdirsResult = parent.mkdirs();\n if (!mkdirsResult) {\n LOG.warn(\"Cannot create the filestore directory at: {}\", parent);\n }\n }\n boolean created = FileUtil.createNewFile(fileStore);\n if (!created) {\n throw new IOException(\"Cannot create filestore: \" + fileStore);\n }\n }\n\n LOG.trace(\"Loading to 1st level cache from state filestore: {}\", fileStore);\n\n cache.clear();\n try (Scanner scanner = new Scanner(fileStore, null, STORE_DELIMITER)) {\n while (scanner.hasNext()) {\n String line = scanner.next();\n int separatorIndex = line.indexOf(KEY_VALUE_DELIMITER);\n String key = line.substring(0, separatorIndex);\n String value = line.substring(separatorIndex + KEY_VALUE_DELIMITER.length());\n cache.put(key, value);\n }\n } catch (IOException e) {\n throw RuntimeCamelException.wrapRuntimeCamelException(e);\n }\n\n LOG.debug(\"Loaded {} to the 1st level cache from state filestore: {}\", cache.size(), fileStore);\n }",
"public abstract FHIRPersistence getPersistenceImpl() throws Exception;",
"public byte[] cache(byte[] contents) {\r\n\t\tif (contents == null)\r\n\t\t\treturn null;\r\n\t\tByteArray ba = new ByteArray(contents);\r\n\t\tcache.putIfAbsent(ba, ba.contents);\r\n\t\treturn cache.get(ba);\r\n\t}",
"public void loadCache() {\r\n\t\tint rango = getEmpleadoActual().getRango();\r\n\t\tArrayList<String> idsDptos = getEmpleadoActual().getDepartamentosId();\r\n\t\t\r\n\t\t// Para todos los departamentos a los que pertenezca el empleado\r\n\t\tfor (int nd=0; nd<idsDptos.size(); nd++){\r\n\t\t\tString dep = idsDptos.get(nd);\r\n\t\t\tint numvendedor = getEmpleadoActual().getEmplId();\r\n\r\n\t\t\tif (!alive) return;\r\n\t\t\tsetProgreso(\"Cargando contratos dpto \"+dep, 50);\r\n\t\t\tcontratos = controlador.getListaContratosDpto(dep);\r\n\t\t\tsetProgreso(\"Cargando contratos dpto \"+dep, 100);\r\n\r\n\t\t\tif (!alive) return;\r\n\t\t\tsetProgreso(\"Cargando empleados dpto \"+dep, 25);\r\n\t\t\templeados = controlador.getEmpleadosDepartamento(getEmpleadoActual().getEmplId(),dep);\r\n\t\t\tsetProgreso(\"Cargando empleados dpto \"+dep, 100);\r\n\t\t\t\r\n\t\t\t//Prueba ordenación empleados\r\n//\t\t\tfor (int i = 0; i < empleados.size(); i++) {\r\n//\t\t\t\tSystem.out.println(empleados.get(i).getPosicion());\r\n//\t\t\t}\r\n\t\t\tordenaEmpleados();\r\n//\t\t\tfor (int i = 0; i < empleados.size(); i++) {\r\n//\t\t\t\tSystem.out.println(empleados.get(i).getPosicion());\r\n//\t\t\t}\r\n\t\t\t//Fin PRueba\r\n\t\t\t\r\n\t\t\t\r\n\t\t\tif (!alive) return;\r\n\t\t\tif (rango == 1) { // Si es un empleado, coger turnos de su departamento\r\n\t\t\t\tsetProgreso(\"Cargando turnos dpto \"+dep, 70);\r\n\t\t\t\tturnos = controlador.getListaTurnosEmpleadosDpto(dep);\r\n\t\t\t\tsetProgreso(\"Cargando turnos dpto \"+dep, 100);\r\n\t\t\t} else if (rango == 2) { // Si es un jefe, coger turnos de todos los departamentos\r\n\t\t\t\tArrayList<String> temp = new ArrayList<String>();\r\n\t\t\t\ttemp = controlador.getDepartamentosJefe(numvendedor);\r\n\t\t\t\tfor (int i=0; i<temp.size(); i++)\r\n\t\t\t\t\tdepartamentosJefe.add(controlador.getDepartamento(temp.get(i)));\r\n\t\t\t\t//TODO borrar si al final no se usa\r\n\t//\t\t\tsetProgreso(\"Cargando jefes de departamento\", 60);\r\n\t//\t\t\tnumeroJefesDepartamento = controlador.getNumVendedorTodosJefes();\r\n\t//\t\t\tnombreJefesDepartamento = controlador.getNombreTodosJefes();\r\n\t\t\t\tsetProgreso(\"Cargando turnos dpto \"+dep, 70);\r\n\t\t\t\tArrayList<Turno> turnosDep = new ArrayList<Turno>();\r\n\t\t\t\tfor (int i=0; i<departamentosJefe.size(); i++) {\r\n\t\t\t\t\tturnosDep = controlador.getListaTurnosEmpleadosDpto(departamentosJefe.get(i).getNombreDepartamento());\r\n\t\t\t\t\tfor (int j=0; j<turnosDep.size(); j++) {\r\n\t\t\t\t\t\tturnos.add(turnosDep.get(j));\r\n\t\t\t\t\t}\t\t\t\t\r\n\t\t\t\t}\r\n\t\t\t\tsetProgreso(\"Cargando turnos dpto \"+dep, 100);\r\n\t\t\t\t\r\n\t\t\t} else {\r\n\t\t\t\tSystem.err.println(\"Vista\\t:: Tipo de empleado inválido para cargar la cache.\");\r\n\t\t\t}\r\n\t\t}\r\n\t\tif(rango==1){//si es un empleado guardamos las ventas que éste ha hecho en un año\r\n\t\t\tjava.util.Date fecha = new java.util.Date();//cogemos la fecha del sistema\r\n\t\t\tvector_ventas=controlador.getVentas(this.getEmpleadoActual().getEmplId(),fecha.getYear()+1900);\r\n\t\t}else if(rango==2){//si es un jefe almacenamos la suma de las ventas de todos los empleados de este departamento durante un año\r\n\t\t\tjava.util.Date fecha = new java.util.Date();//cogemos la fecha del sistema\r\n\t\t\tvector_ventas=controlador.getVentasJefe(this.empleados,fecha.getYear()+1900);\r\n\t\t}\r\n\t\tSystem.out.println(\"Cache cargada\");\r\n\t}",
"@Override\n\tpublic long getCacheSize() {\n\t\treturn 0;\n\t}",
"@Override\r\n\tpublic File getCacheDir() {\r\n\t\treturn CommonUtil.getCacheDir();\r\n\t}",
"public void loadPersistencePreferences() {\n SharedPreferences sharedPreferences = PreferenceManager.getDefaultSharedPreferences(this);\n boolean persistent = sharedPreferences.getBoolean(\"TileCachePersistence\", true);\n Log.v(TAG, \"Cache Size: \" + sharedPreferences.getInt(\"TileCacheSize\", MapsActivity.FILE_SYSTEM_CACHE_SIZE_DEFAULT)\n + \", Persistent: \" + persistent);\n int capacity = Math.min(sharedPreferences.getInt(\"TileCacheSize\", MapsActivity.FILE_SYSTEM_CACHE_SIZE_DEFAULT),\n MapsActivity.FILE_SYSTEM_CACHE_SIZE_MAX);\n TileCache fileSystemTileCache = this.mapView.getFileSystemTileCache();\n\n fileSystemTileCache.setPersistent(persistent);\n fileSystemTileCache.setCapacity(capacity);\n // text size\n String textScaleDefault = getString(R.string.preferences_text_scale_default);\n this.mapView.setTextScale(Float.parseFloat(sharedPreferences.getString(\"mapTextScale\", textScaleDefault)));\n }",
"public void cacheResult(DataEntry dataEntry);",
"public final StorageType mo102949f() {\n return StorageType.CACHE;\n }",
"public interface TaskCache {\n /**\n * Gets an {@link Object} which will emit a {@link TaskEntity}.\n *\n * @param userId The id used to get data.\n */\n List<TaskEntity> get(int userId);\n\n /**\n * Puts and element into the cache.\n *\n * @param userEntity The task data to save.\n */\n void put(TaskEntity userEntity);\n\n /**\n * Checks if an element (User) exists in the cache.\n *\n * @param userId The id used to get data.\n * @return true if the element is cached, otherwise false.\n */\n boolean isCached(int userId);\n\n /**\n * Checks if the cache is expired.\n * @param userId The id used to get data.\n * @return true, the cache is expired, otherwise false.\n */\n boolean isExpired(int userId);\n\n /**\n * Evict all elements of the cache.\n *\n * @param userId The id used to get data.\n */\n void evictAll(int userId);\n\n /**\n * Change task status\n *\n * @param idTask task to update.\n */\n void refresh(int idTask);\n}",
"public HWDiskStore() {\n this.diskStore = new oshi.hardware.HWDiskStore();\n }",
"public void setCached() {\n }",
"protected void putDatabaseQueryCache(String key, String value) {\n\t\t\n\t\tSession session = this.openSession();\n\t\tsession.beginTransaction();\n\t\tsession.save( new Metainfo( key, value ) );\n\t\tsession.getTransaction().commit();\n\t\tsession.close();\n\t}",
"protected void cacheLoadThroughSubjects()\n {\n }",
"public EhcacheSessionDataStorage(Cache cache) {\n this.sessions = cache;\n }",
"public interface RedisCacheService {\n void put(Object key , Object value);\n Object get(Object key);\n}"
] | [
"0.6675296",
"0.6306861",
"0.6142158",
"0.60705817",
"0.60407835",
"0.60363287",
"0.59568715",
"0.591609",
"0.5913606",
"0.58945173",
"0.586976",
"0.5844972",
"0.5842033",
"0.58263165",
"0.579463",
"0.5792106",
"0.57697535",
"0.57622814",
"0.57576483",
"0.5716762",
"0.57049775",
"0.5697552",
"0.5688849",
"0.56816125",
"0.56813055",
"0.5678778",
"0.56760865",
"0.5667876",
"0.5658687",
"0.56541103",
"0.5654087",
"0.5644518",
"0.5642128",
"0.5641215",
"0.56306565",
"0.5627797",
"0.56201375",
"0.5617781",
"0.5613377",
"0.5591682",
"0.5578886",
"0.5566574",
"0.55588084",
"0.5558344",
"0.5555225",
"0.5550611",
"0.5530268",
"0.5511071",
"0.5509591",
"0.5506055",
"0.5503229",
"0.55026996",
"0.549753",
"0.5488589",
"0.5475283",
"0.54746383",
"0.5472701",
"0.5471496",
"0.54710674",
"0.54618996",
"0.54573077",
"0.5449393",
"0.5444987",
"0.5443972",
"0.5443587",
"0.5425449",
"0.5424111",
"0.54215723",
"0.54190874",
"0.5418392",
"0.541621",
"0.54157084",
"0.5415315",
"0.5415224",
"0.5413837",
"0.5412928",
"0.540572",
"0.5402861",
"0.5400718",
"0.53997046",
"0.53968817",
"0.539272",
"0.53911936",
"0.538924",
"0.53808933",
"0.537536",
"0.5375246",
"0.53745407",
"0.5373361",
"0.5364827",
"0.5362713",
"0.5356508",
"0.5352669",
"0.5348947",
"0.5347663",
"0.53469956",
"0.5346262",
"0.5342396",
"0.53422236",
"0.5341554",
"0.5340423"
] | 0.0 | -1 |
course name for this GradeBook constructor initializes courseName with String supplied as argument | public GradeBook4( String name )
{
courseName = name; // initializes courseName
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public Course(String courseName) {\n this.courseName = courseName;\n }",
"public GradeBook2( String name )\n {\n courseName = name; // initializes courseName\n }",
"public GradeBook (String name){ //Constructor\n\t\tcourseName=name;\n//\t\tstudents = studentNum;\n\t}",
"public void setCourseName(String courseName) {\n this.courseName = courseName;\n }",
"public void setCourseName(String courseName) {\n this.courseName = courseName;\n }",
"public void setCourseName(String courseName) {\n this.courseName = courseName;\n }",
"public void setCourseName(String courseName) {\n this.courseName = courseName;\n }",
"public Course(String courseName) {\n studentList = new ArrayList<Student>(MAXSTUDENT);\n this.courseName = courseName;\n studentCount = 0;\n }",
"public void setCourseName( String name )\n\t{\n\t\tcourseName = name;\t// store the course name\n\t}",
"public void setCourseName(String courseName) {\n\t\tCourseName = courseName;\n\t}",
"public void setCourseName(String name){//setCourseName body start\n\t\tCourseName = name;\n\t}",
"public Builder setCourseName(java.lang.String value) {\n\t\t\t\tif (value == null) {\n\t\t\t\t\tthrow new NullPointerException();\n\t\t\t\t}\n\n\t\t\t\tcourseName_ = value;\n\t\t\t\tonChanged();\n\t\t\t\treturn this;\n\t\t\t}",
"public void setCourseName(String courseName) {\n this.courseName = courseName == null ? null : courseName.trim();\n }",
"public void setCourseName (String courseName)\n\t{\n\t\tif(courseName.length ( )==0 || courseName==null)\n\t\t{\n\t\t\tcourseName=\"Course Name\";\n\t\t}\n\t\tthis.courseName = courseName;\n\t\tthis.saveNeed = true;\n\n\t}",
"@Override\n\tpublic String setCourseName() {\n\t\treturn null;\n\t}",
"public Course (String courseName, double creditHours, double courseGrade) {\r\n\t\tname = courseName;\r\n\t\tcredithours = creditHours;\r\n\t\tnumGrade = courseGrade;\r\n\t\tletterGrade = \"\";\r\n\t}",
"java.lang.String getCourseName();",
"public String getCourseName() {\r\n\t\treturn CourseName;\r\n\t}",
"public String getCourseName() {\n\t\treturn courseName;\n\t}",
"public String getCourseName()\n\t{\n\t\treturn courseName;\n\t}",
"public String getCourseName() {\n return this.courseName;\n }",
"public com.google.protobuf.ByteString getCourseNameBytes() {\n\t\t\t\tjava.lang.Object ref = courseName_;\n\t\t\t\tif (ref instanceof String) {\n\t\t\t\t\tcom.google.protobuf.ByteString b = com.google.protobuf.ByteString\n\t\t\t\t\t\t\t.copyFromUtf8((java.lang.String) ref);\n\t\t\t\t\tcourseName_ = b;\n\t\t\t\t\treturn b;\n\t\t\t\t} else {\n\t\t\t\t\treturn (com.google.protobuf.ByteString) ref;\n\t\t\t\t}\n\t\t\t}",
"public String getCourseName() {\n\t\treturn CourseName;\n\t}",
"public com.google.protobuf.ByteString getCourseNameBytes() {\n\t\t\tjava.lang.Object ref = courseName_;\n\t\t\tif (ref instanceof java.lang.String) {\n\t\t\t\tcom.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);\n\t\t\t\tcourseName_ = b;\n\t\t\t\treturn b;\n\t\t\t} else {\n\t\t\t\treturn (com.google.protobuf.ByteString) ref;\n\t\t\t}\n\t\t}",
"public String getCourseName(){//getCourseName body start\n\t\treturn CourseName;\n\t}",
"public String getCourseName() {\n return courseName;\n }",
"public Builder setCourseNameBytes(com.google.protobuf.ByteString value) {\n\t\t\t\tif (value == null) {\n\t\t\t\t\tthrow new NullPointerException();\n\t\t\t\t}\n\t\t\t\tcheckByteStringIsUtf8(value);\n\n\t\t\t\tcourseName_ = value;\n\t\t\t\tonChanged();\n\t\t\t\treturn this;\n\t\t\t}",
"public String getCourseName ( )\n\t{\n\t\tif(courseName.length ( )==0 || courseName==null)\n\t\t{\n\t\t\tcourseName = \"Course Name\";\n\t\t}\n\t\treturn courseName;\n\t}",
"public String getCourseName() {\n return courseName;\n }",
"public String getCourseName() {\n return courseName;\n }",
"public String getCourseName() {\n return courseName;\n }",
"public java.lang.String getCourseName() {\n\t\t\tjava.lang.Object ref = courseName_;\n\t\t\tif (ref instanceof java.lang.String) {\n\t\t\t\treturn (java.lang.String) ref;\n\t\t\t} else {\n\t\t\t\tcom.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;\n\t\t\t\tjava.lang.String s = bs.toStringUtf8();\n\t\t\t\tcourseName_ = s;\n\t\t\t\treturn s;\n\t\t\t}\n\t\t}",
"public void setCourseName( String name )\n {\n courseName = name; // store the course name\n }",
"public java.lang.String getCourseName() {\n\t\t\t\tjava.lang.Object ref = courseName_;\n\t\t\t\tif (!(ref instanceof java.lang.String)) {\n\t\t\t\t\tcom.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;\n\t\t\t\t\tjava.lang.String s = bs.toStringUtf8();\n\t\t\t\t\tcourseName_ = s;\n\t\t\t\t\treturn s;\n\t\t\t\t} else {\n\t\t\t\t\treturn (java.lang.String) ref;\n\t\t\t\t}\n\t\t\t}",
"Student(String name) {\n\t\tthis.name = name;\n\t\tregisteredCourses = new Course[30];\n\t}",
"public String getCourseName() {\r\n return COURSE_NAME;\r\n }",
"@Override\n\tpublic String getCourseName() {\n\t\treturn null;\n\t}",
"com.google.protobuf.ByteString getCourseNameBytes();",
"@Override\n\tpublic void addCourse(String courseName) {\n\t\tcd.addCourse(courseName);\n\t}",
"public String getCourse() {\n return courseName;\n }",
"public Student ( int rollno, String name, String course ) {\n\t\tthis.rollno = rollno;\n\t\tthis.name = name;\n\t\tthis.course = course;\n\t}",
"public Course (double creditHours) {\r\n\t\tname = \"A New Course\";\r\n\t\tnumGrade = 0;\r\n\t\tcredithours = creditHours;\r\n\t\tletterGrade = \"\";\r\n\t}",
"@Override\n public String getCourseName() {\n return this.deadline.getCourseName();\n }",
"public FinishedCourse(String name)\n\t{\n\t\tsuper (name);\n\t\t_grade = Grades.O;\n\t\t_passed = false;\n\t\t\n\t\t\n\t}",
"public Builder clearCourseName() {\n\n\t\t\t\tcourseName_ = getDefaultInstance().getCourseName();\n\t\t\t\tonChanged();\n\t\t\t\treturn this;\n\t\t\t}",
"public String getCourseName(){\n return courseName;\n }",
"public StudentCourse() {\n this(\"student_course\", null);\n }",
"public Student(String name, int age, char gender, int year, String course) {\r\n\t\tthis.name = name;\r\n\t\tthis.age = age;\r\n\t\tthis.gender = gender;\r\n\t\tthis.year = year;\r\n\t\tthis.course = course;\r\n\t}",
"public Student(String name) { // constructor\n\t\tthis.name = name; \n\t}",
"public void setCourse(String course);",
"public Student(String name, String gender, String email, Course course1, \n Course course2, Course course3){\n this.name = name;\n this.gender = gender;\n this.email = email;\n this.course1 = course1;\n this.course2 = course2;\n this.course3 = course3;\n }",
"public void createCourse(String courseName, int courseCode){}",
"public GradeBook(String courseName, int[][] grades){\n this.courseName = courseName;\n this.grades = grades;\n }",
"public uCoursesTest(String name) {\n\t\tsuper(name);\n\t}",
"public String getCourseName()\n {\n return courseName;\n }",
"@Override\n\tpublic Course searchCourse(String course_name) {\n\t\tconn = DBUtils.connectToDb();\n\t\tString query = \"select * from course where course_name = ?;\";\n\t\tpst = DBUtils.getPreparedStatement(conn, query);\n\t\tCourse course = null;\n\t\ttry {\n\t\t\tpst.setString(1, course_name);\n\t\t\trs = pst.executeQuery();\n\t\t\tif (rs != null)\n\t\t\t\tif (rs.next()) {\n\t\t\t\t\tcourse = new Course();\n\t\t\t\t\tcourse.setCourse_id(rs.getInt(1));\n\t\t\t\t\tcourse.setCourse_name(rs.getString(2));\n\t\t\t\t\tcourse.setStart_date(rs.getString(3));\n\t\t\t\t\tcourse.setEnd_date(rs.getString(4));\n\t\t\t\t\tcourse.setCapacity(rs.getInt(5));\n\t\t\t\t}\n\t\t\tDBUtils.closeConnections();\n\t\t} catch (SQLException e) {\n\t\t\te.printStackTrace();\n\t\t}\n\n\t\treturn course;\n\t}",
"public Student(String requiredStudentName)\n {\n studentName = requiredStudentName;\n }",
"public Course() {\n this(\"course\", null);\n }",
"static String getCourseName() {\n\t\tScanner s = new Scanner(System.in);\n\t\tSystem.out.print(\"Enter course name: \");\n\t\tString cn = s.nextLine();\n\t\treturn cn;\n\t}",
"public Student(String name) {\n this.nameProp.set(name);\n }",
"public Course(@NotBlank String name, @NotBlank String lecturer, @NotBlank String description) {\n this.name = name;\n this.lecturer = lecturer;\n this.description = description;\n }",
"public Course(String courseName, String cid, LocalDate start, LocalDate end) {\r\n \tthis.courseName = courseName;\r\n \tthis.cid = cid;\r\n \tthis.start = start;\r\n \tthis.end = end;\r\n \tthis.modules = new ArrayList<Module>();\r\n }",
"public Student(String name) {\n\n this.name = name;\n }",
"public Student(int id, String name, String course) {\n this.id = id;\n this.name = name;\n this.course = course;\n }",
"public void setCourse(String course) {\n\t\tCourse = course;\n\t}",
"public void setCourseNum(String courseNum) {\n this.courseNum = courseNum;\n }",
"public GradeBook(String couseName, int[] gradesArray) {\n this.couseName = couseName; //inicializa courseName\n this.grades = gradesArray; // niveis de armanzenamento.\n }",
"public void setcourse(String course) {\n\t\tthis.course = course;\n\t}",
"public Student(String name, String address, String facNumber) {\r\n super(name, address);\r\n this.facultyNumber = facNumber;\r\n courses = new HashMap<String, Double>();\r\n }",
"public Student(String name) {\n this.name = name;\n }",
"public Course() {\n term = \"\";\n subject = \"\";\n number = 0;\n newRoom = 0;\n oldRoomLetter = \"\";\n section = new String();\n crossList = new String();\n title = new String();\n faculty = new String();\n building = new String();\n room = \"\";\n startDate = \"\";\n dayTime = new String();\n\n }",
"public Student( String name ) {\n sname=name;\n }",
"public Course findCourseByName(String courseName) {\n\t\tCourse course=new Course();\n\t\tcourse.setCourseName(courseName);\n\t\tList<Course> courses=courseDao.findByExample(course);\n\t\tif(courses.size()==0)\n\t\t\treturn null;\n\t\treturn courses.get(0);\n\t}",
"public Student( String name , String address ){//constructor with arguments \r\n \tID_COUNTER++;\r\n \tstudentNum = ID_COUNTER;\r\n getFirstAndLastName( name );\r\n this.address = address ;\r\n loginID = makeLoginID() ;\r\n numCredits = 0;\r\n totalGradePoints = 0;\r\n }",
"public Course(String c, String g, String g2){\n raw = c;\n for(int x = 0; x < raw.length(); x++){\n if(x > 5){\n if(raw.charAt(x) == 't' && raw.charAt(x-1) == 'e' && raw.charAt(x-2) == 'D'){\n cname = raw.substring(0, x-4);\n break;\n }\n }\n }\n\n for(int x = 0; x < g.length(); x++){\n if(g.charAt(x) == ' '){\n grade1 = g.substring(0,x);\n }\n }\n for(int x = 0; x < g2.length(); x++){\n if(g2.charAt(x) == ' '){\n grade1 = g.substring(0,x);\n }\n }\n System.out.println(\"grade1 : \" + grade1);\n System.out.println(\"grade2 : \" + grade2);\n cClassify();\n gpaCalc(grade1, 1);\n gpaCalc(grade2, 2);\n\n }",
"public Student(String firstName, String lastName, int age, double gpa, String major, String department, List<Course> courses) {\n this.firstName = firstName;\n this.lastName = lastName;\n this.age = age;\n this.gpa = gpa;\n this.major = major;\n this.department = department;\n this.courses = courses;\n }",
"public Course(String n, String i, int m, String in, int s, String l) {\n\t\tname = n;\n\t\tid = i;\n\t\tmaxstudents = m;\n\t\tinstructor = in;\n\t\tsection = s;\n\t\tlocation = l;\n\t}",
"public Course(String courseName, String courseID, Course[] prerequisites, Textbook[] textbooks) {\r\n COURSE_NAME = courseName;\r\n COURSE_ID = courseID;\r\n PREREQUISITE_COURSES = prerequisites;\r\n TEXTBOOKS = textbooks;\r\n }",
"public Course(String mandatoryElective, String name, String code, String instructor, String credits, String acronym, String monday, String tuesday, String wednesday, String thurdsday, String friday, String tut, String lab, String preConditions, String postConditions) {\r\n this.name = name;\r\n this.acronym = acronym;\r\n this.instructor = instructor;\r\n this.mandatoryElective = mandatoryElective;\r\n this.credits = credits;\r\n this.code = code;\r\n this.monday = monday;\r\n this.tuesday = tuesday;\r\n this.wednesday = wednesday;\r\n this.thurdsday = thurdsday;\r\n this.friday = friday;\r\n this.tut = tut;\r\n this.lab = lab;\r\n this.preConditions = preConditions;\r\n this.postConditions = postConditions;\r\n }",
"public Student(String name, String gender, String email){\n this.name = name;\n this.gender = gender;\n this.email = email;\n this.course1 = new Course();\n this.course2 = new Course();\n this.course3 = new Course();\n }",
"public void setCourse(String course) {\n\t\tthis.course = course;\n\t}",
"public String getPredefinedCourseName() {\n return predefinedCourseName;\n }",
"public Subject(String subjectName, String course, String semester, String language) {\n this.subjectName = subjectName;\n this.course = course;\n this.semester = semester;\n this.subjectId = subjectCodes.get(subjectName);\n this.language = language;\n if (language.equals(ENGLISH)) {\n this.subjectId += \".I\";\n }\n }",
"public StudentCourse(String alias) {\n this(alias, STUDENT_COURSE);\n }",
"public RollManager (String strCourseName, String strCourseNumber, String strInstructor)\n\t{\n\t\tsuper ( );\n\t\tthis.classRoll = new ArrayList<Student>();\n\t\tthis.courseName = strCourseName;\n\t\tthis.setCourseNumber (strCourseNumber);\n\t\tthis.setInstructor (strInstructor);\n\t\tthis.setCourseToFileString (strCourseName + \" | \" + strCourseNumber + \" | \" + strInstructor) ;\n\t\tsaveNeed=true;\n\t}",
"public Course(String title, String codeNumber)\n {\n this.title = title;\n this.codeNumber = codeNumber;\n\n this.credits = 0;\n this.finalGrade = finalGrade;\n\n module1 = new Module(\"Application Development\", \"AD200\");\n module2 = new Module(\"Programming Concepts\", \"PC452\");\n module3 = new Module(\"Data Analysis\", \"DA101\");\n module4 = new Module(\"Web Design\", \"WD953\");\n }",
"public Course(String courseId, String courseIdSchool, String teacherId, String courseName, String courseType, String courseAcademy, Float courseCredit, String courseArea, String courseTeacher) {\n this.courseId = courseId;\n this.courseIdSchool = courseIdSchool;\n this.teacherId = teacherId;\n this.courseName = courseName;\n this.courseType = courseType;\n this.courseAcademy = courseAcademy;\n this.courseCredit = courseCredit;\n this.courseArea = courseArea;\n this.courseTeacher = courseTeacher;\n }",
"public void setName(String studentName) \r\n {\r\n if (isEmpty(studentName)) \r\n {\r\n throw new IllegalArgumentException(\"Student name cannot be blank.\");\r\n } \r\n else \r\n {\r\n this.studentName = studentName;\r\n }\r\n\r\n }",
"public void setGradeName(String gradeName) {\n this.gradeName = gradeName;\n }",
"public Q1PrivateStudent(String name, int id, String course) {\n\t\tthis.name = name;\n\t\tthis.id = id;\n\t\tthis.course = course;\n\t}",
"public String getcourse() {\n\t\treturn course;\n\t}",
"public void setCourseId(String courseId) {\n this.courseId = courseId;\n }",
"Course() {\r\n\t\tsetValidDays(true);\r\n\t\tsetName(null);\r\n\t\tsetNumberOfDays(0);\r\n\t\tsetPrice(0.0);\r\n\t}",
"public void addCourseName(String courseName) {\r\n\tCoursesList = new ArrayList<String>();\r\n\tCoursesList.add(courseName);\r\n}",
"public String toString() {\r\n return COURSE_ID + \"-\" + COURSE_NAME;\r\n }",
"public Courses(String x1, String x2, String x3, String x4, String x5, String x6) {\n\t\tcourse_name=x1;\n\t\tcourse_id=x2;\n\t\tcourse_max=x3;\n\t\tcourse_current_num=\"0\";\n\t\tlist.clear();\n\t\tcourse_instructor=x4;\n\t\tcourse_section=x5;\n\t\tcourse_location=x6;\n\t\t\n\t}",
"public void setName(String grade) {\r\n\t\tname = grade;\r\n\t\t\r\n\t}",
"public void addCourse(String courseName, String courseCode, String descr, String format, String sem, double grade) \n {\n CreditCourse cc = new CreditCourse(courseName, courseCode, descr, format, sem, grade); \n cc.setActive(); \n courses.put(courseCode, cc); \n // create a CreditCourse object\n // set course active\n // add to courses array list\n }",
"public void setCollegeName(String collegeName) {\n this.collegeName = collegeName;\n }",
"public String getCourse() {\n\t\treturn Course;\n\t}"
] | [
"0.80979913",
"0.78880554",
"0.78635466",
"0.7616934",
"0.7616934",
"0.7616934",
"0.7616934",
"0.75966495",
"0.7551455",
"0.7548391",
"0.75130093",
"0.7480625",
"0.7324072",
"0.72114563",
"0.7069764",
"0.7055251",
"0.70123565",
"0.6979005",
"0.69733524",
"0.6973001",
"0.6950001",
"0.6939835",
"0.692527",
"0.6919327",
"0.6917369",
"0.6892516",
"0.6868156",
"0.6863277",
"0.6828078",
"0.6828078",
"0.6828078",
"0.68166447",
"0.6790508",
"0.678798",
"0.67638844",
"0.6722243",
"0.67024744",
"0.6684221",
"0.660395",
"0.644786",
"0.6442157",
"0.62889254",
"0.6239886",
"0.62364626",
"0.6172407",
"0.61322725",
"0.6124766",
"0.61176157",
"0.610936",
"0.6108396",
"0.6072221",
"0.6061592",
"0.605981",
"0.60577035",
"0.6016576",
"0.6008785",
"0.60080266",
"0.600708",
"0.6001366",
"0.5948382",
"0.59452707",
"0.5924668",
"0.59097946",
"0.5893434",
"0.58902997",
"0.58888537",
"0.5866145",
"0.5862622",
"0.5860527",
"0.5842375",
"0.58185863",
"0.580473",
"0.5791362",
"0.5776412",
"0.5752596",
"0.5752084",
"0.5749498",
"0.5745853",
"0.57225156",
"0.57146716",
"0.57072914",
"0.5705994",
"0.5700475",
"0.56713897",
"0.567039",
"0.56528074",
"0.5639776",
"0.5620141",
"0.56094223",
"0.5605679",
"0.5597086",
"0.55816334",
"0.55775535",
"0.5561438",
"0.5546425",
"0.5542292",
"0.5537101",
"0.5531387",
"0.55301476",
"0.5529789"
] | 0.778128 | 3 |
end constructor method to set the course name | public void setCourseName( String name )
{
courseName = name; // store the course name
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void setCourseName(String name){//setCourseName body start\n\t\tCourseName = name;\n\t}",
"public void setCourseName( String name )\n {\n courseName = name; // store the course name\n }",
"public Course(String courseName) {\n this.courseName = courseName;\n }",
"public GradeBook2( String name )\n {\n courseName = name; // initializes courseName\n }",
"public Course(String courseName) {\n studentList = new ArrayList<Student>(MAXSTUDENT);\n this.courseName = courseName;\n studentCount = 0;\n }",
"public Builder setCourseName(java.lang.String value) {\n\t\t\t\tif (value == null) {\n\t\t\t\t\tthrow new NullPointerException();\n\t\t\t\t}\n\n\t\t\t\tcourseName_ = value;\n\t\t\t\tonChanged();\n\t\t\t\treturn this;\n\t\t\t}",
"public GradeBook4( String name ) \n\t{\n\t\tcourseName = name;\t// initializes courseName\n\t}",
"public GradeBook (String name){ //Constructor\n\t\tcourseName=name;\n//\t\tstudents = studentNum;\n\t}",
"public void setCourseName (String courseName)\n\t{\n\t\tif(courseName.length ( )==0 || courseName==null)\n\t\t{\n\t\t\tcourseName=\"Course Name\";\n\t\t}\n\t\tthis.courseName = courseName;\n\t\tthis.saveNeed = true;\n\n\t}",
"public void setCourseName(String courseName) {\n this.courseName = courseName;\n }",
"public void setCourseName(String courseName) {\n this.courseName = courseName;\n }",
"public void setCourseName(String courseName) {\n this.courseName = courseName;\n }",
"public void setCourseName(String courseName) {\n this.courseName = courseName;\n }",
"@Override\n\tpublic String getCourseName() {\n\t\treturn null;\n\t}",
"public String getCourseName(){//getCourseName body start\n\t\treturn CourseName;\n\t}",
"@Override\n\tpublic String setCourseName() {\n\t\treturn null;\n\t}",
"public uCoursesTest(String name) {\n\t\tsuper(name);\n\t}",
"public void setCourse(String course);",
"public String getCourseName() {\r\n\t\treturn CourseName;\r\n\t}",
"public String getCourseName() {\n return courseName;\n }",
"public String getCourseName()\n\t{\n\t\treturn courseName;\n\t}",
"public String getCourseName() {\n return this.courseName;\n }",
"public String getCourseName() {\r\n return COURSE_NAME;\r\n }",
"public String getCourseName() {\n return courseName;\n }",
"public String getCourseName() {\n return courseName;\n }",
"public String getCourseName() {\n return courseName;\n }",
"public void setCourseName(String courseName) {\n\t\tCourseName = courseName;\n\t}",
"public Builder setCourseNameBytes(com.google.protobuf.ByteString value) {\n\t\t\t\tif (value == null) {\n\t\t\t\t\tthrow new NullPointerException();\n\t\t\t\t}\n\t\t\t\tcheckByteStringIsUtf8(value);\n\n\t\t\t\tcourseName_ = value;\n\t\t\t\tonChanged();\n\t\t\t\treturn this;\n\t\t\t}",
"Student(String name) {\n\t\tthis.name = name;\n\t\tregisteredCourses = new Course[30];\n\t}",
"java.lang.String getCourseName();",
"public String getCourseName() {\n\t\treturn CourseName;\n\t}",
"public String getCourseName ( )\n\t{\n\t\tif(courseName.length ( )==0 || courseName==null)\n\t\t{\n\t\t\tcourseName = \"Course Name\";\n\t\t}\n\t\treturn courseName;\n\t}",
"public String getCourseName() {\n\t\treturn courseName;\n\t}",
"public StudentCourse() {\n this(\"student_course\", null);\n }",
"public void setCourseName(String courseName) {\n this.courseName = courseName == null ? null : courseName.trim();\n }",
"public FinishedCourse(String name)\n\t{\n\t\tsuper (name);\n\t\t_grade = Grades.O;\n\t\t_passed = false;\n\t\t\n\t\t\n\t}",
"public String getCourse() {\n return courseName;\n }",
"public Course (String courseName, double creditHours, double courseGrade) {\r\n\t\tname = courseName;\r\n\t\tcredithours = creditHours;\r\n\t\tnumGrade = courseGrade;\r\n\t\tletterGrade = \"\";\r\n\t}",
"public Course() {\n this(\"course\", null);\n }",
"public String getCourseName(){\n return courseName;\n }",
"public String getCourseName()\n {\n return courseName;\n }",
"public Student ( int rollno, String name, String course ) {\n\t\tthis.rollno = rollno;\n\t\tthis.name = name;\n\t\tthis.course = course;\n\t}",
"public SelectCourse() {\n super();\n }",
"public Course(String n, String i, int m, String in, int s, String l) {\n\t\tname = n;\n\t\tid = i;\n\t\tmaxstudents = m;\n\t\tinstructor = in;\n\t\tsection = s;\n\t\tlocation = l;\n\t}",
"@Override\n public String getCourseName() {\n return this.deadline.getCourseName();\n }",
"public Course (double creditHours) {\r\n\t\tname = \"A New Course\";\r\n\t\tnumGrade = 0;\r\n\t\tcredithours = creditHours;\r\n\t\tletterGrade = \"\";\r\n\t}",
"public Course(String mandatoryElective, String name, String code, String instructor, String credits, String acronym, String monday, String tuesday, String wednesday, String thurdsday, String friday, String tut, String lab, String preConditions, String postConditions) {\r\n this.name = name;\r\n this.acronym = acronym;\r\n this.instructor = instructor;\r\n this.mandatoryElective = mandatoryElective;\r\n this.credits = credits;\r\n this.code = code;\r\n this.monday = monday;\r\n this.tuesday = tuesday;\r\n this.wednesday = wednesday;\r\n this.thurdsday = thurdsday;\r\n this.friday = friday;\r\n this.tut = tut;\r\n this.lab = lab;\r\n this.preConditions = preConditions;\r\n this.postConditions = postConditions;\r\n }",
"public Course(String courseName, String cid, LocalDate start, LocalDate end) {\r\n \tthis.courseName = courseName;\r\n \tthis.cid = cid;\r\n \tthis.start = start;\r\n \tthis.end = end;\r\n \tthis.modules = new ArrayList<Module>();\r\n }",
"public Course(@NotBlank String name, @NotBlank String lecturer, @NotBlank String description) {\n this.name = name;\n this.lecturer = lecturer;\n this.description = description;\n }",
"public Builder clearCourseName() {\n\n\t\t\t\tcourseName_ = getDefaultInstance().getCourseName();\n\t\t\t\tonChanged();\n\t\t\t\treturn this;\n\t\t\t}",
"Course() {\r\n\t\tsetValidDays(true);\r\n\t\tsetName(null);\r\n\t\tsetNumberOfDays(0);\r\n\t\tsetPrice(0.0);\r\n\t}",
"public Course() {\n term = \"\";\n subject = \"\";\n number = 0;\n newRoom = 0;\n oldRoomLetter = \"\";\n section = new String();\n crossList = new String();\n title = new String();\n faculty = new String();\n building = new String();\n room = \"\";\n startDate = \"\";\n dayTime = new String();\n\n }",
"public void createCourse(String courseName, int courseCode){}",
"@Override\n\tpublic void addCourse(String courseName) {\n\t\tcd.addCourse(courseName);\n\t}",
"public Student( String name ) {\n sname=name;\n }",
"public Course(String title, String codeNumber)\n {\n this.title = title;\n this.codeNumber = codeNumber;\n\n this.credits = 0;\n this.finalGrade = finalGrade;\n\n module1 = new Module(\"Application Development\", \"AD200\");\n module2 = new Module(\"Programming Concepts\", \"PC452\");\n module3 = new Module(\"Data Analysis\", \"DA101\");\n module4 = new Module(\"Web Design\", \"WD953\");\n }",
"public Student(String name) { // constructor\n\t\tthis.name = name; \n\t}",
"public Course(int id, String name, String description) {\n this.id = id;\n this.name = name;\n this.description = description;\n this.teachers = new ArrayList<>();\n }",
"public Course(String alias) {\n this(alias, COURSE);\n }",
"public void setcourse(String course) {\n\t\tthis.course = course;\n\t}",
"public void setCourse(String course) {\n\t\tCourse = course;\n\t}",
"public University(String name){\n this.name = name;\n }",
"public Student(String requiredStudentName)\n {\n studentName = requiredStudentName;\n }",
"public StudentCourse(String alias) {\n this(alias, STUDENT_COURSE);\n }",
"public Course(String codeNo, String title)\n {\n // initialise instance variables\n this.codeNo = codeNo;\n this.title = title;\n \n module1 = new Module(\"Programming Concepts\", \"CO452\");\n module2 = new Module(\"Game Design\", \"CO459\");\n module3 = new Module(\"Networking\", \"CO451\");\n module4 = new Module(\"Computer Architectures\", \"CO450\");\n }",
"public Student(String name, String gender, String email, Course course1, \n Course course2, Course course3){\n this.name = name;\n this.gender = gender;\n this.email = email;\n this.course1 = course1;\n this.course2 = course2;\n this.course3 = course3;\n }",
"public Student(int id, String name, String course) {\n this.id = id;\n this.name = name;\n this.course = course;\n }",
"public Course() {\n super();\n }",
"public Course(String courseName, String courseID, Course[] prerequisites, Textbook[] textbooks) {\r\n COURSE_NAME = courseName;\r\n COURSE_ID = courseID;\r\n PREREQUISITE_COURSES = prerequisites;\r\n TEXTBOOKS = textbooks;\r\n }",
"private UserCourseCourse() {\n\t}",
"public Course() {\n\n\t}",
"public java.lang.String getCourseName() {\n\t\t\tjava.lang.Object ref = courseName_;\n\t\t\tif (ref instanceof java.lang.String) {\n\t\t\t\treturn (java.lang.String) ref;\n\t\t\t} else {\n\t\t\t\tcom.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;\n\t\t\t\tjava.lang.String s = bs.toStringUtf8();\n\t\t\t\tcourseName_ = s;\n\t\t\t\treturn s;\n\t\t\t}\n\t\t}",
"public Courses(String x1, String x2, String x3, String x4, String x5, String x6) {\n\t\tcourse_name=x1;\n\t\tcourse_id=x2;\n\t\tcourse_max=x3;\n\t\tcourse_current_num=\"0\";\n\t\tlist.clear();\n\t\tcourse_instructor=x4;\n\t\tcourse_section=x5;\n\t\tcourse_location=x6;\n\t\t\n\t}",
"public Course() {}",
"public Course(String codeNo, String title)\n {\n // initialise variables\n this.codeNo = codeNo;\n this.title = title;\n \n // Setup the four individual modules\n // I did it this way as I couldn't bear pointing-and-clicking to add modules!\n moduleProgramming = new Module(\"Programming\", \"ABC001\");\n moduleWeb = new Module(\"Web Design\", \"ABC002\");\n moduleDigitalTech = new Module(\"Digital Technology\", \"ABC003\");\n moduleCompArchitecture = new Module(\"Computer Architecture\", \"ABC004\");\n \n complete = false;\n totalCredits = 0;\n totalMark = 0;\n }",
"public Student(String name) {\n\n this.name = name;\n }",
"public RollManager (String strCourseName, String strCourseNumber, String strInstructor)\n\t{\n\t\tsuper ( );\n\t\tthis.classRoll = new ArrayList<Student>();\n\t\tthis.courseName = strCourseName;\n\t\tthis.setCourseNumber (strCourseNumber);\n\t\tthis.setInstructor (strInstructor);\n\t\tthis.setCourseToFileString (strCourseName + \" | \" + strCourseNumber + \" | \" + strInstructor) ;\n\t\tsaveNeed=true;\n\t}",
"public CreateCourse() {\r\n super(\"Create Course\", \"Creates a course\", \"`!createcourse`\", commands, \"admin\");\r\n this.requiredUserPermissions = new Permission[]{Permission.ADMINISTRATOR}; // User must have administrator privileges\r\n }",
"public java.lang.String getCourseName() {\n\t\t\t\tjava.lang.Object ref = courseName_;\n\t\t\t\tif (!(ref instanceof java.lang.String)) {\n\t\t\t\t\tcom.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;\n\t\t\t\t\tjava.lang.String s = bs.toStringUtf8();\n\t\t\t\t\tcourseName_ = s;\n\t\t\t\t\treturn s;\n\t\t\t\t} else {\n\t\t\t\t\treturn (java.lang.String) ref;\n\t\t\t\t}\n\t\t\t}",
"public Student(String name) {\n this.name = name;\n }",
"public CSCourses() {\n courseList = new LinkedList<Course>(); \n numOfCourses = 0;\n }",
"public Student(String name, int age, char gender, int year, String course) {\r\n\t\tthis.name = name;\r\n\t\tthis.age = age;\r\n\t\tthis.gender = gender;\r\n\t\tthis.year = year;\r\n\t\tthis.course = course;\r\n\t}",
"public Course() {\n }",
"public Course() {\n }",
"public Student(String firstName, String lastName, int age, double gpa, String major, String department, List<Course> courses) {\n this.firstName = firstName;\n this.lastName = lastName;\n this.age = age;\n this.gpa = gpa;\n this.major = major;\n this.department = department;\n this.courses = courses;\n }",
"public Subject(String subjectName, String course, String semester, String language) {\n this.subjectName = subjectName;\n this.course = course;\n this.semester = semester;\n this.subjectId = subjectCodes.get(subjectName);\n this.language = language;\n if (language.equals(ENGLISH)) {\n this.subjectId += \".I\";\n }\n }",
"@Test\r\n public void testSetCourse() {\r\n System.out.println(\"setCourse\");\r\n String course = \"\";\r\n Student instance = new Student();\r\n instance.setCourse(course);\r\n \r\n }",
"public Student(String name, String gender, String email){\n this.name = name;\n this.gender = gender;\n this.email = email;\n this.course1 = new Course();\n this.course2 = new Course();\n this.course3 = new Course();\n }",
"public Student(String name) {\n this.nameProp.set(name);\n }",
"public String getcourse() {\n\t\treturn course;\n\t}",
"public void setCourse(String course) {\n\t\tthis.course = course;\n\t}",
"public String getPredefinedCourseName() {\n return predefinedCourseName;\n }",
"public Course(int id, String title) {\n this.id = id;\n this.title = title;\n }",
"public AssignmentCategory(String ac) {\n categoryName = ac;\n }",
"public com.google.protobuf.ByteString getCourseNameBytes() {\n\t\t\tjava.lang.Object ref = courseName_;\n\t\t\tif (ref instanceof java.lang.String) {\n\t\t\t\tcom.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);\n\t\t\t\tcourseName_ = b;\n\t\t\t\treturn b;\n\t\t\t} else {\n\t\t\t\treturn (com.google.protobuf.ByteString) ref;\n\t\t\t}\n\t\t}",
"public void setInstructorName(String newInstructorName) {\n instructorName = newInstructorName;\n }",
"public Student(String name, String address, String facNumber) {\r\n super(name, address);\r\n this.facultyNumber = facNumber;\r\n courses = new HashMap<String, Double>();\r\n }",
"public ClassRoom (String course, String teacher)\r\n {\r\n this.course = course;\r\n this.teacher = teacher;\r\n }",
"public String getCourseTitle() {\n return courseTitle;\n }",
"public CoursesManagement() {\n initComponents();\n }"
] | [
"0.8164613",
"0.81503266",
"0.8147021",
"0.79242617",
"0.764652",
"0.75719506",
"0.74866444",
"0.73863876",
"0.7349807",
"0.72838926",
"0.72838926",
"0.72838926",
"0.72838926",
"0.7242148",
"0.7236231",
"0.7225899",
"0.7208408",
"0.720135",
"0.7135035",
"0.7134583",
"0.7128695",
"0.7123592",
"0.7102019",
"0.7078235",
"0.7078235",
"0.7078235",
"0.70629495",
"0.7048511",
"0.7047804",
"0.7047553",
"0.7035731",
"0.7028492",
"0.6991323",
"0.694874",
"0.69331026",
"0.693277",
"0.69101644",
"0.69056845",
"0.68485475",
"0.6843306",
"0.68010056",
"0.67355984",
"0.67102355",
"0.66975516",
"0.6685766",
"0.667195",
"0.6656689",
"0.6653287",
"0.6649256",
"0.66375804",
"0.66065675",
"0.66042185",
"0.65826",
"0.65574",
"0.6550601",
"0.6540032",
"0.6511913",
"0.6496013",
"0.64637077",
"0.64265287",
"0.64260685",
"0.6425396",
"0.6398151",
"0.6391305",
"0.639064",
"0.63903284",
"0.638076",
"0.63623005",
"0.6358893",
"0.634507",
"0.6339013",
"0.6324923",
"0.6313916",
"0.62779325",
"0.6270625",
"0.62663126",
"0.62615126",
"0.62608427",
"0.62510145",
"0.6238181",
"0.6235242",
"0.62266105",
"0.6225896",
"0.6225896",
"0.62230414",
"0.6212098",
"0.62120044",
"0.6211824",
"0.61822116",
"0.6175208",
"0.6167595",
"0.6166043",
"0.61576456",
"0.61511385",
"0.61434793",
"0.61408734",
"0.6136593",
"0.61339873",
"0.6132714",
"0.61298263"
] | 0.79628336 | 3 |
end method setCourseName method to retrieve the course name | public String getCourseName()
{
return courseName;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"java.lang.String getCourseName();",
"public String getCourseName(){//getCourseName body start\n\t\treturn CourseName;\n\t}",
"public String getCourseName() {\n return this.courseName;\n }",
"public String getCourseName() {\n return courseName;\n }",
"public String getCourseName() {\n return courseName;\n }",
"public String getCourseName() {\n return courseName;\n }",
"public String getCourseName() {\n return courseName;\n }",
"public String getCourseName() {\r\n\t\treturn CourseName;\r\n\t}",
"public String getCourseName() {\n\t\treturn courseName;\n\t}",
"public String getCourseName() {\n\t\treturn CourseName;\n\t}",
"public String getCourseName() {\r\n return COURSE_NAME;\r\n }",
"public void setCourseName(String name){//setCourseName body start\n\t\tCourseName = name;\n\t}",
"public String getCourseName ( )\n\t{\n\t\tif(courseName.length ( )==0 || courseName==null)\n\t\t{\n\t\t\tcourseName = \"Course Name\";\n\t\t}\n\t\treturn courseName;\n\t}",
"public void setCourseName( String name )\n\t{\n\t\tcourseName = name;\t// store the course name\n\t}",
"public String getCourse() {\n return courseName;\n }",
"public void setCourseName( String name )\n {\n courseName = name; // store the course name\n }",
"public java.lang.String getCourseName() {\n\t\t\tjava.lang.Object ref = courseName_;\n\t\t\tif (ref instanceof java.lang.String) {\n\t\t\t\treturn (java.lang.String) ref;\n\t\t\t} else {\n\t\t\t\tcom.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;\n\t\t\t\tjava.lang.String s = bs.toStringUtf8();\n\t\t\t\tcourseName_ = s;\n\t\t\t\treturn s;\n\t\t\t}\n\t\t}",
"public java.lang.String getCourseName() {\n\t\t\t\tjava.lang.Object ref = courseName_;\n\t\t\t\tif (!(ref instanceof java.lang.String)) {\n\t\t\t\t\tcom.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;\n\t\t\t\t\tjava.lang.String s = bs.toStringUtf8();\n\t\t\t\t\tcourseName_ = s;\n\t\t\t\t\treturn s;\n\t\t\t\t} else {\n\t\t\t\t\treturn (java.lang.String) ref;\n\t\t\t\t}\n\t\t\t}",
"public String getCourseName(){\n return courseName;\n }",
"public String getCourseName()\n {\n return courseName;\n }",
"@Override\n\tpublic String getCourseName() {\n\t\treturn null;\n\t}",
"public void setCourseName(String courseName) {\n this.courseName = courseName;\n }",
"public void setCourseName(String courseName) {\n this.courseName = courseName;\n }",
"public void setCourseName(String courseName) {\n this.courseName = courseName;\n }",
"public void setCourseName(String courseName) {\n this.courseName = courseName;\n }",
"public com.google.protobuf.ByteString getCourseNameBytes() {\n\t\t\t\tjava.lang.Object ref = courseName_;\n\t\t\t\tif (ref instanceof String) {\n\t\t\t\t\tcom.google.protobuf.ByteString b = com.google.protobuf.ByteString\n\t\t\t\t\t\t\t.copyFromUtf8((java.lang.String) ref);\n\t\t\t\t\tcourseName_ = b;\n\t\t\t\t\treturn b;\n\t\t\t\t} else {\n\t\t\t\t\treturn (com.google.protobuf.ByteString) ref;\n\t\t\t\t}\n\t\t\t}",
"@Override\n public String getCourseName() {\n return this.deadline.getCourseName();\n }",
"public com.google.protobuf.ByteString getCourseNameBytes() {\n\t\t\tjava.lang.Object ref = courseName_;\n\t\t\tif (ref instanceof java.lang.String) {\n\t\t\t\tcom.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);\n\t\t\t\tcourseName_ = b;\n\t\t\t\treturn b;\n\t\t\t} else {\n\t\t\t\treturn (com.google.protobuf.ByteString) ref;\n\t\t\t}\n\t\t}",
"public void setCourseName(String courseName) {\n\t\tCourseName = courseName;\n\t}",
"@Override\n\tpublic String setCourseName() {\n\t\treturn null;\n\t}",
"com.google.protobuf.ByteString getCourseNameBytes();",
"public void setCourseName (String courseName)\n\t{\n\t\tif(courseName.length ( )==0 || courseName==null)\n\t\t{\n\t\t\tcourseName=\"Course Name\";\n\t\t}\n\t\tthis.courseName = courseName;\n\t\tthis.saveNeed = true;\n\n\t}",
"public Builder setCourseName(java.lang.String value) {\n\t\t\t\tif (value == null) {\n\t\t\t\t\tthrow new NullPointerException();\n\t\t\t\t}\n\n\t\t\t\tcourseName_ = value;\n\t\t\t\tonChanged();\n\t\t\t\treturn this;\n\t\t\t}",
"public Course(String courseName) {\n this.courseName = courseName;\n }",
"public void setCourseName(String courseName) {\n this.courseName = courseName == null ? null : courseName.trim();\n }",
"static String getCourseName() {\n\t\tScanner s = new Scanner(System.in);\n\t\tSystem.out.print(\"Enter course name: \");\n\t\tString cn = s.nextLine();\n\t\treturn cn;\n\t}",
"public String getCourseTitle() {\n return courseTitle;\n }",
"public String getPredefinedCourseName() {\n return predefinedCourseName;\n }",
"public String getCourse() {\n\t\treturn Course;\n\t}",
"public String getcourse() {\n\t\treturn course;\n\t}",
"@Override\n\tpublic void addCourse(String courseName) {\n\t\tcd.addCourse(courseName);\n\t}",
"public String getCourseName(String course_id) throws SQLException {\n\n String courseName = null;\n String query = String.format(\"SELECT * FROM course WHERE course_id = '%s'\", course_id);\n Statement statement = connection.createStatement();\n try {\n ResultSet result = statement.executeQuery(query);\n if(result.next()){\n courseName = result.getString(\"course_title\");\n }\n return courseName;\n }\n catch (SQLException e) {\n return \"No course for now\";\n }\n\n }",
"@AutoEscape\n\tpublic String getCourse();",
"public Builder setCourseNameBytes(com.google.protobuf.ByteString value) {\n\t\t\t\tif (value == null) {\n\t\t\t\t\tthrow new NullPointerException();\n\t\t\t\t}\n\t\t\t\tcheckByteStringIsUtf8(value);\n\n\t\t\t\tcourseName_ = value;\n\t\t\t\tonChanged();\n\t\t\t\treturn this;\n\t\t\t}",
"public void setCourse(String course);",
"public Course getCourse() {\n return course; //XXX-CHANGE-XXX\n }",
"public String getCourseID() {\r\n return COURSE_ID;\r\n }",
"public Course(String courseName) {\n studentList = new ArrayList<Student>(MAXSTUDENT);\n this.courseName = courseName;\n studentCount = 0;\n }",
"@Override\n\tpublic List<String> getNameOfCourses() {\n\t\tconn = DBUtils.connectToDb();\n\t\tString query = \"select course_name from course;\";\n\t\tst = DBUtils.getStatement(conn);\n\t\tList<String> list = null;\n\t\ttry {\n\n\t\t\trs = st.executeQuery(query);\n\t\t\tif (rs != null) {\n\t\t\t\tlist = new ArrayList<String>();\n\t\t\t\twhile (rs.next())\n\t\t\t\t\tlist.add(rs.getString(1));\n\t\t\t}\n\t\t\tDBUtils.closeConnections();\n\t\t} catch (SQLException e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t}\n\t\treturn list;\n\t}",
"public String getcName() {\n return cName;\n }",
"public java.lang.String getCourseProperty() {\n return courseProperty;\n }",
"@Override\n\tpublic Map<String, Object> findCourseByName(String name) {\n\t\treturn cd.findCourseByName(name);\n\t}",
"public Course findCourseByName(String courseName) {\n\t\tCourse course=new Course();\n\t\tcourse.setCourseName(courseName);\n\t\tList<Course> courses=courseDao.findByExample(course);\n\t\tif(courses.size()==0)\n\t\t\treturn null;\n\t\treturn courses.get(0);\n\t}",
"public String getCollegeName() {\n return collegeName;\n }",
"public String getCollegeName() {\n return collegeName;\n }",
"public String toString() {\r\n return COURSE_ID + \"-\" + COURSE_NAME;\r\n }",
"String getCName() {\n return nameTF.getText();\n }",
"@Override\n\tpublic Course searchCourse(String course_name) {\n\t\tconn = DBUtils.connectToDb();\n\t\tString query = \"select * from course where course_name = ?;\";\n\t\tpst = DBUtils.getPreparedStatement(conn, query);\n\t\tCourse course = null;\n\t\ttry {\n\t\t\tpst.setString(1, course_name);\n\t\t\trs = pst.executeQuery();\n\t\t\tif (rs != null)\n\t\t\t\tif (rs.next()) {\n\t\t\t\t\tcourse = new Course();\n\t\t\t\t\tcourse.setCourse_id(rs.getInt(1));\n\t\t\t\t\tcourse.setCourse_name(rs.getString(2));\n\t\t\t\t\tcourse.setStart_date(rs.getString(3));\n\t\t\t\t\tcourse.setEnd_date(rs.getString(4));\n\t\t\t\t\tcourse.setCapacity(rs.getInt(5));\n\t\t\t\t}\n\t\t\tDBUtils.closeConnections();\n\t\t} catch (SQLException e) {\n\t\t\te.printStackTrace();\n\t\t}\n\n\t\treturn course;\n\t}",
"public String getCourseNumber ( )\n\t{\n\t\treturn courseNumber;\n\t}",
"public String getCourseNum() {\n return this.courseNum;\n }",
"public String getCourseId() {\n return courseId;\n }",
"public Course findCourseByName(String n) {\n for (int i = 0; i < numOfCourses; i++) {\n if (this.getCourse(i).getCourseNum().equals(n)) { //get the course number of the course at index i and then compare it with the specified string\n return this.getCourse(i);\n }\n }\n return null;\n }",
"public String getCourseId() {\n\t\treturn courseId;\n\t}",
"public String getIdCourse() {\n\t\t\treturn idCourse;\n\t\t}",
"public GradeBook2( String name )\n {\n courseName = name; // initializes courseName\n }",
"public String getCourseDesc() {\n return courseDesc;\n }",
"public void setCourse(String course) {\n\t\tCourse = course;\n\t}",
"public Course getCourse() {\n return course;\n }",
"public String getName() \r\n {\r\n return studentName;\r\n }",
"@Override\r\n\tpublic double getCourse() {\n\t\treturn this.course;\r\n\t}",
"public Builder clearCourseName() {\n\n\t\t\t\tcourseName_ = getDefaultInstance().getCourseName();\n\t\t\t\tonChanged();\n\t\t\t\treturn this;\n\t\t\t}",
"public String getBookNameCn() {\n return bookNameCn;\n }",
"public String getCourseCode() {\r\n\t\treturn this.courseCode;\r\n\t}",
"public String getCourseCode() {\n\t\treturn CourseCode;\n\t}",
"public String getCourseCode() {\n return courseCode;\n }",
"public GradeBook4( String name ) \n\t{\n\t\tcourseName = name;\t// initializes courseName\n\t}",
"@Override\n\tpublic String getCourseId() \n\t{\n\t\treturn null;\n\t}",
"public String removeCourse(String courseName) {\r\n try {\r\n int i;\r\n String query = \"SELECT * FROM courses WHERE coursename=?\";\r\n PreparedStatement pstmt = conn.prepareStatement(query);\r\n pstmt.setString(1, courseName);\r\n ResultSet rs = pstmt.executeQuery();\r\n if (!rs.next()) {\r\n return \"Course not found\";\r\n }\r\n int id = rs.getInt(\"courseid\");\r\n pstmt.close();\r\n int size = studentRegList.size();\r\n for (i = 0; i < size; i++) {\r\n if (studentRegList.get(i).getCourseId() == id) {\r\n studentRegList.get(i).removeRegistration();\r\n studentRegList.remove(i);\r\n break;\r\n }\r\n }\r\n if (i == size) {\r\n return \"Not currently registered in this course\";\r\n }\r\n } catch (Exception e) {\r\n e.printStackTrace();\r\n }\r\n return \"Course removed successfully\";\r\n }",
"public void setcourse(String course) {\n\t\tthis.course = course;\n\t}",
"public String getCouseName() {\n return couseName;\n }",
"public FinishedCourse(String name)\n\t{\n\t\tsuper (name);\n\t\t_grade = Grades.O;\n\t\t_passed = false;\n\t\t\n\t\t\n\t}",
"public void enroll(String courseName, World world) {\n\t\tCourse course = world.dbCourses().get(courseName);\n\t\tif (course == null) {\n\t\t\tSystem.out.println(\"No course named: \" + courseName);\n\t\t\treturn;\n\t\t}\n\n\t\tList<Course> unfinishedCourses = super.getUnfinishedCourses();\n\t\tList<Course> finishedCourses = super.getFinishedCourses();\n\t\tif (unfinishedCourses.contains(course)) {\n\t\t\tSystem.out.println(\"You are already enrolled in \" + course + \".\");\n\t\t\treturn;\n\t\t}\n\t\tif (finishedCourses.contains(course)) {\n\t\t\tSystem.out.println(\"You have already completed \" + course + \"!\");\n\t\t\treturn;\n\t\t}\n\n\t\tRoom room = super.getRoom();\n\t\tList<Creature> roomCreatures = room.getCreatures();\n\t\tCreature creature;\n\t\tfor (int i = 0; i < roomCreatures.size(); i++) {\n \tcreature = roomCreatures.get(i);\n \tif (creature.isTeacher()) {\n \t\tTeacher teacher = (Teacher) creature;\n \t\tif (teacher.getCourse().equals(course)) { // Check that teacher for course is in room\n \t\t\tunfinishedCourses.add(course);\n \t\t\tSystem.out.println(\"You have enrolled in '\" + course + \"'.\");\n \t\t\treturn;\n \t\t}\n \t}\n\t\t}\n\t\tSystem.out.println(\"No teacher who teaches '\" + course + \"' in the room.\");\n\t}",
"protected String getCourseID(){\n sharedPref = getSharedPreferences(AppCSTR.PREF_NAME, Context.MODE_PRIVATE);\n //Log.d(\"ID\", sharedPref.getString(\"id\", null));\n return sharedPref.getString(AppCSTR.ACCOUNT_COURSE, null);\n }",
"public String getEventCourse() {\n\t\treturn courseRelation;\n\t}",
"public String getCname() {\r\n return cname;\r\n }",
"private void printSavedCoursesNames() {\n ArrayList<Course> tempCourseList = courseList.getCourseList();\n for (int i = 0; i < tempCourseList.size(); i++) {\n System.out.println((i + 1) + \": \" + tempCourseList.get(i).getName());\n }\n }",
"protected String getName() {\n\t\t\t\treturn name;\n\t\t\t}",
"@Override\npublic ArrayList<String> courses() {\n\tArrayList<String> studentCourses = new ArrayList<String>();\n\tstudentCourses.add(\"CMPE - 273\");\n\tstudentCourses.add(\"CMPE - 206\");\n\tstudentCourses.add(\"CMPE - 277\");\n\tSystem.out.println(this.name+\" has take these courses\");\n\tfor(int i = 0 ; i < studentCourses.size() ; i++){\n\t\tSystem.out.println( studentCourses.get(i));\n\t}\n\treturn null;\n}",
"private String getName() {\n\t\treturn name;\n\t}",
"public static String getCourseName(int n)\n\t{\n\t\tString s = strings.get(n);\t\n\t\tif(s.indexOf(';') != -1) {\n\t\t\treturn s.substring(0, s.indexOf(';'));\n\t\t} \n\t\telse {\n\t\t\treturn \"\";\n\t\t}\n\t\t\n\t}",
"public void addCourseName(String courseName) {\r\n\tCoursesList = new ArrayList<String>();\r\n\tCoursesList.add(courseName);\r\n}",
"@Test\n public void setGetName() {\n final CourseType courseType = new CourseType();\n final String NAME = \"name\";\n courseType.setName(NAME);\n\n assertSame(NAME, courseType.getName());\n }",
"protected String getName() {\n\t\treturn name;\n\t}",
"protected String getName() {\n\t\treturn name;\n\t}",
"protected String getName(){\r\n return this.name;\r\n }",
"public String getCname() {\n return cname;\n }",
"public String getName()\n {\n ensureLoaded();\n return m_clzName.getValue();\n }",
"public void setCourse(String course) {\n\t\tthis.course = course;\n\t}",
"public void setCourseNum(String courseNum) {\n this.courseNum = courseNum;\n }",
"String getCruiseName();"
] | [
"0.8827883",
"0.86685145",
"0.85401636",
"0.8470369",
"0.8465214",
"0.8465214",
"0.8465214",
"0.845263",
"0.8417323",
"0.8384266",
"0.83427554",
"0.8266504",
"0.82604253",
"0.8213",
"0.8182298",
"0.8109272",
"0.8074284",
"0.80487114",
"0.80104315",
"0.7962049",
"0.78944504",
"0.78848326",
"0.78848326",
"0.78848326",
"0.78848326",
"0.7798018",
"0.77873933",
"0.77866393",
"0.77738476",
"0.76704633",
"0.7605239",
"0.75234413",
"0.7459104",
"0.7385188",
"0.73846424",
"0.71582574",
"0.7062667",
"0.70367086",
"0.6926389",
"0.691837",
"0.67286247",
"0.67088306",
"0.66830343",
"0.6629779",
"0.66294295",
"0.6544108",
"0.6540253",
"0.649717",
"0.64529717",
"0.64417857",
"0.64386743",
"0.642744",
"0.6416597",
"0.6413633",
"0.6413633",
"0.63796026",
"0.6377362",
"0.63773143",
"0.63433963",
"0.63257724",
"0.63179237",
"0.6317172",
"0.63027847",
"0.62932587",
"0.62809604",
"0.6263444",
"0.62186956",
"0.6217982",
"0.6214039",
"0.6183706",
"0.61729324",
"0.61548847",
"0.60953414",
"0.60891026",
"0.6085408",
"0.6078622",
"0.6065594",
"0.6051838",
"0.60407263",
"0.6035755",
"0.6015409",
"0.601187",
"0.6009788",
"0.6005048",
"0.6002314",
"0.5978364",
"0.59569454",
"0.5956746",
"0.59563184",
"0.5945649",
"0.59413856",
"0.59352255",
"0.5925148",
"0.5925148",
"0.59172946",
"0.59158564",
"0.5913456",
"0.5907578",
"0.5907384",
"0.59047484"
] | 0.85476977 | 2 |
end method getCourseName display a welcome message to the GradeBook user | public void displayMessage()
{
// this statement calls getCourseName to get the
// name of the course this GradeBook represents
System.out.printf( "Welcome to the grade book for\n%s!\n", getCourseName() );
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void displayMessage()\n {\n // getCourseName gets the name of the course\n System.out.printf( \"Welcome to the grade book for\\n%s!\\n\\n\",\n getCourseName() );\n }",
"java.lang.String getCourseName();",
"public void displayMessage(){//displayMessage body start\n\t\tSystem.out.printf(\"course name = %s\\n\", getCourseName());\n\t}",
"public void displayMessage(){\n //getCouseName obtém o nome do curso\n System.out.printf(\"Welcome to the grade book for \\n%s!\\n\\n\", getCouseName());\n }",
"public String getCourseName(){//getCourseName body start\n\t\treturn CourseName;\n\t}",
"public String getCourseName ( )\n\t{\n\t\tif(courseName.length ( )==0 || courseName==null)\n\t\t{\n\t\t\tcourseName = \"Course Name\";\n\t\t}\n\t\treturn courseName;\n\t}",
"public String getCourseName() {\r\n return COURSE_NAME;\r\n }",
"public String getCourseName() {\n return this.courseName;\n }",
"public String getCourseName() {\r\n\t\treturn CourseName;\r\n\t}",
"public String getCourseName() {\n return courseName;\n }",
"public String getCourseName()\n\t{\n\t\treturn courseName;\n\t}",
"public String getCourseName() {\n\t\treturn CourseName;\n\t}",
"public String getCourseName() {\n return courseName;\n }",
"public String getCourseName() {\n return courseName;\n }",
"public String getCourseName() {\n return courseName;\n }",
"@Override\n public String getCourseName() {\n return this.deadline.getCourseName();\n }",
"@Override\r\npublic void addUserToCourse(User user, Course course) {\n\tSystem.out.println(\"Student \"+user.getName()+ \" has joined the \"+course.getCourseName()+\".\");\r\n\t\t\r\n}",
"@Override\n\tpublic String getCourseName() {\n\t\treturn null;\n\t}",
"public String getCourseName()\n {\n return courseName;\n }",
"public String displayCourse(){\n return \"\\tCourse Id: \" + id + \"\\n\" +\n \"\\tCourse Name: \" + name + \"\\n\" +\n \"\\tCourse Description: \" + description + \"\\n\" +\n \"\\tCourse Teacher(s): \" + teacherString() + \"\\n\";\n }",
"static String getCourseName() {\n\t\tScanner s = new Scanner(System.in);\n\t\tSystem.out.print(\"Enter course name: \");\n\t\tString cn = s.nextLine();\n\t\treturn cn;\n\t}",
"public String getCourse() {\n return courseName;\n }",
"public String getCourseName() {\n\t\treturn courseName;\n\t}",
"public void setCourseName(String name){//setCourseName body start\n\t\tCourseName = name;\n\t}",
"private void greenord(String m) {\n\n\t\tSystem.out.println(\"Course name is\"+m);\n\t}",
"public String getCourseName(){\n return courseName;\n }",
"public void printCourseDetails()\n {\n // put your code here\n System.out.println(\"Course \" + codeNo + \" - \" + title);\n }",
"String getWelcomeText();",
"public void printWelcomeMessage()\n\t{\n\t\tSystem.out.println(\"Hello \"+teacherName+\", Have a Nice time teaching \"+subject+\" ! \");\n\t}",
"public void welcomeMsg(){\r\n\t\tdisplay(\"***************************\");\r\n\t\tdisplay(\"Hi you and welcome on STYF!\");\r\n\t\tdisplay(\"Are you already registred(Y/N)?\");\r\n\t}",
"com.google.protobuf.ByteString getCourseNameBytes();",
"public void setCourseName( String name )\n\t{\n\t\tcourseName = name;\t// store the course name\n\t}",
"public void displayWelcomeMsg();",
"private void showCourseCatalogue()\r\n {\r\n \tCourseCatalogue courseCat = this.getDBManager().getCourseCat();\r\n \tthis.getClientOut().printf(\"SUCCESS\\n%s\\n\", courseCat.toString());\r\n \tthis.getClientOut().flush();\r\n }",
"public java.lang.String getCourseName() {\n\t\t\t\tjava.lang.Object ref = courseName_;\n\t\t\t\tif (!(ref instanceof java.lang.String)) {\n\t\t\t\t\tcom.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;\n\t\t\t\t\tjava.lang.String s = bs.toStringUtf8();\n\t\t\t\t\tcourseName_ = s;\n\t\t\t\t\treturn s;\n\t\t\t\t} else {\n\t\t\t\t\treturn (java.lang.String) ref;\n\t\t\t\t}\n\t\t\t}",
"public String toString() {\r\n\t\tthis.gpaConverter();\r\n\t\treturn (\"Course Name: \" + this.name + \" Credits: \" + this.credithours + \" GPA: \" + this.letterGrade);\r\n\t}",
"public String getPredefinedCourseName() {\n return predefinedCourseName;\n }",
"public java.lang.String getCourseName() {\n\t\t\tjava.lang.Object ref = courseName_;\n\t\t\tif (ref instanceof java.lang.String) {\n\t\t\t\treturn (java.lang.String) ref;\n\t\t\t} else {\n\t\t\t\tcom.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;\n\t\t\t\tjava.lang.String s = bs.toStringUtf8();\n\t\t\t\tcourseName_ = s;\n\t\t\t\treturn s;\n\t\t\t}\n\t\t}",
"@Override\n\tpublic String setCourseName() {\n\t\treturn null;\n\t}",
"public void enroll(String courseName, World world) {\n\t\tCourse course = world.dbCourses().get(courseName);\n\t\tif (course == null) {\n\t\t\tSystem.out.println(\"No course named: \" + courseName);\n\t\t\treturn;\n\t\t}\n\n\t\tList<Course> unfinishedCourses = super.getUnfinishedCourses();\n\t\tList<Course> finishedCourses = super.getFinishedCourses();\n\t\tif (unfinishedCourses.contains(course)) {\n\t\t\tSystem.out.println(\"You are already enrolled in \" + course + \".\");\n\t\t\treturn;\n\t\t}\n\t\tif (finishedCourses.contains(course)) {\n\t\t\tSystem.out.println(\"You have already completed \" + course + \"!\");\n\t\t\treturn;\n\t\t}\n\n\t\tRoom room = super.getRoom();\n\t\tList<Creature> roomCreatures = room.getCreatures();\n\t\tCreature creature;\n\t\tfor (int i = 0; i < roomCreatures.size(); i++) {\n \tcreature = roomCreatures.get(i);\n \tif (creature.isTeacher()) {\n \t\tTeacher teacher = (Teacher) creature;\n \t\tif (teacher.getCourse().equals(course)) { // Check that teacher for course is in room\n \t\t\tunfinishedCourses.add(course);\n \t\t\tSystem.out.println(\"You have enrolled in '\" + course + \"'.\");\n \t\t\treturn;\n \t\t}\n \t}\n\t\t}\n\t\tSystem.out.println(\"No teacher who teaches '\" + course + \"' in the room.\");\n\t}",
"String getWelcometext();",
"public static String getWelcomeMessage() {\n return \"Welcome to Kim Jong Un's Secret Chat. You can call me RocketMan and please let me know how to help!\";\n }",
"public static int welcomeUser(){\n \n int answer;\n JOptionPane.showMessageDialog(null, \"Welcome to Rock, Paper, Scissors, Lizard, Spock!\");\n JOptionPane.showMessageDialog(null, \"In this twist of the popular Rock, Paper, Scissors game a\"+\n \"\\nlizard and Captain Spock join in the epic battle of decision making.\");\n JOptionPane.showMessageDialog(null, \"The rules are as follows: \\nRock beats Scissors. \\nScissors beats Paper.\"+\n \"\\nPaper beats Rock. \\nLizard poisons Spock. \\nSpock vaporizes Rock. \"+\n \"\\nScissors decapitates Lizard. \\nLizard eats Paper. \\nRock smashes Lizard\"+\n \"\\nSpock smashes Scissors.\\nPaper disproves Spock.\");\n JOptionPane.showMessageDialog(null, \"Enter a R for rock,\"+\"\\nEnter a P for paper,\"+ \n \"\\nEnter an S for scissors\"+ \"\\nEnter an L for Lizard,\"+\n \"\\nEnter an X for Capt. Spock.\");\n \n answer = JOptionPane.showConfirmDialog(null,\"\\n Would you like to play now?\", null, JOptionPane.YES_NO_OPTION);\n return answer;\n }",
"public static void displayWelcomeMessage() {\n\t\tSystem.out.println(\"Welcome to my program! :D\");\n\t\tSystem.out.println(\" Ryan Shupe \");\n\t\tSystem.out.println(\" CSCI 1250-004 Project 3 \");\n\t}",
"public String getWelcomeScreen(){\n\treturn \"Welcome to Prisoners Dilemma\\n\" +\n\t \"(1) Choose desired payoffs for each player\\n\" +\n\t \"(2) Choose strategies for each player.\";\n }",
"public void setCourseName(String courseName) {\n this.courseName = courseName;\n }",
"public void setCourseName(String courseName) {\n this.courseName = courseName;\n }",
"public void setCourseName(String courseName) {\n this.courseName = courseName;\n }",
"public void setCourseName(String courseName) {\n this.courseName = courseName;\n }",
"public void setCourseName( String name )\n {\n courseName = name; // store the course name\n }",
"public String toString() {\r\n return COURSE_ID + \"-\" + COURSE_NAME;\r\n }",
"private void getUserName() {\n if (mAuth.getCurrentUser() != null) {\n nameOfCurrentUser = mAuth.getCurrentUser().getDisplayName();\n Log.d(TAG, \"getUserName: getDisplayName is not null\");\n if (nameOfCurrentUser != null && nameOfCurrentUser.contains(\" \")) {\n String[] nameArray = nameOfCurrentUser.split(\" \");\n personalWelcomeMessage.setText(\"Hello, \" + nameArray[0]);\n Log.d(TAG, \"Name is: \" + personalWelcomeMessage.getText().toString());\n }\n else if (nameOfCurrentUser != null && !nameOfCurrentUser.contains(\" \")) {\n personalWelcomeMessage.setText(\"Hello, \" + nameOfCurrentUser);\n Log.d(TAG, \"Name is: \" + personalWelcomeMessage.getText().toString());\n }\n else if (nameOfCurrentUser==null){\n personalWelcomeMessage.setText(\"Hello\");\n }\n }\n }",
"private String displayUsername() {\n // Get username entered from the previous page and display in the current page\n Intent myIntent = getIntent();\n String nameEntered = myIntent.getStringExtra(\"EditTextValue\");\n String userName = \"Welcome, \" + nameEntered;\n return userName;\n }",
"@AutoEscape\n\tpublic String getCourse();",
"public void setCourseName(String courseName) {\n\t\tCourseName = courseName;\n\t}",
"public static void main(String[] args) {\n JavaCourse java = new JavaCourse(); // subclass of Course.java\n java.printWelcomeMessage();\n java.printName(); \n // You are welcome in Java Course\n }",
"public String getCourseTitle() {\n return courseTitle;\n }",
"public String getCourseName(String course_id) throws SQLException {\n\n String courseName = null;\n String query = String.format(\"SELECT * FROM course WHERE course_id = '%s'\", course_id);\n Statement statement = connection.createStatement();\n try {\n ResultSet result = statement.executeQuery(query);\n if(result.next()){\n courseName = result.getString(\"course_title\");\n }\n return courseName;\n }\n catch (SQLException e) {\n return \"No course for now\";\n }\n\n }",
"public String getCourse() {\n\t\treturn Course;\n\t}",
"public String getcourse() {\n\t\treturn course;\n\t}",
"public void printReport(){\n\t\tSystem.out.println(\"This is \" + name + \", UPENN \" + graduationYear);\n\t\tSystem.out.println(\"Their GPA is \" + GPA);\n\t\tString numCoursesString = \"\";\n\t\tif (numCoursesCompleted == 1){\n\t\t\tnumCoursesString=\"course\";\t//if the student has only taken one course, just print course\n\t\t}\n\t\telse{\n\t\t\tnumCoursesString=\"courses\"; //if the student has taken more than one course, print courses when called\n\t\t}\n\t\tSystem.out.println(\"They have taken \" + numCoursesCompleted + \" \" + numCoursesString); \n\t}",
"private static String courseLine()\n {\n return String.format(STR_FORMAT_1 + STR_FORMAT_2, COURSE_STR, COURSE);\n }",
"@Override\npublic ArrayList<String> courses() {\n\tArrayList<String> studentCourses = new ArrayList<String>();\n\tstudentCourses.add(\"CMPE - 273\");\n\tstudentCourses.add(\"CMPE - 206\");\n\tstudentCourses.add(\"CMPE - 277\");\n\tSystem.out.println(this.name+\" has take these courses\");\n\tfor(int i = 0 ; i < studentCourses.size() ; i++){\n\t\tSystem.out.println( studentCourses.get(i));\n\t}\n\treturn null;\n}",
"public void listOfCourses() {//admin cagirisa bulunna kurslarin hepsi\n if (Courses.size() != 0) {\n System.out.printf(\"%s kullanicisinin dersleri\\n\", this.getUsername());\n for (int i = 0; i < this.Courses.size(); ++i) {\n System.out.printf(\"%d-%s\\n\", i, Courses.get(i));\n }\n } else {\n System.out.printf(\"%s kullanicinin dersi yok\\n\", this.getUsername());\n }\n }",
"public com.google.protobuf.ByteString getCourseNameBytes() {\n\t\t\tjava.lang.Object ref = courseName_;\n\t\t\tif (ref instanceof java.lang.String) {\n\t\t\t\tcom.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);\n\t\t\t\tcourseName_ = b;\n\t\t\t\treturn b;\n\t\t\t} else {\n\t\t\t\treturn (com.google.protobuf.ByteString) ref;\n\t\t\t}\n\t\t}",
"public com.google.protobuf.ByteString getCourseNameBytes() {\n\t\t\t\tjava.lang.Object ref = courseName_;\n\t\t\t\tif (ref instanceof String) {\n\t\t\t\t\tcom.google.protobuf.ByteString b = com.google.protobuf.ByteString\n\t\t\t\t\t\t\t.copyFromUtf8((java.lang.String) ref);\n\t\t\t\t\tcourseName_ = b;\n\t\t\t\t\treturn b;\n\t\t\t\t} else {\n\t\t\t\t\treturn (com.google.protobuf.ByteString) ref;\n\t\t\t\t}\n\t\t\t}",
"private void showStudentCourses()\r\n {\r\n \tString courseResponse = \"\";\r\n \tfor(Course course : this.getDBManager().getStudentCourses(this.studentId))\r\n \t{\r\n \t\tcourseResponse += \"Course Faculty: \" + course.getCourseName() + \", Course Number: \" + String.valueOf(course.getCourseNum()) + \"\\n\";\r\n \t}\r\n \tthis.getClientOut().printf(\"SUCCESS\\n%s\\n\", courseResponse);\r\n \tthis.getClientOut().flush();\r\n }",
"public void loadIntroMessage() {\n\n\t\tmessageToDisplay.add(ArtemisCalendar.getMonthName(ArtemisCalendar.getCalendar().get(2)) + \", \"\n\t\t\t\t+ ArtemisCalendar.getCalendar().get(1) + \".\");\n\n\t\tmessageToDisplay.add(\"NASA have chosen you to help them deliver The Artemis Project successfully.\");\n\t\tmessageToDisplay.add(\"The Project aims to launch the first woman, and next man to the moon by \"\n\t\t\t\t+ ArtemisCalendar.getMonthName(ArtemisCalendar.getEndDate().get(2)) + \", \"\n\t\t\t\t+ ArtemisCalendar.getEndDate().get(1) + \".\");\n\t\tmessageToDisplay.add(\n\t\t\t\t\"In order to accomplish this lofty goal, you must work alongside other chosen companies to ensure 'All Systems are Go!' by launch-day.\");\n\t\tmessageToDisplay.add(\n\t\t\t\t\"Can you work together to research and fully develop all of the systems needed for a successful Lift-off?\");\n\t\tmessageToDisplay.add(\"...or will your team just be in it for personal gain?\");\n\t\tmessageToDisplay.add(\"You decide!\");\n\t\tGameLauncher.displayMessage();\n\t}",
"public void printName()\n\t{\t\t\n\t\t//check if we know the name of the professor\n\t\tif(this.firstName == null || this.surname == null ||\n\t\t\tthis.firstName.isEmpty() || this.surname.isEmpty())\n\t\t{\n\t\t\t//We haven't learned exception throwing yet, so let's just output something and return :'(\n\t\t\tSystem.out.println(\"Error: This Professor is nameless, I'm sorry :(\");\n\t\t\treturn;\n\t\t}\n\t\t\n\t\tSystem.out.println(String.format(\"\", this.firstName, this.surname));\n\t}",
"public void intro()\n\t{\n\t\tname = \"daryl\";\n\t\tSystem.out.println(\"Welcome to classroom hang man.\");\n\t\tSystem.out.println(\"In this game, you will get to guess 3 letters, while\");\n\t\tSystem.out.println(\"trying to figure out whose name it is in this classroom.\");\n\t\tSystem.out.println(\"After you've guessed 3 letters, you will get 1 guess at\");\n\t\tSystem.out.println(\"whose name it actually is.\");\n\t}",
"public String printStudentCourses() {\r\n String s = \"Completed courses: \\n\";\r\n for (Registration r : completeCourses) {\r\n s += r.toString();\r\n }\r\n s += \"Current courses: \\n\";\r\n for (Registration r : studentRegList) {\r\n s += r.toString();\r\n }\r\n s += \"\\0\";\r\n return s;\r\n }",
"public static void welcome(){\n\n System.out.print(\"Welcome to the Human Resources Management System.\"+\n \"\\nThis program allows you to add new employees and print all employees.\");\n \n }",
"@Override\n\tpublic String getWelcomeMessage() {\n\t\treturn null;\n\t}",
"protected abstract void displayWelcome();",
"private String returnToWelcome(Severity severity, String message) {\n\t\tMessages.addMessage(severity, message);\n\t\tFacesContext.getCurrentInstance().getExternalContext().getSessionMap().remove(\"conclude_dc\");\n\t\treturn \"welcome.xhtml\";\n\t}",
"public void courseInfo() {\n\t\tList<Course> unfinishedCourses = super.getUnfinishedCourses();\n\t\tList<Course> finishedCourses = super.getFinishedCourses();\n\n\t\tString retStr = \"Unfinished Courses: \";\n\t\tfor (int i = 0; i < unfinishedCourses.size(); i++) {\n \tretStr += unfinishedCourses.get(i);\n \tif (i != unfinishedCourses.size()-1) {\n\t\t\t\tretStr += \", \";\n \t}\n\t\t}\n\t\tretStr += \"\\nFinished Courses: \";\n\t\tfor (int i = 0; i < finishedCourses.size(); i++) {\n \tretStr += finishedCourses.get(i);\n \tif (i != finishedCourses.size()-1) {\n\t\t\t\tretStr += \", \";\n \t}\n\t\t}\n\t\tretStr += \"\\nHP: \" + this.hp;\n\t\tSystem.out.println(retStr);\n\t}",
"public static void WelcomeMessage () {\n System.out.println(\"===============================================\");\r\n System.out.println(\" C O M P U T E R\");\r\n System.out.println(\" S C I E N C E\");\r\n System.out.println(\" R O U L E T T E\");\r\n System.out.println(\"====================================== v1.2 ===\");\r\n System.out.println();\r\n }",
"public String getScoreboardName() {\n/* 1999 */ return getGameProfile().getName();\n/* */ }",
"public void makeNameTitle(Course course, JPanel singleCoursePanel, SpringLayout layout) {\n JLabel nameTitle = new JLabel(course.courseName + \" Profile\", JLabel.CENTER);\n nameTitle.setFont(new Font(\"Proxima Nova\", Font.BOLD, 17));\n singleCoursePanel.add(nameTitle);\n layout.putConstraint(SpringLayout.WEST, nameTitle, 30, SpringLayout.WEST, singleCoursePanel);\n layout.putConstraint(SpringLayout.NORTH, nameTitle, 15, SpringLayout.NORTH, singleCoursePanel);\n }",
"public GradeBook (String name){ //Constructor\n\t\tcourseName=name;\n//\t\tstudents = studentNum;\n\t}",
"@Override\n\t\t\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\t\t\tJOptionPane.showMessageDialog(frame,\"Nome Atual: \" + userName);\n\t\t\t\t\t}",
"public static void message() {\r\n\t\t\r\n\t\tJOptionPane.showMessageDialog(null, \"Thanks for your participation\" + \"\\nHave a great day!\");\r\n\t\t\r\n\t\t\r\n\t}",
"void getInfo() {\n\tSystem.out.println(\"My name is \"+name+\" and I am going to \"+school+\" and my grade is \"+grade);\n\t}",
"String usernameLabel();",
"private void printWelcome()\n {\n System.out.println();\n System.out.println(\"Welcome to Hammerfell\");\n System.out.println(\"Hammerfell is an unforgiving, lonely world, brimming with monsters, theieves, and death.\");\n System.out.println(\"For years, Malice has plagued the land. Turning what once was a world gleaming with hope and prosperity into a desolate waste land.\");\n System.out.println(\"You will surely not make it out alive, and your death will most likely end in the brutal whipping and nashing of teeth from your enemies.\");\n System.out.println(\"Good Luck :)\");\n System.out.println(\"Type 'help' if you need help.\");\n System.out.println(\"Name is set to Greggory. If you desire to change it, type name.\");\n System.out.println();\n System.out.println(currentRoom.getLongDescription());\n }",
"@ResponseBody\n @RequestMapping(value = \"/bookcourse\", method = RequestMethod.GET)\n public int bookCourse(@RequestParam(\"USERNAME\") String username,\n @RequestParam(\"EXCOURSEID\") String exCourseId) {\n int CID=Integer.parseInt(exCourseId);\n dbManager.initializeDatabase();\n int status=dbManager.bookStudentOnCourse(username,CID);\n dbManager.closeDatabase();\n return status;\n }",
"public FinishedCourse(String name)\n\t{\n\t\tsuper (name);\n\t\t_grade = Grades.O;\n\t\t_passed = false;\n\t\t\n\t\t\n\t}",
"@Override\r\n public void handleCommand(CommandEvent event) {\n if(event.getArgs().length < 2){\r\n event.reply(\"Please specify: Course Code, Course Name\");\r\n return;\r\n }\r\n // Check if Admin\r\n if(!event.getMember().hasPermission(Permission.ADMINISTRATOR)) {\r\n event.reply(\"You must me an Admin to run this command.\");\r\n event.reactFailure();\r\n return;\r\n }\r\n\r\n // TODO: Add record to 'courses'\r\n // Short Name\r\n // Long Name\r\n // Self Enroll (Default: False)\r\n\r\n\r\n }",
"public F returnCourse(String studentID){}",
"private void retrieveStudentsEnrolledForACourse() {\n Scanner sc = new Scanner(System.in);\n Course c;\n while (true) {//Der Kursname sollte existieren\n System.out.print(\"Course ID: \");\n Long id = Long.parseLong(sc.next());\n c = ctrl.getCourse(id);\n if (c == null)\n System.out.println(\"Course with this ID doesn't exist! Please try again!\");\n else\n break;\n }\n\n //Wir rufen die eingeschriebenen Studenten Funktion von dem Controller\n System.out.println(\"Students enrolled for the course: \");\n ctrl.retrieveStudentsEnrolledForACourse(c);\n }",
"private void printWelcome()//Method was given\n {\n System.out.println();\n System.out.println(\"Welcome to Zork!\");\n System.out.println(\"This Zork is a new adventure game. Find your way through the building and get to the exit by solving riddles and escaping each room. Good luck!\");\n System.out.println(\"Type 'help' to see a list of command words that you can use to play the game.\");\n System.out.println();\n System.out.println(currentRoom.longDescription());\n }",
"public void askCourseDetails() {\n\t\t\n\t\tString courseCode, courseName, facultyName;\n\t\tint courseVacancy = 10;\n\t\n\t\t\n\t\tSystem.out.println(\"-------The current faculties are-------\");\n\t\tfacultyNameList = acadCtrl.getFacultyNameList();\n\t\tfor(String fName : facultyNameList) {\n\t\t\tSystem.out.println(fName);\n\t\t}\n\t\twhile(true)\n\t\t{\n\t\t\tSystem.out.println(\"Enter faculty name: \");\n\t\t\tfacultyName = sc.nextLine().toUpperCase();\n\t\t\t\n\t\t\t//check if input data of faculty is correct\n\t\t\tif(checkFacName(facultyName)) {\n\t\t\t\tfacultyNameList.add(facultyName);\n\t\t\t\tbreak;\n\t\t\t}\n\t\t\telse System.out.println(\"Wrong faculty Name\");\n\t\t}\n\t\t\n\t\t\n\t\tcourseCodeList = acadCtrl.getCourseCodeList(facultyName);\n\t\tSystem.out.println(\"The current course codes are \");\n\t\tfor(String code : courseCodeList) {\n\t\t\tSystem.out.println(code);\n\t\t}\n\t\tSystem.out.println(\"Enter course code: \");\n\t\tcourseCode = sc.nextLine().toUpperCase();\n\t\t\n\t\t\n\t\tif(checkCourseCode(courseCode)) {\n\t\t\tSystem.out.println(\"Course code already exists. \\n Please try again\");\n\t\t\tcourseCode = sc.nextLine().toUpperCase();\n\t\t\tcourseCodeList.add(courseCode);\n\t\t}else courseCodeList.add(courseCode);\n\t\t\n\t\t\n\t\tcourseNameList = acadCtrl.getCourseNameList(facultyName);\n\t\tSystem.out.println(\"The current course names are \");\n\t\tfor(String name : courseNameList) {\n\t\t\tSystem.out.println(name);\n\t\t}\n\t\tSystem.out.println(\"Enter course name: \");\n\t\t\n\t\tcourseName = sc.nextLine().toUpperCase();\n\t\t\n\t\tif(checkCourseName(courseName)) {\n\t\t\tSystem.out.println(\"Course name already exists. \\n Please try again\");\n\t\t}else courseNameList.add(courseName);\n\t\t\n\t\t\n\t\t\n\t\tSystem.out.println(\"Choose your available professors\");\n\t\tprofNameList = acadCtrl.getProfessorNameList(facultyName);\n\t\tfor(String p : profNameList) {\n\t\t\tSystem.out.println(p);\n\t\t}\n\t\tSystem.out.println(\"Enter the professor's staff name\"); //input validation\n\t\tString ProfName = sc.nextLine();\n\t\t\n\t\tif(!CheckProfName(ProfName)) {\n\t\t\tSystem.out.println(\"Enter correct professor's name\");\n\t\t\tProfName = sc.nextLine();\n\t\t}\n\t\t\n\t\t// want to add if he's the coordinator?\n\t\t// input who is the coordinator\n\t\tSystem.out.println(\"Is he the course coordinator? Y for Yes / N for No\");\n\t\tchar yn = sc.nextLine().charAt(0);\n\n\t\tif(yn == 'Y' || yn == 'y') {\n\t\t\t// set ProfName to course coord\n\t\t\tacadCtrl.getProfessor(facultyName, ProfName).setCourseCoordinator(true);\n\t\t\tcourseCoordList.add(ProfName);\n\t\t}\n\t\telse if (yn == 'N' || yn == 'n') {\n\t\t\tSystem.out.println(\"Who is the course coordinator for the course?\");\n\t\t\tSystem.out.println();\n\t\t\tfor(String p : profNameList) {\n\t\t\t\tSystem.out.println(p);\n\t\t\t}\n\t\t\t// for course coord\n\t\t\tSystem.out.println(\"Enter the professor's staff name\"); //input validation\n\t\t\tString profNameCoord = sc.nextLine();\n\t\t\t\n\t\t\tif(!CheckProfName(profNameCoord)) {\n\t\t\t\tSystem.out.println(\"Enter correct professor's name\");\n\t\t\t\tprofNameCoord = sc.nextLine();\n\t\t\t\tacadCtrl.getProfessor(facultyName, profNameCoord).setCourseCoordinator(true);\n\t\t\t\tcourseCoordList.add(profNameCoord);\n\t\t\t}\n\t\t\tacadCtrl.getProfessor(facultyName, profNameCoord).setCourseCoordinator(true);\n\t\t\tcourseCoordList.add(profNameCoord);\n\t\t\t\n\t\t}\n\t\t\n\t\t\n\t\tSystem.out.println(\"Enter course Vacancy\");\n\t\tif(sc.hasNextInt()) {\n\t\t\tcourseVacancy = sc.nextInt();\n\t\t}else System.out.println(\"Enter only integers\");\n\t\t\n\t\tString dummy = sc.nextLine(); // dummy scan changes from sc int to string\n\t\t\n\t\tSystem.out.println(\"Lectures only? Y for Yes / N for No\");\n\t\tchar input = sc.nextLine().charAt(0);\n\n\t\tif(input == 'Y' || input == 'y') {\n\t\t\t// creation of course object, by default only exam, only 1 lecture\n\t\t\tacadCtrl.passCourseDetails(courseCode, courseName, facultyName, courseVacancy, ProfName); \n\t\t}\n\t\telse if (input == 'N' || input == 'n') {\n\t\t\t\n\t\t\tint tutVacancy = 0;\n\t\t\t\n\t\t\tSystem.out.println(\"Is there tutorial? Y for Yes / N for No\");\n\t\t\tinput = sc.nextLine().charAt(0);\n\t\t\t\n\t\t\tif (input == 'Y'|| input == 'y') {\n\t\t\t\t\n\t\t\t\tSystem.out.println(\"What is the class vacancy for each group?\");\t\n\t\t\t\tif(sc.hasNextInt()) {\n\t\t\t\t\ttutVacancy = sc.nextInt(); // total tutorial vacancy > lecture size OK!\n\t\t\t\t}\n\t\t\t\ttutGroups = addTutorial(tutVacancy);\n\t\t\t\n\t\t\t\tdummy = sc.nextLine();\n\t\t\t\t\n\t\t\t\tSystem.out.println(\"Is there Lab? Y for Yes / N for No\");\n\t\t\t\tinput = sc.nextLine().charAt(0);\n\t\t\t\t\n\t\t\t\tif(input == 'Y'|| input == 'y') {\n\t\t\t\t\tSystem.out.println(\"Lab group is same as Lecture group\");\n\t\t\t\t\t// creation of course object, with tutorials and lab group\n\t\t\t\t\tacadCtrl.passCourseDetailsWithTutorial(courseCode, courseName, facultyName, courseVacancy, ProfName, tutGroups, true, tutVacancy);\n\t\t\t\n\t\t\t\t}\n\t\t\t\telse if(input == 'N'|| input == 'n') {\n\t\t\t\t\t// creation of course object, with tutorials only\n\t\t\t\t\tacadCtrl.passCourseDetailsWithTutorial(courseCode, courseName, facultyName, courseVacancy, ProfName, tutGroups, false, tutVacancy);\n\t\t\t\t}\n\t\t\t\telse System.out.println(\"Please Enter Y or N only\");\n\t\t\t}\n\t\t}else System.out.println(\"Please Enter Y or N only\");\n\t\t\n\t\t//done and print\n\t\t\n\t\tSystem.out.println(\"Course added to System!\");\n\t\tSystem.out.println(\"The current Lists of courses in \"+ facultyName + \" is: \");\n\t\tprintCourses();\n\t\tSystem.out.println(\"To add sub components into Course Work use function 6 \");\n\t\tSystem.out.println();\n\t}",
"private void printWelcomeMessage() {\r\n\t\tthis.printSeparator();\r\n\t\tSystem.out.println(\"-- Welcome to the JumpIN game --\\n\");\r\n\t\tSystem.out.println(\"Currently five levels are developed.\");\r\n\t\tSystem.out.println(\"Playing level 2\");\r\n\t\tSystem.out.println(\"To move a piece:\"); \r\n\t\tSystem.out.println(\"-Enter the piece's location\");\r\n\t\tSystem.out.println(\"-Wait for validation\");\r\n\t\tSystem.out.println(\"-Enter the location you want to move the piece to\\n\");\r\n\t\tthis.printSeparator();\r\n\t}",
"private String greeting() {\n\t\tanswerUser = null;\n\t\tquestionBot.put(owner.id(), WELCOME);\n\n\t\treturn buildMessage(\"Olá, \" + owner.firstName() + \"! \" + WELCOME);\n\t}",
"public String printNewUsernamePrompt() {\n return \"Please enter new username: \";\n }",
"public void printGrades() {\r\n for(String course : courses.keySet()) {\r\n \t System.out.printf(\"Student with facN: %s has taken course %s with grade of %.2f\\n\\n\",\r\n \t\t\t this.facultyNumber, course, courses.get(course));\r\n }\r\n }",
"public String getCourseID() {\r\n return COURSE_ID;\r\n }",
"public String completePrint(Player winner, int startup, Game game, CompleteCard e) {\n String s = winner.getName() +\" completed a Capital\";\n if(game.game_over && game.main_deck.size() == 0){\n s+= \", ending the game.\";\n }else{\n s+= \" and drew a \" + winner.getHand().getCard(winner.getHand().size()-1).name + \".\";\n }\n return s;\n }",
"public void messageToUser() {\n // show a message dialog - the message is an error message.\n JOptionPane.showMessageDialog(new JFrame(),\n \"You are missing some parameters in the level definitions, Please check it\", \"Error!\",\n JOptionPane.ERROR_MESSAGE);\n // exit the program\n System.exit(0);\n }",
"public String getCollegeName() {\n return collegeName;\n }"
] | [
"0.76477134",
"0.74215907",
"0.72655773",
"0.7140961",
"0.7086814",
"0.6891359",
"0.6802095",
"0.6682723",
"0.6594075",
"0.6560326",
"0.65282387",
"0.6501189",
"0.64980036",
"0.64980036",
"0.64980036",
"0.64918643",
"0.6472803",
"0.6468747",
"0.63967",
"0.63887215",
"0.6377609",
"0.6373717",
"0.6341535",
"0.63021433",
"0.626558",
"0.6261652",
"0.61999524",
"0.61867744",
"0.6184635",
"0.6163733",
"0.6155172",
"0.6143818",
"0.60973495",
"0.6081748",
"0.607419",
"0.60458297",
"0.6044707",
"0.60107887",
"0.60074854",
"0.5985138",
"0.5960419",
"0.5959825",
"0.59482205",
"0.59139097",
"0.58535314",
"0.58526695",
"0.58526695",
"0.58526695",
"0.58526695",
"0.5842914",
"0.58247375",
"0.5805523",
"0.58003306",
"0.57975036",
"0.5792876",
"0.57687175",
"0.5758875",
"0.5755299",
"0.5750568",
"0.5742515",
"0.5732437",
"0.5730677",
"0.5729702",
"0.5728106",
"0.57015646",
"0.56977046",
"0.5660956",
"0.56447285",
"0.5633359",
"0.5627369",
"0.5625547",
"0.5621242",
"0.55989677",
"0.55982625",
"0.55718136",
"0.5567042",
"0.554145",
"0.5540683",
"0.5536801",
"0.5527111",
"0.55268884",
"0.5523967",
"0.5497861",
"0.5492817",
"0.548336",
"0.5476509",
"0.54588985",
"0.5458549",
"0.5454297",
"0.5440626",
"0.5438354",
"0.54358613",
"0.5430745",
"0.5430252",
"0.5428146",
"0.54257286",
"0.54004705",
"0.5397664",
"0.53936523",
"0.53914076"
] | 0.7218843 | 3 |
Inflate the layout for this fragment | @Override
public View onCreateView(LayoutInflater inflater, ViewGroup container,
Bundle savedInstanceState) {
View view = inflater.inflate(R.layout.fragment_bus_single_item_shop, container, false);
AndroidSupportInjection.inject(this);
ButterKnife.bind(this, view);
//TODO take care of the progressBar
return view;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_main_allinfo, container, false);\n }",
"@Override\r\n\tpublic View onCreateView(LayoutInflater inflater, ViewGroup container,\r\n\t\t\tBundle savedInstanceState) {\n\t\treturn inflater.inflate(R.layout.wallpager_layout, null);\r\n\t}",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_invit_friends, container, false);\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View inflate = inflater.inflate(R.layout.fragment_zhuye, container, false);\n initView(inflate);\n initData();\n return inflate;\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup parent, Bundle savedInstanceState) {\n // Defines the xml file for the fragment\n return inflater.inflate(R.layout.fragment_posts, parent, false);\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {\n return inflater.inflate(R.layout.ilustration_fragment, container, false);\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View v = inflater.inflate(R.layout.fragment_sow_drug_cost_per_week, container, false);\n\n db = new DataBaseAdapter(getActivity());\n hc = new HelperClass();\n pop = new FeedSowsFragment();\n\n infltr = (LayoutInflater) getActivity().getSystemService(Context.LAYOUT_INFLATER_SERVICE);\n parent = (LinearLayout) v.findViewById(R.id.layout_for_add);\n tvTotalCost = (TextView) v.findViewById(R.id.totalCost);\n\n getData();\n setData();\n\n return v;\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_stream_list, container, false);\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View v = inflater.inflate(R.layout.fragment_event, container, false);\n\n\n\n\n\n\n\n\n return v;\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_feed, container, false);\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.screen_select_list_student, container, false);\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View rootView = inflater.inflate(R.layout.fragment_overall, container, false);\n mNamesLayout = (LinearLayout) rootView.findViewById(R.id.fragment_overall_names_layout);\n mOverallView = (OverallView) rootView.findViewById(R.id.fragment_overall_view);\n return rootView;\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState)\n {\n\n\n view = inflater.inflate(R.layout.fragment_earning_fragmant, container, false);\n ini(view);\n return view;\n }",
"@Nullable\n @Override\n public View onCreateView(LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) {\n super.onCreateView(inflater, container, savedInstanceState);\n final View rootview = inflater.inflate(R.layout.activity_email_frag, container, false);\n ConfigInnerElements(rootview);\n return rootview;\n }",
"@Override\r\n\tpublic View onCreateView(LayoutInflater inflater, ViewGroup container,\r\n\t\t\tBundle savedInstanceState) {\n\t\trootView = inflater.inflate(R.layout.fragment_attack_armor, container, false);\r\n\r\n\t\tfindInterfaceElements();\r\n\t\taddRangeSelector();\r\n\t\tupdateHeadings();\r\n\t\tsetListeners();\r\n\r\n\t\tsetFromData();\r\n\r\n\t\treturn rootView;\r\n\t}",
"@SuppressLint(\"InflateParams\")\r\n\t@Override\r\n\tpublic View initLayout(LayoutInflater inflater) {\n\t\tView view = inflater.inflate(R.layout.frag_customer_all, null);\r\n\t\treturn view;\r\n\t}",
"@Override\r\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\r\n Bundle savedInstanceState) {\n view = inflater.inflate(R.layout.fragment_fore_cast, container, false);\r\n initView();\r\n mainLayout.setVisibility(View.GONE);\r\n apiInterface = RestClinet.getClient().create(ApiInterface.class);\r\n loadData();\r\n return view;\r\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_friend, container, false);\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n rootView = inflater.inflate(R.layout.fragment_detail, container, false);\n image = rootView.findViewById(R.id.fr_image);\n name = rootView.findViewById(R.id.fr_name);\n phoneNumber = rootView.findViewById(R.id.fr_phone_number);\n email = rootView.findViewById(R.id.fr_email);\n street = rootView.findViewById(R.id.fr_street);\n city = rootView.findViewById(R.id.fr_city);\n state = rootView.findViewById(R.id.fr_state);\n zipcode = rootView.findViewById(R.id.fr_zipcode);\n dBrith = rootView.findViewById(R.id.date_brith);\n return rootView;\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_pm25, container, false);\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_kkbox_playlist, container, false);\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View rootView = inflater.inflate(R.layout.fragment_feed_pager, container, false);\n\n// loadData();\n\n findViews(rootView);\n\n setViews();\n\n return rootView;\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {\n layout = (FrameLayout) inflater.inflate(R.layout.fragment_actualites, container, false);\n\n relLayout = (RelativeLayout) layout.findViewById(R.id.relLayoutActus);\n\n initListView();\n getXMLData();\n\n return layout;\n }",
"@Nullable\n @Override\n public View onCreateView(LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) {\n rootView = inflater.inflate(R.layout.frag_post_prayer_video, container, false);\n setCustomDesign();\n setCustomClickListeners();\n return rootView;\n }",
"@Override\n\tpublic View onCreateView(LayoutInflater inflater, ViewGroup container,\n\t\t\tBundle savedInstanceState) {\n\t\treturn inflater.inflate(R.layout.lf_em4305_fragment, container, false);\n\t}",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_recordings, container, false);\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View view=inflater.inflate(R.layout.fragment_category, container, false);\n initView(view);\n bindRefreshListener();\n loadParams();\n return view;\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_cm_box_details, container, false);\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n view=inflater.inflate(R.layout.fragment_layout12, container, false);\n\n iniv();\n\n init();\n\n return view;\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n view = inflater.inflate(R.layout.fragment_details, container, false);\n //return inflater.inflate(R.layout.fragment_details, container, false);\n getIntentValues();\n initViews();\n return view;\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_mem_body_blood, container, false);\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_qiugouxiaoxi, container, false);\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View inflate = inflater.inflate(R.layout.fragment_coll_blank, container, false);\n initView(inflate);\n initData();\n return inflate;\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View view = inflater.inflate(R.layout.fragment_attendance_divide, container, false);\n\n initView(view);\n return view;\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup parent, Bundle savedInstanceState) {\n // Defines the xml file for the fragment\n return inflater.inflate(R.layout.show_program_fragment, parent, false);\n }",
"@Override\n public View onCreateView(@NonNull LayoutInflater inflater, @Nullable ViewGroup container,\n @Nullable Bundle savedInstanceState) {\n return inflater.inflate(R.layout.visualization_fragment, container, false);\n\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n rootView = inflater.inflate(R.layout.fragment_category_details_page, container, false);\n initializeAll();\n\n return rootView;\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n final View v = inflater.inflate(R.layout.fragemnt_reserve, container, false);\n\n\n\n\n return v;\n }",
"protected int getLayoutResId() {\n return R.layout.activity_fragment;\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_all_quizs, container, false);\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n role = getArguments().getInt(\"role\");\n rootview = inflater.inflate(R.layout.fragment_application, container, false);\n layout = rootview.findViewById(R.id.patentDetails);\n progressBar = rootview.findViewById(R.id.progressBar);\n try {\n run();\n } catch (IOException e) {\n e.printStackTrace();\n }\n return rootview;\n }",
"@Override\n\tpublic View onCreateView(LayoutInflater inflater, ViewGroup container,\n\t\t\tBundle savedInstanceState) {\n\t\tview = inflater.inflate(R.layout.fragment_zhu, null);\n\t\tinitView();\n\t\tinitData();\n\t\treturn view;\n\t}",
"@Override\n\t\tpublic View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState)\n\t\t{\n\t\t\tView rootView = inflater.inflate(R.layout.maimfragment, container, false);\n\t\t\treturn rootView;\n\t\t}",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n // Inflate the layout for this fragment\n return inflater.inflate(R.layout.fragment__record__week, container, false);\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_porishongkhan, container, false);\n\n\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View view = inflater.inflate(R.layout.fragment_dashboard, container, false);\n resultsRv = view.findViewById(R.id.db_results_rv);\n resultText = view.findViewById(R.id.db_search_empty);\n progressBar = view.findViewById(R.id.db_progressbar);\n lastVisitText = view.findViewById(R.id.db_last_visit);\n return view;\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View view = inflater.inflate(getLayoutId(), container, false);\n init(view);\n return view;\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n view = inflater.inflate(R.layout.fragment_feedback, container, false);\n self = getActivity();\n initUI(view);\n initControlUI();\n initData();\n return view;\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View v = inflater.inflate(R.layout.fragment_service_summery, container, false);\n tvVoiceMS = v.findViewById(R.id.tvVoiceValue);\n tvDataMS = v.findViewById(R.id.tvdataValue);\n tvSMSMS = v.findViewById(R.id.tvSMSValue);\n tvVoiceFL = v.findViewById(R.id.tvVoiceFLValue);\n tvDataBS = v.findViewById(R.id.tvDataBRValue);\n tvTotal = v.findViewById(R.id.tvTotalAccountvalue);\n return v;\n }",
"@Override\r\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\r\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_clan_rank_details, container, false);\r\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_star_wars_list, container, false);\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View inflate = inflater.inflate(R.layout.fragment_lei, container, false);\n\n initView(inflate);\n initData();\n return inflate;\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_quotation, container, false);\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_wode_ragment, container, false);\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup parent, Bundle savedInstanceState) {\n\n\n\n\n\n return inflater.inflate(R.layout.fragment_appoint_list, parent, false);\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {\n if (rootView == null) {\n rootView = inflater.inflate(R.layout.fragment_ip_info, container, false);\n initView();\n }\n return rootView;\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_offer, container, false);\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_rooms, container, false);\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {\n\n View view = inflater.inflate(R.layout.fragment_img_eva, container, false);\n\n getSendData();\n\n initView(view);\n\n initData();\n\n return view;\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) {\n View view = inflater.inflate(R.layout.fragment_project_collection, container, false);\n ButterKnife.bind(this, view);\n fragment = this;\n initView();\n getCollectionType();\n // getCategoryList();\n initBroadcastReceiver();\n return view;\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n view = inflater.inflate(R.layout.fragment_yzm, container, false);\n initView(view);\n return view;\n }",
"@Override\r\n\tpublic View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {\n\t\tmainLayout = inflater.inflate(R.layout.fragment_play, container, false);\r\n\t\treturn mainLayout;\r\n\t}",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n view = inflater.inflate(R.layout.fragment_invite_request, container, false);\n initialiseVariables();\n return view;\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {\n getLocationPermission();\n return inflater.inflate(R.layout.centrum_fragment, container, false);\n\n\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View rootView = inflater.inflate(R.layout.fragment_habit_type_details, container, false);\n\n habitTitle = rootView.findViewById(R.id.textViewTitle);\n habitReason = rootView.findViewById(R.id.textViewReason);\n habitStartDate = rootView.findViewById(R.id.textViewStartDate);\n habitWeeklyPlan = rootView.findViewById(R.id.textViewWeeklyPlan);\n\n return rootView;\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View v = inflater.inflate(R.layout.fragment_information_friends4, container, false);\n\n if (getArguments() != null) {\n FriendsID = getArguments().getString(\"keyFriends\");\n }\n\n return v;\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_post_details, container, false);\n\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_hotel, container, false);\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n view=inflater.inflate(R.layout.fragment_bus_inquiry, container, false);\n initView();\n initData();\n initDialog();\n getDataFromNet();\n return view;\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_weather, container, false);\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_srgl, container, false);\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n view = inflater.inflate(R.layout.fragment_ground_detail_frgment, container, false);\n init();\n return view;\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_book_appointment, container, false);\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n view = inflater.inflate(R.layout.fragment_wheretogo, container, false);\n ids();\n setup();\n click();\n return view;\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n binding = DataBindingUtil\n .inflate(inflater, R.layout.fragment_learning_leaders, container, false);\n init();\n\n return rootView;\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {\n View view = inflater.inflate(R.layout.fragment_end_game_tab, container, false);\n\n setupWidgets();\n setupTextFields(view);\n setupSpinners(view);\n\n // Inflate the layout for this fragment\n return view;\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {\n View view = inflater.inflate(R.layout.memoir_fragment, container, false);\n\n getUserIdFromSharedPref();\n configureUI(view);\n configureSortSpinner();\n configureFilterSpinner();\n\n networkConnection = new NetworkConnection();\n new GetAllMemoirTask().execute();\n\n return view;\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_jadwal, container, false);\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n view = inflater.inflate(R.layout.fragment_delivery_detail, container, false);\n initialise();\n\n\n\n return view;\n }",
"@Nullable\n @Override\n public View onCreateView(LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_4, container, false);\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_all_product, container, false);\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_group_details, container, false);\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View view = inflater.inflate(R.layout.fragment06_7, container, false);\n initView(view);\n setLegend();\n setXAxis();\n setYAxis();\n setData();\n return view;\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_downloadables, container, false);\n }",
"@Override\n public View onCreateView(@NonNull LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.movie_list_fragment, container, false);\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_like, container, false);\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_hall, container, false);\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {\n View view = inflater.inflate(R.layout.fragment_unit_main, container, false);\n TextView mTxvBusinessAassistant = (TextView) view.findViewById(R.id.txv_business_assistant);\n TextView mTxvCardINformation = (TextView) view.findViewById(R.id.txv_card_information);\n RelativeLayout mRelOfficialWebsite = (RelativeLayout) view.findViewById(R.id.rel_official_website);\n RelativeLayout mRelPictureAblum = (RelativeLayout) view.findViewById(R.id.rel_picture_album);\n TextView mTxvQrCodeCard = (TextView) view.findViewById(R.id.txv_qr_code_card);\n TextView mTxvShareCard = (TextView) view.findViewById(R.id.txv_share_card);\n mTxvBusinessAassistant.setOnClickListener(this.mOnClickListener);\n mTxvCardINformation.setOnClickListener(this.mOnClickListener);\n mRelOfficialWebsite.setOnClickListener(this.mOnClickListener);\n mRelPictureAblum.setOnClickListener(this.mOnClickListener);\n mTxvQrCodeCard.setOnClickListener(this.mOnClickListener);\n mTxvShareCard.setOnClickListener(this.mOnClickListener);\n return view;\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_moviespage, container, false);\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_s, container, false);\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View view = inflater.inflate(R.layout.fragment_overview, container, false);\n\n initOverviewComponents(view);\n registerListeners();\n initTagListener();\n return view;\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View view = inflater.inflate(R.layout.fragment_bahan_ajar, container, false);\n initView(view);\n return view;\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {\n root = (ViewGroup) inflater.inflate(R.layout.money_main, container, false);\n context = getActivity();\n initHeaderView(root);\n initView(root);\n\n getDate();\n initEvetn();\n return root;\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup parent, Bundle savedInstanceState) {\n // Defines the xml file for the fragment\n return inflater.inflate(R.layout.fragment_historical_event, parent, false);\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_event_details, container, false);\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View view = inflater.inflate(R.layout.fragment_video, container, false);\n unbinder = ButterKnife.bind(this, view);\n initView();\n initData();\n return view;\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n\n v= inflater.inflate(R.layout.fragment_post_contacts, container, false);\n this.mapping(v);\n return v;\n }",
"@Nullable\n @Override\n public View onCreateView(LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_measures, container, false);\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View view = inflater.inflate(R.layout.fragment_feed, container, false);\n findViews(view);\n return view;\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_surah_list, container, false);\n }",
"@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_data_binded, container, false);\n }"
] | [
"0.6739604",
"0.67235583",
"0.6721706",
"0.6698254",
"0.6691869",
"0.6687986",
"0.66869223",
"0.6684548",
"0.66766286",
"0.6674615",
"0.66654444",
"0.66654384",
"0.6664403",
"0.66596216",
"0.6653321",
"0.6647136",
"0.66423255",
"0.66388357",
"0.6637491",
"0.6634193",
"0.6625158",
"0.66195583",
"0.66164845",
"0.6608733",
"0.6596594",
"0.65928894",
"0.6585293",
"0.65842897",
"0.65730995",
"0.6571248",
"0.6569152",
"0.65689117",
"0.656853",
"0.6566686",
"0.65652984",
"0.6553419",
"0.65525705",
"0.65432084",
"0.6542382",
"0.65411425",
"0.6538022",
"0.65366334",
"0.65355957",
"0.6535043",
"0.65329415",
"0.65311074",
"0.65310687",
"0.6528645",
"0.65277404",
"0.6525902",
"0.6524516",
"0.6524048",
"0.65232015",
"0.65224624",
"0.65185034",
"0.65130377",
"0.6512968",
"0.65122765",
"0.65116245",
"0.65106046",
"0.65103024",
"0.6509013",
"0.65088093",
"0.6508651",
"0.6508225",
"0.6504662",
"0.650149",
"0.65011525",
"0.6500686",
"0.64974767",
"0.64935696",
"0.6492234",
"0.6490034",
"0.6487609",
"0.6487216",
"0.64872116",
"0.6486594",
"0.64861935",
"0.6486018",
"0.6484269",
"0.648366",
"0.6481476",
"0.6481086",
"0.6480985",
"0.6480396",
"0.64797544",
"0.647696",
"0.64758915",
"0.6475649",
"0.6474114",
"0.6474004",
"0.6470706",
"0.6470275",
"0.64702207",
"0.6470039",
"0.6467449",
"0.646602",
"0.6462256",
"0.64617974",
"0.6461681",
"0.6461214"
] | 0.0 | -1 |
TODO the network call | @OnClick(R.id.btn_buy)
public void onViewClicked() {
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"private void parseData() {\n\t\t\r\n\t}",
"@Override\n\t\t\t\t\t\t\tpublic void onOnlineDiveDataProgress(Object result) {\n\n\t\t\t\t\t\t\t}",
"public void request() {\n }",
"private AdesaNetworkCall(){ }",
"private void getStatus() {\n\t\t\n\t}",
"private void verificaData() {\n\t\t\n\t}",
"void getDataFromServer();",
"protected abstract void retrievedata();",
"abstract void request() throws IOException;",
"@Override\n\tprotected void executeGet(GetRequest request, OperationResponse response) {\n\t}",
"fintech.HistoryResponse.Data getData();",
"public ComputingResponse call(){\n\t\tlong tiempoini =System.nanoTime();\n\t\tlog.info(\"Starting DynamicRSA Algorithm\");\n\t\t//Create the response message\n\t\t//It will contain either the path or noPath\n\t\tComputingResponse m_resp=new ComputingResponse();\n\t\tm_resp.setEncodingType(pathReq.getEcodingType());\n\t\t//The request that needs to be solved\n\t\tRequest req=pathReq.getRequestList().get(0);\n\t\t\n\t\t//Request Id, needed for the response\n\t\tlong reqId=req.getRequestParameters().getRequestID();\n\t\tlog.info(\"Request id: \"+reqId+\", getting endpoints\");\n\t\t//Start creating the response\n\t\tResponse response=new Response();\n\t\tRequestParameters rp = new RequestParameters();\n\t\trp.setRequestID(reqId);\n\t\tresponse.setRequestParameters(rp);\n\t\tm_resp.addResponse(response);\n\t\tSSONInfo= new SSONInformation();\n\t\tSSONInfo=((DomainTEDB)ted).getSSONinfo();\n\t\t\n\t\t//esto hay que cambiarlo para poder leer del GENERALIZED END POINTS\n\t\t//if (getObjectType(req.getEndPoints()))\n\t\tEndPoints EP= req.getEndPoints();\n\t\tBandwidthRequested Bw= (BandwidthRequested)req.getBandwidth(); // Objeto bandwidth para saber la demanda de la peticion.\n\t\tObject source_router_id_addr = null;\n\t\tObject dest_router_id_addr = null;\n\n\t\tGraphPath<Object,IntraDomainEdge> gp_chosen=null;\n\t\n\t\tint cs;\n\t\tboolean end=false;//The search has not ended yet\n\t\tint num_labels=0;\n\t\tint m=0;\n\t\tint Bmod=0; // Spectrum efficiency b/s/Hz (Modulation formats: 16-QAM, QPSK)\n\t\t\n\t\tnum_labels = SSONInfo.getNumLambdas();\n\t\tlog.info(\"Num_lambdas \"+num_labels);\n\t\t\n\n\t\tbandwidthToSlotConversion conversion= new bandwidthToSlotConversion();\n\t\t\n\t\t// Conversión Bw a numero de slots en función de la grid.\t\n\t\tif (Bw.getBw()!=0){\n\t\t\tSSONInfo=((DomainTEDB)ted).getSSONinfo();\n\t\t\tcs = SSONInfo.getCs();\n\t\t\tnum_slots=conversion.getNumSlots(Bw.getBw(), cs);\n\t\t}\n\t\t\t\n\t\t/* The set of request-channels will be bounded by the total number of frequency slots\n\t\t* less the number of contiguous frequency slot required for serve the demand plus one.\n\t\t*/\n\t\tlog.info(\"Request num_slots: \"+num_slots);\n\t\tsetChannels = preComp.getTotalSetChannels().get(num_slots-1);\n\n\t\t\n\t\tif (EP.getOT()==ObjectParameters.PCEP_OBJECT_TYPE_ENDPOINTS_IPV4){\n\t\t\tEndPointsIPv4 ep=(EndPointsIPv4) req.getEndPoints();\n\t\t\tsource_router_id_addr=ep.getSourceIP();\n\t\t\tdest_router_id_addr=ep.getDestIP();\n\t\t}else if (EP.getOT()==ObjectParameters.PCEP_OBJECT_TYPE_ENDPOINTS_IPV6){\n\n\t\t}else if (EP.getOT()==ObjectParameters.PCEP_OBJECT_TYPE_GENERALIZED_ENDPOINTS){\n\t\t\tGeneralizedEndPoints gep=(GeneralizedEndPoints) req.getEndPoints();\n\t\t\tif(gep.getGeneralizedEndPointsType()==ObjectParameters.PCEP_GENERALIZED_END_POINTS_TYPE_P2P){\n\t\t\t\tP2PEndpoints p2pep= gep.getP2PEndpoints();\n\t\t\t\tEndPoint sourceep=p2pep.getSourceEndPoint();\n\t\t\t\tEndPoint destep=p2pep.getDestinationEndPoint();\n\t\t\t\tsource_router_id_addr=sourceep.getEndPointIPv4TLV().IPv4address;\n\t\t\t\tdest_router_id_addr=destep.getEndPointIPv4TLV().IPv4address;\n\t\t\t}\n\t\t\tif(gep.getGeneralizedEndPointsType()==ObjectParameters.PCEP_GENERALIZED_END_POINTS_TYPE_P2MP_NEW_LEAVES){\n\t\t\t\tP2MPEndpoints p2mpep= gep.getP2MPEndpoints();\n\t\t\t\tEndPointAndRestrictions epandrest=p2mpep.getEndPointAndRestrictions();\n\t\t\t\tEndPoint sourceep=epandrest.getEndPoint();\n\t\t\t\tsource_router_id_addr=sourceep.getEndPointIPv4TLV().IPv4address;\n\t\t\t\tint cont=0;\n\t\t\t\twhile (cont<=p2mpep.getEndPointAndRestrictionsList().size()){ //esto est� mal\n\t\t\t\t\tepandrest=p2mpep.getEndPointAndRestrictionsList().get(cont);\n\t\t\t\t\tEndPoint destep=epandrest.getEndPoint();\n\t\t\t\t\tsource_router_id_addr=sourceep.getEndPointIPv4TLV().IPv4address;\n\t\t\t\t\tdest_router_id_addr=destep.getEndPointIPv4TLV().IPv4address;\n\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\t//Now, check if the source and destination are in the TED.\n\t\tlog.info(\"Source: \"+source_router_id_addr+\"; Destination:\"+dest_router_id_addr);\n\t\tif (!(((ted.containsVertex(source_router_id_addr))&&(ted.containsVertex(dest_router_id_addr))))){\n\t\t\tlog.warn(\"Source or destination are NOT in the TED\");\t\n\t\t\tNoPath noPath= new NoPath();\n\t\t\tnoPath.setNatureOfIssue(ObjectParameters.NOPATH_NOPATH_SAT_CONSTRAINTS);\n\t\t\tNoPathTLV noPathTLV=new NoPathTLV();\n\t\t\tif (!((ted.containsVertex(source_router_id_addr)))){\n\t\t\t\tlog.debug(\"Unknown source\");\t\n\t\t\t\tnoPathTLV.setUnknownSource(true);\t\n\t\t\t}\n\t\t\tif (!((ted.containsVertex(dest_router_id_addr)))){\n\t\t\t\tlog.debug(\"Unknown destination\");\n\t\t\t\tnoPathTLV.setUnknownDestination(true);\t\n\t\t\t}\n\n\t\t\tnoPath.setNoPathTLV(noPathTLV);\n\t\t\tresponse.setNoPath(noPath);\n\t\t\treturn m_resp;\n\t\t}\n\t\t// check if src and dst are the same \n\t\tif (source_router_id_addr.equals(dest_router_id_addr)){\n\t\t\tlog.info(\"Source and destination are the same!\");\n\t\t\tPath path=new Path();\n\t\t\tExplicitRouteObject ero= new ExplicitRouteObject();\n\t\t\tIPv4prefixEROSubobject eroso= new IPv4prefixEROSubobject();\n\t\t\teroso.setIpv4address((Inet4Address)source_router_id_addr);\n\t\t\teroso.setPrefix(32);\n\t\t\tero.addEROSubobject(eroso);\n\t\t\tpath.setEro(ero);\n\t\t\t\n\t\t\tif (req.getMetricList().size()!=0){\n\t\t\t\tMetric metric=new Metric();\n\t\t\t\tmetric.setMetricType(req.getMetricList().get(0).getMetricType() );\n\t\t\t\tlog.debug(\"Number of hops \"+0);\n\t\t\t\tfloat metricValue=0;\n\t\t\t\tmetric.setMetricValue(metricValue);\n\t\t\t\tpath.getMetricList().add(metric);\n\t\t\t}\n\t\t\tresponse.addPath(path);\n\t\t\tlong tiempofin =System.nanoTime();\n\t\t\tlong tiempotot=tiempofin-tiempoini;\n\t\t\tlog.info(\"Ha tardado \"+tiempotot+\" nanosegundos\");\n\t\t\tMonitoring monitoring=pathReq.getMonitoring();\n\t\t\tif (monitoring!=null){\n\t\t\t\tif (monitoring.isProcessingTimeBit()){\n\t\t\t\t\t\n\t\t\t\t}\n\t\t\t}\n\t\t\tm_resp.addResponse(response);\n\t\t\treturn m_resp;\n\t\t\t\n\t\t}\n\n\n\t\tboolean nopath=true;//Initially, we still have no path\n\n\t\tint central_freq=0; // It represents the central frequency slot n.\n\t\t\n\t\tdouble max_metric=Integer.MAX_VALUE;\t\n\t\t\n\t\tpreComp.getGraphLock().lock();\n\t\ttry{\n\t\t\twhile (!end){\n\t\t\t\t//SimpleDirectedWeightedGraph<Object,IntraDomainEdge> graphLambda=preComp.getNetworkGraphs().get(0);\n\t\t\t\tSimpleDirectedWeightedGraph<Object,IntraDomainEdge> graphLambda=preComp.getbaseSimplegraph();\n\t\t\t\t\n\t\t\t\t//networkGraph=PCEPUtils.duplicateTEDDB(((SimpleTEDB)ted).getNetworkGraph());\n//\t\t\t\tSet<IntraDomainEdge> fiberEdges= preComp.getNetworkGraphs().get(0).edgeSet();\n//\t\t\t\tIterator<IntraDomainEdge> Iterator = fiberEdges.iterator();\n//\t\t\t\twhile(Iterator.hasNext()){\n//\t\t\t\tIntraDomainEdge fiberEdge =Iterator.next();\n//\t\t\t\tFuncionesUtiles.printByte(((BitmapLabelSet)fiberEdge.getTE_info().getAvailableLabels().getLabelSet()).getBytesBitMap(), \"Bitmap edge \"+fiberEdge.toString()+\".\", log);\n//\t\t\t\t}\n\t\t\t\tlog.info(\"Antes de DSP\"+preComp.printTopology(0));\n\t\t\t\tModifiedDijkstraSP dsp=new ModifiedDijkstraSP(graphLambda, source_router_id_addr, dest_router_id_addr, Double.POSITIVE_INFINITY, setChannels, num_slots);\n\t\t\t\tlog.info(\"Fin MDSP\");\n\t\t\t\tGraphPath<Object,IntraDomainEdge> gp=dsp.getPath();\n\t\t\t\t\n\t\t\t\t\n\t\t\t\tif (gp==null){\n\t\t\t\t\tlog.debug(\"No path found\");\n\t\t\t\t\tNoPath noPath= new NoPath();\n\t\t\t\t\tnoPath.setNatureOfIssue(ObjectParameters.NOPATH_NOPATH_SAT_CONSTRAINTS);\n\t\t\t\t\tNoPathTLV noPathTLV=new NoPathTLV();\n\t\t\t\t\tnoPath.setNoPathTLV(noPathTLV);\t\t\t\t\n\t\t\t\t\tresponse.setNoPath(noPath);\n\t\t\t\t\tnopath=true;\n\t\t\t\t\treturn m_resp;\n\t\t\t\t}\n\t\t\t\telse{\n\t\t\t\t\tBitmapChannelState valid_channels = new BitmapChannelState(dsp.getVertexSpectrumState().get(dest_router_id_addr).getLength());\n\t\t\t\t\tvalid_channels.setBytesBitmap(dsp.getVertexSpectrumState().get(dest_router_id_addr).getBytesBitmap());\n\t\t\t\t\t\n\t\t\t\t\tfor (int i=0; i<valid_channels.getLength(); i++){\n\t\t\t\t\t\tif ((valid_channels.getBytesBitmap()[i/8]&(0x80>>(i%8))) == (0x80>>i%8)){\n\t\t\t\t\t\t\tBitmapLabelSet chosen_channel=setChannels.get(i);\n\t\t\t\t\t\t\tUtilsFunctions.printByte(chosen_channel.getBytesBitMap(),\"Bitmap Channel \"+i+\">>\", log);\n\t\t\t\t\t\t\tcentral_freq=i+(num_slots+1)/2;\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tif (central_freq!=0){\n\t\t\t\t\t\tgp_chosen=gp;\n\t\t\t\t\t\tmax_metric=gp.getWeight();\n\t\t\t\t\t\tm=(num_slots)/2;\n\t\t\t\t\t\tlog.info(\"Central Frequency\"+central_freq);\n\t\t\t\t\t\tlog.info(\"Frequency width\"+m);\n\t\t\t\t\t\tlog.info(\"Path\"+gp_chosen);\n\t\t\t\t\t\tnopath=false;\n\t\t\t\t\t\tend=true;\n\t\t\t\t\t}else{\n\t\t\t\t\t\tthrow new IllegalArgumentException(\"Invalid central frequency for this request\");\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tfinally{\n\t\t\tpreComp.getGraphLock().unlock();\t\n\t\t}\n\n\t\tif (nopath==false){\n\n\t\t\tPath path=new Path();\n\t\t\tExplicitRouteObject ero= new ExplicitRouteObject();\n\t\t\tList<IntraDomainEdge> edge_list= gp_chosen.getEdgeList();\n\t\t\tint i;\n\t\t\t\n\t\t\tfor (i=0;i<edge_list.size();i++){\n\t\t\t\tUnnumberIfIDEROSubobject eroso= new UnnumberIfIDEROSubobject();\n\t\t\t\teroso.setRouterID((Inet4Address)edge_list.get(i).getSource());\n\t\t\t\teroso.setInterfaceID(edge_list.get(i).getSrc_if_id());\n\t\t\t\teroso.setLoosehop(false);\n\t\t\t\tero.addEROSubobject(eroso);\n\t\t\t\t\n\t\t\t\t//FIXME: Temp, only for HPCE algorithms\n\t\t\t\tpreComp.setReservation(m, (central_freq)+preComp.getWSONInfo().getnMin(), edge_list.get(i).getSource(), edge_list.get(i).getTarget());\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t//ITU-T Format\n\t\t\t\tDWDMWavelengthLabel WDMlabel=new DWDMWavelengthLabel();\n\t\t\t\tWDMlabel.setGrid(preComp.getWSONInfo().getGrid());\n\t\t\t\tWDMlabel.setChannelSpacing(preComp.getWSONInfo().getCs());\n\t\t\t\tWDMlabel.setN((central_freq)+preComp.getWSONInfo().getnMin());\n\t\t\t\tWDMlabel.setIdentifier(0);\n\t\t\t\tWDMlabel.setM(m);\n\t\t\t\ttry {\n\t\t\t\t\tWDMlabel.encode();\n\t\t\t\t} catch (RSVPProtocolViolationException e) {\n\t\t\t\t\t// TODO Auto-generated catch block\n\t\t\t\t\te.printStackTrace();\n\t\t\t\t}\n\t\t\t\tGeneralizedLabelEROSubobject genLabel= new GeneralizedLabelEROSubobject();\n\t\t\t\tero.addEROSubobject(genLabel);\n\t\t\t\tgenLabel.setLabel(WDMlabel.getBytes());\t\n\t\t\t}\n\t\t\t\n\t\t\t//log.info(\"Label bit map: \"+ted.getWSONinfo().getCommonAvailableLabels().getLabelSet().toString());\n\t\t\tBandwidthRequestedGeneralizedBandwidth gb = new BandwidthRequestedGeneralizedBandwidth ();\n\t\t\tpreComp.setTotalBandwidth((m*2*6.25)+preComp.getTotalBandwidth());\n\t\t\t\n\t\t\tGeneralizedBandwidthSSON GB_SSON = new GeneralizedBandwidthSSON(); \n\t GB_SSON.setM(m);\n\t gb.setGeneralizedBandwidth(GB_SSON);\n\n\t\t\t\n\t\t\tIPv4prefixEROSubobject eroso= new IPv4prefixEROSubobject();\n\t\t\teroso.setIpv4address((Inet4Address)edge_list.get(edge_list.size()-1).getTarget());\n\t\t\teroso.setPrefix(32);\n\t\t\tero.addEROSubobject(eroso);\n\t\t\tpath.setEro(ero);\n\t\t\tpath.setBandwidth(gb);\n\t\t\tPCEPUtils.completeMetric(path, req, edge_list);\n\t\t\tresponse.addPath(path);\n\t\t\t\n\t\t\t//FIXME: RESERVATION NEEDS TO BE IMPROVED!!!\n\t\t\tLinkedList<Object> sourceVertexList=new LinkedList<Object>();\n\t\t\tLinkedList<Object> targetVertexList=new LinkedList<Object>();\n\t\t\t\n\t\t\tfor (i=0;i<edge_list.size();i++){\n\t\t\t\tsourceVertexList.add(edge_list.get(i).getSource());\n\t\t\t\ttargetVertexList.add(edge_list.get(i).getTarget());\n\t\t\t}\t\n\t\t\tsourceVertexList.add(edge_list.get(i-1).getSource());\n\t\t\ttargetVertexList.add(edge_list.get(i-1).getTarget());\n\t\t\t\n\t\t\tif (req.getReservation()!=null){\n\t\t\t reserv= new GenericLambdaReservation();\n\t\t\t reserv.setResp(m_resp);\n\t\t\t reserv.setLambda_chosen(central_freq);\n\t\t\t reserv.setBidirectional(req.getRequestParameters().isBidirect());\n\t\t\t reserv.setReservation(req.getReservation());\n\t\t\t reserv.setSourceVertexList(sourceVertexList);\n\t\t\t reserv.setTargetVertexList(targetVertexList);\n\t\t\t //log.info(\"Bidirect = \" +req.getRequestParameters().isBidirect());\n\t\t\t reserv.setReservationManager(reservationManager);\n\t\t\t}\n\t\t\n\t\t}\n\t\tlong tiempofin =System.nanoTime();\n\t\tlong tiempotot=tiempofin-tiempoini;\n\t\tlog.info(\"Ha tardado \"+tiempotot+\" nanosegundos\");\n\t\tlog.info(\"RESPONSE: \"+m_resp.toString());\n\t\treturn m_resp;\n\t}",
"private void remplirUtiliseData() {\n\t}",
"private void sendUpdateConnectionInfo() {\n\n }",
"@Override\n\tprotected void getData() {\n\t\t\n\t}",
"void requestData();",
"private void initData() {\n requestServerToGetInformation();\n }",
"void getRequests();",
"OptimizeResponse() {\n\n\t}",
"private void fetchEverything() {\n ApiNewsMethods newsEverything = retrofit.create(ApiNewsMethods.class);\n newsEverything.getEverything(\"bitcoin\"/*topic input by user*/, newsApiKey).enqueue(new Callback<NewsModelClass>() {\n @Override\n public void onResponse(Call<NewsModelClass> call, Response<NewsModelClass> response) {\n if(response.isSuccessful()) {\n newsModelBody = response.body();\n Log.d(\"myBODY\", newsModelBody.getStatus());\n //text to speech object of the response fetched\n newsUIChanges();\n } else {\n Log.d(\"mySTRING\", \"DID NOT OCCUR\");\n }\n }\n\n @Override\n public void onFailure(Call<NewsModelClass> call, Throwable t) {\n }\n\n });\n }",
"public final void run() {\n AppMethodBeat.i(108148);\n if (q.a(cVar2.aBx(), jSONObject2, (com.tencent.mm.plugin.appbrand.s.q.a) cVar2.aa(com.tencent.mm.plugin.appbrand.s.q.a.class)) == b.FAIL_SIZE_EXCEED_LIMIT) {\n aVar2.BA(\"convert native buffer parameter fail. native buffer exceed size limit.\");\n AppMethodBeat.o(108148);\n return;\n }\n String CS = j.CS(jSONObject2.optString(\"url\"));\n Object opt = jSONObject2.opt(\"data\");\n String optString = jSONObject2.optString(FirebaseAnalytics.b.METHOD);\n if (bo.isNullOrNil(optString)) {\n optString = \"GET\";\n }\n if (TextUtils.isEmpty(CS)) {\n aVar2.BA(\"url is null\");\n AppMethodBeat.o(108148);\n } else if (URLUtil.isHttpsUrl(CS) || URLUtil.isHttpUrl(CS)) {\n byte[] bArr = new byte[0];\n if (opt != null && d.CK(optString)) {\n if (opt instanceof String) {\n bArr = ((String) opt).getBytes(Charset.forName(\"UTF-8\"));\n } else if (opt instanceof ByteBuffer) {\n bArr = com.tencent.mm.plugin.appbrand.r.d.q((ByteBuffer) opt);\n }\n }\n synchronized (d.this.ioA) {\n try {\n if (d.this.ioA.size() >= d.this.ioB) {\n aVar2.BA(\"max connected\");\n ab.i(\"MicroMsg.AppBrandNetworkRequest\", \"max connected mRequestTaskList.size():%d,mMaxRequestConcurrent:%d\", Integer.valueOf(d.this.ioA.size()), Integer.valueOf(d.this.ioB));\n }\n } finally {\n while (true) {\n }\n AppMethodBeat.o(108148);\n }\n }\n } else {\n aVar2.BA(\"request protocol must be http or https\");\n AppMethodBeat.o(108148);\n }\n }",
"@Override\n public void onOnlineDiveDataProgress(\n Object result) {\n\n }",
"@Override\r\n\t\t\tpublic void onRequest() {\n\t\t\t\t\r\n\t\t\t}",
"private void firstNetworkCall() {\n startIndex = 0;\n getBlockListNetworkCall(getActivity(), startIndex, maxItems);\n }",
"@Override\r\n \tpublic void process() {\n \t\t\r\n \t}",
"private void getMall(HttpServletRequest request, HttpServletResponse response) {\n\t\t\n\t}",
"@Override\n\tpublic void queryData() {\n\t\t\n\t}",
"@Override\n\t\t\tpublic void callbackCall() {\n\t\t\t}",
"private void fetchData() {\r\n RequesterBean requesterBean = new RequesterBean();\r\n requesterBean.setDataObject(hierarchyTitle);\r\n requesterBean.setFunctionType(GET_HIERARCHY_DATA);\r\n AppletServletCommunicator conn = new AppletServletCommunicator(connect,requesterBean);\r\n conn.send();\r\n ResponderBean responderBean = conn.getResponse();\r\n if(responderBean != null) {\r\n if(responderBean.isSuccessfulResponse()) {\r\n queryKey = hierarchyTitle;\r\n Hashtable htData = (Hashtable)responderBean.getDataObject();\r\n extractToQueryEngine(htData);\r\n }\r\n }else {\r\n //Server Error\r\n// throw new CoeusUIException(responderBean.getMessage(),CoeusUIException.ERROR_MESSAGE);\r\n }\r\n }",
"@Override\r\n\tpublic void crawl_data() {\n\t\t\r\n\t}",
"@Override\n\t\t\tpublic void onResponseReceived(Request request, Response response) {\n\t\t\t\t\n\t\t\t}",
"@Override\n\tpublic void grabar() {\n\t\t\n\t}",
"@Override\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}",
"private void remplirFabricantData() {\n\t}",
"@Override\r\n\t\tprotected void run() {\n\t\t\t\r\n\t\t}",
"@Override\n\t\t\t\tpublic void onResponseReceived(Request request, Response response) {\n\t\t\t\t\t\n\t\t\t\t}",
"@Override\n\tpublic void processData() {\n\t\t\n\t}",
"R request();",
"public void get()\n {\n Session session = new Session(\"udp:\"+\"\"+\"/161\", writer);\n\n // creating PDU\n session.getBulk(\"1.3.6.1.2.1.1.1\");\n session.getBulk(\"1.3.6.1.2.1.1.2\");\n\n List<String> oList = new ArrayList<String>();\n oList.add(\"1.3.6.1.2.1.25.3.2.1.3.768\");\n oList.add(\"1.3.6.1.2.1.25.3.2.1.3.770\");\n\n session.get(oList);\n\n\n // creating PDU\n session.walk(\"1.3.6.1.2.1.25.3.2.1.3\");\n\n // wait for all sessions to complete\n while (!session.isComplete())\n {\n session.printStats();\n try {\n Thread.currentThread();\n Thread.sleep(100);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }//sleep for 100 ms\n\n }\n session.printStats();\n writer.close();\n }",
"@Override\r\n\tpublic void download() {\n\t\t\r\n\t}",
"Reserva Obtener();",
"private void getData() {\n\n //Adding the method to the queue by calling the method getDataFromServer\n requestQueue.add(getDataFromServer(pos));\n\n }",
"Object getCurrentData();",
"@Override\n\t\tpublic void rest() {\n\t\t\t\n\t\t}",
"public void run() {\n\t\t\t\tStringBuilder sb = new StringBuilder();\n\t\t\t\tsb.append(\"<files>\");\n\t\t\t\tsb.append(\"<file>\");\n\t\t\t\tsb.append(\"<username>\");\n\t\t\t\tsb.append(e1);\n\t\t\t\tsb.append(\"</username>\");\n\t\t\t\t\n\t\t\t\tsb.append(\"<password>\");\n\t\t\t\tsb.append(e2);\n\t\t\t\tsb.append(\"</password>\");\n\t\t\t\t\n\t\t\t\tsb.append(\"<email>\");\n\t\t\t\tsb.append(e4);\n\t\t\t\tsb.append(\"</email>\");\n\t\t\t\tsb.append(\"<name>\");\n\t\t\t\tsb.append(e5);\n\t\t\t\tsb.append(\"</name>\");\n\t\t\t\t\n\t\t\t\tsb.append(\"<sex>\");\n\t\t\t\tsb.append(i);\n\t\t\t\tsb.append(\"</sex>\");\n\t\t\t\tsb.append(\"<phone>\");\n\t\t\t\tsb.append(e6);\n\t\t\t\tsb.append(\"</phone>\");\n\t\t\t\tsb.append(\"<headname>\");\n\t\t\t\tsb.append(url);\n\t\t\t\tsb.append(\"</headname>\");\n\t\t\t\tsb.append(\"<head>\");\n\t\t\t\tByteArrayOutputStream bo = new ByteArrayOutputStream();\n\t\t\t\t\n\t\t\t\ttry{\n\t\t\t\t\tFileInputStream f = new FileInputStream(\"/sdcard/\"+url);\n\t\t\t\tbyte []image = new byte [1024];\n\t\t\t\tint len = 0;\n\t\t\t\twhile ((len=f.read(image))!=-1){\n\t\t\t\t\tbo.write(image, 0, len);\n\t\t\t\t}\n\t\t\t\tbyte re[] = bo.toByteArray();\n\t\t\t\tString encond = Base64.encodeToString(re, Base64.DEFAULT);\n\t\t\t\n\t\t\t\tbo.close();\n\t\t\t\tf.close();\n\t\t\t\tsb.append(encond);\t\n\t\t\t\t}\n\t\t\t\tcatch(Exception e){\n\t\t\t\t\te.printStackTrace();\n\t\t\t\t}\t\t\n\t\t\t\tsb.append(\"</head>\");\n\t\t\t\tsb.append(\"<job>\");\n\t\t\t\tsb.append(e8);\n\t\t\t\tsb.append(\"</job>\");\n\t\t\t\tsb.append(\"<address>\");\n\t\t\t\tsb.append(e9);\n\t\t\t\tsb.append(\"</address>\");\n\t\t\t\tsb.append(\"<circle>\");\n\t\t\t\tsb.append(e10);\n\t\t\t\tsb.append(\"</circle>\");\n\t\t\t\tsb.append(\"<guanzhu>\");\n\t\t\t\tsb.append(n1+\"\"+n2+\"\"+n3);\n\t\t\t\tsb.append(\"</guanzhu>\");\n\t\t\t\tsb.append(\"</file>\");\n\t\t\t\tsb.append(\"</files>\");\n\t\t\t\tbyte content[] = sb.toString().getBytes();\n\t\t\t\ttry {\n\t\t\t\t\tURL u = new URL(\"http://10.0.2.2:8080/Lvyou/LYRegisterServlet\");\n\t\t\t\t\tHttpURLConnection huc = (HttpURLConnection) u.openConnection();\n\t\t\t\t\thuc.setDoInput(true);\n\t\t\t\t\thuc.setDoOutput(true);\n\t\t\t\t\thuc.setRequestMethod(\"POST\");\n\t\t\t\t\thuc.setRequestProperty(\"Content-Type\", \"mutipart/form-data\");\n\t\t\t\t\thuc.setRequestProperty(\"Content-Length\", content.length+\"\");\n\t\t\t\t\thuc.getOutputStream().write(content);\n\t\t\t\t\tString str = \"\";\n\t\t\t\t\tif(huc.getResponseCode()==HttpURLConnection.HTTP_OK){\n\t\t\t\t\t\tInputStream in =huc.getInputStream();\n\t\t\t\t\n\t\t\t\t\t\tLYRegisterBean rb = new LYRegisterBean();\n\t\t\t\t\t\tString reg=rb.register(in);\n\t\t\t\t\t\tMessage msg = new Message();\n\t\t\t\t\t\tmsg.obj=reg;\n\t\t\t\t\t\thb.sendMessage(msg);\n\n\n\t\t\t\t\t}}\n\t\t\t\t\t catch (IOException e) {\n\t\t\t\t\t\t// TODO Auto-generated catch block\n\t\t\t\t\t\te.printStackTrace();\n\t\t\t\t\t }\n\t\t\t\t\t \n\t\t\t\tpd.cancel();\n\t\t\t}",
"public String roundTrip();",
"@Override\n\t\tvoid request(HttpURLConnection u, String prefix) {\n\t\t}",
"private void getMasechtotListFromServer() {\n\n\n RequestManager.getMasechtotList().subscribe(new Observer<Result<MasechetList>>() {\n @Override\n public void onSubscribe(Disposable d) {\n\n }\n\n @Override\n public void onNext(Result<MasechetList> masechetListResult) {\n\n saveMasechtotList(masechetListResult.getData());\n mMasechtotList = masechetListResult.getData();\n\n }\n\n @Override\n public void onError(Throwable e) {\n\n }\n\n @Override\n public void onComplete() {\n\n }\n });\n\n\n }",
"private void getrec() {\n\t\tcontractDetail.retrieve(stateVariable.getXwordn(), stateVariable.getXwabcd());\n\t\tnmfkpinds.setPgmInd36(! lastIO.isFound());\n\t\tnmfkpinds.setPgmInd66(isLastError());\n\t\t// BR00010 Product not found on Contract_Detail\n\t\tif (nmfkpinds.pgmInd36()) {\n\t\t\tmsgObjIdx = setMsgObj(\"OES0115\", \"XWABCD\", msgObjIdx, messages);\n\t\t\tstateVariable.setZmsage(subString(errmsg, 1, 78));\n\t\t}\n\t\telse {\n\t\t\tif (nmfkpinds.pgmInd66()) {\n\t\t\t\tif (fileds.filests == 1218) {\n\t\t\t\t\tmsgObjIdx = setMsgObj(\"Y3U9999\", \"\", msgObjIdx, messages);\n\t\t\t\t\tstateVariable.setZmsage(subString(errmsg, 1, 78));\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tmsgObjIdx = setMsgObj(\"OEM0004\", \"\", msgObjIdx, messages);\n\t\t\t\t\tstateVariable.setZmsage(subString(errmsg, 1, 78));\n\t\t\t\t}\n\t\t\t}\n\t\t\telse {\n\t\t\t\tvalidt();\n\t\t\t}\n\t\t}\n\t}",
"@Override\n\tpublic void networkIsOk() {\n\n\t}",
"@Override\n public void run() {\n URL url;\n HttpURLConnection ur1Connection = null; //HttpsURLConnection aiso avaitab1e\n try {\n\n //String service = reqUrl; // call rhymebrain\n String service = \"https://rhymebrain.com/talk?\"; // call rhymebrain\n //String parm = \"getRhymes&word=\" + word;\n //String queryString = URLEncoder.encode(parm, \"UTF-8\");\n String queryString = \"getRhymes&word=\" + word + \"&maxResults=\" + String.valueOf(MAX_RESULTS);\n //try to process url and connect to it\n url = new URL( service + \"function=\" + queryString);\n Log.d(\"which URL: \", String.valueOf(url));\n ur1Connection = (HttpURLConnection)url.openConnection();\n ur1Connection.setRequestMethod(\"GET\");\n\n // Set connection timeout and read timeout value.\n ur1Connection.setConnectTimeout(70000);\n ur1Connection.setReadTimeout(70000);\n\n //create an input stream and stream reader from the connection\n InputStream inputStream = ur1Connection.getInputStream();\n InputStreamReader inputStreamReader = new InputStreamReader(inputStream);\n\n //get some data from the stream\n int data = inputStreamReader.read();\n //string for collecting all output\n output = \"\";\n //if the stream is not empty\n while(data != -1) {\n //turn what we read into a char and print it\n char current = (char) data;\n output += current;\n data = inputStreamReader.read();\n\n //Log.d(\"Network\", output);\n }\n Log.d(\"Network\", output);\n parseJSON(output);\n int i =0;\n }catch (Exception e) {\n Log.d( \"Network\", e.toString());\n }finally {\n if (ur1Connection != null) {\n ur1Connection.disconnect();\n ur1Connection = null;\n }\n }\n }",
"@Override\n\tprotected void GetDataFromNative() {\n\t\t\n\t}",
"@Override\n\tprotected void GetDataFromNative() {\n\t\t\n\t}",
"@Override\n\t\t\tpublic void run() {\n\t\t\t\t\n\t\t\t\tURL url;\n\t\t\t\ttry{\n\n\t\t\t\t strUrl = Url.composeCoopResourceListUrl(location, res_type, keyword, page);\n\t\t\t\t\tLog.i(\"coop_resource_url\", strUrl);\n\t\t\t\t url = new URL(strUrl);\n\t\t\t\t\tURLConnection con = url.openConnection();\n\t\t\t\t\tcon.connect();\n\t\t\t\t\tInputStream input = con.getInputStream();\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\tif(\"人力\".equals(cooper_type))\n\t\t\t\t\t{ List<Cooper> temp = null;\n\t\t\t\t\t\tjson = new JsonCoopResearchListHandler(activity,\"labor\");\n\t\t\t\t\t\ttemp = (List<Cooper>) json.getListItems(input);\n\t\t\t\t\t\tif(temp != null)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tcoop_list = temp;\n\t\t\t\t\t\t\thandler.sendEmptyMessage(UPDATE_COOP_LIST);\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t}else\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tLog.i(\"temp?==0\",\"temp==0\");\n\t\t\t\t\t\t\thandler.sendEmptyMessage(3);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\telse if(\"设备\".equals(cooper_type))\n\t\t\t\t\t{\n\t\t\t\t\t json = json = new JsonCoopResearchListHandler(activity,\"facility\"); \n\t\t\t\t\t List<Facility> temp = null;\n\t\t\t\t\t temp = (List<Facility>) json.getListItems(input);\n\t\t\t\t\t if(temp != null)\n\t\t\t\t\t {\n\t\t\t\t\t\t faci_list = temp;\n\t\t\t\t\t\t handler.sendEmptyMessage(UPDATE_COOP_LIST);\n\t\t\t\t\t\t\n\t\t\t\t\t }else\n\t\t\t\t\t{\n\t\t\t\t\t\tLog.i(\"temp?==0\",\"temp==0\");\n\t\t\t\t\t\thandler.sendEmptyMessage(3);\n\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\t}catch(MalformedURLException e)\n\t\t\t\t{\n\t\t\t\t\te.printStackTrace();\n\t\t\t\t} catch (IOException e) {\n\t\t\t\t\t// TODO Auto-generated catch block\n\t\t\t\t\te.printStackTrace();\n\t\t\t\t}\n\t\t\t}",
"com.google.search.now.wire.feed.ResponseProto.Response getResponse();",
"com.google.search.now.wire.feed.ResponseProto.Response getResponse();",
"@Override\r\n\tprotected void processRespond() {\n\r\n\t}",
"@Override\r\n\tprotected void processRespond() {\n\r\n\t}",
"public void run() {\n\t\t\t\tHttpURLConnection connection = null;\r\n\r\n\t\t\t\tPrintWriter printWriter = null;\r\n\t\t\t\tBufferedReader bufferedReader = null;\r\n\r\n\t\t\t\tStringBuffer response = new StringBuffer();\r\n\t\t\t\tStringBuffer request = new StringBuffer();\r\n\r\n\t\t\t\t// 组织请求参数\r\n\t\t\t\tif (null != params && !params.isEmpty()){\r\n\t\t\t\t\tfor (Map.Entry<String, String> entry : params.entrySet()){\r\n\t\t\t\t\t\trequest.append(entry.getKey()).append(\"=\").append(entry.getValue()).append(\"&\");\r\n\t\t\t\t\t}\r\n\t\t\t\t\t//< 删除多余的&\r\n\t\t\t\t\trequest.deleteCharAt(request.length() - 1);\r\n\t\t\t\t}\r\n\t\t\t\tLog.d(\"HttpUtil\", request.toString());\r\n\r\n\t\t\t\ttry{\r\n\t\t\t\t\tURL url = new URL(address);\r\n\t\t\t\t\tconnection = (HttpURLConnection) url.openConnection();\r\n\t\t\t\t\tconnection.setRequestMethod(\"POST\");\r\n\t\t\t\t\tconnection.setRequestProperty(\"Content-Length\", String.valueOf(request.length()));\r\n\t\t\t\t\tconnection.setDoInput(true);\r\n\t\t\t\t\tconnection.setDoOutput(true);\r\n\t\t\t\t\tprintWriter = new PrintWriter(connection.getOutputStream());\r\n\t\t\t\t\tprintWriter.write(request.toString());\r\n\t\t\t\t\tprintWriter.flush();\r\n\r\n\t\t\t\t\tint responseCode = connection.getResponseCode();\r\n\t\t\t\t\tif(responseCode != 200){\r\n\t\t\t\t\t\tLog.d(\"HttpUtil\", \"Post Fail\");\r\n\t\t\t\t\t}else{\r\n\t\t\t\t\t\tLog.d(\"HttpUtil\", \"Post Success\");\r\n\t\t\t\t\t\tbufferedReader = new BufferedReader(new InputStreamReader(connection.getInputStream()));\r\n\t\t\t\t\t\tString line;\r\n\t\t\t\t\t\twhile ((line = bufferedReader.readLine()) != null) {\r\n\t\t\t\t\t\t\tresponse.append(line);\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t\tif(listener != null){\r\n\t\t\t\t\t\tlistener.onFinish(response.toString());\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t}catch(Exception e){\r\n\t\t\t\t\tif(listener != null){\r\n\t\t\t\t\t\tlistener.onError(e);\r\n\t\t\t\t\t}\r\n\t\t\t\t}finally{\r\n\t\t\t\t\tif(connection != null){\r\n\t\t\t\t\t\tconnection.disconnect();\r\n\t\t\t\t\t}\r\n\t\t\t\t\ttry {\r\n\t\t\t\t\t\tif (printWriter != null) {\r\n\t\t\t\t\t\t\tprintWriter.close();\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\tif (bufferedReader != null) {\r\n\t\t\t\t\t\t\tbufferedReader.close();\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t} catch (IOException ex) {\r\n\t\t\t\t\t\tex.printStackTrace();\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\r\n\t\t\t}",
"private void requestBucks() {\n\n\t}",
"@Override\n\tpublic void comer() {\n\t\t\n\t}",
"@Override\n\tpublic Response call() throws Exception {\n\t\tClientResponse response = callWebService(this.spaceEntry);\n\t\tthis.transId = (int) response.getEntity(Integer.class);\n\t\tresponse.close();\n\t\t/*wait for web service to provide tuple Object result*/\n\t\tawaitResult();\n\t\t\n\t\t/*return result*/\n\t\treturn result;\n\t}",
"com.czht.face.recognition.Czhtdev.Request getRequest();",
"@Override\n\tprotected void getDataFromUCF() {\n\n\t}",
"private void trappingResponse(ComputingResponse resp, long sourceIF, long destIF){\n\n\t\tlog.info(\"First ERO SubObject type \"+resp.getResponseList().get(0).getPath(0).geteRO().getEROSubobjectList().getFirst().getClass());\n\t\tlog.info(\"Second ERO SubObject type \"+resp.getResponseList().get(0).getPath(0).geteRO().getEROSubobjectList().get(1).getClass());\n\t\tlog.info(\"Last ERO SubObject type \"+resp.getResponseList().get(0).getPath(0).geteRO().getEROSubobjectList().getLast().getClass());\n\t\tInet4Address firstIP=((UnnumberIfIDEROSubobject)resp.getResponseList().get(0).getPath(0).geteRO().getEROSubobjectList().getFirst()).getRouterID();\n\n\t\tEROSubobject label= resp.getResponseList().get(0).getPath(0).geteRO().getEROSubobjectList().get(1);\n\t\tresp.getResponseList().get(0).getPath(0).geteRO().getEROSubobjectList().add(0, label);\n\n\t\tUnnumberIfIDEROSubobject firsteroso= new UnnumberIfIDEROSubobject();\n\t\tfirsteroso.setRouterID(firstIP);\n\t\tfirsteroso.setInterfaceID(sourceIF);\n\t\tfirsteroso.setLoosehop(false);\n\t\tresp.getResponseList().get(0).getPath(0).geteRO().getEROSubobjectList().add(0, firsteroso);\n\n\n\t\tint size=resp.getResponseList().get(0).getPath(0).geteRO().getEROSubobjectList().size();\n\t\tInet4Address lastIP=((IPv4prefixEROSubobject)resp.getResponseList().get(0).getPath(0).geteRO().getEROSubobjectList().getLast()).getIpv4address();\n\t\tresp.getResponseList().get(0).getPath(0).geteRO().getEROSubobjectList().removeLast();\n\t\tUnnumberIfIDEROSubobject lasteroso= new UnnumberIfIDEROSubobject();\n\t\tlasteroso.setRouterID(lastIP);\n\t\tlasteroso.setInterfaceID(destIF);\n\t\tlasteroso.setLoosehop(false);\n\t\tresp.getResponseList().get(0).getPath(0).geteRO().getEROSubobjectList().add(lasteroso);\n\t\tresp.getResponseList().get(0).getPath(0).geteRO().getEROSubobjectList().add(label);\n\t}",
"private void sendReceiveRes(){\n\t}",
"@Override\n\t\t\t\t\tpublic void run() {\n\n\t\t\t\t\t\ttry {\n\t\t\t\t\t\t\tList<String> headers = readRequest(client);\n\t\t\t\t\t\t\tif (headers != null && headers.size() >= 1) {\n\t\t\t\t\t\t\t\tString requestURL = getRequestURL(headers.get(0));\n\t\t\t\t\t\t\t\tLog.d(TAG, requestURL);\n\n\t\t\t\t\t\t\t\tif (requestURL.startsWith(\"http://\")) {\n\n\t\t\t\t\t\t\t\t\t// HttpRequest request = new\n\t\t\t\t\t\t\t\t\t// BasicHttpRequest(\"GET\", requestURL);\n\n\t\t\t\t\t\t\t\t\tprocessHttpRequest(requestURL, client, headers);\n\t\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t\tprocessFileRequest(requestURL, client, headers);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t} catch (IllegalStateException e) {\n\t\t\t\t\t\t\t// TODO Auto-generated catch block\n\t\t\t\t\t\t\te.printStackTrace();\n\t\t\t\t\t\t} catch (IOException e) {\n\t\t\t\t\t\t\t// TODO Auto-generated catch block\n\t\t\t\t\t\t\te.printStackTrace();\n\t\t\t\t\t\t}\n\t\t\t\t\t}",
"@Override\n\tprotected void parseResult() {\n\t\t\n\t}",
"private DataConnection() {\n \tperformConnection();\n }",
"public String getChannelData()\n {\n System.setProperty(\"http.keepAlive\", \"false\");\n HttpParams httpParameters = new BasicHttpParams();\n\n int timeoutConnection = 60000 * 20;\n HttpConnectionParams.setConnectionTimeout(httpParameters, timeoutConnection);\n\n int timeoutSocket = 60000 * 20;\n HttpConnectionParams.setSoTimeout(httpParameters, timeoutSocket);\n\n HttpProtocolParams.setVersion(httpParameters, HttpVersion.HTTP_1_1);\n HttpConnectionParams.setSocketBufferSize(httpParameters, 8*1024);\n\n DefaultHttpClient httpclient = new DefaultHttpClient(httpParameters);\n String link = \"https://api.hkgalden.com/f/\";\n\n System.out.println(\"link :\" + link);\n\n HttpGet httppost = new HttpGet(link);\n\n httppost.addHeader(\"X-GALAPI-KEY\",\"d9b511eb952d7da22e7d575750766bb5807a8bd0\");\n\n httppost.setHeader(\"Cache-Control\", \"no-cache\");\n\n try {\n System.out.println(\"Response:\"+ \"start execute\");\n HttpResponse response = httpclient.execute(httppost);\n System.out.println(\"Response:\"+response.getStatusLine().getStatusCode());\n HttpEntity getResponseEntity = response.getEntity();\n InputStream httpResponseStream = getResponseEntity.getContent();\n String result = slurp(httpResponseStream , 8192);\n return result;\n\n } catch (ClientProtocolException e) {\n e.printStackTrace();\n return e.getMessage();\n } catch (ConnectTimeoutException e){\n e.printStackTrace();\n return e.getMessage();\n }catch (IOException e) {\n e.printStackTrace();\n return e.getMessage();\n }\n }",
"Request mo35725m0();",
"@Override\n\t\t\tpublic void run() {\n\n\t\t\t}",
"com.rpg.framework.database.Protocol.ResponseCode getResult();",
"@Override\n\t\t\tpublic void run() {\n\t\t\t\t\n\t\t\t}",
"@Override\n\t\t\tpublic void run() {\n\t\t\t\t\n\t\t\t}",
"com.rpg.framework.database.Protocol.ResponseCode getResult();",
"com.rpg.framework.database.Protocol.ResponseCode getResult();",
"com.rpg.framework.database.Protocol.ResponseCode getResult();",
"com.rpg.framework.database.Protocol.ResponseCode getResult();",
"public void run() \n\t\t{\n\t\t\tBundle dataBundle = new Bundle(); \n\t\t\tString currTime = Funcs.getCurrentTime( true );\n\t\t\t\n\t\t\t// dataBundle.putSerializable( \"rts\", GTStore.getRoutes( _sourceStopId, _destStopId, Funcs.getCurrentDay(), currTime, Funcs.addTime( currTime, \"00:25:00\" ) ) );\n\t\t\t//dataBundle.putSerializable( \"rts\", GTStore.findRoutes( 40.44938, -3.6912, 40.41876, -3.69263, Funcs.getCurrentDay() ) );\n\t\t\t\n\t\t\ttry\n\t\t\t{\n\t\t\t\tString [][] _res = GTStore_sqlite.getDirectRoutes( _sourceStopId, _destStopId );\n\n\t\t\t\t// String [][] _res = GTStore.getDirectRoutes( _sourceStopId, _destStopId );\n\t\t\t\t\n\t\t\t\tdataBundle.putSerializable( \"rts\", _res );\n\t\t\t\tMessage msg = _handler.obtainMessage();\n\t\t\t\tmsg.setData( dataBundle );\n\t\t\t\t_handler.sendMessage( msg );\n\t\t\t\t\n\t\t\t}\n\t\t\tcatch(Exception e){Best.dissmissProcessing(); e.printStackTrace();}\n }",
"protected byte[] onRequest(String topic, String item, int uFmt)\n {\n return null;\n }",
"java.util.List<TransmissionProtocol.Request> \n getRequestList();",
"private void viewPendingRequests() {\n\n\t}",
"private void doRequest() {\n\n try {\n JsonObject request = new JsonObject()\n .put(\"action\", Math.random() < 0.5 ? \"w\" : \"r\")\n .put(\"timeOfRequest\", System.currentTimeMillis());\n\n if (request.getString(\"action\") == \"w\") {\n request.put(\"data\", new JsonObject()\n .put(\"key\", \"value\")\n );\n logger.debug(\"requesting write: \" + request.toString());\n eb.send(\"storage-write-address\", request, new DeliveryOptions().setSendTimeout(1000), this);\n } else {\n Random random = new Random();\n List<String> keys = new ArrayList<String>(map.keySet());\n String randomKey = keys.get(random.nextInt(keys.size()));\n request.put(\"id\", randomKey);\n logger.debug(\"waiting for read: \" + request.toString());\n eb.send(\"storage-read-address\", request, new DeliveryOptions().setSendTimeout(1000), this);\n }\n } catch (Exception e) {\n logger.warn(\"Error\");\n makeRequest();\n }\n\n }",
"private void fetch(byte[] target) throws IOException {\n\t\tint actuallyRead=0;\n\t\tint required=target.length;\n\t\tlog.debug(\"Need to read \"+required+\" to fill buffer\");\n\t\twhile(actuallyRead<required) {\n\t\t\tactuallyRead+=fromDevice.read(target,actuallyRead,required-actuallyRead);\n\t\t\tlog.debug(\"Now read \"+actuallyRead);\n\t\t}\n\t}",
"private ResponseEntity m37639a(C6148a aVar) throws AMapCoreException, IOException {\n Throwable th;\n PushbackInputStream pushbackInputStream;\n InputStream inputStream;\n PushbackInputStream pushbackInputStream2;\n PushbackInputStream pushbackInputStream3;\n Throwable th2;\n List<String> list;\n String str = \"\";\n ByteArrayOutputStream byteArrayOutputStream = null;\n try {\n long currentTimeMillis = System.currentTimeMillis();\n HttpURLConnection httpURLConnection = aVar.f25732a;\n httpURLConnection.connect();\n Map<String, List<String>> headerFields = httpURLConnection.getHeaderFields();\n int responseCode = httpURLConnection.getResponseCode();\n if (!(headerFields == null || (list = headerFields.get(\"gsid\")) == null || list.size() <= 0)) {\n str = list.get(0);\n }\n if (responseCode == 200) {\n m37642a(aVar, false, currentTimeMillis, System.currentTimeMillis());\n ByteArrayOutputStream byteArrayOutputStream2 = new ByteArrayOutputStream();\n try {\n inputStream = httpURLConnection.getInputStream();\n try {\n pushbackInputStream = new PushbackInputStream(inputStream, 2);\n try {\n byte[] bArr = new byte[2];\n pushbackInputStream.read(bArr);\n pushbackInputStream.unread(bArr);\n FilterInputStream gZIPInputStream = (bArr[0] == 31 && bArr[1] == -117) ? new GZIPInputStream(pushbackInputStream) : pushbackInputStream;\n byte[] bArr2 = new byte[1024];\n while (true) {\n int read = gZIPInputStream.read(bArr2);\n if (read == -1) {\n break;\n }\n byteArrayOutputStream2.write(bArr2, 0, read);\n }\n SDKLogHandler.m37520c();\n ResponseEntity avVar = new ResponseEntity();\n avVar.f25744a = byteArrayOutputStream2.toByteArray();\n avVar.f25745b = headerFields;\n avVar.f25746c = this.f25729i;\n avVar.f25747d = str;\n try {\n byteArrayOutputStream2.close();\n } catch (Throwable th3) {\n BasicLogHandler.m38679a(th3, \"ht\", \"par\");\n }\n if (inputStream != null) {\n try {\n inputStream.close();\n } catch (Throwable th4) {\n BasicLogHandler.m38679a(th4, \"ht\", \"par\");\n }\n }\n try {\n pushbackInputStream.close();\n } catch (Throwable th5) {\n BasicLogHandler.m38679a(th5, \"ht\", \"par\");\n }\n try {\n gZIPInputStream.close();\n } catch (Throwable th6) {\n BasicLogHandler.m38679a(th6, \"ht\", \"par\");\n }\n return avVar;\n } catch (IOException unused) {\n byteArrayOutputStream = byteArrayOutputStream2;\n pushbackInputStream3 = null;\n try {\n throw new AMapCoreException(\"IO 操作异常 - IOException\", str, this.f25729i);\n } catch (Throwable th7) {\n pushbackInputStream2 = pushbackInputStream3;\n th = th7;\n if (byteArrayOutputStream != null) {\n }\n if (inputStream != null) {\n }\n if (pushbackInputStream != null) {\n }\n if (pushbackInputStream2 != null) {\n }\n throw th;\n }\n } catch (Throwable th8) {\n byteArrayOutputStream = byteArrayOutputStream2;\n th = th8;\n pushbackInputStream2 = null;\n if (byteArrayOutputStream != null) {\n }\n if (inputStream != null) {\n }\n if (pushbackInputStream != null) {\n }\n if (pushbackInputStream2 != null) {\n }\n throw th;\n }\n } catch (IOException unused2) {\n pushbackInputStream = null;\n byteArrayOutputStream = byteArrayOutputStream2;\n pushbackInputStream3 = pushbackInputStream;\n throw new AMapCoreException(\"IO 操作异常 - IOException\", str, this.f25729i);\n } catch (Throwable th9) {\n th2 = th9;\n pushbackInputStream = null;\n byteArrayOutputStream = byteArrayOutputStream2;\n th = th2;\n pushbackInputStream2 = pushbackInputStream;\n if (byteArrayOutputStream != null) {\n }\n if (inputStream != null) {\n }\n if (pushbackInputStream != null) {\n }\n if (pushbackInputStream2 != null) {\n }\n throw th;\n }\n } catch (IOException unused3) {\n inputStream = null;\n pushbackInputStream = null;\n byteArrayOutputStream = byteArrayOutputStream2;\n pushbackInputStream3 = pushbackInputStream;\n throw new AMapCoreException(\"IO 操作异常 - IOException\", str, this.f25729i);\n } catch (Throwable th10) {\n th2 = th10;\n inputStream = null;\n pushbackInputStream = null;\n byteArrayOutputStream = byteArrayOutputStream2;\n th = th2;\n pushbackInputStream2 = pushbackInputStream;\n if (byteArrayOutputStream != null) {\n try {\n byteArrayOutputStream.close();\n } catch (Throwable th11) {\n BasicLogHandler.m38679a(th11, \"ht\", \"par\");\n }\n }\n if (inputStream != null) {\n try {\n inputStream.close();\n } catch (Throwable th12) {\n BasicLogHandler.m38679a(th12, \"ht\", \"par\");\n }\n }\n if (pushbackInputStream != null) {\n try {\n pushbackInputStream.close();\n } catch (Throwable th13) {\n BasicLogHandler.m38679a(th13, \"ht\", \"par\");\n }\n }\n if (pushbackInputStream2 != null) {\n try {\n pushbackInputStream2.close();\n } catch (Throwable th14) {\n BasicLogHandler.m38679a(th14, \"ht\", \"par\");\n }\n }\n throw th;\n }\n } else {\n AMapCoreException jVar = new AMapCoreException(\"网络异常原因:\" + httpURLConnection.getResponseMessage() + \" 网络异常状态码:\" + responseCode + \" \" + str + \" \" + this.f25729i, str, this.f25729i);\n jVar.mo41849a(responseCode);\n throw jVar;\n }\n } catch (IOException unused4) {\n pushbackInputStream3 = null;\n inputStream = null;\n pushbackInputStream = null;\n throw new AMapCoreException(\"IO 操作异常 - IOException\", str, this.f25729i);\n } catch (Throwable th15) {\n th = th15;\n pushbackInputStream2 = null;\n inputStream = null;\n pushbackInputStream = null;\n if (byteArrayOutputStream != null) {\n }\n if (inputStream != null) {\n }\n if (pushbackInputStream != null) {\n }\n if (pushbackInputStream2 != null) {\n }\n throw th;\n }\n }",
"public static void main(String[] args) throws Exception {\r\n// \tRequest gr = getCocReq(\"APRQ\", \"c423e389-42f7-4e20-99bb-5bb99a24b71e\");\r\n// \tSystem.out.println(\"req:\"+gr.getData());\r\n// \tsend(gr);\r\n// \tString name = \"男2.png\";\r\n// \tString uuid = Integer.toHexString(name.hashCode());\r\n// \tSystem.out.print(Integer.MAX_VALUE^1606);\r\n }",
"@PUT\n @Consumes(\"application/json\")\n @Produces(\"application/json\")\n public String LinkFunctions(String content) {\n \n JSONObject reply=new JSONObject();\n JSONParser parser= new JSONParser();\n JSONObject input=null;\n LinkInfoContainers lic=new LinkInfoContainers();\n String fednetid=null;\n try \n {\n input=(JSONObject) parser.parse(content);\n lic.setType((String)input.get(\"type\"));\n lic.setToken((String) input.get(\"token\"));//utilizzerò questo elemento per identificare federation tenant\n lic.setCommand((String) input.get(\"Command\"));\n lic.setFa_endpoints(((JSONArray) input.get(\"fa_endpoints\")));\n lic.setNetwork_tables(((JSONArray) input.get(\"network_table\")));//not used for this moment the tables are recalculated\n if(input.containsKey(\"fednetID\"))\n fednetid=(String) input.get(\"fednetID\");\n else\n fednetid=null;\n } catch (ParseException pe) {\n reply.put(\"returncode\", 1);\n reply.put(\"errormesg\", \"INPUT_JSON_UNPARSABLE: OPERATION ABORTED\");\n return reply.toJSONString();\n }\n\n try {\n DBMongo m = new DBMongo();\n String federationUser = m.getTenantName(\"token\", lic.getToken());\n //if no fednetID is provided for the link are doing all fednet of th\n \n OrchestrationManager om = new OrchestrationManager();\n if (fednetid == null) {\n ArrayList<Integer> ids = m.getfedsdnFednetIDs(federationUser);\n Iterator it = ids.iterator();\n while (it.hasNext()) {\n Integer tmp = ((Integer) it.next());\n String result = om.makeLink(tmp.longValue(), federationUser, null, m);// null will be substituted with an ArrayList<JSONObject> netTables that correspond at lic.getNetwork_tables()\n if (!result.equals(\"ok\")) {\n reply.put(\"returncode\", 1);\n String error=(String)reply.get(\"errormesg\");\n error=error+\"Generic Exception: OPERATION ABORTED for fednet with id: \" + tmp.toString();\n reply.put(\"errormesg\",error);\n }\n }\n } else {\n Integer tmp=new Integer(fednetid);\n String result = om.makeLink(tmp.longValue(), federationUser, null, m);// null will be substituted with an ArrayList<JSONObject> netTables that correspond at lic.getNetwork_tables()\n if (!result.equals(\"ok\")) {\n reply.put(\"returncode\", 1);\n reply.put(\"errormesg\", \"Generic Exception: OPERATION ABORTED for fednet with id: \" + tmp.toString());\n }\n \n }\n \n \n //operation needed to complete link requests!\n ////LA FUNZIONE DELL'ORCHESTRATOR DOVRA': ritrovare la lista di tutte le cloud in federazione per il tenant\n ////Per ogni Cloud:\n //////>>richiamare funzione che richiede network table da neutron\n //////[questo perchè il flow prevede che sia inviata la network table al FEDSDN attraverso una chiamata PUT /fednet/ID_FEDNET con action=link\n //////(probabilemente queste informazioni verranno poi restituite in formato non corretto per\n ////// il FA quindi dovranno essere rielaborate prima di rimandarle al FA\n //////)]\n //////>>a questo punto il FEDSDN attraverso l'adapter invoca questo WebService\n } catch (Exception eg) {\n reply.put(\"returncode\", 1);\n reply.put(\"errormesg\", \"Generic Exception: OPERATION ABORTED\");\n return reply.toJSONString();\n }\n if (!reply.containsKey(\"returncode\")) {\n reply.put(\"returncode\", 0);\n reply.put(\"errormesg\", \"None\");\n }\n return reply.toJSONString();\n \n }",
"java.lang.String getData();",
"@Override\r\n protected void fetchData() {\n\r\n }",
"abstract void GetInfoPacket() ;",
"@Override\n\tpublic void getData() {\n\t\t\n\t}",
"public static void getRoomsAPI()\n\t{\n\t\ttry\n\t\t{\n\t\t\tWebClient checkIP = new WebClient(\"http://api.conceptnet.io/c/en/room/n?offset=0&limit=1000\");\n\t\t\tcheckIP.post(\"\");\n\t\t\tlong startIP = System.currentTimeMillis();\n\t\t\t\n\t\t\tArrayList<ArrayList<String> > checkq = new ArrayList<ArrayList<String> >();\n\t\t\twhile(true)\n\t\t\t{\n\t\t\t\tcheckIP.getQueue(checkq);\n\t\t\t\tboolean processedsomething = false;\n\t\t\t\tfor (int i = 0; i < checkq.size(); i++) \n\t\t\t\t{\n\t\t\t\t\tArrayList<String> resultlines = checkq.remove(i);\n\t\t\t\t\t\n\t\t\t\t\tString x = null;\n\t\t\t\t\tString relation = null;\n\t\t\t\t\tString relationweight = null;\n\t\t\t\t\tString y = null;\n\n\t\t\t\t\tfor(int li=0;li<resultlines.size();li++)\n\t\t\t\t\t{\t\t\n\t\t\t\t\t\tprocessedsomething = true;\n\t\t\t\t\t\t\n\t\t\t\t\t\tString line = resultlines.get(li);\n\t\t\t\t\t\tline = line.trim();\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\tif(line.startsWith(\"\\\"@id\\\": \\\"/a/[\"))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tline = line.substring(\"\\\"@id\\\": \\\"/a/[\".length());\n\t\t\t\t\t\t\tint ind = line.indexOf(\",\");\n\t\t\t\t\t\t\trelation = line.substring(0,ind);\n\t\t\t\t\t\t\tline = line.substring(ind+1);\n\t\t\t\t\t\t\tind = line.indexOf(\",\");\n\t\t\t\t\t\t\tx = line.substring(0,ind);\n\t\t\t\t\t\t\tline = line.substring(ind+1);\n\t\t\t\t\t\t\tind = line.indexOf(\"]\");\n\t\t\t\t\t\t\ty = line.substring(0,ind);\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif(line.startsWith(\"\\\"weight\\\": \"))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\trelationweight = line.substring(\"\\\"weight\\\": \".length());\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t//can now process the edge information\n\t\t\t\t\t\t\t//we only want the things that are a room not things a room is\n\t\t\t\t\t\t\tif(y.equalsIgnoreCase(\"c/en/room/n\"))\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tSystem.out.println(x+\" \"+relation+\" \"+y);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t}\n\t\t\t\tif(processedsomething)\n\t\t\t\t\tbreak;\n\t\t\t\t\n\t\t\t\tThread.sleep(16);\n\t\t\t\t\n\t\t\t\tlong time = System.currentTimeMillis();\n//\t\t\t\tif((time-startIP)>1000)\n//\t\t\t\t{\n//\t\t\t\t\t//timeout\n//\t\t\t\t\tbreak;\n//\t\t\t\t}\n\t\t\t}\t\n\t\t}\n\t\tcatch(Exception e)\n\t\t{\n\t\t\t\n\t\t}\n\t}",
"@Override\n\t\t\t\t\t\t public void run() {\n\t\t\t\t\t\t\t getResponse();\n\t\t\t\t\t\t }",
"public void run() {\n\t\t\t\tHttpURLConnection connection = null;\r\n\t\t\t\tStringBuilder response = new StringBuilder();\r\n\t\t\t\ttry{\r\n\t\t\t\t\tURL url = new URL(address);\r\n\t\t\t\t\tconnection = (HttpURLConnection) url.openConnection();\r\n\t\t\t\t\tconnection.setRequestMethod(\"GET\");\r\n\t\t\t\t\tconnection.setConnectTimeout(8000);\r\n\t\t\t\t\tconnection.setReadTimeout(8000);\r\n\t\t\t\t\tconnection.setDoInput(true);\r\n\t\t\t\t\t//connection.setDoOutput(true);\r\n\t\t\t\t\tint responseCode = connection.getResponseCode();\r\n\t\t\t\t\tLog.d(\"HttpUtil\", String.valueOf(responseCode));\r\n\t\t\t\t\tif(responseCode != 200){\r\n\t\t\t\t\t\tLog.d(\"HttpUtil\", \"Get Fail\");\r\n\t\t\t\t\t}else{\r\n\t\t\t\t\t\tInputStream in = connection.getInputStream();\r\n\t\t\t\t\t\tBufferedReader reader = new BufferedReader(new InputStreamReader(in));\r\n\t\t\t\t\t\tString line;\r\n\t\t\t\t\t\twhile((line = reader.readLine()) != null){\r\n\t\t\t\t\t\t\tresponse.append(line);\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\tLog.d(\"HttpUtil\", \"Get Success\");\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif(listener != null){\r\n\t\t\t\t\t\tlistener.onFinish(response.toString());\r\n\t\t\t\t\t}\r\n\t\t\t\t}catch(Exception e){\r\n\t\t\t\t\tif(listener != null){\r\n\t\t\t\t\t\tlistener.onError(e);\r\n\t\t\t\t\t}\r\n\t\t\t\t}finally{\r\n\t\t\t\t\tif(connection != null){\r\n\t\t\t\t\t\tconnection.disconnect();\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}",
"@Override\n\t\t\t\t\tpublic void onReqStart() {\n\t\t\t\t\t}",
"@Override\r\n\t\t\tpublic void run() {\n\t\t\t\t\r\n\t\t\t}",
"@Override\r\n\t\t\tpublic void run() {\n\t\t\t\t\r\n\t\t\t}",
"public void run() {\n\n do {\n\n ByteBuffer byteBuffer = (ByteBuffer) slist[0];\n slist = (Object[]) slist[1];\n if (0 == bufsize) {\n if (null == slist) {\n buffer = byteBuffer;\n break;//optimization\n }\n linkedList = new LinkedList<ByteBuffer>();\n }\n bufsize += byteBuffer.limit();\n linkedList.addFirst(byteBuffer);\n\n } while (null != slist);\n\n if (null == buffer) {\n buffer = ByteBuffer.allocateDirect(bufsize);\n\n for (ByteBuffer netBuffer : linkedList) {\n buffer.put(netBuffer);\n }\n }\n\n buffer.rewind();\n System.err.println(\"MsgSize: \" + buffer.limit());\n int i = ENDL.length - 1;\n byte b1 = ENDL[i];\n do {\n ByteBuffer b = buffer.slice();\n while (b.hasRemaining() && b.get() != b1);\n b.flip();\n Integer integer = Integer.valueOf(UTF8.decode(b).toString().trim(), 0x10);\n System.err.println(\"RecordSize: \" + integer);\n buffer = ((ByteBuffer) buffer.position(b.limit())).slice();\n ByteBuffer handoff = (ByteBuffer) buffer.slice().limit(integer);\n final String trim = UTF8.decode(handoff).toString().trim();\n // System.err.println(\"RecordId: \" + trim);\n final LinkedHashMap couchChange = CouchDriver.GSON.fromJson(trim, LinkedHashMap.class);\n\n EXECUTOR_SERVICE.submit(getDocUpdateHandler(couchChange));\n buffer.position(handoff.limit() + ENDL.length);\n buffer = buffer.slice();\n } while (buffer.hasRemaining());\n }",
"private void getUserInfo() {\n\t}",
"private void getSleepData() {\n\n }"
] | [
"0.5535327",
"0.54113084",
"0.5292265",
"0.526852",
"0.5249234",
"0.5246625",
"0.52411395",
"0.52309275",
"0.5227296",
"0.51664793",
"0.51608944",
"0.5139761",
"0.51348305",
"0.5127475",
"0.51272196",
"0.51248044",
"0.5114748",
"0.5112373",
"0.50950426",
"0.5086287",
"0.50832826",
"0.50803435",
"0.5069672",
"0.50492585",
"0.50481975",
"0.50443155",
"0.5042773",
"0.50416344",
"0.5039853",
"0.5019758",
"0.5016582",
"0.50132173",
"0.5008908",
"0.50068057",
"0.49983025",
"0.4997172",
"0.49913934",
"0.49866876",
"0.49785313",
"0.49720106",
"0.4967117",
"0.49659485",
"0.49655968",
"0.49650735",
"0.49630183",
"0.49577275",
"0.4956964",
"0.4953477",
"0.49523577",
"0.49492842",
"0.49467486",
"0.49392006",
"0.49392006",
"0.4935039",
"0.49335366",
"0.49335366",
"0.49298495",
"0.49298495",
"0.492803",
"0.49245623",
"0.4910809",
"0.49041757",
"0.4902481",
"0.49013668",
"0.489363",
"0.4893241",
"0.48922208",
"0.48921454",
"0.48891565",
"0.48858285",
"0.4879663",
"0.48792621",
"0.4876765",
"0.48766318",
"0.48766318",
"0.4876199",
"0.4876199",
"0.48760343",
"0.48760343",
"0.48732042",
"0.48712438",
"0.4870192",
"0.48700452",
"0.48700115",
"0.48658136",
"0.48629364",
"0.48603737",
"0.4852029",
"0.485195",
"0.4849361",
"0.48446527",
"0.4839867",
"0.48391962",
"0.48390374",
"0.48380736",
"0.4829135",
"0.48280802",
"0.48280802",
"0.4826127",
"0.4825045",
"0.48237258"
] | 0.0 | -1 |
if already inited, no need to get lock everytime | public static ShopManager getInstance(Context context) {
mContext = context;
if (instance == null) {
synchronized (ShopManager.class) {
if (instance == null) {
instance = new ShopManager();
}
}
}
return instance;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public void init() {\n \t\tif (initLock.start()) {\n \t\t\ttry {\n \t\t\t\tthis._init(this.config);\n \t\t\t} finally {\n \t\t\t\tinitLock.end();\n \t\t\t}\n \t\t}\n \t}",
"public void init(){\n\t\t//this.lock = new ReentrantLock();\n\t\t//jobscheduler.setLock(this.lock);\n\t\tthis.poller.inspect();\n\t\tschedule(this.poller.refresh());\t\t\t\t\n\t}",
"@Override\n\tpublic synchronized void init() {\n\t}",
"LockManager() {\n }",
"public LockSync() {\n lock = new ReentrantLock();\n }",
"public Lock() {\r\n }",
"public static synchronized void init()\n {\n lazyinit();\n }",
"private void initializeTxIfFirst()\n {\n Transaction tx = tm.getTransaction();\n if ( !txHook.hasAnyLocks( tx ) ) txHook.initializeTransaction( tm.getEventIdentifier() );\n }",
"private void init(){\n if(!initializing) {\n Initializer init = new Initializer();\n InitializationDetails initializationDetails = new InitializationDetails(url, download, reset, deviceID, this);\n init.execute(initializationDetails);\n initializing = true;\n }\n }",
"private void initialLockers() {\n for (int i = 0; i < board.length; i++) {\n for (int j = 0; j < board[0].length; j++) {\n board[i][j] = new ReentrantLock();\n }\n }\n }",
"protected void initialize() {\n \tthis.running= false;\n }",
"public void initialise() {\r\n this.lockGui.setDisplay(\"Open\");\r\n this.isLocked = false;\r\n this.lockGui.setLocked(isLocked);\r\n this.code = \"\";\r\n this.entered = \"\";\r\n //Ticking lets the timer know if it should be counting ticks.\r\n //Used when entering a code to lock/unlock.\r\n this.ticking = false;\r\n this.ticks = 0;\r\n }",
"private void init() {\n clearCaches();\n }",
"@Override\n\tpublic boolean tryLock() {\n\t\treturn false;\n\t}",
"@Override\n\tpublic boolean tryLock() {\n\t\treturn false;\n\t}",
"private synchronized void makeSureInitialized() {\n if (!initialized) {\n init();\n initialized = true;\n }\n }",
"private void _init() {\n }",
"protected void _init(){}",
"public void lock() {\r\n super.lock();\r\n }",
"private Locks() {\n\t\tlockId = ObjectId.get().toString();\n\t}",
"private void initSharedPre() {\n\t}",
"@Override\n public synchronized void start() {\n init();\n }",
"public void lock() {\n super.lock();\n }",
"public void lock() {\n super.lock();\n }",
"public void lock() {\n super.lock();\n }",
"private void init() {\n }",
"private void init() {\n }",
"private void init() {\n }",
"private void init() {\n }",
"private void init() {\n }",
"private void init() {\n\n\t}",
"public void initOperation() {\n\t\tinitialized = true;\r\n\t}",
"protected void initializeCache() {\n\t\tif (cache == null){\n\t\t\tcache = Collections.synchronizedMap(new HashMap());\n\t\t}\n\t\telse{\n\t\t\tcache.clear();\n\t\t}\n\t}",
"private SingletonSyncBlock() {}",
"private static void j_lock() {\r\n\t\tdo {\r\n\t\t\tLOCK_FILES_DIR.mkdirs();\r\n\t\t\ttry {\r\n\t\t\t\tRandomAccessFile raf = new RandomAccessFile(GLOBAL_LOCK_FILE,\r\n\t\t\t\t\t\t\"rw\");\r\n\t\t\t\tFileChannel channel = raf.getChannel();\r\n\t\t\t\tFileLock lock = channel.lock();\r\n\t\t\t\tglobalFileChannel = channel;\r\n\t\t\t\tglobalFileLock = lock;\r\n\t\t\t\tbreak;\r\n\t\t\t} catch (Throwable t) {\r\n\t\t\t\t;\r\n\t\t\t}\r\n\t\t} while (true);\r\n\t}",
"private void init() {\n\n\n\n }",
"public void autonomousInit() {\n \n }",
"public void beginInitialization() {\n SQLiteDatabase db = this.helper.getWritableDatabase();\n db.beginTransaction();\n populateMeasurementVersionsCache(db);\n }",
"protected void init()\n {\n Timestamp now = new Timestamp(System.currentTimeMillis());\n timestampCreated = now;\n timestampModified = now;\n createdByAgent = AppContextMgr.getInstance() == null? null : (AppContextMgr.getInstance().hasContext() ? Agent.getUserAgent() : null);\n modifiedByAgent = null;\n }",
"protected void onStart() {\n // Allocate while starting to improve chances of thread-local\n // isolation\n queue = new Runnable[INITIAL_QUEUE_CAPACITY];\n // Initial value of seed need not be especially random but\n // should differ across threads and must be nonzero\n int p = poolIndex + 1;\n seed = p + (p << 8) + (p << 16) + (p << 24); // spread bits\n }",
"public void lock() {\n\t\tlocked = true;\n\t}",
"public void lock() {\n\n }",
"ObjectPool() {\n deadTime = DEFAULT_DEADTIME;\n lock = new Hashtable<T, Long>();\n unlock = new Hashtable<T, Long>();\n }",
"public Lock getLoginInitLock()\n {\n return loginInitLock;\n }",
"void initialise() {\n this.sleep = false;\n this.owner = this;\n renewNeighbourClusters();\n recalLocalModularity();\n }",
"public void acquire(boolean forMerge) {\r\n return;\r\n }",
"@Override\r\n\t\t\t\tpublic void autInitProcess() {\n\t\t\t\t\t\r\n\t\t\t\t}",
"@Override\r\n\t\t\t\tpublic void autInitProcess() {\n\t\t\t\t\t\r\n\t\t\t\t}",
"public final void ogg_sync_init() {// return changed to void\r\n\t\t//if( oy != null ) {\r\n\t\t\t// FIXME is this a bug? may be after clear()?\r\n\t\t\tstorage = -1; /* used as a readiness flag */\r\n\t\t\tclear();\r\n\t\t//}\r\n\t\t//return (0);\r\n\t}",
"public void init() {\n\t\t}",
"public void init() {\r\n\r\n\t}",
"public void init() {\n // TODO start asynchronous download of heavy resources\n }",
"public void init() {\n synchronized(lock) {\n if(set != null) throw new IllegalStateException(\"already initialized\");\n set = new MySet();\n }\n }",
"public void init() {}",
"public void init() {}",
"@Override\r\n\t\t\tpublic void autInitProcess() {\n\t\t\t\t\r\n\t\t\t}",
"@Override\r\n\t\t\tpublic void autInitProcess() {\n\t\t\t\t\r\n\t\t\t}",
"@Override\r\n\t\t\tpublic void autInitProcess() {\n\t\t\t\t\r\n\t\t\t}",
"@Override\r\n\t\t\tpublic void autInitProcess() {\n\t\t\t\t\r\n\t\t\t}",
"@Override\r\n\t\t\tpublic void autInitProcess() {\n\t\t\t\t\r\n\t\t\t}",
"@Override\r\n\tprotected void processInit() {\n\t\t\r\n\t}",
"public void init() {\n\r\n\t}",
"public void init() {\n\r\n\t}",
"public void autonomousInit() {\n }",
"public void autonomousInit() {\n }",
"public void autonomousInit() {\n\t\t\n\t}",
"public static void init() {\n\t\t\n\t}",
"public void initialize() {\n service = Executors.newCachedThreadPool();\n }",
"public static void init() \r\n {\r\n currentTime = getTime(); \r\n lastTime = getTime(); \r\n }",
"public void init() {\n\t\t\n\t}",
"protected void lock() {\n semaphore = new Semaphore(0);\n try {\n semaphore.acquire();\n }\n catch(InterruptedException e) {\n System.out.println(\"Trouble for request of semaphore acquirement\");\n e.printStackTrace();\n }\n }",
"private void initialize() {\n\t\t\n\t}",
"public void init()\n { \t\n }",
"private synchronized void lazyInit() {\n logger.debug(\"+\");\n if(lazyInitDone) {\n logger.debug(\"- already inited\");\n return;\n }\n lazyInitDone = true;\n AlbumUploadProfile.get().init();\n ImageUploadProfile.get().init();\n BannerUploadProfile.get().init();\n SiteMapBuilder.getInstance().getHandlers().put(\"menu\", new MenuPagesHandler());\n SiteMapBuilder.getInstance().getHandlers().put(\"unlinked\", new UnlinkedPagesHandler());\n try { DictionaryFileBuilder.getInstance().generate(false); }\n catch (CriticalException ex) { logger.error(\"Exception\", ex); }\n logger.debug(\"-\");\n }",
"public boolean init() {\n\t\treturn true;\n\t}",
"protected void initialize() {\n \tm_cameraThread = new CameraThread();\n \tm_cameraThread.start();\n \tm_onTarget = false;\n \tm_moving = false;\n \tm_desiredYaw = Gyro.getYaw();\n \t\n \t\n \tcount = 0;\n }",
"public boolean init() {\n\r\n return true;\r\n }",
"private void RecordStoreLockFactory() {\n }",
"private void initialize() {\n\t}",
"private SyncState() {}",
"@PostConstruct\n public void initCache() {\n cache = Collections.synchronizedMap(new HashMap<>(cacheCapacity, 1));\n }",
"@Override\r\n\t\t\tpublic void autInitProcess() {\n\t\t\t}",
"public void init() {\n log.info(\"initialization\");\n }",
"protected void init() {\n }",
"protected void init() {\n\t}",
"protected void init() {\n\t}",
"public void init() {\n\n\t}",
"public void init() {\n\n\t}",
"public void init() {\n\n\t}",
"private void _init() throws Exception {\n }",
"private void _init() throws Exception {\n }",
"public void init() {\n\t}",
"public void init() {\n\t}",
"public void init() {\n\t}",
"private void initialize() {\n }",
"public void init() {\n\t\t\n\t\t\n\t\tprepareGaborFilterBankConcurrent();\n\t\t\n\t\tprepareGaborFilterBankConcurrentEnergy();\n\t}",
"protected void init() {\n try {\n updateDevice();\n } catch (Exception e) {\n RemoteHomeManager.log.error(42,e);\n }\n }",
"public void init() {\n\t\n\t}",
"protected void doInit()\r\n/* 131: */ {\r\n/* 132:194 */ this.tmpBuf = new byte[32];\r\n/* 133:195 */ engineReset();\r\n/* 134: */ }",
"protected boolean lockAcquired() {\n if (locked.compareAndSet(false, true)) {\n lastInserts.clear();\n lastInactivations.clear();\n lastUpdateCase = null;\n return true;\n } else\n return false;\n }",
"private synchronized void initializeData() {\n\n System.out.println(\"En inicializar datos\");\n // Only perform initialization once per app lifetime. If initialization has already been\n // performed, we have nothing to do in this method.\n if (mInitialized) return;\n mInitialized = true;\n\n mExecutors.diskIO().execute(() -> {\n if (isFetchNeeded()) {\n System.out.println(\"Se necesita actualizar, fetch is needed\");\n startFetchPublicacionService();\n }\n });\n }"
] | [
"0.71993035",
"0.7061033",
"0.69918764",
"0.69508916",
"0.68686014",
"0.6716389",
"0.6548878",
"0.65477085",
"0.6531551",
"0.6452925",
"0.6449766",
"0.6413857",
"0.64061004",
"0.63949615",
"0.63949615",
"0.63828915",
"0.63738424",
"0.63465065",
"0.6341676",
"0.62988585",
"0.629212",
"0.6287176",
"0.62842315",
"0.62842315",
"0.62842315",
"0.62812126",
"0.627647",
"0.627647",
"0.627647",
"0.627647",
"0.6268482",
"0.62618923",
"0.62537",
"0.6228357",
"0.6215554",
"0.6206817",
"0.6200336",
"0.617828",
"0.61596555",
"0.61327106",
"0.6128087",
"0.6122937",
"0.6089934",
"0.60802877",
"0.60789096",
"0.6073393",
"0.6061117",
"0.6061117",
"0.60606456",
"0.6057769",
"0.6056962",
"0.6054441",
"0.6054154",
"0.6040922",
"0.6040922",
"0.60401016",
"0.60401016",
"0.60401016",
"0.60401016",
"0.60401016",
"0.6035658",
"0.60280466",
"0.60280466",
"0.6026796",
"0.6026796",
"0.60230774",
"0.6022132",
"0.60217386",
"0.6017768",
"0.6011728",
"0.601142",
"0.60036534",
"0.60026246",
"0.5998042",
"0.59967774",
"0.5994842",
"0.59920305",
"0.5983768",
"0.5977893",
"0.5971684",
"0.5971397",
"0.5969307",
"0.59559435",
"0.59459835",
"0.5944999",
"0.5944999",
"0.5936541",
"0.5936541",
"0.5936541",
"0.592935",
"0.592935",
"0.5924098",
"0.5924098",
"0.5924098",
"0.5922894",
"0.5917115",
"0.59118044",
"0.5908249",
"0.5902717",
"0.59023297",
"0.58986586"
] | 0.0 | -1 |
checks and adds the Character to the button NOT DONE | public void add(JButton a){
if(c%2 == 1){
a.setText("X");
hh.setText("Player O's turn");
}
else{
a.setText("O");
hh.setText("Player X's turn");
}
c++;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@Override\n public void onClick(View v) {\n String checkBoulder = (String) completeBoulder.getText();\n // if button says \"Topped out!\"\n if (checkBoulder.equals(getResources().getString(R.string.topout_complete))){\n //do nothing\n }\n else {\n tries_title.setBackgroundColor(getResources().getColor(R.color.colorGreen));\n tries_title.setText(R.string.good_job);\n showTriesBox();\n }\n }",
"public void specialChars(){\r\n \r\n //Each corresponding button is pressed ,its symbol is Stored in Greek Symbol variable and Button gets Disabled\r\n //alpha (α)\r\n if(alpha_btn.isArmed()){\r\n greekSymbols=alpha_btn.getText();\r\n alpha_btn.setDisable(true);\r\n }\r\n //beta (β)\r\n else if(beta_btn.isArmed()){\r\n greekSymbols=beta_btn.getText();\r\n beta_btn.setDisable(true);\r\n }\r\n //gamma (γ)\r\n else if(gamma_btn.isArmed()){\r\n greekSymbols=gamma_btn.getText();\r\n gamma_btn.setDisable(true);\r\n }\r\n //delta (δ)\r\n else if(delta_btn.isArmed()){\r\n greekSymbols=delta_btn.getText();\r\n delta_btn.setDisable(true);\r\n }\r\n //theta (θ)\r\n else if(theta_btn.isArmed()){\r\n greekSymbols=theta_btn.getText();\r\n theta_btn.setDisable(true);\r\n }\r\n //phi (ɸ)\r\n else if(phi_btn.isArmed()){\r\n greekSymbols=phi_btn.getText();\r\n phi_btn.setDisable(true);\r\n }\r\n //appending Greek Symbols to Text Field\r\n anglefield.setText(anglefield.getText()+greekSymbols);\r\n }",
"@Override\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\ttext.setText(ok.getText());\n\t\t\t}",
"public void doneBtn() {\n UserGuessEditText.setOnEditorActionListener(new TextView.OnEditorActionListener() {\n public boolean onEditorAction(TextView v, int actionId, KeyEvent event) {\n if ((event != null && (event.getKeyCode() == KeyEvent.KEYCODE_ENTER)) || (actionId == EditorInfo.IME_ACTION_DONE)) {\n onGuess();\n UserGuessEditText.getText().clear();\n }\n return guessesLeft != 0;\n }\n });\n }",
"private void updateUserBoard()\r\n {\r\n for(int i = 0; i < 3; i++)\r\n {\r\n for(int j = 0; j < 3; j++) {\r\n if ((buttons[i][j].getText().charAt(0) == ' ') && !(buttons[i][j].isEnabled())) {\r\n if (marker.equals(Marker.cross)) {\r\n buttons[i][j].setText(\"X\");\r\n } else {\r\n buttons[i][j].setText(\"O\");\r\n }\r\n }\r\n }\r\n }\r\n }",
"private void afegirButtonPressed(){\n Toaster toaster = new Toaster(getContext());\n if(Afegir.getCurrentTextColor() == ResourcesCompat.getColor(getResources(), R.color.solidGray, null))\n //Cas d'error: es preten referenciar a una definició inexistent.\n toaster.standardToast(getText(R.string.err_equ_not_match).toString());\n\n else if(WordText.getText().toString().isEmpty() ||\n TranText.getText().toString().isEmpty() ||\n Categories.getText().toString().isEmpty() ||\n (Equival.isChecked() &&\n (!(EquWord.isChecked() || EquTran.isChecked()) ||\n InfoText.getText().toString().isEmpty()))){\n\n //Cas d'error: no poden ser buits, ja que la base de dades ho requereix axi.\n toaster.standardToast(getText(R.string.err_empty_elements).toString());\n }\n\n else insertOrUpdateItem();\n }",
"private void validText(String s){\n if(s.length() > 0 && MovieList.getInstance(this).isKeyAvailable(s)){\n btn = (Button)findViewById(R.id.keyCheckButton);\n btn.setEnabled(true);\n } else {\n btn.setEnabled(false);\n }\n\n }",
"public void actionPerformed(ActionEvent e) {\r\n\r\n count++;\r\n\r\n if (count == 1 || count == 3 || count == 5 || count == 7 || count == 9) {\r\n\r\n letter = \"X\";\r\n\r\n } else if (count == 2 || count == 4 || count == 6 || count == 8 || count == 10) {\r\n\r\n letter = \"O\";\r\n }\r\n\r\n if (e.getSource() == b1) {\r\n\r\n b1.setText(letter);\r\n b1.setEnabled(false);\r\n\r\n } else if (e.getSource() == b2) {\r\n\r\n b2.setText(letter);\r\n b2.setEnabled(false);\r\n\r\n } else if (e.getSource() == b3) {\r\n\r\n b3.setText(letter);\r\n b3.setEnabled(false);\r\n\r\n } else if (e.getSource() == b4) {\r\n\r\n b4.setText(letter);\r\n b4.setEnabled(false);\r\n\r\n } else if (e.getSource() == b5) {\r\n\r\n b5.setText(letter);\r\n b5.setEnabled(false);\r\n\r\n } else if (e.getSource() == b6) {\r\n\r\n b6.setText(letter);\r\n b6.setEnabled(false);\r\n\r\n } else if (e.getSource() == b7) {\r\n\r\n b7.setText(letter);\r\n b7.setEnabled(false);\r\n\r\n } else if (e.getSource() == b8) {\r\n\r\n b8.setText(letter);\r\n b8.setEnabled(false);\r\n\r\n } else if (e.getSource() == b9) {\r\n\r\n b9.setText(letter);\r\n b9.setEnabled(false);\r\n }\r\n\r\n// ========================= Horizontal Condition =========================\r\n if (b1.getText() == b2.getText() && b2.getText() == b3.getText() && b1.getText() != \"\") {\r\n\r\n win = true;\r\n } else if (b4.getText() == b5.getText() && b5.getText() == b6.getText() && b4.getText() != \"\") {\r\n\r\n win = true;\r\n } else if (b7.getText() == b8.getText() && b8.getText() == b9.getText() && b7.getText() != \"\") {\r\n\r\n win = true;\r\n } // ========================= Vertical Condition =========================\r\n else if (b1.getText() == b4.getText() && b4.getText() == b7.getText() && b1.getText() != \"\") {\r\n\r\n win = true;\r\n } else if (b2.getText() == b5.getText() && b5.getText() == b8.getText() && b2.getText() != \"\") {\r\n\r\n win = true;\r\n } else if (b3.getText() == b6.getText() && b6.getText() == b9.getText() && b3.getText() != \"\") {\r\n\r\n win = true;\r\n } // ========================= Diagonal Alignment =========================\r\n else if (b1.getText() == b5.getText() && b5.getText() == b9.getText() && b1.getText() != \"\") {\r\n\r\n win = true;\r\n } else if (b3.getText() == b5.getText() && b5.getText() == b7.getText() && b3.getText() != \"\") {\r\n\r\n win = true;\r\n } else {\r\n\r\n win = false;\r\n }\r\n\r\n// ========================= who win the game =========================\r\n if (win == true) {\r\n\r\n JOptionPane.showMessageDialog(null, letter + \" wins !\", \"Who will win he game\", JOptionPane.INFORMATION_MESSAGE);\r\n\r\n int answer = JOptionPane.showConfirmDialog(null, \"Would you like to play again ?\", \"Confirm\", JOptionPane.YES_NO_OPTION);\r\n\r\n if (answer == JOptionPane.NO_OPTION) {\r\n\r\n System.exit(0);\r\n } else {\r\n\r\n reset();\r\n }\r\n } else if (win == false && count == 9) {\r\n\r\n JOptionPane.showMessageDialog(null, \"game draw !\", \"Who will win he game\", JOptionPane.INFORMATION_MESSAGE);\r\n\r\n int answer = JOptionPane.showConfirmDialog(null, \"Would you like to play again ?\", \"Confirm\", JOptionPane.YES_NO_OPTION);\r\n\r\n if (answer == JOptionPane.NO_OPTION) {\r\n\r\n System.exit(0);\r\n } else {\r\n\r\n reset();\r\n }\r\n }\r\n\r\n }",
"private void invalidTry(){\n setButtons(false);\n setMsgText(\"There are 2 players in game, you cannot join in now.\");\n }",
"@Override\n\tpublic void afterTextChanged(Editable s) {\n\t\tcheckButtonsEnable();\n\t}",
"public void resetSpecialChars(){\r\n //When a Greek symbols is missing (Backspace) from the Text Field its corresponding Greek button gets Enabled\r\n if(!anglefield.getText().contains(\"α\"))alpha_btn.setDisable(false);\r\n if(!anglefield.getText().contains(\"β\"))beta_btn.setDisable(false);\r\n if(!anglefield.getText().contains(\"γ\"))gamma_btn.setDisable(false);\r\n if(!anglefield.getText().contains(\"δ\"))delta_btn.setDisable(false);\r\n if(!anglefield.getText().contains(\"θ\"))theta_btn.setDisable(false);\r\n if(!anglefield.getText().contains(\"ɸ\"))phi_btn.setDisable(false);\r\n }",
"public void removeWrongAnswer (char button)\n {\n if (button=='A')\n a.setEnabled(false);\n else if (button=='B')\n b.setEnabled(false);\n else if (button=='C')\n c.setEnabled(false);\n else\n d.setEnabled(false);\n feedbackLabel.setVisible(true);\n }",
"void actionButton ( ) throws IOException {\n String textOfField = this.gui.wdgInputText.getText();\n this.gui.widgOutput.append(\"Button1 \" + (++this.ctKeyStroke1) + \" time, text=\" + textOfField + \"\\n\");\n }",
"private void donePressed() {\n\n checkUnPressed();\n\n try {\n DictionaryAssignment3.result.setText(\"\");\n DictionaryAssignment3.mytext.setText(enteredStringSroggle);\n } catch (Exception e) {\n e.printStackTrace();\n }\n if (((enteredStringSroggle + \"\\n\").equalsIgnoreCase(DictionaryAssignment3.result.getText().toString())) && (!wordsDetectedByUser.containsValue(enteredStringSroggle))) {\n //Entering text to the screen\n\n\n\n // if(!wordsDetectedByUser.containsValue(enteredStringSroggle)) {\n wordsDetectedByUser.put(hashKey, enteredStringSroggle);\n e.append(enteredStringSroggle + \" \");\n hashKey++;\n //}else\n //{\n // Thread showWordAlreadyDetected = new Thread(new WordcantAccept());\n //notValidWord = true;\n //mHandler.removeCallbacks(mRunnable);\n // m1Handler.postDelayed(m1Runnable, 300);\n // }\n if (!phaseTwo) {\n //Clearing off redundant buttons\n for (int i = 0; i < 9; i++) {\n TileAssignment5 tile = mSmallTiles[touchedLargeTile][i];\n if (tile.getOwner() != TileAssignment5.Owner.CLICKED) {\n // if (!phaseTwo) {\n tile.updateDrawableState(' ', 1);\n // }\n } else {\n\n switch (enteredStringSroggle.length()) {\n case 9:\n updateScore(((Button) mSmallTiles[touchedLargeTile][i].getView()).getText().toString(), 50);\n break;\n case 5:\n case 6:\n updateScore(((Button) mSmallTiles[touchedLargeTile][i].getView()).getText().toString(), 5);\n break;\n case 7:\n updateScore(((Button) mSmallTiles[touchedLargeTile][i].getView()).getText().toString(), 20);\n break;\n case 8:\n updateScore(((Button) mSmallTiles[touchedLargeTile][i].getView()).getText().toString(), 30);\n break;\n\n default:\n updateScore(((Button) mSmallTiles[touchedLargeTile][i].getView()).getText().toString(), 1);\n\n }\n }\n\n }\n setAvailableFromLastMove(touchedLargeTile, 0);\n\n\n DoneTiles.add(touchedLargeTile);\n\n DictionaryAssignment3.result.setText(\"\");\n\n\n } else {\n\n for (int i = 0; i < 9; i++) {\n for (int j = 0; j < 9; j++) {\n TileAssignment5 tile = mSmallTiles[i][j];\n if (tile.getOwner() == TileAssignment5.Owner.CLICKED) {\n\n switch (enteredStringSroggle.length()) {\n case 9:\n updateScore(((Button) mSmallTiles[i][j].getView()).getText().toString(), 50);\n break;\n case 5:\n case 6:\n updateScore(((Button) mSmallTiles[i][j].getView()).getText().toString(), 5);\n break;\n case 7:\n updateScore(((Button) mSmallTiles[i][j].getView()).getText().toString(), 20);\n break;\n case 8:\n updateScore(((Button) mSmallTiles[i][j].getView()).getText().toString(), 30);\n break;\n\n default:\n updateScore(((Button) mSmallTiles[i][j].getView()).getText().toString(), 1);\n\n }\n DictionaryAssignment3.result.setText(\"\");\n\n }\n }\n }\n\n }\n } else {\n // canShowDialogBox= true;\n // if (!notValidWord ) {\n // canShowDialogBox =false;\n\n for (int i = 0; i < 9; i++) {\n for (int j = 0; j < 9; j++) {\n TileAssignment5 tile = mSmallTiles[i][j];\n if (tile.getOwner() == TileAssignment5.Owner.CLICKED) {\n if(!DoneTiles.contains(i)){popup = true;}\n atLeastOneClicked = true;\n }\n if (atLeastOneClicked&&popup) break;\n }\n }\n if (atLeastOneClicked) {\n atLeastOneClicked = false;\n if(!phaseTwo){\n if(popup) {\n popup = false;\n e = (TextView) getActivity().findViewById(R.id.scroggle_text_view);\n // e.a ppend(\" \");\n TileAssignment5 tile = mLargeTiles[touchedLargeTile];\n builder = new AlertDialog.Builder(getActivity());\n builder.setMessage(\"Not a Valid Word !\");\n builder.setCancelable(false);\n builder.setPositiveButton(R.string.ok_label,\n new DialogInterface.OnClickListener() {\n @Override\n public void onClick(DialogInterface dialogInterface, int i) {\n\n }\n });\n mDialog = builder.show();\n\n // for(int i =0;i<3;i++){\n tile.animate();\n\n for (int i = 0; i < 9; i++) {\n TileAssignment5 tiles = mSmallTiles[touchedLargeTile][i];\n tiles.setOwner(TileAssignment5.Owner.NOTCLICKED);\n tiles.updateDrawableState('a', 0);\n addAvailable(tiles);}\n }}\n else{\n e = (TextView) getActivity().findViewById(R.id.scroggle_text_view);\n // e.a ppend(\" \");\n TileAssignment5 tile = mLargeTiles[touchedLargeTile];\n builder = new AlertDialog.Builder(getActivity());\n builder.setMessage(\"Not a Valid Word !\");\n builder.setCancelable(false);\n builder.setPositiveButton(R.string.ok_label,\n new DialogInterface.OnClickListener() {\n @Override\n public void onClick(DialogInterface dialogInterface, int i) {\n\n }\n });\n mDialog = builder.show();\n\n // for(int i =0;i<3;i++){\n // tile.animate();\n for (int i = 0; i < 9; i++) {\n for (int j = 0; j < 9; j++) {\n TileAssignment5 tiles = mSmallTiles[i][j];\n if (tiles.getOwner() == TileAssignment5.Owner.CLICKED) {\n tiles.setOwner(TileAssignment5.Owner.NOTCLICKED);\n }\n tiles.updateDrawableState('a', 0);\n\n\n }\n }\n\n }\n\n //try {\n //Thread.sleep(500);\n //} catch (InterruptedException e1) {\n // e1.printStackTrace();\n //}}\n\n\n /*else {\n for (int i = 0; i < 9; i++) {\n for (int j = 0; j < 9; j++) {\n TieAssignment5 tiles = mSmallTiles[i][j];\n if (tiles.getOwner() == ileAssignment5.Owner.CLICKED) {\n tiles.setOwner(ileAssignment5.Owner.NOTCLICKED);\n }\n tiles.updateDrawableState('a', 0);\n\n\n }\n }\n }\n*/\n\n DictionaryAssignment3.result.setText(\"\");\n enteredStringSroggle = \"\";\n // done = false;\n // for (int x = 0; x < touchedSmallTiles.length; x++) {\n // touchedSmallTiles[x] = 0;\n //}\n //touchedLargeTile = 0;\n\n // }\n }\n\n }\n if(phaseTwo){\n\n for(int i = 0; i<9 ; i++) {\n for (int dest = 0; dest < 9; dest++) {\n TileAssignment5 tile = mSmallTiles[i][dest];\n if (tile.getOwner() == TileAssignment5.Owner.CLICKED) {\n tile.setOwner(TileAssignment5.Owner.NOTCLICKED);\n if (mAvailable.contains(tile)) {\n mAvailable.remove(tile);\n }\n tile.updateDrawableState(' ', 1);\n } else {\n if(((Button)mSmallTiles[i][dest].getView()).getText().charAt(0)==' '){\n mAvailable.remove(tile);\n }else{\n addAvailable(tile);}\n tile.setOwner(TileAssignment5.Owner.NOTCLICKED);\n tile.updateDrawableState('a', 0);\n }\n }\n }\n\n }\n\n //if same word is entered again\n /* if(notValidWord){\n notValidWord = false;\n for(int i = 0; i<9 ; i++) {\n for (int dest = 0; dest < 9; dest++) {\n ileAssignment5 tile = mSmallTiles[i][dest];\n if((tile.getOwner()== ileAssignment5.Owner.CLICKED)||(tile.getOwner()== ileAssignment5.Owner.FREEZED)){\n tile.setOwner(ileAssignment5.Owner.NOTCLICKED);\n tile.updateDrawableState('a', 0);\n }\n if(((Button)tile.getView()).getText().charAt(0)==' '){\n mAvailable.remove(tile);\n }else {\n addAvailable(tile);\n }\n }\n }\n }*/\n // done = false;\n\n if (!phaseTwo) {\n if (touchedLargeTile == 0) {\n for (int i = 0; i < 9; i++) {\n TileAssignment5 tiles = mSmallTiles[touchedLargeTile][i];\n if ((tiles.getOwner() == TileAssignment5.Owner.NOTCLICKED)&&(((Button)tiles.getView()).getText().charAt(0)!=' ')) {\n\n addAvailable(tiles);\n }\n }\n\n }\n }\n for (int x = 0; x < touchedSmallTiles.length; x++) {\n touchedSmallTiles[x] = 0;\n }\n touchedLargeTile = 0;\n DictionaryAssignment3.result.setText(\"\");\n\n enteredStringSroggle = \"\";\n }",
"private void checkCanEat(TextButton camp) {\n\t\tif (character.getFood() < character.getMetabolicRate()) {\n\t\t\tTextButtonStyle style = new TextButtonStyle(camp.getStyle());\n\t\t\tstyle.fontColor = Color.RED;\n\t\t\tcamp.setStyle(style);\n\t\t\tcamp.setTouchable(Touchable.disabled);\n\t\t}\n\t}",
"public void btnC(View v) {\n\n if (!displayResult.getText().equals(\"0\")) {\n\n int widthString = displayResult.getText().length();\n\n StringBuffer buffer = new StringBuffer( displayResult.getText());\n\n buffer.delete(widthString-1, widthString);\n\n displayResult.setText(buffer.toString());\n\n if (displayResult.getText().equals(\"\")) {\n\n displayResult.setText(\"0\");\n point = false;\n\n }\n }\n }",
"public void actionPerformed(ActionEvent e) {\n String your_answer = JOptionPane.showInputDialog(Que);\n JOptionPane.showMessageDialog(null, \"Reference and yours: \"+ Right_Answer +\" Vs \" + your_answer);\n JButton source = (JButton) e.getSource();\n source.setEnabled(false);\n System.out.println(Right_Answer.length());\n System.out.println(your_answer.length());\n\n //adds point if your right\n if (your_answer.equalsIgnoreCase(Right_Answer.trim())) {\n source.setBackground(Color.GREEN);\n score1++;\n text.setText(\"Correct:\"+score1);\n }\n //add point if your wrong \n else {\n source.setBackground(Color.red);\n score2++;\n text1.setText(\"Wrong:\"+score2);\n }\n //adds all points \n total=score1+score2;\n text2.setText(\"Total:\"+total);\n }",
"public void onClick(View v) {\n if (mBluetoothReader == null) {\n mTxtEscapeResponse.setText(R.string.card_reader_not_ready);\n return;\n }\n\n /* Retrieve escape command from edit box. */\n byte escapeCommand[] = Utils.getEditTextinHexBytes(mEditEscape);\n\n if (escapeCommand != null && escapeCommand.length > 0) {\n /* Clear response field for result of escape command. */\n mTxtEscapeResponse.setText(R.string.noData);\n\n /* Transmit escape command. */\n if (!mBluetoothReader.transmitEscapeCommand(escapeCommand)) {\n mTxtEscapeResponse\n .setText(R.string.card_reader_not_ready);\n }\n } else {\n mTxtEscapeResponse.setText(\"Character format error!\");\n }\n }",
"public void redo(){\n\t\tthis.setButtonVisible(true);\n\t}",
"private boolean markButton( int i, String mark ) {\n\tif ( button[i].getText( ).equals( \"\" ) ) {\n\t button[i].setText( mark );\n\t button[i].setEnabled( false );\n\t return true;\n\t}\n\treturn false;\n }",
"private void checkActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_checkActionPerformed\n \n if (check.isSelected()) {\n\n Password.setEchoChar((char) 0);\n } else {\n Password.setEchoChar('*');\n }\n }",
"@Override\n public boolean play(String btn)\n {\n return btn.isEmpty();\n }",
"@Override\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\ttext.setText(cancel.getText());\n\t\t\t}",
"public void setLetter() {\n\t\tconfirmButton.setEnabled(true);\n\t\tpassButton.setEnabled(true);\n\t\tfor (int i = 0; i < ROW; i++) {\n\t\t\tfor (int j = 0; j < COLUME; j++) {\n\t\t\t\tif (board[i][j].getText().equals(\"\")) {\n\t\t\t\t\tboard[i][j].setEditable(true);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}",
"public void actionPerformed(ActionEvent e) {\n if(e.getSource() == confirmButton) {\n setVisible(false); // causes all the add text \n }\n else if(e.getSource() == exitButton) {\n System.exit(0);\n }\n }",
"@Override\r\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\tif(e.getSource() == b) {\r\n\t\t\t\t\ttext.setText(\"8\");\r\n\t\t\t\t}\r\n\t\t\t}",
"private void setCharButton(int i, int xPos, int yPos, boolean clickable) {\r\n final JButton jLabel = new JButton(String.valueOf((char) i));\r\n jLabel.setFont(serif24);\r\n panel.add(jLabel);\r\n Dimension size = jLabel.getPreferredSize();\r\n jLabel.setBounds(xPos, yPos, size.width, size.height);\r\n\r\n if (clickable) {\r\n jLabel.addActionListener(new ActionListener() {\r\n @Override\r\n public void actionPerformed(ActionEvent e) {\r\n guess(jLabel); //A guess of a character was made.\r\n }\r\n });\r\n }\r\n }",
"@Override\n public void actionPerformed(ActionEvent arg0) {\n if (zalozenaHra == false) {\n gameConnectButton.setEnabled(false);\n newGameButton.setText(\"Zrus zalozeni\");\n zalozenaHra = true;\n komunikace.CreateGame();\n } else {\n gameConnectButton.setEnabled(true);\n newGameButton.setText(\"Zaloz hru\");\n zalozenaHra = false;\n komunikace.cancelGame();\n }\n\n }",
"@Override\n\tpublic void actionPerformed(ActionEvent ae) {\n\t\tif(ae.getActionCommand().equals(\"Ação 3\"));\n\t\tSystem.out.println(\"Clicke no botão 3\");\n\t\t\n\t}",
"@Override\n public void onClick(View V){\n int r = 0; int c = 0;\n boolean broke = false;\n //finds the coordinates of the button that was clicked\n for(; r < 4; r++){\n for(c = 0; c < 4; c++){\n if(V.getId() == grid.getIDAt(r, c)) {\n broke = true;\n break;\n }\n }\n if(broke)\n break;\n }\n if(!broke)\n return;\n broke = false;\n int rBlank = 0;\n int cBlank = 0;\n //checks to see if the move is legal, and performs it if it is\n for(; rBlank < 4; rBlank++){\n for(cBlank = 0; cBlank < 4; cBlank++){\n if(grid.getButtonAt(rBlank, cBlank).getText() == \"\") {\n broke = true;\n if((r == rBlank && c == cBlank+1) || (r == rBlank && c == cBlank-1)\n || (r == rBlank+1 && c == cBlank) || (r == rBlank-1 && c == cBlank)){\n CharSequence tmp = grid.getButtonAt(r, c).getText();\n grid.getButtonAt(r, c).setText(grid.getButtonAt(rBlank, cBlank).getText());\n grid.getButtonAt(rBlank, cBlank).setText(tmp);\n }\n break;\n }\n }\n if(broke)\n break;\n }\n solved = grid.checkCorrect(correct);\n }",
"@Override\n public void actionPerformed(ActionEvent e) {\n CheckOperation(calButtons.super.getText());\n }",
"public void uiVerifyButtonUndoEnable() {\n try {\n getLogger().info(\"Verify button Undo Todo enable.\");\n Thread.sleep(largeTimeOut);\n\n if (btnToDoUndo.getAttribute(\"class\").toString().equals(\"fa fa-undo\")) {\n NXGReports.addStep(\"Verify button Undo Todo enable.\", LogAs.PASSED, null);\n } else {\n AbstractService.sStatusCnt++;\n NXGReports.addStep(\"verify button Undo Todo enable.\", LogAs.FAILED, new CaptureScreen(CaptureScreen.ScreenshotOf.BROWSER_PAGE));\n }\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n }",
"@Override\n public boolean onKeyUp(int keyCode, KeyEvent event) {\n\n //if(afterCheck==false) {\n //get char pressed by user from keyboard\n char keyPressed = (char) event.getUnicodeChar();\n if(userTurn==true) {\n if (afterCheck == false) {\n //check whether character pressed is valid i.e between a to z\n if (Character.isLetter(keyPressed)) {\n currentWord = ghostT.getText().toString();\n currentWord += keyPressed;\n ghostT.setText(currentWord);\n\n status.setText(COMPUTER_TURN);\n //set Computer turn\n userTurn = false;\n // challenge.setEnabled(false);\n handler = new Handler();\n handler.postDelayed(new Runnable() {\n @Override\n public void run() {\n //Do something after 2seconds\n //invoke computerturn\n computerTurn();\n }\n }, 2000);\n //invoke computerturn\n //computerTurn();\n\n //check validity for user input\n /**if (dictionary.isWord(currentWord)) {\n status.setText(\"VALID WORD\");\n } else\n status.setText(\"INVALID WORD\");\n return true;\n **/\n return true;\n\n } else {\n Toast.makeText(this, \"Invalid INPUT\", Toast.LENGTH_SHORT).show();\n return super.onKeyUp(keyCode, event);\n }\n }\n }\n\n return false;\n }",
"@Override\n public void onClick(View v) {\n String reception = mEmission.getText().toString();\n Log.i(\"debug\", \"onEditorAction:\" + reception);\n\n if (!reception.equals(\"\")) {\n if (Convert.isHexAnd16Byte(reception, ICCActivity.this)) {\n mNo.append(\"SEND: \" + reception + \"\\n\");\n byte[] apdu = Convert.hexStringToByteArray(reception);\n sendCmd(apdu, 1);\n }\n } else {\n Toast.makeText(ICCActivity.this, \"please input content\", Toast.LENGTH_SHORT).show();\n }\n }",
"@Override\r\n\t\tpublic void actionPerformed (ActionEvent e) {\n\t\t\tJButton c = (JButton) e.getSource();\r\n\t\t\tmakemove(c);\r\n\t\t\tgamestatus gs = getgamestatus();\r\n\t\t\tif (gs == gamestatus.incomplete) {\r\n\t\t\t\treturn;\r\n\t\t\t}\r\n\t\t\tdeclarewinner(gs);\r\n\t\t\tint choice = JOptionPane.showConfirmDialog(this, \"Restart?\");\r\n\t\t\tif (choice == JOptionPane.YES_OPTION) {\r\n\t\t\t\tfor (int row = 0; row < board; row++) {\r\n\t\t\t\t\tfor (int col = 0; col < board; col++) {\r\n\t\t\t\t\t\tbuttons[row][col].setText(\"\");// to to blank after restart\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t\tthis.crosscheck = true;\r\n\t\t\t} else {\r\n\t\t\t\tsuper.dispose(); // to close the game on no \r\n\t\t\t}\r\n\t\t}",
"protected boolean hasPositiveButton() {\n return false;\n }",
"public void updateButton(boolean done) {\n\t\tdiceBtn.setDisable(done);\n\t\tendTurn.setDisable(!done);\n\t}",
"@Override\n\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\tif (button_SFX.getText().equals(\"효과음 : On\")){\n\t\t\t\tsfx=false;\n\t\t\t\tbutton_SFX.setText(\"효과음 : off\");\n\t\t\t}\n\t\t\telse{\n\t\t\t\tsfx=true;\n\t\t\t\tbutton_SFX.setText(\"효과음 : On\");\n\t\t\t}\n\t\t}",
"protected void createButtonActionPerformed(ActionEvent evt) {\r\n\t\t// TODO Auto-generated method stub\r\n\t\ttextArea.append(\"My mark is X\\n\");\r\n\t\tmyMark =\"X\";\r\n\t\tyourMark=\"O\";\r\n\t\tnew CreateButtonThread(\"CreateButton\");\t\t\t\t\t\r\n\t}",
"@Override\r\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\tif(e.getSource() == c) {\r\n\t\t\t\t\ttext.setText(\"9\");\r\n\t\t\t\t}\r\n\t\t\t}",
"@Override\n\tpublic boolean activate() {\n\t\tfinal Component CANCEL_BUTTON = CONSTS.CANCEL_BUTTON;\n\t\treturn ctx.backpack.select().id(CONSTS.fletching.getId()).count() >= 1\n\t\t\t\t&& !CANCEL_BUTTON.valid() \n\t\t\t\t&& !CANCEL_BUTTON.visible();\n\t}",
"public void actionPerformed(ActionEvent e) {\n\t\t\t\t\t\t\t\t\t\t\t\t\t\thintButton.setVisible(false);\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tbtnBuyHint.setVisible(true);\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tchangeStart.setVisible(true);\n\t\t\t\t\t\t\t\t\t\t\t\t\t\ttextField.setVisible(true);\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tmainLabel.setText(\"<html> If you would like some hints & tips about the economy, type in what you want to know more about in the following box. If not, press Continue. Think before you click Get Hint to generate your hint since you only have one chance to get a hint each turn! </html> \");\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tbtnBuyHint.addActionListener(new ActionListener() {\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tif((textField.getText()).equals(\"\"))\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tmainLabel.setText(\"Please enter what you want to be hinted on. Or press Continue.\");\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tString print = \"\";\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tString y = \"\" + FuzzySearch.extractOne(textField.getText(), hints);\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tfor(int i = 0; i < y.length(); i++)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tif(y.indexOf(':') == i)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tprint = y.substring(i);\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tmainLabel.setText(\"<html> Hint\" + print + \"</html>\");\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tbtnBuyHint.setVisible(false);\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\ttextField.setVisible(false);\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t//remove the printed thing from the list\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\thints.remove(print);\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tchangeStart.setVisible(true);\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t}",
"@Override\n\t\t\tpublic void afterTextChanged(Editable s) {\n\t\t\t\tif (s.length() > 0) {\n\t\t\t\t\tmSendMsgBtn.setEnabled(true);\n\t\t\t\t} else {\n\t\t\t\t\tmSendMsgBtn.setEnabled(false);\n\t\t\t\t}\n\t\t\t}",
"@Override\n\t\t\tpublic void onClick(View v) {\n\n\t\t\t\toptb=btnoptb.getText().toString();\n\t\t\t\tCheckAns(optb,currentPosition);\n\t\t\t\t//Log.e(\"ans\", optb);\n\n\t\t\t}",
"@Override\n public void onTextChanged(CharSequence charSequence, int i, int i1, int i2) {\n if (!String.valueOf(charSequence).equals(\"\") && all_ingredients.containsKey(charSequence.toString()))\n add_button.setEnabled(true);\n else\n add_button.setEnabled(false);\n }",
"@Override\r\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\tbtTranslate.setEnabled(false);\r\n\t\t\t\tbtTranslate.setText(\"正在翻译..\");\r\n\t\t\t\tString re = Languages.translate(taResult.getText());\r\n\t\t\t\tif(\"\"==re || null==re){\r\n\t\t\t\t\treturn;\r\n\t\t\t\t}\r\n\t\t\t\ttaTranslate.setText(re);\r\n\t\t\t\tbtTranslate.setEnabled(true);\r\n\t\t\t\tbtTranslate.setText(\"翻译\");\r\n\t\t\t}",
"public boolean checkRow() {\n\t\t// conditions fo player X\n\t\tif ((bt[0].getText().equals(\"X\") && bt[1].getText().equals(\"X\") && bt[2].getText().equals(\"X\"))\n\t\t\t\t|| (bt[3].getText().equals(\"X\") && bt[4].getText().equals(\"X\") && bt[5].getText().equals(\"X\"))\n\t\t\t\t|| (bt[6].getText().equals(\"X\") && bt[7].getText().equals(\"X\") && bt[8].getText().equals(\"X\"))) {\n\t\t\tjtf.setText(\" PLAYER X WON!\");\n\t\t\tjtf.setForeground(Color.red);\n\t\t\tjtf.setFont(new Font(\"Arial Black\", Font.BOLD, 50));\n\t\t\tfor (i = 0; i < xo.length; i++) {\n\t\t\t\tbt[i].setEnabled(false);\n\t\t\t}\n\t\t\treturn true;\n\t\t}\n\t\t// conditions fo player O\n\t\tif ((bt[0].getText().equals(\"O\") && bt[1].getText().equals(\"O\") && bt[2].getText().equals(\"O\"))\n\t\t\t\t|| (bt[3].getText().equals(\"O\") && bt[4].getText().equals(\"O\") && bt[5].getText().equals(\"O\"))\n\t\t\t\t|| (bt[6].getText().equals(\"O\") && bt[7].getText().equals(\"O\") && bt[8].getText().equals(\"O\"))) {\n\t\t\tjtf.setText(\" PLAYER O WON!\");\n\t\t\tjtf.setForeground(Color.blue);\n\t\t\tjtf.setFont(new Font(\"Arial Black\", Font.BOLD, 50));\n\t\t\tfor (i = 0; i < xo.length; i++) {\n\t\t\t\tbt[i].setEnabled(false);\n\t\t\t}\n\t\t\treturn true;\n\t\t}\n\n\t\treturn false;\n\t}",
"@Override\n public void onClick(View v) {\n TextView tries_tv;\n tries_tv = findViewById(R.id.notries_Textview);\n // set this back to 1\n tries_tv.setText(R.string.default_tries);\n // set the RelativeLayout invisible again\n tries.setVisibility(View.GONE);\n // reset the \"Press to top out text\"\n completeBoulder.setText(getResources().getString(R.string.topout));\n }",
"protected abstract void pressedOKButton( );",
"@Override\n\t\t\tpublic void onClick(View v) {\n\t\t\t\toptc=btnoptc.getText().toString();\n\t\t\t\tCheckAns(optc,currentPosition);\n\t\t\t\t//Log.e(\"ans\", optc);\n\n\t\t\t}",
"public void uiVerifyButtonUndoExist() {\n try {\n getLogger().info(\"Verify button Undo Todo exist.\");\n btnToDoUndo.getAttribute(\"class\");\n NXGReports.addStep(\"Verify button Undo Todo exist.\", LogAs.PASSED, null);\n } catch (Exception ex) {\n getLogger().info(ex);\n AbstractService.sStatusCnt++;\n NXGReports.addStep(\"verify button Undo Todo exist.\", LogAs.FAILED, new CaptureScreen(CaptureScreen.ScreenshotOf.BROWSER_PAGE));\n }\n }",
"@Override\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\tif (typeCombox.getSelectedIndex() == 0) {\n\t\t\t\t\tunitText.setText(\"s\");\n\t\t\t\t\tunitText.setEnabled(false);\n\t\t\t\t} else {\n\t\t\t\t\tunitText.setText(\"\");\n\t\t\t\t\tunitText.setEnabled(true);\n\t\t\t\t}\n\t\t\t}",
"@Override\n public void onClick(DialogInterface dialog, int which) {\n Utility.hideKeyBoard(editText, mContext);\n if (editText.getText().toString().trim().length() > 0) {\n pump_type.setText(editText.getText().toString().trim());\n } else {\n pump_type.setText(\"\");\n }\n }",
"public void onButtonClicked(){\n\t\t\n\t\t//Gets the guess from text box \n\t\tString guess = AnswerBox.getText();\n\t\t//converts string to lower case\n\t\tguess = guess.toLowerCase();\n\t\t//protects against empty textbox, long strings, and non alphabet characters\n\t\tif (guess != \"\" && guess.length() == 1 && guess.charAt(0) >='a' && guess.charAt(0) <= 'z')\n\t\t{\n\t\t\t//convert String to char\n\t\t\tchar myGuess = guess.charAt(0);\n\t\t\t//test to see if letter is in secretWord\n\t\t\tif(guessIsRight(mysteryWord,myGuess)){ \n\t\t\t\n\t\t\t\t//change _ to letter if player made correct guess\n\t\t\t\tupdateWordState(mysteryWord,myGuess); \n\n\t\t\t\tif (wordState.compareTo(mysteryWord)==0) {\n\t\t\t\t\tGameWin();} \n\t\t\t\t\n\t\t\t}\n\t\t\telse{\n\t\t\t\t//update hangman picture \n\t\t\t\t//make part of hangmanPicture visible if player made incorrect guess\n\t\t\t\t\n\t\t\t\t// add missed letters to incorrect letters bank\n\t\t\t\taddLettersGuessed(myGuess); \n\t\t\t\t\n\t\t\t\tnumGuesses--;\n\t\t\t\tmakeVisible(numGuesses);\n\t\t\t}\n\t\t\t\n\t\t\tAnswerBox.requestFocus(); // set focus on textbox \n\t\t}\n\t\telse\n\t\t{\n\t\t\t// print a message if the user didn't write a letter\n\t\t\tAnswerBox.setText(\"Your guess must be a single letter\");\n\t\t\tAnswerBox.requestFocus(); \n\t\t}\n\t}",
"public void onClick(View view) {\n if(Instruction.getText().length()>=0) {\n //do something\n\n }\n else {\n\n }\n\n }",
"public void onClickButton1(View view) {\n\n if (turn%2 == 0 && button1.getText()==\"·\"){\n button1.setText(\"O\");\n turn++;\n }\n else if (button1.getText()==\"·\"){\n button1.setText(\"X\");\n turn++;\n }\n\n }",
"abstract public boolean onPositiveClicked(String userInput);",
"@Override\n\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\tString word=v.getInput().getText();\n\t\t\tlong t1=System.nanoTime();\n\t\t\tif(m.wordExists(word)){\n\t\t\t\tv.getCheck().setText(word+\" exists.\");\n\t\t\t}else{\n\t\t\t\tv.getCheck().setText(word + \" does not exist.\");\n\t\t\t}\n\t\t\tlong t2=System.nanoTime();\n\t\t\tlong dt=t2-t1;\n\t\t\tv.getTime().setText(dt+\" NanoSec\");\n\t\t\tv.getInput().setText(\"\");\n\t\t\t\n\t\t}",
"@Override\n public void onClick(DialogInterface dialog, int which) {\n Utility.hideKeyBoard(editText, mContext);\n if (editText.getText().toString().trim().length() > 0) {\n pump_no.setText(editText.getText().toString().trim());\n } else {\n pump_no.setText(\"\");\n }\n }",
"public void updateButtons(){\n\t\tif (Player.getPlayer(this).questManager.atMaxNumQuests()) {\n\t\t\tcreateQuest.setEnabled(false);\n\t\t} else {\n\t\t\tcreateQuest.setEnabled(true);\n\t\t}\n\t\tif (selectedQuest != null){\n\t\t\tdeleteQuest.setEnabled(true);\n\t\t\tcompleteQuest.setEnabled(true);\n\t\t} else {\n\t\t\tdeleteQuest.setEnabled(false);\n\t\t\tcompleteQuest.setEnabled(false);\n\t\t}\n\t}",
"private void newWord() {\r\n defaultState();\r\n int random_id_String = 0;\r\n int random_id_Char[] = new int[4];\r\n Random random = new Random();\r\n if (wordNumber == WordCollection.NO_OF_WORDS) return;//quit if all word list is complete;\r\n wordNumber++;\r\n //in case the word has already occured\r\n while (currentWord.equals(\"\")) {\r\n random_id_String = random.nextInt(WordCollection.NO_OF_WORDS);\r\n currentWord = tempWord[random_id_String];\r\n }\r\n currentWord.toUpperCase();\r\n tempWord[random_id_String] = \"\";//so that this word will not be used again in the game session\r\n //generates 4 random nums each for each btn char\r\n for (int i = 0; i < 4; i++) {\r\n random_id_Char[i] = (random.nextInt(4));\r\n for (int j = i - 1; j >= 0; j--) {\r\n if (random_id_Char[i] == random_id_Char[j]) i--;\r\n }\r\n }\r\n\r\n btn1.setText((currentWord.charAt(random_id_Char[0]) + \"\").toUpperCase());\r\n btn2.setText((currentWord.charAt(random_id_Char[1]) + \"\").toUpperCase());\r\n btn3.setText((currentWord.charAt(random_id_Char[2]) + \"\").toUpperCase());\r\n btn4.setText((currentWord.charAt(random_id_Char[3]) + \"\").toUpperCase());\r\n }",
"private void pressed(int count, int button, JButton a) {\n if (winner) {\n return;\n }\n //when counter is even, X is placed in an empty spot\n if (count % 2 == 0) {\n tBoard[button] = 1; //all squares are set to two in the beginning, if a square has a 1 it is an X\n turn.setText(\"It is o's turn\"); //changes the turn to alert the person playing in the position of O that it is their turn\n a.setText(\"X\"); //sets button to show an X \n } else {\n tBoard[button] = 0; //all squares are set to two in the beginning, if a square has a 0 it is an 0\n turn.setText(\"It is x's turn\"); //changes the turn to alert the person playing in the position of X that it is their turn\n a.setText(\"O\"); //sets button to show an O\n }\n //disables the button that is pressed\n a.setEnabled(false);\n\n }",
"public void actionPerformed(ActionEvent e) {\n\t\t\tint encode;\n\n\t\t\tif (allowAll.isSelected()) {\n\t\t\t\tencode = EncodeBoard.USE_ALL_SYMBOLS;\n\t\t\t} else if (allowSome.isSelected()) {\n\t\t\t\tencode = EncodeBoard.USE_SOME_SYMBOLS;\n\t\t\t} else {\n\t\t\t\tencode = EncodeBoard.USE_NO_SYMBOLS;\n\t\t\t}\n\n\t\t\tgui.setPassword(DEFAULT_CHARS_PER_MOVE, encode);\n\t\t}",
"@Override\n public void onClick(View view) {\n if (!flag) {\n\n check_passwd_text.setTransformationMethod(SingleLineTransformationMethod.getInstance());\n flag = !flag;\n } else {\n check_passwd_text.setTransformationMethod(PasswordTransformationMethod.getInstance());\n flag = !flag;\n }\n }",
"public void actionPerformed(ActionEvent e) {\n\t\tplayerSelectNum++;\n\t\tfor (int i = 0; i<charButtons.size(); i++){\n\t\t\tif (e.getSource() == charButtons.get(i)){\n\t\t\t\tcharButtons.get(i).setEnabled(false);\n\t\t\t\tselection = new PlayerInfo(name, characters.get(i));\n\t\t\t\t\n\t\t\t}\n\t\t}\t\n\t\tif (playerSelectNum == 1){\n\t\t\tCLOGameClient c = new CLOGameClient(selection);\n\t\t\tdispose();\n\t\t}\n\t}",
"@Override\r\n public void keyReleased(KeyEvent e)\r\n {\r\n \r\n if(e.getKeyChar() == 'w')\r\n {\r\n buttons[0][0] = false;\r\n }\r\n if(e.getKeyChar() == 'a')\r\n {\r\n buttons[0][1] = false;\r\n }\r\n if(e.getKeyChar() == 's')\r\n {\r\n buttons[0][2] = false;\r\n }\r\n if(e.getKeyChar() == 'd')\r\n {\r\n buttons[0][3] = false;\r\n }\r\n if(e.getKeyChar() == 'f')\r\n {\r\n buttons[0][4] = false;\r\n }\r\n if(e.getKeyChar() == 'g')\r\n {\r\n buttons[0][5] = false;\r\n }\r\n if(e.getKeyCode() == KeyEvent.VK_UP)\r\n {\r\n buttons[1][0] = false;\r\n }\r\n if(e.getKeyCode() == KeyEvent.VK_LEFT)\r\n {\r\n buttons[1][1] = false;\r\n }\r\n if(e.getKeyCode() == KeyEvent.VK_DOWN)\r\n {\r\n buttons[1][2] = false;\r\n }\r\n if(e.getKeyCode() == KeyEvent.VK_RIGHT)\r\n {\r\n buttons[1][3] = false;\r\n }\r\n if(e.getKeyChar() == '.')\r\n {\r\n buttons[1][4] = false;\r\n }\r\n if(e.getKeyChar() == '/')\r\n {\r\n buttons[1][5] = false;\r\n }\r\n }",
"public void VerifyButtons(){\n if (currentTurn.getSiguiente() == null){\n next_turn.setEnabled(false);\n } else{\n next_turn.setEnabled(true);\n }\n if (currentTurn.getAnterior() == null){\n prev_turn.setEnabled(false);\n } else{\n prev_turn.setEnabled(true);\n }\n if (current.getSiguiente() == null){\n next_game.setEnabled(false);\n } else{\n next_game.setEnabled(true);\n }\n if (current.getAnterior() == null){\n prev_game.setEnabled(false);\n } else{\n prev_game.setEnabled(true);\n }\n }",
"public void actionPerformed(ActionEvent actionEvent) {\n\t\t\taddPlayer.setEnabled(false);\n\t\t\tnameField.setEnabled(false);\n\t\t\tplayGame.setEnabled(false);\n\t\t\ttakeTurn.setEnabled(true);\n\t\t\t\n\t\t\tgameText.append(\"\\n\\n\");\n\t\t}",
"public void showNextMovePrompt() {\n\n if(model.isXTurn()){\n resultLabel.setText(\"X's Turn\");\n }\n else{\n resultLabel.setText(\"O's Turn\");\n }\n }",
"@Override\r\n\tprotected void onBoEdit() throws Exception {\n\t\tgetButtonManager().getButton(\r\n\t\t\t\tnc.ui.wds.w8006080202.tcButtun.ITcButtun.Con)\r\n\t\t\t\t.setEnabled(false);\r\n\t\tgetButtonManager().getButton(\r\n\t\t\t\tnc.ui.wds.w8006080202.tcButtun.ITcButtun.Pp)\r\n\t\t\t\t.setEnabled(false);\r\n\t\tsuper.onBoEdit();\r\n\t}",
"private void commitAction(int buttonID){\n if (buttonID == R.id.buttonDEL) {\n if (inputConn != null)\n inputConn.deleteSurroundingText(1, 0);\n } else if (buttonID == R.id.buttonSHIFT) {\n toggleCase();\n }\n else if (buttonID == R.id.buttonALT){\n toggleAlt();\n }\n else if(buttonID == R.id.buttonSPACE) {\n if (inputConn != null)\n inputConn.commitText(\" \",1);\n }\n else if(buttonID == R.id.buttonENTER) {\n if (inputConn != null)\n inputConn.sendKeyEvent(new KeyEvent(KeyEvent.ACTION_DOWN, KeyEvent.KEYCODE_ENTER));\n inputConn.sendKeyEvent(new KeyEvent(KeyEvent.ACTION_UP, KeyEvent.KEYCODE_ENTER));\n }\n\n }",
"public boolean checkColumn() {\n\t\t// conditions fo player X\n\t\tif ((bt[0].getText().equals(\"X\") && bt[3].getText().equals(\"X\") && bt[6].getText().equals(\"X\"))\n\t\t\t\t|| (bt[1].getText().equals(\"X\") && bt[4].getText().equals(\"X\") && bt[7].getText().equals(\"X\"))\n\t\t\t\t|| (bt[2].getText().equals(\"X\") && bt[5].getText().equals(\"X\") && bt[8].getText().equals(\"X\"))) {\n\t\t\tjtf.setText(\" PLAYER X WON!\");\n\t\t\tjtf.setForeground(Color.red);\n\t\t\tjtf.setFont(new Font(\"Arial Black\", Font.BOLD, 50));\n\t\t\tfor (i = 0; i < xo.length; i++) {\n\t\t\t\tbt[i].setEnabled(false);\n\t\t\t}\n\t\t\treturn true;\n\t\t}\n\t\t// conditions fo player O\n\t\tif ((bt[0].getText().equals(\"O\") && bt[3].getText().equals(\"O\") && bt[6].getText().equals(\"O\"))\n\t\t\t\t|| (bt[1].getText().equals(\"O\") && bt[4].getText().equals(\"O\") && bt[7].getText().equals(\"O\"))\n\t\t\t\t|| (bt[2].getText().equals(\"O\") && bt[5].getText().equals(\"O\") && bt[8].getText().equals(\"O\"))) {\n\t\t\tjtf.setText(\" PLAYER O WON!\");\n\t\t\tjtf.setForeground(Color.blue);\n\t\t\tjtf.setFont(new Font(\"Arial Black\", Font.BOLD, 50));\n\t\t\tfor (i = 0; i < xo.length; i++) {\n\t\t\t\tbt[i].setEnabled(false);\n\t\t\t}\n\t\t\treturn true;\n\t\t}\n\n\t\treturn false;\n\t}",
"@Override\n public void onClick(DialogInterface dialog, int which) {\n Utility.hideKeyBoard(editText, mContext);\n if (editText.getText().toString().trim().length() > 0) {\n motor_no.setText(editText.getText().toString().trim());\n } else {\n motor_no.setText(\"\");\n }\n }",
"@Override\n public void onClick(DialogInterface dialog, int which) {\n Utility.hideKeyBoard(editText, mContext);\n if (editText.getText().toString().trim().length() > 0) {\n head.setText(editText.getText().toString().trim());\n } else {\n head.setText(\"\");\n }\n }",
"public void onClickButton2(View view) {\n\n if (turn%2 == 0 && button2.getText()==\"·\"){\n button2.setText(\"O\");\n turn++;\n }\n else if (button2.getText()==\"·\"){\n button2.setText(\"X\");\n turn++;\n }\n\n }",
"private void chkKeyPressed(KeyEvent e) {\n\t\tif (UtilityPtoVenta.verificaVK_F1(e)) // Reservado para ayuda\n\t\t{\n\t\t} else if (UtilityPtoVenta.verificaVK_F11(e)) {\n \n boolean valor=true;\n if (datosValidados()){\n //JCORTEZ 14.03.09 solo para tipo ticket no se podra modificar la cola de impresion con una que ya exista\n if (VariablesImpresoras.vTipoComp.trim().equalsIgnoreCase(ConstantsPtoVenta.TIP_COMP_TICKET)){\n if(!validaRuta()){\n FarmaUtility.showMessage(this,\"No se puede asignar una ruta de impresion que ya existe.\",txtColaImpresion);\n valor=false;\n }\n }\n if(valor)\n if (JConfirmDialog.rptaConfirmDialog(this,\"¿Está seguro que desea grabar los datos ?\")) {\n try {\n if (existenDatos) {\n actualizarImpresora();\n } else {\n insertarImpresora();\n actualizaNumeracionImpresoras();\n }\n\n FarmaUtility.aceptarTransaccion();\n FarmaUtility.showMessage(this,\"La operación se realizó correctamente\",txtDescImpresora);\n\n } catch (SQLException ex) {\n FarmaUtility.liberarTransaccion();\n FarmaUtility.showMessage(this,\"Error al grabar datos de la impresora: \\n\"+ ex.getMessage(), txtDescImpresora);\n log.error(\"\",ex);\n\n }\n cerrarVentana(true);\n }\n }\n\n\t\t} else if (e.getKeyCode() == KeyEvent.VK_ESCAPE) {\n\t\t\tcerrarVentana(false);\n\t\t}\n\n\t}",
"public void uiVerifyButtonUndoDisable() {\n try {\n getLogger().info(\"Verify button Undo Todo disable.\");\n Thread.sleep(largeTimeOut);\n\n if (btnToDoUndo.getAttribute(\"class\").toString().equals(\"fa fa-undo disabled\")) {\n NXGReports.addStep(\"Verify button Undo Todo disable.\", LogAs.PASSED, null);\n } else {\n AbstractService.sStatusCnt++;\n NXGReports.addStep(\"verify button Undo Todo disable.\", LogAs.FAILED, new CaptureScreen(CaptureScreen.ScreenshotOf.BROWSER_PAGE));\n }\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n }",
"@Override\r\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\tif(e.getSource() == g) {\r\n\t\t\t\t\ttext.setText(\"6\");\r\n\t\t\t\t}\r\n\t\t\t}",
"public void removeCharacter(android.widget.Button button){\n int index;\n if(saisie[0] == button.getText().charAt(0)){\n index = 0;\n }else if(saisie[1] == button.getText().charAt(0)){\n index = 1;\n }else if(saisie[2] == button.getText().charAt(0)){\n index = 2;\n }else if(saisie[3] == button.getText().charAt(0)){\n index = 3;\n }else {\n index = 4;\n }\n // Supprmier le caractère\n saisie[index] = ' ';\n\n }",
"@Override\r\n\t\t\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\t\t\tsendmes(e.getActionCommand());\r\n\t\t\t\t\t\tusertext.setText(\"\");\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t}",
"@Override\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\tif (e.getSource() == btn2) {\n\t\t\t\t\tchucnang(txt1.getText(), btn1);\n\t\t\t\t}\n\t\t\t}",
"@Override\npublic void actionPerformed(ActionEvent e) {\n\nJButton b1 = (JButton)(e.getSource());\n\tString text = b1.getText();\n\tSystem.out.println(\"buttn pressed \"+ text);\n\tcm.addADigit(text);\n\n\tcv.update();\n\n}",
"@Override\r\n\tpublic void actionPerformed(ActionEvent arg0) {\n\t\tsecuencia = button.getSecuencia();\r\n\t\tporcentaje = Float.parseFloat(button.getPorcentaje().getText());\r\n\t\tcorrect = false;\r\n\t\tif (button.getTypeN().isSelected()) {\r\n\t\t\ttype = 'n';\r\n\t\t} else {\r\n\t\t\ttype = 'p';\r\n\t\t}\r\n\r\n\t\twhile (correct) {\r\n\t\t\tif (button.getSecuencia() == null) {\r\n\t\t\t\ttry {\r\n\t\t\t\t\tbutton.getResult().setText(\"No se ha introducido una secuencia\");\r\n\t\t\t\t\tcorrect = false;\r\n\t\t\t\t} catch (Exception e) {\r\n\t\t\t\t\tSystem.out.print(\"Error en la pantalla: \" + e.toString());\r\n\t\t\t\t}\r\n\t\t\t} else if (button.getPorcentaje().getText() == null) {\r\n\t\t\t\ttry {\r\n\t\t\t\t\tbutton.getResult().setText(\"No se ha introducido el porcentaje\");\r\n\t\t\t\t} catch (Exception e) {\r\n\t\t\t\t\tSystem.out.print(\"Error en la pantalla: \" + e.toString());\r\n\t\t\t\t\tcorrect = false;\r\n\t\t\t\t}\r\n\t\t\t} else {\r\n\t\t\t\tcorrect = true;\r\n\t\t\t}\r\n\t\t}\r\n\t\tif (!correct) {\r\n\t\t\tBlastController bCnt = new BlastController();\r\n\t\t\ttry {\r\n\t\t\t\tString result = bCnt.blastQuery(type, dataBaseFile, dataBaseIndexes, (float) porcentaje, secuencia);\r\n\t\t\t\tbutton.printResult(result);\r\n\t\t\t} catch (Exception exc) {\r\n\t\t\t\tSystem.out.println(\"Error en la llamada: \" + exc.toString());\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t}",
"@Override\n public void onClick(View v){\n setResult(RESULT_OK);\n if (textboxComment.getText().length() > 0) {\n textboxComment.setEnabled(false);\n buttonAddComment.setEnabled(false);\n }\n }",
"public void verifierSaisie(){\n boolean ok = true;\n\n // On regarde si le client a ecrit quelque chose\n if(saisieMessage.getText().trim().equals(\"\"))\n ok = false;\n\n if(ok)\n btn.setEnabled(true); //activer le bouton\n else\n btn.setEnabled(false); //griser le bouton\n }",
"public boolean wasButtonJustPressed(int playerNum) {\r\n if (button.clicked) {\r\n button.clicked = false;\r\n return true;\r\n } else {\r\n return false;\r\n }\r\n }",
"public boolean validMove(int row, int column)\r\n {\r\n return buttons[row][column].getText().charAt(0) == ' ';\r\n }",
"void killButton() {\n //goes through all columns\n for (int i = 0; i < 7; i++) {\n //if the not of valid move is true, disable the buttons\n if (!Checker.validMove(currentBoard, i)) {\n Inputbuttons[i].setEnabled(false);\n }\n }\n }",
"protected abstract boolean onOkClicked();",
"private void chkKeyPressed(KeyEvent e) {\n \n if (e.getKeyCode() == KeyEvent.VK_ESCAPE) \n { \n FarmaVariables.vAceptar = true;\n this.setVisible(false);\n this.dispose();\n e.consume();\n //cerrarVentana(true); \n } \n \n else if (venta.reference.UtilityPtoVenta.verificaVK_F11(e)) \n {\n if (datosValidados()) {\n try {\n ingresarCantidad();\n FarmaUtility.aceptarTransaccion();\n cerrarVentana(false);\n } catch (SQLException sql) {\n FarmaUtility.liberarTransaccion();\n log.error(\"\",sql);\n FarmaUtility.showMessage(this, \n \"Ocurrió un error al registrar la cantidad : \\n\" +\n sql.getMessage(), txtCruce);\n cerrarVentana(false);\n }\n }\n }\n }",
"public void cancel()\n\t{\n\t\t_buttonHit = true;\n\t}",
"public void if_correct(int number) {\n\n\t\tbuttoninstance.setEmpty(false);\n\t\tboard.info.setText(\"Info\");\n\t\tbuttoninstance.setBackground(Color.white);\n\t\tbuttoninstance.setText(Integer.toString(number + 1));\n\t\tbuttoninstance.setFont(new Font(\"Arial\", Font.BOLD, 30));\n\t\tbuttoninstance.setForeground(Color.black);\n\t\tSudokuBlock.counter = !SudokuBlock.counter;\n\t\tdispose();\n\n\t}",
"public void addContinue() {\n if (cursor == 0) {\n JOptionPane.showMessageDialog(null, \"There's no note to continue!\", \"Invalid Continue\", JOptionPane.WARNING_MESSAGE);\n } else {\n notePressed(CONTINUE);\n }\n }",
"private void setupButtons()\n\t{\n\t\tequals.setText(\"=\");\n\t\tequals.setBackground(Color.RED);\n\t\tequals.setForeground(Color.WHITE);\n\t\tequals.setOpaque(true);\n\t\tequals.setFont(new Font(\"Lucida Grande\", Font.PLAIN, 50));\n\t\tequals.setBorder(new CompoundBorder(new LineBorder(Color.LIGHT_GRAY, 5), new LineBorder(Color.BLACK, 3)));\n\t\tclear.setText(\"C\");\n\t\tclear.setBackground(new Color(0, 170, 100));\n\t\tclear.setForeground(Color.WHITE);\n\t\tclear.setOpaque(true);\n\t\tclear.setFont(new Font(\"Lucida Grande\", Font.PLAIN, 50));\n\t\tclear.setBorder(new CompoundBorder(new LineBorder(Color.LIGHT_GRAY, 5), new LineBorder(Color.BLACK, 3)));\n\t\tbackspace.setText(\"<--\");\n\t\tbackspace.setBackground(new Color(0, 170, 100));\n\t\tbackspace.setForeground(Color.WHITE);\n\t\tbackspace.setOpaque(true);\n\t\tbackspace.setFont(new Font(\"Lucida Grande\", Font.PLAIN, 35));\n\t\tbackspace.setBorder(new CompoundBorder(new LineBorder(Color.LIGHT_GRAY, 5), new LineBorder(Color.BLACK, 3)));\n\t\tnegative.setText(\"+/-\");\n\t\tnegative.setBackground(Color.GRAY);\n\t\tnegative.setForeground(Color.WHITE);\n\t\tnegative.setOpaque(true);\n\t\tnegative.setFont(new Font(\"Lucida Grande\", Font.PLAIN, 35));\n\t\tnegative.setBorder(new CompoundBorder(new LineBorder(Color.LIGHT_GRAY, 5), new LineBorder(Color.BLACK, 3)));\n\t}",
"@FXML\n public void handleKeyRelease() {\n String text = nameField.getText();\n boolean disableButtons = text.isEmpty() || text.trim().isEmpty(); //.trim() is used to set the button disable for space input\n helloButton.setDisable(disableButtons);\n byeButton.setDisable(disableButtons);\n }",
"public void buttonHint(View view) {\n textBoxInput = findViewById(R.id.edit_Dashes);\n\n //get user inputs with edit text\n inputLetter = textBoxInput.getText().toString().toLowerCase();\n\n String carBrandName = \"\";\n\n boolean isWrong = true;\n //get user inputs\n for (int a = 0; a < namesArray.size(); a++) {\n carBrandName = carBrandName + namesArray.get(a);\n brandName = carBrandName.toUpperCase();\n //check user input are correct\n if (inputLetter.equals(namesArray.get(a))) {\n //set input letter to dashes array\n dashesArray.set(a, inputLetter);\n isWrong = false;\n }\n }\n //calculate wrong answers submit count\n if (isWrong) {\n wrongLetterCount += 1;\n }\n\n //check wrong answers count and give chance to user submit another answer\n if(wrongLetterCount < 3) {\n String textName = \"\";\n //set user inputs and dashes to text view\n for (int b = 0; b <= dashesArray.size() - 1; b++) {\n textName = textName + dashesArray.get(b);\n textViewOutput.setText(textName.toUpperCase());\n }\n }\n //user enter 3 wrong answers\n else {\n //call wrong answers dialog box\n wrongAnswer();\n //set correct brand name to text view\n correctNameText.setText(brandName);\n\n //next button visible to user\n buttonNext.setVisibility(view.VISIBLE);\n //submit button invisible to user\n buttonSubmit.setVisibility(view.INVISIBLE);\n\n //edit text invisible to user\n textBoxInput.setVisibility(view.INVISIBLE);\n //text view visible to user\n correctNameText.setVisibility(view.VISIBLE);\n }\n\n dashesCount = 0;\n //calculate dashes count in text view to check user enter correct answer\n for (int a = 0; a < dashesArray.size(); a++) {\n if (\"-\".equals(dashesArray.get(a))) {\n dashesCount += 1;\n }\n }\n\n //if all letters submit correctly then action in below\n if (dashesCount==0){\n //call correct answer dialog box\n correctAnswer();\n\n //next button visible to user\n buttonNext.setVisibility(view.VISIBLE);\n //submit button invisible to user\n buttonSubmit.setVisibility(view.INVISIBLE);\n //edit text invisible to user\n textBoxInput.setVisibility(view.INVISIBLE);\n }\n //clear text in edit text\n textBoxInput.getText().clear();\n }",
"@Override\n\t\t\tpublic void afterTextChanged(Editable s) {\n\n\t\t\t\tif (s.toString().equals(\"\")) {\n\t\t\t\t\tchangeBackColor();\n\t\t\t\t} else {\n\t\t\t\t\tbtn_transfer_ok.setBackgroundColor(getResources().getColor(R.color.tv_leaveItem_state_green));\n\t\t\t\t\tbtn_transfer_ok.setTextColor(android.graphics.Color.parseColor(\"#ffffff\"));\n\t\t\t\t}\n\t\t\t}",
"public void lPressed(View v) {\n //user has pressed a letter to guess\n\n String ltr=((TextView)v).getText().toString();\n char letterChar = ltr.charAt(0);\n\n v.setEnabled(false);\n // v.setBackgroundResource(R.drawable.l_down);\n\n int hang=0;\n int k=0;\n while(k!=currentWord.length()){\n if(currentWord.charAt(k)==letterChar){\n hang=1;\n numCorrect++;\n cViews[k].setTextColor(Color.RED); //change color to red.\n }\n k++;\n }\n\n String t=currentWord;\n if(hang==1){\n if(numCorrect==numChars){\n\n int numLetters = letters.getChildCount();\n for (int i = 0; i < numLetters; i++) {\n letters.getChildAt(i).setEnabled(false);\n }\n play();\n //dialog box that you won\n AlertDialog.Builder wins = new AlertDialog.Builder(this);\n wins.setTitle(\"CONGRATS !!!\");\n wins.setMessage(\"You win!\\n\\nThe answer was : \" + t);\n wins.setPositiveButton(\"Play Again\",\n new DialogInterface.OnClickListener() {\n public void onClick(DialogInterface dialog, int id) {\n MainActivity.this.play();\n }\n });\n wins.setNegativeButton(\"Exit\",\n new DialogInterface.OnClickListener() {\n public void onClick(DialogInterface dialog, int id) {\n MainActivity.this.finish();\n }\n });\n wins.show();\n }\n\n }\n else if (currentPart < numParts) {\n\n if(currentPart==1){ //adding hint 1\n\n switch(g) {\n case 0:\n Toast.makeText(getApplicationContext(), \"Hint 1 : Have you heard of CrANBERRies?\", Toast.LENGTH_SHORT).show();\n break;\n case 1:\n Toast.makeText(getApplicationContext(), \"Hint 1 : Also known as city of David\", Toast.LENGTH_SHORT).show();\n break;\n case 2:\n Toast.makeText(getApplicationContext(), \"Hint 1 : Dalai Lama is bad (No offence) \", Toast.LENGTH_SHORT).show();\n break;\n case 3:\n Toast.makeText(getApplicationContext(), \"Hint 1 : WELL ! A makING TON\", Toast.LENGTH_SHORT).show();\n break;\n case 4:\n Toast.makeText(getApplicationContext(), \"Hint 1 : According to sources, Hamsters live near dam\", Toast.LENGTH_SHORT).show();\n break;\n case 5:\n Toast.makeText(getApplicationContext(), \"Hint 1 : Student wish pumkin had fallen !!!\", Toast.LENGTH_SHORT).show();\n break;\n case 6:\n Toast.makeText(getApplicationContext(), \"Hint 1 : Think this anwer relatively !!\", Toast.LENGTH_SHORT).show();\n break;\n case 7:\n Toast.makeText(getApplicationContext(), \"Hint 1 : Nearnight is antonym of ...\", Toast.LENGTH_SHORT).show();\n break;\n case 8:\n Toast.makeText(getApplicationContext(), \"Hint 1 : Eureka !!!\", Toast.LENGTH_SHORT).show();\n break;\n case 9:\n Toast.makeText(getApplicationContext(), \"Hint 1 : Did you try pressing a button other than an alphabet !!!\", Toast.LENGTH_SHORT).show();\n break;\n case 10:\n Toast.makeText(getApplicationContext(), \"Hint 1 : Windowless !!!\", Toast.LENGTH_SHORT).show();\n break;\n case 11:\n Toast.makeText(getApplicationContext(), \"Hint 1 : Dora is fed up with Windows !!\", Toast.LENGTH_SHORT).show();\n break;\n case 12:\n Toast.makeText(getApplicationContext(), \"Hint 1 : DEBI is AN eclyomologocalysticalisyisac.\", Toast.LENGTH_SHORT).show();\n break;\n case 13:\n Toast.makeText(getApplicationContext(), \"Hint 1 : Short form of 'generation too' !!!\", Toast.LENGTH_SHORT).show();\n break;\n case 14:\n Toast.makeText(getApplicationContext(), \"Hint 1 : Answer also matches with a Hindu goddess.\", Toast.LENGTH_SHORT).show();\n break;\n case 15:\n Toast.makeText(getApplicationContext(), \"Hint 1 : Beth bought a MAC !!\", Toast.LENGTH_SHORT).show();\n break;\n case 16:\n Toast.makeText(getApplicationContext(), \"Hint 1 : Let hamburger be eaten by Prince of Denmark !!\", Toast.LENGTH_SHORT).show();\n break;\n case 17:\n Toast.makeText(getApplicationContext(), \"Hint 1 : King of vampires !!\", Toast.LENGTH_SHORT).show();\n break;\n case 18:\n Toast.makeText(getApplicationContext(), \"Hint 1 : Oath should be made as Hello is made !!!\", Toast.LENGTH_SHORT).show();\n break;\n case 19:\n Toast.makeText(getApplicationContext(), \"Hint 1 : Are you hungry. Then don't mock others !!!\", Toast.LENGTH_SHORT).show();\n break;\n case 20:\n Toast.makeText(getApplicationContext(), \"Hint 1 : He was assassinated\", Toast.LENGTH_SHORT).show();\n break;\n case 21:\n Toast.makeText(getApplicationContext(), \"Hint 1 : Also known as Uncle Abe !!!\", Toast.LENGTH_SHORT).show();\n break;\n case 22:\n Toast.makeText(getApplicationContext(), \"Hint 1 : Is your BeltLoose?\", Toast.LENGTH_SHORT).show();\n break;\n case 23:\n Toast.makeText(getApplicationContext(), \"Hint 1 : He was clever-and..he drank a lot of watel !!!\", Toast.LENGTH_SHORT).show();\n break;\n\n case 24:\n Toast.makeText(getApplicationContext(), \"Hint 1 : Also known as Barry !!!\", Toast.LENGTH_SHORT).show();\n break;\n\n\n }\n arr[currentPart].setVisibility(View.VISIBLE);\n currentPart++;\n }\n\n\n\n\n else if(currentPart==3){ //displaying hint 2\n if(g/5==0)\n {\n Toast.makeText(getApplicationContext(), \"Hint 2 : A capital city!\", Toast.LENGTH_SHORT).show();\n }\n else if(g/5==1)\n {\n Toast.makeText(getApplicationContext(), \"Hint 2 : A Scientist!\", Toast.LENGTH_SHORT).show();\n }\n else if(g/5==2)\n {\n Toast.makeText(getApplicationContext(), \"Hint 2 : A Linux system!\", Toast.LENGTH_SHORT).show();\n }\n else if(g/5==3)\n {\n Toast.makeText(getApplicationContext(), \"Hint 2 : A novel!\", Toast.LENGTH_SHORT).show();\n }\n else if(g/5==4)\n {\n Toast.makeText(getApplicationContext(), \"Hint 2 : An American president!\", Toast.LENGTH_SHORT).show();\n }\n arr[currentPart].setVisibility(View.VISIBLE);\n currentPart++;\n }\n else {\n arr[currentPart].setVisibility(View.VISIBLE);\n currentPart++;\n }\n }\n else{\n int numLetters = letters.getChildCount();\n for (int i = 0; i < numLetters; i++) {\n letters.getChildAt(i).setEnabled(false);\n }\n play();\n //dialog box displaying when u lose\n AlertDialog.Builder lose = new AlertDialog.Builder(this);\n lose.setTitle(\"TRY AGAIN\");\n lose.setMessage(\"You lose!\\n\\nThe answer was : \"+t);\n lose.setPositiveButton(\"Play Again\",\n new DialogInterface.OnClickListener() {\n public void onClick(DialogInterface dialog, int id) {\n MainActivity.this.play();\n }});\n\n lose.setNegativeButton(\"Exit\",\n new DialogInterface.OnClickListener() {\n public void onClick(DialogInterface dialog, int id) {\n MainActivity.this.finish();\n }});\n\n lose.show();\n }\n\n }",
"@Override\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\tif(parent_frame.getFestival().isLocked()){\n\t\t\t\t\tfeedback_display.append(\"\\tPlease submit after voice prompt has finished.\\n\");\n\t\t\t\t} else {\n\t\t\t\t\tprocessAttempt(input_from_user.getText());\n\t\t\t\t}\n\t\t\t\tinput_from_user.requestFocusInWindow();//gets focus back to the spell here field\n\t\t\t}",
"private void setupSayAgainButton() {\n\t\tImageIcon sayagain_button_image = new ImageIcon(parent_frame.getResourceFileLocation() + \"sayagain.png\");\n\t\tJButton sayagain_button = new JButton(\"\", sayagain_button_image);\n\t\tsayagain_button.addActionListener(new ActionListener() {\n\t\t\t@Override\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\tinput_from_user.requestFocusInWindow();//gets focus back to the spell here field\n\t\t\t\t\n\t\t\t\t//says the word slowly\n\t\t\t\tparent_frame.getFestival().speak(words_to_spell.get(current_word_number),true);\n\n\t\t\t\t//says the sample sentence at user's preferred speed there is one @author Abby S\n\t\t\t\tif(parent_frame.getDataHandler().hasSampleSentences()){\n\t\t\t\t\tint index=parent_frame.getDataHandler().getWordlistWords().get(parent_frame.getDataHandler().getCurrentLevel()).indexOf(words_to_spell.get(current_word_number));\n\t\t\t\t\tString sentence=parent_frame.getDataHandler().getSampleSentences().get(parent_frame.getDataHandler().getCurrentLevel()).get(index);\n\t\t\t\t\tif (!sentence.trim().isEmpty()){\n\t\t\t\t\t\tparent_frame.getFestival().speak(sentence,false);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\t\tsayagain_button.addMouseListener(new VoxMouseAdapter(sayagain_button,null));\n\t\tadd(sayagain_button);\n\t\tsayagain_button.setBounds(667, 598, 177, 100);\n\t}"
] | [
"0.6558552",
"0.65009344",
"0.6438187",
"0.641911",
"0.6392142",
"0.6344362",
"0.6312299",
"0.6241852",
"0.6093794",
"0.6089095",
"0.60529846",
"0.6047726",
"0.6047645",
"0.599429",
"0.5959794",
"0.59538144",
"0.5942305",
"0.5936727",
"0.5907834",
"0.5894715",
"0.5889504",
"0.58834076",
"0.5880268",
"0.58583313",
"0.5849451",
"0.5836392",
"0.58248943",
"0.5810966",
"0.58004624",
"0.5793411",
"0.5791101",
"0.5788841",
"0.5768579",
"0.5745257",
"0.5729864",
"0.5722657",
"0.57222146",
"0.57209045",
"0.57174706",
"0.57139957",
"0.57060415",
"0.56980234",
"0.5695425",
"0.56951946",
"0.569138",
"0.5688805",
"0.5686242",
"0.56701434",
"0.56600493",
"0.5659894",
"0.56595623",
"0.56586224",
"0.5657499",
"0.56574804",
"0.56524414",
"0.56446576",
"0.56427675",
"0.5636487",
"0.56290734",
"0.5617284",
"0.5616056",
"0.5615963",
"0.5607714",
"0.5596902",
"0.55958724",
"0.5590599",
"0.5589908",
"0.5585614",
"0.5574784",
"0.5562921",
"0.55616385",
"0.5560668",
"0.55585444",
"0.5547076",
"0.5545302",
"0.5544522",
"0.5541446",
"0.5539406",
"0.553828",
"0.5537448",
"0.5534649",
"0.5532291",
"0.55317914",
"0.5524337",
"0.5522161",
"0.55057716",
"0.550551",
"0.5504698",
"0.5504195",
"0.55025744",
"0.5501145",
"0.5499799",
"0.5490024",
"0.548933",
"0.5487102",
"0.54866076",
"0.54852414",
"0.54835945",
"0.5483214",
"0.54809856"
] | 0.5609563 | 62 |
method(function) that created GUI | public void tictac(){
bb.setVisible(false);
bb.setSize(300, 300);
bb.add(cc);
bb.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
bb.add(hh, BorderLayout.NORTH);
ee.setVisible(true);
ee.add(gg, BorderLayout.NORTH);
ee.add(ff);
ee.setSize(300, 75);
ee.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
ff.add(button11);
ff.add(button10);
cc.setLayout(new GridLayout(3,3));
cc.add(button1);
cc.add(button2);
cc.add(button3);
cc.add(button4);
cc.add(button5);
cc.add(button6);
cc.add(button7);
cc.add(button8);
cc.add(button9);
Listener listen = new Listener();
button11.addActionListener(listen);
button1.addActionListener(listen);
button2.addActionListener(listen);
button3.addActionListener(listen);
button4.addActionListener(listen);
button5.addActionListener(listen);
button6.addActionListener(listen);
button7.addActionListener(listen);
button8.addActionListener(listen);
button9.addActionListener(listen);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"private GUI()\n {\n makeGUI();\n }",
"public void buildGui() {\n\t}",
"@Override\n public void initGUI() {\n\n }",
"private static void initAndShowGUI() {\n }",
"private void createAndShowGUI (){\n\n JustawieniaPowitalne = new JUstawieniaPowitalne();\n }",
"private static void createAndShowGUI() {\n\t\tgui = new GUI();\n\t}",
"Gui getGui();",
"private static void createAndShowGUI() {\n Functionality func = new Functionality();\n }",
"public interface GUI {\n\n /**\n * Adds a MouseListener to the GUI.\n * @param mouseListener added to the GUI.\n */\n void addMouseListener(MouseListener mouseListener);\n\n /**\n * Get list link button for other GUIs. \n * @return List of ButtonLink\n */\n List<ButtonLink> getBtnActionLinks();\n\n /**\n * Sets the link identifier of the GUI.\n * @param linkActionGUI link identifier.\n */\n void setMainAction(LinkActionGUI linkActionGUI);\n\n /**\n * Set the boundaries from a rectangle.\n * @param rectangle for borders.\n */\n void setBounds(Rectangle rectangle);\n\n /**\n * Set visibility of the GUI.\n * @param visible for visibility.\n */\n void setVisible(boolean visible);\n\n /**\n * Set background image.\n * @param path of image.\n */\n void setImageBackground(String path);\n\n /**\n * Set the border color and thickness.\n * @param color for border.\n * @param thickness for border.\n */\n void setBorder(Color color, int thickness);\n\n /**\n * Set visibility of the foreground panel of the GUI.\n * @param visible for visibility panel.\n */\n void setVisibleGlassPanel(Visibility visible);\n\n /**\n * Close the GUI and destroyed JFrame.\n */\n void close();\n\n}",
"public History_GUI(){\n super();\n InitializeComponents();\n ConfigureWin();\n\n }",
"private static void createAndShowGUI() {\n \n JFrame frame = new HandleActionEventsForJButton();\n \n //Display the window.\n \n frame.pack();\n \n frame.setVisible(true);\n \n frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);\n \n }",
"GUIbrain() {\n addMouseListener(this);\n addMouseMotionListener(this);\n createGUI(this);\n }",
"private void designGUI() {\n\t\tmnb= new JMenuBar();\r\n\t\tFileMenu=new JMenu(\"file\");\r\n\t\tEditMenu=new JMenu(\"edit\");\r\n\t\timg1=new ImageIcon(\"s.gif\");\r\n\t\tNew=new JMenuItem(\"new\",img1);\r\n\t\topen=new JMenuItem(\"open\");\r\n\t\tsave=new JMenuItem(\"save\");\r\n\t\tquit=new JMenuItem(\"quit\");\r\n\t\tcut=new JMenuItem(\"cut\");\r\n\t\tcopy=new JMenuItem(\"copy\");\r\n\t\tpaste=new JMenuItem(\"paste\");\r\n\t\t\r\n\t\tFileMenu.add(New);\r\n\t\tFileMenu.add(save);\r\n\t\tFileMenu.add(open);\r\n\t\tFileMenu.add(new JSeparator());\r\n\t\tFileMenu.add(quit);\r\n\t\tEditMenu.add(cut);\r\n\t\tEditMenu.add(copy);\r\n\t\tEditMenu.add(paste);\r\n\t\t\r\n\t\tmnb.add(FileMenu);\r\n\t\tmnb.add(EditMenu);\r\n\t\tsetJMenuBar(mnb);\r\n\t\t\r\n\t\t//to add shortcut\r\n\t\tquit.setMnemonic('q');\r\n\t\t//quit.setAccelerator(KeyStroke.getKeyStroke(KeyEvent.VK_W,ActionEvent.CTRL_MASK));\r\n\t\tquit.addActionListener((ActionEvent e)->\r\n\t\t\t\t{\r\n\t\t\tSystem.exit(0);\r\n\t\t\t\t});\r\n\t\t\r\n\t\t//moving the mouse near to it we get this\r\n\t\tcut.setToolTipText(\"cut the text\");\r\n\t\t//new way fro get domension\r\n\t\tdim=getToolkit().getScreenSize();\r\n\t\tint x=(int) dim.getHeight();\r\n\t\tint y=(int) dim.getWidth();\r\n\t\tc=getContentPane();\r\n\t\tc.setLayout(new BorderLayout());\r\n\t\tmainpanel=new JPanel();\r\n\t\tta1=new JTextArea(x/18,y/12);\r\n\t\tmainpanel.add(new JScrollPane(ta1));\r\n\t\tc.add(mainpanel,BorderLayout.CENTER);\r\n\t\tmymethods();\r\n\t\topen.addActionListener(this);\r\n\t\tsave.addActionListener(this);\r\n\t\tcut.addActionListener(this);\r\n\t\tcopy.addActionListener(this);\r\n\t\tpaste.addActionListener(this);\r\n\t\t\r\n\t}",
"@Override\n\tpublic void guiTinNhan() {\n\n\t}",
"private void makeGUI() {\n //Create the canvas and Components for GUI.\n canvas = new Canvas();\n\n canvas.setBounds(0, 0, getWidth(), getHeight());\n getContentPane().setBackground(DrawAttribute.whiteblue);\n searchArea = new JTextField();\n searchArea.setForeground(Color.GRAY);\n searchArea.setText(promptText);\n\n //Make the components for the frame.\n makeComponents();\n addComponentsToLayers();\n }",
"public gui() {\n initComponents();\n }",
"public gui() {\n initComponents();\n }",
"void createWindow();",
"public void initGui()\n {\n StringTranslate var1 = StringTranslate.getInstance();\n int var2 = this.func_73907_g();\n\n for (int var3 = 0; var3 < this.options.keyBindings.length; ++var3)\n {\n this.controlList.add(new GuiSmallButton(var3, var2 + var3 % 2 * 160, this.height / 6 + 24 * (var3 >> 1), 70, 20, this.options.getOptionDisplayString(var3)));\n }\n\n this.controlList.add(new GuiButton(200, this.width / 2 - 100, this.height / 6 + 168, var1.translateKey(\"gui.done\")));\n this.screenTitle = var1.translateKey(\"controls.minimap.title\");\n }",
"public GUI() {\n initComponents();\n }",
"public GUI() {\n initComponents();\n }",
"public CreateGUI() throws IOException{\r\n\t\tthis.setFocusable(false);\r\n\t\tthis.setTitle(\"Dance Dance Revolution - 201B Edition\");\r\n\t\tthis.setSize(800, 600);\t\t \t\r\n\t\tthis.setLocation(100, 100); \t\r\n\t\tthis.setVisible(true);\r\n\t\tthis.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);\r\n\t\tthis.setResizable(false);\r\n\t\tcp = getContentPane();\r\n\t\tcp.setBackground(Color.black);\r\n\t\tarrowlistener = new ArrowListener();\r\n\t\tscore = new Score();\r\n\t\tcombo = new ComboImage();\r\n\t}",
"public void showGui()\n {\n // TODO\n }",
"public GUI()\n {\n //Initializes the variables and UI aspects\n UI.initialise();\n UI.addTextField(\"Search Title/Director/Genre\", this::searchEither);\n UI.addButton(\"Add Movie\", this::newMovie);\n UI.addButton(\"Rate Movie\", this::rateMovie);\n UI.addButton(\"Show All Movies\", this::printAll);\n UI.addButton(\"Recommend Movies\", this::recommendMovie);\n UI.setMouseListener(r::manageMouse);\n UI.addButton(\"Quit\", UI::quit);\n \n // Sets the size of the whole window and the divider\n UI.setWindowSize(CANVASWIDTH, CANVASHEIGHT);\n UI.setDivider(0.4);\n this.drawMain();\n }",
"private static void createAndShowGUI()\n {\n Sudoku s = new Sudoku();\n }",
"public GUI() {\n }",
"public GUI() {\n initComponents();\n }",
"public MyGUI() {\n \t super(\"Mastermind\");\n \t guiManager = new GUIManager();\n createMenuComponents();\n createMastermindComponents(this,2);\n \n }",
"public GUI() {\n app = new Aplikasi();\n initComponents();\n }",
"public GUI() {\n\t\tinitComponents();\n\t}",
"private void createUserInterface()\r\n {\r\n // get content pane for attaching GUI components\r\n Container contentPane = getContentPane();\r\n\r\n // enable explicit positioning of GUI components\r\n contentPane.setLayout( null );\r\n \r\n // set up side1JLabel\r\n side1JLabel = new JLabel();\r\n side1JLabel.setBounds( 16, 16, 40, 24 );\r\n side1JLabel.setText( \"Side1:\" );\r\n contentPane.add( side1JLabel );\r\n \r\n // set up side1JTextField\r\n side1JTextField = new JTextField();\r\n side1JTextField.setBounds( 72, 16, 90, 24 );\r\n side1JTextField.setHorizontalAlignment( JTextField.RIGHT ); \r\n contentPane.add( side1JTextField );\r\n \r\n // set up side2JLabel\r\n side2JLabel = new JLabel();\r\n side2JLabel.setBounds( 16, 56, 40, 24 );\r\n side2JLabel.setText( \"Side2:\" );\r\n contentPane.add( side2JLabel );\r\n \r\n // set up side2JTextField\r\n side2JTextField = new JTextField();\r\n side2JTextField.setBounds( 72, 56, 90, 24 );\r\n side2JTextField.setHorizontalAlignment( JTextField.RIGHT );\r\n contentPane.add( side2JTextField );\r\n \r\n // set up side3JLabel\r\n side3JLabel = new JLabel();\r\n side3JLabel.setBounds( 16, 96, 40, 24 );\r\n side3JLabel.setText( \"Side3:\" );\r\n contentPane.add( side3JLabel );\r\n \r\n // set up side3JTextField\r\n side3JTextField = new JTextField();\r\n side3JTextField.setBounds( 72, 96, 90, 24 );\r\n side3JTextField.setHorizontalAlignment( JTextField.RIGHT );\r\n contentPane.add( side3JTextField );\r\n \r\n // set up messageJTextField\r\n messageJTextField = new JTextField();\r\n messageJTextField.setBounds( 16, 140, 252, 24 );\r\n messageJTextField.setEditable( false );\r\n contentPane.add( messageJTextField );\r\n \r\n // set up createJButton\r\n createJButton = new JButton();\r\n createJButton.setBounds( 178, 16, 90, 24 );\r\n createJButton.setText( \"Create\" );\r\n contentPane.add( createJButton );\r\n createJButton.addActionListener( \r\n \r\n new ActionListener() // anonymous inner class\r\n {\r\n // event handler called when createJButton is pressed\r\n public void actionPerformed( ActionEvent event )\r\n {\r\n createJButtonActionPerformed( event );\r\n }\r\n \r\n } // end anonymous inner class\r\n \r\n ); // end call to addActionListener\r\n \r\n // set properties of application's window\r\n setTitle( \"Triangle Creator\" ); // set title bar string\r\n setSize( 290, 208 ); // set window size\r\n setVisible( true ); // display window\r\n \r\n }",
"void gui(){\n _hasGUI = true;\n }",
"@Override\n\tpublic void addGui(Gui gui) {\n\t\t\n\t}",
"public GUI_Crear_Funcionario() {\r\n initComponents();\r\n lbl1.setVisible(false);\r\n lbl2.setVisible(false);\r\n lbl3.setVisible(false);\r\n lbl4.setVisible(false);\r\n lbl5.setVisible(false);\r\n lbl6.setVisible(false);\r\n lbl7.setVisible(false);\r\n lbl8.setVisible(false);\r\n lbl9.setVisible(false);\r\n lbl10.setVisible(false);\r\n groupSexoBtn.add(rBtn1);\r\n groupSexoBtn.add(rBtn2);\r\n cargarImagen(jdp4,foto1);\r\n ocultarBarraTitulo();\r\n \r\n }",
"public Object getGuiObject();",
"private void createAndShowGUI(){\r\n initComponents();\r\n openMazefile.addActionListener(this);\r\n solveMaze.addActionListener(this);\r\n clearSolution.addActionListener(this);\r\n setDefaultCloseOperation(WindowConstants.EXIT_ON_CLOSE);\r\n pack();\r\n setVisible(true);\r\n }",
"public void initGui() {\r\n boolean var10000 = method_1147();\r\n this.buttonList.clear();\r\n this.field_985 = this.height / 4 - 52;\r\n boolean var1 = var10000;\r\n this.field_986 = this.height - 29;\r\n bcb var10001 = new bcb;\r\n var10001.method_748(1, this.width / 2 - 98, this.method_1143(1), 60, 20, String.valueOf(class_687.field_2947));\r\n this.field_972 = var10001;\r\n var10001 = new bcb;\r\n var10001.method_748(2, this.width / 2 + 102, this.method_1143(1), 60, 20, String.valueOf(class_687.field_2946));\r\n this.field_973 = var10001;\r\n var10001 = new bcb;\r\n var10001.method_748(3, this.width / 2 + 2, this.method_1143(2), 60, 20, String.valueOf(class_687.field_2948));\r\n this.field_974 = var10001;\r\n class_157 var4 = new class_157;\r\n int var10004 = this.width / 2 + 2;\r\n int var10005 = this.method_1143(3);\r\n String[] var3 = field_989;\r\n var4.method_833(50, var10004, var10005, 150, 20, \"X Pos: \", 1.0F, (float)(this.width - 25), (float)class_687.field_2949, true);\r\n this.field_979 = var4;\r\n var4 = new class_157;\r\n var4.method_833(60, this.width / 2 + 2, this.method_1143(4), 150, 20, \"Y Pos: \", 1.0F, (float)(this.height - 8), (float)class_687.field_2950, true);\r\n this.field_980 = var4;\r\n var10001 = new bcb;\r\n var10001.method_748(4, this.width / 2 + 2, this.method_1143(5), 60, 20, String.valueOf(class_687.field_2951));\r\n this.field_975 = var10001;\r\n var10001 = new bcb;\r\n var10001.method_748(5, this.width / 2 + 2, this.method_1143(6), 60, 20, String.valueOf(class_687.field_2952));\r\n this.field_976 = var10001;\r\n var4 = new class_157;\r\n var4.method_833(70, this.width / 2 + 2, this.method_1143(7), 150, 20, \"x\", 0.0F, 10.0F, (float)class_687.field_2953, false);\r\n this.field_981 = var4;\r\n var10001 = new bcb;\r\n var10001.method_748(100, this.width / 2 - 155, this.field_986, 150, 20, \"Sauvegarder\");\r\n this.field_977 = var10001;\r\n var10001 = new bcb;\r\n var10001.method_748(110, this.width / 2 + 5, this.field_986, 150, 20, \"Annuler\");\r\n this.field_978 = var10001;\r\n this.buttonList.add(this.field_972);\r\n this.buttonList.add(this.field_973);\r\n this.buttonList.add(this.field_974);\r\n this.buttonList.add(this.field_979);\r\n this.buttonList.add(this.field_980);\r\n this.buttonList.add(this.field_975);\r\n this.buttonList.add(this.field_976);\r\n this.buttonList.add(this.field_981);\r\n this.buttonList.add(this.field_977);\r\n this.buttonList.add(this.field_978);\r\n if(!var1) {\r\n int var2 = class_689.method_3977();\r\n ++var2;\r\n class_689.method_3975(var2);\r\n }\r\n\r\n }",
"void initUI();",
"public static void main(String[] args) {\n \n javax.swing.SwingUtilities.invokeLater(new Runnable() {\n \npublic void run() {\n \n createAndShowGUI(); \n \n}\n \n });\n }",
"public void initGui()\n {\n this.buttonList.clear();\n this.multilineMessage = this.fontRendererObj.listFormattedStringToWidth(this.message.getFormattedText(), this.width - 50);\n this.field_175353_i = this.multilineMessage.size() * this.fontRendererObj.FONT_HEIGHT;\n this.buttonList.add(new GuiButton(0, this.width / 2 - 100, this.height / 2 + this.field_175353_i / 2 + this.fontRendererObj.FONT_HEIGHT, I18n.format(\"gui.toMenu\", new Object[0])));\n if(!TabGUI.openTabGUI) return;\n this.buttonList.add(new GuiButton(1, this.width / 2 - 100, this.height / 2 + 20 + this.field_175353_i / 2 + this.fontRendererObj.FONT_HEIGHT, 100, 20, \"Reconnect\"));\n this.buttonList.add(new GuiButton(2, this.width / 2, this.height / 2 + 20 + this.field_175353_i / 2 + this.fontRendererObj.FONT_HEIGHT, 100, 20, \"Random Alt\"));\n }",
"public GUIListener(){}",
"public void run() {\n criaGUI();\n \n }",
"public void initGui()\n {\n StringTranslate var2 = StringTranslate.getInstance();\n int var4 = this.height / 4 + 48;\n\n this.controlList.add(new GuiButton(1, this.width / 2 - 100, var4 + 24 * 1, \"Offline Mode\"));\n this.controlList.add(new GuiButton(2, this.width / 2 - 100, var4, \"Online Mode\"));\n\n this.controlList.add(new GuiButton(3, this.width / 2 - 100, var4 + 48, var2.translateKey(\"menu.mods\")));\n\t\tthis.controlList.add(new GuiButton(0, this.width / 2 - 100, var4 + 72 + 12, 98, 20, var2.translateKey(\"menu.options\")));\n\t\tthis.controlList.add(new GuiButton(4, this.width / 2 + 2, var4 + 72 + 12, 98, 20, var2.translateKey(\"menu.quit\")));\n this.controlList.add(new GuiButtonLanguage(5, this.width / 2 - 124, var4 + 72 + 12));\n }",
"public GUI_Edit_Tour(){\n init();\n }",
"private static void createGUI(){\n DrawingArea drawingArea = new DrawingArea();\n ToolSelect utilityBar = new ToolSelect();\n MenuBar menuBar = new MenuBar();\n JFrame.setDefaultLookAndFeelDecorated(true);\n JFrame frame = new JFrame(\"GUIMk1\");\n frame.setDefaultCloseOperation( JFrame.EXIT_ON_CLOSE );\n frame.setLayout(new BorderLayout());\n frame.getContentPane().add(utilityBar, BorderLayout.WEST);\n frame.getContentPane().add(menuBar,BorderLayout.NORTH);\n frame.getContentPane().add(drawingArea);\n frame.setLocationRelativeTo( null );\n frame.setVisible(true);\n frame.pack();\n\n }",
"public void createGui() {\r\n setResizable(false);\r\n setSize(500, 300);\r\n setTitle(\"TechAndCrack StopWatch\");\r\n setLocation(s.width / 2 - getWidth() / 2, s.height / 2 - getHeight()\r\n / 2);\r\n setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);\r\n setLayout(new BorderLayout());\r\n \r\n textarea.setEditable(false);\r\n textarea.setLineWrap(true);\r\n JScrollPane scrollpane = new JScrollPane(textarea);\r\n \r\n toppanel.add(scrollpane);\r\n toppanel.setLayout(new GridLayout());\r\n add(toppanel, BorderLayout.NORTH);\r\n \r\n labeltimer.setForeground(Color.GRAY);\r\n labeltimer.setFont(new Font(\"Courier New\", Font.BOLD, 36));\r\n centerpanel.add(labeltimer);\r\n add(centerpanel, BorderLayout.CENTER);\r\n \r\n add(bottompanel, BorderLayout.PAGE_END);\r\n bottompanel.setLayout(new GridLayout());\r\n bottompanel.add(btstart);\r\n bottompanel.add(btreset);\r\n bottompanel.add(btlap);\r\n \r\n btstart.addActionListener(new buttonstart());\r\n btreset.addActionListener(new buttonreset());\r\n btlap.addActionListener(new buttonlap());\r\n \r\n setVisible(true);\r\n }",
"GuiView getGui();",
"public void registerGui()\n {\n }",
"public Pane buildGuiInDerSchonzeit() {\n\t\tVBox root = new VBox(10); \r\n\t\t// Der Hintergrund des GUI wird mit einem Transparenten Bild erstellt\r\n\t\tImage imageBackground = new Image(getClass().getResource(\"transparent.png\").toExternalForm()); // Ein Image wird erstellt und das Bild übergeben\r\n\t\tBackgroundImage backgroundImage = new BackgroundImage(imageBackground, BackgroundRepeat.NO_REPEAT, BackgroundRepeat.NO_REPEAT, BackgroundPosition.DEFAULT, BackgroundSize.DEFAULT);\r\n\t\tBackground background = new Background(backgroundImage); // Ein Background wird ertsellt und das Bild übergeben\r\n\t\troot.setBackground(background); // Der Hintergrund mit dem Bild wird dem root übergeben\r\n\t\t\r\n\t\t//\r\n\t\t// // Allse verschiedenen Boxen werden erstellt\r\n\t\t//\r\n\t\t\r\n\t\t// HBox für die erste Spalte\r\n\t\tHBox hBoxSpalte1 = new HBox(190);\r\n\t\t// 2mal VBox um Button und Text anzuzeigen \r\n\t\tVBox vBox1Spalte1 = new VBox();\r\n\t\tVBox vBox2Spalte1 = new VBox();\r\n\t\t\r\n\t\t// HBox für 2. Spalte\r\n\t\tHBox hBoxSpalte2 = new HBox(190);\r\n\t\t// 2 VBoxen für Bild und Text\r\n\t\tVBox vbox1Spalte2 = new VBox();\r\n\t\tVBox vbox2Spalte2 = new VBox();\r\n\t\t\r\n\t\t// HBox für die 3.Spalte\r\n\t\tHBox hboxSpalte3 = new HBox(190);\r\n\t\t// 2mal VBox für Bild und Text\r\n\t\tVBox vbox1Spalte3 = new VBox();\r\n\t\tVBox vbox2Spalte3 = new VBox();\r\n\t\t\r\n\t\t// HBox für die 4 Spalte\r\n\t\tHBox hboxSpalte4 = new HBox(190);\r\n\t\t// 2mal VBox für Bild und Text\r\n\t\tVBox vbox1Spalte4 = new VBox();\r\n\t\tVBox vbox2Spalte4 = new VBox();\r\n\t\t\r\n\t\t//\r\n\t\t// Button für die Fische\r\n\t\t//\r\n\t\t\r\n\t\t//Label Bild für Hecht\r\n\t\tLabel hechtbildLabel = new Label(); // Das Label wird erstellt\r\n\t\tImage hechtimage = new Image(getClass().getResource(\"Hecht.png\").toExternalForm()); // Ein Image mit dem Bild wird erstellt\r\n\t\thechtbildLabel.setGraphic(new ImageView(hechtimage)); // Das Bild wird dem Label übergeben\r\n\t\thechtbildLabel.setTranslateX(100); // X-Achse des Labels\r\n\t\t\r\n\t\t// Label Bild Zander\r\n\t\tLabel zanderbildLabel = new Label(); // Das Label wird erstellt\r\n\t\tImage zanderImage = new Image(getClass().getResource(\"Zander.png\").toExternalForm()); // Ein Image mit dem Bild wird erstellt\r\n\t\tzanderbildLabel.setGraphic(new ImageView(zanderImage)); // Das Bild wird dem Label übergeben\r\n\t\tzanderbildLabel.setTranslateX(100); // X-Achse des Labels\r\n\t\t\r\n\t\t// Label Bild Aal\r\n\t\tLabel aalbildLabel = new Label(); // Das Label wird erstellt\r\n\t\tImage aalImage = new Image(getClass().getResource(\"Aal.png\").toExternalForm()); // Ein Image mit dem Bild wird erstellt\r\n\t\taalbildLabel.setGraphic(new ImageView(aalImage)); // Das Bild wird dem Label übergeben\r\n\t\taalbildLabel.setTranslateX(100); // X-Achse des Labels\r\n\t\t\r\n\t\t// Label Bild Aesche\r\n\t\tLabel aeschebildLabel = new Label(); // Das Label wird erstellt\r\n\t\tImage aescheImage = new Image(getClass().getResource(\"Aesche.png\").toExternalForm()); // Ein Image mit dem Bild wird erstellt\r\n\t\taeschebildLabel.setGraphic(new ImageView(aescheImage)); // Das Bild wird dem Label übergeben\r\n\t\taeschebildLabel.setTranslateX(100); // X-Achse des Labels\r\n\t\t\r\n\t\t// Label Bild Barsch\r\n\t\tLabel barschbildLabel = new Label(); // Das Label wird erstellt\r\n\t\tImage barschImage = new Image(getClass().getResource(\"Barsch.png\").toExternalForm()); // Ein Image mit dem Bild wird erstellt\r\n\t\tbarschbildLabel.setGraphic(new ImageView(barschImage)); // Das Bild wird dem Label übergeben\r\n\t\tbarschbildLabel.setTranslateX(100); // X-Achse des Labels\r\n\t\t\r\n\t\t// Label Bild Forelle\r\n\t\tLabel forellebildLabel = new Label(); // Das Label wird erstellt\r\n\t\tImage forelleImage = new Image(getClass().getResource(\"Regenbogenforelle.png\").toExternalForm()); // Ein Image mit dem Bild wird erstellt\r\n\t\tforellebildLabel.setGraphic(new ImageView(forelleImage)); // Das Bild wird dem Label übergeben\r\n\t\tforellebildLabel.setTranslateX(100); // X-Achse des Labels\r\n\t\t\r\n\t\t// Label Bild Schleie\r\n\t\tLabel schleiebildLabel = new Label(); // Das Label wird erstellt\r\n\t\tImage schleieImage = new Image(getClass().getResource(\"Schleie.png\").toExternalForm()); // Ein Image mit dem Bild wird erstellt\r\n\t\tschleiebildLabel.setGraphic(new ImageView(schleieImage)); // Das Bild wird dem Label übergeben\r\n\t\tschleiebildLabel.setTranslateX(100); // X-Achse des Labels\r\n\t\t\r\n\t\t// Label Bild Karpfe\r\n\t\tLabel karpfenbildLabel = new Label(); // Das Label wird erstellt\r\n\t\tImage karpfenImage = new Image(getClass().getResource(\"Schuppenkarpfen.png\").toExternalForm()); // Ein Image mit dem Bild wird erstellt\r\n\t\tkarpfenbildLabel.setGraphic(new ImageView(karpfenImage)); // Das Bild wird dem Label übergeben\r\n\t\tkarpfenbildLabel.setTranslateX(100); // X-Achse des Labels\r\n\t\t\r\n\t\t//\r\n\t\t// Label für die Titel der Fische\r\n\t\t//\r\n\t\t\r\n\t\t// Label Hecht\r\n\t\tLabel hechtlabel = new Label(\"Hecht\"); // Das Label mit dem Namen wird erstellt\r\n\t\thechtlabel.setFont(new Font(30)); // Die Schriftgrösse\r\n\t\thechtlabel.setTranslateX(180); // X-Achse des Labels\r\n\t\t\r\n\t\t//Label Zander\r\n\t\tLabel zanderLabel = new Label(\"Zander\"); // DAs LAabel mit dem Namen wird erstellt\r\n\t\tzanderLabel.setFont(new Font(30)); // Schriftgrösse\r\n\t\tzanderLabel.setTranslateX(160); // X-Achse des Labels\r\n\t\t\r\n\t\t// Label Aal\r\n\t\tLabel aaLabel = new Label(\"Aal\"); // Das Label mit dem Namen wird erstellt\r\n\t\taaLabel.setFont(new Font(30)); // Schriftgrösse\r\n\t\taaLabel.setTranslateX(200); // X-Achse des Labels\r\n\t\t\r\n\t\t// Label Aesche\r\n\t\tLabel aescheLabel = new Label(\"Äsche\"); // Das Label mit dem Namen wird erstellt\r\n\t\taescheLabel.setFont(new Font(30)); // Schriftgrösse\r\n\t\taescheLabel.setTranslateX(180); // X-Achse des Labels\r\n\t\t\r\n\t\t// Label Barsch\r\n\t\tLabel barschLabel = new Label(\"Flussbarsch\"); // Das Label mit dem Namen wird erstellt\r\n\t\tbarschLabel.setFont(new Font(30)); // Schriftgrösse\r\n\t\tbarschLabel.setTranslateX(130); // X-Achse des Labels\r\n\t\t\r\n\t\t// Label Forelle\r\n\t\tLabel forelleLabel = new Label(\"Forelle\"); // Das Label mit dem Namen wird erstellt\r\n\t\tforelleLabel.setFont(new Font(30)); // Schriftgrösse\r\n\t\tforelleLabel.setTranslateX(180); // X-Achse des Labels\r\n\t\t\r\n\t\t// Label Schleie\r\n\t\tLabel schleieLabel = new Label(\"Schleie\"); // Das Label mit dem Namen wird erstellt\r\n\t\tschleieLabel.setFont(new Font(30)); // Schriftgrösse\r\n\t\tschleieLabel.setTranslateX(170); // X-Achse des Labels\r\n\t\t\r\n\t\t// Label Karpfe\r\n\t\tLabel karpfeLabel = new Label(\"Karpfe\"); // Das Label mit dem Namen wird erstellt\r\n\t\tkarpfeLabel.setFont(new Font(30)); // Schriftgrösse\r\n\t\tkarpfeLabel.setTranslateX(170); // X-Achse des Labels\r\n\t\t\r\n\t\t//\r\n\t\t// Label für die Anzeige in der Schonzeit\r\n\t\t//\r\n\t\t\r\n\t\t// Label Schonzeit für Hecht\r\n\t\tLabel schonzeitHechtLabel = new Label(); // Das Label wird erstellt\r\n\t\tschonzeitHechtLabel.setFont(new Font(25)); // Schriftgrösse\r\n\t\tschonzeitHechtLabel.setTranslateX(140); // X-Achse im root\r\n\t\t\r\n\t\t// Label Schonzeit für Zander\r\n\t\tLabel schonzeitZanderLabel = new Label(); // Das Label wird erstellt\r\n\t\tschonzeitZanderLabel.setFont(new Font(25)); // Schriftgrösse\r\n\t\tschonzeitZanderLabel.setTranslateX(140); // X-Achse im root\r\n\t\t\r\n\t\t// Label Schonzeit für Aal\r\n\t\tLabel schonzeitaaLabel = new Label(); // Das Label wird erstellt\r\n\t\tschonzeitaaLabel.setFont(new Font(25)); // Schriftgrösse\r\n\t\tschonzeitaaLabel.setTranslateX(140); // X-Achse im root\r\n\t\t\r\n\t\t// Label Schonzeit für Aesche\r\n\t\tLabel schonzeitaescheLabel = new Label(); // Das Label wird erstellt\r\n\t\tschonzeitaescheLabel.setFont(new Font(25)); // Schriftgrösse\r\n\t\tschonzeitaescheLabel.setTranslateX(140); // X-Achse im root\r\n\t\t\r\n\t\t// Label Schonzeit Barsch\r\n\t\tLabel schonzeitbarschLabel = new Label(); // Das Label wird erstellt\r\n\t\tschonzeitbarschLabel.setFont(new Font(25)); // Schriftgrösse\r\n\t\tschonzeitbarschLabel.setTranslateX(140); // X-Achse im root\r\n\t\t\r\n\t\t// Label Schonzeit für Forelle\r\n\t\tLabel schonzeitforelleLabel = new Label(); // Das Label wird erstellt\r\n\t\tschonzeitforelleLabel.setFont(new Font(25)); // Schriftgrösse\r\n\t\tschonzeitforelleLabel.setTranslateX(140); // X-Achse im root\r\n\t\t\r\n\t\t// Label Schonzeit Schleie\r\n\t\tLabel schonzeitschleieLabel = new Label(); // Das Label wird erstellt\r\n\t\tschonzeitschleieLabel.setFont(new Font(25)); // Schriftgrösse\r\n\t\tschonzeitschleieLabel.setTranslateX(140); // X-Achse im root\r\n\t\t\r\n\t\t// Label Schonzeit Karpfe\r\n\t\tLabel schonzeitkarpfeLabel = new Label(); // Das Label wird erstellt\r\n\t\tschonzeitkarpfeLabel.setFont(new Font(25)); // Schriftgrösse\r\n\t\tschonzeitkarpfeLabel.setTranslateX(140); // X-Achse im root\r\n\r\n\t\t\r\n\t\t// Das Label für die überschrift\r\n\t\tLabel fischeAuswahlLabel = new Label(\"Fische und Ihre Schonzeit\"); // Das Label wird mit dem Namen erstellt\r\n\t\tfischeAuswahlLabel.setFont(new Font(40)); // Schriftgrösse\r\n\t\tfischeAuswahlLabel.setTranslateX(10); // X-Achse des Labels\r\n\t\t\r\n\t\t//\r\n\t\t// // Buttons werden erstellt\r\n\t\t//\r\n\t\t\r\n\t\t// Button zurück Hauptmenu\r\n\t\tButton hauptmenuButton = new Button(\"Hauptmenü\"); // Button wird erstellt und Initialisiert\r\n\t\thauptmenuButton.setMinSize(200, 50); // Die Minimumgrösse wird gesetzt\r\n\t\thauptmenuButton.setTranslateX(345); // X- Achse des Buttons im root\r\n\t\thauptmenuButton.setFont(new Font(25)); // Schriftgrösse des Buttons\r\n\t\t// Zoom in und out wird hinzugefügt\r\n\t\tButtonHandling zoomButtonHandling = new ButtonHandling();\r\n\t\tzoomButtonHandling.zoomIn(hauptmenuButton);\r\n\t\tzoomButtonHandling.zoomOut(hauptmenuButton);\r\n\t\t// Funktion zurück ins Hauptmenü\r\n\t\thauptMenuAufrufen(hauptmenuButton);\r\n\t\t\r\n\t\t//\r\n\t\t// // Aktuelles Datum wird eingelesen um die Fische auf Ihre Schonzeit zu prüfen\r\n\t\t//\r\n\t\t\r\n\t\t// Aktueller Monat wird in der Variablen datumAktuell gespeichert.\r\n\t\tCalendar dateNow = Calendar.getInstance(); // Kalender wird erstellt\r\n\t\tint datum = dateNow.get(Calendar.MONTH) +1; // Der aktuelle Monat wird im Int Initialisiert. +1 Da die Monate ab 0 Beginnen\r\n\t\t// Datum Manuell setzten für Test und Debbug \r\n\t\t//int datum = 1;\r\n\t\t\r\n\t\t//\r\n\t\t// // Die einzelnen VBoxen für die Fische werden je nach Schonzeit gefüllt\r\n\t\t//\r\n\t\t\r\n\t\t// 1. Spalte und 1 Box\r\n\t\tvBox1Spalte1.getChildren().addAll(hechtlabel,hechtbildLabel);// Erste Linie und erste Spalte mit Bild und Text wird dem root übergeben\r\n\t\tif (datum >=1 && datum <= 4) { // Die Schonzeit wird geprüft\r\n\t\t\tschonzeitHechtLabel.setText(\"hat Schonzeit !\"); // Trifft die IF zu wird dieser Text gesetzt\r\n\t\t\tschonzeitHechtLabel.setTextFill(Color.RED); // Die Schrifftfarbe wird auf Rot gesetzt\r\n\t\t}else { // Wen die IF nicht erfüllt ist\r\n\t\t\tschonzeitHechtLabel.setText(\"keine Schonzeit\"); // Trift due IF nicht zu wird dieser Text gesetzt\r\n\t\t\tschonzeitHechtLabel.setTextFill(Color.GREEN); // Die Schriftfarbe wird auf Grün gesetzt\r\n\t\t}\r\n\t\t// Der VBox wird das Label mit den entsprecheneden Einstellungen übergeben\r\n\t\tvBox1Spalte1.getChildren().add(schonzeitHechtLabel);\r\n\t\t\r\n\t\t// 1. Spalte und 2. Box\r\n\t\tvBox2Spalte1.getChildren().addAll(zanderLabel,zanderbildLabel); // Erste Linie und zweite Spalte mit Bild und Text wird dem root übergeben\r\n\t\tif (datum >= 1 && datum <= 4) { // Die Schonzeit wird geprüft\r\n\t\t\tschonzeitZanderLabel.setText(\"hat Schonzeit !\"); // Trifft die IF zu wird dieser Text gesetzt\r\n\t\t\tschonzeitZanderLabel.setTextFill(Color.RED); // Die Schrifftfarbe wird auf Rot gesetzt\r\n\t\t}else { // Wen die IF nicht erfüllt ist\r\n\t\t\tschonzeitZanderLabel.setText(\"keine Schonzeit\"); // Trift due IF nicht zu wird dieser Text gesetzt\r\n\t\t\tschonzeitZanderLabel.setTextFill(Color.GREEN); // Die Schriftfarbe wird auf Grün gesetzt\r\n\t\t}\r\n\t\t// Der VBox wird das Label mit den entsprechenden Einstellungen übergeben\r\n\t\tvBox2Spalte1.getChildren().add(schonzeitZanderLabel);\r\n\t\t\r\n\t\t// 2. Spalte und 1. Box\r\n\t\tvbox1Spalte2.getChildren().addAll(aaLabel,aalbildLabel); // Zweite Linie erste Spalte mit Bild und Text\r\n\t\t// Der Aal hat keine Schonzeit\r\n\t\t\tschonzeitaaLabel.setText(\"keine Schonzeit\"); // Text wird gesetzt\r\n\t\t\tschonzeitaaLabel.setTextFill(Color.GREEN); // Die Schriftfarbe wird auf Grün gesetzt\r\n\t\t// Der VBox wird das Label mit den einstellungen übergeben\t\r\n\t\tvbox1Spalte2.getChildren().add(schonzeitaaLabel);\r\n\t\t\r\n\t\t// 2. Spalte und 2. Box\r\n\t\tvbox2Spalte2.getChildren().addAll(aescheLabel,aeschebildLabel); // Zweite Linie zweite Spalte mit Bild und Text\r\n\t\tif (datum >= 2 && datum <= 4) { // Die Schonzeit wird geprüft\r\n\t\t\tschonzeitaescheLabel.setText(\"hat Schonzeit !\"); // Trifft die IF zu wird dieser Text gesetzt\r\n\t\t\tschonzeitaescheLabel.setTextFill(Color.RED); // Die Schrifftfarbe wird auf Rot gesetzt\r\n\t\t}else { // Wen die IF nicht erfüllt ist\r\n\t\t\tschonzeitaescheLabel.setText(\"keine Schonzeit\"); // Trift due IF nicht zu wird dieser Text gesetzt\r\n\t\t\tschonzeitaescheLabel.setTextFill(Color.GREEN); // Die Schriftfarbe wird auf Grün gesetzt\r\n\t\t}\r\n\t\t// Der VBox wird das Label mit den Einstellungen übergeben\r\n\t\tvbox2Spalte2.getChildren().add(schonzeitaescheLabel);\r\n\t\t\r\n\t\t// 3. Spalte und 1. Box\r\n\t\tvbox1Spalte3.getChildren().addAll(barschLabel,barschbildLabel); // Dritte Linie erste Spalte mit Bild und Text\r\n\t\t// Der Barsch hat keine Schonzeit\r\n\t\t\tschonzeitbarschLabel.setText(\"keine Schonzeit\");\r\n\t\t\tschonzeitbarschLabel.setTextFill(Color.GREEN); // Die Schriftfarbe wird auf Grün gesetzt\r\n\t\t// Der VBox wird das Label mit den Einstellungen übergeben\t\r\n\t\tvbox1Spalte3.getChildren().add(schonzeitbarschLabel);\r\n\t\t\r\n\t\t// 3. Spalte und 2. Box\r\n\t\tvbox2Spalte3.getChildren().addAll(forelleLabel,forellebildLabel); // Dritte Linie zweite Spalte mit Bild und Text\r\n\t\tif (datum >= 3 && datum <= 9) { // Die Schonzeit wird geprüft\r\n\t\t\tschonzeitforelleLabel.setText(\"keine Schonzeit\"); // Trifft die IF zu wird dieser Text gesetzt\r\n\t\t\tschonzeitforelleLabel.setTextFill(Color.GREEN); // Die Schriftfarbe wird auf Grün gesetzt\r\n\t\t}else { // Wen die IF nicht erfüllt ist\r\n\t\t\tschonzeitforelleLabel.setText(\"hat Schonzeit !\"); // Die Schonzeit des Hechtes wird überprüft\r\n\t\t\tschonzeitforelleLabel.setTextFill(Color.RED); // Trift due IF nicht zu wird dieser Text gesetzt\r\n\t\t}\r\n\t\t// Der VBox wird das Label mit den Einstellungen übergeben\r\n\t\tvbox2Spalte3.getChildren().add(schonzeitforelleLabel);\r\n\t\t\r\n\t\t// 4. Spalte und 1. Box\r\n\t\tvbox1Spalte4.getChildren().addAll(schleieLabel,schleiebildLabel); // Vierte Linie erste Spalte mit Bild und Text\r\n\t\t// Die Schleie hat keien Schonzeit\r\n\t\t\tschonzeitschleieLabel.setText(\"keine Schonzeit\"); // Text wird gesetzt\r\n\t\t\tschonzeitschleieLabel.setTextFill(Color.GREEN); // Die Schriftfarbe wird auf Grün gesetzt\r\n\t\t// Der VBox wird das Label mit den Einstellungen übergeben\t\r\n\t\tvbox1Spalte4.getChildren().add(schonzeitschleieLabel);\r\n\t\t\r\n\t\t// 4. Spalte und 2. Box\r\n\t\tvbox2Spalte4.getChildren().addAll(karpfeLabel,karpfenbildLabel); // Vierte Linie zweite Spalte mit Bild und Text\r\n\t\t// Der Karpfe hat keine Schonzeit\r\n\t\t\tschonzeitkarpfeLabel.setText(\"keine Schonzeit\"); // Text wird gesetzt\r\n\t\t\tschonzeitkarpfeLabel.setTextFill(Color.GREEN); // Die Schriftfarbe wird auf Grün gesetzt\r\n\t\t// Der VBox wird das Label mit den Einstellungen übergeben\t\r\n\t\tvbox2Spalte4.getChildren().add(schonzeitkarpfeLabel);\r\n\t\t\r\n\t\t//\r\n\t\t// // Die einzelnen HBoxen werden gefüllt für die Spalten in der Root\r\n\t\t//\r\n\t\thBoxSpalte1.getChildren().addAll(vBox1Spalte1,vBox2Spalte1); // Die erste Spalte wird mit den zwei Boxen gefüllt\r\n\t\t// HBox Spalte 2\r\n\t\thBoxSpalte2.getChildren().addAll(vbox1Spalte2,vbox2Spalte2); // Die zweite Spalte wird mit den zwei Boxen gefüllt\r\n\t\t// Hbox Spalte 3\r\n\t\thboxSpalte3.getChildren().addAll(vbox1Spalte3,vbox2Spalte3); // Die dritte Spalte wird mit den zwei Boxen gefüllt\r\n\t\t// Hbox Spalte 4\r\n\t\thboxSpalte4.getChildren().addAll(vbox1Spalte4,vbox2Spalte4); // Die vierte Spalte wird mit den zwei Boxen gefüllt\r\n\t\t\r\n\t\t// Elemente werden der HauptVBox root hinzugefügt\r\n\t\troot.getChildren().addAll(fischeAuswahlLabel,hBoxSpalte1,hBoxSpalte2,hboxSpalte3,hboxSpalte4,hauptmenuButton); // Alle gefüllten Boxen werden der Hauptbox übergeben\r\n\t\t\r\n\t\t// Das root wird zurückgegeben um Angezeigt zu werden\r\n\t\treturn root;\r\n\t}",
"public void createGUI() {\n\n\t\tcontents = getContentPane();\n\t\tcontents.setLayout(new GridLayout(size, size));\n\n\t\t// Set Up Menu Bar\n\t\tJMenuBar menuBar = new JMenuBar();\n\t\tsetJMenuBar(menuBar);\n\n\t\tJMenu game = new JMenu(\"Game\");\n\t\tmenuBar.add(game);\n\t\tJMenuItem clearBoard = new JMenuItem(\"New Game\");\n\t\tgame.add(clearBoard);\n\t\tJMenuItem boardSize = new JMenuItem(\"Change Size\");\n\t\tgame.add(boardSize);\n\t\tJMenuItem exit = new JMenuItem(\"Exit\");\n\t\tgame.add(exit);\n\n\t\tJMenu help = new JMenu(\"Help\");\n\t\tmenuBar.add(help);\n\t\tJMenuItem rules = new JMenuItem(\"How to Play\");\n\t\thelp.add(rules);\n\t\tJMenuItem about = new JMenuItem(\"About\");\n\t\thelp.add(about);\n\n\t\tJMenu playerSelect = new JMenu(\"Players: \" + players);\n\t\tmenuBar.add(playerSelect);\n\t\tJMenuItem players2 = new JMenuItem(\"2 Player Game\");\n\t\tplayerSelect.add(players2);\n\t\tJMenuItem players3 = new JMenuItem(\"3 Player Game\");\n\t\tplayerSelect.add(players3);\n\t\tJMenuItem players4 = new JMenuItem(\"4 Player Game\");\n\t\tplayerSelect.add(players4);\n\n\t\tmenuBar.add(Box.createHorizontalGlue());\n\n\t\tplayerTurnLbl.setFont(new Font(\"Lucida Grande\", Font.BOLD, 12)); // Player 1's Turn\n\t\tmenuBar.add(playerTurnLbl);\n\t\tplayerTurnLbl.setVisible(true);\n\n\t\tinvalidMoveLbl.setFont(new Font(\"Lucida Grande\", Font.BOLD, 12)); // Invalid Move Alert\n\t\tinvalidMoveLbl.setForeground(Color.RED);\n\t\tmenuBar.add(invalidMoveLbl);\n\t\tinvalidMoveLbl.setVisible(false);\n\n\t\t// Exit Button Action\n\t\texit.addActionListener(new ActionListener() {\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\tSystem.exit(0);\n\t\t\t}\n\t\t});\n\n\t\t// Board Size Button Action\n\t\tboardSize.addActionListener(new ActionListener() {\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\trestartGame();\n\t\t\t}\n\t\t});\n\n\t\t// Reset Board Button Action\n\t\tclearBoard.addActionListener(new ActionListener() {\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\tresetBoard();\n\t\t\t}\n\t\t});\n\n\t\t// Rules Button Action\n\t\trules.addActionListener(new ActionListener() {\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\tJOptionPane.showMessageDialog(null,\n\t\t\t\t\t\t\"1. Players take turns moving up, down, left, or right to generate a self-avoiding walk.\\n\\tClick on a square to make your move.\\n\\n2. A player who makes a self-intersecting move loses the game. \\n\\n3. A player can win the game by making a self-intersecting move that creates a self-avoiding polygon.\\n\\tThis is only valid after at least 4 moves.\",\n\t\t\t\t\t\t\"Self-Avoiding Walk Game Rules\", JOptionPane.PLAIN_MESSAGE);\n\t\t\t}\n\t\t});\n\n\t\t// About Button Action\n\t\tabout.addActionListener(new ActionListener() {\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\tJOptionPane.showMessageDialog(null,\n\t\t\t\t\t\t\"Self-Avoiding Walk Multiplayer Game\\nDeveloped by Adam Binder\\nCopyright 2019\", \"About\",\n\t\t\t\t\t\tJOptionPane.INFORMATION_MESSAGE);\n\t\t\t}\n\t\t});\n\n\t\t// 2 Player Button Action\n\t\tplayers2.addActionListener(new ActionListener() {\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\tplayers = 2;\n\t\t\t\tresetBoard();\n\t\t\t}\n\t\t});\n\n\t\t// 3 Player Button Action\n\t\tplayers3.addActionListener(new ActionListener() {\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\tplayers = 3;\n\t\t\t\tresetBoard();\n\t\t\t}\n\t\t});\n\n\t\t// 4 Player Button Action\n\t\tplayers4.addActionListener(new ActionListener() {\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\tplayers = 4;\n\t\t\t\tresetBoard();\n\t\t\t}\n\t\t});\n\n\t\t// Create event handlers:\n\t\tButtonHandler buttonHandler = new ButtonHandler();\n\n\t\t// Create and add board components:\n\t\tfor (int i = 0; i < size; i++) {\n\t\t\tfor (int j = 0; j < size; j++) {\n\t\t\t\tsquares[i][j] = new JButton();\n\t\t\t\tsquares[i][j].setBorder(null);\n\t\t\t\tsquares[i][j].setOpaque(true);\n\t\t\t\tsquares[i][j].setBorderPainted(false);\n\t\t\t\tif ((i + j) % 2 != 0) {\n\t\t\t\t\tsquares[i][j].setBackground(colorGray);\n\t\t\t\t\tsquares[i][j].setBorder(null);\n\t\t\t\t\tsquares[i][j].setOpaque(true);\n\t\t\t\t}\n\t\t\t\tcontents.add(squares[i][j]);\n\t\t\t\tsquares[i][j].addActionListener(buttonHandler);\n\t\t\t}\n\t\t}\n\t}",
"private void createContents() {\r\n\t\tshlAjouterNouvelleEquation = new Shell(getParent(), SWT.DIALOG_TRIM | SWT.RESIZE | SWT.APPLICATION_MODAL);\r\n\t\tshlAjouterNouvelleEquation.setSize(363, 334);\r\n\t\tif(modification)\r\n\t\t\tshlAjouterNouvelleEquation.setText(\"Modifier Equation\");\r\n\t\telse\r\n\t\t\tshlAjouterNouvelleEquation.setText(\"Ajouter Nouvelle Equation\");\r\n\t\tshlAjouterNouvelleEquation.setLayout(new FormLayout());\r\n\r\n\r\n\t\tLabel lblContenuEquation = new Label(shlAjouterNouvelleEquation, SWT.NONE);\r\n\t\tFormData fd_lblContenuEquation = new FormData();\r\n\t\tfd_lblContenuEquation.top = new FormAttachment(0, 5);\r\n\t\tfd_lblContenuEquation.left = new FormAttachment(0, 5);\r\n\t\tlblContenuEquation.setLayoutData(fd_lblContenuEquation);\r\n\t\tlblContenuEquation.setText(\"Contenu Equation\");\r\n\r\n\r\n\t\tcontrainteButton = new Button(shlAjouterNouvelleEquation, SWT.CHECK);\r\n\t\tFormData fd_btnContrainte = new FormData();\r\n\t\tfd_btnContrainte.top = new FormAttachment(0, 27);\r\n\t\tfd_btnContrainte.right = new FormAttachment(100, -10);\r\n\t\tcontrainteButton.setLayoutData(fd_btnContrainte);\r\n\t\tcontrainteButton.setText(\"Contrainte\");\r\n\r\n\t\torientationButton = new Button(shlAjouterNouvelleEquation, SWT.CHECK);\r\n\t\tFormData fd_btnOrinet = new FormData();\r\n\t\tfd_btnOrinet.top = new FormAttachment(0, 27);\r\n\t\tfd_btnOrinet.right = new FormAttachment(contrainteButton, -10);\r\n\r\n\t\torientationButton.setLayoutData(fd_btnOrinet);\r\n\t\t\r\n\t\torientationButton.setText(\"Orient\\u00E9\");\r\n\r\n\t\tcontenuEquation = new Text(shlAjouterNouvelleEquation, SWT.BORDER|SWT.SINGLE);\r\n\t\tFormData fd_text = new FormData();\r\n\t\tfd_text.right = new FormAttachment(orientationButton, -10, SWT.LEFT);\r\n\t\tfd_text.top = new FormAttachment(0, 25);\r\n\t\tfd_text.left = new FormAttachment(0, 5);\r\n\t\tcontenuEquation.setLayoutData(fd_text);\r\n\r\n\t\tcontenuEquation.addListener(SWT.FocusOut, out->{\r\n\t\t\tSystem.out.println(\"Making list...\");\r\n\t\t\ttry {\r\n\t\t\t\tequation.getListeDeParametresEqn_DYNAMIC();\r\n\t\t\t\tif(!btnTerminer.isDisposed()){\r\n\t\t\t\t\tif(!btnTerminer.getEnabled())\r\n\t\t\t\t\t\t btnTerminer.setEnabled(true);\r\n\t\t\t\t}\r\n\t\t\t} catch (Exception e1) {\r\n\t\t\t\tthis.showError(shlAjouterNouvelleEquation, e1.toString());\r\n\t\t\t\t btnTerminer.setEnabled(false);\r\n\t\t\t\te1.printStackTrace();\r\n\t\t\t}\t\r\n\t\t});\r\n\r\n\t\tLabel lblNewLabel = new Label(shlAjouterNouvelleEquation, SWT.NONE);\r\n\t\tFormData fd_lblNewLabel = new FormData();\r\n\t\tfd_lblNewLabel.top = new FormAttachment(0, 51);\r\n\t\tfd_lblNewLabel.left = new FormAttachment(0, 5);\r\n\t\tlblNewLabel.setLayoutData(fd_lblNewLabel);\r\n\t\tlblNewLabel.setText(\"Param\\u00E8tre de Sortie\");\r\n\r\n\t\tparametreDeSortieCombo = new Combo(shlAjouterNouvelleEquation, SWT.DROP_DOWN |SWT.READ_ONLY);\r\n\t\tparametreDeSortieCombo.setEnabled(false);\r\n\r\n\t\tFormData fd_combo = new FormData();\r\n\t\tfd_combo.top = new FormAttachment(0, 71);\r\n\t\tfd_combo.left = new FormAttachment(0, 5);\r\n\t\tparametreDeSortieCombo.setLayoutData(fd_combo);\r\n\t\tparametreDeSortieCombo.addListener(SWT.FocusIn, in->{\r\n\t\t\tparametreDeSortieCombo.setItems(makeItems.apply(equation.getListeDeParametresEqn()));\r\n\t\t\tparametreDeSortieCombo.pack();\r\n\t\t\tparametreDeSortieCombo.update();\r\n\t\t});\r\n\r\n\t\tSashForm sashForm = new SashForm(shlAjouterNouvelleEquation, SWT.NONE);\r\n\t\tFormData fd_sashForm = new FormData();\r\n\t\tfd_sashForm.top = new FormAttachment(parametreDeSortieCombo, 6);\r\n\t\tfd_sashForm.bottom = new FormAttachment(100, -50);\r\n\t\tfd_sashForm.right = new FormAttachment(100);\r\n\t\tfd_sashForm.left = new FormAttachment(0, 5);\r\n\t\tsashForm.setLayoutData(fd_sashForm);\r\n\r\n\r\n\r\n\r\n\t\tGroup propertiesGroup = new Group(sashForm, SWT.NONE);\r\n\t\tpropertiesGroup.setLayout(new FormLayout());\r\n\r\n\t\tpropertiesGroup.setText(\"Propri\\u00E9t\\u00E9s\");\r\n\t\tFormData fd_propertiesGroup = new FormData();\r\n\t\tfd_propertiesGroup.top = new FormAttachment(0);\r\n\t\tfd_propertiesGroup.left = new FormAttachment(0);\r\n\t\tfd_propertiesGroup.bottom = new FormAttachment(100, 0);\r\n\t\tfd_propertiesGroup.right = new FormAttachment(100, 0);\r\n\t\tpropertiesGroup.setLayoutData(fd_propertiesGroup);\r\n\r\n\r\n\r\n\r\n\r\n\t\tproperties = new Text(propertiesGroup, SWT.BORDER | SWT.WRAP | SWT.V_SCROLL);\r\n\t\tFormData fd_grouptext = new FormData();\r\n\t\tfd_grouptext.top = new FormAttachment(0,0);\r\n\t\tfd_grouptext.left = new FormAttachment(0, 0);\r\n\t\tfd_grouptext.bottom = new FormAttachment(100, 0);\r\n\t\tfd_grouptext.right = new FormAttachment(100, 0);\r\n\t\tproperties.setLayoutData(fd_grouptext);\r\n\r\n\r\n\r\n\t\tGroup grpDescription = new Group(sashForm, SWT.NONE);\r\n\t\tgrpDescription.setText(\"Description\");\r\n\t\tgrpDescription.setLayout(new FormLayout());\r\n\t\tFormData fd_grpDescription = new FormData();\r\n\t\tfd_grpDescription.bottom = new FormAttachment(100, 0);\r\n\t\tfd_grpDescription.right = new FormAttachment(100,0);\r\n\t\tfd_grpDescription.top = new FormAttachment(0);\r\n\t\tfd_grpDescription.left = new FormAttachment(0);\r\n\t\tgrpDescription.setLayoutData(fd_grpDescription);\r\n\r\n\t\tdescription = new Text(grpDescription, SWT.BORDER | SWT.WRAP | SWT.V_SCROLL | SWT.MULTI);\r\n\t\tdescription.setParent(grpDescription);\r\n\r\n\t\tFormData fd_description = new FormData();\r\n\t\tfd_description.top = new FormAttachment(0,0);\r\n\t\tfd_description.left = new FormAttachment(0, 0);\r\n\t\tfd_description.bottom = new FormAttachment(100, 0);\r\n\t\tfd_description.right = new FormAttachment(100, 0);\r\n\r\n\t\tdescription.setLayoutData(fd_description);\r\n\r\n\r\n\t\tsashForm.setWeights(new int[] {50,50});\r\n\r\n\t\tbtnTerminer = new Button(shlAjouterNouvelleEquation, SWT.NONE);\r\n\t\tbtnTerminer.setEnabled(false);\r\n\t\tFormData fd_btnTerminer = new FormData();\r\n\t\tfd_btnTerminer.top = new FormAttachment(sashForm, 6);\r\n\t\tfd_btnTerminer.left = new FormAttachment(sashForm,0, SWT.CENTER);\r\n\t\tbtnTerminer.setLayoutData(fd_btnTerminer);\r\n\t\tbtnTerminer.setText(\"Terminer\");\r\n\t\tbtnTerminer.addListener(SWT.Selection, e->{\r\n\t\t\t\r\n\t\t\tboolean go = true;\r\n\t\t\tresult = null;\r\n\t\t\tif (status.equals(ValidationStatus.ok())) {\r\n\t\t\t\t//perform all the neccessary tests before validating the equation\t\t\t\t\t\r\n\t\t\t\tif(equation.isOriented()){\r\n\t\t\t\t\tif(!equation.getListeDeParametresEqn().contains(equation.getParametreDeSortie()) || equation.getParametreDeSortie() == null){\t\t\t\t\t\t\r\n\t\t\t\t\t\tString error = \"Erreur sur l'équation \"+equation.getContenuEqn();\r\n\t\t\t\t\t\tgo = false;\r\n\t\t\t\t\t\tshowError(shlAjouterNouvelleEquation, error);\t\t\t\t\t\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif (go) {\r\n\t\t\t\t\t\tresult = Boolean.TRUE;\r\n\t\t\t\t\t\tshlAjouterNouvelleEquation.dispose();\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t}\r\n\t\t\t\telse {\r\n\t\t\t\t\tequation.setParametreDeSortie(null);\r\n\t\t\t\t\tresult = Boolean.TRUE;\r\n\t\t\t\t\t//Just some cleanup\r\n\t\t\t\t\tfor (Parametre par : equation.getListeDeParametresEqn()) {\r\n\t\t\t\t\t\tif (par.getTypeP().equals(TypeParametre.OUTPUT)) {\t\t\t\t\t\r\n\t\t\t\t\t\t\ttry {\r\n\t\t\t\t\t\t\t\tpar.setTypeP(TypeParametre.UNDETERMINED);\r\n\t\t\t\t\t\t\t\tpar.setSousTypeP(SousTypeParametre.FREE);\r\n\t\t\t\t\t\t\t} catch (Exception e1) {\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t\te1.printStackTrace();\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t\tshlAjouterNouvelleEquation.dispose();\r\n\t\t\t\t}\r\n\r\n\t\t\t}\r\n\t\t//\tSystem.out.println(equation.getContenuEqn() +\"\\n\"+equation.isConstraint()+\"\\n\"+equation.isOriented()+\"\\n\"+equation.getParametreDeSortie());\r\n\t\t});\r\n\r\n\t\t//In this sub routine I bind the values to the respective controls in order to observe changes \r\n\t\t//and verify the data insertion\r\n\t\tbindValues();\r\n\t}",
"private ProgramGUI() {\n\t\tsetSize(FRAME_WIDTH, FRAME_HEIGHT);\n\t\tsetLocationRelativeTo(null);\n\t\tsetDefaultCloseOperation(EXIT_ON_CLOSE);\n\t\tJPanel panel = new JPanel();\n\t\tpanel.setLayout(new GridLayout(1, 2));\n\t\tpanel.setBorder(BorderFactory.createEmptyBorder(10, 10, 0, 10));\n\t\tpanel.add(new JLabel(\"Enter Command: \"));\n\t\tcmd = new JTextField();\n\t\tpanel.add(cmd);\n\t\tadd(panel, BorderLayout.NORTH);\n\t\tJPanel button = new JPanel();\n\t\tJButton ok = new JButton(\"Confirm Command\");\n\t\tJButton logout = new JButton(\"Log Out\");\n\t\tok.addActionListener(new OKListener());\n\t\tlogout.addActionListener(new LogoutListener());\n\t\tbutton.add(ok);\n\t\tbutton.add(logout);\n\t\tadd(button, BorderLayout.SOUTH);\n\t\tsetVisible(true);\n\t\tif(isTillOpen) {\n\t\t\tsetTitle(\"Till Open\");\n\t\t}\n\t\telse {\n\t\t\tsetTitle(\"Till Closed\");\n\t\t}\n\t}",
"public GUI(){\n\t\tSIZE = promptSIZE();\n\t\tframe = new JFrame(\"Five in a row developed by Wonjohn Choi in G.Y.G.D.\");\n\t\tframe.setLayout(new GridLayout(SIZE, SIZE));\n\t\t\n\t\tbuttonGrid = new JButton[SIZE][SIZE];\n\t\t\n\t\tfor(int row=0;row<SIZE;row++){\n\t\t\tfor(int col=0;col<SIZE;col++){\n\t\t\t\tbuttonGrid[row][col] = new JButton();\n\t\t\t\tframe.add(buttonGrid[row][col]);\n\t\t\t\tbuttonGrid[row][col].addActionListener(this);\n\t\t\t}\n\t\t}\n\t\t\n\t\tframe.setSize(50*SIZE, 50*SIZE);\n\t\tframe.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);\n\t\tframe.setVisible(true);\n\t\t\n\t\tengine = new Engine(SIZE);\n\t}",
"public GUI() {\n\t\t// sets up file choosers\n\t\tsetFileChoosers();\n\t\t// initialises JFrame\n\t\tsetContent();\n\t\t// sets default window attributes\n\t\tthis.setDefaultAttributes();\n\t\t// instantiates controller object\n\t\tsetController();\n\t\t// sets toolbar to go over frame\n\t\tJPopupMenu.setDefaultLightWeightPopupEnabled(false);\n\t\tToolTipManager.sharedInstance().setLightWeightPopupEnabled(false);\n\t\t// sets antialiasing\n\t\t((Graphics2D) this.getGraphics()).setRenderingHint(RenderingHints.KEY_TEXT_ANTIALIASING,\n\t\t\t\tRenderingHints.VALUE_TEXT_ANTIALIAS_ON);\n\t}",
"private void initUI() {\r\n\t\t//Äußeres Panel\r\n\t\tContainer pane = getContentPane();\r\n\t\tGroupLayout gl = new GroupLayout(pane);\r\n\t\tpane.setLayout(gl);\r\n\t\t//Abstende von den Containern und dem äußeren Rand\r\n\t\tgl.setAutoCreateContainerGaps(true);\r\n\t\tgl.setAutoCreateGaps(true);\r\n\t\t//TextFeld für die Ausgabe\r\n\t\tJTextField output = view.getTextField();\r\n\t\t//Die jeweiligen Panels für die jeweiigen Buttons\r\n\t\tJPanel brackets = view.getBracketPanel();\r\n\t\tJPanel remove = view.getTop2Panel();\r\n\t\tJPanel numbers = view.getNumbersPanel();\r\n\t\tJPanel last = view.getBottomPanel();\r\n\t\t//Anordnung der jeweiligen Panels durch den Layout Manager\r\n\t\tgl.setHorizontalGroup(gl.createParallelGroup().addComponent(output).addComponent(brackets).addComponent(remove).addComponent(numbers).addComponent(last));\r\n\t\tgl.setVerticalGroup(gl.createSequentialGroup().addComponent(output).addComponent(brackets).addComponent(remove).addComponent(numbers).addComponent(last));\r\n\t\tpack();\r\n\t\tsetTitle(\"Basic - Taschenrechner\");\r\n\t\tsetDefaultCloseOperation(EXIT_ON_CLOSE);\r\n\t\tsetResizable(false);\r\n\t}",
"public SearchFrame(){//The main search frame which calls other methods\n\t\t/*Calling the methods intitialiseGUI and buildGUI*/\n\t\tintitialiseGUI();\n\t\tbuildGUI();\n\t}",
"private GUIReminder() {\n\n initComponents();\n initOthers();\n\n }",
"public void makeGUI()\n\t{\n\t\tbuttonPanel = new ButtonPanel(this,ship,planet);\n\t\tgamePanel = new GamePanel(this,ship,planet);\n\n\t\tJMenuBar menubar = new JMenuBar();\n\t\tJMenu menuHelp = new JMenu(\"Help\");\n\t\thelpItem = new JMenuItem(\"Help\");\n\t\tmenuHelp.add(helpItem);\n\t\tmenubar.add(menuHelp);\n\t\tsetJMenuBar(menubar);\n\n\t\tsounds = new AudioClip[2];\n\n\t\ttry\n\t\t{\n\t\t\turl = new URL(getCodeBase() + \"/thrust.au\");\n\t\t\tsounds[0] = Applet.newAudioClip(url);\n\t\t\turl = new URL(getCodeBase() + \"/crash.au\");\n\t\t\tsounds[1] = Applet.newAudioClip(url);\n\t\t}\n\t\tcatch(Exception e){}\n\n\t\thelpItem.addActionListener(new ActionListener(){\n\t\t\tpublic void actionPerformed(ActionEvent e)\n\t\t\t{\n\t\t\t\tif(e.getSource() == helpItem)\n\t\t\t\t{\n\t\t\t\t\tString helpMessage = \"The goal of the game is to land\\nthe ship on the red lines (pads).\\nThe ship must be completely contained\\nwithin the bounds of the red pad.\\nThere are 10 levels total\\nand you will have a certain amount\\nof time to complete each level.\\nGood Landing: velocities must be <10\\nOK Landing: velocities must be <20\\nThe ship's bottom must be facing the ground.\";\n\t\t\t\t\tJOptionPane.showMessageDialog(lander, helpMessage, \"Help Display\", JOptionPane.INFORMATION_MESSAGE);\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\n\t\tgetContentPane().add(gamePanel, BorderLayout.PAGE_START);\n\t\tgetContentPane().add(buttonPanel, BorderLayout.PAGE_END);\n\t\tsetVisible(true);\n\t}",
"public GUI() {\n initComponents();\n this.setVisible(true);\n }",
"public TrainModelGUI CreateNewGUI() {\n //Create a GUI object\n \ttrainModelGUI = new TrainModelGUI(this);\n \tsetValuesForDisplay();\n \treturn trainModelGUI;\n }",
"public guiProntuarioVirtual() {\n initComponents();\n \n }",
"@Override\n public void initGui()\n {\n super.initGui();\n }",
"private GUIAltaHabitacion() {\r\n\t initComponents();\r\n\t }",
"private void buildGUI() {\r\n textArea = new JTextArea(20, 50);\r\n textArea.setEditable(false);\r\n textArea.setLineWrap(true);\r\n add(new JScrollPane(textArea), BorderLayout.CENTER);\r\n\r\n Box box = Box.createHorizontalBox();\r\n add(box, BorderLayout.SOUTH);\r\n inputTextField = new JTextField();\r\n sendButton = new JButton(\"Send\");\r\n box.add(inputTextField);\r\n box.add(sendButton);\r\n\r\n // Action for the inputTextField and the goButton\r\n ActionListener sendListener = new ActionListener() {\r\n public void actionPerformed(ActionEvent e) {\r\n String str = inputTextField.getText();\r\n if (str != null && str.trim().length() > 0) {\r\n chatAccess.send(str);\r\n }\r\n inputTextField.selectAll();\r\n inputTextField.requestFocus();\r\n inputTextField.setText(\"\");\r\n }\r\n };\r\n inputTextField.addActionListener(sendListener);\r\n sendButton.addActionListener(sendListener);\r\n\r\n this.addWindowListener(new WindowAdapter() {\r\n @Override\r\n public void windowClosing(WindowEvent e) {\r\n chatAccess.close();\r\n }\r\n });\r\n }",
"private static void createAndShowGUI() {\n Font f = new Font(\"微软雅黑\", 0, 12);\n String names[] = {\"Label\", \"CheckBox\", \"PopupMenu\", \"MenuItem\", \"CheckBoxMenuItem\",\n \"JRadioButtonMenuItem\", \"ComboBox\", \"Button\", \"Tree\", \"ScrollPane\",\n \"TabbedPane\", \"EditorPane\", \"TitledBorder\", \"Menu\", \"TextArea\",\n \"OptionPane\", \"MenuBar\", \"ToolBar\", \"ToggleButton\", \"ToolTip\",\n \"ProgressBar\", \"TableHeader\", \"Panel\", \"List\", \"ColorChooser\",\n \"PasswordField\", \"TextField\", \"Table\", \"Label\", \"Viewport\",\n \"RadioButtonMenuItem\", \"RadioButton\", \"DesktopPane\", \"InternalFrame\"\n };\n for (String item : names) {\n UIManager.put(item + \".font\", f);\n }\n //Create and set up the window.\n JFrame frame = new JFrame(\"AutoCapturePackagesTool\");\n\n String src = \"/optimizationprogram/GUICode/u5.png\";\n Image image = null;\n try {\n image = ImageIO.read(new CaptureGUI().getClass().getResource(src));\n } catch (IOException e) {\n e.printStackTrace();\n }\n\n frame.setIconImage(image);\n //frame.setIconImage(Toolkit.getDefaultToolkit().getImage(src));\n frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);\n frame.setResizable(false);\n frame.setLocation(Toolkit.getDefaultToolkit().getScreenSize().width / 2 - 520 / 2,\n Toolkit.getDefaultToolkit().getScreenSize().height / 2 - 420 / 2);\n frame.getContentPane().add(new CaptureGUI());\n //Display the window.\n frame.pack();\n frame.setVisible(true);\n }",
"private static void createAndShowGUI() {\n\t\t\t\t// GUIView Moves\n\t\t\t\tGUIViewMoves guiViewMoves = new GUIViewMoves();\n\t\t\t\t\n\t\t\t\t// GUIView Jugs, center the jugs\n\t\t\t\tGUIViewJugs guiViewJug0 = new GUIViewJugs(0);\n\t\t\t\tguiViewJug0.setHorizontalAlignment(JLabel.CENTER);\n\t\t\t\tguiViewJug0.setVerticalAlignment(JLabel.CENTER);; \n\t\t\t \n\t\t\t\tGUIViewJugs guiViewJug1 = new GUIViewJugs(1); \n\t\t\t\tguiViewJug1.setHorizontalAlignment(JLabel.CENTER);\n\t\t\t\tguiViewJug1.setVerticalAlignment(JLabel.CENTER);\n\t\t\t \n\t\t\t\tGUIViewJugs guiViewJug2 = new GUIViewJugs(2); \n\t\t\t\tguiViewJug2.setHorizontalAlignment(JLabel.CENTER);\n\t\t\t\tguiViewJug2.setVerticalAlignment(JLabel.CENTER);\n\t\t\t\n\t\t\t\t// Model\n\t\t\t\tJugPuzzle model = new JugPuzzle();\n\n\t\t\t\t// Hook the model to the view.\n\t\t\t\tmodel.addObserver(guiViewMoves);\n\t\t\t\tmodel.addObserver(guiViewJug0);\n\t\t\t\tmodel.addObserver(guiViewJug1);\n\t\t\t\tmodel.addObserver(guiViewJug2);\n\t\t\t\t\n\t\t\t\t// Create frame.\n\t\t\t\tJFrame frame = new JFrame(\"Jug Game!\");\n\t\t\n\t\t\t\t// Close option.\n\t\t\t\tframe.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);\n\t\t\t\t\n\t\t\t\t// Create two panels, one for the moves and the other for the buttons.\n\t\t\t\t// Labels and buttons go on the grid panel and the moves and restart/quit buttons go on the other panel.\n\t\t\t\tJPanel movesAndButtons = new JPanel();\n\t\t\t\tJPanel grid = new JPanel();\n\t\t\t\t\n\t\t\t\t// A container.\n\t\t\t\tContainer c = frame.getContentPane();\n\t\t\t\t\n\t\t\t\t// Layout for the grid.\n\t\t\t\tGridLayout topGrid = new GridLayout(2,3);\n\t\t\t\tgrid.setLayout(topGrid);\n\t\t\t\t\n\t\t\t\t// Layout for the buttons and moves.\n\t\t\t\tmovesAndButtons.setLayout(new BoxLayout(movesAndButtons, FlowLayout.CENTER));\n\n\t\t\t\t// Panels for buttons and moves.\n\t\t\t\tJPanel movesPanel = new JPanel(); // Moves panel, GUI View.\n\t\t\t\tJPanel quitRestartPanel = new JPanel(); // Quit and Restart panel.\n\t\n\t\t\t\t// Add panels to the layout.\n\t\t\t\tmovesAndButtons.add(movesPanel, BorderLayout.SOUTH);\n\t\t\t\tmovesAndButtons.add(quitRestartPanel, BorderLayout.NORTH);\n\t\t\t\tJButton restart, quit, eight, five, three;\n\t\t\t\n\t\t\t // Initialize buttons,\n\t\t\t\teight = new JButton(\"8\");\n\t\t\t five = new JButton(\"5\");\n\t\t\t three = new JButton(\"3\");\n\t\t\t restart = new JButton(\"Restart\");\n\t\t\t quit = new JButton(\"Quit\");\n\t\t\t \n\t\t\t // Add to grid.\n\t\t\t grid.add(guiViewJug0);\n\t\t\t grid.add(guiViewJug1);\n\t\t\t grid.add(guiViewJug2);\n\t\t\t grid.add(eight);\n\t\t\t grid.add(five);\n\t\t\t grid.add(three);\n\t\t\t\t\n\t\t\t\t// Add to the panels.\n\t\t\t movesPanel.add(guiViewMoves);\n\t\t\t\tquitRestartPanel.add(restart);\n\t\t\t\tquitRestartPanel.add(quit);\n\t\t\t\t\n\t\t\t\t// Add the container which adds to the frame.\n\t\t\t\tc.add(grid, BorderLayout.NORTH);\n\t\t\t\tc.add(movesAndButtons, BorderLayout.SOUTH);\n\t\t\t\t\n\t\t\t\t// ActionListeners \n\t\t\t\tJugPuzzleActionListener e = new JugPuzzleActionListener(model);\n\t\t\t\tQuitActionListener end = new QuitActionListener();\n\t\t\t\tRestartActionListener fresh = new RestartActionListener();\n\t\t\t\t\n\t\t\t\teight.addActionListener(e);\n\t\t\t\teight.setActionCommand(\"0\");\n\t\t\t\t\n\t\t\t\tfive.addActionListener(e);\n\t\t\t\tfive.setActionCommand(\"1\");\n\t\t\t\t\n\t\t\t\tthree.addActionListener(e);\n\t\t\t\tthree.setActionCommand(\"2\");\n\t\t\t\t\n\t\t\t\trestart.addActionListener(fresh);\n\t\t\t\tquit.addActionListener(end);\n\t\t\t\t\n\t\t\t\t// Pack and see frame\n\t\t\t\tframe.pack();\n\t\t\t\tframe.setSize(480, 150);\n\t\t\t\tframe.setResizable(false);\n\t\t\t\tframe.setVisible(true);\t\n\t\t\t}",
"private static void createAndShowGUI() {\r\n //Disable boldface controls.\r\n UIManager.put(\"swing.boldMetal\", Boolean.FALSE); \r\n\r\n //Create and set up the window.\r\n JFrame frame = new JFrame(\"Exertion Scripting\");\r\n frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);\r\n\r\n //Create and set up the content pane.\r\n NetletEditor newContentPane = new NetletEditor(null);\r\n newContentPane.setOpaque(true); //content panes must be opaque\r\n frame.setContentPane(newContentPane);\r\n\r\n //Display the window.\r\n frame.pack();\r\n frame.setVisible(true);\r\n }",
"protected void initializeGUI() {\n\n\t}",
"private static void createAndShowGUI() {\n\t\tJFrame window = MainWindow.newInstance();\n\t\t\n //Display the window.\n window.pack();\n window.setVisible(true);\n \n }",
"private static void createAndShowGUI() {\n\t\t//creating the GUI\n\t\tPhotoViewer myViewer = new PhotoViewer();\n\n\t\t//setting the title\n\t\tmyViewer.setTitle(\"Cameron Chiaramonte (ccc7sej)\");\n\n\t\t//making sure it will close when the x is clicked\n\t\tmyViewer.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);\n\n\t\t//calling the method to add the components to the pane and then making it visible\n\t\tmyViewer.addComponentsToPane(myViewer.getContentPane());\n\t\tmyViewer.pack();\n\t\tmyViewer.setVisible(true);\n\t}",
"private void createUIComponents() {\n bt1 = new JButton(\"Hola\");\n }",
"private void createContents() {\r\n\t\tshlOProgramie = new Shell(getParent().getDisplay(), SWT.DIALOG_TRIM\r\n\t\t\t\t| SWT.RESIZE);\r\n\t\tshlOProgramie.setBackground(SWTResourceManager.getColor(255, 255, 255));\r\n\t\tshlOProgramie.setText(\"O programie\");\r\n\t\tshlOProgramie.setSize(386, 221);\r\n\t\tint x = 386;\r\n\t\tint y = 221;\r\n\t\t// Get the resolution\r\n\t\tRectangle pDisplayBounds = shlOProgramie.getDisplay().getBounds();\r\n\r\n\t\t// This formulae calculate the shell's Left ant Top\r\n\t\tint nLeft = (pDisplayBounds.width - x) / 2;\r\n\t\tint nTop = (pDisplayBounds.height - y) / 2;\r\n\r\n\t\t// Set shell bounds,\r\n\t\tshlOProgramie.setBounds(nLeft, nTop, x, y);\r\n\t\tsetText(\"O programie\");\r\n\r\n\t\tbtnZamknij = new Button(shlOProgramie, SWT.PUSH | SWT.BORDER_SOLID);\r\n\t\tbtnZamknij.addMouseListener(new MouseAdapter() {\r\n\t\t\t@Override\r\n\t\t\tpublic void mouseUp(MouseEvent e) {\r\n\t\t\t\tshlOProgramie.dispose();\r\n\t\t\t}\r\n\t\t});\r\n\t\tbtnZamknij.setBounds(298, 164, 68, 23);\r\n\t\tbtnZamknij.setText(\"Zamknij\");\r\n\r\n\t\tText link = new Text(shlOProgramie, SWT.READ_ONLY);\r\n\t\tlink.setBackground(SWTResourceManager.getColor(230, 230, 250));\r\n\t\tlink.setBounds(121, 127, 178, 13);\r\n\t\tlink.setText(\"Kontakt: [email protected]\");\r\n\r\n\t\tCLabel lblNewLabel = new CLabel(shlOProgramie, SWT.BORDER\r\n\t\t\t\t| SWT.SHADOW_IN | SWT.SHADOW_OUT | SWT.SHADOW_NONE);\r\n\t\tlblNewLabel.setBackground(SWTResourceManager.getColor(230, 230, 250));\r\n\t\tlblNewLabel.setBounds(118, 20, 248, 138);\r\n\t\tlblNewLabel\r\n\t\t\t\t.setText(\" Kalkulator walut ver 0.0.2 \\r\\n -------------------------------\\r\\n Program umo\\u017Cliwiaj\\u0105cy pobieranie\\r\\n aktualnych kurs\\u00F3w walut ze strony nbp.pl\\r\\n\\r\\n Copyright by Wojciech Trocki.\\r\\n\");\r\n\r\n\t\tLabel lblNewLabel_1 = new Label(shlOProgramie, SWT.NONE);\r\n\t\tlblNewLabel_1.setBackground(SWTResourceManager.getColor(255, 255, 255));\r\n\t\tlblNewLabel_1.setImage(SWTResourceManager.getImage(\"images/about.gif\"));\r\n\t\tlblNewLabel_1.setBounds(10, 20, 100, 138);\r\n\t}",
"public void memoGui() {\n HBox memos = new HBox();\n Label memoLabel = new Label(\"Add to memo\");\n ChoiceBox<Object> memoChoice = new ChoiceBox<>();\n memoChoice.getItems().addAll(mSys.getListOfMemo().toArray());\n memos.getChildren().addAll(memoLabel, memoChoice);\n\n Button button = new Button();\n if (isNew) {\n button.setText(\"Add Event to Memo\");\n } else {\n button.setText(\"Remove Event From Memo\");\n }\n\n button.setOnMouseClicked(e -> {\n if (isNew) {\n if (memoChoice.getValue() == null) {\n return;\n }\n memo = (Memo) memoChoice.getValue();\n mSys.addEventToMemo(memo, event.getId());\n } else {\n mSys.removeEventInMemo(event.getId());\n }\n stage.close();\n });\n\n VBox vBox = new VBox();\n if (isNew) {\n vBox.getChildren().addAll(memos, button);\n } else {\n vBox.getChildren().addAll(button);\n }\n\n Scene scene = new Scene(vBox, 500, 400);\n scene.getStylesheets().add(Theme.getInstance().getStylesheet());\n stage.setScene(scene);\n stage.showAndWait();\n }",
"private void InitGUI() {\n\n\t\t//Configuraciones de la ventana principal\n\t\tcontenedor = getContentPane();\n\t\tcontenedor.removeAll();\n\t\tgetContentPane().setLayout(null);\n\t\tthis.setUndecorated(true);\n\t\tlistener = new ManejadorDeBotones();\n\t\tmanejadorDesplazamientoVentana(this);\n\n\t\t// Logo del sofa\n\t\tJLabel imagenSofa = new JLabel(\"\");\n\t\timagenSofa.setIcon(new ImageIcon(GUIMenuAdmin.class.getResource(\"/images/sofa.png\")));\n\t\timagenSofa.setBounds(199, 15, 120, 80);\n\t\tgetContentPane().add(imagenSofa);\n\n\t\t// Etiqueta para el nombre al ladpo del logo\n\t\tJLabel lblMueblesYMuebles = new JLabel(\" Muebles y Muebles\");\n\t\tlblMueblesYMuebles.setFont(font);\n\t\tlblMueblesYMuebles.setForeground(Color.WHITE);\n\t\tlblMueblesYMuebles.setBounds(390, 77, 152, 32);\n\t\tgetContentPane().add(lblMueblesYMuebles);\n\n\t\t// Etiqueta para el logo XYZ\n\t\tJLabel imagenLogo = new JLabel(\"\");\n\t\timagenLogo.setIcon(\n\t\t\t\tnew ImageIcon(GUIMenuAdmin.class.getResource(\"/images/logo_blanco.png\")));\n\t\timagenLogo.setBounds(288, 23, 213, 82);\n\t\tgetContentPane().add(imagenLogo);\n\n\t\t//Boton para inicial crear ordenes de trabajo\n\t\tcrearOrden = new JButton(\"CREAR\");\n\t\tcrearOrden.setForeground(SystemColor.textHighlight);\n\t\tcrearOrden.setVerticalTextPosition(SwingConstants.BOTTOM);\n\t\tcrearOrden.setHorizontalTextPosition(SwingConstants.CENTER);\n\t\tcrearOrden.setIcon(new ImageIcon(GUIMenuAdmin.class.getResource(\"/images/orden_crear.png\")));\n\t\tcrearOrden.setFocusPainted(false);\n\t\tcrearOrden.setBorderPainted(false);\n\t\tcrearOrden.setOpaque(true);\n\t\tcrearOrden.setBackground(new Color(227, 227, 227));\n crearOrden.setFont(font);\n crearOrden.setBounds(117, 219, 140, 120);\n crearOrden.addActionListener(listener);\n getContentPane().add(crearOrden);\n\n\t\t//Boton para modificar ordenes de trabajo\n\t\tmodificarOrden = new JButton(\"MODIFICAR\");\n\t\tmodificarOrden.setForeground(SystemColor.textHighlight);\n\t\tmodificarOrden.setVerticalTextPosition(SwingConstants.BOTTOM);\n\t\tmodificarOrden.setHorizontalTextPosition(SwingConstants.CENTER);\n\t\tmodificarOrden.setIcon(new ImageIcon(GUIMenuAdmin.class.getResource(\"/images/orden_editar.png\")));\n\t\tmodificarOrden.setFocusPainted(false);\n\t\tmodificarOrden.setBorderPainted(false);\n\t\tmodificarOrden.setOpaque(true);\n\t\tmodificarOrden.setBackground(new Color(227, 227, 227));\n\t\tmodificarOrden.setFont(font);\n\t\tmodificarOrden.setBounds(267, 219, 140, 120);\n modificarOrden.addActionListener(listener);\n getContentPane().add(modificarOrden);\n\n\t\t//Boton para inicial la actualizacion de los usuarios\n\t\tconsultarOrden = new JButton(\"CONSULTAR\");\n\t\tconsultarOrden.setForeground(SystemColor.textHighlight);\n\t\tconsultarOrden.setVerticalTextPosition(SwingConstants.BOTTOM);\n\t\tconsultarOrden.setHorizontalTextPosition(SwingConstants.CENTER);\n\t\tconsultarOrden.setIcon(new ImageIcon(GUIMenuAdmin.class.getResource(\"/images/orden_buscar.png\")));\n\t\tconsultarOrden.setFocusPainted(false);\n\t\tconsultarOrden.setBorderPainted(false);\n\t\tconsultarOrden.setOpaque(true);\n\t\tconsultarOrden.setBackground(new Color(227, 227, 227));\n\t\tconsultarOrden.setFont(font);\n\t\tconsultarOrden.setBounds(417, 219, 140, 120);\n consultarOrden.addActionListener(listener);\n getContentPane().add(consultarOrden);\n\n //Boton salir\n\t\tsalir = new JButton(\"\");\n\t\tsalir.setIcon(new ImageIcon(GUIMenuAdmin.class.getResource(\"/images/salir.png\")));\n\t\tsalir.setBorderPainted(false);\n\t\tsalir.setBorder(null);\n\t\tsalir.setMargin(new Insets(0, 0, 0, 0));\n\t\tsalir.setContentAreaFilled(false);\n\t\tsalir.addActionListener(listener);\n\t\tsalir.setBounds(588, 411, 81, 59);\n\t\tgetContentPane().add(salir);\n\n\t\t//-- Eriqueta --//\n\t\tlabel_1 = new JLabel(\"ORDENES DE TRABAJO\");\n\t\tlabel_1.setForeground(SystemColor.textHighlight);\n\t\tlabel_1.setFont(font);\n\t\tlabel_1.setBounds(117, 192, 140, 14);\n\t\tgetContentPane().add(label_1);\n\n\t\t//-- Separadores --//\n\t\tseparator_1 = new JSeparator();\n\t\tseparator_1.setForeground(SystemColor.textHighlight);\n\t\tseparator_1.setBackground(new Color(255, 255, 255));\n\t\tseparator_1.setBounds(260, 199, 297, 9);\n\t\tgetContentPane().add(separator_1);\n\t\t\n\t\t//Etiqueta salir\n\t\tlblSalir = new JLabel(\"SALIR\");\n\t\tlblSalir.setHorizontalAlignment(SwingConstants.CENTER);\n\t\tlblSalir.setForeground(SystemColor.textHighlight);\n\t\tlblSalir.setFont(new Font(\"Tahoma\", Font.PLAIN, 14));\n\t\tlblSalir.setBounds(597, 391, 49, 14);\n\t\tgetContentPane().add(lblSalir);\n\t\t//Etiqueta superior azul\n\t\tJLabel fondoAzul = new JLabel(\"\");\n\t\tfondoAzul.setOpaque(true);\n\t\tfondoAzul.setBackground(new Color(45, 118, 232));// azul #2D76E8\n\t\tfondoAzul.setBounds(0, 0, 679, 120);\n\t\tgetContentPane().add(fondoAzul);\n\n\t\t//Titulo para tipo de usuario\n\t\tJLabel titulo = new JLabel(\"JEFE DE TALLER\");\n\t\ttitulo.setFont(new Font(\"Tahoma\", Font.BOLD, 16));\n\t\ttitulo.setForeground(SystemColor.textHighlight);\n\t\ttitulo.setBounds(417, 146, 140, 21);\n\t\tgetContentPane().add(titulo);\n\n\t\t\n\t\t// Etiqueta principal blanca\n\t\tJLabel fondoBlanco = new JLabel(\"\");\n\t\tfondoBlanco.setOpaque(true);\n\t\tfondoBlanco.setBackground(new Color(255, 255, 255));\n\t\tfondoBlanco.setBounds(0, 120, 679, 377);\n\t\tgetContentPane().add(fondoBlanco);\n\n\t\t//Configuraciones adicionales de la ventana principal\n\t\tsetSize(679, 497);\n\t\tsetResizable(false);\n\t\tsetVisible(true);\n\t\tsetLocationRelativeTo(null);\n\t\tsetShape(new java.awt.geom.RoundRectangle2D.Double(0, 0, getWidth(), getHeight(), 5, 5));\n\n }",
"private void createGUI() {\n ResizeGifPanel newContentPane = new ResizeGifPanel();\n newContentPane.setOpaque(true); \n setContentPane(newContentPane); \n }",
"public GUI_IntroDatos() {\n initComponents();\n }",
"private void initGui(){\n // TODO: add code for GUI initialization for a given auction\n }",
"public JavierGUI() {\r\n\t\tsuper();\r\n\t\tinitialize();\r\n\t\tthis.setJavier(getJavier());\r\n\t\tbtnHome.doClick();\r\n\t}",
"public static void createGUI() {\n\t\tSimpleGUI gui = new SimpleGUI();\n\t\tgui.setVisible(true);\n\t}",
"private void mymethods() {\n\t\tNew.addActionListener(new ActionListener()\r\n\t\t{\r\n\r\n\t\t\t@Override\r\n\t\t\tpublic void actionPerformed(ActionEvent arg0) {\r\n\t\t\t\t// TODO Auto-generated method stub\r\n\t\t\t\tta1.setText(\" \");\r\n\t\t\t}\r\n\t\t\t\r\n\t\t});\r\n\t\t\r\n\t\t\r\n\t}",
"void setGui(Gui gui);",
"public EnterDetailsGUI() {\n initComponents();\n }",
"private void initUI() {\n\t\tPanel p = new Panel();\n\t\tp.setLayout(new BorderLayout());\n\t\t\n\t\tPanel flowLayoutPanel = new Panel();\n\t\tflowLayoutPanel.setLayout(new FlowLayout());\n\t\t\n\t\ttextArea = new JTextArea();\n\t\t\n\t\tMyCloseButton exitButton = new MyCloseButton(\"Exit\");\n\t\t/*\n\t\texit.addActionListener(new ActionListener(){\n\n\t\t\t@Override\n\t\t\tpublic void actionPerformed(ActionEvent arg0) {\n\t\t\t\t// TODO Auto-generated method stub\n\t\t\t\tSystem.exit(0);\n\t\t\t}\n\t\t\t\t\t\n\t\t});\n\t\t*/\n\t\tMyOpenButton saveButton = new MyOpenButton(\"Open\");\n\t\t/*\n\t\tsaveButton.addActionListener(new ActionListener(){\n\n\t\t\t@Override\n\t\t\tpublic void actionPerformed(ActionEvent arg0) {\n\t\t\t\t// TODO Auto-generated method stub\n\t\t\t\tSystem.exit(0);\n\t\t\t}\n\t\t\n\t\t});\n\t\t*/\n\t\tMySaveButton mySaveButton =new MySaveButton(\"Save\");\n\t\t//setVisible(mb);\n\t\tp.add(flowLayoutPanel, BorderLayout.SOUTH);\n\t\tflowLayoutPanel.add(exitButton);\n\t\tflowLayoutPanel.add(saveButton);\n\t\tflowLayoutPanel.add(mySaveButton);\n\t\tp.add(textArea, BorderLayout.CENTER); \n\t\tadd(p);\n\t\t\n\t\tcreateMenu();\n\t\t\n\t\tsetTitle(\"Text Editor\");\n\t\tsetSize(600, 600);\n\t\tsetLocationRelativeTo(null);\n\t\tsetDefaultCloseOperation(EXIT_ON_CLOSE);\n\t\t\n\t}",
"Button createButton();",
"public orgGui() {\n initComponents();\n }",
"public void initGui()\n {\n Keyboard.enableRepeatEvents(true);\n this.buttons.clear();\n GuiButton guibutton = this.addButton(new GuiButton(3, this.width / 2 - 100, this.height / 4 + 24 + 12, I18n.format(\"selectWorld.edit.resetIcon\")));\n this.buttons.add(new GuiButton(4, this.width / 2 - 100, this.height / 4 + 48 + 12, I18n.format(\"selectWorld.edit.openFolder\")));\n this.buttons.add(new GuiButton(0, this.width / 2 - 100, this.height / 4 + 96 + 12, I18n.format(\"selectWorld.edit.save\")));\n this.buttons.add(new GuiButton(1, this.width / 2 - 100, this.height / 4 + 120 + 12, I18n.format(\"gui.cancel\")));\n guibutton.enabled = this.mc.getSaveLoader().getFile(this.worldId, \"icon.png\").isFile();\n ISaveFormat isaveformat = this.mc.getSaveLoader();\n WorldInfo worldinfo = isaveformat.getWorldInfo(this.worldId);\n String s = worldinfo == null ? \"\" : worldinfo.getWorldName();\n this.nameEdit = new GuiTextField(2, this.fontRenderer, this.width / 2 - 100, 60, 200, 20);\n this.nameEdit.setFocused(true);\n this.nameEdit.setText(s);\n }",
"public exerciseAddGUI() {\n initComponents();\n }",
"public abstract void initUiAndListener();",
"private void todoChooserGui() {\r\n jframe = makeFrame(\"My Todo List\", 500, 800, JFrame.EXIT_ON_CLOSE);\r\n panelSelectFile = makePanel(jframe, BorderLayout.CENTER,\r\n \"Choose a Todo\", 150, 50, 200, 25);\r\n JButton clickRetrieve = makeButton(\"retrieveTodo\", \"Retrieve A TodoList\",\r\n 175, 100, 150, 25, JComponent.CENTER_ALIGNMENT, \"cli.wav\");\r\n panelSelectFile.add(clickRetrieve);\r\n JTextField textFieldName = makeJTextField(1, 100, 150, 150, 25);\r\n textFieldName.setName(\"Name\");\r\n panelSelectFile.add(textFieldName);\r\n JButton clickNew = makeButton(\"newTodo\", \"Make New TodoList\",\r\n 250, 150, 150, 25, JComponent.CENTER_ALIGNMENT, \"cli.wav\");\r\n panelSelectFile.add(clickNew);\r\n panelSelectFile.setBackground(Color.WHITE);\r\n jframe.setBackground(Color.PINK);\r\n jframe.setVisible(true);\r\n }",
"public mainUI() {\n initComponents();\n }",
"public GUI(GUIController controler){\n\t\t//Create the fame with specific features\n\t\ttry {\n\t\t\tUIManager.setLookAndFeel(UIManager.getSystemLookAndFeelClassName());\n\t\t} catch (ClassNotFoundException e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t} catch (InstantiationException e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t} catch (IllegalAccessException e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t} catch (UnsupportedLookAndFeelException e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t}\n\t\tthis.controler=controler;\n\t\tsetFrame(new JFrame(\"Network Topology\"));\n\t\t//getFrame().setPreferredSize(new Dimension(1200, 700));\n\t\tbuttons=new ArrayList<JButton>();\n\t\tcirclePanel=new CirclePanel();\n\t\tstratButtons= new ArrayList<JButton>();\n\t\t\n\t\tgetFrame().setResizable(true);\n\t\t}",
"protected void createContents() {\n\t\tshell = new Shell();\n\t\tshell.setSize(550, 400);\n\t\tshell.setText(\"Source A Antenna 1 Data\");\n\t\t\n\t\tButton btnNewButton_1 = new Button(shell, SWT.NONE);\n\t\tbtnNewButton_1.setFont(SWTResourceManager.getFont(\"Ubuntu\", 11, SWT.BOLD));\n\t\tbtnNewButton_1.setBounds(116, 10, 98, 30);\n\t\tbtnNewButton_1.setText(\"pol 1\");\n\t\t\n\t\tButton btnPol = new Button(shell, SWT.NONE);\n\t\tbtnPol.setText(\"pol 2\");\n\t\tbtnPol.setFont(SWTResourceManager.getFont(\"Ubuntu\", 11, SWT.BOLD));\n\t\tbtnPol.setBounds(220, 10, 98, 30);\n\t\t\n\t\tButton btnPol_1 = new Button(shell, SWT.NONE);\n\t\tbtnPol_1.setText(\"pol 3\");\n\t\tbtnPol_1.setFont(SWTResourceManager.getFont(\"Ubuntu\", 11, SWT.BOLD));\n\t\tbtnPol_1.setBounds(324, 10, 98, 30);\n\t\t\n\t\tButton btnPol_2 = new Button(shell, SWT.NONE);\n\t\tbtnPol_2.setText(\"pol 4\");\n\t\tbtnPol_2.setFont(SWTResourceManager.getFont(\"Ubuntu\", 11, SWT.BOLD));\n\t\tbtnPol_2.setBounds(428, 10, 98, 30);\n\t\t\n\t\tButton button_3 = new Button(shell, SWT.NONE);\n\t\tbutton_3.addSelectionListener(new SelectionAdapter() {\n\t\t\t@Override\n\t\t\tpublic void widgetSelected(SelectionEvent arg0) {\n\t\t\t\tPlot_graph nw = new Plot_graph();\n\t\t\t\tnw.GraphScreen();\n\t\t\t}\n\t\t});\n\t\tbutton_3.setBounds(116, 46, 98, 30);\n\t\t\n\t\tButton button_4 = new Button(shell, SWT.NONE);\n\t\tbutton_4.setBounds(116, 83, 98, 30);\n\t\t\n\t\tButton button_5 = new Button(shell, SWT.NONE);\n\t\tbutton_5.setBounds(116, 119, 98, 30);\n\t\t\n\t\tButton button_6 = new Button(shell, SWT.NONE);\n\t\tbutton_6.setBounds(116, 155, 98, 30);\n\t\t\n\t\tButton button_7 = new Button(shell, SWT.NONE);\n\t\tbutton_7.setBounds(220, 155, 98, 30);\n\t\t\n\t\tButton button_8 = new Button(shell, SWT.NONE);\n\t\tbutton_8.setBounds(220, 119, 98, 30);\n\t\t\n\t\tButton button_9 = new Button(shell, SWT.NONE);\n\t\tbutton_9.setBounds(220, 83, 98, 30);\n\t\t\n\t\tButton button_10 = new Button(shell, SWT.NONE);\n\t\tbutton_10.setBounds(220, 46, 98, 30);\n\t\t\n\t\tButton button_11 = new Button(shell, SWT.NONE);\n\t\tbutton_11.setBounds(428, 155, 98, 30);\n\t\t\n\t\tButton button_12 = new Button(shell, SWT.NONE);\n\t\tbutton_12.setBounds(428, 119, 98, 30);\n\t\t\n\t\tButton button_13 = new Button(shell, SWT.NONE);\n\t\tbutton_13.setBounds(428, 83, 98, 30);\n\t\t\n\t\tButton button_14 = new Button(shell, SWT.NONE);\n\t\tbutton_14.setBounds(428, 46, 98, 30);\n\t\t\n\t\tButton button_15 = new Button(shell, SWT.NONE);\n\t\tbutton_15.setBounds(324, 46, 98, 30);\n\t\t\n\t\tButton button_16 = new Button(shell, SWT.NONE);\n\t\tbutton_16.setBounds(324, 83, 98, 30);\n\t\t\n\t\tButton button_17 = new Button(shell, SWT.NONE);\n\t\tbutton_17.setBounds(324, 119, 98, 30);\n\t\t\n\t\tButton button_18 = new Button(shell, SWT.NONE);\n\t\tbutton_18.setBounds(324, 155, 98, 30);\n\n\t}",
"public void setupGui(){\n \t\n \t w1 = (RadioButton) guiView.findViewById(R.id.w1); \t\t \n \t w2 = (RadioButton) guiView.findViewById(R.id.w2);\n \t w3 = (RadioButton) guiView.findViewById(R.id.w3);\n \t w4 = (RadioButton) guiView.findViewById(R.id.w4);\n \t pb = (Button) guiView.findViewById(R.id.paint_button);\n \t plus = (Button) guiView.findViewById(R.id.plus_button);\n \t minus = (Button) guiView.findViewById(R.id.minus_button);\n \t \n \t \n \t //model select listener\n \t lis =new View.OnClickListener(){\n \t\t \n public void onClick(View v){\n \t RadioButton b = (RadioButton)v;\n \t String tmp=b.getHint().toString();\n \t int i = Integer.parseInt(tmp);\n \t setModel(i); \n }\n };\n w1.setOnClickListener(lis);\n w2.setOnClickListener(lis);\n w3.setOnClickListener(lis);\n w4.setOnClickListener(lis);\n \n w1.setHintTextColor(Color.TRANSPARENT);\n w2.setHintTextColor(Color.TRANSPARENT);\n w3.setHintTextColor(Color.TRANSPARENT);\n w4.setHintTextColor(Color.TRANSPARENT);\n \n w1.setChecked(true);\n \n //paint button listener\n pb.setOnClickListener(new View.OnClickListener(){\n public void onClick(View v){ \t \n \t paintWheel();\t \n }\n }); \n \n //plus button listener\n plus.setOnClickListener(new View.OnClickListener(){\n public void onClick(View v){ \t \n \t scaleUp();\t \n }\n }); \n \n //minus button listener\n minus.setOnClickListener(new View.OnClickListener(){\n public void onClick(View v){ \t \n \t scaleDown();\t \n }\n }); \n }",
"public void createEvents(){\r\n\t\tbtnCurrent.addActionListener((ActionEvent e) -> JLabelDialog.run());\r\n\t}",
"private void setGUI()\r\n\t{\r\n\t\tbubblePB = setProgressBar(bubblePB);\r\n\t\tinsertionPB = setProgressBar(insertionPB);\r\n\t\tmergePB = setProgressBar(mergePB);\r\n\t\tquickPB = setProgressBar(quickPB);\r\n\t\tradixPB = setProgressBar(radixPB);\r\n\t\t\r\n\t\tsetLabels();\r\n\t\tsetPanel();\r\n\t\tsetLabels();\r\n\t\tsetFrame();\r\n\t}",
"private void makeGUI() {\r\n\t\tInstrument[] instruments = getAvailableInstruments();\r\n\r\n\t\tJPanel channels = new JPanel();\r\n\t\tchannels.setLayout(new BoxLayout(channels, BoxLayout.Y_AXIS));\r\n\r\n\t\tcomboBoxes = new JComboBox[16];\r\n\t\tfor (int chan = 0; chan < 16; chan++) {\r\n\t\t\tJPanel channelPanel = new JPanel();\r\n\t\t\tchannelPanel\r\n\t\t\t\t\t.setLayout(new BoxLayout(channelPanel, BoxLayout.X_AXIS));\r\n\t\t\tJLabel label = new JLabel(\"Channel \" + chan);\r\n\t\t\tlabel.setPreferredSize(LABEL_DIMENSION);\r\n\t\t\tchannelPanel.add(label);\r\n\t\t\tJComboBox cb = new JComboBox(instruments);\r\n\t\t\tcb.setMaximumRowCount(25);\r\n\t\t\tint program = pianoRollPanel.getProgram(chan);\r\n\t\t\tcb.setSelectedIndex(program);\r\n\t\t\tchannelPanel.add(cb);\r\n\t\t\tcomboBoxes[chan] = cb;\r\n\t\t\tchannels.add(channelPanel);\r\n\t\t}\r\n\t\tadd(channels, BorderLayout.CENTER);\r\n\t\tJPanel buttonPanel = new JPanel();\r\n\t\tJButton okButton = new JButton(OK);\r\n\t\tokButton.setActionCommand(OK);\r\n\t\tokButton.setMnemonic('O');\r\n\t\tokButton.addActionListener(this);\r\n\t\tJButton cancelButton = new JButton(CANCEL);\r\n\t\tcancelButton.setActionCommand(CANCEL);\r\n\t\tcancelButton.setMnemonic('C');\r\n\t\tcancelButton.addActionListener(this);\r\n\t\tbuttonPanel.add(okButton);\r\n\t\tbuttonPanel.add(cancelButton);\r\n\t\tadd(buttonPanel, BorderLayout.SOUTH);\r\n\t}",
"private InstructGui() {\n }",
"private void criaInterface() {\n\t\tColor azul = new Color(212, 212, 240);\n\n\t\tpainelMetadado.setLayout(null);\n\t\tpainelMetadado.setBackground(azul);\n\n\t\tmetadadoLabel = FactoryInterface.createJLabel(10, 3, 157, 30);\n\t\tpainelMetadado.add(metadadoLabel);\n\n\t\tbotaoAdicionar = FactoryInterface.createJButton(520, 3, 30, 30);\n\t\tbotaoAdicionar.setIcon(FactoryInterface.criarImageIcon(Imagem.ADICIONAR));\n\t\tbotaoAdicionar.setToolTipText(Sap.ADICIONAR.get(Sap.TERMO.get()));\n\t\tpainelMetadado.add(botaoAdicionar);\n\n\t\tbotaoEscolha = FactoryInterface.createJButton(560, 3, 30, 30);\n\t\tbotaoEscolha.setIcon(FactoryInterface.criarImageIcon(Imagem.VOLTAR_PRETO));\n\t\tbotaoEscolha.setToolTipText(Sap.ESCOLHER.get(Sap.TERMO.get()));\n\t\tbotaoEscolha.setEnabled(false);\n\t\tpainelMetadado.add(botaoEscolha);\n\n\t\talterarModo(false);\n\t\tatribuirAcoes();\n\t}",
"private void initUI() {\n }",
"public Gui() {\n\t\tsuper();\n\t\tinitGUI();\n\t}",
"private static void createAndShowGUI() {\n\n //Create and set up the window.\n JFrame frame = new JFrame(\"ButtonDemo\");\n frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);\n\n //Create and set up the content pane.\n ButtonDemo newContentPane = new ButtonDemo();\n newContentPane.setOpaque(true); //content panes must be opaque\n frame.setContentPane(newContentPane);\n\n //Display the window.\n frame.pack();\n frame.setVisible(true);\n }"
] | [
"0.7769286",
"0.7344924",
"0.72735023",
"0.7256589",
"0.7183636",
"0.7182198",
"0.71688974",
"0.71541846",
"0.7104284",
"0.7060536",
"0.7009881",
"0.69942915",
"0.6972428",
"0.6941343",
"0.69407165",
"0.69010603",
"0.69010603",
"0.68864185",
"0.68781245",
"0.6876533",
"0.6876533",
"0.68601185",
"0.6835105",
"0.6833027",
"0.6829738",
"0.68256223",
"0.68215823",
"0.6791083",
"0.6786662",
"0.6784724",
"0.6781512",
"0.6778016",
"0.67632467",
"0.6760182",
"0.6757225",
"0.67564887",
"0.67562705",
"0.6733646",
"0.6733097",
"0.6732056",
"0.6730148",
"0.6727322",
"0.6723632",
"0.67150635",
"0.6711246",
"0.6708604",
"0.6698617",
"0.6690818",
"0.66834104",
"0.66780585",
"0.66776913",
"0.6675774",
"0.6673586",
"0.66610634",
"0.6661057",
"0.66295475",
"0.66272885",
"0.66198224",
"0.66137344",
"0.6611286",
"0.66086406",
"0.66005945",
"0.65969586",
"0.657959",
"0.65792286",
"0.6576376",
"0.6563005",
"0.6560142",
"0.65525734",
"0.6552467",
"0.65523577",
"0.65503097",
"0.6539696",
"0.65380806",
"0.65264416",
"0.65244114",
"0.6524299",
"0.65235853",
"0.6519211",
"0.6516804",
"0.6515154",
"0.6512348",
"0.6510481",
"0.6509308",
"0.6495723",
"0.6480655",
"0.64780855",
"0.6476079",
"0.64669526",
"0.6464972",
"0.6464234",
"0.6464071",
"0.6461678",
"0.6457513",
"0.64575016",
"0.6453186",
"0.6448026",
"0.64435536",
"0.6432737",
"0.6432698",
"0.6430944"
] | 0.0 | -1 |
Constructor for the ButtonPanel, creates the Buttons and calls helper methods. | public ButtonPanel(CalculatorController appController)
{
super();
this.appController = appController;
numberLayout = new GridLayout(5, 4, 10, 10);
zero = new CalculatorButton(appController, "0", Color.GRAY);
one = new CalculatorButton(appController, "1", Color.GRAY);
two = new CalculatorButton(appController, "2", Color.GRAY);
three = new CalculatorButton(appController, "3", Color.GRAY);
four = new CalculatorButton(appController, "4", Color.GRAY);
five = new CalculatorButton(appController, "5", Color.GRAY);
six = new CalculatorButton(appController, "6", Color.GRAY);
seven = new CalculatorButton(appController, "7", Color.GRAY);
eight = new CalculatorButton(appController, "8", Color.GRAY);
nine = new CalculatorButton(appController, "9", Color.GRAY);
point = new CalculatorButton(appController, ".", Color.GRAY);
multiply = new CalculatorButton(appController, "x", Color.BLUE);
divide = new CalculatorButton(appController, "/", Color.BLUE);
add = new CalculatorButton(appController, "+", Color.BLUE);
subtract = new CalculatorButton(appController, "-", Color.BLUE);
ans = new CalculatorButton(appController, "Ans", new Color(0, 170, 100));
equals = new JButton();
clear = new JButton();
backspace = new JButton();
negative = new JButton();
setupPanel();
setupButtons();
setupListeners();
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public JButtonsPanel() {\r\n setBorder(BorderFactory.createEtchedBorder(Color.GREEN, new Color(148, 145, 140)));\r\n\r\n jOpen.setText(BTN_OPEN);\r\n jOpen.setToolTipText(MSG_OPEN);\r\n jOpen.setBounds(new Rectangle(BTN_LEFT, BTN_VSPACE, BTN_WIDTH, BTN_HEIGHT));\r\n add(jOpen);\r\n\r\n jCheckHealth.setText(BTN_CHECK_HEALTH);\r\n jCheckHealth.setToolTipText(MSG_CHECK_HEALTH);\r\n jCheckHealth.setBounds(new Rectangle(BTN_LEFT, (int) (jOpen.getBounds().getMaxY() + BTN_VSPACE), BTN_WIDTH, BTN_HEIGHT));\r\n add(jCheckHealth);\r\n\r\n jClose.setText(BTN_CLOSE);\r\n jClose.setToolTipText(MSG_CLOSE);\r\n jClose.setBounds(new Rectangle(BTN_LEFT, (int) (jCheckHealth.getBounds().getMaxY() + BTN_VSPACE), BTN_WIDTH, BTN_HEIGHT));\r\n add(jClose);\r\n\r\n jClaim.setText(BTN_CLAIM);\r\n jClaim.setToolTipText(MSG_CLAIM);\r\n jClaim.setBounds(new Rectangle(BTN_LEFT, (int) (jClose.getBounds().getMaxY() + BTN_VSPACE), BTN_WIDTH, BTN_HEIGHT));\r\n add(jClaim);\r\n\r\n jRelease.setText(BTN_RELEASE);\r\n jRelease.setToolTipText(MSG_RELEASE);\r\n jRelease.setBounds(new Rectangle(BTN_LEFT, (int) (jClaim.getBounds().getMaxY() + BTN_VSPACE), BTN_WIDTH, BTN_HEIGHT));\r\n add(jRelease);\r\n\r\n jDeviceEnable.setText(BTN_DEVICE_ENABLE);\r\n jDeviceEnable.setToolTipText(MSG_DEVICE_ENABLE);\r\n jDeviceEnable.setBounds(new Rectangle(BTN_LEFT, (int) (jRelease.getBounds().getMaxY() + BTN_VSPACE), BTN_WIDTH, BTN_HEIGHT));\r\n add(jDeviceEnable);\r\n\r\n jDeviceDisable.setText(BTN_DEVICE_DISABLE);\r\n jDeviceDisable.setToolTipText(MSG_DEVICE_DISABLE);\r\n jDeviceDisable.setBounds(new Rectangle(BTN_LEFT, (int) (jDeviceEnable.getBounds().getMaxY() + BTN_VSPACE), BTN_WIDTH, BTN_HEIGHT));\r\n add(jDeviceDisable);\r\n\r\n jClearData.setText(BTN_CLEAR_DATA);\r\n jClearData.setToolTipText(MSG_CLEAR_DATA);\r\n jClearData.setBounds(new Rectangle(BTN_LEFT, (int) (jDeviceDisable.getBounds().getMaxY() + BTN_VSPACE), BTN_WIDTH, BTN_HEIGHT));\r\n add(jClearData);\r\n\r\n jBeginEnrollCapture.setText(BTN_BEGIN_ENROLL_CAPTURE);\r\n jBeginEnrollCapture.setToolTipText(MSG_BEGIN_ENROLL_CAPTURE);\r\n jBeginEnrollCapture.setBounds(new Rectangle(BTN_LEFT, (int) (jClearData.getBounds().getMaxY() + BTN_VSPACE), BTN_WIDTH, BTN_HEIGHT));\r\n add(jBeginEnrollCapture);\r\n\r\n jEndCapture.setText(BTN_END_CAPTURE);\r\n jEndCapture.setToolTipText(MSG_END_CAPTURE);\r\n jEndCapture.setBounds(new Rectangle(BTN_LEFT, (int) (jBeginEnrollCapture.getBounds().getMaxY() + BTN_VSPACE), BTN_WIDTH, BTN_HEIGHT));\r\n add(jEndCapture);\r\n\r\n jBeginVerifyCapture.setText(BTN_BEGIN_VERIFY_CAPTURE);\r\n jBeginVerifyCapture.setToolTipText(MSG_BEGIN_VERIFY_CAPTURE);\r\n jBeginVerifyCapture.setBounds(new Rectangle(BTN_LEFT, (int) (jEndCapture.getBounds().getMaxY() + BTN_VSPACE), BTN_WIDTH, BTN_HEIGHT));\r\n add(jBeginVerifyCapture);\r\n\r\n jIdentifyMatch.setText(BTN_IDENTIFY_MATCH);\r\n jIdentifyMatch.setToolTipText(MSG_IDENTIFY_MATCH);\r\n jIdentifyMatch.setBounds(new Rectangle(BTN_LEFT, (int) (jBeginVerifyCapture.getBounds().getMaxY() + BTN_VSPACE), BTN_WIDTH, BTN_HEIGHT));\r\n add(jIdentifyMatch);\r\n\r\n jVerifyMatch.setText(BTN_VERIFY_MATCH);\r\n jVerifyMatch.setToolTipText(MSG_VERIFY_MATCH);\r\n jVerifyMatch.setBounds(new Rectangle(BTN_LEFT, (int) (jIdentifyMatch.getBounds().getMaxY() + BTN_VSPACE), BTN_WIDTH, BTN_HEIGHT));\r\n add(jVerifyMatch);\r\n\r\n jIdentify.setText(BTN_IDENTIFY);\r\n jIdentify.setToolTipText(MSG_IDENTIFY);\r\n jIdentify.setBounds(new Rectangle(BTN_LEFT, (int) (jVerifyMatch.getBounds().getMaxY() + BTN_VSPACE), BTN_WIDTH, BTN_HEIGHT));\r\n add(jIdentify);\r\n\r\n jVerify.setText(BTN_VERIFY);\r\n jVerify.setToolTipText(MSG_VERIFY);\r\n jVerify.setBounds(new Rectangle(BTN_LEFT, (int) (jIdentify.getBounds().getMaxY() + BTN_VSPACE), BTN_WIDTH, BTN_HEIGHT));\r\n add(jVerify);\r\n }",
"private void initPanelButtons() {\r\n\t\tthis.panelButtons = new JPanel(new GridBagLayout());\r\n\t\tthis.panelButtons.setBorder(BorderFactory.createEmptyBorder(10, 5, 0, 5));\r\n\t\tthis.panelButtons.setOpaque(false);\r\n\t\tGridBagConstraints gbc = new GridBagConstraints();\r\n\r\n\t\tgbc.gridx = 0;\r\n\t\tgbc.gridy = 0;\r\n\t\tgbc.gridwidth = 1;\r\n\t\tgbc.gridheight = 1;\r\n\t\tgbc.weightx = 1;\r\n\t\tgbc.weighty = 1;\r\n\t\tthis.returnButton.setBackground(ConstantView.COLOR_BUTTON_LOGIN);\r\n\t\tthis.returnButton.setForeground(Color.WHITE);\r\n\t\tthis.returnButton.setFocusable(false);\r\n\t\tthis.returnButton.setCursor(new Cursor(Cursor.HAND_CURSOR));\r\n\t\tthis.returnButton.setFont(ConstantView.FONT_PRINCIPAL_LABELS);\r\n\t\tthis.panelButtons.add(returnButton, gbc);\r\n\r\n\t\tgbc.gridx = 7;\r\n\t\tthis.okButton.setBackground(ConstantView.COLOR_BUTTON_LOGIN);\r\n\t\tthis.okButton.setForeground(Color.WHITE);\r\n\t\tthis.okButton.setFocusable(false);\r\n\t\tthis.okButton.setCursor(new Cursor(Cursor.HAND_CURSOR));\r\n\t\tthis.okButton.setFont(ConstantView.FONT_PRINCIPAL_LABELS);\r\n\t\tthis.okButton.addActionListener(ControlClient.getInstance());\r\n\t\tthis.okButton.setActionCommand(ClientCommands.OK_SIGN_IN.toString());\r\n\t\tthis.panelButtons.add(okButton, gbc);\r\n\t}",
"public ButtonPanel(MainPanel m) {\n\n\t\t// Send a reference to the Main Panel\n\t\t// to all of the buttons.\n\n\t\tstep = new StepButton(m);\n\t\tslow = new RunSlowButton(m);\n\t\tfast = new RunFastButton(m);\n\t\tstop = new StopButton(m);\n\t\tlower = new LowerHalfButton(m);\n\t\tupper = new UpperHalfButton(m);\n\t\trepeat = new RepeatButton(m);\n\t\tclear = new ResetButton(m);\n\t\tsetLayout(new FlowLayout());\n\n\t\t// Add all of the buttons\n\n\t\tadd(step);\n\t\tadd(slow);\n\t\tadd(fast);\n\t\tadd(stop);\n\t\tadd(lower);\n\t\tadd(upper);\n\t\tadd(repeat);\n\t\tadd(clear);\n\t}",
"private JPanel initBtnPanel() {\n\t\tconvBtn = new JButton();\n\t\tconvBtn.addActionListener(new ConversionBtnListener());\n\t\tconvBtn.setFont(new AppFont());\n\n\t\t// A button to switch the input and output scales\n\t\tswitchBtn = new JButton();\n\t\tswitchBtn.addActionListener(new SwitchListener());\n\t\tswitchBtn.setFont(new AppFont());\n\n\t\t// The panel that displays the buttons\n\t\tJPanel btnPanel = new JPanel();\n\t\tbtnPanel.setLayout(new FlowLayout());\n\t\tbtnPanel.add(convBtn);\n\t\tbtnPanel.add(switchBtn);\n\n\t\treturn btnPanel;\n\t}",
"private void initButton() {\r\n\t\tthis.panelButton = new JPanel();\r\n\t\tthis.panelButton.setLayout(new BoxLayout(this.panelButton,\r\n\t\t\t\tBoxLayout.LINE_AXIS));\r\n\t\tthis.modifyButton = new JButton(\"Modify\");\r\n\t\tthis.buttonSize(this.modifyButton);\r\n\t\tthis.deleteButton = new JButton(\"Delete\");\r\n\t\tthis.buttonSize(this.deleteButton);\r\n\t\tthis.cancelButton = new JButton(\"Cancel\");\r\n\t\tthis.buttonSize(this.cancelButton);\r\n\r\n\t\tthis.modifyButton.addActionListener(this.editWeaponControl);\r\n\t\tthis.deleteButton.addActionListener(this.editWeaponControl);\r\n\t\tthis.cancelButton.addActionListener(this.editWeaponControl);\r\n\r\n\t\tthis.panelButton.add(this.modifyButton);\r\n\t\tthis.panelButton.add(Box.createRigidArea(new Dimension(15, 0)));\r\n\t\tthis.panelButton.add(this.deleteButton);\r\n\t\tthis.panelButton.add(Box.createRigidArea(new Dimension(15, 0)));\r\n\t\tthis.panelButton.add(this.cancelButton);\r\n\t}",
"private void createButtonsPanel() {\r\n Composite buttonsPanel = new Composite(this, SWT.NONE);\r\n buttonsPanel.setLayoutData(new GridData(SWT.FILL, SWT.FILL, true, false));\r\n buttonsPanel.setLayout(new GridLayout(4, true));\r\n\r\n getButtonFromAction(buttonsPanel, \"New\", new NewAction(_window));\r\n getButtonFromAction(buttonsPanel, \"Save\", new SaveAction());\r\n getButtonFromAction(buttonsPanel, \"Delete\", new DeleteAction(_window));\r\n getButtonFromAction(buttonsPanel, \"Cancel\", new CancelAction());\r\n }",
"public ActionButtonPanel() {\n\t\tthis.setBackground(new Color(33, 162, 246));\n\t\tthis.setLayout(new FlowLayout());\n\t\t\n\t\tmoveShepherdButton = new ActionButton(new ImageIcon(Default.moveShepherdButtonUrl));\n\t\tmoveSheepButton = new ActionButton(new ImageIcon(Default.moveSheepButtonUrl));\n\t\tcoupleButton = new ActionButton(new ImageIcon(Default.coupleButtonUrl));\n\t\tcoupleSheepsButton = new ActionButton(new ImageIcon(Default.coupleSheepsButtonUrl));\n\t\tkillButton = new ActionButton(new ImageIcon(Default.killButtonUrl));\n\t\tbuyCardButton = new ActionButton(new ImageIcon(Default.buyCardButtonUrl));\n\t\t\n\t\tthis.add(moveShepherdButton);\n\t\tthis.add(moveSheepButton);\n\t\tthis.add(coupleButton);\n\t\tthis.add(coupleSheepsButton);\n\t\tthis.add(killButton);\n\t\tthis.add(buyCardButton);\n\t\t\n\t\tmoveShepherdButton.setEnabled(false);\n\t\tmoveSheepButton.setEnabled(false);\n\t\tcoupleButton.setEnabled(false);\n\t\tcoupleSheepsButton.setEnabled(false);\n\t\tkillButton.setEnabled(false);\n\t\tbuyCardButton.setEnabled(false);\n\t}",
"private void buttonPanel() {\n totalButton = new JButton(\"Calculate Total\");\r\n totalButton.setPreferredSize(new Dimension(150, 60));\r\n\r\n //add an action listener to the total.\r\n totalButton.addActionListener(new TotalButtonListener());\r\n\r\n //create a button to Submit Order.\r\n orderButton = new JButton(\"Submit Order\");\r\n orderButton.setPreferredSize(new Dimension(150, 60));\r\n orderButton.setEnabled(false);\r\n\r\n //add an action listener to the button.\r\n orderButton.addActionListener(new OrderButtonListener());\r\n\r\n //create a button to reset the checkboxes.\r\n resetButton = new JButton(\"Reset\");\r\n resetButton.setPreferredSize(new Dimension(150, 60));\r\n\r\n //add an action listener to the button.\r\n resetButton.addActionListener(new ResetButtonListener());\r\n\r\n //create a button to exit the application.\r\n exitButton = new JButton(\"Exit\");\r\n exitButton.setPreferredSize(new Dimension(150, 60));\r\n\r\n //add an action listener to the button.\r\n exitButton.addActionListener(new ExitButtonListener());\r\n\r\n //put the buttons in their own panel.\r\n buttonPanel = new JPanel();\r\n buttonPanel.setLayout(new GridLayout(1, 4));\r\n buttonPanel.add(totalButton);\r\n buttonPanel.add(orderButton);\r\n buttonPanel.add(resetButton);\r\n buttonPanel.add(exitButton);\r\n }",
"private void buildButtonPanel() // buildButtonPanel method start\n\t{\n\t\tsubmit = new JButton(\"Submit\");\n\t\treset = new JButton(\"Reset\");\n\t\t\n\t\tbuttonPanel.add(reset);\n\t\tbuttonPanel.add(submit);\n\t\t\n\t\tsubmit.addActionListener(new SubmitHandler());\n\t\treset.addActionListener(new ResetHandler());\n\t}",
"public ButtonBar() {\n scrollPane = new JScrollPane();\n scrollPane.setBorder(null);\n scrollPane.setHorizontalScrollBarPolicy(ScrollPaneConstants\n .HORIZONTAL_SCROLLBAR_NEVER);\n scrollPane.setVerticalScrollBarPolicy(ScrollPaneConstants\n .VERTICAL_SCROLLBAR_AS_NEEDED);\n scrollPane.setMinimumSize(new Dimension(0,buttonHeight\n + ((int) PlatformDefaults.getUnitValueX(\"related\").getValue()) * 2));\n \n buttons = Collections.synchronizedMap(new TreeMap<FrameContainer<?>,\n JToggleButton>(new FrameContainerComparator()));\n position = FramemanagerPosition.getPosition(\n IdentityManager.getGlobalConfig().getOption(\"ui\",\n \"framemanagerPosition\"));\n \n if (position.isHorizontal()) {\n buttonPanel = new ButtonPanel(new MigLayout(\"ins rel, fill, flowx\"),\n this);\n } else {\n buttonPanel = new ButtonPanel(new MigLayout(\"ins rel, fill, flowy\"),\n this);\n }\n scrollPane.getViewport().add(buttonPanel);\n }",
"public PlayerPanel() {\n initComponents();\n\n panel.initializeButtons(\n new javax.swing.JButton[]{addPlayerButton, editPlayerButton, deletePlayerButton},\n new javax.swing.JButton[]{cancelPlayerButton, savePlayerButton}\n );\n }",
"protected Panel createButtonPanel() {\n Panel panel = new Panel();\n panel.setLayout(new PaletteLayout(2, new Point(2,2), false));\n return panel;\n }",
"private ButtonJPanel(){\n GridLayout layout = new GridLayout(0, 1);//creates a grid layout with 1 column and unlimited rows, for the buttons\n setLayout(layout);//sets the JPanel layout\n layout.setVgap(5);//sets the vertical gap between the buttons\n setBackground(Color.WHITE);//sets the color of the panel to WHITE\n \n fillrecimg = new ImageIcon(\"src/fillrec.png\");//assigns a png image to the ImageIcon\n fillovalimg = new ImageIcon(\"src/filloval.png\");\n emptyrecimg = new ImageIcon(\"src/emptyrec.png\");\n emptyovalimg = new ImageIcon(\"src/emptyoval.png\");\n linedrawimg = new ImageIcon(\"src/linedraw.png\");\n \n clear = new JButton(\"Clear\");//initializes the buttons, either with text or an icon\n (fillrec = new JButton(fillrecimg)).setActionCommand(\"Filled Rectangle\");//icon buttons are assigned a string ActionCommand\n (filloval = new JButton(fillovalimg)).setActionCommand(\"Filled Oval\");\n (emptyrec = new JButton(emptyrecimg)).setActionCommand(\"Empty Rectangle\");\n (emptyoval = new JButton(emptyovalimg)).setActionCommand(\"Empty Oval\");\n (linedraw = new JButton(linedrawimg)).setActionCommand(\"Line Drawing\");\n opencolor = new JButton(\"Color Chooser\");\n \n JButton[] buttons = {clear, fillrec, filloval, emptyrec, emptyoval, linedraw, opencolor};//an array of all the buttons\n \n for(JButton button : buttons){//for each button...\n button.addActionListener(this);//add a listener\n add(button);//add the button to the panel\n button.setOpaque(true);//make the color visable\n button.setBackground(Color.BLACK);//set background to black\n button.setFont(new Font(Font.DIALOG, Font.PLAIN, 13));//sets the font, style, and size\n }\n }",
"private void generateButtonPanel() {\n buttonsPanel = new JPanel();\n playPauseButton = addButton(\"Play/Pause\");\n restartButton = addButton(\"Restart\");\n speedUpButton = addButton(\"Speed Up\");\n slowDownButton = addButton(\"Slow Down\");\n loopbackButton = addButton(\"Loopback\");\n keyCommandsButton = addButton(\"Key Commands\");\n textViewButton = addButton(\"Animation Text\");\n\n addShapeButton = addButton(\"Add Shape\");\n removeShapeButton = addButton(\"Remove Shape\");\n addKeyframeButton = addButton(\"Add Keyframe\");\n removeKeyframeButton = addButton(\"Remove Keyframe\");\n editKeyframeButton = addButton(\"Edit Keyframe\");\n clearAnimationButton = addButton(\"Clear Animation\");\n clearShapeButton = addButton(\"Clear Shape\");\n buttonsPanel.setLayout(new FlowLayout());\n\n mainPanel.add(buttonsPanel);\n }",
"public void initializeButtons() {\n\t\tif(null!=itemPanel)\n\t\t\tremove(itemPanel);\n\t\t\n\t\titemPanel = new JPanel();\n\t\titemPanel.setLayout(new FlowLayout());\n\t\tList<Item> allItems = itemDao.readAll();\n\t\t\n\t\t//Sort list of items based on item code.\n\t\tCollections.sort(allItems, new Comparator<Item>() {\n\t\t\t@Override\n\t\t\tpublic int compare(Item o1, Item o2) {\n\t\t\t\tCharacter c1 = o1.getCode();\n\t\t\t\tCharacter c2 = o2.getCode();\n\t\t\t\treturn c1.compareTo(c2);\n\t\t\t}\n\t\t});\n\t\t\n\t\tfor(final Item item : allItems){\n\t\t\tJButton addButton = new JButton(item.getName());\n\t\t\tDeal deal = item.getDeal();\n\t\t\tString dealName = deal == null ? \"\" : \"<br>\" + deal.getName();\n\t\t\t//Set tool tip as description and deal if available\n\t\t\taddButton.setToolTipText(\"<html>\"+item.getDescription()+\"<br>Price: $\"+item.getPrice()\n\t\t\t\t\t+ dealName+\"</html>\");\n\t\t\t//Add item to cart when pressed, also update cartLabel.\n\t\t\taddButton.addActionListener(new ActionListener() {\n\t\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\t\tcart.addItem(item.getCode());\n\t\t\t\t\tcartLabel.setText(cart.size()+ \" items in your cart\");\n\t\t\t\t}\n\t\t\t});\n\t\t\t//addButton.setBounds(10, frameHeight, 75, 20);\n\t\t\taddButton.setSize(new Dimension(75, 20));\n\t\t\titemPanel.add(addButton);\n\t\t}\n\t\t\n\t\titemPanel.setBounds(10, 30, 280, 150);\n\t\tadd(itemPanel);\n\t\tMain.getFrame().setVisible(true);;\n\t}",
"public ButtonsPanel(final List<JButton> buttons) {\n super();\n this.buttons = buttons;\n\n init();\n }",
"ButtonPanel() {\n setLayout(new GridLayout(0,3));\n setPreferredSize(new Dimension(1000,100));\n setVisible(true);\n setMaximumSize(new Dimension(1000,250));\n reservationButton = new JButton(\"Reservation View\");\n bookingButton = new JButton(\"Booking View\");\n searchButton = new JButton(\"Search View\");\n add(reservationButton);\n add(bookingButton);\n add(searchButton);\n \n }",
"private void buttonInit() {\n panel.add(createButton);\n panel.add(editButton);\n panel.add(changeButton);\n createButton.addActionListener(this);\n editButton.addActionListener(this);\n changeButton.addActionListener(this);\n submitNewUser.addActionListener(this);\n editAccTypeBtn.addActionListener(this);\n changePassBtn.addActionListener(this);\n }",
"public ButtonPanel(GameFrame gf) {\n gameFrame = gf;\n JPanel buttonPanel = new JPanel();\n setFocusable(false);\n setBackground(new Color(0x696969));\n setLayout(new FlowLayout(FlowLayout.CENTER, 100, 70));\n add(startButton());\n add(saveButton());\n add(loadButton());\n add(resetButton());\n add(exitButton());\n addListeners();\n }",
"public PizzaPalacePanel() \r\n\t{\t\t\r\n\t\tcustomer = new JButton (\"Order Form\");\r\n\t\tmanager = new JButton (\"Inventory Manger\");\r\n\t\tnewStock = new JButton (\"New Inventory\");\r\n\t\t\r\n\t\tadd (customer);\r\n\t\tadd (manager);\r\n\t\tadd (newStock);\r\n\r\n\t\tcustomer.addActionListener (buttonListener);\r\n\t\tmanager.addActionListener (buttonListener);\r\n\t\tnewStock.addActionListener (buttonListener);\r\n\t}",
"private void makeButtonPanel()\n {\n \n this.buttonPanel.setLayout(new GridLayout(10, 2, 30, 10));\n \n \n this.buttonPanel.add(this.fLabel);\n this.fName.setColumns(COL_WIDTH);\n this.buttonPanel.add(this.fName);\n\n this.buttonPanel.add(this.lLabel);\n this.lName.setColumns(COL_WIDTH);\n this.buttonPanel.add(this.lName);\n\n this.buttonPanel.add(this.idLabel);\n this.iD.setColumns(COL_WIDTH);\n this.buttonPanel.add(this.iD);\n\n this.buttonPanel.add(this.courseLabel);\n this.course.setColumns(COL_WIDTH);\n this.buttonPanel.add(this.course);\n\n this.buttonPanel.add(this.instructorLabel);\n this.instructor.setColumns(COL_WIDTH);\n this.buttonPanel.add(this.instructor);\n\n this.buttonPanel.add(this.tutorLabel);\n this.tutor.setColumns(COL_WIDTH);\n this.buttonPanel.add(this.tutor);\n \n this.buttonPanel.add(this.commentsLable);\n this.comments.setColumns(COL_WIDTH);\n this.buttonPanel.add(this.comments);\n //Removed for appointment tabel\n //this.buttonPanel.add(this.appointmentLable);\n //this.buttonPanel.add(this.appointment);\n this.buttonPanel.add(this.sessionLenLabel);\n this.sessionLength.setColumns(COL_WIDTH);\n this.sessionLength.setText(\"30\");\n this.buttonPanel.add(this.sessionLength);\n\n this.ADD_BUTTON.addActionListener(new AddButtonListener());\n //buttonPanel.add(ADD_BUTTON);\n \n \n this.addSessionPlaceHolder.add(this.buttonPanel);\n }",
"private JPanel initButtonPanel() {\n JPanel buttonPanel = new JPanel();\n buttonPanel.setLayout(new FlowLayout(SwingUtilities.HORIZONTAL));\n\n completeButton = new JButton(new AbstractAction(\"Complete\") {\n\n @Override\n public void actionPerformed(ActionEvent e) {\n task.setStatus(TaskStatus.COMPLETED);\n dialog.setVisible(false);\n }\n });\n buttonPanel.add(completeButton);\n\n closeButton = new JButton(new AbstractAction(\"Close\") {\n\n @Override\n public void actionPerformed(ActionEvent e) {\n dialog.setVisible(false);\n }\n });\n buttonPanel.add(closeButton);\n\n return buttonPanel;\n }",
"private JPanel createButtons()\r\n\t{\r\n\t\tJPanel buttons = new JPanel();\r\n\t\tbuttons.setLayout(new FlowLayout(FlowLayout.TRAILING));\r\n\r\n\r\n\t\tButton save = new Button(PrimeMain1.texts.getString(\"save\"));\r\n\t\tsave.addActionListener(this);\r\n\t\tsave.setActionCommand(\"save\");\r\n\r\n\t\tButton cancel = new Button(PrimeMain1.texts.getString(\"cancel\"));\r\n\t\tcancel.addActionListener(this);\r\n\t\tcancel.setActionCommand(\"cancel\");\r\n\r\n\r\n\t\tbuttons.add(save);\r\n\t\tbuttons.add(cancel);\r\n\r\n\t\treturn buttons;\r\n\t}",
"private void createButtonsForPanel(JPanel queueButtonPanel) {\n JButton playbutton = new JButton(\"Play\");\n JButton addsongbutton = new JButton(\"Add song\");\n playButtonActionListener(playbutton);\n addSongButtonActionListener(addsongbutton);\n queueButtonPanel.add(playbutton);\n queueButtonPanel.add(addsongbutton);\n }",
"private void setButtonPanelComponents(){\n\t\tJPanel buttonPane = new JPanel();\n\t\tbuttonPane.setPreferredSize(new Dimension(-1,32));\n\t\tbuttonPane.setBackground(Constant.DIALOG_BOX_COLOR_BG);\n\t\tbuttonPane.setLayout(new FlowLayout(FlowLayout.RIGHT));\n\t\tgetContentPane().add(buttonPane, BorderLayout.SOUTH);\n\t\t\n\t\tsaveButton = Utilities.getInstance().initializeNewButton(\n\t\t\t-1, -1, -1, -1,\n\t\t\tImages.getInstance().saveBtnDialogImg,\n\t\t\tImages.getInstance().saveBtnDialogImgHover\n\t\t);\n\t\tbuttonPane.add(saveButton);\n\t\n\n\t\n\t}",
"public ButtonPanel(ModelController c, ArrayList<Turtle> t) {\n\tsliderCurrent = 5;\n\tCONTROLLER = c;\n\tTURTLE = t;\n\tmakeUpButton();\n\tmakeDownButton();\n\tmakeLeftButton();\n }",
"protected void createButtons(Panel panel) {\n panel.add(new Filler(24,20));\n\n Choice drawingChoice = new Choice();\n drawingChoice.addItem(fgUntitled);\n\n\t String param = getParameter(\"DRAWINGS\");\n\t if (param == null)\n\t param = \"\";\n \tStringTokenizer st = new StringTokenizer(param);\n while (st.hasMoreTokens())\n drawingChoice.addItem(st.nextToken());\n // offer choice only if more than one\n if (drawingChoice.getItemCount() > 1)\n panel.add(drawingChoice);\n else\n panel.add(new Label(fgUntitled));\n\n\t\tdrawingChoice.addItemListener(\n\t\t new ItemListener() {\n\t\t public void itemStateChanged(ItemEvent e) {\n\t\t if (e.getStateChange() == ItemEvent.SELECTED) {\n\t\t loadDrawing((String)e.getItem());\n\t\t }\n\t\t }\n\t\t }\n\t\t);\n\n panel.add(new Filler(6,20));\n\n Button button;\n button = new CommandButton(new DeleteCommand(\"Delete\", fView));\n panel.add(button);\n\n button = new CommandButton(new DuplicateCommand(\"Duplicate\", fView));\n panel.add(button);\n\n button = new CommandButton(new GroupCommand(\"Group\", fView));\n panel.add(button);\n\n button = new CommandButton(new UngroupCommand(\"Ungroup\", fView));\n panel.add(button);\n\n button = new Button(\"Help\");\n\t\tbutton.addActionListener(\n\t\t new ActionListener() {\n\t\t public void actionPerformed(ActionEvent event) {\n\t\t showHelp();\n\t\t }\n\t\t }\n\t\t);\n panel.add(button);\n\n fUpdateButton = new Button(\"Simple Update\");\n\t\tfUpdateButton.addActionListener(\n\t\t new ActionListener() {\n\t\t public void actionPerformed(ActionEvent event) {\n if (fSimpleUpdate)\n setBufferedDisplayUpdate();\n else\n setSimpleDisplayUpdate();\n\t\t }\n\t\t }\n\t\t);\n\n // panel.add(fUpdateButton); // not shown currently\n }",
"private void constructButtonPanel() {\n //boolean manualAdvance = true;\n \n buttonPanel = new JPanel();\n buttonPanel.setBorder(BorderFactory.createTitledBorder(\"Admin Actions\"));\n buttonPanel.setLayout(new GridLayout(2, 2, 20, 15));\n \n JPanel startExpPanel = new JPanel();\n startExpButton = new JButton(\"Start Experiment\");\n startExpButton.setEnabled(false);\n startExpButton.addActionListener(new ActionListener() {\n public void actionPerformed(ActionEvent evt) {\n if (allConnected || JOptionPane.showConfirmDialog(null, \"<html>Start the game even though all clients are not yet connected?</html>\", \"Premature Start\", JOptionPane.YES_NO_OPTION) == JOptionPane.YES_OPTION)\n startExperiment();\n }\n });\n startExpPanel.add(startExpButton);\n \n JPanel startPeriodPanel = new JPanel();\n startPeriodButton = new JButton(\"Start Period\");\n startPeriodButton.setEnabled(false);\n startPeriodPanel.add(startPeriodButton);\n startPeriodButton.addActionListener(new ActionListener() {\n public void actionPerformed(ActionEvent evt) {\n if (JOptionPane.showConfirmDialog(null, \"<html>Start this period?</html>\", \"Confirm Exit\", JOptionPane.YES_NO_OPTION) == JOptionPane.YES_OPTION)\n startPeriod();\n }\n });\n \n JPanel switchButtonPanel = new JPanel();\n switchButton = new JButton(autoSwitchString);\n switchButton.setEnabled(true);\n switchButtonPanel.add(switchButton);\n switchButton.addActionListener(new ActionListener() {\n public void actionPerformed(ActionEvent evt) {\n manualAdvance = !manualAdvance;\n setSwitchStatus();\n }\n });\n \n JPanel stopExpPanel = new JPanel();\n stopExpButton = new JButton(\"Stop Experiment\");\n stopExpButton.addActionListener(new ActionListener() {\n public void actionPerformed(ActionEvent evt) {\n if (JOptionPane.showConfirmDialog(null, \"<html>Terminate the current experiment?<br>(This will exit this interface)</html>\", \"Confirm Exit\", JOptionPane.YES_NO_OPTION) == JOptionPane.YES_OPTION)\n stopExperiment();\n }\n });\n stopExpButton.setEnabled(false);\n stopExpPanel.add(stopExpButton);\n \n buttonPanel.add(startExpPanel);\n buttonPanel.add(startPeriodPanel);\n buttonPanel.add(stopExpPanel);\n buttonPanel.add(switchButtonPanel);\n \n buttonPanel.setPreferredSize(relativeSize(0.25f, 0.15f));\n }",
"private void initializeButtonPanel() {\n buttonPanel = new ButtonPanel();\n radioPanel = new JPanel(new GridLayout(0, 1));\n ButtonGroup buttonGroup = new ButtonGroup();\n Collections.addAll(toDoButtonList,task1,task2,task3,task4,task5,task6);\n for (int i=0;i<toDoButtonList.size();i++){\n JRadioButton task = toDoButtonList.get(i);\n buttonGroup.add(task);\n radioPanel.add(task);\n }\n\n refresh();\n\n }",
"public Button(){\n id=1+nbrButton++;\n setBounds(((id-1)*getDimX())/(Data.getNbrLevelAviable()+1),((id-1)*getDimY())/(Data.getNbrLevelAviable()+1),getDimX()/(2*Data.getNbrLevelAviable()),getDimY()/(2*Data.getNbrLevelAviable()));\n setText(id+\"\");\n setFont(Data.getFont());\n addMouseListener(this);\n setVisible(true);\n }",
"private void buttonsPanel(JPanel panel_buttons) {\n\t\t//BUTTON COMPONENETS\n\t\tJButton btnDraw = new JButton(\"DRAW\");\n\t\tbtnDraw.setMinimumSize(new Dimension(81, 34));\n\t\tbtnDraw.setMaximumSize(new Dimension(81, 34));\n\t\tbtnDraw.setOpaque(true);\n\t\tbtnDraw.setBorderPainted(false);\n\t\tbtnDraw.setHideActionText(true);\n\t\tbtnDraw.setCursor(Cursor.getPredefinedCursor(Cursor.DEFAULT_CURSOR));\n\t\tbtnDraw.setSelected(true);\n\t\tbtnDraw.setRequestFocusEnabled(false);\n\t\tbtnDraw.addActionListener(new ActionListener() {\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t}\n\t\t});\n\t\tbtnDraw.setFont(UIManager.getFont(\"ColorChooser.font.green\"));\n\t\tbtnDraw.setBackground(Color.BLACK);\n\t\tbtnDraw.setForeground(Color.GREEN);\n\t\tbtnDraw.setFont(UIManager.getFont(\"ColorChooser.font.green\"));\n\t\t\n\t\tJButton btnReset = new JButton(\"RESET\");\n\t\tbtnReset.setForeground(Color.RED);\n\t\tbtnReset.setFont(UIManager.getFont(\"Button.font\"));\n\t\tbtnReset.setBorder(null);\n\t\tbtnReset.setOpaque(true);\n\t\tbtnReset.setBackground(Color.BLACK);\n\t\tbtnReset.setName(\"\");\n\t\t\n\t\tJButton btnQuit = new JButton(\"QUIT\");\n\t\tbtnQuit.setMaximumSize(new Dimension(81, 29));\n\t\tbtnQuit.setMinimumSize(new Dimension(81, 29));\n\t\tbtnQuit.setOpaque(true);\n\t\tbtnQuit.setBackground(Color.BLACK);\n\t\tbtnQuit.setBorderPainted(false);\n\t\tbtnQuit.setForeground(Color.WHITE);\n\t\tbtnQuit.setFont(UIManager.getFont(\"ColorChooser.font\"));\n\t\tbtnQuit.addActionListener(new ActionListener() {\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t}\n\t\t});\n\t\t\n\t\t\n\t\t//PANEL LAYOUT FOR BUTTONS\n\t\tGroupLayout gl_panel_Buttons = new GroupLayout(panel_buttons);\n\t\tgl_panel_Buttons.setHorizontalGroup(\n\t\t\tgl_panel_Buttons.createParallelGroup(Alignment.TRAILING)\n\t\t\t\t.addComponent(btnReset, Alignment.LEADING, GroupLayout.DEFAULT_SIZE, 106, Short.MAX_VALUE)\n\t\t\t\t.addComponent(btnQuit, Alignment.LEADING, GroupLayout.DEFAULT_SIZE, 106, Short.MAX_VALUE)\n\t\t\t\t.addComponent(btnDraw, Alignment.LEADING, GroupLayout.DEFAULT_SIZE, 106, Short.MAX_VALUE)\n\t\t);\n\t\tgl_panel_Buttons.setVerticalGroup(\n\t\t\tgl_panel_Buttons.createParallelGroup(Alignment.LEADING)\n\t\t\t\t.addGroup(gl_panel_Buttons.createSequentialGroup()\n\t\t\t\t\t.addComponent(btnDraw, GroupLayout.PREFERRED_SIZE, 78, GroupLayout.PREFERRED_SIZE)\n\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t.addComponent(btnReset, GroupLayout.DEFAULT_SIZE, 81, Short.MAX_VALUE)\n\t\t\t\t\t.addPreferredGap(ComponentPlacement.RELATED)\n\t\t\t\t\t.addComponent(btnQuit, GroupLayout.PREFERRED_SIZE, 80, GroupLayout.PREFERRED_SIZE))\n\t\t);\n\t\tpanel_buttons.setLayout(gl_panel_Buttons);\n\t}",
"protected JBPanel getButtonsPanel() {\n return buttonsPanel;\n }",
"private Component getButtonPanel() {\r\n\r\n logger.entering(this.getClass().getName(), \"getButtonPanel\");\r\n\r\n JButton btnOK = new JButton(\"OK\");\r\n\r\n btnOK.addActionListener(new ActionListener() {\r\n\r\n public void actionPerformed(@SuppressWarnings(\"unused\")\r\n final ActionEvent e) {\r\n updateMsdtFilterMap();\r\n\t\t\t\tclosePanel();\r\n }\r\n });\r\n\r\n JButton btnApply = new JButton(\"Apply\");\r\n\r\n btnApply.addActionListener(new ActionListener() {\r\n\r\n public void actionPerformed(@SuppressWarnings(\"unused\")\r\n final ActionEvent e) {\r\n updateMsdtFilterMap();\r\n }\r\n });\r\n\r\n JButton btnCancel = new JButton(\"Cancel\");\r\n\r\n btnCancel.addActionListener(new ActionListener() {\r\n\r\n public void actionPerformed(@SuppressWarnings(\"unused\")\r\n final ActionEvent e) {\r\n\t\t\t\tclosePanel();\r\n }\r\n });\r\n\r\n JButton btnClearAll = new JButton(\"Clear all\");\r\n\r\n btnClearAll.addActionListener(new ActionListener() {\r\n\r\n @SuppressWarnings( {\"synthetic-access\", \"unqualified-field-access\"})\r\n public void actionPerformed(@SuppressWarnings(\"unused\")\r\n final ActionEvent e) {\r\n for (JCheckBox chkMsdt : chkMsdtSelection.values()) {\r\n chkMsdt.setSelected(false);\r\n }\r\n\r\n }\r\n });\r\n\r\n JButton btnRestore = new JButton(\"Restore\");\r\n\r\n btnRestore.addActionListener(new ActionListener() {\r\n\r\n public void actionPerformed(@SuppressWarnings(\"unused\")\r\n final ActionEvent e) {\r\n refreshCheckBoxes();\r\n\r\n }\r\n\r\n });\r\n\r\n JPanel pnlButtons = new JPanel();\r\n\r\n pnlButtons.add(btnRestore);\r\n\r\n pnlButtons.add(btnClearAll);\r\n\r\n pnlButtons.add(btnCancel);\r\n\r\n pnlButtons.add(btnApply);\r\n\r\n\t\tpnlButtons.add(btnOK);\r\n\r\n logger.exiting(this.getClass().getName(), \"getButtonPanel\", pnlButtons);\r\n\r\n return pnlButtons;\r\n }",
"public LinkButton() {\n\t\tsuper();\n\t\tinit();\n\t}",
"@AutoGenerated\r\n\tprivate HorizontalLayout buildButtonsLayout()\r\n\t{\n\t\tbuttonsLayout = new HorizontalLayout();\r\n\t\tbuttonsLayout.setImmediate(false);\r\n\t\tbuttonsLayout.setWidth(\"-1px\");\r\n\t\tbuttonsLayout.setHeight(\"-1px\");\r\n\t\tbuttonsLayout.setMargin(false);\r\n\t\tbuttonsLayout.setSpacing(true);\r\n\t\t\r\n\t\t// addButton\r\n\t\taddButton = new Button();\r\n\t\taddButton.setCaption(\"Add...\");\r\n\t\taddButton.setImmediate(true);\r\n\t\taddButton.setWidth(\"100px\");\r\n\t\taddButton.setHeight(\"-1px\");\r\n\t\tbuttonsLayout.addComponent(addButton);\r\n\t\t\r\n\t\t// editButton\r\n\t\teditButton = new Button();\r\n\t\teditButton.setCaption(\"Edit...\");\r\n\t\teditButton.setImmediate(true);\r\n\t\teditButton.setWidth(\"100px\");\r\n\t\teditButton.setHeight(\"-1px\");\r\n\t\tbuttonsLayout.addComponent(editButton);\r\n\t\t\r\n\t\t// deleteButton\r\n\t\tdeleteButton = new Button();\r\n\t\tdeleteButton.setCaption(\"Delete...\");\r\n\t\tdeleteButton.setImmediate(true);\r\n\t\tdeleteButton.setWidth(\"100px\");\r\n\t\tdeleteButton.setHeight(\"-1px\");\r\n\t\tbuttonsLayout.addComponent(deleteButton);\r\n\t\t\r\n\t\treturn buttonsLayout;\r\n\t}",
"public void createButtons() {\n\t\tbutton1 = new JButton(\"Button1\");\n\t\tbutton2 = new JButton(\"Button2\");\n\t\tbutton3 = new JButton(\"Button3\");\n\t\tbutton4 = new JButton(\"Button4\");\n\t\tbutton5 = new JButton(\"Button5\");\n\t}",
"@Override\n\tprotected void createCompButtons() {\n\t\tbuildCompButtons();\n\t}",
"public ButtonPanel(SnakeFrame snakeFrame) {\n\t\tthis.snakeFrame =snakeFrame;\n\t\t//初始化面板信息\n\t\tinitPanel();\n\t\t//初始化组件信息\n\t\tinitComponents();\n\t\t//添加组件\n\t\taddComponents();\n\t}",
"public ButtonMenuPanelBuyer() {\n initComponents();\n }",
"public void init()\n {\n Container screen = getContentPane();\n buttonPanel.setLayout(new BoxLayout(buttonPanel, BoxLayout.Y_AXIS));\n buttonPanel.add(attackButton);\n attackButton.setBackground(Color.WHITE);\n buttonPanel.add(defendButton);\n buttonPanel.add(fireButton);\n buttonPanel.add(iceButton);\n buttonPanel.add(hPotionButton);\n buttonPanel.add(mPotionButton);\n attackButton.addActionListener(this);\n defendButton.addActionListener(this);\n hPotionButton.addActionListener(this);\n mPotionButton.addActionListener(this);\n fireButton.addActionListener(this);\n iceButton.addActionListener(this);\n offScreen = new BufferedImage(500,500, BufferedImage.TYPE_INT_RGB);\n add(buttonPanel, BorderLayout.EAST);\n }",
"private void createButton() {\n\t\tbtnAddTask = new JButton(\"Add Task\");\n\t\tbtnSave = new JButton(\"Save\");\n\t\tbtnCancel = new JButton(\"Cancel\");\n\n\t\tbtnAddTask.addActionListener(new ToDoAction());\n\t\tbtnSave.addActionListener(new ToDoAction());\n\t\tbtnCancel.addActionListener(new ToDoAction());\n\t}",
"private JPanel createButtonPanel(){\n JPanel buttonPanel = new JPanel();\n buttonPanel.setLayout(new BoxLayout(buttonPanel, BoxLayout.X_AXIS));\n buttonPanel.setBorder(BorderFactory.createEmptyBorder(VERTICAL_BUFFER,HORIZONTAL_BUFFER,0,HORIZONTAL_BUFFER));\n\n export = new JButton(\"Export\");\n cancel = new JButton(\"Cancel\");\n\n buttonPanel.add(Box.createHorizontalGlue());\n buttonPanel.add(export);\n buttonPanel.add(Box.createHorizontalStrut(HORIZONTAL_BUFFER));\n buttonPanel.add(cancel);\n buttonPanel.add(Box.createHorizontalGlue());\n\n return buttonPanel;\n }",
"private void setupButtonPanel() {\n\n Dimension btnSize = new Dimension(100, 50);\n\n exitButton = new JButton(\"Exit\");\n playAgainButton = new JButton(\"Play Again\");\n\n exitButton.setPreferredSize(btnSize);\n playAgainButton.setPreferredSize(btnSize);\n\n buttonPanel.add(playAgainButton);\n buttonPanel.add(exitButton);\n fullPanel.add(buttonPanel, BorderLayout.SOUTH);\n\n playAgainButton.addActionListener(actionEvent -> {\n GameOver.this.dispose();\n new MainScreen();\n });\n exitButton.addActionListener(actionEvent -> System.exit(0));\n }",
"private JComponent getButtonPanel() {\n JPanel buttonPanel = new JPanel();\n // Open\n OpenAction openAction = new OpenAction();\n buttonPanel.add(new JButton(openAction));\n // Save\n SaveAction saveAction = new SaveAction();\n buttonPanel.add(new JButton(saveAction));\n // Save as\n SaveAsAction saveAsAction = new SaveAsAction(saveAction);\n buttonPanel.add(new JButton(saveAsAction));\n return buttonPanel;\n }",
"public BuildingsPanel() {\n \n player = Player.getInstance();\n buttons = new JButton[8];\n structureData = new Building[10];\n \n initComponents();\n init();\n }",
"public Box getButtonPanel() {\n\t\tBox buttonsPanel = new Box(BoxLayout.Y_AXIS);\n\t\tbuttonsPanel.setAlignmentX(Component.CENTER_ALIGNMENT);\n\n\t\tBox treeBox = new Box(BoxLayout.Y_AXIS);\n\t\ttreeBox.setBorder(new TitledBorder(\"Schema\"));\n\n\t\tBox associationBox = new Box(BoxLayout.Y_AXIS);\n\t\tassociationBox.setBorder(new TitledBorder(\"Association\"));\n\n\t\tBox outputBox = new Box(BoxLayout.Y_AXIS);\n\t\toutputBox.setBorder(new TitledBorder(\"Output\"));\n\n\t\tBox numerotationBox = new Box(BoxLayout.X_AXIS);\n\t\tnumerotationBox.setBorder(new TitledBorder(\"Numerotation\"));\n\t\t/* add a button for loading a XML Schema */\n\t\tJButton loadFileb = new JButton(\"Open schema\");\n\t\tUtils.setDefaultSize(loadFileb);\n\t\tloadFileb.addActionListener(new LoadSchemaListener());\n\n\t\t/*\n\t\t * add a button for associating the content of a node to a line in the\n\t\t * flat file\n\t\t */\n\t\tJButton selectLineNodeb = new JButton(\"Main node\");\n\t\tUtils.setDefaultSize(selectLineNodeb);\n\t\tselectLineNodeb.addActionListener(new SelectLineNodeListener());\n\n\t\tJButton selectNodeb = new JButton(\"Select\");\n\t\tUtils.setDefaultSize(selectNodeb);\n\t\tselectNodeb.addActionListener(new SelectNodeListener());\n\n\t\tJButton unselectNodeb = new JButton(\"Unselect\");\n\t\tUtils.setDefaultSize(unselectNodeb);\n\t\tunselectNodeb.addActionListener(new UnselectNodeListener());\n\n\t\tJButton nameb = new JButton(\"Name\");\n\t\tUtils.setDefaultSize(nameb);\n\t\tnameb.addActionListener(new associateNameListener());\n\n\t\tJButton filterb = new JButton(\"Filter\");\n\t\tUtils.setDefaultSize(filterb);\n\t\tfilterb.addActionListener(new AssociateFilterListener());\n\n\t\tJButton infosb = new JButton(\"About\");\n\t\tUtils.setDefaultSize(infosb);\n\t\tinfosb.addActionListener(new InfosListener());\n\n\t\tassociationBox.add(selectNodeb);\n\t\tassociationBox.add(unselectNodeb);\n\t\tassociationBox.add(nameb);\n\t\tassociationBox.add(filterb);\n\t\tfilter = new JLabel(\"no filter\");\n\t\tassociationBox.add(filter);\n\n\t\ttreeBox.add(loadFileb);\n\n\t\tassociationBox.add(infosb);\n\n\t\tJButton loadXmlFileb = new JButton(\"Open document (XML)\");\n\t\tUtils.setDefaultSize(loadXmlFileb);\n\t\tloadXmlFileb.addActionListener(new LoadDocumentListener());\n\n\t\tJButton setSeparatorb = new JButton(\"Separator\");\n\t\tUtils.setDefaultSize(setSeparatorb);\n\t\tsetSeparatorb.addActionListener(new SetSeparatorListener());\n\n\t\tJButton printTabFileb = new JButton(\"Print\");\n\t\tUtils.setDefaultSize(printTabFileb);\n\t\tprintTabFileb.addActionListener(new PrintFlatFileListener());\n\n\t\ttreeBox.add(loadXmlFileb);\n\t\ttreeBox.add(selectLineNodeb);\n\n\t\toutputBox.add(setSeparatorb);\n\t\toutputBox.add(printTabFileb);\n\n\t\tnumerotationButtons = new ButtonGroup();\n\n\t\tnumericb = new JRadioButton(\"1\");\n\t\thighAlphabeticb = new JRadioButton(\"A\");\n\t\tlowAlphabeticb = new JRadioButton(\"a\");\n\t\tnoneb = new JRadioButton(\"none\");\n\n\t\tnumericb.addActionListener(new NumerotationListener());\n\t\thighAlphabeticb.addActionListener(new NumerotationListener());\n\t\tlowAlphabeticb.addActionListener(new NumerotationListener());\n\t\tnumerotationBox.setAlignmentX(Component.LEFT_ALIGNMENT);\n\t\tnumerotationButtons.add(numericb);\n\t\tnumerotationButtons.add(highAlphabeticb);\n\t\tnumerotationButtons.add(lowAlphabeticb);\n\t\tnumerotationButtons.add(noneb);\n\n\t\tswitch (((XsdTreeStructImpl) xsdTree).numerotation_type) {\n\t\tcase XsdTreeStructImpl.HIGH_ALPHABETIC_NUMEROTATION:\n\t\t\thighAlphabeticb.setSelected(true);\n\t\t\tbreak;\n\t\tcase XsdTreeStructImpl.LOW_ALPHABETIC_NUMEROTATION:\n\t\t\tlowAlphabeticb.setSelected(true);\n\t\t\tbreak;\n\t\tcase XsdTreeStructImpl.NUMERIC_NUMEROTATION:\n\t\t\tnumericb.setSelected(true);\n\t\t\tbreak;\n\t\tdefault:\n\t\t\tnoneb.setSelected(true);\n\t\t\tbreak;\n\t\t}\n\n\t\tnumerotationBox.add(numericb);\n\t\tnumerotationBox.add(highAlphabeticb);\n\t\tnumerotationBox.add(lowAlphabeticb);\n\t\tnumerotationBox.add(noneb);\n\n\t\tbuttonsPanel.add(treeBox);\n\t\tbuttonsPanel.add(associationBox);\n\t\tbuttonsPanel.add(outputBox);\n\t\tbuttonsPanel.add(numerotationBox);\n\n\t\tdisplayExample = new JCheckBox(\"preview\");\n\t\tbuttonsPanel.add(displayExample);\n\t\tdisplayExample.addActionListener(new PreviewListener());\n\t\t\n\t\treturn buttonsPanel;\n\t}",
"private ButtonPane()\r\n\t\t\t{ super(new String[]{\"OK\",\"Cancel\"},1,2); }",
"private void createUIComponents() {\n bt1 = new JButton(\"Hola\");\n }",
"public abstract void initButton(int buttonIndex);",
"public ButtonHolderActionBarView(SpeelveldController speelveldController)\n throws RemoteException {\n this.speelveldController = speelveldController;\n this.speler = speelveldController.getSpeler();\n this.karakter = this.speler.getKarakter();\n\n container = new StackPane();\n gebruikEigenschap = new Button();\n exitbutton = new Button();\n spelregels = new Button();\n opslaanknop = new Button();\n goudbutton = new Button();\n bouwbutton = new Button();\n eindebeurtbutton = new Button();\n\n this.speler.addObserver(this);\n this.karakter.addObserver(this);\n\n this.buttonGrid.setHgap(10);\n this.buttonGrid.setVgap(10);\n this.buttonGrid.setPadding(new Insets(22.5, 0, 22.5, 0));\n\n initButton(gebruikEigenschap, \"Eigenschap\", \"button-primary\", 1, 1, 160f, 55f);\n initButton(bouwbutton, \"Bouwen\", \"button-primary\", 2, 1, 160f, 55f);\n initButton(goudbutton, \"Bonusgoud\", \"button-primary\", 1, 2, 160f, 55f);\n initButton(eindebeurtbutton, \"Einde beurt\", \"button-danger\", 2, 2, 160f, 55f);\n initButton(opslaanknop, \"Opslaan\", \"button-success\", 1, 3, 160f, 55f);\n initButton(exitbutton, \"Afsluiten\", \"button-danger\", 2, 3, 160f, 55f);\n\n opslaanknop.setOnAction(event1 -> this.speelveldController.cmdOpslaan());\n goudbutton.setOnAction(event -> this.speelveldController.cmdBonusGoud());\n bouwbutton.setOnAction(event -> this.speelveldController.cmdBouwGebouw());\n eindebeurtbutton.setOnAction(event -> this.speelveldController.cmdEindeBeurt());\n gebruikEigenschap.setOnAction(event -> this.speelveldController.cmdGebruikEigenschap());\n exitbutton.setOnAction(event -> System.exit(0));\n\n isKarakterBonusable();\n\n buttonholder = new Rectangle(0, 0, 350, 250);\n buttonholder.setFill(Color.rgb(57, 57, 57));\n this.container.getChildren().addAll(buttonholder, buttonGrid);\n }",
"public FlowPanel(){\r\n setLayout(new FlowLayout());\r\n setBackground(Color.green);\r\n JButton b1 = new JButton(\"Button 1\");\r\n JButton b2 = new JButton(\"Button 2\");\r\n JButton b3 = new JButton(\"Button 3\");\r\n JButton b4 = new JButton(\"Button 4\");\r\n JButton b5 = new JButton(\"Button 5\");\r\n add(b1);\r\n add(b2);\r\n add(b3);\r\n add(b4);\r\n add(b5);\r\n }",
"private void buttonInit(){\n for(int i=0; i < 3; i++){\n choice[i] = new JButton();\n\n }\n choice[0].setText(\"10x10 / 8 bombs\");\n choice[0].setBackground(new Color(86, 160, 189));\n\n\n choice[0].addActionListener(l-> makeGamePanel(10, 8));\n\n choice[1].setText(\"15x15 / 30 bombs\");\n choice[1].setBackground(new Color(238, 160, 160));\n\n\n choice[1].addActionListener(l-> makeGamePanel(15,30));\n\n choice[2].setText(\"24x24 / 70 bombs\");\n choice[2].setBackground(new Color(253, 230, 122));\n choice[2].setFont(new Font(Font.MONOSPACED, Font.BOLD, 30));\n choice[2].setForeground(new Color(45, 68, 73));\n\n choice[2].addActionListener(l-> makeGamePanel(24,70));\n\n this.add(choice[0], BorderLayout.LINE_START); this.add(choice[1], BorderLayout.LINE_END); this.add(choice[2], BorderLayout.CENTER);\n }",
"public TranslateButton() {\n this.posX = 0;\n this.posY = 0;\n this.width = 0;\n this.height = 0;\n translateButton = new JButton();\n }",
"public TicTacToePanel()\n {\n //Construct a JPanel\n super();\n \n GridLayout layout;\n \n //Make a 3x3 View\n layout = new GridLayout(3,3);\n layout.setHgap(0);\n layout.setVgap(0);\n \n //Initialize the button array\n ticTacToeButtons = new JButton[9];\n \n //Put everything together\n this.setLayout(layout);\n \n for(int i = 0; i < ticTacToeButtons.length; i++)\n {\n //Initialize Button\n ticTacToeButtons[i] = new JButton();\n \n //Now the loop can work like a for-each\n JButton myButton = ticTacToeButtons[i];\n \n //Setup the button\n myButton.setContentAreaFilled(false);\n this.add(myButton);\n }\n \n validate();\n repaint();\n }",
"@AutoGenerated\n\tprivate HorizontalLayout buildLayoutButtons() {\n\t\tlayoutButtons = new HorizontalLayout();\n\t\tlayoutButtons.setImmediate(false);\n\t\tlayoutButtons.setWidth(\"-1px\");\n\t\tlayoutButtons.setHeight(\"-1px\");\n\t\tlayoutButtons.setMargin(false);\n\t\t\n\t\t// btnSave\n\t\tbtnSave = new Button();\n\t\tbtnSave.setCaption(\"Salvar\");\n\t\tbtnSave.setImmediate(true);\n\t\tbtnSave.setWidth(\"-1px\");\n\t\tbtnSave.setHeight(\"-1px\");\n\t\tlayoutButtons.addComponent(btnSave);\n\t\t\n\t\t// btnCancel\n\t\tbtnCancel = new Button();\n\t\tbtnCancel.setCaption(\"Cancelar\");\n\t\tbtnCancel.setImmediate(true);\n\t\tbtnCancel.setWidth(\"-1px\");\n\t\tbtnCancel.setHeight(\"-1px\");\n\t\tlayoutButtons.addComponent(btnCancel);\n\t\t\n\t\treturn layoutButtons;\n\t}",
"private void createButtons() {\n Button helpSettingsButton = new Button(\"\",\n new Button.ClickListener() {\n private static final long serialVersionUID = -5797923866320649518L;\n\n @Override\n public void buttonClick(ClickEvent event) {\n settingsPresenter.navigateToHelp();\n }\n });\n\n// Button skillSettingsButton = new Button(\"\",\n// new Button.ClickListener() {\n// private static final long serialVersionUID = 7147554466396214893L;\n//\n// @Override\n// public void buttonClick(ClickEvent event) {\n// settingsPresenter.navigateToSkills();\n// }\n// });\n// skillSettingsButton.addStyleName(\"icon-cog\");\n\n Button medicSettingsButton = new Button(\"\",\n new Button.ClickListener() {\n private static final long serialVersionUID = 7147554466396214893L;\n\n @Override\n public void buttonClick(ClickEvent event) {\n settingsPresenter.navigateToMedic();\n }\n });\n\n\n Button logoutButton = new Button(\"\",\n new Button.ClickListener() {\n private static final long serialVersionUID = -1096188732209266611L;\n\n @Override\n public void buttonClick(ClickEvent event) {\n settingsPresenter.navigateBack();\n }\n });\n logoutButton.addStyleName(\"default\");\n\n // Adding and aligning the 3 Buttons.\n //Setting a Description for the buttons which is displayed when flying over the button\n super.verticalNavigation.addComponent(helpSettingsButton);\n super.verticalNavigation.setComponentAlignment(helpSettingsButton, Alignment.MIDDLE_CENTER);\n helpSettingsButton.setDescription(\"Set the Help options for the Patient\");\n helpSettingsButton.setIcon(new ThemeResource(\"img/contacgg.png\"), BUTTON_HELP_SETTINGS);\n helpSettingsButton.setWidth(BUTTON_WIDTH);\n helpSettingsButton.setHeight(BUTTON_HEIGHT);\n\n super.verticalNavigation.addComponent(medicSettingsButton);\n super.verticalNavigation.setComponentAlignment(medicSettingsButton, Alignment.MIDDLE_CENTER);\n medicSettingsButton.setDescription(\"Set the Medication options for the Patient\");\n medicSettingsButton.setIcon(new ThemeResource(\"img/medicine-icon-cog.png\"),BUTTON_MEDIC_SETTINGS);\n medicSettingsButton.setWidth(BUTTON_WIDTH);\n medicSettingsButton.setHeight(BUTTON_HEIGHT);\n\n// addComponent(skillSettingsButton);\n// setComponentAlignment(skillSettingsButton, Alignment.MIDDLE_CENTER);\n// skillSettingsButton.setDescription(\"Set the Skill options for the Patient\");\n// skillSettingsButton.setIcon(new ThemeResource(\"img/skill2-icon-cog.png\"), BUTTON_SKILL_SETTINGS);\n// skillSettingsButton.setWidth(BUTTON_WIDTH);\n// skillSettingsButton.setHeight(BUTTON_HEIGHT);\n\n logoutButton.setWidth(BUTTON_WIDTH);\n super.verticalNavigation.addComponent(logoutButton);\n super.verticalNavigation.setComponentAlignment(logoutButton, Alignment.MIDDLE_CENTER);\n logoutButton.setDescription(\"You will be logged out\");\n logoutButton.setIcon(new ThemeResource(\"img/logout.png\"), BUTTON_LOGOUT);\n logoutButton.setWidth(BUTTON_WIDTH);\n logoutButton.setHeight(BUTTON_HEIGHT);\n\n }",
"private void init() {\r\n\t\tthis.setBackground(Color.decode(\"#c5dfed\"));\r\n\r\n\t\tthis.initPanelButtons();\r\n\r\n\t\tUtilityClass.addBorder(this, 20, 20, 20, 20);\r\n\t\t\r\n\t\tthis.title.setFont(ConstantView.FONT_TITLE_CRUD);\r\n\t\tthis.title.setHorizontalAlignment(JLabel.CENTER);\r\n\t\tthis.add(title, BorderLayout.NORTH);\r\n\t\t\r\n\t\tthis.add(panelButtons, BorderLayout.SOUTH);\r\n\t\tthis.jPanelFormClient.setOpaque(false);\r\n\t\tthis.add(jPanelFormClient, BorderLayout.CENTER);\r\n\t}",
"Button createButton();",
"private void initializeButton(JPanel myPanel) {\n for (int row = 0; row < 8; row++) {\n for (int col = 0; col < 8; col++) {\n JButton myButton = new JButton();\n buttonGrid[row][col] = myButton;\n setButtonIcon(row,col);\n if ((row + col) % 2 == 0)\n myButton.setBackground(Color.WHITE);\n else\n myButton.setBackground(Color.GRAY);\n myButton.setOpaque(true);\n myButton.setBorderPainted(false);\n myButton.addActionListener(new ActionListener() {\n @Override\n public void actionPerformed(ActionEvent e) {\n pieceButtonClicked(e);\n }\n });\n myPanel.add(myButton);\n }\n }\n }",
"private void setupButtons() {\n\t\tsetupCreateCourse();\n\t\tsetupRemoveCourse();\n\t\tsetupCreateOffering();\n\t\tsetupRemoveOffering();\n\t\tsetupAddPreReq();\n\t\tsetupRemovePreReq();\n\t\tsetupBack();\n\t}",
"private void createButton(){\n addButton();\n addStartButton();\n }",
"private void init() {\n\t\t\n\t\t// Buttons\n\t\tendButton = new JButton(\"Spiel beenden\");\n\t\tendButton.setBackground(Color.white);\n\t\tendButton.setForeground(Color.black);\n\t\tendButton.setFont(endButton.getFont().deriveFont(20.0f));\n\t\tendButton.setBorder(BorderFactory.createStrokeBorder(new BasicStroke(1.5f), Color.black));\n\t\t\n\t\tanleitungButton = new JButton(\"Anleitung\");\n\t\tanleitungButton.setBackground(endButton.getBackground());\n\t\tanleitungButton.setForeground(endButton.getForeground());\n\t\tanleitungButton.setFont(endButton.getFont());\n\t\tanleitungButton.setBorder(endButton.getBorder());\n\t\t\n\t\tbackButton = new JButton(\"zurück\");\n\t\tbackButton.setBackground(endButton.getBackground());\n\t\tbackButton.setForeground(endButton.getForeground());\n\t\tbackButton.setFont(endButton.getFont());\n\t\tbackButton.setBorder(endButton.getBorder());\n\t\t\n\t\tbuttonPanel = new JPanel(new GridLayout(3, 1, 0, 50));\n\t\tbuttonPanel.add(endButton);\n\t\tbuttonPanel.add(anleitungButton);\n\t\tbuttonPanel.add(backButton);\n\t\tbuttonPanel.setBackground(Color.red.darker());\n\t\t\n\t\tgetContentPane().setLayout(new BorderLayout(40, 40));\n\t\tgetContentPane().add(buttonPanel, BorderLayout.CENTER);\n\t\tgetContentPane().add(new JLabel(), BorderLayout.NORTH);\n\t\tgetContentPane().add(new JLabel(), BorderLayout.SOUTH);\n\t\tgetContentPane().add(new JLabel(), BorderLayout.WEST);\n\t\tgetContentPane().add(new JLabel(), BorderLayout.EAST);\n\t\tgetContentPane().setBackground(buttonPanel.getBackground());\n\t\t\n\t\t// ACTIONLISTENER\n\t\tendButton.addActionListener(new ActionListener() {\n\t\t\t\n\t\t\t@Override\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\tdispose();\n\t\t\t\tSystem.exit(0);\n\t\t\t\tcancelGameandGoBackToHome(e);\t\t\t\n\t\t\t}\n\t\t});\n\t\t\n\t\tanleitungButton.addActionListener(new ActionListener() {\n\t\t\t\n\t\t\t@Override\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\tdispose();\n\t\t\t\topenAnleitung(e);\n\t\t\t}\n\t\t});\n\t\t\n\t\tbackButton.addActionListener(new ActionListener() {\n\t\t\t\n\t\t\t@Override\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\tdispose();\n\t\t\t\tbackToGame(e);\t\t\t\t\t\n\t\t\t}\n\t\t});\n\t}",
"public void createButtons() {\n\n addRow = new JButton(\"Add row\");\n add(addRow);\n\n deleteRow = new JButton(\"Delete row\");\n add(deleteRow);\n }",
"private JPanel createButtonPanel()\n\t{\n\t\tfinal String OK_COMMAND = \"Ok\";\n\t\tfinal String CANCEL_COMMAND = \"Cancel\";\n\t\tfinal String APPLY_COMMAND = \"Apply\";\n\n\t\tJPanel buttonPanel = new JPanel();\n\t\tbuttonPanel.setLayout(new FlowLayout(FlowLayout.RIGHT));\n\t\tActionListener buttonListener = new ActionListener()\n\t\t{\n\t\t\t@Override\n\t\t\tpublic void actionPerformed(ActionEvent e)\n\t\t\t{\n\t\t\t\tif (e.getActionCommand().equals(OK_COMMAND))\n\t\t\t\t{\n\t\t\t\t\tStyleEditorFrame.this.setVisible(false);\n\n\t\t\t\t\tguiController.displayProgressWhileRebuilding(new Runnable()\n\t\t\t\t\t{\n\t\t\t\t\t\t@Override\n\t\t\t\t\t\tpublic void run()\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tStyleEditorFrame.this.applyCurrentStyle();\n\t\t\t\t\t\t}\n\t\t\t\t\t});\n\n\t\t\t\t\tStyleEditorFrame.this.getCurrentStyleTree().updateTree();\n\t\t\t\t}\n\t\t\t\telse if (e.getActionCommand().equals(CANCEL_COMMAND))\n\t\t\t\t{\n\t\t\t\t\tStyleEditorFrame.this.setVisible(false);\n\t\t\t\t\tStyleEditorFrame.this.getCurrentStyleTree().updateTree();\n\t\t\t\t}\n\t\t\t\telse if (e.getActionCommand().equals(APPLY_COMMAND))\n\t\t\t\t{\n\t\t\t\t\tguiController.displayProgressWhileRebuilding(new Runnable()\n\t\t\t\t\t{\n\t\t\t\t\t\t@Override\n\t\t\t\t\t\tpublic void run()\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tStyleEditorFrame.this.applyCurrentStyle();\n\t\t\t\t\t\t}\n\t\t\t\t\t});\n\n\t\t\t\t\tStyleEditorFrame.this.getCurrentStyleTree().updateTree();\n\t\t\t\t}\n\t\t\t}\n\t\t};\n\n\t\t{\n\t\t\tJButton applyButton = new JButton(\"Apply\");\n\t\t\tapplyButton.setActionCommand(APPLY_COMMAND);\n\t\t\tbuttonPanel.add(applyButton);\n\t\t\tapplyButton.addActionListener(buttonListener);\n\t\t}\n\t\t{\n\t\t\tJButton okButton = new JButton(\"Ok\");\n\t\t\tokButton.setActionCommand(OK_COMMAND);\n\t\t\tbuttonPanel.add(okButton);\n\t\t\tokButton.addActionListener(buttonListener);\n\t\t}\n\t\t{\n\t\t\tJButton cancelButton = new JButton(\"Cancel\");\n\t\t\tcancelButton.setActionCommand(CANCEL_COMMAND);\n\t\t\tbuttonPanel.add(cancelButton);\n\t\t\tcancelButton.addActionListener(buttonListener);\n\t\t}\n\n\t\treturn buttonPanel;\n\t}",
"public CompoundButton(IButton... buttons) {\n\t\tthis.buttons = buttons;\n\t\twasDown = false;\n\t}",
"private void initComponents() {\n\n jButton1 = new javax.swing.JButton();\n\n setLayout(new java.awt.BorderLayout());\n\n org.openide.awt.Mnemonics.setLocalizedText(jButton1, org.openide.util.NbBundle.getMessage(CallGraphTopComponent.class, \"NO_VIEW_AVAILABLE\")); // NOI18N\n jButton1.setEnabled(false);\n jButton1.setFocusable(false);\n add(jButton1, java.awt.BorderLayout.CENTER);\n }",
"private void setupButtons() {\n final ButtonGroup btngrp = new ButtonGroup();\n\n for (final AbstractAction actn : myToolActions) {\n final JToggleButton btn = new JToggleButton(actn);\n btn.addActionListener(actn);\n btngrp.add(btn);\n add(btn);\n }\n\n btngrp.clearSelection();\n btngrp.getElements().nextElement().setSelected(true);\n\n }",
"@Override\n\tprotected void createCompButtons() {\n\t\tbtnExcelReport = new Button(getCompButtons(), SWT.NONE);\n\t\tbtnExcelReport.setText(\"Excel Report\");\n\t\tbtnExcelReport.setFont(ResourceUtils.getFont(iDartFont.VERASANS_8));\n\t\tbtnExcelReport\n\t\t.addSelectionListener(new org.eclipse.swt.events.SelectionAdapter() {\n\t\t\t@Override\n\t\t\tpublic void widgetSelected(\n\t\t\t\t\torg.eclipse.swt.events.SelectionEvent e) {\n\t\t\t\tcmdExcelReportWidgetSelected();\n\t\t\t}\n\t\t});\n\t}",
"public void createButtonGrid() {\n\t\tbuttonPanel.setOpaque(false);\n\t\t\n\t\t// designs array of buttons\n\t\tfor (int counter = 1; counter <= 20; counter++) {\n\t\t\tbuttonArray[counter] = new JButton();\n\t\t\tbuttonArray[counter].setOpaque(false);\n\t\t\tbuttonArray[counter].setVisible(true);\n\t\t\tbuttonArray[counter].setBorderPainted(false);\n\t\t\tbuttonArray[counter].setHorizontalTextPosition(JButton.CENTER);\n\t\t\tbuttonArray[counter].setVerticalTextPosition(SwingConstants.CENTER);\n\t\t\tbuttonArray[counter].setFont(new Font(\"Courier\", Font.PLAIN, 15));\n\t\t\tbuttonArray[counter].setText(\"<html><font color = white>\" + Integer.toString(counter) + \"</font></html>\");\n\t\t\t// add action listener to each button\n\t\t\tbuttonArray[counter].addActionListener(eventsMain);\n\t\t\t// add each button to the container\n\t\t\tbuttonPanel.add(buttonArray[counter]);\n\t\t}\n\t\t\n\t\t// set colour for ach row of buttons\n\t\tfor (int counter = 1; counter <= 20; counter++) {\n\t\t\tif (counter >= 1 && counter < 6) {\n\t\t\t\tbuttonArray[counter].setIcon(btnBlue);\n\t\t\t} else if (counter > 5 && counter < 11) {\n\t\t\t\tbuttonArray[counter].setIcon(btnGreen);\n\t\t\t} else if (counter > 10 && counter < 16) {\n\t\t\t\tbuttonArray[counter].setIcon(btnRed);\n\t\t\t} else if (counter > 15 && counter < 21) {\n\t\t\t\tbuttonArray[counter].setIcon(btnGray);\n\t\t\t}\n\t\t}\n\t}",
"private void initBtnsArray()\r\n {\r\n for (int i = 0; i < this.buttons.length; i++)\r\n this.buttons[i] = new Button(\"Button #\" + i);\r\n }",
"private void createButtonPanel()\r\n { \r\n JPanel buttonPanel = new JPanel();\r\n buttonPanel.setLayout(new GridLayout(4, 4));\r\n\r\n buttonPanel.add(makeDigitButton(\"7\"));\r\n buttonPanel.add(makeDigitButton(\"8\"));\r\n buttonPanel.add(makeDigitButton(\"9\"));\r\n buttonPanel.add(makeOperatorButton(\"/\"));\r\n buttonPanel.add(makeDigitButton(\"4\"));\r\n buttonPanel.add(makeDigitButton(\"5\"));\r\n buttonPanel.add(makeDigitButton(\"6\"));\r\n buttonPanel.add(makeOperatorButton(\"*\"));\r\n buttonPanel.add(makeDigitButton(\"1\"));\r\n buttonPanel.add(makeDigitButton(\"2\"));\r\n buttonPanel.add(makeDigitButton(\"3\"));\r\n buttonPanel.add(makeOperatorButton(\"-\"));\r\n buttonPanel.add(makeDigitButton(\"0\"));\r\n buttonPanel.add(makeDigitButton(\".\"));\r\n buttonPanel.add(makeOperatorButton(\"=\"));\r\n buttonPanel.add(makeOperatorButton(\"+\"));\r\n\r\n add(buttonPanel, BorderLayout.CENTER);\r\n }",
"@Override\n\tprotected void buildButton() {\n\t\t\n\t}",
"public OptionPanel(Main w) {\r\n\t\tthis.w = w;\r\n\t\tstartButton = new JButton();\r\n\t\texitButton = new JButton();\r\n\t\t\r\n\t}",
"private JPanel makeControlPanel() {\n\n final JPanel panel = new JPanel(new FlowLayout(3));\n final JButton refreshButton = new JButton(new ImageIcon(iconMaker(\"refreshREAL.png\")));\n refreshButton.setFocusPainted(false);\n refreshButton.addActionListener(this::refreshButtonClicked);\n refreshButton.setToolTipText(\"Refresh Item Price(s)\");\n //checkButton.setPreferredSize(new Dimension(25,25));\n JButton viewLink = new JButton(new ImageIcon(iconMaker(\"visitSite.png\")));\n viewLink.setToolTipText(\"Visit Item Website\");\n JButton deleteItem = new JButton(new ImageIcon(iconMaker(\"delete.png\")));\n deleteItem.setToolTipText(\"Remove Item\");\n JButton addItem = buttonMaker(\"additem.png\");\n addItem.setToolTipText(\"Add Item to Price Watcher\");\n JButton editItem = buttonMaker(\"edititem.png\");\n editItem.setToolTipText(\"Edit Item Details\");\n\n\n viewLink.setFocusPainted(false);\n deleteItem.setFocusPainted(false);\n\n viewLink.addActionListener(this::viewPageClicked);\n panel.add(refreshButton);\n panel.add(viewLink);\n panel.add(deleteItem);\n panel.add(addItem);\n panel.add(editItem);\n\n return panel;\n }",
"public BorderPanel(){\r\n setLayout(new BorderLayout());\r\n setBackground(Color.green);\r\n JButton b1 = new JButton(\"Button 1\");\r\n JButton b2 = new JButton(\"Button 2\");\r\n JButton b3 = new JButton(\"Button 3\");\r\n JButton b4 = new JButton(\"Button 4\");\r\n JButton b5 = new JButton(\"Button 5\");\r\n add(b1, BorderLayout.CENTER);\r\n add(b2, BorderLayout.NORTH);\r\n add(b3, BorderLayout.SOUTH);\r\n add(b4, BorderLayout.EAST);\r\n add(b5, BorderLayout.WEST);\r\n }",
"@Override\n protected void addButtons()\n {\n JLabel agentOptions = new JLabel(\"Client Options \", SwingConstants.CENTER);\n addComponentToGridBag(this, agentOptions, 0, 0, 1, 1, GridBagConstraints.CENTER, GridBagConstraints.BOTH);\n\n JButton agentSendMessage = new JButton(\"Send Message\");\n addComponentToGridBag(this, agentSendMessage, 0, 2, 1, 1, GridBagConstraints.CENTER, GridBagConstraints.BOTH);\n agentSendMessage.addActionListener((ActionEvent e) ->\n {\n String to = getTo();\n String content = getContent(to);\n sendMessage(to, content);\n });\n\n JButton agentShowPortal = new JButton(\"Show Portal\");\n addComponentToGridBag(this, agentShowPortal, 0, 3, 1, 1, GridBagConstraints.CENTER, GridBagConstraints.BOTH);\n agentShowPortal.addActionListener((ActionEvent e) ->\n {\n displayConnections();\n });\n\n JButton agentexit = new JButton(\"Exit\");\n addComponentToGridBag(this, agentexit, 0, 5, 1, 1, GridBagConstraints.CENTER, GridBagConstraints.BOTH);\n agentexit.addActionListener((ActionEvent e) ->\n {\n System.exit(0);\n });\n }",
"@NotNull\n TBItemButton addButton() {\n @NotNull TBItemButton butt = new TBItemButton(myItemListener, myStats != null ? myStats.getActionStats(\"simple_button\") : null);\n myItems.addItem(butt);\n return butt;\n }",
"private JComponent buildButtons() {\n Panel panel = new Panel();\n panel.setLayout(new FlowLayout(FlowLayout.RIGHT));\n JButton button = Buttons.create(\"Create\").onClick((ev) -> {\n try {\n group.setName(name.getText());\n group.clearUsers();\n list.getSelectedValuesList().forEach((item) -> {\n group.addUser(item);\n });\n if (group.getName().isEmpty()) {\n JOptionPane.showMessageDialog(null, \"Name is required\");\n return;\n }\n if (!group.hasUsers()) {\n JOptionPane.showMessageDialog(null, \"Users are required\");\n return;\n }\n if (group.getId() == 0) {\n GroupRepository.get().save(group);\n } else {\n GroupRepository.get().update(group);\n }\n SwingUtilities.getWindowAncestor(this).dispose();\n } catch (RepositoryException ex) {\n JOptionPane.showMessageDialog(null, ex.getMessage());\n }\n });\n button.setIcon(IconFactory.get().create(\"fa:check\"));\n panel.add(button);\n return panel;\n }",
"private void initButtons() {\n HBox buttons = new HBox(50);\n yes = new Button(\"Yes!\");\n no = new Button(\"No!\");\n buttons.getChildren().addAll(yes,no);\n buttons.setAlignment(Pos.CENTER);\n root.getChildren().addAll(buttons);\n }",
"@Override\n\tprotected void initAddButton() {\n addBtn = addButton(\"newBtn\", TwlLocalisationKeys.ADD_BEAT_TYPE_TOOLTIP, new Runnable() {\n\t\t\t\t@Override\n\t\t\t\tpublic void run() {\n\t\t\t\t\tnew AddEditBeatTypePanel(true, null, BeatTypesList.this).run(); // adding\n\t\t\t\t}\n\t }); \t\t\n\t}",
"protected void createButtons(Composite parent) {\n\t\tcomRoot = new Composite(parent, SWT.BORDER);\n\t\tcomRoot.setLayoutData(new GridData(SWT.RIGHT, SWT.CENTER, true, false));\n\t\tcomRoot.setLayout(new GridLayout(2, false));\n\n\t\ttbTools = new ToolBar(comRoot, SWT.WRAP | SWT.RIGHT | SWT.FLAT);\n\t\ttbTools.setLayout(new GridLayout());\n\t\ttbTools.setLayoutData(new GridData(SWT.RIGHT, SWT.BOTTOM, true, false));\n\n\t\tfinal ToolItem btnSettings = new ToolItem(tbTools, SWT.NONE);\n\t\tbtnSettings.setText(Messages.btnAdvancedSettings);\n\t\tbtnSettings.setToolTipText(Messages.tipAdvancedSettings);\n\t\tbtnSettings.addSelectionListener(new SelectionAdapter() {\n\n\t\t\tpublic void widgetSelected(final SelectionEvent event) {\n\t\t\t\tPerformanceSettingsDialog dialog = new PerformanceSettingsDialog(\n\t\t\t\t\t\tgetShell(), getMigrationWizard().getMigrationConfig());\n\t\t\t\tdialog.open();\n\t\t\t}\n\t\t});\n\n\t\tnew ToolItem(tbTools, SWT.SEPARATOR);\n\t\tbtnPreviewDDL = new ToolItem(tbTools, SWT.CHECK);\n\t\tbtnPreviewDDL.setSelection(false);\n\t\tbtnPreviewDDL.setText(Messages.btnPreviewDDL);\n\t\tbtnPreviewDDL.setToolTipText(Messages.tipPreviewDDL);\n\t\tbtnPreviewDDL.addSelectionListener(new SelectionAdapter() {\n\n\t\t\tpublic void widgetSelected(final SelectionEvent event) {\n\t\t\t\tboolean flag = btnPreviewDDL.getSelection();\n\t\t\t\tswitchText(flag);\n\t\t\t}\n\t\t});\n\t\tnew ToolItem(tbTools, SWT.SEPARATOR);\n\n\t\tfinal ToolItem btnExportScript = new ToolItem(tbTools, SWT.NONE);\n\t\tbtnExportScript.setText(Messages.btnExportScript);\n\t\tbtnExportScript.setToolTipText(Messages.tipSaveScript);\n\t\tbtnExportScript.addSelectionListener(new SelectionAdapter() {\n\n\t\t\tpublic void widgetSelected(final SelectionEvent event) {\n\t\t\t\texportScriptToFile();\n\t\t\t}\n\t\t});\n\t\tnew ToolItem(tbTools, SWT.SEPARATOR);\n\t\tfinal ToolItem btnUpdateScript = new ToolItem(tbTools, SWT.NONE);\n\t\tbtnUpdateScript.setText(Messages.btnUpdateScript);\n\t\tbtnUpdateScript.setToolTipText(Messages.tipUpdateScript);\n\t\tbtnUpdateScript.addSelectionListener(new SelectionAdapter() {\n\n\t\t\tpublic void widgetSelected(final SelectionEvent event) {\n\t\t\t\tprepare4SaveScript();\n\t\t\t\tgetMigrationWizard().saveMigrationScript(false, isSaveSchema());\n\t\t\t\tMessageDialog.openInformation(PlatformUI.getWorkbench()\n\t\t\t\t\t\t.getDisplay().getActiveShell(),\n\t\t\t\t\t\tMessages.msgInformation, Messages.setOptionPageOKMsg);\n\t\t\t}\n\t\t});\n\t\tbtnUpdateScript\n\t\t\t\t.setEnabled(getMigrationWizard().getMigrationScript() != null);\n\t\tnew ToolItem(tbTools, SWT.SEPARATOR);\n\t\tfinal ToolItem btnNewScript = new ToolItem(tbTools, SWT.NONE);\n\t\tbtnNewScript.setText(Messages.btnCreateNewScript);\n\t\tbtnNewScript.setToolTipText(Messages.tipCreateNewScript);\n\t\tbtnNewScript.addSelectionListener(new SelectionAdapter() {\n\n\t\t\tpublic void widgetSelected(final SelectionEvent event) {\n\t\t\t\tprepare4SaveScript();\n\t\t\t\tString name = EditScriptDialog.getMigrationScriptName(\n\t\t\t\t\t\tgetShell(), getMigrationWizard().getMigrationConfig()\n\t\t\t\t\t\t\t\t.getName());\n\t\t\t\tif (StringUtils.isBlank(name)) {\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t\tgetMigrationWizard().getMigrationConfig().setName(name);\n\t\t\t\tgetMigrationWizard().saveMigrationScript(true, isSaveSchema());\n\t\t\t\tbtnUpdateScript.setEnabled(getMigrationWizard()\n\t\t\t\t\t\t.getMigrationScript() != null);\n\t\t\t\tMessageDialog.openInformation(PlatformUI.getWorkbench()\n\t\t\t\t\t\t.getDisplay().getActiveShell(),\n\t\t\t\t\t\tMessages.msgInformation, Messages.setOptionPageOKMsg);\n\t\t\t}\n\t\t});\n\t}",
"public void buildButtons() {\r\n\t\tImage temp1= display_img.getImage();\r\n\t\tImageIcon img=new ImageIcon(temp1.getScaledInstance(800, 800, Image.SCALE_SMOOTH));\r\n\t\timg1 = img.getImage();\r\n\t\tfor(int y=0;y<10;y++) {\r\n\t\t\tfor(int x=0; x<10; x++) {\r\n\t\t\t\tImage image = Toolkit.getDefaultToolkit().createImage(new FilteredImageSource(img1.getSource(), new CropImageFilter(x * 800 / 10, y * 800 / 10, 100, 100)));\r\n\t\t\t\tImageIcon icon = new ImageIcon(image);\r\n\t\t\t\tJButton temp = new JButton(icon);\r\n\t\t\t\ttemp.putClientProperty(\"position\", new Point(y,x));\r\n\t\t\t\tsolutions.add(new Point(y,x));\r\n\t\t\t\ttemp.putClientProperty(\"isLocked\", false);\r\n\t\t\t\ttemp.addMouseListener(new DragMouseAdapter());\r\n\t\t\t\tgrid[x][y]=temp;\r\n\r\n\t\t\t\tbuttons.add(temp);\r\n\t\t\t}\r\n\t\t}\r\n\t}",
"private JPanel createButtonPanel() {\n\t\tJPanel buttonPanel = new JPanel();\n\t\tbuttonPanel.setLayout(new BoxLayout(buttonPanel, BoxLayout.LINE_AXIS));\n\t\t\n\t\tGridBagConstraints gbc = new GridBagConstraints();\n gbc.gridwidth = GridBagConstraints.REMAINDER;\n gbc.anchor = GridBagConstraints.NORTH;\n gbc.anchor = GridBagConstraints.CENTER;\n gbc.fill = GridBagConstraints.HORIZONTAL;\n\t\t\n\t\tJButton okBtn = new JButton(\"Close\");\n\t\t\n\t\tokBtn.addActionListener(new ActionListener() {\n public void actionPerformed(ActionEvent event) {\n \tsetVisible(false);\n }\n });\n\t\t\n\t\tJPanel buttons = new JPanel(new GridBagLayout());\n buttons.add(okBtn, gbc);\n \n gbc.weighty = 1;\n\t\tbuttonPanel.add(buttons, gbc);\n\t\tbuttonPanel.setBorder(BorderFactory.createEmptyBorder(10, 10, 10, 10));\n\n\t\treturn buttonPanel;\n\t}",
"private JPanel makePrgButtonPanel() {\r\n\t\tGridBagConstraints gridBagConstraints2 = new GridBagConstraints();\r\n\t\tgridBagConstraints2.insets = new Insets(0, 0, 0, 0);\r\n\t\tgridBagConstraints2.gridy = 0;\r\n\t\tgridBagConstraints2.ipady = 0;\r\n\t\tgridBagConstraints2.gridheight = 1;\r\n\t\tgridBagConstraints2.gridwidth = 1;\r\n\t\tgridBagConstraints2.gridx = 0;\r\n\t\tJPanel tprgButtonPanel = new JPanel();\r\n\t\ttprgButtonPanel.setLayout(new GridBagLayout());\r\n\t\ttprgButtonPanel.setBorder(BorderFactory.createLineBorder(new Color(102, 102, 102), 1));\r\n\t\ttprgButtonPanel.setBackground(new Color(250, 250, 250));\r\n\t\ttprgButtonPanel.setPreferredSize(new Dimension(150, 140));\r\n\t\ttprgButtonPanel.add(makePrgRunButton(), gridBagConstraints2);\r\n\t\treturn tprgButtonPanel;\r\n\t}",
"private void addButtonsToButtonPanel() {\n // The button to change the login accounts password\n changePasswordButton = new JButton(\"Change Password\");\n changePasswordButton.setPreferredSize(new Dimension(150, 45));\n changePasswordButton.addActionListener(this);\n changePasswordButton.setToolTipText(\"<html> Click this button to change the login accounts <b> password</b>. </html>\");\n changePasswordButton.setIcon(new ImageIcon(\"images/icons/bullet_edit.png\"));\n \n // Adds the change login accounts password to the button panel\n buttonPanel.add(changePasswordButton);\n \n \n // The button to change the login accounts security question and answer\n changeSecurityQ = new JButton(\"Change Security Question & Answer\");\n changeSecurityQ.setPreferredSize(new Dimension(250, 45));\n changeSecurityQ.addActionListener(this);\n changeSecurityQ.setToolTipText(\"<html> Click this button to change the login accounts <b> security question & answer</b>. </html>\");\n changeSecurityQ.setIcon(new ImageIcon(\"images/icons/bullet_edit.png\"));\n \n // Adds the change login accounts security question and answer to the button panel\n buttonPanel.add(changeSecurityQ);\n \n \n // The button to change the login accounts security question and answer\n cancelButton = new JButton(\"Cancel editting\");\n cancelButton.setPreferredSize(new Dimension(150, 45));\n cancelButton.addActionListener(this);\n cancelButton.setToolTipText(\"<html> Click this button to <b> cancel</b> the editing of the login account. </html>\");\n cancelButton.setIcon(new ImageIcon(\"images/icons/cancel.png\"));\n \n // Adds the change login accounts security question and answer to the button panel\n buttonPanel.add(cancelButton);\n \n // Updates the UI of the button panel\n buttonPanel.updateUI();\n }",
"MyButton(int i, int j, ButtonListenerImplementation buttonListener){\n\n super(\" \");\n setBackground(Color.LIGHT_GRAY);\n\n indexX=i;\n indexY=j;\n addActionListener(buttonListener);\n }",
"@Override\n public void initialiseButtons() {\n resumeButton = new Button(buttonLeft, resumeButtonTop, buttonRight, resumeButtonBottom, Assets.resume);\n restartButton = new Button(buttonLeft, restartButtonTop, buttonRight, restartButtonBottom, Assets.restart);\n instructionsButton = new Button(buttonLeft, instructionsButtonTop, buttonRight, instructionsButtonBottom, Assets.instructions);\n quitButton = new Button(buttonLeft, quitButtonTop, buttonRight, quitButtonBottom, Assets.quit);\n backArrowButton = new Button(-8,-10,120,100, Assets.backArrowButton);\n saveGameButton = new Button(buttonLeft,saveGameButtonTop,buttonRight,saveGameButtonBottom,Assets.saveGame);\n }",
"private void setUpPanel() {\n\n this.add(nameLabel);\n this.add(showMetadataButton);\n this.add(compressFilesButton);\n this.add(decompressFilesButton);\n this.add(compressionResultLabel);\n this.add(messageShorteningButton);\n this.add(messageShorteningResultLabel);\n }",
"public RobotContainer() {\n // Configure the button bindings\n configureButtonBindings();\n\n }",
"public BoardControl() {\r\n\t\t\tsuper();\r\n\t\t\tthis.setLayout(null);\r\n\r\n\t\t\tbtnCrt = new JButton(\"创建\");\r\n\t\t\tbtnCrt.setBounds(0, 300, 130, 40);\r\n\t\t\tbtnCrt.setFont(new Font(\"楷体\", Font.BOLD, 30));\r\n\t\t\tbtnCrt.setBackground(Color.gray);\r\n\t\t\tadd(btnCrt);\r\n\r\n\t\t\tbtnJin = new JButton(\"加入\");\r\n\t\t\tbtnJin.setBounds(0, 360, 130, 40);\r\n\t\t\tbtnJin.setFont(new Font(\"楷体\", Font.BOLD, 30));\r\n\t\t\tbtnJin.setBackground(Color.gray);\r\n\t\t\tadd(btnJin);\r\n\r\n\t\t\tbtnSrd = new JButton(\"认输\");\r\n\t\t\tbtnSrd.setBounds(0, 420, 130, 40);\r\n\t\t\tbtnSrd.setFont(new Font(\"楷体\", Font.BOLD, 30));\r\n\t\t\tbtnSrd.setBackground(Color.gray);\r\n\t\t\tadd(btnSrd);\r\n\r\n\t\t\tbtnExt = new JButton(\"退出\");\r\n\t\t\tbtnExt.setBounds(0, 480, 130, 40);\r\n\t\t\tbtnExt.setFont(new Font(\"楷体\", Font.BOLD, 30));\r\n\t\t\tbtnExt.setBackground(Color.gray);\r\n\t\t\tadd(btnExt);\r\n\r\n\t\t\tButtonAct cbut = new ButtonAct();\r\n\t\t\tbtnCrt.addActionListener(cbut);\r\n\t\t\tbtnJin.addActionListener(cbut);\r\n\t\t\tbtnSrd.addActionListener(cbut);\r\n\t\t\tbtnExt.addActionListener(cbut);\r\n\t\t}",
"protected void init(){\n ac = new ButtonEventManager(this);\n \n nameField = new JTextField();\n \n done = new JButton(\"DONE\");\n back = new JButton(\"MAIN MENU\");\n quit = new JButton(\"QUIT\");\n \n done.setActionCommand(\"go to game menu after saving\");\n back.setActionCommand(\"go to the main menu\");\n quit.setActionCommand(\"quit the game\");\n \n Font font = new Font(\"Arial\", Font.PLAIN, 10);\n \n nameField.setFont(font);\n \n nameField.setBounds(2 * this.getWidth() / 3 - buttonWidth / 2, (int)(0.4 * this.getHeight() - textFieldHeight / 2), buttonWidth, textFieldHeight);\n \n done.setBounds((this.getWidth() / 2 - buttonWidth) / 2, (int)(0.7 * this.getHeight() - buttonHeight / 2), buttonWidth, buttonHeight);\n back.setBounds((this.getWidth() - buttonWidth) / 2, (int)(0.7 * this.getHeight() - buttonHeight / 2), buttonWidth, buttonHeight);\n quit.setBounds(3 * (this.getWidth() - buttonWidth) / 2, (int)(0.7 * this.getHeight() - buttonHeight / 2), buttonWidth, buttonHeight);\n \n done.addActionListener(ac);\n back.addActionListener(ac);\n quit.addActionListener(ac);\n \n add(nameField);\n \n add(done);\n add(back);\n add(quit);\n }",
"public BubblePanel()\n\t{\n\t\t// Set the layout to be border-style\n\t\tsuper( new BorderLayout());\n\t\t// Create panel defaults\n\t\tinitPanel();\n\t}",
"public GameButton() {\n initialize();\n }",
"private void createButton() {\n this.setIcon(images.getImageIcon(fileName + \"-button\"));\n this.setActionCommand(command);\n this.setPreferredSize(new Dimension(width, height));\n this.setMaximumSize(new Dimension(width, height));\n }",
"private void createButton() throws SlickException {\n int width = 25*getGameContainer().getWidth()/100;\n int height = 10*getGameContainer().getHeight()/100;\n\n Image login = new Image(getReaderXmlFile().read(\"buttonLogin\")).getScaledCopy(width, height);\n Coordinate posLogin = new Coordinate((getGameContainer().getWidth() - login.getWidth())/2,55*getGameContainer().getHeight()/100);\n loginButton = new Button(getGameContainer(), login, posLogin, IDStates.MENU_STATE, this);\n\n Image account = new Image(getReaderXmlFile().read(\"buttonAccount\")).getScaledCopy(width, height);\n Coordinate posAccount = new Coordinate((getGameContainer().getWidth() - account.getWidth())/2,70*getGameContainer().getHeight()/100);\n accountButton = new Button(getGameContainer(), account, posAccount, IDStates.MENU_STATE, this);\n }",
"private JPanel getButtonPanel() {\n if (buttonPanel == null) {\n GridLayout gridLayout = new GridLayout();\n gridLayout.setRows(1);\n gridLayout.setColumns(2);\n gridLayout.setHgap(4);\n buttonPanel = new JPanel();\n buttonPanel.setLayout(gridLayout);\n buttonPanel.add(getOkButton(), null);\n buttonPanel.add(getCancelButton(), null);\n }\n return buttonPanel;\n }",
"public RobotContainer() {\n // Configure the button bindings\n configureButtonBindings();\n }",
"public RobotContainer() {\n // Configure the button bindings\n configureButtonBindings();\n }",
"private JPanel createAddAndRemoveButtons() {\n JPanel panel = new JPanel(new FlowLayout(FlowLayout.LEADING));\n panel.add(createAddResourceButton());\n panel.add(createRemoveResourceButton());\n\n return panel;\n }",
"public ZeePanel(Spel spel) {\n this.spel = spel;\n buttons = new JButton[16][16];\n setLayout(new GridLayout(16,16,5,5));\n for (int rij=0;rij<16;rij++)\n {\n for (int kolom=0;kolom<16;kolom++)\n {\n buttons[rij][kolom] = new JButton();\n buttons[rij][kolom].setBackground(Color.CYAN);\n add(buttons[rij][kolom]);\n buttons[rij][kolom].addActionListener(this);\n buttons[rij][kolom].setActionCommand(rij + \",\" + kolom);\n }\n }\n }"
] | [
"0.7802748",
"0.77472293",
"0.7607926",
"0.75684947",
"0.74838156",
"0.73257405",
"0.716733",
"0.7064777",
"0.7022968",
"0.7022253",
"0.70215654",
"0.7016491",
"0.6997365",
"0.69789934",
"0.6962999",
"0.6952659",
"0.6943063",
"0.6891889",
"0.6860475",
"0.6853876",
"0.6838225",
"0.6814339",
"0.6785634",
"0.6766321",
"0.673887",
"0.6737408",
"0.6730485",
"0.67070216",
"0.6687177",
"0.66856164",
"0.6676142",
"0.6675179",
"0.6647755",
"0.6635087",
"0.6627476",
"0.6626034",
"0.6611383",
"0.6608903",
"0.6601748",
"0.6598546",
"0.6598018",
"0.65899295",
"0.6588877",
"0.65795255",
"0.6555044",
"0.65525126",
"0.6549004",
"0.6548512",
"0.654844",
"0.6532544",
"0.65208113",
"0.6512637",
"0.64940834",
"0.6490519",
"0.6477742",
"0.6473068",
"0.64651114",
"0.6459892",
"0.6438163",
"0.64243746",
"0.64077145",
"0.6396512",
"0.63899815",
"0.63776994",
"0.63748294",
"0.6362994",
"0.63609993",
"0.6359902",
"0.63581514",
"0.6344062",
"0.63370407",
"0.63365555",
"0.6334443",
"0.6332243",
"0.6332195",
"0.63112295",
"0.6310163",
"0.6304342",
"0.63031936",
"0.6297835",
"0.62814695",
"0.6276067",
"0.62703645",
"0.62661546",
"0.62334377",
"0.622995",
"0.6228464",
"0.6222982",
"0.62178415",
"0.62120426",
"0.6199121",
"0.61953086",
"0.6194085",
"0.6191296",
"0.6189297",
"0.6187088",
"0.6185691",
"0.6185691",
"0.61812395",
"0.61735165"
] | 0.7663724 | 2 |
Helper method for the Constructor used to set parameters and add components to the Panel. | private void setupPanel()
{
setLayout(numberLayout);
setBorder(new EtchedBorder(EtchedBorder.RAISED, Color.GRAY, Color.DARK_GRAY));
setBackground(Color.LIGHT_GRAY);
add(ans);
add(clear);
add(backspace);
add(divide);
add(seven);
add(eight);
add(nine);
add(multiply);
add(four);
add(five);
add(six);
add(subtract);
add(one);
add(two);
add(three);
add(add);
add(negative);
add(zero);
add(point);
add(equals);
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public Panel() {\n initComponents();\n\n\n }",
"public Panel() {\n }",
"public ChooseParameterPanel() {\n initComponents();\n }",
"public NewsParamPanel() {\n initComponents();\n titleAnalyzer.setFieldName(\"TITLE\");\n dateAnalyzer.setFieldName(\"DATE\");\n sourceExtractor.setFieldName(\"SOURCENAME\");\n authorExtractor.setFieldName(\"AUTHOR\");\n commentsExtractor.setFieldName(\"COMMENT_COUNT\");\n clicksExtractor.setFieldName(\"CLICK_COUNT\");\n transmitExtractor.setFieldName(\"TRANSMIT_COUNT\");\n summaryExtractor.setFieldName(\"SUMMARY\");\n chnlExtractor.setFieldName(\"CHANNEL\");\n contentExtractor.setFieldName(\"CONTENT\");\n }",
"public Panel(LayoutManager paramLayoutManager)\n/* */ {\n/* 65 */ setLayout(paramLayoutManager);\n/* */ }",
"public Panel()\n/* */ {\n/* 56 */ this(new FlowLayout());\n/* */ }",
"public RaceBasePanel()\n\t{\n\t\tinitComponents();\n\t\tinitComponentContents();\n\t}",
"public NewJPanel() {\n initComponents();\n }",
"public NewJPanel() {\n initComponents();\n }",
"private void init() {\r\n\t\tthis.setBackground(Color.decode(\"#c5dfed\"));\r\n\r\n\t\tthis.initPanelButtons();\r\n\r\n\t\tUtilityClass.addBorder(this, 20, 20, 20, 20);\r\n\t\t\r\n\t\tthis.title.setFont(ConstantView.FONT_TITLE_CRUD);\r\n\t\tthis.title.setHorizontalAlignment(JLabel.CENTER);\r\n\t\tthis.add(title, BorderLayout.NORTH);\r\n\t\t\r\n\t\tthis.add(panelButtons, BorderLayout.SOUTH);\r\n\t\tthis.jPanelFormClient.setOpaque(false);\r\n\t\tthis.add(jPanelFormClient, BorderLayout.CENTER);\r\n\t}",
"public DrawPanel() {\n initComponents();\n }",
"public ECCPanel() {\n initComponents();\n \n }",
"public Records_Panel() {\n\t\tsuper();\n\t\tinitialize();\n\t}",
"public PrintsPanel() {\n initComponents();\n createPanels();\n\n }",
"public DataSetPanel() {\n initComponents();\n }",
"public LoggingPanel() {\n initComponents();\n\n }",
"public AddNewJobPanel() {\n initComponents();\n\n DateTime now = new DateTime();\n initializeComboBoxes();\n }",
"public JavaPanel() {\n\t\tsuper();\n\t}",
"public DemoPanel() {\n }",
"public ControlPanel() {\n\t\tpanelName = null;\n\t}",
"public HoaDonJPanel() {\n initComponents(); \n this.init();\n }",
"public void initialize() {\n \n super.initialize();\n \n PreferredSizeX = this.getPreferredSizeX();\n PreferredSizeY = this.getPreferredSizeY();\n this.setPreferredSize(new Dimension(PreferredSizeX, PreferredSizeY));\n \n this.createParameterPanel();\n \n }",
"private void initPanel() {\n\t\tthis.panel = new JPanel();\n\t\tthis.panel.setBounds(5, 5, 130, 20);\n\t\tthis.panel.setLayout(null); \n\n\t}",
"public void init() {\r\n\t\t/*\r\n\t\t * Initialize panel for base\r\n\t\t */\r\n\t\tbaseList = GameMap.getBaseList();\r\n\t\tthis.add(new BaseInfoPanel(baseList.getFirst(), controlPanel));\r\n\t}",
"public LocalPanel() {\r\n\t\tinitComponents();\r\n\t}",
"public PanelAmigo() {\n initComponents();\n \n }",
"protected DistributionParameterPanel()\r\n\t{\r\n\t\tthis.setPreferredSize(new Dimension(this.width, this.height));\r\n\t}",
"public ParamPanel() {\n this.paramService = new ParamService();\n initComponents();\n doQuery();\n }",
"public OptionPanel() {\n initComponents();\n }",
"public abstract void init(JPanel panel);",
"private void initializePanels()\r\n\t{\r\n\t\tthis.subscribersPanel = new SubscribersPanel(DIMENSIONS);\r\n\t\tthis.consolePanel = new ConsolePanel(DIMENSIONS);\r\n\r\n\t\tthis.parametersPanel = new ParametersPanel(DIMENSIONS);\r\n\t\tthis.parametersPanel.setSize(DIMENSIONS);\r\n\r\n\t\tthis.mainPanel = new MainPanel(parametersPanel, this);\r\n\t\tthis.mainPanel.setSize(DIMENSIONS);\r\n\r\n\t\tshowParametersPanel();\r\n\t}",
"public ComandaPanel() {\n\n initComponents();\n // comanda = new Comanda();\n }",
"public ControlPanel(String propFile) {\n super(propFile);\n frame = new JFrame(\"Control Panel\");\n frame.setPreferredSize(new Dimension(900, 500));\n frame.setDefaultCloseOperation(frame.EXIT_ON_CLOSE);\n }",
"private void setUpPanel() {\n\n this.add(nameLabel);\n this.add(showMetadataButton);\n this.add(compressFilesButton);\n this.add(decompressFilesButton);\n this.add(compressionResultLabel);\n this.add(messageShorteningButton);\n this.add(messageShorteningResultLabel);\n }",
"public AssemblingMessageListPanel()\n {\n //initComponents();\n }",
"public DetailsPanel( )\n {\n initComponents();\n }",
"public BuildingConfigPanel() {\n\n\t\tthis.setLayout(new BorderLayout());\n\t\tthis.setOpaque(true);\n\t\tDimension size = new Dimension(1200, 700);\n\t\tthis.setMaximumSize(size);\n\t\tthis.setPreferredSize(size);\n\t\tthis.setMinimumSize(size);\n\t\tthis.setAlignmentX(LEFT_ALIGNMENT);\n\t\tthis.setBorder(BorderFactory.createLineBorder(Color.blue));\n\t\tthis.setBackground(Color.WHITE);\n\t\tthis.setLayout(null);\n\n\t\tfont = new Font(\"Serif\", Font.BOLD, 18);\n\t\tfont1 = new Font(\"Serif\", Font.PLAIN, 15);\n\n\t\t// method to create sensors checkboxes, date and time fields\n\t\tcreateSensors();\n\t\t// method to connect to database\n\t\tcreateJDBCConnection();\n\t\t// method to highlight the area of selection\n\t\tareaTracker();\n\n\t}",
"public AboutUsPanel() {\n initComponents();\n }",
"public PanelTKPhong() {\n\t\tinitComponents();\n\t\tloaddataTable();\n\t\tloaddataLabel();\n\t}",
"public AddCourseJPanel() { \n initComponents(); \n }",
"public GraphPanel()\n\t{\n\t\t// instantiates graphArray to hold list of names to graph \n\t\tgraphArray = new ArrayList<NameRecord>();\n\t\t\n\t\t// sets the size of the panel\n\t\tsetPreferredSize(new Dimension(600,600));\n\t}",
"public LookUpPanel() {\n initComponents(); \n }",
"public ConfEGTaskPanel() {\n initComponents();\n initListenerButton(); \n initState();\n initApplyCellCheckBox();\n }",
"public RepositoryPanel() {\n initComponents();\n }",
"public ContactPanel() {\n initComponents();\n }",
"public MetadataPanel()\n {\n fieldMap = new HashMap<String, Component>();\n initialiseUI();\n }",
"private void init() {\r\n\t\tthis.panel.setLayout(new BoxLayout(this.panel, BoxLayout.PAGE_AXIS));\r\n\t\tthis.labelTitle = new JLabel(\"Edit your weapons\");\r\n\t\tthis.labelTitle.setAlignmentX(Component.CENTER_ALIGNMENT);\r\n\t\tthis.initFilter();\r\n\t\tthis.initList();\r\n\t\tthis.list.setSelectedIndex(0);\r\n\t\tthis.initInfo();\r\n\t\tthis.initButton();\r\n\r\n\t\tJPanel panelWest = new JPanel();\r\n\t\tpanelWest.setLayout(new BoxLayout(panelWest, BoxLayout.PAGE_AXIS));\r\n\t\tJPanel panelCenter = new JPanel();\r\n\t\tpanelCenter.setLayout(new BoxLayout(panelCenter, BoxLayout.LINE_AXIS));\r\n\r\n\t\tpanelWest.add(this.panelFilter);\r\n\t\tpanelWest.add(Box.createRigidArea(new Dimension(0, 5)));\r\n\t\tpanelWest.add(this.panelInfo);\r\n\t\tpanelCenter.add(panelWest);\r\n\t\tpanelCenter.add(Box.createRigidArea(new Dimension(10, 0)));\r\n\t\tthis.panelList.setPreferredSize(new Dimension(300, 150));\r\n\t\tpanelCenter.add(this.panelList);\r\n\r\n\t\tthis.panel.add(this.labelTitle);\r\n\t\tthis.panel.add(Box.createRigidArea(new Dimension(0, 10)));\r\n\t\tthis.panel.add(panelCenter);\r\n\t\tthis.panel.add(Box.createRigidArea(new Dimension(0, 10)));\r\n\t\tthis.panel.add(this.panelButton);\r\n\r\n\t}",
"public TemporizadorPanel() {\n initComponents();\n }",
"public AppoinmentPanel() {\n initComponents();\n }",
"public PanelCompra() {\n initComponents();\n lblNick.setText(PanelCuenta.cuenta.getNickName());\n lblNombre.setText(PanelCuenta.cuenta.getUsuario().getNombre());\n lblDireccion.setText(PanelCuenta.cuenta.getUsuario().getDireccion());\n llenarTabla();\n }",
"public OptionsPanel() {\n initComponents();\n }",
"public ControladorPanel() { }",
"public ParamPanel() {\n Insets lft_spc = new Insets(0, 5, 0, 0);\n\n /*----------------------------------------------\n Constructor: ParamPanel\n \n \n Purpose: Sets up the control panel containing the\n user specified parameters for performing\n the LSystems image\n \n ---------------------------------------------*/\n\n initColors();\n\n b_doApply = false;\n b_gotImagePnl = false;\n\n\n Panel lPanel = new Panel();\n Panel rPanel = new Panel();\n Panel mPanel = new Panel();\n ClrPanel bPanel = new ClrPanel(aColors);\n\n\n GridBagLayout gridbag = new GridBagLayout();\n GridBagConstraints c = new GridBagConstraints();\n setLayout(gridbag);\n\n c.fill = GridBagConstraints.HORIZONTAL;\t/* fill horizontally*/\n c.weightx = 1; \t\t\t /* each of the 3 panels\n get same horiz space */\n c.insets = new Insets(0, 0, 0, 10); \t/* pad left and right */\n\n c.gridwidth = 1;\n c.anchor = GridBagConstraints.NORTH;\n\n gridbag.setConstraints(lPanel, c);\n gridbag.setConstraints(rPanel, c);\n\n gridbag.setConstraints(mPanel, c);\n\n add(lPanel);\t\t\t/* add panels left to right */\n add(mPanel);\n add(rPanel);\n\n\n\n /*------------\n color panel\n ------------*/\n\n\n\n c = new GridBagConstraints();\n c.gridx = 0;\n c.gridwidth = GridBagConstraints.REMAINDER;\n c.insets = new Insets(15, 0, 0, 0);\n c.fill = GridBagConstraints.HORIZONTAL;\n c.anchor = GridBagConstraints.WEST;\n gridbag.setConstraints(bPanel, c);\n add(bPanel);\n\n gridbag = new GridBagLayout();\n bPanel.setLayout(gridbag);\n\n\n GridBagConstraints c_num = new GridBagConstraints();\n\n c_num.gridwidth = 1; /* first in row */\n c_num.fill = GridBagConstraints.HORIZONTAL;\n c_num.weightx = 1;\n\n\n c_num.insets = new Insets(5, 20, 5, 0);\n Label label8 = new Label(\"0\");\n gridbag.setConstraints(label8, c_num);\n bPanel.add(label8);\n\n c_num.insets = new Insets(5, 59, 5, 0);\n label8 = new Label(\"5\");\n gridbag.setConstraints(label8, c_num);\n bPanel.add(label8);\n\n label8 = new Label(\"10\");\n gridbag.setConstraints(label8, c_num);\n bPanel.add(label8);\n\n label8 = new Label(\"15\");\n gridbag.setConstraints(label8, c_num);\n bPanel.add(label8);\n\n label8 = new Label(\"20\");\n gridbag.setConstraints(label8, c_num);\n bPanel.add(label8);\n\n label8 = new Label(\"25\");\n gridbag.setConstraints(label8, c_num);\n bPanel.add(label8);\n\n\n label8 = new Label(\"30\");\n gridbag.setConstraints(label8, c_num);\n bPanel.add(label8);\n\n label8 = new Label(\"35\");\n gridbag.setConstraints(label8, c_num);\n bPanel.add(label8);\n\n c_num.insets = new Insets(5, 10, 5, 5);\n tb_clr = new TextField(3);\n gridbag.setConstraints(tb_clr, c_num);\n bPanel.add(tb_clr);\n\n\n\n gridbag = new GridBagLayout();\n c = new GridBagConstraints();\n setFont(new Font(\"Helvetica\", Font.PLAIN, 14));\n lPanel.setLayout(gridbag);\n\n c.fill = GridBagConstraints.NONE; /* stretch components left to right */\n\n\n\n c.fill = GridBagConstraints.HORIZONTAL; /* stretch components left to right */\n\n /*----------------------\n LSystems Samples\n ---------------------*/\n GridBagConstraints c_smpl = new GridBagConstraints();\n c_smpl.gridx = 0;\n c_smpl.gridy = 0;\n c_smpl.gridwidth = GridBagConstraints.REMAINDER;\n\n\n /* Rules Label */\n c_smpl.anchor = GridBagConstraints.WEST;\n Label label7 = new Label(\"Sample LSystems:\");\n gridbag.setConstraints(label7, c_smpl);\n lPanel.add(label7);\n\n\n GridBagConstraints c_btn = new GridBagConstraints();\n c_btn.gridwidth = 1;\n c_btn.fill = GridBagConstraints.HORIZONTAL;\n c_btn.weightx = 1;\n\n c_btn.gridx = 0;\n c_btn.gridy = 1;\n TextField tb_placeholder = new TextField(25);\n gridbag.setConstraints(tb_placeholder, c_btn);\n tb_placeholder.hide();\n lPanel.add(tb_placeholder);\n tb_placeholder.show();\n tb_placeholder.hide();\n\n /* List of Samples LSystem Patterns */\n c_smpl.fill = GridBagConstraints.HORIZONTAL;\n c_smpl.anchor = GridBagConstraints.WEST;\n c_smpl.gridy = 1;\n ch_ptrnspecs = new List(6, false);\n ch_ptrnspecs.clear();\n gridbag.setConstraints(ch_ptrnspecs, c_smpl);\n lPanel.add(ch_ptrnspecs);\n fillSpecChoices(ch_ptrnspecs);\n\n\n\n c_btn = new GridBagConstraints();\n c_btn.gridwidth = 1;\n c_btn.fill = GridBagConstraints.HORIZONTAL;\n c_btn.weightx = 1;\n c_btn.insets = new Insets(30, 0, 0, 0);\n\n\n /* Apply button */\n b_apply = new Button(\"Apply\");\n gridbag.setConstraints(b_apply, c_btn);\n lPanel.add(b_apply);\n\n\n\n\n\n\n gridbag = new GridBagLayout();\n c = new GridBagConstraints();\n setFont(new Font(\"Helvetica\", Font.PLAIN, 14));\n mPanel.setLayout(gridbag);\n c.fill = GridBagConstraints.NONE; /* stretch components left to right */\n\n /*----------------------\n Rule Controls\n ---------------------*/\n GridBagConstraints c_rule = new GridBagConstraints();\n c_rule.gridx = 0;\n c_rule.insets = lft_spc;\n c_rule.gridwidth = GridBagConstraints.REMAINDER;\n\n /* Rules Label */\n c_rule.anchor = GridBagConstraints.WEST;\n Label label5 = new Label(\"Rules:\");\n gridbag.setConstraints(label5, c_rule);\n mPanel.add(label5);\n\n\n /* List of Rules */\n c_rule.fill = GridBagConstraints.HORIZONTAL;\n c_rule.anchor = GridBagConstraints.WEST;\n lst_rules = new List(4, false);\n gridbag.setConstraints(lst_rules, c_rule);\n mPanel.add(lst_rules);\n lst_rules.clear();\n\n /* rule edit box */\n c_rule.insets = new Insets(35, 5, 0, 0);\n c_rule.anchor = GridBagConstraints.WEST;\n c_rule.fill = GridBagConstraints.NONE;\n tb_rule = new TextField(27);\n gridbag.setConstraints(tb_rule, c_rule);\n mPanel.add(tb_rule);\n\n\n\n\n\n /*------------------\n Rule Editing Buttons\n (Add, Update, Delete, New)\n ------------------*/\n\n c_btn = new GridBagConstraints();\n c_btn.insets = lft_spc;\n c_btn.gridwidth = 1;\n c_btn.fill = GridBagConstraints.HORIZONTAL;\n c_btn.weightx = 1;\n\n /* rule editing buttons */\n b_add = new Button(\"Add\");\n b_updt = new Button(\"Update\");\n b_del = new Button(\"Delete\");\n b_new = new Button(\"Clear\");\n\n\n gridbag.setConstraints(b_add, c_btn);\n\n gridbag.setConstraints(b_updt, c_btn);\n\n gridbag.setConstraints(b_del, c_btn);\n\n c_btn.gridwidth = GridBagConstraints.REMAINDER; /* last-in-row */\n gridbag.setConstraints(b_new, c_btn);\n\n\n mPanel.add(b_add);\n mPanel.add(b_updt);\n mPanel.add(b_del);\n mPanel.add(b_new);\n\n\n gridbag = new GridBagLayout();\n c = new GridBagConstraints();\n setFont(new Font(\"Helvetica\", Font.PLAIN, 14));\n rPanel.setLayout(gridbag);\n\n c.fill = GridBagConstraints.NONE; /* don't stretch components */\n\n\n cbg_Lines = new CheckboxGroup();\n\n\n /*-------------------\n Line Checkboxes\n ------------------*/\n GridBagConstraints c_line = new GridBagConstraints();\n c_line.gridx = 0;\n c_line.anchor = GridBagConstraints.WEST;\n c_line.gridwidth = GridBagConstraints.REMAINDER; /* last-in-row */\n\n\n\n /* Straight Line Checkbox*/\n\n c_line.insets = new Insets(20, 50, 0, 0);\n cb_strt = new Checkbox(\"Straight Lines\", cbg_Lines, true);\n gridbag.setConstraints(cb_strt, c_line);\n rPanel.add(cb_strt);\n\n\n /* Hermite Curve Checkbox*/\n\n c_line.insets = new Insets(0, 50, 0, 0);\n cb_hermite = new Checkbox(\"Hermite Curved Lines\", cbg_Lines, false);\n gridbag.setConstraints(cb_hermite, c_line);\n rPanel.add(cb_hermite);\n\n\n /* BSpline Curve Checkbox*/\n cb_bspline = new Checkbox(\"B-Spline Curved Lines\", cbg_Lines, false);\n c_line.insets = new Insets(0, 50, 12, 0);\n gridbag.setConstraints(cb_bspline, c_line);\n rPanel.add(cb_bspline);\n\n\n\n\n /*-------------------\n Parameter Text Boxes \n \n Axiom, Ignore, Depth, Angle, Scale\n ------------------*/\n\n GridBagConstraints c_textb = new GridBagConstraints();\n\n /* Axiom */\n c_textb.gridwidth = 1; /* first in row */\n c_textb.anchor = GridBagConstraints.WEST;\n Label label1 = new Label(\"Axiom: \");\n gridbag.setConstraints(label1, c_textb);\n rPanel.add(label1);\n\n\n c_textb.anchor = GridBagConstraints.WEST; /* reset */\n c_textb.gridwidth = GridBagConstraints.REMAINDER;/* last-in-row */\n tb_axiom = new TextField(26);\n gridbag.setConstraints(tb_axiom, c_textb);\n rPanel.add(tb_axiom);\n\n\n /* Ignore */\n c_textb.gridwidth = 1; /* first in row */\n c_textb.anchor = GridBagConstraints.WEST;\n Label label6 = new Label(\"Ignore: \");\n gridbag.setConstraints(label6, c_textb);\n rPanel.add(label6);\n\n c_textb.anchor = GridBagConstraints.WEST; /* reset */\n c_textb.gridwidth = GridBagConstraints.REMAINDER;/* last-in-row */\n tb_ignore = new TextField(26);\n gridbag.setConstraints(tb_ignore, c_textb);\n rPanel.add(tb_ignore);\n\n\n /* Depth */\n c_textb.gridwidth = 1; /* first in row */\n c_textb.anchor = GridBagConstraints.WEST;\n Label label2 = new Label(\"Depth:\");\n gridbag.setConstraints(label2, c_textb);\n rPanel.add(label2);\n\n\n c_textb.anchor = GridBagConstraints.WEST; /* reset */\n tb_depth = new TextField(1);\n gridbag.setConstraints(tb_depth, c_textb);\n rPanel.add(tb_depth);\n\n\n /* Angle */\n c_textb.anchor = GridBagConstraints.WEST; /* reset */\n Label label3 = new Label(\"Angle:\");\n gridbag.setConstraints(label3, c_textb);\n rPanel.add(label3);\n\n\n c_textb.anchor = GridBagConstraints.WEST; /* reset */\n tb_angle = new TextField(3);\n gridbag.setConstraints(tb_angle, c_textb);\n rPanel.add(tb_angle);\n\n\n /* Scale */\n c_textb.anchor = GridBagConstraints.WEST; /* reset */\n Label label4 = new Label(\"Scale:\");\n gridbag.setConstraints(label4, c_textb);\n rPanel.add(label4);\n\n\n c_textb.anchor = GridBagConstraints.WEST; /* reset */\n tb_scale = new TextField(3);\n gridbag.setConstraints(tb_scale, c_textb);\n rPanel.add(tb_scale);\n\n\n\n lPanel.show();\n rPanel.show();\n mPanel.show();\n bPanel.show();\n\n tb_placeholder.hide();\n\n\n ch_ptrnspecs.select(0);\n changeSpecs(ch_ptrnspecs.getSelectedIndex());\n\n\n }",
"private void setupPanel()\n\t{\n\t\tthis.setLayout(baseLayout);\n\t\tthis.add(firstButton);\n\t\tthis.add(firstField);\n\t}",
"private JPanel initializeSubPanel() {\r\n\t\t// create a panel.\r\n\t\tsubPanel = new JPanel();\r\n\t\t// set layout property and add components into.\r\n\t\tsubPanel.setLayout(new GridLayout(1, 2));\r\n\t\tsubPanel.add(initializeMessageField());\r\n\t\tsubPanel.add(initializeSendButton());\r\n\t\treturn subPanel;\r\n\t}",
"public RegisterPanel() {\n initComponents();\n }",
"public BubblePanel()\n\t{\n\t\t// Set the layout to be border-style\n\t\tsuper( new BorderLayout());\n\t\t// Create panel defaults\n\t\tinitPanel();\n\t}",
"ReportGenerationPanel() {\n initComponents();\n reportPanel.setLayout(new GridBagLayout());\n constraints = new GridBagConstraints();\n constraints.fill = GridBagConstraints.BOTH;\n constraints.gridx = 0;\n constraints.gridy = 0;\n constraints.weightx = 1.0;\n glue = Box.createVerticalGlue();\n progressPanel = new ReportProgressPanel();\n }",
"public NetworkPanel() {\n initComponents();\n }",
"public ProductListJPanel() {\n initComponents();\n }",
"private void initPanels() {\r\n\t\r\n\tpanel = new JPanel();\r\n\tpanel.setBounds(0, 0, ScreenSize.WIDTH + 25, ScreenSize.HEIGHT + 50);\r\n\tpanel.setLayout(new BorderLayout());\r\n\tpanel.addComponentListener(this);\r\n\r\n\tbord = new BordPanel();\r\n\tbord.setBounds(0 ,0 ,ScreenSize.WIDTH, ScreenSize.HEIGHT);\r\n\tbord.setOpaque(true);\r\n\r\n\tlabel = new JLabel();\r\n\tlabel.setText(\"Text\");\r\n\r\n\tpanel.add(label, BorderLayout.SOUTH);\r\n\tpanel.add(bord, BorderLayout.CENTER);\r\n\t\r\n\tframe.add(panel);\r\n }",
"public PanelIniciarSesion() {\n initComponents();\n }",
"public WithdrawPanel() {\n initComponents();\n }",
"public MenuPanel() {\n initComponents();\n }",
"public DatosTextFieldPanel() {\n initComponents();\n }",
"public SettingsPanel() {\n initComponents();\n }",
"public CreateAccountPanel() {\n initComponents();\n initializeDateChooser();\n }",
"public PlayerPanel() {\n initComponents();\n\n panel.initializeButtons(\n new javax.swing.JButton[]{addPlayerButton, editPlayerButton, deletePlayerButton},\n new javax.swing.JButton[]{cancelPlayerButton, savePlayerButton}\n );\n }",
"public PanelAccountInfo() {\n initComponents();\n setTextFields();\n setLabels();\n }",
"private void initialize() {\r\n\t\t// set specific properties and add inner components.\r\n\t\tthis.setBorder(BorderFactory.createEtchedBorder());\r\n\t\tthis.setSize(300, 400);\r\n\t\tthis.setLayout(new BorderLayout());\r\n\t\taddComponents();\r\n\t}",
"public TShapePanel() {\r\ncommonInitialization();\r\n }",
"public TitlePanel() {\n\t\tinitComponents();\n\t}",
"public BuildingsPanel() {\n \n player = Player.getInstance();\n buttons = new JButton[8];\n structureData = new Building[10];\n \n initComponents();\n init();\n }",
"public AboutPanel() {\n super();\n initialize();\n }",
"public JPanel buildPanel() {\n\t\tsetLayout(new BorderLayout());\n\t\tsetBackground(ClientConstants.LIGHT_YELLOW);\n\t\tJLabel graphPlotLabel = new JLabel(ClientConstants.GRAPH_PLOT, JLabel.CENTER);\n\t\tgraphPlotLabel.setFont(ClientConstants.TEXT_FONT);\n\t\tadd(graphPlotLabel, BorderLayout.NORTH);\n\t\tsetLayout(new BorderLayout());\n\t\taffectiveGraphPlot = new AffectivePlot();\n\t\tClientDataSingleton.getInstance().setAffectivePlot(affectiveGraphPlot);\n\t\taffectiveGraphPlot.setBackground(Color.WHITE);\n\t\tadd(affectiveGraphPlot);\n\t\treturn this;\n\t}",
"public ProcedureFormPanel() {\n initComponents();\n }",
"private void initComponents() {\r\n\r\n setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);\r\n setTitle(title());\r\n setMinimumSize(new java.awt.Dimension(1000, 500));\r\n\r\n toolsPanel.setLayout(new java.awt.FlowLayout(java.awt.FlowLayout.LEFT));\r\n\r\n channelComboBox.setMinimumSize(new java.awt.Dimension(75, 20));\r\n channelComboBox.setPreferredSize(new java.awt.Dimension(100, 20));\r\n channelComboBox.addActionListener(new java.awt.event.ActionListener() {\r\n public void actionPerformed(java.awt.event.ActionEvent evt) {\r\n channelComboBox_actionPerformed(evt);\r\n }\r\n });\r\n toolsPanel.add(channelComboBox);\r\n\r\n getContentPane().add(toolsPanel, java.awt.BorderLayout.NORTH);\r\n getContentPane().add(tabsPanel, java.awt.BorderLayout.CENTER);\r\n\r\n valuesPanel.setLayout(new javax.swing.BoxLayout(valuesPanel, javax.swing.BoxLayout.Y_AXIS));\r\n getContentPane().add(valuesPanel, java.awt.BorderLayout.EAST);\r\n\r\n pack();\r\n }",
"public PreferencesPanel() {\n initComponents();\n }",
"public PatientPanelPrescription() {\n initComponents();\n set();\n }",
"public CreditsPanel() {\n super(RRConstants.BACKGROUND_COLOR);\n contributorFont = RRConstants.getFont(15);\n\n /* this is a useful helper variable used to position elements in\n aesthetically pleasing places in the CreditsPanel */\n int increment = RRConstants.HEIGHT/10;\n\n // title of the CreditsPanel\n JLabel credits = makeText(\"CREDITS\", nameFont);\n \n // the first section of the JPanel - represents the names of creators\n JLabel creatorSubtitle = makeText(\"Created by:\", buttonFont);\n JLabel creatorText = makeText(\n \"<html><center>Isabel Bryant,<br>\" + \n \"Hunter Sessa,<br>\" + \n \"Mara Steiu &<br>\" + \n \"Angelina Li</html>\", textFont);\n\n // second section of the JPanel - represents names of contributors\n JLabel contributorSubtitle = makeText(\"Thanks to:\", buttonFont);\n JLabel contributorText = makeText(\n \"<html><center>Ada & Takis,<br>\" + \n \"This: bit.ly/sojavaswing,<br>\" + \n \"and CS230 for teaching us <br>\" + \n \"how to make our game.</html>\", contributorFont);\n\n //setting up backButton - getButton is a method inherited from TextPanel\n backButton = getButton(\"BACK TO MENU\", BACK_COLOR, new ButtonListener());\n \n /* adding each component to the CreditsPanel, using the addComponent \n method inherited from TextPanel */\n addComponent(credits, RRConstants.HEIGHT/6);\n addComponent(creatorSubtitle, RRConstants.HEIGHT/5 + increment);\n addComponent(creatorText, RRConstants.HEIGHT/5 + (3*increment/2));\n addComponent(contributorSubtitle, RRConstants.HEIGHT/2 + increment/2);\n addComponent(contributorText, RRConstants.HEIGHT/2 + increment);\n addComponent(backButton, RRConstants.HEIGHT - RRConstants.HEIGHT/6 - increment);\n }",
"public studentsPanel() {\n initComponents();\n String no = String.valueOf(sNum.studentID);\n String name = String.valueOf(sNum.studentName);\n lblStudentID.setText(name);\n delivery();\n lblTakeBookLimit.setText(new texts().bookLimit() + takeBookLimit + \" )\");\n List();\n }",
"public PaperSettingsJPanel() {\n initComponents();\n }",
"private void initialize() {\r\n\t\r\n\t\tpanel = new JPanel();\r\n\t\tpanel.setBounds(0, 0, 300, 100);\r\n\t\tpanel.setLayout(null);\r\n\t\t\r\n\t\ttxtQas = new JTextField();\r\n\t\ttxtQas.setToolTipText(\"\");\r\n\t\ttxtQas.setBounds(124, 11, 166, 20);\r\n\t\tpanel.add(txtQas);\r\n\t\ttxtQas.setColumns(10);\r\n\t\t\r\n\t\tJLabel lblId = new JLabel(\"ID: \");\r\n\t\tlblId.setBounds(10, 14, 46, 14);\r\n\t\tpanel.add(lblId);\r\n\t\t\r\n\t\tbtnExcluirItem = new JButton(\"Excluir Item\");\r\n\t\tbtnExcluirItem.setBounds(10, 70, 99, 23);\r\n\t\tpanel.add(btnExcluirItem);\r\n\r\n\t}",
"private void createComponents() {\n\n add(createSetDataPanel(), BorderLayout.NORTH);\n add(createResourcesListAndButtonsPanel(), BorderLayout.CENTER);\n }",
"private void initComponent() {\n\t\taddGrid();\n\t\taddToolBars();\n\t}",
"private void initMyComponents() {\n this.jPanel1.setLayout(new BoxLayout(this.jPanel1, BoxLayout.Y_AXIS));\n this.jPanel1.add(controller.getPressureController().getEMeasureBasicView());\n this.jPanel1.add(controller.getTemperatureController().getEMeasureBasicView());\n this.controller.getPressureController().getListeners().add(this);\n this.controller.getTemperatureController().getListeners().add(this);\n this.jComboBox1.setModel(new DefaultComboBoxModel(FluidKind.values()));\n this.changeResponce();\n }",
"public MainMenuPanel() {\n\t\tinitComponents();\n\t}",
"public MyPanel(int x,int y,int width,int height){\r\n\t\tsetBounds(x,y,width,height);}",
"public AuthenticationPanel() {\n\t\tsuper();\n\t\tinitComponents();\n\t\tinitComponents2();\n\t}",
"private Panel designPanel() {\n Panel panel = new Panel();\n contentLayout = new FormLayout();\n wrapperLayout = new VerticalLayout();\n numberOfDatasetsBox = new ComboBox<>();\n numberOfReplicatesBox = new ComboBox<>(\"Select number of Replicates\");\n\n\n List<Integer> possibleDatasetNumber =\n IntStream.rangeClosed(1, 100).boxed().collect(Collectors.toList());\n numberOfDatasetsBox.setItems(possibleDatasetNumber);\n\n List<Integer> possibleReplicateNumber =\n IntStream.rangeClosed(1, 100).boxed().collect(Collectors.toList());\n numberOfReplicatesBox.setItems(possibleReplicateNumber);\n\n datasetAccordion = new Accordion();\n datasetAccordion.setWidth(\"100%\");\n\n panel.setContent(wrapperLayout);\n return panel;\n }",
"private void initComponents() {\n\t\t\n\t}",
"private void initComponents() {\n\t\t\n\t}",
"public SearchResultPanel()\n\t{\n\t\tcreateComponents();\n\t\tdesignComponents();\n\t\taddComponents();\n\t}",
"public HashDbSimplePanel() {\n initComponents();\n customizeComponents();\n }",
"private void initComponents() {\n\n scenePanel = new javax.swing.JPanel();\n\n setLayout(new javax.swing.BoxLayout(this, javax.swing.BoxLayout.PAGE_AXIS));\n\n scenePanel.setLayout(new javax.swing.BoxLayout(scenePanel, javax.swing.BoxLayout.LINE_AXIS));\n add(scenePanel);\n }",
"public RegisterPanel() {\n control = new ControlRegister();\n initComponents();\n }",
"public BankPanel() {\r\n\t super();\r\n\t}",
"private void initComponents() {\r\n\r\n setLayout(new java.awt.BorderLayout());\r\n }",
"public PanelControl() {\r\n initComponents();\r\n VersionEImageIcon versionEImageIcon = new VersionEImageIcon();\r\n versionEImageIcon.newColorFromPanel(panelColor);\r\n jLabel1.setText(INFO_LABEL);\r\n Usuario usuarioTipo = Login.getUsuario();\r\n this.administrador = usuarioTipo.isAdmin();\r\n if (!administrador)\r\n {\r\n rangos.setEnabled(false);\r\n controles.setEnabled(false);\r\n alta_usuarios.setEnabled(false);\r\n verificacion.setEnabled(false);\r\n }\r\n }",
"private void initComponents() {\n java.awt.GridBagConstraints gridBagConstraints;\n\n javax.swing.JLabel subjectLabel = new javax.swing.JLabel();\n subjectComponent = new javax.swing.JTextArea();\n javax.swing.JLabel holderLabel = new javax.swing.JLabel();\n javax.swing.JScrollPane holderScrollPane = new javax.swing.JScrollPane();\n holderComponent = new javax.swing.JTextArea();\n javax.swing.JLabel issuerLabel = new javax.swing.JLabel();\n javax.swing.JScrollPane issuerScrollPane = new javax.swing.JScrollPane();\n issuerComponent = new javax.swing.JTextArea();\n javax.swing.JLabel issuedLabel = new javax.swing.JLabel();\n issuedComponent = new javax.swing.JTextArea();\n javax.swing.JLabel notBeforeLabel = new javax.swing.JLabel();\n notBeforeComponent = new javax.swing.JTextArea();\n javax.swing.JLabel notAfterLabel = new javax.swing.JLabel();\n notAfterComponent = new javax.swing.JTextArea();\n javax.swing.JLabel consumerLabel = new javax.swing.JLabel();\n consumerComponent = new javax.swing.JTextArea();\n javax.swing.JLabel infoLabel = new javax.swing.JLabel();\n javax.swing.JScrollPane infoScrollPane = new javax.swing.JScrollPane();\n infoComponent = new javax.swing.JTextArea();\n\n setBorder(javax.swing.BorderFactory.createCompoundBorder(javax.swing.BorderFactory.createTitledBorder(format(LicenseWizardMessage.display_title)), javax.swing.BorderFactory.createEmptyBorder(10, 10, 10, 10))); // NOI18N\n setName(DisplayPanel.class.getSimpleName());\n setLayout(new java.awt.GridBagLayout());\n\n subjectLabel.setLabelFor(subjectComponent);\n subjectLabel.setText(format(LicenseWizardMessage.display_subject)); // NOI18N\n gridBagConstraints = new java.awt.GridBagConstraints();\n gridBagConstraints.gridx = 0;\n gridBagConstraints.gridy = 0;\n gridBagConstraints.ipadx = 5;\n gridBagConstraints.anchor = java.awt.GridBagConstraints.BASELINE_TRAILING;\n add(subjectLabel, gridBagConstraints);\n\n subjectComponent.setEditable(false);\n subjectComponent.setFont(getFont());\n subjectComponent.setBorder(javax.swing.BorderFactory.createEtchedBorder());\n subjectComponent.setName(LicenseWizardMessage.display_subject.name());\n gridBagConstraints = new java.awt.GridBagConstraints();\n gridBagConstraints.gridx = 1;\n gridBagConstraints.gridy = 0;\n gridBagConstraints.fill = java.awt.GridBagConstraints.BOTH;\n gridBagConstraints.anchor = java.awt.GridBagConstraints.BASELINE_LEADING;\n gridBagConstraints.weightx = 1.0;\n gridBagConstraints.weighty = 1.0;\n add(subjectComponent, gridBagConstraints);\n\n holderLabel.setLabelFor(holderComponent);\n holderLabel.setText(format(LicenseWizardMessage.display_holder)); // NOI18N\n gridBagConstraints = new java.awt.GridBagConstraints();\n gridBagConstraints.gridx = 0;\n gridBagConstraints.gridy = 1;\n gridBagConstraints.ipadx = 5;\n gridBagConstraints.anchor = java.awt.GridBagConstraints.BASELINE_TRAILING;\n add(holderLabel, gridBagConstraints);\n\n holderScrollPane.setBorder(javax.swing.BorderFactory.createEtchedBorder());\n holderScrollPane.setHorizontalScrollBarPolicy(javax.swing.ScrollPaneConstants.HORIZONTAL_SCROLLBAR_NEVER);\n holderScrollPane.setPreferredSize(new java.awt.Dimension(300, 65));\n\n holderComponent.setEditable(false);\n holderComponent.setFont(getFont());\n holderComponent.setLineWrap(true);\n holderComponent.setWrapStyleWord(true);\n holderComponent.setBorder(null);\n holderComponent.setName(LicenseWizardMessage.display_holder.name());\n holderScrollPane.setViewportView(holderComponent);\n\n gridBagConstraints = new java.awt.GridBagConstraints();\n gridBagConstraints.gridx = 1;\n gridBagConstraints.gridy = 1;\n gridBagConstraints.fill = java.awt.GridBagConstraints.BOTH;\n gridBagConstraints.anchor = java.awt.GridBagConstraints.BASELINE_LEADING;\n gridBagConstraints.weightx = 1.0;\n gridBagConstraints.weighty = 1.0;\n add(holderScrollPane, gridBagConstraints);\n\n issuerLabel.setLabelFor(issuerComponent);\n issuerLabel.setText(format(LicenseWizardMessage.display_issuer)); // NOI18N\n gridBagConstraints = new java.awt.GridBagConstraints();\n gridBagConstraints.gridx = 0;\n gridBagConstraints.gridy = 2;\n gridBagConstraints.ipadx = 5;\n gridBagConstraints.anchor = java.awt.GridBagConstraints.BASELINE_TRAILING;\n add(issuerLabel, gridBagConstraints);\n\n issuerScrollPane.setBorder(javax.swing.BorderFactory.createEtchedBorder());\n issuerScrollPane.setHorizontalScrollBarPolicy(javax.swing.ScrollPaneConstants.HORIZONTAL_SCROLLBAR_NEVER);\n issuerScrollPane.setPreferredSize(new java.awt.Dimension(300, 65));\n\n issuerComponent.setEditable(false);\n issuerComponent.setFont(getFont());\n issuerComponent.setLineWrap(true);\n issuerComponent.setWrapStyleWord(true);\n issuerComponent.setBorder(null);\n issuerComponent.setName(LicenseWizardMessage.display_issuer.name());\n issuerScrollPane.setViewportView(issuerComponent);\n\n gridBagConstraints = new java.awt.GridBagConstraints();\n gridBagConstraints.gridx = 1;\n gridBagConstraints.gridy = 2;\n gridBagConstraints.fill = java.awt.GridBagConstraints.BOTH;\n gridBagConstraints.anchor = java.awt.GridBagConstraints.BASELINE_LEADING;\n gridBagConstraints.weightx = 1.0;\n gridBagConstraints.weighty = 1.0;\n add(issuerScrollPane, gridBagConstraints);\n\n issuedLabel.setLabelFor(issuedComponent);\n issuedLabel.setText(format(LicenseWizardMessage.display_issued)); // NOI18N\n gridBagConstraints = new java.awt.GridBagConstraints();\n gridBagConstraints.gridx = 0;\n gridBagConstraints.gridy = 3;\n gridBagConstraints.ipadx = 5;\n gridBagConstraints.anchor = java.awt.GridBagConstraints.BASELINE_TRAILING;\n add(issuedLabel, gridBagConstraints);\n\n issuedComponent.setEditable(false);\n issuedComponent.setFont(getFont());\n issuedComponent.setBorder(javax.swing.BorderFactory.createEtchedBorder());\n issuedComponent.setName(LicenseWizardMessage.display_issued.name());\n gridBagConstraints = new java.awt.GridBagConstraints();\n gridBagConstraints.gridx = 1;\n gridBagConstraints.gridy = 3;\n gridBagConstraints.fill = java.awt.GridBagConstraints.BOTH;\n gridBagConstraints.anchor = java.awt.GridBagConstraints.BASELINE_LEADING;\n gridBagConstraints.weightx = 1.0;\n gridBagConstraints.weighty = 1.0;\n add(issuedComponent, gridBagConstraints);\n\n notBeforeLabel.setLabelFor(notBeforeComponent);\n notBeforeLabel.setText(format(LicenseWizardMessage.display_notBefore)); // NOI18N\n gridBagConstraints = new java.awt.GridBagConstraints();\n gridBagConstraints.gridx = 0;\n gridBagConstraints.gridy = 4;\n gridBagConstraints.ipadx = 5;\n gridBagConstraints.anchor = java.awt.GridBagConstraints.BASELINE_TRAILING;\n add(notBeforeLabel, gridBagConstraints);\n\n notBeforeComponent.setEditable(false);\n notBeforeComponent.setFont(getFont());\n notBeforeComponent.setBorder(javax.swing.BorderFactory.createEtchedBorder());\n notBeforeComponent.setName(LicenseWizardMessage.display_notBefore.name());\n gridBagConstraints = new java.awt.GridBagConstraints();\n gridBagConstraints.gridx = 1;\n gridBagConstraints.gridy = 4;\n gridBagConstraints.fill = java.awt.GridBagConstraints.BOTH;\n gridBagConstraints.anchor = java.awt.GridBagConstraints.BASELINE_LEADING;\n gridBagConstraints.weightx = 1.0;\n gridBagConstraints.weighty = 1.0;\n add(notBeforeComponent, gridBagConstraints);\n\n notAfterLabel.setLabelFor(notAfterComponent);\n notAfterLabel.setText(format(LicenseWizardMessage.display_notAfter)); // NOI18N\n gridBagConstraints = new java.awt.GridBagConstraints();\n gridBagConstraints.gridx = 0;\n gridBagConstraints.gridy = 5;\n gridBagConstraints.ipadx = 5;\n gridBagConstraints.anchor = java.awt.GridBagConstraints.BASELINE_TRAILING;\n add(notAfterLabel, gridBagConstraints);\n\n notAfterComponent.setEditable(false);\n notAfterComponent.setFont(getFont());\n notAfterComponent.setBorder(javax.swing.BorderFactory.createEtchedBorder());\n notAfterComponent.setName(LicenseWizardMessage.display_notAfter.name());\n gridBagConstraints = new java.awt.GridBagConstraints();\n gridBagConstraints.gridx = 1;\n gridBagConstraints.gridy = 5;\n gridBagConstraints.fill = java.awt.GridBagConstraints.BOTH;\n gridBagConstraints.anchor = java.awt.GridBagConstraints.BASELINE_LEADING;\n gridBagConstraints.weightx = 1.0;\n gridBagConstraints.weighty = 1.0;\n add(notAfterComponent, gridBagConstraints);\n\n consumerLabel.setLabelFor(consumerComponent);\n consumerLabel.setText(format(LicenseWizardMessage.display_consumer)); // NOI18N\n gridBagConstraints = new java.awt.GridBagConstraints();\n gridBagConstraints.gridx = 0;\n gridBagConstraints.gridy = 6;\n gridBagConstraints.ipadx = 5;\n gridBagConstraints.anchor = java.awt.GridBagConstraints.BASELINE_TRAILING;\n add(consumerLabel, gridBagConstraints);\n\n consumerComponent.setEditable(false);\n consumerComponent.setFont(getFont());\n consumerComponent.setBorder(javax.swing.BorderFactory.createEtchedBorder());\n consumerComponent.setName(LicenseWizardMessage.display_consumer.name());\n gridBagConstraints = new java.awt.GridBagConstraints();\n gridBagConstraints.gridx = 1;\n gridBagConstraints.gridy = 6;\n gridBagConstraints.fill = java.awt.GridBagConstraints.BOTH;\n gridBagConstraints.anchor = java.awt.GridBagConstraints.BASELINE_LEADING;\n gridBagConstraints.weightx = 1.0;\n gridBagConstraints.weighty = 1.0;\n add(consumerComponent, gridBagConstraints);\n\n infoLabel.setLabelFor(infoComponent);\n infoLabel.setText(format(LicenseWizardMessage.display_info)); // NOI18N\n gridBagConstraints = new java.awt.GridBagConstraints();\n gridBagConstraints.gridx = 0;\n gridBagConstraints.gridy = 7;\n gridBagConstraints.ipadx = 5;\n gridBagConstraints.anchor = java.awt.GridBagConstraints.BASELINE_TRAILING;\n add(infoLabel, gridBagConstraints);\n\n infoScrollPane.setBorder(javax.swing.BorderFactory.createEtchedBorder());\n infoScrollPane.setHorizontalScrollBarPolicy(javax.swing.ScrollPaneConstants.HORIZONTAL_SCROLLBAR_NEVER);\n infoScrollPane.setPreferredSize(new java.awt.Dimension(300, 65));\n\n infoComponent.setEditable(false);\n infoComponent.setFont(getFont());\n infoComponent.setLineWrap(true);\n infoComponent.setWrapStyleWord(true);\n infoComponent.setBorder(null);\n infoComponent.setName(LicenseWizardMessage.display_info.name());\n infoScrollPane.setViewportView(infoComponent);\n\n gridBagConstraints = new java.awt.GridBagConstraints();\n gridBagConstraints.gridx = 1;\n gridBagConstraints.gridy = 7;\n gridBagConstraints.fill = java.awt.GridBagConstraints.BOTH;\n gridBagConstraints.anchor = java.awt.GridBagConstraints.BASELINE_LEADING;\n gridBagConstraints.weightx = 1.0;\n gridBagConstraints.weighty = 1.0;\n add(infoScrollPane, gridBagConstraints);\n }",
"public PanelConBoton() {\n initComponents();\n }"
] | [
"0.74472696",
"0.72496843",
"0.71572703",
"0.7130536",
"0.7022037",
"0.6991024",
"0.69427335",
"0.6876838",
"0.6876838",
"0.68492734",
"0.68369573",
"0.6804456",
"0.6788915",
"0.67844343",
"0.67790645",
"0.67775744",
"0.6744906",
"0.67391115",
"0.6738539",
"0.6731661",
"0.6726683",
"0.6723911",
"0.6721521",
"0.67162186",
"0.67084515",
"0.6706798",
"0.67017287",
"0.66992253",
"0.66987914",
"0.6661983",
"0.6639173",
"0.6638372",
"0.6629459",
"0.6621647",
"0.66000664",
"0.65997016",
"0.6584046",
"0.65659356",
"0.6557594",
"0.6544577",
"0.6531167",
"0.652722",
"0.6526489",
"0.6525391",
"0.6524895",
"0.6522298",
"0.65215373",
"0.65180117",
"0.65091807",
"0.6508738",
"0.6508291",
"0.6507853",
"0.650165",
"0.6501251",
"0.64892",
"0.6488289",
"0.64782166",
"0.6468351",
"0.64669204",
"0.6462844",
"0.646154",
"0.6458961",
"0.64577824",
"0.6455784",
"0.6455233",
"0.64452595",
"0.6444984",
"0.6440926",
"0.64403844",
"0.6437255",
"0.64286613",
"0.6418851",
"0.64074135",
"0.63919973",
"0.6383881",
"0.6381801",
"0.63802505",
"0.6374206",
"0.6371076",
"0.63676286",
"0.6366094",
"0.63647234",
"0.63572043",
"0.6354817",
"0.6351545",
"0.63506705",
"0.63481814",
"0.6345764",
"0.63394195",
"0.63301915",
"0.6327093",
"0.6327093",
"0.6322084",
"0.6312962",
"0.6309277",
"0.6306124",
"0.6304704",
"0.63046163",
"0.6299634",
"0.62967926",
"0.629629"
] | 0.0 | -1 |
Helper method for the Constructor used to set parameters for all of the unique buttons. | private void setupButtons()
{
equals.setText("=");
equals.setBackground(Color.RED);
equals.setForeground(Color.WHITE);
equals.setOpaque(true);
equals.setFont(new Font("Lucida Grande", Font.PLAIN, 50));
equals.setBorder(new CompoundBorder(new LineBorder(Color.LIGHT_GRAY, 5), new LineBorder(Color.BLACK, 3)));
clear.setText("C");
clear.setBackground(new Color(0, 170, 100));
clear.setForeground(Color.WHITE);
clear.setOpaque(true);
clear.setFont(new Font("Lucida Grande", Font.PLAIN, 50));
clear.setBorder(new CompoundBorder(new LineBorder(Color.LIGHT_GRAY, 5), new LineBorder(Color.BLACK, 3)));
backspace.setText("<--");
backspace.setBackground(new Color(0, 170, 100));
backspace.setForeground(Color.WHITE);
backspace.setOpaque(true);
backspace.setFont(new Font("Lucida Grande", Font.PLAIN, 35));
backspace.setBorder(new CompoundBorder(new LineBorder(Color.LIGHT_GRAY, 5), new LineBorder(Color.BLACK, 3)));
negative.setText("+/-");
negative.setBackground(Color.GRAY);
negative.setForeground(Color.WHITE);
negative.setOpaque(true);
negative.setFont(new Font("Lucida Grande", Font.PLAIN, 35));
negative.setBorder(new CompoundBorder(new LineBorder(Color.LIGHT_GRAY, 5), new LineBorder(Color.BLACK, 3)));
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"private ButtonEnum(int numberOfJoystick, int numberOfButton) {\n buttonNum = numberOfButton; \n joystickNum = numberOfJoystick;\n }",
"public abstract void initButton(int buttonIndex);",
"private ButtonPane()\r\n\t\t\t{ super(new String[]{\"OK\",\"Cancel\"},1,2); }",
"public PacManUiBuilder() {\n this.defaultButtons = false;\n this.buttons = new LinkedHashMap<>();\n this.keyMappings = new HashMap<>();\n }",
"public void createButtons() {\n\t\tbutton1 = new JButton(\"Button1\");\n\t\tbutton2 = new JButton(\"Button2\");\n\t\tbutton3 = new JButton(\"Button3\");\n\t\tbutton4 = new JButton(\"Button4\");\n\t\tbutton5 = new JButton(\"Button5\");\n\t}",
"public Button(String name, Page page) {\r\n super(name);\r\n this.page = page;\r\n //assignedParameters = new HashMap();\r\n //assignedParameters.put(this.name, Button.EMPTY);\r\n //assignedParameters.put(this.name+\".x\", Button.EMPTY);\r\n addExcludeParam(this.name);\r\n addExcludeParam(this.name+\".x\");\r\n addExcludeParam(this.name+\".y\");\r\n }",
"public void init() {\r\n\r\n add(btnUn);\r\n add(btnDeux);\r\n add(btnTrois);\r\n add(btnQuatre);\r\n add(btnCinq);\r\n\r\n btnUn.setBounds(120, 120, 100, 75);\r\n btnDeux.setBounds(120, 310, 100, 75);\r\n btnDeux.setTransferHandler(new TransferHandler(\"icon\"));\r\n btnTrois.setBounds(360, 310, 100, 75);\r\n btnQuatre.setBounds(160, 600, 100, 75);\r\n btnQuatre.setTransferHandler(new TransferHandler(\"icon\"));\r\n btnCinq.setBounds(360, 600, 100, 75);\r\n\r\n }",
"private void setupButtons() {\n\t\tsetupCreateCourse();\n\t\tsetupRemoveCourse();\n\t\tsetupCreateOffering();\n\t\tsetupRemoveOffering();\n\t\tsetupAddPreReq();\n\t\tsetupRemovePreReq();\n\t\tsetupBack();\n\t}",
"private void initBtnsArray()\r\n {\r\n for (int i = 0; i < this.buttons.length; i++)\r\n this.buttons[i] = new Button(\"Button #\" + i);\r\n }",
"private void generateButtons(){\n\t\tint coordX = ThreadLocalRandom.current().nextInt(0, 16);\n\t\tint coordY = ThreadLocalRandom.current().nextInt(0, 16);\n\t\t//Button button = new Button(coordX, coordY);\n\t\t//buttons.put(0, button);\n\t}",
"public CompoundButton(IButton... buttons) {\n\t\tthis.buttons = buttons;\n\t\twasDown = false;\n\t}",
"private void createUIComponents() {\n bt1 = new JButton(\"Hola\");\n }",
"private void buttonInit() {\n panel.add(createButton);\n panel.add(editButton);\n panel.add(changeButton);\n createButton.addActionListener(this);\n editButton.addActionListener(this);\n changeButton.addActionListener(this);\n submitNewUser.addActionListener(this);\n editAccTypeBtn.addActionListener(this);\n changePassBtn.addActionListener(this);\n }",
"@Override\n public void initialiseButtons() {\n resumeButton = new Button(buttonLeft, resumeButtonTop, buttonRight, resumeButtonBottom, Assets.resume);\n restartButton = new Button(buttonLeft, restartButtonTop, buttonRight, restartButtonBottom, Assets.restart);\n instructionsButton = new Button(buttonLeft, instructionsButtonTop, buttonRight, instructionsButtonBottom, Assets.instructions);\n quitButton = new Button(buttonLeft, quitButtonTop, buttonRight, quitButtonBottom, Assets.quit);\n backArrowButton = new Button(-8,-10,120,100, Assets.backArrowButton);\n saveGameButton = new Button(buttonLeft,saveGameButtonTop,buttonRight,saveGameButtonBottom,Assets.saveGame);\n }",
"void set_buttons(){\n\n int button_count = 5;\n\n button_data_set = new ArrayList(button_count);\n\n try {\n\n JSONObject btn1 = new JSONObject();\n btn1.put(\"title\", \"Button1\");\n button_data_set.add(btn1);\n\n JSONObject btn2 = new JSONObject();\n btn1.put(\"title\", \"Button2\");\n button_data_set.add(btn2);\n\n JSONObject btn3 = new JSONObject();\n btn1.put(\"title\", \"Button3\");\n button_data_set.add(btn3);\n\n JSONObject btn4 = new JSONObject();\n btn1.put(\"title\", \"Button4\");\n button_data_set.add(btn4);\n\n JSONObject btn5 = new JSONObject();\n btn1.put(\"title\", \"Button5\");\n button_data_set.add(btn5);\n\n }catch(Exception e){\n e.printStackTrace();\n }\n\n Common.ButtonsCount = button_count;\n }",
"public ButtonRequests() {\r\n this(null);\r\n }",
"private void init(){\r\n\t\tImageIcon newTaskImg = new ImageIcon(\"resources/images/New.png\");\r\n\t\tImageIcon pauseImg = new ImageIcon(\"resources/images/Pause.png\");\r\n\t\tImageIcon resumeImg = new ImageIcon (\"resources/images/Begin.png\");\r\n\t\tImageIcon stopImg = new ImageIcon(\"resources/images/Stop.png\");\r\n\t\tImageIcon removeImg = new ImageIcon(\"resources/images/Remove.gif\");\r\n\t\tImageIcon shareImg = new ImageIcon(\"resources/images/Share.png\");\r\n\t\tImageIcon inboxImg = new ImageIcon(\"resources/images/Inbox.png\");\r\n\t\t\r\n\t\tnewTask = new JButton(newTaskImg);\r\n\t\tnewTask.setToolTipText(\"New Task\");\r\n\t\tpause = new JButton (pauseImg);\r\n\t\tpause.setToolTipText(\"Pause\");\r\n\t\trestart = new JButton (resumeImg);\r\n\t\trestart.setToolTipText(\"Restart\");\r\n\t\tstop = new JButton(stopImg);\r\n\t\tstop.setToolTipText(\"Stop\");\r\n\t\tremove = new JButton(removeImg);\r\n\t\tremove.setToolTipText(\"Remove\");\r\n\t\tshare = new JButton(shareImg);\r\n\t\tshare.setToolTipText(\"Share\");\r\n\t\tinbox = new JButton(inboxImg);\r\n\t\tinbox.setToolTipText(\"Inbox\");\r\n\t\t\r\n\t}",
"public Controls()\n {\n string = \"Controls\";\n getButtonImage();\n }",
"public LWButton01() {\n\t\t//Invoke the parameterized constructor with an \n\t\t// empty string\n\t\tthis(\"\");\n\t}",
"private void createButton() {\n\t\tbtnAddTask = new JButton(\"Add Task\");\n\t\tbtnSave = new JButton(\"Save\");\n\t\tbtnCancel = new JButton(\"Cancel\");\n\n\t\tbtnAddTask.addActionListener(new ToDoAction());\n\t\tbtnSave.addActionListener(new ToDoAction());\n\t\tbtnCancel.addActionListener(new ToDoAction());\n\t}",
"public URLButton()\n {\n title = \"\";\n }",
"public OptionPanel(Main w) {\r\n\t\tthis.w = w;\r\n\t\tstartButton = new JButton();\r\n\t\texitButton = new JButton();\r\n\t\t\r\n\t}",
"private void setButtons()\n\t{\n\t\tstartSim = new JButton(\"Start Sim\");\n\t\tstartSim.addActionListener(this);\n\t\tpauseSim = new JButton(\"Pause Sim\");\n\t\tpauseSim.addActionListener(this);\n\t\taddEat = new JButton(\"Add Eatery\");\n\t\taddEat.addActionListener(this);\n\t\tsubEat = new JButton(\"Subtract Eatery\");\n\t\tsubEat.addActionListener(this);\n\t\taddCash = new JButton(\"Add Cashier\");\n\t\taddCash.addActionListener(this);\n\t\tsubCash = new JButton(\"Subtract Cashier\");\n\t\tsubCash.addActionListener(this);\n\t}",
"private void initButton() {\r\n\t\tthis.panelButton = new JPanel();\r\n\t\tthis.panelButton.setLayout(new BoxLayout(this.panelButton,\r\n\t\t\t\tBoxLayout.LINE_AXIS));\r\n\t\tthis.modifyButton = new JButton(\"Modify\");\r\n\t\tthis.buttonSize(this.modifyButton);\r\n\t\tthis.deleteButton = new JButton(\"Delete\");\r\n\t\tthis.buttonSize(this.deleteButton);\r\n\t\tthis.cancelButton = new JButton(\"Cancel\");\r\n\t\tthis.buttonSize(this.cancelButton);\r\n\r\n\t\tthis.modifyButton.addActionListener(this.editWeaponControl);\r\n\t\tthis.deleteButton.addActionListener(this.editWeaponControl);\r\n\t\tthis.cancelButton.addActionListener(this.editWeaponControl);\r\n\r\n\t\tthis.panelButton.add(this.modifyButton);\r\n\t\tthis.panelButton.add(Box.createRigidArea(new Dimension(15, 0)));\r\n\t\tthis.panelButton.add(this.deleteButton);\r\n\t\tthis.panelButton.add(Box.createRigidArea(new Dimension(15, 0)));\r\n\t\tthis.panelButton.add(this.cancelButton);\r\n\t}",
"public void initialize() {\n\t\tbombLabel.setText(\"Flag: \" + game.getFlagCounter() + \"/\" + game.getNumOfBombs());\n\t\ttimerLabel.setText(\"Time: \" + 0);\n\t\tboard.getStyleClass().add(\"grid\");\n\t\tbtnArray = new Button[game.getHeight()][game.getWidth()];\n\t\tfor (int x = 0; x < game.getHeight(); x++) {\n\t\t\tfor (int y = 0; y < game.getWidth(); y++) {\n\t\t\t\tButton btn = new Button(\"\");\n\t\t\t\tbtnArray[x][y] = btn;\n\t\t\t\tbtn.setMaxSize(50, 50);\n\t\t\t\tbtn.setMinSize(50, 50);\n\t\t\t\t//Add Button to the board (GridPane)\n\t\t\t\tboard.add(btn, x, y);\n\t\t\t\tbtn.setId(x + \" . \" + y);\n\t\t\t\tbtn.setOnMouseClicked(e -> TileClicked(e));\n\t\t\t}\n\t\t}\n\t}",
"public ButtonPanel(ModelController c, ArrayList<Turtle> t) {\n\tsliderCurrent = 5;\n\tCONTROLLER = c;\n\tTURTLE = t;\n\tmakeUpButton();\n\tmakeDownButton();\n\tmakeLeftButton();\n }",
"public BaseButton(Command command, int... codes) {\n\t\tthis.command = command;\n\t\tthis.codes = codes;\n\t\twasDown = false;\n\t}",
"private void initialize() {\r\n\r\n // add default buttons\r\n addButton(getToggleButton(),\"toggle\");\r\n addButton(getFinishButton(),\"finish\");\r\n addButton(getCancelButton(),\"cancel\");\r\n addActionListener(new ActionListener() {\r\n\r\n public void actionPerformed(ActionEvent e) {\r\n String cmd = e.getActionCommand();\r\n if(\"toggle\".equalsIgnoreCase(cmd)) change();\r\n else if(\"finish\".equalsIgnoreCase(cmd)) finish();\r\n else if(\"cancel\".equalsIgnoreCase(cmd)) cancel();\r\n }\r\n\r\n });\r\n\r\n }",
"Button(int x, int y, int w, int h, String label, int c){\n this.x = x;\n this.y = y;\n this.w = w;\n this.h = h;\n this.label = label;\n this.col = c;\n }",
"public Button(String name, int x, int y, int L, int l, ValueNeeded object) {\n\t\tthis.nameField = name;\n\t\tthis.setBounds(x, y, L, l);\n\t\tthis.setText(nameField);\n\t\tif (name.equals(\"-\") || name.equals(\"X\") || name.equals(\"<\") || name.equals(\"Forgot Password ?\")\n\t\t\t\t|| name.equals(\"Register Here !\")) {\n\t\t\tthis.setContentAreaFilled(false);\n\t\t\tthis.setOpaque(false);\n\t\t\tthis.setBorder(new LineBorder(Color.DARK_GRAY));\n\t\t\tif (name.equals(\"X\")) {\n\t\t\t\tthis.setFont(new Font(\"Rockwell Nova\", Font.BOLD, 17));\n\t\t\t} else if (name.equals(\"Forgot Password ?\") || name.equals(\"Register Here !\")) {\n\t\t\t\tthis.setBorderPainted(false);\n\t\t\t\tthis.setForeground(Color.DARK_GRAY);\n\t\t\t\tif (name.equals(\"Forgot Password ?\")) {\n\t\t\t\t\tthis.setFont(new Font(\"Rockwell Nova\", Font.PLAIN, 10));\n\t\t\t\t} else {\n\t\t\t\t\tthis.setFont(new Font(\"Rockwell Nova\", Font.BOLD, 10));\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\tthis.setFont(new Font(\"Rockwell Nova\", Font.BOLD, 30));\n\t\t\t}\n\t\t} else if (name.equals(\"Login\") || name.equals(\"Register\") || name.equals(\"Send Password\")\n\t\t\t\t|| name.equals(\"Login Page\") || name.equals(\"Modify Datas\") || name.equals(\"Modify Password\")\n\t\t\t\t|| name.equals(\"Save Datas\")|| name.equals(\"Save Password\")) {\n\t\t\tthis.setBorder(BorderFactory.createBevelBorder(0));\n\t\t\tthis.setFont(new Font(\"Rockwell Nova\", Font.PLAIN, 15));\n\t\t\tthis.setForeground(new Color(255, 255, 255));\n\t\t\tthis.setBackground(new Color(72, 209, 204));\n\t\t}\n\t\tthis.addActionListener(new ButtonListener(name, object)); // We add actionListener to all the buttons\n\t}",
"private void initCommandButtons(char[] levelLetters) {\n\t\tthis.btnTopFirst = (Button) findViewById(R.id.buttonTopFirst);\n\t\tthis.btnTopSecond = (Button) findViewById(R.id.buttonTopSecond);\n\t\tthis.btnTopThird = (Button) findViewById(R.id.buttonTopThird);\n\t\tthis.btnTopFourth = (Button) findViewById(R.id.buttonTopFourth);\n\n\t\tthis.btnBotFirst = (Button) findViewById(R.id.buttonBotFirst);\n\t\tthis.btnBotSecond = (Button) findViewById(R.id.buttonBotSecond);\n\t\tthis.btnBotThird = (Button) findViewById(R.id.buttonBotThird);\n\t\tthis.btnBotFourth = (Button) findViewById(R.id.buttonBotFourth);\n\t\tthis.letterButtons = new Button[] { btnBotFirst, btnBotSecond,\n\t\t\t\tbtnBotThird, btnBotFourth, btnTopFirst, btnTopSecond,\n\t\t\t\tbtnTopThird, btnTopFourth };\n\t\tthis.btnEndWord = (Button) findViewById(R.id.btnEndWord);\n\n\t\t// End word should be disabled by default\n\t\tthis.btnEndWord.setEnabled(false);\n\n\t\t// Populate level letters\n\t\tint index = 0;\n\t\tfor (Button btn : this.letterButtons) {\n\t\t\tbtn.setText(\"\" + levelLetters[index]);\n\t\t\tindex++;\n\t\t}\n\t}",
"public GameButton() {\n initialize();\n }",
"public void init() {\n setLayout(new GridLayout(n-1, n));\n setFont(new Font(\"SansSerif\", Font.BOLD, 24));\n \n // Baris 1\n add(makeButton(\"X\",Color.red));\n add(makeButton(\"X\",Color.red));\n add(makeButton(\"X\",Color.red));\n add(makeButton(\"Bksp\",Color.red));\n add(makeButton(\"CE\",Color.red));\n add(makeButton(\"X\",Color.red));\n \n // Baris 2\n add(makeButton(\"MC\",Color.red));\n add(new Button(\"7\"));\n add(new Button(\"8\"));\n add(new Button(\"9\"));\n add(new Button(\"/\"));\n add(new Button(\"sqrt\"));\n \n // Baris 3\n add(makeButton(\"MR\",Color.red));\n add(new Button(\"4\"));\n add(new Button(\"5\"));\n add(new Button(\"6\"));\n add(new Button(\"x\"));\n add(new Button(\"%\"));\n \n // Baris 4\n add(makeButton(\"MR\",Color.red));\n add(new Button(\"1\"));\n add(new Button(\"2\"));\n add(new Button(\"3\"));\n add(new Button(\"-\"));\n add(new Button(\"1/x\"));\n\n // Baris 5\n add(makeButton(\"M+\",Color.red));\n add(new Button(\"0\"));\n add(new Button(\"+/-\"));\n add(new Button(\".\"));\n add(new Button(\"+\"));\n add(new Button(\"=\"));\n }",
"protected KeyBoardButton(String keyView){\r\n\t\tsuper(keyView); // setting text\r\n\t\t_keyView = keyView; //saving as an internal field\r\n\t\tthis.setToolTipText(_keyView); //setting tooltip\r\n\t\t_keyBoardButtons.add(this); //adding to arraylist\r\n\t}",
"private void createAdditionalButtonControls(Composite parent) {\r\n\t\tComposite btnComposite = new Composite(parent, SWT.NONE);\r\n\t\tbtnComposite.setLayout(new GridLayout(2, false));\r\n\r\n\t\tButton selAllBtn = new Button(btnComposite, SWT.PUSH);\r\n\t\tselAllBtn.setText(Messages.TOPOLOGY_BTN_SELECT_ALL_TXT);\r\n\t\tselAllBtn.addSelectionListener(new SelectionListener() {\r\n\t\t\tpublic void widgetDefaultSelected(SelectionEvent e) {\r\n\t\t\t}\r\n\r\n\t\t\tpublic void widgetSelected(SelectionEvent e) {\r\n\t\t\t\tselectedUnitsList.setAllChecked(true);\r\n\t\t\t\tupdateSelectedItemsProperty();\r\n\t\t\t}\r\n\t\t});\r\n\r\n\t\tButton deselAllBtn = new Button(btnComposite, SWT.PUSH);\r\n\t\tdeselAllBtn.setText(Messages.TOPOLOGY_BTN_DESELECT_ALL_TXT);\r\n\t\tdeselAllBtn.addSelectionListener(new SelectionListener() {\r\n\t\t\tpublic void widgetDefaultSelected(SelectionEvent e) {\r\n\t\t\t}\r\n\r\n\t\t\tpublic void widgetSelected(SelectionEvent e) {\r\n\t\t\t\tselectedUnitsList.setAllChecked(false);\r\n\t\t\t\tupdateSelectedItemsProperty();\r\n\t\t\t}\r\n\t\t});\r\n\t}",
"public Button(){\n id=1+nbrButton++;\n setBounds(((id-1)*getDimX())/(Data.getNbrLevelAviable()+1),((id-1)*getDimY())/(Data.getNbrLevelAviable()+1),getDimX()/(2*Data.getNbrLevelAviable()),getDimY()/(2*Data.getNbrLevelAviable()));\n setText(id+\"\");\n setFont(Data.getFont());\n addMouseListener(this);\n setVisible(true);\n }",
"private void initializeSetColorButton() {\n\n setColorTextLabel = new JLabel(\"Set New Color\");\n setColorTextLabel.setBounds(250, 250,150, 25);\n setColorTextLabel.setFont(new Font(\"Arial\", Font.PLAIN, 20));\n this.add(setColorTextLabel);\n\n greenButton = new JButton();\n greenButton.setBackground(java.awt.Color.green);\n greenButton.setBounds(400, 250, 60, 25);\n this.add(greenButton);\n\n redButton = new JButton();\n redButton.setBackground(java.awt.Color.red);\n redButton.setBounds(460, 250, 60, 25);\n this.add(redButton);\n\n yellowButton = new JButton();\n yellowButton.setBackground(java.awt.Color.yellow);\n yellowButton.setBounds(520, 250, 60, 25);\n this.add(yellowButton);\n\n blueButton = new JButton();\n blueButton.setBackground(java.awt.Color.blue);\n blueButton.setBounds(580, 250, 60, 25);\n this.add(blueButton);\n\n setColorTextLabel.setVisible(false);\n greenButton.setVisible(false);\n blueButton.setVisible(false);\n redButton.setVisible(false);\n yellowButton.setVisible(false);\n }",
"private void init_buttons(){\r\n /**\r\n * BOTON NUEVO\r\n */\r\n im_tool1.setOnMouseClicked((MouseEvent mouseEvent) -> {\r\n if(mouseEvent.getButton().equals(MouseButton.PRIMARY)){\r\n if(mouseEvent.getClickCount() > 0){\r\n botonInicio();\r\n botonNuevo();\r\n }\r\n }\r\n });\r\n /**\r\n * BOTON EDITAR\r\n */\r\n im_tool2.setOnMouseClicked((MouseEvent mouseEvent) -> {\r\n if(mouseEvent.getButton().equals(MouseButton.PRIMARY)){\r\n if(mouseEvent.getClickCount() > 0){\r\n botonEditar();\r\n }\r\n }\r\n });\r\n /**\r\n * BOTON GUARDAR\r\n */\r\n im_tool3.setOnMouseClicked((MouseEvent mouseEvent) -> {\r\n if(mouseEvent.getButton().equals(MouseButton.PRIMARY)){\r\n if(mouseEvent.getClickCount() > 0){\r\n botonGuardar();\r\n }\r\n }\r\n }); \r\n /**\r\n * BOTON ELIMINAR\r\n */\r\n im_tool4.setOnMouseClicked((MouseEvent mouseEvent) -> {\r\n if(mouseEvent.getButton().equals(MouseButton.PRIMARY)){\r\n if(mouseEvent.getClickCount() > 0){\r\n botonEliminar();\r\n }\r\n }\r\n });\r\n /**\r\n * BOTON IMPRIMIR\r\n */\r\n im_tool5.setOnMouseClicked((MouseEvent mouseEvent) -> {\r\n if(mouseEvent.getButton().equals(MouseButton.PRIMARY)){\r\n if(mouseEvent.getClickCount() > 0){ \r\n botonImprimir();\r\n }\r\n }\r\n });\r\n /**\r\n * BOTON REGRESAR\r\n */\r\n im_tool6.setOnMouseClicked((MouseEvent mouseEvent) -> {\r\n if(mouseEvent.getButton().equals(MouseButton.PRIMARY)){\r\n if(mouseEvent.getClickCount() > 0){\r\n botonInicio();\r\n }\r\n }\r\n });\r\n /**\r\n * BOTON POR ASIGNAR\r\n */\r\n im_tool7.setOnMouseClicked((MouseEvent mouseEvent) -> {\r\n if(mouseEvent.getButton().equals(MouseButton.PRIMARY)){\r\n if(mouseEvent.getClickCount() > 0){\r\n //\r\n }\r\n }\r\n });\r\n /**\r\n * BOTON NOTAS DE CREDITO\r\n */\r\n im_tool8.setOnMouseClicked((MouseEvent mouseEvent) -> {\r\n if(mouseEvent.getButton().equals(MouseButton.PRIMARY)){\r\n if(mouseEvent.getClickCount() > 0){\r\n //\r\n }\r\n }\r\n });\r\n /**\r\n * BOTON DEVOLUCION\r\n */\r\n im_tool9.setOnMouseClicked((MouseEvent mouseEvent) -> {\r\n if(mouseEvent.getButton().equals(MouseButton.PRIMARY)){\r\n if(mouseEvent.getClickCount() > 0){\r\n //\r\n }\r\n }\r\n });\r\n /**\r\n * BOTON BUSCAR\r\n */\r\n im_tool12.setOnMouseClicked((MouseEvent mouseEvent) -> {\r\n if(mouseEvent.getButton().equals(MouseButton.PRIMARY)){\r\n switch (mouseEvent.getClickCount()){\r\n case 1:\r\n botonInicio();\r\n botonBuscar();\r\n break;\r\n case 2:\r\n Datos.setIdButton(2003041);\r\n Gui.getInstance().showBusqueda(\"Busqueda\"); \r\n break;\r\n }\r\n }\r\n });\r\n /**\r\n * SELECCION EN LA TABLA\r\n */\r\n tb_guias.setOnMouseClicked((MouseEvent mouseEvent) -> {\r\n if(mouseEvent.getButton().equals(MouseButton.PRIMARY)){\r\n if(mouseEvent.getClickCount() > 0){\r\n if ((tb_guias.getItems() != null) && (!tb_guias.getItems().isEmpty()))\r\n selectedRowGuide();\r\n }\r\n }\r\n }); \r\n /**\r\n * metodo para mostrar buscar el nro de guia\r\n * param: ENTER O TAB\r\n */\r\n tf_nroguia.setOnKeyReleased((KeyEvent ke) -> {\r\n if (ke.getCode().equals(KeyCode.ENTER)){\r\n //Valida que el evento se haya generado en el campo de busqueda\r\n if(((Node)ke.getSource()).getId().equals(\"tf_nroguia\")){\r\n //Solicita los datos y envia la Respuesta a imprimirse en la Pantalla\r\n Datos.setLog_cguias(new log_CGuias()); \r\n boolean boo = Ln.getInstance().check_log_CGuias_rela_caja(tf_nroguia.getText()); \r\n numGuias = 0;\r\n if(boo){\r\n Datos.setRep_log_cguias(Ln.getInstance().find_log_CGuias(tf_nroguia.getText(), \"\", \"ncaja\", Integer.parseInt(rows)));\r\n loadTable(Datos.getRep_log_cguias()); \r\n }\r\n else{\r\n change_im_val(0, im_checkg); \r\n Gui.getInstance().showMessage(\"El Nro. de \" + ScreenName + \" NO existe!\", \"A\");\r\n tf_nroguia.requestFocus();\r\n }\r\n }\r\n }\r\n });\r\n /**\r\n * metodo para mostrar buscar el nro de guia\r\n * param: ENTER O TAB\r\n */\r\n tf_nrorguia.setOnKeyReleased((KeyEvent ke) -> {\r\n if (ke.getCode().equals(KeyCode.ENTER)){\r\n //Valida que el evento se haya generado en el campo de busqueda\r\n if(((Node)ke.getSource()).getId().equals(\"tf_nrorguia\")){\r\n //Solicita los datos y envia la Respuesta a imprimirse en la Pantalla\r\n boolean booa = true; \r\n if(booa){\r\n boolean booc = Ln.getInstance().check_log_CGuias_caja(tf_nrorguia.getText()); \r\n if(booc){\r\n change_im_val(0, im_checkg); \r\n Gui.getInstance().showMessage(\"El Nro. de Guia ya esta relacionado!\", \"A\");\r\n tf_nrorguia.requestFocus();\r\n }\r\n else{\r\n for (int i = 0; i < log_guide_guia.size(); i++) {\r\n if(tf_nrorguia.getText().equals(tb_guias.getItems().get(i).getGuias())){\r\n booa = false;\r\n Gui.getInstance().showMessage(\"El Nro. de Guia ya esta relacionado!\", \"A\");\r\n tf_nrorguia.requestFocus();\r\n break;\r\n }\r\n } \r\n if(booa){\r\n log_Guide_rel_inv guide_carga = new log_Guide_rel_inv();\r\n\r\n List<Fxp_Archguid_gfc> data = \r\n Ln.getList_log_Archguid_gfc(Ln.getInstance().find_Archguid_gfc(tf_nrorguia.getText()));\r\n\r\n if (data.get(0).getStat_guia().equals(\"X\")\r\n || data.get(0).getStat_guia().equals(\"C\")){\r\n guide_carga.setNumorden(String.valueOf((log_guide_guia.size() + 1)));\r\n guide_carga.setGuias(tf_nrorguia.getText());\r\n guide_carga.setNumfact(data.get(0).getNumfact());\r\n guide_carga.setNumclie(data.get(0).getNumclie());\r\n\r\n if (data.get(0).getStat_guia().equals(\"A\")){\r\n if (tipoOperacion == 1)\r\n guide_carga.setStat_guia(null);\r\n else\r\n guide_carga.setStat_guia(data.get(0).getStat_guia());\r\n }\r\n else{\r\n guide_carga.setStat_guia(null);\r\n }\r\n \r\n \r\n log_guide_guia.add(guide_carga);\r\n\r\n loadTableGuide_guias();\r\n change_im_val(200, im_checkg); \r\n\r\n numFactCarga = numFactCarga + data.get(0).getNumfact();\r\n numClieCarga = numClieCarga + data.get(0).getNumclie();\r\n\r\n tf_nrorguia.setText(\"\");\r\n }else{\r\n if (data.get(0).getStat_guia().equals(\"\")){\r\n Gui.getInstance().showMessage(\"El Nro. de Guia NO tiene relación de Guia de Carga!\", \"A\");\r\n }\r\n else{\r\n Gui.getInstance().showMessage(\"El Nro. de Guia ya esta relacionado!\", \"A\");\r\n }\r\n tf_nrorguia.requestFocus();\r\n }\r\n \r\n }\r\n }\r\n }\r\n else{\r\n change_im_val(0, im_checkg); \r\n Gui.getInstance().showMessage(\"El Nro. de Guia NO existe!\", \"A\");\r\n tf_nrorguia.requestFocus();\r\n }\r\n }\r\n }\r\n });\r\n }",
"public void initializeButtons() {\n\n playGameButton = (Button) findViewById(R.id.playGameButton);\n freePlayButton = (Button) findViewById(R.id.freePlayButton);\n informationIcon = (ImageView) findViewById(R.id.informationAboutGame);\n }",
"public BTextPairSettings(String button_title, String text_title){\n\t\tsuper(button_title, text_title);\n\t//\tbutton.addActionListener(this);\n\t\t\n\t}",
"public ButtonTracker(GenericHID joystick, int buttonNumber) {\n\t\tsuper(joystick, buttonNumber);\n\t\tallButtons.add(this);\n\t}",
"private void createButtons() {\n Button helpSettingsButton = new Button(\"\",\n new Button.ClickListener() {\n private static final long serialVersionUID = -5797923866320649518L;\n\n @Override\n public void buttonClick(ClickEvent event) {\n settingsPresenter.navigateToHelp();\n }\n });\n\n// Button skillSettingsButton = new Button(\"\",\n// new Button.ClickListener() {\n// private static final long serialVersionUID = 7147554466396214893L;\n//\n// @Override\n// public void buttonClick(ClickEvent event) {\n// settingsPresenter.navigateToSkills();\n// }\n// });\n// skillSettingsButton.addStyleName(\"icon-cog\");\n\n Button medicSettingsButton = new Button(\"\",\n new Button.ClickListener() {\n private static final long serialVersionUID = 7147554466396214893L;\n\n @Override\n public void buttonClick(ClickEvent event) {\n settingsPresenter.navigateToMedic();\n }\n });\n\n\n Button logoutButton = new Button(\"\",\n new Button.ClickListener() {\n private static final long serialVersionUID = -1096188732209266611L;\n\n @Override\n public void buttonClick(ClickEvent event) {\n settingsPresenter.navigateBack();\n }\n });\n logoutButton.addStyleName(\"default\");\n\n // Adding and aligning the 3 Buttons.\n //Setting a Description for the buttons which is displayed when flying over the button\n super.verticalNavigation.addComponent(helpSettingsButton);\n super.verticalNavigation.setComponentAlignment(helpSettingsButton, Alignment.MIDDLE_CENTER);\n helpSettingsButton.setDescription(\"Set the Help options for the Patient\");\n helpSettingsButton.setIcon(new ThemeResource(\"img/contacgg.png\"), BUTTON_HELP_SETTINGS);\n helpSettingsButton.setWidth(BUTTON_WIDTH);\n helpSettingsButton.setHeight(BUTTON_HEIGHT);\n\n super.verticalNavigation.addComponent(medicSettingsButton);\n super.verticalNavigation.setComponentAlignment(medicSettingsButton, Alignment.MIDDLE_CENTER);\n medicSettingsButton.setDescription(\"Set the Medication options for the Patient\");\n medicSettingsButton.setIcon(new ThemeResource(\"img/medicine-icon-cog.png\"),BUTTON_MEDIC_SETTINGS);\n medicSettingsButton.setWidth(BUTTON_WIDTH);\n medicSettingsButton.setHeight(BUTTON_HEIGHT);\n\n// addComponent(skillSettingsButton);\n// setComponentAlignment(skillSettingsButton, Alignment.MIDDLE_CENTER);\n// skillSettingsButton.setDescription(\"Set the Skill options for the Patient\");\n// skillSettingsButton.setIcon(new ThemeResource(\"img/skill2-icon-cog.png\"), BUTTON_SKILL_SETTINGS);\n// skillSettingsButton.setWidth(BUTTON_WIDTH);\n// skillSettingsButton.setHeight(BUTTON_HEIGHT);\n\n logoutButton.setWidth(BUTTON_WIDTH);\n super.verticalNavigation.addComponent(logoutButton);\n super.verticalNavigation.setComponentAlignment(logoutButton, Alignment.MIDDLE_CENTER);\n logoutButton.setDescription(\"You will be logged out\");\n logoutButton.setIcon(new ThemeResource(\"img/logout.png\"), BUTTON_LOGOUT);\n logoutButton.setWidth(BUTTON_WIDTH);\n logoutButton.setHeight(BUTTON_HEIGHT);\n\n }",
"private void buttonInit(){\n for(int i=0; i < 3; i++){\n choice[i] = new JButton();\n\n }\n choice[0].setText(\"10x10 / 8 bombs\");\n choice[0].setBackground(new Color(86, 160, 189));\n\n\n choice[0].addActionListener(l-> makeGamePanel(10, 8));\n\n choice[1].setText(\"15x15 / 30 bombs\");\n choice[1].setBackground(new Color(238, 160, 160));\n\n\n choice[1].addActionListener(l-> makeGamePanel(15,30));\n\n choice[2].setText(\"24x24 / 70 bombs\");\n choice[2].setBackground(new Color(253, 230, 122));\n choice[2].setFont(new Font(Font.MONOSPACED, Font.BOLD, 30));\n choice[2].setForeground(new Color(45, 68, 73));\n\n choice[2].addActionListener(l-> makeGamePanel(24,70));\n\n this.add(choice[0], BorderLayout.LINE_START); this.add(choice[1], BorderLayout.LINE_END); this.add(choice[2], BorderLayout.CENTER);\n }",
"private void setupActionButtons() {\n setupLikeActionButton();\n setupRepostActionButton();\n setupMoreActionButton();\n }",
"private void setAddButtonUI() {\n addButton = new JButton(\"Add\");\n addButton.setForeground(new Color(247, 37, 133));\n addButton.addActionListener(this);\n addButton.setContentAreaFilled(false);\n addButton.setFocusPainted(false);\n addButton.setFont(new Font(\"Nunito\", Font.PLAIN, 14));\n addButton.setAlignmentX(Component.CENTER_ALIGNMENT);\n }",
"public RobotContainer() {\n // Configure the button bindings\n configureButtonBindings();\n\n }",
"private void initButtons() {\n\t\taddGoalkeeper = new JButton(\"+\");\n\t\taddGoalkeeper.addActionListener(new ActionListener() {\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\tchangePlayer(0, e);\n\t\t\t}\n\t\t});\n\t\t\n\t\taddDefence1 = new JButton(\"+\");\n\t\taddDefence1.addActionListener(new ActionListener() {\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\tchangePlayer(1, e);\n\t\t\t}\n\t\t});\n\t\t\n\t\taddDefence2 = new JButton(\"+\");\n\t\taddDefence2.addActionListener(new ActionListener() {\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\tchangePlayer(2, e);\n\t\t\t}\n\t\t});\n\t\t\t\t\n\t\taddDefence3 = new JButton(\"+\");\n\t\taddDefence3.addActionListener(new ActionListener() {\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\tchangePlayer(3, e);\n\t\t\t}\n\t\t});\n\t\t\n\t\taddDefence4 = new JButton(\"+\");\n\t\taddDefence4.addActionListener(new ActionListener() {\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\tchangePlayer(4, e);\n\t\t\t}\n\t\t});\n\t\t\n\t\taddMiddle1 = new JButton(\"+\");\n\t\taddMiddle1.addActionListener(new ActionListener() {\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\tchangePlayer(5, e);\n\t\t\t}\n\t\t});\n\t\t\n\t\taddMiddle2 = new JButton(\"+\");\n\t\taddMiddle2.addActionListener(new ActionListener() {\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\tchangePlayer(6, e);\n\t\t\t}\n\t\t});\n\t\t\n\t\taddMiddle3 = new JButton(\"+\");\n\t\taddMiddle3.addActionListener(new ActionListener() {\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\tchangePlayer(7, e);\n\t\t\t}\n\t\t});\n\t\t\n\t\taddMiddle4 = new JButton(\"+\");\n\t\taddMiddle4.addActionListener(new ActionListener() {\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\tchangePlayer(8, e);\n\t\t\t}\n\t\t});\n\t\t\n\t\taddForward1 = new JButton(\"+\");\n\t\taddForward1.addActionListener(new ActionListener() {\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\tchangePlayer(9, e);\n\t\t\t}\n\t\t});\n\t\t\n\t\taddForward2 = new JButton(\"+\");\n\t\taddForward2.addActionListener(new ActionListener() {\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\tchangePlayer(10, e);\n\t\t\t}\n\t\t});\n\t}",
"void init(){\n\n //to do associations\n mButtonBottomLeftCorner = findViewById(R.id.idButtonBottomLeftCorner);\n mButtonBottomRightCorner = findViewById(R.id.idButtonBottomRightCorner);\n mButtonTopLeftCorner = findViewById(R.id.idButtonTopLeftCorner);\n mButtonTopRightCorner = findViewById(R.id.idButtonTopRightCorner);\n\n //to set behavior\n\n mButtonBottomLeftCorner.setOnClickListener(this);\n mButtonBottomRightCorner.setOnClickListener(this);\n mButtonTopLeftCorner.setOnClickListener(this);\n mButtonTopRightCorner.setOnClickListener(this);\n\n }",
"public void initGui()\n {\n StringTranslate var1 = StringTranslate.getInstance();\n int var2 = this.func_73907_g();\n\n for (int var3 = 0; var3 < this.options.keyBindings.length; ++var3)\n {\n this.controlList.add(new GuiSmallButton(var3, var2 + var3 % 2 * 160, this.height / 6 + 24 * (var3 >> 1), 70, 20, this.options.getOptionDisplayString(var3)));\n }\n\n this.controlList.add(new GuiButton(200, this.width / 2 - 100, this.height / 6 + 168, var1.translateKey(\"gui.done\")));\n this.screenTitle = var1.translateKey(\"controls.minimap.title\");\n }",
"private void setupButtons() {\n final ButtonGroup btngrp = new ButtonGroup();\n\n for (final AbstractAction actn : myToolActions) {\n final JToggleButton btn = new JToggleButton(actn);\n btn.addActionListener(actn);\n btngrp.add(btn);\n add(btn);\n }\n\n btngrp.clearSelection();\n btngrp.getElements().nextElement().setSelected(true);\n\n }",
"public ButtonPanel(CalculatorController appController)\n\t{\n\t\tsuper();\n\t\tthis.appController = appController;\n\t\tnumberLayout = new GridLayout(5, 4, 10, 10);\n\t\tzero = new CalculatorButton(appController, \"0\", Color.GRAY);\n\t\tone = new CalculatorButton(appController, \"1\", Color.GRAY);\n\t\ttwo = new CalculatorButton(appController, \"2\", Color.GRAY);\n\t\tthree = new CalculatorButton(appController, \"3\", Color.GRAY);\n\t\tfour = new CalculatorButton(appController, \"4\", Color.GRAY);\n\t\tfive = new CalculatorButton(appController, \"5\", Color.GRAY);\n\t\tsix = new CalculatorButton(appController, \"6\", Color.GRAY);\n\t\tseven = new CalculatorButton(appController, \"7\", Color.GRAY);\n\t\teight = new CalculatorButton(appController, \"8\", Color.GRAY);\n\t\tnine = new CalculatorButton(appController, \"9\", Color.GRAY);\n\t\tpoint = new CalculatorButton(appController, \".\", Color.GRAY);\n\t\tmultiply = new CalculatorButton(appController, \"x\", Color.BLUE);\n\t\tdivide = new CalculatorButton(appController, \"/\", Color.BLUE);\n\t\tadd = new CalculatorButton(appController, \"+\", Color.BLUE);\n\t\tsubtract = new CalculatorButton(appController, \"-\", Color.BLUE);\n\t\tans = new CalculatorButton(appController, \"Ans\", new Color(0, 170, 100));\n\t\tequals = new JButton();\n\t\tclear = new JButton();\n\t\tbackspace = new JButton();\n\t\tnegative = new JButton();\n\t\tsetupPanel();\n\t\tsetupButtons();\n\t\tsetupListeners();\n\t}",
"Button createButton();",
"public LinkButton() {\n\t\tsuper();\n\t\tinit();\n\t}",
"public ButtonsPanel(final List<JButton> buttons) {\n super();\n this.buttons = buttons;\n\n init();\n }",
"@Override\n\tpublic void init() {\n\t\tmaterialImages = new JButton[MaterialState.materialLibrary.size()];\n\t\tmaterialNames = new JLabel[MaterialState.materialLibrary.size()];\n\t\tmaterialAmounts = new JLabel[MaterialState.materialLibrary.size()];\n\t\tmaterialColours = new JLabel[MaterialState.materialLibrary.size()];\n\n\t\ttotalRating = 0;\n\t\ttotalToxic = 0;\n\t\ttotalNegative = 0;\n\t\ttotalDamage = 0;\n\n\t}",
"@Override\n\tprotected void buildButton() {\n\t\t\n\t}",
"public jImageList(Controls _ctrls, long _Self) { //Add more others news \"_xxx\" params if needed!\n //super(_ctrls.activity);\n context = _ctrls.activity;\n pascalObj = _Self;\n controls = _ctrls;\n }",
"@Override\n\tprotected void createCompButtons() {\n\t\tbuildCompButtons();\n\t}",
"private void setUpOptionButtons() {\n setUpOptionOneButton();\n setUpOptionTwoButton();\n setUpOptionThreeButton();\n setUpProfileButton();\n setUpSignOutButton();\n }",
"public ButtonSetterFX() {\n }",
"public SimpleButton()\n {\n this(true);\n }",
"private void init() {\r\n\t\tthis.setBackground(Color.decode(\"#c5dfed\"));\r\n\r\n\t\tthis.initPanelButtons();\r\n\r\n\t\tUtilityClass.addBorder(this, 20, 20, 20, 20);\r\n\t\t\r\n\t\tthis.title.setFont(ConstantView.FONT_TITLE_CRUD);\r\n\t\tthis.title.setHorizontalAlignment(JLabel.CENTER);\r\n\t\tthis.add(title, BorderLayout.NORTH);\r\n\t\t\r\n\t\tthis.add(panelButtons, BorderLayout.SOUTH);\r\n\t\tthis.jPanelFormClient.setOpaque(false);\r\n\t\tthis.add(jPanelFormClient, BorderLayout.CENTER);\r\n\t}",
"public Button(ISizeReference x, ISizeReference y, ISizeReference width, ISizeReference height)\n {\n _x = x;\n _y = y;\n _width = width;\n _height = height;\n }",
"private void initPanelButtons() {\r\n\t\tthis.panelButtons = new JPanel(new GridBagLayout());\r\n\t\tthis.panelButtons.setBorder(BorderFactory.createEmptyBorder(10, 5, 0, 5));\r\n\t\tthis.panelButtons.setOpaque(false);\r\n\t\tGridBagConstraints gbc = new GridBagConstraints();\r\n\r\n\t\tgbc.gridx = 0;\r\n\t\tgbc.gridy = 0;\r\n\t\tgbc.gridwidth = 1;\r\n\t\tgbc.gridheight = 1;\r\n\t\tgbc.weightx = 1;\r\n\t\tgbc.weighty = 1;\r\n\t\tthis.returnButton.setBackground(ConstantView.COLOR_BUTTON_LOGIN);\r\n\t\tthis.returnButton.setForeground(Color.WHITE);\r\n\t\tthis.returnButton.setFocusable(false);\r\n\t\tthis.returnButton.setCursor(new Cursor(Cursor.HAND_CURSOR));\r\n\t\tthis.returnButton.setFont(ConstantView.FONT_PRINCIPAL_LABELS);\r\n\t\tthis.panelButtons.add(returnButton, gbc);\r\n\r\n\t\tgbc.gridx = 7;\r\n\t\tthis.okButton.setBackground(ConstantView.COLOR_BUTTON_LOGIN);\r\n\t\tthis.okButton.setForeground(Color.WHITE);\r\n\t\tthis.okButton.setFocusable(false);\r\n\t\tthis.okButton.setCursor(new Cursor(Cursor.HAND_CURSOR));\r\n\t\tthis.okButton.setFont(ConstantView.FONT_PRINCIPAL_LABELS);\r\n\t\tthis.okButton.addActionListener(ControlClient.getInstance());\r\n\t\tthis.okButton.setActionCommand(ClientCommands.OK_SIGN_IN.toString());\r\n\t\tthis.panelButtons.add(okButton, gbc);\r\n\t}",
"protected void init(){\n ac = new ButtonEventManager(this);\n \n nameField = new JTextField();\n \n done = new JButton(\"DONE\");\n back = new JButton(\"MAIN MENU\");\n quit = new JButton(\"QUIT\");\n \n done.setActionCommand(\"go to game menu after saving\");\n back.setActionCommand(\"go to the main menu\");\n quit.setActionCommand(\"quit the game\");\n \n Font font = new Font(\"Arial\", Font.PLAIN, 10);\n \n nameField.setFont(font);\n \n nameField.setBounds(2 * this.getWidth() / 3 - buttonWidth / 2, (int)(0.4 * this.getHeight() - textFieldHeight / 2), buttonWidth, textFieldHeight);\n \n done.setBounds((this.getWidth() / 2 - buttonWidth) / 2, (int)(0.7 * this.getHeight() - buttonHeight / 2), buttonWidth, buttonHeight);\n back.setBounds((this.getWidth() - buttonWidth) / 2, (int)(0.7 * this.getHeight() - buttonHeight / 2), buttonWidth, buttonHeight);\n quit.setBounds(3 * (this.getWidth() - buttonWidth) / 2, (int)(0.7 * this.getHeight() - buttonHeight / 2), buttonWidth, buttonHeight);\n \n done.addActionListener(ac);\n back.addActionListener(ac);\n quit.addActionListener(ac);\n \n add(nameField);\n \n add(done);\n add(back);\n add(quit);\n }",
"private void initializeButtonPanel() {\n buttonPanel = new ButtonPanel();\n radioPanel = new JPanel(new GridLayout(0, 1));\n ButtonGroup buttonGroup = new ButtonGroup();\n Collections.addAll(toDoButtonList,task1,task2,task3,task4,task5,task6);\n for (int i=0;i<toDoButtonList.size();i++){\n JRadioButton task = toDoButtonList.get(i);\n buttonGroup.add(task);\n radioPanel.add(task);\n }\n\n refresh();\n\n }",
"private void initiateChoiceButtons() {\n\t\trock = new JButton(\"Rock\");\n\t\trock.setPreferredSize(selectionButtonSize);\n\t\tpaper = new JButton(\"Paper\");\n\t\tpaper.setPreferredSize(selectionButtonSize);\n\t\tscissors = new JButton(\"Scissors\");\n\t\tscissors.setPreferredSize(selectionButtonSize);\n\n\t\taddButtonListener();\n\t}",
"public void createButtons() {\n\n addRow = new JButton(\"Add row\");\n add(addRow);\n\n deleteRow = new JButton(\"Delete row\");\n add(deleteRow);\n }",
"@Override\r\n public void initialize(URL url, ResourceBundle rb) {\r\n // TODO\r\n btnCliente.setAlignment(Pos.CENTER_RIGHT);\r\n btnCompras.setAlignment(Pos.CENTER_RIGHT);\r\n btnInventario.setAlignment(Pos.CENTER_RIGHT);\r\n btnProveedores.setAlignment(Pos.CENTER_RIGHT);\r\n btnUsuarios.setAlignment(Pos.CENTER_RIGHT);\r\n btnVentas.setAlignment(Pos.CENTER_RIGHT);\r\n }",
"private void initializeAttributes() {\n\t language.setMinWidth(200);//250\n\t language.setAlignment(Pos.CENTER);\n\t language.getStyleClass().clear();\n\t language.getStyleClass().add(\"menuButton\");\n\t \n\t // Set history button properties\n\t history.setMinWidth(200);//250\n\t history.setAlignment(Pos.CENTER);\n\t history.getStyleClass().clear();\n\t history.getStyleClass().add(\"menuButton\");\n\t \n\t // Set closing button button properties\n\t closingButton.getStyleClass().clear();\n\t closingButton.getStyleClass().add(\"menuButton\");\n\t \n\t // Set reducing button button properties\n\t reducingButton.getStyleClass().clear();\n\t reducingButton.getStyleClass().add(\"menuButton\");\n\t \n\t // Close window/application on click\n\t closingButton.setOnAction(new EventHandler<ActionEvent>() {\n public void handle(ActionEvent e) {\n \tgameMainStage.close();\n }\n });\n\t \n\t // Reduce window/application on click\n\t reducingButton.setOnAction(new EventHandler<ActionEvent>() {\n public void handle(ActionEvent e) {\n \tgameMainStage.setIconified(true);\n }\n });\n\t \n\t // Switch to the language part of the application on click\n\t language.setOnAction(new EventHandler<ActionEvent>() {\n public void handle(ActionEvent e) {\n if (currentTab == null || currentTab.equals(\"history\")) {\n \tcurrentTab = \"language\";\n \tupdateTabButtons();\n \twindowMainPane.setCenter(new Language());\n }\n }\n });\n\t \n\t\t// Switch to the history part of the application on click\n\t history.setOnAction(new EventHandler<ActionEvent>() {\n public void handle(ActionEvent e) {\n \tif (currentTab == null || currentTab.equals(\"language\")) {\n \t\tcurrentTab = \"history\";\n \t\tupdateTabButtons();\n \t\twindowMainPane.setCenter(new History(0));\n \t}\n }\n });\n\t}",
"public ButtonMenuPanelBuyer() {\n initComponents();\n }",
"@Override\r\n public void initialize(URL url, ResourceBundle rb) {\n correctButtonName = buttonList[(int)(Math.random() * buttonList.length)];\r\n \r\n/* If you want to test out the program but hate guessing, this will give you the correct button name.\r\n This is a cheat code for \"X Marks The Spot!\".\r\n System.out.print(correctButtonName);\r\n*/\r\n }",
"private void addUniqueToViewNodes() {\n\t\taddFilterButton();\n\t\t\n\t\t/* Button Initialization */\n\t\t//This Button Creates a Report\n\t\tcreateReportBtn = new Button(\"Create Report\");\n\t\tcreateReportBtn.getStyleClass().add(\"GreenButton\");\n\t\tcreateReportBtn.setOnAction(e -> {\n\t\t\tCreateReportPopup crPopup = new CreateReportPopup(\"Create Report\");\n\t\t\tcrPopup.show();\n\t\t});\n\t\t\n\t\t// This Button views the currently selected report in more detail\n\t\treportDetailsBtn = new Button(\"Report Details\");\n\t\treportDetailsBtn.getStyleClass().add(\"GreenButton\");\n\t\t\n\t\t/* Assembly */\n\t\tactionButtons.getChildren().addAll(createReportBtn, reportDetailsBtn);\n\t\t\n\t\tactionButtons.setPrefHeight(Values.ACTION_BUTTONS_PREF_WIDTH);\n\t}",
"private void initComponents() {\n\t\tbtn_pause =new JButton(\"暂停游戏\");\n\t\tbtn_continue =new JButton(\"继续游戏\");\n\t\tbtn_restart =new JButton(\"重新开始\");\n\t\tbtn_rank =new JButton(\"游戏排行\");\n\t\tbtn_admin =new JButton(\"后台管理\");\n\t\t\n\t\t\n\t\t//给按钮设置单击监听\n\t\tbtn_pause.addActionListener(this);\n\t\tbtn_continue.addActionListener(this);\n\t\tbtn_restart.addActionListener(this);\n\t\tbtn_rank.addActionListener(this);\n\t\tbtn_admin.addActionListener(this);\n\t}",
"private void initComponents() {\n LOOGER.info(\"Get init components\");\n this.loadButton = new JButton(\"Load\");\n this.fillButton = new JButton(\"Fill\");\n this.deleteButton = new JButton(\"Delete\");\n this.setLayout(new FlowLayout());\n LOOGER.info(\"components exit\");\n }",
"private void initButtons() {\n findViewById(R.id.home_profileBtn).setOnClickListener(new View.OnClickListener() {\n @Override\n public void onClick(View view) {\n Intent profile = new Intent(HomeView.this, ProfileView.class);\n profile.putExtra(\"profile\", user);\n startActivity(profile);\n }\n });\n\n findViewById(R.id.home_FindMatchBtn).setOnClickListener(new View.OnClickListener() {\n @Override\n public void onClick(View view) {\n Intent match = new Intent(HomeView.this, MatchView.class);\n match.putExtra(\"profile\", user);\n match.putExtra(\"matches\", toBeMatched);\n startActivity(match);\n }\n });\n\n findViewById(R.id.sign_out_button).setOnClickListener(new View.OnClickListener() {\n @Override\n public void onClick(View view) {\n signOut();\n Intent main = new Intent(HomeView.this, MainActivity.class);\n startActivity(main);\n }\n });\n }",
"@Override\n public final void initButtons(int x, int y, int addy){\n \n String data = s_datapath;\n addButton(data + \"SM_NeuesSpiel\" + s_typ, x, y, 1);\n addButton(data + \"OM_SpielSpeichern\" + s_typ, x, y + addy, 2);\n addButton(data + \"SM_SpielLaden\" + s_typ, x, y + addy * 2, 3);\n //addButton(data,x, y + addy*3, 4);\n addButton(data + \"Menu_Element_Blank\" + s_typ, x,/*715*/ y + addy * 4, 5);\n addButton(data + \"SM_SpielBeenden\" + s_typ, x,/*845*/ y + addy * 5, 6);\n }",
"public TWTRLogInButton() {}",
"public GridButton(int column, int row) {\n\n // YOUR CODE HERE\n this.column = column;\n this.row =row;\n this.lbl = new JLabel();\n\n\n }",
"@Override\n\tprotected void initAddButton() {\n addBtn = addButton(\"newBtn\", TwlLocalisationKeys.ADD_BEAT_TYPE_TOOLTIP, new Runnable() {\n\t\t\t\t@Override\n\t\t\t\tpublic void run() {\n\t\t\t\t\tnew AddEditBeatTypePanel(true, null, BeatTypesList.this).run(); // adding\n\t\t\t\t}\n\t }); \t\t\n\t}",
"@Override\n\tprotected void initParams() {\n\t\t\n\t}",
"public GUIObject() {\n this.id = UUID.randomUUID();\n }",
"public MyJButton(String name, int index)\n\t{\n\t\tsuper(name);\n\t\tthis.index = index;\n\t}",
"public PiButton()\n\t{\n\t\tpasswordLogic = new PINLogic();\n\t\tled = new PiLED(21, 22);\n\t\tbuzzer = new PiBuzzer();\n\t}",
"public ButtonPanel(MainPanel m) {\n\n\t\t// Send a reference to the Main Panel\n\t\t// to all of the buttons.\n\n\t\tstep = new StepButton(m);\n\t\tslow = new RunSlowButton(m);\n\t\tfast = new RunFastButton(m);\n\t\tstop = new StopButton(m);\n\t\tlower = new LowerHalfButton(m);\n\t\tupper = new UpperHalfButton(m);\n\t\trepeat = new RepeatButton(m);\n\t\tclear = new ResetButton(m);\n\t\tsetLayout(new FlowLayout());\n\n\t\t// Add all of the buttons\n\n\t\tadd(step);\n\t\tadd(slow);\n\t\tadd(fast);\n\t\tadd(stop);\n\t\tadd(lower);\n\t\tadd(upper);\n\t\tadd(repeat);\n\t\tadd(clear);\n\t}",
"public void initializeButtons(){\n\t\t\tplay.setBounds(40,90,280,30);\n\t\t\tadd(play);\n\t\t\tplay.addActionListener(new PlayGame());\n\t\t\tplay.setVisible(true);\n\t\t\t\n\t\t\tenterquestion.setBounds(40,140,280,30);\n\t\t\tadd(enterquestion);\n\t\t\tenterquestion.addActionListener(new EnterQuestion());\n\t\t\tenterquestion.setVisible(true);\n\t\t\t\n\t\t\tdirections.setBounds(40,190,280,30);\n\t\t\tadd(directions);\n\t\t\tdirections.addActionListener(new Instructor());\n\t\t\tdirections.setVisible(true);\n\t\t\t\n\t\t\t\n\t\t}",
"public Window()\n {\n // sets title\n super(\"Awesome Calculator\");\n\n // generated design code\n initComponents();\n\n conversions.addListSelectionListener(this);\n\n // sets up the map\n buttons = new JButton[]{\n zero, one, two, three, four,\n five, six, seven, eight, nine\n };\n\n // stores the initial button color\n init = zero.getBackground();\n\n // center frame on screen\n setLocationRelativeTo(null);\n\n // don't have to worry about component focus\n KeyboardFocusManager.getCurrentKeyboardFocusManager()\n .addKeyEventDispatcher(new KeyEventDispatcher()\n {\n @Override\n public boolean dispatchKeyEvent(KeyEvent event)\n {\n if (event.getID() == KeyEvent.KEY_PRESSED)\n {\n keyPressed(event);\n }\n\n return false;\n }\n }\n );\n }",
"public void createGameButtons() {\n \tcreateGameButton(myResources.getString(\"startcommand\"), 1, GAME_BUTTON_XLOCATION, GAME_BUTTON_YLOCATION);\n \tcreateGameButton(myResources.getString(\"stopcommand\"), 0, GAME_BUTTON_XLOCATION * 3, GAME_BUTTON_YLOCATION);\n \tcreateGameButton(myResources.getString(\"speedup\"), SPEED_INCREASE, GAME_BUTTON_XLOCATION*5, GAME_BUTTON_YLOCATION);\n \tcreateGameButton(myResources.getString(\"slowdown\"), 1/SPEED_INCREASE, GAME_BUTTON_XLOCATION*7, GAME_BUTTON_YLOCATION);\n }",
"public void initializeBtn(){\r\n\t\t\r\n\t\t//Populate Table\r\n\t\tinitializeTable();\r\n\t\t\r\n\t\t//Initialize form\r\n\t\tinitializeForm();\r\n\t\t\r\n\t}",
"private void crearObjetos() {\n // crea los botones\n this.btnOK = new CCButton(this.OK);\n this.btnOK.setActionCommand(\"ok\");\n this.btnOK.setToolTipText(\"Confirmar la Operación\");\n \n this.btnCancel = new CCButton(this.CANCEL);\n this.btnCancel.setActionCommand(\"cancel\");\n this.btnCancel.setToolTipText(\"Cancelar la Operación\");\n \n // Agregar los eventos a los botones\n this.btnOK.addActionListener(this);\n this.btnCancel.addActionListener(this);\n }",
"private void initializeButton(JPanel myPanel) {\n for (int row = 0; row < 8; row++) {\n for (int col = 0; col < 8; col++) {\n JButton myButton = new JButton();\n buttonGrid[row][col] = myButton;\n setButtonIcon(row,col);\n if ((row + col) % 2 == 0)\n myButton.setBackground(Color.WHITE);\n else\n myButton.setBackground(Color.GRAY);\n myButton.setOpaque(true);\n myButton.setBorderPainted(false);\n myButton.addActionListener(new ActionListener() {\n @Override\n public void actionPerformed(ActionEvent e) {\n pieceButtonClicked(e);\n }\n });\n myPanel.add(myButton);\n }\n }\n }",
"public Principal() {\n initComponents();\n JButton botonesH[] = {cmdCrear, cmdLimpiar};\n JButton botonesD[] = {cmdManual, cmdAutomatico, cmdOperaciones};\n\n Helper.habilitarBotones(botonesH);\n Helper.deshabilitarBotones(botonesD);\n\n txtFilas.setEditable(true);\n txtColumnas.setEditable(true);\n }",
"public RobotContainer() {\n // Configure the button bindings\n configureButtonBindings();\n }",
"public RobotContainer() {\n // Configure the button bindings\n configureButtonBindings();\n }",
"private void initView() {\n\r\n Button bt1 = (Button)findViewById(R.id.button1);\r\n bt1.setOnClickListener(this);\r\n Button bt2 = (Button)findViewById(R.id.button2);\r\n bt2.setOnClickListener(this);\r\n Button bt3 = (Button)findViewById(R.id.button3);\r\n bt3.setOnClickListener(this);\r\n Button bt4 = (Button)findViewById(R.id.button4);\r\n bt4.setOnClickListener(this);\r\n }",
"public SysMenuParams() {\n\t\tsuper();\n\t}",
"ButtonPanel() {\n setLayout(new GridLayout(0,3));\n setPreferredSize(new Dimension(1000,100));\n setVisible(true);\n setMaximumSize(new Dimension(1000,250));\n reservationButton = new JButton(\"Reservation View\");\n bookingButton = new JButton(\"Booking View\");\n searchButton = new JButton(\"Search View\");\n add(reservationButton);\n add(bookingButton);\n add(searchButton);\n \n }",
"private void initButtons() {\n HBox buttons = new HBox(50);\n yes = new Button(\"Yes!\");\n no = new Button(\"No!\");\n buttons.getChildren().addAll(yes,no);\n buttons.setAlignment(Pos.CENTER);\n root.getChildren().addAll(buttons);\n }",
"public BridgingUI() {\n initComponents();\n initUserActions();\n }",
"protected void createButtonsForButtonBar(Composite parent) {\n\t\tcreateButton(barComp, BUTTON_ADD_ID, Messages.btnAddParameter, true);\n\t\tcreateButton(barComp, BUTTON_EDIT_ID, Messages.btnEditParameter, true);\n\t\tcreateButton(barComp, BUTTON_DROP_ID, Messages.btnDropParameter, true);\n\t\tcreateButton(barComp, BUTTON_UP_ID, Messages.btnUpParameter, true);\n\t\tcreateButton(barComp, BUTTON_DOWN_ID, Messages.btnDownParameter, true);\n\t\tcreateButton(parent, IDialogConstants.OK_ID, com.cubrid.common.ui.common.Messages.btnOK, true);\n\n\t\tgetButton(BUTTON_EDIT_ID).setEnabled(false);\n\t\tgetButton(BUTTON_UP_ID).setEnabled(false);\n\t\tgetButton(BUTTON_DOWN_ID).setEnabled(false);\n\t\tgetButton(BUTTON_DROP_ID).setEnabled(false);\n\t\tcreateButton(parent, IDialogConstants.CANCEL_ID, com.cubrid.common.ui.common.Messages.btnCancel, false);\n\t}",
"MyButton(int i, int j, ButtonListenerImplementation buttonListener){\n\n super(\" \");\n setBackground(Color.LIGHT_GRAY);\n\n indexX=i;\n indexY=j;\n addActionListener(buttonListener);\n }"
] | [
"0.67154175",
"0.65641433",
"0.64469767",
"0.6311028",
"0.6277633",
"0.626547",
"0.6263635",
"0.6216259",
"0.6196647",
"0.61084306",
"0.60985863",
"0.6094916",
"0.60864705",
"0.60722655",
"0.60644823",
"0.6014911",
"0.59910023",
"0.59839934",
"0.5962536",
"0.59531623",
"0.5935346",
"0.5933078",
"0.5922029",
"0.59090614",
"0.58998936",
"0.58941364",
"0.5892562",
"0.58420795",
"0.58402604",
"0.58309674",
"0.5830575",
"0.5812585",
"0.5812054",
"0.58090883",
"0.580821",
"0.5796153",
"0.57957804",
"0.5789337",
"0.5779544",
"0.5770215",
"0.57664454",
"0.57526696",
"0.5748453",
"0.573968",
"0.57297075",
"0.5723557",
"0.57195526",
"0.5718503",
"0.570655",
"0.57051575",
"0.57050556",
"0.5701408",
"0.5691647",
"0.56905574",
"0.56865156",
"0.5684981",
"0.56836134",
"0.56811816",
"0.5681084",
"0.56808984",
"0.5679917",
"0.56706834",
"0.5667997",
"0.56563216",
"0.56542623",
"0.5653692",
"0.56473804",
"0.56367964",
"0.56357014",
"0.5633499",
"0.5632047",
"0.5620228",
"0.5619887",
"0.5618114",
"0.5611571",
"0.56105155",
"0.5607735",
"0.5607077",
"0.56002444",
"0.55986965",
"0.5598535",
"0.55935913",
"0.5593562",
"0.55911076",
"0.55832607",
"0.55791754",
"0.55759865",
"0.55722606",
"0.5570549",
"0.55650353",
"0.5565008",
"0.5558639",
"0.5556657",
"0.5556657",
"0.5555877",
"0.55522186",
"0.5550842",
"0.5548624",
"0.55446273",
"0.5544373",
"0.55442363"
] | 0.0 | -1 |
Helper method for the Constructor used to add MouseListeners to all of the unique buttons. | private void setupListeners()
{
equals.addMouseListener(new MouseAdapter()
{
public void mouseClicked(MouseEvent click)
{
appController.calculate();
appController.refocus();
}
public void mousePressed(MouseEvent onClick)
{
equals.setBackground(Color.RED.darker());
}
public void mouseReleased(MouseEvent offClick)
{
equals.setBackground(Color.RED);
}
public void mouseEntered(MouseEvent enter)
{
equals.setBorder(new CompoundBorder(new LineBorder(Color.LIGHT_GRAY, 5), new LineBorder(Color.WHITE, 3)));
}
public void mouseExited(MouseEvent exit)
{
equals.setBorder(new CompoundBorder(new LineBorder(Color.LIGHT_GRAY, 5), new LineBorder(Color.BLACK, 3)));
}
});
clear.addMouseListener(new MouseAdapter()
{
public void mouseClicked(MouseEvent click)
{
appController.clearText();
appController.refocus();
}
public void mousePressed(MouseEvent onClick)
{
clear.setBackground(new Color(0, 170, 100).darker());
}
public void mouseReleased(MouseEvent offClick)
{
clear.setBackground(new Color(0, 170, 100));
}
public void mouseEntered(MouseEvent enter)
{
clear.setBorder(new CompoundBorder(new LineBorder(Color.LIGHT_GRAY, 5), new LineBorder(Color.WHITE, 3)));
}
public void mouseExited(MouseEvent exit)
{
clear.setBorder(new CompoundBorder(new LineBorder(Color.LIGHT_GRAY, 5), new LineBorder(Color.BLACK, 3)));
}
});
backspace.addMouseListener(new MouseAdapter()
{
public void mouseClicked(MouseEvent click)
{
appController.backspace();
appController.refocus();
}
public void mousePressed(MouseEvent onClick)
{
backspace.setBackground(new Color(0, 170, 100).darker());
}
public void mouseReleased(MouseEvent offClick)
{
backspace.setBackground(new Color(0, 170, 100));
}
public void mouseEntered(MouseEvent enter)
{
backspace.setBorder(new CompoundBorder(new LineBorder(Color.LIGHT_GRAY, 5), new LineBorder(Color.WHITE, 3)));
}
public void mouseExited(MouseEvent exit)
{
backspace.setBorder(new CompoundBorder(new LineBorder(Color.LIGHT_GRAY, 5), new LineBorder(Color.BLACK, 3)));
}
});
negative.addMouseListener(new MouseAdapter()
{
public void mouseClicked(MouseEvent click)
{
appController.changeSign();
appController.refocus();
}
public void mousePressed(MouseEvent onClick)
{
negative.setBackground(Color.GRAY.darker());
}
public void mouseReleased(MouseEvent offClick)
{
negative.setBackground(Color.GRAY);
}
public void mouseEntered(MouseEvent enter)
{
negative.setBorder(new CompoundBorder(new LineBorder(Color.LIGHT_GRAY, 5), new LineBorder(Color.WHITE, 3)));
}
public void mouseExited(MouseEvent exit)
{
negative.setBorder(new CompoundBorder(new LineBorder(Color.LIGHT_GRAY, 5), new LineBorder(Color.BLACK, 3)));
}
});
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"private void setupListeners() {\n\t\tfor (int i = 0; i < _controlPoints.length; i++) {\n\t\t\taddControlPointListener(_controlPoints[i][0], i);\n\t\t\taddControlPointListener(_controlPoints[i][1], i);\n\t\t}\n\t\t\n\t\tfor (int i = 0; i < _selectionButtons.length; i++) {\n\t\t\taddPointSelectionButtonListener(i);\n\t\t}\n\t}",
"public MouseHandler()\n {\n // initialise instance variables:\n //INSTANTIATE listeners list:\n _listeners = new ArrayList<IMouseListener>();\n \n }",
"private void init_buttons(){\r\n /**\r\n * BOTON NUEVO\r\n */\r\n im_tool1.setOnMouseClicked((MouseEvent mouseEvent) -> {\r\n if(mouseEvent.getButton().equals(MouseButton.PRIMARY)){\r\n if(mouseEvent.getClickCount() > 0){\r\n botonInicio();\r\n botonNuevo();\r\n }\r\n }\r\n });\r\n /**\r\n * BOTON EDITAR\r\n */\r\n im_tool2.setOnMouseClicked((MouseEvent mouseEvent) -> {\r\n if(mouseEvent.getButton().equals(MouseButton.PRIMARY)){\r\n if(mouseEvent.getClickCount() > 0){\r\n botonEditar();\r\n }\r\n }\r\n });\r\n /**\r\n * BOTON GUARDAR\r\n */\r\n im_tool3.setOnMouseClicked((MouseEvent mouseEvent) -> {\r\n if(mouseEvent.getButton().equals(MouseButton.PRIMARY)){\r\n if(mouseEvent.getClickCount() > 0){\r\n botonGuardar();\r\n }\r\n }\r\n }); \r\n /**\r\n * BOTON ELIMINAR\r\n */\r\n im_tool4.setOnMouseClicked((MouseEvent mouseEvent) -> {\r\n if(mouseEvent.getButton().equals(MouseButton.PRIMARY)){\r\n if(mouseEvent.getClickCount() > 0){\r\n botonEliminar();\r\n }\r\n }\r\n });\r\n /**\r\n * BOTON IMPRIMIR\r\n */\r\n im_tool5.setOnMouseClicked((MouseEvent mouseEvent) -> {\r\n if(mouseEvent.getButton().equals(MouseButton.PRIMARY)){\r\n if(mouseEvent.getClickCount() > 0){ \r\n botonImprimir();\r\n }\r\n }\r\n });\r\n /**\r\n * BOTON REGRESAR\r\n */\r\n im_tool6.setOnMouseClicked((MouseEvent mouseEvent) -> {\r\n if(mouseEvent.getButton().equals(MouseButton.PRIMARY)){\r\n if(mouseEvent.getClickCount() > 0){\r\n botonInicio();\r\n }\r\n }\r\n });\r\n /**\r\n * BOTON POR ASIGNAR\r\n */\r\n im_tool7.setOnMouseClicked((MouseEvent mouseEvent) -> {\r\n if(mouseEvent.getButton().equals(MouseButton.PRIMARY)){\r\n if(mouseEvent.getClickCount() > 0){\r\n //\r\n }\r\n }\r\n });\r\n /**\r\n * BOTON NOTAS DE CREDITO\r\n */\r\n im_tool8.setOnMouseClicked((MouseEvent mouseEvent) -> {\r\n if(mouseEvent.getButton().equals(MouseButton.PRIMARY)){\r\n if(mouseEvent.getClickCount() > 0){\r\n //\r\n }\r\n }\r\n });\r\n /**\r\n * BOTON DEVOLUCION\r\n */\r\n im_tool9.setOnMouseClicked((MouseEvent mouseEvent) -> {\r\n if(mouseEvent.getButton().equals(MouseButton.PRIMARY)){\r\n if(mouseEvent.getClickCount() > 0){\r\n //\r\n }\r\n }\r\n });\r\n /**\r\n * BOTON BUSCAR\r\n */\r\n im_tool12.setOnMouseClicked((MouseEvent mouseEvent) -> {\r\n if(mouseEvent.getButton().equals(MouseButton.PRIMARY)){\r\n switch (mouseEvent.getClickCount()){\r\n case 1:\r\n botonInicio();\r\n botonBuscar();\r\n break;\r\n case 2:\r\n Datos.setIdButton(2003041);\r\n Gui.getInstance().showBusqueda(\"Busqueda\"); \r\n break;\r\n }\r\n }\r\n });\r\n /**\r\n * SELECCION EN LA TABLA\r\n */\r\n tb_guias.setOnMouseClicked((MouseEvent mouseEvent) -> {\r\n if(mouseEvent.getButton().equals(MouseButton.PRIMARY)){\r\n if(mouseEvent.getClickCount() > 0){\r\n if ((tb_guias.getItems() != null) && (!tb_guias.getItems().isEmpty()))\r\n selectedRowGuide();\r\n }\r\n }\r\n }); \r\n /**\r\n * metodo para mostrar buscar el nro de guia\r\n * param: ENTER O TAB\r\n */\r\n tf_nroguia.setOnKeyReleased((KeyEvent ke) -> {\r\n if (ke.getCode().equals(KeyCode.ENTER)){\r\n //Valida que el evento se haya generado en el campo de busqueda\r\n if(((Node)ke.getSource()).getId().equals(\"tf_nroguia\")){\r\n //Solicita los datos y envia la Respuesta a imprimirse en la Pantalla\r\n Datos.setLog_cguias(new log_CGuias()); \r\n boolean boo = Ln.getInstance().check_log_CGuias_rela_caja(tf_nroguia.getText()); \r\n numGuias = 0;\r\n if(boo){\r\n Datos.setRep_log_cguias(Ln.getInstance().find_log_CGuias(tf_nroguia.getText(), \"\", \"ncaja\", Integer.parseInt(rows)));\r\n loadTable(Datos.getRep_log_cguias()); \r\n }\r\n else{\r\n change_im_val(0, im_checkg); \r\n Gui.getInstance().showMessage(\"El Nro. de \" + ScreenName + \" NO existe!\", \"A\");\r\n tf_nroguia.requestFocus();\r\n }\r\n }\r\n }\r\n });\r\n /**\r\n * metodo para mostrar buscar el nro de guia\r\n * param: ENTER O TAB\r\n */\r\n tf_nrorguia.setOnKeyReleased((KeyEvent ke) -> {\r\n if (ke.getCode().equals(KeyCode.ENTER)){\r\n //Valida que el evento se haya generado en el campo de busqueda\r\n if(((Node)ke.getSource()).getId().equals(\"tf_nrorguia\")){\r\n //Solicita los datos y envia la Respuesta a imprimirse en la Pantalla\r\n boolean booa = true; \r\n if(booa){\r\n boolean booc = Ln.getInstance().check_log_CGuias_caja(tf_nrorguia.getText()); \r\n if(booc){\r\n change_im_val(0, im_checkg); \r\n Gui.getInstance().showMessage(\"El Nro. de Guia ya esta relacionado!\", \"A\");\r\n tf_nrorguia.requestFocus();\r\n }\r\n else{\r\n for (int i = 0; i < log_guide_guia.size(); i++) {\r\n if(tf_nrorguia.getText().equals(tb_guias.getItems().get(i).getGuias())){\r\n booa = false;\r\n Gui.getInstance().showMessage(\"El Nro. de Guia ya esta relacionado!\", \"A\");\r\n tf_nrorguia.requestFocus();\r\n break;\r\n }\r\n } \r\n if(booa){\r\n log_Guide_rel_inv guide_carga = new log_Guide_rel_inv();\r\n\r\n List<Fxp_Archguid_gfc> data = \r\n Ln.getList_log_Archguid_gfc(Ln.getInstance().find_Archguid_gfc(tf_nrorguia.getText()));\r\n\r\n if (data.get(0).getStat_guia().equals(\"X\")\r\n || data.get(0).getStat_guia().equals(\"C\")){\r\n guide_carga.setNumorden(String.valueOf((log_guide_guia.size() + 1)));\r\n guide_carga.setGuias(tf_nrorguia.getText());\r\n guide_carga.setNumfact(data.get(0).getNumfact());\r\n guide_carga.setNumclie(data.get(0).getNumclie());\r\n\r\n if (data.get(0).getStat_guia().equals(\"A\")){\r\n if (tipoOperacion == 1)\r\n guide_carga.setStat_guia(null);\r\n else\r\n guide_carga.setStat_guia(data.get(0).getStat_guia());\r\n }\r\n else{\r\n guide_carga.setStat_guia(null);\r\n }\r\n \r\n \r\n log_guide_guia.add(guide_carga);\r\n\r\n loadTableGuide_guias();\r\n change_im_val(200, im_checkg); \r\n\r\n numFactCarga = numFactCarga + data.get(0).getNumfact();\r\n numClieCarga = numClieCarga + data.get(0).getNumclie();\r\n\r\n tf_nrorguia.setText(\"\");\r\n }else{\r\n if (data.get(0).getStat_guia().equals(\"\")){\r\n Gui.getInstance().showMessage(\"El Nro. de Guia NO tiene relación de Guia de Carga!\", \"A\");\r\n }\r\n else{\r\n Gui.getInstance().showMessage(\"El Nro. de Guia ya esta relacionado!\", \"A\");\r\n }\r\n tf_nrorguia.requestFocus();\r\n }\r\n \r\n }\r\n }\r\n }\r\n else{\r\n change_im_val(0, im_checkg); \r\n Gui.getInstance().showMessage(\"El Nro. de Guia NO existe!\", \"A\");\r\n tf_nrorguia.requestFocus();\r\n }\r\n }\r\n }\r\n });\r\n }",
"MyButton(int i, int j, ButtonListenerImplementation buttonListener){\n\n super(\" \");\n setBackground(Color.LIGHT_GRAY);\n\n indexX=i;\n indexY=j;\n addActionListener(buttonListener);\n }",
"private void initListeners() {\n this.setOnMousePressed((event -> {\n this.setPressedStyle();\n }));\n\n this.setOnMouseReleased((event -> {\n this.setReleasedStyle();\n }));\n\n this.setOnMouseEntered((event -> {\n this.setEffect(new DropShadow());\n }));\n\n this.setOnMouseExited((event -> {\n this.setEffect(null);\n }));\n }",
"private void setButtonListener() {\n for(CellButton[] buttonsRow : mainFrame.getButtons()) {\n for(CellButton button :buttonsRow) {\n button.addButtonListener(this);\n }\n }\n }",
"public void createListeners() {\n\n addRow.addActionListener(e -> gui.addRow());\n deleteRow.addActionListener(e -> gui.deleteRow());\n }",
"private void createListeners() {\n btGeneralSave.addActionListener(new ActionListener() {\n @Override\n public void actionPerformed(ActionEvent e) {\n saveGeneralData();\n }\n });\n }",
"public void addClickables() {\n\t\tclickable.add(button1.getBounds());\n\t\tbehaviors.put(clickable.get(0), () -> hideEscapeScreen());\n\t\tclickable.add(button3.getBounds());\n\t\tbehaviors.put(clickable.get(1), () -> Driver.getInstance().switchToScreen(new FFWorldMap()));\n\t\tclickable.add(button4.getBounds());\n\t\tbehaviors.put(clickable.get(2), () -> Driver.getInstance().switchToScreen(new FFMainMenu()));\n\t}",
"private void createButtons() {\n\t\tfor (int x = 0; x < buttons.length; x++)\n\t\t\tfor (int y = 0; y < buttons[x].length; y++) {\n\t\t\t\tif ((x % 2 == 0 && y % 2 == 0) || (x % 2 == 1 && y % 2 == 1))\n\t\t\t\t\tbuttons[x][y] = new DarkButton();\n\t\t\t\telse\n\t\t\t\t\tbuttons[x][y] = new LightButton();\n\n\t\t\t\tbuttonListener(x, y);\n\t\t\t}\n\t\t\t\n\t\t\tinitButtonIcons();\n\t}",
"private void setupButtons() {\n final ButtonGroup btngrp = new ButtonGroup();\n\n for (final AbstractAction actn : myToolActions) {\n final JToggleButton btn = new JToggleButton(actn);\n btn.addActionListener(actn);\n btngrp.add(btn);\n add(btn);\n }\n\n btngrp.clearSelection();\n btngrp.getElements().nextElement().setSelected(true);\n\n }",
"@Override\n\tpublic void initListeners() {\n\t\tmClick.setOnClickListener(this);\n\t}",
"private void registerListeners() {\n\n\t\tline.addActionListener(new LineButtonListener());\n\t\trect.addActionListener(new RectButtonListener());\n\t\toval.addActionListener(new OvalButtonListener());\n\t\timage.addActionListener(new ImageButtonListener());\n\n\t\tMouseListener listener = new ListenToMouse();\n\t\tMouseMotionListener motionListener = new ListenToMouse();\n\n\t\tcanvas.addMouseMotionListener(motionListener);\n\t\tcanvas.addMouseListener(listener);\n\n\t}",
"private void createEvents() {\n\t\taddBtn.addActionListener(new ActionListener(){\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\tbuildOutput();\n\t\t\t}\n\t\t});\n\t}",
"private void addListeners()\r\n {\r\n Actions act = new Actions();\r\n btnCountA.addActionListener(act);\r\n btnSearch.addActionListener(act);\r\n btnFindL.addActionListener(act);\r\n }",
"public void createButtons() {\n\t\tbutton1 = new JButton(\"Button1\");\n\t\tbutton2 = new JButton(\"Button2\");\n\t\tbutton3 = new JButton(\"Button3\");\n\t\tbutton4 = new JButton(\"Button4\");\n\t\tbutton5 = new JButton(\"Button5\");\n\t}",
"public void addPanelActionListeners() {\n\n iconBase = new IconFactory();\n\n JButton[] iconsArray = LeftPanel.getIconsArray();\n for (JButton button : iconsArray) {\n button.addMouseListener(new MouseAdapter() {\n @Override\n public void mouseClicked(MouseEvent e) {\n super.mouseClicked(e);\n selectedIconText = button.getText();\n }\n });\n\n button.addMouseListener(new MouseAdapter() {\n @Override\n public void mouseReleased(MouseEvent e) {\n super.mouseReleased(e);\n int tabIndex = jTabbedPane.getSelectedIndex();\n WorkingPanel tab = (WorkingPanel) jTabbedPane.getComponent(tabIndex);\n if (tab.getMousePosition() != null) {\n addIconToTab(tab, button.getText());\n tab.repaint();\n }\n\n }\n });\n\n button.addMouseMotionListener(new MouseAdapter() {\n @Override\n public void mouseDragged(MouseEvent e) {\n super.mouseDragged(e);\n selectedIconText = button.getText();\n\n int tabIndex = jTabbedPane.getSelectedIndex();\n WorkingPanel tab = (WorkingPanel) jTabbedPane.getComponent(tabIndex);\n\n icon = iconBase.getIconObject(button.getText(), tab);\n if (icon != null) {\n icon.draw(getGraphics(), (int) (MouseInfo.getPointerInfo().getLocation().getX() - button.getWidth() / 3),\n (int) (MouseInfo.getPointerInfo().getLocation().getY() - button.getHeight() / 3));\n }\n repaint();\n }\n });\n }\n }",
"public void buildButtons() {\r\n\t\tImage temp1= display_img.getImage();\r\n\t\tImageIcon img=new ImageIcon(temp1.getScaledInstance(800, 800, Image.SCALE_SMOOTH));\r\n\t\timg1 = img.getImage();\r\n\t\tfor(int y=0;y<10;y++) {\r\n\t\t\tfor(int x=0; x<10; x++) {\r\n\t\t\t\tImage image = Toolkit.getDefaultToolkit().createImage(new FilteredImageSource(img1.getSource(), new CropImageFilter(x * 800 / 10, y * 800 / 10, 100, 100)));\r\n\t\t\t\tImageIcon icon = new ImageIcon(image);\r\n\t\t\t\tJButton temp = new JButton(icon);\r\n\t\t\t\ttemp.putClientProperty(\"position\", new Point(y,x));\r\n\t\t\t\tsolutions.add(new Point(y,x));\r\n\t\t\t\ttemp.putClientProperty(\"isLocked\", false);\r\n\t\t\t\ttemp.addMouseListener(new DragMouseAdapter());\r\n\t\t\t\tgrid[x][y]=temp;\r\n\r\n\t\t\t\tbuttons.add(temp);\r\n\t\t\t}\r\n\t\t}\r\n\t}",
"public void createButtons() {\n\n addRow = new JButton(\"Add row\");\n add(addRow);\n\n deleteRow = new JButton(\"Delete row\");\n add(deleteRow);\n }",
"private void buttonInit() {\n panel.add(createButton);\n panel.add(editButton);\n panel.add(changeButton);\n createButton.addActionListener(this);\n editButton.addActionListener(this);\n changeButton.addActionListener(this);\n submitNewUser.addActionListener(this);\n editAccTypeBtn.addActionListener(this);\n changePassBtn.addActionListener(this);\n }",
"public void initButtons() {\n for (int i = 0; i < 5; i++) {\n for (int j = 0; j < 5; j++) {\n bt[i][j].setOnMouseEntered(e -> {\n Button button;\n button = (Button) e.getSource();\n button.setStyle(\"-fx-border-color:yellow\");\n });\n bt[i][j].setOnMouseExited(e -> {\n Button button;\n button = (Button) e.getSource();\n button.setStyle(\"-fx-border-color:trasparent\");\n });\n\n }\n }\n }",
"private void setupListeners() {\t\t\n\n\t\tnextButton.addActionListener(new ActionListener() {\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\t\n\t\t\t\t gameModel.generateGame();\n\t\t\t\t \n\t\t\t\t setGameModel(gameModel);\n\t\t\t\t \n\t\t\t\t //gameModel = new GameModel(gameModel.getList());\n\t\t\t\t \n\t\t\t\n\t\t\t}\n\t\t});\n\t\t\n\t\ttilePanel.addMouseListener(new MouseAdapter() {\n\t\t\t@Override\n\t\t\tpublic void mousePressed(MouseEvent e) {\n\t\t\t\tSystem.out.println(\"PRESS\");\n\t\t\t}\n\t\t\t\n\t\t\tpublic void mouseReleased(MouseEvent e) {\n\t\t\t\tSystem.out.println(\"RELEASED\");\n\t\t\t}\n\t\t});\n\t}",
"private void createAdditionalButtonControls(Composite parent) {\r\n\t\tComposite btnComposite = new Composite(parent, SWT.NONE);\r\n\t\tbtnComposite.setLayout(new GridLayout(2, false));\r\n\r\n\t\tButton selAllBtn = new Button(btnComposite, SWT.PUSH);\r\n\t\tselAllBtn.setText(Messages.TOPOLOGY_BTN_SELECT_ALL_TXT);\r\n\t\tselAllBtn.addSelectionListener(new SelectionListener() {\r\n\t\t\tpublic void widgetDefaultSelected(SelectionEvent e) {\r\n\t\t\t}\r\n\r\n\t\t\tpublic void widgetSelected(SelectionEvent e) {\r\n\t\t\t\tselectedUnitsList.setAllChecked(true);\r\n\t\t\t\tupdateSelectedItemsProperty();\r\n\t\t\t}\r\n\t\t});\r\n\r\n\t\tButton deselAllBtn = new Button(btnComposite, SWT.PUSH);\r\n\t\tdeselAllBtn.setText(Messages.TOPOLOGY_BTN_DESELECT_ALL_TXT);\r\n\t\tdeselAllBtn.addSelectionListener(new SelectionListener() {\r\n\t\t\tpublic void widgetDefaultSelected(SelectionEvent e) {\r\n\t\t\t}\r\n\r\n\t\t\tpublic void widgetSelected(SelectionEvent e) {\r\n\t\t\t\tselectedUnitsList.setAllChecked(false);\r\n\t\t\t\tupdateSelectedItemsProperty();\r\n\t\t\t}\r\n\t\t});\r\n\t}",
"private void registerEventListeners() {\n addDisposeListener(new DisposeListener() {\n @Override\n public void widgetDisposed(DisposeEvent de) {\n Display display = getDisplay();\n display.removeFilter(SWT.Move, moveFilter);\n OldFXCanvas.this.widgetDisposed(de);\n }\n });\n\n addPaintListener(pe -> {\n OldFXCanvas.this.paintControl(pe);\n });\n\n addMouseListener(new MouseListener() {\n @Override\n public void mouseDoubleClick(MouseEvent me) {\n // Clicks and double-clicks are handled in FX\n }\n @Override\n public void mouseDown(MouseEvent me) {\n // FX only supports 3 buttons so don't send the event for other buttons\n if (me.button > 3) {\n return;\n }\n OldFXCanvas.this.sendMouseEventToFX(me, AbstractEvents.MOUSEEVENT_PRESSED);\n }\n @Override\n public void mouseUp(MouseEvent me) {\n // FX only supports 3 buttons so don't send the event for other buttons\n if (me.button > 3) {\n return;\n }\n OldFXCanvas.this.sendMouseEventToFX(me, AbstractEvents.MOUSEEVENT_RELEASED);\n }\n });\n\n addMouseMoveListener(me -> {\n if ((me.stateMask & SWT.BUTTON_MASK) != 0) {\n // FX only supports 3 buttons so don't send the event for other buttons\n if ((me.stateMask & (SWT.BUTTON1 | SWT.BUTTON2 | SWT.BUTTON3)) != 0) {\n OldFXCanvas.this.sendMouseEventToFX(me, AbstractEvents.MOUSEEVENT_DRAGGED);\n } else {\n OldFXCanvas.this.sendMouseEventToFX(me, AbstractEvents.MOUSEEVENT_MOVED);\n }\n } else {\n OldFXCanvas.this.sendMouseEventToFX(me, AbstractEvents.MOUSEEVENT_MOVED);\n }\n });\n\n addMouseWheelListener(me -> {\n OldFXCanvas.this.sendMouseEventToFX(me, AbstractEvents.MOUSEEVENT_WHEEL);\n });\n\n addMouseTrackListener(new MouseTrackListener() {\n @Override\n public void mouseEnter(MouseEvent me) {\n OldFXCanvas.this.sendMouseEventToFX(me, AbstractEvents.MOUSEEVENT_ENTERED);\n }\n @Override\n public void mouseExit(MouseEvent me) {\n OldFXCanvas.this.sendMouseEventToFX(me, AbstractEvents.MOUSEEVENT_EXITED);\n }\n @Override\n public void mouseHover(MouseEvent me) {\n // No mouse hovering in FX\n }\n });\n\n addControlListener(new ControlListener() {\n @Override\n public void controlMoved(ControlEvent ce) {\n OldFXCanvas.this.sendMoveEventToFX();\n }\n @Override\n public void controlResized(ControlEvent ce) {\n OldFXCanvas.this.sendResizeEventToFX();\n }\n });\n\n addFocusListener(new FocusListener() {\n @Override\n public void focusGained(FocusEvent fe) {\n OldFXCanvas.this.sendFocusEventToFX(fe, true);\n }\n @Override\n public void focusLost(FocusEvent fe) {\n OldFXCanvas.this.sendFocusEventToFX(fe, false);\n }\n });\n\n addKeyListener(new KeyListener() {\n @Override\n public void keyPressed(KeyEvent e) {\n OldFXCanvas.this.sendKeyEventToFX(e, SWT.KeyDown);\n \n }\n @Override\n public void keyReleased(KeyEvent e) {\n OldFXCanvas.this.sendKeyEventToFX(e, SWT.KeyUp);\n }\n });\n \n addMenuDetectListener(e -> {\n Runnable r = () -> {\n if (isDisposed()) {\n return;\n }\n OldFXCanvas.this.sendMenuEventToFX(e);\n };\n // In SWT, MenuDetect comes before the equivalent mouse event\n // On Mac, the order is MenuDetect, MouseDown, MouseUp. FX\n // does not expect this order and when it gets the MouseDown,\n // it closes the menu. The fix is to defer the MenuDetect\n // notification until after the MouseDown is sent to FX.\n if (\"cocoa\".equals(SWT.getPlatform())) {\n getDisplay().asyncExec(r);\n } else {\n r.run();\n }\n });\n }",
"private void createUIComponents() {\n bt1 = new JButton(\"Hola\");\n }",
"private void addButtonListener() {\n\t\trock.addActionListener(buttonListener);\n\t\tpaper.addActionListener(buttonListener);\n\t\tscissors.addActionListener(buttonListener);\n\t}",
"private void addActionListeners() {\n\t\tif(this.actionListener == null)\n\t\t\t\treturn; \n\t\t\n\t\t\n\t\t/**\n\t\t\tADD ACTION LISTENERS FOR BUTTONS HERE \n\t\t*/\n\t\tclearButton.addActionListener(this.actionListener);\n\t\tsinButton.addActionListener(this.actionListener);\n\t\tcosButton.addActionListener(this.actionListener);\n\t\ttanButton.addActionListener(this.actionListener);\n\t\tnegateButton.addActionListener(this.actionListener);\n\t\tsquareButton.addActionListener(this.actionListener);\n\t\tinverseButton.addActionListener(this.actionListener);\n\t\tsqrtButton.addActionListener(this.actionListener);\n\t\tpowerButton.addActionListener(this.actionListener);\n\t\tdivideButton.addActionListener(this.actionListener);\n\t\tmultiplyButton.addActionListener(this.actionListener);\n\t\tsubtractButton.addActionListener(this.actionListener);\n\t\taddButton.addActionListener(this.actionListener);\n\t\tpercentButton.addActionListener(this.actionListener);\n\t\t\n\t\t\n\t\tfor(int i = 0 ; i < valueButtons.length ; ++i) {\n\t\t\tvalueButtons[i].addActionListener(this.actionListener);\n\t\t}\n\t\t\n\t\t\n\t}",
"private void registerEvents() {\n MouseEventHandler handler = new MouseEventHandler();\n setOnMousePressed(handler);\n setOnMouseReleased(handler);\n setOnMouseMoved(handler);\n setOnMouseEntered(handler);\n setOnMouseExited(handler);\n\n }",
"private void agregarListeners() {\n this.vista.jbAceptar.addActionListener(this);\n this.vista.jbAgregar.addActionListener(this);\n this.vista.jbCancelar.addActionListener(this);\n this.vista.jbQuitar.addActionListener(this);\n this.vista.jtPermisosDisponibles.addMouseListener(this);\n this.vista.jtPermisosSeleccionados.addMouseListener(this);\n }",
"private void initButtonsListener(){\n initDraw();\n initResign();\n initRedo();\n }",
"private void createToolButtons(final Map<PaintTool, ToolAction> theMap, \n final List<PaintTool> theTools,\n final JFrame theFrame) {\n \n final ButtonGroup toolBarGroup = new ButtonGroup();\n for (final PaintTool aT : theTools) {\n final JToggleButton button = new JToggleButton(aT.getDescription());\n toolBarGroup.add(button);\n aT.addPropertyChangeListener(this);\n button.setAction(theMap.get(aT));\n myToolBar.add(button);\n myToolBar.addSeparator();\n }\n theFrame.add(myToolBar, BorderLayout.PAGE_END);\n }",
"private void componentsListeners() {\r\n\t\t// NIFs\r\n\t\tbtnRefrescarnifs.addMouseListener(new MouseAdapter() {\r\n\t\t\t@Override\r\n\t\t\tpublic void mousePressed(MouseEvent e) {\r\n\t\t\t\tcb_nifCliente.setModel(new DefaultComboBoxModel(ContenedorPrincipal.getContenedorPrincipal().getContenedorClientes().getNifs()));\r\n\t\t\t}\r\n\t\t});\r\n\r\n\t\t// Clientes\r\n\t\tbtnClientes.addMouseListener(new MouseAdapter() {\r\n\t\t\t@Override\r\n\t\t\tpublic void mousePressed(MouseEvent e) {\r\n\t\t\t\tcontroladorVehiculos.pulsarClientes();\r\n\t\t\t}\r\n\t\t});\r\n\r\n\t\t// Reparaciones\r\n\t\tbtnRepararVehvulo.addMouseListener(new MouseAdapter() {\r\n\t\t\t@Override\r\n\t\t\tpublic void mousePressed(MouseEvent e) {\r\n\t\t\t\tcontroladorVehiculos.pulsarReparaciones();\r\n\t\t\t}\r\n\t\t});\r\n\t\t// Anterior vehiculo\r\n\t\tbuttonLeftArrow.addActionListener(new ActionListener() {\r\n\t\t\tpublic void actionPerformed(ActionEvent arg0) {\r\n\t\t\t\tif (!Constantes.MODO_CREAR) {\r\n\t\t\t\t\tcontroladorVehiculos.pulsarLeftArrow();\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t});\r\n\t\t// Siguiente vehiculo\r\n\t\tbuttonRightArrow.addActionListener(new ActionListener() {\r\n\t\t\tpublic void actionPerformed(ActionEvent arg0) {\r\n\t\t\t\tif (!Constantes.MODO_CREAR) {\r\n\t\t\t\t\tcontroladorVehiculos.pulsarRightArrow();\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t});\r\n\r\n\t\t// Atras\r\n\t\tbtnAtrs.addMouseListener(new MouseAdapter() {\r\n\t\t\t@Override\r\n\t\t\tpublic void mousePressed(MouseEvent e) {\r\n\t\t\t\tcontroladorVehiculos.pulsarAtras();\r\n\t\t\t}\r\n\t\t});\r\n\t\t// Guarda el vehiculo\r\n\t\tbtnGuardar.addMouseListener(new MouseAdapter() {\r\n\t\t\t@Override\r\n\t\t\tpublic void mousePressed(MouseEvent e) {\r\n\t\t\t\tif (Constantes.MODO_CREAR) {\r\n\t\t\t\t\ttry {\r\n\t\t\t\t\t\tcontroladorVehiculos.guardarVehiculo();\r\n\t\t\t\t\t} catch (NumberFormatException e1) {\r\n\t\t\t\t\t\tJOptionPane.showMessageDialog(null, \"Hay campos vacios\", \"Error\", JOptionPane.ERROR_MESSAGE);\r\n\t\t\t\t\t} catch (Exception e2) {\r\n\t\t\t\t\t\tJOptionPane.showMessageDialog(null, \"Algo ha ido mal\", \"Error\", JOptionPane.ERROR_MESSAGE);\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t});\r\n\t\t// Borra el vehículo\r\n\t\tbtnBorrarVehiculo.addMouseListener(new MouseAdapter() {\r\n\t\t\t@Override\r\n\t\t\tpublic void mousePressed(MouseEvent e) {\r\n\t\t\t\tif (Constantes.MODO_CREAR) {\r\n\t\t\t\t\tcontroladorVehiculos.pulsarBorrarVehiculo();\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t});\r\n\t}",
"public Button(){\n id=1+nbrButton++;\n setBounds(((id-1)*getDimX())/(Data.getNbrLevelAviable()+1),((id-1)*getDimY())/(Data.getNbrLevelAviable()+1),getDimX()/(2*Data.getNbrLevelAviable()),getDimY()/(2*Data.getNbrLevelAviable()));\n setText(id+\"\");\n setFont(Data.getFont());\n addMouseListener(this);\n setVisible(true);\n }",
"public void addListeners()\n {\n view.addListeners(new FileButtonClick(view, this), new ViewButtonClick(view, this), new ClassClick(view, this), new RelationshipClick(view, this), new RightClickListenerFactory(view, this));\n\t}",
"private void initComponents(MinesweeperView frame, int[] gridef, Checkerboard panGrid, Score panScore) {\r\n frame.add(new JButton());\r\n String[] table = {\"Retour et sauvegarder\", \"Quitter et sauvegarder\", \"Rejouer\"};\r\n for (int i = 0 ; i < 3 ; i++) {\r\n JButton btn = new JButton(table[i]);\r\n btn.setSize(200, 50);\r\n btn.setLocation(953, 470+60*i);\r\n btn.addActionListener(new ListenerGame(frame, panGrid, panScore, table, gridef));\r\n frame.add(btn);\r\n }\r\n }",
"public ButtonTracker(GenericHID joystick, int buttonNumber) {\n\t\tsuper(joystick, buttonNumber);\n\t\tallButtons.add(this);\n\t}",
"public MyButtonListener(){\n super();\n }",
"@Override\n\tprotected void createCompButtons() {\n\t\tbuildCompButtons();\n\t}",
"private void generateButtons(){\n\t\tint coordX = ThreadLocalRandom.current().nextInt(0, 16);\n\t\tint coordY = ThreadLocalRandom.current().nextInt(0, 16);\n\t\t//Button button = new Button(coordX, coordY);\n\t\t//buttons.put(0, button);\n\t}",
"private void cargaListeners() {\n\t\tbtnGuardar.addActionListener(this);\n\n\t}",
"private void addListeners() {\n\t\t\n\t\tresetButton.setOnAction(new EventHandler<ActionEvent>() {\n\t\t\t \n\t\t public void handle(ActionEvent e) {\n\t\t \n\t\t \treset();\n\t\t \t\n\t\t }\n\t\t \n\t\t});\n\t\t\n\t\ttoggleGroup.selectedToggleProperty().addListener(\n\t\t\t (ObservableValue<? extends Toggle> ov, Toggle old_toggle, \n\t\t\t Toggle new_toggle) -> {\n\t\t\t \t\n\t\t\t \tif(rbCourse.isSelected()) {\n\t\t \t\t\n\t\t \t\thbox3.getChildren().set(0, CourseSelectionBox.instance());\n\t\t \t\thbox3.setDisable(false);\n\t\t \t\t\n\t\t \t}else if(rbAuthor.isSelected()) {\n\t\t \t\t\n\t\t \t\thbox3.getChildren().set(0, AuthorSelectionBox.instance());\n\t\t \t\thbox3.setDisable(false);\n\t\t \t\t\n\t\t \t}else if(rbNone.isSelected()) {\n\t\t \t\t\n\t\t \t\thbox3.setDisable(true);\n\t\t \t\t\n\t\t \t}\n\t\t\t \t\n\t\t\t});\n\t\t\n\t\tapplyButton.setOnAction(new EventHandler<ActionEvent>() {\n\t\t\t \n\t\t public void handle(ActionEvent e) {\n\t\t \n\t\t \tfilter();\n\t\t \t\n\t\t }\n\t\t \n\t\t});\n\t\t\n\t\tsearchButton.setOnAction(new EventHandler<ActionEvent>() {\n\t\t\t \n\t\t public void handle(ActionEvent e) {\n\t\t \n\t\t \tResult.instance().search(quizIDField.getText());\n\t\t \t\n\t\t }\n\t\t \n\t\t});\n\t\t\n\t}",
"private void registerListeners() {\r\n View.OnClickListener clickListener = new ButtonListener();\r\n btnStart.setOnClickListener(clickListener);\r\n btnStop.setOnClickListener(clickListener);\r\n }",
"@Override\r\n\tprotected SelectionListener createAddButtonActionListener() {\r\n\t\t// the value must by initialized! (don't return new AddActionListener()) \r\n\t\tthis.addButtonListener = new EventTypeAddActionListener();\r\n\t\t\r\n\t\treturn addButtonListener;\r\n\t}",
"public ToolBar(final List<AbstractAction> theToolActions) {\n super();\n myToolActions = theToolActions;\n\n setupButtons();\n\n }",
"private void createButtonsPanel() {\r\n Composite buttonsPanel = new Composite(this, SWT.NONE);\r\n buttonsPanel.setLayoutData(new GridData(SWT.FILL, SWT.FILL, true, false));\r\n buttonsPanel.setLayout(new GridLayout(4, true));\r\n\r\n getButtonFromAction(buttonsPanel, \"New\", new NewAction(_window));\r\n getButtonFromAction(buttonsPanel, \"Save\", new SaveAction());\r\n getButtonFromAction(buttonsPanel, \"Delete\", new DeleteAction(_window));\r\n getButtonFromAction(buttonsPanel, \"Cancel\", new CancelAction());\r\n }",
"private void buttonInit(){\n for(int i=0; i < 3; i++){\n choice[i] = new JButton();\n\n }\n choice[0].setText(\"10x10 / 8 bombs\");\n choice[0].setBackground(new Color(86, 160, 189));\n\n\n choice[0].addActionListener(l-> makeGamePanel(10, 8));\n\n choice[1].setText(\"15x15 / 30 bombs\");\n choice[1].setBackground(new Color(238, 160, 160));\n\n\n choice[1].addActionListener(l-> makeGamePanel(15,30));\n\n choice[2].setText(\"24x24 / 70 bombs\");\n choice[2].setBackground(new Color(253, 230, 122));\n choice[2].setFont(new Font(Font.MONOSPACED, Font.BOLD, 30));\n choice[2].setForeground(new Color(45, 68, 73));\n\n choice[2].addActionListener(l-> makeGamePanel(24,70));\n\n this.add(choice[0], BorderLayout.LINE_START); this.add(choice[1], BorderLayout.LINE_END); this.add(choice[2], BorderLayout.CENTER);\n }",
"private void initBtnsArray()\r\n {\r\n for (int i = 0; i < this.buttons.length; i++)\r\n this.buttons[i] = new Button(\"Button #\" + i);\r\n }",
"private void initListeners() {\n btnCadastrar.setOnClickListener(this);\n cadastrar.setOnClickListener(this);\n }",
"public void registerButtons()\n\t{\n\t\tplot.addActionListener(new ButtonListener());\n\t\tin.addActionListener(new ButtonListener(1));\n\t\tout.addActionListener(new ButtonListener(2));\n\t\t\n\t}",
"private void initialize() {\n\t\tframe = new JFrame();\n\t\tframe.getContentPane().setBackground(Color.GRAY);\n\t\tframe.setBounds(100, 100, 270, 300);\n\t\tframe.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);\n\t\tframe.getContentPane().setLayout(null);\n\t\t\n\t\tbuttons = new ArrayList<>();\n\t\t\n\t\tJButton btnNewButton = new JButton(\"7\");\n\t\tbtnNewButton.setBackground(Color.LIGHT_GRAY);\n\t\tbtnNewButton.setBounds(10, 81, 47, 23);\n\t\tbuttons.add(btnNewButton);\n\t\tframe.getContentPane().add(btnNewButton);\n\t\t\n\t\tJButton btnNewButton_1 = new JButton(\"8\");\n\t\tbtnNewButton_1.setBackground(Color.LIGHT_GRAY);\n\t\tbtnNewButton_1.setBounds(67, 81, 47, 23);\n\t\tbuttons.add(btnNewButton_1);\n\t\tframe.getContentPane().add(btnNewButton_1);\n\t\t\n\t\tJButton btnNewButton_2 = new JButton(\"9\");\n\t\tbtnNewButton_2.setBackground(Color.LIGHT_GRAY);\n\t\tbtnNewButton_2.setBounds(124, 81, 47, 23);\n\t\tbuttons.add(btnNewButton_2);\n\t\tframe.getContentPane().add(btnNewButton_2);\n\t\t\n\t\tJButton button = new JButton(\"4\");\n\t\tbutton.setBackground(Color.LIGHT_GRAY);\n\t\tbutton.setBounds(10, 115, 47, 23);\n\t\tbuttons.add(button);\n\t\tframe.getContentPane().add(button);\n\t\t\n\t\tJButton button_1 = new JButton(\"5\");\n\t\tbutton_1.setBackground(Color.LIGHT_GRAY);\n\t\tbutton_1.setBounds(67, 115, 47, 23);\n\t\tbuttons.add(button_1);\n\t\tframe.getContentPane().add(button_1);\n\t\t\n\t\tJButton button_2 = new JButton(\"6\");\n\t\tbutton_2.setBackground(Color.LIGHT_GRAY);\n\t\tbutton_2.setBounds(124, 115, 47, 23);\n\t\tbuttons.add(button_2);\n\t\tframe.getContentPane().add(button_2);\n\t\t\n\t\tJButton button_3 = new JButton(\"1\");\n\t\tbutton_3.setBackground(Color.LIGHT_GRAY);\n\t\tbutton_3.setBounds(10, 149, 47, 23);\n\t\tbuttons.add(button_3);\n\t\tframe.getContentPane().add(button_3);\n\t\t\n\t\tJButton button_4 = new JButton(\"2\");\n\t\tbutton_4.setBackground(Color.LIGHT_GRAY);\n\t\tbutton_4.setBounds(67, 149, 47, 23);\n\t\tbuttons.add(button_4);\n\t\tframe.getContentPane().add(button_4);\n\t\t\n\t\tJButton button_5 = new JButton(\"3\");\n\t\tbutton_5.setBackground(Color.LIGHT_GRAY);\n\t\tbutton_5.setBounds(124, 149, 47, 23);\n\t\tbuttons.add(button_5);\n\t\tframe.getContentPane().add(button_5);\n\t\t\n\t\tJButton button_6 = new JButton(\"0\");\n\t\tbutton_6.setBackground(Color.LIGHT_GRAY);\n\t\tbutton_6.setBounds(67, 183, 47, 23);\n\t\tbuttons.add(button_6);\n\t\tframe.getContentPane().add(button_6);\n\t\t\n\t\tJButton button_7 = new JButton(\"+\");\n\t\tbutton_7.setBackground(Color.LIGHT_GRAY);\n\t\tbutton_7.setBounds(197, 215, 47, 36);\n\t\tbuttons.add(button_7);\n\t\tframe.getContentPane().add(button_7);\n\t\t\n\t\tJButton button_8 = new JButton(\"-\");\n\t\tbutton_8.setBackground(Color.LIGHT_GRAY);\n\t\tbutton_8.setBounds(197, 170, 47, 36);\n\t\tbuttons.add(button_8);\n\t\tframe.getContentPane().add(button_8);\n\t\t\n\t\tJButton button_9 = new JButton(\"*\");\n\t\tbutton_9.setBackground(Color.LIGHT_GRAY);\n\t\tbutton_9.setBounds(197, 123, 47, 36);\n\t\tbuttons.add(button_9);\n\t\tframe.getContentPane().add(button_9);\n\t\t\n\t\tJButton button_10 = new JButton(\"/\");\n\t\tbutton_10.setBackground(Color.LIGHT_GRAY);\n\t\tbutton_10.setBounds(197, 70, 47, 36);\n\t\tbuttons.add(button_10);\n\t\tframe.getContentPane().add(button_10);\t\t\n\t\t\n\t\tbtnSqrt = new JButton(\"\\u221a\");\n\t\tbtnSqrt.setBackground(Color.LIGHT_GRAY);\n\t\tbtnSqrt.setBounds(197, 21, 47, 36);\n\t\tframe.getContentPane().add(btnSqrt);\n\t\t\n\t\tJButton button_12 = new JButton(\".\");\n\t\tbutton_12.setBackground(Color.LIGHT_GRAY);\n\t\tbutton_12.setBounds(124, 183, 47, 23);\n\t\tbuttons.add(button_12);\n\t\tframe.getContentPane().add(button_12);\n\t\t\n\t\tJButton button_13 = new JButton(\"=\");\n\t\tbutton_13.setBackground(Color.LIGHT_GRAY);\n\t\tbutton_13.setBounds(104, 217, 67, 36);\n\t\tbuttons.add(button_13);\n\t\tframe.getContentPane().add(button_13);\n\t\t\n\t\tlabel = new JLabel(text1);\n\t\tlabel.setBackground(Color.WHITE);\n\t\tlabel.setOpaque(true);\n\t\tlabel.setHorizontalAlignment(SwingConstants.RIGHT);\n\t\tlabel.setVerticalAlignment(SwingConstants.NORTH);\n\t\tlabel.setBounds(10, 24, 161, 23);\n\t\tframe.getContentPane().add(label);\n\t\t\n\t\tlabel_1 = new JLabel(\"0\");\n\t\tlabel_1.setFont(new Font(\"Tahoma\", Font.PLAIN, 16));\n\t\tlabel_1.setBackground(Color.WHITE);\n\t\tlabel_1.setOpaque(true);\n\t\tlabel_1.setHorizontalAlignment(SwingConstants.RIGHT);\n\t\tlabel_1.setBounds(10, 43, 161, 29);\n\t\tframe.getContentPane().add(label_1);\n\t}",
"public CanvasPanel() {\n\t \t\taddMouseListener(this);\n\t \t\taddMouseMotionListener(this);\n\t }",
"private void initEvent() {\n\t\tmBtnPower.setOnClickListener(this);\n\t\tmBtnProfile.setOnClickListener(this);\n\t\tmBtnArea.setOnClickListener(this);\n\t\tmBtnSkipTime.setOnClickListener(this);\n\t\tmBtnFrequencyPoint.setOnClickListener(this);\n\t\tmBtnAlgorithm.setOnClickListener(this);\n\t}",
"public void createButtons() {\n\t\tescapeBackground = new GRect(200, 150, 300, 400);\n\t\tescapeBackground.setFilled(true);\n\t\tescapeBackground.setColor(Color.gray);\n\n\t\tbutton1 = new GButton(\"Return to Game\", 250, 175, 200, 50, Color.cyan);\n\t\tbutton3 = new GButton(\"Exit Level\", 250, 330, 200, 50, Color.cyan);\n\t\tbutton4 = new GButton(\"Return to Menu\", 250, 475, 200, 50, Color.cyan);\n\n\t\tescapeButtons.add(button1);\n\t\tescapeButtons.add(button3);\n\t\tescapeButtons.add(button4);\n\n\t}",
"private void createButton() {\n\t\tbtnAddTask = new JButton(\"Add Task\");\n\t\tbtnSave = new JButton(\"Save\");\n\t\tbtnCancel = new JButton(\"Cancel\");\n\n\t\tbtnAddTask.addActionListener(new ToDoAction());\n\t\tbtnSave.addActionListener(new ToDoAction());\n\t\tbtnCancel.addActionListener(new ToDoAction());\n\t}",
"public BigTwoPanel()\n\t\t{\n\t\t\tthis.addMouseListener(this);\n\t\t}",
"private void setListeners() {\r\n \t/*----------------------------\r\n\t\t * 1. Buttons\r\n\t\t\t----------------------------*/\r\n\t\t//\r\n \tButton bt_create = (Button) findViewById(R.id.db_manager_btn_create_table);\r\n \tButton bt_drop = (Button) findViewById(R.id.db_manager_btn_drop_table);\r\n \tButton bt_register_patterns = \r\n \t\t\t\t\t\t(Button) findViewById(R.id.db_manager_btn_register_patterns);\r\n \t\r\n \t/*----------------------------\r\n\t\t * 2. Tags\r\n\t\t\t----------------------------*/\r\n \tbt_create.setTag(Methods.ButtonTags.db_manager_activity_create_table);\r\n \tbt_drop.setTag(Methods.ButtonTags.db_manager_activity_drop_table);\r\n \tbt_register_patterns.setTag(Methods.ButtonTags.db_manager_activity_register_patterns);\r\n \t\r\n \t/*----------------------------\r\n\t\t * 3. Listeners\r\n\t\t * \t\t1. OnClick\r\n\t\t * \t\t2. OnTouch\r\n\t\t\t----------------------------*/\r\n \t/*----------------------------\r\n\t\t * 3.1. OnClick\r\n\t\t\t----------------------------*/\r\n \t//\r\n \tbt_create.setOnClickListener(new ButtonOnClickListener(this));\r\n \tbt_drop.setOnClickListener(new ButtonOnClickListener(this));\r\n \tbt_register_patterns.setOnClickListener(new ButtonOnClickListener(this));\r\n \t\r\n \t/*----------------------------\r\n\t\t * 3.2. OnTouch\r\n\t\t\t----------------------------*/\r\n \t//\r\n \tbt_create.setOnTouchListener(new ButtonOnTouchListener(this));\r\n \tbt_drop.setOnTouchListener(new ButtonOnTouchListener(this));\r\n \tbt_register_patterns.setOnTouchListener(new ButtonOnTouchListener(this));\r\n \t\r\n \t/*----------------------------\r\n\t\t * 4. Disenable => \"Create table\"\r\n\t\t\t----------------------------*/\r\n// \tbt_create.setEnabled(false);\r\n \t\r\n\t}",
"public MenuButtons(String nameOfButton) {\n Text text = new Text(nameOfButton);\n text.setFont(Font.font(null, FontWeight.BOLD, 18));\n text.setFill(Color.WHITESMOKE);\n\n //A rectangle that will be a part of the button\n Rectangle rectangle = new Rectangle(250,30);\n rectangle.setOpacity(0.3);\n rectangle.setFill(Color.BLUE);\n\n setAlignment(Pos.CENTER_LEFT);\n getChildren().addAll(rectangle, text);\n\n setOnMouseEntered(e -> {\n rectangle.setTranslateX(5);\n text.setTranslateX(5);\n rectangle.setFill(Color.DARKBLUE);\n });\n\n setOnMouseExited(e -> {\n rectangle.setTranslateX(0);\n text.setTranslateX(0);\n rectangle.setFill(Color.BLUE);\n });\n\n DropShadow shadowEffect = new DropShadow();\n shadowEffect.setInput(new Glow());\n\n setOnMousePressed(e -> setEffect(shadowEffect));\n setOnMouseReleased(e -> setEffect(null));\n }",
"private void initializeButton(JPanel myPanel) {\n for (int row = 0; row < 8; row++) {\n for (int col = 0; col < 8; col++) {\n JButton myButton = new JButton();\n buttonGrid[row][col] = myButton;\n setButtonIcon(row,col);\n if ((row + col) % 2 == 0)\n myButton.setBackground(Color.WHITE);\n else\n myButton.setBackground(Color.GRAY);\n myButton.setOpaque(true);\n myButton.setBorderPainted(false);\n myButton.addActionListener(new ActionListener() {\n @Override\n public void actionPerformed(ActionEvent e) {\n pieceButtonClicked(e);\n }\n });\n myPanel.add(myButton);\n }\n }\n }",
"private void initializeListeners() {\n llBack.setOnClickListener(this);\n btnChange.setOnClickListener(this);\n btnNext.setOnClickListener(this);\n }",
"private VecCanvas(){\n MouseAdapter mouse = new CanvasMouse();\n this.addMouseListener(mouse);\n this.addMouseMotionListener(mouse);\n setupKeyBindings();\n }",
"public void addListeners() {\r\n\t\tbtnLogin.addActionListener(listener);\r\n\t\tbtnChooseFile.addActionListener(listener);\r\n\t\tbtnSendMessage.addActionListener(listener);\r\n\t\tbtnRemoveImage.addActionListener(listener);\r\n\t\tbtnUpdateMessages.addActionListener(listener);\r\n\t\tbtnUpdateUsers.addActionListener(listener);\r\n\t}",
"private void setupAddToReviewButton() {\n\t\tImageIcon addreview_button_image = new ImageIcon(parent_frame.getResourceFileLocation() + \"addtoreview.png\");\n\t\tJButton add_to_review = new JButton(\"\", addreview_button_image);\n\t\tadd_to_review.setBounds(374, 598, 177, 100);\n\t\tadd_to_review.addActionListener(new ActionListener() {\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\twords_to_add_to_review.add(words_to_spell.get(current_word_number));\n\t\t\t\tinput_from_user.requestFocusInWindow();//gets focus back to the spell here field\n\t\t\t}\n\t\t});\n\t\tadd_to_review.addMouseListener(new VoxMouseAdapter(add_to_review,null));\n\t\tadd(add_to_review);\n\t}",
"private void adicionaListeners() {\r\n\t\t\taddFocusListener(this);\r\n\t\t\taddKeyListener(this);\r\n\t\t\taddMouseListener(this);\r\n\t\t}",
"private void listenersInitiation() {\n ActionSelectors listener = new ActionSelectors();\n submit.addActionListener(listener);\n goBack.addActionListener(listener);\n }",
"public void addListeners() {\n\t\timages[TOP].setOnClickListener(top);\t\n\t\timages[BOTTOM].setOnClickListener(bottom);\n\t\timages[TOP].setOnLongClickListener(topsave);\t\n\t\timages[BOTTOM].setOnLongClickListener(bottomsave);\n }",
"public void init() {\r\n\r\n add(btnUn);\r\n add(btnDeux);\r\n add(btnTrois);\r\n add(btnQuatre);\r\n add(btnCinq);\r\n\r\n btnUn.setBounds(120, 120, 100, 75);\r\n btnDeux.setBounds(120, 310, 100, 75);\r\n btnDeux.setTransferHandler(new TransferHandler(\"icon\"));\r\n btnTrois.setBounds(360, 310, 100, 75);\r\n btnQuatre.setBounds(160, 600, 100, 75);\r\n btnQuatre.setTransferHandler(new TransferHandler(\"icon\"));\r\n btnCinq.setBounds(360, 600, 100, 75);\r\n\r\n }",
"public JButtonsPanel() {\r\n setBorder(BorderFactory.createEtchedBorder(Color.GREEN, new Color(148, 145, 140)));\r\n\r\n jOpen.setText(BTN_OPEN);\r\n jOpen.setToolTipText(MSG_OPEN);\r\n jOpen.setBounds(new Rectangle(BTN_LEFT, BTN_VSPACE, BTN_WIDTH, BTN_HEIGHT));\r\n add(jOpen);\r\n\r\n jCheckHealth.setText(BTN_CHECK_HEALTH);\r\n jCheckHealth.setToolTipText(MSG_CHECK_HEALTH);\r\n jCheckHealth.setBounds(new Rectangle(BTN_LEFT, (int) (jOpen.getBounds().getMaxY() + BTN_VSPACE), BTN_WIDTH, BTN_HEIGHT));\r\n add(jCheckHealth);\r\n\r\n jClose.setText(BTN_CLOSE);\r\n jClose.setToolTipText(MSG_CLOSE);\r\n jClose.setBounds(new Rectangle(BTN_LEFT, (int) (jCheckHealth.getBounds().getMaxY() + BTN_VSPACE), BTN_WIDTH, BTN_HEIGHT));\r\n add(jClose);\r\n\r\n jClaim.setText(BTN_CLAIM);\r\n jClaim.setToolTipText(MSG_CLAIM);\r\n jClaim.setBounds(new Rectangle(BTN_LEFT, (int) (jClose.getBounds().getMaxY() + BTN_VSPACE), BTN_WIDTH, BTN_HEIGHT));\r\n add(jClaim);\r\n\r\n jRelease.setText(BTN_RELEASE);\r\n jRelease.setToolTipText(MSG_RELEASE);\r\n jRelease.setBounds(new Rectangle(BTN_LEFT, (int) (jClaim.getBounds().getMaxY() + BTN_VSPACE), BTN_WIDTH, BTN_HEIGHT));\r\n add(jRelease);\r\n\r\n jDeviceEnable.setText(BTN_DEVICE_ENABLE);\r\n jDeviceEnable.setToolTipText(MSG_DEVICE_ENABLE);\r\n jDeviceEnable.setBounds(new Rectangle(BTN_LEFT, (int) (jRelease.getBounds().getMaxY() + BTN_VSPACE), BTN_WIDTH, BTN_HEIGHT));\r\n add(jDeviceEnable);\r\n\r\n jDeviceDisable.setText(BTN_DEVICE_DISABLE);\r\n jDeviceDisable.setToolTipText(MSG_DEVICE_DISABLE);\r\n jDeviceDisable.setBounds(new Rectangle(BTN_LEFT, (int) (jDeviceEnable.getBounds().getMaxY() + BTN_VSPACE), BTN_WIDTH, BTN_HEIGHT));\r\n add(jDeviceDisable);\r\n\r\n jClearData.setText(BTN_CLEAR_DATA);\r\n jClearData.setToolTipText(MSG_CLEAR_DATA);\r\n jClearData.setBounds(new Rectangle(BTN_LEFT, (int) (jDeviceDisable.getBounds().getMaxY() + BTN_VSPACE), BTN_WIDTH, BTN_HEIGHT));\r\n add(jClearData);\r\n\r\n jBeginEnrollCapture.setText(BTN_BEGIN_ENROLL_CAPTURE);\r\n jBeginEnrollCapture.setToolTipText(MSG_BEGIN_ENROLL_CAPTURE);\r\n jBeginEnrollCapture.setBounds(new Rectangle(BTN_LEFT, (int) (jClearData.getBounds().getMaxY() + BTN_VSPACE), BTN_WIDTH, BTN_HEIGHT));\r\n add(jBeginEnrollCapture);\r\n\r\n jEndCapture.setText(BTN_END_CAPTURE);\r\n jEndCapture.setToolTipText(MSG_END_CAPTURE);\r\n jEndCapture.setBounds(new Rectangle(BTN_LEFT, (int) (jBeginEnrollCapture.getBounds().getMaxY() + BTN_VSPACE), BTN_WIDTH, BTN_HEIGHT));\r\n add(jEndCapture);\r\n\r\n jBeginVerifyCapture.setText(BTN_BEGIN_VERIFY_CAPTURE);\r\n jBeginVerifyCapture.setToolTipText(MSG_BEGIN_VERIFY_CAPTURE);\r\n jBeginVerifyCapture.setBounds(new Rectangle(BTN_LEFT, (int) (jEndCapture.getBounds().getMaxY() + BTN_VSPACE), BTN_WIDTH, BTN_HEIGHT));\r\n add(jBeginVerifyCapture);\r\n\r\n jIdentifyMatch.setText(BTN_IDENTIFY_MATCH);\r\n jIdentifyMatch.setToolTipText(MSG_IDENTIFY_MATCH);\r\n jIdentifyMatch.setBounds(new Rectangle(BTN_LEFT, (int) (jBeginVerifyCapture.getBounds().getMaxY() + BTN_VSPACE), BTN_WIDTH, BTN_HEIGHT));\r\n add(jIdentifyMatch);\r\n\r\n jVerifyMatch.setText(BTN_VERIFY_MATCH);\r\n jVerifyMatch.setToolTipText(MSG_VERIFY_MATCH);\r\n jVerifyMatch.setBounds(new Rectangle(BTN_LEFT, (int) (jIdentifyMatch.getBounds().getMaxY() + BTN_VSPACE), BTN_WIDTH, BTN_HEIGHT));\r\n add(jVerifyMatch);\r\n\r\n jIdentify.setText(BTN_IDENTIFY);\r\n jIdentify.setToolTipText(MSG_IDENTIFY);\r\n jIdentify.setBounds(new Rectangle(BTN_LEFT, (int) (jVerifyMatch.getBounds().getMaxY() + BTN_VSPACE), BTN_WIDTH, BTN_HEIGHT));\r\n add(jIdentify);\r\n\r\n jVerify.setText(BTN_VERIFY);\r\n jVerify.setToolTipText(MSG_VERIFY);\r\n jVerify.setBounds(new Rectangle(BTN_LEFT, (int) (jIdentify.getBounds().getMaxY() + BTN_VSPACE), BTN_WIDTH, BTN_HEIGHT));\r\n add(jVerify);\r\n }",
"public void setupHoverMainMenuButtons(){\n ingredBtn.hoverProperty().addListener(new ChangeListener<Boolean>() {\n @Override\n public void changed(ObservableValue<? extends Boolean> observableValue, Boolean notHover, Boolean hover) {\n if (hover){\n //increase the drop shadow effect if the mouse is hovering over the button\n InterfaceStyling.dropShadowSelect(ingredBtn);\n } else {\n //decrease the drop shadow effect if the mouse is no longer hovering over the button\n InterfaceStyling.dropShadowDeselect(ingredBtn);\n }\n }\n });\n\n mealsBtn.hoverProperty().addListener(new ChangeListener<Boolean>() {\n @Override\n public void changed(ObservableValue<? extends Boolean> observableValue, Boolean notHover, Boolean hover) {\n if (hover){\n InterfaceStyling.dropShadowSelect(mealsBtn);\n } else {\n InterfaceStyling.dropShadowDeselect(mealsBtn);\n }\n }\n });\n\n plannerBtn.hoverProperty().addListener(new ChangeListener<Boolean>() {\n @Override\n public void changed(ObservableValue<? extends Boolean> observableValue, Boolean notHover, Boolean hover) {\n if (hover){\n InterfaceStyling.dropShadowSelect(plannerBtn);\n } else {\n InterfaceStyling.dropShadowDeselect(plannerBtn);\n }\n }\n });\n\n }",
"private void setupMouseEventHandlers() {\n this.setOnMouseClicked(event -> {\n if (event.getButton() == MouseButton.PRIMARY) {\n fireEvent(new MenuSelectedEvent(\n MenuManager.MenuType.BUILDING, this.getSpriteType(),\n event.getSceneX(), event.getSceneY()));\n }\n });\n }",
"public void addActionListeners() {\n\t\tbtnReadRow.addActionListener(this);\n\t\tbtnPrintRow.addActionListener(this);\n\t\tbtnReadCol.addActionListener(this);\n\t\tbtnPrintCol.addActionListener(this);\n\t}",
"public MouseHandler(TicTacToePanel ticTacToePanel) {\n\t}",
"private void createButton(int i){\n\t\tint x = 10, y = 120, width = 100, height = 20;\n\t\tint temp = 0;\n\t\t\n\t\tbuttons.add(new JButton(\"New Student\"));\n\t\tbuttons.get(i).addActionListener(this);\n\t\t\n\t\tfor (int a = 0; a<i; a++){\n\t\t\tx += 110;\n\t\t\ttemp++;\n\t\t\tif(temp >= Integer.parseInt(askColumns.getText())){\n\t\t\t\ty += 140;\n\t\t\t\tx = 10;\n\t\t\t\ttemp = 0;\n\t\t\t}\n\t\t\t\n\n\t\t}\n\t\t\n\t\t\n\t\tbuttons.get(i).setBounds(x, y, width, height);\n\t\tthis.add(buttons.get(i));\t\n\t\tbuttons.get(i).revalidate();\n\t\tbuttons.get(i).repaint();\n\t\t\n\t}",
"public void connectListeners(){\n for(int i=0; i<3; i++){\n for(int j=0; j<3; j++){\n grid[i][j].addActionListener(this);\n }\n }\n }",
"private void makeMouseListener() {\n myMouseListener = new MouseListener() {\n @Override\n public void mouseClicked (MouseEvent e) {\n myController.handleMapClick(e.getLocationOnScreen());\n }\n @Override\n public void mouseEntered (MouseEvent e) {\n }\n @Override\n public void mouseExited (MouseEvent e) {\n }\n @Override\n public void mousePressed (MouseEvent e) {\n }\n @Override\n public void mouseReleased (MouseEvent e) {\n }\n };\n }",
"public Mouse() {}",
"public void createButtonGrid() {\n\t\tbuttonPanel.setOpaque(false);\n\t\t\n\t\t// designs array of buttons\n\t\tfor (int counter = 1; counter <= 20; counter++) {\n\t\t\tbuttonArray[counter] = new JButton();\n\t\t\tbuttonArray[counter].setOpaque(false);\n\t\t\tbuttonArray[counter].setVisible(true);\n\t\t\tbuttonArray[counter].setBorderPainted(false);\n\t\t\tbuttonArray[counter].setHorizontalTextPosition(JButton.CENTER);\n\t\t\tbuttonArray[counter].setVerticalTextPosition(SwingConstants.CENTER);\n\t\t\tbuttonArray[counter].setFont(new Font(\"Courier\", Font.PLAIN, 15));\n\t\t\tbuttonArray[counter].setText(\"<html><font color = white>\" + Integer.toString(counter) + \"</font></html>\");\n\t\t\t// add action listener to each button\n\t\t\tbuttonArray[counter].addActionListener(eventsMain);\n\t\t\t// add each button to the container\n\t\t\tbuttonPanel.add(buttonArray[counter]);\n\t\t}\n\t\t\n\t\t// set colour for ach row of buttons\n\t\tfor (int counter = 1; counter <= 20; counter++) {\n\t\t\tif (counter >= 1 && counter < 6) {\n\t\t\t\tbuttonArray[counter].setIcon(btnBlue);\n\t\t\t} else if (counter > 5 && counter < 11) {\n\t\t\t\tbuttonArray[counter].setIcon(btnGreen);\n\t\t\t} else if (counter > 10 && counter < 16) {\n\t\t\t\tbuttonArray[counter].setIcon(btnRed);\n\t\t\t} else if (counter > 15 && counter < 21) {\n\t\t\t\tbuttonArray[counter].setIcon(btnGray);\n\t\t\t}\n\t\t}\n\t}",
"public void init()\n\t{\n\t\taddKeyListener(this);\n\t\taddMouseListener(this);\n\t\taddMouseMotionListener(this);\n\t\n\t}",
"@Override\n\tprotected void createCompButtons() {\n\t\tbtnExcelReport = new Button(getCompButtons(), SWT.NONE);\n\t\tbtnExcelReport.setText(\"Excel Report\");\n\t\tbtnExcelReport.setFont(ResourceUtils.getFont(iDartFont.VERASANS_8));\n\t\tbtnExcelReport\n\t\t.addSelectionListener(new org.eclipse.swt.events.SelectionAdapter() {\n\t\t\t@Override\n\t\t\tpublic void widgetSelected(\n\t\t\t\t\torg.eclipse.swt.events.SelectionEvent e) {\n\t\t\t\tcmdExcelReportWidgetSelected();\n\t\t\t}\n\t\t});\n\t}",
"public void createMouseListeners() {\n\t\taddMouseListener(new MouseAdapter() {\n\t\t\tpublic void mousePressed(MouseEvent e) {\n\t\t\t\t\n\t\t\t\t// Change current focus\n\t\t\t\tLineConnectPanel.this.requestFocusInWindow();\n\t\t\t\t\n\t\t\t\t// Deselect all synths\n\t\t\t\tdeselectAll();\n\t\t\t\t\n\t\t\t\t// Start dragging \n\t\t\t\tif (pointHovering && !dragging) {\n\t\t\t\t\toriginPanel = currentPanel;\n\t\t\t\t\tconnectOrigin = originPanel.getConnectionLocation(); // new\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t// Point(e.getX(),\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t// e.getY());\n\t\t\t\t\tconnectDestination = new Point(e.getPoint());\n\t\t\t\t\tdragging = true;\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t// Check if clicking a line\n\t\t\t\tif (!pointHovering) {\n\t\t\t\t\tclicked = getClickedConnection(e.getPoint(), 10);\n\t\t\t\t\tif (clicked != null) {\n\t\t\t\t\t\tclicked.setClicked(true);\n\t\t\t\t\t} else {\n\t\t\t\t\t\tfor (Connection connection : getConnections()) {\n\t\t\t\t\t\t\tconnection.setClicked(false);\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\tLineConnectPanel.this.requestFocusInWindow();\n\t\t\t\t\t}\n\t\t\t\t\trepaint();\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t@Override\n\t\t\tpublic void mouseReleased(MouseEvent e) {\n\t\t\t\t\n\t\t\t\tsuper.mouseReleased(e);\n\t\t\t\t\n\t\t\t\t// If the mouse was dragging, see if we landed on anything\n\t\t\t\tif (dragging) {\n\t\t\t\t\tdragging = false;\n\t\t\t\t\t\n\t\t\t\t\t// Found a destination panel, try and connect the points\n\t\t\t\t\tif (destinationPanel != null) {\n\t\t\t\t\t\tSystem.out.println(\"Destination box exists\");\n\t\t\t\t\t\tconnectPoints(originPanel.getConnector(), destinationPanel.getConnector());\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t// Reset origin and destination\n\t\t\t\t\toriginPanel = null;\n\t\t\t\t\tdestinationPanel = null;\n\t\t\t\t\t\n\t\t\t\t\t// Check for hovering\n\t\t\t\t\tfor (ConnectablePanel connectableBox : boxes) {\n\t\t\t\t\t\tconnectableBox.checkPointHover(e);\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\trepaint();\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\n\t\taddMouseMotionListener(new MouseAdapter() {\n\t\t\tpublic void mouseDragged(MouseEvent e) {\n\t\t\t\tconnectDestination = new Point(e.getPoint());\n\t\t\t\trepaint();\n\t\t\t\tcheckPoints(e);\n\t\t\t\t\n\t\t\t}\n\n\t\t\tpublic void mouseMoved(MouseEvent e) {\n\t\t\t\tcheckPoints(e);\n\t\t\t\t//System.out.println(\"CHecking points\");\n\t\t\t};\n\n\t\t});\n\t}",
"public ZeePanel(Spel spel) {\n this.spel = spel;\n buttons = new JButton[16][16];\n setLayout(new GridLayout(16,16,5,5));\n for (int rij=0;rij<16;rij++)\n {\n for (int kolom=0;kolom<16;kolom++)\n {\n buttons[rij][kolom] = new JButton();\n buttons[rij][kolom].setBackground(Color.CYAN);\n add(buttons[rij][kolom]);\n buttons[rij][kolom].addActionListener(this);\n buttons[rij][kolom].setActionCommand(rij + \",\" + kolom);\n }\n }\n }",
"public TicTacToePanel()\n {\n //Construct a JPanel\n super();\n \n GridLayout layout;\n \n //Make a 3x3 View\n layout = new GridLayout(3,3);\n layout.setHgap(0);\n layout.setVgap(0);\n \n //Initialize the button array\n ticTacToeButtons = new JButton[9];\n \n //Put everything together\n this.setLayout(layout);\n \n for(int i = 0; i < ticTacToeButtons.length; i++)\n {\n //Initialize Button\n ticTacToeButtons[i] = new JButton();\n \n //Now the loop can work like a for-each\n JButton myButton = ticTacToeButtons[i];\n \n //Setup the button\n myButton.setContentAreaFilled(false);\n this.add(myButton);\n }\n \n validate();\n repaint();\n }",
"private void setClickListeners() {\n buttonSomethingWentWrong.setOnClickListener(this);\n buttonSuggestion.setOnClickListener(this);\n buttonHighlightRequest.setOnClickListener(this);\n closeButton.setOnClickListener(this);\n }",
"private void initListeners() {\n appCompatButtonLogout.setOnClickListener(this);\n appCompatButtonDelete.setOnClickListener(this);\n }",
"public ButtonsPanel(final List<JButton> buttons) {\n super();\n this.buttons = buttons;\n\n init();\n }",
"void createButtons(Container cp) {\r\n JPanel pn4 = new JPanel(); // create a panel\r\n pn4.setLayout(new FlowLayout(FlowLayout.LEFT)); // set the layout\r\n for (int i=0; i<strClEx.length; i++) {\r\n // repeat for the number of the buttons\r\n bt[i] = new JButton(strClEx[i]); // create a button\r\n bt[i].addActionListener(this); // add the action listener to the button\r\n pn4.add(bt[i]); // add the button to the panel\r\n }\r\n cp.add(pn4); // add the panel to the container\r\n }",
"protected void createTools(Panel palette) {\n Tool tool = createSelectionTool();\n\n fDefaultToolButton = createToolButton(IMAGES+\"SEL\", \"Selection Tool\", tool);\n palette.add(fDefaultToolButton);\n }",
"private void setAddButtonUI() {\n addButton = new JButton(\"Add\");\n addButton.setForeground(new Color(247, 37, 133));\n addButton.addActionListener(this);\n addButton.setContentAreaFilled(false);\n addButton.setFocusPainted(false);\n addButton.setFont(new Font(\"Nunito\", Font.PLAIN, 14));\n addButton.setAlignmentX(Component.CENTER_ALIGNMENT);\n }",
"public void setListeners(){\n\t\t\n\t\tthis.addActionListener(new ActionListener() {\n\t\t\t\n\t\t\t@Override\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\t// chosen to add new patient\n\t\t\t\t\n\t\t\t\tArrayList<String> constructorInput = null;\n\t\t\t\tconstructorInput = NewPatientWindow.showInputdialog(true);\n\t\t\t\t\n\t\t\t\t// if cancel or close chosen on new patient window:\n\t\t\t\tif (constructorInput == null)\n\t\t\t\t\treturn; \n\t\t\t\t\n\t\t\t\t//else:\n\t\t\t\tBrainFreezeMain.patients.add(new Patient(\n\t\t\t\t\t\t(constructorInput.toArray( new String[constructorInput.size()]))));\n\t\t\t\tBrainFreezeMain.currentPatientIndex = BrainFreezeMain.patients.size()-1;\n\t\t\t\t\n\t\t\t\t\n\t\t\t\tLeftPanel.refreshPatientLabel(); // change to patient list, update label\n\t\t\t\tLeftPanel.refreshPatientData(); // change to patient, update data\n\t\t\t\t\t\n\t\t\t\t}\n\t\t\t});\n\t}",
"public Jeopardy3() {\n\t\taddMouseListener(this);\n\t}",
"public void init(){ \n\t\tcreatePieces(); \n\t\taddMouseListener(ChessMousePressListener.getInstance(this));\n\t}",
"private void initiateChoiceButtons() {\n\t\trock = new JButton(\"Rock\");\n\t\trock.setPreferredSize(selectionButtonSize);\n\t\tpaper = new JButton(\"Paper\");\n\t\tpaper.setPreferredSize(selectionButtonSize);\n\t\tscissors = new JButton(\"Scissors\");\n\t\tscissors.setPreferredSize(selectionButtonSize);\n\n\t\taddButtonListener();\n\t}",
"private JPanel initBtnPanel() {\n\t\tconvBtn = new JButton();\n\t\tconvBtn.addActionListener(new ConversionBtnListener());\n\t\tconvBtn.setFont(new AppFont());\n\n\t\t// A button to switch the input and output scales\n\t\tswitchBtn = new JButton();\n\t\tswitchBtn.addActionListener(new SwitchListener());\n\t\tswitchBtn.setFont(new AppFont());\n\n\t\t// The panel that displays the buttons\n\t\tJPanel btnPanel = new JPanel();\n\t\tbtnPanel.setLayout(new FlowLayout());\n\t\tbtnPanel.add(convBtn);\n\t\tbtnPanel.add(switchBtn);\n\n\t\treturn btnPanel;\n\t}",
"private void createButton(){\n addButton();\n addStartButton();\n }",
"@SuppressWarnings(\"unchecked\")\n // <editor-fold defaultstate=\"collapsed\" desc=\"Generated Code\"> \n private void initComponents() {\n\n addMouseListener(new java.awt.event.MouseAdapter() {\n public void mouseClicked(java.awt.event.MouseEvent evt) {\n mouseClickedHandler(evt);\n }\n public void mouseExited(java.awt.event.MouseEvent evt) {\n mouseExitedHandler(evt);\n }\n public void mouseEntered(java.awt.event.MouseEvent evt) {\n mouseEnteredHandler(evt);\n }\n });\n\n javax.swing.GroupLayout layout = new javax.swing.GroupLayout(this);\n this.setLayout(layout);\n layout.setHorizontalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGap(0, 400, Short.MAX_VALUE)\n );\n layout.setVerticalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGap(0, 300, Short.MAX_VALUE)\n );\n }",
"public ButtonBar() {\n scrollPane = new JScrollPane();\n scrollPane.setBorder(null);\n scrollPane.setHorizontalScrollBarPolicy(ScrollPaneConstants\n .HORIZONTAL_SCROLLBAR_NEVER);\n scrollPane.setVerticalScrollBarPolicy(ScrollPaneConstants\n .VERTICAL_SCROLLBAR_AS_NEEDED);\n scrollPane.setMinimumSize(new Dimension(0,buttonHeight\n + ((int) PlatformDefaults.getUnitValueX(\"related\").getValue()) * 2));\n \n buttons = Collections.synchronizedMap(new TreeMap<FrameContainer<?>,\n JToggleButton>(new FrameContainerComparator()));\n position = FramemanagerPosition.getPosition(\n IdentityManager.getGlobalConfig().getOption(\"ui\",\n \"framemanagerPosition\"));\n \n if (position.isHorizontal()) {\n buttonPanel = new ButtonPanel(new MigLayout(\"ins rel, fill, flowx\"),\n this);\n } else {\n buttonPanel = new ButtonPanel(new MigLayout(\"ins rel, fill, flowy\"),\n this);\n }\n scrollPane.getViewport().add(buttonPanel);\n }",
"public void initializeButtons() {\n\t\tif(null!=itemPanel)\n\t\t\tremove(itemPanel);\n\t\t\n\t\titemPanel = new JPanel();\n\t\titemPanel.setLayout(new FlowLayout());\n\t\tList<Item> allItems = itemDao.readAll();\n\t\t\n\t\t//Sort list of items based on item code.\n\t\tCollections.sort(allItems, new Comparator<Item>() {\n\t\t\t@Override\n\t\t\tpublic int compare(Item o1, Item o2) {\n\t\t\t\tCharacter c1 = o1.getCode();\n\t\t\t\tCharacter c2 = o2.getCode();\n\t\t\t\treturn c1.compareTo(c2);\n\t\t\t}\n\t\t});\n\t\t\n\t\tfor(final Item item : allItems){\n\t\t\tJButton addButton = new JButton(item.getName());\n\t\t\tDeal deal = item.getDeal();\n\t\t\tString dealName = deal == null ? \"\" : \"<br>\" + deal.getName();\n\t\t\t//Set tool tip as description and deal if available\n\t\t\taddButton.setToolTipText(\"<html>\"+item.getDescription()+\"<br>Price: $\"+item.getPrice()\n\t\t\t\t\t+ dealName+\"</html>\");\n\t\t\t//Add item to cart when pressed, also update cartLabel.\n\t\t\taddButton.addActionListener(new ActionListener() {\n\t\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\t\tcart.addItem(item.getCode());\n\t\t\t\t\tcartLabel.setText(cart.size()+ \" items in your cart\");\n\t\t\t\t}\n\t\t\t});\n\t\t\t//addButton.setBounds(10, frameHeight, 75, 20);\n\t\t\taddButton.setSize(new Dimension(75, 20));\n\t\t\titemPanel.add(addButton);\n\t\t}\n\t\t\n\t\titemPanel.setBounds(10, 30, 280, 150);\n\t\tadd(itemPanel);\n\t\tMain.getFrame().setVisible(true);;\n\t}",
"public FrameEjercicio1() {\n super(\"Control de Ratón\");\n setLayout(new FlowLayout());\n setFocusable(true);\n\n class MouseHandler extends MouseAdapter { // Uso el adaptador para no escribir funciones vacías\n\n @Override\n public void mouseExited(MouseEvent e) {\n setTitle(titulo);\n }\n\n @Override\n public void mouseMoved(MouseEvent e) {\n\n if(e.getSource().getClass() == JButton.class){\n setTitle(String.format(titulo + \" - (X:%d Y:%d)\", e.getX() + (int)((JButton)e.getSource()).getBounds().getX(), e.getY() + (int)((JButton)e.getSource()).getBounds().getY())); \n }\n else{\n setTitle(String.format(titulo + \" - (X:%d Y:%d)\", e.getX(), e.getY()));\n }\n }\n\n @Override\n public void mousePressed(MouseEvent e) {\n if (e.getButton() == MouseEvent.BUTTON1) {\n btnClickIzquierdo.setBackground(colorFondoBotones);\n } else if (e.getButton() == MouseEvent.BUTTON3) {\n btnClickDerecho.setBackground(colorFondoBotones);\n }\n }\n\n @Override\n public void mouseReleased(MouseEvent e) {\n btnClickIzquierdo.setBackground(null);\n btnClickDerecho.setBackground(null);\n }\n }\n\n MouseHandler mh = new MouseHandler(); // Creo el MouseHandler\n // Añado los listeners al ContentPane\n getContentPane().addMouseListener(mh);\n getContentPane().addMouseMotionListener(mh);\n \n addKeyListener(this); // Añado el KeyListener\n\n btnClickIzquierdo = new JButton(\"Click Izquierdo\");\n btnClickIzquierdo.setSize(btnClickIzquierdo.getPreferredSize());\n btnClickIzquierdo.addMouseMotionListener(mh); // También añado el MotionListener a los botones para que muestre las coordenadas aún cuando esté encima de ellos\n add(btnClickIzquierdo);\n\n btnClickDerecho = new JButton(\"Click Derecho\");\n btnClickDerecho.setSize(btnClickDerecho.getPreferredSize());\n btnClickDerecho.addMouseMotionListener(mh);\n add(btnClickDerecho);\n\n lblTeclas = new JLabel(\"Teclas\");\n lblTeclas.setSize(lblTeclas.getPreferredSize());\n add(lblTeclas);\n\n }",
"protected void init() {\r\n\t\tsetBackground(Color.black);\r\n\t\tsetForeground(Color.white);\r\n\t\taddMouseListener(this);\r\n\t\taddMouseMotionListener(this);\r\n\t\tcreateSelection();\r\n\t\tsel.addListener(this);\r\n\t\tcreateSection();\r\n\t\tsection.addListener(this);\r\n\t\tsetOpaque(true);\r\n\t\tremoveAll();\r\n\t}",
"public BoardControl() {\r\n\t\t\tsuper();\r\n\t\t\tthis.setLayout(null);\r\n\r\n\t\t\tbtnCrt = new JButton(\"创建\");\r\n\t\t\tbtnCrt.setBounds(0, 300, 130, 40);\r\n\t\t\tbtnCrt.setFont(new Font(\"楷体\", Font.BOLD, 30));\r\n\t\t\tbtnCrt.setBackground(Color.gray);\r\n\t\t\tadd(btnCrt);\r\n\r\n\t\t\tbtnJin = new JButton(\"加入\");\r\n\t\t\tbtnJin.setBounds(0, 360, 130, 40);\r\n\t\t\tbtnJin.setFont(new Font(\"楷体\", Font.BOLD, 30));\r\n\t\t\tbtnJin.setBackground(Color.gray);\r\n\t\t\tadd(btnJin);\r\n\r\n\t\t\tbtnSrd = new JButton(\"认输\");\r\n\t\t\tbtnSrd.setBounds(0, 420, 130, 40);\r\n\t\t\tbtnSrd.setFont(new Font(\"楷体\", Font.BOLD, 30));\r\n\t\t\tbtnSrd.setBackground(Color.gray);\r\n\t\t\tadd(btnSrd);\r\n\r\n\t\t\tbtnExt = new JButton(\"退出\");\r\n\t\t\tbtnExt.setBounds(0, 480, 130, 40);\r\n\t\t\tbtnExt.setFont(new Font(\"楷体\", Font.BOLD, 30));\r\n\t\t\tbtnExt.setBackground(Color.gray);\r\n\t\t\tadd(btnExt);\r\n\r\n\t\t\tButtonAct cbut = new ButtonAct();\r\n\t\t\tbtnCrt.addActionListener(cbut);\r\n\t\t\tbtnJin.addActionListener(cbut);\r\n\t\t\tbtnSrd.addActionListener(cbut);\r\n\t\t\tbtnExt.addActionListener(cbut);\r\n\t\t}",
"public void addActionListeners(){\n terugButton.addActionListener(this);\n klaarButton.addActionListener(this);\n\n }"
] | [
"0.65992945",
"0.65627223",
"0.65009177",
"0.637317",
"0.63252586",
"0.6316384",
"0.6310154",
"0.62886584",
"0.6262154",
"0.62408113",
"0.6231322",
"0.62190723",
"0.62146896",
"0.6203535",
"0.61982894",
"0.6157288",
"0.6073742",
"0.60704744",
"0.60661054",
"0.6062264",
"0.6050908",
"0.60176027",
"0.59826994",
"0.5973022",
"0.5972114",
"0.5970556",
"0.59576136",
"0.5943007",
"0.5938906",
"0.5923118",
"0.590608",
"0.5900992",
"0.58975726",
"0.5890559",
"0.5888407",
"0.58822346",
"0.58743286",
"0.58713377",
"0.5868785",
"0.58670574",
"0.58583826",
"0.5856707",
"0.5838308",
"0.58368397",
"0.5820839",
"0.5816743",
"0.58166134",
"0.5815736",
"0.5803004",
"0.58014023",
"0.57970846",
"0.579545",
"0.57874155",
"0.57873905",
"0.57870585",
"0.57853705",
"0.5785205",
"0.57824105",
"0.5781038",
"0.5780801",
"0.57796514",
"0.5773933",
"0.5757115",
"0.5739985",
"0.57304263",
"0.5725034",
"0.5717753",
"0.57097185",
"0.5709329",
"0.570778",
"0.57038486",
"0.5697318",
"0.56873876",
"0.5682458",
"0.5681703",
"0.5676331",
"0.5675177",
"0.5672149",
"0.56683254",
"0.5666461",
"0.56622386",
"0.56602484",
"0.5653334",
"0.5650982",
"0.56499785",
"0.56418544",
"0.5639959",
"0.56395644",
"0.56356597",
"0.56352544",
"0.56333506",
"0.563226",
"0.56311005",
"0.56286997",
"0.56204486",
"0.56198335",
"0.56163275",
"0.56159127",
"0.5611713",
"0.5610514"
] | 0.58172834 | 45 |
This test will run multiple parallel conversions, using 8 office processes. Just change the MAX_ constants to control the numbers of conversion, threads and maximum conversion per office process allowed. | @Test
public void runParallelConversions() throws Exception {
final String pattern = "%d{ISO8601} %-5p [%c{3}] [%t] %m%n";
Logger.getRootLogger().removeAllAppenders();
// Create console appender
final ConsoleAppender console = new ConsoleAppender();
console.setWriter(new OutputStreamWriter(System.out));
console.setLayout(new PatternLayout(pattern));
console.setThreshold(Level.DEBUG);
console.activateOptions();
Logger.getRootLogger().addAppender(console);
// Keep a log file to be able to see if an error occurred
final FileAppender fileAppender = new FileAppender();
fileAppender.setName("FileLogger");
fileAppender.setFile("test-output/" + StressITest.class.getSimpleName() + "/test.log");
fileAppender.setLayout(new PatternLayout(pattern));
fileAppender.setThreshold(Level.DEBUG);
fileAppender.setAppend(true);
fileAppender.activateOptions();
Logger.getRootLogger().addAppender(fileAppender);
// Configure the office manager in a way that maximizes possible race conditions.
final OfficeManager officeManager =
DefaultOfficeManager.builder()
.portNumbers(2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009)
.maxTasksPerProcess(MAX_TASKS_PER_PROCESS)
.build();
final DocumentConverter converter = DefaultConverter.make(officeManager);
final DocumentFormatRegistry formatRegistry = converter.getFormatRegistry();
officeManager.start();
try {
final File inputFile = new File("src/integTest/resources/documents/test." + INPUT_EXTENSION);
final Thread[] threads = new Thread[MAX_RUNNING_THREADS];
boolean first = true;
int t = 0;
final DocumentFormat inputFormat = formatRegistry.getFormatByExtension(INPUT_EXTENSION);
final DocumentFormat outputFormat = formatRegistry.getFormatByExtension(OUTPUT_EXTENSION);
for (int i = 0; i < MAX_CONVERSIONS; i++) {
final File outputFile = File.createTempFile("test", "." + outputFormat.getExtension());
outputFile.deleteOnExit();
// Converts the first document without threads to ensure everything is OK.
if (first) {
converter.convert(inputFile).as(inputFormat).to(outputFile).as(outputFormat).execute();
first = false;
}
logger.info("Creating thread " + t);
final Runner r = new Runner(inputFile, outputFile, inputFormat, outputFormat, converter);
threads[t] = new Thread(r);
threads[t++].start();
if (t == MAX_RUNNING_THREADS) {
for (int j = 0; j < t; j++) {
threads[j].join();
}
t = 0;
}
}
// Wait for remaining threads.
for (int j = 0; j < t; j++) {
threads[j].join();
}
} finally {
officeManager.stop();
}
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"@Override\r\n\t\t\tpublic void autStartParallelProcess() {\n\t\t\t\t\r\n\t\t\t}",
"@Override\r\n\t\t\tpublic void autStartParallelProcess() {\n\t\t\t\t\r\n\t\t\t}",
"@Override\r\n\t\t\tpublic void autStartParallelProcess() {\n\t\t\t\t\r\n\t\t\t}",
"@Override\r\n\t\t\tpublic void autStartParallelProcess() {\n\t\t\t\t\r\n\t\t\t}",
"@Override\r\n\t\t\tpublic void autStartParallelProcess() {\n\t\t\t\t\r\n\t\t\t}",
"@Override\r\n\t\t\tpublic void autStartParallelProcess() {\n\t\t\t\t\r\n\t\t\t}",
"@Override\r\n\t\t\tpublic void autStartParallelProcess() {\n\t\t\t\t\r\n\t\t\t}",
"@Override\r\n\t\t\t\tpublic void autStartParallelProcess() {\n\t\t\t\t\t\r\n\t\t\t\t}",
"@Override\r\n\t\t\t\tpublic void autStartParallelProcess() {\n\t\t\t\t\t\r\n\t\t\t\t}",
"@Test\n public void test4(){\n System.out.println(Runtime.getRuntime().availableProcessors());\n }",
"@Test\n public void testMultiJCPCalls() throws Exception {\n \n Topology topology = newTopology(\"testMultiJCPCalls\");\n \n for (int i = 0 ; i < 10; i++)\n topology.addJobControlPlane();\n \n submitAndCheckJCPIsThere(topology); \n }",
"public static void main(String[] args) {\n\n testWithNElementsParallel(1000);\n testWithNElementsParallel(10000);\n testWithNElementsParallel(100000);\n testWithNElementsParallel(1000000);\n testWithNElementsParallel(5000000);\n testWithNElementsParallel(10000000);\n }",
"public static void main(String a[]) throws InterruptedException {\n System.out.println(PiDigits.getDigits(1, 1000000, 500));\n// long end3 = System.nanoTime();\n// System.out.println(\"parallel code took :\"+(double)(end3-start3)/1e9 +\" seconds\");\n//\t\tString s1 = new String(bytesToHex(PiDigits.getDigits(1, 100)));\n// \tString s2 = new String(PiDigits.getDigits(1, 100, 1));\n// System.out.println(s1.equals(s2));\n\t}",
"public static void main(String[] args) {\n ForkJoinPool forkJoinPool = new ForkJoinPool(Runtime.getRuntime().availableProcessors());\n\n //Create three FolderProcessor tasks. Initialize each one with a different folder path.\n FolderProcessor desktop = new FolderProcessor(\"/Users/neeraj/Desktop\", \"log\");\n FolderProcessor downloads = new FolderProcessor(\"/Users/neeraj/Downloads\", \"log\");\n FolderProcessor github = new FolderProcessor(\"/Users/neeraj/Projects/office\", \"log\");\n\n // Execute the 3 tasks in the ForkJoinPool.\n forkJoinPool.execute(desktop);\n forkJoinPool.execute(downloads);\n forkJoinPool.execute(github);\n\n //Write to the console information about the status of the pool every second\n //until the three tasks have finished their execution.\n do {\n System.out.printf(\"******************************************\\n\");\n System.out.printf(\"Main: Parallelism: %d\\n\", forkJoinPool.getParallelism());\n System.out.printf(\"Main: Active Threads: %d\\n\", forkJoinPool.getActiveThreadCount());\n System.out.printf(\"Main: Task Count: %d\\n\", forkJoinPool.getQueuedTaskCount());\n System.out.printf(\"Main: Steal Count: %d\\n\", forkJoinPool.getStealCount());\n System.out.printf(\"******************************************\\n\");\n try {\n TimeUnit.SECONDS.sleep(1);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n } while ((!desktop.isDone()) || (!downloads.isDone()) || (!github.isDone()));\n\n //Shut down ForkJoinPool using the shutdown() method.\n forkJoinPool.shutdown();\n\n //Write the number of results generated by each task to the console.\n List<String> results;\n results = desktop.join();\n System.out.printf(\"Desktop: %d files found.\\n\", results.size());\n results = downloads.join();\n System.out.printf(\"Downloads: %d files found.\\n\", results.size());\n results = github.join();\n System.out.printf(\"Github: %d files found.\\n\", results.size());\n\n }",
"public static void main(String[] args) {\n ExecutorService executorService = Executors.newFixedThreadPool(100);\n\n for (int i=0;i<10000000;i++){\n executorService.execute(()->{\n System.out.println(generateTransId());\n });\n }\n }",
"public static void xmlclassgeneration_parallel_web(Integer noOfBrowsers, String executionType) {\n\t\tSystem.out.println(noOfBrowsers);\r\n\t\tSystem.out.println(executionType);\r\n\r\n\t\t/**\r\n\t\t * Add Listener Classes\r\n\t\t */\r\n\t\t// Thread count need to be provided for running scripts sequential\r\n\t\tif (listner_count < count) {\r\n\t\t\t// add pdf listener\r\n\t\t\tsuite.addListener(\"com.vil.web.reports.MyExtentListners\");\r\n\t\t\t// suite.addListener(\"com.utteshappend.pdfngreport.PDFReportListener\");\r\n\t\t\tlistner_count = listner_count + 1;\r\n\t\t}\r\n\r\n\t\t/*\r\n\t\t * Add Parameters for suite level\r\n\t\t */\r\n\r\n\t\tHashMap<String, String> testParameters1 = new HashMap<String, String>();\r\n\t\ttestParameters1.put(\"pdfngreport-properties\", \"pdfngreport.properties\");\r\n\t\tsuite.setParameters(testParameters1);\r\n\t\tsuite.setGroupByInstances(false);\r\n\t\tsuite.setThreadCount(noOfBrowsers);\r\n\t\tsuite.setParallel(\"tests\");\r\n\r\n\t\t// find total module count from ModuleExecutionControl\r\n\t\t// sheet config.xlsx file\r\n\t\tArrayList<String> moduleNames = new ArrayList<String>();\r\n\t\tint totalModuleRowCount = ExcelLibrary.getExcelRowCount(\"./config/config.xlsx\", \"ModuleExecutionControl\");\r\n\t\tfor (int i = 1; i <= totalModuleRowCount; i++) {\r\n\t\t\tif (ExcelLibrary\r\n\t\t\t\t\t.getExcelData(\"./config/config.xlsx\", \"ModuleExecutionControl\", i, GenericLib\r\n\t\t\t\t\t\t\t.getHeaderColumnIndex(\"./config/config.xlsx\", \"ModuleExecutionControl\", \"Execution_Status\"))\r\n\t\t\t\t\t.trim().equals(\"Yes\")) {\r\n\t\t\t\tmoduleNames\r\n\t\t\t\t\t\t.add(ExcelLibrary.getExcelData(\"./config/config.xlsx\", \"ModuleExecutionControl\", i, GenericLib\r\n\t\t\t\t\t\t\t\t.getHeaderColumnIndex(\"./config/config.xlsx\", \"ModuleExecutionControl\", \"ModuleName\")));\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\t// Iterate loop based number of browsers to parameters to <test> in <suite>\r\n\t\tArrayList<String> browserNames = new ArrayList<String>();\r\n\t\tfor (int i = 1; i <= noOfBrowsers; i++) {\r\n\t\t\tbrowserNames.add(ExcelLibrary.getExcelData(\"./config/config.xlsx\", \"config\", i,\r\n\t\t\t\t\tGenericLib.getHeaderColumnIndex(\"./config/config.xlsx\", \"config\", \"Browser Name\")));\r\n\t\t}\r\n\r\n\t\tif (noOfBrowsers > 1) {\r\n\t\t\tif (moduleNames.size() != 0) {\r\n\r\n\t\t\t\tfor (int i = 1; i <= noOfBrowsers; i++) {\r\n\t\t\t\t\tXmlTest test = new XmlTest(suite);\r\n\t\t\t\t\tHashMap<String, String> testCases = new HashMap<String, String>();\r\n\r\n\t\t\t\t\tfor (int l = 0; l < moduleNames.size(); l++) {\r\n\t\t\t\t\t\tString modulenames[] = GenericLib.testConfigutration(\"./config/config.xlsx\",\r\n\t\t\t\t\t\t\t\tmoduleNames.get(l));\r\n\t\t\t\t\t\ttestCases.put(moduleNames.get(l),\r\n\t\t\t\t\t\t\t\tArrays.toString(modulenames).replace(\"[\", \"\").replace(\"]\", \"\"));\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t\tSystem.out.println(\"loop\" + i);\r\n\t\t\t\t\tSystem.out.println(testCases.size());\r\n\t\t\t\t\tSet<String> keys = testCases.keySet();\r\n\t\t\t\t\tArrayList<String> testNames = new ArrayList<String>();\r\n\t\t\t\t\tfor (String key : keys) {\r\n\t\t\t\t\t\ttestNames.add(key);\r\n\t\t\t\t\t\tSystem.out.println(key);\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t\tHashMap<String, String> testParameters = new HashMap<String, String>();\r\n\r\n\t\t\t\t\ttestParameters.put(\r\n\t\t\t\t\t\t\tExcelLibrary.getExcelData(\"./config/config.xlsx\", \"config\", 0,\r\n\t\t\t\t\t\t\t\t\tGenericLib.getHeaderColumnIndex(\"./config/config.xlsx\", \"config\", \"Browser Name\")),\r\n\t\t\t\t\t\t\tExcelLibrary.getExcelData(\"./config/config.xlsx\", \"config\", i,\r\n\t\t\t\t\t\t\t\t\tGenericLib.getHeaderColumnIndex(\"./config/config.xlsx\", \"config\", \"Browser Name\")));\r\n\t\t\t\t\tfor (Map.Entry entry : testParameters.entrySet()) {\r\n\t\t\t\t\t\tSystem.out.println(entry.getKey() + \" : \" + entry.getValue());\r\n\t\t\t\t\t}\r\n\t\t\t\t\tString testname = Arrays.toString(testNames.toArray());\r\n\t\t\t\t\t// System.out.println(testname);\r\n\r\n\t\t\t\t\ttest.setName(\"Regression_Test_\" + browserNames.get(i - 1) + \"_\" + i);\r\n\t\t\t\t\t// test.setPreserveOrder(\"true\");\r\n\t\t\t\t\ttest.setPreserveOrder(true);\r\n\t\t\t\t\ttest.setParameters(testParameters);\r\n\t\t\t\t\t// testParameters.clear();\r\n\t\t\t\t\ttest.setThreadCount(noOfBrowsers);\r\n\t\t\t\t\tArrayList<XmlClass> classes = new ArrayList<XmlClass>();\r\n\t\t\t\t\tIterator it = testCases.entrySet().iterator();\r\n\t\t\t\t\twhile (it.hasNext()) {\r\n\t\t\t\t\t\tSystem.out.println(\"inside\");\r\n\t\t\t\t\t\tMap.Entry pair = (Map.Entry) it.next();\r\n\t\t\t\t\t\tSystem.out.println(pair.getKey() + \" = \" + pair.getValue());\r\n\t\t\t\t\t\tString[] testcases = pair.getValue().toString().replace(\",\", \"\").split(\" \");\r\n\t\t\t\t\t\tSystem.out.println(\"Test cases length \" + testcases.length);\r\n\r\n\t\t\t\t\t\t// Add all test cases in before creating xml file\r\n\t\t\t\t\t\tfor (int k = 0; k < testcases.length; k++) {\r\n\t\t\t\t\t\t\tString className = \"com.vil.web.tests.\" + pair.getKey() + \".\"\r\n\t\t\t\t\t\t\t\t\t+ testcases[k].replace(\"]\", \"\");\r\n\t\t\t\t\t\t\tSystem.out.println(className);\r\n\t\t\t\t\t\t\tclasses.add(new XmlClass(className));\r\n\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\ttest.setXmlClasses(classes);\r\n\t\t\t\t\t\tit.remove();\r\n\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\r\n\t\t\t}\r\n\t\t} else if (moduleNames.size() == 0) {\r\n\t\t\tSystem.out.println(\r\n\t\t\t\t\t\"Please select modules which you wan execute in under config_execution --> Test Execution Control\");\r\n\t\t} else {\r\n\t\t\tSystem.out.println(\"Please configure > 1 browser in config.xlsx--> config for Parallel execution\");\r\n\t\t}\r\n\r\n\t\tsuites.add(suite);\r\n\t\tsuite.setName(\"Suite\");\r\n\t\ttry {\r\n\t\t\tFileWriter writer = new FileWriter(\"testng_\" + \"web_parallel\" + \".xml\");\r\n\t\t\twriter.write(suite.toXml());\r\n\t\t\twriter.flush();\r\n\t\t\twriter.close();\r\n\t\t} catch (Exception e) {\r\n\r\n\t\t}\r\n\t\ttry {\r\n\t\t\tThread.sleep(2000);\r\n\t\t} catch (InterruptedException e) {\r\n\t\t\te.printStackTrace();\r\n\t\t}\r\n\t}",
"public static void main(String[] args){\n\t\tint increment=1;\n\t\tfor(int m=0;m<=5000;m+=increment){\n\t\t\tif(m==10)\n\t\t\t\tincrement=5;\n\t\t\tif(m==100)\n\t\t\t\tincrement=100;\n\t\t\tif(m==500)\n\t\t\t\tincrement=500;\n\n\t\t\tfor(int l=0;l<30;++l){\n\t\t\t\tdouble[][][] AFFINITY3=new double[Task.TYPES_OF_TASK_NUMBER][Task.TYPES_OF_TASK_NUMBER][Task.TYPES_OF_TASK_NUMBER];\n\t\t\t\tRandom r=new Random(l);\n\t\t\t\tdouble affinity;\n\t\t\t\tfor(int i=0;i<Task.TYPES_OF_TASK_NUMBER;++i){\n\t\t\t\t\tfor(int j=0;j<Task.TYPES_OF_TASK_NUMBER;++j){\n\t\t\t\t\t\tfor(int k=0;k<Task.TYPES_OF_TASK_NUMBER;++k){\n\t\t\t\t\t\t\tdo{\n\t\t\t\t\t\t\t\taffinity=r.nextDouble();\n\t\t\t\t\t\t\t}while(affinity==0);\n\t\t\t\t\t\t\tAFFINITY3[i][j][k]=AFFINITY3[i][k][j]=AFFINITY3[k][i][j]=AFFINITY3[j][i][k]=AFFINITY3[k][j][i]=AFFINITY3[j][k][i]=affinity;\t\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tList<Node> infrastructure=new ArrayList<>();\n\t\t\t\tfor(int i=0; i<TEST_NUMBER_OF_NODES;++i)\n\t\t\t\t\tinfrastructure.add(new Node(TEST_NUMBER_OF_CORES, TEST_RAM_SIZE));\n\t\t\t\tList<Task> tasks=new ArrayList<>();\n\t\t\t\tTaskType[] types=TaskType.values();\n\t\t\t\tfor(int i=0;i<TEST_NUMBER_OF_PROCESS;++i){\n\t\t\t\t\tTaskType type=types[r.nextInt(Task.TYPES_OF_TASK_NUMBER)];\n\t\t\t\t\tint instanceNumber=r.nextInt(101)+10;//from 10 to 100 instances\n\t\t\t\t\tint coresPerInstance=r.nextInt(12)+1;//from 1 to 12\n\t\t\t\t\tint ramPerinstance=r.nextInt(12*1024+101)+100;//from 100MB to 12GB\n\t\t\t\t\tdouble baseTime=r.nextInt(10001)+1000;//from 100 cycles to 1000\n\t\t\t\t\ttasks.add(new Task(type,instanceNumber,coresPerInstance,ramPerinstance,baseTime));\n\t\t\t\t}\n\t\t\t\tList<Integer> arrivalOrder=new ArrayList<>();\n\t\t\t\tint tasksSoFar=0;\n\t\t\t\tdo{\n\t\t\t\t\ttasksSoFar+=r.nextInt(11);\n\t\t\t\t\tarrivalOrder.add((tasksSoFar<tasks.size())?tasksSoFar:tasks.size());\n\t\t\t\t}while(tasksSoFar<tasks.size());\n\t\t\t\tfinal Scheduler scheduler=new AffinityAwareFifoScheduler(tasks, arrivalOrder, infrastructure,AFFINITY3,AffinityType.NORMAL,m);\n\t\t\t\tThread t=new Thread(new Runnable() {\t\t\n\t\t\t\t\t@Override\n\t\t\t\t\tpublic void run() {\n\t\t\t\t\t\tscheduler.runScheduler();\n\t\t\t\t\t}\n\t\t\t\t});\n\t\t\t\tt.start();\n\t\t\t\ttry {\n\t\t\t\t\tt.join();\n\t\t\t\t} catch (InterruptedException e) {\n\t\t\t\t\t// TODO Auto-generated catch block\n\t\t\t\t\te.printStackTrace();\n\t\t\t\t}\n\t\t\t\tSystem.out.println(\"Finished running.\");\n\t\t\t}\n\t\t}\n\t}",
"private static void runTests() {\r\n\t\tfor (int i = 0; i < testFiles.length; i++) {\r\n\t\t\tConverter file = new Converter(testFiles[i]);\r\n\t\t\tfile.convert();\r\n\t\t\tSystem.out.println(\"---------\");\r\n\t\t}\r\n\t}",
"@Test \n\t public static void Execute_Sessions() throws Exception\n\t {\n\t\t int MYTHREADS = 30; \n\t\t // ExecutorService pool = Executors.newFixedThreadPool(MYTHREADS); \n\t\t //CountDownLatch latch = new CountDownLatch(totalNumberOfTasks);\n\t\t ExecutorService executor = Executors.newFixedThreadPool(MYTHREADS);\n\t\t \n\t\t// CountDownLatch latch = new CountDownLatch(15);\n\t\t //ExecutorService executor = Executors.newFixedThreadPool(13);\n\t\t// ExecutorService pool = Executors.newFixedThreadPool(MYTHREADS); \n\t\t \n\t\t int NumberofTestScripts = 0;\n\t\t\tExcelApiTest3 eat = new ExcelApiTest3();\n\t\t\tNumberofTestScripts=eat.getRowCount(\"E://Batch2Source//Regression1.xls\",\"Sheet1\");\n\t\t\tSystem.out.println(\"Numberof TestScripts Count Regression1.xls :\"+NumberofTestScripts);\n\t\t\t\n\t\t\t\t\t\n\t\t\tfor (int iRow1=1;iRow1<NumberofTestScripts;iRow1++) // Number of Test Cases in Regression Sheet\n\t\t\t{\n\t\t\t\tRunnable worker = new DriverTest124(iRow1);\n\t\t\t\tThread.sleep(3000);\n\t\t\t\t\n\t \t\texecutor.execute(worker);\n\t \t\t\n\n\t\t\t\t//executor.awaitTermination(5, TimeUnit.HOURS);\n\t \t\t//Runnable worker = new WorkerThread(\"\" + iRow1);\n\t // executor.execute(worker);\n\t\t\t\t//Future f = executor.submit(new DriverTest124(iRow1));\n\t\t\t\t//f.get(60,TimeUnit.SECONDS);\n\t\t\t\t//Thread.sleep(9000);\n\t \t\n\t\n\t\t\t\t/*\n\t \t\tSystem.out.println(\"First Thread ID:\"+Thread.currentThread().getId());\n\t\t\t\tSystem.out.println(\"First Thread status:\"+Thread.currentThread().getState());\n\t\t\t\tSystem.out.println(\"First Thread Name:\"+Thread.currentThread().getName());\n\t\t\t\t\n\t\t\n\t\t\t\t String str=\"Row Iteration in for loop- \" + String.valueOf(iRow1);\n\t\t\t\t System.out.println(\"Row Iteration in for loop- \"+str);\n\t\t\t\t\n\t\t\t\tSystem.out.println(\"Thread ID:\"+Thread.currentThread().getId());\n\t\t\t\tSystem.out.println(\"Thread status:\"+Thread.currentThread().getState());\n\t\t\t\tSystem.out.println(\"Thread Name:\"+Thread.currentThread().getName());*/\n\t\t\t\t\n\t\t\t\t/*if(Thread.currentThread().isInterrupted())\n\t\t\t\t{\n\t\t\t\t\tSystem.out.println(\"Thread status:\"+Thread.currentThread().getId());\n\t\t\t\t\tSystem.out.println(\"Thread status:\"+Thread.currentThread().getState());\n\t\t\t\t}*/\n\t\t\t\t\n\t \t\n\t\t\t\t//f.wait();\n\t\t\t\t//System.out.println(\"Task Status - :\"+f.isCancelled());\n\t\t\t\t\n\t\t\t\t\t//f.isDone();\n\t \t\t\n\t\t\t\n\t\t\t}\n\t\t\t\n\t\t\t\n\t\t\t\n\n\t\t\t/*try {\n\t\t\t latch.await();\n\t\t\t} catch (InterruptedException E) {\n\t\t\t\t\n\t\t\t}\n\t\t\t*/\n\t\t\t\n\t\t\tSystem.out.println(\"Finish tasks\");\n\t\t\t\n\t\t\t//awaitTerminationAfterShutdown\n\t\t\t\t\t\n\t\t\n\t\t\texecutor.shutdown();\n\t\t\texecutor.awaitTermination(5, TimeUnit.HOURS);\n\t\t\t\n\t\t\t// Wait until all threads are finish\n\t\t//\twhile (!executor.isTerminated()) {\n\t \n\t\t//\t}\n\t\t\tSystem.out.println(\"\\nFinished all threads\");\n\t\t\t\n\t\t\t\n\t\t}",
"@Override\r\n public int getMaxConcurrentProcessingInstances() {\r\n return 1;\r\n }",
"public static void main(String[] args)\n throws InterruptedException\n {\n // Defining threads to accept the jobs\n // ----------------------------------------------------------\n Thread thread1 = new Intermediate(10, \"INT01\");// Instantiate thread1\n Thread thread2 = new Intermediate(50, \"INT02\");// Instantiate thread2\n Thread thread3 = new CPUBound(60, \"CPU01\");// Instantiate thread3\n Thread thread4 = new CPUBound(70, \"CPU02\");// Instantiate thread4\n Thread thread5 = new IOBound(System.in, \"IO01\");// Instantiate thread5\n Thread thread6 = new IOBound(System.in, \"IO02\");// Instantiate thread6\n Thread thread7 = new Intermediate(82, \"INT03\");// Instantiate thread7\n Thread thread8 = new CPUBound(80, \"CPU03\");// Instantiate thread8\n\n // Creating a ArrayList of threads and adding the jobs to the ArrayList\n // ----------------------------------------------------------\n ArrayList<Thread> threadList = new ArrayList<Thread>();\n threadList.add(thread1);\n threadList.add(thread2);\n threadList.add(thread3);\n threadList.add(thread4);\n threadList.add(thread5);\n threadList.add(thread6);\n threadList.add(thread7);\n threadList.add(thread8);\n\n // Creating a FCFS object and running it with the created ArrayList\n // object\n // ----------------------------------------------------------\n FCFS fcfs = new FCFS(threadList);\n fcfs.run();\n\n // Displaying the results of the FCFS run\n // ----------------------------------------------------------\n\n System.out.println(\"----------------FCFS-----------------------------\");\n for (String key : fcfs.getRun_times().keySet())\n System.out.println(key + \" => \" + fcfs.getRun_times().get(key));\n System.out.println(\"-------------------------------------------------\");\n\n // Defining a Hash Map with key Long and value Thread. To pair\n // each unique time with a process\n // ----------------------------------------------------------\n Map<Long, Thread> threadList2 = new HashMap<Long, Thread>();\n threadList2.put(fcfs.getRun_times().get(thread1.getName()), thread1);\n threadList2.put(fcfs.getRun_times().get(thread2.getName()), thread2);\n threadList2.put(fcfs.getRun_times().get(thread3.getName()), thread3);\n threadList2.put(fcfs.getRun_times().get(thread4.getName()), thread4);\n threadList2.put(fcfs.getRun_times().get(thread5.getName()), thread5);\n threadList2.put(fcfs.getRun_times().get(thread6.getName()), thread6);\n threadList2.put(fcfs.getRun_times().get(thread7.getName()), thread7);\n threadList2.put(fcfs.getRun_times().get(thread8.getName()), thread8);\n\n // Creating a SJF object and running it with the created ArrayList\n // object\n // ----------------------------------------------------------\n SJF sjf = new SJF(threadList2);\n sjf.run();\n\n // Displaying the results of the SJF run\n // ----------------------------------------------------------\n System.out.println(\"-----------------SJF-----------------------------\");\n for (String key : sjf.getRun_times().keySet())\n System.out.println(key + \" => \" + sjf.getRun_times().get(key));\n System.out.println(\"-------------------------------------------------\");\n\n // Creating a RoundRobin object and running it with the previously\n // created ArrayList object holding our processes.\n // ----------------------------------------------------------\n RoundRobin roundRobin = new RoundRobin(threadList);\n roundRobin.run();\n\n // Displaying the results of the RoundRobin run\n // ----------------------------------------------------------\n System.out.println(\"-----------------Round Robin---------------------\");\n for (String key : roundRobin.getRun_times().keySet())\n System.out.println(key + \" => \" + sjf.getRun_times().get(key));\n System.out.println(\"-------------------------------------------------\");\n\n }",
"public static void main(String[] args) throws InterruptedException {\n\t\tXls_Reader excel = new Xls_Reader(Constants.TestSuitePath);\n\t\t\n\t\t//Selected suite\n\t\tConstants.SelectedSuite=excel.getCellData(Constants.TestSuiteSheetname, 1, 3);\n\t\t\n\t\t//Generate Run ID and add Test cases flagged yes\n\t\tflaggedTestCases();\n\t\t//System.out.println(\"Suite Name \"+Constants.SelectedSuite);\n\t\t\n\t\t//get the value for IE browser\n\t\tConstants.IE = excel.getCellData(Constants.TestSuiteSheetname, 1, 2);\n\t\t//get the value for Chrome browser\n\t\tConstants.Chrome =excel.getCellData(Constants.TestSuiteSheetname, 2, 2);\n\t\t//get the value for Firefox browser\n\t\tConstants.Firefox =excel.getCellData(Constants.TestSuiteSheetname, 3, 2);\t\t\n\t\t//Safari browser\n\t\tConstants.Safari =excel.getCellData(Constants.TestSuiteSheetname, 5, 2);\t\t\n\t\t//get the value for Firefox browser\n\t\tConstants.Mobile =excel.getCellData(Constants.TestSuiteSheetname, 4, 2);\n\t\t//get the type of framework selected\n\t\tConstants.SelectedFramework =excel.getCellData(Constants.TestSuiteSheetname, 2, 3);\n\t\t\n\t\t//Get all the objects from Excel and store it an array\n\t\tOR.storeObjects();\n\t\t\n\t\t//Start the browser instance based on selected options.\n\t\texecute(Constants.IE,Constants.Chrome,Constants.Firefox, Constants.Safari, Constants.Mobile);\n\t\t\n\t}",
"public static void main(String[] args) throws InterruptedException, ExecutionException {\t\r\n\t\tScanner reader = new Scanner(System.in);\r\n\t\t/*\r\n\t\t * Limite maximo de números. \r\n\t\t */\t\r\n\t\tList<Future<Long>> list = new ArrayList<Future<Long>>();\r\n\t\t/*\r\n\t\t * Lista que guarda los tiempos de ejecución de cada hilo. \r\n\t\t */\t\r\n\t\tArrayList<Long> ListaTiempo = new ArrayList<Long>();\r\n\t\tSystem.out.print(\"ingrese numeros limite de numeros para analizar:\");\r\n\t\t/*\r\n\t\t * Variable que guarda el numero captado por consola. \r\n\t\t */\t\r\n\t\tint numeros = reader.nextInt();\r\n\t\t/*\r\n\t\t * Variable que incrementa para generar los hilos. \r\n\t\t */\t\r\n\t\tint hilos = 1;\r\n\t\t/*\r\n\t\t * Variable que guarda el tiempo de ejecucion del hilo uno. \r\n\t\t */\t\r\n\t\tlong tiempoHiloUno = 0;\r\n\t\t\r\n\t\t//while que itera hasta 16 hilos.\r\n\t\twhile (hilos <= 16) {\r\n\t\t\t//Calculo del límite.\r\n\t\t\tint limite = numeros / hilos;\r\n\t\t\t/*\r\n\t\t\t * Se crea el pool de hilos. \r\n\t\t\t */\t\r\n\t\t\tExecutorService servicio = Executors.newFixedThreadPool(hilos);\r\n\t\t\tint inferior = 1;\r\n\t\t\tint superior = limite;\r\n\t\t\tlong initialTime = System.currentTimeMillis();\r\n\t\t\t//Itera segun el numero de hilos.\r\n\t\t\tfor (int i = 1; i <= hilos; i++) {\r\n\t\t\t\tFuture<Long> resultado = servicio.submit(new Nprimos(superior, inferior));\r\n\t\t\t\tlist.add(resultado);\r\n\t\t\t\tinferior = superior + 1;\r\n\t\t\t\tsuperior += limite;\r\n\t\t\t\t//Si supera el límite rompe el ciclo.\r\n\t\t\t\tif (superior > limite * hilos) {\r\n\t\t\t\t\tbreak;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\r\n\t\t\t// se termina de ejecutar cuando todos los hilos terminan de trabajar.\r\n\t\t\tfor (Future<Long> resultado : list) {\r\n\t\t\t\ttry {\r\n\t\t\t\t\tListaTiempo.add(resultado.get());\r\n\t\t\t\t} catch (InterruptedException | ExecutionException e) {\r\n\t\t\t\t\te.printStackTrace();\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\tif(hilos==1) {\r\n\t\t\t\ttiempoHiloUno = System.currentTimeMillis() - initialTime; \r\n\t\t\t}\r\n\t\t\tSystem.out.print(\" \\n \" + \"(\" + hilos + \")\" + \"tiempo de ejecución: \"+ (System.currentTimeMillis() - initialTime) + \" ms\\n\");\r\n\t\t\tSystem.out.print(\" speed up = \" + (double)(tiempoHiloUno /(System.currentTimeMillis() - initialTime)) + \" \\n\");\r\n\t\t\tservicio.shutdown();\r\n\t\t\t//Se incrementa variable hilos.\r\n\t\t\thilos++;\r\n\t\t}\r\n\r\n\t}",
"public static void main(String [] args) {\n\t\tExecutorService executor= Executors.newFixedThreadPool(2);\n\t\t\n\t\t//add the tasks that the threadpook executor should run\n\t\tfor(int i=0;i<5;i++) {\n\t\t\texecutor.submit(new Processor(i));\n\t\t}\n\t\t\n\t\t//shutdown after all have started\n\t\texecutor.shutdown();\n\t\t\n\t\tSystem.out.println(\"all submitted\");\n\t\t\n\t\t//wait 1 day till al the threads are finished \n\t\ttry {\n\t\t\texecutor.awaitTermination(1, TimeUnit.DAYS);\n\t\t} catch (InterruptedException e) {\n\t\t\t\te.printStackTrace();\n\t\t}\n\t\t\n\t\tSystem.out.println(\"all completed\");\n\t\t\n\t}",
"public void testForNThreads();",
"@Test\n @Issue(\"JENKINS-41685\")\n public void testParallelsWithDuplicateEvents() throws Exception {\n //https://gist.github.com/vivek/ccf3a4ef25fbff267c76c962d265041d\n WorkflowJob job = r.jenkins.createProject(WorkflowJob.class, \"ParallelInsanity\");\n job.setDefinition(new CpsFlowDefinition(\"\" +\n \"echo 'first stage'\\n\" +\n \"parallel left : {\\n\" +\n \" echo 'run a bit'\\n\" +\n \" echo 'run a bit more'\\n\" +\n \" semaphore 'wait1'\\n\" +\n \"}, right : {\\n\" +\n \" echo 'wozzle'\\n\" +\n \" semaphore 'wait2'\\n\" +\n \"}\\n\" +\n \"echo 'last stage'\\n\" +\n \"echo \\\"last done\\\"\\n\",\n true));\n ForkScanner scan = new ForkScanner();\n ChunkFinder labelFinder = new NoOpChunkFinder();\n WorkflowRun run = job.scheduleBuild2(0).getStartCondition().get();\n SemaphoreStep.waitForStart(\"wait1/1\", run);\n SemaphoreStep.waitForStart(\"wait2/1\", run);\n\n TestVisitor test = new TestVisitor();\n List<FlowNode> heads = run.getExecution().getCurrentHeads();\n scan.setup(heads);\n scan.visitSimpleChunks(test, labelFinder);\n\n SemaphoreStep.success(\"wait1\"+\"/1\", null);\n SemaphoreStep.success(\"wait2\"+\"/1\", null);\n r.waitForCompletion(run);\n\n int atomEventCount = 0;\n int parallelBranchEndCount = 0;\n int parallelStartCount = 0;\n for (TestVisitor.CallEntry ce : test.calls) {\n switch (ce.type) {\n case ATOM_NODE:\n atomEventCount++;\n break;\n case PARALLEL_BRANCH_END:\n parallelBranchEndCount++;\n break;\n case PARALLEL_START:\n parallelStartCount++;\n break;\n default:\n break;\n }\n }\n\n sanityTestIterationAndVisiter(heads);\n Assert.assertEquals(10, atomEventCount);\n Assert.assertEquals(1, parallelStartCount);\n Assert.assertEquals(2, parallelBranchEndCount);\n }",
"public static void main(String[] args) throws MalformedURLException, InterruptedException\n\t{\n\n\t\tint meterNum = 10;\n//\t\tif(Integer.parseInt(args[1]) > 0) {\n//\t\t\tmeterNum = Integer.parseInt(args[1]);\n//\t\t}\n\t\t\n\t\tint threadNum = 5;\n\t\tint totalDocNum = 10;\n\t\t\n\t\tSystem.gc();\n\t\t\n\t\tmeterStream[] ms = new meterStream[meterNum]; \t\t\t\n\t\t\n\t\tfor(int i = 0 ; i < meterNum ; i++)\n\t\t{\n\t\t\tms[i] = new meterStream();\n\t\t\t//ms[i].setUrl(\"http://service2.allenworkspace.net/xml/xmldata/testxml\"+(i+1)+\".xml\");\n\t\t\tms[i].setUrl(\"http://program.allenworkspace.net/xml/xmldata/testxml\"+(i+1)+\".xml\");\t\t\t\t\t\t\t\t\t\n\t\t\t\n\t\t}\n\t\t\n\t\t/*\n\t\tString[] xpathArray = new String[] {\"/a0CC175B9C0F1B6A831C399E269772661/a92EB5FFEE6AE2FEC3AD71C777531578F/@aB80BB7740288FDA1F201890375A60C8F\",\n\t\t\t\t\"/a0CC175B9C0F1B6A831C399E269772661/a4A8A08F09D37B73795649038408B5F33/@a2063C1608D6E0BAF80249C42E2BE5804\"};\n\t\t*/\n\t\t\n\t\tString[] xpathArray = new String[] {\"/a0CC175B9C0F1B6A831C399E269772661/a92EB5FFEE6AE2FEC3AD71C777531578F/\",\n\t\t\t\t\"/a0CC175B9C0F1B6A831C399E269772661/a4A8A08F09D37B73795649038408B5F33/\"};//YFilter專用\n\t\t\n\t\tList<String> xpathList = new ArrayList<String>();\n\t\tCollections.addAll(xpathList, xpathArray);\n\t\t\n\t\t//List<XMLDogTask> taskPool = null;\n\t\t//List<SaxonTask> taskPool = null;\n\t\tList<YFilterTask> taskPool = null;\n\t\t\n\t\tif(threadNum > 0) {\n\t\t\t//taskPool = TaskPool.CreateXMLDogTasks(threadNum, xpathList);\n\t\t\t//taskPool = TaskPool.CreateSaxonTasks(threadNum, xpathList);\n\t\t\ttaskPool = TaskPool.CreateYFilterTasks(threadNum, xpathList);\n\t\t\t\n\t\t\t/*\n\t\t\tfor(int i = 0; i < threadNum; ++i) {\n\t\t\t\tDefaultNamespaceContext nsContext = new DefaultNamespaceContext(); // an implementation of javax.xml.namespace.NamespaceContext\n\t\t\t\tnsContext.declarePrefix(\"xsd\", Namespaces.URI_XSD);\n\t\t\t\tdog = new XMLDog(nsContext);\n\t\t\t\ttry \n\t\t\t\t{\n\t\t\t\t\tExpression xpath1 = dog.addXPath(\"/a0CC175B9C0F1B6A831C399E269772661/a92EB5FFEE6AE2FEC3AD71C777531578F/@aB80BB7740288FDA1F201890375A60C8F\");\n\t\t\t\t\tExpression xpath2 = dog.addXPath(\"/a0CC175B9C0F1B6A831C399E269772661/a4A8A08F09D37B73795649038408B5F33/@a2063C1608D6E0BAF80249C42E2BE5804\");\t\n\t\t\t\t} \n\t\t\t\tcatch (SAXPathException e) \n\t\t\t\t{\n\t\t\t\t\t// TODO Auto-generated catch block\n\t\t\t\t\te.printStackTrace();\n\t\t\t\t} \n\t\t\t} */\n\t\t}\n\t\t\n\t\tExecutorService executorService = Executors.newFixedThreadPool(threadNum);\n\t\tExecutorService reducerService = Executors.newCachedThreadPool(); \n\t\tList<Future<List<String>>> resultList = null;\n\t\t\n\t\tlong starttime = System.currentTimeMillis();\n\t\t\n\t\tfor(int i = 0 ; i < totalDocNum ; i++ )\n\t\t{\n\t\t\t//callXMLDogFilter myFilter = new callXMLDogFilter(ms[i%meterNum].strURI);\n\t\t\t//callSaxonFilter myFilter = new callSaxonFilter(ms[i%meterNum].strURI);\n\t\t\tcallYFilter myFilter = new callYFilter(ms[i%meterNum].strURI);\n\t\t\t\n\t\t\tmyFilter.SetTaskList(taskPool);\n\t\t\t// myFilter.setStream(ms[i%meterNum].getStream());\n\t\t\t/* myThreads[t] = new Thread(testFilter[t]);\n\t\t\tmyThreads[t].start(); */\n\t\t\tFuture<List<String>> result = executorService.submit(myFilter);\n\t\t\tif(i % meterNum == 0) {\n\t\t\t\tresultList = new ArrayList<Future<List<String>>>();\n\t\t\t} \n\t\t\tresultList.add(result);\n\t\t\tif(resultList.size() == meterNum) {\n\t\t\t\t//ExecuteService myReducer = Executors.newFixedThreadPool(threadNum)\n\t\t\t\tString taskID = (i/meterNum)+\"\";\n\t\t\t\t\n\t\t\t\t//XMLDogTaskReducer reducer = (XMLDogTaskReducer) TaskReducerFactory.Create(\"XMLDogTaskReducer\");\n\t\t\t\t//SaxonTaskReducer reducer = (SaxonTaskReducer) TaskReducerFactory.Create(\"SaxonTaskReducer\");\n\t\t\t\tYFilterTaskReducer reducer = (YFilterTaskReducer) TaskReducerFactory.Create(\"YFilterTaskReducer\");\n\t\t\t\t\n\t\t\t\treducer.SetID(taskID);\n\t\t\t\treducer.resultList = resultList;\t\t\t\t\t\n\t\t\t\treducerService.execute(reducer);\n\t\t\t}\n\t\t\t// resultList.add(result);\n\t\t}\n\t\texecutorService.shutdown(); \n\t\texecutorService.awaitTermination(30, TimeUnit.MINUTES);\n\t\treducerService.shutdown();\n\t\treducerService.awaitTermination(30, TimeUnit.MINUTES);\n\t\t\t\t\n\t\tlong endTime = System.currentTimeMillis();\n\t\tSystem.out.println((\"duration:\" + (endTime - starttime)));\n\t}",
"private static void automate() {\n \tLOG.info(\"Begin automation task.\");\n \t\n \tcurrentOpticsXi = clArgs.clusteringOpticsXi;\n \tdouble opticsXiMax = (clArgs.clusteringOpticsXiMaxValue > ELKIClusterer.MAX_OPTICS_XI ? ELKIClusterer.MAX_OPTICS_XI : clArgs.clusteringOpticsXiMaxValue);\n \tcurrentOpticsMinPoints = clArgs.clusteringOpticsMinPts;\n \tint opticsMinPointsMax = clArgs.clusteringOpticsMinPtsMaxValue;\n \t\n \tLOG.info(\"optics-xi-start: {}, optics-xi-min-points-start: {}, optics-xi-step-size: {}, optics-min-points-step-size: {}\",\n \t\t\tnew Object[] { \n \t\t\t\tdf.format(currentOpticsXi), df.format(currentOpticsMinPoints), \n \t\t\t\tdf.format(clArgs.clusteringOpticsXiStepSize), df.format(clArgs.clusteringOpticsMinPtsStepSize)\n \t\t\t});\n \t\n \twhile (currentOpticsXi <= opticsXiMax) {\n \t\twhile (currentOpticsMinPoints <= opticsMinPointsMax) {\n \t\t\t// Run automation for each combination of opticsXi and opticsMinPoints\n \t\t\tLOG.info(\"Run automation with optics-xi: {}, optics-xi-min-points: {}\", \n \t\t\t\t\tdf.format(currentOpticsXi), df.format(currentOpticsMinPoints));\n \t\t\t\n \t\t\ttry {\n\t \t\t\t// Step 1: Clustering\n\t \t\t\tclustering(clArgs.clusteringInFile, clArgs.clusteringOutDir, currentOpticsXi, currentOpticsMinPoints);\n\t \t\t\t\n\t \t\t\t// Step 2: Build shared framework\n\t \t\t\tbuildFramework();\n\t \t\t\t\n\t \t\t\t// Step 3: Build user hierarchical graphs\n\t \t\t\tbuildHierarchicalGraphs();\n\t \t\t\t\n\t \t\t\t// Step 4: Calculate similarity between all users and create evaluation results afterwards\n\t \t\t\tcalculateSimilarity();\n \t\t\t} catch (Exception e) {\n\t\t\t\t\tLOG.error(\"An error occurred during the automation task. Jumping to the next pass.\", e);\n\t\t\t\t} finally {\n\t \t\t\t// Step 5: Clean up for the next run\n\t \t\t\tcleanAutomationResults();\n\t \t\t\t\n\t \t\t\t// Increase the currentOpticsMinPoints for the next run if desired\n\t \t\t\tif (clArgs.clusteringOpticsMinPtsStepSize > 0)\n\t \t\t\t\tcurrentOpticsMinPoints += clArgs.clusteringOpticsMinPtsStepSize;\n\t \t\t\telse\n\t \t\t\t\tbreak;\n\t\t\t\t}\n \t\t}\n \t\t// Reset current values\n \t\tcurrentOpticsMinPoints = clArgs.clusteringOpticsMinPts;\n \t\t\n \t\t// Increase currentOpticsXi for the next run if desired\n \t\tif (clArgs.clusteringOpticsXiStepSize > 0)\n\t\t\t\tcurrentOpticsXi += clArgs.clusteringOpticsXiStepSize;\n\t\t\telse\n\t\t\t\tbreak;\n \t}\n \t\n \tLOG.info(\"End automation task.\");\n }",
"@Override\r\n public void generateTasks() {\r\n int tasks = Integer.parseInt(this.getProperty(\"numTask\", \"1000\"));\r\n setNumOfTasks(tasks);\r\n //TODO:fixed port here !!!! need to change!!!\r\n serverPort = Integer.parseInt(this.getProperty(\"reqServerPort\", \"5560\")); \r\n PROC_MAX = Integer.parseInt(this.getProperty(\"reqServerMaxConcurrentClients\",\"10\"));\r\n location = this.getProperty(\"location\", \"rutgers\");\r\n energyplusPropertyFile = this.getProperty(\"energyplusTemplate\", \"energyplus.property\");\r\n \r\n winnerTakeAll = Boolean.parseBoolean(this.getProperty(\"winnerTakeAll\",\"true\"));\r\n jobDistributionMap = new HashMap<Integer,Integer>();\r\n copyJobDistributionMap = new HashMap<Integer,Integer>();\r\n //System.out.println(\"energyplusPropertyFile:\"+energyplusPropertyFile);\r\n \r\n initInfoSystem();\r\n initDistributionSystem();\r\n startFedServer();\r\n }",
"public static void main(String[] args) {\n\t\tString[]array=new String[2];\n\t\tfor (int i = 0; i < Runtime.getRuntime().availableProcessors(); i++) {\n\t\t\tHiloHijo h=new HiloHijo(i,array);\n\t\t\tThread t=new Thread(h);\n\t\t\t//t.run(); si lo hacemos asi se hace secuencial 01,2,3\n\t\t\t//en paralelo\n\t\t\tt.start();//para empezar el hilo el so se encarga de saber como empezarlo\n\t\t\t\n\t\t\tSystem.out.println(\"Hilos vivos (aprox) :\"+Thread.activeCount());\n\t\t\tSystem.out.println(\"hilo \"+i+\" vivo? \"+t.isAlive()+\" estado: \"+t.getState());\n\t\t\t//Inicializamos otro hilo\n\t\t\tHijoTipo2 h2=new HijoTipo2(i);\n\t\t\th2.start();\n\t\t\t\n\t\t\t/*\n\t\t\t * String[]arr=new String[3];\n\t\t\n\t\tHiloHijo h=new HiloHijo(1,arr);\n\t\tfor (int i = 0; i < Runtime.getRuntime().availableProcessors(); i++) {\n\t\t\tnew Thread(h).start();\n\t\t\t\n\t\t\t */\n\t\t\t\n\t\t}\n\t\t\n\t\ttry {\n\t\t\tThread.sleep(1000);\n\t\t\tSystem.out.println(\"Hilos vivos al final (aprox) :\"+Thread.activeCount());\n\t\t\t\n\t\t} catch (InterruptedException e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t};\n\t}",
"@Test\n public void testTripleParallel() throws Exception {\n WorkflowJob job = r.jenkins.createProject(WorkflowJob.class, \"TripleParallel\");\n job.setDefinition(new CpsFlowDefinition(\n \"echo 'test stage'\\n\"+ // Id 3, Id 2 before that has the FlowStartNode\n \"parallel 'unit':{\\n\" + // Id 4 starts parallel, Id 7 is the block start for the unit branch\n \" echo \\\"Unit testing...\\\"\\n\" + // Id 10\n \"},'integration':{\\n\" + // Id 11 is unit branch end, Id 8 is the branch start for integration branch\n \" echo \\\"Integration testing...\\\"\\n\" + // Id 12\n \"}, 'ui':{\\n\" + // Id 13 in integration branch end, Id 9 is branch start for UI branch\n \" echo \\\"UI testing...\\\"\\n\" + // Id 14\n \"}\", // Node 15 is UI branch end node, Node 16 is Parallel End node, Node 17 is FlowEndNode\n true));\n WorkflowRun b = r.assertBuildStatusSuccess(job.scheduleBuild2(0));\n FlowExecution exec = b.getExecution();\n ForkScanner f = new ForkScanner();\n List<FlowNode> heads = exec.getCurrentHeads();\n f.setup(heads);\n TestVisitor visitor = new TestVisitor();\n f.visitSimpleChunks(visitor, new BlockChunkFinder());\n sanityTestIterationAndVisiter(heads);\n\n List<TestVisitor.CallEntry> parallels = visitor.calls.stream()\n .filter(\n predicateForCallEntryType(TestVisitor.CallType.PARALLEL_BRANCH_START)\n .or(\n predicateForCallEntryType(TestVisitor.CallType.PARALLEL_BRANCH_END)))\n .collect(Collectors.toList());\n Assert.assertEquals(6, parallels.size());\n\n // Visiting from partially completed branches\n // Verify we still get appropriate parallels callbacks for a branch end\n // even if in-progress and no explicit end node\n ArrayList<FlowNode> ends = new ArrayList<>();\n ends.add(exec.getNode(\"11\"));\n ends.add(exec.getNode(\"12\"));\n ends.add(exec.getNode(\"14\"));\n Assert.assertEquals(new DepthFirstScanner().allNodes(ends).size(),\n new ForkScanner().allNodes(ends).size());\n visitor = new TestVisitor();\n f.setup(ends);\n f.visitSimpleChunks(visitor, new BlockChunkFinder());\n sanityTestIterationAndVisiter(ends);\n\n // Specifically test parallel structures\n parallels = visitor.calls.stream()\n .filter(\n predicateForCallEntryType(TestVisitor.CallType.PARALLEL_BRANCH_START)\n .or(\n predicateForCallEntryType(TestVisitor.CallType.PARALLEL_BRANCH_END)))\n .collect(Collectors.toList());\n Assert.assertEquals(6, parallels.size());\n Assert.assertEquals(18, visitor.calls.size());\n\n // Test the least common ancestor implementation with triplicate\n FlowNode[] branchHeads = {exec.getNode(\"7\"), exec.getNode(\"8\"), exec.getNode(\"9\")};\n ArrayDeque<ForkScanner.ParallelBlockStart> starts = f.leastCommonAncestor(new HashSet<>(Arrays.asList(branchHeads)));\n Assert.assertEquals(1, starts.size());\n ForkScanner.ParallelBlockStart pbs = starts.pop();\n Assert.assertEquals(exec.getNode(\"4\"), pbs.forkStart);\n Assert.assertEquals(3, pbs.unvisited.size());\n Assert.assertTrue(pbs.unvisited.contains(exec.getNode(\"7\")));\n Assert.assertTrue(pbs.unvisited.contains(exec.getNode(\"8\")));\n Assert.assertTrue(pbs.unvisited.contains(exec.getNode(\"9\")));\n }",
"public static int availableProcessors() {\n/* 98 */ return holder.availableProcessors();\n/* */ }",
"public static void main(String[] args) {\n\n System.out.println(Runtime.getRuntime().availableProcessors());\n }",
"public Integer call() throws IOException {\n \t\t\tint ret=90;\n \t\t\ttestCases = new ArrayList<String>();\n \t\t\trealIds = new ArrayList<String>();\n \t \tString path = \"./workspace/\"+jobname;\n\t\t\t\tlistener.getLogger().println(\"IL PATH DEL TESTRUN E' \"+path);\n \t\t\t/* folders = listFilesForFolder(new File(path),listener);\n \t\t\t// cerco il TestRun nell'svn di Polarion\n \tcheck:\tfor(String folder : folders){\n \t \tlistener.getLogger().println(\"confronto: \"+testrunid+\" - \"+folder);\n \t\t\t\tif(testrunid.equals(folder)){ \t\t\t\t\t\n \t\t\t\t\t// prelevo i TestCase relativi al TestRun\n \t\t\t\t\t */\n \t\t\t\t\ttestCases = getTestCases(path,listener);\n \t\t\t\t\tString nometestrun = \"Executed - \"+testrunid+\".xml\";\n \t\t\t\t\tif(!testCases.isEmpty()){\n \t\t\t\t\t\t// prelevo l'ID vero dei Test Case\n\t\t\t\t\t\t\trealIds = getRealTestCaseIdFromPolarion(listener,testCases);\n\t\t\t\t\t\t\tif(type.equals(\"TestMTP\")){ // ESECUZIONE SU MTP\n\t\t\t\t\t\t\t\tlistener.getLogger().println(\"eseguo MTP\");\n\t\t\t\t\t\t\t\tfor(String realId : realIds){\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t/* Per l'esecuzione con lo stub (va messa fuori il for per funzionare)\n\t\t \t\t\t\t\tCreaXMLStub stub = new CreaXMLStub(testCases);\n\t\t\t\t\t\t\t\tstub.doTest(\"C:/JenkinsSlave/workspace/\"+jobname+\"/Temp/\"+nometestrun,listener);*/\n\t\t\t\t\t\t\t}else if(type.equals(\"TestMX\")){ // ESECUZIONE SU MICROMAX\n\t\t\t\t\t\t\t\tif(!scenario){\n\t\t\t\t\t\t\t\t\tArrayList<Integer> returnCodes = new ArrayList<Integer>();\n\t\t\t\t\t\t\t\t\tfor(String realId : realIds){\n\t\t\t\t\t\t\t\t\t\t// stampo il realId del test case\n\t\t\t\t\t\t\t \tlistener.getLogger().println(\"TC: \"+realId);\n\t\t\t\t\t\t\t\t\t\tlistener.getLogger().println(\"eseguo MX\");\n\t\t\t\t\t\t\t\t\t\tString[] parameters = realId.split(\",\");\n\t\t\t\t\t\t\t\t\t\ttry {\n\t\t\t\t\t\t\t\t\t\t\tProcessBuilder builder = new ProcessBuilder(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\"MxVGUI\", \"/n\", \"/r\", mxpath+File.separator+parameters[0]+File.separator+parameters[1]+\".mxp\", mxpath+File.separator+parameters[0]+\"/ScenariosAndTestCases/\"+parameters[2]); \n\t\t\t\t\t\t\t\t\t\t\tbuilder.redirectErrorStream(true); \n\t\t\t\t\t\t\t\t\t\t\tProcess p = builder.start();\n\t\t\t\t\t\t\t\t\t\t\tBufferedReader reader = new BufferedReader(new InputStreamReader(p.getInputStream()));\n\t\t\t\t\t\t\t\t\t\t\tString line;\n\t\t\t\t\t\t\t\t\t\t\twhile ((line = reader.readLine()) != null)\n\t\t\t\t\t\t\t\t\t\t\t\tlistener.getLogger().println(\"tasklist: \" + line);\n\t\t\t\t\t\t\t\t\t\t\tret=p.waitFor();\n\t\t\t\t\t\t\t\t\t\t\treturnCodes.add(ret);\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\tlistener.getLogger().println(\"eseguito MX \"+ret);\n\t\t\t\t\t\t\t\t\t\t} catch (Exception e) {\n\t\t\t\t\t\t\t\t\t\t\t// TODO Auto-generated catch block\n\t\t\t\t\t\t\t\t\t\t\tContactPolarion(listener);\n\t\t\t\t\t\t\t\t\t\t\tlistener.getLogger().println(e.getMessage());\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t//Scrive i risultati in base al valore di ritorno di MxVDEV\n\t\t\t\t\t\t\t\t\twriteTestResults(\"C:/JenkinsSlave/Results/\"+nometestrun, testCases, returnCodes);\t\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t//Converto tutti i risultati nel formato desiderato leggendo i log\n\t\t\t\t\t\t\t\t//convertTestCaseResults(realIds, \"C:/JenkinsSlave/workspace/\"+jobname+\"/Temp/\"+nometestrun, testCases);\n\t\t\t\t\t\t\t\telse{\n\t\t\t\t\t\t\t\t\t//convertScenarioResults(testCases, new ArrayList<String>(), mxpath+File.separator+parameters[0]+\"/ScenariosAndTestCases/\"+testrunid ,testrunid);\n\t\t\t\t\t\t\t\t\tString[] parameters = realIds.get(0).split(\",\");\n\t\t\t\t\t\t\t\t\tScenario scenario = new Scenario(testrunid,realIds,mxpath+File.separator+parameters[0]+\"/ScenariosAndTestCases/\");\n\t\t\t\t\t\t\t\t\tif(scenario.createScenario()){\n\t\t\t\t\t\t\t\t\t\tlistener.getLogger().println(\"Scenario creato\");\n\t\t\t\t\t\t\t\t\t\ttry {\n\t\t\t\t\t\t\t\t\t\t\tProcessBuilder builder = new ProcessBuilder(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\"MxVGUI\", \"/n\", \"/r\", mxpath+File.separator+parameters[0]+File.separator+parameters[1]+\".mxp\", mxpath+File.separator+parameters[0]+\"/ScenariosAndTestCases/\"+testrunid+\".mxs\"); \n\t\t\t\t\t\t\t\t\t\t\tbuilder.redirectErrorStream(true); \n\t\t\t\t\t\t\t\t\t\t\tProcess p = builder.start();\n\t\t\t\t\t\t\t\t\t\t\tBufferedReader reader = new BufferedReader(new InputStreamReader(p.getInputStream()));\n\t\t\t\t\t\t\t\t\t\t\tString line;\n\t\t\t\t\t\t\t\t\t\t\twhile ((line = reader.readLine()) != null)\n\t\t\t\t\t\t\t\t\t\t\t\tlistener.getLogger().println(\"tasklist: \" + line);\n\t\t\t\t\t\t\t\t\t\t\tret=p.waitFor();\n\t\t\t\t\t\t\t\t\t\t\tlistener.getLogger().println(\"eseguito MX \"+ret);\n\t\t\t\t\t\t\t\t\t\t\tconvertScenarioResults(testCases, new ArrayList<String>(), mxpath+File.separator+parameters[0]+\"/ScenariosAndTestCases/\"+testrunid ,testrunid);\n\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t} catch (Exception e) {\n\t\t\t\t\t\t\t\t\t\t\tContactPolarion(listener);\n\t\t\t\t\t\t\t\t\t\t\tlistener.getLogger().println(e.getMessage());\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t}else{\n\t\t\t\t\t\t\t\t\t\tlistener.getLogger().println(\"creazione dello scenario non riuscita\");\n\t\t\t\t\t\t\t\t\t}\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}else{ // CONDIZIONE EVENTUALI ERRORI\n\t\t\t\t\t\t\t\tContactPolarion(listener);\n\t\t\t\t\t\t\t\tlistener.getLogger().println(\"condizione inaspettata\");\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\tpublishTest(\"C:/JenkinsSlave/Results/\",sharedpasswd,shareduser,nometestrun, listener, projectname);\n\t\t\t\t\t \t}else{\n\t\t\t\t\t \t\tContactPolarion(listener);\n\t\t\t\t\t \t\tlistener.getLogger().println(\"Nessun tc impostato. Setto tr a open\");\n\t\t\t\t\t \t//}\n\t\t\t\t\t \t//break check;\n \t\t\t\t//}\n \t\t\t}\n \t\t\treturn ret; \t\n \t\t}",
"public void run() {\n \n if (Parameter != null && Parameter instanceof ConvertTextUnitsParameter) {\n CastParameter = (ConvertTextUnitsParameter)Parameter;\n }\n else {\n CastParameter = null;\n }\n\n String shortErrorMessage = \"Error: Text Units Cannot be Converted!\";\n this.acceptTask(TaskProgress.INDETERMINATE, \"Initial Preparations\");\n this.validateParameter(Parameter, shortErrorMessage);\n this.openDiasdemCollection(CastParameter.getCollectionFileName());\n this.checkPrerequisitesAndSetDefaultTextUnitsLayer(shortErrorMessage);\n \n if (CastParameter.getConversionType() == ConvertTextUnitsParameter\n .APPLY_REGULAR_EXPRESSION_TO_TEXT_UNITS) {\n RegexPattern = Pattern.compile(CastParameter.getRegularExpression());\n }\n \n if (CastParameter.getConversionType() == ConvertTextUnitsParameter\n .IDENTIFY_SPECIFIED_MULTI_TOKEN_TERMS) {\n // read multi token word: each line contains one multi token word;\n // comment lines start with '#'\n TextFile multiTokenFile = new TextFile(\n new File(CastParameter.getMultiTokenFileName()));\n multiTokenFile.open();\n String line = multiTokenFile.getFirstLineButIgnoreCommentsAndEmptyLines();\n ArrayList list = new ArrayList();\n while (line != null) {\n list.add(line.trim());\n line = multiTokenFile.getNextLineButIgnoreCommentsAndEmptyLines();\n }\n // sort multi token terms by decreasing length\n Collections.sort(list, new SortStringsByDecreasingLength());\n // for (int i = 0; i < list.size(); i++) {\n // System.out.println((String)list.get(i));\n // }\n // System.out.println(list.size());\n String[] multiToken = new String[list.size()];\n for (int i = 0; i < list.size(); i++)\n multiToken[i] = (String)list.get(i);\n multiTokenFile.close();\n MyMultiTokenWordIdentifier = new HeuristicMultiTokenWordIdentifier(\n multiToken);\n }\n else {\n MyMultiTokenWordIdentifier = null;\n }\n \n if (CastParameter.getConversionType() == ConvertTextUnitsParameter\n .FIND_AND_REPLACE_SPECIFIED_TOKENS) {\n // read token replacement file: each line contains the tokens to search \n // for and the replacement tokens separated by a tab stop;\n // comment lines start with '#'\n TextFile tokenReplacementFile = new TextFile(\n new File(CastParameter.getTokenReplacementFileName()));\n tokenReplacementFile.open();\n String line = tokenReplacementFile.getFirstLineButIgnoreCommentsAndEmptyLines();\n HashMap tokensSearchList = new HashMap();\n String[] tokensContents = null;\n while (line != null) {\n tokensContents = line.split(\"\\t\");\n if (tokensContents.length == 2\n && tokensContents[1].trim().length() > 0) {\n try {\n tokensSearchList.put(tokensContents[0].trim(), \n tokensContents[1].trim());\n }\n catch (PatternSyntaxException e) {\n System.out.println(\"[TokenizeTextUnitsTask] Regex syntax error in \"\n + \" file \" + CastParameter.getTokenReplacementFileName() + \": \"\n + \" Line \\\"\" + line + \"\\\"; error message: \" + e.getMessage());\n }\n }\n else {\n System.out.println(\"[TokenizeTextUnitsTask] Error in file \"\n + CastParameter.getTokenReplacementFileName() + \": Line \\\"\"\n + line + \"\\\" does not conform to syntax!\");\n }\n line = tokenReplacementFile.getNextLineButIgnoreCommentsAndEmptyLines();\n }\n // sort multi token terms by decreasing length\n ArrayList list = new ArrayList(tokensSearchList.keySet());\n Collections.sort(list, new SortStringsByDecreasingLength());\n // create arrays for token replacement \n String[] tokensSearch = new String[list.size()];\n String[] tokensReplace = new String[list.size()];\n Iterator iterator = list.iterator();\n int i = 0;\n while (iterator.hasNext()) {\n TmpString = (String)iterator.next();\n tokensSearch[i] = TmpString;\n tokensReplace[i++] = (String)tokensSearchList.get(TmpString);\n }\n tokenReplacementFile.close();\n MyTokenReplacer = new HeuristicTokenReplacer(tokensSearch, tokensReplace);\n }\n else {\n MyTokenReplacer = null;\n }\n \n int counterProgress = 0;\n long maxProgress = DiasdemCollection.getNumberOfDocuments();\n \n DiasdemDocument = DiasdemCollection.getFirstDocument(); \n while (DiasdemDocument != null) {\n \n if (counterProgress == 1 || (counterProgress % 50) == 0) {\n Progress.update( (int)(counterProgress * 100 / maxProgress),\n \"Processing Document \" + counterProgress);\n DiasdemServer.setTaskProgress(Progress, TaskThread);\n }\n\n DiasdemDocument.setActiveTextUnitsLayer(DiasdemProject\n .getActiveTextUnitsLayerIndex());\n DiasdemDocument.backupProcessedTextUnits(DiasdemProject\n .getProcessedTextUnitsRollbackOption());\n \n for (int i = 0; i < DiasdemDocument.getNumberOfProcessedTextUnits(); \n i++) {\n DiasdemTextUnit = DiasdemDocument.getProcessedTextUnit(i);\n switch (CastParameter.getConversionType()) {\n case ConvertTextUnitsParameter.CONVERT_TEXT_UNITS_TO_LOWER_CASE: {\n TextUnitContentsAsString = DiasdemTextUnit.getContentsAsString()\n .toLowerCase();\n break;\n }\n case ConvertTextUnitsParameter.CONVERT_TEXT_UNITS_TO_UPPER_CASE: {\n TextUnitContentsAsString = DiasdemTextUnit.getContentsAsString()\n .toUpperCase();\n break;\n } \n case ConvertTextUnitsParameter.APPLY_REGULAR_EXPRESSION_TO_TEXT_UNITS: {\n RegexMatcher = RegexPattern.matcher(DiasdemTextUnit\n .getContentsAsString());\n TmpStringBuffer = new StringBuffer(DiasdemTextUnit\n .getContentsAsString().length() + 10000);\n while (RegexMatcher.find()) {\n RegexMatcher.appendReplacement(TmpStringBuffer,\n CastParameter.getReplacementString());\n }\n TextUnitContentsAsString = RegexMatcher.appendTail(TmpStringBuffer)\n .toString();\n break;\n }\n case ConvertTextUnitsParameter.IDENTIFY_SPECIFIED_MULTI_TOKEN_TERMS: {\n TextUnitContentsAsString = MyMultiTokenWordIdentifier\n .identifyMultiTokenWords(DiasdemTextUnit.getContentsAsString());\n break;\n } \n case ConvertTextUnitsParameter.FIND_AND_REPLACE_SPECIFIED_TOKENS: {\n TextUnitContentsAsString = MyTokenReplacer\n .replaceTokens(DiasdemTextUnit.getContentsAsString());\n break;\n } \n case ConvertTextUnitsParameter.REMOVE_PART_OF_SPEECH_TAGS_FROM_TOKENS: {\n TextUnitContentsAsString = this.removeTagsFromTokens(\n DiasdemTextUnit.getContentsAsString(), \"/p:\");\n break;\n } \n case ConvertTextUnitsParameter.REMOVE_WORD_SENSE_TAGS_FROM_TOKENS: {\n TextUnitContentsAsString = this.removeTagsFromTokens(\n DiasdemTextUnit.getContentsAsString(), \"/s:\");\n break;\n } \n default: {\n TextUnitContentsAsString = DiasdemTextUnit.getContentsAsString();\n }\n }\n DiasdemTextUnit.setContentsFromString(TextUnitContentsAsString);\n DiasdemDocument.replaceProcessedTextUnit(i, DiasdemTextUnit);\n }\n\n DiasdemCollection.replaceDocument(DiasdemDocument\n .getDiasdemDocumentID(), DiasdemDocument);\n \n DiasdemDocument = DiasdemCollection.getNextDocument();\n counterProgress++;\n \n } // read all documents\n \n super.closeDiasdemCollection();\n \n CastResult = new ConvertTextUnitsResult(TaskResult.FINAL_RESULT,\n \"All processed text units have been converted in the DIAsDEM document\\n\" +\n \" collection \" +\n Tools.shortenFileName(CastParameter.getCollectionFileName(), 55) + \"!\", \n \"Processed text units have been converted.\");\n this.setTaskResult(100, \"All Documents Processed ...\", CastResult,\n TaskResult.FINAL_RESULT, Task.TASK_FINISHED);\n \n }",
"public static void main(String args[])\n {\n try\n {\n Date startDate = new Date();\n System.out.println(\"Job started \" + startDate);\n\n // Change the thread name so we can easily identify messages\n // from this run in the log.\n Thread t = Thread.currentThread();\n t.setName(\"RunLBL_\" + startDate.getTime());\n\n log.info(\"LBL conversion started\");\n\n RL21Convert lbl = new RL21Convert(RL21Convert.LBL);\n\n // Get a new RunConvert using our conversion class.\n RunConvert run = new RunConvert(lbl);\n\n // RunConvert.process handles all I/O and the calling\n // of the MarcConvert routines to perform the conversion.\n int rc = run.convert();\n log.info(\"LBL conversion completed - return code = \" + rc);\n System.out.println(\"Job completed \" + new java.util.Date() + \" rc = \" + rc);\n System.exit(rc);\n }\n catch (MarcParmException e)\n {\n log.error(\"MarcParmException: \" + e.getMessage(), e);\n }\n catch (Exception e)\n {\n log.error(\"Exception: \" + e.getMessage(), e);\n }\n }",
"public void runParallel() {\n Thread[] threads = new Thread[parallelCount];\n for (int i = 1; i < parallelCount; i++) {\n final int finalI = i;\n Runnable runnable = new Runnable() {\n public void run() {\n runRepeat(finalI);\n }\n };\n threads[i] = new Thread(runnable, \"JAM-\" + i);\n System.out.println(\"Starting thread: \" + threads[i].getName());\n threads[i].start();\n }\n runRepeat(0);\n }",
"public static void main(String[] args) throws IOException {\n\t\tSystem.out.println(\"Starting message processing.....\");\n\n\t\tProcessor processor = new Processor();\n\t\tList<FutureTask<String>> futureTasks = processor.buildFutureCallableMessages();\n\t\tExecutorService executor = Executors.newFixedThreadPool(10);\n\n\t\tint i=1;\n\t\tfor (FutureTask<String> futureTask:futureTasks) {\n\t\t\tSystem.out.println(\"Executing \" + i + \" out of \" + futureTasks.size());\n\t\t\texecutor.execute(futureTask);\n\t\t\ti++;\n\t\t}\n\t\tfor (FutureTask<String> futureTask:futureTasks) {\n\t\t\twhile (true) {\n\t\t\t\tif(futureTask.isDone()){\n\t\t\t\t\tSystem.out.println(\"Done\");\n\t\t\t\t\t//shut down executor service\n\t\t\t\t\t//executor.shutdown();\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tSystem.out.println(\"Done message processing \" + futureTasks.size() + \" message\");\n\t\tSystem.exit(0);\n\t\n\t}",
"@Parameters({ \"Test\", \"env\", \"Parallel\" })\n\t@Test\n\tpublic void createXMLfile(String Test, String env, @Optional(\"false\") Boolean parallel) throws IOException {\n\n\t\tExcel_Handling excel = new Excel_Handling();\n\t\tTimestamp timestamp = new Timestamp(System.currentTimeMillis());\n Instant instant = timestamp.toInstant();\n \n String timeStampString = instant.toString();\n\t\tClassLoader classLoader = getClass().getClassLoader();\n\t\t//SimpleDateFormat formatter = new SimpleDateFormat(\"ddMMyyyyHHmm\"); \n\t\t//Date date = new Date(); \n\t\tFile dataSheet = null;\n\t\tFile dataSheetResult = null;\n\t\tString nameReport = null;\n\t\t\n\t\tnameReport = env+Test+\".html\";\n\t\t//nameReport = env+Test+formatter.format(date)+\".html\";\n\t\t\t\t\n\t\tif (Test.equalsIgnoreCase(\"RegressionIBM\")) {\n\t\t\tdataSheet = new File(classLoader.getResource(\"Datasheet_Regression_IBM.xlsx\").getFile());\n\t\t\tdataSheetResult = new File(classLoader.getResource(\"Datasheet_RegressionIBM_Result.xlsx\").getFile());\n\t\t}\n\t\tif (Test.equalsIgnoreCase(\"RegressionBP\")) {\n\t\t\tdataSheet = new File(classLoader.getResource(\"Datasheet_Regression_BP.xlsx\").getFile());\n\t\t\tdataSheetResult = new File(classLoader.getResource(\"Datasheet_Regression_BP_Result.xlsx\").getFile());\n\t\t}\n\t\tif (Test.equalsIgnoreCase(\"SanityBP\")) {\n\t\t\tSystem.out.println(\"SanityBP reader done!\");\n\t\t\tdataSheet = new File(classLoader.getResource(\"Datasheet_SanityBP.xlsx\").getFile());\n\t\t\tdataSheetResult = new File(classLoader.getResource(\"Datasheet_Sanity_ResultBP.xlsx\").getFile());\n\t\t\tnameReport = \"SanityBPParallel.html\";\n\t\t}\n\t\tif (Test.equalsIgnoreCase(\"SanityIBM\")) {\n\t\t\tSystem.out.println(\"SanityIBM reader done!\");\n\t\t\tdataSheet = new File(classLoader.getResource(\"Datasheet_SanityIBM.xlsx\").getFile());\n\t\t\tdataSheetResult = new File(classLoader.getResource(\"Datasheet_Sanity_ResultIBM.xlsx\").getFile());\n\t\t\tnameReport = \"SanityIBMParallel.html\";\n\t\t}\n\t\tif (Test.equalsIgnoreCase(\"Legal_IBM\"))\n\t\t{\n\t\t\t dataSheet = new File(classLoader.getResource(\"Datasheet_Legal_IBM.xlsx\").getFile());\n\t\t\t dataSheetResult = new File(classLoader.getResource(\"Datasheet_Legal_IBM_Result.xlsx\").getFile());\n\t\t}\n\t\tif (Test.equalsIgnoreCase(\"Legal_BP\"))\n\t\t{\n\t\t\t dataSheet = new File(classLoader.getResource(\"Datasheet_Legal_BP.xlsx\").getFile());\n\t\t\t dataSheetResult = new File(classLoader.getResource(\"Datasheet_Legal_BP_Result.xlsx\").getFile());\n\t\t}\n\t\tif (Test.equalsIgnoreCase(\"Legal_Min\"))\n\t\t{\n\t\t\t dataSheet = new File(classLoader.getResource(\"Datasheet_Legal_Min.xlsx\").getFile());\n\t\t\t dataSheetResult = new File(classLoader.getResource(\"Datasheet_Legal_Min_Result.xlsx\").getFile());\n\t\t}\n\t\ttry {\n\t\t\texcel.ExcelReader(dataSheet.getAbsolutePath(), \"Data\", dataSheetResult.getAbsolutePath(), \"Data\");\n\t\t\texcel.getExcelDataAll(\"Data\", \"Execute\", \"Y\", \"TC_ID\");\n\t\t} catch (Exception e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t}\n\n\t\tSystem.out.println(\"excel reader done!\");\n\t\tSystem.out.println(\"test env is \" + env);\n\n\t\tMap<String, HashMap<String, String>> map = Excel_Handling.TestData;\n\t\t// creation of the testng xml based on parameters/data\n\t\tTestNG testNG = new TestNG();\n\t\tReport_Setup.getInstance();\n\t\tReport_Setup.setReportName(nameReport);\n\t\t\n\t\tXmlSuite suite = new XmlSuite();\n\t\tif (parallel) {\n\t\t\tsuite.setParallel(ParallelMode.TESTS);\n\t\t}\n\t\tfor (String key : map.keySet()) {\n\t\t\tFile configFile = new File(classLoader.getResource(\"Config.xml\").getFile());\n\t\t\tSystem.out.println(\"configFile:: \" + configFile.getAbsolutePath());\n\t\t\tfinal Common_Functions commonFunctions = new Common_Functions();\n\t\t\tsuite.setName(commonFunctions.GetXMLTagValue(configFile.getAbsolutePath(), \"Regression_Suite_Name\"));\n\t\t\tXmlTest test = new XmlTest(suite);\n\t\t\ttest.setName(key);\n\t\t\ttest.setPreserveOrder(\"true\");\n\t\t\ttest.addParameter(\"browserType\", Excel_Handling.Get_Data(key, \"Browser_Type\"));\n\t\t\ttest.addParameter(\"tcID\", key);\n\t\t\ttest.addParameter(\"ENV\", env);\n\t\t\ttest.addParameter(\"appURL\", commonFunctions.GetXMLTagValue(configFile.getAbsolutePath(), \"AppUrl\"));\n\t\t\ttest.addParameter(\"IBMURL\", commonFunctions.GetXMLTagValue(configFile.getAbsolutePath(), env + \"IBM\"));\n\t\t\ttest.addParameter(\"PCSURL\",commonFunctions.GetXMLTagValue(configFile.getAbsolutePath(), env + \"BPDirectPCS\"));\n\t\t\ttest.addParameter(\"MySAURL\", commonFunctions.GetXMLTagValue(configFile.getAbsolutePath(), env + \"MySA\"));\n\t\t\ttest.addParameter(\"Timestamp\", timeStampString);\n\t\t\tXmlClass testClass = new XmlClass();\n\n\t\t\tif (Test.equalsIgnoreCase(\"RegressionIBM\")) {\n\t\t\t\ttestClass.setName(\"com.ibm.stax.Tests.RegressionIBM.\" + Excel_Handling.Get_Data(key, \"Class_Name\"));\n\t\t\t}\n\t\t\tif (Test.equalsIgnoreCase(\"RegressionBP\")) {\n\t\t\t\ttestClass.setName(\"com.ibm.stax.Tests.RegressionBP.\" + Excel_Handling.Get_Data(key, \"Class_Name\"));\n\t\t\t}\n\t\t\tif (Test.equalsIgnoreCase(\"SanityBP\")) {\n\t\t\t\ttestClass.setName(\"com.ibm.stax.Tests.Sanity.\" + Excel_Handling.Get_Data(key, \"Class_Name\"));\n\t\t\t}\n\t\t\tif (Test.equalsIgnoreCase(\"SanityIBM\")) {\n\t\t\t\ttestClass.setName(\"com.ibm.stax.Tests.Sanity.\" + Excel_Handling.Get_Data(key, \"Class_Name\"));\n\t\t\t}\n\t\t\tif (Test.equalsIgnoreCase(\"Legal_IBM\"))\t{\n\t\t\t\ttestClass.setName(\"com.ibm.stax.Tests.Legal.\" + Excel_Handling.Get_Data(key, \"Class_Name\"));\n\t\t\t}\n\t\t\tif (Test.equalsIgnoreCase(\"Legal_BP\")) { \n\t\t\t\ttestClass.setName(\"com.ibm.stax.Tests.Legal.\" + Excel_Handling.Get_Data(key, \"Class_Name\"));\n\t\t\t}\n\t\t\tif (Test.equalsIgnoreCase(\"Legal_Min\")) {\n\t\t\t\ttestClass.setName(\"com.ibm.stax.Tests.Legal.\" + Excel_Handling.Get_Data(key, \"Class_Name\"));\n\t\t\t}\n\t\t\ttest.setXmlClasses(Arrays.asList(new XmlClass[] { testClass }));\n\t\t}\n\t\tList<String> suites = new ArrayList<String>();\n\t\tfinal File f1 = new File(Create_TestNGXML.class.getProtectionDomain().getCodeSource().getLocation().getPath());\n\t\tSystem.out.println(\"f1:: \" + f1.getAbsolutePath());\n\t\tFile f = new File(\".\\\\testNG.xml\");\n\t\tf.createNewFile();\n\t\tFileWriter fw = new FileWriter(f.getAbsoluteFile());\n\t\tBufferedWriter bw = new BufferedWriter(fw);\n\t\tbw.write(suite.toXml());\n\t\tbw.close();\n\t\tsuites.add(f.getPath());\n\t\ttestNG.setTestSuites(suites);\n\t\ttestNG.run();\n\t\tf.delete();\n\t\tReport_Setup.flush();\n\n\t}",
"public static void main(String[] args) {\n\t\tForkJoinPool core = ForkJoinPool.commonPool() ;\n\t\tSystem.out.println(core.getParallelism());\n\t\t\n\t\t// Paralle() on a stream\n\t\tStream stream =Stream.of(\"Shobhit\",\"Mahesh\",\"Suresh\",\"Anand\",\"Andrew\");\n\t\tStream.of(\"Shobhit\",\"Mahesh\",\"Suresh\",\"Anand\",\"Andrew\").forEach(System.out::println);\n\t\tSystem.out.println(\"------\");\n\t\tStream.of(\"Shobhit\",\"Mahesh\",\"Suresh\",\"Anand\",\"Andrew\").parallel().forEach(System.out::println);\n\t\tSystem.out.println(\"------\");\n\t\t//2 .Use ParallelStream method at a collector \n\t\tArrays.asList(\"Shobhit\",\"Mahesh\",\"Suresh\",\"Anand\",\"Andrew\").parallelStream().forEach(System.out::println);\n\t\tSystem.out.println(\"------\");\n\t\t//3.Range method\n\t\tIntStream.rangeClosed(0, 10).forEach(System.out::println);\n\t\tSystem.out.println(\"------\");\n\t\tIntStream.rangeClosed(0, 10).parallel().forEach(System.out::println);\n\t\t//Print in Alaphabetical order\n\t\t//System.out.println(getArrayList());\n\t\tgetArrayList().stream().forEach(System.out::println);\n\t\tgetArrayList().parallelStream().forEach(System.out::println);\n\t\t//Check stream is running in Parallel Mode :-isParallel() Method is there\n\t\tIntStream s1=IntStream.rangeClosed(1,10);\n\t\tSystem.out.println(s1.isParallel()); // to check whether stream is running paralllel or not\n\t\tIntStream s2=IntStream.rangeClosed(1,10);s2.parallel();\n\t\tSystem.out.println(s2.isParallel());\n\t}",
"public void multiThreadCalc(int threadCount, int limit){\n ArrayList<Integer> pids = lcm.getALLProjectID();\n int total = pids.size();\n List<ArrayList<Integer>> pidList = new ArrayList<ArrayList<Integer>>();\n for(int i = 0; i < threadCount; i++) pidList.add(new ArrayList<Integer>());\n for(int i = 0; i < total;){\n for(int j = 0; j < threadCount && i < total; j++, i++)\n pidList.get(j).add(pids.get(i));\n }\n Thread[] threads = new Thread[threadCount];\n for(int i = 0; i < threadCount; i++){\n threads[i] = new Thread(new LangCompetenceMultiThread(i, pidList.get(i), lcm));\n }\n long startTime = System.currentTimeMillis();\n int startCount = Thread.activeCount();\n for(int i = 0; i < threadCount; i++)\n threads[i].start();\n int endCount = Thread.activeCount();\n while(endCount != startCount) endCount = Thread.activeCount();\n long endTime=System.currentTimeMillis();\n System.out.println(\"Used : \" + (endTime - startTime) + \"ms\");\n System.out.println(\"Calculated : \" + commit_count + \" commits\");\n }",
"@Test\n public void testParallelStressMultipleThreadsMultipleWorkersJitEnabled() throws Exception {\n Assume.assumeTrue(JitUtil.isJitSupported());\n\n testParallelStress(queryNoLimit, expectedNoLimit, 4, 4, SqlJitMode.JIT_MODE_ENABLED);\n }",
"public static void main(String[] args) throws InterruptedException {\n TransformationBackendMain.main(new String[] { \"2551\", \"campaign1\", \"campaign2\" });\n }",
"public static void main(String[] args) {\n\n\n List<Integer> source = buildIntRange();\n\n if(CollectionUtils.isNotEmpty(source)){\n\n }\n // 传统方式的遍历\n long start = System.currentTimeMillis();\n for (int i = 0; i < source.size(); i++) {\n try {\n TimeUnit.MILLISECONDS.sleep(1);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n }\n System.out.println(\"传统方式 : \" + (System.currentTimeMillis() - start) + \"ms\");\n\n // 单管道stream\n start = System.currentTimeMillis();\n source.stream().forEach(r -> {\n try {\n TimeUnit.MILLISECONDS.sleep(1);\n } catch (Exception e) {\n e.printStackTrace();\n }\n });\n System.out.println(\"stream : \" + (System.currentTimeMillis() - start) + \"ms\");\n\n // 多管道parallelStream\n start = System.currentTimeMillis();\n source.parallelStream().forEach(r -> {\n try {\n TimeUnit.MILLISECONDS.sleep(1);\n } catch (Exception e) {\n e.printStackTrace();\n }\n });\n System.out.println(\"parallelStream : \" + (System.currentTimeMillis() - start) + \"ms\");\n }",
"public static void main(String[] args) throws FileNotFoundException, IOException {\nfor (double b = 0.5; b < 0.51; b+=0.1) {\n for (double k = 4.40; k < 4.5; k+=0.5) {\n Machine.b = 0.5; //0.2 - ATCnon-delay\n Machine.k = 1.5; //1.4 - ATCnon delay\n int hits = 0;\n engineJob = new cern.jet.random.engine.MersenneTwister(99999);\n noise = new cern.jet.random.Normal(0, 1, engineJob);\n SmallStatistics[] result = new SmallStatistics[5];\n result[0] = new SmallStatistics();\n result[1] = new SmallStatistics();\n for (int ds = 0; ds < 2; ds++) {\n JSPFramework[] jspTesting = new JSPFramework[105];\n for (int i = 0; i < jspTesting.length; i++) {\n jspTesting[i] = new JSPFramework();\n jspTesting[i].getJSPdata(i*2 + 1);\n }\n //DMU - instances (1-80)//la - instances (81-120)\n //mt - instances (121/-123)//orb - instances (124-133)//ta -instances (134-173)\n //////////////////////////////////////////////\n for (int i = 0; i < jspTesting.length; i++) {\n double countEval = 0;\n double tempObj = Double.POSITIVE_INFINITY;\n double globalBest = Double.POSITIVE_INFINITY;\n boolean[] isApplied_Nk = new boolean[2]; //Arrays.fill(isApplied_Nk, Boolean.TRUE);\n int Nk = 0; // index of the Iterative dispatching rule to be used\n jspTesting[i].resetALL();\n boolean firstIteration = true;\n double countLargeStep = 0;\n do{\n countEval++;\n //start evaluate schedule\n jspTesting[i].reset();\n int N = jspTesting[i].getNumberofOperations();\n jspTesting[i].initilizeSchedule();\n int nScheduledOp = 0;\n\n //choose the next machine to be schedule\n while (nScheduledOp<N){\n\n Machine M = jspTesting[i].Machines[jspTesting[i].nextMachine()];\n\n jspTesting[i].setScheduleStrategy(Machine.scheduleStrategy.HYBRID );\n jspTesting[i].setPriorityType(Machine.priorityType.ATC);\n jspTesting[i].setNonDelayFactor(0.3);\n //*\n jspTesting[i].setInitalPriority(M);\n for (Job J:M.getQueue()) {\n double RJ = J.getReadyTime();\n double RO = J.getNumberRemainingOperations();\n double RT = J.getRemainingProcessingTime();\n double PR = J.getCurrentOperationProcessingTime();\n double W = J.getWeight();\n double DD = J.getDuedate();\n double RM = M.getReadyTime();\n double RWT = J.getCurrentOperationWaitingTime();\n double RFT = J.getFinishTime();\n double RNWT = J.getNextOperationWaitingTime();\n int nextMachine = J.getNextMachine();\n\n if (nextMachine==-1){\n RNWT=0;\n } else {\n RNWT = J.getNextOperationWaitingTime();\n if (RNWT == -1){\n RNWT = jspTesting[i].getMachines()[nextMachine].getQueueWorkload()/2.0;\n }\n }\n if (RWT == -1){\n RWT = M.getQueueWorkload()/2.0;\n }\n //J.addPriority((W/PR)*Math.exp(-maxPlus((DD-RM-PR-(RT-PR+J.getRemainingWaitingTime(M)))/(3*M.getQueueWorkload()/M.getNumberofJobInQueue())))); //iATC\n //J.addPriority((PR*PR*0.614577*(-RM-RM/W)-RT*PR*RT/W)\n // -(RT*PR/(W-0.5214191)-RM/W*PR*0.614577+RT*PR/(W-0.5214191)*2*RM/W));\n //J.addPriority(((W/PR)*((W/PR)/(RFT*RFT)))/(max(div((RFT-RT),(RWT/W)),IF(RFT/W-max(RFT-RT,DD),DD,RFT))+DD/RFT+RFT/W-max(RFT-RFT/W,DD))); //best TWT priorityIterative\n if (Nk==0)\n //J.addPriority(min(W/PR-RFT+min(RT,W/RFT),((min(RT,RNWT-RFT)/(RJ-min(RWT,RFT*0.067633785)))/(RJ-min(RWT,RFT*0.067633785))))/RFT);\n J.addPriority(min(W/PR-RFT+min(RT,W/RFT),((div(min(RT,RNWT-RFT),(RJ-min(RWT,RFT*0.067633785))))/(RJ-min(RWT,RFT*0.067633785))))/RFT);\n else\n J.addPriority(min((((W/PR)/RFT)/(2*RNWT+max(RO,RFT)))/(PR+RNWT+max(RO,RFT)),((W/PR)/RFT)/PR)/RFT);\n }\n //jspTesting[i].calculatePriority(M);\n jspTesting[i].sortJobInQueue(M);\n Job J = M.completeJob();\n if (!J.isCompleted()) jspTesting[i].Machines[J.getCurrentMachine()].joinQueue(J);\n nScheduledOp++;\n }\n double currentObj = -100;\n currentObj = jspTesting[i].getTotalWeightedTardiness();\n if (tempObj > currentObj){\n tempObj = currentObj;\n jspTesting[i].recordSchedule();\n Arrays.fill(isApplied_Nk, Boolean.FALSE);\n //System.out.println(\"Improved!!!\");\n }\n else {\n isApplied_Nk[Nk] = true;\n if (!isNextApplied(Nk, isApplied_Nk)) Nk = circleShift(Nk, isApplied_Nk.length);\n else {\n if (globalBest>tempObj) {\n globalBest = tempObj;\n jspTesting[i].storeBestRecordSchedule();\n } jspTesting[i].restoreBestRecordSchedule();\n if (countLargeStep<1) {\n tempObj = Double.POSITIVE_INFINITY;\n Arrays.fill(isApplied_Nk, Boolean.FALSE);\n jspTesting[i].shakeRecordSchedule(noise, engineJob, globalBest);\n countLargeStep++;\n }\n else break;\n }\n }\n firstIteration = false;\n \n } while(true);\n result[ds].add(jspTesting[i].getDevREFTotalWeightedTardiness(globalBest));\n if (jspTesting[i].getDevLBCmax()==0) hits++;\n System.out.println(jspTesting[i].instanceName + \" & \"+ globalBest + \" & \" + countEval);\n }\n }\n //jsp.schedule();\n //*\n System.out.println(\"*************************************************************************\");\n System.out.println(\"[ & \" + formatter.format(result[0].getMin()) + \" & \"\n + formatter.format(result[0].getAverage()) + \" & \" + formatter.format(result[0].getMax()) +\n \" & \" + formatter.format(result[1].getMin()) + \" & \"\n + formatter.format(result[1].getAverage()) + \" & \" + formatter.format(result[1].getMax()) + \"]\");\n //*/\n System.out.print(\"\"+formatter.format(result[0].getAverage()) + \" \");\n }\n System.out.println(\"\");\n}\n }",
"public void testExecuteInParallel_Collection() throws Exception\n {\n System.out.println( \"executeInParallel\" );\n Collection<Callable<Double>> tasks = createTasks( 10 );\n Collection<Double> result = ParallelUtil.executeInParallel( tasks );\n assertEquals( result.size(), tasks.size() );\n }",
"private void runTestProcess(Configuration config) throws Exception {\r\n\t\tint timeout = config.getWorkTimeout();\r\n\t\tlog.info(\"Executing test process...\");\r\n\t\t// Start L2\r\n\t\t// Sorted list to make sure first one becomes active always\r\n\t\tArrayList<String> sortedList = new ArrayList<String>(config.getL2machines());\r\n\t\tCollections.sort(sortedList, String.CASE_INSENSITIVE_ORDER);\r\n\t\tfor (String l2: sortedList){\r\n\t\t\tlog.info(\"Start L2 on l2_machines: \" + l2);\r\n\t\t\texecuteWork(l2, new StartL2(config), timeout);\r\n\t\t}\r\n\t\tcwExecutor.start(getCWProperties(config));\r\n\r\n\t\t// Start l1\r\n\t\tlog.info(\"Start L1 on all l1_machines: \" + config.getL1machines());\r\n\t\tif (config.getLoadmachines().size() > 0) {\r\n\t\t\texecuteWork(config.getL1machines(), new StartL1(config), timeout);\r\n\t\t\t// Start load\r\n\t\t\tlog.info(\"Start Load on all load_machines: \"\r\n\t\t\t\t\t+ config.getLoadmachines());\r\n\t\t\texecuteWorkTillFinish(config.getLoadmachines(), new StartLoad(\r\n\t\t\t\t\tconfig));\r\n\t\t} else\r\n\t\t\texecuteWorkTillFinish(config.getL1machines(), new StartL1(config));\r\n\t}",
"public static void main(String[] args) {\n int[] nums = initializeNums();\n\n THRESHOLD = nums.length / Runtime.getRuntime().availableProcessors();\n\n SequentialMaxFinding sequentialMaxFinding = new SequentialMaxFinding();\n\n long start = System.currentTimeMillis();\n System.out.println(\"Max: \"+sequentialMaxFinding.SequentialMaxFind(nums, nums.length));\n long end = System.currentTimeMillis();\n System.out.println(\"Time taken for Sequential maxFinding: \"+ (end - start) + \" ms\");\n\n System.out.println();\n\n ForkJoinPool pool = new ForkJoinPool(Runtime.getRuntime().availableProcessors());\n ParallelMaxFinding parallelMaxFinding = new ParallelMaxFinding(nums, 0, nums.length);\n\n start = System.currentTimeMillis();\n System.out.println(\"Max: \"+pool.invoke(parallelMaxFinding));\n end = System.currentTimeMillis();\n System.out.println(\"Time taken for Parallel maxFinding: \"+ (end - start) + \" ms\");\n\n }",
"public void runIndividualSpreadsheetTests() {\r\n\r\n\t\t// Make a list of files to be analyzed\r\n\t\tString[] inputFiles = new String[] {\r\n//\t\t\t\t\"salesforecast_TC_IBB.xml\",\r\n//\t\t\t\t\"salesforecast_TC_2Faults.xml\",\r\n//\t\t\t\t\t\t\t\"salesforecast_TC_2FaultsHeavy.xml\",\r\n\t\t\t\t\"SemUnitEx1_DJ.xml\",\r\n\t\t\t\t\"SemUnitEx2_1fault.xml\",\r\n\t\t\t\t\"SemUnitEx2_2fault.xml\",\r\n//\t\t\t\t\"VDEPPreserve_1fault.xml\",\r\n//\t\t\t\t\"VDEPPreserve_2fault.xml\",\r\n//\t\t\t\t\t\t\t\"VDEPPreserve_3fault.xml\",\r\n//\t\t\t\t\"AZA4.xml\",\r\n//\t\t\t\t\"Consultant_form.xml\",\r\n//\t\t\t\t\"Hospital_Payment_Calculation.xml\",\r\n//\t\t\t\t\"Hospital_Payment_Calculation_v2.xml\",\r\n//\t\t\t\t\"Hospital_Payment_Calculation_C3.xml\",\r\n//\t\t\t\t\"11_or_12_diagnoses.xml\",\r\n//\t\t\t\t\"choco_loop.xml\",\r\n//\t\t\t\t\"Paper2.xml\",\r\n//\t\t\t\t\"Test_If.xml\",\r\n//\t\t\t\t\"Test_If2.xml\",\r\n\r\n\t\t};\r\n\r\n\t\tscenarios.add(new Scenario(executionMode.singlethreaded, pruningMode.on, PARALLEL_THREADS, CHOCO3));\r\n//\t\tscenarios.add(new Scenario(executionMode.levelparallel, pruningMode.on, 2, CHOCO3));\r\n//\t\tscenarios.add(new Scenario(executionMode.fullparallel, pruningMode.on, 1, CHOCO3));\r\n\t\tscenarios.add(new Scenario(executionMode.fullparallel, pruningMode.on, 2, CHOCO3));\r\n//\t\tscenarios.add(new Scenario(executionMode.fullparallel, pruningMode.on, 4, CHOCO3));\r\n//\t\tscenarios.add(new Scenario(executionMode.heuristic, pruningMode.on, 1, CHOCO3));\r\n\t\tscenarios.add(new Scenario(executionMode.heuristic, pruningMode.on, 2, CHOCO3));\r\n//\t\tscenarios.add(new Scenario(executionMode.heuristic, pruningMode.on, 4, CHOCO3));\r\n//\t\tscenarios.add(new Scenario(executionMode.heuristic, pruningMode.on, PARALLEL_THREADS, true));\r\n//\t\tscenarios.add(new Scenario(executionMode.hybrid, pruningMode.on, 1, CHOCO3));\r\n\t\tscenarios.add(new Scenario(executionMode.hybrid, pruningMode.on, 2, CHOCO3));\r\n//\t\tscenarios.add(new Scenario(executionMode.hybrid, pruningMode.on, 4, CHOCO3));\r\n//\t\tscenarios.add(new Scenario(executionMode.levelparallel, pruningMode.on, PARALLEL_THREADS, false));\r\n//\t\tscenarios.add(new Scenario(executionMode.fullparallel, pruningMode.on, PARALLEL_THREADS, false));\r\n//\t\tscenarios.add(new Scenario(executionMode.fullparallel, pruningMode.on, PARALLEL_THREADS, false));\r\n//\t\tscenarios.add(new Scenario(executionMode.heuristic,pruningMode.on,PARALLEL_THREADS*2));\r\n//\t\tscenarios.add(new Scenario(executionMode.heuristic,pruningMode.on,0));\r\n\r\n//\t\tinputFiles = new String[]{\"VDEPPreserve_3fault.xml\"};\r\n\r\n\r\n\t\t// Go through the files and run them in different scenarios\r\n\t\tfor (String inputfilename : inputFiles) {\r\n\t\t\trunScenarios(inputFileDirectory, inputfilename, logFileDirectory, scenarios);\r\n\t\t}\r\n\t}",
"public static void main(String[] args) {\n Module module = ActivatorToolBox.simpleLink(new BaseDBActivator(),\n new ConfigurationActivator(),\n new StandaloneModeActivator(),\n new ModuleHealActivator(),\n new StateServiceActivator(),\n new ChartBaseActivator(),\n new SchedulerActivator(),\n new ReportBaseActivator(),\n new RestrictionActivator(),\n new ReportActivator(),\n new WriteActivator());\n SimpleWork.supply(CommonOperator.class, new CommonOperatorImpl());\n String envpath = \"//Applications//FineReport10_325//webapps//webroot//WEB-INF\";\n SimpleWork.checkIn(envpath);\n I18nResource.getInstance();\n module.start();\n\n\n ResultWorkBook rworkbook = null;\n try {\n // read the workbook\n TemplateWorkBook workbook = TemplateWorkBookIO.readTemplateWorkBook(\"//doc//Primary//Parameter//Parameter.cpt\");\n // get the parameters and set value\n Parameter[] parameters = workbook.getParameters();\n parameters[0].setValue(\"华东\");\n // define a parameter map to execute the workbook\n java.util.Map parameterMap = new java.util.HashMap();\n for (int i = 0; i < parameters.length; i++) {\n parameterMap.put(parameters[i].getName(), parameters[i]\n .getValue());\n }\n\n FileOutputStream outputStream;\n\n // unaltered export to xls\n outputStream = new FileOutputStream(new File(\"//Users//susie//Downloads//ExcelExport.xls\"));\n ExcelExporter excel = new ExcelExporter();\n excel.setVersion(true);\n excel.export(outputStream, workbook.execute(parameterMap,new WriteActor()));\n\n // unaltered export to xlsx\n outputStream = new FileOutputStream(new File(\"//Users//susie//Downloads//ExcelExport.xlsx\"));\n StreamExcel2007Exporter excel1 = new StreamExcel2007Exporter();\n excel.export(outputStream, workbook.execute(parameterMap,new WriteActor()));\n\n // full page export to xls\n outputStream = new FileOutputStream(new File(\"//Users//susie//Downloads//PageExcelExport.xls\"));\n PageExcelExporter page = new PageExcelExporter(ReportUtils.getPaperSettingListFromWorkBook(workbook.execute(parameterMap,new WriteActor())));\n page.setVersion(true);\n page.export(outputStream, workbook.execute(parameterMap,new WriteActor()));\n\n // full page export to xlsx\n outputStream = new FileOutputStream(new File(\"//Users//susie//Downloads//PageExcelExport.xlsx\"));\n PageExcel2007Exporter page1 = new PageExcel2007Exporter(ReportUtils.getPaperSettingListFromWorkBook(rworkbook));\n page1.export(outputStream, workbook.execute(parameterMap,new WriteActor()));\n\n // page to sheet export to xls\n outputStream = new FileOutputStream(new File(\"//Users//susie//Downloads//PageSheetExcelExport.xls\"));\n PageToSheetExcelExporter sheet = new PageToSheetExcelExporter(ReportUtils.getPaperSettingListFromWorkBook(workbook.execute(parameterMap,new WriteActor())));\n sheet.setVersion(true);\n sheet.export(outputStream, workbook.execute(parameterMap,new WriteActor()));\n\n // page to sheet export to xlsx\n outputStream = new FileOutputStream(new File(\"//Users//susie//Downloads//PageSheetExcelExport.xlsx\"));\n PageToSheetExcel2007Exporter sheet1 = new PageToSheetExcel2007Exporter(ReportUtils.getPaperSettingListFromWorkBook(rworkbook));\n sheet1.export(outputStream, workbook.execute(parameterMap,new WriteActor()));\n\n // Large data volume export to xls\n outputStream = new FileOutputStream(new File(\"//Users//susie//Downloads//LargeExcelExport.zip\"));\n LargeDataPageExcelExporter large = new LargeDataPageExcelExporter(ReportUtils.getPaperSettingListFromWorkBook(workbook.execute(parameterMap,new WriteActor())), true);\n\n // Large data volume export to xlsx\n // outputStream = new FileOutputStream(new File(\"//Users//susie//Downloads//LargeExcelExport.xlsx\"));\n // LargeDataPageExcel2007Exporter large = new LargeDataPageExcel2007Exporter(ReportUtils.getPaperSettingListFromWorkBook(rworkbook), true);\n large.export(outputStream, workbook.execute(parameterMap,new WriteActor()));\n\n outputStream.close();\n module.stop();\n } catch (Exception e) {\n e.printStackTrace();\n }\n }",
"public static void twoClientSetupProcesses() {\n\n\tList<String> aClientTags=TagsFactory.getAssignmentTags().getTwoClientClientTags();\n\tList<String> aServerTags=TagsFactory.getAssignmentTags().getTwoClientServerTags();\n\n\ttwoClientSetupProcesses(aClientTags, aServerTags);\n//\tBasicExecutionSpecificationSelector.getBasicExecutionSpecification().setProcessTeams(Arrays.asList(\"RegistryBasedDistributedProgram\"));\n//\tBasicExecutionSpecificationSelector.getBasicExecutionSpecification().setTerminatingProcesses(\"RegistryBasedDistributedProgram\", Arrays.asList(\"Client_0\", \"Client_1\"));\n//\tBasicExecutionSpecificationSelector.getBasicExecutionSpecification().setProcesses(\"RegistryBasedDistributedProgram\", Arrays.asList(\"Registry\", \"Server\", \"Client_0\", \"Client_1\"));\n//\tBasicExecutionSpecificationSelector.getBasicExecutionSpecification().setEntryTags(\"Registry\", Arrays.asList(\"Registry\"));\n//\tBasicExecutionSpecificationSelector.getBasicExecutionSpecification().setEntryTags(\"Server\", aServerTags);\n//\tBasicExecutionSpecificationSelector.getBasicExecutionSpecification().setEntryTags(\"Client_0\", aClientTags);\n//\tBasicExecutionSpecificationSelector.getBasicExecutionSpecification().setEntryTags(\"Client_1\", aClientTags);\n//\tBasicExecutionSpecificationSelector.getBasicExecutionSpecification().setArgs(\"Registry\", FlexibleStaticArgumentsTestCase.TEST_REGISTRY_ARGS);\n//\tBasicExecutionSpecificationSelector.getBasicExecutionSpecification().setArgs(\"Server\", FlexibleStaticArgumentsTestCase.TEST_SERVER_ARGS);\n//\tBasicExecutionSpecificationSelector.getBasicExecutionSpecification().setArgs(\"Client_0\", FlexibleStaticArgumentsTestCase.TEST_CLIENT_0_ARGS);\n//\tBasicExecutionSpecificationSelector.getBasicExecutionSpecification().setArgs(\"Client_1\", FlexibleStaticArgumentsTestCase.TEST_CLIENT_1_ARGS);\n//\tBasicExecutionSpecificationSelector.getBasicExecutionSpecification().setSleepTime(\"Registry\", 500);\n//\tBasicExecutionSpecificationSelector.getBasicExecutionSpecification().setSleepTime(\"Server\", 2000);\n//\tBasicExecutionSpecificationSelector.getBasicExecutionSpecification().setSleepTime(\"Client_0\", 5000);\n//\tBasicExecutionSpecificationSelector.getBasicExecutionSpecification().setSleepTime(\"Client_1\", 5000);\n//\tBasicExecutionSpecificationSelector.getBasicExecutionSpecification().getProcessTeams().forEach(team -> System.out.println(\"### \" + team));\n}",
"protected Smp(int maxThreads) {\r\n\tmaxThreads = Math.max(1,maxThreads);\r\n\tthis.maxThreads = maxThreads;\r\n\tif (maxThreads>1) {\r\n\t\tthis.taskGroup = new FJTaskRunnerGroup(maxThreads);\r\n\t}\r\n\telse { // avoid parallel overhead\r\n\t\tthis.taskGroup = null;\r\n\t}\r\n}",
"public static void main(String[] args) {\n\t\tint num;\n\t\tArrayList<Thread> numbersThreads = new ArrayList<Thread>();\n\t\t\n\t\tnum = 0;\n\t\tScanner number = new Scanner(System.in);\n\t\tfor(int i = 0; i < 4; i++)\n\t\t{\n\t\t\tSystem.out.println(\"Put number \" + i + \": \");\n\t\t\tnum = number.nextInt();\n\t\t\tPrimeCalculator numRunnable = new PrimeCalculator(num);\n\t\t\tThread t1 = new Thread(numRunnable);\n\t\t\tnumbersThreads.add(t1);\n\t\t}\n\t\t\n\t\tfor(int i = 0; i < numbersThreads.size(); i++)\n\t\t\tnumbersThreads.get(i).start();\n\t\tnumber.close();\n\t}",
"public static void main(String[] args) {\n for (int i=1001; i < 1007; i++){\n String[] pArgs = new String[1];\n pArgs[0] = Integer.toString(i);\n new Thread(() -> PeerProcess.main(pArgs)).start();\n\n // Delay to give the peers enough time to start. We need to make sure the peers start in the correct order\n try{\n TimeUnit.MILLISECONDS.sleep(500);\n } catch(Exception e){\n System.out.println(e);\n exit(1);\n }\n }\n }",
"@Test\n public void testThread() {\n\n Thread thread1 = new Thread(() -> {\n //i++;\n for (int j = 0; j < 2000000; j++) {\n (this.i)++;\n }\n });\n\n Thread thread2 = new Thread(() -> {\n //System.out.println(\"i = \" + i);\n for (int j = 0; j < 2000000; j++) {\n System.out.println(\"i = \" + this.i);\n }\n });\n\n thread1.start();\n thread2.start();\n /*for (int j = 0; j < 20; j++) {\n thread1.start();\n thread2.start();\n }*/\n\n\n /* ValueTask valueTask = new ValueTask();\n PrintTask printTask = new PrintTask();*/\n\n /*for (int i = 0; i < 20; i++) {\n Worker1 worker1 = new Worker1(valueTask);\n Worker2 worker2 = new Worker2(printTask);\n\n worker1.start();\n worker2.start();\n }*/\n\n }",
"public void testExecuteInSequence() throws Exception\n {\n System.out.println( \"executeInSequence\" );\n Collection<Callable<Double>> tasks = createTasks( 10 );\n Collection<Double> result = ParallelUtil.executeInSequence( tasks );\n assertEquals( result.size(), tasks.size() );\n }",
"@Test\n public void testParallelPropagationLoopBack3Sites() {\n // Create locators\n Integer lnPort = vm0.invoke(() -> WANTestBase.createFirstLocatorWithDSId(1));\n Integer nyPort = vm1.invoke(() -> WANTestBase.createFirstRemoteLocator(2, lnPort));\n Integer tkPort = vm2.invoke(() -> WANTestBase.createFirstRemoteLocator(3, lnPort));\n\n // create cache and receivers on all the 3 sites\n createCacheInVMs(lnPort, vm3, vm6);\n createReceiverInVMs(vm3, vm6);\n createCacheInVMs(nyPort, vm4, vm7);\n createReceiverInVMs(vm4, vm7);\n createCacheInVMs(tkPort, vm5);\n createReceiverInVMs(vm5);\n\n\n // create senders on all the 3 sites\n vm3.invoke(() -> WANTestBase.createSender(\"ln\", 2, true, 100, 10, false, false, null, true));\n vm6.invoke(() -> WANTestBase.createSender(\"ln\", 2, true, 100, 10, false, false, null, true));\n\n vm4.invoke(() -> WANTestBase.createSender(\"ny\", 3, true, 100, 10, false, false, null, true));\n vm7.invoke(() -> WANTestBase.createSender(\"ny\", 3, true, 100, 10, false, false, null, true));\n\n vm5.invoke(() -> WANTestBase.createSender(\"tk\", 1, true, 100, 10, false, false, null, true));\n\n // create PR on the 3 sites\n vm3.invoke(() -> WANTestBase.createPartitionedRegion(getTestMethodName() + \"_PR\", \"ln\", 0, 100,\n isOffHeap()));\n vm6.invoke(() -> WANTestBase.createPartitionedRegion(getTestMethodName() + \"_PR\", \"ln\", 0, 100,\n isOffHeap()));\n\n vm4.invoke(() -> WANTestBase.createPartitionedRegion(getTestMethodName() + \"_PR\", \"ny\", 0, 100,\n isOffHeap()));\n vm7.invoke(() -> WANTestBase.createPartitionedRegion(getTestMethodName() + \"_PR\", \"ny\", 0, 100,\n isOffHeap()));\n\n vm5.invoke(() -> WANTestBase.createPartitionedRegion(getTestMethodName() + \"_PR\", \"tk\", 0, 100,\n isOffHeap()));\n\n // start senders on all the sites\n startSenderInVMs(\"ln\", vm3, vm6);\n\n startSenderInVMs(\"ny\", vm4, vm7);\n\n vm5.invoke(() -> WANTestBase.startSender(\"tk\"));\n\n // pause senders on site1 and site3. Site2 has the sender running to pass along events\n vm3.invoke(() -> WANTestBase.pauseSender(\"ln\"));\n vm6.invoke(() -> WANTestBase.pauseSender(\"ln\"));\n\n vm5.invoke(() -> WANTestBase.pauseSender(\"tk\"));\n\n // do puts on site1\n vm3.invoke(() -> WANTestBase.doPuts(getTestMethodName() + \"_PR\", 100));\n\n // do more puts on site3\n vm5.invoke(() -> WANTestBase.doPutsFrom(getTestMethodName() + \"_PR\", 100, 200));\n\n // verify queue size on site1 and site3\n vm3.invoke(() -> WANTestBase.verifyQueueSize(\"ln\", 100));\n vm5.invoke(() -> WANTestBase.verifyQueueSize(\"tk\", 100));\n\n // resume sender on site1 so that events reach site2 and from there to site3\n vm3.invoke(() -> WANTestBase.resumeSender(\"ln\"));\n vm6.invoke(() -> WANTestBase.resumeSender(\"ln\"));\n vm6.invoke(() -> waitForSenderRunningState(\"ln\"));\n vm3.invoke(() -> waitForSenderRunningState(\"ln\"));\n\n // validate region size on site2 (should have 100) and site3 (should have 200)\n vm4.invoke(() -> WANTestBase.validateRegionSize(getTestMethodName() + \"_PR\", 100));\n vm5.invoke(() -> WANTestBase.validateRegionSize(getTestMethodName() + \"_PR\", 200));\n\n // verify queue size remains same on site3 which means event loopback did not happen\n // this means events coming from site1 are not enqueued back into the sender\n vm5.invoke(() -> WANTestBase.verifyQueueSize(\"tk\", 100));\n\n // resume sender on site3\n vm5.invoke(() -> WANTestBase.resumeSender(\"tk\"));\n vm5.invoke(() -> waitForSenderRunningState(\"tk\"));\n\n // validate region size\n vm3.invoke(() -> WANTestBase.validateRegionSize(getTestMethodName() + \"_PR\", 200));\n vm4.invoke(() -> WANTestBase.validateRegionSize(getTestMethodName() + \"_PR\", 200));\n vm5.invoke(() -> WANTestBase.validateRegionSize(getTestMethodName() + \"_PR\", 200));\n }",
"public static void main(String[] args)\n\t{\n\t\tint coreCount = Runtime.getRuntime().availableProcessors();\n\t\t//Create the pool\n\t\tExecutorService ec = Executors.newCachedThreadPool(); //Executors.newFixedThreadPool(coreCount);\n\t\tfor(int i=0;i<100;i++) \n\t\t{\n\t\t\t//Thread t = new Thread(new Task());\n\t\t\t//t.start();\n\t\t\tec.execute(new Task());\n\t\t\tSystem.out.println(\"Thread Name under main method:-->\"+Thread.currentThread().getName());\n\t\t}\n\t\t\n\t\t//for scheduling tasks\n\t\tScheduledExecutorService service = Executors.newScheduledThreadPool(10);\n\t\tservice.schedule(new Task(), 10, TimeUnit.SECONDS);\n\t\t\n\t\t//task to run repetatively 10 seconds after previous taks completes\n\t\tservice.scheduleWithFixedDelay(new Task(), 15, 10, TimeUnit.SECONDS);\n\t\t\n\t}",
"private static void localParallelSweep(String [] args){\n\t\tString applicationPath = convertApplication(args[2], null);\n\t\tConfMan baseConfigManager;\n\t\t\n\n\t\tboolean synthesis = false;\n\t\tif(args[5].equals(\"true\")){\n\t\t\tsynthesis = true;\n\t\t}\n\t\telse if (args[5].equals(\"false\")){\n\t\t\tsynthesis = false;\n\t\t} else{\n\t\t\tSystem.out.println(\"Synthesis parameter not set correctly: \" + args[3]+ \"\");\n\t\t\tSystem.out.println(\"Valid values are \\\"true\\\" and \\\"false\\\"\");\n\t\t\tSystem.out.println(\"Aborting...\");\n\t\t\treturn;\n\t\t}\n\n\n\n\t\tbaseConfigManager = new ConfMan(args[1], applicationPath, synthesis);\n\t\tConfMan[] cms;\n\t\tAmidarSimulationResult[] results;\n\t\t\n\t\tSweepConfig sweepConfig = new SweepConfig(baseConfigManager, args[3],false);\n\n\t\tcms = sweepConfig.getConfManager();\n\n\t\tTrace sweepTrace = new Trace(System.out, System.in, \"\", \"\");\n\t\tsweepTrace.setPrefix(\"basic config\");\n\t\tbaseConfigManager.printConfig(sweepTrace);\n\n\t\tsweepTrace.setPrefix(\"sweep\");\n\t\tsweepTrace.printTableHeader(\"Sweeping:\");\n\n\n\n\n\t\t//////// Starting RMI Servers + Creating client Threads /////////////////////////\n\t\tlong start = 0;\n\t\tlong stop = 0;\n\t\tProcess regProcess = null;\n\t\tProcess[] servers = null;\n\t\tString workingDirectory = System.getProperty(\"user.dir\");\n\t\tworkingDirectory = workingDirectory.substring(0, workingDirectory.length()-7);\n\t\tString codeBase = \t\"file://\"+workingDirectory+\"/AmidarTools/bin/ \"+\n\t\t\t\t\t\t\t\"file://\"+workingDirectory+\"/Synthesis/bin/ \"+\n\t\t\t\t\t\t\t\"file://\"+workingDirectory+\"/cgra/CGRA/bin/ \"+\n\t\t\t\t\t\t\t\"file://\"+workingDirectory+\"/Amidar/bin/ \"+\n\t\t\t\t\t\t\t\"file://\"+workingDirectory+\"/AXTLoader/bin/ \"+\n\t\t\t\t\t\t\t\"file://\"+workingDirectory+\"/AmidarTools/lib/axtConverter.jar \"+\n\t\t\t\t\t\t\t\"file://\"+workingDirectory+\"/AmidarTools/lib/bcel-5.2.jar \"+\n\t\t\t\t\t\t\t\"file://\"+workingDirectory+\"/AmidarTools/lib/commons-lang-2.6.jar \"+\n\t\t\t\t\t\t\t\"file://\"+workingDirectory+\"/AmidarTools/lib/j-text-utils-0.3.3.jar \"+\n\t\t\t\t\t\t\t\"file://\"+workingDirectory+\"/AmidarTools/lib/json-simple-1.1.1.jar \"+\n\t\t\t\t\t\t\t\"file://\"+workingDirectory+\"/AmidarTools/lib/lombok.jar\";\n\t\t\t\t\t\t\t\n\t\tProcessBuilder regProcessBuilder = new ProcessBuilder(\"/usr/lib/jvm/java-8-oracle/bin/rmiregistry\", \"-J-Djava.rmi.server.codebase=\" + codeBase);\n\t\ttry {\n\t\t\tFile logFolder = new File(\"log/remoteSimLog\");\n\t\t\tlogFolder.mkdirs();\n\t\t\t\n\t\t\tsweepTrace.println(\"Starting RMI registry...\");\n\t\t\tFile regLog = new File(\"log/remoteSimLog/registry.log\");\n\t\t\tregProcessBuilder.redirectError(regLog);\n\t\t\tregProcessBuilder.redirectOutput(regLog);\n\t\t\tregProcess = regProcessBuilder.start();\n\t\t\tsweepTrace.println(\" DONE\");\n\n\t\t\tint nrOfServers = Integer.parseInt(args[4]);\n\t\t\tservers = new Process[nrOfServers];\n\t\t\tClientSimulatorTask[] clientThreads = new ClientSimulatorTask[nrOfServers];\n\t\t\t\n\t\t\tThread.sleep(500);\n\t\t\t\n\t\t\tfor(int i = 0; i < nrOfServers; i++){\n\t\t\t\tString serverName = AmidarRemoteManager.REMOTE_SERVER_STUB_NAME + i ;\n\t\t\t\t\n\t\t\t\tsweepTrace.println(\"Starting remote simulator \" + serverName);\n\t\t\t\tProcessBuilder pb = new ProcessBuilder(\"java\", \"-cp\", \"../Amidar/bin:../AmidarTools/bin:../AmidarTools/lib/axtConverter.jar:../AmidarTools/lib/bcel-5.2.jar:../AmidarTools/lib/commons-lang-2.6.jar:../AmidarTools/lib/j-text-utils-0.3.3.jar:../AmidarTools/lib/json-simple-1.1.1.jar:../AmidarTools/lib/lombok.jar:../AXTLoader/bin:../Synthesis/bin:../cgra/CGRA/bin\", \"amidar.sweep.AmidarRemoteSimulator\", serverName);\n\t\t\t\tFile log = new File(\"log/remoteSimLog/\"+serverName+\".log\");\n\t\t\t\tpb.redirectError(log);\n\t\t\t\tpb.redirectOutput(log);\n\n\t\t\t\tservers[i] = pb.start();\n\t\t\t\t//\t\t\t\tSystem.out.println(servers[i].waitFor());\n\n\t\t\t\tTrace clientTrace = new Trace(System.out, System.in, \"\", \"\");\n\t\t\t\tclientTrace.setPrefix(\"client \"+ i);\n\n\t\t\t\tclientThreads[i] = new ClientSimulatorTask(serverName, clientTrace, \"localhost\", 1099);\n\t\t\t\tsweepTrace.println(\" DONE\");\n\t\t\t}\n\t\t\t////////////////////////////////////////////////////////\n\t\t\t\tThread.sleep(500);\n\n\t\t\tClientSimulatorTask.init(sweepConfig, \"log/sweep\");\n\n\t\t\t///\n\t\t\tstart = System.nanoTime();\n\t\t\tfor(int i = 0; i< nrOfServers; i++ ){\n\t\t\t\tsweepTrace.println(\"Starting client thread no\"+i);\n\t\t\t\tclientThreads[i].start();\n\t\t\t}\n\n\t\t\tfor(int i = 0; i< nrOfServers; i++ ){\n\t\t\t\tclientThreads[i].join();\n\t\t\t\tsweepTrace.println(\"Finished client thread no\"+i);\n\t\t\t}\n\t\t\tstop = System.nanoTime();\n\t\t\t////\n\n\t\t} catch (Exception e1) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te1.printStackTrace();\n\t\t} finally {\n\t\t\tif(regProcess != null){\n\t\t\t\tregProcess.destroy();\n\t\t\t\tsweepTrace.println(\"Ended RMI registry\");\n\t\t\t}\n\t\t\tif(servers != null){\n\t\t\t\tfor(int i = 0; i< servers.length; i++){\n\t\t\t\t\tif(servers[i] != null){\n\t\t\t\t\t\tservers[i].destroy();\n\t\t\t\t\t\tsweepTrace.println(\"Ended remote simulator Amidar_\"+i);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\n\n\t\t\n\t\tresults = ClientSimulatorTask.getResults();\n\t\t\n\t\tif(sweepTrace.active()){\n\t\t\tsweepTrace.setPrefix(\"results\");\n\t\t\tsweepTrace.printTableHeader(\"Simulated \"+applicationPath+\" - Synthesis \"+(synthesis?\"ON\":\"OFF\"));\n\t\t\t\n\t\t\tString[] configs = sweepConfig.getSweepConfigurations();\n\t\t\tfor(int i = 0; i<cms.length; i++){\n\t\t\t\tsweepTrace.println(configs[i] + \":\");\n\t\t\t\tsweepTrace.println(\"\\tTicks: \"+results[i].getTicks());\n\t\t\t\tsweepTrace.println(\"\\tBytecodes: \"+results[i].getByteCodes());\n\t\t\t\t\n\t\t\t\t//\t\t\t\tresultTrace.printTableHeader(\"Loop Profiling\");\n\t\t\t\t//\t\t\t\tresults.get(tm).getProfiler().reportProfile(resultTrace);\n\t\t\t}\n\t\t\tsweepTrace.println();\n\t\t\tsweepTrace.println(\"Execution Time: \"+(stop-start)/1000000+\" ms\");\n\t\t}\n\t\t\n\t\texportPlot(results, sweepConfig);\n\n\n\t}",
"@Test\n public void launchesEventhandlerThreadpoolMaxsizeTest() {\n // TODO: test launchesEventhandlerThreadpoolMaxsize\n }",
"@Test\n public void orgApacheFelixEventadminAsyncToSyncThreadRatioTest() {\n // TODO: test orgApacheFelixEventadminAsyncToSyncThreadRatio\n }",
"public static void spawnThreads(String type) {\n\t\tThread[] threads = new Thread[threadCount];\n\n\t\tfor (int i = 0; i < threadCount; i++) {\n\t\t\tthreads[i] = new Thread(new TestCoarseList(i, type));\n\t\t\tthreads[i].start();\n\t\t}\n\n\t\tfor (Thread t : threads) {\n\t\t\ttry {\n\t\t\t\tt.join();\n\t\t\t} catch (InterruptedException e) {\n\t\t\t\te.printStackTrace();\n\t\t\t}\n\t\t}\n\t}",
"public static void main(String[] args)\n\t{\n\t\tString fullFile = \"\";\n\t\tint lineAmount = 0;\n\t\ttry\n\t\t{\n\t\t\tBufferedReader br = new BufferedReader(\n\t\t\t\t\tnew FileReader(\"alice.txt\"));\n\t\t\t\n\t\t\tString st = br.readLine();\n\t\t\t//int counter = 0;\n\t\t while (st != null)\n\t\t {\n\t\t \t//fullFile[counter] = st;\n\t\t \tfullFile += st;\n\t\t \t//System.out.println(st);\n\t\t \tst = br.readLine();\n\t\t \tlineAmount++;\n\t\t \t//counter++;\n\t\t }\n\t\t br.close();\n\t\t}\n\t\tcatch(FileNotFoundException ex)\n\t\t{\n\t\t\tex.printStackTrace();\n\t\t}\n\t\tcatch (IOException e)\n\t\t{\n\t\t\te.printStackTrace();\n\t\t}\n\t\t\n\t\tint processors = Runtime.getRuntime().availableProcessors();\n\t\tSystem.out.println(\"Num of processors: \" + processors);\n\t\t\n\t\tForkJoinPool forkJoinPool = new ForkJoinPool(processors);\n\t\t\n\t\tint x = fullFile.length() / processors;\n\t\t\n//\t\tint count = 0;\n//\t\tint stoppingPointForLastThread = 0;\n\t\t\n//\t\tfor(int i = 0; i < fullFile.length(); i++)\n//\t\t{\n//\t\t\tif(fullFile.charAt(i) == '\\n')\n//\t\t\t{\n//\t\t\t\tcount++;\n//\t\t\t}\n//\t\t\t\n//\t\t\tif(count >= processors)\n//\t\t\t{\n//\t\t\t\tThread t = new Thread( fullFile.substring(\n//\t\t\t\t\t\tstoppingPointForLastThread, i) );\n//\t\t\t\t\n//\t\t\t\tstoppingPointForLastThread = i;\n//\t\t\t\tcount = 0;\n//\t\t\t}\n//\t\t}\n\t\t\n\t\tint divisionOfWork = (lineAmount * 40) / processors;\n\t\t\n//\t\tThread t = new Thread( fullFile.substring(0, \n//\t\t\t\tdivisionOfWork) );\n//\t\tThread t = new Thread( \n//\t\t\t\tfullFile.substring(divisionOfWork, \n//\t\t\t\tdivisionOfWork * 2) );\n\t\t\n\t\t//FORKJOIN\n\t\tAtomicInteger wordCount = new AtomicInteger(0);\n\t\tfor(int i = 0; i < processors; i++)\n\t\t{\n\t\t\tDataParallelThread t = new DataParallelThread( \n\t\t\t\t\tfullFile.substring(divisionOfWork * i, \n\t\t\t\t\tdivisionOfWork + (divisionOfWork * i)) );\n\t\t\t\n\t\t\twordCount.getAndAdd(\n\t\t\t\t\tforkJoinPool.invoke(t).get()\n\t\t\t\t\t);\n\t\t}\n\t\tSystem.out.println(\"Word count of \\\"the\\\" is: \" + \n\t\t\t\twordCount);\n\t\t\n\t\t//THREAD\n\t\tMyThread[] threads = new MyThread[processors];\n\t\tfor(int i = 0; i < processors; i++)\n\t\t{\n\t\t\tMyThread t = new MyThread( \n\t\t\t\t\tfullFile.substring(divisionOfWork * i, \n\t\t\t\t\tdivisionOfWork + (divisionOfWork * i)) );\n\t\t\t\n\t\t\tt.run();\n\t\t\tthreads[i] = t;\n\t\t}\n\t\t\n\t\tint wordCount2 = 0;\n\t\tfor(int i = 0; i < processors; i++)\n\t\t{\n\t\t\twordCount2 += threads[i].WordCount();\n\t\t}\n\t\t\n\t\tSystem.out.println(\"Word count of \\\"the\\\" is: \" + \n\t\t\t\t\twordCount2);\n\t\t\n\t\t\n\t\t\n//\t\tint wordCount = 0;\n//\t\tfor(int i = 0; i < processors; i++)\n//\t\t{\n//\t\t\twordCount += forkJoinPool.\n//\t\t}\n\t}",
"public void testExecuteInParallel_Collection_ThreadPoolExecutor() throws Exception\n {\n System.out.println( \"executeInParallel\" );\n Collection<Callable<Double>> tasks = createTasks( 10 );\n Collection<Double> result = ParallelUtil.executeInParallel( tasks, ParallelUtil.createThreadPool( 1 ) );\n assertEquals( result.size(), tasks.size() );\n }",
"@Override\n\tpublic int getMaxThreads() {\n\t\treturn 10;\n\t}",
"@Test\n public void testGetNextCulturalObjectByCountDownLatchMethod() throws InterruptedException {\n final CountDownLatch startSignal = new CountDownLatch(1);\n final CountDownLatch resultsReadySignal = new CountDownLatch(NUMBER_OF_EXECUTIONS);\n final Multimap<Long, CulturalObject> multimap = ArrayListMultimap.create();\n for (int i = 0; i < NUMBER_OF_EXECUTIONS; i++) {\n new Thread(() -> {\n try {\n startSignal.await();\n CulturalObject co = cardService.getNextCulturalObject(null);\n if (co != null) {\n multimap.put(co.getId(), co);\n }\n } catch (InterruptedException e) {\n LOG.error(\"Thread exception: \", e);\n } finally {\n resultsReadySignal.countDown();\n }\n }).start();\n }\n\n Thread.sleep(100); // give some time to create and start all threads\n startSignal.countDown(); // signal all workers\n\n resultsReadySignal.await();\n\n double[] sizes = multimap.keySet().stream().mapToDouble(aLong -> (double) multimap.get(aLong).size()).toArray();\n StandardDeviation std = new StandardDeviation();\n assertThat(std.evaluate(sizes), is(closeTo(0.0, 0.5)));\n }",
"public static void main(String[] args) {\n\t\t\n\t\tboolean verbose = false;\n\t\tString[] mainArgs = new String[1];\n\t\t\n\t\tif (args[0].equals(\"--verbose\"))\n\t\t\tverbose = true;\n\t\t\n\t\tif (verbose)\n\t\t\tmainArgs[0] = args[1];\n\t\telse\n\t\t\tmainArgs[0] = args[0];\n\t\t\n\t\tMain main = new Main();\n\t\tArrayList<Process> processes = main.processInput(mainArgs);\n\t\tArrayList<Process> processes2 = new ArrayList<Process>();\n\t\tArrayList<Process> processes3 = new ArrayList<Process>();\n\t\tArrayList<Process> processes4 = new ArrayList<Process>();\n\t\t\n\t\tint i = 0;\n\t\twhile (i < 3) {\n\t\t\tfor (int j = 0; j < processes.size(); j++) {\n\t\t\t\tProcess p = processes.get(j);\n\t\t\t\tProcess pCopy = new Process(p);\n\t\t\t\tpCopy.setCpuTime(pCopy.getC());\n\t\t\t\tif (i == 0)\n\t\t\t\t\tprocesses2.add(pCopy);\n\t\t\t\telse if (i == 1)\n\t\t\t\t\tprocesses3.add(pCopy);\n\t\t\t\telse\n\t\t\t\t\tprocesses4.add(pCopy);\n\t\t\t}\n\t\t\ti++;\n\t\t}\n\t\t\n\n\t\tScheduler s = new Scheduler();\n\t\ts.FCFS(processes, verbose);\n\t\tSystem.out.println(\"\");\n//\t\ts.RR(processes2, verbose);\n//\t\tSystem.out.println(\"\");\n//\t\ts.uniProgramming(processes3, verbose);\n//\t\tSystem.out.println(\"\");\n//\t\ts.SJF(processes4, verbose);\n\t}",
"public static void main(String[] args) {\n\t\t// create a thread and start a parallel execution from here\t\t\n\t\ttry{\n\t\t\tDate dNow = new Date( );\n\t\t\tSimpleDateFormat ft = new SimpleDateFormat(\"ddMMyyyyhhmmss\");\n\t\t\tString RunID = String.valueOf(ft.format(dNow)) + String.valueOf(System.currentTimeMillis());\n\t\t\tGlobalProperties.items.setRunID(RunID);\n\t\t\trun();\n\t\t\t\n\t\t}\n\t\tcatch(Exception ex){\n\t\t\t\n\t\t}\n\n\t}",
"@Ignore\r\n @Test\r\n public void speedTest() throws InterruptedException {\n for (int i = 0; i < 10; i++) {\r\n singleSpeedTest();\r\n }\r\n }",
"public static void main(String args[]) throws Exception\n {\n ImplementsRunnable rc = new ImplementsRunnable();\n Thread t1 = new Thread(rc);\n t1.start();\n Thread.sleep(1000); // Waiting for 1 second before starting next thread\n Thread t2 = new Thread(rc);\n t2.start();\n Thread.sleep(1000); // Waiting for 1 second before starting next thread\n Thread t3 = new Thread(rc);\n t3.start();\n \n // Modification done here. Only one object is shered by multiple threads\n // here also.\n ExtendsThread extendsThread = new ExtendsThread();\n Thread thread11 = new Thread(extendsThread);\n thread11.start();\n Thread.sleep(1000);\n Thread thread12 = new Thread(extendsThread);\n thread12.start();\n Thread.sleep(1000);\n Thread thread13 = new Thread(extendsThread);\n thread13.start();\n Thread.sleep(1000);\n }",
"private void processFunction(String function) throws TargetException, InterruptedException {\n String[] pieces = function.split(\"\\\\*\");\n long delay = getDelay();\n int parallelThreadCount = 1;\n if (pieces.length > 1) {\n parallelThreadCount = Integer.parseInt(pieces[1]);\n }\n if (parallelThreadCount == 1) {\n performFunction(pieces[0], 1);\n } else {\n Thread[] threads = new Thread[parallelThreadCount];\n AtomicBoolean[] threadOK = new AtomicBoolean[parallelThreadCount];\n for (int i = 0; i < parallelThreadCount; i++) {\n threadOK[i] = new AtomicBoolean();\n threads[i] = new Thread(new Runner(pieces[0], i, threadOK[i]));\n threads[i].start();\n /*\n *No need to wait if we just started the last thread.\n */\n if (delay != 0 && i < parallelThreadCount - 1) {\n Thread.currentThread().sleep(delay);\n }\n }\n boolean allThreadsOK = true;\n for (int i = 0; i < parallelThreadCount; i++) {\n Thread t = threads[i];\n t.join(getTimeout());\n allThreadsOK &= threadOK[i].get();\n }\n \n if ( ! allThreadsOK) {\n throw new RuntimeException(\"At least one thread failed\");\n }\n }\n }",
"@Issue(\"JENKINS-38536\")\n @Test\n public void testPartlyCompletedParallels() throws Exception {\n String jobScript = \"\"+\n \"echo 'first stage'\\n\" +\n \"parallel 'long' : { sleep 60; }, \\n\" + // Needs to be in-progress\n \" 'short': { sleep 2; }\"; // Needs to have completed, and SemaphoreStep alone doesn't cut it\n\n // This must be amateur science fiction because the exposition for the setting goes on FOREVER\n ForkScanner scan = new ForkScanner();\n TestVisitor tv = new TestVisitor();\n WorkflowJob job = r.jenkins.createProject(WorkflowJob.class, \"parallelTimes\");\n job.setDefinition(new CpsFlowDefinition(jobScript, true));\n WorkflowRun run = job.scheduleBuild2(0).getStartCondition().get();\n Thread.sleep(4000); // Allows enough time for the shorter branch to finish and write its BlockEndNode\n FlowExecution exec = run.getExecution();\n List<FlowNode> heads = exec.getCurrentHeads();\n scan.setup(heads);\n scan.visitSimpleChunks(tv, new NoOpChunkFinder());\n FlowNode endNode = exec.getNode(tv.filteredCallsByType(TestVisitor.CallType.PARALLEL_END).get(0).getNodeId().toString());\n Assert.assertEquals(\"sleep\", endNode.getDisplayFunctionName());\n sanityTestIterationAndVisiter(heads);\n run.doKill(); // Avoid waiting for long branch completion\n }",
"public static void main(String[] args) {\n\t\tint[] longArr = new int[1000];\n\t\tlong startTime = System.currentTimeMillis();\n\t\tparallelAssignValues(longArr);\n\t\tlong endTime = System.currentTimeMillis();\n\t\tSystem.out.println(\"parallel method time is: \" + (endTime - startTime));\n\n\t\t// for (int i = 0; i < longArr.length; i++) {\n\t\t// System.out.print(longArr[i]);\n\t\t// }\n\n\t\tRandom random = new Random();\n\t\tint[] lista = new int[1000];\n\t\tlong startTimes = System.currentTimeMillis();\n\t\tfor (int i = 0; i < 1000; i++) {\n\t\t\tlista[i] = random.nextInt(500);\n\t\t}\n\t\tlong endTimes = System.currentTimeMillis();\n\t\tSystem.out.println(\"serial method time is: \" + (endTimes - startTimes));\n\n\t}",
"public void testExplicitGcAnalsysisParallelSerialOld() {\n // TODO: Create File in platform independent way.\n File testFile = new File(\"src/test/data/dataset56.txt\");\n GcManager gcManager = new GcManager();\n File preprocessedFile = gcManager.preprocess(testFile, null);\n gcManager.store(preprocessedFile, false);\n JvmRun jvmRun = gcManager.getJvmRun(new Jvm(null, null), Constants.DEFAULT_BOTTLENECK_THROUGHPUT_THRESHOLD);\n Assert.assertEquals(\"Event type count not correct.\", 2, jvmRun.getEventTypes().size());\n Assert.assertTrue(JdkUtil.LogEventType.PARALLEL_SCAVENGE.toString() + \" collector not identified.\",\n jvmRun.getEventTypes().contains(LogEventType.PARALLEL_SCAVENGE));\n Assert.assertTrue(JdkUtil.LogEventType.PARALLEL_SERIAL_OLD.toString() + \" collector not identified.\",\n jvmRun.getEventTypes().contains(LogEventType.PARALLEL_SERIAL_OLD));\n Assert.assertTrue(Analysis.WARN_EXPLICIT_GC_SERIAL_PARALLEL + \" analysis not identified.\",\n jvmRun.getAnalysis().contains(Analysis.WARN_EXPLICIT_GC_SERIAL_PARALLEL));\n Assert.assertTrue(Analysis.ERROR_SERIAL_GC_PARALLEL + \" analysis not identified.\",\n jvmRun.getAnalysis().contains(Analysis.ERROR_SERIAL_GC_PARALLEL));\n }",
"public static void main(String[] args) throws InterruptedException {\n\t\tThreadPoolExecutor executor = (ThreadPoolExecutor) Executors.newFixedThreadPool(3);\n\t\tint numPaletes = 5, ti, te, numMaons = 10;\n\t\t\n\t\t//instanciem els paletes\n\t\tPaletaP[] P = new PaletaP[numPaletes];\n\t\t\t\t\t\t\n\t\t//comencem a contar el temps\n\t\tti = (int) System.currentTimeMillis();\n\t\t//Donem nom als paletes i els posem a fer fer la paret\n\t\tfor (int i=0;i<numPaletes;i++) {\n\t\t\tP[i] = new PaletaP(\"Paleta-\"+i,numMaons);\n\t\t\texecutor.execute(P[i]);\n\t\t}\n\n\t\texecutor.shutdown();\n\t\texecutor.awaitTermination(Long.MAX_VALUE, TimeUnit.SECONDS);\n\t\t/*while (!executor.isTerminated()) {\n\t\t}*/\n\n\t\t//Han acabat i agafem el temps final\n\t\tte = (int) System.currentTimeMillis();\n\t\t\t\t\n\t\tSystem.out.println(\"Han trigat: \" + (te - ti)/1000 + \" segons\");\n\t\t\n\t}",
"@Test\n public void testParallelStressSingleThreadMultipleWorkersJitEnabled() throws Exception {\n Assume.assumeTrue(JitUtil.isJitSupported());\n\n testParallelStress(queryNoLimit, expectedNoLimit, 4, 1, SqlJitMode.JIT_MODE_ENABLED);\n }",
"@Test\n public void multipleProducerScenarioTest() throws InterruptedException, JsonProcessingException, ExecutionException {\n\n //Create list of chunk for producer 1\n ObjectMapper objectMapper = new ObjectMapper();\n List<Chunk> chunkList1 = new ArrayList<>();\n Chunk chunk = new Chunk();\n chunk.setData(Arrays.asList(objectMapper.readValue(\"{\\\"id\\\":\\\"1\\\", \\\"asOf\\\":\\\"2021-09-07T21:26:57.202898400\\\", \\\"payload\\\":{\\\"Price\\\":20.139961889377744}}\", Record.class),\n objectMapper.readValue(\"{\\\"id\\\":\\\"2\\\", \\\"asOf\\\":\\\"2021-09-07T09:26:57.265399700\\\", \\\"payload\\\":{\\\"Price\\\":70.14384608537513}}\", Record.class)));\n chunkList1.add(chunk);\n ExecutorService executorService = Executors.newFixedThreadPool(2);\n ProducerThread producerThread1 = new ProducerThread(\"Producer1\", chunkList1, 10, new ApplicationService());\n\n Future<String> producerResult = executorService.submit(producerThread1);\n while (true) {\n if (producerResult.isDone())\n break;\n }\n\n //Once the producer 1 is done with the batch run, producer 2 starts the batch run\n if (ProducerConstants.BATCH_COMPLETION_MESSAGE.equals(producerResult.get())) {\n List<Chunk> chunkList2 = new ArrayList<>();\n chunk.setData(Arrays.asList(objectMapper.readValue(\"{\\\"id\\\":\\\"1\\\", \\\"asOf\\\":\\\"2021-09-07T21:55:57.265399700\\\", \\\"payload\\\":{\\\"Price\\\":98.12933222921298}}\", Record.class),\n objectMapper.readValue(\"{\\\"id\\\":\\\"2\\\", \\\"asOf\\\":\\\"2021-09-06T10:26:57.265399700\\\", \\\"payload\\\":{\\\"Price\\\":31.54355122981366}}\", Record.class)));\n chunkList2.add(chunk);\n ProducerThread producerThread2 = new ProducerThread(\"Producer2\", chunkList2, 10, new ApplicationService());\n\n producerResult = executorService.submit(producerThread2);\n while (true) {\n if (producerResult.isDone())\n break;\n }\n\n //Once producer 2 is also done with the batch , then start 2 consumer threads to access the instrument id value.\n if (ProducerConstants.BATCH_COMPLETION_MESSAGE.equals(producerResult.get())) {\n Future<String> priceFromConsumer1 = executorService.submit(new ConsumerThread(\"Consumer1\", 1, new ApplicationService()));\n Future<String> priceFromConsumer2 = executorService.submit(new ConsumerThread(\"Consumer2\", 2, new ApplicationService()));\n\n assertEquals(\"98.12933222921298\", priceFromConsumer1.get());\n assertEquals(\"70.14384608537513\", priceFromConsumer2.get());\n }\n }\n\n executorService.shutdown();\n\n }",
"@Test\n public void AppProcNumError() {\n try{\n App.main(new String[]{TEST_PATH + \"input.dot\",\"yes\"});\n }catch(RuntimeException re){\n assertEquals(re.getMessage(),\"Invalid number of processors\");\n }\n }",
"public static void main(String[] args) {\n\n ConcurrentHashMap h = new ConcurrentHashMap();\n\n for (int i = 0; i < 100; i++) {\n new MTest(h).start();\n }\n }",
"@Test\n public void testParallelPropagationLoopBack3SitesNtoNTopologyPutFromOneDS() {\n Integer lnPort = vm0.invoke(() -> WANTestBase.createFirstLocatorWithDSId(1));\n Integer nyPort = vm1.invoke(() -> WANTestBase.createFirstRemoteLocator(2, lnPort));\n Integer tkPort = vm2.invoke(() -> WANTestBase.createFirstRemoteLocator(3, lnPort));\n\n createCacheInVMs(lnPort, vm3, vm6);\n createCacheInVMs(nyPort, vm4, vm7);\n createCacheInVMs(tkPort, vm5);\n vm3.invoke(WANTestBase::createReceiver);\n vm4.invoke(WANTestBase::createReceiver);\n vm5.invoke(WANTestBase::createReceiver);\n\n // site1\n vm3.invoke(() -> WANTestBase.createSender(\"ln1\", 2, true, 100, 10, false, false, null, true));\n vm6.invoke(() -> WANTestBase.createSender(\"ln1\", 2, true, 100, 10, false, false, null, true));\n\n vm3.invoke(() -> WANTestBase.createSender(\"ln2\", 3, true, 100, 10, false, false, null, true));\n vm6.invoke(() -> WANTestBase.createSender(\"ln2\", 3, true, 100, 10, false, false, null, true));\n\n // site2\n vm4.invoke(() -> WANTestBase.createSender(\"ny1\", 1, true, 100, 10, false, false, null, true));\n vm7.invoke(() -> WANTestBase.createSender(\"ny1\", 1, true, 100, 10, false, false, null, true));\n\n vm4.invoke(() -> WANTestBase.createSender(\"ny2\", 3, true, 100, 10, false, false, null, true));\n vm7.invoke(() -> WANTestBase.createSender(\"ny2\", 3, true, 100, 10, false, false, null, true));\n\n // site3\n vm5.invoke(() -> WANTestBase.createSender(\"tk1\", 1, true, 100, 10, false, false, null, true));\n vm5.invoke(() -> WANTestBase.createSender(\"tk2\", 2, true, 100, 10, false, false, null, true));\n\n // create PR\n vm3.invoke(() -> WANTestBase.createPartitionedRegion(getTestMethodName() + \"_PR\", \"ln1,ln2\", 0,\n 1, isOffHeap()));\n vm6.invoke(() -> WANTestBase.createPartitionedRegion(getTestMethodName() + \"_PR\", \"ln1,ln2\", 0,\n 1, isOffHeap()));\n\n vm4.invoke(() -> WANTestBase.createPartitionedRegion(getTestMethodName() + \"_PR\", \"ny1,ny2\", 0,\n 1, isOffHeap()));\n vm7.invoke(() -> WANTestBase.createPartitionedRegion(getTestMethodName() + \"_PR\", \"ny1,ny2\", 0,\n 1, isOffHeap()));\n\n vm5.invoke(() -> WANTestBase.createPartitionedRegion(getTestMethodName() + \"_PR\", \"tk1,tk2\", 0,\n 1, isOffHeap()));\n\n // start all the senders\n vm3.invoke(() -> WANTestBase.startSender(\"ln1\"));\n vm3.invoke(() -> WANTestBase.startSender(\"ln2\"));\n vm6.invoke(() -> WANTestBase.startSender(\"ln1\"));\n vm6.invoke(() -> WANTestBase.startSender(\"ln2\"));\n\n vm4.invoke(() -> WANTestBase.startSender(\"ny1\"));\n vm4.invoke(() -> WANTestBase.startSender(\"ny2\"));\n vm7.invoke(() -> WANTestBase.startSender(\"ny1\"));\n vm7.invoke(() -> WANTestBase.startSender(\"ny2\"));\n\n vm5.invoke(() -> WANTestBase.startSender(\"tk1\"));\n vm5.invoke(() -> WANTestBase.startSender(\"tk2\"));\n\n // pause senders on all the sites\n vm3.invoke(() -> WANTestBase.pauseSender(\"ln1\"));\n vm3.invoke(() -> WANTestBase.pauseSender(\"ln2\"));\n vm6.invoke(() -> WANTestBase.pauseSender(\"ln1\"));\n vm6.invoke(() -> WANTestBase.pauseSender(\"ln2\"));\n\n vm4.invoke(() -> WANTestBase.pauseSender(\"ny1\"));\n vm4.invoke(() -> WANTestBase.pauseSender(\"ny2\"));\n vm7.invoke(() -> WANTestBase.pauseSender(\"ny1\"));\n vm7.invoke(() -> WANTestBase.pauseSender(\"ny2\"));\n\n vm5.invoke(() -> WANTestBase.pauseSender(\"tk1\"));\n vm5.invoke(() -> WANTestBase.pauseSender(\"tk2\"));\n\n // this is required since sender pause doesn't take effect immediately\n Wait.pause(1000);\n\n // do puts on site1\n vm3.invoke(() -> WANTestBase.doPuts(getTestMethodName() + \"_PR\", 100));\n\n // verify queue size on site1 and site3\n vm3.invoke(() -> WANTestBase.verifyQueueSize(\"ln1\", 100));\n vm3.invoke(() -> WANTestBase.verifyQueueSize(\"ln2\", 100));\n\n // resume sender (from site1 to site2) on site1\n vm3.invoke(() -> WANTestBase.resumeSender(\"ln1\"));\n vm6.invoke(() -> WANTestBase.resumeSender(\"ln1\"));\n\n // validate region size on site2\n vm4.invoke(() -> WANTestBase.validateRegionSize(getTestMethodName() + \"_PR\", 100));\n\n // verify queue size on site2 (sender 2 to 1)\n // should remain at 0 as the events from site1 should not go back to site1\n vm4.invoke(() -> WANTestBase.verifyQueueSize(\"ny1\", 0));\n\n // verify queue size on site2 (sender 2 to 3)\n // should remain at 0 as events from site1 will reach site3 directly..site2 need not send to\n // site3 again\n vm4.invoke(() -> WANTestBase.verifyQueueSize(\"ny2\", 0));\n\n // do more puts on site3\n vm5.invoke(() -> WANTestBase.doPutsFrom(getTestMethodName() + \"_PR\", 100, 200));\n\n // resume sender (from site3 to site2) on site3\n vm5.invoke(() -> WANTestBase.resumeSender(\"tk2\"));\n\n // validate region size on site2\n vm4.invoke(() -> WANTestBase.validateRegionSize(getTestMethodName() + \"_PR\", 200));\n\n // verify queue size on site2 (sender 2 to 3)\n // should remain at 0 as the events from site3 should not go back to site3\n vm4.invoke(() -> WANTestBase.verifyQueueSize(\"ny2\", 0));\n\n // verify queue size on site2 (sender 2 to 1)\n // should remain at 0 as events from site3 will reach site1 directly..site2 need not send to\n // site1 again\n vm4.invoke(() -> WANTestBase.verifyQueueSize(\"ny1\", 0));\n\n // resume all senders\n vm3.invoke(() -> WANTestBase.resumeSender(\"ln2\"));\n vm6.invoke(() -> WANTestBase.resumeSender(\"ln2\"));\n\n vm4.invoke(() -> WANTestBase.resumeSender(\"ny1\"));\n vm4.invoke(() -> WANTestBase.resumeSender(\"ny2\"));\n vm7.invoke(() -> WANTestBase.resumeSender(\"ny1\"));\n vm7.invoke(() -> WANTestBase.resumeSender(\"ny2\"));\n\n vm5.invoke(() -> WANTestBase.resumeSender(\"tk1\"));\n\n // validate region size on all sites\n vm3.invoke(() -> WANTestBase.validateRegionSize(getTestMethodName() + \"_PR\", 200));\n vm4.invoke(() -> WANTestBase.validateRegionSize(getTestMethodName() + \"_PR\", 200));\n vm5.invoke(() -> WANTestBase.validateRegionSize(getTestMethodName() + \"_PR\", 200));\n }",
"@Test\n public void testParallelStressMultipleThreadsMultipleWorkersPositiveLimitJitEnabled() throws Exception {\n Assume.assumeTrue(JitUtil.isJitSupported());\n\n testParallelStress(queryPositiveLimit, expectedPositiveLimit, 4, 4, SqlJitMode.JIT_MODE_ENABLED);\n }",
"public static void main(String[] args) {\n SequenceGenerator generator = new SequenceGenerator();\r\n // init generator consumers\r\n MyThread thread1 = new MyThread(\"th1\", generator);\r\n MyThread thread2 = new MyThread(\"th2\", generator);\r\n MyThread thread3 = new MyThread(\"th3\", generator);\r\n // Start a race for ints from generator\r\n thread1.start();\r\n thread2.start();\r\n thread3.start();\r\n // At last the generated number must be stable\r\n // 3 * MyThread.SEQ_SIZE = 30000\r\n\r\n }",
"public static void main(String[] args) throws Exception \n {\n int numIterations = numSamples / numThreads;\n new Master().doRun(numIterations, numThreads);\n }",
"@Test(timeout = 5000)\n public void concurrentFunctions() {\n final String input = \"input\";\n\n final int size = 100;\n //since we start at index 0\n final int expected = size - 1;\n\n\n // QUESTION Using this thread blocks indefinitely. The execution of the Hystrix command\n // happens on the computation Thread if this is used\n\n // final Scheduler scheduler = Schedulers.threadPoolForComputation();\n\n //use the I/O scheduler to allow enough thread, otherwise our pool will be the same size as the # of cores\n\n\n //set our size equal\n// ConfigurationManager.getConfigInstance().setProperty( THREAD_POOL_SIZE, size );\n // ConfigurationManager.getConfigInstance().setProperty( THREAD_POOL_SIZE, 10 );\n\n //reject requests we have to queue\n// ConfigurationManager.getConfigInstance().setProperty( THREAD_POOL_QUEUE, -1 );\n\n //latch used to make each thread block to prove correctness\n final CountDownLatch latch = new CountDownLatch( size );\n\n\n //create our observable and execute it in the I/O pool since we'll be doing I/O operations\n\n /**\n * QUESTION: Should this use the computation scheduler since all operations (except the hystrix command) are\n * non blocking?\n */\n\n final Observable<String> observable = Observable.just( input ).observeOn( Schedulers.io() );\n\n\n Observable<Integer> thing = observable.flatMap( new Func1<String, Observable<Integer>>() {\n\n @Override\n public Observable<Integer> call( final String s ) {\n List<Observable<Integer>> functions = new ArrayList<Observable<Integer>>();\n\n logger.info( \"Creating new set of observables in thread {}\",\n Thread.currentThread().getName() );\n\n for ( int i = 0; i < size; i++ ) {\n\n\n final int index = i;\n\n // create a new observable and execute the function on it.\n // These should happen in parallel when a subscription occurs\n\n /**\n * QUESTION: Should this again be the process thread, not the I/O\n */\n Observable<String> newObservable = Observable.just( input ).subscribeOn( Schedulers.io() );\n\n Observable<Integer> transformed = newObservable.map( new Func1<String, Integer>() {\n\n @Override\n public Integer call( final String s ) {\n\n final String threadName = Thread.currentThread().getName();\n\n logger.info( \"Invoking parallel task in thread {}\", threadName );\n\n// /**\n// * Simulate a Hystrix command making a call to an external resource. Invokes\n// * the Hystrix command immediately as the function is invoked. This is currently\n// * how we have to call Cassandra.\n// *\n// * TODO This needs to be re-written and evaluated once this PR is released https://github.com/Netflix/Hystrix/pull/209\n// */\n// return new HystrixCommand<Integer>( GROUP_KEY ) {\n// @Override\n// protected Integer run() throws Exception {\n//\n// final String threadName = Thread.currentThread().getName();\n//\n// logger.info( \"Invoking hystrix task in thread {}\", threadName );\n\n\n\n\n latch.countDown();\n\n try {\n latch.await();\n }\n catch ( InterruptedException e ) {\n throw new RuntimeException( \"Interrupted\", e );\n }\n\n// assertTrue( isExecutedInThread() );\n//\n// return index;\n// }\n// }.execute();\n\n return index;\n }\n } );\n\n functions.add( transformed );\n }\n\n /**\n * Execute the functions above and zip the results together\n */\n Observable<Integer> zipped = Observable.zip( functions, new FuncN<Integer>() {\n\n @Override\n public Integer call( final Object... args ) {\n\n logger.info( \"Invoking zip in thread {}\", Thread.currentThread().getName() );\n\n assertEquals( size, args.length );\n\n for ( int i = 0; i < args.length; i++ ) {\n assertEquals( \"Indexes are returned in order\", i, args[i] );\n }\n\n //just return our string\n return ( Integer ) args[args.length - 1];\n }\n } );\n\n return zipped;\n }\n } );\n\n\n final Integer last = thing.toBlocking().last();\n\n\n assertEquals( expected, last.intValue() );\n\n\n }",
"@Test\n public void Day5AExample1() {\n intCodeProcessorService = new IntCodeProcessorService(\"data/day05/example1.txt\");\n intCodeProcessorService.setCpuInputValue(555L);\n intCodeProcessorService.runToCompletion();\n\n long result = intCodeProcessorService.getProgramOutput();\n Assert.assertEquals(555L, result);\n }",
"public static void main(String[] args) throws InstantiationException, IllegalAccessException, ClassNotFoundException, SQLException {\n\r\n\t\tfor (int ratio = 100; ratio <= 300; ratio+=100) {\r\n\t\t\tfor (int stopMinutes = 15; stopMinutes <= 60; stopMinutes+=15) {\r\n\t\t\t\tunknownPOIs(ratio, stopMinutes, false);\r\n\t\t\t}\r\n\t\t}\r\n\t\t\r\n\t}",
"public static void main(String[] args) {\n MPI.Init(args);\n CollectiveMultiplication(args, false, 2500);\n MPI.Finalize();\n// int[] matrixSizes = {200, 400, 600, 800, 1000};\n// double[] serialResults = new double[matrixSizes.length];\n// for (int i=0; i<matrixSizes.length; i++){\n// ArrayList<Double> results = new ArrayList<>();\n// for (int j=0; j<4; j++){\n// results.add(serial(matrixSizes[i]));\n// }\n// serialResults[i] = results.stream().mapToDouble(a -> a).sum() / results.size();\n// } \n// for (double result: serialResults)\n// System.out.println(result);\n }",
"public static void main (String[] args){\r\n\t\tint num_threads = 100;\r\n\t\tpid_manager pid_test = new pid_manager();\r\n\t\tSystem.out.println(\"Ready \\n\");\r\n\t\tpid_test.allocate_map();\r\n\t\tfor(int i = 0; i < num_threads; i++){\r\n\t\t\tThread rc = new Thread(new mthread(pid_test));\r\n\t\t\trc.start();\r\n\t}\r\n}",
"public static void main(String[] args) {\n\t\tfor(int i=0; i<5; i++)\n\t\t{\n\t\t\tnew Thread(new DaytimeClientMulti(args)).start();\n\t\t}\n\n\t}",
"public static void main(String[] args) {\n\t\tfinal JobStream rootJobStream = new SerialJobStream(\"1\");\n\t\t// final JobStream rootJobStream = new ParallelJobStream(\"1\");\n\n\t\tfinal JobStream rootChild1 = new SerialJobStream(\"2\");\n\n\t\trootChild1.addJob(new Job(\"3\") {\n\t\t\t@Override\n\t\t\tpublic void process(Date tick, Object data) {\n\t\t\t\tsetJobSuccessful(null);\n\t\t\t}\n\t\t});\n\n\t\trootChild1.addJob(new Job(\"4\") {\n\t\t\t@Override\n\t\t\tpublic void process(Date tick, Object data) {\n\t\t\t\tsetJobSuccessful(null);\n\t\t\t}\n\t\t});\n\n\t\trootChild1.addJob(new Job(\"5\") {\n\t\t\t@Override\n\t\t\tpublic void process(Date tick, Object data) {\n\t\t\t\tsetJobSuccessful(null);\n\t\t\t}\n\t\t});\n\n\t\tfinal JobStream rootChild2 = new SerialJobStream(\"6\");\n\n\t\trootChild2.addJob(new Job(\"7\") {\n\t\t\t@Override\n\t\t\tpublic void process(Date tick, Object data) {\n\t\t\t\tsetJobSuccessful(null);\n\t\t\t}\n\t\t});\n\n\t\trootChild2.addJob(new Job(\"8\") {\n\t\t\t@Override\n\t\t\tpublic void process(Date tick, Object data) {\n\t\t\t\tsetJobSuccessful(null);\n\t\t\t}\n\t\t});\n\n\t\trootChild2.addJob(new Job(\"9\") {\n\t\t\t@Override\n\t\t\tpublic void process(Date tick, Object data) {\n\t\t\t\tsetJobSuccessful(null);\n\t\t\t}\n\t\t});\n\n\t\t// Add child job streams to root\n\t\trootJobStream.addJob(rootChild1);\n\t\trootChild1.addJob(rootChild2);\n\n\t\t// Start the runner\n\t\tfinal JobStreamRunner runnner = new JobStreamRunner(rootJobStream);\n\t\trunnner.start();\n\t}",
"public static void main(String[] args) {\n ThreadPoolExecutor executor = new ThreadPoolExecutor(7, 8, 5, TimeUnit.SECONDS,\r\n new LinkedBlockingQueue<Runnable>());\r\n System.out.println(executor.getCorePoolSize());\r\n System.out.println(executor.getMaximumPoolSize());\r\n System.out.println(\"***************************\");\r\n ThreadPoolExecutor executor2 = new ThreadPoolExecutor(7, 8, 5, TimeUnit.SECONDS,\r\n new SynchronousQueue<Runnable>());\r\n System.out.println(executor2.getCorePoolSize());\r\n System.out.println(executor2.getMaximumPoolSize());\r\n\r\n// 7\r\n// 8\r\n// ***************************\r\n// 7\r\n// 8\r\n\r\n // 熟悉下api,查询线程池中保存的core线程数量为7,最大为8\r\n }",
"public static void test_3a(){\r\n try{\r\n System.out.println(\"\\n\\nTestCase-3A\\n\\n\");\r\n TestNetwork n=new TestNetwork(4,4,2);\r\n Paxos p=new Paxos(n);\r\n p.runPaxos();\r\n n.change_DPmode(-1,1);\r\n for(int i=0;i<10;i++) //Block the channel of all processes\r\n n.block_channel(i, 1); \r\n Thread.sleep(500);\r\n for(int i=0;i<4;i++) //Release all Proposers\r\n n.block_channel(i,0); \r\n Thread.sleep(1000);\r\n for(int i=0;i<9;i++) //Shuffling all message queues\r\n n.shuffle_msg(i);\r\n for(int i=4;i<8;i++) //Release all Acceptors\r\n n.block_channel(i,0);\r\n Thread.sleep(1000);\r\n n.block_channel(9,0); //Release one of the learner's channel\r\n Thread.sleep(1000); \r\n n.block_channel(8,0); //Lets release the next learner's channel\r\n Thread.sleep(5000);\r\n n.terminate_run();\r\n Thread.sleep(2000);\r\n System.out.println(\"\\n\\nTERMINATED PAXOS RUN-3A\");\r\n n.printTrace();\r\n }\r\n catch(Exception e){}\r\n}",
"public static void main(String[] args){\n\t\tint tamPool=Integer.parseInt(args[0]);\r\n\t\tSystem.out.println(\"Cuantos numero quiere lanzar?\");\r\n\t\tn=Integer.parseInt(args[1]);\r\n\t\tlong time_start, time_end;\r\n\t\tint numeros=n/tamPool;\r\n\t\tThread []hilos= new Thread[tamPool];\r\n\t\ttime_start = System.currentTimeMillis();\r\n\t\t//System.out.println(\"Numeros: \"+numeros);\r\n\t\tint grueso=numeros;\r\n\t\t\t//ExecutorService exec = Executors.newCachedThreadPool();\r\n\t\t\tfor(int i=0;i<tamPool;++i){\r\n\t\t\t\thilos[i]= new Thread(new piParalelo(numeros));\r\n\t\t\t\thilos[i].start();\r\n\t\t\t//System.out.println(i+\" : \"+grueso);\r\n\t\t\t//exec.execute(new piParalelo(numeros));\r\n\t\t\tif((grueso+numeros)>=n)numeros=n-grueso;\r\n\t\t\telse grueso+=numeros;\r\n\r\n\t\t\t\t\t\t\t\t\t\t\t}\r\n\t\t\tfor(int i=0;i<tamPool;++i){\r\n\t\t\t\ttry{\r\n\t\t\t\thilos[i].join();\r\n\t\t\t\t}catch(Exception e){}\r\n\t\t\t\t\t\t\t\t\t\t}\r\n\t\t\t/**try{\r\n\t\t\texec.shutdown();\r\n\t\t\texec.awaitTermination(1, TimeUnit.DAYS);\r\n\t\t\t}catch(Exception e){}*/\r\n\t\tPI=4*((double)atomico.get()/(double)n);\r\n\t\tSystem.out.println(\"La aproximacion del numero PI por montecarlo es: \"+PI);\r\n\t\ttime_end = System.currentTimeMillis();\r\n\t\tSystem.out.println(\"the task has taken \"+ ( time_end - time_start ) +\" milliseconds\");\r\n\t\t\t\t\t\t\t}",
"public static void main(String[] args) {\n// printTO1Million(2);\n printTO1Million(3);\n }",
"public static void main(String[] args) {\n long maxPrime = (long)Math.pow(2,20) - 1;\n\n // PrimeCross pp = new PrimeCross(maxPrime); //With cross 3, 5, 7\n Prime pp = new PrimeParallel(maxPrime);\n\n double time = System.nanoTime();\n pp.findPrimes();\n time = (System.nanoTime() - time) / 1000000; //milliseconds\n\n System.out.println(\"Time used to find primes: \" + time + \" ms.\");\n\n\n pp.print(); // Prints some of the last primes\n // pp.write(\"eratosthenes.txt\");\n\n System.out.println(\"\\n\\n---------------------------------------\");\n System.out.println(\"Gaps:\\n\");\n\n findGapsWithEratosthenes(pp);\n // findPrimesDivision(pp);\n // findGapDivision(pp);\n }",
"@Test(timeout = TIMEOUT)\n public void convertFileTaskLifecycle() throws Exception {\n final Result<TaskResponse> uploadImportTaskResponseResult = docSDKClient.importUsing().upload(new UploadImportRequest(), jpgTest1InputStream);\n assertThat(uploadImportTaskResponseResult.getStatus()).isEqualTo(HttpStatus.SC_OK);\n\n final TaskResponse uploadImportTaskResponse = uploadImportTaskResponseResult.getBody();\n assertThat(uploadImportTaskResponse.getOperation()).isEqualTo(Operation.IMPORT_UPLOAD);\n\n // List convert formats\n final Result<Pageable<OperationResponse>> convertFormatsOperationResponsePageableResult = docSDKClient.tasks().convertFormats();\n assertThat(convertFormatsOperationResponsePageableResult.getStatus()).isEqualTo(HttpStatus.SC_OK);\n\n final List<OperationResponse> operationResponses = convertFormatsOperationResponsePageableResult.getBody().getData();\n assertThat(operationResponses).anySatisfy(operationResponse -> assertThat(operationResponse.getOutputFormat()).isEqualTo(JPG));\n\n // Convert\n final ConvertFilesTaskRequest convertFilesTaskRequest = new ConvertFilesTaskRequest().setInput(uploadImportTaskResponse.getId()).setInputFormat(JPG).setOutputFormat(PNG);\n final Result<TaskResponse> convertTaskResponseResult = docSDKClient.tasks().convert(convertFilesTaskRequest);\n assertThat(convertTaskResponseResult.getStatus()).isEqualTo(HttpStatus.SC_CREATED);\n\n final TaskResponse convertTaskResponse = convertTaskResponseResult.getBody();\n assertThat(convertTaskResponse.getOperation()).isEqualTo(Operation.CONVERT);\n\n // Wait\n final Result<TaskResponse> waitConvertTaskResponseResult = docSDKClient.tasks().wait(convertTaskResponse.getId());\n assertThat(waitConvertTaskResponseResult.getStatus()).isEqualTo(HttpStatus.SC_OK);\n\n final TaskResponse waitConvertTaskResponse = waitConvertTaskResponseResult.getBody();\n assertThat(waitConvertTaskResponse.getOperation()).isEqualTo(Operation.CONVERT);\n assertThat(waitConvertTaskResponse.getStatus()).isEqualTo(Status.FINISHED);\n assertThat(waitConvertTaskResponse.getId()).isEqualTo(convertTaskResponse.getId());\n\n // Show\n final Result<TaskResponse> showConvertTaskResponseResult = docSDKClient.tasks().show(convertTaskResponse.getId());\n assertThat(showConvertTaskResponseResult.getStatus()).isEqualTo(HttpStatus.SC_OK);\n\n final TaskResponse showConvertTaskResponse = showConvertTaskResponseResult.getBody();\n assertThat(showConvertTaskResponse.getOperation()).isEqualTo(Operation.CONVERT);\n assertThat(showConvertTaskResponse.getStatus()).isEqualTo(Status.FINISHED);\n assertThat(showConvertTaskResponse.getId()).isEqualTo(convertTaskResponse.getId());\n\n // Delete\n final Result<Void> deleteVoidResult = docSDKClient.tasks().delete(convertTaskResponse.getId());\n assertThat(deleteVoidResult.getStatus()).isEqualTo(HttpStatus.SC_NO_CONTENT);\n }",
"public void testSummaryStatsParallel() {\n File testFile = new File(\"src/test/data/dataset1.txt\");\n GcManager gcManager = new GcManager();\n gcManager.store(testFile, false);\n JvmRun jvmRun = gcManager.getJvmRun(new Jvm(null, null), Constants.DEFAULT_BOTTLENECK_THROUGHPUT_THRESHOLD);\n Assert.assertEquals(\"Max young space not calculated correctly.\", 248192, jvmRun.getMaxYoungSpace());\n Assert.assertEquals(\"Max old space not calculated correctly.\", 786432, jvmRun.getMaxOldSpace());\n Assert.assertEquals(\"NewRatio not calculated correctly.\", 3, jvmRun.getNewRatio());\n Assert.assertEquals(\"Max heap space not calculated correctly.\", 1034624, jvmRun.getMaxHeapSpace());\n Assert.assertEquals(\"Max heap occupancy not calculated correctly.\", 1013058, jvmRun.getMaxHeapOccupancy());\n Assert.assertEquals(\"Max pause not calculated correctly.\", 2782, jvmRun.getMaxGcPause());\n Assert.assertEquals(\"Max perm gen space not calculated correctly.\", 159936, jvmRun.getMaxPermSpace());\n Assert.assertEquals(\"Max perm gen occupancy not calculated correctly.\", 76972, jvmRun.getMaxPermOccupancy());\n Assert.assertEquals(\"Total GC duration not calculated correctly.\", 5614, jvmRun.getTotalGcPause());\n Assert.assertEquals(\"GC Event count not correct.\", 2, jvmRun.getEventTypes().size());\n Assert.assertTrue(JdkUtil.LogEventType.PARALLEL_SCAVENGE.toString() + \" collector not identified.\",\n jvmRun.getEventTypes().contains(LogEventType.PARALLEL_SCAVENGE));\n Assert.assertTrue(JdkUtil.LogEventType.PARALLEL_SERIAL_OLD.toString() + \" collector not identified.\",\n jvmRun.getEventTypes().contains(LogEventType.PARALLEL_SERIAL_OLD));\n Assert.assertTrue(Analysis.WARN_APPLICATION_STOPPED_TIME_MISSING + \" analysis not identified.\",\n jvmRun.getAnalysis().contains(Analysis.WARN_APPLICATION_STOPPED_TIME_MISSING));\n Assert.assertTrue(Analysis.ERROR_SERIAL_GC_PARALLEL + \" analysis not identified.\",\n jvmRun.getAnalysis().contains(Analysis.ERROR_SERIAL_GC_PARALLEL));\n }",
"public static void main(String[] args) {\n\t\t// Number of Threads\n\t\tint numThreads = 1;\n\t\tString threadsStr = System.getProperty(\"threads\");\n\n\t\tif (threadsStr != null) {\n\t\t\tnumThreads = Integer.parseInt(threadsStr);\n\t\t}\n\n\t\t// Run test suite in multiple threads?\n\t\tif (numThreads > 1) {\n\t\t\t// Spawn each thread passing in the Test Suite\n\t\t\tfor (int i = 0; i < numThreads; i++) {\n\t\t\t\tTestThread thread = new TestThread(\"EPPFeeTst Thread \" + i,\n\t\t\t\t\t\tEPPFeeTst.suite());\n\t\t\t\tthread.start();\n\t\t\t}\n\t\t}\n\t\telse { // Single threaded mode.\n\t\t\tjunit.textui.TestRunner.run(EPPFeeTst.suite());\n\t\t}\n\t}",
"public void SampleWindows() {\n \t\tfor (int loop = 0; loop < 10; loop++) {\n \t\t\tJobs jobUnit = new Jobs(\"time /T\", \"Windows\");\n \t\t\tjobqueue.add(jobUnit);\n \t\t}\n \t}",
"public static void main(String[] args) throws InterruptedException {\n\t\tScanner in = new Scanner(System.in);\n\t\tint qntdAssentos = in.nextInt();\n\t\tString nomeArquivo = in.next();\n\t\tin.close();\n\n\t\t// Vetor de assentos\n\t\tAssento assentos[] = criaAssentos(qntdAssentos);\n\n\t\t// Fila com os logs da aplicação a serem impressos(max 10 elementos)\n\t\tQueue<Log> logs = new ArrayBlockingQueue<>(10);\n\n\t\t// quantas threads ja terminaram no programa\n\t\tInteger threadsFinalizadas = 0;\n\n\t\t// Lista de threads\n\t\tList<Thread> produtoras = new ArrayList<>();\n\n\t\t// Cria e Inicia as threads, retorna a thread consumidora\n\t\tThread0 consumidora = criaThreads(produtoras, logs, assentos, threadsFinalizadas, nomeArquivo);\n\n\t\t// Espera pelas produtoras acabarem\n\t\tfor (Thread k : produtoras) {\n\t\t\tk.join();\n\t\t}\n\n\t\t// Acabando, esperamos agora a thread0 acabar\n\t\tconsumidora.setFinish(false);\n\t\tconsumidora.join();\n\n\t}"
] | [
"0.5953333",
"0.5953333",
"0.5953333",
"0.5953333",
"0.5953333",
"0.5953333",
"0.5953333",
"0.59243214",
"0.59243214",
"0.5917014",
"0.5904976",
"0.58982235",
"0.58200526",
"0.56468725",
"0.56282026",
"0.5596976",
"0.55267406",
"0.55260503",
"0.55125153",
"0.54835147",
"0.5459343",
"0.54286027",
"0.54108286",
"0.5376787",
"0.5364157",
"0.5359264",
"0.53382003",
"0.53238106",
"0.5276925",
"0.52722067",
"0.5269841",
"0.52692413",
"0.5247587",
"0.5242495",
"0.5239243",
"0.5222421",
"0.52177405",
"0.52145064",
"0.5210253",
"0.5209611",
"0.5196401",
"0.5189119",
"0.5187973",
"0.5183079",
"0.51727206",
"0.51695544",
"0.5160099",
"0.51536834",
"0.51528883",
"0.5148447",
"0.51435244",
"0.51419437",
"0.5141848",
"0.5140317",
"0.5134028",
"0.5122386",
"0.5122171",
"0.5115998",
"0.5115325",
"0.50971645",
"0.5057455",
"0.50469166",
"0.50431037",
"0.50429314",
"0.5039084",
"0.5033647",
"0.50313544",
"0.5028718",
"0.5020844",
"0.5017278",
"0.5012347",
"0.50069475",
"0.5005901",
"0.50041497",
"0.50041133",
"0.49976233",
"0.49974293",
"0.4993586",
"0.49916425",
"0.4989152",
"0.49890417",
"0.49781913",
"0.49773207",
"0.49732828",
"0.4972916",
"0.49636263",
"0.49601334",
"0.4957323",
"0.49569678",
"0.49564776",
"0.49561307",
"0.4950056",
"0.4947436",
"0.49467424",
"0.49434504",
"0.49412405",
"0.49402514",
"0.49402165",
"0.494003",
"0.49381328"
] | 0.7476774 | 0 |
get the input scanner | public static void main(String[] args)
{
Scanner scan = new Scanner(System.in);
System.out.println("Tileset Spacer by TJ Couch\n");
//if there are no commandline inputs, ask for a file
if (args.length <= 0)
{
System.out.print("Enter the tileset's filename: ");
args = new String[1];
args[0] = scan.nextLine();
}
//get the tile width
System.out.print("Enter the tile width in pixels (Default " + tileWidth + "): ");
String in = scan.nextLine();
if (in != null && !in.isEmpty())
tileWidth = Integer.parseInt(in);
//get the tile height
System.out.print("Enter the tile height in pixels (Default " + tileHeight + "): ");
in = scan.nextLine();
if (in != null && !in.isEmpty())
tileHeight = Integer.parseInt(in);
//get the border size
System.out.print("Enter the border thickness in pixels (Default " + borderSize + "): ");
in = scan.nextLine();
if (in != null && !in.isEmpty())
borderSize = Integer.parseInt(in);
// run program for every file input
for (int f = 0; f < args.length; f++)
{
BufferedImage image = null;
try
{
image = ImageIO.read(new File(args[f]));
System.out.println("Opened " + args[f]);
}
catch (IOException e)
{
System.out.println(e);
}
boolean succeeded = spaceTileSet(image, args[f]);
if (succeeded)
System.out.println("Successfully spaced tileset " + args[f]);
else System.out.println("Did not successfully space tileset " + args[f]);
}
System.out.println("Done.");
scan.close();
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"static InputScanner getInputScanner() {\n return inputScanner;\n }",
"public MyInput() {\r\n\t\tthis.scanner = new Scanner(System.in);\r\n\t}",
"public static String readInput() {\r\n return SCANNER.nextLine();\r\n }",
"private Scanner getInput(String name) {\n try {\n return new Scanner(new File(name));\n } catch (IOException excp) {\n throw error(\"could not open %s\", name);\n }\n }",
"public Scanner getScanner(){\n\t\t\n\t\tboolean hasFile = false;\n\t\tString filename = \"\";\n\t\tfor(int i = 0; i<argList.size(); i++ ){\n\t\t\tif(argList.get(i).equals(\"-f\")){\n\t\t\t\thasFile = true;\n\t\t\t\tfilename = argList.get(i+1);\n\t\t\t}\n\t\t}\n\t\tSystem.out.println(System.getProperty(\"user.dir\") + \" ... \" + filename);\n\t\tFile file = new File(System.getProperty(\"user.dir\")+\"\\\\ARM230Compiler\\\\InputOutputFolder\\\\\", filename);\n\t\tScanner toReturn = null;\n\t\ttry {\n\t\t\ttoReturn = new Scanner(file);\n\t\t} catch (FileNotFoundException e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t}\n\t\treturn toReturn;\n\t}",
"String readInput() {\n Scanner scanner = new Scanner(System.in);\n return scanner.nextLine();\n }",
"public static String GetInput() {\r\n\t\t// Scanner is created and a value is set for input\r\n\t\tScanner in = new Scanner(System.in);\r\n\t\tString input = in.nextLine();\r\n\t\treturn input;\r\n\r\n\t}",
"public Scanner getScanner(){\n\t\t\n\t\tString filename = \"\";\n\t\tfor(int i = 0; i<argList.size(); i++ ){\n\t\t\tif(argList.get(i).equals(\"-f\")){\n\t\t\t\tfilename = argList.get(i+1);\n\t\t\t\t//DIFFERENT FROM OTHER INIT FILE!\n\t\t\t\tfilename = filename.trim().replace(\".s230\", \".S230\");\n\t\t\t}\n\t\t}\n\t\tSystem.out.println(System.getProperty(\"user.dir\") + \" ... \" + filename);\n\t\tString dirName = System.getProperty(\"user.dir\");\n\t\tdirName = dirName.replace(\"\\\\Program_Files\\\\source\",\"\\\\\").trim();\n\t\tdirName = dirName.replace(\"\\\\Program_Files\\\\classes\",\"\\\\\").trim();\n\t\tdirName = dirName.concat(\"\\\\InputOutputFolder\\\\\");\n\t\tSystem.out.println(dirName+filename);\n\t\tFile file = new File(dirName, filename);\n\t\tScanner toReturn = null;\n\t\ttry {\n\t\t\ttoReturn = new Scanner(file);\n\t\t} catch (FileNotFoundException e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t}\n\t\treturn toReturn;\n\t}",
"private static Scanner determineInputSource(String[] args) throws FileNotFoundException{\n if (args.length > 0) {\n //Reading from file\n return new Scanner(new File(args[0]));\n }\n else {\n //Reading from standard Input\n return new Scanner(System.in);\n }\n }",
"public static void setInputScanner(InputScanner scanner){\n inputScanner = scanner;\n }",
"@Override\n\tpublic Scanner getScanner() {\n\t\treturn this.scan;\n\t}",
"public String Get_Input()throws IOException{\r\n\t\tString input=\"\";\r\n\t\tInputStreamReader converter = new InputStreamReader(System.in);\r\n\t\tBufferedReader in = new BufferedReader(converter);\r\n\t\t\r\n\t\tinput = in.readLine();\r\n\t\t\r\n\t\treturn input;\r\n\t}",
"private static void scan() {\n\t\tt = la;\n\t\tla = Scanner.next();\n\t\tla.toString();\n\t\tsym = la.kind;\n\t}",
"public void getPlayerInput() {\n System.out.println(\"Enter a Command: \");\n playerInput = inputScanner.nextLine();\n }",
"public InputReader() {\n reader = new Scanner(System.in);\n }",
"public static void init() {\n\t\tscanner = new Scanner(System.in);\n\t\treturn;\n\t}",
"public void getGamerInput() {\n\t\ttry {\n\t\t\tsCurrentCharInput = String.format(\"%s\", (consoleInput.readLine())).toUpperCase(Locale.getDefault());\n\t\t} catch (Exception e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t}\n\t\t/* ************************************* */\n\t\tconsoleLog.println(\" \");\n\t\t// System.out.println(\" Quit readline \");\n\t\t/* ************************************* */\n\t\t// if (sCurrentCharInput.length() == 0)\n\t\t// continue;\n\n\t\t// if (sCurrentCharInput.contains(sAskedWord))\n\t\t// continue;\n\n\t}",
"private static String[] collectInput() {\n\t\tString command = sc.next();\n\t\tString i = sc.next();\n\t\tString destination = sc.next();\n\t\treturn new String[] { command, destination };\n\t\t\n\t}",
"public Ui() {\n this.scanner = new Scanner(System.in);\n }",
"public Ui() {\n this.scanner = new Scanner(System.in);\n }",
"private String getUserInput(Scanner sc) {\n\t\t\n\t\tif (sc == null) {\n\t\t\treturn null;\n\t\t}\n\n\t System.out.print(\"\\nctransfer > \");\n\t return sc.nextLine();\n\t}",
"private void start() {\n Scanner scanner = new Scanner(System.in);\n \n // While there is input, read line and parse it.\n String input = scanner.nextLine();\n TokenList parsedTokens = readTokens(input);\n }",
"public String userCommand(){\n return scanner.nextLine();\n }",
"public ContentScanner getScanner(\n )\n {return scanner;}",
"public static String readUserInput() {\n return in.nextLine();\n }",
"protected String getInput() {\n if (input.hasNext()) {\n return input.nextLine();\n }\n return getInput();\n }",
"String getInput();",
"public static String getStringInput() {\n Scanner in = new Scanner(System.in);\n return in.next();\n }",
"private int getInput()\n {\n int input = 0;\n Scanner scanner = new Scanner(System.in);\n\n try {\n input = scanner.nextInt();\n }\n catch(Exception e) {\n System.out.println(\"Vælg et tal fra menuen.\");\n scanner.nextLine();\n }\n\n return input;\n }",
"private static void readInput() { input = sc.nextLine().toLowerCase().toCharArray(); }",
"public void input(Scanner in) { \r\n if (in.hasNext()) firstName = in.next();\r\n if (in.hasNext()) lastName = in.next();\r\n\t}",
"Input getInputs();",
"@Override\n\tpublic String read() \n\t{\n\t\tString res = \"\";\n\t\tScanner scan = new Scanner(System.in);\n\t\t\n\t\tif (scan.hasNextLine())\n\t\t\tres = scan.nextLine();\n\t\t\n\t\treturn res;\n\t\t\n\n\t}",
"private String getInput(String prompt) throws IOException {\n System.out.print(prompt);\n BufferedReader in = new BufferedReader(\n new InputStreamReader(System.in));\n return in.readLine();\n }",
"void scanner() {\r\n\t\tSystem.out.println(\"---------- Scanner\" + ++exampleNumber\r\n\t\t\t\t+ \"----------\");\r\n\r\n\t\tString source = \"asdqw easd casa\";\r\n\t\tScanner s1 = new Scanner(source);\r\n\t\t// hasNext() - testuje wartosc kolejnego tokena, ale go nie pobiera\r\n\t\t// next() - pobiera kolejny token\r\n\t\t// domyslnie bialy znak jest delimiterem\r\n\t\twhile (s1.hasNext()) {\r\n\t\t\tSystem.out.println(s1.next());\r\n\t\t}\r\n\r\n\t\tSystem.out.println(\"---------- Scanner\" + ++exampleNumber\r\n\t\t\t\t+ \"----------\");\r\n\r\n\t\t// hasNextXxx() - dla wszystkich primitives oprocz chara\r\n\t\t// nextXxx() - pobiera kolejny prymitywny token\r\n\t\tScanner s2 = new Scanner(\"1 true 34 hi\");\r\n\t\tboolean b;\r\n\t\twhile (b = s2.hasNext()) {\r\n\t\t\tif (s2.hasNextInt()) {\r\n\t\t\t\tint i = s2.nextInt();\r\n\t\t\t\tSystem.out.println(\"integer token: \" + i);\r\n\t\t\t} else if (s2.hasNextBoolean()) {\r\n\t\t\t\tboolean b2 = s2.nextBoolean();\r\n\t\t\t\tSystem.out.println(\"boolean token: \" + b2);\r\n\t\t\t} else {\r\n\t\t\t\tString str = s2.next();\r\n\t\t\t\tSystem.out.println(\"String token: \" + str);\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tSystem.out.println(\"---------- Scanner\" + ++exampleNumber\r\n\t\t\t\t+ \"----------\");\r\n\r\n\t\t// useDelimiter(delimiter) - ustawienie delimitera (wyrazenia regularnego) wg ktorego bedzie przetwarzany strumien\r\n\t\t// domyslnym delimiterem jest spacja, tabulator, ogolnie bialy znak lub znaki\r\n\t\tScanner s3 = new Scanner(\"Test1 true 34 hi\");\r\n\t\ts3.useDelimiter(\"\\\\d\"); // delimiterem jest cyfra\r\n\t\twhile (s3.hasNext()) {\r\n\t\t\tSystem.out.println(s3.next());\r\n\t\t}\r\n\t}",
"public WrongInputDataInScanner() {\n\tsuper();\n\t\n}",
"public java_cup.runtime.Symbol scan()\n throws java.lang.Exception\n {\n return getScanner().next_token(); \n }",
"public Menu() {\n scanner = new Scanner(System.in);\n }",
"public void getInput(){\n\t\tScanner scan= new Scanner(System.in);\n\t\t//Get the range\n\t\tif(scan.hasNext()){\n\t\t\tcount=Integer.parseInt(scan.nextLine()); \n\t\t}\n\t\t//Initialize the array\n\t\tpeople = new People[count];\n\t\t//Get the array elements\n\t\tint i=0;\n\t\twhile(i<count){\n\t\t\tString lin[] = scan.nextLine().split(\" \");\n\t\t\tpeople[i] = new People(Integer.parseInt(lin[0]), Double.parseDouble(lin[1]));\n\t\t\ti++;\n\t\t}\n\t\t\n\t\t\n\t}",
"String getUserInput();",
"private void getInput() {\n\t\tScanner scan = new Scanner(System.in);\r\n\t\tSystem.out.println(\"Enter a number\");\r\n\t\tn=scan.nextInt();\r\n\r\n\t}",
"public static String getInput() {\n\t\tScanner inputReader = new Scanner(System.in);\n\t\tString userInput;\n\t\tuserInput = inputReader.nextLine();\n\t\treturn userInput;\n\t}",
"private static String getUserInput(String prompt){ \r\n Scanner in = new Scanner(System.in);\r\n System.out.print(prompt);\r\n return in.nextLine();\r\n }",
"public static String inputStringFromKeyboard(String input){\n System.out.println(\"Input the String: \");\n //Scanner, save the inputted from keyboard\n Scanner scanner = new Scanner(System.in);\n //The value 'scanner' is assigned to 'input'\n input = scanner.next();\n return input;\n }",
"public void inputScanner(){\n\t\t Scanner sc=new Scanner(System.in); \n\t \n\t\t System.out.println(\"Enter your rollno\"); \n\t\t int rollno=sc.nextInt(); \n\t\t System.out.println(\"Enter your name\"); \n\t\t String name=sc.next(); \n\t\t System.out.println(\"Enter your fee\"); \n\t\t double fee=sc.nextDouble(); \n\t\t System.out.println(\"Rollno:\"+rollno+\" name:\"+name+\" fee:\"+fee); \n\t\t sc.close(); \n\t}",
"public String getUserInput(String question) {\r\n System.out.print(question);\r\n return scanner.next();\r\n }",
"public Scanner(java.io.InputStream in) {\r\n this(new java.io.InputStreamReader(in));\r\n }",
"private String readNextCommand(Scanner scanner) {\n // set the current thread\n this.currentThread.set(Thread.currentThread());\n\n String nextCommand;\n try {\n // read next line\n nextCommand = scanner.nextLine().trim();\n } finally {\n // terminate this thread\n this.currentThread.set(null);\n }\n\n return nextCommand;\n }",
"public Scanner(java.io.Reader in) {\r\n this.zzReader = in;\r\n }",
"public String getInput() throws IOException {\n\t\tSystem.out.print(\">> \");\n\t\treturn consoleIn.readLine();\n\t}",
"public Ch12Ex1to9()\n {\n scan = new Scanner( System.in );\n }",
"public static String getString(){\n Scanner in = new Scanner(System.in); //scanner variable to take input\n return in.nextLine().trim();\n }",
"public String getInputForName() {\n\t\twhile (true) {\n\t\t\ttry {\n\t\t\t\treturn bufferedReader.readLine();\n\t\t\t}\n\t\t\tcatch (Exception e) {\n\t\t\t\tSystem.err.println(e.getLocalizedMessage());\n\t\t\t}\n\t\t}\n\t}",
"public String readCommand() {\n sc = new Scanner(System.in);\n userInput = new TextField();\n return userInput.getText();\n }",
"public Scanner(java.io.Reader in) {\n this.zzReader = in;\n }",
"public Scanner(java.io.Reader in) {\n this.zzReader = in;\n }",
"public UserInput()\n {\n try\n {\n scanner = new Scanner(System.in);\n input = new InputMethods();\n citiesTotal = new CityContainer();\n\n if(scanner != null)\n {\n askUser();\n }\n } catch(Exception ex)\n {\n }\n }",
"private ConsoleScanner() {}",
"public static String inputCommand() {\n String command;\n Scanner in = new Scanner(System.in);\n\n command = in.nextLine();\n\n return command;\n }",
"public String getUserInput() {\n\t\tString input;\n\t\tinput = this.console.next();\n\t\treturn input;\n\t}",
"protected String getInputFromConsole() throws IOException\n {\n BufferedReader consoleInput = new BufferedReader(new InputStreamReader(System.in));\n return consoleInput.readLine();\n }",
"private static String scan(String text)\r\n\t{\r\n\t\tSystem.out.print(text);\r\n\t\treturn input.nextLine();\r\n\t}",
"private int nextPick(Scanner scanner) {\n String input = scanner.nextLine();\n try {\n int result = Integer.parseInt(input);\n return result;\n } catch (Exception e) {\n System.out.println(\"Enter a number from the menu.\");\n return -1;\n }\n\n }",
"public Scanner(java.io.InputStream in) {\n this(new java.io.InputStreamReader(in));\n }",
"public Scanner(java.io.InputStream in) {\n this(new java.io.InputStreamReader(in));\n }",
"public static Input getInput() {\r\n return input;\r\n }",
"public In(){\n\t\tscanner=new Scanner(new BufferedInputStream(System.in),CHARSET_NAME);\n\t\tscanner.useLocale(LOCALE);\n\t}",
"OutputStream getStdin();",
"private String getClientInput() {\n BufferedReader br = new BufferedReader(new InputStreamReader(System.in));\n String input = null;\n try {\n input = br.readLine();\n } catch (IOException e) {\n e.printStackTrace();\n }\n return input;\n }",
"private Scanner getScanner(String fixedString) throws IOException {\n\t\tURLConnection connection = new URL(SUPERVALU_URL_START +fixedString).openConnection();\n\t\treturn new Scanner(connection.getInputStream());\n\t}",
"public void read(Scanner input) {\r\n overallRoot = readHelper(input);\r\n }",
"private static void takeInput() throws IOException {\n\n System.out.println(\"Enter number 1\");\n BufferedReader br= new BufferedReader(new InputStreamReader(System.in));\n String number1=br.readLine();\n System.out.println(\"Enter number 2\");\n String number2=br.readLine();\n System.out.println(\"Operation\");\n String op=br.readLine();\n //WhiteHatHacker processes the input\n WhiteHatHacker hack=new WhiteHatHacker(number1,number2,op);\n hack.processInput();\n }",
"public static int getInput() {\n Scanner in = new Scanner(System.in);\n\n return in.nextInt();\n }",
"String consoleInput();",
"INPUT createINPUT();",
"public void readInput()\n\t{\n\t\tString userInput;\n\t\tChoices choice;\n\t\t\n\t\tdo {\n\t\t\tlog.log(Level.INFO, \"Please give the inputs as:\\n\"\n\t\t\t\t\t+ \"ADDACCOUNT to add the account\\n\" \n\t\t\t\t\t+ \"DISPLAYALL to display all accounts\\n\"\n\t\t\t\t\t+ \"SEARCHBYACCOUNT to search by account\\n\"\n\t\t\t\t\t+ \"DEPOSIT to deposit into account\\n\"\n\t\t\t\t\t+ \"WITHDRAW to withdraw from the account\\n\"\n\t\t\t\t\t+ \"EXIT to end the application\"\n\t\t\t\t\t);\n userInput = scan.next();\n choice = Choices.valueOf(userInput);\n\n switch (choice) {\n case ADDACCOUNT : \taddAccount();\n \t\t\t\t\t\tbreak;\n \n case DISPLAYALL :\t\tdisplayAll();\n \t\t\t\t\t\tbreak;\n\n case SEARCHBYACCOUNT :\tsearchByAccount();\n \t\t\t\t\t\tbreak;\n \n case DEPOSIT :\t\t\tdepositAmount();\n \t\t\t\t\t\tbreak;\n \n case WITHDRAW :\t\t\twithDrawAmount();\n \t\t\t\t\t\tbreak;\n \n case EXIT:\t\t\t\tlog.log(Level.INFO, \"Application has ended successfully\");\n \t\t\t\t\t\tbreak;\n \n default: break;\n }\n } while(choice != Choices.EXIT);\n\t\t\n\t\tscan.close();\n\t}",
"public static String bufferScanner() throws IOException\n\t{\n\treturn br.readLine();\n\t}",
"protected abstract void getInput();",
"private void getInput() {\n\t\tSystem.out.println(\"****Welcome to TNEB online Payment*****\");\r\n\t\tScanner scan = new Scanner(System.in);\r\n\t\tSystem.out.println(\"Enter your current unit\");\r\n\t\tunit = scan.nextInt();\r\n\t}",
"public java_cup.runtime.Symbol scan()\r\n throws java.lang.Exception\r\n {\r\n\r\n\tSymbol s = this.getScanner().next_token();\r\n\tif (s != null && s.value != null) \r\n\t\tlog.info(s.toString() + \" \" + s.value.toString());\r\n\treturn s;\r\n\r\n }",
"public static void main(String[] args) {\n Scanner scan=new Scanner(System.in);\n\n\n\n }",
"public String readCommand() {\n Scanner sc = new Scanner(System.in);\n return sc.nextLine();\n }",
"public PasitoScanner(java.io.InputStream in) {\n this(new java.io.InputStreamReader(in));\n }",
"public String readCommand() {\n return scanner.nextLine();\n }",
"@SuppressWarnings(\"resource\")\n public Scanner openFile() {\n boolean flag = false;\n Scanner input;\n\n while(!flag) {\n\t\t\tScanner scanned = new Scanner(System.in); \n\t if((scanned.next()).equals(\"game\")) {\n\t \tthis.fileName = scanned.next();\n\t try\n\t {\n\t File file = new File(\"./examples/\"+this.fileName);\n\t input = new Scanner(file);\n\t flag = true;\n\t return input;\n\t }\n\t catch (FileNotFoundException e)\n\t {\n\t \tSystem.err.println(\"File was not found, try again\");\n\t } \t\n\t }\n\t else {\n\t \tSystem.err.println(\"First command must be game, try again\");\n\t }\n }\n return null;\n }",
"protected Scanner getTagScanner() {\n \tif(scanner == null)\n \t scanner = new Scanner();\n \treturn scanner;\n }",
"Inputs getInputs();",
"public static void echoContents(Scanner in) {\n }",
"public void read() {\n try {\n pw = new PrintWriter(System.out, true);\n br = new BufferedReader(new InputStreamReader(System.in));\n input = br.readLine();\n while (input != null) {\n CM.processCommand(input, pw, true);\n input = br.readLine();\n }\n } catch (IOException ioe) {\n pw.println(\"ERROR: Problem with reading user input.\");\n } finally {\n try {\n br.close();\n } catch (IOException ioe) {\n pw.println(\"ERROR: Buffer DNE\");\n }\n }\n }",
"R extractRawInputs(I input);",
"@Override\n public T getData() {\n Scanner scanner = new Scanner(System.in);\n return (T) scanner.next();\n }",
"public PasitoScanner(java.io.Reader in) {\n this.yy_reader = in;\n }",
"public void input()\n\t{\n\t\t// this facilitates the output\n\t\tScanner sc = new Scanner(System.in) ; \n\t\tSystem.out.print(\"The Bike Number:- \") ;\n\t \tthis.bno = sc.nextInt() ; \t\n\t\tSystem.out.print(\"The Biker Name:- \") ; \n\t \tthis.name = new Scanner(System.in).nextLine() ; \t\n\t\tSystem.out.print(\"The Phone number:- \") ; \n\t \tthis.phno = sc.nextInt() ; \t\n\t\tSystem.out.print(\"The number of days:- \") ; \n\t \tthis.days = sc.nextInt() ; \t\n\t}",
"public interface Input \n{\n\t/*\n\t * Use to initialise input\n\t */\n\tboolean initialise (String args);\n\t/*\n\t * Return a line or return null\n\t */\n\tString getLine ();\n\t\n}",
"InputPromptTransmitter getInputPromptTransmitter();",
"private static Integer[] readInputFromUser(Scanner in) {\n\t\tInteger[] array = null;\n\t\t/**\n\t\t * Accept the quantity of the data along with actual data.\n\t\t */\n\t\tSystem.out.print(\"Please enter number of integers you want to input:\");\n\t\tint s = in.nextInt();\n\t\tarray = new Integer[s];\n\t\tSystem.out.print(\"Please enter Integers:\");\n\n\t\tfor (int i = 0; i < s; i++) {\n\t\t\tarray[i] = in.nextInt();\n\t\t}\n\t\tSystem.out.println(\"Input Array: \" + Arrays.toString(array));\n\t\treturn array;\n\t}",
"public String userInputString() {\n Scanner scanner = new Scanner(System.in);\n return scanner.nextLine();\n }",
"void readInput() {\n\t\ttry {\n\t\t\tBufferedReader input = new BufferedReader(new InputStreamReader(System.in));\n\t\t\t\n\t\t\tString line = input.readLine();\n\t\t\tString [] numbers = line.split(\" \");\n\n\t\t\tlenA = Integer.parseInt(numbers[0]);\n\t\t\tlenB = Integer.parseInt(numbers[1]); \n\n\t\t\twordA = input.readLine().toLowerCase(); \n\t\t\twordB = input.readLine().toLowerCase();\n\n\t\t\tg = Integer.parseInt(input.readLine());\n\n\t\t\tString key; \n\t\t\tString [] chars;\n\t\t\tpenaltyMap = new HashMap<String, Integer>();\n\n\t\t\tfor(int i=0;i<676;i++) {\n\t\t\t\tline = input.readLine();\n\t\t\t\tchars = line.split(\" \");\n\t\t\t\tkey = chars[0] + \" \" + chars[1];\n\t\t\t\tpenaltyMap.put(key, Integer.parseInt(chars[2]));\n\n\t\t\t}\n\n\t\t\tinput.close();\n\n\t\t} catch (IOException io) {\n\t\t\tio.printStackTrace();\n\t\t}\n\t}",
"private void scan() {\n token = nextToken;\n nextToken = scanner.next();\n }",
"public static void getString()\n\t{\n\t\t\n\t\tScanner s=new Scanner(System.in);\n\t\t\n\t\t//Here Scanner is the class name, a is the name of object, \n\t\t//new keyword is used to allocate the memory and System.in is the input stream. \n\t\t\n\t\tSystem.out.println(\"Entered a string \");\n\t\tString inputString = s.nextLine();\n\t\tSystem.out.println(\"You entered a string \" + inputString );\n\t\tSystem.out.println();\n\t}",
"@Override\r\n public void getInput() { \r\n \r\n String command;\r\n Scanner inFile = new Scanner(System.in);\r\n \r\n do {\r\n \r\n this.display();\r\n \r\n command = inFile.nextLine();\r\n command = command.trim().toUpperCase();\r\n \r\n switch (command) {\r\n case \"B\":\r\n this.helpMenuControl.displayBoardHelp();\r\n break;\r\n case \"C\":\r\n this.helpMenuControl.displayComputerPlayerHelp();\r\n break;\r\n case \"G\":\r\n this.helpMenuControl.displayGameHelp();\r\n break; \r\n case \"Q\": \r\n break;\r\n default: \r\n new Connect4Error().displayError(\"Invalid command. Please enter a valid command.\");\r\n }\r\n } while (!command.equals(\"Q\")); \r\n }"
] | [
"0.78090006",
"0.7141299",
"0.70267206",
"0.6914823",
"0.6722363",
"0.67179507",
"0.67054766",
"0.66842026",
"0.66632307",
"0.6631631",
"0.65835124",
"0.6522134",
"0.65155816",
"0.6508017",
"0.65075225",
"0.64948344",
"0.64844126",
"0.64820474",
"0.6465586",
"0.6465586",
"0.6450088",
"0.64441454",
"0.64359283",
"0.63815045",
"0.6367123",
"0.6363821",
"0.6350856",
"0.62974864",
"0.62418044",
"0.62280864",
"0.62074894",
"0.6194029",
"0.61775064",
"0.61704564",
"0.6169613",
"0.6159468",
"0.615068",
"0.6146388",
"0.61463",
"0.61398566",
"0.6138385",
"0.6117945",
"0.6112345",
"0.61089027",
"0.61045694",
"0.6098302",
"0.6093209",
"0.6089474",
"0.6088283",
"0.60878134",
"0.6084301",
"0.607617",
"0.6073214",
"0.60596746",
"0.60526586",
"0.60526586",
"0.60434747",
"0.6040362",
"0.6025753",
"0.6020754",
"0.6013022",
"0.6011465",
"0.59924555",
"0.598556",
"0.598556",
"0.59841466",
"0.5973595",
"0.59634864",
"0.59594685",
"0.59564626",
"0.59455264",
"0.59436506",
"0.59284514",
"0.5927085",
"0.5914867",
"0.59114105",
"0.5905787",
"0.5903947",
"0.5896687",
"0.5896008",
"0.58851045",
"0.58812934",
"0.58543706",
"0.5851571",
"0.58359474",
"0.58332306",
"0.58325773",
"0.58322483",
"0.58121264",
"0.58097976",
"0.5808596",
"0.58060753",
"0.58050543",
"0.5801641",
"0.5796911",
"0.5788744",
"0.57856673",
"0.5784994",
"0.57801336",
"0.577418",
"0.5773266"
] | 0.0 | -1 |
1 meter per 1 meter | public Soil()
{
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public static double metresPerSecondToCentiMetresPerSecond(double num) { return (num*100); }",
"public static double centiMetresPerSecondToMetrePerSecond(double num) { return (num/100); }",
"public static double feetPerSecondToCentiMetresPerSecond(double num) { return (num*30.48); }",
"public void metersPerSecond(Double val)\n\t{\n\t\tsetValue(val, VelocityUnit.METERS_PER_SECOND);\n\t}",
"public double toMetersPerSecond(){\n\t\tdouble mps = mph * 1609.34/3600;\n\t\treturn mps;\n\t}",
"private static float calculateStepRate(int stepCount) {\n\n return (float) stepCount / (float) secsPerMinute;\n\n }",
"Meter createMeter();",
"public Double metersPerSecond()\n\t{\n\t\treturn getValue(VelocityUnit.METERS_PER_SECOND);\n\t}",
"int getMPPerSecond();",
"Millimeter createMillimeter();",
"public static double milesPerHourToCentiMetresPerSecond(double num) { return (num*44.704); }",
"@Override\n public double salario() {\n return 2600 * 1.10;\n }",
"public Double millimetersPerSecond()\n\t{\n\t\treturn getValue(VelocityUnit.MILLIMETERS_PER_SECOND);\n\t}",
"@Override\r\n\tpublic void perSecond() {\n\r\n\t}",
"public static double centiToMeter(double num) { return (num/Math.pow(10,2)); }",
"public float spiderScaleAmount()\n {\nreturn 1F;\n }",
"private KilometersPerHour() {}",
"public void calcSpeed(){\r\n Random rand = new Random();\r\n tire = rand.nextInt(10)+1;\r\n engine = rand.nextInt(10)+1;\r\n weight = rand.nextInt(10)+1;\r\n speed = ((double)(tire+engine+weight))/3;\r\n\r\n //round speed to 2 decimal places\r\n speed = speed*100;\r\n speed = Math.round(speed);\r\n speed = speed/100;\r\n }",
"public void millimetersPerSecond(Double val)\n\t{\n\t\tsetValue(val, VelocityUnit.MILLIMETERS_PER_SECOND);\n\t}",
"public void micrometersPerSecond(Double val)\n\t{\n\t\tsetValue(val, VelocityUnit.MICROMETERS_PER_SECOND);\n\t}",
"@Override\n public int calculerPerimetre() {\n return (int)(rayon * 2 * Math.PI);\n }",
"public void kilometersPerSecond(Double val)\n\t{\n\t\tsetValue(val, VelocityUnit.KILOMETERS_PER_SECOND);\n\t}",
"@Override\n public double tuition(){\n return 2500;\n }",
"@Override\n protected float calculateSpeedPerPixel\n (DisplayMetrics displayMetrics) {\n return MILLISECONDS_PER_INCH/displayMetrics.densityDpi;\n }",
"public static Velocity newMetersPerSecondValue()\n\t{\n\t\treturn new Velocity(0.0, VelocityUnit.METERS_PER_SECOND);\n\t}",
"public float getFrameRate() { return 1000f/_interval; }",
"protected abstract float getMeasurement();",
"public Double kilometersPerSecond()\n\t{\n\t\treturn getValue(VelocityUnit.KILOMETERS_PER_SECOND);\n\t}",
"public static double kiloMetresPerHourToCentiMetresPerSecond(double num) { return (num*27.7778); }",
"private int convertProgressToMeters(int progress) {\n return progress * METERS_PER_PROGRESS;\n }",
"@Override\r\n\tpublic int unitsToWagger() {\n\t\treturn 0;\r\n\t}",
"public Double micrometersPerSecond()\n\t{\n\t\treturn getValue(VelocityUnit.MICROMETERS_PER_SECOND);\n\t}",
"public static double computeDiameter(int wireGauge)\r\n{ \r\n return 0.127 * Math.pow(92.0, (36.0 - wireGauge) / 39.0); \r\n}",
"double getRatio();",
"public void doubleSpeed()\r\n {\r\n \tthis.speed= speed-125;\r\n \tgrafico.setVelocidad(speed);\r\n }",
"public abstract double getMeasurement();",
"public abstract double getMeasurement();",
"int getMortgageRate();",
"double getRate();",
"public void megabytesPerSecond(Double val)\n\t{\n\t\tsetValue(val, DataRateUnit.MEGABYTES_PER_SEC);\n\t}",
"public double perimetre()\n\t{\n\t\treturn 2*Math.PI*rayon;\n\t}",
"public static Velocity newMicrometersPerSecondValue()\n\t{\n\t\treturn new Velocity(0.0, VelocityUnit.MICROMETERS_PER_SECOND);\n\t}",
"@Override\n\tpublic double perimetro() {\n\t\treturn 0;\n\t}",
"public Integer getMeterDenominator() {\n return this.meterDenominator;\n }",
"public static double convertPixelToMeter(int pixel) {\n return pixel / 50;\n }",
"public double masse () {return this.volume()*this.element.masseVolumique();}",
"double getPerimetro();",
"public abstract float perimetro();",
"double getSpeed();",
"@Override\n\t\tpublic int getSpeed() {\n\t\t\treturn i+30;\n\t\t}",
"public static Velocity newKilometersPerSecondValue()\n\t{\n\t\treturn new Velocity(0.0, VelocityUnit.KILOMETERS_PER_SECOND);\n\t}",
"public Double megabytesPerSecond()\n\t{\n\t\treturn getValue(DataRateUnit.MEGABYTES_PER_SEC);\n\t}",
"@Override\n\tpublic double calRate() {\n\t\treturn 0.9f;\n\t}",
"Double getMultiplier();",
"protected double pixelOneSampleF() {\r\n\t\treturn ((double) getGraphWidth()) / section.getLength();\r\n\t}",
"public static double squareMetersToSquareMilliMeters(double num){ return (num*Math.pow(10,6)); }",
"int getSampleMs();",
"public void degreePerSecond(Double val)\n\t{\n\t\tsetValue(val, AngularVelocityUnit.DEGREES_PER_SEC);\n\t}",
"public double getUnitsPerPercent()\n {\n return unitsPerPercent;\n }",
"public double getMass();",
"void total() {\r\n t=m1+m2+m3;\r\n per=t/3;\r\n System.out.println(\"total :\"+t);\r\n System.out.println(\"persentage:\"+per);\r\n \r\n \r\n }",
"private int SpeedCalculation(int speed)\r\n\t{\t\r\n\t\tif(up||down)\r\n\t\treturn (int) ((speed/12.5)+1); //Speed divided by (100/(parts-1)) = 1-9\r\n\t\telse return (int) (0); \r\n\t}",
"public float getRate() {\n\treturn durationStretch * nominalRate;\n }",
"public static Velocity newMillimetersPerSecondValue()\n\t{\n\t\treturn new Velocity(0.0, VelocityUnit.MILLIMETERS_PER_SECOND);\n\t}",
"public double getSpeed();",
"public double perSecond(double quantity) {\n\t\treturn getSimulationStepDuration(TimeUnit.SECONDS) * quantity;\n\t}",
"protected double samplesOnePixelF() {\r\n\t\tif (getGraphWidth() > 1) {\r\n\t\t\t// avoid division by zero\r\n\t\t\treturn ((double) section.getLength()) / getGraphWidth();\r\n\t\t}\r\n\t\treturn 1.0;\r\n\t}",
"public void utilization() {\r\n\t\tfloat fAktuell = this.aktuelleLast;\r\n\t\tfloat fMax = this.raumsonde.getMaxNutzlast();\r\n\t\tfloat prozent = fAktuell / fMax * 100;\r\n\r\n\t\tSystem.out.println(\" \" + fAktuell + \"/\" + fMax + \" (\" + prozent + \"%)\");\r\n\t}",
"protected double getMPS() {\n\t\t\treturn this.getCost() / this.castPeriod;\n\t\t}",
"private int normalizeTime() {\n int currentTimeSeconds = (int) (System.currentTimeMillis() / 1000);\n\n // The graphing interval in minutes\n // TODO not hardcoded :3\n int interval = 30;\n\n // calculate the devisor denominator\n int denom = interval * 60;\n\n return (int) Math.round((currentTimeSeconds - (denom / 2d)) / denom) * denom;\n }",
"public double getPercentRem(){\n return ((double)freeSpace / (double)totalSpace) * 100d;\n }",
"@Override\n\t\tpublic int getSpeed() {\n\t\t\treturn i+20;\n\t\t}",
"Measurement getAccumulation();",
"private void updateSpeed(CLocation location) {\n try {\n\n i = i + 1;\n Log.i(\"111\", \"====updateSpeed=====i===\" + i);\n // Log.i(\"111\",\"====location=====getLongitude===\"+location.getLongitude());\n // Log.i(\"111\",\"====location=====getLatitude===\"+location.getLatitude());\n\n\n float nCurrentSpeed = 0;\n\n if (location != null) {\n location.setUseMetricunits(true);\n nCurrentSpeed = location.getSpeed();\n }\n\n Formatter fmt = new Formatter(new StringBuilder());\n fmt.format(Locale.US, \"%5.1f\", nCurrentSpeed);\n String strCurrentSpeed = fmt.toString();\n strCurrentSpeed = strCurrentSpeed.replace(' ', '0');\n\n String strUnits = \"miles/hour\";\n\n\n strLog = strLog +\n \"\\n--------------\\n \" +\n strCurrentSpeed + \" \" + strUnits +\n \"\\n--------------\\n \";\n\n tvData.append(\"\\n Speed2 = \" + strCurrentSpeed + \" \" + strUnits);\n\n /* float speed = Float.parseFloat(strCurrentSpeed);\n if(speed<100)\n mGaugeView.setTargetValue(speed);\n else\n {\n tvLog.setText(\"out of speed\"+strLog);\n }*/\n\n } catch (Exception e) {\n e.printStackTrace();\n }\n }",
"public float getIterationValue()\n\t{\n\t\tif (getDuration() <= 0) { return 1; }\n\t\treturn getCurrentTime() / getDuration();\n\t}",
"private static Double convertToMeters(Double Ins) {\n double meters;\n meters = Ins / 39.37;\n return meters;\n }",
"public double getWidthInMillimeters()\n {\n return MILLIMETERS * width;\n }",
"private double genMultiplier() {\n return (random.nextInt(81) + 60)/100.0;\n }",
"public double getSpeed(){\r\n double Speed;\r\n Speed = (double)(Distance * TimeConversion)/(getMinutes() * SecondsConversion + getSeconds()); \r\n if ((getMinutes()==0) || (getSeconds() == 0)) {\r\n Speed =0;\r\n } //Closing bracket if statement\r\n return Speed;\r\n }",
"int getSpeed();",
"int getSpeed();",
"int getSpeed();",
"int getSpeed();",
"int getSpeed();",
"int getSpeed();",
"int getPulsePercentage();",
"protected final int calculateInterst1(int pr){\n\t\t return pr*10*1/100;\n\t }",
"int getSmpRate();",
"@Override\n public double total() {\n return 2500;\n }",
"@Override\n public double calculate(double input)\n {\n return input/getValue();\n }",
"private float getRefreshRate() {\n return 1;\n }",
"public void timer()\n {\n timer += .1; \n }",
"public void setRate(double annualRate) {\nmonthlyInterestRate = annualRate / 100.0 / MONTHS;\n}",
"public int getSpeed()\r\n\t{\n\t\treturn 90;\r\n\t}",
"public void nanometersPerSecond(Double val)\n\t{\n\t\tsetValue(val, VelocityUnit.NANOMETERS_PER_SECOND);\n\t}",
"public static double millimetersOfMercuryToAtmosphere(double num) { return (num/760); }",
"public Integer getMeterNumerator() {\n return this.meterNumerator;\n }",
"public double CalcoloPerimetro () {\r\n \treturn 4*(base);\r\n }",
"double getThroughput();",
"public float calculateSpeedPerPixel(DisplayMetrics displayMetrics) {\n return 100.0f / ((float) displayMetrics.densityDpi);\n }",
"public static Velocity newNanometersPerSecondValue()\n\t{\n\t\treturn new Velocity(0.0, VelocityUnit.NANOMETERS_PER_SECOND);\n\t}"
] | [
"0.66928077",
"0.6677123",
"0.6501564",
"0.64412624",
"0.6420685",
"0.6402936",
"0.638208",
"0.63519543",
"0.62965983",
"0.6293932",
"0.6246396",
"0.62167937",
"0.6211671",
"0.61556077",
"0.6154605",
"0.6141081",
"0.613194",
"0.6116223",
"0.6115492",
"0.6089843",
"0.60892797",
"0.6084834",
"0.6080756",
"0.6078581",
"0.6075892",
"0.60683846",
"0.6038994",
"0.60078746",
"0.5996342",
"0.59841126",
"0.5961733",
"0.59571815",
"0.5935625",
"0.59355897",
"0.59179443",
"0.591684",
"0.591684",
"0.5909645",
"0.5909522",
"0.58971614",
"0.5856125",
"0.5853291",
"0.5852289",
"0.5851483",
"0.5843656",
"0.5827647",
"0.582136",
"0.5817177",
"0.58103675",
"0.58064115",
"0.5805212",
"0.58004934",
"0.5787935",
"0.57866484",
"0.5780421",
"0.57777363",
"0.5766247",
"0.57651514",
"0.57643145",
"0.5759641",
"0.57567453",
"0.5751196",
"0.57467836",
"0.57421786",
"0.5723153",
"0.5720545",
"0.57177323",
"0.57154506",
"0.571241",
"0.5711435",
"0.5706643",
"0.5700725",
"0.56949687",
"0.56925505",
"0.56915367",
"0.5686996",
"0.5681294",
"0.5673358",
"0.5669225",
"0.56663483",
"0.56663483",
"0.56663483",
"0.56663483",
"0.56663483",
"0.56663483",
"0.5664502",
"0.566259",
"0.5657529",
"0.5656811",
"0.56501067",
"0.56429005",
"0.56399995",
"0.56385183",
"0.5635933",
"0.5635379",
"0.5631714",
"0.5623739",
"0.5623658",
"0.561959",
"0.55998397",
"0.5596236"
] | 0.0 | -1 |
double radianLat1 = Math.toRadians(latitude1); double radianLon1 = Math.toRadians(longitude1); double radianLat2 = Math.toRadians(latitude2); double radianLon2 = Math.toRadians(longitude2); double deltaLat = radianLat1radianLat2; double deltaLon = radianLon1radianLon2; double a = Math.pow(Math.sin(deltaLat/2),2) + Math.cos(radianLat1) Math.cos(radianLat2) Math.pow(Math.sin(deltaLon/2), 2); double c = 2 Math.atan2(Math.sqrt(a), Math.sqrt(1a)); return r c; | public double calculateDistance(double latitude1, double longitude1, double latitude2, double longitude2)
{
latitude1 = Math.toRadians(latitude1);
longitude1 = Math.toRadians(longitude1);
latitude2 = Math.toRadians(latitude2);
longitude2 = Math.toRadians(longitude2);
double dlon = longitude2 - longitude1;
double dlat = latitude2 - latitude1;
double a = Math.pow((Math.sin(dlat/2)),2) + Math.cos(latitude1) * Math.cos(latitude2) * Math.pow(Math.sin(dlon/2),2);
double c = 2 * Math.atan2(Math.sqrt(a), Math.sqrt(1-a));
//System.out.println("a: " + a + ";c: " + c + ";result: " + (r*c));
return r * c;
} | {
"objective": {
"self": [],
"paired": [],
"triplet": [
[
"query",
"document",
"negatives"
]
]
}
} | [
"public static double GetDistance(double lat1, double lon1, double lat2, double lon2) {\n double radLat1 = rad(lat1);\n double radLat2 = rad(lat2);\n double a = radLat1 - radLat2;\n double b = rad(lon1) - rad(lon2);\n double s = 2 * Math.asin(Math.sqrt(Math.pow(Math.sin(a / 2), 2) +\n Math.cos(radLat1) * Math.cos(radLat2) * Math.pow(Math.sin(b / 2), 2)));\n s = s * EARTH_RADIUS;//km\n// Log.e(\"s\", \"s=\" + s);\n return s;\n }",
"public double GetGPSBearing(double lat1,\n double lat2, double lon1,\n double lon2) {\n\n\n double currentLatitudeRadians = Math.toRadians(lat1);\n double destinationLatitudeRadians = Math.toRadians(lat2);\n double currentLongitudeRadians = Math.toRadians(lon1);\n double destinationLongitudeRadians = Math.toRadians(lon2);\n\n double y;\n y = Math.sin(destinationLongitudeRadians - currentLongitudeRadians) * Math.cos(destinationLatitudeRadians);\n double x;\n x = Math.cos(currentLatitudeRadians) * Math.sin(destinationLatitudeRadians) -\n Math.sin(currentLatitudeRadians) * Math.cos(destinationLatitudeRadians) * Math.cos(destinationLongitudeRadians - currentLongitudeRadians);\n double bearing = Math.atan2(y, x);\n\n\n return (bearing * 180 / Math.PI + 360) % 360;\n\n }",
"public static double distance(double latitude,double longitude,double latitude2,double longitude2){\n\n \t double deltalat = Math.toRadians(latitude2 - latitude);\n \t double deltalog = Math.toRadians(longitude2 - longitude);\n\n \t double a = Math.pow(Math.sin(deltalat/2),2) +\n \t\t\t\t Math.pow(Math.sin(deltalog/2),2) *\n \t\t\t\t Math.cos(latitude) *\n \t\t\t\t Math.cos(latitude2);\n \t double c = 2 * Math.asin(Math.sqrt(a));\n\n \t return EARTH_RADIUS * c;\n\n }",
"private double distance(double lat1, double lon1, double lat2, double lon2) {\r\n double theta = lon1 - lon2;\r\n double dist = Math.sin(deg2rad(lat1))\r\n * Math.sin(deg2rad(lat2))\r\n + Math.cos(deg2rad(lat1))\r\n * Math.cos(deg2rad(lat2))\r\n * Math.cos(deg2rad(theta));\r\n dist = Math.acos(dist);\r\n dist = rad2deg(dist);\r\n dist = dist * 60 * 1.1515;\r\n return (dist);\r\n }",
"private double distance(double lat1, double lon1, double lat2, double lon2) {\n double theta = lon1 - lon2;\r\n double dist = Math.sin(deg2rad(lat1)) * Math.sin(deg2rad(lat2)) + Math.cos(deg2rad(lat1)) * Math.cos(deg2rad(lat2)) * Math.cos(deg2rad(theta));\r\n dist = Math.acos(dist);\r\n dist = rad2deg(dist);\r\n dist = dist * 60 * 1.1515;\r\n dist = dist * 1.609344;\r\n return (dist); // return distance in kilometers\r\n }",
"final public static int dist(float lat1, float lon1,\n \t\tfloat lat2, float lon2) {\n \tdouble latSin = Math.sin((lat2-lat1)/2d);\n \tdouble longSin = Math.sin((lon2-lon1)/2d);\n \tdouble a = (latSin * latSin) + (Math.cos(lat1)*Math.cos(lat2)*longSin*longSin);\n \tdouble c = 2d * atan2(Math.sqrt(a),Math.sqrt(1d-a));\n \treturn (int)(PLANET_RADIUS_D * (c + 0.5d));\n }",
"public static double distanciaCoord(double lat1, double lng1, double lat2, double lng2) {\n\n double radioTierra = 6371;//en kilómetros \n double dLat = Math.toRadians(lat2 - lat1);\n double dLng = Math.toRadians(lng2 - lng1);\n double sindLat = Math.sin(dLat / 2);\n double sindLng = Math.sin(dLng / 2);\n double va1 = Math.pow(sindLat, 2) + Math.pow(sindLng, 2)\n * Math.cos(Math.toRadians(lat1)) * Math.cos(Math.toRadians(lat2));\n double va2 = 2 * Math.atan2(Math.sqrt(va1), Math.sqrt(1 - va1));\n double distancia = radioTierra * va2;\n\n return distancia * 1000;\n }",
"public double calcDistance(double lat1, double lon1, double lat2, double lon2) {\n \t//Calculate great-circle distance\n \tdouble radius = 6371000;\t//radius of earth in meters\n \tdouble deltaLat = Math.toRadians(lat2 - lat1);\n \tdouble deltaLong = Math.toRadians(lon2 - lon1);\n\t\n \tlat1 = Math.toRadians(lat1);\n \tlat2 = Math.toRadians(lat2);\n\t\t\n \tdouble a = Math.sin(deltaLat / 2.0) * Math.sin(deltaLat / 2.0) +\n \t\t\tMath.cos(lat1) * Math.cos(lat2) * Math.sin(deltaLong / 2.0) *\n \t\t\tMath.sin(deltaLong / 2.0);\n \tdouble c = 2 * Math.atan2(Math.sqrt(a), Math.sqrt(1.0 - a));\n\t\n \treturn radius * c;\n }",
"private double distance(double lat1, double lat2, double lon1, double lon2)\n {\n lon1 = Math.toRadians(lon1);\n lon2 = Math.toRadians(lon2);\n lat1 = Math.toRadians(lat1);\n lat2 = Math.toRadians(lat2);\n\n // Haversine formula\n double dlon = lon2 - lon1;\n double dlat = lat2 - lat1;\n double a = Math.pow(Math.sin(dlat / 2), 2)\n + Math.cos(lat1) * Math.cos(lat2)\n * Math.pow(Math.sin(dlon / 2),2);\n\n double c = 2 * Math.asin(Math.sqrt(a));\n\n // Radius of earth in kilometers. Use 3956\n // for miles\n double r = 6371;\n\n // calculate the result\n return(c * r);\n }",
"public static double calcBearing(double lat1, double lon1, double lat2, double lon2) {\n\tdouble x = Math.sin(lon2 - lon1) * Math.cos(lat2);\n\tdouble y = Math.cos(lat1) * Math.sin(lat2) - Math.sin(lat1) *\n\t\tMath.cos(lat2) * Math.cos(lon2 - lon1);\n\t\n\treturn ((Math.toDegrees(Math.atan2(x,y)) + 360) % 360);\n }",
"public static double distance(double latitude1, double longitude1, double latitude2, double longitude2) {\n\n\t\tdouble a,c,d; // fjern = 1.0\n\t\t\n\t\t// TODO:\n\t\t// OPPGAVE - START\n\t\tdouble phi1 = toRadians(latitude1);\n\t\tdouble phi2 = toRadians(latitude2);\n\t\tdouble dphi1 = toRadians(latitude2 - latitude1);\n\t\tdouble dLamd1 = toRadians(longitude2 - longitude1);\n\t\t\n\t\ta = Math.pow((sin(dphi1/2)),2)+ cos(phi1)*cos(phi2)*Math.pow(sin(dLamd1/2),2);\n\t\tc = 2*atan2(sqrt(a), sqrt((1-a)));\n\t\td = R*c;\n\t\t// OPPGAVE - SLUTT\n\n\t\treturn d;\n\t}",
"public static double orthodromicDistance(double dLat1, double dLon1, double dLat2, double dLon2){\n\t\tdouble dLat = DEG_TO_RAD*(dLat2-dLat1); \n\t\tdouble dLon = DEG_TO_RAD*(dLon2-dLon1); \n\t\tdouble a = Math.sin(dLat/2.) * Math.sin(dLat/2.) + Math.cos(DEG_TO_RAD*dLat1) * Math.cos(DEG_TO_RAD*dLat2) * Math.sin(dLon/2.) * Math.sin(dLon/2.);\n\t\treturn EARTH_RADIUS * 2. * Math.atan2(Math.sqrt(a), Math.sqrt(1-a));\n\t}",
"public static double initialGeodesicBearing(double dLat1, double dLon1, double dLat2, double dLon2){\n\t\t\n\t\t//dOut = output\n\t\t//d1 = difference between longitudes\n\t\t \n\t\tdouble d1;\n\t\tdouble dOut;\n\t\t\n\t\t//checking that start and destination points are different\n\t\tif(!arePointsDifferent(dLat1, dLon1, dLat2, dLon2)){\n\t\t\treturn Double.NaN;\n\t\t}\n\t\t\n\t\t//loading output\n\t\td1 = dLon2 - dLon1;\n\t\td1 = d1*DEG_TO_RAD;\n\t\tdOut=RAD_TO_DEG*atan2(Math.sin(d1)*cos(DEG_TO_RAD*dLat2), cos(DEG_TO_RAD*dLat1)*sin(DEG_TO_RAD*dLat2)-sin(DEG_TO_RAD*dLat1)*cos(DEG_TO_RAD*dLat2)*cos(d1));\n\t\t\n\t\t//checking that output is in the interval [0,360]\n\t\treturn convertBearingTo360(dOut);\n\t}",
"private static double deg2rad(double lat1) {\n return (lat1*Math.PI/180.0);\n }",
"public static double distance(double lat1, double lon1, double lat2, double lon2) {\n\n\n float[] dist = new float[1];\n Location.distanceBetween(lat1, lon1, lat2, lon2, dist);\n //Log.d(\"*******dist\", \":\" + dist[0]);\n return (dist[0]);\n //\n // double theta = lon1 - lon2;\n // double dist = Math.sin(deg2rad(lat1)) * Math.sin(deg2rad(lat2))\n // + Math.cos(deg2rad(lat1)) * Math.cos(deg2rad(lat2))\n // * Math.cos(deg2rad(theta));\n // dist = Math.acos(dist);\n // dist = rad2deg(dist);\n // dist = dist * 60; // 60 nautical miles per degree of seperation\n // dist = dist * 1852; // 1852 meters per nautical mile\n // return (dist);\n //\n }",
"private static void computeDistanceAndBearing(double lat1, double lon1,\n\t double lat2, double lon2, double[] results) {\n\n\t\tint MAXITERS = 20;\n\t\t// Convert lat/long to radians\n\t\tlat1 *= Math.PI / 180.0;\n\t\tlat2 *= Math.PI / 180.0;\n\t\tlon1 *= Math.PI / 180.0;\n\t\tlon2 *= Math.PI / 180.0;\n\n\t\tdouble a = 6378137.0; // WGS84 major axis\n\t\tdouble b = 6356752.3142; // WGS84 semi-major axis\n\t\tdouble f = (a - b) / a;\n\t\tdouble aSqMinusBSqOverBSq = (a * a - b * b) / (b * b);\n\n\t\tdouble L = lon2 - lon1;\n\t\tdouble A = 0.0;\n\t\tdouble U1 = Math.atan((1.0 - f) * Math.tan(lat1));\n\t\tdouble U2 = Math.atan((1.0 - f) * Math.tan(lat2));\n\n\t\tdouble cosU1 = Math.cos(U1);\n\t\tdouble cosU2 = Math.cos(U2);\n\t\tdouble sinU1 = Math.sin(U1);\n\t\tdouble sinU2 = Math.sin(U2);\n\t\tdouble cosU1cosU2 = cosU1 * cosU2;\n\t\tdouble sinU1sinU2 = sinU1 * sinU2;\n\n\t\tdouble sigma = 0.0;\n\t\tdouble deltaSigma = 0.0;\n\t\tdouble cosSqAlpha = 0.0;\n\t\tdouble cos2SM = 0.0;\n\t\tdouble cosSigma = 0.0;\n\t\tdouble sinSigma = 0.0;\n\t\tdouble cosLambda = 0.0;\n\t\tdouble sinLambda = 0.0;\n\n\t\tdouble lambda = L; // initial guess\n\t\tfor (int iter = 0; iter < MAXITERS; iter++) {\n\t\t\tdouble lambdaOrig = lambda;\n\t\t\tcosLambda = Math.cos(lambda);\n\t\t\tsinLambda = Math.sin(lambda);\n\t\t\tdouble t1 = cosU2 * sinLambda;\n\t\t\tdouble t2 = cosU1 * sinU2 - sinU1 * cosU2 * cosLambda;\n\t\t\tdouble sinSqSigma = t1 * t1 + t2 * t2; // (14)\n\t\t\tsinSigma = Math.sqrt(sinSqSigma);\n\t\t\tcosSigma = sinU1sinU2 + cosU1cosU2 * cosLambda; // (15)\n\t\t\tsigma = Math.atan2(sinSigma, cosSigma); // (16)\n\t\t\tdouble sinAlpha = (sinSigma == 0) ? 0.0 :\n\t\t\t\t\t\t\tcosU1cosU2 * sinLambda / sinSigma; // (17)\n\t\t\tcosSqAlpha = 1.0 - sinAlpha * sinAlpha;\n\t\t\tcos2SM = (cosSqAlpha == 0) ? 0.0 :\n\t\t\t\t\t\t\tcosSigma - 2.0 * sinU1sinU2 / cosSqAlpha; // (18)\n\n\t\t\tdouble uSquared = cosSqAlpha * aSqMinusBSqOverBSq; // defn\n\t\t\tA = 1 + (uSquared / 16384.0) * // (3)\n\t\t\t\t\t\t\t(4096.0 + uSquared *\n\t\t\t\t\t\t\t\t\t\t\t(-768 + uSquared * (320.0 - 175.0 * uSquared)));\n\t\t\tdouble B = (uSquared / 1024.0) * // (4)\n\t\t\t\t\t\t\t(256.0 + uSquared *\n\t\t\t\t\t\t\t\t\t\t\t(-128.0 + uSquared * (74.0 - 47.0 * uSquared)));\n\t\t\tdouble C = (f / 16.0) *\n\t\t\t\t\t\t\tcosSqAlpha *\n\t\t\t\t\t\t\t(4.0 + f * (4.0 - 3.0 * cosSqAlpha)); // (10)\n\t\t\tdouble cos2SMSq = cos2SM * cos2SM;\n\t\t\tdeltaSigma = B * sinSigma * // (6)\n\t\t\t\t\t\t\t(cos2SM + (B / 4.0) *\n\t\t\t\t\t\t\t\t\t\t\t(cosSigma * (-1.0 + 2.0 * cos2SMSq) -\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t(B / 6.0) * cos2SM *\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t(-3.0 + 4.0 * sinSigma * sinSigma) *\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t(-3.0 + 4.0 * cos2SMSq)));\n\n\t\t\tlambda = L +\n\t\t\t\t\t\t\t(1.0 - C) * f * sinAlpha *\n\t\t\t\t\t\t\t\t\t\t\t(sigma + C * sinSigma *\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t(cos2SM + C * cosSigma *\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t(-1.0 + 2.0 * cos2SM * cos2SM))); // (11)\n\n\t\t\tdouble delta = (lambda - lambdaOrig) / lambda;\n\t\t\tif (Math.abs(delta) < 1.0e-12) {\n\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\n\t\tfloat distance = (float) (b * A * (sigma - deltaSigma));\n\t\tresults[0] = distance;\n\t\tfloat initialBearing = (float) Math.atan2(cosU2 * sinLambda,\n\t\t cosU1 * sinU2 - sinU1 * cosU2 * cosLambda);\n\t\tinitialBearing *= 180.0 / Math.PI;\n\t\tfloat finalBearing = (float) Math.atan2(cosU1 * sinLambda,\n\t\t -sinU1 * cosU2 + cosU1 * sinU2 * cosLambda);\n\t\tfinalBearing *= 180.0 / Math.PI;\n\t\tresults[1] = finalBearing;\n\t}",
"private double distance (double lata, double lona, double latb, double lonb) { \r\n return Math.acos(Math.sin(lata)*Math.sin(latb)+Math.cos(lata)*Math.cos(latb)*Math.cos(lonb-lona))*6371;\r\n }",
"private static Double getDistance(Double lng1, Double lat1, Double lng2, Double lat2) {\n double radLat1 = lat1 * RAD;\n double radLat2 = lat2 * RAD;\n double a = radLat1 - radLat2;\n double b = (lng1 - lng2) * RAD;\n double s = 2 * Math.asin(Math.sqrt(\n Math.pow(Math.sin(a / 2), 2) + Math.cos(radLat1) * Math.cos(radLat2) * Math.pow(Math.sin(b / 2), 2)));\n s = s * EARTH_RADIUS;\n s = Math.round(s * 10000) / 10000000.0;\n return s;\n }",
"private double distanceBetweenLatLongPoints(double lat1, double long1, double lat2, double long2) {\r\n // radius of the Earth in km\r\n double R = 6378.137;\r\n double dLat = (lat2 * Math.PI / 180) - (lat1 * Math.PI / 180);\r\n double dLong = (long2 * Math.PI / 180) - (long1 * Math.PI / 180);\r\n double a = Math.sin(dLat / 2) * Math.sin(dLat / 2) +\r\n Math.cos(lat1 * Math.PI / 180) * Math.cos(lat2 * Math.PI / 180) *\r\n Math.sin(dLong / 2) * Math.sin(dLong / 2);\r\n double c = 2 * Math.atan2(Math.sqrt(a), Math.sqrt(1-a));\r\n double d = R * c;\r\n return d * 1000;\r\n }",
"public double getDistance(double latitude1, double latitude2, double longitude1, double longitude2) {\n final int EarthRadius = 6371000; // It is in meters scale.\n double latitude_difference = Math.toRadians(latitude2 - latitude1);\n double longitude_difference = Math.toRadians(longitude2 - longitude1);\n double a = (Math.sin(latitude_difference / 2) * Math.sin(latitude_difference / 2))\n + (Math.cos(Math.toRadians(latitude1)) * Math.cos(Math.toRadians(latitude2))\n * Math.sin(longitude_difference / 2) * Math.sin(longitude_difference / 2));\n double c = 2 * Math.atan2(Math.sqrt(a), Math.sqrt(1 - a));\n double distance = EarthRadius * c;\n return distance;\n }",
"public static double distanceFromLatLon(double dLat1, double dLon1, double dLat2, double dLon2)\n\t{\n\t\tdouble dLat = (dLat2 - dLat1) * PIOVER180;\n\t\tdouble dLon = (dLon2 - dLon1) * PIOVER180;\n\t\tdouble dA = Math.sin(dLat / 2) * Math.sin(dLat /2) + Math.cos(dLat1 * PIOVER180) * Math.cos(dLat2 * PIOVER180) * Math.sin(dLon / 2) * Math.sin(dLon / 2);\n\t\treturn 2 * EARTH_RADIUS_KM * Math.asin(Math.sqrt(dA));\n\t}",
"public double initialGeodesicBearingWGS84(double dLat1, double dLon1, double dLat2, double dLon2){\n\t\t\n\t\t//dOut = output\n\t\t\n\t\tdouble dOut;\n\t\t\n\t\t//checking that start and destination points are different\n\t\tif(!arePointsDifferent(dLat1, dLon1, dLat2, dLon2)){\n\t\t\treturn Double.NaN;\n\t\t}\n\t\t\n\t\t//loading output\n\t\tgcl1.setStartingGeographicPoint(dLon1, dLat1);\n\t\tgcl1.setDestinationGeographicPoint(dLon2, dLat2);\n\t\tdOut = gcl1.getAzimuth();\n\t\t\n\t\t//checking that output is in the interval [0,360]\n\t\treturn convertBearingTo360(dOut);\n\t}",
"public static double findLatitudeOfOrthodromeIntersection(double dLat1, double dLng1, double dLat2, double dLng2, double dLng){\n\t\t \n\t\t //d1 = output\n\t\t \n\t\t double d1;\n\t\t \n\t\t //computing intersection\n\t\t d1 = Math.atan((Math.tan(dLat1*DEG_TO_RAD)*Math.sin(dLng*DEG_TO_RAD - dLng2*DEG_TO_RAD) - Math.tan(dLat2*DEG_TO_RAD)*Math.sin(dLng*DEG_TO_RAD - dLng1*DEG_TO_RAD)) / Math.sin(dLng1*DEG_TO_RAD - dLng2*DEG_TO_RAD));\n\t\t \n\t\t //outputting result\n\t\t return d1*RAD_TO_DEG;\n\t }",
"public static double distance(double lat1, double lat2, double lon1, double lon2) {\n lon1 = Math.toRadians(lon1);\n lon2 = Math.toRadians(lon2);\n lat1 = Math.toRadians(lat1);\n lat2 = Math.toRadians(lat2);\n\n // Haversine formula\n double dlon = lon2 - lon1;\n double dlat = lat2 - lat1;\n double a = Math.pow(Math.sin(dlat / 2), 2) + Math.cos(lat1) * Math.cos(lat2) * Math.pow(Math.sin(dlon / 2),2);\n\n double c = 2 * Math.asin(Math.sqrt(a));\n\n // Radius of earth in miles.\n double r = 3956;\n\n // calculate the result\n return(c * r);\n }",
"public double orthodromicDistanceWGS84(double dLat1, double dLon1, double dLat2, double dLon2){\n\t\t\n\t\tif(dLon1<=-180){\n\t\t\tdLon1=-179.99999999;\n\t\t}\n\t\tif(dLon1>=180){\n\t\t\tdLon1=179.99999999;\n\t\t}\n\t\tif(dLon2<=-180){\n\t\t\tdLon2=-179.99999999;\n\t\t}\n\t\tif(dLon2>=180){\n\t\t\tdLon2=179.99999999;\n\t\t}\n\t\t\n\t\tif(dLat1<=-90){\n\t\t\tdLat1=-89.99999999;\n\t\t}\n\t\tif(dLat1>=90){\n\t\t\tdLat1=89.99999999;\n\t\t}\n\t\tif(dLat2<=-90){\n\t\t\tdLat2=-89.99999999;\n\t\t}\n\t\tif(dLat2>=90){\n\t\t\tdLat2=89.99999999;\n\t\t}\n\t\t\n\t\t\n\t\tgcl1.setStartingGeographicPoint(dLon1, dLat1);\n\t\tgcl1.setDestinationGeographicPoint(dLon2, dLat2);\n\t\ttry{\n\t\t\treturn gcl1.getOrthodromicDistance()/1000.;\n\t\t}catch(Exception e){\n\t\t\treturn orthodromicDistance(dLat1, dLon1, dLat2, dLon2);\n\t\t}\n\t}",
"private double feetBetweenCoordinates(double latitude1, double longitude1, double latitude2, double longitude2) {\n int radiusOfEarth = 20903520; // mean radius of Earth in feet\n double deltaLat = Math.toRadians(latitude2 - latitude1); // change in latitude\n double deltaLong = Math.toRadians(longitude2 - longitude1); // change in longitude\n latitude1 = Math.toRadians(latitude1);\n latitude2 = Math.toRadians(latitude2);\n\n double varA = Math.sin(deltaLat / 2) * Math.sin(deltaLat / 2) +\n Math.cos(latitude1) * Math.cos(latitude2) *\n Math.sin(deltaLong / 2) * Math.sin(deltaLong / 2);\n double varC = 2 * Math.atan2(Math.sqrt(varA), Math.sqrt(1 - varA));\n\n return radiusOfEarth * varC;\n }",
"private int getDistance(double lat1, double lng1, double lat2, double lng2) {\n\n double earthRadius = 6371; // kilometer output\n double dLat = Math.toRadians(lat2-lat1);\n double dLng = Math.toRadians(lng2-lng1);\n double sindLat = Math.sin(dLat / 2);\n double sindLng = Math.sin(dLng / 2);\n\n double a = Math.pow(sindLat, 2) + Math.pow(sindLng, 2)\n * Math.cos(Math.toRadians(lat1)) * Math.cos(Math.toRadians(lat2));\n double c = 2 * Math.atan2(Math.sqrt(a), Math.sqrt(1-a));\n double dist = earthRadius * c;\n\n int distance = (int)dist / 20; // output distance\n return distance;\n }",
"private double distFrom(double lat1, double lng1, double lat2, double lng2) {\n\t\tdouble dist = Math.pow(lat1 - lat2, 2) + Math.pow(lng1 - lng2, 2);\n\n\t\treturn dist;\n\t}",
"private double bearing(double lata, double lona, double latb, double lonb) { \r\n return Math.atan2(Math.sin(lonb-lona)*Math.cos(latb), Math.cos(lata)*Math.sin(latb)-Math.sin(lata)*Math.cos(latb)*Math.cos(lonb-lona));\r\n }",
"private float distance(double startLat, double startLon,\n double endLat, double endLon) {\n // Based on http://www.ngs.noaa.gov/PUBS_LIB/inverse.pdf\n // using the \"Inverse Formula\" (section 4)\n int MAXITERS = 20;\n // Convert lat/long to radians\n startLat *= Math.PI / 180.0;\n endLat *= Math.PI / 180.0;\n startLon *= Math.PI / 180.0;\n endLon *= Math.PI / 180.0;\n double a = 6378137.0; // WGS84 major axis\n double b = 6356752.3142; // WGS84 semi-major axis\n double f = (a - b) / a;\n double aSqMinusBSqOverBSq = (a * a - b * b) / (b * b);\n double L = endLon - startLon;\n double A = 0.0;\n double U1 = Math.atan((1.0 - f) * Math.tan(startLat));\n double U2 = Math.atan((1.0 - f) * Math.tan(endLat));\n double cosU1 = Math.cos(U1);\n double cosU2 = Math.cos(U2);\n double sinU1 = Math.sin(U1);\n double sinU2 = Math.sin(U2);\n double cosU1cosU2 = cosU1 * cosU2;\n double sinU1sinU2 = sinU1 * sinU2;\n double sigma = 0.0;\n double deltaSigma = 0.0;\n double cosSqAlpha = 0.0;\n double cos2SM = 0.0;\n double cosSigma = 0.0;\n double sinSigma = 0.0;\n double cosLambda = 0.0;\n double sinLambda = 0.0;\n double lambda = L; // initial guess\n for (int iter = 0; iter < MAXITERS; iter++) {\n double lambdaOrig = lambda;\n cosLambda = Math.cos(lambda);\n sinLambda = Math.sin(lambda);\n double t1 = cosU2 * sinLambda;\n double t2 = cosU1 * sinU2 - sinU1 * cosU2 * cosLambda;\n double sinSqSigma = t1 * t1 + t2 * t2; // (14)\n sinSigma = Math.sqrt(sinSqSigma);\n cosSigma = sinU1sinU2 + cosU1cosU2 * cosLambda; // (15)\n sigma = Math.atan2(sinSigma, cosSigma); // (16)\n double sinAlpha = (sinSigma == 0) ? 0.0 :\n cosU1cosU2 * sinLambda / sinSigma; // (17)\n cosSqAlpha = 1.0 - sinAlpha * sinAlpha;\n cos2SM = (cosSqAlpha == 0) ? 0.0 :\n cosSigma - 2.0 * sinU1sinU2 / cosSqAlpha; // (18)\n double uSquared = cosSqAlpha * aSqMinusBSqOverBSq; // defn\n A = 1 + (uSquared / 16384.0) * // (3)\n (4096.0 + uSquared *\n (-768 + uSquared * (320.0 - 175.0 * uSquared)));\n double B = (uSquared / 1024.0) * // (4)\n (256.0 + uSquared *\n (-128.0 + uSquared * (74.0 - 47.0 * uSquared)));\n double C = (f / 16.0) *\n cosSqAlpha *\n (4.0 + f * (4.0 - 3.0 * cosSqAlpha)); // (10)\n double cos2SMSq = cos2SM * cos2SM;\n deltaSigma = B * sinSigma * // (6)\n (cos2SM + (B / 4.0) *\n (cosSigma * (-1.0 + 2.0 * cos2SMSq) -\n (B / 6.0) * cos2SM *\n (-3.0 + 4.0 * sinSigma * sinSigma) *\n (-3.0 + 4.0 * cos2SMSq)));\n lambda = L +\n (1.0 - C) * f * sinAlpha *\n (sigma + C * sinSigma *\n (cos2SM + C * cosSigma *\n (-1.0 + 2.0 * cos2SM * cos2SM))); // (11)\n double delta = (lambda - lambdaOrig) / lambda;\n if (Math.abs(delta) < 1.0e-12) {\n break;\n }\n }\n float distance = (float) (b * A * (sigma - deltaSigma));\n return distance;\n }",
"public static double distCalc(double long1, double long2, double lat1,\n\t\t\tdouble lat2) {\n\t\tdouble theta = long1 - long2;\n\t\tdouble dist = Math.sin(deg2rad(lat1)) * Math.sin(deg2rad(lat2))\n\t\t\t\t+ Math.cos(deg2rad(lat1)) * Math.cos(deg2rad(lat2))\n\t\t\t\t* Math.cos(deg2rad(theta));\n\t\tdist = rad2deg(Math.acos(dist));\n\t\treturn (dist * 60 * 1.1515);\n\t}",
"public double arcDistance(double lat1, double lon1, double lat2, double lon2) {\n return UmxSloppyMath.haversinMeters(lat1, lon1, lat2, lon2);\n }",
"public double GetDistanceBetweenTwoGPSPoints(double lat1,\n double lat2, double lon1,\n double lon2, gpsUnits unit) {\n\n double lat1Radians = Math.toRadians(lat1);\n double lat2Radians = Math.toRadians(lat2);\n double deltaLatInRadians = Math.toRadians(lat2 - lat1);\n double deltaLonInRadians = Math.toRadians(lon2 - lon1);\n\n double a;\n a = Math.sin(deltaLatInRadians / 2) * Math.sin(deltaLatInRadians / 2) +\n Math.cos(lat1Radians) * Math.cos(lat2Radians) *\n Math.sin(deltaLonInRadians / 2) * Math.sin(deltaLonInRadians / 2);\n double c = 2 * Math.atan2(Math.sqrt(a), Math.sqrt(1 - a));\n\n double distance = 0;\n\n switch (unit) {\n case KILOMETERS:\n distance = c * R_IN_KILOMETERS;\n break;\n case NAUTICAL_MILES:\n distance = c * R_IN_NAUTICAL_MILES;\n break;\n case MILES:\n distance = c * R_IN_MILES;\n break;\n }\n\n return distance;\n }",
"static double geocentricToGeodetic(double geocentricLatitude) {\n return (Math.atan(Math.tan(geocentricLatitude) / (1.0 - E_ECC_SQUARED)));\n }",
"public double calcDist(double lat2, double lon2, ArrayList<Record> cCentres)\n {\n double dist = 0;\n if (lat1==lat2 && lon1==lon2)\n dist = 0;\n else {\n double theta = lon1 - lon2;\n dist = Math.sin(Math.toRadians(lat1)) * Math.sin(Math.toRadians(lat2)) + Math.cos(Math.toRadians(lat1)) * Math.cos(Math.toRadians(lat2)) * Math.cos(Math.toRadians(theta));\n dist = Math.acos(dist);\n dist = Math.toDegrees(dist);\n dist = dist * 60 * 1.1515;\n dist = dist * 1.609344; //km\n }\n return (dist);\n }",
"private static double polarTriangleArea(double tan1, double lng1, double tan2, double lng2) {\n double deltaLng = lng1 - lng2;\n double t = tan1 * tan2;\n return 2 * atan2(t * sin(deltaLng), 1 + t * cos(deltaLng));\n }",
"private static double get_distance ( String one, String two){\n String temp[] = one.split(\" \");\n double lat1 = Double.parseDouble(temp[0]);\n double long1 = Double.parseDouble(temp[1]);\n\n String temp2[] = two.split(\" \");\n double lat2 = Double.parseDouble(temp2[0]);\n double long2 = Double.parseDouble(temp2[1]);\n\n// Get distance between two lats and two lans\n double latDistance = Math.toRadians(lat1 - lat2);\n double lngDistance = Math.toRadians(long1 - long2);\n\n// Step 1\n double a = (Math.sin ( latDistance / 2 ) * Math.sin (latDistance / 2)) +\n (Math.cos ( Math.toRadians(lat1)) * Math.cos(Math.toRadians(lat2)) )\n * ( Math.sin (lngDistance /2 ) * Math.sin(lngDistance / 2) );\n// Step 2\n double c = ( 2 * (Math.atan2( Math.sqrt(a), Math.sqrt(1-a))));\n// Step 3\n double d = ( EARTH_RADIUS * c );\n return d;\n }",
"private Double euclidean(LatitudeLongitude point1, LatitudeLongitude point2) {\n return Double.valueOf(Math.sqrt(Math.pow(point1.getLatitude() - point2.getLatitude(), 2)\n + Math.pow(point1.getLongitude() - point2.getLongitude(), 2)));\n }",
"@SuppressLint(\"UseValueOf\")\n\tpublic static double distFrom(double lat1, double lng1, double lat2, double lng2) {\n\t double earthRadius = 3958.75;\n\t double dLat = Math.toRadians(lat2-lat1);\n\t double dLng = Math.toRadians(lng2-lng1);\n\t double a = Math.sin(dLat/2) * Math.sin(dLat/2) +\n\t Math.cos(Math.toRadians(lat1)) * Math.cos(Math.toRadians(lat2)) *\n\t Math.sin(dLng/2) * Math.sin(dLng/2);\n\t double c = 2 * Math.atan2(Math.sqrt(a), Math.sqrt(1-a));\n\t double dist = earthRadius * c;\n\n\t int meterConversion = 1609;\n\t \n\t return new Double(dist * meterConversion).doubleValue();\n\t }",
"public double Angle2D(double x1, double y1, double x2, double y2)\n {\n double dtheta,theta1,theta2;\n\n theta1 = Math.atan2(y1,x1);\n theta2 = Math.atan2(y2,x2);\n dtheta = theta2 - theta1;\n while (dtheta > Math.PI)\n dtheta -= 2*Math.PI;\n while (dtheta < -Math.PI)\n dtheta += 2*Math.PI;\n\n return(dtheta);\n}",
"public double calcDistanceHaversine(double lat1, double lon1, double lat2, double lon2) {\n\n double latDistance = Math.toRadians(lat2 - lat1);\n double lonDistance = Math.toRadians(lon2 - lon1);\n\n double a = Math.sin(latDistance / 2) * Math.sin(latDistance / 2) +\n Math.cos(Math.toRadians(lat1)) * Math.cos(Math.toRadians(lat2)) *\n Math.sin(lonDistance / 2) * Math.sin(lonDistance / 2);\n\n double c = 2 * Math.atan2(Math.sqrt(a), Math.sqrt(1 - a));\n double distanceInMeters = EARTH_RADIUS * c * ONE_KM; // convert to meters\n\n distanceInMeters = Math.pow(distanceInMeters, 2);\n\n return Math.sqrt(distanceInMeters) / ONE_KM;\n }",
"private static double angulo(Point2D.Double p2,Point2D.Double p1){\n \t\n return Math.atan2(p2.x - p1.x, p2.y - p1.y);\n }",
"private static double distance(double lat1, double lat2, double lon1, double lon2,\n\t double el1, double el2) {\n\n\t final int R = 6371; // Radius of the earth\n\n\t Double latDistance = deg2rad(lat2 - lat1);\n\t Double lonDistance = deg2rad(lon2 - lon1);\n\t Double a = Math.sin(latDistance / 2) * Math.sin(latDistance / 2)\n\t + Math.cos(deg2rad(lat1)) * Math.cos(deg2rad(lat2))\n\t * Math.sin(lonDistance / 2) * Math.sin(lonDistance / 2);\n\t Double c = 2 * Math.atan2(Math.sqrt(a), Math.sqrt(1 - a));\n\t double distance = R * c * 1000; // convert to meters\n\n\t double height = el1 - el2;\n\t distance = Math.pow(distance, 2) + Math.pow(height, 2);\n\t return Math.sqrt(distance);\n\t}",
"public double betweenAngle(Coordinates a, Coordinates b, Coordinates origin);",
"private static double distance(double lat1, double lon1, double lat2, double lon2, String unit) {\n double theta = lon1 - lon2;\n double dist = Math.sin(deg2rad(lat1)) * Math.sin(deg2rad(lat2)) + Math.cos(deg2rad(lat1)) * Math.cos(deg2rad(lat2)) * Math.cos(deg2rad(theta));\n dist = Math.acos(dist);\n dist = rad2deg(dist);\n dist = dist * 60 * 1.1515;\n if (unit.equals(\"K\")) {\n dist = dist * 1.609344;\n } else if (unit.equals(\"N\")) {\n dist = dist * 0.8684;\n }\n //default miles\n return (dist);\n }",
"private static Coord findCoordinate(Coord p0, Coord p1, Coord p2, double r0, double r1, double r2){\r\n\r\n\tdouble x0, y0, x1, y1, x2, y2;\r\n\tx0 = p0.getX(); y0 = p0.getY();\r\n\tx1 = p1.getX(); y1 = p1.getY();\r\n\tx2 = p2.getX(); y2 = p2.getY();\r\n\t//core.Debug.p(\"x0:\" + x0 + \",y0:\" + y0 + \",r0:\" + r0);\r\n\t//core.Debug.p(\"x1:\" + x1 + \",y1:\" + y1 + \",r1:\" + r1);\r\n\t//core.Debug.p(\"x2:\" + x2 + \",y2:\" + y2 + \",r2:\" + r2);\r\n\tdouble a, dx, dy, d, h, rx, ry;\r\n\tdouble point2_x, point2_y;\r\n\r\n\t/* dx and dy are the vertical and horizontal distances between\r\n\t * the circle centers.\r\n\t */\t\r\n\tdx = x1 - x0;\r\n\tdy = y1 - y0;\r\n\r\n\t/* Determine the straight-line distance between the centers. */\r\n\td = Math.sqrt((dy*dy) + (dx*dx));\r\n\r\n\t/* Check for solvability. */\r\n\tif (d > (r0 + r1)){\r\n\t\t/* no solution. circles do not intersect. */\r\n\t\t//core.Debug.p(\"no solution1\");\r\n\t\treturn null;\r\n\t}\r\n\tif (d < Math.abs(r0 - r1)){\r\n\t\t/* no solution. one circle is contained in the other */\r\n\t\t//core.Debug.p(\"no solution2\");\r\n\t\treturn null;\r\n\t}\r\n\r\n\t/* 'point 2' is the point where the line through the circle\r\n\t * intersection points crosses the line between the circle\r\n\t * centers.\r\n\t */\r\n\r\n\t/* Determine the distance from point 0 to point 2. */\r\n\ta = ((r0*r0) - (r1*r1) + (d*d)) / (2.0 * d) ;\r\n\r\n\t/* Determine the coordinates of point 2. */\r\n\tpoint2_x = x0 + (dx * a/d);\r\n\tpoint2_y = y0 + (dy * a/d);\r\n\r\n\t/* Determine the distance from point 2 to either of the\r\n\t * intersection points.\r\n\t */\t\r\n\th = Math.sqrt((r0*r0) - (a*a));\r\n\r\n\t/* Now determine the offsets of the intersection points from\r\n\t * point 2.\r\n\t */\r\n\trx = -dy * (h/d);\r\n\try = dx * (h/d);\r\n\r\n\t/* Determine the absolute intersection points. */\r\n\tdouble intersectionPoint1_x = point2_x + rx;\r\n\tdouble intersectionPoint2_x = point2_x - rx;\r\n\tdouble intersectionPoint1_y = point2_y + ry;\r\n\tdouble intersectionPoint2_y = point2_y - ry;\r\n\r\n\t/* Lets determine if circle 3 intersects at either of the above intersection points. */\r\n\tdx = intersectionPoint1_x - x2;\r\n\tdy = intersectionPoint1_y - y2;\r\n\tdouble d1 = Math.sqrt((dy*dy) + (dx*dx));\r\n\r\n\tdx = intersectionPoint2_x - x2;\r\n\tdy = intersectionPoint2_y - y2;\r\n\tdouble d2 = Math.sqrt((dy*dy) + (dx*dx));\r\n\r\n\t//core.Debug.p(\"d1: \" + d1 + \", d2: \" + d2 + \", r2: \" + r2);\r\n\t//core.Debug.p(\"diff1: \" + Math.abs(d1-r2));\r\n\t//core.Debug.p(\"point1: (\" + intersectionPoint1_x + \", \" + intersectionPoint1_y + \")\");\r\n\t//core.Debug.p(\"diff2: \" + Math.abs(d2-r2));\r\n\t//core.Debug.p(\"point2: (\" + intersectionPoint2_x + \", \" + intersectionPoint2_y + \")\");\r\n\r\n\r\n\tif(Math.abs(d1 - r2) < EPSILON) {\r\n\t\t//core.Debug.p(\"point: (\" + intersectionPoint1_x + \", \" + intersectionPoint1_y + \")\");\r\n\t\treturn new Coord(intersectionPoint1_x, intersectionPoint1_y);\r\n\t}\r\n\telse if(Math.abs(d2 - r2) < EPSILON) {\r\n\t\t//core.Debug.p(\"point: (\" + intersectionPoint2_x + \", \" + intersectionPoint2_y + \")\");\r\n\t\treturn new Coord(intersectionPoint2_x, intersectionPoint2_y);}\r\n\telse {\r\n\t\t//core.Debug.p(\"no intersection\");\r\n\t\treturn null;\r\n\t}\r\n}",
"public static double distance(double latit1, double longit1, double latit2, double longit2)\n\t{\n\t\tdouble latitude1 = Math.toRadians(latit1); //latitude of the first location\n\t\tdouble latitude2 = Math.toRadians(latit2);\t//latitude of the second location\n\t\t\n\t\tdouble longitude1 = Math.toRadians(longit1); //longitude of the first location\n\t\tdouble longitude2 = Math.toRadians(longit2); //longitude of the second location\n\t\t\n\t\tdouble radiusOfEarth = 6371; //km\n\t\tdouble distance;\n\t\t\n\t\tdouble sinSquaredLatitude = Math.pow(Math.sin((latitude1-latitude2)/2),2);\n\t\tdouble cosCalculations = Math.cos(latitude1)*Math.cos(latitude2);\n\t\tdouble sinSquaredLongitude = Math.pow(Math.sin((longitude1-longitude2)/2),2);\n\t\t\n\t\tdistance = 2*radiusOfEarth * Math.asin(Math.sqrt(sinSquaredLatitude + cosCalculations * sinSquaredLongitude));\n\t\t\n\t\t//distance = Math.round(distance);\n\t\treturn distance;\n\t\t\n\t\t//System.out.println(\"Distance is: \"+distance+\"km\");\n\t}",
"public static double CalculateDistance(double latitude1, double longitude1,\n\t\t\tdouble latitude2, double longitude2) {\n\t\t/*\n\t\t * Haversine formula: A = sin²(Δlat/2) +\n\t\t * cos(lat1).cos(lat2).sin²(Δlong/2) C = 2.atan2(√a, √(1−a)) D =\n\t\t * R.c R = radius of earth, 6371 km. All angles are in radians\n\t\t */\n\n\t\tdouble deltaLatitude = Math.toRadians(Math.abs(latitude1 - latitude2));\n\t\tdouble deltaLongitude = Math.toRadians(Math\n\t\t\t\t.abs(longitude1 - longitude2));\n\t\tdouble latitude1Rad = Math.toRadians(latitude1);\n\t\tdouble latitude2Rad = Math.toRadians(latitude2);\n\n\t\tdouble a = Math.pow(Math.sin(deltaLatitude / 2), 2)\n\t\t\t\t+ (Math.cos(latitude1Rad) * Math.cos(latitude2Rad) * Math.pow(\n\t\t\t\t\t\tMath.sin(deltaLongitude / 2), 2));\n\n\t\tdouble c = 2 * Math.atan2(Math.sqrt(a), Math.sqrt(1 - a));\n\n\t\treturn 6371 * c * 1000; // Distance in meters\n\n\t}",
"public int distanceInMeters (double degLon1, double degLat1\n , double degLon2, double degLat2) {\n\n double radLonDelta = Math.toRadians(degLon2-degLon1);\n double radLat1 = Math.toRadians(degLat1);\n double radLat2 = Math.toRadians(degLat2);\n\n double d = issAverageOrbit\n *Math.acos(Math.sin(radLat1)\n *Math.sin(radLat2)\n +Math.cos(radLat1)\n *Math.cos(radLat2)\n *Math.cos(radLonDelta));\n return (int) Math.round(d);\n }",
"public double distancia2(GPS a2,GPS a3){\n return this.distancia(a2)+a2.distancia(a3);\n }",
"private double distantziaKalkulatu() {\r\n\t\tdouble lurrarenRadioa = 6371;// kilometrotan Lurraren radioa\r\n\t\tdouble dLat = Math.toRadians(terLat - latitudea); //\r\n\t\tdouble dLng = Math.toRadians(termLong - longitudea);\r\n\t\tdouble sindLat = Math.sin(dLat / 2);\r\n\t\tdouble sindLng = Math.sin(dLng / 2);\r\n\t\tdouble va1 = Math.pow(sindLat, 2)\r\n\t\t\t\t+ Math.pow(sindLng, 2) * Math.cos(Math.toRadians(terLat)) * Math.cos(Math.toRadians(latitudea));\r\n\t\tdouble va2 = 2 * Math.atan2(Math.sqrt(va1), Math.sqrt(1 - va1));\r\n\t\tdouble distancia = lurrarenRadioa * va2;\r\n\r\n\t\treturn distancia;\r\n\t}",
"static double geodeticToGeocentric(double geodeticLatitude) {\n return (Math.atan((1.0 - E_ECC_SQUARED) * Math.tan(geodeticLatitude)));\n }",
"private double haversineDist(CityNode a, CityNode b) {\n\n double distLat = Math.toRadians(a.getLat() - b.getLat());\n double distLong = Math.toRadians(a.getLong() - b.getLong());\n\n // Convert latitudes to radians\n double startLat = Math.toRadians(b.getLat());\n double endLat = Math.toRadians(a.getLat());\n\n double calc = Math.pow(Math.sin(distLat / 2), 2)\n + Math.pow(Math.sin(distLong / 2), 2) * Math.cos(startLat) * Math.cos(endLat);\n double calc2 = 2 * Math.asin(Math.sqrt(calc));\n return 3959 * calc2;\n }",
"public double getDistanceBetween_2points(double initialLat, double initialLon, double finalLat, double finalLon){\n\n //https://stackoverflow.com/questions/8049612/calculating-distance-between-two-geographic-locations\n Location startPoint = new Location(\"initial\");\n startPoint.setLatitude(initialLat);\n startPoint.setLongitude(initialLon);\n\n Location endPoint = new Location(\"final\");\n endPoint.setLatitude(finalLat);\n endPoint.setLongitude(finalLon);\n\n double distance = startPoint.distanceTo(endPoint);\n Log.d(TAG, \"getDistanceBetween_2points: \" + distance);\n\n return distance;\n\n }",
"public double measure(double lat1, double lon1, double lat2, double lon2){ // generally used geo measurement function\n\t\tdouble R = 6378.137; // Radius of earth in KM\n\t\tdouble dLat = (lat2 - lat1) * Math.PI / 180;\n\t\tdouble dLon = (lon2 - lon1) * Math.PI / 180;\n\t\tdouble a = Math.sin(dLat/2) * Math.sin(dLat/2) + Math.cos(lat1 * Math.PI / 180) * Math.cos(lat2 * Math.PI / 180) * Math.sin(dLon/2) * Math.sin(dLon/2);\n\t\tdouble c = 2 * Math.atan2(Math.sqrt(a), Math.sqrt(1-a));\n\t\tdouble d = R * c;\n\t return d * 1000; // meters\n\t}",
"private double haversineDist(CityNode a, CityNode b) {\n\n double distLat = Math.toRadians(a.getLat() - b.getLat());\n double distLong = Math.toRadians(a.getLong() - b.getLong());\n\n // Convert latitudes to radians\n double startLat = Math.toRadians(b.getLat());\n double endLat = Math.toRadians(a.getLat());\n\n double calc = Math.pow(Math.sin(distLat / 2), 2)\n + Math.pow(Math.sin(distLong / 2), 2) * Math.cos(startLat) * Math.cos(endLat);\n double calc2 = 2 * Math.asin(Math.sqrt(calc));\n return earthRadius * calc2;\n }",
"public static double measureDistance(double lat1, double lon1, double lat2, double lon2){ // generally used geo measurement function\n\t\tdouble R = 6378.137; // Radius of earth in KM\n\t\tdouble dLat = (lat2 - lat1) * Math.PI / 180;\n\t\tdouble dLon = (lon2 - lon1) * Math.PI / 180;\n\t\tdouble a = Math.sin(dLat/2) * Math.sin(dLat/2) +\n\t Math.cos(lat1 * Math.PI / 180) * Math.cos(lat2 * Math.PI / 180) *\n\t Math.sin(dLon/2) * Math.sin(dLon/2);\n\t\tdouble c = 2 * Math.atan2(Math.sqrt(a), Math.sqrt(1-a));\n\t\tdouble d = R * c;\n\t return d * 1000; // meters\n\t}",
"public static double getDistance(GPSPosition first, GPSPosition second) {\n\t\tdouble distance = 0;\n\t\t\n\t\tdouble latitude_distance_in_radians = \n\t\t\t\tMath.toRadians(second.getLatitude() - first.getLatitude());\n\t\tdouble longitude_distance_in_radians = \n\t\t\t\tMath.toRadians(second.getLongitude() - first.getLongitude());\n\t\t// harvesin(d / R) = harvesin(lat1 - lat2) + cos(lat1) * cos(lat2) * harvesin(lng1 - lng2);\n\t\t// harvesin(angle) = sin(angle / 2) ^ 2;\n\t\t// d = 2 * R * arcsin(sqrt(harvesin));\n\t\tdouble harvesin_diff_lat = Math.pow(Math.sin(latitude_distance_in_radians / 2), 2);\n\t\tdouble harvesin_diff_lng = Math.pow(Math.sin(longitude_distance_in_radians / 2), 2);\n\t\tdouble cos_lat1 = Math.cos(Math.toRadians(first.getLatitude()));\n\t\tdouble cos_lat2 = Math.cos(Math.toRadians(second.getLatitude()));\n\t\tdouble harvesin = harvesin_diff_lat + cos_lat1 * cos_lat2 * harvesin_diff_lng;\n\n\t\tdistance = 2 * kEarthRadius * Math.atan2(Math.sqrt(harvesin), Math.sqrt(1 - harvesin));\n\t\treturn distance;\n\t}",
"private float getRadian(float x, float y) {\n float alpha = (float) Math.atan((x - mCx) / (mCy - y));\n // Quadrant\n if (x > mCx && y > mCy) {\n // 2\n alpha += Math.PI;\n } else if (x < mCx && y > mCy) {\n // 3\n alpha += Math.PI;\n } else if (x < mCx && y < mCy) {\n // 4\n alpha = (float) (2 * Math.PI + alpha);\n }\n return alpha;\n }",
"static double angle(CvPoint a, CvPoint b, CvPoint c) {\n\t\t\n\t\tCvPoint vecAC = new CvPoint(a.x() - c.x(), a.y() - c.y());\n\t\tCvPoint vecBC = new CvPoint(b.x() - c.x(), b.y() - c.y());\n\n\t\tdouble q = (vecAC.x() * vecBC.x()) + (vecAC.y() * vecBC.y());\n\t\tdouble ac = Math.sqrt(Math.pow(vecAC.x(), 2) + Math.pow(vecAC.y(), 2));\n\t\tdouble cd = Math.sqrt(Math.pow(vecBC.x(), 2) + Math.pow(vecBC.y(), 2));\n\n\t\tdouble ang = q / Math.abs((ac * cd));\n\t\tdouble rad = Math.acos(ang);\n\t\tdouble rad2 = Math.toDegrees(rad);\n\n\t\treturn rad2;\n\t}",
"public double findRotation(Point a, Point b) {\n\t\t// Find rotation in radians using acttan2.\n\t\tdouble rad = Math.atan2(a.y - b.y, a.x - b.x);\n\n\t\t// Remove negative rotation.\n\t\tif (rad < 0) {\n\t\t\trad += 2 * Math.PI;\n\t\t}\n\t\t\n\t\t// Convert the rotation to degrees.\n\t\treturn rad * (180 / Math.PI);\n\t}",
"public static double distanceInMeter(double lat1, double long1, double lat2, double long2) {\n\t\t// Compute difference of latitude, longitude and convert to radians\n\t\tdouble diffLat = Math.toRadians(lat2 - lat1);\n\t\tdouble diffLong = Math.toRadians(long2 - long1);\n\t\t\n\t\t// Convert single latitude values to radiant\n\t\tlat1 = Math.toRadians(lat1);\n\t\tlat2 = Math.toRadians(lat2);\n\t\t\n\t\tdouble diffLatSin = Math.sin(diffLat/2);\n\t\tdouble diffLongSin = Math.sin(diffLong/2);\n\t\t\n\t\tdouble a = \tdiffLatSin * diffLatSin +\n\t\t\t\t\tdiffLongSin * diffLongSin *\n\t\t\t\t\tMath.cos(lat1) * Math.cos(lat2);\n\t\t\n\t\tdouble greatCircleDistanceRad = 2 * Math.atan2(Math.sqrt(a), Math.sqrt(1 - a));\n\t\t\n\t\treturn EARTH_RADIUS * greatCircleDistanceRad;\n\t}",
"private double distanceResult(double preLng, double preLat, double nextLng, double nextLat) {\n\t\treturn Math.sqrt((preLng - nextLng) * (preLng - nextLng) + (preLat - nextLat) * (preLat - nextLat));\n\t}",
"public float calculateAngle(float x1, float y1, float x2, float y2) {\n float difX = x1 - x2;\n float difY = y1 - y2;\n float angle = (float)(180.0 / Math.PI * Math.atan2(difY, difX));\n if(angle < 0) {\n return 360 + angle;\n }\n return angle;\n }",
"private Integer getDistance(double lat1, double lon1, double lat2, double lon2) {\n Location locationA = new Location(\"Source\");\n locationA.setLatitude(lat1);\n locationA.setLongitude(lon1);\n Location locationB = new Location(\"Destination\");\n locationB.setLatitude(lat2);\n locationB.setLongitude(lon2);\n distance = Math.round(locationA.distanceTo(locationB));\n return distance;\n }",
"public static double getOrient(Position p1, Position p2){\n\t\tdouble lat1 = p1.getLat();\n\t\tdouble lon1 = p1.getLon();\n\t\tdouble lat2 = p2.getLat();\n\t\tdouble lon2 = p2.getLon();\n\t\t\n\t\tdouble dLat = Math.toRadians(lat2-lat1);\n\t\tdouble dLon = Math.toRadians(lon2-lon1);\n\t\tlat1 = Math.toRadians(lat1);\n\t\tlat2 = Math.toRadians(lat2);\n\n\t\t// following code is from http://www.movable-type.co.uk/scripts/latlong.html\n\t\tdouble y = Math.sin(dLon) * Math.cos(lat2);\n\t\tdouble x = Math.cos(lat1)*Math.sin(lat2) - Math.sin(lat1)*Math.cos(lat2)*Math.cos(dLon);\n\t\tdouble orient = Math.toDegrees(Math.atan2(y, x));\n\t\t//converting orient from a scale of -180 .. + 180 to 0-359 degrees\n\t\tdouble orient360 = (orient + 360) % 360;\n\t\treturn orient360;\n\t}",
"private double d(Point a, Point b){\n\t\treturn Math.sqrt(Math.pow(b.getX()-a.getX(),2) + Math.pow(a.getY() - b.getY(), 2));\r\n\t}",
"private double calculateDis(double lata, double lona, double latb, double lonb){\n\t\tdouble lon2latRatio = Math.cos(lata * 3.14159 / 180.0);\n\t\tdouble milesperDegreeLat = 69.0;\n\t\tdouble milesperDegreeLon = milesperDegreeLat * lon2latRatio;\n\t\tdouble distance = 0.0;\n\t\tdistance = Math.sqrt((milesperDegreeLat * (latb - lata))\n\t\t\t\t* (milesperDegreeLat * (latb - lata))\n\t\t\t\t+ (milesperDegreeLon * (lonb - lona))\n\t\t\t\t* (milesperDegreeLon * (lonb - lona)));\n\t\treturn distance;\n\t}",
"public static double distance(Position p1, Position p2){\n\t\t\n\t\tdouble lat1 = p1.getLat(); \n\t\tdouble lon1 = p1.getLon();\n\t\tdouble lat2 = p2.getLat(); \n\t\tdouble lon2 = p2.getLon();\n\t\t\n\t\tdouble r = 6371; // km\n\t\tdouble dLat = Math.toRadians(lat2-lat1);\n\t\tdouble dLon = Math.toRadians(lon2-lon1);\n\t\tdouble nlat1 = Math.toRadians(lat1);\n\t\tdouble nlat2 = Math.toRadians(lat2);\n\n\t\tdouble a = Math.sin(dLat/2) * Math.sin(dLat/2) + \n\t\t Math.sin(dLon/2) * Math.sin(dLon/2) * Math.cos(nlat1) * Math.cos(nlat2); \n\t\tdouble c = 2 * Math.atan2(Math.sqrt(a), Math.sqrt(1-a)); \n\t\tdouble d = r * c;\n\t\treturn d;\n\t\t\n\t}",
"private double calculateDistance(Circle point1, Circle point2) {\r\n double x = point1.getCenterX() - point2.getCenterX();\r\n double y = point1.getCenterY() - point2.getCenterY();\r\n\r\n return Math.sqrt(x*x + y*y);\r\n }",
"public double getAngle(float x1, float y1, float x2, float y2) {\n\n double rad = Math.atan2(y1-y2,x2-x1) + Math.PI;\n return (rad*180/Math.PI + 180)%360;\n }",
"public static Double getDistanceFromLatLonInKm(Double firstPointLatitude,\n Double firstPointLongitude,\n Double secondPointLatitude,\n Double secondPointLongitude) {\n final int radiusOfEarth = 6371;\n Double latitudeDistance = Math.toRadians(secondPointLatitude - firstPointLatitude);\n Double longitudeDistance = Math.toRadians(secondPointLongitude - firstPointLongitude);\n\n double a = Math.sin(latitudeDistance / 2) * Math.sin(latitudeDistance / 2)\n + Math.cos(Math.toRadians(firstPointLatitude)) * Math.cos(Math.toRadians(secondPointLatitude))\n * Math.sin(longitudeDistance / 2) * Math.sin(longitudeDistance / 2);\n\n double c = 2 * Math.atan2(Math.sqrt(a), Math.sqrt(1 - a));\n // convert to meters\n\n double distnce = radiusOfEarth * c * 1000;\n distnce = Math.pow(distnce, 2) + Math.pow(0.0, 2);\n\n return Math.sqrt(distnce);\n }",
"static double radiusOfCircumcirle(PointDouble a, PointDouble b, PointDouble c) {\n return radiusOfCircumcirle(dist(a, b), dist(b, c), dist(c, a));\n }",
"public double absbearing(double x1, double y1, double x2, double y2) {\r\n\t\tdouble xo = x2 - x1;\r\n\t\tdouble yo = y2 - y1;\r\n\t\tdouble h = getRange(x1, y1, x2, y2);\r\n\t\tif (xo > 0 && yo > 0) {\r\n\t\t\treturn Math.asin(xo / h);\r\n\t\t}\r\n\t\tif (xo > 0 && yo < 0) {\r\n\t\t\treturn Math.PI - Math.asin(xo / h);\r\n\t\t}\r\n\t\tif (xo < 0 && yo < 0) {\r\n\t\t\treturn Math.PI + Math.asin(-xo / h);\r\n\t\t}\r\n\t\tif (xo < 0 && yo > 0) {\r\n\t\t\treturn 2.0 * Math.PI - Math.asin(-xo / h);\r\n\t\t}\r\n\t\treturn 0;\r\n\t}",
"public double getDistance() {\n\n final int R = 6371; // Radius of the earth\n double lat1 = latitude;\n double lon1 = longitude;\n double lat2 = 41.917715; //lat2, lon2 is location of St.Charles, IL\n double lon2 = -88.266027;\n double el1=0,el2 = 0;\n double latDistance = Math.toRadians(lat2 - lat1);\n double lonDistance = Math.toRadians(lon2 - lon1);\n double a = Math.sin(latDistance / 2) * Math.sin(latDistance / 2)\n + Math.cos(Math.toRadians(lat1)) * Math.cos(Math.toRadians(lat2))\n * Math.sin(lonDistance / 2) * Math.sin(lonDistance / 2);\n double c = 2 * Math.atan2(Math.sqrt(a), Math.sqrt(1 - a));\n double distance = R * c * 1000; // convert to meters\n\n double height = el1 - el2;\n\n distance = Math.pow(distance, 2) + Math.pow(height, 2);\n\n return Math.sqrt(distance);\n }",
"public double calculateHeadingRadians(){\r\n if(coordinateHistory.size() > 2){\r\n GPSCoordinate firstPoint = coordinateHistory.get(coordinateHistory.size() - 2);\r\n GPSCoordinate secondPoint = coordinateHistory.get(coordinateHistory.size() - 1);\r\n \r\n if(!firstPoint.compareTo(secondPoint)){\r\n double latA = firstPoint.getLatitude();\r\n double longA = firstPoint.getLongitude();\r\n double latB = secondPoint.getLatitude();\r\n double longB = secondPoint.getLongitude();\r\n\r\n double X = Math.cos(latB) * Math.sin(longB - longA);\r\n double Y = (Math.cos(latA) * Math.sin(latB)) - (Math.sin(latA) * Math.cos(latB) * Math.cos(longB - longA));\r\n\r\n headingRadians = - Math.atan2(X, Y);\r\n return headingRadians;\r\n }else{\r\n return headingRadians;\r\n }\r\n }else{\r\n return headingRadians;\r\n }\r\n }",
"private double[][] circlepoints2(double x1, double y1, double x2, double y2, double rad1, double rad2)\n {\n double[][]pos = new double[2][2];\n\n double t1 = (y1 - y2) / (x2 - x1);\n double t2 = (((((x2 * x2 - x1 * x1) + y2 * y2) - y1 * y1) + rad1 * rad1) - rad2 * rad2) /(2.0 * x2 - 2.0 * x1);\n double a_circ = (t1*t1 + 1.0);\n double b_circ = 2.0 * ((t1 * t2 - t1 * x1) - y1);\n double c_circ = (t2*t2 - 2*t2*x1 + x1*x1 + y1*y1 - rad1*rad1);\n\n //y-Werte\n pos[0][1] = (-b_circ + Math.sqrt(b_circ*b_circ - 4 * a_circ*c_circ)) / (2 * a_circ); //y1\n pos[1][1] = (-b_circ - Math.sqrt(b_circ*b_circ - 4 * a_circ*c_circ)) / (2 * a_circ); //y2\n\n //x-Werte\n pos[0][0] = t1 * pos[0][1] + t2; //x1\n pos[1][0] = t1 * pos[1][1] + t2; //x2\n\n return pos;\n }",
"public double calculateDistanceBetween(Location A, Location B){\n double distance; //http://www.movable-type.co.uk/scripts/latlong.html\n double earthsRadius;\n if(unitSelect){\n earthsRadius = 6372.8;\n }\n else{\n earthsRadius = 3959.87433;\n }\n double latARadians = Math.toRadians(A.getDblLatitude());\n double latBRadians = Math.toRadians(B.getDblLatitude());\n double changeInLat = Math.toRadians(B.getDblLatitude() - A.getDblLatitude());\n double changeInLong = Math.toRadians((B.getDblLongitude() - A.getDblLongitude()));\n\n double a = Math.sin(changeInLat/2) * Math.sin(changeInLat/2)\n + Math.cos(latARadians) * Math.cos(latBRadians)\n * Math.sin(changeInLong/2) * Math.sin(changeInLong/2);\n double c = 2 * Math.atan2(Math.sqrt(a), Math.sqrt(1-a));\n\n distance = (earthsRadius * c);\n\n return distance;\n }",
"double[] destination(double lata, double lona, double dist, double brng) { \r\n double latb = Math.asin(Math.sin(lata)*Math.cos(dist/6371) + Math.cos(lata)*Math.sin(dist/6371)*Math.cos(brng));\r\n double lonb = lona+Math.atan2(Math.sin(brng)*Math.sin(dist/6371)*Math.cos(lata), Math.cos(dist/6371)-Math.sin(lata)*Math.sin(latb));\r\n return new double[]{180*latb/Math.PI, 180*lonb/Math.PI};\r\n }",
"public double calculateDistance(MapLocation a, MapLocation b) {\r\n\t\treturn Math.sqrt((double) ( Math.pow((b.x - a.x),2) + Math.pow((b.y - a.y),2) ));\r\n\t}",
"public double getCircunference(){\n return 2.0 * radius * Math.PI; \n }",
"private double eculidean(double x, double x1, double y, double y1) {\n\t\treturn Math.sqrt(Math.pow((x - x1), 2) + Math.pow((y - y1), 2));\n\t}",
"public static int distanceBetween(double latA, double lonA, double latB, double lonB) {\n // translates degrees to radians\n latA = latA * Math.PI / 180;\n lonA = lonA * Math.PI / 180;\n latB = latB * Math.PI / 180;\n lonB = lonB * Math.PI / 180;\n\n double lonDelta = abs(lonA - lonB);\n double result = acos(sin(latA) * sin(latB) + cos(latA) * cos(latB) * cos(lonDelta));\n\n if (isNaN(result) || isInfinite(result)) {\n throw new ArithmeticException(\"Error in distance calculation, try different values of coordinates\");\n }\n\n return (int) (result * EARTH_RADIUS_METERS);\n }",
"public double betweenAngle(Coordinates vectorA, Coordinates vectorB);",
"private static double calculateDistance(Position A, Position B) {\n\t\tdouble x = (B.m_dLongitude - A.m_dLongitude) * Math.cos( (A.m_dLatitude + B.m_dLatitude) / 2.0d);\n\t\tdouble y = B.m_dLatitude - A.m_dLatitude;\n\t\treturn Math.sqrt(Math.pow(x, 2.0d) + Math.pow(y, 2.0d)) * 6371;\n\t}",
"public static double greatCircleDistance(double cust_lat, double cust_lon) {\n\t\t// convert degrees to radians. \n\t\tdouble lon1 = Math.toRadians(cust_lon);\n\t\tdouble lat1 = Math.toRadians(cust_lat);\n\t\tdouble lon2 = Math.toRadians(Constants.host_longtitude);\n\t\tdouble lat2 = Math.toRadians(Constants.host_latitude);\n\n\t\tdouble dlon = lon2 - lon1;\n\t\tdouble c = Math.acos(Math.sin(lat1) * Math.sin(lat2) + Math.cos(lat1) * Math.cos(lat2) * Math.cos(dlon));\n\n\t\t// Radius of earth in kilometers.\n\t\tdouble r = 6371;\n\t\t// calculate the result \n\t\treturn (c * r);\n\t}",
"public double absoluteBearing( double x1, double y1, double x2, double y2 )\n {\n double xo = x2 - x1;\n double yo = y2 - y1;\n double hyp = Point2D.distance( x1, y1, x2, y2 );\n double arcSin = Math.toDegrees( Math.asin( xo / hyp ) );\n double bearing = 0;\n\n if ( xo > 0 && yo > 0 )\n { // both pos: lower-Left\n bearing = arcSin;\n }\n else if ( xo < 0 && yo > 0 )\n { // x neg, y pos: lower-right\n bearing = 360 + arcSin; // arcsin is negative here, actually 360\n // -\n // ang\n }\n else if ( xo > 0 && yo < 0 )\n { // x pos, y neg: upper-left\n bearing = 180 - arcSin;\n }\n else if ( xo < 0 && yo < 0 )\n { // both neg: upper-right\n bearing = 180 - arcSin; // arcsin is negative here, actually 180\n // +\n // ang\n }\n\n return bearing;\n }",
"static boolean pointInCircumcircle2(PointDouble a, PointDouble b, PointDouble c, PointDouble p) {\n return ((a.x - p.x) * (b.y - p.y) * ((c.x - p.x) * (c.x - p.x) + (c.y - p.y) * (c.y - p.y)) +\n (a.y - p.y) * ((b.x - p.x) * (b.x - p.x) + (b.y - p.y) * (b.y - p.y)) * (c.x - p.x) +\n ((a.x - p.x) * (a.x - p.x) + (a.y - p.y) * (a.y - p.y)) * (b.x - p.x) * (c.y - p.y) -\n ((a.x - p.x) * (a.x - p.x) + (a.y - p.y) * (a.y - p.y)) * (b.y - p.y) * (c.x - p.x) -\n (a.y - p.y) * (b.x - p.x) * ((c.x - p.x) * (c.x - p.x) + (c.y - p.y) * (c.y - p.y)) -\n (a.x - p.x) * ((b.x - p.x) * (b.x - p.x) + (b.y - p.y) * (b.y - p.y)) * (c.y - p.y)) > 0.0;\n }",
"private static double getDistance(final WayNodeOSM a, final WayNodeOSM b) {\n \t\tdouble latA = a.getLatitude()/180*Math.PI;\n \t\tdouble latB = b.getLatitude()/180*Math.PI;\n \t\tdouble lonDif = (b.getLongitude() - a.getLongitude())/180*Math.PI;\n \t\treturn (Math.acos((Math.sin(latA) * Math.sin(latB)) + (Math.cos(latA) * Math.cos(latB) * Math.cos(lonDif))) * 6367500);\n \t}",
"private static double calculateSekante(double left, double right) {\n\n\t\t// if there was only a small change in angle , should be unnecessary\n\t\tif (Math.abs(newangle) < deviationAngle) {\n\t\t\tdistance = (left + right) / 2.0;\n\t\t\t// isLine = false;\n\t\t\treturn distance;\n\t\t}\n\t\t// compute radius\n\n\t\tdouble r = 0.5 * (left + right) / newangle;\n\t\tradius = r;\n\n\t\tInputHandler.stepForward(\"ra.\" + radius);\n\n\t\t// compute distance with the center pos\n\t\tdistance = 2.0 * (r) * Math.sin(newangle / 2.0);\n\n\t\treturn (distance);\n\t}",
"public void calcDistance() {\n if (DataManager.INSTANCE.getLocation() != null && location.getLength() == 2) {\n Log.e(\"asdf\", DataManager.INSTANCE.getLocation().getLength() + \"\");\n Log.e(\"asdf\", DataManager.INSTANCE.getLocation().getLength() + \"\");\n double dLat = Math.toRadians(location.getLatitude() - DataManager.INSTANCE.getLocation().getLatitude()); // deg2rad below\n double dLon = Math.toRadians(location.getLongitude() - DataManager.INSTANCE.getLocation().getLongitude());\n double a =\n Math.sin(dLat / 2) * Math.sin(dLat / 2) +\n Math.cos(Math.toRadians(location.getLatitude()))\n * Math.cos(Math.toRadians(location.getLatitude()))\n * Math.sin(dLon / 2)\n * Math.sin(dLon / 2);\n double c = 2 * Math.atan2(Math.sqrt(a), Math.sqrt(1 - a));\n double d = KM_IN_RADIUS * c; // Distance in km\n distance = (float) d;\n } else distance = null;\n }",
"public int distance(Coord coord1, Coord coord2);",
"private math_vector3d TwoPointGetCenterArcPoint(math_vector3d start, math_vector3d end)\n {\n\n\n ObjectPoint center2d = new ObjectPoint((start.X() + end.X()) / 2.0,(start.Y() + end.Y()) / 2.0);\n ObjectPoint orgin2d = new ObjectPoint(this.theOrigin.X(),this.theOrigin.Y());\n\n\n MathVector2D orginTocenter = new MathVector2D(orgin2d, center2d);\n\n orginTocenter = orginTocenter.GetUnit();\n orginTocenter = orginTocenter.multiply(this.theRadius);\n orgin2d.AddVector(orginTocenter);\n\n math_vector3d center = new math_vector3d(orgin2d.x,orgin2d.y,0);\n return center;\n }",
"private double getDistance(float x, float y, float x1, float y1) {\n double distanceX = Math.abs(x - x1);\n double distanceY = Math.abs(y - y1);\n return Math.sqrt(distanceX * distanceX + distanceY * distanceY);\n }",
"private double distance(Double lat1, Double lon1, String userName){\r\n\t\t//fetch the potential match\r\n\t\tString command = \"SELECT latitude, longitude FROM location WHERE userName = \\\"\" + userName + \"\\\";\";\r\n\t\trs = null;//clear previous results\r\n\t\tdouble lon2 = 0.0;//will hold the match's longitude\r\n\t\tdouble lat2 = 0.0;//will hold the match's latitude\r\n\r\n\t\ttry {//try block\r\n\t\t\trs = stmt.executeQuery(command);//send command\r\n\t\t\twhile(rs.next()){//parse the results\r\n\t\t\t\tlon2 = Double.valueOf(rs.getString(\"longitude\"));\r\n\t\t\t\tlat2 = Double.valueOf(rs.getString(\"latitude\"));\r\n\t\t\t}\r\n\t\t} catch (NumberFormatException | SQLException e) {\r\n\t\t\te.printStackTrace();\r\n\t\t\tout.println(\"Server error\");//server error\r\n\t\t}\r\n\r\n\t\t//compute distance\r\n\t\tdouble theta = lon1 - lon2;\r\n\t\tdouble dist = Math.sin(deg2rad(lat1)) * Math.sin(deg2rad(lat2)) + Math.cos(deg2rad(lat1))\r\n\t\t\t\t\t* Math.cos(deg2rad(lat2)) * Math.cos(deg2rad(theta));\r\n\t\tdist = Math.acos(dist);\r\n\t\tdist = rad2deg(dist);\r\n\t\tdist = dist * 60 * 1.1515;\r\n\t\trs = null;\r\n\t\t\r\n\t\treturn dist;//the distance computed\r\n\t}",
"public static double distance(double lat1, double lat2, double lon1, double lon2, double el1, double el2) {\n final int R = 6371; // Radius of the earth\n double latDistance = Math.toRadians(lat2 - lat1);\n double lonDistance = Math.toRadians(lon2 - lon1);\n double a = Math.sin(latDistance / 2) * Math.sin(latDistance / 2)\n + Math.cos(Math.toRadians(lat1)) * Math.cos(Math.toRadians(lat2))\n * Math.sin(lonDistance / 2) * Math.sin(lonDistance / 2);\n double c = 2 * Math.atan2(Math.sqrt(a), Math.sqrt(1 - a));\n double distance = R * c * 1000; // convert to meters\n double height = el1 - el2;\n distance = Math.pow(distance, 2) + Math.pow(height, 2);\n distance = Math.sqrt(distance);\n distance = 0.001 * distance;\n distance = 0.621371 * distance;\n BigDecimal bd = new BigDecimal(distance).setScale(2, RoundingMode.HALF_UP);\n double roundedDistance = bd.doubleValue();\n return roundedDistance;\n }",
"public static double haversineFormula(double [] point1, double [] point2) {\r\n\r\n\t\tdouble distance=0;\r\n\t\tdouble DEG_TO_RAD = 0.017453293; //The known pi/180\r\n\t\tdouble EARTH_RADIUS_IN_METERS = 6371.0; //Earth radius in km\r\n\t\tdouble dlon,dlat,a,c;\r\n\r\n\t\tdlat = (point2[0] - point1[0]) * DEG_TO_RAD;\r\n\t\tdlon = (point2[1] - point1[1]) * DEG_TO_RAD;\r\n\t\ta = Math.pow(Math.sin(dlat * 0.5),2) + Math.cos(point1[0] * DEG_TO_RAD)* Math.cos(point2[0] * DEG_TO_RAD) * Math.pow(Math.sin(dlon * 0.5),2);\r\n\t\tc = 2.0 * Math.asin(Math.min(1.0 , Math.sqrt(a)));\r\n\t\tdistance = EARTH_RADIUS_IN_METERS * c;\r\n\r\n\t\treturn distance; //Distance in km \r\n\t}",
"@Test\n public void testFind_South() {\n\n double lat1 = 0.0;\n double lon1 = 0.0;\n double lat2 = -10.0;\n double lon2 = 0.0;\n double expResult = Math.toRadians(180);\n double result = Azimuth.find(lat1, lon1, lat2, lon2);\n assertEquals(expResult, result, 0.0);\n }",
"public static double getDisplacementBetweenCoordinates(double lat1, double lon1, double lat2, double lon2) {\n Location locationA = new Location(\"point A\");\n locationA.setLatitude(lat1);\n locationA.setLongitude(lon1);\n Location locationB = new Location(\"point B\");\n locationB.setLatitude(lat2);\n locationB.setLongitude(lon2);\n return locationA.distanceTo(locationB) ;\n }",
"public double theta() { return Math.atan2(y, x); }"
] | [
"0.7711866",
"0.7585533",
"0.75745106",
"0.75525355",
"0.7393969",
"0.7369092",
"0.7286155",
"0.7201643",
"0.71621245",
"0.7128488",
"0.70961314",
"0.70955354",
"0.7093756",
"0.70885503",
"0.7081631",
"0.7075796",
"0.7024967",
"0.70231247",
"0.69544196",
"0.6873976",
"0.68526995",
"0.6833979",
"0.6808908",
"0.67875785",
"0.67703885",
"0.6742302",
"0.6741208",
"0.6741123",
"0.6722812",
"0.67119265",
"0.66962403",
"0.66933286",
"0.66721404",
"0.66598165",
"0.6656165",
"0.66325545",
"0.66034544",
"0.66019696",
"0.65805143",
"0.6578272",
"0.6568464",
"0.6561457",
"0.6522815",
"0.65210056",
"0.651528",
"0.6489176",
"0.6487996",
"0.6374936",
"0.6364272",
"0.6354928",
"0.63400114",
"0.6333845",
"0.6320064",
"0.6281074",
"0.6254215",
"0.62505347",
"0.62365526",
"0.6236354",
"0.6220643",
"0.6209563",
"0.6202934",
"0.6186338",
"0.617993",
"0.6172583",
"0.61640716",
"0.61603814",
"0.61522114",
"0.61493134",
"0.61399025",
"0.6133243",
"0.612579",
"0.612226",
"0.611457",
"0.61033016",
"0.6076877",
"0.60717523",
"0.60621274",
"0.60564923",
"0.60564435",
"0.6036467",
"0.6026642",
"0.60253155",
"0.6025301",
"0.6019444",
"0.60135484",
"0.6002412",
"0.6002105",
"0.59959173",
"0.59870565",
"0.5968408",
"0.595844",
"0.5953917",
"0.5926734",
"0.592525",
"0.5912305",
"0.59054923",
"0.5901549",
"0.5901244",
"0.5882276",
"0.5868317"
] | 0.77002025 | 1 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.