query
stringlengths
7
33.1k
document
stringlengths
7
335k
metadata
dict
negatives
listlengths
3
101
negative_scores
listlengths
3
101
document_score
stringlengths
3
10
document_rank
stringclasses
102 values
Metodo para establecer un valor de IDt.
public static void setIDt(int IDt) { Componente.IDt = IDt; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "protected Object getId(Modulo t) {\n\t\treturn t.getId();\n\t}", "String getValueId();", "public Number getTallaId() {\n return (Number)getAttributeInternal(TALLAID);\n }", "IDType getID();", "public abstract java.lang.String getTica_id();", "public void setID(String idIn) {this.id = idIn;}", "public void setId_trimestre(int id_trimestre) {this.id_trimestre = id_trimestre;}", "public final Long getId_etudiant() {\n return this.id_etudiant;\n }", "protected String text() {\n\t\treturn idSet ? String.valueOf(id) : \"\";\n\t}", "@RdfProperty(\"http://www.coadunation.net/schema/rdf/1.0/base#IdValue\")\n public abstract String getValue();", "public Integer getTid() {\r\n return tid;\r\n }", "java.lang.String getID();", "public Integer getID(){\n return ID;\n }", "@Override public String getID() { return id;}", "private Integer getId() { return this.id; }", "public String getID(){return ID;}", "@Override\n public int intValue(int numId) {\n return 0;\n }", "public void setTid(Integer tid) {\r\n this.tid = tid;\r\n }", "private JTextField getTId() {\r\n if (tId == null) {\r\n tId = new JTextField();\r\n tId.setBounds(new Rectangle(100, 20, 100, 20));\r\n }\r\n return tId;\r\n }", "public void setM_Locator_ID (int M_Locator_ID)\n{\nset_Value (\"M_Locator_ID\", new Integer(M_Locator_ID));\n}", "public String getTxtID() {\n return txtId.getText();\n }", "public String getId(){ return id.get(); }", "protected int getID(){\r\n\t\treturn this.ID;\r\n\t}", "public void setC_Conversion_UOM_ID (int C_Conversion_UOM_ID)\n{\nset_Value (\"C_Conversion_UOM_ID\", new Integer(C_Conversion_UOM_ID));\n}", "public java.lang.String getValue_id() {\n return value_id;\n }", "public void setC_UOM_ID (int C_UOM_ID)\n{\nset_Value (\"C_UOM_ID\", new Integer(C_UOM_ID));\n}", "public int getId()\r\n/* 75: */ {\r\n/* 76:110 */ return this.idAutorizacionDocumentoPuntoDeVentaAutoimpresorSRI;\r\n/* 77: */ }", "public final void setId_etudiant(final Long id_etudiant) {\n this.id_etudiant = id_etudiant;\n }", "public String getMtId() {\n return mtId;\n }", "public Object get_KeyValue(){return\t\t\t Id;}", "public int getID(){\r\n return this.ID;\r\n }", "public String getId(){ return ID; }", "public String getID(){\n return Id;\n }", "public Number getID();", "@Override\n\tpublic double getId()\n\t{\n\t\treturn id;\n\t}", "public int getId()\r\n/* 53: */ {\r\n/* 54: 79 */ return this.idDetalleComponenteCosto;\r\n/* 55: */ }", "public String getID()\r\n {\r\n return this.id;\r\n }", "public java.lang.Long getTiag_id();", "public int getId()\r\n/* 208: */ {\r\n/* 209:381 */ return this.idCargaEmpleado;\r\n/* 210: */ }", "public String getID();", "public String getID();", "public String getID();", "public String getID();", "public String getID();", "public String getID();", "public String getID();", "public Valor(Integer id_valor, String valor){\n\n //A variavel da classe Construtora vai receber a variavel que está vindo por parametro (This faz referencia a classe)\n this.id_valor = id_valor ;\n this.valor = valor ;\n }", "public void setM_Splitting_ID (int M_Splitting_ID)\n{\nset_ValueNoCheck (\"M_Splitting_ID\", new Integer(M_Splitting_ID));\n}", "@Override\r\n\tpublic String getID() {\n\t\treturn super.id;\r\n\t}", "public int getM_Splitting_ID() \n{\nInteger ii = (Integer)get_Value(\"M_Splitting_ID\");\nif (ii == null) return 0;\nreturn ii.intValue();\n}", "@Override\r\n\tpublic TVA rechercherParId(TVA t) {\n\t\treturn null;\r\n\t}", "public abstract int getTribeID();", "public Integer getId_movimiento() {\r\n return id_movimiento;\r\n }", "@Override\r\n public Object valT(String id, int indice) throws IllegalAccessException {\r\n Quadruplet quad = stack.peekFirst(id);\r\n if (quad == null){\r\n throw new IllegalAccessException(id + \" has not been declared\");\r\n }\r\n if (quad.nature() != OBJ.TAB) {\r\n throw new IllegalAccessException(id + \" is not an array\");\r\n }\r\n return heap.valeurTas(quad.val(), indice);\r\n }", "public void setID(Number numID);", "String getID();", "String getID();", "String getID();", "String getID();", "public int getM_Locator_ID() \n{\nInteger ii = (Integer)get_Value(\"M_Locator_ID\");\nif (ii == null) return 0;\nreturn ii.intValue();\n}", "public void setTid(int tid);", "public String getID()\n {\n return this.id;\n }", "@Override\r\n public Integer getID() {\r\n return this.id;\r\n }", "public int getIden() {\n return iden;\n }", "public String getTeid() {\n\t\treturn this.teid;\n\t}", "public String getId() {\n return getNom();\n }", "public int getID(){\n return this.ID;\n }", "public int getiid(){\r\n return Iid;\r\n }", "public int getIdenti() {\r\n return identi;\r\n }", "Integer getID();", "Integer getID();", "public Integer getValueId() {\n return valueId;\n }", "public void setM_Product_ID (int M_Product_ID)\n{\nset_Value (\"M_Product_ID\", new Integer(M_Product_ID));\n}", "java.lang.String getId();", "java.lang.String getId();", "java.lang.String getId();", "java.lang.String getId();", "java.lang.String getId();", "java.lang.String getId();", "java.lang.String getId();", "java.lang.String getId();", "java.lang.String getId();", "java.lang.String getId();", "java.lang.String getId();", "java.lang.String getId();", "java.lang.String getId();", "java.lang.String getId();", "java.lang.String getId();", "java.lang.String getId();", "java.lang.String getId();", "java.lang.String getId();", "java.lang.String getId();", "private int getT()\n\t{\n\t\tint numberT = Integer.parseInt(field2.getText()) ;\n\t\treturn numberT;\n\t\t\n\t}", "public long getIdCargaTienda();", "@Override\n public String getEntId() {\n init();\n return entid;\n }", "@Test\n public void setGetID() {\n final CourseType courseType = new CourseType();\n final String ID = \"ID\";\n courseType.setId(ID);\n\n assertSame(ID, courseType.getId());\n }", "public abstract long getId(T obj);", "public String getId()\r\n/* 14: */ {\r\n/* 15:14 */ return this.id;\r\n/* 16: */ }", "@Override\r\n\t\tpublic String getId()\r\n\t\t\t{\n\t\t\t\treturn null;\r\n\t\t\t}", "public abstract java.lang.Integer getEspe_id();" ]
[ "0.65876037", "0.641057", "0.6371306", "0.6256342", "0.6070359", "0.6060348", "0.60149276", "0.5990532", "0.5947585", "0.5925188", "0.5919379", "0.5912041", "0.5910302", "0.58979344", "0.5865302", "0.58606", "0.58416075", "0.58313215", "0.58173525", "0.58147746", "0.5810736", "0.57898605", "0.5771434", "0.5768278", "0.5766581", "0.57654583", "0.5760946", "0.5756166", "0.57540685", "0.5753417", "0.57424664", "0.5740662", "0.5738664", "0.5736893", "0.57332164", "0.57327473", "0.5729721", "0.57236755", "0.5701327", "0.5700318", "0.5700318", "0.5700318", "0.5700318", "0.5700318", "0.5700318", "0.5700318", "0.56956166", "0.5695036", "0.56901556", "0.5689149", "0.5685611", "0.56855404", "0.5682239", "0.56794673", "0.5675914", "0.56749475", "0.56749475", "0.56749475", "0.56749475", "0.5672266", "0.5667355", "0.5663011", "0.56572586", "0.5657112", "0.56553566", "0.5650494", "0.5650217", "0.5649672", "0.56420076", "0.5635859", "0.5635859", "0.56315416", "0.56290257", "0.56268233", "0.56268233", "0.56268233", "0.56268233", "0.56268233", "0.56268233", "0.56268233", "0.56268233", "0.56268233", "0.56268233", "0.56268233", "0.56268233", "0.56268233", "0.56268233", "0.56268233", "0.56268233", "0.56268233", "0.56268233", "0.56268233", "0.56179255", "0.56101596", "0.56099814", "0.56048864", "0.5603048", "0.56021035", "0.559068", "0.5584422" ]
0.6538628
1
Encode String without padding
private String encode(String str) { verifyNotNull(str, ERROR_MESSAGE); byte[] bytes = str.getBytes(); return Base64.getEncoder() .withoutPadding() .encodeToString(bytes); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "java.lang.String getEncoded();", "private static String encodeBase64(String stringToEncode){\r\n\t\treturn Base64.getEncoder().encodeToString(stringToEncode.getBytes());\t\r\n\t}", "public String base64Encode(String str) throws StoreFactoryException;", "public static String encode(String string){\n return encode(string.getBytes());\n }", "public static String returnEncoded(String text) {\n if (text == null) {\n return null;\n }\n return Base64.encodeToString(text.getBytes(), Base64.NO_WRAP);\n }", "public static String encodeString(String str) throws IOException {\n BASE64Encoder encoder = new BASE64Encoder();\n String encodedStr = encoder.encodeBuffer(str.getBytes());\n \n return (encodedStr.trim());\n }", "public static String encode(String arg) {\n String encoded = Base64.getEncoder().encodeToString(arg.getBytes());\n\n return encoded;\n }", "String encrypt(String input) {\n\t\treturn BaseEncoding.base64().encode(input.getBytes());\n\t}", "private static void encodeString(String in){\n\n\t\tString officalEncodedTxt = officallyEncrypt(in);\n\t\tSystem.out.println(\"Encoded message: \" + officalEncodedTxt);\n\t}", "public String encode() {\n return encodeToBase64(encKey.getEncoded()) + \":\" + encodeToBase64(macKey.getEncoded());\n }", "public String encode(String str) throws EncoderException {\n/* 249 */ if (str == null) {\n/* 250 */ return null;\n/* */ }\n/* */ try {\n/* 253 */ return encode(str, getDefaultCharset());\n/* 254 */ } catch (UnsupportedEncodingException e) {\n/* 255 */ throw new EncoderException(e.getMessage(), e);\n/* */ } \n/* */ }", "public static String encode(String string){\n\t\treturn new String(encode(string.getBytes()));\n\t}", "public static String encode(String inString, String type, String Key) throws Exception{\r\n\t\tStringBuilder encodedString = new StringBuilder();\r\n\t\tString thisString;\r\n\t\tencodedString.append(\"<encrypted type=\" + type + \" key=\");\r\n\t\tif(type==\"Caesar\"){\r\n\t\t\tencodedString.append(Integer.toHexString(Integer.parseInt(Key)) + \"> \");\r\n\t\t\tchar[] alphabet ={'a','b','c','d','e','f','g','h','i','j','k','l','m',\r\n\t\t\t\t\t'n','o','p','q','r','s','t','u','v','w','x','y','z','å','ä','ö','A','B',\r\n\t\t\t\t\t'C','D','E','F','G','H','I','J','K','L','M','N','O','P','Q','R','S','T','U',\r\n\t\t\t\t\t'V','W','X','Y','Z','Å','Ä','Ö','0','1','2','3','4','5','6','7','8','9',\r\n\t\t\t\t\t'!','?',')','(','=','>','<','/','&','%','#','@','$','[',']'};\r\n\t\t\tfor(int i = 0; i < inString.length(); i++){\r\n\t\t\t\tchar a = inString.charAt(i);\r\n\t\t\t\tint used = 0;\r\n\t\t\t\tfor(char b: alphabet){\r\n\t\t\t\t\tif(b==a){\r\n\t\t\t\t\t\ttry{\r\n\t\t\t\t\t\t\tthisString = String.format(\"%02x\",(int)alphabet[(indexOf(alphabet,b)\r\n\t\t\t\t\t\t\t\t\t+Integer.parseInt(Key))%alphabet.length]);\r\n\t\t\t\t\t\t\tencodedString.append(thisString);\r\n\t\t\t\t\t\t\tused = 1;\r\n\t\t\t\t\t\t\tbreak;\r\n\t\t\t\t\t\t}catch(Exception c){\r\n\t\t\t\t\t\t\tSystem.out.print(c.getMessage());\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t\tif(used==0){\r\n\t\t\t\t\tthisString = String.format(\"%02x\", (int)a);\r\n\t\t\t\t\tencodedString.append(thisString);\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t\telse if(type==\"AES\"){\r\n\t\t\tfor(int i = 0; i<Key.length();i++){\r\n\t\t\t\tencodedString.append(String.format(\"%02x\", (int)Key.charAt(i)));\r\n\t\t\t}\r\n\t\t\tencodedString.append(\">\");\r\n\t\t\tencodedString.append(\" \");\r\n\t\t\tbyte[] keyContent = Base64.getDecoder().decode(Key);\r\n\t\t\tSecretKeySpec AESkey = new SecretKeySpec(keyContent,0,keyContent.length, \"AES\");\r\n\t\t\tSystem.out.println(keyContent);\r\n\t\t\t\r\n\t\t\tCipher AEScipher = Cipher.getInstance(\"AES\");\r\n\t\t\tAEScipher.init(Cipher.ENCRYPT_MODE, AESkey);\r\n\t\t\tbyte[] cipherData = AEScipher.doFinal(inString.getBytes());\r\n\t\t\tfor(byte b: cipherData){\r\n\t\t\t\tencodedString.append(String.format(\"%02x\", b));\r\n\t\t\t}\r\n\t\t}\r\n\t\telse{\r\n\t\t\tthrow new Exception(\"Unknown encryption\");\r\n\t\t}\r\n\t\tencodedString.append(\" </encrypted> \");\r\n\t\treturn encodedString.toString();\r\n\t\t\r\n\t}", "public static String base64EncodeString(String input) throws Exception\n {\n return base64Encode(input.getBytes(\"UTF-8\"));\n }", "public static String encode(byte[] in) {\n int fourB64Bytes = 0;\n StringBuffer sb = new StringBuffer();\n int posIn = 0;\n for (posIn = 0; posIn < in.length; posIn++) {\n int oneByte = in[posIn]; // in 0..255, not -128..127 \n if (oneByte < 0) {\n oneByte += 256;\n }\n fourB64Bytes = (fourB64Bytes << 8) + oneByte;\n if (posIn % 3 == 2) {\n sb.append((char)ENCODE_TABLE[(fourB64Bytes >> 18) & 0x3F]);\n sb.append((char)ENCODE_TABLE[(fourB64Bytes >> 12) & 0x3F]);\n sb.append((char)ENCODE_TABLE[(fourB64Bytes >> 6) & 0x3F]);\n sb.append((char)ENCODE_TABLE[fourB64Bytes & 0x3F]);\n fourB64Bytes = 0;\n }\n }\n posIn--;\n switch (posIn % 3) {\n case 0:\n fourB64Bytes = fourB64Bytes << 4; //pad with 0000\n sb.append((char)ENCODE_TABLE[(fourB64Bytes >> 6) & 0x3F]);\n sb.append((char)ENCODE_TABLE[fourB64Bytes & 0x3F]);\n sb.append((char)PAD);\n sb.append((char)PAD);\n fourB64Bytes = 0;\n break;\n\n case 1:\n fourB64Bytes = fourB64Bytes << 2; //pad with 00\n sb.append((char)ENCODE_TABLE[(fourB64Bytes >> 12) & 0x3F]);\n sb.append((char)ENCODE_TABLE[(fourB64Bytes >> 6) & 0x3F]);\n sb.append((char)ENCODE_TABLE[fourB64Bytes & 0x3F]);\n sb.append((char)PAD);\n fourB64Bytes = 0;\n break;\n\n }\n return sb.toString();\n }", "private void encode(){\r\n \r\n StringBuilder sb = new StringBuilder();\r\n \r\n /*\r\n *if a character code is >126 after adding the encryption key, subtract \r\n *95 to wrap\r\n */\r\n for(int i = 0; i < message.length(); i++){\r\n if(message.charAt(i) + key > 126){\r\n int wrappedKey = message.charAt(i) + key - 95;\r\n \r\n sb.append((char) wrappedKey);\r\n \r\n /*\r\n *if a character code ins't > 126 after adding the encryption key\r\n */\r\n } else{\r\n int wrappedKey = message.charAt(i) + key;\r\n sb.append( (char) wrappedKey);\r\n }\r\n }\r\n /*\r\n *case coded message to a string\r\n */\r\n codedMessage = sb.toString();\r\n }", "public static String encode(String s) {\n // return java.net.URLEncoder.encode(s);\n /*\n ** The only encoded chars are \"<>%=/\", chars < space and chars >= 127\n ** (including cr/lf, ...)\n ** A leading and/or trailing space is also encoded, all others are\n ** left alone\n **\n ** Encoding is %dd where dd are hex digits for the hex value encode\n **\n ** Check if needs encoding first, if not, simply return original string\n */\n char arr[] = s.toCharArray();\n int len = arr.length;\n for(int i=0; i < len; i++) {\n char ch = arr[i];\n if (ch < ' ' || ch > (char)127 || ch == '%' ||\n ch == '<' || ch == '>' || ch == '=' || \n ch == '/' || \n ((ch == ' ') && (i == 0 || i == len-1))) {\n \n StringBuffer sb = new StringBuffer();\n for(i=0; i < len; i++) {\n ch = arr[i];\n if (ch < ' ' || ch > (char)127 || ch == '%' ||\n ch == '<' || ch == '>' || ch == '=' || \n ch == '/' || \n ((ch == ' ') && (i == 0 || i == len-1))) {\n \n byte b = (byte)arr[i];\n sb.append('%');\n char c = Character.forDigit((b >> 4) & 0xf, 16);\n sb.append(c);\n c = Character.forDigit(b & 0xf, 16);\n sb.append(c);\n } else {\n sb.append(arr[i]);\n }\n }\n s = sb.toString();\n break;\n }\n }\n return s;\n }", "public static String encode(byte[] input) {\r\n\tint i;\r\n\tint j;\r\n\tint m;\r\n\tint a;\r\n\tint b;\r\n\tint c;\r\n\tStringBuffer output;\r\n\r\n\tif (input.length == 0) {\r\n\t return \"\";\r\n\t}\r\n\r\n\t/*\r\n\t * Compute the length of the output buffer.\r\n\t */\r\n\ti = ((input.length + 2) / 3) << 2;\r\n\toutput = new StringBuffer(i);\r\n\ti = input.length / 3;\r\n\tj = 0;\r\n\r\n\twhile (i > 0) {\r\n\t a = input[j++];\r\n\t b = input[j++];\r\n\t c = input[j++];\r\n\r\n\t m = (a >>> 2) & 63;\r\n\t output.append(BASE64[m]);\r\n\r\n\t m = ((a & 3) << 4) | ((b >>> 4) & 15);\r\n\t output.append(BASE64[m]);\r\n\r\n\t m = ((b & 15) << 2) | ((c >>> 6) & 3);\r\n\t output.append(BASE64[m]);\r\n\r\n\t m = c & 63;\r\n\t output.append(BASE64[m]);\r\n\t i--;\r\n\t}\r\n\t/*\r\n\t * Handle the padding and encoding of groups of less than three input\r\n\t * bytes length.\r\n\t */\r\n\ti = input.length % 3;\r\n\r\n\tswitch (i) {\r\n\tcase 1:\r\n\t a = input[j++];\r\n\t m = (a >>> 2) & 63;\r\n\t output.append(BASE64[m]);\r\n\t m = (a & 3) << 4;\r\n\t output.append(BASE64[m]);\r\n\t output.append(PAD_2);\r\n\t break;\r\n\r\n\tcase 2:\r\n\t a = input[j++];\r\n\t b = input[j++];\r\n\t m = (a >>> 2) & 63;\r\n\t output.append(BASE64[m]);\r\n\r\n\t m = ((a & 3) << 4) | ((b >>> 4) & 15);\r\n\t output.append(BASE64[m]);\r\n\r\n\t m = (b & 15) << 2;\r\n\t output.append(BASE64[m]);\r\n\t output.append(PAD_1);\r\n\t break;\r\n\t}\r\n\treturn output.toString();\r\n }", "private String UTF8Encode(String s) {\n\n\n s = s.replace(\"\\r\\n\", \"\\n\");\n int[] utftext = new int[s.length() * 3];\n int utftextlen = 0;\n for (int n = 0; n < s.length(); n++) {\n int c = s.charAt(n);\n if (c < 128) {\n utftext[utftextlen++] = c;\n Log.e(\"utf\", n + \" try:\" + c);\n } else if ((c > 127) && (c < 2048)) {\n utftext[utftextlen++] = (c >> 6) | 192;\n utftext[utftextlen++] = (c & 63) | 128;\n Log.e(\"utf\", n + \" try:\" + ((c >> 6) | 192));\n Log.e(\"utf\", n + \" try:\" + ((c & 63) | 128));\n } else {\n utftext[utftextlen++] = (c >> 12) | 224;\n utftext[utftextlen++] = ((c >> 6) & 63) | 128;\n utftext[utftextlen++] = (c & 63) | 128;\n Log.e(\"utf\", n + \" try:\" + ((c >> 12) | 224));\n Log.e(\"utf\", n + \" try:\" + (((c >> 6) & 63) | 128));\n Log.e(\"utf\", n + \" try:\" + ((c & 63) | 128));\n }\n\n }\n int i = 0;\n char chr1, chr2, chr3;\n int enc1, enc2, enc3, enc4;\n StringBuilder string = new StringBuilder();\n while (i < utftextlen) {\n chr1 = (char) utftext[i++];\n chr2 = (char) utftext[i++];\n chr3 = (char) utftext[i++];\n enc1 = chr1 >> 2;\n enc2 = ((chr1 & 3) << 4) | (chr2 >> 4);\n enc3 = ((chr2 & 15) << 2) | (chr3 >> 6);\n enc4 = chr3 & 63;\n if (isNaN(chr2)) {\n enc3 = enc4 = 64;\n } else if (isNaN(chr3)) {\n enc4 = 64;\n }\n string.append(_keyStr.charAt(enc1) + _keyStr.charAt(enc2) + _keyStr.charAt(enc3) + _keyStr.charAt(enc4));\n }\n string.append(\"\");\n return string.toString();\n }", "public String toUrlSafe() {\n// try {\n //todo: key encoder\n return Base64.getEncoder().encodeToString(new Gson().toJson(this).getBytes());\n// return URLEncoder.encode(\"\", UTF_8.name());\n// return URLEncoder.encode(TextFormat.printToString(toPb()), UTF_8.name());\n// } catch (UnsupportedEncodingException e) {\n// throw new IllegalStateException(\"Unexpected encoding exception\", e);\n// }\n }", "public static String uuencode (String str) {\n\tStringBuilder ret = new StringBuilder (str.length () * 4 / 3);\n\tchar ch, ch1, ch2, ch3;\n\tint i;\n\t\n\tfor (i = 0; i+2 < str.length (); i+=3) {\t \n\t ch1 = str.charAt (i);\n\t ch2 = str.charAt (i+1);\n\t ch3 = str.charAt (i+2);\n\t ch = uu_base64[((ch1 >> 2) & 077)];\n\t ret.append (ch);\n\t \n\t ch = uu_base64[(((ch1 << 4) & 060) | ((ch2 >> 4) & 017))];\n\t ret.append (ch);\n\t \n\t ch = uu_base64[(((ch2 << 2) & 074) | ((ch3 >> 6) & 03))];\n\t ret.append (ch);\n\t \n\t ch = uu_base64[(ch3 & 077)];\n\t ret.append (ch);\n\t}\n\t\n\t// are we done yet?\n\tif (i == str.length ()) \n\t return ret.toString ();\n\n\t// no so handle the trailing characters.\n\tch1 = str.charAt (i);\n\tch2 = str.length() > i + 1 ? str.charAt (i+1) : (char)0;\n\t\n\tch = uu_base64[((ch1 >> 2) & 077)];\n\tret.append (ch);\n\t\n\tch = uu_base64[(((ch1 << 4) & 060) | ((ch2 >> 4) & 017))];\n\tret.append (ch);\n\t\n\tif (str.length () > i + 1) {\n\t ch = uu_base64[((ch2 << 2) & 074)];\n\t ret.append (ch);\n\t} else {\n\t ret.append ('=');\n\t}\n\tret.append ('=');\n\treturn ret.toString ();\n }", "public String encode( String password );", "public static String base64Encode(String str) {\n sun.misc.BASE64Encoder encoder = new sun.misc.BASE64Encoder();\n byte[] bytes = str.getBytes();\n return encoder.encode(bytes);\n\n }", "public static String encode(String str) {\n if (str.length() == 0)\n return str;\n StringBuilder sb = new StringBuilder();\n encodeXML(sb, str);\n return sb.toString();\n }", "public String encode(String text) {\n\t\t// TODO fill this in.\n\n\t\tString encodedText = \"\";\n\t\tSystem.out.println(\"text.length(): \" + text.length());\n\t\tfor (int i = 0; i < text.length(); i++) {\n\t\t\tString characterCode = encodingTable.get(text.charAt(i));\n\t\t\tSystem.out.println(text.charAt(i));\n\t\t\tencodedText = encodedText.concat(characterCode);\n\t\t}\n\t\tSystem.out.println(\"THISHERE: \\n\" + encodedText + \"\\nTHISEND\");\n\n\t\treturn encodedText;\n\t}", "public static String encrypt(String input) {\n\t\tBase64.Encoder encoder = Base64.getMimeEncoder();\n String message = input;\n String key = encoder.encodeToString(message.getBytes());\n return key;\n\t}", "public String encode() {\n\t\tString coded = \"\";\n\t\tfor (Character c: this.input.toCharArray()) {\n\t\t\tcoded += this.mapping.get(c);\n\t\t}\n\t\treturn coded;\n\t}", "public String encode(String text) {\n\t\t// TODO fill this in.\n\t\tStringBuilder sb = new StringBuilder();\n\n\t\tfor (int i = 0; i < text.length(); i++) {\n\t\t\tsb.append(encodingTable.get(text.charAt(i)));\n\t\t}\n\t\treturn sb.toString();\n\t}", "String encode(Object obj);", "public static String encode(byte[] input, int offset, int len)\r\n {\r\n return Base64.encode(input, offset, len);\r\n }", "public String encode(List<String> strs) {\n \n StringBuilder ans = new StringBuilder(\"\");\n for(String str:strs) {\n ans.append(str.length()+\"@\");\n ans.append(str);\n }\n return ans.toString();\n }", "private String encode(String value) {\n String encoded = \"\";\n try {\n encoded = URLEncoder.encode(value, \"UTF-8\");\n } catch (Exception e) {\n e.printStackTrace();\n }\n String sb = \"\";\n char focus;\n for (int i = 0; i < encoded.length(); i++) {\n focus = encoded.charAt(i);\n if (focus == '*') {\n sb += \"%2A\";\n } else if (focus == '+') {\n sb += \"%20\";\n } else if (focus == '%' && i + 1 < encoded.length() && encoded.charAt(i + 1) == '7' && encoded.charAt(i + 2) == 'E') {\n sb += '~';\n i += 2;\n } else {\n sb += focus;\n }\n }\n return sb.toString();\n }", "private String encodeValue(final String dirtyValue) {\n String cleanValue = \"\";\n\n try {\n cleanValue = URLEncoder.encode(dirtyValue, StandardCharsets.UTF_8.name())\n .replace(\"+\", \"%20\");\n } catch (final UnsupportedEncodingException e) {\n }\n\n return cleanValue;\n }", "public String encode(String p_str)\n {\n int x = 0, len = 0;\n char aChar;\n StringBuffer buff;\n\n if (p_str == null)\n {\n return null;\n }\n\n len = p_str.length();\n if (len == 0)\n {\n return p_str;\n }\n\n buff = new StringBuffer (len*2);\n aChar = p_str.charAt(x++);\n\n // leading whitespace - for software it should be preserved\n while ((x < len) && Character.isWhitespace(aChar))\n {\n buff.append(makeTmx(aChar, true)); // true = leading whitespace\n aChar = p_str.charAt(x++);\n }\n --x; // backup one\n\n while (x < len)\n {\n aChar = p_str.charAt(x++);\n String tmx = makeTmx(aChar, false);\n if (tmx.equals(\"\" + aChar))\n {\n tmx = encodeXml(aChar);\n }\n\n buff.append(tmx);\n }\n\n return (buff.toString());\n }", "public static String encode(String unencoded) {\r\n StringBuilder buffer = null;\r\n for (int i = 0; i < unencoded.length(); ++i) {\r\n String encS = XmlWriter.encoding.get(unencoded.charAt(i));\r\n if (encS != null) {\r\n if (buffer == null)\r\n buffer = new StringBuilder(unencoded.substring(0,i));\r\n buffer.append(encS);\r\n } else if (buffer != null)\r\n buffer.append(unencoded.charAt(i));\r\n }\r\n return (buffer == null) ? unencoded : buffer.toString();\r\n }", "public static String encode(String argStr) {\r\n\t\tString result = argStr;\r\n\t\ttry {\r\n\t\t\tif (result != null && !result.isEmpty()) {\r\n\t\t\t\tresult = URLDecoder.decode(result, UTF_8);\r\n\t\t\t}\r\n\t\t} catch (Exception e) {\r\n\t\t\t// ignore\r\n\t\t}\r\n\t\tresult = encodeExplicit(result);\r\n\t\treturn result;\r\n\t}", "private ByteBuffer encode(String str) {\n ByteBuffer bb = null;\n CharsetEncoder isoencoder = UTF8.newEncoder();\n try {\n bb = isoencoder.encode(CharBuffer.wrap(str));\n } catch (CharacterCodingException e) {\n log.error(e);\n }\n return bb;\n }", "private String encode(String s) {\n\t\tString t = \"\";\n\n\t\tif (s == null) {\n\t\t\treturn t;\n\t\t}\n\n\t\tfor (int i = 0; i < s.length(); i++) {\n\t\t\tchar c = s.charAt(i);\n\n\t\t\tif (c == '<') {\n\t\t\t\tt += \"&lt;\";\n\t\t\t} else if (c == '>') {\n\t\t\t\tt += \"&gt;\";\n\t\t\t} else if (c == '&') {\n\t\t\t\tt += \"&amp;\";\n\t\t\t} else if (c == '\"') {\n\t\t\t\tt += \"&quot;\";\n\t\t\t} else if (c == '\\'') {\n\t\t\t\tt += \"&apos;\";\n\t\t\t} else {\n\t\t\t\tt += c;\n\t\t\t}\n\t\t}\n\n\t\treturn t;\n\t}", "public static String encodePassword( String object )\n\t{\n\t\tBASE64Encoder encoder = new BASE64Encoder();\n\t\tif ( object != null ) {\n\t\t\ttry {\n\t\t\t\tString encodedPassword = encoder.encode(object.getBytes(\"UTF-8\"));\n\t\t\t\tLOGGER.info(\"encode '\" + object + \"' password as base64 -> '\" + encodedPassword + \"'\");\n\t\t\t\treturn encodedPassword;\n\t\t\t} catch (UnsupportedEncodingException e) {\n\t\t\t\tLOGGER.severe(\"UTF-8 not supported\");\n\t\t\t}\n\t\t}\n\n\n\t\treturn \"\";\n\t}", "private String encodeMessage() {\n\t\tString encode = \"\";\n\t\tfor (int i = 0; i < message.length(); i++) {\n\t\t\tencode += map.get(message.charAt(i));\n\t\t}\n\t\tgenerateBack();\n\t\treturn encode;\n\t}", "protected String encode(AsciiValueEncoder enc)\n {\n // note: nothing in buffer, can't flush (thus no need to call to check)\n int last = enc.encodeMore(mBuffer, 0, mBuffer.length);\n if (enc.isCompleted()) { // fitted in completely?\n return new String(mBuffer, 0, last);\n }\n // !!! TODO: with Java 5, use StringBuilder instead\n StringBuffer sb = new StringBuffer(mBuffer.length << 1);\n sb.append(mBuffer, 0, last);\n do {\n last = enc.encodeMore(mBuffer, 0, mBuffer.length);\n sb.append(mBuffer, 0, last);\n } while (!enc.isCompleted());\n return sb.toString();\n }", "public String encode(String message)\n\t{\n\t\treturn encode(message, 0);\n\t}", "@Override\r\n\tpublic String encode() {\n\t\treturn null;\r\n\t}", "public static String encode(String string, String encodingName) {\r\n\t\tString encodedString = \"\";\r\n\t\tif (encodingName.equalsIgnoreCase(\"base64\")) {\r\n\t\t\tbyte[] byteArray = Base64.encodeBase64(string.getBytes());\r\n\t\t\tencodedString = new String(byteArray);\r\n\r\n\t\t} else if (encodingName.equalsIgnoreCase(\"PBEWithMD5AndDES\")) {\r\n\t\t\t// Key generation for enc and desc\r\n\t\t\tKeySpec keySpec = new PBEKeySpec(secretKey.toCharArray(), salt, iterationCount);\r\n\t\t\tSecretKey key = null;\r\n\t\t\tString charSet = \"UTF-8\";\r\n\t\t\tbyte[] in = null;\r\n\t\t\tbyte[] out = null;\r\n\t\t\ttry {\r\n\t\t\t\tkey = SecretKeyFactory.getInstance(\"PBEWithMD5AndDES\").generateSecret(keySpec);\r\n\t\t\t\tAlgorithmParameterSpec paramSpec = new PBEParameterSpec(salt, iterationCount);\r\n\t\t\t\tecipher = Cipher.getInstance(key.getAlgorithm());\r\n\t\t\t\tecipher.init(Cipher.ENCRYPT_MODE, key, paramSpec);\r\n\t\t\t\tin = string.getBytes(charSet);\r\n\t\t\t\tout = ecipher.doFinal(in);\r\n\t\t\t} catch (InvalidKeySpecException | NoSuchAlgorithmException | NoSuchPaddingException | InvalidKeyException\r\n\t\t\t\t\t| InvalidAlgorithmParameterException | UnsupportedEncodingException | IllegalBlockSizeException\r\n\t\t\t\t\t| BadPaddingException e) {\r\n\t\t\t\tlog.error(\"encode :\" + e.getMessage());\r\n\t\t\t}\r\n\t\t\tencodedString = new Base64().encodeAsString(out);\r\n\t\t\tif (encodedString.indexOf(\"/\", 0) > -1) {\r\n\t\t\t\tencodedString = encodedString.replace('/', '(');\r\n\t\t\t}\r\n\t\t} else if (encodingName.equalsIgnoreCase(\"DES/ECB/PKCS5Padding\")) {\r\n\t\t\ttry {\r\n\t\t\t\t// Get a cipher object.\r\n\t\t\t\tCipher cipher = Cipher.getInstance(\"DES/ECB/PKCS5Padding\");\r\n\t\t\t\tcipher.init(Cipher.ENCRYPT_MODE, generateKey());\r\n\r\n\t\t\t\t// Gets the raw bytes to encrypt, UTF8 is needed for\r\n\t\t\t\t// having a standard character set\r\n\t\t\t\tbyte[] stringBytes = string.getBytes(\"UTF8\");\r\n\r\n\t\t\t\t// encrypt using the cypher\r\n\t\t\t\tbyte[] raw = cipher.doFinal(stringBytes);\r\n\r\n\t\t\t\t// converts to base64 for easier display.\r\n\t\t\t\tBASE64Encoder encoder = new BASE64Encoder();\r\n\t\t\t\tencodedString = encoder.encode(raw);\r\n\t\t\t} catch (NoSuchAlgorithmException | NoSuchPaddingException | InvalidKeyException\r\n\t\t\t\t\t| UnsupportedEncodingException | IllegalBlockSizeException | BadPaddingException e) {\r\n\t\t\t\tlog.error(\"encode :\" + e.getMessage());\r\n\t\t\t}\r\n\r\n\t\t}\r\n\t\treturn encodedString;\r\n\t}", "public byte[] encode(byte[] pArray) {\n return encodeQuotedPrintable(PRINTABLE_CHARS, pArray);\n }", "private String encode(String paramString, char[] paramArrayOfchar, MessageDigest paramMessageDigest) {\n/* */ try {\n/* 522 */ paramMessageDigest.update(paramString.getBytes(\"ISO-8859-1\"));\n/* 523 */ } catch (UnsupportedEncodingException unsupportedEncodingException) {\n/* */ assert false;\n/* */ } \n/* 526 */ if (paramArrayOfchar != null) {\n/* 527 */ byte[] arrayOfByte1 = new byte[paramArrayOfchar.length];\n/* 528 */ for (byte b1 = 0; b1 < paramArrayOfchar.length; b1++)\n/* 529 */ arrayOfByte1[b1] = (byte)paramArrayOfchar[b1]; \n/* 530 */ paramMessageDigest.update(arrayOfByte1);\n/* 531 */ Arrays.fill(arrayOfByte1, (byte)0);\n/* */ } \n/* 533 */ byte[] arrayOfByte = paramMessageDigest.digest();\n/* */ \n/* 535 */ StringBuffer stringBuffer = new StringBuffer(arrayOfByte.length * 2);\n/* 536 */ for (byte b = 0; b < arrayOfByte.length; b++) {\n/* 537 */ int i = arrayOfByte[b] >>> 4 & 0xF;\n/* 538 */ stringBuffer.append(charArray[i]);\n/* 539 */ i = arrayOfByte[b] & 0xF;\n/* 540 */ stringBuffer.append(charArray[i]);\n/* */ } \n/* 542 */ return stringBuffer.toString();\n/* */ }", "private String base64Encode(String xmlAsString, String xmlEncoding) throws UnsupportedEncodingException {\r\n String xmlencodingDeclaration = \"<?xml version=\\\"1.0\\\" encoding=\\\"\" + xmlEncoding + \"\\\"?>\";\r\n byte[] xmlAsBytes = (xmlencodingDeclaration + xmlAsString).getBytes(xmlEncoding);\r\n\r\n byte[] xmlAsBase64 = Base64.encodeBase64(xmlAsBytes);\r\n\r\n // base64 is pure ascii\r\n String xmlAsBase64String = new String(xmlAsBase64, \"ascii\");\r\n\r\n return xmlAsBase64String;\r\n }", "public final String urlEncode() {\n\t\treturn urlEncode(UTF_8);\n\t}", "public static String encode(byte[] data) {\t\t\n\t\tif (data == null || data.length == 0) {\n\t\t\treturn \"\";\n\t\t}\n\t\t\n\t\tStringBuilder resultBuffer = new StringBuilder();\n\t\t//mod\n\t\tint m = data.length % 3;\n\t\t//amount of data group with 3 byte\n\t\tint g = (m == 0) ? (data.length / 3) : (data.length / 3 + 1);\n\t\tfinal byte[] _clear_buff = {0, 0, 0};\n\t\tbyte[] dataBuffer = new byte[3];\n\t\tchar[] codeBuffer = new char[4];\n\t\tint offset = 0;\n\t\tfor (int i = 0; i < g; ++i) {\n\t\t\t//clear buffer\n\t\t\tSystem.arraycopy(_clear_buff, 0, dataBuffer, 0, 3);\n\t\t\t//copy data for handling\n\t\t\tint copySize = (m != 0 && i == g - 1) ? m : 3;\n\t\t\tSystem.arraycopy(data, offset, dataBuffer, 0, copySize);\n\t\t\t//concatenate the byte data buffer as an integer\n\t\t\tint tmp = 0x00000000;\n\t\t\tfor (int j = 0, z = 2; j < 3; ++j, --z) {\n\t\t\t\tint tt = ((dataBuffer[j] & 0xff) << (z * 8));\n\t\t\t\ttmp ^= tt;\n\t\t\t}\n\t\t\t//encode current data buffer with base64\n\t\t\tfor (int k = 0; k < 4; ++k) {\n\t\t\t\tint p = (tmp >> (k * 6)) & 0x0000003F;\n\t\t\t\tcodeBuffer[3 - k] = _dict_[p];\n\t\t\t}\n\t\t\t\n\t\t\tif (copySize != 3) {\n\t\t\t\tfor (int e = 0; e < 3 - copySize; ++e) {\n\t\t\t\t\tcodeBuffer[3 - e] = '=';\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\tresultBuffer.append(codeBuffer);\n\t\t\toffset += 3;\n\t\t}\n\t\t\n\t\tString encodeText = resultBuffer.toString();\n\t\tresultBuffer.delete(0, resultBuffer.length());\n\t\treturn encodeText;\n\t}", "private String encodeBase64(String msg) {\n\t\tbyte[] bytesEncoded = Base64.encodeBase64(msg.getBytes());\n\t\t//System.out.println(\"encoded value is \" + new String(bytesEncoded));\n\n\t\treturn new String(bytesEncoded);\n\t}", "public static String encodeBase64(String string) {\n\t\tif (string == null) {\n\t\t\treturn null;\n\t\t}\n\n\t\treturn Base64.getEncoder().encodeToString(string.getBytes(UTF_8));\n\t}", "public static String encode (String original){\n\n // WRITE YOUR CODE HERE\n String encodeString = new String();\n int n = original.length();\n for (int i = 0; i < n; i++){\n int count = 1;\n while (i < n - 1 && original.charAt(i) == original.charAt(i + 1)){\n count++;\n i++;\n }\n if (count != 1) {\n \tencodeString = encodeString + count;\n }\n encodeString = encodeString + original.charAt(i);\n }\n return encodeString;\n\n }", "public String encode(String str, String charsetName) throws UnsupportedEncodingException {\n/* 230 */ if (str == null) {\n/* 231 */ return null;\n/* */ }\n/* 233 */ return StringUtils.newStringUsAscii(encode(str.getBytes(charsetName)));\n/* */ }", "private static String encodeToBase64(byte[] data) {\n return Base64.encodeToString(data, BASE64_EFLAGS);\n }", "public static String utf8Encode(String str, String defultReturn) {\n if (!TextUtils.isEmpty(str) && str.getBytes().length != str.length()) {\n try {\n return URLEncoder.encode(str, \"UTF-8\");\n } catch (UnsupportedEncodingException e) {\n return defultReturn;\n }\n }\n return str;\n }", "public static String encode(byte[] input)\r\n {\r\n return (input == null ? null : Base64.encode(input, 0, input.length));\r\n }", "public String encodeKey() {\n byte[] keyByte = secretKey.getEncoded();\n return Base64.getEncoder().encodeToString(keyByte);\n }", "private static void encodeStringToBuffer(String str, StringBuffer buf)\n {\n if (str == null || buf == null)\n {\n return;\n }\n\n // place the ascii value of each letter -32 into the buffer\n for (int letter = 0; letter < str.length(); letter++)\n {\n int intLetter = str.charAt(letter) - 32;\n\n if (intLetter < 10)\n {\n buf.append(\"0\");\n }\n buf.append(intLetter);\n }\n }", "public static String base64Encode(byte[] input) {\n return DatatypeConverter.printBase64Binary(input);\n }", "public static String encode(String in){\n in = in.replace(\"&\", \"&amp;\");\n in = in.replace(\"\\\"\", \"&quot;\");\n in = in.replace(\"<\", \"&lt;\");\n in = in.replace(\">\", \"&gt;\");\n log.debug(\"encoded string: \" + in);\n // FIXME: Consider double-encoding & if it is not part of &amp;\n return in;\n }", "@Override\r\n\t\tpublic String encode(String str) {\r\n\t\t\t// str to char[]\r\n\t\t\tchar content[] = str.toCharArray();\r\n\t\t\t\r\n\t\t\t// per char\r\n\t\t\tStringBuilder result = new StringBuilder(content.length);\r\n\t\t\tfor (int i = 0; i < content.length; i++) {\r\n\t\t\t\tswitch (content[i]) {\r\n\t\t\t\tcase '<':\r\n\t\t\t\t\tresult.append(\"&lt;\");\r\n\t\t\t\t\tbreak;\r\n\t\t\t\tcase '>':\r\n\t\t\t\t\tresult.append(\"&gt;\");\r\n\t\t\t\t\tbreak;\r\n\t\t\t\tcase '&':\r\n\t\t\t\t\tresult.append(\"&amp;\");\r\n\t\t\t\t\tbreak;\r\n\t\t\t\tcase '\"':\r\n\t\t\t\t\tresult.append(\"&quot;\");\r\n\t\t\t\t\tbreak;\r\n\t\t\t\tcase '\\'':\r\n\t\t\t\t\tresult.append(\"&apos;\");\r\n\t\t\t\t\tbreak;\r\n\t\t\t\tdefault:\r\n\t\t\t\t\tresult.append(content[i]);\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\treturn (result.toString());\r\n\t\t}", "public String encodePassword(String normalPassword, String key);", "@Override\r\n\t\tpublic String encode(String str) {\r\n\t\t\t// str to char[]\r\n\t\t\tchar content[] = str.toCharArray();\r\n\r\n\t\t\t// per char\r\n\t\t\tStringBuilder result = new StringBuilder(content.length);\r\n\t\t\tfor (int i = 0; i < content.length; i++) {\r\n\t\t\t\tswitch (content[i]) {\r\n\t\t\t\t\tcase '<':\r\n\t\t\t\t\t\tresult.append(\"&#60;\");\r\n\t\t\t\t\t\tbreak;\r\n\t\t\t\t\tcase '>':\r\n\t\t\t\t\t\tresult.append(\"&#62;\");\r\n\t\t\t\t\t\tbreak;\r\n\t\t\t\t\tcase '&':\r\n\t\t\t\t\t\tresult.append(\"&#38;\");\r\n\t\t\t\t\t\tbreak;\r\n\t\t\t\t\tcase '\"':\r\n\t\t\t\t\t\tresult.append(\"&#34;\");\r\n\t\t\t\t\t\tbreak;\r\n\t\t\t\t\tcase '\\'':\r\n\t\t\t\t\t\tresult.append(\"&#39;\");\r\n\t\t\t\t\t\tbreak;\r\n\t\t\t\t\tdefault:\r\n\t\t\t\t\t\tresult.append(content[i]);\r\n\t\t\t\t}\r\n\t\t\t}\r\n\r\n\t\t\treturn (result.toString());\r\n\t\t}", "public static void encode()\n {\n \n String s = BinaryStdIn.readString();\n //String s = \"ABRACADABRA!\";\n int len = s.length();\n int key = 0;\n \n // generating rotating string table\n String[] table = new String[len];\n for (int i = 0 ; i < len; i++)\n {\n table[i] = rotate(s, i, len);\n }\n \n // sort the table\n String[] sorted = new String[len];\n for(int i = 0 ; i < len; i++)\n {\n sorted[i] = table[i];\n }\n sort(sorted, len);\n \n //generating encoded string\n StringBuilder result = new StringBuilder();\n for(int i = 0 ; i < len; i++)\n result.append(sorted[i].charAt(len-1));\n \n //find the key index \n for(int i = 0 ; i < table.length; i++)\n {\n if(sorted[i].equals(s))\n {\n key = i;\n break;\n }\n }\n \n // output part\n \n BinaryStdOut.write(key);\n \n for(int i = 0 ; i < len; i++)\n BinaryStdOut.write(result.charAt(i)); // generate the output character by character\n \n BinaryStdOut.close();\n \n }", "private static String encodeWritable(Writable obj) throws IOException {\n DataOutputBuffer buf = new DataOutputBuffer();\n obj.write(buf);\n Base64 encoder = new Base64(0, null, true);\n byte[] raw = new byte[buf.getLength()];\n System.arraycopy(buf.getData(), 0, raw, 0, buf.getLength());\n return encoder.encodeToString(raw);\n }", "public static String utf8Encode(String str, String defultReturn) {\n if (!isEmpty(str) && str.getBytes().length != str.length()) {\n try {\n return URLEncoder.encode(str, \"UTF-8\");\n } catch (UnsupportedEncodingException e) {\n return defultReturn;\n }\n }\n return str;\n }", "public String getEnryptedString() {\n this.enryptedString= encoderFunc();\n return this.enryptedString;\n }", "public String encodeValue(String value) {\r\n\t\treturn (null == value) ? \"\" : JSONUtil.encodeString(value);\r\n\t}", "public void encodeMessage() {\n for (int i = message.length() - 1; i >= 0; i--) {\n message.insert(i, String.valueOf(message.charAt(i)).repeat(2));\n }\n }", "public String encode(String text) {\n\t\t// TODO fill this in.\n\t\tString binaryCode = \"\";\n\n\t\tchar[] array = text.toCharArray();\n\n\t\tfor(char c : chars.keySet()){\n\t\t\tString code = findPath(c, root, \"\");\n\t\t\tcodeMap.put(c, code);\n\t\t\tSystem.out.println(c + \" \" + code);\t\t\t\t\t\t\t// print char codes\n\t\t}\n\n\t\tfor(char t : array){\n\t\t\tString charCode = codeMap.get(t);\n\t\t\tbinaryCode = binaryCode + charCode;\n\t\t}\n\n\t\treturn binaryCode;\n\t}", "public String encode(List<String> strs) {\n StringBuilder b = new StringBuilder();\n for (String s : strs) {\n b.append(s.length()).append(\"#\").append(s);\n }\n return b.toString();\n }", "public String encode(List<String> strs) {\n String res = \"\";\n for(String s : strs)\n {\n int len = s.length();\n res += len + \"/\" + s;\n }\n return res;\n }", "public static String encode(String str, String encoding) throws UnsupportedEncodingException {\n return Base64.getEncoder().encodeToString(str.getBytes(encoding));\n }", "public String encode(String input) {\n String encoded = \"\";\n char[] message = input.toCharArray();\n for (int j = 0; j < message.length; j++) { //takes input into a array of chars\n encodingQueue.enqueue(message[j]);\n }\n char lastvalue =0;\n boolean islastvaluenum= false;\n for(int i=0; i<message.length;i++) {\n char character = encodingQueue.dequeue();\n if(character != ' ') { //if not a space\n String alphabet = \"abcdefghijklmnopqrstuvwxyz\";\n if(islastvaluenum ==false) { //if last value was not a num, then proceed normally with first set of numbers\n char encodedvalue=enumerate(character,1);\n if(encodedvalue !=0) {\n islastvaluenum = true;\n lastvalue = encodedvalue;\n encoded = encoded +encodedvalue;\n }\n else {\n islastvaluenum = false;\n int shiftvalue = 5+(2*i);\n boolean charfound = false;\n char[] chararray = (alphabet.toUpperCase()).toCharArray();\n char output = 'n';\n for (int j=0;j<chararray.length;j++) { // look through the alphabet and see if character matches, then shift accordingly to shiftby\n if (charfound==false) {\n if (character == chararray[j]) {\n output = chararray[(j+chararray.length+shiftvalue)% chararray.length];\n charfound = true;\n }\n }\n }\n character = output;\n lastvalue = character;\n encoded = encoded+ character;\n }\n }\n else {\n char encodedvalue=enumerate(character,2);//if last value was a num, then proceed with second set of numbers\n if(encodedvalue !=0) {\n islastvaluenum = true;\n lastvalue = encodedvalue;\n encoded = encoded +encodedvalue;\n }\n else {\n islastvaluenum = false;\n int shiftvalue = (5+(2*i))+((lastvalue-'0')*(-2));\n boolean charfound = false;\n char[] chararray = (alphabet.toUpperCase()).toCharArray();\n char output = 'n';\n for (int j=0;j<chararray.length;j++) {// look through the alphabet and see if character matches, then shift accordingly to shiftby\n if (charfound==false) {\n if (character == chararray[j]) {\n output = chararray[(j+chararray.length+shiftvalue)% chararray.length];\n charfound = true;\n }\n }\n }\n character = output;\n lastvalue = character;\n encoded = encoded+ character;\n }\n }\n\n }\n else{\n encoded = encoded + ' ';\n }\n }\n return encoded;\n }", "public static String encodeEscapes(@Nullable String inString)\n {\n if(inString == null)\n return \"\";\n\n // replace all special characters with some equivalent\n StringBuilder result = new StringBuilder();\n for(int i = 0; i < inString.length(); i++)\n {\n char c = inString.charAt(i);\n int pos = s_escapes.indexOf(c);\n\n if(pos >= 0)\n result.append(s_marker + pos + s_marker);\n else\n result.append(c);\n }\n\n return result.toString();\n }", "public static String base64Encode(int value)\n {\n StringBuffer buffer = new StringBuffer(6);\n\n // For now, let's just use the lower 3 bytes. This increases\n // the possibility of collisions, but it allows us to go\n // from a 6 char to 4 char id.\n\n for (int i = 0; i < 4; i++)\n buffer.append(_BASE_64_CHARS[((value >> (6 * i)) & 0x3f)]);\n\n return buffer.toString();\n }", "public static String encode(String str)\r\n\t{\r\n\t\ttry\r\n\t\t{\r\n\t\t\treturn java.net.URLEncoder.encode(str, \"UTF-8\");\r\n\t\t}\r\n\t\tcatch(java.io.UnsupportedEncodingException ue)\r\n\t\t{\r\n\t\t\treturn str;\r\n\t\t}\r\n\t}", "private static String normalizeB64String(String s) {\n while(s.length() % 4 != 0)\n s += \"=\";\n return s;\n }", "public String encode(String s) {\n if (s == null || s.length() == 0) {\n return \"\";\n }\n int n = s.length();\n String[][] dp = new String[n][n];\n for (int len = 1; len <= n; len++) {\n if (len == 10) {\n int a = 1;\n }\n for (int i = 0; i + len - 1 < n; i++) {\n int j = i + len - 1;\n String word = s.substring(i, j + 1);\n dp[i][j] = word;\n if (len <= 4) {\n continue;\n }\n for (int k = i; k < j; k++) {\n if (dp[i][k].length() + dp[k + 1][j].length() < dp[i][j].length()) {\n dp[i][j] = dp[i][k] + dp[k + 1][j];\n }\n }\n String tmp = word + word;\n int second = tmp.indexOf(word, 1);\n if (second > 0 && second < len) {\n int times = len / (second);\n String sub = dp[i][i + second - 1];\n String encoded = times + \"[\" + sub + \"]\";\n if (encoded.length() < dp[i][j].length()) {\n dp[i][j] = encoded;\n }\n }\n }\n }\n return dp[0][s.length() - 1];\n }", "public CodePointIterator base64Encode() {\n return base64Encode(Base64Alphabet.STANDARD, true);\n }", "public String encode() {\n\t\tString encoded_string;\n\t\tencoded_string = MEDIA_FIELD;\n\t\tif (media != null)\n\t\t\tencoded_string += media + Separators.SP + port;\n\t\t// Workaround for Microsoft Messenger contributed by Emil Ivov\n\t\t// Leave out the nports parameter as this confuses the messenger.\n\t\tif (nports > 1)\n\t\t\tencoded_string += Separators.SLASH + nports;\n\n\t\tif (proto != null)\n\t\t\tencoded_string += Separators.SP + proto;\n\n\t\tif (formats != null)\n\t\t\tencoded_string += Separators.SP + encodeFormats();\n\n\t\tencoded_string += Separators.NEWLINE;\n\t\treturn encoded_string;\n\t}", "@Test\n public void testEncode() {\n LOGGER.info(\"testEncode\");\n final String actual = new AtomString().encode();\n final String expected = \"0:\";\n assertEquals(expected, actual);\n }", "public String encode() {\n\t\tString encoded_string = ATTRIBUTE_FIELD;\n\t\tif (attribute != null)\n\t\t\tencoded_string += attribute.encode();\n\t\treturn encoded_string + Separators.NEWLINE;\n\t}", "private String compressString(String input) throws IOException {\n\t\tByteArrayOutputStream output = new ByteArrayOutputStream();\n\t\tGZIPOutputStream gzip = new GZIPOutputStream(output);\n\n\t\tgzip.write(input.getBytes(\"UTF-8\"));\n\t\tgzip.close();\n\t\toutput.close();\n\n\t\treturn Base64.encodeBase64String(output.toByteArray());\n\t}", "public static String encode(String toEncode)\n {\n return com.github.terefang.jldap.ldap.LDAPUrl.encode( toEncode);\n }", "public String encrypt(String unencryptedString) throws InvalidKeyException, UnsupportedEncodingException, IllegalBlockSizeException, BadPaddingException {\n String encryptedString = null;\n try{\n cipher.init(Cipher.ENCRYPT_MODE, key);\n byte[] plainText = unencryptedString.getBytes(UNICODE_FORMAT);\n byte[] encryptedText = cipher.doFinal(plainText);\n BASE64Encoder base64encoder = new BASE64Encoder();\n // encryptedString = base64encoder.<span class=\"\\IL_AD\\\" id=\"\\IL_AD9\\\">encode</span>(encryptedText);\n encryptedString = base64encoder.encode(encryptedText);\n }\n catch (Exception e) {\n e.printStackTrace();\n }\n return encryptedString;\n }", "public static String base64Encode(final byte[] key) {\n return Base64.encode(key);\n }", "@VisibleForTesting\n static String encode(String source, CharMatcher charactersToKeep) {\n byte[] bytes = source.getBytes(StandardCharsets.UTF_8);\n ByteArrayOutputStream bos = new ByteArrayOutputStream(source.length()); // approx sizing\n boolean wasChanged = false;\n for (byte b : bytes) {\n if (charactersToKeep.matches(toChar(b))) {\n bos.write(b);\n } else {\n bos.write('%');\n char hex1 = Character.toUpperCase(Character.forDigit((b >> 4) & 0xF, 16));\n char hex2 = Character.toUpperCase(Character.forDigit(b & 0xF, 16));\n bos.write(hex1);\n bos.write(hex2);\n wasChanged = true;\n }\n }\n return wasChanged ? new String(bos.toByteArray(), StandardCharsets.UTF_8) : source;\n }", "@Override\n protected final String encode(String unencoded) {\n try {\n return StringUtils.isBlank(unencoded) ? \"\" : URLEncoder.encode(unencoded, \"UTF-8\");\n } catch (UnsupportedEncodingException ex) {\n java.util.logging.Logger.getLogger(PostRedirectGetWithCookiesFormHelperImpl.class.getName()).log(Level.SEVERE, null, ex);\n return unencoded;\n }\n }", "public String getEncodedValue() throws UnsupportedEncodingException {\n return URLEncoder.encode(this.value, \"UTF-8\");\n }", "public static String encB64(byte[] data) {\n return Base64.encodeToString(data,Base64.DEFAULT);\n }", "public String encode(List<String> strs) {\r\n StringBuilder sb = new StringBuilder();\r\n for(String s: strs) {\r\n sb.append(intToString(s));\r\n sb.append(s);\r\n }\r\n return sb.toString();\r\n }", "public static String encode(byte[] bytes){\n //USED\n ByteArrayInputStream in = new ByteArrayInputStream(bytes);\n /*\n * Number of bytes will be equal to (string * (4/3)) rounded\n * upwards.\n */\n int mod;\n int length = bytes.length;\n if ((mod = length % 3) != 0){\n length += 3 - mod;\n }\n length = length * 4 / 3;\n ByteArrayOutputStream out = new ByteArrayOutputStream(length);\n try {\n encode(in, out);\n } catch (IOException x){\n /* This should never happen! */\n throw new RuntimeException(x);\n }\n return new String(out.toByteArray());\n }", "public EncodeAndDecodeStrings() {}", "public String encode(String pString) throws EncoderException {\n if (pString == null) {\n return null;\n }\n try {\n return encode(pString, getDefaultCharset());\n } catch(UnsupportedEncodingException e) {\n throw new EncoderException(e.getMessage());\n }\n }", "public static char[] encode(byte[] in) {\r\n \t\treturn encode(in, in.length);\r\n \t}", "public String encode() {\n\tStringBuffer retval = new StringBuffer();\n\n\tif (mediaField != null) \n\t retval.append(mediaField.encode());\n\n\tif (informationField != null) \n\t retval.append(informationField.encode());\n\n\tif (connectionField != null) \n\t retval.append(connectionField.encode());\n\n\tif (bandwidthFields != null) {\n\t for (int i = 0; i < bandwidthFields.size(); i++) {\n\t\tBandwidthField bandwidthField = \n\t\t (BandwidthField) bandwidthFields.elementAt(i);\n\t\tretval.append(bandwidthField.encode());\n\t }\n\t}\n\n\tif (keyField != null) \n\t retval.append(keyField.encode());\n\n\tif (attributeFields != null) {\n\t for (int i = 0; i < attributeFields.size(); i++) \n\t\tretval.append(((SDPField)attributeFields.elementAt(i)).\n\t\t\t encode());\n\t}\n\n\treturn retval.toString();\n }", "@Test\n public void encodeAsString()\n {\n int value = 3;\n BinaryEncoder encoder = new BinaryEncoder(16);\n String result = encoder.encodeAsString(value);\n if (IS_VERBOSE)\n {\n System.out.println(\"result = \" + result);\n }\n assertNotNull(result);\n assertEquals(\"0011\", result);\n\n value = 20; // > 16 outside range\n result = encoder.encodeAsString(value);\n if (IS_VERBOSE)\n {\n System.out.println(\"result = \" + result);\n }\n assertNotNull(result);\n assertEquals(\"0100\", result); // Best fit into 4 digits; ignores higher bits\n\n encoder = new BinaryEncoder(0.0, 360.0, 1.0);\n assertEquals(9, encoder.getLength());\n assertEquals(\"000000000\", encoder.encodeAsString(0.0));\n assertEquals(\"000000001\", encoder.encodeAsString(1.0));\n assertEquals(\"000101101\", encoder.encodeAsString(45.0));\n assertEquals(\"001011010\", encoder.encodeAsString(90.0));\n assertEquals(\"010110100\", encoder.encodeAsString(180.0));\n assertEquals(\"101101000\", encoder.encodeAsString(360.0));\n }", "public static String padBitsForHashing(String message) throws UnsupportedEncodingException {\n\n\t\tint rem = 0;\n\t\tint padCount = 0;\n\t\tint lengthOfMsg = message.getBytes(\"UTF-8\").length;\n\t\tString outputMessage = new String();\n\t\toutputMessage = message.toString();\n\t\toutputMessage = outputMessage.concat(\"1\"); // Padding done at least once\n\t\tint lengthOfUnpadedMsg = (lengthOfMsg + 8 + 1)*8; //64 is the size of the field L and 8 will be the size of the 1 that was appended\n\t\tif (lengthOfUnpadedMsg > 512) {\n\t\t\trem = lengthOfUnpadedMsg % 512;\n\t\t\tif (rem > 0) {\n\t\t\t\tpadCount = 512 - rem;\n\t\t\t}\n\n\t\t} else {\n\t\t\tpadCount = 512 - lengthOfUnpadedMsg;\n\t\t}\n\t\tfor (int i = 0; i < padCount;i += 8) {\n\t\t\toutputMessage = outputMessage .concat(\"0\"); \n\t\t}\n\t\toutputMessage = outputMessage .concat(String.format(\"%08d\", lengthOfMsg));//representing length of message into a 64bit value\n\t\treturn outputMessage ;\n\n\t}", "private String encodeBase64(String ldapPwd){\n try {\n return CryptoUtils.object2String(ldapPwd);\n } catch (Exception e) {\n throw new RuntimeException(e);\n }\n }" ]
[ "0.7062943", "0.66447383", "0.65815455", "0.6566165", "0.650839", "0.65050083", "0.6462702", "0.6420864", "0.63873774", "0.6374848", "0.6310446", "0.63097864", "0.6282176", "0.6270857", "0.62516344", "0.62456876", "0.62357205", "0.6196016", "0.617438", "0.6157841", "0.6148062", "0.614066", "0.6132891", "0.61226225", "0.6119011", "0.61187595", "0.60991925", "0.60778266", "0.6049971", "0.6035043", "0.60171574", "0.60093385", "0.60025287", "0.59990436", "0.59985167", "0.59975666", "0.59967685", "0.5966178", "0.596334", "0.59546643", "0.59535044", "0.5941508", "0.5910036", "0.59093523", "0.59085006", "0.5882914", "0.5879993", "0.58745", "0.5869175", "0.58563846", "0.5842608", "0.5836475", "0.5834061", "0.5833248", "0.58263654", "0.5821696", "0.5806072", "0.57979983", "0.57905936", "0.5782465", "0.577871", "0.5778308", "0.57762885", "0.5775413", "0.57727855", "0.57679147", "0.5766503", "0.57582176", "0.57560384", "0.57534623", "0.57468396", "0.57335424", "0.57275087", "0.57231426", "0.57176745", "0.57141894", "0.5707282", "0.5700109", "0.5696162", "0.5681362", "0.56741494", "0.5655695", "0.5655588", "0.5653869", "0.56519926", "0.56507045", "0.56235915", "0.5623484", "0.56225497", "0.56205666", "0.56185144", "0.5607316", "0.5597711", "0.55975986", "0.55972147", "0.55961955", "0.55943334", "0.5591222", "0.5581423", "0.5578854" ]
0.7018091
1
All classes that either depend on other objects or could have dependent objects must implement Dependable, and contain a DependencyNode. The DependencyManager class handles the dependency graph structure, and uses the Dependable interface to link the graph structure with actual objects in the program. To make an object implement Dependable, the object should contain an instance of DependencyNode, and return it in the dependencyNode() method. To put this in a class, you can copy the code fragmet at the end of Dependable.java into the class.
public interface Dependable { /** * This method is called by the Dependency Manager when the * Dependable object should be updated. * This method is called when the actual definition or dependencies of * an object change. Expressions need to be rebuilt. * * @param updatingObjects a set of all the objects that have been * or will be updated */ public void dependencyUpdateDef(Set updatingObjects); /** * This method is called by the Dependency Manager when the * Dependable object should be updated. * This method is called when only a value changes, and the type * of the value does not change. An example of this kind of update * is when the value of a variable changes, but the definition of * it does not. Expressions do not have to be rebuilt. * * @param updatingObjects a set of all the objects that have been * or will be updated */ public void dependencyUpdateVal(Set updatingObjects); /** * @return the depdenency graph node for this class */ public DependencyNode dependencyNode(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "Dependency createDependency();", "Dependency createDependency();", "public abstract DependencyGraph getDependencyGraph();", "protected final Dependency createDependency( Object obj, String name) \r\n {\r\n\treturn dependencyFactory.createDependency( obj, name );\r\n }", "public void connectDependencies();", "RelationalDependency createRelationalDependency();", "TaskDependency createTaskDependency();", "public interface Dependency extends Relationship , java.io.Serializable\n{\n // declare/define something only in the code\n // please fill in/modify the following section\n // -beg- preserve=no 327A646F00E6 detail_begin \"Dependency\"\n\n // -end- 327A646F00E6 detail_begin \"Dependency\"\n\n // -beg- preserve=no 3E423DBE00A1 head327A646F00E6 \"changeClient\"\n public void changeClient(ModelElement oldClient, ModelElement newClient)\n // -end- 3E423DBE00A1 head327A646F00E6 \"changeClient\"\n // declare any checked exceptions\n // please fill in/modify the following section\n // -beg- preserve=no 3E423DBE00A1 throws327A646F00E6 \"changeClient\"\n\n // -end- 3E423DBE00A1 throws327A646F00E6 \"changeClient\"\n ; // empty\n\n // -beg- preserve=no 3E423DCA0134 head327A646F00E6 \"changeSupplier\"\n public void changeSupplier(ModelElement oldSupplier, ModelElement newSupplier)\n // -end- 3E423DCA0134 head327A646F00E6 \"changeSupplier\"\n // declare any checked exceptions\n // please fill in/modify the following section\n // -beg- preserve=no 3E423DCA0134 throws327A646F00E6 \"changeSupplier\"\n\n // -end- 3E423DCA0134 throws327A646F00E6 \"changeSupplier\"\n ; // empty\n\n /** add a Client.\n * \n * @see #removeClient\n * @see #containsClient\n * @see #iteratorClient\n * @see #clearClient\n * @see #sizeClient\n */\n // -beg- preserve=no 33FFE57B03B3 add_head327A646F00E6 \"Dependency::addClient\"\n public void addClient(ModelElement client1)\n // -end- 33FFE57B03B3 add_head327A646F00E6 \"Dependency::addClient\"\n ; // empty\n\n /** disconnect a Client.\n * @see #addClient\n */\n // -beg- preserve=no 33FFE57B03B3 remove_head327A646F00E6 \"Dependency::removeClient\"\n public ModelElement removeClient(ModelElement client1)\n // -end- 33FFE57B03B3 remove_head327A646F00E6 \"Dependency::removeClient\"\n ; // empty\n\n /** tests if a given Client is connected.\n * @see #addClient\n */\n // -beg- preserve=no 33FFE57B03B3 test_head327A646F00E6 \"Dependency::containsClient\"\n public boolean containsClient(ModelElement client1)\n // -end- 33FFE57B03B3 test_head327A646F00E6 \"Dependency::containsClient\"\n ; // empty\n\n /** used to enumerate all connected Clients.\n * @see #addClient\n */\n // -beg- preserve=no 33FFE57B03B3 get_all_head327A646F00E6 \"Dependency::iteratorClient\"\n public java.util.Iterator iteratorClient()\n // -end- 33FFE57B03B3 get_all_head327A646F00E6 \"Dependency::iteratorClient\"\n ; // empty\n\n /** disconnect all Clients.\n * @see #addClient\n */\n // -beg- preserve=no 33FFE57B03B3 remove_all_head327A646F00E6 \"Dependency::clearClient\"\n public void clearClient()\n // -end- 33FFE57B03B3 remove_all_head327A646F00E6 \"Dependency::clearClient\"\n ; // empty\n\n /** returns the number of Clients.\n * @see #addClient\n */\n // -beg- preserve=no 33FFE57B03B3 size_head327A646F00E6 \"Dependency::sizeClient\"\n public int sizeClient()\n // -end- 33FFE57B03B3 size_head327A646F00E6 \"Dependency::sizeClient\"\n ; // empty\n\n /** DONT USE; link management internal\n */\n // -beg- preserve=no 33FFE57B03B3 _link_body327A646F00E6 \"Dependency::_linkClient\"\n public void _linkClient(ModelElement client1);\n // -end- 33FFE57B03B3 _link_body327A646F00E6 \"Dependency::_linkClient\"\n\n /** DONT USE; link management internal\n */\n // -beg- preserve=no 33FFE57B03B3 _unlink_body327A646F00E6 \"Dependency::_unlinkClient\"\n public void _unlinkClient(ModelElement client1);\n // -end- 33FFE57B03B3 _unlink_body327A646F00E6 \"Dependency::_unlinkClient\"\n\n /** add a Supplier.\n * \n * @see #removeSupplier\n * @see #containsSupplier\n * @see #iteratorSupplier\n * @see #clearSupplier\n * @see #sizeSupplier\n */\n // -beg- preserve=no 335C0D7A02E4 add_head327A646F00E6 \"Dependency::addSupplier\"\n public void addSupplier(ModelElement supplier1)\n // -end- 335C0D7A02E4 add_head327A646F00E6 \"Dependency::addSupplier\"\n ; // empty\n\n /** disconnect a Supplier.\n * @see #addSupplier\n */\n // -beg- preserve=no 335C0D7A02E4 remove_head327A646F00E6 \"Dependency::removeSupplier\"\n public ModelElement removeSupplier(ModelElement supplier1)\n // -end- 335C0D7A02E4 remove_head327A646F00E6 \"Dependency::removeSupplier\"\n ; // empty\n\n /** tests if a given Supplier is connected.\n * @see #addSupplier\n */\n // -beg- preserve=no 335C0D7A02E4 test_head327A646F00E6 \"Dependency::containsSupplier\"\n public boolean containsSupplier(ModelElement supplier1)\n // -end- 335C0D7A02E4 test_head327A646F00E6 \"Dependency::containsSupplier\"\n ; // empty\n\n /** used to enumerate all connected Suppliers.\n * @see #addSupplier\n */\n // -beg- preserve=no 335C0D7A02E4 get_all_head327A646F00E6 \"Dependency::iteratorSupplier\"\n public java.util.Iterator iteratorSupplier()\n // -end- 335C0D7A02E4 get_all_head327A646F00E6 \"Dependency::iteratorSupplier\"\n ; // empty\n\n /** disconnect all Suppliers.\n * @see #addSupplier\n */\n // -beg- preserve=no 335C0D7A02E4 remove_all_head327A646F00E6 \"Dependency::clearSupplier\"\n public void clearSupplier()\n // -end- 335C0D7A02E4 remove_all_head327A646F00E6 \"Dependency::clearSupplier\"\n ; // empty\n\n /** returns the number of Suppliers.\n * @see #addSupplier\n */\n // -beg- preserve=no 335C0D7A02E4 size_head327A646F00E6 \"Dependency::sizeSupplier\"\n public int sizeSupplier()\n // -end- 335C0D7A02E4 size_head327A646F00E6 \"Dependency::sizeSupplier\"\n ; // empty\n\n /** DONT USE; link management internal\n */\n // -beg- preserve=no 335C0D7A02E4 _link_body327A646F00E6 \"Dependency::_linkSupplier\"\n public void _linkSupplier(ModelElement supplier1);\n // -end- 335C0D7A02E4 _link_body327A646F00E6 \"Dependency::_linkSupplier\"\n\n /** DONT USE; link management internal\n */\n // -beg- preserve=no 335C0D7A02E4 _unlink_body327A646F00E6 \"Dependency::_unlinkSupplier\"\n public void _unlinkSupplier(ModelElement supplier1);\n // -end- 335C0D7A02E4 _unlink_body327A646F00E6 \"Dependency::_unlinkSupplier\"\n\n /** add a Presentation.\n * \n * @see #removePresentation\n * @see #containsPresentation\n * @see #iteratorPresentation\n * @see #clearPresentation\n * @see #sizePresentation\n */\n // -beg- preserve=no 362409A9000A add_head327A646F00E6 \"ModelElement::addPresentation\"\n public void addPresentation(PresentationElement presentation1)\n // -end- 362409A9000A add_head327A646F00E6 \"ModelElement::addPresentation\"\n ; // empty\n\n /** disconnect a Presentation.\n * @see #addPresentation\n */\n // -beg- preserve=no 362409A9000A remove_head327A646F00E6 \"ModelElement::removePresentation\"\n public PresentationElement removePresentation(PresentationElement presentation1)\n // -end- 362409A9000A remove_head327A646F00E6 \"ModelElement::removePresentation\"\n ; // empty\n\n /** tests if a given Presentation is connected.\n * @see #addPresentation\n */\n // -beg- preserve=no 362409A9000A test_head327A646F00E6 \"ModelElement::containsPresentation\"\n public boolean containsPresentation(PresentationElement presentation1)\n // -end- 362409A9000A test_head327A646F00E6 \"ModelElement::containsPresentation\"\n ; // empty\n\n /** used to enumerate all connected Presentations.\n * @see #addPresentation\n */\n // -beg- preserve=no 362409A9000A get_all_head327A646F00E6 \"ModelElement::iteratorPresentation\"\n public java.util.Iterator iteratorPresentation()\n // -end- 362409A9000A get_all_head327A646F00E6 \"ModelElement::iteratorPresentation\"\n ; // empty\n\n /** disconnect all Presentations.\n * @see #addPresentation\n */\n // -beg- preserve=no 362409A9000A remove_all_head327A646F00E6 \"ModelElement::clearPresentation\"\n public void clearPresentation()\n // -end- 362409A9000A remove_all_head327A646F00E6 \"ModelElement::clearPresentation\"\n ; // empty\n\n /** returns the number of Presentations.\n * @see #addPresentation\n */\n // -beg- preserve=no 362409A9000A size_head327A646F00E6 \"ModelElement::sizePresentation\"\n public int sizePresentation()\n // -end- 362409A9000A size_head327A646F00E6 \"ModelElement::sizePresentation\"\n ; // empty\n\n /** DONT USE; link management internal\n */\n // -beg- preserve=no 362409A9000A _link_body327A646F00E6 \"ModelElement::_linkPresentation\"\n public void _linkPresentation(PresentationElement presentation1);\n // -end- 362409A9000A _link_body327A646F00E6 \"ModelElement::_linkPresentation\"\n\n /** DONT USE; link management internal\n */\n // -beg- preserve=no 362409A9000A _unlink_body327A646F00E6 \"ModelElement::_unlinkPresentation\"\n public void _unlinkPresentation(PresentationElement presentation1);\n // -end- 362409A9000A _unlink_body327A646F00E6 \"ModelElement::_unlinkPresentation\"\n\n // declare/define something only in the code\n // please fill in/modify the following section\n // -beg- preserve=no 327A646F00E6 detail_end \"Dependency\"\n\n // -end- 327A646F00E6 detail_end \"Dependency\"\n\n}", "static public Collection<TypedDependency> dependencies(Tree thisTree)\n\t{\n\t\tGrammaticalStructure thisStructure = Analyzer.theGrammaticalStructureFactory.newGrammaticalStructure(thisTree);\n\t\treturn theFactory.make(thisStructure);\n\t}", "public interface ObjectGraph {\n\n\t\n\t/**\n\t * As in neo4j, starts a new transaction and associates it with the current thread.\n\t * @return a transaction from NeoService.\n\t */\n\tTransaction beginTx();\n\n\t/**\n\t * Mirror a java object within the neo4j graph. Only fields annotated with {@code}neo\n\t * will be considered.\n\t * @param o\n\t */\n\t<A> void persist(A... o);\n\n\t/**\n\t * removes all data representing an object from the graph.\n\t * \n\t * @param o an object retrieved from this {@link ObjectGraph}\n\t */\n\tvoid delete(Object... o);\n\t\n\t\n\t/**\n\t * Looks up a neo4j graph node using it's java object\n\t * mirror. \n\t * @param o an object retrieved from this {@link ObjectGraph}\n\t * @return neo4j node represented by o\n\t */\n\tNode get(Object o);\n\t\n\t/**\n\t * Looks up all instances of {@code}type in the graph.\n\t * \n\t * @param type a type previously stored in the graph\n\t * @return a Collection of {@code}type instances.\n\t */\n\t<T> Collection<T> get(Class<T> type);\n\n\t/**\n\t * Type safe lookup of object given it's neo4j nodeid.\n\t * Your domain classes may use {@link Nodeid#id()} to discover\n\t * their neo4j nodeid. \n\t * \n\t * @param t\n\t * @param key neo4j node id.\n\t * @return\n\t */\n\t<T> T get(Class<T> t, long key);\n\n\t\n\t/**\n\t * Return an object represented by <code>node</code> provided\n\t * the node was created by jo4neo.\n\t * \n\t * @param node\n\t * @return an object that mirrors node.\n\t */\n\tObject get(Node node);\n\t\n\t/**\n\t * Looks up the node representation of a given \n\t * uri. This method may update your graph if no node\n\t * was previously allocated for the uri.\n\t * \n\t * @return the node representation of uri.\n\t */\n\tNode get(URI uri);\n\n\n\t/**\n\t * Unmarshal a collections of nodes into objects.\n\t * \n\t */\n\t<T> Collection<T> get(Class<T> type, Iterable<Node> nodes);\n\n\t/**\n\t * Closes this ObjectGraph after which it will be unavailable \n\t * for use. Calling close is necessary, and should be called even\n\t * if the application is halted suddenly. ObjectGraph's maintain \n\t * a lucene index which may become corrupt without proper shutdown.\n\t * \n\t */\n\tvoid close();\n\n\t/**\n\t * Begin fluent interface find. <code>a</code> should be \n\t * a newly constructed instance as it's contents will be modified/initialized\n\t * by this call.\n\t * <pre>\n\t * <code>\n\t * Customer customer = new Customer();\n\t * customer = graph.find(customer).where(customer.id).is(123).result();\n\t * </code>\n\t * </pre>\n\t * \n\t * @param a\n\t * @return\n\t */\n\t<A> Where<A> find(A a);\n\n\t/**\n\t * Counts child entities without loading objects into memory. This is preferable to \n\t * using Collection.size(), which would load the full collection into memory.\n\t * <pre>\n\t * <code>\n\t * Customer customer = new Customer();\n\t * customer = graph.find(customer).where(customer.id).is(123).result();\n\t * long numOrders = graph.count(customer.orders);\n\t * </code>\n\t * </pre>\n\t * \n\t * @param values a collection value from a jo4neo annotated field.\n\t * @return\n\t */\n\tlong count(Collection<? extends Object> values);\n\n\t/**\n\t * Returns a collection of entities added since <code>d</code>.\n\t * Type <code>t</code> must be annotated with {@link Timeline}\n\t * \n\t * @see Timeline\n\t * \n\t */\n\t<T> Collection<T> getAddedSince(Class<T> t, Date d);\n\n\t/**\n\t * Returns a collection of entities added bewteen dates from and to.\n\t * Type <code>t</code> must be annotated with {@link Timeline}.\n\t * \n\t * @see Timeline\n\t */\n\t<T> Collection<T> getAddedBetween(Class<T> t, Date from,\n\t\t\tDate to);\n\n\t\n\t/**\n\t * Returns up to <code>max</code> most recently added instances of type <code>t</code>\n\t * \n\t * @param max limit the number of instances returned\n\t * @see neo#recency()\n\t */\n\t<T> Collection<T> getMostRecent(Class<T> t, int max);\n\t\n\t\n\t<T> T getSingle(Class<T> t, String indexname, Object value);\n\t\n\t<T> Collection<T> get(Class<T> t, String indexname, Object value);\n\t\n\t<T> Collection<T> fullTextQuery(Class<T> t, String indexname, Object value);\n\n}", "public IManagedDependencyGenerator getDependencyGenerator();", "ISChangePropagationDueToInterfaceDependencies createISChangePropagationDueToInterfaceDependencies();", "Set<DependencyItem> getIDependOn(Class<?> type);", "void addDependsOnMe(DependencyItem dependency);", "public interface ClassNode\n{\n}", "public Object caseRDependency(RDependency object) {\n\t\treturn null;\n\t}", "public interface Node extends TreeComponent {\n /**\n * The types of decision tree nodes available.\n */\n enum NodeType {\n Internal,\n Leaf\n }\n\n /**\n * Gets the type of this node.\n * @return The type of node.\n */\n NodeType getType();\n\n void print();\n\n String getClassLabel(DataTuple tuple);\n}", "ISChangePropagationDueToDataDependencies createISChangePropagationDueToDataDependencies();", "public interface INode\n{\n // read/write forces and integration\n void resetForce();\n double getForce();\n double step(double interval);\n void addForce(XY force);\n\n // read/write position\n void setPos(XY pos);\n @NotNull\n XY getPos();\n\n // read-only connections\n boolean connects(INode n);\n boolean connectsForwards(INode to);\n boolean connectsBackwards(INode from);\n Collection<DirectedEdge> getConnections();\n Collection<DirectedEdge> getInConnections();\n Collection<DirectedEdge> getOutConnections();\n DirectedEdge getConnectionTo(INode node);\n DirectedEdge getConnectionFrom(INode from);\n\n // other read-only properties\n String longName();\n String getCodes();\n String getTemplate();\n double getRad();\n\n // misc\n String print(int tab, boolean full);\n\n // indices created and read-back for handy data access when relaxing\n void setIdx(int i);\n int getIdx();\n\n // colour for pretty drawing\n int getColour();\n void setColour(int c);\n\n // name (currently writable for showing door <-> key relations etc\n String getName();\n void setName(String s);\n\n // access the geometry-layout object for this node...\n GeomLayout.IGeomLayoutCreateFromNode geomLayoutCreator();\n}", "abstract void depComponent(DepComponent depComponent);", "public interface Node extends Serializable {\n\n\tvoid setOwner(Object owner);\n Object getOwner();\n\n String getName();\n Node getChild(int i);\n List<Node> childList();\n\n Node attach(int id, Node n) throws VetoTypeInduction;\n void induceOutputType(Class type) throws VetoTypeInduction;\n int getInputCount();\n\tClass getInputType(int id);\n List<Class> getInputTypes();\n Class getOutputType();\n Tuple.Two<Class,List<Class>> getType();\n\n Object evaluate();\n\n boolean isTerminal();\n\n <T extends Node> T copy();\n String debugString(Set<Node> set);\n}", "@SuppressWarnings(\"unchecked\")\n\tpublic List getDependents(PDGNode node);", "public Dependency() \r\n {\r\n }", "public void getDependencies(ScopeInformation scopeInfo,\n\t\tDependencyManager fdm);", "public interface IDraggableFactory {\n DraggableNode constructDraggable();\n}", "public interface Node {\n public int arityOfOperation();\n public String getText(int depth) throws CalculationException;\n public double getResult() throws CalculationException;\n public boolean isReachable(int depth);\n public List<Node> getAdjacentNodes();\n public String getTitle();\n public void setDepth(int depth);\n}", "public interface ResolvableModelicaNode extends ModelicaNode {\n /**\n * Tries to resolve the <b>declaration</b> of the referenced component.\n */\n ResolutionResult getResolutionCandidates();\n}", "public interface ProgramDependenceGraph extends MutableEdgeLabelledDirectedGraph {\n\n\t/**\n\t * @return A List of weak regions, generated by RegionAnalysis for the corresponding\n\t * control flow graph (These are Regions and not PDGRegions.)\n\t */\n\tpublic List<Region> getWeakRegions();\n\t/**\n\t * @return A List of strong regions, generated when constructing the program dependence graph\n\t * (These are Regions and not PDGRegions.)\n\t */\n\tpublic List<Region> getStrongRegions();\n\t/**\n\t * This method returns the list of PDGRegions computed by the construction method.\n\t * @return The list of PDGRegions\n\t */\n\tpublic List<PDGRegion> getPDGRegions();\n\t/**\n\t * @return The root region of the PDG.\n\t */\n\tpublic IRegion GetStartRegion();\n\n\t/**\n\t * @return The root node of the PDG, which is essentially the same as the start region\n\t * but packaged in its PDGNode, which can be used to traverse the graph, etc.\n\t */\n\tpublic PDGNode GetStartNode();\n\n\t/**\n\t * This method determines if node1 is control-dependent on node2 in this PDG.\n\t * @param node1\n\t * @param node2\n\t * @return returns true if node1 is dependent on node2\n\t */\n\tpublic boolean dependentOn(PDGNode node1, PDGNode node2);\n\t/**\n\t * This method returns the list of all dependents of a node in the PDG.\n\t * @param node is the PDG node whose dependents are desired.\n\t * @return a list of dependent nodes\n\t */\n\t@SuppressWarnings(\"unchecked\")\n\tpublic List getDependents(PDGNode node);\n\n\n\t/**\n\t * This method returns the PDGNode in the PDG corresponding to the given\n\t * CFG node. Note that currently the CFG node has to be a Block.\n\t * @param cfgNode is expected to be a node in CFG (currently only Block).\n\t * @return The node in PDG corresponding to cfgNode.\n\t */\n\n\tpublic PDGNode getPDGNode(Object cfgNode);\n\n\t/**\n\t *\n\t * @return A human readable description of the PDG.\n\t */\n\tpublic String toString();\n\n}", "public abstract List<Dependency> selectDependencies( Class<?> clazz );", "public interface IDirectedAcyclicGraph<T> extends Serializable {\n\n /**\n * Adds an edge to the graph.\n *\n * @param from the starting point.\n * @param to the ending point.\n * @return true if the edge was actually added (i.e. not present and didn't\n * create a cycle)\n * @throws NullPointerException if from or to is null\n */\n boolean add(T from, T to) throws NullPointerException;\n\n /**\n * Returns all the nodes that can be reached following the directed edges\n * starting from the selected node. It is guaranteed that the elements are\n * partially ordered by increasing distance from the selected node. If the\n * starting point is not a node in the graph, an empty iterable is returned.\n *\n * @param start the starting point.\n * @return an iterable with all the nodes that can be reached from the\n * starting node.\n * @throws NullPointerException if start is null.\n */\n Iterable<T> followNode(T start) throws NullPointerException;\n\n /**\n * Returns the selected node, followed by all the nodes that can be reached\n * following the directed edges starting from the selected node. It is\n * guaranteed that the elements are partially ordered by increasing distance\n * from the selected node. If the starting point is not a node in the graph,\n * an iterable containing only the starting node is returned.\n *\n * @param start the starting point.\n * @return an iterable which starts with the selected node and is followed\n * by all the connected nodes.\n * @throws NullPointerException if start is null.\n */\n Iterable<T> followNodeAndSelef(T start) throws NullPointerException;\n\n}", "void onDependencyRelation( DependencyRelation relation );", "public interface Node {\n static class NodeComparor implements Comparator<Node>{\n @Override\n public int compare(Node o1, Node o2) {\n return o1.getNodeId().compareTo(o2.getNodeId());\n }\n }\n\n public String getNodeId();\n\n public Chunk getChunck(String id) throws ChunkNotFound;\n\n public void addChunk(Chunk c);\n\n public boolean doesManage(String chunkId);\n\n public void sendMessage(Message m) throws IOException;\n\n public NodeWorkGroup getWorkGroup();\n}", "public interface GNode{\n\n\tpublic String getName();\n\tpublic GNode[] getChildren();\n\tpublic ArrayList<GNode> walkGraph(GNode parent);\n\tpublic ArrayList<ArrayList<GNode>> paths(GNode parent);\n\n}", "public interface DependentFactory {\n Dependent createDependent(String relationToSubscriber);\n}", "void depend(@Nonnull Path path);", "public interface PersonService {\r\n\r\n\t/**\r\n\t * Delete all the nodes of the person\r\n\t */\r\n\tvoid deleteAll();\r\n\r\n\t/**\r\n\t * Add Person node in the database using the JSONObject containing the data of the person\r\n\t * @param personJson\r\n\t * @return person\r\n\t */\r\n\tPerson addPerson(JSONObject person);\r\n\r\n\t/**\r\n\t * Relate nodes of the person by creating a relationship between them\r\n\t * @param person1\r\n\t * @param person2\r\n\t * @param relation\r\n\t * @return relatedPerson\r\n\t */\r\n\tRelatedPerson<Person, Person> relatePerson(String person1, String person2, String relation);\r\n\r\n\t/**\r\n\t * Find relation between the nodes of the two person.\r\n\t * @param person1\r\n\t * @param person2\r\n\t * @return strRelationship\r\n\t */\r\n\tString findRelation(String person1, String person2);\r\n\r\n\t/**\r\n\t * Finds the Person node with the given name\r\n\t * @param name\r\n\t * @return person\r\n\t */\r\n\tPerson findPerson(String name);\r\n\r\n\t/**\r\n\t * Finds the Person node and adds the image path\r\n\t * @param name\r\n\t * @param imagePath\r\n\t * @return person\r\n\t */\r\n\tPerson addImage(String name, String imagePath);\r\n\r\n}", "public interface ObjetoDependienteDeTurno {\n\n public void siguienteTurno();\n\n}", "private void writeClassDependencies(ClassDependencyInfo classDependencyInfo) {\n\n /* Writes all classes depended on plus their packages */\n Vector<String> classesDependedOn = classDependencyInfo.getEfferentClassDependencies();\n writeSpacesCorrespondingToNestedLevel(CLASS_DEPENDENCY_INFO_NEST_LEVEL);\n writer.println(\"uses:\");\n for(String classDependency : classesDependedOn) {\n\n int lastDecimal = classDependency.lastIndexOf(\".\");\n String classDependencyName = classDependency.substring(lastDecimal + 1);\n String pkgOfClassDependency = classDependency.substring(0, lastDecimal);\n\n /* Only writes the class dependency if it does not end with a '$'.\n * Dependency Analyzer tool will return dependencies even for anonymous inner classes which\n * will have a $ appended to the end of the name. These classes are ignored in the analysis.\n */\n if(!classDependencyName.contains(\"$\")) {\n /* Writes class dependency name followed by ':' */\n writeSpacesCorrespondingToNestedLevel(CLASS_DEPENDENCY_NAME_NEST_LEVEL);\n writer.println(classDependencyName + \":\");\n\n /* Writes package the dependency belongs to */\n writeSpacesCorrespondingToNestedLevel(CLASS_DEPENDENCY_NAME_NEST_LEVEL + 1);\n writer.println(\"package: \" + pkgOfClassDependency);\n }\n\n\n }\n\n /* Writes all classes that depend on this class plus their packages */\n Vector<String> classesThatDependOnThisClass = classDependencyInfo.getAfferentClassDependencies();\n writeSpacesCorrespondingToNestedLevel(CLASS_DEPENDENCY_INFO_NEST_LEVEL);\n writer.println(\"usedBy:\");\n for(String classDependency : classesThatDependOnThisClass) {\n\n int lastDecimal = classDependency.lastIndexOf(\".\");\n String classDependencyName = classDependency.substring(lastDecimal + 1);\n String pkgOfClassDependency = classDependency.substring(0, lastDecimal);\n\n /* Only writes the class dependency if it does not end with a '$'.\n * Dependency Analyzer tool will return dependencies even for anonymous inner classes which\n * will have a $ appended to the end of the name. These classes are ignored in the analysis.\n */\n if(!classDependencyName.contains(\"$\")) {\n /* Writes class dependency name followed by ':' */\n writeSpacesCorrespondingToNestedLevel(CLASS_DEPENDENCY_NAME_NEST_LEVEL);\n writer.println(classDependencyName + \":\");\n\n /* Writes package the dependency belongs to */\n writeSpacesCorrespondingToNestedLevel(CLASS_DEPENDENCY_NAME_NEST_LEVEL + 1);\n writer.println(\"package: \" + pkgOfClassDependency);\n }\n }\n }", "ConditionalDependency createConditionalDependency();", "void addDependencies(Object object) {\n objects.add(object);\n }", "private void resolveDependency(Set<Node> availableBeans, Node node,\n\t\t\tDependency dependency) {\n\t\tfinal ClassItem classItem = dependency.getTarget();\n\t\tType type;\n\t\tif(classItem.isMethod()) {\n\t\t\tMethod method = (Method) classItem;\n\t\t\tParameter parameter = method.getParameters().get(0);\n\t\t\ttype = parameter.getType();\n\t\t} else { // attribute\n\t\t\tAttribute attribute = (Attribute) classItem;\n\t\t\ttype = attribute.getType();\n\t\t}\n\t\tboolean collection = false;\n if(type.isArray()) {\n\t\t\ttype = type.asArrayType().getInnerType();\n\t\t\tcollection = true;\n\t\t} else if(type.isClassType() && ClassModelUtil.isCollection(type.asClassType())) {\n\t\t\t List<Type> typeParameters = type.asClassType().getTypeParameters();\n\t\t\t type = typeParameters.size() == 1 ? typeParameters.get(0) : null;\n\t\t\t collection = true;\n\t\t}\n if(type != null && type.isBasic()) { // Won't inject basic types\n\t\t\ttype = null;\n\t\t}\n\t\tif(type != null) {\n\t\t\tfinal ClassType targetType = type.asClassType();\n Set<Node> candidates = getCandidates(availableBeans, targetType);\n if((candidates.size() == 1 && !collection) || (candidates.size() > 0 && collection && !candidates.contains(node))) {\n\t\t\t\t// Resolved dependency!\n\t\t\t\tdependency.setNature(collection ? IoCModelUtil.getCollectionDependencyNature(node, candidates) :\n\t\t\t\t\tIoCModelUtil.getDependencyNature(node, candidates.iterator().next()));\n\t\t\t\tfor (Node candidate : candidates) {\n\t\t\t\t\tcreateInjection(node, candidate, dependency);\n\t\t\t\t}\n\t\t\t} else if(classItem.isAttribute()) {\n\t\t\t\t// Add unresolved injection nature to associations\n\t\t\t\tcreateUnresolvedInjections(node, dependency, candidates);\n\t\t\t}\n\t\t}\n\t}", "public interface InterparameterDependenciesLanguageFactory extends EFactory\n{\n /**\n * The singleton instance of the factory.\n * <!-- begin-user-doc -->\n * <!-- end-user-doc -->\n * @generated\n */\n InterparameterDependenciesLanguageFactory eINSTANCE = es.us.isa.interparamdep.interparameterDependenciesLanguage.impl.InterparameterDependenciesLanguageFactoryImpl.init();\n\n /**\n * Returns a new object of class '<em>Model</em>'.\n * <!-- begin-user-doc -->\n * <!-- end-user-doc -->\n * @return a new object of class '<em>Model</em>'.\n * @generated\n */\n Model createModel();\n\n /**\n * Returns a new object of class '<em>Dependency</em>'.\n * <!-- begin-user-doc -->\n * <!-- end-user-doc -->\n * @return a new object of class '<em>Dependency</em>'.\n * @generated\n */\n Dependency createDependency();\n\n /**\n * Returns a new object of class '<em>Relational Dependency</em>'.\n * <!-- begin-user-doc -->\n * <!-- end-user-doc -->\n * @return a new object of class '<em>Relational Dependency</em>'.\n * @generated\n */\n RelationalDependency createRelationalDependency();\n\n /**\n * Returns a new object of class '<em>Arithmetic Dependency</em>'.\n * <!-- begin-user-doc -->\n * <!-- end-user-doc -->\n * @return a new object of class '<em>Arithmetic Dependency</em>'.\n * @generated\n */\n ArithmeticDependency createArithmeticDependency();\n\n /**\n * Returns a new object of class '<em>Operation</em>'.\n * <!-- begin-user-doc -->\n * <!-- end-user-doc -->\n * @return a new object of class '<em>Operation</em>'.\n * @generated\n */\n Operation createOperation();\n\n /**\n * Returns a new object of class '<em>Operation Continuation</em>'.\n * <!-- begin-user-doc -->\n * <!-- end-user-doc -->\n * @return a new object of class '<em>Operation Continuation</em>'.\n * @generated\n */\n OperationContinuation createOperationContinuation();\n\n /**\n * Returns a new object of class '<em>Conditional Dependency</em>'.\n * <!-- begin-user-doc -->\n * <!-- end-user-doc -->\n * @return a new object of class '<em>Conditional Dependency</em>'.\n * @generated\n */\n ConditionalDependency createConditionalDependency();\n\n /**\n * Returns a new object of class '<em>General Predicate</em>'.\n * <!-- begin-user-doc -->\n * <!-- end-user-doc -->\n * @return a new object of class '<em>General Predicate</em>'.\n * @generated\n */\n GeneralPredicate createGeneralPredicate();\n\n /**\n * Returns a new object of class '<em>General Clause</em>'.\n * <!-- begin-user-doc -->\n * <!-- end-user-doc -->\n * @return a new object of class '<em>General Clause</em>'.\n * @generated\n */\n GeneralClause createGeneralClause();\n\n /**\n * Returns a new object of class '<em>General Term</em>'.\n * <!-- begin-user-doc -->\n * <!-- end-user-doc -->\n * @return a new object of class '<em>General Term</em>'.\n * @generated\n */\n GeneralTerm createGeneralTerm();\n\n /**\n * Returns a new object of class '<em>Param</em>'.\n * <!-- begin-user-doc -->\n * <!-- end-user-doc -->\n * @return a new object of class '<em>Param</em>'.\n * @generated\n */\n Param createParam();\n\n /**\n * Returns a new object of class '<em>Param Value Relation</em>'.\n * <!-- begin-user-doc -->\n * <!-- end-user-doc -->\n * @return a new object of class '<em>Param Value Relation</em>'.\n * @generated\n */\n ParamValueRelation createParamValueRelation();\n\n /**\n * Returns a new object of class '<em>General Clause Continuation</em>'.\n * <!-- begin-user-doc -->\n * <!-- end-user-doc -->\n * @return a new object of class '<em>General Clause Continuation</em>'.\n * @generated\n */\n GeneralClauseContinuation createGeneralClauseContinuation();\n\n /**\n * Returns a new object of class '<em>General Predefined Dependency</em>'.\n * <!-- begin-user-doc -->\n * <!-- end-user-doc -->\n * @return a new object of class '<em>General Predefined Dependency</em>'.\n * @generated\n */\n GeneralPredefinedDependency createGeneralPredefinedDependency();\n\n /**\n * Returns the package supported by this factory.\n * <!-- begin-user-doc -->\n * <!-- end-user-doc -->\n * @return the package supported by this factory.\n * @generated\n */\n InterparameterDependenciesLanguagePackage getInterparameterDependenciesLanguagePackage();\n\n}", "public CPointer<Object> getDepsgraph() throws IOException\n\t{\n\t\tlong __dna__targetAddress;\n\t\tif ((__io__pointersize == 8)) {\n\t\t\t__dna__targetAddress = __io__block.readLong(__io__address + 120);\n\t\t} else {\n\t\t\t__dna__targetAddress = __io__block.readLong(__io__address + 100);\n\t\t}\n\t\tClass<?>[] __dna__targetTypes = new Class[]{Object.class};\n\t\treturn new CPointer<Object>(__dna__targetAddress, __dna__targetTypes, __io__blockTable.getBlock(__dna__targetAddress, -1), __io__blockTable);\n\t}", "@objid (\"5bf23d8e-6afe-478b-ae81-6989245a8387\")\n Collection<SmDependencyTypeChecker> createDependencyCheckers(SmMetamodel metamodel);", "public boolean dependentOn(PDGNode node1, PDGNode node2);", "public interface NodeWorkFlow {\n\n /*\n * @return next node in chain\n * */\n public Node nextNode();\n\n /*\n * @return prev. node in chain.\n * */\n public Node prevNode();\n\n /*\n * Set node after this node as the next node. New node will be the last in chain.\n * @param node: the new node\n * @return this node\n * */\n public Node setNextNode(Node node);\n\n /*\n * Set node before this node as the prev node. New node will be the first in chain.\n * @param node: the new node\n * @return this node\n * */\n public Node setPrevNode(Node node);\n\n /*\n * @return the first node in chain.\n * */\n public Node firstNode();\n\n /*\n * @return the last node in chain\n * */\n public Node lastNode();\n\n /*\n * append new node to the last node in chain.\n * @param node: the new node\n * @return this node\n * */\n public Node appendNode(Node node);\n\n /*\n * insert new node into the chain after this node. It does not break the chain.\n * @param node: the new node\n * @return this node\n * */\n public Node insertAfter(Node node);\n\n /*\n * insert new node into the chain before this node. It does not break the chain.\n * @param node: the new node\n * @return this node\n * */\n public Node insertBefore(Node node);\n\n /*\n * Remove node from its chain.\n * @return this node\n * */\n public Node removeFromChain();\n\n /*\n * Set node as the top node.\n * @param node: new top node\n * @return this node\n * */\n public Node setTopNode(Node node);\n\n /*\n * @return topNode node\n * */\n public Node topNode();\n\n /*\n * @return true if node is in chain\n * */\n public boolean isNodeInChain( Node node );\n\n public void constructGraphics();\n public void constructPhysics();\n public void destroyGraphics();\n public void destroyPhysics();\n\n public void preExport();\n public void postExport();\n\n}", "public interface IRelayNodeFactory {\n\n\t/**\n\t * This method should return true only if the specified object id should be handled by this factory\n\t */\n\tboolean handlesNodeId(String id);\n\n\t/**\n\t * Accepts a Relay ID and constructs an object based on the ID.\n\t * @param objectId the relay object ID. All object ID's must be prefixed with the factories name\n\t * @return\n\t */\n\tINode newObjectFromID(String objectId);\n\n}", "public interface IRelationService<DependenciesBean, AssociationTreeBean> {\n\n /**\n * Method to obtain a list of dependencies.\n *\n * @param path the resource path.\n *\n * @return the list of dependencies.\n * @throws RegistryException if the operation failed.\n */\n DependenciesBean getDependencies(String path) throws RegistryException;\n\n /**\n * Method to add an association (or dependency).\n *\n * @param path the resource path.\n * @param type the type of association. If the type of association is 'depends' a\n * dependency will be created.\n * @param associationPaths the list of associations to be added.\n *\n * @throws RegistryException if the operation failed.\n */\n void addAssociation(String path, String type, String associationPaths,\n String operation) throws RegistryException;\n\n // TODO: FIXME: The operation parameter is not required. Get rid of that and fix the\n // addAssociation method on the BE service.\n\n /**\n * Method to obtain a list of associations.\n * \n * @param path the resource path.\n * @param type the type of association.\n *\n * @return the list of associations.\n * @throws RegistryException if the operation failed.\n */\n AssociationTreeBean getAssociationTree(String path, String type) throws RegistryException;\n}", "void depend(int parentID, int childID){\n check(parentID, childID);\n nodes_[childID].parent_ = parentID;\n nodes_[parentID].addChild(childID);\n }", "public interface IAnimableNode {\n\n public IAnimableNode getNext();\n\n public IAnimable getAnimable();\n\n}", "public interface Manager {\n\n}", "public interface NodeManager<K extends Comparable<K>, V> extends Closeable, Monitorable {\n\n /**\n * Returns the root node of the specified <code>BTree</code>.\n * \n * @param btree the BTree.\n * @return the root node.\n * @throws IOException if an I/O problem occurs.\n */\n Node<K, V> getRoot(BTree<K, V> btree) throws IOException;\n\n /**\n * Sets the new root node.\n * \n * @param root the new root node.\n * @throws IOException if an I/O problem occurs.\n */\n void setRoot(Node<K, V> root) throws IOException;\n\n /**\n * Allows this manager to take control of the storage of specified node.\n * \n * @param node the node.\n * @return the decorated node.\n * @throws IOException if an I/O problem occurs.\n */\n @SuppressWarnings(\"unchecked\")\n Node<K, V>[] wrapNodes(Node<K, V>... nodes) throws IOException;\n\n /**\n * Allows this manager to take control of the storage of specified node.\n * \n * @param node the node.\n * @return the decorated node.\n * @throws IOException if an I/O problem occurs.\n */\n Node<K, V> wrapNode(Node<K, V> node) throws IOException;\n\n /**\n * Allows the user of the node to retrieve the original node.\n * \n * @param node the decorated node.\n * @return the node.\n * @throws IOException if an I/O problem occurs.\n */\n Node<K, V> unwrapNode(Node<K, V> node) throws IOException;\n\n /**\n * Allows this manager to take control of the storage of specified value.\n * \n * @param value the value.\n * @return the decorated value.\n * @throws IOException if an I/O problem occurs.\n */\n ValueWrapper<V> wrapValue(V value) throws IOException;\n \n /**\n * {@inheritDoc}\n */\n @Override\n void close();\n}", "public static JDependAdapter getJDependAdapter() {\n if(getDefault().jdepend == null) {\n \tJDependAdapter jdepend = new JDependAdapter();\n \tgetDefault().jdepend = jdepend;\n } \n return getDefault().jdepend;\n }", "public interface TreeNode{\r\n\t\r\n\t// enumerated node types\r\n\tpublic enum NodeType {\r\n\t\tMIN {\r\n\t\t\t@Override\r\n\t\t\tpublic NodeType opposite() {\r\n\t\t\t\treturn MAX;\r\n\t\t\t}\r\n\t\t}, MAX {\r\n\t\t\t@Override\r\n\t\t\tpublic NodeType opposite() {\r\n\t\t\t\treturn MIN;\r\n\t\t\t}\r\n\t\t};\r\n\t\r\n\t\tpublic abstract NodeType opposite();\r\n\t};\r\n\t\r\n\t// the type of node represented\r\n\tpublic NodeType getNodeType();\r\n\t\r\n\t// a possibly empty list of children\r\n\tpublic List<TreeNode> getChildrenNodes();\r\n\t\r\n\t// request a new child node after executing a move\r\n\tpublic TreeNode getChildNode(GameMove move) throws IllegalArgumentException;\r\n\t\r\n\t// the parent node of the current node\r\n\t// current Node == getParentNode for ROOT\r\n\tpublic TreeNode getParentNode();\r\n \r\n\t// whether the current node is the root node\r\n\tpublic Boolean isRootNode();\r\n \r\n\t// returns an object modeling some external state \r\n\tpublic GameState getGameState();\r\n \r\n\t// depth of node in tree\r\n\tpublic int getDepth();\r\n \r\n\t// evaluates/scores the leaf node\r\n\tpublic int scoreLeafNode();\r\n}", "public interface NodeService {\n\n /**\n * Given a Node's ID, return the point associated with that Node.\n * @param nodeId - Integer unique ID for the Node.\n * @return Point with the coordinates of the Node's coordinates.\n */\n Point getPointByNodeId(Integer nodeId);\n\n /**\n * Adding a candidate Node to the network which has yet been evaluated\n * against the network.\n *\n * @param lat - Latitude of the Node.\n * @param lon - Longitude of the Node.\n * @return JSON String listing the results of evaluating whether this Node is on\n * the Network or requires adding Edges to reach the network.\n */\n String addNewNode(Double lat, Double lon);\n\n // TODO: Diagnostic Service? This is being used however to Edit Nodes.\n String showAllNodes();\n\n String getNodeGroups();\n\n String setNodeGroup(Integer id, Double lat, Double lon);\n\n // TODO: Probably would go over to the EdgeService\n String getMatchingSegments(Integer pointId);\n\n /**\n * Given a Node's ID and a new Lat/Lon position, edit the Edges connected\n * to that node and return a Feature Collection with the updated Edges (the\n * Node itself will be still active in the browser and the position is\n * already known by the client).\n * @param pointId - Unique Integer representing the Node to edit.\n * @param lat - Latitude of the new location.\n * @param lng - Longitude of the new location.\n * @return Feature Collection with the updated Edges.\n */\n // TODO: Probably would go over to the EdgeService\n String getEdgesAtNewLocation(Integer pointId, Double lat, Double lng);\n\n /**\n * Accepts the last recommended position for the Node as the one to be\n * committed to the database.\n * @param pointId - Unique Integer representing the Node to edit.\n * @return String \"OK\" to confirm.\n */\n // TODO: Probably would go over to the EdgeService\n String confirmEdgesAtNewLocation(Integer pointId);\n}", "void depComponent(DepComponent depComponent);", "public interface DependenciesHandler {\n\n /**\n * Configures dependency management for the dependency identified by the given {@code id}. The id is a string\n * of the form {@code group:name:version}.\n *\n * @param id the id of the dependency\n */\n void dependency(String id);\n\n /**\n * Configures dependency management for the dependency identified by the given {@code id}. The id is a map with\n * {@code group}, {@code name}, and {@code version} entries.\n *\n * @param id the id of the dependency\n */\n void dependency(Map<String, String> id);\n\n /**\n * Configures dependency management for the dependency identified by the given {@code id}. The dependency\n * management can be further configured using the given {@code closure} that is called with a {@link\n * DependencyHandler} as its delegate. The id is a string of the form {@code group:name:version}.\n *\n * @param id the id of the dependency\n * @param closure the closure used to further configure the dependency management\n * @see DependencyHandler\n */\n void dependency(String id, Closure closure);\n\n /**\n * Configures dependency management for the dependency identified by the given {@code id}. The dependency\n * management can be further configured using the given {@code action}. The id is a string of the form\n * {@code group:name:version} or a map with {@code group}, {@code name}, and {@code version} entries.\n *\n * @param id the id of the dependency\n * @param action the action used to further configure the dependency management\n * @see DependencyHandler\n */\n void dependency(String id, Action<DependencyHandler> action);\n\n /**\n * Configures dependency management for the dependency identified by the given {@code id}. The dependency\n * management can be further configured using the given {@code closure} that is called with a {@link\n * DependencyHandler} as its delegate. The id is a map with {@code group}, {@code name}, and {@code version}\n * entries.\n *\n * @param id the id of the dependency\n * @param closure the closure used to further configure the dependency management\n * @see DependencyHandler\n */\n void dependency(Map<String, String> id, Closure closure);\n\n /**\n * Configures dependency management for the dependency identified by the given {@code id}. The dependency\n * management can be further configured using the given {@code action}. The id is a map with {@code group},\n * {@code name}, and {@code version} entries.\n *\n * @param id the id of the dependency\n * @param action the action used to further configure the dependency management\n * @see DependencyHandler\n */\n void dependency(Map<String, String> id, Action<DependencyHandler> action);\n\n /**\n * Configures dependency management for a set of dependencies with the same {@code group} and {@code version}\n * as specified by the given {@code setId}. The id is a string of the form {@code group:version}. Entries are added\n * to the set using the given {@code closure} that is called with a {@link DependencySetHandler} as its delegate.\n *\n * @param setId the id of the set\n * @param closure the closure used to configure the entries\n * @see DependencySetHandler\n */\n void dependencySet(String setId, Closure closure);\n\n /**\n * Configures dependency management for a set of dependencies with the same {@code group} and {@code version}\n * as specified by the given {@code setId}. The id is a string of the form {@code group:version}. Entries are added\n * to the set using the given {@code action}.\n *\n * @param setId the id of the set\n * @param action the action used to configure the entries\n * @see DependencySetHandler\n */\n void dependencySet(String setId, Action<DependencySetHandler> action);\n\n /**\n * Configures dependency management for a set of dependencies with the same {@code group} and {@code version} as\n * specified by the given {@code setId}. The id is a map with {@code group} and {@code version} entries. Entries\n * are added to the set using the given {@code closure} that is called with a {@link DependencySetHandler} as its\n * delegate.\n *\n * @param setId a map containing the {@code group} and {@code version} of the set of dependencies\n * @param closure the closure used to configure the entries\n * @see DependencySetHandler\n */\n void dependencySet(Map<String, String> setId, Closure closure);\n\n /**\n * Configures dependency management for a set of dependencies with the same {@code group} and {@code version} as\n * specified by the given {@code setId}. The id is a map with {@code group} and {@code version} entries. Entries\n * are added to the set using the given {@code action}.\n *\n * @param setId a map containing the {@code group} and {@code version} of the set of dependencies\n * @param action the action used to configure the entries\n * @see DependencySetHandler\n */\n void dependencySet(Map<String, String> setId, Action<DependencySetHandler> action);\n\n}", "public interface Nodelet {\n\n\tLogger log = Logger.getLogger(Nodelet.class);\n\t\n\tvoid process (Node node) throws Exception;\n}", "public interface TreeBuilder {\r\n\r\n\t/**\r\n\t * Creates the relationship for the give persons in the provided family with given relationshiptype.\r\n\t * @param rt\r\n\t * @param parentId\r\n\t * @param childId\r\n\t * @param familyId\r\n\t * @return - Relationship created with the given type in the given family for the given persons\r\n\t * @throws Exception\r\n\t */\r\n\tpublic Relationship createRelationship(RelationshipType rt, String parentId, String childId, String familyId) throws Exception;\r\n\t/**\r\n\t * Creates a family with given name.\r\n\t * @param name\r\n\t * @return - Family ID of the created family\r\n\t */\r\n\tpublic String createFamily(String name);\r\n\t/**\r\n\t * Provides any one person from the given family.\r\n\t * @param familyId\r\n\t * @return - Person ID from the given family\r\n\t */\r\n\tpublic String getFamilyPerson(String familyId);\r\n\t/**\r\n\t * Provides the Person Id of the root member of this family.\r\n\t * @param familyId\r\n\t * @return - Person ID of the root member in the family.\r\n\t */\r\n\tpublic String getFamilyRoot(String familyId);\r\n\t/**\r\n\t * Checks if the family exists with given ID.\r\n\t * @param familyId\r\n\t * @return boolean\r\n\t */\r\n\tpublic boolean isFamily(String familyId);\r\n}", "ArithmeticDependency createArithmeticDependency();", "protected void setDependencies() {\n\t\t\n\t}", "Set<DependencyItem> getDependsOnMe(Class<?> type);", "public interface DirectedGraph {\n\n /**\n * Set a graph label\n * @param label a graph label\n */\n void setGraphLabel(String label);\n\n /**\n * @return the graph label\n */\n String getGraphLabel();\n\n /**\n * Add a node in graph\n * @param node\n * @throws IllegalArgumentException if node is negative\n */\n void addNode(int node);\n\n /**\n * Associating metadata to node\n * @param node the node id\n * @param key the metadata key\n * @param value the metadata value\n */\n void addNodeMetadata(int node, String key, String value);\n\n /**\n * Get the value of the metadata associated with the given node\n * @param node the node to get metadata for\n * @param key the metadata key\n * @return the value or null if not found\n */\n String getNodeMetadataValue(int node, String key);\n\n /**\n * @return the node given the label or -1 if not found\n */\n int getNodeFromMetadata(String metadata);\n\n /**\n * Add an edge in graph from tail to head and return its index\n * @param tail predecessor node\n * @param head successor node\n * @return the edge id or -1 if already exists\n */\n int addEdge(int tail, int head);\n\n /**\n * Set an edge label\n * @param edge a edge id\n * @param label a node label\n */\n void setEdgeLabel(int edge, String label);\n\n /**\n * @return the edge label\n */\n String getEdgeLabel(int edge);\n\n /**\n * @return an array of graph nodes\n */\n int[] getNodes();\n\n /**\n * @return an array of graph edges\n */\n int[] getEdges();\n\n /**\n * @return the edge id from end points or -1 if not found\n */\n int getEdge(int tail, int head);\n\n /**\n * Get the incoming and outcoming edges for the given nodes\n * @param nodes the nodes\n * @return edge indices\n */\n int[] getEdgesIncidentTo(int... nodes);\n\n /**\n * Get the incoming edges to the given nodes\n * @param nodes the nodes\n * @return edge indices\n */\n int[] getInEdges(int... nodes);\n\n /**\n * Get the outcoming edges from the given nodes\n * @param nodes the nodes\n * @return edge indices\n */\n int[] getOutEdges(int... nodes);\n\n /**\n * @return the tail node of the given edge or -1 if not found\n */\n int getTailNode(int edge);\n\n /**\n * @return the head node of the given edge or -1 if not found\n */\n int getHeadNode(int edge);\n\n /**\n * @return true if node belongs to graph else false\n */\n boolean containsNode(int node);\n\n /**\n * @return true if edge belongs to graph else false\n */\n boolean containsEdge(int edge);\n\n /**\n * @return true if tail -> head edge belongs to graph else false\n */\n boolean containsEdge(int tail, int head);\n\n /**\n * @return ancestors of the given node\n */\n int[] getAncestors(int node);\n\n /**\n * @return descendants of the given node\n */\n int[] getDescendants(int node);\n\n /**\n * @return descendants of the given node\n */\n int[] getDescendants(int node, int maxDepth);\n\n /**\n * @return true if queryDescendant is a descendant of queryAncestor\n */\n boolean isAncestorOf(int queryAncestor, int queryDescendant);\n\n /**\n * @return the predecessors of the given node\n */\n int[] getPredecessors(int node);\n\n /**\n * @return the successors of the given node\n */\n int[] getSuccessors(int node);\n\n /**\n * @return the number of head ends adjacent to the given node\n */\n int getInDegree(int node);\n\n /**\n * @return the number of tail ends adjacent to the given node\n */\n int getOutDegree(int node);\n\n /**\n * @return the sources (indegree = 0) of the graph\n */\n int[] getSources();\n\n /**\n * @return the sinks (outdegree = 0) of the graph\n */\n int[] getSinks();\n\n /**\n * @return the subgraph of this graph composed of given nodes\n */\n DirectedGraph calcSubgraph(int... nodes);\n\n /**\n * @return the total number of graph nodes\n */\n default int countNodes() {\n\n return getNodes().length;\n }\n\n /**\n * @return the total number of graph edges\n */\n default int countEdges() {\n\n return getEdges().length;\n }\n\n /**\n * @return true if queryDescendant is a descendant of queryAncestor\n */\n default boolean isDescendantOf(int queryDescendant, int queryAncestor) {\n\n return isAncestorOf(queryAncestor, queryDescendant);\n }\n\n default boolean isSource(int node) {\n return getInDegree(node) == 0 && getOutDegree(node) > 0;\n }\n\n default boolean isSink(int node) {\n return getInDegree(node) > 0 && getOutDegree(node) == 0;\n }\n\n /**\n * The height of a rooted tree is the length of the longest downward path to a leaf from the root.\n *\n * @return the longest path from the root or -1 if it is not a tree\n */\n default int calcHeight() throws NotATreeException {\n\n int[] roots = getSources();\n\n if (roots.length == 0) {\n throw new NotATreeException();\n }\n\n class WrappedCalcLongestPath {\n private int calcLongestPath(int node, TIntList path) throws CycleDetectedException {\n\n if (!containsNode(node)) {\n throw new IllegalArgumentException(\"node \"+ node + \" was not found\");\n }\n\n if (isSink(node)) {\n return path.size()-1;\n }\n\n TIntList lengths = new TIntArrayList();\n for (int edge : getOutEdges(node)) {\n\n int nextNode = getHeadNode(edge);\n\n TIntList newPath = new TIntArrayList(path);\n newPath.add(nextNode);\n\n if (path.contains(nextNode)) {\n throw new CycleDetectedException(newPath);\n }\n\n lengths.add(calcLongestPath(nextNode, newPath));\n }\n\n return lengths.max();\n }\n }\n\n // it is ok if there are multiple roots (see example of enzyme-classification-cv where it misses the root that\n // connect children EC 1.-.-.-, EC 2.-.-.-, ..., EC 6.-.-.-)\n /*if (roots.length > 1) {\n throw new NotATreeMultipleRootsException(roots);\n }*/\n\n return new WrappedCalcLongestPath().calcLongestPath(roots[0], new TIntArrayList(new int[] {roots[0]}));\n }\n\n class NotATreeException extends Exception {\n\n public NotATreeException() {\n\n super(\"not a tree\");\n }\n }\n\n class NotATreeMultipleRootsException extends NotATreeException {\n\n private final int[] roots;\n\n public NotATreeMultipleRootsException(int[] roots) {\n\n super();\n this.roots = roots;\n }\n\n @Override\n public String getMessage() {\n\n return super.getMessage() + \", roots=\" + Arrays.toString(this.roots);\n }\n }\n\n class CycleDetectedException extends NotATreeException {\n\n private final TIntList path;\n\n public CycleDetectedException(TIntList path) {\n\n super();\n\n this.path = path;\n }\n\n @Override\n public String getMessage() {\n\n return super.getMessage() + \", path=\" + this.path;\n }\n }\n}", "protected void addDependant1PropertyDescriptor(Object object) {\n\t\titemPropertyDescriptors.add\n\t\t\t(createItemPropertyDescriptor\n\t\t\t\t(((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),\n\t\t\t\t getResourceLocator(),\n\t\t\t\t getString(\"_UI_NetworkDependency_Dependant1_feature\"),\n\t\t\t\t getString(\"_UI_PropertyDescriptor_description\", \"_UI_NetworkDependency_Dependant1_feature\", \"_UI_NetworkDependency_type\"),\n\t\t\t\t OMPackage.Literals.NETWORK_DEPENDENCY__DEPENDANT1,\n\t\t\t\t true,\n\t\t\t\t false,\n\t\t\t\t true,\n\t\t\t\t null,\n\t\t\t\t null,\n\t\t\t\t null));\n\t}", "@Override\n\tpublic void checkDependencies() throws Exception\n\t{\n\t\t\n\t}", "public interface ReferenceHolder {\n\n /**\n * Sets the text.\n *\n * @param text the new text\n */\n void setText(String text);\n\n /**\n * Gets the current text.\n *\n * @return Returns the text.\n */\n String getText();\n\n /**\n * Gets the current {@link Diagram}.\n *\n * @return Returns the diagram.\n */\n Diagram getDiagram();\n\n /**\n * Sets the reference {@link Diagram}.\n *\n * @param reference the new reference\n */\n void setReference(Diagram reference);\n\n /**\n * Gets the reference {@link Diagram}.\n *\n * @return Returns the reference.\n */\n Diagram getReference();\n\n /**\n * Adds a {@link PropertyChangeListener}.\n *\n * @param listener the listener to add\n */\n void addPropertyChangeListener(PropertyChangeListener listener);\n\n}", "public interface IRepositoryService {\n\n /**\n * Returns the path to an artifact with the given identifier.\n *\n * @param identifier artifact identifier\n * @return the path to an artifact with the given identifier.\n */\n Path getArtifact(String identifier);\n\n /**\n * Returns the set of paths to the artifacts that the artifact with the given identifier depends on. If the given\n * artifact has no dependencies, returns an empty set.\n *\n * @param identifier artifact identifier\n * @param transitive if {@code false}, returns the immediate dependencies of the artifact; otherwise, returns all\n * dependencies, including dependencies of dependencies\n * @return the set of paths to the dependent artifacts\n */\n Set<Path> getArtifactDependencies(String identifier, boolean transitive);\n\n}", "void depend(@Nonnull String path);", "public interface Transition extends Node {\n}", "GeneralPredefinedDependency createGeneralPredefinedDependency();", "public interface NEPCalculation<T> extends CalculationInfo<T>\n{\n\t/**\n\t * \"Processes\" (or runs) the NEPCalculation in order to determine the\n\t * appropriate result of the NEPCalculation.\n\t * \n\t * There is no requirement that a NEPCalculation take into account the input\n\t * value (it can be a \"set\").\n\t * \n\t * The NEPCalculation should treat the input as an Immutable object (it does\n\t * not gain ownership of that parameter).\n\t * \n\t * @param input\n\t * The input value used (if necessary) to determine the\n\t * appropriate result of this NEPCalculation\n\t * @param scopeInfo\n\t * The ScopeInformation that is used (if necessary) to process a\n\t * Formula that is contained by this NEPCalculation\n\t * @return The resulting value of the NEPCalculation\n\t */\n\tpublic T process(T input, ScopeInformation scopeInfo);\n\n\t/**\n\t * Loads the dependencies for the NEPCalculation into the given\n\t * DependencyManager.\n\t * \n\t * The DependencyManager may not be altered if there are no dependencies for\n\t * this NEPCalculation.\n\t * \n\t * @param scopeInfo\n\t * The ScopeInformation to be used in case this NEPCalculation\n\t * depends on a Formula that needs deeper analysis\n\t * @param fdm\n\t * The DependencyManager to be notified of dependencies for this\n\t * NEPCalculation\n\t */\n\tpublic void getDependencies(ScopeInformation scopeInfo,\n\t\tDependencyManager fdm);\n}", "public DependencyElements getDependencyAccess() {\n\t\treturn pDependency;\n\t}", "@Test\n public void testZeroDependencies() {\n dependencyManager.depend(\"foo\", ImmutableSet.of());\n assertTrue(dependencyManager.isdepend(\"foo\", ImmutableSet.of()));\n }", "public interface BdObjectGraph\r\n{\r\n // Object Graph is a tree representation of BD object.\r\n // From root node to sub child node to finally leaf object graph shows the location of object.\r\n // for example \r\n //root=station,\r\n //station has 3 clusters=Nodes\r\n // Clusters has many objects for example file objects,schedule objects \r\n // then sub-node=file object,schedule object \r\n //Each node has resource description allocator,for example if i want to get file object in clsuter1\r\n //in station1 then resource description allocator of Big Dinosaur gives me \r\n //stationname,clustername,filename as a query \r\n //the syntax for query has to be decided in what format\r\n // may be station:cluster:where:filename=\"big dinosaur u will rule \"\r\n //Challenges:On what interval of time the BdObjectGraph has to be persist or it is stored in file system or create object\r\n //in runtime \r\n//////////////////////////////////\r\n //May be representing tree in file system or in object \r\n \r\n //for Example Example 1\r\n // Bd has different types of object graph on the basis of object type\r\n // which tree as object graph to search is determined on the basis of query syntax\r\n // for example\r\n // Station:Abcbankclientstation(in sense it represent one machine virtually but is a collection of many physical clusters or virtual clusters)\r\n // this will search station tree object with key as Abcbankclientstation.It goes on traversing on tree until it gets Abcbankclientstation and gets space object allcoated for this client in sense of cluster \r\n\r\n //for Example Example 2\r\n //Now after transversing cluster object with allocated space is retirved then again i need to retirve file object from that cluster\r\n //then again the query is \r\n //Station:Abcbankclientstation:insurancestore:abishkar.txt\r\n //now again file object graph tree is traversed until i get abishkar.txt and goes on recusrsively\r\n //or \r\n //Station:Abcbankclientstation:insurancestore:insuranceObject\r\n //insurancestore has large no of insuranceObject kept as tree,so again insurancestore is traversed until\r\n //insuranceObject is retirved and goes on recusrsively \r\n \r\n \r\n //Object graph is continuously updated ot inserted by another program in continuous basis on the basis of tree type object\r\n \r\n}", "public interface GeometricalObjectVisitor {\n\n\t/**\n\t * Visits the given line.\n\t * \n\t * @param line\n\t * to visit\n\t */\n\tpublic abstract void visit(Line line);\n\n\t/**\n\t * Visits the given circle.\n\t * \n\t * @param circle\n\t * to visit\n\t */\n\tpublic abstract void visit(Circle circle);\n\n\t/**\n\t * Visits the given filled circle.\n\t * \n\t * @param filledCircle\n\t * to visit\n\t */\n\tpublic abstract void visit(FilledCircle filledCircle);\n\n\tpublic abstract void visit(FilledPolygon filledPolygon);\n}", "public interface Node {\n\n\tLong getClsId();\n\n\tNode getParent();\n\n\tvoid setParent(Node p);\n\n\tNode[] getChildrenArray();\n\n\tList<Node> getChildrenList();\n\n\tvoid resetChildren(Node[] children);\n\n\tObject getValue(int attr);\n\n\tObject setValue(int attr, Object value);\n\n\tlong getLongValue(int attr);\n\n\tInteger getId();\n}", "@Test\n public void testCreateDependencyTree2() {\n Map<String, Integer> expected = new HashMap<>() {{\n put(\"github.com/jfrog/gocmd:0.1.12\", 2);\n }};\n try {\n Path projectDir = GO_ROOT.resolve(\"project2\");\n GoTreeBuilder treeBuilder = new GoTreeBuilder(null, projectDir, projectDir.resolve(\"go.mod\").toString(), null, log);\n DepTree dt = treeBuilder.buildTree();\n validateDependencyTreeResults(expected, dt);\n } catch (IOException ex) {\n fail(ExceptionUtils.getStackTrace(ex));\n }\n }", "public interface Task {\n\n /**\n * Getter for the conversaitonal object concerned with this task.\n * @return the conversational object owning this task\n */\n ConversationalObject getTaskOwner();\n\n /**\n * Stter for the conversaitonal object concerned with this task.\n * @param taskOwner the task owner to set.\n */\n void setTaskOwner(ConversationalObject taskOwner);\n\n /**\n * Getter for the status of this task\n * @return the current status of this task\n */\n TaskStatus getStatus();\n\n /**\n * Setter for the status of this task\n * @param status\n */\n void setStatus(TaskStatus status);\n\n /**\n * Getter for the stage of this task. It is strongly recomended that concrete\n * task classes declare static final string variables to refer to there\n * possible stages.\n * @return The current stage of this task\n */\n String getStage();\n\n /**\n * Getter for the result of this task.\n * @return the result of this task, or {@code null} if the task is not\n * finished.\n */\n TaskResult getResult();\n\n /**\n * Getter for the set of tasks that depend from this task\n * @return The set of dependent tasks (can be null)\n */\n Set<Task> getDependentTasks();\n\n /**\n * Setter for the set of tasks that depend from this task\n * @param dependentTasks the set of dependent tasks to set\n */\n void setDependentTasks(Set<Task> dependentTasks);\n\n /**\n * Getter for the aggregated task this task has generated and is dependent on.\n * @return The aggregated task, if any (can be null)\n */\n Task getAggregatedTask();\n\n /**\n * Setter for the aggregated task this task has generated and is dependent on.\n * @param aggregatedTask the aggregated task to set\n */\n void setAggregatedTask(Task aggregatedTask);\n\n // TODO Other references could be added to extend the tasks model: e.g.\n // (1) subtasks: list of tasks composing this task, i.e. that should be\n // executed\n // in sequence in order to complete this task, and\n // (2) supertask: reversely, task this task is a subtask of.\n\n /**\n * Getter for the set of conversations this task generated and is now\n * dependent on.\n * @return the set of generated conversations\n */\n Set<OnGoingConversation> getGeneratedConversations();\n\n /**\n * Setter for generatedConversations.\n * @param generatedConversations the set of generatedConversations to set\n */\n void setGeneratedConversations(\n Set<OnGoingConversation> generatedConversations);\n\n /**\n * Cuts all references to other objects so that the garbage collector can\n * destroy them after having destroyed this task, if they are not referenced\n * by other objects than this task. Should be executed before removing the\n * last reference to this task (usually before removing this task from the set\n * of tasks of a conversational object)\n */\n void clean();\n\n /**\n * Executes the task. Specific to each concrete task class.\n */\n void execute();\n}", "public interface RMITreeNode extends Remote {\n\n\t/**\n\t * Set the father of the RMITreeNodeImpl. If it's set to null, the RMITreeNodeImpl becomes a root.\n\t * @param father The father of the RMITreeNodeImpl. If it's null, the RMITreeNodeImpl is a root.\n\t */\n\tpublic void setFather(RMITreeNode father) throws RemoteException;\n\t\n\tpublic void addChild(RMITreeNode child) throws RemoteException;\n\t\n\tpublic void removeChild(int index) throws RemoteException;\n\t\n\tpublic void removeChild(RMITreeNode child) throws RemoteException;\n\t\n\t/**\n\t * Remove every child of the RMITreeNode so it becomes a leaf.\n\t */\n\tpublic void clearChildren() throws RemoteException;\n\t\n\tpublic RMITreeNode getFather() throws RemoteException;\n\t\n\tpublic List<RMITreeNode> getChildren() throws RemoteException;\n\t\n\tpublic RMITreeNode getChild(int index) throws RemoteException;\n\t\n\tpublic String getName() throws RemoteException;\n\t\n\t/**\n\t * Return a String containing the trace of the propogation since its beginning.\n\t * @return The trace of the propogation.\n\t * @throws RemoteException\n\t */\n\tpublic String getTrace() throws RemoteException;\n\t\n\t/**\n\t * Give data as an array of byte to the RMITreeNode in order to propagate to the leaves of the tree.\n\t * @param data The data to propagate to the leaves of the tree.\n\t * @return The trace of the entire propagation.\n\t * @throws RemoteException\n\t */\n\tpublic String propagate(byte[] data) throws RemoteException;\n\t\n\t/**\n\t * Send data as an array of byte to every children of the RMITreeNode.\n\t * If the node is a leaf, put the message in the trace.\n\t * @param data An array of byte containing the data to send to the children.\n\t * @return The trace of the children receiving the data.\n\t * @throws RemoteException\n\t */\n\tpublic String sendDataToChildren(byte[] data) throws RemoteException;\n\n}", "public interface ProjectDiagramListener {\n\n /**\n * Listener method. Whenever any publishable change occurs, this method of all listeners is invoked.\n *\n * @param change is an object holding info about the change\n *\n * @see cz.cvut.promod.services.projectService.treeProjectNode.ProjectDiagramChange\n */\n public void changePerformed(final ProjectDiagramChange change);\n}", "public interface NodeSelectionChangedListener {\n public void nodeChanged(NodeSelectedEvent evt);\n}", "public interface TreeModel {\n\n double checkAccuracy(DataSource d);\n void crossValidate(DataSource testdata);\n void pessimisticPrune(double z);\n void printTree();\n\n}", "public interface INodeWalker {\n\t\n\t/**\n\t * adds a filter to the list of filters through which nodes will be passed when \n\t * successor nodes are retrieved via the <code>getFilteredSuccessorNodes</code> method. \n\t * If an identical filter is already in the list of filters, this method does nothing.\n\t * \n\t * @param filter\n\t * @see #getFilteredSuccessorNodes(Object)\n\t */\n\tpublic void addNodeFilter (INodeFilter filter);\n\t\n\t/**\n\t * removes the specified filter from the list of filters through which a node is passed when \n\t * <code>getFilteredSuccessorNodes</code> is called.\n\t * \n\t * @param filter\n\t * @see #getFilteredSuccessorNodes(Object)\n\t */\n\tpublic void removeNodeFilter (INodeFilter filter);\n\t\n\t/**\n\t * removes all filters from this walker\n\t * \n\t * @return all removed filters\n\t */\n\tpublic INodeFilter[] removeAllFilters ();\n\t\n\t/**\n\t * get the starting nodes of the graph. These are the nodes of the graph that have\n\t * no predecessors.\n\t *\n\t * @return starting nodes of graph\n\t */\n\tpublic Object[] getStartNodes ();\n\n\t/**\n\t * retreave the direct predecessors of the given element. The direct predecessors of the\n\t * given element are those elements that are connected to the given element via a single edge and\n\t * serve as heads on that edge, permitting the given element to serve as the tail.\n\t *\n\t * @param node - node for which direct predecessors are desired\n\t * @return direct predecessors of given node or empty array if no predecessors are present\n\t */\n\tpublic Object[] getPredecessorNodes (Object node) throws InvalidComponentException;\n\n\t/**\n\t * retreave the direct successors of the given element. The direct successors of the\n\t * given element are those elements that are connected to the given element via a single edge and\n\t * serve as tails on that edge, permitting the given element to serve as the head.\n\t *\n\t * @param node - node for which direct successors are desired\n\t * @return direct successors of given node or empty array if no successors are present\n\t */\n\tpublic Object[] getSuccessorNodes (Object node) throws InvalidComponentException;\n\n\t/**\n\t * retrieve the direct successors of the given element that pass each of the node filters added via the\n\t * <code>addNodeFilter</code> method. The direct successors of the\n\t * given element are those elements that are connected to the given element via a single edge and\n\t * serve as tails on that edge, permitting the given element to serve as the head.\n\t * \n\t * <p>If no filters have been added or if all filters pass all successor nodes, then this method is \n\t * equivalent to <code>getSuccessorNodes</code>.\n\t *\n\t * @param node - node for which direct successors are desired\n\t * @return direct successors of given node (filtered) or empty array if no successors are present\n\t * @see #addNodeFilter(INodeFilter)\n\t */\n\tpublic Object[] getFilteredSuccessorNodes (Object node) throws InvalidComponentException;\n\n}", "@Test\n public void testCreateDependencyTree1() {\n Map<String, Integer> expected = new HashMap<>() {{\n put(\"github.com/jfrog/jfrog-cli-core:1.9.0\", 11);\n put(\"github.com/jfrog/jfrog-client-go:0.26.1\", 9);\n }};\n\n try {\n Path projectDir = GO_ROOT.resolve(\"project1\");\n GoTreeBuilder treeBuilder = new GoTreeBuilder(null, projectDir, projectDir.resolve(\"go.mod\").toString(), null, log);\n DepTree dt = treeBuilder.buildTree();\n validateDependencyTreeResults(expected, dt);\n } catch (IOException ex) {\n fail(ExceptionUtils.getStackTrace(ex));\n }\n }", "public interface NameServiceDependencies\n extends ServiceDependencies\n {\n /**\n * Return the AcceptorDependencies.\n *\n * @return AcceptorDependencies\n */\n public AcceptorDependencies getAcceptorDependencies();\n }", "public interface Node extends WrappedIndividual {\r\n\r\n /* ***************************************************\r\n * Property http://www.sifemontologies.com/ontologies/FEMSettingsPAK.owl#hasNodeSettings\r\n */\r\n \r\n /**\r\n * Gets all property values for the hasNodeSettings property.<p>\r\n * \r\n * @returns a collection of values for the hasNodeSettings property.\r\n */\r\n Collection<? extends NodeSettings> getHasNodeSettings();\r\n\r\n /**\r\n * Checks if the class has a hasNodeSettings property value.<p>\r\n * \r\n * @return true if there is a hasNodeSettings property value.\r\n */\r\n boolean hasHasNodeSettings();\r\n\r\n /**\r\n * Adds a hasNodeSettings property value.<p>\r\n * \r\n * @param newHasNodeSettings the hasNodeSettings property value to be added\r\n */\r\n void addHasNodeSettings(NodeSettings newHasNodeSettings);\r\n\r\n /**\r\n * Removes a hasNodeSettings property value.<p>\r\n * \r\n * @param oldHasNodeSettings the hasNodeSettings property value to be removed.\r\n */\r\n void removeHasNodeSettings(NodeSettings oldHasNodeSettings);\r\n\r\n\r\n /* ***************************************************\r\n * Property http://www.sifemontologies.com/ontologies/FiniteElementModel.owl#isBoundaryNodeOf\r\n */\r\n \r\n /**\r\n * Gets all property values for the isBoundaryNodeOf property.<p>\r\n * \r\n * @returns a collection of values for the isBoundaryNodeOf property.\r\n */\r\n Collection<? extends Boundary> getIsBoundaryNodeOf();\r\n\r\n /**\r\n * Checks if the class has a isBoundaryNodeOf property value.<p>\r\n * \r\n * @return true if there is a isBoundaryNodeOf property value.\r\n */\r\n boolean hasIsBoundaryNodeOf();\r\n\r\n /**\r\n * Adds a isBoundaryNodeOf property value.<p>\r\n * \r\n * @param newIsBoundaryNodeOf the isBoundaryNodeOf property value to be added\r\n */\r\n void addIsBoundaryNodeOf(Boundary newIsBoundaryNodeOf);\r\n\r\n /**\r\n * Removes a isBoundaryNodeOf property value.<p>\r\n * \r\n * @param oldIsBoundaryNodeOf the isBoundaryNodeOf property value to be removed.\r\n */\r\n void removeIsBoundaryNodeOf(Boundary oldIsBoundaryNodeOf);\r\n\r\n\r\n /* ***************************************************\r\n * Property http://www.sifemontologies.com/ontologies/FiniteElementModel.owl#isNodeOf\r\n */\r\n \r\n /**\r\n * Gets all property values for the isNodeOf property.<p>\r\n * \r\n * @returns a collection of values for the isNodeOf property.\r\n */\r\n Collection<? extends Subdomain> getIsNodeOf();\r\n\r\n /**\r\n * Checks if the class has a isNodeOf property value.<p>\r\n * \r\n * @return true if there is a isNodeOf property value.\r\n */\r\n boolean hasIsNodeOf();\r\n\r\n /**\r\n * Adds a isNodeOf property value.<p>\r\n * \r\n * @param newIsNodeOf the isNodeOf property value to be added\r\n */\r\n void addIsNodeOf(Subdomain newIsNodeOf);\r\n\r\n /**\r\n * Removes a isNodeOf property value.<p>\r\n * \r\n * @param oldIsNodeOf the isNodeOf property value to be removed.\r\n */\r\n void removeIsNodeOf(Subdomain oldIsNodeOf);\r\n\r\n\r\n /* ***************************************************\r\n * Property http://www.sifemontologies.com/ontologies/FiniteElementModel.owl#isVertexOf\r\n */\r\n \r\n /**\r\n * Gets all property values for the isVertexOf property.<p>\r\n * \r\n * @returns a collection of values for the isVertexOf property.\r\n */\r\n Collection<? extends Subdomain_group> getIsVertexOf();\r\n\r\n /**\r\n * Checks if the class has a isVertexOf property value.<p>\r\n * \r\n * @return true if there is a isVertexOf property value.\r\n */\r\n boolean hasIsVertexOf();\r\n\r\n /**\r\n * Adds a isVertexOf property value.<p>\r\n * \r\n * @param newIsVertexOf the isVertexOf property value to be added\r\n */\r\n void addIsVertexOf(Subdomain_group newIsVertexOf);\r\n\r\n /**\r\n * Removes a isVertexOf property value.<p>\r\n * \r\n * @param oldIsVertexOf the isVertexOf property value to be removed.\r\n */\r\n void removeIsVertexOf(Subdomain_group oldIsVertexOf);\r\n\r\n\r\n /* ***************************************************\r\n * Property http://www.sifemontologies.com/ontologies/FiniteElementModel.owl#hasNodeID\r\n */\r\n \r\n /**\r\n * Gets all property values for the hasNodeID property.<p>\r\n * \r\n * @returns a collection of values for the hasNodeID property.\r\n */\r\n Collection<? extends Integer> getHasNodeID();\r\n\r\n /**\r\n * Checks if the class has a hasNodeID property value.<p>\r\n * \r\n * @return true if there is a hasNodeID property value.\r\n */\r\n boolean hasHasNodeID();\r\n\r\n /**\r\n * Adds a hasNodeID property value.<p>\r\n * \r\n * @param newHasNodeID the hasNodeID property value to be added\r\n */\r\n void addHasNodeID(Integer newHasNodeID);\r\n\r\n /**\r\n * Removes a hasNodeID property value.<p>\r\n * \r\n * @param oldHasNodeID the hasNodeID property value to be removed.\r\n */\r\n void removeHasNodeID(Integer oldHasNodeID);\r\n\r\n\r\n\r\n /* ***************************************************\r\n * Property http://www.sifemontologies.com/ontologies/FiniteElementModel.owl#hasXCoordinate\r\n */\r\n \r\n /**\r\n * Gets all property values for the hasXCoordinate property.<p>\r\n * \r\n * @returns a collection of values for the hasXCoordinate property.\r\n */\r\n Collection<? extends Object> getHasXCoordinate();\r\n\r\n /**\r\n * Checks if the class has a hasXCoordinate property value.<p>\r\n * \r\n * @return true if there is a hasXCoordinate property value.\r\n */\r\n boolean hasHasXCoordinate();\r\n\r\n /**\r\n * Adds a hasXCoordinate property value.<p>\r\n * \r\n * @param newHasXCoordinate the hasXCoordinate property value to be added\r\n */\r\n void addHasXCoordinate(Object newHasXCoordinate);\r\n\r\n /**\r\n * Removes a hasXCoordinate property value.<p>\r\n * \r\n * @param oldHasXCoordinate the hasXCoordinate property value to be removed.\r\n */\r\n void removeHasXCoordinate(Object oldHasXCoordinate);\r\n\r\n\r\n\r\n /* ***************************************************\r\n * Property http://www.sifemontologies.com/ontologies/FiniteElementModel.owl#hasYCoordinate\r\n */\r\n \r\n /**\r\n * Gets all property values for the hasYCoordinate property.<p>\r\n * \r\n * @returns a collection of values for the hasYCoordinate property.\r\n */\r\n Collection<? extends Object> getHasYCoordinate();\r\n\r\n /**\r\n * Checks if the class has a hasYCoordinate property value.<p>\r\n * \r\n * @return true if there is a hasYCoordinate property value.\r\n */\r\n boolean hasHasYCoordinate();\r\n\r\n /**\r\n * Adds a hasYCoordinate property value.<p>\r\n * \r\n * @param newHasYCoordinate the hasYCoordinate property value to be added\r\n */\r\n void addHasYCoordinate(Object newHasYCoordinate);\r\n\r\n /**\r\n * Removes a hasYCoordinate property value.<p>\r\n * \r\n * @param oldHasYCoordinate the hasYCoordinate property value to be removed.\r\n */\r\n void removeHasYCoordinate(Object oldHasYCoordinate);\r\n\r\n\r\n\r\n /* ***************************************************\r\n * Property http://www.sifemontologies.com/ontologies/FiniteElementModel.owl#hasZCoordinate\r\n */\r\n \r\n /**\r\n * Gets all property values for the hasZCoordinate property.<p>\r\n * \r\n * @returns a collection of values for the hasZCoordinate property.\r\n */\r\n Collection<? extends Object> getHasZCoordinate();\r\n\r\n /**\r\n * Checks if the class has a hasZCoordinate property value.<p>\r\n * \r\n * @return true if there is a hasZCoordinate property value.\r\n */\r\n boolean hasHasZCoordinate();\r\n\r\n /**\r\n * Adds a hasZCoordinate property value.<p>\r\n * \r\n * @param newHasZCoordinate the hasZCoordinate property value to be added\r\n */\r\n void addHasZCoordinate(Object newHasZCoordinate);\r\n\r\n /**\r\n * Removes a hasZCoordinate property value.<p>\r\n * \r\n * @param oldHasZCoordinate the hasZCoordinate property value to be removed.\r\n */\r\n void removeHasZCoordinate(Object oldHasZCoordinate);\r\n\r\n\r\n\r\n /* ***************************************************\r\n * Property http://www.sifemontologies.com/ontologies/FiniteElementModel.owl#isCentralNode\r\n */\r\n \r\n /**\r\n * Gets all property values for the isCentralNode property.<p>\r\n * \r\n * @returns a collection of values for the isCentralNode property.\r\n */\r\n Collection<? extends Boolean> getIsCentralNode();\r\n\r\n /**\r\n * Checks if the class has a isCentralNode property value.<p>\r\n * \r\n * @return true if there is a isCentralNode property value.\r\n */\r\n boolean hasIsCentralNode();\r\n\r\n /**\r\n * Adds a isCentralNode property value.<p>\r\n * \r\n * @param newIsCentralNode the isCentralNode property value to be added\r\n */\r\n void addIsCentralNode(Boolean newIsCentralNode);\r\n\r\n /**\r\n * Removes a isCentralNode property value.<p>\r\n * \r\n * @param oldIsCentralNode the isCentralNode property value to be removed.\r\n */\r\n void removeIsCentralNode(Boolean oldIsCentralNode);\r\n\r\n\r\n\r\n /* ***************************************************\r\n * Property http://www.sifemontologies.com/ontologies/FiniteElementModel.owl#isMidNode\r\n */\r\n \r\n /**\r\n * Gets all property values for the isMidNode property.<p>\r\n * \r\n * @returns a collection of values for the isMidNode property.\r\n */\r\n Collection<? extends Boolean> getIsMidNode();\r\n\r\n /**\r\n * Checks if the class has a isMidNode property value.<p>\r\n * \r\n * @return true if there is a isMidNode property value.\r\n */\r\n boolean hasIsMidNode();\r\n\r\n /**\r\n * Adds a isMidNode property value.<p>\r\n * \r\n * @param newIsMidNode the isMidNode property value to be added\r\n */\r\n void addIsMidNode(Boolean newIsMidNode);\r\n\r\n /**\r\n * Removes a isMidNode property value.<p>\r\n * \r\n * @param oldIsMidNode the isMidNode property value to be removed.\r\n */\r\n void removeIsMidNode(Boolean oldIsMidNode);\r\n\r\n\r\n\r\n /* ***************************************************\r\n * Common interfaces\r\n */\r\n\r\n OWLNamedIndividual getOwlIndividual();\r\n\r\n OWLOntology getOwlOntology();\r\n\r\n void delete();\r\n\r\n}", "public ClassNode(Ontology o) {\n\t\tname = o.getName();\n\t}", "public LibraryDependencyGraph createLibraryDependencyGraph(DependencyTypeSet dependencySet)\n {\n // Get the compilation units from the swcs.\n List<ISWC> swcs = getLibraries();\n Workspace w = getWorkspace();\n List<IRequest<IOutgoingDependenciesRequestResult, ICompilationUnit>> requests =\n new ArrayList<IRequest<IOutgoingDependenciesRequestResult, ICompilationUnit>>();\n \n // For each swc, get the compilation units. Request the semantic problems\n // for each compilation unit to cause the dependency graph to be built.\n Set<ICompilationUnit> swcUnits = new HashSet<ICompilationUnit>();\n \n for (ISWC swc : swcs)\n {\n String path = swc.getSWCFile().getAbsolutePath();\n Collection<ICompilationUnit> units = w.getCompilationUnits(path, this);\n swcUnits.addAll(units);\n \n for (ICompilationUnit unit : units)\n requests.add(unit.getOutgoingDependenciesRequest());\n }\n \n // Iterate over the requests to cause the dependency graph to be\n // populated.\n for (IRequest<IOutgoingDependenciesRequestResult, ICompilationUnit> request : requests)\n {\n try\n {\n request.get();\n }\n catch (InterruptedException e)\n {\n assert false : \"Unexpected interruption\";\n return null;\n }\n }\n \n // Now that the dependency tree of compilation units is populated, \n // build a graph of library dependencies.\n DependencyGraph unitGraph = getDependencyGraph();\n LibraryDependencyGraph libraryGraph = new LibraryDependencyGraph();\n \n for (ICompilationUnit unit : swcUnits)\n {\n Set<Edge> dependencies = unitGraph.getOutgoingEdges(unit);\n \n // If a unit has no dependencies then make sure we add the swc to\n // the graph to make sure no swcs are missing.\n if (dependencies.size() == 0)\n libraryGraph.addLibrary(unit.getAbsoluteFilename());\n \n // For each edge look to see it the dependency is external to the swc since\n // we only care about external dependencies. \n // If it is an external dependency then filter based of the dependency types\n // we care about.\n for (Edge dependency : dependencies)\n {\n // Test if the edge is between different swcs\n ICompilationUnit from = dependency.getFrom();\n ICompilationUnit to = dependency.getTo();\n\n /* Check if the compilation units live in different\n * swcs. If so, add a dependency between the swcs.\n */\n if (isInterSWCDependency(from, to))\n {\n if (dependencySet == null || \n dependency.typeInSet(dependencySet) ||\n dependencySet.isEmpty())\n {\n libraryGraph.addLibrary(from.getAbsoluteFilename());\n libraryGraph.addLibrary(to.getAbsoluteFilename());\n libraryGraph.addDependency(from.getAbsoluteFilename(), to.getAbsoluteFilename(),\n dependency.getNamedDependencies());\n }\n }\n }\n }\n \n return libraryGraph;\n }", "Optional<ServiceEdge> getEdge(T dependant, T dependency);", "protected RemoteFactory.Requires<Msg, Ref> requires() {\n assert this.selfComponent != null: \"This is a bug.\";\n if (!this.init) {\n \tthrow new RuntimeException(\"requires() can't be accessed until a component has been created from this implementation, use start() instead of the constructor if requires() is needed to initialise the component.\");\n }\n return this.selfComponent.bridge;\n }", "public interface IContainerTreeNode extends IMutableTypeContainer, MutableTreeNode {\r\n}", "private static void traverseGraph(Object o, SmartVisitor visitor) {\r\n if (SmartAccess.isSmartContainer(o)) {\r\n traverseSmartContainer(o, visitor);\r\n } else if (SmartAccess.isVersionable(o)) {\r\n traverseVersionable(o, visitor);\r\n } else {\r\n throw new IllegalArgumentException();\r\n }\r\n }", "public static void initializeDiContainer() {\n addDependency(new CamelCaseConverter());\n addDependency(new JavadocGenerator());\n addDependency(new TemplateResolver());\n addDependency(new PreferenceStoreProvider());\n addDependency(new CurrentShellProvider());\n addDependency(new ITypeExtractor());\n addDependency(new DialogWrapper(getDependency(CurrentShellProvider.class)));\n addDependency(new PreferencesManager(getDependency(PreferenceStoreProvider.class)));\n addDependency(new ErrorHandlerHook(getDependency(DialogWrapper.class)));\n\n addDependency(new BodyDeclarationOfTypeExtractor());\n addDependency(new GeneratedAnnotationPredicate());\n addDependency(new GenericModifierPredicate());\n addDependency(new IsPrivatePredicate(getDependency(GenericModifierPredicate.class)));\n addDependency(new IsStaticPredicate(getDependency(GenericModifierPredicate.class)));\n addDependency(new IsPublicPredicate(getDependency(GenericModifierPredicate.class)));\n addDependency(new GeneratedAnnotationContainingBodyDeclarationFilter(getDependency(GeneratedAnnotationPredicate.class)));\n addDependency(new PrivateConstructorRemover(getDependency(IsPrivatePredicate.class),\n getDependency(GeneratedAnnotationContainingBodyDeclarationFilter.class)));\n addDependency(new BodyDeclarationOfTypeExtractor());\n addDependency(new BuilderClassRemover(getDependency(BodyDeclarationOfTypeExtractor.class),\n getDependency(GeneratedAnnotationContainingBodyDeclarationFilter.class),\n getDependency(IsPrivatePredicate.class),\n getDependency(IsStaticPredicate.class),\n getDependency(PreferencesManager.class)));\n addDependency(new JsonDeserializeRemover(getDependency(PreferencesManager.class)));\n addDependency(new StagedBuilderInterfaceRemover(getDependency(BodyDeclarationOfTypeExtractor.class),\n getDependency(GeneratedAnnotationContainingBodyDeclarationFilter.class)));\n addDependency(new StaticBuilderMethodRemover(getDependency(IsStaticPredicate.class), getDependency(IsPublicPredicate.class),\n getDependency(GeneratedAnnotationContainingBodyDeclarationFilter.class)));\n addDependency(new BuilderAstRemover(getDependencyList(BuilderRemoverChainItem.class)));\n\n addDependency(new BuilderRemover(getDependency(PreferencesManager.class), getDependency(ErrorHandlerHook.class),\n getDependency(BuilderAstRemover.class)));\n addDependency(new CompilationUnitSourceSetter());\n addDependency(new HandlerUtilWrapper());\n addDependency(new WorkingCopyManager());\n addDependency(new WorkingCopyManagerWrapper(getDependency(HandlerUtilWrapper.class)));\n addDependency(new CompilationUnitParser());\n addDependency(new GeneratedAnnotationPopulator(getDependency(PreferencesManager.class)));\n addDependency(new MarkerAnnotationAttacher());\n addDependency(new ImportRepository());\n addDependency(new ImportPopulator(getDependency(PreferencesManager.class), getDependency(ImportRepository.class)));\n addDependency(new BuilderMethodNameBuilder(getDependency(CamelCaseConverter.class),\n getDependency(PreferencesManager.class),\n getDependency(TemplateResolver.class)));\n addDependency(new PrivateConstructorAdderFragment());\n addDependency(new JsonPOJOBuilderAdderFragment(getDependency(PreferencesManager.class), getDependency(ImportRepository.class)));\n addDependency(new EmptyBuilderClassGeneratorFragment(getDependency(GeneratedAnnotationPopulator.class),\n getDependency(PreferencesManager.class),\n getDependency(JavadocGenerator.class),\n getDependency(TemplateResolver.class),\n getDependency(JsonPOJOBuilderAdderFragment.class)));\n addDependency(new BuildMethodBodyCreatorFragment());\n addDependency(new BuildMethodDeclarationCreatorFragment(getDependency(PreferencesManager.class),\n getDependency(MarkerAnnotationAttacher.class),\n getDependency(TemplateResolver.class)));\n addDependency(new JavadocAdder(getDependency(JavadocGenerator.class), getDependency(PreferencesManager.class)));\n addDependency(new BuildMethodCreatorFragment(getDependency(BuildMethodDeclarationCreatorFragment.class),\n getDependency(BuildMethodBodyCreatorFragment.class)));\n addDependency(new FullyQualifiedNameExtractor());\n addDependency(new StaticMethodInvocationFragment());\n addDependency(new OptionalInitializerChainItem(getDependency(StaticMethodInvocationFragment.class), getDependency(PreferencesManager.class)));\n addDependency(new BuiltInCollectionsInitializerChainitem(getDependency(StaticMethodInvocationFragment.class), getDependency(PreferencesManager.class)));\n addDependency(new FieldDeclarationPostProcessor(getDependency(PreferencesManager.class), getDependency(FullyQualifiedNameExtractor.class),\n getDependency(ImportRepository.class), getDependencyList(FieldDeclarationPostProcessorChainItem.class)));\n addDependency(new BuilderFieldAdderFragment(getDependency(FieldDeclarationPostProcessor.class)));\n addDependency(new WithMethodParameterCreatorFragment(getDependency(PreferencesManager.class), getDependency(MarkerAnnotationAttacher.class)));\n addDependency(new RegularBuilderWithMethodAdderFragment(getDependency(PreferencesManager.class),\n getDependency(JavadocAdder.class),\n getDependency(MarkerAnnotationAttacher.class),\n getDependency(BuilderMethodNameBuilder.class),\n getDependency(WithMethodParameterCreatorFragment.class)));\n addDependency(new BuilderFieldAccessCreatorFragment());\n addDependency(new TypeDeclarationToVariableNameConverter(getDependency(CamelCaseConverter.class)));\n addDependency(new FieldSetterAdderFragment(getDependency(BuilderFieldAccessCreatorFragment.class)));\n addDependency(new IsRegularBuilderInstanceCopyEnabledPredicate(getDependency(PreferencesManager.class)));\n addDependency(new RegularBuilderCopyInstanceConstructorAdderFragment(getDependency(TypeDeclarationToVariableNameConverter.class),\n getDependency(IsRegularBuilderInstanceCopyEnabledPredicate.class)));\n addDependency(new PublicConstructorWithMandatoryFieldsAdderFragment());\n addDependency(new RegularBuilderClassCreator(getDependency(PrivateConstructorAdderFragment.class),\n getDependency(EmptyBuilderClassGeneratorFragment.class),\n getDependency(BuildMethodCreatorFragment.class),\n getDependency(BuilderFieldAdderFragment.class),\n getDependency(RegularBuilderWithMethodAdderFragment.class),\n getDependency(JavadocAdder.class),\n getDependency(RegularBuilderCopyInstanceConstructorAdderFragment.class),\n getDependency(PublicConstructorWithMandatoryFieldsAdderFragment.class)));\n addDependency(new StaticBuilderMethodSignatureGeneratorFragment(getDependency(GeneratedAnnotationPopulator.class), getDependency(PreferencesManager.class)));\n addDependency(new BuilderMethodDefinitionCreatorFragment(getDependency(TemplateResolver.class),\n getDependency(PreferencesManager.class),\n getDependency(JavadocAdder.class), getDependency(StaticBuilderMethodSignatureGeneratorFragment.class)));\n addDependency(new BlockWithNewBuilderCreationFragment());\n addDependency(\n new RegularBuilderBuilderMethodCreator(getDependency(BlockWithNewBuilderCreationFragment.class),\n getDependency(BuilderMethodDefinitionCreatorFragment.class)));\n addDependency(new PrivateConstructorMethodDefinitionCreationFragment(getDependency(PreferencesManager.class),\n getDependency(GeneratedAnnotationPopulator.class),\n getDependency(CamelCaseConverter.class)));\n addDependency(new SuperFieldSetterMethodAdderFragment(getDependency(BuilderFieldAccessCreatorFragment.class)));\n addDependency(new PrivateConstructorBodyCreationFragment(getDependency(TypeDeclarationToVariableNameConverter.class),\n getDependency(FieldSetterAdderFragment.class),\n getDependency(BuilderFieldAccessCreatorFragment.class),\n getDependency(SuperFieldSetterMethodAdderFragment.class)));\n addDependency(new ConstructorInsertionFragment());\n addDependency(new PrivateInitializingConstructorCreator(\n getDependency(PrivateConstructorMethodDefinitionCreationFragment.class),\n getDependency(PrivateConstructorBodyCreationFragment.class),\n getDependency(ConstructorInsertionFragment.class)));\n addDependency(new FieldPrefixSuffixPreferenceProvider(getDependency(PreferenceStoreProvider.class)));\n addDependency(new FieldNameToBuilderFieldNameConverter(getDependency(PreferencesManager.class),\n getDependency(FieldPrefixSuffixPreferenceProvider.class),\n getDependency(CamelCaseConverter.class)));\n addDependency(new TypeDeclarationFromSuperclassExtractor(getDependency(CompilationUnitParser.class),\n getDependency(ITypeExtractor.class)));\n addDependency(new BodyDeclarationVisibleFromPredicate());\n addDependency(new ApplicableFieldVisibilityFilter(getDependency(BodyDeclarationVisibleFromPredicate.class)));\n addDependency(new ClassFieldCollector(getDependency(FieldNameToBuilderFieldNameConverter.class),\n getDependency(PreferencesManager.class), getDependency(TypeDeclarationFromSuperclassExtractor.class),\n getDependency(ApplicableFieldVisibilityFilter.class)));\n addDependency(new RecordFieldCollector(getDependency(FieldNameToBuilderFieldNameConverter.class)));\n addDependency(new BodyDeclarationFinderUtil(getDependency(CamelCaseConverter.class)));\n addDependency(new SuperConstructorParameterCollector(getDependency(FieldNameToBuilderFieldNameConverter.class),\n getDependency(PreferencesManager.class), getDependency(TypeDeclarationFromSuperclassExtractor.class),\n getDependency(BodyDeclarationVisibleFromPredicate.class),\n getDependency(BodyDeclarationFinderUtil.class)));\n addDependency(new SuperClassSetterFieldCollector(getDependency(PreferencesManager.class),\n getDependency(TypeDeclarationFromSuperclassExtractor.class),\n getDependency(CamelCaseConverter.class),\n getDependency(BodyDeclarationFinderUtil.class)));\n addDependency(new ApplicableBuilderFieldExtractor(Arrays.asList(\n getDependency(SuperConstructorParameterCollector.class),\n getDependency(ClassFieldCollector.class),\n getDependency(SuperClassSetterFieldCollector.class),\n getDependency(RecordFieldCollector.class))));\n addDependency(new ActiveJavaEditorOffsetProvider());\n addDependency(new ParentITypeExtractor());\n addDependency(new IsTypeApplicableForBuilderGenerationPredicate(getDependency(ParentITypeExtractor.class)));\n addDependency(new CurrentlySelectedApplicableClassesClassNameProvider(getDependency(ActiveJavaEditorOffsetProvider.class),\n getDependency(IsTypeApplicableForBuilderGenerationPredicate.class),\n getDependency(ParentITypeExtractor.class)));\n addDependency(new BuilderOwnerClassFinder(getDependency(CurrentlySelectedApplicableClassesClassNameProvider.class),\n getDependency(PreferencesManager.class), getDependency(GeneratedAnnotationPredicate.class)));\n addDependency(new BlockWithNewCopyInstanceConstructorCreationFragment());\n addDependency(new CopyInstanceBuilderMethodDefinitionCreatorFragment(getDependency(TemplateResolver.class),\n getDependency(PreferencesManager.class),\n getDependency(JavadocAdder.class), getDependency(StaticBuilderMethodSignatureGeneratorFragment.class)));\n addDependency(new RegularBuilderCopyInstanceBuilderMethodCreator(getDependency(BlockWithNewCopyInstanceConstructorCreationFragment.class),\n getDependency(CopyInstanceBuilderMethodDefinitionCreatorFragment.class),\n getDependency(TypeDeclarationToVariableNameConverter.class),\n getDependency(IsRegularBuilderInstanceCopyEnabledPredicate.class)));\n addDependency(new JsonDeserializeAdder(getDependency(ImportRepository.class)));\n addDependency(new GlobalBuilderPostProcessor(getDependency(PreferencesManager.class), getDependency(JsonDeserializeAdder.class)));\n addDependency(new DefaultConstructorAppender(getDependency(ConstructorInsertionFragment.class), getDependency(PreferencesManager.class),\n getDependency(GeneratedAnnotationPopulator.class)));\n addDependency(new RegularBuilderCompilationUnitGenerator(getDependency(RegularBuilderClassCreator.class),\n getDependency(RegularBuilderCopyInstanceBuilderMethodCreator.class),\n getDependency(PrivateInitializingConstructorCreator.class),\n getDependency(RegularBuilderBuilderMethodCreator.class), getDependency(ImportPopulator.class),\n getDependency(BuilderRemover.class),\n getDependency(GlobalBuilderPostProcessor.class),\n getDependency(DefaultConstructorAppender.class)));\n addDependency(new RegularBuilderUserPreferenceDialogOpener(getDependency(CurrentShellProvider.class)));\n addDependency(new RegularBuilderDialogDataConverter());\n addDependency(new RegularBuilderUserPreferenceConverter(getDependency(PreferencesManager.class)));\n addDependency(new RegularBuilderUserPreferenceProvider(getDependency(RegularBuilderUserPreferenceDialogOpener.class),\n getDependency(PreferencesManager.class),\n getDependency(RegularBuilderDialogDataConverter.class),\n getDependency(RegularBuilderUserPreferenceConverter.class)));\n addDependency(new RegularBuilderCompilationUnitGeneratorBuilderFieldCollectingDecorator(getDependency(ApplicableBuilderFieldExtractor.class),\n getDependency(RegularBuilderCompilationUnitGenerator.class),\n getDependency(RegularBuilderUserPreferenceProvider.class)));\n addDependency(new IsEventOnJavaFilePredicate(getDependency(HandlerUtilWrapper.class)));\n\n // staged builder dependencies\n addDependency(new StagedBuilderInterfaceNameProvider(getDependency(PreferencesManager.class),\n getDependency(CamelCaseConverter.class),\n getDependency(TemplateResolver.class)));\n addDependency(new StagedBuilderWithMethodDefiniationCreatorFragment(getDependency(PreferencesManager.class),\n getDependency(BuilderMethodNameBuilder.class),\n getDependency(MarkerAnnotationAttacher.class),\n getDependency(StagedBuilderInterfaceNameProvider.class),\n getDependency(WithMethodParameterCreatorFragment.class)));\n addDependency(new StagedBuilderInterfaceTypeDefinitionCreatorFragment(getDependency(JavadocAdder.class)));\n addDependency(new StagedBuilderInterfaceCreatorFragment(getDependency(StagedBuilderWithMethodDefiniationCreatorFragment.class),\n getDependency(StagedBuilderInterfaceTypeDefinitionCreatorFragment.class),\n getDependency(StagedBuilderInterfaceTypeDefinitionCreatorFragment.class),\n getDependency(BuildMethodDeclarationCreatorFragment.class),\n getDependency(JavadocAdder.class),\n getDependency(GeneratedAnnotationPopulator.class)));\n addDependency(new StagedBuilderCreationBuilderMethodAdder(getDependency(BlockWithNewBuilderCreationFragment.class),\n getDependency(BuilderMethodDefinitionCreatorFragment.class)));\n addDependency(new NewBuilderAndWithMethodCallCreationFragment());\n addDependency(new StagedBuilderCreationWithMethodAdder(getDependency(StagedBuilderWithMethodDefiniationCreatorFragment.class),\n getDependency(NewBuilderAndWithMethodCallCreationFragment.class), getDependency(JavadocAdder.class)));\n addDependency(new StagedBuilderStaticBuilderCreatorMethodCreator(getDependency(StagedBuilderCreationBuilderMethodAdder.class),\n getDependency(StagedBuilderCreationWithMethodAdder.class),\n getDependency(PreferencesManager.class)));\n addDependency(new StagedBuilderWithMethodAdderFragment(\n getDependency(StagedBuilderWithMethodDefiniationCreatorFragment.class),\n getDependency(MarkerAnnotationAttacher.class)));\n addDependency(new InterfaceSetter());\n addDependency(new StagedBuilderClassCreator(getDependency(PrivateConstructorAdderFragment.class),\n getDependency(EmptyBuilderClassGeneratorFragment.class),\n getDependency(BuildMethodCreatorFragment.class),\n getDependency(BuilderFieldAdderFragment.class),\n getDependency(StagedBuilderWithMethodAdderFragment.class),\n getDependency(InterfaceSetter.class),\n getDependency(MarkerAnnotationAttacher.class)));\n addDependency(new StagedBuilderStagePropertyInputDialogOpener(getDependency(CurrentShellProvider.class)));\n addDependency(new StagedBuilderStagePropertiesProvider(getDependency(StagedBuilderInterfaceNameProvider.class),\n getDependency(StagedBuilderStagePropertyInputDialogOpener.class)));\n addDependency(new StagedBuilderCompilationUnitGenerator(getDependency(StagedBuilderClassCreator.class),\n getDependency(PrivateInitializingConstructorCreator.class),\n getDependency(StagedBuilderStaticBuilderCreatorMethodCreator.class),\n getDependency(ImportPopulator.class),\n getDependency(StagedBuilderInterfaceCreatorFragment.class),\n getDependency(BuilderRemover.class),\n getDependency(GlobalBuilderPostProcessor.class),\n getDependency(DefaultConstructorAppender.class)));\n addDependency(new StagedBuilderCompilationUnitGeneratorFieldCollectorDecorator(\n getDependency(StagedBuilderCompilationUnitGenerator.class),\n getDependency(ApplicableBuilderFieldExtractor.class),\n getDependency(StagedBuilderStagePropertiesProvider.class)));\n\n // Generator chain\n addDependency(new GenerateBuilderExecutorImpl(getDependency(CompilationUnitParser.class),\n getDependencyList(BuilderCompilationUnitGenerator.class),\n getDependency(IsEventOnJavaFilePredicate.class), getDependency(WorkingCopyManagerWrapper.class),\n getDependency(CompilationUnitSourceSetter.class),\n getDependency(ErrorHandlerHook.class),\n getDependency(BuilderOwnerClassFinder.class)));\n addDependency(new GenerateBuilderHandlerErrorHandlerDecorator(getDependency(GenerateBuilderExecutorImpl.class),\n getDependency(ErrorHandlerHook.class)));\n addDependency(new StatefulBeanHandler(getDependency(PreferenceStoreProvider.class),\n getDependency(WorkingCopyManagerWrapper.class), getDependency(ImportRepository.class)));\n addDependency(\n new StateInitializerGenerateBuilderExecutorDecorator(\n getDependency(GenerateBuilderHandlerErrorHandlerDecorator.class),\n getDependency(StatefulBeanHandler.class)));\n }", "public interface Node\n{\n /**\n * Method to be signaled with a received message\n *\n * @param receiverThread <code>TCPReceiverThread</code> of the receiver associated with the message. Contains\n * a socket connection to the message sender.\n * @param data <code>Event</code> of the incoming message.\n */\n public void onEvent(TCPReceiverThread receiverThread, Event event) throws IOException;\n\n// public void onEvent(TCPReceiverThread receiverThread, byte[] data) throws IOException;\n\n\n /**\n * Method to register a connection between the current node and another. To register a\n * connection, we must create a new Link and add it to our list of connected nodes.\n *\n * @param receiverThread <code>TCPReceiverThread</code> of the receiver thread associated with the node that\n * is being registered.\n * @param sourceID <code>String</code> identifier of the Node creating the Link.\n * @param targetID <code>String</code> identifier of the Node the created Link is to.\n */\n public void registerConnection(TCPReceiverThread receiverThread, String sourceID, String targetID);\n\n /**\n * Method to deregister a node from the current node (ie., sever the link)\n *\n * @param ID <<code>String</code> of the ID to be associated with the link to be deregistered.\n */\n public void deregisterConnection(String ID);\n\n /**\n * Method to return the current Node's ID\n *\n * @return <code>String</code> of the current Node's identifier.\n */\n public String getID();\n\n}", "public interface ClasspathComponent {\r\n\r\n /**\r\n * Find a class by name within thsi classpath component.\r\n * @param className the name of the class\r\n * @return the <tt>FindResult</tt> object. <tt>null</tt> if no class could be found.\r\n */\r\n public FindResult findClass(String className);\r\n\r\n /**\r\n * Merge all classes in this classpath component into the supplied tree.\r\n * @param model the tree model.\r\n * @param reset whether this is an incremental operation or part of a reset.\r\n * For a reset, no change events will be fired on the tree model.\r\n */\r\n public void mergeClassesIntoTree(DefaultTreeModel model, boolean reset);\r\n\r\n /**\r\n * Add a <tt>ClasspathChangeListener</tt>.\r\n * @param listener the listener\r\n */\r\n public void addClasspathChangeListener(ClasspathChangeListener listener);\r\n\r\n /**\r\n * Remove a <tt>ClasspathChangeListener</tt>.\r\n * @param listener the listener\r\n */\r\n public void removeClasspathChangeListener(ClasspathChangeListener listener);\r\n}", "public void setDependencyFactory( DependencyFactory dependencyFactory ) \r\n {\r\n this.dependencyFactory = dependencyFactory;\r\n }", "@RequiresLock(\"SeaLock\")\r\n @Vouch(\"controlled alias of f_dependents for performance\")\r\n protected final Set<Drop> getDependentsReference() {\r\n return f_dependents;\r\n }", "@Override\n\tprotected void addDependencies() {\n\t\tSelectedParameter selectedParameter = (SelectedParameter) kernelType.getValue();\n\t\tSelectedParameterItem item = selectedParameter.getItems().get(selectedParameter.getSelectedIndex());\n\n\t\tif (linearKernel.equals(item)) {\n\t\t\taddDependency(\"linearKernel\");\n\t\t} else if (polynomialKernel.equals(item)) {\n\t\t\taddDependency(\"polynomialKernel\");\n\t\t} else if (radialBasisKernel.equals(item)) {\n\t\t\taddDependency(\"radialBasisKernel\");\n\t\t} else if (sigmoidKernel.equals(item)) {\n\t\t\taddDependency(\"sigmoidKernel\");\n\t\t}\n\t}", "public interface RuleRefableBase extends org.semanticwb.model.Referensable\r\n{\r\n /**\r\n * Referencia a un objeto de tipo Rule \r\n */\r\n public static final org.semanticwb.platform.SemanticClass swb_RuleRef=org.semanticwb.SWBPlatform.getSemanticMgr().getVocabulary().getSemanticClass(\"http://www.semanticwebbuilder.org/swb4/ontology#RuleRef\");\r\n public static final org.semanticwb.platform.SemanticProperty swb_hasRuleRef=org.semanticwb.SWBPlatform.getSemanticMgr().getVocabulary().getSemanticProperty(\"http://www.semanticwebbuilder.org/swb4/ontology#hasRuleRef\");\r\n public static final org.semanticwb.platform.SemanticProperty swb_notInheritRuleRef=org.semanticwb.SWBPlatform.getSemanticMgr().getVocabulary().getSemanticProperty(\"http://www.semanticwebbuilder.org/swb4/ontology#notInheritRuleRef\");\r\n public static final org.semanticwb.platform.SemanticProperty swb_andEvalRuleRef=org.semanticwb.SWBPlatform.getSemanticMgr().getVocabulary().getSemanticProperty(\"http://www.semanticwebbuilder.org/swb4/ontology#andEvalRuleRef\");\r\n /**\r\n * Interfaz que define propiedades para elementos que pueden referencia a reglas \r\n */\r\n public static final org.semanticwb.platform.SemanticClass swb_RuleRefable=org.semanticwb.SWBPlatform.getSemanticMgr().getVocabulary().getSemanticClass(\"http://www.semanticwebbuilder.org/swb4/ontology#RuleRefable\");\r\n\r\n public org.semanticwb.model.GenericIterator<org.semanticwb.model.RuleRef> listRuleRefs();\r\n public boolean hasRuleRef(org.semanticwb.model.RuleRef value);\r\n public org.semanticwb.model.GenericIterator<org.semanticwb.model.RuleRef> listInheritRuleRefs();\r\n\r\n /**\r\n * Adds the RuleRef\r\n * @param value An instance of org.semanticwb.model.RuleRef\r\n */\r\n public void addRuleRef(org.semanticwb.model.RuleRef value);\r\n\r\n /**\r\n * Remove all the values for the property RuleRef\r\n */\r\n public void removeAllRuleRef();\r\n\r\n /**\r\n * Remove a value from the property RuleRef\r\n * @param value An instance of org.semanticwb.model.RuleRef\r\n */\r\n public void removeRuleRef(org.semanticwb.model.RuleRef value);\r\n\r\n/**\r\n* Gets the RuleRef\r\n* @return a instance of org.semanticwb.model.RuleRef\r\n*/\r\n public org.semanticwb.model.RuleRef getRuleRef();\r\n\r\n public boolean isNotInheritRuleRef();\r\n\r\n public void setNotInheritRuleRef(boolean value);\r\n\r\n public boolean isAndEvalRuleRef();\r\n\r\n public void setAndEvalRuleRef(boolean value);\r\n}", "void visitElement_depends_on(org.w3c.dom.Element element) { // <depends-on>\n // element.getValue();\n org.w3c.dom.NodeList nodes = element.getChildNodes();\n for (int i = 0; i < nodes.getLength(); i++) {\n org.w3c.dom.Node node = nodes.item(i);\n switch (node.getNodeType()) {\n case org.w3c.dom.Node.CDATA_SECTION_NODE:\n // ((org.w3c.dom.CDATASection)node).getData();\n break;\n case org.w3c.dom.Node.ELEMENT_NODE:\n org.w3c.dom.Element nodeElement = (org.w3c.dom.Element)node;\n break;\n case org.w3c.dom.Node.PROCESSING_INSTRUCTION_NODE:\n // ((org.w3c.dom.ProcessingInstruction)node).getTarget();\n // ((org.w3c.dom.ProcessingInstruction)node).getData();\n break;\n case org.w3c.dom.Node.TEXT_NODE:\n issue.dependsOn.add(((org.w3c.dom.Text)node).getData());\n break;\n }\n }\n }" ]
[ "0.6550074", "0.6550074", "0.63520914", "0.59774417", "0.58898056", "0.5711006", "0.5687579", "0.5649769", "0.5593964", "0.5564458", "0.5521825", "0.55077326", "0.5457816", "0.5447459", "0.54307896", "0.54125696", "0.5402884", "0.53830606", "0.53828114", "0.5373583", "0.5346206", "0.53063446", "0.5291317", "0.5280727", "0.52797264", "0.52568936", "0.5229116", "0.52204186", "0.5201902", "0.5198997", "0.51985484", "0.5198281", "0.5194187", "0.518351", "0.51707155", "0.51676655", "0.5163069", "0.5162069", "0.51482195", "0.5146379", "0.51456016", "0.5142299", "0.51316833", "0.5120066", "0.5113001", "0.51111263", "0.5106902", "0.5097396", "0.5081737", "0.50751317", "0.5074685", "0.50743693", "0.5058102", "0.50542736", "0.5042459", "0.50366706", "0.5034044", "0.5032351", "0.5017197", "0.5015989", "0.50132155", "0.49914858", "0.4989981", "0.49691454", "0.4968981", "0.49603212", "0.4954949", "0.49393633", "0.4936828", "0.49364656", "0.49240854", "0.49171925", "0.4913789", "0.49131876", "0.49021658", "0.48858058", "0.48847765", "0.4878965", "0.48691738", "0.48599654", "0.4859177", "0.48478502", "0.4846172", "0.48452675", "0.4844807", "0.48333257", "0.48266518", "0.48202366", "0.48043504", "0.48019812", "0.48016903", "0.4798365", "0.47949135", "0.47914997", "0.47880134", "0.47795144", "0.4756179", "0.4749983", "0.4742389", "0.47360897" ]
0.81503993
0
This method is called by the Dependency Manager when the Dependable object should be updated. This method is called when the actual definition or dependencies of an object change. Expressions need to be rebuilt.
public void dependencyUpdateDef(Set updatingObjects);
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public interface Dependable {\n\n /**\n * This method is called by the Dependency Manager when the\n * Dependable object should be updated.\n * This method is called when the actual definition or dependencies of \n * an object change. Expressions need to be rebuilt.\n *\n * @param updatingObjects a set of all the objects that have been\n *\t\t\t or will be updated\n */\n public void dependencyUpdateDef(Set updatingObjects);\n\n /**\n * This method is called by the Dependency Manager when the\n * Dependable object should be updated.\n * This method is called when only a value changes, and the type\n * of the value does not change. An example of this kind of update\n * is when the value of a variable changes, but the definition of\n * it does not. Expressions do not have to be rebuilt.\n *\n * @param updatingObjects a set of all the objects that have been\n *\t\t\t or will be updated\n */\n public void dependencyUpdateVal(Set updatingObjects);\n\n /**\n * @return the depdenency graph node for this class\n */\n public DependencyNode dependencyNode();\n\n}", "protected void updateDynamic()\n {\n // Nothing at this level.\n }", "public void refreshDependencies() {\n\t\tremovePropertyChangeListener(this);\n\t\taddPropertyChangeListener(this);\n\t\tif(smoldynSimulationOptions != null) {\n\t\t\tsmoldynSimulationOptions.refreshDependencies();\n\t\t}\n\t\tif(nfsimSimulationOptions != null) {\n\t\t\tnfsimSimulationOptions.refreshDependencies();\n\t\t}\n\t\tif(langevinSimulationOptions != null) {\n\t\t\tlangevinSimulationOptions.refreshDependencies();\n\t\t}\n\t}", "public void dependencyUpdateVal(Set updatingObjects);", "public void willbeUpdated() {\n\t\t\n\t}", "@Override\n\t\t\tpublic void changedUpdate(DocumentEvent arg0) {\n\t\t\t}", "public abstract void modelStructureChanged();", "protected void indicateModified() {\n invalidationListenerManager.callListeners(this);\n }", "@Override\n\t\tpublic void update() {\n\n\t\t}", "@Override\n\t\tpublic void update() {\n\n\t\t}", "@Override\n\t\tpublic void update() {\n\n\t\t}", "@Override\n\tpublic void update() {\n\t\tobj.update();\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}", "public void update() {\n \t\t\t\t// XXX: workaround for https://bugs.eclipse.org/bugs/show_bug.cgi?id=206111\n \t\t\t\tif (fOperationCode == ITextOperationTarget.REDO)\n \t\t\t\t\treturn;\n \n \t\t\t\tboolean wasEnabled= isEnabled();\n \t\t\t\tboolean isEnabled= (fOperationTarget != null && fOperationTarget.canDoOperation(fOperationCode));\n \t\t\t\tsetEnabled(isEnabled);\n \n \t\t\t\tif (wasEnabled != isEnabled) {\n \t\t\t\t\tfirePropertyChange(ENABLED, wasEnabled ? Boolean.TRUE : Boolean.FALSE, isEnabled ? Boolean.TRUE : Boolean.FALSE);\n \t\t\t\t}\n \t\t\t}", "@Override\n\tpublic void changedUpdate(DocumentEvent de) {\n\n\t}", "ISChangePropagationDueToDataDependencies createISChangePropagationDueToDataDependencies();", "@Override\n\tpublic void update(UpdateVisitor visitor) {\n\t}", "@Override\r\n\tpublic void update(Object object) {\n\t\t\r\n\t}", "public void structuralChange();", "private void fireRebuildPerformedEvent() {\r\n final Vector listeners = getProjectChangedListeners();\r\n final Enumeration enumer = listeners.elements();\r\n while (enumer.hasMoreElements()) {\r\n final ProjectChangedListener listener = (ProjectChangedListener) enumer.\r\n nextElement();\r\n listener.rebuildPerformed(getProject());\r\n }\r\n }", "void rebuildIfNecessary();", "public void update(Observable o, Object d){\n\n\t\t System.out.println(name1 + \" was notified about a price change of \" + \n\t\t ((PriceChange)d).getProduct().getName() + \n\t\t \" at \" + ((PriceChange)d).getProduct().getStore() + \n\t\t \" to \"+ String.format(\"%.2f\", ((PriceChange)d).getProduct().getPrice()) + \".\");\n\n\t\t\n\t}", "@Override\r\n\tpublic void update() {\r\n\t}", "@Override\n\t\t\t\tpublic void ontologyModified(KIDSGUIOracle o){\n\t\t\t\t\tlogme.debug(String.format(\"Received ontology modified event; repopulating list for class %s\", ourClass));\n\t\t\t\t\trepopulateList(individualJListModel);\n\t\t\t\t}", "@Override\r\n\tpublic void update() {\n\t}", "@Override\r\n\tpublic void update() {\n\t}", "private void reafficher() {\n\t\tthis.setChanged();\n\t\tthis.notifyObservers();\n\t}", "@Override\r\n\t\tpublic void update() {\n\t\t\t\r\n\t\t}", "@Override\r\n\t\tpublic void update() {\n\t\t\t\r\n\t\t}", "protected void setDependencies() {\n\t\t\n\t}", "@Override\r\n\t\tpublic void update(Observable arg0, Object arg1) {\n\t\t}", "@Override\n public void rootRPClassUpdate(RPObject entity) {\n }", "@Override\n\tpublic void update() {\n\t}", "@Override\n\tpublic void update() {\n\t}", "@Override\n\tpublic void update() {\n\t}", "void onDemandUpdated(Vehicule demand);", "protected void notifyReferenceChanged(Object oldObject, Object newObject) {\n\t\t// Avoid spurious notifications\n\t\tif (oldObject == newObject)\n\t\t\treturn;\n\n\t\tSet<CFGChangeListener> invokedListeners = new HashSet<CFGChangeListener>(1000);\n\n\t\t// Get the wrapper for the old object. If we broadcast notifications, we\n\t\t// directly inform this object.\n\t\ttry {\n\t\t\tUpdatableWrapper<?> wrapper = this.wrappedObjects.get(oldObject);\n\t\t\tif (BROADCAST_NOTIFICATIONS && wrapper != null) {\n\t\t\t\twrapper.notifyReferenceChanged(oldObject, newObject);\n\t\t\t\tinvokedListeners.add(wrapper);\n\t\t\t}\n\t\t\n\t\t\t// Notify all explicitly registered object listeners\n\t\t\tSet<CFGChangeListener> objListeners = objectListeners.get(oldObject);\n\t\t\tif (objListeners != null) {\n\t\t\t\tfor (CFGChangeListener listener : objListeners) {\n\t\t\t\t\tif (listener != null && invokedListeners.add(listener))\n\t\t\t\t\t\tlistener.notifyReferenceChanged(oldObject, newObject);\n\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t// Make sure that we don't loose track of our listeners. Expired\n\t\t\t\t// listeners for gc'ed objects will automatically be removed by\n\t\t\t\t// the WeakHashMap.\n\t\t\t\tobjectListeners.put(newObject, objListeners);\n\t\t\t}\n\t\t\t\t\n\t\t\t// Notify the global listeners that have not yet been notified as\n\t\t\t// object listeners\n\t\t\tfor (CFGChangeListener listener : globalListeners)\n\t\t\t\tif (!invokedListeners.contains(listener))\n\t\t\t\t\tlistener.notifyReferenceChanged(oldObject, newObject);\n\t\t\t\n\t\t\t// We must also update our list of wrapped objects\n\t\t\tthis.wrappedObjects.put(newObject, wrapper);\n//\t\t\tthis.wrappedObjects.remove(oldObject);\n\t\t} catch (ExecutionException e) {\n\t\t\tSystem.err.println(\"Could not wrap object\");\n\t\t\te.printStackTrace();\n\t\t}\t\t\n\t}", "@Override\r\n\tpublic void update() {\r\n\r\n\t}", "@Override\r\n\tpublic void update() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void update() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void update() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void update() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void update() {\n\t\t\r\n\t}", "@Override\n\tpublic void update(Observable arg0, Object arg1) {\n\t\t\n\t}", "public void notifyChange()\r\n {\r\n setChanged();\r\n notifyObservers();\r\n }", "@Override\n\tpublic void update() {\n\n\t}", "@Override\n\tpublic void update() {\n\n\t}", "@Override\n\tpublic void update() {\n\n\t}", "@Override\n\tpublic void update() {\n\n\t}", "@Override\n\tpublic void update() {\n\n\t}", "@Override\n\tpublic void update() {\n\n\t}", "@Override\r\n\tpublic void update(Observable arg0, Object arg1) {\n\t\t\r\n\t}", "private void updatePlotDefinitionRef(final Object source, final PlotDefinition plotDefinition) {\n if (logger.isDebugEnabled()) {\n logger.debug(\"updatePlotDefinitionRef: plotDefinition: {}\", plotDefinition);\n }\n\n plotDefinition.incVersion();\n firePlotDefinitionChanged(source, plotDefinition.getId());\n\n // find dependencies:\n for (Plot plot : getPlotList()) {\n if (plot.getPlotDefinition() != null && plot.getPlotDefinition().getId().equals(plotDefinition.getId())) {\n // match\n plot.setPlotDefinition(plotDefinition);\n\n // update plot version and fire events (PlotChanged):\n updatePlotRef(source, plot);\n }\n }\n }", "public void markChanged()\n \t{\n \t\tbChanged=true;\n \t}", "@Override\n\tpublic void update(Observable o, Object arg) {\n\t\t\n\t}", "public void notifyChange(Object obj) {\n\t\t\ttry\n\t\t\t{\n\t\t\t\tsetChanged();\n\t\t\t\tnotifyObservers(obj);\n\t\t\t}\n\t\t\tcatch(Exception e)\n\t\t\t{\n\t\t\t}\n\t\t\t\n\t\t}", "@Override\r\n\tpublic void operations() {\n\t\tSystem.out.println(\"update self!\"); \r\n notifyObservers(); \r\n\r\n\t}", "@Override\n public void update(Observable arg0, Object arg1) {\n \n }", "@Override\n public void update(Observable o, Object arg) {\n setChanged();\n notifyObservers();\n }", "protected synchronized void setChanged() {\n changed = true;\n }", "@Override\n\tpublic void update() { }", "public void update() {\n\t}", "public void update() {\n\t}", "public void update() {\n\t}", "public void update() {\n\t}", "public void update(){\n\t\tSystem.out.println(\"Return From Observer Pattern: \\n\" + theModel.getObserverState() \n\t\t+ \"\\n\");\n\t}", "@Override\n public void update() {\n }", "@Override\n\tpublic void update(Object o) {\n\n\t}", "@Override\n\tpublic void update(Object o) {\n\n\t}", "public void makeUpdate()\n {\n this.mustUpdate = true;\n }", "public final synchronized void setChanged() {\n\t\tsuper.setChanged ();\n }", "protected void updateGeneratedExpressions() throws cbit.vcell.parser.ExpressionException, PropertyVetoException {\r\n\t\tKineticsParameter rateParm = getKineticsParameterFromRole(ROLE_ReactionRate);\r\n\t\tKineticsParameter currentParm = getKineticsParameterFromRole(ROLE_CurrentDensity);\r\n\t\tKineticsParameter bindingRadiusParam = getKineticsParameterFromRole(ROLE_Binding_Radius);\r\n\t\tKineticsParameter kOnParam = getKineticsParameterFromRole(ROLE_KOn);\r\n\t\tKineticsParameter diff_react1Param = getKineticsParameterFromRole(ROLE_Diffusion_Reactant1);\r\n\t\tKineticsParameter diff_react2Param = getKineticsParameterFromRole(ROLE_Diffusion_Reactant2);\r\n\t\tKineticsParameter conc_react1Param = getKineticsParameterFromRole(ROLE_Concentration_Reactant1);\r\n\t\tKineticsParameter conc_react2Param = getKineticsParameterFromRole(ROLE_Concentration_Reactant2);\r\n\t\t\r\n\t\tif (currentParm==null && rateParm==null){\r\n\t\t\treturn;\r\n\t\t}\r\n\t\t\r\n\t\t// rate prameter expr.\r\n\t\tReactionParticipant rp_Array[] = getReactionStep().getReactionParticipants();\r\n\t\tExpression kOn_exp = getSymbolExpression(kOnParam);\r\n\t\tExpression newRateExp = null;\r\n\t\tint reactantCount = 0;\r\n\t\tfor (int i = 0; i < rp_Array.length; i++) {\r\n\t\t\tExpression term = null;\r\n\t\t\tExpression speciesContext = getSymbolExpression(rp_Array[i].getSpeciesContext());\r\n\t\t\tint stoichiometry = rp_Array[i].getStoichiometry();\r\n\t\t\tif (rp_Array[i] instanceof Reactant){\r\n\t\t\t\treactantCount++;\r\n\t\t\t\tif (stoichiometry < 1){\r\n\t\t\t\t\tthrow new ExpressionException(\"reactant must have stoichiometry of at least 1\");\r\n\t\t\t\t}else if (stoichiometry == 1){\r\n\t\t\t\t\tterm = speciesContext;\r\n\t\t\t\t}else{\r\n\t\t\t\t\tterm = Expression.power(speciesContext,new Expression(stoichiometry));\r\n\t\t\t\t}\t\r\n\t\t\t\tkOn_exp = Expression.mult(kOn_exp,term);\t\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tif (reactantCount > 0){\r\n\t\t\tnewRateExp = kOn_exp;\r\n\t\t}else{\r\n\t\t\tnewRateExp = new Expression(0.0);\r\n\t\t}\r\n\t\trateParm.setExpression(newRateExp);\r\n\t\t\r\n\t\t// current Parameter. set to 0??\r\n\t\tcurrentParm.setExpression(new Expression(0.0));\r\n\t\t\r\n\t\t// binding radius, computed by Kon = 2*PI*D/Ln(b/R), b = 1/sqrt(Pa*PI)\r\n\t\tReservedSymbol pi_ReservedSymbol = getReactionStep().getModel().getPI_CONSTANT();\r\n\t\tExpression Pa = Expression.max(getSymbolExpression(conc_react1Param), getSymbolExpression(conc_react2Param));\r\n\t\tExpression sqrt_Pa_PI = Expression.sqrt(Expression.mult(Pa, getSymbolExpression(pi_ReservedSymbol))); //sqrt(Pa*PI)\r\n\t\tExpression b = Expression.div(new Expression(1), sqrt_Pa_PI); // 1/sqrt(Pa*PI)\r\n\t\tExpression sumD = Expression.add(getSymbolExpression(diff_react1Param), getSymbolExpression(diff_react2Param));\r\n\t\tExpression exp2_PI_D = Expression.mult(new Expression(2.0), getSymbolExpression(pi_ReservedSymbol), sumD); //2*PI*D\r\n\t\tExpression exponentNumExp = Expression.div(exp2_PI_D, getSymbolExpression(kOnParam)); // 2*PI*D/kon\r\n\t\tExpression exponentExp = Expression.exp(Expression.negate(exponentNumExp)); // exp(-2*PI*D/Kon)\r\n\t\tExpression radius = Expression.mult(b,exponentExp); // b*exp(-2*PI*D/Kon)\r\n\t\t\r\n\t\tif (bindingRadiusParam != null && radius != null) {\r\n\t\t\tbindingRadiusParam.setExpression(radius);\r\n\t\t} \r\n\t\t\t\r\n\t\t// SECONDARY CURRENT DENSITY\r\n\t\t// update from reaction rate\r\n\t\tupdateInwardCurrentDensityFromReactionRate();\r\n\t}", "@Override\r\n\tpublic void update(Observable o, Object arg) {\n\t\t\r\n\t}", "@Override\n public void update(Observable o, Object arg)\n {\n \n }", "@Override\r\n\tpublic void update(Observable o, Object arg) {\n\r\n\t}", "@Override\r\n\tpublic void update(Observable o, Object arg) {\n\r\n\t}", "@Override\n\t\tpublic void changedUpdate(DocumentEvent e) {\n\t\t\t\n\t\t}", "@Override\r\n\tpublic void update() {\n\t\tsuper.update();\r\n\t}", "@Override\r\n public void afterVisit() {\n final MethodCallUtils.EnclosingRefs enclosing = \r\n MethodCallUtils.getEnclosingInstanceReferences(\r\n thisExprBinder, expr,\r\n superClassDecl,\r\n context.theReceiverNode, getEnclosingSyntacticDecl());\r\n /* The transformer will already be set in the map correctly for these\r\n * effects when they are original generated. We are just modifying\r\n * the lock and evidence information for the effects.\r\n */\r\n for (final Effect e : newContext.theEffects.build()) {\r\n Effect maskedEffect = e.mask(thisExprBinder);\r\n if (maskedEffect != null) {\r\n // Mask again if the effect is on the receiver of the anonymous class\r\n if (maskedEffect.affectsReceiver(newContext.theReceiverNode)) {\r\n context.theEffects.add(\r\n Effect.effect(\r\n maskedEffect.getSource(), maskedEffect.isRead(),\r\n new EmptyTarget(new EmptyEvidence(Reason.UNDER_CONSTRUCTION)),\r\n new MaskedEffectEvidence(maskedEffect),\r\n maskedEffect.getNeededLocks()));\r\n } else {\r\n final Target target = maskedEffect.getTarget();\r\n \r\n final TargetEvidence te = target.getEvidence();\r\n if (te instanceof EmptyEvidence\r\n && ((EmptyEvidence) te).getReason() == Reason.METHOD_CALL) {\r\n /* Special case: empty effect that carries lock preconditions */\r\n final ImmutableSet.Builder<NeededLock> newLockSet = ImmutableSet.builder();\r\n for (final NeededLock lock : maskedEffect.getNeededLocks()) {\r\n newLockSet.add(lock.replaceEnclosingInstanceReference(enclosing));\r\n }\r\n context.theEffects.add(\r\n Effect.empty(maskedEffect.getSource(),\r\n new EmptyEvidence(Reason.METHOD_CALL), \r\n ImmutableSet.of(getEvidence()), newLockSet.build()));\r\n } else if (target instanceof InstanceTarget) {\r\n final IRNode ref = target.getReference();\r\n \r\n final IRNode newRef = enclosing.replace(ref);\r\n if (newRef != null) {\r\n final IRNode objectExpr = thisExprBinder.bindThisExpression(newRef);\r\n final Target newTarget = new InstanceTarget(\r\n objectExpr, target.getRegion(),\r\n new EnclosingRefEvidence(maskedEffect.getSource(), ref, newRef));\r\n final Set<NeededLock> newLocks = new HashSet<>();\r\n for (final NeededLock lock : maskedEffect.getNeededLocks()) {\r\n newLocks.add(lock.replaceEnclosingInstanceReference(enclosing));\r\n }\r\n elaborateInstanceTarget(\r\n context.bcaQuery, lockFactory, thisExprBinder, lockModel.get(),\r\n maskedEffect.getSource(), maskedEffect.isRead(), newTarget, getEvidence(),\r\n newLocks, context.theEffects);\r\n } else {\r\n /* XXX: Not sure if it is possible to get here. External\r\n * variable references are turned into ANyInstance targets\r\n * during elaboration.\r\n */\r\n /* 2012-08-24: We have to clean the type to make sure it is not a \r\n * type formal.\r\n */\r\n IJavaType type = thisExprBinder.getJavaType(ref);\r\n if (type instanceof IJavaTypeFormal) {\r\n type = TypeUtil.typeFormalToDeclaredClass(\r\n thisExprBinder.getTypeEnvironment(), (IJavaTypeFormal) type);\r\n }\r\n context.theEffects.add(Effect.effect(\r\n maskedEffect.getSource(), maskedEffect.isRead(),\r\n new AnyInstanceTarget(\r\n (IJavaReferenceType) type, target.getRegion(),\r\n new UnknownReferenceConversionEvidence(\r\n maskedEffect, ref, (IJavaReferenceType) type)),\r\n getEvidence(), maskedEffect.getNeededLocks()));\r\n }\r\n } else {\r\n context.theEffects.add(\r\n maskedEffect.updateEvidence(target.getEvidence(), ImmutableSet.of(getEvidence())));\r\n }\r\n }\r\n }\r\n }\r\n }", "@Override\r\n\tpublic void update() {\n\r\n\t}", "@Override\r\n\tpublic void update() {\n\r\n\t}", "public @Override void changedUpdate(DocumentEvent e, Shape a, ViewFactory f) {\n if (children == null && getParent() == null) {\n return;\n }\n \n super.changedUpdate(e, a, f);\n }", "@Override\n\tpublic void update() {}", "@Override\n\tpublic void update() {}", "@Override\r\n\t\t\tpublic void changedUpdate(DocumentEvent e) {\n\t\t\t}", "@Override\n\tprotected void runUpdate(IJavaElement element, ASTNode node){\n\t\tif((deviceType == null)||(!deviceType.exists())){\n\t\t\trebuild();\n\t\t\treturn;\n\t\t}\n\t\t\n\t\tif(element != null){\n\t\t\tif(element instanceof ICompilationUnit){\n\t\t\t\tICompilationUnit unit = (ICompilationUnit)element;\n\t\t\t\tif((deviceType != null)&&(deviceType.getCompilationUnit() != null)){\n\t\t\t\t\tif(ModelBuilderUtil.isSameCompilationUnit(unit, \n\t\t\t\t\t\t\tdeviceType.getCompilationUnit())){\n\t\t\t\t\t\tif(deviceField != null){\n\t\t\t\t\t\t\t//Use field, since children are still processed, \n\t\t\t\t\t\t\t//and keeps proper associations\n\t\t\t\t\t\t\tFRCRMechanism recMech = new FRCRMechanism(deviceField);\n\t\t\t\t\t\t\treconcile(recMech);\n\t\t\t\t\t\t\treturn;\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\tsuper.runUpdate(element, node);\n\t\t}\n\t}", "void onDependencyRelation( DependencyRelation relation );", "@Override\n\tpublic boolean update(Dynamic object) {\n\t\treturn false;\n\t}", "@Override\n\t\t\t\tpublic void changedUpdate(final DocumentEvent e) {\n\t\t\t\t}", "public void update(Observable o, Object arg) {\n\t\tfireStateChanged();\n\t}", "@Override\r\n protected void updateObject(SimpleBody object, Entity e) {\n }", "@Override\r\n protected void updateObject(SimpleBody object, Entity e) {\n }", "@Override\r\n public void changedUpdate(DocumentEvent e)\r\n {\n }", "@Override\n\t\t\t\tpublic void changedUpdate(DocumentEvent e) {\n\t\t\t\t\tchange();\n\t\t\t\t}", "public void stateChanged(ChangeEvent e){\n\r\n repaint(); // at the moment we're being pretty crude with this, redrawing all the shapes\r\n\r\n\r\n\r\n if (fDeriverDocument!=null) // if this drawing has a journal, set it for saving\r\n fDeriverDocument.setDirty(true);\r\n\r\n\r\n\r\n }", "@Override\n public void update (Observable o, Object arg) {\n }", "public synchronized void setChanged() {\n super.setChanged();\n }", "@Override\n\tpublic void update() {\n\t\t\n\t}", "@Override\n\tpublic void update() {\n\t\t\n\t}", "@Override\n\tpublic void update() {\n\t\t\n\t}" ]
[ "0.7164805", "0.5970791", "0.59399825", "0.57646143", "0.5552456", "0.5549488", "0.55294466", "0.5515471", "0.5498911", "0.5498911", "0.5498911", "0.5470631", "0.54438895", "0.54417163", "0.5436226", "0.54344827", "0.5429583", "0.5400867", "0.53500974", "0.533108", "0.53296816", "0.5323188", "0.5316376", "0.5285527", "0.5283639", "0.5283639", "0.5278336", "0.5275064", "0.5275064", "0.5269601", "0.5268454", "0.526075", "0.52595854", "0.52595854", "0.52595854", "0.5259099", "0.52589834", "0.5258935", "0.5256482", "0.5256482", "0.5256482", "0.5256482", "0.5256482", "0.52535343", "0.5253016", "0.52512026", "0.52512026", "0.52512026", "0.52512026", "0.52512026", "0.52512026", "0.52461123", "0.5228292", "0.5226356", "0.5225336", "0.5224421", "0.5219746", "0.52151275", "0.5212555", "0.52124816", "0.5205964", "0.5202148", "0.5202148", "0.5202148", "0.5202148", "0.51969033", "0.5196753", "0.51877946", "0.51877946", "0.5185996", "0.5183846", "0.5181438", "0.5180352", "0.5179562", "0.5171818", "0.5171818", "0.51712537", "0.5165684", "0.5165253", "0.51630545", "0.51630545", "0.5161145", "0.51499176", "0.51499176", "0.51491183", "0.51483375", "0.5147778", "0.5145525", "0.51425904", "0.5139323", "0.5136925", "0.5136925", "0.5136076", "0.51315016", "0.51284826", "0.5124436", "0.5123305", "0.5122802", "0.5122802", "0.5122802" ]
0.6298586
1
This method is called by the Dependency Manager when the Dependable object should be updated. This method is called when only a value changes, and the type of the value does not change. An example of this kind of update is when the value of a variable changes, but the definition of it does not. Expressions do not have to be rebuilt.
public void dependencyUpdateVal(Set updatingObjects);
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public interface Dependable {\n\n /**\n * This method is called by the Dependency Manager when the\n * Dependable object should be updated.\n * This method is called when the actual definition or dependencies of \n * an object change. Expressions need to be rebuilt.\n *\n * @param updatingObjects a set of all the objects that have been\n *\t\t\t or will be updated\n */\n public void dependencyUpdateDef(Set updatingObjects);\n\n /**\n * This method is called by the Dependency Manager when the\n * Dependable object should be updated.\n * This method is called when only a value changes, and the type\n * of the value does not change. An example of this kind of update\n * is when the value of a variable changes, but the definition of\n * it does not. Expressions do not have to be rebuilt.\n *\n * @param updatingObjects a set of all the objects that have been\n *\t\t\t or will be updated\n */\n public void dependencyUpdateVal(Set updatingObjects);\n\n /**\n * @return the depdenency graph node for this class\n */\n public DependencyNode dependencyNode();\n\n}", "void valueChanged(T oldValue, T newValue);", "void onVariableChanged(Object... newValue);", "void valueChanged(CalcModel model);", "void valueChanged(CalcModel model);", "private void fireValueChange(boolean b) {\n \t\n\t\t\n\t}", "public void dependencyUpdateDef(Set updatingObjects);", "public void willbeUpdated() {\n\t\t\n\t}", "@Override\n public void update(Observable o, Object arg) {\n setChanged();\n notifyObservers();\n }", "protected void updateDynamic()\n {\n // Nothing at this level.\n }", "@Override\r\n\t\tpublic void update(Observable arg0, Object arg1) {\n\t\t}", "public void update(Observable o, Object arg) \n\t{\n\t\tboolean previousOut = getValue();\n\t\t//use the class Boolean rather than primitive \n\t\t//so we can use null to check if there was a mistake\n\t\t//in this update being called later on\n\t\tBoolean newOut = null; \n\t\tBoolean inputVal = null;\n\t\t\n\t\t//the update comes from either an observable boolean\n\t\t//or another Neuron so figure out which one\n\n\t\tif (o instanceof InputBoolean)\n\t\t\tinputVal = ((InputBoolean)o).getValue();\n\t\telse if (o instanceof Connection)\n\t\t{\n\t\t\tConnection c = (Connection)o;\n\t\t\tif(c.isInhibitory() && c.sourceValue())\n\t\t\t{\n\t\t\t\t//this neuron is being inhibited\n\t\t\t\t//but we should only act if we were\n\t\t\t\t//not inhibited before \n\t\t\t\tif(_inhibited != true)\n\t\t\t\t{\n\t\t\t\t\t_inhibited = true;\n\t\t\t\t\tsetChanged();\n\t\t\t\t\tnotifyObservers();\n\t\t\t\t\tclearChanged();\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t}\n\t\t\telse \n\t\t\t\tinputVal = ((Connection)o).sourceValue();\n\t\t}\n\t\tif(inputVal != null)\n\t\t{\n\t\t\tif(inputVal)\n\t\t\t\t_curValue++;\n\t\t\telse\n\t\t\t\t_curValue--;\n\t\t}\n\t\t\n\t\t//alert downstream neurons and other observers\n\t\t//that they need to update themselves \n\t\tif(getValue() != previousOut)\n\t\t{\n\t\t\tsetChanged();\n\t\t\tnotifyObservers();\n\t\t\tclearChanged();\n\t\t}\n\t}", "private void changed() {\n // Ok to have a race here, see the field javadoc.\n if (!changed)\n changed = true;\n }", "@Override\n\tpublic void update(Observable o, Object arg) {\n\t\t\n\t}", "@Override\n public void update(Observable o, Object arg)\n {\n \n }", "@Override\n\tpublic void update(Observable arg0, Object arg1) {\n\t\t\n\t}", "@Override\n public void update(Observable arg0, Object arg1) {\n \n }", "void updateView(V child, View dependency) {\n float percent = 0;\n float start = 0;\n float current = 0;\n float end = UNSPECIFIED_INT;\n switch (mDependType) {\n case DEPEND_TYPE_WIDTH:\n start = mDependStartWidth;\n current = dependency.getWidth();\n end = mDependTarget;\n break;\n case DEPEND_TYPE_HEIGHT:\n start = mDependStartHeight;\n current = dependency.getHeight();\n end = mDependTarget;\n break;\n case DEPEND_TYPE_X:\n start = mDependStartX;\n current = dependency.getX();\n end = mDependTarget;\n break;\n case DEPEND_TYPE_Y:\n start = mDependStartY;\n current = dependency.getY();\n end = mDependTarget;\n break;\n }\n\n // need to define target value according to the depend type, if not then skip\n if (end != UNSPECIFIED_INT) {\n percent = Math.abs(current - start) / Math.abs(end - start);\n }\n updateViewWithPercent(child, percent > 1 ? 1 : percent);\n }", "@Override\r\n\tpublic void update(Observable arg0, Object arg1) {\n\t\t\r\n\t}", "public void allActualValuesUpdated ();", "public void isChanged()\n\t{\n\t\tchange = true;\n\t}", "@Override\r\n\tpublic void update(Observable o, Object arg) {\n\t\t\r\n\t}", "@Override\n public void update (Observable o, Object arg) {\n }", "@Override\n\t\tpublic void monitorChanged(MonitorEvent arg0) {\n\t\t\tDBR dbr = arg0.getDBR();\n\t\t\tif (dbr.isDOUBLE()) {\n\t\t\t\t// update the latest value\n\t\t\t\tdouble lastValue = latestValue;\n\t\t\t\tlatestValue = ((DBR_Double) dbr).getDoubleValue()[0];\n\n\t\t\t\t// if the percentage change has been great enough, then inform\n\t\t\t\t// IObservers\n\t\t\t\tif (Math.abs((lastValue - latestValue) / lastValue) * 100.0 >= sensitivity) {\n\t\t\t\t\tnotifyIObservers(this, latestValue);\n\t\t\t\t}\n\t\t\t}\n\t\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\r\n\tpublic void update(Observable o, Object arg) {\n\r\n\t}", "@Override\r\n\tpublic void update(Observable o, Object arg) {\n\r\n\t}", "@ConfigOperation\n @Order(50)\n protected void execChangedValue() throws ProcessingException {\n }", "@Override\n\tpublic void beforeVariableChanged(ProcessVariableChangedEvent arg0) {\n\n\t}", "@Override\n public void update(Observable o, Object arg) {\n }", "protected void boundObjectChanged(Object componentValue) {\r\n this.boundObjectChanged(true, componentValue);\r\n }", "public void onUpdate(T oldValue, T newValue);", "public void update(Observable o, Object d){\n\n\t\t System.out.println(name1 + \" was notified about a price change of \" + \n\t\t ((PriceChange)d).getProduct().getName() + \n\t\t \" at \" + ((PriceChange)d).getProduct().getStore() + \n\t\t \" to \"+ String.format(\"%.2f\", ((PriceChange)d).getProduct().getPrice()) + \".\");\n\n\t\t\n\t}", "public void update(Observable o, Object arg) {\n\t\tfireStateChanged();\n\t}", "public void variableChanged(VariableAttribute var);", "public void notifyObservers(int UPDATE_VALUE){\n\t\tfor(int i = 0; i < observerNodes.size();i++){\n\t\t\tNode currentNode = observerNodes.get(i);\n\t\t\tif(currentNode.filterType.filter(UPDATE_VALUE)) {\n\t\t\t\t\tcurrentNode.listen(UPDATE_VALUE);\n\t\t }\n\t\t}\n\t}", "public void valueForPathChanged(TreePath path, Object newValue) {\n\t}", "public void valueForPathChanged(TreePath path, Object newValue) {\n\t}", "@Override\n public void update(Observable o, Object arg) {\n\n }", "@Override\n\tpublic void update() {\n\t\tobj.update();\n\t}", "public abstract void update(Observable o, java.lang.Object arg);", "public void valueForPathChanged(TreePath path, Object newValue) {\n\n\t}", "protected abstract void sourceChanged(Change<? extends F> c);", "protected synchronized void setChanged() {\n changed = true;\n }", "public void notifyChange()\r\n {\r\n setChanged();\r\n notifyObservers();\r\n }", "@Override\n\tpublic void update(Object o) {\n\n\t}", "@Override\n\tpublic void update(Object o) {\n\n\t}", "@Override\n\t\tpublic void update() {\n\n\t\t}", "@Override\n\t\tpublic void update() {\n\n\t\t}", "@Override\n\t\tpublic void update() {\n\n\t\t}", "public void markChanged()\n \t{\n \t\tbChanged=true;\n \t}", "protected abstract void updateImpl(M newValue);", "@Override\r\n\tpublic void valuesChanged() {\r\n\t}", "public void update(Observable o, Object arg) {\n\t\t\r\n\t}", "void onChange( T newValue );", "@Override\n\tpublic void setChanged() {\n\t\tthis.changed = true;\n\t}", "public void update(){}", "public void update(){}", "public void update(Observable arg0, Object arg1) {\n\n\t}", "@Override\r\n\tpublic void update(Object object) {\n\t\t\r\n\t}", "public void valueChanged(ConfigurationIdentifier configurationIdentifier, Serializable value);", "void update(Type type);", "public void changed(ObservableValue ov, Number value, Number new_value)\n\t {\n\n\t String dsConexao = optionsConexao.get(new_value.intValue());\n\t conexao = dao.consultar(dsConexao);\n\t carregarEmpresas(consultas.listar(conexao));\n\t carregarConfigSuprii(conexao);\n\t }", "public void update(){\n \t//NOOP\n }", "public void makeUpdate()\n {\n this.mustUpdate = true;\n }", "public void dataChanged() {\n\t\tif (wijzigInfo)\n\t\t\twijzigInfo();\n\n\t\tsetChanged();\n\t\tnotifyObservers(\"dataChanged\");\n\t}", "@Override\n\tpublic void update() {}", "@Override\n\tpublic void update() {}", "public void fieldChanged(Field arg0, int arg1) {\n\t\t\n\t}", "public abstract void update(Object obj) ;", "public void valueChanged(IntegerStorageChange change);", "@Override\n public void update(Observable o, Object arg) {\n if (o == observable) {\n // System.out.println(\"To do list updated to: \" + observable.getList());\n notification = \"To do list updated to: \" + observable.getList();\n }\n }", "public void changeValue(ValueHolder newValue) {\r\n value = ((AttrObject) newValue).getValue();\r\n\tuserInfo = ((AttrObject) newValue).getUserInfo();\r\n\tnotifyFromAttr(); \r\n }", "@Override\n\tpublic void update() { }", "@Override\n\tprotected boolean configurationItemChanged(String itemName, VariableItem itemValue) {\n\t\tfinal VariableItem configurationVariable;\n\t\tif (Objects.isNull(configurationVariable = configurationVariableOf(itemName))) {\n\t\t\tlog.warn(\"No accessible variable '{}' in configuration.\", itemName);\n\t\t\treturn false;\n\t\t}\n\t\t// check for delay\n\t\tif (itemName.equals(delayName())) {\n\t\t\tdelay = itemValue.get(Integer.class).longValue();\n\t\t\tlog.debug(\"Changed variable 'delay' to {}\", delay);\n\t\t\tconfigurationVariable.set(delay);\n\t\t\treturn true;\n\t\t}\n\t\t// check for ignoredModules\n\t\tif (itemName.equals(ignoreModulesName())) {\n\t\t\tignoredModules = itemValue.get(String.class).split(\",\");\n\t\t\tlog.debug(\"Changed variable 'ignoredModules' to {}\", Arrays.asList(ignoredModules));\n\t\t\tconfigurationVariable.set(String.join(\",\", ignoredModules));\n\t\t\treturn true;\n\t\t}\n\t\treturn false;\n\t}", "@Override\r\n\tpublic void update() {\r\n\t}", "@Override\n public void update(Observable o, Object arg) {\n this.currentSelectedEntity = EntityObserver.selected;\n manageComponentVisibility();\n \n if (objectPanel.isVisible()) {\n setType();\n setPosition();\n setEntityDampening();\n setEntityReflection();\n setEntityRotation();\n \n if (colorPanel.isVisible()) {\n manageLights(EntityObserver.selected);\n }\n }\n }", "@DISPID(-2147412091)\n @PropPut\n void onbeforeupdate(\n java.lang.Object rhs);", "@Override\n\t\t\tpublic void changedUpdate(DocumentEvent arg0) {\n\t\t\t}", "void onDemandUpdated(Vehicule demand);", "public void notifyAlgoUpdateCurrentValue() {\n this.mHwGradualBrightnessAlgo.updateTargetAndRate(this.mTargetValue, this.mRate);\n this.mHwGradualBrightnessAlgo.updateCurrentBrightnessValue((float) this.mCurrentValue);\n }", "@Override\n\tpublic void update() {\n\t}", "@Override\n\tpublic void update() {\n\t}", "@Override\n\tpublic void update() {\n\t}", "private void notifyUpdated() {\n if (mChanged) {\n mChanged = false;\n mObserver.onChanged(this);\n }\n }", "public void changed(cz.ive.messaging.Hook initiator) {\r\n value.value = FuzzyValueHolder.True;\r\n hook.unregisterListener(this);\r\n notifyListeners();\r\n }", "@DISPID(-2147412090)\n @PropPut\n void onafterupdate(\n java.lang.Object rhs);", "@Override\r\n\tpublic void update() {\n\t}", "@Override\r\n\tpublic void update() {\n\t}", "@Override\n\tpublic boolean update(Dynamic object) {\n\t\treturn false;\n\t}", "@DISPID(12)\n\t// = 0xc. The runtime will prefer the VTID if present\n\t@VTID(22)\n\tvoid updated(boolean pVal);", "protected abstract void update();", "protected abstract void update();", "@Override\n\tpublic void update(float[] val) {\n\t\t\n\t}", "@Override\r\n\tpublic void update(Observable arg0, Object arg1) {\n\t\trepaint();\r\n\t}", "@Override\r\n\tpublic void update() {\r\n\r\n\t}", "public void update(Observable o, Object arg) {\n if (o == model) {\n setChanged();\n notifyObservers(arg);\n }\n }", "void update(Object source, Object reason, T arg);", "@Override\n\tpublic void update() {\n\n\t}", "@Override\n\tpublic void update() {\n\n\t}" ]
[ "0.69306296", "0.64610606", "0.6232627", "0.61896527", "0.61896527", "0.6001236", "0.59069794", "0.59000427", "0.58397526", "0.5833095", "0.5832212", "0.5831307", "0.5826202", "0.58246213", "0.5810435", "0.58096486", "0.58070344", "0.5802906", "0.5802057", "0.5779358", "0.57788324", "0.5776766", "0.5743863", "0.57401156", "0.5718818", "0.5706304", "0.5706304", "0.57011974", "0.56863886", "0.5674328", "0.56697285", "0.5647137", "0.5630353", "0.562954", "0.561184", "0.5606382", "0.5603557", "0.5603557", "0.5578575", "0.5576735", "0.5572496", "0.5567193", "0.55628234", "0.55613905", "0.554678", "0.55456686", "0.55456686", "0.554454", "0.554454", "0.554454", "0.5542264", "0.55421704", "0.55392593", "0.5535321", "0.5529273", "0.55210286", "0.552066", "0.552066", "0.5508476", "0.5508381", "0.54726136", "0.54520655", "0.54498035", "0.5443604", "0.54407793", "0.5437332", "0.5433814", "0.5433814", "0.54332244", "0.5431849", "0.5430285", "0.5421762", "0.5416719", "0.5407977", "0.54064196", "0.54062617", "0.5390663", "0.5375428", "0.5374898", "0.536963", "0.5366946", "0.5365325", "0.5365325", "0.5365325", "0.5363166", "0.53624225", "0.5357103", "0.53569865", "0.53569865", "0.5356928", "0.5354232", "0.5350103", "0.5350103", "0.53462034", "0.5344074", "0.53425497", "0.534002", "0.5336969", "0.5331267", "0.5331267" ]
0.66394407
1
m_grabberHand = new DoubleSolenoid(RobotMap.pmc1CanID(), RobotMap.GrabberSolenoidForward(), RobotMap.GrabberSolenoidReverse()); m_grabberHand.set(DoubleSolenoid.Value.kOff);
@Override public void initDefaultCommand() { }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void initShoulder(){\r\n do{\r\n int currentShoulderPosition = motorShoulder.getCurrentPosition();\r\n posShoulder = currentShoulderPosition + DELTA_SHOULDER;\r\n motorShoulder.setTargetPosition(posShoulder);\r\n motorShoulder.setPower(POWER_SHOULDER_SLOW);\r\n\r\n //System.out.println(\"posShoulder = \" + posShoulder);\r\n } while(!sensorShoulder.isPressed());\r\n\r\n motorShoulder.setPower(STOP);\r\n resetShoulderEncoder();\r\n posShoulder = 0;\r\n }", "public CurrentRobotState() {\r\n currentPos = new RobotCoordinates();\r\n motorState = new Motor();\r\n reInitialize();\r\n }", "protected void initialize() {\n \tRobot.hand.setWrist(moveValue);\n }", "public void liftArm(){armLifty.set(-drivePad.getThrottle());}", "@Override\n public void robotInit() {\n m_oi = new OI();\n m_chooser.setDefaultOption(\"Default Auto\", new ExampleCommand());\n // chooser.addOption(\"My Auto\", new MyAutoCommand());\n SmartDashboard.putData(\"Auto mode\", m_chooser);\n\n Comp = new Compressor();\n\n //ClimbBack = new DoubleSolenoid(PCM_COMP_24V, 0, 1);\n //ClimbFront = new DoubleSolenoid(PCM_COMP_24V, 2, 3);\n LegFrontL = new VictorSPX(30);\n LegFrontR = new Spark(9);\n LegBackL = new VictorSPX(31);\n LegBackR = new VictorSPX(32);\n\n BackFootMover = new VictorSP(1);\n FrontFootMover = new Spark(2);\n //FeetMovers = new SpeedControllerGroup(BackFootMoverFootMover);\n\n MainRight = new CANSparkMax(9, MotorType.kBrushless);\n AltRight = new CANSparkMax(10, MotorType.kBrushless);\n MainLeft = new CANSparkMax(11, MotorType.kBrushless);\n AltLeft = new CANSparkMax(12, MotorType.kBrushless);\n\n MainRight.setIdleMode(IdleMode.kCoast);\n AltRight.setIdleMode(IdleMode.kCoast);\n MainLeft.setIdleMode(IdleMode.kCoast);\n AltLeft.setIdleMode(IdleMode.kCoast);\n\n AltLeft.follow(MainLeft);\n AltRight.follow(MainRight);\n\n Drive = new DifferentialDrive(MainLeft, MainRight);\n\n Lifter = new TalonSRX(6);\n Lifter.setNeutralMode(NeutralMode.Brake);\n Lifter.enableCurrentLimit(false);\n /*Lifter.configContinuousCurrentLimit(40);\n Lifter.configPeakCurrentLimit(50);\n Lifter.configPeakCurrentDuration(1500);*/\n //Lifter.configReverseSoftLimitEnable(true);\n //Lifter.configReverseSoftLimitThreshold(-27000);\n //Lifter.configForwardLimitSwitchSource(LimitSwitchSource.FeedbackConnector, LimitSwitchNormal.NormallyOpen);\n //Lifter.configClearPositionOnLimitF(true, 0);\n Lifter.selectProfileSlot(0, 0);\n LiftSetpoint = 0;\n\n LiftFollower = new TalonSRX(5);\n LiftFollower.follow(Lifter);\n LiftFollower.setNeutralMode(NeutralMode.Brake);\n\n ArmExtender = new Solenoid(0);\n ArmOpener = new Solenoid(1);\n ArmGrippers = new Spark(0);\n\n HatchSwitch0 = new DigitalInput(0);\n HatchSwitch1 = new DigitalInput(1);\n\n Accel = new BuiltInAccelerometer(Range.k2G);\n\n //Diagnostics = new DiagnosticsLogger();\n // Uncomment this line to enable diagnostics. Warning: this may\n // cause the robot to be slower than it is supposed to be because of lag.\n //Diagnostics.start();\n\n xbox = new XboxController(0);\n joystick = new Joystick(1);\n \n LiftRamp = new SRamp();\n SpeedRamp = new SRamp();\n\n NetworkTableInstance nt = NetworkTableInstance.getDefault();\n\n VisionTable = nt.getTable(\"ChickenVision\");\n TapeDetectedEntry = VisionTable.getEntry(\"tapeDetected\");\n TapePitchEntry = VisionTable.getEntry(\"tapePitch\");\n TapeYawEntry = VisionTable.getEntry(\"tapeYaw\");\n\n LedTable = nt.getTable(\"LedInfo\");\n LedScript = LedTable.getEntry(\"CurrentScript\");\n LedScriptArgument = LedTable.getEntry(\"ScriptArgument\");\n LedArmsClosed = LedTable.getEntry(\"ArmsClosed\");\n\n UsbCamera cam = CameraServer.getInstance().startAutomaticCapture();\n cam.setPixelFormat(PixelFormat.kMJPEG);\n cam.setResolution(320, 240);\n cam.setFPS(15);\n \n\n LedScript.setString(\"ColorWaves\");\n LedScriptArgument.setString(\"\");\n\n limits = new DigitalInput[8];\n\n for (int i = 0; i < limits.length; i++) {\n limits[i] = new DigitalInput(i + 2);\n }\n }", "public OI() {\n\n pilotLS.whenPressed(new ShiftGear(Gear.HIGH));\n pilotLS.whenReleased(new ShiftGear(Gear.OFF));\n pilotRS.whenPressed(new ShiftGear(Gear.LOW));\n pilotRS.whenPressed(new ShiftGear(Gear.OFF));\n\n pilotRTrig.whileActive(new CenterBay());\n\n pilotA.whenPressed(new TrackPipeline(Pipeline.OFF));\n pilotB.whenPressed(new FlipLimelight());\n //pilotY.whenPressed(new FollowPath(Path.TO_PERPENDICULAR, false));\n pilotY.whenPressed(new PlayTrajectory(\"Test\"));\n\n pilotDpadNorth.whileHeld(new ManualClimb(1.0));\n pilotDpadSouth.whileHeld(new ManualClimb(-1.0));\n\n pilotDpadEast.whileHeld(new ClimbSequence());\n pilotDpadWest.whenPressed(new PassThrough());\n\n pilotBack.whenPressed(new KillAll());\n copilotBack.whenPressed(new KillAll());\n\n copilotA.whileHeld(new SpinIntake(1.0));\n copilotA.whenReleased(new SpinIntake(0));\n copilotB.whileHeld(new SpinIntake(-1.0));\n copilotB.whenReleased(new SpinIntake(0));\n\n copilotY.whenPressed(new FireHatch(Value.kForward));\n copilotY.whenReleased(new FireHatch(Value.kOff));\n copilotX.whenPressed(new FireHatch(Value.kReverse));\n copilotX.whenReleased(new FireHatch(Value.kOff));\n\n copilotLb.whileHeld(new WristEndGame());\n copilotLb.whenReleased(new SpinIntake(0));\n\n rbGround.whenPressed(new ToHeight(Height.HOME));\n rbHatchLow.whenPressed(new ToHeight(Height.HATCH_LOW));\n rbHatchMid.whenPressed(new ToHeight(Height.HATCH_MID));\n rbHatchHigh.whenPressed(new ToHeight(Height.HATCH_HIGH));\n rbCargoLow.whenPressed(new ToHeight(Height.CARGO_LOW));\n rbCargoMid.whenPressed(new ToHeight(Height.CARGO_MID));\n rbCargoHigh.whenPressed(new ToHeight(Height.CARGO_HIGH));\n\n copilotDpadNorth.whenPressed(new ToHeight(Height.CARGO_LOAD));\n copilotDpadSouth.whenPressed(new ToHeight(Height.CARGO_FLOOR));\n copilotDpadEast.whenPressed(new ToHeight(Height.CARGO_SHIP));\n copilotDpadWest.whenPressed(new ToHeight(Height.HATCH_LOW));\n\n }", "@Override \n public void init() {\n intakeLeft = hardwareMap.crservo.get(\"intakeLeft\");\n intakeRight = hardwareMap.crservo.get(\"intakeRight\");\n topLeft = hardwareMap.servo.get(\"topLeft\");\n bottomLeft = hardwareMap.servo.get(\"bottomRight\");\n topRight = hardwareMap.servo.get(\"topRight\");\n bottomRight = hardwareMap.servo.get(\"bottomRight\");\n lift = hardwareMap.dcMotor.get(\"lift\");\n }", "public OI(){\n driveStick = new Joystick(RobotMap.DRIVE_STICK);\n armStick = new Joystick(RobotMap.ARM_STICK);\n assoc(); \n }", "@Override\n\tpublic void robotInit() {\n\t\toi = new OI();\n\t\t\n\t\t// chooser.addObject(\"My Auto\", new MyAutoCommand());\n\t\tSmartDashboard.putData(\"Auto mode\", chooser);\n\t\tSystem.out.println(\"I am here\");\n\t\ttopRight = new CANTalon(1);\n\t\tmiddleRight = new CANTalon(3);\n\t\tbottomRight = new CANTalon(2);\n\t\ttopLeft = new CANTalon(5);\n\t\tmiddleLeft = new CANTalon(6);\n\t\tbottomLeft = new CANTalon(7);\n\t\tclimber = new CANTalon(4);\n\t\tshifter = new DoubleSolenoid(2,3);\n\t\tshifter.set(Value.kForward);\n\t\tbucket= new DoubleSolenoid(0, 1);\n\t\tclimber.reverseOutput(true);\n\t\t//Setting Followers\n\t\t//topRight is Right Side Master (TalonSRX #1)0.062, 0.00062, 0.62)\n\t\t//middleRight.reset();\n//\t\tmiddleRight.setProfile(0);\n//\t\tmiddleRight.setPID( 0.0, 0.0, 0.0);//TODO: make multiple profiles\n\t\t\n//\t\tmiddleRight.setFeedbackDevice(FeedbackDevice.CtreMagEncoder_Absolute);\n//\t\tmiddleRight.setEncPosition(0);\n//\t\tmiddleRight.setAllowableClosedLoopErr(10);\n\t\tmiddleRight.reverseSensor(true);\n//\t\tmiddleRight.configNominalOutputVoltage(+0f, -0f);\n//\t\tmiddleRight.configPeakOutputVoltage(+12f, -12f);\n\t\ttopRight.changeControlMode(TalonControlMode.Follower);\n\t\ttopRight.set(middleRight.getDeviceID());\n\t\ttopRight.reverseOutput(true);\n\t\tbottomRight.changeControlMode(TalonControlMode.Follower); //TalonSRX #3\n\t\tbottomRight.set(middleRight.getDeviceID());\n//\t\tmiddleRight.setProfile(1);\n//\t\tmiddleRight.setPID( 0.0, 0.0, 0.0);\n\t\t//climber is the climber Motor (TalonSRX #4)\n\t\t//TopLeft is Right Side Master (TalonSRX #5)\n\t\t//middleLeft.reset();\n\t\t//middleLeft.setProfile(0);\n//\t\tmiddleLeft.setPID(0.0, 0.00, 0.0);\n//\t\tmiddleLeft.setEncPosition(0);\n//\t\tmiddleLeft.setFeedbackDevice(FeedbackDevice.CtreMagEncoder_Absolute);\n//\t\tmiddleLeft.configNominalOutputVoltage(+0f, -0f);\n//\t\tmiddleLeft.configPeakOutputVoltage(+12f, -12f);\n\t\tmiddleLeft.reverseSensor(false);\n//\t\tmiddleLeft.setAllowableClosedLoopErr(10);\n\t\ttopLeft.changeControlMode(TalonControlMode.Follower); //TalonSRX #6\n\t\ttopLeft.set(middleLeft.getDeviceID());\n\t\ttopLeft.reverseOutput(true);\n\t\tbottomLeft.changeControlMode(TalonControlMode.Follower); //TalonSRX #7\n\t\tbottomLeft.set(middleLeft.getDeviceID());\n//\t\tmiddleLeft.setProfile(1);\n//\t\tmiddleLeft.setPID(0, 0, 0);\n\t\t//Sensors\n\t\timu = new ADIS16448IMU();\n\t\tclimberSubsystem = new ClimberSubsystem();\n\t\tbucketSubsystem = new BucketSubsystem();\n\t\tdriveSubsystem = new DriveSubsystem();\n\t}", "protected void initialize() {\n \tif (Robot.shifters.getGear() == Shifters.Gear.HIGH) {\n \tRobot.shifters.shift(Shifters.Gear.LOW);\n \t} else {\n \tRobot.shifters.shift(Shifters.Gear.HIGH);\n \t}\n }", "protected void initialize() {\n \tRobot.gearIntake.setIsDown(true);\n }", "public void setSensorOff() {\n\n }", "public Drivetrain(){\r\n LeftSlave.follow(LeftMaster);\r\n RightSlave.follow(RightMaster);\r\n\r\n RightMaster.setInverted(true);\r\n LeftMaster.setInverted(true);\r\n\r\n gyro.reset();\r\n}", "public void turnLightsOff()\n {\n set(Relay.Value.kOff);\n }", "private boolean poleSwitchEngaged(){\n return true; //poleSwitch.get();\n }", "public static void init() {\n driveLeft = new VictorSP(1);\r\n LiveWindow.addActuator(\"Drive\", \"Left\", (VictorSP) driveLeft);\r\n \r\n driveRight = new VictorSP(0);\r\n LiveWindow.addActuator(\"Drive\", \"Right\", (VictorSP) driveRight);\r\n \r\n driveMotors = new RobotDrive(driveLeft, driveRight);\r\n \r\n driveMotors.setSafetyEnabled(false);\r\n driveMotors.setExpiration(0.1);\r\n driveMotors.setSensitivity(0.5);\r\n driveMotors.setMaxOutput(1.0);\r\n\r\n driveEncoderLeft = new Encoder(0, 1, true, EncodingType.k1X);\r\n LiveWindow.addSensor(\"Drive\", \"EncoderLeft\", driveEncoderLeft);\r\n driveEncoderLeft.setDistancePerPulse(0.053855829);\r\n driveEncoderLeft.setPIDSourceType(PIDSourceType.kRate);\r\n driveEncoderRight = new Encoder(2, 3, false, EncodingType.k1X);\r\n LiveWindow.addSensor(\"Drive\", \"EncoderRight\", driveEncoderRight);\r\n driveEncoderRight.setDistancePerPulse(0.053855829);\r\n driveEncoderRight.setPIDSourceType(PIDSourceType.kRate);\r\n driveFrontSonar = new Ultrasonic(4, 5);\r\n LiveWindow.addSensor(\"Drive\", \"FrontSonar\", driveFrontSonar);\r\n \r\n shooterMotor = new VictorSP(3);\r\n LiveWindow.addActuator(\"Shooter\", \"Motor\", (VictorSP) shooterMotor);\r\n \r\n climberMotor = new Spark(2);\r\n LiveWindow.addActuator(\"Climber\", \"Motor\", (Spark) climberMotor);\r\n \r\n gearGrabReleaseSolonoid = new DoubleSolenoid(0, 0, 1);\r\n LiveWindow.addActuator(\"Gear\", \"GrabReleaseSolonoid\", gearGrabReleaseSolonoid);\r\n \r\n powerPanel = new PowerDistributionPanel(0);\r\n LiveWindow.addSensor(\"Power\", \"Panel\", powerPanel);\r\n \r\n cameraMountpan = new Servo(4);\r\n LiveWindow.addActuator(\"CameraMount\", \"pan\", cameraMountpan);\r\n \r\n cameraMounttilt = new Servo(5);\r\n LiveWindow.addActuator(\"CameraMount\", \"tilt\", cameraMounttilt);\r\n \r\n\r\n // END AUTOGENERATED CODE, SOURCE=ROBOTBUILDER ID=CONSTRUCTORS\r\n\t\tdriveSonarFront = new SonarMB1010(0);\r\n\t\tLiveWindow.addSensor(\"Drive\", \"SonarFront\", driveSonarFront);\r\n\r\n\t\t//driveGyro = new GyroADXRS453();\r\n\t\tdriveGyro = new ADXRS450_Gyro();\r\n\t\tLiveWindow.addSensor(\"Drive\", \"Gyro\", driveGyro);\r\n\t\tdriveGyro.calibrate();\r\n\t}", "void setHand(Hand hand) {\n\t\t_hand = hand;\n\t}", "protected void initialize() {\n \t starttime = Timer.getFPGATimestamp();\n \tthis.startAngle = RobotMap.navx.getAngle();\n \tangleorientation.setSetPoint(RobotMap.navx.getAngle());\n \t\n \tRobotMap.motorLeftTwo.enableControl();\n \tRobotMap.motorRightTwo.enableControl();\n \tRobotMap.motorLeftTwo.enableControl();\n \tRobotMap.motorRightTwo.enableControl();\n \n //settting talon control mode\n \tRobotMap.motorLeftTwo.changeControlMode(TalonControlMode.MotionMagic);\t\t\n\t\tRobotMap.motorLeftOne.changeControlMode(TalonControlMode.Follower);\t\n\t\tRobotMap.motorRightTwo.changeControlMode(TalonControlMode.MotionMagic);\t\n\t\tRobotMap.motorRightOne.changeControlMode(TalonControlMode.Follower);\n\t\t//setting peak and nominal output voltage for the motors\n\t\tRobotMap.motorLeftTwo.configPeakOutputVoltage(+12.0f, -12.0f);\n\t\tRobotMap.motorLeftTwo.configNominalOutputVoltage(0.00f, 0.0f);\n\t\tRobotMap.motorRightTwo.configPeakOutputVoltage(+12.0f, -12.0f);\n\t\tRobotMap.motorRightTwo.configNominalOutputVoltage(0.0f, 0.0f);\n\t\t//setting who is following whom\n\t\tRobotMap.motorLeftOne.set(4);\n\t\tRobotMap.motorRightOne.set(3);\n\t\t//setting pid value for both sides\n\t//\tRobotMap.motorLeftTwo.setCloseLoopRampRate(1);\n\t\tRobotMap.motorLeftTwo.setProfile(0);\n\t RobotMap.motorLeftTwo.setP(0.000014f);\n \tRobotMap.motorLeftTwo.setI(0.00000001);\n\t\tRobotMap.motorLeftTwo.setIZone(0);//325);\n\t\tRobotMap.motorLeftTwo.setD(1.0f);\n\t\tRobotMap.motorLeftTwo.setF(this.fGainLeft+0.014);//0.3625884);\n\t\tRobotMap.motorLeftTwo.setAllowableClosedLoopErr(0);//300);\n\t\t\n\t RobotMap.motorRightTwo.setCloseLoopRampRate(1);\n\t RobotMap.motorRightTwo.setProfile(0);\n\t\tRobotMap.motorRightTwo.setP(0.000014f);\n\t\tRobotMap.motorRightTwo.setI(0.00000001);\n\t\tRobotMap.motorRightTwo.setIZone(0);//325);\n\t\tRobotMap.motorRightTwo.setD(1.0f);\n\t\tRobotMap.motorRightTwo.setF(this.fGainRight);// 0.3373206);\n\t\tRobotMap.motorRightTwo.setAllowableClosedLoopErr(0);//300);\n\t\t\n\t\t//setting Acceleration and velocity for the left\n\t\tRobotMap.motorLeftTwo.setMotionMagicAcceleration(125);\n\t\tRobotMap.motorLeftTwo.setMotionMagicCruiseVelocity(250);\n\t\t//setting Acceleration and velocity for the right\n\t\tRobotMap.motorRightTwo.setMotionMagicAcceleration(125);\n\t\tRobotMap.motorRightTwo.setMotionMagicCruiseVelocity(250);\n\t\t//resets encoder position to 0\t\t\n\t\tRobotMap.motorLeftTwo.setEncPosition(0);\n\t\tRobotMap.motorRightTwo.setEncPosition(0);\n\t //Set Allowable error for the loop\n\t\tRobotMap.motorLeftTwo.setAllowableClosedLoopErr(300);\n\t\tRobotMap.motorRightTwo.setAllowableClosedLoopErr(300);\n\t\t\n\t\t//sets desired endpoint for the motors\n RobotMap.motorLeftTwo.set(motionMagicEndPoint);\n RobotMap.motorRightTwo.set(-motionMagicEndPoint );\n \t\n }", "@Override\n public void execute() {\n //How does one pass the joystick value here? There has to be a better way.\n driveTrainSubsystem.drive(1.0);\n\n\n //control pneumatics\n DoubleSolenoid doubleSolenoid = new DoubleSolenoid(1, 2);\n\n for(int i =0; i < 30000; i++) {\n doubleSolenoid.set(Value.kForward);\n System.out.println(\"Solenoid forward\");\n }\n\n for(int i =0; i < 30000; i++) {\n doubleSolenoid.set(Value.kReverse);\n System.out.println(\"Solenoid backward\");\n }\n\n\n System.out.println(\"Solenoid off\");\n doubleSolenoid.set(Value.kReverse);\n\n }", "public Hand(){}", "@Override\n\tpublic void robotInit() {\n\t\toi = new OI();\n\t\tdrivebase.calibrateGyro();\n\t\tSmartDashboard.putData(\"Zero Gyro\", new ZeroGyro());\n\t\tSmartDashboard.putData(\"Calibrate Gyro - WHILE ROBOT NOT MOVING\", new CalibrateGyro());\n\t\tchooser.addDefault(\"Default Prepare Gear Auto\", new PrepareGearManipulator());\n\t\t//shooterModeChooser.addDefault(\"Shooter at Nominal Preset when Pressed\", object);\n\t\t/*chooser.addObject(\"Left Gear Auto\", new LeftGearGroup());\n\t\tchooser.addObject(\"Center Gear Auto\", new CenterGearGroup());*/\n\t//\tchooser.addObject(\"Test Vision Auto\", new TurnTillPerpVision(true));\n\t//\tchooser.addObject(\"Testing turn gyro\", new RotateToGyroAngle(90,4));\n\t\t//chooser.addObject(\"DriveStraightTest\", new GoAndReturn());\n\t\t //UNNECESSARY AUTOS FOR TESTING ^\n\t\tchooser.addObject(\"Center Gear Encoder Auto (place)\", new DriveStraightCenter());\n\t\tchooser.addObject(\"Vision center TESTING!!!\", new TurnTillPerpVision());\n\t\tchooser.addObject(\"Boiler Auto RED\", new BoilerAuto(true));\n\t\tchooser.addObject(\"Boiler Auto BLUE\", new BoilerAuto(false));\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\n\t//\tchooser.addObject(\"Center Gear Encoder Auto (do not place )\", new DriveToFace(false, false, false));\n\t\tchooser.addObject(\"Baseline\", new DriveToLeftRightFace(false,false,false,false));\n\t\tchooser.addObject(\"TEST DRIVETANK AUTO\", new DriveTimedTank(0.7,0.7,5));\n\t\tchooser.addObject(\"Side Gear Auto RIGHT (manual straight lineup)(place)(TURN AFTER AND START CYCLE)\", new DriveStraightSide(true,false));\n\n\t\tchooser.addObject(\"Side Gear Auto LEFT (manual straight lineup)(place)(TURN AFTER AND START CYCLE)\", new DriveStraightSide(true,true));\n\t\t//chooser.addObject(\"Side Gear Auto (place)\", new DriveToLeftRightFace(true,false,false,false));\n\t\t//chooser.addObject(\"Test DriveStraight Auto\", new DriveStraightPosition(10,5));\n\t\t//chooser.addObject(\"Center Gear Encoder Auto (place)\", new DriveStraightCenter());\n\t\t/*InterpreterGroup interp = new InterpreterGroup();\n\t\t(interp.init()){\n\t\t\tchooser.addObject(\"Interpreter\",interp);\n\t\t}*/\n\t\t// chooser.addObject(\"My Auto\", new MyAutoCommand());\n\t\tSmartDashboard.putData(\"Auto Chooser\", chooser);\n\n\t\tRobot.drivebase.leftDrive1.setPosition(0);\n \tRobot.drivebase.rightDrive1.setPosition(0);\n \t\n\t\t\n \tRobot.leds.initializei2cBus();\n \tbyte mode = 0;\n \tRobot.leds.setMode(mode);\n \tgearcamera = CameraServer.getInstance();\n\t\t\n \tUsbCamera gearUsb = gearcamera.startAutomaticCapture();\n \tgearUsb.setFPS(25);\n \tgearUsb.setResolution(256, 144);\n\n\t\t//NetworkTable.setClientMode();\n \t//NetworkTable.setIPAddress(\"raspberrypi.local\");\n\t\t\n\t\t\n\t\t/*\n\t\t * new Thread(() -> { UsbCamera goalcamera =\n\t\t * CameraServer.getInstance().startAutomaticCapture();\n\t\t * goalcamera.setResolution(320, 240); goalcamera.setFPS(30);\n\t\t * goalcamera.setBrightness(1); goalcamera.setExposureManual(1);\n\t\t * \n\t\t * CvSink goalCvSink = CameraServer.getInstance().getVideo();\n\t\t * \n\t\t * Mat source = new Mat();\n\t\t * \n\t\t * while(!Thread.interrupted()) { goalCvSink.grabFrame(source);\n\t\t * goaloutputmat = source; } }).start();\n\t\t * goalPipeline.process(goaloutputmat);\n\t\t * \n\t\t * new Thread(() -> { UsbCamera gearcamera =\n\t\t * CameraServer.getInstance().startAutomaticCapture();\n\t\t * gearcamera.setResolution(320, 240); gearcamera.setFPS(30);\n\t\t * gearcamera.setBrightness(1); gearcamera.setExposureManual(1);\n\t\t * \n\t\t * CvSink gearCvSink = CameraServer.getInstance().getVideo();\n\t\t * \n\t\t * Mat source = new Mat();\n\t\t * \n\t\t * while(!Thread.interrupted()) { gearCvSink.grabFrame(source);\n\t\t * gearoutputmat = source; } }).start();\n\t\t * gearPipeline.process(gearoutputmat);\n\t\t */\n\t}", "public Hand() {\r\n\t\t\r\n\t}", "protected void initialize() {\n \tRobot.intake.setHard(isHard);\n }", "public Robot() {\t\n\t\tthis.step = myclass.STD_STEP ; \n\t\tthis.speed = myclass.STD_SPEED ; \n\t\tthis.rightM = new EV3LargeRegulatedMotor(myclass.rightP) ; \n\t\tthis.leftM = new EV3LargeRegulatedMotor(myclass.leftP) ; \n\t}", "public ShooterWheel() {\n configureWheelFalcons();\n }", "public void grab() {\n\t\tif (climbMode == false) {\n\t\t\tif (bumperL) {\n\t\t\t\tmotorGL.set(-1);\n\t\t\t\tmotorGR.set(1);\n\t\t\t} \n\t\t\telse if (bumperR) {\n\t\t\t\tmotorGL.set(1);\n\t\t\t\tmotorGR.set(-1);\n\t\t\t}\t\n\t\t\telse {\n\t\t\t\tmotorGL.set(0);\n\t\t\t\tmotorGR.set(0);\n\t\t\t}\n\t\t}\n\t}", "protected void initialize() {\n \tshooterWheel.shooterWheelSpeedControllerAft.reset();\n \tshooterWheel.shooterWheelSpeedControllerAft.Enable();\n }", "public void robotInit() {\n chooser = new SendableChooser();\n chooser.addDefault(\"Default Auto\", defaultAuto);\n chooser.addObject(\"My Auto\", customAuto);\n SmartDashboard.putData(\"Auto choices\", chooser);\n \n // camera stuff\n robotCamera = CameraServer.getInstance();\n robotCamera.setQuality(50);\n robotCamera.startAutomaticCapture(\"cam0\");\n\n //our robot stuff\n // myChassis\t= new RobotDrive(0,1);\n leftSide\t= new VictorSP(1);\n rightSide\t= new VictorSP(0);\n spinWheels\t= new TalonSRX(2);\n armLifty\t= new TalonSRX(3);\n drivePad\t= new Joystick(0);\n statesPad\t= new Joystick(1);\n LiveWindow.addActuator(\"stud\", \"talonsrx\", armLifty);\n \n //arm position stuff\n armPosition\t\t= new AnalogInput(0);\n armPortSwitch\t= new DigitalInput(0);\n \n //solenoid stuff\n //solenoidThing = new Solenoid(1);\n \n //init button states\n lBPX\t\t\t= false;\n bIPX\t\t\t= false;\n \n //driver buttons\n ballSpitButton\t= 4;\n ballSuckButton\t= 2;\n \n //state machine variables\n defaultState\t\t= 0;\n portState\t\t\t= 1;\n chevellState\t\t= 2;\n ballGrabState\t\t= 10;\n driveState\t\t\t= 11;\n lowBarState\t\t\t= 8;\n rockState\t\t\t= driveState;\n roughState\t\t\t= driveState;\n moatState\t\t\t= driveState;\n rampartState\t\t= driveState;\n drawState\t\t\t= driveState;\n sallyState\t\t\t= driveState;\n liftOverride\t\t= 0.09;\n terrainStates\t\t= 0;\n autoLiftSpeed\t\t= 1.0;\n armLiftBuffer\t\t= 0.01;\n //port state variables\n portPosition1\t\t= 1.7;\n portPosition2\t\t= 0.9;\n portSwitch\t\t\t= 0;\n //chevell state variables\n chevellPosition1\t= 1.135;\n chevellPosition2\t= 2.0;\n chevellSwitch \t\t= 0;\n chevellWheelSpeed\t= 0.3;\n //ball grab state variables\n ballGrabPosition1\t= 1.35;\n ballGrabSwitch\t\t= 0;\n ballGrabWheelSpeed\t= -0.635;\n ballSpitWheelSpeed\t= 1.0;\n //lowbar state variables\n lowBarPosition\t\t= 1.6;\n lowBarSwitch\t\t= 0;\n //drive state variables\n driveSwitch\t\t\t= 1;\n \n }", "public Hand() {\n }", "@Override\n protected void initialize() {\n isInterruptible();\n holdPos = Robot.getEndEffectorAngle().getRawEncoder();\n }", "public Shooter() {\n servo.set(ShooterConstants.Servo_Down);\n \n \n }", "public void setBoulderLockOff(){\r\n\t\tservoTarget = Constants.BALL_HOLDER_RETRACTED;\r\n\t}", "@Override\n public void robotInit() {\n m_chooser.setDefaultOption(\"Default Auto\", kDefaultAuto);\n m_chooser.addOption(\"My Auto\", kCustomAuto);\n SmartDashboard.putData(\"Auto choices\", m_chooser);\n\n /* lets grab the 360 degree position of the MagEncoder's absolute position */\n /* mask out the bottom12 bits, we don't care about the wrap arounds */ \n\t\tint absolutePosition = elevator.getSelectedSensorPosition(0) & 0xFFF;\n \n /* use the low level API to set the quad encoder signal */\n elevator.setSelectedSensorPosition(absolutePosition, Constants.kPIDLoopIdx, Constants.kTimeoutMs);\n\n /* choose the sensor and sensor direction */\n elevator.configSelectedFeedbackSensor(FeedbackDevice.CTRE_MagEncoder_Relative, \n Constants.kPIDLoopIdx, Constants.kTimeoutMs);\n\n /* Ensure sensor is positive when output is positive */\n elevator.setSensorPhase(false);\n\n /**\n * Set based on what direction you want forward/positive to be.\n * This does not affect sensor phase. \n */ \n //elevator.setInverted(Constants.kMotorInvert);\n \n /* Config the peak and nominal outputs, 12V means full */\n elevator.configNominalOutputForward(0, Constants.kTimeoutMs);\n elevator.configNominalOutputReverse(0, Constants.kTimeoutMs);\n //elevator.configPeakOutputForward(1, Constants.kTimeoutMs);\n elevator.configNominalOutputForward(0.5);\n //elevator.configPeakOutputForward(1, Constants.kTimeoutMs);\n elevator.configPeakOutputForward(0.5);\n elevator.configPeakOutputReverse(-1, Constants.kTimeoutMs);\n \n /**\n * Config the allowable closed-loop error, Closed-Loop output will be\n * neutral within this range. See Table in Section 17.2.1 for native\n * units per rotation.\n */\n //elevator.configAllowableClosedloopError(0, Constants.kPIDLoopIdx, Constants.kTimeoutMs);\n \n /* Config Position Closed Loop gains in slot0, typically kF stays zero. */\n elevator.config_kF(Constants.kPIDLoopIdx, 0.0, Constants.kTimeoutMs);\n elevator.config_kP(Constants.kPIDLoopIdx, 0.5, Constants.kTimeoutMs);\n elevator.config_kI(Constants.kPIDLoopIdx, 0.0, Constants.kTimeoutMs);\n elevator.config_kD(Constants.kPIDLoopIdx, 0.0, Constants.kTimeoutMs);\n\n\n }", "public void setAsDoor()\n\t{\n\t\toriginalX = this.x2;\n\t\toriginalY = this.y2;\n\t\tisDoor = true;\t\n\t\tstateOfDoor=DOOR_STATE_CLOSED;\n\t\t\n\t\tswingingWay1=true;//May change directions if there is an obstacle\n\t\tticks = 0;\n\t}", "@Override\n protected void initialize() {\n Robot.powerCellManipulator.stopIntake();\n }", "public OI() {\n\t\tgearShifter.whenActive(new SetShifterLowGear());\n\t\tgearShifter.whenInactive(new SetShifterHighGear());\n\n\t\t// ballIntakeForward.whenPressed(new BallIntakeSetForward());\n\t\t// ballIntakeReverse.whenPressed(new BallIntakeSetReverse());\n\t\t// ballIntakeStop.whenActive(new BallIntakeSetStop());\n\t\t//\n\t\t// feederForward.whenPressed(new FeederSetForward());\n\t\t// feederReverse.whenPressed(new FeederSetReverse());\n\t\t// feederStop.whenActive(new FeederSetStop());\n\t\t// //\n\t\t// flywheelForward.whenPressed(new FlywheelSetForward());\n\t\t// flywheelReverse.whenPressed(new FlywheelSetReverse());\n\t\t// flywheelStop.whenActive(new FlywheelSetStop());\n\t\t//\n\t\t// gearIntakeReverse.whileHeld(new IntakeInDown());\n\t\t// gearIntakeForward.whileHeld(new IntakeOutDown());\n\t\t// gearIntakeJoystickReverse.whileHeld(new IntakeInDown());\n\t\t// gearIntakeJoystickForward.whileHeld(new IntakeOutDown());\n\t\t// gearIntakeReverse.whenReleased(new IntakeInDownTimer());\n\t\t// gearIntakeForward.whenReleased(new IntakeOutDownTimer());\n\t\t// gearIntakeForward.whenReleased(new GearIntakeSetUp());\n\t\t// gearIntakeReverse.whenPressed(new GearIntakeSetReverse());\n\t\t// gearIntakeStop.whenActive(new GearIntakeSetStop());\n\t\t// gearIntakePosistionSwitch.whenPressed(new GearIntakeSetUp());\n\t\t// gearIntakePosistionSwitch.whenReleased(new GearIntakeSetDown());\n\t\t//\n\t\t// climber.whenPressed(new ClimberSetUp());\n\t\t// climber.whenReleased(new ClimberSetStop());\n\t\t//\n\t\t// otherShooter.whenPressed(new OtherShooterShoot());\n\t\t// otherShooter.whenReleased(new OtherShooterReset());\n\t}", "public OI(){\n\t\t\n\t//\tc6.whenPressed(new dumpFlapOpen());\n\t\t//c8.whenPressed(new dumpFlapClose()); \n//\t\tl7.whenPressed(new dumpFlapOpen());\n//\n//\t\tx3.whileHeld(new hopperCoil());\n//\t\tx1.whileHeld(new hopperUnCoil());\n//\t\tx2.whileHeld(new climber());\n//\t\tx0.whenPressed(new climberReset());\n//\t\tx8.toggleWhenPressed(new cameraOneInit());\n//\t\tx9.toggleWhenPressed(new cameraTwoInit());\n//\n//\t\tr1.toggleWhenPressed(new driveBaseSwitchDirections());\n\t\t//l1.toggleWhenPressed(new visionSwitchCameras());\n\t\t\n\t\t/* logitech controller */\n\t\tc6.whenPressed(new dumpFlapOpen());\n\t\tc8.whenPressed(new dumpFlapClose()); \n\t\tl7.whenPressed(new dumpFlapOpen());\n\n\t\tc4.whileHeld(new hopperCoil());\n\t\tc3.whileHeld(new hopperUnCoil());\n\t\tc1.whileHeld(new climber());\n\t\tc2.whenPressed(new climberReset());\n\t\tc11.toggleWhenPressed(new cameraOneInit());\n\t\tc12.toggleWhenPressed(new cameraTwoInit());\n\n\t\tr1.toggleWhenPressed(new driveBaseSwitchDirections());\n\t\tl1.toggleWhenPressed(new visionSwitchCameras());\n\t\t\n\t\t\n\t\t\n\t\t\n\t\t\n\t\t/* TRASH CONTROLS */\n\t\t//l7.whenPressed(new resetClimberBoolean());\n\t\t//r1.whenPressed(new visionSwitchCameras());\n//\t\tl1.whenPressed(new visionSwitchCameras());\n\t\t//r1.whenActive(new visionSwitchCameras());\n//\t\tc9.whenPressed(new intakeFlapOpen());\n//\t\tc10.whenPressed(new intakeFlapClose()); \n\t\t\n//\t\tc5.whenPressed(new pushGearOut());\n//\t\tc7.whenPressed(new pushGearIn()); \n\t\t\n//\t\tc5.whenActive(new pushGearOut());\n//\t\tc7.whenActive(new pushGearIn()); \n//\t\tc5.toggleWhenPressed(new pushGearOut());\n//\tc7.toggleWhenPressed(new pushGearIn()); \n//\n//\t\tc5.whileHeld(new pushGearOut());\n//\t\tc7.whileHeld(new pushGearIn()); \n\t}", "public void extendSolenoid2(){\n solenoid2.set(Value.kForward);\n }", "protected void initialize() {\n ////TEST CODE\n \tRobotMap.frontLeftTurn.set(0);\n \tRobotMap.frontRightTurn.set(0);\n \tRobotMap.backLeftTurn.set(0);\n \tRobotMap.backRightTurn.set(0);\n \t\n \t//Spin motors\n \tRobotMap.frontLeftTurn.set(85);\n \tRobotMap.frontRightTurn.set(85);\n \tRobotMap.backLeftTurn.set(85);\n \tRobotMap.backRightTurn.set(85);\n \tTimer.delay(2.75);\n \t\n \t//Stop Spin\n \tRobotMap.frontLeftTurn.set(0);\n \tRobotMap.frontRightTurn.set(0);\n \tRobotMap.backLeftTurn.set(0);\n \tRobotMap.backRightTurn.set(0);\n \tTimer.delay(2.75);\n \t\n \t//Move Back\n \tRobotMap.frontLeftDrive.set(0.2);\n \tRobotMap.frontRightDrive.set(0.2);\n \tRobotMap.backLeftDrive.set(0.2);\n \tRobotMap.backRightDrive.set(0.2); \t\n \tTimer.delay(2.75); \n \t\n \t//Stop\n \t\n \tRobotMap.frontLeftDrive.set(0);\n \tRobotMap.frontRightDrive.set(0);\n \tRobotMap.backLeftDrive.set(0);\n \tRobotMap.backRightDrive.set(0);\n }", "public void turnLightsOn()\n {\n set(Relay.Value.kForward);\n }", "public interface RobotMap {\n\t// CAN Device IDs\n\n\tpublic static final int WINCH_TALON = 1;\n\t// winch motors\n\n\tpublic static final int LEFT_ALIGN_TALON = 3;\n\tpublic static final int RIGHT_ALIGN_TALON = 4;\n\t// allignment wheels\n\n\tpublic static final int REAR_RIGHT_TALON = 5;\n\tpublic static final int REAR_LEFT_TALON = 6;\n\tpublic static final int FRONT_RIGHT_TALON = 7;\n\tpublic static final int FRONT_LEFT_TALON = 8;\n\t// drivetrain wheels\n\n\tpublic static final int PCM_MAIN = 9;\n\n\t/******************\n ** PNEUMATICS ** \n ******************/ \n\tpublic static final int FLIPPER_RIGHT = 0;\n\tpublic static final int FLIPPER_LEFT = 1;\n\tpublic static final int ARMS_A = 2;\n\tpublic static final int ARMS_B = 3;\n\t// End Pneumatic Channels\n\n\t/******************\n **PID CONTROLLER** \n ******************/ \n public static final double ABS_TOL = 100;\n public static final double P = .4;\n public static final double I = .01;\n public static final double D = 11;\n public static final double OUT_RANGE_L = -0.8;\n public static final double OUT_RANGE_H = 0.8;\n\n}", "@Override\n public void init() {\n telemetry.addData(\"Status\", \"Initializing\"); //display on the drivers phone that its working\n\n FLM = hardwareMap.get(DcMotor.class, \"FLM\"); //Go into the config and get the device named \"FLM\" and assign it to FLM\n FRM = hardwareMap.get(DcMotor.class, \"FRM\"); //device name doesn't have to be the same as the variable name\n BLM = hardwareMap.get(DcMotor.class, \"BLM\"); //DcMotor.class because that is what the object is\n BRM = hardwareMap.get(DcMotor.class, \"BRM\");\n\n BigSuck = hardwareMap.get(DcMotor.class, \"BigSUCK\");\n SmallSuck = hardwareMap.get(DcMotor.class, \"SmallSUCK\");\n SmallSuck.setDirection(DcMotor.Direction.REVERSE);\n \n UpLift = hardwareMap.get(DcMotor.class, \"LIFT\");\n UpLift.setMode(DcMotor.RunMode.STOP_AND_RESET_ENCODER);\n UpLift.setZeroPowerBehavior(DcMotor.ZeroPowerBehavior.BRAKE);\n\n //Make it so we don't have to add flip the sign of the power we are setting to half the motors\n //FRM.setDirection(DcMotor.Direction.REVERSE); //Run the right side of the robot backwards\n FLM.setDirection(DcMotor.Direction.REVERSE);\n BRM.setDirection(DcMotor.Direction.REVERSE); //the right motors are facing differently than the left handed ones\n\n FLM.setZeroPowerBehavior(DcMotor.ZeroPowerBehavior.BRAKE);\n FRM.setZeroPowerBehavior(DcMotor.ZeroPowerBehavior.BRAKE);\n BLM.setZeroPowerBehavior(DcMotor.ZeroPowerBehavior.BRAKE);\n BRM.setZeroPowerBehavior(DcMotor.ZeroPowerBehavior.BRAKE);\n\n DragArm = hardwareMap.servo.get(\"drag_arm\");\n DragArm.setDirection(Servo.Direction.REVERSE);\n DragArm.setPosition(DragArmRestPosition);\n\n LiftGrab = hardwareMap.servo.get(\"GRAB\");\n LiftGrab.setPosition(LiftGrabRestPosition);\n\n LiftSwivel = hardwareMap.servo.get(\"SWIVEL\");\n LiftSwivel.setPosition(LiftSwivelRestPosition);\n\n Push = hardwareMap.get(Servo.class, \"PUSH\");\n Push.setDirection(Servo.Direction.FORWARD);\n Push.setPosition(PushRestPosition);\n\n telemetry.addData(\"Status\", \"Initialized\");\n telemetry.update();\n }", "@Override\n public void robotInit() {\n\n // BEGIN AUTOGENERATED CODE, SOURCE=ROBOTBUILDER ID=CONSTRUCTORS\n drive = new Drive();\n pDP = new PDP();\n\n // END AUTOGENERATED CODE, SOURCE=ROBOTBUILDER ID=CONSTRUCTORS\n // OI must be constructed after subsystems. If the OI creates Commands\n //(which it very likely will), subsystems are not guaranteed to be\n // constructed yet. Thus, their requires() statements may grab null\n // pointers. Bad news. Don't move it.\n oi = new OI();\n camera1 = CameraServer.getInstance().startAutomaticCapture(0);\n camera2 = CameraServer.getInstance().startAutomaticCapture(1);\n camera1.setConnectionStrategy(VideoSource.ConnectionStrategy.kKeepOpen);\n camera2.setConnectionStrategy(VideoSource.ConnectionStrategy.kKeepOpen);\n server = CameraServer.getInstance().getServer();\n flipped = true;\n server.setSource(camera1);\n vexGyro = new AnalogGyro(0);\n vexGyro.setSensitivity(.00175);\n //rightEncoder = new Encoder(0, 1, false);\n //leftEncoder = new Encoder(2, 3, true);\n // Add commands to Autonomous Sendable Chooser\n // BEGIN AUTOGENERATED CODE, SOURCE=ROBOTBUILDER ID=AUTONOMOUS\n\n chooser.setDefaultOption(\"Autonomous Command\", new AutonomousCommand());\n PixyCamBlock centerBlock = PixyCam2.GetCentermostBlock();\n if(centerBlock == null)\n {\n SmartDashboard.putString(\"target good? \", \"no, is null\");\n }\n else{\n String out = \"Center Block, X: \"+centerBlock.xCenter + \" Y: \"+centerBlock.yCenter;\n SmartDashboard.putString(\"center block data \", out);\n if (centerBlock.yCenter < 200){\n SmartDashboard.putString(\"target good?\", \"YES!!! ycenter less than 200\");\n }\n }\n \n \n\n\n \n \n // END AUTOGENERATED CODE, SOURCE=ROBOTBUILDER ID=AUTONOMOUS\n SmartDashboard.putData(\"Auto mode\", chooser);\n SmartDashboard.putBoolean(\"isFlipped\", flipped);\n SmartDashboard.putNumber(\"right encoder\", drive.getRightEncoder());\n SmartDashboard.putNumber(\"left encoder\", drive.getLeftEncoder());\n }", "@Override\n public void robotInit() {\n m_chooser.setDefaultOption(\"Default Auto\", kDefaultAuto);\n m_chooser.addOption(\"My Auto\", kCustomAuto);\n SmartDashboard.putData(\"Auto choices\", m_chooser);\n SmartDashboard.putData(leftMotor1);\n SmartDashboard.putData(leftMotor2);\n SmartDashboard.putData(rightMotor1);\n SmartDashboard.putData(rightMotor2);\n SmartDashboard.putData(firstMotor);\n SmartDashboard.putData(secondMotor);\n \n\n\n\n }", "public void frontUp(){\n frontSolenoid.set(DoubleSolenoid.Value.kForward);\n }", "public void init(HardwareMap ahwMap) {\n // Save reference to Hardware map\n hwMap = ahwMap;\n\n // Define and Initialize Motors\n// frontLeft = hwMap.get(DcMotor.class, \"frontLeft\");\n// frontRight = hwMap.get(DcMotor.class, \"frontRight\");\n// backLeft = hwMap.get(DcMotor.class, \"backLeft\");\n// lift = hwMap.get(DcMotor.class, \"lift\");\n// backRight = hwMap.get(DcMotor.class, \"backRight\");\n\n leftIntake = hwMap.get(DcMotor.class, \"leftIntake\");\n rightIntake = hwMap.get(DcMotor.class, \"rightIntake\");\n dropper = hwMap.get(DcMotor.class, \"dropper\");\n\n\n //range = hwMap.get(ModernRoboticsI2cRangeSensor.class, \"range\");\n gyro = (ModernRoboticsI2cGyro)hwMap.gyroSensor.get(\"gyro\");\n //color = hwMap.get(ModernRoboticsI2cColorSensor.class, \"color\");\n\n frontLeft.setDirection(DcMotor.Direction.REVERSE); // Set to REVERSE if using AndyMark motors\n frontRight.setDirection(DcMotor.Direction.FORWARD);// Set to FORWARD if using AndyMark motors\n backLeft.setDirection(DcMotor.Direction.REVERSE); // Set to REVERSE if using AndyMark motors\n backRight.setDirection(DcMotor.Direction.FORWARD);// Set to FORWARD if using AndyMark motors\n\n // Set all motors to zero power\n frontLeft.setPower(0);\n frontRight.setPower(0);\n backLeft.setPower(0);\n backRight.setPower(0);\n leftIntake.setPower(0);\n rightIntake.setPower(0);\n dropper.setPower(0);\n\n // Set all motors to run without encoders.\n // May want to use RUN_USING_ENCODERS if encoders are installed.\n frontLeft.setMode(DcMotor.RunMode.RUN_WITHOUT_ENCODER);\n frontRight.setMode(DcMotor.RunMode.RUN_WITHOUT_ENCODER);\n backLeft.setMode(DcMotor.RunMode.RUN_WITHOUT_ENCODER);\n backRight.setMode(DcMotor.RunMode.RUN_WITHOUT_ENCODER);\n leftIntake.setMode(DcMotor.RunMode.RUN_WITHOUT_ENCODER);\n rightIntake.setMode(DcMotor.RunMode.RUN_WITHOUT_ENCODER);\n dropper.setMode(DcMotor.RunMode.RUN_WITHOUT_ENCODER);\n\n // Define and initialize ALL installed servos.\n\n// claimingArm = hwMap.get(Servo.class, \"claimingArm\");\n// claw1 = hwMap.get(Servo.class, \"claw1\");\n// claw2 = hwMap.get(Servo.class, \"claw2\");\n// samplingArm = hwMap.get(Servo.class, \"samplingArm\");\n\n helper = hwMap.get(Servo.class, \"helper\");\n leftUp = hwMap.get(Servo.class, \"leftUp\");\n rightUp = hwMap.get(Servo.class, \"rightUp\");\n outLeft = hwMap.get(Servo.class, \"outLeft\");\n outRight = hwMap.get(Servo.class, \"outRight\");\n\n// claimingArm.setPosition(0); // find out what servo they are using\n// claw1.setPosition(0);\n// claw2.setPosition(0);\n// samplingArm.setPosition(0);\n\n helper.setPosition(MID_SERVO);\n leftUp.setPosition(MID_SERVO);\n rightUp.setPosition(MID_SERVO);\n outLeft.setPosition(0.5);\n outRight.setPosition(0.5);\n\n dim = hwMap.get(DeviceInterfaceModule.class, \"Device Interface Module 1\");\n\n }", "public void onCompletedGesture(SimpleOpenNI curContext,int gestureType, PVector pos)\n{\n println(\"onCompletedGesture - gestureType: \" + gestureType + \", pos: \" + pos);\n \n int handId = kinect.startTrackingHand(pos);\n println(\"hand stracked: \" + handId);\n}", "@Override\r\n protected void initialize() {\r\n //colorMotor = new CANSparkMax(leftDeviceID, MotorType.kBrushless);\r\n //colorEncoder = colorMotor.getEncoder();\r\n \r\n RobotMap.colorEncoder.setPosition(0); // set the encoder to its \"home\" position or zero \r\n }", "@Override\n public void init() {\n // Get references to dc motors and set initial mode and direction\n // It appears all encoders are reset upon robot startup, but just in case, set all motor\n // modes to Stop-And-Reset-Encoders during initialization.\n motorLeftA = hardwareMap.dcMotor.get(MOTOR_DRIVE_LEFT_A);\n motorLeftA.setMode(DcMotor.RunMode.RUN_USING_ENCODER);\n motorLeftA.setDirection(DcMotor.Direction.FORWARD);\n\n motorLeftB = hardwareMap.dcMotor.get(MOTOR_DRIVE_LEFT_B);\n motorLeftB.setMode(DcMotor.RunMode.RUN_USING_ENCODER);\n motorLeftB.setDirection(DcMotor.Direction.FORWARD);\n\n motorRightA = hardwareMap.dcMotor.get(MOTOR_DRIVE_RIGHT_A);\n motorRightA.setMode(DcMotor.RunMode.RUN_USING_ENCODER);\n motorRightA.setDirection(DcMotor.Direction.REVERSE);\n\n motorRightB = hardwareMap.dcMotor.get(MOTOR_DRIVE_RIGHT_B);\n motorRightB.setMode(DcMotor.RunMode.RUN_USING_ENCODER);\n motorRightB.setDirection(DcMotor.Direction.REVERSE);\n\n //motorGlyphLift = hardwareMap.dcMotor.get(GLYPH_LIFT);\n //motorGlyphLift.setMode(DcMotor.RunMode.RUN_USING_ENCODER);\n //motorGlyphLift.setDirection(DcMotor.Direction.FORWARD);\n\n sGlyphL = hardwareMap.servo.get(GLYPH_LEFT);\n //sGlyphL.scaleRange(0,180);\n\n sGlyphR = hardwareMap.servo.get(GLYPH_RIGHT);\n sGem = hardwareMap.servo.get(Gem);\n\n //Initialize vex motor\n sGLift = hardwareMap.crservo.get(Servo_GlyphLift);\n\n //sGLift.setPower(0);\n\n //sGLift2 = hardwareMap.servo.get(Servo_GlyphLift);\n\n BNO055IMU.Parameters parameters = new BNO055IMU.Parameters();\n parameters.angleUnit = BNO055IMU.AngleUnit.DEGREES;\n\n imu = hardwareMap.get(BNO055IMU.class, \"imu\");\n imu.initialize(parameters);\n\n imu = hardwareMap.get(BNO055IMU.class,\"imu\");\n imu.initialize(parameters);\n\n //servoGlyph1.setPosition(180);\n //servoGlyph2.setPosition(180);\n\n bDirection = true;\n }", "protected void initialize() {\n \ttarget = (int) SmartDashboard.getNumber(\"target\", 120);\n \ttarget = (int) (target * Constants.TICKS_TO_INCHES);\n\t\tRobot.drive.stop();\n\t\tmaxCount = (int) SmartDashboard.getNumber(\"max count\", 0);\n\t\ttolerance = (int) SmartDashboard.getNumber(\"tolerance\", 0);\n\t\tRobot.drive.left.motor1.setSelectedSensorPosition(0, Constants.kPIDLoopIdx, Constants.kTimeoutMs);\n\t\tRobot.drive.right.motor1.setSelectedSensorPosition(0, Constants.kPIDLoopIdx, Constants.kTimeoutMs);\n }", "public void robotInit() \n {\n RobotMap.init();\n\n driveTrain = new DriveTrain();\n gripper = new Gripper();\n verticalLift = new VerticalLift();\n\n // OI must be constructed after subsystems. If the OI creates Commands \n //(which it very likely will), subsystems are not guaranteed to be \n // constructed yet. Thus, their requires() statements may grab null \n // pointers. Bad news. Don't move it.\n\n oi = new OI();\n\n autonomousChooser = new SendableChooser();\n autonomousChooser.addDefault( \"Auto: Do Nothing\" , new DoNothing () );\n autonomousChooser.addObject ( \"Auto: Drive To Auto Zone\" , new DriveToAutoZone () );\n autonomousChooser.addObject ( \"Auto: Drive To Auto Zone (Bump)\" , new DriveToAutoZoneBump () );\n //autonomousChooser.addObject ( \"Auto: Get One (Long)\" , new GetOneLong () );\n //autonomousChooser.addObject ( \"Auto: Get One (Short)\" , new GetOneShort () );\n //autonomousChooser.addObject ( \"Auto: Get One Recycle Bin (Bump)\" , new GetOneRecycleBin () );\n autonomousChooser.addObject ( \"Auto: Get One Recycle Bin (Side)\" , new GetRecycleBinSide () );\n //autonomousChooser.addObject ( \"Auto: Get One Recycle Bin (Backwards)\" , new GetOneRecycleBinBackwards () );\n //autonomousChooser.addObject ( \"Auto: Get One Recycle Bin (Backwards, Bump)\", new GetOneRecycleBinBackwardsBump() );\n //autonomousChooser.addObject ( \"Auto: Get Two (Short)\" , new GetTwoShort () );\n //autonomousChooser.addObject ( \"Auto: Get Two Short (Special)\" , new GetTwoShortSpecial () );\n //autonomousChooser.addObject ( \"Auto: Get Two (Long, From left)\" , new TwoLongFromLeft () );\n //autonomousChooser.addObject ( \"Auto: Get Two (Long, From right)\" , new TwoLongFromRight () );\n autonomousChooser.addObject ( \"Auto: Get One Tote and Recycle Bin\" , new OneRecycleBinAndTote () );\n autonomousChooser.addObject ( \"Auto: Get One Tote and Recycle Bin (Bump)\" , new OneRecycleBinAndToteBump () );\n SmartDashboard.putData( \"Autonomous\", autonomousChooser );\n\n // instantiate the command used for the autonomous period\n //autonomousCommand = new RunAutonomousCommand();\n\n m_USBVCommand = new UpdateSBValuesCommand();\n m_USBVCommand.start();\n \n frame = NIVision.imaqCreateImage(NIVision.ImageType.IMAGE_RGB, 0);\n /*\n // the camera name (ex \"cam0\") can be found through the roborio web interface\n session = NIVision.IMAQdxOpenCamera(\"cam1\",\n NIVision.IMAQdxCameraControlMode.CameraControlModeController);\n NIVision.IMAQdxConfigureGrab(session);\n \n NIVision.IMAQdxStartAcquisition(session);\n */\n /*\n camServer = CameraServer.getInstance();//.startAutomaticCapture(\"cam1\");\n camServer.setQuality(30);\n \n cam = new USBCamera(\"cam1\");\n cam.openCamera();\n cam.setFPS(60);\n \n cam.setSize(320, 240);\n cam.updateSettings();\n */\n }", "@Override\r\n\tpublic void handleObject() {\r\n\t\tfinished = false;\r\n\t\t//hand.setStallThreshold(5, 100);\r\n\r\n\t\tif (wheelDriver != null) {\r\n\t\t\twheelDriver.turn(Math.toRadians(30));\r\n\t\t}\r\n\r\n\t\thand.stop();\r\n\t\topenHand();\r\n\r\n\t\tif (wheelDriver != null) {\r\n\t\t\tarm.rotate(SWEEP_ROTATION);\r\n\t\t\twheelDriver.setSpeed(WheelDriver.SPEED_SLOW);\r\n\t\t\twheelDriver.turn(-Math.toRadians(45));\r\n\t\t\twheelDriver.setSpeed(WheelDriver.SPEED_NORMAL);\r\n\t\t\tarm.rotate(ARM_ROTATION - SWEEP_ROTATION);\r\n\t\t\twheelDriver.backward(2);\r\n\t\t} else {\r\n\t\t\tarm.rotate(ARM_ROTATION);\r\n\t\t}\r\n\r\n\t\thand.rotate(-100, true);\r\n\t\ttry {\r\n\t\t\tThread.sleep(WAIT_TIME);\r\n\t\t} catch (InterruptedException e) {\r\n\t\t}\r\n\r\n\t\tif (wheelDriver != null) {\r\n\t\t\twheelDriver.backward(8);\r\n\t\t}\r\n\r\n\t\tarm.rotate(-ARM_ROTATION);\r\n\t\tarm.stop();\r\n\t\tarm.flt();\r\n\r\n\t\tfinished = true;\r\n\t}", "void unlockDoor() {\n }", "@Override\n\tprotected void initialize()\n\t{\n\t\tRobotMap.joshsPID.reset();\n\t\tRobotMap.joshsPID.enable();\n\t\tRobotMap.joshsPID.setOutputRange(-1.0, 0.0);\n\t\t// RobotMap.joshsPID.setIContributionRange(-0.1, 0.1);\n\t}", "@Override\n protected void initialize() {\n ramper.reset();\n Robot.toteLifterSubsystem.setGateState(GateState.OPEN);\n }", "public void grabStone() {\n }", "public void initElbow(){\r\n do{\r\n int currentElbowPosition = motorElbow.getCurrentPosition();\r\n posElbow = currentElbowPosition - DELTA_ELBOW;\r\n motorElbow.setTargetPosition(posElbow);\r\n motorElbow.setPower(POWER_ELBOW_SLOW);\r\n } while(!sensorElbow.isPressed());\r\n\r\n motorElbow.setPower(STOP);\r\n resetElbowEncoder();\r\n posElbow = 0;\r\n }", "public void init(HardwareMap hwMap) {\r\n\r\n //DRIVE//\r\n front_left = hwMap.dcMotor.get(\"front_left\");\r\n front_right = hwMap.dcMotor.get(\"front_right\");\r\n back_left = hwMap.dcMotor.get(\"back_left\");\r\n back_right = hwMap.dcMotor.get(\"back_right\");\r\n\r\n hook = hwMap.dcMotor.get(\"hook\");\r\n\r\n //intake1 = hwMap.servo.get(\"intake1\");\r\n //intake2 = hwMap.servo.get(\"intake2\");\r\n //intake3 = hwMap.servo.get(\"intake3\");\r\n //intake4 = hwMap.servo.get(\"intake4\");\r\n\r\n phone = hwMap.servo.get(\"phone\");\r\n marker = hwMap.servo.get(\"marker\");\r\n\r\n //linSlide1 = hwMap.dcMotor.get(\"lin_slide1\");\r\n //linSlide2 = hwMap.dcMotor.get(\"lin_slide2\");\r\n\r\n //arm_motor_1 = hwMap.dcMotor.get(\"arm1\");\r\n //arm_motor_2 = hwMap.dcMotor.get(\"arm2\");\r\n\r\n\r\n front_left.setDirection(DcMotor.Direction.FORWARD);\r\n front_right.setDirection(DcMotor.Direction.FORWARD);\r\n back_left.setDirection(DcMotor.Direction.REVERSE);\r\n back_right.setDirection(DcMotor.Direction.REVERSE);\r\n\r\n /* front_left.setMode(DcMotor.RunMode.RUN_TO_POSITION);\r\n front_right.setMode(DcMotor.RunMode.RUN_TO_POSITION);\r\n back_left.setMode(DcMotor.RunMode.RUN_TO_POSITION);\r\n back_right.setMode(DcMotor.RunMode.RUN_TO_POSITION);\r\n */\r\n hook.setDirection(DcMotor.Direction.FORWARD);\r\n\r\n //linSlide1.setDirection(DcMotor.Direction.FORWARD);\r\n //linSlide1.setDirection(DcMotor.Direction.REVERSE);\r\n\r\n //arm_motor_1.setDirection(DcMotor.Direction.FORWARD);\r\n //arm_motor_2.setDirection(DcMotor.Direction.REVERSE);\r\n\r\n front_left.setZeroPowerBehavior(DcMotor.ZeroPowerBehavior.BRAKE);\r\n front_right.setZeroPowerBehavior(DcMotor.ZeroPowerBehavior.BRAKE);\r\n back_left.setZeroPowerBehavior(DcMotor.ZeroPowerBehavior.BRAKE);\r\n back_right.setZeroPowerBehavior(DcMotor.ZeroPowerBehavior.BRAKE);\r\n\r\n //encoder1 = hwMap.analogInput.get(\"encoder1\");\r\n //encoder2 = hwMap.analogInput.get(\"encoder2\");\r\n\r\n imu = hwMap.get(BNO055IMU.class, \"imu\");\r\n }", "public Motor() {\n reInitialize();\n }", "public void hold() {\n _collectorMotor.set(holdSpeed);\n }", "@Override\n protected void initialize() {\n //Robot.limelight.setLiveStream(0);\n Robot.limelight.setLEDMode(3);\n }", "public void init(HardwareMap ahwMap) {\n // Save reference to Hardware map\n hwMap = ahwMap;\n \n // Define and Initialize Motors\n leftMotorFrt = hwMap.get(DcMotor.class, \"LeftMotorFwd\");\n rightMotorFrt = hwMap.get(DcMotor.class, \"RightMotorFwd\");\n //PickupUnit = hwMap.get(DcMotor.class, \"PickupUnit\");\n leftMotorBck = hwMap.get(DcMotor.class, \"LeftMotorBck\");\n rightMotorBck = hwMap.get(DcMotor.class, \"RightMotorBck\");\n foundationHookRight = hwMap.get(Servo.class, \"hookRight\");\n foundationHookLeft = hwMap.get(Servo.class, \"hookLeft\");\n TheClaw = hwMap.get(Servo.class, \"theclaw\");\n foundTouch = hwMap.get(TouchSensor.class, \"foundTouch\");\n intakeRight = hwMap.get(DcMotor.class, \"intakeRight\");\n intakeLeft = hwMap.get(DcMotor.class, \"intakeLeft\");\n \n foundationHookRight.setPosition(0.7);\n foundationHookLeft.setPosition(0.7);\n leftMotorFrt.setDirection(DcMotor.Direction.FORWARD); // Set to REVERSE if using AndyMark motors\n rightMotorFrt.setDirection(DcMotor.Direction.REVERSE);// Set to FORWARD if using AndyMark motors\n leftMotorBck.setDirection(DcMotor.Direction.FORWARD); // Set to REVERSE if using AndyMark motors\n rightMotorBck.setDirection(DcMotor.Direction.REVERSE);// Set to FORWARD if using AndyMark motors\n intakeRight.setDirection(DcMotor.Direction.REVERSE);\n intakeLeft.setDirection(DcMotor.Direction.FORWARD);\n\n // Set all motors to zero power\n leftMotorFrt.setPower(0);\n rightMotorFrt.setPower(0);\n leftMotorBck.setPower(0);\n rightMotorBck.setPower(0);\n //PickupUnit.setPower(0);\n \n leftMotorFrt.setZeroPowerBehavior(DcMotor.ZeroPowerBehavior.BRAKE);\n rightMotorFrt.setZeroPowerBehavior(DcMotor.ZeroPowerBehavior.BRAKE);\n leftMotorBck.setZeroPowerBehavior(DcMotor.ZeroPowerBehavior.BRAKE);\n rightMotorBck.setZeroPowerBehavior(DcMotor.ZeroPowerBehavior.BRAKE);\n //PickupUnit.setZeroPowerBehavior(DcMotor.ZeroPowerBehavior.BRAKE);\n \n // Set all motors to run without encoders.\n // May want to use RUN_USING_ENCODERS if encoders are installed.\n leftMotorFrt.setMode(DcMotor.RunMode.RUN_WITHOUT_ENCODERS);\n rightMotorFrt.setMode(DcMotor.RunMode.RUN_WITHOUT_ENCODERS);\n leftMotorBck.setMode(DcMotor.RunMode.RUN_WITHOUT_ENCODERS);\n rightMotorBck.setMode(DcMotor.RunMode.RUN_WITHOUT_ENCODERS);\n //PickupUnit.setMode(DcMotor.RunMode.RUN_WITHOUT_ENCODERS);\n \n }", "protected void initialize() {\n \tRobot.conveyor.stop();\n }", "public void newHand() {\n if(player.getSecondHand().size() > 0){\n player.emptySecondHand(deck);\n shuffle();\n }\n player.resetBet();\n dealer.resetBet();\n errorFlag = false;\n userMessage = \"Place your Bet\";\n againDisabled = true;\n dealDisabled = false;\n hitDisabled = true;\n splitDisabled = true;\n standDisabled = true;\n doubleDisabled = true;\n bettingDisabled = false;\n emptyHands();\n }", "public void shoot() {\n _shooterMotor1.set(_targetRPM);\n }", "@Override\npublic void teleopPeriodic() {\nm_robotDrive.arcadeDrive(m_stick.getRawAxis(5)* (-0.5), m_stick.getRawAxis(4)*0.5);\n}", "@Override\n\tpublic void setChaseTarget(){\n\t\tthis.setTarget(_pacman.getX()+Constants.SQUARE_SIDE,_pacman.getY()-(4*Constants.SQUARE_SIDE));\n\t}", "protected void initialize() {\n \tbrakeFactor = 0.0;\n }", "@Override\n protected void initialize() {\n Robot.leftDriveEncoder.reset();\n Robot.rightDriveEncoder.reset();\n tempTargetDirection = Robot.targetDirection + Robot.navX.getYaw();\n\n\n }", "private void setZeroPowerBrakes() {\n //Initialize Mecanum Wheel DC Motor Behavior\n robot2.DriveRightFront.setZeroPowerBehavior(DcMotor.ZeroPowerBehavior.BRAKE);\n robot2.DriveRightRear.setZeroPowerBehavior(DcMotor.ZeroPowerBehavior.BRAKE);\n robot2.DriveLeftFront.setZeroPowerBehavior(DcMotor.ZeroPowerBehavior.BRAKE);\n robot2.DriveLeftRear.setZeroPowerBehavior(DcMotor.ZeroPowerBehavior.BRAKE);\n }", "public Hand() {\n this.hole1 = new BlankCard();\n this.hole2 = new BlankCard();\n showCards = false;\n }", "public void setByhand(java.lang.Boolean newByhand)\n\t\tthrows java.rmi.RemoteException;", "public interface RobotMap {\n\n /* COMPETITION BOT */\n\n // CAN Talon SRX\n int LEFT_TALON = 7;\n int RIGHT_TALON = 9;\n int LIFT_TALON = 8;\n int CLIMB_TALON = 10;\n\n // CAN Victor SPX\n int LEFT_DRIVE_VICTOR = 1;\n int RIGHT_DRIVE_VICTOR = 3;\n\n // Victor SP PWM ports\n int INTAKE_VICTOR = 0;\n int CLIMB_VICTOR = 1;\n\n // Double Solenoid PCM IDs\n int FORWARD_CHANNEL = 6;\n int REVERSE_CHANNEL = 7;\n\n // Digital Input ports\n int HALL_SENSOR = 0;\n int LIMIT_SWITCH = 1;\n\n // Pneumatics Control Module CAN ID\n int PCM = 0;\n\n\n /* PRACTICE BOT */\n\n /*\n\n // CAN Talon SRX\n int LEFT_TALON = 6;\n int RIGHT_TALON = 1;\n int LIFT_TALON = 2;\n int CLIMB_TALON = 5;\n\n // CAN Victor SPX\n int LEFT_DRIVE_VICTOR = 6;\n int RIGHT_DRIVE_VICTOR = 2;\n\n // Victor SP PWM ports\n int INTAKE_VICTOR = 0;\n int CLIMB_VICTOR = 1;\n\n // Double Solenoid PCM IDs\n int FORWARD_CHANNEL = 6;\n int REVERSE_CHANNEL = 7;\n\n // Digital Input ports\n int HALL_SENSOR = 0;\n int LIMIT_SWITCH = 1;\n\n // Pneumatics Control Module CAN ID\n int PCM = 0;\n\n */\n\n}", "public Intake() {\n motor_0.setInverted(true);\n }", "public AutoScript(Robot robot) {\r\n\t\tthis.robot = robot;\r\n\r\n\t\t//leftEncoder = new DirectionalEncoder(1, 2, RobotTemplate.WHEEL_DIAMETER);\r\n\t\tleftEncoderPIDOut = new PIDOut();\r\n\t\tleftEncoderPIDSauce = new PIDSauce(0);\r\n\t\tleftEncoderPID = new PIDWrapper(RobotTemplate.ENCODER_PID_P, RobotTemplate.ENCODER_PID_I, RobotTemplate.ENCODER_PID_D, RobotTemplate.ENCODER_PID_F, leftEncoderPIDSauce, leftEncoderPIDOut, 0.05);\r\n\r\n\t\t//rightEncoder = new DirectionalEncoder(3, 4, RobotTemplate.WHEEL_DIAMETER);\r\n\t\trightEncoderPIDOut = new PIDOut();\r\n\t\trightEncoderPIDSauce = new PIDSauce(0);\r\n\t\trightEncoderPID = new PIDWrapper(RobotTemplate.ENCODER_PID_P, RobotTemplate.ENCODER_PID_I, RobotTemplate.ENCODER_PID_D, RobotTemplate.ENCODER_PID_F, rightEncoderPIDSauce, rightEncoderPIDOut, 0.05);\r\n\r\n\t\tgyro = robot.chassis.gyro;\r\n\t\tgyroPIDOut = new PIDOut();\r\n\t\tgyroPIDSauce = new PIDSauce(0);\r\n\t\tgyroPID = new PIDWrapper(RobotTemplate.GYRO_PID_P, RobotTemplate.GYRO_PID_I, RobotTemplate.GYRO_PID_D, RobotTemplate.GYRO_PID_F, gyroPIDSauce, gyroPIDOut, 0.05);\r\n\t\tgyroPID.enable();\r\n\t}", "public void autonomousInit() { //Problems here when power is not cycled between matches.\n \tauto.autonomousInit();\n }", "public void setHigh(double value){high = value;}", "public HanoiTower(){\n\n }", "public void setSensorOn() {\n\n }", "@Override\n public void setOpponentsLastHand(Hand hand)\n {\n }", "public UnoHand getHand() {\r\n return hand;\r\n }", "protected void initialize() {\n finished = false;\n Robot.shooter.Spin();//Spin up wheels\n Timer.delay(3);\n Robot.shooter.TriggerExtend();//Reset Trigger\n Timer.delay(.2);\n Robot.shooter.FeederExtend();//Drop Frisbee\n Timer.delay(1.5);\n Robot.shooter.TriggerRetract();//Fire frisbee\n Timer.delay(.2);\n Robot.shooter.FeederRetract();//Reset Feeder\n Timer.delay(.4);\n \n Robot.shooter.TriggerExtend();//Reset Trigger\n Timer.delay(.2);\n Robot.shooter.FeederExtend();//Drop Frisbee\n Timer.delay(1.5);\n Robot.shooter.TriggerRetract();//Fire frisbee\n Timer.delay(.2);\n Robot.shooter.FeederRetract();//Reset Feeder\n Timer.delay(.4);\n \n Robot.shooter.TriggerExtend();//Reset Trigger\n Timer.delay(.2);\n Robot.shooter.FeederExtend();//Drop Frisbee\n Timer.delay(1.5);\n Robot.shooter.TriggerRetract();//Fire frisbee\n Timer.delay(.2);\n Robot.shooter.FeederRetract();//Reset Feeder\n Timer.delay(.4);\n //Robot.shooter.Stop();\n Robot.shooter.TriggerExtend();//Reset Trigger\n \n Robot.driveTrain.DriveBack();//Drives backwards from pyramid\n Timer.delay(1.5);\n Robot.driveTrain.TurnAround();//Turns Bob around\n Timer.delay(1);\n Robot.driveTrain.Stop();//Stops Bob\n \n Robot.pneumatics.CompressorOn();//Turns compressor on\n }", "@Override\n public void robotInit() {\n m_driveTrain = new DriveTrain();\n m_oi = new OI(); \n encoder = new Encoder();\n JoystickDrive = new JoystickDrive();\n RoboticArm = new RoboticArm();\n Science = new Science();\n pid = new PID();\n inverse = new Inverse();\n\n // workingSerialCom = new serialComWorking();\n\n\n // while(true){\n // // ros_string = workingSerialCom.read();\n // // System.out.println(ros_string);\n // LeftFront = Robot.m_driveTrain.dr+iveTrainLeftFrontMotor.getSelectedSensorVelocity()*(10/4096);\n // RightFront = Robot.m_driveTrain.driveTrainRightFrontMotor.getSelectedSensorVelocity()*(10/4096);\n // LeftFront_ros = workingSerialCom.floattosString(LeftFront);\n // RigthFront_ros = workingSerialCom.floattosString(RightFront);\n\n // ros_string = workingSerialCom.read();\n // gulce = workingSerialCom.StringConverter(ros_string, 1);\n // System.out.println(gulce);\n // workingSerialCom.write(LeftFront_ros+RigthFront_ros+\"\\n\");\n // }\n // workingSerialCom.write(\"Yavuz\\n\");\n // // RoboticArm.run();\n // // m_driveTrain.run();\n // // workingSerialCom.StringConverter(ros_string, 3);\n }", "@Override\n\tpublic void robotInit() {\n\t\tm_chooser.setDefaultOption(\"Default Auto\", kDefaultAuto);\n\t\tm_chooser.addOption(\"My Auto\", kCustomAuto);\n\t\tSmartDashboard.putData(\"Auto choices\", m_chooser);\n\n\t\tJoy = new Joystick(0);\n\t\ts1 = new DoubleSolenoid(1, 0);\n\t\ts2 = new DoubleSolenoid(2, 3);\n\t\tairCompressor = new Compressor();\n\t\ttriggerValue = false;\n\t\ts1Value = false;\n\t}", "public void stopRobot(){\n LAM.setPower(0);\n RAM.setPower(0);\n ILM.setPower(0);\n IRM.setPower(0);\n BLM.setPower(0);\n BRM.setPower(0);\n FLM.setPower(0);\n FRM.setPower(0);\n }", "@Override\n public void initialize() {\n conveyor.setBallCount(0);\n conveyor.startTime(); \n }", "public void toggleGrab(){\n \tif (isClosed == true){\n \t\ttriggerTimer.reset();\n \t\tisClosed = false;\n \t\tClawAct.set(false);\n \t\tRobot.oi.armRumble(RUMBLE_DURATION);\n\n \t} else {\n \t\tisClosed = true;\n \t\tClawAct.set(true);\n \t\tRobot.oi.armRumble(RUMBLE_DURATION);\n\n \t}\n }", "public DriveSubsystem() {\n leftFrontMotor = new TalonSRX(RobotMap.leftFrontMotor);\n rightFrontMotor = new TalonSRX(RobotMap.rightFrontMotor);\n leftBackMotor = new TalonSRX(RobotMap.leftBackMotor);\n rightBackMotor = new TalonSRX(RobotMap.rightBackMotor);\n // rightMotor.setInverted(true); \n direction = 0.75;\n SmartDashboard.putString(\"Direction\", \"Shooter side\");\n }", "@Override\n public void initialize() {\n setPoint = (((targetAngle + driveSubsystem.getHeading() + 180) % 360) - 180);\n }", "public void mo4361Y() {\n this.f3169c = -1;\n }", "public void init() {\n//\t\tint anglesToEncTicks = (int) ((90 - currentAngle) * encoderTicksPerRev);\n//\t\tarmMotor.setEncPosition(anglesToEncTicks);\n\t\twhile (armMotor.isFwdLimitSwitchClosed() != true) {\n\t\t\tarmMotor.set(.2);\n\t\t}\n\t\tSystem.out.println(\"Calibrated!\");\n\t\tarmMotor.setEncPosition(0);\n\t}", "@Override\n\tpublic void robotInit() {\n\t\tdrive = new Drive();\n\t\tintake = new Intake();\n\t\tshooter = new Shooter();\n\t\taimShooter = new AimShooter();\n\t\tvision = new Vision();\n\t\tintakeRoller = new IntakeRoller();\n\t\taManipulators = new AManipulators();\n\t\tshooterLock = new ShooterLock();\n\n\t\t// autochooser\n\t\t// autoChooser = new SendableChooser();\n\n\t\toi = new OI();\n\t\t// instantiate the command used for the autonomous period\n\t\tlowGearCommand = new LowGear();\n\n\t\t// auto chooser commands\n\t\t// autoChooser.addDefault(\"FarLeftAuto\", new FarLeftAuto());\n\t\t// autoChooser.addObject(\"MidLeftAuto\", new MidLeftAuto());\n\t\t// autoChooser.addObject(\"MidAuto\", new MidAuto());\n\t\t// autoChooser.addObject(\"MidRightAuto\", new MidRightAuto());\n\t\t// autoChooser.addObject(\"FarRightAuto\", new FarRightAuto());\n\t\t// autoChooser.addObject(\"Uber Auto\", new UberAuto());\n\t\t// autoChooser.addObject(\"Paper Weight\", new PaperWeightAuto());\n\t\t//\n\t\t// SmartDashboard.putData(\"Autonomous\", autoChooser);\n\n\t\t// autonomousCommand = (Command) autoChooser.getSelected();\n\t\tautonomousCommand = new FarLeftAuto();\n\t\t// autonomousCommand = new MidAuto();\n\t\t// CameraServer.getInstance().startAutomaticCapture(\"cam3\");\n\t\t// autonomousCommand = new FarLeftAuto\n\n\t\tpovUpTrigger.whenActive(new MoveActuatorsUp());\n\t\tpovDownTrigger.whenActive(new MoveActuatorsDown());\n\t}", "public void resetHand()\r\n\t{\r\n\t\thandCount = 0;\r\n\t\tstand = false;\r\n\t}", "@Override\r\n public void init() {\r\n // Define and Initialize Motors\r\nFL = hardwareMap.get(DcMotor.class, \"Front Left\");\r\n FR = hardwareMap.get(DcMotor.class, \"Front Right\");\r\n BL = hardwareMap.get(DcMotor.class, \"Back Left\");\r\n BR = hardwareMap.get(DcMotor.class, \"Back Right\");\r\n\r\n\r\nFL.setDirection(DcMotor.Direction.FORWARD);\r\n FR.setDirection(DcMotor.Direction.REVERSE);\r\n BL.setDirection(DcMotor.Direction.FORWARD);\r\n BR.setDirection(DcMotor.Direction.REVERSE);\r\n // Set all motors to zero power\r\n FL.setPower(0);\r\n FR.setPower(0);\r\n BL.setPower(0);\r\n BR.setPower(0); }", "public Shooter() {\n fire1 = new Solenoid(1);\n fire2 = new Solenoid(4);\n returnValve = new Solenoid(3);\n latchSolenoid = new Solenoid(2);\n FFM = true;\n m_enabled = true;\n shooting = false;\n reloading = false;\n initShooter();\n }", "public void mo12203o() {\n this.f10960o = 0;\n }", "@Override\n public void loop() {\n\n //double armRot = robot.Pivot.getPosition();\n\n double deadzone = 0.2;\n\n double trnSpdMod = 0.5;\n\n float xValueRight = gamepad1.right_stick_x;\n float yValueLeft = -gamepad1.left_stick_y;\n\n xValueRight = Range.clip(xValueRight, -1, 1);\n yValueLeft = Range.clip(yValueLeft, -1, 1);\n\n // Pressing \"A\" opens and closes the claw\n if (gamepad1.a) {\n\n if (robot.Claw.getPosition() < 0.7)\n while(gamepad1.a){\n robot.Claw.setPosition(1);}\n else if (robot.Claw.getPosition() > 0.7)\n while(gamepad1.a){\n robot.Claw.setPosition(0.4);}\n else\n while(gamepad1.a)\n robot.Claw.setPosition(1);\n }\n\n // Pressing \"B\" changes the wrist position\n if (gamepad1.b) {\n\n if (robot.Wrist.getPosition() == 1)\n while(gamepad1.b)\n robot.Wrist.setPosition(0.5);\n else if (robot.Wrist.getPosition() == 0.5)\n while(gamepad1.b)\n robot.Wrist.setPosition(1);\n else\n while(gamepad1.b)\n robot.Wrist.setPosition(1);\n }\n\n // Turn left/right, overrides forward/back\n if (Math.abs(xValueRight) > deadzone) {\n\n robot.FL.setPower(xValueRight * trnSpdMod);\n robot.FR.setPower(-xValueRight * trnSpdMod);\n robot.BL.setPower(xValueRight * trnSpdMod);\n robot.BR.setPower(-xValueRight * trnSpdMod);\n\n\n } else {//Forward/Back On Solely Left Stick\n if (Math.abs(yValueLeft) > deadzone) {\n robot.FL.setPower(yValueLeft);\n robot.FR.setPower(yValueLeft);\n robot.BL.setPower(yValueLeft);\n robot.BR.setPower(yValueLeft);\n }\n robot.FL.setPower(0);\n robot.FR.setPower(0);\n robot.BL.setPower(0);\n robot.BR.setPower(0);\n }\n\n\n telemetry.addData(\"Drive Encoder Ticks\", robot.FL.getCurrentPosition());\n telemetry.addData(\"Winch Encoder Ticks\", robot.Winch.getCurrentPosition());\n telemetry.addData(\"ColorArm Position\", robot.ColorArm.getPosition());\n telemetry.addData(\"Wrist Position\", robot.Wrist.getPosition());\n telemetry.addData(\"Claw Position\", robot.Claw.getPosition());\n telemetry.addData(\"Grip Position\", robot.Grip.getPosition());\n telemetry.addData(\"Color Sensor Data Red\", robot.Color.red());\n telemetry.addData(\"Color Sensor Data Blue\", robot.Color.blue());\n\n /*\n\n // This is used for an Omniwheel base\n\n // Group a is Front Left and Rear Right, Group b is Front Right and Rear Left\n float a;\n float b;\n float turnPower;\n if(!gamepad1.x) {\n if (Math.abs(xValueRight) <= deadzone && Math.abs(yValueRight) <= deadzone) {\n // And is used here because both the y and x values of the right stick should be less than the deadzone\n\n a = Range.clip(yValueLeft + xValueLeft, -1, 1);\n b = Range.clip(yValueLeft - xValueLeft, -1, 1);\n\n\n robot.FL.setPower(a);\n robot.FR.setPower(b);\n robot.BL.setPower(b);\n robot.BR.setPower(a);\n\n telemetry.addData(\"a\", \"%.2f\", a);\n telemetry.addData(\"b\", \"%.2f\", b);\n\n } else if (Math.abs(xValueRight) > deadzone || Math.abs(yValueRight) > deadzone) {\n\n // Or is used here because only one of the y and x values of the right stick needs to be greater than the deadzone\n turnPower = Range.clip(xValueRight, -1, 1);\n\n robot.FL.setPower(-turnPower);\n robot.FR.setPower(turnPower);\n robot.BL.setPower(-turnPower);\n robot.BR.setPower(turnPower);\n\n } else {\n\n robot.FL.setPower(0);\n robot.FR.setPower(0);\n robot.BL.setPower(0);\n robot.BR.setPower(0);\n }\n\n } else {\n\n if (Math.abs(xValueRight) <= deadzone && Math.abs(yValueRight) <= deadzone) {\n\n // And is used here because both the y and x values of the right stick should be less than the deadzone\n a = Range.clip(yValueLeft + xValueLeft, -0.6f, 0.6f);\n b = Range.clip(yValueLeft - xValueLeft, -0.6f, 0.6f);\n\n\n robot.FL.setPower(a);\n robot.FR.setPower(b);\n robot.BL.setPower(b);\n robot.BR.setPower(a);\n\n telemetry.addData(\"a\", \"%.2f\", a);\n telemetry.addData(\"b\", \"%.2f\", b);\n\n } else if (Math.abs(xValueRight) > deadzone || Math.abs(yValueRight) > deadzone) {\n\n // Or is used here because only one of the y and x values of the right stick needs to be greater than the deadzone\n turnPower = Range.clip(xValueRight, -1, 1);\n\n robot.FL.setPower(-turnPower);\n robot.FR.setPower(turnPower);\n robot.BL.setPower(-turnPower);\n robot.BR.setPower(turnPower);\n\n } else {\n\n robot.FL.setPower(0);\n robot.FR.setPower(0);\n robot.BL.setPower(0);\n robot.BR.setPower(0);\n }\n }\n\n\n if (gamepad1.dpad_up) {\n\n robot.Swing.setPower(.6);\n\n } else if (gamepad1.dpad_down) {\n\n robot.Swing.setPower(-.6);\n\n } else {\n\n robot.Swing.setPower(0);\n }\n\n if(gamepad1.a){\n\n robot.Claw.setPosition(.4);\n\n } else if(gamepad1.b){\n\n robot.Claw.setPosition(0);\n }\n\n if(gamepad1.left_bumper) {\n\n robot.Pivot.setPosition(armRot+0.0005);\n\n } else if(gamepad1.right_bumper) {\n\n robot.Pivot.setPosition(armRot-0.0005);\n\n } else{\n\n robot.Pivot.setPosition(armRot);\n }\n\n telemetry.addData(\"position\", position);\n\n */\n\n /*\n * Code to run ONCE after the driver hits STOP\n */\n }", "@Override\n\tpublic void robotInit() {\n\t\tm_chooser.setDefaultOption(\"Default Auto\", kDefaultAuto);\n\t\tm_chooser.addOption(\"My Auto\", kCustomAuto);\n\t\tSmartDashboard.putData(\"Auto choices\", m_chooser);\n\n\t\tm_frontRight = new PWMVictorSPX(0);\n\t\tm_frontLeft = new PWMVictorSPX(2);\n\t\tm_backRight = new PWMVictorSPX(1);\n\t\tm_backLeft = new PWMVictorSPX(3);\n\n\t\tx_aligning = false;\n\n\t\tJoy = new Joystick(0);\n\t\tmyTimer = new Timer();\n\n\t\tfinal SpeedControllerGroup m_left = new SpeedControllerGroup(m_frontLeft, m_backLeft);\n\t\tfinal SpeedControllerGroup m_right = new SpeedControllerGroup(m_frontRight, m_backRight);\n\n\t\tm_drive = new DifferentialDrive(m_left, m_right);\n\n\t\tdistanceToTarget = 0;\n\n\t\tcounter = new Counter(9);\n\t\tcounter.setMaxPeriod(10.0);\n\t\tcounter.setSemiPeriodMode(true);\n\t\tcounter.reset();\n\t}", "protected void initialize() {\n initialPos = Math.abs(Robot.arm.getArmEncoderValue());\n double direction = Math.signum(setpoint - Math.abs(Robot.arm.getArmEncoderValue()));\n Robot.arm.moveArm(direction * RobotMap.ArmConstants.ARM_AUTONOMOUS_MOVEMENT_POWER, 1);\n }", "public void init(HardwareMap ahwMap) {\n\n// Giving hwMap a value\n hwMap = ahwMap;\n\n// Declaring servos to use in other classes\n claw = hwMap.get(Servo.class, \"servoClaw\");\n clawLeft = hwMap.get(Servo.class, \"servoClawLeft\");\n clawRight = hwMap.get(Servo.class, \"servoClawRight\");\n }", "public void autoGrab(){\n \tif (getTrigger() == true){\n\t \tif(triggerTimer.get() >= TRIGGER_LOCKOUT){\n\t\t \tClawAct.set(true);\n\t\t \tisClosed = true;\n\t \t\tRobot.oi.armRumble(RUMBLE_DURATION);\n\t \t}\n \t}\n\n }" ]
[ "0.6316763", "0.6206535", "0.6204765", "0.6160981", "0.60501117", "0.60298175", "0.5970637", "0.5968425", "0.5964556", "0.5954554", "0.5903092", "0.58931434", "0.58699924", "0.5855027", "0.58143324", "0.57758904", "0.5762559", "0.57382077", "0.5736041", "0.5727749", "0.57125765", "0.5710336", "0.5704932", "0.56722313", "0.56660044", "0.5662967", "0.56619674", "0.5661152", "0.56582034", "0.565766", "0.56565285", "0.56508726", "0.56496644", "0.56452626", "0.5645153", "0.56367934", "0.5634951", "0.56321836", "0.56307673", "0.5622792", "0.5621684", "0.56104946", "0.5607276", "0.5590042", "0.55882317", "0.558568", "0.5585164", "0.55748504", "0.55717605", "0.5567792", "0.5566663", "0.5564034", "0.5556457", "0.55546653", "0.5549729", "0.55471116", "0.5544272", "0.55439526", "0.55420303", "0.5541128", "0.55280524", "0.55275285", "0.5521155", "0.55208415", "0.5516519", "0.5515036", "0.5507667", "0.5503247", "0.55000013", "0.54994226", "0.549937", "0.54954827", "0.549114", "0.5490337", "0.54901505", "0.5489382", "0.5487501", "0.5486666", "0.54842865", "0.54835963", "0.5480948", "0.54728305", "0.54616773", "0.5459616", "0.54556227", "0.5447925", "0.5444322", "0.54347235", "0.54303545", "0.54277027", "0.5427432", "0.5424543", "0.5423384", "0.54231906", "0.5420711", "0.54198354", "0.54118544", "0.5406781", "0.5404958", "0.540258", "0.53930545" ]
0.0
-1
TODO Autogenerated method stub
@Override public void checkOutRoom() { }
{ "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
onLoad is NOT a viable replacement for firstTick stuff, as it is called before the chunk is fully loaded, meaning that any world access will result in infiniteloading of the same chunk
@Override public void update() { if(firstTick) { sortingInventory.onFirstTick(); firstTick = false; } ticksSinceSync++; int x = pos.getX(); int y = pos.getY(); int z = pos.getZ(); if (!worldObj.isRemote && numPlayersUsing != 0 && (ticksSinceSync + x + y + z) % 200 == 0) { Iterator<EntityPlayer> it = chestPlayers.iterator(); while(it.hasNext()) { EntityPlayer entityPlayer = it.next(); if(entityPlayer.isDead || ((ContainerSortingChest) entityPlayer.openContainer).getTileEntity() != this) { it.remove(); } } numPlayersUsing = chestPlayers.size(); worldObj.addBlockEvent(pos, getBlockType(), 1, numPlayersUsing); } prevLidAngle = lidAngle; float lidAngleSpeed = 0.1f; if (numPlayersUsing > 0 && lidAngle == 0f) { worldObj.playSoundEffect(x + 0.5d, y + 0.5d, z + 0.5d, "random.chestopen", 0.5f, worldObj.rand.nextFloat() * 0.1f + 0.9f); } if (numPlayersUsing == 0 && lidAngle > 0.0F || numPlayersUsing > 0 && lidAngle < 1.0F) { float oldLidAngle = lidAngle; if (numPlayersUsing > 0) { lidAngle += lidAngleSpeed; } else { lidAngle -= lidAngleSpeed; } if (lidAngle > 1f) { lidAngle = 1f; } float closeSoundAngle = 0.5f; if (lidAngle < closeSoundAngle && oldLidAngle >= closeSoundAngle) { worldObj.playSoundEffect(x + 0.5d, y + 0.5d, z + 0.5d, "random.chestclosed", 0.5f, worldObj.rand.nextFloat() * 0.1f + 0.9f); } if (lidAngle < 0f) { lidAngle = 0f; } } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n public void onChunkLoad(ChunkLoadEvent event) {\n Chunk chunk = event.getChunk();\n\n //\n Legends.info(\"Chunk loaded in world: \" + event.getWorld().getName());\n\n }", "void minecraftChunkLoaded() {\n\t\tthis.lastLoadingTime = System.currentTimeMillis();\n\t}", "public void load() {\n loadDisabledWorlds();\n chunks.clear();\n for (World world : ObsidianDestroyer.getInstance().getServer().getWorlds()) {\n for (Chunk chunk : world.getLoadedChunks()) {\n loadChunk(chunk);\n }\n }\n }", "public void onLoad() {\n\t}", "@Override\n public void afterWorldInit() {\n }", "public final void onWorldTick() {\n onTick();\n }", "@Override\n\tpublic void onLoad() {\n\t\t\n\t}", "@Override\n\tpublic void load() {\n\t\tModLoader.setInGameHook(this, true, false);\n\t\tModLoader.setInGUIHook(this, true, false);\n\t}", "@Override\n\tpublic void onLoad() {\n\t\tdescription = this.getDescription();\n\t\tpluginConfiguration = this.getConfig();\n\t\tLogHelper.initLogger(\"BukkitWebby\", \"Minecraft\");\n\t}", "public void onLoad()\n\t{\n\t\tJLog.info(\" --- INIT --- \");\n\t\t\n\t}", "protected void onStartLoading() { forceLoad();}", "@Override\n public void loadGame() {\n\n }", "@Override\n public void preInitialise(Context rootContext) {\n this.window = new GlfwWindow(\"ChunkWorld\", 1350, 900, false, true, false);\n rootContext.put(IWindow.class, window);\n window.init();\n }", "@Override\r\n\tprotected void initLoad() {\n\r\n\t}", "@Override\r\n public void load()\r\n {\r\n\tLevel.openMap(\"maps/Level1.map\", _width, _height);\r\n\t_level = Level.getInstance();\r\n\tCamera.getInstance().setBounds(_level.getWorldBoundaries());\r\n\t_printText = new Text(TILESHEET_TEXTURE, \"0123456789xUPC\", 0, 244, 32, 37, 4, 24, 28);\r\n\t_coin = new Sprite(\"Coin\", 6, _height - 34, 24, 24, Tiles.get(COIN_ANIM), false);\r\n\t_1UP = new Sprite(\"1UP\", 200, _height - 42, 42, 42, Tiles.get(MUSHROOM_GREEN), false);\r\n\tSoundLibrary.getInstance().loop(MUSIC_LEVEL);\r\n\tMario.clearData();\r\n }", "void loadAll() {\n\t\tsynchronized (this) {\n\t\t\tif (isFullyLoaded) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tfor (Entry<Integer, Supplier<ChunkMeta<?>>> generator : ChunkMetaFactory.getInstance()\n\t\t\t\t\t.getEmptyChunkFunctions()) {\n\t\t\t\tChunkMeta<?> chunk = generator.getValue().get();\n\t\t\t\tchunk.setChunkCoord(this);\n\t\t\t\tchunk.setPluginID(generator.getKey());\n\t\t\t\ttry {\n\t\t\t\t\tchunk.populate();\n\t\t\t\t} catch (Exception e) {\n\t\t\t\t\t// need to catch everything here, otherwise we block the main thread forever\n\t\t\t\t\t// once it tries to read this\n\t\t\t\t\tCivModCorePlugin.getInstance().getLogger().log(Level.SEVERE, \n\t\t\t\t\t\t\t\"Failed to load chunk data\", e);\n\t\t\t\t}\n\t\t\t\taddChunkMeta(chunk);\n\t\t\t}\n\t\t\tisFullyLoaded = true;\n\t\t\tthis.notifyAll();\n\t\t}\n\t}", "@Override\n public void onLoad() {\n super.onLoad();\n instance = this;\n running = true;\n }", "@Subscribe\n public void load(FMLInitializationEvent event) {\n Log.printFinest(\"container Load event\");\n\n // core checks\n if (!CoreTransformer.created) {\n printDebugDataAndCrash(CoreTransformer.class.getSimpleName() + \" is not being created!\");\n }\n\n if (!CoreTransformer.lightningHookApplied) {\n printDebugDataAndCrash(\"Unable to install a lightning hook!\");\n }\n\n if (!CoreTransformer.gameDataHookApplied) {\n printDebugDataAndCrash(\"Unable to install gamedata hooks!\");\n }\n\n if (MonnefCorePlugin.debugEnv && MonnefCorePlugin.jaffasEnv) {\n try {\n Log.printInfo(\"calling item dumping procedure\");\n ObfuscationHelper.dumpUsedItemsToConfig();\n Log.printInfo(\"item dumping procedure finished\");\n } catch (Exception e) {\n e.printStackTrace();\n }\n }\n\n FMLCommonHandler.instance().bus().register(new CoreTickHandler());\n\n MinecraftForge.EVENT_BUS.register(new WolfFoodRegistry());\n\n MonnefCorePlugin.initialized = true;\n MonnefCorePlugin.Log.printInfo(\"Final checks passed.\");\n }", "public void populate(IChunkProvider loader, int chunkX, int chunkZ)\n\t{\n\t\tBlockFalling.fallInstantly = true;\n\t\tint k = chunkX * 16;\n\t\tint l = chunkZ * 16;\n\t\tBiomeGenBase biomegenbase = worldObj.getBiomeGenForCoords(k + 16, l + 16);\n\t\trand.setSeed(worldObj.getSeed());\n\t\tlong i1 = rand.nextLong() / 2L * 2L + 1L;\n\t\tlong j1 = rand.nextLong() / 2L * 2L + 1L;\n\t\trand.setSeed(chunkX * i1 + chunkZ * j1 ^ worldObj.getSeed());\n\t\tboolean flag = false;\n\n\t\tint k1;\n\t\tint l1;\n\t\tint i2;\n\n\t\t//controls vanilla ores and things like dirt patches\n\t\t//biomegenbase.decorate(worldObj, rand, k, l);\n\n\t\t//if (TerrainGen.populate(loader, worldObj, rand, chunkX, chunkZ, flag, ANIMALS)) {\n\t\t//\tSpawnerAnimals.performWorldGenSpawning(worldObj, biomegenbase, k + 8, l + 8, 16, 16, rand);\n\t\t//}\n\t\tk += 8;\n\t\tl += 8;\n\n\t\tBlockFalling.fallInstantly = false;\n\t}", "public static void onWorldLoad(WorldEvent.Load event)\n {\n if (DO_DAYLIGHT_CYCLE_TC == null || !(event.getWorld() instanceof World)) return;\n\n World world = (World) event.getWorld();\n\n if (world.dimension() == World.OVERWORLD)\n {\n MinecraftServer server = null;\n\n if (!world.isClientSide() && world instanceof ServerWorld)\n {\n server = ((ServerWorld) world).getServer();\n }\n\n world.getGameRules().getRule(RULE_DAYLIGHT).set(false, server);\n\n if (!world.isClientSide() && !Config.sync_to_system_time.get())\n {\n updateServer(world.getDayTime());\n }\n }\n }", "@Override\n public void simpleUpdate(float tpf)\n {\n if (ADD_CHUNKS_DYNAMICALLY) {\n makeMoreWorld();\n if (COMPILE_CHUNK_DATA_ASYNC) buildRestOfColumns();\n }\n }", "@SideOnly(Side.CLIENT)\r\n public void randomDisplayTick(World world, int x, int y, int z, Random random)\r\n {\r\n int meta = world.getBlockMetadata(x, y, z);\r\n if(meta != 1) {\r\n \tif(this.litLevel > 0) {\r\n\t if(random.nextInt(36) == 0) {\r\n\t world.playSound((double)((float)x + 0.5F), (double)((float)y + 0.5F), (double)((float)z + 0.5F), \"fire.fire\", 1.0F + random.nextFloat(), 0.3F + random.nextFloat() * 0.7F, false);\r\n\t }\r\n\t\r\n//\t TileCampfire tile = (TileCampfire)world.getTileEntity(x, y, z);\r\n\t float xOffset = 0.5F;\r\n\t float yOffset = 0.7F;\r\n\t float zOffset = 0.5F;\r\n\t double d0 = (double)((float)x + xOffset);\r\n\t double d1 = (double)((float)y + yOffset);\r\n\t double d2 = (double)((float)z + zOffset);\r\n\t GL11.glPushMatrix();\r\n\t MainRegistry.proxy.spawnParticle(\"largesmoke\", d0, d1, d2, 0.0D, 0.0D, 0.0D, 1.5F * this.litLevel);\r\n\t MainRegistry.proxy.spawnParticle(\"flame\", d0, d1, d2, 0.0D, 0.0D, 0.0D, 2.5F * this.litLevel);\r\n\t GL11.glPopMatrix();\r\n\t }\r\n }\r\n }", "private void loadAllVisibleChunks2(boolean async)\n\t{\n\t\tcalculateChunkBounds();\n\n\t\tfor (int cy = chunkBounds[BOUND_BOTTOM]; cy <= chunkBounds[BOUND_TOP]; cy++)\n\t\t{\n\t\t\tproject.loadChunkRow(cy, chunkBounds[BOUND_LEFT], chunkBounds[BOUND_RIGHT], async);\n\t\t}\n\n\t\tpersistChunkBounds();\n\t\trequestRender();\n\t}", "public void onFirstTick_EM(IGregTechTileEntity aBaseMetaTileEntity) {\n }", "public void updateTick(World p_149674_1_, int p_149674_2_, int p_149674_3_, int p_149674_4_, Random p_149674_5_)\n {\n if (!p_149674_1_.isClient)\n {\n if (p_149674_1_.getBlockLightValue(p_149674_2_, p_149674_3_ + 1, p_149674_4_) < 4 && p_149674_1_.getBlock(p_149674_2_, p_149674_3_ + 1, p_149674_4_).getLightOpacity() > 2)\n {\n p_149674_1_.setBlock(p_149674_2_, p_149674_3_, p_149674_4_, Blocks.dirt);\n }\n else if (p_149674_1_.getBlockLightValue(p_149674_2_, p_149674_3_ + 1, p_149674_4_) >= 9)\n {\n for (int var6 = 0; var6 < 4; ++var6)\n {\n int var7 = p_149674_2_ + p_149674_5_.nextInt(3) - 1;\n int var8 = p_149674_3_ + p_149674_5_.nextInt(5) - 3;\n int var9 = p_149674_4_ + p_149674_5_.nextInt(3) - 1;\n Block var10 = p_149674_1_.getBlock(var7, var8 + 1, var9);\n\n if (p_149674_1_.getBlock(var7, var8, var9) == Blocks.dirt && p_149674_1_.getBlockMetadata(var7, var8, var9) == 0 && p_149674_1_.getBlockLightValue(var7, var8 + 1, var9) >= 4 && var10.getLightOpacity() <= 2)\n {\n p_149674_1_.setBlock(var7, var8, var9, Blocks.grass);\n }\n }\n }\n }\n }", "protected void onLoad() {\n \t\tsuper.onLoad();\n \t\teval(scripts);\n \t}", "public void loadWorld() {\n\t\tint[][] tileTypes = new int[100][100];\n\t\tfor (int x = 0; x < 100; x++) {\n\t\t\tfor (int y = 0; y < 100; y++) {\n\t\t\t\ttileTypes[x][y] = 2;\n\t\t\t\tif (x > 40 && x < 60 && y > 40 && y < 60) {\n\t\t\t\t\ttileTypes[x][y] = 1;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tEntityList entities = new EntityList(0);\n\t\tPlayer player = new Player(Direction.SOUTH_WEST, 50, 50);\n\t\tentities.addEntity(player);\n\t\tentities.addEntity(new Tree(Direction.SOUTH_WEST,49, 49));\n\t\tworld = new World(new Map(tileTypes), player, entities);\n\t}", "@Override\n public void preInit(FMLPreInitializationEvent event)\n {\n EntityRegistry.registerModEntity(new ResourceLocation(ModInfo.MOD_ID, \"goomba\"), EntityGoomba.class, ModInfo.MOD_ID + \":goomba\", 0, MarioMod2.INSTANCE, 128, 1, false);\n EntityRegistry.registerModEntity(new ResourceLocation(ModInfo.MOD_ID, \"koopa\"), EntityKoopa.class, ModInfo.MOD_ID + \":koopa\", 1, MarioMod2.INSTANCE, 128, 1, false);\n EntityRegistry.registerModEntity(new ResourceLocation(ModInfo.MOD_ID, \"fireball\"), EntityFireball.class, ModInfo.MOD_ID + \":fireball\", 2, MarioMod2.INSTANCE, 64, 1, true);\n }", "public void preLoadContent(AssetManager manager) {\n\t\tif (worldAssetState != AssetState.EMPTY) {\n\t\t\treturn;\n\t\t}\n\n\t\tworldAssetState = AssetState.LOADING;\n\n\t\tmanager.load(KOI_TEXTURE, Texture.class);\n\t\tassets.add(KOI_TEXTURE);\n\n\t\tmanager.load(ENEMY_TEXTURE, Texture.class);\n\t\tassets.add(ENEMY_TEXTURE);\n\n\t\tmanager.load(LILY_TEXTURE, Texture.class);\n\t\tassets.add(LILY_TEXTURE);\n\t\t\n\t\tmanager.load(LILY_TEXTURE_N, Texture.class);\n\t\tassets.add(LILY_TEXTURE_N);\n\t\t\n\t\tmanager.load(LILY_TEXTURE_S, Texture.class);\n\t\tassets.add(LILY_TEXTURE_S);\n\n\t\tmanager.load(LANTERN_TEXTURE, Texture.class);\n\t\tassets.add(LANTERN_TEXTURE);\n\n\t\tmanager.load(LIGHTING_TEXTURE, Texture.class);\n\t\tassets.add(LIGHTING_TEXTURE);\n\n\t\tmanager.load(SHADOW_TEXTURE, Texture.class);\n\t\tassets.add(SHADOW_TEXTURE);\n\n\t\tmanager.load(GOAL_TEXTURE, Texture.class);\n\t\tassets.add(GOAL_TEXTURE);\n\n\t\tmanager.load(EARTH_FILE,Texture.class);\n\t\tassets.add(EARTH_FILE);\n\n\t\tmanager.load(EARTH_FILE_D,Texture.class);\n\t\tassets.add(EARTH_FILE_D);\n\t\tmanager.load(EARTH_FILE_N,Texture.class);\n\t\tassets.add(EARTH_FILE_N);\n\t\tmanager.load(EARTH_FILE_S,Texture.class);\n\t\tassets.add(EARTH_FILE_S);\n\t\tmanager.load(SHORE_FILE,Texture.class);\n\t\tassets.add(SHORE_FILE);\n\n\t\tmanager.load(ROCK_FILE_D,Texture.class);\n\t\tassets.add(ROCK_FILE_D);\n\t\tmanager.load(ROCK_FILE_N,Texture.class);\n\t\tassets.add(ROCK_FILE_N);\n\t\tmanager.load(ROCK_FILE_S,Texture.class);\n\t\tassets.add(ROCK_FILE_S);\n\n\t\tmanager.load(WHIRLPOOL_TEXTURE, Texture.class);\n\t\tassets.add(WHIRLPOOL_TEXTURE);\n\t\t\n\t\tmanager.load(ENERGYBAR_TEXTURE, Texture.class);\n\t\tassets.add(ENERGYBAR_TEXTURE);\n\n\t\tmanager.load(UI_FLOWER, Texture.class);\n\t\tassets.add(UI_FLOWER);\n\n\t\tmanager.load(OVERLAY, Texture.class);\n\t\tassets.add(OVERLAY);\n\n\t\tmanager.load(BACKGROUND_FILE_N, Texture.class);\n\t\tassets.add(BACKGROUND_FILE_N);\n\n\t\tmanager.load(BACKGROUND_FILE_D, Texture.class);\n\t\tassets.add(BACKGROUND_FILE_D);\n\n\t\tmanager.load(BACKGROUND_FILE_S, Texture.class);\n\t\tassets.add(BACKGROUND_FILE_S);\n\t\t\n\t\t\n\n\t\tmanager.load(OVERLAY_FILE, Texture.class);\n\t\tassets.add(OVERLAY_FILE);\n\n\t\tmanager.load(KOI_ARROW, Texture.class);\n\t\tassets.add(KOI_ARROW);\n\t\tmanager.load(WHIRL_ARROW, Texture.class);\n\t\tassets.add(WHIRL_ARROW);\n\t\t\n\t\tmanager.load(TUTORIAL_TEXTURE1, Texture.class);\n\t\tassets.add(TUTORIAL_TEXTURE1);\n\t\tmanager.load(TUTORIAL_TEXTURE2, Texture.class);\n\t\tassets.add(TUTORIAL_TEXTURE2);\n\t\tmanager.load(TUTORIAL_TEXTURE3, Texture.class);\n\t\tassets.add(TUTORIAL_TEXTURE3);\n\t\tmanager.load(TUTORIAL_TEXTURE4, Texture.class);\n\t\tassets.add(TUTORIAL_TEXTURE4);\n\t\tmanager.load(TUTORIAL_TEXTURE5, Texture.class);\n\t\tassets.add(TUTORIAL_TEXTURE5);\n\t\tmanager.load(TUTORIAL_TEXTURE6, Texture.class);\n\t\tassets.add(TUTORIAL_TEXTURE6);\n\t\t\n\t\tmanager.load(HELP_TEXTURE, Texture.class);\n\t\tassets.add(HELP_TEXTURE);\n\t\t\n\n\t\treferenceC.a = 0f;\n\n\t\t// Load the font\n\t\tFreetypeFontLoader.FreeTypeFontLoaderParameter size2Params = new FreetypeFontLoader.FreeTypeFontLoaderParameter();\n\t\tsize2Params.fontFileName = FONT_FILE;\n\t\tsize2Params.fontParameters.size = FONT_SIZE;\n\t\tmanager.load(FONT_FILE, BitmapFont.class, size2Params);\n\t\tassets.add(FONT_FILE);\n\n\t\tFreetypeFontLoader.FreeTypeFontLoaderParameter size3Params = new FreetypeFontLoader.FreeTypeFontLoaderParameter();\n\t\tsize3Params.fontFileName = FONT_FILE2;\n\t\tsize3Params.fontParameters.size = FONT_SIZE2;\n\t\tmanager.load(FONT_FILE2, BitmapFont.class, size3Params);\n\t\tassets.add(FONT_FILE2);\n\t\t\n\t\t\n\t}", "public Chunk loadChunk(int x, int p_73158_2_)\n\t{\n\t\treturn this.provideChunk(x, p_73158_2_);\n\t}", "@Override\n public void onLoad() {\n\n new CommandAPICommand(\"killall\")\n .executes((sender, args) -> {\n //Kills all enemies in all worlds\n Bukkit.getWorlds().forEach(w -> w.getLivingEntities().forEach(e -> e.setHealth(0)));\n \t})\n .register();\n }", "public void initChunkSeed(long p_75903_1_, long p_75903_3_) {\n/* 119 */ this.chunkSeed = this.worldGenSeed;\n/* 120 */ this.chunkSeed *= (this.chunkSeed * 6364136223846793005L + 1442695040888963407L);\n/* 121 */ this.chunkSeed += p_75903_1_;\n/* 122 */ this.chunkSeed *= (this.chunkSeed * 6364136223846793005L + 1442695040888963407L);\n/* 123 */ this.chunkSeed += p_75903_3_;\n/* 124 */ this.chunkSeed *= (this.chunkSeed * 6364136223846793005L + 1442695040888963407L);\n/* 125 */ this.chunkSeed += p_75903_1_;\n/* 126 */ this.chunkSeed *= (this.chunkSeed * 6364136223846793005L + 1442695040888963407L);\n/* 127 */ this.chunkSeed += p_75903_3_;\n/* */ }", "void loadChunk(String string, ScriptContext scriptContext)\n\t\t\tthrows ScriptException {\n\t\ttry {\n\t\t\tluaState.load(string, getChunkName(scriptContext));\n\t\t} catch (LuaException e) {\n\t\t\tthrow getScriptException(e);\n\t\t}\n\t}", "@Override\n\t\tpublic void onTick(long arg0) {\n\t\t\t\n\t\t}", "@Override\n\t\tpublic void onLoaded(String arg0) {\n\t\t\t\tplayer.play();\n\t\t}", "protected abstract void initializeWorld();", "@Override\n public void setLoadOnStartup(int los) {\n }", "@Override\n protected final void onLoad() {\n fireDebug(\"QuickTime Player plugin\");\n playerWidget.setSize(\"100%\", _height);\n setWidth(_width);\n\n Timer tt = new Timer() {\n\n @Override\n public void run() {\n impl = QuickTimePlayerImpl.getPlayer(playerId);\n try {\n String v = impl.getPluginVersion();\n if (v != null) {\n cancel();\n fireDebug(\"Plugin Version : \" + v);\n manager.registerMediaStateListener(impl, handler, \"\");\n firePlayerStateEvent(PlayerStateEvent.State.Ready);\n playlistManager.load(0);\n }\n } catch (Exception e) {\n }\n }\n };\n tt.scheduleRepeating(200); // IE workarround ...\n }", "public void loadGame() {\n game.loadGame();\n }", "private void onTickInGame()\n \t{\n \n \t\ttry\n \t\t{\n \n \t\t\tif(tickCount>100)\n \t\t\t{\n \t\t\t\ttickCount=0;\n \t\t\t\tint i=0;\n \n \n \t\t\t\twhile (i<15&&FMLCommonHandler.instance().getEffectiveSide()==Side.SERVER)\n \t\t\t\t{\n \t\t\t\t\ti++;\n \t\t\t\t\tLinkData link;\n \n \t\t\t\t\t//actually gets the random rift based on the size of the list\n \t\t\t\t\tlink = (LinkData) dimHelper.instance.getRandomLinkData(true);\n \n \n \n \t\t\t\t\tif(link!=null)\n \t\t\t\t\t{\n \n \t\t\t\t\t\tif(dimHelper.getWorld(link.locDimID)!=null)\n \t\t\t\t\t\t{\n \t\t\t\t\t\t\tWorld world=dimHelper.getWorld(link.locDimID);\n \n \t\t\t\t\t\t\tint blocktoReplace = world.getBlockId(link.locXCoord, link.locYCoord, link.locZCoord);\n \n \t\t\t\t\t\t\tif(!mod_pocketDim.blocksImmuneToRift.contains(blocktoReplace))//makes sure the rift doesn't replace a door or something\n \t\t\t\t\t\t\t{\n \t\t\t\t\t\t\t\tif(dimHelper.instance.getLinkDataFromCoords(link.locXCoord, link.locYCoord, link.locZCoord, link.locDimID)==null)\n \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\telse\n \t\t\t\t\t\t\t\t{\n \t\t\t\t\t\t\t\t\tdimHelper.getWorld(link.locDimID).setBlock(link.locXCoord, link.locYCoord, link.locZCoord, properties.RiftBlockID);\n \t\t\t\t\t\t\t\t\tTileEntityRift.class.cast(dimHelper.getWorld(link.locDimID).getBlockTileEntity(link.locXCoord, link.locYCoord, link.locZCoord)).hasGrownRifts=true;\n \t\t\t\t\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}\n \t\t\t}\n \n \n \t\t}\n \t\tcatch (Exception e)\n \t\t{\n \t\t\ttickCount++;\n \t\t\tSystem.out.println(\"something on tick went wrong: \" + e);\n \t\t\te.printStackTrace();\n \t\t}\n \t\ttickCount++;\n \n \t\t//this section regulates decay in Limbo- it records any blocks placed by the player and later progresss them through the decay cycle\n \t\tif(tickCount2>10&&dimHelper.blocksToDecay!=null)\n \t\t{\n \t\t\ttickCount2=0;\n \t\t\tif(!dimHelper.blocksToDecay.isEmpty()&&dimHelper.getWorld(properties.LimboDimensionID)!=null)\n \t\t\t{\n \n \n \t\t\t\tif(dimHelper.blocksToDecay.size()>rand.nextInt(400))\n \t\t\t\t{\n \t\t\t\t\tint index = rand.nextInt(dimHelper.blocksToDecay.size());\n \t\t\t\t\tPoint3D point = (Point3D) dimHelper.blocksToDecay.get(index);\n \n \t\t\t\t\tint blockID = dimHelper.getWorld(properties.LimboDimensionID).getBlockId(point.getX(), point.getY(), point.getZ());\n \t\t\t\t\tint idToSet=Block.stone.blockID;\n \n \t\t\t\t\tif(blockID==0||blockID==properties.LimboBlockID)\n \t\t\t\t\t{\n \t\t\t\t\t\tdimHelper.blocksToDecay.remove(index);\n \t\t\t\t\t}\n \t\t\t\t\telse\n \t\t\t\t\t{\n \t\t\t\t\t\tif(Block.blocksList[idToSet] instanceof BlockContainer)\n \t\t\t\t\t\t{\n \t\t\t\t\t\t\tidToSet=-1;\n \t\t\t\t\t\t\tdimHelper.blocksToDecay.remove(index); \n \t\t\t\t\t\t}\n \n \n \n \t\t\t\t\t\tif(blockID==Block.cobblestone.blockID)\n \t\t\t\t\t\t{\n \t\t\t\t\t\t\tidToSet=Block.gravel.blockID;\n \t\t\t\t\t\t}\n \t\t\t\t\t\tif(blockID==Block.stone.blockID)\n \t\t\t\t\t\t{\n \t\t\t\t\t\t\tidToSet=Block.cobblestone.blockID;\n \n \t\t\t\t\t\t}\n \t\t\t\t\t\tif(blockID==Block.gravel.blockID&&!dimHelper.getWorld(properties.LimboDimensionID).isAirBlock(point.getX(), point.getY()-1, point.getZ()))\n \t\t\t\t\t\t{\n \t\t\t\t\t\t\tidToSet=properties.LimboBlockID;\n \t\t\t\t\t\t\tdimHelper.getWorld(properties.LimboDimensionID).scheduleBlockUpdate(point.getX(), point.getY(), point.getZ(),10, idToSet);\n \n \t\t\t\t\t\t}\n \t\t\t\t\t\telse if(blockID==Block.gravel.blockID)\n \t\t\t\t\t\t{\n \t\t\t\t\t\t\tdimHelper.blocksToDecay.remove(index);\n \t\t\t\t\t\t\tidToSet=-1;\n \n \t\t\t\t\t\t}\n \n \t\t\t\t\t\tif(idToSet!=-1)\n \t\t\t\t\t\t{\n \n \t\t\t\t\t\t\tdimHelper.getWorld(properties.LimboDimensionID).setBlock(point.getX(), point.getY(), point.getZ(), idToSet);\n \n \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\n \t\t\t}\n \t\t}\n \n \t\ttickCount2++;\n \n \t\tif(mod_pocketDim.teleTimer>0)\n \t\t{\n \t\t\tmod_pocketDim.teleTimer--;\n \t\t}\n \n \n \n \n \n \n \t}", "private void GameInitialize()\r\n { \r\n // set to fullscreen to use the entire \r\n // display or false to only use\r\n // the area inbetween the two bars on the display\r\n setFullScreenMode(true);\r\n\r\n // setup 3D\r\n try\r\n {\r\n Object3D[] buffer = Loader.load(\"/RaptorWalk.m3g\");\r\n\r\n for(int i = 0; i < buffer.length; i++)\r\n {\r\n if(buffer[i] instanceof World)\r\n {\r\n // get our world node\r\n mWorld = (World)buffer[i];\r\n mEnemy = (SkinnedMesh)mWorld.find(56);\r\n mEnemyTimer = 0;\r\n break;\r\n }\r\n }\r\n }\r\n catch(Exception e) \r\n { System.out.println(\"Loading error!\" + e.getMessage()); }\r\n\r\n // create a game font\r\n mGameFont = Font.getFont(Font.FACE_MONOSPACE, \r\n Font.STYLE_PLAIN, Font.SIZE_SMALL);\r\n\r\n // Get the active camera from the world\r\n mCam = mWorld.getActiveCamera();\r\n mCam.translate(0, 1.0f, 0);\r\n\r\n // Create an ambient light and add it to the world node\r\n Light light = new Light();\r\n light.setMode(Light.AMBIENT);\r\n light.setIntensity(3);\r\n mWorld.addChild(light);\r\n }", "public static void SelfCallForLoading() {\n\t}", "@Override\n public void livingTick() {\n super.livingTick();\n }", "@Override\n protected void onStartLoading() {\n\n forceLoad();\n }", "public void registerWorldChunkManager() {\n\t\tthis.worldChunkMgr = new WorldChunkManagerHell(BiomeGenBase.sky, 0.5F, 0.0F);\n\t\tthis.dimensionId = 1;\n\t\tthis.hasNoSky = true;\n\t}", "public void registerWorldChunkManager()\n\t{\n\t\tthis.worldChunkMgr = new WorldChunkMangerHeaven(worldObj.getSeed(), terrainType);\n\t\tthis.hasNoSky = false;\n\t}", "public MyWorld()\n { \n // Create a new world with 600x400 cells with a cell size of 1x1 pixels.\n super(1078, 672, 1); \n preparePlayer1();\n preparePlayer2();\n prepareTitle();\n //playmusic();\n }", "@Mod.EventHandler\n public void preinit(FMLInitializationEvent event)\n {\n \tCOBIDs.ids();\n \t//Solid\n \tCSBIDs.ids();\n //Items\n \t//Gems\n \tGIDs.ids();\n //Copper\n \t//Ar\n \t//Ores\n \tCOIDs.ids();\n //Tools\n \t//Hoes\n \tCHIDs.ids();\n \t//Swords\n \tCSWIDs.ids();\n \t//SwordsSlot1\n \tCSWS1IDs.ids();\n \t//Pickaxes\n \tCPIDs.ids();\n \t//PikaxesSlot1\n \tCPS1IDs.ids();\n \t//Axes\n \tCAIDs.ids();\n\t\t//Shovel\n \tCSIDs.ids();\n \t\n //Reg\n //Blocks\n \t//Copper\n \tCOBReg.reg();\n \tCSBReg.reg();\n //Items\n \t//Gems\n \tGReg.reg();\n //Copper\n \t//Ore\n \tCOReg.reg();\n //Tools\n \t//Hoes\n \tCHReg.reg();\n \t//Swords\n \tCSWReg.reg();\n \t//SwordsSlot1\n \tCSWS1Reg.reg();\n \t//Pickaxes\n \tCPReg.reg();\n \t//PckaxesSlot1\n \tCPS1Reg.reg();\n \t//Axes\n \tCAReg.reg();\n \t//Shovel\n \tCSReg.reg();\n \t//Renders\n \tproxy.init();\n }", "@PreInit\n\tpublic void CodeLyokoPreLoad(FMLPreInitializationEvent preevt)\n\t{\n\t preevt.getModMetadata().version = \"0.4.3-Beta\";\n\t\tpreevt.getModMetadata().name = \"Code Lyoko Mod\";\n\t\tpreevt.getModMetadata().authorList.add(\"986523714\");\n\t\tpreevt.getModMetadata().authorList.add(\"Jadar\");\n\t\tpreevt.getModMetadata().authorList.add(\"catchaser9620\");\n\t\tpreevt.getModMetadata().authorList.add(\"wolfSpirit1st\");\n\t\tpreevt.getModMetadata().logoFile = \"/eye-xana.png\";\n\t\tpreevt.getModMetadata().modId = \"CodeLyoko\";\n\t\tpreevt.getModMetadata().url = \"http://www.minecraftforum.net/topic/1403995-151-code-lyoko-mod-042-minecraft-forum/\";\n\t\tpreevt.getModMetadata().description = \"Recreates the TV show Code Lyoko to the best of minecraft's cabilities.\";\n\t\t\n \tConfiguration config = new Configuration(preevt.getSuggestedConfigurationFile());\n\t\tconfig.load();\n\t\t\n\t\t// Blocks\n\t\tBlockIds.LYOKO_TOWER = config.getBlock(\"lyokoTower\", BlockIds.LYOKO_TOWER_DEFAULT).getInt();\n\t\tBlockIds.LYOKO_TOWER_BASE = config.getBlock(\"lyokoTowerBase\", BlockIds.LYOKO_TOWER_BASE_DEFAULT).getInt();\n\t\tBlockIds.LYOKO_GRASS = config.getBlock(\"lyokoGrass\", BlockIds.LYOKO_GRASS_DEFAULT).getInt();\n\t\tBlockIds.LYOKO_STONE = config.getBlock(\"lyokoStone\", BlockIds.LYOKO_STONE_DEFAULT).getInt();\n\t\tBlockIds.LYOKO_SAND = config.getBlock(\"lyokoSand\", BlockIds.LYOKO_SAND_DEFAULT).getInt();\n\t\tBlockIds.LYOKO_ICE = config.getBlock(\"lyokoIce\", BlockIds.LYOKO_ICE_DEFAULT).getInt();\n\t\tBlockIds.LYOKO_LOG = config.getBlock(\"lyokoLog\", BlockIds.LYOKO_LOG_DEFAULT).getInt();\n\t\tBlockIds.LYOKO_SEA_BLOCK = config.getBlock(\"lyokoSeaBlock\", BlockIds.LYOKO_SEA_BLOCK_DEFAULT).getInt();\n\t\tBlockIds.LYOKO_SEA_FLOWING = config.getBlock(\"lyokoSeaFlowing\", BlockIds.LYOKO_SEA_FLOWING_DEFAULT).getInt();\n\t\tBlockIds.LYOKO_SEA_STILL = config.getBlock(\"lyokoSeaStill\", BlockIds.LYOKO_SEA_STILL_DEFAULT).getInt();\n\t\tBlockIds.LYOKO_VIRTUAL_BLOCK = config.getBlock(\"lyokovirtualblock\", BlockIds.LYOKO_VIRTUAL_BLOCK_DEFAULT).getInt();\n\t\tBlockIds.LYOKO_CARTHAGE = config.getBlock(\"lyokoCarthage\", BlockIds.LYOKO_CARTHAGE_DEFAULT).getInt();\n\t\tBlockIds.LYOKO_ORE = config.getBlock(\"lyokoOre\", BlockIds.LYOKO_ORE_DEFAULT).getInt();\n\t\tBlockIds.LYOKO_ICE_PORTAL = config.getBlock(\"lyokoPolarPortal\", BlockIds.LYOKO_ICE_PORTAL_DEFAULT).getInt();\n\t\tBlockIds.LYOKO_DESERT_PORTAL = config.getBlock(\"lyokoDesertPortal\", BlockIds.LYOKO_DESERT_PORTAL_DEFAULT).getInt();\n\t\tBlockIds.LYOKO_FOREST_PORTAL = config.getBlock(\"lyokoForestPortal\", BlockIds.LYOKO_FOREST_PORTAL_DEFAULT).getInt();\n\t\tBlockIds.LYOKO_MOUNTAIN_PORTAL = config.getBlock(\"lyokoMountainPortal\", BlockIds.LYOKO_MOUNTAIN_PORTAL_DEFAULT).getInt();\n\t\tBlockIds.LYOKO_CARTHAGE_PORTAL = config.getBlock(\"lyokoCarthagePortal\", BlockIds.LYOKO_CARTHAGE_PORTAL_DEFAULT).getInt();\n\t\tBlockIds.LYOKO_URANIUM_ORE = config.getBlock(\"lyokoUraniumOre\", BlockIds.LYOKO_URANIUM_ORE_DEFAULT).getInt();\n\t\tBlockIds.LYOKO_SUPER_CALC = config.getBlock(\"lyokoSuperCalculator\", BlockIds.LYOKO_SUPER_CALC_DEFAULT).getInt();\n\t\tBlockIds.LYOKO_LEAD_ORE = config.getBlock(\"lyokoLeadOre\", BlockIds.LYOKO_LEAD_ORE_DEFAULT).getInt();\n\t\tBlockIds.LYOKO_MARABOUNTA = config.getBlock(\"marabounta\", BlockIds.LYOKO_MARABOUNTA_DEFAULT).getInt();\n\t\tBlockIds.TOWER_CONSOLE = config.getBlock(\"towerConsole\", BlockIds.TOWER_CONSOLE_DEFAULT).getInt();\n\t\tBlockIds.TOWER_FLOOR = config.getBlock(\"towerWall\", BlockIds.TOWER_FLOOR_DEFAULT).getInt();\n\t\tBlockIds.CABLE = config.getBlock(\"cable\", BlockIds.CABLE_DEFAULT).getInt();\n\t\t\n\t\t// Items\n\t\tItemIds.WEAPON_LYOKO_1 = config.getItem(\"weaponLyoko1\", ItemIds.WEAPON_LYOKO_1_DEFAULT).getInt();\n\t\tItemIds.WEAPON_LYOKO_2 = config.getItem(\"weaponLyoko2\", ItemIds.WEAPON_LYOKO_2_DEFAULT).getInt();\n\t\tItemIds.WEAPON_LYOKO_3 = config.getItem(\"weaponLyoko3\", ItemIds.WEAPON_LYOKO_3_DEFAULT).getInt();\n\t\tItemIds.WEAPON_LYOKO_4 = config.getItem(\"weaponLyoko4\", ItemIds.WEAPON_LYOKO_4_DEFAULT).getInt();\n\t\tItemIds.WEAPON_LYOKO_5 = config.getItem(\"weaponLyoko5\", ItemIds.WEAPON_LYOKO_5_DEFAULT).getInt();\n\t\tItemIds.WEAPON_LYOKO_6 = config.getItem(\"weaponLyoko6\", ItemIds.WEAPON_LYOKO_6_DEFAULT).getInt();\n\t\tItemIds.ITEM_SKID = config.getItem(\"itemLyoko1\", ItemIds.ITEM_SKID_DEFAULT).getInt();\n\t\tItemIds.ITEM_OVERBOARD = config.getItem(\"itemOverboard\", ItemIds.ITEM_OVERBOARD_DEFAULT).getInt();\n\t\tItemIds.ITEM_QUANTUM_MATRIX = config.getItem(\"itemQuantumMatrix\", ItemIds.ITEM_QUANTUM_MATRIX_DEFAULT).getInt();\n\t\tItemIds.ITEM_QUANTUM_CONTAINMENT_CELL = config.getItem(\"itemQuantumContainmentCell\", ItemIds.ITEM_QUANTUM_CONTAINMENT_CELL_DEFAULT).getInt();\n\t\tItemIds.NOT_USED4 = config.getItem(\"itemLyoko5\", ItemIds.NOT_USED4_DEFAULT).getInt();\n\t\tItemIds.NOT_USED5 = config.getItem(\"itemLyoko6\", ItemIds.NOT_USED5_DEFAULT).getInt();\n\t\tItemIds.NOT_USED6 = config.getItem(\"itemLyoko7\", ItemIds.NOT_USED6_DEFAULT).getInt();\n\t\tItemIds.NOT_USED7 = config.getItem(\"itemLyoko8\", ItemIds.NOT_USED7_DEFAULT).getInt();\n\t\tItemIds.NOT_USED8 = config.getItem(\"itemLyoko9\", ItemIds.NOT_USED8_DEFAULT).getInt();\n\t\tItemIds.NOT_USED9 = config.getItem(\"itemLyoko10\", ItemIds.NOT_USED9_DEFAULT).getInt();\n\t\tItemIds.ITEM_LYOKO_URANIUM = config.getItem(\"itemLyokoUranium\", ItemIds.ITEM_LYOKO_URANIUM_DEFAULT).getInt();\n\t\tItemIds.ITEM_LYOKO_11 = config.getItem(\"itemLyoko11\", ItemIds.ITEM_LYOKO_11_DEFAULT).getInt();\n\t\tItemIds.ITEM_LYOKO_12 = config.getItem(\"itemLyoko12\", ItemIds.ITEM_LYOKO_12_DEFAULT).getInt();\n\t\tItemIds.ITEM_LYOKO_13 = config.getItem(\"itemLyoko13\", ItemIds.ITEM_LYOKO_13_DEFAULT).getInt();\n\t\tItemIds.ITEM_LYOKO_14 = config.getItem(\"itemLyoko14\", ItemIds.ITEM_LYOKO_14_DEFAULT).getInt();\n\t\tItemIds.ITEM_LYOKO_15 = config.getItem(\"itemLyoko15\", ItemIds.ITEM_LYOKO_15_DEFAULT).getInt();\n\t\tItemIds.AELITA_ARMOR_HELMET = config.getItem(\"aelitaArmorHelmet\", ItemIds.AELITA_ARMOR_HELMET_DEFAULT).getInt();\n\t\tItemIds.AELITA_ARMOR_CHEST = config.getItem(\"aelitaArmorChest\", ItemIds.AELITA_ARMOR_CHEST_DEFAULT).getInt();\n\t\tItemIds.AELITA_ARMOR_PANTS = config.getItem(\"aelitaArmorPants\", ItemIds.AELITA_ARMOR_PANTS_DEFAULT).getInt();\n\t\tItemIds.AELITA_ARMOR_BOOTS = config.getItem(\"aelitaArmorBoots\", ItemIds.AELITA_ARMOR_BOOTS_DEFAULT).getInt();\n\t\tItemIds.ODD_ARMOR_HELMET = config.getItem(\"oddArmorHelmet\", ItemIds.ODD_ARMOR_HELMET_DEFAULT).getInt();\n\t\tItemIds.ODD_ARMOR_CHEST = config.getItem(\"oddArmorChest\", ItemIds.ODD_ARMOR_CHEST_DEFAULT).getInt();\n\t\tItemIds.ODD_ARMOR_PANTS = config.getItem(\"oddArmorPants\", ItemIds.ODD_ARMOR_PANTS_DEFAULT).getInt();\n\t\tItemIds.ODD_ARMOR_BOOTS = config.getItem(\"oddArmorBoots\", ItemIds.ODD_ARMOR_BOOTS_DEFAULT).getInt();\n\t\tItemIds.ULRICH_ARMOR_HELMET = config.getItem(\"ulrichArmorHelmet\", ItemIds.ULRICH_ARMOR_HELMET_DEFAULT).getInt();\n\t\tItemIds.ULRICH_ARMOR_CHEST = config.getItem(\"ulrichArmorChest\", ItemIds.ULRICH_ARMOR_CHEST_DEFAULT).getInt();\n\t\tItemIds.ULRICH_ARMOR_PANTS = config.getItem(\"ulrichArmorPants\", ItemIds.ULRICH_ARMOR_PANTS_DEFAULT).getInt();\n\t\tItemIds.ULRICH_ARMOR_BOOTS = config.getItem(\"ulrichArmorBoots\", ItemIds.ULRICH_ARMOR_BOOTS_DEFAULT).getInt();\n\t\tItemIds.YUMI_ARMOR_HELMET = config.getItem(\"yumiArmorHelmet\", ItemIds.YUMI_ARMOR_HELMET_DEFAULT).getInt();\n\t\tItemIds.YUMI_ARMOR_CHEST = config.getItem(\"yumiArmorChest\", ItemIds.YUMI_ARMOR_CHEST_DEFAULT).getInt();\n\t\tItemIds.YUMI_ARMOR_PANTS = config.getItem(\"yumiArmorPants\", ItemIds.YUMI_ARMOR_PANTS_DEFAULT).getInt();\n\t\tItemIds.YUMI_ARMOR_BOOTS = config.getItem(\"yumiArmorBoots\", ItemIds.YUMI_ARMOR_BOOTS_DEFAULT).getInt();\n\t\tItemIds.WILLIAM_ARMOR_HELMET = config.getItem(\"williamArmorHelmet\", ItemIds.WILLIAM_ARMOR_HELMET_DEFAULT).getInt();\n\t\tItemIds.WILLIAM_ARMOR_CHEST = config.getItem(\"williamArmorChest\", ItemIds.WILLIAM_ARMOR_CHEST_DEFAULT).getInt();\n\t\tItemIds.WILLIAM_ARMOR_PANTS = config.getItem(\"williamArmorPants\", ItemIds.WILLIAM_ARMOR_PANTS_DEFAULT).getInt();\n\t\tItemIds.WILLIAM_ARMOR_BOOTS = config.getItem(\"williamArmorBoots\", ItemIds.WILLIAM_ARMOR_BOOTS_DEFAULT).getInt();\n\t\tItemIds.DATA_FRAGMENT = config.getItem(\"dataFragment\", ItemIds.DATA_FRAGMENT_DEFAULT).getInt();\n\t\tItemIds.ITEM_LYOKO_URANIUM_CELL = config.getItem(\"itemLyokoUraniumCell\", ItemIds.ITEM_LYOKO_URANIUM_CELL_DEFAULT).getInt();\n\t\tItemIds.ITEM_LYOKO_DEPLETED_URANIUM = config.getItem(\"itemLyokoDepletedUranium\", ItemIds.ITEM_LYOKO_DEPLETED_URANIUM_DEFAULT).getInt();\n\t\t\n enableAdminPowers = config.get(Configuration.CATEGORY_GENERAL, \"enableAdminPowers\", false).getBoolean(false);\n\t\t\n\t\tDimensionIds.ICE = config.get(Configuration.CATEGORY_GENERAL, \"polarSectorID\", DimensionIds.ICE_DEFAULT).getInt();\n\t\tDimensionIds.MOUNTAIN = config.get(Configuration.CATEGORY_GENERAL, \"mountainSectorID\", DimensionIds.MOUNTAIN_DEFAULT).getInt();\n\t\tDimensionIds.FOREST = config.get(Configuration.CATEGORY_GENERAL, \"forestSectorID\", DimensionIds.FOREST_DEFAULT).getInt();\n\t\tDimensionIds.DESERT = config.get(Configuration.CATEGORY_GENERAL, \"desertSectorID\", DimensionIds.DESERT_DEFAULT).getInt();\n\t\tDimensionIds.CARTHAGE = config.get(Configuration.CATEGORY_GENERAL, \"carthageSectorID\", DimensionIds.CARTHAGE_DEFAULT).getInt();\n\t\t\n\t\tconfig.save();\n\t}", "public abstract void loaded();", "@Override\n protected void onStartLoading() {\n forceLoad();\n\n }", "public void updateTick(World p_149674_1_, int p_149674_2_, int p_149674_3_, int p_149674_4_, Random p_149674_5_) {\n\t\tif (!p_149674_1_.isRemote) {\n\t\t\tthis.func_149830_m(p_149674_1_, p_149674_2_, p_149674_3_, p_149674_4_);\n\t\t}\n\t}", "public void onWorldLoad(Minecraft minecraft, WorldClient world, String message);", "@Override\r\n\t\tprotected void onTick() {\n\r\n\t\t}", "@Override\n\tpublic void registerWorldChunkManager() {\n\t\tworldChunkMgr = new zei_WorldChunkManagerZeitgeist(giants, worldObj);\n\t\tworldType = 99;\n\t\thasNoSky = false;\n\t}", "@Override\n public void onTick(long arg0) {\n }", "protected void init() {\n eachModule(ModuleHandler.INSTANCE::depends);\n \n // init, only enabled modules are run\n eachEnabledModule(ModuleHandler.INSTANCE::init);\n \n // listen for server world loading events\n // LoadWorldCallback.EVENT.register(server -> eachEnabledModule(m ->\n // m.loadWorld(server)));\n }", "public static void preInit() {\n registerBlocks();\n }", "public void loaded(){\n\t\tloaded=true;\n\t}", "public interface Chunk extends PersistentDataHolder {\r\n\r\n /**\r\n * Gets the X-coordinate of this chunk\r\n *\r\n * @return X-coordinate\r\n */\r\n int getX();\r\n\r\n /**\r\n * Gets the Z-coordinate of this chunk\r\n *\r\n * @return Z-coordinate\r\n */\r\n int getZ();\r\n\r\n /**\r\n * Gets the world containing this chunk\r\n *\r\n * @return Parent World\r\n */\r\n @NotNull\r\n World getWorld();\r\n\r\n /**\r\n * Gets a block from this chunk\r\n *\r\n * @param x 0-15\r\n * @param y 0-255\r\n * @param z 0-15\r\n * @return the Block\r\n */\r\n @NotNull\r\n Block getBlock(int x, int y, int z);\r\n\r\n /**\r\n * Capture thread-safe read-only snapshot of chunk data\r\n *\r\n * @return ChunkSnapshot\r\n */\r\n @NotNull\r\n ChunkSnapshot getChunkSnapshot();\r\n\r\n /**\r\n * Capture thread-safe read-only snapshot of chunk data\r\n *\r\n * @param includeMaxblocky - if true, snapshot includes per-coordinate\r\n * maximum Y values\r\n * @param includeBiome - if true, snapshot includes per-coordinate biome\r\n * type\r\n * @param includeBiomeTempRain - if true, snapshot includes per-coordinate\r\n * raw biome temperature and rainfall\r\n * @return ChunkSnapshot\r\n */\r\n @NotNull\r\n ChunkSnapshot getChunkSnapshot(boolean includeMaxblocky, boolean includeBiome, boolean includeBiomeTempRain);\r\n\r\n /**\r\n * Get a list of all entities in the chunk.\r\n *\r\n * @return The entities.\r\n */\r\n @NotNull\r\n Entity[] getEntities();\r\n\r\n /**\r\n * Get a list of all tile entities in the chunk.\r\n *\r\n * @return The tile entities.\r\n */\r\n @NotNull\r\n BlockState[] getTileEntities();\r\n\r\n /**\r\n * Checks if the chunk is loaded.\r\n *\r\n * @return True if it is loaded.\r\n */\r\n boolean isLoaded();\r\n\r\n /**\r\n * Loads the chunk.\r\n *\r\n * @param generate Whether or not to generate a chunk if it doesn't\r\n * already exist\r\n * @return true if the chunk has loaded successfully, otherwise false\r\n */\r\n boolean load(boolean generate);\r\n\r\n /**\r\n * Loads the chunk.\r\n *\r\n * @return true if the chunk has loaded successfully, otherwise false\r\n */\r\n boolean load();\r\n\r\n /**\r\n * Unloads and optionally saves the Chunk\r\n *\r\n * @param save Controls whether the chunk is saved\r\n * @return true if the chunk has unloaded successfully, otherwise false\r\n */\r\n boolean unload(boolean save);\r\n\r\n /**\r\n * Unloads and optionally saves the Chunk\r\n *\r\n * @return true if the chunk has unloaded successfully, otherwise false\r\n */\r\n boolean unload();\r\n\r\n /**\r\n * Checks if this chunk can spawn slimes without being a swamp biome.\r\n *\r\n * @return true if slimes are able to spawn in this chunk\r\n */\r\n boolean isSlimeChunk();\r\n\r\n /**\r\n * Gets whether the chunk at the specified chunk coordinates is force\r\n * loaded.\r\n * <p>\r\n * A force loaded chunk will not be unloaded due to lack of player activity.\r\n *\r\n * @return force load status\r\n * @see World#isChunkForceLoaded(int, int)\r\n */\r\n boolean isForceLoaded();\r\n\r\n /**\r\n * Sets whether the chunk at the specified chunk coordinates is force\r\n * loaded.\r\n * <p>\r\n * A force loaded chunk will not be unloaded due to lack of player activity.\r\n *\r\n * @param forced force load status\r\n * @see World#setChunkForceLoaded(int, int, boolean)\r\n */\r\n void setForceLoaded(boolean forced);\r\n\r\n /**\r\n * Adds a plugin ticket for this chunk, loading this chunk if it is not\r\n * already loaded.\r\n * <p>\r\n * A plugin ticket will prevent a chunk from unloading until it is\r\n * explicitly removed. A plugin instance may only have one ticket per chunk,\r\n * but each chunk can have multiple plugin tickets.\r\n * </p>\r\n *\r\n * @param plugin Plugin which owns the ticket\r\n * @return {@code true} if a plugin ticket was added, {@code false} if the\r\n * ticket already exists for the plugin\r\n * @throws IllegalStateException If the specified plugin is not enabled\r\n * @see World#addPluginChunkTicket(int, int, Plugin)\r\n */\r\n boolean addPluginChunkTicket(@NotNull Plugin plugin);\r\n\r\n /**\r\n * Removes the specified plugin's ticket for this chunk\r\n * <p>\r\n * A plugin ticket will prevent a chunk from unloading until it is\r\n * explicitly removed. A plugin instance may only have one ticket per chunk,\r\n * but each chunk can have multiple plugin tickets.\r\n * </p>\r\n *\r\n * @param plugin Plugin which owns the ticket\r\n * @return {@code true} if the plugin ticket was removed, {@code false} if\r\n * there is no plugin ticket for the chunk\r\n * @see World#removePluginChunkTicket(int, int, Plugin)\r\n */\r\n boolean removePluginChunkTicket(@NotNull Plugin plugin);\r\n\r\n /**\r\n * Retrieves a collection specifying which plugins have tickets for this\r\n * chunk. This collection is not updated when plugin tickets are added or\r\n * removed to this chunk.\r\n * <p>\r\n * A plugin ticket will prevent a chunk from unloading until it is\r\n * explicitly removed. A plugin instance may only have one ticket per chunk,\r\n * but each chunk can have multiple plugin tickets.\r\n * </p>\r\n *\r\n * @return unmodifiable collection containing which plugins have tickets for\r\n * this chunk\r\n * @see World#getPluginChunkTickets(int, int)\r\n */\r\n @NotNull\r\n Collection<Plugin> getPluginChunkTickets();\r\n\r\n /**\r\n * Gets the amount of time in ticks that this chunk has been inhabited.\r\n *\r\n * Note that the time is incremented once per tick per player in the chunk.\r\n *\r\n * @return inhabited time\r\n */\r\n long getInhabitedTime();\r\n\r\n /**\r\n * Sets the amount of time in ticks that this chunk has been inhabited.\r\n *\r\n * @param ticks new inhabited time\r\n */\r\n void setInhabitedTime(long ticks);\r\n\r\n /**\r\n * Tests if this chunk contains the specified block.\r\n *\r\n * @param block block to test\r\n * @return if the block is contained within\r\n */\r\n boolean contains(@NotNull BlockData block);\r\n}", "public void setLoaded();", "@Override\n\tprotected void load() {\n\t\tisPageLoaded = true;\n\t}", "@Override\n public void world() {\n super.world();\n }", "public static void start(){\n new Light(new Vector3f(getSIZE()*Chunk.getCHUNKSIZE()/2,getSIZE()*Chunk.getCHUNKSIZE()/2,getSIZE()*Chunk.getCHUNKSIZE()/2));\n Keyboard.enableRepeatEvents(true);\n createWindow();\n initGL();\n generateWorld();\n Game.gameLoop();\n }", "void minecraftChunkUnloaded() {\n\t\tthis.lastUnloadingTime = System.currentTimeMillis();\n\t}", "@Override\n\tpublic void init(GameContainer container) throws SlickException {\n\t\tloadWorld();\n\t\tTiles.loadTiles();\n\t}", "public Chunk loadChunk(int par1, int par2)\n {\n return this.provideChunk(par1, par2);\n }", "@EventHandler\n\tpublic void preInit(FMLPreInitializationEvent event) {\n\t\t\n\t\tlogger = event.getModLog();\n\t\t\n\t\tAlmagestData.loadConigulation(event.getSuggestedConfigurationFile());\n\t\t\n\t\t// for mod's specific data.\n\t\tHelperConstellation.registerStarData(event);\n\t\tPacketHandler.registerPre();\n\t\t\n\t\t// for items and blocks.\n\t\tAlmagestData.registerPre();\n\t\tproxy.registerPre();\n\t\tproxy.registerEntities();\n\t\t\n\t\tMinecraftForge.EVENT_BUS.register(savedDataManager);\n\t\t\n\t}", "public static void initialize()\n {\n CHUNK_LOADER = new ChunkLoader();\n //VILLAGE_INDICATOR = new VillageIndicator();\n\n BLOCK_LIST.add(CHUNK_LOADER);\n //BLOCK_LIST.add(VILLAGE_INDICATOR);\n Log.info(\"=========================================================> Initialized Blocks\");\n }", "@Override\n\tpublic void loadPlayer() {\n\t\t\n\t}", "@Override\n\tpublic void loadPlayerCannons() {\n\t\t\n\t}", "public World() {\n\t\tbackgroundLoader.submit(new Callable<Object>() {\n\t\t\t@Override\n\t\t\tpublic Object call() throws Exception {\n\t\t\t\tItemDefinition.load();\n\t\t\t\treturn null;\n\t\t\t}\n\t\t});\n\t\tbackgroundLoader.submit(new Callable<Object>() {\n\t\t\t@Override\n\t\t\tpublic Object call() throws Exception {\n\t\t\t\tNPCDefinition.load();\n\t\t\t\tNPCStyle.init();\n\t\t\t\treturn null;\n\t\t\t}\n\t\t});\n\t\tbackgroundLoader.submit(new Callable<Object>() {\n\t\t\t@Override\n\t\t\tpublic Object call() throws Exception {\n\t\t\t\tDegradeSystem.init();\n\t\t\t\tProjectileManager.init();\n\t\t\t\treturn null;\n\t\t\t}\n\t\t});\n\t\tbackgroundLoader.submit(new Callable<Object>() {\n\t\t\t@Override\n\t\t\tpublic Object call() throws Exception {\n\t\t\t\tShops.loadShopFile();\n\t\t\t\treturn null;\n\t\t\t}\n\t\t});\n\t}", "@EventHandler\n public void preInit(FMLInitializationEvent event)\n {\n \tWorldType.DEFAULT = new TUMWorldType(\"TUMDefault\");\n\n \tDimensionManager.unregisterDimension(-1);\n \tDimensionManager.unregisterDimension(0);\n \tDimensionManager.unregisterDimension(1);\n \tDimensionManager.unregisterProviderType(-1);\n \tDimensionManager.unregisterProviderType(0);\n \tDimensionManager.unregisterProviderType(1);\n \t\n \tDimensionManager.registerProviderType(0, TUMProvider.class, true);\n \tDimensionManager.registerDimension(0, 0);\n }", "public void onModuleLoad() {\n \t\tMainPage.currentPage = this;\n \t\t\n \t\tif(Window.Location.getHash().length() == 0){\n \t\t\tloggedIn = false;\n \t\t}else{\n \t\t\tloggedIn = true;\n \t\t}\n \t\t\n \t\tinitUI();\n \t\t\n \t\tif(loggedIn){\n \t\t\tsetStatus(\"fetching JSON...\", false);\n \t\t\tfbFetcher.fetchNeededJSON();\n \t\t}\n \t\t\n \t}", "public void loadContent(){\n\t\tspriteBatch = new SpriteBatch(getGraphicsDevice());\n\t\t//TODO: put content loading code here\n\t\t\n\t}", "@Override\n public void onTick() {\n \n }", "void loadChunk(Reader reader, ScriptContext scriptContext)\n\t\t\tthrows ScriptException {\n\t\tloadChunk(new ReaderInputStream(reader), scriptContext);\n\t}", "@Override\n\tpublic void init() {\n\t\tworld = new World(gsm);\n\t\tworld.init();\n\t\t\n\t\tif(worldName == null){\n\t\t\tworldName = \"null\";\n\t\t\tmap_name = \"map\";\n\t\t} \n\t\tworld.generate(map_name);\n\t}", "public static void\tload(FMLServerStartingEvent event)\r\n\t{\n\t}", "public void onModuleLoad() {\n\t\tMaps.loadMapsApi(\"notsupplied\", \"2\", false, new Runnable() {\n\t\t\tpublic void run() {\n\t\t\t\tbuildUi();\n\t\t\t}\n\t\t});\n\t}", "public void startEngine() {\n if (!isLoaded) {\n currentSpeed = 0.1;\n }\n }", "@Override\r\n\tpublic void initialLoad() throws IOException {\n\t\t\r\n\t}", "@Override\n\tpublic void onProxyBeforePreInit(Abstract_Mod aMod, FMLPreInitializationEvent aEvent) {\n\t\tnew DefaultAnimations();\n\t}", "@Override\n\t\t\t\t\tpublic void beginLoad(int type) {\n\n\t\t\t\t\t}", "private void loadingPhase() {\n try { Thread.sleep(10000); } catch(InterruptedException e) { return; }\n ClickObserver.getInstance().setTerrainFlag(\"\");\n }", "private void generateNextChunk() {\n \n chunkNumber++;\n \n // generate a chunk filled with content\n List<Object> list = chunkFactory.generateChunk(chunkNumber);\n Vector3f newChunkPosition =\n new Vector3f(nextChunkX, 0f, 0f);\n nextChunkX += P.chunkLength;\n\n for (Object object : list) {\n if (object instanceof Spatial) {\n Spatial spatial = (Spatial) object;\n addToLevel(spatial, spatial.getLocalTranslation().add(newChunkPosition));\n } else if (object instanceof SpotLight) {\n SpotLight light = (SpotLight) object;\n addToLevel(light, light.getPosition().add(newChunkPosition));\n } else if (object instanceof PointLight) {\n PointLight light = (PointLight) object;\n addToLevel(light, light.getPosition().add(newChunkPosition)); \n }\n }\n\n }", "@Override\n public void onLoad(String url) {\n \n }", "public Chunk loadChunk(int par1, int par2)\n {\n return provideChunk(par1, par2);\n }", "@Override\n\tpublic Engine onLoadEngine() {\n\t\tToast.makeText(this, \"You move my sprite right round, right round...\", Toast.LENGTH_LONG).show();\n\t\tthis.mCamera = new Camera(0, 0, CAMERA_WIDTH, CAMERA_HEIGHT);\n\t\treturn new Engine(new EngineOptions(true, ScreenOrientation.LANDSCAPE, new RatioResolutionPolicy(CAMERA_WIDTH, CAMERA_HEIGHT), this.mCamera));\n\t}", "public void randomDisplayTick(yc world, int i, int j, int k, Random random) {}", "public void Load() {\n\t\tsceneLoaded = false;\n\n\t\tfor (int i = 0 ; i < gameObjects.size();i++) {\n\t\t\tGameObject gO = gameObjects.get(i);\n\t\t\tEngine.Instance.AddObject(gO);\n\n\t\t}\n\t\tEngine.Instance.currentScenes.add(this);\n\t\tsceneLoaded = true;\n\t}", "@EventHandler(ignoreCancelled = true)\n\tpublic void onChunkLoad(ChunkLoadEvent e) {\n\t\tChunk chunk = e.getChunk();\n\t\t\n\t\tCropControl.getDAO().getChunk(chunk);\n\n\t}", "@Override\n protected void onPreExecute() {\n super.onPreExecute();\n gD.callload(context, nScreenHeight);\n\n\n\n }", "@Override\r\n\tpublic void tileLoadedHandler(Tile tile) {\n\r\n\t}", "public void onRenderTick() {\n updateLang();\n updateRenderEngine();\n }", "private static void generateWorld(){\n for(int i = 0; i < SIZE*SIZE; i++){\n new Chunk();\n }\n }", "public void onLoad()\n {\n saveDefaultConfig();\n\n // Get the lobby name\n chatManager = new ChatManager(this);\n lobby = getConfig().getString(\"lobby\");\n\n // Loading up needed classes\n worldManager = new WorldManager(this);\n\n boolean backupsFound = false;\n\n File backupDir = new File(getDataFolder(), \"backups\");\n if (!backupDir.exists()) {\n getLogger().info(\"No backup directory found; creating one now.\");\n getLogger().info(\"Place world folders you want to reset from in '.../plugins/SkyblockWarriors/backups'\");\n backupDir.mkdirs();\n } else {\n for (File backup : backupDir.listFiles()) {\n if ((backup.isDirectory()) && (backup.listFiles().length != 0)) {\n backupsFound = true;\n }\n }\n\n if (backupsFound) {\n getLogger().info(\"Found backup folder, attempting to reset the world..\");\n // Resetting the world\n worldManager.resetWorld();\n } else {\n if (!getConfig().getBoolean(\"arena-setup\") == false) {\n getLogger().info(\"The plugin should be setup, please copy the world into the backup folder\");\n getLogger().info(\"so the plugin can reset the world on each restart!\");\n }\n }\n }\n }", "@Override\r\n public void preInit(FMLPreInitializationEvent e) {\n \tModBlocks.registerBlockModels();\r\n \tnet.minecraftforge.fml.client.registry.RenderingRegistry.registerEntityRenderingHandler(EntityTribeling.class, RenderTribeling.FACTORY);\r\n super.preInit(e);\r\n }", "public MyWorld()\n { \n super(1200, 600, 1); \n prepare();\n bienvenida();\n instrucciones();\n sonido();\n }", "private void onModuleUpdate() {\n //!\n //! Calculate the initial time of the frame.\n //!\n mTime = GLFW.glfwGetTime();\n\n do {\n //!\n //! Render until the display is not active.\n //!\n onModuleRender(GLFW.glfwGetTime());\n } while (mDisplay.isActive());\n }", "private static void load(){\n }" ]
[ "0.70385545", "0.6636415", "0.62642217", "0.6258453", "0.6255058", "0.61173946", "0.611193", "0.59749174", "0.5927977", "0.5876771", "0.583723", "0.58276814", "0.58276343", "0.5787839", "0.5772977", "0.5761104", "0.5732423", "0.57020444", "0.56767356", "0.56740147", "0.5670409", "0.5667836", "0.56582737", "0.56561816", "0.56494504", "0.56280255", "0.56187594", "0.561438", "0.5594388", "0.55917585", "0.5581252", "0.55555195", "0.5526345", "0.5506529", "0.54966164", "0.5491611", "0.5477872", "0.546401", "0.54625857", "0.54479355", "0.5438545", "0.5436449", "0.5436221", "0.5426179", "0.54203546", "0.54168", "0.54152477", "0.5411732", "0.5405584", "0.5400789", "0.53879005", "0.538244", "0.5381131", "0.5376483", "0.5360524", "0.5358797", "0.5351416", "0.5350439", "0.5350388", "0.53361887", "0.5332862", "0.53301936", "0.5328413", "0.53117913", "0.5288605", "0.5285306", "0.52774006", "0.5275326", "0.5274086", "0.52726924", "0.52726275", "0.5271066", "0.5268138", "0.5258175", "0.52540404", "0.5246049", "0.5246009", "0.5244196", "0.5239353", "0.5236897", "0.5235669", "0.5234266", "0.5229171", "0.52280754", "0.52249926", "0.5223118", "0.5211911", "0.5193088", "0.51865137", "0.5179708", "0.5176367", "0.517517", "0.5164929", "0.5164081", "0.5161121", "0.51596373", "0.5154419", "0.5152432", "0.51420003", "0.51399875", "0.5138584" ]
0.0
-1
Java boolean lar icin getter olustururken "is" ile baslar. setter lara degisiklik yok
public boolean isZengin() { return zengin; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public boolean getBoolean();", "boolean getBoolean();", "boolean getBoolean();", "boolean get();", "void set(boolean value);", "boolean getBoolValue();", "boolean getBoolValue();", "abstract public boolean getAsBoolean();", "public void set(boolean bol);", "boolean isSetValue();", "boolean isSetValue();", "void setBoolean(boolean value);", "boolean getValue();", "public void setDirezione(boolean direzione) {\n\r\n }", "boolean getSet();", "public void set()\r\n {\r\n isSet = true;\r\n }", "public abstract boolean read_boolean();", "protected Boolean geBoolValue() {\n return boolValue;\n }", "public boolean getValue();", "public Boolean getBooleanAttribute();", "public boolean isGettersOfBoolean() {\n final boolean result = cbBoolean.getModel().isSelected();\n paramBoolean = result;\n return result;\n }", "public boolean getEstado(){\n return estado;\n }", "public void testSetBoolean() {\n ValueString vs = new ValueString();\n\n vs.setBoolean(false);\n assertEquals(\"N\", vs.getString());\n vs.setBoolean(true);\n assertEquals(\"Y\", vs.getString());\n }", "BooleanProperty getOn();", "public void setTallied(java.lang.Boolean value);", "public void onChanged(Boolean bool) {\n if (bool != null) {\n C41389o oVar = this.f107704a;\n C7573i.m23582a((Object) bool, \"it\");\n oVar.mo102021a(bool.booleanValue());\n }\n }", "@Test\r\n public void testSetMatin() {\r\n System.out.println(\"*****************\");\r\n System.out.println(\"Test : setMatin\");\r\n boolean matin = false;\r\n Cours_Reservation instance = new Cours_Reservation();\r\n instance.setMatin(matin);\r\n assertEquals(matin, instance.isMatin());\r\n }", "public void setIsModifier(java.lang.Boolean value);", "public boolean getMyBool() {\n return myBool;\n }", "public Boolean getBooleanValue() {\n return this.booleanValue;\n }", "public void setData(boolean isData);", "public Boolean getDescTraslado(){\n return this.descTraslado;\n }", "public void setProcessed (boolean Processed)\n{\nset_Value (\"Processed\", new Boolean(Processed));\n}", "void set(boolean on);", "public boolean getBoolValue() {\n return boolValue_;\n }", "public Boolean getValue() {\n/* 60 */ return Boolean.valueOf(this.val);\n/* */ }", "private BooleanValueProvider() {\n this.state = true;\n }", "public abstract void setInput(boolean value);", "public void setI(boolean i) {\n\tthis.i = i;\n }", "public boolean getBoolean(){\r\n try{return kd.getJSONObject(ug).getBoolean(udn);}\r\n catch(JSONException e){return false;}\r\n }", "void setSet(boolean set);", "public void onChanged(Boolean bool) {\n int i;\n if (bool != null) {\n LocationActivitySettingItem a = this.f107703a.mo102020a();\n C7573i.m23582a((Object) bool, \"it\");\n if (bool.booleanValue()) {\n i = 0;\n } else {\n i = 8;\n }\n a.setVisibility(i);\n }\n }", "public void setValue(boolean value) {\n this.value = value;\n }", "public boolean getAI(){return ai;}", "boolean getIsChecked();", "public Boolean getIndicadorFactura()\r\n/* 697: */ {\r\n/* 698:765 */ return this.indicadorFactura;\r\n/* 699: */ }", "boolean readBoolean();", "public void setI_IsImported (boolean I_IsImported);", "public boolean getBoolValue() {\n return boolValue_;\n }", "public void setRequiresTaxCertificate (boolean RequiresTaxCertificate)\n{\nset_Value (COLUMNNAME_RequiresTaxCertificate, Boolean.valueOf(RequiresTaxCertificate));\n}", "public BooleanStateValue( boolean value, boolean isImmortal) {\n\t\tsuper( isImmortal);\n\t\t_storage = value;\n\t}", "public void setS ( boolean s ) {\n\n\tthis.s = s;\n }", "@Column(name = \"BOOLEAN_VALUE\", length = 20)\n/* 35 */ public String getBooleanValue() { return this.booleanValue; }", "public boolean isBool() {\n return bool;\n }", "public void setA ( boolean a ) {\n\n\tthis.a = a;\n }", "public abstract void setBooleanImpl(String str, boolean z, Resolver<Void> resolver);", "void setBoolean(String key, boolean val);", "public Boolean getABoolean()\n {\n return aBoolean;\n }", "public void setMyBool(boolean myBoolIn) {\n myBool = myBoolIn;\n }", "public interface IBooleanProperty {\n /**\n * A simple implementation that holds its own state.\n */\n class WithState implements IBooleanProperty {\n private boolean value;\n\n public WithState(boolean value) {\n this.value = value;\n }\n\n @Override\n public boolean getBoolean() {\n return this.value;\n }\n\n @Override\n public void setBoolean(boolean value) {\n this.value = value;\n }\n\n @Override\n public boolean isValidBoolean(boolean value) {\n return true;\n }\n }\n\n /**\n * Get the boolean value.\n * @return the boolean value\n */\n boolean getBoolean();\n\n /**\n * Set the boolean value, regardless of it being a valid value or not.\n * The validity of the boolean value should be evaluated with isValidBoolean.\n * @param value the boolean value\n */\n void setBoolean(boolean value);\n\n /**\n * Returns true if the boolean value is valid.\n * @param value the boolean value\n * @return true if the boolean value is valid\n */\n boolean isValidBoolean(boolean value);\n\n /**\n * Try to set the boolean value. Returns true if it succeeded.\n * @param value the boolean value\n * @return true if it succeeded\n */\n default boolean trySetBoolean(boolean value) {\n if (this.isValidBoolean(value)) {\n this.setBoolean(value);\n return true;\n } else {\n return false;\n }\n }\n}", "public void setActivo(boolean activo)\r\n/* 115: */ {\r\n/* 116:142 */ this.activo = activo;\r\n/* 117: */ }", "public Boolean getValue() {\n return value;\n }", "public void setIsLat(Boolean boo) {\n\t this.isLat = boo;\n }", "public void setCorrigeDatosRetencion(boolean corrigeDatosRetencion)\r\n/* 628: */ {\r\n/* 629:706 */ this.corrigeDatosRetencion = corrigeDatosRetencion;\r\n/* 630: */ }", "public String getIsFlag() {\r\n return isFlag;\r\n }", "public abstract void setCheck(Boolean check);", "boolean boolField(String name, boolean isDefined, boolean value)\n throws NullField, InvalidFieldValue;", "abstract void setIsInit(boolean b);", "public void setForua(boolean newValue);", "default boolean trySetBoolean(boolean value) {\n if (this.isValidBoolean(value)) {\n this.setBoolean(value);\n return true;\n } else {\n return false;\n }\n }", "public void setOn(boolean arg) {\n isOn = arg;\n }", "public Boolean getValue() {\n\t\treturn b;\n\t}", "public boolean get(boolean a) {\n\t\treturn a;\r\n\t}", "public Boolean getBoolean(String attr) {\n return (Boolean) super.get(attr);\n }", "@Test\r\n public void testSetMidi() {\r\n System.out.println(\"*****************\");\r\n System.out.println(\"Test : setMidi\");\r\n boolean midi = false;\r\n Cours_Reservation instance = new Cours_Reservation();\r\n instance.setMidi(midi);\r\n assertEquals(instance.isMidi(), midi);\r\n }", "protected boolean getBool(Boolean b, String clave, boolean defecto) {\n if (b != null) {\n return b;\n }\n\n String property = properties.getProperty(clave);\n if (property != null) {\n return Boolean.parseBoolean(property);\n }\n\n return defecto;\n }", "protected String getFalse() {\n return \"false\";\n }", "boolean getemisoraRadio(){\n return emisoraRadio;\n }", "private void stelDoelIn(boolean isDoel)\n {\n this.isDoel = isDoel; \n }", "void setString(boolean string);", "public void setAktif(java.lang.Boolean value) {\n this.aktif = value;\n }", "public void setValue(boolean value) {\n this.value = value;\n }", "public boolean isSetValue() {\n return this.value != null;\n }", "public void setIsReal(Boolean isReal) {\n this.isReal = isReal;\n }", "@Override\n public boolean getAsBoolean() {\n return this.persistenceCheck.getAsBoolean();\n }", "void setIsManaged(boolean isManaged);", "public void set_boolean(boolean param) {\n this.local_boolean = param;\n }", "public BooleanValue(boolean bool) {\r\n this.val = bool;\r\n }", "public Boolean asBoolean();", "public boolean isBoolean();", "@Override\n public String getIsimIst() {\n return mIsimIst;\n }", "public String toString() { return this.booleanValue; }", "public void setIsFixPrice (String IsFixPrice);", "public boolean isValue() {\n return value;\n }", "public boolean isPredeterminado()\r\n/* 154: */ {\r\n/* 155:264 */ return this.predeterminado;\r\n/* 156: */ }", "public boolean isRequiresTaxCertificate() \n{\nObject oo = get_Value(COLUMNNAME_RequiresTaxCertificate);\nif (oo != null) \n{\n if (oo instanceof Boolean) return ((Boolean)oo).booleanValue();\n return \"Y\".equals(oo);\n}\nreturn false;\n}", "boolean getestadoRadio(){\n return estadoRadio;\n }", "public void setPredeterminado(boolean predeterminado)\r\n/* 159: */ {\r\n/* 160:274 */ this.predeterminado = predeterminado;\r\n/* 161: */ }", "public void setIsGermplasmTemplate(boolean isGermplasmTemplate);", "public Value.Builder setAktif(boolean value) {\n validate(fields()[6], value);\n this.aktif = value;\n fieldSetFlags()[6] = true;\n return this;\n }", "public void setIsActive (boolean IsActive);" ]
[ "0.73778325", "0.73542017", "0.73542017", "0.711452", "0.7102868", "0.70903903", "0.70903903", "0.70462346", "0.69554955", "0.694153", "0.694153", "0.6939304", "0.6923241", "0.6885468", "0.68707585", "0.67944795", "0.67735565", "0.6746924", "0.6721408", "0.6695703", "0.6671432", "0.66688156", "0.66675067", "0.6653683", "0.6600392", "0.6588146", "0.65590113", "0.65567875", "0.655443", "0.6536404", "0.6508847", "0.6495812", "0.64944434", "0.6492966", "0.6483952", "0.6480442", "0.6468267", "0.6468067", "0.645739", "0.64430875", "0.6421629", "0.6414409", "0.64142984", "0.64030945", "0.6401383", "0.63996476", "0.63879365", "0.6384885", "0.637769", "0.6374499", "0.637354", "0.63601846", "0.63581157", "0.6352076", "0.6350987", "0.634645", "0.6344632", "0.6342984", "0.6335609", "0.6322985", "0.63215816", "0.63149893", "0.63130647", "0.63004184", "0.6296441", "0.62958276", "0.6294717", "0.6289507", "0.6288848", "0.62869096", "0.62832594", "0.62805235", "0.62778366", "0.62673837", "0.62642425", "0.62555104", "0.6254769", "0.6253239", "0.62458843", "0.6245021", "0.6241817", "0.62365633", "0.6235063", "0.6229892", "0.6219627", "0.6212346", "0.62012076", "0.6197576", "0.6189426", "0.61893314", "0.61872387", "0.6181783", "0.6177829", "0.6173662", "0.61718315", "0.61700755", "0.6165983", "0.61593807", "0.6154737", "0.6150858", "0.6148136" ]
0.0
-1
TODO Autogenerated method stub
@Override public int insertBook(Book book) { 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
TODO Autogenerated method stub
@Override public int getBookCount() { 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
TODO Autogenerated method stub
@Override public int getBookCount(String kind) { 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
TODO Autogenerated method stub
@Override public List<Book> getBooks(String kind) { 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 List<Book> getBooks(String kind, int startRow, int endRow) { 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 int updateBookInfo(Book book, int book_id) { 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
TODO Autogenerated method stub
@Override public int deleteBook(int book_id) { 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
TODO Autogenerated method stub
@Override public int managerCheck(String id, String password) { 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
TODO Autogenerated method stub
@Override public Book getBookInfo(int book_id) { 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
setup the listeners for the control point text fields and the control point selection buttons
private void setupListeners() { for (int i = 0; i < _controlPoints.length; i++) { addControlPointListener(_controlPoints[i][0], i); addControlPointListener(_controlPoints[i][1], i); } for (int i = 0; i < _selectionButtons.length; i++) { addPointSelectionButtonListener(i); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private void setControls() {\n calendarDisplayBox.addEventFilter(KEY_PRESSED, event -> {\n switch (event.getCode()) {\n case LEFT:\n logger.info(\"LEFT arrow Pressed.\");\n displayPreviousWeek();\n indicateCalendarDisplayTimeChanged();\n break;\n case RIGHT:\n logger.info(\"RIGHT arrow Pressed.\");\n displayNextWeek();\n indicateCalendarDisplayTimeChanged();\n break;\n default:\n }\n });\n }", "private void setupListeners()\n\t{\n\t\tequals.addMouseListener(new MouseAdapter()\n\t\t{\n\t\t\tpublic void mouseClicked(MouseEvent click)\n\t\t\t{\n\t\t\t\tappController.calculate();\n\t\t\t\tappController.refocus();\n\t\t\t}\n\n\t\t\tpublic void mousePressed(MouseEvent onClick)\n\t\t\t{\n\t\t\t\tequals.setBackground(Color.RED.darker());\n\t\t\t}\n\n\t\t\tpublic void mouseReleased(MouseEvent offClick)\n\t\t\t{\n\t\t\t\tequals.setBackground(Color.RED);\n\t\t\t}\n\n\t\t\tpublic void mouseEntered(MouseEvent enter)\n\t\t\t{\n\t\t\t\tequals.setBorder(new CompoundBorder(new LineBorder(Color.LIGHT_GRAY, 5), new LineBorder(Color.WHITE, 3)));\n\t\t\t}\n\n\t\t\tpublic void mouseExited(MouseEvent exit)\n\t\t\t{\n\t\t\t\tequals.setBorder(new CompoundBorder(new LineBorder(Color.LIGHT_GRAY, 5), new LineBorder(Color.BLACK, 3)));\n\t\t\t}\n\t\t});\n\t\tclear.addMouseListener(new MouseAdapter()\n\t\t{\n\t\t\tpublic void mouseClicked(MouseEvent click)\n\t\t\t{\n\t\t\t\tappController.clearText();\n\t\t\t\tappController.refocus();\n\t\t\t}\n\n\t\t\tpublic void mousePressed(MouseEvent onClick)\n\t\t\t{\n\t\t\t\tclear.setBackground(new Color(0, 170, 100).darker());\n\t\t\t}\n\n\t\t\tpublic void mouseReleased(MouseEvent offClick)\n\t\t\t{\n\t\t\t\tclear.setBackground(new Color(0, 170, 100));\n\t\t\t}\n\n\t\t\tpublic void mouseEntered(MouseEvent enter)\n\t\t\t{\n\t\t\t\tclear.setBorder(new CompoundBorder(new LineBorder(Color.LIGHT_GRAY, 5), new LineBorder(Color.WHITE, 3)));\n\t\t\t}\n\n\t\t\tpublic void mouseExited(MouseEvent exit)\n\t\t\t{\n\t\t\t\tclear.setBorder(new CompoundBorder(new LineBorder(Color.LIGHT_GRAY, 5), new LineBorder(Color.BLACK, 3)));\n\t\t\t}\n\t\t});\n\t\tbackspace.addMouseListener(new MouseAdapter()\n\t\t{\n\t\t\tpublic void mouseClicked(MouseEvent click)\n\t\t\t{\n\t\t\t\tappController.backspace();\n\t\t\t\tappController.refocus();\n\t\t\t}\n\n\t\t\tpublic void mousePressed(MouseEvent onClick)\n\t\t\t{\n\t\t\t\tbackspace.setBackground(new Color(0, 170, 100).darker());\n\t\t\t}\n\n\t\t\tpublic void mouseReleased(MouseEvent offClick)\n\t\t\t{\n\t\t\t\tbackspace.setBackground(new Color(0, 170, 100));\n\t\t\t}\n\n\t\t\tpublic void mouseEntered(MouseEvent enter)\n\t\t\t{\n\t\t\t\tbackspace.setBorder(new CompoundBorder(new LineBorder(Color.LIGHT_GRAY, 5), new LineBorder(Color.WHITE, 3)));\n\t\t\t}\n\n\t\t\tpublic void mouseExited(MouseEvent exit)\n\t\t\t{\n\t\t\t\tbackspace.setBorder(new CompoundBorder(new LineBorder(Color.LIGHT_GRAY, 5), new LineBorder(Color.BLACK, 3)));\n\t\t\t}\n\t\t});\n\t\tnegative.addMouseListener(new MouseAdapter()\n\t\t{\n\t\t\tpublic void mouseClicked(MouseEvent click)\n\t\t\t{\n\t\t\t\tappController.changeSign();\n\t\t\t\tappController.refocus();\n\t\t\t}\n\n\t\t\tpublic void mousePressed(MouseEvent onClick)\n\t\t\t{\n\t\t\t\tnegative.setBackground(Color.GRAY.darker());\n\t\t\t}\n\n\t\t\tpublic void mouseReleased(MouseEvent offClick)\n\t\t\t{\n\t\t\t\tnegative.setBackground(Color.GRAY);\n\t\t\t}\n\n\t\t\tpublic void mouseEntered(MouseEvent enter)\n\t\t\t{\n\t\t\t\tnegative.setBorder(new CompoundBorder(new LineBorder(Color.LIGHT_GRAY, 5), new LineBorder(Color.WHITE, 3)));\n\t\t\t}\n\n\t\t\tpublic void mouseExited(MouseEvent exit)\n\t\t\t{\n\t\t\t\tnegative.setBorder(new CompoundBorder(new LineBorder(Color.LIGHT_GRAY, 5), new LineBorder(Color.BLACK, 3)));\n\t\t\t}\n\t\t});\n\t}", "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}", "private void initControls() {\n txtFirstName.setDocument(new clsTextFieldLimit(255));\n txtMiddleName.setDocument(new clsTextFieldLimit(255));\n txtLastName.setDocument(new clsTextFieldLimit(255));\n txtStreet.setDocument(new clsTextFieldLimit(255));\n txtPostcode.setDocument(new clsTextFieldLimit(255));\n txtCity.setDocument(new clsTextFieldLimit(255));\n txtCountry.setDocument(new clsTextFieldLimit(255));\n \n //Only allow JTable the selection of one single row.\n tblContacts.setSelectionMode(ListSelectionModel.SINGLE_SELECTION);\n //Make next column head auto-resizable.\n tblContacts.setAutoResizeMode(JTable.AUTO_RESIZE_NEXT_COLUMN);\n //Define a contact listener for handling row changes.\n this.pContactSelectionModel = tblContacts.getSelectionModel();\n this.pContactSelectionModel.addListSelectionListener(new tblContactsListSelectionHandler());\n tblContacts.setSelectionModel(pContactSelectionModel);\n //Set the mouse scroll speed of the JScrollPane.\n scrRight.getVerticalScrollBar().setUnitIncrement(10);\n }", "@Override\n\tprotected void setControlListeners() {\n\t\tcheckBox.selectedProperty().addListener(new ChangeListener<Boolean>() {\n\t\t\t@Override\n\t\t\tpublic void changed(\n\t\t\t\t\tObservableValue<? extends Boolean> observable,\n\t\t\t\t\tBoolean oldValue, Boolean newValue) {\n\t\t\t\tif (!settingsPane.isExperimentRunning()) {\n\t\t\t\t\tparameter.set(newValue);\n\t\t\t\t\tsettingsPane.revalidateParameters();\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\t}", "private void createEvents() {\n\t\t\n\t\ttxtXC.addKeyListener(new KeyAdapter() {\n\t\t\t@Override\n\t\t\tpublic void keyTyped(KeyEvent e) {\n\t\t\t\tchar c = e.getKeyChar();\n\t\t\t\tif (!((c >= '0') && (c <= '9') ||\n\t\t\t\t\t\t(c == KeyEvent.VK_BACK_SPACE) ||\n\t\t\t\t\t\t(c == KeyEvent.VK_DELETE))) {\n\t\t\t\t\tgetToolkit().beep();\n\t\t\t\t\te.consume();\n\t\t\t\t}\t\n\t\t\t}\n\t\t});\n\t\t\n\t\ttxtYC.addKeyListener(new KeyAdapter() {\n\t\t\t@Override\n\t\t\tpublic void keyTyped(KeyEvent e) {\n\t\t\t\tchar c = e.getKeyChar();\n\t\t\t\tif (!((c >= '0') && (c <= '9') ||\n\t\t\t\t\t\t(c == KeyEvent.VK_BACK_SPACE) ||\n\t\t\t\t\t\t(c == KeyEvent.VK_DELETE))) {\n\t\t\t\t\tgetToolkit().beep();\n\t\t\t\t\te.consume();\n\t\t\t\t}\t\n\t\t\t}\n\t\t});\n\t\t\n\t\ttxtHeight.addKeyListener(new KeyAdapter() {\n\t\t\t@Override\n\t\t\tpublic void keyTyped(KeyEvent e) {\n\t\t\t\tchar c = e.getKeyChar();\n\t\t\t\tif (!((c >= '0') && (c <= '9') ||\n\t\t\t\t\t\t(c == KeyEvent.VK_BACK_SPACE) ||\n\t\t\t\t\t\t(c == KeyEvent.VK_DELETE))) {\n\t\t\t\t\tgetToolkit().beep();\n\t\t\t\t\te.consume();\n\t\t\t\t}\t\n\t\t\t}\n\t\t});\n\t\t\n\t\ttxtWidth.addKeyListener(new KeyAdapter() {\n\t\t\t@Override\n\t\t\tpublic void keyTyped(KeyEvent e) {\n\t\t\t\tchar c = e.getKeyChar();\n\t\t\t\tif (!((c >= '0') && (c <= '9') ||\n\t\t\t\t\t\t(c == KeyEvent.VK_BACK_SPACE) ||\n\t\t\t\t\t\t(c == KeyEvent.VK_DELETE))) {\n\t\t\t\t\tgetToolkit().beep();\n\t\t\t\t\te.consume();\n\t\t\t\t}\t\n\t\t\t}\n\t\t});\n\t\t\n\t\ttxtColor.addMouseListener(new MouseAdapter() {\n\t\t\t@Override\n\t\t\tpublic void mouseClicked(MouseEvent e) {\n\t\t\t\tcolor = JColorChooser.showDialog(null, \"Choose your color\", color);\n\t\t\t\tif (color == null) {\n\t\t\t\t\tcolor = Color.BLACK;\n\t\t\t\t}\n\t\t\t\ttxtColor.setBackground(color);\n\t\t\t}\n\t\t});\n\t\t\n\t\ttxtFill.addMouseListener(new MouseAdapter() {\n\t\t\t@Override\n\t\t\tpublic void mouseClicked(MouseEvent arg0) {\n\t\t\t\tfill = JColorChooser.showDialog(null, \"Choose your color\", fill);\n\t\t\t\tif (fill == null) {\n\t\t\t\t\tfill = Color.WHITE;\n\t\t\t\t}\n\t\t\t\ttxtFill.setBackground(fill);\n\t\t\t}\n\t\t});\n\t\t\n\t\tbtnOK.addActionListener(new ActionListener() {\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\tif (txtXC.getText().trim().isEmpty() ||\n\t\t\t\t\t\ttxtYC.getText().trim().isEmpty() ||\n\t\t\t\t\t\ttxtHeight.getText().trim().isEmpty() ||\n\t\t\t\t\t\ttxtWidth.getText().trim().isEmpty()) {\n\t\t\t\t\tisOK = false;\n\t\t\t\t\tsetVisible(true);\n\t\t\t\t\tgetToolkit().beep();\n\t\t\t\t\tJOptionPane.showMessageDialog(null, \"Not all fields have entered values!\", \"Error\",\n\t\t\t\t\t\t\tJOptionPane.ERROR_MESSAGE);\n\t\t\t\t} else if (\n\t\t\t\t\t\tInteger.parseInt(txtHeight.getText()) > 999 ||\n\t\t\t\t\t\tInteger.parseInt(txtWidth.getText()) > 999) {\n\t\t\t\t\t\n\t\t\t\t\tisOK = false;\n\t\t\t\t\tsetVisible(true);\n\t\t\t\t\tgetToolkit().beep();\n\t\t\t\t\tJOptionPane.showMessageDialog(null, \"Values entered must be between 0 and 999! \\nPlease try again\", \"Error\",\n\t\t\t\t\t\t\tJOptionPane.ERROR_MESSAGE);\n\t\t\t\t\t\tif (Integer.parseInt(txtHeight.getText()) > 999) {\n\t\t\t\t\t\t\ttxtHeight.setText(\"\");\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\tif (Integer.parseInt(txtWidth.getText()) > 999) {\n\t\t\t\t\t\t\ttxtWidth.setText(\"\");\n\t\t\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\tisOK = true;\n\t\t\t\t\tdispose();\n\t\t\t\t\tr = new Rectangle(new Point (Integer.parseInt(txtXC.getText()), Integer.parseInt(txtYC.getText())),\n\t\t\t\t\tInteger.parseInt(txtHeight.getText()), Integer.parseInt(txtWidth.getText()),\n\t\t\t\t\tFrmDrawing.getColor1(), FrmDrawing.getColor2());\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\t\t\n\t\tbtnCancel.addActionListener(new ActionListener() {\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\tint confirm = JOptionPane.showConfirmDialog (null, \"Are you sure you want to cancel your actions?\",\"Warning\", JOptionPane.YES_NO_OPTION);\n\t\t\t\tif (confirm == JOptionPane.YES_OPTION) {\n\t\t\t\t\tisOK = false;\n\t\t\t\t\tdispose();\n\t\t\t\t}\n\t\t\t}\n\t\t});\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() {\n\t\t\n\t\t//Vertical coupler action listener\n\t\tvC.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\n\t\t\t\t//divide facet option FALSE\n\t\t\t\tdivideFacet = false;\n\t\t\t\t//Edit button not enabled for couplers\n\t\t\t\tedit.setEnabled(false);\n\t\t\t\t//Extend button not enabled for couplers\n\t\t\t\textend.setEnabled(false);\n\t\t\t\t//Setting cursor icon configuration for vertical coupler\n\t\t\t\tbuttonAction(ValidOrientations.VERTICAL.getValue());\n\t\t\t\t//MType for couplers equals 1\n\t\t\t\tmType = ValidCouplerMullions.COUPLER.getValue();\n\t\t\t\t//Semaphore vertical coupler option\n\t\t\t\tselectedHV = ValidOrientations.VERTICAL.getValue();\n\t\t\t\t//Semaphore level selected\n\t\t\t\tselectedLevel = ValidCouplerMullions.COUPLER.getValue();\n\n //Filter valid coupler verticals\n List<TypeCouplerMullion> validCouplers = couplerMullionController.filterCouplerMullion(ValidCouplerMullions.COUPLER.getValue(),\n ValidOrientations.VERTICAL.getValue());\n\n List<TypeCouplerMullion> validDividers = couplerMullionController.filterCouplerMullion(ValidCouplerMullions.DIVIDER.getValue(),\n ValidOrientations.VERTICAL.getValue());\n\n validCouplers.addAll(validDividers);\n\n //Init coupler types comboBox\n\t\t\t\tDefaultComboBoxModel comboBoxModel = new DefaultComboBoxModel(validCouplers.toArray());\n couplerTypeC.setModel(comboBoxModel);\n\t\t\t\tcouplerTypeC.setSelectedIndex(0);\n\t\t\t\t\n\t\t\t\t//Remove components options which feature\n\t\t\t\twhichFeature.remove(couplerTypeC);\n\t\t\t\twhichFeature.remove(edit);\n\t\t\t\twhichFeature.remove(extend);\n\t\t\t\t\n\t\t\t\twhichFeature.add(couplerTypeC, new XYConstraints(2, 22, 180, 19));\n\t\t\t\t\n\t\t\t\twhichFeature.validate();\n\t\t\t\twhichFeature.repaint();\n\t\t\t}\n\t\t});\n\t\t\n\t\t//Horizontal coupler action listener\n\t\thC.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\n\t\t\t\t//Semaphore divide facet option FALSE\n\t\t\t\tdivideFacet = false;\n\t\t\t\t//Edit button disabled for horizontal coupler\n\t\t\t\tedit.setEnabled(false);\n\t\t\t\t//Extend button disabled for horizontal coupler\n\t\t\t\textend.setEnabled(false);\n\t\t\t\t//Semaphore level selected\n\t\t\t\tselectedLevel = ValidCouplerMullions.COUPLER.getValue();\n\t\t\t\t//Setting cursor icon configuration for horizontal coupler\n\t\t\t\tbuttonAction(ValidOrientations.HORIZONTAL.getValue());\n\t\t\t\t//MType for couplers equals 1\n\t\t\t\tmType = ValidCouplerMullions.COUPLER.getValue();\n\t\t\t\t//Semaphore horizontal coupler option\n\t\t\t\tselectedHV = ValidOrientations.HORIZONTAL.getValue();\n\t\t\t\t\n\t\t\t\t//Filter valid coupler verticals\n\t\t\t\tList<TypeCouplerMullion> validCouplers = couplerMullionController.filterCouplerMullion(ValidCouplerMullions.COUPLER.getValue(),\n\t\t\t\t\t\t\tValidOrientations.HORIZONTAL.getValue());\n\t\t\t\t\n\t\t\t\t//Init coupler types comboBox\n\t\t\t\tDefaultComboBoxModel comboBoxModel = new DefaultComboBoxModel(validCouplers.toArray());\n couplerTypeC.setModel(comboBoxModel);\n couplerTypeC.setSelectedIndex(0);\n\t\t\t\t\n\t\t\t\t//Remove components options which feature\n\t\t\t\twhichFeature.remove(couplerTypeC);\n\t\t\t\twhichFeature.remove(edit);\n\t\t\t\twhichFeature.remove(extend);\n\t\t\t\t\n\t\t\t\twhichFeature.add(couplerTypeC, new XYConstraints(2, 22, 180, 19));\n\t\t\t\t\n\t\t\t\twhichFeature.validate();\n\t\t\t\twhichFeature.repaint();\n\t\t\t}\n\t\t});\n\t\t\n\t\tvM.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\n\t\t\t\t//myParent.clearCMAlignEdit();\n\t\t\t\tdivideFacet = false;\n\t\t\t\t//MType for mullions equals 2\n\t\t\t\tmType = ValidCouplerMullions.MULLION.getValue();\n\t\t\t\t//Vertical mullions position\n\t\t\t\tselectedHV = ValidOrientations.VERTICAL.getValue();\n\t\t\t\t//Level selected for mullions\n\t\t\t\tselectedLevel = ValidCouplerMullions.MULLION.getValue();\n\t\t\t\t//Edit button enabled for vertical mullions\n\t\t\t\tbuttonAction(ValidOrientations.VERTICAL.getValue());\n\t\t\t\t//Extends button enabled for vertical mullions\n\t\t\t\tenableDisableBySeries();\n\t\t\t\t\n\t\t\t\t//Filter valid coupler verticals\n\t\t\t\tList<TypeCouplerMullion> validMullions = couplerMullionController.filterCouplerMullion(ValidCouplerMullions.MULLION.getValue(),\n\t\t\t\t\t\t\tValidOrientations.VERTICAL.getValue());\n\t\t\t\t\n\t\t\t\t//Init mullion types comboBox\n DefaultComboBoxModel comboBoxModel = new DefaultComboBoxModel(validMullions.toArray());\n couplerTypeC.setModel(comboBoxModel);\n couplerTypeC.setSelectedIndex(0);\n\n whichFeature.remove(couplerTypeC);\n\n\t\t\t\twhichFeature.add(edit, new XYConstraints(132, 0, 24, 19));\n\t\t\t\twhichFeature.add(extend, new XYConstraints(156, 0, 24, 19));\n whichFeature.add(couplerTypeC, new XYConstraints(2, 22, 180, 19));\n\t\t\t\t\n\t\t\t\twhichFeature.validate();\n\t\t\t\twhichFeature.repaint();\n\t\t\t}\n\t\t});\n\t\t\n\t\thM.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\n\t\t\t\t//myParent.clearCMAlignEdit();\n\t\t\t\tdivideFacet = false;\n\t\t\t\t//MType for mullions equals 2\n\t\t\t\tmType = ValidCouplerMullions.MULLION.getValue();\n\t\t\t\t//Horizontal mullions position\n\t\t\t\tselectedHV = ValidOrientations.HORIZONTAL.getValue();\n\t\t\t\t//Selected level for mullions equals 2\n\t\t\t\tselectedLevel = ValidCouplerMullions.MULLION.getValue();\n\t\t\t\t//Edit panel enabled for mullions\n\t\t\t\tenableDisableBySeries();\n\t\t\t\tbuttonAction(ValidOrientations.HORIZONTAL.getValue());\n\t\t\t\t//Filter valid coupler verticals\n\t\t\t\tList<TypeCouplerMullion> validMullions = couplerMullionController.filterCouplerMullion(ValidCouplerMullions.MULLION.getValue(),\n\t\t\t\t\t\t\tValidOrientations.HORIZONTAL.getValue());\n\n //Init mullion types comboBox\n DefaultComboBoxModel comboBoxModel = new DefaultComboBoxModel(validMullions.toArray());\n couplerTypeC.setModel(comboBoxModel);\n couplerTypeC.setSelectedIndex(0);\n\n whichFeature.remove(couplerTypeC);\n\n\t\t\t\twhichFeature.add(edit, new XYConstraints(132, 0, 24, 19));\n\t\t\t\twhichFeature.add(extend, new XYConstraints(156, 0, 24, 19));\n whichFeature.add(couplerTypeC, new XYConstraints(2, 22, 180, 19));\n\t\t\t\t\n\t\t\t\twhichFeature.validate();\n\t\t\t\twhichFeature.repaint();\n\t\t\t}\n\t\t});\n\t\t\n\t\tcancel.addActionListener(new ActionListener() {\n\t\t\t@Override\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\t\n\t\t\t\t//Setting edit visible\n\t\t\t\tsetEditVisible(false, null);\n\t\t\t\t\n\t\t\t\tif (hM.isSelected() || vM.isSelected()) {\n\t\t\t\t\tenableDisableBySeries();\n\t\t\t\t} else if (hC.isSelected() || vC.isSelected()) {\n\t\t\t\t\tenableDisableBySeries();\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\t\t\n\t\t//Edit mullions action listener\n\t\tedit.addActionListener(new ActionListener() {\n\t\t\t@Override\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\textend.setSelected(false);\n\t\t\t\tedit.setSelected(true);\n\t\t\t\t\n\t\t\t\t//Call edit action event\n\t\t\t\tedit_actionPerformed(e);\n\t\t\t}\n\t\t});\n\t\t\n\t\tpfCombo.addActionListener(new ActionListener() {\n\t\t\t@Override\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\tcomboPF(true);\n\t\t\t}\n\t\t});\n\t\t\n\t\t//Coupler type comboBox listener\n\t\tthis.couplerTypeC.addActionListener(new ActionListener() {\n\t\t\t@Override\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\tcoupleTypeAction();\n\t\t\t}\n\t\t});\n\t\t\n\t\tthis.part.addActionListener(new ActionListener() {\n\t\t\t@Override\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\t\n\t\t\t\tif (part.isSelected()) {\n\t\t\t\t\tparts.setEnabled(true);\n\t\t\t\t\tsetGo.setEnabled(true);\n\t\t\t\t} else {\n\t\t\t\t\tparts.setEnabled(false);\n\t\t\t\t\tif (!endTypeLT.isSelected() && !endTypeRB.isSelected() && !pfFormL.isSelected()) {\n\t\t\t\t\t\tsetGo.setEnabled(false);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\t\t\n\t\tthis.extend.addActionListener(new ActionListener() {\n\t\t\t@Override\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\textend.setSelected(true);\n\t\t\t\tedit.setSelected(false);\n\t\t\t\tcont_actionPerformed(e);\n\t\t\t}\n\t\t});\n\t\t\n\t\tendTypeLT.addActionListener(new ActionListener() {\n\t\t\t@Override\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\tif (endTypeLT.isSelected()) {\n\t\t\t\t\tlCut.setEnabled(true);\n\t\t\t\t\tsetGo.setEnabled(true);\n\t\t\t\t} else {\n\t\t\t\t\tlCut.setEnabled(false);\n\t\t\t\t\tif (!part.isSelected() && !endTypeRB.isSelected() && !pfFormL.isSelected()) {\n\t\t\t\t\t\tsetGo.setEnabled(false);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\t\t\n\t\tendTypeRB.addActionListener(new ActionListener() {\n\t\t\t@Override\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\tif (endTypeRB.isSelected()) {\n\t\t\t\t\trCut.setEnabled(true);\n\t\t\t\t\tsetGo.setEnabled(true);\n\t\t\t\t} else {\n\t\t\t\t\trCut.setEnabled(false);\n\t\t\t\t\tif (!endTypeLT.isSelected() && !part.isSelected() && !pfFormL.isSelected()) {\n\t\t\t\t\t\tsetGo.setEnabled(false);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\t\t\n\t\tpfFormL.addActionListener(new ActionListener() {\n\t\t\t@Override\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\tif (pfFormL.isSelected()) {\n\t\t\t\t\tpfCombo.setEnabled(true);\n\t\t\t\t\toffsetLT.setEnabled(true);\n\t\t\t\t\toffsetRB.setEnabled(true);\n\t\t\t\t\tdeltaL.setEnabled(true);\n\t\t\t\t\tdeltaR.setEnabled(true);\n\t\t\t\t\toffsetL.setEnabled(true);\n\t\t\t\t\toffsetR.setEnabled(true);\n\t\t\t\t\tsetGo.setEnabled(true);\n\t\t\t\t} else {\n\t\t\t\t\tpfCombo.setEnabled(false);\n\t\t\t\t\toffsetLT.setEnabled(false);\n\t\t\t\t\toffsetRB.setEnabled(false);\n\t\t\t\t\tdeltaL.setEnabled(false);\n\t\t\t\t\tdeltaR.setEnabled(false);\n\t\t\t\t\toffsetL.setEnabled(false);\n\t\t\t\t\toffsetR.setEnabled(false);\n\t\t\t\t\tif (!endTypeLT.isSelected() && !part.isSelected() && !part.isSelected()) {\n\t\t\t\t\t\tsetGo.setEnabled(false);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\t\t\n\t\tsetGo.addActionListener(new ActionListener() {\n\t\t\t@Override\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\tset_actionPerformed(e);\n\t\t\t}\n\t\t});\n\t}", "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}", "private void setupBtnListeners() {\n findViewById(R.id.btnAddValue).setOnClickListener(new View.OnClickListener() {\n @Override\n public void onClick(View v) {\n buttonAddValues();\n updateUI();\n MainActivity.hideKeyboard(getApplicationContext(), v);\n }\n });\n\n //Button to open blood pressure chart sets opens blood pressure chart activity\n findViewById(R.id.btnOpenBPChart).setOnClickListener(new View.OnClickListener() {\n @Override\n public void onClick(View v) {\n Intent bpChart = new Intent(WeightActivity.this, BPChartActivity.class);\n startActivity(bpChart.addFlags(Intent.FLAG_ACTIVITY_NO_ANIMATION));\n mSettingsOrBPChartOpened = true;\n }\n });\n\n //Clicking date button opens date picker and closes keyboard\n findViewById(R.id.tvDate).setOnClickListener(new View.OnClickListener() {\n @Override\n public void onClick(View v) {\n showDatePickerDialog();\n MainActivity.hideKeyboard(getApplicationContext(), v);\n }\n });\n }", "private void setViewListeners() {\n // Set an OnClickListener for each button.\n btnDecrease.setOnClickListener(this);\n btnIncrease.setOnClickListener(this);\n btnOrder.setOnClickListener(this);\n\n // Set an OnTouchListener for each view.\n btnDecrease.setOnTouchListener(touchListener);\n btnIncrease.setOnTouchListener(touchListener);\n etTitle.setOnTouchListener(touchListener);\n etAuthor.setOnTouchListener(touchListener);\n etPrice.setOnTouchListener(touchListener);\n etEditQuantity.setOnTouchListener(touchListener);\n etSupplier.setOnTouchListener(touchListener);\n etPhoneNumber.setOnTouchListener(touchListener);\n\n /* Format the phone number as the user types it.\n Reference: https://stackoverflow.com/a/15647444\n Date: 8/1/18\n */\n etPhoneNumber.addTextChangedListener(new PhoneNumberFormattingTextWatcher());\n // End referenced code.\n }", "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 addPointSelectionButtonListener(final int fieldNr) {\n\t\t_selectionButtons[fieldNr].addActionListener(new ActionListener() {\t\t\n\t\t\t@Override\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\t_activeIndex = fieldNr;\n\t\t\t\tfor (int i = 0; i < _selectionButtons.length; i++) {\n\t\t\t\t\t_selectionButtons[i].setForeground(Color.gray);\n\t\t\t\t}\n\t\t\t\t_selectionButtons[fieldNr].setForeground(Color.green);\n\t\t\t}\n\t\t});\n\t}", "protected void initControls()\n {\n glfwSetKeyCallback(windowID, new KeyboardInput());\n MouseInput.init(windowID);\n }", "void installListeners() {\n\t\t\t// Listeners on this popup's table and scroll bar\n\t\t\tproposalTable.addListener(SWT.FocusOut, this);\n\t\t\tScrollBar scrollbar = proposalTable.getVerticalBar();\n\t\t\tif (scrollbar != null) {\n\t\t\t\tscrollbar.addListener(SWT.Selection, this);\n\t\t\t}\n\n\t\t\t// Listeners on this popup's shell\n\t\t\tgetShell().addListener(SWT.Deactivate, this);\n\t\t\tgetShell().addListener(SWT.Close, this);\n\n\t\t\t// Listeners on the target control\n\t\t\tcontrol.addListener(SWT.MouseDoubleClick, this);\n\t\t\tcontrol.addListener(SWT.MouseDown, this);\n\t\t\tcontrol.addListener(SWT.Dispose, this);\n\t\t\tcontrol.addListener(SWT.FocusOut, this);\n\t\t\t// Listeners on the target control's shell\n\t\t\tShell controlShell = control.getShell();\n\t\t\tcontrolShell.addListener(SWT.Move, this);\n\t\t\tcontrolShell.addListener(SWT.Resize, this);\n\t\t}", "private void addActionListeners() {\r\n\t\tbuttonImport.addActionListener(this);\r\n\t\tbuttonCancel.addActionListener(this);\r\n\t\tcbContainsHeader.addActionListener(this);\r\n\t\tcbEnableLenCorrect.addActionListener(this);\r\n\t\ttextfieldDelimSymbol.addKeyListener(this);\r\n\t\ttextfieldLenCorrection.addKeyListener(this);\r\n\t\ttableSelectionPD.registerSelectedProfilesListener(this);\r\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}", "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 setupEventListeners(){\n\t\t//Check boxes.k\n\t\tchkVisible.addClickHandler(new ClickHandler(){\n\t\t\tpublic void onClick(ClickEvent event){\n\t\t\t\t((QuestionDef)propertiesObj).setVisible(chkVisible.getValue() == true);\n\t\t\t\tformChangeListener.onFormItemChanged(propertiesObj);\n\t\t\t}\n\t\t});\n\n\t\tchkEnabled.addClickHandler(new ClickHandler(){\n\t\t\tpublic void onClick(ClickEvent event){\n\t\t\t\t((QuestionDef)propertiesObj).setEnabled(chkEnabled.getValue() == true);\n\t\t\t\tformChangeListener.onFormItemChanged(propertiesObj);\n\t\t\t}\n\t\t});\n\n\t\tchkLocked.addClickHandler(new ClickHandler(){\n\t\t\tpublic void onClick(ClickEvent event){\n\t\t\t\t((QuestionDef)propertiesObj).setLocked(chkLocked.getValue() == true);\n\t\t\t\tformChangeListener.onFormItemChanged(propertiesObj);\n\t\t\t}\n\t\t});\n\n\t\tchkRequired.addClickHandler(new ClickHandler(){\n\t\t\tpublic void onClick(ClickEvent event){\n\t\t\t\t((QuestionDef)propertiesObj).setRequired(chkRequired.getValue() == true);\n\t\t\t\tformChangeListener.onFormItemChanged(propertiesObj);\n\t\t\t}\n\t\t});\n\n\t\t//Text boxes.\n\t\ttxtDefaultValue.addChangeHandler(new ChangeHandler(){\n\t\t\tpublic void onChange(ChangeEvent event){\n\t\t\t\tif(checkDefaultValueAgainstQuestionType()){\n\t\t\t\t\tupdateDefaultValue();\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\t\ttxtDefaultValue.addKeyUpHandler(new KeyUpHandler(){\n\t\t\tpublic void onKeyUp(KeyUpEvent event) {\n\t\t\t\tif(checkDefaultValueAgainstQuestionType()){\n\t\t\t\t\tupdateDefaultValue();\n\t\t\t\t}\n\t\t\t\telse{\n\t\t\t\t\tWindow.alert(LocaleText.get(\"invalidDefaultValueForQuestionType\"));\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\n\t\ttxtHelpText.addChangeHandler(new ChangeHandler(){\n\t\t\tpublic void onChange(ChangeEvent event){\n\t\t\t\tupdateHelpText();\n\t\t\t}\n\t\t});\n\t\ttxtHelpText.addKeyUpHandler(new KeyUpHandler(){\n\t\t\tpublic void onKeyUp(KeyUpEvent event) {\n\t\t\t\tupdateHelpText();\n\t\t\t}\n\t\t});\n\n\t\ttxtHelpText.addKeyDownHandler(new KeyDownHandler(){\n\t\t\tpublic void onKeyDown(KeyDownEvent event) {\n\t\t\t\tint keyCode = event.getNativeKeyCode();\n\t\t\t\tif(keyCode == KeyCodes.KEY_ENTER || keyCode == KeyCodes.KEY_DOWN)\n\t\t\t\t\tcbDataType.setFocus(true);\n\t\t\t\telse if(keyCode == KeyCodes.KEY_UP){\n\t\t\t\t\ttxtText.setFocus(true);\n\t\t\t\t\ttxtText.selectAll();\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\n\t\ttxtBinding.addChangeHandler(new ChangeHandler(){\n\t\t\tpublic void onChange(ChangeEvent event){\n\t\t\t\tupdateBinding();\n\t\t\t}\n\t\t});\n\t\ttxtBinding.addKeyUpHandler(new KeyUpHandler(){\n\t\t\tpublic void onKeyUp(KeyUpEvent event) {\n\t\t\t\tString s = txtBinding.getText();\n\n\t\t\t\ts = s.replace(\"%\", \"\");\n\t\t\t\ts = s.replace(\"(\", \"\");\n\t\t\t\ts = s.replace(\"!\", \"\");\n\t\t\t\ts = s.replace(\"&\", \"\");\n\t\t\t\t//s = s.replace(\".\", \"\"); //Looks like this is an allowed character in xml node names.\n\t\t\t\ts = s.replace(\"'\", \"\");\n\t\t\t\ts = s.replace(\"\\\"\", \"\");\n\t\t\t\ts = s.replace(\"$\", \"\");\n\t\t\t\ts = s.replace(\"#\", \"\");\n\n\t\t\t\ttxtBinding.setText(s);\n\t\t\t\tupdateBinding();\n\t\t\t}\n\t\t});\n\n\t\ttxtBinding.addKeyDownHandler(new KeyDownHandler(){\n\t\t\tpublic void onKeyDown(KeyDownEvent event) {\n\t\t\t\tif(event.getNativeKeyCode() == KeyCodes.KEY_UP){\n\t\t\t\t\tif(cbDataType.isEnabled())\n\t\t\t\t\t\tcbDataType.setFocus(true);\n\t\t\t\t\telse{\n\t\t\t\t\t\ttxtText.setFocus(true);\n\t\t\t\t\t\ttxtText.selectAll();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\n\t\ttxtBinding.addKeyPressHandler(new KeyPressHandler(){\n\t\t\tpublic void onKeyPress(KeyPressEvent event) {\n\t\t\t\tif(propertiesObj instanceof PageDef){\n\t\t\t\t\tif(!Character.isDigit(event.getCharCode())){\n\t\t\t\t\t\t((TextBox) event.getSource()).cancelKey(); \n\t\t\t\t\t\treturn;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\telse if(propertiesObj instanceof FormDef || propertiesObj instanceof QuestionDef){\n\t\t\t\t\tif(((TextBox) event.getSource()).getCursorPos() == 0){\n\t\t\t\t\t\tif(!isAllowedXmlNodeNameStartChar(event.getCharCode())){\n\t\t\t\t\t\t\t((TextBox) event.getSource()).cancelKey(); \n\t\t\t\t\t\t\treturn;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\telse if(!isAllowedXmlNodeNameChar(event.getCharCode())){\n\t\t\t\t\t\t((TextBox) event.getSource()).cancelKey(); \n\t\t\t\t\t\treturn;\n\t\t\t\t\t}\n\t\t\t\t} //else OptionDef varname can be anything\n\t\t\t}\n\t\t});\n\n\t\ttxtText.addChangeHandler(new ChangeHandler(){\n\t\t\tpublic void onChange(ChangeEvent event){\n\t\t\t\tString orgText = getSelObjetOriginalText();\n\t\t\t\tupdateText();\n\t\t\t\tupdateSelObjBinding(orgText);\n\t\t\t}\n\t\t});\n\t\ttxtText.addKeyUpHandler(new KeyUpHandler(){\n\t\t\tpublic void onKeyUp(KeyUpEvent event) {\n\t\t\t\tString orgText = getSelObjetOriginalText();\n\t\t\t\tupdateText();\n\t\t\t\tupdateSelObjBinding(orgText);\n\t\t\t}\n\t\t});\n\n\t\ttxtText.addKeyDownHandler(new KeyDownHandler(){\n\t\t\tpublic void onKeyDown(KeyDownEvent event) {\n\t\t\t\tif(event.getNativeKeyCode() == KeyCodes.KEY_ENTER || event.getNativeKeyCode() == KeyCodes.KEY_DOWN){\n\t\t\t\t\tif(txtHelpText.isEnabled())\n\t\t\t\t\t\ttxtHelpText.setFocus(true);\n\t\t\t\t\telse{\n\t\t\t\t\t\ttxtBinding.setFocus(true);\n\t\t\t\t\t\ttxtBinding.selectAll();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\n\t\ttxtDescTemplate.addChangeHandler(new ChangeHandler(){\n\t\t\tpublic void onChange(ChangeEvent event){\n\t\t\t\tupdateDescTemplate();\n\t\t\t}\n\t\t});\n\t\ttxtDescTemplate.addKeyUpHandler(new KeyUpHandler(){\n\t\t\tpublic void onKeyUp(KeyUpEvent event) {\n\t\t\t\tupdateDescTemplate();\n\t\t\t}\n\t\t});\n\n\t\ttxtCalculation.addChangeHandler(new ChangeHandler(){\n\t\t\tpublic void onChange(ChangeEvent event){\n\t\t\t\tupdateCalculation();\n\t\t\t}\n\t\t});\n\t\ttxtCalculation.addKeyUpHandler(new KeyUpHandler(){\n\t\t\tpublic void onKeyUp(KeyUpEvent event) {\n\t\t\t\tupdateCalculation();\n\t\t\t}\n\t\t});\n\n\t\t//Combo boxes\n\t\tcbDataType.addClickHandler(new ClickHandler(){\n\t\t\tpublic void onClick(ClickEvent event){\n\t\t\t\tupdateDataType();\n\t\t\t}\n\t\t});\n\t\tcbDataType.addChangeHandler(new ChangeHandler(){\n\t\t\tpublic void onChange(ChangeEvent event){\n\t\t\t\tupdateDataType();\n\t\t\t}\n\t\t});\n\t\tcbDataType.addKeyDownHandler(new KeyDownHandler(){\n\t\t\tpublic void onKeyDown(KeyDownEvent event) {\n\t\t\t\tint keyCode = event.getNativeEvent().getKeyCode();\n\t\t\t\tif(keyCode == KeyCodes.KEY_ENTER || keyCode == KeyCodes.KEY_DOWN){\n\t\t\t\t\ttxtBinding.setFocus(true);\n\t\t\t\t\ttxtBinding.selectAll();\n\t\t\t\t}\n\t\t\t\telse if(keyCode == KeyCodes.KEY_UP){\n\t\t\t\t\ttxtHelpText.setFocus(true);\n\t\t\t\t\ttxtHelpText.selectAll();\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\t\t\n\t\ttxtFormKey.addChangeHandler(new ChangeHandler(){\n\t\t\tpublic void onChange(ChangeEvent event){\n\t\t\t\tupdateFormKey();\n\t\t\t}\n\t\t});\n\t\ttxtFormKey.addKeyUpHandler(new KeyUpHandler(){\n\t\t\tpublic void onKeyUp(KeyUpEvent event) {\n\t\t\t\tupdateFormKey();\n\t\t\t}\n\t\t});\n\t}", "public void setupUIListeners() {\n\t\tsetupEditTextListeners();\n\t\tsetupSeekBarsListeners();\n\t}", "protected void initControls() {\n\t\tbind(true);\n\t}", "private void initControlsPage()\r\n {\n \tString keyTitleString = \"KEYBOARD\";\r\n \tkeyTitleText = new OText(25, 200, 300, keyTitleString);\r\n \tkeyTitleText.setFont(\"Courier New\", 20, 1.0, 'C', Settings.themes.textColor);\r\n \t\r\n \t//Initialize the keyboard movement text\r\n \tString keyMoveString = \"Move Optimus with the WASD keys \"\r\n \t\t\t + \" <br> \"\r\n \t\t\t + \"as if they were the arrow keys.\";\r\n \tkeyMoveText = new OText(25, 225, 300, keyMoveString);\r\n \tkeyMoveText.setFont(\"Courier New\", 14, 1.0, 'C', Settings.themes.textColor);\r\n \t\r\n \t\r\n \t//Initialize the mouse title text\r\n \tString mouseTitleString = \"MOUSE\";\r\n \tmouseTitleText = new OText(375, 200, 300, mouseTitleString);\r\n \tmouseTitleText.setFont(\"Courier New\", 20, 1.0, 'C', Settings.themes.textColor);\r\n \t\r\n \t//Initialize the mouse text\r\n \tString mouseMoveString = \"Aim by moving the mouse and shoot bullets from Optimus in the direction of the cursor using both clicks. \";\r\n \tmouseText = new OText(375, 225, 300, mouseMoveString);\r\n \tmouseText.setFont(\"Courier New\", 14, 1.0, 'C', Settings.themes.textColor);\r\n }", "public void setListeners() {\n backButton.setOnClickListener(new View.OnClickListener() {\n @Override\n public void onClick(View v) {\n finish();\n }\n });\n\n settingButton.setOnClickListener(new View.OnClickListener() {\n @Override\n public void onClick(View v) {\n showEditDialog();\n }\n });\n\n cameraButton.setOnClickListener(new View.OnClickListener() {\n @Override\n public void onClick(View v) {\n showChoosePictureDialog();\n }\n });\n }", "private void installListeners() {\r\n\t\tcboText.addActionListener(this);\r\n\r\n\t\tComponent c = cboText.getEditor().getEditorComponent();\r\n\t\tif (c instanceof JTextComponent) {\r\n\t\t\t((JTextComponent) c).getDocument().addDocumentListener(this);\r\n\t\t}\r\n\r\n\t\tbtnFind.addActionListener(this);\r\n\t\tbtnReplace.addActionListener(this);\r\n\t\tbtnReplaceAll.addActionListener(this);\r\n\t\tbtnReplaceFind.addActionListener(this);\r\n\r\n\t\trbAll.addActionListener(this);\r\n\t\trbSelectedLines.addActionListener(this);\r\n\r\n\t\tcbUseRegex.addItemListener(this);\r\n\t}", "@Override\n\tpublic void initializeControls() {\n\t\t\n\t}", "private void initInputListeners() {\n focusGrabber = new FocusGrabber();\r\n mouseClickScroller = new MouseClickScroller();\r\n cursorChanger = new CursorChanger();\r\n wheelScroller = new MouseWheelScroller();\r\n keyScroller = new KeyScroller();\r\n }", "protected void setupListeners() {\n\t\t\n\t\tloginBtn.addActionListener(new ActionListener() {\n\t\t\tpublic void actionPerformed(ActionEvent click) {\n\t\t\t\tSession session = theController.validateUser(usernameField.getText(), passwordField.getText());\n\t\t\t\tif(session != null) {\n\t\t\t\t\ttheController.login();\n\t\t\t\t} else {\n\t\t\t\t\tlblInvalid.setVisible(true);\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\t\t\n\t\tbtnRegister.addActionListener(new ActionListener() {\n\t\t\tpublic void actionPerformed(ActionEvent click) {\n\t\t\t\ttheController.register();\n\t\t\t}\n\t\t});\n\t\t\n\t\tbtnGuide.addActionListener(new ActionListener() {\n\t\t\tpublic void actionPerformed(ActionEvent click) {\n\t\t\t\ttheController.viewGuide();\n\t\t\t}\n\t\t});\n\t\t\n\t}", "private void setListener() {\n\t\tmSlidingLayer.setOnInteractListener(this);\r\n\t\tmMsgNotifySwitch.setOnCheckedChangeListener(this);\r\n\t\tmMsgSoundSwitch.setOnCheckedChangeListener(this);\r\n\t\tmShowHeadSwitch.setOnCheckedChangeListener(this);\r\n\t\tmAccountSetting.setOnClickListener(this);\r\n\t\tmMyProfile.setOnClickListener(this);\r\n\t\tmFaceJazzEffect.setOnClickListener(this);\r\n\t\tmAcountInfo.setOnClickListener(this);\r\n\t\tmFeedBack.setOnClickListener(this);\r\n\t\tmExitAppBtn.setOnClickListener(this);\r\n\r\n\t}", "private void initControl(){\n Button start = view.getStart();\n start.setDisable(true);\n view.getNameBlackField().setOnKeyTyped(event -> view.getStart().setDisable(! validNames(view.getNameWhiteField().getText(), view.getNameBlackField().getText())));\n view.getNameWhiteField().setOnKeyTyped(event -> view.getStart().setDisable(! validNames(view.getNameWhiteField().getText(), view.getNameBlackField().getText())));\n start.setOnAction(event -> {\n String whiteName = view.getNameWhiteField().getText();\n String blackName = view.getNameBlackField().getText();\n if (validNames(whiteName, blackName)){\n this.whiteName = whiteName;\n this.blackName = blackName;\n start();\n }\n });\n }", "private void addListeners()\n {\n // Enable LDAP Checkbox\n addDirtyListener( enableLdapCheckbox );\n addSelectionListener( enableLdapCheckbox, enableLdapCheckboxListener );\n\n // LDAP Port Text\n addDirtyListener( ldapPortText );\n addModifyListener( ldapPortText, ldapPortTextListener );\n\n // LDAP Address Text\n addDirtyListener( ldapAddressText );\n addModifyListener( ldapAddressText, ldapAddressTextListener );\n\n // LDAP nbThreads Text\n addDirtyListener( ldapNbThreadsText );\n addModifyListener( ldapNbThreadsText, ldapNbThreadsTextListener );\n\n // LDAP BackLogSize Text\n addDirtyListener( ldapBackLogSizeText );\n addModifyListener( ldapBackLogSizeText, ldapBackLogSizeTextListener );\n\n // Enable LDAPS Checkbox\n addDirtyListener( enableLdapsCheckbox );\n addSelectionListener( enableLdapsCheckbox, enableLdapsCheckboxListener );\n\n // LDAPS Address Text\n addDirtyListener( ldapsAddressText );\n addModifyListener( ldapsAddressText, ldapsAddressTextListener );\n\n // LDAPS Port Text\n addDirtyListener( ldapsPortText );\n addModifyListener( ldapsPortText, ldapsPortTextListener );\n\n // LDAPS nbThreads Text\n addDirtyListener( ldapsNbThreadsText );\n addModifyListener( ldapsNbThreadsText, ldapsNbThreadsTextListener );\n\n // LDAPS BackLogSize Text\n addDirtyListener( ldapsBackLogSizeText );\n addModifyListener( ldapsBackLogSizeText, ldapsBackLogSizeTextListener );\n \n // Enable wantClientAuth Checkbox\n addDirtyListener( wantClientAuthCheckbox );\n addSelectionListener( wantClientAuthCheckbox, wantClientAuthListener );\n\n // Enable needClientAuth Checkbox\n addDirtyListener( needClientAuthCheckbox );\n addSelectionListener( needClientAuthCheckbox, needClientAuthListener );\n\n // Auth Mechanisms Simple Checkbox\n addDirtyListener( authMechSimpleCheckbox );\n addSelectionListener( authMechSimpleCheckbox, authMechSimpleCheckboxListener );\n\n // Auth Mechanisms GSSAPI Checkbox\n addDirtyListener( authMechGssapiCheckbox );\n addSelectionListener( authMechGssapiCheckbox, authMechGssapiCheckboxListener );\n\n // Auth Mechanisms CRAM-MD5 Checkbox\n addDirtyListener( authMechCramMd5Checkbox );\n addSelectionListener( authMechCramMd5Checkbox, authMechCramMd5CheckboxListener );\n\n // Auth Mechanisms DIGEST-MD5 Checkbox\n addDirtyListener( authMechDigestMd5Checkbox );\n addSelectionListener( authMechDigestMd5Checkbox, authMechDigestMd5CheckboxListener );\n\n // Auth Mechanisms NTLM Checkbox\n addDirtyListener( authMechNtlmCheckbox );\n addSelectionListener( authMechNtlmCheckbox, authMechNtlmCheckboxListener );\n\n // Auth Mechanisms NTLM Text\n addDirtyListener( authMechNtlmText );\n addModifyListener( authMechNtlmText, authMechNtlmTextListener );\n\n // Auth Mechanisms GSS SPNEGO Checkbox\n addDirtyListener( authMechGssSpnegoCheckbox );\n addSelectionListener( authMechGssSpnegoCheckbox, authMechGssSpnegoCheckboxListener );\n addModifyListener( authMechGssSpnegoText, authMechGssSpnegoTextListener );\n\n // Auth Mechanisms GSS SPNEGO Text\n addDirtyListener( authMechGssSpnegoText );\n addModifyListener( authMechGssSpnegoText, authMechGssSpnegoTextListener );\n\n // Keystore File Text\n addDirtyListener( keystoreFileText );\n addModifyListener( keystoreFileText, keystoreFileTextListener );\n\n // Keystore File Browse Button\n addSelectionListener( keystoreFileBrowseButton, keystoreFileBrowseButtonSelectionListener );\n\n // Password Text\n addDirtyListener( keystorePasswordText );\n addModifyListener( keystorePasswordText, keystorePasswordTextListener );\n\n // Show Password Checkbox\n addSelectionListener( showPasswordCheckbox, showPasswordCheckboxSelectionListener );\n\n // SASL Host Text\n addDirtyListener( saslHostText );\n addModifyListener( saslHostText, saslHostTextListener );\n\n // SASL Principal Text\n addDirtyListener( saslPrincipalText );\n addModifyListener( saslPrincipalText, saslPrincipalTextListener );\n\n // SASL Seach Base Dn Text\n addDirtyListener( saslSearchBaseDnText );\n addModifyListener( saslSearchBaseDnText, saslSearchBaseDnTextListener );\n\n // SASL Realms Table Viewer\n addSelectionChangedListener( saslRealmsTableViewer, saslRealmsTableViewerSelectionChangedListener );\n addDoubleClickListener( saslRealmsTableViewer, saslRealmsTableViewerDoubleClickListener );\n addSelectionListener( editSaslRealmsButton, editSaslRealmsButtonListener );\n addSelectionListener( addSaslRealmsButton, addSaslRealmsButtonListener );\n addSelectionListener( deleteSaslRealmsButton, deleteSaslRealmsButtonListener );\n\n // Max Time Limit Text\n addDirtyListener( maxTimeLimitText );\n addModifyListener( maxTimeLimitText, maxTimeLimitTextListener );\n\n // Max Size Limit Text\n addDirtyListener( maxSizeLimitText );\n addModifyListener( maxSizeLimitText, maxSizeLimitTextListener );\n\n // Max PDU Size Text\n addDirtyListener( maxPduSizeText );\n addModifyListener( maxPduSizeText, maxPduSizeTextListener );\n\n // Enable TLS Checkbox\n addDirtyListener( enableTlsCheckbox );\n addSelectionListener( enableTlsCheckbox, enableTlsCheckboxListener );\n\n // Hashing Password Checkbox\n addDirtyListener( enableServerSidePasswordHashingCheckbox );\n addSelectionListener( enableServerSidePasswordHashingCheckbox, enableServerSidePasswordHashingCheckboxListener );\n\n // Hashing Method Combo Viewer\n addDirtyListener( hashingMethodComboViewer );\n addSelectionChangedListener( hashingMethodComboViewer, hashingMethodComboViewerListener );\n\n // Advanced SSL Cipher Suites\n ciphersSuiteTableViewer.addCheckStateListener( ciphersSuiteTableViewerListener );\n\n // Advanced SSL Enabled Protocols\n // Enable sslv3 Checkbox\n addDirtyListener( sslv3Checkbox );\n addSelectionListener( sslv3Checkbox, sslv3CheckboxListener );\n\n // Enable tlsv1 Checkbox\n addDirtyListener( tlsv1_0Checkbox );\n addSelectionListener( tlsv1_0Checkbox, tlsv1_0CheckboxListener );\n\n // Enable tlsv1.1 Checkbox\n addDirtyListener( tlsv1_1Checkbox );\n addSelectionListener( tlsv1_1Checkbox, tlsv1_1CheckboxListener );\n\n // Enable tlsv1.2 Checkbox\n addDirtyListener( tlsv1_2Checkbox );\n addSelectionListener( tlsv1_2Checkbox, tlsv1_2CheckboxListener );\n\n // Replication Pinger Sleep\n addDirtyListener( replicationPingerSleepText );\n addModifyListener( replicationPingerSleepText, replicationPingerSleepTextListener );\n\n // Disk Synchronization Delay\n addDirtyListener( diskSynchronizationDelayText );\n addModifyListener( diskSynchronizationDelayText, diskSynchronizationDelayTextListener );\n }", "private void initEvents() {\n\t\tuser_head_img.setOnClickListener(this);\r\n\t\ttxt_zcgl.setOnClickListener(this);\r\n\t\ttxt_tzgl.setOnClickListener(this);\r\n\t\ttxt_jlcx.setOnClickListener(this);\r\n\t\ttxt_wdyhk.setOnClickListener(this);\r\n\t\ttxt_wdxx.setOnClickListener(this);\r\n\t\tlayout_zhaq.setOnClickListener(this);\r\n\t\tlayout_ssmm.setOnClickListener(this);\r\n\t\ttxt_myredpager.setOnClickListener(this);\r\n\t}", "private void populateControlPanel() {\n \n ControlListener control = new ControlListener();\n startStopButton = new JButton(\"Start/Stop\");\n startStopButton.addActionListener(control);\n \n saveButton = new JButton(\"Save\");\n saveButton.addActionListener(control);\n \n loadButton = new JButton(\"Load\");\n loadButton.addActionListener(control);\n \n resetButton = new JButton(\"Reset\");\n resetButton.addActionListener(control);\n \n add(startStopButton);\n add(saveButton);\n add(loadButton);\n add(resetButton);\n }", "public void setGuiListeners()\n\t{\n\t\tcustomerList.addSelectionListener(new SelectionAdapter()\n\t\t{\n\t\t\tpublic void widgetSelected(SelectionEvent event)\n\t\t\t{\n\t\t\t\tint index = customerList.getSelectionIndex();\n\t\t\t\tif (index >= 0 && index <= mCollect.getList().size())\n\t\t\t\t{\n\t\t\t\t\tmeasureText.setText(mCollect.getList().get(index).getMeasurementData());\n\t\t\t\t\taData = new AddressData(mCollect.getMesID(index));\n\t\t\t\t\tcustomerText.setText(aData.getCustomerData());\n\t\t\t\t\ttry\n\t\t\t\t\t{\n\t\t\t\t\t\tsetTaskData(mCollect.getMesID(index));\n\t\t\t\t\t}\n\t\t\t\t\tcatch (IOException e)\n\t\t\t\t\t{\n\t\t\t\t\t\te.printStackTrace();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\n\t\t});\n\n\t\tpriorityCombo.addSelectionListener(new SelectionAdapter()\n\t\t{\n\t\t\tpublic void widgetSelected(SelectionEvent e)\n\t\t\t{\n\n\t\t\t\tif (priorityCombo.getText().equals(\"HIGH\"))\n\t\t\t\t{\n\t\t\t\t\tcustomerList.removeAll();\n\t\t\t\t\tmCollect.highPriorityfilter();\n\t\t\t\t\tfor (Measurement mObject : mCollect.getList())\n\t\t\t\t\t{\n\t\t\t\t\t\taData = new AddressData(mObject.getId());\n\t\t\t\t\t\tif (mObject.getPriority().equals(\"HIGH\"))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tcustomerList.add(\"+ \" + aData.guiAddressData());\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse if (mObject.getPriority().equals(\"MEDIUM\"))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tcustomerList.add(\"- \" + aData.guiAddressData());\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\tcustomerList.add(\"o \" + aData.guiAddressData());\n\t\t\t\t\t\t}\n\n\t\t\t\t\t}\n\t\t\t\t\tstatusBar.setText(\"List filtered according High priority\");\n\n\t\t\t\t}\n\t\t\t\telse if (priorityCombo.getText().equals(\"MEDIUM\"))\n\t\t\t\t{\n\t\t\t\t\tcustomerList.removeAll();\n\t\t\t\t\tmCollect.mediumPriorityfilter();\n\t\t\t\t\tfor (Measurement mObject : mCollect.getList())\n\t\t\t\t\t{\n\t\t\t\t\t\taData = new AddressData(mObject.getId());\n\t\t\t\t\t\tif (mObject.getPriority().equals(\"HIGH\"))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tcustomerList.add(\"+ \" + aData.guiAddressData());\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse if (mObject.getPriority().equals(\"MEDIUM\"))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tcustomerList.add(\"- \" + aData.guiAddressData());\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\tcustomerList.add(\"o \" + aData.guiAddressData());\n\t\t\t\t\t\t}\n\n\t\t\t\t\t}\n\t\t\t\t\tstatusBar.setText(\"List filtered according Medium priority\");\n\n\t\t\t\t}\n\t\t\t\telse if (priorityCombo.getText().equals(\"LOW\"))\n\t\t\t\t{\n\t\t\t\t\tcustomerList.removeAll();\n\t\t\t\t\tmCollect.lowPriorityfilter();\n\t\t\t\t\tfor (Measurement mObject : mCollect.getList())\n\t\t\t\t\t{\n\t\t\t\t\t\taData = new AddressData(mObject.getId());\n\t\t\t\t\t\tif (mObject.getPriority().equals(\"HIGH\"))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tcustomerList.add(\"+ \" + aData.guiAddressData());\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse if (mObject.getPriority().equals(\"MEDIUM\"))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tcustomerList.add(\"- \" + aData.guiAddressData());\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\tcustomerList.add(\"o \" + aData.guiAddressData());\n\t\t\t\t\t\t}\n\n\t\t\t\t\t}\n\t\t\t\t\tstatusBar.setText(\"List filtered according Low priority\");\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\n\t\t// register listener for the electrode combo\n\t\telectrodeCombo.addSelectionListener(new SelectionAdapter()\n\t\t{\n\t\t\tpublic void widgetSelected(SelectionEvent e)\n\t\t\t{\n\t\t\t\tif (electrodeCombo.getText().equals(\"Simple\"))\n\t\t\t\t{\n\t\t\t\t\trestApiUpdate(\"Simple\", \"electrode\");\n\t\t\t\t}\n\t\t\t\telse if (electrodeCombo.getText().equals(\"Test\"))\n\t\t\t\t{\n\t\t\t\t\trestApiUpdate(\"Test\", \"electrode\");\n\t\t\t\t}\n\t\t\t\telse if (electrodeCombo.getText().equals(\"New\"))\n\t\t\t\t{\n\t\t\t\t\trestApiUpdate(\"New\", \"electrode\");\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\n\t\t\t\t}\n\t\t\t}\n\n\t\t});\n\n\t\t// delete all data on gui, update list and set text fields to first selected item\n\t\tupdateButton.addSelectionListener(new SelectionAdapter()\n\t\t{\n\t\t\tpublic void widgetSelected(SelectionEvent e)\n\t\t\t{\n\t\t\t\tresetGuiData();\n\t\t\t\tsetData();\n\t\t\t\tstatusBar.setText(\"List updated successfully\");\n\t\t\t}\n\t\t});\n\n\t\t// register listener for the selection event\n\t\tconfigButton.addSelectionListener(new SelectionAdapter()\n\t\t{\n\t\t\t@Override\n\t\t\tpublic void widgetSelected(SelectionEvent e)\n\t\t\t{\n\t\t\t\ttry\n\t\t\t\t{\n\t\t\t\t\tif (ConnectionManager.getInstance().currentSensor(0).getBatteryVoltage() < 3.8)\n\t\t\t\t\t{\n\t\t\t\t\t\tmessageCode = batteryWarning();\n\t\t\t\t\t\tif (messageCode == 32)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tconfigurateSensor();\n\t\t\t\t\t\t\tconfigButton.setEnabled(false);\n\t\t\t\t\t\t}\n\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tconfigurateSensor();\n\t\t\t\t\t\tconfigButton.setEnabled(false);\n\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tcatch (SensorNotFoundException e1)\n\t\t\t\t{\n\t\t\t\t\tstatusBar.setText(e1.getMessage());\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\n\t\tshell.addShellListener(new ShellAdapter()\n\t\t{\n\t\t\tpublic void shellDeactivated(ShellEvent shellEvent)\n\t\t\t{\n\t\t\t\tshellCheck = false;\n\t\t\t\tTimer timer = new Timer();\n\t\t\t\ttimer.schedule(new TimerTask()\n\t\t\t\t{\n\t\t\t\t\t@Override\n\t\t\t\t\tpublic void run()\n\t\t\t\t\t{\n\t\t\t\t\t\tDisplay.getDefault().asyncExec(new Runnable()\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t@Override\n\t\t\t\t\t\t\tpublic void run()\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\twhile (!shellCheck)\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tstatusBar.setText(\"Operator access requesting.....\");\n\t\t\t\t\t\t\t\t\tInputDialog opdialog = new InputDialog(shell, SWT.DIALOG_TRIM);\n\t\t\t\t\t\t\t\t\topdialog.createDialogArea();\n\t\t\t\t\t\t\t\t\tstatusBar.setText(\"You have logged in as \" + login);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t});\n\n\t\t\t\t\t}\n\n\t\t\t\t}, 600000);\n\n\t\t\t}\n\n\t\t\tpublic void shellActivated(ShellEvent arg1)\n\t\t\t{\n\t\t\t\tshellCheck = true;\n\n\t\t\t}\n\t\t});\n\n\t}", "private void listenersInitiation() {\n ActionSelectors listener = new ActionSelectors();\n submit.addActionListener(listener);\n goBack.addActionListener(listener);\n }", "protected void initControl() {\n\t\t\r\n\t}", "private void initHandlers(){\n\t\tlabel.setOnMouseClicked(new EventHandler<MouseEvent>() {\n\t\t\tpublic void handle(MouseEvent e) {\n\t\t\t\tfor(TLEventLabel label : eventLabels){\n\t\t\t\t\tlabel.setSelected(false);\n\t\t\t\t}\n\t\t\t\tsetSelected(true);\n\t\t\t\tnew Thread(new Runnable() {\n\t\t\t\t\tpublic void run() {\n\t\t\t\t\t\tmodel.selectEvent(event);\n\t\t\t\t\t}\n\t\t\t\t}).start();\n\t\t\t}\n\t\t});\n\t}", "private void setupListeners() {\n\n // \"Save\" button\n Button confirmButton = (Button) findViewById(R.id.button_save_report);\n confirmButton.setOnClickListener(new View.OnClickListener() {\n @Override\n public void onClick(View v) {\n setResult(RESULT_OK);\n saveForm();\n finish(); // eventually calls onPause() and onStop()\n }\n });\n\n // \"Cancel\" button\n Button cancelButton = (Button) findViewById(R.id.button_cancel_edit_report);\n cancelButton.setOnClickListener(new View.OnClickListener() {\n @Override\n public void onClick(View v) {\n setResult(RESULT_CANCELED);\n finish(); // eventually calls onPause() and onStop()\n }\n });\n\n TextWatcher onFormChangeListener = new TextWatcher() {\n\n @Override\n public void onTextChanged(CharSequence s, int start, int before, int count) {\n mFormChanged = true;\n }\n\n @Override\n public void beforeTextChanged(CharSequence s, int start, int count, int after) {\n }\n\n @Override\n public void afterTextChanged(Editable s) {\n }\n };\n\n mValueText.addTextChangedListener(onFormChangeListener);\n }", "private void initListener() {\n initPieceListener();\n initButtonsListener();\n }", "private void InitListeners() {\n craftRobot.addActionListener(e -> settler.CraftRobot());\n craftTp.addActionListener(e -> settler.CraftTeleportGate());\n placeTp.addActionListener(e -> settler.PlaceTeleporter());\n fill.addActionListener(e -> {\n if(!inventory.isSelectionEmpty()) settler.PlaceResource(inventory.getSelectedValue());\n });\n inventory.addListSelectionListener(e -> fill.setEnabled(!(inventory.isSelectionEmpty())\n && settler.GetOnAsteroid().GetResource()==null\n && settler.GetOnAsteroid().GetLayerCount()==0)\n );\n }", "public Onview() {\r\n initComponents();\r\n loadDisplayScreen();\r\n jcbX_Axis.setModel(new DefaultComboBoxModel(new String[]{}));\r\n jcbX_Axis.setEnabled(false);\r\n jcbY_Axis.setModel(new DefaultComboBoxModel(new String[]{}));\r\n jcbY_Axis.setEnabled(false);\r\n setResizable(false);\r\n }", "public void addControls() {\n }", "void init() {\n\n\t\timgX.setBounds(0, 0, imgX.getIntrinsicWidth(), imgX.getIntrinsicHeight());\n\n\t\t// There may be initial text in the field, so we may need to display the button\n\n\t\tmanageClearButton();\n\n\t\tsetOnTouchListener(this);\n\n\t\tthis.addTextChangedListener(generalTextWatcher);\n\n\t}", "private void configureButtons() {\n\n\t\t// Set button listeners\n\t\tfor(SLChannelControllerViews views : mChannelViews) {\n\t\t\tviews.getChannelButton().setOnTouchListener(new SLSeekBarOnTouchListener(views.getChannelSeekBar()));\n\t\t}\n\t}", "private void setUpDialoguebox() {\n\t\tinput = new CTS_GUI_Dialoguebox();\n\t\tinput.setTitle(\"Settings\");\n\t\tBorderPane pane = new BorderPane();\n\t\tLocalTime t = LocalTime.now();\n\t\tLocalDate d = LocalDate.now();\n\t\tuicontrols = new VBox(10);\n\t\tHBox box0 = new HBox(5);\n\t\tbox0.getChildren().addAll(new Label(\"Latitude: \"),new TextField(\"0\"));\n\t\tHBox box1 = new HBox(5);\n\t\tbox1.getChildren().addAll(new Label(\"Longitude: \"),new TextField(\"0\"));\n\t\tHBox box2 = new HBox(5);\n\t\tbox2.getChildren().addAll(new Label(\"Date: \"),new TextField(d.toString()));\n\t\tTextField time = new TextField(t.getHour() + \":\" + t.getMinute() + \":\" + (int) floor(t.getSecond()));\n\t\tHBox box3 = new HBox(5);\n\t\tbox3.getChildren().addAll(new Label(\"Time: \"),time);\n\t\t// Check boxes\n\t\tHBox box5 = new HBox(5);\n\t\tCheckBox c1 = new CheckBox(\"Plot Stars\");\n\t\tc1.setSelected(true);\n\t\tCheckBox c2 = new CheckBox(\"Plot DSOs\");\n\t\tc2.setSelected(true);\n\t\tCheckBox c3 = new CheckBox(\"Plot Constellations\");\n\t\tc3.setSelected(true);\n\t\tCheckBox c4 = new CheckBox(\"Plot Planets\");\n\t\tc4.setSelected(true);\n\t\tbox5.getChildren().addAll(c1,c2,c3,c4);\n\t\t// Color Picker\n\t\t// 0 = Star color, 1 = Low mag star, 2 = Very low mag star.\n\t\t// 3 = DSO, 4 = Sky background, 5 = Circle around sky background\n\t\t// 6 = Overall background, 7 = Lat/long txt color, 8 = Constellation line color.\n\t\tHBox box6 = new HBox(5);\n\t\tTextField colorSet = new TextField(\"255,255,255,1\");\n\t\tButton setcolorbutton = new Button(\"Submit Color\");\n\t\tbox6.getChildren().addAll(new Label(\"Color to Set: \"),colorSet,setcolorbutton,new Label(\"[PREVIEW COLOR]\"));\n\t\tsetcolorbutton.setOnAction((event) -> { colorPickerHander(); });\n MenuBar mainmenu = new MenuBar();\n Menu colorpickermenu = new Menu(\"Set Custom Colors\");\n String[] colorstrs = {\"Star Color\",\"Low Magnituide Star Color\",\"Very Low Magnituide Star Color\", \"Deep Space Object Color\",\"Sky Background Color\",\n \t\t\"Circle Around Sky Background Color\",\"Overall Background Color\", \"Latitude/Longitude Text Color\",\"Constellation Line Color\"};\n for(int x = 0; x < colorstrs.length; x++) {\n \tMenuItem opt = new MenuItem(colorstrs[x]);\n \tint id = x;\n \topt.setOnAction((event) -> { colorSetterId = id; });\n \tcolorpickermenu.getItems().add(opt);\n }\n \n ComboBox<String> consts = new ComboBox<>();\n HashMap<String, String> cdbs = controller.getModelConstellationDBs();\n\n for (String name : cdbs.keySet()) {\n consts.getItems().add(name);\n }\n HBox box7 = new HBox(5);\n box7.getChildren().addAll(new Label(\"Select Constellation Set\"), consts);\n \n consts.getSelectionModel().select(\"Western\");\n mainmenu.getMenus().addAll(colorpickermenu);\n\t\tHBox box4 = new HBox(5);\n\t\tButton but = new Button(\"Cancel\");\n\t\tbut.setPadding(new Insets(5));\n\t\tButton but2 = new Button(\"Submit\");\n\t\tbut2.setPadding(new Insets(5));\n\t\tbox4.getChildren().addAll(but,but2);\n\t\tuicontrols.getChildren().addAll(box0,box1,box2,box3,box5,box6,box7,box4);\n\t\tbut.setOnAction((event) -> { input.close(); });\n\t\tbut2.setOnAction((event) -> {\n\t\t\tuserSelectedConstellationFileName = cdbs.get(consts.getValue());\n\t\t\tlong i = validateInput();\n\t\t\tif (i == 0) {\n\t\t\t\tchartTheStars();\n\t\t\t\tinput.close();\n\t\t\t} else {\n\t\t\t\tGUIerrorout = new Alert(AlertType.ERROR, getGUIErrorMsg(i));\n\t\t\t\tGUIerrorout.showAndWait();\n\t\t\t}\n });\n\t\tpane.setTop(mainmenu);\n\t\tpane.setCenter(uicontrols);\n\t\tpane.setPadding(new Insets(10));\n\t\tScene scene = new Scene(pane, 520, 310);\n\t\tinput.setScene(scene);\n\t}", "private void setOnClickListeners() {\n now_playing_previous_button.setOnClickListener(this::handleTransportControls);\n\n now_playing_play_button.setOnClickListener(this::handleTransportControls);\n\n now_playing_next_button.setOnClickListener(this::handleTransportControls);\n }", "private void addListeners() {\r\n updateMethod.addActionListener(new ActionListener() {\r\n @Override\r\n public void actionPerformed(ActionEvent e) {\r\n enableFieldBasedOnUpdateMethod();\r\n }\r\n });\r\n cbUseLeakyLearning.addActionListener(this);\r\n cbUseLeakyLearning.setActionCommand(\"useLeakyLearning\");\r\n }", "private void initButtonsListener(){\n initDraw();\n initResign();\n initRedo();\n }", "private void initControls()\r\n\t{\r\n\t\tif (deltager != null)\r\n\t\t{\r\n\t\t\ttxfInput[0].setText(deltager.getNavn());\r\n\t\t\ttxfInput[1].setText(\"\" + deltager.getTelefonNr());\r\n\t\t\ttxfInput[2].setText(deltager.getAdresse().getVej());\r\n\t\t\ttxfInput[3].setText(\"\" + deltager.getAdresse().getNr());\r\n\t\t\ttxfInput[4].setText(deltager.getAdresse().getEtage());\r\n\t\t\ttxfInput[5].setText(\"\" + deltager.getAdresse().getPostNr());\r\n\t\t\ttxfInput[6].setText(deltager.getAdresse().getBy());\r\n\t\t\ttxfInput[7].setText(deltager.getAdresse().getLand());\r\n\t\t} \r\n\t\telse\r\n\t\t{\r\n\t\t\ttxfInput[0].clear();\r\n\t\t\ttxfInput[1].clear();\r\n\t\t\ttxfInput[2].clear();\r\n\t\t\ttxfInput[3].clear();\r\n\t\t\ttxfInput[4].clear();\r\n\t\t\ttxfInput[5].clear();\r\n\t\t\ttxfInput[6].clear();\r\n\t\t\ttxfInput[7].clear();\r\n\t\t}\r\n\t}", "protected void initListeners() {\n\t\tfinal StyledText textWidget = fSourceViewer.getTextWidget();\n\t\ttextWidget.addVerifyListener(new VerifyListener() {\n\t\t\t@Override\n\t\t\tpublic void verifyText(VerifyEvent e) {\n\t\t\t\tint start = getExt5().widgetOffset2ModelOffset(e.start);\n\t\t\t\tint end = getExt5().widgetOffset2ModelOffset(e.end);\n\t\t\t\tContainer atStart = fContainerManager\n\t\t\t\t\t\t.getContainerHavingOffset(start);\n\t\t\t\tContainer atEnd = fContainerManager\n\t\t\t\t\t\t.getContainerHavingOffset(end);\n\n\t\t\t\t/* Text replaced */\n\t\t\t\tif ((atStart != null && start != atStart.getPosition()\n\t\t\t\t\t\t.getOffset())\n\t\t\t\t\t\t|| (atEnd != null && e.end != atEnd.getPosition()\n\t\t\t\t\t\t\t\t.getOffset())) {\n\t\t\t\t\te.doit = false;\n\t\t\t\t\treturn;\n\t\t\t\t}\n\n\t\t\t\t/* XXX Visibility */\n\t\t\t\t// fContainerManager.updateContainerVisibility(false);\n\t\t\t}\n\t\t});\n\n\t\ttextWidget.addVerifyKeyListener(new VerifyKeyListener () {\n\n\t\t\t@Override\n\t\t\tpublic void verifyKey(VerifyEvent e) {\n\t\t\t\tOptional<IEditorLocation> position = fContainerManager.getCursonPosition();\n\t\t\t\tint action = getAction(e);\n\t\t\t\tif (position.isPresent()) {\n\t\t\t\t\tif (!position.get().getEditor().handleKey(e)) {\n\t\t\t\t\t\tif (action == SWT.NULL && e.character != 0) {\n\t\t\t\t\t\t\tIEditorLocation replace = fContainerManager.getSelectionModel().replace(String.valueOf(e.character));\n\t\t\t\t\t\t\tfContainerManager.setCursorPosition(replace);\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tdoAction(action);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\te.doit = false;\n\t\t\t\t} else {\n\t\t\t\t\tif (action == SWT.NULL) {\n\t\t\t\t\t\tif (e.character == SWT.DEL) {\n\t\t\t\t\t\t\taction = ST.DELETE_NEXT;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tif (action != SWT.NULL) {\n\t\t\t\t\t\tint caretOffset = getExt5().widgetOffset2ModelOffset(textWidget.getCaretOffset());\n\t\t\t\t\t\tswitch (action) {\n\t\t\t\t\t\tcase ST.COLUMN_PREVIOUS:\n\t\t\t\t\t\tcase ST.SELECT_COLUMN_PREVIOUS:\n\t\t\t\t\t\t\te.doit = caretPositionChange(caretOffset, false);\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase ST.COLUMN_NEXT:\n\t\t\t\t\t\tcase ST.SELECT_COLUMN_NEXT:\t\n\t\t\t\t\t\t\te.doit = caretPositionChange(caretOffset, true);\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase ST.DELETE_NEXT:\n\t\t\t\t\t\t\tContainer container = fContainerManager\n\t\t\t\t\t\t\t\t\t.getContainerHavingOffset(caretOffset);\n\t\t\t\t\t\t\tif (container != null) {\n\t\t\t\t\t\t\t\tcontainer.destroy();\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\tcase ST.DELETE_PREVIOUS:\n\t\t\t\t\t\t\tContainer prevContainer = fContainerManager\n\t\t\t\t\t\t\t\t\t.getContainerHavingOffset(caretOffset - 1);\n\t\t\t\t\t\t\tif (prevContainer != null) {\n\t\t\t\t\t\t\t\tprevContainer.destroy();\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\n\t\t/*\n\t\t * If caret is inside Container's text region, moving it to the end of\n\t\t * line\n\t\t */\n\t\ttextWidget.addCaretListener(new CaretListener() {\n\t\t\t@Override\n\t\t\tpublic void caretMoved(CaretEvent e) {\n\t\t\t\tPoint selection = fSourceViewer.getSelectedRange();\n\t\t\t\tif (selection.y == 0) {\n\t\t\t\t\tint caretOffset = getExt5().widgetOffset2ModelOffset(e.caretOffset);\n\t\t\t\t\tContainer container = fContainerManager\n\t\t\t\t\t\t\t.getContainerHavingOffset(caretOffset);\n\t\t\t\t\tif (container != null) {\n\t\t\t\t\t\tPosition position = container.getPosition();\n\t\t\t\t\t\tif (caretOffset != position.getOffset()) {\n\t\t\t\t\t\t\t/* Move caret to the Pad's border */\n\t\t\t\t\t\t\ttextWidget.setCaretOffset(getExt5().modelOffset2WidgetOffset(position.getOffset()\n\t\t\t\t\t\t\t\t\t+ position.getLength()));\n\t\t\t\t\t\t\tfContainerManager.selectEditor(null);\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\t\n\t\ttextWidget.addMenuDetectListener(new MenuDetectListener() {\n\t\t\t\n\t\t\t@Override\n\t\t\tpublic void menuDetected(MenuDetectEvent e) {\n\t\t\t\tPoint control = textWidget.toControl(e.x, e.y);\n\t\t\t\tOptional<ITextEditor<?>> editor = fContainerManager.getEditorAt(control.x, control.y);\n\t\t\t\twhile (editor.isPresent() && !(editor.get() instanceof IMenuContributor)) {\n\t\t\t\t\teditor = editor.get().getParent();\n\t\t\t\t}\n\t\t\t\tif (editor.isPresent()) {\n\t\t\t\t\tMenuManager menuManager = new MenuManager();\n\t\t\t\t\tMenu menu = menuManager.createContextMenu(textWidget);\n\t\t\t\t\t((IMenuContributor) editor.get()).contribute(menuManager);\n\t\t\t\t\tmenuManager.update(false);\n\t\t\t\t\tmenu.setLocation(e.x, e.y);\n\t\t\t\t\tmenu.setVisible(true);\n\t\t\t\t\te.doit = false;\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\t\t\n\t\ttextWidget.addFocusListener(new FocusListener() {\n\t\t\t\n\t\t\t@Override\n\t\t\tpublic void focusLost(FocusEvent e) {\n\t\t\t}\n\t\t\t\n\t\t\t@Override\n\t\t\tpublic void focusGained(FocusEvent e) {\n\t\t\t\tfContainerManager.activateEditor(null);\n\t\t\t}\n\t\t});\n\n\t}", "private void addChangeListeners() {\r\n myTetrisPanel.addPropertyChangeListener(myInfoPanel);\r\n myTetrisMenuBar.addPropertyChangeListener(myInfoPanel);\r\n myTetrisMenuBar.addPropertyChangeListener(myKeyAdapter);\r\n myTetrisMenuBar.addPropertyChangeListener(myTetrisPanel);\r\n addPropertyChangeListener(myTetrisMenuBar);\r\n myInfoPanel.addPropertyChangeListener(myTetrisMenuBar);\r\n }", "private void setupEvents(){\n btnOk.addActionListener(new ActionListener() {\n\n @Override\n public void actionPerformed(ActionEvent e) {\n isClick_ok = true;\n password = jPasswordField1.getText();\n dispose();\n }\n });\n btnCancel.addActionListener(new ActionListener() {\n\n @Override\n public void actionPerformed(ActionEvent e) {\n dispose();\n }\n });\n }", "public void setListeners() {\n mbt_no_realizar_comentario.setOnClickListener(this);\n mbt_realizar_comentario_propietario.setOnClickListener(this);\n }", "private void createListeners() {\n btGeneralSave.addActionListener(new ActionListener() {\n @Override\n public void actionPerformed(ActionEvent e) {\n saveGeneralData();\n }\n });\n }", "private void control()\r\n\t\t{\n\t\tspinMin.addChangeListener(createMinListener());\r\n\t\tspinMax.addChangeListener(createMaxListener());\r\n\t\t}", "@Override\r\n public void initControl() {\n \r\n }", "public void addListeners()\n {\n nameEdit.addTextChangedListener(new TextWatcher()\n {\n @Override\n public void afterTextChanged(Editable arg0)\n {\n boolean isEmpty = nameEdit.getText().toString().isEmpty();\n acceptButton.setEnabled(!isEmpty);\n }\n\n @Override\n public void beforeTextChanged(CharSequence s, int start, int count, int after){}\n\n @Override\n public void onTextChanged(CharSequence s, int start, int before, int count) {}\n });\n\n numStandsEdit.addTextChangedListener(new TextWatcher()\n {\n @Override\n public void afterTextChanged(Editable s)\n {\n acceptButton.setEnabled(checkNumber());\n }\n @Override\n public void beforeTextChanged(CharSequence s, int start, int count, int after) {}\n\n @Override\n public void onTextChanged(CharSequence s, int start, int before, int count) {}\n });\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 initComponents() {\r\n titlePanel1 = new com.floreantpos.ui.TitlePanel();\r\n transparentPanel1 = new com.floreantpos.swing.TransparentPanel();\r\n posButton1 = new com.floreantpos.swing.PosButton();\r\n posButton2 = new com.floreantpos.swing.PosButton();\r\n transparentPanel2 = new com.floreantpos.swing.TransparentPanel();\r\n numberSelectionView1 = new com.floreantpos.ui.views.NumberSelectionView();\r\n noteView1 = new com.floreantpos.ui.views.NoteView();\r\n\r\n setDefaultCloseOperation(javax.swing.WindowConstants.DISPOSE_ON_CLOSE);\r\n titlePanel1.setTitle(com.floreantpos.POSConstants.MISC_ITEM);\r\n getContentPane().add(titlePanel1, java.awt.BorderLayout.NORTH);\r\n\r\n posButton1.setIcon(new javax.swing.ImageIcon(getClass().getResource(\"/images/finish_32.png\")));\r\n posButton1.setText(com.floreantpos.POSConstants.FINISH);\r\n posButton1.setPreferredSize(new java.awt.Dimension(120, 50));\r\n posButton1.addActionListener(new java.awt.event.ActionListener() {\r\n public void actionPerformed(java.awt.event.ActionEvent evt) {\r\n doFinish(evt);\r\n }\r\n });\r\n\r\n transparentPanel1.add(posButton1);\r\n\r\n posButton2.setIcon(new javax.swing.ImageIcon(getClass().getResource(\"/images/cancel_32.png\")));\r\n posButton2.setText(com.floreantpos.POSConstants.CANCEL);\r\n posButton2.setPreferredSize(new java.awt.Dimension(120, 50));\r\n posButton2.addActionListener(new java.awt.event.ActionListener() {\r\n public void actionPerformed(java.awt.event.ActionEvent evt) {\r\n doCancel(evt);\r\n }\r\n });\r\n\r\n transparentPanel1.add(posButton2);\r\n\r\n getContentPane().add(transparentPanel1, java.awt.BorderLayout.SOUTH);\r\n\r\n transparentPanel2.setLayout(new java.awt.BorderLayout());\r\n\r\n numberSelectionView1.setPreferredSize(new java.awt.Dimension(220, 392));\r\n numberSelectionView1.setTitle(com.floreantpos.POSConstants.PRICE);\r\n transparentPanel2.add(numberSelectionView1, java.awt.BorderLayout.WEST);\r\n\r\n noteView1.setBorder(javax.swing.BorderFactory.createTitledBorder(null, com.floreantpos.POSConstants.ITEM_NAME, javax.swing.border.TitledBorder.CENTER, javax.swing.border.TitledBorder.DEFAULT_POSITION));\r\n transparentPanel2.add(noteView1, java.awt.BorderLayout.CENTER);\r\n\r\n getContentPane().add(transparentPanel2, java.awt.BorderLayout.CENTER);\r\n\r\n java.awt.Dimension screenSize = java.awt.Toolkit.getDefaultToolkit().getScreenSize();\r\n setBounds((screenSize.width-786)/2, (screenSize.height-452)/2, 786, 452);\r\n }", "void configureButtonListener();", "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 }", "private void initHandlers() {\n setOnAction(new EventHandler<ActionEvent>() {\n\n @Override\n public void handle(ActionEvent arg0) {\n System.out.println(\"-5\");\n parseAndFormatInput();\n }\n });\n\n focusedProperty().addListener(new ChangeListener<Boolean>() {\n\n @Override\n public void changed(ObservableValue<? extends Boolean> observable, Boolean oldValue, Boolean newValue) {\n if (!newValue.booleanValue()) {\n System.out.println(\"1\");\n parseAndFormatInput();\n }\n }\n });\n\n // Set text in field if BigDecimal property is changed from outside.\n numberProperty().addListener(new ChangeListener<BigDecimal>() {\n\n @Override\n public void changed(ObservableValue<? extends BigDecimal> obserable, BigDecimal oldValue, BigDecimal newValue) {\n if (newValue.toBigInteger().signum() < 0) {\n newValue = new BigDecimal(1);\n }\n setText(nf.format(newValue));\n }\n });\n\n textProperty().addListener(new ChangeListener<String>() {\n @Override\n public void changed(ObservableValue<? extends String> observableValue, String s, String t1) {\n try {\n int newValue = Integer.parseInt(t1);\n if (newValue < NumberSpinner.MIN) newValue = NumberSpinner.MIN;\n if (newValue > NumberSpinner.MAX+1) newValue = NumberSpinner.MAX+1;\n setText(newValue+\"\");\n } catch (NumberFormatException e) {\n setText(s);\n }\n }\n });\n }", "private void initTextFields()\n\t{\n\t\talpha_min_textfield.setText(String.valueOf(rangeSliders.get(\"alpha\").getLowValue()));\n\t\talpha_max_textfield.setText(String.valueOf(rangeSliders.get(\"alpha\").getHighValue()));\n\t\teta_min_textfield.setText(String.valueOf(rangeSliders.get(\"eta\").getLowValue()));\n\t\teta_max_textfield.setText(String.valueOf(rangeSliders.get(\"eta\").getHighValue()));\n\t\tkappa_min_textfield.setText(String.valueOf(rangeSliders.get(\"kappa\").getLowValue()));\n\t\tkappa_max_textfield.setText(String.valueOf(rangeSliders.get(\"kappa\").getHighValue()));\n\t\t\n\t\ttry {\n\t\t\t// Add listener for focus changes.\n//\t\t\tnumberOfDatasets_textfield.focusedProperty().addListener(new ChangeListener<Boolean>() {\n//\t\t\t @Override\n//\t\t\t public void changed(ObservableValue<? extends Boolean> arg0, Boolean oldPropertyValue, Boolean newPropertyValue)\n//\t\t\t {\n//\t\t\t updateNumberOfDatasets(null);\n//\t\t\t }\n//\t\t\t});\n//\t\t\tnumberOfDivisions_textfield.focusedProperty().addListener(new ChangeListener<Boolean>() {\n//\t\t\t @Override\n//\t\t\t public void changed(ObservableValue<? extends Boolean> arg0, Boolean oldPropertyValue, Boolean newPropertyValue)\n//\t\t\t {\n//\t\t\t updateNumberOfDivisions(null);\n//\t\t\t }\n//\t\t\t});\n\t\t\t\n\t\t\t// Set initial values.\n\t\t\tnumberOfDatasetsToGenerate\t= Integer.parseInt(numberOfDatasets_textfield.getText());\n\t\t\tnumberOfDivisions\t\t\t= Integer.parseInt(numberOfDivisions_textfield.getText());\n\t\t\t\n\t\t\t// Disable number of divisions by default (since random sampling is enabled by default).\n\t\t\tnumberOfDivisions_textfield.setDisable(true);\n\t\t}\n\t\t\n\t\tcatch (NumberFormatException e) {\n\t\t\te.printStackTrace();\n\t\t}\n\t}", "private void setupListeners()\n\t{\n\t\tfinal String query = \"INSERT INTO\" + \"`\" + table + \"` \" + getFields() + \"VALUES\" + getValues();\n\t\t\n\t\tqueryButton.addActionListener(new ActionListener()\n\t\t{\n\t\t\tpublic void actionPerformed(ActionEvent click)\n\t\t\t{\n\t\t\t\tbaseController.getDataController().submitUpdateQuery(query);\n\t\t\t}\n\t\t});\n\t}", "private void initializeListeners() {\n llBack.setOnClickListener(this);\n btnChange.setOnClickListener(this);\n btnNext.setOnClickListener(this);\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}", "@Override\n protected void setListener() {\n findView(R.id.btnClear).setOnClickListener(this);\n findView(R.id.btnSave).setOnClickListener(this);\n\n ivGraffit.setOnTouchListener(new GraffitTouchListener());\n }", "private void init() {\n setDefaultCloseOperation(EXIT_ON_CLOSE);\n controlPanel = new ControlPanel(this);\n canvas = new DrawingPanel(this);\n shapeController = ShapeController.getInstance();\n\n shapeController.setFactory(new RegularPolygonShapeFactory(6, 50));\n optionsPanel = new RegularPolygonOptionsPanel(this, 6, 50);\n toolPanel = new ToolPanel(this);\n\n add(optionsPanel, BorderLayout.NORTH);\n add(canvas, BorderLayout.CENTER);\n add(controlPanel, BorderLayout.SOUTH);\n add(toolPanel, BorderLayout.EAST);\n\n pack();\n }", "public void setListeners() {\n buttonPanel.getAddTask().addActionListener(new ActionListener() {\n @Override\n public void actionPerformed(ActionEvent e) {\n if (toDoList.toDoListLength() >= 6) {\n JDialog errorBox = new JDialog();\n JLabel errorMessage = new JLabel(\"You already have 6 Tasks remove one to add another\");\n errorBox.add(errorMessage);\n errorBox.setSize(450, 100);\n errorBox.setVisible(true);\n } else {\n addDialog = new AddDialog();\n addDialog.setVisible(true);\n addDialog.setSize(500, 500);\n acceptListener();\n }\n }\n });\n saveListener();\n removeListener();\n completeListener();\n editSetup();\n }", "public ChampionSelectGUI() {\n\t\tsetupPanel();\n\t\tsetupScroll();\n\t\tsetupCenterPanel();\n\t\tsetupBottomPanel();\n\t\tsetupSidePanels();\n\t\taddWindowListener(this);\n\t}", "private void addEventsToTextBox() {\n \t\ttextBox.addFocusHandler(this);\n \t\ttextBox.addBlurHandler(this);\n \t\ttextBox.addKeyDownHandler(this);\n \t\ttextBox.addKeyUpHandler(this);\n \t\ttextBox.addKeyPressHandler(this);\t\t\n \t}", "@Override\n\tpublic void setListeners() {\n\t\tet1.setOnClickListener(this);\n\t\tet2.setOnClickListener(this);\n\t\tet3.setOnClickListener(this);\n\t\tet4.setOnClickListener(this);\n\t\tet5.setOnClickListener(this);\n\t\tet6.setOnClickListener(this);\n\t\tet7.setOnClickListener(this);\n\t\tet8.setOnClickListener(this);\n\t\tet9.setOnClickListener(this);\n\t\tet10.setOnClickListener(this);\n\t\tet11.setOnClickListener(this);\n\t\tet12.setOnClickListener(this);\n\t\tet13.setOnClickListener(this);\n\t\tet14.setOnClickListener(this);\n\t}", "@Override\n\tprotected void InitButtonListener() {\n\t\ttextViewAvgInital.setOnClickListener(new View.OnClickListener() {\n\t\t\t\n\t\t\t@Override\n\t\t\tpublic void onClick(View v) {\n\t\t\t\t// TODO Auto-generated method stub\n\t\t\t\tCursurIndex = 1;\n\t\t\t\tHandleCursurDisplay.sendMessage(HandleCursurDisplay.obtainMessage(CursurIndex));\n\t\t\t\tClickAverageInitial();\n\t\t\t}\n\t\t});\n\t\ttextViewDaysInital.setOnClickListener(new View.OnClickListener() {\n\t\t\t\n\t\t\t@Override\n\t\t\tpublic void onClick(View v) {\n\t\t\t\t// TODO Auto-generated method stub\n\t\t\t\tCursurIndex = 2;\n\t\t\t\tHandleCursurDisplay.sendMessage(HandleCursurDisplay.obtainMessage(CursurIndex));\n\t\t\t\tClickDaysInitial();\n\t\t\t}\n\t\t});\t\t\n\t\timgbtnOK.setOnClickListener(new View.OnClickListener() {\n\t\t\t\n\t\t\t@Override\n\t\t\tpublic void onClick(View v) {\n\t\t\t\t// TODO Auto-generated method stub\n\t\t\t\tCursurIndex = 3;\n\t\t\t\tHandleCursurDisplay.sendMessage(HandleCursurDisplay.obtainMessage(CursurIndex));\n\t\t\t\tClickOK();\n\t\t\t}\n\t\t});\t\t\n\t}", "private void initListeners() {\n btnCadastrar.setOnClickListener(this);\n cadastrar.setOnClickListener(this);\n }", "private void setEventListener() {\n mCameraView.addCameraKitListener(this);\n mCameraButton.setOnClickListener(this);\n mCameraButtonCloud.setOnClickListener(this);\n }", "private void initGui() {\n initSeekBar();\n initDateFormatSpinner();\n GuiHelper.defineButtonOnClickListener(view, R.id.settings_buttonSave, this);\n\n }", "private void createControls() {\n JScrollPane votesScroller = new JScrollPane(votesTable, JScrollPane.VERTICAL_SCROLLBAR_AS_NEEDED, JScrollPane.HORIZONTAL_SCROLLBAR_AS_NEEDED);\n JPanel bottomPanel = new JPanel();\n JPanel buttonsPanel = new JPanel();\n JLabel votesLabel = new JLabel(\"<html><div style='text-align: center; width: \" + PANEL_SIZE.width + \";'><h3>Votes</h3></html>\");\n \n // Enables/disables buttons.\n enableAdding();\n \n // Hooks up the controller on the action listeners.\n loadButton.addActionListener((e) -> controller.loadVotes());\n addButton.addActionListener((e) -> {\n // Uses the selected indexes of the combo boxes to determine the candidate IDs.\n ArrayList<Integer> candidateIds = new ArrayList<>();\n comboBoxes.forEach((comboBox) -> candidateIds.add(comboBox.getSelectedIndex() - 1));\n \n // Requests that the controller adds a vote with the given candidate IDs.\n controller.addVote(candidateIds);\n });\n \n // Lays out the components.\n panel.setLayout(new BorderLayout());\n panel.add(votesLabel, BorderLayout.PAGE_START);\n panel.add(votesScroller, BorderLayout.CENTER);\n panel.add(bottomPanel, BorderLayout.PAGE_END);\n \n bottomPanel.setLayout(new BorderLayout());\n bottomPanel.add(createComboBoxes(), BorderLayout.PAGE_START);\n bottomPanel.add(buttonsPanel, BorderLayout.PAGE_END);\n \n buttonsPanel.setLayout(new FlowLayout(FlowLayout.CENTER));\n buttonsPanel.add(addButton);\n buttonsPanel.add(loadButton);\n \n \n panel.setPreferredSize(PANEL_SIZE);\n }", "private void initialize() {\n\t\tsetLayout(null);\n\t\t\n\t\tJTextPane txtName = new JTextPane();\n\t\ttxtName.setFont(new Font(\"YuKyokasho Yoko\", Font.BOLD, 17));\n\t\ttxtName.setText(\"\");\n\t\ttxtName.setBounds(445, 112, 277, 42);\n\t\tadd(txtName);\n\t\ttxtName.setOpaque(false);\n\t\t\n\t\tJTextPane txtCoordinatelat = new JTextPane();\n\t\ttxtCoordinatelat.setText(\"\");\n\t\ttxtCoordinatelat.setFont(new Font(\"YuKyokasho Yoko\", Font.BOLD, 17));\n\t\ttxtCoordinatelat.setBounds(450, 203, 277, 42);\n\t\tadd(txtCoordinatelat);\n\t\ttxtCoordinatelat.addKeyListener(new KeyAdapter(){\n\t\t\tpublic void keyTyped(KeyEvent e) {\n\t\t\t\tchar c = e.getKeyChar();\n\t\t\t\tif(!Character.isDigit(c)&& c!=127&& c!=8 && c!='.') {\n\t\t\t\t\tJOptionPane.showMessageDialog(null, \"Please enter the number\", \"Warning\",JOptionPane.WARNING_MESSAGE); \n\t\t\t\t\te.consume();\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\t\ttxtCoordinatelat.setOpaque(false);\n\t\t\n\t\tJTextPane txtCoordinatelng = new JTextPane();\n\t\ttxtCoordinatelng.setText(\"\");\n\t\ttxtCoordinatelng.setFont(new Font(\"YuKyokasho Yoko\", Font.BOLD, 17));\n\t\ttxtCoordinatelng.setBounds(450, 304, 277, 42);\n\t\tadd(txtCoordinatelng);\n\t\ttxtCoordinatelng.addKeyListener(new KeyAdapter(){\n\t\t\tpublic void keyTyped(KeyEvent e) {\n\t\t\t\tchar c = e.getKeyChar();\n\t\t\t\tif(!Character.isDigit(c)&& c!=127&& c!=8 && c!='.') {\n\t\t\t\t\tJOptionPane.showMessageDialog(null, \"Please enter the number\", \"Warning\",JOptionPane.WARNING_MESSAGE); \n\t\t\t\t\te.consume();\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\t\ttxtCoordinatelng.setOpaque(false);\n\t\t\n\t\tJTextPane txtTotaldocks = new JTextPane();\n\t\ttxtTotaldocks.setText(\"\");\n\t\ttxtTotaldocks.setFont(new Font(\"YuKyokasho Yoko\", Font.BOLD, 17));\n\t\ttxtTotaldocks.setBounds(450, 393, 277, 42);\n\t\tadd(txtTotaldocks);\n\t\ttxtTotaldocks.addKeyListener(new KeyAdapter(){\n\t\t\tpublic void keyTyped(KeyEvent e) {\n\t\t\t\tchar c = e.getKeyChar();\n\t\t\t\tif(!Character.isDigit(c)&& c!=127&& c!=8) {\n\t\t\t\t\tJOptionPane.showMessageDialog(null, \"The number of the docks can only be a whole number\", \"Warning\",JOptionPane.WARNING_MESSAGE); \n\t\t\t\t\te.consume();\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\t\ttxtTotaldocks.setOpaque(false);\n\t\t\n\t\t/* Background pic */\n\t\tImageIcon background = new ImageIcon(getClass().getResource(\"/main/resources/com/team15/ebrs/images/add.png\"));\n\t\tJLabel lblbackground = new JLabel(background);\n\t\tlblbackground.setBounds(0, 0, 960, 518);\n\t\tadd(lblbackground);\n\t\t\n\t\t\n\t\tJButton btnNext = new JButton(\"Save\");\n\t\tbtnNext.setCursor(new Cursor(Cursor.HAND_CURSOR));\n\t\tbtnNext.addActionListener(new ActionListener() {\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\tif(txtName.getText().equals(\"\")||txtCoordinatelat.getText().equals(\"\")||txtCoordinatelng.getText().equals(\"\")||txtTotaldocks.getText().equals(\"\")) {\n\t\t\t\t\tJOptionPane.showMessageDialog(null, \"The fields cannot be empty.\", \"Information\",JOptionPane.WARNING_MESSAGE); \n\t\t\t\t}else{\n\t\t\t\t\tString stationName = txtName.getText().trim();\n\t\t\t\t\tdouble coordinatelat = Double.parseDouble(txtCoordinatelat.getText().trim());\n\t\t\t\t\tdouble coordinatelng = Double.parseDouble(txtCoordinatelng.getText().trim());\n\t\t\t\t\tint total_docks = Integer.parseInt(txtTotaldocks.getText().trim());\n\t\t\t\t\ttry {\n\t\t\t\t\t\tDockingStation newStation = new DockingStation(stationName,coordinatelat,coordinatelng,total_docks);\n\t\t\t\t\t\tif(dsDAO.addDockingStation(newStation)) {\n\t\t\t\t\t\t\tJOptionPane.showMessageDialog(null, \"The new station is successfully registered\", \"Information\",JOptionPane.WARNING_MESSAGE); \n\t\t\t\t\t\t}else {\n\t\t\t\t\t\t\tJOptionPane.showMessageDialog(null, \"Error! The station name is already registered \\nPlease try another name\", \"Information\",JOptionPane.WARNING_MESSAGE); \n\t\t\t\t\t\t}\n\t\t\t\t\t}catch(Exception nullPointerException ) {\n\t\t\t\t\t\tJOptionPane.showMessageDialog(null, \"Please fill out the information\");\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\t\tbtnNext.setBounds(758, 419, 145, 93);\n\t\tadd(btnNext);\n\t\tbtnNext.setOpaque(false);\n\n\t\tmainFrame.getRootPane().setDefaultButton(btnNext);\n\n\t\tJButton btnBack = new JButton(\"Back\");\n\t\tbtnBack.setCursor(new Cursor(Cursor.HAND_CURSOR));\n\t\tbtnBack.addActionListener(new ActionListener() {\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\tStationPanel stationScreen = new StationPanel(mainFrame);\n\t\t\t\tmainFrame.setContentPane(stationScreen);\n\t\t\t\tmainFrame.revalidate();\n\t\t\t}\n\t\t});\n\t\tbtnBack.setBounds(0, -13, 75, 76);\n\t\tadd(btnBack);\n\t\tbtnBack.setOpaque(false);\n\n\t}", "protected void setupViewControllers() {\r\n\t\tViewControlsLayer viewControlsLayer = new ViewControlsLayer();\r\n\t\t@SuppressWarnings(\"unused\")\r\n\t\tToolTipController toolTipController = new ToolTipController(getWWD(),\r\n\t\t\t\tAVKey.DISPLAY_NAME, null);\r\n\t\t@SuppressWarnings(\"unused\")\r\n\t\tHighlightController highlightController = new HighlightController(getWWD(),\r\n\t\t\t\tSelectEvent.ROLLOVER);\r\n\r\n\t\tinsertBeforeCompass(viewControlsLayer);\r\n\t\tgetWWD().addSelectListener(new ViewControlsSelectListener(getWWD(),\r\n\t\t\t\tviewControlsLayer));\r\n\t}", "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 setup() {\n\t\t//set which chars are allowed in the textfield\n\t\ttextfield_floor_number.setTextFormatter(new TextFormatter<>(change -> {\n\t\t\tString newText = change.getControlNewText();\n\t\t\t//only positive integers without leading sing\n\t\t\tif (newText.matches(\"([1-9][0-9]*)?\")) {\n\t\t\t\treturn change;\n\t\t\t}\n\t\t\treturn null;\n\t\t}));\n\t\t\n\t\t//listen for selection changes on the elevator listview. Update the selected index.\n\t\tlistview_elevators.getSelectionModel().selectedItemProperty().addListener(new ChangeListener<String>() {\n\t\t\tpublic void changed(ObservableValue<? extends String> ov, String oldValue, String newValue) {\n\t\t\t\tselectedElevator = listview_elevators.getSelectionModel().getSelectedIndex();\n\t\t\t\t\n\t\t\t\tif(updateData == null) {\n\t\t\t\t\tthrow new NullPointerException(\"MainGuiController.setup() NullPointerException\");\n\t\t\t\t}\n\t\t\t\t//getSelectedIndex() returns -1 if no line is selected\n\t\t\t\tif(selectedElevator < 0) {\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t\tupdateData.setSelectedElevator(selectedElevator);\n\t\t\t}\n\t\t});\n\t}", "TvShowScraperNfoSettingsPanel() {\n checkBoxListener = e -> checkChanges();\n comboBoxListener = e -> checkChanges();\n\n // UI init\n initComponents();\n initDataBindings();\n\n // data init\n\n // implement checkBoxListener for preset events\n settings.addPropertyChangeListener(evt -> {\n if (\"preset\".equals(evt.getPropertyName())) {\n buildComboBoxes();\n }\n });\n\n buildCheckBoxes();\n buildComboBoxes();\n }", "public JInputPanel() {\n initComponents();\n listeners = new Vector();\n blue =txtBlue.getValue();\n green =txtGreen.getValue();\n red =txtRed.getValue();\n \n// sldRe.addActionListener(new ActionListener() {\n// public void actionPerformed(ActionEvent e) {\n// \n// }});\n \n \n }", "private void addListeners() {\n table.addValueChangeListener((Property.ValueChangeListener) this);\n// selectedCustomer.comboBoxSelectCustomer.addValueChangeListener((Property.ValueChangeListener) this);\n }", "private void initListeners() {\n comboBox.comboBoxListener(this::showProgramData);\n view.refreshListener(actionEvent -> scheduledUpdate());\n\n }", "private void initialize() {\n\t\tframe = new JFrame();\n\t\tframe.setResizable(false);\n\t\tframe.setBounds(100, 100, 210, 469);\n\t\tframe.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);\n\t\tframe.getContentPane().setLayout(null);\n\n\t\ttextField = new JTextField();\n\t\ttextField.setHorizontalAlignment(SwingConstants.CENTER);\n\t\ttextField.setFont(new Font(\"Gisha\", Font.PLAIN, 14));\n\t\ttextField.setEditable(false);\n\t\ttextField.setBounds(10, 11, 184, 46);\n\t\tframe.getContentPane().add(textField);\n\t\ttextField.setColumns(10);\n\n\t\tJLabel lblNewLabel = new JLabel(\"Instrctions:\");\n\t\tlblNewLabel.setBounds(10, 364, 135, 14);\n\t\tframe.getContentPane().add(lblNewLabel);\n\n\t\tlblNewLabel_1 = new JLabel(\"1. Press Enter to select number\");\n\t\tlblNewLabel_1.setBounds(10, 377, 184, 14);\n\t\tframe.getContentPane().add(lblNewLabel_1);\n\n\t\tlblPressSpace = new JLabel(\"2. Press Enter to select function\");\n\t\tlblPressSpace.setBounds(10, 391, 194, 14);\n\t\tframe.getContentPane().add(lblPressSpace);\n\n\t\tlblPressC = new JLabel(\"3. Press C to clear\");\n\t\tlblPressC.setBounds(10, 406, 135, 14);\n\t\tframe.getContentPane().add(lblPressC);\n\n\n\t\tfor(int i = 0;i<10;i++){\n\t\t\tnumberButton[i] = new JButton(String.valueOf(i));\n\t\t\tnumberButton[i].setFont(new Font(\"Tahoma\", Font.BOLD, 18));\n\t\t\tnumberButton[i].setBackground(new Color(224, 223, 219));\n\t\t\tframe.getContentPane().add(numberButton[i]);\n\t\t}\n\t\tnumberButton[7].setBounds(20, 68, 50, 50);\n\t\tnumberButton[8].setBounds(80, 68, 50, 50);\n\t\tnumberButton[9].setBounds(140, 68, 50, 50);\n\t\tnumberButton[4].setBounds(20, 129, 50, 50);\n\t\tnumberButton[5].setBounds(80, 129, 50, 50);\n\t\tnumberButton[6].setBounds(140, 129, 50, 50);\n\t\tnumberButton[1].setBounds(20, 190, 50, 50);\n\t\tnumberButton[2].setBounds(80, 190, 50, 50);\n\t\tnumberButton[3].setBounds(140, 190, 50, 50);\n\t\tnumberButton[0].setBounds(80, 251, 50, 50);\n\n\t\tfor(int i = 0;i<5;i++){\n\t\t\tfunctionButton[i] = new JButton(getFunc(i));\n\t\t\tfunctionButton[i].setFont(new Font(\"Tahoma\", Font.BOLD, 18));\n\t\t\tfunctionButton[i].setBackground(new Color(224, 223, 219));\n\t\t\tframe.getContentPane().add(functionButton[i]);\n\t\t}\n\t\tfunctionButton[0].setBounds(20, 251, 50, 50);\n\t\tfunctionButton[3].setBounds(140, 305, 50, 50);\n\t\tfunctionButton[1].setBounds(20, 305, 50, 50);\n\t\tfunctionButton[2].setBounds(80, 305, 50, 50);\n\t\tfunctionButton[4].setBounds(140, 251, 50, 50);\n\t\t////////////////////////////////////////////////////////////////////////\n\t}", "private void setButtonListener() {\n for(CellButton[] buttonsRow : mainFrame.getButtons()) {\n for(CellButton button :buttonsRow) {\n button.addButtonListener(this);\n }\n }\n }", "private void initialize() {\n\t\tfrmCoordinateConverter = new JFrame();\n\t\tfrmCoordinateConverter.setResizable(false);\n\t\tfrmCoordinateConverter.setForeground(SystemColor.menu);\n\t\tfrmCoordinateConverter.setTitle(\"Coordinate Converter\");\n\t\tfrmCoordinateConverter.setBounds(100, 100, 581, 167);\n\t\tfrmCoordinateConverter.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);\n\t\tfrmCoordinateConverter.getContentPane().setLayout(new BorderLayout(0, 0));\n\n\t\tJPanel panel_container = new JPanel();\n\t\tpanel_container.setBackground(SystemColor.menu);\n\t\tfrmCoordinateConverter.getContentPane().add(panel_container);\n\t\tpanel_container.setLayout(new FlowLayout(FlowLayout.CENTER, 5, 5));\n\n\t\tJPanel panel_entry = new JPanel();\n\t\tpanel_container.add(panel_entry);\n\n\t\tJLabel lblEnterCoordinates = new JLabel(\"Enter coordinates:\");\n\t\tpanel_entry.add(lblEnterCoordinates);\n\n\t\ttextField_1 = new JTextField();\n\t\tpanel_entry.add(textField_1);\n\t\ttextField_1.setColumns(10);\n\n\t\ttextField_2 = new JTextField();\n\t\tpanel_entry.add(textField_2);\n\t\ttextField_2.setColumns(10);\n\n\t\ttextField_3 = new JTextField();\n\t\tpanel_entry.add(textField_3);\n\t\ttextField_3.setColumns(10);\n\n\t\tJPanel panel_from = new JPanel();\n\t\tpanel_container.add(panel_from);\n\n\t\tJLabel lblFrom = new JLabel(\"From:\");\n\t\tpanel_from.add(lblFrom);\n\n\t\tJRadioButton rdbtnFromRect = new JRadioButton(\"Rectangular\");\n\t\tpanel_from.add(rdbtnFromRect);\n\t\tbuttonGroup.add(rdbtnFromRect);\n\n\t\tJRadioButton rdbtnFromCyl = new JRadioButton(\"Cylindrical\");\n\t\tpanel_from.add(rdbtnFromCyl);\n\t\tbuttonGroup.add(rdbtnFromCyl);\n\n\t\tJRadioButton rdbtnFromSph = new JRadioButton(\"Spherical\");\n\t\tpanel_from.add(rdbtnFromSph);\n\t\tbuttonGroup.add(rdbtnFromSph);\n\n\t\tJPanel panel_to = new JPanel();\n\t\tpanel_container.add(panel_to);\n\n\t\tJLabel lblTo = new JLabel(\"To:\");\n\t\tpanel_to.add(lblTo);\n\n\t\tJRadioButton rdbtnToRect = new JRadioButton(\"Rectangular\");\n\t\tbuttonGroup_1.add(rdbtnToRect);\n\t\tpanel_to.add(rdbtnToRect);\n\n\t\tJRadioButton rdbtnToCyl = new JRadioButton(\"Cylindrical\");\n\t\tbuttonGroup_1.add(rdbtnToCyl);\n\t\tpanel_to.add(rdbtnToCyl);\n\n\t\tJRadioButton rdbtnToSph = new JRadioButton(\"Spherical\");\n\t\tbuttonGroup_1.add(rdbtnToSph);\n\t\tpanel_to.add(rdbtnToSph);\n\n\t\tJButton btnNewButton = new JButton(\"Convert!\");\n\t\tpanel_entry.add(btnNewButton);\n\t\tbtnNewButton.addActionListener(new ActionListener() {\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\tif (isDouble(textField_1.getText()) && isDouble(textField_1.getText())\n\t\t\t\t\t\t&& isDouble(textField_1.getText())) {\n\n\t\t\t\t\tdouble a = (Double.parseDouble(textField_1.getText()));\n\t\t\t\t\tdouble b = (Double.parseDouble(textField_2.getText()));\n\t\t\t\t\tdouble c = (Double.parseDouble(textField_3.getText()));\n\n\t\t\t\t\tif (rdbtnFromRect.isSelected() && rdbtnToCyl.isSelected()) {\n\t\t\t\t\t\tCylindrical coord = new Rectangular(a, b, c).toCylindrical();\n\n\t\t\t\t\t\ttextField_1.setText(Double.toString(coord.r));\n\t\t\t\t\t\ttextField_2.setText(Double.toString(coord.theta));\n\t\t\t\t\t\ttextField_3.setText(Double.toString(coord.z));\n\t\t\t\t\t} \n\t\t\t\t\telse if (rdbtnFromRect.isSelected() && rdbtnToSph.isSelected()) {\n\t\t\t\t\t\tSpherical coord = new Rectangular(a, b, c).toSpherical();\n\n\t\t\t\t\t\ttextField_1.setText(Double.toString(coord.rho));\n\t\t\t\t\t\ttextField_2.setText(Double.toString(coord.theta));\n\t\t\t\t\t\ttextField_3.setText(Double.toString(coord.phi));\n\t\t\t\t\t}\n\t\t\t\t\telse if (rdbtnFromCyl.isSelected() && rdbtnToRect.isSelected()) {\n\t\t\t\t\t\tRectangular coord = new Cylindrical(a, b, c).toRectangular();\n\n\t\t\t\t\t\ttextField_1.setText(Double.toString(coord.x));\n\t\t\t\t\t\ttextField_2.setText(Double.toString(coord.y));\n\t\t\t\t\t\ttextField_3.setText(Double.toString(coord.z));\n\t\t\t\t\t}\n\t\t\t\t\telse if (rdbtnFromCyl.isSelected() && rdbtnToSph.isSelected()) {\n\t\t\t\t\t\tSpherical coord = new Cylindrical(a, b, c).toSpherical();\n\n\t\t\t\t\t\ttextField_1.setText(Double.toString(coord.rho));\n\t\t\t\t\t\ttextField_2.setText(Double.toString(coord.theta));\n\t\t\t\t\t\ttextField_3.setText(Double.toString(coord.phi));\n\t\t\t\t\t}\n\t\t\t\t\telse if (rdbtnFromSph.isSelected() && rdbtnToRect.isSelected()) {\n\t\t\t\t\t\tRectangular coord = new Spherical(a, b, c).toRectangular();\n\n\t\t\t\t\t\ttextField_1.setText(Double.toString(coord.x));\n\t\t\t\t\t\ttextField_2.setText(Double.toString(coord.y));\n\t\t\t\t\t\ttextField_3.setText(Double.toString(coord.z));\n\t\t\t\t\t}\n\t\t\t\t\telse if (rdbtnFromSph.isSelected() && rdbtnToCyl.isSelected()) {\n\t\t\t\t\t\tCylindrical coord = new Spherical(a, b, c).toCylindrical();\n\n\t\t\t\t\t\ttextField_1.setText(Double.toString(coord.r));\n\t\t\t\t\t\ttextField_2.setText(Double.toString(coord.theta));\n\t\t\t\t\t\ttextField_3.setText(Double.toString(coord.z));\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\tJOptionPane.showMessageDialog(frmCoordinateConverter, \"Please enter numerical values only.\");\n\t\t\t\t}\n\t\t\t}\n\n\t\t});\n\n\t\tJButton btnHelp = new JButton(\"Help\");\n\t\tpanel_container.add(btnHelp);\n\t\tbtnHelp.addActionListener(new ActionListener() {\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\tJOptionPane.showMessageDialog(frmCoordinateConverter,\n\t\t\t\t\t\t\"Rectangular: (x, y, z)\\nCylindrical: (r, theta, z)\\nSpherical: (rho, theta, phi)\\n\"\n\t\t\t\t\t\t+ \"All angles measured in radians\");\n\t\t\t}\n\t\t});\n\t}", "public void assignDimensionalControls() {\n frame = imp1.getWindow();\n Component[] comps = frame.getComponents();\n try {\n cSelectorChannel_ = (ScrollbarWithLabel) comps[1];\n if (comps.length > 2) {\n tSelectorTime_ = (ScrollbarWithLabel) comps[2];\n }\n if (comps.length > 3) {\n zSelectorZSlice_ = (ScrollbarWithLabel) comps[3];\n }\n } catch (Exception ex) {\n }\n try {\n pSelectorPos = (ScrollbarWithLabel) comps[4];\n } catch (Exception ex) {\n System.out.println(\n \"Warning: Orientation indicators could not attach to Position dim. It might not be present.\");\n }\n// if (imp1.getRoi() == null && imp1.getCanvas().getMagnification() > 1) {\n// Rectangle rec = new Rectangle(imp1.getCanvas().getSrcRect());\n// imp1.setRoi(rec);\n// }\n// if (\"Yes\".equals(UseListener) && \"Yes\".equals(EnableIndicators)) {\n// //loadParams();\n// addListeners();\n// } else {\n// //UseListener = \"No\";\n// EnableIndicators = \"No\";\n// removeListeners();\n// }\n }", "private void initialize() {\r\n\t\tsetLabels();\r\n\t\tinitPoints();\r\n\t\tsetButtons();\r\n\t\tthis.setTitle(\"Digite os pesos dos pontos\");\r\n\t\tthis.setDefaultCloseOperation(WindowConstants.DISPOSE_ON_CLOSE);\r\n\t}", "private void setupPlayerControls() {\n ExtendableScene currScene = SceneManager.getSceneParent();\n\n // Controls for the player\n // Delegated to player controller\n currScene.setOnKeyPressed(PlayerController.get()::onKeyPressed);\n currScene.setOnKeyReleased(PlayerController.get()::onKeyReleased);\n\n // All mouse movement events (for turret rotation)\n view.getPane().setOnMouseMoved(view::changeMouseEvent);\n view.getPane().setOnMouseDragged(view::changeMouseEvent);\n\n // Setup player shooting\n view.getPane().setOnMousePressed(view::createBullet);\n }", "private void initComponents() {\n lblHAUF = new JLabel();\n jdcHAUF = new JDateChooser();\n lblStation = new JLabel();\n cmbStation = new JComboBox<>();\n lblRoom = new JLabel();\n cmbRoom = new JComboBox<>();\n cbKZP = new JCheckBox();\n\n //======== this ========\n setLayout(new FormLayout(\n \"default, $lcgap, pref, $lcgap, default:grow, $lcgap, default\",\n \"4*(default, $lgap), default\"));\n\n //---- lblHAUF ----\n lblHAUF.setText(\"text\");\n lblHAUF.setFont(new Font(\"Arial\", Font.PLAIN, 14));\n add(lblHAUF, CC.xy(3, 3));\n\n //---- jdcHAUF ----\n jdcHAUF.setFont(new Font(\"Arial\", Font.PLAIN, 14));\n jdcHAUF.addPropertyChangeListener(\"date\", e -> jdcDOBPropertyChange(e));\n add(jdcHAUF, CC.xy(5, 3));\n\n //---- lblStation ----\n lblStation.setText(\"text\");\n lblStation.setFont(new Font(\"Arial\", Font.PLAIN, 14));\n add(lblStation, CC.xy(3, 5));\n\n //---- cmbStation ----\n cmbStation.setFont(new Font(\"Arial\", Font.PLAIN, 14));\n cmbStation.addItemListener(e -> cmbStationItemStateChanged(e));\n add(cmbStation, CC.xy(5, 5));\n\n //---- lblRoom ----\n lblRoom.setText(\"text\");\n lblRoom.setFont(new Font(\"Arial\", Font.PLAIN, 14));\n add(lblRoom, CC.xy(3, 7));\n\n //---- cmbRoom ----\n cmbRoom.setFont(new Font(\"Arial\", Font.PLAIN, 14));\n cmbRoom.addItemListener(e -> cmbRoomItemStateChanged(e));\n add(cmbRoom, CC.xy(5, 7));\n\n //---- cbKZP ----\n cbKZP.setText(\"text\");\n cbKZP.addItemListener(e -> cbKZPItemStateChanged(e));\n add(cbKZP, CC.xywh(3, 9, 3, 1));\n // JFormDesigner - End of component initialization //GEN-END:initComponents\n }", "private void setInputListeners () {\r\n // initialize input state\r\n myLastKeyPressed = NO_KEY_PRESSED;\r\n myKeys = new TreeSet<Integer>();\r\n addKeyListener(new KeyAdapter() {\r\n @Override\r\n public void keyPressed (KeyEvent e) {\r\n // resets key after being used once. Does not affect getKeysPressed.\r\n if (myLastKeyPressed == e.getKeyCode()) {\r\n myLastKeyPressed = NO_KEY_PRESSED;\r\n }\r\n else {\r\n myLastKeyPressed = e.getKeyCode();\r\n }\r\n myKeys.add(e.getKeyCode());\r\n }\r\n\r\n @Override\r\n public void keyReleased (KeyEvent e) {\r\n myKeys.remove(e.getKeyCode());\r\n }\r\n });\r\n myLastMousePosition = NO_MOUSE_PRESSED;\r\n addMouseMotionListener(new MouseMotionAdapter() {\r\n @Override\r\n public void mouseDragged (MouseEvent e) {\r\n myLastMousePosition = e.getPoint();\r\n }\r\n });\r\n addMouseListener(new MouseAdapter() {\r\n @Override\r\n public void mousePressed (MouseEvent e) {\r\n myLastMousePosition = e.getPoint();\r\n myMouseClick = true;\r\n }\r\n\r\n @Override\r\n public void mouseReleased (MouseEvent e) {\r\n myLastMousePosition = NO_MOUSE_PRESSED;\r\n myMouseClick = false;\r\n }\r\n });\r\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 void setupWindowButtons(){\n focusPropertyButton(btnExitProgramPlannerPlanPane);\n focusPropertyButton(btnExitProgramPlannerShoppingListPane);\n focusPropertyButton(btnExitProgramPlannerCupboardPane);\n focusPropertyButton(btnMinimiseProgramPlannerPlanPlane);\n focusPropertyButton(btnMinimiseProgramPlannerShoppingListPane);\n focusPropertyButton(btnMinimiseProgramPlannerCupboardPane);\n focusPropertyButton(btnExitProgramMealsBrowsePane);\n focusPropertyButton(btnMinimiseProgramMealsBrowsePane);\n focusPropertyButton(btnExitProgramMealsAddPane);\n focusPropertyButton(btnMinimiseProgramMealsAddPane);\n focusPropertyButton(btnExitProgramIngredBrowse);\n focusPropertyButton(btnMinimiseProgramIngredBrowse);\n focusPropertyButton(btnExitProgramIngredAdd);\n focusPropertyButton(btnMinimiseProgramIngredAdd);\n\n }", "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}", "@Override\n\tpublic synchronized void registerEventListeners() {\n\t\tif (eventListeners != null) // already called\n\t\t\treturn;\n\t\teventListeners = EventListenerManagers.wrap(this);\n\t\tSelectionUpdateListener selectionUpdateListener = new SelectionUpdateListener();\n\t\tselectionUpdateListener.setHandler(this);\n\t\teventListeners.register(SelectionUpdateEvent.class, selectionUpdateListener);\n\n\t\tSelectionCommandListener selectionCommandListener = new SelectionCommandListener();\n\t\tselectionCommandListener.setHandler(this);\n\t\t// selectionCommandListener.setDataDomainID(dataDomain.getDataDomainID());\n\t\teventListeners.register(SelectionCommandEvent.class, selectionCommandListener);\n\n\t\tsuper.registerEventListeners();\n\n\n\t}", "private void makeControls() {\n Label label1 = new Label(\"Placement:\");\n textField = new TextField ();\n textField.setPrefWidth(300);\n\n // Task8 Start the game with the randomly selected piece placement\n textField.setText(\"AAO\");\n makePlacement(\"AAO\");\n\n Button button = new Button(\"Refresh\");\n button.setOnAction(new EventHandler<ActionEvent>() {\n @Override\n public void handle(ActionEvent e) {\n makePlacement(textField.getText());\n // Task8 Do not clear the textField in order to place pieces step by step.\n // textField.clear();\n }\n });\n HBox hb = new HBox();\n hb.getChildren().addAll(label1, textField, button);\n hb.setSpacing(10);\n hb.setLayoutX(130);\n hb.setLayoutY(VIEWER_HEIGHT - 50);\n controls.getChildren().add(hb);\n }", "private void setListeners() {\n\t\trefreshButton.addActionListener(new refreshButtonListener());\n\n\t\tthis.list.addMouseListener(new MouseAdapter() {\n\n\t\t\t@Override\n\t\t\tpublic void mouseClicked(MouseEvent event) {\n\t\t\t\tif (event.getClickCount() == 2 && list.getSelectedValue() != null && !list.getSelectedValue().equals(\"\") && tabs.getSelectedIndex() != -1) {\n\t\t\t\t\tlaunchDocument(tabs.getTitleAt(tabs.getSelectedIndex()), list.getSelectedValue());\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\n\t\ttabs.addChangeListener(new ChangeListener() {\n\n\t\t\t@Override\n\t\t\tpublic void stateChanged(ChangeEvent arg0) {\n\t\t\t\tif (!tabs.getTitleAt(tabs.getSelectedIndex()).equals(\"Chat\")) {\n\t\t\t\t\tlistmodel.clear();\n\t\t\t\t\tmakeRequest();\n\t\t\t\t}\n\t\t\t}\n\n\t\t});\n\t}", "protected void installListeners() {\n\t\tMappingMouseWheelListener mouseWheelHandler = \n\t\t\t\tnew MappingMouseWheelListener(this);\n\n\t\t// Handles mouse wheel events in the outline and graph component\n\t\tgraphOutline.addMouseWheelListener(mouseWheelHandler);\n\t\tgraphComponent.addMouseWheelListener(mouseWheelHandler);\n\n\t\tGraphOutlinePopupMouseAdapter outlinePoputListener = new \n\t\t\t\tGraphOutlinePopupMouseAdapter(this);\n\t\t\n\t\t// Installs the popup menu in the outline\n\t\tgraphOutline.addMouseListener(outlinePoputListener);\n\n\t\tGraphComponentPopupMouseAdapter componentPoputListener = new \n\t\t\t\tGraphComponentPopupMouseAdapter(this);\n\t\t\n\t\t// Installs the popup menu in the graph component\n\t\tgraphComponent.getGraphControl().addMouseListener(\n\t\t\t\tcomponentPoputListener);\n\t}", "public void init() {\n\t\t//Inits the WEST interactors\n\t\tstatusfield = new JTextField(TEXT_FIELD_SIZE);\n\t\tstatusbutton = new JButton(\"Change Status\");\n\t\tpicturefield = new JTextField(TEXT_FIELD_SIZE);\n\t\tpicturebutton = new JButton(\"Change Picture\");\n\t\tfriendfield = new JTextField(TEXT_FIELD_SIZE);\n\t\tfriendbutton = new JButton(\"Add Friend\");\n\t\t\n\t\tadd(statusfield, WEST);\n\t\tadd(statusbutton, WEST);\n\t\tadd(new JLabel(EMPTY_LABEL_TEXT), WEST);\n\t\tadd(picturefield, WEST);\n\t\tadd(picturebutton, WEST);\n\t\tadd(new JLabel(EMPTY_LABEL_TEXT), WEST);\n\t\tadd(friendfield, WEST);\n\t\tadd(friendbutton, WEST);\n\t\t\n\t\tstatusfield.addActionListener(this);\n\t\tfriendfield.addActionListener(this);\n\t\tpicturefield.addActionListener(this);\n\t\t\n\t\t//Inits the NORTH interactors\n\t\tJLabel namelabel = new JLabel(\"Name\");\n\t\tnamefield = new JTextField(TEXT_FIELD_SIZE);\n\t\tJButton add_button = new JButton(\"Add\");\n\t\tJButton delete_button = new JButton(\"Delete\");\n\t\tJButton lookup_button = new JButton(\"Lookup\");\n\t\t\n\t\tadd(namelabel, NORTH);\n\t\tadd(namefield, NORTH);\n\t\tadd(add_button, NORTH);\n\t\tadd(delete_button, NORTH);\n\t\tadd(lookup_button, NORTH);\n\t\t\n\t\taddActionListeners();\n\t\tcanvas = new FacePamphletCanvas();\n\t\tadd(canvas);\n }" ]
[ "0.6799707", "0.6702952", "0.66153467", "0.65518874", "0.65046984", "0.649198", "0.6465898", "0.6451478", "0.6400791", "0.63681513", "0.63257027", "0.6313513", "0.63091385", "0.6301201", "0.6286437", "0.6257706", "0.6250813", "0.6247865", "0.623161", "0.62306046", "0.6218074", "0.6216383", "0.6192538", "0.61816126", "0.61654043", "0.6156097", "0.6127952", "0.6112736", "0.61119473", "0.6110932", "0.61062413", "0.6098002", "0.60887915", "0.6080253", "0.6068312", "0.60621333", "0.6057942", "0.6050081", "0.60309726", "0.6020346", "0.6014903", "0.6014719", "0.60093725", "0.6007966", "0.6002431", "0.60013473", "0.5995535", "0.5977722", "0.5955931", "0.5943493", "0.59398735", "0.59371203", "0.5929351", "0.5927457", "0.5914326", "0.5900938", "0.589746", "0.5896485", "0.58951926", "0.5893268", "0.5883505", "0.5881202", "0.58740056", "0.5862397", "0.58595574", "0.5858946", "0.58561426", "0.5849037", "0.58337545", "0.5823559", "0.58176357", "0.5812919", "0.5804993", "0.58032626", "0.5799205", "0.579841", "0.5789792", "0.57773507", "0.5776557", "0.5773554", "0.57574767", "0.5753499", "0.57513237", "0.57408106", "0.5728694", "0.5728654", "0.57273734", "0.57266647", "0.5726376", "0.57252383", "0.57207185", "0.5720161", "0.5718454", "0.57169646", "0.5716448", "0.5709576", "0.5700664", "0.5690991", "0.56907815", "0.56882983" ]
0.7739398
0
adds a action listener to the JButton that sets the active index to the field nr of the button.
private void addPointSelectionButtonListener(final int fieldNr) { _selectionButtons[fieldNr].addActionListener(new ActionListener() { @Override public void actionPerformed(ActionEvent e) { _activeIndex = fieldNr; for (int i = 0; i < _selectionButtons.length; i++) { _selectionButtons[i].setForeground(Color.gray); } _selectionButtons[fieldNr].setForeground(Color.green); } }); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\tJButton btn = (JButton) e.getSource();\n\t lev_no = (int) btn.getClientProperty(\"column\") + 3 * ((int) btn.getClientProperty(\"row\"));\n\t\t\tselect.setVisible(false);\n\t\t\ttitle.setVisible(true);\n\t\t\tstart.setVisible(true);\n\t\t\texit.setVisible(true);\n\t\t\tlev_button.setVisible(true);\n\t \n\t\t}", "private void setButtonListener() {\n for(CellButton[] buttonsRow : mainFrame.getButtons()) {\n for(CellButton button :buttonsRow) {\n button.addButtonListener(this);\n }\n }\n }", "@Override\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\tJButton btn = (JButton)e.getSource();\n\t\t\t\tString num = btn.getText();\n\t\t\t\t\n\t\t\t\t//check if pressed btn is orange\n\t\t\t\tif(btn.getBackground()!=Color.orange){\n\t\t\t\t\ttfNums[numIndex].setText(num);\n\t\t\t\t\tbtn.setBackground(Color.orange);\n\t\t\t\t\t\n\t\t\t\t\tif(enteredNums[numIndex]!=null){\n\t\t\t\t\t\tbtns[enteredNums[numIndex]-1].setBackground(Color.white);\n\t\t\t\t\t}\n\t\t\t\t\tenteredNums[numIndex]=Integer.parseInt(num);\n\t\t\t\t\t\n\t\t\t\t\tif(numIndex==5){\n\t\t\t\t\t\tnumIndex=0;\n\t\t\t\t\t}else{\n\t\t\t\t\t\tnumIndex++;\n\t\t\t\t\t}\n\t\t\t\t}else{\n\t\t\t\t\t//cancel num\n\t\t\t\t\tbtn.setBackground(Color.white);\n\t\t\t\t\tfor(JTextField tf : tfNums){\n\t\t\t\t\t\tif(tf.getText().equals(num)){\n\t\t\t\t\t\t\ttf.setText(\"\");\n\t\t\t\t\t\t\ttf.setBackground(Color.white);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t\n\t\t\t}", "@Override\n\t\t\tpublic void actionPerformed(ActionEvent cb_e) {\n\t\t\t\tinx4 = cb[4].getSelectedIndex();\n\t\t\t}", "@Override\n\t\t\tpublic void actionPerformed(ActionEvent cb_e) {\n\t\t\t\tinx5 = cb[5].getSelectedIndex();\n\t\t\t}", "private void buttonListener(int x, int y) {\t\n\t\tbuttons[x][y].addActionListener(event -> controller.onClick(x, y));\n\t}", "@Override\n\t\t\tpublic void actionPerformed(ActionEvent cb_e) {\n\t\t\t\tinx0 = cb[0].getSelectedIndex();\n\t\t\t}", "@Override\n\t\t\tpublic void actionPerformed(ActionEvent cb_e) {\n\t\t\t\tinx3 = cb[3].getSelectedIndex();\n\t\t\t}", "@Override\n\t\t\tpublic void actionPerformed(ActionEvent cb_e) {\n\t\t\t\tinx1 = cb[1].getSelectedIndex();\n\t\t\t}", "private void setActionListener(){\r\n \tthis.addPropertyChangeListener(\"Refresh\", this);\r\n \tdeleteButton.addActionListener(this);\r\n \taddNewButton.addActionListener(this);\r\n }", "public void actionPerformed(ActionEvent e)\n\t\t{\n\t\t\tnextButton.setText(\"NEXT >> \");\n\t\t\tint index = tabbedPane.getSelectedIndex();\n\t\t\tif (index != 0)\n\t\t\t{\n\t\t\t\ttabbedPane.setSelectedIndex(index - 1);\n\t\t\t}\n\t\t\tif (index - 1 == 0)\n\t\t\t{\n\t\t\t\tbackButton.setEnabled(false);\n\t\t\t}\n\t\t}", "@Override\n\t\t\tpublic void actionPerformed(ActionEvent cb_e) {\n\t\t\t\tinx2 = cb[2].getSelectedIndex();\n\t\t\t}", "@Override\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\taddBtn.setEnabled(true);\n\t\t\t}", "public void addButtonListener(ActionListener l)\r\n\t{\r\n\t\tbnt_pane.addButtonListener(l);\r\n\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}", "private void jTextField10ActionPerformed(java.awt.event.ActionEvent evt) {\n }", "private void rowCountTextFldActionPerformed(java.awt.event.ActionEvent evt) {\n }", "private void numeroLActionPerformed(java.awt.event.ActionEvent evt) {\n }", "public void addActionEvent()\n {\n\t depositButton.addActionListener(this);\n \n }", "void addButton_actionPerformed(ActionEvent e) {\n addButton();\n }", "@Override\r\n\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\tint val = Integer.parseInt(jt.getText());\r\n\t\t\tval++;\r\n\t\t\tjt.setText(val+\"\");\r\n\t\t\t\r\n\t\t}", "public void addActionListener(ActionListener listener){\n\t\n\t\tfor(int i = 0; i< 5; i++){\n\t\t\tfor(int j = 0; j < 5; j++){\n\t\t\t\tbuttons[i][j].addActionListener(listener);\n\t\t\t}\n\t\t}\n\t}", "public void addNextActionListener(ActionListener actionListener){\n\t\tbtnNext.addActionListener(actionListener);\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 }", "@Override\r\n\t\t\tpublic void handle(ActionEvent event) {\n\r\n\t\t\t\tvalue[11]++;\r\n\t\t\t\tvalue[11] %= 3;\r\n\t\t\t\tif (value[11] == 0) {\r\n\t\t\t\t\tbtn[11].setText(\"0\");\r\n\t\t\t\t}\r\n\t\t\t\tif (value[11] == 1) {\r\n\t\t\t\t\tbtn[11].setText(\"1\");\r\n\t\t\t\t}\r\n\t\t\t\tif (value[11] == 2) {\r\n\t\t\t\t\tbtn[11].setText(\"X\");\r\n\t\t\t\t}\r\n\t\t\t}", "public void qBrowseBtnAddListener(ActionListener listener)\r\n\t{\r\n\t\tqbrowseBtn.addActionListener(listener);\r\n\t}", "public void Number_Button(int i){\n\t}", "public void addListener(ActionListener listener){\n\t\tbtn.addActionListener(listener);\n\t}", "private void jTextFieldIDActionPerformed(java.awt.event.ActionEvent evt) {\n }", "public void addBtnDodajListener(ActionListener ae) {\n btnDodaj.addActionListener(ae);\n }", "@Override\r\n\t\t\tpublic void handle(ActionEvent event) {\n\r\n\t\t\t\tvalue[9]++;\r\n\t\t\t\tvalue[9] %= 3;\r\n\t\t\t\tif (value[9] == 0) {\r\n\t\t\t\t\tbtn[9].setText(\"0\");\r\n\t\t\t\t}\r\n\t\t\t\tif (value[9] == 1) {\r\n\t\t\t\t\tbtn[9].setText(\"1\");\r\n\t\t\t\t}\r\n\t\t\t\tif (value[9] == 2) {\r\n\t\t\t\t\tbtn[9].setText(\"X\");\r\n\t\t\t\t}\r\n\t\t\t}", "protected void do_btnIncrement_actionPerformed(ActionEvent e, MyCounter paramMyCounter) {\n\t\tprintln(\"Button Clicked\");\n\t\tparamMyCounter.increment();\n\n\t}", "private void updateButton(JButton button) {\n\t\tbutton.setFocusPainted(comboBox.isEditable());\n\t}", "private void jtxtIDActionPerformed(java.awt.event.ActionEvent evt) {\n \n }", "@Override\r\n\tpublic void actionPerformed(ActionEvent e) {\n adaptee.btnIDSearch_actionPerformed(e);\r\n\t}", "private void jTextField11ActionPerformed(java.awt.event.ActionEvent evt) {\n }", "private void jTextField11ActionPerformed(java.awt.event.ActionEvent evt) {\n }", "@SuppressWarnings(\"unchecked\")\n // <editor-fold defaultstate=\"collapsed\" desc=\"Generated Code\">//GEN-BEGIN:initComponents\n private void initComponents() {\n\n jPanel1 = new javax.swing.JPanel();\n num1 = new javax.swing.JButton();\n num2 = new javax.swing.JButton();\n num3 = new javax.swing.JButton();\n num4 = new javax.swing.JButton();\n num5 = new javax.swing.JButton();\n num6 = new javax.swing.JButton();\n num7 = new javax.swing.JButton();\n txtQ = new javax.swing.JTextField();\n add = new javax.swing.JButton();\n num8 = new javax.swing.JButton();\n num9 = new javax.swing.JButton();\n num0 = new javax.swing.JButton();\n exit = new javax.swing.JButton();\n clear = new javax.swing.JButton();\n\n setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);\n\n num1.setText(\"1\");\n num1.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n num1ActionPerformed(evt);\n }\n });\n\n num2.setText(\"2\");\n num2.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n num2ActionPerformed(evt);\n }\n });\n\n num3.setText(\"3\");\n num3.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n num3ActionPerformed(evt);\n }\n });\n\n num4.setText(\"4\");\n num4.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n num4ActionPerformed(evt);\n }\n });\n\n num5.setText(\"5\");\n num5.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n num5ActionPerformed(evt);\n }\n });\n\n num6.setText(\"6\");\n num6.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n num6ActionPerformed(evt);\n }\n });\n\n num7.setText(\"7\");\n num7.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n num7ActionPerformed(evt);\n }\n });\n\n txtQ.setText(\"0\");\n\n add.setText(\"Add\");\n add.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n addActionPerformed(evt);\n }\n });\n\n num8.setText(\"8\");\n num8.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n num8ActionPerformed(evt);\n }\n });\n\n num9.setText(\"9\");\n num9.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n num9ActionPerformed(evt);\n }\n });\n\n num0.setText(\"0\");\n num0.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n num0ActionPerformed(evt);\n }\n });\n\n exit.setText(\"Exit\");\n exit.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n exitActionPerformed(evt);\n }\n });\n\n clear.setText(\"Clear\");\n clear.setToolTipText(\"\");\n clear.addActionListener(new java.awt.event.ActionListener() {\n public void actionPerformed(java.awt.event.ActionEvent evt) {\n clearActionPerformed(evt);\n }\n });\n\n javax.swing.GroupLayout jPanel1Layout = new javax.swing.GroupLayout(jPanel1);\n jPanel1.setLayout(jPanel1Layout);\n jPanel1Layout.setHorizontalGroup(\n jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel1Layout.createSequentialGroup()\n .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanel1Layout.createSequentialGroup()\n .addGap(0, 0, Short.MAX_VALUE)\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING, false)\n .addGroup(jPanel1Layout.createSequentialGroup()\n .addComponent(num0)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addComponent(add, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))\n .addGroup(jPanel1Layout.createSequentialGroup()\n .addComponent(num7)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addComponent(num8)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addComponent(num9)))\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING, false)\n .addComponent(txtQ, javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel1Layout.createSequentialGroup()\n .addComponent(num4)\n .addGap(6, 6, 6)\n .addComponent(num5)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addComponent(num6))\n .addGroup(jPanel1Layout.createSequentialGroup()\n .addComponent(num1)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addComponent(num2)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addComponent(num3))))))\n .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanel1Layout.createSequentialGroup()\n .addComponent(clear)\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)\n .addComponent(exit)))\n .addContainerGap())\n );\n jPanel1Layout.setVerticalGroup(\n jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(jPanel1Layout.createSequentialGroup()\n .addContainerGap()\n .addComponent(txtQ, javax.swing.GroupLayout.PREFERRED_SIZE, 40, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addGap(18, 18, 18)\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(num2)\n .addComponent(num3)\n .addComponent(num1))\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(num6)\n .addComponent(num5)\n .addComponent(num4))\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(num7)\n .addComponent(num8)\n .addComponent(num9))\n .addGap(9, 9, 9)\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(num0)\n .addComponent(add))\n .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)\n .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)\n .addComponent(exit)\n .addComponent(clear))\n .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))\n );\n\n javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());\n getContentPane().setLayout(layout);\n layout.setHorizontalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addComponent(jPanel1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n );\n layout.setVerticalGroup(\n layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)\n .addGroup(layout.createSequentialGroup()\n .addComponent(jPanel1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)\n .addGap(0, 27, Short.MAX_VALUE))\n );\n\n pack();\n }", "public void actionPerformed(ActionEvent e) {\n\t\t\t\tImage img = new ImageIcon(this.getClass().getResource(\"/qbpSelected.png\")).getImage();\n\t\t\t\tbtnQuadbp.setIcon(new ImageIcon(img));\n\t\t\t\tuiInterceptor.addItem(4);\n\t\t\t\tbtnDoublebp.setEnabled(false);\n\t\t\t\tbtnTriplebp.setEnabled(false);\n\t\t\t\tbtnBypass.setEnabled(false);\n\t\t\t}", "public void addActionListener(ActionListener al)\n {\n _tf.addActionListener(al);\n }", "private void jButton16ActionPerformed(java.awt.event.ActionEvent evt) {\n }", "private void addBtn1ActionPerformed(java.awt.event.ActionEvent evt) {\n addBtnActionPerformed();\n }", "private void setPlus(JButton btn, JLabel lbl) {\n \tbtn.addActionListener(new ActionListener() {\n\t\t\t@Override\n\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\tif (blingCount >= 3) return;\n\t\t\t\tint num = Integer.parseInt(lbl.getText()) + 1;\n\t\t\t\tlbl.setText(String.valueOf(num));\n\t\t\t\tblingCount++;\n\t\t\t}\n \t});\n }", "@Override\r\n\t\t\tpublic void handle(ActionEvent event) {\n\r\n\t\t\t\tvalue[4]++;\r\n\t\t\t\tvalue[4] %= 3;\r\n\t\t\t\tif (value[4] == 0) {\r\n\t\t\t\t\tbtn[4].setText(\"0\");\r\n\t\t\t\t}\r\n\t\t\t\tif (value[4] == 1) {\r\n\t\t\t\t\tbtn[4].setText(\"1\");\r\n\t\t\t\t}\r\n\t\t\t\tif (value[4] == 2) {\r\n\t\t\t\t\tbtn[4].setText(\"X\");\r\n\t\t\t\t}\r\n\t\t\t}", "@Override\r\n\t\t\tpublic void handle(ActionEvent event) {\n\r\n\t\t\t\tvalue[15]++;\r\n\t\t\t\tvalue[15] %= 3;\r\n\t\t\t\tif (value[15] == 0) {\r\n\t\t\t\t\tbtn[15].setText(\"0\");\r\n\t\t\t\t}\r\n\t\t\t\tif (value[15] == 1) {\r\n\t\t\t\t\tbtn[15].setText(\"1\");\r\n\t\t\t\t}\r\n\t\t\t\tif (value[15] == 2) {\r\n\t\t\t\t\tbtn[15].setText(\"X\");\r\n\t\t\t\t}\r\n\t\t\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 }", "@Override\r\n\t\t\tpublic void handle(ActionEvent event) {\n\r\n\t\t\t\tvalue[1]++;\r\n\t\t\t\tvalue[1] %= 3;\r\n\t\t\t\tif (value[1] == 0) {\r\n\t\t\t\t\tbtn[1].setText(\"0\");\r\n\t\t\t\t}\r\n\t\t\t\tif (value[1] == 1) {\r\n\t\t\t\t\tbtn[1].setText(\"1\");\r\n\t\t\t\t}\r\n\t\t\t\tif (value[1] == 2) {\r\n\t\t\t\t\tbtn[1].setText(\"X\");\r\n\t\t\t\t}\r\n\t\t\t}", "void addMultiplyListener(ActionListener f){\n\t\tm_multiplyBtn.addActionListener(f);\n\t}", "@Override\n\tpublic void pressed(PushButton button) {\n\t\tvm.getConfigurationPanel().getButton(index);\n\t\t\n\t}", "public void actionPerformed (ActionEvent e)\n \t\t{\n \t\t\tjP.add(textField);\n \t\t\tjP.add(label);\n \t\t\t\n \t\t\t// Set position of TExt Field\n \t \ttextField.setBounds(350, 463, 125, 25);\n \t \t\n \t \tlabel.setBounds(15, 450, 500, 50);\n \t \tlabel.setFont(arial);\n \t\t\t\n \t \t// Remove the 2 Buttons\n \t\t\tjP.remove(call);\n \t\t\tjP.remove(raise);\n \t\t\t\n \t\t\t// Add a 2nd raise Button\n \t\t\tjP.add(raise2);\n \t\t\traise2.setBounds(500, 460, 80, 30);\n \t\t\t\n \t\t\t// Repaint and update the J Panel\n \t\t\tjP.repaint();\n \t\t}", "@Override\r\n\t\t\tpublic void handle(ActionEvent event) {\n\r\n\t\t\t\tvalue[10]++;\r\n\t\t\t\tvalue[10] %= 3;\r\n\t\t\t\tif (value[10] == 0) {\r\n\t\t\t\t\tbtn[10].setText(\"0\");\r\n\t\t\t\t}\r\n\t\t\t\tif (value[10] == 1) {\r\n\t\t\t\t\tbtn[10].setText(\"1\");\r\n\t\t\t\t}\r\n\t\t\t\tif (value[10] == 2) {\r\n\t\t\t\t\tbtn[10].setText(\"X\");\r\n\t\t\t\t}\r\n\t\t\t}", "protected void updateButtons() {\n int currentIndex = tabbedPane.getSelectedIndex();\n if( currentIndex == 0) {\n backButton.setEnabled(false);\n forwardButton.setText(\"weiter\");\n }\n if(currentIndex > 0) {\n backButton.setEnabled(true);\n forwardButton.setText(\"weiter\");\n }\n \n if(currentIndex == 6) {\n forwardButton.setText(\"würfeln\");\n }\n \n }", "private void jNumHabitacionActionPerformed(java.awt.event.ActionEvent evt) {\n }", "public void actionPerformed(ActionEvent e)\n {\n int pos = findFieldButtonPosition();\n formatEditor.setCaretPosition(pos);\n }", "public void addSetColorListener(ActionListener action) {\n greenButton.addActionListener(action);\n redButton.addActionListener(action);\n yellowButton.addActionListener(action);\n blueButton.addActionListener(action);\n }", "@Override\r\n\t\t\tpublic void handle(ActionEvent event) {\n\r\n\t\t\t\tvalue[12]++;\r\n\t\t\t\tvalue[12] %= 3;\r\n\t\t\t\tif (value[12] == 0) {\r\n\t\t\t\t\tbtn[12].setText(\"0\");\r\n\t\t\t\t}\r\n\t\t\t\tif (value[12] == 1) {\r\n\t\t\t\t\tbtn[12].setText(\"1\");\r\n\t\t\t\t}\r\n\t\t\t\tif (value[12] == 2) {\r\n\t\t\t\t\tbtn[12].setText(\"X\");\r\n\t\t\t\t}\r\n\t\t\t}", "private void CounterJTextFieldActionPerformed(java.awt.event.ActionEvent evt) {\n }", "public void actionPerformed(java.awt.event.ActionEvent e) {\n\t\t\t\t\tisButtonClick = true;\r\n\t\t\t\t\tpageSize = 0;\r\n\t\t\t\t\tcurrentPage = 1;\r\n\t\t\t\t\tgetQx();\r\n\t\t\t\t}", "private void addNumberListeners()\n\t{\n\t\tnine.addActionListener (new numberListener());\n\t\teight.addActionListener (new numberListener());\n\t\tseven.addActionListener (new numberListener());\n\t\tsix.addActionListener (new numberListener());\n\t\tfive.addActionListener (new numberListener());\n\t\tfour.addActionListener (new numberListener());\n\t\tthree.addActionListener (new numberListener());\n\t\ttwo.addActionListener (new numberListener());\n\t\tone.addActionListener (new numberListener());\n\t\tzero.addActionListener (new numberListener());\n\t\t\n\t}", "private void createJButtonActionPerformed( ActionEvent event )\r\n {\r\n \r\n }", "@Override\n\tpublic void actionPerformed(ActionEvent e)\n\t {\n\t\tint btnId = Integer.parseInt(e.getActionCommand());\n\n\t\tJButton bttn = btn[btnId];\n\n\t\tif (bttn.getIcon().equals(icons[6]))\n\t\t{\n\t\t bttn.setIcon(icons[pairs[btnId]]);\n\t\t} else\n\t\t{\n\t\t bttn.setIcon(icons[6]);\n\t\t}\n\t }", "public void actionPerformed (ActionEvent e) {\n \t\t\tfor(int i=0; i<10; i++) {//add the buttons to the frame\n \t \tfor (int j=0; j<10; j++) {\n \t \t\ttile[i][j].addActionListener(new tileClicked());\n \t \t}\n \t }\n \t\t\tSystem.out.println(\"Move Mode Selected\");\n \t\t}", "void addActionListener(ActionListener listener);", "public void actionPerformed (ActionEvent e) {\n\t \t\t\tfor(int i=0; i<10; i++) {//add the buttons to the frame\n\t \t \tfor (int j=0; j<10; j++) {\n\t \t \t\ttile[i][j].addActionListener(new tileClicked());\n\t \t \t}\n\t \t }\n\t \t\t\tSystem.out.println(\"Move Mode Selected\");\n\t \t\t}", "@Override\n\tpublic void actionPerformed(ActionEvent e) {\n\t\tJButton clicked=(JButton)e.getSource();\n\t\tif(clicked == mostrarinfo)\n\t\t{\n\t\t\t//textPanel.appendText(\"Good Bye\\n\");\n\t\t\tif(arrayListener!=null)\n\t\t\t{\n\t\t\t\tarrayListener.arrayEminetted(this.myList);\n\t\t\t}\n\t\t\t\n\t\t}\n\t\t\n\t}", "void enablButtonListener();", "private void addButtonListener() {\n\t\trock.addActionListener(buttonListener);\n\t\tpaper.addActionListener(buttonListener);\n\t\tscissors.addActionListener(buttonListener);\n\t}", "@Override\r\n\t\t\tpublic void handle(ActionEvent event) {\n\r\n\t\t\t\tvalue[6]++;\r\n\t\t\t\tvalue[6] %= 3;\r\n\t\t\t\tif (value[6] == 0) {\r\n\t\t\t\t\tbtn[6].setText(\"0\");\r\n\t\t\t\t}\r\n\t\t\t\tif (value[6] == 1) {\r\n\t\t\t\t\tbtn[6].setText(\"1\");\r\n\t\t\t\t}\r\n\t\t\t\tif (value[6] == 2) {\r\n\t\t\t\t\tbtn[6].setText(\"X\");\r\n\t\t\t\t}\r\n\t\t\t}", "private void jTextField5ActionPerformed(java.awt.event.ActionEvent evt) {\n }", "private void jTextField5ActionPerformed(java.awt.event.ActionEvent evt) {\n }", "private void jTextField5ActionPerformed(java.awt.event.ActionEvent evt) {\n }", "public void qImageBtnAddListener(ActionListener listener)\r\n\t{\r\n\t\tqImage.addActionListener(listener);\r\n\t}", "@Override\r\n\t\t\tpublic void handle(ActionEvent event) {\n\r\n\t\t\t\tvalue[14]++;\r\n\t\t\t\tvalue[14] %= 3;\r\n\t\t\t\tif (value[14] == 0) {\r\n\t\t\t\t\tbtn[14].setText(\"0\");\r\n\t\t\t\t}\r\n\t\t\t\tif (value[14] == 1) {\r\n\t\t\t\t\tbtn[14].setText(\"1\");\r\n\t\t\t\t}\r\n\t\t\t\tif (value[14] == 2) {\r\n\t\t\t\t\tbtn[14].setText(\"X\");\r\n\t\t\t\t}\r\n\t\t\t}", "@Override\r\n\t\t\tpublic void handle(ActionEvent event) {\n\r\n\t\t\t\tvalue[7]++;\r\n\t\t\t\tvalue[7] %= 3;\r\n\t\t\t\tif (value[7] == 0) {\r\n\t\t\t\t\tbtn[7].setText(\"0\");\r\n\t\t\t\t}\r\n\t\t\t\tif (value[7] == 1) {\r\n\t\t\t\t\tbtn[7].setText(\"1\");\r\n\t\t\t\t}\r\n\t\t\t\tif (value[7] == 2) {\r\n\t\t\t\t\tbtn[7].setText(\"X\");\r\n\t\t\t\t}\r\n\t\t\t}", "public void actionPerformed(ActionEvent arg0) \n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tborderSelected(dayNumber -1);\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t//show the event items in the box on the right\n\t\t\t\t\t\t\twriteEvents(dayNumber);\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tchangeDateLabel(dayNumber);\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t//make these buttons available for use\n\t\t\t\t\t\t\tnextDay.setEnabled(true);\n\t\t\t\t\t\t\tprevDay.setEnabled(true);\n\t\t\t\t\t\t\tcreateButton.setEnabled(true);\n\t\t\t\t\t\t}", "@Override\r\n\t\t\tpublic void handle(ActionEvent event) {\n\r\n\t\t\t\tvalue[5]++;\r\n\t\t\t\tvalue[5] %= 3;\r\n\t\t\t\tif (value[5] == 0) {\r\n\t\t\t\t\tbtn[5].setText(\"0\");\r\n\t\t\t\t}\r\n\t\t\t\tif (value[5] == 1) {\r\n\t\t\t\t\tbtn[5].setText(\"1\");\r\n\t\t\t\t}\r\n\t\t\t\tif (value[5] == 2) {\r\n\t\t\t\t\tbtn[5].setText(\"X\");\r\n\t\t\t\t}\r\n\t\t\t}", "public void ansBrowseBtnAddListener(ActionListener listener)\r\n\t{\r\n\t\tansBrowseBtn.addActionListener(listener);\r\n\t}", "@Override\r\n\t\t\tpublic void handle(ActionEvent event) {\n\r\n\t\t\t\tvalue[3]++;\r\n\t\t\t\tvalue[3] %= 3;\r\n\t\t\t\tif (value[3] == 0) {\r\n\t\t\t\t\tbtn[3].setText(\"0\");\r\n\t\t\t\t}\r\n\t\t\t\tif (value[3] == 1) {\r\n\t\t\t\t\tbtn[3].setText(\"1\");\r\n\t\t\t\t}\r\n\t\t\t\tif (value[3] == 2) {\r\n\t\t\t\t\tbtn[3].setText(\"X\");\r\n\t\t\t\t}\r\n\t\t\t}", "private void booksNumberActionPerformed(java.awt.event.ActionEvent evt) {\n }", "@Override\r\n\t\t\tpublic void handle(ActionEvent event) {\n\r\n\t\t\t\tvalue[8]++;\r\n\t\t\t\tvalue[8] %= 3;\r\n\t\t\t\tif (value[8] == 0) {\r\n\t\t\t\t\tbtn[8].setText(\"0\");\r\n\t\t\t\t}\r\n\t\t\t\tif (value[8] == 1) {\r\n\t\t\t\t\tbtn[8].setText(\"1\");\r\n\t\t\t\t}\r\n\t\t\t\tif (value[8] == 2) {\r\n\t\t\t\t\tbtn[8].setText(\"X\");\r\n\t\t\t\t}\r\n\t\t\t}", "private void setRegisterButtonListener(ActionListener actionListener) {\n System.out.println(\"ShareView: adding register listener\");\n buttonRegister.addActionListener(actionListener);\n buttonRegister.setActionCommand(GlobalControlCodes.TRACK_OPEN.name());\n }", "public abstract void initButton(int buttonIndex);", "@Override\r\n\t\t\tpublic void handle(ActionEvent event) {\n\r\n\t\t\t\tvalue[2]++;\r\n\t\t\t\tvalue[2] %= 3;\r\n\t\t\t\tif (value[2] == 0) {\r\n\t\t\t\t\tbtn[2].setText(\"0\");\r\n\t\t\t\t}\r\n\t\t\t\tif (value[2] == 1) {\r\n\t\t\t\t\tbtn[2].setText(\"1\");\r\n\t\t\t\t}\r\n\t\t\t\tif (value[2] == 2) {\r\n\t\t\t\t\tbtn[2].setText(\"X\");\r\n\t\t\t\t}\r\n\t\t\t}", "public void actionPerformed(ActionEvent e) {\n\t\t\t\tImage img = new ImageIcon(this.getClass().getResource(\"/tbpSelected.png\")).getImage();\n\t\t\t\tbtnTriplebp.setIcon(new ImageIcon(img));\n\t\t\t\tuiInterceptor.addItem(3);\n\t\t\t\tbtnDoublebp.setEnabled(false);\n\t\t\t\tbtnBypass.setEnabled(false);\n\t\t\t\tbtnQuadbp.setEnabled(false);\n\t\t\t}", "private void numeroDaFarmaciaEntradaActionPerformed(java.awt.event.ActionEvent evt) {\n }", "private void jTextField19ActionPerformed(java.awt.event.ActionEvent evt) {\n }", "private void nuevoBotonNumerico(String digito) {\r\n\t\tJButton btn = new JButton();\r\n\t\tbtn.setText(digito);\r\n\t\tbtn.addMouseListener(new MouseAdapter() {\r\n\r\n\t\t\t@Override\r\n\t\t\tpublic void mouseReleased(MouseEvent evt) {\r\n\t\t\t\tJButton btn = (JButton) evt.getSource();\r\n\t\t\t\tnumeroPulsado(btn.getText());\r\n\t\t\t}\r\n\t\t});\r\n\r\n\t\tpanelNumeros.add(btn);\r\n\t}", "@Override\r\n\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\tint row = Integer.valueOf(e.getActionCommand());\r\n\t\t\t//LibriTableModel model = (LibriTableModel) table.getModel();\r\n\t\t\tModelMethods.aggiungiCarrello(row);\r\n\t\t\tVenditeView.aggiornaLabels();\r\n\t\t\tLibriJPanJTab.refresh();\r\n\t\t}", "private void jButton9ActionPerformed(java.awt.event.ActionEvent evt) {\n }", "void configureButtonListener();", "private void jTextField12ActionPerformed(java.awt.event.ActionEvent evt) {\n }", "private void jTextField12ActionPerformed(java.awt.event.ActionEvent evt) {\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\t\tpublic void actionPerformed(ActionEvent arg0) {\n\t\t\tString name = ((JButton)arg0.getSource()).getText();\n\t\t\ttextField.setText(name);\n\t\t}", "@Override\r\n\tpublic void actionPerformed(ActionEvent e) {\n adaptee.btnBill_actionPerformed(e);\r\n\t}", "private void jTextField4ActionPerformed(java.awt.event.ActionEvent evt) {\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 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 actionPerformed(ActionEvent e) {\n\t\tadaptee.botonEditar_actionPerformed(e);\n\t}", "@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}" ]
[ "0.667007", "0.6490194", "0.643425", "0.639029", "0.63652277", "0.6284824", "0.6280576", "0.62681854", "0.62074125", "0.6194111", "0.61776173", "0.61194557", "0.6065017", "0.60619605", "0.60570544", "0.6017279", "0.6005057", "0.5996277", "0.5977653", "0.5959391", "0.5937187", "0.5902732", "0.5889708", "0.5886802", "0.58649343", "0.5851949", "0.58416927", "0.58374786", "0.5829445", "0.5819874", "0.58192086", "0.58077985", "0.57961947", "0.5785868", "0.5780116", "0.57751274", "0.57751274", "0.5772865", "0.5769623", "0.5767962", "0.57567835", "0.57451904", "0.57264787", "0.572267", "0.5718716", "0.57178587", "0.571728", "0.5709659", "0.5709455", "0.57071596", "0.5699893", "0.5691806", "0.5691078", "0.5690401", "0.5688275", "0.5680309", "0.56802285", "0.56748086", "0.5671581", "0.567123", "0.5669294", "0.5664844", "0.5664786", "0.56638235", "0.5662268", "0.5659657", "0.5656402", "0.5654146", "0.56524885", "0.56524885", "0.56524885", "0.564806", "0.56458753", "0.5644776", "0.56361103", "0.56349355", "0.5632624", "0.56261003", "0.5625906", "0.5625682", "0.56213903", "0.56210196", "0.5620705", "0.5618005", "0.5604483", "0.55997556", "0.5595034", "0.55905527", "0.5585189", "0.55811256", "0.5577266", "0.5577266", "0.5573638", "0.5570077", "0.5559733", "0.5554369", "0.5553255", "0.55530167", "0.55467194", "0.55451745" ]
0.70125985
0
checks for all y controlPoint fields if they are in the interval 0..1 checks for all x controlPoint fields if they are in the interval 0..1 and if they form a increasing row. First controlPoints x has to be <= 2nds... If necessary tries to auto correct errors in the ordering.
private void testAndUpdateControlFields(int startFieldNr) { boolean consistent = true; //test and correct y for (int i = 0; i < _controlPoints.length; i++) { if (parseTextFieldValue(_controlPoints[i][1]) == -1.0f) { consistent = false; } } //test and correct x at startFieldNr and above for (int i = startFieldNr; i >= 0; i--) { float value1 = parseTextFieldValue(_controlPoints[i][0]); if (value1 == -1.0f) { //check field value consistent = false; } else { //field value ok check if it is greater than the field above if (i > 0) { float value2 = parseTextFieldValue(_controlPoints[i-1][0]); if (value2 > value1) { //value 2 has to be <= value1 change it _controlPoints[i-1][0].setText(String.valueOf(value1)); } } } } //test and correct x at startFieldNr and below for (int i = startFieldNr; i < _controlPoints.length; i++) { float value1 = parseTextFieldValue(_controlPoints[i][0]); if (value1 == -1.0f) { //check field value consistent = false; } else { //field value ok check if it is smaller than the field below if (i < (_controlPoints.length-1)) { float value2 = parseTextFieldValue(_controlPoints[i+1][0]); if (value2 < value1) { //value 2 has to be >= value1 change it _controlPoints[i+1][0].setText(String.valueOf(value1)); } } } } _isConsistent = consistent; _changeListener.pointsChanged(consistent); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n protected void doAlgorithmA1() {\n int xP = 0;\n int yP = 0;\n\n\n //Taking the variable out of the list that are in the bounds\n //Testing that the bound has variables\n if (csp.getSimpleConstraints().get(cIndex).getSimpleBounds().get(bIndex).getX() != null) {\n xP = csp.getSimpleConstraints().get(cIndex).getSimpleBounds().get(bIndex).getX().getPosition();\n }\n int xU = 0;\n int xL = 0;\n if (csp.getSimpleConstraints().get(cIndex).getSimpleBounds().get(bIndex).getY() != null) {\n yP = csp.getSimpleConstraints().get(cIndex).getSimpleBounds().get(bIndex).getY().getPosition();\n }\n int yU = 0;\n int yL = 0;\n int cright = csp.getSimpleConstraints().get(cIndex).getSimpleBounds().get(bIndex).getCright();\n int cleft = csp.getSimpleConstraints().get(cIndex).getSimpleBounds().get(bIndex).getCleft();\n\n\n\n for (Variable variable : csp.getVars()) {\n if (csp.getSimpleConstraints().get(cIndex).getSimpleBounds().get(bIndex).getX() != null) {\n if (variable.getPosition() == xP) {\n xU = variable.getUpperDomainBound();\n xL = variable.getLowerDomainBound();\n }\n }\n if (csp.getSimpleConstraints().get(cIndex).getSimpleBounds().get(bIndex).getY() != null) {\n if (variable.getPosition() == yP) {\n yU = variable.getUpperDomainBound();\n yL = variable.getLowerDomainBound();\n }\n }\n }\n\n boolean first = false;\n boolean second = false;\n\n //Testing if the bound is true, false or inconclusive\n\n if (xL + cleft >= yU + cright) {\n first = true;\n }\n if (xU + cleft < yL + cright) {\n second = true;\n }\n\n //are first and second not equal is the bound not inconclusive\n if (first != second) {\n if (first) { //a true Simple Bound was found\n //checks if it was the last constraint in a csp\n //If so the csp is true\n //else check the next constraint and do this method again\n if (csp.getSimpleConstraints().size() - 1 == cIndex) {\n System.out.println(\"P is satisfiable\");\n System.out.println(System.nanoTime()-startTime);\n return;\n } else {\n bIndex = 0;\n cIndex++;\n unit=false;\n doAlgorithmA1();\n }\n } else if (csp.getSimpleConstraints().get(cIndex).getSimpleBounds().size() - 1 == bIndex) { //a false Simple Bound was found\n //\n bIndex = 0;\n cIndex = 0;\n if (isInconclusive) {\n if(unit){\n doDeduction();\n }else {\n doAlgorithmA3();\n }\n } else {\n doAlgorithmA2();\n }\n } else {\n bIndex++;\n doAlgorithmA1();\n }\n } else {//an inconclusive Simple Bound was found\n //checks if the bound wasn't already inconclusive\n if(!isInconclusive){\n unit=true;\n unitSB = csp.getSimpleConstraints().get(cIndex).getSimpleBounds().get(bIndex);\n }else {\n unit=false;\n }\n isInconclusive = true;\n\n if (csp.getSimpleConstraints().get(cIndex).getSimpleBounds().size() - 1 == bIndex) {\n cIndex = 0;\n bIndex = 0;\n if(unit){\n doDeduction();\n }else {\n doAlgorithmA3();\n }\n } else {\n bIndex++;\n doAlgorithmA1();\n }\n }\n }", "protected void calcMinMax() {\n if (this.mDataSets != null) {\n T t;\n this.mYMax = -3.4028235E38f;\n this.mYMin = Float.MAX_VALUE;\n this.mXMax = -3.4028235E38f;\n this.mXMin = Float.MAX_VALUE;\n Iterator<T> iterator = this.mDataSets.iterator();\n while (iterator.hasNext()) {\n this.calcMinMax((IDataSet)iterator.next());\n }\n this.mLeftAxisMax = -3.4028235E38f;\n this.mLeftAxisMin = Float.MAX_VALUE;\n this.mRightAxisMax = -3.4028235E38f;\n this.mRightAxisMin = Float.MAX_VALUE;\n T t2 = this.getFirstLeft(this.mDataSets);\n if (t2 != null) {\n this.mLeftAxisMax = t2.getYMax();\n this.mLeftAxisMin = t2.getYMin();\n for (IDataSet iDataSet : this.mDataSets) {\n if (iDataSet.getAxisDependency() != YAxis.AxisDependency.LEFT) continue;\n if (iDataSet.getYMin() < this.mLeftAxisMin) {\n this.mLeftAxisMin = iDataSet.getYMin();\n }\n if (!(iDataSet.getYMax() > this.mLeftAxisMax)) continue;\n this.mLeftAxisMax = iDataSet.getYMax();\n }\n }\n if ((t = this.getFirstRight(this.mDataSets)) != null) {\n this.mRightAxisMax = t.getYMax();\n this.mRightAxisMin = t.getYMin();\n for (IDataSet iDataSet : this.mDataSets) {\n if (iDataSet.getAxisDependency() != YAxis.AxisDependency.RIGHT) continue;\n if (iDataSet.getYMin() < this.mRightAxisMin) {\n this.mRightAxisMin = iDataSet.getYMin();\n }\n if (!(iDataSet.getYMax() > this.mRightAxisMax)) continue;\n this.mRightAxisMax = iDataSet.getYMax();\n }\n }\n }\n }", "@Test\n public void test09() throws Throwable {\n SubCategoryAxis subCategoryAxis0 = new SubCategoryAxis(\"Null 'marker' not permitted.\");\n CombinedDomainCategoryPlot combinedDomainCategoryPlot0 = new CombinedDomainCategoryPlot((CategoryAxis) subCategoryAxis0);\n Layer layer0 = Layer.BACKGROUND;\n Collection collection0 = combinedDomainCategoryPlot0.getRangeMarkers(0, layer0);\n boolean boolean0 = combinedDomainCategoryPlot0.isRangeCrosshairLockedOnData();\n DefaultMultiValueCategoryDataset defaultMultiValueCategoryDataset0 = new DefaultMultiValueCategoryDataset();\n combinedDomainCategoryPlot0.setDataset((CategoryDataset) defaultMultiValueCategoryDataset0);\n ValueAxis[] valueAxisArray0 = new ValueAxis[8];\n LogarithmicAxis logarithmicAxis0 = new LogarithmicAxis(\"Null 'marker' not permitted.\");\n valueAxisArray0[0] = (ValueAxis) logarithmicAxis0;\n NumberAxis3D numberAxis3D0 = new NumberAxis3D(\"Null 'marker' not permitted.\");\n valueAxisArray0[1] = (ValueAxis) numberAxis3D0;\n LogarithmicAxis logarithmicAxis1 = new LogarithmicAxis(\"Null 'marker' not permitted.\");\n valueAxisArray0[2] = (ValueAxis) logarithmicAxis1;\n CyclicNumberAxis cyclicNumberAxis0 = new CyclicNumberAxis((double) 0);\n valueAxisArray0[3] = (ValueAxis) cyclicNumberAxis0;\n NumberAxis numberAxis0 = new NumberAxis();\n valueAxisArray0[4] = (ValueAxis) numberAxis0;\n ZoneInfo zoneInfo0 = (ZoneInfo)TimeZone.getDefault();\n Locale locale0 = JComponent.getDefaultLocale();\n TimeTableXYDataset timeTableXYDataset0 = new TimeTableXYDataset((TimeZone) zoneInfo0, locale0);\n Range range0 = timeTableXYDataset0.getDomainBounds(true);\n ModuloAxis moduloAxis0 = null;\n try {\n moduloAxis0 = new ModuloAxis(\"\", (Range) null);\n } catch(TooManyResourcesException e) {\n //\n // Loop has been executed more times than the allowed 10000\n //\n assertThrownBy(\"org.evosuite.runtime.LoopCounter\", e);\n }\n }", "public void checkDataOrder(Double[] times) {\n Double[] longitudes;\n Double[] latitudes;\n try {\n longitudes = getSampleLongitudes();\n latitudes = getSampleLatitudes();\n } catch ( Exception ex ) {\n // Messages about problems getting the longitudes or latitudes should already have been generated\n return;\n }\n TreeSet<DataLocation> orderedSet = new TreeSet<DataLocation>();\n for (int rowIdx = 0; rowIdx < numSamples; rowIdx++) {\n if ( times[rowIdx] != null ) {\n DataLocation dataLoc = new DataLocation();\n // Messages about missing longitude, latitude, or times should already have been generated\n if ( (times[rowIdx] == null) || (longitudes[rowIdx] == null) || (latitudes[rowIdx] == null) )\n continue;\n dataLoc.setDataDate(new Date(Math.round(times[rowIdx] * 1000.0)));\n dataLoc.setLongitude(longitudes[rowIdx]);\n dataLoc.setLatitude(latitudes[rowIdx]);\n dataLoc.setRowNumber(rowIdx + 1);\n if ( !orderedSet.add(dataLoc) )\n throw new RuntimeException(\"Unexpected duplicate data location with row number\");\n }\n }\n\n // TODO: needs a better method of figuring out which rows are actually misordered\n // the following works okay if there is only one block of misordered data\n // or if multiple blocks are consistent in the \"direction\" they are misordered.\n\n double[] maxSpeeds = DashboardConfigStore.getMaxCalcSpeedsKnots();\n double[] maxTimeGaps = DashboardConfigStore.getMaxTimeGapsDays();\n\n // The following will say:\n // 4,5,6 are misordered in 1,2,3,7,8,9,4,5,6,10,11,12;\n // 1,2 are misordered in 3,4,1,2,5,6\n // 3 is misordered in 1,2,4,5\n TreeSet<Integer> forwardErrs = new TreeSet<Integer>();\n ArrayList<ADCMessage> forwardSpeedMsgs = new ArrayList<ADCMessage>();\n ArrayList<ADCMessage> forwardTimeGapMsgs = new ArrayList<ADCMessage>();\n int lastRowNum = 0;\n int expectedRowNum = 1;\n for (DataLocation dataLoc : orderedSet) {\n int actualRowNum = dataLoc.getRowNumber();\n while ( expectedRowNum < actualRowNum ) {\n forwardErrs.add(expectedRowNum);\n expectedRowNum += 1;\n }\n if ( expectedRowNum == actualRowNum ) {\n if ( lastRowNum > 0 ) {\n double kmdelta = DashboardServerUtils.distanceBetween(longitudes[actualRowNum - 1],\n latitudes[actualRowNum - 1], longitudes[lastRowNum - 1], latitudes[lastRowNum - 1]);\n double hourdelta = (times[actualRowNum - 1] - times[lastRowNum - 1]) / 3600.0;\n double speed = 0.539957 * kmdelta / hourdelta;\n if ( (speed < 0.0) || (hourdelta < 0.0) ) {\n // Just to make sure the calculation was done correctly\n throw new RuntimeException(\"Negative calculated speed or time gap obtained\");\n }\n else if ( speed > maxSpeeds[1] ) {\n // Add one message at this time - later repeat with all the columns\n ADCMessage msg = new ADCMessage();\n msg.setSeverity(Severity.ERROR);\n msg.setRowNumber(actualRowNum);\n msg.setGeneralComment(String.format(\n \"calculated speed exceeds %g knots\", maxSpeeds[1]));\n msg.setDetailedComment(String.format(\n \"calculated speed of %g knots exceeds %g knots\", speed, maxSpeeds[1]));\n forwardSpeedMsgs.add(msg);\n }\n else if ( speed > maxSpeeds[0] ) {\n // Add one message at this time - later repeat with all the columns\n ADCMessage msg = new ADCMessage();\n msg.setSeverity(Severity.WARNING);\n msg.setRowNumber(actualRowNum);\n msg.setGeneralComment(String.format(\n \"calculated speed exceeds %g knots\", maxSpeeds[0]));\n msg.setDetailedComment(String.format(\n \"calculated speed of %g knots exceeds %g knots\", speed, maxSpeeds[0]));\n forwardSpeedMsgs.add(msg);\n }\n else if ( hourdelta > 24.0 * maxTimeGaps[1] ) {\n // Add one message at this time - later repeat with all the columns\n ADCMessage msg = new ADCMessage();\n msg.setSeverity(Severity.ERROR);\n msg.setRowNumber(actualRowNum);\n msg.setGeneralComment(String.format(\n \"time between consecutive measurements exceeds %g days\", maxTimeGaps[1]));\n msg.setDetailedComment(String.format(\n \"time between consecutive measurements %g days exceeds %g days\",\n hourdelta / 24.0, maxTimeGaps[1]));\n forwardTimeGapMsgs.add(msg);\n }\n else if ( hourdelta > 24.0 * maxTimeGaps[0] ) {\n // Add one message at this time - later repeat with all the columns\n ADCMessage msg = new ADCMessage();\n msg.setSeverity(Severity.WARNING);\n msg.setRowNumber(actualRowNum);\n msg.setGeneralComment(String.format(\n \"time between consecutive measurements exceeds %g days\", maxTimeGaps[0]));\n msg.setDetailedComment(String.format(\n \"time between consecutive measurements %g days exceeds %g days\",\n hourdelta / 24.0, maxTimeGaps[0]));\n forwardTimeGapMsgs.add(msg);\n }\n }\n lastRowNum = actualRowNum;\n expectedRowNum += 1;\n }\n }\n // The following will say:\n // 7,8,9 are misordered in 1,2,3,7,8,9,4,5,6,10,11,12;\n // 3,4 are misordered in 3,4,1,2,5,6\n // 3 is misordered in 1,2,4,5\n TreeSet<Integer> reverseErrs = new TreeSet<Integer>();\n ArrayList<ADCMessage> reverseSpeedMsgs = new ArrayList<ADCMessage>();\n ArrayList<ADCMessage> reverseTimeGapMsgs = new ArrayList<ADCMessage>();\n lastRowNum = 0;\n expectedRowNum = numSamples;\n for (DataLocation dataLoc : orderedSet.descendingSet()) {\n int actualRowNum = dataLoc.getRowNumber();\n while ( expectedRowNum > actualRowNum ) {\n reverseErrs.add(expectedRowNum);\n expectedRowNum -= 1;\n }\n if ( expectedRowNum == actualRowNum ) {\n if ( lastRowNum > 0 ) {\n double kmdelta = DashboardServerUtils.distanceBetween(longitudes[lastRowNum - 1],\n latitudes[lastRowNum - 1], longitudes[actualRowNum - 1], latitudes[actualRowNum - 1]);\n double hourdelta = (times[lastRowNum - 1] - times[actualRowNum - 1]) / 3600.0;\n double speed = 0.539957 * kmdelta / hourdelta;\n if ( (speed < 0.0) || (hourdelta < 0.0) ) {\n // Just to make sure the calculation was done correctly\n throw new RuntimeException(\"Negative calculated speed or time gap obtained\");\n }\n else if ( speed > maxSpeeds[1] ) {\n // Add one message at this time - later repeat with all the columns\n ADCMessage msg = new ADCMessage();\n msg.setSeverity(Severity.ERROR);\n msg.setRowNumber(actualRowNum);\n msg.setGeneralComment(String.format(\n \"calculated speed exceeds %g knots\", maxSpeeds[1]));\n msg.setDetailedComment(String.format(\n \"calculated speed of %g knots exceeds %g knots\", speed, maxSpeeds[1]));\n reverseSpeedMsgs.add(msg);\n }\n else if ( speed > maxSpeeds[0] ) {\n // Add one message at this time - later repeat with all the columns\n ADCMessage msg = new ADCMessage();\n msg.setSeverity(Severity.WARNING);\n msg.setRowNumber(actualRowNum);\n msg.setGeneralComment(String.format(\n \"calculated speed exceeds %g knots\", maxSpeeds[0]));\n msg.setDetailedComment(String.format(\n \"calculated speed of %g knots exceeds %g knots\", speed, maxSpeeds[0]));\n reverseSpeedMsgs.add(msg);\n }\n else if ( hourdelta > 24.0 * maxTimeGaps[1] ) {\n // Add one message at this time - later repeat with all the columns\n ADCMessage msg = new ADCMessage();\n msg.setSeverity(Severity.ERROR);\n msg.setRowNumber(actualRowNum);\n msg.setGeneralComment(String.format(\n \"time between consecutive measurements exceeds %g days\", maxTimeGaps[1]));\n msg.setDetailedComment(String.format(\n \"time between consecutive measurements %g days exceeds %g days\",\n hourdelta / 24.0, maxTimeGaps[1]));\n reverseTimeGapMsgs.add(msg);\n }\n else if ( hourdelta > 24.0 * maxTimeGaps[0] ) {\n // Add one message at this time - later repeat with all the columns\n ADCMessage msg = new ADCMessage();\n msg.setSeverity(Severity.WARNING);\n msg.setRowNumber(actualRowNum);\n msg.setGeneralComment(String.format(\n \"time between consecutive measurements exceeds %g days\", maxTimeGaps[0]));\n msg.setDetailedComment(String.format(\n \"time between consecutive measurements %g days exceeds %g days\",\n hourdelta / 24.0, maxTimeGaps[0]));\n reverseTimeGapMsgs.add(msg);\n }\n }\n lastRowNum = actualRowNum;\n expectedRowNum -= 1;\n }\n }\n // Guess that the set with fewer errors is the correct one\n TreeSet<Integer> errorRowsNums;\n ArrayList<ADCMessage> speedMsgs;\n ArrayList<ADCMessage> timeGapMsgs;\n if ( (forwardErrs.size() + forwardSpeedMsgs.size() + forwardTimeGapMsgs.size())\n <= (reverseErrs.size() + reverseSpeedMsgs.size() + reverseTimeGapMsgs.size()) ) {\n errorRowsNums = forwardErrs;\n speedMsgs = forwardSpeedMsgs;\n timeGapMsgs = forwardTimeGapMsgs;\n }\n else {\n errorRowsNums = reverseErrs;\n speedMsgs = reverseSpeedMsgs;\n timeGapMsgs = reverseTimeGapMsgs;\n }\n for (Integer rowNum : errorRowsNums) {\n for (Integer colIdx : indicesForTime) {\n ADCMessage msg = new ADCMessage();\n msg.setSeverity(Severity.CRITICAL);\n msg.setRowNumber(rowNum);\n msg.setColNumber(colIdx + 1);\n msg.setColName(userColNames[colIdx]);\n String comment = \"time-misordered data row\";\n msg.setGeneralComment(comment);\n msg.setDetailedComment(comment);\n stdMsgList.add(msg);\n }\n }\n for (ADCMessage spdmsg : speedMsgs) {\n // Speed problems could be in longitude ...\n ADCMessage msg = new ADCMessage();\n msg.setSeverity(spdmsg.getSeverity());\n msg.setRowNumber(spdmsg.getRowNumber());\n msg.setColNumber(longitudeIndex + 1);\n msg.setColName(userColNames[longitudeIndex]);\n msg.setGeneralComment(spdmsg.getGeneralComment());\n msg.setDetailedComment(spdmsg.getDetailedComment());\n stdMsgList.add(msg);\n // ... or latitude ...\n msg = new ADCMessage();\n msg.setSeverity(spdmsg.getSeverity());\n msg.setRowNumber(spdmsg.getRowNumber());\n msg.setColNumber(latitudeIndex + 1);\n msg.setColName(userColNames[latitudeIndex]);\n msg.setGeneralComment(spdmsg.getGeneralComment());\n msg.setDetailedComment(spdmsg.getDetailedComment());\n stdMsgList.add(msg);\n // ... or time\n for (Integer colIdx : indicesForTime) {\n msg = new ADCMessage();\n msg.setSeverity(spdmsg.getSeverity());\n msg.setRowNumber(spdmsg.getRowNumber());\n msg.setColNumber(colIdx + 1);\n msg.setColName(userColNames[colIdx]);\n msg.setGeneralComment(spdmsg.getGeneralComment());\n msg.setDetailedComment(spdmsg.getDetailedComment());\n stdMsgList.add(msg);\n }\n }\n for (ADCMessage tgmsg : timeGapMsgs) {\n for (Integer colIdx : indicesForTime) {\n ADCMessage msg = new ADCMessage();\n msg.setSeverity(tgmsg.getSeverity());\n msg.setRowNumber(tgmsg.getRowNumber());\n msg.setColNumber(colIdx + 1);\n msg.setColName(userColNames[colIdx]);\n msg.setGeneralComment(tgmsg.getGeneralComment());\n msg.setDetailedComment(tgmsg.getDetailedComment());\n stdMsgList.add(msg);\n }\n }\n }", "public void checkBounds() {\n\t\tfor (int k = 0; k < numDataCols; k++) {\n\t\t\tDashDataType<?> dtype = dataTypes[k];\n\n\t\t\tif ( dtype instanceof StringDashDataType ) {\n\t\t\t\tStringDashDataType strtype = (StringDashDataType) dtype;\n\t\t\t\tfor (int j = 0; j < numSamples; j++) {\n\t\t\t\t\tADCMessage msg = strtype.boundsCheckStandardValue(\n\t\t\t\t\t\t\t\t\t\t\t(String) stdObjects[j][k]);\n\t\t\t\t\tif ( msg != null ) {\n\t\t\t\t\t\tmsg.setRowNumber(j+1);\n\t\t\t\t\t\tmsg.setColNumber(k+1);\n\t\t\t\t\t\tmsg.setColName(userColNames[k]);\n\t\t\t\t\t\tstdMsgList.add(msg);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\telse if ( dtype instanceof CharDashDataType ) {\n\t\t\t\tCharDashDataType chartype = (CharDashDataType) dtype;\n\t\t\t\tfor (int j = 0; j < numSamples; j++) {\n\t\t\t\t\tADCMessage msg = chartype.boundsCheckStandardValue(\n\t\t\t\t\t\t\t\t\t\t\t(Character) stdObjects[j][k]);\n\t\t\t\t\tif ( msg != null ) {\n\t\t\t\t\t\tmsg.setRowNumber(j+1);\n\t\t\t\t\t\tmsg.setColNumber(k+1);\n\t\t\t\t\t\tmsg.setColName(userColNames[k]);\n\t\t\t\t\t\tstdMsgList.add(msg);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\telse if ( dtype instanceof IntDashDataType ) {\n\t\t\t\tIntDashDataType inttype = (IntDashDataType) dtype;\n\t\t\t\tfor (int j = 0; j < numSamples; j++) {\n\t\t\t\t\tADCMessage msg = inttype.boundsCheckStandardValue(\n\t\t\t\t\t\t\t\t\t\t\t(Integer) stdObjects[j][k]);\n\t\t\t\t\tif ( msg != null ) {\n\t\t\t\t\t\tmsg.setRowNumber(j+1);\n\t\t\t\t\t\tmsg.setColNumber(k+1);\n\t\t\t\t\t\tmsg.setColName(userColNames[k]);\n\t\t\t\t\t\tstdMsgList.add(msg);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\telse if ( dtype instanceof DoubleDashDataType ) {\n\t\t\t\tDoubleDashDataType dbltype = (DoubleDashDataType) dtype;\n\t\t\t\tfor (int j = 0; j < numSamples; j++) {\n\t\t\t\t\tADCMessage msg = dbltype.boundsCheckStandardValue(\n\t\t\t\t\t\t\t\t\t\t\t(Double) stdObjects[j][k]);\n\t\t\t\t\tif ( msg != null ) {\n\t\t\t\t\t\tmsg.setRowNumber(j+1);\n\t\t\t\t\t\tmsg.setColNumber(k+1);\n\t\t\t\t\t\tmsg.setColName(userColNames[k]);\n\t\t\t\t\t\tstdMsgList.add(msg);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\telse {\n\t\t\t\tthrow new IllegalArgumentException(\"unexpected data type encountered \" + \n\t\t\t\t\t\t\"in bounds checking: \" + dtype);\n\t\t\t}\n\t\t}\n\t}", "boolean checkValidPt(DoubleMatrix1D y){\n for(int dof=0; dof<numDOFs; dof++){\n if(y.get(dof)<DOFmin.get(dof) || y.get(dof)>DOFmax.get(dof))\n return false;\n }\n \n if(of.getValue(y)>thresh)\n return false;\n \n return true;\n }", "public static void main(String[] args) throws FileNotFoundException {\n FileReader fileReader = new FileReader(\"C:\\\\Users\\\\Stephanie\\\\Projects\\\\HackerRank\\\\src\\\\data\");\n\n Scanner sc = new Scanner(fileReader);\n DecimalFormat df = new DecimalFormat(\"##.00\");\n int n = sc.nextInt();\n\n\n sc.nextLine();\n int i, k = 0, j = 0;\n double arr[] = new double[n - 20];\n int arr_x[] = new int[n - 20];\n int miss_index[] = new int[20];\n for (i = 0; i < n; i++) {\n String temp[] = sc.nextLine().split(\"\\t\");\n\n if (temp[1].startsWith(\"Missing\")) {\n miss_index[j] = i;\n j++;\n } else {\n arr[k] = Double.parseDouble(temp[1]);\n arr_x[k] = i;\n k++;\n }\n\n }\n\n System.out.println(Arrays.toString(arr));\n System.out.println(Arrays.toString(arr_x));\n System.out.println(Arrays.toString(miss_index));\n\n double ansy, ansx, a, b, x0, x1, y0, y1;\n int temp, q1, q2, qq1, qq2;\n\n for (i = 0; i < 20; i++) {\n if (miss_index[i] < arr_x[0]) {\n System.out.println(i+\" miss_index[i]: \"+miss_index[i]+\" arr_x[0]: \"+arr_x[0]);\n x0 = arr_x[0];\n x1 = arr_x[1];\n y0 = arr[0];\n y1 = arr[1];\n\n } else if (miss_index[i] > arr_x[n - 21]) {\n x0 = arr_x[n - 21];\n x1 = arr_x[n - 22];\n y0 = arr[n - 21];\n y1 = arr[n - 22];\n\n\n } else {\n temp = 0;\n while (miss_index[i] > arr_x[temp]) {\n temp++;\n }\n x0 = arr_x[temp - 1];\n x1 = arr_x[temp];\n y0 = arr[temp - 1];\n y1 = arr[temp];\n\n }\n a = (y1 - y0) / (x1 - x0);\n b = y0 - a * x0;\n ansx = miss_index[i];\n ansy = a * ansx + b;\n System.out.println(df.format(ansy));\n }\n\n }", "private boolean onBorder(double f_xy, double f_xyNext) {\n\t\tdouble lowerBorder = this.f_xLowest;\n\t\tdouble higherBorder = this.f_xHighest;\n\t\t\n\t\tfor(int i = 0 ; i< borders.length; i++) {\n\t\t\thigherBorder = borders[i];\n\t\t\tif((f_xy >= lowerBorder && f_xy < higherBorder) || (f_xyNext >= lowerBorder && f_xyNext < higherBorder)) {\n\t\t\t\t\n\t\t\t\tif((f_xy >= lowerBorder && f_xy < higherBorder) && (f_xyNext >= lowerBorder && f_xyNext < higherBorder)) {\n\t\t\t\t\t\n\t\t\t\t\treturn false;\n\t\t\t\t}\n\t\t\t\treturn true;\n\t\t\t}\n\t\t\tlowerBorder = higherBorder;\n\t\t}\n\t\t\n\t\treturn true;\n\t\t\n\t}", "@Test\n public void test_lowerBound() {\n assertThat(AbstractBoundCurveInterpolator.lowerBoundIndex(0.0d, new double[] {1, 2, 3})).isEqualTo(0);\n assertThat(AbstractBoundCurveInterpolator.lowerBoundIndex(0.5d, new double[] {1, 2, 3})).isEqualTo(0);\n assertThat(AbstractBoundCurveInterpolator.lowerBoundIndex(0.9999d, new double[] {1, 2, 3})).isEqualTo(0);\n // good input\n assertThat(AbstractBoundCurveInterpolator.lowerBoundIndex(1.0d, new double[] {1, 2, 3})).isEqualTo(0);\n assertThat(AbstractBoundCurveInterpolator.lowerBoundIndex(1.0001d, new double[] {1, 2, 3})).isEqualTo(0);\n assertThat(AbstractBoundCurveInterpolator.lowerBoundIndex(1.9999d, new double[] {1, 2, 3})).isEqualTo(0);\n assertThat(AbstractBoundCurveInterpolator.lowerBoundIndex(2.0d, new double[] {1, 2, 3})).isEqualTo(1);\n assertThat(AbstractBoundCurveInterpolator.lowerBoundIndex(2.0001d, new double[] {1, 2, 3})).isEqualTo(1);\n assertThat(AbstractBoundCurveInterpolator.lowerBoundIndex(2.9999d, new double[] {1, 2, 3})).isEqualTo(1);\n assertThat(AbstractBoundCurveInterpolator.lowerBoundIndex(3.0d, new double[] {1, 2, 3})).isEqualTo(2);\n // bad input, but still produces good output\n assertThat(AbstractBoundCurveInterpolator.lowerBoundIndex(3.0001d, new double[] {1, 2, 3})).isEqualTo(2);\n // check zero\n assertThat(AbstractBoundCurveInterpolator.lowerBoundIndex(-1.0d, new double[] {-1, 0, 1})).isEqualTo(0);\n assertThat(AbstractBoundCurveInterpolator.lowerBoundIndex(-0.9999d, new double[] {-1, 0, 1})).isEqualTo(0);\n assertThat(AbstractBoundCurveInterpolator.lowerBoundIndex(-0.0001d, new double[] {-1, 0, 1})).isEqualTo(0);\n assertThat(AbstractBoundCurveInterpolator.lowerBoundIndex(-0.0d, new double[] {-1, 0, 1})).isEqualTo(1);\n assertThat(AbstractBoundCurveInterpolator.lowerBoundIndex(0.0d, new double[] {-1, 0, 1})).isEqualTo(1);\n assertThat(AbstractBoundCurveInterpolator.lowerBoundIndex(1.0d, new double[] {-1, 0, 1})).isEqualTo(2);\n assertThat(AbstractBoundCurveInterpolator.lowerBoundIndex(1.5d, new double[] {-1, 0, 1})).isEqualTo(2);\n }", "private void checkOverlaps() {\r\n final ArrayList<Vertex> overlaps = new ArrayList<Vertex>(3);\r\n final int count = getOutlineNumber();\r\n boolean firstpass = true;\r\n do {\r\n for (int cc = 0; cc < count; cc++) {\r\n final Outline outline = getOutline(cc);\r\n int vertexCount = outline.getVertexCount();\r\n for(int i=0; i < outline.getVertexCount(); i++) {\r\n final Vertex currentVertex = outline.getVertex(i);\r\n if ( !currentVertex.isOnCurve()) {\r\n final Vertex nextV = outline.getVertex((i+1)%vertexCount);\r\n final Vertex prevV = outline.getVertex((i+vertexCount-1)%vertexCount);\r\n final Vertex overlap;\r\n\r\n // check for overlap even if already set for subdivision\r\n // ensuring both triangular overlaps get divided\r\n // for pref. only check in first pass\r\n // second pass to clear the overlaps array(reduces precision errors)\r\n if( firstpass ) {\r\n overlap = checkTriOverlaps0(prevV, currentVertex, nextV);\r\n } else {\r\n overlap = null;\r\n }\r\n if( overlaps.contains(currentVertex) || overlap != null ) {\r\n overlaps.remove(currentVertex);\r\n\r\n subdivideTriangle(outline, prevV, currentVertex, nextV, i);\r\n i+=3;\r\n vertexCount+=2;\r\n addedVerticeCount+=2;\r\n\r\n if(overlap != null && !overlap.isOnCurve()) {\r\n if(!overlaps.contains(overlap)) {\r\n overlaps.add(overlap);\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n firstpass = false;\r\n } while( !overlaps.isEmpty() );\r\n }", "private void validateSortedData() {\n Preconditions.checkArgument(\n indices.length == values.length,\n \"Indices size and values size should be the same.\");\n if (this.indices.length > 0) {\n Preconditions.checkArgument(\n this.indices[0] >= 0 && this.indices[this.indices.length - 1] < this.n,\n \"Index out of bound.\");\n }\n for (int i = 1; i < this.indices.length; i++) {\n Preconditions.checkArgument(\n this.indices[i] > this.indices[i - 1], \"Indices duplicated.\");\n }\n }", "private boolean processXRange()\n\t{\n\t\tint startRow=0,startCol=0,endRow=0,endCol=0;\n\t\t/**Used to tokenize the text received from the\n\t\tx axis value text field.*/\n\t\tStringTokenizer st=new StringTokenizer(xValue.getText(),\",:\");\n\t\ttry\n\t\t{\n\t\t\tif(!st.hasMoreTokens())\n\t\t\t\treturn false;\n\t\t\tstartRow=Integer.parseInt(st.nextToken());\n\n\t\t\tif(!st.hasMoreTokens())\n\t\t\t\treturn false;\n\t\t\tstartCol=Integer.parseInt(st.nextToken());\n\n\t\t\tif(!st.hasMoreTokens())\n\t\t\t\treturn false;\n\t\t\tendRow=Integer.parseInt(st.nextToken());\n\n\t\t\tif(!st.hasMoreTokens())\n\t\t\t\treturn false;\n\t\t\tendCol=Integer.parseInt(st.nextToken());\n\n\t\t}\n\t\tcatch(Exception e)\n\t\t{\n\t\t\treturn false;\n\t\t}\n\t\t//System.out.println(startRow+\"--\"+startCol+\"--\"+endRow+\"--\"+endCol);\n\t\tif(startRow<0 || startCol<0 || endRow<0 || endCol<0)\n\t\t\treturn false;\n\t\tif(startRow!=endRow && startCol!=endCol)\n\t\t\treturn false;\n\t\tif(endRow>49||endCol>17)\n\t\t\treturn false;\n\t\tif(endRow<startRow)\n\t\t{\n\t\t\tint temp;\n\t\t\ttemp=endRow;\n\t\t\tendRow=startRow;\n\t\t\tstartRow=temp;\n\t\t}\n\t\telse if(endCol<startCol)\n\t\t{\n\t\t\tint temp;\n\t\t\ttemp=endCol;\n\t\t\tendCol=startCol;\n\t\t\tstartCol=temp;\n\t\t}\n\t\tif(startRow==endRow)\n\t\t{\n\t\t\txvalues=new String[endCol-startCol+2];\n\t\t\txvalues[0]=new String(\"YESVAL\");\n\t\t\tfor(int i=0;i<(endCol-startCol+1);i++)\n\t\t\t\txvalues[i+1]=new String(ws.data[startRow][startCol+i].toString());\n\t\t}\n\t\telse\n\t\t{\n\t\t\txvalues=new String[endRow-startRow+2];\n\t\t\txvalues[0]=new String(\"YESVAL\");\n\t\t\tfor(int i=0;i<(endRow-startRow+1);i++)\n\t\t\t\txvalues[i+1]=new String(ws.data[startRow+i][startCol].toString());\n\t\t}\n\t\treturn true;\n\t}", "public void boundsLex(int [] a , IntDomainVar [] x , int [] b,int j) throws ContradictionException{\n\n int i =0;\n\n\n while( i< n && a[i]==b[i]){\n\n\n if((x[i].getInf()==a[i] || x[i].updateInf(a[i], this, false)) &&\n (x[i].getSup()==b[i] || x[i].updateSup(b[i], this, false))){\n i++;\n }else{\n this.fail();\n }\n\n }\n\n\n if(i<n )\n if ((x[i].getInf()==a[i] || x[i].updateInf(a[i], this, false)) &&\n (x[i].getSup()==b[i] || x[i].updateSup(b[i], this, false))){\n }else{\n this.fail();\n }\n\n\n if(i==n || x[i].getNextDomainValue(a[i])<b[i]){\n return ;\n }\n\n i+=1;\n\n while(i<n && (b[i]+1 <= a[i]-1) && x[i].getInf()==b[i] && x[i].getSup()==a[i]){\n if(x[i].removeInterval(b[i]+1,a[i]-1, this, false)){\n i++;\n }else{\n this.fail();\n\n }\n }\n\n if(i<n) {\n if (b[i] + 1 <= a[i] - 1 && x[i].getInf() <= b[i] &&\n b[i] <= x[i].getSup() && x[i].getSup() >= a[i] && a[i] >= x[i].getInf()) {\n if (!x[i].removeInterval(b[i] + 1, a[i] - 1, this, false)) {\n this.fail();\n }\n }\n }\n\n }", "public void findUpperAndLowerEdge() throws NoSudokuFoundException{\n int bestUpperHit = 0;\n int bestLowerHit = 0;\n double t = INTERSECT_TOLERANCE;\n for (int h=0; h<nextH; h++) {\n int upperHit = 0;\n int lowerHit = 0;\n // for every horizontal line, check if vertical edge points A and B \n // are on that line.\n double[] hline = horizontalLines[h];\n double hy1 = hline[1],\n hy2 = hline[3];\n for (int v=0; v<nextV; v++){\n double[] vec = verticalLines[v];\n double ay = vec[1],\n by = vec[3];\n // if they are, count them\n if(ay < by) { // A is above B\n if ((hy1<=ay+t && ay<=hy2+t) || (hy1+t>=ay && ay+t>=hy2)){\n // A is between the left and right edge point.\n // only count it if it is above the screen center.\n if(hy1 < centerY && hy2 < centerY) {\n upperHit++;\n }\n } else if ((hy1<=by+t && by<=hy2+t) || (hy1+t>=by && by+t>=hy2)) {\n if(hy1 > centerY && hy2 > centerY) {\n lowerHit++;\n }\n }\n } else { // B is above A\n if ((hy1<=by+t && by<=hy2+t) || (hy1+t>=by && by+t>=hy2)) {\n if(hy1 < centerY && hy2 < centerY) {\n upperHit++;\n }\n } else if ((hy1<=ay+t && ay<=hy2+t) || (hy1+t>=ay && ay+t>=hy2)) {\n if(hy1 > centerY && hy2 > centerY) {\n lowerHit++;\n }\n } \n }\n }\n // take the lines with the highest counts\n if(upperHit > bestUpperHit) {\n edges[0] = horizontalLines[h];\n bestUpperHit = upperHit;\n } else if (lowerHit > bestLowerHit){\n edges[2] = horizontalLines[h];\n bestLowerHit = lowerHit;\n }\n }\n if(bestUpperHit < LINE_THRESHOLD || bestLowerHit < LINE_THRESHOLD){\n throw new NoSudokuFoundException(\"Number of upper (\"+bestUpperHit+\") or lower (\"+bestLowerHit+\") line ends below threshold. h\");\n }\n // Log.v(TAG, \"Best upper hit: \" + bestUpperHit + \", best lower: \" + bestLowerHit);\n }", "@Test\n public void test81() throws Throwable {\n Line2D.Double line2D_Double0 = new Line2D.Double(228.0, 0.0, 228.0, 0.0);\n LogAxis logAxis0 = new LogAxis(\"8dVi7isYx7'@IN\");\n CombinedRangeCategoryPlot combinedRangeCategoryPlot0 = new CombinedRangeCategoryPlot((ValueAxis) logAxis0);\n combinedRangeCategoryPlot0.setAnchorValue((-725.5571138));\n }", "private void checkValues(int yMin2, int yMax2, List<XYValue> listOfValues2) {\n\t\tif(yMin2 < 0) {\n\t\t\tthrow new IllegalArgumentException(\"Number can not be negative!\");\n\t\t}\n\t\tif(yMax2 <= yMin2) {\n\t\t\tthrow new IllegalArgumentException(\"Max has to be greater than min!\");\n\t\t}\n\t\tfor(XYValue value : listOfValues2) {\n\t\t\tif(value.getY() < yMin2) {\n\t\t\t\tthrow new IllegalArgumentException(\"Found smaller y than minimum!\");\n\t\t\t}\n\t\t}\n\t}", "private boolean checkConnection(int x1, int x2) {\n\t\treturn (xStartValue <= x1 && xEndValue >= x1) || (xStartValue <= x2 && xEndValue >= x2) ||\n\t\t\t\t(x1 <= xStartValue && x2 >= xStartValue) || (x1 <= xEndValue && x2 >= xEndValue);\n\t\t\n\t}", "@Test\n public void test00() throws Throwable {\n CombinedRangeCategoryPlot combinedRangeCategoryPlot0 = new CombinedRangeCategoryPlot();\n DefaultCaret defaultCaret0 = new DefaultCaret();\n DefaultBoxAndWhiskerCategoryDataset defaultBoxAndWhiskerCategoryDataset0 = new DefaultBoxAndWhiskerCategoryDataset();\n DefaultKeyedValuesDataset defaultKeyedValuesDataset0 = new DefaultKeyedValuesDataset();\n List list0 = defaultKeyedValuesDataset0.getKeys();\n defaultBoxAndWhiskerCategoryDataset0.add((List) list0, (Comparable) 0, (Comparable) 0);\n List list1 = defaultBoxAndWhiskerCategoryDataset0.getColumnKeys();\n // Undeclared exception!\n try { \n combinedRangeCategoryPlot0.drawRangeGridlines((Graphics2D) null, defaultCaret0, list1);\n } catch(ClassCastException e) {\n //\n // java.lang.Integer cannot be cast to org.jfree.chart.axis.ValueTick\n //\n assertThrownBy(\"org.jfree.chart.plot.CategoryPlot\", e);\n }\n }", "private boolean checkifCollinear(Point[] ptArr, Comparator<Point> cmp, int start){\n\t\tif(start +2 >= ptArr.length) return false;\t\n\t\tif(cmp.compare(ptArr[start],ptArr[start+1]) == cmp.compare(ptArr[start+1],ptArr[start+2]) && cmp.compare(ptArr[start],ptArr[start+1]) == 0){\n\t\t\treturn true;\n\t\t}\t\t\n\t\treturn false;\t\n\t}", "@Test\n public void test52() throws Throwable {\n CyclicNumberAxis cyclicNumberAxis0 = new CyclicNumberAxis(0.0, 0.0);\n CombinedRangeCategoryPlot combinedRangeCategoryPlot0 = new CombinedRangeCategoryPlot((ValueAxis) cyclicNumberAxis0);\n Color color0 = (Color)combinedRangeCategoryPlot0.getDomainGridlinePaint();\n cyclicNumberAxis0.setAxisLineVisible(false);\n Line2D.Double line2D_Double0 = new Line2D.Double(0.0, (-1489.688195002), 0.0, 0.0);\n line2D_Double0.x1 = (-1489.688195002);\n line2D_Double0.y2 = 0.0;\n line2D_Double0.x1 = 2.0;\n double double0 = line2D_Double0.getY2();\n CategoryAxis categoryAxis0 = combinedRangeCategoryPlot0.getDomainAxis(1);\n Point2D.Double point2D_Double0 = new Point2D.Double();\n point2D_Double0.setLocation((-2.147483648E9), 0.75);\n double double1 = point2D_Double0.getX();\n combinedRangeCategoryPlot0.configureRangeAxes();\n Range range0 = combinedRangeCategoryPlot0.getDataRange(cyclicNumberAxis0);\n }", "public void boundsCheck(BigDecimal d) throws InvalidDatatypeValueException {\n boolean minOk = false;\n boolean maxOk = false;\n String upperBound = (fMaxExclusive != null )? ( fMaxExclusive.toString() ):\n ( ( fMaxInclusive != null )?fMaxInclusive.toString():\"\");\n \n String lowerBound = (fMinExclusive != null )? ( fMinExclusive.toString() ):\n (( fMinInclusive != null )?fMinInclusive.toString():\"\"); \n String lowerBoundIndicator = \"\";\n String upperBoundIndicator = \"\";\n \n \n if ( isMaxInclusiveDefined){\n maxOk = (d.compareTo(fMaxInclusive) <= 0);\n upperBound = fMaxInclusive.toString();\n if ( upperBound != null ){\n upperBoundIndicator = \"<=\"; \n } else {\n upperBound=\"\";\n }\n } else if ( isMaxExclusiveDefined){\n maxOk = (d.compareTo(fMaxExclusive) < 0);\n upperBound = fMaxExclusive.toString();\n if ( upperBound != null ){\n upperBoundIndicator = \"<\";\n } else {\n upperBound = \"\";\n }\n } else{\n maxOk = (!isMaxInclusiveDefined && ! isMaxExclusiveDefined);\n }\n \n \n if ( isMinInclusiveDefined){\n minOk = (d.compareTo(fMinInclusive) >= 0);\n lowerBound = fMinInclusive.toString();\n if( lowerBound != null ){\n lowerBoundIndicator = \"<=\";\n }else {\n lowerBound = \"\";\n }\n } else if ( isMinExclusiveDefined){\n minOk = (d.compareTo(fMinExclusive) > 0);\n lowerBound = fMinExclusive.toString();\n if( lowerBound != null ){\n lowerBoundIndicator = \"<\";\n } else {\n lowerBound = \"\";\n }\n } else{\n minOk = (!isMinInclusiveDefined && !isMinExclusiveDefined);\n }\n \n if (!(minOk && maxOk))\n throw new InvalidDatatypeValueException (\n getErrorString(DatatypeMessageProvider.OutOfBounds,\n DatatypeMessageProvider.MSG_NONE,\n new Object [] { d.toString() , lowerBound ,\n upperBound, lowerBoundIndicator, upperBoundIndicator}));\n \n }", "protected void calcMinMax(T t) {\n if (this.mYMax < t.getYMax()) {\n this.mYMax = t.getYMax();\n }\n if (this.mYMin > t.getYMin()) {\n this.mYMin = t.getYMin();\n }\n if (this.mXMax < t.getXMax()) {\n this.mXMax = t.getXMax();\n }\n if (this.mXMin > t.getXMin()) {\n this.mXMin = t.getXMin();\n }\n if (t.getAxisDependency() == YAxis.AxisDependency.LEFT) {\n if (this.mLeftAxisMax < t.getYMax()) {\n this.mLeftAxisMax = t.getYMax();\n }\n if (!(this.mLeftAxisMin > t.getYMin())) return;\n {\n this.mLeftAxisMin = t.getYMin();\n return;\n }\n } else {\n if (this.mRightAxisMax < t.getYMax()) {\n this.mRightAxisMax = t.getYMax();\n }\n if (!(this.mRightAxisMin > t.getYMin())) return;\n {\n this.mRightAxisMin = t.getYMin();\n return;\n }\n }\n }", "@Test\n public void test28() throws Throwable {\n CombinedRangeCategoryPlot combinedRangeCategoryPlot0 = new CombinedRangeCategoryPlot();\n CategoryAnchor categoryAnchor0 = combinedRangeCategoryPlot0.getDomainGridlinePosition();\n RectangleEdge rectangleEdge0 = combinedRangeCategoryPlot0.getRangeAxisEdge((-119));\n }", "@Test\n public void test21() throws Throwable {\n ExtendedCategoryAxis extendedCategoryAxis0 = new ExtendedCategoryAxis(\" twtGuHO\");\n CombinedDomainCategoryPlot combinedDomainCategoryPlot0 = new CombinedDomainCategoryPlot((CategoryAxis) extendedCategoryAxis0);\n Polygon polygon0 = new Polygon();\n Rectangle rectangle0 = polygon0.getBounds();\n DefaultKeyedValuesDataset defaultKeyedValuesDataset0 = new DefaultKeyedValuesDataset();\n List list0 = defaultKeyedValuesDataset0.getKeys();\n combinedDomainCategoryPlot0.drawRangeGridlines((Graphics2D) null, rectangle0, list0);\n rectangle0.height = (-2538);\n boolean boolean0 = combinedDomainCategoryPlot0.isRangeZoomable();\n DatasetChangeEvent datasetChangeEvent0 = new DatasetChangeEvent((Object) list0, (Dataset) defaultKeyedValuesDataset0);\n combinedDomainCategoryPlot0.datasetChanged(datasetChangeEvent0);\n RectangleInsets rectangleInsets0 = new RectangleInsets();\n combinedDomainCategoryPlot0.setAxisOffset(rectangleInsets0);\n }", "@Test\n public void test50() throws Throwable {\n Line2D.Double line2D_Double0 = new Line2D.Double();\n line2D_Double0.x2 = (-2256.58198271);\n double double0 = line2D_Double0.getX1();\n CombinedDomainCategoryPlot combinedDomainCategoryPlot0 = new CombinedDomainCategoryPlot((CategoryAxis) null);\n // Undeclared exception!\n try { \n combinedDomainCategoryPlot0.mapDatasetToRangeAxis((-1483), (-1748));\n } catch(IllegalArgumentException e) {\n //\n // Requires index >= 0.\n //\n assertThrownBy(\"org.jfree.chart.util.AbstractObjectList\", e);\n }\n }", "@Test\n public void test55() throws Throwable {\n CyclicNumberAxis cyclicNumberAxis0 = new CyclicNumberAxis(10.0, 25000.0);\n CombinedRangeCategoryPlot combinedRangeCategoryPlot0 = new CombinedRangeCategoryPlot((ValueAxis) cyclicNumberAxis0);\n combinedRangeCategoryPlot0.configureRangeAxes();\n Rectangle2D.Double rectangle2D_Double0 = new Rectangle2D.Double((-1032.0), 10.0, 25000.0, 0.0);\n }", "private boolean isValidPos(List<Integer> sol) {\n int row = sol.size() - 1;\n int col = sol.get(row);\n \n for (int i = 0; i < row; i++) {\n // we are sure that there will be no conflict in the same row\n // check vertical line, and diagonal line\n if (col == sol.get(i) || Math.abs(col - sol.get(i)) == row - i) {\n return false;\n }\n }\n return true;\n }", "public static void validateInitialConstraints(Constraints constraints) \n throws InvalidInputDataException, ArrayIndexOutOfBoundsException { \n \t\n \tint[][] constraintsArray = Utilities.convertSolutionToArray(constraints);\n \t//check that no non-zero number appears twice in a row\n \tfor (int x=0; x<constraints.getDimSq(); x++) {\n \t\tList<Integer> cellList = new ArrayList<Integer>();\n \t\tfor(int y=0; y<constraints.getDimSq(); y++) {\n \tif (constraintsArray[x][y] != 0){\n \t\tif ((constraintsArray[x][y] < 0) || (constraintsArray[x][y] > constraints.getDimSq())) {\n \t\t\tthrow new InvalidInputDataException(\"Out-of-range value \" + constraintsArray[x][y] + \" found at cell x = \" + x + \" y = \" + y);\n \t\t}\n \t\tInteger currentValue = new Integer(constraintsArray[x][y]);\n \t\tif (cellList.contains(currentValue)){\n \t\t\tthrow new InvalidInputDataException(\"Value \" + currentValue.intValue() + \" found twice in row \" + x);\n \t\t}\n \t\tcellList.add(currentValue);\n \t}\n }\n }\n //check that non-zero number appears twice in a column\n for (int y=0; y<constraints.getDimSq(); y++) {\n List<Integer> cellList = new ArrayList<Integer>();\n for(int x=0; x<constraints.getDimSq(); x++) {\n \tif (constraintsArray[x][y] != 0){\n \t\tInteger currentValue = new Integer(constraintsArray[x][y]);\n \t\tif (cellList.contains(currentValue)) {\n \t\t\tthrow new InvalidInputDataException(\"Value \" + currentValue.intValue() + \" found twice in column \" + y);\n \t\t}\n \t\tcellList.add(currentValue);\n \t}\n }\n }\n //check that no non-zero number appears twice in the same box\n for (int bx=0;bx<constraints.getDim();bx++){\n for (int by=0;by<constraints.getDim();by++) {\n \tList<Integer> cellList = new ArrayList<Integer>();\n \tfor (int x=0; x<constraints.getDimSq(); x++) {\n \t for(int y=0; y<constraints.getDimSq(); y++) {\n \t \tif ((x / constraints.getDim() == bx) && (y / constraints.getDim() == by)){\n \t \tif (constraintsArray[x][y] != 0){\n \t \t\tInteger currentValue = new Integer(constraintsArray[x][y]);\n \t \t\tif (cellList.contains(currentValue)) {\n \t \t\t\tthrow new InvalidInputDataException(\"Value \" + currentValue.intValue() + \" found twice in box \" + bx + \" \" + by);\n \t \t\t}\n \t \t\tcellList.add(currentValue);\n \t \t}\n \t \t}\n \t }\n \t}\n }\n }\n }", "public void checkBounds() {\n for (int k = 0; k < numDataCols; k++) {\n DashDataType<?> dtype = dataTypes[k];\n\n if ( dtype instanceof StringDashDataType ) {\n StringDashDataType strtype = (StringDashDataType) dtype;\n for (int j = 0; j < numSamples; j++) {\n ADCMessage msg = strtype.boundsCheckStandardValue((String) stdObjects[j][k]);\n if ( msg != null ) {\n msg.setRowNumber(j + 1);\n msg.setColNumber(k + 1);\n msg.setColName(userColNames[k]);\n stdMsgList.add(msg);\n }\n }\n }\n else if ( dtype instanceof IntDashDataType ) {\n IntDashDataType inttype = (IntDashDataType) dtype;\n for (int j = 0; j < numSamples; j++) {\n ADCMessage msg = inttype.boundsCheckStandardValue((Integer) stdObjects[j][k]);\n if ( msg != null ) {\n msg.setRowNumber(j + 1);\n msg.setColNumber(k + 1);\n msg.setColName(userColNames[k]);\n stdMsgList.add(msg);\n }\n }\n }\n else if ( dtype instanceof DoubleDashDataType ) {\n DoubleDashDataType dbltype = (DoubleDashDataType) dtype;\n for (int j = 0; j < numSamples; j++) {\n ADCMessage msg = dbltype.boundsCheckStandardValue((Double) stdObjects[j][k]);\n if ( msg != null ) {\n msg.setRowNumber(j + 1);\n msg.setColNumber(k + 1);\n msg.setColName(userColNames[k]);\n stdMsgList.add(msg);\n }\n }\n }\n else {\n throw new IllegalArgumentException(\n \"unexpected data type encountered in bounds checking: \" + dtype);\n }\n }\n }", "public void controlPointsChanged(List<Coordinates> lcp) {\n // sort the control points by x position.\n // this makes things easier later when we paint the function.\n lcp.sort(\n (point1,point2) -> Integer.compare(point1.getX(),point2.getX())\n );\n\n // collect the points in an array before doing the calculations.\n // again, this makes things easier for us.\n controlPoints=lcp.toArray(new Coordinates[0]);\n n=controlPoints.length;\n if(n<2) {\n // nothing to do here\n return;\n }\n double []X = new double[n];\n double []Y = new double[n];\n for(int i =0;i<n;i++){\n \tX[i]=controlPoints[i].getX();\n \tY[i]=controlPoints[i].getY();\n }\n // Construct the linear system S*C=T with n-2 equations.\n // The matrix S contains the left hand side of the equations on slide 13.\n // The matrix Z contains the right hand side of the equations on slide 13.\n double[][] S=new double[n-2][n-2];\n double[] Z=new double[n-2];\n \n // Fill the matrix S and the vector Z and solve S*C=T to get c_2 to c_{n-1}.\n for(int i = 0; i< n-3;i++){\n \tS[i][i]=2*delta(X,i+1,0);\n \tS[i+1][i]=delta(X,i+2,-1);\n \tS[i][i+1]=delta(X,i+1,1);\n \tZ[i]=z(Y,X,i);\n }\n S[n-2][n-2]=2*delta(X,n-1,0);\n \n C= EliminationGaussLegendre.solve(S, Z);\n \n // Calculate the n-1 coefficients b_i and d_i.\n // Note that you need all c_i here (but you know that c_1 and c_n are zero).\n //a_i = y_i;\n for(int i=1 ; i<n ; i++){\n \tD[i-1]=d(Y,X,i-1);\n \tB[i-1]=b(Y,C,X,i-1);\n }\n \n }", "protected int checkWhere(float x, float y)\n\t{\n\t\t//check if it's in the first column\n\t\tif((x>0)&&(x<180))\n\t\t{\n\t\t\t//if it's in the first column, check which row it's in\n\t\t\tif(y<180)\n\t\t\t{\n\t\t\t\treturn 0;\n\t\t\t}\n\t\t\tif(y<360)\n\t\t\t{\n\t\t\t\treturn 1;\n\t\t\t}\n\t\t\tif(y<540)\n\t\t\t{\n\t\t\t\treturn 2;\n\t\t\t}\n\t\t}\n\n\t\t//check if it's in the second column\n\t\tif((x>180)&&(x<360))\n\t\t{\n\t\t\t//if it is, check which row it's in\n\t\t\tif(y<180)\n\t\t\t{\n\t\t\t\treturn 3;\n\t\t\t}\n\t\t\tif(y<360)\n\t\t\t{\n\t\t\t\treturn 4;\n\t\t\t}\n\t\t\tif(y<540)\n\t\t\t{\n\t\t\t\treturn 5;\n\t\t\t}\n\t\t}\n\n\t\t//if it's not in the first or second column, it's in the third column\n\t\tif(x>360)\n\t\t{\n\t\t\t//check which row it's in\n\t\t\tif(y<180)\n\t\t\t{\n\t\t\t\treturn 6;\n\t\t\t}\n\t\t\tif(y<360)\n\t\t\t{\n\t\t\t\treturn 7;\n\t\t\t}\n\t\t\tif(y<540)\n\t\t\t{\n\t\t\t\treturn 8;\n\t\t\t}\n\t\t}\n\t\t//just in case it's not in anything, then return 9.\n\t\t//this will cause the thingy to not change\n\t\treturn 9;\n\t}", "boolean validateOffset() {\n\t\t\tint num = entriesByIndex.size() + 1; // assuming 0, plus 1-N)\n\t\t\tfor (int index : entriesByIndex.keySet()) {\n\t\t\t\tif (index > num || index < 0) {\n\t\t\t\t\treturn false;\n\t\t\t\t}\n\t\t\t}\n\t\t\treturn true;\n\t\t}", "@Test\n public void test33() throws Throwable {\n CombinedRangeCategoryPlot combinedRangeCategoryPlot0 = new CombinedRangeCategoryPlot();\n List list0 = combinedRangeCategoryPlot0.getSubplots();\n PlotOrientation plotOrientation0 = combinedRangeCategoryPlot0.getOrientation();\n SortOrder sortOrder0 = SortOrder.DESCENDING;\n DateAxis dateAxis0 = new DateAxis(\"M+*J(I1\\u0003Du\");\n dateAxis0.setPositiveArrowVisible(true);\n combinedRangeCategoryPlot0.setRangeAxis((ValueAxis) dateAxis0);\n combinedRangeCategoryPlot0.setRowRenderingOrder(sortOrder0);\n combinedRangeCategoryPlot0.setRangeCrosshairVisible(true);\n CategoryAxis categoryAxis0 = combinedRangeCategoryPlot0.getDomainAxisForDataset((-2385));\n combinedRangeCategoryPlot0.setGap((-2385));\n combinedRangeCategoryPlot0.clearRangeMarkers(3);\n XYPointerAnnotation xYPointerAnnotation0 = new XYPointerAnnotation(\"\", 0.0, 1.7976931348623157E308, (-752.113037619));\n Color color0 = (Color)xYPointerAnnotation0.getArrowPaint();\n combinedRangeCategoryPlot0.setNoDataMessagePaint(color0);\n combinedRangeCategoryPlot0.setRangeCrosshairLockedOnData(true);\n combinedRangeCategoryPlot0.setRangeCrosshairLockedOnData(false);\n }", "boolean updatePolicy() {\n double maxUtilityVal = -Double.MAX_VALUE;\n //if(x==19&&y==0)\n // System.out.println(\"minVal: \"+maxUtilityVal);\n for (int i = 0; i < AbsoluteDirection.values().length; i++) {\n double proposedValue = calculateUtility(AbsoluteDirection.values()[i]);\n // if(x==19&&y==0) {\n // System.out.println(\"Proposed value at cell \" + x + \", \" + y + \" is\" + proposedValue);\n\n // }\n if (proposedValue > maxUtilityVal) {\n policyDirection = AbsoluteDirection.values()[i];\n nextUtilityValue = proposedValue; // update curValues to nextValues at the end of iteration\n maxUtilityVal = proposedValue;\n }\n }\n\n return true;\n }", "private void checkAnnotation() {\n if (annotMin != -1)\n Assert.condition(annotMin >= 0, \"min isn't >= 0: '\" + annotMin + \"'\");\n if (annotMax != -1)\n Assert.condition(annotMax >= 0, \"max isn't >= 0: '\" + annotMax + \"'\");\n if ((annotMin != -1) && (annotMax != -1))\n Assert.condition(annotMin <= annotMax,\n \"min isn't <= max: '\" + annotMin + \"', '\" + annotMax + \"'\");\n }", "@Test\n public void test24() throws Throwable {\n CategoryPlot categoryPlot0 = new CategoryPlot();\n categoryPlot0.clearRangeMarkers();\n categoryPlot0.setOutlineVisible(false);\n categoryPlot0.setFixedRangeAxisSpace((AxisSpace) null);\n AxisLocation axisLocation0 = AxisLocation.TOP_OR_RIGHT;\n AxisLocation axisLocation1 = axisLocation0.getOpposite();\n // Undeclared exception!\n try { \n categoryPlot0.setRangeAxisLocation((-24), axisLocation0, true);\n } catch(IllegalArgumentException e) {\n //\n // Requires index >= 0.\n //\n assertThrownBy(\"org.jfree.chart.util.AbstractObjectList\", e);\n }\n }", "private Point[] nearestPairRec(Point[] range, boolean axis) {\n\t\t\tPoint[] Answer = new Point[2];\n\t\t\tif (range.length < 4) return nearestPair3Points(range);\n\t\t\tPoint[] MinPointsLeft = new Point[2];\n\t\t\tPoint[] MinPointsRight = new Point[2];\n\t\t\tPoint[] MinPointsInStrip = new Point[2];\n\t\t\tdouble MinDistance = -1; //it will be change for sure, because we pass the array only if it containes 4 points and above.\n\t\t\tdouble MinDistanceInStrip;\n\t\t\t//step 4\n\t\t\tif (axis){\n\t\t\t\tMinPointsLeft = nearestPairRec(getPointsInRangeRegAxis(range[0].getX(), range[(range.length)/2].getX(), axis), axis);\n\t\t\t\tMinPointsRight =nearestPairRec(getPointsInRangeRegAxis(range[((range.length)/2)+1].getX(), range[range.length-1].getX() ,axis), axis);\n\t\t\t}\n\t\t\telse{\n\t\t\t\tMinPointsLeft = nearestPairRec(getPointsInRangeRegAxis(range[0].getY(), range[(range.length)/2].getY(), axis), axis);\n\t\t\t\tMinPointsRight =nearestPairRec(getPointsInRangeRegAxis(range[((range.length)/2)+1].getY(), range[range.length-1].getY() ,axis), axis);\n\t\t\t}\n\t\t\t//step 5\n\t\t\tif (MinPointsLeft!=null && MinPointsRight!=null){\n\t\t\t\tif (Distance(MinPointsLeft[0], MinPointsLeft[1]) > Distance(MinPointsRight[0], MinPointsRight[1])){\n\t\t\t\t\tMinDistance = Distance(MinPointsRight[0], MinPointsRight[1]);\n\t\t\t\t\tAnswer = MinPointsRight;\n\t\t\t\t}else{\n\t\t\t\t\tMinDistance = Distance(MinPointsLeft[0], MinPointsLeft[1]);\n\t\t\t\t\tAnswer = MinPointsLeft;\n\t\t\t\t}\n\t\t\t}else if (MinPointsLeft!=null && MinPointsRight==null) {\n\t\t\t\tMinDistance = Distance(MinPointsLeft[0], MinPointsLeft[1]);\n\t\t\t\tAnswer = MinPointsLeft;\n\t\t\t}else if (MinPointsRight!=null && MinPointsLeft==null){\n\t\t\t\tMinDistance = Distance(MinPointsRight[0], MinPointsRight[1]);\n\t\t\t\tAnswer = MinPointsRight;\n\t\t\t}\n\t\t\t//step 6 find the nearest point around the median\n\t\t\tint upper;\n\t\t\tint lower;\n\t\t\tif (MinDistance==-1) MinDistance = 0;\n\t\t\tif (axis){\n\t\t\t\tupper = (int) (range[(range.length)/2].getX()+MinDistance);\n\t\t\t\tlower = (int) (range[(range.length)/2].getX()-MinDistance);\n\t\t\t}\n\t\t\telse{\n\t\t\t\tupper = (int) (range[(range.length)/2].getY()+MinDistance);\n\t\t\t\tlower = (int) (range[(range.length)/2].getY()-MinDistance);\n\t\t\t}\n\t\t\trange = getPointsInRangeOppAxis(lower, upper, axis);\n\t\t\tif (range.length>=2) MinPointsInStrip = nearestPointInArray(range);\n\t\t\tif (MinPointsInStrip[0]!=null){\n\t\t\t\tMinDistanceInStrip = Distance(MinPointsInStrip[0], MinPointsInStrip[1]);\n\t\t\t\tif (MinDistanceInStrip < MinDistance) return MinPointsInStrip;\n\t\t\t}\n\t\t\treturn Answer;\n\t\t}", "public boolean isValid(){\n\t\treturn points.size() >= 2;\n\t}", "private boolean consistencyCheckC2Constraints(double[][] xResults, double[][] yResults, double[] alpha) {\n\t\tint n = mExplicitMDP.getNumStates();\n\n\t\tfor (int i = 0; i < n; i++) {\n\t\t\tdouble outxValue = GRBSolverUtils.getOutValue(i, xResults, mExplicitMDP);\n\t\t\tdouble outyValue = GRBSolverUtils.getOutValue(i, yResults, mExplicitMDP);\n\t\t\tdouble inyValue = GRBSolverUtils.getInValue(i, yResults, mExplicitMDP);\n\t\t\tboolean satisfied = GRBSolverUtils.approximatelyEqual(outxValue + outyValue - inyValue, alpha[i],\n\t\t\t\t\tmSettings.getFeasibilityTolerance());\n\n\t\t\tif (!satisfied) {\n\t\t\t\treturn false;\n\t\t\t}\n\t\t}\n\t\treturn true;\n\t}", "@Test\n public void test52() throws Throwable {\n ThermometerPlot thermometerPlot0 = new ThermometerPlot();\n NumberAxis numberAxis0 = (NumberAxis)thermometerPlot0.getRangeAxis();\n CombinedRangeCategoryPlot combinedRangeCategoryPlot0 = new CombinedRangeCategoryPlot((ValueAxis) numberAxis0);\n CategoryAxis3D categoryAxis3D0 = new CategoryAxis3D(\"Null 'thresholdType' argument.\");\n AxisChangeEvent axisChangeEvent0 = new AxisChangeEvent((Axis) categoryAxis3D0);\n ChartChangeEventType chartChangeEventType0 = axisChangeEvent0.getType();\n axisChangeEvent0.setType(chartChangeEventType0);\n thermometerPlot0.axisChanged(axisChangeEvent0);\n CategoryAxis3D categoryAxis3D1 = new CategoryAxis3D(\"\");\n int int0 = combinedRangeCategoryPlot0.getDomainAxisIndex(categoryAxis3D1);\n LegendItemCollection legendItemCollection0 = combinedRangeCategoryPlot0.getFixedLegendItems();\n AxisLocation axisLocation0 = combinedRangeCategoryPlot0.getRangeAxisLocation();\n // Undeclared exception!\n try { \n combinedRangeCategoryPlot0.setRangeAxisLocation((-1), axisLocation0, false);\n } catch(IllegalArgumentException e) {\n //\n // Requires index >= 0.\n //\n assertThrownBy(\"org.jfree.chart.util.AbstractObjectList\", e);\n }\n }", "public void checkCellStatus()\r\n {\r\n for (int columns = 0; columns < LOWER_BOUND; columns ++)\r\n {\r\n for (int rows = 0; rows < RIGHT_BOUND; rows ++)\r\n {\r\n checkNeighbours(rows, columns);\r\n } // end of for (int rows = 0; rows < RIGHT_BOUND; rows ++)\r\n } // end of for (int columns = 0; columns < LOWER_BOUND; columns ++)\r\n }", "@Test\n public void test33() throws Throwable {\n CombinedRangeCategoryPlot combinedRangeCategoryPlot0 = new CombinedRangeCategoryPlot();\n DefaultPieDataset defaultPieDataset0 = new DefaultPieDataset();\n RingPlot ringPlot0 = new RingPlot((PieDataset) defaultPieDataset0);\n Second second0 = new Second();\n Second second1 = (Second)second0.next();\n defaultPieDataset0.setValue((Comparable) second1, (Number) null);\n Comparable comparable0 = ringPlot0.getSectionKey(0);\n CategoryMarker categoryMarker0 = new CategoryMarker(comparable0);\n Layer layer0 = Layer.BACKGROUND;\n combinedRangeCategoryPlot0.addDomainMarker(75, categoryMarker0, layer0);\n Layer layer1 = Layer.BACKGROUND;\n boolean boolean0 = combinedRangeCategoryPlot0.isRangeZoomable();\n combinedRangeCategoryPlot0.clearDomainMarkers();\n Point2D.Double point2D_Double0 = new Point2D.Double();\n point2D_Double0.x = (double) (-1);\n double double0 = point2D_Double0.y;\n combinedRangeCategoryPlot0.clearRangeAxes();\n combinedRangeCategoryPlot0.setDomainGridlinesVisible(false);\n CategoryAnchor categoryAnchor0 = combinedRangeCategoryPlot0.getDomainGridlinePosition();\n Rectangle2D.Double rectangle2D_Double0 = new Rectangle2D.Double();\n boolean boolean1 = combinedRangeCategoryPlot0.isRangeGridlinesVisible();\n XYSplineAndShapeRenderer xYSplineAndShapeRenderer0 = new XYSplineAndShapeRenderer();\n }", "@Test\n public void test83() throws Throwable {\n CategoryPlot categoryPlot0 = new CategoryPlot();\n AxisLocation axisLocation0 = AxisLocation.TOP_OR_RIGHT;\n AxisLocation axisLocation1 = axisLocation0.getOpposite();\n AxisLocation axisLocation2 = axisLocation0.getOpposite();\n AxisLocation axisLocation3 = AxisLocation.getOpposite(axisLocation0);\n AxisLocation axisLocation4 = AxisLocation.getOpposite(axisLocation3);\n categoryPlot0.clearRangeAxes();\n AxisLocation axisLocation5 = AxisLocation.getOpposite(axisLocation2);\n // Undeclared exception!\n try { \n categoryPlot0.setRangeAxisLocation((-223), axisLocation0);\n } catch(IllegalArgumentException e) {\n //\n // Requires index >= 0.\n //\n assertThrownBy(\"org.jfree.chart.util.AbstractObjectList\", e);\n }\n }", "@Test\n public void test18() throws Throwable {\n CombinedRangeCategoryPlot combinedRangeCategoryPlot0 = new CombinedRangeCategoryPlot();\n boolean boolean0 = combinedRangeCategoryPlot0.equals(combinedRangeCategoryPlot0);\n CategoryDataset categoryDataset0 = combinedRangeCategoryPlot0.getDataset();\n TextBox textBox0 = new TextBox();\n NumberAxis3D numberAxis3D0 = new NumberAxis3D(\"\");\n combinedRangeCategoryPlot0.setRangeAxis((ValueAxis) numberAxis3D0);\n RectangleInsets rectangleInsets0 = textBox0.getInteriorGap();\n combinedRangeCategoryPlot0.setAxisOffset(rectangleInsets0);\n Color color0 = (Color)combinedRangeCategoryPlot0.getRangeCrosshairPaint();\n Line2D.Double line2D_Double0 = new Line2D.Double();\n double double0 = line2D_Double0.getY1();\n }", "private void checkFormat() {\n if (y.pixelStride != 1) {\n throw new IllegalArgumentException(String.format(\n \"Pixel stride for Y plane must be 1 but got %d instead\",\n y.pixelStride\n ));\n }\n if (u.pixelStride != v.pixelStride || u.rowStride != v.rowStride) {\n throw new IllegalArgumentException(String.format(\n \"U and V planes must have the same pixel and row strides \" +\n \"but got pixel=%d row=%d for U \" +\n \"and pixel=%d and row=%d for V\",\n u.pixelStride, u.rowStride,\n v.pixelStride, v.rowStride\n ));\n }\n if (u.pixelStride != 1 && u.pixelStride != 2) {\n throw new IllegalArgumentException(\n \"Supported pixel strides for U and V planes are 1 and 2\"\n );\n }\n }", "static int getExitAxis(S2Point n) {\n // assert (intersectsFace(n));\n if (intersectsOppositeEdges(n)) {\n // The line passes through opposite edges of the face.\n // It exits through the v=+1 or v=-1 edge if the u-component of N has a\n // larger absolute magnitude than the v-component.\n return (Math.abs(n.x) >= Math.abs(n.y)) ? 1 : 0;\n } else {\n // The line passes through two adjacent edges of the face.\n // It exits the v=+1 or v=-1 edge if an even number of the components of N\n // are negative. We test this using signbit() rather than multiplication\n // to avoid the possibility of underflow.\n // assert(n.x != 0 && n.y != 0 && n.z != 0);\n return ((n.x < 0) ^ (n.y < 0) ^ (n.z < 0)) ? 0 : 1;\n }\n }", "static int [][] checkPreventer( int[][]MultiArray,int CurrentX, int CurrentY, int[] ComXY, String CurrentTitle){\n\t\touterloop_TopLeftTiles:\n\t\tfor(int j = 1; j <=7 ; j++){\n\t\t\tint [] NewXY = new int[2];\n\t\t\tNewXY[0] = CurrentX - j;\n\t\t\tNewXY[1] = CurrentY - j;\n\t\t\t\n\t\t\tif (NewXY[0] < 0 || NewXY[1] < 0 ){\n\t\t\t\t//break due to out of bounds\n\t\t\t\tbreak outerloop_TopLeftTiles;\n\t\t\t}\n\t\t\tfor(int i = 0 ; i < aggregateBlacksEXKing(CurrentTitle,ComXY).length ; i++) {\n\t\t\t\tint[] Coordinate = aggregateBlacksEXKing(CurrentTitle,ComXY)[i];\n\t\t\t\tif(Arrays.equals(Coordinate, NewXY)){\n\t\t\t\t\tbreak outerloop_TopLeftTiles;\n\t\t\t\t}\t\t \t\t\t \n\t\t\t}\n\t\n\n\t\t\tfor(int[] i: aggregateWhitesForCheck(CurrentTitle, ComXY)){\n\t\t\t\tint[] Coordinate = i;\n\t\t\t\tif(Arrays.equals(Coordinate, NewXY)){\n\t\t\t\t\tbreak outerloop_TopLeftTiles;\n\t\t\t\t}\t \n\t\t\t}\n\t\t\t\n\t\t\tif(Arrays.equals(NewXY,ComXY) && CurrentTitle != \"Black King (E8)\"){\n\t\t\t\t//this if statement is necessary to allow pieces to block bishop's line of sight\n\t\t\t\t////System.out.println(\"Outerbreak3.3\");\n\t\t\t\tbreak outerloop_TopLeftTiles;\n\t\t\t}\n\n\t\t\tfor(int i = 0 ; i < MultiArray.length ; i++) {\n\t\t\t\tif(Arrays.equals(MultiArray[i], NewXY)){\n\t\t\t\t\t//System.out.println(\"White Bishop threatining check from the bottom right\");\n\t\t\t\t\tMultiArray[i]=null;\t\n\t\t\t\t\tbreak outerloop_TopLeftTiles; \n\t\t\t\t}\t\t \t\t\t \n\t\t\t}\n\t\t}\n\t\t\n\t\t//top right tiles\n\t\touterloop_TopRightTiles:\n\t\tfor(int j = 1; j <=7 ; j++){\n\t\t\tint [] NewXY = new int[2];\n\t\t\tNewXY[0] = CurrentX + j;\n\t\t\tNewXY[1] = CurrentY - j;\n\t\t\t\n\t\t\tif (NewXY[0] > 7 || NewXY[1] < 0 ){\n\t\t\t\t//break due to out of bounds\n\t\t\t\tbreak outerloop_TopRightTiles;\n\t\t\t}\n\t\t\tfor(int i = 0 ; i < aggregateBlacksEXKing(CurrentTitle,ComXY).length ; i++) {\n\t\t\t\tint[] Coordinate = aggregateBlacksEXKing(CurrentTitle,ComXY)[i];\n\t\t\t\tif(Arrays.equals(Coordinate, NewXY)){\n\t\t\t\t\tbreak outerloop_TopRightTiles;\n\t\t\t\t}\t\t \t\t\t \n\t\t\t}\n\t\t\t\n\n\t\t\tfor(int[] i: aggregateWhitesForCheck(CurrentTitle, ComXY)){\n\t\t\t\tint[] Coordinate = i;\n\t\t\t\tif(Arrays.equals(Coordinate, NewXY)){\n\t\t\t\t\tbreak outerloop_TopRightTiles;\n\t\t\t\t}\t \n\t\t\t}\n\t\t\tif(Arrays.equals(NewXY,ComXY) && CurrentTitle != \"Black King (E8)\"){\n\t\t\t\t//this if statement is necessary to allow pieces to block rook's line of sight\n\t\t\t\tbreak outerloop_TopRightTiles;\n\t\t\t}\n\t\t\tfor(int i = 0 ; i < MultiArray.length ; i++) {\n\t\t\t\tif(Arrays.equals(MultiArray[i], NewXY)){\n\t\t\t\t\t//System.out.println(\"White Bishop threatining check from the bottom left\");\n\t\t\t\t\tMultiArray[i]=null;\t\n\t\t\t\t\tbreak outerloop_TopRightTiles; \n\t\t\t\t}\t\t \t\t\t \n\t\t\t}\n\t\t}\n\t\t\n\t\t//bottom left tiles\n\t\touterloop_BottomLeftTiles:\n\t\tfor(int j = 1; j <=7 ; j++){\n\t\t\tint [] NewXY = new int[2];\n\t\t\tNewXY[0] = CurrentX - j;\n\t\t\tNewXY[1] = CurrentY + j;\n\n\t\t\tif (NewXY[0] < 0 || NewXY[1] > 7 ){\n\t\t\t\t//break due to out of bounds\n\t\t\t\tbreak outerloop_BottomLeftTiles;\n\t\t\t}\n\t\t\t\n\t\t\tfor(int i = 0 ; i < aggregateBlacksEXKing(CurrentTitle,ComXY).length ; i++) {\n\t\t\t\tint[] Coordinate = aggregateBlacksEXKing(CurrentTitle,ComXY)[i];\n\t\t\t\tif(Arrays.equals(Coordinate, NewXY)){\n\t\t\t\t\tbreak outerloop_BottomLeftTiles;\n\t\t\t\t}\t\t \t\t\t \n\t\t\t}\n\t\t\n\n\t\t\tfor(int[] i: aggregateWhitesForCheck(CurrentTitle, ComXY)){\n\t\t\t\tint[] Coordinate = i;\n\t\t\t\tif(Arrays.equals(Coordinate, NewXY)){\n\t\t\t\t\t////System.out.println(\"Outerbreak3.2\");\n\t\t\t\t\tbreak outerloop_BottomLeftTiles;\n\t\t\t\t}\t\t \n\t\t\t}\n\t\t\tif(Arrays.equals(NewXY,ComXY) && CurrentTitle != \"Black King (E8)\"){\n\t\t\t\t//this if statement is necessary to allow pieces to block rook's line of sight\n\t\t\t\t////System.out.println(\"Outerbreak3.3\");\n\t\t\t\tbreak outerloop_BottomLeftTiles;\n\t\t\t}\n\n\t\t\tfor(int i = 0 ; i < MultiArray.length ; i++) {\n\t\t\t\tif(Arrays.equals(MultiArray[i], NewXY)){\n\t\t\t\t\t////System.out.println(\"Outerbreak3.4\");\n\t\t\t\t\t//System.out.println(\"White Bishop threatining check from the top right\");\n\t\t\t\t\tMultiArray[i]=null;\t\n\t\t\t\t\tbreak outerloop_BottomLeftTiles; \n\t\t\t\t}\t\t \t\t\t \n\t\t\t}\n\t\t}\n\t\t//bottom right tiles\n\t\touterloop_BottomRightTiles:\n\t\tfor(int j = 1; j <=7 ; j++){\n\t\t\tint [] NewXY = new int[2];\n\t\t\tNewXY[0] = CurrentX + j;\n\t\t\tNewXY[1] = CurrentY + j;\n\t\t\t\n\t\t\tif (NewXY[0] > 7 || NewXY[1] > 7 ){\n\t\t\t\t//break due to out of bounds\n\t\t\t\tbreak outerloop_BottomRightTiles;\n\t\t\t}\n\t\t\tfor(int i = 0 ; i < aggregateBlacksEXKing(CurrentTitle,ComXY).length ; i++) {\n\t\t\t\tint[] Coordinate = aggregateBlacksEXKing(CurrentTitle,ComXY)[i];\n\t\t\t\tif(Arrays.equals(Coordinate, NewXY)){\n\t\t\t\t\tbreak outerloop_BottomRightTiles;\n\t\t\t\t}\t\t \t\t\t \n\t\t\t}\n\t\t\t\n\n\t\t\tfor(int[] i: aggregateWhitesForCheck(CurrentTitle, ComXY)){\n\t\t\t\tint[] Coordinate = i;\n\t\t\t\tif(Arrays.equals(Coordinate, NewXY)){\n\t\t\t\t\tbreak outerloop_BottomRightTiles;\n\t\t\t\t}\t\t \n\t\t\t}\n\t\t\tif(Arrays.equals(NewXY,ComXY) && CurrentTitle != \"Black King (E8)\"){\n\t\t\t\t//this if statement is necessary to allow pieces to block rook's line of sight\n\t\t\t\tbreak outerloop_BottomRightTiles;\n\t\t\t}\n\t\t\tfor(int i = 0 ; i < MultiArray.length ; i++) {\n\t\t\t\tif(Arrays.equals(MultiArray[i], NewXY)){\n\t\t\t\t\t//System.out.println(\"White Bishop threatining check from the top left\");\n\t\t\t\t\tMultiArray[i]=null;\t\n\t\t\t\t\tbreak outerloop_BottomRightTiles;\n\t\t\t\t}\t\t \t\t\t \n\t\t\t}\n\t\t}\n\t\t\n\t\treturn MultiArray;\n\t}", "@Override\n public List<XYCoords> interpolate(XYSeries series, Params params) {\n if (params.getPointPerSegment() < 2) {\n throw new IllegalArgumentException(\n \"pointsPerSegment must be greater than 2, since 2 points is just the linear segment.\");\n }\n\n // Cannot interpolate curves given only two points. Two points\n // is best represented as a simple line segment.\n if (series.size() < 3) {\n throw new IllegalArgumentException(\"Cannot interpolate a series with fewer than 3 vertices.\");\n }\n\n // Get the change in x and y between the first and second coordinates.\n double dx = series.getX(1).doubleValue() - series.getX(0).doubleValue();\n double dy = series.getY(1).doubleValue() - series.getY(0).doubleValue();\n\n // Then using the change, extrapolate backwards to find a control point.\n double x1 = series.getX(0).doubleValue() - dx;\n double y1 = series.getY(0).doubleValue() - dy;\n\n // Actually create the start point from the extrapolated values.\n XYCoords start = new XYCoords(x1, y1);\n\n // Repeat for the end control point.\n int n = series.size() -1;\n dx = series.getX(n).doubleValue() - series.getX(n-1).doubleValue();\n dy = series.getY(n).doubleValue() - series.getY(n - 1).doubleValue();\n double xn = series.getX(n).doubleValue() + dx;\n double yn = series.getY(n).doubleValue() + dy;\n XYCoords end = new XYCoords(xn, yn);\n\n // TODO: figure out whether this extra control-point synthesis is\n // TODO: really necessary and either remove the above or fix the below.\n // insert the start control point at the start of the vertices list.\n // TODO vertices.add(0, start);\n\n // append the end control ponit to the end of the vertices list.\n // TODO vertices.add(end);\n //}\n\n ExtrapolatedXYSeries extrapolatedXYSeries = new ExtrapolatedXYSeries(series, start, end);\n\n // Dimension a result list of coordinates.\n List<XYCoords> result = new ArrayList<>();\n\n // When looping, remember that each cycle requires 4 points, starting\n // with i and ending with i+3. So we don't loop through all the points.\n for (int i = 0; i < extrapolatedXYSeries.size() - 3; i++) {\n\n // Actually calculate the Catmull-Rom curve for one segment.\n List<XYCoords> points = interpolate(extrapolatedXYSeries, i, params);\n\n // Since the middle points are added twice, once for each bordering\n // segment, we only add the 0 index result point for the first\n // segment. Otherwise we will have duplicate points.\n if (result.size() > 0) {\n points.remove(0);\n }\n\n // Add the coordinates for the segment to the result list.\n result.addAll(points);\n }\n return result;\n\n }", "boolean losCompare(double x1, double y1, double x2, double y2, CObject pHo)\r\n {\r\n double delta;\r\n int x, y;\r\n\r\n int xLeft = pHo.hoX - pHo.hoImgXSpot;\r\n int xRight = xLeft + pHo.hoImgWidth;\r\n int yTop = pHo.hoY - pHo.hoImgYSpot;\r\n int yBottom = yTop + pHo.hoImgHeight;\r\n\r\n if (x2 - x1 > y2 - y1)\r\n {\r\n delta = (double) (y2 - y1) / (double) (x2 - x1);\r\n if (x2 > x1)\r\n {\r\n if (xRight < x1 || xLeft >= x2)\r\n {\r\n return false;\r\n }\r\n }\r\n else\r\n {\r\n if (xRight < x2 || xLeft >= x1)\r\n {\r\n return false;\r\n }\r\n }\r\n y = (int) (delta * (xLeft - x1) + y1);\r\n if (y >= yTop && y < yBottom)\r\n {\r\n return true;\r\n }\r\n\r\n y = (int) (delta * (xRight - x1) + y1);\r\n if (y >= yTop && y < yBottom)\r\n {\r\n return true;\r\n }\r\n\r\n return false;\r\n }\r\n else\r\n {\r\n delta = (double) (x2 - x1) / (double) (y2 - y1);\r\n if (y2 > y1)\r\n {\r\n if (yBottom < y1 || yTop >= y2)\r\n {\r\n return false;\r\n }\r\n }\r\n else\r\n {\r\n if (yBottom < y2 || yTop >= y1)\r\n {\r\n return false;\r\n }\r\n }\r\n x = (int) (delta * (yTop - y1) + x1);\r\n if (x >= xLeft && x < xRight)\r\n {\r\n return true;\r\n }\r\n\r\n x = (int) (delta * (yTop - y1) + x1);\r\n if (x >= xLeft && x < xRight)\r\n {\r\n return true;\r\n }\r\n\r\n return false;\r\n }\r\n }", "@Test\n public void test59() throws Throwable {\n Point2D.Double point2D_Double0 = new Point2D.Double();\n point2D_Double0.y = (-365.83);\n point2D_Double0.setLocation(0.0, 0.0);\n CombinedRangeCategoryPlot combinedRangeCategoryPlot0 = new CombinedRangeCategoryPlot();\n combinedRangeCategoryPlot0.mapDatasetToRangeAxis(1051, 1051);\n boolean boolean0 = combinedRangeCategoryPlot0.isDomainZoomable();\n PlotOrientation plotOrientation0 = PlotOrientation.HORIZONTAL;\n // Undeclared exception!\n try { \n Plot.resolveDomainAxisLocation((AxisLocation) null, plotOrientation0);\n } catch(IllegalArgumentException e) {\n //\n // Null 'location' argument.\n //\n assertThrownBy(\"org.jfree.chart.plot.Plot\", e);\n }\n }", "private ArrayList<XYValue> sortArray(ArrayList<XYValue> array){\n /*\n //Sorts the xyValues in Ascending order to prepare them for the PointsGraphSeries<DataSet>\n */\n int factor = Integer.parseInt(String.valueOf(Math.round(Math.pow(array.size(),2))));\n int m = array.size()-1;\n int count = 0;\n Log.d(TAG, \"sortArray: Sorting the XYArray.\");\n\n while(true){\n m--;\n if(m <= 0){\n m = array.size() - 1;\n }\n Log.d(TAG, \"sortArray: m = \" + m);\n try{\n //print out the y entrys so we know what the order looks like\n //Log.d(TAG, \"sortArray: Order:\");\n //for(int n = 0;n < array.size();n++){\n //Log.d(TAG, \"sortArray: \" + array.get(n).getY());\n //}\n double tempY = array.get(m-1).getY();\n double tempX = array.get(m-1).getX();\n if(tempX > array.get(m).getX() ){\n array.get(m-1).setY(array.get(m).getY());\n array.get(m).setY(tempY);\n array.get(m-1).setX(array.get(m).getX());\n array.get(m).setX(tempX);\n }\n else if(tempY == array.get(m).getY()){\n count++;\n Log.d(TAG, \"sortArray: count = \" + count);\n }\n\n else if(array.get(m).getX() > array.get(m-1).getX()){\n count++;\n Log.d(TAG, \"sortArray: count = \" + count);\n }\n //break when factorial is done\n if(count == factor ){\n break;\n }\n }catch(ArrayIndexOutOfBoundsException e){\n Log.e(TAG, \"sortArray: ArrayIndexOutOfBoundsException. Need more than 1 data point to create Plot.\" +\n e.getMessage());\n break;\n }\n }\n return array;\n }", "private boolean isHorizantalLines2Points(Point p1, Point p2) {\n\n if (abs(p1.y - p2.y ) < 70 && p1.x != p2.x) {\n return true;\n }\n return false;\n }", "private boolean tryBorder(int x, int y){\n\n\t\treturn y == this.dimension - 1 || x == this.dimension - 1;\n\t}", "@Test\n public void test24() throws Throwable {\n double[] doubleArray0 = new double[5];\n PolynomialFunctionLagrangeForm polynomialFunctionLagrangeForm0 = new PolynomialFunctionLagrangeForm(doubleArray0, doubleArray0);\n try { \n UnivariateRealSolverUtils.solve((UnivariateRealFunction) polynomialFunctionLagrangeForm0, (-628.8590785579964), 31.140624862635367);\n fail(\"Expecting exception: Exception\");\n \n } catch(Exception e) {\n //\n // Abscissa 0 is duplicated at both indices 1 and 1\n //\n assertThrownBy(\"org.apache.commons.math.analysis.polynomials.PolynomialFunctionLagrangeForm\", e);\n }\n }", "final void checkAxis( final DatumType type )\n throws IllegalArgumentException {\n final int dimension = getDimension();\n for ( int i = 0; i < dimension; i++ ) {\n AxisOrientation check = getAxis( i ).orientation;\n if ( type != null && !type.isCompatibleOrientation( check ) ) {\n throw new IllegalArgumentException(\n Resources.format(\n ResourceKeys.ERROR_ILLEGAL_AXIS_ORIENTATION_$2,\n check.getName( null ),\n Utilities.getShortClassName( this ) ) );\n }\n check = check.absolute();\n if ( !check.equals( AxisOrientation.OTHER ) ) {\n for ( int j = i + 1; j < dimension; j++ ) {\n if ( check.equals( getAxis( j ).orientation.absolute() ) ) {\n final String nameI = getAxis( i ).orientation.getName( null );\n final String nameJ = getAxis( j ).orientation.getName( null );\n throw new IllegalArgumentException(\n Resources.format(\n ResourceKeys.ERROR_COLINEAR_AXIS_$2,\n nameI, nameJ ) );\n }\n }\n }\n }\n }", "private void settingXY9Array(int x, int y, int[] arrX, int[] arrY) {\n for (int i = 0; i < 9; i++) {\n arrY[i] = y + i / 3 - 1;\n }\n arrX[0] = x - 1;\n arrX[1] = x;\n arrX[2] = x + 1;\n arrX[3] = x - 1;\n arrX[4] = x;\n arrX[5] = x + 1;\n arrX[6] = x - 1;\n arrX[7] = x;\n arrX[8] = x + 1;\n for (int i = 0; i < arrX.length; i++) {\n if (arrX[i] >= numSqW || arrX[i] < 0 || arrY[i] < 0 || arrX[i] >= numSqH) {\n arrX[i] = -1;\n arrY[i] = -1;\n }\n }\n }", "boolean between(tPoint p2)\n {\n if (! this.collinear(p2))\n return false;\n \n //check to see if line is vertical\n if (this.p0.x != this.p1.x)\n {\n //if not vertical, check to see if point overlaps in x\n return (((this.p0.x < p2.x) && (p2.x < this.p1.x)) |\n ((this.p0.x > p2.x) && (p2.x > this.p1.x)));\n }\n else\n {\n //if vertical, check to see if point overlaps in y\n return (((this.p0.y < p2.y) && (p2.y < this.p1.y)) |\n ((this.p0.y > p2.y) && (p2.y > this.p1.y)));\n }\n }", "private static void checkFromToBounds(int paramInt1, int paramInt2, int paramInt3) {\n/* 386 */ if (paramInt2 > paramInt3) {\n/* 387 */ throw new ArrayIndexOutOfBoundsException(\"origin(\" + paramInt2 + \") > fence(\" + paramInt3 + \")\");\n/* */ }\n/* */ \n/* 390 */ if (paramInt2 < 0) {\n/* 391 */ throw new ArrayIndexOutOfBoundsException(paramInt2);\n/* */ }\n/* 393 */ if (paramInt3 > paramInt1) {\n/* 394 */ throw new ArrayIndexOutOfBoundsException(paramInt3);\n/* */ }\n/* */ }", "@Test\n public void test31() throws Throwable {\n CombinedDomainCategoryPlot combinedDomainCategoryPlot0 = new CombinedDomainCategoryPlot();\n combinedDomainCategoryPlot0.setAnchorValue(2191.3904);\n Rectangle2D.Double rectangle2D_Double0 = new Rectangle2D.Double(2191.3904, (-1506.5146538784184), (-1506.5146538784184), 1734.5430998130028);\n double double0 = rectangle2D_Double0.getX();\n ZoneInfo zoneInfo0 = (ZoneInfo)TimeZone.getDefault();\n TimeSeriesCollection timeSeriesCollection0 = new TimeSeriesCollection((TimeZone) zoneInfo0);\n Range range0 = timeSeriesCollection0.getDomainBounds(false);\n ModuloAxis moduloAxis0 = new ModuloAxis((String) null, (Range) null);\n int int0 = combinedDomainCategoryPlot0.getRangeAxisIndex(moduloAxis0);\n }", "Point3D[] reinterpolate_alone_y (int n, Point3D[] a) {\n if (n < 2) n = 2;\n int len = a.length;\n if (n == len) return a; // nothing to do\n int idx_last = len -1;\n int seg_count = idx_last;\n double y0 = a[0].y;\n double seg = span/seg_count;\n Point3D bottom = new Point3D(a[0].x - (a[1].x - a[0].x),\n a[0].y - (a[1].y - a[0].y),\n a[0].z - (a[1].z - a[0].z));\n Point3D top = new Point3D(a[idx_last].x + (a[idx_last].x - a[idx_last-1].x),\n a[idx_last].y + (a[idx_last].y - a[idx_last-1].y),\n a[idx_last].z + (a[idx_last].z - a[idx_last-1].z));\n Point3D[] new_a = new Point3D[n];\n double new_seg = span/(n-1);\n for (int i = 0; i < new_a.length; i++) {\n double offs = new_seg * i;\n double y = y0 + offs;\n int prev_idx = (int)Math.floor(offs/seg);\n if (prev_idx == idx_last) { // last point\n new_a[i] = a[idx_last]; \n continue; // really a break....\n }\n Point3D p1 = a[prev_idx];\n Point3D p2 = a[prev_idx+1];\n Point3D p0 = prev_idx > 0 ? a[prev_idx-1] : bottom;\n Point3D p3 = prev_idx < idx_last-1 ? a[prev_idx+2] : top;\n double mu = (y-p1.y)/seg; /// mu spans the range of 0...1\n // double new_x = solver.LinearInterpolate(p1.x, p2.x, mu);\n double new_x = solver.CubicInterpolate(p0.x, p1.x, p2.x, p3.x, mu);\n // double new_z = solver.LinearInterpolate(p1.z, p2.z, mu);\n double new_z = solver.CubicInterpolate(p0.z, p1.z, p2.z, p3.z, mu);\n new_a[i] = new Point3D(new_x, y, new_z);\n }\n return new_a;\n }", "private GenericGridError testShipBoundaries(final ShipCommand command, GenericGridError errors){\r\n\t\tInteger xCount;\r\n\t\tInteger yCount;\r\n\t\tif(command.getIsHorizontal()){\r\n\t\t\txCount = command.getShipSize()+2;\r\n\t\t\tyCount = 3;\r\n\t\t} else{\r\n\t\t\txCount = 3;\r\n\t\t\tyCount = command.getShipSize()+2;\r\n\t\t}\r\n\t\tPoint currentPosition = command.getTile().getPosition();\r\n\t\tScanArea scanArea = new ScanArea(\r\n\t\t\t\t\t\t\tnew Point((currentPosition.x - 1), (currentPosition.y - 1)), \r\n\t\t\t\t\t\t\tnew Dimension(xCount, yCount));\r\n\t\t\r\n\t\tList<Point> positionList = scanArea.getScanAreaPositions();\r\n\t\t\r\n\t\tfor(Point position : positionList){\r\n\t\t\tAbstractTile currentTile = command.getGrid().getTile(position);\r\n\t\t\tif(AbstractShipTile.class.isInstance(currentTile)){\r\n\t\t\t\terrors.addErrorMessage(\"SHIP TILE DETECTED AT POSITION(X,Y): \" \r\n\t\t\t\t\t\t+ currentTile.getPosition().x + \", \" \r\n\t\t\t\t\t\t+ currentTile.getPosition().y \r\n\t\t\t\t\t\t+ \"\\nRULE VIOLATION: SHIPS CANNOT BE PLACED ADJACENT TO OTHER SHIPS (INCLUDING DIAGONAL)\");\r\n\t\t\t}\r\n\t\t}\t\t\r\n\t\treturn errors;\r\n\t}", "@Test\n\tpublic final void testProcGridCoord() {\n\t\tfor (int d=0; d<DIMENSIONALITY; d++) {\n\t\t\tassertTrue(0 <= block.procGridCoord(d)\n\t\t\t\t\t&& block.procGridCoord(d)<block.procGridSize(d));\n\t\t}\n\t}", "@Test\n public void test40() throws Throwable {\n CombinedRangeCategoryPlot combinedRangeCategoryPlot0 = new CombinedRangeCategoryPlot();\n combinedRangeCategoryPlot0.setRangeCrosshairVisible(true);\n combinedRangeCategoryPlot0.clearDomainMarkers();\n combinedRangeCategoryPlot0.setRangeCrosshairValue(987.458);\n Point2D.Float point2D_Float0 = new Point2D.Float();\n Line2D.Double line2D_Double0 = null;\n try {\n line2D_Double0 = new Line2D.Double((Point2D) null, (Point2D) point2D_Float0);\n } catch(NullPointerException e) {\n //\n // no message in exception (getMessage() returned null)\n //\n assertThrownBy(\"java.awt.geom.Line2D\", e);\n }\n }", "public void findLeftAndRightEdge() throws NoSudokuFoundException{\n int bestLeftHit = 0;\n int bestRightHit = 0;\n for (int v=0; v<nextV; v++) {\n int leftHit = 0;\n int rightHit = 0;\n // for every vertical line, check if horizontal edge points A B\n // are on that line.\n double[] vline = verticalLines[v];\n double vx1 = vline[0],\n vx2 = vline[2];\n for (int h=0; h<nextH; h++){\n double[] vec = horizontalLines[h];\n double ax = vec[0],\n bx = vec[2];\n if(ax < bx) { // A is left of B\n if ((vx1<=ax && ax<=vx2) || (vx1>=ax && ax>=vx2)){\n // A is between the upper and lower edge point\n if(vx1 < centerX && vx2 < centerX) {\n leftHit++;\n }\n } else if ((vx1<=bx&& bx<=vx2) || (vx1>=bx && bx>=vx2)){\n if(vx1 > centerX && vx2 > centerX) {\n rightHit++;\n }\n }\n } else {\n if ((vx1<=bx && bx<=vx2) || (vx1>=bx && bx>=vx2)){\n if(vx1 < centerX && vx2 < centerX) {\n leftHit++;\n }\n } else if ((vx1<=ax && ax<=vx2) || (vx1>=ax && ax>=vx2)){\n if(vx1 > centerX && vx2 > centerX) {\n rightHit++;\n }\n }\n }\n }\n // take the lines with the highest counts\n if(leftHit > bestLeftHit) {\n edges[3] = verticalLines[v];\n bestLeftHit = leftHit;\n } else if (rightHit > bestRightHit){\n edges[1] = verticalLines[v];\n bestRightHit = rightHit;\n }\n }\n if(bestLeftHit < LINE_THRESHOLD || bestRightHit < LINE_THRESHOLD){\n throw new NoSudokuFoundException(\"Number of left or right line ends below threshold: L\" + bestLeftHit + \" R\" + bestRightHit);\n }\n Log.v(TAG, \"Best left hit: \" + bestLeftHit + \", best right: \" + bestRightHit);\n }", "public boolean isSelfCrossing(int[] x) {\n for(int i = 0; i <= x.length - 1; i ++){\n // Case 1 where arrow i goes across arrow i - 3\n if(i >= 3 && x[i] >= x[i - 2] && x[i - 1] <= x[i - 3]) return true;\n // Case 2 where arrow i goes across arrow i - 4\n if(i >= 4 && x[i] + x[i - 4] >= x[i - 2] && x[i - 1] == x[i - 3]) return true;\n // Case 3 where arrow goes across arrow i - 5\n if(i >= 5 && x[i - 1] + x[i - 5] >= x[i - 3] && x[i] + x[i - 4] >= x[i - 2]\n && x[i - 2] >= x[i - 4] && x[i - 1] <= x[i - 3]) return true;\n }\n return false;\n }", "@Test\n public void test14() throws Throwable {\n SubCategoryAxis subCategoryAxis0 = new SubCategoryAxis((String) null);\n CombinedDomainCategoryPlot combinedDomainCategoryPlot0 = new CombinedDomainCategoryPlot((CategoryAxis) subCategoryAxis0);\n subCategoryAxis0.setPlot(combinedDomainCategoryPlot0);\n CyclicNumberAxis cyclicNumberAxis0 = new CyclicNumberAxis(2915.6662320392, 2915.6662320392, \"Null 'stroke' argument.\");\n subCategoryAxis0.setAxisLineVisible(false);\n int int0 = combinedDomainCategoryPlot0.getRangeAxisIndex(cyclicNumberAxis0);\n AxisLocation axisLocation0 = combinedDomainCategoryPlot0.getDomainAxisLocation((-1));\n combinedDomainCategoryPlot0.setDomainAxisLocation(axisLocation0, true);\n Color color0 = (Color)combinedDomainCategoryPlot0.getDomainGridlinePaint();\n // Undeclared exception!\n try { \n combinedDomainCategoryPlot0.setRangeAxis((-1), (ValueAxis) cyclicNumberAxis0, true);\n } catch(IllegalArgumentException e) {\n //\n // Requires index >= 0.\n //\n assertThrownBy(\"org.jfree.chart.util.AbstractObjectList\", e);\n }\n }", "static Boolean lineBetween(int x1, int y1, int x2, int y2) {\n double m, b; // for line eqn.\n int maxV = Math.max( pgmInf.img[y1][x1], pgmInf.img[y2][x2] );\n int xmin = Math.min(x1, x2), xmax = Math.max(x1, x2);\n int ymin = Math.min(y1, y2), ymax = Math.max(y1, y2);\n\n if (x1 == x2) {\n // x = c\n for (int y=ymin ; y < ymax ; y++)\n if (pgmInf.img[y][x1] > maxV) return false;\n }\n else {\n // setup for y=mx + b form\n double top = (y1-y2), bot = (x1-x2);\n m = top / bot; \n\n if (m > -1 && m < 1) {\n // y = mx + b\n b = y1 - m * (double)x1;\n\n for (int x=xmin ; x < xmax ; x++) {\n int y = (int)Math.round( m * (double)x + b );\n if (pgmInf.img[y][x] > maxV ) return false;\n }\n }\n else {\n // x = my + b\n top = (x1-x2); bot = (y1-y2); \n m = top / bot; b = x1 - m * (double)y1;\n\n for (int y=ymin ; y < ymax ; y++) {\n int x = (int)Math.round( m* (double)y + b );\n if (pgmInf.img[y][x] > maxV) return false;\n }\n }\n }\n return true;\n }", "private void computeXY(int x, int y){\n\n for (int x1 = x-1; x1 <= x+1; x1++) {\n for (int y1 = y-1; y1 <= y+1; y1++) {\n switch ((int)generator.cellHashes.get(ccells.cell2Hash(x1,y1))){\n case 3:\n ncells.set(x1,y1,false);\n break;\n case 1:\n ncells.set(x1,y1,true);\n break;\n case 0:\n ncells.set(x1,y1,ccells.get(x1,y1));\n break;\n }\n }\n }\n }", "boolean handleInput(float x, float y){\n return r1_.x_ <= x && r2_.x_ >= x && r1_.y_ >= y && r2_.y_ <= y;\n }", "private static boolean isValid(int x, int y)\n\t {\n\t if (x < M && y < N && x >= 0 && y >= 0) {\n\t return true;\n\t }\n\t \n\t return false;\n\t }", "private boolean checkConvexity()\r\n \t{\r\n\t\tswap(0, findLowest());\r\n\t\tArrays.sort(v, new Comparator() {\r\n\t\t\tpublic int compare(Object a, Object b)\r\n\t\t\t{\r\n\t\t\t\tint as = area_sign(v[0], (Pointd)a, (Pointd)b);\r\n\t\t\t\tif ( as > 0)\t\t/* left turn */\r\n\t\t\t\t\treturn -1;\r\n\t\t\t\telse if (as < 0)\t/* right turn */\r\n\t\t\t\t\treturn 1;\r\n\t\t\t\telse \t\t\t\t\t/* collinear */\r\n\t\t\t\t{\r\n\t\t\t\t\tdouble x = Math.abs(((Pointd)a).getx() - v[0].getx()) - Math.abs(((Pointd)b).getx() - v[0].getx());\r\n\t\t\t\t\tdouble y = Math.abs(((Pointd)a).gety() - v[0].gety()) - Math.abs(((Pointd)b).gety() - v[0].gety());\r\n\t\t\t\t\tif ( (x < 0) || (y < 0) )\r\n\t\t\t\t\t\treturn -1;\r\n\t\t\t\t\telse if ( (x > 0) || (y > 0) )\r\n\t\t\t\t\t\treturn 1;\r\n\t\t\t\t\telse\t\t// points are coincident\r\n\t\t\t\t\t\treturn 0;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t});\r\n\r\n \t\tfor (int i=0; i < nv; i++)\r\n \t\t{\r\n \t\t\ti2 = next(i, nv);\r\n \t\t\ti3 = next(i2, nv);\r\n \t\t\tif ( !lefton(\tv[i], v[i2], v[i3]) )\r\n \t\t\t\treturn false;\r\n \t\t}\r\n \t\treturn true;\r\n\t}", "@Test\n public void test29() throws Throwable {\n Line2D.Double line2D_Double0 = new Line2D.Double(536.1149799, 536.1149799, 536.1149799, 536.1149799);\n GridBagLayout gridBagLayout0 = new GridBagLayout();\n Point point0 = gridBagLayout0.location((-178), (-178));\n Point point1 = (Point)point0.clone();\n Line2D.Float line2D_Float0 = new Line2D.Float((Point2D) point0, (Point2D) point0);\n line2D_Float0.y1 = (float) (-178);\n line2D_Float0.setLine((double) 0, (double) 0, 536.1149799, 536.1149799);\n line2D_Double0.setLine((Line2D) line2D_Float0);\n Point2D.Double point2D_Double0 = (Point2D.Double)line2D_Double0.getP1();\n CategoryPlot categoryPlot0 = new CategoryPlot();\n BasicStroke basicStroke0 = (BasicStroke)categoryPlot0.getRangeCrosshairStroke();\n JFreeChart jFreeChart0 = new JFreeChart(\"4|||4=C,\", (Plot) categoryPlot0);\n ChartPanel chartPanel0 = new ChartPanel(jFreeChart0, true);\n Point2D point2D0 = chartPanel0.getAnchor();\n Line2D.Double line2D_Double1 = null;\n try {\n line2D_Double1 = new Line2D.Double((Point2D) point0, (Point2D) null);\n } catch(NullPointerException e) {\n //\n // no message in exception (getMessage() returned null)\n //\n assertThrownBy(\"java.awt.geom.Line2D\", e);\n }\n }", "private boolean overlappingGateways(BpmnShape s1, BpmnShape s2) {\n\t\tdouble firstHeight = s1.getBounds().getHeight() / 2;\n\t\tdouble firstWidth = s1.getBounds().getWidth() / 2;\n\t\tdouble firstX = s1.getBounds().getX() + firstWidth;\n\t\tdouble firstY = s1.getBounds().getY() + firstHeight;\n\t\tdouble firstApothem = (s1.getBounds().getHeight() * Math.sqrt(2)) / 2;\n\n\t\tdouble secondWidth = s2.getBounds().getWidth() / 2;\n\t\tdouble secondHeight = s2.getBounds().getHeight() / 2;\n\t\tdouble secondX = s2.getBounds().getX();\n\t\tdouble secondY = s2.getBounds().getY() + secondHeight;\n\t\tdouble secondApothem = (s2.getBounds().getHeight() * Math.sqrt(2)) / 2;\n\t\t\n\t\tif (firstX > secondX && firstY > secondY){\n\t\t\tif ((firstX - firstWidth < secondX + secondWidth && firstY - firstHeight < secondY + secondHeight) &&\n\t\t\t\t(firstX - firstApothem < secondX + secondApothem || firstY - firstApothem < secondY + secondApothem))\n\t\t\t\treturn true;\n\t\t\telse\n\t\t\t\treturn false;\n\t\t}\n\t\t\n\t\tif (firstX > secondX && firstY < secondY){\n\t\t\tif ((firstX - firstWidth < secondX + secondWidth && firstY + firstHeight > secondY - secondHeight) &&\n\t\t\t\t(firstX - firstApothem < secondX + secondApothem || firstY + firstApothem > secondY - secondApothem))\n\t\t\t\treturn true;\n\t\t\telse\n\t\t\t\treturn false;\n\t\t}\n\t\t\n\t\tif (firstX < secondX && firstY > secondY){\n\t\t\tif ((firstX + firstWidth > secondX - secondWidth && firstY - firstHeight < secondY + secondHeight) &&\n\t\t\t\t(firstX + firstApothem > secondX - secondApothem || firstY - firstApothem < secondY + secondApothem))\n\t\t\t\treturn true;\n\t\t\telse\n\t\t\t\treturn false;\n\t\t}\n\t\t\n\t\tif (firstX < secondX && firstY < secondY){\n\t\t\tif ((firstX - firstWidth < secondX + secondWidth && firstY + firstHeight > secondY - secondHeight) &&\n\t\t\t\t(firstX - firstApothem < secondX + secondApothem || firstY + firstApothem > secondY - secondApothem))\n\t\t\t\treturn true;\n\t\t\telse\n\t\t\t\treturn false;\n\t\t}\n\t\t\n\t\tif (firstX == secondX && firstY == secondY)\n\t\t\t\treturn true;\n\t\t\n\t\tif (firstX == secondX && firstY > secondY){\n\t\t\tif (firstY - firstHeight < secondY + secondHeight)\n\t\t\t\treturn true;\n\t\t\telse\n\t\t\t\treturn false;\n\t\t}\n\t\t\n\t\tif (firstX > secondX && firstY == secondY){\n\t\t\tif (firstX - firstWidth < secondX + secondWidth)\n\t\t\t\treturn true;\n\t\t\telse\n\t\t\t\treturn false;\n\t\t}\n\t\t\n\t\tif (firstX == secondX && firstY < secondY){\n\t\t\tif (firstY + firstHeight > secondY - secondHeight)\n\t\t\t\treturn true;\n\t\t\telse\n\t\t\t\treturn false;\n\t\t}\n\t\t\n\t\tif (firstX < secondX && firstY == secondY){\n\t\t\tif (firstX + firstWidth > secondX - secondWidth)\n\t\t\t\treturn true;\n\t\t\telse\n\t\t\t\treturn false;\n\t\t}\n\t\treturn false;\n\t}", "boolean judgeValid()\r\n\t{\r\n\t\tif(loc.i>=0 && loc.i<80 && loc.j>=0 && loc.j<80 && des.i>=0 && des.i<80 && des.j>=0 && des.j<80)\r\n\t\t{\r\n\t\t\treturn true;\r\n\t\t}\r\n\t\treturn false;\r\n\t\t\r\n\t}", "private void checkNeqContradictions(HashMap<ComparableExpression, HashSet<ComparableExpression>> cNeq,\n HashMap<TimeSelector, Long> lowerBounds,\n HashMap<TimeSelector, Long> upperBounds)\n throws QueryContradictoryException {\n ArrayList<ArrayList<ComparableExpression>> neq = relationToTuples(cNeq);\n for (ArrayList<ComparableExpression> tuple : neq) {\n if (tuple.get(0) instanceof TimeSelector) {\n TimeSelector sel = (TimeSelector) tuple.get(0);\n // if lower(sel)!=upper(sel), no constraint sel!=x is contradictory\n if (!lowerBounds.get(sel).equals(upperBounds.get(sel))) {\n return;\n }\n // selector1 != selector2 only contradictory if both selectors have the same fixed value\n // (lower(selector1)=upper(selector1)=lower(selector2)=upper(selector2)\n if (tuple.get(1) instanceof TimeSelector) {\n TimeSelector sel2 = (TimeSelector) tuple.get(1);\n if (lowerBounds.get(sel).equals(lowerBounds.get(sel2)) &&\n lowerBounds.get(sel2).equals(upperBounds.get(sel2))) {\n throw new QueryContradictoryException();\n } // selector != literal only contradictory if lower(selector)=upper(selector)=literal\n } else if (tuple.get(1) instanceof TimeLiteral) {\n Long literalValue = ((TimeLiteral) tuple.get(1)).getMilliseconds();\n if (lowerBounds.get(sel).equals(literalValue)) {\n throw new QueryContradictoryException();\n }\n }\n } else if (tuple.get(0) instanceof TimeLiteral && tuple.get(1) instanceof TimeSelector) {\n // selector != literal only contradictory if lower(selector)=upper(selector)=literal\n TimeSelector sel = (TimeSelector) tuple.get(1);\n Long literalValue = ((TimeLiteral) tuple.get(0)).getMilliseconds();\n if (lowerBounds.get(sel).equals(upperBounds.get(sel)) && lowerBounds.get(sel).equals(literalValue)) {\n throw new QueryContradictoryException();\n }\n }\n }\n }", "public boolean checkUpDown() {\r\n\t\tif (p1[0] + p1[3] + p1[6] == 15)\r\n\t\t\treturn true;\r\n\t\telse if (p1[1] + p1[4] + p1[7] == 15)\r\n\t\t\treturn true;\r\n\t\telse if (p1[2] + p1[5] + p1[8] == 15)\r\n\t\t\treturn true;\r\n\t\telse if (p2[0] + p2[3] + p2[6] == 15)\r\n\t\t\treturn true;\r\n\t\telse if (p2[1] + p2[4] + p2[7] == 15)\r\n\t\t\treturn true;\r\n\t\telse if (p2[2] + p2[5] + p2[8] == 15)\r\n\t\t\treturn true;\r\n\r\n\t\treturn false;\r\n\t}", "@Override\n public double at(double x, boolean increasing) {\n\n /** Handle the boundary cases. */\n final int n = ctrlX.length;\n if (Double.isNaN(x) || ctrlX == null || ctrlY == null) {\n return x;\n }\n if (ctrlX.length == 1) {\n return ctrlY[0];\n }\n if (x <= ctrlX[0]) {\n return ctrlY[0];\n }\n if (x >= ctrlX[n - 1]) {\n return ctrlY[n - 1];\n }\n\n /*\n * Finds the index 'i' of the last point with smaller X. We know this\n * will be within the spline due to the boundary tests.\n */\n\n int i = 0;\n while (x >= ctrlX[i + 1]) {\n i += 1;\n if (x == ctrlX[i]) {\n return ctrlY[i];\n }\n }\n\n /* Performs cubic Hermite spline interpolation. */\n double h = ctrlX[i + 1] - ctrlX[i];\n double t = (x - ctrlX[i]) / h;\n\n double yOut = (ctrlY[i] * (1 + 2 * t) + h * mm[i] * t) * (1 - t)\n * (1 - t)\n + (ctrlY[i + 1] * (3 - 2 * t) + h * mm[i + 1] * (t - 1)) * t\n * t;\n\n /* Correction and restriction */\n int k = 0;\n for (k = 1; k < ctrlX.length; k++) {\n if (x <= ctrlX[k]) {\n break;\n }\n }\n if (increasing && yOut > ctrlY[k]) {\n yOut = ctrlY[k];\n }\n return yOut;\n }", "private boolean locateSafety(String[] coord) {\n\n int[] indices = getIndexFromCoord(coord);\n int x0 = indices[0];\n int y0 = indices[1];\n int x1 = indices[2];\n int y1 = indices[3];\n\n\n if (x0 == x1) {\n // horizontal\n int northIndex = x0 > 0 ? x0 - 1 : -1;\n int southIndex = x0 < Row.values().length - 1 ? x0 + 1 : -1;\n int leftIndex = y0 > 0 ? y0 - 1 : -1;\n int rightIndex = y1 < fields.length - 1 ? y1 + 1 : -1;\n // check north area\n if (northIndex != -1) {\n for (int i = y0; i <= y1; i++) {\n if (fields[northIndex][i].isShip()) {\n System.out.println(\"Error! You placed it too close to another one. Try again:\");\n return false;\n }\n }\n }\n // check south area\n if (southIndex != -1) {\n for (int i = y0; i <= y1; i++) {\n if (fields[southIndex][i].isShip()) {\n System.out.println(\"Error! You placed it too close to another one. Try again:\");\n return false;\n }\n }\n }\n // check left\n if (leftIndex != -1 && fields[x0][leftIndex].isShip()) {\n System.out.println(\"Error! You placed it too close to another one. Try again:\");\n return false;\n }\n // check right\n if (rightIndex != -1 && fields[x0][rightIndex].isShip()) {\n System.out.println(\"Error! You placed it too close to another one. Try again:\");\n return false;\n }\n\n } else {\n // vertical\n int leftCol = y0 > 0 ? y0 - 1 : -1;\n int rightCol = y0 < fields.length - 1 ? y0 + 1 : -1;\n int northIndex = x0 > 0 ? x0 - 1 : -1;\n int southIndex = x1 < Row.values().length -1 ? x1 + 1 : -1;\n\n // check north\n if (northIndex != -1 && fields[northIndex][y0].isShip()) {\n System.out.println(\"Error! You placed it too close to another one. Try again:\");\n return false;\n }\n // check south\n if (southIndex != -1 && fields[southIndex][y0].isShip()) {\n System.out.println(\"Error! You placed it too close to another one. Try again:\");\n return false;\n }\n // check left\n if (leftCol != -1) {\n for (int i = x0; i <= x1; i++) {\n if (fields[i][leftCol].isShip()) {\n System.out.println(\"Error! You placed it too close to another one. Try again:\");\n return false;\n }\n }\n }\n // check right\n if (rightCol != -1) {\n for (int i = x0; i <= x1; i++) {\n if (fields[i][rightCol].isShip()) {\n System.out.println(\"Error! You placed it too close to another one. Try again:\");\n return false;\n }\n }\n }\n }\n return true;\n }", "private int inRange(int x, int y) {\n\t\tif (x > 3 && y > 3 && x < max_x - 3 && y < max_y - 3) {\n\t\t\treturn 1;\n\t\t} else {\n\t\t\treturn 0;\n\t\t}\n\t}", "private void checkRep() {\n for (Ball ball : balls) {\n assert ball.getPosition().d1 >= 0\n && ball.getPosition().d1 <= WIDTH - 1;\n assert ball.getPosition().d2 >= 0\n && ball.getPosition().d2 <= HEIGHT - 1;\n }\n for (Gadget gadget : gadgets) {\n assert gadget.getPosition().d1 >= 0\n && gadget.getPosition().d1 <= WIDTH - 1;\n assert gadget.getPosition().d2 >= 0\n && gadget.getPosition().d2 <= HEIGHT - 1;\n }\n\n assert GRAVITY > 0 && MU2 > 0 && MU > 0;\n }", "@Test\n public void test48() throws Throwable {\n Rectangle2D.Double rectangle2D_Double0 = new Rectangle2D.Double();\n Rectangle2D.Double rectangle2D_Double1 = (Rectangle2D.Double)rectangle2D_Double0.getBounds2D();\n CombinedRangeCategoryPlot combinedRangeCategoryPlot0 = new CombinedRangeCategoryPlot((ValueAxis) null);\n AxisLocation axisLocation0 = combinedRangeCategoryPlot0.getRangeAxisLocation();\n combinedRangeCategoryPlot0.setDomainAxisLocation(axisLocation0);\n Layer layer0 = Layer.BACKGROUND;\n Collection collection0 = combinedRangeCategoryPlot0.getRangeMarkers(layer0);\n SortOrder sortOrder0 = combinedRangeCategoryPlot0.getColumnRenderingOrder();\n ChartRenderingInfo chartRenderingInfo0 = new ChartRenderingInfo();\n PlotRenderingInfo plotRenderingInfo0 = chartRenderingInfo0.getPlotInfo();\n // Undeclared exception!\n try { \n plotRenderingInfo0.getSubplotInfo(2029);\n } catch(IndexOutOfBoundsException e) {\n //\n // Index: 2029, Size: 0\n //\n assertThrownBy(\"java.util.ArrayList\", e);\n }\n }", "protected void calcMinMax() {\n }", "public void checkLines() {\n int cont2 = 0;\n int cont3, cont4;\n int casillasVacias;\n int vInicial, vFinal;\n\n for(cont3=20; cont3>0; cont3--) {\n vInicial = cont3*12 + 1;\n vFinal = vInicial + 10;\n casillasVacias = 10;\n\n //Bucle para todas las casillas de una fila\n for(cont4=vInicial; cont4<vFinal; cont4++) {\n if(colMatrix[cont4]) casillasVacias--;\n }\n\n if(casillasVacias == 0) {\n completeLines[cont2] = cont3;\n cont2++;\n }\n }\n removeLines();\n }", "public static void main(String[] args) {\n Scanner sc = new Scanner(System.in); \n int n = sc.nextInt();\n int[] array = new int[n];\n for(int i = 0;i < n; i++) {\n array[i] = sc.nextInt();\n }\n sc.close();\n \n int start = -1, end = -1;\n int misplaced = 0;\n \n for(int i = 0; i < n - 1; i++) {\n if(array[i] > array[i + 1]) {\n misplaced++;\n if(start < 0) {\n start = i;\n }\n }\n }\n \n for(int i = n - 1; i > 0; i--) {\n if(array[i] < array[i-1]) {\n end = i;\n break;\n }\n }\n \n if(misplaced < 1) {\n System.out.println(\"no\");\n return;\n }\n else if(misplaced == 1 || misplaced == 2) {\n if(misplaced == 1) //case where two neighbors swap themselves\n end = start + 1;\n boolean leftValidator = (start == 0 || array[end] >= array[start - 1]) && array[end] <= array[start + 1];\n boolean rightValidator = \n (end == n - 1 || array[start] <= array[end + 1]) && array[start] >= array[end -1];\n if(leftValidator && rightValidator) {\n System.out.println(\"yes\");\n System.out.println(\"swap \"+(start+1)+\" \"+(end+1));\n }\n else{\n System.out.println(\"no\");\n }\n return;\n }\n else{\n boolean leftValidator = start == 0 || array[end] >= array[start - 1];\n boolean rightValidator = end == n -1 || array[start] <= array[end + 1];\n if(!leftValidator || !rightValidator){\n System.out.println(\"no\");\n return;\n }\n int pre = array[end];\n for(int i = end - 1; i >= start; i--) {\n if(array[i] < pre) {\n System.out.println(\"no\");\n return;\n }\n pre = array[i];\n }\n \n System.out.println(\"yes\");\n System.out.println(\"reverse \"+(start+1)+\" \"+(end+1));\n }\n \n /**\n //I am such an idot cause I first understood the question wrongly\n //If the array was supposed to be consecutively ascending order, then the code below would've worked\n \n int min = Integer.MAX_VALUE;\n int start = -1, end = -1;\n int left = 0, right = n - 1;\n int misplaced = 0;\n \n for(int i : array) { //find the min value\n min = Math.min(min, i);\n }\n \n while(left <= right) { //find how many elements are misplaced and the index of first misplaced element\n if(array[left] != min + left) { //and the index of the last misplaced element\n misplaced++;\n if(start < 0) {\n start = left;\n }\n }\n left++;\n if(left <= right && array[right] != min + right) { //left != right for the case where the array is odd\n misplaced++;\n if(end < 0) {\n end = right;\n }\n }\n right--;\n }\n \n if(misplaced < 2) {\n System.out.println(\"no\");\n return;\n }\n else if(misplaced == 2) {\n if(min + start == array[end] && min + end == array[start]) {\n System.out.println(\"yes\");\n System.out.println(\"swap \"+(start+1)+\" \"+(end+1));\n }\n else{\n System.out.println(\"no\");\n }\n return;\n }\n else{\n for(int i = start, j = 0; i <= end; i++, j++) {\n if(array[i] != min + end - j) {\n System.out.println(\"no\");\n return;\n }\n }\n \n System.out.println(\"yes\");\n System.out.println(\"reverse \"+(start+1)+\" \"+(end+1));\n }\n **/\n \n }", "@Test\n public void test77() throws Throwable {\n CombinedDomainCategoryPlot combinedDomainCategoryPlot0 = new CombinedDomainCategoryPlot((CategoryAxis) null);\n combinedDomainCategoryPlot0.setDrawSharedDomainAxis(false);\n DecimalFormat decimalFormat0 = (DecimalFormat)NumberFormat.getCurrencyInstance();\n NumberTickUnit numberTickUnit0 = new NumberTickUnit((-28.552), (NumberFormat) decimalFormat0);\n Color color0 = (Color)Axis.DEFAULT_TICK_MARK_PAINT;\n boolean boolean0 = numberTickUnit0.equals((Object) null);\n TimeTableXYDataset timeTableXYDataset0 = new TimeTableXYDataset();\n RectangleEdge rectangleEdge0 = combinedDomainCategoryPlot0.getDomainAxisEdge();\n CyclicNumberAxis cyclicNumberAxis0 = new CyclicNumberAxis(0.0, 0.0);\n XYAreaRenderer2 xYAreaRenderer2_0 = new XYAreaRenderer2();\n XYPlot xYPlot0 = new XYPlot((XYDataset) timeTableXYDataset0, (ValueAxis) cyclicNumberAxis0, (ValueAxis) cyclicNumberAxis0, (XYItemRenderer) xYAreaRenderer2_0);\n BasicStroke basicStroke0 = (BasicStroke)xYPlot0.getRangeZeroBaselineStroke();\n CategoryMarker categoryMarker0 = new CategoryMarker((Comparable) numberTickUnit0, (Paint) color0, (Stroke) basicStroke0, (Paint) color0, cyclicNumberAxis0.DEFAULT_ADVANCE_LINE_STROKE, 0.85F);\n combinedDomainCategoryPlot0.addRangeMarker((Marker) categoryMarker0);\n int int0 = combinedDomainCategoryPlot0.getRangeAxisIndex(cyclicNumberAxis0);\n Layer layer0 = Layer.BACKGROUND;\n combinedDomainCategoryPlot0.addDomainMarker(0, categoryMarker0, layer0);\n combinedDomainCategoryPlot0.setRenderer((CategoryItemRenderer) null);\n boolean boolean1 = combinedDomainCategoryPlot0.isRangeZoomable();\n Point2D.Double point2D_Double0 = new Point2D.Double((-862.0), 1.0E-6);\n point2D_Double0.y = (double) 0;\n AxisLocation axisLocation0 = combinedDomainCategoryPlot0.getDomainAxisLocation((-2040));\n combinedDomainCategoryPlot0.setDomainAxisLocation(axisLocation0);\n }", "public static boolean checkCollinearUsingSlope(int x1, int y1, int x2, int y2, int x3, int y3) {\r\n\t\tdouble slopeAB, slopeBC, slopeAC;\r\n\t\tslopeAB = (y2 - y1) / (x2 - x1);\r\n\t\tslopeBC = (y3 - y2) / (x3 - x2);\r\n\t\tslopeAC = (y3 - y1) / (x3 - x1);\r\n\t\tif (slopeAB == slopeBC) {\r\n\t\t\tif (slopeAB == slopeAC) {\r\n\t\t\t\treturn true;\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn false;\r\n\t}", "public boolean checkAcross() {\r\n\t\tif (p1[0] + p1[1] + p1[2] == 15)\r\n\t\t\treturn true;\r\n\t\telse if (p1[3] + p1[4] + p1[5] == 15)\r\n\t\t\treturn true;\r\n\t\telse if (p1[6] + p1[7] + p1[8] == 15)\r\n\t\t\treturn true;\r\n\t\telse if (p2[0] + p2[1] + p2[2] == 15)\r\n\t\t\treturn true;\r\n\t\telse if (p2[3] + p2[4] + p2[5] == 15)\r\n\t\t\treturn true;\r\n\t\telse if (p2[6] + p2[7] + p2[8] == 15)\r\n\t\t\treturn true;\r\n\r\n\t\treturn false;\r\n\t}", "@Override protected void updateAxisRange() {\n final Axis<X> xa = getXAxis();\n final Axis<Y> ya = getYAxis();\n List<X> xData = null;\n List<Y> yData = null;\n if(xa.isAutoRanging()) xData = new ArrayList<X>();\n if(ya.isAutoRanging()) yData = new ArrayList<Y>();\n if(xData != null || yData != null) {\n for(Series<X,Y> series : getData()) {\n for(Data<X,Y> data: series.getData()) {\n if(xData != null) {\n xData.add(data.getXValue());\n xData.add(xa.toRealValue(xa.toNumericValue(data.getXValue()) + getLength(data.getExtraValue())));\n }\n if(yData != null){\n yData.add(data.getYValue());\n }\n }\n }\n if(xData != null) xa.invalidateRange(xData);\n if(yData != null) ya.invalidateRange(yData);\n }\n }", "@Test\n public void test72() throws Throwable {\n CombinedRangeCategoryPlot combinedRangeCategoryPlot0 = new CombinedRangeCategoryPlot();\n combinedRangeCategoryPlot0.mapDatasetToDomainAxis(304, 908);\n Point2D.Double point2D_Double0 = new Point2D.Double((double) 304, (double) 908);\n AxisLocation axisLocation0 = AxisLocation.TOP_OR_LEFT;\n combinedRangeCategoryPlot0.setRangeAxisLocation(908, axisLocation0);\n CategoryAxis3D categoryAxis3D0 = new CategoryAxis3D(\"org.jfree.chart.annotations.XYBoxAnnotation\");\n combinedRangeCategoryPlot0.setDomainAxis((CategoryAxis) categoryAxis3D0);\n point2D_Double0.x = 4978.54542523173;\n String string0 = combinedRangeCategoryPlot0.getPlotType();\n ValueAxis[] valueAxisArray0 = new ValueAxis[6];\n DateAxis dateAxis0 = new DateAxis(\"org.jfree.chart.annotations.XYBoxAnnotation\");\n valueAxisArray0[0] = (ValueAxis) dateAxis0;\n CyclicNumberAxis cyclicNumberAxis0 = new CyclicNumberAxis((-1.0), (double) 304);\n valueAxisArray0[1] = (ValueAxis) cyclicNumberAxis0;\n NumberAxis numberAxis0 = new NumberAxis(\"z)m!{V![\");\n valueAxisArray0[2] = (ValueAxis) numberAxis0;\n SimpleDateFormat simpleDateFormat0 = (SimpleDateFormat)DateFormat.getInstance();\n ZoneInfo zoneInfo0 = (ZoneInfo)simpleDateFormat0.getTimeZone();\n DateAxis dateAxis1 = new DateAxis(\"org.jfree.chart.annotations.XYBoxAnnotation\", (TimeZone) zoneInfo0);\n valueAxisArray0[3] = (ValueAxis) dateAxis1;\n DefaultValueDataset defaultValueDataset0 = new DefaultValueDataset();\n ThermometerPlot thermometerPlot0 = new ThermometerPlot((ValueDataset) defaultValueDataset0);\n NumberAxis numberAxis1 = (NumberAxis)thermometerPlot0.getRangeAxis();\n valueAxisArray0[4] = (ValueAxis) numberAxis1;\n String[] stringArray0 = new String[7];\n stringArray0[0] = \"z)m!{V![\";\n stringArray0[1] = \"\";\n stringArray0[2] = \"%}~t|T'c.q2O/M@;Vu5\";\n stringArray0[3] = \"?_t}%h[qlt\";\n stringArray0[4] = \"z)m!{V![\";\n stringArray0[5] = \"z)m!{V![\";\n stringArray0[6] = \"d*%)TD6zCx!%m^]|\";\n }", "protected boolean checkRep() {\n if ( this.getX() < 0 || this.getY() < 0 || this.getX() >= 20 || this.getY() >= 20 ) {\n return false;\n }\n return true;\n }", "@Test\n public void test43() throws Throwable {\n DateAxis dateAxis0 = new DateAxis();\n CombinedRangeCategoryPlot combinedRangeCategoryPlot0 = new CombinedRangeCategoryPlot((ValueAxis) dateAxis0);\n dateAxis0.setLabelToolTip(\"Null 'order' argument.\");\n int int0 = combinedRangeCategoryPlot0.getRangeAxisIndex(dateAxis0);\n combinedRangeCategoryPlot0.mapDatasetToRangeAxis(2758, 2758);\n Point2D.Double point2D_Double0 = new Point2D.Double((double) 2758, (double) 0);\n String string0 = point2D_Double0.toString();\n }", "@Test\n public void test34() throws Throwable {\n CombinedRangeCategoryPlot combinedRangeCategoryPlot0 = new CombinedRangeCategoryPlot();\n DefaultPieDataset defaultPieDataset0 = new DefaultPieDataset();\n RingPlot ringPlot0 = new RingPlot((PieDataset) defaultPieDataset0);\n Second second0 = new Second();\n Second second1 = (Second)second0.next();\n defaultPieDataset0.setValue((Comparable) second1, (Number) null);\n Comparable comparable0 = ringPlot0.getSectionKey(0);\n CategoryMarker categoryMarker0 = new CategoryMarker(comparable0);\n Layer layer0 = Layer.BACKGROUND;\n combinedRangeCategoryPlot0.addDomainMarker(75, categoryMarker0, layer0);\n Layer layer1 = Layer.BACKGROUND;\n Collection collection0 = combinedRangeCategoryPlot0.getDomainMarkers((-1), layer1);\n boolean boolean0 = combinedRangeCategoryPlot0.isRangeZoomable();\n combinedRangeCategoryPlot0.clearDomainMarkers();\n Point2D.Double point2D_Double0 = new Point2D.Double();\n point2D_Double0.x = (double) (-1);\n double double0 = point2D_Double0.y;\n combinedRangeCategoryPlot0.clearRangeAxes();\n combinedRangeCategoryPlot0.setDomainGridlinesVisible(false);\n CategoryAnchor categoryAnchor0 = combinedRangeCategoryPlot0.getDomainGridlinePosition();\n Rectangle2D.Double rectangle2D_Double0 = new Rectangle2D.Double();\n int int0 = rectangle2D_Double0.outcode(4.0, (double) 0);\n boolean boolean1 = combinedRangeCategoryPlot0.isRangeGridlinesVisible();\n XYSplineAndShapeRenderer xYSplineAndShapeRenderer0 = new XYSplineAndShapeRenderer();\n BasicStroke basicStroke0 = (BasicStroke)xYSplineAndShapeRenderer0.getItemOutlineStroke(120, 15);\n combinedRangeCategoryPlot0.setRangeGridlineStroke(basicStroke0);\n }", "boolean hasXYPairs();", "public boolean isValid(int x, int y)\n\t{\n\t\treturn (x < rowLen && y < columnLen && x >= 0 && y >= 0);\n\t}", "private boolean canCaptureSomewhere(int x, int y){\n\t\tfor (int i = -2; i <= 2; i=i+4){\n\t\t\tfor (int j = -2; j <= 2; j=j+4){\n\t\t\t\tif (!(x+i < 0 || x+i > N\t\t\n\t\t\t\t|| y+j < 0 || y+j > N)){\t\t//don't give validMove impossible final coordinates\n\t\t\t\t\tif (validMove(x, y, x+i, y+j)) return true;\t\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn false;\n\t}", "public void checkRep() {\n assert(wall.p1().x() >= BOARD_MIN_BOUND && wall.p1().x() <= BOARD_MAX_BOUND) :\n \"x coordinate of p1 must be within in the board\";\n assert(wall.p2().x() >= BOARD_MIN_BOUND && wall.p2().x() <= BOARD_MAX_BOUND) :\n \"x coordinate of p2 must be within in the board\";\n assert(wall.p1().y() >= BOARD_MIN_BOUND && wall.p1().y() <= BOARD_MAX_BOUND) :\n \"y coordinate of p1 must be within in the board\";\n assert(wall.p2().y() >= BOARD_MIN_BOUND && wall.p2().y() <= BOARD_MAX_BOUND) :\n \"y coordinate of p2 must be within in the board\";\n }", "private void interpolateIfNeeded(TimeSeries data, SparklineValues.SparklineValue value, SparklineValues.SparklineValue nextValue, List<SparkLinePlotBand> plotBands) {\n if (nextValue != null && value.getValue() != null && nextValue.getValue() != null) {\n long x1 = value.getInstant().toEpochMilli();\n long x2 = nextValue.getInstant().toEpochMilli();\n double y1 = value.getValue();\n double y2 = nextValue.getValue();\n\n double delta = (maxY - minY) / 100.0;\n\n for (SparkLinePlotBand plotBand : plotBands) {\n double from = plotBand.getFromValue();\n double to = plotBand.getToValue();\n\n if (from >= y1 && from < y2) {\n addInterpolatedItem(data, x1, x2, y1, y2, from - delta);\n addInterpolatedItem(data, x1, x2, y1, y2, from + delta);\n }\n if (to >= y1 && to < y2) {\n addInterpolatedItem(data, x1, x2, y1, y2, to - delta);\n addInterpolatedItem(data, x1, x2, y1, y2, to + delta);\n }\n if (from <= y1 && from > y2) {\n addInterpolatedItem(data, x1, x2, y1, y2, from - delta);\n addInterpolatedItem(data, x1, x2, y1, y2, from + delta);\n }\n if (to <= y1 && to > y2) {\n addInterpolatedItem(data, x1, x2, y1, y2, to - delta);\n addInterpolatedItem(data, x1, x2, y1, y2, to + delta);\n }\n }\n }\n }", "private void readXY(Variable v2, int ensIdx, int timeIdx, int levIdx, Range yRange, Range xRange, IndexIterator ii)\n throws IOException {\n\n dataFile = getDataFile(ensIdx, timeIdx);\n List<GradsVariable> vars = gradsDDF.getVariables();\n // if it's an ensemble template, then all data is in this file\n int numEns = ((gradsDDF.getTemplateType() == GradsDataDescriptorFile.ENS_TEMPLATE)\n || (gradsDDF.getTemplateType() == GradsDataDescriptorFile.ENS_TIME_TEMPLATE)) ? 0 : ensIdx;\n // if it's a time template figure out how many previous times we should use\n int numTimes = gradsDDF.getTimeDimension().getSize();\n if ((gradsDDF.getTemplateType() == GradsDataDescriptorFile.TIME_TEMPLATE)\n || (gradsDDF.getTemplateType() == GradsDataDescriptorFile.ENS_TIME_TEMPLATE)) {\n int[] tpf = gradsDDF.getTimeStepsPerFile(dataFile.getLocation());\n numTimes = tpf[0];\n timeIdx = (timeIdx - tpf[1]) % numTimes;\n }\n int gridNum = numEns * numTimes * gradsDDF.getGridsPerTimeStep();\n // loop up to the last time in the last ensemble\n for (int t = 0; t < timeIdx; t++) {\n for (GradsVariable var : vars) {\n int numVLevels = var.getNumLevels();\n if (numVLevels == 0) {\n numVLevels = 1;\n }\n for (int l = 0; l < numVLevels; l++) {\n gridNum++;\n }\n }\n }\n // loop up to the last level in the last time in the last ensemble\n for (GradsVariable var : vars) {\n int numVLevels = var.getNumLevels();\n if (numVLevels == 0) {\n numVLevels = 1;\n }\n if (var.getName().equals(v2.getFullName())) {\n gridNum += levIdx;\n\n break;\n }\n for (int l = 0; l < numVLevels; l++) {\n gridNum++;\n }\n }\n\n // TODO: Flip grid if Y is reversed\n float[] data = readGrid(gridNum);\n\n // LOOK can improve with System.copy ??\n for (int y : yRange)\n for (int x : xRange)\n ii.setFloatNext(data[y * sizeX + x]);\n }", "public void errode(int x, int y, int[] inputMap, int[] errosionMap) {\n\t\tif (marked(errosionMap[width * y + x])) {\n\t\t\t// System.out.println(\"Attempted to errode a marked location : \" + x\n\t\t\t// + \" , \" + y);\n\t\t\treturn;\n\t\t}\n\n\t\t// Errode everypoint by at least one\n\t\terrosionMap[width * y + x] += 0xffff;\n\n\t\tint lowX = 0;\n\t\tint lowY = 0;\n\n\t\t// Its a grid ie :\n\t\t// -1,-1 -1,0 -1,1\n\t\t// 0,-1 0,0 0,1\n\t\t// 1,-1 1,0 1,1\n\n\t\tint tempHeight = inputMap[width * y + x];\n\n\t\t// Find lowest value of neighbors\n\t\tfor (int i = -1; i < 2; i++) {\n\t\t\tfor (int k = -1; k < 2; k++) {\n\n\t\t\t\tif (i == 0 && k == 0) {\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\n\t\t\t\tif (inArray(x + i, y + k)) {\n\t\t\t\t\t// System.out.println(\"Check \" + tempHeight + \" vs \" +\n\t\t\t\t\t// inputMap[width * (y + k) + (x + i)]);\n\t\t\t\t\tif (tempHeight > inputMap[width * (y + k) + (x + i)]) {\n\t\t\t\t\t\tlowX = i;\n\t\t\t\t\t\tlowY = k;\n\t\t\t\t\t\ttempHeight = inputMap[width * (y + k) + (x + i)];\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t}\n\t\t}\n\n\t\tint currentHeight = inputMap[width * y + x];\n\n\t\t// If the lowest point is the current point, then errosion is done\n\t\tif (lowX == 0 && lowY == 0) {\n\t\t\treturn;\n\t\t} else {\n\t\t\t// Find all points that are lower next to the origin point\n\t\t\t// And not marked\n\t\t\terrosionMap[width * (y + lowY) + (x + lowX)] += errosionMap[width\n\t\t\t\t\t* y + x];\n\t\t\t\n\t\t\t//errosionMap[width * (y + lowY) + (x + lowX)] = _\t\n\n\t\t\terrosionMap[width * y + x] = mark(errosionMap[width * y + x]);\n\t\t\tfor (int i = -1; i < 2; i++) {\n\t\t\t\tfor (int k = -1; k < 2; k++) {\n\n\t\t\t\t\tif (i == 0 && k == 0) {\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\n\t\t\t\t\tif (inArray(x + i, y + k)) {\n\t\t\t\t\t\t// System.out.println(\"X : \" + x + \" Y : \" + y + \" i:k \"\n\t\t\t\t\t\t// + i +\":\" + k);\n\t\t\t\t\t\t// System.out.println(\"Check \" + currentHeight + \" vs \"\n\t\t\t\t\t\t// + inputMap[width * (y + k) + (x + i)]);\n\t\t\t\t\t\tif (currentHeight > inputMap[width * (y + k) + (x + i)]) {\n\t\t\t\t\t\t/*\tSystem.out.println(\"Going to position : \"\n\t\t\t\t\t\t\t\t\t+ (x + i)\n\t\t\t\t\t\t\t\t\t+ \" , \"\n\t\t\t\t\t\t\t\t\t+ (y + k)\n\t\t\t\t\t\t\t\t\t+ \" Height diff = \"\n\t\t\t\t\t\t\t\t\t+ (currentHeight - inputMap[width * (y + k)\n\t\t\t\t\t\t\t\t\t\t\t+ (x + i)])); */\n\t\t\t\t\t\t\terrode(x + i, y + k, inputMap, errosionMap);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t}", "@Test\n public void test32() throws Throwable {\n CyclicNumberAxis cyclicNumberAxis0 = new CyclicNumberAxis((-1505.20649), \"Category_Plot\");\n CombinedRangeCategoryPlot combinedRangeCategoryPlot0 = new CombinedRangeCategoryPlot((ValueAxis) cyclicNumberAxis0);\n SystemColor systemColor0 = SystemColor.text;\n BasicStroke basicStroke0 = (BasicStroke)CategoryPlot.DEFAULT_GRIDLINE_STROKE;\n ValueMarker valueMarker0 = new ValueMarker(4.0, (Paint) systemColor0, (Stroke) basicStroke0);\n MarkerChangeEvent markerChangeEvent0 = new MarkerChangeEvent((Marker) valueMarker0);\n combinedRangeCategoryPlot0.markerChanged(markerChangeEvent0);\n combinedRangeCategoryPlot0.setAnchorValue(1401.824847306, false);\n CategoryAxis categoryAxis0 = new CategoryAxis(\"Category_Plot\");\n combinedRangeCategoryPlot0.setDomainAxis(categoryAxis0);\n // Undeclared exception!\n try { \n combinedRangeCategoryPlot0.setDataset((-1030), (CategoryDataset) null);\n } catch(IllegalArgumentException e) {\n //\n // Requires index >= 0.\n //\n assertThrownBy(\"org.jfree.chart.util.AbstractObjectList\", e);\n }\n }" ]
[ "0.5620912", "0.5417902", "0.53995097", "0.5384295", "0.5382468", "0.53710014", "0.5317418", "0.5315966", "0.5291393", "0.52699834", "0.5264456", "0.5243765", "0.5231732", "0.52297544", "0.5221148", "0.5211031", "0.5169379", "0.5144097", "0.51315385", "0.5120747", "0.51160085", "0.5105041", "0.5078913", "0.5076338", "0.5060266", "0.50501466", "0.5049047", "0.5046074", "0.50422525", "0.50361305", "0.50127774", "0.5005604", "0.5001108", "0.49909547", "0.4986445", "0.49638245", "0.49319834", "0.49190548", "0.4918114", "0.49094978", "0.4897851", "0.4878989", "0.48747337", "0.48728612", "0.48686284", "0.48632202", "0.48591328", "0.48445848", "0.48326215", "0.48266217", "0.48189855", "0.48171496", "0.4805119", "0.480424", "0.4803219", "0.47989872", "0.47948983", "0.47872368", "0.4787075", "0.47854918", "0.4783806", "0.47818828", "0.47818288", "0.47773483", "0.4777273", "0.47771668", "0.47752157", "0.47713494", "0.47672218", "0.47666806", "0.47657266", "0.4763782", "0.4763269", "0.4761472", "0.4761402", "0.47595713", "0.4750155", "0.47446814", "0.47393817", "0.47355247", "0.47326833", "0.47278723", "0.47261673", "0.47171235", "0.47072026", "0.47054654", "0.47028568", "0.46993005", "0.46979466", "0.46978796", "0.46976277", "0.46935388", "0.46917257", "0.4691054", "0.4690816", "0.46846345", "0.4682686", "0.46812636", "0.46798867", "0.46795076" ]
0.676416
0
Complete the code, handle possible exception
public static void main(String[] args) { int a=10, b=0; int result; try{ result = a/b;} catch(ArithmeticException ae){//exception name System.out.println(ae.getMessage()); System.out.println(ae); ae.printStackTrace(); } System.out.println("The code continues"); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "protected void finishExecution() {\r\n\r\n\t}", "private void finish() {\n }", "@Override\n protected void complete()\n {\n // Log the result of the script execution(s)\n logScriptCompletionStatus(associations, isBad);\n\n // Enable the calling dialog's controls\n dialog.setControlsEnabled(true);\n }", "public void finish() throws Exception {\n\t\t\n\t}", "public void complete() {\n\t}", "@Override\n\tpublic void complete()\n\t{\n\t}", "@Override\r\n\tpublic void complete() {\n\r\n\t}", "public void onComplete() {\n /*\n r3 = this;\n monitor-enter(r3)\n U r0 = r3.l // Catch:{ all -> 0x0022 }\n if (r0 != 0) goto L_0x0007\n monitor-exit(r3) // Catch:{ all -> 0x0022 }\n return\n L_0x0007:\n r1 = 0\n r3.l = r1 // Catch:{ all -> 0x0022 }\n monitor-exit(r3) // Catch:{ all -> 0x0022 }\n d.a.a0.c.e<U> r1 = r3.f13249d\n r1.offer(r0)\n r0 = 1\n r3.f13251f = r0\n boolean r0 = r3.f()\n if (r0 == 0) goto L_0x0021\n d.a.a0.c.e<U> r0 = r3.f13249d\n d.a.s<? super V> r1 = r3.f13248c\n r2 = 0\n d.a.a0.j.q.c(r0, r1, r2, r3, r3)\n L_0x0021:\n return\n L_0x0022:\n r0 = move-exception\n monitor-exit(r3) // Catch:{ all -> 0x0022 }\n throw r0\n */\n throw new UnsupportedOperationException(\"Method not decompiled: d.a.a0.e.d.o.b.onComplete():void\");\n }", "@Override\n\t\t\tpublic void onComplete(Bundle values) {\n\n\t\t\t\tfinish();\n\t\t\t}", "void complete();", "void complete();", "@Override\n\t\t\t\t\tpublic void onComplete() {\n\t\t\t\t\t}", "@Override\n\tprotected void doAfterCompletion(HttpServletRequest request,\n\t\t\tHttpServletResponse response, Object obj, Exception e) {\n\t\t\n\t}", "public void done() {\n try {\n C1000c.this.mo5101e(get());\n } catch (InterruptedException e) {\n Log.w(\"AsyncTask\", e);\n } catch (ExecutionException e2) {\n throw new RuntimeException(\"An error occurred while executing doInBackground()\", e2.getCause());\n } catch (CancellationException unused) {\n C1000c.this.mo5101e(null);\n } catch (Throwable th) {\n throw new RuntimeException(\"An error occurred while executing doInBackground()\", th);\n }\n }", "@Override\r\n\t\t\tpublic void onComplete() {\n\t\t\t\t\r\n\t\t\t}", "@Override\r\n\t\t\tpublic void onComplete() {\n\t\t\t\t\r\n\t\t\t}", "protected void end() {\n \tRobot.telemetry.setAutonomousStatus(\"Finishing \" + commandName + \": \" + distance);\n Robot.driveDistancePID.disable();\n \tRobot.drivetrain.arcadeDrive(0.0, 0.0);\n }", "@Override\r\n\t\t\tpublic void autEndProcess() {\n\t\t\t\t\r\n\t\t\t}", "@Override\r\n\t\t\tpublic void autEndProcess() {\n\t\t\t\t\r\n\t\t\t}", "@Override\r\n\t\t\tpublic void autEndProcess() {\n\t\t\t\t\r\n\t\t\t}", "@Override\r\n\t\t\tpublic void autEndProcess() {\n\t\t\t\t\r\n\t\t\t}", "@Override\r\n\t\t\tpublic void autEndProcess() {\n\t\t\t\t\r\n\t\t\t}", "protected void end() {\n \n \n }", "protected void finish() {\n }", "public static void finishALl() {\n\t\tSystem.exit(-1);\r\n\t}", "@Override\r\n\t\t\t\tpublic void autEndProcess() {\n\t\t\t\t\t\r\n\t\t\t\t}", "@Override\r\n\t\t\t\tpublic void autEndProcess() {\n\t\t\t\t\t\r\n\t\t\t\t}", "@Override\n public void onFailure(@NonNull Exception e) {\n finish();\n }", "protected void finishLogic() throws Exception {//activity\n this.worldActivity = CombatActivity.forName(moduleConfig.getString(\"Activity\"));\n loginSession = new LoginSession(moduleConfig, worldActivity);\n library = new XteaLibrary();\n ItemDefinition.init(revision);\n //gamedialogues.start\n Runtime.getRuntime().addShutdownHook(new WorldShutdownHook());\n protocol = Protocol.applyPatch(revision);\n //revisionMap = Protocol.handleProtocolLoad(revision, multiRevisional, new File(Module.getFile(\"available_revisions.inf\")));\n combat = new Combat(this.worldActivity);\n }", "@Override\n\tpublic void finish() {\n\t\t\n\t}", "@Override\r\n protected void end() {\r\n\r\n }", "@Override\r\n\t\t\tpublic void autEndProcess() {\n\t\t\t}", "@Override\r\n\t\t\tpublic void autEndProcess() {\n\t\t\t}", "void complete() {\n try {\n try {\n subscriber.onComplete();\n } catch (Throwable e) {\n Exceptions.handleUncaught(Conformance.onCompleteThrew(e));\n }\n } finally {\n // no need to remove ourselves from psm.\n terminate();\n }\n }", "@Override\n\tpublic void onComplete() {\n\t\tSystem.out.println(\"Its Done!!!\");\n\t}", "@Override\n\tpublic void finish() {\n\n\t}", "@Override\n\tpublic void finish() {\n\n\t}", "@Override\n\tpublic void finish() {\n\n\t}", "public void performCompletion() {\n/* 536 */ throw new RuntimeException(\"Stub!\");\n/* */ }", "void completeJob();", "public void complete()\n {\n isComplete = true;\n }", "@Override\n public void onComplete() {\n }", "@Override\n public void onComplete() {\n }", "@Override\n public void onComplete() {\n }", "@Override\n public void onComplete() {\n }", "@Override\n public void onComplete() {\n }", "@Override\n public void onComplete() {\n }", "@Override\n public void onComplete() {\n }", "@Override\n public void onComplete() {\n }", "@Override\n public void onComplete() {\n }", "@Override\n public void onComplete() {\n }", "@Override\n public void onComplete() {\n }", "@Override\n public void onComplete() {\n }", "public void finish() {}", "@Override\n\tpublic void endSuccess() {\n\t\t\n\t}", "public void finish() throws Exception {\n\t\tthis.reader.open();\n\t\tthis.reader.autoModeReset();\n\t\tthis.reader.setNotifyMode(AlienClass1Reader.OFF);\n\t\tthis.reader.close();\n\t}", "@Override\n\tpublic void finishSuccess() {\n\t\tSystem.err.println(\"finishSuccess\");\n\n\t}", "public void finish() { \n\t\t\n\t}", "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 }", "public void execute() throws Exception { \n \n \t source.emettre(); // on emet le signal \t \t \t \n }", "@Override\n\t\t\t\t\tpublic void onFinish() {\n\n\t\t\t\t\t}", "private void inizia() throws Exception {\n }", "protected void execute() {\n finished = true;\n }", "public void done() {\n AppMethodBeat.i(98166);\n try {\n AsyncTask.this.a(get());\n AppMethodBeat.o(98166);\n } catch (InterruptedException e) {\n AppMethodBeat.o(98166);\n } catch (ExecutionException e2) {\n RuntimeException runtimeException = new RuntimeException(\"An error occured while executing doInBackground()\", e2.getCause());\n AppMethodBeat.o(98166);\n throw runtimeException;\n } catch (CancellationException e3) {\n AsyncTask.this.a(null);\n AppMethodBeat.o(98166);\n }\n }", "@Override\n\t\t\tpublic void done(BmobException e) {\n\t\t\t\tif (e==null) {\n\t\t\t\t\ttoast(\"更新成功\");\n\t\t\t\t\tUpdateJobActivity.this.finish();\n\t\t\t\t} else {\n\t\t\t\t\ttoast(\"错误:\"+e.getMessage());\n\t\t\t\t}\n\t\t\t}", "protected void end() {\n isFinished();\n }", "@Override\n public void execute() {\n System.out.println(\"programm closed\");\n System.exit(0);\n }", "public void finish() {\n\n\t}", "@Override\n\t\t\t\t\tpublic void onFinish() {\n\t\t\t\t\t}", "@Override\n\t\t\t\t\tpublic void onFinish() {\n\t\t\t\t\t}", "public void DONE() throws SystemException {\r\n\t\t\r\n\t\t// Instance check.\r\n\t\tisResponseInstance();\r\n\t\tcommandResponder.done();\r\n\t}", "@Override\n\t\t\tpublic void end() {\n\t\t\t\t\n\t\t\t}", "void oR() {\n if (this.aqt == null) {\n throw new IllegalStateException(\"Callback must be set before execute\");\n }\n this.aqt.ob();\n bh.V(\"Attempting to load resource from disk\");\n if ((ce.oJ().oK() == ce.a.aqi || ce.oJ().oK() == ce.a.aqj) && this.aoc.equals(ce.oJ().getContainerId())) {\n this.aqt.a(bg.a.apM);\n return;\n }\n try {\n var1_1 = new FileInputStream(this.oS());\n }\n catch (FileNotFoundException var1_2) {\n bh.S(\"Failed to find the resource in the disk\");\n this.aqt.a(bg.a.apM);\n return;\n }\n var2_7 = new ByteArrayOutputStream();\n cr.b(var1_1, (OutputStream)var2_7);\n var2_7 = ol.a.l(var2_7.toByteArray());\n this.d((ol.a)var2_7);\n this.aqt.l((ol.a)var2_7);\n try {\n var1_1.close();\n }\n catch (IOException var1_3) {\n bh.W(\"Error closing stream for reading resource from disk\");\n }\n ** GOTO lbl52\n catch (IOException var2_8) {\n this.aqt.a(bg.a.apN);\n bh.W(\"Failed to read the resource from disk\");\n {\n catch (Throwable var2_10) {\n try {\n var1_1.close();\n }\n catch (IOException var1_6) {\n bh.W(\"Error closing stream for reading resource from disk\");\n throw var2_10;\n }\n throw var2_10;\n }\n }\n try {\n var1_1.close();\n }\n catch (IOException var1_4) {\n bh.W(\"Error closing stream for reading resource from disk\");\n }\n ** GOTO lbl52\n catch (IllegalArgumentException var2_9) {\n this.aqt.a(bg.a.apN);\n bh.W(\"Failed to read the resource from disk. The resource is inconsistent\");\n try {\n var1_1.close();\n }\n catch (IOException var1_5) {\n bh.W(\"Error closing stream for reading resource from disk\");\n }\nlbl52: // 6 sources:\n bh.V(\"The Disk resource was successfully read.\");\n return;\n }\n }\n }", "@Override\r\n\tpublic void done() {\n\t\t\r\n\t}", "@Override\n \tpublic void finished()\n \t{\n \t}", "@Override\n\t\tpublic void onFinish() {\n\t\t}", "@Override\n public boolean completed() {\n return false;\n }", "public void done() {\n\t\t}", "public void onComplete() {\r\n\r\n }", "public void done() {\n if (!isCancelled()) {\n try {\n C0637h.this.mo7991a(get());\n } catch (InterruptedException | ExecutionException e) {\n C0637h.this.mo7992a(e.getCause());\n }\n } else {\n C0637h.this.mo7992a((Throwable) new CancellationException());\n }\n }", "@Override\r\n\tprotected void processFinish() {\n\r\n\t}", "@Override\r\n\tprotected void processFinish() {\n\r\n\t}", "@Override\r\n\tprotected void processFinish() {\n\r\n\t}", "@Override\n public void done() {\n Toolkit.getDefaultToolkit().beep();\n enableMenusItens();\n \n if ( !erro ) {\n \tprogressBar.setValue(100);\n \ttaskOutput.append(\"Feito!\\n\");\n \ttaskOutput.append(\"Arquivo gerado com sucesso em \" + excelFileName);\n }\n }", "public void completeData();", "@Override\n\t\tpublic void onComplete() {\n\t\t\tSystem.out.println(\"onComplete\");\n\t\t}", "@Override\n\t\tpublic int onEnd(){\n\t\t\tif(masterError){\n\t\t\t\treturn 0;\n\t\t\t}\n\t\t\treturn 1;\n\t\t}", "@Override\n protected void end() {\n }", "@Override\n public void onFinish() {\n }", "protected void end() {\n\t\tRobot.Drivetrain.drive(0,0);\n\t}", "@Override\n\t\tpublic void done() {\n\n\t\t}", "@Override\n public void onFinish() {\n\t\t\t\n }", "protected void end() {\n // Robot.drive.setMoveVisionAssist(0);\n // Robot.drive.setTurnVisionAssist(0);\n Robot.limelight.setPipeline(1.0); \n }", "public void end() throws Exception;", "@Override\r\n\tprotected void end() {\r\n\t}", "protected void execute() {\n\ttry {\n\t if(!theLoader.loaderJag.getReverseLimitOK()) { // then we must be at the limit\n\t\t\n\t\t// since we're at the limit, calibrate!!\n\t\ttheLoader.CalibrateCurrentToLimitPosition();\n\t\t\n\t\t// now that we've calibrated, go to the start postition\n\t\ttheLoader.setOffsetSetpoint(Loader.START_OFFSET);\n\t\tisDone = true;\n\t }\n\t} catch (CANTimeoutException ex) {\n\t ex.printStackTrace();\n\t}\n }", "protected void end() {\n\t}", "protected void end() {\n\t}", "protected void end() {\n\t}", "protected void end() {\n\t}", "protected void end() {\n\t}" ]
[ "0.6579844", "0.65796363", "0.657692", "0.655499", "0.6481409", "0.6444069", "0.632361", "0.6268207", "0.62357736", "0.6154499", "0.6154499", "0.61539185", "0.6146283", "0.6142701", "0.6140326", "0.6140326", "0.6114004", "0.6068717", "0.6068717", "0.6068717", "0.6068717", "0.6068717", "0.6053723", "0.6051591", "0.60494053", "0.60402477", "0.60402477", "0.60377514", "0.6036638", "0.60187924", "0.59849894", "0.59831953", "0.59831953", "0.59803647", "0.5979401", "0.59598964", "0.59598964", "0.59598964", "0.5937493", "0.59312576", "0.5920705", "0.5914348", "0.5914348", "0.5914348", "0.5914348", "0.5914348", "0.5914348", "0.5914348", "0.5914348", "0.5914348", "0.5914348", "0.5914348", "0.5914348", "0.5912396", "0.5902596", "0.5899841", "0.58903146", "0.58819723", "0.5872953", "0.58679116", "0.58657", "0.5864535", "0.5856951", "0.58548635", "0.5853133", "0.58368456", "0.5832646", "0.58323073", "0.5829429", "0.5829429", "0.5793338", "0.5771234", "0.5768752", "0.57555324", "0.5751079", "0.5747498", "0.57468253", "0.57431614", "0.5733504", "0.5727527", "0.57243234", "0.57243234", "0.57243234", "0.57227534", "0.57218945", "0.57217216", "0.5719133", "0.57157964", "0.5712492", "0.5709795", "0.57089996", "0.57088524", "0.57044107", "0.56834096", "0.56828254", "0.5682479", "0.56824744", "0.56824744", "0.56824744", "0.56824744", "0.56824744" ]
0.0
-1
TODO Autogenerated method stub
public void setTable(DefaultTable table) { }
{ "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 void onConfigurationChanged(Configuration newConfig) { notOrientationChange=false; super.onConfigurationChanged(newConfig); }
{ "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
Save the user's current game state
@Override public void onSaveInstanceState(Bundle savedInstanceState) { savedInstanceState.putBoolean(HAS_RUN, true); //savedInstanceState.putParcelable(MODEL_DATA, dS); Log.i("MAIN","Saved instances"); // Always call the superclass so it can save the view hierarchy state super.onSaveInstanceState(savedInstanceState); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private void currentStateSaveToSharedPref() {\n sharedPreferences = getPreferences(Context.MODE_PRIVATE);\n SharedPreferences.Editor editor = sharedPreferences.edit();\n editor.putString(\"nameOfActiveChallenge\", nameOfCurrentChallenge);\n editor.putInt(\"key1OfActiveChallenge\", key1OfActiveChallenge);\n editor.putString(\"dateOfLastEdit\", dateOfLastEdit);\n editor.putFloat(\"goal\", goal);\n editor.putFloat(\"carry\", carry);\n editor.putInt(\"challengeDaysRunning\", challengeDaysRunning);\n editor.commit();\n }", "public void saveGameSession() {\n\t\tlastSaved = ProjectZero.calendar.getTime().toString();\n\t\tAssetHandler.saveGameSession();\n\t}", "public void SaveCurrentGame(){\n if(gameStarted == false){ return; }\n recordGame.write(board, timeRuunableThread, level);\n timeRuunableThread.setDrawNumber(false);\n canLoadGame = true;\n // update infoCanvas\n CleanInfoCanvas();\n }", "public void saveCurrentUserState(){\n\t\tCurrentUserState currState = new CurrentUserState();\n\t\tcurrState.setBatchOutput(batchState.getBatchOutput());\n\t\tcurrState.setCurrFields(batchState.getFields());\n\t\tcurrState.setCurrProject(batchState.getProject());\n\t\tcurrState.setCurrScale(display.getScale());\n\t\tcurrState.setCurrSelectedCell(batchState.getSelectedCell());\n\t\tcurrState.setErrorCells(batchState.getErrors());\n\t\t\n\t\tcurrState.setHighlight(display.isToggleOn());\n\t\tcurrState.setInverted(display.isInverted());\n\t\t\n\t\tcurrState.setCurrWindowPos(getLocationOnScreen());\n\t\tcurrState.setCurrWindowSize(getSize());\n\t\t\n\t\tcurrState.setHorizontalDiv(bottomPanel.getDividerLocation());\n\t\tcurrState.setVertivalDiv(centerPanel.getDividerLocation());\n\t\t\n\t\tcurrState.setOriginX(display.getW_originX());\n\t\tcurrState.setOriginY(display.getW_originY());\n\t\t\n\t\tcurrState.setValues(batchState.getValues());\n\t\t\n\t\t//put to xstream\n\t\tXStream xstream = new XStream(new DomDriver());\n\t\ttry {\n\t\t\n\t\t\txstream.toXML(currState, new FileOutputStream(new File(info.getUsername() + \".xml\")));\n\t\t\tSystem.out.println(\"current state is saved!\");\n\t\t} catch (FileNotFoundException e) {\n\t\t\tSystem.out.println(\"file not found/ couldn't go to xml\");\n\t\t\te.printStackTrace();\n\t\t}\n\t}", "public void saveGame() {\n\t\tmanager.saveGame();\n\t}", "private void saveCurrentState(Bundle outState){\n outState.putInt(PLAYER_COUNT_STATE_KEY,playerScore);\n outState.putSerializable(VIEW_MAP_STATE_KEY,globalViewMap);\n outState.putSerializable(CHILD_TEXT_CONTAINER_STATE_KEY,globalChildTextContainer);\n outState.putSerializable(PRIME_RECORD_MAP_KEY,primeRecorderMap);\n outState.putSerializable(CURRENT_SCREEN_GAME_STATE_KEY,currentScreenGameState);\n outState.putLong(GAME_TIME_LEFT_STATE_KEY,gameTimeLeftYet);\n }", "public void saveGame(){\n \tsaveOriginator.writeMap(this.map, this.getObjectives(), this.gameState);\n \tsaveGame.saveGame(saveOriginator);\n }", "public void save() {\n\t\tthis.setState(Constants.CWorld.STATE_SAVING);\n\t\tthis.getWorld().saveAll();\n\t\tthis.setState(Constants.CWorld.STATE_ONLINE);\n\t}", "public String saveCurrentGameState() {\r\n\t\treturn null;\r\n\t}", "public void saveState() { }", "@Override\r\n\tpublic GameState save() {\n\t\treturn null;\r\n\t}", "public void saveCurrentPlayer() {\n\t\tBashCmdUtil.bashCmdNoOutput(\"touch data/current_player\");\n\t\tBashCmdUtil.bashCmdNoOutput(String.format(\"echo \\\"%s\\\" >> data/current_player\",_currentPlayer));\n\t}", "private void saveState() {\n SharedPreferences prefs = getPreferences(MODE_PRIVATE);\n SharedPreferences.Editor editor = prefs.edit();\n\n // Store our count..\n editor.putInt(\"count\", this._tally);\n\n // Save changes\n editor.commit();\n }", "public void save(){\r\n\t\ttry {\r\n\t\t\tgame.suspendLoop();\r\n\t\t\tGameStockage.getInstance().save(game);\r\n\t\t\tgame.resumeLoop();\r\n\t\t} catch (GameNotSaveException e) {\r\n\t\t\tSystem.err.println(e.getMessage());\r\n\t\t\tgame.resumeLoop();\r\n\t\t} catch (IOException e) {\r\n\t\t\tSystem.err.println(e.getMessage());\r\n\t\t\tgame.resumeLoop();\r\n\t\t}\r\n\t}", "private void saveGame(){\n\t\t\n\t}", "@RequiresApi(api = Build.VERSION_CODES.O)\n @Override\n public void onPause() {\n SharedPreferences sharedPreferences = getSharedPreferences(MainActivity.sharedPreferencesKey,MODE_PRIVATE);\n SharedPreferences.Editor edit = sharedPreferences.edit();\n GlobalVariables globalVariables = GlobalVariables.getInstance();\n boolean gameStarted = globalVariables.getGameStarted();\n if (gameStarted) {\n try {\n String serializedGame = globalVariables.toString(\"\");\n edit.putString(\"game\", serializedGame);\n } catch (IOException e) {\n e.printStackTrace();\n }\n }\n edit.commit();\n super.onPause();\n }", "void saveGame();", "public void saveState() {\n\t\tsuper.saveState();\n\t}", "public void saveState() \n\t{\n\t\tsuper.saveState();\n\t}", "void saveGameState(File saveName);", "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 void saveGame();", "private void saveState() throws IOException {\n speakerManager.saveState();\n roomManager.saveState();\n organizerManager.saveState();\n eventManager.saveState();\n chatManager.saveState();\n attendeeManager.saveState();\n\n }", "@Override\r\n public void onSaveInstanceState(Bundle savedInstanceState) {\n super.onSaveInstanceState(savedInstanceState);\r\n // Save the user's current game state\r\n savedInstanceState.putInt(\"STEPS\", numSteps);\r\n\r\n }", "public void saveState(ObjectOutput out) throws IOException {\n\t\t// save deikto values\n\t\tdk.saveState(out);\n\t\t// save interpreter values\n\t\tout.writeFloat(interpreter.globalActorBox);\n\t\tout.writeFloat(interpreter.globalPropBox);\n\t\tout.writeFloat(interpreter.globalStageBox);\n\t\tout.writeFloat(interpreter.globalEventBox);\n\t\tout.writeFloat(interpreter.globalVerbBox);\n\t\tout.writeFloat(interpreter.globalBNumberBox);\n\n\t\t// save ticks\n\t\tout.writeInt(cMoments);\n\t\t// save inactivity counter\n\t\tout.writeInt(cInactivity);\n\t\t// save player inactivity\n\t\tout.writeInt(playerInactivity);\n\t\t// save storyIsOver\n\t\tout.writeBoolean(storyIsOver);\n\t\tout.writeBoolean(isEpilogueNow);\n\t\tout.writeBoolean(isHappilyDone);\n\t\tout.writeBoolean(isPenultimateDone);\n\n\t\t// save historyBook\n\t\tout.writeInt(historyBook.size());\n\t\tfor(Sentence s:historyBook)\n\t\t\tout.writeObject(s);\n\t\t// save random seeds\n\t\tout.writeObject(random);\n\t\tout.writeLong(interpreter.scriptRandom.getSeed());\n\t\t// save alarms\n\t\tout.writeInt(alarms.size());\n\t\tfor(Alarm a:alarms)\n\t\t\tout.writeObject(a);\n\t\tout.writeInt(storybook.size());\n\t\tfor(String s:storybook)\n\t\t\tout.writeUTF(s);\n\t}", "public void save() {\n savePrefs();\n }", "void gameSaved() {\n\t\tSystem.out.println(\"\\n\\nGame saved.\");\n\t}", "@Override\n protected void onSaveInstanceState(Bundle outState) {\n super.onSaveInstanceState(outState);\n\n outState.putInt(\"roundCount\", roundCount);\n outState.putInt(\"player1Points\", player1Points);\n outState.putInt(\"player2Points\", player2Points);\n outState.putBoolean(\"player1Turn\", player1Turn);\n }", "void save() {\r\n if (actionCompleted) {\r\n forget();\r\n } else {\r\n AccountSettings.stateStored = new Bundle();\r\n save(AccountSettings.stateStored);\r\n }\r\n }", "public void saveState() throws IOException {\n\t\tFile f = new File(workingDirectory() + File.separator + id() + FILE_EXTENSION);\n\t\t\n\t\t// create new file if it doesnt exist\n\t\tf.createNewFile();\n\t\t\n\t\t// dump client state into file\n\t\tObjectOutputStream os = new ObjectOutputStream(new FileOutputStream(f));\n\t\tos.writeObject(this);\n\t\tos.close();\n\t}", "@Override\n public void onSaveInstanceState(Bundle savedInstanceState)\n {\n savedInstanceState.putIntArray(\"board\", tttGame.getBoard());\n savedInstanceState.putBoolean(\"turn\", tttGame.getTurn());\n savedInstanceState.putBoolean(\"mode\", tttGame.getAIMode());\n\n savedInstanceState.putInt(\"p1Count\", pOneCounter);\n savedInstanceState.putInt(\"p2Count\", pTwoCounter);\n savedInstanceState.putInt(\"pAICount\",pAICounter);\n savedInstanceState.putInt(\"tieCount\", tieCounter);\n\n boolean[] enabled = getState();\n savedInstanceState.putBooleanArray(\"state\", enabled);\n }", "public void save() {\r\n try {\r\n FileOutputStream fos = new FileOutputStream(REPO_STATE_FILE_NAME);\r\n fos.write(CodecUtils.toJson(this).getBytes());\r\n fos.close();\r\n } catch (Exception e) {\r\n Logging.logError(e);\r\n }\r\n }", "@Override\n public void save(Game game) {\n }", "private void savePrefsData() {\n SharedPreferences pref = getApplicationContext().getSharedPreferences(\"myPrefs\", MODE_PRIVATE);\n SharedPreferences.Editor editor = pref.edit();\n editor.putBoolean(\"isIntroOpnend\", true);\n editor.commit();\n }", "@Override\n public void onSaveInstanceState(Bundle savedInstanceState) {\n // Save the user's current game state\n savedInstanceState.putBoolean(\"Authenticated\", authenticated);\n\n // Always call the superclass so it can save the view hierarchy state\n super.onSaveInstanceState(savedInstanceState);\n }", "private void saveAppState(Context context) {\n LogHelper.v(LOG_TAG, \"Saving state.\");\n }", "public void save() {\n\t\ttry {\n\t\t\t// use buffering\n\t\t\tOutputStream file = new FileOutputStream(\"games.txt\");\n\t\t\tOutputStream buffer = new BufferedOutputStream(file);\n\t\t\tObjectOutput output = new ObjectOutputStream(buffer);\n\t\t\ttry {\n\t\t\t\tif (gameOver) {\n\t\t\t\t\t//notify no need to save completed game\n\t\t\t\t} else {\n\t\t\t\t\tgames.add(this);\n\t\t\t\t\toutput.writeObject(games);\n\t\t\t\t}\n\t\t\t} finally {\n\t\t\t\toutput.close();\n\t\t\t}\n\t\t} catch (IOException e) {\n\t\t\tSystem.out.println(\"Save not successful\");\n\t\t}\n\t}", "@Override\n public void saveGame() {\n\n }", "@Override\n protected void onSaveInstanceState(Bundle savedInstanceState) {\n savedInstanceState.putInt(\"scorePlayerA\", scorePlayerA);\n savedInstanceState.putInt(\"scorePlayerB\", scorePlayerB);\n savedInstanceState.putInt(\"triesPlayerA\", triesPlayerA);\n savedInstanceState.putInt(\"triesPlayerB\", triesPlayerB);\n super.onSaveInstanceState(savedInstanceState);\n }", "public void saveGame(){\n updateProperties();\n try {\n output = new FileOutputStream(fileName);\n properties.store(output, null); //saving properties to file\n } catch (IOException e) {\n System.out.println(\"--- FAILED TO SAVE GAME ---\");\n e.printStackTrace();\n } finally {\n if (output != null) {\n try {\n output.close();\n System.out.println(\"--- GAME SAVED ---\");\n } catch (IOException e) {\n System.out.println(\"--- FAILED TO CLOSE OUTPUT ---\");\n e.printStackTrace();\n }\n }\n }\n }", "@Override\r\n\tpublic void onPause() {\r\n\t\tsuper.onPause();\r\n\t\ttry {\r\n\t\t\tSaveGameHandler.saveGame(this, new SaveGame(controller, status),\r\n\t\t\t\t\t\"test.game\");\r\n\t\t} catch (IOException e) {\r\n\t\t\te.printStackTrace();\r\n\t\t}\r\n\t}", "private void persistData() {\n mSharedPref.storeLastScreen(SCREEN_NAME);\n }", "public SaveGame() {\n\t\tlives = 0;\n\t\tscore = 0;\n\t\tbrainX = 0;\n\t\tbrainY = 0;\n\t\tzombieX = 0;\n\t}", "public void save() {\n final JFileChooser fileChooser =\n new JFileChooser(System.getProperty(\"user.dir\"));\n try {\n fileChooser.setSelectedFile(new File(\"save.ser\"));\n int saveFile = fileChooser.showSaveDialog(GameFrame.this);\n\n if (saveFile == JFileChooser.APPROVE_OPTION) {\n File saveGame = fileChooser.getSelectedFile();\n FileOutputStream fileOut = new FileOutputStream(saveGame);\n ObjectOutputStream objOut = new ObjectOutputStream(fileOut);\n objOut.writeObject(world);\n objOut.close();\n fileOut.close();\n System.out.println(\"Game saved.\");\n } else {\n return;\n }\n } catch (IOException i) {\n i.printStackTrace();\n }\n\n }", "public void SaveGame(){\n if(gameStarted == false || canLoadGame == true){ return; }\n gamePaused = true;\n timeRuunableThread.setPause(gamePaused);\n int input = JOptionPane.showOptionDialog(null, \"Do you want to save game?\", \"Save Game\", JOptionPane.OK_CANCEL_OPTION, JOptionPane.INFORMATION_MESSAGE, null, null, null);\n if(input == JOptionPane.OK_OPTION) {\n SaveCurrentGame();\n animationThread.start();\n if(muteMusic == false){\n music.stopPlayingAudio(\"All\");\n music.playAudio(\"LoadingScreenMusic\");\n }\n musicName = \"LoadingScreenMusic\";\n }else{\n gamePaused = false;\n timeRuunableThread.setPause(gamePaused);\n }\n }", "private void saveInPreferences(String gameName) {\n //Store name in shared preferences\n SharedPreferences preferences = PreferenceManager.getDefaultSharedPreferences(this);\n SharedPreferences.Editor editor = preferences.edit();\n editor.putString(\"gameName\", gameName);\n editor.commit();\n\n //Check if gameName stored\n //String storedPreference = preferences.getString(\"gameName\",\"none\");\n //Log.d(\"checkGameName\", storedPreference);\n }", "@Override\n public void onSaveInstanceState(Bundle outState) {\n super.onSaveInstanceState(outState);\n currentStateSaveToSharedPref();\n }", "private void saveState() {\n // Increase capacity if necessary\n if (nSaved == savedC.length) {\n Object tmp;\n tmp = savedC;\n savedC = new int[nSaved+SAVED_INC];\n System.arraycopy(tmp,0,savedC,0,nSaved);\n tmp = savedCT;\n savedCT = new int[nSaved+SAVED_INC];\n System.arraycopy(tmp,0,savedCT,0,nSaved);\n tmp = savedA;\n savedA = new int[nSaved+SAVED_INC];\n System.arraycopy(tmp,0,savedA,0,nSaved);\n tmp = savedB;\n savedB = new int[nSaved+SAVED_INC];\n System.arraycopy(tmp,0,savedB,0,nSaved);\n tmp = savedDelFF;\n savedDelFF = new boolean[nSaved+SAVED_INC];\n System.arraycopy(tmp,0,savedDelFF,0,nSaved);\n }\n // Save the current sate\n savedC[nSaved] = c;\n savedCT[nSaved] = cT;\n savedA[nSaved] = a;\n savedB[nSaved] = b;\n savedDelFF[nSaved] = delFF;\n nSaved++;\n }", "public void save() {\n\t\tpreferences().flush();\n\t}", "@Override\n public void onPause() {\n super.onPause();\n ObjectOutput out = null;\n String fileName = \"savedGame\";\n File saved = new File(getFilesDir(), fileName);\n\n try {\n out = new ObjectOutputStream(new FileOutputStream(saved, false));\n out.writeObject(player);\n out.close();\n } catch (FileNotFoundException e) {\n e.printStackTrace();\n } catch (IOException e) {\n e.printStackTrace();\n }\n }", "void save() {\n File file = new File(main.myPath + \"state.xml\");\n Framework.backup(main.myPath + \"state.xml\");\n Framework.transform(stateDoc, new StreamResult(file), null);\n setDirty(false);\n }", "@Override\n public void actionPerformed(ActionEvent e) {\n currentUser = (String) comboBox1.getSelectedItem();\n try {\n saveGame.setGameState(currentUser);\n } catch (IOException ex) {\n System.out.println(ex);\n }\n }", "@Override\n protected void onSaveInstanceState(Bundle outState) {\n outState.putParcelable(GAME_TAG, game);\n outState.putBoolean(EXIT_ALERT_VISIBILITY, exitAlertVisible); // is EXIT AlertDialog shown?\n super.onSaveInstanceState(outState);\n }", "@Override\n protected void onSaveInstanceState(Bundle bundle) {\n super.onSaveInstanceState(bundle);\n gameView.saveInstanceState(bundle);\n }", "public boolean isSavingGame() {\n return savingGame;\n }", "@Override\n public void onSaveInstanceState(Bundle outState) {\n super.onSaveInstanceState(outState);\n outState.putBoolean(\"AppRunning\",running);\n outState.putBoolean(\"Latest\",latestOp);\n outState.putBoolean(\"Started\",started);\n outState.putInt(\"Seconds\",sec);\n outState.putInt(\"Score\",score);\n outState.putInt(\"Total\",total);\n }", "private void storeViewState()\n\t{\n\t\tCommand lastCmd = project.getLastCommand();\n\t\tif (lastCmd != null)\n\t\t{\n\t\t\tlastCmd.setOptionalState(view.toJSONString(lastCmd.getProjectState()));\n\t\t}\n\t}", "@Override\n protected void onSaveInstanceState(@NonNull Bundle outState) {\n super.onSaveInstanceState(outState);\n outState.putInt(TEAM_A_SCORE_KEY, teamAScoreInt);\n outState.putInt(TEAM_B_SCORE_KEY, teamBScoreInt);\n outState.putInt(TEAM_A_FOUL_KEY, teamAFoulScoreInt);\n outState.putInt(TEAM_B_FOUL_KEY, teamBFoulScoreInt);\n }", "private void save() {\n Tile[][] field = gameController.grid.field;\n Tile[][] undoField = gameController.grid.undoField;\n// SharedPreferenceUtil.put(this, SpConstant.WIDTH, field.length);\n// SharedPreferenceUtil.put(this, SpConstant.HEIGHT, field.length);\n for (int xx = 0; xx < field.length; xx++) {\n for (int yy = 0; yy < field[0].length; yy++) {\n if (field[xx][yy] != null) {\n SharedPreferenceUtil.put(this, xx + \"_\" + yy, field[xx][yy].getValue());\n } else {\n SharedPreferenceUtil.put(this, xx + \"_\" + yy, 0);\n }\n\n if (undoField[xx][yy] != null) {\n SharedPreferenceUtil.put(this, SpConstant.UNDO_GRID + xx + \"_\" + yy, undoField[xx][yy].getValue());\n } else {\n SharedPreferenceUtil.put(this, SpConstant.UNDO_GRID + xx + \"_\" + yy, 0);\n }\n }\n }\n SharedPreferenceUtil.put(this, SpConstant.SCORE, gameController.currentScore);\n SharedPreferenceUtil.put(this, SpConstant.HIGH_SCORE_TEMP, gameController.historyHighScore);\n SharedPreferenceUtil.put(this, SpConstant.UNDO_SCORE, gameController.lastScore);\n SharedPreferenceUtil.put(this, SpConstant.CAN_UNDO, gameController.canUndo);\n SharedPreferenceUtil.put(this, SpConstant.GAME_STATE, gameController.gameState);\n SharedPreferenceUtil.put(this, SpConstant.UNDO_GAME_STATE, gameController.lastGameState);\n SharedPreferenceUtil.put(this, SpConstant.AUDIO_ENABLED, gameController.isAudioEnabled);\n }", "private void savePreferences(){\n SharedPreferences prefs = getPreferences(MODE_PRIVATE);\n SharedPreferences.Editor editor = prefs.edit();\n\n editor.putInt(\"p1Count\", pOneCounter);\n editor.putInt(\"p2Count\", pTwoCounter);\n editor.putInt(\"pAICount\", pAICounter);\n editor.putInt(\"tieCount\", tieCounter);\n\n editor.commit();\n }", "private void saveState() {\r\n \tSharedPreferences settings = getSharedPreferences(TEMP, 0);\r\n \tEditor editor = settings.edit();\r\n \tif (mRowId != null)\r\n \t\teditor.putLong(DbAdapter.KEY_ROWID, mRowId);\r\n \teditor.putLong(DbAdapter.KEY_DATE, mTime);\r\n \teditor.putString(DbAdapter.KEY_PAYEE, mPayeeText != null && \r\n \t\t\tmPayeeText.getText() != null ? mPayeeText.getText().toString() : null);\r\n \teditor.putString(DbAdapter.KEY_AMOUNT, mAmountText != null && \r\n \t\t\tmAmountText.getText() != null ? mAmountText.getText().toString() : null);\r\n \teditor.putString(DbAdapter.KEY_CATEGORY, mCategoryText != null && \r\n \t\t\tmCategoryText.getText() != null ? mCategoryText.getText().toString() : null);\r\n \teditor.putString(DbAdapter.KEY_MEMO, mMemoText != null && \r\n \t\t\tmMemoText.getText() != null ? mMemoText.getText().toString() : null);\r\n \teditor.putString(DbAdapter.KEY_TAG, mTagText != null && \r\n \t\t\tmTagText.getText() != null ? mTagText.getText().toString() : null);\r\n \teditor.commit();\r\n }", "public void saveState(IMemento memento) {\n\t\t\r\n\t}", "public void saveState() {\n savedPen.setValues(pm.pen);\n }", "@Override\n protected void onSaveInstanceState(Bundle outState) {\n super.onSaveInstanceState(outState);\n Session currentSession = sessionTracker.getSession();\n Session.saveSession(currentSession, outState);\n outState.putBoolean(SESSION_IS_ACTIVE_KEY, sessionTracker.isTrackingActiveSession());\n }", "private Bundle saveState() {\n Bundle state = new Bundle();\n // For Example\n //state.putString(\"text\", tv1.getText().toString());\n onSaveState(state);\n return state;\n }", "private void saveMove(){\n\t\tpreviousTile=monster.currentTile;\r\n\t}", "private void savePreferences() {\n SharedPreferences sp = getSharedPreferences(MY_PREFS, MODE_PRIVATE);\n SharedPreferences.Editor editor = sp.edit();\n\n editor.putInt(\"entreeIndex\", spEntree.getSelectedItemPosition());\n editor.putInt(\"drinkIndex\", spDrink.getSelectedItemPosition());\n editor.putInt(\"dessertIndex\", spDessert.getSelectedItemPosition());\n\n editor.apply();\n }", "@Override\r\n protected void onSaveInstanceState(Bundle outState) {\r\n super.onSaveInstanceState(outState);\r\n\r\n String stateSaveHome = home.getText().toString();\r\n outState.putString(\"save_state_home\", stateSaveHome);\r\n\r\n String stateSaveVisitor = visitor.getText().toString();\r\n outState.putString(\"save_state_visitor\", stateSaveVisitor);\r\n }", "private void saveInitialGameLocation() {\n\n\t\tGAME_LIST = new ArrayList<gameLocation>();\n\n\t\tfor (int i = 0; i < NumGameLocation; i++) {\n\t\t\taddNewGame(getGameLocation(i));\n\t\t}\n\t}", "private void saveCurrentPreferences() {\n\t\toldUnitType = preferences.getInt(\"displayUnit\", UnitType.FOOTINCH.getId());\n\t\toldPrecision = preferences.getInt(\"precision\", 16);\n\t\toldRounding = preferences.getBoolean(\"roundUp\", true);\n\t\toldDisplayOptions = preferences.getString(\"displayOptions\", context.getString(R.string.displayAutomatic));\n\t}", "private void save() {\n prefs.saveCardBackground(selectedBackground);\n prefs.saveCardBackgroundColor(selectedBackgroundColor);\n\n updateSummary();\n }", "private void save() {\n Saver.saveTeam(team);\n }", "public void save() {\n settingService.saveMaxScore(score);\r\n// powerUpCount = 0;\r\n// powerDownCount = 0;\r\n// purplePowerCount = 0;\r\n// yellowMadnessCount = 0;\r\n// shapeCount = 0;\r\n }", "private void writePref() {\n SharedPreferences.Editor editor = sp.edit();\n long currentTime = System.currentTimeMillis();\n editor.putLong(UPDATE, currentTime);\n editor.commit();\n System.out.println(\"Time of current update: \" + getDateFromLong(currentTime));\n }", "private static void saveScore() {\n\t\tif (mContext != null) {\n\t\t\tEditor edit = mContext.getSharedPreferences(Defines.SHARED_PREF_NAME, Context.MODE_PRIVATE).edit();\n\t\t\tedit.putInt(Defines.SHARED_PREF_ACTIVITY_SCORE, DataStore.mActivityScore);\n\n\t\t\tfor (int x = 0; x < Defines.NUM_DAYS_SCORE_TO_SAVE; x++) {\n\t\t\t\tedit.putInt(Defines.SHARED_PREF_PREV_SCORE + x, DataStore.mPreviousActivityScores[x]);\n\t\t\t}\n\n\t\t\tif (mActivityScoreDate != null) {\n\t\t\t\tedit.putString(Defines.SHARED_PREF_SCORE_DATE, mActivityScoreDate.format2445());\n\t\t\t}\n\n\t\t\tedit.commit();\n\t\t}\n\t}", "@Override\n public void onSaveInstanceState(Bundle outState) {\n outState.putBundle(ICICLE_KEY, mGameView.saveState());\n }", "public void save () {\n preference.putBoolean(\"sound effect\", hasSoundOn);\n preference.putBoolean(\"background music\", hasMusicOn);\n preference.putFloat(\"sound volume\", soundVolume);\n preference.putFloat(\"music volume\", musicVolume);\n preference.flush(); //this is called to write the changed data into the file\n }", "public void saveGame(DataOutputStream s) throws IOException {\n s.writeUTF(level.toString());\n s.writeUTF(level.getName());\n s.writeInt(lives);\n s.writeInt(points);\n s.writeInt(wonLevels);\n pacman.writeEntity(s);\n s.writeInt(entities.size());\n for (GameEntity entity : entities)\n entity.writeEntity(s);\n }", "public boolean saveState(String _filename) {\r\n\t\treturn saveVariables(_filename, stateVariablesList);\r\n\t}", "static boolean savePlayerState(PlayerState playerState) {\n if (playerState.getId() == null) {\n return insertPlayerState(playerState);\n } else {\n return updatePlayerState(playerState);\n }\n }", "public static void save(){\n\t\ttry{\n\t\t\tFile f=new File(Constants.PATH+\"\\\\InitializeData\\\\battlesavefile.txt\");\n\t\t\tPrintWriter pw=new PrintWriter(f);\n\t\t\tpw.println(turn);\n\t\t\tpw.println(opponent.toString());\n\t\t\tfor(Unit u:punits){\n\t\t\t\tpw.println(u.toString());\n\t\t\t}\n\t\t\tpw.println(\"End Player Units\");\n\t\t\tfor(Unit u:ounits){\n\t\t\t\tpw.println(u.toString());\n\t\t\t}\n\t\t\tpw.println(\"End Opponent Units\");\n\t\t\tpw.println(priorities);\n\t\t\tpw.println(Arrays.asList(xpgains));\n\t\t\tpw.println(spikesplaced+\" \"+numpaydays+\" \"+activeindex+\" \"+activeunit.getID()+\" \"+weather+\" \"+weatherturn);\n\t\t\tpw.println(bfmaker.toString());\n\t\t\tpw.close();\n\t\t}catch(Exception e){e.printStackTrace();}\n\t}", "@Override\n public void onSaveInstanceState(Bundle outState) {\n super.onSaveInstanceState(outState);\n mGameLoop.saveState(outState);\n Log.w(LOG_TAG, \"sIS called\");\n }", "public static void saveStats() {\r\n\t\tif(Main.optionsCheckbox.getState()) FileUtils.exportGameOptions();\r\n\t\t\r\n\t\tif(Main.isFourHandedTeams) {\r\n\t\t\tif(Main.team1Checkbox.getState()) FileUtils.exportTeamFile(Main.teamOne);\r\n\t\t\tif(Main.team2Checkbox.getState()) FileUtils.exportTeamFile(Main.teamTwo);\r\n\t\t\tif(Main.teamPreviousCheckbox.getState()) FileUtils.exportTeamFile(Main.teamPrevious);\r\n\t\t}\r\n\t\t\r\n\t\tif(Main.isFourHandedSingle) {\r\n\t\t\tif(Main.player1Checkbox.getState()) FileUtils.exportPlayerFile(Main.playerOne);\r\n\t\t\tif(Main.player2Checkbox.getState()) FileUtils.exportPlayerFile(Main.playerTwo);\r\n\t\t\tif(Main.player3Checkbox.getState()) FileUtils.exportPlayerFile(Main.playerThree);\r\n\t\t\tif(Main.player4Checkbox.getState()) FileUtils.exportPlayerFile(Main.playerFour);\r\n\t\t\tif(Main.playerPreviousCheckbox.getState()) FileUtils.exportPlayerFile(Main.playerPrevious);\r\n\t\t}\r\n\t\t\r\n\t\tif(Main.isThreeHanded) {\r\n\t\t\tif(Main.player1Checkbox.getState()) FileUtils.exportPlayerFile(Main.playerOne);\r\n\t\t\tif(Main.player2Checkbox.getState()) FileUtils.exportPlayerFile(Main.playerTwo);\r\n\t\t\tif(Main.player3Checkbox.getState()) FileUtils.exportPlayerFile(Main.playerThree);\r\n\t\t\tif(Main.playerPreviousCheckbox.getState()) FileUtils.exportPlayerFile(Main.playerPrevious);\r\n\t\t}\r\n\t}", "public Save(Game game) {\n\t\tthis(game, \"/\");\n\t\t\n\t\twritePrefs(\"Preferences\");\n\t}", "@Override\n public void saveState(Bundle outBundle) {\n }", "public void displayCurrentState(State game);", "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 saveState() {\n table.saveState(store);\n }", "private void setCurrentUserState(CurrentUserState savedState){\n\t\t\n\t\tif(savedState.getBatchOutput() != null){\n\t\t\t\n\t\t\tbatchState.setImageID(info.getImageID());\n\t\t\tbatchState.setErrors(savedState.getErrorCells());\n\t\t\tbatchState.setFields(savedState.getCurrFields());\n\t\t\tbatchState.setBatchOutput(savedState.getBatchOutput());\n\t\t\tbatchState.setProject(savedState.getCurrProject());\n\t\t\t\n\t\t\tdisplay.setInverted(savedState.isInverted());\n\t\t\tdisplay.setToggleOn(savedState.isHighlight());\n\t\t\tbatchState.initDownloadBatch();\n\n\t\t\tbatchState.setSelectedCell(savedState.getCurrSelectedCell());\n\t\t\tbatchState.setValues(savedState.getValues());\n\t\t\t\n\t\t\tdisplay.setScale(savedState.getCurrScale());\n\t\t\tdisplay.setW_originX(savedState.getOriginX());\n\t\t\tdisplay.setW_originY(savedState.getOriginY());\n\t\t\t\n\t\t\tbuttonsPanel.toggleButtons(true);\n\t\t\tdownloadbatchMenu.setEnabled(false);\n\t\t\t\n\t\t}\n\t\telse{\n\t\t\tbuttonsPanel.toggleButtons(false);\n\t\t\tdownloadbatchMenu.setEnabled(true);\n\t\t}\n\t\tthis.setLocation(savedState.getCurrWindowPos());\n\t\tthis.setSize(savedState.getCurrWindowSize());\n\t\tbottomPanel.setDividerLocation(savedState.getHorizontalDiv());\n\t\tcenterPanel.setDividerLocation(savedState.getVertivalDiv());\n\t\t\n\t}", "public void save() {\n DataBuffer.saveDataLocally();\n\n //TODO save to db must be done properly\n DataBuffer.save(session);\n\n //TODO recording saved confirmation\n }", "public void saveState() throws RemoteException {\r\n server.unbind(this.agentID);\r\n try {\r\n ObjectOutputStream oos = new ObjectOutputStream(new FileOutputStream(\"agent.dat\"));\r\n oos.writeObject(this);\r\n oos.close();\r\n } catch (Exception e) {\r\n System.out.println(\"Object not saved correctly.\");\r\n } finally {\r\n System.exit(0);\r\n }\r\n }", "public void saveScore() {\n if (this.currentScore > this.highScore) {\n this.highScore = this.currentScore;\n SharedPreferences sharedPref = this.getPreferences(Context.MODE_PRIVATE);\n SharedPreferences.Editor editor = sharedPref.edit();\n editor.putInt(\"High Score\", this.highScore);\n editor.commit();\n }\n }", "public void save() {\n SharedPreferences settings = activity.getSharedPreferences(\"Preferences\", 0);\n SharedPreferences.Editor editor = settings.edit();\n editor.putLong(\"bestDistance\", values.bestDistance);\n\n // Commit the edits!\n editor.commit();\n\n }", "private void currentStateRestoreFromSharedPref() {\n sharedPreferences = getPreferences(MODE_PRIVATE);\n int key1DeffaultValue = -1;\n key1OfActiveChallenge = sharedPreferences.getInt(\"key1OfActiveChallenge\", key1DeffaultValue);\n nameOfCurrentChallenge = sharedPreferences.getString(\"nameOfActiveChallenge\", nameOfCurrentChallenge);\n\n dateOfLastEdit = sharedPreferences.getString(\"dateOfLastEdit\", dateOfLastEdit);\n\n goal = sharedPreferences.getFloat(\"goal\", goal);\n carry = sharedPreferences.getFloat(\"carry\", carry);\n\n challengeDaysRunning = sharedPreferences.getInt(\"challengeDaysRunning\", challengeDaysRunning);\n }", "private void saveStateSnapshot(State state){\n\t\ttry{\n\t\t\tif(saveStateSnapshot){\n\t\t\t\t//System.out.println(Utils.treeDesc(state, 2, Tags.Role, Tags.Desc, Tags.Shape, Tags.Blocked));\n\t\t\t\tTaggable taggable = new TaggableBase();\n\t\t\t\ttaggable.set(SystemState, state);\n\t\t\t\tLogSerialiser.log(\"Saving state snapshot...\\n\", LogSerialiser.LogLevel.Debug);\n\t\t\t\tFile file = Util.generateUniqueFile(settings.get(ConfigTags.OutputDir), \"state_snapshot\");\n\t\t\t\tObjectOutputStream oos = new ObjectOutputStream(new BufferedOutputStream(new FileOutputStream(file)));\n\t\t\t\toos.writeObject(taggable);\n\t\t\t\toos.close();\n\t\t\t\tsaveStateSnapshot = false;\n\t\t\t\tLogSerialiser.log(\"Saved state snapshot to \" + file.getAbsolutePath() + \"\\n\", LogSerialiser.LogLevel.Info);\n\t\t\t}\n\t\t}catch(IOException ioe){\n\t\t\tthrow new RuntimeException(ioe);\n\t\t}\n\t}", "public void startSavedGame()\n {\n \n // get rid of nl character left in the stream\n // outFile.flush();\n \n // prompt user and get a file path\n System.out.println(\"\\nWhat is the file path?\");\n String filePath = keyboard.next();\n \n // call the getSavedGame( ) method in the GameControl class to load the game\n GameControl gc = new GameControl();\n gc.getSavedGame(filePath);\n\n // display the game menu for the loaded game\n MainMenuView mmv = new MainMenuView();\n mmv.displaySaveGameView();\n }", "public GameState(){\n this.gameResults = \"\";\n initVars();\n this.theme = DEFAULT_THEME;\n this.board = new Board(DEFAULT_BOARD);\n createSetOfPlayers(DEFAULT_PLAYERS, DEFAULT_AUTOPLAYER, DEFAULT_AUTOMODE);\n }", "public static void saveOptions() {\r\n\t\tMain.bagValue = GameOptions.bagValue.getSelectedItem();\r\n\t\tMain.nilValue = GameOptions.nilValueTextField.getText();\r\n\t\tMain.doubleNilValue = GameOptions.doubleNilValueTextField.getText();\r\n\t\tMain.winScore = GameOptions.winScoreTextField.getText();\r\n\t\tMain.loseScore = GameOptions.loseScoreTextField.getText();\r\n\t}", "public void save()\n\t{\n\t\tif(entity != null)\n\t\t\t((SaveHandler)DimensionManager.getWorld(0).getSaveHandler()).writePlayerData(entity);\n\t}", "@Override \n\t\tpublic void onSaveInstanceState(Bundle savedInstanceState) {\n\t\t savedInstanceState.putInt(STATE_SCORE, mCurrentScore);\n\t\t savedInstanceState.putInt(STATE_LEVEL, mCurrentLevel);\n\t\t \n\t\t // Always call the superclass so it can save the view hierarchy state \n\t\t super.onSaveInstanceState(savedInstanceState);\n\t\t}", "public void onSaveListen() {\n _gamesList.get(_gamePos).getPlayers().add(playerName);\n // Increment the number of players that have joined the game\n _gamesList.get(_gamePos).setNumPlayers(_gamesList.get(_gamePos).getNumPlayers() + 1);\n\n TextView playersBlock = (TextView) findViewById(R.id.playersBlock);\n playersBlock.setText(\"\");\n List<String> players = _gamesList.get(_gamePos).getPlayers();\n for(int i = 0; i < players.size(); i++) {\n Log.d(\"GamePlayerSize\", Integer.toString(_gamesList.get(_gamePos).getPlayers().size()));\n if (i < players.size() - 1) {\n playersBlock.append(players.get(i) + \", \");\n }\n else {\n // Don't put a comma after the last one\n playersBlock.append(players.get(i));\n }\n }\n\n // Update the shared preferences with the edited game\n SharedPreferences gamesPref = this.getSharedPreferences(GAMES_FILE, MODE_PRIVATE);\n Gson gson = new Gson();\n\n SharedPreferences.Editor prefsEditor = gamesPref.edit();\n\n // Convert the games list into a json string\n String json = gson.toJson(_gamesList);\n Log.d(\"MainActivity\", json);\n\n // Update the _gamesMasterList with the modified _game\n prefsEditor.putString(GAME_KEY, json);\n prefsEditor.commit();\n\n Context context = getApplicationContext();\n CharSequence text = \"You have joined the game!\";\n int duration = Toast.LENGTH_SHORT;\n\n Toast toast = Toast.makeText(context, text, duration);\n toast.show();\n }" ]
[ "0.7804075", "0.7712752", "0.7602927", "0.75645405", "0.7396474", "0.7345214", "0.73291826", "0.7311352", "0.7284302", "0.72278345", "0.7219766", "0.71794105", "0.71143407", "0.709977", "0.708385", "0.70568585", "0.6988412", "0.69816697", "0.69075036", "0.6854349", "0.68473125", "0.6813", "0.6804535", "0.679316", "0.6751886", "0.6741948", "0.67112195", "0.66653234", "0.66583097", "0.66476786", "0.6624848", "0.65511996", "0.6539535", "0.65329653", "0.6525638", "0.6520806", "0.65181804", "0.6505397", "0.6484687", "0.6482079", "0.64808476", "0.6471371", "0.64697117", "0.6462602", "0.6438923", "0.6393636", "0.6364297", "0.6324874", "0.6317972", "0.63177484", "0.6303283", "0.63010615", "0.62819004", "0.62647796", "0.62634504", "0.6261256", "0.62443346", "0.6236664", "0.62317985", "0.62292904", "0.62250984", "0.621046", "0.620954", "0.6199932", "0.6196067", "0.61685467", "0.61577475", "0.6149385", "0.61273116", "0.61265075", "0.6126415", "0.6114527", "0.6112063", "0.6078477", "0.607443", "0.60717785", "0.6067582", "0.60623467", "0.6052587", "0.6048725", "0.6046392", "0.6035237", "0.60350484", "0.6022953", "0.6011613", "0.6001004", "0.60004544", "0.59912133", "0.5991106", "0.59878147", "0.59852076", "0.5984283", "0.59825844", "0.597575", "0.5971748", "0.59657913", "0.596329", "0.5961395", "0.5960971", "0.59607035", "0.59518474" ]
0.0
-1
Do Here what ever you want do on back press;
@Override public void onBackPressed() { super.onBackPressed(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\r\n\tpublic void backButton() {\n\t\t\r\n\t}", "@Override\n public void onBackPressed() {\n if(web.canGoBack()){\n web.goBack();\n } else {\n super.onBackPressed();\n }\n }", "@Override\n\tpublic void onBackPressed() {\n\t\t\n\t}", "void onGoBackButtonClick();", "@Override\r\n\tpublic void onBackPressed() {\n\r\n\t}", "@Override\r\n\tpublic void onBackPressed() {\n\r\n\t}", "@Override\r\n\tpublic void onBackPressed() {\n\t\tsuper.onBackPressed();\r\n\t\tdoBack();\r\n\t}", "@Override\n \tpublic void onBackPressed() {\n \t}", "public void back() {\n Views.goBack();\n }", "@Override\n public void backButton() {\n\n\n }", "@Override\n\tpublic void onBackPressed() {\n\n\t}", "public void onBackPressed() {\n backbutton();\n }", "@Override\n\tpublic void onBackPressed() {\n\t\tBack();\n\t}", "@Override\r\n public void onBackPressed() {\n }", "public void onBackPressed() {\r\n }", "@Override\n\tpublic void onBackPressed()\n\t{\n\t}", "@Override\n public void onBackPressed(){\n System.out.println(\"---------------- No debe hacer nada -------------------------------\");\n }", "@Override\n public void onBackPressed()\n {\n\n }", "public void goBack() {\n goBackBtn();\n }", "@Override\n\tpublic void onBackPressed() {\n\t}", "@Override\n\tpublic void onBackPressed() {\n\t}", "@Override\n\tpublic void onBackPressed() {\n\t}", "@Override\n\tpublic void onBackPressed() {\n\t}", "@Override\n public void onBackPressed() {}", "@Override\n\tpublic void onBackPressed()\n\t\t{\n\t\tbackPressed();\n\t\t}", "@Override\n // Detect when the back button is pressed\n public void onBackPressed() {\n\n // Let the system handle the back button\n\n super.onBackPressed();\n\n }", "@Override\n\tpublic void backButton() {\n\n\t}", "@Override\n public void onBackPressed() {\n }", "@Override\n public void onBackPressed() {\n }", "@Override\n public void onBackPressed() {\n }", "@Override\n public void onBackPressed() {\n }", "@Override\n public void onBackPressed() {\n }", "@Override\n public void onBackPressed() {\n }", "@Override\n public void onBackPressed() {\n }", "@Override\n public void onBackPressed() {\n }", "@Override\n public void onBackPressed() {\n }", "@Override\n public void onBackPressed() {\n }", "@Override\n public void onBackPressed() {\n }", "@Override\n public void onBackPressed() {\n }", "@Override\n public void onBackPressed() {\n }", "@Override\n public void onBackPressed() {\n }", "@Override\n public void onBackPressed() {\n }", "@Override\n public void onBackPressed() {\n }", "@Override\n\tpublic void onBackPressed() {\n\t\tsuper.onBackPressed();\n\n\t\t\n\t}", "@Override\n public void onBackPressed() { }", "@Override\n public void backPressed(){\n }", "@Override\n public void onBackPressed() {\n backToHome();\n }", "boolean onBackPressed();", "boolean onBackPressed();", "@Override\r\n\tpublic void onBackPressed() {\n\t\tbackButtonHandler();\r\n\t\treturn;\r\n\t}", "public void onBackPressed()\n {\n }", "@Override\n\tpublic void onBackPressed() {\n\treturn;\n\t}", "@Override\n public void handleOnBackPressed() {\n }", "@Override\n public void goBack() {\n\n }", "@Override\r\n\tpublic void onBackPressed() {\n\t\tsuper.onBackPressed();\r\n\t}", "@Override\r\n\tpublic void onBackPressed() {\n\t\tsuper.onBackPressed();\r\n\t}", "@Override\n public void onBackPressed(){\n }", "@Override\r\n\tpublic void onBackPressed() {\n\t\tfinish();\r\n\t}", "@Override\r\n\tpublic void onBackPressed() {\n\t\tfinish();\r\n\t}", "public static void onBackPressed()\n {\n }", "@Override\n\tpublic void onBackKeyPressed() {\n\treturn;\t\n\t}", "public void back()\n\t{\n\t\tdriver.findElementById(OR.getProperty(\"BackButton\")).click();\n\t}", "@Override\n public void onBackPressed() {\n //super.onBackPressed();\n goBack();\n }", "@Override\n public void onBackPressed() {\n\n\n super.onBackPressed();\n\n }", "@Override\n\tpublic void onBackPressed() {\n\t\tfinish();\n\t\tsuper.onBackPressed();\n\t}", "@Override\n\tpublic void onBackPressed() {\n\t\tfinish();\n\t\tsuper.onBackPressed();\n\t}", "@Override\n\tpublic void onBackPressed() {\n\t\tsuper.onBackPressed();\n\t\tfinish();\n\t}", "@Override\n\tpublic void onBackPressed() {\n\t\tsuper.onBackPressed();\n\t\tfinish();\n\t}", "@Override\n\tpublic void onBackPressed() {\n\t\tsuper.onBackPressed();\n\t\tfinish();\n\t}", "public void onBackPressed(){\n }", "@Override\n\tpublic void onBackPressed() {\n\t\tsuper.onBackPressed();\n\t\t finish();\n\t}", "@Override\n public void onBackPressed()\n {\n mIsBackButtonPressed = true;\n super.onBackPressed();\n \n }", "@Override\n public void onBackPressed() {\n super.onBackPressed();\n }", "@Override\n public void onBackPressed() {\n super.onBackPressed();\n }", "@Override\n public void onBackPressed() {\n super.onBackPressed();\n }", "@Override\n public void onBackPressed() {\n super.onBackPressed();\n }", "@Override\n public void onBackPressed() {\n super.onBackPressed();\n }", "@Override\n public void onBackPressed() {\n super.onBackPressed();\n }", "@Override\n public void onBackPressed() {\n super.onBackPressed();\n }", "@Override\n public void onBackPressed() {\n super.onBackPressed();\n this.finish();\n }", "@Override\n public void onBackPressed() {\n super.onBackPressed();\n this.finish();\n }", "@Override\n public void onBackPressed() {\n return;\n }", "@Override\n public void onBackPressed() {\n return;\n }", "@Override\n public void onBackPressed() {\n return;\n }", "@Override\n public void onBackPressed() {\n return;\n }", "@Override\n public void onBackPressed()\n {\n super.onBackPressed();\n }", "@Override\n public void onBackPressed() {\n super.onBackPressed();\n\n }", "@Override\n\tpublic void onBackPressed() {\n\t\tupdata();\n\t\tsuper.onBackPressed();\n\t}", "@Override\n public void onBackPressed() {\n\n finish();\n }", "@Override\n\tpublic void onBackPressed() {\n\t\tthis.finish();\n\t\tsuper.onBackPressed();\n\t}", "protected void handleBack(ActionEvent event) {\n\t}", "private void returnBack()\n {\n getActivity().onBackPressed();\n }", "@Override\n\tpublic void onBackPressed() {\n\t\treturn;\n\t}" ]
[ "0.8369724", "0.835255", "0.8349505", "0.8347241", "0.8313743", "0.8313743", "0.83131164", "0.8283113", "0.8266392", "0.82591003", "0.824914", "0.8248022", "0.82347167", "0.8222484", "0.8222405", "0.82217807", "0.82140553", "0.8212019", "0.8211788", "0.82060015", "0.82060015", "0.82060015", "0.82060015", "0.8205846", "0.8201736", "0.8193021", "0.8183399", "0.8146159", "0.8146159", "0.8146159", "0.8146159", "0.8146159", "0.8146159", "0.8146159", "0.8146159", "0.8146159", "0.8146159", "0.8146159", "0.8146159", "0.8146159", "0.8146159", "0.8146159", "0.8146159", "0.81414235", "0.8140893", "0.81377035", "0.81289935", "0.81123036", "0.81123036", "0.8109395", "0.8101016", "0.8093004", "0.8048646", "0.80385315", "0.8035466", "0.8035466", "0.80288434", "0.8028404", "0.8028404", "0.8009473", "0.79901123", "0.7989642", "0.7971747", "0.79669416", "0.79651505", "0.79651505", "0.7953146", "0.7953146", "0.7953146", "0.7951324", "0.79479533", "0.79355806", "0.7905281", "0.7905281", "0.7905281", "0.7905281", "0.7905281", "0.7905281", "0.7905281", "0.7903949", "0.7903949", "0.7891799", "0.7891799", "0.7891799", "0.7891799", "0.78864926", "0.78832805", "0.7876987", "0.7875856", "0.7874285", "0.7870535", "0.7868667", "0.7864496" ]
0.7973622
69
SitesProviderHelper.deleteSite(mApp,String.valueOf(Consts.BLANK_SITE_ID_NO_LOCATION)); find current location to parse forecast
private void getUserCurrentLocation() { NicerLocationManager locationMgr = new NicerLocationManager(this.getApplicationContext()); if (locationMgr.isAnyLocationServicesAvailble()) { Log.i("MAIN","retrieving current location..."); // get current location locationMgr.getBestGuessLocation(1000, new NicerLocationListener() { @Override public void locationLoaded(final Location location) { // parse the current site forecast for users current // location in the background //LocationForecastSetup currentForecast = new LocationForecastSetup(); //currentForecast.execute(location); // QLog.i("location loaded. finding nearest location..."); // // // find nearest weather location // Site nearestLocation = // Utils.findNearestSite(mApp, location); // // // insert the new current user location site // SitesProviderHelper.addSavedSite(mApp, // Long.valueOf(nearestLocation.getmSiteId()), true); // Log.i("MAIN","location found "+location.getLatitude()+" "+location.getLongitude()); dS.lat=(float) location.getLatitude(); dS.lon=(float) location.getLongitude(); //TextView versionText = (TextView) findViewById(R.id.info_area_string); //versionText.setText("lat " + location.getLatitude()+" lon "+location.getLongitude()); // // /* // * add blank site if user has no saved sites. a blank site // * forecast is also added in the WeatherService class // * (runWeatherService method) to display correctly in the // * view pager.this is later removed when a user adds a // site // * and added again when user removes last site. // */ // SitesProviderHelper.addBlankSavedSite(mApp); // // // re-order sites so current location is first // SitesProviderHelper.setSiteOrder(mApp, // nearestLocation.getmSiteId(), "0"); // SitesProviderHelper.setSiteOrder(mApp, // Consts.BLANK_SITE_ID, "1"); } @Override public void error() { // give option to change location settings or select a // location manually Log.e("MAIN","Error finding best guess location"); dS.lat=0; dS.lon=0; if(once) { //promptSetLocationService(MainActivity.this); } once=false; } @Override public void onFinished() { //runUpdateService(false, false); Log.i("MAIN","onFinished"); } }); } else { dS.lat=0; dS.lon=0; } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n\t public void locationLoaded(final Location location)\n\t { parse the current site forecast for users current\n\t // location in the background\n\t //LocationForecastSetup currentForecast = new LocationForecastSetup();\n\t //currentForecast.execute(location);\n\n\t // QLog.i(\"location loaded. finding nearest location...\");\n\t //\n\t // // find nearest weather location\n\t // Site nearestLocation =\n\t // Utils.findNearestSite(mApp, location);\n\t //\n\t // // insert the new current user location site\n\t // SitesProviderHelper.addSavedSite(mApp,\n\t // Long.valueOf(nearestLocation.getmSiteId()), true);\n\t //\n\t Log.i(\"MAIN\",\"location found \"+location.getLatitude()+\" \"+location.getLongitude());\n\t dS.lat=(float) location.getLatitude();\n\t dS.lon=(float) location.getLongitude();\n\t //TextView versionText = (TextView) findViewById(R.id.info_area_string);\n\t //versionText.setText(\"lat \" + location.getLatitude()+\" lon \"+location.getLongitude());\n\t \n\t //\n\t // /*\n\t // * add blank site if user has no saved sites. a blank site\n\t // * forecast is also added in the WeatherService class\n\t // * (runWeatherService method) to display correctly in the\n\t // * view pager.this is later removed when a user adds a\n\t // site\n\t // * and added again when user removes last site.\n\t // */\n\t // SitesProviderHelper.addBlankSavedSite(mApp);\n\t //\n\t // // re-order sites so current location is first\n\t // SitesProviderHelper.setSiteOrder(mApp,\n\t // nearestLocation.getmSiteId(), \"0\");\n\t // SitesProviderHelper.setSiteOrder(mApp,\n\t // Consts.BLANK_SITE_ID, \"1\");\n\n\t }", "@Override\n public void onLocationChanged(Location location) {\n LocationServices.FusedLocationApi.removeLocationUpdates(mGoogleApiClient, this);\n \tmDiveSiteManager.saveLastLocation(location);\n }", "@SuppressWarnings(\"MissingPermission\")\n private void getLastLocation() {\n mFusedLocationClient.getLastLocation()\n .addOnCompleteListener(getActivity(), new OnCompleteListener<Location>() {\n @Override\n public void onComplete(@NonNull Task<Location> task) {\n if (task.isSuccessful() && task.getResult() != null) {\n mLastLocation = task.getResult();\n getWeather(mLastLocation);\n } else {\n Log.w(TAG, \"getLastLocation:exception\", task.getException());\n showSnackbar(getString(R.string.no_location_detected));\n }\n }\n });\n }", "@Override\n\tpublic List<Historic_siteVO> MainLocation() throws Exception {\n\t\treturn dao.MainLocation();\n\t}", "void unsaveCurrentStation();", "private void deleteOldData() {\n Date today = SunshineDateUtils.getNormalizedUtcDateForToday();\n weatherDao.deleteOldWeather(today);\n }", "private void removeLocation() {\n try {\n this.location_view.setVisibility(View.GONE);\n this.current_location.setVisibility(View.GONE);\n this.drop_location.setVisibility(View.GONE);\n this.mPostModel.setLocationPost(\"\");\n } catch (Exception ex) {\n ex.printStackTrace();\n }\n }", "private Location getLastKnownLocation(){\n \t \tLocation loc = LocationUtil.getBestLastKnowLocation(ctx);\t\n \t \tStatus.getCurrentStatus().setLocation(loc);\t\n \t \treturn loc;\n \t}", "public static Location getLatestLocation(){\n if(latestLocation!= null) {\n return latestLocation;\n }else{\n return null;\n }\n }", "public void downloadWeatherForCurrentLocation() {\n if(checkConnection()) {\n LocationManager locationManager = LocationManager.getInstance(this, view);\n locationManager.getCoordinates();\n } else {\n showNoConnectionDialog();\n }\n }", "void updateForecast(DarkSkyApi api, PlaceWeather weather){\n\n long now = Calendar.getInstance().getTimeInMillis()/1000;\n\n deleteObsoleteEntries(now);\n\n long placeId = weather.getId();\n long currentDay = databaseInstance.weatherDao().selectObsoleteDayCount(now);\n long daysSaved = databaseInstance.weatherDao().selectDayCount();\n\n //check if need to load data\n if(daysSaved - currentDay < 7){\n\n List<HourlyData> hourlyData;\n\n String apiKey = context.getString(R.string.api_key);\n Map<String, String> avoid = new HashMap<>();\n avoid.put(\"units\", \"si\");\n avoid.put(\"lang\", \"en\");\n avoid.put(\"exclude\", \"alerts,daily\");\n\n long currentTime = weather.getDaily().getData().get(\n weather.getDaily().getData().size()-1\n ).getTime() + 1;\n\n //load days\n for(long day = daysSaved - currentDay; day < 7; ++day){\n currentTime += 3600 * 24;\n PlaceWeather nextDay;\n try{\n nextDay = api.getTimeForecast(apiKey,\n weather.getLatitude(),\n weather.getLongitude(),\n now, avoid).execute().body();\n }catch (IOException e){\n //log network failure\n break;\n }\n\n nextDay.getDaily().getData().get(0).setParentPlaceId(placeId);\n\n long nextDailyDataId =\n databaseInstance.weatherDao().insertDailyData(\n nextDay.getDaily().getData().get(0)\n );\n\n nextDay.getHourly().setParentDayId(nextDailyDataId);\n nextDay.getHourly().setId(\n databaseInstance.weatherDao().insertHourly(nextDay.getHourly())\n );\n\n hourlyData = nextDay.getHourly().getData();\n\n for(int j = 0; j < hourlyData.size(); ++j){\n hourlyData.get(j).setParentDayId(nextDailyDataId);\n databaseInstance.weatherDao().insertHourlyData(hourlyData.get(j));\n }\n }\n }\n }", "SiteLocation getLocatedAt();", "@Override\n\tpublic String getLocation() {\n\t\treturn null;\n\t}", "@Override\n\tpublic String getLocation() {\n\t\treturn null;\n\t}", "public abstract WeatherData[] getDailyWeatherForecast(LocationCoordinate _location) throws Exception;", "@Generated(hash = 74421150)\n public synchronized void resetForecast() {\n forecast = null;\n }", "public void resetLocation()\r\n {\r\n locations.clear();\r\n }", "public abstract WeatherData getCurrentWeather(LocationCoordinate _location) throws Exception;", "private void removeLocationUpdatesWithIntent() {\n mFusedLocationProviderClient.removeLocationUpdates(mLocationCallback)\n // Define callback for success in stopping requesting location updates.\n .addOnSuccessListener(new OnSuccessListener<Void>() {\n @Override\n public void onSuccess(Void aVoid) {\n Toast.makeText(MainActivity.this, \"Location Request Successfully Stopped\",LENGTH_SHORT).show();\n }\n })\n // Define callback for failure in stopping requesting location updates.\n .addOnFailureListener(new OnFailureListener() {\n @Override\n public void onFailure(Exception e) {\n Toast.makeText(MainActivity.this, \"Location Request Failed to Stop\",LENGTH_SHORT).show();\n }\n });\n }", "private void updateWeather() {\n\t\tFetchWeatherTask weatherTask = new FetchWeatherTask(getActivity()); \n\t\tString location = Utility.getPreferredLocation(getActivity());\n\t\tweatherTask.execute(location); \n\t}", "@Override\n\t\t\tpublic void onLocationChanged(Location location) {\n\t\t\t\tnew PostDogShitTask().execute(location);\n\t\t\t\tmLocationManager.removeUpdates(mLocationListener);\n\t\t\t}", "public void removeLocationUpdates() {\n timer.schedule(new TimerTask() {\n @Override\n public void run() {\n if (insideOrganization != null) {\n\n organizationAccess = new OrganizationAccess();\n //Update the access' list when the user exits from organization.\n organizationAccess.setEntranceTimestamp(organizationAccessTime);\n organizationAccess.setAccessType(accessType);\n organizationAccess.setOrganizationId(insideOrganization.getOrgID());\n organizationAccess.setOrgName(insideOrganization.getName());\n organizationAccess.setExitTimestamp(OffsetDateTime.now());\n organizationAccess.setTimeStay(HomePageActivity.getCurrentTime());\n\n if (HomePageActivity.getSwitcherModeStatus()) {\n //Comunicates the server that user is outside the organization(authenticated).\n server.performOrganizationMovementServer(insideOrganization.getOrgAuthServerID(), insideOrganization.getOrgID(), userToken, -1, organizationMovement.getExitToken(),organizationAccess,prefsEditor,gson);\n } else {\n //Comunicates the server that user is outside the organization(anonymous).\n server.performOrganizationMovementServer(null, insideOrganization.getOrgID(),userToken, -1, organizationMovement.getExitToken(), organizationAccess,prefsEditor,gson);\n }\n\n flag = false;\n\n\n organizationMovement = null;\n String organizationMovementJson = gson.toJson(null);\n String insideOrganizationJson = gson.toJson(null);\n prefsEditor.putString(\"organizationMovement\",organizationMovementJson);\n prefsEditor.putString(\"insideOrganization\",insideOrganizationJson);\n prefsEditor.commit();\n }\n if (insidePlace != null) {\n\n placeAccess = new PlaceAccess();\n //Update the access' list when the user exits from organization and place.\n placeAccess.setEntranceTimestamp(placeAccessTime);\n placeAccess.setPlaceName(insidePlace.getName());\n placeAccess.setOrgId(orgID);\n placeAccess.setExitTimestamp(OffsetDateTime.now());\n\n if (HomePageActivity.getSwitcherModeStatus()) {\n //Comunicates the server that user is outside the place(authenticated).\n server.performPlaceMovementServer(placeMovement.getExitToken(), -1, insidePlace.getId(), insideOrganization.getOrgAuthServerID(), userToken, placeAccess,prefsEditor,gson);\n } else {\n //Comunicates the server that user is outside the place(anonymous).\n server.performPlaceMovementServer(placeMovement.getExitToken(), -1, insidePlace.getId(), null, userToken, placeAccess,prefsEditor,gson);\n }\n\n //Deletes the place's list of the organization.\n insidePlace = null;\n placeMovement = null;\n String placeMovementJson = gson.toJson(null);\n String insidePlacejson = gson.toJson(null);\n prefsEditor.putString(\"placeMovement\",placeMovementJson);\n prefsEditor.putString(\"insidePlace\",insidePlacejson);\n prefsEditor.commit();\n }\n\n }\n }, 2000);\n\n if (insideOrganization != null) {\n Toast.makeText(getApplicationContext(), \"Sei uscito dall'organizzazione: \" + insideOrganization.getName(), Toast.LENGTH_SHORT).show();\n\n }\n if (insidePlace != null) {\n Toast.makeText(getApplicationContext(), \"Sei uscito dal luogo: \" + insidePlace.getName(), Toast.LENGTH_SHORT).show();\n\n }\n\n HomePageActivity.setNameOrg(\"Nessuna organizzazione\");\n HomePageActivity.setNamePlace(\"Nessun luogo\");\n HomePageActivity.playPauseTimeService();\n HomePageActivity.resetTime();\n\n HomePageActivity.playPauseTimeServicePlace();\n HomePageActivity.resetTimePlace();\n\n timer.schedule(new TimerTask() {\n @Override\n public void run() {\n Intent intent = new Intent(ACTION_BROADCAST);\n intent.putExtra(EXTRA_LOCATION, mLocation);\n LocalBroadcastManager.getInstance(getApplicationContext()).sendBroadcast(intent);\n }\n },5000);\n //Reset of all parameters.\n Log.i(TAG, \"Removing location updates\");\n\n try {\n mFusedLocationClient.removeLocationUpdates(mLocationCallback);\n Utils.setRequestingLocationUpdates(this, false);\n if(!mPrefs.getBoolean(\"switchTrack\", false)) {\n stopSelf();\n }\n\n } catch (SecurityException unlikely) {\n Utils.setRequestingLocationUpdates(this, true);\n Log.e(TAG, \"Lost location permission. Could not remove updates. \" + unlikely);\n }\n }", "public export.serializers.avro.DeviceInfo.Builder clearSite() {\n site = null;\n fieldSetFlags()[0] = false;\n return this;\n }", "@Override\n public void onLocationChanged(Location location) {\n //Aqui creamos la funcion DownloadWebPageTask para poder descargar los archivos desde la pagina del api\n DownloadWebPageTask task = new DownloadWebPageTask(location);\n task.execute(new String[] { \"http://api.openweathermap.org/data/2.5/weather?lat=\"+location.getLatitude()+\n \"&lon=\"+location.getLongitude()+\"&units=metric&lang=fr&appid=5bdfb081811a28abc515bc673fc0d20f\" });\n Log.d(\"DEBUGGGGGGGGGGGGGGGGGG\", String.valueOf(location.getLatitude()));\n }", "@SuppressLint(\"MissingPermission\")\n @AfterPermissionGranted(PERMISSION_LOCATION_ID)\n private void getCurrentLocation() {\n Task<Location> task = fusedLocationProviderClient.getLastLocation();\n task.addOnSuccessListener(new OnSuccessListener<Location>() {\n @Override\n public void onSuccess(Location location) {\n if(location != null) {\n currentLat = location.getLatitude();\n currentLong = location.getLongitude();\n\n String placeType = \"museum\";\n\n int radius = ProfileFragment.getRadius();\n\n String url = \"https://maps.googleapis.com/maps/api/place/nearbysearch/json\" +\n \"?location=\" + currentLat + \",\" + currentLong +\n \"&radius=\" + radius +\n \"&type=\" + placeType +\n \"&key=\" + getResources().getString(R.string.maps_api_key);\n\n new NearbyMuseumTask().execute(url);\n\n mapFragment.getMapAsync(new OnMapReadyCallback() {\n @Override\n public void onMapReady(GoogleMap googleMap) {\n map = googleMap;\n setMapUISettings();\n\n map.animateCamera(CameraUpdateFactory.newLatLngZoom(\n new LatLng(currentLat,currentLong), 12\n ));\n }\n });\n }\n }\n });\n }", "private void obtainCurrentLocation(boolean add_current_location_on) {\n\t\tif (add_current_location_on) {\n\t\t\t// If Google Play Services is available\n\t\t\tif (servicesConnected()) {\n\t\t\t\t// mProgressBar_location.setVisibility(View.VISIBLE);\n\t\t\t\t// Get the current location\n\t\t\t\tLocation currentLocation = mLocationClient.getLastLocation();\n\t\t\t\tlink_to_global_report.setReporter_geopoint(new LatLng(currentLocation.getLatitude(), currentLocation.getLongitude()));\n\t\t\t\t// mProgressBar_location.setVisibility(View.GONE);\n\t\t\t\tLog.e(DEBUG, \"current_location_add:\" + currentLocation);\n\t\t\t}\n\n\t\t} else {\n\t\t\tToast.makeText(this, DEBUG + \"off ... supposed to delete loc!\", Toast.LENGTH_SHORT).show();\n\t\t\t// mProgressBar_location.setVisibility(View.GONE);\n\t\t}\n\t}", "public void onStop(){mainActivity.locationManager.removeUpdates(mainActivity.locationListener);}", "private void fetchLastLocation() {\n try {\n FusedLocationProviderClient fusedLocationProviderClient = LocationServices.getFusedLocationProviderClient(this);\n //get last known location of device\n Task<Location> task = fusedLocationProviderClient.getLastLocation();\n\n task.addOnSuccessListener(new OnSuccessListener<Location>() {\n @Override\n public void onSuccess(Location location) {\n if (location != null) {\n //store current location\n currentLocation = location;\n Toast.makeText(MapsActivity.this, currentLocation.getLatitude() + \" \" + currentLocation.getLongitude(), Toast.LENGTH_SHORT).show();\n // Obtain the SupportMapFragment\n supportMapFragment = (SupportMapFragment) getSupportFragmentManager().findFragmentById(R.id.fragment_content);\n // Attach OnMapReadyCallback listener using getMapAsync(OnMapReadyCallback)\n // This listener notified when the map is ready by invoking onMapReady along with a GoogleMap object.\n supportMapFragment.getMapAsync(MapsActivity.this);\n } else {\n Toast.makeText(MapsActivity.this, \"No Location recorded\", Toast.LENGTH_SHORT).show();\n }\n }\n });\n } catch (SecurityException e) {\n Log.e(\"Exception: %s\", e.getMessage());\n }\n }", "private void stopPeriodicUpdates() {\n\t\tmLocationClient.removeLocationUpdates(this);\n\t\tmConnectionState.setText(R.string.location_updates_stopped);\n\t}", "protected void saveProjectSite() {\r\n\t\tlog.debug(\"saveing project site\");\r\n\r\n\t\ttry {\r\n\r\n\t\t\tLocation curLocation = new Location(LocationServiceFactory.getLocationService().getLocation()), lastLocation = site.getLastLocation();\r\n\r\n\t\t\tif (lastLocation == null || (curLocation.getX() != lastLocation.getX() && curLocation.getY() != lastLocation.getY())) {\r\n\t\t\t\tsite.setLastLocation(curLocation);\r\n\r\n\t\t\t\tDao<Location, Integer> locDao = databaseHelper.getDao(Location.class);\r\n\r\n\t\t\t\tif (lastLocation != null) {\r\n\t\t\t\t\t// delete old location\r\n\t\t\t\t\tlocDao.delete(lastLocation);\r\n\t\t\t\t}\r\n\t\t\t\t// and create new one\r\n\t\t\t\tlocDao.create(curLocation);\r\n\r\n\t\t\t}\r\n\r\n\t\t\tfor (MultiTouchDrawable d : map.getSubDrawables()) {\r\n\r\n\t\t\t\tif (d instanceof AccessPointDrawable) {\r\n\t\t\t\t\tAccessPoint ap = ((AccessPointDrawable) d).getAccessPoint();\r\n\t\t\t\t\t// id is not 0, so this location was never saved\r\n\t\t\t\t\tif (!ap.isCalculated() && ap.getLocation() != null) {\r\n\t\t\t\t\t\ttry {\r\n\t\t\t\t\t\t\tdatabaseHelper.getDao(Location.class).create(ap.getLocation());\r\n\t\t\t\t\t\t\tdatabaseHelper.getDao(AccessPoint.class).update(ap);\r\n\t\t\t\t\t\t} catch (SQLException e) {\r\n\t\t\t\t\t\t\tlog.error(\"could not save location data for an ap: \" + ap.toString(), e);\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\r\n\r\n\t\t\tint changed = projectSiteDao.update(site);\r\n\r\n\t\t\tif (changed > 0) {\r\n\t\t\t\tToast.makeText(this, R.string.project_site_saved, Toast.LENGTH_SHORT).show();\r\n\t\t\t}\r\n\r\n\t\t\tprojectSiteDao.refresh(site);\r\n\t\t} catch (SQLException e) {\r\n\t\t\tlog.error(\"could not save or refresh project site\", e);\r\n\t\t\tToast.makeText(this, R.string.project_site_save_failed, Toast.LENGTH_LONG).show();\r\n\t\t}\r\n\r\n\t}", "private void stopLocationUpdates() {\n if (!mRequestingLocationUpdates) {\n Log.e(TAG, \"stopLocationUpdates: updates never requested, no-op.\");\n return;\n }\n\n // It is a good practice to remove location requests when the activity is in a paused or\n // stopped state. Doing so helps battery performance and is especially\n // recommended in applications that request frequent location updates.\n mFusedLocationClient.removeLocationUpdates(mLocationCallback).addOnCompleteListener(this, new OnCompleteListener<Void>() {\n @Override\n public void onComplete(@NonNull Task<Void> task) {\n SunshinePreferences.setRequestUpdates(MainActivity.this, false);\n mRequestingLocationUpdates = false;\n }\n });\n }", "private void returnForecast() {\n\t\tif (callback != null) {\n\t\t\t// use the callback to prevent the client\n\t\t\tif (callback.get() != null) {\n\t\t\t\t// yep, we use a weakReference\n\t\t\t\tcallback.get().forecastLoaded(forecasts);\n\t\t\t}\n\t\t\tif (forecasts.isEmpty()&&reload) {\n\t\t\t\tupdateForecastRequest();\n\t\t\t} else {\n\t\t\t\t// then ask the serviceupdater to update data\n\t\t\t\t// but update only if one day of difference between the last update and now is more\n\t\t\t\t// than one day\n\t\t\t\tString strLastUpdate = MyApplication.instance.getServiceManager().getForecastServiceUpdater().getLastUpdate(this.woeid);\n\t\t\t\tLog.e(\"ForecastServiceData\", \"strLastUpdate \" + strLastUpdate);\n\t\t\t\ttry {\n\t\t\t\t\t// empty data base case and empty SharedPreference\n\t\t\t\t\tif (strLastUpdate.equals(\"null\")) {\n\t\t\t\t\t\tupdateForecastRequest();\n\t\t\t\t\t} else {\n\t\t\t\t\t\t// current case\n SimpleDateFormat sdf=MyApplication.instance.getServiceManager().getForecastServiceUpdater().getDateFormatForLastUpdate();\n\t\t\t\t\t\tDate lastUpdate = sdf.parse(strLastUpdate);\n\t\t\t\t\t\tif (new Date().getTime() - lastUpdate.getTime() > 1000 * 60 * 60 * 24) {\n\t\t\t\t\t\t\t// if the last update was one day ago, then make an automatic update\n\t\t\t\t\t\t\tupdateForecastRequest();\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t} catch (ParseException e) {\n\t\t\t\t\tExceptionManager.manage(new ExceptionManaged(this.getClass(), R.string.exc_date_parsing, e));\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}", "@Override\n protected void onPause() {\n super.onPause();\n providerClient.removeLocationUpdates(locationCallback);\n }", "private void getDeviceLocation(){\n Log.d(TAG,\"get device location currently\");\n mFusedLocationProviderClient= LocationServices.getFusedLocationProviderClient(this);\n try{\n if(mLocationPermissionGranted){\n @SuppressLint(\"MissingPermission\") final Task location = mFusedLocationProviderClient.getLastLocation();\n location.addOnCompleteListener(new OnCompleteListener() {\n @Override\n public void onComplete(@NonNull Task task) {\n if(task.isSuccessful()){\n Log.d(TAG,\"onComplete: found Location\");\n mLastKnownLocation= (Location) task.getResult();\n moveCamera(new LatLng(mLastKnownLocation.getLatitude(),mLastKnownLocation.getLongitude()),DEFAULT_ZOOM);\n\n Geocoder geocoder;\n List<Address> addresses;\n geocoder = new Geocoder(MapsActivity.this, Locale.getDefault());\n\n try {\n addresses = geocoder.getFromLocation(mLastKnownLocation.getLatitude(), mLastKnownLocation.getLongitude(), 1); // Here 1 represent max location result to returned, by documents it recommended 1 to 5\n LatLng latLng = new LatLng(mLastKnownLocation.getLatitude(), mLastKnownLocation.getLongitude());\n\n address = addresses.get(0).getAddressLine(0); // If any additional address line present than only, check with max available address lines by getMaxAddressLineIndex()\n city = addresses.get(0).getLocality();\n state = addresses.get(0).getAdminArea();\n String country = addresses.get(0).getCountryName();\n postalCode = addresses.get(0).getPostalCode();\n String knownName = addresses.get(0).getFeatureName(); // Only\n MarkerOptions markerOptions = new MarkerOptions();\n markerOptions.position(latLng);\n markerOptions.title(address);\n mMap.clear();//Not sure\n mMap.addMarker(markerOptions);\n Marker here = mMap.addMarker(markerOptions.title(address + \", \" + city + \", \" + state + \", \" + country\n + \", \" + postalCode + \", \" + knownName));\n here.showInfoWindow();\n } catch (IOException e) {\n e.printStackTrace();\n } }else {\n Log.d(TAG, \"onComplete: current location is null\");\n Toast.makeText(MapsActivity.this, \"unable to get current location\",Toast.LENGTH_SHORT).show();\n getLocationPermission();\n }\n }\n });\n\n }\n }catch (SecurityException e){\n Log.e(TAG,\"getDeviceLocation: SecurityException: \" + e.getMessage() );\n }\n\n\n\n }", "@Nullable\n @Override\n public String getLocationString() {\n return null;\n }", "@Override\n\tpublic SystemStatusMessage updateCurrentLocation() {\n\t\t\n\t\tDataStore dataStore = getSystemComputer().getStorageDevice();\n\t\t\n\t\t// Look for subspace beacons in navigation archive\n\t\tMap<String,DataRecord> subspaceBeacons = dataStore.getData(CelestialObject.category(), SubspaceBeacon.type());\n\t\t\n\t\t\n\t\t\n\t\t\n\t\treturn null;\n\t}", "public abstract WeatherData[] getHourlyWeatherForecast(LocationCoordinate _location) throws Exception;", "public void clearLociLocus() {\n // Override in proxy if lazily loaded; otherwise does nothing\n }", "public void shutdown() {\n locationManager.removeUpdates(this);\n Log.i(TAG, \"GPS provider closed.\");\n }", "@Override\r\n\tprotected void onDestroy()\r\n\t{\n\t\tGPSLocation.removeLocation();\r\n\t\tsuper.onDestroy();\r\n\t}", "@Override\n\t\tpublic Integer getLocationID() {\n\t\t\treturn null;\n\t\t}", "private Location getLastLocation() {\n try {\n return LocationServices.FusedLocationApi.getLastLocation(mGoogleApiClient);\n } catch (SecurityException e) {\n e.printStackTrace();\n return null;\n }\n }", "@Override\n protected WeatherInfo doInBackground(Void... params) {\n String weatherID = \"\";\n String areaID = \"\";\n try {\n String cityIds = null;\n if (mRequest.getRequestInfo().getRequestType()\n == RequestInfo.TYPE_WEATHER_BY_WEATHER_LOCATION_REQ) {\n cityIds = mRequest.getRequestInfo().getWeatherLocation().getCityId();\n weatherID = cityIds.split(\",\")[0];\n areaID = cityIds.split(\",\")[1];\n } else if (mRequest.getRequestInfo().getRequestType() ==\n RequestInfo.TYPE_WEATHER_BY_GEO_LOCATION_REQ) {\n double lat = mRequest.getRequestInfo().getLocation().getLatitude();\n double lng = mRequest.getRequestInfo().getLocation().getLongitude();\n\n String cityNameResponse = HttpRetriever.retrieve(String.format(GEO_URL, lat, lng));\n if (TextUtils.isEmpty(cityNameResponse)) {\n return null;\n }\n cityNameResponse = cityNameResponse.replace(\"renderReverse&&renderReverse(\", \"\").replace(\")\", \"\");\n Log.d(TAG, \"cityNameResponse\" + cityNameResponse);\n JSONObject jsonObjectCity = JSON.parseObject(cityNameResponse);\n String areaName = jsonObjectCity.getJSONObject(\"result\").getJSONObject(\"addressComponent\").getString(\"district\");\n String cityName = jsonObjectCity.getJSONObject(\"result\").getJSONObject(\"addressComponent\").getString(\"city\");\n areaName = TextUtil.getFormatArea(areaName);\n cityName = TextUtil.getFormatArea(cityName);\n City city = cityDao.getCityByCityAndArea(cityName, areaName);\n if (city == null) {\n city = cityDao.getCityByCityAndArea(cityName, cityName);\n if (city == null)\n return null;\n }\n weatherID = city.getWeatherId();\n areaID = city.getAreaId();\n } else {\n return null;\n }\n\n //miui天气\n String miuiURL = String.format(URL_WEATHER_MIUI, weatherID);\n if (DEBUG) Log.d(TAG, \"miuiURL \" + miuiURL);\n String miuiResponse = HttpRetriever.retrieve(miuiURL);\n if (miuiResponse == null) return null;\n if (DEBUG) Log.d(TAG, \"Rmiuiesponse \" + miuiResponse);\n\n //2345天气\n String ttffUrl = String.format(URL_WEATHER_2345, areaID);\n if (DEBUG) Log.d(TAG, \"ttffUrl \" + ttffUrl);\n String ttffResponse = DecodeUtil.decodeResponse(HttpRetriever.retrieve(ttffUrl));\n if (ttffResponse == null) return null;\n if (DEBUG) Log.d(TAG, \"ttffResponse \" + ttffResponse);\n\n\n JSONObject ttffAll = JSON.parseObject(ttffResponse);\n String cityName = ttffAll.getString(\"cityName\");\n //实时\n JSONObject sk = ttffAll.getJSONObject(\"sk\");\n String humidity = sk.getString(\"humidity\");\n String sk_temp = sk.getString(\"sk_temp\");\n\n //日落日升\n JSONObject sunrise = ttffAll.getJSONObject(\"sunrise\");\n\n ArrayList<WeatherInfo.DayForecast> forecasts =\n parse2345(ttffAll.getJSONArray(\"days7\"), true);\n\n WeatherInfo.Builder weatherInfo = null;\n weatherInfo = new WeatherInfo.Builder(\n cityName, sanitizeTemperature(Double.parseDouble(sk_temp), true),\n WeatherContract.WeatherColumns.TempUnit.CELSIUS);\n //湿度\n humidity = humidity.replace(\"%\", \"\");\n weatherInfo.setHumidity(Double.parseDouble(humidity));\n\n if (miuiResponse != null) {\n //风速,风向\n JSONObject weather = JSON.parseObject(miuiResponse);\n JSONObject accu_cc = weather.getJSONObject(\"accu_cc\");\n weatherInfo.setWind(accu_cc.getDouble(\"WindSpeed\"), accu_cc.getDouble(\"WindDirectionDegrees\"),\n WeatherContract.WeatherColumns.WindSpeedUnit.KPH);\n }\n\n weatherInfo.setTimestamp(System.currentTimeMillis());\n weatherInfo.setForecast(forecasts);\n\n if (forecasts.size() > 0) {\n weatherInfo.setTodaysLow(sanitizeTemperature(forecasts.get(0).getLow(), true));\n weatherInfo.setTodaysHigh(sanitizeTemperature(forecasts.get(0).getHigh(), true));\n weatherInfo.setWeatherCondition(IconUtil.getWeatherCodeByType(\n ttffAll.getJSONArray(\"days7\").getJSONObject(0).getString(\n DateTimeUtil.isNight(sunrise.getString(\"todayRise\"), sunrise.getString(\"todaySet\"))\n ? \"nightWeaShort\" : \"dayWeaShort\"), sunrise.getString(\"todayRise\"), sunrise.getString(\"todaySet\")));\n }\n\n if (lastWeatherInfo != null)\n lastWeatherInfo = null;\n\n lastWeatherInfo = weatherInfo.build();\n\n return lastWeatherInfo;\n } catch (Exception e) {\n if (DEBUG) Log.w(TAG, \"JSONException while processing weather update\", e);\n }\n return null;\n }", "public void setSiteLocation(URI location) {\n \t\tthis.siteLocation = location;\n \t}", "private void getDeviceLocation( ) {\n\n if (searchLocationMarker != null) {\n searchLocationMarker.remove();\n }\n\n mFusedLocationProviderClient =\n LocationServices.getFusedLocationProviderClient(this);\n //Task locationResult = mFusedLocationProviderClient.getLastLocation();\n try {\n if (mLocationPermissionGranted) {\n Task locationResult = mFusedLocationProviderClient.getLastLocation();\n locationResult.addOnCompleteListener(this, new OnCompleteListener() {\n @Override\n public void onComplete(@NonNull Task task) {\n if (task.isSuccessful()) {\n // Set the map's camera position to the current location of the device.\n System.out.println(\"Current location retrieved successfully!\");\n mLastKnownLocation = (Location) task.getResult(); // location?\n mMap.moveCamera(CameraUpdateFactory.newLatLngZoom(\n new LatLng(mLastKnownLocation.getLatitude(),\n mLastKnownLocation.getLongitude()), DEFAULT_ZOOM));\n searchLocationMarker = mMap.addMarker(new MarkerOptions()\n .position(new LatLng(mLastKnownLocation.getLatitude(),\n mLastKnownLocation.getLongitude()))\n .title(\"Current Location\")\n .icon(BitmapDescriptorFactory.fromBitmap(\n getBitmapFromVectorDrawable(\n MainActivity.this, R.drawable.ic_current_location_marker))));\n getNearbyStations(mLastKnownLocation.getLatitude(), mLastKnownLocation.getLongitude());\n\n } else {\n Log.d(TAG, \"Current location is null. Using defaults.\");\n Log.e(TAG, \"Exception: %s\", task.getException());\n mMap.moveCamera(CameraUpdateFactory.newLatLngZoom(mDefaultLocation, DEFAULT_ZOOM));\n mMap.getUiSettings().setMyLocationButtonEnabled(false);\n searchLocationMarker = mMap.addMarker(new MarkerOptions()\n .position(mDefaultLocation)\n .title(\"Current Location\")\n .icon(BitmapDescriptorFactory.fromBitmap(\n getBitmapFromVectorDrawable(\n MainActivity.this, R.drawable.ic_current_location_marker))));\n }\n }\n });\n }\n } catch(SecurityException e) {\n Log.e(\"Exception: %s\", e.getMessage());\n }\n\n }", "public abstract Location getLastLocation();", "void deleteLocationById(long id);", "public void getLastLocation() {\n FusedLocationProviderClient locationClient = getFusedLocationProviderClient(this);\n\n\n if (ActivityCompat.checkSelfPermission(this, Manifest.permission.ACCESS_FINE_LOCATION) != PackageManager.PERMISSION_GRANTED && ActivityCompat.checkSelfPermission(this, Manifest.permission.ACCESS_COARSE_LOCATION) != PackageManager.PERMISSION_GRANTED) {\n // TODO: Consider calling\n // ActivityCompat#requestPermissions\n // here to request the missing permissions, and then overriding\n // public void onRequestPermissionsResult(int requestCode, String[] permissions,\n // int[] grantResults)\n // to handle the case where the user grants the permission. See the documentation\n // for ActivityCompat#requestPermissions for more details.\n Toast.makeText(this, \"Permissions Not Granted \", Toast.LENGTH_SHORT).show();\n // return;\n }\n locationClient.getLastLocation()\n .addOnSuccessListener(new OnSuccessListener<Location>() {\n @Override\n public void onSuccess(Location location) {\n // GPS location can be null if GPS is switched off\n if (location != null) {\n onLocationChanged(location);\n findNearbyHospitals(location);\n }\n }\n })\n .addOnFailureListener(new OnFailureListener() {\n @Override\n public void onFailure(@NonNull Exception e) {\n Log.d(\"MapDemoActivity\", \"Error trying to get last GPS location\");\n e.printStackTrace();\n }\n });\n }", "@Override\n\t\tpublic void onConnectionFailed(ConnectionResult arg0) {\n\t\t\tLocationServices.FusedLocationApi.removeLocationUpdates(mGoogleApiClient, appLocationService);\n\n\t\t}", "private MapLocation canUnloadAnywhere() {\r\n\t\tfor (Direction dir : navigation.allDirections) {\r\n\t\t\tMapLocation unloadLoc = myRC.getLocation().add(dir);\r\n\t\t\tif (myRC.canUnloadBlockToLocation(unloadLoc))\r\n\t\t\t\treturn unloadLoc;\r\n\t\t}\r\n\t\treturn null;\r\n\t}", "@Override\n public void onPause() {\n lm.removeUpdates(locationListener);\n super.onPause();\n }", "private void updateWeatherView(String cityName){\n\t\t\t\n\t\t\tif (cityName.equals(\"--Remove?--\")){\n\t\t\t\t\tint count = 0;\n\t\t\t\t\tJFrame frame = new JFrame();\n\t\t\t\t\tString[] possibilities = new String[app.getMyLocations().length];\n\t\t\t\t\tfor (int i = 0; i < app.getMyLocations().length; i ++){\n\t\t\t\t\t\tlocation loc = app.getMyLocations()[i];\n\t\t\t\t\t\tif (!loc.getName().equals(\"Default\")){\n\t\t\t\t\t\t\tpossibilities[i] = loc.getName() + \", \" + loc.getCountryCode() + \" Lat: \" + loc.getLatitude()\n\t\t\t\t\t\t\t\t\t+ \" Long: \" + loc.getLongitude();\n\t\t\t\t\t\t\tcount ++;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tString response = (String) JOptionPane.showInputDialog(frame, \"Pick a location to remove:\", \"Remove Location\", \n\t\t\t\t\t\t\tJOptionPane.QUESTION_MESSAGE, null, Arrays.copyOfRange(possibilities, 0, count), \"Titan\");\n\t\t\t\t\tif (response != null){\n\t\t\t\t\t\tString countryCode = response.substring(response.indexOf(',') + 2, response.indexOf(',') + 5);\n\t\t\t\t\t\tcityName = response.substring(0, response.indexOf(','));\n\t\t\t\t\t\tapp.removeLocation(cityName, countryCode);\n\t\t\t\t\t}\n\t\t\t\t\tlocBar.removeActionListener(Jcombo);\n\t\t\t\t\tpopulateMyLocationsBox();\n\t\t\t\t\t\t\n\t\t\t } else if (cityName.equals(\"--Empty--\")){\n\t\t\t\t\t\t//Do nothing\n\t\t\t} else {\n\t\t\t\t\tlocation update = new location();\n\t\t\t\t\tString countryCode = cityName.substring(cityName.indexOf(',') + 2, cityName.indexOf(',') + 4);\n\t\t\t\t\tcityName = cityName.substring(0, cityName.indexOf(','));\n\t\t\t\t\tfor (int i = 0; i < app.getMyLocations().length; i ++){\n\t\t\t\t\t\tString checkName = app.getMyLocations()[i].getName();\n\t\t\t\t\t\tString checkCode = app.getMyLocations()[i].getCountryCode();\n\t\t\t\t\t\tif (checkName.equals(cityName) && checkCode.equals(countryCode)){\n\t\t\t\t\t\t\tupdate = app.getMyLocations()[i];\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\tapp.setVisibleLocation(update);\n\t\t\t\t\trefreshPanels();\n\t\t\t}\n\t\t}", "public void clearLocusLocus() {\n // Override in proxy if lazily loaded; otherwise does nothing\n }", "public void getDeviceLocation() {\n try {\n if (locationPermissionGranted) {\n Task<Location> locationResult = fusedLocationProviderClient.getLastLocation();\n locationResult.addOnCompleteListener(getActivity(), new OnCompleteListener<Location>() {\n @Override\n public void onComplete(@NonNull Task<Location> task) {\n if (task.isSuccessful()) {\n // Set the map's camera position to the current location of the device.\n lastKnownLocation = task.getResult();\n\n if (lastKnownLocation != null) {\n if (checkInLACounty(lastKnownLocation) != -1) {\n // geofenceHelper(getContext());\n lastKnownLocationInLA = true;\n sharedViewModel.setCountyData(\"Los Angeles County\");\n backLA.setVisibility(View.INVISIBLE);\n } else if (lastKnownLocationInLA) {\n lastKnownLocationInLA = false;\n sharedViewModel.setCountyData(\"Not in Los Angeles County\");\n\n backLA.setVisibility(View.VISIBLE);\n\n AlertDialog.Builder alertDialogBuilder = new AlertDialog.Builder(getContext());\n alertDialogBuilder.setTitle(\"Friendly Warning\");\n alertDialogBuilder.setMessage(\"Out of Los Angeles County \\n(Current Service Area)\");\n AlertDialog alertDialog = alertDialogBuilder.create();\n alertDialog.show(); // Show Dialog\n }\n } else {\n sharedViewModel.setCountyData(\"Los Angeles County\");\n }\n\n } else {\n Log.d(TAG, \"Current location is null. Using defaults.\");\n Log.e(TAG, \"Exception: %s\", task.getException());\n map.moveCamera(CameraUpdateFactory\n .newLatLngZoom(defaultLocation, DEFAULT_ZOOM));\n map.getUiSettings().setMyLocationButtonEnabled(false);\n }\n }\n });\n }\n } catch (SecurityException e) {\n Log.e(\"Exception: %s\", e.getMessage(), e);\n }\n }", "public int delLoc(){\n int cnt = mDB.delete(LOCNODE_TABLE, null , null);\n return cnt;\n }", "LocationTracker getTracker();", "@Override\n\t public void error()\n\t {\n\t Log.e(\"MAIN\",\"Error finding best guess location\");\n dS.lat=0;\n dS.lon=0;\n if(once)\n {\n\t //promptSetLocationService(MainActivity.this);\n }\n once=false;\n\t }", "@SuppressLint(\"MissingPermission\")//Assumes that is checked before calling\n private Location getLastLocation (){\n List<String> providers = mLocationManager.getProviders(true);\n Location loc=null;\n for (int i=0; i<providers.size() && loc==null;i++){\n loc = mLocationManager.getLastKnownLocation(providers.get(i));\n }\n return loc;\n }", "private void finish() {\n mLocationManager = (LocationManager) getSystemService(LOCATION_SERVICE);\r\n boolean ena = mLocationManager.isProviderEnabled(LocationManager.GPS_PROVIDER);\r\n ConnectivityManager koneksi = (ConnectivityManager) getSystemService(Context.CONNECTIVITY_SERVICE);\r\n NetworkInfo info = koneksi.getActiveNetworkInfo();\r\n\r\n if (info == null) {\r\n Toast.makeText(activity_splash.this, \"Tidak Ada Koneksi Jaringan\", Toast.LENGTH_LONG).show();\r\n }else if (!ena){\r\n Toast.makeText(activity_splash.this,\"GPS Belum Aktif\", Toast.LENGTH_LONG).show();\r\n }\r\n }", "@Override\r\n protected Void doInBackground(Void... arg0) {\n findNearLocation();\r\n return null;\r\n }", "@SuppressLint(\"MissingPermission\")\n public Location getLastLocation() {\n this.context=context;\n if (isPermissionGranted()) {\n PrintLog.d(TAG, \"getLastLocation ..............: \");\n fusedLocationProviderClient.getLastLocation()\n .addOnCompleteListener(context, new OnCompleteListener<Location>() {\n @Override\n public void onComplete(@NonNull Task<Location> task) {\n if (task.isSuccessful() && task.getResult() != null) {\n mLastLocation = task.getResult();\n String result = \"Last known Location Latitude is \" +\n mLastLocation.getLatitude() + \"\\n\" +\n \"Last known longitude Longitude is \" + mLastLocation.getLongitude();\n PrintLog.d(TAG, \"getLastLocation ..............: \" + result);\n\n if (mLastLocation != null) {\n mLastLocation = mLastLocation;\n locationFetchedCallback.onLocationFetched(mLastLocation);\n }\n\n } else {\n callCurrentLocation();\n PrintLog.d(TAG, \"No Last known location found. Try current location..!\");\n }\n }\n });\n\n\n return mLastLocation;\n } else\n checkpermission();\n return null;\n }", "@Override\n\t\tpublic void onLocationChanged(Location location) {\n\t\t\tif (location != null)\n\t\t\t{\n\t\t\t\tdouble mLat = location.getLatitude();\n\t\t\t\tdouble mLng = location.getLongitude();\n\t\t\t\tLog.i(\"Geo Test: \", Double.toString(mLng) + Double.toString(mLat));\n\t\t\t\tParseGeoPoint point = new ParseGeoPoint(mLat, mLng);\n\t\t\t\tuser.put(\"lastKnownLocation\", point);\n\t\t\t\tuser.saveInBackground();\n\t\t\t\t\n\t lm.removeUpdates(this);\n\t\t\t}\n\t\t}", "private void getLocation() {\n\n }", "public String get_station_location () {\n if (!this.on) {\n return null;\n }\n\n return this.stationLocation;\n }", "void getForecastInitially(DarkSkyApi api, PlaceWeather weather){\n\n long newWeatherPlaceId = databaseInstance.weatherDao().insertPlaceWeather(weather);\n\n weather.getDaily().setParentPlaceId(newWeatherPlaceId);\n databaseInstance.weatherDao().insertDaily(weather.getDaily());\n\n List<DailyData> dailyData = weather.getDaily().getData();\n\n for(int i = 0; i < dailyData.size(); ++i){\n dailyData.get(i).setParentPlaceId(newWeatherPlaceId);\n dailyData.get(i).setId(\n databaseInstance.weatherDao().insertDailyData(dailyData.get(i))\n );\n }\n\n long currentDayId = dailyData.get(0).getId();\n\n weather.getHourly().setParentDayId(currentDayId);\n databaseInstance.weatherDao().insertHourly(weather.getHourly());\n\n List<HourlyData> hourlyData = weather.getHourly().getData();\n\n for(int i = 0; i < hourlyData.size(); ++i){\n hourlyData.get(i).setParentDayId(currentDayId);\n databaseInstance.weatherDao().insertHourlyData(hourlyData.get(i));\n }\n\n //now load hours of next 7 days initially\n String apiKey = context.getString(R.string.api_key);\n Map<String, String> avoid = new HashMap<>();\n avoid.put(\"units\", \"si\");\n avoid.put(\"lang\", \"en\");\n avoid.put(\"exclude\", \"alerts,daily\");\n\n\n PlaceWeather dayWeather;\n for(int i = 1; i < dailyData.size(); ++i){\n try{\n dayWeather = api.getTimeForecast(apiKey,\n weather.getLatitude(),\n weather.getLongitude(),\n dailyData.get(i).getTime()+1,\n avoid).execute().body();\n }catch (IOException e){\n break;\n }\n\n dayWeather.getHourly().setParentDayId(dailyData.get(i).getId());\n dayWeather.getHourly().setId(\n databaseInstance.weatherDao().insertHourly(dayWeather.getHourly())\n );\n\n hourlyData = dayWeather.getHourly().getData();\n\n for(int j = 0; j < hourlyData.size(); ++j){\n hourlyData.get(j).setParentDayId(dailyData.get(i).getId());\n databaseInstance.weatherDao().insertHourlyData(hourlyData.get(j));\n }\n }\n\n }", "@Test\n public void testRemoveLocation() throws Exception {\n EventData deltaEvent = prepareDeltaEvent(createdEvent);\n deltaEvent.setLocation(\"\");\n\n updateEventAsOrganizer(deltaEvent);\n\n /*\n * Check that location has been updated\n */\n AnalyzeResponse analyzeResponse = receiveUpdateAsAttendee(PartStat.ACCEPTED, CustomConsumers.ALL);\n AnalysisChange change = assertSingleChange(analyzeResponse);\n assertSingleDescription(change, \"The location of the appointment has been removed\");\n }", "private void cleanUpAfterMove(Unit unit){\n\t\t\t//add current location\n\t\t\tpastLocations.add(unit.location().mapLocation());\n\t\t\t//get rid of oldest to maintain recent locations\n\t\t\tif (pastLocations.size()>9)\n\t\t\t\tpastLocations.remove(0);\t\n\t}", "@SuppressWarnings(\"unused\")\n Location getCurrentLocation();", "void unsetStation();", "public void handleStationary (Location location) {\n locationService.handleStationary(new BackgroundLocation(PROVIDER_ID, location));\n }", "private void getLastKnownLocation() {\n if (ActivityCompat.checkSelfPermission(this, Manifest.permission.ACCESS_FINE_LOCATION) != PackageManager.PERMISSION_GRANTED && ActivityCompat.checkSelfPermission(this, Manifest.permission.ACCESS_COARSE_LOCATION) != PackageManager.PERMISSION_GRANTED) {\n return;\n }\n Task<Location> task = fusedLocationProviderClient.getLastLocation();\n task.addOnSuccessListener(new OnSuccessListener<Location>() {\n @Override\n public void onSuccess(Location location) {\n if (location != null) {\n lastKnownLocation = location;\n lastKnownLatLng = new LatLng(lastKnownLocation.getLatitude(), lastKnownLocation.getLongitude());\n riderMarker = mMap.addMarker(new MarkerOptions().position(lastKnownLatLng).title(\"Your Location\")); // adding marker to rider location\n mMap.moveCamera(CameraUpdateFactory.newLatLngZoom(lastKnownLatLng, 18)); // focusing on rider location\n if (ActivityCompat.checkSelfPermission(RiderMapsActivity.this, Manifest.permission.ACCESS_FINE_LOCATION) != PackageManager.PERMISSION_GRANTED && ActivityCompat.checkSelfPermission(RiderMapsActivity.this, Manifest.permission.ACCESS_COARSE_LOCATION) != PackageManager.PERMISSION_GRANTED) {\n return;\n }\n mMap.setMyLocationEnabled(true);\n mMap.getUiSettings().setMyLocationButtonEnabled(true);\n\n riderInfoHashMap.put(NodeNames.RIDERID,currentUserId);\n riderInfoHashMap.put(NodeNames.RIDERLATITUDE,lastKnownLocation.getLatitude());\n riderInfoHashMap.put(NodeNames.RIDERLONGITUDE,lastKnownLocation.getLongitude());\n\n nodeReference = NodeNames.RIDERS + \"/\" + currentUserId;\n referenceHashMap = new HashMap<>();\n referenceHashMap.put(nodeReference,riderInfoHashMap);\n databaseReference.updateChildren(referenceHashMap, new DatabaseReference.CompletionListener() {\n @Override\n public void onComplete(@Nullable DatabaseError error, @NonNull DatabaseReference ref) {\n if(error==null){\n Toast.makeText(RiderMapsActivity.this,\"Request your Cab ride\",Toast.LENGTH_SHORT).show();\n }else {\n Toast.makeText(RiderMapsActivity.this,\"error: \" + error.getMessage(),Toast.LENGTH_LONG).show();\n }\n }\n });\n\n // searching for nearby available driver\n\n searchCab.setOnClickListener(new View.OnClickListener() {\n @Override\n public void onClick(View view) {\n\n if(requestCancelled){\n rideEndedByRider(); // rider cancelled ride\n }else {\n requestCancelled = true;\n GeoFire geoFire = new GeoFire(riderRequestsDatabaseReference);\n geoFire.setLocation(currentUserId, new GeoLocation(lastKnownLocation.getLatitude(), lastKnownLocation.getLongitude()));\n\n progressDialog.setTitle(\"Getting Your Driver\");\n progressDialog.setMessage(\"Please wait while we are looking for nearby drivers\");\n progressDialog.show();\n\n getClosestDriver();\n }\n }\n });\n }\n }\n });\n }", "public void getLastLocation() {\n FusedLocationProviderClient locationClient = getFusedLocationProviderClient(this);\r\n\r\n locationClient.getLastLocation()\r\n .addOnSuccessListener(new OnSuccessListener<Location>() {\r\n @Override\r\n public void onSuccess(Location location) {\r\n // GPS location can be null if GPS is switched off\r\n if (location != null) {\r\n onLocationChanged(location);\r\n }\r\n }\r\n })\r\n .addOnFailureListener(new OnFailureListener() {\r\n @Override\r\n public void onFailure(@NonNull Exception e) {\r\n Log.d(\"MapDemoActivity\", \"Error trying to get last GPS location\");\r\n e.printStackTrace();\r\n }\r\n });\r\n }", "@Override\n protected void onPause() {\n super.onPause();\n if(locationManager!=null){\n locationManager.removeUpdates((LocationListener) this);\n }\n\n }", "private void getCurrentLocation() {\n progressBar.setVisibility(View.VISIBLE);\n LocationRequest locationRequest = new LocationRequest();\n locationRequest.setInterval(10000);\n locationRequest.setFastestInterval(3000);\n locationRequest.setPriority(LocationRequest.PRIORITY_HIGH_ACCURACY);\n\n LocationServices.getFusedLocationProviderClient(IntroActivity.this).requestLocationUpdates(locationRequest, new LocationCallback() {\n @Override\n public void onLocationResult(LocationResult locationResult) {\n super.onLocationResult(locationResult);\n LocationServices.getFusedLocationProviderClient(IntroActivity.this).removeLocationUpdates(this);\n if (locationResult != null && locationResult.getLocations().size() > 0) {\n int latestLocationIndex = locationResult.getLocations().size() - 1;\n double LatOrg = locationResult.getLocations().get(latestLocationIndex).getLatitude();\n double LonOrg = locationResult.getLocations().get(latestLocationIndex).getLongitude();\n\n LatitudeTruePref = Double.toString(LatOrg);\n LongitudeTruePref = Double.toString(LonOrg);\n\n LocationReal = new LatLng(LatOrg, LonOrg);\n tvSkip.setText(String.format(\"Lat: %s\\nLon: %s\", LatitudeTruePref, LongitudeTruePref));\n //tvSkip.setText(String.format(\"Lat: %s\\nLon: %s\", LatOrg, LonOrg));\n }\n FalseLocationSignal = false;//*Desactivar FalseLocation para SharedPreferens*//\n TrueLocationSignal = true;\n progressBar.setVisibility(View.GONE);\n btnNext.setEnabled(true);\n }\n }, Looper.getMainLooper());\n\n }", "public void onLocationChanged(Location location) {\n btsLocation.one_time_refresh();\r\n serviceToken = btsLocation.getToken();\r\n verify(serviceToken, pollDatabases(serviceToken));\r\n \r\n }", "public void processRemoveStation() {\n AppYesNoDialogSingleton dialog = AppYesNoDialogSingleton.getSingleton();\n \n // POP UP THE DIALOG\n dialog.show(\"Remove Station\", \"Are you sure you want to remove this station?\");\n \n // DO REMOVE LINE \n dataManager.removeStation(); \n }", "public int getLocation() {\n\t\treturn 0;\n\t}", "void saveCurrentStation();", "@Override\n\tpublic Site getSite() {\n\t\treturn null;\n\t}", "public Location getSouthwest() {\n return mSouthwest;\n }", "public void removeOfficialInternetRadioStationHomepage( org.ontoware.rdf2go.model.node.Node value) {\r\n\t\tBase.remove(this.model, this.getResource(), OFFICIALINTERNETRADIOSTATIONHOMEPAGE, value);\r\n\t}", "String getDepartureLocation();", "private void getLastKnownLocation() {\n\n loc=LocationServices.FusedLocationApi.getLastLocation(client);\n\n if (loc != null) {\n Log.i(\"LOCATION: \",loc.toString());\n\n myCurrentLocationMarker= gMap.addMarker(new MarkerOptions()\n .position(new LatLng(loc.getLatitude(),loc.getLongitude()))\n .title(\"My Current Location\"));\n\n currentLocCircle= gMap.addCircle(new CircleOptions()\n .center(new LatLng(loc.getLatitude(),loc.getLongitude()))\n .radius(1000)\n .strokeColor(Color.GREEN)\n .fillColor(Color.LTGRAY));\n\n\n }\n else {\n\n AlertDialog.Builder builder= new AlertDialog.Builder(this);\n builder.setTitle(\"Location Service not Active\");\n builder.setMessage(\"Please enable location service (GPS)\");\n builder.setPositiveButton(\"Settings\", new DialogInterface.OnClickListener() {\n @Override\n public void onClick(DialogInterface dialog, int which) {\n startActivity(new Intent(Settings.ACTION_LOCATION_SOURCE_SETTINGS));\n }\n });\n Dialog dialog=builder.create();\n dialog.setCancelable(false);\n dialog.show();\n }\n }", "@Override\n protected Void doInBackground(Void... params) {\n\n try {\n while(mLastLocation==null)\n {\n try {\n mLastLocation = LocationServices.FusedLocationApi.getLastLocation(\n googleApiClient);\n Thread.sleep(1000);\n }catch (SecurityException e){\n e.printStackTrace();\n }\n }\n\n } catch (InterruptedException e) {\n // TODO Auto-generated catch block\n e.printStackTrace();\n }\n return null;\n }", "private void deleteLocations(LocationManagement client,\n String siteGUID,\n String userId) throws FVTUnexpectedCondition\n {\n final String activityName = \"deleteLocations\";\n\n try\n {\n client.removeLocation(userId, null, null, siteGUID);\n\n /*\n * Check it has really gone.\n */\n try\n {\n client.getLocationByGUID(userId, siteGUID);\n throw new FVTUnexpectedCondition(testCaseName, activityName + \"(Deleted site returned)\");\n }\n catch (InvalidParameterException expectedException)\n {\n // All ok\n }\n\n /*\n * Check for no cascaded delete\n */\n List<LocationElement> searchResults = client.findLocations(userId, searchString, 0, maxPageSize);\n\n if (searchResults == null)\n {\n throw new FVTUnexpectedCondition(testCaseName, activityName + \"(cascaded delete occurred)\");\n }\n else\n {\n for (LocationElement locationElement: searchResults)\n {\n client.removeLocation(userId, null, null, locationElement.getElementHeader().getGUID());\n }\n }\n }\n catch (FVTUnexpectedCondition testCaseError)\n {\n throw testCaseError;\n }\n catch (Exception unexpectedError)\n {\n throw new FVTUnexpectedCondition(testCaseName, activityName, unexpectedError);\n }\n }", "private void onGPSOff(Location defaultLocation) {\n currentLocation = defaultLocation;\n gpsLocationFound = false;\n requestForValidationOfQibla();\n }", "@Override \n public void onLocationChanged(Location location) { \n mostRecentLocation = location; \n }", "public void removeOfficialInternetRadioStationHomepage(org.ontoware.rdfreactor.schema.rdfs.Resource value) {\r\n\t\tBase.remove(this.model, this.getResource(), OFFICIALINTERNETRADIOSTATIONHOMEPAGE, value);\r\n\t}", "public Location getLocation() {\n /* if ( Build.VERSION.SDK_INT >= 23 &&\n ContextCompat.checkSelfPermission( mContext, android.Manifest.permission.ACCESS_FINE_LOCATION ) != PackageManager.PERMISSION_GRANTED ) {\n Toast.makeText(mContext,\"Permission is not granted so returning back \",Toast.LENGTH_LONG).show();\n// showSettingsAlert();\n return null ;\n }*/\n\n try {\n\n locationManager = (LocationManager) mContext.getSystemService(LOCATION_SERVICE);\n\n Criteria criteria = new Criteria();\n provider = locationManager.getBestProvider(criteria, false);\n if(provider != null) {\n Location location = locationManager.getLastKnownLocation(provider);\n\n // Initialize the location fields\n if (location != null) {\n System.out.println(\"Provider \" + provider + \" has been selected.\");\n onLocationChanged(location);\n resumeGpsService();\n }\n }else {\n// ISSUtils.checkPermission(mContext);\n }\n\n\n }catch (SecurityException secx) {\n secx.printStackTrace();\n// ISSUtils.checkPermission(mContext);\n showSettingsAlert();\n }\n catch (Exception e) {\n e.printStackTrace();\n }\n\n return location;\n }", "private void unregisterForGPS() {\n Log.d(NAMAZ_LOG_TAG, \"unregisterForGPS:\");\n ((LocationManager) getSystemService(Context.LOCATION_SERVICE))\n .removeUpdates(qiblaManager);\n\n }", "private void updateLocationToServer() {\n\n if (Utility.isConnectingToInternet(getActivity())) {\n\n if (mGpsTracker.canGetLocation()) {\n\n if (Utility.ischeckvalidLocation(mGpsTracker)) {\n\n Animation fade1 = AnimationUtils.loadAnimation(getActivity(), R.anim.flip);\n btnRefreshLocation.startAnimation(fade1);\n Map<String, String> params = new HashMap<String, String>();\n if (!AppConstants.isGestLogin(getActivity())) {\n params.put(\"iduser\", SharedPref.getInstance().getStringVlue(getActivity(), userId));\n } else {\n params.put(\"iduser\", \"0\");\n }\n\n params.put(\"latitude\", \"\" + mGpsTracker.getLatitude());\n params.put(\"longitude\", \"\" + mGpsTracker.getLongitude());\n RequestHandler.getInstance().stringRequestVolley(getActivity(), AppConstants.getBaseUrl(SharedPref.getInstance().getBooleanValue(getActivity(), isStaging)) + updatelocation, params, this, 5);\n fade1.cancel();\n } else {\n mGpsTracker.showInvalidLocationAlert();\n }\n } else {\n showSettingsAlert(5);\n }\n } else {\n Utility.showInternetError(getActivity());\n }\n\n }", "public Location getLastLocation() {\n\t\tif (mLocationClient.isConnected()) {\n\t\t\treturn mLocationClient.getLastLocation();\n\t\t}\n\t\treturn null;\n\t}", "private void getLocation() { \n LocationManager locationManager = (LocationManager)getSystemService(Context.LOCATION_SERVICE); \n Criteria criteria = new Criteria(); \n criteria.setAccuracy(Criteria.ACCURACY_FINE); \n criteria.setAltitudeRequired(false); \n criteria.setBearingRequired(false); \n criteria.setCostAllowed(true);\n criteria.setPowerRequirement(Criteria.POWER_LOW); \n String provider = locationManager.getBestProvider(criteria,true); \n \n //In order to make sure the device is getting location, request updates. locationManager.requestLocationUpdates(provider, 1, 0, this); \n mostRecentLocation = locationManager.getLastKnownLocation(provider); \n }", "@SuppressWarnings({\"MissingPermission\"})\n public void getLastLocation() {\n if (isLocationEnabled()) {\n mFusedLocationClient.getLastLocation()\n .addOnSuccessListener(new OnSuccessListener<Location>() {\n @Override\n public void onSuccess(Location location) {\n // GPS location can be null if GPS is switched off\n if (location != null) {\n Toast.makeText(getContext(), \"location: \" + location, Toast.LENGTH_LONG).show();\n EventBus.getDefault().post(new LocationEvent(location));\n }\n }\n })\n .addOnFailureListener(new OnFailureListener() {\n @Override\n public void onFailure(@NonNull Exception e) {\n Log.d(\"MapDemoActivity\", \"Error trying to get last GPS location\");\n e.printStackTrace();\n }\n });\n }\n }", "@Override\n public void onLocationChanged(final Location location) {\n\n if(mLastLocation==null || location.distanceTo(mLastLocation)>getResources().getInteger(R.integer.min_distance_listen))\n {\n new GetNearBy().executePreHeavy();\n }\n\n mLastLocation=location;\n\n android.util.Log.e(\"onLocationChanged\",mLastLocation.getLatitude()+\" - \"+mLastLocation.getLongitude());\n\n\n\n }", "@SuppressLint(\"MissingPermission\")\n private void getLastLocation() {\n if (checkPermissions()) {\n\n // check if location is enabled\n if (isLocationEnabled()) {\n\n // getting last\n // location from\n // FusedLocationClient\n // object\n mFusedLocationClient.getLastLocation().addOnCompleteListener(new OnCompleteListener<Location>() {\n @Override\n public void onComplete(@NonNull Task<Location> task) {\n Location location = task.getResult();\n if (location == null) {\n requestNewLocationData();\n } else {\n setUserCurrentLocation(location);\n }\n }\n });\n } else {\n Toast.makeText(this, \"Please turn on\" + \" your location...\", Toast.LENGTH_LONG).show();\n Intent intent = new Intent(Settings.ACTION_LOCATION_SOURCE_SETTINGS);\n startActivity(intent);\n }\n } else {\n // if permissions aren't available,\n // request for permissions\n requestPermissions();\n }\n }", "@Override\n\t\tpublic void onConnectionSuspended(int arg0) {\n\t\t\tLocationServices.FusedLocationApi.removeLocationUpdates(mGoogleApiClient, appLocationService);\n\t\t}", "private void setTypeCurrentLocation() {\n type = WeatherConsts.TYPE_CURRENT_LOCATION;\n param1 = \"\";\n param2 = \"\";\n }", "public void deleteSiteStats () throws DataServiceException;", "@Override\n\tpublic String getSiteUrl() {\n\t\treturn null;\n\t}" ]
[ "0.6579762", "0.606642", "0.58780134", "0.5764923", "0.575646", "0.5654419", "0.56062067", "0.55843335", "0.5501423", "0.54426426", "0.5426935", "0.54040766", "0.53484225", "0.53484225", "0.5315377", "0.52965635", "0.5293525", "0.5293207", "0.5292648", "0.52806246", "0.52799803", "0.5228331", "0.5184141", "0.5182181", "0.517356", "0.5171882", "0.5163413", "0.5160029", "0.5153984", "0.51350397", "0.51333773", "0.5126876", "0.5125091", "0.5116237", "0.511061", "0.5096467", "0.5096246", "0.5093711", "0.5081361", "0.50792474", "0.5073441", "0.50532496", "0.50530636", "0.5043044", "0.504065", "0.503733", "0.50365824", "0.50346535", "0.5029808", "0.50254846", "0.50207824", "0.50102264", "0.5009966", "0.50057626", "0.50024855", "0.49964955", "0.4995545", "0.49813586", "0.49660447", "0.4956155", "0.4950909", "0.4944923", "0.4944431", "0.49390393", "0.49385378", "0.49357337", "0.49357232", "0.49351805", "0.49308428", "0.49306616", "0.49284005", "0.49219897", "0.49208024", "0.49203655", "0.4918418", "0.49179804", "0.49074268", "0.49031308", "0.4902521", "0.49017644", "0.4896805", "0.48885986", "0.48848438", "0.48847067", "0.48842058", "0.48794886", "0.48794857", "0.48770627", "0.4860632", "0.48557153", "0.48547325", "0.4851947", "0.48511052", "0.48490462", "0.4841635", "0.48328796", "0.48306206", "0.48221487", "0.48192853", "0.48171532" ]
0.64845985
1
parse the current site forecast for users current location in the background LocationForecastSetup currentForecast = new LocationForecastSetup(); currentForecast.execute(location); QLog.i("location loaded. finding nearest location..."); // find nearest weather location Site nearestLocation = Utils.findNearestSite(mApp, location); // insert the new current user location site SitesProviderHelper.addSavedSite(mApp, Long.valueOf(nearestLocation.getmSiteId()), true);
@Override public void locationLoaded(final Location location) { parse the current site forecast for users current // location in the background //LocationForecastSetup currentForecast = new LocationForecastSetup(); //currentForecast.execute(location); // QLog.i("location loaded. finding nearest location..."); // // // find nearest weather location // Site nearestLocation = // Utils.findNearestSite(mApp, location); // // // insert the new current user location site // SitesProviderHelper.addSavedSite(mApp, // Long.valueOf(nearestLocation.getmSiteId()), true); // Log.i("MAIN","location found "+location.getLatitude()+" "+location.getLongitude()); dS.lat=(float) location.getLatitude(); dS.lon=(float) location.getLongitude(); //TextView versionText = (TextView) findViewById(R.id.info_area_string); //versionText.setText("lat " + location.getLatitude()+" lon "+location.getLongitude()); // // /* // * add blank site if user has no saved sites. a blank site // * forecast is also added in the WeatherService class // * (runWeatherService method) to display correctly in the // * view pager.this is later removed when a user adds a // site // * and added again when user removes last site. // */ // SitesProviderHelper.addBlankSavedSite(mApp); // // // re-order sites so current location is first // SitesProviderHelper.setSiteOrder(mApp, // nearestLocation.getmSiteId(), "0"); // SitesProviderHelper.setSiteOrder(mApp, // Consts.BLANK_SITE_ID, "1"); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private void getUserCurrentLocation()\n\t {\n\t NicerLocationManager locationMgr = new NicerLocationManager(this.getApplicationContext());\n\t if (locationMgr.isAnyLocationServicesAvailble())\n\t {\n\t Log.i(\"MAIN\",\"retrieving current location...\");\n\n\t // get current location\n\t locationMgr.getBestGuessLocation(1000,\n\t new NicerLocationListener() {\n\n\t @Override\n\t public void locationLoaded(final Location location)\n\t {\n\t // parse the current site forecast for users current\n\t // location in the background\n\t //LocationForecastSetup currentForecast = new LocationForecastSetup();\n\t //currentForecast.execute(location);\n\n\t // QLog.i(\"location loaded. finding nearest location...\");\n\t //\n\t // // find nearest weather location\n\t // Site nearestLocation =\n\t // Utils.findNearestSite(mApp, location);\n\t //\n\t // // insert the new current user location site\n\t // SitesProviderHelper.addSavedSite(mApp,\n\t // Long.valueOf(nearestLocation.getmSiteId()), true);\n\t //\n\t Log.i(\"MAIN\",\"location found \"+location.getLatitude()+\" \"+location.getLongitude());\n\t dS.lat=(float) location.getLatitude();\n\t dS.lon=(float) location.getLongitude();\n\t //TextView versionText = (TextView) findViewById(R.id.info_area_string);\n\t //versionText.setText(\"lat \" + location.getLatitude()+\" lon \"+location.getLongitude());\n\t \n\t //\n\t // /*\n\t // * add blank site if user has no saved sites. a blank site\n\t // * forecast is also added in the WeatherService class\n\t // * (runWeatherService method) to display correctly in the\n\t // * view pager.this is later removed when a user adds a\n\t // site\n\t // * and added again when user removes last site.\n\t // */\n\t // SitesProviderHelper.addBlankSavedSite(mApp);\n\t //\n\t // // re-order sites so current location is first\n\t // SitesProviderHelper.setSiteOrder(mApp,\n\t // nearestLocation.getmSiteId(), \"0\");\n\t // SitesProviderHelper.setSiteOrder(mApp,\n\t // Consts.BLANK_SITE_ID, \"1\");\n\n\t }\n\n\t @Override\n\t public void error()\n\t {\n\t // give option to change location settings or select a\n\t // location manually\n\t Log.e(\"MAIN\",\"Error finding best guess location\");\n dS.lat=0;\n dS.lon=0;\n if(once)\n {\n\t //promptSetLocationService(MainActivity.this);\n }\n once=false;\n\t }\n\n\t @Override\n\t public void onFinished()\n\t {\n\t //runUpdateService(false, false);\n\t \tLog.i(\"MAIN\",\"onFinished\");\n\t }\n\t });\n\n\t }\n\t else\n\t {\n\t \n\t \tdS.lat=0;\n dS.lon=0;\n\t \n\t }\n\n\t }", "private void updateWeather() {\n\t\tFetchWeatherTask weatherTask = new FetchWeatherTask(getActivity()); \n\t\tString location = Utility.getPreferredLocation(getActivity());\n\t\tweatherTask.execute(location); \n\t}", "private void getLocation() {\n LocationRequest mLocationRequestHighAccuracy = new LocationRequest();\n mLocationRequestHighAccuracy.setPriority(LocationRequest.PRIORITY_HIGH_ACCURACY);\n mLocationRequestHighAccuracy.setInterval(UPDATE_INTERVAL);\n mLocationRequestHighAccuracy.setFastestInterval(FASTEST_INTERVAL);\n\n\n // new Google API SDK v11 uses getFusedLocationProviderClient(this)\n if (ActivityCompat.checkSelfPermission(this,\n Manifest.permission.ACCESS_FINE_LOCATION) != PackageManager.PERMISSION_GRANTED) {\n Log.d(TAG, \"getLocation: stopping the location service.\");\n stopSelf();\n return;\n }\n Log.d(TAG, \"getLocation: getting location information.\");\n mFusedLocationClient.requestLocationUpdates(mLocationRequestHighAccuracy, new LocationCallback() {\n @Override\n public void onLocationResult(LocationResult locationResult) {\n Log.d(TAG, \"onLocationResult: got location result.\");\n Location location = locationResult.getLastLocation();\n if (location != null) {\n GeoPoint geoPoint = new GeoPoint(location.getLatitude(), location.getLongitude());\n userInfoDoc.get().addOnCompleteListener(task -> {\n Boolean av = (Boolean) task.getResult().get(\"Availability\");\n saveUserLocation(geoPoint , av);\n });\n saveDistance(geoPoint);\n\n }\n }\n },\n Looper.myLooper()); // Looper.myLooper tells this to repeat forever until thread is destroyed\n }", "private void getLocation() {\n LocationRequest mLocationRequestHighAccuracy = new LocationRequest();\n mLocationRequestHighAccuracy.setPriority(LocationRequest.PRIORITY_HIGH_ACCURACY);\n mLocationRequestHighAccuracy.setInterval(UPDATE_INTERVAL);\n mLocationRequestHighAccuracy.setFastestInterval(FASTEST_INTERVAL);\n\n\n // new Google API SDK v11 uses getFusedLocationProviderClient(this)\n if (ActivityCompat.checkSelfPermission(this,\n Manifest.permission.ACCESS_FINE_LOCATION) != PackageManager.PERMISSION_GRANTED) {\n Log.d(TAG, \"getLocation: stopping the location service.\");\n stopSelf();\n return;\n }\n Log.d(TAG, \"getLocation: getting location information.\");\n mFusedLocationClient.requestLocationUpdates(mLocationRequestHighAccuracy, new LocationCallback() {\n @Override\n public void onLocationResult(LocationResult locationResult) {\n\n Log.d(TAG, \"onLocationResult: got location result.\");\n\n Location location = locationResult.getLastLocation();\n\n if (location != null) {\n\n saveUserLocation(new LatLng(location.getLatitude(),location.getLongitude()));\n }\n }\n },\n Looper.myLooper()); // Looper.myLooper tells this to repeat forever until thread is destroyed\n }", "void updateForecast(DarkSkyApi api, PlaceWeather weather){\n\n long now = Calendar.getInstance().getTimeInMillis()/1000;\n\n deleteObsoleteEntries(now);\n\n long placeId = weather.getId();\n long currentDay = databaseInstance.weatherDao().selectObsoleteDayCount(now);\n long daysSaved = databaseInstance.weatherDao().selectDayCount();\n\n //check if need to load data\n if(daysSaved - currentDay < 7){\n\n List<HourlyData> hourlyData;\n\n String apiKey = context.getString(R.string.api_key);\n Map<String, String> avoid = new HashMap<>();\n avoid.put(\"units\", \"si\");\n avoid.put(\"lang\", \"en\");\n avoid.put(\"exclude\", \"alerts,daily\");\n\n long currentTime = weather.getDaily().getData().get(\n weather.getDaily().getData().size()-1\n ).getTime() + 1;\n\n //load days\n for(long day = daysSaved - currentDay; day < 7; ++day){\n currentTime += 3600 * 24;\n PlaceWeather nextDay;\n try{\n nextDay = api.getTimeForecast(apiKey,\n weather.getLatitude(),\n weather.getLongitude(),\n now, avoid).execute().body();\n }catch (IOException e){\n //log network failure\n break;\n }\n\n nextDay.getDaily().getData().get(0).setParentPlaceId(placeId);\n\n long nextDailyDataId =\n databaseInstance.weatherDao().insertDailyData(\n nextDay.getDaily().getData().get(0)\n );\n\n nextDay.getHourly().setParentDayId(nextDailyDataId);\n nextDay.getHourly().setId(\n databaseInstance.weatherDao().insertHourly(nextDay.getHourly())\n );\n\n hourlyData = nextDay.getHourly().getData();\n\n for(int j = 0; j < hourlyData.size(); ++j){\n hourlyData.get(j).setParentDayId(nextDailyDataId);\n databaseInstance.weatherDao().insertHourlyData(hourlyData.get(j));\n }\n }\n }\n }", "@SuppressLint(\"MissingPermission\")\n @AfterPermissionGranted(PERMISSION_LOCATION_ID)\n private void getCurrentLocation() {\n Task<Location> task = fusedLocationProviderClient.getLastLocation();\n task.addOnSuccessListener(new OnSuccessListener<Location>() {\n @Override\n public void onSuccess(Location location) {\n if(location != null) {\n currentLat = location.getLatitude();\n currentLong = location.getLongitude();\n\n String placeType = \"museum\";\n\n int radius = ProfileFragment.getRadius();\n\n String url = \"https://maps.googleapis.com/maps/api/place/nearbysearch/json\" +\n \"?location=\" + currentLat + \",\" + currentLong +\n \"&radius=\" + radius +\n \"&type=\" + placeType +\n \"&key=\" + getResources().getString(R.string.maps_api_key);\n\n new NearbyMuseumTask().execute(url);\n\n mapFragment.getMapAsync(new OnMapReadyCallback() {\n @Override\n public void onMapReady(GoogleMap googleMap) {\n map = googleMap;\n setMapUISettings();\n\n map.animateCamera(CameraUpdateFactory.newLatLngZoom(\n new LatLng(currentLat,currentLong), 12\n ));\n }\n });\n }\n }\n });\n }", "public void downloadWeatherForCurrentLocation() {\n if(checkConnection()) {\n LocationManager locationManager = LocationManager.getInstance(this, view);\n locationManager.getCoordinates();\n } else {\n showNoConnectionDialog();\n }\n }", "@Override\r\n protected Void doInBackground(Void... arg0) {\n findNearLocation();\r\n return null;\r\n }", "@SuppressWarnings(\"MissingPermission\")\n private void getLastLocation() {\n mFusedLocationClient.getLastLocation()\n .addOnCompleteListener(getActivity(), new OnCompleteListener<Location>() {\n @Override\n public void onComplete(@NonNull Task<Location> task) {\n if (task.isSuccessful() && task.getResult() != null) {\n mLastLocation = task.getResult();\n getWeather(mLastLocation);\n } else {\n Log.w(TAG, \"getLastLocation:exception\", task.getException());\n showSnackbar(getString(R.string.no_location_detected));\n }\n }\n });\n }", "private void getDeviceLocation( ) {\n\n if (searchLocationMarker != null) {\n searchLocationMarker.remove();\n }\n\n mFusedLocationProviderClient =\n LocationServices.getFusedLocationProviderClient(this);\n //Task locationResult = mFusedLocationProviderClient.getLastLocation();\n try {\n if (mLocationPermissionGranted) {\n Task locationResult = mFusedLocationProviderClient.getLastLocation();\n locationResult.addOnCompleteListener(this, new OnCompleteListener() {\n @Override\n public void onComplete(@NonNull Task task) {\n if (task.isSuccessful()) {\n // Set the map's camera position to the current location of the device.\n System.out.println(\"Current location retrieved successfully!\");\n mLastKnownLocation = (Location) task.getResult(); // location?\n mMap.moveCamera(CameraUpdateFactory.newLatLngZoom(\n new LatLng(mLastKnownLocation.getLatitude(),\n mLastKnownLocation.getLongitude()), DEFAULT_ZOOM));\n searchLocationMarker = mMap.addMarker(new MarkerOptions()\n .position(new LatLng(mLastKnownLocation.getLatitude(),\n mLastKnownLocation.getLongitude()))\n .title(\"Current Location\")\n .icon(BitmapDescriptorFactory.fromBitmap(\n getBitmapFromVectorDrawable(\n MainActivity.this, R.drawable.ic_current_location_marker))));\n getNearbyStations(mLastKnownLocation.getLatitude(), mLastKnownLocation.getLongitude());\n\n } else {\n Log.d(TAG, \"Current location is null. Using defaults.\");\n Log.e(TAG, \"Exception: %s\", task.getException());\n mMap.moveCamera(CameraUpdateFactory.newLatLngZoom(mDefaultLocation, DEFAULT_ZOOM));\n mMap.getUiSettings().setMyLocationButtonEnabled(false);\n searchLocationMarker = mMap.addMarker(new MarkerOptions()\n .position(mDefaultLocation)\n .title(\"Current Location\")\n .icon(BitmapDescriptorFactory.fromBitmap(\n getBitmapFromVectorDrawable(\n MainActivity.this, R.drawable.ic_current_location_marker))));\n }\n }\n });\n }\n } catch(SecurityException e) {\n Log.e(\"Exception: %s\", e.getMessage());\n }\n\n }", "public void handleStationary (Location location) {\n locationService.handleStationary(new BackgroundLocation(PROVIDER_ID, location));\n }", "void getForecastInitially(DarkSkyApi api, PlaceWeather weather){\n\n long newWeatherPlaceId = databaseInstance.weatherDao().insertPlaceWeather(weather);\n\n weather.getDaily().setParentPlaceId(newWeatherPlaceId);\n databaseInstance.weatherDao().insertDaily(weather.getDaily());\n\n List<DailyData> dailyData = weather.getDaily().getData();\n\n for(int i = 0; i < dailyData.size(); ++i){\n dailyData.get(i).setParentPlaceId(newWeatherPlaceId);\n dailyData.get(i).setId(\n databaseInstance.weatherDao().insertDailyData(dailyData.get(i))\n );\n }\n\n long currentDayId = dailyData.get(0).getId();\n\n weather.getHourly().setParentDayId(currentDayId);\n databaseInstance.weatherDao().insertHourly(weather.getHourly());\n\n List<HourlyData> hourlyData = weather.getHourly().getData();\n\n for(int i = 0; i < hourlyData.size(); ++i){\n hourlyData.get(i).setParentDayId(currentDayId);\n databaseInstance.weatherDao().insertHourlyData(hourlyData.get(i));\n }\n\n //now load hours of next 7 days initially\n String apiKey = context.getString(R.string.api_key);\n Map<String, String> avoid = new HashMap<>();\n avoid.put(\"units\", \"si\");\n avoid.put(\"lang\", \"en\");\n avoid.put(\"exclude\", \"alerts,daily\");\n\n\n PlaceWeather dayWeather;\n for(int i = 1; i < dailyData.size(); ++i){\n try{\n dayWeather = api.getTimeForecast(apiKey,\n weather.getLatitude(),\n weather.getLongitude(),\n dailyData.get(i).getTime()+1,\n avoid).execute().body();\n }catch (IOException e){\n break;\n }\n\n dayWeather.getHourly().setParentDayId(dailyData.get(i).getId());\n dayWeather.getHourly().setId(\n databaseInstance.weatherDao().insertHourly(dayWeather.getHourly())\n );\n\n hourlyData = dayWeather.getHourly().getData();\n\n for(int j = 0; j < hourlyData.size(); ++j){\n hourlyData.get(j).setParentDayId(dailyData.get(i).getId());\n databaseInstance.weatherDao().insertHourlyData(hourlyData.get(j));\n }\n }\n\n }", "@Override\n protected Void doInBackground(Void... params) {\n\n try {\n while(mLastLocation==null)\n {\n try {\n mLastLocation = LocationServices.FusedLocationApi.getLastLocation(\n googleApiClient);\n Thread.sleep(1000);\n }catch (SecurityException e){\n e.printStackTrace();\n }\n }\n\n } catch (InterruptedException e) {\n // TODO Auto-generated catch block\n e.printStackTrace();\n }\n return null;\n }", "private void getLocation() {\n LocationRequest mLocationRequestHighAccuracy = new LocationRequest();\n mLocationRequestHighAccuracy.setPriority(LocationRequest.PRIORITY_HIGH_ACCURACY);\n mLocationRequestHighAccuracy.setInterval(UPDATE_INTERVAL);\n mLocationRequestHighAccuracy.setFastestInterval(FASTEST_INTERVAL);\n\n if (ActivityCompat.checkSelfPermission(this,\n Manifest.permission.ACCESS_FINE_LOCATION) != PackageManager.PERMISSION_GRANTED || ActivityCompat.checkSelfPermission(this,\n Manifest.permission.ACCESS_COARSE_LOCATION) != PackageManager.PERMISSION_GRANTED) {\n stopSelf();\n return;\n } else\n mFusedLocationClient.requestLocationUpdates(mLocationRequestHighAccuracy, new LocationCallback() {\n @Override\n public void onLocationResult(LocationResult locationResult) {\n\n Log.d(TAG, \"onLocationResult: got location result.\");\n\n Location location = locationResult.getLastLocation();\n if (location != null) {\n db.getReference(\"Users\").child(FirebaseAuth.getInstance().getCurrentUser().getUid()).addValueEventListener(new ValueEventListener() {\n @Override\n public void onDataChange(@NonNull DataSnapshot snapshot) {\n user=snapshot.getValue(User.class);\n }\n\n @Override\n public void onCancelled(@NonNull DatabaseError error) {\n\n }\n });\n\n\n LocationModel geoPoint = new LocationModel(location.getLatitude(), location.getLongitude());\n UserLocation userLocation = new UserLocation(geoPoint, user);\n saveUserLocation(userLocation);\n }\n\n /*if (location != null) {\n DocumentReference u = db.collection(\"Users\").document(FirebaseAuth.getInstance().getCurrentUser().getUid());\n u.get().addOnCompleteListener(new OnCompleteListener<DocumentSnapshot>() {\n @Override\n public void onComplete(@NonNull Task<DocumentSnapshot> task) {\n if (task.isSuccessful()) {\n user = task.getResult().toObject(User.class);\n }\n }\n });\n\n GeoPoint geoPoint = new GeoPoint(location.getLatitude(), location.getLongitude());\n UserLocation userLocation = new UserLocation(geoPoint, null, user);\n saveUserLocation(userLocation);\n }*/\n\n }\n },\n Looper.myLooper()); // Looper.myLooper tells this to repeat forever until thread is destroyed\n }", "private void getLocation() { \n LocationManager locationManager = (LocationManager)getSystemService(Context.LOCATION_SERVICE); \n Criteria criteria = new Criteria(); \n criteria.setAccuracy(Criteria.ACCURACY_FINE); \n criteria.setAltitudeRequired(false); \n criteria.setBearingRequired(false); \n criteria.setCostAllowed(true);\n criteria.setPowerRequirement(Criteria.POWER_LOW); \n String provider = locationManager.getBestProvider(criteria,true); \n \n //In order to make sure the device is getting location, request updates. locationManager.requestLocationUpdates(provider, 1, 0, this); \n mostRecentLocation = locationManager.getLastKnownLocation(provider); \n }", "@Override\n public void onLocationChanged(Location location) {\n //Aqui creamos la funcion DownloadWebPageTask para poder descargar los archivos desde la pagina del api\n DownloadWebPageTask task = new DownloadWebPageTask(location);\n task.execute(new String[] { \"http://api.openweathermap.org/data/2.5/weather?lat=\"+location.getLatitude()+\n \"&lon=\"+location.getLongitude()+\"&units=metric&lang=fr&appid=5bdfb081811a28abc515bc673fc0d20f\" });\n Log.d(\"DEBUGGGGGGGGGGGGGGGGGG\", String.valueOf(location.getLatitude()));\n }", "@Override\n protected Void doInBackground(Void... voids) {\n\n Retrofit retrofit = new Retrofit.Builder()\n .baseUrl(BaseUrl)\n .addConverterFactory(GsonConverterFactory.create())\n .build();\n WeatherService service = retrofit.create(WeatherService.class);\n Call<CurrentWeatherCallResult> call = service.getCurrentWeatherDataLatLng(String.valueOf(latLng.latitude), String.valueOf(latLng.longitude), AppId);\n call.enqueue(new Callback<CurrentWeatherCallResult>() {\n @Override\n public void onResponse(@NonNull Call<CurrentWeatherCallResult> call, @NonNull Response<CurrentWeatherCallResult> response) {\n if (response.code() == 200 && response.body() != null) {//TODO DEFINE 200\n\n CurrentWeatherCallResult currentWeatherCallResult = response.body();\n CurrentWeather currentWeather =\n new CurrentWeather(\n position,\n currentWeatherCallResult.weather.get(0).description,\n currentWeatherCallResult.weather.get(0).icon,\n String.valueOf(Math.round((double) currentWeatherCallResult.main.temp_max - 273)),\n String.valueOf(Math.round((double) currentWeatherCallResult.main.temp_min - 273)),\n String.valueOf(Math.round((double) currentWeatherCallResult.main.temp - 273)),\n currentWeatherCallResult.name);\n Intent i;\n switch (position) {\n case -2:\n i = new Intent(\"CURRENT_WEATHER_SEARCH_A\");\n break;\n case -1:\n i = new Intent(\"CURRENT_WEATHER\");\n break;\n default:\n i = new Intent(\"CURRENT_WEATHER_F\");\n break;\n\n\n }\n i.putExtra(\"CURRENT_WEATHER_OBJECT\", currentWeather);\n mContext.sendBroadcast(i);\n }\n }\n\n @Override\n public void onFailure(@NonNull Call<CurrentWeatherCallResult> call, @NonNull Throwable t) {\n t.getMessage();\n }\n });\n return null;\n }", "@Override\n protected Void doInBackground(Void... params) {\n try {\n Query query = new Query(\"India\"); //\n\n GeoLocation location = new GeoLocation(mLastLocation.getLatitude(), mLastLocation.getLongitude()); //latitude, longitude\n\n query.setGeoCode(location, 1, Query.MILES); //location, radius, unit\n query.setSinceId(latestTweetId);\n QueryResult result;\n\n do {\n result = twitter.search(query);\n\n\n for (twitter4j.Status tweet : result.getTweets()) {\n\n if(tweet.getGeoLocation()!=null){\n\n newTweets.add(tweet);\n long id = tweet.getId();\n\n if(id>latestTweetId){\n\n latestTweetId = id;\n }\n\n }\n\n System.out.println(\"@\" + tweet.getUser().getScreenName() + \" - \" + tweet.getText());\n }\n\n } while ((query = result.nextQuery()) != null);\n\n } catch (TwitterException te) {\n System.out.println(\"Failed to search tweets: \" + te.getMessage());\n }\n return null;\n }", "public abstract WeatherData getCurrentWeather(LocationCoordinate _location) throws Exception;", "@Override\n public void onLocationChanged(final Location location) {\n\n if(mLastLocation==null || location.distanceTo(mLastLocation)>getResources().getInteger(R.integer.min_distance_listen))\n {\n new GetNearBy().executePreHeavy();\n }\n\n mLastLocation=location;\n\n android.util.Log.e(\"onLocationChanged\",mLastLocation.getLatitude()+\" - \"+mLastLocation.getLongitude());\n\n\n\n }", "protected void saveProjectSite() {\r\n\t\tlog.debug(\"saveing project site\");\r\n\r\n\t\ttry {\r\n\r\n\t\t\tLocation curLocation = new Location(LocationServiceFactory.getLocationService().getLocation()), lastLocation = site.getLastLocation();\r\n\r\n\t\t\tif (lastLocation == null || (curLocation.getX() != lastLocation.getX() && curLocation.getY() != lastLocation.getY())) {\r\n\t\t\t\tsite.setLastLocation(curLocation);\r\n\r\n\t\t\t\tDao<Location, Integer> locDao = databaseHelper.getDao(Location.class);\r\n\r\n\t\t\t\tif (lastLocation != null) {\r\n\t\t\t\t\t// delete old location\r\n\t\t\t\t\tlocDao.delete(lastLocation);\r\n\t\t\t\t}\r\n\t\t\t\t// and create new one\r\n\t\t\t\tlocDao.create(curLocation);\r\n\r\n\t\t\t}\r\n\r\n\t\t\tfor (MultiTouchDrawable d : map.getSubDrawables()) {\r\n\r\n\t\t\t\tif (d instanceof AccessPointDrawable) {\r\n\t\t\t\t\tAccessPoint ap = ((AccessPointDrawable) d).getAccessPoint();\r\n\t\t\t\t\t// id is not 0, so this location was never saved\r\n\t\t\t\t\tif (!ap.isCalculated() && ap.getLocation() != null) {\r\n\t\t\t\t\t\ttry {\r\n\t\t\t\t\t\t\tdatabaseHelper.getDao(Location.class).create(ap.getLocation());\r\n\t\t\t\t\t\t\tdatabaseHelper.getDao(AccessPoint.class).update(ap);\r\n\t\t\t\t\t\t} catch (SQLException e) {\r\n\t\t\t\t\t\t\tlog.error(\"could not save location data for an ap: \" + ap.toString(), e);\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\r\n\r\n\t\t\tint changed = projectSiteDao.update(site);\r\n\r\n\t\t\tif (changed > 0) {\r\n\t\t\t\tToast.makeText(this, R.string.project_site_saved, Toast.LENGTH_SHORT).show();\r\n\t\t\t}\r\n\r\n\t\t\tprojectSiteDao.refresh(site);\r\n\t\t} catch (SQLException e) {\r\n\t\t\tlog.error(\"could not save or refresh project site\", e);\r\n\t\t\tToast.makeText(this, R.string.project_site_save_failed, Toast.LENGTH_LONG).show();\r\n\t\t}\r\n\r\n\t}", "@Override\n protected WeatherInfo doInBackground(Void... params) {\n String weatherID = \"\";\n String areaID = \"\";\n try {\n String cityIds = null;\n if (mRequest.getRequestInfo().getRequestType()\n == RequestInfo.TYPE_WEATHER_BY_WEATHER_LOCATION_REQ) {\n cityIds = mRequest.getRequestInfo().getWeatherLocation().getCityId();\n weatherID = cityIds.split(\",\")[0];\n areaID = cityIds.split(\",\")[1];\n } else if (mRequest.getRequestInfo().getRequestType() ==\n RequestInfo.TYPE_WEATHER_BY_GEO_LOCATION_REQ) {\n double lat = mRequest.getRequestInfo().getLocation().getLatitude();\n double lng = mRequest.getRequestInfo().getLocation().getLongitude();\n\n String cityNameResponse = HttpRetriever.retrieve(String.format(GEO_URL, lat, lng));\n if (TextUtils.isEmpty(cityNameResponse)) {\n return null;\n }\n cityNameResponse = cityNameResponse.replace(\"renderReverse&&renderReverse(\", \"\").replace(\")\", \"\");\n Log.d(TAG, \"cityNameResponse\" + cityNameResponse);\n JSONObject jsonObjectCity = JSON.parseObject(cityNameResponse);\n String areaName = jsonObjectCity.getJSONObject(\"result\").getJSONObject(\"addressComponent\").getString(\"district\");\n String cityName = jsonObjectCity.getJSONObject(\"result\").getJSONObject(\"addressComponent\").getString(\"city\");\n areaName = TextUtil.getFormatArea(areaName);\n cityName = TextUtil.getFormatArea(cityName);\n City city = cityDao.getCityByCityAndArea(cityName, areaName);\n if (city == null) {\n city = cityDao.getCityByCityAndArea(cityName, cityName);\n if (city == null)\n return null;\n }\n weatherID = city.getWeatherId();\n areaID = city.getAreaId();\n } else {\n return null;\n }\n\n //miui天气\n String miuiURL = String.format(URL_WEATHER_MIUI, weatherID);\n if (DEBUG) Log.d(TAG, \"miuiURL \" + miuiURL);\n String miuiResponse = HttpRetriever.retrieve(miuiURL);\n if (miuiResponse == null) return null;\n if (DEBUG) Log.d(TAG, \"Rmiuiesponse \" + miuiResponse);\n\n //2345天气\n String ttffUrl = String.format(URL_WEATHER_2345, areaID);\n if (DEBUG) Log.d(TAG, \"ttffUrl \" + ttffUrl);\n String ttffResponse = DecodeUtil.decodeResponse(HttpRetriever.retrieve(ttffUrl));\n if (ttffResponse == null) return null;\n if (DEBUG) Log.d(TAG, \"ttffResponse \" + ttffResponse);\n\n\n JSONObject ttffAll = JSON.parseObject(ttffResponse);\n String cityName = ttffAll.getString(\"cityName\");\n //实时\n JSONObject sk = ttffAll.getJSONObject(\"sk\");\n String humidity = sk.getString(\"humidity\");\n String sk_temp = sk.getString(\"sk_temp\");\n\n //日落日升\n JSONObject sunrise = ttffAll.getJSONObject(\"sunrise\");\n\n ArrayList<WeatherInfo.DayForecast> forecasts =\n parse2345(ttffAll.getJSONArray(\"days7\"), true);\n\n WeatherInfo.Builder weatherInfo = null;\n weatherInfo = new WeatherInfo.Builder(\n cityName, sanitizeTemperature(Double.parseDouble(sk_temp), true),\n WeatherContract.WeatherColumns.TempUnit.CELSIUS);\n //湿度\n humidity = humidity.replace(\"%\", \"\");\n weatherInfo.setHumidity(Double.parseDouble(humidity));\n\n if (miuiResponse != null) {\n //风速,风向\n JSONObject weather = JSON.parseObject(miuiResponse);\n JSONObject accu_cc = weather.getJSONObject(\"accu_cc\");\n weatherInfo.setWind(accu_cc.getDouble(\"WindSpeed\"), accu_cc.getDouble(\"WindDirectionDegrees\"),\n WeatherContract.WeatherColumns.WindSpeedUnit.KPH);\n }\n\n weatherInfo.setTimestamp(System.currentTimeMillis());\n weatherInfo.setForecast(forecasts);\n\n if (forecasts.size() > 0) {\n weatherInfo.setTodaysLow(sanitizeTemperature(forecasts.get(0).getLow(), true));\n weatherInfo.setTodaysHigh(sanitizeTemperature(forecasts.get(0).getHigh(), true));\n weatherInfo.setWeatherCondition(IconUtil.getWeatherCodeByType(\n ttffAll.getJSONArray(\"days7\").getJSONObject(0).getString(\n DateTimeUtil.isNight(sunrise.getString(\"todayRise\"), sunrise.getString(\"todaySet\"))\n ? \"nightWeaShort\" : \"dayWeaShort\"), sunrise.getString(\"todayRise\"), sunrise.getString(\"todaySet\")));\n }\n\n if (lastWeatherInfo != null)\n lastWeatherInfo = null;\n\n lastWeatherInfo = weatherInfo.build();\n\n return lastWeatherInfo;\n } catch (Exception e) {\n if (DEBUG) Log.w(TAG, \"JSONException while processing weather update\", e);\n }\n return null;\n }", "private void returnForecast() {\n\t\tif (callback != null) {\n\t\t\t// use the callback to prevent the client\n\t\t\tif (callback.get() != null) {\n\t\t\t\t// yep, we use a weakReference\n\t\t\t\tcallback.get().forecastLoaded(forecasts);\n\t\t\t}\n\t\t\tif (forecasts.isEmpty()&&reload) {\n\t\t\t\tupdateForecastRequest();\n\t\t\t} else {\n\t\t\t\t// then ask the serviceupdater to update data\n\t\t\t\t// but update only if one day of difference between the last update and now is more\n\t\t\t\t// than one day\n\t\t\t\tString strLastUpdate = MyApplication.instance.getServiceManager().getForecastServiceUpdater().getLastUpdate(this.woeid);\n\t\t\t\tLog.e(\"ForecastServiceData\", \"strLastUpdate \" + strLastUpdate);\n\t\t\t\ttry {\n\t\t\t\t\t// empty data base case and empty SharedPreference\n\t\t\t\t\tif (strLastUpdate.equals(\"null\")) {\n\t\t\t\t\t\tupdateForecastRequest();\n\t\t\t\t\t} else {\n\t\t\t\t\t\t// current case\n SimpleDateFormat sdf=MyApplication.instance.getServiceManager().getForecastServiceUpdater().getDateFormatForLastUpdate();\n\t\t\t\t\t\tDate lastUpdate = sdf.parse(strLastUpdate);\n\t\t\t\t\t\tif (new Date().getTime() - lastUpdate.getTime() > 1000 * 60 * 60 * 24) {\n\t\t\t\t\t\t\t// if the last update was one day ago, then make an automatic update\n\t\t\t\t\t\t\tupdateForecastRequest();\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t} catch (ParseException e) {\n\t\t\t\t\tExceptionManager.manage(new ExceptionManaged(this.getClass(), R.string.exc_date_parsing, e));\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}", "private void getLocation() {\n\t\tif (Build.VERSION.SDK_INT >= Build.VERSION_CODES.M) {\n\t\t\tif (checkSelfPermission(Manifest.permission.ACCESS_FINE_LOCATION) != PackageManager.PERMISSION_GRANTED) {\n\t\t\t\treturn;\n\t\t\t}\n\t\t}\n\t\t\n\t\tFusedLocationProviderClient locationProviderClient = LocationServices.getFusedLocationProviderClient(getApplicationContext());\n\t\tlocationProviderClient.getLastLocation().addOnSuccessListener(new OnSuccessListener<Location>() {\n\t\t\t@Override\n\t\t\tpublic void onSuccess(Location location) {\n\t\t\t\t\n\t\t\t\tfinal Location finalLocation = location;\n\t\t\t\t\n\t\t\t\tbtnGoToYou.setOnClickListener(new View.OnClickListener() {\n\t\t\t\t\t@Override\n\t\t\t\t\tpublic void onClick(View v) {\n\t\t\t\t\t\tLatLng userLocation = new LatLng(finalLocation.getLatitude(), finalLocation.getLongitude());\n\t\t\t\t\t\tmMap.addMarker(new MarkerOptions().position(userLocation).title(\"You are Here!\"));\n\t\t\t\t\t\tmMap.moveCamera(CameraUpdateFactory.newLatLng(userLocation));\n\t\t\t\t\t}\n\t\t\t\t});\n\t\t\t\t\n\t\t\t\t\n\t\t\t}\n\t\t});\n\t\t\n\t}", "private void initLocationData() {\n\n // init google client and request for fused location provider\n fusedLocationProviderClient = LocationServices.getFusedLocationProviderClient(context);\n\n locationRequest = new LocationRequest()\n //.setPriority(LocationRequest.PRIORITY_HIGH_ACCURACY) // GPS quality location points\n .setPriority(LocationRequest.PRIORITY_BALANCED_POWER_ACCURACY) // optimized for battery\n .setInterval(20000) // at least once every 20 seconds\n .setFastestInterval(10000); // at most once every 10 seconds\n\n locationCallback = new LocationCallback() {\n @Override\n public void onLocationResult(LocationResult locationResult) {\n\n Point userPoint;\n if (locationResult != null) {\n // update user location\n Location lastLocation = locationResult.getLastLocation();\n userPoint = new Point(lastLocation.getLatitude(), lastLocation.getLongitude());\n // cache location\n PreferencesCache.setLastLatitude(lastLocation.getLatitude());\n PreferencesCache.setLastLongitude(lastLocation.getLongitude());\n } else {\n // get cached data\n userPoint = new Point(PreferencesCache.getLastLatitude(), PreferencesCache.getLastLongitude());\n }\n\n navigator.updateUserLocation(userPoint);\n }\n };\n }", "@Override\n public void onLocationChanged(Location location) {\n currentLatitude = location.getLatitude();\n currentLongitude = location.getLongitude();\n\n Toast.makeText(this, currentLatitude + \" - \" + currentLongitude + \"\", Toast.LENGTH_LONG).show();\n String latitude = currentLatitude + \",\";\n String latitudeAndLongitude = latitude + currentLongitude;\n REQUEST_URL_1 += latitudeAndLongitude;\n REQUEST_URL_1 += REQUEST_URL_2;\n ForecastAsyncTask task = new ForecastAsyncTask();\n task.execute(REQUEST_URL_1);\n\n }", "private void searchForLocation() {\n foundLocation = false;\n FusedLocationProviderClient mFusedLocationProviderClient = LocationServices\n .getFusedLocationProviderClient(getActivity());\n //Ignore the red line - we check for permissions before this function is called\n if (ActivityCompat.checkSelfPermission(getContext(), Manifest.permission.ACCESS_FINE_LOCATION) != PackageManager.PERMISSION_GRANTED &&\n ActivityCompat.checkSelfPermission(getContext(), Manifest.permission.ACCESS_COARSE_LOCATION) != PackageManager.PERMISSION_GRANTED) {\n\n return;\n }\n Task<Location> lastLocation = mFusedLocationProviderClient.getLastLocation();\n lastLocation.addOnCompleteListener(new OnCompleteListener<Location>() {\n @Override\n public void onComplete(@NonNull Task<Location> task) {\n if (task.isSuccessful()) {\n // Set the map's camera position to the current location of the device.\n Location location = task.getResult();\n if (location != null) {\n LatLng currentLatLng = new LatLng(location.getLatitude(),\n location.getLongitude());\n CameraUpdate update = CameraUpdateFactory.newLatLngZoom(currentLatLng,\n DEFAULT_ZOOM);\n googleMap.moveCamera(update);\n foundLocation = true;\n }\n }\n }\n });\n }", "@Override\r\n\t\tpublic void run() {\n\t\t\t\r\n\t\t\tLog.i(\"currentLocation\", \"in\");\r\n\t\t\t\r\n\t\t\tCriteria criteria = new Criteria();\r\n\t\t\tLocationManager locationManager = (LocationManager) getSystemService(LOCATION_SERVICE);\r\n\t\t\tString bestProvider = locationManager.getBestProvider(criteria, false);\r\n\t\t\tif(bestProvider != null){\r\n\t\t\t\tLocation location = locationManager.getLastKnownLocation(bestProvider);\r\n\t\t\t\tif(location != null){\r\n\t\t\t\t\t\r\n\t\t\t\t\tLog.i(\"currentLocation\", \"get\");\r\n\t\t\t\t\tmylat = location.getLatitude();\r\n\t\t\t\t\tmylng = location.getLongitude();\r\n\t\t\t\t}\r\n\t\t\t\telse{\r\n\t\t\t\t\tLog.i(\"currentLocation\", \"not get\");\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\telse Log.i(\"currentLocation\", \"bestProvider = null\");\r\n\t\t\t\r\n\t\t\t\r\n\t\t}", "protected Void doInBackground(Context... params) {\n Long t = Calendar.getInstance().getTimeInMillis();\n while (!foundLocation) {\n searchForLocation();\n try {\n Thread.sleep(1000);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n }\n return null;\n }", "private void updateWeather()\n\t{\n\t\tSunshineSyncAdapter.syncImmediately(getActivity());\n\t}", "@SuppressLint(\"MissingPermission\")\n private void requestNewLocationData() {\n LocationRequest mLocationRequest = new LocationRequest();\n mLocationRequest.setPriority(LocationRequest.PRIORITY_HIGH_ACCURACY);\n mLocationRequest.setInterval(5);\n mLocationRequest.setFastestInterval(0);\n mLocationRequest.setNumUpdates(1);\n\n // setting LocationRequest\n // on FusedLocationClient\n mFusedLocationClient = LocationServices.getFusedLocationProviderClient(this);\n mFusedLocationClient.requestLocationUpdates(mLocationRequest, mLocationCallback, Looper.myLooper());\n }", "@SuppressLint(\"MissingPermission\")\n private void requestNewLocationData() {\n LocationRequest mLocationRequest = new LocationRequest();\n mLocationRequest.setPriority(LocationRequest.PRIORITY_HIGH_ACCURACY);\n mLocationRequest.setInterval(5);\n mLocationRequest.setFastestInterval(0);\n mLocationRequest.setNumUpdates(1);\n\n // setting LocationRequest\n // on FusedLocationClient\n mFusedLocationClient = LocationServices.getFusedLocationProviderClient(this);\n mFusedLocationClient.requestLocationUpdates(mLocationRequest, mLocationCallback, Looper.myLooper());\n }", "@Override\n public void onConnected(Bundle bundle) {\n if (ActivityCompat.checkSelfPermission(this, Manifest.permission.ACCESS_FINE_LOCATION) != PackageManager.PERMISSION_GRANTED && ActivityCompat.checkSelfPermission(this, Manifest.permission.ACCESS_COARSE_LOCATION) != PackageManager.PERMISSION_GRANTED) {\n return;\n }\n Location location = LocationServices.FusedLocationApi.getLastLocation(mGoogleApiClient);\n\n if (location == null) {\n LocationServices.FusedLocationApi.requestLocationUpdates(mGoogleApiClient, mLocationRequest, this);\n\n } else {\n //If everything went fine lets get latitude and longitude\n currentLatitude = location.getLatitude();\n currentLongitude = location.getLongitude();\n\n Toast.makeText(this, currentLatitude + \" - \" + currentLongitude + \"\", Toast.LENGTH_LONG).show();\n String latitude = currentLatitude + \",\";\n String latitudeAndLongitude = latitude + currentLongitude;\n REQUEST_URL_1 += latitudeAndLongitude;\n REQUEST_URL_1 += REQUEST_URL_2;\n ForecastAsyncTask task = new ForecastAsyncTask();\n task.execute(REQUEST_URL_1);\n }\n }", "@SuppressLint(\"MissingPermission\")\n private void requestNewLocationData() {\n LocationRequest mLocationRequest = new LocationRequest();\n mLocationRequest.setPriority(LocationRequest.PRIORITY_HIGH_ACCURACY);\n mLocationRequest.setInterval(5);\n mLocationRequest.setFastestInterval(0);\n mLocationRequest.setNumUpdates(1);\n\n // setting LocationRequest\n // on FusedLocationClient\n FusedLocationProviderClient mFusedLocationClient = LocationServices.getFusedLocationProviderClient(this);\n mFusedLocationClient.requestLocationUpdates(mLocationRequest, mLocationCallback, Looper.myLooper());\n }", "private void Location() {\n\n if (ContextCompat.checkSelfPermission(this, Manifest.permission.ACCESS_FINE_LOCATION)\n != PackageManager.PERMISSION_GRANTED) {\n ActivityCompat.requestPermissions(this, new String[]{Manifest.permission.ACCESS_FINE_LOCATION},\n PERMISSION_ACCESS_FINE_LOCATION);\n }\n\n //Google Play Location stored in loc variable\n fusedLocationClient = LocationServices.getFusedLocationProviderClient(this);\n fusedLocationClient.getLastLocation()\n .addOnSuccessListener(this, new OnSuccessListener<Location>() {\n\n\n @Override\n public void onSuccess(Location location) {\n\n // Got last known location. In some rare situations this can be null.\n if (location != null) {\n loc = location;\n getAddressFromLocation(loc.getLatitude(), loc.getLongitude());\n\n }\n }\n });\n }", "private void getDeviceLocation() {\n /*\n * Get the best and most recent location of the device, which may be null in rare\n * cases when a location is not available.\n */\n try {\n if (mLocationPermissionGranted) {\n Task<Location> locationResult = mFusedLocationProviderClient.getLastLocation();\n locationResult.addOnSuccessListener(this, new OnSuccessListener<Location>() {\n @Override\n public void onSuccess(Location location) {\n if (location != null) {\n // Set the map's camera position to the current location of the device.\n mLastKnownLocation = location;\n Log.d(TAG, \"Latitude: \" + mLastKnownLocation.getLatitude());\n Log.d(TAG, \"Longitude: \" + mLastKnownLocation.getLongitude());\n mMap.moveCamera(CameraUpdateFactory.newLatLngZoom(\n new LatLng(mLastKnownLocation.getLatitude(),\n mLastKnownLocation.getLongitude()), DEFAULT_ZOOM));\n } else {\n Log.d(TAG, \"Current location is null. Using defaults.\");\n mMap.moveCamera(CameraUpdateFactory\n .newLatLngZoom(mDefaultLocation, DEFAULT_ZOOM));\n }\n\n getCurrentPlaceLikelihoods();\n }\n });\n }\n } catch (Exception e) {\n Log.e(\"Exception: %s\", e.getMessage());\n }\n }", "private void getLocation() {\n //if you don't have permission for location services yet, ask\n if (ActivityCompat.checkSelfPermission(this,\n Manifest.permission.ACCESS_FINE_LOCATION)\n != PackageManager.PERMISSION_GRANTED) {\n ActivityCompat.requestPermissions(this, new String[]\n {Manifest.permission.ACCESS_FINE_LOCATION},\n REQUEST_LOCATION_PERMISSION);\n //have the app ask for location permission\n } else {\n fusedLocationClient.requestLocationUpdates\n (getLocationRequest(), mLocationCallback,\n null /* Looper */);\n //uses the type of request and the location callback to update the location\n /**fusedLocationClient.getLastLocation().addOnSuccessListener(\n new OnSuccessListener<Location>() {\n @Override\n public void onSuccess(Location location) {\n TextView error = findViewById(R.id.errorMsg);\n error.setVisibility(View.VISIBLE);\n\n if (location != null) {\n lastLocation = location;\n error.setText(\"location: \" + lastLocation.getLatitude());\n } else {\n error.setText(\"location not available\");\n }\n }\n });**/\n }\n }", "@Override\n\tpublic List<Historic_siteVO> MainLocation() throws Exception {\n\t\treturn dao.MainLocation();\n\t}", "private void getLocation() {\n if (ActivityCompat.checkSelfPermission(getActivity(), Manifest.permission.ACCESS_FINE_LOCATION)\n != PackageManager.PERMISSION_GRANTED && ActivityCompat.checkSelfPermission(getActivity(), Manifest.permission.ACCESS_COARSE_LOCATION) != PackageManager.PERMISSION_GRANTED) {\n if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.M) {\n requestPermissions(new String[]{Manifest.permission.ACCESS_COARSE_LOCATION, Manifest.permission.ACCESS_FINE_LOCATION, Manifest.permission.INTERNET}\n , 10);\n }\n return;\n }\n\n //Update location\n locationManager.requestLocationUpdates(\"gps\", 5000, 0, listener);\n }", "SiteLocation getLocatedAt();", "@Override\n public void run() {\n try {\n\n try {\n mLastLocation = LocationServices.FusedLocationApi.getLastLocation(\n googleApiClient);\n } catch (SecurityException e) {\n e.printStackTrace();\n }\n\n if (mLastLocation != null) {\n\n\n Query query = new Query(\"India\"); //\n\n GeoLocation location = new GeoLocation(mLastLocation.getLatitude(), mLastLocation.getLongitude()); //latitude, longitude\n\n query.setGeoCode(location, 5, Query.MILES); //location, radius, unit\n query.setSinceId(latestTweetId);\n QueryResult result;\n\n do {\n result = twitter.search(query);\n\n for (twitter4j.Status tweet : result.getTweets()) {\n\n if (tweet.getGeoLocation() != null) {\n\n newTweets.add(tweet);\n long id = tweet.getId();\n\n if (id > latestTweetId) {\n\n latestTweetId = id;\n }\n\n }\n\n System.out.println(\"@\" + tweet.getUser().getScreenName() + \" - \" + tweet.getText());\n }\n\n } while ((query = result.nextQuery()) != null);\n\n handler.sendEmptyMessage(1);\n }\n\n }catch(TwitterException te){\n System.out.println(\"Failed to search tweets: \" + te.getMessage());\n }\n\n\n\n\n\n }", "@Override\r\n\tprotected RiderLocation doInBackground(RiderLocation... params) {\r\n\t\t/*\r\n\t\t * Get a new geocoding service instance, set for localized addresses.\r\n\t\t * This example uses android.location.Geocoder, but other geocoders that\r\n\t\t * conform to address standards can also be used.\r\n\t\t */\r\n\t\tGeocoder geocoder = new Geocoder(this.localContext, Locale.getDefault());\r\n\r\n\t\t// Get the current location from the input parameter list\r\n\t\tRiderLocation location = params[0];\r\n\r\n\t\t// Create a list to contain the result address\r\n\t\tList<Address> addresses = null;\r\n\r\n\t\t// Try to get an address for the current location. Catch IO or network\r\n\t\t// problems.\r\n\t\ttry {\r\n\r\n\t\t\t/*\r\n\t\t\t * Call the synchronous getFromLocation() method with the latitude\r\n\t\t\t * and longitude of the current location. Return at most 1 address.\r\n\t\t\t */\r\n\t\t\taddresses = geocoder.getFromLocation(location.getLatitude(),\r\n\t\t\t\t\tlocation.getLongitude(), 1);\r\n\r\n\t\t\t// Catch network or other I/O problems.\r\n\t\t} catch (IOException exception1) {\r\n\r\n\t\t\t// Log an error and return an error message\r\n\t\t\tLog.e(\"GetAddressTask \", exception1.getMessage());\r\n\r\n\t\t\t// print the stack trace\r\n\t\t\texception1.printStackTrace();\r\n\r\n\t\t\treturn null;\r\n\r\n\t\t\t// Catch incorrect latitude or longitude values\r\n\t\t} catch (IllegalArgumentException exception2) {\r\n\r\n\t\t\texception2.printStackTrace();\r\n\r\n\t\t\t//\r\n\t\t\treturn null;\r\n\t\t}\r\n\t\t// If the reverse geocode returned an address if (addresses != null &&\r\n\t\t// addresses.size() > 0) {\r\n\r\n\t\t// Get the first address\r\n\t\tAddress address = addresses.get(0);\r\n // com.ssinfo.corider.app.models.RiderLocation locationAddress = new com.ssinfo.corider.app.models.RiderLocation();\r\n // locationAddress.setLatitude(location.getLatitude());\r\n //locationAddress.setLongitude(location.getLongitude());\r\n\t\tlocation.setAddress(address.getMaxAddressLineIndex() > 0 ? address.getAddressLine(0):\"\");\r\n\t\tlocation.setCity(address.getSubAdminArea());\r\n\t\tlocation.setCountry(address.getCountryName());\r\n\t\t\r\n return location;\r\n\t}", "@Override\r\n public void run() {\r\n mLocationManager.removeUpdates(locationListenerGps);\r\n mLocationManager.removeUpdates(locationListenerNetwork);\r\n \r\n try{\r\n \t isGpsEnabled=mLocationManager.isProviderEnabled(LocationManager.GPS_PROVIDER);\r\n }catch(Exception ex){\r\n \t//Exception: No suitable permission is present for the provider.\r\n \tConstants.PROVIDER_EXCEPTION = ex.getMessage();\r\n }\r\n try{\r\n \t isNetworkEnabled=mLocationManager.isProviderEnabled(LocationManager.NETWORK_PROVIDER);\r\n }catch(Exception ex){\r\n \tConstants.PROVIDER_EXCEPTION = ex.getMessage();\r\n }\r\n\r\n Location net_loc=null, gps_loc=null;\r\n\r\n if(isGpsEnabled){\r\n \t /*Returns a Location indicating the data from the last known location fix obtained \r\n \t * from the given provider. This can be done without starting the provider. \r\n \t * Note that this location could be out-of-date, \r\n \t * for example if the device was turned off and moved to another location.*/\r\n gps_loc=mLocationManager.getLastKnownLocation(LocationManager.GPS_PROVIDER);\r\n Constants.LAST_KNOWN_LOCATION = true;\r\n }\r\n if(isNetworkEnabled){\r\n net_loc=mLocationManager.getLastKnownLocation(LocationManager.NETWORK_PROVIDER);\r\n Constants.LAST_KNOWN_LOCATION = true;\r\n }\r\n \r\n //if there are both values then use the latest one.\r\n if(gps_loc!=null && net_loc!=null){\r\n if(gps_loc.getTime()>net_loc.getTime())\r\n gotLocation(gps_loc);\r\n else\r\n gotLocation(net_loc);\r\n return;\r\n }\r\n\r\n if(gps_loc!=null){\r\n gotLocation(gps_loc);\r\n return;\r\n }\r\n \r\n if(net_loc!=null){\r\n gotLocation(net_loc);\r\n return;\r\n }\r\n gotLocation(null);\r\n }", "private void getLastKnownLocation() {\n if (ActivityCompat.checkSelfPermission(this, Manifest.permission.ACCESS_FINE_LOCATION) != PackageManager.PERMISSION_GRANTED && ActivityCompat.checkSelfPermission(this, Manifest.permission.ACCESS_COARSE_LOCATION) != PackageManager.PERMISSION_GRANTED) {\n return;\n }\n Task<Location> task = fusedLocationProviderClient.getLastLocation();\n task.addOnSuccessListener(new OnSuccessListener<Location>() {\n @Override\n public void onSuccess(Location location) {\n if (location != null) {\n lastKnownLocation = location;\n lastKnownLatLng = new LatLng(lastKnownLocation.getLatitude(), lastKnownLocation.getLongitude());\n riderMarker = mMap.addMarker(new MarkerOptions().position(lastKnownLatLng).title(\"Your Location\")); // adding marker to rider location\n mMap.moveCamera(CameraUpdateFactory.newLatLngZoom(lastKnownLatLng, 18)); // focusing on rider location\n if (ActivityCompat.checkSelfPermission(RiderMapsActivity.this, Manifest.permission.ACCESS_FINE_LOCATION) != PackageManager.PERMISSION_GRANTED && ActivityCompat.checkSelfPermission(RiderMapsActivity.this, Manifest.permission.ACCESS_COARSE_LOCATION) != PackageManager.PERMISSION_GRANTED) {\n return;\n }\n mMap.setMyLocationEnabled(true);\n mMap.getUiSettings().setMyLocationButtonEnabled(true);\n\n riderInfoHashMap.put(NodeNames.RIDERID,currentUserId);\n riderInfoHashMap.put(NodeNames.RIDERLATITUDE,lastKnownLocation.getLatitude());\n riderInfoHashMap.put(NodeNames.RIDERLONGITUDE,lastKnownLocation.getLongitude());\n\n nodeReference = NodeNames.RIDERS + \"/\" + currentUserId;\n referenceHashMap = new HashMap<>();\n referenceHashMap.put(nodeReference,riderInfoHashMap);\n databaseReference.updateChildren(referenceHashMap, new DatabaseReference.CompletionListener() {\n @Override\n public void onComplete(@Nullable DatabaseError error, @NonNull DatabaseReference ref) {\n if(error==null){\n Toast.makeText(RiderMapsActivity.this,\"Request your Cab ride\",Toast.LENGTH_SHORT).show();\n }else {\n Toast.makeText(RiderMapsActivity.this,\"error: \" + error.getMessage(),Toast.LENGTH_LONG).show();\n }\n }\n });\n\n // searching for nearby available driver\n\n searchCab.setOnClickListener(new View.OnClickListener() {\n @Override\n public void onClick(View view) {\n\n if(requestCancelled){\n rideEndedByRider(); // rider cancelled ride\n }else {\n requestCancelled = true;\n GeoFire geoFire = new GeoFire(riderRequestsDatabaseReference);\n geoFire.setLocation(currentUserId, new GeoLocation(lastKnownLocation.getLatitude(), lastKnownLocation.getLongitude()));\n\n progressDialog.setTitle(\"Getting Your Driver\");\n progressDialog.setMessage(\"Please wait while we are looking for nearby drivers\");\n progressDialog.show();\n\n getClosestDriver();\n }\n }\n });\n }\n }\n });\n }", "private void getLocation() {\n NimbeesLocationManager.NimbeesLocationListener mNimbeesLocationListener = new NimbeesLocationManager.NimbeesLocationListener() {\n @Override\n public void onGetCurrentLocation(Location location) {\n mLocation = location;\n setUpMap();\n }\n\n @Override\n public void onError(NimbeesException e) {\n }\n };\n NimbeesClient.getLocationManager().obtainCurrentLocation(mNimbeesLocationListener);\n }", "private void getDeviceLocation(){\n Log.d(TAG,\"get device location currently\");\n mFusedLocationProviderClient= LocationServices.getFusedLocationProviderClient(this);\n try{\n if(mLocationPermissionGranted){\n @SuppressLint(\"MissingPermission\") final Task location = mFusedLocationProviderClient.getLastLocation();\n location.addOnCompleteListener(new OnCompleteListener() {\n @Override\n public void onComplete(@NonNull Task task) {\n if(task.isSuccessful()){\n Log.d(TAG,\"onComplete: found Location\");\n mLastKnownLocation= (Location) task.getResult();\n moveCamera(new LatLng(mLastKnownLocation.getLatitude(),mLastKnownLocation.getLongitude()),DEFAULT_ZOOM);\n\n Geocoder geocoder;\n List<Address> addresses;\n geocoder = new Geocoder(MapsActivity.this, Locale.getDefault());\n\n try {\n addresses = geocoder.getFromLocation(mLastKnownLocation.getLatitude(), mLastKnownLocation.getLongitude(), 1); // Here 1 represent max location result to returned, by documents it recommended 1 to 5\n LatLng latLng = new LatLng(mLastKnownLocation.getLatitude(), mLastKnownLocation.getLongitude());\n\n address = addresses.get(0).getAddressLine(0); // If any additional address line present than only, check with max available address lines by getMaxAddressLineIndex()\n city = addresses.get(0).getLocality();\n state = addresses.get(0).getAdminArea();\n String country = addresses.get(0).getCountryName();\n postalCode = addresses.get(0).getPostalCode();\n String knownName = addresses.get(0).getFeatureName(); // Only\n MarkerOptions markerOptions = new MarkerOptions();\n markerOptions.position(latLng);\n markerOptions.title(address);\n mMap.clear();//Not sure\n mMap.addMarker(markerOptions);\n Marker here = mMap.addMarker(markerOptions.title(address + \", \" + city + \", \" + state + \", \" + country\n + \", \" + postalCode + \", \" + knownName));\n here.showInfoWindow();\n } catch (IOException e) {\n e.printStackTrace();\n } }else {\n Log.d(TAG, \"onComplete: current location is null\");\n Toast.makeText(MapsActivity.this, \"unable to get current location\",Toast.LENGTH_SHORT).show();\n getLocationPermission();\n }\n }\n });\n\n }\n }catch (SecurityException e){\n Log.e(TAG,\"getDeviceLocation: SecurityException: \" + e.getMessage() );\n }\n\n\n\n }", "public abstract WeatherData[] getDailyWeatherForecast(LocationCoordinate _location) throws Exception;", "public void getDeviceLocation() {\n try {\n if (locationPermissionGranted) {\n Task<Location> locationResult = fusedLocationProviderClient.getLastLocation();\n locationResult.addOnCompleteListener(getActivity(), new OnCompleteListener<Location>() {\n @Override\n public void onComplete(@NonNull Task<Location> task) {\n if (task.isSuccessful()) {\n // Set the map's camera position to the current location of the device.\n lastKnownLocation = task.getResult();\n\n if (lastKnownLocation != null) {\n if (checkInLACounty(lastKnownLocation) != -1) {\n // geofenceHelper(getContext());\n lastKnownLocationInLA = true;\n sharedViewModel.setCountyData(\"Los Angeles County\");\n backLA.setVisibility(View.INVISIBLE);\n } else if (lastKnownLocationInLA) {\n lastKnownLocationInLA = false;\n sharedViewModel.setCountyData(\"Not in Los Angeles County\");\n\n backLA.setVisibility(View.VISIBLE);\n\n AlertDialog.Builder alertDialogBuilder = new AlertDialog.Builder(getContext());\n alertDialogBuilder.setTitle(\"Friendly Warning\");\n alertDialogBuilder.setMessage(\"Out of Los Angeles County \\n(Current Service Area)\");\n AlertDialog alertDialog = alertDialogBuilder.create();\n alertDialog.show(); // Show Dialog\n }\n } else {\n sharedViewModel.setCountyData(\"Los Angeles County\");\n }\n\n } else {\n Log.d(TAG, \"Current location is null. Using defaults.\");\n Log.e(TAG, \"Exception: %s\", task.getException());\n map.moveCamera(CameraUpdateFactory\n .newLatLngZoom(defaultLocation, DEFAULT_ZOOM));\n map.getUiSettings().setMyLocationButtonEnabled(false);\n }\n }\n });\n }\n } catch (SecurityException e) {\n Log.e(\"Exception: %s\", e.getMessage(), e);\n }\n }", "private void getCurrentLocation() {\n progressBar.setVisibility(View.VISIBLE);\n LocationRequest locationRequest = new LocationRequest();\n locationRequest.setInterval(10000);\n locationRequest.setFastestInterval(3000);\n locationRequest.setPriority(LocationRequest.PRIORITY_HIGH_ACCURACY);\n\n LocationServices.getFusedLocationProviderClient(IntroActivity.this).requestLocationUpdates(locationRequest, new LocationCallback() {\n @Override\n public void onLocationResult(LocationResult locationResult) {\n super.onLocationResult(locationResult);\n LocationServices.getFusedLocationProviderClient(IntroActivity.this).removeLocationUpdates(this);\n if (locationResult != null && locationResult.getLocations().size() > 0) {\n int latestLocationIndex = locationResult.getLocations().size() - 1;\n double LatOrg = locationResult.getLocations().get(latestLocationIndex).getLatitude();\n double LonOrg = locationResult.getLocations().get(latestLocationIndex).getLongitude();\n\n LatitudeTruePref = Double.toString(LatOrg);\n LongitudeTruePref = Double.toString(LonOrg);\n\n LocationReal = new LatLng(LatOrg, LonOrg);\n tvSkip.setText(String.format(\"Lat: %s\\nLon: %s\", LatitudeTruePref, LongitudeTruePref));\n //tvSkip.setText(String.format(\"Lat: %s\\nLon: %s\", LatOrg, LonOrg));\n }\n FalseLocationSignal = false;//*Desactivar FalseLocation para SharedPreferens*//\n TrueLocationSignal = true;\n progressBar.setVisibility(View.GONE);\n btnNext.setEnabled(true);\n }\n }, Looper.getMainLooper());\n\n }", "@SuppressLint({\"MissingPermission\", \"DefaultLocale\"})\n private void requestCurrentLocation() {\n mFusedLocationClient\n .getCurrentLocation(PRIORITY_HIGH_ACCURACY, cancellationTokenSource.getToken())\n .addOnCompleteListener(this, task -> {\n if (task.isSuccessful() && task.getResult() != null) {\n Location result = task.getResult();\n Log.d(TAG, String.format(\"getCurrentLocation() result: %s\", result.toString()));\n logOutputToScreen(String.format(\n \"Location (success): %f, %f\",\n result.getLatitude(), result.getLongitude()\n ));\n } else {\n Log.e(TAG, String.format(\"Location (failure): %s\", task.getException()));\n }\n });\n }", "public void getLocation() {\n if (ActivityCompat.checkSelfPermission(this,\n Manifest.permission.ACCESS_FINE_LOCATION)\n != PackageManager.PERMISSION_GRANTED) {\n ActivityCompat.requestPermissions(this, new String[]\n {Manifest.permission.ACCESS_FINE_LOCATION},\n REQUEST_LOCATION_PERMISSION);\n } else {\n mFusedLocationClient.getLastLocation().addOnSuccessListener(\n location -> {\n if (location != null) {\n // Start the reverse geocode AsyncTask\n new FetchAddressTask(DetailsTextActivity.this,\n DetailsTextActivity.this).execute(location);\n txtLocation.setText(getString(R.string.loading));\n Log.d(\"myTag\", \"have location\");\n } else {\n txtLocation.setText(R.string.no_location);\n }\n }\n );\n }\n }", "@Override\n public Single<WeatherData> getForecastData(@NonNull final Location location) {\n return Single.just(true)\n .observeOn(Schedulers.io())\n .flatMap(aBoolean -> api.getForecast(apiKey, location.latitude(), location.longitude(), EXCLUDE_DATA_BLOCKS, \"ca\"));\n }", "private void openPreferredLocationMap()\n\t{\n\n\t\tif (_forecastAdapter != null)\n\t\t{\n\t\t\tCursor cursor = _forecastAdapter.getCursor();\n\n\t\t\tif (cursor != null)\n\t\t\t{\n\t\t\t\tcursor.moveToPosition(0);\n\n\t\t\t\tString posLat = cursor.getString(COL_COORD_LAT);\n\t\t\t\tString posLong = cursor.getString(COL_COORD_LONG);\n\n\t\t\t\tUri geoLocation = Uri.parse(\"geo:\" + posLat + \",\" + posLong);\n\n\t\t\t\tIntent intent = new Intent(Intent.ACTION_VIEW);\n\t\t\t\tintent.setData(geoLocation);\n\n\t\t\t\tif (intent.resolveActivity(getActivity().getPackageManager()) != null)\n\t\t\t\t{\n\t\t\t\t\tstartActivity(intent);\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\tTraceUtil.logD(CLASS_NAME, \"openPreferredLocationMap\",\n\t\t\t\t\t\t\t\"Couldn't call \" + geoLocation.toString() +\n\t\t\t\t\t\t\t\t\t\", no receiving apps installed!\");\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}", "private void checkLocationandAddToMap() {\n if (ActivityCompat.checkSelfPermission(getActivity(), android.Manifest.permission.ACCESS_FINE_LOCATION) != PackageManager.PERMISSION_GRANTED && ActivityCompat.checkSelfPermission(getActivity(), android.Manifest.permission.ACCESS_COARSE_LOCATION) != PackageManager.PERMISSION_GRANTED) {\n //Requesting the Location permission\n ActivityCompat.requestPermissions(getActivity(), new String[]{android.Manifest.permission.ACCESS_FINE_LOCATION}, LOCATION_REQUEST_CODE);\n return;\n }\n\n locationManager = (LocationManager) getActivity().getSystemService(LOCATION_SERVICE);\n criteria = new Criteria();\n bestProvider = locationManager.getBestProvider(criteria, true);\n\n\n //Fetching the last known location using the Fus\n Location location = locationManager.getLastKnownLocation(bestProvider);\n\n\n if (location != null) {\n\n onLocationChanged(location);\n\n\n } else {\n //This is what you need:\n locationManager.requestLocationUpdates(bestProvider, 1000, 0, (LocationListener) getActivity());\n }\n\n\n }", "public void getLocationInfo() {\n startLocationService();\n }", "private void fetchLastLocation() {\n try {\n FusedLocationProviderClient fusedLocationProviderClient = LocationServices.getFusedLocationProviderClient(this);\n //get last known location of device\n Task<Location> task = fusedLocationProviderClient.getLastLocation();\n\n task.addOnSuccessListener(new OnSuccessListener<Location>() {\n @Override\n public void onSuccess(Location location) {\n if (location != null) {\n //store current location\n currentLocation = location;\n Toast.makeText(MapsActivity.this, currentLocation.getLatitude() + \" \" + currentLocation.getLongitude(), Toast.LENGTH_SHORT).show();\n // Obtain the SupportMapFragment\n supportMapFragment = (SupportMapFragment) getSupportFragmentManager().findFragmentById(R.id.fragment_content);\n // Attach OnMapReadyCallback listener using getMapAsync(OnMapReadyCallback)\n // This listener notified when the map is ready by invoking onMapReady along with a GoogleMap object.\n supportMapFragment.getMapAsync(MapsActivity.this);\n } else {\n Toast.makeText(MapsActivity.this, \"No Location recorded\", Toast.LENGTH_SHORT).show();\n }\n }\n });\n } catch (SecurityException e) {\n Log.e(\"Exception: %s\", e.getMessage());\n }\n }", "private void updateLocationToServer() {\n\n if (Utility.isConnectingToInternet(getActivity())) {\n\n if (mGpsTracker.canGetLocation()) {\n\n if (Utility.ischeckvalidLocation(mGpsTracker)) {\n\n Animation fade1 = AnimationUtils.loadAnimation(getActivity(), R.anim.flip);\n btnRefreshLocation.startAnimation(fade1);\n Map<String, String> params = new HashMap<String, String>();\n if (!AppConstants.isGestLogin(getActivity())) {\n params.put(\"iduser\", SharedPref.getInstance().getStringVlue(getActivity(), userId));\n } else {\n params.put(\"iduser\", \"0\");\n }\n\n params.put(\"latitude\", \"\" + mGpsTracker.getLatitude());\n params.put(\"longitude\", \"\" + mGpsTracker.getLongitude());\n RequestHandler.getInstance().stringRequestVolley(getActivity(), AppConstants.getBaseUrl(SharedPref.getInstance().getBooleanValue(getActivity(), isStaging)) + updatelocation, params, this, 5);\n fade1.cancel();\n } else {\n mGpsTracker.showInvalidLocationAlert();\n }\n } else {\n showSettingsAlert(5);\n }\n } else {\n Utility.showInternetError(getActivity());\n }\n\n }", "private void getDeviceLocation() {\n try {\n if (mLocationPermissionGranted) {\n Task<Location> locationResult = mFusedLocationProviderClient.getLastLocation();\n locationResult.addOnCompleteListener(getActivity(), new OnCompleteListener<Location>() {\n @Override\n public void onComplete(@NonNull Task<Location> task) {\n if (task.isSuccessful()) {\n // Set the customer_map's camera position to the current location of the device.\n mLastKnownLocation = task.getResult();\n mMap.moveCamera(CameraUpdateFactory.newLatLngZoom(\n new LatLng(mLastKnownLocation.getLatitude(),\n mLastKnownLocation.getLongitude()), DEFAULT_ZOOM));\n getNearestDriver();\n } else {\n Log.d(TAG, \"Current location is null. Using defaults.\");\n Log.e(TAG, \"Exception: %s\", task.getException());\n mMap.moveCamera(CameraUpdateFactory\n .newLatLngZoom(mDefaultLocation, DEFAULT_ZOOM));\n mMap.getUiSettings().setMyLocationButtonEnabled(false);\n\n }\n }\n });\n }\n } catch (SecurityException e) {\n Log.e(\"Exception: %s\", e.getMessage());\n }\n }", "private void StartLocationUpdates() {\n mLocationRequest = new LocationRequest();\n mLocationRequest.setPriority(LocationRequest.PRIORITY_BALANCED_POWER_ACCURACY);\n mLocationRequest.setInterval(UPDATE_INTERVAL);\n mLocationRequest.setFastestInterval(FASTEST_INTERVAL);\n\n // Create LocationSettings object using location request\n LocationSettingsRequest.Builder builder = new LocationSettingsRequest.Builder();\n builder.addLocationRequest(mLocationRequest);\n LocationSettingsRequest locationSettingsRequest = builder.build();\n\n // Checks if location settings are OK\n SettingsClient settingsClient = LocationServices.getSettingsClient(context);\n settingsClient.checkLocationSettings(locationSettingsRequest);\n\n if (ActivityCompat.checkSelfPermission(context, Manifest.permission.ACCESS_FINE_LOCATION)\n != PackageManager.PERMISSION_GRANTED && ActivityCompat.checkSelfPermission\n (context, Manifest.permission.ACCESS_COARSE_LOCATION) != PackageManager.PERMISSION_GRANTED) {\n\n return;\n }else {\n getFusedLocationProviderClient(context).requestLocationUpdates(mLocationRequest, new LocationCallback() {\n @Override\n public void onLocationResult(LocationResult locationResult) {\n onLocationChanged(locationResult.getLastLocation());\n// getLastLocation();\n }\n },\n Looper.myLooper());\n }\n\n }", "private void startPlaceListActivity() {\n if (mLastLocation == null) {\n Toast.makeText(getContext(), getResources().getString(R.string.location_unavailable), Toast.LENGTH_SHORT).show();\n\n // after announcing user that their location is unknown, try getting their location again\n startLocationUpdate();\n\n } else {\n Intent intent = new Intent(getContext(), PlaceListActivity.class);\n intent.putExtra(PLACE_TYPE_KEY, mPlaceType);\n intent.putExtra(CURRENT_LOCATION_KEY, mLastLocation);\n startActivity(intent);\n }\n }", "public void onReportSunny(View view) {\n Location userLoc = LocationServices.FusedLocationApi.getLastLocation(\n MapsActivity.mGoogleApiClient);\n\n new AsyncPostRequest().execute(userLoc.getLatitude(), userLoc.getLongitude(), 0.0);\n }", "public void startLocationUpdates() {\n if(checkCoarseLocationPermission()) {\n LocationServices.FusedLocationApi.requestLocationUpdates(\n mGoogleApiClient, mLocationRequest, this);\n }\n }", "public void updateLoc()\n {\n driverLoc = new ParseGeoPoint(driverLocCord.latitude, driverLocCord.longitude);\n ParseUser.getCurrentUser().put(\"Location\", driverLoc);\n ParseUser.getCurrentUser().saveInBackground(new SaveCallback() {\n @Override\n public void done(ParseException e) {\n if(e==null){\n Toast.makeText(getApplicationContext(), \"Location Updated\", Toast.LENGTH_SHORT).show();\n }\n else{\n\n Toast.makeText(getApplicationContext(), \"Error in Location Update\", Toast.LENGTH_SHORT).show();\n e.printStackTrace();\n }\n }\n });\n\n\n populate();\n\n }", "public void onLocationChange() {\n\t\tupdateWeather();\n\t\tgetLoaderManager().restartLoader(FORECAST_LOADER_ID, null, this);\n\t}", "private void getDeviceLocation() {\n /*\n * Get the best and most recent location of the device, which may be null in rare\n * cases when a location is not available.\n */\n try {\n if (mLocationPermissionGranted) {\n Task<Location> locationResult = mFusedLocationProviderClient.getLastLocation();\n locationResult.addOnCompleteListener(this, new OnCompleteListener<Location>() {\n @Override\n public void onComplete(@NonNull Task<Location> task) {\n if (task.isSuccessful()) {\n // Set the map's camera position to the current location of the device.\n mLastKnownLocation = task.getResult();\n mMap.moveCamera(CameraUpdateFactory.newLatLngZoom(\n new LatLng(mLastKnownLocation.getLatitude(),\n mLastKnownLocation.getLongitude()), DEFAULT_ZOOM));\n showCurrentPlace();\n } else {\n Log.d(TAG, \"Current location is null. Using defaults.\");\n Log.e(TAG, \"Exception: %s\", task.getException());\n mMap.moveCamera(CameraUpdateFactory\n .newLatLngZoom(mDefaultLocation, DEFAULT_ZOOM));\n mMap.getUiSettings().setMyLocationButtonEnabled(false);\n }\n }\n });\n }\n } catch (SecurityException e) {\n Log.e(\"Exception: %s\", e.getMessage());\n }\n }", "private void getDeviceLocation() {\n /*\n * Get the best and most recent location of the device, which may be null in rare\n * cases when a location is not available.\n */\n try {\n if (mLocationPermissionGranted) {\n Task<Location> locationResult = mFusedLocationProviderClient.getLastLocation();\n locationResult.addOnCompleteListener(this, new OnCompleteListener<Location>() {\n @Override\n public void onComplete(@NonNull Task<Location> task) {\n if (task.isSuccessful()) {\n // Set the map's camera position to the current location of the device.\n mLastKnownLocation = task.getResult();\n currLatLng = new LatLng(mLastKnownLocation.getLatitude(), mLastKnownLocation.getLongitude());\n mMap.moveCamera(CameraUpdateFactory.newLatLngZoom(\n new LatLng(mLastKnownLocation.getLatitude(),\n mLastKnownLocation.getLongitude()), DEFAULT_ZOOM));\n destinationPoint.set(0,currLatLng);\n } else {\n Log.d(TAG, \"Current location is null. Using defaults.\");\n Log.e(TAG, \"Exception: %s\", task.getException());\n currLatLng = mDefaultLocation;\n mMap.moveCamera(CameraUpdateFactory\n .newLatLngZoom(mDefaultLocation, DEFAULT_ZOOM));\n mMap.getUiSettings().setMyLocationButtonEnabled(false);\n }\n }\n });\n }\n } catch (SecurityException e) {\n Log.e(\"Exception: %s\", e.getMessage());\n }\n }", "@Override\n\t\t\tpublic void onLocationSuccess(AMapLocation location) {\n\n\t\t\t\tmLoadingDialog.cancelDialog();\n\t\t\t\tll_mySite = new LatLng(location.getLatitude(), location\n\t\t\t\t\t\t.getLongitude());\n\n\t\t\t\tAppConfigUtil.LocalLocation.Location_latitude = String\n\t\t\t\t\t\t.valueOf(location.getLatitude());\n\t\t\t\tAppConfigUtil.LocalLocation.Location_longitude = String\n\t\t\t\t\t\t.valueOf(location.getLongitude());\n\t\t\t\tLatLng latLng;\n\t\t\t\tif (AppConfigUtil.LocalLocation.Location_latitude.equals(\"0.0\")\n\t\t\t\t\t\t|| AppConfigUtil.LocalLocation.Location_longitude\n\t\t\t\t\t\t\t\t.equals(\"0.0\")) {\n\t\t\t\t\tAppConfigUtil.LocalLocation.Location_latitude = MyApplication.Location_latitude;\n\t\t\t\t\tAppConfigUtil.LocalLocation.Location_longitude = MyApplication.Location_longitude;\n\t\t\t\t\tmNaviStart = new NaviLatLng(Double\n\t\t\t\t\t\t\t.valueOf(MyApplication.Location_latitude), Double\n\t\t\t\t\t\t\t.valueOf(MyApplication.Location_longitude));\n\t\t\t\t\tmStartPoints.add(mNaviStart);\n\t\t\t\t\tlatLng = new LatLng(Double\n\t\t\t\t\t\t\t.valueOf(MyApplication.Location_latitude), Double\n\t\t\t\t\t\t\t.valueOf(MyApplication.Location_longitude));\n\t\t\t\t} else {\n\t\t\t\t\tmNaviStart = new NaviLatLng(location.getLatitude(),\n\t\t\t\t\t\t\tlocation.getLongitude());\n\t\t\t\t\tmStartPoints.add(mNaviStart);\n\t\t\t\t\tlatLng = new LatLng(location.getLatitude(), location\n\t\t\t\t\t\t\t.getLongitude());\n\t\t\t\t}\n\n\t\t\t\t// 初始化当前位置\n\t\t\t\t// aMap.moveCamera(CameraUpdateFactory.newLatLng(latLng));\n\t\t\t\taMap.moveCamera(CameraUpdateFactory.zoomTo(14));\n\t\t\t\taMap.addMarker(new MarkerOptions()\n\t\t\t\t\t\t.position(latLng)\n\t\t\t\t\t\t.title(\"我的位置\")\n\t\t\t\t\t\t.icon(BitmapDescriptorFactory\n\t\t\t\t\t\t\t\t.fromResource(R.drawable.location_marker))\n\t\t\t\t\t\t.draggable(true));\n\t\t\t}", "private void getDeviceLocation(){\n mFusedLocationProviderClient = LocationServices.getFusedLocationProviderClient(this);\n\n try {\n if (mLocationPermissionsGranted) {\n\n final Task location = mFusedLocationProviderClient.getLastLocation();\n location.addOnCompleteListener(new OnCompleteListener() {\n @Override\n public void onComplete(@NonNull Task task) {\n if(task.isSuccessful()){\n\n Location currentLocation = (Location) task.getResult();\n\n if (currentLocation == null) {\n\n // Provide default current location\n\n currentLocation = new Location(\"\");\n currentLocation.setLatitude(51.454514);\n currentLocation.setLongitude(-2.587910);\n }\n\n } else {\n Helpers.showToast(getApplicationContext(), \"Could not get current location\");\n }\n }\n });\n }\n } catch (SecurityException e) {\n Helpers.showToast(getApplicationContext(), \"Could not get current location\");\n }\n }", "public void miUbicacion() { //Funcion que recupera la ubicacion\n\n if (ActivityCompat.checkSelfPermission(this, android.Manifest.permission.ACCESS_FINE_LOCATION) != PackageManager.PERMISSION_GRANTED &&\n ActivityCompat.checkSelfPermission(this, android.Manifest.permission.ACCESS_COARSE_LOCATION) != PackageManager.PERMISSION_GRANTED) {\n return;\n }\n LocationManager locationManager = (LocationManager) getSystemService(Context.LOCATION_SERVICE); //Se accede al sistema para el servicio de locatizacion\n Location location = locationManager.getLastKnownLocation(GPS_PROVIDER); //Se recupera la ultima localizacion conocida\n if(location != null) {\n new DownloadWebPageTask(location).execute(\"http://api.openweathermap.org/data/2.5/weather?lat=\" + location.getLatitude() + \"&lon=\" + location.getLongitude() +\n \"&units=metric&lang=fr&appid=5bdfb081811a28abc515bc673fc0d20f\");\n }\n locationManager.requestLocationUpdates(LocationManager.NETWORK_PROVIDER, 20000,0,locListenner); //Esto se hace cada 10s\n }", "@Override\n protected StopData[] doInBackground(Void... voids) {\n if(mLocation == null) {\n Log.e(TAG, \"location require to display activity\");\n return null;\n } else {\n Log.i(TAG, \"got location\");\n }\n ArrayList<StopData> stopData = StopService.createNearbyStopList(NearbyActivity.this, mLocation);\n final StopData[] adapterList = new StopData[stopData.size()];\n stopData.toArray(adapterList);\n return adapterList;\n }", "@SuppressLint(\"RestrictedApi\")\n protected void startLocationUpdates() {\n mLocationRequest = new LocationRequest();\n mLocationRequest.setPriority(LocationRequest.PRIORITY_HIGH_ACCURACY);\n mLocationRequest.setInterval(UPDATE_INTERVAL);\n mLocationRequest.setFastestInterval(FASTEST_INTERVAL);\n\n LocationSettingsRequest.Builder builder = new LocationSettingsRequest.Builder();\n builder.addLocationRequest(mLocationRequest);\n LocationSettingsRequest locationSettingsRequest = builder.build();\n\n SettingsClient settingsClient = LocationServices.getSettingsClient(this);\n settingsClient.checkLocationSettings(locationSettingsRequest);\n\n if (ActivityCompat.checkSelfPermission(this, Manifest.permission.ACCESS_FINE_LOCATION) != PackageManager.PERMISSION_GRANTED && ActivityCompat.checkSelfPermission(this, Manifest.permission.ACCESS_COARSE_LOCATION) != PackageManager.PERMISSION_GRANTED) {\n return;\n }\n getFusedLocationProviderClient(this).requestLocationUpdates(mLocationRequest, new LocationCallback() {\n @Override\n public void onLocationResult(LocationResult locationResult) {\n onLocationChanged(locationResult.getLastLocation());\n }\n },\n Looper.myLooper());\n }", "private void detectUserLocation(){\n \ttimestamp = System.currentTimeMillis();\n \tmLocationManager = (LocationManager) getSystemService(Context.LOCATION_SERVICE);\n\t\tCriteria criteria = new Criteria();\n\t\tcriteria.setAccuracy(Criteria.ACCURACY_FINE);\n\t\tcriteria.setCostAllowed(false);\n\t\tcriteria.setAltitudeRequired(false);\n\t\tcriteria.setPowerRequirement(Criteria.POWER_MEDIUM);\n\t\tString providerName = mLocationManager.getBestProvider(criteria, true);\n\t\tLog.d(TAG,\"Provider selected based on given criteria: \"+providerName);\n\t\tif(providerName != null)\n\t\t\tmLocationManager.requestLocationUpdates(providerName, 10000, 10, this);\n\t\telse\n\t\t\tLog.w(TAG,\"No provider\");\n }", "@Override\n public void onLocationChanged(Location location) {\n LocationServices.FusedLocationApi.removeLocationUpdates(mGoogleApiClient, this);\n \tmDiveSiteManager.saveLastLocation(location);\n }", "public abstract WeatherData[] getHourlyWeatherForecast(LocationCoordinate _location) throws Exception;", "private void moveToCurrentLocation() {\n \t\tGPSFilterLocationRetriever retriever = new GPSFilterLocationRetriever( new Criteria() );\n \t\tLocation loc = retriever.getLocation( this );\n \n \t\tif ( loc == null ) {\n \t\t\t// User turned off GPS, send it to device location settings.\n \t\t\tIntent i = new Intent( android.provider.Settings.ACTION_LOCATION_SOURCE_SETTINGS );\n \t\t\tthis.startActivity( i );\n \t\t} else {\n \t\t\t// First move to the last known location..\n \t\t\tthis.moveCameraToLocation( loc, false );\n \n \t\t\t// Check if location fix is out dated, if it is, request a new location, ONCE.\n \t\t\tlong elapsedTime = System.currentTimeMillis() - loc.getTime();\n \t\t\tif ( elapsedTime > MAX_LOCATION_FIX_AGE ) {\n \t\t\t\t// Therefore, we request a single fix.\n \t\t\t\tretriever.requestSingleUpdate( this, new LocationAdapter() {\n \t\t\t\t\t@Override\n \t\t\t\t\tpublic void onLocationChanged( Location loc ) {\n \t\t\t\t\t\tmoveCameraToLocation( loc, true );\n \t\t\t\t\t}\n \t\t\t\t} );\n \t\t\t}\n \t\t}\n \t}", "private void refresh() {\n progressDialog = new ProgressDialog(this);\n progressDialog.setMessage(\"Loading...\");\n progressDialog.show();\n\n textViewTemperature = (TextView) findViewById(R.id.textViewTemperature);\n textViewRain = (TextView) findViewById(R.id.textViewRain);\n textViewDescription = (TextView) findViewById(R.id.textViewDescription);\n textViewDescription = (TextView) findViewById(R.id.textViewDescription);\n icon = (ImageView) findViewById(R.id.icon);\n\n LocationManager lm = (LocationManager) getSystemService(Context.LOCATION_SERVICE);\n if (ActivityCompat.checkSelfPermission(this, android.Manifest.permission.ACCESS_FINE_LOCATION) != PackageManager.PERMISSION_GRANTED && ActivityCompat.checkSelfPermission(this, android.Manifest.permission.ACCESS_COARSE_LOCATION) != PackageManager.PERMISSION_GRANTED) {\n\n\n ActivityCompat.requestPermissions(this,\n new String[]{Manifest.permission.ACCESS_FINE_LOCATION, Manifest.permission.ACCESS_COARSE_LOCATION },\n 0);\n\n progressDialog.dismiss();\n return;\n }\n try {\n Location location2 = lm.getLastKnownLocation(LocationManager.GPS_PROVIDER);\n final double longitude = location2.getLongitude();\n final double latitude = location2.getLatitude();\n latlong.clear();\n latlong.add(latitude);\n latlong.add(longitude);\n location.clear();\n location.add(latlong.get(0) + \",\" + latlong.get(1));\n } catch (Exception e) {\n Log.d(\"BAD\", \"unable to pull location\");\n }\n\n new AsyncTask<Void, Void, Void>() {\n protected Void doInBackground(Void... voids) {\n try {\n URL url;\n if (location.size() == 0) {\n url = new URL(\"https://api.darksky.net/forecast/5711edd00f69e7c3d178667848166542/\" + \"37.85267,-122.4233\");\n } else {\n url = new URL(\"https://api.darksky.net/forecast/5711edd00f69e7c3d178667848166542/\" + location.get(0));\n }\n HttpURLConnection conn = (HttpURLConnection) url.openConnection();\n conn.setRequestMethod(\"GET\");\n InputStream in = new BufferedInputStream(conn.getInputStream());\n String response = convertStreamToString(in);\n JSONObject json = new JSONObject(response);\n Log.d(\"DEBUG\", json.toString());\n temperature = json.getJSONObject(\"currently\").getString(\"temperature\");\n double value = Double.parseDouble(temperature);\n int temp = (int) Math.round(value);\n\n formattedTemperature = Integer.toString(temp);\n\n\n description = json.getJSONObject(\"currently\").getString(\"summary\");\n iconType = json.getJSONObject(\"currently\").getString(\"icon\");\n JSONArray minuteData = json.getJSONObject(\"minutely\").getJSONArray(\"data\");\n willRainInCurrentHour = false;\n\n willRainInCurrentHour = false;\n for (int i = 0; i < 60; i ++) {\n if (minuteData.getJSONObject(i).getInt(\"precipProbability\") > 0) {\n willRainInCurrentHour = true;\n long unixSeconds = minuteData.getJSONObject(i).getInt(\"time\");\n Date date = new Date(unixSeconds*1000L); // *1000 is to convert seconds to milliseconds\n SimpleDateFormat sdf = new SimpleDateFormat(\"h:mm a\"); // the format of your date\n sdf.setTimeZone(TimeZone.getTimeZone(\"GMT-7\")); // give a timezone reference for formating (see comment at the bottom\n formattedTime = sdf.format(date);\n break;\n }\n }\n\n } catch (MalformedURLException e) {\n e.printStackTrace();\n Log.e(\"bad\", \"url\");\n } catch (ProtocolException p) {\n p.printStackTrace();\n Log.e(\"bad\", \"protocol\");\n } catch (IOException e) {\n e.printStackTrace();\n Log.e(\"bad\", \"io\");\n } catch (Exception e) {\n e.printStackTrace();\n Log.e(\"bad\", e.getMessage());\n }\n return null;\n }\n\n @Override\n protected void onProgressUpdate(Void... values) { }\n\n @Override\n protected void onPostExecute(Void aVoid) {\n\n progressDialog.dismiss();\n\n textViewTemperature.setText(formattedTemperature + \"°\");\n textViewDescription.setText(description);\n\n if (willRainInCurrentHour) {\n\n textViewRain.setText(\"It will rain at \" + formattedTime);\n }\n\n if (!willRainInCurrentHour) {\n textViewRain.setText(\"It will not rain in the next hour!\");\n }\n\n if (iconType.equals(\"clear-day\")) {\n icon.setImageResource(R.drawable.ic_brightness_high_black_24dp);\n }\n else if (iconType.equals(\"clear-night\")) {\n icon.setImageResource(R.drawable.ic_brightness_2_black_24dp);\n }\n else {\n icon.setImageResource(R.drawable.ic_cloud_queue_black_24dp);\n }\n }\n }.execute();\n\n }", "private void updateWithNewLocation(Location location)\n {\n\n float fLatitude = (float)0.0;\n float fLongitude = (float)0.0;\n float fHepe=(float)10000.0;\n byte ucNapUsed = 0;\n byte ucWiperErrorCode = 0;\n\n if (Config.LOGD) Log.d(TAG,\"Network Location callback\");\n\n if( location != null)\n {\n //read params from location structure return by WPS\n fLatitude = (float)(location.getLatitude());\n fLongitude = (float)(location.getLongitude());\n fHepe = location.getAccuracy();\n\n if(bScanCompleted == true)\n {\n ucNapUsed= (byte)aResults.size();\n }\n else\n {\n ucNapUsed = 50;\n }\n\n }\n else\n {\n ucWiperErrorCode = 99;\n }\n startWiperReport();\n native_notify_wiper_position(fLatitude,fLongitude,fHepe,ucNapUsed,ucWiperErrorCode);\n endWiperReport();\n\n }", "@Override\n public void onLocationChanged(Location location)\n {\n stopLocationUpdates();\n isRequestingLocationUpdates = false;\n\n LinearLayoutManager linearLayoutManager = new LinearLayoutManager(getActivity());\n nearbyBusStopsRecyclerView.setLayoutManager(linearLayoutManager);\n adaptor = new NearbyBusStopsRecyclerViewAdapter(getContext(), busStops);\n nearbyBusStopsRecyclerView.setAdapter(adaptor);\n\n try\n {\n if (CommonMethods.checkNetworkConnectivity(getActivity()))\n {\n URL nearestBusStopURL = new URL(\"http://bmtcmob.hostg.in/api/busstops/stopnearby/lat/\" +\n location.getLatitude() + \"/lon/\" + location.getLongitude() + \"/rad/1.0\");\n nearestBusStopsTask = new NearestBusStopsTask(this);\n nearestBusStopsTask.executeOnExecutor(AsyncTask.THREAD_POOL_EXECUTOR, nearestBusStopURL);\n }\n else\n {\n showError(R.drawable.ic_cloud_off_black, R.string.error_message_internet_unavailable,\n R.string.fix_error_retry);\n nearbyBusStopsRecyclerView.setVisibility(View.GONE);\n }\n }\n catch (MalformedURLException e)\n {\n showError(R.drawable.ic_sad_face, R.string.error_message_url_exception,\n R.string.fix_error_retry);\n nearbyBusStopsRecyclerView.setVisibility(View.GONE);\n }\n }", "public Location getLocation() {\n /* if ( Build.VERSION.SDK_INT >= 23 &&\n ContextCompat.checkSelfPermission( mContext, android.Manifest.permission.ACCESS_FINE_LOCATION ) != PackageManager.PERMISSION_GRANTED ) {\n Toast.makeText(mContext,\"Permission is not granted so returning back \",Toast.LENGTH_LONG).show();\n// showSettingsAlert();\n return null ;\n }*/\n\n try {\n\n locationManager = (LocationManager) mContext.getSystemService(LOCATION_SERVICE);\n\n Criteria criteria = new Criteria();\n provider = locationManager.getBestProvider(criteria, false);\n if(provider != null) {\n Location location = locationManager.getLastKnownLocation(provider);\n\n // Initialize the location fields\n if (location != null) {\n System.out.println(\"Provider \" + provider + \" has been selected.\");\n onLocationChanged(location);\n resumeGpsService();\n }\n }else {\n// ISSUtils.checkPermission(mContext);\n }\n\n\n }catch (SecurityException secx) {\n secx.printStackTrace();\n// ISSUtils.checkPermission(mContext);\n showSettingsAlert();\n }\n catch (Exception e) {\n e.printStackTrace();\n }\n\n return location;\n }", "public void locate()\n\t{\n\t\tlocationClient = new LocationClient(Main.activity.getApplicationContext()); // 实例化LocationClient类\n\t\t\t\t\n\t\tlocationClient.registerLocationListener(myListener); // 注册监听函数\n\t\tthis.setLocationOption();\t//设置定位参数\n\t\tlocationClient.start(); // 开始定位\n\t\tlocationClient.requestLocation();\n\t}", "@Override\n public void requestWeatherSuccess(Weather weather, Location requestLocation) {\n try {\n if (request != null) {\n List<WeatherInfo.DayForecast> forecastList = new ArrayList<>();\n for (int i = 0; i < weather.dailyList.size(); i++) {\n forecastList.add(\n new WeatherInfo.DayForecast.Builder(\n WeatherConditionConvertHelper.getConditionCode(\n weather.dailyList.get(i).weatherKinds[0],\n true))\n .setHigh(weather.dailyList.get(i).temps[0])\n .setLow(weather.dailyList.get(i).temps[1])\n .build());\n }\n WeatherInfo.Builder builder = new WeatherInfo.Builder(\n weather.base.city,\n weather.realTime.temp,\n WeatherContract.WeatherColumns.TempUnit.CELSIUS)\n .setWeatherCondition(\n WeatherConditionConvertHelper.getConditionCode(\n weather.realTime.weatherKind,\n TimeManager.getInstance(this)\n .getDayTime(this, weather, false)\n .isDayTime()))\n .setTodaysHigh(weather.dailyList.get(0).temps[0])\n .setTodaysLow(weather.dailyList.get(0).temps[1])\n .setTimestamp(weather.base.timeStamp)\n .setHumidity(\n Double.parseDouble(\n weather.index.humidities[1]\n .split(\" : \")[1]\n .split(\"%\")[0]))\n .setWind(\n Double.parseDouble(weather.realTime.windSpeed.split(\"km/h\")[0]),\n weather.realTime.windDegree,\n WeatherContract.WeatherColumns.WindSpeedUnit.KPH)\n .setForecast(forecastList);\n\n request.complete(new ServiceRequestResult.Builder(builder.build()).build());\n }\n } catch (Exception ignore) {\n requestWeatherFailed(requestLocation);\n }\n }", "public void showTodayForecast(View view) {\n Log.i(\"User input\", cityUserInput.getText().toString());\n //String cityName = cityUserInput.getText().toString().trim();\n String cityName = null;\n todayInfo = new ArrayList<>();\n try {\n cityName = URLEncoder.encode(cityUserInput.getText().toString(), \"UTF-8\");\n if (cityName.equals(\"\")){\n Toast.makeText(getApplicationContext(), \"Using default city: london\", Toast.LENGTH_SHORT).show();\n cityName = \"london\";\n }\n } catch (UnsupportedEncodingException e) {\n e.printStackTrace();\n }\n String url = \"http://api.openweathermap.org/data/2.5/weather?q=\" + cityName + \"&appid=5c7c917f2eedbebf85086c5fab2569d2\";\n //FragmentA fragmentA = new FragmentA();\n //FragmentA.DownloadTask downloadTask = fragmentA.new DownloadTask();\n FragmentA.TodayWeatherTask downloadTask = f1.new TodayWeatherTask();\n downloadTask.execute(url);\n\n\n\n\n //TODO: get arraylist containing today's information\n //launchTodayFragment(todayInfo);\n }", "private void updateGPS() {\n fusedLocationProviderClient = LocationServices.getFusedLocationProviderClient(Location.this);\n\n if (ActivityCompat.checkSelfPermission(this, Manifest.permission.ACCESS_FINE_LOCATION) == PackageManager.PERMISSION_GRANTED) {\n fusedLocationProviderClient.getLastLocation().addOnSuccessListener(this, new OnSuccessListener<android.location.Location>() {\n @Override\n public void onSuccess(android.location.Location location) {\n updateUI(location);\n }\n });\n } else {\n //permission not granted, we will ask for it\n if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.M) {\n requestPermissions(new String[]{Manifest.permission.ACCESS_FINE_LOCATION}, 99);\n }\n }\n }", "private Location getLastKnownLocation(){\n \t \tLocation loc = LocationUtil.getBestLastKnowLocation(ctx);\t\n \t \tStatus.getCurrentStatus().setLocation(loc);\t\n \t \treturn loc;\n \t}", "private void startLocationUpdates() {\n Log.d(LOG_TAG, \"startLocationUpdates() called\");\n fusedLocationClient.requestLocationUpdates(locationRequest, locationCallback, Looper.getMainLooper());\n }", "@Override\n\tprotected String doInBackground(String... params) {\n\t\tgetLocation();\n\t\treturn null;\n\t}", "@Override\n public void onSuccess(Location location) {\n if (location != null) {\n onLocationChanged(location);\n findNearbyHospitals(location);\n }\n }", "@Override\n public void onLocationChanged( final Location location ) {\n if (location!=null) {\n // sore last location as member, in case it is needed somewhere (in e.g. your adjusted project)\n MainActivity.this.lastKnownLocaton = location;\n if ( MainActivity.this.architectView != null ) {\n // check if location has altitude at certain accuracy level & call right architect method (the one with altitude information)\n if ( location.hasAltitude() && location.hasAccuracy() && location.getAccuracy()<7) {\n MainActivity.this.architectView.setLocation( location.getLatitude(), location.getLongitude(), location.getAltitude(), location.getAccuracy() );\n } else {\n MainActivity.this.architectView.setLocation( location.getLatitude(), location.getLongitude(), location.hasAccuracy() ? location.getAccuracy() : 1000 );\n }\n }\n }\n }", "private void getCurrentLocation() {\n try {\n if (locationPermissionGranted) {\n Task<Location> locationResult = fusedLocationClient.getLastLocation();\n locationResult.addOnCompleteListener(this, new OnCompleteListener<Location>() {\n @Override\n public void onComplete(@NonNull Task<Location> task) {\n if (task.isSuccessful()) {\n // Set the map's camera position to the current location of the device.\n lastKnownLocation = task.getResult();\n if (lastKnownLocation != null) {\n map.moveCamera(CameraUpdateFactory.newLatLngZoom(\n new LatLng(lastKnownLocation.getLatitude(),\n lastKnownLocation.getLongitude()), DEFAULT_ZOOM));\n updateCameraBearing(map, location.getBearing());\n }\n }\n }\n });\n }\n } catch (SecurityException e) {\n Log.e(\"Exception: %s\", e.getMessage(), e);\n }\n }", "private UserLocation getLocation() {\n if (ContextCompat.checkSelfPermission(this, Manifest.permission.ACCESS_FINE_LOCATION) != PackageManager.PERMISSION_GRANTED) {\n\n if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.M) {\n\n if (ActivityCompat.shouldShowRequestPermissionRationale(this, Manifest.permission.ACCESS_FINE_LOCATION)) {\n Toast.makeText(this, \"The Location Permission is needed to show the weather \", Toast.LENGTH_SHORT).show();\n } else {\n ActivityCompat.requestPermissions(this,\n new String[]{Manifest.permission.ACCESS_FINE_LOCATION},\n REQUEST_LOCATION_CODE_PERMISSION);\n }\n }\n\n } else {\n Log.d(TAG, \"getLocation: Permission Granted\");\n mFusedLocationClient.getLastLocation().addOnSuccessListener(new OnSuccessListener<Location>() {\n @Override\n public void onSuccess(Location location) {\n if (location != null) {\n msLocation = location;\n userLocation.setLat(location.getLatitude());\n userLocation.setLon(location.getLongitude());\n\n mLocationText.setText(getString(R.string.location_text\n , msLocation.getLatitude()\n , msLocation.getLongitude()\n , msLocation.getTime()));\n RelativeLayout.LayoutParams params = new RelativeLayout.LayoutParams(RelativeLayout.LayoutParams.WRAP_CONTENT, RelativeLayout.LayoutParams.WRAP_CONTENT);\n params.addRule(RelativeLayout.CENTER_HORIZONTAL);\n mLocationText.setGravity(Gravity.CENTER_HORIZONTAL);\n mLocationText.setLayoutParams(params);\n mLocationText.setTextSize(24);\n\n } else {\n mLocationText.setText(R.string.no_location);\n }\n }\n });\n\n }\n return userLocation;\n }", "@Override\n public void onLocationChanged(Location location) {\n Log.i(LOG_TAG, \"Location Change\");\n Location target = new Location(\"target\");\n String closePoint;\n int closestIndex = -1;// Default to none\n float minDistance = 1000; // Default to high value\n\n // Focus camera on initial location\n if (mapReady == true && initialCameraSet == true) {\n LatLng initialLocation = new LatLng(location.getLatitude(), location.getLongitude());\n gMap.moveCamera(CameraUpdateFactory.newLatLng(initialLocation));\n initialCameraSet = false; // Initial location already displayed\n }\n // Check if spot is close\n for (int i = 0; i < LocationsClass.spotsCoordinates.length; ++i) {\n target.setLatitude(LocationsClass.spotsCoordinates[i].latitude);\n target.setLongitude(LocationsClass.spotsCoordinates[i].longitude);\n if (location.distanceTo(target) < minDistance) {\n closestIndex = i; //Save closes index\n minDistance = location.distanceTo(target); // update minDistance\n }\n }\n\n if (minDistance < 200 && minDistance > 20) {\n Toast.makeText(getActivity(), \"Location: \" + LocationsClass.spotNames[closestIndex] +\n \" is within 200 meters!\\n\" + \"Go check it out!\", Toast.LENGTH_LONG).show();\n// pointsOfInterests.get(closestIndex).showInfoWindow();\n// gMap.getUiSettings().setMapToolbarEnabled(true);\n popNotification = true; // Allow notification to trigger when user reaches destination\n } else if (minDistance < 20) {\n if (closestIndex != currentUserLocation) {\n int locationId = getResources().getIdentifier(\"loc_\"+closestIndex, \"drawable\", getActivity().getPackageName());\n showArrivalNotification(locationId, LocationsClass.spotNames[closestIndex]);\n currentUserLocation = closestIndex; // Update user location\n }\n }\n\n if (hotspotIndex != -1) {\n pointsOfInterests.get(hotspotIndex).showInfoWindow();\n gMap.getUiSettings().setMapToolbarEnabled(true);\n }\n }", "protected void startLocationUpdates() {\n mLocationRequest = new LocationRequest();\n mLocationRequest.setPriority(LocationRequest.PRIORITY_HIGH_ACCURACY);\n mLocationRequest.setInterval(UPDATE_INTERVAL);\n //mLocationRequest.setFastestInterval(FASTEST_INTERVAL);\n\n // Create LocationSettingsRequest object using location request\n LocationSettingsRequest.Builder builder = new LocationSettingsRequest.Builder();\n builder.addLocationRequest(mLocationRequest);\n LocationSettingsRequest locationSettingsRequest = builder.build();\n\n // Check whether location settings are satisfied\n // https://developers.google.com/android/reference/com/google/android/gms/location/SettingsClient\n SettingsClient settingsClient = LocationServices.getSettingsClient(this);\n settingsClient.checkLocationSettings(locationSettingsRequest);\n\n // new Google API SDK v11 uses getFusedLocationProviderClient(this)\n try{\n getFusedLocationProviderClient(this).requestLocationUpdates(mLocationRequest, new LocationCallback() {\n @Override\n public void onLocationResult(LocationResult locationResult) {\n onLocationChanged(locationResult.getLastLocation(),false);\n }\n },\n Looper.myLooper());\n }\n catch(SecurityException e){\n e.printStackTrace();\n }\n\n }", "public void updateWeatherData(String location, int locationType) throws Exception {\n weatherRetriever.getForecast(location,locationType);\n //currentLocation = location;\n weatherRetriever.loadWeatherCache(location);\n }", "protected void startLocationUpdates() {\n mLocationRequest = LocationRequest.create()\n .setPriority(LocationRequest.PRIORITY_BALANCED_POWER_ACCURACY)\n .setInterval(1000000)\n .setFastestInterval(1000000);\n // Request location updates\n if (ActivityCompat.checkSelfPermission(this, android.Manifest.permission.ACCESS_COARSE_LOCATION) == PackageManager.PERMISSION_GRANTED) {\n LocationServices.FusedLocationApi.requestLocationUpdates(mGoogleApiClient, mLocationRequest, new LocationListener() {\n @Override\n public void onLocationChanged(Location location) {\n mLastLocation = location;\n }\n });\n }\n\n }", "@Override\n protected void onPostExecute(Weather weather) {\n }", "private void configMyLocation() {\n try {\n if (ActivityCompat.checkSelfPermission(this, Manifest.permission.ACCESS_FINE_LOCATION) != PackageManager.PERMISSION_GRANTED && ActivityCompat.checkSelfPermission(this, Manifest.permission.ACCESS_COARSE_LOCATION) != PackageManager.PERMISSION_GRANTED) {\n // TODO: Consider calling\n // ActivityCompat#requestPermissions\n // here to request the missing permissions, and then overriding\n // public void onRequestPermissionsResult(int requestCode, String[] permissions,\n // int[] grantResults)\n // to handle the case where the user grants the permission. See the documentation\n // for ActivityCompat#requestPermissions for more details.\n return;\n }\n\n FusedLocationProviderClient locationProviderClient = LocationServices.getFusedLocationProviderClient(this);\n\n locationProviderClient.getLastLocation().addOnCompleteListener(new OnCompleteListener<Location>() {\n @Override\n public void onComplete(@NonNull Task<Location> task) {\n Location location = task.getResult();\n LatLng sd = new LatLng(location.getLatitude(), location.getLongitude());\n\n mMap.addMarker(new MarkerOptions().position(sd).title(\"you are here\").icon(BitmapDescriptorFactory.defaultMarker()));\n mMap.moveCamera(CameraUpdateFactory.newLatLng(sd));\n mMap.moveCamera(CameraUpdateFactory.newLatLngZoom(sd, MAP_ZOOM));\n\n model.setLongitude(location.getLatitude());\n model.setLatitude(location.getLongitude());\n }\n });\n }catch (Exception ex){\n Constant.showMessage(\"Exception\", ex.getMessage(), this);\n }\n }", "private void getDeviceLocation() {\n /*\n * Get the best and most recent location of the device, which may be null in rare\n * cases when a location is not available.\n */\n try {\n if (mLocationPermissionGranted) {\n Task<Location> locationResult = mFusedLocationProviderClient.getLastLocation();\n locationResult.addOnCompleteListener(mActivity, new OnCompleteListener<Location>() {\n @Override\n public void onComplete(@NonNull Task<Location> task) {\n if (task.isSuccessful()) {\n // Set the map's camera position to the current location of the device.\n mLastKnownLocation = task.getResult();\n mMap.moveCamera(CameraUpdateFactory.newLatLngZoom(\n new LatLng(mLastKnownLocation.getLatitude(),\n mLastKnownLocation.getLongitude()), DEFAULT_ZOOM));\n } else {\n Log.d(TAG, \"Current location is null. Using defaults.\");\n Log.e(TAG, \"Exception: %s\", task.getException());\n mMap.moveCamera(CameraUpdateFactory\n .newLatLngZoom(mDefaultLocation, DEFAULT_ZOOM));\n mMap.getUiSettings().setMyLocationButtonEnabled(false);\n }\n }\n });\n }\n } catch (SecurityException e) {\n Log.e(\"Exception: %s\", e.getMessage());\n }\n }", "public void getLocation() {\n\t\tThread locationThread = new Thread(new Runnable(){\n\t\t\tpublic void run(){\n\t\t\t\ttry{\n\t\t\t\t\tURL url = new URL(\"http://ip-api.com/json\");\n\t\t\t\t\tURLConnection connection = url.openConnection();\n\t\t\t\t\n\t\t\t\t\tString line;\n\t\t\t\t\tStringBuilder builder = new StringBuilder();\n\t\t\t\t\tBufferedReader reader = new BufferedReader(new InputStreamReader(connection.getInputStream()));\n\t\t\t\t\twhile ((line = reader.readLine()) != null) {\n\t\t\t\t\t\tbuilder.append(line);\n\t\t\t\t\t}\n\t\t\t\t\n\t\t\t\t\tJSONObject json = new JSONObject(builder.toString());\n\t\t\t\t\tString status = json.getString(\"status\");\n\t\t\t\t\tSystem.out.println(\"Location retrieval was: \" + status);\n\t\t\t\t\tif(status.equals(\"success\")){\n\t\t\t\t\t\tcity = json.getString(\"city\");\n\t\t\t\t\t\tzipCode = json.getString(\"zip\");\n\t\t\t\t\t\tcountryCode = json.getString(\"countryCode\");\n\t\t\t\t\t}else{\n\t\t\t\t\t\tSystem.out.println(\"Failed to retreive location\");\n\t\t\t\t\t}\n\t\t\t\t}catch(IOException e){\n\t\t\t\t\te.printStackTrace();\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\t\t\n\t\tif(!locationThread.isAlive()){\n\t\t\tlocationThread.start();\n\t\t}else{\n\t\t\ttry {\n\t\t\t\tlocationThread.join();\n\t\t\t} catch (InterruptedException e) {\n\t\t\t\te.printStackTrace();\n\t\t\t}\n\t\t\tlocationThread.start();\n\t\t}\n\t}", "@Override\n public void onLocationChanged(Location location) {\n Intent i = new Intent(\"location_update\");\n i.putExtra(\"coordinates\", location.getLongitude() + \" \" + location.getLatitude());\n home_loc = new FileCacher<>(getApplicationContext(), \"myloc.txt\");\n\n if (home_loc.hasCache()) {\n try {\n double lat1 = location.getLatitude();\n double long1 = location.getLongitude();\n String loc = home_loc.readCache();\n String[] coors1 = {Double.toString(long1), Double.toString(lat1)};\n if (loc != null) {\n Log.i(\"loc\", loc);\n coors1 = loc.split(\" \");\n }\n\n double lat2 = Double.parseDouble(coors1[1]);\n double long2 = Double.parseDouble(coors1[0]);\n double dist = distance(lat1, lat2, long1, long2);\n Log.i(\"dist\", Double.toString(dist));\n if (dist > thresh) {\n i.putExtra(\"exceed\", \"true\");\n } else {\n i.putExtra(\"exceed\", \"false\");\n }\n\n } catch (IOException e) {\n e.printStackTrace();\n }\n }\n sendBroadcast(i);\n }", "public void getLocation() {\n\n\t\t// If Google Play Services is available\n\t\tif (servicesConnected()) {\n\t\t\t// Get the current location\n\t\t\tLocation currentLocation = mLocationClient.getLastLocation();\n\n\t\t\t// Display the current location in the UI\n\t\t\tmLatLng.setText(LocationUtils.getLatLng(this, currentLocation));\n\n\t\t\tlatCurrent=(float) currentLocation.getLatitude();\n\t\t\tlntCurrent=(float) currentLocation.getLongitude();\n\n\t\t}\n\t}" ]
[ "0.78250885", "0.6671968", "0.6236452", "0.617458", "0.6131493", "0.6023559", "0.60186607", "0.5975055", "0.59009576", "0.57774365", "0.57648987", "0.57520807", "0.5716909", "0.57083607", "0.56906146", "0.568748", "0.5671762", "0.5647495", "0.5646127", "0.56407785", "0.5624708", "0.56244916", "0.5605183", "0.55799127", "0.5570059", "0.55650985", "0.55434954", "0.55383664", "0.5533333", "0.5519321", "0.5517466", "0.5517466", "0.5511373", "0.5506563", "0.5497721", "0.54779875", "0.5461529", "0.545878", "0.5438691", "0.54366684", "0.54363924", "0.54309374", "0.5421105", "0.5417325", "0.5414663", "0.5404626", "0.5395625", "0.5394169", "0.5393334", "0.5379615", "0.53778046", "0.537621", "0.536659", "0.5360702", "0.5359683", "0.5345035", "0.5340374", "0.53377366", "0.5316371", "0.5315046", "0.5300871", "0.52987474", "0.5282483", "0.52788234", "0.52748835", "0.5270388", "0.526914", "0.52665323", "0.5266265", "0.5265466", "0.5256602", "0.5253229", "0.52518475", "0.52446884", "0.52428037", "0.52412075", "0.52372503", "0.5235569", "0.52295554", "0.5222513", "0.5217013", "0.5213914", "0.5207227", "0.52043", "0.5202375", "0.52000874", "0.51994246", "0.5196842", "0.519347", "0.51919156", "0.5191699", "0.51686174", "0.51607686", "0.5153674", "0.5153639", "0.5151991", "0.5139298", "0.5135738", "0.5132612", "0.5126648" ]
0.8358875
0
give option to change location settings or select a location manually
@Override public void error() { Log.e("MAIN","Error finding best guess location"); dS.lat=0; dS.lon=0; if(once) { //promptSetLocationService(MainActivity.this); } once=false; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void onClickLocationSettings(View view) {\n startActivity(new Intent(android.provider.Settings.ACTION_LOCATION_SOURCE_SETTINGS));\n }", "private void pickLocation() {\n // By default the location picker will enable all the included buttons like\n // Satellite view and position me\n Intent locationPicker = new LocationPickerActivity.Builder().build(this.getContext());\n startActivityForResult(locationPicker, LOCATION_REQUEST_CODE);\n }", "private void updateLocationUi() {\n if (mMap == null) {\n return;\n }\n try {\n if (mPermissionCheck.locationPermissionGranted()) {\n mMap.setMyLocationEnabled(true);\n mMap.getUiSettings().setMyLocationButtonEnabled(true);\n } else {\n mMap.setMyLocationEnabled(false);\n mMap.getUiSettings().setMyLocationButtonEnabled(false);\n }\n } catch (SecurityException e) {\n Log.e(\"Exception: %s\", e.getMessage());\n }\n }", "public void setLocation(String location);", "private void updateLocationUI() {\n if (map == null) {\n return;\n }\n try {\n if (locationPermissionGranted) {\n map.setMyLocationEnabled(true);\n map.getUiSettings().setMyLocationButtonEnabled(true);\n } else {\n map.setMyLocationEnabled(false);\n map.getUiSettings().setMyLocationButtonEnabled(false);\n lastKnownLocation = null;\n getLocationPermission();\n }\n } catch (SecurityException e) {\n Log.e(\"Exception: %s\", e.getMessage());\n }\n }", "@Override\r\n public void getLocation(Location location) {\r\n if(!(REQUEST==PLACE_AUTOCOMPLETE_REQUEST_CODE || REQUEST==OPEN_SETTINGS)){\r\n mCurrentLocation = location;\r\n moveToCurrentLocation();\r\n }\r\n }", "private void launchGPSOptions() {\n final ComponentName toLaunch = new ComponentName(\"com.android.settings\",\"com.android.settings.SecuritySettings\");\n final Intent intent = new Intent(Settings.ACTION_LOCATION_SOURCE_SETTINGS);\n intent.addCategory(Intent.CATEGORY_LAUNCHER);\n intent.setComponent(toLaunch);\n intent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK);\n startActivityForResult(intent, 0);\n }", "private void updateLocationUI() {\n if (mMap == null) {\n return;\n }\n try {\n if (mLocationPermissionGranted) {\n mMap.setMyLocationEnabled(true);\n mMap.getUiSettings().setMyLocationButtonEnabled(true);\n } else {\n mMap.setMyLocationEnabled(false);\n mMap.getUiSettings().setMyLocationButtonEnabled(false);\n mLastKnownLocation = null;\n getLocationPermission();\n }\n } catch (SecurityException e) {\n Log.e(\"Exception: %s\", e.getMessage());\n }\n }", "private void updateLocationUI() {\n if (mMap == null) {\n return;\n }\n try {\n if (mLocationPermissionGranted) {\n mMap.setMyLocationEnabled(true);\n mMap.getUiSettings().setMyLocationButtonEnabled(true);\n } else {\n mMap.setMyLocationEnabled(false);\n mMap.getUiSettings().setMyLocationButtonEnabled(false);\n mLastKnownLocation = null;\n getLocationPermission();\n }\n } catch (SecurityException e) {\n Log.e(\"Exception: %s\", e.getMessage());\n }\n }", "private void updateLocationUI() {\n if (mMap == null) {\n return;\n }\n try {\n if (mLocationPermissionGranted) {\n mMap.setMyLocationEnabled(true);\n mMap.getUiSettings().setMyLocationButtonEnabled(true);\n } else {\n mMap.setMyLocationEnabled(false);\n mMap.getUiSettings().setMyLocationButtonEnabled(false);\n mLastKnownLocation = null;\n getLocationPermission();\n }\n } catch (SecurityException e) {\n Log.e(\"Exception: %s\", e.getMessage());\n }\n }", "@Override\n public void onClick(DialogInterface dialog, int which) {\n Intent intent1 = new Intent(Settings.ACTION_LOCATION_SOURCE_SETTINGS);\n startActivity(intent1);\n }", "public void selectLocation(String location) {\n selectedLocation = location;\n }", "public void onClick(DialogInterface dialog, int id) {\n Intent callGPSSettingIntent = new Intent(\n android.provider.Settings.ACTION_LOCATION_SOURCE_SETTINGS);\n startActivity(callGPSSettingIntent);\n }", "private void updateLocationUI() {\n if (mMap == null) {\n return;\n }\n try {\n if (mLocationPermissionGranted) {\n mMap.setMyLocationEnabled(true);\n mMap.getUiSettings().setMyLocationButtonEnabled(false);\n } else {\n mMap.setMyLocationEnabled(false);\n mMap.getUiSettings().setMyLocationButtonEnabled(false);\n mLastKnownLocation = null;\n getLocationPermission();\n }\n } catch (SecurityException e) {\n Log.e(\"Exception: %s\", e.getMessage());\n }\n }", "private boolean setLocationInformation() {\n try {\n this.mPostModel.setLocationPost(mAutoCompleteTextView.getText().toString());\n\n if (StringEmptyUtil.isEmptyString(this.mPostModel.getLocationPost())) {\n Toast.makeText(getApplicationContext(), \"Please Select Location\", Toast.LENGTH_LONG).show();\n return false;\n }\n\n this.drop_location.setVisibility(View.VISIBLE);\n this.location_view.setVisibility(View.VISIBLE);\n this.current_location.setVisibility(View.VISIBLE);\n this.current_location.setText(this.mPostModel.getLocationPost());\n return true;\n } catch (Exception ex) {\n ex.printStackTrace();\n }\n Toast.makeText(getApplicationContext(), \"Please Select Location\", Toast.LENGTH_LONG).show();\n\n return false;\n }", "private void updateLocationUI() {\n if (mMap == null) {\n return;\n }\n /*\n * Request location permission, so that we can get the location of the\n * device. The result of the permission request is handled by a callback,\n * onRequestPermissionsResult.\n */\n if (ContextCompat.checkSelfPermission(this.getApplicationContext(),\n android.Manifest.permission.ACCESS_FINE_LOCATION)\n == PackageManager.PERMISSION_GRANTED) {\n mLocationPermissionGranted = true;\n } else {\n ActivityCompat.requestPermissions(this,\n new String[]{android.Manifest.permission.ACCESS_FINE_LOCATION},\n PERMISSIONS_REQUEST_ACCESS_FINE_LOCATION);\n }\n if (mLocationPermissionGranted) {\n mMap.setMyLocationEnabled(true);\n mMap.getUiSettings().setMyLocationButtonEnabled(true);\n } else {\n mMap.setMyLocationEnabled(false);\n mMap.getUiSettings().setMyLocationButtonEnabled(false);\n mLastKnownLocation = null;\n }\n }", "private void updateLocationUI() {\n if (mMap == null) {\n return;\n }\n\n /*\n * Request location permission, so that we can get the location of the\n * device. The result of the permission request is handled by a callback,\n * onRequestPermissionsResult.\n */\n if (ContextCompat.checkSelfPermission(this.getApplicationContext(),\n android.Manifest.permission.ACCESS_FINE_LOCATION)\n == PackageManager.PERMISSION_GRANTED) {\n mLocationPermissionGranted = true;\n } else {\n ActivityCompat.requestPermissions(this,\n new String[]{android.Manifest.permission.ACCESS_FINE_LOCATION},\n PERMISSIONS_REQUEST_ACCESS_FINE_LOCATION);\n }\n\n if (mLocationPermissionGranted) {\n mMap.setMyLocationEnabled(true);\n mMap.getUiSettings().setMyLocationButtonEnabled(true);\n } else {\n mMap.setMyLocationEnabled(false);\n mMap.getUiSettings().setMyLocationButtonEnabled(false);\n mLastKnownLocation = null;\n }\n }", "public void setLocation(Location loc) {\n this.location = loc;\n }", "private void updateLocationUI() {\n if (mMap == null) {\n return;\n }\n try {\n if (mLocationPermissionGranted) {\n mMap.setMyLocationEnabled(true);\n\n // Display the user selected map type\n mMap.setMapType(GoogleMap.MAP_TYPE_NORMAL);\n\n MapStyleOptions style = MapStyleOptions.loadRawResourceStyle(mContext, R.raw.map_style_night);\n mMap.setMapStyle(style);\n\n // Don't want to display the default location button because\n // we are already displaying using a FAB\n mMap.getUiSettings().setMyLocationButtonEnabled(false);\n\n mMap.setOnMyLocationClickListener(this);\n } else {\n mMap.setMyLocationEnabled(false);\n mMap.getUiSettings().setMyLocationButtonEnabled(false);\n mLastKnownLocation = null;\n getLocationPermission();\n }\n } catch (SecurityException e) {\n Log.e(\"Exception: %s\", e.getMessage());\n }\n }", "@Override\n public boolean onMyLocationButtonClick() {\n LocationManager manager = (LocationManager) getContext().getSystemService(Context.LOCATION_SERVICE);\n if (!manager.isProviderEnabled(LocationManager.GPS_PROVIDER)) {\n // If Location disable create a alert dialog\n AlertDialog.Builder alertDialogBuilder = new AlertDialog.Builder(getContext());\n alertDialogBuilder.setMessage(\"Location is disabled in your device. Would you like to enable it?\")\n // Have to respond to this message not cancelable\n .setCancelable(false)\n // If yes open setting page to enable location\n .setPositiveButton(\"Yes\",\n new DialogInterface.OnClickListener() {\n public void onClick(DialogInterface dialog, int id) {\n // intent calls the android activity of location settings\n Intent callGPSSettingIntent = new Intent(\n android.provider.Settings.ACTION_LOCATION_SOURCE_SETTINGS);\n startActivity(callGPSSettingIntent);\n }\n });\n //if no close the dialog\n alertDialogBuilder.setNegativeButton(\"Maybe Later\",\n new DialogInterface.OnClickListener() {\n public void onClick(DialogInterface dialog, int id) {\n dialog.cancel();\n }\n });\n AlertDialog alert = alertDialogBuilder.create();\n alert.show();\n }\n\n return false;\n }", "void changeLocation(@NonNull String location);", "public void onClick(DialogInterface arg0, int which) {\n\t\tif(which == DialogInterface.BUTTON_NEUTRAL){\n\t\t\t//editTextShowLocation.setText(\"Sorry, location is not determined. To fix this please enable location providers\");\n\t\t}else if \n\t\t(which == DialogInterface.BUTTON_POSITIVE) {\n\t\t\tstartActivity(new Intent(android.provider.Settings.ACTION_LOCATION_SOURCE_SETTINGS));\n\t\t}\n\t}", "public void chooseLocation(View v) {\n InternetConnectionChecker checker = new InternetConnectionChecker();\n Context context = getApplicationContext();\n final boolean isOnline = checker.isOnline(context);\n\n if (isOnline) {\n if (currentLocationCheckbox.isChecked()) {\n Toast.makeText(getApplicationContext(), \"Sorry, You have already chosen CURRENT LOCATION.\", Toast.LENGTH_LONG).show();\n } else {\n Intent child = new Intent(getApplicationContext(), ChooseLocationOnMapActivity.class);\n startActivityForResult(child, REQ_CODE_CHILD);\n }\n } else {\n Toast.makeText(getApplicationContext(), \"Map is not available when this device is offline.\", Toast.LENGTH_LONG).show();\n }\n }", "protected void setLocation(String location){\r\n this.location = location;\r\n }", "public void setLocation(String location){\n this.location = location;\n }", "public void setLocation(String location){\n this.location = location;\n }", "@Override\r\n public void onClick(DialogInterface paramDialogInterface, int paramInt) {\n Intent myIntent = new Intent(Settings.ACTION_LOCATION_SOURCE_SETTINGS);\r\n context.startActivity(myIntent);\r\n }", "@Override\r\n\t\t\t\t\t\tpublic void onClick(DialogInterface dialog, int which) {\n\t\t\t\t\t\t\tIntent intent = new Intent(\r\n\t\t\t\t\t\t\t\t\tSettings.ACTION_LOCATION_SOURCE_SETTINGS);\r\n\t\t\t\t\t\t\tstartActivity(intent);\r\n\r\n\t\t\t\t\t\t}", "@Override\n public void onClick(DialogInterface paramDialogInterface, int paramInt) {\n Intent myIntent = new Intent( Settings.ACTION_LOCATION_SOURCE_SETTINGS);\n context.startActivity(myIntent);\n //get gps\n }", "public void setLocation(String location) {\n this.location.setText(location);\n }", "@Override\r\n public void getLocation(Location location) {\r\n if (REQUEST != PLACE_AUTOCOMPLETE_REQUEST_CODE || REQUEST != OPEN_SETTINGS) {\r\n mCurrentLocation = location;\r\n moveToCurrentLocation();\r\n }\r\n }", "public void setLocation(Location location) {\n this.location = location;\n }", "public void setLocation(Location location) {\n this.location = location;\n }", "public void setLocation(Location location) {\n this.location = location;\n }", "@Override\n\tpublic void setLocation(String l) {\n\t\tlocation = l;\n\t\t\n\t}", "public void setLocationType(String locationType);", "public final void setLocation(String value) {\n location = value;\n }", "private void setCurrentLocation() {\n foundLocation = false;\n //Ignore the red line - we check for permissions before this function is called\n if (ActivityCompat.checkSelfPermission(getContext(), Manifest.permission.ACCESS_FINE_LOCATION) != PackageManager.PERMISSION_GRANTED &&\n ActivityCompat.checkSelfPermission(getContext(), Manifest.permission.ACCESS_COARSE_LOCATION) != PackageManager.PERMISSION_GRANTED) {\n return;\n }\n googleMap.setMyLocationEnabled(true);\n FusedLocationProviderClient mFusedLocationProviderClient = LocationServices\n .getFusedLocationProviderClient(getActivity());\n //Ignore the red line - we check for permissions before this function is called\n Task<Location> lastLocation = mFusedLocationProviderClient.getLastLocation();\n lastLocation.addOnCompleteListener(task -> {\n if (task.isSuccessful()) {\n // Set the map's camera position to the current location of the device.\n Location location = task.getResult();\n if (location == null) {\n locationControlTask = new LocationControl();\n locationControlTask.execute(getActivity());\n } else {\n LatLng currentLatLng = new LatLng(location.getLatitude(),\n location.getLongitude());\n CameraUpdate update = CameraUpdateFactory.newLatLngZoom(currentLatLng,\n DEFAULT_ZOOM);\n googleMap.moveCamera(update);\n foundLocation = true;\n }\n }\n });\n }", "public void setLocationType(LocationType value) { _locationType = value; }", "@Override\n \tpublic void onLocationChanged(Location location) {\n \t\tthis.location = location;\n \t}", "@Override\n public void onClick(DialogInterface dialog, int which) {\n Intent intent = new Intent(Settings.ACTION_LOCATION_SOURCE_SETTINGS);\n startActivity(intent);\n dialog.cancel();\n }", "private void locationActionPerformed(\n\t\t\t\tfinal java.awt.event.ActionEvent evt) {\n\t\t}", "@Override\n public void onClick(DialogInterface paramDialogInterface, int paramInt) {\n Intent myIntent = new Intent(android.provider.Settings.ACTION_LOCATION_SOURCE_SETTINGS);\n myIntent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK | Intent.FLAG_ACTIVITY_CLEAR_TOP);\n getApplicationContext().startActivity(myIntent);\n\n }", "public void setLocation(Location location) \n\t{\n\t\tthis.location = location;\n\t}", "@Override\n public void onClick(DialogInterface paramDialogInterface, int paramInt) {\n paramDialogInterface.dismiss();\n\n Intent myIntent = new Intent( Settings.ACTION_LOCATION_SOURCE_SETTINGS);\n startActivity(myIntent);\n //get gps\n }", "private void getLocation() {\n\n }", "public void setLocation(Location location) {\r\n\t\tthis.location = location;\r\n\t}", "public void setLocation(String location) {\r\n this.location = location;\r\n }", "@Override\n public void onClick(DialogInterface paramDialogInterface, int paramInt) {\n Intent myIntent = new Intent( Settings.ACTION_LOCATION_SOURCE_SETTINGS);\n myIntent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK);\n getApplicationContext().startActivity(myIntent);\n //get gps\n }", "@Override\n public void onClick(DialogInterface dialog, int id) {\n Intent gpsOptionsIntent = new Intent(\n android.provider.Settings.ACTION_SETTINGS);\n startActivityForResult(gpsOptionsIntent, 0);\n }", "private void setTypeCurrentLocation() {\n type = WeatherConsts.TYPE_CURRENT_LOCATION;\n param1 = \"\";\n param2 = \"\";\n }", "@Override\n public void setLocation(String location) {\n this.location = location;\n }", "public void startLocationButtonClick() {\n Dexter.withActivity(this)\r\n .withPermission(Manifest.permission.ACCESS_FINE_LOCATION)\r\n .withListener(new PermissionListener() {\r\n @Override\r\n public void onPermissionGranted(PermissionGrantedResponse response) {\r\n mRequestingLocationUpdates = true;\r\n startLocationUpdates();\r\n }\r\n\r\n @Override\r\n public void onPermissionDenied(PermissionDeniedResponse response) {\r\n if (response.isPermanentlyDenied()) {\r\n // open device settings when the permission is\r\n // denied permanently\r\n openSettings();\r\n }\r\n }\r\n\r\n @Override\r\n public void onPermissionRationaleShouldBeShown(PermissionRequest permission, PermissionToken token) {\r\n token.continuePermissionRequest();\r\n }\r\n }).check();\r\n }", "public void setLocation(String location)\n {\n this.location = location;\n }", "private void turnOnGPS(){\r\n\r\n final AlertDialog.Builder builder = new AlertDialog.Builder(this);\r\n\r\n builder.setMessage(\"Enable GPS\").setCancelable(false).setPositiveButton(\"Yes\", new DialogInterface.OnClickListener() {\r\n @Override\r\n public void onClick(DialogInterface dialogInterface, int i) {\r\n startActivity(new Intent(Settings.ACTION_LOCATION_SOURCE_SETTINGS));\r\n }\r\n }).setNegativeButton(\"No\", new DialogInterface.OnClickListener() {\r\n @Override\r\n public void onClick(DialogInterface dialogInterface, int i) {\r\n dialogInterface.cancel();\r\n }\r\n });\r\n\r\n // create the dialog to show to the user\r\n final AlertDialog alertDialog = builder.create();\r\n\r\n alertDialog.show();\r\n }", "public void setLocation(String location){\n mLocation = location;\n loadData();\n }", "public void setLocation(String location) {\r\n this.location = location;\r\n }", "public void setLocation(String location) {\n this.location = location;\n }", "private void pickCurrentPlace() {\n if (mMap == null) {\n return;\n }\n\n if (mLocationPermissionGranted) {\n getDeviceLocation();\n } else {\n getLocationPermission();\n }\n }", "public void setLocation(String location) {\n this.location = location;\n }", "@SuppressLint(\"MissingPermission\")\n @AfterPermissionGranted(PERMISSION_LOCATION_ID)\n private void setMapUISettings() {\n map.getUiSettings().setZoomControlsEnabled(true);\n map.getUiSettings().setCompassEnabled(true);\n map.getUiSettings().setAllGesturesEnabled(true);\n\n map.setOnMyLocationClickListener(new GoogleMap.OnMyLocationClickListener() {\n @Override\n public void onMyLocationClick(@NonNull Location location) {\n\n }\n });\n\n map.setOnMyLocationButtonClickListener(new GoogleMap.OnMyLocationButtonClickListener() {\n @Override\n public boolean onMyLocationButtonClick() {\n return false;\n }\n });\n\n if (EasyPermissions.hasPermissions(requireContext(), Manifest.permission.ACCESS_FINE_LOCATION))\n map.setMyLocationEnabled(true);\n else\n EasyPermissions.requestPermissions(this, \"Access fine location needed to get my location\", PERMISSION_LOCATION_ID, Manifest.permission.ACCESS_FINE_LOCATION);\n }", "public void settingRequest() {\n mLocationRequest = new LocationRequest();\n mLocationRequest.setInterval(10000); // 10 seconds, in milliseconds\n mLocationRequest.setFastestInterval(1000); // 1 second, in milliseconds\n mLocationRequest.setPriority(LocationRequest.PRIORITY_HIGH_ACCURACY);\n\n LocationSettingsRequest.Builder builder = new LocationSettingsRequest.Builder()\n .addLocationRequest(mLocationRequest);\n\n PendingResult<LocationSettingsResult> result =\n LocationServices.SettingsApi.checkLocationSettings(mGoogleApiClient,\n builder.build());\n\n result.setResultCallback(new ResultCallback<LocationSettingsResult>() {\n\n @Override\n public void onResult(@NonNull LocationSettingsResult result) {\n status = result.getStatus();\n final LocationSettingsStates state = result.getLocationSettingsStates();\n switch (status.getStatusCode()) {\n case LocationSettingsStatusCodes.SUCCESS:\n // All location settings are satisfied. The client can\n // initialize location requests here.\n getLocation();\n break;\n case LocationSettingsStatusCodes.RESOLUTION_REQUIRED:\n // Location settings are not satisfied, but this can be fixed\n // by showing the user a dialog.\n try {\n // Show the dialog by calling startResolutionForResult(),\n // and check the result in onActivityResult().\n status.startResolutionForResult(UserCurrentLocation.this, 1000);\n } catch (IntentSender.SendIntentException e) {\n // Ignore the error.\n }\n break;\n case LocationSettingsStatusCodes.SETTINGS_CHANGE_UNAVAILABLE:\n // Location settings are not satisfied. However, we have no way\n // to fix the settings so we won't show the dialog.\n break;\n }\n }\n\n });\n }", "Label setLocation();", "public void setLocation(String location) {\n inputParameters.Location = location;\n\n }", "public void setLocation(Point p) {\n // Not supported for MenuComponents\n }", "public void locate()\n\t{\n\t\tlocationClient = new LocationClient(Main.activity.getApplicationContext()); // 实例化LocationClient类\n\t\t\t\t\n\t\tlocationClient.registerLocationListener(myListener); // 注册监听函数\n\t\tthis.setLocationOption();\t//设置定位参数\n\t\tlocationClient.start(); // 开始定位\n\t\tlocationClient.requestLocation();\n\t}", "@Override\n public void updateUserLocation(Location location) {\n locationSelectorPresenter.setUserLocationGoogleMarker(location);\n }", "public void setLocation(){\n //Check if user come from notification\n if (getIntent().hasExtra(EXTRA_PARAM_LAT) && getIntent().hasExtra(EXTRA_PARAM_LON)){\n Log.d(TAG, \"Proviene del servicio, lat: \" + getIntent().getExtras().getDouble(EXTRA_PARAM_LAT) + \" - lon: \" + getIntent().getExtras().getDouble(EXTRA_PARAM_LON));\n mMap.moveCamera(CameraUpdateFactory.newLatLngZoom(new LatLng(getIntent().getExtras().getDouble(EXTRA_PARAM_LAT), getIntent().getExtras().getDouble(EXTRA_PARAM_LON)), 18));\n NotificationManager mNM = (NotificationManager) getSystemService(NOTIFICATION_SERVICE);\n mNM.cancel(1);\n } else{\n if (bestLocation!=null){\n Log.d(TAG, \"Posicion actual -> LAT: \"+ bestLocation.getLatitude() + \" LON: \" + bestLocation.getLongitude());\n mMap.moveCamera(CameraUpdateFactory.newLatLngZoom(new LatLng(bestLocation.getLatitude(), bestLocation.getLongitude()), 16));\n } else{\n mMap.moveCamera(CameraUpdateFactory.newLatLngZoom(new LatLng(41.651981, -4.728561), 16));\n }\n }\n }", "private void setMyLatLong() {\n }", "private void requestLocationSettingGoogleApi() {\n if (mGoogleApiClient == null || !mGoogleApiClient.isConnected()) {\n finishForResult(Locset.ResultCode.GOOGLE_API_FAILURE);\n return;\n }\n\n final LocationSettingsRequest request = new LocationSettingsRequest.Builder()\n .setAlwaysShow(true)\n .addLocationRequest(LocationRequest.create().setPriority(mPriority))\n .build();\n\n final PendingResult<LocationSettingsResult> result = LocationServices.SettingsApi.checkLocationSettings(\n mGoogleApiClient,\n request);\n\n result.setResultCallback(new ResultCallback<LocationSettingsResult>() {\n @Override\n public void onResult(@NonNull LocationSettingsResult locationSettingsResult) {\n final Status status = locationSettingsResult.getStatus();\n switch (status.getStatusCode()) {\n case LocationSettingsStatusCodes.SUCCESS:\n // All location settings are satisfied. The client can initialize location\n // requests here.\n finishForResult(Locset.ResultCode.SUCCESS);\n return;\n case LocationSettingsStatusCodes.RESOLUTION_REQUIRED:\n // Location settings are not satisfied. But could be fixed by showing the user\n // a dialog.\n try {\n // Show the dialog by calling startResolutionForResult(),\n // and check the result in onActivityResult().\n status.startResolutionForResult(\n LocsetActivity.this,\n // An arbitrary constant to disambiguate activity results.\n REQUEST_CODE_LOCATION_SETTING);\n return;\n } catch (IntentSender.SendIntentException e) {\n // failure\n }\n break;\n case LocationSettingsStatusCodes.SETTINGS_CHANGE_UNAVAILABLE:\n // Location settings are not satisfied. However, we have no way to fix the\n // settings so we won't show the dialog.\n break;\n }\n finishForResult(Locset.ResultCode.LOCATION_SETTING_FAILURE);\n }\n });\n }", "@Override\r\n\tpublic void onLocationChanged(Location location) {\n\t if(location!=null){\r\n\t //Toast.makeText(mContext,\"Location provider = \"+location.getProvider(), Toast.LENGTH_SHORT).show();\r\n if (LocationManager.GPS_PROVIDER.equals(location.getProvider())) {\r\n double [] latlng =Common.adjustLatLng(location.getLatitude(), location.getLongitude());\r\n location.setLatitude(latlng[0]);\r\n location.setLongitude(latlng[1]);\r\n Common.saveLocation(location);\r\n super.onLocationChanged(location);\r\n }else if(\"lbs\".equals(location.getProvider())){\r\n Common.saveLocation(location);\r\n super.onLocationChanged(location);\r\n }\r\n\t }\r\n\t}", "static public void set_location_data(){\n\n\t\tEdit_row_window.attrs = new String[]{\"location name:\", \"rating:\", \"population:\"};\n\t\tEdit_row_window.attr_vals = new String[]\n\t\t\t\t{Edit_row_window.selected[0].getText(1), Edit_row_window.selected[0].getText(2), \n\t\t\t\tEdit_row_window.selected[0].getText(3)};\n\t\t\n\t\tEdit_row_window.linked_query =\t\n\t\t\t\t\" select distinct c.`id`, c.`name`, c.`area (1000 km^2)`, c.`GDP per capita (1000 $)`, \" +\n\t\t\t\t\t\t\t\t\"c.`population (million)`, c.`capital`, c.`GDP (billion $)` \" +\n\t\t\t\t\t\t\t\t\t\t\t\" from curr_places_countries c, \" +\n\t\t\t\t\t\t\t\t\t\t\t\" curr_places_location_country lc \" +\n\t\t\t\t\t\t\t\t\t\t\t\" where lc.country_id=c.id and lc.location_id=\"+Edit_row_window.id+\n\t\t\t\t\t\t\t\t\t\t\t\" order by c.`GDP (billion $)` desc \";\n\t\t\t\t\n\t\tEdit_row_window.not_linked_query = \" select distinct c.`id`, c.`name`, c.`area (1000 km^2)`, c.`GDP per capita (1000 $)`, \" +\n\t\t\t\t\" c.`population (million)`, c.`capital`, c.`GDP (billion $)` \" +\n\t\t\t\t\" from curr_places_countries c \";\n\t\t\n\t\tEdit_row_window.linked_attrs = new String[]{\"id:\", \"country name:\", \"area (1000 km^2):\", \"GDP per capita (1000 $):\",\n\t\t\t\t\"population (million):\", \"capital:\", \"GDP (billion $):\"};\n\t\tEdit_row_window.label_min_parameter=\"min. population:\";\n\t\tEdit_row_window.linked_category_name = \"COUNTRIES\";\n\t}", "void setOrigination(Locations origination);", "public void setLocation(String location) {\n this.location = location;\n }", "public void setLocation(String location) {\n this.location = location;\n }", "public void setLocation(String location) {\n this.location = location;\n }", "public void setLocation(String location) {\n this.location = location;\n }", "private void displayLocation() {\n\n if(customProgressDialog.isShowing())\n customProgressDialog.cancel();\n\n boolean hasPermissionFine = (ContextCompat.checkSelfPermission(LocationChooser.this,\n android.Manifest.permission.ACCESS_FINE_LOCATION) == PackageManager.PERMISSION_GRANTED);\n boolean hasPermissionCoarse = (ContextCompat.checkSelfPermission(LocationChooser.this,\n android.Manifest.permission.ACCESS_COARSE_LOCATION) == PackageManager.PERMISSION_GRANTED);\n if (!hasPermissionFine || !hasPermissionCoarse) {\n ActivityCompat.requestPermissions(LocationChooser.this,\n new String[]{android.Manifest.permission.ACCESS_FINE_LOCATION, android.Manifest.permission.ACCESS_COARSE_LOCATION}, REQUEST_LOCATION);\n } else {\n mLocation = LocationServices.FusedLocationApi.getLastLocation(mGoogleApiClient);\n }\n mLocation = LocationServices.FusedLocationApi.getLastLocation(mGoogleApiClient);\n if (mLocation != null) {\n sLat = mLocation.getLatitude();\n sLang = mLocation.getLongitude();\n Log.d(\"curren location:\", String.valueOf(sLat) + \"::\" + String.valueOf(sLang));\n source.setText(\"Your location\");\n //locationText.setText(String.valueOf(sLat)+\"::\"+String.valueOf(sLang));\n } else {\n Toast.makeText(this, \"Location not Detected.\", Toast.LENGTH_SHORT).show();\n // showSettingsAlert();\n }\n }", "@Override\n\t\tpublic void onLocationChanged(Location location) {\n\t\t\t\n\t\t}", "@Override\n\t\tpublic void onLocationChanged(Location location) {\n\t\t\t\n\t\t}", "private void pickCurrentPlace() {\n if (mMap == null) {\n return;\n }\n\n if (mLocationPermissionGranted) {\n getDeviceLocation();\n } else {\n // The user has not granted permission.\n Log.i(TAG, \"The user did not grant location permission.\");\n\n // Add a default marker, because the user hasn't selected a place.\n mMap.addMarker(new MarkerOptions()\n .title(getString(R.string.default_info_title))\n .position(mDefaultLocation)\n .snippet(getString(R.string.default_info_snippet)));\n\n // Prompt the user for permission.\n getLocationPermission();\n }\n }", "@Override\n public void onClick(DialogInterface paramDialogInterface, int paramInt) {\n Intent myIntent = new Intent( Settings.ACTION_LOCATION_SOURCE_SETTINGS);\n HomeActivity.this.startActivity(myIntent);\n //get gps\n }", "private void displayLocationSettingsRequest(Context context) {\r\n GoogleApiClient googleApiClient = new GoogleApiClient.Builder(context)\r\n .addApi(LocationServices.API).build();\r\n googleApiClient.connect();\r\n final int REQUEST_CHECK_SETTINGS = 0x1;\r\n\r\n LocationRequest locationRequest = LocationRequest.create();\r\n locationRequest.setPriority(LocationRequest.PRIORITY_HIGH_ACCURACY);\r\n locationRequest.setInterval(10000);\r\n locationRequest.setFastestInterval(10000 / 2);\r\n\r\n LocationSettingsRequest.Builder builder = new LocationSettingsRequest.Builder().addLocationRequest(locationRequest);\r\n builder.setAlwaysShow(true);\r\n\r\n PendingResult<LocationSettingsResult> result = LocationServices.SettingsApi.checkLocationSettings(googleApiClient, builder.build());\r\n result.setResultCallback(new ResultCallback<LocationSettingsResult>() {\r\n @Override\r\n public void onResult(LocationSettingsResult result) {\r\n final Status status = result.getStatus();\r\n switch (status.getStatusCode()) {\r\n case LocationSettingsStatusCodes.SUCCESS:\r\n //Log.i(\"view\", \"All location settings are satisfied.\");\r\n break;\r\n case LocationSettingsStatusCodes.RESOLUTION_REQUIRED:\r\n //Log.i(\"view\", \"Location settings are not satisfied. Show the user a dialog to upgrade location settings \");\r\n\r\n try {\r\n // Show the dialog by calling startResolutionForResult(), and check the result\r\n // in onActivityResult().\r\n status.startResolutionForResult(LocationActivity.this, REQUEST_CHECK_SETTINGS);\r\n } catch (IntentSender.SendIntentException e) {\r\n //Log.i(\"view\", \"PendingIntent unable to execute request.\");\r\n }\r\n break;\r\n case LocationSettingsStatusCodes.SETTINGS_CHANGE_UNAVAILABLE:\r\n //Log.i(\"view\", \"Location settings are inadequate, and cannot be fixed here. Dialog not created.\");\r\n break;\r\n }\r\n }\r\n });\r\n }", "private void startLocationUpdates() {\n mSettingsClient.checkLocationSettings(mLocationSettingsRequest)\n .addOnSuccessListener(getActivity(), locationSettingsResponse -> {\n mFusedLocationClient.requestLocationUpdates(mLocationRequest,\n mLocationCallback, Looper.myLooper());\n\n updateUI();\n })\n .addOnFailureListener(getActivity(), e -> {\n int statusCode = ((ApiException) e).getStatusCode();\n switch (statusCode) {\n case LocationSettingsStatusCodes.RESOLUTION_REQUIRED:\n try {\n // Show the dialog and check the result in onActivityResult().\n ResolvableApiException resolvable = (ResolvableApiException) e;\n MapFragment.this.startIntentSenderForResult(resolvable.getResolution().getIntentSender(),\n REQUEST_CHECK_SETTINGS, null, 0,\n 0, 0, null);\n } catch (IntentSender.SendIntentException sie) {\n //...\n }\n break;\n case LocationSettingsStatusCodes.SETTINGS_CHANGE_UNAVAILABLE:\n String errorMessage = \"Location settings are inadequate, and cannot be \" +\n \"fixed here. Fix in Settings.\";\n Toast.makeText(MapFragment.this.getActivity(), errorMessage, Toast.LENGTH_LONG).show();\n mRequestingLocationUpdates = false;\n }\n\n MapFragment.this.updateUI();\n });\n }", "public void setPreferredlocation(java.lang.String preferredlocation) {\n this.preferredlocation = preferredlocation;\n }", "@Override\n \t\t\tpublic void onCheckedChanged(CompoundButton arg0, boolean arg1) {\n \t\t\t\tif(arg1==true)\n \t\t\t\t\tmMap.setMyLocationEnabled(true);\n \t\t\t\telse\n \t\t\t\t\tmMap.setMyLocationEnabled(false);\n \t\t\t}", "@Override\n \t\t\tpublic void onCheckedChanged(CompoundButton arg0, boolean arg1) {\n \t\t\t\tif(arg1==true)\n \t\t\t\t\tmMap.setMyLocationEnabled(true);\n \t\t\t\telse\n \t\t\t\t\tmMap.setMyLocationEnabled(false);\n \t\t\t}", "private void enableLocation(){\n if(PermissionsManager.areLocationPermissionsGranted(this))\n {\n initializeLocationEngine();\n initializeLocationLayer();\n\n\n }else{\n permissionsManager = new PermissionsManager(this);\n permissionsManager.requestLocationPermissions(this);\n }\n }", "public void setLocation(Point loc){\n\t\tthis.location = loc;\n\t}", "public void setLocation(String location) {\r\n\t\tthis.location = location;\r\n\t}", "public void updateLocation();", "private void configMap() {\n\n googleMap.getUiSettings().setMapToolbarEnabled(false);//an buton dieu huong bat snag map\n\n googleMap.getUiSettings().setMyLocationButtonEnabled(true);//nut vi tri cua minh tru se hien thi\n googleMap.getUiSettings().setZoomControlsEnabled(true);//co the zoom\n\n// b2\n googleMap.setInfoWindowAdapter(new MyInfoWindown());//cutom titlemap\n\n try {//them lenh nay de no cap location thì cai nut tren moi hoat dong\n\n googleMap.setMyLocationEnabled(true);//cung cap vi tri cua minh,can try cacth xin quyen\n } catch (SecurityException e) {\n\n }\n googleMap.setOnMyLocationButtonClickListener(this);//dNG KY\n\n\n }", "@Override\n public void onClick(View v) {\n buttonSetLocation();\n }", "private void configMyLocation() {\n try {\n if (ActivityCompat.checkSelfPermission(this, Manifest.permission.ACCESS_FINE_LOCATION) != PackageManager.PERMISSION_GRANTED && ActivityCompat.checkSelfPermission(this, Manifest.permission.ACCESS_COARSE_LOCATION) != PackageManager.PERMISSION_GRANTED) {\n // TODO: Consider calling\n // ActivityCompat#requestPermissions\n // here to request the missing permissions, and then overriding\n // public void onRequestPermissionsResult(int requestCode, String[] permissions,\n // int[] grantResults)\n // to handle the case where the user grants the permission. See the documentation\n // for ActivityCompat#requestPermissions for more details.\n return;\n }\n\n FusedLocationProviderClient locationProviderClient = LocationServices.getFusedLocationProviderClient(this);\n\n locationProviderClient.getLastLocation().addOnCompleteListener(new OnCompleteListener<Location>() {\n @Override\n public void onComplete(@NonNull Task<Location> task) {\n Location location = task.getResult();\n LatLng sd = new LatLng(location.getLatitude(), location.getLongitude());\n\n mMap.addMarker(new MarkerOptions().position(sd).title(\"you are here\").icon(BitmapDescriptorFactory.defaultMarker()));\n mMap.moveCamera(CameraUpdateFactory.newLatLng(sd));\n mMap.moveCamera(CameraUpdateFactory.newLatLngZoom(sd, MAP_ZOOM));\n\n model.setLongitude(location.getLatitude());\n model.setLatitude(location.getLongitude());\n }\n });\n }catch (Exception ex){\n Constant.showMessage(\"Exception\", ex.getMessage(), this);\n }\n }", "private void inputLocation() {\n// boolean googleMapExist= (ConnectionResult.SUCCESS==GooglePlayServicesUtil.isGooglePlayServicesAvailable(mContext));\n//\n// if(googleMapExist) {\n// org.wowtalk.Log.w(\"google map exist\");\n// Intent mapIntent = new Intent(mContext, PickLocActivity.class);\n// mapIntent.putExtra(\"auto_loc\", true);\n// mContext.startActivityForResult(mapIntent, REQ_INPUT_LOC);\n// } else {\n //org.wowtalk.Log.w(\"google map not exist\");\n Intent mapIntent = new Intent(mContext, PickLocActivityWithAMap.class);\n mapIntent.putExtra(\"auto_loc\", true);\n mContext.startActivityForResult(mapIntent, REQ_INPUT_LOC);\n //}\n }", "private void updateLocationUI() {\n mCurrentLocationStr = mCurrentPlace.getAddress().toString();\n mCurrentLatLng = mCurrentPlace.getLatLng();\n if(mCurrentLocationStr.isEmpty())\n mCurrentLocationStr = String.format(\"(%.2f, %.2f)\",mCurrentLatLng.latitude, mCurrentLatLng.longitude);\n\n mAddLocation.setText(mCurrentLocationStr);\n mAddLocation.setTextColor(mSecondaryTextColor);\n mClearLocation.setVisibility(View.VISIBLE);\n }", "private void initLocation() {\n BaiduLocationHolder.OPTION.setLocationMode(LocationClientOption.LocationMode.Hight_Accuracy);\n //可选,默认高精度,设置定位模式,高精度,低功耗,仅设备\n\n BaiduLocationHolder.OPTION.setCoorType(\"bd09ll\");\n //可选,默认gcj02,设置返回的定位结果坐标系\n\n int span = 1000;\n BaiduLocationHolder.OPTION.setScanSpan(span);\n //可选,默认0,即仅定位一次,设置发起定位请求的间隔需要大于等于1000ms才是有效的\n\n BaiduLocationHolder.OPTION.setIsNeedAddress(true);\n //可选,设置是否需要地址信息,默认不需要\n\n BaiduLocationHolder.OPTION.setOpenGps(true);\n //可选,默认false,设置是否使用gps\n\n BaiduLocationHolder.OPTION.setLocationNotify(true);\n //可选,默认false,设置是否当GPS有效时按照1S/1次频率输出GPS结果\n\n BaiduLocationHolder.OPTION.setIsNeedLocationDescribe(true);\n //可选,默认false,设置是否需要位置语义化结果,可以在BDLocation.getLocationDescribe里得到,结果类似于“在北京天安门附近”\n\n BaiduLocationHolder.OPTION.setIsNeedLocationPoiList(true);\n //可选,默认false,设置是否需要POI结果,可以在BDLocation.getPoiList里得到\n\n BaiduLocationHolder.OPTION.setIgnoreKillProcess(false);\n //可选,默认true,定位SDK内部是一个SERVICE,并放到了独立进程,设置是否在stop的时候杀死这个进程,默认不杀死\n\n BaiduLocationHolder.OPTION.SetIgnoreCacheException(false);\n //可选,默认false,设置是否收集CRASH信息,默认收集\n\n BaiduLocationHolder.OPTION.setEnableSimulateGps(false);\n //可选,默认false,设置是否需要过滤GPS仿真结果,默认需要\n\n// BaiduLocationHolder.OPTION.setWifiValidTime(5*60*1000);\n //可选,7.2版本新增能力,如果您设置了这个接口,首次启动定位时,会先判断当前WiFi是否超出有效期,超出有效期的话,会先重新扫描WiFi,然后再定位\n\n BaiduLocationHolder.CLIENT.setLocOption(BaiduLocationHolder.OPTION);\n }", "public static void setCurrentLocation(Double lat, Double lng ){\n //SharedPreferences sharedPreferences1=appCompatActivity. getSharedPreferences(\"longitude\", MODE_PRIVATE) ;\n SharedPreferences.Editor editor=sharedPreferences.edit();\n editor.putString(USER_LTD, String.valueOf(lat));\n editor.putString(USER_LNG, String.valueOf(lng));\n editor.apply();\n }", "private void requestLocationPermission() {\n if (ActivityCompat.shouldShowRequestPermissionRationale(this,\n Manifest.permission.ACCESS_FINE_LOCATION)) {\n\n new AlertDialog.Builder(this)\n .setTitle(\"Permission needed\")\n .setMessage(\"Location Permission is needed to show your current location on the map\")\n .setPositiveButton(\"OK\", new DialogInterface.OnClickListener() {\n @Override\n public void onClick(DialogInterface dialog, int which) {\n ActivityCompat.requestPermissions(ScavengerHunt.this,\n new String[]{Manifest.permission.ACCESS_FINE_LOCATION}, 2);\n }\n })\n .setNegativeButton(\"Cancel\", new DialogInterface.OnClickListener() {\n @Override\n public void onClick(DialogInterface dialog, int which) {\n dialog.dismiss();\n Toast.makeText(ScavengerHunt.this, \"Location Permission is needed to update the map\", Toast.LENGTH_SHORT).show();\n }\n })\n .create()\n .show();\n\n } else {\n ActivityCompat.requestPermissions(this,\n new String[]{Manifest.permission.ACCESS_FINE_LOCATION}, 2);\n }\n }", "private void setLocation(){\r\n\t\t//make the sql command\r\n\t\tString sqlCmd = \"INSERT INTO location VALUES ('\" + commandList.get(1) + \"', '\"\r\n\t\t\t\t+ commandList.get(2) + \"', '\" + commandList.get(3) + \"');\";\r\n\r\n\t\ttry {//start SQL statement\r\n\t\t\tstmt.executeUpdate(sqlCmd);\r\n\t\t} catch (SQLException e) {\r\n\t\t\terror = true;\r\n\t\t\tout.println(e.getMessage());\r\n\t\t\te.printStackTrace();\r\n\t\t}\r\n\t\tif(error == false)\r\n\t\t\tout.println(\"true\");\r\n\t}", "public void setLocation(Location loc) {\n if (loc.getLatitude() != 0.0 && loc.getLongitude() != 0.0) {\n try {\n Geocoder geocoder = new Geocoder(this, Locale.getDefault());\n List<Address> list = geocoder.getFromLocation(\n loc.getLatitude(), loc.getLongitude(), 1);\n if (!list.isEmpty()) {\n Address DirCalle = list.get(0);\n mensaje2.setText(\n DirCalle.getAddressLine(0));\n }\n\n } catch (IOException e) {\n e.printStackTrace();\n }\n }\n }" ]
[ "0.71411115", "0.71144885", "0.7087753", "0.7074434", "0.6837234", "0.6775804", "0.6765546", "0.6756111", "0.6756111", "0.6756111", "0.6750957", "0.67253715", "0.6718873", "0.6685165", "0.665394", "0.6649267", "0.66282386", "0.661101", "0.65919524", "0.6587729", "0.65816283", "0.6581381", "0.6578293", "0.655834", "0.6525701", "0.6525701", "0.652224", "0.6515742", "0.65108323", "0.65105397", "0.6509072", "0.6489978", "0.6489978", "0.6489978", "0.6488069", "0.6468595", "0.6465146", "0.64546645", "0.64472383", "0.6437545", "0.6431945", "0.6430345", "0.64236563", "0.6420646", "0.6405764", "0.6377838", "0.6374364", "0.6359754", "0.6359353", "0.63514125", "0.63508683", "0.63475955", "0.6347575", "0.63438165", "0.63225543", "0.63158053", "0.6310209", "0.6307928", "0.63037366", "0.6302784", "0.62917656", "0.6289081", "0.62872094", "0.62740666", "0.6260701", "0.62590873", "0.6254611", "0.62500423", "0.6231911", "0.6218505", "0.621626", "0.61939025", "0.61937004", "0.6192705", "0.6192705", "0.6192705", "0.6192705", "0.6189215", "0.6182932", "0.6182932", "0.6174737", "0.61728895", "0.61709255", "0.61702067", "0.6164901", "0.6159036", "0.6159036", "0.6150234", "0.6150205", "0.6144438", "0.61427027", "0.6139498", "0.6131219", "0.61256725", "0.61236054", "0.61190337", "0.61169475", "0.6116736", "0.6113744", "0.6113297", "0.6111862" ]
0.0
-1
Inflate the menu; this adds items to the action bar if it is present.
@Override public boolean onCreateOptionsMenu(Menu menu) { getMenuInflater().inflate(R.menu.toplevel, menu); return true; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n public boolean onCreateOptionsMenu(Menu menu) {\n \tMenuInflater inflater = getMenuInflater();\n \tinflater.inflate(R.menu.main_activity_actions, menu);\n \treturn super.onCreateOptionsMenu(menu);\n }", "@Override\n public void onCreateOptionsMenu(Menu menu, MenuInflater inflater) {\n super.onCreateOptionsMenu(menu, inflater);\n inflater.inflate(R.menu.actions, menu);\n }", "@Override\n public boolean onCreateOptionsMenu(Menu menu) {\n \tgetMenuInflater().inflate(R.menu.actions, menu);\n \treturn super.onCreateOptionsMenu(menu);\n }", "@Override\n public boolean onCreateOptionsMenu(Menu menu) {\n MenuInflater inflater = getMenuInflater();\n inflater.inflate(R.menu.actions_bar, menu);\n return super.onCreateOptionsMenu(menu);\n }", "@Override\n\tpublic boolean onCreateOptionsMenu(Menu menu) {\n\t\tMenuInflater inflater = getMenuInflater();\n\t\tinflater.inflate(R.menu.main_actions, menu);\n\n\t\treturn super.onCreateOptionsMenu(menu);\n\t}", "@Override\r\n\tpublic boolean onCreateOptionsMenu(Menu menu) {\n\t\tMenuInflater inflater = getMenuInflater();\r\n\t\tinflater.inflate(R.menu.action_bar_menu, menu);\r\n\t\tmMenu = menu;\r\n\t\treturn super.onCreateOptionsMenu(menu);\r\n\t}", "@Override\n public boolean onCreateOptionsMenu(Menu menu) {\n MenuInflater inflater = getMenuInflater();\n inflater.inflate(R.menu.act_bar_menu, menu);\n return super.onCreateOptionsMenu(menu);\n }", "@Override\r\n\tpublic boolean onCreateOptionsMenu(Menu menu) {\n\t\tMenuInflater inflater = getMenuInflater();\r\n inflater.inflate(R.menu.main_actions, menu);\r\n\t\treturn true;\r\n //return super.onCreateOptionsMenu(menu);\r\n\t}", "@Override\r\n\tpublic boolean onCreateOptionsMenu(Menu menu) {\n\t MenuInflater inflater = getMenuInflater();\r\n\t inflater.inflate(R.menu.action_bar_all, menu);\r\n\t return super.onCreateOptionsMenu(menu);\r\n\t}", "@Override\n\tpublic boolean onCreateOptionsMenu(android.view.Menu menu) {\n\t\t super.onCreateOptionsMenu(menu);\n\t\tMenuInflater muu= getMenuInflater();\n\t\tmuu.inflate(R.menu.cool_menu, menu);\n\t\treturn true;\n\t\t\n\t\t\n\t}", "@Override\r\n\tpublic boolean onCreateOptionsMenu(Menu menu) {\n\t\tgetMenuInflater().inflate(R.menu.adventure_archive, menu);\r\n\t\treturn true;\r\n\t}", "@Override\r\n\tpublic boolean onCreateOptionsMenu(Menu menu) {\n\t\tgetMenuInflater().inflate(R.menu.archive_menu, menu);\r\n\t\treturn true;\r\n\t}", "@Override\n public boolean onCreateOptionsMenu(Menu menu) {\n\n MenuInflater inflater = getMenuInflater();\n inflater.inflate(R.menu.main_activity_actions, menu);\n return super.onCreateOptionsMenu(menu);\n }", "@Override\n public boolean onCreateOptionsMenu(Menu menu) {\n MenuInflater inflater = getMenuInflater();\n inflater.inflate(R.menu.main_activity_actions, menu);\n return super.onCreateOptionsMenu(menu);\n }", "@Override\n public boolean onCreateOptionsMenu(Menu menu) {\n MenuInflater inflater = getMenuInflater();\n inflater.inflate(R.menu.main_activity_actions, menu);\n return super.onCreateOptionsMenu(menu);\n }", "@Override\n \tpublic void onCreateOptionsMenu(Menu menu, MenuInflater inflater) {\n \t\tinflater.inflate(R.menu.main, menu);\n \t\tsuper.onCreateOptionsMenu(menu, inflater);\n \t}", "@Override\n\tpublic boolean onCreateOptionsMenu(Menu menu) {\n\t MenuInflater inflater = getMenuInflater();\n\t inflater.inflate(R.menu.action_menu, menu);\n\t return super.onCreateOptionsMenu(menu);\n\t}", "@Override\n public void onCreateOptionsMenu(Menu menu, MenuInflater inflater) {\n inflater.inflate(R.menu.action_menu, menu);\n super.onCreateOptionsMenu(menu, inflater);\n }", "@Override\n\tpublic boolean onCreateOptionsMenu(Menu menu) {\n\t\tsuper.onCreateOptionsMenu(menu);\n\t\tMenuInflater bow=getMenuInflater();\n\t\tbow.inflate(R.menu.menu, menu);\n\t\treturn true;\n\t\t}", "@Override\n\tpublic boolean onCreateOptionsMenu(Menu menu) {\n\t\tMenuInflater inflater = getMenuInflater();\n\t\tinflater.inflate(R.menu.main, menu);\n\t\treturn super.onCreateOptionsMenu(menu);\n\t}", "@Override\n\tpublic boolean onCreateOptionsMenu(Menu menu) {\n\t\tMenuInflater inflater = getMenuInflater();\n\t\tinflater.inflate(R.menu.main, menu);\n\t\treturn super.onCreateOptionsMenu(menu);\n\t}", "@Override\n\tpublic boolean onCreateOptionsMenu(Menu menu) {\n\t\tMenuInflater inflater = getMenuInflater();\n\t\tinflater.inflate(R.menu.main, menu);\n\t\treturn super.onCreateOptionsMenu(menu);\n\t}", "@Override\n\tpublic boolean onCreateOptionsMenu(Menu menu) {\n\t\tMenuInflater inflater = getMenuInflater();\n\t\tinflater.inflate(R.menu.main, menu);\n\t\treturn super.onCreateOptionsMenu(menu);\n\t}", "@Override\t\n\tpublic boolean onCreateOptionsMenu(Menu menu) {\t\t\n\t\t/* Inflate the menu; this adds items to the action bar if it is present */\n\t\tgetMenuInflater().inflate(R.menu.act_main, menu);\t\t\n\t\treturn true;\n\t}", "@Override\n public boolean onCreateOptionsMenu(Menu menu) {\n MenuInflater inflate = getMenuInflater();\n inflate.inflate(R.menu.menu, ApplicationData.amvMenu.getMenu());\n return true;\n }", "@Override\n\t\tpublic boolean onCreateOptionsMenu(Menu menu) {\n\t\t\tgetMenuInflater().inflate(R.menu.menu, menu);\n\t\t\treturn true; \n\t\t\t\t\t\n\t\t}", "@Override\n\tpublic void onCreateOptionsMenu(Menu menu, MenuInflater inflater) {\n\t\tinflater.inflate(R.menu.main, menu);\n\t}", "@Override\n public boolean onCreateOptionsMenu(Menu menu) \n {\n MenuInflater inflater = getMenuInflater();\n inflater.inflate(R.menu.menu_bar, menu);\n return true;\n }", "@Override\n public boolean onCreateOptionsMenu(Menu menu) {\n getMenuInflater().inflate(R.menu.menu, menu);//Menu Resource, Menu\n return true;\n }", "@Override\n public boolean onCreateOptionsMenu(Menu menu) {\n getMenuInflater().inflate(R.menu.menu, menu);//Menu Resource, Menu\n return true;\n }", "@Override\n public boolean onCreateOptionsMenu(Menu menu) {\n MenuInflater inflater = getMenuInflater();\n inflater.inflate(R.menu.menu_item, menu);\n return super.onCreateOptionsMenu(menu);\n }", "@Override\n\tpublic void onCreateOptionsMenu(Menu menu, MenuInflater inflater) {\n\t\tinflater.inflate(R.menu.menu, menu);\n\t\tsuper.onCreateOptionsMenu(menu, inflater);\n\t}", "@Override\n\tpublic boolean onCreateOptionsMenu(Menu menu) {\n\t MenuInflater inflater = getMenuInflater();\n\t inflater.inflate(R.menu.menu, menu);\n\t return super.onCreateOptionsMenu(menu);\n\t}", "@Override\n\tpublic boolean onCreateOptionsMenu(Menu menu) {\n\t\tMenuInflater inflater = getMenuInflater();\n\t inflater.inflate(R.menu.menu, menu);\n\t \n\t\treturn super.onCreateOptionsMenu(menu);\n\t}", "@Override\n\tpublic void onCreateOptionsMenu(Menu menu, MenuInflater inflater) {\n\t\tsuper.onCreateOptionsMenu(menu, inflater);\n\t\t//menu.clear();\n\t\tinflater.inflate(R.menu.soon_to_be, menu);\n\t\t//getActivity().getActionBar().show();\n\t\t//getActivity().getActionBar().setBackgroundDrawable(\n\t\t\t\t//new ColorDrawable(Color.rgb(223, 160, 23)));\n\t\t//return true;\n\t}", "@Override\n public boolean onCreateOptionsMenu(Menu menu) {\n this.getMenuInflater().inflate(R.menu.main, menu);\n return super.onCreateOptionsMenu(menu);\n }", "@Override\n public void onCreateOptionsMenu(Menu menu, MenuInflater inflater) {\n super.onCreateOptionsMenu(menu, inflater);\n inflater.inflate(R.menu.main, menu);\n }", "@Override\n\tpublic void onCreateOptionsMenu( Menu menu, MenuInflater inflater )\n\t{\n\t\tsuper.onCreateOptionsMenu( menu, inflater );\n\t}", "@Override\r\n\tpublic boolean onCreateOptionsMenu(Menu menu) {\n\t\tgetMenuInflater().inflate(R.menu.main, menu);\r\n\t\treturn super.onCreateOptionsMenu(menu);\r\n\t}", "@Override\r\n public boolean onCreateOptionsMenu(Menu menu) {\r\n \t// We must call through to the base implementation.\r\n \tsuper.onCreateOptionsMenu(menu);\r\n \t\r\n MenuInflater inflater = getMenuInflater();\r\n inflater.inflate(R.menu.main_menu, menu);\r\n\r\n return true;\r\n }", "@Override\n public boolean onCreateOptionsMenu(Menu menu) {\n getMenuInflater().inflate(R.menu.main, menu);//Menu Resource, Menu\n return true;\n }", "@Override\n public boolean onCreateOptionsMenu(Menu menu) {\n getMenuInflater().inflate(R.menu.main, menu);//Menu Resource, Menu\n return true;\n }", "@Override\n public boolean onCreateOptionsMenu(Menu menu) {\n MenuInflater inflater= getMenuInflater();\n inflater.inflate(R.menu.menu_main, menu);\n return super.onCreateOptionsMenu(menu);\n }", "@Override\n public void onCreateOptionsMenu(Menu menu, MenuInflater inflater) {\n super.onCreateOptionsMenu(menu, inflater);\n inflater.inflate(R.menu.inter_main, menu);\n }", "@Override\n public boolean onCreateOptionsMenu(Menu menu) {\n getMenuInflater().inflate(R.menu.menu, menu);\n return super.onCreateOptionsMenu(menu);\n }", "@Override\n\tpublic boolean onCreateOptionsMenu(Menu menu) {\n\t\tgetMenuInflater().inflate(R.menu.action, menu);\n\t\treturn true;\n\t}", "@Override\n public boolean onCreateOptionsMenu(Menu menu) {\n MenuInflater inflater = getMenuInflater();\n inflater.inflate(R.menu.menu, menu);\n return super.onCreateOptionsMenu(menu);\n }", "@Override\n public boolean onCreateOptionsMenu(Menu menu) {\n MenuInflater inflater = getMenuInflater();\n inflater.inflate(R.menu.menu, menu);\n return super.onCreateOptionsMenu(menu);\n }", "@Override\n public boolean onCreateOptionsMenu (Menu menu){\n MenuInflater inflater = getMenuInflater();\n inflater.inflate(R.menu.menu_main, menu);\n return super.onCreateOptionsMenu(menu);\n }", "@Override\n\tpublic boolean onCreateOptionsMenu(Menu menu) {\n\t\tgetMenuInflater().inflate(R.menu.custom_action_bar, menu);\n\t\treturn true;\n\t}", "public void initMenubar() {\n\t\tremoveAll();\n\n\t\t// \"File\"\n\t\tfileMenu = new FileMenuD(app);\n\t\tadd(fileMenu);\n\n\t\t// \"Edit\"\n\t\teditMenu = new EditMenuD(app);\n\t\tadd(editMenu);\n\n\t\t// \"View\"\n\t\t// #3711 viewMenu = app.isApplet()? new ViewMenu(app, layout) : new\n\t\t// ViewMenuApplicationD(app, layout);\n\t\tviewMenu = new ViewMenuApplicationD(app, layout);\n\t\tadd(viewMenu);\n\n\t\t// \"Perspectives\"\n\t\t// if(!app.isApplet()) {\n\t\t// perspectivesMenu = new PerspectivesMenu(app, layout);\n\t\t// add(perspectivesMenu);\n\t\t// }\n\n\t\t// \"Options\"\n\t\toptionsMenu = new OptionsMenuD(app);\n\t\tadd(optionsMenu);\n\n\t\t// \"Tools\"\n\t\ttoolsMenu = new ToolsMenuD(app);\n\t\tadd(toolsMenu);\n\n\t\t// \"Window\"\n\t\twindowMenu = new WindowMenuD(app);\n\n\t\tadd(windowMenu);\n\n\t\t// \"Help\"\n\t\thelpMenu = new HelpMenuD(app);\n\t\tadd(helpMenu);\n\n\t\t// support for right-to-left languages\n\t\tapp.setComponentOrientation(this);\n\t}", "@Override\n\tpublic boolean onCreateOptionsMenu(Menu menu) {\n\t\tgetMenuInflater().inflate(R.menu.main, menu);\n\t\treturn super.onCreateOptionsMenu(menu);\n\t}", "@Override\n\tpublic boolean onCreateOptionsMenu(Menu menu) {\n\t\tsuper.onCreateOptionsMenu(menu);\n\t\tMenuInflater blowUp=getMenuInflater();\n\t\tblowUp.inflate(R.menu.welcome_menu, menu);\n\t\treturn true;\n\t}", "@Override\r\n\tpublic boolean onCreateOptionsMenu(Menu menu) {\n\t\tgetMenuInflater().inflate(R.menu.listing, menu);\r\n\t\treturn true;\r\n\t}", "@Override\n public boolean onCreateOptionsMenu(Menu menu) {\n getMenuInflater().inflate(R.menu.item, menu);\n return true;\n }", "@Override\n\tpublic boolean onCreateOptionsMenu(Menu menu) {\n\t\tgetMenuInflater().inflate(R.menu.resource, menu);\n\t\treturn true;\n\t}", "@Override\n public boolean onCreateOptionsMenu(Menu menu) {\n MenuInflater inflater= getMenuInflater();\n inflater.inflate(R.menu.menu,menu);\n return super.onCreateOptionsMenu(menu);\n }", "@Override\n public boolean onCreateOptionsMenu(Menu menu) {\n MenuInflater inflater = getMenuInflater();\n inflater.inflate(R.menu.home_action_bar, menu);\n return super.onCreateOptionsMenu(menu);\n }", "@Override\n public boolean onCreateOptionsMenu(Menu menu) {\n MenuInflater inflater = getMenuInflater();\n inflater.inflate(R.menu.main, menu);\n return super.onCreateOptionsMenu(menu);\n }", "@Override\n public boolean onCreateOptionsMenu(Menu menu) {\n MenuInflater inflater = getMenuInflater();\n inflater.inflate(R.menu.main, menu);\n return super.onCreateOptionsMenu(menu);\n }", "@Override\n\tpublic boolean onCreateOptionsMenu(Menu menu) {\n\t\tgetMenuInflater().inflate(R.menu.template, menu);\n\t\treturn true;\n\t}", "@Override\n public boolean onCreateOptionsMenu(Menu menu) {\n Log.d(\"onCreateOptionsMenu\", \"create menu\");\n MenuInflater inflater = getMenuInflater();\n inflater.inflate(R.menu.socket_activity_actions, menu);\n return super.onCreateOptionsMenu(menu);\n }", "@Override\n public boolean onCreateOptionsMenu(Menu menu) {\n getMenuInflater().inflate(R.menu.main_menu, menu);//Menu Resource, Menu\n\n return true;\n }", "@Override\n public boolean onCreateOptionsMenu(Menu menu) {\n getMenuInflater().inflate(R.menu.actionbar, menu);\n return true;\n }", "@Override\n public boolean onCreateOptionsMenu(Menu menu) {\n getMenuInflater().inflate(toolbar_res, menu);\n updateMenuItemsVisibility(menu);\n return true;\n }", "@Override\n\tpublic boolean onCreateOptionsMenu(Menu menu) {\n\t\t// \n\t\tMenuInflater mi = getMenuInflater();\n\t\tmi.inflate(R.menu.thumb_actv_menu, menu);\n\t\t\n\t\treturn super.onCreateOptionsMenu(menu);\n\t}", "@Override\n\tpublic void onCreateOptionsMenu(Menu menu, MenuInflater inflater) {\n\t\tsuper.onCreateOptionsMenu(menu, inflater);\n\t}", "@Override\n\tpublic void onCreateOptionsMenu(Menu menu, MenuInflater inflater) {\n\t\tsuper.onCreateOptionsMenu(menu, inflater);\n\t}", "@Override\n\tpublic void onCreateOptionsMenu(Menu menu, MenuInflater inflater) {\n\t\tsuper.onCreateOptionsMenu(menu, inflater);\n\t}", "@Override\n public void onCreateOptionsMenu(Menu menu, MenuInflater inflater) {\n super.onCreateOptionsMenu(menu, inflater);\n }", "@Override\n\t\tpublic boolean onCreateOptionsMenu(Menu menu) {\n\t\t\tgetMenuInflater().inflate(R.menu.main, menu);\n\t\t\treturn true;\n\t\t}", "@Override\n\t\tpublic boolean onCreateOptionsMenu(Menu menu) {\n\t\t\tgetMenuInflater().inflate(R.menu.main, menu);\n\t\t\treturn true;\n\t\t}", "@Override\n\t\tpublic boolean onCreateOptionsMenu(Menu menu) {\n\t\t\tgetMenuInflater().inflate(R.menu.main, menu);\n\t\t\treturn true;\n\t\t}", "@Override\n public void onCreateOptionsMenu(Menu menu, MenuInflater inflater) {\n super.onCreateOptionsMenu(menu, inflater);\n\n }", "@Override\n public boolean onCreateOptionsMenu(Menu menu) {\n MenuInflater inflater = getMenuInflater();\n inflater.inflate(R.menu.swag_list_activity_menu, menu);\n return super.onCreateOptionsMenu(menu);\n }", "@Override\n public boolean onCreateOptionsMenu(Menu menu) {\n MenuInflater inflater = getMenuInflater();\n inflater.inflate(R.menu.main_menu, menu);\n return super.onCreateOptionsMenu(menu);\n }", "@Override\n\tpublic boolean onCreateOptionsMenu(android.view.Menu menu) {\n\t\tgetMenuInflater().inflate(R.menu.main, menu);\n\n\t\treturn true;\n\t}", "public void onCreateOptionsMenu(Menu menu, MenuInflater inflater){\n }", "@Override\n\t\tpublic boolean onCreateOptionsMenu(Menu menu) {\n\t\t\tgetMenuInflater().inflate(R.menu.main, menu);\n\t\t\treturn true;\n\t}", "@Override\n\tpublic boolean onCreateOptionsMenu(Menu menu) {\n\t\tgetMenuInflater().inflate(R.menu.jarvi, menu);\n\t\treturn super.onCreateOptionsMenu(menu);\n\t}", "@Override\n public void onCreateOptionsMenu(Menu menu, MenuInflater menuInflater) {\n menuInflater.inflate(R.menu.main, menu);\n\n }", "@Override\r\n public boolean onCreateOptionsMenu(Menu menu) {\n getMenuInflater().inflate(R.menu.actmain, menu);\r\n return true;\r\n }", "@Override\r\n\tpublic boolean onCreateOptionsMenu(Menu menu) {\n\t\tgetMenuInflater().inflate(R.menu.add__listing, menu);\r\n\t\treturn true;\r\n\t}", "@Override\n\tpublic boolean onCreateOptionsMenu(Menu menu) {\n\t\tgetMenuInflater().inflate(R.menu.buat_menu, menu);\n\t\treturn true;\n\t}", "@Override\n\tpublic boolean onCreateOptionsMenu(Menu menu) {\n\t\tgetMenuInflater().inflate(R.layout.menu, menu);\n\t\treturn true;\n\t}", "@Override\npublic boolean onCreateOptionsMenu(Menu menu) {\n\n\t\n\t\n\tgetMenuInflater().inflate(R.menu.main, menu);\n\t\n\treturn super.onCreateOptionsMenu(menu);\n}", "@Override\n\tpublic boolean onCreateOptionsMenu(Menu menu) {\n\t\tgetMenuInflater().inflate(R.menu.ichat, menu);\n\t\treturn true;\n\t}", "@Override\n public boolean onCreateOptionsMenu(Menu menu) {\n getMenuInflater().inflate(R.menu.menu, menu);\n return super.onCreateOptionsMenu(menu);\n }", "@Override\n\tpublic void onCreateOptionsMenu(Menu menu, MenuInflater inflater)\n\t{\n\t\tsuper.onCreateOptionsMenu(menu, inflater);\n\t\tinflater.inflate(R.menu.expenses_menu, menu);\n\t}", "@Override\n public boolean onCreateOptionsMenu(Menu menu) {\n getMenuInflater().inflate(R.menu.action_bar, menu);\n return true;\n }", "@Override\n \tpublic boolean onCreateOptionsMenu(Menu menu) {\n \t\tgetMenuInflater().inflate(R.menu.main, menu);\n \t\treturn true;\n \t}", "@Override\n \tpublic boolean onCreateOptionsMenu(Menu menu) {\n \t\tgetMenuInflater().inflate(R.menu.main, menu);\n \t\treturn true;\n \t}", "@Override\n \tpublic boolean onCreateOptionsMenu(Menu menu) {\n \t\tgetMenuInflater().inflate(R.menu.main, menu);\n \t\treturn true;\n \t}", "@Override\n\tpublic boolean onCreateOptionsMenu(Menu menu) {\n\t\tsuper.onCreateOptionsMenu(menu);\n\t\tMenuInflater blowUp = getMenuInflater();\n\t\tblowUp.inflate(R.menu.status, menu);\n\t\treturn true;\n\t}", "@Override\r\n\tpublic boolean onCreateOptionsMenu(Menu menu) {\n\t\tgetMenuInflater().inflate(R.menu.menu, menu);\r\n\t\treturn true;\r\n\t}", "@Override\n\tpublic void onCreateOptionsMenu(Menu menu, MenuInflater inflater) {\n\t}", "@Override\n\tpublic boolean onCreateOptionsMenu(Menu menu) {\n\t\tMenuInflater inflater = getMenuInflater();\n\t\tinflater.inflate(R.menu.main, menu);\n\t\treturn true;\n\t}", "@Override\r\n\tpublic boolean onCreateOptionsMenu(Menu menu) {\n\t\tgetMenuInflater().inflate(R.menu.ui_main, menu);\r\n\t\treturn true;\r\n\t}", "@Override\n public boolean onCreateOptionsMenu(Menu menu) {\n getMenuInflater().inflate(R.menu.main_activity_actions, menu);\n return true;\n }", "@Override\n public void onCreateOptionsMenu(Menu menu, MenuInflater inflater) {\n inflater.inflate(R.menu.menu_main, menu);\n super.onCreateOptionsMenu(menu, inflater);\n }", "@Override\n public void onCreateOptionsMenu(Menu menu, MenuInflater inflater) {\n inflater.inflate(R.menu.menu_main, menu);\n super.onCreateOptionsMenu(menu, inflater);\n }" ]
[ "0.72474515", "0.72030497", "0.7196155", "0.7178126", "0.7107996", "0.7041309", "0.70395386", "0.7012691", "0.7010885", "0.69815445", "0.69462097", "0.6940046", "0.69345695", "0.69183254", "0.69183254", "0.6892358", "0.6885014", "0.6876514", "0.6876359", "0.68626404", "0.68626404", "0.68626404", "0.68626404", "0.68531734", "0.6847643", "0.6820225", "0.68181914", "0.6814208", "0.6813837", "0.6813837", "0.68064666", "0.68020374", "0.6798646", "0.6791925", "0.6790931", "0.67888904", "0.67845815", "0.6760694", "0.6757882", "0.6748644", "0.67447454", "0.67447454", "0.67418957", "0.6741017", "0.67266047", "0.67249906", "0.6723434", "0.6723434", "0.67215663", "0.67127925", "0.6707654", "0.67049575", "0.6700402", "0.66994053", "0.6697105", "0.66957295", "0.6687554", "0.66844624", "0.66841024", "0.66841024", "0.6681423", "0.66800034", "0.6677954", "0.6669318", "0.6668182", "0.66635394", "0.66584915", "0.66584915", "0.66584915", "0.665774", "0.6654975", "0.6654975", "0.6654975", "0.66531545", "0.6653111", "0.6650819", "0.6649277", "0.6647981", "0.6647559", "0.66473025", "0.66472363", "0.66454226", "0.6645291", "0.6644485", "0.6643628", "0.66426724", "0.6639548", "0.66354436", "0.6634969", "0.66334665", "0.6632732", "0.6632732", "0.6632732", "0.6630075", "0.66289353", "0.6628308", "0.6626852", "0.6625003", "0.66209805", "0.661984", "0.661984" ]
0.0
-1
Handle action bar item clicks here. The action bar will automatically handle clicks on the Home/Up button, so long as you specify a parent activity in AndroidManifest.xml. Handle presses on the action bar items
@Override public boolean onOptionsItemSelected(MenuItem item) { switch (item.getItemId()) { case R.id.action_settings: Intent prefsIntentS = new Intent(this, PreferencesActivity.class); startActivity(prefsIntentS); return true; case R.id.action_about: Intent aboutIntent = new Intent(this, AboutActivity.class); startActivity(aboutIntent); overridePendingTransition(R.anim.fadein,R.anim.fader); return true; case R.id.action_help: Intent helpIntent = new Intent(this, HelpActivity.class); startActivity(helpIntent); overridePendingTransition(R.anim.fadein,R.anim.fader); return true; default: return super.onOptionsItemSelected(item); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n public boolean onOptionsItemSelected(MenuItem item) { Handle action bar item clicks here. The action bar will\n // automatically handle clicks on the Home/Up button, so long\n // as you specify a parent activity in AndroidManifest.xml.\n\n //\n // HANDLE BACK BUTTON\n //\n int id = item.getItemId();\n if (id == android.R.id.home) {\n // Back button clicked\n this.finish();\n }\n\n return super.onOptionsItemSelected(item);\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n switch (item.getItemId()) {\n // Respond to the action bar's Up/Home button\n case android.R.id.home:\n onBackPressed();\n return true;\n default:\n return super.onOptionsItemSelected(item);\n }\n }", "@Override\r\n public boolean onOptionsItemSelected(MenuItem item) {\n int id = item.getItemId();\r\n switch (id) {\r\n case android.R.id.home:\r\n // app icon in action bar clicked; go home\r\n this.finish();\r\n return true;\r\n default:\r\n return super.onOptionsItemSelected(item);\r\n }\r\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n switch (item.getItemId()) {\n case android.R.id.home:\n // app icon in action bar clicked; goto parent activity.\n onBackPressed();\n return true;\n default:\n return super.onOptionsItemSelected(item);\n }\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n // Handle presses on the action bar items\n switch (item.getItemId()) {\n case android.R.id.home:\n onBackPressed();\n return true;\n case R.id.action_clear:\n return true;\n case R.id.action_done:\n\n return true;\n default:\n return super.onOptionsItemSelected(item);\n }\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n int id = item.getItemId();\n\n if (id == android.R.id.home) {\n Log.e(\"clik\", \"action bar clicked\");\n finish();\n }\n\n return super.onOptionsItemSelected(item);\n }", "@Override\n\t public boolean onOptionsItemSelected(MenuItem item) {\n\t int id = item.getItemId();\n\t \n\t\t\tif (id == android.R.id.home) {\n\t\t\t\t// Respond to the action bar's Up/Home button\n\t\t\t\t// NavUtils.navigateUpFromSameTask(this);\n\t\t\t\tonBackPressed();\n\t\t\t\treturn true;\n\t\t\t}\n\t \n\t \n\t return super.onOptionsItemSelected(item);\n\t }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n int id = item.getItemId();\n if (id == android.R.id.home) {\n // app icon in action bar clicked; go home\n finish();\n }\n return super.onOptionsItemSelected(item);\n }", "@Override\n\tpublic boolean onOptionsItemSelected(MenuItem item) {\n\t switch (item.getItemId()) {\n\t\tcase android.R.id.home:\n\t\t\t// app icon in action bar clicked; go home \n\t\t\tIntent intent = new Intent(this, Kelutral.class); \n\t\t\tintent.addFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP); \n\t\t\tstartActivity(intent); \n\t\t\treturn true;\t\t\n\t case R.id.Search:\n\t \treturn onSearchRequested();\n\t\tcase R.id.AppInfo:\n\t\t\t// Place holder menu item\n\t\t\tIntent newIntent = new Intent(Intent.ACTION_VIEW,\n\t\t\t\t\tUri.parse(\"http://forum.learnnavi.org/mobile-apps/\"));\n\t\t\tstartActivity(newIntent);\n\t\t\treturn true;\n\t\tcase R.id.Preferences:\n\t\t\tnewIntent = new Intent(getBaseContext(), Preferences.class);\n\t\t\tstartActivity(newIntent);\n\t\t\treturn true;\t\n\t }\n\t return false;\n\t}", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n int id = item.getItemId();\n switch (id) {\n case android.R.id.home:\n onActionHomePressed();\n return true;\n }\n return super.onOptionsItemSelected(item);\n }", "@Override\n\tpublic boolean onOptionsItemSelected(MenuItem item) {\n\t\tswitch (item.getItemId()) {\n\t\tcase android.R.id.home:\n\t\t\tonBackPressed();\n\t\t\treturn true;\n\t\tdefault:\n\t\t\treturn super.onOptionsItemSelected(item);\n\t\t}\n\t}", "@Override\r\n public boolean onOptionsItemSelected(MenuItem item) {\r\n switch (item.getItemId()) {\r\n // Respond to the action bar's Up/Home button\r\n case android.R.id.home:\r\n finish();\r\n return true;\r\n }\r\n return super.onOptionsItemSelected(item);\r\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n int id = item.getItemId();\n\n switch (id) {\n case android.R.id.home:\n onBackPressed();\n break;\n }\n return super.onOptionsItemSelected(item);\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n switch (item.getItemId()) {\n // Respond to the action bar's Up/Home button\n case android.R.id.home:\n finish();\n return true;\n }\n\n return super.onOptionsItemSelected(item);\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n int id = item.getItemId();\n\n //noinspection SimplifiableIfStatement\n\n switch (item.getItemId()) {\n case android.R.id.home:\n\n // app icon in action bar clicked; goto parent activity.\n this.finish();\n return true;\n default:\n\n return super.onOptionsItemSelected(item);\n\n }\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n int id = item.getItemId();\n\n //noinspection SimplifiableIfStatement\n\n switch (item.getItemId()) {\n case android.R.id.home:\n\n // app icon in action bar clicked; goto parent activity.\n this.finish();\n return true;\n default:\n\n return super.onOptionsItemSelected(item);\n\n }\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n int id = item.getItemId();\n switch (id) {\n case android.R.id.home:\n onBackPressed();\n break;\n }\n\n return super.onOptionsItemSelected(item);\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n switch (item.getItemId()) {\n case android.R.id.home:\n onBackPressed();\n return true;\n\n default:\n return super.onOptionsItemSelected(item);\n }\n\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n\n switch (item.getItemId())\n {\n case android.R.id.home :\n super.onBackPressed();\n break;\n }\n return super.onOptionsItemSelected(item);\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n switch (item.getItemId ()) {\n case android.R.id.home:\n onBackPressed ();\n return true;\n\n default:\n break;\n }\n return super.onOptionsItemSelected ( item );\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n switch (item.getItemId()) {\n\n case android.R.id.home:\n onBackPressed();\n return true;\n\n }\n return super.onOptionsItemSelected(item);\n\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n // Pass the event to ActionBarDrawerToggle, if it returns\n // true, then it has handled the app icon touch event\n if (mDrawerToggle.onOptionsItemSelected(item)) {\n return true;\n }\n\n // Handle your other action bar items...\n return super.onOptionsItemSelected(item);\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n\n switch (item.getItemId()) {\n case android.R.id.home:\n super.onBackPressed();\n return true;\n\n default:\n // If we got here, the user's action was not recognized.\n // Invoke the superclass to handle it.\n return super.onOptionsItemSelected(item);\n\n }\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n switch (item.getItemId()) {\n case android.R.id.home:\n onBackPressed();\n return true;\n default:\n return super.onOptionsItemSelected(item);\n\n }\n\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n int id = item.getItemId();\n\n //noinspection SimplifiableIfStatement\n if(id == android.R.id.home){\n onBackPressed();\n }\n\n return super.onOptionsItemSelected(item);\n }", "@RequiresApi(api = Build.VERSION_CODES.M)\n @Override\n public boolean onOptionsItemSelected(MenuItem item) {\n switch (item.getItemId()) {\n case android.R.id.home:\n onBackPressed();\n break;\n }\n return super.onOptionsItemSelected(item);\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n switch (item.getItemId()) {\n case android.R.id.home:\n onBackPressed();\n return true;\n\n default:\n return super.onOptionsItemSelected(item);\n }\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n // Handle action bar item clicks here. The action bar will\n // automatically handle clicks on the Home/Up button, so long\n // as you specify a parent activity in AndroidManifest.xml.\n int id = item.getItemId();\n\n\n return super.onOptionsItemSelected(item);\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n switch (item.getItemId()) {\n case android.R.id.home:\n onBackPressed();\n return true;\n }\n return super.onOptionsItemSelected(item);\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n switch (item.getItemId()) {\n case android.R.id.home:\n onBackPressed();\n return true;\n }\n return super.onOptionsItemSelected(item);\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n switch (item.getItemId()) {\n //Back arrow\n case android.R.id.home:\n onBackPressed();\n }\n return super.onOptionsItemSelected(item);\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n int id = item.getItemId();\n\n switch (id) {\n case android.R.id.home:\n onBackPressed();\n return false;\n }\n\n return super.onOptionsItemSelected(item);\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n int id = item.getItemId();\n\n if (id == android.R.id.home) {\n onBackPressed();\n return true;\n }\n\n return super.onOptionsItemSelected(item);\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n switch (item.getItemId()) {\n case android.R.id.home:\n onBackPressed();\n return true;\n default:\n return super.onOptionsItemSelected(item);\n }\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n switch (item.getItemId()) {\n case android.R.id.home:\n onBackPressed();\n return true;\n default:\n return super.onOptionsItemSelected(item);\n }\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n switch (item.getItemId()) {\n case android.R.id.home:\n onBackPressed();\n return true;\n default:\n return super.onOptionsItemSelected(item);\n }\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n switch (item.getItemId()) {\n case android.R.id.home:\n onBackPressed();\n return true;\n }\n\n return super.onOptionsItemSelected(item);\n }", "@Override\n\tpublic boolean onOptionsItemSelected(MenuItem item) {\n\t\tswitch (item.getItemId()) {\n\t\tcase android.R.id.home:\n\t\t\tonBackPressed();\n\t\t\treturn true;\n\t\tcase R.id.scan_menu:\n\t\t\tonScan();\n\t\t\tbreak;\n\t\tcase R.id.opt_about:\n\t\t\t//onAbout();\n\t\t\tbreak;\n\t\tcase R.id.opt_exit:\n\t\t\tfinish();\n\t\t\tbreak;\n\t\tdefault:\n\t\t\treturn super.onOptionsItemSelected(item);\n\t\t}\n\t\treturn true;\n\t}", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n switch (item.getItemId()) {\n case android.R.id.home:\n // Intent homeIntent = new Intent(this, MainActivity.class);\n // homeIntent.addFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP);\n // startActivity(homeIntent);\n finish();\n return true;\n default:\n return (super.onOptionsItemSelected(item));\n }\n\n }", "@Override\r\n\tpublic boolean onOptionsItemSelected(MenuItem item) {\n\t\tif(item.getItemId()==android.R.id.home)\r\n\t\t{\r\n\t\t\tgetActivity().onBackPressed();\r\n\t\t}\r\n\t\treturn super.onOptionsItemSelected(item);\r\n\t}", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n switch (item.getItemId()) {\n case android.R.id.home:\n this.onBackPressed();\n return false;\n }\n return false;\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n int id = item.getItemId();\n if (id == android.R.id.home) {\n // This ID represents the Home or Up button. In the case of this\n // activity, the Up button is shown. Use NavUtils to allow users\n // to navigate up one level in the application structure. For\n // more details, see the Navigation pattern on Android Design:\n //\n // http://developer.android.com/design/patterns/navigation.html#up-vs-back\n //\n \tgetActionBar().setDisplayHomeAsUpEnabled(false);\n \tgetFragmentManager().popBackStack();\n return true;\n }\n return super.onOptionsItemSelected(item);\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n switch (item.getItemId()) {\n case android.R.id.home:\n onBackPressed();\n return true;\n default:\n }\n return super.onOptionsItemSelected(item);\n }", "@Override\r\n public boolean onOptionsItemSelected(MenuItem item) {\r\n // Handle item selection\r\n switch (item.getItemId()) {\r\n case android.R.id.home:\r\n onBackPressed();\r\n return true;\r\n\r\n case me.cchiang.lookforthings.R.id.action_sample:\r\n// Snackbar.make(parent_view, item.getTitle() + \" Clicked \", Snackbar.LENGTH_SHORT).show();\r\n return true;\r\n default:\r\n return super.onOptionsItemSelected(item);\r\n }\r\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n if(item.getItemId()==android.R.id.home){\n super.onBackPressed();\n }\n return super.onOptionsItemSelected(item);\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n switch (item.getItemId()) {\n case android.R.id.home:\n super.onBackPressed();\n return true;\n }\n return super.onOptionsItemSelected(item);\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n // setResult and close the activity when Action Bar Up Button clicked.\n if (item.getItemId() == android.R.id.home) {\n setResult(RESULT_CANCELED);\n finish();\n return true;\n }\n return super.onOptionsItemSelected(item);\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n switch (item.getItemId()){\n case android.R.id.home:\n onBackPressed();\n break;\n }\n return true;\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n switch (item.getItemId()) {\n case android.R.id.home:\n // android.R.id.home是Android内置home按钮的id\n finish();\n break;\n }\n return super.onOptionsItemSelected(item);\n }", "@Override\r\n public boolean onOptionsItemSelected(MenuItem item) {\n switch (item.getItemId()) {\r\n // Respond to a click on the \"Delete all entries\" menu option\r\n case R.id.action_share_list:\r\n // TODO: Action for the App Bar\r\n return true;\r\n case R.id.action_delete:\r\n // TODO: Action for the App Bar\r\n return true;\r\n // Respond to a click on the \"Up\" arrow button in the app bar\r\n case android.R.id.home:\r\n NavUtils.navigateUpFromSameTask(RecordActivity.this);\r\n return true;\r\n }\r\n return super.onOptionsItemSelected(item);\r\n }", "@Override\r\n public boolean onOptionsItemSelected(MenuItem item) {\n switch (item.getItemId()) {\r\n case android.R.id.home:\r\n onBackPressed();\r\n break;\r\n }\r\n return true;\r\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n\n onBackPressed();\n\n return super.onOptionsItemSelected(item);\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n // Handling item selection\n switch (item.getItemId()) {\n case R.id.action_home:\n Intent intent = new Intent(this, MainActivity.class);\n startActivity(intent);\n return true;\n case R.id.action_birds:\n intent = new Intent(this, Birds.class);\n startActivity(intent);\n return true;\n case R.id.action_storm:\n intent = new Intent(this, Storm.class);\n startActivity(intent);\n return true;\n case R.id.action_nocturnal:\n intent = new Intent(this, Nocturnal.class);\n startActivity(intent);\n return true;\n case R.id.action_library:\n intent = new Intent(this, Mylibrary.class);\n startActivity(intent);\n return true;\n case R.id.action_now_playing:\n intent = new Intent(this, Nowplaying.class);\n startActivity(intent);\n return true;\n case R.id.action_download:\n intent = new Intent(this, Download.class);\n startActivity(intent);\n return true;\n default:\n return super.onOptionsItemSelected(item);\n }\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n switch (item.getItemId()) {\n // Respond to the action bar's Up/Home button\n case android.R.id.home:\n NavUtils.navigateUpFromSameTask(getActivity());\n return true;\n case R.id.action_settings:\n Intent i = new Intent(getActivity(), SettingsActivity.class);\n startActivity(i);\n return true;\n }\n\n return super.onOptionsItemSelected(item);\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n int id = item.getItemId();\n\n switch (id){\n case android.R.id.home:\n this.finish();\n return true;\n }\n\n return super.onOptionsItemSelected(item);\n }", "@Override\n public boolean onOptionsItemSelected(@NonNull MenuItem item) {\n if (item.getItemId() == android.R.id.home) {\n onBackPressed();\n }\n return super.onOptionsItemSelected(item);\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n int id = item.getItemId();\n\n //noinspection SimplifiableIfStatement\n if (id == android.R.id.home) {\n onBackPressed();\n return true;\n }\n\n return super.onOptionsItemSelected(item);\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n int id = item.getItemId();\n\n //noinspection SimplifiableIfStatement\n if (id == android.R.id.home) {\n onBackPressed();\n return true;\n }\n\n return super.onOptionsItemSelected(item);\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n int id = item.getItemId();\n\n //noinspection SimplifiableIfStatement\n if (id == android.R.id.home) {\n onBackPressed();\n return true;\n }\n\n return super.onOptionsItemSelected(item);\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n int id = item.getItemId();\n\n //noinspection SimplifiableIfStatement\n if (id == android.R.id.home) {\n onBackPressed();\n return true;\n }\n\n return super.onOptionsItemSelected(item);\n }", "@Override\r\n public boolean onOptionsItemSelected(MenuItem item) {\r\n switch (item.getItemId()) {\r\n\r\n case android.R.id.home:\r\n /*Intent i= new Intent(getApplication(), MainActivity.class);\r\n i.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK | Intent.FLAG_ACTIVITY_CLEAR_TOP);\r\n startActivity(i);*/\r\n onBackPressed();\r\n finish();\r\n return true;\r\n default:\r\n return super.onOptionsItemSelected(item);\r\n }\r\n }", "@Override\r\n\tpublic boolean onOptionsItemSelected(MenuItem item) {\n\t\tswitch (item.getItemId()) {\r\n\t\tcase android.R.id.home:\r\n\t\t\tsetResult(RESULT_OK, getIntent());\r\n\t\t\tfinish();\r\n\t\t\tbreak;\r\n\t\t}\r\n\t\treturn true;\r\n\t}", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n int id = item.getItemId();\n\n\n if (id == android.R.id.home) {\n NavUtils.navigateUpFromSameTask(this);\n }\n\n return super.onOptionsItemSelected(item);\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n int id = item.getItemId();\n //Fixes the Up Button\n if(id == android.R.id.home) {\n BuildRoute.this.finish();\n return true;\n }\n return super.onOptionsItemSelected(item);\n }", "@Override\r\n public boolean onOptionsItemSelected(MenuItem item) {\n int id = item.getItemId();\r\n\r\n //noinspection SimplifiableIfStatement\r\n if (id == R.id.home) {\r\n NavUtils.navigateUpFromSameTask(this);\r\n return true;\r\n }\r\n\r\n //noinspection SimplifiableIfStatement\r\n if (id == R.id.action_about) {\r\n AboutDialog();\r\n return true;\r\n }\r\n\r\n //noinspection SimplifiableIfStatement\r\n if (id == R.id.action_exit) {\r\n finish();\r\n return true;\r\n }\r\n\r\n\r\n return super.onOptionsItemSelected(item);\r\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n switch (item.getItemId()) {\n case android.R.id.home:\n onBackPressed();\n //NavUtils.navigateUpFromSameTask(this);\n return true;\n default:\n return super.onOptionsItemSelected(item);\n }\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n switch (item.getItemId()) {\n case android.R.id.home:\n finish();\n return true;\n default:\n // If we got here, the user's action was not recognized.\n // Invoke the superclass to handle it.\n return super.onOptionsItemSelected(item);\n\n }\n }", "@Override\n\tpublic boolean onOptionsItemSelected(MenuItem item) {\n\t\tif (item.getItemId() == android.R.id.home) {\n\t\t\tfinish();\n\t\t}\n\t\treturn super.onOptionsItemSelected(item);\n\t}", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n switch (item.getItemId()) {\n case android.R.id.home:\n\n this.finish();\n return true;\n default:\n return super.onOptionsItemSelected(item);\n }\n\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n if (item.getItemId() == android.R.id.home) {\n onBackPressed();\n return true;\n }\n return false;\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n int id = item.getItemId();\n\n//noinspection SimplifiableIfStatement\n if (id == android.R.id.home) {\n// finish the activity\n onBackPressed();\n return true;\n }\n\n return super.onOptionsItemSelected(item);\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item)\n {\n int id = item.getItemId();\n\n //noinspection SimplifiableIfStatement\n if( id == android.R.id.home ) // Back button of the actionbar\n {\n finish();\n return true;\n }\n\n return super.onOptionsItemSelected(item);\n }", "@Override\r\n\t\tpublic boolean onOptionsItemSelected(MenuItem item) {\n\t\t\tswitch (item.getItemId()) {\r\n\t\t\tcase android.R.id.home:\r\n\t\t\t\tfinish();\r\n\t\t\t\tbreak;\r\n\t\t\tdefault:\r\n\t\t\t\tbreak;\r\n\t\t\t}\r\n\t\t\treturn super.onOptionsItemSelected(item);\r\n\t\t}", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n int id = item.getItemId();\n\n //noinspection SimplifiableIfStatement\n switch(item.getItemId())\n {\n case android.R.id.home:\n super.onBackPressed();\n break;\n }\n\n return super.onOptionsItemSelected(item);\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n int id = item.getItemId();\n\n switch (id) {\n\n case android.R.id.home:\n this.finish();\n return true;\n }\n return true;\n }", "@Override\r\n public boolean onOptionsItemSelected(MenuItem item) {\n int id = item.getItemId();\r\n\r\n //noinspection SimplifiableIfStatement\r\n if (id == android.R.id.home) {\r\n // finish the activity\r\n onBackPressed();\r\n return true;\r\n }\r\n\r\n return super.onOptionsItemSelected(item);\r\n }", "@Override\r\n public boolean onOptionsItemSelected(MenuItem item) {\n int id = item.getItemId();\r\n\r\n //noinspection SimplifiableIfStatement\r\n if (id == android.R.id.home) {\r\n // finish the activity\r\n onBackPressed();\r\n return true;\r\n }\r\n\r\n return super.onOptionsItemSelected(item);\r\n }", "@Override\n\tpublic boolean onOptionsItemSelected(MenuItem item) {\n\t\tswitch (item.getItemId()) {\n\t\tcase android.R.id.home:\n\t\t\tfinish();\n\t\t\tbreak;\n\n\t\t}\n\t\treturn super.onOptionsItemSelected(item);\n\t}", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n int id = item.getItemId();\n\n if (id == android.R.id.home) {\n\n this.finish();\n }\n\n return super.onOptionsItemSelected(item);\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n int id = item.getItemId();\n\n if (id == android.R.id.home) {\n\n this.finish();\n }\n\n return super.onOptionsItemSelected(item);\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n int id = item.getItemId();\n\n //noinspection SimplifiableIfStatement\n if (id == android.R.id.home) {\n super.onBackPressed();\n return true;\n }\n\n return super.onOptionsItemSelected(item);\n }", "@Override\n\tpublic boolean onOptionsItemSelected(MenuItem item) {\n\t\tswitch (item.getItemId()) {\n\t\tcase android.R.id.home:\n\t\t\tfinish();\n\t\t\tbreak;\n\n\t\tdefault:\n\t\t\tbreak;\n\t\t}\n\t\treturn super.onOptionsItemSelected(item);\n\t}", "@Override\n public final boolean onOptionsItemSelected(MenuItem item) {\n if (actionBarDrawerToggle.onOptionsItemSelected(item)) {\n return true;\n }\n // Handle your other action bar items...\n\n return super.onOptionsItemSelected(item);\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n int id = item.getItemId();\n\n switch (id) {\n case android.R.id.home:\n this.finish();\n return true;\n default:\n return super.onOptionsItemSelected(item);\n }\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n int id = item.getItemId();\n\n //noinspection SimplifiableIfStatement\n if (id == android.R.id.home) {\n // finish the activity\n onBackPressed();\n return true;\n }\n return super.onOptionsItemSelected(item);\n }", "@Override\r\n public boolean onOptionsItemSelected(MenuItem item) {\n int id = item.getItemId();\r\n if ( id == android.R.id.home ) {\r\n finish();\r\n return true;\r\n }\r\n return super.onOptionsItemSelected(item);\r\n }", "@Override\n\tpublic boolean onOptionsItemSelected(MenuItem item) {\n\t\tint id = item.getItemId();\n\t\tif (id == android.R.id.home) {\n\t\t\tfinish();\n\t\t\treturn true;\n\t\t}\n\t\treturn super.onOptionsItemSelected(item);\n\t}", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n int id = item.getItemId();\n\n\n if(id == android.R.id.home){\n finish();\n }\n\n return super.onOptionsItemSelected(item);\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n switch (item.getItemId()) {\n case android.R.id.home:\n // todo: goto back activity from here\n finish();\n return true;\n\n default:\n return super.onOptionsItemSelected(item);\n }\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n int id = item.getItemId();\n //noinspection SimplifiableIfStatement\n if (id == android.R.id.home) {\n // finish the activity\n onBackPressed();\n return true;\n }\n\n return super.onOptionsItemSelected(item);\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n int id = item.getItemId();\n\n //noinspection SimplifiableIfStatement\n if (id == android.R.id.home) {\n // finish the activity\n onBackPressed();\n return true;\n }\n\n return super.onOptionsItemSelected(item);\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n int id = item.getItemId();\n\n //noinspection SimplifiableIfStatement\n if (id == android.R.id.home) {\n // finish the activity\n onBackPressed();\n return true;\n }\n\n return super.onOptionsItemSelected(item);\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n switch (item.getItemId()) {\n case android.R.id.home: \n \t Intent homeIntent = new Intent(this, MenuActivity.class);\n homeIntent.addFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP);\n startActivity(homeIntent); \n break; \n case R.id.action_cancel:\n Intent homeIntent2 = new Intent(this, MenuActivity.class);\n homeIntent2.addFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP);\n startActivity(homeIntent2); \n \t break;\n default:\n return super.onOptionsItemSelected(item);\n }\n return true;\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n\n switch (item.getItemId()) {\n case android.R.id.home:\n onBackPressed();\n\n return true;\n\n case R.id.action_settings:\n return true;\n }\n\n return super.onOptionsItemSelected(item);\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n switch (item.getItemId()) {\n case android.R.id.home:\n finish();\n return true;\n default:\n return super.onOptionsItemSelected(item);\n }\n\n\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n int id = item.getItemId();\n\n switch (id){\n case android.R.id.home:\n onBackPressed();\n return true;\n case R.id.action_settings:\n return true;\n }\n\n return super.onOptionsItemSelected(item);\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n switch (item.getItemId())\n {\n case android.R.id.home:\n this.finish();\n return (true);\n }\n return super.onOptionsItemSelected(item);\n }", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n\n if (item.getItemId() == android.R.id.home) {\n finish();\n }\n return super.onOptionsItemSelected(item);\n }", "@Override\n\tpublic boolean onOptionsItemSelected(MenuItem item) {\n\t\tswitch (item.getItemId()) {\n\t\tcase android.R.id.home:\n\t\t\tfinish();\n\t\t\treturn true;\n\n\t\tdefault:\n\t\t\treturn super.onOptionsItemSelected(item);\n\t\t}\n\t}", "@Override\n public boolean onOptionsItemSelected(MenuItem item) {\n int id = item.getItemId();\n\n switch (id){\n case R.id.home:{\n NavUtils.navigateUpFromSameTask(this);\n return true;\n }\n }\n return super.onOptionsItemSelected(item);\n }", "@Override\n public boolean onOptionsItemSelected(@NonNull MenuItem item) {\n switch (item.getItemId()) {\n case android.R.id.home: //id of back arrow set by android\n finish();\n break;\n\n default:\n break;\n }\n\n return super.onOptionsItemSelected(item);\n }" ]
[ "0.77937174", "0.76561034", "0.7616773", "0.7569597", "0.755328", "0.7500425", "0.747581", "0.7460495", "0.7408268", "0.7406156", "0.73618114", "0.7337574", "0.7306836", "0.73019415", "0.73004127", "0.73004127", "0.72956413", "0.72647184", "0.72637916", "0.7262261", "0.7257101", "0.7253315", "0.72417957", "0.7237012", "0.7222842", "0.7222321", "0.7214285", "0.72034985", "0.7196499", "0.7196499", "0.7193613", "0.7185072", "0.7183368", "0.717478", "0.717478", "0.717478", "0.7172932", "0.71635205", "0.71630394", "0.71626323", "0.71475893", "0.71400946", "0.71334493", "0.71275526", "0.7123026", "0.7115824", "0.7097727", "0.7075426", "0.70717055", "0.70611966", "0.7060916", "0.70601743", "0.7050041", "0.70450795", "0.70447445", "0.70284694", "0.70169586", "0.70169586", "0.70169586", "0.70169586", "0.70081514", "0.7005301", "0.7000939", "0.69981503", "0.6988232", "0.69874173", "0.69822514", "0.6974572", "0.6971487", "0.6970998", "0.6969316", "0.69689876", "0.69633394", "0.69607663", "0.69577575", "0.6956759", "0.6956759", "0.69524246", "0.69501287", "0.69501287", "0.6949456", "0.69494057", "0.69401485", "0.69379544", "0.691986", "0.6918451", "0.6913178", "0.6911011", "0.6910208", "0.6902904", "0.68998927", "0.68998927", "0.689747", "0.68969816", "0.68969053", "0.68966115", "0.6891365", "0.68904585", "0.68841153", "0.68838114", "0.68829787" ]
0.0
-1
TODO Autogenerated method stub
@Override public void onAnimationEnd(Animation animation) { findViewById(R.id.textView8).setVisibility(View.GONE); findViewById(R.id.textView81).setVisibility(View.GONE); findViewById(R.id.textView9).setVisibility(View.GONE); findViewById(R.id.textView10).setVisibility(View.GONE); findViewById(R.id.textView11).startAnimation(animb); }
{ "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 void onAnimationRepeat(Animation animation) { }
{ "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 void onAnimationStart(Animation animation) { }
{ "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
Definicion de los metodos nativos, estos estan implementados en el Lenguaje c, en el archivo Calculadora.c
private native double SumaC(double operador_1, double operador_2);
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public cola_de_un_banco(){// se crea nuestro metodo costructor \r\n primero=null;//se crea el tipo de indicaciones con valor a null\r\n ultimo=null;\r\n}", "private void limpiarDatos() {\n\t\t\n\t}", "public CalendarBasi()\n {\n dia = new DisplayDosDigitos(31);\n mes = new DisplayDosDigitos(13);\n anio = new DisplayDosDigitos(100);\n }", "public void afegirPosicio() {\n\t\tfor(int i=0; i<cal.length; ++i){\n\t\t\tcal[i] = new Dia(false);\n\t\t\tfor(int j=0; j<3; ++j) cal[i].getTorns()[j].setPosicio(i);\n\t\t}\n\t}", "public CalendarioSilvia()\n {\n // initialise instance variables\n dia = new DisplayDosDigitos(31);\n mes = new DisplayDosDigitos(13);\n año = new DisplayDosDigitos(100);\n }", "public Data() {\n\t\tCalendar now = new GregorianCalendar();\n\t\tthis.anno = now.get(Calendar.YEAR);\n\t\tthis.giorno = now.get(Calendar.DAY_OF_MONTH);\n\t\tthis.mese = Data.MESI[now.get(Calendar.MONTH)];\n\t}", "@Override\n\tvoid geraDados() {\n\n\t}", "private void inicializarVariablesControlRonda() {\n\t\ttieneAs = new int[4];\n\t\tfor(int i=0;i<tieneAs.length;i++) {\n\t\t\ttieneAs[i]=0;\n\t\t}\n\t\tidJugadores = new String[3];\n\t\tvalorManos = new int[4];\n\t\t\n\t\tmazo = new Baraja();\n\t\tCarta carta;\n\t\tganador = new ArrayList<String>();\n\t\tapuestasJugadores = new int[3];\n\t\tmanoJugador1 = new ArrayList<Carta>();\n\t\tmanoJugador2 = new ArrayList<Carta>();\n\t\tmanoJugador3 = new ArrayList<Carta>();\n\t\tmanoDealer = new ArrayList<Carta>();\n\t\tparejaNombreGanancia = new ArrayList<Pair<String,Integer>>(); \n\t\t\n\t\t// gestiona las tres manos en un solo objeto para facilitar el manejo del hilo\n\t\tmanosJugadores = new ArrayList<ArrayList<Carta>>(4);\n\t\tmanosJugadores.add(manoJugador1);\n\t\tmanosJugadores.add(manoJugador2);\n\t\tmanosJugadores.add(manoJugador3);\n\t\tmanosJugadores.add(manoDealer);\n\t\t// reparto inicial jugadores 1 y 2\n\t\tfor (int i = 1; i <= 2; i++) {\n\t\t\tcarta = mazo.getCarta();\n\t\t\tmanoJugador1.add(carta);\n\t\t\tcalcularValorMano(carta, 0);\n\t\t\tcarta = mazo.getCarta();\n\t\t\tmanoJugador2.add(carta);\n\t\t\tcalcularValorMano(carta, 1);\n\t\t\tcarta = mazo.getCarta();\n\t\t\tmanoJugador3.add(carta);\n\t\t\tcalcularValorMano(carta, 2);\n\t\t}\n\t\t// Carta inicial Dealer\n\t\tcarta = mazo.getCarta();\n\t\tmanoDealer.add(carta);\n\t\tcalcularValorMano(carta, 3);\n\n\t\t\n\t}", "public Pelicula(String nombre, int anno, int duracionMinutos, int calidad)\n {\n super(nombre,anno);\n this.duracionMinutos = duracionMinutos;\n this.calidad = calidad;\n }", "public Calculadora() {\n initComponents();\n }", "public Calculadora(){\n this.operador1 = 0.0;\n this.operador2 = 0.0;\n this.resultado = 0.0;\n }", "public Fecha () {\n\t\tthis.ahora = Calendar.getInstance();\n\t\tahora.set(2018, 3, 1, 15, 15, 0);\t \n\t\taño = ahora.get(Calendar.YEAR);\n\t\tmes = ahora.get(Calendar.MONTH) + 1; // 1 (ENERO) y 12 (DICIEMBRE)\n\t\tdia = ahora.get(Calendar.DAY_OF_MONTH);\n\t\thr_12 = ahora.get(Calendar.HOUR);\n\t\thr_24 = ahora.get(Calendar.HOUR_OF_DAY);\n\t\tmin = ahora.get(Calendar.MINUTE);\n\t\tseg = ahora.get(Calendar.SECOND);\n\t\tam_pm = v_am_pm[ahora.get(Calendar.AM_PM)]; //ahora.get(Calendar.AM_PM)=> 0 (AM) y 1 (PM)\n\t\tmes_nombre = v_mes_nombre[ahora.get(Calendar.MONTH)];\n\t\tdia_nombre = v_dia_nombre[ahora.get(Calendar.DAY_OF_WEEK) - 1];\n\n\t}", "public Mencacao()\r\n {\r\n texto = \"\";\r\n deUtilizador = \"\";\r\n data = new GregorianCalendar();\r\n }", "private void dibujarMarcador() {\n\n\t\tText tituloMarcador = new Text(\"Marcador\");\n\t\ttituloMarcador.setFont(new Font(16));\n\n\t\tText tituloJuega = new Text(\"Juega\");\n\t\ttituloJuega.setFont(new Font(16));\n\t\t\n\t\tcantidadFichasNegras = new Label();\n\t\tcantidadFichasBlancas = new Label();\n\t\tjugadorActual = new Label();\n\n\t\tGridPane marcador = new GridPane();\n\t\tmarcador.setAlignment(Pos.TOP_CENTER);\n\t\tmarcador.setHgap(20);\n\t\tmarcador.setVgap(20);\n\t\tmarcador.setPadding(new Insets(20));\n\t\tmarcador.add(tituloMarcador, 0, 0, 2, 1);\n\t\tmarcador.add(new Label(\"Negras :\"), 0, 1);\n\t\tmarcador.add(cantidadFichasNegras, 1, 1);\n\t\tmarcador.add(new Label(\"Blancas :\"), 0, 2);\n\t\tmarcador.add(cantidadFichasBlancas, 1, 2);\n\t\tmarcador.add(tituloJuega, 0, 3, 2, 1);\n\t\tmarcador.add(jugadorActual, 0, 4, 2, 1);\n\n\t\tpanel.setPadding(new Insets(5));\n\t\tpanel.setRight(marcador);\n\t}", "public Calculadora() {\r\n\t\tsuper();\r\n\t\tsetSize(300, 300);\r\n\t\tsetTitle(\"Convertidor de dólares\");\r\n\t\tsetDefaultCloseOperation(WindowConstants.EXIT_ON_CLOSE);\r\n\t\tsetResizable(false);\r\n\r\n\t\t// Vamos a dibujar sobre el panel\r\n\t\tJPanel panel = (JPanel) this.getContentPane();\r\n\t\tpanel.setLayout(new BorderLayout());\r\n\r\n\t\tpantalla = new JTextField(\"0\", 20);\r\n\t\tpantalla.setBorder(new EmptyBorder(4, 4, 4, 4));\r\n\t\tpantalla.setFont(new Font(\"Arial\", Font.BOLD, 25));\r\n\t\tpantalla.setHorizontalAlignment(JTextField.RIGHT);\r\n\t\tpantalla.setEditable(false);\r\n\t\tpantalla.setBackground(Color.WHITE);\r\n\t\tpanel.add(\"North\", pantalla);\r\n \r\n\t\tpanelNumeros = new JPanel();\r\n\t\tpanelNumeros.setLayout(new GridLayout(4, 3));\r\n\t\tpanelNumeros.setBorder(new EmptyBorder(4, 4, 4, 4));\r\n\r\n for (int n = 0; n <= 9; n++) {\r\n\t\t\tnuevoBotonNumerico(\"\" + n);\r\n\t\t}\r\n\r\n\t\tnuevoBotonNumerico(\".\");\r\n\r\n\t\tpanel.add(\"Center\", panelNumeros);\r\n\r\n\t\tpanelOperaciones = new JPanel();\r\n\t\tpanelOperaciones.setLayout(new GridLayout(6, 1));\r\n\t\tpanelOperaciones.setBorder(new EmptyBorder(4, 4, 4, 4));\r\n\r\n\t\tnuevoBotonOperacion(\"Convertir\");\r\n\t\tnuevoBotonOperacion(\"CE\");\r\n\r\n\t\tpanel.add(\"East\", panelOperaciones);\r\n\t\tvalidate();\r\n\t}", "private static void ordenamientoMezclaNatural(Comparable[] a, int primero, int ultimo) {\r\n\t\tint i = primero;\r\n\t\tint j = 0;\r\n\t\tint medio = 0;\r\n\t\tint az = 0;\r\n\t\twhile(true) {\r\n\t\t\ti = 0;\r\n\t\t\twhile(i < a.length) {\r\n\t\t\t\tif( i == a.length - 1) {\r\n\t\t\t\t\tbreak;\r\n\t\t\t\t}else if(a[i].compareTo(a[i + 1]) > 0) {\r\n\t\t\t\t\tbreak;\r\n\t\t\t\t}\r\n\t\t\t\tj ++;\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t//medio = primero + ( j - primero) / 2;\r\n\t\t\t\r\n\t\t\tMezcla(a, primero, i, j);\r\n\t\t\tprimero = 0;\r\n\t\t\t\r\n\t\t\tif(estaOrdenado(a)) {\r\n\t\t\t\tbreak;\r\n\t\t\t}\r\n\t\t}\r\n\t}", "public void pintaFecha(){\n \tImage image;\r\n \ttry {\r\n\t \r\n \t\tString imageUrl = PropiedadesJLet.getInstance().getProperty(\"path.img.logoinvoice\") + \"FondoLeppardPico1.png\";\r\n\t\r\n\t\t\timage = Image.getInstance(imageUrl);\r\n\t\t image.setAbsolutePosition(inmargde-10, 725);\r\n\t\t image.scaleAbsolute(50,20);\r\n\t\t image.setAlignment(Image.LEFT | Image.TEXTWRAP);//Code 2\r\n\t\t\tdocumento.add(image);\r\n \r\n\t\t\tFRAparen.absTextBoldColor(writer,\"Fecha \",inmargde,730,10,new BaseColor(255,255,255));\r\n\t\t\tFRAparen.absText(writer,FRAparen.fechaNormal(fhfactur),inmargde + 45,730,10);\r\n\t\t\t\r\n\t\t\timage = Image.getInstance(imageUrl);\r\n\t\t image.setAbsolutePosition(inmargde-10, 700);\r\n\t\t image.scaleAbsolute(100,20);\r\n\t\t image.setAlignment(Image.LEFT | Image.TEXTWRAP);//Code 2\r\n\t\t\tdocumento.add(image);\r\n\t\t\t\r\n\t\t\tif (cabecNFC.equals(\"COND\") || cabecNFC.equals(\"R\")){\r\n\t\t\t\tFRAparen.absTextBoldColor(writer,cabecNFC +\" \"+ numerNFC +\" \",inmargde,705,10,new BaseColor(255,255,255));\r\n\t\t\t} else {\r\n\t\t\t\tFRAparen.absTextBoldColor(writer,\"NFC \"+ cabecNFC +\" \"+ numerNFC +\" \",inmargde,705,10,new BaseColor(255,255,255));\r\n\t\t\t}\r\n\t\t\t\r\n \t} catch (Exception e) {\r\n \t\tSystem.err.println(this.getClass().getName() +\" ERROR pintaFecha() - \"+ e.getMessage());\r\n \t}\r\n \t\r\n }", "public Maquina() {\n savia = 0;\n reflejosLagrimas = 0;\n estado = false;\n }", "public void inicializarListaMascotas()\n {\n //creamos un arreglo de objetos y le cargamos datos\n mascotas = new ArrayList<>();\n mascotas.add(new Mascota(R.drawable.elefante,\"Elefantin\",0));\n mascotas.add(new Mascota(R.drawable.conejo,\"Conejo\",0));\n mascotas.add(new Mascota(R.drawable.tortuga,\"Tortuga\",0));\n mascotas.add(new Mascota(R.drawable.caballo,\"Caballo\",0));\n mascotas.add(new Mascota(R.drawable.rana,\"Rana\",0));\n }", "private void gerarLaudoPermanenciaMaior(MpmPrescricaoMedica prescricao,\r\n\t\t\tList<MpmLaudo> laudoList, FatConvenioSaudePlano convenioSaudePlano,\r\n\t\t\tAghParametros seqLaudoMaiorPermanencia) {\r\n\t\tMpmTipoLaudoConvenio tipoLaudoConvenio = this\r\n\t\t\t\t.getMpmTipoLaudoConvenioDAO()\r\n\t\t\t\t.obterTempoValidadeTipoLaudoPermanenciaMaior(\r\n\t\t\t\t\t\tseqLaudoMaiorPermanencia.getVlrNumerico().shortValue(),\r\n\t\t\t\t\t\tconvenioSaudePlano);\r\n\r\n\t\tif (tipoLaudoConvenio != null) {\r\n\r\n\t\t\tShort quantidadeDiasFaturamento = 0;\r\n\t\t\tShort diasPermanenciaMaior = 0;\r\n\r\n\t\t\tMpmTipoLaudo tipoLaudoMaiorPermanencia = this.getMpmTipoLaudoDAO()\r\n\t\t\t\t\t.obterPorChavePrimaria(\r\n\t\t\t\t\t\t\tseqLaudoMaiorPermanencia.getVlrNumerico()\r\n\t\t\t\t\t\t\t\t\t.shortValue());\r\n\r\n\t\t\tif (prescricao.getAtendimento().getInternacao() != null) {\r\n\t\t\t\tif (prescricao.getAtendimento()\r\n\t\t\t\t\t\t.getInternacao().getItemProcedimentoHospitalar() != null){\r\n\t\t\t\t\t\r\n\t\t\t\t\tif (prescricao.getAtendimento()\r\n\t\t\t\t\t.getInternacao().getItemProcedimentoHospitalar()\r\n\t\t\t\t\t.getQuantDiasFaturamento() != null){\r\n\t\t\t\t\t\tquantidadeDiasFaturamento = prescricao.getAtendimento()\r\n\t\t\t\t\t\t.getInternacao().getItemProcedimentoHospitalar()\r\n\t\t\t\t\t\t.getQuantDiasFaturamento();\t\t\t\t\t\t\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t\tdiasPermanenciaMaior = prescricao.getAtendimento()\r\n\t\t\t\t\t.getInternacao().getItemProcedimentoHospitalar()\r\n\t\t\t\t\t.getDiasPermanenciaMaior();\t\t\t\t\t\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\tif (diasPermanenciaMaior == null || diasPermanenciaMaior > 0){\r\n\t\t\t\t\r\n\t\t\t\tInteger adicionalDias = 0;\r\n\t\t\t\tif (quantidadeDiasFaturamento != null) {\r\n\t\t\t\t\tadicionalDias = (quantidadeDiasFaturamento * 2) + 1;\r\n\t\t\t\t}\r\n\t\t\t\t\r\n\t\t\t\tif (DateUtil.validaDataTruncadaMaiorIgual(new Date(), DateUtil\r\n\t\t\t\t\t\t.adicionaDias(prescricao.getAtendimento().getInternacao()\r\n\t\t\t\t\t\t\t\t.getDthrInternacao(), adicionalDias))) {\r\n\t\t\t\t\t\r\n\t\t\t\t\tif (this.getMpmLaudoDAO()\r\n\t\t\t\t\t\t\t.obterCountLaudosPorTipoEAtendimento(\r\n\t\t\t\t\t\t\t\t\tprescricao.getAtendimento(),\r\n\t\t\t\t\t\t\t\t\ttipoLaudoMaiorPermanencia) <= 0) {\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\tMpmLaudo laudo = new MpmLaudo();\r\n\t\t\t\t\t\tlaudo.setDthrInicioValidade(prescricao.getAtendimento()\r\n\t\t\t\t\t\t\t\t.getInternacao().getDthrInternacao());\r\n\t\t\t\t\t\tlaudo.setContaDesdobrada(false);\r\n\t\t\t\t\t\tlaudo.setImpresso(false);\r\n\t\t\t\t\t\tlaudo.setLaudoManual(false);\r\n\t\t\t\t\t\tlaudo.setAtendimento(prescricao.getAtendimento());\r\n\t\t\t\t\t\tlaudo.setTipoLaudo(tipoLaudoMaiorPermanencia);\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\tlaudoList.add(laudo);\r\n\t\t\t\t\t\t\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}", "public interface CausalAprobacionDevolucionCommon\n{\n\t/** Propiedad autorizar ingreso secuencias. */\n\tpublic final long AUTORIZAR_INGRESO_SECUENCIAS = 9L;\n\n\t/** Propiedad devolucion aprobador. */\n\tpublic final long DEVOLUCION_APROBADOR = 4L;\n\n\t/** Propiedad devolver al analista de restitucion de turno. */\n\tpublic final long DEVOLVER_AL_ANALISTA_DE_RESTITUCION_DE_TURNO = 11L;\n\n\t/** Propiedad devolver a analisis de desistimiento. */\n\tpublic final long DEVOLVER_A_ANALISIS_DE_DESISTIMIENTO = 8L;\n\n\t/** Propiedad devolver con observacion copias. */\n\tpublic final long DEVOLVER_CON_OBSERVACION_COPIAS = 113L;\n\n\t/** Propiedad devolver con solicitud copias. */\n\tpublic final long DEVOLVER_CON_SOLICITUD_COPIAS = 114L;\n\n\t/** Propiedad DEVOLVER_ETAPA_ANTERIOR_410. */\n\tpublic final long DEVOLVER_ETAPA_ANTERIOR_410 = 124L;\n\n\t/** Propiedad DEVOLVER_ETAPA_ANTERIOR_415. */\n\tpublic final long DEVOLVER_ETAPA_ANTERIOR_415 = 123L;\n\n\t/** Propiedad DEVOLVER_ETAPA_ANTERIOR_420. */\n\tpublic final long DEVOLVER_ETAPA_ANTERIOR_420 = 122L;\n\n\t/** Propiedad devolver grabacion del folio. */\n\tpublic final long DEVOLVER_GRABACION_DEL_FOLIO = 60L;\n\n\t/** Propiedad devolver negacion al ejecutor. */\n\tpublic final long DEVOLVER_NEGACION_AL_EJECUTOR = 63L;\n\n\t/** Propiedad devolver negacion de la solicitud. */\n\tpublic final long DEVOLVER_NEGACION_DE_LA_SOLICITUD = 58L;\n\n\t/** Propiedad devolver resolucion de grabacion. */\n\tpublic final long DEVOLVER_RESOLUCION_DE_GRABACION = 59L;\n\n\t/** Propiedad error al generar documentos. */\n\tpublic final long ERROR_AL_GENERAR_DOCUMENTOS = 6L;\n\n\t/** Propiedad error datos del turno. */\n\tpublic final long ERROR_DATOS_DEL_TURNO = 7L;\n\n\t/** Propiedad error en la generación del documento. */\n\tpublic final long ERROR_EN_LA_GENERACION_DEL_DOCUMENTO = 61L;\n\n\t/** Propiedad error en la seleccion de la plantilla. */\n\tpublic final long ERROR_EN_LA_SELECCION_DE_LA_PLANTILLA = 62L;\n\n\t/** Propiedad generar nota devolutiva. */\n\tpublic final long GENERAR_NOTA_DEVOLUTIVA = 2L;\n\n\t/** Propiedad inscripcion con observaciones. */\n\tpublic final long INSCRIPCION_CON_OBSERVACIONES = 1L;\n\n\t/** Propiedad inscripcion testamento con observaciones. */\n\tpublic final long INSCRIPCION_TESTAMENTO_CON_OBSERVACIONES = 111L;\n\n\t/** Propiedad modificar oficios o actos administrativos. */\n\tpublic final long MODIFICAR_OFICIOS_O_ACTOS_ADMINISTRATIVOS = 3L;\n\n\t/** Propiedad no autorizar ingreso secuencias. */\n\tpublic final long NO_AUTORIZAR_INGRESO_SECUENCIAS = 10L;\n\n\t/** Propiedad no generar inscripción. */\n\tpublic final long NO_GENERAR_INSCRIPCION = 112L;\n\n\t/** Propiedad reproduccion de constancia. */\n\tpublic final long REPRODUCCION_DE_CONSTANCIA = 12L;\n\n\t/** Propiedad requiere complementacion. */\n\tpublic final long REQUIERE_COMPLEMENTACION = 5L;\n\t\n\t/** Propiedad modificar resolucion. */\n\tpublic final long MODIFICAR_RESOLUCION = 140L;\n\t\n\t/** Propiedad modificar datos en el folio a crear. */\n\tpublic final long MODIFICAR_DATOS_EN_EL_FOLIO_A_CREAR = 171L;\n\t\n\t/** Propiedad negar solicitud. */\n\tpublic final long NEGAR_SOLICITUD = 172L;\n\t\n}", "@Override\r\n\tprotected void initVentajas() {\n\r\n\t}", "public Transportadora() {\r\n super();\r\n this.nif = \"\";\r\n this.raio = 0;\r\n this.precoKm = 0;\r\n this.classificacao = new Classificacao();\r\n this.estaLivre = true;\r\n this.velocidadeMed = 0;\r\n this.kmsTotal = 0;\r\n this.capacidade = 0;\r\n }", "public Map<String, MonthDay> dataFeriadosNacionais(int ano);", "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 }", "private void obtenerGastosDiariosMes() {\n\t\t// Obtenemos las fechas actuales inicial y final\n\t\tCalendar calendar = Calendar.getInstance();\n calendar.setTime(new Date());\n int diaFinalMes = calendar.getActualMaximum(Calendar.DAY_OF_MONTH);\n\n\t\tList<Movimiento> movimientos = this.movimientoService.obtenerMovimientosFechaUsuario(idUsuario, LocalDate.of(LocalDate.now().getYear(),LocalDate.now().getMonthValue(),1),\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tLocalDate.of(LocalDate.now().getYear(),LocalDate.now().getMonthValue(), diaFinalMes));\n\t\tList<Double> listaGastos = new ArrayList<Double>();\n\t\tList<String> listaFechas = new ArrayList<String>();\n\t\t\n\t\tDate fechaUtilizadaActual = null;\n\t\tdouble gastoDiario = 0;\n\t\t\n\t\tfor (Iterator iterator = movimientos.iterator(); iterator.hasNext();) {\n\t\t\tMovimiento movimiento = (Movimiento) iterator.next();\n\t\t\tif(fechaUtilizadaActual == null) { //Comprobamos si se acaba de entrar en el bucle para inicializar la fecha del movimiento\n\t\t\t\tfechaUtilizadaActual = movimiento.getFecha();\t\t\n\t\t\t}\n\t\t\t\n\t\t\t// Si hemos cambiado de fecha del movimiento se procede a guardar los datos recogidos\n\t\t\tif(!fechaUtilizadaActual.equals(movimiento.getFecha())) {\n\t\t\t\tlistaGastos.add(gastoDiario);\n\t\t\t\tlistaFechas.add(fechaUtilizadaActual.getDate()+\"/\"+Utils.getMonthForInt(fechaUtilizadaActual.getMonth()).substring(0, 3));\n\t\t\t\tgastoDiario = 0; // Reiniciamos el contador del gasto\n\t\t\t\tfechaUtilizadaActual = movimiento.getFecha(); // Almacenemos la fecha del nuevo gasto\n\t\t\t}\n\t\t\t\n\t\t\t// Si el movimiento que se ha realizado es un gasto lo sumamos al contador de gasto\n\t\t\tif(movimiento.getTipo().equals(TipoMovimiento.GASTO)) {\n\t\t\t\tgastoDiario += movimiento.getCantidad();\t\t\t\t\t\n\t\t\t}\n\t\t\t\n\t\t\t// Comprobamos si es el ultimo item del iterador y almacenamos sus datos\n\t\t\tif(!iterator.hasNext()) {\n\t\t\t\tlistaGastos.add(gastoDiario);\n\t\t\t\tlistaFechas.add(fechaUtilizadaActual.getDate()+\"/\"+Utils.getMonthForInt(fechaUtilizadaActual.getMonth()).substring(0, 3));\n\t\t\t}\n\t\t\t\n\t\t\t\n\t\t}\n\t\t\n\t\tthis.listadoGastosDiariosDiagrama = new Double[listaGastos.size()];\n\t\tthis.listadoGastosDiariosDiagrama = listaGastos.toArray(this.listadoGastosDiariosDiagrama);\n\t\tthis.fechasDiagrama = new String[listaFechas.size()];\n\t\tthis.fechasDiagrama = listaFechas.toArray(this.fechasDiagrama);\n\t\t\n\t}", "public void generar() throws Exception {\n\t\tAnalizador_Sintactico.salida.generar(\".DATA\", \"genero los datos estaticos para la clase \"+this.nombre);\r\n\t\tAnalizador_Sintactico.salida.generar(\"VT_\"+nombre+\":\",\" \");\r\n\t\t\r\n\t\tboolean esDinamico=false;\r\n\t\t\r\n\t\t//para cada metodo, genero la etiqueta dw al codigo\r\n\t\tfor (EntradaMetodo m: entradaMetodo.values()) {\r\n\t\t\tif (m.getModificador().equals(\"dynamic\")) {\r\n\t\t\t\tAnalizador_Sintactico.salida.gen_DW(\"DW \"+m.getEtiqueta(),\"offset: \"+m.getOffsetMetodo(),m.getOffsetMetodo());\r\n\t\t\t\tesDinamico=true;\r\n\t\t\t}\r\n\t\t}\r\n\t\tAnalizador_Sintactico.salida.agregar_DW();\r\n\t\t\r\n\t\t//si NO hay ningun metodo dinamico -> VT con NOP\r\n\t\tif (! esDinamico)\r\n\t\t\tAnalizador_Sintactico.salida.generar(\"NOP\",\"no hago nada\");\r\n\t\t\r\n\t\t//genero codigo para todos los metodos\r\n\t\tAnalizador_Sintactico.salida.generar(\".CODE\",\"seccion codigo de la clase \"+this.nombre);\r\n\t\t\r\n\t\tList<EntradaPar> listaParams;\r\n\t\tfor(EntradaMetodo m: entradaMetodo.values()) {\r\n\t\t\t//metodo actual es m\r\n\t\t\tAnalizador_Sintactico.TS.setMetodoActual(m);\r\n\t\t\t\r\n\t\t\t//SETEO el offset de sus parametros\r\n\t\t\tlistaParams= m.getEntradaParametros();\r\n\t\t\t\r\n\t\t\tfor(EntradaPar p: listaParams) {\r\n\t\t\t\t//seteo offset de p\r\n\t\t\t\t\r\n\t\t\t\t//si es dinamico m -> offset desde 3\r\n\t\t\t\tif (m.getModificador().equals(\"dynamic\")) {\r\n\t\t\t\t\tp.setOffset((listaParams.size() +4) - p.getUbicacion());\r\n\t\t\t\t}\r\n\t\t\t\telse\r\n\t\t\t\t//si es estatico m -> offset desde 2\r\n\t\t\t\t\tp.setOffset((listaParams.size() +3) - p.getUbicacion());\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t//genero el codigo del cuerpo de ese metodo\r\n\t\t\tm.generar();\r\n\t\t}\t\r\n\t\t\r\n\t\t\r\n\t\t\r\n\t\t//genero codigo para todos los constructores\r\n\t\tfor(EntradaCtor c: entradaCtor.values()) {\r\n\t\t\t//metodo actual es m\r\n\t\t\tAnalizador_Sintactico.TS.setMetodoActual(c);\r\n\t\t\t\r\n\t\t\t//SETEO el offset de sus parametros\r\n\t\t\tlistaParams= c.getEntradaParametros();\r\n\t\t\t\r\n\t\t\tfor(EntradaPar p: listaParams) {\r\n\t\t\t\t//seteo offset de p\r\n\t\t\t\tp.setOffset(listaParams.size() +4 - p.getUbicacion());\t// +4 porque el ctor tiene this\r\n\t\t\t}\t\r\n\t\t\t\r\n\t\t\t//genero el codigo de ese metodo\r\n\t\t\tc.generar();\r\n\t\t}\t\r\n\t}", "public static void main(String[] args) {\r\n\r\n\t\tMinhaCalculadora.operacao = \"somar\"; //Não precisa instanciar o objeto quando o método é STATIC.\r\n\t\t\r\n\t\tSystem.out.println(MinhaCalculadora.soma(1, 2)); //Não precisa instanciar a classe quando o método é STATIC.\r\n\t\t\r\n\t\t//Para ambos os casos só precisa inicializar com o nome da classe. logo será apresentado os atributos e métodos STATIC da classe.\r\n\r\n\t}", "public void Ordenamiento() {\n\n\t}", "public Unidadmedida() {\r\n\t}", "public interface DadosGerais extends IDataStruct {\n \n @Data(size=8)\n IString nmPrograma() ;\n \n @Data(size=50)\n IString dFunlPrg() ;\n \n @Data(size=10)\n IString zInicPrct() ;\n \n @Data(size=8)\n IString hInicPrct() ;\n \n @Data(size=10)\n IString zFimPrct() ;\n \n @Data(size=8)\n IString hFimPrct() ;\n \n @Data(size=50)\n IString xCteuAlig() ;\n \n }", "public Persona() { // constructor sin parámetros\r\n\t\t\r\n\t\tthis.nif = \"44882229Y\";\r\n\t\tthis.nombre=\"Anonimo\";\r\n\t\tthis.sexo = 'F';\r\n\t\tthis.fecha = LocalDate.now();\r\n\t\tthis.altura = 180;\r\n\t\tthis.madre = null;\r\n\t\tthis.padre = null;\r\n\t\tcontador++;\r\n\t}", "public static void pocetniMeni() {\r\n\t\tSystem.out\r\n\t\t\t\t.println(\"***********************************************\\n\"\r\n\t\t\t\t\t\t+ \"Unesite 1 ako zelite vidjeti kalendar(za dati mjesec i godinu)\\n\"\r\n\t\t\t\t\t\t+ \"Unesite 2 za pregled podsjetnika za dati mjesec i godinu\\n\"\r\n\t\t\t\t\t\t+ \"Unesite 3 da pregledate podsjetnik za datu godinu\\n\"\r\n\t\t\t\t\t\t+ \"Unesite 4 ako zelite da pogledate sve podsjetnike!\\n\"\r\n\t\t\t\t\t\t+ \"Unesite 5 ako zelite da upisete neki podsjetnik!\\n\"\r\n\t\t\t\t\t\t+ \":::::::::::::::::::::::::::::::::::::::::::::::\");\r\n\t}", "private RepositorioAtendimentoPublicoHBM() {\r\t}", "public Cotizaciones() throws DatatypeConfigurationException {\r\n initComponents();\r\n this.jDateChooser1.setDateFormatString(\"yyyy-MM-dd\");\r\n this.jDateChooser2.setDateFormatString(\"yyyy-MM-dd\");\r\n \r\n //Escondo la columna que tiene el objeto guardado.\r\n jTable1.getColumnModel().getColumn(4).setMinWidth(0);\r\n jTable1.getColumnModel().getColumn(4).setMaxWidth(0);\r\n jTable1.getColumnModel().getColumn(4).setWidth(0);\r\n DefaultTableCellRenderer Alinear = new DefaultTableCellRenderer();\r\n Alinear.setHorizontalAlignment(SwingConstants.LEFT);\r\n \r\n jTable1.getColumnModel().getColumn(0).setCellRenderer(Alinear);\r\n jTable1.getColumnModel().getColumn(1).setCellRenderer(Alinear);\r\n jTable1.getColumnModel().getColumn(2).setCellRenderer(Alinear);\r\n jTable1.getColumnModel().getColumn(3).setCellRenderer(Alinear);\r\n \r\n }", "public void dataPadrao() {\n Calendar c = Calendar.getInstance();\n SimpleDateFormat s = new SimpleDateFormat(\"dd/MM/yyyy\");\n String dataAtual = s.format(c.getTime());\n c.add(c.MONTH, 1);\n String dataAtualMaisUm = s.format(c.getTime());\n dataInicial.setText(dataAtual);\n dataFinal.setText(dataAtualMaisUm);\n }", "public CalculadoraBasica() {\n initComponents();\n }", "public void crearPeliculaNueva(){\n //Atributos de pelicula\n String titulo;\n String autor;\n Multimedia.FORMATO formato;\n GregorianCalendar anyo;\n double duracion = 0;\n String actorPrincipal;\n String actrizPrincipal;\n\n boolean validado = false;\n\n\n titulo = pedirString( \"titulo\"); // Pido el titulo\n autor = pedirString(\"autor\"); // Pido el autor\n formato = pedirFormato(); // Pido el formato\n anyo = pedirAnyo(); // Pido el anyo\n\n do{\n System.out.println(\"Introduce la duracion:\");\n try {\n duracion = Double.parseDouble(lector.nextLine());\n validado = true;\n\n if(duracion <= 0){\n validado = false;\n System.out.println(\"la duracion no puede ser un numero negativo\");\n }\n }catch (NumberFormatException nfe){\n System.out.println(\"Por favor, introduce un numero.\");\n }\n\n }while(!validado);\n validado = false;\n\n // Pido el actor\n do {\n System.out.println(\"Actor: \");\n actorPrincipal = lector.nextLine();\n validado = titulo.length() > 2;\n if(!validado) {\n System.out.println(\"El actor debe tener almenos 2 caracteres\");\n Lib.pausa();\n }\n } while (!validado);\n\n validado = false;\n\n // Pido la actriz\n do {\n System.out.println(\"Actriz: \");\n actrizPrincipal = lector.nextLine();\n validado = titulo.length() > 2;\n if(!validado) {\n System.out.println(\"La actriz debe tener almenos 2 caracteres\");\n Lib.pausa();\n }\n } while (!validado);\n\n\n // Finalmente creo la pelicula y lo anyado a las peliculas de la tienda.\n tienda.getPeliculas().add(new Pelicula(titulo, autor, formato, anyo, duracion, actorPrincipal, actrizPrincipal));\n System.out.println(\"Pelicula creado con exito\");\n Lib.pausa();\n\n }", "public static void init()\n\t{\n\t\t\n\t\tu.creerGalaxie(\"VoieLactee\", \"spirale\", 0);\n\t\tu.creerEtoile(\"Soleil\", 0, 'F', u.getGalaxie(\"VoieLactee\")); //1\n\t\tu.creerObjetFroid(\"Terre\", 150000 , 13000 , 365 , u.getObjet(1)); //2\n\n\t\tu.creerObjetFroid(\"Lune\", 200 , 5000 , 30 , u.getObjet(2)); //3\n\n\t\tu.creerObjetFroid(\"Mars\", 200000 , 11000 , 750 , u.getObjet(1)); //4\n\n\t\tu.creerObjetFroid(\"Phobos\", 150 , 500 , 40 , u.getObjet(4)); //5\n\n\t\tu.creerObjetFroid(\"Pluton\", 1200000 , 4000 , 900 , u.getObjet(1)); //6\n\n\t\tu.creerEtoile(\"Sirius\", 2, 'B', u.getGalaxie(\"VoieLactee\")); //7\n\n\t\tu.creerObjetFroid(\"BIG-1\", 1000 , 50000 , 333 , u.getObjet(7)); //8\n\n\t\tu.creerGalaxie(\"M31\", \"lenticulaire\", 900000);\n\t\tu.creerEtoile(\"XS67\", 8, 'F', u.getGalaxie(\"M31\")); //9\n\t\tu.creerObjetFroid(\"XP88\", 160000 , 40000 , 400 , u.getObjet(9)); //10\n\t}", "public void ordenaPontos(){\r\n\t\tloja.ordenaPontos();\r\n\t}", "Polo(ArrayList<Integer> valoresConfig)\n {\n flagsDesastres = new ArrayList();\n for (int d = 0; d < numCatastrofes; d++) //< Modificar al añadir desastres\n {\n flagsDesastres.add(false);\n }\n dia = 1;\n animales = new ArrayList();\n extintos = new ArrayList();\n for (int i = 0; i < 6; i++) //ID 0 reservado para el krill, no son objetos, pero si objetivos de comida\n {\n animales.add(new ArrayList());\n extintos.add(false);\n }\n SerVivo.IniciaCantidad();\n int randNum = Utilidades.rand(valoresConfig.get(0), valoresConfig.get(1));\n krill = randNum;\n randNum = Utilidades.rand(valoresConfig.get(2), valoresConfig.get(3));\n for (int i = 0; i < randNum; i++) {\n animales.get(1).add(new Pez(0, dia, 0));\n }\n randNum = Utilidades.rand(valoresConfig.get(4), valoresConfig.get(5));\n for (int i = 0; i < randNum; i++) {\n animales.get(2).add(new Foca(0, dia));\n }\n randNum = Utilidades.rand(valoresConfig.get(8), valoresConfig.get(9));\n for (int i = 0; i < randNum; i++) {\n animales.get(3).add(new Oso(0, dia));\n }\n randNum = Utilidades.rand(valoresConfig.get(6), valoresConfig.get(7));\n for (int i = 0; i < randNum; i++) {\n animales.get(4).add(new Morsa(0, dia));\n }\n\n randNum = Utilidades.rand(valoresConfig.get(10), valoresConfig.get(11));\n for (int i = 0; i < randNum; i++) {\n animales.get(5).add(new Esquimal(0, dia));\n }\n temperatura = valoresConfig.get(12);\n\n for (int i = 1; i < 6; i++) {\n animales.set(i, Utilidades.RadixSortIMC(animales.get(i)));\n }\n System.out.println(krill + \",\" + animales.get(1).size() + \",\" + animales.get(2).size() + \",\" + animales.get(3).size() + \",\" + animales.get(4).size() + \",\" + animales.get(5).size());\n }", "public IJoueur quiEstMonMaitre();", "@Override\n public String cualquierMetodo2() {\n return \"Método implementado en la clase hija viaje de incentivo\";\n }", "public static void main(String[] args) throws ParseException {\t\t\n\t int mes, ano, diaDaSemana, primeiroDiaDoMes, numeroDeSemana = 1;\n\t Date data;\n\t \n\t //Converter texto em data e data em texto\n\t SimpleDateFormat sdf\t = new SimpleDateFormat(\"dd/MM/yyyy\");\n\t //Prover o calendario\n\t GregorianCalendar gc\t = new GregorianCalendar();\n\t \n\t String mesesCalendario[] = new String[12];\n\t\tString mesesNome[]\t\t = {\"Janeiro\", \"Fevereiro\", \"Marco\", \"Abri\", \"Maio\", \"Junho\", \"Julho\", \"Agosto\", \"Setembro\", \"Outubro\", \"Novembro\", \"Dezembro\"};\n\t\tint mesesDia[]\t\t\t = {31,28,31,30,31,30,31,31,30,31,30,31};\n\t\t\n\t\t//Errado? e pra receber apenas o \"dia da semana\" do \"primeiro dia do mes\" na questao\n\t //Recebendo mes e ano\n\t mes = Entrada.Int(\"Digite o mes:\", \"Entrada de dados\");\n\t ano = Entrada.Int(\"Digite o ano:\", \"Entrada de dados\");\n\t \n\t //Errado? e pra ser o dia inicial do mes na questao\n\t // Dia inicial do ano\n data = sdf.parse(\"01/01/\" + ano);\n gc.setTime(data);\n diaDaSemana = gc.get(GregorianCalendar.DAY_OF_WEEK);\n \n //Nao sei se e necessario por causa da questao\n //*Alteracao feita||| Ano bissexto tem +1 dia em fevereiro\n if(ano % 4 == 0) {\n \tmesesDia[1] = 29;\n \tmesesNome[1] = \"Ano Bissexto - Fevereiro\";\n }\n \n \n //Meses \n for(int mesAtual = 0; mesAtual < 12; mesAtual++) {\n\t int diasDoMes\t= 0;\n\t String nomeMesAtual = \"\";\n\n\n\t nomeMesAtual = mesesNome[mesAtual]; \n diasDoMes\t = mesesDia[mesAtual]; \n\n\n mesesCalendario[mesAtual] = \"\\n \" + nomeMesAtual + \" de \" + ano + \"\\n\";\n mesesCalendario[mesAtual] += \"---------------------------------------------------------------------|\\n\";\n mesesCalendario[mesAtual] += \" Dom Seg Ter Qua Qui Sex Sab | Semanas\\n\";\n mesesCalendario[mesAtual] += \"---------------------------------------------------------------------|\\n \";\n\t\n\t \n\t // Primeira semana comeca em\n\t data = sdf.parse( \"01/\" + (mesAtual+1) + \"/\" + ano );\n gc.setTime(data);\n primeiroDiaDoMes = gc.get(GregorianCalendar.DAY_OF_WEEK);\n\t for (int space = 1; space < primeiroDiaDoMes; space++) {\n\t \tmesesCalendario[mesAtual] += \" \";\n\t }\n\t \n\t //Dias\t \n\t for (int diaAtual = 1; diaAtual <= diasDoMes; diaAtual++)\n\t {\n\t \t// Trata espaco do dia\n\t \t\t//Transforma o diaAtuel em String\n\t String diaTratado = Integer.toString(diaAtual);\n\t if (diaTratado.length() == 1)\n\t \tdiaTratado = \" \" + diaAtual + \" \";\n\t else\n\t \tdiaTratado = \" \" + diaAtual + \" \";\n\t \n\t // dia\n\t mesesCalendario[mesAtual] += diaTratado;\n\t \t\n\t \t// Pula Linha no final da semana\n\t data = sdf.parse( diaAtual + \"/\" + (mesAtual+1) + \"/\" + ano );\n\t gc.setTime(data);\n\t diaDaSemana = gc.get(GregorianCalendar.DAY_OF_WEEK);\n\t if (diaDaSemana == 7) {\n\t \tmesesCalendario[mesAtual] += (\"| \" + numeroDeSemana++);\n\t \tmesesCalendario[mesAtual] += \"\\n |\";\n\t \tmesesCalendario[mesAtual] += \"\\n \";\n\t }\n\t }\n\t mesesCalendario[mesAtual] += \"\\n\\n\\n\\n\";\n\t }\n\t \n //Imprime mes desejado\n\t System.out.println(mesesCalendario[mes-1]);\n\n\t}", "private void gerarLaudosProcedimentosMateriais(\r\n\t\t\tMpmPrescricaoMedica prescricao, List<MpmLaudo> laudoList) throws ApplicationBusinessException {\r\n\r\n\t\tMap<MpmPrescricaoProcedimento, FatProcedHospInternos> procedimentosMap = this\r\n\t\t\t\t.getConfirmarPrescricaoMedicaRN()\r\n\t\t\t\t.listarProcedimentosGeracaoLaudos(prescricao);\r\n\r\n\t\tMpmLaudo laudo = null;\r\n\r\n\t\tfor (MpmPrescricaoProcedimento procedimento : procedimentosMap.keySet()) {\r\n\t\t\tlaudo = new MpmLaudo();\r\n\t\t\tlaudo.setDthrInicioValidade(prescricao.getDthrInicio());\r\n\r\n\t\t\tDate dataFimValidade = prescricao.getDthrInicio();\r\n\t\t\tif (procedimento.getDuracaoTratamentoSolicitado() != null) {\r\n\t\t\t\tdataFimValidade = DateUtil.adicionaDias(dataFimValidade,\r\n\t\t\t\t\t\tprocedimento.getDuracaoTratamentoSolicitado()\r\n\t\t\t\t\t\t\t\t.intValue() - 1);\r\n\t\t\t}\r\n\t\t\tlaudo.setDthrFimValidade(dataFimValidade);\r\n\t\t\tlaudo.setDthrFimPrevisao(dataFimValidade);\r\n\r\n\t\t\tlaudo.setJustificativa(procedimento.getJustificativa());\r\n\t\t\tlaudo.setContaDesdobrada(false);\r\n\t\t\tlaudo.setImpresso(false);\r\n\t\t\tlaudo.setDuracaoTratSolicitado(procedimento\r\n\t\t\t\t\t.getDuracaoTratamentoSolicitado());\r\n\t\t\tlaudo.setLaudoManual(false);\r\n\t\t\tlaudo.setAtendimento(prescricao.getAtendimento());\r\n\t\t\tlaudo.setPrescricaoProcedimento(procedimento);\r\n\t\t\tlaudo.setProcedimentoHospitalarInterno(procedimentosMap\r\n\t\t\t\t\t.get(procedimento));\r\n\r\n\t\t\tthis.adicionarLaudoLista(laudoList, laudo);\r\n\r\n\t\t}\r\n\r\n\t}", "public String Dime_datos_generales() {\n\t\t\n\t\treturn \"la plataforma del veiculo tiene \"+ rueda+\" ruedas\"+\n\t\t\"\\nmide \"+ largo/1000+\" metros con un ancho de \"+ancho+\n\t\t\"cm\"+\"\\nun peso de platafrorma de \"+peso;\n\t}", "@Override // Métodos que fazem a anulação\n\tpublic void getBonificação() {\n\t\t\n\t}", "public Listas_simplemente_enlazada(){\r\n inicio=null; // este constructor me va servir para apuntar el elemento\r\n fin=null;\r\n }", "public void AddNroCitasRealizadas() {\n\t\tthis.NroCitasRealizadas = this.NroCitasRealizadas+1;\n\t}", "public void inizializza() {\n Navigatore nav;\n Portale portale;\n\n super.inizializza();\n\n try { // prova ad eseguire il codice\n\n Modulo modulo = getModuloRisultati();\n modulo.inizializza();\n// Campo campo = modulo.getCampoChiave();\n// campo.setVisibileVistaDefault(false);\n// campo.setPresenteScheda(false);\n// Vista vista = modulo.getVistaDefault();\n// vista.getElement\n// Campo campo = vista.getCampo(modulo.getCampoChiave());\n\n\n\n /* aggiunge il Portale Navigatore al pannello placeholder */\n nav = this.getNavigatore();\n portale = nav.getPortaleNavigatore();\n this.getPanNavigatore().add(portale);\n\n } catch (Exception unErrore) { // intercetta l'errore\n Errore.crea(unErrore);\n }// fine del blocco try-catch\n\n }", "@Override\n public void cantidad_Defensa(){\n defensa=2+nivel+aumentoD;\n }", "public FrecuenciaPorSemana(){\n super(new Hora(0,0));\n dias = new boolean[7];\n for (int i = 0;i<7;i++)\n dias[i] = true;\n }", "public void limpiarMemoria();", "public interface NotificadorPelicula {\r\n public void notificar(Categoria categoria, int posicion);\r\n public void abrirGrilla(Categoria categoria);\r\n public void solicituddeActualizarDatosFragmentsPelicula(Pelicula pelicula);\r\n\r\n }", "public DAOPedidoMesa() {\n\t\trecursos = new ArrayList<Object>();\n\t}", "public Summalista()\r\n\t{\r\n\t\tthis.summa = 0;\r\n\t\tthis.alkiot = 0;\r\n\t}", "public static void main(String[] args) {\n\t\t\r\n\tString nombre = leerTexto(\"Ingrese un nombre:\");\r\n\tint edad = leerNumero(\"Ingrese su edad:\");\r\n\tString rut = leerTexto(\"Ingresa el RUT:\");\r\n\tchar genero = leerTexto(\"Ingresa el genero: (M/F/O)\").charAt(0);\r\n\tfloat peso = leerNumero(\"Ingrese peso:\");\r\n\tfloat altura = leerNumero(\"Ingrese la altura:\");\r\n\tPersona claudia = new Persona(nombre, rut, edad, genero, peso, altura);\r\n\t\r\n\tnombre = leerTexto(\"Ingrese un nombre:\");\r\n\tedad = leerNumero(\"Ingrese su edad:\");\r\n\trut = leerTexto(\"Ingresa el RUT:\");\r\n\tgenero = leerTexto(\"Ingresa el genero: (M/F/O)\").charAt(0);\r\n\tPersona juliano = new Persona(nombre, rut, edad, genero);\r\n\t\r\n\tPersona noelia = new Persona();\r\n\tnoelia.setNombre(leerTexto(\"Ingresa un nombre\"));\r\n\tnoelia.setEdad(leerNumero(\"Ingresa la edad\"));\r\n\tnoelia.setRut(leerTexto(\"Ingresa el RUT\"));\r\n\tnoelia.setGenero(leerTexto(\"Ingresa el genero\").charAt(0));\r\n\tnoelia.setAltura(leerNumero(\"Ingresa la altura\"));\r\n\tnoelia.setPeso(leerNumero(\"Ingresa el peso\"));\r\n\t\r\n\tPersona[] perso = new Persona[3];\r\n\tperso[0] = claudia;\r\n\tperso[1] = juliano;\r\n\tperso[2] = noelia;\r\n\t\r\n\tfor (Persona persona : perso) {\r\n\t\tif (persona.calcularIMC()==Persona.PESO_BAJO) {\r\n\t\t\tescribir(\"Pongale sus buenas cazuelas\");\r\n\t\t}else {\r\n\t\t\tif (persona.calcularIMC()==Persona.PESO_IDEAL) {\r\n\t\t\t\tescribir(\"Estamos tiki taka\");\r\n\t\t\t}else {\r\n\t\t\t\tescribir(\"Menos coffe break!\");\r\n\t\t\t}\r\n\t\t}\r\n\t\t//Mayor de edad\r\n\t\tescribir(\"La persona \" + persona.getNombre() + \" es mayor de edad? \" + persona.esMayorDeEdad());\r\n\t\t//Mostrar el toString()\r\n\t\tescribir(persona.toString());\r\n\t }\r\n\t}", "public MovimientoPantallaCocina() {\n initComponents();\n \n //COLOCAR FONOD EN LA PANTALLA PARA LA COCINA\n try{\n pnlOrdenes.setBorder(new ImagenCocina());\n } catch (IOException e){\n Logger.getLogger(MovimientoPantallaCocina.class.getName()).log(Level.SEVERE, null, e);\n }\n \n //VISUALIZAR TODAS LAS ORDENES ACTIVAS\n hilo p = new hilo(\"ordenes\");\n p.start();\n }", "public Controlador() {\n\t\t// m\n\t\tdatosPrueba1 = new ListaEnlazada();\n\t\t// m\n\t\tdatosPrueba2 = new ListaEnlazada();\n\t\t// add\n\t\tdatosPrueba3 = new ListaEnlazada();\n\t\tdatosPrueba4 = new ListaEnlazada();\n\t\tprueba1 = new Estadisticas(datosPrueba1);\n\t\tprueba2 = new Estadisticas(datosPrueba2);\n\t\tprueba3 = new Estadisticas(datosPrueba3);\n\t\tprueba4 = new Estadisticas(datosPrueba4);\n\t\t// finAdd\n\t}", "Vaisseau_longueur createVaisseau_longueur();", "public static void instanciarCreencias() {\n\t\tfor(int i =0; i < GestorPartida.getContJugadores(); i++) {\n\t\t\t\n\t\t\tGestorPartida.jugadores[i].setCreencias(new Creencias(GestorPartida.jugadores, GestorPartida.objetoJugador, GestorPartida.objetoSala, i)); \n\t\t}\n\t}", "public vistaAlojamientos() {\n initComponents();\n \n try {\n miConn = new Conexion(\"jdbc:mysql://localhost/turismo\", \"root\", \"\");\n ad = new alojamientoData(miConn);\n \n } catch (ClassNotFoundException ex) {\n Logger.getLogger(vistaAlojamientos.class.getName()).log(Level.SEVERE, null, ex);\n }\n \n \n }", "public void listadoNotaMediaAlumnos() {\r\n\t\tint acumulador;\r\n\t\tfor(int i=0; i<notasAlumnos.length; i++) {\r\n\t\t\tacumulador = 0;\r\n\t\t\tfor(int j=0; j<notasAlumnos[i].length; j++) {\r\n\t\t\t\tacumulador += notasAlumnos[i][j];\r\n\t\t\t}\r\n\t\t\tSystem.out.println(alumnos[i] + \": \" + acumulador + \" de Nota Media.\");\r\n\t\t}\r\n\t}", "private void reposicionarPersonajes() {\n // TODO implement here\n }", "private UsineJoueur() {}", "public Parametros() {\r\n semilla = SEMILLA_DEFECTO;\r\n numeroPistas = NUMERO_PISTAS_DEFECTO;\r\n duracionSlot = DURACION_SLOT_DEFECTO;\r\n frecuencia = FRECUENCIA_DEFECTO;\r\n duracionMedia = DURACION_MEDIA_DEFECTO;\r\n duracionDesviacion = DURACION_DESVIACION_DEFECTO;\r\n duracionMinima = DURACION_MINIMA_DEFECTO;\r\n demoraMedia = DEMORA_MEDIA_DEFECTO;\r\n demoraDesviacion = DEMORA_DESVIACION_DEFECTO;\r\n }", "@Override\n\tpublic int canalMais() {\n\t\treturn 0;\n\t}", "private void populaHorarioAula()\n {\n Calendar hora = Calendar.getInstance();\n hora.set(Calendar.HOUR_OF_DAY, 18);\n hora.set(Calendar.MINUTE, 0);\n HorarioAula h = new HorarioAula(hora, \"Segunda e Quinta\", 1, 3, 1);\n horarioAulaDAO.insert(h);\n\n hora.set(Calendar.HOUR_OF_DAY, 5);\n h = new HorarioAula(hora, \"Terca e Sexta\", 1, 3, 1);\n horarioAulaDAO.insert(h);\n\n hora.set(Calendar.HOUR_OF_DAY, 15);\n h = new HorarioAula(hora, \"Terca e Sexta\", 2, 5, 3);\n horarioAulaDAO.insert(h);\n\n hora.set(Calendar.HOUR_OF_DAY, 5);\n h = new HorarioAula(hora, \"Terca e Sexta\", 2, 5, 3);\n horarioAulaDAO.insert(h);\n\n hora.set(Calendar.HOUR_OF_DAY, 10);\n h = new HorarioAula(hora, \"Terca e Sexta\", 2, 5, 3);\n horarioAulaDAO.insert(h);\n\n hora.set(Calendar.HOUR_OF_DAY, 5);\n h = new HorarioAula(hora, \"Quarta e Sexta\", 3, 5, 3);\n horarioAulaDAO.insert(h);\n\n hora.set(Calendar.HOUR_OF_DAY, 5);\n h = new HorarioAula(hora, \"Sexta\", 1, 1, 2);\n horarioAulaDAO.insert(h);\n\n hora.set(Calendar.HOUR_OF_DAY, 19);\n h = new HorarioAula(hora, \"Sexta\", 2, 1, 1);\n horarioAulaDAO.insert(h);\n\n hora.set(Calendar.HOUR_OF_DAY, 5);\n h = new HorarioAula(hora, \"Segunda\", 3, 6, 4);\n horarioAulaDAO.insert(h);\n\n }", "private void cargarNotasAclaratorias() {\r\n\t\tMap<String, Object> parametros = new HashMap<String, Object>();\r\n\t\tparametros.put(\"nro_identificacion\",\r\n\t\t\t\tadmision_seleccionada.getNro_identificacion());\r\n\t\tparametros.put(\"nro_ingreso\", admision_seleccionada.getNro_ingreso());\r\n\t\tparametros.put(\"estado\", admision_seleccionada.getEstado());\r\n\t\tparametros.put(\"codigo_administradora\",\r\n\t\t\t\tadmision_seleccionada.getCodigo_administradora());\r\n\t\tparametros.put(\"id_plan\", admision_seleccionada.getId_plan());\r\n\t\tparametros.put(\"tipo_hc\", \"\");\r\n\t\tparametros.put(\"tipo\", INotas.NOTAS_ACLARATORIAS);\r\n\t\ttabboxContendor\r\n\t\t\t\t.abrirPaginaTabDemanda(false, \"/pages/nota_aclaratoria.zul\",\r\n\t\t\t\t\t\t\"NOTAS ACLARATORIAS\", parametros);\r\n\t}", "private DittaAutonoleggio(){\n \n }", "private void iniciar() {\r\n\t\t/*Se instancian las clases*/\r\n\t\tmiVentanaPrincipal=new VentanaPrincipal();\r\n\t\tmiVentanaRegistro=new VentanaRegistro();\r\n\t\tmiVentanaBuscar= new VentanaBuscar();\r\n\t\tmiLogica=new Logica();\r\n\t\tmiCoordinador= new Coordinador();\r\n\t\t\r\n\t\t/*Se establecen las relaciones entre clases*/\r\n\t\tmiVentanaPrincipal.setCoordinador(miCoordinador);\r\n\t\tmiVentanaRegistro.setCoordinador(miCoordinador);\r\n\t\tmiVentanaBuscar.setCoordinador(miCoordinador);\r\n\t\tmiLogica.setCoordinador(miCoordinador);\r\n\t\t\r\n\t\t/*Se establecen relaciones con la clase coordinador*/\r\n\t\tmiCoordinador.setMiVentanaPrincipal(miVentanaPrincipal);\r\n\t\tmiCoordinador.setMiVentanaRegistro(miVentanaRegistro);\r\n\t\tmiCoordinador.setMiVentanaBuscar(miVentanaBuscar);\r\n\t\tmiCoordinador.setMiLogica(miLogica);\r\n\t\t\t\t\r\n\t\tmiVentanaPrincipal.setVisible(true);\r\n\t}", "private void creaModuloMem() {\n /* variabili e costanti locali di lavoro */\n ArrayList<Campo> campi = new ArrayList<Campo>();\n ModuloRisultati modulo;\n Campo campo;\n\n try { // prova ad eseguire il codice\n\n campo = CampoFactory.intero(Campi.Ris.codicePiatto.getNome());\n campi.add(campo);\n\n campo = CampoFactory.testo(Campi.Ris.nomePiatto.getNome());\n campo.setVisibileVistaDefault();\n campo.setTitoloColonna(\"piatto\");\n campo.setToolTipLista(\"nome del piatto\");\n campo.decora()\n .etichetta(\"nome del piatto\"); // le etichette servono per il dialogo ricerca\n campo.setLarghezza(250);\n campi.add(campo);\n\n campo = CampoFactory.testo(Campi.Ris.categoria.getNome());\n campo.setVisibileVistaDefault();\n campo.setTitoloColonna(\"categoria\");\n campo.setToolTipLista(\"categoria del piatto\");\n campo.setLarghezza(80);\n campi.add(campo);\n\n campo = CampoFactory.intero(Campi.Ris.quanteVolte.getNome());\n campo.setVisibileVistaDefault();\n campo.setLarghezza(80);\n campo.setTitoloColonna(\"quante volte\");\n campo.setToolTipLista(\n \"quante volte questo piatto è stato offerto nel periodo analizzato\");\n campo.decora().etichetta(\"quante volte\");\n campi.add(campo);\n\n campo = CampoFactory.intero(Campi.Ris.quantiCoperti.getNome());\n campo.setVisibileVistaDefault();\n campo.setTitoloColonna(\"coperti\");\n campo.setToolTipLista(\"numero di coperti che avrebbero potuto ordinare\");\n campo.decora().etichetta(\"n. coperti\");\n campo.setLarghezza(80);\n campi.add(campo);\n\n campo = CampoFactory.intero(Campi.Ris.quanteComande.getNome());\n campo.setVisibileVistaDefault();\n campo.setTitoloColonna(\"comande\");\n campo.setToolTipLista(\"numero di comande effettive\");\n campo.decora().etichetta(\"n. comande\");\n campo.setLarghezza(80);\n campo.setTotalizzabile(true);\n campi.add(campo);\n\n campo = CampoFactory.percentuale(Campi.Ris.gradimento.getNome());\n campo.setVisibileVistaDefault();\n campo.setTitoloColonna(\"gradimento\");\n campo.setToolTipLista(\n \"percentuale di gradimento (è il 100% se tutti i coperti potenziali lo hanno ordinato)\");\n campo.decora().etichetta(\"% gradimento\");\n campo.setLarghezza(80);\n campi.add(campo);\n\n modulo = new ModuloRisultati(campi);\n setModuloRisultati(modulo);\n\n\n } catch (Exception unErrore) { // intercetta l'errore\n Errore.crea(unErrore);\n } // fine del blocco try-catch\n\n }", "@Override\n public void crearReloj() {\n Manecilla seg;\n seg = new Manecilla(40,60,0,1,null);\n cronometro = new Reloj(seg);\n }", "void mo1507n();", "@Override\n\tpublic DAOIncidencias CrearInformesMedicos() {\n\t\treturn null;\n\t}", "public ManipularEstudiantes() {\n initComponents();\n cme = new Control_Mantenimiento_Estudiante(this);\n this.gUI_botones2.agregar_eventos(cme);\n }", "MaquinaCafetera(){\n }", "public void tipoDatos() {\n\t\tint num = 10;\n\t\t// Texto STring\n\t\tString cadena = \"cadena\";\n\n\t\t// Decimale O flotante\n\t\tdouble decimal = 12.16;\n\t\tfloat fl = new Float(10);\n\t\t// Bolean\n\t\tboolean bl = true;\n\n\t\t// ARREGLOS\n\t\t// string\n\t\tString[] veString = new String[5];\n\t\tveString[0] = \"hola mundo\";\n\t\tveString[1] = \"hola mundo\";\n\t\tveString[2] = \"hola mundo\";\n\t\tveString[3] = \"hola mundo\";\n\t\tveString[4] = \"hola mundo\";\n\n\t\tint[] varNum = new int[] { 0, 1, 2, 3, 4, 5 };\n\n\t}", "@Override\n\tpublic double netoAnual(double precio) {\n\t\treturn this.precio * 12;\n\t}", "private void gerarLaudosProcedimentosCirurgicos(\r\n\t\t\tMpmPrescricaoMedica prescricao, List<MpmLaudo> laudoList) throws ApplicationBusinessException {\r\n\r\n\t\tMap<MpmPrescricaoProcedimento, FatProcedHospInternos> procedimentosMap = this\r\n\t\t\t\t.getConfirmarPrescricaoMedicaRN()\r\n\t\t\t\t.listarProcedimentosCirurgicosGeracaoLaudos(prescricao);\r\n\r\n\t\tMpmLaudo laudo = null;\r\n\r\n\t\tfor (MpmPrescricaoProcedimento procedimento : procedimentosMap.keySet()) {\r\n\r\n\t\t\tlaudo = new MpmLaudo();\r\n\t\t\tlaudo.setDthrInicioValidade(prescricao.getDthrInicio());\r\n\r\n\t\t\tDate dataFimValidade = prescricao.getDthrInicio();\r\n\t\t\tif (procedimento.getDuracaoTratamentoSolicitado() != null) {\r\n\t\t\t\tdataFimValidade = DateUtil.adicionaDias(dataFimValidade,\r\n\t\t\t\t\t\tprocedimento.getDuracaoTratamentoSolicitado()\r\n\t\t\t\t\t\t\t\t.intValue() - 1);\r\n\t\t\t}\r\n\t\t\tlaudo.setDthrFimValidade(dataFimValidade);\r\n\t\t\tlaudo.setDthrFimPrevisao(dataFimValidade);\r\n\r\n\t\t\tlaudo.setJustificativa(procedimento.getJustificativa());\r\n\t\t\tlaudo.setContaDesdobrada(false);\r\n\t\t\tlaudo.setImpresso(false);\r\n\t\t\tlaudo.setDuracaoTratSolicitado(procedimento\r\n\t\t\t\t\t.getDuracaoTratamentoSolicitado());\r\n\t\t\tlaudo.setLaudoManual(false);\r\n\t\t\tlaudo.setAtendimento(prescricao.getAtendimento());\r\n\t\t\tlaudo.setPrescricaoProcedimento(procedimento);\r\n\t\t\tlaudo.setProcedimentoHospitalarInterno(procedimentosMap\r\n\t\t\t\t\t.get(procedimento));\r\n\r\n\t\t\tthis.adicionarLaudoLista(laudoList, laudo);\r\n\r\n\t\t}\r\n\r\n\t}", "public FiltroMicrorregiao() {\r\n }", "@Override\npublic String toString() {// PARA MOSTRAR LOS DATOS DE ESTA CLASE\n// TODO Auto-generated method stub\nreturn MuestraCualquiera();\n}", "public Jogador(int nLinhas, int nCols, List<Par<Integer,Integer>> obstaculos) {\n\t\tthis.ambiente = new Ambiente(nLinhas, nCols, obstaculos);\n\t\tthis.pontuacao = 0;\n\t}", "public listaAlumnos()\r\n\t{\r\n\t\tinicio = fin = null; \r\n\t}", "@Override\n\tpublic void crearNuevaPoblacion() {\n\t\t/* Nos quedamos con los mejores individuos. Del resto, cruzamos la mitad, los mejores,\n\t\t * y el resto los borramos.*/\n\t\tList<IIndividuo> poblacion2 = new ArrayList<>();\n\t\tint numFijos = (int) (poblacion.size()/2);\n\t\t/* Incluimos el 50%, los mejores */\n\t\tpoblacion2.addAll(this.poblacion.subList(0, numFijos));\n\t\t\n\t\t/* De los mejores, mezclamos la primera mitad \n\t\t * con todos, juntandolos de forma aleatoria */\n\t\tList<IIndividuo> temp = poblacion.subList(0, numFijos+1);\n\t\tfor(int i = 0; i < temp.size()/2; i++) {\n\t\t\tint j;\n\t\t\tdo {\n\t\t\t\tj = Individuo.aleatNum(0, temp.size()-1);\n\t\t\t}while(j != i);\n\t\t\t\n\t\t\ttry {\n\t\t\t\tpoblacion2.addAll(cruce(temp.get(i), temp.get(j)));\n\t\t\t} catch (CruceNuloException e) {\n\t\t\t\te.printStackTrace();\n\t\t\t}\n\t\t}\n\t\t\n\t\t//this.poblacion.clear();\n\t\tthis.poblacion = poblacion2;\n\t}", "public void limpiar(){\n\t\tfCargaI=new Date();\n\t\tfCargaF=new Date();\n\t\tlistaMarcacion=null;\n\t\tlistaMarcacionPDF=null;\n\t}", "public nomina()\n {\n deducidoClase = new deducido();\n devengadoClase = new devengado();\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}", "@Override\n public void memoria() {\n \n }", "public void prepararDados() {\n\t\tatribuiPrimeiroAnoCasoAnoEstejaNulo();\n\t\t\n\t\tsalvarOuAtualizar(alunosMilitarPraca);\n\t\tsalvarOuAtualizar(alunosMilitarOficial);\n\t\t\n\t\tinit();\n\t\thabilitaBotao=false;\n\t}", "public interface CalculadoraGeneral {\n public String Calculo(String element);\n}", "private Pannello creaPanDate() {\n /* variabili e costanti locali di lavoro */\n Pannello panDate = null;\n Campo campoDataInizio;\n Campo campoDataFine;\n JButton bottone;\n ProgressBar pb;\n\n try { // prova ad eseguire il codice\n\n /* pannello date */\n campoDataInizio = CampoFactory.data(DialogoStatistiche.nomeDataIni);\n campoDataInizio.decora().eliminaEtichetta();\n campoDataInizio.decora().etichettaSinistra(\"dal\");\n campoDataInizio.decora().obbligatorio();\n campoDataFine = CampoFactory.data(DialogoStatistiche.nomeDataFine);\n campoDataFine.decora().eliminaEtichetta();\n campoDataFine.decora().etichettaSinistra(\"al\");\n campoDataFine.decora().obbligatorio();\n\n /* bottone esegui */\n bottone = new JButton(\"Esegui\");\n bottone.setOpaque(false);\n this.setBottoneEsegui(bottone);\n bottone.addActionListener(new DialogoStatistiche.AzioneEsegui());\n bottone.setFocusPainted(false);\n\n /* progress bar */\n pb = new ProgressBar();\n this.setProgressBar(pb);\n\n panDate = PannelloFactory.orizzontale(this.getModulo());\n panDate.setAllineamento(Layout.ALLINEA_CENTRO);\n panDate.creaBordo(\"Periodo di analisi\");\n panDate.add(campoDataInizio);\n panDate.add(campoDataFine);\n panDate.add(bottone);\n panDate.add(Box.createHorizontalGlue());\n panDate.add(pb);\n\n } catch (Exception unErrore) { // intercetta l'errore\n Errore.crea(unErrore);\n } // fine del blocco try-catch\n\n /* valore di ritorno */\n return panDate;\n }", "private static void cajas() {\n\t\t\n\t}", "public Dipendente() {\r\n\t\tsetnMat();\r\n\t}", "public InterfazConsultarCalificaciones() {\n initComponents();\n\n //establece la interfaz de manera central\n this.setLocationRelativeTo(null);\n\n //colocar icono a la interfaz\n setIconImage(new ImageIcon(getClass().getResource(\"/imagenes/icono.png\")).getImage());\n\n //des activa la opcion maximizar \n this.setResizable(false);\n //desactiva la opcion cerrar\n setDefaultCloseOperation(0);\n }", "public interface DateInterface \n{\n /*\n Dada uma data, determina a sua estação do ano (Primavera, Verão, Outono ou Inverno) de acordo com o hemisfério Norte.\n */\n public String estacaoDoAno(LocalDate d);\n \n /*\n Determina o dia da semana do primeiro dia de um ano.\n */\n public DayOfWeek primeiroDiaSemanaAno(int ano);\n \n /*\n Determina o dia da semana de uma data.\n */\n public DayOfWeek diaDaSemana(LocalDate d);\n \n /*\n Determina o dia do ano de uma data (por exemplo, 10/01/2018 corresponde ao 10º dia do ano de 2018).\n */\n public int diaDoAno(LocalDate d);\n \n /*\n Determina em que trimestre do ano uma data se situa.\n */\n public int trimestre(LocalDate d);\n \n /*\n Determina o número de semanas completas entre duas datas, sendo uma delas a atual.\n */\n public long numSemanasAteData(LocalDate d);\n \n /*\n Determina se um ano é bissexto ou não.\n */\n public boolean anoBissexto(Year ano);\n \n /*\n Determina o século, o milénio e a era de uma data.\n */\n public TuploSeculoMilenioEra seculoMilenioEraData(LocalDate d);\n \n /*\n Determina quanto tempo falta até à próxima passagem do cometa Halley. Mostra o resultado em dias totais, meses totais\n e anos totais.\n */\n public ParDataDiaMesAno cometaHalley();\n \n /*\n Determina o número de dias úteis entre duas dadas datas.\n */\n public int diasUteisEntreDatas(LocalDate d1, LocalDate d2);\n \n /*\n Determina quantos fins-de-semanas completos um ano tem. Caso o ano inserido possua um sábado ou um domingo extra, \n estes também são sinalizados.\n */\n public ParFimDeSemana numFinsDeSemanaAno(int ano);\n \n /*\n Determina quantos dias faltam até ao próximo Natal.\n */\n public long diasAteNatal();\n \n /*\n Determina o salário de um indivíduo sabendo quanto ganha por hora e o ano que pretende calcular. Apresenta o resultado\n em dias, semanas, meses e ano.\n */\n public SalarioAno salarioDiaMesSemanaAno(float salarioHora, int ano); \n \n /*\n Determina o número de dias úteis (isto é, que não são fins-de-semana) de um ano.\n */\n public int numDiasUteisAno(int ano);\n \n /*\n Determina em que dias são os fins-de-semana de um dado mês. Por exemplo, em Janeiro de 2018 o primeiro fim-de-semana\n ocorre nos dias 6 (Sábado) e 7 (Domingo).\n */\n public Map<Integer, DayOfWeek> finsDeSemanaDoMes(int ano, int mes);\n \n /*\n A uma dada data são somados anos, meses, semanas e dias.\n */\n public LocalDate somaData(LocalDate d, int ano, int mes, int semanas, int dias);\n \n /*\n A uma dada data são subtraidos anos, meses, semanas e dias.\n */\n public LocalDate subtraiData(LocalDate d, int ano, int mes, int semanas, int dias);\n \n /*\n Dado um número de dias, calcula a data daqui a esse número de dias e apresenta ainda qual o dia da semana e quantos\n dias úteis faltam até lá.\n */\n public TuploDataDia_SemanaDias_Uteis eventoDaquiXDias(int dias);\n \n /*\n Dado um número de dias úteis, calcula a data daqui a esse número de dias e apresenta ainda qual o dia da semana.\n */\n public ParDataDiaDaSemana eventoDaquiXDiasUteis(int dias);\n \n /*\n Determina qual a data da próxima Black Friday e quantos dias faltam até essa data.\n */\n public ParDataDia proxBlackFriday();\n \n /*\n Calcula a data da Páscoa de um determinado ano.\n */\n public LocalDate proxPascoa(int ano);\n \n /*\n Para um dado ano apresenta a data dos feriados nacionais e em que dia da semana ocorrem.\n */\n public Map<String, MonthDay> dataFeriadosNacionais(int ano);\n \n /*\n Calcula a diferença entre duas datas. Apresenta o resultado em anos, meses e dias. Por exemplo, de 01/01/2018 até \n 10/02/2018 existe uma diferença de 0 anos, 1 mês e 9 dias.\n */\n public static TuploAnosMesesDias difEntreDatas(LocalDate d1, LocalDate d2)\n { \n boolean stop = false;\n boolean stop2 = false;\n long dias;\n int meses;\n int anos;\n \n anos = 0;\n meses = 0;\n dias = 0;\n\n while((d1.getYear() != d2.getYear() || d1.getMonthValue() != d2.getMonthValue())&&!stop && !stop2)\n {\n \n \n while(d1.getMonthValue() != d2.getMonthValue() && !stop2)\n {\n if(d1.getYear() == (d2.getYear() - 1) && d1.getMonthValue() == 12 && d2.getMonthValue() == 1 && d2.getDayOfMonth() < d1.getDayOfMonth())\n {\n stop2 = true;\n dias = 31 - d1.getDayOfMonth() + d2.getDayOfMonth();\n }\n if(stop2 == false)\n {\n YearMonth anoMes = YearMonth.of(d1.getYear(), d1.getMonth());\n int daysInMonth = anoMes.lengthOfMonth(); \n\n if(((d2.getYear() - d1.getYear()) == 0) \n &&((d2.getMonthValue() - d1.getMonthValue()) == 1)\n &&(d1.getDayOfMonth() > d2.getDayOfMonth()))\n {\n\n dias = d2.getDayOfMonth() + daysInMonth - d1.getDayOfMonth(); \n stop = true;\n break;\n }\n\n meses++;\n\n d1 = d1.plusMonths(1);\n }\n }\n if(stop2 == false)\n {\n if(d1.getMonthValue() == d2.getMonthValue() && d1.getYear() !=d2.getYear())\n {\n meses++;\n d1 = d1.plusMonths(1);\n }\n }\n }\n \n if(d1.getMonthValue() == d2.getMonthValue())\n {\n dias = d2.getDayOfMonth() - d1.getDayOfMonth();\n }\n\n while(meses > 12)\n {\n anos++;\n meses-=12;\n }\n \n return new TuploAnosMesesDias(anos, meses, dias);\n \n }\n}", "public Nodo(datos libro)\n {\n this.libro=libro;//LA VARIABLE LIBRO TENDRA LOS DATOS DE LA CLASE LIBRO\n }", "public PantallaPrincipal() {\n gestor= new Gestor();\n initComponents();\n inicializarTablaCarreras();\n inicializarTablaCorredorTotales();\n inicializarTablaCorredor();\n mostrarCarreras();\n mostrarCorredoresTotales();\n \n \n }", "public void abrirManoMaximo()\n {\n brazo.manoAbrirMaximo();\n }", "public static void main(String[] args) {\n\t\tElectrodomestico[] electrodomesticos = new Electrodomestico[10];\n\t\t\n\t\telectrodomesticos[0] = new Lavadora();\n\t\telectrodomesticos[1] = new Television(29, true);\n\t\telectrodomesticos[2] = new Television();\n\t\telectrodomesticos[3] = new Electrodomestico((float)1555.8, 20);\n\t\telectrodomesticos[4] = new Lavadora(800, 30);\n\t\telectrodomesticos[5] = new Television(699, 55);\n\t\telectrodomesticos[6] = new Lavadora(2900, 81);\n\t\telectrodomesticos[7] = new Electrodomestico();\n\t\telectrodomesticos[8] = new Electrodomestico(567, \"rojo\", 'a', 78);\n\t\telectrodomesticos[9] = new Lavadora(45);\n\t\t//electrodomesticos[10] = new Television(67, false);\n\t\t\n\t\tint precioT = 0, precioE = 0, precioL = 0;\n\t\t\n\t\tfor (Electrodomestico electrodomestico : electrodomesticos) {\n\t\t\tif(electrodomestico instanceof Television) {\n\t\t\t\telectrodomestico.precioFinal();\n\t\t\t\tSystem.out.println(\"Precio televisor: \" + electrodomestico.getPrecioBase());\n\t\t\t\tprecioT += electrodomestico.getPrecioBase();\n\t\t\t} else if(electrodomestico instanceof Lavadora){\n\t\t\t\telectrodomestico.precioFinal();\n\t\t\t\tSystem.out.println(\"Precio lavadora: \" + electrodomestico.getPrecioBase());\n\t\t\t\tprecioL += electrodomestico.getPrecioBase();\n\t\t\t} else {\n\t\t\t\telectrodomestico.precioFinal();\n\t\t\t\tSystem.out.println(\"Precio electrodomestico: \" + electrodomestico.getPrecioBase());\n\t\t\t\tprecioE += electrodomestico.getPrecioBase();\n\t\t\t}\n\t\t}\n\t\t\n\t\tSystem.out.println(\"\\nTelevisores\\nEl precio total de los televisores es de: \" + precioT);\n\t\tSystem.out.println(\"\\nLavadoras\\nEl precio total de las lavadoras es de: \" + precioL);\n\t\tSystem.out.println(\"\\nElectrodomesticos\\nEl precio total de los electrodomestricos es de: \" + (precioT + precioL + precioE));\n\t}", "private void calculadorNotaFinal() {\n\t\t//calculo notaFinal, media de las notas medias\n\t\tif(this.getAsignaturas() != null) {\n\t\t\t\tfor (Iterator<Asignatura> iterator = this.asignaturas.iterator(); iterator.hasNext();) {\n\t\t\t\t\tAsignatura asignatura = (Asignatura) iterator.next();\n\t\t\t\t\tif(asignatura.getNotas() != null) {\n\t\t\t\t\tnotaFinal += asignatura.notaMedia();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t//curarse en salud con division entre 0\n\t\t\t\tif(this.getAsignaturas().size() != 0) {\n\t\t\t\tnotaFinal /= this.getAsignaturas().size();\n\t\t\t\t}\n\t\t}\n\t}" ]
[ "0.57764703", "0.5774415", "0.5758239", "0.57533354", "0.57175946", "0.5666471", "0.5600488", "0.55881846", "0.5587407", "0.5585635", "0.5566601", "0.55628216", "0.5503012", "0.54799885", "0.5473147", "0.54526645", "0.54422194", "0.5440923", "0.54256", "0.5419093", "0.54141307", "0.5396837", "0.5384878", "0.5363951", "0.5358203", "0.53559184", "0.5352435", "0.5341577", "0.53384566", "0.5337742", "0.531964", "0.5309379", "0.53050417", "0.5296402", "0.52848125", "0.5277307", "0.5272617", "0.52647996", "0.52637404", "0.52631086", "0.52596426", "0.52549016", "0.52547884", "0.5254406", "0.5253392", "0.5252728", "0.5249663", "0.52491945", "0.52459705", "0.5241326", "0.5240674", "0.5239996", "0.52371866", "0.5232277", "0.52319986", "0.5231881", "0.5220295", "0.52184135", "0.5214345", "0.52096117", "0.52064055", "0.5206141", "0.5193775", "0.51929665", "0.51831394", "0.51744986", "0.517129", "0.5168107", "0.51668084", "0.51656693", "0.516449", "0.51642036", "0.51616865", "0.515533", "0.51496893", "0.514842", "0.5148181", "0.5141511", "0.51412964", "0.5141028", "0.5138326", "0.5132959", "0.5129327", "0.5125056", "0.5123989", "0.5123484", "0.5118292", "0.51174337", "0.51167375", "0.5115107", "0.5112897", "0.5103236", "0.51020175", "0.5099685", "0.5097621", "0.5095654", "0.50946397", "0.5089297", "0.508544", "0.50853586", "0.5084066" ]
0.0
-1
Metodo "Sumar" llama al metodo nativo "SumarC"
public double Sumar(double operador_1, double operador_2){ return SumaC(operador_1, operador_2); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void sumar(){\n recogidaDatos();\n System.out.println(\"El resultado de la suma es: \" + (numerando1 + numerando2));\n System.out.println(\"***********************************\");\n\n }", "private int sumaCen(){\n int kasa = 0;\n for(Restauracja r :zamowioneDania){\n kasa+=r.getCena();\n }\n return kasa;\n }", "public static void main(String[] args){\n\t\tSystem.out.println(\"Resultado1: (a + b) = \" + Operaciones.sumar(3,4));\n\t\tSystem.out.println();\n\n\t\t//Metodo int double\n\t\tSystem.out.println(\"Resultado2: (a + b) = \" + Operaciones.sumar(5,4.1));\n\t\tSystem.out.println();\n\n\t\t//Metodo double int\n\t\tSystem.out.println(\"Resultado3: (a + b) = \" + Operaciones.sumar(7.1,6));\n\t\tSystem.out.println();\n\n\t\t//¿Cúal es el metodo que se manda a llamar si utilizamos los siguientes argumentos?\n\t\tSystem.out.println(\"Resultado4: (a + b) = \" + Operaciones.sumar(3,4L)); //Se manda a llamar un (int,double) ya que un double y un long son de 64 bytes\n\t\tSystem.out.println();\n\n\t\t//¿Cúal es el metodo que se manda a llamar si utilizamos los siguientes argumentos?\n\t\tSystem.out.println(\"Resultado4: (a + b) = \" + Operaciones.sumar(5F,'A')); //Se manda a llamar un (double,int) ya que un \"float\" lo soporta un \"double\" y el \"char\" lo soporta el \"int\"\n\t\tSystem.out.println();\n\t}", "public void sumar() {\n Acumula.acumulador++;\n }", "int getSumaAdunata();", "int getSuma();", "public void sumarUnidad() {\r\n\t\tcantidad++;\r\n\t}", "public static void sumarSuma(int valor) {\n\t\tsuma += valor;\n\t}", "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 }", "void desconto_final(){\n setDesconto_final(this.inss + this.irpf);\n System.out.println(\"desconto_total = R$ \" + arredondar(this.desconto_final));\n }", "public void calculos() {\n a = a1+a2+a3;\n b = b1+b2+b3;\n c = c1+c2+c3;\n }", "public static Double sumarColeccion(ListaVinculada<Double> coleccionStrings) {\n double acumulador=0.0;\n for (Double dato : coleccionStrings) {\n acumulador =acumulador+dato;\n }\n return acumulador;\n }", "public void Sumatoria()\n {\n for (int i = 0; i < vector1.length; i++) {\n sumatoria[i]=vector1[i]+vector2[i];\n }\n }", "public void categoryTotal()\n {\n attiretra=c+c2+c3;\n audibitytra=d+d2+d3;\n emphasistra=e+e2+e3;\n gesturetra=f+f2+f3;\n contenttra=g+g2+g3;\n dikomatra=at+at2+at3;\n diagelotra=bt+bt2+bt3;\n humantra=ct+ct2+ct3;\n womenabusetra=dt+dt2+dt3;\n killingtra=ht+ht2+ht3;\n rapetra=et+et2+et3;\n xenophobiatra=gt+gt2+gt3;\n albinismtra=ft+ft2+ft3;\n }", "public static void main(String[] args) {\n\t\tSystem.out.println(\"La suma de los cuadrados es \"+FuncCuadrado());\n\t}", "private static void calcularTotal(String[] campos) {\n\t\tif (campos.length == 1)\n\t\t\tSystem.out.println(\"TOTAL de lugares atribuidos: \" + gestor.totalAtribuidos());\n\t\telse {\n\t\t\tint escalao = Integer.valueOf(campos[1]);\n\t\t\tSystem.out.println(\"TOTAL de lugares atribuidos no escalao \" + escalao + \" : \" + gestor.atribuidosNoEscalao(escalao));\n\t\t}\n\t}", "public int sumar(){\n return this.a+this.b;\n }", "public int fondMagasin(){\n\tint total =this.jeton;\n\tfor(Caisse c1 : this.lesCaisses){\n\ttotal = c1.getTotal()+total;\n\t}\n\treturn total;\n}", "public int suma(int numero1, int numero2){\n //Estas variables solo tienen el alcance de este metodo\n return numero1 + numero2;\n }", "public String getSum();", "public void prinRecaudacion()\n {\n System.out.println(\"La cantidad recaudada por la maquina1 es \" + maquina1.getTotal());\n System.out.println(\"La cantidad recaudada por la maquina2 es \" + maquina2.getTotal());\n System.out.println(\"La cantidad total es\" + ( maquina1.getTotal() + maquina2.getTotal()));\n}", "public int sumarConRetorno() {\n return a + b;\n }", "public static void main(String[] args) {\n\n\t\tConta c = new Conta();\n\t\tContaCorrente cc = new ContaCorrente();\n\t\tContaPoupanca cp = new ContaPoupanca();\n\t\t\n\t\tc.deposita(5000);\n\t\tcc.deposita(5000);\n\t\tcp.deposita(5000);\n\t\t\n\t\tAtualizadorDeContas adc = new AtualizadorDeContas(0.01);\n\t\t\n\t\tSystem.out.println(\"\\n Criando um banco com 3 contas\");\n\t\tBanco banco = new Banco(3);\n\t\tbanco.adiciona(c);\n\t\tbanco.adiciona(cc);\n\t\tbanco.adiciona(cp);\n\t\t\n\t\tfor (int i = 0; i < banco.pegaTotalContas(); i ++){\n\t\t\tSystem.out.println(\"\\n Funcionario de numero \" + (i+1));\n\t\t\tSystem.out.println(\"Saldo: %.2f \\n \" + banco.pegaConta(i).getSaldo());\n\t\t\tadc.roda(banco.pegaConta(i));\n\t\t}\n\t\t\n\t\tSystem.out.println(\"\\n Saldo total: %.2f\\n\" + adc.getSaldoTotal());\n\t\t\n\t}", "public int getTotalRecaudado()\n {\n return maquina1.getTotal() + maquina2.getTotal();\n }", "public static void main(String[] args) {\n\n int resultado = new Aritmetica(4,5).sumar();\n\n System.out.println(\"resultado = \" + resultado);\n\n }", "public static void main(String[] args) {\n\t\t Scanner teclado=new Scanner(System.in);\n\t\t int n, suma=0, aux;\n\t\t System.out.println(\"Introducir numero\");\n\t\t n=teclado.nextInt();\n\t\t aux=n;\n\t\t while(aux>0){\n\t\t\tsuma=suma + aux%10;\t\t\t\n\t\t\tSystem.out.println(\"Sumo \"+ (aux%10)); //Desde el final vamos cogiendo los digitos\n\t\t\taux=aux/10;\n\t }\n\t\tSystem.out.println(\"La suma de las cifras del numero \" + n + \" es \"+suma);\t\n\t\tteclado.close();\n\t}", "public static void main(String[] args) {\n\t\t\n\t\tint suma = 0; //Acumulador en el que guardamos el resultado de las sumas.\n\t\t\tfor (int cont = 1; cont <=3; cont++)\n\t\t\tsuma = suma + cont;\n\t\t\t\n\t\t\tSystem.out.println(\"La suma es:\" + suma);\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}", "private void sumarTotalVenta(int cantidad, double precioProducto) {\r\n\t\tdouble valorProductos = cantidad * precioProducto;\r\n\t\ttotalVenta += valorProductos;\r\n\t}", "public Summalista()\r\n\t{\r\n\t\tthis.summa = 0;\r\n\t\tthis.alkiot = 0;\r\n\t}", "public String sumatoria(int columna) {\r\n\t\ttry {\r\n\t\t\tdouble total = 0;\r\n\t\t\tDouble cAux = new Double(total);\r\n\t\t\tString totalChar = \"\";\r\n\t\t\tString valchar = \"\";\r\n\t\t\tfor (int i = 1; i <= this.elemVS.size(); i++) {\r\n\t\t\t\tvalchar = (getObject(i, columna)).toString();\r\n\t\t\t\ttotal = total + (Double.valueOf(valchar)).doubleValue();\r\n\t\t\t}\r\n\t\t\ttotalChar = Double.toString(total);\r\n\t\t\treturn totalChar;\r\n\t\t}\r\n\t\tcatch (Exception e) {\r\n\t\t\treturn \"&nbsp;\";\r\n\t\t}\r\n\t}", "public static void main(String[] args)\n\t{\n\t int sum = Compute.sum(3, 4);\n\t\t//int sum = c.sum(3, 4);\n\t\tSystem.out.println(sum);\n\t\t\n\t\tint sum1 = Compute.sum(5,1,2);\n\t\tSystem.out.println(sum1);\n\t\t\n\t\tdouble sum2 = Compute.sum(4.5,3.9);\n\t\tSystem.out.println(sum2);\n\t}", "private void sumaApostado() {\n\t\tapostado.set(apostado.get() + 1.0);\n\t\tdiruField.setText(String.format(\"%.2f\", apostado.get()));\n\t\tactualizaPremio();\n\t}", "public void main(String[] args) {\n \n Scanner entrada = new Scanner(System.in); \n String nombre;\n \n System.out.println(\"¿Cual es tu Nombre? \");\n nombre = entrada.nextLine();\n mensaje(nombre);\n \n \n \n imprimir(28, 12);\n imprimir(67, 6);\n imprimir(84, 16);\n imprimir(57, 23);\n imprimir(92, 12);\n \n \n\n \n int resultado=sumar(1, 2);\n System.out.println(\n concatenar(\"El resultado es\", \"\" +resultado));\n \n int resultado2= sumar(sumar(1, 2), 7);\n\n boolean mayor= comprobar(resultado2);\n \nif(comprobar(resultado2))\n System.out.println(\"Es mayor\");\n else\n System.out.println(\"No es mayor\");\n}", "public static void main(String[] args) {\n\n Triangulo triangulo = new TrianguloEquilatero();\n Rectangulo rectangulo = new Rectangulo();\n Circulo circulo = new Circulo();\n\n Matematica matematica = new Matematica();\n matematica.calcularArea(triangulo);\n matematica.calcularArea(rectangulo);\n System.out.println(\"Area cuadrado: \" + rectangulo.getArea());\n matematica.calcularArea(circulo);\n\n matematica.calcularPerimetro(triangulo);\n matematica.calcularPerimetro(rectangulo);\n matematica.calcularPerimetro(circulo);\n\n // No se permite porque solo tiene metodos estaticos\n // y por eso se creo el contructor privado\n // MatematicaUtils matematicaUtils = new MatematicaUtils();\n double suma = MatematicaUtils.suma(1,2,3,4,5);\n System.out.println(\"Suma: \" + suma);\n\n\n String[] nombres = StringUtils.dividir1();\n System.out.println(\"Cadena estatico: \" + StringUtils.cadena1);\n }", "static void additionner() throws IOException {\n\t\tScanner clavier = new Scanner(System.in);\n\t\tint nb1, nb2, resultat;\n\t\tnb1 = lireNombreEntier();\n\t\tnb2 = lireNombreEntier();\n\t\tresultat = nb1 + nb2;\n\t\tSystem.out.println(\"\\n\\t\" + nb1 + \" + \" + nb2 + \" = \" + resultat);\n\t}", "public static void main(String[] args) {\n Calculadora cal = new Calculadora();\n\n int actualResult = cal.sumar(5,5);\n int expectedResult = 10;\n\n if(actualResult == expectedResult){\n System.out.println(\"Funciona\");\n }else {\n System.out.println(\"No Funciona\");\n }\n }", "IVec3 sum(IVec3 v);", "public Fraccion suma() {\r\n return new Fraccion(operador1.getNumerador()*operador2.getDenominador() + operador1.getDenominador()*operador2.getNumerador(),\r\n operador1.getDenominador()*operador2.getDenominador());\r\n }", "private void syncNumCopertiTotali() {\n int qPranzo = campoPranzo.getInt();\n int qCena = campoCena.getInt();\n campoTotale.setValore(qPranzo+qCena);\n }", "public static int tirarDados(){\n //elige valores aleatorios para los dados\n int dado1 = 1 + numerosAleatorios.nextInt(6);//<primer tiro del dado\n int dado2 = 1 + numerosAleatorios.nextInt(6);//< segundo tiro del dado\n \n int suma = dado1 + dado2;//< suma de los valores de los dados\n \n //muestra los resultados de este tiro\n System.out.printf(\"El jugador tiro %d + %d = %d%n\", dado1, dado2, suma);\n return suma;\n }", "public void suma(View v){\n presenter.Operacion(main_number_one.getText().toString(),main_number_two.getText().toString(),1);\n }", "public static void main(String[] args) {\n\t\tInteger a, b, c, d;\n\t\ta = readWindowInteger(\"Digite um número para var A\");\n\t\tb = readWindowInteger(\"Digite um número para var B\");\n\t\tc = readWindowInteger(\"Digite um número para var C\");\n\t\td = readWindowInteger(\"Digite um número para var D\");\n\n\t\t//Passo 2: fazer as combinações de soma\n\t\tInteger\n\t\t\t\tsomaAB, //1\n\t\t\t\tsomaAC, //2\n\t\t\t\tsomaAD, //3\n\t\t\t\tsomaBC, //4\n\t\t\t\tsomaBD, //5\n\t\t\t\tsomaCD; //6\n\t\t\n\t\tsomaAB = a + b; //1\n\t\tsomaAC = a + c; //2\n\t\tsomaAD = a + d; //3\n\t\tsomaBC = b + c; //4\n\t\tsomaBD = b + d; //5\n\t\tsomaCD = c + d; //6\n\t\t\t\t\n\t\t//Passo 3: fazer as combinações de multiplicacao\n\t\tInteger\n\t\t\t\tmultiAB,\n\t\t\t\tmultiAC,\n\t\t\t\tmultiAD,\n\t\t\t\tmultiBC,\n\t\t\t\tmultiBD,\n\t\t\t\tmultiCD;\n\t\t\n\t\tmultiAB = a * b;\n\t\tmultiAC = a * c;\n\t\tmultiAD = a * d;\n\t\tmultiBC = b * c;\n\t\tmultiBD = b * d;\n\t\tmultiCD = c * d;\n\t\t\n\t\t//Passo 4: exibir todas as combinações\n\t\twriteWindow(\n\t\t\t\t\"+----------------------------------------+\\n\" +\n\t\t\t\t\"| Combinações da Operações Matemáticas |\\n\" +\n\t\t\t\t\"+----------------------------------------+\\n\" +\n\t\t\t\t\" Valores Originais\\n\" +\n\t\t\t\t\" A = \" + a + \" \\n\" +\n\t\t\t\t\" B = \" + b + \" \\n\" +\n\t\t\t\t\" C = \" + c + \" \\n\" +\n\t\t\t\t\" D = \" + d + \" \\n\" +\n\t\t\t\t\"\\n\" +\n\t\t\t\t\" Somas \\n\" +\n\t\t\t\t\" A + B = \" + somaAB + \" \\n\" +\n\t\t\t\t\" A + C = \" + somaAC + \" \\n\" +\n\t\t\t\t\" A + D = \" + somaAD + \" \\n\" +\n\t\t\t\t\" B + C = \" + somaBC + \" \\n\" +\n\t\t\t\t\" B + D = \" + somaBD + \" \\n\" +\n\t\t\t\t\" C + D = \" + somaCD + \" \\n\" +\n\t\t\t\t\" \\n\" +\n\t\t\t\t\" Multiplicações \\n\" +\n\t\t\t\t\" A * B = \" + multiAB + \" \\n\" +\n\t\t\t\t\" A * C = \" + multiAC + \" \\n\" +\n\t\t\t\t\" A * D = \" + multiAD + \" \\n\" +\n\t\t\t\t\" B * C = \" + multiBC + \" \\n\" +\n\t\t\t\t\" B * D = \" + multiBD + \" \\n\" +\n\t\t\t\t\" C * D = \" + multiCD + \" \\n\" +\n\t\t\t\t\"\t\\n\" +\n\t\t\t\t\"+----------------------------------------+\"\n\t\t\n\t\t);\n\t\t\n\t\t\n\t\t// Your code ends here :(\n//<editor-fold defaultstate=\"collapsed\" desc=\"final program settings...\">\n\t}", "public void sum()\n {\n int a=5;\n int b=10;\n int c=a+b;\n\n System.out.println(c);\n }", "public String sumatoria(String columna) {\r\n\t\ttry {\r\n\t\t\tdouble total = 0;\r\n\t\t\tDouble cAux = new Double(total);\r\n\t\t\tString totalChar = \"\";\r\n\t\t\tString valchar = \"\";\r\n\t\t\tfor (int i = 1; i <= this.elemVS.size(); i++) {\r\n\t\t\t\tvalchar = (getObject(i, columna)).toString();\r\n\t\t\t\ttotal = total + (Double.valueOf(valchar)).doubleValue();\r\n\t\t\t}\r\n\t\t\ttotalChar = Double.toString(total);\r\n\t\t\treturn totalChar;\r\n\t\t}\r\n\t\tcatch (Exception e) {\r\n\t\t\treturn \"&nbsp;\" + elemVS.size();\r\n\t\t}\r\n\t}", "public T sum();", "public double sum() {\n double resultat = 0;\n for (int i = 0; i < tab.size(); i++) {\n resultat += CalculatorArray.sum(tab.get(i));\n }\n System.out.println(\"Sum colonne:\" + resultat);\n return resultat;\n }", "public static void main(String[] args){\n printMessage(\"so\", \"calm..\");\n System.out.println(sum(3,5,6));\n }", "public void total() {\n\t\t\n\t}", "public void aumentarAciertos() {\r\n this.aciertos += 1;\r\n this.intentos += 1; \r\n }", "private static void cajas() {\n\t\t\n\t}", "double getSum();", "double getSum();", "public static void sueldoTotal(int hora, int sueldo){\n int resultado = 0;\r\n if(hora<=40){\r\n resultado = hora*sueldo;\r\n }\r\n if(hora>40 || hora<48){\r\n resultado = (40*sueldo)+(hora-40)*(sueldo*2);\r\n }\r\n if (hora>=48){\r\n resultado =(40*sueldo)+8*(sueldo*2)+(hora-48)*(sueldo*3);\r\n }\r\n System.out.println(\"El sueldo es de \"+ resultado);//Se muestra el sueldo total\r\n \r\n \r\n \r\n }", "private static Suma creaObjetoSuma (){\n Suma suma = new Suma(4,6);\n return suma; \n }", "public void calcularTotalGastos(FormularioRegistrarCorte formularioRegistrarCorte) {\n Double suma = 0.0;\n try {\n for (int i = 0; i < formularioRegistrarCorte.getTablaSlidas().getRowCount(); i++) {\n suma = suma + (Double.valueOf(formularioRegistrarCorte.getTablaSlidas().getValueAt(i, 2).toString()));\n }\n formularioRegistrarCorte.getTxtTotalGastos().setText(new OperacionesUtiles().formatoDouble(suma));\n } catch (Exception e) {\n showMessageDialog(null, \"Ocurrio un error al intenetar calcular total salidas\");\n }\n\n }", "@Override\n\tpublic int sum() {\n\t\treturn this.first + this.second + this.third;\n\t}", "@Test\n public void testSuma() {\n assertEquals(new Fraccion(12.0, 9.0), instance.suma());\n assertEquals(12.0, instance.suma().getNumerador(), 0.001);\n assertEquals(9.0, instance.suma().getDenominador(), 1.0E-3); // 1.0 ^ -3 -> 1 / 1000\n }", "public void añadirCuentas(int numeroCuentas){\n\t\tfloat saldo; \r\n\t\tint random;\r\n\t\tString titular=\"\", numero=\"\", caracteres=\"0123456789\";\r\n\t\tString[] palabras=new String[5];\r\n\t\tpalabras[0]=\"Marta\";\r\n\t\tpalabras[1]=\"Javier\";\r\n\t\tpalabras[2]=\"Sandra\";\r\n\t\tpalabras[3]=\"David\";\r\n\t\tpalabras[4]=\"Juan\";\r\n\t\tboolean valida;\r\n\r\n\t\t//(int)(Math.random()*(hasta-desde+1)+desde)\r\n\r\n\r\n\t\tfor (int i=0;i<numeroCuentas;i++){\r\n\r\n\t\t\trandom=(int)(Math.random()*(4-0+1)+0);\r\n\t\t\ttitular=palabras[random];\r\n\r\n\t\t\trandom=(int)(Math.random()*(10000-0+1)+0);\r\n\t\t\tsaldo=random;\r\n\r\n\t\t\tdo{\r\n\t\t\t\tfor(int j=0;j<20;j++){\r\n\t\t\t\t\trandom=(int)(Math.random()*(9-0+1)+0);\r\n\t\t\t\t\tnumero+=caracteres.charAt(random);\r\n\t\t\t\t}\r\n\t\t\t\tvalida=comprobarNumero(numero);\r\n\t\t\t}while(!valida);\r\n\r\n\t\t\tCuentaCorriente defecto=new CuentaCorriente(titular, numero, saldo);\r\n\t\t\tlista[i]=defecto;\r\n\t\t\tCuentas.setnCuentas(CuentaCorriente.getCodigo());\r\n\t\t\tnumero=\"\";\r\n\r\n\t\t}\r\n\t\tordenar();\r\n\r\n\t}", "public void generarTotal(){\n\n\t\tfloat total = 0;\n\n\t\tfor (int con = 0; con < modelo.getRowCount(); con++) {\n\n\t\t\ttotal += (float) tabla.getValueAt(con, 3);\n\t\t\t\n\t\t}\n\n\t\tcampoTotal.setText(formato.format(total));\n\n\t\tlimpiarCampos();\n\n\t}", "public void iniSumSubconjuntos(int[] conjunto, int sumD)\n {\n List<List<Integer>> subsets = new ArrayList<>();\n subsets.add(new ArrayList<>());\n String ns = \"\";\n int sum = 0;\n int nSum = 1;\n System.out.println(\"Subconjunto que suman \" + sumD);\n for (int x : conjunto)\n {\n int n = subsets.size();\n for (int i = 0; i < n; i++)\n {\n ArrayList<Integer> aux = new ArrayList(subsets.get(i));\n aux.add(x);\n subsets.add(aux);\n if (aux.size() >= 2)\n {\n //Ejecucion del hilo mientras hace las combinaciones\n //-->>Implementado en hilo\n int add = 0;\n String ssAux = \"\";\n ssAux += \"{ \";\n for (int j = 0; j < aux.size(); j++)\n {\n if (j == aux.size() - 1)\n {\n ssAux += aux.get(j);\n } else\n {\n ssAux += aux.get(j) + \", \";\n }\n add += aux.get(j);\n }\n ssAux += \" }\\n\";\n if (add == sumD)\n {\n //--> Aqui imprime el resultado\n //System.out.println(\"\" + ssAux);\n sum++;\n System.out.println(sum + \".-\" + ssAux + \"\\n\");\n s += ssAux;\n } else\n {\n ns += nSum + \".- \" + ssAux + \"\\n\";\n nSum++;\n }\n }\n }\n }\n //System.out.println(\"Subconjuntos que suman \" + sumD + \"\\n\" + s + \" Total de resultados: \" + sum + \"\");\n System.out.println(\"\\n----------------------------------------------------------------------------------------\");\n System.out.println(\"Subconjuntos que NO suman \" + sumD + \"\\n\" + ns + \"Total de resultados: \" + nSum);\n //System.out.println(\"PPSubconjuntos\");\n /*subsets.forEach(System.out::println);*/\n }", "public void totalEntradas(int[][] entradas) {\n int totalProductos = 0;\n int costoTotal = 0;\n \n ciclo : {\n for (int i = 0; i < entradas.length; i++) {\n if (entradas[i][1] != 0) {\n totalProductos++;\n costoTotal += entradas[i][3];\n }\n } \n }\n \n DefaultTableModel modelo = (DefaultTableModel) jTableTotalEntradaCostos.getModel();\n Object[] filaNueva = { totalProductos, costoTotal };\n modelo.addRow(filaNueva);\n }", "public void calcularTotalVentas(FormularioRegistrarCorte formularioRegistrarCorte) {\n Double suma = 0.00;\n try {\n for (int i = 0; i < formularioRegistrarCorte.getTablaEntradas().getRowCount(); i++) {\n suma = suma + (Double.valueOf(formularioRegistrarCorte.getTablaEntradas().getValueAt(i, 2).toString()));\n }\n formularioRegistrarCorte.getTxtTotalVentas().setText(new OperacionesUtiles().formatoDouble(suma));\n } catch (Exception e) {\n showMessageDialog(null, \"Ocurrio un error al intenetar calcular total entradas\");\n\n }\n\n }", "public int Suma(){\r\n for (int i = 0; i < 9; i++) {\r\n mult = convert()[i] * arregloCo[i];\r\n // Si la suma e mayor o igual a 10 se le resta 9\r\n if (mult >= 10){\r\n mult = mult - 9;\r\n }\r\n suma = suma + mult;\r\n }\r\n return suma;\r\n }", "public void sum() { // 0 input parameter\r\n\t\tSystem.out.println(\"Sum method -- Zero parameter\");\r\n\r\n\t\t// public void test() {\r\n\t\t//\r\n\t\t// }\r\n\t}", "private void getSum() {\n\t\tint sum =0;\r\n\t\t\r\n\t\tfor(int i=0; i<index; i++) {\r\n\t\t\tif(products[i] != null)\r\n\t\t\t\tsum += products[i].getPrice();\r\n\t\t}\r\n\t\tSystem.out.println(sum);\r\n\t}", "public static void main(String[] args) {\n sum(23, 43);\n }", "public boolean calcularTotal() {\r\n double dou_debe = 0;\r\n double dou_haber = 0;\r\n for (int i = 0; i < tab_tabla2.getTotalFilas(); i++) {\r\n try {\r\n if (tab_tabla2.getValor(i, \"ide_cnlap\").equals(p_con_lugar_debe)) {\r\n dou_debe += Double.parseDouble(tab_tabla2.getValor(i, \"valor_cndcc\"));\r\n } else if (tab_tabla2.getValor(i, \"ide_cnlap\").equals(p_con_lugar_haber)) {\r\n dou_haber += Double.parseDouble(tab_tabla2.getValor(i, \"valor_cndcc\"));\r\n }\r\n } catch (Exception e) {\r\n }\r\n }\r\n eti_suma_debe.setValue(\"TOTAL DEBE : \" + utilitario.getFormatoNumero(dou_debe));\r\n eti_suma_haber.setValue(\"TOTAL HABER : \" + utilitario.getFormatoNumero(dou_haber));\r\n\r\n double dou_diferencia = Double.parseDouble(utilitario.getFormatoNumero(dou_debe)) - Double.parseDouble(utilitario.getFormatoNumero(dou_haber));\r\n eti_suma_diferencia.setValue(\"DIFERENCIA : \" + utilitario.getFormatoNumero(dou_diferencia));\r\n if (dou_diferencia != 0.0) {\r\n eti_suma_diferencia.setStyle(\"font-size: 14px;font-weight: bold;color:red\");\r\n } else {\r\n eti_suma_diferencia.setStyle(\"font-size: 14px;font-weight: bold\");\r\n return true;\r\n }\r\n return false;\r\n }", "@Override\n public double calcularValorCompra(ArrayList<Mueble> muebles){\n double total = 0d;\n for (Mueble m : muebles) {\n total+= m.getCantidad()*m.getPrecio();\n }\n return total; \n }", "public static void main(String[] args) {\n\n\n Scanner scanner = new Scanner(System.in);\n // V skobite mu kazvame OT KUDE DA CHETE, v sluchaq da chete ot standarniq\n // vhod, t.e. OT KONZOLATA ! NO MOJE I DA CHETE OT DRUGI MESTA !!!\n // SKENERA VAJI SAMO ZA METODA V KOITO E SUZDADEN, MOJEM DA GO KRUSTIM KAKTO SI ISKAME !\n\n // V Java Integer.parseInt() e ekvivalentno na int.Parse() v C# !!!!!\n //Double.parseDouble() E KATO double.Prse() !!!!\n //scanner.nextLine() e kato console.ReadLine() v C# !!!\n double firstNum = Double.parseDouble(scanner.nextLine());\n double secondNum = Double.parseDouble(scanner.nextLine());\n\n double sum = firstNum + secondNum;\n\n\n // S Place holdera mojem da formatirame kakto si poiskame\n //Trqbva da e .printf() za da raboti.\n System.out.printf(\"Sum = %.2f\", sum);\n\n //VAJNO !!! :\n // V Java nqma decimal, Ima BigInteger, BigDecimal i dr\n // BigInteger e Cqlo chislo koeto e golqmo kolkoto ni subira pametta !\n // BigDecimal e DROBNO CHISLO koeto e golqmo kolkoto ni subira pametta !\n }", "public static void main(String[] args) {\n\n int finalNumber = 8;\n\n sum(finalNumber);\n System.out.println(sum(finalNumber));\n }", "public static void main(final String[] args) {\n SimpleSummater summater = new SimpleSummater();\n final int[] array = {10, 20, 1, 25};\n System.out.println(summater.sum(array));\n }", "@Override\n public void cantidad_Ataque(){\n ataque=5+2*nivel+aumentoT;\n }", "public static void main(String[] args) {\n String primerNumero = JOptionPane.showInputDialog(\"Introduzca el primer entero\");\r\n String segundoNumero = JOptionPane.showInputDialog(\"Introduzca el segundo entero\");\r\n \r\n //Convertir las entradas String en valores int para usarlos en un calculo\r\n int numero1 = Integer.parseInt(primerNumero);\r\n int numero2 = Integer.parseInt(segundoNumero);\r\n int suma = numero1 + numero2;\r\n \r\n //Muestra los resultados en un dialogo de mensajes de JOptionPane\r\n JOptionPane.showMessageDialog(null,\"La suma es \" + suma, \"Suma de dos enteros\", JOptionPane.PLAIN_MESSAGE);\r\n }", "public static void main(String[] args) {\n\r\n\t\t\r\n\t\tScanner teclado= new Scanner(System.in);\r\n\t\t\r\n\t\tString pedido;\r\n\t\tint armz;\r\n\t\t\r\n\t\tSystem.out.println(\" Digite uma palavra \");\r\n\t\tpedido=teclado.nextLine();\r\n\t\t\r\n\t\tarmz=Contar2(pedido);\r\n\t\t\r\n\t\tSystem.out.println(\"QUANTIDADE DE CARACTERES ENCONTTRADOS \"+armz);\r\n\t\t\r\n\t\t\r\n\t}", "public static void main(String[] args) {\n Math math=new Math();\n System.out.println(math.sum(5, 13));\t\n\t System.out.println(math.sub(13, 5));\n\t System.out.println(math.mult(13, 5));\n\t System.out.println(\"Bölüm :\"+ math.divide(13, 5));\n\t System.out.println(math.getpi());\n\t System.out.println(math.areaOfCircle(5));\n\t System.out.println(math.volumeOfShpere(3));\n\t System.out.println(math.areaOfRectangularPrism(3, 4, 6));\n System.out.println(\"üçgenin Alanı :\"+math.areaOfTriangle(5, 4, 2));\n\t System.out.println(\"Üçgenin Çevresi :\"+math.perimeterOfTriangle(5, 4, 2));\t\n\t System.out.println(math.factoriyel(5));\n\t System.out.println(math.sumOfSmallNumbers(6));\n\t// System.out.println(math.theSumOfTheNumbersBetween(3, 6));\n\t}", "default int sumOfAll(int a, int b) {\n\t\t\treturn 0;\n\t\t}", "public static void main(String[] args) {\nint i;\nint sum=0;\nfor (i=1;i<=5; sum =sum + i++) \n\tSystem.out.println(\"сумма= \" +sum);\n\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 void mostrarTotales() { \n // Inicializacion de los atributos en 0\n totalPCs = 0;\n totalLaptops = 0;\n totalDesktops = 0; \n /* Recorrido de la lista de computadores para acumular el precio usar instanceof para comparar el tipo de computador */ \n for (Computador pc : computadores){\n if (pc instanceof PCLaptop) {\n totalLaptops += pc.calcularPrecio(); \n } else if (pc instanceof PCDesktop){\n totalDesktops += pc.calcularPrecio();\n }\n }\n totalPCs = totalLaptops + totalDesktops;\n System.out.println(\"El precio total de los computadores es de \" + totalPCs); \n System.out.println(\"La suma del precio de los Laptops es de \" + totalLaptops); \n System.out.println(\"La suma del precio de los Desktops es de \" + totalDesktops);\n }", "private int sum(AFormula o1){\n\t\t\t\t\n\t\t\t\treturn o1.calculate(customerType, weekdayCount, weekendCount);\n\t\t\t\t\n\t\t\t}", "public static void main(String[] args) {\n\t\tConta conta = new Conta(\"Brendo\", 111, 1000.00, 0.0);\n\t\tconta.depositar(100.00);\n\t\tconta.sacar(10.00);\n\t\tconta.sacar(10.00);\n\t\tSystem.out.println(conta.getSaldo());\n\t}", "public static void main(String[] args){\n int result = Stream.of(1,2,3,4,5,6,7,8,9,10)\n .reduce(0,Integer::sum);//metodo referenciado\n// .reduce(0, (acumulador, elemento) -> acumulador+elemento);\n System.out.println(result);\n\n // Obtener lenguajes separados por pipeline entre ellos y sin espacios\n // opcion 1(mejor) con operador ternario\n String cadena = Stream.of(\"Java\",\"C\",\"Python\",\"Ruby\")\n .reduce(\"\", (acumulador, lenguaje) -> acumulador.equals(\"\")?lenguaje:acumulador + \"|\" + lenguaje);\n\n System.out.println(cadena);\n\n //Opcion 2 Con regex\n String cadenaRegex = Stream.of(\"Java\",\"C\",\"Python\",\"Ruby\")\n .reduce(\"\", (acumulador, lenguaje) -> acumulador + \"|\" + lenguaje)\n .replaceFirst(\"\\\\|\",\"\") // Quitamos la primera pipeline\n .replaceAll(\"\\\\s\",\"\"); // Quitamos todos los espacios\n\n System.out.println(cadenaRegex);\n }", "static int sum(int... args) {\n\t\tint sum = 0;\n\t\tfor (int arg : args)\n\t\t\tsum += arg;\n\t\treturn sum;\n\t}", "public double getCustoAluguel(){\n return 2 * cilindradas;\n }", "public static void main (String[] args){\n int num;\n Scanner n = new Scanner(System.in);\n num = n.nextInt();\n int sod = sum(num);\n System.out.println(sod);\n\t}", "public void suma(int dirOp1, int dirOp2, int dirRes) {\n //traduce casos de direccionamiento indirecto\n dirOp1 = traduceDirIndirecto(dirOp1);\n dirOp2 = traduceDirIndirecto(dirOp2);\n if (ManejadorMemoria.isConstante(dirOp1)) { // OPERANDO 1 CTE\n String valor1 = this.directorioProcedimientos.getConstantes().get(dirOp1).getValorConstante();\n if (ManejadorMemoria.isGlobal(dirOp2)) { // OPERANDO 2 GLOBAL\n String valor2 = this.registroGlobal.getValor(dirOp2);\n if (ManejadorMemoria.isGlobal(dirRes)) { // RES GLOBAL\n this.registroGlobal.guardaValor(dirRes, auxOperacion(dirOp1, dirOp2, valor1, valor2, Codigos.SUMA));\n } else { // RES LOCAL\n this.pilaRegistros.peek().guardaValor(dirRes, auxOperacion(dirOp1, dirOp2, valor1, valor2, Codigos.SUMA));\n }\n } else if (ManejadorMemoria.isConstante(dirOp2)) { // OPERANDO 2 CTE\n String valor2 = this.directorioProcedimientos.getConstantes().get(dirOp2).getValorConstante();\n if (ManejadorMemoria.isGlobal(dirRes)) { // RES GLOBAL\n this.registroGlobal.guardaValor(dirRes, auxOperacion(dirOp1, dirOp2, valor1, valor2, Codigos.SUMA));\n } else { // RES LOCAL\n this.pilaRegistros.peek().guardaValor(dirRes, auxOperacion(dirOp1, dirOp2, valor1, valor2, Codigos.SUMA));\n }\n } else { // OPERANDO 2 LOCAL\n String valor2 = this.pilaRegistros.peek().getValor(dirOp2);\n if (ManejadorMemoria.isGlobal(dirRes)) { // RES GLOBAL\n this.registroGlobal.guardaValor(dirRes, auxOperacion(dirOp1, dirOp2, valor1, valor2, Codigos.SUMA));\n } else { //RES LOCAL\n this.pilaRegistros.peek().guardaValor(dirRes, auxOperacion(dirOp1, dirOp2, valor1, valor2, Codigos.SUMA));\n }\n }\n } else if (ManejadorMemoria.isGlobal(dirOp1)) { // OPERANDO 1 GLOBAL\n String valor1 = this.registroGlobal.getValor(dirOp1);\n if (ManejadorMemoria.isGlobal(dirOp2)) { // OPERANDO 2 GLOBAL\n String valor2 = this.registroGlobal.getValor(dirOp2);\n if (ManejadorMemoria.isGlobal(dirRes)) { // RES GLOBAL\n this.registroGlobal.guardaValor(dirRes, auxOperacion(dirOp1, dirOp2, valor1, valor2, Codigos.SUMA));\n } else { // RES LOCAL\n this.pilaRegistros.peek().guardaValor(dirRes, auxOperacion(dirOp1, dirOp2, valor1, valor2, Codigos.SUMA));\n }\n } else if (ManejadorMemoria.isConstante(dirOp2)) { // OPERANDO 2 CTE\n String valor2 = this.directorioProcedimientos.getConstantes().get(dirOp2).getValorConstante();\n if (ManejadorMemoria.isGlobal(dirRes)) { // RES GLOBAL\n this.registroGlobal.guardaValor(dirRes, auxOperacion(dirOp1, dirOp2, valor1, valor2, Codigos.SUMA));\n } else { // RES LOCAL\n this.pilaRegistros.peek().guardaValor(dirRes, auxOperacion(dirOp1, dirOp2, valor1, valor2, Codigos.SUMA));\n }\n } else { // OPERANDO 2 LOCAL\n String valor2 = this.pilaRegistros.peek().getValor(dirOp2);\n if (ManejadorMemoria.isGlobal(dirRes)) { // RES GLOBAL\n this.registroGlobal.guardaValor(dirRes, auxOperacion(dirOp1, dirOp2, valor1, valor2, Codigos.SUMA));\n } else { // RES LOCAL\n this.pilaRegistros.peek().guardaValor(dirRes, auxOperacion(dirOp1, dirOp2, valor1, valor2, Codigos.SUMA));\n }\n }\n } else { // OPERANDO 1 LOCAL\n String valor1 = this.pilaRegistros.peek().getValor(dirOp1);\n if (ManejadorMemoria.isGlobal(dirOp2)) { // OPERANDO 2 GLOBAL\n String valor2 = this.registroGlobal.getValor(dirOp2);\n if (ManejadorMemoria.isGlobal(dirRes)) { // RES GLOBAL\n this.registroGlobal.guardaValor(dirRes, auxOperacion(dirOp1, dirOp2, valor1, valor2, Codigos.SUMA));\n } else { // RES 2 LOCAL\n this.pilaRegistros.peek().guardaValor(dirRes, auxOperacion(dirOp1, dirOp2, valor1, valor2, Codigos.SUMA));\n }\n } else if (ManejadorMemoria.isConstante(dirOp2)) { // OPERANDO 2 CTE\n String valor2 = this.directorioProcedimientos.getConstantes().get(dirOp2).getValorConstante();\n if (ManejadorMemoria.isGlobal(dirRes)) { // RES GLOBAL\n this.registroGlobal.guardaValor(dirRes, auxOperacion(dirOp1, dirOp2, valor1, valor2, Codigos.SUMA));\n } else { // RES LOCAL\n this.pilaRegistros.peek().guardaValor(dirRes, auxOperacion(dirOp1, dirOp2, valor1, valor2, Codigos.SUMA));\n }\n } else { //OPERANDO 2 LOCAL\n String valor2 = this.pilaRegistros.peek().getValor(dirOp2);\n if (ManejadorMemoria.isGlobal(dirRes)) { // RES GLOBAL\n this.registroGlobal.guardaValor(dirRes, auxOperacion(dirOp1, dirOp2, valor1, valor2, Codigos.SUMA));\n } else { // RES LOCAL\n this.pilaRegistros.peek().guardaValor(dirRes, auxOperacion(dirOp1, dirOp2, valor1, valor2, Codigos.SUMA));\n }\n }\n }\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 int getSum() {\n\t\t\treturn 0;\r\n\t\t}", "public static void main(String[] args) {\n System.out.println(getSum(6, 3));\n }", "public static void main(String[] args) {\n // initialize number to sum up to.\n int x = 3792;\n // Display the summation result.\n System.out.println(\"The sum of integers from 1 to \" + x +\n \" is \" + summation(x) + \".\");\n }", "public int getSuma() {\n return suma_;\n }", "public static void main(String[] args)\n {\n\n System.out.println(sum(3));\n }", "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 }", "public static void main(String[] args) {\n\n Poupanca poupanca = new Poupanca();\n\n Corrente corrente = new Corrente();\n\n poupanca.setNome(\"maria\");\n poupanca.setNumero(123);\n poupanca.setDiaAniversario(10);\n poupanca.depositar(100);\n\n\n System.out.println(\"=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=\");\n System.out.println(\"nome do cliente da poupança:\" + poupanca.getNome());\n\n boolean operacao = poupanca.sacar(50);\n\n if(operacao){\n System.out.println(\"saque realizado com sucesso\");\n }else {\n System.out.println(\"saldo insuficiente\");\n }\n\n System.out.println(\"saldo de \" + poupanca.getNome() + \": \" + poupanca.getSaldo());\n\n\n // para conta corrente\n corrente.setNumero(234);\n corrente.setNome(\"rafael\");\n corrente.depositar(1000);\n corrente.setLimite(500);\n\n System.out.println(\"=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=\");\n System.out.println(\"nome do cliente: \" + corrente.getNome());\n System.out.println(\"saldo atual: \" + corrente.getSaldo());\n\n operacao = corrente.sacar(500);\n\n if(operacao){\n System.out.println(\"saque realizado com sucesso\");\n }else {\n System.out.println(\"saldo insuficiente\");\n }\n\n System.out.println(\"saldo atual: \" + corrente.getSaldo());\n System.out.println(\"=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=\");\n\n Corrente corrente1 = new Corrente();\n corrente1.setSaldo(1000);\n\n GerenciarPatrimonioBanco gp = new GerenciarPatrimonioBanco();\n gp.adicionarConta(corrente);\n gp.adicionarConta(poupanca);\n gp.adicionarConta(corrente1);\n\n System.out.println();\n System.out.println(\"=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=\");\n System.out.println(\"total do dinheiro dos clientes no banco: \" );\n System.out.println(gp.getTotalPatrimonio());\n\n System.out.println(\"=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=\");\n\n }", "public static void main(String[] args) {\n\n\t\tSystem.out.println(\"3 dados al azar\");\n\t\t\n\t\tint dado1 = 0;\n\t\tint dado2 = 0;\n\t\tint dado3 = 0;\n\t\tint total;\n\t\t\n\t\t\n\t\tfor(int i=0; i<=1; i++) {\n\t\t\n\t\tdado1=((int)(Math.random()*7)+1);\n\t\tdado2=((int)(Math.random()*7)+1);\n\t\tdado3=((int)(Math.random()*7)+1);\n\t\t\n\t\t}\n\t\t\n\t\ttotal = dado1 + dado2 + dado3;\n\t\t\n\t\tSystem.out.println(\"Dado 1 : \"+dado1);\n\t\tSystem.out.println(\"Dado 2 : \"+dado2);\n\t\tSystem.out.println(\"Dado 3 : \"+dado3);\n\t\tSystem.out.println(\"Suma de los dados : \"+total);\n\t}", "public static int getSuma() {\n\t\treturn suma;\n\t}", "public void totalFacturaVenta(){\n BigDecimal totalVentaFactura = new BigDecimal(0);\n \n try{\n //Recorremos la lista de detalle y calculamos la Venta total de la factura\n for(Detallefactura det: listDetalle){\n //Sumamos a la variable 'totalVentaFactura'\n totalVentaFactura = totalVentaFactura.add(det.getTotal());\n } \n }catch(Exception e){\n e.printStackTrace();\n }\n \n //Setemos al objeto Factura el valor de la variable 'totalFacturaVenta'\n factura.setTotalVenta(totalVentaFactura);\n \n }", "public static void main(String[] args) {\n int[][] arrayFirst = {\n {1, 2, 3},\n {1, 2, 3},\n {1, 2, 3},\n };\n int[][] arraySecond = {\n {2, 2, 2},\n {3, 3, 3},\n {4, 4, 4}\n };\n int[][] arraySum = new int[arrayFirst.length][arrayFirst[0].length];\n System.out.println(\"Итоговая матрица:\");\n for (int i = 0; i < arrayFirst.length; i++) {\n for (int k = 0; k < arrayFirst[i].length; k++) {\n arraySum[i][k] = arrayFirst[i][k] + arraySecond[i][k];\n System.out.print(arraySum[i][k] + \" \");\n }\n System.out.println();\n }\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 }" ]
[ "0.6937479", "0.6794071", "0.6729296", "0.6685154", "0.6615303", "0.6508279", "0.6477747", "0.6386732", "0.6276026", "0.6243233", "0.62312394", "0.6160961", "0.6138986", "0.61295235", "0.6101033", "0.6064527", "0.59784174", "0.5966338", "0.59649116", "0.59614086", "0.59190786", "0.58861256", "0.5865505", "0.5858658", "0.5835424", "0.58340764", "0.5802847", "0.57897913", "0.57847846", "0.5780941", "0.57750547", "0.57636416", "0.5751675", "0.5748626", "0.5741962", "0.57412225", "0.5740041", "0.57372165", "0.5715096", "0.57042754", "0.5701692", "0.5679421", "0.5675078", "0.5673114", "0.56710273", "0.56705225", "0.5648489", "0.5648121", "0.5647042", "0.5641423", "0.5635607", "0.56308955", "0.56308955", "0.56156814", "0.56131554", "0.56078404", "0.5607082", "0.55952233", "0.5584484", "0.55717695", "0.5568502", "0.5556123", "0.55535084", "0.55294293", "0.55241954", "0.55224353", "0.5516202", "0.5502772", "0.5501941", "0.5500235", "0.54996884", "0.54978716", "0.549556", "0.5480049", "0.5474332", "0.54735893", "0.5471521", "0.5470811", "0.54670185", "0.5466887", "0.54571915", "0.5452835", "0.54476076", "0.54421455", "0.54403335", "0.5432798", "0.5429132", "0.54240656", "0.5415834", "0.5412385", "0.54091376", "0.5408874", "0.54069257", "0.5405087", "0.5404863", "0.5402761", "0.5394286", "0.53886014", "0.5381641", "0.5380107" ]
0.6161447
11
Metodo "Restar" llama al metodo nativo "RestarC"
public double Restar(double operador_1, double operador_2){ return RestaC(operador_1, operador_2); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n\tpublic void recreo() {\n\n\t}", "public void restarPunto ( ) {\n\t\tif ( vida > 0 )\n\t\t\tvida--;\n\t}", "public void reiniciar() {\n // TODO implement here\n }", "private static void cajas() {\n\t\t\n\t}", "@Override\r\n\tpublic void modifier_rec(long code_apoger) {\n\r\n for(int i=0;i<reclamations.size();i++) {\r\n\t\t\t\r\n\t\t\tif(reclamations.get(i).getcodeapoger() ==code_apoger ) {\r\n\t\t\t\t\r\n\t\t\t\t\r\n\t\t\t\treclamations.remove(reclamations);\r\n\t\t \r\n\t\t\t\treclamations.add(reclamations.get(i));\r\n\t\t\t\r\n\t } \r\n\t\t} \r\n }", "public void disparar(){}", "public void carroRemovido(){\n System.out.println(\"Su carro fue removido exitosamente\");\n }", "@Override\r\n\tpublic void rozmnozovat() {\n\t}", "public void rodar(){\n\t\tmeuConjuntoDePneus.rodar();\r\n\t}", "public void aumentarReproducidas() {\n\t\tsuper.aumentarReproducidas();\n\n\t}", "public void cocinar(){\n\n }", "void redo();", "public void cambiarRonda() {\n\t\ttry {\r\n\t\t\tjuego.cambiarRonda();\r\n\t\t} catch (RemoteException e) {\r\n\t\t\t// TODO Auto-generated catch block\r\n\t\t\te.printStackTrace();\r\n\t\t}\r\n\t}", "public void aumentarReproducciones() {\n\t\treproducciones++;\n\t}", "public void redo() {\n\t\t\n\t}", "public void imprimir() {\n Nodo reco=raiz;\n System.out.println(\"Listado de todos los elementos de la pila.\");\n System.out.print(\"Raiz-\");\n while (reco!=null) {\n \tSystem.out.print(\"(\");\n System.out.print(reco.edad+\"-\");\n System.out.print(reco.nombre+\"\");\n System.out.print(\")-\");\n //System.out.print(reco.sig+\"-\");\n reco=reco.sig;\n }\n System.out.print(\"Cola\");\n System.out.println();\n }", "public void testaReclamacao() {\n\t}", "@Override\n\tpublic void coba() {\n\t\t\n\t}", "@Override\n public Nodo ejecutar() {\n listaNodos.add(nodoRaiz);\n //nodo almacenado temporalmente\n Nodo nodoActual;\n //cola de hijos producto de aplicar ops\n ArrayList <Nodo> cola;\n \n NODO:while(!(listaNodos.isEmpty()))\n {\n nodoActual=listaNodos.get(0);\n listaNodos.remove(0);\n //Detecto el nodo como un ciclo y salto si sí es luego verifico meta\n if(nodoCiclo(nodoActual))\n {\n \n// System.out.println(\"Es Ciclo: \"+nodoActual.getOperador());\n continue NODO;\n }\n else if(esMeta(nodoActual)){\n solucion(nodoActual);\n JOptionPane.showMessageDialog(null, \"nodos expandidos\"+nodoexpandidos+\"profundidad\"+profundidad);\n return nodoActual;\n }\n //Expando Nodo\n cola=expandirNodo(nodoActual);\n nodoexpandidos++;\n for(int i=0;i<cola.size();i++)\n {\n Nodo temporal=cola.get(i);\n cola.set(i, temporal);\n \n }\n //Armo cola general\n cola.addAll(listaNodos);\n listaNodos=(ArrayList <Nodo>)cola.clone();\n }\n return null;\n }", "@Override\n\tpublic void addRecurso(Recurso recurso) {\n\t\t\n\t}", "public void gored() {\n\t\t\n\t}", "public void rec() {\n\n\t}", "@Override\n\tpublic void r() {\n\n\t}", "private static void muta(Cromosoma c)\n\t{\n\t}", "@Listen(\"onClick =#solicitudReclamo\")\n\t\tpublic void Reclamo() {\n\t\t\tString dir = \"gps/reclamo/frm-reclamo-ordenesEntrega.zul\";\n\t\t\tclearDivApp(dir);\n\t\t\t// Clients.evalJavaScript(\"document.title = 'ServiAldanas'; \");\n\t\t}", "@Override\n public void curar(Curandero curandero, Pieza receptor) {\n }", "public static void main(String[] args) {\n\n // Pitamo korisnika za ime fajla koji korisitmo\n String imeFajla = Svetovid.in.readLine(\"Unesite ime fajla:\");\n\n // Poziv prvog nacina ispisivanja\n citajSveRedove(imeFajla);\n\n // Moramo zatvoriti fajl da bi ga opet citali ispocetka\n Svetovid.in(imeFajla).close();\n\n // Poziv drugog nacina ispisivanja\n citajSveRedoveAlt(imeFajla);\n\n }", "static void perform_rrc(String passed){\n\t\tint type = type_of_rrc(passed);\n\t\tswitch(type){\n\t\tcase 1:\n\t\t\trrc_without_carry(passed);\n\t\t\tbreak;\n\t\t}\n\t}", "public static void main(String[] args) {\n Cachorro x = new Cachorro();\n //x.emitirSom();\n \n // Programa Principal\n Cachorro c = new Cachorro();\n \n c.reagir(\"Olá\"); // Abanar e Latir\n System.out.println(\"\");\n c.reagir(\"Vai apanhar\"); // Rosnar\n System.out.println(\"\");\n c.reagir(11, 45); // Abanar\n System.out.println(\"\");\n c.reagir(21, 00); // Ignorar\n System.out.println(\"\");\n c.reagir(true); // Abanar\n System.out.println(\"\");\n c.reagir(false); // Rosnar e Latir (// emitirSom();)\n System.out.println(\"\");\n c.reagir(2, 12.5f); // Latir\n System.out.println(\"\");\n c.reagir(17, 4.5f); // Rosnar\n \n }", "public abstract void mo91580a(StarTheme starTheme);", "public void riconnetti() {\n\t\tconnesso = true;\n\t}", "private void remplirPrestaraireData() {\n\t}", "@Override\r\n\tpublic void stehReagieren() {\r\n\t\t//\r\n\t}", "public void rebajoIngredientes() {\n }", "private void voidMethodDeclaratorRest(Modifier modify, MethodType x, ClassType object)\r\n {\r\n Scope scope = object.scope;\r\n\r\n x.parameter = formalParameters();\r\n if (nextSymbol == Keyword.THROWSSY)\r\n {\r\n lookAhead();\r\n x.throwing = qualidentList();\r\n }\r\n else\r\n x.throwing = new String[0];\r\n\r\n if (nextSymbol == Keyword.SEMICOLONSY)\r\n {\r\n if ((modify.cur & Keyword.NATIVESY.value) == 0)\r\n {\r\n if ( (x.modify & Keyword.ABSTRACTSY.value) == 0)\r\n error(\"missing modifier abstract\");\r\n\r\n if ( (modify.cur & modify.access) == 0)\r\n modify.add(Keyword.PUBLICSY.value);\r\n }\r\n\r\n x.scope = new Scope(scope, Scope.automatic, \"\");\r\n insertThis(object, x);\r\n lookAhead();\r\n }\r\n else\r\n {\r\n if ((x.modify & Keyword.ABSTRACTSY.value) == 0)\r\n {\r\n if ((x.modify & new Modifier().constructors) == 0)\r\n x.modify |= Keyword.PUBLICSY.value ;\r\n }\r\n\r\n Vector label = new Vector();\r\n label.add(Operation.newLabel() + \"\");\r\n x.scope = block(x, null, scope, label, Scope.MAIN, null, x.operation);\r\n }\r\n\r\n scope.declInsertOverload(x);\r\n }", "@Override\n\tpublic void redo() {\n\t\t\n\t}", "void scavenge();", "static void perform_rc(String passed){\n\t\tint type = type_of_rc(passed);\n\t\tswitch(type){\n\t\tcase 1:\n\t\t\treturn_when_carry(passed);\n\t\t\tbreak;\n\t\t}\n\t}", "protected Reaction() {/* intentionally empty block */}", "public void fecharRecursos() {\n\t\tRessourcesUtils.closeRessources(this.buffer);\n\t}", "@Override\n public void crearReloj() {\n Manecilla seg;\n seg = new Manecilla(40,60,0,1,null);\n cronometro = new Reloj(seg);\n }", "public void desactivarRecursos() {\n\r\n\t}", "public static void main(String[] args) {\n\t\tScanner teclado= new Scanner(System.in);\r\n\t\tchar letra\r\n\t\tSystem.out.printf(\"Introduzca un caracter\");\r\n\t\tletra=teclado.next().charAt(0);\r\n\t\twhile(letra!='*') {\r\n\t\t\t\r\n\t\t}\r\n\t}", "public void esperarRecogidaIngrediente(){\n enter();\n if ( ingredienteact != -1 )\n estanquero.await();\n leave();\n }", "public void printRecipt(){\n\n }", "public void selecao () {}", "public void mo21793R() {\n }", "public void snare();", "public void setRecommand(RequestParameter rp) {\n\t\tdao.boardSetRecommand(rp);\n\t}", "@Override\n public void redo() {\n\n }", "public void redo() {\n\t\tcmd = new RedoCommand(editor);\n\t\tinvoker = new MiniEditorInvoker(cmd);\n\t\tinvoker.action();\n\t}", "public void ganar() {\n // TODO implement here\n }", "public static void main(String[] args) {\n\t\tdoOperation(\"Ramya\", \"Add\");\r\n\t\tdoOperation(\"Ramya\", \"Replace\");\r\n\t\tdoOperation(\"Ramya\", \"Remove\");\r\n\t\tdoOperation(\"ramya\", \"Change\");\r\n\r\n\t}", "private String redact(String str)\n\t{\n\t\tStringBuilder r = new StringBuilder();\n\t\tfor(int i = 0; i < str.length(); i++)\n\t\t\tr.append(\"*\");\n\t\tString redacted = r.toString();\n\t\treturn redacted;\n\t}", "@Override\n\tpublic void alterar() {\n\t\t\n\t}", "public static void main(String[] args) {\n\t\tSystem.out.println(\"remove \"+OneEditAway(\"pale\",\"bae\"));\r\n\r\n\r\n\t}", "public static void reci(){\n\n GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(generatorBase, 1),\"XXX\", \"XXX\", \"XXX\", 'X', ItemHandler.ironHard));\n GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(generatorCombust, 1), \"XYX\", \"DFD\", \"XXX\", 'X', generatorBase, 'Y', \"gemDiamond\", 'D', \"dustRedstone\", 'F', Blocks.furnace));\n GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(tank, 1), \"XXX\", \"XYX\", \"XXX\", 'X', ItemHandler.ironHard, 'Y', \"blockGlass\"));\n GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(charcoalBlock, 1), \"CCC\", \"CCC\", \"CCC\", 'C', new ItemStack(Items.coal, 1, 1)));\n GameRegistry.addRecipe(new ShapelessOreRecipe(new ItemStack(Items.coal, 9, 1), new ItemStack(charcoalBlock)));\n }", "static void citajSveRedove(String imeFajla) {\n\n /* Radimo dokle god fajl nije prazan */\n while (!Svetovid.in(imeFajla).isEmpty()){\n\n /* Citamo ceo red */\n String red = Svetovid.in(imeFajla).readLine();\n\n /* Ispisujemo procitani red */\n Svetovid.out.println(red);\n\n }\n\n }", "public String redo() {\n/* 173 */ return redo(0, false);\n/* */ }", "public abstract void redo();", "private Celda rastrearAPacman() {\n // TODO implement here\n return null;\n }", "private void methodDeclaratorRest(Modifier modify, Type t, Token name, ClassType object)\r\n {\r\n modify.check(modify.methods | modify.access);\r\n MethodType x = member = new MethodType(modify.cur);\r\n\r\n x.comment = comment + '\\n';\r\n resetComment();\r\n\r\n x.type = t;\r\n returns = x.type;\r\n x.name = name;\r\n x.parameter = formalParameters();\r\n x.type.dim += bracketsOpt();\r\n\r\n if (nextSymbol == Keyword.THROWSSY)\r\n {\r\n lookAhead();\r\n x.throwing = qualidentList();\r\n }\r\n else\r\n x.throwing = new String[0];\r\n\r\n if (nextSymbol == Keyword.SEMICOLONSY)\r\n {\r\n if ((modify.cur & Keyword.NATIVESY.value) == 0)\r\n {\r\n if ( (object.modify & Keyword.ABSTRACTSY.value) == 0)\r\n error(\"missing modifier abstract\");\r\n\r\n if ( (modify.cur & modify.access) == 0)\r\n modify.add(Keyword.PUBLICSY.value);\r\n }\r\n\r\n x.scope = new Scope(object.scope, Scope.automatic, \"\");\r\n insertThis(object, x);\r\n lookAhead();\r\n }\r\n else\r\n {\r\n if ((object.modify & Keyword.ABSTRACTSY.value) == 0)\r\n {\r\n if ((x.modify & new Modifier().constructors) == 0)\r\n x.modify |= Keyword.PUBLICSY.value ;\r\n }\r\n\r\n Vector label = new Vector();\r\n label.add(Operation.newLabel() + \"\");\r\n x.scope = block(x, null, object.scope, label, Scope.MAIN, null, x.operation);\r\n }\r\n\r\n object.scope.declInsertOverload(x);\r\n \r\n member = null;\r\n }", "private static void concretizarRegisto(String nome, int escalao) {\n\t\tif (gestor.registarFuncionario(nome, escalao))\n\t\t\tSystem.out.println(\"REGISTO do funcionario \" + nome + \" com escalao \" + escalao);\n\t\telse \n\t\t\tSystem.out.println(\"ERRO: Nao foi possivel registar o funcionario \" + nome);\n\t}", "@Override\n\tpublic void chocoContraPared() {}", "public static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\n\t\tbyte opcao = 0;\n\t\tControleRemoto remoto = new ControleRemoto(new TV());\n\t\tdo {\n\t\t\tSystem.out.println(\"Selecione o comando (0 para sair)\");\n\t\t\tSystem.out.println(\"1 - Ligar/Desligar\");\n\t\t\tSystem.out.println(\"2 - Aumentar Volume\");\n\t\t\tSystem.out.println(\"3 - Abaixar Volume\");\n\t\t\topcao = sc.nextByte();\n\t\t\tswitch (opcao) {\n\t\t\tcase 1:\n\t\t\t\tremoto.pressLigDes();\n\t\t\t\tbreak;\n\t\t\tcase 2:\n\t\t\t\tremoto.pressAumVol();\n\t\t\t\tbreak;\n\t\t\tcase 3:\n\t\t\t\tremoto.pressAbxVol();\n\t\t\t\tbreak;\n\t\t\t}\n\t\t} while (opcao != 0);\n\t}", "public void imprimir() {\r\n NodoPila reco=raiz;\r\n System.out.println(\"Listado de todos los elementos de la pila:\");\r\n while (reco!=null) {\r\n System.out.print(reco.dato+\" \");\r\n reco=reco.sig;\r\n System.out.println();\r\n }\r\n System.out.println();\r\n }", "public void colorearSecuencial() {\n\t\t// Collections.shuffle(nodos);\n\t\tcolorearSecuencialAlternativo();\n\t}", "public void wild(){\n\t}", "private void sub() {\n\n\t}", "protected void pretragaGledalac() {\n\t\tString Gledalac=tfPretraga.getText();\r\n\r\n\t\tObject[]redovi=new Object[9];\r\n\t\tdtm.setRowCount(0);\r\n\t\t\r\n\t\tfor(Rezervacije r:Kontroler.getInstanca().vratiRezervacije()) {\r\n\t\t\tif(r.getImePrezime().toLowerCase().contains(Gledalac.toLowerCase())) {\r\n\t\t\t\r\n\t\t\t\tredovi[0]=r.getID_Rez();\r\n\t\t\t\tredovi[1]=r.getImePrezime();\r\n\t\t\t\tredovi[2]=r.getImePozorista();\r\n\t\t\t\tredovi[3]=r.getNazivPredstave();\r\n\t\t\t\tredovi[4]=r.getDatumIzvodjenja();\r\n\t\t\t\tredovi[5]=r.getVremeIzvodjenja();\r\n\t\t\t\tredovi[6]=r.getScenaIzvodjenja();\r\n\t\t\t\tredovi[7]=r.getBrRezUl();\r\n\t\t\t\tredovi[8]=r.getCenaUlaznica();\r\n\t\t\t\tdtm.addRow(redovi);\r\n\t\t\t\r\n\t\t\t}\r\n\t\t}\r\n\t\t\r\n\t}", "void atterir();", "public void modifierRdV() {\n\n }", "public void rescanRepository() { // recree les liste de classes connues a partir du depot\n // cette methode peut etre invoquee si on sait que le depot a ete modifie\n for (int i=0; i<types.length; i++) {\n classesDisponibles[i] = new HashMap<String, String>();\n scanRepository(types[i], classesDisponibles[i]);\n }\n }", "public void comprar() {\n }", "public static void main(String[]args){\n Carataker carataker=new Carataker();\n //el originator es el creador de los mementos\n Originator originator=new Originator();\n\n ConcreteObject concreteObject;\n\n concreteObject=new ConcreteObject(\"Doc\",\"Titulo\",\"Estado1\");\n originator.setState(concreteObject);\n\n concreteObject=new ConcreteObject(\"Doc\",\"Descripcion\",\"Estado2\");\n originator.setState(concreteObject);\n carataker.addMemento(originator.createMemento()); // [0] Primer estado\n\n concreteObject=new ConcreteObject(\"Doc\",\"Resumen\",\"Estado3\");\n originator.setState(concreteObject);\n\n concreteObject=new ConcreteObject(\"Doc\",\"Conclusion\",\"Estado4\");\n originator.setState(concreteObject);\n carataker.addMemento(originator.createMemento()); //[1] Segundo estado\n\n concreteObject=new ConcreteObject(\"Doc\",\"Bibliografia\",\"Estado5\");\n originator.setState(concreteObject);\n\n //recuperando o restaurando un estado\n\n originator.restoreFromMemento(carataker.getMemento(0));\n\n }", "private void processRelopCnd(int cnd)\n\t{\n\t\tCode.put(Code.jcc + cnd);\n\t\tCode.put2(7);\n\t\t\t\t\t\n\t\t// no: put 0, jmp next\n\t\tCode.loadConst(0);\n\t\tCode.put(Code.jmp);\n\t\tCode.put2(4);\n\t\t\t\t\t\n\t\t// yes: put 1\n\t\tCode.loadConst(1);\n\t\t\t\t\t\n\t\t// next\n\t}", "@Override\n\tpublic void emprestimo() {\n\n\t}", "@Test\n\t\tpublic void applyRecursivelyGoal() {\n\t\t\tassertSuccess(\" ;H; ;S; s ⊆ ℤ |- r∈s ↔ s\",\n\t\t\t\t\trm(\"\", ri(\"\", rm(\"2.1\", empty))));\n\t\t}", "@Override\n\tpublic void nadar() {\n\t\t\n\t}", "protected void restart()\r\n \t{\r\n \t\tspielen();\r\n \t}", "public void colorearSecuencialAlternativo() {\n\t\tint color;\n\t\tcantColores = 0;\n\t\tfor (int i = 0; i < cantNodos; i++) {\n\t\t\tcolor = 1;\n\t\t\t/** Mientras el color no se pueda usar, elijo otro color **/\n\t\t\twhile (!sePuedeColorear(i, color))\n\t\t\t\tcolor++;\n\n\t\t\tnodos.get(i).setColor(color);\n\n\t\t\tif (color > cantColores)\n\t\t\t\tcantColores = color;\n\t\t}\n\t}", "@Override\n\tpublic void rotiereNachRechts() {\n\n\t}", "public boolean reComentQna(int qna_index, String re_content);", "@ActionTrigger(action=\"QUERY_RECS\")\n\t\tpublic void spriden_QueryRecs()\n\t\t{\n\t\t\t\n\n\t\t\t\tSpridenAdapter spridenElement = (SpridenAdapter)this.getFormModel().getSpriden().getRowAdapter(true);\n\t\t\t\tSgbstdnAdapter sgbstdnElement = (SgbstdnAdapter)this.getFormModel().getSgbstdn().getRowAdapter(true);\n\t\t\t\tSovlcurAdapter sovlcurElement = (SovlcurAdapter)this.getFormModel().getSovlcur().getRowAdapter(true);\n\n\t\t\t\tif(spridenElement!=null && sgbstdnElement!=null && sovlcurElement!=null){\n\n\t\t\t\ttry { \n\t\t\t\t\tMessageServices.setMessageLevel(OracleMessagesLevel.decodeMessageLevel(5));\n\t\t\t\t// \n\t\t\t\tnextBlock();\n\t\t\t\t// soundex\n\t\t\t\tnextBlock();\n\t\t\t\t// spraddr \n\t\t\t\texecuteQuery();\n\t\t\t\tnextBlock();\n\t\t\t\t// sgbstdn \n\t\t\t\texecuteQuery();\n\t\t\t\tnextBlock();\n\t\t\t\t// sfbetrm \n\t\t\t\texecuteQuery();\n\t\t\t\t// execute the query on sovlcur and sovlfos \n\t\t\t\tgetFormModel().getSCurriculaSummary().setSummaryPidm(spridenElement.getSpridenPidm());\n\t\t\t\tgetFormModel().getSCurriculaSummary().setSummaryCode(SbCurriculumStr.fLearner());\n\t\t\t\tgetFormModel().getSCurriculaSummary().setSummaryKeySeqno(toNumber(99));\n\t\t\t\tgetFormModel().getSCurriculaSummary().setSummaryTermCode(sgbstdnElement.getSgbstdnTermCodeEff());\n\t\t\t\tgetFormModel().getSCurriculaSummary().setSummaryEndTerm(SbLearner.fQueryEnd(spridenElement.getSpridenPidm(), sgbstdnElement.getSgbstdnTermCodeEff()));\n\t\t\t\tif ( !sgbstdnElement.getSgbstdnTermCodeEff().isNull() )\n\t\t\t\t{\n\t\t\t\t\t// Create SOTVCUR since this is a learner curriculum \n\t\t\t\t\tSoklcur.pCreateSotvcur(/*pPidm=>*/getFormModel().getSCurriculaSummary().getSummaryPidm(), /*pTermCode=>*/getFormModel().getSCurriculaSummary().getSummaryTermCode(), /*pLmodCode=>*/getFormModel().getSCurriculaSummary().getSummaryCode());\n\t\t\t\t\t// Now execute the query on summary blocks \n\t\t\t\t\tgoBlock(\"SOVLCUR\");\n\t\t\t\t\texecuteQuery();\n\t\t\t\t\tif ( !sovlcurElement.getSummaryRowid().isNull() )\n\t\t\t\t\t{\n\t\t\t\t\t\tgoBlock(\"SOVLFOS\");\n\t\t\t\t\t\texecuteQuery();\n\t\t\t\t\t}\n\t\t\t\t\telse {\n\t\t\t\t\t\tgoBlock(\"SOVLFOS\");\n\t\t\t\t\t\tclearBlock();\n\t\t\t\t\t}\n\t\t\t\t\tgoBlock(\"SFBETRM\");\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tgoBlock(\"SOVLFOS\");\n\t\t\t\t\tclearBlock();\n\t\t\t\t\tgoBlock(\"SOVLCUR\");\n\t\t\t\t\tclearBlock();\n\t\t\t\t}\n\t\t\t\t// - sgbstdn term is not null \n\t\t\t\tgoBlock(\"SFBETRM\");\n\t\t\t\tpreviousBlock();\n\t\t\t\t// sgbstdn\n\t\t\t\tpreviousBlock();\n\t\t\t\t// spraddr\n\t\t\t\tpreviousBlock();\n\t\t\t\t// soundex \n\t\t\t\tpreviousBlock();\n\t\t\t\t// spriden \n\t\t\t\t// \n\t\t\t\t\n\t\t\t\t} finally {\n\t\t\t\t\t\t\t\n\t\t\t\t\tMessageServices.setMessageLevel(OracleMessagesLevel.decodeMessageLevel(0));\n\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t}\n\t\t}", "static void perform_rnc(String passed){\n\t\tint type = type_of_rnc(passed);\n\t\tswitch(type){\n\t\tcase 1:\n\t\t\treturn_not_carry(passed);\n\t\t\tbreak;\n\t\t}\n\t}", "Curso modificaCurso(Curso curso);", "public void asignarRaza(int raza);", "public boolean restarUno(){\n\t\tif (numero>0){\n\t\t\tnumero--;\n\t\t\treturn true;\n\t\t}\n\t\treturn false;\n\t}", "int recuperar(int c);", "@Override\n public void alRechazarOperacion() {\n }", "public void modificarCompraComic();", "@Override\n\tpublic void grabar() {\n\t\t\n\t}", "@Override\n\tpublic void comer() {\n\t\t\n\t}", "public void redoUndoneCommand() {\r\n // TODO: Fix me!!!\r\n try {\r\n char c=redo.pop();\r\n //redo.push(c);\r\n if(c=='c'){\r\n super.rotateClockwise();\r\n }\r\n if(c=='r'){\r\n super.rotateCounterClockwise();\r\n }\r\n if(c=='m'){\r\n super.moveForward();\r\n }\r\n } catch (Exception e) {\r\n System.out.println(e.getMessage());\r\n }\r\n }", "public void reiniciar() {\r\n\t\tauxiliar = primeira;//auxiliar recebe a primeira\r\n\t}", "void reactivarArticuloLeyMercado(Integer codigoCompania, String codigoArticulo, String userId) throws SICException;", "@Override\n public void comunicar() {\n System.out.println(\"miauuuu\");\n\n }", "public void act() \r\n {\r\n mueve();\r\n //tocaJugador();\r\n //bala();\r\n disparaExamen();\r\n }", "public void tornarFavorita(Conta contaFavorita) throws RNException{\n\t\tConta c = buscarFavorita(contaFavorita.getUsuario());\n\t\t\n\t\t\n\t\t// ALT + Shift + M\n\t\t\n\t\t//Caso encontre, deve-se \"desfavoritar\" a mesma\n\t\tif(c != null){\n\t\t\tc.setFavorita(false);\n\t\t\tsalvar(c);\n\t\t}\n\t\t\n\t\t// torna a conta que veio da tela como favorita\n\t\tcontaFavorita.setFavorita(true);\n\t\tsalvar(contaFavorita);\n\t}", "@Override\n\tpublic void swim() {\n\t\t\n\t}" ]
[ "0.5870402", "0.57050014", "0.56329936", "0.55781025", "0.5575355", "0.551042", "0.54667443", "0.5464711", "0.5405251", "0.53825605", "0.5379425", "0.53739953", "0.5326713", "0.5315851", "0.5302126", "0.5295466", "0.52702415", "0.52601105", "0.5215741", "0.5206391", "0.51875097", "0.5172534", "0.5164609", "0.5163955", "0.5150442", "0.51448154", "0.5119424", "0.5118876", "0.5102855", "0.5095627", "0.50949854", "0.5086551", "0.50797296", "0.5078521", "0.5077701", "0.50744957", "0.50708705", "0.5054608", "0.50431234", "0.50384486", "0.50381154", "0.50353575", "0.50278306", "0.502453", "0.5009544", "0.49907628", "0.49837416", "0.49738973", "0.4959433", "0.4953909", "0.4947602", "0.4945686", "0.49443835", "0.49441394", "0.4942231", "0.4931352", "0.4917756", "0.49079975", "0.4906542", "0.490408", "0.4903082", "0.49013296", "0.489652", "0.48909673", "0.48878965", "0.4878687", "0.48672023", "0.486441", "0.4858151", "0.48413852", "0.48395866", "0.48314667", "0.4828922", "0.48274136", "0.48266748", "0.4821992", "0.482151", "0.48208198", "0.48189276", "0.48187265", "0.48128366", "0.4812778", "0.48092076", "0.48074362", "0.48070344", "0.48044294", "0.47936943", "0.4780535", "0.47796994", "0.47790325", "0.4775803", "0.47736442", "0.476597", "0.4760847", "0.47586113", "0.4757888", "0.4756797", "0.47560528", "0.475485", "0.47434652" ]
0.5403372
9
Metodo "Multiplicar" llama al metodo nativo "MultiplicarC"
public double Multiplicar(double operador_1, double operador_2){ return MultiplicacionC(operador_1, operador_2); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void multiply() {\n\t\t\n\t}", "Multiply createMultiply();", "private void mul() {\n\n\t}", "private void multiplication()\n\t{\n\t\tFun = Function.MULTIPLY; //Function set to determine what action should be taken later.\n\t\t\n\t\t\tsetLeftValue();\n\t\t\tentry.grabFocus();\n\t\t\n\t}", "Multiplication createRandomMultiplication();", "Multiplication createRandomMultiplication();", "public static double multi() {\n System.out.println(\"Enter multiplier\");\n double a = getNumber();\n System.out.println(\"Enter multiplicand\");\n double b = getNumber();\n\n return a * b;\n }", "@Override\r\n\tpublic int mul() {\n\t\treturn 0;\r\n\t}", "public void enfoncerMult() {\n\t\ttry {\n\t\t\tthis.op = new Mult();\n\t\t\tif (!raz) {\n\t\t\t\tthis.pile.push(valC);\n\t\t\t}\n\t\t\tint a = this.pile.pop(); int b = this.pile.pop();\n\t\t\tthis.valC = this.op.eval(b,a);\n\t\t\tthis.pile.push(this.valC);\n\t\t\tthis.raz = true;\n\t\t}\n\t\tcatch (EmptyStackException e) {\n\t\t\tSystem.out.println(\"Erreur de syntaxe : Saisir deux operandes avant de saisir un operateur\");\n\t\t}\n\t}", "static void productoEscalarMatriz() {\r\n\r\n System.out.println(\"PRODUCTO ESCALAR X MATRIZ \\n\");\r\n setup(false);\r\n String valor = inputDialog(\"Inserte un escalar\", \"Escalar\", JOptionPane.INFORMATION_MESSAGE);\r\n int escalar = Integer.parseInt(valor);\r\n matrizA.productoEscalarMatriz(escalar);\r\n messageDialog(\"La matriz resultante al multiplicar por el escalar \" + escalar + \", es: \\n\" + matrizA.datosMatrizNumeros(), \"Producto escalar\", 3);\r\n\r\n }", "static void multiplier() throws IOException {\n\t\tScanner clavier = new Scanner(System.in);\n\t\tint nb1, nb2, resultat;\n\t\tnb1 = lireNombreEntier();\n\t\tnb2 = lireNombreEntier();\n\t\tresultat = nb1 * nb2;\n\t\tSystem.out.println(\"\\n\\t\" + nb1 + \" * \" + nb2 + \" = \" + resultat);\n\t}", "public Inatnum multiply(Inatnum a) {\n Inatnum zero = new zeronatnum(); // we need a new zero natural number for our res\n Inatnum res = zero;// this is our res value where we store our information, it needs to start at 0\n //INV: i>0 && i-1 <= this.getval() && res = a^(i) ==> i=this.getval()-(this.getval()z-1)\n for(int i = this.getVal(); i>0;i--) {// setting our i value to our this and if its greater than zero decrement by 1\n //INV: i>0 && i <= this.getval() && res = a^i ==> i=this.getval()-(this.getval()\n\t\t\tres = res.add(a);//now we save our res value as the previous res value plus a. we do this as many times as we are multiplying by. So if it is 3 times\n //INV: i>0 && i <= this.getval() && res = a^i ==> i=this.getval()-(this.getval()-1) \n \t\t\t//i-- => i = this.getval()-(this.getval()-1-1)\n \t\t\t //INV: i>0 && i-1 <= this.getval() && res = a^(i) ==> i=this.getval()-(this.getval()-1-1)\n \t\t\t //INV: i>0 && i-1 <= this.getval() && res = a^(i) ==> i=this.getval()-(this.getval()z-1) \n\t\t\t // 4 then we are adding 4 3 times\n }\n\t\t\t //INV: i<0 && i-1 < this.getval() ==> i ==0 && res = a^i ==> i=this.getval()\n //Termination Argument: i starts at this.getval(), i decrements each time through the loop\n\t\t\t\t\t\t return res;// we need to return our res value that holds our current value.\n }", "@Override\n\tpublic void visit(MultiplyNode node) {\n\t\tif (Evaluator.checkScope(node) == false) {\n\t\t\treturn;\n\t\t}\n\n\t\tif (Evaluator.checkAssert(node) == false) {\n\t\t\treturn;\n\t\t}\n\n\t\t/**\n\t\t * evaluam cei doi fii\n\t\t */\n\t\tEvaluator.evaluate(node.getChild(0));\n\t\tEvaluator.evaluate(node.getChild(1));\n\n\t\tInteger i, j;\n\t\t/**\n\t\t * salvam si inmultim valorile rezulate in urma evaluarii celor 2 fii si\n\t\t * setam valoarea corespunzatoare in nodul curent\n\t\t */\n\t\tif (node.getChild(1) instanceof Variable) {\n\t\t\ti = Integer.parseInt(Evaluator.variables.get(node.getChild(1).getName()));\n\n\t\t} else {\n\t\t\ti = Integer.parseInt(node.getChild(1).getName());\n\t\t}\n\n\t\tif (node.getChild(0) instanceof Variable) {\n\t\t\tj = Integer.parseInt(Evaluator.variables.get(node.getChild(0).getName()));\n\n\t\t} else {\n\t\t\tj = Integer.parseInt(node.getChild(0).getName());\n\t\t}\n\n\t\tInteger n = i * j;\n\n\t\tnode.setName(n.toString());\n\t}", "public int producto(){\r\n return x*y;\r\n }", "@Test\n public void testMultiplicar() {\n\tSystem.out.println(\"multiplicar\");\n\tdouble valor1 = 0.0;\n\tdouble valor2 = 0.0;\n\tCalculadora instance = new Calculadora();\n\tdouble expResult = 0.0;\n\tdouble result = instance.multiplicar(valor1, valor2);\n\tassertEquals(expResult, result, 0.0);\n\t// TODO review the generated test code and remove the default call to fail.\n\tfail(\"The test case is a prototype.\");\n }", "public static int multiply(int lafoot,int lapaki){\n\treturn 0;\n}", "public String multiply()\r\n {\r\n\r\n return First.multiply(Second).stripTrailingZeros().toString();\r\n }", "@Override\n\tpublic float multiplicar(float op1, float op2) {\n\t\treturn op1 * op2;\n\t}", "public int getProduct() {\n int a = 5;\n int b = 14;\n int c = a * b;\n return c;\n }", "@Override\r\n\tpublic int multi(int x, int y) {\n\t\treturn x * y;\r\n\t}", "public int mult()\r\n\t{\r\n\t\tint a=10;\r\n\t\tint b=20;\r\n\t\tint c = a*b;\r\n\t\treturn(c);\r\n\t}", "public FuncionMultiplicacion(String operador, int hijos) {\n super(operador, hijos);\n }", "@Override\r\n\tpublic void mul(int x, int y) {\n\t\t\r\n\t}", "abstract int multiplication(int num1, int num2);", "public DisparoJugador getMultiplicador(){\r\n\t\treturn nextLevel();\r\n\t}", "public Composite multiply(Composite comp) {\n\t\tif(comp.isUnit()){\n\t\t\treturn this;\n\t\t}\n\t\tif(this.isUnit()){\n\t\t\treturn comp;\n\t\t}\n\t\tNode head = comp.head;\n\t\tNode current_node = this.head;\n\t\t//long product = 1;\n\t\tBigInteger product = BigInteger.ONE;\n\t\twhile (current_node != null){\n\t\t\tlong factor = (long) Math.pow(current_node.factor, current_node.power);\n\t\t\tproduct = product.multiply(BigInteger.valueOf(factor));\n\t\t\tcurrent_node = current_node.next;\n\t\t}\n\t\twhile (comp.head != null){\n\t\t\tlong factor = (long)Math.pow(comp.head.factor, comp.head.power);\n\t\t\tproduct = product.multiply(BigInteger.valueOf(factor));\n\t\t\tcomp.head = comp.head.next;\n\t\t}\n\t\tComposite p = new Composite();\n\t\tNode n = new Node(product.longValue(), 1);\n\t\tp.head = n;\n\t\tcomp.head = head;\n\t\treturn p;\n\t}", "public AncientEgyptianMultiplication( ) {\r\n }", "int multiply (int a, int b) {\n\t\t//let me do it in one step\n\t\treturn a * b; \n\t\t\n\t\t\n\t}", "public void MUL( ){\n String tipo1 = pilhaVerificacaoTipos.pop().toString();\n String tipo2 = pilhaVerificacaoTipos.pop().toString();\n String val1 = dads.pop().toString();\n float fresult = -1;\n int iresult = -1;\n String val2 = dads.pop().toString();\n if(val1 != null && val2 != null){\n if (tipo1 != null && tipo2 != null){\n if(tipo1 == \"inteiro\" && tipo2 == \"real\"){\n fresult = Integer.parseInt(val1) * Float.parseFloat(val2);\n dads.push(fresult);\n pilhaVerificacaoTipos.push(\"real\");\n }else if(tipo1 == \"real\" && tipo2 ==\"inteiro\"){\n fresult = Integer.parseInt(val2) * Float.parseFloat(val1);\n dads.push(fresult);\n pilhaVerificacaoTipos.push(\"real\");\n }else if(tipo1 == \"real\" && tipo2 ==\"real\"){\n fresult = Float.parseFloat(val2) * Float.parseFloat(val1);\n dads.push(fresult);\n pilhaVerificacaoTipos.push(\"real\");\n }else if(tipo1 == \"inteiro\" && tipo2 ==\"inteiro\"){\n iresult = Integer.parseInt(val2) * Integer.parseInt(val1);\n dads.push(iresult);\n pilhaVerificacaoTipos.push(\"inteiro\");\n }\n else{\n mensagensErrosVM += \"\\nRUNTIME ERROR(1): essa instrução é válida apenas para valores inteiros ou reais.\";\n numErrVM += 1;\n return;\n }\n }else{\n mensagensErrosVM += \"\\nRUNTIME ERROR(2): não foi possível executar a instrução, tipo null encontrado.\";\n numErrVM += 1;\n return;\n }\n }else{\n mensagensErrosVM += \"\\nRUNTIME ERROR(3): não foi possível executar a instrução, valor null encontrado.\";\n numErrVM += 1;\n return;\n }\n\n\n\n topo += -1;\n ponteiro += 1;\n }", "public Vector3 times(Vector3 multiplicand) {\n\t\treturn new Vector3(multiplicand.x * this.x, multiplicand.y * this.y, multiplicand.z * this.z);\n\t}", "@Override\npublic void mul(int a, int b) {\n\t\n}", "protected void sequence_Multiplication(ISerializationContext context, Multi semanticObject) {\n\t\tif (errorAcceptor != null) {\n\t\t\tif (transientValues.isValueTransient(semanticObject, DslPackage.Literals.MULTI__LEFT) == ValueTransient.YES)\n\t\t\t\terrorAcceptor.accept(diagnosticProvider.createFeatureValueMissing(semanticObject, DslPackage.Literals.MULTI__LEFT));\n\t\t\tif (transientValues.isValueTransient(semanticObject, DslPackage.Literals.MULTI__RIGHT) == ValueTransient.YES)\n\t\t\t\terrorAcceptor.accept(diagnosticProvider.createFeatureValueMissing(semanticObject, DslPackage.Literals.MULTI__RIGHT));\n\t\t}\n\t\tSequenceFeeder feeder = createSequencerFeeder(context, semanticObject);\n\t\tfeeder.accept(grammarAccess.getMultiplicationAccess().getMultiLeftAction_1_0_0_0(), semanticObject.getLeft());\n\t\tfeeder.accept(grammarAccess.getMultiplicationAccess().getRightPrimaryExpressionParserRuleCall_1_1_0(), semanticObject.getRight());\n\t\tfeeder.finish();\n\t}", "public MecanismoMultiplicacionPrimo(int numPrimo)\n {\n super(numPrimo) ;\n\n }", "@Test\n public void testMultiplic() {\n System.out.println(\"multiplic\");\n float num1 = 0.0F;\n float num2 = 0.0F;\n float expResult = 0.0F;\n float result = Calculadora_teste.multiplic(num1, num2);\n assertEquals(expResult, result, 0.0);\n \n }", "@Test(priority=3)\n\n\tpublic void multiplicationTest() {\n\n\t\tandroidCalculator = new AndroidCalculator(driver);\n\n\t\tandroidCalculator.inputLeftAndRightFields(\"20\", \"10\");\n\t\tandroidCalculator.multiplication();;\n\n\t\tAssert.assertEquals(androidCalculator.verifyResult(), 20*10);\n\t}", "protected void sequence_Multiplication(ISerializationContext context, Div semanticObject) {\n\t\tif (errorAcceptor != null) {\n\t\t\tif (transientValues.isValueTransient(semanticObject, DslPackage.Literals.DIV__LEFT) == ValueTransient.YES)\n\t\t\t\terrorAcceptor.accept(diagnosticProvider.createFeatureValueMissing(semanticObject, DslPackage.Literals.DIV__LEFT));\n\t\t\tif (transientValues.isValueTransient(semanticObject, DslPackage.Literals.DIV__RIGHT) == ValueTransient.YES)\n\t\t\t\terrorAcceptor.accept(diagnosticProvider.createFeatureValueMissing(semanticObject, DslPackage.Literals.DIV__RIGHT));\n\t\t}\n\t\tSequenceFeeder feeder = createSequencerFeeder(context, semanticObject);\n\t\tfeeder.accept(grammarAccess.getMultiplicationAccess().getDivLeftAction_1_0_1_0(), semanticObject.getLeft());\n\t\tfeeder.accept(grammarAccess.getMultiplicationAccess().getRightPrimaryExpressionParserRuleCall_1_1_0(), semanticObject.getRight());\n\t\tfeeder.finish();\n\t}", "public final void mul() {\n\t\tif (size > 1) {\n\n\t\t\tdouble topMostValue = pop();\n\t\t\tdouble secondTopMostValue = pop();\n\t\t\tpush(secondTopMostValue * topMostValue);\n\t\t}\n\t}", "public void mul()\n\t{\n\t\t\n\t\tSystem.out.println(\"Hey I am in base class********** and addition is 2500\");\n\t}", "public static void main(String[] args) {\n\tComplex c1 = new Complex(1,2);\r\n\tComplex c2 = new Complex(-2,-1);\r\n\t\r\n\t//Calculates the product of c1 and c2\r\n\tComplex product_c1c2 = Complex.multiply(c1, c2);\r\n\tSystem.out.println(\"The product of c1 and c2 is: \"+product_c1c2);\r\n \t\r\n\t//Calculates the ratio of c1 to c2 (c1/c2)\r\n\tComplex ratio_c1c2 = Complex.divide(c1, c2);\r\n\tSystem.out.println(\"The ratio of c1 to c2 is: \"+ratio_c1c2);\r\n\t\r\n\t//Calculates the product of c1 and I\r\n\tComplex product_c1I = Complex.multiply(c1, Complex.I);\r\n\tSystem.out.println(\"The product of c1 and I is: \"+product_c1I);\r\n\t\r\n\t//Calculates the ratio of c1 to 0\r\n\tComplex ratio_c1Zero = Complex.divide(c1, Complex.Zero);\r\n\tSystem.out.println(\"The ratio of c1 and 0 is: \"+ratio_c1Zero);\r\n\t\r\n\t//Calculates the product of c1 with the conjugate of c1\r\n\tComplex c1_conj = Complex.conj(c1);\r\n\tComplex product_c1c1conj = Complex.multiply(c1,c1_conj);\r\n\tSystem.out.println(\"The product of c1 and c1* is: \"+product_c1c1conj);\r\n\t\r\n\t//Calculates the product of c1 with the conjugate of c1\r\n\tComplex c2_conj = Complex.conj(c2);\r\n\tComplex product_c2c2conj = Complex.multiply(c2,c2_conj);\r\n\tSystem.out.println(\"The product of c1 and c1* is: \"+product_c2c2conj);\r\n\t}", "public int multiply(int a,int b) throws RemoteException;", "abstract void mulS();", "public void multiply()\r\n {\r\n resultDoubles = Operations.multiply(leftOperand, rightOperand);\r\n resultResetHelper();\r\n }", "public double getProduct()\n {\n return first * second;\n }", "public void multiply(CubieCube multiplier) {\n multiplyTheCorners(multiplier);\n multiplyTheEdges(multiplier);\n }", "public static void main(String[] args) {\n\t\tint numeros[]=new int[150];\n\t\tint multiplica=Integer.parseInt(JOptionPane.showInputDialog(\"Que número quieres multiplicar\"));\n\t\tfor(int i=0;i<numeros.length;i++) {\n\t\t\tnumeros[i]=(int) Math.round((Math.random()*100));\n\t\t\tnumeros[i]=numeros[i]*multiplica;\n\t\t\tSystem.out.println(numeros[i]);\n\t\t}\n\t}", "@Override\r\n\tpublic int mul(int a,int b) {\n\t\treturn a*b;\r\n\t}", "public Parameter multiplyParameter(Parameter otherPram);", "public float setaMulta(int tempo){\n float multa_aux = valor_multa;\n for(int clk = 0; clk < tempo; clk++){\n multa_aux *= 1.1;\n }\n return multa_aux;\n }", "public Fraccion producto() {\r\n Fraccion producto = new Fraccion(operador1.getNumerador()*operador2.getNumerador() , operador1.getDenominador()*operador2.getDenominador());\r\n return simplify(producto);\r\n }", "public void mul(Complex c){\n\t\tdouble tempRe = re*c.getRe() - im*c.getIm();\n\t\tim = im*c.getRe() + re*c.getIm();\n\t\tre = tempRe;\n\t}", "private static void muta(Cromosoma c)\n\t{\n\t}", "public int getMultiplier() {\n return multiplier;\n }", "public void multiply(int value) {\r\n\t\ttotal *= value;\r\n\t\thistory += \" * \" + value;\r\n\t}", "@Test\n\tpublic void testMultiplication() {\n\t\tint tmpRndVal = 0;\n\t\tint tmpRndVal2 = 0;\n\t\tint tmpResult = 0;\n\t\t\n\t\t//testing with negative numbers\n\t\tfor (int i = 0; i < 5; i++) {\n\t\t\ttmpRndVal = RandomNegativeNumbers();\n\t\t\ttmpRndVal2 = RandomNegativeNumbers();\n\t\t\ttmpResult = tmpRndVal * tmpRndVal2;\n\t\t\tassertEquals(bc.multiplication(tmpRndVal, tmpRndVal2), tmpResult);\n\t\t}\n\t\t\n\t\t//testing with positive numbers\n\t\tfor (int i = 0; i < 5; i++) {\n\t\t\ttmpRndVal = RandomPositiveNumbers();\n\t\t\ttmpRndVal2 = RandomPositiveNumbers();\n\t\t\ttmpResult = tmpRndVal * tmpRndVal2;\n\t\t\tassertEquals(bc.multiplication(tmpRndVal, tmpRndVal2), tmpResult);\n\t\t}\n\t\t\n\t\t//testing with zero\n\t\tint zero = 0;\n\t\tint tmpVal = 7;\n\t\tfor (int i = 0; i < 5; i++) {\n\t\t\tassertTrue( ((bc.multiplication(tmpVal, zero) == zero) \n\t\t\t\t\t|| (bc.multiplication(zero, zero) == zero)\n\t\t\t\t\t|| (bc.multiplication(zero, tmpVal) == zero) ));\n\t\t}\n\t\t\n\t}", "public BigDecimal multiplyNumbers(List<Integer> numbers) throws Exception;", "public static void main(String[] args) {\n\t\tListNode a = new ListNode(3);\n\t\ta.setNext(new ListNode(2));\n\t\t\n\t\tListNode b = new ListNode(2);\n\t\t\n\t\tListNode res = multiply(a, b);\n\t\tres.printList(res);\n\t\t\n\t\t\n\t}", "public int multiplication(int a, int b) {\n return a * b;\n }", "public static NumberP Multiplication(NumberP first, NumberP second)\n {\n return OperationsManaged.PerformArithmeticOperation\n (\n first, second, ExistingOperations.Multiplication\n ); \t\n }", "Sum getMultiplier();", "public void multiply (int value) {\r\n\t\ttotal = total * value;\r\n\t\thistory = history + \" * \" + value;\r\n\t}", "public static UnitP Multiplication(UnitP first, UnitP second)\n {\n return OperationsPublic.PerformUnitOperation\n (\n first, second, Operations.Multiplication,\n OperationsOther.GetOperationString(first, second, Operations.Multiplication) \n );\n }", "public static void main(String[] args) {\n\n System.out.println(\"Tafel van 55 als variabel x:\");\n System.out.println();\n\n int x = 55;\n\n System.out.println(\"1 x \" + x + \" = \" + x);\n System.out.println(\"2 x \" + x + \" = \" + x*2);\n System.out.println(\"3 x \" + x + \" = \" + x*3);\n System.out.println(\"4 x \" + x + \" = \" + x*4);\n System.out.println(\"5 x \" + x + \" = \" + x*5);\n System.out.println(\"6 x \" + x + \" = \" + x*6);\n System.out.println(\"7 x \" + x + \" = \" + x*7);\n System.out.println(\"8 x \" + x + \" = \" + x*8);\n System.out.println(\"9 x \" + x + \" = \" + x*9);\n System.out.println(\"10 x \" + x + \" = \" + x*10);\n\n\n System.out.println();\n System.out.println(\"─────────────────────────────\");\n System.out.println();\n\n // Tafel van 13 als variabel a.\n\n System.out.println(\"Tafel van 13 als variabel a:\");\n System.out.println();\n\n int a = 13;\n int b = 1;\n int c = 1;\n\n System.out.println(b++ + \" x \" + a + \" = \" + a*c++);\n System.out.println(b++ + \" x \" + a + \" = \" + a*c++);\n System.out.println(b++ + \" x \" + a + \" = \" + a*c++);\n System.out.println(b++ + \" x \" + a + \" = \" + a*c++);\n System.out.println(b++ + \" x \" + a + \" = \" + a*c++);\n System.out.println(b++ + \" x \" + a + \" = \" + a*c++);\n System.out.println(b++ + \" x \" + a + \" = \" + a*c++);\n System.out.println(b++ + \" x \" + a + \" = \" + a*c++);\n System.out.println(b++ + \" x \" + a + \" = \" + a*c++);\n System.out.println(b + \" x \" + a + \" = \" + a*c);\n\n System.out.println();\n System.out.println(\"─────────────────────────────\");\n System.out.println();\n\n // Tafel van 22 als variabel d.\n\n System.out.println(\"Tafel van 22 als variabel d:\");\n System.out.println();\n\n int d = 22;\n int e = 1;\n\n System.out.println(e + \" x \" + d + \" = \" + d*e++);\n System.out.println(e + \" x \" + d + \" = \" + d*e++);\n System.out.println(e + \" x \" + d + \" = \" + d*e++);\n System.out.println(e + \" x \" + d + \" = \" + d*e++);\n System.out.println(e + \" x \" + d + \" = \" + d*e++);\n System.out.println(e + \" x \" + d + \" = \" + d*e++);\n System.out.println(e + \" x \" + d + \" = \" + d*e++);\n System.out.println(e + \" x \" + d + \" = \" + d*e++);\n System.out.println(e + \" x \" + d + \" = \" + d*e++);\n System.out.println(e + \" x \" + d + \" = \" + d*e);\n\n }", "public void multiplyTwoNumbers(int num1, int num2) {\n\t\t\n\t\tint product = num1*num2; //A\n\t\tSystem.out.println(\"**************************************************************\");\n\t\tSystem.out.println(\"Product of these 2 numbers is: \"+product);\n\t\tint remainder = getRemainder(num1, num2); //C\n\t\tint finalResult = product+remainder; //B\n\t\tSystem.out.println(\"Final Result of these 2 numbers is: \"+ finalResult);\n\t\n\t\t\n\t}", "public Matrix multiply(ComplexNumber cn) {\n\t\tMatrix a = copy();\n\t\tfor (int row = 0; row < a.M; row++) {\n\t\t\tfor (int col = 0; col < a.N; col++) {\n\t\t\t\ta.ROWS[row][col] = a.ROWS[row][col].multiply(cn);\n\t\t\t}\n\t\t}\n\t\treturn a;\n\t}", "public static void main(String[] args) {\n\n int a = 3, n = 4;\n\n int calculPutere = 1;\n\n for(int i = 0; i < n; i++){\n\n calculPutere *= a;\n }\n\n System.out.println(a+ \" la puterea \" + n + \" = \" + calculPutere);\n\n\n\n }", "public void mul() {\n //TODO: Fill in this method, then remove the RuntimeException\n throw new RuntimeException(\"RatPolyStack->mul() unimplemented!\\n\");\n }", "IVec3 mult(IVec3 v);", "BaseNumber multiply(BaseNumber operand);", "public static int mul(int value1, int value2){\r\n return value1 * value2;\r\n }", "public int multi(Integer x, Integer y) {\n\t\treturn x*y;\n\t}", "public void multiplication(View view)\n {\n tag=6;\n add.setVisibility(Button.INVISIBLE);\n sub.setVisibility(Button.INVISIBLE);\n mul.setVisibility(Button.INVISIBLE);\n div.setVisibility(Button.INVISIBLE);\n mainrelativelayout.setVisibility(RelativeLayout.VISIBLE);\n playagain(findViewById(R.id.mathsrelativeLayout));\n }", "public void ejercicio05() {\r\n\t\tcabecera(\"05\",\"\");\r\n\r\n\t\tint a=2, b=5, c=1; //Modificar los valores para realizar pruebas o leerlos por teclado\r\n\t\t\r\n\t\t// Ecuacion2Grado ecuacion=new Ecuacion2Grado(a,b,c);\r\n\t\t// Inicio modificacion\r\n\r\n\t\tSystem.out.println(\"Introduce el numero que multiplica a x²\");\r\n\t\ta = Teclado.readInteger();\r\n\t\tSystem.out.println(\"Introduce el numero que multiplica a x\");\r\n\t\tb = Teclado.readInteger();\r\n\t\tSystem.out.println(\"Introduce el termino independiente\");\r\n\t\tc = Teclado.readInteger();\r\n\r\n\t\tEcuacion2Grado ecuacion = new Ecuacion2Grado(a,b,c);\r\n\r\n\t\tSystem.out.println(ecuacion);\r\n\r\n // Fin modificacion\r\n\t}", "LengthScalarMultiply createLengthScalarMultiply();", "public static void main(String[] args) {\n\t\tint num, multiplicador;\n\t\tdo{\n\t\t\tSystem.out.println(\"Introduce el numero de inicio: \");\n\t\t\tnum=Consola.leeInt();\n\t\t}while (num<1);\n\t\tmultiplicador=num;\n\t\twhile (multiplicador>0) {\n\t\t\tSystem.out.print(num+\"\\t\");\n\t\t\tnum*=multiplicador;\n\t\t\tmultiplicador-=1;\n\t\t}\n\t}", "public void multiply(Object mulValue) {\r\n\r\n\t\tNumberOperation operator = new NumberOperation(this.value, mulValue) {\r\n\t\t\t\r\n\t\t\t@Override\r\n\t\t\tpublic Number doAnOperation() {\r\n\t\t\t\tTypeEnum typeOfResult = getFinalType();\r\n\t\t\t\tif(typeOfResult == TypeEnum.TYPE_INTEGER) {\r\n\t\t\t\t\treturn getO1().intValue() * getO2().intValue();\r\n\t\t\t\t}\r\n\t\t\t\telse {\r\n\t\t\t\t\treturn getO1().doubleValue() * getO2().doubleValue();\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t};\r\n\t\tthis.value = operator.doAnOperation();\r\n\t}", "public void testMultiply() {\r\n System.out.println(\"Multiply\");\r\n Double [][] n = new Double[][]{{-3., -2.5, -1., 0., 1., 2., 3.4, 3.5, 1.1E100, -1.1E100}, \r\n {-3., 2.5, 0., 0., 1., -2., 3., 3.7, 1.1E100, 1.1E100}, \r\n {9., -6.25, 0., 0., 1., -4., 10.2, 12.95, 1.21E200, -1.21E200}};\r\n for(int i = 0; i < 10; i++){\r\n Double x = n[0][i];\r\n Double y = n[1][i];\r\n double expResult = n[2][i];\r\n double result = MathOp.Multiply(x, y);\r\n assertEquals(expResult, result, 0.001);\r\n }\r\n }", "public T mul(T first, T second);", "@Override\r\n\tpublic int mulNo(int a, int b) {\n\t\treturn a*b;\r\n\t}", "public void multiply(double skalar) {\r\n for (int i = 0; i < matrix.length; i++) {\r\n for (int j = 0; j < matrix[0].length; j++) {\r\n matrix[i][j] *= skalar;\r\n }\r\n }\r\n }", "@Test\n\tpublic void testMultiplica2Enteros() {\n\t\tdouble resultado= Producto.multiplica2enteros(10, 10);\n\t\tdouble esperado= 100;\n\t\t\n\t\tassertEquals(esperado, resultado);\n\t}", "Double getMultiplier();", "public void multiply (int value) {\n\t\ttotal = total * value;\n\n\t\thistory = history + \" * \" + value;\n\t\t\n\t}", "public int product() {\n // You'll need to replace this code with something\n // else to make product() work; this is just to make\n // things compile while you work on sum()\n return 1;\n }", "float getCpMultiplier();", "void mult(int a, int b) {\n\t\tSystem.out.println(\"Addition \"+(a*b));\n}", "public int multiply(int number1, int number2)\n\t\tthrows CalculatorOperationException;", "public static void main(String[] args) {\n\n\t\n\n\t\tint num1;\n\t\tint cont;\n\t\tfinal int TOPE=10;\n\t\t\n\t\tScanner scan = new Scanner(System.in);\n\t\t\n\t\tSystem.out.println(\"Ingresa un numero: \");\n\t\tnum1=scan.nextInt();\n\t\t\n\t\tSystem.out.println(\"Ingrese un contador \");\n\t\tcont=scan.nextInt();\n\t\t\n\t\twhile (cont <=TOPE) {\n\t\t\tSystem.out.println(\"el valor de la multiplicación es: \" + cont*num1);\n\t\t\tcont++; \n\t\t\n\t}\n\t}", "public int Multipy(int x, int y, int y){\n\t\t\treturn x*y*z;\n\t}", "public static void main(String[] args) {\n\t\t final int NUMERO=1;\n\t\t\n\t\tfor(int i=1;i<=10;i++) {\n\t\t\tSystem.out.println(NUMERO+\"x\"+i+\"=\"+NUMERO*i);\n\t\t}\n\n\t}", "private String multiply(String strOP1, String strOP2) {\n if (log4j.isDebugEnabled())\n log4j.debug(\"CreateCashFlowStatement - multiply - strOP1 - \" + strOP1 + \" - strOP2 - \"\n + strOP2);\n BigDecimal op1 = new BigDecimal(strOP1);\n BigDecimal op2 = new BigDecimal(strOP2);\n op1 = op1.setScale(200);\n op2 = op2.setScale(200);\n String strResult = \"\";\n try {\n strResult = op1.multiply(op2).toString();\n } catch (Exception e) {\n e.printStackTrace();\n log4j.warn(\"Servlet CreateCashFlowStatement - multiply - Exception\");\n }\n return strResult;\n }", "int[][] multiple(int size) {\n\t\t size++; // наверняка пользователь захочет получить таблицу до того номера ВКЛЮЧИТЕЛЬНО, который укажет во входных параметрах\n\t\t int[][] mult = new int[size][size]; \n\t\t for (int i = 0; i < size; i++) {\n\t\t\t for (int j = 0; j < size; j++) {\n\t\t\t\t mult[i][j] = i * j;\n\t\t\t }\n\t\t }\n\t\t return mult;\n\t }", "public void multiply(Monom m){\r\n\t\tint temp_power = this.get_power();\r\n\t\tdouble temp_coaf = this.get_coefficient();\r\n\t\ttemp_power += m.get_power();\r\n\t\ttemp_coaf *= m.get_coefficient();\r\n\t\tthis.set_power(temp_power);\r\n\t\tthis.set_coefficient(temp_coaf);\r\n\t}", "public static int potencia(int x, int y){\r\n int potencia = x;\r\n if (y!=0){\r\n for (int i = 1; i<y; i++){\r\n potencia = potencia * x;\r\n }\r\n }else {\r\n potencia = 1;\r\n }\r\n return potencia;\r\n}", "public static void main(String[] args) {\n\t\t\n\t\tint[][] a = {{7,1,3}, {5,6,8}, {4,2,5}};\n\t\tint[][] b = {{7,10,2}, {3,5,1}, {6,2,4,}};\n\t\t\n\t\tif(a[0].length!=b.length) {\n\t\t\tSystem.out.println(\"Las matrices no pueden multiplicarse\");\n\t\t}\n\t\telse {\n\t\t\tSystem.out.println(\"Las matrices pueden multiplicarse\");\n\t\t\tSystem.out.println(\"Quiere multiplicarlas? S/N\");\n\t\t\tScanner sc = new Scanner(System.in);\n\t\t\tString opcion=sc.nextLine();\n\t\t\tif(opcion.equalsIgnoreCase(\"S\")) {\n\t\t\t\tint[][] resultado = new int[a.length][b[0].length];\n\t\t\t\tfor(int i=0; i<a.length; i++) {\n\t\t\t\t\tfor(int j=0; j<b.length; j++) {\n\t\t\t\t\t\tfor(int k=0; k<a[0].length; k++) {\n\t\t\t\t\t\t\tresultado[i][j] += a[i][k] * b[k][j];\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tsc.close();\n\t\t\t\t\n\t\t\t\tfor(int i=0; i<resultado.length; i++) {\n\t\t\t\t\tSystem.out.println(\"\\n\");\n\t\t\t\t\tfor(int j=0; j<resultado.length; j++) {\n\t\t\t\t\t\tSystem.out.print(\" \");\n\t\t\t\t\t\tSystem.out.print(resultado[i][j]);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\telse {\n\t\t\t\tSystem.out.println(\"Ejecución terminada. Muchas gracias\");\n\t\t\t}\n\t\t}\t\n\t\t\n\t}", "public ComplexNumber mul(ComplexNumber c) {\n\t\tdouble real = getReal() * c.getReal();\n\t\treal -= getImaginary() * c.getImaginary();\n\n\t\tdouble imaginary = getReal() * c.getImaginary();\n\t\timaginary += c.getReal() * getImaginary();\n\n\t\treturn new ComplexNumber(real, imaginary);\n\t}", "public int multiply(int a, int b) {\r\n\t\treturn a*b;\r\n\t}", "private static void directProd(DMatrixRMaj a, DMatrixRMaj b, DMatrixRMaj c) {\n for (int i=0; i<5; ++i) {\n for (int j=0; j<5; ++j) {\n c.unsafe_set(i, j, a.unsafe_get(i, 0)*b.unsafe_get(j, 0));\n }\n }\n }", "public static void main(String[] args) {\n\t\tSystem.out.println(multiply(\"2\", \"3\"));\r\n\t}", "public static void main(String[] args) {\n CPI cpi = new CPI();\r\n cpi.entra(3);\r\n cpi.entra(6);\r\n cpi.entra(4);\r\n cpi.resta();\r\n cpi.multiplica();\r\n cpi.entra(5);\r\n cpi.suma();\r\n System.out.println(\"Resultado \" + cpi.getResultado ());\r\n }", "public static OperationMBean getMultiplyOperationMBean()\n {\n return new Operation(\"multiply\");\n }" ]
[ "0.7506374", "0.7175932", "0.70310575", "0.6874879", "0.6748003", "0.6748003", "0.672602", "0.65796137", "0.6554585", "0.64401734", "0.64002776", "0.6373462", "0.6363856", "0.63091063", "0.6305955", "0.6295556", "0.62733334", "0.6257558", "0.62501544", "0.62424684", "0.6240705", "0.62224007", "0.62092453", "0.62083954", "0.6206201", "0.61942446", "0.6191216", "0.6095921", "0.60742384", "0.6069945", "0.60615546", "0.605593", "0.60494936", "0.59662837", "0.59660566", "0.5957315", "0.59334636", "0.59238064", "0.5893845", "0.58891195", "0.5884408", "0.5867522", "0.5866851", "0.5863204", "0.5829165", "0.58092433", "0.58049434", "0.5793091", "0.5792037", "0.578553", "0.57733774", "0.57696813", "0.5763701", "0.5750951", "0.5749624", "0.57419807", "0.5741071", "0.574017", "0.57344913", "0.57340676", "0.5732684", "0.57278633", "0.57269454", "0.57246226", "0.57221866", "0.57113004", "0.57056886", "0.5702514", "0.5699435", "0.5693104", "0.5680479", "0.56730163", "0.56656784", "0.56619227", "0.5659333", "0.56533337", "0.5652247", "0.56483823", "0.5646658", "0.56378895", "0.5637693", "0.5618435", "0.56119084", "0.56100184", "0.56012636", "0.55992997", "0.5596761", "0.5593945", "0.5591408", "0.5587526", "0.55767494", "0.5573872", "0.5572856", "0.5570631", "0.55660564", "0.55644894", "0.5564431", "0.5564313", "0.55601364", "0.5545134" ]
0.69945544
3
Metodo "Dividir" llama al metodo nativo "DividirC"
public double Dividir(double operador_1, double operador_2){ return DivisionC(operador_1, operador_2); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void enfoncerDiv() {\n\t\ttry {\n\t\t\tthis.op = new Div();\n\t\t\tif (!raz) {\n\t\t\t\tthis.pile.push(valC);\n\t\t\t}\n\t\t\tint a = this.pile.pop(); int b = this.pile.pop();\n\t\t\tthis.valC = this.op.eval(b,a);\n\t\t\tthis.pile.push(this.valC);\n\t\t\tthis.raz = true;\n\t\t}\n\t\tcatch (ArithmeticException e) {\n\t\t\tSystem.out.println(\"Erreur : Division par zero !\");\n\t\t}\n\t\tcatch (EmptyStackException e) {\n\t\t\tSystem.out.println(\"Erreur de syntaxe : Saisir deux operandes avant de saisir un operateur\");\n\t\t}\n\t}", "public abstract String division();", "public void dividirDineroGobierno() {\n\n double dineroDividible = super.getMundo().getGobierno().getCapitalEconomico() / 2;\n double dineroPorPersona = super.getMundo().contarPersonas();\n\n if (dineroDividible > 0) {\n\n super.getMundo().gobiernoDarDinero(dineroDividible);\n\n for (Persona p : super.getMundo().getListaDoctores())\n p.ganarDinero(dineroPorPersona);\n for (Persona p : super.getMundo().getListaCocineros())\n p.ganarDinero(dineroPorPersona);\n for (Persona p : super.getMundo().getListaAlbaniles())\n p.ganarDinero(dineroPorPersona);\n for (Persona p : super.getMundo().getListaHerreros())\n p.ganarDinero(dineroPorPersona);\n for (Persona p : super.getMundo().getListaCocineros())\n p.ganarDinero(dineroPorPersona);\n for (Persona p : super.getMundo().getListaDoctores())\n p.ganarDinero(dineroPorPersona);\n for (Persona p : super.getMundo().getListaCocineros())\n p.ganarDinero(dineroPorPersona);\n for (Persona p : super.getMundo().getListaAlbaniles())\n p.ganarDinero(dineroPorPersona);\n for (Persona p : super.getMundo().getListaHerreros())\n p.ganarDinero(dineroPorPersona);\n for (Persona p : super.getMundo().getListaCocineros())\n p.ganarDinero(dineroPorPersona);\n }\n }", "@Override\n\tpublic void div(double dx, double dy) {\n\t\t\n\t}", "IVec3 div(IVec3 v);", "private static void cajas() {\n\t\t\n\t}", "public void divide() {\n\t\t\n\t}", "public static void main(String[] args) {\n DivisoriNumero N = new DivisoriNumero();\n N.DimmiDivisori();\n }", "@Override\npublic void div(int a, int b) {\n\t\n}", "public String toString(){ return \"DIV\";}", "@Override\r\n\tpublic void div(int x, int y) {\n\t\t\r\n\t}", "public void setClaveDivisa(String claveDivisa) {\r\n this.claveDivisa = claveDivisa;\r\n }", "public double divisao (double numero1, double numero2){\n\t}", "public double dividir(int numerador, int denominador) throws DivisionPorCeroException {\n if(denominador == 0){\n throw new DivisionPorCeroException(\"El denominador no puede ser 0\");\n }\n return (double) numerador/denominador;\n }", "public String divorce() {\n MarriageRegister marriageRegister = marriageRegistrationService.getMarriageRegisterByIdUKey(idUKey, user,\n Permission.DIVORCE);\n if (marriageRegister != null && marriageRegister.getState() != MarriageRegister.State.EXTRACT_PRINTED) {\n addActionError(getText(\"error.marriageregister.invalidstate\"));\n return ERROR;\n } else {\n try {\n //TODO : refactor rename licensePrintedLocationId and licenseIssuedUserId in order to user this attribute for both notice and Extract print\n marriageRegistrationService.divorce(idUKey, comment, effectiveDateOfDivorce,\n MarriageRegister.State.DIVORCE, user);\n } catch (CRSRuntimeException e) {\n addActionError(getText(\"error.marriageregister.divorcefailed\"));\n return ERROR;\n }\n }\n addActionMessage(getText(\"message.marriageregister.divorced\"));\n return SUCCESS;\n }", "public void divide(int dirOp1, int dirOp2, int dirRes) {\n //traduce casos de direccionamiento indirecto\n dirOp1 = traduceDirIndirecto(dirOp1);\n dirOp2 = traduceDirIndirecto(dirOp2);\n if (ManejadorMemoria.isConstante(dirOp1)) { // OPERANDO 1 CTE\n String valor1 = this.directorioProcedimientos.getConstantes().get(dirOp1).getValorConstante();\n if (ManejadorMemoria.isGlobal(dirOp2)) { // OPERANDO 2 GLOBAL\n String valor2 = this.registroGlobal.getValor(dirOp2);\n if (ManejadorMemoria.isGlobal(dirRes)) { // RES GLOBAL\n this.registroGlobal.guardaValor(dirRes, auxOperacion(dirOp1, dirOp2, valor1, valor2, Codigos.DIV));\n } else { // RES LOCAL\n this.pilaRegistros.peek().guardaValor(dirRes, auxOperacion(dirOp1, dirOp2, valor1, valor2, Codigos.DIV));\n }\n } else if (ManejadorMemoria.isConstante(dirOp2)) { // OPERANDO 2 CTE\n String valor2 = this.directorioProcedimientos.getConstantes().get(dirOp2).getValorConstante();\n if (ManejadorMemoria.isGlobal(dirRes)) { // RES GLOBAL\n this.registroGlobal.guardaValor(dirRes, auxOperacion(dirOp1, dirOp2, valor1, valor2, Codigos.DIV));\n } else { // RES LOCAL\n this.pilaRegistros.peek().guardaValor(dirRes, auxOperacion(dirOp1, dirOp2, valor1, valor2, Codigos.DIV));\n }\n } else { // OPERANDO 2 LOCAL\n String valor2 = this.pilaRegistros.peek().getValor(dirOp2);\n if (ManejadorMemoria.isGlobal(dirRes)) { // RES GLOBAL\n this.registroGlobal.guardaValor(dirRes, auxOperacion(dirOp1, dirOp2, valor1, valor2, Codigos.DIV));\n } else { //RES LOCAL\n this.pilaRegistros.peek().guardaValor(dirRes, auxOperacion(dirOp1, dirOp2, valor1, valor2, Codigos.DIV));\n }\n }\n } else if (ManejadorMemoria.isGlobal(dirOp1)) { // OPERANDO 1 GLOBAL\n String valor1 = this.registroGlobal.getValor(dirOp1);\n if (ManejadorMemoria.isGlobal(dirOp2)) { // OPERANDO 2 GLOBAL\n String valor2 = this.registroGlobal.getValor(dirOp2);\n if (ManejadorMemoria.isGlobal(dirRes)) { // RES GLOBAL\n this.registroGlobal.guardaValor(dirRes, auxOperacion(dirOp1, dirOp2, valor1, valor2, Codigos.DIV));\n } else { // RES LOCAL\n this.pilaRegistros.peek().guardaValor(dirRes, auxOperacion(dirOp1, dirOp2, valor1, valor2, Codigos.DIV));\n }\n } else if (ManejadorMemoria.isConstante(dirOp2)) { // OPERANDO 2 CTE\n String valor2 = this.directorioProcedimientos.getConstantes().get(dirOp2).getValorConstante();\n if (ManejadorMemoria.isGlobal(dirRes)) { // RES GLOBAL\n this.registroGlobal.guardaValor(dirRes, auxOperacion(dirOp1, dirOp2, valor1, valor2, Codigos.DIV));\n } else { // RES LOCAL\n this.pilaRegistros.peek().guardaValor(dirRes, auxOperacion(dirOp1, dirOp2, valor1, valor2, Codigos.DIV));\n }\n } else { // OPERANDO 2 LOCAL\n String valor2 = this.pilaRegistros.peek().getValor(dirOp2);\n if (ManejadorMemoria.isGlobal(dirRes)) { // RES GLOBAL\n this.registroGlobal.guardaValor(dirRes, auxOperacion(dirOp1, dirOp2, valor1, valor2, Codigos.DIV));\n } else { // RES LOCAL\n this.pilaRegistros.peek().guardaValor(dirRes, auxOperacion(dirOp1, dirOp2, valor1, valor2, Codigos.DIV));\n }\n }\n } else { // OPERANDO 1 LOCAL\n String valor1 = this.pilaRegistros.peek().getValor(dirOp1);\n if (ManejadorMemoria.isGlobal(dirOp2)) { // OPERANDO 2 GLOBAL\n String valor2 = this.registroGlobal.getValor(dirOp2);\n if (ManejadorMemoria.isGlobal(dirRes)) { // RES GLOBAL\n this.registroGlobal.guardaValor(dirRes, auxOperacion(dirOp1, dirOp2, valor1, valor2, Codigos.DIV));\n } else { // RES 2 LOCAL\n this.pilaRegistros.peek().guardaValor(dirRes, auxOperacion(dirOp1, dirOp2, valor1, valor2, Codigos.DIV));\n }\n } else if (ManejadorMemoria.isConstante(dirOp2)) { // OPERANDO 2 CTE\n String valor2 = this.directorioProcedimientos.getConstantes().get(dirOp2).getValorConstante();\n if (ManejadorMemoria.isGlobal(dirRes)) { // RES GLOBAL\n this.registroGlobal.guardaValor(dirRes, auxOperacion(dirOp1, dirOp2, valor1, valor2, Codigos.DIV));\n } else { // RES LOCAL\n this.pilaRegistros.peek().guardaValor(dirRes, auxOperacion(dirOp1, dirOp2, valor1, valor2, Codigos.DIV));\n }\n } else { //OPERANDO 2 LOCAL\n String valor2 = this.pilaRegistros.peek().getValor(dirOp2);\n if (ManejadorMemoria.isGlobal(dirRes)) { // RES GLOBAL\n this.registroGlobal.guardaValor(dirRes, auxOperacion(dirOp1, dirOp2, valor1, valor2, Codigos.DIV));\n } else { // RES LOCAL\n this.pilaRegistros.peek().guardaValor(dirRes, auxOperacion(dirOp1, dirOp2, valor1, valor2, Codigos.DIV));\n }\n }\n }\n }", "@Override\n\tpublic void coba() {\n\t\t\n\t}", "@Override\n\tpublic void hacerDevolucion() {\n\t\tSystem.out.println(\"Hacer Devolucion pantalon\");\n\t}", "static void diviser() throws IOException {\n\t Scanner clavier = new Scanner(System.in);\n\tdouble nb1, nb2, resultat;\n\tnb1 = lireNombreEntier();\n\tnb2 = lireNombreEntier();\n\tif (nb2 != 0) {\n\tresultat = nb1 / nb2;\n\tSystem.out.println(\"\\n\\t\" + nb1 + \" / \" + nb2 + \" = \" +\n\tresultat);\n\t} else\n\tSystem.out.println(\"\\n\\t le nombre 2 est nul, devision par 0 est impossible \");\n\t}", "private void suono(int idGioc) {\n\t\tpartita.effettoCasella(idGioc);\n\t}", "@Override\r\n\tpublic void dormir() {\n\t\t\r\n\t}", "@Test\n public void testDividir() {\n\tSystem.out.println(\"dividir\");\n\tdouble valor1 = 0.0;\n\tdouble valor2 = 0.0;\n\tCalculadora instance = new Calculadora();\n\tdouble expResult = 0.0;\n\tdouble result = instance.dividir(valor1, valor2);\n\tassertEquals(expResult, result, 0.0);\n\t// TODO review the generated test code and remove the default call to fail.\n\tfail(\"The test case is a prototype.\");\n }", "public void decidiOrdine() {\n\r\n }", "public Arginfo visit(DivExpression n, Arginfo argu) {\n\t \t Arginfo _ret=null;\n\t int num=labelctr++;\n\t System.out.println(\"BEGIN\\nNOOP\\n RETURN DIV \");\n\t n.f0.accept(this, argu);\n\t n.f1.accept(this, argu);\n\t n.f2.accept(this, argu);\n\t \n\t System.out.println(\"\\nEND\\n\");\n\t return _ret;\n }", "public Fraccion division() {\r\n Fraccion division = new Fraccion(operador1.getNumerador()*operador2.getDenominador() , operador1.getDenominador()*operador2.getNumerador());\r\n return simplify(division);\r\n }", "public void eliminarCompraComic();", "@Override\r\n\tpublic void hacerSonido() {\n\t\tSystem.out.print(\"miau,miau -- o depende\");\r\n\t\t\r\n\t}", "public void prenderVehiculo();", "public void ejercicio04() {\r\n\t\tcabecera(\"04\", \"Suma, multiplicar, divisores\");\r\n\r\n\t\t// Inicio modificacion\r\n\t\t\r\n\t\tSystem.out.println(\"Introduce un numero\");\r\n\t\tint n1 = Teclado.readInteger();\r\n\r\n\t\tSystem.out.println(\"Introduce otro numero\");\r\n\t\tint n2 = Teclado.readInteger();\r\n\r\n\t\tSystem.out.println(\"¿Que quieres hacer?\");\r\n\t\tSystem.out.println(\"[1] - Sumar\");\r\n\t\tSystem.out.println(\"[2] - Multiplicar\");\r\n\t\tSystem.out.println(\"[3] - Divisores\");\r\n\r\n\t\tint respuesta = Teclado.readInteger();\r\n\r\n\t\tif (respuesta == 1) {\r\n\r\n\t\t\tint suma = n1+n2;\r\n\t\t\tSystem.out.println(\"La suma de los numeros es: \" + suma);\r\n\r\n\t\t}else if (respuesta == 2) {\r\n\r\n\t\t\tint multiplicacion = n1*n2;\r\n\t\t\tSystem.out.println(\"La multiplicacion de los numeros es: \" + multiplicacion);\r\n\r\n\t\t}else if (respuesta == 3) {\r\n\t\t\r\n\t\t\tif (n1%n2==0) {\r\n\t\t\t\tSystem.out.println(n1+\" es divisble por \"+n2);\r\n\t\t\t}\r\n\r\n\t\t\tif (n2%n1==0) {\r\n\t\t\t\tSystem.out.println(n2+\" es divisble por \"+n1);\r\n\t\t\t}\r\n\t\t\telse{\r\n\t\t\t\tSystem.out.println(\"Los numeros dados no son divisbles entre si.\");\r\n\t\t\t}\r\n\r\n\t\t}else{\r\n\r\n\t\t\tSystem.out.println(\"Opcion incorrecta\");\r\n\r\n\t\t}\r\n\t\t\r\n // Fin modificacion\r\n\t}", "public Divide(){\n }", "@Override\r\n\tpublic int div() {\n\t\treturn 0;\r\n\t}", "public void Ordenamiento() {\n\n\t}", "int division(int num1, int num2) {\n System.out.print(\"\\nIn Child Class : \");\n return num1 / num2;\n }", "public void comer(){\r\n\t\tSystem.out.println(\"He comido\");\r\n\t}", "private static void helloHelloModulo() {\n int a = 1;\n int b = 10;\n int c = 1 / 10;\n\n int d = 1 % 10;\n\n\n System.out.println(\" Result deleniya \" + c);\n System.out.println(\" Result deleniya \" + d);\n\n\n int делимое = 75;\n int делитель = 13;\n int f = делимое % делитель;\n\n int остаток = делимое - (делимое / делитель) * делитель;\n int j = 7 % 2;\n\n System.out.println(f);\n System.out.println(остаток);\n\n\n }", "@Override\n\tpublic void visit(Division arg0) {\n\t\t\n\t}", "public void ex() {\n int inches = 86; \n int pie = 12; //1 pie = 12 inches \n //Operaciones para obtener la cantidad de pies e inches\n int cant = inches / pie; \n int res = inches % pie;\n //Muestra de resultados\n System.out.println(inches + \" pulgadas es equivalente a\\n \" + \n cant + \" pies \\n \" + res + \" pulgadas \");\n }", "public void carroPulando() {\n\t\tpulos++;\n\t\tpulo = (int) (PULO_MAXIMO/10);\n\t\tdistanciaCorrida += pulo;\n\t\tif (distanciaCorrida > distanciaTotalCorrida) {\n\t\t\tdistanciaCorrida = distanciaTotalCorrida;\n\t\t}\n\t}", "@Override\n\tpublic void visit(Division arg0) {\n\n\t}", "public void cierraParentesisAction(ActionEvent event){\r\n cadena+=\")\";\r\n escribirHilera.setText(cadena); \r\n contadorParentesis-= 1;\r\n hileraNula.setDisable(false);\r\n concatenar.setDisable(false);\r\n hileraNoNula.setDisable(false);\r\n union.setDisable(false);\r\n finSecuencia.setDisable(true);\r\n abreParentesis.setDisable(true);\r\n cierraParentesis.setDisable(true);\r\n }", "public boolean eDentro(Casella c) { return eDentro(c.riga,c.colonna); }", "public void cocinar(){\n\n }", "@Override\n\tpublic float dividir(float op1, float op2) {\n\t\treturn op1 / op2;\n\t}", "public void gastarDinero(double cantidad){\r\n\t\t\r\n\t}", "@Override\r\n\tpublic void horario() {\n\t\t\r\n\t}", "void LienaDivisoria(){\r\n \t\r\n VerticalLayout LayoutLineaDivisoria = new VerticalLayout();\r\n LayoutLineaDivisoria.setWidth(\"1024px\");\r\n LayoutLineaDivisoria.setHeight(\"5px\");\r\n LayoutLineaDivisoria.setStyleName(EstiloCSS + \"LayoutLineaDicisoria\");\r\n layout.addComponent(LayoutLineaDivisoria, \"left: 0px; top: 450px;\"); \r\n\r\n }", "@Override\n\tpublic double dividir(double numerador, double denominador) throws ArithmeticException {\n\t\treturn 0;\n\t}", "public final void mDIV() throws RecognitionException\n\t{\n\t\ttry\n\t\t{\n\t\t\tfinal int _type = AshvmLexer.DIV;\n\t\t\tfinal int _channel = BaseRecognizer.DEFAULT_TOKEN_CHANNEL;\n\t\t\t// D:\\\\Programmieren\\\\projects\\\\ashvm\\\\Ashvm.g:714:5: ( 'div' )\n\t\t\t// D:\\\\Programmieren\\\\projects\\\\ashvm\\\\Ashvm.g:714:7: 'div'\n\t\t\t{\n\t\t\t\tthis.match(\"div\");\n\n\t\t\t}\n\n\t\t\tthis.state.type = _type;\n\t\t\tthis.state.channel = _channel;\n\t\t}\n\t\tfinally\n\t\t{\n\t\t}\n\t}", "void courir();", "public void jugar_con_el() {\n System.out.println(nombre + \" esta jugando contigo :D\");\n }", "public static void main(String[] args) {\n int primeiroNumero = 10; // Armazena o valor 10 para o primeiro número\n int segundoNumero = 2; // Armazena o valor 10 para o segundo número\n int resultado = 0; // Armazena do resultado da operação\n \n // Forma de adição\n resultado = primeiroNumero + segundoNumero;\n \n //Apresenta o resultado da adição\n System.out.printf(\"Resultado da adição = %d\\n\", resultado);\n \n \n // Forma de subtração\n resultado = primeiroNumero - segundoNumero;\n \n //Apresenta o resultado da subtração\n System.out.printf(\"Resultado da subtração = %d\\n\", resultado);\n \n \n // Forma de multiplicação\n resultado = primeiroNumero * segundoNumero;\n \n //Apresenta o resultado da multiplicação\n System.out.printf(\"Resultado da multiplicação = %d\\n\", resultado);\n \n \n // Forma de divisão\n resultado = primeiroNumero / segundoNumero;\n \n //Apresenta o resultado da divisão\n System.out.printf(\"Resultado da divisão = %d\\n\", resultado);\n \n \n // Forma de resto\n resultado = primeiroNumero % segundoNumero;\n \n //Apresenta o resultado do resto da divisão\n System.out.printf(\"Resultado do resto da divisão = %d\\n\", resultado);\n \n }", "public void brazoSubir( int presicion )\n {\n brazo.brazoSubir( presicion );\n }", "@Override\n public void comunicar() {\n System.out.println(\"miauuuu\");\n\n }", "@Override\r\n\tpublic void dibujar(Entorno ent, Coordenada c) {\n\t\tent.dibujarRectangulo(c.getX(), c.getY(), 20, 20, 0, Color.YELLOW);\r\n\t}", "public static void main(String[] args) {\n \n\t\tcalculatior input=new calculatior();\n\tSystem.out.println(input.div(15, 3));\t\n\t\t\n\t}", "public void div() {\n //TODO: Fill in this method, then remove the RuntimeException\n throw new RuntimeException(\"RatPolyStack->div() unimplemented!\\n\");\n }", "public Fraction divide( Fraction divisor ) {\n // Division ist genau wie multiplication aber in Kreuz\n // also, wir tauschen den numerator und den denomitanor aus, und\n // multiplizieren wie üblich\n Fraction upsideDown = new Fraction( divisor.denominator, divisor.numerator );\n Fraction result = this.multiply( upsideDown );\n\n return result;\n }", "public void nommerHeros() {\n\t\tSystem.out.println(\"\\nComment voulez vous appeler votre personnage ?\");\n\t\tthis.nom = Clavier.entrerClavierString();\n\t\tSystem.out.println(\"\\n*********Bienvenue dans le labyrinthe \" + getNom()+\"*********\");\n\t}", "public MovimientoPantallaCocina() {\n initComponents();\n \n //COLOCAR FONOD EN LA PANTALLA PARA LA COCINA\n try{\n pnlOrdenes.setBorder(new ImagenCocina());\n } catch (IOException e){\n Logger.getLogger(MovimientoPantallaCocina.class.getName()).log(Level.SEVERE, null, e);\n }\n \n //VISUALIZAR TODAS LAS ORDENES ACTIVAS\n hilo p = new hilo(\"ordenes\");\n p.start();\n }", "public int dividir(int a, int b) throws ExececaoCalculo{\n \n if(b==0){\n //ExececaoCalculo é uma class que esta nesse pacote atual\n throw new ExececaoCalculo(a, b);\n }\n return a/b;\n }", "public void duerme() {\n System.out.println(\"Duerme profundamentZzZzZz...\");\n }", "@Test(expected = ArithmeticException.class)\r\n\tpublic void testDivPorCero() {\r\n\t\tSystem.out.println(\" Ejecutando Test: testDivPorCero()\");\r\n\t\tint result = calc.div(5, 0);\r\n\t}", "public void hallarPerimetroEscaleno() {\r\n this.perimetro = this.ladoA+this.ladoB+this.ladoC;\r\n }", "@Override\n\tpublic void dibuja() {\n\t\t\n\t}", "public void imprimirSubdominios(String dominio,Pila pila){\n\t\t\tmodCons.imprimirSubdominios(dominio,pila);\n\t}", "public void abreParentesisAction(ActionEvent event){\r\n cadena+= \"(\";\r\n escribirHilera.setText(cadena);\r\n cierraParentesis.setDisable(true);\r\n hileraNula.setDisable(true);\r\n hileraNoNula.setDisable(true);\r\n concatenar.setDisable(true);\r\n union.setDisable(true);\r\n finSecuencia.setDisable(true);\r\n hilera.setVisible(true);\r\n aceptar.setDisable(false);\r\n contadorParentesis+= 1; \r\n aceptar.setDisable(false);\r\n }", "public void ciudad(){\n System.out.println(\"ciudad londres\");\n }", "@Override\n\tdouble dienTich() {\n\t\tdouble p = chuVi() / 2;\n\t\treturn Math.sqrt(p*(p-canhA)*(p-canhB)*(p-canhC));\n\t}", "private void division()\n\t{\n\t\tFun = Function.DIVIDE; //Function set to determine what action should be taken later.\n\t\t\n\t\t\tsetLeftValue();\n\t\t\tentry.grabFocus();\n\t\t\n\t}", "@Override\n\tpublic void DiminuirCarrinho(EntidadeDominio entidade) throws SQLException {\n\t\t\n\t}", "void eliminar(int c);", "public PanelMethodSEDN(Color fondo){\n super(fondo,\"Solucion Sistemas ED\");\n titulo_n = new JLabel(\"Num. de Div:\");\n setPanelDatos();\n setInformacion();\n setAllElements();\n calcular.addActionListener(this);\n limpiar.addActionListener(this);\n agregar.addActionListener(this);\n }", "@Override\r\n public void prenderVehiculo() {\r\n System.out.println(\"___________________________________________________\");\r\n System.out.println(\"prender Jet\");\r\n }", "@Override\n\tvoid geraDados() {\n\n\t}", "private void handleIndivisible() {\n\t\n}", "public Ej_varclase1() {\n\t\t//contador++; \n\t\tcontador = contador + 1;\n\t\t\n\t}", "private void aggiornaContiFiglioRicorsivamente(Conto contoPadre) {\n\t\tString methodName = \"aggiornaContiFiglioRicorsivamente\";\n\t\tcontoPadre.setDataInizioValiditaFiltro(this.conto.getDataInizioValidita());\n\t\t\n\t\tListaPaginata<Conto> contiFiglio = contoDad.ricercaSinteticaContoFigli(contoPadre, new ParametriPaginazione(0,Integer.MAX_VALUE));\n\t\tfor (Conto contoFiglio : contiFiglio) {\n\t\t\t\n\t\t\t//TODO aggiungere qui tutti i parametri da ribaltare sui conti figli.\n\t\t\tcontoFiglio.setAttivo(contoPadre.getAttivo()); //in analisi c'è solo questo parametro!\n\t\t\t\n\t\t\tif(isContoDiLivelloDiLegge()) {\n\t\t\t\tlog.debug(methodName, \"Conto di livello di legge: aggiorno tutti i campi del figlio \" + contoFiglio.getCodice());\n\t\t\t\t\n\t\t\t\t//TODO controllare eventuali altri parametri da ribaltare ai conti figlio.\n\t\t\t\tcontoFiglio.setElementoPianoDeiConti(contoPadre.getElementoPianoDeiConti());\n\t\t\t\tcontoFiglio.setCategoriaCespiti(contoPadre.getCategoriaCespiti());\n\t\t\t\tcontoFiglio.setTipoConto(contoPadre.getTipoConto());\n\t\t\t\tcontoFiglio.setTipoLegame(contoPadre.getTipoLegame());\n\t\t\t\tcontoFiglio.setContoAPartite(contoPadre.getContoAPartite());\n\t\t\t\tcontoFiglio.setContoDiLegge(contoPadre.getContoDiLegge());\n\t\t\t\tcontoFiglio.setCodiceBilancio(contoPadre.getCodiceBilancio());\n\t\t\t\tcontoFiglio.setContoCollegato(contoPadre.getContoCollegato());\n\t\t\t} else {\n\t\t\t\tlog.debug(methodName, \"Conto NON di livello di legge: aggiorno solo il flag Attivo del figlio \" + contoFiglio.getCodice());\n\t\t\t}\n\t\t\t\n\t\t\tcontoDad.aggiornaConto(contoFiglio);\n\t\t\tlog.debug(methodName, \"Aggiornato conto figlio: \"+ contoFiglio.getCodice());\n\t\t\taggiornaContiFiglioRicorsivamente(contoFiglio);\n\t\t}\n\t}", "public void DiezDias()\n {\n for (int i = 0; i < 10; i++) {\n UnDia();\n }\n }", "public void exibirJogo() {\n super.exibirJogo();\n System.out.println(\"Codigo do Jogo Digital: \" + codigo);\n }", "public void dibujar(){\n\t\tswitch(partida.getErrores()){\n\t\t\tcase 1:\n\t\t\t\tSystem.out.printf(\"\\n ______\\n | |\\n | ( )\\n |\\n |\\n |\\n |\\n__|__\\n\");\n\t\t\t\tbreak;\n\t\t\tcase 2:\n\t\t\t\tSystem.out.printf(\"\\n ______\\n | |\\n | ( )\\n | /\\n |\\n |\\n |\\n__|__\\n\");\n\t\t\t\tbreak;\n\t\t\tcase 3:\n\t\t\t\tSystem.out.printf(\"\\n ______\\n | |\\n | ( )\\n | / \\\\\\n |\\n |\\n |\\n__|__\\n\");\n\t\t\t\tbreak;\n\t\t\tcase 4:\n\t\t\t\tSystem.out.printf(\"\\n ______\\n | |\\n | ( )\\n | /|\\\\\\n |\\n |\\n |\\n__|__\\n\");\n\t\t\t\tbreak;\n\t\t\tcase 5:\n\t\t\t\tSystem.out.printf(\"\\n ______\\n | |\\n | ( )\\n | _/|\\\\\\n |\\n |\\n |\\n__|__\\n\");\n\t\t\t\tbreak;\n\t\t\tcase 6:\n\t\t\t\tSystem.out.printf(\"\\n ______\\n | |\\n | ( )\\n | _/|\\\\_\\n |\\n |\\n |\\n__|__\\n\");\n\t\t\t\tbreak;\n\t\t\tcase 7:\n\t\t\t\tSystem.out.printf(\"\\n ______\\n | |\\n | ( )\\n | _/|\\\\_\\n | _/\\n |\\n |\\n__|__\\n\");\n\t\t\t\tbreak;\n\t\t\tcase 8:\n\t\t\t\tSystem.out.printf(\"\\n ______\\n | |\\n | ( )\\n | _/|\\\\_\\n | _/ \\\\_\\n |\\n |\\n__|__\\n\");\n\t\t\t\tbreak;\n\t\t\tcase 9:\n\t\t\t\tSystem.out.printf(\"\\n ______\\n | |\\n | (x )\\n | _/|\\\\_\\n | _/ \\\\_\\n |\\n |\\n__|__\\n\");\n\t\t\t\tbreak;\n\t\t\tcase 10:\n\t\t\t\tSystem.out.printf(\"\\n ______\\n | |\\n | (x x)\\n | _/|\\\\_\\n | _/ \\\\_\\n |\\n |\\n__|__\\n\");\n\t\t\t\tbreak;\n\t\t\tdefault:\n\t\t\t\tSystem.out.printf(\"\\n ______\\n | |\\n |\\n |\\n |\\n |\\n |\\n__|__\\n\");\n\t\t\t\tbreak;\n\t\t}\n\t}", "@Override\n\tpublic Void visit(Div div) {\n\t\tprintIndent(div.token.getText());\n\t\tindent++;\n\t\tdiv.left.accept(this);\n\t\tdiv.right.accept(this);\n\t\tindent--;\n\t\treturn null;\n\t}", "public void draw() {\n background(0); // Color de Fondo - Negro\n // Se mencionan cada una de las funciones a utilizar en la class.\n a.movbolitas1(); // a.funcion es para las funciones principales.\n a.bolita2();\n a.movbolitas();\n a.bolita1();\n a.triangulo();\n a.triangulo1();\n c.movbolitas(); // c.funcion y m.funci\\u00f3n es para las mismas\n // funciones anteriores que se repetir\\u00e1n\n c.bolita1();\n c.movbolitas();\n c.bolita2();\n m.movbolitas();\n m.bolita1();\n m.movbolitas1();\n m.bolita2();\n a.circulos();\n}", "public void come(String comida) {\n System.out.println(\"Estoy comiendo \" + comida);\n }", "int getCedula();", "public DividirConta() {\n initComponents();\n }", "public static void dodavanjeBicikl() {\n\t\tString vrstaVozila = \"Bicikl\";\n\t\tString regBr = UtillMethod.unosRegBroj();\n\t\tGorivo gorivo = Main.nista;\n\t\tint brServisa = 1;\n\t\tdouble potrosnja100 = 0;\n\t\tSystem.out.println(\"Unesite broj km koje je vozilo preslo:\");\n\t\tdouble predjeno = UtillMethod.unesiteBroj();\n\t\tdouble preServisa = 700;\n\t\tdouble cenaServisa = 5000;\n\t\tSystem.out.println(\"Unesite cenu vozila za jedan dan:\");\n\t\tdouble cenaDan = UtillMethod.unesiteBroj();\n\t\tint brSedist = 1;\n\t\tint brVrata = 0;\n\t\tboolean vozObrisano = false;\n\t\tArrayList<Gorivo> gorivaVozila = new ArrayList<Gorivo>();\n\t\tgorivaVozila.add(gorivo);\n\t\tArrayList<Servis> servisiNadVozilom = new ArrayList<Servis>();\n\t\tBicikl vozilo = new Bicikl(vrstaVozila, regBr, gorivaVozila, brServisa, potrosnja100, predjeno, preServisa,\n\t\t\t\tcenaServisa, cenaDan, brSedist, brVrata, vozObrisano, servisiNadVozilom);\n\t\tUtillMethod.prviServis(vozilo, predjeno);\n\t\tMain.getVozilaAll().add(vozilo);\n\t\tSystem.out.println(\"Novo vozilo je uspesno dodato u sistem!\");\n\t\tSystem.out.println(\"--------------------------------------\");\n\t}", "public void iniciar(){\nSystem.out.println(\"El primer contador comenzara en el número 0\");\ncontador=0;\nSystem.out.println(\"El segundo contador comenzara en el número 100\");\ncontador2=100;}", "@Override\n\tpublic String getDivisionCode(final Integer divid, final Connection connection)\n\t{\n\t\tString divCode = null;\n\t\tfinal String sql = \"SELECT distinct BNDRY_NUM FROM EG_BOUNDARY where ID_BNDRY= ?\";\n\t\tif (LOGGER.isDebugEnabled())\n\t\t\tLOGGER.debug(\"Divisio code query-->>>>>>>> \" + sql);\n\t\ttry {\n\n\t\t\tQuery pst = persistenceService.getSession().createSQLQuery(sql);\n\t\t\tpst.setInteger(0, divid);\n\t\t\tList<Object[]> rset = pst.list();\n\t\t\tfor (final Object[] element : rset) {\n\t\t\t\tdivCode = element[0].toString();\n\t\t\t\tif (LOGGER.isDebugEnabled())\n\t\t\t\t\tLOGGER.debug(\"divCode >>>>>>>\" + divCode);\n\t\t\t}\n\n\t\t} catch (final HibernateException e)\n\t\t{\n\t\t\tLOGGER.error(\"Exp=\" + e.getMessage(), e);\n\t\t\tthrow new HibernateException(e.toString());\n\t\t}\n\t\treturn divCode;\n\t}", "public void inicio(){\n d.display(\"Para un calcular conversiones de grados Farenheit y Celsius\\n\"\n + \"o viceversa\");\n //System.out.println(\"Para un nadaro que ha ganado medallas en 5 competencias\");\n }", "public void Dios()\r\n {\r\n \tif(!dios)\r\n \t\tgrafico.cambiarA(0);\r\n \telse\r\n \t\tgrafico.cambiarA(1);\r\n dios=!dios;\r\n }", "public void mostrarCompra() {\n }", "@Override\n public String comer(String c)\n {\n c=\"Gato No puede Comer Nada\" ;\n \n return c;\n }", "separador(){\r\n uno = null;\r\n dos = null;\r\n tres = null;\r\n cero = null;\r\n }", "private void mostrarCoches() {\n int i = 0;\n for (Coche unCoche : coches) {\n System.out.println((i + 1) + \"º \" + coches.get(i));\n ++i;\n }\n }", "public void disparar(){}", "public static void divisores(int n){\n for(int i=1;i<=n;i++){\n if(n%i==0){System.out.println(i+\" es divisor\");}\n }\n }", "public static Solide octaedre (){\n\t\tPoint a = new Point(-25, 0,-25);\r\n\t\tPoint b = new Point(-25, 0,25);\r\n\t\tPoint c = new Point(25, 0,-25);\r\n\t\tPoint d = new Point(25,0,25);\r\n\t\t// La hauteur d'une des 2 pyramide vaut longueur d'un cote * (1/ racine de 2)\r\n\t\tfloat hauteur = (float) (50/Math.sqrt(2));\r\n\t\t// on se sert de la hauteur pour donnee les coordonees des sommets manquant\r\n\t\tPoint e = new Point(0, hauteur,0);\r\n\t\tPoint f = new Point(0,-hauteur,0);\r\n\r\n\r\n\t\tArrayList<Point> po = new ArrayList<Point>();\r\n\t\tArrayList<Arete> ar = new ArrayList<Arete>();\r\n\t\tArrayList<Face> lf = new ArrayList<Face>();\r\n\t\t\r\n\t\tPoint[][] pts = new Point[][] {\r\n\t\t\t{a, b, e}, \r\n\t\t\t{a, f, b}, \r\n\t\t\t{a, e, c},\r\n\t\t\t{a, c, f}, \r\n\t\t\t{d, c, e}, \r\n\t\t\t{d, f, c}, \r\n\t\t\t{b, d, e},\r\n\t\t\t{b, f, d}\r\n\t\t};\r\n\t\t\r\n\t\tfor (int i = 0; i < 8; i++) {\r\n\t\t\tFace h = new Face(ar);\r\n\t\t\tfor (int j = 0; j < 3; j++) {\r\n\t\t\t\tpo.add(pts[i][j]);\r\n\t\t\t}\r\n\t\t\th.face(po);\r\n\t\t\tpo.clear();\r\n\t\t\tlf.add(h);\r\n\t\t}\r\n\r\n\t\tSolide t= new Solide(lf);\r\n\t\treturn t;\r\n\t}", "public static void menu(){\n System.out.println(\"-Ingrese el número correspondiente-\");\n System.out.println(\"------------ Opciones -------------\");\n System.out.println(\"------------ 1. Sumar -------------\");\n System.out.println(\"------------ 2. Restar ------------\");\n System.out.println(\"------------ 3. Multiplicar -------\");\n System.out.println(\"------------ 4. Dividir -----------\");\n }", "@Listen(\"onClick =#diagnostico\")\n\tpublic void diagnostico() {\n\t\tString dir = \"gs/servicio/frm-diagnostico-catalogo.zul\";\n\t\tclearDivApp(dir);\n\t\t// Clients.evalJavaScript(\"document.title = 'ServiAldanas'; \");\n\t}", "int recuperar(int c);" ]
[ "0.66542476", "0.62016225", "0.6197841", "0.60190463", "0.600413", "0.5991229", "0.59847724", "0.5911996", "0.5847352", "0.5844856", "0.5835425", "0.5773032", "0.57527053", "0.5730644", "0.57055396", "0.56878096", "0.5687666", "0.5678029", "0.56776905", "0.564644", "0.5645865", "0.56141037", "0.56110454", "0.5594285", "0.5590239", "0.5572315", "0.556048", "0.55527896", "0.5549193", "0.55469686", "0.5534437", "0.5532304", "0.55134404", "0.5487472", "0.54805607", "0.5456194", "0.5455341", "0.5449703", "0.54477465", "0.54361284", "0.543241", "0.5427702", "0.5424217", "0.54235435", "0.54212195", "0.54173285", "0.5401879", "0.5397103", "0.5396182", "0.53864056", "0.53765213", "0.5366206", "0.5363633", "0.53618455", "0.5355603", "0.5327979", "0.53259724", "0.53172994", "0.53094935", "0.5306906", "0.5306429", "0.53012514", "0.5297182", "0.5296523", "0.52910477", "0.52820164", "0.5279943", "0.5274485", "0.5269455", "0.52693594", "0.5262006", "0.526163", "0.52585316", "0.5255957", "0.52511317", "0.52452993", "0.5241889", "0.5230605", "0.52238095", "0.5222887", "0.5217465", "0.5204727", "0.5202702", "0.51998746", "0.5197209", "0.51967955", "0.51950353", "0.51923263", "0.5190161", "0.51866776", "0.5183823", "0.5182304", "0.5171017", "0.5170452", "0.5164131", "0.516289", "0.5161939", "0.5161592", "0.5158952", "0.51540405" ]
0.61703175
3
Using binary search to effectively find the can of paint to buy
private static int findNeed(int currN) { int lo = 0, hi = shopList.length-1; while (lo < hi) { int mid = (lo + hi) / 2; if (shopList[mid] < currN) { lo = mid + 1; } else { hi = mid; } } return shopList[lo]; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "static int binSearch(int []arr,int key) {\n\t\tint start=0;\n\t\tint end=arr.length-1;\n\t\tdo {\n\t\t\tint pc=(start+end)/2;\n\t\t\tif(arr[pc]==key) {\n\t\t\t\treturn pc;\n\t\t\t}else if(arr[pc]<key) {\n\t\t\t\tstart=pc+1;\n\t\t\t}else\n\t\t\t\tend=pc-1;\n\t\t}while(start<=end);\n\t\t\n\t\treturn -1;\n\t}", "abstract int binSearch(int[] array, int num, int left, int right);", "private static int bSearch(int[] elements, int key) {\n int left = 0, right = elements.length - 1, mid = 0;\n while (left <= right) {\n mid = (left + right) / 2;\n\n if (key < elements[mid]) {\n right = mid - 1;\n } else if (key == elements[mid]) {\n return mid;\n } else {\n left = mid + 1;\n }\n }\n return -1;\n }", "public boolean find(int key){\r\n int BB = 0,BA = nElemen-1;\r\n boolean search = true;\r\n while(search){\r\n int mid = (BA+BB)/2;\r\n if(arr[mid]==key){\r\n search = false;\r\n return true;\r\n }else if (BB>BA){\r\n break;\r\n }else{\r\n if(arr[mid]<key){\r\n BB = mid + 1;\r\n }else{\r\n BA = mid - 1;\r\n }\r\n }\r\n }\r\n return false;\r\n }", "private static boolean checkHalfway(int[] arr, int searchValue, int begin, int end) {\r\n\t\treturn searchValue < arr[(begin+end+1)/2];\r\n\t}", "public static int binSearch(int[] a, int x) {\r\n int l = 0;\r\n int r = a.length;\r\n while (l != r) {\r\n // inv: l <= res <= r\r\n int m = (l + r) / 2;\r\n if (a[m] >= x) {\r\n r = m;\r\n }\r\n else {\r\n l = m + 1;\r\n }\r\n }\r\n return r;\r\n }", "private int checkBook(FlatShelf b) {\n\n\tIterator<Map.Entry<String, Integer>> tags = b.enumerateTags()\n\t\t.iterator();\n\t// Iterator<Map.Entry<String, String>> properties =\n\t// b.enumerateProperties();\n\n\t// InputPairSet inputPairs = new InputPairSet(); // neuron # -> weight\n\n\tdouble[] inputValues = new double[numTags];\n\n\twhile (tags.hasNext()) {\n\t Map.Entry<String, Integer> tag = tags.next();\n\t // System.out.println(\"tags: \" + tag.getKey() + \" : \" +\n\t // tag.getValue());\n\t Integer current = idPairs.get(tag.getKey());\n\t if (current == null) {\n\t\t// current = idPairs.get(OTHER);\n\t\t// inputValues[current.getValue()] += tag.getValue();\n\t } else\n\t\tinputValues[current] = tag.getValue();\n\n\t // inputPairs.add(new InputPair(current.getValue(),\n\t // (double)tag.getValue()));\n\n\t}\n\n\tNeuralData book = new BasicNeuralData(inputValues);\n\tfinal NeuralData output = brain.compute(book);\n\n\tdouble best = Double.MIN_VALUE;\n\n\tfor (int i = 0; i < numShelfs; ++i)\n\t best = Math.max(best, output.getData(i));\n\n\tint index = -1;\n\tfor (int i = 0; i < numShelfs; ++i)\n\t if (best == output.getData(i))\n\t\tindex = i;\n\n\treturn index;\n }", "int binarySearch(int[] arr, int low, int high, int key){\n while(low <= high){\n int mid = (low + high) / 2;\n if (key < arr[mid])\n high = mid - 1;\n else if (key > arr[mid])\n low = mid + 1;\n else\n return mid;\n }\n return -1;\n }", "private static int binary_Search(int[] arr, int target) {\n\n\t\tint low = 0;\n\t\tint high = arr.length - 1;\n\n\t\twhile (low <= high) {\n\n\t\t\tint mid = low + (high - low) / 2;\n\t\t\tSystem.out.println(\"low = \" + low + \" mid = \" + mid + \" high =\" + high);\n\t\t\tif (arr[mid] == target) {\n\t\t\t\treturn mid;\n\t\t\t}\n\t\t\tif (arr[mid] < target) {\n\t\t\t\tlow = mid + 1;\n\n\t\t\t} else {\n\t\t\t\thigh = mid - 1;\n\t\t\t}\n\n\t\t\t// System.out.println(\"low = \" + low + \" high =\" + high);\n\t\t}\n\t\treturn -1;\n\t}", "static int findPos(int []arr, int key)\n\t{\n\t\tint low=0, high =1;\n\t\tint val =arr[0];\n\t\t\n\t\twhile(val<key)\n\t\t{\n\t\t\tlow= high; //// store previous high check that 2*h doesn't exceeds array length to prevent ArrayOutOfBoundException\n\t\t\tif (2*high < arr.length -1)\n\t\t\t\thigh =2*high;\n\t\t\telse\n\t\t\t\thigh =arr.length -1;\n\t\t\t\n\t\t\tval = arr[high];\n\t\t}\n\t\treturn binarySearch(arr,low,high,key);\n\t}", "public void search() {\n while (!done) {\n num2 = mNums.get(cntr);\n num1 = mSum - num2;\n\n if (mKeys.contains(num1)) {\n System.out.printf(\"We found our pair!...%d and %d\\n\\n\",num1,num2);\n done = true;\n } //end if\n\n mKeys.add(num2);\n cntr++;\n\n if (cntr > mNums.size()) {\n System.out.println(\"Unable to find a matching pair of Integers. Sorry :(\\n\");\n done = true;\n }\n } //end while\n }", "private static int binary_search(int[] array, int num, int low, int high) {\n\t\t\n\t\treturn -1;\n\t}", "public static int binSearch(int[] a, int first, int last, int key)\n\t{\t\n\t\tif(first <= last)\n\t\t{\n\t\t\tint mid = (first + last) / 2; //Divides the beginning of the array and the length of the array into 2\n\t\t\t\n\t\t\tif (a[mid] == key)\n\t\t\t{\n\t\t\t\treturn mid; \n\t\t\t}\n\t\t\t\n\t\t\telse if (a[mid] > key) //IF THE INDEX(WHICH IS THE MID) OF ARRAY A IS GREATER THAN THE KEY\n\t\t\t{\n\t\t\t\treturn last = mid - 1; //RETURNS THE LENGTH OF THE ARRAY WHICH IS THE DECREMENTED MID\n\t\t\t}\n\t\t\t\n\t\t\telse //IF THE INDEX(WHICH IS THE MID) OF ARRAY A IS LESS THAN THE KEY\n\t\t\t{\n\t\t\t\treturn first = mid + 1; //RETURNS THE FIRST = INCREMENTED MID\t\t\n\t\t\t}\n\t\t}\n\t\treturn -1;\t\n\t}", "private int findEntry(long msb, long lsb) {\n\n int lowIndex = 0;\n int highIndex = index.remaining() / 24 - 1;\n float lowValue = Long.MIN_VALUE;\n float highValue = Long.MAX_VALUE;\n float targetValue = msb;\n\n while (lowIndex <= highIndex) {\n int guessIndex = lowIndex + Math.round(\n (highIndex - lowIndex)\n * (targetValue - lowValue)\n / (highValue - lowValue));\n int position = index.position() + guessIndex * 24;\n long m = index.getLong(position);\n if (msb < m) {\n highIndex = guessIndex - 1;\n highValue = m;\n } else if (msb > m) {\n lowIndex = guessIndex + 1;\n lowValue = m;\n } else {\n // getting close...\n long l = index.getLong(position + 8);\n if (lsb < l) {\n highIndex = guessIndex - 1;\n highValue = m;\n } else if (lsb > l) {\n lowIndex = guessIndex + 1;\n lowValue = m;\n } else {\n // found it!\n return position;\n }\n }\n }\n\n // not found\n return -1;\n }", "@Override\n\tpublic int has(Comparable value) {\n\t\t\n\t\tint lowerBound = 0;\n\t\tint upperBound = currentIndex - 1;\n\t\tint current;\n\t\t\n\t\twhile (true) {\n\t\t\t\n\t\t\tcurrent = (lowerBound + upperBound) / 2;\n\t\t\t\n\t\t\tif (array[current].equalsWith(value)) {\n\t\t\t\t//element is successfully found\n\t\t\t\treturn current;\n\t\t\t} else if (lowerBound > upperBound) {\n\t\t\t\t// not found\n\t\t\t\treturn -1;\n\t\t\t} else {\n\t\t\t\t\n\t\t\t\tif (array[current].lessThan(value)) {\n\t\t\t\t\tlowerBound = current + 1; //in higher half\n\t\t\t\t} else {\n\t\t\t\t\tupperBound = current - 1; //in lower half\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t}\n\t\t\n\t}", "public static int binSearchRotatedIter(int src[], int lo, int hi, int target){\n\n while(lo<=hi){\n int mid = lo + (hi-lo)/2;\n if(src[mid]==target) return mid;\n //if bottom half is sorted\n if(src[lo]<=src[mid]){\n \n if(src[lo]<=target && target<src[mid]){\n hi=mid-1;\n }else{\n lo=mid+1;\n }\n }\n //if upper half is sorted\n else{\n if(src[mid]<target && target<=src[hi]){\n lo=mid+1;\n }else{\n hi=mid-1;\n }\n }\n }\n return -1;\n}", "public static int binarySearch(int[] list, int key) {\n int low = 0;\n int high = list.length - 1;\n \n while (high >= low) {\n int mid = (low + high) / 2;\n if (key < list[mid])\n high = mid - 1;\n else if (key == list[mid])\n return mid;\n else\n low = mid + 1;\n }\n return -1 - 1; // now high < low, key not found\n }", "public static void main(String[] args) {\n\n int[] arr = {45,63,78,92,110};\n int search = 110;\n\n\n boolean toggle = true;\n int start = 0;\n int end = arr.length - 1;\n\n while (toggle) {\n int mid = (start + end) / 2;\n if (arr[mid] == search) {\n System.out.println(mid);\n toggle = false;\n } else {\n if (arr[mid] < search) {\n start = mid + 1;\n } else {\n end = mid - 1;\n }\n }\n }\n\n }", "private int binarySearch(List<Span> spans, int line) {\n int left = 0,right = spans.size() - 1,mid,row;\n int max = right;\n while(left <= right){\n mid = (left + right) / 2;\n if(mid < 0) return 0;\n if(mid > max) return max;\n row = spans.get(mid).getLine();\n if(row == line) {\n return mid;\n }else if(row < line){\n left = mid + 1;\n }else{\n right = mid - 1;\n }\n }\n return Math.max(0,Math.min(left,max));\n }", "public static int search(int[] nums, int target) {\n int low=0;\n int high=nums.length-1;\n int middle=(high+low)>>1;\n\n for(int i=0;i<nums.length;i++){\n int num = nums[middle];\n if(target>num){\n low=middle+1;\n middle=(high+low)>>1;\n }else if(target<num){\n high=middle-1;\n middle=(high+low)>>1;\n } else{\n return middle;\n }\n\n }\n\n return -1;\n }", "public static Boolean binarySearch(int[] arr, int n){\r\n if(arr.length == 0) return false;\r\n if(arr.length == 1 && arr[0] != n) return false; \r\n if(arr.length == 1 && arr[0] == n) return true; \r\n int start = 0;\r\n int mid = arr.length/2;\r\n int end = arr.length;\r\n int pos = mid;\r\n while(arr[pos] != n){\r\n if(n > arr[pos]){\r\n start = mid;\r\n mid = (end-start)/2+start;\r\n } else if(n < arr[pos]){\r\n end = mid;\r\n mid = (end-start)/2+start;\r\n System.out.println(\"here \" + start+ \" \" + mid + \" \" + end + \" pos= \" + pos);\r\n }\r\n pos = mid;\r\n if(arr[pos] == n) return true;\r\n if(start+1 == end){\r\n System.out.println(start+ \" \" + mid + \" \" + end + \" pos= \" + pos);\r\n return false;\r\n }\r\n }\r\n return true;\r\n}", "public boolean search(int[] nums, int target) {\n if (nums == null || nums.length == 0) return false;\n int l = 0;\n int r = nums.length - 1;\n int m;\n while (l <= r) {\n m = (l + r) / 2; \n if (nums[m] == target) return true;\n int low, high;\n if (nums[m] >=nums[l]) {\n if(nums[m] == nums[l]){\n l++;\n }\n else{\n if (nums[l] <= target && target < nums[m]) {\n r = m - 1;\n }\n else {\n l = m + 1;\n }\n }\n }\n else {\n if (nums[m] == nums[r]){\n r--;\n } \n else{\n if (nums[m] < target && target <= nums[r]) {\n l = m + 1;\n }\n else {\n r = m - 1;\n }\n }\n }\n }\n return false;\n }", "private int binarySearchByIndex(List<Span> spans, int index){\n int left = 0,right = spans.size() - 1,mid,row;\n int max = right;\n while(left <= right){\n mid = (left + right) / 2;\n if(mid < 0) return 0;\n if(mid > max) return max;\n row = spans.get(mid).startIndex;\n if(row == index) {\n return mid;\n }else if(row < index){\n left = mid + 1;\n }else{\n right = mid - 1;\n }\n }\n int result = Math.max(0,Math.min(left,max));\n while(result > 0) {\n if(spans.get(result).startIndex > index) {\n result--;\n }else{\n break;\n }\n }\n while(result < right) {\n if(getSpanEnd(result,spans) < index) {\n result++;\n }else{\n break;\n }\n }\n return result;\n }", "static int binarySearchHelp(int[] array, int searched) {\n\t\tint mid = array.length / 2;\r\n\t\tint first = 0;\r\n\t\tint last = array.length - 1;\r\n\r\n\t\twhile (array[mid] != searched && first <= last) {\r\n\t\t\tmid = (first + last) / 2;\r\n\t\t\tif (searched == array[mid]) {\r\n\t\t\t\treturn mid;\r\n\t\t\t}\r\n\t\t\tif (searched < array[mid]) {\r\n\t\t\t\tlast = mid - 1;\r\n\r\n\t\t\t}\r\n\t\t\tif (searched > array[mid]) {\r\n\t\t\t\tfirst = mid + 1;\r\n\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\treturn -1;\r\n\t}", "private boolean isFound(int remaingingMarbles) {\n\n return (Math.log(remaingingMarbles) / Math.log(2)) % 1 == 0 ;\n\n }", "@Test\n\tpublic void testBinarySearch() {\n\t\tint[] arr0 = {0, 1, 2, 3, 4, 5};\n\t\tassertEquals(0, _01_BinarySearch.binarySearch(arr0, 0, arr0.length - 1, 0));\n\t\tassertEquals(1, _01_BinarySearch.binarySearch(arr0, 0, arr0.length - 1, 1));\n\t\tassertEquals(2, _01_BinarySearch.binarySearch(arr0, 0, arr0.length - 1, 2));\n\t\tassertEquals(3, _01_BinarySearch.binarySearch(arr0, 0, arr0.length - 1, 3));\n\t\t\n\t\tassertEquals(-1, _01_BinarySearch.binarySearch(arr0, 0, arr0.length - 1, 99));\n\t\t\n\t\tint[] arr1 = {0, 43, 209, 388, 401, 599};\n\t\tassertEquals(2, _01_BinarySearch.binarySearch(arr1, 0, arr0.length - 1, 209));\n\t\tassertEquals(-1, _01_BinarySearch.binarySearch(arr1, 0, arr0.length - 1, 45));\n\t}", "private static int binarySearchMine(int[] data, int target, int low, int high) {\n while (low <= high) {\n int median = (low + high) / 2;\n int current = data[median];\n if (current == target) {\n return median;\n } else if (target < current) {\n return binarySearchMine(data, target, low, median - 1);\n } else {\n return binarySearchMine(data, target, median + 1, high);\n }\n }\n return -1;\n }", "private int search(Bitboard board, int posMask, int turn) {\n // if this player doesn't even \"own\" any connected components, they're in bad shape...\n if (!ownerToCCs.containsKey(turn)) {\n return 100;\n }\n\n // perform basic BFS to explore the connected component\n // we're finding distance to an \"owned\" connected component\n int target = ownerToCCs.get(turn);\n int orthogonal, nextMask, altDist;\n int myVisit = 0;\n\n searchQueue.clear();\n prev.clear();\n dist.clear();\n\n searchQueue.add(posMask);\n dist.put(posMask, 0);\n\n while (!searchQueue.isEmpty()) {\n // get next position off of queue\n posMask = searchQueue.poll();\n\n // ignore if visited, invalid location, or opponent owns\n if ((myVisit & posMask) != 0 || !board.isValid(posMask)\n || board.owns(posMask, 1 - turn))\n continue;\n myVisit |= posMask;\n\n // check if it's a target\n if ((target & posMask) != 0) {\n // return distance to posMask\n return dist.get(prev.get(posMask)) + 1;\n }\n\n // continue BFS\n orthogonal = BitMasks.orthogonal.get(posMask);\n while (orthogonal != 0) {\n nextMask = orthogonal & ~(orthogonal - 1);\n orthogonal ^= nextMask;\n\n altDist = dist.get(posMask) + 1;\n if (altDist < dist.getOrDefault(nextMask, Integer.MAX_VALUE)) {\n prev.put(nextMask, posMask);\n dist.put(nextMask, altDist);\n }\n searchQueue.add(nextMask);\n }\n }\n // no path found to a target (the circle is isolated)\n return 100;\n }", "public int Search(int key)\n {\n for(int i=0; i<n; i++)\n {\n if(a[i]==key)\n return 1;\n }\n return 0;\n }", "public int getIndex(int start) {\n int left = 0;\r\n int right = bookings.size()-1;\r\n while (left <= right) {\r\n int mid = left + (right-left)/2;\r\n if (bookings.get(mid).start == start) {\r\n return mid;\r\n }\r\n else if (bookings.get(mid).start < start) {\r\n left = mid+1;\r\n }\r\n else {\r\n right = mid-1;\r\n }\r\n }\r\n return right;\r\n }", "private static int search(int[] arr, int n, int x, int k) {\n\t\tint i = 0;\n\t\twhile (i < n) {\n\n\t\t\t// If x is found at index i\n\t\t\tif (arr[i] == x)\n\t\t\t\treturn i;\n\n\t\t\t// Jump the difference between\n\t\t\t// current array element and x\n\t\t\t// divided by k We use max here\n\t\t\t// to make sure that i moves\n\t\t\t// at-least one step ahead.\n\t\t\ti = i + Math.max(1, Math.abs(arr[i] - x) / k);\n\n\t\t}\n\n\t\tSystem.out.println(\"number is not\" + \" present!\");\n\n\t\treturn -1;\n\t}", "public int searchCyc(int[] nums) {\n int lo = 0;\n int hi = nums.length - 1;\n\n while (lo < hi) {\n int mid = (lo + hi) / 2;\n if (nums[mid] > nums[hi]) {\n lo = mid + 1;\n } else { //\n hi = mid;\n }\n }\n\n //Loop ends when left == right\n return lo;\n}", "@Test\n\tpublic void testBinarySearch() {\n\t\tint[] numbers = {0, 1, 2, 3, 4, 5, 6};\n\t\tint r1 = _01_BinarySearch.binarySearch(numbers, 0, numbers.length - 1, 4);\n\t\tassertEquals(4, r1);\n\t\t\n\t\tint[] numbers2 = {2, 4, 7, 9, 14};\n\t\tint r2 = _01_BinarySearch.binarySearch(numbers2, 0, numbers2.length - 1, 8);\n\t\tassertEquals(-1, r2);\n\t\t\n\t\tint[] numbers3 = {3, 5, 10, 16, 25};\n\t\tint r3 = _01_BinarySearch.binarySearch(numbers3, 0, numbers3.length - 1, 25);\n\t\tassertEquals(4, r3);\n\t\t\n\t}", "public Integer binSearch(Integer target, Integer[] data, Integer left, Integer right) {\n if (right - left == 1) {\n if (data[left] == target) return left;\n if (data[right] == target) return right;\n }\n if (right - left == 0) {\n if (data[left] == target) return left;\n }\n Integer midpt = (right + left) / 2 ;\n if (target == data[midpt]) return midpt ;\n if (target > data[midpt] ) return binSearch(target, data, midpt, right) ;\n if (target < data[midpt] ) return binSearch(target, data, left, midpt) ;\n\n return -1;\n }", "int contains(int pgNum, int clock, char act)\r\n {\r\n for(int i = 0; i <size; i++)\r\n if(pm[i][0]==pgNum)\r\n {\r\n pm[i][1] = clock;\r\n pm[i][2] = act=='W' ? 1 : 0;\r\n return i;\r\n }\r\n\r\n return -1;\r\n }", "private boolean checkGreedyDefense() {\r\n return enTotal.get(2)+1 < myTotal.get(2) && enTotal.get(0)+1 < myTotal.get(0);\r\n }", "@Override\r\n\t\r\n\t\r\n\t\r\n\tpublic int[] locate(int target) {\r\n\t\tint low = 0; \r\n\t\tint high = length()- 1;\r\n\t\t\r\n\t\twhile ( low <= high) {\r\n\t\t\tint mid = ((low + high)/2);\r\n\t\t\tint value = inspect(mid,0);\r\n\t\t\t\t\t\r\n\t\t\tif ( value == target) {\r\n\t\t\t\treturn new int[] {mid,0};\r\n\t\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t\t\t\t\r\n\t\t\t\t}\r\n\t\t\telse if (value < target) {\r\n\t\t\t\tlow = mid +1;\r\n\t\t\t\t}\r\n\t\t\telse {\r\n\t\t\t\thigh = mid -1;\r\n\t\t}\r\n\t\t\r\n\t}\r\n\t\treturn binarySearch(high, target);\r\n\t}", "private static int binarySearch0_BranchFreeUnrolledStatic16(int[] a, int key) {\n\t\tint low = 8;\n\t\tint midVal;\n\t\tint highMask;\n\n\t\tmidVal = a[low];\n\t\tlow += 4;\n\t\thighMask = (int) (((long) key - midVal) >> 63);\n\t\tlow -= 8 & highMask;\n\n\t\tmidVal = a[low];\n\t\tlow += 2;\n\t\thighMask = (int) (((long) key - midVal) >> 63);\n\t\tlow -= 4 & highMask;\n\n\t\tmidVal = a[low];\n\t\tlow += 1;\n\t\thighMask = (int) (((long) key - midVal) >> 63);\n\t\tlow -= 2 & highMask;\n\n\t\tmidVal = a[low];\n\t\thighMask = (int) (((long) key - midVal) >> 63);\n\t\tlow -= 1 & highMask;\n\n\t\treturn a[low] == key ? low : -(low + 1);\n\n\t}", "private int locate (List<Integer> list, int hash) {\n\t\tif (list.size() == 0) {\n\t\t\treturn 0;\n\t\t}\n\n\t\tint index_a = -1;\n\t\tint index_b = list.size();\n\t\tfloat value_a = (float)list.get(index_a+1);\n\t\tfloat value_b = (float)list.get(index_b-1);\n\t\tfloat hash_float = (float)hash;\n\n\t\tif (hash <= value_a) {\n\t\t\treturn 0;\n\t\t}\n\t\tif (hash > value_b) {\n\t\t\treturn list.size();\n\t\t}\n\n\t\twhile (index_b - index_a > 1) {\n\t\t\tint index_mid = index_a+(int)((float)(index_b-index_a)*(hash_float-value_a)/(value_b-value_a));\n\t\t\tif (index_mid == index_a) {\n\t\t\t\tindex_mid++;\n\t\t\t} else if (index_mid == index_b) {\n\t\t\t\tindex_mid--;\n\t\t\t}\n\t\t\tif (hash >= list.get(index_mid)) {\n\t\t\t\tindex_a = index_mid;\n\t\t\t\tvalue_a = list.get(index_a);\n\t\t\t} else {\n\t\t\t\tindex_b = index_mid;\n\t\t\t\tvalue_b = list.get(index_b);\n\t\t\t}\n\t\t}\n\t\tif (hash == list.get(index_a)) {\n\t\t\treturn index_a;\n\t\t}\n\t\treturn index_b;\n\t}", "public int binarySearch(int[] nums, int target) {\n // write your code here\n if (nums == null || nums.length == 0) return -1;\n int start = 0, end = nums.length - 1;\n while (start + 1 < end) {\n int mid = start + (end - start) / 2;\n if (nums[mid] == target) {\n end = mid;\n }\n else if (nums[mid] < target) {\n start = mid;\n }\n else {\n end = mid;\n }\n }\n if (nums[start] == target) return start;\n if (nums[end] == target) return end;\n return -1;\n }", "public int binarySearchRotated(int [] nums) {\n\t\tint n = nums.length;\n\t\tint low = 0;\n\t\tint high = n -1;\n\t\twhile(low <= high) {\n\t\t\tif(nums[low] <= nums[high]) return low;\n\t\t\tint mid = (low + high) >> 1;\n\t\t\tint next = (mid + 1) % n;\n\t\t\tint prev = (mid - 1) % n;\n\t\t\tif(nums[mid] <= nums[next] && nums[mid] <= nums[prev]) return mid;\n\t\t\telse if(nums[mid] <= nums[high]) high = mid-1;\n\t\t\telse if(nums[mid] >= nums[low]) low = mid+1;\n\t\t}\n\t\t\n\t\treturn -1;\n\t\t\n\t}", "@SuppressWarnings(\"unchecked\") // stops Java complaining about the call to compare\n private int findIndexOf(Comparable<E> item) {\n if (count == 0) { //this is where the binary search happens that reduces the time and computational power it takes to search the collection\n return count; // if count == 0 it returns the count variable to break the loop and show that the collection is empty\n }\n int low = 0; //Sets up three variables to keep track of the start and end values of index and the middle of the collection, this helps\n int high = count - 1; //the search algorithm becase the array always knows where the middle is and so the collection can contnually half using the three\n int mid; //variables to find a single value, while the low is less or equal to the high variable,\n while (low <= high) {\n\n mid = (low + high) / 2;\n\n int compareValue = item.compareTo(data[mid]); // the value we are trying to find\n if (compareValue == 0) return mid; //returns the middle value,\n if (compareValue > 0) low = mid + 1; //if greater than it changes low value to equal the middle, plus one(as mid is already checked)\n else high = mid - 1; //else it changes to the lower half of the collecton to search there.\n }\n return low; //Hopefully if found it will then return low,\n }", "int binarySearch(int arr[], int x)\n {\n int l = 0, r = arr.length - 1;\n while (l <= r) {\n int m = l + (r - l) / 2;\n\n // Check if x is present at mid\n if (arr[m] == x)\n return m;\n\n // If x greater, ignore left half\n if (arr[m] < x)\n l = m + 1;\n\n // If x is smaller, ignore right half\n else\n r = m - 1;\n }\n\n // if we reach here, then element was\n // not present\n return -1;\n }", "private void checkStench(int top, int left, int bottom, int right) {\n\t\tif (top > height - 1) {\n\t\t\ttop = height - 1;\n\t\t}\n\t\tif (bottom < 0) {\n\t\t\tbottom = 0;\n\t\t}\n\t\tif (left < 0) {\n\t\t\tleft = 0;\n\t\t}\n\t\tif (right > width - 1) {\n\t\t\tright = width - 1;\n\t\t}\n\t\tboolean stench = false;\n\t\tfor (int i = bottom; i <= top; i++) {\n\t\t\tfor (int j = left; j <= right; j++) {\n\t\t\t\tstench = false;\n\t\t\t\tif (i > 0) {\n\t\t\t\t\tSet s = (Set) agentPositions.get(new Point(i - 1, j));\n\t\t\t\t\tfor (Iterator it = s.iterator(); it.hasNext(); ) {\n\t\t\t\t\t\tif (it.next() instanceof Wumpus) {\n\t\t\t\t\t\t\tstench = true;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tif (i < width - 1) {\n\t\t\t\t\tSet s = (Set) agentPositions.get(new Point(i + 1, j));\n\t\t\t\t\tfor (Iterator it = s.iterator(); it.hasNext(); ) {\n\t\t\t\t\t\tif (it.next() instanceof Wumpus) {\n\t\t\t\t\t\t\tstench = true;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tif (j > 0) {\n\t\t\t\t\tSet s = (Set) agentPositions.get(new Point(i, j - 1));\n\t\t\t\t\tfor (Iterator it = s.iterator(); it.hasNext(); ) {\n\t\t\t\t\t\tif (it.next() instanceof Wumpus) {\n\t\t\t\t\t\t\tstench = true;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tif (j < height - 1) {\n\t\t\t\t\tSet s = (Set) agentPositions.get(new Point(i, j + 1));\n\t\t\t\t\tfor (Iterator it = s.iterator(); it.hasNext(); ) {\n\t\t\t\t\t\tif (it.next() instanceof Wumpus) {\n\t\t\t\t\t\t\tstench = true;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tif (stench) {\n\t\t\t\t\tif (!checkImage(i, j, STENCH_FILE)) {\n\t\t\t\t\t\taddImage(i, j, STENCH_FILE, STENCH_FILE);\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\tif (checkImage(i, j, STENCH_FILE)) {\n\t\t\t\t\t\tremoveImage(i, j, STENCH_FILE);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}", "static void check(int arr[],int sum)\r\n {\r\n boolean binmap[] = new boolean[max]; /* by default this is array of false as {false,false,false,false,......,false} */\r\n for(int i=0;i<arr.length;i++)\r\n {\r\n int temp=sum-arr[i];\r\n if(temp>0 && binmap[temp]){ /* in condition , we can use binmap[temp] which means binmap[temp]==true */\r\n System.out.println(\"two numbers in given array whose sum is equal to given sum are :\"+temp+ \" and \" +arr[i]);\r\n }\r\n binmap[arr[i]]=true;\r\n }\r\n }", "public static void useBinarySearch1() {\n int[] numbers = {-3, 2, 8, 12, 17, 29, 44, 58, 79};\n int index = Arrays.binarySearch(numbers, 29);\n System.out.println(\"29 is found at index \" + index);\n }", "public static int binSearch(int[] a, int x, int l, int r) {\r\n if (l == r) {\r\n return r;\r\n }\r\n int m = (l + r) / 2;\r\n if (a[m] >= x) {\r\n return binSearch(a, x, l, m);\r\n }\r\n else {\r\n return binSearch(a, x, m + 1, r);\r\n }\r\n }", "private int binarySearch(int[] nums, int target, int low, int high) {\n while (low <= high) {\n int mid = low + (high - low) / 2; // find mid\n\n if (nums[mid] == target) { // if number found\n if (mid == low || nums[mid] > nums[mid - 1]) // check if it is the first occurence\n return mid; // if it is return mid\n else\n high = mid - 1; // decrease high to reach the index\n } else if (nums[mid] > target) // if the value in num is greater\n high = mid - 1; // decrease high\n else\n low = mid + 1; // else increase low\n\n }\n\n return -1; // number not found\n }", "private static boolean binarySearch(int[] arr, int num, int start, int end) {\n\t\tif(arr==null || arr.length==0){\r\n\t\t\treturn false;\r\n\t\t}\r\n\t\tint mid;\r\n\t\t\r\n\t\twhile(start<=end){\r\n\t\t\t\r\n\t\t\tmid= start+ (end-start)/2;\r\n\t\t\t\r\n\t\t\tif(arr[mid]==num){\r\n\t\t\t\treturn true;\r\n\t\t\t}\r\n\t\t\telse if(num < arr[mid]){\r\n\t\t\t\tend=mid-1;\r\n\t\t\t}\r\n\t\t\telse{\r\n\t\t\t\tstart=mid+1;\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn false;\r\n\t}", "static int binarySearch(@NotNull int[] search, int find) {\n int start, end, midPt;\n start = 0;\n end = search.length - 1;\n\n while (start <= end) {\n midPt = (start + end) / 2;\n if (search[midPt] == find) {\n return midPt;\n } else if (search[midPt] < find) {\n start = midPt + 1;\n } else {\n end = midPt - 1;\n }\n }\n\n return -1;\n }", "public int search(int[] A, int target) {\n\n int start = 0;\n int end = A.length - 1;\n int mid;\n\n while (start + 1 < end) {\n mid = start + (end - start) / 2;\n if (A[mid] == target) {\n return mid;\n }\n if (A[start] < A[mid]) {\n // situation 1, red line\n if (A[start] <= target && target <= A[mid]) {\n end = mid;\n } else {\n start = mid;\n }\n } else {\n // situation 2, green line\n if (A[mid] <= target && target <= A[end]) {\n start = mid;\n } else {\n end = mid;\n }\n }\n } // while\n\n if (A[start] == target) {\n return start;\n }\n if (A[end] == target) {\n return end;\n }\n return -1;\n }", "private static int search(int[] arr, int findMe, int left, int right) {\n\t\tif (left > right) {\n\t\t\treturn FAILURE;\n\t\t}\n\t\tint mid = (left + right) / 2;\n\t\tif (findMe == arr[mid]) {\n\t\t\treturn mid;\n\t\t}\n\t\telse if (findMe < arr[mid]) {\n\t\t\treturn search(arr, findMe, left, mid - 1);\n\t\t}\n\t\telse {\n\t\t\treturn search(arr, findMe, mid + 1, right);\n\t\t}\n\t}", "private int findAcessess(int m) {\n\t\t\tint number = 0;\n\t\t\tif(m > size-1) throw new IllegalArgumentException(\"Out of range.\");\n\t\t\twhile(m != array[m]) {\n\t\t\t\tm = array[m];\n\t\t\t\tnumber+=2;\n\t\t\t}\n\t\t\treturn ++number;\n\t\t}", "protected int binarySearch(int x) {\n if (arr.length == 0) {\n return -1;\n }\n\n int left = 0;\n int right = count - 1;\n\n while (left <= right) {\n int mid = (right + left) >>> 1;\n int val = arr[mid];\n\n if (val < x) {\n left = mid + 1;\n } else if (val > x) {\n right = mid - 1;\n }\n else {\n return mid;\n }\n }\n\n return -1;\n }", "@Test\n public void testBinarySearch() {\n System.out.println(\"binarySearch\");\n int[] index = {10, 11, 12, 13, 14};\n int key = 12;\n int begin = 0;\n int end = 5;\n int expResult = 2;\n int result = Utils.binarySearch(index, key, begin, end);\n assertEquals(expResult, result);\n }", "private int PASSSelection(HashMap<Integer, Integer> T, HashMap<Integer, Integer> colours, ColEdge[] edge){\r\n\t\tHashMap<Integer, Integer> bestBoiStorage = new HashMap<>();\r\n\t\tHashMap<Integer, Integer> bestBoiFinder = new HashMap<>();\r\n\t\tfor(int s = 0; s < T.size(); s++){\r\n\t\t\tint coloursPos = 0;\r\n\t\t\tVs = T.get(s);\r\n\t\t\tfor(int i = 1; i < T.size(); i++){\r\n\t\t\t\tif(i != s){\r\n\t\t\t\t\tVi = T.get(i);\r\n\t\t\t\t\tcoloursPos += same(edge, colours, Vs, Vi);\r\n\t\t\t\t}else{\r\n\t\t\t\t\tbreak;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\tbestBoiStorage.put(s, Vs);\r\n\t\t\tbestBoiFinder.put(s, coloursPos);\r\n\t\t}\r\n\t\tint mostColPos = 0;\r\n\t\tint mostColKey = 0;\r\n\t\tfor(int b = 0; b < bestBoiFinder.size(); b++){\r\n\t\t\tif(mostColPos == 0 || bestBoiFinder.get(b).compareTo(mostColPos) > 0){\r\n\t\t\t\tmostColPos = bestBoiFinder.get(b);\r\n\t\t\t\tmostColKey = b;\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn bestBoiStorage.get(mostColKey);\r\n\t}", "private void analyzeForObstacles() {\n \t\n \t\n \tStack<Rect> bestFound = new Stack<Rect>();//This is a stack as the algorithm moves along x linearly\n \tboolean[][] blackWhiteGrid = getBlackWhiteGrid();\n \tint[] cache = new int[grid.length];\n \t\n \twhile (true) {\n\t\t\tboolean noneFound = true;\n\t\t\t\n\t\t\tfor (int i = 0; i<cache.length; i++)\n\t\t\t\tcache[i] = 0;\n\t\t\tfor (int llx = grid.length -1; llx >= 0; llx--) {\n\t\t\t\tupdate_cache(blackWhiteGrid,cache, llx);\n\t\t\t\tfor (int lly = 0; lly < grid.length; lly++) {\n\t\t\t\t\tRect bestOfRound = new Rect(llx,lly,llx,lly);\n\t\t\t\t\tint y = lly;\n\t\t\t\t\tint x_max = 9999;\n\t\t\t\t\tint x = llx;\n\t\t\t\t\twhile (y+1<grid.length && blackWhiteGrid[llx][y]) {\n\t\t\t\t\t\ty++;\n\t\t\t\t\t\tx = Math.min(llx+cache[y]-1, x_max);\n\t\t\t\t\t\tx_max = x;\n\t\t\t\t\t\tRect tryRect = new Rect(llx,lly-1,x,y);\n\t\t\t\t\t\tif (tryRect.area() > bestOfRound.area()) {\n\t\t\t\t\t\t\tbestOfRound = tryRect;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tif (bestOfRound.area() > 40) {\n\t\t\t\t\t\tif (noneFound) {\n\t\t\t\t\t\t\tbestFound.push(bestOfRound);\n\t\t\t\t\t\t\tnoneFound = false;\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse {\n\t\t\t\t\t\t\tRect lastRect = bestFound.peek();\n\t\t\t\t\t\t\tif (lastRect.area() < bestOfRound.area()) {\n\t\t\t\t\t\t\t\tbestFound.pop();\n\t\t\t\t\t\t\t\tbestFound.push(bestOfRound);\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\tif (noneFound)\n\t\t\t\tbreak;\n\t\t\t\n\t\t\tclearFoundRectangle(blackWhiteGrid, bestFound.peek());\n \t}\n \t\n \t//add found rectanlges\n \tobstacles.clear();\n \tobstacles.addAll(bestFound);\n \tSystem.out.println(\"Sweep done:\");\n \tfor (Rect r : bestFound){\n \t\tSystem.out.println(\"Rect: llx=\" + (r.llx-400) + \"\\tlly=\" + (r.lly-400) + \"\\turx=\" + (r.urx-400) + \"\\tury=\" + (r.ury-400));\n \t\tList<Point2D.Double> corners = new ArrayList<Point2D.Double>();\n \t\tcorners.add(new Point2D.Double((r.llx-400),(r.lly-400)));\n \t\tcorners.add(new Point2D.Double((r.llx-400),(r.ury-400)));\n \t\tcorners.add(new Point2D.Double((r.urx-400),(r.lly-400)));\n \t\tcorners.add(new Point2D.Double((r.urx-400),(r.ury-400)));\n \t\tobstaclesF.add(new Obstacle(corners));\n \t}\n \t\n \ttoExplore.clear();\n \tint i = 0;\n \tRandom rand = new Random();\n \twhile (toExplore.size() < 10 && i < 1000) {\n \t\tint x = rand.nextInt(grid.length);\n \t\tint y = rand.nextInt(grid.length);\n \t\tif (grid[x][y] == .5) {\n \t\t\ttoExplore.add(new Flag(\"blue\",x,y));\n \t\t}\n \t}\n }", "private void discretization(int[] nums) {\n\t\tint[] sorted = nums.clone();\n\t\tArrays.sort(sorted);\n\t\tfor (int i = 0; i < nums.length; i++) {\n\t\t\tnums[i] = Arrays.binarySearch(sorted, nums[i]);\n\t\t}\n\t}", "private int rob(int[] num, int lo, int hi) {\r\n int include = 0, exclude = 0;\r\n for (int j = lo; j <= hi; j++) {\r\n int i = include, e = exclude;\r\n include = e + num[j];\r\n exclude = Math.max(e, i);\r\n }\r\n return Math.max(include, exclude);\r\n}", "public void binSearch(int current, int first, int last) {\r\n long average2 = 0, timeB = 0, stanDev = 0;\r\n System.out.println(\"\\nBINARY SEARCH\\n\");\r\n for (int i = 0; i < 10; i++) {\r\n long start = System.nanoTime();\r\n while (last >= first) {\r\n int mid = (last + first) / 2;//FINDS THE MID WAY POINT IN ORDER TO KEEP HALF-ING THE SEARCH RESULTS.\r\n if (A[mid] == current) {\r\n long stop = System.nanoTime();\r\n long timelength = (stop - start);\r\n timeB += timelength; // USED FOR GETTING AVERAGE. \r\n bin[k][i] = timelength;//USED FOR STORING THE TIME IT TOOK FOR EACH TEST, IT IS USED LATER ON TO DISPLAY IN THE CHART.\r\n binary[i] = timelength;//USED FOR FINDING STANDARD DEVIATION.\r\n System.out.println(\"The number: \" + current + \" was found in the array index: \" + A[mid]\r\n + \"\\nIt took: \" + timelength + \" nanoseconds.\");\r\n break;\r\n\r\n } else if (A[mid] < current) {\r\n first = mid + 1;\r\n } else {\r\n last = mid - 1;\r\n }\r\n }\r\n }\r\n average2 = (timeB / 10);\r\n linAvAndDev[h][0] = average2;\r\n for (int j = 0; j < 10; j++) {\r\n stanDev += Math.pow((binary[j] - average2), 2.0);\r\n }\r\n stanDev /= 10;\r\n stanDev = (long) Math.sqrt(stanDev);\r\n linAvAndDev[h][1] = stanDev;\r\n System.out.println(\"The Avearge time for the Binary Search was: \" + average2 + \" nanoseconds.\"\r\n + \"\\nThe Standard Deviation time for the Binary Search was: \" + stanDev + \" nanoseconds.\");\r\n h += 1;\r\n k += 1;\r\n }", "private int threshFind(int[] ray){\n int min = 0;\n int max = 0;\n for(int i = 0; i < ray.length; i++){\n if(min > ray[i]) min = ray[i];\n else if(max < ray[i]) max = ray[i];\n }\n\n return (min + max) / 2;\n }", "public void binarySearchForValue(int value){\n int lowIndex = 0;\n int highIndex = arraySize -1;\n\n while(lowIndex <= highIndex){\n int middleIndex = (lowIndex + highIndex)/2;\n\n if(theArray[middleIndex] < value){\n lowIndex = middleIndex + 1;\n } else if(theArray[middleIndex] > value) {\n highIndex = middleIndex -1;\n } else {\n System.out.println(\"Found a match for \" + value + \" at Index \" + middleIndex);\n // Exit the while loop.\n lowIndex = highIndex + 1;\n }\n\n printHorizontalArray(middleIndex, -1);\n }\n }", "public int binarySearch(ArrayList<Integer> a, int val){\n int low = 0;\n int high = a.size() - 1;\n \n while(high - low > 3){\n int mid = (low + high)/2;\n if(a.get(mid) > val){\n high = mid - 1;\n }\n else{\n low = mid; \n }\n }\n int i;\n for(i=low; i<=high; ++i){\n if(a.get(i) > val)\n return i;\n }\n return i;\n }", "public static void main(String[] args) {\n\n\t\tint[] arr = {1, 2, 5, 5, 5, 10, 20};\n\t\t\n\t\tint search = 5;\n\t\t\n\t\tint index = Arrays.binarySearch(arr, search);\n\t\t//System.out.println(index);\n\t\t\n\t\tif(index < 0) {\n\t\t\tint lowerBound = Math.abs(index) - 2;\n\t\t\tint upperBound = Math.abs(index) - 1;\n\t\t\t\n\t\t\tSystem.out.println(lowerBound + \" \" + upperBound);\n\t\t}\n\t\t\n\t}", "private int binarySearch(T element) {\n int start = 0, end = sortedArray.size(), mid = 0;\n while (start < end) {\n mid = (end + start) / 2;\n int cmp = sortedArray.get(mid).compareTo(element);\n if (cmp == 0) {\n start = end = mid;\n }\n else if (cmp < 0) {\n start = mid + 1;\n }\n else {\n end = mid;\n }\n }\n return start;\n }", "private int GetBestCard(Card[] card) {\n\t int iPos = 0;\n\t int iWeightTemp = 0;\n\t int iWeight[] = new int[8];\n\t for (int i = 0; i < 8; i++){\n\t\t iWeight[i] = -1;\n\t }\n\t // For each selectable card, work out a weight, the highest weight is the one selected.\n\t // The weight is worked out by the distance another of the players cards is from playable ones, with no playable cards in between\n\t Card myCard, nextCard;\n\t for (int i = 0; i < 8; i++){\n\t\t if (card[i] != null){\n\t\t\t // if card value > 7\n\t\t\t if (card[i].GetValue() > 7){\n\t\t\t\t // do you have cards that are higher than this card\n\t\t\t\t myCard = card[i];\n\t\t\t\t iWeightTemp = 0;\n\t\t\t \tfor (int j = 0; j < mCardCount; j++){\n\t\t\t \t\tnextCard = mCard[j];\n\t\t\t \t\tif (nextCard != null && nextCard.GetSuit() == myCard.GetSuit() && nextCard.GetValue() > myCard.GetValue()){\n\t\t\t \t\t\tif (nextCard.GetValue() - myCard.GetValue() > iWeightTemp)\n\t\t\t \t\t\t\tiWeightTemp = nextCard.GetValue() - myCard.GetValue();\n\t\t\t \t\t\tmyCard = nextCard;\n\t\t\t \t\t}\n\t\t\t \t}\n\t\t\t \tiWeight[i] = iWeightTemp;\n\t\t\t \t\t\n\t\t\t }\n\t\t\t if (card[i].GetValue() < 7){\n\t\t\t\t // do you have cards that are lower than this card\n\t\t\t\t myCard = card[i];\n\t\t\t\t iWeightTemp = 0;\n\t\t\t \tfor (int j = mCardCount-1; j >=0; j--){\n\t\t\t \t\tnextCard = mCard[j];\n\t\t\t \t\tif (nextCard != null && nextCard.GetSuit() == myCard.GetSuit() && nextCard.GetValue() < myCard.GetValue()){\n\t\t\t \t\t\tif (myCard.GetValue() - nextCard.GetValue() > iWeightTemp)\n\t\t\t \t\t\t\tiWeightTemp = myCard.GetValue() - nextCard.GetValue();\n\t\t\t \t\t\tmyCard = nextCard;\n\t\t\t \t\t}\n\t\t\t \t}\n\t\t\t \tiWeight[i] = iWeightTemp;\n\t\t\t \t\t\n\t\t\t }\t\n\t\t\t if (card[i].GetValue() == 7){\n\t\t\t\t // do you have cards that are in this suit\n\t\t\t\t myCard = card[i];\n\t\t\t\t int iWeightTemp1;\n\t\t\t\t iWeightTemp = 0;\n\t\t\t\t iWeightTemp1 = 0;\n\t\t\t\t // do you have cards that are higher than this card\n\t\t\t \tfor (int j = 0; j < mCardCount; j++){\n\t\t\t \t\tnextCard = mCard[j];\n\t\t\t \t\tif (nextCard != null && nextCard.GetSuit() == myCard.GetSuit() && nextCard.GetValue() > myCard.GetValue()){\n\t\t\t \t\t\tif (nextCard.GetValue() - myCard.GetValue() > iWeightTemp)\n\t\t\t \t\t\t\tiWeightTemp = nextCard.GetValue() - myCard.GetValue();\n\t\t\t \t\t\tmyCard = nextCard;\n\t\t\t \t\t}\n\t\t\t \t}\n\t\t\t \tmyCard = card[i];\n\t\t\t \t// do you have cards that are lower than this card\n\t\t\t \tfor (int j = mCardCount-1; j >=0; j--){\n\t\t\t \t\tnextCard = mCard[j];\n\t\t\t \t\tif (nextCard != null && nextCard.GetSuit() == myCard.GetSuit() && nextCard.GetValue() < myCard.GetValue()){\n\t\t\t \t\t\tif (myCard.GetValue() - nextCard.GetValue() > iWeightTemp1)\n\t\t\t \t\t\t\tiWeightTemp1 = myCard.GetValue() - nextCard.GetValue();\n\t\t\t \t\t\tmyCard = nextCard;\n\t\t\t \t\t}\n\t\t\t \t} \t\n\t\t\t \tiWeight[i] = iWeightTemp + iWeightTemp1;\n\t\t\t \t\t\n\t\t\t }\t\t\t \n\t\t }\n\t\t \t \n\t }\n\t boolean bLoopAceKing = true;\n\t int iMaxTemp = 0;\n\t int iMaxCount = 0;\t\n\t int[] iMaxs;\n\t iMaxs = new int[8];\n\t while (bLoopAceKing){\n\t\t for (int i = 0; i < 8; i++){\n\t\t\t if (iWeight[i] >= iMaxTemp){\n\t\t\t\t if (iWeight[i] == iMaxTemp){\n\t\t\t\t\t iMaxs[iMaxCount] = i;\n\t\t\t\t\t iMaxCount++;\n\t\t\t\t }\n\t\t\t\t else {\n\t\t\t\t\t iMaxTemp = iWeight[i];\n\t\t\t\t\t iMaxs = new int[8];\n\t\t\t\t\t iMaxCount = 0;\n\t\t\t\t\t iMaxs[iMaxCount] = i;\n\t\t\t\t\t iMaxCount++;\n\t\t\t\t }\t\t\t \n\t\t\t }\t \n\t\t }\n\t\t boolean bAceKing = false;\n\t\t // If the top weight is zero, meaning your options don't help you, then play the one that is closest to ace/king\n\t\t if (iMaxTemp == 0 && iMaxCount > 1){\n\t\t\t for (int k = 0; k < iMaxCount; k++){\n\t\t\t\t\t iWeight[iMaxs[k]] = Math.abs(card[iMaxs[k]].GetValue()-7);\n\t\t\t\t\t bAceKing = true;\t\t\t\t \n\t\t\t } \t\t \n\t\t }\n\t\t if (bAceKing){\n\t\t\t bLoopAceKing = true;\n\t\t\t iMaxs = new int[8];\n\t\t\t iMaxTemp = 0;\n\t\t\t iMaxCount = 0;\t\t\t \n\t\t }\n\t\t else \n\t\t\t bLoopAceKing = false;\n\t }\n\t if (iMaxCount == 1)\n\t\t iPos = iMaxs[iMaxCount-1];\n\t else {\n\t\t Random generator = new Random();\n\t\t int randomIndex = generator.nextInt( iMaxCount );\n\t\t iPos = iMaxs[randomIndex];\n\t }\n\t\t \n\t return iPos;\n\t \n }", "int find(int[] arr) {\n int start = 0;\n int end = arr.length - 1;\n while (start < end) {\n int mid = start + (end - start) / 2;\n if (mid % 2 == 0) {\n if (arr[mid] == arr[mid + 1]) {\n start = mid + 2;\n } else {\n end = mid;\n }\n } else if (mid % 2 == 1) {\n if (arr[mid] == arr[mid - 1]) {\n start = mid + 1;\n } else {\n end = mid - 1;\n }\n }\n }\n if (start == end) {\n return arr[start];\n }\n return -1;\n }", "public boolean find(int value) {\r\n // Write your code here\r\n for (int i = 0; i < elements.size() && elements.get(i) < value / 2 + 1; i++) {\r\n if (elements.get(i) * 2 == value && mapping.get(elements.get(i)) == 2) {\r\n return true;\r\n }\r\n if (elements.get(i) * 2 != value && mapping.containsKey(value - elements.get(i))) {\r\n return true;\r\n }\r\n }\r\n return false;\r\n }", "static int find(int[] arr){\n\t\tif(arr.length==1) return -1;\n\t\tint slow = arr[0] , fast = arr[arr[0]];\n\t\twhile(slow!=fast){\n\t\t\tslow = arr[slow];\n\t\t\tfast = arr[arr[fast]];\n\t\t}\n\t\tslow = 0;\n\t\twhile(slow!=fast){\n\t\t\tslow = arr[slow];\n\t\t\tfast = arr[fast];\n\t\t}\n\t\treturn slow;\n\n\t}", "private static int binarySearch(int[] arr, int low, int high, int target) {\n\n\t\tif (low <= high) {\n\n\t\t\tint mid = low + (high - low) / 2;\n\n\t\t\tif (arr[mid] == target) {\n\t\t\t\treturn mid;\n\t\t\t}\n\n\t\t\tif (arr[mid] < target) {\n\t\t\t\treturn binarySearch(arr, mid + 1, high, target);\n\t\t\t} else {\n\t\t\t\treturn binarySearch(arr, low, mid - 1, target);\n\t\t\t}\n\n\t\t}\n\n\t\treturn -1;\n\t}", "static int BinarySearch(int[] arr, int target, int start, int end) {\n boolean isAsc = arr[start] < arr[end];\n\n while(start <= end) {\n // find the middle element\n// int mid = (start + end) / 2; // might be possible that (start + end) exceeds the range of int in java\n int mid = start + (end - start) / 2;\n\n if (arr[mid] == target) {\n return mid;\n }\n\n if (isAsc) {\n if (target < arr[mid]) {\n end = mid - 1;\n } else {\n start = mid + 1;\n }\n } else {\n if (target > arr[mid]) {\n end = mid - 1;\n } else {\n start = mid + 1;\n }\n }\n }\n return -1;\n }", "public static int binarySearch(int[] num, int target) {\n\t\tint left = 0;\n\t\tint right = num.length - 1;\n\t\twhile (left <= right) {\n\t\t\tint middle = (left+right)/2;\n\t\t\tif (num[middle] == target) {\n\t\t\t\treturn middle;\n\t\t\t} else if (num[middle] < target) {\n\t\t\t\tleft = middle + 1;\n\t\t\t} else {\n\t\t\t\tright = middle - 1;\n\t\t\t}\n\t\t}\n\t\t\n\t\treturn -1;\n\t}", "private int binarySearchQ7(int first, int last, K key)\n {\n int index;\n \n if (first > last)\n index = first; \n else \n {\n int mid = first + (last - first) / 2;\n K midKey = dictionary[mid].getKey(); \n if (key.equals(midKey))\n index = mid; \n else if (key.compareTo(midKey) < 0)\n index = binarySearchQ7(first, mid - 1, key);\n else\n index = binarySearchQ7(mid + 1, last, key);\n } \n return index;\n }", "public static UniformCostSearchNode searchBnB(UniformCostSearchNode root){\n PriorityQueue<UniformCostSearchNode> frontier = new PriorityQueue<UniformCostSearchNode>();\n\n // hash set for fast verification of closed nodes\n HashSet<UniformCostSearchNode> closed = new HashSet<UniformCostSearchNode>();\n\n int upperBoundCost = Integer.MAX_VALUE;\n\n frontier.add(root);\n\n while(frontier.size() != 0){\n UniformCostSearchNode current = frontier.remove();\n if(current.isGoalState()){\n System.out.println(\"UCS B&B Nodes explored: \" + closed.size());\n return current;\n }\n\n // implicitly pruning the frontier\n if(current.getCost() >= upperBoundCost){\n // skipping due to bounding\n continue;\n }\n\n closed.add(current);\n\n PriorityQueue<UniformCostSearchNode> toAdd = new PriorityQueue<UniformCostSearchNode>();\n for(UniformCostSearchNode neighbor : current.getNeighbors()){\n toAdd.add(neighbor);\n }\n\n while(toAdd.size() != 0) {\n UniformCostSearchNode neighbor = toAdd.remove();\n if (neighbor.getCost() < upperBoundCost) {\n if (neighbor.isGoalState()) {\n // bounding\n upperBoundCost = neighbor.getCost();\n }\n frontier.add(neighbor);\n }\n }\n }\n\n System.out.println(\"UCS B&B Search failed, nodes explored: \" + closed.size());\n // search failed\n return null;\n }", "protected int search(double value) {\n int n = sequence.size();\n int left = 0, right = n - 1, index = 0;\n while (left != right) {\n index = (right - left) / 2 + left;\n if (value >= sequence.get(index == left ? index + 1 : index)) {\n left = index == left ? index + 1 : index;\n } else {\n right = index;\n }\n }\n while (left > 0 && value == sequence.get(left - 1)) {\n left -= 1;\n }\n return left;\n }", "private static boolean binarySearch(int[] data, int target, int low, int high) {\n if (low > high) {\n return false;\n } else {\n int mid = (low + high) / 2;\n if (target == data[mid]) {\n return true;\n } else if (target < data[mid]) {\n return binarySearch(data, target, low, mid - 1);\n } else {\n return binarySearch(data, target, mid + 1, high);\n }\n }\n }", "public int book(int start, int end) {\n bst.put(start, bst.getOrDefault(start, 0) + 1);\n bst.put(end, bst.getOrDefault(end, 0) - 1);\n int overlap = 0, k = 0;\n for (Integer key : bst.keySet()) {\n overlap += bst.get(key);\n k = Math.max(k, overlap);\n }\n return k;\n }", "public static double binSearchT(int s, Integer[] a){\n Random rand = new Random();\n int searchVar;\n Stopwatch timer = new Stopwatch();\n Arrays.sort(a);\n for (int i = 0; i < s; i++){\n searchVar = (int)(rand.nextDouble()*a.length);\n Arrays.binarySearch(a, searchVar);\n }\n return timer.elapsedTime(); // the method returns the elapsed time\n }", "public void binarySearchForValue(int value) {\n int lowIndex = 0;\n int highIndex = arraySize - 1;\n\n while (lowIndex <= highIndex) {\n int middleIndex = (highIndex + lowIndex) / 2;\n\n if (theArray[middleIndex] < value) {\n lowIndex = middleIndex + 1;\n } else if (theArray[middleIndex] > value) {\n highIndex = middleIndex - 1;\n } else {\n System.out.println(\"\\nFound a match for \" + value + \" at index \" + middleIndex);\n lowIndex = highIndex + 1;\n }\n\n printHorizontalArray(middleIndex, -1);\n }\n }", "@Override\n public boolean contain(int x, int y) {\n return(x>=this.x && y>=this.y && x<=this.x+(int)a && y<=this.y+(int)b);\n }", "private static void task222(int nUMS, RedBlackBST<Integer, Integer> i) {\n\t\tSystem.out.println(\"RED BLAST BST Started Search...\");\n\t double search_start = 0, search_end = 0;\n\t int totalkeymatched = 0;\n\n\t search_start = System.nanoTime();\n\t \n\t for (int z = 0; z < nUMS; z++) {\n\t \tint checker= GenerateInt.generateNumber();\n\t \t\n//\t \tSystem.out.println(GenerateStrings.getAlphaNumericString(limit));\n\t if (i.contains(checker)) {\n\t\n//\t System.out.println(\"Key Matches\");\n\t totalkeymatched++;\n\t \t }\n\t }\n\t search_end = System.nanoTime();\n\t System.out.println(\"Average time for each search: \" + (search_end - search_start) / nUMS + \" nanoseconds\");\n\t System.out.println(\"TOTAL MATCHES \" + totalkeymatched);\n\n\t}", "public boolean find(int value) {\n for(int num1 : list){\n int num2 = value - num1;\n if((num1 == num2) && map.get(num1) > 1 || (num1 != num2) && map.containsKey(num2)) return true;\n }\n return false;\n }", "public int find(int[] nums, int target, int start, int end){\n int middle = (start + end) / 2;\n\n while (start <= end){\n middle = (start + end) >> 1;\n if(nums[middle] == target){\n return middle;\n }\n else if(nums[middle] > target){\n end = middle - 1;\n }\n else {\n start = middle + 1;\n }\n }\n return -1;\n }", "public static int binarySearchRec(int[] arr, int from, int to, int key) {\n\t\t\n\t\tif (from<=to) {\n\t\t\tint mid=from+(to-from)/2;\n\t\t\tif (arr[mid]<key) \t\treturn binarySearchRec(arr, ++mid, to, key);//upper\t\n\t\t\telse if (arr[mid]>key) \treturn binarySearchRec(arr, from, --mid, key); //lower\n\t\t\telse \t\t\t\t\treturn mid;//found\n\t\t}\n\t\telse {//not found\n\t\t\tint shouldBeIndex=from;\n\t\t\treturn -shouldBeIndex-1;\n\t\t}\n\t}", "static void binarySearch(int mat[][], int i, int j_low, int j_high, int x){\n\t\t\n\t\twhile(j_low < j_high){\n\t\t\t\n\t\t}\n\t}", "private static void task2(int nUMS, BinarySearchTree<Integer> t) {\n\t\tSystem.out.println(\"Binary Search Started...\");\n\t double search_start = 0, search_end = 0;\n\t int totalkeymatched = 0;\n\n\t search_start = System.nanoTime();\n\t \n\t for (int z = 0; z < nUMS; z++) {\n\t \tint checker= GenerateInt.generateNumber();\n\t \t\n//\t \tSystem.out.println(GenerateStrings.getAlphaNumericString(limit));\n\t if (t.contains(checker)) {\n\t\n//\t System.out.println(\"Key Matches\");\n\t totalkeymatched++;\n\t \t }\n\t }\n\t search_end = System.nanoTime();\n\t System.out.println(\"Average time for each search: \" + (search_end - search_start) / nUMS + \" nanoseconds\");\n\t System.out.println(\"TOTAL MATCHES \" + totalkeymatched);\n\t\t\n\t}", "public static int binaryFind(int []A, int s, int e, int key) {\n\tif(s>e) return -1;\n\tint mid = (s+e)/2;\n\tif(A[mid] == key) return mid;\n if(A[mid] < key) return binaryFind(A, mid+1, e, key);\n else return binaryFind(A, s, mid-1, key); //(A[mid] > key)\n }", "public void seekWalls() {\n\t\t for (int j=0; j<visited[0].length; j++){\n\t\t\tfor (int i=visited.length-1; i>=0; i--) {\t\t\t\n\t\t\t\tif (i!=0 && j!= visited[0].length-1) {//general position\n\t\t\t\t\tif (map.get(visited[i][j]) + map.get(visited[i-1][j]) == maxComb && !isFree(i,j,2)) {\n\t\t\t\t\t\twallRow = i+1;\n\t\t\t\t\t\twallCol = j+1;\n\t\t\t\t\t\twallSide = 'N';\n\t\t\t\t\t\treturn;//not break!!!!! return to exit !\n\t\t\t\t\t}\n\n\t\t\t\t\tif (map.get(visited[i][j]) + map.get(visited[i][j+1]) == maxComb && !isFree(i,j,4)) {\n\t\t\t\t\t\twallRow = i+1;\n\t\t\t\t\t\twallCol = j+1;\n\t\t\t\t\t\twallSide = 'E';\t\n\t\t\t\t\t\treturn;\t\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\telse if (i==0 && j!= visited[0].length-1) {\n\t\t\t\t\tif (map.get(visited[i][j]) + map.get(visited[i][j+1]) == maxComb && !isFree(i,j,4)) {\n\t\t\t\t\t\twallRow = i+1;\n\t\t\t\t\t\twallCol = j+1;\n\t\t\t\t\t\twallSide = 'E';\t\n\t\t\t\t\t\treturn;\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\telse if (i!=0 && j== visited[0].length-1) {\n\t\t\t\t\tif (map.get(visited[i][j]) + map.get(visited[i-1][j]) == maxComb && !isFree(i,j,2)) {\n\t\t\t\t\t\twallRow = i+1;\n\t\t\t\t\t\twallCol = j+1;\n\t\t\t\t\t\twallSide = 'N';\n\t\t\t\t\t\treturn;\n\t\t\t\t\t}\n\n\t\t\t\t}\n\t\t\t\telse {//if (i==0 && j== visited[0].length-1) {\n\t\t\t\t\t//no solution\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}", "private static int search(int[] nums, int target, int start, int end)\r\n\t{\n\t\tif (end == start)\r\n\t\t\treturn nums[start] == target ? start : -1;\r\n\t\t\r\n\t\tif(end - start == 1)\r\n\t\t{\r\n\t\t\tif(nums[start] == target)\r\n\t\t\t\treturn start;\r\n\t\t\tif(nums[end] == target)\r\n\t\t\t\treturn end;\r\n\t\t\treturn -1;\r\n\t\t}\r\n\t\t\r\n\t\t// If there are more than two elements\r\n\t\tint mid = (start + end) / 2;\r\n\t\tif (nums[mid] == target)\r\n\t\t\treturn mid;\r\n\t\telse if (nums[mid] > target)\r\n\t\t\treturn search(nums, target, start, mid - 1);\r\n\t\telse\r\n\t\t\treturn search(nums, target, mid + 1, end);\r\n\t}", "int binarySearchWithRecursion(int[] arr, int low, int high, int key){\n if (high < low)\n return -1;\n int mid = (low + high) / 2;\n if (key == arr[mid])\n return mid;\n if (key > arr[mid])\n return binarySearchWithRecursion(arr,(mid + 1), high, key);\n return binarySearchWithRecursion(arr, low, (mid - 1), key);\n }", "private int probe(K key, int i, int size)\r\n\t{\r\n\t\t// Use quadratic probing of the form: (i^2 + i) / 2\r\n\t\treturn (hash(key) + ((int) (Math.pow(i, 2) + i) >> 2)) % size;\r\n\t}", "public static int binarySearchIter(int[] arr, int from, int to, int key) {\n\t\t\n\t\tint shouldBeIndex;\n\t\twhile (from<=to){\n\t\t\tint mid=from+(to-from)/2;\n\t\t\tif (arr[mid]<key) from=mid+1;//upper\n\t\t\telse if (arr[mid]>key) to=mid-1;//lower\n\t\t\telse return mid;//found\n\t\t}\n\t\t//not found\n\t\tshouldBeIndex=from;\n\t\treturn -shouldBeIndex-1;\n\t}", "public int binarySearchAlgo(int a[], int x) {\n\t\tint low = 0;\n\t\tint high = a.length - 1;\n\n\t\twhile (low <= high) {\n\t\t\tint mid = (low + high) / 2;\n\t\t\tif (a[mid] == x) {\n\t\t\t\treturn mid;\n\t\t\t}\n\t\t\tif (x > a[mid]) {\n\t\t\t\tlow = mid + 1;\n\t\t\t} else /* if(a[mid] < x) */ {\n\t\t\t\thigh = mid - 1;\n\t\t\t}\n\t\t}\n\t\treturn -1;\n\t}", "public static int binarySearch(List pl, Comparator c, Object p) {\n int l = 0;\n int u = pl.size()-1;\n\n while (l <= u) {\n int m = (l + u)/2;\n int v = c.compare(pl.get(m), p);\n if (v > 0) {\n\tl = m + 1;\n } else if (v < 0) {\n\tu = m - 1;\n } else {\n\treturn m;\n }\n }\n return -(l + 1); // key not found.\n }", "static int binarySearch(int arr[], int start, int end, int target ){\n if(start>end){\n return -1;\n }\n int mid = start+(end-start)/2;\n \n if(arr[mid] == target && (mid==0 || arr[mid-1]!=target)){\n return mid;\n }\n if(arr[mid] == target){\n return mid;\n }\n if(arr[mid]>=target && arr[mid]>arr[start]){\n return binarySearch(arr,start,mid-1,target);\n }\n // else if(arr[mid]<arr[start] && arr[mid]<target){\n // return binarySearch(arr,mid+1,end,target);\n // }\n return binarySearch(arr,mid+1,end,target);\n }", "public int binarySearch(int[] numbers, int numToSearch){\n\n QuickSort quickSort = new QuickSort();\n quickSort.sort(numbers);\n\n //Above code is tightly coupled with either of the algo to be used, we can not manage using sort algo dynamically.\n\n\n // Login to search\n\n //Return the number found\n\n return 5; //returning any hypothetical number\n }", "public int search(int[] A, int target) {\n\n\t\tint s = 0;\n\t\tint e = A.length - 1;\n\n\t\twhile (s <= e) {\n\t\t\tint m = (s + e) / 2;\n\n\t\t\tif (target == A[m])\n\t\t\t\treturn m;\n\t\t\telse if (A[s] <= A[m]) {\n\t\t\t\tif (A[s] <= target && target < A[m])\n\t\t\t\t\te = m;\n\t\t\t\telse\n\t\t\t\t\ts = m + 1;\n\t\t\t} else {\n\t\t\t\tif (A[m] < target && target <= A[e])\n\t\t\t\t\ts = m + 1;\n\t\t\t\telse\n\t\t\t\t\te = m;\n\t\t\t}\n\t\t}\n\n\t\treturn -1;\n\t}", "public int getSearchResult(int borrowedBorrowedTarget) \n\t{\n\t\tint first = 0;\n\t\tint last = recordCount + NOT_FOUND;\n\t\tint mid = 0;\n\t\tboolean found = false;\n\n\t\twhile(first <= last && found == false) \n\t\t{\n\t\t\tmid = (first + last) / 2;\n\n\t\t\tif(itemIDs[mid] == borrowedBorrowedTarget) \n\t\t\t{\n\t\t\t\tfound = true;\n\t\t\t}\n\t\t\telse \n\t\t\t{\n\t\t\t\tif(itemIDs[mid] < borrowedBorrowedTarget) \n\t\t\t\t{\n\t\t\t\t\tfirst = mid + 1;\n\t\t\t\t}\n\t\t\t\telse \n\t\t\t\t{\n\t\t\t\t\tlast = mid -1;\n\t\t\t\t}\n\t\t\t}\n\t\t}//END while\n\n\t\tif(found == false) \n\t\t{\n\t\t\tmid = NOT_FOUND;\n\t\t}\n\n\t\treturn mid;\n\t}", "private int checkCorners(int[] arr, int[] availableMoves) {\n for (int i = 0; i <= 6; i += 6) {\n int sum = arr[i] + arr[i + 1] + arr[i + 2];\n System.out.println(sum);\n if (sum == -1 && contains(availableMoves,i)) { \n return i;\n } \n }\n\n // Check verticals\n for (int i = 0; i < 3; i+=2) {\n int sum = arr[i] + arr[i + 3] + arr[i + 6];\n System.out.println(sum);\n if (sum == -1 && contains(availableMoves,i)) {\n return i;\n } \n }\n \n return -1;\n }", "public static int Bricksolution(int[] H) {\n int i = 0;\n int index = 0;\n ArrayList indexes = new ArrayList();\n do {\n if (H[i] <= H[i + 1]) {\n i++;\n } else {\n indexes.add(i);\n i++;\n }\n } while (i < H.length);\n return 0;\n }" ]
[ "0.6297529", "0.60606366", "0.6034683", "0.5910886", "0.5887328", "0.5841531", "0.5814943", "0.5775123", "0.5750768", "0.5699777", "0.5687641", "0.56703484", "0.5660193", "0.5636146", "0.5611309", "0.5595036", "0.55832607", "0.55767906", "0.5575091", "0.556061", "0.55371696", "0.5534713", "0.55329335", "0.5530615", "0.5530478", "0.5518682", "0.5513845", "0.55070543", "0.5501198", "0.5499314", "0.54907495", "0.5481722", "0.54799914", "0.5472824", "0.546545", "0.54533935", "0.5449339", "0.5445164", "0.5444458", "0.54382366", "0.5434565", "0.5423196", "0.54181445", "0.5414982", "0.5413444", "0.5412597", "0.54119873", "0.54062164", "0.54022557", "0.53998506", "0.53988343", "0.5380586", "0.5374465", "0.53733385", "0.53644544", "0.535465", "0.5352724", "0.53450125", "0.5343972", "0.53424203", "0.53393185", "0.5324301", "0.5317863", "0.53168017", "0.5304453", "0.5298754", "0.5297421", "0.52973336", "0.52966523", "0.529477", "0.5290085", "0.5289104", "0.5278215", "0.52777165", "0.5277688", "0.52757394", "0.527552", "0.527363", "0.5272892", "0.5272087", "0.52702606", "0.52694535", "0.5267369", "0.5266243", "0.52593654", "0.52593035", "0.525735", "0.52544355", "0.5248652", "0.5239926", "0.52373916", "0.52341145", "0.52239347", "0.5222683", "0.5221223", "0.52205026", "0.5218895", "0.521865", "0.5218125", "0.52144665" ]
0.5767065
8
Code for merge sort
static void merge(int arr[], int l, int m, int r) { // Sizes of the two subarrays int size1 = m - l + 1; int size2 = r - m; // Temporary arrays int left[] = new int [size1]; int right[] = new int [size2]; // Copy over to temps for (int i=0; i<size1; ++i) left[i] = arr[l + i]; for (int j=0; j<size2; ++j) right[j] = arr[m + 1+ j]; // Initial indexes of first and second subarrays int i = 0, j = 0; // Initial index of merged subarry array int k = l; while (i < size1 && j < size2) { if (left[i] <= right[j]) { arr[k] = left[i]; i++; } else { arr[k] = right[j]; j++; } k++; } // Copy rest of arrays while (i < size1) { arr[k] = left[i]; i++; k++; } // For the other array while (j < size2) { arr[k] = right[j]; j++; k++; } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private PerfectMergeSort() {}", "public void mergeSort(){\r\n mergeSort(mArray, new int[mArray.length], 0 , mArray.length - 1);\r\n }", "private void mergesort(int[] array) {\n\t\t\n\t}", "private void mergeSort(int low, int high) {\n\t\tif (low < high) {\n\t\t\tint middle = low + (high - low) / 2;\n\t\t\tmergeSort(low, middle);\n\t\t\tmergeSort(middle + 1, high);\n\t\t\tmergeParts(low, middle, high);\n\t\t}\n\t}", "private void merge_sort( ArrayList<Type> array, ArrayList<Type> auxillary, int low, int high ){\n\t\tif((high-low)>switchOff){\n\t\t\tint middle=low+((high-low)/2);\n\t\t\tmerge_sort(array,auxillary,low,middle);\n\t\t\tmerge_sort(array,auxillary,middle+1,high);\n\t\t\tcombine(array,auxillary,low,middle,high);\n\t\t}else{\n\t\t\tSort_Utils.insertion_sort(array, low, high);\n\t\t}\n\t}", "public static void mergesort(int[]data){\n if (data.length <= 1)\n return;\n mergesortH(data, 0, data.length - 1);\n \n }", "private static void mergeSort(int[] data, int left, int right) {\n\n\t\tint mid;\n\n\t\tif (left < right) {\n\n\t\t\tmid = (left + right) / 2;\n\n\t\t\tmergeSort(data, left, mid);\n\t\t\tmergeSort(data, mid + 1, right);\n\t\t\tmerge(data, left, mid, right);\n\t\t}\n\n\t}", "public void mergeSort() {\n this.array = mergeSort(array);\n }", "public void mergesort()\n { sort(this.heap, 0, heap.size()-1);\n }", "private void merge_sort( ArrayList<Type> array, ArrayList<Type> auxillary, int low, int high )\r\n\t{\r\n\t\t// base case\r\n\t\tif ((high - low) <= switchValue)\r\n\t\t{\r\n\t\t\tSort_Utils.insertion_sort(array, low, high);\r\n\t\t}\r\n\t\t\r\n\t\tif (low < high)\r\n\t\t{\r\n\t\t\tint middle = low + (high - low)/2;\r\n\t\t\t\r\n\t\t\t// recursively sort the two halves of the array\r\n\t\t\tmerge_sort(array, auxillary, low, middle);\r\n\t\t\tmerge_sort(array, auxillary, middle + 1, high);\r\n\t\t\tcombine(array, auxillary, low, middle, high);\r\n\t\t}\r\n}", "private void mergeSortHelper(Object arr[], int l, int r) \n\t{ \n\t\tif (l < r) \n\t\t{ \n\t\t\t// Find the middle point \n\t\t\tint m = (l+r)/2; \n\n\t\t\t// Sort first and second halves \n\t\t\tmergeSortHelper(arr, l, m); \n\t\t\tmergeSortHelper(arr , m+1, r); \n\n\t\t\t// Merge the sorted halves \n\t\t\tmerge(arr, l, m, r); \n\t\t} \n\t}", "private void mergeSort(int[] array, int start, int end) {\n\t\tif (start < end) {\n\t\t\tint mid = (start + end) / 2;\n\t\t\tmergeSort(array, start, mid);\n\t\t\tmergeSort(array, mid + 1, end);\n\t\t\tmerge(array, start, mid, end);\n\t\t}\n\t}", "private static void mergeSort(int[] attr, int low, int hight) {\n\t\t\n\t}", "private void merge() {\n for (int i = low; i<high; i++){\n temparray[i]=nums[i];\n }\n\n int i = low;\n int j = middle;\n //index of the original array for which we are making compare\n int index = low;\n //copy the smallest from the left and right partition to temp\n while ((i<middle)&&(j<high)){\n if(temparray[i]<=temparray[j]){\n nums[index]=temparray[i];\n i++;\n }\n else {\n nums[index]=temparray[j];\n j++;\n }\n index++;\n }\n // copy the rest of the the left side\n while (i<middle){\n nums[index]= temparray[i];\n i++;\n index++;\n }\n //and the right\n while (j<high){\n nums[index]=temparray[j];\n j++;\n index++;\n }\n\n }", "public void mergesort_iterative(){\n\t\tint step = 1;\n\t\tint length = arr.length;\n\t\twhile(step < length){\n\t\t\tint i = 0;\n\t\t\twhile(i<length){\n\t\t\t\tmerge_iterative(i, step);\n\t\t\t\ti += step*2;\n\t\t\t}\n\t\t\tstep <<= 1;\n\t\t}\n\t}", "void mergeSort(int arr[], int l, int r) \n { \n if (l < r) \n { \n // Find the middle point \n int m = (l+r)/2; \n \n // Sort first and second halves \n mergeSort(arr, l, m); \n mergeSort(arr , m+1, r); \n \n // Merge the sorted halves \n sort(arr, l, m, r); \n } \n\t}", "public void sort() {\n if(c==null) {\n int middle;\n\n Comparable[] left, right;\n\n\n if (unsorted.length <= 1) {\n\n sorted = unsorted;\n\n } else {\n\n middle = unsorted.length / 2;\n\n\n left = new Comparable[middle];\n\n right = new Comparable[unsorted.length - middle];\n\n\n System.arraycopy(unsorted, 0, left, 0, middle);\n\n System.arraycopy(unsorted, middle, right, 0, unsorted.length - middle);\n\n\n // Внимание! Опа, рекурсия :)\n\n SimpleMerger leftSort = new SimpleMerger(left, c);\n\n SimpleMerger rightSort = new SimpleMerger(right,c);\n\n\n leftSort.sort();\n\n rightSort.sort();\n\n\n sorted = merge(leftSort.getSorted(), rightSort.getSorted());\n\n }\n }else{\n\n int middle;\n\n Object[] left, right;\n\n\n if (unsorted2.length <= 1) {\n\n sorted2 = unsorted2;\n\n } else {\n\n middle = unsorted2.length / 2;\n\n\n left = new Object[middle];\n\n right = new Object[unsorted2.length - middle];\n System.arraycopy(unsorted2, 0, left, 0, middle);\n\n System.arraycopy(unsorted2, middle, right, 0, unsorted2.length - middle);\n\n\n\n\n SimpleMerger leftSort = new SimpleMerger(left,c);\n\n SimpleMerger rightSort = new SimpleMerger(right,c);\n\n\n leftSort.sort();\n\n rightSort.sort();\n\n\n\n sorted2 = merge2(leftSort.getSorted2(), rightSort.getSorted2());\n\n }\n\n }\n }", "static void mergeSort(int array[], int start, int end) {\n if (start < end) {\n // Find the middle point\n int middle = start + (end - start)/2;\n\n // Sort first and second parts\n mergeSort(array, start, middle);\n mergeSort(array, middle + 1, end);\n\n // Merge the sorted parts\n merge(array, start, middle, end);\n\n }\n\n }", "void mergeSort(int[] arr, int l, int r) {\r\n if (l<r)\r\n {\r\n int m = (l+r)/2;\r\n\r\n mergeSort(arr,l,m);\r\n mergeSort(arr, m+1, r);\r\n merge(arr, l, m, r);\r\n }\r\n }", "private static <T extends Comparable<T>> void mergeSort(T[] arrayToSort, int startIndex, int endIndex) {\n if(startIndex + 1 < endIndex) {\n int centerIndex = (endIndex + startIndex)/2;\n mergeSort(arrayToSort, startIndex, centerIndex); // sort left half\n mergeSort(arrayToSort, centerIndex, endIndex); // sort right half\n merge(arrayToSort, startIndex, centerIndex, endIndex); // merge two, sorted halves\n }\n }", "static void mergeSort(int[] arr, int l, int r) {\n\t\tif (l<r) {\n\t\t\tint m = (l+r)/2;\n\n\t\t\tmergeSort(arr, l, m);\n\t\t\tmergeSort(arr, m+1, r);\n\t\t\tmerge(arr, l, r, m);\n\t\t}\n\t}", "public static void Mergesort(int[]data,int[]storageA,int[]storageB){\n int length=data.length;\n while (length>8){\n for(int i=0;i<data.length/2;i++){\n storageA[i]=data[i];\n }\n int index=0;\n for(int i=data.length/2;i<data.length;i++){\n storageB[index]=data[i];\n index++;\n }\n int[]temp1=new int[storageA.length/2];\n int[]temp2=new int[storageA.length-temp1.length];\n int[]temp3=new int[storageB.length/2];\n int[]temp4=new int[storageB.length-temp3.length];\n Mergesort(storageA,temp1,temp2);\n Mergesort(storageB,temp3,temp4);\n\n merge(data,storageA,storageB);\n // System.out.println(Arrays.toString(data));\n length=8;\n }\n insertion(data);\n\n // System.out.println(Arrays.toString(storageA));\n //System.out.println(Arrays.toString(storageB));\n //data=merge(storageA,storageB,0,1);\n }", "private static int[] mergeSortedArray(int[] a, int[] b){\n int i = a.length -1;\n for(int j = 3, k = 3, x=0; ( (j >= 0) && (k >= 0)) ; x++){\n\n if(a[j] > b[k]){\n a[i] = a[j];\n a[j] = 0;\n --j;\n --i;\n\n } else{\n a[i] = b[k];\n --k;\n --i;\n }\n\n if(j == -1 ) // this condition worked\n j = 0;\n }\n\n return a;\n\n }", "static void MergeSort(int[] arr){\n int[] helper = new int[arr.length];\n MergeSort(arr, helper, 0, arr.length-1);\n }", "private static int[] mergeSort(int numbers[]) {\n\n\t\tif (numbers.length <= 1) {\n\t\t\treturn numbers;\n\t\t}\n\n\t\tint mid = numbers.length / 2;\n\t\tint subArray1[] = new int[mid];\n\t\tint subArray2[] = new int[numbers.length - mid];\n\n\t\tint count = 0;\n\t\tfor (int i = 0; i < subArray1.length; i++) {\n\t\t\tsubArray1[i] = numbers[count++];\n\t\t}\n\t\tfor (int i = 0; i < subArray2.length; i++) {\n\t\t\tsubArray2[i] = numbers[count++];\n\t\t}\n\n\t\tsubArray1 = mergeSort(subArray1);\n\t\tsubArray2 = mergeSort(subArray2);\n\t\tnumbers = merge(subArray1, subArray2);\n\n\t\treturn numbers;\n\t}", "private static void mergeSort(int[] array, int startIndex, int endIndex) {\n if (startIndex < endIndex) {\n int halfIndex = (int) Math.floor((startIndex + endIndex) / 2);\n mergeSort(array, startIndex, halfIndex);\n mergeSort(array, halfIndex + 1, endIndex);\n mergeLogic(array, startIndex, halfIndex, endIndex);\n }\n }", "public static void mergeSort(int[] arr) {\r\n if (arr.length - 1 > 0) {\r\n int[] arrLeft = new int[arr.length / 2];\r\n System.arraycopy(arr, 0, arrLeft, 0, arr.length / 2);\r\n int[] arrRight = new int[arr.length - arrLeft.length];\r\n System.arraycopy(arr, arr.length / 2, arrRight, 0, arrRight.length);\r\n mergeSort(arrLeft);\r\n mergeSort(arrRight);\r\n merge(arr, arrLeft, arrRight);\r\n }\r\n }", "public void mergeSort(int[] array){\n if(array.length <= 1){\r\n return;\r\n }\r\n // divide into 2 arrays\r\n int split = array.length/2;\r\n // create 2 arrays\r\n int[] front = Arrays.copyOfRange(array, 0, split);\r\n int[] back = Arrays.copyOfRange(array, split, array.length);\r\n \r\n // recursively sort\r\n mergeSort(front);\r\n mergeSort(back);\r\n \r\n // put numbers in correct spot\r\n // keeping track of where we are\r\n int fSpot = 0;\r\n int bSpot = 0;\r\n for(int i = 0; i < array.length; i++){\r\n // no more items in front array\r\n if(fSpot == front.length){\r\n // put item from back array in\r\n array[i] = back[bSpot];\r\n bSpot++;\r\n }else if(bSpot == back.length){\r\n // put item from front array in\r\n array[i] = front[fSpot];\r\n fSpot++;\r\n }else if(front[fSpot] < back[bSpot]){\r\n // put front item in\r\n array[i] = front[fSpot];\r\n fSpot++;\r\n }else{\r\n // put back item in\r\n array[i] = back[bSpot];\r\n bSpot++;\r\n }\r\n }\r\n }", "public static void sort(int[] mergeList) {\n for(int i = 0; i < mergeList.length - 1; i++) { //iterate through mergeList \n int min = mergeList[i];\n int minIndex = i;\n \n\n for(int j = i + 1; j < mergeList.length; j++) { //swap current list item with smaller value \n if(mergeList[j] < min) { \n min = mergeList[j]; \n minIndex = j; \n \n }\t\t\t\t\t\n }\n \n \n if(minIndex != i) { //swap original list with sorted list\n mergeList[minIndex] = mergeList[i];\n mergeList[i] = min;\n \n }\n }\n }", "public static void merge(int []a , int low,int mid,int high) {\n int [] helper = new int[a.length] ; \n for (int i = low; i<=high; i++) {\n helper[i] = a[i]; \n }\n\n int i = low;\n int j = mid + 1;\n int k = low;\n\n // combine the low part of a and its high part \n while (i<=mid && j<=high) {\n if (helper[i] >= helper[j]){\n a[k] = helper[i];\n i++;\n } else {\n a[k] = helper[j];\n j++;\n }\n k++;\n }\n\n // copy the rest of low part of a if there is any\n while (i<=mid) {\n a[k] = helper[i];\n i++; k++;\n }\n\n\n // copy the rest of the high part of a if there is any\n while (j<=high) {\n a[k] = helper[j];\n j++;k++;\n }\n\n // out put each time we sort and let you watch the change sequence\n for (int Item:a) {\n System.out.print(Item+\" \");\n }\n System.out.println();\n\n }", "public void mergeSort(ArrayList <Comparable> a, int first, int last){\r\n\t\t\r\n\t\tif (last - first == 0) {\r\n\t\t\tsteps ++;\r\n\t\t}else if (last - first == 1) {\r\n\t\t\tsteps += 4; \r\n\t\t\tif (a.get(first).compareTo(a.get(last)) > 0) {\r\n\t\t\t\tsteps += 5;\r\n\t\t\t\tswap(a, first, last);\r\n\t\t\t\t\r\n\t\t\t}\r\n\t\t}else {\r\n\t\t\tsteps += 3;\r\n\t\t\tint mid = (last + first)/2;\r\n\t\t\tsteps += 4;\r\n\t\t\tmergeSort(a, first, mid);\r\n\t\t\tmergeSort(a, mid + 1, last);\r\n\t\t\tmerge(a, first, mid, last);\r\n\t\t}\r\n\t\tSystem.out.println();\r\n\t\tSystem.out.println(\"Merge Sort\");\r\n\t\tSystem.out.println();\r\n\t}", "public static void mergeSort(int a[]) {\n\t sort(a, 0, a.length-1); \n\t }", "public void merge(paintIntegers[] arr, int lidx, int midx, int ridx){\n int leftn = midx - lidx + 1;\n int rightn = ridx - midx;\n\n //instantiating the left and right arrays\n int Left[] = new int [leftn];\n int Right[] = new int [rightn];\n\n //copies the data from original to the left and right\n for (int i=0; i < leftn; ++i) {\n Left[i] = arr[lidx + i].val;\n }\n for (int j=0; j < rightn; ++j) {\n Right[j] = arr[midx + 1 + j].val;\n }\n\n //merges the two arrays and updates the original array\n //initializes leftIndex and rightIndex to iterate over the left and right arrays\n //if it is added to the original array, then where it came from, it would increment\n int leftIndex = 0;\n int rightIndex = 0;\n int k = lidx; //to properly align where the elements to go, left\n //System.out.println(k);\n //while it hasnt gone through all the elements in the left and right array\n //between the two arrays check which one is lowest, and then updates original array\n while (leftIndex < leftn && rightIndex < rightn)\n {\n if (Left[leftIndex] <= Right[rightIndex])\n {\n arr[k].val = Left[leftIndex];\n sorting.add(paintIntegers.deepCopy(arr));//adds current array to list\n leftIndex++;\n }\n else\n {\n arr[k].val = Right[rightIndex];\n sorting.add(paintIntegers.deepCopy(arr));//adds current array to list\n rightIndex++;\n }\n k++;\n }\n //if there are some left on the left array then just adds to original array\n //possible because all the elements in right array have been added\n //all thats left is the sorted elements from the left array\n while (leftIndex < leftn)\n {\n arr[k].val = Left[leftIndex];\n sorting.add(paintIntegers.deepCopy(arr));//adds current array to list\n leftIndex++;\n k++;\n }\n //same explanation as above but with the right array\n while (rightIndex < rightn)\n {\n arr[k].val = Right[rightIndex];\n sorting.add(paintIntegers.deepCopy(arr));//adds current array to list\n rightIndex++;\n k++;\n }\n }", "private void merge(int[] left, int[] right, int[] a) {\n\t\t// i - left\n\t\t// j - right\n\t\t// k - original\n\t\tint i = 0, j = 0, k = 0;\n\t\tint sL = left.length;\n\t\tint sR = right.length;\n\n\t\twhile (i < sL && j < sR) {\n\t\t\tif (left[i] < right[j]) {\n\t\t\t\ta[k] = left[i];\n\t\t\t\ti++;\n\t\t\t} else {\n\t\t\t\ta[k] = right[j];\n\t\t\t\tj++;\n\t\t\t}\n\t\t\tk++;\n\t\t}\n\n\t\twhile (i < sL) {\n\t\t\ta[k] = left[i];\n\t\t\tk++;\n\t\t\ti++;\n\t\t}\n\t\twhile (j < sR) {\n\t\t\ta[k] = right[j];\n\t\t\tk++;\n\t\t\tj++;\n\t\t}\n\t}", "private void mergesort(ToCompare[] a, int l, int r) throws BrokenBarrierException, InterruptedException {\n if (l >= r) {\r\n return;\r\n }\r\n\r\n //recursion step: a[l..r] is not empty \r\n //divide into sublists and merge \r\n int m = (l + r) / 2;\r\n mergesort(a, l, m);\r\n mergesort(a, m + 1, r);\r\n merge(a, l, m, r);\r\n }", "private static void mergeSort(int[] num, int low, int high) {\n\t\tif ((high - low) >= 1) {\n\n\t\t\t// find the middle index\n\t\t\tint middle = (low + high) / 2;\n\n\t\t\t// make recursive calls to the 'left' and 'right' sides of the sublist\n\t\t\tmergeSort(num, low, middle);\n\t\t\tmergeSort(num, middle + 1, high);\n\n\t\t\t// merge the sublists back together\n\t\t\tmerge(num, low, middle, middle + 1, high);\n\n\t\t}\n\t}", "public void mergesort(int[] a, int startI, int endI) {\n\t\t\n\t\t//int si= a.length-1;\n\t\tint [] val = new int[1];\n\t\tint midPoint;\n\t\tlong heapSize = Runtime.getRuntime().totalMemory();\n\t\tlong heapFreeSize = Runtime.getRuntime().freeMemory(); \n\t\t//System.out.println(\"current heap size \"+heapsize);\n\t\tmidPoint = (endI+startI)/2; //midpoint for array\n\t\t\n\t\tif(heapFreeSize<1212015976)\n\t\tSystem.out.println(\"Start: \"+startI+\" End: \"+endI+\" Mid: \"+midPoint+\" current heap size \"+heapSize+\" current free heap \"+heapFreeSize);\n\t\tif (endI-startI < 1) {\n\t\t\tval[0]=a[startI];\n\t\t\t//System.out.println(\"returning \"+val[0]);\n\t\t\treturn ;\n\t\t}\n\t\t/*try\n\t\t{\n\t\t Thread.sleep(3000);\n\t\t}\n\t\tcatch(InterruptedException ex)\n\t\t{\n\t\t Thread.currentThread().interrupt();\n\t\t}*/\n\t\n\t\tmergesort(a, startI, midPoint); //split left\n\t\t\n\t\t\n\t\t//System.out.println(\"Start 2: \"+startI+\" End: \"+endI+\" Mid: \"+midPoint);\n\t\tmergesort(a, midPoint+1, endI);\t\t//split right\n\t\ttemp=mergeSortedArrays(a, startI, midPoint, midPoint+1, endI); //by defining positions in array, we are taking out array slices\n\t\t/*for (int i=0;i<temp.length;i++) {\n\t\t\ta[i]=temp[i];\n\t\t}*/\n\t\t/*System.out.println(\"Printing Temp=>\");\n\t\t\n\t\tfor (int i=0;i<temp.length;i++) {\n\t\t\tSystem.out.print(temp[i]+\", \");\n\t\t}\n\t\tSystem.out.println(\"\\n Printing A=>\");\n\t\t\n\t\tfor (int i=startI;i<endI;i++) {\n\t\t\tSystem.out.print(a[i]+\", \");\n\t\t}\n\t\tSystem.out.println(\"==>\");\n\t\treturn a;*/\n\t\t\n\t\t//System.out.println(\"==>\");\n\t\tint fill = startI;\n\t\tfor (int i=0;i<temp.length;i++) {\n\t\t\ta[fill]=temp[i];\n\t\t\tfill++;\n\t\t}\n\t\treturn ;\n\t}", "static void mergesort(MappedByteBuffer A, MappedByteBuffer result, \r\n\t\t\tint start, int end) throws IOException {\r\n\r\n\t\tif (end - start < 8) { \r\n\t\t\treturn; \r\n\t\t}\r\n\r\n\t\tif (end - start == 8) {\r\n\t\t\tresult.position(start);\r\n\t\t\tint left = result.getInt();\r\n\t\t\tint right = result.getInt();\r\n\t\t\tif (left > right) {\r\n\t\t\t\tresult.position (start);\r\n\t\t\t\tresult.putInt (right);\r\n\t\t\t\tresult.putInt (left);\r\n\t\t\t}\r\n\t\t\treturn;\r\n\t\t}\r\n\r\n\t\tint mid = (end + start)/8*4;\r\n\t\tmergesort (result, A, start, mid);\r\n\t\tmergesort (result, A, mid, end);\r\n\r\n\t\tresult.position(start);\r\n\t\tfor (int i = start, j = mid, idx=start; idx < end; idx += 4) {\r\n\t\t\tint Ai = A.getInt (i);\r\n\t\t\tint Aj = 0;\r\n\t\t\tif (j < end) { Aj = A.getInt (j); }\r\n\t\t\tif (j >= end || (i < mid && Ai < Aj)) { \r\n\t\t\t\tresult.putInt (Ai);\r\n\t\t\t\ti += 4;\r\n\t\t\t} else {\r\n\t\t\t\tresult.putInt (Aj);\r\n\t\t\t\tj += 4;\r\n\t\t\t}\r\n\t\t}\r\n\t}", "private static void norecursion_mergesort(String[] arr) {\r\n\t\tint n = arr.length, k = 2;\r\n\t\twhile (k <= n) {\r\n\t\t\tfor (int i = 0;i < n;i++) {\r\n\t\t\t\tif ((i+1) % k == 0) {\r\n\t\t\t\t\tmerge(arr, i+1-k, i+1-k/2, i+1);\r\n\t\t\t\t\tif (n-(i+1) < k) {\r\n\t\t\t\t\t\tmerge(arr, (i+1)-k, i+1, n);\r\n\t\t\t\t\t\tbreak;\r\n\t\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\tk *= 2;\r\n\t\t}\r\n\t}", "public static int[] mergeSortHelper(int num[]) {\n\t\tmergeSort(num, 0, num.length - 1);\n\t\treturn num;\n\t}", "static void mergeSortInner(int[] array, int low, int high, int[] extra) {\n if (low == high - 1) {\r\n return;\r\n }\r\n if (low >= high) {\r\n return;\r\n }\r\n // 1. 平均切分\r\n int mid = low + (high - low) / 2;\r\n // [low, mid) + [mid, high)\r\n // 2. 分治算法处理所有两个小区间\r\n mergeSortInner(array, low, mid, extra);\r\n mergeSortInner(array, mid, high, extra);\r\n\r\n // 左右两个小区间已经有序了\r\n merge(array, low, mid, high, extra);\r\n }", "static void MergeSort(int[] A, int p, int r) {\n\t\tif (p < r) {\n\t\t\tint q = (p + r) / 2;\n\t\t\tMergeSort(A, p, q);\n\t\t\tMergeSort(A, q + 1, r);\n\t\t\tMerge(A, p, q, r);\n\t\t}\n\t}", "public MergeSort(){\r\n \r\n }", "public static void mergeSort(int[] elts) {\r\n\t\tint size = elts.length;\r\n\t\tif (size == 2) {\r\n\t\t\tif (elts[0] > elts[1])\r\n\t\t\t\tIntArraySortUtils.swap(elts, 0, 1);\r\n\t\t}\r\n\t\telse if (size > 2) {\r\n\t\t\tPair<int[], int[]> split = splitArray(elts);\r\n\t\t\tint[] left = split.first;\r\n\t\t\tint[] right = split.second;\r\n\t\t\tmergeSort(left);\r\n\t\t\tmergeSort(right);\r\n\t\t\tIntArraySortUtils.merge(elts, left, right);\r\n\t\t}\r\n\r\n\t}", "private void mergesort(ArrayList<Integer> list, int l, int h) {\n\t\tif (l < h) {\n\t\t\tint m = (l + h) / 2;\n\t\t\tmergesort(list, l, m);\n\t\t\tmergesort(list, m + 1, h);\n\t\t\tSystem.out.println(list);\n\t\t\tmerge(list, l, m, h);\n\t\t}\n\t}", "private int[] mergeSort(int[] nums, int start, int end) {\n if (start == end) {\n return new int[]{nums[start]};\n }\n\n // keep dividing the entire array into sub-arrays\n int mid = (end - start) / 2 + start;\n int[] left = mergeSort(nums, start, mid);\n int[] right = mergeSort(nums, mid + 1, end);\n // return merged array\n return mergeTwoSortedArrays(left, right);\n }", "private static <T extends Comparable,S> void mergeSort(T[] src, S[] src2,\n\t\t\tT[] dest,\n\t\t\tS[] dest2,\n\t\t\tint low,\n\t\t\tint high,\n\t\t\tint off) {\n\t\tint length = high - low;\n\n\t\t// Insertion sort on smallest arrays\n\t\tif (length < INSERTIONSORT_THRESHOLD) {\n\t\t\tfor (int i=low; i<high; i++)\n\t\t\t\tfor (int j=i; j>low &&\n\t\t\t\t\t\tdest[j-1].compareTo(dest[j])>0; j--)\n\t\t\t\t\tswap(dest,dest2, j, j-1);\n\t\t\treturn;\n\t\t}\n\n\t\t// Recursively sort halves of dest into src\n\t\tint destLow = low;\n\t\tint destHigh = high;\n\t\tlow += off;\n\t\thigh += off;\n\t\tint mid = (low + high) >>> 1;\n\t\tmergeSort(dest, dest2, src, src2,low, mid, -off);\n\t\tmergeSort(dest, dest2, src, src2, mid, high, -off);\n\n\t\t// If list is already sorted, just copy from src to dest. This is an\n\t\t// optimization that results in faster sorts for nearly ordered lists.\n\t\tif (src[mid-1].compareTo(src[mid]) <= 0) {\n\t\t\tSystem.arraycopy(src, low, dest, destLow, length);\n\t\t\tSystem.arraycopy(src2, low, dest2, destLow, length);\n\t\t\treturn;\n\t\t}\n\n\t\t// Merge sorted halves (now in src) into dest\n\t\tfor(int i = destLow, p = low, q = mid; i < destHigh; i++) {\n\t\t\tif (q >= high || p < mid && src[p].compareTo(src[q])<=0) {\n\t\t\t\tdest2[i] = src2[p];\n\t\t\t\tdest[i] = src[p++];\n\t\t\t}\n\t\t\telse {\n\t\t\t\tdest2[i] = src2[q];\n\t\t\t\tdest[i] = src[q++];\n\t\t\t}\n\t\t}\n\t}", "private static void mergeSortInternally(int[] a, int low, int high) {\n\n if (low >= high) {\n return;\n }\n int mid = low + (high - low) / 2;\n mergeSortInternally(a, low, mid);\n mergeSortInternally(a, mid + 1, high);\n System.out.println(\"low:\" + low + \", mid:\" + mid + \", high:\" + high);\n merge(a, low, mid, high);\n }", "public static int[] mergeSort(int[] arr, int lo, int hi) {\n //write your code here\n if(lo < hi) {\n int mid = (lo+hi)/2;\n int[] lft = mergeSort(arr, lo, mid);\n int[] rgt = mergeSort(arr, mid+1, hi);\n int[] res = mergeTwoSortedArrays(lft, rgt);\n return res;\n }\n return new int[]{arr[lo]}; // if(lo==hi)\n}", "private static void merge(int[] nums, int[] work, int start, int mid, int end){\n\t\tboolean loop = true;\n\t\tint counter1 = start;\n\t\tint counter2 = mid+1;\n\t\tint workCounter = start;\n\t\t\n\t\twhile(loop){\n\t\t\tif(counter1 > mid){\n\t\t\t\t// Copy all elements from 2nd end to work\n\t\t\t\tfor(int i=counter2; i<=end; i++)\n\t\t\t\t\twork[workCounter++] = nums[i];\n\t\t\t\tbreak;\n\t\t\t}\n\t\t\t\n\t\t\tif(counter2 > end){\n\t\t\t\t// Copy all elements from start-mid to work\n\t\t\t\tfor(int i=counter1; i<=mid; i++)\n\t\t\t\t\twork[workCounter++] = nums[i];\n\t\t\t\tbreak;\n\t\t\t}\n\t\t\t\n\t\t\t// Swap the number if the numbers in are not is sorted order\n\t\t\tif(nums[counter1] < nums[counter2]){\n\t\t\t\twork[workCounter] = nums[counter1]; \n\t\t\t\tcounter1++;\n\t\t\t}else{\n\t\t\t\twork[workCounter] = nums[counter2]; \n\t\t\t\tcounter2++;\n\t\t\t}\n\t\t\t\n\t\t\tworkCounter++;\n\t\t}\n\t\t\n\t\t// Copy the sorted work array into main array\n\t\tfor(int i=start; i <= end; i++)\n\t\t\tnums[i] = work[i];\n\t}", "private Mergesort() {\r\n }", "private static <T,S>void mergeSort(T[] src,S[] src2,\n\t\t\tT[] dest,\n\t\t\tS[] dest2,\n\t\t\tint low, int high, int off,\n\t\t\tComparator c) {\n\t\tint length = high - low;\n\n\t\t// Insertion sort on smallest arrays\n\t\tif (length < INSERTIONSORT_THRESHOLD) {\n\t\t\tfor (int i=low; i<high; i++)\n\t\t\t\tfor (int j=i; j>low && c.compare(dest[j-1], dest[j])>0; j--) \n\t\t\t\t\tswap(dest,dest2,j, j-1);\n\t\t\treturn;\n\t\t}\n\n\t\t// Recursively sort halves of dest into src\n\t\tint destLow = low;\n\t\tint destHigh = high;\n\t\tlow += off;\n\t\thigh += off;\n\t\tint mid = (low + high) >>> 1;\n\t\t\tmergeSort(dest,dest2, src, src2,low, mid, -off, c);\n\t\t\tmergeSort(dest,dest2, src, src2, mid, high, -off, c);\n\n\t\t\t// If list is already sorted, just copy from src to dest. This is an\n\t\t\t// optimization that results in faster sorts for nearly ordered lists.\n\t\t\tif (c.compare(src[mid-1], src[mid]) <= 0) {\n\t\t\t\tSystem.arraycopy(src, low, dest, destLow, length);\n\t\t\t\tSystem.arraycopy(src2, low, dest2, destLow, length);\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\t// Merge sorted halves (now in src) into dest\n\t\t\tfor(int i = destLow, p = low, q = mid; i < destHigh; i++) {\n\t\t\t\tif (q >= high || p < mid && c.compare(src[p], src[q]) <= 0) {\n\t\t\t\t\tdest2[i] = src2[p];\n\t\t\t\t\tdest[i] = src[p++];\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tdest2[i] = src2[q];\n\t\t\t\t\tdest[i] = src[q++];\n\t\t\t\t}\n\t\t\t}\n\t}", "public void mergeSort() throws Exception{\n\t\tif(this.qtd<=1)\n\t\t\tthrow new Exception(\"Nada para ordenar\");\n\t\tthis.sort(0,this.qtd-1);\n\t}", "public static void main(String[] args) {\n\t\t\tint arr[]= {2,9,8,3,6,4,10,7};\r\n\t\t\tint[] so=mergesort(arr,0,arr.length-1);\r\n\t\t\tSystem.out.println(Arrays.toString(so));\r\n//\t\t\tfor(int i=0;i<arr.length;i++)\r\n//\t\t\t\tSystem.out.print(so[i]+\" \");\r\n\t\t}", "private static <T extends Comparable<? super T>> void mergeSort(List<T> list, int begin, int mid, int finish, T[] auxiliaryArray){\n if(begin + 1 == finish)\n merge(list, begin, mid, mid + 1, finish, auxiliaryArray);\n else{\n if(begin < finish){\n mergeSort(list, begin, (mid + begin)/2, mid, auxiliaryArray);\n mergeSort(list, mid + 1, (finish + mid)/2, finish, auxiliaryArray);\n merge(list, begin, mid, mid + 1, finish, auxiliaryArray);\n }\n }\n }", "public List<Integer> chunkMergesort(List<Integer> S) {\n\t\tif (S.size() < 2) {\n \t\t\treturn S;\n \t\t}\n \t\tint c = chunks(S);\n \t\tif (c == 1){\n \t\t\treturn S;\n \t\t}\n \t\tChunks p = chunkDivide(S, c);\n \t\tList<Integer> S1 = p.left;\n \t\tList<Integer> S2 = p.right;\n\t\tS1 = chunkMergesort(S1);\n\t\tS2 = chunkMergesort(S2);\n\t\tS = merge(S1, S2);\n\t\treturn S;\n\t}", "static double[] mergeSortRecursive (double a[]) {\r\n \tif(a==null){\r\n \t\tSystem.out.print(\"Array empty\");\r\n \t\treturn null;\r\n \t}\r\n \tif(a.length>1) {\r\n \t\tint mid=a.length/2;\r\n \t\t//spilt left part\r\n \t\tdouble[] left =new double[mid];\r\n \t\tfor(int i =0 ; i <mid;i++) {\r\n \t\t\tleft[i]=a[i];\r\n \t\t}\r\n \t\t//spilt right part\r\n \t\tdouble[] right =new double[a.length-mid];\r\n \t\tfor(int i=mid; i< a.length;i++) {\r\n \t\t\tright[i-mid]=a[i];\r\n \t\t}\r\n \t\tmergeSortIterative(left);\r\n \t\tmergeSortIterative(right);\r\n \t\tint i=0;\r\n \t\tint j=0;\r\n \t\tint k=0;\r\n \t\t//Merge left and right arrays\r\n \t\twhile(i<left.length && j<right.length) {\r\n \t\t\tif(left[i]<right[j]) {\r\n \t\t\t\ta[k]=left[i];\r\n \t\t\t\ti++;\r\n \t\t\t}else {\r\n \t\t\t\ta[k]=right[j];\r\n \t\t\t\tj++;\r\n \t\t\t}\r\n \t\t\tk++;\r\n \t\t}\r\n \t\t//Collect remaining elements\r\n \t\twhile(i<left.length) {\r\n \t\t\ta[k]=left[i];\r\n \t\t\ti++;\r\n \t\t\tk++;\r\n \t\t}\r\n \t\twhile(j<right.length) {\r\n \t\t\ta[k]=right[j];\r\n \t\t\tj++;\r\n \t\t\tk++;\r\n \t\t}\r\n \t}\r\n\r\n \treturn a;\r\n }", "private void merge(int lb, int mid, int ub, int[] ar){\n\t\tint i = lb ,j = lb + mid, k = 0;\n\t\tint[] out = new int[ub - lb + 1];\n\t\twhile( (i <= lb + mid - 1) && (j <= ub)){\n\t\t if(ar[i] <= ar[j]) out[k++] = ar[i++];\n\t\t else out[k++] = ar[j++];\n\t\t}\n\t\twhile(i <= lb + mid - 1) out[k++] = ar[i++];\n\t\twhile(j <= ub) \t out[k++] = ar[j++];\n\t\tfor(int l = 0; l < k; l++) ar[lb + l] = out[l];\n\t}", "@Test(timeout = SHORT_TIMEOUT)\n public void testTinyMergeSort() {\n //size-0 arr\n toSort = new IntPlus[0];\n sortedInts = cloneArr(toSort);\n Sorting.mergeSort(sortedInts, comp);\n\n assertArrayEquals(toSort, sortedInts); //Sort can't rearrange anything\n\n //size-1 arr\n toSort = new IntPlus[1];\n toSort[0] = new IntPlus(42);\n sortedInts = cloneArr(toSort);\n Sorting.mergeSort(sortedInts, comp);\n\n assertArrayEquals(toSort, sortedInts); //Sort can't rearrange anything\n }", "private static void merge(int[] a, int[] b) {\n\t\tint aI = a.length-1;\r\n\t\tint bI = b.length-1;\r\n\t\tint posI=a.length-b.length-1;\r\n\t\t\r\n\t\r\n\t\twhile (aI>=0 ) {\r\n\t\t\tif(a[posI]> b[bI]) {//missing the test for posI>=0 see mergeInPlace(int a[],int b[])\r\n\t\t\t\ta[aI]=a[posI];\r\n\t\t\t\tposI--;\t\r\n\t\t\t}\r\n\t\t\telse {\r\n\r\n\t\t\t\ta[aI]=b[bI];\r\n\t\t\t\tbI--;\r\n\r\n\t\t\t}\r\n\t\t\taI--;\r\n\t\t}\r\n\t\t\r\n\t\tfor (int x:a) {\r\n\t\t\tSystem.out.println(x);\r\n\t\t}\r\n\t}", "public void mergeSort(Comparable[] input) {\n\t\t\n\t\t// check if input array is null\n\t\tif (input == null)\n\t\t\tthrow new IllegalArgumentException(\"Input array cannot be null!\");\n\t\t\n\t\t// if input array is empty or contains only 1 element - there's no need to sort\n\t\tif (input.length < 2)\n\t\t\treturn;\n\t\t\n\t\t// set up environment\n\t\tsetUp(input);\n\t\t\n\t\t// variable to store final result list\n\t\tint list;\n\t\twhile (true) {\n\t\t\t\n\t\t\t// poll two lists from queue\n\t\t\tint list1 = poll();\n\t\t\tint list2 = poll();\n\t\t\t\n\t\t\t// merge them and save result into created variable\n\t\t\tlist = merge(list1, list2);\n\t\t\t\n\t\t\t// if queue is empty - there's nothing else to merge - break loop\n\t\t\tif (isEmpty())\n\t\t\t\tbreak;\n\t\t\t\n\t\t\t// if queue is not empty - add merged list to it\n\t\t\tadd(list);\n\t\t}\n\t\t\n\t\t// write result\n\t\twriteBack(input, list);\n\t}", "public static Integer[] mergeSort(int[] left, int[] right, int k) {\n Integer[] output;\n if (k <= left.length + right.length) {\n output = new Integer[k];\n } else {\n output = new Integer[left.length + right.length];\n k = left.length + right.length;\n }\n int leftIdx = 0;\n int rightIdx = 0;\n int outputIdx = 0;\n while (k > 0) {\n if (leftIdx >= left.length) {\n leftIdx = -1;\n }\n if (rightIdx >= right.length) {\n rightIdx = -1;\n }\n if (leftIdx != -1 && rightIdx != -1) {\n int leftVal = left[leftIdx];\n int rightVal = right[rightIdx];\n if (left[leftIdx] == right[rightIdx]) {\n if (k >= 2) {\n output[outputIdx++] = leftVal;\n output[outputIdx++] = rightVal;\n leftIdx++;\n rightIdx++;\n k -= 2;\n } else {\n output[outputIdx++] = leftVal;\n leftIdx++;\n k--;\n }\n } else if (leftVal < rightVal) {\n output[outputIdx++] = leftVal;\n leftIdx++;\n k--;\n } else {\n output[outputIdx++] = rightVal;\n rightIdx++;\n k--;\n }\n } else if (leftIdx != -1) {\n output[outputIdx++] = left[leftIdx++];\n k--;\n } else if (rightIdx != -1) {\n output[outputIdx++] = right[rightIdx++];\n k--;\n }\n }\n return output;\n }", "public static void mergesort(int low, int high) {\n\t\tif (low < high) {\n\t\t\t// Get the index of the element which is in the middle\n\t\t\tint middle = low + (high - low) / 2;\n\t\t\t// Sort the left side of the array\n\t\t\tmergesort(low, middle);\n\t\t\t// Sort the right side of the array\n\t\t\tmergesort(middle + 1, high);\n\t\t\t// Combine them both\n\t\t\tmerge(low, middle, high);\n\t\t}\n\t}", "private static void merge(int[] arr, int start, int mid, int end) {\n\t\tint length1 = mid - start + 1;\n\t\tint length2 = end - mid;\n\t\tint left[] = new int[length1];\n\t\tint right[] = new int[length2];\n\t\tfor (int index =0; index < length1; index++) {\n\t\t\tleft[index] = arr[start+index];\n\t\t}\n\t\tfor (int index =0; index < length2; index++) {\n\t\t\tright[index] = arr[mid+index+1];\n\t\t}\n\t\tint leftIndex = 0;\n\t\tint rightIndex = 0;\n\t\tint index = start;\n\t\twhile (leftIndex < length1 && rightIndex < length2) {\n\t\t\tif (left [leftIndex] < right[rightIndex]) {\n\t\t\t\tarr[index] = left[leftIndex];\n\t\t\t\tleftIndex ++;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tarr[index] = right[rightIndex];\n\t\t\t\trightIndex++;\n\t\t\t\tnumberOfInversions += (mid - leftIndex)+1;\n\t\t\t}\n\t\t\tindex++;\n\t\t}\n\t\twhile (leftIndex < length1) {\n\t\t\tarr[index] = left[leftIndex];\n\t\t\tleftIndex++;\n\t\t\tindex++;\n\t\t}\n\t\twhile (rightIndex < length2) {\n\t\t\tarr[index] = right[rightIndex];\n\t\t\trightIndex++;\n\t\t\tindex++;\n\t\t}\n\t\t\t\n\t\t\n\t}", "public static ArrayList<Integer> mergeSort(ArrayList <Integer> list){\n System.out.println();\n System.out.println(\"Insertion Sort\");\n System.out.println();\n if (3 > 2){\n int mid= list.size()/2;\n ArrayList<Integer> left= new ArrayList<Integer>(mid);\n ArrayList<Integer> right=new ArrayList<Integer>(list.size()-mid);\n for (int i = 0; i < mid; i++) {\n left.add(list.get(i));\n } \n\n for (int i = 0; i < list.size()-mid; i++) {\n right.add(list.get(i));\n } \n\n left = mergeSort(left); \n right = mergeSort(right);\n merge(left,right,list);\n }\n return list;\n }", "public static void mergeSort(String[] word,int[] lineNumber, int p, int r){\n int q;\n if(p<r){\n q=(p+r)/2;\n mergeSort(word,lineNumber, p, q);\n mergeSort(word,lineNumber,q+1, r);\n merge(word,lineNumber, p, q, r);\n }\n }", "static void sort(int arr[], int l, int r) \n { \n if (l < r) \n { \n // Find middle \n int m = (l+r)/2; \n \n // Sort both halves\n sort(arr, l, m); \n sort(arr , m+1, r); \n \n // Merge both halves after they have been sorted \n merge(arr, l, m, r); \n } \n }", "private void recMergeSort(final long[] workSpace, final int lowerBound,\n final int upperBound) {\n if (lowerBound == upperBound) // if range is 1,\n return; // no use sorting\n else { // find midpoint\n final int mid = (lowerBound + upperBound) / 2;\n // sort low half\n recMergeSort(workSpace, lowerBound, mid);\n // sort high half\n recMergeSort(workSpace, mid + 1, upperBound);\n // merge them\n merge(workSpace, lowerBound, mid + 1, upperBound);\n } // end else\n }", "public T[] mergeSort(T[] array) {\n if (array.length == 1) {\n return array;\n }\n if (array.length == 2) {\n Comparable first = (Comparable) array[0];\n if (((Comparable) array[0]).compareTo(array[1]) > 0) {\n array[0] = array[1];\n array[1] = (T) first;\n }\n return array;\n }\n int mid = array.length / 2;\n T[] first = (T[]) new Object[mid];\n T[] second = (T[]) new Object[array.length - mid];\n for (int i = 0; i < mid; i++) {\n first[i] = array[i];\n }\n for (int i = mid; i < array.length; i++) {\n second[i - mid] = array[i];\n }\n first = mergeSort(first);\n second = mergeSort(second);\n int j = 0;\n int k = 0;\n int i = 0;\n while ((first.length != j) && (second.length != k)) {\n if (((Comparable) first[j]).compareTo(second[k]) < 0) {\n array[i] = first[j];\n j++;\n i++;\n } else {\n array[i] = second[k];\n k++;\n i++;\n }\n }\n if (first.length == j) {\n for (; i < array.length; i++) {\n array[i] = second[k];\n k++;\n }\n } else {\n for (; i < array.length; i++) {\n array[i] = first[j];\n j++;\n }\n }\n return array;\n }", "private void merge(ArrayList <Comparable> a, int first, int mid, int last){\r\n\t\tsteps += 5;\r\n\t\tArrayList<Comparable> temp = new ArrayList<Comparable>();\r\n\t\tint firstInd = first;\r\n\t\tint middle = mid + 1;\r\n\t\tsteps += 2;\r\n\t\twhile (firstInd <= mid && (middle) <= last) {\r\n\t\t\tif (a.get(firstInd).compareTo(a.get(middle)) < 0) {\r\n\t\t\t\ttemp.add(a.get(firstInd));\r\n\t\t\t\tfirstInd ++;\r\n\t\t\t\tsteps += 7;\r\n\t\t\t}else if (a.get(middle).compareTo(a.get(firstInd)) < 0){\r\n\t\t\t\ttemp.add(a.get(middle));\r\n\t\t\t\tmiddle++;\r\n\t\t\t\tsteps += 7;\r\n\t\t }else {\r\n\t\t\t\ttemp.add(a.get(middle));\r\n\t\t\t\tmiddle++;\r\n\t\t\t\tsteps += 3;\r\n\t\t\t}\r\n\t\t}\r\n\t\t\r\n\t\tif (firstInd >= mid + 1) {\r\n\t\t\tsteps += 4;\r\n\t\t\tfor (int i = middle; i <= last; i++) {\r\n\t\t\t\ttemp.add(a.get(i));\r\n\t\t\t}\r\n\t\t\tsteps += 3;\r\n\t\t}else {\r\n\t\t\tsteps += 2;\r\n\t\t\tfor (int i = firstInd; i <= mid; i++) {\r\n\t\t\t\ttemp.add(a.get(i));\r\n\t\t\t}\r\n\t\t\tsteps += 3;\r\n\t\t}\r\n\t\tsteps += 3;\r\n\t\tint j = 0;\r\n\t\tfor (int i = first; i <= last; i++) {\r\n\t\t\ta.set(i, temp.get(j));\r\n\t\t\tj++;\r\n\t\t\tsteps += 4;\r\n\t\t}\r\n\t\t\r\n\t\tSystem.out.println();\r\n\t\tSystem.out.println(\"Merge\");\r\n\t\tSystem.out.println();\r\n\r\n\t}", "public static void mergeSort(int[] array,int left,int right) {\n if(left<right)\n {\n int middle=(left+right)/2; //9 --> 0,9 -->0-4 5-9|| 8 --> 0-4 5-8\n mergeSort(array,left,middle);\n mergeSort(array,middle+1,right);\n merge(array,left,right,middle);\n }\n }", "private static void merge(Comparable[] a, int[] index, int[] aux, int lo, int mid, int hi){\n for(int k=lo;k<=hi;k++){\n aux[k]=index[k];\n }\n int i=lo,j=mid+1;\n for(int k=lo;k<=hi;k++){\n if(i>mid) index[k]=aux[j++];\n else if(j>hi) index[k]=aux[i++];\n else if(less(a[aux[j]],a[aux[i]])) index[k]=aux[j++];\n else index[k]=aux[i++];\n }\n }", "private static void mergeAsc(int arr[], int start, int mid, int end) {\n\r\n\t\tint subArrLen1 = mid - start + 1;\r\n\t\tint subArrLen2 = end - mid;\r\n\r\n\t\t// create the sub Arrays as temporary storage\r\n\t\tint subArray1[] = new int[subArrLen1];\r\n\t\tint subArray2[] = new int[subArrLen2];\r\n\r\n\t\t// copy data in temporary arrays\r\n\r\n\t\tfor (int i = 0; i < subArrLen1; i++) {\r\n\t\t\tsubArray1[i] = arr[start + i];\r\n\t\t}\r\n\r\n\t\tfor (int i = 0; i < subArrLen2; i++) {\r\n\t\t\tsubArray2[i] = arr[mid + i + 1];\r\n\t\t}\r\n\r\n\t\t// merging the temporary arrays\r\n\r\n\t\tint i = 0, j = 0;\r\n\t\tint k = start;\r\n\r\n\t\twhile (i < subArrLen1 && j < subArrLen2) {\r\n\t\t\tif (subArray1[i] <= subArray2[j]) {\r\n\t\t\t\tarr[k] = subArray1[i];\r\n\t\t\t\ti++;\r\n\t\t\t} else {\r\n\t\t\t\tarr[k] = subArray2[j];\r\n\t\t\t\tj++;\r\n\t\t\t}\r\n\t\t\tk++;\r\n\r\n\t\t}\r\n\r\n\t\t// copy left over elements of subArray2[]\r\n\t\twhile (i < subArrLen1) {\r\n\t\t\tarr[k] = subArray1[i];\r\n\t\t\ti++;\r\n\t\t\tk++;\r\n\t\t}\r\n\r\n\t\t// copy left over elements of subArray2[]\r\n\t\twhile (j < subArrLen2) {\r\n\t\t\tarr[k] = subArray2[j];\r\n\t\t\tj++;\r\n\t\t\tk++;\r\n\t\t}\r\n\r\n\t}", "public FindInversionsAndMergeSort() {\n\t\tthis.intArr = null;\n\t}", "private int[] merge(int[] left, int[] right) {\r\n\t\tint[] merged = new int[(left.length + right.length)];\r\n\r\n\t\t// l -> arrL index and r -> arrR index\r\n\t\tint l = 0, r = 0;\r\n\t\tfor (int i = 0; i < merged.length; i++) {\r\n\r\n\t\t\tif (l >= left.length) {\r\n\t\t\t\tmerged[i] = right[r++];\r\n\t\t\t} \r\n\t\t\telse if (r >= right.length) {\r\n\t\t\t\tmerged[i] = left[l++];\r\n\t\t\t}\r\n\t\t\telse if (left[l] >= right[r]) {\r\n\t\t\t\t// The total inversions will always be left.length - l\r\n\t\t\t\tcounter += (left.length - l);\r\n\t\t\t\tmerged[i] = right[r++];\r\n\t\t\t}\r\n\t\t\telse if (left[l] < right[r]) {\r\n\t\t\t\tmerged[i] = left[l++];\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\treturn merged;\r\n\t}", "public static void mergeSortNonRecursive(int[] input){\n int[] arr;\n Stack<int[]> unsortedStack = new Stack();\n Stack<int[]> sortedStack = new Stack();\n unsortedStack.push(input);\n //while !unsortedStack.isempty, needs to pop int[] from stack , assign to arr, pop status\n //if(arr.length>1), split arr to arr.left and arr.right,push left and right into stack, push false to stack twice\n //else if(arr.length<=1), push arr to sortedStack (while (!unsorted.isempty && peek().length==arr,merge and pushback to stack again)\n //\n\n while(!unsortedStack.empty()) {\n arr = unsortedStack.pop();\n if (arr.length > 1) {\n int begin = 0,end=arr.length,mid=arr.length/2;\n int[] left = Arrays.copyOfRange(arr, begin, mid);\n int[] right = Arrays.copyOfRange(arr, mid, end);\n unsortedStack.push(left);\n unsortedStack.push(right);\n } else {\n while(!sortedStack.isEmpty() && sortedStack.peek().length<=arr.length){\n arr = merge(arr, sortedStack.pop());\n }\n sortedStack.push(arr);\n }\n }\n while(sortedStack.size()>1){\n arr = merge(sortedStack.pop(), sortedStack.pop());\n sortedStack.push(arr);\n }\n int[] tmp = sortedStack.pop();\n for(int i=0;i<input.length;i++){\n input[i]=tmp[i];\n }\n\n }", "static double[] mergeSortIterative (double a[]) {\r\n \tif(a==null){\r\n \t\tSystem.out.print(\"Array: empty\");\r\n \t\treturn null;\r\n \t}\r\n \tint length = (a.length-1);\r\n \tint currentSize; //varies from 1 to n/2\r\n\t\tint leftStart; // pick starting index of left subarray to be merged\r\n\t\tfor(currentSize=1; currentSize <= length; currentSize = (2*currentSize)) { //Merge subarrays in bottom up manner\r\n\t\t\t for(leftStart =0; leftStart < length ; leftStart += (2*currentSize)) { //Pick starting point of differnet subarrays of current size\r\n\t\t\t\t int mid = leftStart + currentSize -1;\r\n\t\t\t\t int rightEnd = Math.min(leftStart+2*currentSize-1, length);\r\n\t\t\t\t merge(a,leftStart,mid,rightEnd);\r\n\t\t\t }\r\n\t\t }\r\n\t\t return a;\r\n }", "private static int[] merge( int[] a, int[] b )\n {\n int[] retList = new int[a.length + b.length];\n\t int aPos = 0, bPos = 0;\n\t for(int x = 0; x < retList.length; x ++) {\n\t\t if(aPos < a.length && bPos < b.length) {\n\t\t\t if(a[aPos] < b[bPos]) {\n\t\t\t\t retList[x] = a[aPos];\n\t\t\t\t aPos ++;\n\t\t\t }\n\t\t\t else {\n\t\t\t\t retList[x] = b[bPos];\n\t\t\t\t bPos ++;\n\t\t\t }\n\t\t }\n\t\t else if(aPos < a.length) {\n\t\t\t retList[x] = a[aPos];\n\t\t\t aPos ++;\n\t\t }\n\t\t else {\n\t\t\t retList[x] = b[bPos];\n\t\t\t bPos ++;\n\t\t }\n\t }\n return retList;\n }", "private static void mergesort(String[] arr, int s, int e) {\n\t\tint len = e - s;\r\n\t\tif (len > 1) {\r\n\t\t\tint mid = (s + e) / 2;\r\n\t\t\tmergesort(arr, s, mid);\r\n\t\t\tmergesort(arr, mid, e);\r\n\t\t\tmerge(arr, s, mid, e);\r\n\t\t}\r\n\t}", "private static void mergeDesc(int arr[], int start,int mid, int end) {\n\r\n\t\t\t\tint subArrLen1 = mid - start + 1;\r\n\t\t\t\tint subArrLen2 = end - mid;\r\n\r\n\t\t\t\t// create the sub Arrays as temporary storage\r\n\t\t\t\tint subArray1[] = new int[subArrLen1];\r\n\t\t\t\tint subArray2[] = new int[subArrLen2];\r\n\r\n\t\t\t\t// copy data in temporary arrays\r\n\r\n\t\t\t\tfor (int i = 0; i < subArrLen1; i++) {\r\n\t\t\t\t\tsubArray1[i] = arr[start + i];\r\n\t\t\t\t}\r\n\r\n\t\t\t\tfor (int i = 0; i < subArrLen2; i++) {\r\n\t\t\t\t\tsubArray2[i] = arr[mid + i + 1];\r\n\t\t\t\t}\r\n\r\n\t\t\t\t// merging the temporary arrays\r\n\r\n\t\t\t\tint i = 0, j = 0;\r\n\t\t\t\tint k = start;\r\n\r\n\t\t\t\twhile (i < subArrLen1 && j < subArrLen2) {\r\n\t\t\t\t\tif (subArray1[i] > subArray2[j]) {\r\n\t\t\t\t\t\tarr[k] = subArray1[i];\r\n\t\t\t\t\t\ti++;\r\n\t\t\t\t\t} else {\r\n\t\t\t\t\t\tarr[k] = subArray2[j];\r\n\t\t\t\t\t\tj++;\r\n\t\t\t\t\t}\r\n\t\t\t\t\tk++;\r\n\r\n\t\t\t\t}\r\n\r\n\t\t\t\t// copy left over elements of subArray2[]\r\n\t\t\t\twhile (i < subArrLen1) {\r\n\t\t\t\t\tarr[k] = subArray1[i];\r\n\t\t\t\t\ti++;\r\n\t\t\t\t\tk++;\r\n\t\t\t\t}\r\n\r\n\t\t\t\t// copy left over elements of subArray2[]\r\n\t\t\t\twhile (j < subArrLen2) {\r\n\t\t\t\t\tarr[k] = subArray2[j];\r\n\t\t\t\t\tj++;\r\n\t\t\t\t\tk++;\r\n\t\t\t\t}\r\n\r\n\t}", "public void sort(int arr[], int l, int m, int r) \n {\n int n1 = m - l + 1; \n int n2 = r - m; \n /* Create temp arrays */\n int L[] = new int [n1]; \n int R[] = new int [n2]; \n /*Copy data to temp arrays*/\n for (int i=0; i<n1; ++i) \n L[i] = arr[l + i]; \n for (int j=0; j<n2; ++j) \n R[j] = arr[m + 1+ j]; \n /* Merge the temp arrays */\n // Initial indexes of first and second subarrays \n int i = 0, j = 0; \n // Initial index of merged subarry array \n int k = l; \n while (i < n1 && j < n2) \n { \n if (L[i] <= R[j]) \n { \n arr[k] = L[i]; \n i++; \n } \n else\n { \n arr[k] = R[j]; \n j++; \n } \n k++; \n } \n /* Copy remaining elements of L[] if any */\n while (i < n1) \n { \n arr[k] = L[i]; \n i++; \n k++; \n } \n /* Copy remaining elements of R[] if any */\n while (j < n2) \n { \n arr[k] = R[j]; \n j++; \n k++; \n } \n }", "public void merge(int[] inputArray, int start, int mid, int end) {\n int s1 = mid - start + 1;\n int s2 = end - mid;\n\n //Create a left and right array\n int L[] = new int [s1];\n int R[] = new int [s2];\n\n //Copy elements into two separate arrays\n for (int i=0; i<s1; ++i)\n L[i] = inputArray[start + i];\n for (int j=0; j<s2; ++j)\n R[j] = inputArray[mid + 1+ j];\n\n\n int i = 0, j = 0;\n int k = start;\n\n //Start your comparision\n while (i < s1 && j < s2)\n {\n if (L[i] <= R[j])\n {\n inputArray[k] = L[i];\n i++;\n }\n else\n {\n inputArray[k] = R[j];\n j++;\n }\n k++;\n }\n\n //Copy the remaining elements\n while (i < s1)\n {\n inputArray[k] = L[i];\n i++;\n k++;\n }\n while (j < s2)\n {\n inputArray[k] = R[j];\n j++;\n k++;\n }\n }", "private int merge(Comparable[] a, Comparable[] aux, int lo, int mid, int hi) {\n for (int k = lo; k <= hi; k++) {\n aux[k] = a[k];\n }\n\n int k = lo;\n int i = lo;\n int j = mid + 1;\n int count = 0;\n\n while (k < hi) {\n if (i > mid) a[k++] = aux[j++];\n else if (j > hi) a[k++] = aux[i++];\n else if (less(aux[j], aux[i])) {\n count += mid + 1 - i;\n a[k++] = aux[j++];\n }\n else a[k++] = aux[i++];\n }\n return count;\n }", "public static int[] bottomUpMergeSort(int[] num) {\n\n\t\tint[] temp = new int[num.length];\n\n\t\t// repeat merging process while width is smaller than length\n\t\tfor (int width = 2; width <= num.length; width *= 2) {\n\n\t\t\t// System.out.println(\"width = \" + width );\n\n\t\t\t// merge sublists\n\t\t\tfor (int i = 0; i < num.length; i += width)\n\t\t\t\tmergeLists(num, i, width, temp);\n\n\t\t\t// copy temp array back to original array\n\t\t\tfor (int i = 0; i < num.length; i++) {\n\t\t\t\tnum[i] = temp[i];\n\t\t\t\t// System.out.print(num[i] + \" \");\n\t\t\t}\n\n\t\t\t// System.out.println();\n\t\t\t// System.out.println();\n\t\t}\n\n\t\treturn num;\n\n\t}", "public static void mergeSort(List<Integer> values) {\r\n for (int stepSize = 2; stepSize < values.size(); stepSize *= 2) {\r\n for (int i = 0; i < values.size(); i += stepSize) {\r\n int prefixStart = i;\r\n int suffixStart = i + stepSize / 2;\r\n int suffixEnd = Math.min(values.size(), i + stepSize);\r\n merge(values, prefixStart, suffixStart, suffixEnd);\r\n } // for\r\n if (stepSize > values.size() / 2) {\r\n int prefixStart = 0;\r\n int suffixStart = stepSize;\r\n int suffixEnd = values.size();\r\n merge(values, prefixStart, suffixStart, suffixEnd);\r\n } // if\r\n //printList(values);\r\n } // for\r\n }", "private static void merge(int[] inputArray, int start, int mid, int end) {\n int tempArray [] = new int[end - start + 1]; //length of array\n\n // index counter for left side of Array\n int leftSlot = start;\n\n // index counter for right side of Array\n int rightSlot = mid + 1;\n\n // index for temp array\n int k = 0;\n\n while(leftSlot <= mid && rightSlot <= end){ //loop will run till left slot is less than mid value, and right slot is less than end index\n if(inputArray[leftSlot] < inputArray[rightSlot]){\n tempArray[k] = inputArray[leftSlot];\n leftSlot = leftSlot + 1; // incrementing the left slot\n }else {\n tempArray[k] = inputArray[rightSlot];\n rightSlot = rightSlot + 1; // incrementing the right slot\n }\n\n k = k+1; //need to increment the index of temp array so that value gets copied to correct place\n }\n\n /**\n * when it gets to here that means the above loop is completed and\n * both the left and right side of array are sorted\n */\n\n //there can be scenario that right array is sorted and left index is always less than right\n\n if(leftSlot <= mid){\n while(leftSlot <= mid){\n tempArray[k] = inputArray[leftSlot];\n leftSlot = leftSlot + 1;\n k = k + 1;\n }\n }else if(rightSlot <= end){\n while(rightSlot <= end){\n tempArray[k] = inputArray[rightSlot];\n rightSlot = rightSlot + 1;\n k = k + 1;\n }\n }\n for(int i=0;i< tempArray.length;i++){\n inputArray[start + i] = tempArray[i]; // copying back to original array\n }\n }", "private void sort(T[] arr, T[] temp, int lo, int hi) {\n if (lo >= hi) return; // we return if the size of the part equals 1\n int mid = lo + (hi - lo) / 2;\n sort(arr, temp, lo, mid); // sorting the left part\n sort(arr, temp, mid + 1, hi); // sorting the right part\n merge(arr, temp, lo, hi, mid); // merging two parts\n }", "public int[] mergeSort(int[] nums) {\n\t\tif(nums.length<=1) return nums;\n\t\t\n\t\tint mid=nums.length/2;\n\t\tint[] numsA=Arrays.copyOfRange(nums,0,mid);\n\t\tint[] numsB=Arrays.copyOfRange(nums,mid,nums.length);\n\t\t\n\t\treturn merge(mergeSort(numsA),mergeSort(numsB));\n\t\t\n\t}", "private static void sort(ArrayList<Integer> a, int left, int right) {\r\n\t\tif (left < right) {\r\n\t\t\tint mid = (left+right)/2;\r\n\t\t\t//sort both halves\r\n\t\t\tsort(a, left, mid);\r\n\t\t\tsort(a, mid + 1, right);\r\n\t\t\t//merge back\r\n\t\t\tmerge(a, left, mid, right);\r\n\t\t}\r\n\t}", "private void mergeSortRec(WordList list, Comparator<String> comp, int start, int end)\r\n {\r\n // TODO\r\n\t int middle = start + (end - start)/2; \r\n\t \r\n\t if(start < end) {\r\n\t\t mergeSortRec(list, comp, start, middle);\r\n\t\t mergeSortRec(list, comp, middle+1, end);\r\n\t\t mergeHelp(list, comp, start, middle, end);\r\n\t }\r\n\t \r\n }", "public static void enhancedMergeSort(int[] array, int size)\n {\n //base case\n if (size < 2)\n return;\n\n //sub arrays are sorted using insertion sort as\n //Mergesort has too much overhead for tiny subarrays.\n\n if ((size-1) < CUTOFF)\n {\n insertSort(array);\n return;\n }\n\n //dividing the array from the middle\n int mid = size / 2;\n int[] leftArray = new int[mid];\n int[] rightArray = new int[size - mid];\n for (int i = 0; i < mid; i++)\n {\n leftArray[i] = array[i];\n }\n for (int i = mid; i < size; i++)\n {\n rightArray[i - mid] = array[i];\n }\n //recursion\n mergeSort(leftArray, mid);\n mergeSort(rightArray, size - mid);\n\n // if the last element of left half is lesser or equal than first element of second half of the array\n // merge() call is skipped as it is not required.\n if ((array[mid] <= array[mid+1]))\n return;\n\n //merging the sorted halves\n merge(array, leftArray, rightArray, mid, size - mid);\n }", "private void sort()\n {\n // This implements Shell sort.\n // Unfortunately we cannot use the sorting functions from the library\n // (e.g. java.util.Arrays.sort), since the ones that work on int\n // arrays do not accept a comparison function, but only allow\n // sorting into natural order.\n int jump = length;\n boolean done;\n \n while( jump>1 ){\n jump /= 2;\n \n do {\n done = true;\n \n for( int j = 0; j<(length-jump); j++ ){\n int i = j + jump;\n \n if( !areCorrectlyOrdered( indices[j], indices[i] ) ){\n // Things are in the wrong order, swap them and step back.\n int tmp = indices[i];\n indices[i] = indices[j];\n indices[j] = tmp;\n done = false;\n }\n }\n } while( !done );\n }\n \n // TODO: integrate this with the stuff above.\n for( int i=1; i<length; i++ ){\n commonality[i] = commonLength( indices[i-1], indices[i] );\n }\n commonality[0] = -1;\n }", "private void merge(Comparable[] a, int min, int mid, int max){\n for(int t = min; t <= max;t++){\n aux[t] = a[t];\n }\n \n int i = min; // start index for left side\n int j = mid + 1; // start index for right side\n \n for(int k = min; k <= max; k++){\n if(i > mid){\n a[k] = aux[j++];\n }\n else if(j > max){\n a[k] = aux[i++];\n }\n else if(aux[i].compareTo(aux[j]) < 0 ){\n a[k] = aux[i++];\n }\n else {\n a[k] = aux[j++];\n }\n }\n }", "private static void merge(int[] nums, int low, int mid, int high) {\n int n1=mid-low+1;\n int n2=high-mid;\n int[] left=new int[n1];\n int[] right=new int[n2];\n for (int i = 0; i <n1 ; i++) {\n left[i]=nums[i+low];\n }\n for (int j = 0; j < n2; j++) {\n right[j]=nums[mid+1+j];\n }\n int k=low;\n int i=0,j=0;\n while (i< left.length && j< right.length){\n if(left[i]<right[j]){\n nums[k++]=left[i++];\n }\n else {\n nums[k++]=right[j++];\n }\n }\n //copy the remaining elements\n\n while (i<left.length){\n nums[k++]=left[i++];\n }\n while (j< right.length){\n nums[k++]=right[j++];\n }\n }", "void merge(int arr[], int l, int m, int r) {\r\n\t\tint[] temp = new int[r - l + 1];\r\n\t\tint i = l;\r\n\t\tint j = m + 1;\r\n\t\tint k = 0;\r\n\t\twhile (i <= m && j <= r) {\r\n\t\t\tif (arr[i] < arr[j])\r\n\t\t\t\ttemp[k++] = arr[i++]; // same as b[k]=a[i]; k++; i++;\r\n\t\t\telse\r\n\t\t\t\ttemp[k++] = arr[j++];\r\n\t\t}\r\n\r\n\t\twhile (j <= r) {\r\n\t\t\ttemp[k++] = arr[j++];\r\n\t\t}\r\n\t\twhile (i <= m) {\r\n\t\t\ttemp[k++] = arr[i++];\r\n\t\t}\r\n\r\n\t\tfor (i = r; i >= l; i--) {\r\n\t\t\tarr[i] = temp[--k];\r\n\t\t}\r\n\t}", "private static void mergeSorted(int[] a, int alength, int[] b) {\n int ai = alength - 1;\n int bi = b.length - 1;\n int ri = a.length - 1;\n while (ai >= 0 && bi >= 0) {\n if (a[ai] > b[bi]) {\n a[ri--] = a[ai--];\n } else {\n a[ri--] = b[bi--];\n }\n }\n\n while (bi >= 0) a[ri--] = b[bi--];\n //Note that you don't need to copy the contents of A after running out of elements in B. They are already in place.\n// while (ai >= 0) a[ri--] = a[ai--];\n }", "public static IntList mergeSort(IntList input) {\n\t\tif (input.length() <= 1)\n\t\t\treturn input;\n\t\tIntList part1 = new SimpleIntList();\n\t\tIntList part2 = new SimpleIntList();\n\t\tdivide(input,part1,part2);\n\t\tpart1 = mergeSort(part1);\n\t\tpart2 = mergeSort(part2);\n\t\treturn merge(part1,part2);\n\t}", "static void merge(double a[],int start,int mid, int end) {\r\n \tint i,j,k;\r\n \tint size1 = mid - start +1;\r\n \tint size2 = end - mid;\r\n \tif (size2 > 0 && size1 > 0) {\r\n \t\tdouble leftA[] = new double[size1]; // temp arrays\r\n \tdouble rightA[] = new double[size2];\r\n \tfor(i=0;i < size1;i++) leftA[i] = a[start+i]; //Copy data into temp arrays \r\n \tfor(j=0;j<size2;j++) rightA[j] = a[mid+1+j];\r\n \ti=0; // Merge temp arrays back into a[]\r\n \tj=0;\r\n \tk=start;\r\n \twhile (i<size1 && j < size2) {\r\n \t\tif(leftA[i]<=rightA[j]) {\r\n \t\t\ta[k]=leftA[i];\r\n \t\t\ti++;\r\n \t\t}else {\r\n \t\t\ta[k]=rightA[j];\r\n \t\t\tj++;\r\n \t\t}\r\n \t\tk++;\r\n \t}\r\n \twhile(i<size1) { //if remaining in leftA[] copy in\r\n \t\ta[k]=leftA[i];\r\n \t\ti++;\r\n \t\tk++;\r\n \t}\r\n \twhile(j<size2) { //if remaining in rightA[] copy in\r\n \t\ta[k]=rightA[j];\r\n \t\tj++;\r\n \t\tk++;\r\n \t}\r\n \t}\t\r\n }", "public static void mergeSort(int start, int end, int[] numbers) {\n int mid = (start + end) / 2;\n\n if (start < end) {\n // sort left half\n mergeSort(start, mid, numbers);\n\n // sort right half\n mergeSort(mid + 1, end, numbers);\n\n // merge\n merge(start, mid, end, numbers);\n }\n }", "private void merge(Comparable[] array, Comparable[] aux, int low, int high) {\n if (low >= high) return;\n\n int mid = (low + high) / 2;\n // Copy to aux\n for (int i = low; i <= high; i++) {\n aux[i] = array[i];\n }\n\n int i = low;\n int j = mid + 1;\n\n for (int k = low; k <= high; k++) {\n if (i > mid) array[k] = aux[j++];\n else if (j > high) array[k] = aux[i++];\n else if (aux[i].compareTo(aux[j]) <= 0) array[k] = aux[i++]; // <= makes it stable!!\n else array[k] = aux[j++];\n }\n }" ]
[ "0.7720987", "0.76503146", "0.76023114", "0.7580012", "0.7509526", "0.7484415", "0.74171895", "0.74028426", "0.7357797", "0.7333467", "0.73257565", "0.73112327", "0.7296708", "0.7274217", "0.7204499", "0.7194972", "0.71694595", "0.71596795", "0.7148461", "0.71083975", "0.7101238", "0.7100171", "0.7097989", "0.7095363", "0.7091035", "0.70577985", "0.7038071", "0.7037318", "0.70275396", "0.7020594", "0.7017614", "0.7011497", "0.6999161", "0.69948596", "0.6993535", "0.699312", "0.69858426", "0.69747335", "0.69596654", "0.6946666", "0.6943652", "0.69393176", "0.6937927", "0.6925756", "0.69215614", "0.6902682", "0.68990266", "0.6895233", "0.68927866", "0.6887481", "0.6880745", "0.68680626", "0.6854095", "0.68403554", "0.68382114", "0.6833725", "0.6810927", "0.6807736", "0.680676", "0.68060476", "0.67943203", "0.67883277", "0.67759275", "0.6771892", "0.6768917", "0.6755697", "0.67556095", "0.6754795", "0.67470324", "0.67419213", "0.67413664", "0.67389137", "0.67374897", "0.6737487", "0.6734929", "0.6723441", "0.67148596", "0.6714765", "0.6709848", "0.669923", "0.6699065", "0.66944104", "0.6694019", "0.6692822", "0.6688467", "0.6687894", "0.6680121", "0.66765213", "0.6675222", "0.6671927", "0.6665712", "0.66635185", "0.6663195", "0.66562027", "0.66551316", "0.66457385", "0.6642243", "0.66326576", "0.66318417", "0.6630979" ]
0.66668135
90
Sort function that uses merge
static void sort(int arr[], int l, int r) { if (l < r) { // Find middle int m = (l+r)/2; // Sort both halves sort(arr, l, m); sort(arr , m+1, r); // Merge both halves after they have been sorted merge(arr, l, m, r); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void mergesort()\n { sort(this.heap, 0, heap.size()-1);\n }", "public void mergeSort() {\n this.array = mergeSort(array);\n }", "public void sort() {\n if(c==null) {\n int middle;\n\n Comparable[] left, right;\n\n\n if (unsorted.length <= 1) {\n\n sorted = unsorted;\n\n } else {\n\n middle = unsorted.length / 2;\n\n\n left = new Comparable[middle];\n\n right = new Comparable[unsorted.length - middle];\n\n\n System.arraycopy(unsorted, 0, left, 0, middle);\n\n System.arraycopy(unsorted, middle, right, 0, unsorted.length - middle);\n\n\n // Внимание! Опа, рекурсия :)\n\n SimpleMerger leftSort = new SimpleMerger(left, c);\n\n SimpleMerger rightSort = new SimpleMerger(right,c);\n\n\n leftSort.sort();\n\n rightSort.sort();\n\n\n sorted = merge(leftSort.getSorted(), rightSort.getSorted());\n\n }\n }else{\n\n int middle;\n\n Object[] left, right;\n\n\n if (unsorted2.length <= 1) {\n\n sorted2 = unsorted2;\n\n } else {\n\n middle = unsorted2.length / 2;\n\n\n left = new Object[middle];\n\n right = new Object[unsorted2.length - middle];\n System.arraycopy(unsorted2, 0, left, 0, middle);\n\n System.arraycopy(unsorted2, middle, right, 0, unsorted2.length - middle);\n\n\n\n\n SimpleMerger leftSort = new SimpleMerger(left,c);\n\n SimpleMerger rightSort = new SimpleMerger(right,c);\n\n\n leftSort.sort();\n\n rightSort.sort();\n\n\n\n sorted2 = merge2(leftSort.getSorted2(), rightSort.getSorted2());\n\n }\n\n }\n }", "public static void sort(int[] mergeList) {\n for(int i = 0; i < mergeList.length - 1; i++) { //iterate through mergeList \n int min = mergeList[i];\n int minIndex = i;\n \n\n for(int j = i + 1; j < mergeList.length; j++) { //swap current list item with smaller value \n if(mergeList[j] < min) { \n min = mergeList[j]; \n minIndex = j; \n \n }\t\t\t\t\t\n }\n \n \n if(minIndex != i) { //swap original list with sorted list\n mergeList[minIndex] = mergeList[i];\n mergeList[i] = min;\n \n }\n }\n }", "public void sortGivenArray_date(){\n movieList = mergeSort(movieList);\n }", "void sort();", "void sort();", "public void mergeSort(){\r\n mergeSort(mArray, new int[mArray.length], 0 , mArray.length - 1);\r\n }", "private void mergeSort(int low, int high) {\n\t\tif (low < high) {\n\t\t\tint middle = low + (high - low) / 2;\n\t\t\tmergeSort(low, middle);\n\t\t\tmergeSort(middle + 1, high);\n\t\t\tmergeParts(low, middle, high);\n\t\t}\n\t}", "private PerfectMergeSort() {}", "public String doSort();", "private static void mergeSort(int[] attr, int low, int hight) {\n\t\t\n\t}", "public void mergeSort() throws Exception{\n\t\tif(this.qtd<=1)\n\t\t\tthrow new Exception(\"Nada para ordenar\");\n\t\tthis.sort(0,this.qtd-1);\n\t}", "public void sort() {\n }", "private void merge_sort( ArrayList<Type> array, ArrayList<Type> auxillary, int low, int high ){\n\t\tif((high-low)>switchOff){\n\t\t\tint middle=low+((high-low)/2);\n\t\t\tmerge_sort(array,auxillary,low,middle);\n\t\t\tmerge_sort(array,auxillary,middle+1,high);\n\t\t\tcombine(array,auxillary,low,middle,high);\n\t\t}else{\n\t\t\tSort_Utils.insertion_sort(array, low, high);\n\t\t}\n\t}", "public static void mergeSort(int a[]) {\n\t sort(a, 0, a.length-1); \n\t }", "public void sort(){\r\n\t\t\t// we pass this doubly linked list's head to merge sort it\r\n\t\t\tthis.head = mergeSort(this.head);\r\n\t\t}", "private void merge_sort( ArrayList<Type> array, ArrayList<Type> auxillary, int low, int high )\r\n\t{\r\n\t\t// base case\r\n\t\tif ((high - low) <= switchValue)\r\n\t\t{\r\n\t\t\tSort_Utils.insertion_sort(array, low, high);\r\n\t\t}\r\n\t\t\r\n\t\tif (low < high)\r\n\t\t{\r\n\t\t\tint middle = low + (high - low)/2;\r\n\t\t\t\r\n\t\t\t// recursively sort the two halves of the array\r\n\t\t\tmerge_sort(array, auxillary, low, middle);\r\n\t\t\tmerge_sort(array, auxillary, middle + 1, high);\r\n\t\t\tcombine(array, auxillary, low, middle, high);\r\n\t\t}\r\n}", "private void mergesort(int[] array) {\n\t\t\n\t}", "public static void sortInputExternalMerge() {\r\n\t\tExternalMultiwayMerge merge = new ExternalMultiwayMerge();\r\n\t\tmerge.sort(inputFile, M, d);\r\n\t}", "void sortV();", "public static void mergesort(int[]data){\n if (data.length <= 1)\n return;\n mergesortH(data, 0, data.length - 1);\n \n }", "public static <T extends Comparable<? super T>> void mergeSort(List<T> a){\n // create tmp array \n List<T> tmpArray = new ArrayList<>();\n for(int i = 0; i < a.size(); i++){\n tmpArray.add(null);\n }\n\n // call mergeSort method\n mergeSort(a, tmpArray, 0, a.size()-1);\n }", "static void mergeSort(int array[], int start, int end) {\n if (start < end) {\n // Find the middle point\n int middle = start + (end - start)/2;\n\n // Sort first and second parts\n mergeSort(array, start, middle);\n mergeSort(array, middle + 1, end);\n\n // Merge the sorted parts\n merge(array, start, middle, end);\n\n }\n\n }", "public static void sort(Comparable[] a)\n {\n // Do lg N passes of pairwise merges.\n int N = a.length;\n aux = new Comparable[N];\n for (int sz = 1; sz < N; sz = sz+sz) // sz: subarray size\n for (int lo = 0; lo < N - sz; lo += sz + sz) // lo: subarray index\n merge(a, lo, lo + sz - 1, Math.min(lo + sz + sz - 1, N - 1));\n }", "private void mergeSortHelper(Object arr[], int l, int r) \n\t{ \n\t\tif (l < r) \n\t\t{ \n\t\t\t// Find the middle point \n\t\t\tint m = (l+r)/2; \n\n\t\t\t// Sort first and second halves \n\t\t\tmergeSortHelper(arr, l, m); \n\t\t\tmergeSortHelper(arr , m+1, r); \n\n\t\t\t// Merge the sorted halves \n\t\t\tmerge(arr, l, m, r); \n\t\t} \n\t}", "public void mergeSort(Comparable[] input) {\n\t\t\n\t\t// check if input array is null\n\t\tif (input == null)\n\t\t\tthrow new IllegalArgumentException(\"Input array cannot be null!\");\n\t\t\n\t\t// if input array is empty or contains only 1 element - there's no need to sort\n\t\tif (input.length < 2)\n\t\t\treturn;\n\t\t\n\t\t// set up environment\n\t\tsetUp(input);\n\t\t\n\t\t// variable to store final result list\n\t\tint list;\n\t\twhile (true) {\n\t\t\t\n\t\t\t// poll two lists from queue\n\t\t\tint list1 = poll();\n\t\t\tint list2 = poll();\n\t\t\t\n\t\t\t// merge them and save result into created variable\n\t\t\tlist = merge(list1, list2);\n\t\t\t\n\t\t\t// if queue is empty - there's nothing else to merge - break loop\n\t\t\tif (isEmpty())\n\t\t\t\tbreak;\n\t\t\t\n\t\t\t// if queue is not empty - add merged list to it\n\t\t\tadd(list);\n\t\t}\n\t\t\n\t\t// write result\n\t\twriteBack(input, list);\n\t}", "private void mergeSort(int[] array, int start, int end) {\n\t\tif (start < end) {\n\t\t\tint mid = (start + end) / 2;\n\t\t\tmergeSort(array, start, mid);\n\t\t\tmergeSort(array, mid + 1, end);\n\t\t\tmerge(array, start, mid, end);\n\t\t}\n\t}", "@Override\r\n\tpublic void sort() {\r\n\t\tint minpos;\r\n\t\tfor (int i = 0; i < elements.length-1; i++) {\r\n\t\t\tminpos=AuxMethods.minPos(elements, i);\r\n\t\t\telements=AuxMethods.swapElements(elements, i, minpos);\r\n\t\t\t\r\n\t\t}\r\n\t}", "public static void mergeSort(String[] word,int[] lineNumber, int p, int r){\n int q;\n if(p<r){\n q=(p+r)/2;\n mergeSort(word,lineNumber, p, q);\n mergeSort(word,lineNumber,q+1, r);\n merge(word,lineNumber, p, q, r);\n }\n }", "private void sort(Metric metr, DoubleData dObj, DoubleData[] dObjects, int left, int right)\n {\n int p = left + RANDOM_GENERATOR.nextInt(right-left+1);\n DoubleData tmpObj = dObjects[right];\n dObjects[right] = dObjects[p];\n dObjects[p] = tmpObj;\n int l = left, r = right - 1;\n double dist = metr.dist(dObjects[right], dObj);\n while (l < r)\n if (dist >= metr.dist(dObjects[l], dObj)) l++;\n else if (dist < metr.dist(dObjects[r], dObj)) r--;\n else\n {\n tmpObj = dObjects[l];\n dObjects[l] = dObjects[r];\n dObjects[r] = tmpObj;\n l++;\n if (l < r) r--;\n }\n if (dist < metr.dist(dObjects[l], dObj))\n {\n tmpObj = dObjects[l];\n dObjects[l] = dObjects[right];\n dObjects[right] = tmpObj;\n }\n if (left < l) sort(metr, dObj, dObjects, left, l);\n if (l + 1 < right) sort(metr, dObj, dObjects, l + 1, right);\n }", "private static void mergeSort(int[] data, int left, int right) {\n\n\t\tint mid;\n\n\t\tif (left < right) {\n\n\t\t\tmid = (left + right) / 2;\n\n\t\t\tmergeSort(data, left, mid);\n\t\t\tmergeSort(data, mid + 1, right);\n\t\t\tmerge(data, left, mid, right);\n\t\t}\n\n\t}", "public List<Integer> chunkMergesort(List<Integer> S) {\n\t\tif (S.size() < 2) {\n \t\t\treturn S;\n \t\t}\n \t\tint c = chunks(S);\n \t\tif (c == 1){\n \t\t\treturn S;\n \t\t}\n \t\tChunks p = chunkDivide(S, c);\n \t\tList<Integer> S1 = p.left;\n \t\tList<Integer> S2 = p.right;\n\t\tS1 = chunkMergesort(S1);\n\t\tS2 = chunkMergesort(S2);\n\t\tS = merge(S1, S2);\n\t\treturn S;\n\t}", "public static int[] mergeSortHelper(int num[]) {\n\t\tmergeSort(num, 0, num.length - 1);\n\t\treturn num;\n\t}", "public void sort(int arr[], int l, int m, int r) \n {\n int n1 = m - l + 1; \n int n2 = r - m; \n /* Create temp arrays */\n int L[] = new int [n1]; \n int R[] = new int [n2]; \n /*Copy data to temp arrays*/\n for (int i=0; i<n1; ++i) \n L[i] = arr[l + i]; \n for (int j=0; j<n2; ++j) \n R[j] = arr[m + 1+ j]; \n /* Merge the temp arrays */\n // Initial indexes of first and second subarrays \n int i = 0, j = 0; \n // Initial index of merged subarry array \n int k = l; \n while (i < n1 && j < n2) \n { \n if (L[i] <= R[j]) \n { \n arr[k] = L[i]; \n i++; \n } \n else\n { \n arr[k] = R[j]; \n j++; \n } \n k++; \n } \n /* Copy remaining elements of L[] if any */\n while (i < n1) \n { \n arr[k] = L[i]; \n i++; \n k++; \n } \n /* Copy remaining elements of R[] if any */\n while (j < n2) \n { \n arr[k] = R[j]; \n j++; \n k++; \n } \n }", "public void sort() {\n ListNode start = head;\n ListNode position1;\n ListNode position2;\n\n // Going through each element of the array from the second element to the end\n while (start.next != null) {\n start = start.next;\n position1 = start;\n position2 = position1.previous;\n // Checks if previous is null and keeps swapping elements backwards till there\n // is an element that is bigger than the original element\n while (position2 != null && (position1.data < position2.data)) {\n swap(position1, position2);\n numberComparisons++;\n position1 = position2;\n position2 = position1.previous;\n }\n }\n }", "private void mergesort(ToCompare[] a, int l, int r) throws BrokenBarrierException, InterruptedException {\n if (l >= r) {\r\n return;\r\n }\r\n\r\n //recursion step: a[l..r] is not empty \r\n //divide into sublists and merge \r\n int m = (l + r) / 2;\r\n mergesort(a, l, m);\r\n mergesort(a, m + 1, r);\r\n merge(a, l, m, r);\r\n }", "private void sortEntities(){\n for (int i = 1; i < sorted.size; i++) {\n for(int j = i ; j > 0 ; j--){\n \tEntity e1 = sorted.get(j);\n \tEntity e2 = sorted.get(j-1);\n if(getRL(e1) < getRL(e2)){\n sorted.set(j, e2);\n sorted.set(j-1, e1);\n }\n }\n }\n }", "void mergeSort(int[] arr, int l, int r) {\r\n if (l<r)\r\n {\r\n int m = (l+r)/2;\r\n\r\n mergeSort(arr,l,m);\r\n mergeSort(arr, m+1, r);\r\n merge(arr, l, m, r);\r\n }\r\n }", "public static void Mergesort(int[]data,int[]storageA,int[]storageB){\n int length=data.length;\n while (length>8){\n for(int i=0;i<data.length/2;i++){\n storageA[i]=data[i];\n }\n int index=0;\n for(int i=data.length/2;i<data.length;i++){\n storageB[index]=data[i];\n index++;\n }\n int[]temp1=new int[storageA.length/2];\n int[]temp2=new int[storageA.length-temp1.length];\n int[]temp3=new int[storageB.length/2];\n int[]temp4=new int[storageB.length-temp3.length];\n Mergesort(storageA,temp1,temp2);\n Mergesort(storageB,temp3,temp4);\n\n merge(data,storageA,storageB);\n // System.out.println(Arrays.toString(data));\n length=8;\n }\n insertion(data);\n\n // System.out.println(Arrays.toString(storageA));\n //System.out.println(Arrays.toString(storageB));\n //data=merge(storageA,storageB,0,1);\n }", "public static void merge(int []a , int low,int mid,int high) {\n int [] helper = new int[a.length] ; \n for (int i = low; i<=high; i++) {\n helper[i] = a[i]; \n }\n\n int i = low;\n int j = mid + 1;\n int k = low;\n\n // combine the low part of a and its high part \n while (i<=mid && j<=high) {\n if (helper[i] >= helper[j]){\n a[k] = helper[i];\n i++;\n } else {\n a[k] = helper[j];\n j++;\n }\n k++;\n }\n\n // copy the rest of low part of a if there is any\n while (i<=mid) {\n a[k] = helper[i];\n i++; k++;\n }\n\n\n // copy the rest of the high part of a if there is any\n while (j<=high) {\n a[k] = helper[j];\n j++;k++;\n }\n\n // out put each time we sort and let you watch the change sequence\n for (int Item:a) {\n System.out.print(Item+\" \");\n }\n System.out.println();\n\n }", "static void mergeSort(int[] arr, int l, int r) {\n\t\tif (l<r) {\n\t\t\tint m = (l+r)/2;\n\n\t\t\tmergeSort(arr, l, m);\n\t\t\tmergeSort(arr, m+1, r);\n\t\t\tmerge(arr, l, r, m);\n\t\t}\n\t}", "static void MergeSort(int[] A, int p, int r) {\n\t\tif (p < r) {\n\t\t\tint q = (p + r) / 2;\n\t\t\tMergeSort(A, p, q);\n\t\t\tMergeSort(A, q + 1, r);\n\t\t\tMerge(A, p, q, r);\n\t\t}\n\t}", "public static void mergesort (File A) throws IOException {\r\n\t\tFile copy = File.createTempFile(\"Mergesort\", \".bin\");\r\n\t\tcopyFile (A, copy);\r\n\r\n\t\tRandomAccessFile src = new RandomAccessFile(A, \"rw\");\r\n\t\tRandomAccessFile dest = new RandomAccessFile(copy, \"rw\");\r\n\t\tFileChannel srcC = src.getChannel();\r\n\t\tFileChannel destC = dest.getChannel();\r\n\t\tMappedByteBuffer srcMap = srcC.map (FileChannel.MapMode.READ_WRITE, 0, src.length());\r\n\t\tMappedByteBuffer destMap = destC.map (FileChannel.MapMode.READ_WRITE, 0, dest.length());\r\n\r\n\t\tmergesort (destMap, srcMap, 0, (int) A.length());\r\n\t\t\r\n\t\tsrc.close();\r\n\t\tdest.close();\r\n\t\tcopy.deleteOnExit();\r\n\t}", "public static <T extends Comparable<? super T>> void mergeSort(List<T> list){\n if(list.size() > 1){\n mergeSort(list, 0, (list.size()/2), list.size() - 1, (T[])new Comparable[list.size()]);\n }\n }", "static void mergesort(MappedByteBuffer A, MappedByteBuffer result, \r\n\t\t\tint start, int end) throws IOException {\r\n\r\n\t\tif (end - start < 8) { \r\n\t\t\treturn; \r\n\t\t}\r\n\r\n\t\tif (end - start == 8) {\r\n\t\t\tresult.position(start);\r\n\t\t\tint left = result.getInt();\r\n\t\t\tint right = result.getInt();\r\n\t\t\tif (left > right) {\r\n\t\t\t\tresult.position (start);\r\n\t\t\t\tresult.putInt (right);\r\n\t\t\t\tresult.putInt (left);\r\n\t\t\t}\r\n\t\t\treturn;\r\n\t\t}\r\n\r\n\t\tint mid = (end + start)/8*4;\r\n\t\tmergesort (result, A, start, mid);\r\n\t\tmergesort (result, A, mid, end);\r\n\r\n\t\tresult.position(start);\r\n\t\tfor (int i = start, j = mid, idx=start; idx < end; idx += 4) {\r\n\t\t\tint Ai = A.getInt (i);\r\n\t\t\tint Aj = 0;\r\n\t\t\tif (j < end) { Aj = A.getInt (j); }\r\n\t\t\tif (j >= end || (i < mid && Ai < Aj)) { \r\n\t\t\t\tresult.putInt (Ai);\r\n\t\t\t\ti += 4;\r\n\t\t\t} else {\r\n\t\t\t\tresult.putInt (Aj);\r\n\t\t\t\tj += 4;\r\n\t\t\t}\r\n\t\t}\r\n\t}", "public Node mergeSort(Node head){\r\n\t\t\tif(head == null || head.next == null)\r\n\t\t\t\treturn head;\r\n\t\t\t// divide the list in 2 parts\r\n\t\t\tNode rightLow = split(head);\r\n\t\t\t\r\n\t\t\tNode leftPart = mergeSort(head);\r\n\t\t\tNode rightPart = mergeSort(rightLow);\r\n\r\n\t\t\t// call the merge sorted lists method to merge both the divided parts in sorted way\r\n\t\t\treturn mergeSortedLists(leftPart, rightPart);\r\n\t\t}", "@Test\n public void sortArrayMergeSortTest() {\n int[] array1 = new int[]{5, 2, 3, 1};\n int[] expectedArray1 = new int[]{1, 2, 3, 5};\n int[] actualArray1 = sortArrayMergeSort(array1);\n assertArrayEquals(expectedArray1, actualArray1);\n /**\n * Example 2:\n * Input: nums = [5,1,1,2,0,0]\n * Output: [0,0,1,1,2,5]\n */\n int[] array2 = new int[]{5, 1, 1, 2, 0, 0};\n int[] expectedArray2 = new int[]{0, 0, 1, 1, 2, 5};\n int[] actualArray2 = sortArrayMergeSort(array2);\n assertArrayEquals(expectedArray2, actualArray2);\n }", "private void mergeSortRec(WordList list, Comparator<String> comp, int start, int end)\r\n {\r\n // TODO\r\n\t int middle = start + (end - start)/2; \r\n\t \r\n\t if(start < end) {\r\n\t\t mergeSortRec(list, comp, start, middle);\r\n\t\t mergeSortRec(list, comp, middle+1, end);\r\n\t\t mergeHelp(list, comp, start, middle, end);\r\n\t }\r\n\t \r\n }", "private static int[] mergeSort(int numbers[]) {\n\n\t\tif (numbers.length <= 1) {\n\t\t\treturn numbers;\n\t\t}\n\n\t\tint mid = numbers.length / 2;\n\t\tint subArray1[] = new int[mid];\n\t\tint subArray2[] = new int[numbers.length - mid];\n\n\t\tint count = 0;\n\t\tfor (int i = 0; i < subArray1.length; i++) {\n\t\t\tsubArray1[i] = numbers[count++];\n\t\t}\n\t\tfor (int i = 0; i < subArray2.length; i++) {\n\t\t\tsubArray2[i] = numbers[count++];\n\t\t}\n\n\t\tsubArray1 = mergeSort(subArray1);\n\t\tsubArray2 = mergeSort(subArray2);\n\t\tnumbers = merge(subArray1, subArray2);\n\n\t\treturn numbers;\n\t}", "private void mergesort(ArrayList<Integer> list, int l, int h) {\n\t\tif (l < h) {\n\t\t\tint m = (l + h) / 2;\n\t\t\tmergesort(list, l, m);\n\t\t\tmergesort(list, m + 1, h);\n\t\t\tSystem.out.println(list);\n\t\t\tmerge(list, l, m, h);\n\t\t}\n\t}", "@Override\n\tpublic Object sort(Object o) {\n\t\tSystem.out.println(\"\\nI am Merge Sort!!!\");\n\t\t if (o instanceof MyArray) {\n\t\t \tMyArray new_name = (MyArray) o;\n\t\t \tint[] array = new_name.array;\n\t\t \t\n\t\t \tmergesort(array);\n\t\t \tfor (int i = 0; i < array.length; i++) {\n\t\t \t\tSystem.out.print(array[i] + \" \");\n\t\t \t\t\n\t\t \t}\n\t\t }\n\t\treturn null;\n\t}", "public void mergeSort(ArrayList <Comparable> a, int first, int last){\r\n\t\t\r\n\t\tif (last - first == 0) {\r\n\t\t\tsteps ++;\r\n\t\t}else if (last - first == 1) {\r\n\t\t\tsteps += 4; \r\n\t\t\tif (a.get(first).compareTo(a.get(last)) > 0) {\r\n\t\t\t\tsteps += 5;\r\n\t\t\t\tswap(a, first, last);\r\n\t\t\t\t\r\n\t\t\t}\r\n\t\t}else {\r\n\t\t\tsteps += 3;\r\n\t\t\tint mid = (last + first)/2;\r\n\t\t\tsteps += 4;\r\n\t\t\tmergeSort(a, first, mid);\r\n\t\t\tmergeSort(a, mid + 1, last);\r\n\t\t\tmerge(a, first, mid, last);\r\n\t\t}\r\n\t\tSystem.out.println();\r\n\t\tSystem.out.println(\"Merge Sort\");\r\n\t\tSystem.out.println();\r\n\t}", "public static void mergeSort(int[] elts) {\r\n\t\tint size = elts.length;\r\n\t\tif (size == 2) {\r\n\t\t\tif (elts[0] > elts[1])\r\n\t\t\t\tIntArraySortUtils.swap(elts, 0, 1);\r\n\t\t}\r\n\t\telse if (size > 2) {\r\n\t\t\tPair<int[], int[]> split = splitArray(elts);\r\n\t\t\tint[] left = split.first;\r\n\t\t\tint[] right = split.second;\r\n\t\t\tmergeSort(left);\r\n\t\t\tmergeSort(right);\r\n\t\t\tIntArraySortUtils.merge(elts, left, right);\r\n\t\t}\r\n\r\n\t}", "void mergeSort(int arr[], int l, int r) \n { \n if (l < r) \n { \n // Find the middle point \n int m = (l+r)/2; \n \n // Sort first and second halves \n mergeSort(arr, l, m); \n mergeSort(arr , m+1, r); \n \n // Merge the sorted halves \n sort(arr, l, m, r); \n } \n\t}", "private static <T extends Comparable<T>> void mergeSort(T[] arrayToSort, int startIndex, int endIndex) {\n if(startIndex + 1 < endIndex) {\n int centerIndex = (endIndex + startIndex)/2;\n mergeSort(arrayToSort, startIndex, centerIndex); // sort left half\n mergeSort(arrayToSort, centerIndex, endIndex); // sort right half\n merge(arrayToSort, startIndex, centerIndex, endIndex); // merge two, sorted halves\n }\n }", "private static <T,S>void mergeSort(T[] src,S[] src2,\n\t\t\tT[] dest,\n\t\t\tS[] dest2,\n\t\t\tint low, int high, int off,\n\t\t\tComparator c) {\n\t\tint length = high - low;\n\n\t\t// Insertion sort on smallest arrays\n\t\tif (length < INSERTIONSORT_THRESHOLD) {\n\t\t\tfor (int i=low; i<high; i++)\n\t\t\t\tfor (int j=i; j>low && c.compare(dest[j-1], dest[j])>0; j--) \n\t\t\t\t\tswap(dest,dest2,j, j-1);\n\t\t\treturn;\n\t\t}\n\n\t\t// Recursively sort halves of dest into src\n\t\tint destLow = low;\n\t\tint destHigh = high;\n\t\tlow += off;\n\t\thigh += off;\n\t\tint mid = (low + high) >>> 1;\n\t\t\tmergeSort(dest,dest2, src, src2,low, mid, -off, c);\n\t\t\tmergeSort(dest,dest2, src, src2, mid, high, -off, c);\n\n\t\t\t// If list is already sorted, just copy from src to dest. This is an\n\t\t\t// optimization that results in faster sorts for nearly ordered lists.\n\t\t\tif (c.compare(src[mid-1], src[mid]) <= 0) {\n\t\t\t\tSystem.arraycopy(src, low, dest, destLow, length);\n\t\t\t\tSystem.arraycopy(src2, low, dest2, destLow, length);\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\t// Merge sorted halves (now in src) into dest\n\t\t\tfor(int i = destLow, p = low, q = mid; i < destHigh; i++) {\n\t\t\t\tif (q >= high || p < mid && c.compare(src[p], src[q]) <= 0) {\n\t\t\t\t\tdest2[i] = src2[p];\n\t\t\t\t\tdest[i] = src[p++];\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tdest2[i] = src2[q];\n\t\t\t\t\tdest[i] = src[q++];\n\t\t\t\t}\n\t\t\t}\n\t}", "private void mergeHelp(WordList list, Comparator<String> comp, int start, int mid, int end) {\r\n\t \r\n\t \r\n\t int pos = 0;\r\n\t int a = start;\r\n\t int len = end - start + 1;\r\n\t int b = mid + 1;\r\n\t String[] sorted = new String[len];\r\n\t \r\n\t while(a <= mid && b <= end) {\r\n\t\t if(comp.compare(list.get(a), list.get(b)) == -1) { \r\n\t\t\t sorted[pos] = list.get(b);\r\n\t\t\t b++;\r\n\t\t }\r\n\t\t else {\r\n\t\t\t sorted[pos] = list.get(a);\r\n\t\t\t a++;\r\n\t\t }\r\n\t\t pos++;\r\n\t }\r\n\t \r\n\t while(a <= mid) {\r\n\t\t sorted[pos] = list.get(a);\r\n\t\t a++;\r\n\t\t pos++;\r\n\t }\r\n\t while(b <= end) {\r\n\t\t sorted[pos] = list.get(b);\r\n\t\t b++;\r\n\t\t pos++;\r\n\t }\r\n\t for(int i = 0; i < len; i++) {\r\n\t\t list.set(i + start, sorted[i]);\r\n\t }\r\n }", "public void mergesort_iterative(){\n\t\tint step = 1;\n\t\tint length = arr.length;\n\t\twhile(step < length){\n\t\t\tint i = 0;\n\t\t\twhile(i<length){\n\t\t\t\tmerge_iterative(i, step);\n\t\t\t\ti += step*2;\n\t\t\t}\n\t\t\tstep <<= 1;\n\t\t}\n\t}", "public void sort(){\n ListNode t, x, b = new ListNode(null, null);\n while (firstNode != null){\n t = firstNode; firstNode = firstNode.nextNode;\n for (x = b; x.nextNode != null; x = x.nextNode) //b is the first node of the new sorted list\n if (cmp.compare(x.nextNode.data, t.data) > 0) break;\n t.nextNode = x.nextNode; x.nextNode = t;\n if (t.nextNode==null) lastNode = t;\n }\n firstNode = b.nextNode;\n }", "private static void sort(Comparable[] as, Comparable[] aux, int lo, int hi) {\n if (hi <= lo + CUTOFF - 1) {\n Insertion.sort(as, lo, hi);\n return;\n }\n int mid = lo + (hi - lo) / 2;\n sort (as, aux, lo, mid);\n sort (as, aux, mid + 1, hi);\n // Last element of first array is less than the first of the second --> Stop!\n if (!less(as[mid + 1], as[mid])) return;\n merge (as, aux, lo, mid, hi);\n }", "public static void ordenarMergeSort( Comparable[ ] datos ) {\n\n\t\t// TODO implementar el algoritmo MergeSort\n\t\tlong startTime = System.currentTimeMillis();\n\t\tmergeSort(datos, 0, datos.length-1);\n\t\tlong endTime = System.currentTimeMillis() - startTime;\n\t\tSystem.out.println(endTime+\"\");\n\n\t}", "@Override\n \tpublic void sort() {\n \t\tArrays.sort(data);\n \t}", "public void merge(paintIntegers[] arr, int lidx, int midx, int ridx){\n int leftn = midx - lidx + 1;\n int rightn = ridx - midx;\n\n //instantiating the left and right arrays\n int Left[] = new int [leftn];\n int Right[] = new int [rightn];\n\n //copies the data from original to the left and right\n for (int i=0; i < leftn; ++i) {\n Left[i] = arr[lidx + i].val;\n }\n for (int j=0; j < rightn; ++j) {\n Right[j] = arr[midx + 1 + j].val;\n }\n\n //merges the two arrays and updates the original array\n //initializes leftIndex and rightIndex to iterate over the left and right arrays\n //if it is added to the original array, then where it came from, it would increment\n int leftIndex = 0;\n int rightIndex = 0;\n int k = lidx; //to properly align where the elements to go, left\n //System.out.println(k);\n //while it hasnt gone through all the elements in the left and right array\n //between the two arrays check which one is lowest, and then updates original array\n while (leftIndex < leftn && rightIndex < rightn)\n {\n if (Left[leftIndex] <= Right[rightIndex])\n {\n arr[k].val = Left[leftIndex];\n sorting.add(paintIntegers.deepCopy(arr));//adds current array to list\n leftIndex++;\n }\n else\n {\n arr[k].val = Right[rightIndex];\n sorting.add(paintIntegers.deepCopy(arr));//adds current array to list\n rightIndex++;\n }\n k++;\n }\n //if there are some left on the left array then just adds to original array\n //possible because all the elements in right array have been added\n //all thats left is the sorted elements from the left array\n while (leftIndex < leftn)\n {\n arr[k].val = Left[leftIndex];\n sorting.add(paintIntegers.deepCopy(arr));//adds current array to list\n leftIndex++;\n k++;\n }\n //same explanation as above but with the right array\n while (rightIndex < rightn)\n {\n arr[k].val = Right[rightIndex];\n sorting.add(paintIntegers.deepCopy(arr));//adds current array to list\n rightIndex++;\n k++;\n }\n }", "private static <T extends Comparable<? super T>> void mergeSort(List<T> list, int begin, int mid, int finish, T[] auxiliaryArray){\n if(begin + 1 == finish)\n merge(list, begin, mid, mid + 1, finish, auxiliaryArray);\n else{\n if(begin < finish){\n mergeSort(list, begin, (mid + begin)/2, mid, auxiliaryArray);\n mergeSort(list, mid + 1, (finish + mid)/2, finish, auxiliaryArray);\n merge(list, begin, mid, mid + 1, finish, auxiliaryArray);\n }\n }\n }", "@Override\n public void sort() throws IOException {\n long i = 0;\n // j represents the turn of writing the numbers either to g1 or g2 (or viceversa)\n long j = 0;\n long runSize = (long) Math.pow(2, i);\n long size;\n\n long startTime = System.currentTimeMillis();\n\n System.out.println(\"Strart sorting \"+ this.inputFileName);\n\n while(i <= Math.ceil(Math.log(this.n) / Math.log(2))){\n j = 0;\n do{\n size = merge(runSize, destinationFiles[(int)j % 2]);\n j += 1;\n }while (size/2 == runSize);\n\n System.out.println(\"iteration: \" + i + \", Run Size:\" + runSize + \", Total time elapsed: \" + (System.currentTimeMillis() - startTime));\n i += 1;\n runSize = (long) Math.pow(2, i);\n swipe();\n }\n System.out.println(\"The file has been sorted! Total time elapsed: \"+(System.currentTimeMillis() - startTime));\n\n destinationFiles[0].close();\n destinationFiles[1].close();\n originFiles[0].close();\n originFiles[1].close();\n\n createFile(OUT_PATH +inputFileName);\n copyFile(new File(originFileNames[0]), new File(\"out/TwoWayMergesort/OUT_\"+inputFileName));\n\n }", "public void sort(){\n\t\t\n\t\tif(Q.size() != 1){\n\t\t\tArrayQueue<E> tempQueue1 = Q.dequeue();\n\t\t\tArrayQueue<E> tempQueue2 = Q.dequeue();\n\t\t\tArrayQueue<E> tempQueue3 = merge(tempQueue1, tempQueue2);\n\t\t\tQ.enqueue(tempQueue3);\n\t\t\tsort();\n\t\t}\n\t\t\n\t}", "public MergeSort(){\r\n \r\n }", "private void merge() {\n for (int i = low; i<high; i++){\n temparray[i]=nums[i];\n }\n\n int i = low;\n int j = middle;\n //index of the original array for which we are making compare\n int index = low;\n //copy the smallest from the left and right partition to temp\n while ((i<middle)&&(j<high)){\n if(temparray[i]<=temparray[j]){\n nums[index]=temparray[i];\n i++;\n }\n else {\n nums[index]=temparray[j];\n j++;\n }\n index++;\n }\n // copy the rest of the the left side\n while (i<middle){\n nums[index]= temparray[i];\n i++;\n index++;\n }\n //and the right\n while (j<high){\n nums[index]=temparray[j];\n j++;\n index++;\n }\n\n }", "public static void mergesort(ArrayList<Score> items, int start, int end) {\r\n if (start < end) {\r\n int mid = (start + end) / 2;\r\n mergesort(items, start, mid);\r\n mergesort(items, mid + 1, end);\r\n merge(items, start, mid, end);\r\n }\r\n }", "public T[] mergeSort(T[] array) {\n if (array.length == 1) {\n return array;\n }\n if (array.length == 2) {\n Comparable first = (Comparable) array[0];\n if (((Comparable) array[0]).compareTo(array[1]) > 0) {\n array[0] = array[1];\n array[1] = (T) first;\n }\n return array;\n }\n int mid = array.length / 2;\n T[] first = (T[]) new Object[mid];\n T[] second = (T[]) new Object[array.length - mid];\n for (int i = 0; i < mid; i++) {\n first[i] = array[i];\n }\n for (int i = mid; i < array.length; i++) {\n second[i - mid] = array[i];\n }\n first = mergeSort(first);\n second = mergeSort(second);\n int j = 0;\n int k = 0;\n int i = 0;\n while ((first.length != j) && (second.length != k)) {\n if (((Comparable) first[j]).compareTo(second[k]) < 0) {\n array[i] = first[j];\n j++;\n i++;\n } else {\n array[i] = second[k];\n k++;\n i++;\n }\n }\n if (first.length == j) {\n for (; i < array.length; i++) {\n array[i] = second[k];\n k++;\n }\n } else {\n for (; i < array.length; i++) {\n array[i] = first[j];\n j++;\n }\n }\n return array;\n }", "private static <T extends Comparable,S> void mergeSort(T[] src, S[] src2,\n\t\t\tT[] dest,\n\t\t\tS[] dest2,\n\t\t\tint low,\n\t\t\tint high,\n\t\t\tint off) {\n\t\tint length = high - low;\n\n\t\t// Insertion sort on smallest arrays\n\t\tif (length < INSERTIONSORT_THRESHOLD) {\n\t\t\tfor (int i=low; i<high; i++)\n\t\t\t\tfor (int j=i; j>low &&\n\t\t\t\t\t\tdest[j-1].compareTo(dest[j])>0; j--)\n\t\t\t\t\tswap(dest,dest2, j, j-1);\n\t\t\treturn;\n\t\t}\n\n\t\t// Recursively sort halves of dest into src\n\t\tint destLow = low;\n\t\tint destHigh = high;\n\t\tlow += off;\n\t\thigh += off;\n\t\tint mid = (low + high) >>> 1;\n\t\tmergeSort(dest, dest2, src, src2,low, mid, -off);\n\t\tmergeSort(dest, dest2, src, src2, mid, high, -off);\n\n\t\t// If list is already sorted, just copy from src to dest. This is an\n\t\t// optimization that results in faster sorts for nearly ordered lists.\n\t\tif (src[mid-1].compareTo(src[mid]) <= 0) {\n\t\t\tSystem.arraycopy(src, low, dest, destLow, length);\n\t\t\tSystem.arraycopy(src2, low, dest2, destLow, length);\n\t\t\treturn;\n\t\t}\n\n\t\t// Merge sorted halves (now in src) into dest\n\t\tfor(int i = destLow, p = low, q = mid; i < destHigh; i++) {\n\t\t\tif (q >= high || p < mid && src[p].compareTo(src[q])<=0) {\n\t\t\t\tdest2[i] = src2[p];\n\t\t\t\tdest[i] = src[p++];\n\t\t\t}\n\t\t\telse {\n\t\t\t\tdest2[i] = src2[q];\n\t\t\t\tdest[i] = src[q++];\n\t\t\t}\n\t\t}\n\t}", "public void sort() throws IOException {\n for(int i = 0; i < 32; i++)\n {\n if(i%2 == 0){\n filePointer = file;\n onePointer = one;\n }else{\n filePointer = one;\n onePointer = file;\n }\n filePointer.seek(0);\n onePointer.seek(0);\n zero.seek(0);\n zeroCount = oneCount = 0;\n for(int j = 0; j < totalNumbers; j++){\n int n = filePointer.readInt();\n sortN(n,i);\n }\n //Merging\n onePointer.seek(oneCount*4);\n zero.seek(0L);\n for(int j = 0; j < zeroCount; j++){\n int x = zero.readInt();\n onePointer.writeInt(x);\n }\n //One is merged\n }\n }", "public void mergeSort(List<Integer> a, int n) {\n if (n < 2) {\n return;\n }\n int mid = n / 2;\n List<Integer> l = new LinkedList<Integer>();\n List<Integer> r = new LinkedList<Integer>();\n \n for (int i = 0; i < mid; i++) {\n l.add(a.get(i));\n }\n for (int i = mid; i < n; i++) {\n r.add(a.get(i));\n }\n mergeSort(l, mid);\n mergeSort(r, n - mid);\n \n merge(a, l, r, mid, n - mid);\n }", "public void sort() {\n if (sorter != null)\n sort(sorter);\n }", "private void sort(T[] arr, T[] temp, int lo, int hi) {\n if (lo >= hi) return; // we return if the size of the part equals 1\n int mid = lo + (hi - lo) / 2;\n sort(arr, temp, lo, mid); // sorting the left part\n sort(arr, temp, mid + 1, hi); // sorting the right part\n merge(arr, temp, lo, hi, mid); // merging two parts\n }", "private void merge(int[] left, int[] right, int[] a) {\n\t\t// i - left\n\t\t// j - right\n\t\t// k - original\n\t\tint i = 0, j = 0, k = 0;\n\t\tint sL = left.length;\n\t\tint sR = right.length;\n\n\t\twhile (i < sL && j < sR) {\n\t\t\tif (left[i] < right[j]) {\n\t\t\t\ta[k] = left[i];\n\t\t\t\ti++;\n\t\t\t} else {\n\t\t\t\ta[k] = right[j];\n\t\t\t\tj++;\n\t\t\t}\n\t\t\tk++;\n\t\t}\n\n\t\twhile (i < sL) {\n\t\t\ta[k] = left[i];\n\t\t\tk++;\n\t\t\ti++;\n\t\t}\n\t\twhile (j < sR) {\n\t\t\ta[k] = right[j];\n\t\t\tk++;\n\t\t\tj++;\n\t\t}\n\t}", "public static void mergeSort(int start, int end, int[] numbers) {\n int mid = (start + end) / 2;\n\n if (start < end) {\n // sort left half\n mergeSort(start, mid, numbers);\n\n // sort right half\n mergeSort(mid + 1, end, numbers);\n\n // merge\n merge(start, mid, end, numbers);\n }\n }", "public static void sort(Comparable[] a)\n {\n aux= new Comparable[a.length]; //Allocate space just once\n sort(a,0,a.length); //this uses the sort method in the bottom and tells where it should merge sort.\n }", "public void sortCompetitors(){\n\t\t}", "private void mergeSort(ArrayList<File> listToSort, Comparator<File> fileComparator) {\r\n int size = listToSort.size();\r\n if (size < 2) {\r\n return;\r\n }\r\n int half = size / 2;\r\n ArrayList<File> firstList = new ArrayList<File>(listToSort.subList(0, half));\r\n ArrayList<File> secondList = new ArrayList<File>(listToSort.subList(half, size));\r\n\r\n mergeSort(firstList, fileComparator);\r\n mergeSort(secondList, fileComparator);\r\n\r\n merge(firstList, secondList, listToSort, fileComparator);\r\n }", "private static void mergeSorted(int[] a, int alength, int[] b) {\n int ai = alength - 1;\n int bi = b.length - 1;\n int ri = a.length - 1;\n while (ai >= 0 && bi >= 0) {\n if (a[ai] > b[bi]) {\n a[ri--] = a[ai--];\n } else {\n a[ri--] = b[bi--];\n }\n }\n\n while (bi >= 0) a[ri--] = b[bi--];\n //Note that you don't need to copy the contents of A after running out of elements in B. They are already in place.\n// while (ai >= 0) a[ri--] = a[ai--];\n }", "static void MergeSort(int[] arr){\n int[] helper = new int[arr.length];\n MergeSort(arr, helper, 0, arr.length-1);\n }", "private static void sort(Comparable[] a, int[] index, int[] aux, int lo, int hi){\n if(hi<=lo) return;\n int mid=lo+(hi-lo)/2;\n sort(a,index,aux,lo,mid);\n sort(a,index,aux,mid+1,hi);\n merge(a,index,aux,lo,mid,hi);\n }", "@Override\n public <T extends Comparable<? super T>> List<T> sort(List<T> list){\n return pool.invoke(new ForkJoinSorter<T>(list));\n }", "public static void mergesort(int low, int high) {\n\t\tif (low < high) {\n\t\t\t// Get the index of the element which is in the middle\n\t\t\tint middle = low + (high - low) / 2;\n\t\t\t// Sort the left side of the array\n\t\t\tmergesort(low, middle);\n\t\t\t// Sort the right side of the array\n\t\t\tmergesort(middle + 1, high);\n\t\t\t// Combine them both\n\t\t\tmerge(low, middle, high);\n\t\t}\n\t}", "Comparator<T> sortBy();", "public static void sort(String f1, String f2) throws FileNotFoundException, IOException {\n\t\tDataInputStream input = new DataInputStream(new BufferedInputStream(new FileInputStream(new File(f1))));\n\t\tfileSize = (int) input.available()/4;\n\t\tif (fileSize == 0){ input.close(); return;} //file is empty\t\n\t\t\n\t\tRandomAccessFile f1a = new RandomAccessFile(f1,\"rw\");\n\t\tRandomAccessFile f2a = new RandomAccessFile(f2,\"rw\");\n\t\tDataOutputStream f1d = new DataOutputStream(new BufferedOutputStream(new FileOutputStream(f1a.getFD())));\n\t\tDataOutputStream f2d = new DataOutputStream(new BufferedOutputStream(new FileOutputStream(f2a.getFD())));\n\t\t\n\t\t//perform quicksort on partitions of quickSortSize\n\t\tquickSortSize = (int) (Math.min(quickSortSize, fileSize)); \n\t\tint numDivisions = (int) (Math.floor(fileSize/quickSortSize));\n\t\tint excess = (int) (fileSize%(numDivisions*quickSortSize));\n\t\tint[] tmp = new int[quickSortSize];\n\t\tfor (int j = 0; j < numDivisions; j++){\n\t\t\tfor (int i = 0; i< quickSortSize; i++){\n\t\t\t\ttmp[i] = input.readInt();\n\t\t\t}\n\t\t\tquickSort(tmp);\n\t\t\tfor (int i: tmp){\n\t\t\t\tf2d.writeInt(i);\n\t\t\t}\n\t\t}\n\t\ttmp = new int[excess];\n\t\tfor (int i = 0; i< excess; i++){\n\t\t\ttmp[i] = input.readInt();\n\t\t}\n\t\tquickSort(tmp);\n\t\tfor (int i: tmp){\n\t\t\tf2d.writeInt(i);\n\t\t}\n\t\tf2d.flush();\n\t\tinput.close();\n\t\t\n\t\t//Perform Merge sort on the larger partitions\n\t\tint iteration = (int) Math.ceil(Math.log(fileSize/(quickSortSize))/Math.log(2));\n\t\tfor (int i = 0; i < iteration; i++){\n\t\t\tint size = (int) Math.pow(2, i)*quickSortSize;\n\t\t\tif (i%2 == 0){ \n\t\t\t\tf1a.seek(0);\n\t\t\t\tstepSorter(f2, f1d, size);\n\t\t\t} else {\n\t\t\t\tf2a.seek(0);\n\t\t\t\tstepSorter(f1, f2d, size);\n\t\t\t}\n\t\t}\n\n\t\t//Copies f2 to f1 if the iteration ends with f2\n\t\tif (iteration%2==0){\n\t\t\tFileChannel source = null;\n\t\t\tFileChannel destination = null;\n\t\t\ttry {\n\t\t\t\tsource = new FileInputStream(f2).getChannel();\n\t\t\t\tdestination = new FileOutputStream(f1).getChannel();\n\t\t destination.transferFrom(source, 0, source.size());\n\t\t }\n\t\t finally {\n\t\t if(source != null) {\n\t\t source.close();\n\t\t }\n\t\t if(destination != null) {\n\t\t destination.close();\n\t\t }\n\t\t }\n\t\t}\n\t\tf1a.close();\n\t\tf2a.close();\n\t\tf1d.close();\n\t\tf2d.close();\n\t}", "private static void evaluateMergesortVogellaOpenMP() {\n\n // LOGGER.info(\"evaluating parallel mergesort with OpenMP based on the Vogella version\");\n\n // The time before start to sort.\n long startTime;\n\n // The time after sort.\n long endTime;\n\n // generate sorted array\n numbers = generateSortedArray(ARRAY_SIZE);\n\n // get array to evaluate\n generateWorstUnsortArray(numbers);\n\n // get systemtime before sorting\n startTime = System.currentTimeMillis();\n\n // sort @TODO\n //msVogellaOMP.sort(numbers);\n\n // get systemtime after sorting\n endTime = System.currentTimeMillis();\n\n // show the result of the sorting process\n System.out.println(\"\\n- Sortierergebnis: OpenMP (Vogella) -\");\n System.out.println(\"Die sortierte Folge lautet: \" + arrayToString(numbers));\n System.out.printf(\"Für die Sortierung wurden %d ms benötigt\", endTime - startTime);\n System.out.println(\"\\n------------------------------------------------\\n\");\n }", "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 }", "private static int[] mergeSortedArray(int[] a, int[] b){\n int i = a.length -1;\n for(int j = 3, k = 3, x=0; ( (j >= 0) && (k >= 0)) ; x++){\n\n if(a[j] > b[k]){\n a[i] = a[j];\n a[j] = 0;\n --j;\n --i;\n\n } else{\n a[i] = b[k];\n --k;\n --i;\n }\n\n if(j == -1 ) // this condition worked\n j = 0;\n }\n\n return a;\n\n }", "private void sort()\n {\n // This implements Shell sort.\n // Unfortunately we cannot use the sorting functions from the library\n // (e.g. java.util.Arrays.sort), since the ones that work on int\n // arrays do not accept a comparison function, but only allow\n // sorting into natural order.\n int jump = length;\n boolean done;\n \n while( jump>1 ){\n jump /= 2;\n \n do {\n done = true;\n \n for( int j = 0; j<(length-jump); j++ ){\n int i = j + jump;\n \n if( !areCorrectlyOrdered( indices[j], indices[i] ) ){\n // Things are in the wrong order, swap them and step back.\n int tmp = indices[i];\n indices[i] = indices[j];\n indices[j] = tmp;\n done = false;\n }\n }\n } while( !done );\n }\n \n // TODO: integrate this with the stuff above.\n for( int i=1; i<length; i++ ){\n commonality[i] = commonLength( indices[i-1], indices[i] );\n }\n commonality[0] = -1;\n }", "private static void mergeSort(int[] num, int low, int high) {\n\t\tif ((high - low) >= 1) {\n\n\t\t\t// find the middle index\n\t\t\tint middle = (low + high) / 2;\n\n\t\t\t// make recursive calls to the 'left' and 'right' sides of the sublist\n\t\t\tmergeSort(num, low, middle);\n\t\t\tmergeSort(num, middle + 1, high);\n\n\t\t\t// merge the sublists back together\n\t\t\tmerge(num, low, middle, middle + 1, high);\n\n\t\t}\n\t}", "public void sort(int l,int r){\n if(l<r){\n int m = (int)(l+r)/2; // find the middle element\n sort(l,m);\n sort(m+1,r);\n\n merge(l,m,r);\n }\n \n }", "private int[] mergeSort(int[] nums, int start, int end) {\n if (start == end) {\n return new int[]{nums[start]};\n }\n\n // keep dividing the entire array into sub-arrays\n int mid = (end - start) / 2 + start;\n int[] left = mergeSort(nums, start, mid);\n int[] right = mergeSort(nums, mid + 1, end);\n // return merged array\n return mergeTwoSortedArrays(left, right);\n }", "private static ListNode sortList(ListNode head) {\n if (head == null || head.next == null) {\n return head;\n }\n ListNode mid = getMid(head);\n ListNode left = sortList(head);\n ListNode right = sortList(mid);\n return merge(left, right);\n }", "private static void sort(ArrayList<Integer> a, int left, int right) {\r\n\t\tif (left < right) {\r\n\t\t\tint mid = (left+right)/2;\r\n\t\t\t//sort both halves\r\n\t\t\tsort(a, left, mid);\r\n\t\t\tsort(a, mid + 1, right);\r\n\t\t\t//merge back\r\n\t\t\tmerge(a, left, mid, right);\r\n\t\t}\r\n\t}", "public int[] mergeSort(int[] nums) {\n\t\tif(nums.length<=1) return nums;\n\t\t\n\t\tint mid=nums.length/2;\n\t\tint[] numsA=Arrays.copyOfRange(nums,0,mid);\n\t\tint[] numsB=Arrays.copyOfRange(nums,mid,nums.length);\n\t\t\n\t\treturn merge(mergeSort(numsA),mergeSort(numsB));\n\t\t\n\t}", "private static void evaluateMergesortVogellaThreaded() {\n\n // LOGGER.info(\"evaluating parallel mergesort with Java Threads based on the Vogella version\");\n\n // The time before start to sort.\n long startTime;\n\n // The time after sort.\n long endTime;\n\n // generate sorted array\n numbers = generateSortedArray(ARRAY_SIZE);\n\n // get array to evaluate\n generateWorstUnsortArray(numbers);\n\n // get systemtime before sorting\n startTime = System.currentTimeMillis();\n\n // sort\n msVogellaJThreads.sort(numbers);\n\n // get systemtime after sorting\n endTime = System.currentTimeMillis();\n\n // show the result of the sorting process\n System.out.println(\"\\n- Sortierergebnis: Java Threads (Vogella) -\");\n System.out.println(\"Die sortierte Folge lautet: \" + arrayToString(numbers));\n System.out.printf(\"Für die Sortierung wurden %d ms benötigt\", endTime - startTime);\n System.out.println(\"\\n------------------------------------------------\\n\");\n }", "static double[] mergeSortRecursive (double a[]) {\r\n \tif(a==null){\r\n \t\tSystem.out.print(\"Array empty\");\r\n \t\treturn null;\r\n \t}\r\n \tif(a.length>1) {\r\n \t\tint mid=a.length/2;\r\n \t\t//spilt left part\r\n \t\tdouble[] left =new double[mid];\r\n \t\tfor(int i =0 ; i <mid;i++) {\r\n \t\t\tleft[i]=a[i];\r\n \t\t}\r\n \t\t//spilt right part\r\n \t\tdouble[] right =new double[a.length-mid];\r\n \t\tfor(int i=mid; i< a.length;i++) {\r\n \t\t\tright[i-mid]=a[i];\r\n \t\t}\r\n \t\tmergeSortIterative(left);\r\n \t\tmergeSortIterative(right);\r\n \t\tint i=0;\r\n \t\tint j=0;\r\n \t\tint k=0;\r\n \t\t//Merge left and right arrays\r\n \t\twhile(i<left.length && j<right.length) {\r\n \t\t\tif(left[i]<right[j]) {\r\n \t\t\t\ta[k]=left[i];\r\n \t\t\t\ti++;\r\n \t\t\t}else {\r\n \t\t\t\ta[k]=right[j];\r\n \t\t\t\tj++;\r\n \t\t\t}\r\n \t\t\tk++;\r\n \t\t}\r\n \t\t//Collect remaining elements\r\n \t\twhile(i<left.length) {\r\n \t\t\ta[k]=left[i];\r\n \t\t\ti++;\r\n \t\t\tk++;\r\n \t\t}\r\n \t\twhile(j<right.length) {\r\n \t\t\ta[k]=right[j];\r\n \t\t\tj++;\r\n \t\t\tk++;\r\n \t\t}\r\n \t}\r\n\r\n \treturn a;\r\n }" ]
[ "0.7126611", "0.7115414", "0.70251346", "0.69846964", "0.69373083", "0.69331104", "0.69331104", "0.6870737", "0.686465", "0.68597233", "0.67904997", "0.66399527", "0.66357774", "0.6628662", "0.66087556", "0.65830386", "0.6577973", "0.65218085", "0.6521673", "0.6503949", "0.64997613", "0.6458468", "0.64146465", "0.64136785", "0.6402651", "0.63825446", "0.6381043", "0.6370675", "0.6363916", "0.63585424", "0.63534546", "0.6351109", "0.63509727", "0.634607", "0.63376427", "0.63234675", "0.63230664", "0.6321713", "0.6318097", "0.6317949", "0.63141716", "0.6306494", "0.6303886", "0.6295129", "0.629502", "0.6292082", "0.6291715", "0.62798595", "0.6275546", "0.62543684", "0.6248965", "0.62333125", "0.62245405", "0.6224517", "0.62156737", "0.6208115", "0.6203865", "0.619526", "0.61937463", "0.61914706", "0.61891836", "0.6185558", "0.61822116", "0.61749357", "0.6166208", "0.6166193", "0.6162262", "0.61603093", "0.6157046", "0.6146504", "0.6143377", "0.6135301", "0.61271214", "0.6124643", "0.6119795", "0.6110948", "0.60973716", "0.6093478", "0.6092909", "0.60882676", "0.60879415", "0.60878867", "0.60848147", "0.60816586", "0.608056", "0.60742205", "0.60741717", "0.60679626", "0.60611767", "0.6059731", "0.6055324", "0.6050849", "0.60504466", "0.604906", "0.60483295", "0.604024", "0.6037126", "0.6028182", "0.60257524", "0.60226315" ]
0.6025249
99
setter for transaction list
@JsonProperty("transaction") public void setTransaction(Transaction transaction) { this.transactionList.add(transaction); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@JsonProperty(\"transaction\")\n public void setTransaction(List<Transaction> transaction) {\n this.transactionList = transaction;\n }", "@JsonProperty(\"transaction\")\n public List<Transaction> getTransactionList() {\n return this.transactionList;\n }", "public void setPolicyTransactions(entity.AppCritPolicyTransaction[] value);", "private void setTransactions(\n int index, com.google.protobuf.ByteString value) {\n java.lang.Class<?> valueClass = value.getClass();\n ensureTransactionsIsMutable();\n transactions_.set(index, value);\n }", "public ArrayList<Purchase> getTransactionList()\r\n\t{\r\n\t\t\r\n\t\treturn transactionList;\r\n\t\t\r\n\t}", "public void setTransaction(com.cybersource.stub.PaypalTransaction[] transaction) {\r\n this.transaction = transaction;\r\n }", "public void setListProperty(List<Integer> t) {\n\n\t\t}", "@java.lang.Override\n public java.util.List<com.google.protobuf.ByteString>\n getTransactionsList() {\n return java.util.Collections.unmodifiableList(\n instance.getTransactionsList());\n }", "@java.lang.Override\n public java.util.List<com.google.protobuf.ByteString>\n getTransactionsList() {\n return transactions_;\n }", "public abstract void setList(List<T> items);", "public List<List<Integer>> getTransactions() {\n return transactions;\n }", "public void setTrades(List<Trade> trades);", "List<TransactionVO> addPendingTransactions(List<SignedTransaction> transactions);", "public void setTokenTransactionArray(java.util.List<com.networknt.taiji.token.TokenTransaction> value) {\n this.TokenTransactionArray = value;\n }", "@Override\r\n\tpublic List<Transaction> getTransactions() {\n\t\treturn null;\r\n\t}", "public void setTranlist(java.lang.String param) {\r\n localTranlistTracker = param != null;\r\n\r\n this.localTranlist = param;\r\n }", "@Override\n\tpublic List<Transaction> getTransactions() {\n\t\treturn null;\n\t}", "public void UpdateTransaction() {\n\t\tgetUsername();\n\t\tcol_transactionID.setCellValueFactory(new PropertyValueFactory<Account, Integer>(\"transactionID\"));\n\t\tcol_date.setCellValueFactory(new PropertyValueFactory<Account, Date>(\"date\"));\n\t\tcol_description.setCellValueFactory(new PropertyValueFactory<Account, String>(\"description\"));\n\t\tcol_category.setCellValueFactory(new PropertyValueFactory<Account, String>(\"category\"));\n\t\tcol_amount.setCellValueFactory(new PropertyValueFactory<Account, Double>(\"amount\"));\n\t\tmySqlCon.setUsername(username);\n\t\tlists = mySqlCon.getAccountData();\n\t\ttableTransactions.setItems(lists);\n\t}", "public com.networknt.taiji.token.TokenTransactions.Builder setTokenTransactionArray(java.util.List<com.networknt.taiji.token.TokenTransaction> value) {\n validate(fields()[0], value);\n this.TokenTransactionArray = value;\n fieldSetFlags()[0] = true;\n return this;\n }", "private void transactionList(CallbackContext callbackContext) {\n TransactionDAO transactionDAO = new TransactionDAO(StoneSDK.this.cordova.getActivity());\n\n // cria uma lista com todas as transacoes\n List<TransactionObject> transactionObjects = transactionDAO.getAllTransactionsOrderByIdDesc();\n\n // exibe todas as transacoes (neste caso valor e status) para o usuario\n JSONArray arrayList = new JSONArray();\n\n for (TransactionObject list : transactionObjects) {\n JSONObject obj = new JSONObject();\n\n try{\n obj.put(\"idFromBase\", String.valueOf(list.getIdFromBase()));\n obj.put(\"amount\", list.getAmount());\n obj.put(\"requestId\", String.valueOf(list.getRequestId()));\n obj.put(\"emailSent\", String.valueOf(list.getEmailSent()));\n obj.put(\"timeToPassTransaction\", String.valueOf(list.getTimeToPassTransaction()));\n obj.put(\"initiatorTransactionKey\", String.valueOf(list.getInitiatorTransactionKey()));\n obj.put(\"recipientTransactionIdentification\", String.valueOf(list.getRecipientTransactionIdentification()));\n obj.put(\"cardHolderNumber\", String.valueOf(list.getCardHolderNumber()));\n obj.put(\"cardHolderName\", String.valueOf(list.getCardHolderName()).trim());\n obj.put(\"date\", String.valueOf(list.getDate()));\n obj.put(\"time\", String.valueOf(list.getTime()));\n obj.put(\"aid\", String.valueOf(list.getAid()));\n obj.put(\"arcq\", String.valueOf(list.getArcq()));\n obj.put(\"authorizationCode\", String.valueOf(list.getAuthorizationCode()));\n obj.put(\"iccRelatedData\", String.valueOf(list.getIccRelatedData()));\n obj.put(\"transactionReference\", String.valueOf(list.getTransactionReference()));\n obj.put(\"actionCode\", String.valueOf(list.getActionCode()));\n obj.put(\"commandActionCode\", String.valueOf(list.getCommandActionCode()));\n obj.put(\"pinpadUsed\", String.valueOf(list.getPinpadUsed()));\n obj.put(\"cne\", String.valueOf(list.getCne()));\n obj.put(\"cvm\", String.valueOf(list.getCvm()));\n obj.put(\"serviceCode\", String.valueOf(list.getServiceCode()));\n obj.put(\"entryMode\", String.valueOf(list.getEntryMode()));\n obj.put(\"cardBrand\", String.valueOf(list.getCardBrand()));\n obj.put(\"instalmentTransaction\", String.valueOf(list.getInstalmentTransaction()));\n obj.put(\"transactionStatus\", String.valueOf(list.getTransactionStatus()));\n obj.put(\"instalmentType\", String.valueOf(list.getInstalmentType()));\n obj.put(\"typeOfTransactionEnum\", String.valueOf(list.getTypeOfTransactionEnum()));\n obj.put(\"cancellationDate\", String.valueOf(list.getCancellationDate()));\n\n arrayList.put(obj);\n\n }catch (JSONException e){\n e.printStackTrace();\n }\n }\n callbackContext.success(arrayList);\n }", "public static void setList(CustomerList list){\n\t\tUserInterface.list = list;\n\t}", "public void setSettlement(Settlement set);", "public void setList(List<Integer> list) {\n this.list = list;\n }", "public void setParcelBuyList(ParcelBuyList parcelBuyList) {\r\n/* 417 */ this._parcelBuyList = parcelBuyList;\r\n/* */ }", "void setTransactionId( long txId )\n {\n this.transactionId = txId;\n }", "void setListProperty(Object name, List<Object> list) throws JMSException;", "public RecyclerTransactionAdaptor(List<Transaction> myDataset) {\n mDataset = myDataset;\n }", "public Transaction[] getTransactionsList() throws Exception;", "String transactionChangeString() {\n return transaction_mod_list.toString();\n }", "@Override\n public List<Transaction> getTxListFromCache() {\n return null;\n }", "public void setList(List<ListItem> list) {\n this.items = list;\n\n Log.d(\"ITEMs\",items+\"\");\n }", "public void setData(List<Business> list) {\n }", "@Override\n\tpublic void setTaxList(List<Tax> data) {\n\t\t\n\t}", "public Map<LocalDate, Transactions> getTransactionsList(){\n return listOfTransactions;\n }", "public ArrayList<Double> getTransactions() {\n return transactions;\r\n }", "public void setTransactionManager(TransactionManager tm)\n {\n _tm = tm;\n }", "public void setBalance(T balance) {\n transactions = new ArrayList<Transaction>();\n\t\ttransactions.add(new Transaction<T>('+', balance));\n }", "public void setAccountList(List<Account> accountList) {\r\n this.accountList = accountList;\r\n }", "public void addTransaction(Transactions t){\n listOfTransactions.put(LocalDate.now(), t);\n }", "public TradeList() {\n this.trades = new ArrayList<>();\n }", "public void setTransferSerials(java.util.List<TransferSerial> value) {\n this.TransferSerials = value;\n }", "java.util.List<com.google.protobuf.ByteString> getTransactionsList();", "public void setListaCreditoTributarioSRI(List<CreditoTributarioSRI> listaCreditoTributarioSRI)\r\n/* 136: */ {\r\n/* 137:149 */ this.listaCreditoTributarioSRI = listaCreditoTributarioSRI;\r\n/* 138: */ }", "public void setListOfStock( List<StockEntity> listOfStock ) {\n this.listOfStock = listOfStock;\n }", "void setList(ArrayList<UserContactInfo> contactDeatailsList);", "public TransactionResp transaction_list() throws Exception {\n String s = main(\"transaction_list\",\"[]\");\n return JsonHelper.jsonStr2Obj(s, TransactionResp.class);\n }", "public void setTransactionID(int tid) {\n m_TransactionID = tid;\n // setChanged(true);\n }", "public TransactionSystem(List<Transaction> transactionList)\n\t{\n\t\ttransactionQueue = new LinkedList<Transaction>();\n\t\tfor(Transaction transaction: transactionList)\n\t\t\ttransactionQueue.add(transaction);\n\t\tSystem.out.println(\"Transaction system created!\");\n\t}", "public void setList_Base (String List_Base);", "public void setTransaction(Double transaction) {\r\n this.transaction = transaction;\r\n }", "public abstract java.util.Vector setDB2ListItems();", "public void setList(java.util.List newAktList) {\n\t\tlist = newAktList;\n\t}", "public void setCurrentListToBeDoneList();", "public Transaction(){\n\t\t\n\t\ttransactions = new HashMap<String, ArrayList<Products>>();\n\t}", "public void setCurrentListToBeUndoneList();", "public OrderTransactionManagedBean() \n {\n orders = new ArrayList<>();\n lineItems = new ArrayList<>();\n }", "public void setItems(List<T> value) {\n getElement().setItems(SerDes.mirror(value).cast());\n }", "@JsonSetter(\"purchase_history\")\n public void setPurchaseHistory (List<PurchaseInfo> value) { \n this.purchaseHistory = value;\n }", "public void setUsers(List<User> users)\r\n/* */ {\r\n/* 221 */ this.users = users;\r\n/* */ }", "private void getTransactionListRequest() {\r\n\t\tBasicXmlDocument document = new BasicXmlDocument();\r\n\t\tdocument.parseString(\"<\" + TransactionType.GET_TRANSACTION_LIST.getValue()\r\n\t\t\t\t+ \" xmlns = \\\"\" + XML_NAMESPACE + \"\\\" />\");\r\n\r\n\t\taddAuthentication(document);\r\n\t\taddReportingBatchId(document);\r\n\r\n\t\tcurrentRequest = document;\r\n\t}", "void processTransaction(String[] transaction) {\n\t\titemsetSets.get(itemsetSets.size() - 1).processTransaction(transaction);\n\t}", "@java.lang.Override\n public java.util.List<java.lang.Integer>\n getTransactionStateValueList() {\n return transactionState_;\n }", "public void setSalesLog(List<Sale> salesLogToSet) {\n salesLog = salesLogToSet;\n }", "public static Transactions getTransactions() {\n return Transactions;\n }", "public void setListActividad(List<Pair> listActividad) {\n this.listActividad = listActividad;\n }", "@Override\n\tpublic final void setListUsers(final IntListUsers list) {\n\t\tthis.listUsers = list;\n\t}", "void storeBusinessTransactions(String tenantId, List<BusinessTransaction> businessTransactions) throws Exception;", "public void setT(List<String> e);", "public void setContratos(List<ContratoDTO> contratos) {\r\n this.contratos = contratos;\r\n }", "public void saveTransactions(List<Transaction> transactions) {\r\n Session session = HibernateUtil.getSessionFactory().getCurrentSession();\r\n try {\r\n org.hibernate.Transaction hbtransaction = session.beginTransaction();\r\n for(Transaction trans : transactions) {\r\n // don't save \"duplicate\" transactions\r\n Query q = session.createQuery (\"from finance.entity.Transaction trans WHERE trans.transdate = :transdate AND trans.amount = :amount AND trans.vendor = :vendor AND trans.account.uid = :accountuid\");\r\n q.setParameter(\"transdate\", trans.getTransdate());\r\n q.setParameter(\"amount\", trans.getAmount());\r\n q.setParameter(\"vendor\", trans.getVendor());\r\n Account acct = trans.getAccount();\r\n q.setParameter(\"accountuid\", acct.getUid());\r\n List<Transaction> transactionList = (List<Transaction>) q.list();\r\n if (transactionList.isEmpty()) {\r\n session.save(trans);\r\n }\r\n }\r\n hbtransaction.commit();\r\n } catch (Exception e) {\r\n throw e;\r\n }\r\n }", "public void updateList(List<DiscountDTO> list) {\n\t\tthis.discountRegister = list;\n\t}", "public void setTaxAmtPriceList (BigDecimal TaxAmtPriceList);", "public void setTransactionId(int value) {\n this.transactionId = value;\n }", "public void setAddresses(final List<Address> value)\n\t{\n\t\tsetAddresses( getSession().getSessionContext(), value );\n\t}", "public void setSemUnits(ArrayList value);", "public void setTaskList(List<WTask> list)\n\t{\n\t\tthis.taskList = list;\n\t}", "public Gel_BioInf_Models.VirtualPanel.Builder setTranscripts(java.util.List<java.lang.String> value) {\n validate(fields()[5], value);\n this.Transcripts = value;\n fieldSetFlags()[5] = true;\n return this; \n }", "public void setComUnits(ArrayList value);", "@Override\n protected void set(java.util.Collection<org.tair.db.locusdetail.ILocusDetail> list) {\n loci = list;\n // Add the primary keys to the serialized key list if there are any.\n if (loci != null) {\n for (com.poesys.db.dto.IDbDto object : loci) {\n lociKeys.add(object.getPrimaryKey());\n }\n }\n }", "private void clearTransactions() {\n transactions_ = emptyProtobufList();\n }", "private void getUnsettledTransactionListRequest() {\r\n\t\tBasicXmlDocument document = new BasicXmlDocument();\r\n\t\tdocument.parseString(\"<\" + TransactionType.GET_UNSETTLED_TRANSACTION_LIST.getValue()\r\n\t\t\t\t+ \" xmlns = \\\"\" + XML_NAMESPACE + \"\\\" />\");\r\n\r\n\t\taddAuthentication(document);\r\n\r\n\t\tcurrentRequest = document;\r\n\t}", "public void setList(List<Product> list) {\n\t\tcellTable.setList(list);\n\t}", "public void setTempbats(List<Tempbat> getlist) {\n\t\t\n\t}", "@Test\n public void testSetUsersList() {\n System.out.println(\"setUsersList\");\n Set<User> usersList = new HashSet<>();\n usersList.add(new User(\"test1\", \"[email protected]\"));\n sn10.setUsersList(usersList);\n assertEquals(usersList, sn10.getUsersList());\n }", "public void setTxRangeList(cwterm.service.rigctl.xsd.FreqRange[] param) {\n validateTxRangeList(param);\n if (param != null) {\n localTxRangeListTracker = true;\n } else {\n localTxRangeListTracker = true;\n }\n this.localTxRangeList = param;\n }", "public void setList(DOCKSList param) {\r\n localListTracker = param != null;\r\n\r\n this.localList = param;\r\n }", "public ArrayList<Integer> getAllTransactionsID(){\n return allTransactionsID;\n }", "void setTransaction(final INodeReadTrx pRtx);", "public Builder setTransferSerials(java.util.List<TransferSerial> value) {\n validate(fields()[3], value);\n this.TransferSerials = value;\n fieldSetFlags()[3] = true;\n return this; \n }", "public void setOrderList() {\n\n\t\tint index = 0;\n\t\tlistModel.clear();\n\t\tfor (Order order : driver.getOrderDB().getCustomerOrderList()) {\n\t\t\tlistModel\n\t\t\t\t\t.addElement(textAlignment(\" \" + order.getId(), \"\" + order.getDate(), \"\"\n\t\t\t\t\t\t\t+ order.getPerson().getId(), \"\"\n\t\t\t\t\t\t\t+ order.getCurrentlyLoggedInStaff().getId()));\n\t\t\t// stockList.setSelectedIndex(orderListIndex);\n\t\t\tindex++;\n\t\t}\n\t}", "private void addTransactions(com.google.protobuf.ByteString value) {\n java.lang.Class<?> valueClass = value.getClass();\n ensureTransactionsIsMutable();\n transactions_.add(value);\n }", "private void setValuse(int index) {\n\t\t\t\tuser = searchedUserList.get(index);\n\t\t\t\tgetOldBillDetails(user.getUid()); \n\t\t\t\tBills.removeAllElements();\n\t\t\t\tfor (OldBillModel b : billList) {\n\t\t\t\t\tBills.addElement(b);\n\t\t\t\t\tSystem.out.println(b.getBid());\n\t\t\t\t}\n\t\t\t\tBillList.setCellRenderer(new OldBillRender(billList));\n\t\t\t}", "@Override\r\n public void setTxnDao(TxnDAO txnDao) {\n }", "public void setCommittee(List<Professor> list) {\r\n committee = list;\r\n }", "public XmlSerializableTaskList() {\n task = new ArrayList<>();\n tags = new ArrayList<>();\n }", "public java.util.List<java.lang.Integer>\n getTransactionStateValueList() {\n return java.util.Collections.unmodifiableList(transactionState_);\n }", "public void setRoomList (ArrayList<ItcRoom> roomList)\r\n\t {\r\n\t //this.roomList = roomList;\r\n\t }", "public void setWorkContractItems(){\r\n\t\tComboItem[] comboItems;\r\n\t\t//array list is used as interim solution due to the fact that regular arrays size is immutable\r\n\t\tArrayList<ComboItem> itemList = new ArrayList<ComboItem>();\r\n\t\t\r\n\t\ttry {\r\n\t\t\t//Query database and populate array list with values. \r\n\t\t\tResultSet result = WORK_CONTRACT_OPTIONS.executeQuery();\r\n\t\t\twhile(result.next()){\r\n\t\t\t\titemList.add(new ComboItem(result.getInt(1), result.getString(2)));\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t//Initialise new array with needed size\r\n\t\t\tcomboItems = new ComboItem[itemList.size()];\r\n\t\t\t//convert arraylist object into array\r\n\t\t\tcomboItems = itemList.toArray(comboItems);\r\n\t\t} catch (SQLException e) {\r\n\t\t\t//initialise empty array to be returned\r\n\t\t\tcomboItems = new ComboItem[0];\r\n\t\t\tlogger.log(Level.SEVERE, e.getMessage());\r\n\t\t} \r\n\t\t\r\n\t\tthis.work_contracts = comboItems;\r\n\t}", "public static Transaction[] transactionList(){\n int countFullPosition = 0;\n for (Transaction tr:transactions) {\n if(tr != null){\n countFullPosition++;\n }\n }\n if(countFullPosition == 0)\n return new Transaction[] {};\n // throw new InternalServerException(\"TransactionList is empty\");\n Transaction[] trList = new Transaction[countFullPosition];\n int index = 0;\n for (Transaction tr:transactions) {\n if(tr != null){\n trList[index] = tr;\n index++;\n }\n }\n return trList;\n }", "public ArrayList<VenTransactionFee> persistVenTransactionFeeList(\n\t\t\tList<VenTransactionFee> venTransactionFeeList);" ]
[ "0.7725893", "0.68608433", "0.63739413", "0.632694", "0.63258624", "0.6231915", "0.6215434", "0.6152053", "0.6132816", "0.6118594", "0.6094639", "0.6060565", "0.6014153", "0.59842026", "0.59627444", "0.59527206", "0.5941265", "0.5849152", "0.583697", "0.5815889", "0.5804256", "0.5782994", "0.57374513", "0.5731788", "0.5725024", "0.5702057", "0.5696428", "0.56711704", "0.5667643", "0.5665425", "0.56592226", "0.5638724", "0.5633077", "0.56302476", "0.5615512", "0.56118894", "0.56073457", "0.5596872", "0.5583034", "0.55731845", "0.5557182", "0.555135", "0.5539979", "0.5533447", "0.5530195", "0.5526689", "0.5515668", "0.54987484", "0.5495856", "0.54913884", "0.5487489", "0.5474472", "0.5473566", "0.54725957", "0.54641587", "0.54603666", "0.54531264", "0.54497904", "0.5448632", "0.543894", "0.5412254", "0.54041594", "0.5387621", "0.5383303", "0.5379496", "0.5377258", "0.5375823", "0.53625506", "0.53480786", "0.5344691", "0.53398895", "0.5337678", "0.53263605", "0.53164995", "0.5305808", "0.5304881", "0.53017455", "0.5297367", "0.5293147", "0.5275304", "0.52713996", "0.52650833", "0.52649325", "0.5253064", "0.52520406", "0.5249533", "0.5243811", "0.5243353", "0.52431333", "0.52423066", "0.5241562", "0.5238711", "0.5231235", "0.5225765", "0.5222643", "0.5221509", "0.5216576", "0.52152467", "0.5210246", "0.520865" ]
0.6715674
2
setter for transaction list
@JsonProperty("transaction") public void setTransaction(List<Transaction> transaction) { this.transactionList = transaction; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@JsonProperty(\"transaction\")\n public List<Transaction> getTransactionList() {\n return this.transactionList;\n }", "@JsonProperty(\"transaction\")\n public void setTransaction(Transaction transaction) {\n this.transactionList.add(transaction);\n }", "public void setPolicyTransactions(entity.AppCritPolicyTransaction[] value);", "private void setTransactions(\n int index, com.google.protobuf.ByteString value) {\n java.lang.Class<?> valueClass = value.getClass();\n ensureTransactionsIsMutable();\n transactions_.set(index, value);\n }", "public ArrayList<Purchase> getTransactionList()\r\n\t{\r\n\t\t\r\n\t\treturn transactionList;\r\n\t\t\r\n\t}", "public void setTransaction(com.cybersource.stub.PaypalTransaction[] transaction) {\r\n this.transaction = transaction;\r\n }", "public void setListProperty(List<Integer> t) {\n\n\t\t}", "@java.lang.Override\n public java.util.List<com.google.protobuf.ByteString>\n getTransactionsList() {\n return java.util.Collections.unmodifiableList(\n instance.getTransactionsList());\n }", "@java.lang.Override\n public java.util.List<com.google.protobuf.ByteString>\n getTransactionsList() {\n return transactions_;\n }", "public abstract void setList(List<T> items);", "public List<List<Integer>> getTransactions() {\n return transactions;\n }", "public void setTrades(List<Trade> trades);", "List<TransactionVO> addPendingTransactions(List<SignedTransaction> transactions);", "public void setTokenTransactionArray(java.util.List<com.networknt.taiji.token.TokenTransaction> value) {\n this.TokenTransactionArray = value;\n }", "@Override\r\n\tpublic List<Transaction> getTransactions() {\n\t\treturn null;\r\n\t}", "public void setTranlist(java.lang.String param) {\r\n localTranlistTracker = param != null;\r\n\r\n this.localTranlist = param;\r\n }", "@Override\n\tpublic List<Transaction> getTransactions() {\n\t\treturn null;\n\t}", "public void UpdateTransaction() {\n\t\tgetUsername();\n\t\tcol_transactionID.setCellValueFactory(new PropertyValueFactory<Account, Integer>(\"transactionID\"));\n\t\tcol_date.setCellValueFactory(new PropertyValueFactory<Account, Date>(\"date\"));\n\t\tcol_description.setCellValueFactory(new PropertyValueFactory<Account, String>(\"description\"));\n\t\tcol_category.setCellValueFactory(new PropertyValueFactory<Account, String>(\"category\"));\n\t\tcol_amount.setCellValueFactory(new PropertyValueFactory<Account, Double>(\"amount\"));\n\t\tmySqlCon.setUsername(username);\n\t\tlists = mySqlCon.getAccountData();\n\t\ttableTransactions.setItems(lists);\n\t}", "public com.networknt.taiji.token.TokenTransactions.Builder setTokenTransactionArray(java.util.List<com.networknt.taiji.token.TokenTransaction> value) {\n validate(fields()[0], value);\n this.TokenTransactionArray = value;\n fieldSetFlags()[0] = true;\n return this;\n }", "private void transactionList(CallbackContext callbackContext) {\n TransactionDAO transactionDAO = new TransactionDAO(StoneSDK.this.cordova.getActivity());\n\n // cria uma lista com todas as transacoes\n List<TransactionObject> transactionObjects = transactionDAO.getAllTransactionsOrderByIdDesc();\n\n // exibe todas as transacoes (neste caso valor e status) para o usuario\n JSONArray arrayList = new JSONArray();\n\n for (TransactionObject list : transactionObjects) {\n JSONObject obj = new JSONObject();\n\n try{\n obj.put(\"idFromBase\", String.valueOf(list.getIdFromBase()));\n obj.put(\"amount\", list.getAmount());\n obj.put(\"requestId\", String.valueOf(list.getRequestId()));\n obj.put(\"emailSent\", String.valueOf(list.getEmailSent()));\n obj.put(\"timeToPassTransaction\", String.valueOf(list.getTimeToPassTransaction()));\n obj.put(\"initiatorTransactionKey\", String.valueOf(list.getInitiatorTransactionKey()));\n obj.put(\"recipientTransactionIdentification\", String.valueOf(list.getRecipientTransactionIdentification()));\n obj.put(\"cardHolderNumber\", String.valueOf(list.getCardHolderNumber()));\n obj.put(\"cardHolderName\", String.valueOf(list.getCardHolderName()).trim());\n obj.put(\"date\", String.valueOf(list.getDate()));\n obj.put(\"time\", String.valueOf(list.getTime()));\n obj.put(\"aid\", String.valueOf(list.getAid()));\n obj.put(\"arcq\", String.valueOf(list.getArcq()));\n obj.put(\"authorizationCode\", String.valueOf(list.getAuthorizationCode()));\n obj.put(\"iccRelatedData\", String.valueOf(list.getIccRelatedData()));\n obj.put(\"transactionReference\", String.valueOf(list.getTransactionReference()));\n obj.put(\"actionCode\", String.valueOf(list.getActionCode()));\n obj.put(\"commandActionCode\", String.valueOf(list.getCommandActionCode()));\n obj.put(\"pinpadUsed\", String.valueOf(list.getPinpadUsed()));\n obj.put(\"cne\", String.valueOf(list.getCne()));\n obj.put(\"cvm\", String.valueOf(list.getCvm()));\n obj.put(\"serviceCode\", String.valueOf(list.getServiceCode()));\n obj.put(\"entryMode\", String.valueOf(list.getEntryMode()));\n obj.put(\"cardBrand\", String.valueOf(list.getCardBrand()));\n obj.put(\"instalmentTransaction\", String.valueOf(list.getInstalmentTransaction()));\n obj.put(\"transactionStatus\", String.valueOf(list.getTransactionStatus()));\n obj.put(\"instalmentType\", String.valueOf(list.getInstalmentType()));\n obj.put(\"typeOfTransactionEnum\", String.valueOf(list.getTypeOfTransactionEnum()));\n obj.put(\"cancellationDate\", String.valueOf(list.getCancellationDate()));\n\n arrayList.put(obj);\n\n }catch (JSONException e){\n e.printStackTrace();\n }\n }\n callbackContext.success(arrayList);\n }", "public static void setList(CustomerList list){\n\t\tUserInterface.list = list;\n\t}", "public void setSettlement(Settlement set);", "public void setList(List<Integer> list) {\n this.list = list;\n }", "public void setParcelBuyList(ParcelBuyList parcelBuyList) {\r\n/* 417 */ this._parcelBuyList = parcelBuyList;\r\n/* */ }", "void setTransactionId( long txId )\n {\n this.transactionId = txId;\n }", "void setListProperty(Object name, List<Object> list) throws JMSException;", "public RecyclerTransactionAdaptor(List<Transaction> myDataset) {\n mDataset = myDataset;\n }", "public Transaction[] getTransactionsList() throws Exception;", "String transactionChangeString() {\n return transaction_mod_list.toString();\n }", "@Override\n public List<Transaction> getTxListFromCache() {\n return null;\n }", "public void setList(List<ListItem> list) {\n this.items = list;\n\n Log.d(\"ITEMs\",items+\"\");\n }", "public void setData(List<Business> list) {\n }", "@Override\n\tpublic void setTaxList(List<Tax> data) {\n\t\t\n\t}", "public Map<LocalDate, Transactions> getTransactionsList(){\n return listOfTransactions;\n }", "public ArrayList<Double> getTransactions() {\n return transactions;\r\n }", "public void setTransactionManager(TransactionManager tm)\n {\n _tm = tm;\n }", "public void setBalance(T balance) {\n transactions = new ArrayList<Transaction>();\n\t\ttransactions.add(new Transaction<T>('+', balance));\n }", "public void setAccountList(List<Account> accountList) {\r\n this.accountList = accountList;\r\n }", "public void addTransaction(Transactions t){\n listOfTransactions.put(LocalDate.now(), t);\n }", "public TradeList() {\n this.trades = new ArrayList<>();\n }", "public void setTransferSerials(java.util.List<TransferSerial> value) {\n this.TransferSerials = value;\n }", "java.util.List<com.google.protobuf.ByteString> getTransactionsList();", "public void setListaCreditoTributarioSRI(List<CreditoTributarioSRI> listaCreditoTributarioSRI)\r\n/* 136: */ {\r\n/* 137:149 */ this.listaCreditoTributarioSRI = listaCreditoTributarioSRI;\r\n/* 138: */ }", "public void setListOfStock( List<StockEntity> listOfStock ) {\n this.listOfStock = listOfStock;\n }", "void setList(ArrayList<UserContactInfo> contactDeatailsList);", "public TransactionResp transaction_list() throws Exception {\n String s = main(\"transaction_list\",\"[]\");\n return JsonHelper.jsonStr2Obj(s, TransactionResp.class);\n }", "public void setTransactionID(int tid) {\n m_TransactionID = tid;\n // setChanged(true);\n }", "public TransactionSystem(List<Transaction> transactionList)\n\t{\n\t\ttransactionQueue = new LinkedList<Transaction>();\n\t\tfor(Transaction transaction: transactionList)\n\t\t\ttransactionQueue.add(transaction);\n\t\tSystem.out.println(\"Transaction system created!\");\n\t}", "public void setList_Base (String List_Base);", "public void setTransaction(Double transaction) {\r\n this.transaction = transaction;\r\n }", "public abstract java.util.Vector setDB2ListItems();", "public void setList(java.util.List newAktList) {\n\t\tlist = newAktList;\n\t}", "public void setCurrentListToBeDoneList();", "public Transaction(){\n\t\t\n\t\ttransactions = new HashMap<String, ArrayList<Products>>();\n\t}", "public void setCurrentListToBeUndoneList();", "public OrderTransactionManagedBean() \n {\n orders = new ArrayList<>();\n lineItems = new ArrayList<>();\n }", "public void setItems(List<T> value) {\n getElement().setItems(SerDes.mirror(value).cast());\n }", "@JsonSetter(\"purchase_history\")\n public void setPurchaseHistory (List<PurchaseInfo> value) { \n this.purchaseHistory = value;\n }", "public void setUsers(List<User> users)\r\n/* */ {\r\n/* 221 */ this.users = users;\r\n/* */ }", "private void getTransactionListRequest() {\r\n\t\tBasicXmlDocument document = new BasicXmlDocument();\r\n\t\tdocument.parseString(\"<\" + TransactionType.GET_TRANSACTION_LIST.getValue()\r\n\t\t\t\t+ \" xmlns = \\\"\" + XML_NAMESPACE + \"\\\" />\");\r\n\r\n\t\taddAuthentication(document);\r\n\t\taddReportingBatchId(document);\r\n\r\n\t\tcurrentRequest = document;\r\n\t}", "void processTransaction(String[] transaction) {\n\t\titemsetSets.get(itemsetSets.size() - 1).processTransaction(transaction);\n\t}", "@java.lang.Override\n public java.util.List<java.lang.Integer>\n getTransactionStateValueList() {\n return transactionState_;\n }", "public void setSalesLog(List<Sale> salesLogToSet) {\n salesLog = salesLogToSet;\n }", "public static Transactions getTransactions() {\n return Transactions;\n }", "public void setListActividad(List<Pair> listActividad) {\n this.listActividad = listActividad;\n }", "@Override\n\tpublic final void setListUsers(final IntListUsers list) {\n\t\tthis.listUsers = list;\n\t}", "void storeBusinessTransactions(String tenantId, List<BusinessTransaction> businessTransactions) throws Exception;", "public void setT(List<String> e);", "public void setContratos(List<ContratoDTO> contratos) {\r\n this.contratos = contratos;\r\n }", "public void saveTransactions(List<Transaction> transactions) {\r\n Session session = HibernateUtil.getSessionFactory().getCurrentSession();\r\n try {\r\n org.hibernate.Transaction hbtransaction = session.beginTransaction();\r\n for(Transaction trans : transactions) {\r\n // don't save \"duplicate\" transactions\r\n Query q = session.createQuery (\"from finance.entity.Transaction trans WHERE trans.transdate = :transdate AND trans.amount = :amount AND trans.vendor = :vendor AND trans.account.uid = :accountuid\");\r\n q.setParameter(\"transdate\", trans.getTransdate());\r\n q.setParameter(\"amount\", trans.getAmount());\r\n q.setParameter(\"vendor\", trans.getVendor());\r\n Account acct = trans.getAccount();\r\n q.setParameter(\"accountuid\", acct.getUid());\r\n List<Transaction> transactionList = (List<Transaction>) q.list();\r\n if (transactionList.isEmpty()) {\r\n session.save(trans);\r\n }\r\n }\r\n hbtransaction.commit();\r\n } catch (Exception e) {\r\n throw e;\r\n }\r\n }", "public void updateList(List<DiscountDTO> list) {\n\t\tthis.discountRegister = list;\n\t}", "public void setTaxAmtPriceList (BigDecimal TaxAmtPriceList);", "public void setTransactionId(int value) {\n this.transactionId = value;\n }", "public void setAddresses(final List<Address> value)\n\t{\n\t\tsetAddresses( getSession().getSessionContext(), value );\n\t}", "public void setSemUnits(ArrayList value);", "public void setTaskList(List<WTask> list)\n\t{\n\t\tthis.taskList = list;\n\t}", "public Gel_BioInf_Models.VirtualPanel.Builder setTranscripts(java.util.List<java.lang.String> value) {\n validate(fields()[5], value);\n this.Transcripts = value;\n fieldSetFlags()[5] = true;\n return this; \n }", "public void setComUnits(ArrayList value);", "@Override\n protected void set(java.util.Collection<org.tair.db.locusdetail.ILocusDetail> list) {\n loci = list;\n // Add the primary keys to the serialized key list if there are any.\n if (loci != null) {\n for (com.poesys.db.dto.IDbDto object : loci) {\n lociKeys.add(object.getPrimaryKey());\n }\n }\n }", "private void clearTransactions() {\n transactions_ = emptyProtobufList();\n }", "private void getUnsettledTransactionListRequest() {\r\n\t\tBasicXmlDocument document = new BasicXmlDocument();\r\n\t\tdocument.parseString(\"<\" + TransactionType.GET_UNSETTLED_TRANSACTION_LIST.getValue()\r\n\t\t\t\t+ \" xmlns = \\\"\" + XML_NAMESPACE + \"\\\" />\");\r\n\r\n\t\taddAuthentication(document);\r\n\r\n\t\tcurrentRequest = document;\r\n\t}", "public void setList(List<Product> list) {\n\t\tcellTable.setList(list);\n\t}", "public void setTempbats(List<Tempbat> getlist) {\n\t\t\n\t}", "@Test\n public void testSetUsersList() {\n System.out.println(\"setUsersList\");\n Set<User> usersList = new HashSet<>();\n usersList.add(new User(\"test1\", \"[email protected]\"));\n sn10.setUsersList(usersList);\n assertEquals(usersList, sn10.getUsersList());\n }", "public void setTxRangeList(cwterm.service.rigctl.xsd.FreqRange[] param) {\n validateTxRangeList(param);\n if (param != null) {\n localTxRangeListTracker = true;\n } else {\n localTxRangeListTracker = true;\n }\n this.localTxRangeList = param;\n }", "public void setList(DOCKSList param) {\r\n localListTracker = param != null;\r\n\r\n this.localList = param;\r\n }", "public ArrayList<Integer> getAllTransactionsID(){\n return allTransactionsID;\n }", "void setTransaction(final INodeReadTrx pRtx);", "public Builder setTransferSerials(java.util.List<TransferSerial> value) {\n validate(fields()[3], value);\n this.TransferSerials = value;\n fieldSetFlags()[3] = true;\n return this; \n }", "public void setOrderList() {\n\n\t\tint index = 0;\n\t\tlistModel.clear();\n\t\tfor (Order order : driver.getOrderDB().getCustomerOrderList()) {\n\t\t\tlistModel\n\t\t\t\t\t.addElement(textAlignment(\" \" + order.getId(), \"\" + order.getDate(), \"\"\n\t\t\t\t\t\t\t+ order.getPerson().getId(), \"\"\n\t\t\t\t\t\t\t+ order.getCurrentlyLoggedInStaff().getId()));\n\t\t\t// stockList.setSelectedIndex(orderListIndex);\n\t\t\tindex++;\n\t\t}\n\t}", "private void addTransactions(com.google.protobuf.ByteString value) {\n java.lang.Class<?> valueClass = value.getClass();\n ensureTransactionsIsMutable();\n transactions_.add(value);\n }", "private void setValuse(int index) {\n\t\t\t\tuser = searchedUserList.get(index);\n\t\t\t\tgetOldBillDetails(user.getUid()); \n\t\t\t\tBills.removeAllElements();\n\t\t\t\tfor (OldBillModel b : billList) {\n\t\t\t\t\tBills.addElement(b);\n\t\t\t\t\tSystem.out.println(b.getBid());\n\t\t\t\t}\n\t\t\t\tBillList.setCellRenderer(new OldBillRender(billList));\n\t\t\t}", "@Override\r\n public void setTxnDao(TxnDAO txnDao) {\n }", "public void setCommittee(List<Professor> list) {\r\n committee = list;\r\n }", "public XmlSerializableTaskList() {\n task = new ArrayList<>();\n tags = new ArrayList<>();\n }", "public java.util.List<java.lang.Integer>\n getTransactionStateValueList() {\n return java.util.Collections.unmodifiableList(transactionState_);\n }", "public void setRoomList (ArrayList<ItcRoom> roomList)\r\n\t {\r\n\t //this.roomList = roomList;\r\n\t }", "public void setWorkContractItems(){\r\n\t\tComboItem[] comboItems;\r\n\t\t//array list is used as interim solution due to the fact that regular arrays size is immutable\r\n\t\tArrayList<ComboItem> itemList = new ArrayList<ComboItem>();\r\n\t\t\r\n\t\ttry {\r\n\t\t\t//Query database and populate array list with values. \r\n\t\t\tResultSet result = WORK_CONTRACT_OPTIONS.executeQuery();\r\n\t\t\twhile(result.next()){\r\n\t\t\t\titemList.add(new ComboItem(result.getInt(1), result.getString(2)));\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t//Initialise new array with needed size\r\n\t\t\tcomboItems = new ComboItem[itemList.size()];\r\n\t\t\t//convert arraylist object into array\r\n\t\t\tcomboItems = itemList.toArray(comboItems);\r\n\t\t} catch (SQLException e) {\r\n\t\t\t//initialise empty array to be returned\r\n\t\t\tcomboItems = new ComboItem[0];\r\n\t\t\tlogger.log(Level.SEVERE, e.getMessage());\r\n\t\t} \r\n\t\t\r\n\t\tthis.work_contracts = comboItems;\r\n\t}", "public static Transaction[] transactionList(){\n int countFullPosition = 0;\n for (Transaction tr:transactions) {\n if(tr != null){\n countFullPosition++;\n }\n }\n if(countFullPosition == 0)\n return new Transaction[] {};\n // throw new InternalServerException(\"TransactionList is empty\");\n Transaction[] trList = new Transaction[countFullPosition];\n int index = 0;\n for (Transaction tr:transactions) {\n if(tr != null){\n trList[index] = tr;\n index++;\n }\n }\n return trList;\n }", "public ArrayList<VenTransactionFee> persistVenTransactionFeeList(\n\t\t\tList<VenTransactionFee> venTransactionFeeList);" ]
[ "0.68608433", "0.6715674", "0.63739413", "0.632694", "0.63258624", "0.6231915", "0.6215434", "0.6152053", "0.6132816", "0.6118594", "0.6094639", "0.6060565", "0.6014153", "0.59842026", "0.59627444", "0.59527206", "0.5941265", "0.5849152", "0.583697", "0.5815889", "0.5804256", "0.5782994", "0.57374513", "0.5731788", "0.5725024", "0.5702057", "0.5696428", "0.56711704", "0.5667643", "0.5665425", "0.56592226", "0.5638724", "0.5633077", "0.56302476", "0.5615512", "0.56118894", "0.56073457", "0.5596872", "0.5583034", "0.55731845", "0.5557182", "0.555135", "0.5539979", "0.5533447", "0.5530195", "0.5526689", "0.5515668", "0.54987484", "0.5495856", "0.54913884", "0.5487489", "0.5474472", "0.5473566", "0.54725957", "0.54641587", "0.54603666", "0.54531264", "0.54497904", "0.5448632", "0.543894", "0.5412254", "0.54041594", "0.5387621", "0.5383303", "0.5379496", "0.5377258", "0.5375823", "0.53625506", "0.53480786", "0.5344691", "0.53398895", "0.5337678", "0.53263605", "0.53164995", "0.5305808", "0.5304881", "0.53017455", "0.5297367", "0.5293147", "0.5275304", "0.52713996", "0.52650833", "0.52649325", "0.5253064", "0.52520406", "0.5249533", "0.5243811", "0.5243353", "0.52431333", "0.52423066", "0.5241562", "0.5238711", "0.5231235", "0.5225765", "0.5222643", "0.5221509", "0.5216576", "0.52152467", "0.5210246", "0.520865" ]
0.7725893
0
getter for transaction list
@JsonProperty("transaction") public List<Transaction> getTransactionList() { return this.transactionList; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public Transaction[] getTransactionsList() throws Exception;", "public ArrayList<Purchase> getTransactionList()\r\n\t{\r\n\t\t\r\n\t\treturn transactionList;\r\n\t\t\r\n\t}", "java.util.List<com.google.protobuf.ByteString> getTransactionsList();", "@java.lang.Override\n public java.util.List<com.google.protobuf.ByteString>\n getTransactionsList() {\n return java.util.Collections.unmodifiableList(\n instance.getTransactionsList());\n }", "public List<List<Integer>> getTransactions() {\n return transactions;\n }", "@java.lang.Override\n public java.util.List<com.google.protobuf.ByteString>\n getTransactionsList() {\n return transactions_;\n }", "@Override\r\n\tpublic List<Transaction> getTransactions() {\n\t\treturn null;\r\n\t}", "public static Transactions getTransactions() {\n return Transactions;\n }", "@Override\n public List<Transaction> getTxListFromCache() {\n return null;\n }", "@Override\n\tpublic List<Transaction> getTransactions() {\n\t\treturn null;\n\t}", "public Iterator getTransactions() {\n return (transactions.listIterator());\n }", "public TransactionResp transaction_list() throws Exception {\n String s = main(\"transaction_list\",\"[]\");\n return JsonHelper.jsonStr2Obj(s, TransactionResp.class);\n }", "public Map<LocalDate, Transactions> getTransactionsList(){\n return listOfTransactions;\n }", "public List<TransactionInfo> getAll() {\n return transactions;\n }", "public ArrayList<Transaction> GetUserTransactions(int UserID);", "List<String> getTransactionInfos() {\n\t\tList<String> result = new ArrayList<String>();\n\t\tfor (Transaction transaction : transactionLog.getTransactions()) {\n\t\t\tresult.add(transaction.toString());\n\t\t}\n\t\treturn result;\n\t}", "public ArrayList<Double> getTransactions() {\n return transactions;\r\n }", "public List<Trade> getTrades();", "public static Transaction[] transactionList(){\n int countFullPosition = 0;\n for (Transaction tr:transactions) {\n if(tr != null){\n countFullPosition++;\n }\n }\n if(countFullPosition == 0)\n return new Transaction[] {};\n // throw new InternalServerException(\"TransactionList is empty\");\n Transaction[] trList = new Transaction[countFullPosition];\n int index = 0;\n for (Transaction tr:transactions) {\n if(tr != null){\n trList[index] = tr;\n index++;\n }\n }\n return trList;\n }", "public List<TransactionInfo> list() {\n LOG.debug(\"loading all transaction info\");\n try {\n return getEditor().list();\n } catch (IOException e) {\n throw new CommandExecutionException(\"error occurred while loading transactions\", e);\n }\n }", "@java.lang.Override\n public com.google.protobuf.ByteString getTransactions(int index) {\n return instance.getTransactions(index);\n }", "public Collection<Transaction> getAllTransactions();", "@java.lang.Override\n public com.google.protobuf.ByteString getTransactions(int index) {\n return transactions_.get(index);\n }", "List<TransactionType> listClientTransactionTypes();", "List<transactionsProducts> purchasedProducts();", "public ArrayList<Products> getTransaction(String transID){\n\t\t\n\t\tArrayList<Products> transaction = transactions.get(transID);\n\t\ttransactions.remove(transID); \n\t\treturn transaction;\n\t\t\n\t}", "public HashMap<Integer, ArrayList<PerformanceTransaction>> getTransactions() {\n\t\t//return this.transactions;\n\t\treturn this.transactions;\n\t}", "public ArrayList<Integer> getAllTransactionsID(){\n return allTransactionsID;\n }", "java.util.List<frame.socket.common.proto.Login.ActAmount> \n getActAmountList();", "public com.cybersource.stub.PaypalTransaction[] getTransaction() {\r\n return transaction;\r\n }", "com.google.protobuf.ByteString getTransactions(int index);", "@GetMapping(\"/rest\")\n\t\tpublic @ResponseBody List<Transaction> transactionsListRest() {\n\t\t\tUserDetails user = (UserDetails) SecurityContextHolder.getContext()\n\t\t\t\t\t.getAuthentication().getPrincipal();\n\t\t\tString username = user.getUsername();\n\t\t\tUser currentUser = userRepo.findByUsername(username);\n\t\t\treturn (List<Transaction>) traRepo.findByUser(currentUser);\n\t\t}", "private Collection<StorableTransaction> getTransactionList(Object body) {\r\n Collection<StorableTransaction> txs = new ArrayList<>();\r\n JsonObject data = (JsonObject) body;\r\n data.getJsonArray(ID_COLLECTION).forEach(json -> {\r\n StorableTransaction tx = Serializer.unpack((JsonObject) json, StorableTransaction.class);\r\n tx.setTimestamp(timestampFrom(data.getLong(ID_TIME)));\r\n txs.add(tx);\r\n });\r\n return txs;\r\n }", "public List getTrabajadores();", "public Transaction getTransaction()\n {\n return transaction;\n }", "ListView getManageTransactionListView();", "@Override\n public List list() throws TransactionException {\n return hibernateQuery.list();\n }", "public java.util.List<com.networknt.taiji.token.TokenTransaction> getTokenTransactionArray() {\n return TokenTransactionArray;\n }", "public cto.framework.web.action.plugin.schema.Trans[] getTrans() {\r\n cto.framework.web.action.plugin.schema.Trans[] array = new cto.framework.web.action.plugin.schema.Trans[0];\r\n return this._transList.toArray(array);\r\n }", "Object[] getPendingTransactions(int count);", "Transaction getTransaction() { \r\n return tx;\r\n }", "String transactionChangeString() {\n return transaction_mod_list.toString();\n }", "public ArrayList<GamePurchase> GetTransactionGame(int TransactionID);", "public ArrayList<TradeRequest> getTradeRequests(){return tradeRequests;}", "public List<TransExtAttr> getByTransID(String transid);", "public List<Payer> getPayers() {\n\t\tList<Payer> listPayer = new ArrayList<Payer>();\n\t\tAddTransaction transaction = new AddTransaction();\n\t\tPayer payer1 = new Payer();\n\t\tpayer1.setPayerName(\"DANNON\");\n\t\tlistPayer.add(payer1);\n\t\tPayer payer2 = new Payer();\n\t\tpayer2.setPayerName(\"UNILEVER\");\n\t\tlistPayer.add(payer2);\n\t\tPayer payer3 = new Payer();\n\t\tpayer3.setPayerName(\"MILLER COORS\");\n\t\tlistPayer.add(payer3);\n\t\ttransaction.addTransaction(\"DANNON\", 1000, LocalDateTime.parse(\"2020-11-02T14:00:00\").format(formatter),\n\t\t\t\tlistPayer);\n\t\ttransaction.addTransaction(\"UNILEVER\", 200, LocalDateTime.parse(\"2020-10-31T11:00:00\").format(formatter),\n\t\t\t\tlistPayer);\n\t\ttransaction.addTransaction(\"DANNON\", -200, LocalDateTime.parse(\"2020-10-31T15:00:00\").format(formatter),\n\t\t\t\tlistPayer);\n\t\ttransaction.addTransaction(\"MILLER COORS\", 10000, LocalDateTime.parse(\"2020-11-01T14:00:00\").format(formatter),\n\t\t\t\tlistPayer);\n\t\ttransaction.addTransaction(\"DANNON\", 300, LocalDateTime.parse(\"2020-10-31T10:00:00\").format(formatter),\n\t\t\t\tlistPayer);\n\t\treturn listPayer;\n\t}", "public java.util.List<com.networknt.taiji.token.TokenTransaction> getTokenTransactionArray() {\n return TokenTransactionArray;\n }", "private void transactionList(CallbackContext callbackContext) {\n TransactionDAO transactionDAO = new TransactionDAO(StoneSDK.this.cordova.getActivity());\n\n // cria uma lista com todas as transacoes\n List<TransactionObject> transactionObjects = transactionDAO.getAllTransactionsOrderByIdDesc();\n\n // exibe todas as transacoes (neste caso valor e status) para o usuario\n JSONArray arrayList = new JSONArray();\n\n for (TransactionObject list : transactionObjects) {\n JSONObject obj = new JSONObject();\n\n try{\n obj.put(\"idFromBase\", String.valueOf(list.getIdFromBase()));\n obj.put(\"amount\", list.getAmount());\n obj.put(\"requestId\", String.valueOf(list.getRequestId()));\n obj.put(\"emailSent\", String.valueOf(list.getEmailSent()));\n obj.put(\"timeToPassTransaction\", String.valueOf(list.getTimeToPassTransaction()));\n obj.put(\"initiatorTransactionKey\", String.valueOf(list.getInitiatorTransactionKey()));\n obj.put(\"recipientTransactionIdentification\", String.valueOf(list.getRecipientTransactionIdentification()));\n obj.put(\"cardHolderNumber\", String.valueOf(list.getCardHolderNumber()));\n obj.put(\"cardHolderName\", String.valueOf(list.getCardHolderName()).trim());\n obj.put(\"date\", String.valueOf(list.getDate()));\n obj.put(\"time\", String.valueOf(list.getTime()));\n obj.put(\"aid\", String.valueOf(list.getAid()));\n obj.put(\"arcq\", String.valueOf(list.getArcq()));\n obj.put(\"authorizationCode\", String.valueOf(list.getAuthorizationCode()));\n obj.put(\"iccRelatedData\", String.valueOf(list.getIccRelatedData()));\n obj.put(\"transactionReference\", String.valueOf(list.getTransactionReference()));\n obj.put(\"actionCode\", String.valueOf(list.getActionCode()));\n obj.put(\"commandActionCode\", String.valueOf(list.getCommandActionCode()));\n obj.put(\"pinpadUsed\", String.valueOf(list.getPinpadUsed()));\n obj.put(\"cne\", String.valueOf(list.getCne()));\n obj.put(\"cvm\", String.valueOf(list.getCvm()));\n obj.put(\"serviceCode\", String.valueOf(list.getServiceCode()));\n obj.put(\"entryMode\", String.valueOf(list.getEntryMode()));\n obj.put(\"cardBrand\", String.valueOf(list.getCardBrand()));\n obj.put(\"instalmentTransaction\", String.valueOf(list.getInstalmentTransaction()));\n obj.put(\"transactionStatus\", String.valueOf(list.getTransactionStatus()));\n obj.put(\"instalmentType\", String.valueOf(list.getInstalmentType()));\n obj.put(\"typeOfTransactionEnum\", String.valueOf(list.getTypeOfTransactionEnum()));\n obj.put(\"cancellationDate\", String.valueOf(list.getCancellationDate()));\n\n arrayList.put(obj);\n\n }catch (JSONException e){\n e.printStackTrace();\n }\n }\n callbackContext.success(arrayList);\n }", "java.util.List<io.opencannabis.schema.commerce.OrderItem.Item> \n getItemList();", "@Override\n public List<Transaksi> getAll() {\n List<Transaksi> listTransaksi = new ArrayList<>();\n\n try {\n String query = \"SELECT id, date_format(tgl_transaksi, '%d-%m-%Y') AS tgl_transaksi FROM transaksi\";\n\n PreparedStatement ps = Koneksi().prepareStatement(query);\n ResultSet rs = ps.executeQuery();\n\n while (rs.next()) {\n Transaksi transaksi = new Transaksi();\n\n transaksi.setId(rs.getString(\"id\"));\n transaksi.setTglTransaksi(rs.getString(\"tgl_transaksi\"));\n\n listTransaksi.add(transaksi);\n }\n } catch (SQLException se) {\n se.printStackTrace();\n } catch (Exception e) {\n e.printStackTrace();\n }\n\n return listTransaksi;\n }", "List<TransactionType> listAgentTransactionTypes();", "ArrayList<String> getTransactions(String IBAN, Klant klant) throws SessionExpiredException, IllegalArgumentException, RemoteException;", "public List findAll() {\n return findAll(TransactionItem.class);\n }", "@Override\r\n\tpublic Map<String, Object> getTranList(Search search) throws Exception {\n\t\tList<Transaction> list = tranDao.selectListTran(search); \r\n\t\tint totalCount = tranDao.selectTotalCount(search);\r\n\t\t\r\n\t\tMap<String, Object> map = new HashMap<String, Object>();\r\n\t\tmap.put(\"list\", list);\r\n\t\tmap.put(\"totalCount\", totalCount);\t\t\r\n\t\t\r\n\t\treturn map;\r\n\t}", "protected ArrayList<Transaction> refreshTransactions() {\r\n\t\ttry {\r\n\t\t\tHttpResponse response = serverAccess.getAllTransactionsResponse();\r\n\t\t\tif (response.getStatusLine().getStatusCode() == HttpStatus.SC_OK) {\r\n\t\t\t\tString transactionsJson = EntityUtils.toString(response.getEntity());\r\n\t\t\t\tGson gson = new GsonBuilder().create();\r\n\t\t\t\tTransaction[] transactionArray = gson.fromJson(transactionsJson, Transaction[].class);\r\n\t\t\t\tArrayList<Transaction> transactionList = new ArrayList<Transaction>(Arrays.asList(transactionArray));\r\n\t\t\t\ttxtError.setText(\"\");\r\n\t\t\t\treturn transactionList;\r\n\t\t\t} else {\r\n\t\t\t\ttxtError.setText(EntityUtils.toString(response.getEntity()) + \" (Fehler: \"\r\n\t\t\t\t\t\t+ response.getStatusLine().getStatusCode() + \")\");\r\n\t\t\t}\r\n\t\t} catch (IOException e) {\r\n\t\t\te.printStackTrace();\r\n\t\t\ttxtError.setText(\"Server nicht verfügbar\");\r\n\t\t}\r\n\t\treturn null;\r\n\t}", "public List<Ticket> getTransactionLog() {\r\n\t\treturn tickets;\r\n\t}", "public Transaction getTransaction() {\n return transaction;\n }", "public String getTransaction() {\n return transaction;\n }", "public List<StockItem> getStockList();", "public java.util.List<TransferSerial> getTransferSerials() {\n return TransferSerials;\n }", "public List<TransactionM> getTransactionsInfo(int fId) {\n\t\tList<TransactionM> d= new ArrayList<>();\r\n\t\ttry {\r\n\t\t\t\r\n\t\t\tthis.pst = this.con.prepareStatement(\"select * from transaction where fromaccno=? ORDER BY balance LIMIT 0,5\"); \r\n\t\t\t\r\n\t\t\t\r\n\t\t\tthis.pst.setInt(1,fId);\r\n\t\t\tthis.rs = this.pst.executeQuery();\r\n\t\t\twhile (rs.next()) {\r\n\t\t\t\td.add(new TransactionM(rs.getInt(1),rs.getInt(2),rs.getInt(3),rs.getInt(4))) ;\r\n\t\t\t}\r\n\t\t} \r\n\t\tcatch(Exception e) {\r\n\t\t\t\r\n\t\t\tSystem.out.println(e);\r\n\t\t}\r\n\r\n\t\treturn d;\r\n\t}", "@JsonProperty(\"transaction\")\n public void setTransaction(List<Transaction> transaction) {\n this.transactionList = transaction;\n }", "List<Trade> getAllTrades();", "public List<Transaction> getAllTransaction() throws SQLException {\n String sql = \"SELECT * FROM LabStore.Transaction_Detail\";\n List<Transaction> transactions = new ArrayList<>();\n\n try (Connection conn = database.getConnection();\n PreparedStatement preStmt = conn.prepareStatement(sql)) {\n try (ResultSet rs = preStmt.executeQuery()) {\n while (rs.next()) {\n Transaction transaction = new Transaction();\n transaction.setId(rs.getInt(\"id\"));\n transaction.setUser(userDbManager.getUser(rs.getInt(\"uId\")));\n transaction.setPurchaseDetail(purchaseDetailDbManager\n .getPurchaseDetailById(rs.getInt(\"pdId\")));\n transaction.setCount(rs.getInt(\"count\"));\n transaction.setTime(rs.getTimestamp(\"time\"));\n transactions.add(transaction);\n }\n }\n }\n\n return transactions;\n }", "public List<Integer> getAccessedTransaction() {\n return new ArrayList<Integer>(_accessedTransactions);\n }", "public List<TransactionType> listESETransactionTypes();", "public Transaction getTransaction() {\n return this.transaction;\n }", "public List<TaskItemBean> getItemList(){\n return itemList;\n }", "@Override\n\tpublic List<Transaction> getAllTransactions() { \n\t\t/* begin transaction */ \n\t\tSession session = getCurrentSession(); \n\t\tsession.beginTransaction();\n\n\t\tQuery query = session.createQuery(\"from Transaction\");\n\t\tList<Transaction> expenses = query.list();\n\n\t\t/* commit */ \n\t\tsession.getTransaction().commit();\n\n\t\treturn expenses; \n\t}", "public List<Transaction> readAllTransaction() throws TransactionNotFoundException {\n\t\treturn transactionDAO.listAccountTransactionTable();\n\t}", "public lnrpc.Rpc.TransactionDetails getTransactions(lnrpc.Rpc.GetTransactionsRequest request) {\n return blockingUnaryCall(\n getChannel(), getGetTransactionsMethod(), getCallOptions(), request);\n }", "public List<Transaction> getAllTransactions(){\n Cursor cursor = fetchAllRecords();\n List<Transaction> transactions = new ArrayList<Transaction>();\n if (cursor != null){\n while(cursor.moveToNext()){\n transactions.add(buildTransactionInstance(cursor));\n }\n cursor.close();\n }\n return transactions;\n }", "String getTransactionId();", "String getTransactionId();", "@java.lang.Override\n public java.util.List<adamant.global.v1.Enum.TransactionState> getTransactionStateList() {\n return new com.google.protobuf.Internal.ListAdapter<\n java.lang.Integer, adamant.global.v1.Enum.TransactionState>(transactionState_, transactionState_converter_);\n }", "public Object getTransactionId() throws StandardException;", "public java.lang.String getTranlist() {\r\n return localTranlist;\r\n }", "@Override\r\n\t@Transactional\r\n\tpublic Transactions getTransaction() {\r\n\r\n\t\tArrayList<Transactions> closedTransactions=null;\r\n\t\tif(closedTransactions == null)\r\n\t\t{\r\n\t\tclosedTransactions = new ArrayList<Transactions>();\r\n\t\tclosedTransactions = this.getClosedTransactions();\r\n\t\t}\r\n\r\n\r\n\t\tif (index < closedTransactions.size()) {\r\n\t\t\tTransactions transaction = closedTransactions.get(index++);\r\n\t\t\treturn transaction;\r\n\t\t} else {\r\n\t\t\treturn null;\r\n\t\t}\r\n\t}", "public java.util.List<TransferSerial> getTransferSerials() {\n return TransferSerials;\n }", "List<Customer> getList();", "Collection lookupTransactions(String email);", "public ObjectList getList(){\n return payroll;\n }", "@java.lang.Override\n public java.util.List<java.lang.Integer>\n getTransactionStateValueList() {\n return transactionState_;\n }", "public List<String> getT();", "@Override\n\tpublic List<MarketTransaction> getMarketTransactions() {\n\t\treturn null;\n\t}", "public List<Transaction> getTransactions() throws SQLException {\n\t\tList<Transaction> result = new ArrayList<>();\n\t\tStatement statement = conn.createStatement();\n\t\ttry (ResultSet resultSet = statement.executeQuery(\"select Date, Amount, Category, Type from transaction\")) {\n\t\t\twhile (resultSet.next()) {\n\t\t\t\tresult.add(new Transaction(resultSet.getDate(1), resultSet.getDouble(2), resultSet.getString(3), resultSet.getString(4)));\n\t\t\t}\n\t\t}\n\t\treturn result;\n\t}", "java.util.List<cosmos.base.v1beta1.CoinOuterClass.Coin> \n getFundsList();", "java.util.List<cosmos.base.v1beta1.CoinOuterClass.Coin> \n getFundsList();", "@Override\n\tpublic List<BankTransaction> getAllTransactions() throws BusinessException {\n\t\tBankTransaction bankTransaction = null;\n\t\tList<BankTransaction> bankTransactionList = new ArrayList<>();\n\t\tConnection connection;\n\n\t\ttry {\n\t\t\tconnection = PostgresqlConnection.getConnection();\n\t\t\tString sql = \"select transaction_id, account_id, transaction_type, amount, transaction_date from dutybank.transactionss\";\n\t\t\t\n\t\t\tPreparedStatement preparedStatement = connection.prepareStatement(sql);\n\n\t\t\tResultSet resultSet = preparedStatement.executeQuery();\n\t\t\t\n\t\t\t\n\t\t\twhile (resultSet.next()) {\n\t\t\t\tbankTransaction = new BankTransaction();\n\t\t\t\tbankTransaction.setTransactionid(resultSet.getInt(\"transaction_id\"));\n\t\t\t\tbankTransaction.setAccountid(resultSet.getInt(\"account_id\"));\n\t\t\t\tbankTransaction.setTransactiontype(resultSet.getString(\"transaction_type\"));\n\t\t\t\tbankTransaction.setTransactionamount(resultSet.getDouble(\"amount\"));\n\t\t\t\tbankTransaction.setTransactiondate(resultSet.getDate(\"transaction_date\"));\n\n\t\t\t\tbankTransactionList.add(bankTransaction);\n\t\t\t} \n\t\t\t\n\t\t\tif (bankTransactionList.size() == 0) {\n\t\t\t\tthrow new BusinessException(\"There is not data to retrieve\");\n\t\t\t}\n\t\t\n\t\t} catch (ClassNotFoundException | SQLException e) {\n\t\t\tthrow new BusinessException(\"Some Error ocurred retrieving data for transactions\");\n\t\t}\n\t\t\n\t\treturn bankTransactionList;\n\t}", "public ParcelBuyList getParcelBuyList() {\r\n/* 201 */ return this._parcelBuyList;\r\n/* */ }", "public int getAmount()\n {\n return this.transactionValue;\n }", "public java.util.List<adamant.global.v1.Enum.TransactionState> getTransactionStateList() {\n return new com.google.protobuf.Internal.ListAdapter<\n java.lang.Integer, adamant.global.v1.Enum.TransactionState>(transactionState_, transactionState_converter_);\n }", "List<Customer> getCustomerList();", "@java.lang.Override\n public int getTransactionsCount() {\n return transactions_.size();\n }", "List<TradeItem> getTradesForAccount(long accountId);", "public Double getTransaction() {\r\n return transaction;\r\n }", "public int getTransactionId() {\n return transactionId;\n }", "public List<Order> getOrderHistory();", "List<Debt> split(Transaction transaction);", "@XmlTransient\r\n public List<Account> getAccountList() {\r\n return accountList;\r\n }" ]
[ "0.7617803", "0.75439423", "0.728009", "0.72771657", "0.7183541", "0.70751977", "0.6996001", "0.698039", "0.6928055", "0.6888672", "0.68205523", "0.67944294", "0.6763294", "0.6719483", "0.6706948", "0.66849023", "0.66797245", "0.6677271", "0.6595898", "0.6591482", "0.65639913", "0.65600336", "0.6546943", "0.65295863", "0.65072656", "0.6472247", "0.6431624", "0.64007205", "0.6349605", "0.6343609", "0.6343149", "0.6335915", "0.6329766", "0.6314742", "0.6302016", "0.6293436", "0.62666243", "0.625979", "0.6256149", "0.6249061", "0.6234604", "0.62259614", "0.621703", "0.6176521", "0.6160614", "0.6158515", "0.61530626", "0.6135515", "0.61112183", "0.6110767", "0.6109788", "0.6106683", "0.61000675", "0.6095497", "0.60646284", "0.60540396", "0.6041104", "0.6035021", "0.60343677", "0.6010445", "0.6006546", "0.6001462", "0.6001456", "0.59824294", "0.5980201", "0.59801775", "0.5979985", "0.59795266", "0.5966906", "0.5966875", "0.59582967", "0.5952626", "0.5935288", "0.5935288", "0.5933514", "0.59291595", "0.59244925", "0.5910605", "0.5907553", "0.59052616", "0.5891779", "0.58874494", "0.58732396", "0.5851391", "0.5846463", "0.5843796", "0.5843218", "0.5843218", "0.58378196", "0.58356667", "0.58120424", "0.5809427", "0.5804341", "0.578647", "0.5769159", "0.57586384", "0.5752773", "0.5747989", "0.5740731", "0.57352746" ]
0.7451967
2
Binding is a interface used to represent the runtime properties and methods associated with a variable: specifically, a method to get the value of the variable.
public interface Binding { /** * Get the declared type of the variable * @return the declared type */ public SequenceType getRequiredType(); /** * Evaluate the variable * @param context the XPath dynamic evaluation context * @return the result of evaluating the variable */ public ValueRepresentation evaluateVariable(XPathContext context) throws XPathException; /** * Indicate whether the binding is local or global. A global binding is one that has a fixed * value for the life of a query or transformation; any other binding is local. * @return true if the binding is global */ public boolean isGlobal(); /** * If this is a local variable held on the local stack frame, return the corresponding slot number. * In other cases, return -1. * @return the slot number on the local stack frame */ public int getLocalSlotNumber(); /** * Get the name of the variable * @return the name of the variable, as a structured QName */ public StructuredQName getVariableQName(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public abstract int getBindingVariable();", "Binding getBinding();", "public Binding getBinding() {\n\t\treturn binding;\n\t}", "public Binding getBinding() {\n return binding;\n }", "public interface YCoolBindings {\n /**\n * The porpouse of this method is to store any bind, because depending on\n * the circunstances it can be caught by garbadge collector.\n * @param bind_name Binding name\n * @param bind Bind itself\n */\n public void yAddBind(String bind_name, ObservableValue<? extends Number> bind);\n\n /**\n * @param pivo The porcentage point of the object, for example, 0 is the\n * leftmost point of the object, 0.5 is the middle and 1 is the rightmost\n * point (it is not limited from 0 to 1, you can go further).\n * @return A DoubleBinding that is linked to the X location of the object, in\n * other words, whenever the X location of the object changes, the\n * DoubleBinding will change automaticaly with it. (this bind is linked to\n * the X location but the opposite is not true).\n */\n public DoubleBinding yTranslateXbind(double pivo);\n\n /**\n * @param pivo The porcentage point of the object, for example, 0 is the\n * upper point of the object, 0.5 is the middle and 1 is the bottom point (it\n * is not limited from 0 to 1, you can go further).\n * @return A DoubleBinding that is linked to the Y location of the object, in\n * other words, whenever the Y location of the object changes, the\n * DoubleBinding will change automaticaly with it. (this bind is linked to\n * the Y location but the opposite is not true).\n */\n public DoubleBinding yTranslateYbind(double pivo);\n\n /**\n * Links the X position of the object with an observable value, so whenever\n * it changes, the object's X position will change too.\n *\n * @param bind_name The name for this link.\n * @param X The observable value to link the object's X position.\n * @param pivo The porcentage point of the object, for example, 0 is the\n * leftmost point of the object, 0.5 is the middle and 1 is the rightmost\n * point (it is not limited from 0 to 1, you can go further).\n */\n public void yBindTranslateX(String bind_name, ObservableValue<? extends Number> X, double pivo);\n\n /**\n * Links the Y position of the object with an observable value, so whenever\n * it changes, the object's Y position will change too.\n *\n * @param bind_name The name for this link.\n * @param Y The observable value to link the object's Y position.\n * @param pivo The porcentage point of the object, for example, 0 is the\n * upper point of the object, 0.5 is the middle and 1 is the bottom point (it\n * is not limited from 0 to 1, you can go further).\n */\n public void yBindTranslateY(String bind_name, ObservableValue<? extends Number> Y, double pivo);\n\n /**\n * @param stroke_included If you want the stroke of the object to be part of\n * the new width, mark this as true.\n * @return A DoubleBinding that is linked to the width of the object, in\n * other words, whenever the width of the object changes, the DoubleBinding\n * will change automaticaly with it. (this bind is linked to the width but\n * the opposite is not true).\n */\n public DoubleBinding yWidthBind(boolean stroke_included);\n\n /**\n * @param stroke_included If you want the stroke of the object to be part of\n * the new height, mark this as true.\n * @return A DoubleBinding that is linked to the height of the object, in\n * other words, whenever the height of the object changes, the DoubleBinding\n * will change automaticaly with it. (this bind is linked to the height but\n * the opposite is not true).\n */\n public DoubleBinding yHeightBind(boolean stroke_included);\n\n /**\n * Links the width of the object with an observable value, so whenever it\n * changes, the object's width will change too.\n *\n * @param bind_name The name for this link.\n * @param width The observable value to link the object's width.\n * @param stroke_included If you want the stroke of the object to be part of\n * the new width, mark this as true.\n */\n public void yBindWidth(String bind_name, ObservableValue<? extends Number> width, boolean stroke_included);\n\n /**\n * Links the height of the object with an observable value, so whenever it\n * changes, the object's height will change too.\n *\n * @param bind_name The name for this link.\n * @param height The observable value to link the object's height.\n * @param stroke_included If you want the stroke of the object to be part of\n * the new height, mark this as true.\n */\n public void yBindHeight(String bind_name, ObservableValue<? extends Number> height, boolean stroke_included);\n\n /**\n * Breaks any bind created previously based on the name of the bind.\n * @param bind_name Name of the bind to be broken.\n */\n public void yUnbind(String bind_name);\n}", "public interface BindingObject {\n void bindTo(View view, Object object);\n}", "Binding<T> fixed();", "public void setBinding(Binding binding) {\r\n\t \tthis.binding = binding;\r\n\t }", "Expression getBindingExpression();", "public void bind(String var, E value) {\n put(var, value);\n }", "public Binding getBinding() { \n\t\tif (myBinding == null) {\n\t\t\tmyBinding = new Binding();\n\t\t}\n\t\treturn myBinding;\n\t}", "IViewerBinding getBinding();", "public BindingElements getBindingAccess() {\n\t\treturn pBinding;\n\t}", "@Override\n public int getBindingVariable() {\n return BR.data;\n }", "@Override\n public int getBindingVariable() {\n return BR.data;\n }", "public interface BindingStrategy<T> {\n T bind(Method method, Object arg, PreferenceOperation methodPrefAnnotation, Object defVal) throws NoSuchConverterException;\n void setPreferenceHelper(PreferenceHelper preferenceHelper);\n void setPreferenceConverters(Set<newBaseConverter> preferenceConverters);\n PreferenceHelper getPreferenceHelper();\n Set<newBaseConverter> getPreferenceConverters();\n boolean canWorkWith(Class<?> arg);\n}", "public DCPList getBinding() {\n return binding;\n }", "FieldBinding getBinding( Field< ? > field );", "public interface ScriptBinding\n{\n /**\n * Returns the list of variables this ScriptBinding provides, mapped by variable name.\n * @return The list of variables, or null if no variable is provided.\n */\n public Map<String, Object> getVariables();\n \n /**\n * Returns the list of variables descriptions, mapped by variable name.\n * This list does not have to match the getVariables return value, but the description is used to inform the user of the existence and usability of each variable.\n * @return The list of variables descriptions, or null if no description is provided.\n */\n public Map<String, I18nizableText> getVariablesDescriptions();\n\n /**\n * Allows clean up of variables created during the getVariables call.\n * @param variables The map of variables.\n */\n public void cleanVariables(Map<String, Object> variables);\n \n /**\n * Returns the JavaScript functions to inject at the start of the script, in the form of a single String prepended to the script.\n * @return The functions text, or null if no function is provided.\n */\n public String getFunctions();\n \n /**\n * Returns the list of functions descriptions, mapped by function name.\n * This list does not have to match the functions returned by getFunctions, but the description is used to inform the user of the existence and usability of each function.\n * @return The list of functions descriptions, or null if no description is provided.\n */\n public Map<String, I18nizableText> getFunctionsDescriptions();\n \n /**\n * Process the script result if there are any specificities for this console data.\n * @param result The result\n * @return The result processed, or null if this console data does not have any processing to do. \n * @throws ScriptException If a processing error occurs.\n */\n public Object processScriptResult(Object result) throws ScriptException;\n}", "private void changeBinding(InstanceBinding binding) {\r\n\t\t\r\n\t}", "public final void setBinding(@Nullable TBinding binding) {\n // if we already had a binding\n try (AutoRef<TBinding> oldBinding = AutoRef.of(_binding);\n AutoRef<Context> context = AutoRef.of(oldBinding.get().getRoot().getContext())) {\n // notify the derived class that the current binding is being unset\n onBindingUnset(context, oldBinding);\n } catch (ReferenceNullException ignored) { }\n // set the new binding\n _binding = new WeakReference<>(binding);\n // if the new binding is not null\n try (AutoRef<TBinding> newBinding = AutoRef.of(_binding);\n AutoRef<Context> context = AutoRef.of(newBinding.get().getRoot().getContext())) {\n // set the values contained within the value repository\n for (int key : _values.keySet()) {\n newBinding.get().setVariable(key, _values.get(key));\n }\n // notify the derived class of the new binding being set\n onBindingSet(context, newBinding);\n // execute the binding's pending changes\n _binding.get().executePendingBindings();\n } catch (ReferenceNullException ignored) {}\n }", "public interface BindingMapperVarAware<T>\n extends BindingMapper<T>\n{\n Set<Var> getVarsMentioned();\n}", "Binding<T> shared();", "public static MemberMemberBinding memberBind(Member member, Iterable<MemberBinding> bindings) { throw Extensions.todo(); }", "public interface BindingPattern extends IHasPosition {\n\n int getFormalIndex();\n}", "public abstract TypeBindings bindingsForBeanType();", "public interface Binding extends AutoCloseable, Consumer<Bindings> {\n\n\n}", "public Binding(TBTermVar var, ATerm val, boolean isFormal){\n\t\tthis.var = var;\n\t\tthis.val = val;\n\t\tthis.formal = isFormal;\n\t\tname = var.getVarName();\n\t}", "public void add(Binding binding) {\n\tif (values == null) values = new LinkedList();\n\tvalues.add(binding);\n }", "protected abstract void bind();", "protected abstract void bind();", "public void yAddBind(String bind_name, ObservableValue<? extends Number> bind);", "public static MemberMemberBinding memberBind(Method method, Iterable<MemberBinding> bindings) { throw Extensions.todo(); }", "protected abstract void bindingView();", "public void addBinding(Binding aBinding)\n{\n removeBinding(aBinding.getPropertyName()); // Remove current binding for property name (if it exists)\n List <Binding> bindings = getBindings(true); // Add binding\n bindings.add(aBinding);\n aBinding.setNode(this); // Set binding width to this shape\n}", "@Override\n protected String getBindingKey() {return _parms.bindingKey;}", "EStructuralFeature getBoundProperty();", "private void registerBindings(){\t\t\n\t}", "private void registerBindings(){\t\t\n\t}", "ParameterBinding createParameterBinding();", "public ElementDefinitionDt setBinding(Binding theValue) {\n\t\tmyBinding = theValue;\n\t\treturn this;\n\t}", "public static void simpleBinding() {\n DoubleProperty d1 = new SimpleDoubleProperty(1);\n DoubleProperty d2 = new SimpleDoubleProperty(2);\n d1.bind(d2); // Bind d1 with d2\n System.out.println(\"d1 is \" + d1.getValue()\n + \" and d2 is \" + d2.getValue());\n d2.setValue(70.2);\n System.out.println(\"d1 is \" + d1.getValue()\n + \" and d2 is \" + d2.getValue());\n }", "@Override\n\tpublic void bind() {\n\t\t\n\t}", "public static void addNameBinding (String name, Object javaObject)\n\t{\n\t\tm_interpreter.set (name, javaObject);\n\t}", "@Override\n\tpublic void put(String name, Scriptable start, Object value) {\n\t\tif(unwrap().appliedBindings.size() > 0) {\n\t\t\tfor(XBLBinding binding : unwrap().appliedBindings) {\n\t\t\t\tXBLProperty prop = binding.getProperty(name);\n\t\t\t\tif(prop != null && prop.getSetter() != null) {\n\t\t\t\t\tFunction setter = asFunction(prop.getSetter());\n\t\t\t\t\tprop.setSetter(setter);\n\t\t\t\t\tsetter.call(Context.getCurrentContext(), getParentScope(), this, new Object[]{value});\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tsuper.put(name, start, value);\n\t}", "public static String bind(String message, Object binding) {\n \t\treturn PlatformMessages.bind(message, new Object[] {binding});\n \t}", "public void bind() {\n }", "T bindTo(Object instance);", "private void updateBinding(){\n\t\tif(propertiesObj == null)\n\t\t\treturn;\n\n\t\tif(txtBinding.getText().trim().length() == 0)\n\t\t\treturn;\n\n\t\tif(propertiesObj instanceof QuestionDef)\n\t\t\t((QuestionDef)propertiesObj).setVariableName(txtBinding.getText());\n\t\telse if(propertiesObj instanceof OptionDef)\n\t\t\t((OptionDef)propertiesObj).setVariableName(txtBinding.getText());\n\t\telse if(propertiesObj instanceof FormDef)\n\t\t\t((FormDef)propertiesObj).setVariableName(txtBinding.getText());\n\t\telse if(propertiesObj instanceof PageDef){\n\t\t\ttry{\n\t\t\t\t((PageDef)propertiesObj).setPageNo(Integer.parseInt(txtBinding.getText()));\n\t\t\t}catch(Exception ex){\n\t\t\t\treturn;\n\t\t\t}\n\t\t}\n\n\t\tformChangeListener.onFormItemChanged(propertiesObj);\n\t}", "public Binding getBinding(int anIndex) { return getBindings(true).get(anIndex); }", "private void bind(final BindToBeanProperty beanBinding, final Field jfxComponentField){\n \t\tfinal Class<? extends StringConverter<?>> converter = beanBinding.converter();\n \t\tfinal boolean dummyConverter = converter.isAssignableFrom(DummyConverter.class);\n \t\tfinal String bindPropertyName = beanBinding.bindPropertyName();\n\t\t\n \t\tfinal Object objectFromField = objectFromField(jfxComponentField, owner);\n \t\tif(objectFromField == null) {\n \t\t\tthrow new RuntimeException(\"property to bind is null, forgot to initiate field \" + jfxComponentField.getName() + \"?\");\n \t\t}\n \t\t\n \t\tif(dummyConverter) {\n \t\t\tfinal Property<Object> jfxComponentProp = jfxProperty(bindPropertyName, objectFromField);\n \t\t\tfinal Property<Object> modelObjectProp = jfxProperty(jfxComponentField.getName(), modelObject);\n \t\t\tbind(jfxComponentProp, modelObjectProp);\n \t\t\tbindedProperties.add(new Pair<Property<?>, Property<?>>(jfxComponentProp, modelObjectProp));\n \t\t} else {\n \t\t\tfinal Property<String> jfxComponentProp = jfxProperty(bindPropertyName, objectFromField);\n \t\t\tfinal Property<Object> modelObjectProp = jfxProperty(jfxComponentField.getName(), modelObject);\n \t\t\tbind(jfxComponentProp, modelObjectProp, converter(beanBinding));\n \t\t\tbindedProperties.add(new Pair<Property<?>, Property<?>>(jfxComponentProp, modelObjectProp));\n \t\t}\n \t}", "@Override\n\tpublic boolean visit(SimpleName node) {\n\t\tIBinding b = node.resolveBinding();\n\t\tif (b != null) {\n\t\t\tif (b instanceof IVariableBinding) {\n\t\t\t\tIVariableBinding vb = (IVariableBinding) b;\n\t\t\t\tITypeBinding tb = vb.getType();\n\t\t\t\tif (tb != null) {\n\t\t\t\t\ttb = tb.getTypeDeclaration();\n\t\t\t\t\tif (tb.isLocal() || tb.getQualifiedName().isEmpty())\n\t\t\t\t\t\treturn false;\n\t\t\t\t\tthis.fullTokens.append(\" \" + getQualifiedName(tb) + \" \");\n\t\t\t\t\tthis.partialTokens.append(\" \" + getName(tb) + \" \");\n\t\t\t\t}\n\t\t\t} else if (b instanceof ITypeBinding) {\n\t\t\t\tITypeBinding tb = (ITypeBinding) b;\n\t\t\t\ttb = tb.getTypeDeclaration();\n\t\t\t\tif (tb.isLocal() || tb.getQualifiedName().isEmpty())\n\t\t\t\t\treturn false;\n\t\t\t\tthis.fullTokens.append(\" \" + getQualifiedName(tb) + \" \");\n\t\t\t\tthis.partialTokens.append(\" \" + getName(tb) + \" \");\n\t\t\t}\n\t\t} else {\n\t\t\tthis.fullTokens.append(\" \" + node.getIdentifier() + \" \");\n\t\t\tthis.partialTokens.append(\" \" + node.getIdentifier() + \" \");\n\t\t}\n\t\treturn false;\n\t}", "public Term bind(Term[] binding)\n {\n return this;\n }", "void addFieldBinding( FieldBinding binding );", "public interface ViewBinder<T> {\n void bind(T target);\n\n void unBind(T target);\n}", "@Override\n\tpublic void setBindingValue(T value, Object target, BindingEvaluationContext context) {\n\n\t}", "@SuppressWarnings(\"unchecked\")\n public <T> Binding<T> getBinding(Key<T> key) {\n return (Binding<T>) bindings.get(key);\n }", "@Nonnull\n SystemScriptBindings getBindings();", "@Override\n\tpublic Object get(String name, Scriptable start) {\n\t\tObject result = super.get(name, start);\n\t\tif(result == NOT_FOUND && unwrap().appliedBindings.size() > 0) {\n\t\t\tfor(XBLBinding binding : unwrap().appliedBindings) {\n\t\t\t\t// Check fields:\n\t\t\t\tXBLField field = binding.getField(name);\n\t\t\t\tif(field != null && field.getInitializer() != null) {\n\t\t\t\t\tFunction init = asFunction(field.getInitializer());\n\t\t\t\t\tfield.setInitializer(init);\n\t\t\t\t\tresult = init.call(Context.getCurrentContext(), getParentScope(), this, new Object[]{});\n\t\t\t\t\tput(name, this, result);\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\n\t\t\t\t// Check property getters:\n\t\t\t\tXBLProperty prop = binding.getProperty(name);\n\t\t\t\tif(prop != null && prop.getGetter() != null) {\n\t\t\t\t\tFunction getter = asFunction(prop.getGetter());\n\t\t\t\t\tprop.setGetter(getter);\n\t\t\t\t\tresult = getter.call(Context.getCurrentContext(), getParentScope(), this, new Object[]{});\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\n\t\t\t\t// Check methods:\n\t\t\t\tXBLMethod method = binding.getMethod(name);\n\t\t\t\tif(method != null && method.getBody() != null) {\n\t\t\t\t\tresult = asFunction(method.getBody());\n\t\t\t\t\tmethod.setBody(result);\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn convertReturnValue(result);\n\t}", "public interface InstanceBindable<T> {\n\n /**\n * Binds this element to the given object, making it implicit in every interaction\n *\n * @param instance The instance to bind\n * @return The bound version of this instance\n */\n T bindTo(Object instance);\n\n}", "void bind(Object element);", "boolean hasIsBinding();", "public interface INameGUIDBinding {\n\t\n /**\n * Gets the name.\n * \n * @return the name\n */\n String getName();\n \n /**\n * Gets the GUID.\n * \n * @return the GUID\n */\n IGUID getGUID();\n}", "private void bindObject() {\n }", "public BindElements getBindAccess() {\n\t\treturn pBind;\n\t}", "public final void mT__69() throws RecognitionException {\n try {\n int _type = T__69;\n int _channel = DEFAULT_TOKEN_CHANNEL;\n // C:\\\\Documents and Settings\\\\D043530\\\\runtime-workspace\\\\com.sap.ap.cts.editor\\\\generated\\\\generated\\\\Binding.g:137:7: ( 'binding' )\n // C:\\\\Documents and Settings\\\\D043530\\\\runtime-workspace\\\\com.sap.ap.cts.editor\\\\generated\\\\generated\\\\Binding.g:137:9: 'binding'\n {\n match(\"binding\"); if (state.failed) return ;\n\n\n }\n\n state.type = _type;\n state.channel = _channel;\n }\n finally {\n }\n }", "public static MemberMemberBinding memberBind(Member member, MemberBinding[] bindings) {\n return memberBind(member, Arrays.asList(bindings));\n }", "@NonNull\n public final AutoRef<TBinding> getBinding() throws ReferenceNullException {\n return AutoRef.of(_binding);\n }", "public interface MovieBinder {\n void bindMovie(Movie movie);\n}", "public ITypeBinding getType() {\n\t\treturn binding;\n\t}", "public VariableBinding formVarbind(MetaData mdata) {\n VariableBinding vbind = null;\n if (mdata.m_oidValue != null) {\n vbind = new VariableBinding(new OID(mdata.m_oid), castOidType(mdata.m_oidType, mdata.m_oidValue));\n }\n return vbind;\n }", "Binding<T> unqualified();", "public BindingOperation getBindingOp() {\n return bindingOp;\n }", "public static Object getBindingObject(String bindingValue) {\r\n\r\n\t\tFacesContext ctx = FacesContext.getCurrentInstance();\r\n\t\tApplication app = ctx.getApplication();\r\n\t\treturn app.createValueBinding(bindingValue).getValue(ctx);\r\n\t}", "public interface TypedComponentAssignment<V> {\n V getAssignedValue ();\n void setAssignedValue (V value);\n}", "@Override\n public Object data_get(String key) {\n return _dataBind.get(key);\n }", "public static List<VariableDeclaration> getBindingManagementVars()\n {\n return FrameworkDefs.bindingManagementVars; \n }", "public void addBinding(WbBinding binding)\n {\n _bindingList.add(binding);\n }", "public void bind(Interface i) {\n\t\t_interface = i;\n\t}", "public void bind(String name, Object obj) {\n\t\tif (log.isInfoEnabled()) {\n\t\t\tlog.info(\"Static JNDI binding: [\" + name + \"] = [\" + obj + \"]\");\n\t\t}\n\t\tthis.boundObjects.put(name, obj);\n\t}", "DataBinding createDataBinding();", "DataBinding createDataBinding();", "public void addBinding(String aPropName, String aKey) { addBinding(new Binding(aPropName, aKey)); }", "public String getBindingClass()\n {\n return bindingClass;\n }", "@Override\r\n\tpublic String getBind_property_ind() {\n\t\treturn super.getBind_property_ind();\r\n\t}", "private boolean bindNewVariable(String name, Obj value) {\n if (name.equals(\"_\")) return true;\n \n // Bind the variable.\n return mScope.define(mIsMutable, name, value);\n }", "Aliasing getVariable();", "EventBinding createEventBinding();", "public interface ViewModelBinder {\n void generateCode(MethodSpec.Builder builder);\n FieldSpec.Builder generateConstantField();\n}", "public int bind(IModel model, Map<String, Object> variableBindings,\n boolean isIterative) throws CannotMatchException;", "public interface Beobachter {\n\n public int getValue();\n}", "public void bind(String name, Object obj)\r\n {\r\n if (logger.isInfoEnabled()) {\r\n logger.info(\"Static JNDI binding: [\" + name + \"] = [\" + jndiObjectToString(obj) + \"]\");\r\n }\r\n this.boundObjects.put(name, obj);\r\n }", "@Override\n\tpublic void setValueExpression(String name, ValueExpression binding) {\n\t\tif (PropertyKeys.var.toString().equals(name)) {\n\t\t\tthrow new IllegalArgumentException(ERROR_EXPRESSION_DISALLOWED);\n\t\t}\n\n\t\tsuper.setValueExpression(name, binding);\n\t}", "Variable(String _var) {\n this._var = _var;\n }", "@Override\n protected DagNode evaluate(DagNode parent, Bindings bindings) {\n // type acts as storage for the status\n DagEdge bound = bindings.getBinding(_varName, getType());\n if (bound == null) {\n if (getType() == Bindings.LOCAL) {\n // first occurence of this var, bind the variable name\n // to the given node. This is on the application side, where new bindings\n // are only relevant in expandVars, which is why the DagEdge is not\n // important, but the node, to establish coreferences.\n bound = new DagEdge((short) -1, parent);\n bindings.bind(_varName, bound, getType());\n } else {\n logger.warn(\"Unknown binding during application of rule: \" + this);\n return parent;\n }\n }\n // Avoid unwanted coreferences for atomic nodes\n if (bound.getValue().newEdgesAreEmpty()) {\n return bound.getValue().cloneFS();\n }\n return bound.getValue();\n }", "public Exp createBind(Expression exp, Variable var){\r\n if (var.getVariableList() != null){\r\n // bind (sql() as ())\r\n return createASTBind(exp, var);\r\n }\r\n else {\r\n return Binding.create(exp, var);\r\n }\r\n }", "public Object bind(LigoObject ligoObject) {\n\t\tif (annotation.mode()!=DEFAULT)\n\t\t\tbinder().setMode(annotation.mode());\n\t\t\n\t\tList<? extends LigoData> data = environment().expressionResolver().resolve(boundName(),ligoObject);\n\t\treturn binder().bind(data);\n\t\n\t}", "public IBinder asBinder() {\n return this;\n }", "public IBinder asBinder() {\n return this;\n }", "default AdvancedWorkdayEndpointBuilder basicPropertyBinding(\n String basicPropertyBinding) {\n doSetProperty(\"basicPropertyBinding\", basicPropertyBinding);\n return this;\n }" ]
[ "0.71681404", "0.7046602", "0.65462315", "0.65252405", "0.64560455", "0.63056654", "0.6282438", "0.6188445", "0.60663", "0.60495096", "0.6015784", "0.60149056", "0.59348255", "0.59270716", "0.59270716", "0.5883893", "0.58628625", "0.58447224", "0.58432436", "0.582718", "0.5792552", "0.5720408", "0.57198", "0.5694868", "0.56605804", "0.56520855", "0.56493866", "0.563874", "0.5625512", "0.56169146", "0.56169146", "0.5610412", "0.5610382", "0.5609073", "0.56072485", "0.5589339", "0.5582378", "0.55451363", "0.55451363", "0.5538726", "0.55179465", "0.55057377", "0.54960585", "0.5491915", "0.5485413", "0.5473521", "0.5466333", "0.54629153", "0.5462476", "0.54589444", "0.5449886", "0.54497945", "0.54427445", "0.5442203", "0.5434939", "0.54232395", "0.5416455", "0.5403037", "0.5392402", "0.53899455", "0.5382497", "0.5368985", "0.53318936", "0.53155553", "0.5293814", "0.52917624", "0.52853024", "0.5276937", "0.5252396", "0.52471894", "0.5241999", "0.52279085", "0.5219219", "0.52181214", "0.5214344", "0.52068543", "0.52064335", "0.5198942", "0.5160288", "0.51374316", "0.51298356", "0.51298356", "0.51249605", "0.5120915", "0.51063156", "0.5103787", "0.5093849", "0.50872546", "0.50850594", "0.5067256", "0.50478655", "0.5047397", "0.50451756", "0.5016112", "0.5014973", "0.5014224", "0.5012347", "0.5006592", "0.5006592", "0.5006047" ]
0.7966216
0
Get the declared type of the variable
public SequenceType getRequiredType();
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public VarTypeNative getFieldVarType();", "TypeRef getType();", "type getType();", "Type getType();", "Type getType();", "Type getType();", "Type getType();", "Type getType();", "Type getType();", "Type getType();", "Type getType();", "Type getType();", "Type getType();", "Type getType();", "public java.lang.Short getVariableType() {\r\n return variableType;\r\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();", "public Type getType();", "private static TypeToken<?> typeVariable() {\n\t\tParameterizedType t = (ParameterizedType)TypeToken.of(Identity.class).getSupertype(StreamElement.class).getType();\n\t\treturn TypeToken.of(t.getActualTypeArguments()[0]);\n\t}", "public abstract jq_Type getDeclaredType();", "Type type();", "Type type();", "public Class getType();", "DType getType();", "public TYPE SemantMe() {\n\t\tSYM_TABLE sym_table = SYM_TABLE.getInstance();\n\t\t\n\t\t// Lookup the name\n\t\tTYPE t = sym_table.find(this.type);\n\t\t// Check it\n\t\tif (t == null || !t.isTypeName())\n\t\t {\n\t\t\t// Code bug -- type given does not exist in table or just is not a name a of a type\n\t\t\treport_error();\n\t\t }\n\t\t\t// Its fine, declare it\n\t\treturn new TYPE_VAR_DEC(t.name,this.name);\n }", "static String varType(Field field)\r\n {\r\n switch(field.type)\r\n {\r\n case Field.BYTE:\r\n return \"BYTE\";\r\n case Field.SHORT:\r\n return \"SHORT\";\r\n case Field.INT:\r\n case Field.SEQUENCE:\r\n case Field.LONG:\r\n return \"LONG\";\r\n case Field.CHAR:\r\n case Field.ANSICHAR:\r\n return \"CHAR(\"+String.valueOf(field.length)+\")\";\r\n case Field.DATE:\r\n case Field.DATETIME:\r\n case Field.TIME:\r\n case Field.TIMESTAMP:\r\n return \"DATETIME\";\r\n case Field.FLOAT:\r\n case Field.DOUBLE:\r\n if (field.scale != 0)\r\n return \"DOUBLE(\"+String.valueOf(field.precision)+\", \"+String.valueOf(field.scale)+\")\";\r\n else if (field.precision != 0)\r\n return \"DOUBLE(\"+String.valueOf(field.precision)+\")\";\r\n return \"DOUBLE\";\r\n case Field.BLOB:\r\n return \"LONGBINARY\";\r\n case Field.TLOB:\r\n return \"LONGTEXT\";\r\n case Field.MONEY:\r\n return \"DOUBLE(15,2)\";\r\n case Field.USERSTAMP:\r\n return \"VARCHAR(16)\";\r\n case Field.IDENTITY:\r\n return \"<not supported>\";\r\n }\r\n return \"unknown\";\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();", "public String getType(JmmNode node) {\n switch (node.getKind()) {\n case \"Add\":\n case \"Sub\":\n case \"Mul\":\n case \"Div\":\n return \"int\";\n\n case \"LessThan\":\n case \"And\":\n case \"Not\":\n return \"boolean\";\n\n case \"Var\":\n return getVariableSymbol(node.get(\"name\")).getType().getName();\n default:\n return null;\n }\n }", "public Class 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();", "String getType();", "int getTypeValue();", "int getTypeValue();", "int getTypeValue();", "int getTypeValue();", "int getTypeValue();", "int getTypeValue();", "int getTypeValue();", "int getTypeValue();", "int getTypeValue();", "int getTypeValue();", "int getTypeValue();", "int getTypeValue();", "int getTypeValue();", "public List<Ref<? extends Type>> typeVariables();", "public Type typeOf(Context ctxt, TypeEnv locals)\n throws Failure {\n TypeEnv te = ctxt.findVar(name, locals);\n loc = te.getLoc();\n return type = te.getType();\n }", "public Class getFieldDeclarerType() {\n String type = getFieldDeclarerName();\n if (type == null)\n return null;\n return Strings.toClass(type, getClassLoader());\n }", "private Type type()\r\n {\r\n Type t = new Type();\r\n\r\n t.ident = nextToken;\r\n t.type = basicType();\r\n if (t.type == Keyword.NONESY)\r\n {\r\n unresolved.add(t.ident.string = qualident());\r\n }\r\n else\r\n t.ident.string = null;\r\n\r\n t.dim = bracketsOpt();\r\n\r\n return t;\r\n }" ]
[ "0.7295713", "0.686877", "0.6832922", "0.6716097", "0.6716097", "0.6716097", "0.6716097", "0.6716097", "0.6716097", "0.6716097", "0.6716097", "0.6716097", "0.6716097", "0.6716097", "0.6648523", "0.65955305", "0.65955305", "0.65955305", "0.65955305", "0.65955305", "0.65955305", "0.65955305", "0.65955305", "0.65955305", "0.65955305", "0.65955305", "0.65955305", "0.65955305", "0.65955305", "0.65955305", "0.65955305", "0.65955305", "0.65955305", "0.65955305", "0.65955305", "0.65561384", "0.65485835", "0.65102494", "0.6468439", "0.6468439", "0.6465843", "0.64636415", "0.64308167", "0.6429604", "0.6364532", "0.6364532", "0.6364532", "0.6364532", "0.6364532", "0.6364532", "0.6364532", "0.6364532", "0.6364532", "0.6364532", "0.6364532", "0.6364532", "0.6364532", "0.63567007", "0.6355822", "0.6348876", "0.6348876", "0.6348876", "0.6348876", "0.6348876", "0.6348876", "0.6348876", "0.6348876", "0.6348876", "0.6348876", "0.6348876", "0.6348876", "0.6348876", "0.6348876", "0.6348876", "0.6348876", "0.6348876", "0.6348876", "0.6348876", "0.6348876", "0.6348876", "0.6348876", "0.6348876", "0.6348876", "0.6348876", "0.63195187", "0.63195187", "0.63195187", "0.63195187", "0.63195187", "0.63195187", "0.63195187", "0.63195187", "0.63195187", "0.63195187", "0.63195187", "0.63195187", "0.63195187", "0.63154733", "0.6212711", "0.6181239", "0.6176767" ]
0.0
-1
Indicate whether the binding is local or global. A global binding is one that has a fixed value for the life of a query or transformation; any other binding is local.
public boolean isGlobal();
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public boolean isGlobal() {\n return true;\n }", "public boolean isGlobalScopeOnly() {\n return this.isGlobalScopeOnly;\n }", "public boolean isLocal() {\n return local;\n }", "public boolean isLocal() {\n\t\treturn _local;\n\t}", "public boolean isLocal()\n {\n return true;\n }", "public boolean isLocal();", "public boolean isLocal() {\n return mIsLocal;\n }", "boolean isLocal();", "@Override\n\tpublic boolean isLocal() {\n\t\treturn heldObj.isLocal();\n\t}", "public boolean IsLocal() {\r\n\t\treturn BrickFinder.getDefault().isLocal();\r\n\t}", "public boolean is_global_transaction(){\n\t\treturn transaction_type == TransactionType.GLOBAL;\n\t}", "protected boolean atGlobalScope() {\n return !currentScope.hasParent();\n }", "public BindState(Set<AccessPath> globalVariableNames) {\n this.stateOnLastFunctionCall = null;\n this.globalDefs =\n addVariables(PathCopyingPersistentTree.<String, BindingPoint>of(), globalVariableNames);\n this.localDefs = new PathCopyingPersistentTree<>();\n }", "public boolean isMCGlobal() {\n\t\treturn javaNetAddress.isMCGlobal();\n\t}", "public boolean isGlobalEnabled() {\n\t\treturn globalEnabled;\n\t}", "private boolean isGlobalDeclaration() throws IOException\n\t{\n\t\tboolean isGlobal = false;\n\t\t\n\t\tif(theCurrentToken.TokenType == TokenType.GLOBAL)\n\t\t{\n\t\t\tisGlobal = true;\n\t\t\tupdateToken();\n\t\t\tSystem.out.println(\"Global!\");\n\t\t}\n\t\t\n\t\t// Determine declaration type.\n\t\tif(isProcedureDeclaration(isGlobal))\n\t\t\treturn true;\n\t\telse if(isVariableDeclaration(isGlobal))\n\t\t\treturn true;\n\t\telse\n\t\t\treturn false;\n\t}", "public boolean isSetBindSource() {\n return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __BINDSOURCE_ISSET_ID);\n }", "public boolean _is_local() {\n throw new NO_IMPLEMENT(reason);\n }", "public void setLocal(boolean isLocal);", "public boolean getUseLocal() {return this.databaseConfig.getProperty(\"useLocal\").equals(\"true\");}", "boolean hasIsBinding();", "public void testLocalBinding()\n throws Exception\n {\n getLog().debug(\"HAJndiTestCase.testLocalBinding()\");\n validateUrls();\n \n // bind to node0 locally\n Context naming = getContext(NODE0_JNDI);\n naming.bind(LOCAL0_KEY, LOCAL0_VALUE);\n closeContext(naming);\n \n // lookup binding locally on Node0 - should succeed\n naming = getContext(NODE0_JNDI);\n String value = (String)lookup(naming, LOCAL0_KEY);\n closeContext(naming);\n assertEquals(\"lookup local binding on same server\", LOCAL0_VALUE, value);\n \n // lookup binding locally on Node1 - should fail\n naming = getContext(NODE1_JNDI);\n value = (String)lookup(naming, LOCAL0_KEY);\n closeContext(naming);\n assertNull(\"lookup local binding on different server in cluster\", value);\n \n // lookup binding using HA-JNDI on Node0 - should succeed\n naming = getContext(NODE0_HAJNDI);\n value = (String)lookup(naming, LOCAL0_KEY);\n closeContext(naming);\n assertEquals(\"lookup local binding on same server using HA-JNDI\", LOCAL0_VALUE, value);\n \n // lookup binding using HA-JNDI on Node1 - should succeed\n naming = getContext(NODE1_HAJNDI);\n value = (String)lookup(naming, LOCAL0_KEY);\n closeContext(naming);\n assertEquals(\"lookup local binding on different server in cluster using HA-JNDI\", LOCAL0_VALUE, value);\n }", "public boolean needsBinding(){\n\t\tArrayList<String> bindVars = getNeedBindingVars();\n\t\tif(bindVars.isEmpty())\n\t\t\treturn false;\n\t\telse return true;\n\t}", "public boolean isSetLocal()\r\n {\r\n synchronized (monitor())\r\n {\r\n check_orphaned();\r\n return get_store().count_elements(LOCAL$0) != 0;\r\n }\r\n }", "int getGlobalIndex(int localIndex) {\r\n return local2globalIndex[localIndex];\r\n }", "protected boolean isGlobalVariable(String string) {\n\t\treturn string.charAt(0) == '@';\n\t}", "public boolean get_boolean() {\n return local_boolean;\n }", "public GlobalNode getGlobal() { return global; }", "public interface Binding {\n\n /**\n * Get the declared type of the variable\n * @return the declared type\n */\n\n public SequenceType getRequiredType();\n\n /**\n * Evaluate the variable\n * @param context the XPath dynamic evaluation context\n * @return the result of evaluating the variable\n */\n\n public ValueRepresentation evaluateVariable(XPathContext context) throws XPathException;\n\n /**\n * Indicate whether the binding is local or global. A global binding is one that has a fixed\n * value for the life of a query or transformation; any other binding is local.\n * @return true if the binding is global\n */\n\n public boolean isGlobal();\n\n /**\n * If this is a local variable held on the local stack frame, return the corresponding slot number.\n * In other cases, return -1.\n * @return the slot number on the local stack frame\n */\n\n public int getLocalSlotNumber();\n\n /**\n * Get the name of the variable\n * @return the name of the variable, as a structured QName\n */\n\n public StructuredQName getVariableQName();\n\n}", "public String getLocalFlag() {\n return (String)getAttributeInternal(LOCALFLAG);\n }", "void setBind() {\n for (int i = 1; i < size(); i++) {\n Exp f = get(i);\n if (f.isFilter() && f.size() > 0) {\n Exp bind = f.first();\n if (bind.type() == OPT_BIND\n // no bind (?x = ?y) in case of JOIN\n && (!Query.testJoin || bind.isBindCst())) {\n int j = i - 1;\n while (j > 0 && get(j).isFilter()) {\n j--;\n }\n if (j >= 0) {\n Exp g = get(j);\n if ((g.isEdge() || g.isPath())\n && (bind.isBindCst() ? g.bind(bind.first().getNode()) : true)) {\n bind.status(true);\n g.setBind(bind);\n }\n }\n }\n }\n }\n }", "boolean isBound();", "boolean canRewrite(int global, Stack<Integer> local);", "public boolean isAnyLocalAddress() {\n\t\treturn javaNetAddress.isAnyLocalAddress();\n\t}", "public boolean isRoot(){\n\t\treturn bound.isRoot();\n\t}", "public String getLocalFlag() {\n return (String) getAttributeInternal(LOCALFLAG);\n }", "public boolean isLocal()\n {\n try\n {\n Member member = getMember();\n return member == null || member.equals(\n getService().getCluster().getLocalMember());\n }\n catch (RuntimeException e)\n {\n // the local services are stopped\n // there is no good answer...\n return true;\n }\n }", "public boolean getUseGlobalService();", "public LocalScope getlocalScope() {\n return localScope;\n }", "public boolean isMCOrgLocal() {\n\t\treturn javaNetAddress.isMCOrgLocal();\n\t}", "public void setGlobalEnabled(boolean globalEnabled) {\n\t\tthis.globalEnabled = globalEnabled;\n\t}", "static public boolean isPatternGlobal(String flags) {\r\n\t\treturn flags.indexOf('g') != -1;\r\n\t}", "public String getLocal() {\n\t\treturn this.local;\n\t}", "public final PythonParser.global_stmt_return global_stmt() throws RecognitionException {\n PythonParser.global_stmt_return retval = new PythonParser.global_stmt_return();\n retval.start = input.LT(1);\n\n PythonTree root_0 = null;\n\n Token GLOBAL121=null;\n Token COMMA122=null;\n Token n=null;\n List list_n=null;\n\n PythonTree GLOBAL121_tree=null;\n PythonTree COMMA122_tree=null;\n PythonTree n_tree=null;\n RewriteRuleTokenStream stream_NAME=new RewriteRuleTokenStream(adaptor,\"token NAME\");\n RewriteRuleTokenStream stream_GLOBAL=new RewriteRuleTokenStream(adaptor,\"token GLOBAL\");\n RewriteRuleTokenStream stream_COMMA=new RewriteRuleTokenStream(adaptor,\"token COMMA\");\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:850:5: ( GLOBAL n+= NAME ( COMMA n+= NAME )* -> ^( GLOBAL[$GLOBAL, actions.makeNames($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:850:7: GLOBAL n+= NAME ( COMMA n+= NAME )*\n {\n GLOBAL121=(Token)match(input,GLOBAL,FOLLOW_GLOBAL_in_global_stmt3265); if (state.failed) return retval; \n if ( state.backtracking==0 ) stream_GLOBAL.add(GLOBAL121);\n\n n=(Token)match(input,NAME,FOLLOW_NAME_in_global_stmt3269); if (state.failed) return retval; \n if ( state.backtracking==0 ) stream_NAME.add(n);\n\n if (list_n==null) list_n=new ArrayList();\n list_n.add(n);\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:850:22: ( COMMA n+= NAME )*\n loop59:\n do {\n int alt59=2;\n int LA59_0 = input.LA(1);\n\n if ( (LA59_0==COMMA) ) {\n alt59=1;\n }\n\n\n switch (alt59) {\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:850:23: COMMA n+= NAME\n \t {\n \t COMMA122=(Token)match(input,COMMA,FOLLOW_COMMA_in_global_stmt3272); if (state.failed) return retval; \n \t if ( state.backtracking==0 ) stream_COMMA.add(COMMA122);\n\n \t n=(Token)match(input,NAME,FOLLOW_NAME_in_global_stmt3276); if (state.failed) return retval; \n \t if ( state.backtracking==0 ) stream_NAME.add(n);\n\n \t if (list_n==null) list_n=new ArrayList();\n \t list_n.add(n);\n\n\n \t }\n \t break;\n\n \tdefault :\n \t break loop59;\n }\n } while (true);\n\n\n\n // AST REWRITE\n // elements: GLOBAL\n // token labels: \n // rule labels: retval\n // token list labels: \n // rule list labels: \n // wildcard labels: \n if ( state.backtracking==0 ) {\n retval.tree = root_0;\n RewriteRuleSubtreeStream stream_retval=new RewriteRuleSubtreeStream(adaptor,\"rule retval\",retval!=null?retval.tree:null);\n\n root_0 = (PythonTree)adaptor.nil();\n // 851:4: -> ^( GLOBAL[$GLOBAL, actions.makeNames($n)] )\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:851:7: ^( GLOBAL[$GLOBAL, actions.makeNames($n)] )\n {\n PythonTree root_1 = (PythonTree)adaptor.nil();\n root_1 = (PythonTree)adaptor.becomeRoot(new Global(GLOBAL, GLOBAL121, actions.makeNames(list_n)), root_1);\n\n adaptor.addChild(root_0, root_1);\n }\n\n }\n\n retval.tree = root_0;}\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 boolean isConstant()\n {\n return analysis.getRequiredBindings().isEmpty();\n }", "public boolean createLocalScope(Function f){\n if(localConstantScopes.containsKey(f) || localVariableScopes.containsKey(f)){\n return false;\n }\n\n localConstantScopes.putIfAbsent(f, new HashMap<>());\n localVariableScopes.putIfAbsent(f, new HashMap<>());\n \n return true;\n }", "public boolean isItemLocal ();", "public boolean isBound(String name)\n {\n try\n {\n InitialContext ctx = new InitialContext();\n Object ds = ctx.lookup(name);\n if (ds == null) {\n return false;\n }\n return true;\n }\n catch (NamingException e)\n {\n return false;\n } // end of catch\n \n }", "public static boolean isGlobal(Symbol symbol) {\n if (symbol instanceof PseudoSymbol) {\n symbol = ((PseudoSymbol)symbol).getIRSymbol();\n }\n Traversable tr = (Traversable)symbol;\n while (tr != null && !(tr instanceof SymbolTable)) {\n tr = tr.getParent();\n }\n return (tr instanceof TranslationUnit);\n }", "public void addIsLocalClause() {\n if (!queryTarget.isCompatibleLocal()) {\n throw new IllegalArgumentException(\"Cannot addIsLocalFolderClause b/c DBQueryOperation already has a remote target\");\n }\n queryTarget = QueryTarget.LOCAL;\n allResultsQuery = false;\n includeIsLocalFolders = true;\n }", "public GlobalVariable defineGlobal(QName qname, SequenceType type)\n {\n GlobalVariable g = declareGlobal(qname, type);\n addDeclaration(g); // otherwise cant be initialized\n return g;\n }", "public void mergeGlobal() {\n if (global == null) return;\n // merge global nodes.\n Set set = Collections.singleton(GlobalNode.GLOBAL);\n global.replaceBy(set, true);\n nodes.remove(global);\n unifyAccessPaths(new LinkedHashSet(set));\n if (VERIFY_ASSERTIONS) {\n verifyNoReferences(global);\n }\n global = null;\n }", "boolean isSwitchingScope();", "boolean isScope();", "public boolean isMCNodeLocal() {\n\t\treturn javaNetAddress.isMCNodeLocal();\n\t}", "public String getBindingItemIdIsServer(){\n return bindingItemIdIsServer;\n }", "public boolean isLinkLocalAddress() {\n\t\treturn javaNetAddress.isLinkLocalAddress();\n\t}", "@Override\n public boolean isScoped() {\n \treturn getScope() != null && !getScope().isEmpty();\n }", "GlobalsType getGlobals();", "public static int checkGlobal(Token t) {\n for (int i = 0; i < global1.size(); i++) {\n\n if (t.instanc.equals(global1.get(i).instanc)) {\n return 1;\n }\n }\n support.error(\"This variable is not defined: \" + t.instanc + \": \" + t.lineNum);\n return -1;\n }", "boolean bind(Mapping map) {\n if (!isEdge()) {\n return false;\n }\n\n for (int i = 0; i < nbNode(); i++) {\n Node node = getNode(i);\n if (node.isVariable() && map.getNode(node) != null) {\n return true;\n }\n }\n\n return false;\n }", "public boolean isInEnv()\n {\n return environment().objectAt(location()) == this;\n }", "public void setUseGlobalService(boolean flag);", "public boolean isSetScope() {\r\n return this.scope != null;\r\n }", "protected boolean isBound(){\n\t\treturn !listeners.isEmpty();\n\t}", "protected boolean isBound(){\n\t\treturn !listeners.isEmpty();\n\t}", "private boolean bindNewVariable(String name, Obj value) {\n if (name.equals(\"_\")) return true;\n \n // Bind the variable.\n return mScope.define(mIsMutable, name, value);\n }", "public Namespace locateEntityBinding(String name, boolean local) {\n ActiveEntity ent = (entities == null)\n ? null : entities.getEntityBinding(name);\n if (ent != null) return entities;\n return (local || nameContext == null)\n ? null : nameContext.locateEntityBinding(name, local);\n }", "public boolean isSiteLocalAddress() {\n\t\treturn javaNetAddress.isSiteLocalAddress();\n\t}", "protected ConstraintElement globalizeConstraintElement(ConstraintElement localElement) throws QueryException {\n // return the element if it does not need to be converted\n if (!(localElement instanceof LocalNode) || (localElement instanceof URIReferenceImpl)) return localElement;\n \n // try {\n // convert the reference to a Value\n return makeRefImpl((URIReference)globalizeNode((LocalNode)localElement));\n // } catch (ResolverException re) {\n // throw new QueryException(\"Unable to globalize constraint element: \" + localElement, re);\n // }\n }", "public int getLocalPort() {\n if (state >= BOUND)\n return localPort;\n else\n return -1;\n }", "public boolean isMCLinkLocal() {\n\t\treturn javaNetAddress.isMCLinkLocal();\n\t}", "public boolean getIsServiceBound () ;", "boolean simpleBind(Filter f){\n// List<String> list = f.getVariables();\n// \n// for (Exp exp : this){\n// if (exp.isEdge() || exp.isPath() || exp.isValues() || exp.isBind()){\n// \n// }\n// }\n \n return true;\n }", "public BindingOperation getBindingOp() {\n return bindingOp;\n }", "public void set_boolean(boolean param) {\n this.local_boolean = param;\n }", "List<Exp> varBind() {\n List<Exp> lBind = new ArrayList<Exp>();\n for (int i = 0; i < size(); i++) {\n Exp f = get(i);\n if ((f.type == VALUES) || (f.isFilter() && f.size() > 0)) {\n Exp bind = f.first();\n if (bind.type() == OPT_BIND) {\n if (bind.isBindCst()) {\n // ?x = cst\n lBind.add(bind);\n } else {\n // filter has BIND\n // TODO: when there is a UNION, variables of BIND may not be all bound \n // so we cannot bind here\n //add(i, bind);\n //i++;\n }\n }\n }\n }\n return lBind;\n }", "public boolean hasPendingBindings() {\n synchronized (this) {\n long l10 = this.u;\n long l11 = 0L;\n long l12 = l10 == l11 ? 0 : (l10 < l11 ? -1 : 1);\n if (l12 == false) return false;\n return (boolean)((long)1);\n }\n }", "public static boolean isGlobalConnectionUsed(Path fileName, globalType globalType, int dotNetNumber, int globalNumber) {\n boolean isAddress = false;\n //TODO Create option for DotNet only connection used so that a list of used connection list can be created\n try {\n Document doc = getDocument(fileName);\n NodeList dotNetNodeList = doc.getElementsByTagName(\"commsController\");\n for (int dotNetCount = 0; dotNetCount < dotNetNodeList.getLength(); dotNetCount++) {\n Node dotNetNode = dotNetNodeList.item(dotNetCount);\n if (dotNetNode.getNodeType() == Node.ELEMENT_NODE) {\n Element eElement = (Element) dotNetNode;\n if (dotNetNumber == Integer.parseInt(eElement.getAttribute(\"address\"))) {\n // System.out.println(Integer.parseInt( eElement.getAttribute( \"address\" ) ));\n NodeList globalTypeNodeList = dotNetNode.getChildNodes();\n\n for (int globalTypeCount = 0; globalTypeCount < globalTypeNodeList.getLength(); globalTypeCount++) {\n if (globalTypeNodeList.item(globalTypeCount).getNodeName().equals(globalType.name())) {\n\n NodeList globalNodeList = globalTypeNodeList.item(globalTypeCount).getChildNodes();\n\n for (int globalCount = 0; globalCount < globalNodeList.getLength(); globalCount++) {\n\n if (globalNodeList.item(globalCount).getNodeName().equals(globalType.typeName)) {\n String no = \"null\";\n NodeList globalConNoList = globalNodeList.item(globalCount).getChildNodes();\n for (int glocalConNoCount = 0; glocalConNoCount < globalConNoList.getLength(); glocalConNoCount++) {\n if (globalConNoList.item(glocalConNoCount).getNodeName().contains(\"wideConnectionNumber\")) {\n no = globalConNoList.item(glocalConNoCount).getTextContent();\n }\n }\n if (!(no.contains(\"null\"))) {\n int gNumber = Integer.parseInt(no);\n if (globalNumber == gNumber) {\n isAddress = true;\n break;\n }\n }\n }\n }\n }\n\n\n }\n }\n }\n }\n } catch (Exception e) {\n e.printStackTrace();\n }\n return isAddress;\n }", "void setGlobalIndex(int localIndex, int globalIndex) {\r\n if (local2globalIndex == null) {\r\n local2globalIndex = new int[table.attributes.size()];\r\n }\r\n local2globalIndex[localIndex] = globalIndex;\r\n }", "boolean hasBbgGlobalId();", "public boolean isSetBindEmailSource() {\n return org.apache.thrift.EncodingUtils.testBit(__isset_bitfield, __BINDEMAILSOURCE_ISSET_ID);\n }", "public boolean getParam0(){\n return localParam0;\n }", "public void setGlobalStatus(boolean newStatus) {\n enabled = newStatus;\n }", "private static boolean isLocalVariableForFunction(String scopedVarName, String function) {\n return scopedVarName.startsWith(function + \"::\");\n }", "private boolean putGlobVar(String name){\n if(get(name) != null) return false;\n return globalVariables.putIfAbsent(name, name) == null;\n }", "public static boolean isGlobalUsed(Path fileName, int dotNetAddress, globalType globalType, int globalNumber) {\n boolean isAddress = false;\n try {\n Document doc = getDocument(fileName);\n NodeList dotNetNodeList = doc.getElementsByTagName(\"commsController\");\n for (int dotNetCount = 0; dotNetCount < dotNetNodeList.getLength(); dotNetCount++) {\n Node dotNetNode = dotNetNodeList.item(dotNetCount);\n if (dotNetNode.getNodeType() == Node.ELEMENT_NODE) {\n Element eElement = (Element) dotNetNode;\n if (dotNetAddress == Integer.parseInt(eElement.getAttribute(\"address\"))) {\n NodeList globalTypeNodeList = dotNetNode.getChildNodes();\n\n for (int globalTypeCount = 0; globalTypeCount < globalTypeNodeList.getLength(); globalTypeCount++) {\n if (globalTypeNodeList.item(globalTypeCount).getNodeName().equals(globalType.name())) {\n\n NodeList globalNodeList = globalTypeNodeList.item(globalTypeCount).getChildNodes();\n\n for (int globalCount = 0; globalCount < globalNodeList.getLength(); globalCount++) {\n\n if (globalNodeList.item(globalCount).getNodeName().equals(globalType.typeName)) {\n String no = ((Element) globalNodeList.item(globalCount)).getAttribute(\"number\");\n if (!(no.contains(\"null\"))) {\n int gNumber = Integer.parseInt(no);\n if (globalNumber == gNumber) {\n isAddress = true;\n break;\n }\n }\n }\n }\n }\n\n\n }\n }\n }\n }\n } catch (Exception e) {\n e.printStackTrace();\n }\n return isAddress;\n }", "public ActiveEntity getEntityBinding(String name, boolean local) {\n ActiveEntity ent = (entities == null)\n ? null : entities.getEntityBinding(name);\n if (debug() && ent != null) \n debug(\"Binding found for \" + name + \" \" + ent.getClass().getName());\n return (local || ent != null || nameContext == null)\n ? ent : nameContext.getEntityBinding(name, local);\n }", "public void setUseLocal(boolean useLocal) {this.databaseConfig.setProperty(\"useLocal\", Boolean.toString(useLocal));}", "public boolean hasPendingBindings() {\n synchronized (this) {\n long l10 = this.m;\n long l11 = 0L;\n long l12 = l10 == l11 ? 0 : (l10 < l11 ? -1 : 1);\n if (l12 == false) return false;\n return (boolean)((long)1);\n }\n }", "public boolean isLocalTransactionIdentifier() {\n return getNodeId().equals( PUID.EMPTY_PUID ) && getUserId().equals( PUID.EMPTY_PUID ) && getConnectionId().equals( PUID.EMPTY_PUID );\n }", "public static boolean isSecurityOnlyLocalRequests() {\r\n return (isSecurityOnlyLocalRequests);\r\n }", "public boolean hasLocality() {\n return localityBuilder_ != null || locality_ != null;\n }", "public Binding getBinding() {\n\t\treturn binding;\n\t}", "public GlobalScope() {\n super(null);\n }", "public boolean hasBbgGlobalId() {\n return ((bitField0_ & 0x00000800) == 0x00000800);\n }", "public boolean containsLocalColumn(ColumnInfo localColumn) {\n return doContainsLocalColumn(localColumn.getColumnDbName());\n }", "public boolean isSetBindingParams() {\n return this.bindingParams != null;\n }", "public java.lang.Boolean getMarkAsLocalSupported() {\r\n return markAsLocalSupported;\r\n }", "public boolean hasLocalId() {\n return fieldSetFlags()[1];\n }" ]
[ "0.68063986", "0.6642382", "0.66339254", "0.6526131", "0.6511175", "0.64047134", "0.6270221", "0.62645894", "0.6191824", "0.60546684", "0.6025515", "0.5934214", "0.5919706", "0.5876648", "0.58069", "0.5800291", "0.57821864", "0.5778584", "0.5640486", "0.5605833", "0.56029624", "0.55655843", "0.5500404", "0.5487231", "0.54832226", "0.5471611", "0.5428631", "0.53432304", "0.53264505", "0.5322931", "0.530616", "0.53040224", "0.5253606", "0.5238325", "0.5227558", "0.5225977", "0.5203602", "0.5191189", "0.51874965", "0.5164142", "0.5149647", "0.51397854", "0.512552", "0.51191324", "0.50978374", "0.5070315", "0.5056963", "0.5055248", "0.5049545", "0.50471455", "0.50336546", "0.5033551", "0.503197", "0.5031461", "0.501697", "0.49882773", "0.49770758", "0.49545085", "0.4941279", "0.4930071", "0.4927242", "0.49141872", "0.49115947", "0.490193", "0.48777646", "0.48777646", "0.48766443", "0.48563266", "0.48549488", "0.4835362", "0.48335144", "0.48270938", "0.48077798", "0.4805875", "0.4799516", "0.47951823", "0.47951728", "0.4784879", "0.4781896", "0.47806042", "0.4777584", "0.47629097", "0.47463658", "0.47432923", "0.473922", "0.4736128", "0.47359517", "0.47357976", "0.4735348", "0.4734403", "0.47171885", "0.47165513", "0.47106585", "0.4709374", "0.4706934", "0.46937722", "0.4692569", "0.4689469", "0.46844918", "0.46827728" ]
0.67222434
1
If this is a local variable held on the local stack frame, return the corresponding slot number. In other cases, return 1.
public int getLocalSlotNumber();
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public int getLocalSlotNumber() {\n return 0; //To change body of implemented methods use File | Settings | File Templates.\n }", "private int findFreeSlot(){\n\t\tfor(int i = 0; i < INVENTORY_SLOTS; i++){\n\t\t\tif(inventoryItems[i] == null){\n\t\t\t\treturn i;\n\t\t\t}\n\t\t}\n\t\treturn 0;\n\t}", "public int getSlot() {\r\n\t\treturn slot;\r\n\t}", "public SQLInteger getSlot() {\n\t\treturn slot;\n\t}", "public int getSlot() {\n\t\treturn slot;\n\t}", "private native int getSlotCount0();", "public int getSlot() {\n return slot;\n }", "public int getSlot() {\n return slot;\n }", "public int getSlotStackLimit()\n {\n return 1;\n }", "public int getSlotStackLimit()\n {\n return 1;\n }", "@Override\n public int getSlot() {\n\n if(availableSlots.size() == 0){\n return -1;\n }\n return availableSlots.first();\n }", "public boolean isSlot(int i);", "public int numSlots() {\t\t\r\n\t\tHashSet<Integer> slots = new HashSet<Integer>();\r\n\t\tfor(Entry s : stmts) {\r\n\t\t\ts.code.registers(slots);\r\n\t\t}\r\n\t\tint r = 0;\r\n\t\tfor(int i : slots) {\r\n\t\t\tr = Math.max(r,i+1);\r\n\t\t}\t\t\r\n\t\treturn Math.max(numInputs,r);\r\n\t}", "public int getSlotNumber() {\n return slotNumber;\n }", "public int getUnmanaged() {\n int ret = nextLocal++;\n return ret;\n }", "public int getSlotTracker() {\r\n return slotTracker;\r\n }", "public Stack getStack(int slot);", "@Override\r\n public int getSecondArg() {\n return localsNum;\r\n }", "public String resolveVariableName(int slot, int l) {\n \t\treturn null;\n \t}", "protected final int computeSlot(int paramInt)\n/* */ {\n/* 149 */ return (paramInt * 517 & 0x7FFFFFFF) % this.m_flagTable.length;\n/* */ }", "public int getSlotCount() { \n return getSlotCount0();\n }", "@Override\n\tpublic int getSlotIndex() {\n\t\treturn -1;\n\t}", "public String getAsSlot(int i);", "protected int assignSlot(int paramInt)\n/* */ {\n/* 164 */ int i = freeSlot(computeSlot(paramInt));\n/* 165 */ this.m_flagTable[i] = true;\n/* 166 */ this.m_keyTable[i] = paramInt;\n/* 167 */ return i;\n/* */ }", "public int get_int() {\n return local_int;\n }", "public int maxLocals();", "private int findSlot(K key, boolean forAdd)\r\n\t{\r\n\t\tint slot = hash1(key);\r\n\t\tint step = hash2(key);\r\n\t\tint M = table.length;\r\n\t\t\r\n\t\tif (forAdd)\r\n\t\t{\r\n\t\t\t//TODO: is it possible that this will loop forever?\r\n\t\t\twhile (true)\r\n\t\t\t{\r\n\t\t\t\tMapEntry<K, V> e = table[slot];\r\n\t\t\t\tif(e == null || e == DUMMY) //we can override DUMMY\r\n\t\t\t\t{ \r\n\t\t\t\t\treturn slot;\r\n\t\t\t\t}\r\n\t\t\t\telse\r\n\t\t\t\t{\r\n\t\t\t\t\tslot = (slot + step) % M;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t\telse\r\n\t\t{\r\n\t\t\t//TODO: is it possible that this will loop forever?\r\n\t\t\twhile (table[slot] != null)\r\n\t\t\t{\r\n\t\t\t\tMapEntry<K, V> e = table[slot];\r\n\t\t\t\tif(key.equals(e.getKey()))\r\n\t\t\t\t{\r\n\t\t\t\t\treturn slot;\r\n\t\t\t\t}\r\n\t\t\t\telse\r\n\t\t\t\t{\r\n\t\t\t\t\tslot = (slot + step) % M;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\t\r\n\t\t}\r\n\t\t\r\n\t\treturn -1;\r\n\t}", "private int m3944c(C0820v vVar, C0788a0 a0Var, int i) {\n if (!a0Var.mo4536g()) {\n return this.f3125N.mo4307b(i);\n }\n int i2 = this.f3123L.get(i, -1);\n if (i2 != -1) {\n return i2;\n }\n int a = vVar.mo4796a(i);\n if (a != -1) {\n return this.f3125N.mo4307b(a);\n }\n StringBuilder sb = new StringBuilder();\n sb.append(\"Cannot find span size for pre layout position. It is not cached, not in the adapter. Pos:\");\n sb.append(i);\n Log.w(\"GridLayoutManager\", sb.toString());\n return 1;\n }", "public int getStaticLevel(int slot) {\r\n return staticLevels[slot];\r\n }", "public int getHolder() {\n return this.pIndex;\n }", "public ItemStack getStackInSlot(int par1)\n {\n return par1 >= 9 ? null : tile.inventory[par1];\n }", "public int getSlotCount() {\n\t\t// TODO: Implement\n\t\treturn this.slotCount;\n\t}", "public int getALocationToPlaceBlock(){\n int lruIndex=-1,lruVal=-1;\n for(int i=0;i<this.localCache.length;i++){\n if(!this.localCache[i].isOccupied)// checks if the block is occupied\n return i;\n \n if(lruVal<this.localCache[i].lastUsed){// checks the last used of each block\n lruIndex=i;\n lruVal=this.localCache[i].lastUsed;\n }\n }\n \n return lruIndex;\n }", "public int getLevel(int slot) {\r\n return dynamicLevels[slot];\r\n }", "public int getPosOf(String varname){\n\t\tfor(int i=0;i<sqlVariables.length;i++){\n\t\t\tif(varname.equals(sqlVariables[i])){\n\t\t\t\treturn i;\n\t\t\t}\n\t\t}\n\t\treturn -1;\n\t}", "public int getBinderySlotNumber() {\n return binderySlotNumber;\n }", "public void getSlotNumber(String className) {\n try {\n Class<?> c = Class.forName(className);\n Field fields1 = c.getField(slotName1);\n fields1.setAccessible(true);\n slotNumber1 = (Integer) fields1.get(null);\n Field fields2 = c.getField(slotName2);\n fields2.setAccessible(true);\n slotNumber2 = (Integer) fields2.get(null);\n } catch (Exception e) {\n slotNumber1 = 0;\n slotNumber2 = 1;\n }\n }", "private int m3942b(C0820v vVar, C0788a0 a0Var, int i) {\n if (!a0Var.mo4536g()) {\n return this.f3125N.mo4312a(i, this.f3120I);\n }\n int i2 = this.f3124M.get(i, -1);\n if (i2 != -1) {\n return i2;\n }\n int a = vVar.mo4796a(i);\n if (a != -1) {\n return this.f3125N.mo4312a(a, this.f3120I);\n }\n StringBuilder sb = new StringBuilder();\n sb.append(\"Cannot find span size for pre layout position. It is not cached, not in the adapter. Pos:\");\n sb.append(i);\n Log.w(\"GridLayoutManager\", sb.toString());\n return 0;\n }", "public int getFirstValidSlot(ItemStack stack, IItemHandler handler)\n\t{\n\n\t\tfor (int i=0; i<handler.getSlots();i++)\n\t\t{\n\t\t\tif (handler.isItemValid(i, stack))\n\t\t\t\treturn i;\n\t\t}\n\t\treturn -1;\n\t}", "public ItemStack getStackInSlot(int p_70301_1_)\n {\n return p_70301_1_ >= 0 && p_70301_1_ < this.inventoryContents.length ? this.inventoryContents[p_70301_1_] : null;\n }", "private native int isSatSlot0(int slotNumber);", "@Override\n\tpublic ItemStack getStackInSlot(int p_70301_1_) {\n\t\treturn field_145900_a[p_70301_1_];\n\t}", "public static int getFirstItemSlot(Player player, ItemStack istack) {\n\t\tPlayerInventory inv = player.getInventory();\n\t\tItemStack[] contents = inv.getContents();\n\t\tfor (int i = 0; i < contents.length; i++) {\n\t\t\tif (contents[i] != null) {\n\t\t\t\tif (contents[i].getType() == istack.getType()) {\n\t\t\t\t\treturn i;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn -1;\n\t}", "private String getSlot() {\n\t\tint slotPick = rgen.nextInt(1, 7);\n\t\t\tswitch (slotPick) {\n\t\t\tcase 1: return CHERRY;\n\t\t\tcase 2: return LEMON;\n\t\t\tcase 3: return ORANGE;\n\t\t\tcase 4: return PLUM;\n\t\t\tcase 5: return BELL;\n\t\t\tcase 6: return BAR;\n\t\t\tcase 7: return EMPTY_SLOT;\n\t\t\tdefault: return null;\n\t\t}\n\t}", "public java.lang.Integer getVar232() {\n return var232;\n }", "public static int getSlot(String inp) {\n \n String[] sp = inp.split(\"(?!^)\");/*https://stackoverflow.com/questions/5235401/split-string-into-array-of-character-strings*/\n\n if (sp.length != 2) {\n return 99;\n }\n\n int nmbr = 0;\n // check the row\n if (sp[0].equals(\"a\")) { // row 1: values 0, 1, 2\n nmbr += 0;\n } else if (sp[0].equals(\"b\")) { // row 2: values 3, 4, 5\n nmbr += 3;\n } else if (sp[0].equals(\"c\")) { // row 3: values 6, 7, 8\n nmbr += 6;\n } else {\n return 99;\n }\n \n int parsed = Integer.parseInt(sp[1]);\n\n if (parsed > 3 || parsed == 0) {\n return 99;\n }\n\n nmbr += parsed - 1; // add the column value\n return nmbr;\n }", "public java.lang.Integer getVar232() {\n return var232;\n }", "public abstract int getBindingVariable();", "private int indexToSlot(int listIndexPosition)\n {\n Integer slot = indexToSlotList.get(listIndexPosition);\n\n return slot.intValue();\n }", "int getBlockNumber();", "int getBlockNumber();", "@Override\n\tpublic int getVarThisFlag() {\n\t\treturn heldObj.getVarThisFlag();\n\t}", "public int pickVictim() {\r\n\t\t\r\n\t\tfor(int counter = 0; counter < numberOfFrame * 2; counter++) {\r\n\r\n\t\t\tif(frametab[current].getPageId().pid==INVALID_PAGEID)\r\n\t\t\t//if(frametab[current].getValid())\r\n\t\t\t{\r\n\t\t\t\tavailFrame = true;\r\n\t\t\t\tbreak;\r\n\t\t\t}\r\n\t\t\tif(frametab[current].getPinCount() == 0) {\r\n\t\t\t\tif(frametab[current].getRef() == true) {\r\n\t\t\t\t\tframetab[current].setRef(false);\r\n\t\t\t\t}\r\n\t\t\t\telse{\r\n\t\t\t\t\tavailFrame = true;\r\n\t\t\t\t\tbreak;\r\n\t\t\t\t}\t\t\t\t\t\r\n\t\t\t}\r\n\t\t\tcurrent = (current + 1) % numberOfFrame;\r\n\r\n\t\t} // End for loop\r\n\t\t\r\n\t\tif(availFrame == false)\r\n\t\t\tthrow new IllegalStateException(\"No available Frame.\");\r\n\t\t\r\n\t\treturn current; \r\n\t}", "public int getCurrent(TypeReference type) {\n if (type == null) {\n throw new IllegalArgumentException(\"The argument type may not be null\");\n }\n\n int candidateSSA = -1;\n int candidateScope = -1;\n\n if (seenTypes.containsKey(type)) {\n for (ManagedParameter param : seenTypes.get(type)) {\n if ((param.status == ValueStatus.FREE) ||\n (param.status == ValueStatus.ALLOCATED)) {\n assert (param.type.equals(type)) : \"Inequal types\";\n if (param.setInScope > currentScope) {\n \n continue;\n } else if (param.setInScope == currentScope) {\n \n return param.ssa;\n } else {\n if (param.setInScope > candidateScope) {\n candidateScope = param.setInScope;\n candidateSSA = param.ssa;\n }\n }\n } else {\n \n }\n }\n } else {\n throw new IllegalArgumentException(\"Type \" + type + \" has never been seen before!\");\n }\n\n if (candidateSSA < 0 ) {\n \n return candidateSSA;\n } else {\n throw new IllegalStateException(\"No suitable candidate has been found for \" + type.getName());\n }\n }", "public ItemStack getStackInSlot(int par1)\n {\n return this.furnaceItemStacks[par1];\n }", "public int indexVar(Node node) {\n Expr ee = getFilter().getExp();\n String name = node.getLabel();\n for (int i = 0; i < 2; i++) {\n if (ee.getExp(i).type() == ExprType.VARIABLE\n && ee.getExp(i).getLabel().equals(name)) {\n return i;\n }\n }\n return -1;\n }", "public Local getRegisterLocal(int num) throws InvalidDalvikBytecodeException {\n int totalRegisters = registerLocals.length;\n if (num > totalRegisters) {\n throw new InvalidDalvikBytecodeException(\n \"Trying to access register \"\n + num\n + \" but only \"\n + totalRegisters\n + \" is/are available.\");\n }\n return registerLocals[num];\n }", "public int getSlots() {\n\t\treturn this.rows * 9;\n\t}", "public Closure find_var(String name){\n Closure currentClosure = this;\n while (currentClosure != null){\n if (currentClosure.contains(name)){\n return currentClosure;\n }\n currentClosure = currentClosure.getParent();\n }\n throw new UndefinedVariable();\n }", "public ItemStack func_82846_b(EntityPlayer par1EntityPlayer, int slot) {\n/* 82 */ ItemStack stack = ItemStack.field_190927_a;\n/* 83 */ Slot slotObject = (Slot)this.field_75151_b.get(slot);\n/* */ \n/* */ \n/* 86 */ if (slotObject != null && slotObject.func_75216_d()) {\n/* 87 */ ItemStack stackInSlot = slotObject.func_75211_c();\n/* 88 */ stack = stackInSlot.func_77946_l();\n/* */ \n/* 90 */ if (slot == 0) {\n/* 91 */ if (!func_75135_a(stackInSlot, 1, this.field_75151_b.size(), true)) {\n/* 92 */ return ItemStack.field_190927_a;\n/* */ }\n/* */ }\n/* 95 */ else if (!func_75135_a(stackInSlot, 0, 1, false)) {\n/* 96 */ return ItemStack.field_190927_a;\n/* */ } \n/* */ \n/* 99 */ if (stackInSlot.func_190916_E() == 0) {\n/* 100 */ slotObject.func_75215_d(ItemStack.field_190927_a);\n/* */ } else {\n/* 102 */ slotObject.func_75218_e();\n/* */ } \n/* */ } \n/* */ \n/* 106 */ return stack;\n/* */ }", "private static int getSlotIndex(int par0, int par1)\n {\n return par0 & par1 - 1;\n }", "public int peek(){\n return runStack.peek();\n }", "public int integerVarAt(int index) {\n\t\treturn storage[index];\n\t}", "int getSlotsCount();", "public int get_var_count()\r\n {\r\n\r\n int retVal = get_var_count_0(nativeObj);\r\n\r\n return retVal;\r\n }", "public static int getFreeFrame(){\n\t\tint frameNo = -1;\n\t\tfor(int i=0;i<memory_fmbv.length;i++){\n\t\t\tif(memory_fmbv[i] == 0){\n\t\t\t\tframeNo = i;\n\t\t\t\tmemory_fmbv[i] = 1;\n\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\t\treturn frameNo;\n\t}", "private int m2009c(@C0193h0 C0370g gVar) {\n int size = this.f1282T.size();\n for (int i = 0; i < size; i++) {\n if (gVar == ((C0365d) this.f1282T.get(i)).f1310b) {\n return i;\n }\n }\n return -1;\n }", "public int getPointer(){\n return this.pointInventory;\n }", "public void visitLocalVariableInstruction(LocalVariableInstruction o){\n\t\tif (locals().maxLocals() <= (o.getType(cpg).getSize()==1? o.getIndex() : o.getIndex()+1) ){\n\t\t\tconstraintViolated(o, \"The 'index' is not a valid index into the local variable array.\");\n\t\t}\n\t}", "public int getCurrentNumber()\r\n\t{\r\n\t\treturn currentNumber;\r\n\t}", "private boolean putLocalVar(String name){\n if(currentVariables == null) return false;\n if(get(name) != null) return false;\n\n for (int i = 0; i < Integer.MAX_VALUE - 1; i++) {\n if(!currentVariables.containsValue(i)){\n currentVariables.put(name, i); \n return true;\n }\n }\n return false;\n }", "public int getRow() {\r\n\t\treturn slot / 9;\r\n\t}", "public java.lang.Integer getVar127() {\n return var127;\n }", "@Override\n\tpublic Object visitDec(Dec declaration, Object arg) throws Exception {\n\t\tdeclaration.slotnumber = (num++);\n\t\t//System.out.println(declaration.slotnumber);\n\t\treturn null;\n\t}", "public java.lang.Integer getVar42() {\n return var42;\n }", "public java.lang.Integer getVar127() {\n return var127;\n }", "public void setBinderySlotNumber(int s) {\n if (!isUnused()) {\n binderySlotNumber = s;\n }\n }", "public IntegerVariable getIntegerVariable(String name) {\n return integerVariableMap.get(name);\n }", "private static int isVariable(ArrayList<Variable> vars, String name) {\n\t\tfor (int i = 0; i < vars.size(); i++) {\n\t\t\tif (vars.get(i).name.equals(name)) {\n\t\t\t\treturn i;\n\t\t\t}\n\t\t}\n\t\treturn -1;\n\t}", "protected final int internalFind(int paramInt)\n/* */ {\n/* 200 */ int i = computeSlot(paramInt);\n/* 201 */ while (this.m_flagTable[i] != false) {\n/* 202 */ if (paramInt == this.m_keyTable[i]) {\n/* 203 */ return i;\n/* */ }\n/* 205 */ i = stepSlot(i);\n/* */ }\n/* 207 */ return -i - 1;\n/* */ }", "default int getMaximumCount(int slot) {\n\t\treturn 64;\n\t}", "GlobalVariable getStartOffsetCounterVariable();", "public int getNumOfSp(){\r\n // return statement\r\n return numOfSp;\r\n }", "public int getElementAtTopOfStack() {\n if (isEmpty()) throw new RuntimeException(\"Stack underflow\");\n return myarray[top];\n \n }", "private static long slotOffset(int i) {\n return ((long) i << qShift) + qBase;\n }", "static int varno(String v) {\n int i=0;\n if (varlist==null) {System.out.println(\"Varlist null\");}\n while (i<varlist.size() && !v.equals( ((Variable)(varlist.get(i))).ident)) {i++;}\n if (i==varlist.size()) {i=-1;}\n return i;\n }", "final int threadLocalSize()\r\n/* 154: */ {\r\n/* 155:182 */ return ((Stack)this.threadLocal.get()).size;\r\n/* 156: */ }", "@Override\n public int evaluate(SymbolTable symTab) {\n return symTab.get(name);\n }", "public IDecisionVariable getNestedVariable(String slotName) {\r\n IDecisionVariable result = null;\r\n if (parent instanceof CompoundVariable) {\r\n result = ((CompoundVariable) parent).getNestedVariable(slotName);\r\n } else {\r\n Value tmp = Configuration.dereference(conf, value);\r\n if (tmp instanceof CompoundValue) { // not available for Container\r\n CompoundValue cValue = (CompoundValue) tmp;\r\n Compound type = (Compound) cValue.getType();\r\n DecisionVariableDeclaration slotDecl = type.getElement(slotName);\r\n if (null != slotDecl) {\r\n Value slotValue = cValue.getNestedValue(slotName);\r\n if (!Reference.TYPE.isAssignableFrom(slotDecl.getType())) { // don't dereference references\r\n slotValue = Configuration.dereference(conf, slotValue);\r\n }\r\n LocalDecisionVariable var = new LocalDecisionVariable(slotDecl, conf, null);\r\n if (null != slotValue) {\r\n try {\r\n var.setValue(slotValue, AssignmentState.ASSIGNED);\r\n } catch (ConfigurationException e) {\r\n }\r\n }\r\n result = var;\r\n }\r\n } \r\n }\r\n return result;\r\n }", "public static int getMaxSlot() {\n\t\tString maxSlot = Utils.getValueFromConfig(\"max_slot\");\n\t\tif (maxSlot == null || maxSlot.isEmpty())\n\t\t{\n\t\t\treturn MAX_SLOT;\n\t\t}\n\t\treturn Integer.parseInt(maxSlot);\n\t}", "private LocalVariables locals(){\n\t\treturn frame.getLocals();\n\t}", "public Integer get(String name){\n\t\treturn blocks.getLast().get(name);\n\t}", "public int getCurrentIdx() {\n\t\treturn this.currentIdx;\n\t}", "private native boolean selectSlot0(int slotIndex);", "public java.lang.Integer getVar42() {\n return var42;\n }", "@Override\n\tpublic ItemStack getStackInSlot(int slot){\n\t return modularStacks[slot];\n\t}", "private Integer varOffset( String defun, String varname ) {\n\treturn symbolTable.get( defun ).get( varname );\n }", "public int getValue(String name) {\r\n // Looks things up in the symbol table\r\n return symbolTable.getValue(name);\r\n }", "public ItemStack getStackInSlot(int slot)\n {\n return waterjetStacks[slot];\n }", "public int getCardSlot() {\n return cardSlot;\n }" ]
[ "0.6921299", "0.61746407", "0.6134313", "0.6124463", "0.6103253", "0.60748273", "0.6037091", "0.6037091", "0.59612685", "0.59612685", "0.5923841", "0.58501244", "0.5845142", "0.5823851", "0.58001375", "0.57985574", "0.57787895", "0.57688355", "0.5736412", "0.5685913", "0.5669926", "0.56616616", "0.5646432", "0.55512714", "0.55469745", "0.5517034", "0.5502067", "0.54377913", "0.5432819", "0.5426413", "0.5407516", "0.5407388", "0.5397483", "0.5385827", "0.537578", "0.5333413", "0.53297037", "0.5323673", "0.53055894", "0.53053445", "0.52991503", "0.52981925", "0.5294447", "0.52739227", "0.52691746", "0.52686495", "0.52644867", "0.52627903", "0.5259018", "0.52367675", "0.52367675", "0.5234898", "0.5227276", "0.5224451", "0.5202336", "0.51979876", "0.5191247", "0.51882505", "0.5185296", "0.51845104", "0.51797575", "0.51792306", "0.5175923", "0.5173327", "0.5166374", "0.51558715", "0.51501364", "0.51328236", "0.5125856", "0.51229656", "0.51125777", "0.508896", "0.50869876", "0.5085713", "0.5083129", "0.50794095", "0.5078418", "0.5075775", "0.50749624", "0.5072097", "0.5068967", "0.50541806", "0.50513166", "0.5047995", "0.5039828", "0.50378686", "0.5037014", "0.50336593", "0.50222087", "0.50144356", "0.50120604", "0.50086266", "0.50023216", "0.49992463", "0.49869126", "0.49855393", "0.49806997", "0.4971967", "0.4966423", "0.4964115" ]
0.73595685
0
Get the name of the variable
public StructuredQName getVariableQName();
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "String getVarName();", "String getVarName();", "String getVarName();", "String getVarName(String name);", "String getVariable();", "public String getVariable();", "public String variable()\n\t{\n\t\treturn _var;\n\t}", "public String getVariableName() {\n\t\treturn variableName;\n\t}", "public String getVariableName() {\n\t\treturn variableName;\n\t}", "public Name getVariable() {\n return variable;\n }", "public String getVariableName() {\n return _vname;\n }", "public String toString () {\n return nameOfVar;\n }", "public Variable getVariable(String name);", "String getVariableDefinition();", "public String getVar() {\n\t\treturn state.get(PropertyKeys.var);\n\t}", "public IString getVariableIdentifier() {\n\treturn VARIABLE_IDENTIFIER.get(getNd(), this.address);\n }", "public String getVar () {\n\t\treturn var;\n\t}", "public String getVariable()\n {\n return this.strVariable;\n }", "public StructuredQName getObjectName() {\n return getVariableQName();\n }", "public String getVariable() {\n return variable;\n }", "private String getVarName(GradsDimension dim) {\n for (int i = 0; i < dimNames.length; i++) {\n if (dim.getName().equalsIgnoreCase(dimNames[i])) {\n return dimVarNames[i];\n }\n }\n return dim.getName();\n }", "public String getVar()\n {\n return var;\n }", "public String getVar() {\n\t\treturn _var;\n\t}", "String getVarDeclare();", "@Override\n public SymbolicName getSymbolicName() {\n return new SymbolicName(StandardNames.XSL_VARIABLE, variableQName);\n }", "public Identifier getName();", "public String getElementVarName() {\r\n\t\treturn elementVarName;\r\n\t}", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "public String getVariable(String _name) {\r\n\t\treturn getVariable(_name, \",\");\r\n\t}", "public StructuredQName getVariableQName() {\n return variableQName;\n }", "Node getVariable();", "String getValueName();", "public String getName()\r\n\t{\r\n\t\treturn name; // gives the value of the name to the caller\r\n\t}", "public java.lang.String getName();", "public String getLhsName() {\n Xnode lhs = getLhs();\n if(lhs != null) {\n return (lhs.opcode() == Xcode.VAR) ? lhs.value() :\n lhs.matchSeq(Xcode.VAR_REF, Xcode.VAR).value();\n }\n return \"\";\n }", "java.lang.String getVarValue();", "String getName( );", "public String name() {\n return myStrVal;\n }", "public String getParameterName(int index) {\n List<? extends VariableElement> parameters = executable.getParameters();\n String name = parameters.get(index).getSimpleName().toString();\n return name;\n }", "PropertyName getName();", "@Override\n\tpublic String getSymbolName()\n\t{\n\t\tVariableDeclarationContext ctx = getContext();\n\t\tNameContextExt nameContextExt = (NameContextExt)getExtendedContext(ctx.name());\n\t\treturn nameContextExt.getFormattedText();\n\t}", "String getName() ;", "public static String getName()\n {\n read_if_needed_();\n \n return _get_name;\n }", "SimpleName getName();", "public final String getName() {\n\treturn name.getName();\n }", "public String getName() {\r\n\t\treturn name.get();\r\n\t}", "public String getVarName(PlainGraph graph, PlainNode grooveName) {\n return graphNodeMap.get(graph).entrySet().stream()\n .filter(e -> e.getValue().equals(grooveName))\n .collect(Collectors.toList())\n .get(0)\n .getKey();\n }", "Name getName();", "final public Identifier getName ()\n {\n\treturn myName;\n }" ]
[ "0.83274627", "0.83274627", "0.83274627", "0.81303656", "0.81021", "0.7803678", "0.7726254", "0.7631941", "0.7631941", "0.74622566", "0.74481386", "0.74296284", "0.73227125", "0.7242122", "0.7177164", "0.71471745", "0.7079293", "0.7067927", "0.69971603", "0.6976947", "0.69674295", "0.6953836", "0.69273484", "0.68915355", "0.68902", "0.6816767", "0.6696538", "0.6684719", "0.6684719", "0.6684719", "0.6684719", "0.6684719", "0.6684719", "0.6684719", "0.6684719", "0.6684719", "0.6684719", "0.6684719", "0.6684719", "0.6684719", "0.6684719", "0.6684719", "0.6684719", "0.6684719", "0.6684719", "0.6684719", "0.6684719", "0.6684719", "0.6684719", "0.6684719", "0.6684719", "0.6684719", "0.6684719", "0.6684719", "0.6684719", "0.6684719", "0.6684719", "0.6684719", "0.6684719", "0.6684719", "0.6684719", "0.6684719", "0.6684719", "0.6684719", "0.6684719", "0.6684719", "0.6684719", "0.6684719", "0.6684719", "0.6684719", "0.6684719", "0.6684719", "0.6684719", "0.6684719", "0.6684719", "0.6684719", "0.6684719", "0.6684719", "0.6684719", "0.6658423", "0.66371834", "0.66353685", "0.6580994", "0.657464", "0.6563722", "0.6555907", "0.65446186", "0.6536492", "0.65254676", "0.65197587", "0.6513627", "0.6491676", "0.6484439", "0.6481119", "0.64467067", "0.6446286", "0.6429357", "0.6426392", "0.6426117", "0.64100474" ]
0.67096376
26
Test of addAnalysis method, of class Writer.
@Test public void testAddAnalysis() { System.out.println("addAnalysis"); Analysis a = new Analysis(BigDecimal.ONE, BigDecimal.ONE, BigDecimal.ONE, null, 1, null, null, 1); assertEquals(0, w.analysies.size()); w.addAnalysis(a); assertEquals(1, w.analysies.size()); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Test\n\tpublic void testWriteToFile() {\n\t\tArrayList<ArrayList<String>> risultatoAnalisi = \n\t\t\t\tnew ArrayList<ArrayList<String>>();\n\t\toutput.setAnalysisResult(risultatoAnalisi);\n\t\tString percorso = \"\";\n\t\toutput.setOutputFileFolder(percorso);\n\t\ttry {\n\t\t\toutput.writeToFile();\n\t\t} catch (IOException e) {\n\t\t\tfail(\"Problem when writing to specified path.\");\n\t\t}\n\t\tassertTrue(new File(percorso + \"analysis.txt\").exists());\n\t\t/*\n\t\t * Ora passo un path corretto e controllo che venga creato il fiile\n\t\t */\n\t\tpercorso = \"test-dir\";\n\t\toutput.setOutputFileFolder(percorso);\n\t\ttry {\n\t\t\toutput.writeToFile();\n\t\t} catch (IOException e) {\n\t\t\tfail(\"Problem when writing to specified path.\");\n\t\t}\n\t\tassertTrue(new File(percorso + File.separator + \"analysis.txt\").exists());\n\t\t/*\n\t\t * Ripeto il test con valori da scrivere\n\t\t */\n\t\tArrayList<String> datiCasuali = new ArrayList<String>();\n\t\tdatiCasuali.add(\"27\");\n\t\trisultatoAnalisi.add(datiCasuali);\n\t\tdatiCasuali.add(\"12\");\n\t\trisultatoAnalisi.add(datiCasuali);\n\t\tdatiCasuali.add(\"3245543\");\n\t\trisultatoAnalisi.add(datiCasuali);\n\t\toutput.setAnalysisResult(risultatoAnalisi); \n\t\tpercorso = \"\";\n\t\toutput.setOutputFileFolder(percorso);\t\t\n\t\ttry {\n\t\t\toutput.writeToFile();\n\t\t} catch (IOException e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t\tfail(\"Problem when writing to specified path.\");\n\t\t}\n\t\tassertTrue(new File(percorso + \"analysis.txt\").exists());\n\t}", "@Test\n public void testAdd()\n {\n System.out.println(\"add\");\n final File file = new File(\"src/test/data/test.example.txt\");\n final Lexer lexer = new Lexer();\n final Token token = lexer.analyze(file);\n assertTrue(token.size() == 159);\n }", "void write(TestResult testResult);", "public static void testSet07(PrintStream outputStream)\r\n {\r\n outputStream.println(\"\\r\\n----Test Set 7----\\r\\n\");\r\n // Test #1 \r\n DynamicArray a1 = new DynamicArray(2);\r\n a1.add(0, 5);\r\n a1.add(0, 6);\r\n a1.add(1, 7);\r\n int[] test1 ={6, 7, 5, 0};\r\n if(equal(a1.getArray(), test1) && a1.getCapacity()==4) \r\n {\r\n outputStream.printf(\"%-80s%-10s\\r\\n\", \"Test Set 07: Test 1 for add()\", \"PASSED\");\r\n \r\n }\r\n else outputStream.printf(\"%-80s%-10s\\r\\n\", \"Test Set 07: Test 1 for add()\", \"FAILED\");\r\n // Test #2 \r\n \r\n a1.add(2, 2);\r\n a1.add(3, 3);\r\n int[] test2 = {6, 7, 2, 3, 5, 0, 0, 0};\r\n if(equal(a1.getArray(), test2) && a1.getCapacity()==8) \r\n {\r\n outputStream.printf(\"%-80s%-10s\\r\\n\", \"Test Set 07: Test 2 for add()\", \"PASSED\");\r\n \r\n }\r\n else outputStream.printf(\"%-80s%-10s\\r\\n\", \"Test Set 07: Test 2 for add()\", \"FAILED\");\r\n\r\n// Test #3\r\n try{\r\n a1.add(55, 55);\r\n outputStream.printf(\"%-80s%-10s\\r\\n\", \"Test Set 07: Test 3 for add() - exception\", \"FAILED\");\r\n }\r\n catch(IndexOutOfBoundsException e)\r\n {\r\n outputStream.printf(\"%-80s%-10s\\r\\n\", \"Test Set 07: Test 3 for add() - exception\", \"PASSED\");\r\n \r\n }\r\n \r\n }", "@Test\n\t public void testAdd() {\n\t\t TestSuite suite = new TestSuite(RecommendationModelTest.class, AnalysisModelTest.class);\n\t\t TestResult result = new TestResult();\n\t\t suite.run(result);\n\t\t System.out.println(\"Number of test cases = \" + result.runCount());\n\n\t }", "public void addAnalysisByPatient(Analysis analysis, Patient patient){\n try {\n analysisDAO.addAnalysis(analysis, patient);\n log.info(analysisDAO);\n log.info(\"Analyzes was added!\");\n } catch (PersistenceException e) {\n e.printStackTrace();\n log.info(\"Analyzes was not added!\");\n }\n }", "public void analysis(){\n\n\n this.outputFilename = \"PCAOutput\";\n if(this.fileOption==1){\n this.outputFilename += \".txt\";\n }\n else{\n this.outputFilename += \".xls\";\n }\n String message1 = \"Output file name for the analysis details:\";\n String message2 = \"\\nEnter the required name (as a single word) and click OK \";\n String message3 = \"\\nor simply click OK for default value\";\n String message = message1 + message2 + message3;\n String defaultName = this.outputFilename;\n this.outputFilename = Db.readLine(message, defaultName);\n this.analysis(this.outputFilename);\n }", "public void writeAnalysis(File file) throws IOException {\n FileWriter writer = new FileWriter(file);\n boolean wasSuccessful = wasSuccessful();\n String overview = \"# Overview\"\n + \"\\n - Connection from: \"\n + getClientIp()\n + \"\\n - Player name: \"\n + getPlayerName()\n + \"\\n - Scenario: \"\n + getScenario()\n + \"\\n - Architect: \"\n + getArchitect()\n + \"\\n - Successful: \"\n + wasSuccessful\n + \"\\n\\n## Times\"\n + \"\\n - Start Time: \"\n + getStartTime()\n + \"\\n - Success Time: \"\n + (wasSuccessful ? getSuccessTime() : \"not applicable\")\n + \"\\n - End Time: \"\n + getEndTime()\n + \"\\n - Experiment Duration: \"\n + (wasSuccessful ? getTimeToSuccess() + \" seconds\" : \"not applicable\")\n + \"\\n - Total time logged in: \"\n + getTotalTime()\n + \" seconds\\n\\n## Blocks\"\n + \"\\n - Number of blocks placed: \"\n + getNumBlocksPlaced()\n + \"\\n - Number of blocks destroyed: \"\n + getNumBlocksDestroyed()\n + \"\\n - Number of mistakes: \"\n + getNumMistakes();\n writer.write(overview);\n writer.flush();\n\n List<Integer> blockDurations = getBlockPlacedDurations();\n StringBuilder durations = new StringBuilder(\"\\n\\n# Duration per block\");\n for (int current: blockDurations) {\n durations.append(\"\\n - \").append(current).append(\"ms\");\n }\n\n if (wasSuccessful) {\n List<Pair<String, HLOInformation>> HLODurations = getHLOInformation();\n durations.append(\"\\n\\n# Durations per High-level object\");\n for (var pair : HLODurations) {\n durations.append(\"\\n - \").append(pair.getFirst());\n durations.append(\" : \").append(pair.getSecond().duration);\n durations.append(\"ms\");\n }\n\n List<Pair<String, Integer>> instructionDurations = getDurationPerInstruction();\n durations.append(\"\\n\\n# Durations per Instruction\");\n for (var pair : instructionDurations) {\n durations.append(\"\\n - \").append(pair.getFirst());\n durations.append(\" : \").append(pair.getSecond());\n durations.append(\"ms\");\n }\n }\n writer.write(durations.toString());\n writer.close();\n }", "void write(TestResultContainer testResultContainer);", "void analysisPostponed();", "@Test\n public void testImprimirStatistics()\n {\n //this.linealRegressionCalculator.printStatistics();\n }", "void createdOutput(TestResult tr, Section section, String outputName);", "private void addAnalysisSummary()\r\n throws XMLStreamException\r\n {\r\n SimpleStartElement start;\r\n SimpleEndElement end;\r\n\r\n addNewline();\r\n\r\n start = new SimpleStartElement(\"analysis_summary\");\r\n start.addAttribute(\"analysis\", mimicXpress ? \"xpress\" : \"q3\");\r\n start.addAttribute(\"time\", now);\r\n// start.addAttribute(\"xmlns\",\"\");\r\n add(start);\r\n\r\n addNewline();\r\n\r\n String tagName = mimicXpress ? \"xpressratio_summary\" : \"q3ratio_summary\";\r\n start = new SimpleStartElement(tagName);\r\n start.addAttribute(\"version\", mimicXpress ? \"0.0\" : Q3.VERSION);\r\n start.addAttribute(\"author\", Q3.AUTHOR);\r\n\r\n // ???? Must ensure format of multiples is compatible with TPP\r\n StringBuilder residues = new StringBuilder();\r\n StringBuilder specs = new StringBuilder();\r\n boolean first = true;\r\n for (IsotopicLabel label : labels.values())\r\n {\r\n residues.append(label.getResidue());\r\n if (first)\r\n first = false;\r\n else\r\n specs.append(' ');\r\n specs.append(label.getResidue());\r\n specs.append(',');\r\n specs.append(String.format(\"%f\", label.getMassDiff()));\r\n }\r\n\r\n start.addAttribute(\"labeled_residues\", residues.toString());\r\n start.addAttribute(\"massdiff\", specs.toString());\r\n\r\n start.addAttribute(\"massTol\", mimicXpress ? \"0.75\" : \".1\");\r\n\r\n if (mimicXpress)\r\n {\r\n start.addAttribute(\"same_scan_range\", \"Y\");\r\n start.addAttribute(\"xpress_light\", \"0\");\r\n }\r\n\r\n add(start);\r\n\r\n end = new SimpleEndElement(tagName);\r\n add(end);\r\n\r\n addNewline();\r\n\r\n end = new SimpleEndElement(\"analysis_summary\");\r\n add(end);\r\n }", "@Test\n\tpublic void testSetGetAnalysisResult() {\n\t\tArrayList<ArrayList<String>> risultatoAnalisi = \n\t\t\t\tnew ArrayList<ArrayList<String>>();\n\t\toutput.setAnalysisResult(risultatoAnalisi);\n\t\tboolean result = output.getAnalysisResult() != null &&\n\t\t\t\toutput.getAnalysisResult() == risultatoAnalisi;\n\t\tassertTrue(result);\n\t}", "private void writeAnalysisResults(Map<SillyBot, List<IntermediateResult>> analysisCallResults)\n\t\t\tthrows InterruptedException, ExecutionException {\n\t\tfor (SillyBot sillyBot : analysisCallResults.keySet()) {\n\t\t\tSystem.out.println(\"PRINT SILLY BOT ANALYZED RESULTS:\");\n\t\t\tfor (IntermediateResult botsAnalysisCall : analysisCallResults.get(sillyBot)) {\n\t\t\t\tProposal propsal;\n\t\t\t\tif (sillyBot instanceof PerformanceSillyBot) {\n\t\t\t\t\tSystem.out.println();\n\t\t\t\t\tpropsal = new PerformanceProposal(getResponseValue(botsAnalysisCall.analysisResult),\n\t\t\t\t\t\t\tbotsAnalysisCall.name);\n\t\t\t\t\tSystem.out.println(\"For Model \" + botsAnalysisCall.name + \" metric is \"\n\t\t\t\t\t\t\t+ getResponseValue(botsAnalysisCall.analysisResult));\n\t\t\t\t} else if (sillyBot instanceof ModifiabilitySillyBot) {\n\t\t\t\t\tpropsal = new ModifiabilityProposal(getResponseValue(botsAnalysisCall.analysisResult),\n\t\t\t\t\t\t\tbotsAnalysisCall.name);\n\t\t\t\t\tSystem.out.println(\"For Model \" + botsAnalysisCall.name + \" metric is \"\n\t\t\t\t\t\t\t+ getResponseValue(botsAnalysisCall.analysisResult));\n\t\t\t\t} else {\n\t\t\t\t\tthrow new IllegalArgumentException(\"Unknown type of Silly Bot.\");\n\t\t\t\t}\n\n\t\t\t\tsillyBot.insertInOrder(propsal);\n\t\t\t}\n\t\t}\n\t}", "@Test\n void fileWriter() {\n\n\n ArrayList<String> fileLines = Name_Sorter.fileRead(this.readFile, \"src/main/java/oop/assignment3/ex41/base/testFile-ex41\");\n Collections.sort(fileLines);\n this.writeFile = Name_Sorter.fileWriter(this.writeFile, fileLines, \"src/main/java/oop/assignment3/ex41/base/ex41-testOutputFile.txt\");\n boolean actualOutput = this.writeFile != null;\n Assertions.assertTrue(actualOutput);\n }", "public String getAnalysis()\n\t{\n\t\treturn m_analysis;\n\t}", "protected abstract void _analyze(Object input, Consumer<Analysis> collector);", "@Override\n\tpublic void addTestReport(ConverterTester tester) throws Exception {\n\t\t\n\t}", "void analysisCompleted();", "public void process(String analysisData) throws Exception;", "@Test(timeout = 4000)\n public void test047() throws Throwable {\n ClassWriter classWriter0 = new ClassWriter((-4015));\n byte[] byteArray0 = new byte[0];\n FileSystemHandling.appendDataToFile((EvoSuiteFile) null, byteArray0);\n MethodWriter methodWriter0 = new MethodWriter(classWriter0, 2, \"dVw2Z7M){e/Y(#j\", \"dVw2Z7M){e/Y(#j\", \"dVw2Z7M){e/Y(#j\", (String[]) null, false, true);\n ByteVector byteVector0 = new ByteVector(2);\n methodWriter0.visitFrame((-4015), 191, (Object[]) null, (-4058), (Object[]) null);\n }", "public Analysis(GraphAnalyzer analyzer) {\n\t\t_analyzer = analyzer;\n\n\t\t// Maybe we may want to implement the Observer pattern instead of this.\n\t\tgraph().addAnalysis(this);\n\t}", "@Test// to tell jUnit that method with @Test annotation has to be run. \n\tvoid testAdd() {\n\t\tSystem.out.println(\"Before assumption method: Add Method\");\n\t\tboolean isServerUp = false;\n\t\tassumeTrue(isServerUp,\"If this method ran without skipping, my assumption is right\"); //Eg: This is used in occasions like run only when server is up.\n\t\t\n\t\tint expected = 2;\n\t\tint actual = mathUtils.add(0, 2);\n\t\t//\t\tassertEquals(expected, actual);\n\t\t// can add a string message to log \n\t\tassertEquals(expected, actual,\"add method mathUtils\");\n\t}", "@Test(timeout = 4000)\n public void test012() throws Throwable {\n ClassWriter classWriter0 = new ClassWriter((-1983180370));\n FileSystemHandling.appendStringToFile((EvoSuiteFile) null, \"\");\n String[] stringArray0 = new String[0];\n classWriter0.visit(1, 1, \"InnerClasses\", \"\", \"EQIUR?\", stringArray0);\n classWriter0.newField(\"\", \"\", \"\\\"\");\n String[] stringArray1 = new String[4];\n stringArray1[0] = \"\\\"\";\n stringArray1[1] = \"char\";\n stringArray1[2] = \"boolean\";\n stringArray1[3] = \" ,G\";\n MethodWriter methodWriter0 = new MethodWriter(classWriter0, (-1983180370), \" ,G\", \"<T'RwU+)i.UKJX>\", \"\", stringArray1, true, true);\n methodWriter0.visitCode();\n }", "@Test(timeout = 4000)\n public void test001() throws Throwable {\n Label label0 = new Label();\n byte[] byteArray0 = new byte[8];\n byteArray0[0] = (byte)3;\n byteArray0[1] = (byte)70;\n byteArray0[2] = (byte) (-85);\n byteArray0[3] = (byte)108;\n byteArray0[4] = (byte) (-5);\n byteArray0[5] = (byte) (-1);\n byteArray0[6] = (byte)76;\n byteArray0[7] = (byte) (-1);\n FileSystemHandling.appendDataToFile((EvoSuiteFile) null, byteArray0);\n int[] intArray0 = new int[1];\n intArray0[0] = 243;\n MethodWriter.getNewOffset(intArray0, intArray0, label0);\n ClassWriter classWriter0 = new ClassWriter((-2473));\n MethodWriter methodWriter0 = classWriter0.lastMethod;\n assertNull(methodWriter0);\n }", "public interface IAnalysisListener {\r\n /**\r\n * Notification that analysis is starting.\r\n */\r\n void analysisStarting();\r\n\r\n /**\r\n * Notification that analysis has been completed.\r\n */\r\n void analysisCompleted();\r\n\r\n /**\r\n * Notification that analysis has been postponed until compilation errors are\r\n * removed.\r\n */\r\n void analysisPostponed();\r\n \r\n /**\r\n * Notification that analysis has been cancelled\r\n */\r\n void analysisCancelled();\r\n}", "public void startAnalysis() throws IOException {\n if (line.length() == 0)\n return;\n\n for (String item : breakDown()) {\n if (Condition.isKeyword(item)) {\n wordArray.addWord(item, Symbol.valueOf(item + \"sym\"));\n } else if (item.equals(Condition.Semicolon)) {\n wordArray.addWord(Condition.Semicolon, Symbol.semicolon);\n } else {\n int count = item.codePointCount(0, item.length());\n\n for (int i = 0; i < count; i++) {\n int[] point = {item.codePointAt(i)};\n String character = new String(point, 0, 1);\n\n if (Condition.isLetter(character)) {\n i = generateToken(count, i, item, character, \"Identifier\", Condition.toIdentifier());\n } else if (Condition.isDigit(character)) {\n i = generateToken(count, i, item, character, \"Number\", Condition.toNumber());\n } else if (Condition.isOperator(character)) {\n i = generateToken(count, i, item, character, \"Symbol\", Condition.toSymbol());\n } else if (Condition.isParentheses(character)) {\n wordArray.addWord(character, legalCharMap.get(character));\n } else {\n throw new IOException(\"Position \" + line.indexOf(character) +\n \" occur the unexpected char \\'\" + character + \"\\'.\");\n }\n }\n }\n }\n wordArray.addWord(\".\", Symbol.period);\n }", "@Test\n public void testAdd() {\n System.out.println(\"testing add\");\n Arithmetic arithmetic = new Arithmetic(); \n \n assertEquals(\"unexpected result of addition\", 8, arithmetic.add(3,5));\n assertEquals(\"unexpected result of addition\", 6, arithmetic.add(0,6));\n assertEquals(\"unexpected result of addition\", -14, arithmetic.add(0,-14));\n assertEquals(\"unexpected result of addition\", 0, arithmetic.add(-5,5));\n assertEquals(\"unexpected result of addition\", -6, arithmetic.add(-12,6));\n \n }", "@Test (dataProvider=\"testdata\")\r\n\r\n\r\n\r\n\t //public void testAdd(Integer exp, Inputs i) {\r\n\r\n\t public void testAdd(Integer exp, int a, int b) {\n\r\n\t assertEquals( exp, (Integer) calci.add(a,b));\r\n\r\n\t //fail(\"expected exceotion didn't occur\");\r\n\r\n\t //assertTrue(false);\r\n\r\n\t }", "@Test\n public void addTest() {\n double expected = 5.5;\n double actual = calculatorApp.add();\n Assert.assertThat(\"Addition function in CalculatorApp: Expected != Real\", actual, is(expected));\n }", "@Test\n\tpublic void testWriteToFile() {\n ArrayList<String> actualLines = new ArrayList<String>();\n\n\t\tactualLines.add(\"Course: Java\");\n\t\tactualLines.add(\"CourseID: 590\");\n\t\tactualLines.add(\"StudentName: Nikhil Kumar\");\n\t\t\n\t\t// Write to file\n\t\tmyFileWriter1.writeToFile(actualLines);\n\t\t\n\t\t// Read the written file to test its contents\n\t\tArrayList<String> expectedLines = readWrittenFile(\"output_test.txt\");\n\t\tassertEquals(expectedLines, actualLines);\n\t}", "public Results test(ITraceIterator trace, String database, IDataAccessObject dataAccessObject, IAlgorithmOutStream outputStream) throws TotalADSGeneralException, TotalADSDBMSException, TotalADSReaderException;", "private void createTotalTestMethod(BufferedWriter writer)\r\n\t\t\tthrows IOException {\r\n\t\tString parent = \"<label style='position: inherit;top: 57px;'>\";\r\n\t\tString content = \"<span style='color: #000000;font-weight: bold;padding-left: 8px;font-family: Roboto, sans-serif;'>Total TestMethod</span>\";\r\n\t\tString total = \"<span style='margin-left: 83px;color: #000000;font-weight: bold;font-family: Roboto, sans-serif;'>\"\r\n\t\t\t\t+ data.getNumberOfTest() + \"</span></label>\";\r\n\t\twriter.write(parent + content + total);\r\n\t}", "DocumentAnalysisResult analyze(String saplDefinition);", "@Test\n public void testAnalyse() {\n System.out.println(\"analyse simple case\");\n\n // Setup test objects\n Environment env = new Environment(new RigidBody(0, 0, 500, 500));\n Collection<Robot> robots = new LinkedList<Robot>();\n Collection<Cup> things = new LinkedList<Cup>();\n\n things.add(new Cup(10, 40, false));\n\n // Make a robot to hold the sensor\n SensorTestingRobot robot = new SensorTestingRobot(0, new XPoint(10, 10), 0);\n\n // Set the parameters of the sensor\n double offsetAngle = 0;\n double max = 500;\n\n // Make the sensor\n CupSensor instance = new CupSensor(offsetAngle, max);\n\n instance.setObject(robot);\n\n // Look for cup\n instance.analyse(env, robots, things);\n assertEquals(true, instance.getOutput());\n }", "private void addSampleData() {\r\n }", "public Analysis(String alias) {\n this(alias, ANALYSIS);\n }", "@Test(timeout = 4000)\n public void test023() throws Throwable {\n ClassWriter classWriter0 = new ClassWriter((-1983180370));\n ClassWriter classWriter1 = new ClassWriter(2);\n FileSystemHandling.appendStringToFile((EvoSuiteFile) null, \"/||OC]6QKvi*G\");\n classWriter0.visitInnerClass(\"I)3(E\\\"fl>%a;-7\", \"8oDTx&g*ZVx?eE@.\", \"/||OC]6QKvi*G\", 1);\n ByteVector byteVector0 = new ByteVector(1);\n String[] stringArray0 = new String[0];\n MethodWriter methodWriter0 = new MethodWriter(classWriter0, 1499, \"long\", \"Code\", \"8oDTx&g*ZVx?eE@.\", stringArray0, false, false);\n methodWriter0.put(byteVector0);\n }", "@Test\n public void testGetAnalyzedData() {\n System.out.println(\"getAnalyzedData\");\n \n }", "@Test\n public void test55() throws Throwable {\n CategoryAxis categoryAxis0 = new CategoryAxis(\"\");\n CombinedDomainCategoryPlot combinedDomainCategoryPlot0 = new CombinedDomainCategoryPlot(categoryAxis0);\n DefaultCategoryItemRenderer defaultCategoryItemRenderer0 = new DefaultCategoryItemRenderer();\n boolean boolean0 = categoryAxis0.equals(defaultCategoryItemRenderer0);\n AxisLocation axisLocation0 = AxisLocation.BOTTOM_OR_LEFT;\n combinedDomainCategoryPlot0.setDomainAxisLocation(axisLocation0, false);\n combinedDomainCategoryPlot0.setDomainAxisLocation(0, axisLocation0, false);\n DefaultPolarItemRenderer defaultPolarItemRenderer0 = new DefaultPolarItemRenderer();\n defaultPolarItemRenderer0.setAutoPopulateSeriesPaint(true);\n categoryAxis0.setCategoryLabelPositionOffset(1378);\n BasicStroke basicStroke0 = (BasicStroke)defaultPolarItemRenderer0.getItemStroke(0, 0);\n MockPrintStream mockPrintStream0 = null;\n try {\n mockPrintStream0 = new MockPrintStream(\"\", \"\");\n } catch(FileNotFoundException e) {\n //\n // no message in exception (getMessage() returned null)\n //\n assertThrownBy(\"org.evosuite.runtime.mock.java.io.MockFileOutputStream\", e);\n }\n }", "@Test\n public void testCalculate() throws Exception {\n Writer writer = new Writer();\n File file = new File(\"/home/spec/HomeWork/semestr2/homework5/hw5_task1/src/arithmeticTree/input.txt\");\n writer.writeTextToFile(\"(* (+ (* (+ 10 15) 2) 50) (- (+ 5 5) (/ 8 4)))\");\n ArithmeticTree tree = new ArithmeticTree(file);\n assertEquals(800, tree.calculate());\n writer.writeTextToFile(\"(* (+ 1 1) 2)\");\n tree = new ArithmeticTree(file);\n assertEquals(4, tree.calculate());\n writer.writeTextToFile(\"(+ (/ 100 20) (/ 100500 (/ 400 4))\");\n tree = new ArithmeticTree(file);\n assertEquals(1010, tree.calculate());\n }", "@Test(timeout = 4000)\n public void test003() throws Throwable {\n ClassWriter classWriter0 = new ClassWriter(0);\n String[] stringArray0 = new String[8];\n stringArray0[1] = \"\";\n stringArray0[2] = \"yU7u<DG%2l[\";\n byte[] byteArray0 = new byte[3];\n byteArray0[1] = (byte)95;\n byteArray0[2] = (byte)95;\n FileSystemHandling.appendDataToFile((EvoSuiteFile) null, byteArray0);\n int[] intArray0 = new int[1];\n intArray0[0] = (int) (byte) (-115);\n int int0 = MethodWriter.getNewOffset(intArray0, intArray0, 1, (-2905));\n assertEquals((-2791), int0);\n }", "@Test(timeout = 4000)\n public void test035() throws Throwable {\n FileSystemHandling.appendStringToFile((EvoSuiteFile) null, \"oc[MfnZM[~MHOK iO\");\n ClassWriter classWriter0 = new ClassWriter((-2450));\n String[] stringArray0 = new String[0];\n MethodWriter methodWriter0 = new MethodWriter(classWriter0, 2, \"H\", \"H\", \"Hai4?;|GlMP=+q\", stringArray0, false, false);\n String[] stringArray1 = new String[2];\n stringArray1[0] = \"oc[MfnZM[~MHOK iO\";\n stringArray1[1] = \"Hai4?;|GlMP=+q\";\n MethodWriter methodWriter1 = new MethodWriter(classWriter0, 1, \"LocalVariableTypeTable\", \"StackMap\", \"StackMap\", stringArray1, false, false);\n methodWriter0.visitIincInsn(1243, 2);\n assertNotSame(methodWriter0, methodWriter1);\n }", "@Test\n\tpublic void addTaskOutput(){\n\t}", "private void addAnalysisTimestamp()\r\n throws XMLStreamException\r\n {\r\n SimpleStartElement start;\r\n SimpleEndElement end;\r\n\r\n addNewline();\r\n\r\n start = new SimpleStartElement(\"analysis_timestamp\");\r\n start.addAttribute(\"analysis\", mimicXpress ? \"xpress\" : \"q3\");\r\n start.addAttribute(\"time\", now);\r\n start.addAttribute(\"id\", \"1\");\r\n add(start);\r\n\r\n addNewline();\r\n\r\n if (mimicXpress)\r\n {\r\n start = new SimpleStartElement(\"xpressratio_timestamp\");\r\n start.addAttribute(\"xpress_light\", \"0\");\r\n add(start);\r\n\r\n end = new SimpleEndElement(\"xpressratio_timestamp\");\r\n add(end);\r\n\r\n addNewline();\r\n }\r\n\r\n end = new SimpleEndElement(\"analysis_timestamp\");\r\n add(end);\r\n }", "public void testAppendDataInFile() throws IOException {\n\t\tfinal CachedParserDocument pdoc = new CachedParserDocument(this.tempFilemanager,0);\n\t\tassertTrue(pdoc.inMemory());\n\t\tassertEquals(0, pdoc.length());\n\t\tassertFalse(this.outputFile.exists());\n\t\t\n\t\t// copying data\n\t\tthis.appendData(TESTFILE, pdoc);\n\t\t\n\t\t// some tests\n\t\tassertFalse(pdoc.inMemory());\n\t\tassertEquals(this.fileSize, pdoc.length());\n\t\tassertTrue(this.outputFile.exists());\n\t\tassertEquals(TESTFILE, pdoc.getTextAsReader());\n\t\tassertEquals(TESTFILE, pdoc.getTextFile());\n\t\tassertFalse(pdoc.inMemory());\n\t}", "@Override\n\tpublic String getAnalysisName() {\n\t\treturn analysisName;\n\t}", "@Override\r\n\tpublic void doWorkFlowAnalysis() {\n\t\t\r\n\t}", "private void createTotalTest(BufferedWriter writer) throws IOException {\r\n\t\t// Creates the layout\r\n\t\tString layout = \"<div style ='height: 100px;width: inherit;'>\";\r\n\t\t// Creates the child div\r\n\t\tString displayTotalTestLayout = \"<div style='width: 260px;background-color: #FFFFFF;box-shadow: 1px 1px 1px #888888;height: 85px;position: absolute;top: 67px;'>\";\r\n\r\n\t\t// Creates Total Test Tag count\r\n\t\twriter.write(layout);\r\n\t\twriter.write(displayTotalTestLayout);\r\n\t\tcreateTotalTestCase(writer);\r\n\t\tcreateTotalTestMethod(writer);\r\n\t\twriter.write(\"</div></div>\");\r\n\t}", "@Test\n public void testWrite_3args() {\n String expResult = \"@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . \" + ls\n + \"@prefix lemon: <http://lemon-model.net/lemon#> . \" + ls\n + \"\" + ls\n + \"<file:test#Cat> lemon:sense [ a lemon:LexicalSense ;\" + ls\n + \" lemon:reference <http://dbpedia.org/resource/Cat> ] ;\" + ls\n + \" lemon:canonicalForm [ lemon:writtenRep \\\"cat\\\"@en ;\" + ls\n + \" a lemon:Form ] ;\" + ls\n + \" a lemon:LexicalEntry .\" + ls\n + \"\" + ls\n + \"<file:test#lexicon> lemon:entry <file:test#Cat> ;\" + ls\n + \" a lemon:Lexicon .\";\n //System.out.println(\"write\");\n LemonSerializerImpl instance = new LemonSerializerImpl(null);\n LemonModel lm = makeModel(instance);\n Writer dt = new StringWriter();\n boolean xml = false;\n instance.write(lm, dt, xml);\n //System.out.println(dt.toString());\n }", "@Test\n\tvoid test() throws IOException\n\t{\n\t\t\tFile f1=new File(\"testcase1.txt\");\n\t\t\tf1.createNewFile();\n\t\t\tFileWriter fileWriter;\n\t\t\tfileWriter = new FileWriter(f1.getPath());\n\t\t\tString str1=\"I am a test string and number one two three four five six seven eight nine ten eleven twelve.\";\n\t\t\tfileWriter.write(str1);\n\t\t fileWriter.close();\n\n\t\t /**\n\t\t * TO-DO\n\t\t * call formatter to get actual.txt\n\t\t */\n\t\t \n\t\t File f2=new File(\"expected1.txt\");\n\t\t\tf2.createNewFile();\n\t\t\tFileWriter fileWriter2 = new FileWriter(f2.getPath());\n\t\t\tString str2=\"I am a test string and number one two three four five six seven eight nine ten\\neleven twelve.\";\n\t\t\tfileWriter2.write(str2);\n\t\t fileWriter2.close();\n\t\t \t\t \n\t\t\tassertFalse(equalFile(\"testcase1.txt\",\"expected1.txt\"));\t\n\t}", "void analysisStarting();", "@Test(timeout = 4000)\n public void test005() throws Throwable {\n Label label0 = new Label();\n FileSystemHandling.appendStringToFile((EvoSuiteFile) null, \"oc[MfnZM[~MHOK iO\");\n ClassWriter classWriter0 = new ClassWriter((-2450));\n String[] stringArray0 = new String[0];\n MethodWriter methodWriter0 = new MethodWriter(classWriter0, (-2450), \"H\", \"/i%NB\", \"LocalVariableTable\", stringArray0, false, false);\n methodWriter0.exceptionCount = 1;\n methodWriter0.getSize();\n int int0 = methodWriter0.getSize();\n assertEquals(38, int0);\n }", "@Test\r\n\tpublic void testRuleSets2() throws Exception{\r\n\t\t\r\n\t\tAssert.assertEquals(0L, testAdminCon.size());\r\n\t\ttestAdminCon.add(micah, lname, micahlname, dirgraph1);\r\n\t\ttestAdminCon.add(micah, fname, micahfname, dirgraph1);\r\n\t\ttestAdminCon.add(micah, developPrototypeOf, semantics, dirgraph1);\r\n\t\ttestAdminCon.add(micah, type, sEngineer, dirgraph1);\r\n\t\ttestAdminCon.add(micah, worksFor, ml, dirgraph1);\r\n\t\t\r\n\t\ttestAdminCon.add(john, fname, johnfname,dirgraph);\r\n\t\ttestAdminCon.add(john, lname, johnlname,dirgraph);\r\n\t\ttestAdminCon.add(john, writeFuncSpecOf, inference, dirgraph);\r\n\t\ttestAdminCon.add(john, type, lEngineer, dirgraph);\r\n\t\ttestAdminCon.add(john, worksFor, ml, dirgraph);\r\n\t\t\r\n\t\ttestAdminCon.add(writeFuncSpecOf, subProperty, design, dirgraph1);\r\n\t\ttestAdminCon.add(developPrototypeOf, subProperty, design, dirgraph1);\r\n\t\ttestAdminCon.add(design, subProperty, develop, dirgraph1);\r\n\t\t\r\n\t\ttestAdminCon.add(lEngineer, subClass, engineer, dirgraph1);\r\n\t\ttestAdminCon.add(sEngineer, subClass, engineer, dirgraph1);\r\n\t\ttestAdminCon.add(engineer, subClass, employee, dirgraph1);\r\n\t\t\r\n\t\tString query = \"select (count (?s) as ?totalcount) where {?s ?p ?o .} \";\r\n\t\tTupleQuery tupleQuery = testAdminCon.prepareTupleQuery(QueryLanguage.SPARQL, query);\r\n\t\t((MarkLogicQuery) tupleQuery).setRulesets(SPARQLRuleset.RDFS_PLUS_FULL);\r\n\t\tTupleQueryResult result\t= tupleQuery.evaluate();\r\n\t\t\r\n\t\ttry {\r\n\t\t\tassertThat(result, is(notNullValue()));\r\n\t\t\tassertThat(result.hasNext(), is(equalTo(true)));\r\n\t\t\twhile (result.hasNext()) {\r\n\t\t\t\tBindingSet solution = result.next();\r\n\t\t\t\tassertThat(solution.hasBinding(\"totalcount\"), is(equalTo(true)));\r\n\t\t\t\tValue count = solution.getValue(\"totalcount\");\r\n\t\t\t\tAssert.assertEquals(374, Integer.parseInt(count.stringValue()));\r\n\t\t\t}\r\n\t\t}\r\n\t\tfinally {\r\n\t\t\tresult.close();\r\n\t\t}\r\n\t\r\n\t\tRepositoryResult<Statement> resultg = testAdminCon.getStatements(null, null, null, true, dirgraph, dirgraph1);\r\n\t\t\r\n\t\tassertNotNull(\"Iterator should not be null\", resultg);\r\n\t\tassertTrue(\"Iterator should not be empty\", resultg.hasNext());\r\n\t\t\t\t\r\n\t\ttupleQuery = testAdminCon.prepareTupleQuery(QueryLanguage.SPARQL, query);\r\n\t\t((MarkLogicQuery) tupleQuery).setRulesets(SPARQLRuleset.EQUIVALENT_CLASS);\r\n\t\tresult = tupleQuery.evaluate();\r\n\t\t\r\n\t\ttry {\r\n\t\t\tassertThat(result, is(notNullValue()));\r\n\t\t\tassertThat(result.hasNext(), is(equalTo(true)));\r\n\t\t\twhile (result.hasNext()) {\r\n\t\t\t\tBindingSet solution = result.next();\r\n\t\t\t\tassertThat(solution.hasBinding(\"totalcount\"), is(equalTo(true)));\r\n\t\t\t\tValue count = solution.getValue(\"totalcount\");\r\n\t\t\t\tAssert.assertEquals(18, Integer.parseInt(count.stringValue()));\r\n\t\t\t}\r\n\t\t}\r\n\t\tfinally {\r\n\t\t\tresult.close();\r\n\t\t}\r\n\t\t\r\n\t\ttupleQuery = testAdminCon.prepareTupleQuery(QueryLanguage.SPARQL, query);\r\n\t\t((MarkLogicQuery) tupleQuery).setRulesets(SPARQLRuleset.RDFS,SPARQLRuleset.INVERSE_OF);\r\n\t\tresult = tupleQuery.evaluate();\r\n\t\t\r\n\t\ttry {\r\n\t\t\tassertThat(result, is(notNullValue()));\r\n\t\t\tassertThat(result.hasNext(), is(equalTo(true)));\r\n\t\t\twhile (result.hasNext()) {\r\n\t\t\t\tBindingSet solution = result.next();\r\n\t\t\t\tassertThat(solution.hasBinding(\"totalcount\"), is(equalTo(true)));\r\n\t\t\t\tValue count = solution.getValue(\"totalcount\");\r\n\t\t\t\tAssert.assertEquals(86, Integer.parseInt(count.stringValue()));\r\n\t\t\t}\r\n\t\t}\r\n\t\tfinally {\r\n\t\t\tresult.close();\r\n\t\t}\r\n\t\t\r\n\t\ttupleQuery = testAdminCon.prepareTupleQuery(QueryLanguage.SPARQL, query);\r\n\t\t((MarkLogicQuery) tupleQuery).setRulesets(null,SPARQLRuleset.INVERSE_OF);\r\n\t\tresult = tupleQuery.evaluate();\r\n\t\t\r\n\t\ttry {\r\n\t\t\tassertThat(result, is(notNullValue()));\r\n\t\t\tassertThat(result.hasNext(), is(equalTo(true)));\r\n\t\t\twhile (result.hasNext()) {\r\n\t\t\t\tBindingSet solution = result.next();\r\n\t\t\t\tassertThat(solution.hasBinding(\"totalcount\"), is(equalTo(true)));\r\n\t\t\t\tValue count = solution.getValue(\"totalcount\");\r\n\t\t\t\tAssert.assertEquals(18, Integer.parseInt(count.stringValue()));\r\n\t\t\t}\r\n\t\t}\r\n\t\tfinally {\r\n\t\t\tresult.close();\r\n\t\t}\r\n\t\t\r\n\t\ttupleQuery = testAdminCon.prepareTupleQuery(QueryLanguage.SPARQL, query);\r\n\t\t((MarkLogicQuery) tupleQuery).setRulesets((SPARQLRuleset)null, null);\r\n\t\ttupleQuery.setIncludeInferred(false);\r\n\t\tresult = tupleQuery.evaluate();\r\n\t\t\r\n\t\ttry {\r\n\t\t\tassertThat(result, is(notNullValue()));\r\n\t\t\tassertThat(result.hasNext(), is(equalTo(true)));\r\n\t\t\twhile (result.hasNext()) {\r\n\t\t\t\tBindingSet solution = result.next();\r\n\t\t\t\tassertThat(solution.hasBinding(\"totalcount\"), is(equalTo(true)));\r\n\t\t\t\tValue count = solution.getValue(\"totalcount\");\r\n\t\t\t\tAssert.assertEquals(16, Integer.parseInt(count.stringValue()));\r\n\t\t\t}\r\n\t\t}\r\n\t\tfinally {\r\n\t\t\tresult.close();\r\n\t\t}\r\n\t}", "public void testAddAction() {\n AccuracyMockAddAction addAction = new AccuracyMockAddAction(\n modelElement, classToolUtil, manager, namespace);\n\n assertEquals(\"Should return ModelElement instance.\", modelElement,\n addAction.getModelElement());\n assertEquals(\"Should return ClassToolUtil instance.\", classToolUtil,\n addAction.getClassToolUtil());\n }", "ch.crif_online.www.webservices.crifsoapservice.v1_00.ScoreAnalysis addNewScoreAnalysis();", "@Test\n public void testPrint() throws Exception {\n Writer writer = new Writer();\n File file = new File(\"/home/spec/HomeWork/semestr2/homework5/hw5_task1/src/arithmeticTree/input.txt\");\n writer.writeTextToFile(\"(* (+ (* (+ 10 15) 2) 50) (- (+ 5 5) (/ 8 4)))\");\n ArithmeticTree tree = new ArithmeticTree(file);\n tree.print();\n System.out.println();\n writer.writeTextToFile(\"(* (+ 1 1) 2)\");\n tree = new ArithmeticTree(file);\n tree.print();\n System.out.println();\n writer.writeTextToFile(\"(+ (/ 100 20) (/ 100500 (/ 400 4))\");\n tree = new ArithmeticTree(file);\n tree.print();\n System.out.println();\n }", "public Analyse createAnalysis(Sample samplesCurrent, Modeleanalyse idmodeleanalyse, Methode idmethod, BigInteger limsidanalysis ) throws AnalysisWithoutSamplesError {\n if(null == samplesCurrent){\r\n throw new AnalysisWithoutSamplesError(\"Cannot create a analysis with a null Sample \");\r\n }\r\n Analyse a =new Analyse();\r\n //System.out.println(\" dans Analyse Utilitie createAnalyse a (null OK) \"+a.getSample());\r\n \r\n a=setInfoFromSample(a , samplesCurrent);\r\n System.out.println(\" dans Analyse Utilitie createAnalyse a \"+a.getSample());\r\n a=setInfoFromModeleAnalysis(a, idmodeleanalyse);\r\n System.out.println(\" dans Analyse Utilitie createAnalyse a \"+a.getModeleanalyse());\r\n a=setInfoFromMethode(a, idmethod);\r\n System.out.println(\" dans Analyse Utilitie createAnalyse a \"+a.getMethode());\r\n \r\n System.out.println(\" avant retour \"+a);\r\n a.setLimsidanalyse(limsidanalysis);\r\n return a;\r\n }", "private void analysisText(){\n\n FileOutput fout = null;\n if(this.fileNumberingSet){\n fout = new FileOutput(this.outputFilename, 'n');\n }\n else{\n fout = new FileOutput(this.outputFilename);\n }\n\n // perform PCA if not already performed\n if(!pcaDone)this.pca();\n if(!this.monteCarloDone)this.monteCarlo();\n\n // output title\n fout.println(\"PRINCIPAL COMPONENT ANALYSIS\");\n fout.println(\"Program: PCA - Analysis Output\");\n for(int i=0; i<this.titleLines; i++)fout.println(title[i]);\n Date d = new Date();\n String day = DateFormat.getDateInstance().format(d);\n String tim = DateFormat.getTimeInstance().format(d);\n fout.println(\"Program executed at \" + tim + \" on \" + day);\n fout.println();\n if(this.covRhoOption){\n fout.println(\"Covariance matrix used\");\n }\n else{\n fout.println(\"Correlation matrix used\");\n }\n fout.println();\n\n // output eigenvalue table\n // field width\n int field1 = 10;\n int field2 = 12;\n int field3 = 2;\n\n fout.println(\"ALL EIGENVALUES\");\n\n fout.print(\"Component \", field1);\n fout.print(\"Unordered \", field1);\n fout.print(\"Eigenvalue \", field2);\n fout.print(\"Proportion \", field2);\n fout.print(\"Cumulative \", field2);\n fout.println(\"Difference \");\n\n fout.print(\" \", field1);\n fout.print(\"index\", field1);\n fout.print(\" \", field2);\n fout.print(\"as % \", field2);\n fout.print(\"percentage \", field2);\n fout.println(\" \");\n\n\n\n for(int i=0; i<this.nItems; i++){\n fout.print(i+1, field1);\n fout.print((this.eigenValueIndices[i]+1), field1);\n fout.print(Fmath.truncate(this.orderedEigenValues[i], this.trunc), field2);\n fout.print(Fmath.truncate(this.proportionPercentage[i], this.trunc), field2);\n fout.print(Fmath.truncate(this.cumulativePercentage[i], this.trunc), field2);\n if(i<this.nItems-1){\n fout.print(Fmath.truncate((this.orderedEigenValues[i] - this.orderedEigenValues[i+1]), this.trunc), field2);\n }\n else{\n fout.print(\" \", field2);\n }\n fout.print(\" \", field3);\n\n fout.println();\n }\n fout.println();\n\n\n // Extracted components\n int nMax = this.greaterThanOneLimit;\n if(nMax<this.meanCrossover)nMax=this.meanCrossover;\n if(nMax<this.percentileCrossover)nMax=this.percentileCrossover;\n fout.println(\"EXTRACTED EIGENVALUES\");\n fout.print(\" \", field1);\n fout.print(\"Greater than unity\", 3*field2 + field3);\n fout.print(\"Greater than Monte Carlo Mean \", 3*field2 + field3);\n fout.println(\"Greater than Monte Carlo Percentile\");\n\n fout.print(\"Component \", field1);\n fout.print(\"Eigenvalue \", field2);\n fout.print(\"Proportion \", field2);\n fout.print(\"Cumulative \", field2);\n fout.print(\" \", field3);\n\n fout.print(\"Eigenvalue \", field2);\n fout.print(\"Proportion \", field2);\n fout.print(\"Cumulative \", field2);\n fout.print(\" \", field3);\n\n fout.print(\"Eigenvalue \", field2);\n fout.print(\"Proportion \", field2);\n fout.print(\"Cumulative \", field2);\n fout.println(\" \");\n\n fout.print(\" \", field1);\n fout.print(\" \", field2);\n fout.print(\"as % \", field2);\n fout.print(\"percentage \", field2);\n fout.print(\" \", field3);\n\n fout.print(\" \", field2);\n fout.print(\"as % \", field2);\n fout.print(\"percentage \", field2);\n fout.print(\" \", field3);\n\n fout.print(\" \", field2);\n fout.print(\"as % \", field2);\n fout.print(\"percentage \", field2);\n fout.println(\" \");\n\n int ii=0;\n while(ii<nMax){\n fout.print(ii+1, field1);\n\n if(ii<this.greaterThanOneLimit){\n fout.print(Fmath.truncate(this.orderedEigenValues[ii], this.trunc), field2);\n fout.print(Fmath.truncate(this.proportionPercentage[ii], this.trunc), field2);\n fout.print(Fmath.truncate(this.cumulativePercentage[ii], this.trunc), (field2+field3));\n }\n\n if(ii<this.meanCrossover){\n fout.print(Fmath.truncate(this.orderedEigenValues[ii], this.trunc), field2);\n fout.print(Fmath.truncate(this.proportionPercentage[ii], this.trunc), field2);\n fout.print(Fmath.truncate(this.cumulativePercentage[ii], this.trunc), (field2+field3));\n }\n\n if(ii<this.percentileCrossover){\n fout.print(Fmath.truncate(this.orderedEigenValues[ii], this.trunc), field2);\n fout.print(Fmath.truncate(this.proportionPercentage[ii], this.trunc), field2);\n fout.print(Fmath.truncate(this.cumulativePercentage[ii], this.trunc));\n }\n fout.println();\n ii++;\n }\n fout.println();\n\n\n fout.println(\"PARALLEL ANALYSIS\");\n fout.println(\"Number of simulations = \" + this.nMonteCarlo);\n if(this.gaussianDeviates){\n fout.println(\"Gaussian random deviates used\");\n }\n else{\n fout.println(\"Uniform random deviates used\");\n }\n fout.println(\"Percentile value used = \" + this.percentile + \" %\");\n\n fout.println();\n fout.print(\"Component \", field1);\n fout.print(\"Data \", field2);\n fout.print(\"Proportion \", field2);\n fout.print(\"Cumulative \", field2);\n fout.print(\" \", field3);\n fout.print(\"Data \", field2);\n fout.print(\"Monte Carlo \", field2);\n fout.print(\"Monte Carlo \", field2);\n fout.println(\"Monte Carlo \");\n\n fout.print(\" \", field1);\n fout.print(\"Eigenvalue \", field2);\n fout.print(\"as % \", field2);\n fout.print(\"percentage \", field2);\n fout.print(\" \", field3);\n fout.print(\"Eigenvalue \", field2);\n fout.print(\"Eigenvalue \", field2);\n fout.print(\"Eigenvalue \", field2);\n fout.println(\"Eigenvalue \");\n\n fout.print(\" \", field1);\n fout.print(\" \", field2);\n fout.print(\" \", field2);\n fout.print(\" \", field2);\n fout.print(\" \", field3);\n fout.print(\" \", field2);\n fout.print(\"Percentile \", field2);\n fout.print(\"Mean \", field2);\n fout.println(\"Standard Deviation \");\n\n for(int i=0; i<this.nItems; i++){\n fout.print(i+1, field1);\n fout.print(Fmath.truncate(this.orderedEigenValues[i], this.trunc), field2);\n fout.print(Fmath.truncate(this.proportionPercentage[i], this.trunc), field2);\n fout.print(Fmath.truncate(this.cumulativePercentage[i], this.trunc), field2);\n fout.print(\" \", field3);\n fout.print(Fmath.truncate(this.orderedEigenValues[i], this.trunc), field2);\n fout.print(Fmath.truncate(this.randomEigenValuesPercentiles[i], this.trunc), field2);\n fout.print(Fmath.truncate(this.randomEigenValuesMeans[i], this.trunc), field2);\n fout.println(Fmath.truncate(this.randomEigenValuesSDs[i], this.trunc));\n }\n fout.println();\n\n // Correlation Matrix\n fout.println(\"CORRELATION MATRIX\");\n fout.println(\"Original component indices in parenthesis\");\n fout.println();\n fout.print(\" \", field1);\n fout.print(\"component\", field1);\n for(int i=0; i<this.nItems; i++)fout.print((this.eigenValueIndices[i]+1) + \" (\" + (i+1) + \")\", field2);\n fout.println();\n fout.println(\"component\");\n for(int i=0; i<this.nItems; i++){\n fout.print((this.eigenValueIndices[i]+1) + \" (\" + (i+1) + \")\", 2*field1);\n for(int j=0; j<this.nItems; j++)fout.print(Fmath.truncate(this.correlationMatrix.getElement(j,i), this.trunc), field2);\n fout.println();\n }\n fout.println();\n\n // Covariance Matrix\n fout.println(\"COVARIANCE MATRIX\");\n fout.println(\"Original component indices in parenthesis\");\n fout.println();\n fout.print(\" \", field1);\n fout.print(\"component\", field1);\n for(int i=0; i<this.nItems; i++)fout.print((this.eigenValueIndices[i]+1) + \" (\" + (i+1) + \")\", field2);\n fout.println();\n fout.println(\"component\");\n for(int i=0; i<this.nItems; i++){\n fout.print((this.eigenValueIndices[i]+1) + \" (\" + (i+1) + \")\", 2*field1);\n for(int j=0; j<this.nItems; j++)fout.print(Fmath.truncate(this.covarianceMatrix.getElement(j,i), this.trunc), field2);\n fout.println();\n }\n\n fout.println();\n\n // Eigenvectors\n fout.println(\"EIGENVECTORS\");\n fout.println(\"Original component indices in parenthesis\");\n fout.println(\"Vector corresponding to an ordered eigenvalues in each row\");\n fout.println();\n fout.print(\" \", field1);\n fout.print(\"component\", field1);\n for(int i=0; i<this.nItems; i++)fout.print((this.eigenValueIndices[i]+1) + \" (\" + (i+1) + \")\", field2);\n fout.println();\n fout.println(\"component\");\n for(int i=0; i<this.nItems; i++){\n fout.print((i+1) + \" (\" + (this.eigenValueIndices[i]+1) + \")\", 2*field1);\n for(int j=0; j<this.nItems; j++)fout.print(Fmath.truncate(this.orderedEigenVectorsAsRows[i][j], this.trunc), field2);\n fout.println();\n }\n fout.println();\n\n // Loading factors\n fout.println(\"LOADING FACTORS\");\n fout.println(\"Original indices in parenthesis\");\n fout.println(\"Loading factors corresponding to an ordered eigenvalues in each row\");\n fout.println();\n fout.print(\" \", field1);\n fout.print(\"component\", field1);\n for(int i=0; i<this.nItems; i++)fout.print((this.eigenValueIndices[i]+1) + \" (\" + (i+1) + \")\", field2);\n fout.print(\" \", field1);\n fout.print(\"Eigenvalue\", field2);\n fout.print(\"Proportion\", field2);\n fout.println(\"Cumulative %\");\n fout.println(\"factor\");\n for(int i=0; i<this.nItems; i++){\n fout.print((i+1) + \" (\" + (this.eigenValueIndices[i]+1) + \")\", 2*field1);\n for(int j=0; j<this.nItems; j++)fout.print(Fmath.truncate(this.loadingFactorsAsRows[i][j], this.trunc), field2);\n fout.print(\" \", field1);\n fout.print(Fmath.truncate(this.orderedEigenValues[i], this.trunc), field2);\n fout.print(Fmath.truncate(proportionPercentage[i], this.trunc), field2);\n fout.println(Fmath.truncate(cumulativePercentage[i], this.trunc));\n }\n fout.println();\n\n // Rotated loading factors\n fout.println(\"ROTATED LOADING FACTORS\");\n if(this.varimaxOption){\n fout.println(\"NORMAL VARIMAX\");\n }\n else{\n fout.println(\"RAW VARIMAX\");\n }\n\n String message = \"The ordered eigenvalues with Monte Carlo means and percentiles in parenthesis\";\n message += \"\\n (Total number of eigenvalues = \" + this.nItems + \")\";\n int nDisplay = this.nItems;\n Dimension screenSize = Toolkit.getDefaultToolkit().getScreenSize();\n int screenHeight = screenSize.height;\n int nDisplayLimit = 20*screenHeight/800;\n if(nDisplay>nDisplay)nDisplay = nDisplayLimit;\n for(int i=0; i<nDisplay; i++){\n message += \"\\n \" + Fmath.truncate(this.orderedEigenValues[i], 4) + \" (\" + Fmath.truncate(this.randomEigenValuesMeans[i], 4) + \" \" + Fmath.truncate(this.randomEigenValuesPercentiles[i], 4) + \")\";\n }\n if(nDisplay<this.nItems)message += \"\\n . . . \";\n message += \"\\nEnter number of eigenvalues to be extracted\";\n int nExtracted = this.greaterThanOneLimit;\n nExtracted = Db.readInt(message, nExtracted);\n this.varimaxRotation(nExtracted);\n\n fout.println(\"Varimax rotation for \" + nExtracted + \" extracted factors\");\n fout.println(\"Rotated loading factors and eigenvalues scaled to ensure total 'rotated variance' matches unrotated variance for the extracted factors\");\n fout.println(\"Original indices in parenthesis\");\n fout.println();\n fout.print(\" \", field1);\n fout.print(\"component\", field1);\n for(int i=0; i<this.nItems; i++)fout.print((this.rotatedIndices[i]+1) + \" (\" + (i+1) + \")\", field2);\n fout.print(\" \", field1);\n fout.print(\"Eigenvalue\", field2);\n fout.print(\"Proportion\", field2);\n fout.println(\"Cumulative %\");\n fout.println(\"factor\");\n\n for(int i=0; i<nExtracted; i++){\n fout.print((i+1) + \" (\" + (rotatedIndices[i]+1) + \")\", 2*field1);\n for(int j=0; j<this.nItems; j++)fout.print(Fmath.truncate(this.rotatedLoadingFactorsAsRows[i][j], this.trunc), field2);\n fout.print(\" \", field1);\n fout.print(Fmath.truncate(rotatedEigenValues[i], this.trunc), field2);\n fout.print(Fmath.truncate(rotatedProportionPercentage[i], this.trunc), field2);\n fout.println(Fmath.truncate(rotatedCumulativePercentage[i], this.trunc));\n }\n fout.println();\n\n fout.println(\"DATA USED\");\n fout.println(\"Number of items = \" + this.nItems);\n fout.println(\"Number of persons = \" + this.nPersons);\n\n\n if(this.originalDataType==0){\n fout.printtab(\"Item\");\n for(int i=0; i<this.nPersons; i++){\n fout.printtab(i+1);\n }\n fout.println();\n for(int i=0; i<this.nItems; i++){\n fout.printtab(this.itemNames[i]);\n for(int j=0; j<this.nPersons; j++){\n fout.printtab(Fmath.truncate(this.scores0[i][j], this.trunc));\n }\n fout.println();\n }\n }\n else{\n fout.printtab(\"Person\");\n for(int i=0; i<this.nItems; i++){\n fout.printtab(this.itemNames[i]);\n }\n fout.println();\n for(int i=0; i<this.nPersons; i++){\n fout.printtab(i+1);\n for(int j=0; j<this.nItems; j++){\n fout.printtab(Fmath.truncate(this.scores1[i][j], this.trunc));\n }\n fout.println();\n }\n }\n\n fout.close();\n }", "@Test public void testWithExternalDataSet() throws IOException\n {\n final String homeDir = System.getProperty(\"user.home\");\n assumeNotNull(null != homeDir);\n final File inDir = new File(new File(homeDir), fixedDataSetDir);\n assumeTrue(inDir.isDirectory());\n final File outDir = new File(new File(homeDir), fixedDataSetOutDir);\n assertTrue(outDir.isDirectory());\n assertTrue(outDir.canWrite());\n // Ensure no old result files hanging around...\n final File basicResultFile = new File(outDir, ETVSimpleDriverNBulkInputs.OUTPUT_STATS_FILE_BASIC);\n basicResultFile.delete(); // Make sure no output file.\n assertFalse(\"output file should not yet exist\", basicResultFile.isFile());\n final File basicFilteredResultFile = new File(outDir, ETVSimpleDriverNBulkInputs.OUTPUT_STATS_FILE_FILTERED_BASIC);\n basicFilteredResultFile.delete(); // Make sure no output file.\n assertFalse(\"output filtered file should not yet exist\", basicFilteredResultFile.isFile());\n // Do the computation.\n ETVSimpleDriverNBulkInputs.doComputation(inDir, outDir);\n // Check results.\n assertTrue(\"output file should now exist\", basicResultFile.isFile());\n assertTrue(\"output filtered file should now exist\", basicFilteredResultFile.isFile());\n System.out.println(\"Written to \" + outDir);\n }", "@Test\n public void testWriteParkReport() {\n System.out.println(\"writeParkReport\");\n List<String> write = new ArrayList<>();\n write.add(\"ePT03;100;0\\n\");\n write.add(\"ePT02;20;3846\\n\");\n boolean expResult = true;\n boolean result = WriteReport.writeParkReport(write, \"parkReport.txt\");\n assertEquals(expResult, result);\n expResult = false;\n result = WriteReport.writeParkReport(write, \"\");\n assertEquals(expResult, result);\n \n }", "@Test\n\tvoid testAdd() {\n\t\tint result = calculator.add(1,3);//act\n\t\tassertEquals(4,result);//assert//customized the failed message \"Test failed\"\n\t}", "protected void storeAndWriteEvalResults(Evaluation aggregated,\n Instances headerNoSummary, int totalFolds, boolean testSetPresent,\n String seed, String outputPath) throws IOException {\n\n StringBuilder buff = new StringBuilder();\n String info = \"Summary - \";\n if (testSetPresent) {\n info += \"separate test set\";\n } else if (totalFolds == 1) {\n info += \"test on training\";\n } else {\n info +=\n totalFolds + \" fold cross-validation (seed=\" + seed + \"): \"\n + m_classifier.getClass().getCanonicalName() + \" \"\n + Utils.joinOptions(m_classifier.getOptions())\n + \"\\n(note: relative measures might be slightly \"\n + \"pessimistic due to the mean/mode of the target being computed on \"\n + \"all the data rather than on training folds)\";\n }\n info += \":\\n\";\n if (aggregated.predictions() != null) {\n info +=\n \"Number of predictions retained for computing AUC/AUPRC: \"\n + aggregated.predictions().size() + \"\\n\";\n }\n buff.append(info).append(\"\\n\\n\");\n buff.append(aggregated.toSummaryString()).append(\"\\n\");\n if (headerNoSummary.classAttribute().isNominal()) {\n try {\n buff.append(aggregated.toClassDetailsString()).append(\"\\n\");\n buff.append(aggregated.toMatrixString()).append(\"\\n\");\n } catch (Exception ex) {\n logMessage(ex);\n throw new IOException(ex);\n }\n }\n\n String evalOutputPath =\n outputPath\n + (outputPath.toLowerCase().contains(\"://\") ? \"/\" : File.separator)\n + \"evaluation.txt\";\n m_textEvalResults = buff.toString();\n PrintWriter writer = null;\n try {\n writer = openTextFileForWrite(evalOutputPath);\n writer.println(m_textEvalResults);\n } finally {\n if (writer != null) {\n writer.flush();\n writer.close();\n writer = null;\n }\n }\n\n OutputStream stream = null;\n try {\n Instances asInstances =\n WekaClassifierEvaluationReduceTask\n .evaluationResultsToInstances(aggregated);\n m_evalResults = asInstances;\n\n String arffOutputPath =\n outputPath\n + (outputPath.toLowerCase().contains(\"://\") ? \"/\" : File.separator)\n + \"evaluation.arff\";\n writer = openTextFileForWrite(arffOutputPath);\n writer.println(asInstances.toString());\n\n String csvOutputPath =\n outputPath\n + (outputPath.toLowerCase().contains(\"://\") ? \"/\" : File.separator)\n + \"evaluation.csv\";\n stream = openFileForWrite(csvOutputPath);\n CSVSaver saver = new CSVSaver();\n saver.setRetrieval(Saver.BATCH);\n saver.setInstances(asInstances);\n saver.setDestination(stream);\n saver.writeBatch();\n } catch (Exception ex) {\n logMessage(ex);\n throw new IOException(ex);\n } finally {\n if (writer != null) {\n writer.flush();\n writer.close();\n }\n if (stream != null) {\n stream.flush();\n stream.close();\n }\n }\n }", "private void createIAnalysisInterface(final Environment result,\n\t\t\tfinal Environment ext)\n\t{\n\n\t\tMethodFactory extMf = new MethodFactory()\n\t\t{\n\n\t\t\t@Override\n\t\t\tpublic Method createCaseMethod(IClassDefinition cdef)\n\t\t\t{\n\t\t\t\tAnalysisAdaptorCaseMethod aacm = new AnalysisAdaptorCaseMethod();\n\t\t\t\taacm.setClassDefinition(cdef);\n\t\t\t\treturn aacm;\n\n\t\t\t}\n\n\t\t\t@Override\n\t\t\tpublic Method createDefaultCaseMethod(IClassDefinition cdef)\n\t\t\t{\n\t\t\t\tAnalysisAdaptorDefaultMethod aadm = new AnalysisAdaptorDefaultMethod();\n\t\t\t\taadm.setClassDefinition(cdef);\n\t\t\t\treturn aadm;\n\t\t\t}\n\n\t\t};\n\n\t\tcreateAnalysisInterface(Arrays.asList(new String[0]), \"Analysis\", result.TAG_IAnalysis, extMf, ext, result, base);\n\t}", "private static void createAnalysisInterface(List<String> genericArguments,\n\t\t\tString name, String tag, MethodFactory extMf, Environment extEnv,\n\t\t\tEnvironment result, Environment base)\n\t{\n\t\tJavaName jname = new JavaName(result.getAstPackage() + \".analysis.intf\", \"I\"\n\t\t\t\t+ extEnv.getName() + name);\n\t\tInterfaceDefinition extNewDef = new InterfaceDefinition(jname, result.getAstPackage());\n\t\textNewDef.setTag(tag);\n\t\textNewDef.setGenericArguments(genericArguments);\n\t\tresult.addInterface(extNewDef);\n\t\tIInterfaceDefinition iAnalysis = result.lookUpType(\"I\" + name);\n\t\t// extNewDef.supers.add(iAnalysis);\n\t\textNewDef.setExtJavaDoc(COMPASS_JAVA_DOC_STRING);\n\n\t\textNewDef.setIsExtTree(true);\n\t\textNewDef.setIsBaseTree(false);\n\n\t\t// Add methods for the analysis and apply functions for the classes\n\t\tfor (IClassDefinition cdef : result.getClasses())\n\t\t{\n\t\t\tEnvironment env = null;\n\t\t\tIInterfaceDefinition newDef = null;\n\t\t\tMethodFactory mf = null;\n\t\t\tif (!base.classToType.containsKey(cdef)\n\t\t\t\t\t&& result.classToType.containsKey(cdef))\n\t\t\t{\n\t\t\t\tmf = extMf;\n\t\t\t\tnewDef = extNewDef;\n\t\t\t\tenv = result;\n\t\t\t}\n\n\t\t\t// Should it have an apply method and a case in the analysis?\n\t\t\tif (mf != null)\n\t\t\t\tswitch (env.classToType.get(cdef))\n\t\t\t\t{\n\t\t\t\t\tcase Alternative:\n\t\t\t\t\tcase Token:\n\t\t\t\t\t{\n\t\t\t\t\t\t// mf.updateApplyMethod(cdef, jname.getCanonicalName());\n\n\t\t\t\t\t\tMethod caseMethod = mf.createCaseMethod(cdef);\n\t\t\t\t\t\tnewDef.addMethod(caseMethod);\n\n\t\t\t\t\t\t// remove this case from IAnalysis\n\t\t\t\t\t\tList<Method> toBeRemoved = new LinkedList<Method>();\n\t\t\t\t\t\tfor (Method m : iAnalysis.getMethods())\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tif (m.classDefinition == cdef)\n\t\t\t\t\t\t\t\ttoBeRemoved.add(m);\n\t\t\t\t\t\t}\n\t\t\t\t\t\tiAnalysis.getMethods().removeAll(toBeRemoved);\n\n\t\t\t\t\t}\n\t\t\t\t\t\tbreak;\n\t\t\t\t\tdefault:\n\t\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t}\n\n\t\t// Find existing adaptor class\n\t\tString adaptorName = name + \"Adaptor\";\n\t\tIClassDefinition answerClass = result.lookUp(adaptorName);\n\n\t\t// Create adaptor class\n\t\tIClassDefinition extAnswerClass = ClassFactory.createCustom(new JavaName(result.getAstPackage()\n\t\t\t\t+ \".analysis\", name + extEnv.getName() + \"Adaptor\"), result);\n\t\textAnswerClass.setGenericArguments(extNewDef.getGenericArguments());\n\t\textAnswerClass.addInterface(extNewDef);\n\t\textAnswerClass.setSuper(answerClass);\n\t\textAnswerClass.setAbstract(true);\n\t\textAnswerClass.setAnnotation(\"@SuppressWarnings({\\\"all\\\"})\");\n\n\t\tfor (IClassDefinition cdef : result.getClasses())\n\t\t{\n\t\t\tif (result.classToType.containsKey(cdef)\n\t\t\t\t\t&& !base.classToType.containsKey(cdef))\n\t\t\t{\n\t\t\t\tswitch (result.classToType.get(cdef))\n\t\t\t\t{\n\t\t\t\t\tcase Alternative:\n\t\t\t\t\tcase Token:\n\n\t\t\t\t\t\tMethod caseMethod = extMf.createCaseMethod(cdef);\n\t\t\t\t\t\textAnswerClass.addMethod(caseMethod);\n\n\t\t\t\t\t\t// Remove the case for the existing adaptor\n\t\t\t\t\t\tList<Method> toBeRemoved = new LinkedList<Method>();\n\t\t\t\t\t\tfor (Method m : answerClass.getMethods())\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tif (m.classDefinition == cdef)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\ttoBeRemoved.add(m);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\tanswerClass.getMethods().removeAll(toBeRemoved);\n\t\t\t\t\t\tbreak;\n\t\t\t\t\tcase Production:\n\t\t\t\t\tcase SubProduction:\n\n\t\t\t\t\t\tMethod defaultCase = extMf.createDefaultCaseMethod(cdef);\n\t\t\t\t\t\tdefaultCase.setClassDefinition(cdef);\n\t\t\t\t\t\textAnswerClass.addMethod(defaultCase);\n\n\t\t\t\t\t\t// Remove the case for the existing adaptor\n\t\t\t\t\t\ttoBeRemoved = new LinkedList<Method>();\n\t\t\t\t\t\tfor (Method m : answerClass.getMethods())\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tif (m.classDefinition == cdef)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\ttoBeRemoved.add(m);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\tanswerClass.getMethods().removeAll(toBeRemoved);\n\t\t\t\t\t\tbreak;\n\t\t\t\t\tdefault:\n\t\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t}", "public ExplanationPipeline<I, F>\n addRuleSetOptimizerWithTest(Optimizer<RuleExplanationSet, RuleExplanationSetFactory, ?, ?> toAdd) {\n return addRuleSetOptimizerWithTest(toAdd, false);\n }", "private void createTotalTestCase(BufferedWriter writer) throws IOException {\r\n\t\tString parent = \"<label style='margin-top: 8px;position: absolute;'>\";\r\n\t\tString content = \"<span style='display: inline;color: #000000;margin-left: 8px;font-weight: bold;font-family: Roboto, sans-serif;'>Total TestCases</span>\";\r\n\t\tString total = \"<span style='display: inline;color: #000000;margin-left: 100px;font-weight: bold;font-family: Roboto, sans-serif;'>\"\r\n\t\t\t\t+ data.getNumberOfTestTags() + \"</span></label>\";\r\n\t\twriter.write(parent + content + total);\r\n\t}", "@Test(timeout = 4000)\n public void test101() throws Throwable {\n Label label0 = new Label();\n FileSystemHandling.appendStringToFile((EvoSuiteFile) null, \"oc[MfnZM[~MHOK iO\");\n ClassWriter classWriter0 = new ClassWriter((-2463));\n classWriter0.newInteger((-2463));\n FileSystemHandling.setPermissions((EvoSuiteFile) null, false, false, false);\n String[] stringArray0 = new String[9];\n stringArray0[0] = \"Fj)3/|(;sZXz$\";\n stringArray0[1] = \"double\";\n stringArray0[2] = \"\\\".3t\\\"0\";\n stringArray0[3] = \"~)yCTRxQ#s$y[Ly%\";\n stringArray0[4] = \"Fj)3/|(;sZXz$\";\n stringArray0[5] = \"oc[MfnZM[~MHOK iO\";\n stringArray0[6] = \"Cpd7(e\";\n stringArray0[7] = \"oc[MfnZM[~MHOK iO\";\n stringArray0[8] = \"Cpd7(e\";\n MethodWriter methodWriter0 = new MethodWriter(classWriter0, 2, \"\\\".3t\\\"0\", \"~)yCTRxQ#s$y[Ly%\", \"double\", stringArray0, true, false);\n methodWriter0.visitJumpInsn(1, label0);\n classWriter0.newFieldItem(\"oc[MfnZM[~MHOK iO\", \"~hmio$aI6.7xL0\", \"~hmio$aI6.7xL0\");\n label0.successor = label0;\n Label label1 = new Label();\n methodWriter0.visitJumpInsn(1, label0);\n methodWriter0.visitMaxs(2708, (-1036));\n methodWriter0.visitFieldInsn(1, \"oc[MfnZM[~MHOK iO\", \"JSR/RET ar not supported with computeFrames option\", \"JSR/RET ar not supported with computeFrames option\");\n methodWriter0.visitJumpInsn(2, label0.successor);\n methodWriter0.getSize();\n // Undeclared exception!\n try { \n methodWriter0.visitInsn((-2486));\n fail(\"Expecting exception: ArrayIndexOutOfBoundsException\");\n \n } catch(ArrayIndexOutOfBoundsException e) {\n //\n // -2486\n //\n verifyException(\"org.objectweb.asm.jip.MethodWriter\", e);\n }\n }", "public void storeFinalTestDetail(TestEntry test, int verdict, DateFormat dateFormat, Calendar cal, File dirPath) throws Exception {\n // Fortify Mod: make sure that dirPath is a legal path\n // Note: a null dirPath is tolerated\n if( dirPath != null ) {\n TEPath tpath = new TEPath(dirPath.getAbsolutePath());\n if( ! tpath.isValid() ) \n throw new IllegalArgumentException(\"TEPath error on path \" + dirPath.getAbsolutePath());\n}\n // Check recording enable\n // Check recording is enable\n if (dirPath != null && A_TRUE.equals(System.getProperty(RECORD))) {\n // match test name\n if (!TECore.nameOfTest.equals(test.getName())) {\n String result=\"\";\n JSONObject obj = new JSONObject();\n obj.put(NAME, test.getName());\n if(getResultDescription(verdict).contains(\"Inherited\")&&test.getName().contains(\"GetMap\")){\n result=\"Passed\";\n }else{\n result=getResultDescription(verdict);\n }\n obj.put(RESULT, result);\n obj.put(TIME, dateFormat.format(cal.getTime()));\n // write the data into file in form of json\n OutputStreamWriter writer = new OutputStreamWriter(\n new FileOutputStream(dirPath.getAbsolutePath() + Constants.TEST_RESULTTXT, true), UT_F8);\n try (BufferedWriter fbw = new BufferedWriter(writer)) {\n fbw.write(obj.toString());\n fbw.newLine();\n fbw.close();\n }\n } else {\n // update test no\n TECore.testCount = 0;\n }\n }\n }", "public CustomAnalyses(String analysisFolder) {\n \n this.analysisFolder = new File(analysisFolder);\n this.analyses = new HashMap<>();\n \n // Scan alayses in folder & populate analyses array\n File[] files = this.analysisFolder.listFiles();\n for (File f: files) {\n if (f.isFile()) {\n \n // Get filename\n String n = f.getName();\n \n // get extension\n String[] parts = n.split(\"\\\\.\");\n String ext = parts[parts.length-1];\n \n // Strip extension\n n = n.substring(0, n.length()-ext.length()-1);\n \n // Create entry\n if (!analyses.containsKey(n)) {\n File subPath = new File(this.analysisFolder, n);\n analyses.put(n, new Data(n, subPath.getPath()) );\n }\n }\n }\n \n }", "public interface Analysis {\n Collection<Collection<String>> analyze(CalculationPeriod period, String user);\n}", "@Test\n\tpublic void testAdd() {\n\t\t\n\t\ttestStructure.add(\"Dog\", 5);\n\t\ttestStructure.add(\"dog\", 1);\n\t\ttestStructure.add(\"dog\", 1);\n\t\ttestStructure.add(\"zebra\", 3);\n\t\ttestStructure.add(\"horse\", 5);\n\n\t\t\n\t\tSystem.out.println(testStructure.showAll());\n\t\tassertEquals(\"[dog: 1, 5\\n, horse: 5\\n, zebra: 3\\n]\", testStructure.showAll().toString());\n\t\t\n\t}", "@Test(timeout = 4000)\n public void test037() throws Throwable {\n ClassWriter classWriter0 = new ClassWriter(23);\n byte[] byteArray0 = classWriter0.toByteArray();\n MethodWriter methodWriter0 = new MethodWriter(classWriter0, 2, \".JAR\", \".JAR\", \".JAR\", (String[]) null, false, false);\n Attribute attribute0 = new Attribute(\"LineNumberTable\");\n attribute0.value = byteArray0;\n methodWriter0.visitAttribute(attribute0);\n ByteVector byteVector0 = new ByteVector();\n ByteVector byteVector1 = byteVector0.putShort(16777220);\n methodWriter0.put(byteVector1);\n assertSame(byteVector1, byteVector0);\n }", "@org.junit.Test\r\n public void testProspectParser() {\r\n PrintWriter writer;\r\n try {\r\n writer = new PrintWriter(file);\r\n\r\n //Should be added to prospect list\r\n writer.println(\"Börje,30000,4,3\");\r\n //Should not be added to prospect list\r\n writer.println(\"Bamse,5000,fyra,3.\");\r\n //Should not be added to prospect list\r\n writer.println(\"Andersson,f,2\");\r\n //Should be added to prospect list\r\n writer.println(\"Doris,40000,5,2\");\r\n\r\n writer.close();\r\n ProspectParser p = new ProspectParser(file, namePattern, digitPattern);\r\n p.parse();\r\n int size = p.getProspects().size();\r\n\r\n assertEquals(2, size);\r\n } catch (FileNotFoundException ex) {\r\n String failStr = \"Failed to create file writer: \" + ex;\r\n Logger.getLogger(MortagePlanTest.class.getName()).log(Level.SEVERE, null, ex);\r\n fail(failStr);\r\n }\r\n }", "@Test\n public void testAddMedium() throws Exception {\n System.out.println(\"addMedium\");\n String type = \"\";\n Medium pomData = new MediumImpl();\n pomData.addTitle(\"test1\");\n pomData.addTitle(\"test2\");\n DBManager instance = new ODSDBManager(\"empty.ods\");\n List<Medium> expResult = instance.getMedia(\"b\");\n instance.addMedium(\"b\", pomData);\n expResult.add(pomData);\n List<Medium> result = instance.getMedia(\"b\");\n System.out.println(\"result:\"+result+\"\\n data:\"+pomData);\n assertTrue(result.contains(pomData));\n \n // TODO review the generated test code and remove the default call to fail.\n //fail(\"The test case is a prototype.\");\n }", "protected int addInfo(syntaxMap toAdd){\n if(index == 10){\n return 0;\n }\n else if(index < 5) {\n this.array1[index] = toAdd;\n }\n else{\n this.array2[index - 5] = toAdd;\n }\n ++index;\n return 1;\n }", "@Test\n void qureyInfoByStudentNum() {\n addInfoForGEIAS();\n }", "public void writeToFile(String outputName) throws Exception{\n if (trials == null || data == null) throw new Exception(\"Must read marker and data file before writing it out\");\n BufferedWriter bw = new BufferedWriter(new FileWriter(outputName));\n \n //.. write out the headers\n for (int i= FIRSTPROBEINDEX; i < header.length; i++) {\n bw.write(header[i]);\n bw.write(\",\");\n }\n \n //.. write out condition\n bw.write(\"condition\");\n \n bw.write(\"\\n\");\n int rowNum =0;\n \n //.. write out actual data\n for (String [] row : data) {\n if (row.length!= header.length) System.out.println(\"Row has \" + row.length + \" whereas header has \" + header.length);\n String label =null;\n for (int i = FIRSTPROBEINDEX; i < row.length; i++) {\n label = getLabel(rowNum); //.. will be null if it doesn't exist\n \n if (label != null ) {\n bw.write(row[i]);\n bw.write(\",\");\n }\n }\n if (label!=null) {\n //System.out.println(\"Writing \" + getLabel(rowNum));\n String condition = getLabel(rowNum);\n bw.write(condition);\n bw.write(\"\\n\");\n \n //.. this is a hack since my program gives an error if a conditon jsut has one line\n if (condition.equals(\"passed\")) duplicateLastLine(bw, row, condition,20 );\n \n }\n rowNum++;\n }\n \n bw.close();\n }", "public static void testSet06(PrintStream outputStream)\r\n {\r\n outputStream.println(\"\\r\\n----Test Set 6----\\r\\n\");\r\n\r\n DynamicArray a1 = new DynamicArray(20);\r\n addValues(a1, 12);\r\n \r\n// Test #1\r\n if(a1.get(0)==0 && a1.get(11)== 11) \r\n {\r\n outputStream.printf(\"%-80s%-10s\\r\\n\", \"Test Set 06: Test 1 for get()\", \"PASSED\");\r\n \r\n }\r\n else outputStream.printf(\"%-80s%-10s\\r\\n\", \"Test Set 06: Test 1 for get()\", \"FAILED\");\r\n// Test #2\r\n try{\r\n a1.get(13);\r\n outputStream.printf(\"%-80s%-10s\\r\\n\", \"Test Set 06: Test 2 for get() - exception\", \"FAILED\");\r\n }\r\n catch(IndexOutOfBoundsException e)\r\n {\r\n outputStream.printf(\"%-80s%-10s\\r\\n\", \"Test Set 06: Test 2 for get() - exception\", \"PASSED\");\r\n \r\n }\r\n \r\n// Test #3\r\n if(a1.indexOf(0) == 0 && a1.indexOf(11) == 11 && a1.indexOf(33)==-1) \r\n {\r\n outputStream.printf(\"%-80s%-10s\\r\\n\", \"Test Set 06: Test 1 for indexOf()\", \"PASSED\");\r\n \r\n }\r\n else outputStream.printf(\"%-80s%-10s\\r\\n\", \"Test Set 06: Test 1 for indexOf()\", \"FAILED\");\r\n int[] test4 = {0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11};\r\n int[] empty = {};\r\n DynamicArray a2 = new DynamicArray(3);\r\n DynamicArray a3 = new DynamicArray();\r\n \r\n// Test #4\r\n if(equal(a1.toArray(), test4)&& equal(a2.toArray(), empty) && equal(a3.toArray(), empty)) \r\n {\r\n outputStream.printf(\"%-80s%-10s\\r\\n\", \"Test Set 06: Test 1 for toArray()\", \"PASSED\");\r\n \r\n }\r\n else outputStream.printf(\"%-80s%-10s\\r\\n\", \"Test Set 06: Test 1 for toArray()\", \"FAILED\");\r\n\r\n }", "@Override\n\tpublic void saveTestingData() {\n\t\t\n\t}", "@Test(timeout = 4000)\n public void test088() throws Throwable {\n ClassWriter classWriter0 = new ClassWriter((-1983180321));\n byte[] byteArray0 = new byte[6];\n byteArray0[1] = (byte) (-8);\n byteArray0[2] = (byte)111;\n FileSystemHandling fileSystemHandling0 = new FileSystemHandling();\n byteArray0[3] = (byte)111;\n byteArray0[4] = (byte)114;\n byteArray0[5] = (byte) (-85);\n FileSystemHandling.appendDataToFile((EvoSuiteFile) null, byteArray0);\n String[] stringArray0 = new String[4];\n stringArray0[0] = \"\";\n stringArray0[1] = \"\";\n stringArray0[2] = \"\";\n stringArray0[3] = \"\";\n MethodWriter methodWriter0 = new MethodWriter(classWriter0, (-1983180321), \"\", \"<T'RwU+).UKJX>\", \"\", stringArray0, true, false);\n methodWriter0.visitMethodInsn(183, \"\", \"\", \"<T'RwU+).UKJX>\");\n methodWriter0.visitTypeInsn((byte)0, \"HC\");\n }", "@Override\n public void performRecommendedDataMiningMethodForAnalysis(Analysis analysis) throws IOException {\n }", "public void testADDWithData() throws Exception {\n String data =\"Some words about Helen of Troy\";\n doAdd(data, null);\n }", "@Test(timeout = 4000)\n public void test012() throws Throwable {\n ResultMatrixLatex resultMatrixLatex0 = new ResultMatrixLatex();\n assertEquals(0, resultMatrixLatex0.getMeanWidth());\n assertEquals(\"Whether to remove the classname package prefixes from the filter names in datasets.\", resultMatrixLatex0.removeFilterNameTipText());\n assertTrue(resultMatrixLatex0.getEnumerateColNames());\n assertEquals(0, resultMatrixLatex0.getDefaultStdDevWidth());\n assertEquals(\"The number of decimals after the decimal point for the standard deviation.\", resultMatrixLatex0.stdDevPrecTipText());\n assertEquals(0, resultMatrixLatex0.getStdDevWidth());\n assertEquals(1, resultMatrixLatex0.getVisibleColCount());\n assertEquals(\"Whether to enumerate the column names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixLatex0.enumerateColNamesTipText());\n assertEquals(\"The maximum width of the column names (0 = optimal).\", resultMatrixLatex0.colNameWidthTipText());\n assertFalse(resultMatrixLatex0.getRemoveFilterName());\n assertEquals(\"Whether to output column names or just numbers representing them.\", resultMatrixLatex0.printColNamesTipText());\n assertEquals(0, resultMatrixLatex0.getCountWidth());\n assertEquals(\"The width of the standard deviation (0 = optimal).\", resultMatrixLatex0.stdDevWidthTipText());\n assertEquals(\"The width of the significance indicator (0 = optimal).\", resultMatrixLatex0.significanceWidthTipText());\n assertEquals(\"LaTeX\", resultMatrixLatex0.getDisplayName());\n assertEquals(\"Whether to show the row with averages.\", resultMatrixLatex0.showAverageTipText());\n assertEquals(0, resultMatrixLatex0.getSignificanceWidth());\n assertFalse(resultMatrixLatex0.getShowStdDev());\n assertEquals(0, resultMatrixLatex0.getRowNameWidth());\n assertTrue(resultMatrixLatex0.getDefaultEnumerateColNames());\n assertFalse(resultMatrixLatex0.getShowAverage());\n assertEquals(\"The maximum width for the row names (0 = optimal).\", resultMatrixLatex0.rowNameWidthTipText());\n assertEquals(0, resultMatrixLatex0.getColNameWidth());\n assertFalse(resultMatrixLatex0.getDefaultEnumerateRowNames());\n assertEquals(0, resultMatrixLatex0.getDefaultRowNameWidth());\n assertFalse(resultMatrixLatex0.getDefaultShowAverage());\n assertEquals(2, resultMatrixLatex0.getMeanPrec());\n assertEquals(\"Whether to enumerate the row names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixLatex0.enumerateRowNamesTipText());\n assertEquals(0, resultMatrixLatex0.getDefaultCountWidth());\n assertFalse(resultMatrixLatex0.getEnumerateRowNames());\n assertFalse(resultMatrixLatex0.getPrintColNames());\n assertEquals(1, resultMatrixLatex0.getVisibleRowCount());\n assertEquals(2, resultMatrixLatex0.getDefaultStdDevPrec());\n assertEquals(1, resultMatrixLatex0.getRowCount());\n assertEquals(\"The number of decimals after the decimal point for the mean.\", resultMatrixLatex0.meanPrecTipText());\n assertEquals(2, resultMatrixLatex0.getDefaultMeanPrec());\n assertTrue(resultMatrixLatex0.getDefaultPrintRowNames());\n assertEquals(\"Whether to display the standard deviation column.\", resultMatrixLatex0.showStdDevTipText());\n assertFalse(resultMatrixLatex0.getDefaultPrintColNames());\n assertEquals(\"Whether to output row names or just numbers representing them.\", resultMatrixLatex0.printRowNamesTipText());\n assertTrue(resultMatrixLatex0.getPrintRowNames());\n assertEquals(\"The width of the counts (0 = optimal).\", resultMatrixLatex0.countWidthTipText());\n assertEquals(2, resultMatrixLatex0.getStdDevPrec());\n assertEquals(\"The width of the mean (0 = optimal).\", resultMatrixLatex0.meanWidthTipText());\n assertFalse(resultMatrixLatex0.getDefaultShowStdDev());\n assertEquals(0, resultMatrixLatex0.getDefaultSignificanceWidth());\n assertEquals(1, resultMatrixLatex0.getColCount());\n assertEquals(\"Generates the matrix output in LaTeX-syntax.\", resultMatrixLatex0.globalInfo());\n assertEquals(0, resultMatrixLatex0.getDefaultColNameWidth());\n assertEquals(0, resultMatrixLatex0.getDefaultMeanWidth());\n assertFalse(resultMatrixLatex0.getDefaultRemoveFilterName());\n assertNotNull(resultMatrixLatex0);\n assertEquals(0, ResultMatrix.SIGNIFICANCE_TIE);\n assertEquals(1, ResultMatrix.SIGNIFICANCE_WIN);\n assertEquals(2, ResultMatrix.SIGNIFICANCE_LOSS);\n \n int[] intArray0 = new int[1];\n intArray0[0] = 1;\n resultMatrixLatex0.setRowOrder(intArray0);\n assertArrayEquals(new int[] {1}, intArray0);\n assertEquals(0, resultMatrixLatex0.getMeanWidth());\n assertEquals(\"Whether to remove the classname package prefixes from the filter names in datasets.\", resultMatrixLatex0.removeFilterNameTipText());\n assertTrue(resultMatrixLatex0.getEnumerateColNames());\n assertEquals(0, resultMatrixLatex0.getDefaultStdDevWidth());\n assertEquals(\"The number of decimals after the decimal point for the standard deviation.\", resultMatrixLatex0.stdDevPrecTipText());\n assertEquals(0, resultMatrixLatex0.getStdDevWidth());\n assertEquals(1, resultMatrixLatex0.getVisibleColCount());\n assertEquals(\"Whether to enumerate the column names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixLatex0.enumerateColNamesTipText());\n assertEquals(\"The maximum width of the column names (0 = optimal).\", resultMatrixLatex0.colNameWidthTipText());\n assertFalse(resultMatrixLatex0.getRemoveFilterName());\n assertEquals(\"Whether to output column names or just numbers representing them.\", resultMatrixLatex0.printColNamesTipText());\n assertEquals(0, resultMatrixLatex0.getCountWidth());\n assertEquals(\"The width of the standard deviation (0 = optimal).\", resultMatrixLatex0.stdDevWidthTipText());\n assertEquals(\"The width of the significance indicator (0 = optimal).\", resultMatrixLatex0.significanceWidthTipText());\n assertEquals(\"LaTeX\", resultMatrixLatex0.getDisplayName());\n assertEquals(\"Whether to show the row with averages.\", resultMatrixLatex0.showAverageTipText());\n assertEquals(0, resultMatrixLatex0.getSignificanceWidth());\n assertFalse(resultMatrixLatex0.getShowStdDev());\n assertEquals(0, resultMatrixLatex0.getRowNameWidth());\n assertTrue(resultMatrixLatex0.getDefaultEnumerateColNames());\n assertFalse(resultMatrixLatex0.getShowAverage());\n assertEquals(\"The maximum width for the row names (0 = optimal).\", resultMatrixLatex0.rowNameWidthTipText());\n assertEquals(0, resultMatrixLatex0.getColNameWidth());\n assertFalse(resultMatrixLatex0.getDefaultEnumerateRowNames());\n assertEquals(0, resultMatrixLatex0.getDefaultRowNameWidth());\n assertFalse(resultMatrixLatex0.getDefaultShowAverage());\n assertEquals(2, resultMatrixLatex0.getMeanPrec());\n assertEquals(\"Whether to enumerate the row names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixLatex0.enumerateRowNamesTipText());\n assertEquals(0, resultMatrixLatex0.getDefaultCountWidth());\n assertFalse(resultMatrixLatex0.getEnumerateRowNames());\n assertFalse(resultMatrixLatex0.getPrintColNames());\n assertEquals(1, resultMatrixLatex0.getVisibleRowCount());\n assertEquals(2, resultMatrixLatex0.getDefaultStdDevPrec());\n assertEquals(1, resultMatrixLatex0.getRowCount());\n assertEquals(\"The number of decimals after the decimal point for the mean.\", resultMatrixLatex0.meanPrecTipText());\n assertEquals(2, resultMatrixLatex0.getDefaultMeanPrec());\n assertTrue(resultMatrixLatex0.getDefaultPrintRowNames());\n assertEquals(\"Whether to display the standard deviation column.\", resultMatrixLatex0.showStdDevTipText());\n assertFalse(resultMatrixLatex0.getDefaultPrintColNames());\n assertEquals(\"Whether to output row names or just numbers representing them.\", resultMatrixLatex0.printRowNamesTipText());\n assertTrue(resultMatrixLatex0.getPrintRowNames());\n assertEquals(\"The width of the counts (0 = optimal).\", resultMatrixLatex0.countWidthTipText());\n assertEquals(2, resultMatrixLatex0.getStdDevPrec());\n assertEquals(\"The width of the mean (0 = optimal).\", resultMatrixLatex0.meanWidthTipText());\n assertFalse(resultMatrixLatex0.getDefaultShowStdDev());\n assertEquals(0, resultMatrixLatex0.getDefaultSignificanceWidth());\n assertEquals(1, resultMatrixLatex0.getColCount());\n assertEquals(\"Generates the matrix output in LaTeX-syntax.\", resultMatrixLatex0.globalInfo());\n assertEquals(0, resultMatrixLatex0.getDefaultColNameWidth());\n assertEquals(0, resultMatrixLatex0.getDefaultMeanWidth());\n assertFalse(resultMatrixLatex0.getDefaultRemoveFilterName());\n assertEquals(0, ResultMatrix.SIGNIFICANCE_TIE);\n assertEquals(1, ResultMatrix.SIGNIFICANCE_WIN);\n assertEquals(2, ResultMatrix.SIGNIFICANCE_LOSS);\n assertEquals(1, intArray0.length);\n \n ResultMatrixPlainText resultMatrixPlainText0 = new ResultMatrixPlainText(1, 1);\n assertFalse(resultMatrixPlainText0.getShowStdDev());\n assertEquals(\"The width of the mean (0 = optimal).\", resultMatrixPlainText0.meanWidthTipText());\n assertEquals(2, resultMatrixPlainText0.getStdDevPrec());\n assertEquals(\"Plain Text\", resultMatrixPlainText0.getDisplayName());\n assertTrue(resultMatrixPlainText0.getDefaultPrintColNames());\n assertEquals(\"Whether to display the standard deviation column.\", resultMatrixPlainText0.showStdDevTipText());\n assertTrue(resultMatrixPlainText0.getDefaultEnumerateColNames());\n assertEquals(\"The width of the standard deviation (0 = optimal).\", resultMatrixPlainText0.stdDevWidthTipText());\n assertEquals(\"The width of the significance indicator (0 = optimal).\", resultMatrixPlainText0.significanceWidthTipText());\n assertEquals(0, resultMatrixPlainText0.getSignificanceWidth());\n assertFalse(resultMatrixPlainText0.getEnumerateRowNames());\n assertEquals(\"Whether to remove the classname package prefixes from the filter names in datasets.\", resultMatrixPlainText0.removeFilterNameTipText());\n assertTrue(resultMatrixPlainText0.getDefaultPrintRowNames());\n assertEquals(\"The number of decimals after the decimal point for the standard deviation.\", resultMatrixPlainText0.stdDevPrecTipText());\n assertEquals(\"Whether to output column names or just numbers representing them.\", resultMatrixPlainText0.printColNamesTipText());\n assertEquals(0, resultMatrixPlainText0.getDefaultMeanWidth());\n assertEquals(2, resultMatrixPlainText0.getMeanPrec());\n assertEquals(\"Whether to enumerate the column names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixPlainText0.enumerateColNamesTipText());\n assertFalse(resultMatrixPlainText0.getDefaultEnumerateRowNames());\n assertEquals(1, resultMatrixPlainText0.getVisibleColCount());\n assertTrue(resultMatrixPlainText0.getPrintRowNames());\n assertEquals(5, resultMatrixPlainText0.getCountWidth());\n assertEquals(2, resultMatrixPlainText0.getDefaultMeanPrec());\n assertEquals(0, resultMatrixPlainText0.getDefaultStdDevWidth());\n assertEquals(0, resultMatrixPlainText0.getDefaultSignificanceWidth());\n assertEquals(25, resultMatrixPlainText0.getDefaultRowNameWidth());\n assertEquals(0, resultMatrixPlainText0.getDefaultColNameWidth());\n assertEquals(\"The number of decimals after the decimal point for the mean.\", resultMatrixPlainText0.meanPrecTipText());\n assertEquals(\"The width of the counts (0 = optimal).\", resultMatrixPlainText0.countWidthTipText());\n assertFalse(resultMatrixPlainText0.getDefaultShowStdDev());\n assertEquals(5, resultMatrixPlainText0.getDefaultCountWidth());\n assertEquals(2, resultMatrixPlainText0.getDefaultStdDevPrec());\n assertTrue(resultMatrixPlainText0.getPrintColNames());\n assertEquals(\"Whether to output row names or just numbers representing them.\", resultMatrixPlainText0.printRowNamesTipText());\n assertFalse(resultMatrixPlainText0.getDefaultRemoveFilterName());\n assertEquals(\"Generates the output as plain text (for fixed width fonts).\", resultMatrixPlainText0.globalInfo());\n assertFalse(resultMatrixPlainText0.getRemoveFilterName());\n assertEquals(1, resultMatrixPlainText0.getVisibleRowCount());\n assertEquals(\"Whether to enumerate the row names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixPlainText0.enumerateRowNamesTipText());\n assertEquals(\"The maximum width for the row names (0 = optimal).\", resultMatrixPlainText0.rowNameWidthTipText());\n assertEquals(1, resultMatrixPlainText0.getColCount());\n assertEquals(0, resultMatrixPlainText0.getColNameWidth());\n assertFalse(resultMatrixPlainText0.getDefaultShowAverage());\n assertEquals(\"The maximum width of the column names (0 = optimal).\", resultMatrixPlainText0.colNameWidthTipText());\n assertEquals(0, resultMatrixPlainText0.getMeanWidth());\n assertTrue(resultMatrixPlainText0.getEnumerateColNames());\n assertEquals(1, resultMatrixPlainText0.getRowCount());\n assertEquals(25, resultMatrixPlainText0.getRowNameWidth());\n assertEquals(\"Whether to show the row with averages.\", resultMatrixPlainText0.showAverageTipText());\n assertEquals(0, resultMatrixPlainText0.getStdDevWidth());\n assertFalse(resultMatrixPlainText0.getShowAverage());\n assertNotNull(resultMatrixPlainText0);\n assertEquals(1, ResultMatrix.SIGNIFICANCE_WIN);\n assertEquals(2, ResultMatrix.SIGNIFICANCE_LOSS);\n assertEquals(0, ResultMatrix.SIGNIFICANCE_TIE);\n \n resultMatrixPlainText0.m_StdDevPrec = 1;\n assertFalse(resultMatrixPlainText0.getShowStdDev());\n assertEquals(\"The width of the mean (0 = optimal).\", resultMatrixPlainText0.meanWidthTipText());\n assertEquals(\"Plain Text\", resultMatrixPlainText0.getDisplayName());\n assertTrue(resultMatrixPlainText0.getDefaultPrintColNames());\n assertEquals(\"Whether to display the standard deviation column.\", resultMatrixPlainText0.showStdDevTipText());\n assertTrue(resultMatrixPlainText0.getDefaultEnumerateColNames());\n assertEquals(\"The width of the standard deviation (0 = optimal).\", resultMatrixPlainText0.stdDevWidthTipText());\n assertEquals(\"The width of the significance indicator (0 = optimal).\", resultMatrixPlainText0.significanceWidthTipText());\n assertEquals(0, resultMatrixPlainText0.getSignificanceWidth());\n assertFalse(resultMatrixPlainText0.getEnumerateRowNames());\n assertEquals(\"Whether to remove the classname package prefixes from the filter names in datasets.\", resultMatrixPlainText0.removeFilterNameTipText());\n assertTrue(resultMatrixPlainText0.getDefaultPrintRowNames());\n assertEquals(\"The number of decimals after the decimal point for the standard deviation.\", resultMatrixPlainText0.stdDevPrecTipText());\n assertEquals(\"Whether to output column names or just numbers representing them.\", resultMatrixPlainText0.printColNamesTipText());\n assertEquals(0, resultMatrixPlainText0.getDefaultMeanWidth());\n assertEquals(2, resultMatrixPlainText0.getMeanPrec());\n assertEquals(1, resultMatrixPlainText0.getStdDevPrec());\n assertEquals(\"Whether to enumerate the column names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixPlainText0.enumerateColNamesTipText());\n assertFalse(resultMatrixPlainText0.getDefaultEnumerateRowNames());\n assertEquals(1, resultMatrixPlainText0.getVisibleColCount());\n assertTrue(resultMatrixPlainText0.getPrintRowNames());\n assertEquals(5, resultMatrixPlainText0.getCountWidth());\n assertEquals(2, resultMatrixPlainText0.getDefaultMeanPrec());\n assertEquals(0, resultMatrixPlainText0.getDefaultStdDevWidth());\n assertEquals(0, resultMatrixPlainText0.getDefaultSignificanceWidth());\n assertEquals(25, resultMatrixPlainText0.getDefaultRowNameWidth());\n assertEquals(0, resultMatrixPlainText0.getDefaultColNameWidth());\n assertEquals(\"The number of decimals after the decimal point for the mean.\", resultMatrixPlainText0.meanPrecTipText());\n assertEquals(\"The width of the counts (0 = optimal).\", resultMatrixPlainText0.countWidthTipText());\n assertFalse(resultMatrixPlainText0.getDefaultShowStdDev());\n assertEquals(5, resultMatrixPlainText0.getDefaultCountWidth());\n assertEquals(2, resultMatrixPlainText0.getDefaultStdDevPrec());\n assertTrue(resultMatrixPlainText0.getPrintColNames());\n assertEquals(\"Whether to output row names or just numbers representing them.\", resultMatrixPlainText0.printRowNamesTipText());\n assertFalse(resultMatrixPlainText0.getDefaultRemoveFilterName());\n assertEquals(\"Generates the output as plain text (for fixed width fonts).\", resultMatrixPlainText0.globalInfo());\n assertFalse(resultMatrixPlainText0.getRemoveFilterName());\n assertEquals(1, resultMatrixPlainText0.getVisibleRowCount());\n assertEquals(\"Whether to enumerate the row names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixPlainText0.enumerateRowNamesTipText());\n assertEquals(\"The maximum width for the row names (0 = optimal).\", resultMatrixPlainText0.rowNameWidthTipText());\n assertEquals(1, resultMatrixPlainText0.getColCount());\n assertEquals(0, resultMatrixPlainText0.getColNameWidth());\n assertFalse(resultMatrixPlainText0.getDefaultShowAverage());\n assertEquals(\"The maximum width of the column names (0 = optimal).\", resultMatrixPlainText0.colNameWidthTipText());\n assertEquals(0, resultMatrixPlainText0.getMeanWidth());\n assertTrue(resultMatrixPlainText0.getEnumerateColNames());\n assertEquals(1, resultMatrixPlainText0.getRowCount());\n assertEquals(25, resultMatrixPlainText0.getRowNameWidth());\n assertEquals(\"Whether to show the row with averages.\", resultMatrixPlainText0.showAverageTipText());\n assertEquals(0, resultMatrixPlainText0.getStdDevWidth());\n assertFalse(resultMatrixPlainText0.getShowAverage());\n \n int int0 = resultMatrixPlainText0.getDefaultCountWidth();\n assertFalse(resultMatrixPlainText0.getShowStdDev());\n assertEquals(\"The width of the mean (0 = optimal).\", resultMatrixPlainText0.meanWidthTipText());\n assertEquals(\"Plain Text\", resultMatrixPlainText0.getDisplayName());\n assertTrue(resultMatrixPlainText0.getDefaultPrintColNames());\n assertEquals(\"Whether to display the standard deviation column.\", resultMatrixPlainText0.showStdDevTipText());\n assertTrue(resultMatrixPlainText0.getDefaultEnumerateColNames());\n assertEquals(\"The width of the standard deviation (0 = optimal).\", resultMatrixPlainText0.stdDevWidthTipText());\n assertEquals(\"The width of the significance indicator (0 = optimal).\", resultMatrixPlainText0.significanceWidthTipText());\n assertEquals(0, resultMatrixPlainText0.getSignificanceWidth());\n assertFalse(resultMatrixPlainText0.getEnumerateRowNames());\n assertEquals(\"Whether to remove the classname package prefixes from the filter names in datasets.\", resultMatrixPlainText0.removeFilterNameTipText());\n assertTrue(resultMatrixPlainText0.getDefaultPrintRowNames());\n assertEquals(\"The number of decimals after the decimal point for the standard deviation.\", resultMatrixPlainText0.stdDevPrecTipText());\n assertEquals(\"Whether to output column names or just numbers representing them.\", resultMatrixPlainText0.printColNamesTipText());\n assertEquals(0, resultMatrixPlainText0.getDefaultMeanWidth());\n assertEquals(2, resultMatrixPlainText0.getMeanPrec());\n assertEquals(1, resultMatrixPlainText0.getStdDevPrec());\n assertEquals(\"Whether to enumerate the column names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixPlainText0.enumerateColNamesTipText());\n assertFalse(resultMatrixPlainText0.getDefaultEnumerateRowNames());\n assertEquals(1, resultMatrixPlainText0.getVisibleColCount());\n assertTrue(resultMatrixPlainText0.getPrintRowNames());\n assertEquals(5, resultMatrixPlainText0.getCountWidth());\n assertEquals(2, resultMatrixPlainText0.getDefaultMeanPrec());\n assertEquals(0, resultMatrixPlainText0.getDefaultStdDevWidth());\n assertEquals(0, resultMatrixPlainText0.getDefaultSignificanceWidth());\n assertEquals(25, resultMatrixPlainText0.getDefaultRowNameWidth());\n assertEquals(0, resultMatrixPlainText0.getDefaultColNameWidth());\n assertEquals(\"The number of decimals after the decimal point for the mean.\", resultMatrixPlainText0.meanPrecTipText());\n assertEquals(\"The width of the counts (0 = optimal).\", resultMatrixPlainText0.countWidthTipText());\n assertFalse(resultMatrixPlainText0.getDefaultShowStdDev());\n assertEquals(5, resultMatrixPlainText0.getDefaultCountWidth());\n assertEquals(2, resultMatrixPlainText0.getDefaultStdDevPrec());\n assertTrue(resultMatrixPlainText0.getPrintColNames());\n assertEquals(\"Whether to output row names or just numbers representing them.\", resultMatrixPlainText0.printRowNamesTipText());\n assertFalse(resultMatrixPlainText0.getDefaultRemoveFilterName());\n assertEquals(\"Generates the output as plain text (for fixed width fonts).\", resultMatrixPlainText0.globalInfo());\n assertFalse(resultMatrixPlainText0.getRemoveFilterName());\n assertEquals(1, resultMatrixPlainText0.getVisibleRowCount());\n assertEquals(\"Whether to enumerate the row names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixPlainText0.enumerateRowNamesTipText());\n assertEquals(\"The maximum width for the row names (0 = optimal).\", resultMatrixPlainText0.rowNameWidthTipText());\n assertEquals(1, resultMatrixPlainText0.getColCount());\n assertEquals(0, resultMatrixPlainText0.getColNameWidth());\n assertFalse(resultMatrixPlainText0.getDefaultShowAverage());\n assertEquals(\"The maximum width of the column names (0 = optimal).\", resultMatrixPlainText0.colNameWidthTipText());\n assertEquals(0, resultMatrixPlainText0.getMeanWidth());\n assertTrue(resultMatrixPlainText0.getEnumerateColNames());\n assertEquals(1, resultMatrixPlainText0.getRowCount());\n assertEquals(25, resultMatrixPlainText0.getRowNameWidth());\n assertEquals(\"Whether to show the row with averages.\", resultMatrixPlainText0.showAverageTipText());\n assertEquals(0, resultMatrixPlainText0.getStdDevWidth());\n assertFalse(resultMatrixPlainText0.getShowAverage());\n assertEquals(1, ResultMatrix.SIGNIFICANCE_WIN);\n assertEquals(2, ResultMatrix.SIGNIFICANCE_LOSS);\n assertEquals(0, ResultMatrix.SIGNIFICANCE_TIE);\n assertEquals(5, int0);\n \n ResultMatrixGnuPlot resultMatrixGnuPlot0 = new ResultMatrixGnuPlot(resultMatrixLatex0);\n assertEquals(0, resultMatrixLatex0.getMeanWidth());\n assertEquals(\"Whether to remove the classname package prefixes from the filter names in datasets.\", resultMatrixLatex0.removeFilterNameTipText());\n assertTrue(resultMatrixLatex0.getEnumerateColNames());\n assertEquals(0, resultMatrixLatex0.getDefaultStdDevWidth());\n assertEquals(\"The number of decimals after the decimal point for the standard deviation.\", resultMatrixLatex0.stdDevPrecTipText());\n assertEquals(0, resultMatrixLatex0.getStdDevWidth());\n assertEquals(1, resultMatrixLatex0.getVisibleColCount());\n assertEquals(\"Whether to enumerate the column names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixLatex0.enumerateColNamesTipText());\n assertEquals(\"The maximum width of the column names (0 = optimal).\", resultMatrixLatex0.colNameWidthTipText());\n assertFalse(resultMatrixLatex0.getRemoveFilterName());\n assertEquals(\"Whether to output column names or just numbers representing them.\", resultMatrixLatex0.printColNamesTipText());\n assertEquals(0, resultMatrixLatex0.getCountWidth());\n assertEquals(\"The width of the standard deviation (0 = optimal).\", resultMatrixLatex0.stdDevWidthTipText());\n assertEquals(\"The width of the significance indicator (0 = optimal).\", resultMatrixLatex0.significanceWidthTipText());\n assertEquals(\"LaTeX\", resultMatrixLatex0.getDisplayName());\n assertEquals(\"Whether to show the row with averages.\", resultMatrixLatex0.showAverageTipText());\n assertEquals(0, resultMatrixLatex0.getSignificanceWidth());\n assertFalse(resultMatrixLatex0.getShowStdDev());\n assertEquals(0, resultMatrixLatex0.getRowNameWidth());\n assertTrue(resultMatrixLatex0.getDefaultEnumerateColNames());\n assertFalse(resultMatrixLatex0.getShowAverage());\n assertEquals(\"The maximum width for the row names (0 = optimal).\", resultMatrixLatex0.rowNameWidthTipText());\n assertEquals(0, resultMatrixLatex0.getColNameWidth());\n assertFalse(resultMatrixLatex0.getDefaultEnumerateRowNames());\n assertEquals(0, resultMatrixLatex0.getDefaultRowNameWidth());\n assertFalse(resultMatrixLatex0.getDefaultShowAverage());\n assertEquals(2, resultMatrixLatex0.getMeanPrec());\n assertEquals(\"Whether to enumerate the row names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixLatex0.enumerateRowNamesTipText());\n assertEquals(0, resultMatrixLatex0.getDefaultCountWidth());\n assertFalse(resultMatrixLatex0.getEnumerateRowNames());\n assertFalse(resultMatrixLatex0.getPrintColNames());\n assertEquals(1, resultMatrixLatex0.getVisibleRowCount());\n assertEquals(2, resultMatrixLatex0.getDefaultStdDevPrec());\n assertEquals(1, resultMatrixLatex0.getRowCount());\n assertEquals(\"The number of decimals after the decimal point for the mean.\", resultMatrixLatex0.meanPrecTipText());\n assertEquals(2, resultMatrixLatex0.getDefaultMeanPrec());\n assertTrue(resultMatrixLatex0.getDefaultPrintRowNames());\n assertEquals(\"Whether to display the standard deviation column.\", resultMatrixLatex0.showStdDevTipText());\n assertFalse(resultMatrixLatex0.getDefaultPrintColNames());\n assertEquals(\"Whether to output row names or just numbers representing them.\", resultMatrixLatex0.printRowNamesTipText());\n assertTrue(resultMatrixLatex0.getPrintRowNames());\n assertEquals(\"The width of the counts (0 = optimal).\", resultMatrixLatex0.countWidthTipText());\n assertEquals(2, resultMatrixLatex0.getStdDevPrec());\n assertEquals(\"The width of the mean (0 = optimal).\", resultMatrixLatex0.meanWidthTipText());\n assertFalse(resultMatrixLatex0.getDefaultShowStdDev());\n assertEquals(0, resultMatrixLatex0.getDefaultSignificanceWidth());\n assertEquals(1, resultMatrixLatex0.getColCount());\n assertEquals(\"Generates the matrix output in LaTeX-syntax.\", resultMatrixLatex0.globalInfo());\n assertEquals(0, resultMatrixLatex0.getDefaultColNameWidth());\n assertEquals(0, resultMatrixLatex0.getDefaultMeanWidth());\n assertFalse(resultMatrixLatex0.getDefaultRemoveFilterName());\n assertEquals(\"The width of the standard deviation (0 = optimal).\", resultMatrixGnuPlot0.stdDevWidthTipText());\n assertFalse(resultMatrixGnuPlot0.getShowAverage());\n assertEquals(0, resultMatrixGnuPlot0.getStdDevWidth());\n assertEquals(\"The width of the significance indicator (0 = optimal).\", resultMatrixGnuPlot0.significanceWidthTipText());\n assertTrue(resultMatrixGnuPlot0.getDefaultPrintColNames());\n assertEquals(\"Whether to display the standard deviation column.\", resultMatrixGnuPlot0.showStdDevTipText());\n assertEquals(\"GNUPlot\", resultMatrixGnuPlot0.getDisplayName());\n assertEquals(0, resultMatrixGnuPlot0.getSignificanceWidth());\n assertFalse(resultMatrixGnuPlot0.getPrintColNames());\n assertEquals(\"Whether to remove the classname package prefixes from the filter names in datasets.\", resultMatrixGnuPlot0.removeFilterNameTipText());\n assertEquals(50, resultMatrixGnuPlot0.getDefaultRowNameWidth());\n assertFalse(resultMatrixGnuPlot0.getEnumerateRowNames());\n assertEquals(\"The width of the mean (0 = optimal).\", resultMatrixGnuPlot0.meanWidthTipText());\n assertEquals(2, resultMatrixGnuPlot0.getStdDevPrec());\n assertEquals(\"The number of decimals after the decimal point for the standard deviation.\", resultMatrixGnuPlot0.stdDevPrecTipText());\n assertTrue(resultMatrixGnuPlot0.getDefaultPrintRowNames());\n assertEquals(\"Generates output for a data and script file for GnuPlot.\", resultMatrixGnuPlot0.globalInfo());\n assertFalse(resultMatrixGnuPlot0.getShowStdDev());\n assertEquals(\"The maximum width of the column names (0 = optimal).\", resultMatrixGnuPlot0.colNameWidthTipText());\n assertEquals(0, resultMatrixGnuPlot0.getColNameWidth());\n assertEquals(0, resultMatrixGnuPlot0.getMeanWidth());\n assertEquals(0, resultMatrixGnuPlot0.getDefaultCountWidth());\n assertEquals(1, resultMatrixGnuPlot0.getRowCount());\n assertEquals(\"Whether to show the row with averages.\", resultMatrixGnuPlot0.showAverageTipText());\n assertEquals(0, resultMatrixGnuPlot0.getRowNameWidth());\n assertTrue(resultMatrixGnuPlot0.getEnumerateColNames());\n assertFalse(resultMatrixGnuPlot0.getDefaultRemoveFilterName());\n assertEquals(2, resultMatrixGnuPlot0.getDefaultStdDevPrec());\n assertEquals(0, resultMatrixGnuPlot0.getDefaultSignificanceWidth());\n assertEquals(\"The number of decimals after the decimal point for the mean.\", resultMatrixGnuPlot0.meanPrecTipText());\n assertEquals(\"Whether to enumerate the row names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixGnuPlot0.enumerateRowNamesTipText());\n assertEquals(0, resultMatrixGnuPlot0.getCountWidth());\n assertEquals(\"Whether to output row names or just numbers representing them.\", resultMatrixGnuPlot0.printRowNamesTipText());\n assertFalse(resultMatrixGnuPlot0.getDefaultEnumerateRowNames());\n assertEquals(1, resultMatrixGnuPlot0.getColCount());\n assertEquals(1, resultMatrixGnuPlot0.getVisibleRowCount());\n assertFalse(resultMatrixGnuPlot0.getRemoveFilterName());\n assertFalse(resultMatrixGnuPlot0.getDefaultShowAverage());\n assertFalse(resultMatrixGnuPlot0.getDefaultShowStdDev());\n assertEquals(\"The maximum width for the row names (0 = optimal).\", resultMatrixGnuPlot0.rowNameWidthTipText());\n assertEquals(2, resultMatrixGnuPlot0.getMeanPrec());\n assertEquals(0, resultMatrixGnuPlot0.getDefaultStdDevWidth());\n assertEquals(50, resultMatrixGnuPlot0.getDefaultColNameWidth());\n assertEquals(\"Whether to enumerate the column names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixGnuPlot0.enumerateColNamesTipText());\n assertEquals(\"Whether to output column names or just numbers representing them.\", resultMatrixGnuPlot0.printColNamesTipText());\n assertEquals(0, resultMatrixGnuPlot0.getDefaultMeanWidth());\n assertEquals(1, resultMatrixGnuPlot0.getVisibleColCount());\n assertTrue(resultMatrixGnuPlot0.getPrintRowNames());\n assertEquals(2, resultMatrixGnuPlot0.getDefaultMeanPrec());\n assertEquals(\"The width of the counts (0 = optimal).\", resultMatrixGnuPlot0.countWidthTipText());\n assertFalse(resultMatrixGnuPlot0.getDefaultEnumerateColNames());\n assertNotNull(resultMatrixGnuPlot0);\n assertEquals(0, ResultMatrix.SIGNIFICANCE_TIE);\n assertEquals(1, ResultMatrix.SIGNIFICANCE_WIN);\n assertEquals(2, ResultMatrix.SIGNIFICANCE_LOSS);\n assertEquals(1, ResultMatrix.SIGNIFICANCE_WIN);\n assertEquals(2, ResultMatrix.SIGNIFICANCE_LOSS);\n assertEquals(0, ResultMatrix.SIGNIFICANCE_TIE);\n \n String string0 = resultMatrixGnuPlot0.toStringMatrix();\n assertEquals(0, resultMatrixLatex0.getMeanWidth());\n assertEquals(\"Whether to remove the classname package prefixes from the filter names in datasets.\", resultMatrixLatex0.removeFilterNameTipText());\n assertTrue(resultMatrixLatex0.getEnumerateColNames());\n assertEquals(0, resultMatrixLatex0.getDefaultStdDevWidth());\n assertEquals(\"The number of decimals after the decimal point for the standard deviation.\", resultMatrixLatex0.stdDevPrecTipText());\n assertEquals(0, resultMatrixLatex0.getStdDevWidth());\n assertEquals(1, resultMatrixLatex0.getVisibleColCount());\n assertEquals(\"Whether to enumerate the column names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixLatex0.enumerateColNamesTipText());\n assertEquals(\"The maximum width of the column names (0 = optimal).\", resultMatrixLatex0.colNameWidthTipText());\n assertFalse(resultMatrixLatex0.getRemoveFilterName());\n assertEquals(\"Whether to output column names or just numbers representing them.\", resultMatrixLatex0.printColNamesTipText());\n assertEquals(0, resultMatrixLatex0.getCountWidth());\n assertEquals(\"The width of the standard deviation (0 = optimal).\", resultMatrixLatex0.stdDevWidthTipText());\n assertEquals(\"The width of the significance indicator (0 = optimal).\", resultMatrixLatex0.significanceWidthTipText());\n assertEquals(\"LaTeX\", resultMatrixLatex0.getDisplayName());\n assertEquals(\"Whether to show the row with averages.\", resultMatrixLatex0.showAverageTipText());\n assertEquals(0, resultMatrixLatex0.getSignificanceWidth());\n assertFalse(resultMatrixLatex0.getShowStdDev());\n assertEquals(0, resultMatrixLatex0.getRowNameWidth());\n assertTrue(resultMatrixLatex0.getDefaultEnumerateColNames());\n assertFalse(resultMatrixLatex0.getShowAverage());\n assertEquals(\"The maximum width for the row names (0 = optimal).\", resultMatrixLatex0.rowNameWidthTipText());\n assertEquals(0, resultMatrixLatex0.getColNameWidth());\n assertFalse(resultMatrixLatex0.getDefaultEnumerateRowNames());\n assertEquals(0, resultMatrixLatex0.getDefaultRowNameWidth());\n assertFalse(resultMatrixLatex0.getDefaultShowAverage());\n assertEquals(2, resultMatrixLatex0.getMeanPrec());\n assertEquals(\"Whether to enumerate the row names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixLatex0.enumerateRowNamesTipText());\n assertEquals(0, resultMatrixLatex0.getDefaultCountWidth());\n assertFalse(resultMatrixLatex0.getEnumerateRowNames());\n assertFalse(resultMatrixLatex0.getPrintColNames());\n assertEquals(1, resultMatrixLatex0.getVisibleRowCount());\n assertEquals(2, resultMatrixLatex0.getDefaultStdDevPrec());\n assertEquals(1, resultMatrixLatex0.getRowCount());\n assertEquals(\"The number of decimals after the decimal point for the mean.\", resultMatrixLatex0.meanPrecTipText());\n assertEquals(2, resultMatrixLatex0.getDefaultMeanPrec());\n assertTrue(resultMatrixLatex0.getDefaultPrintRowNames());\n assertEquals(\"Whether to display the standard deviation column.\", resultMatrixLatex0.showStdDevTipText());\n assertFalse(resultMatrixLatex0.getDefaultPrintColNames());\n assertEquals(\"Whether to output row names or just numbers representing them.\", resultMatrixLatex0.printRowNamesTipText());\n assertTrue(resultMatrixLatex0.getPrintRowNames());\n assertEquals(\"The width of the counts (0 = optimal).\", resultMatrixLatex0.countWidthTipText());\n assertEquals(2, resultMatrixLatex0.getStdDevPrec());\n assertEquals(\"The width of the mean (0 = optimal).\", resultMatrixLatex0.meanWidthTipText());\n assertFalse(resultMatrixLatex0.getDefaultShowStdDev());\n assertEquals(0, resultMatrixLatex0.getDefaultSignificanceWidth());\n assertEquals(1, resultMatrixLatex0.getColCount());\n assertEquals(\"Generates the matrix output in LaTeX-syntax.\", resultMatrixLatex0.globalInfo());\n assertEquals(0, resultMatrixLatex0.getDefaultColNameWidth());\n assertEquals(0, resultMatrixLatex0.getDefaultMeanWidth());\n assertFalse(resultMatrixLatex0.getDefaultRemoveFilterName());\n assertEquals(\"The width of the standard deviation (0 = optimal).\", resultMatrixGnuPlot0.stdDevWidthTipText());\n assertFalse(resultMatrixGnuPlot0.getShowAverage());\n assertEquals(0, resultMatrixGnuPlot0.getStdDevWidth());\n assertEquals(\"The width of the significance indicator (0 = optimal).\", resultMatrixGnuPlot0.significanceWidthTipText());\n assertTrue(resultMatrixGnuPlot0.getDefaultPrintColNames());\n assertEquals(\"Whether to display the standard deviation column.\", resultMatrixGnuPlot0.showStdDevTipText());\n assertEquals(\"GNUPlot\", resultMatrixGnuPlot0.getDisplayName());\n assertEquals(0, resultMatrixGnuPlot0.getSignificanceWidth());\n assertFalse(resultMatrixGnuPlot0.getPrintColNames());\n assertEquals(\"Whether to remove the classname package prefixes from the filter names in datasets.\", resultMatrixGnuPlot0.removeFilterNameTipText());\n assertEquals(50, resultMatrixGnuPlot0.getDefaultRowNameWidth());\n assertFalse(resultMatrixGnuPlot0.getEnumerateRowNames());\n assertEquals(\"The width of the mean (0 = optimal).\", resultMatrixGnuPlot0.meanWidthTipText());\n assertEquals(2, resultMatrixGnuPlot0.getStdDevPrec());\n assertEquals(\"The number of decimals after the decimal point for the standard deviation.\", resultMatrixGnuPlot0.stdDevPrecTipText());\n assertTrue(resultMatrixGnuPlot0.getDefaultPrintRowNames());\n assertEquals(\"Generates output for a data and script file for GnuPlot.\", resultMatrixGnuPlot0.globalInfo());\n assertFalse(resultMatrixGnuPlot0.getShowStdDev());\n assertEquals(\"The maximum width of the column names (0 = optimal).\", resultMatrixGnuPlot0.colNameWidthTipText());\n assertEquals(0, resultMatrixGnuPlot0.getColNameWidth());\n assertEquals(0, resultMatrixGnuPlot0.getMeanWidth());\n assertEquals(0, resultMatrixGnuPlot0.getDefaultCountWidth());\n assertEquals(1, resultMatrixGnuPlot0.getRowCount());\n assertEquals(\"Whether to show the row with averages.\", resultMatrixGnuPlot0.showAverageTipText());\n assertEquals(0, resultMatrixGnuPlot0.getRowNameWidth());\n assertTrue(resultMatrixGnuPlot0.getEnumerateColNames());\n assertFalse(resultMatrixGnuPlot0.getDefaultRemoveFilterName());\n assertEquals(2, resultMatrixGnuPlot0.getDefaultStdDevPrec());\n assertEquals(0, resultMatrixGnuPlot0.getDefaultSignificanceWidth());\n assertEquals(\"The number of decimals after the decimal point for the mean.\", resultMatrixGnuPlot0.meanPrecTipText());\n assertEquals(\"Whether to enumerate the row names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixGnuPlot0.enumerateRowNamesTipText());\n assertEquals(0, resultMatrixGnuPlot0.getCountWidth());\n assertEquals(\"Whether to output row names or just numbers representing them.\", resultMatrixGnuPlot0.printRowNamesTipText());\n assertFalse(resultMatrixGnuPlot0.getDefaultEnumerateRowNames());\n assertEquals(1, resultMatrixGnuPlot0.getColCount());\n assertEquals(1, resultMatrixGnuPlot0.getVisibleRowCount());\n assertFalse(resultMatrixGnuPlot0.getRemoveFilterName());\n assertFalse(resultMatrixGnuPlot0.getDefaultShowAverage());\n assertFalse(resultMatrixGnuPlot0.getDefaultShowStdDev());\n assertEquals(\"The maximum width for the row names (0 = optimal).\", resultMatrixGnuPlot0.rowNameWidthTipText());\n assertEquals(2, resultMatrixGnuPlot0.getMeanPrec());\n assertEquals(0, resultMatrixGnuPlot0.getDefaultStdDevWidth());\n assertEquals(50, resultMatrixGnuPlot0.getDefaultColNameWidth());\n assertEquals(\"Whether to enumerate the column names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixGnuPlot0.enumerateColNamesTipText());\n assertEquals(\"Whether to output column names or just numbers representing them.\", resultMatrixGnuPlot0.printColNamesTipText());\n assertEquals(0, resultMatrixGnuPlot0.getDefaultMeanWidth());\n assertEquals(1, resultMatrixGnuPlot0.getVisibleColCount());\n assertTrue(resultMatrixGnuPlot0.getPrintRowNames());\n assertEquals(2, resultMatrixGnuPlot0.getDefaultMeanPrec());\n assertEquals(\"The width of the counts (0 = optimal).\", resultMatrixGnuPlot0.countWidthTipText());\n assertFalse(resultMatrixGnuPlot0.getDefaultEnumerateColNames());\n assertNotNull(string0);\n assertEquals(0, ResultMatrix.SIGNIFICANCE_TIE);\n assertEquals(1, ResultMatrix.SIGNIFICANCE_WIN);\n assertEquals(2, ResultMatrix.SIGNIFICANCE_LOSS);\n assertEquals(1, ResultMatrix.SIGNIFICANCE_WIN);\n assertEquals(2, ResultMatrix.SIGNIFICANCE_LOSS);\n assertEquals(0, ResultMatrix.SIGNIFICANCE_TIE);\n assertEquals(\"\\n##################\\n# file: plot.dat #\\n##################\\n# generated by WEKA 3.7.7\\n# contains the data for the plot\\n\\n# key for the x-axis\\n# 1 - row0\\n\\n# data for the plot\\n1 ''\\n#######\\n# end #\\n#######\\n\\n##################\\n# file: plot.scr #\\n##################\\n# generated by WEKA 3.7.7\\n# script to plot the data\\n\\n# display it in a window:\\nset terminal x11\\nset output\\n\\n# to display all data rows:\\nset xrange [0:2]\\n\\n# axis labels, e.g.:\\n#set xlabel \\\"Datasets\\\"\\n#set ylabel \\\"Accuracy in %\\\"\\n\\n# the plot commands\\nplot \\\"plot.dat\\\" using 1:2 with lines title \\\"(1)\\\"\\n\\n# generate ps:\\n#set terminal postscript\\n#set output \\\"plot.ps\\\"\\n#replot\\n\\n# generate png:\\n#set terminal png size 800,600\\n#set output \\\"plot.png\\\"\\n#replot\\n\\n# wait for user to hit <Return>\\npause -1\\n#######\\n# end #\\n#######\\n\", string0);\n \n resultMatrixLatex0.m_ColOrder = intArray0;\n assertEquals(0, resultMatrixLatex0.getMeanWidth());\n assertEquals(\"Whether to remove the classname package prefixes from the filter names in datasets.\", resultMatrixLatex0.removeFilterNameTipText());\n assertTrue(resultMatrixLatex0.getEnumerateColNames());\n assertEquals(0, resultMatrixLatex0.getDefaultStdDevWidth());\n assertEquals(\"The number of decimals after the decimal point for the standard deviation.\", resultMatrixLatex0.stdDevPrecTipText());\n assertEquals(0, resultMatrixLatex0.getStdDevWidth());\n assertEquals(1, resultMatrixLatex0.getVisibleColCount());\n assertEquals(\"Whether to enumerate the column names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixLatex0.enumerateColNamesTipText());\n assertEquals(\"The maximum width of the column names (0 = optimal).\", resultMatrixLatex0.colNameWidthTipText());\n assertFalse(resultMatrixLatex0.getRemoveFilterName());\n assertEquals(\"Whether to output column names or just numbers representing them.\", resultMatrixLatex0.printColNamesTipText());\n assertEquals(0, resultMatrixLatex0.getCountWidth());\n assertEquals(\"The width of the standard deviation (0 = optimal).\", resultMatrixLatex0.stdDevWidthTipText());\n assertEquals(\"The width of the significance indicator (0 = optimal).\", resultMatrixLatex0.significanceWidthTipText());\n assertEquals(\"LaTeX\", resultMatrixLatex0.getDisplayName());\n assertEquals(\"Whether to show the row with averages.\", resultMatrixLatex0.showAverageTipText());\n assertEquals(0, resultMatrixLatex0.getSignificanceWidth());\n assertFalse(resultMatrixLatex0.getShowStdDev());\n assertEquals(0, resultMatrixLatex0.getRowNameWidth());\n assertTrue(resultMatrixLatex0.getDefaultEnumerateColNames());\n assertFalse(resultMatrixLatex0.getShowAverage());\n assertEquals(\"The maximum width for the row names (0 = optimal).\", resultMatrixLatex0.rowNameWidthTipText());\n assertEquals(0, resultMatrixLatex0.getColNameWidth());\n assertFalse(resultMatrixLatex0.getDefaultEnumerateRowNames());\n assertEquals(0, resultMatrixLatex0.getDefaultRowNameWidth());\n assertFalse(resultMatrixLatex0.getDefaultShowAverage());\n assertEquals(2, resultMatrixLatex0.getMeanPrec());\n assertEquals(\"Whether to enumerate the row names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixLatex0.enumerateRowNamesTipText());\n assertEquals(0, resultMatrixLatex0.getDefaultCountWidth());\n assertFalse(resultMatrixLatex0.getEnumerateRowNames());\n assertFalse(resultMatrixLatex0.getPrintColNames());\n assertEquals(1, resultMatrixLatex0.getVisibleRowCount());\n assertEquals(2, resultMatrixLatex0.getDefaultStdDevPrec());\n assertEquals(1, resultMatrixLatex0.getRowCount());\n assertEquals(\"The number of decimals after the decimal point for the mean.\", resultMatrixLatex0.meanPrecTipText());\n assertEquals(2, resultMatrixLatex0.getDefaultMeanPrec());\n assertTrue(resultMatrixLatex0.getDefaultPrintRowNames());\n assertEquals(\"Whether to display the standard deviation column.\", resultMatrixLatex0.showStdDevTipText());\n assertFalse(resultMatrixLatex0.getDefaultPrintColNames());\n assertEquals(\"Whether to output row names or just numbers representing them.\", resultMatrixLatex0.printRowNamesTipText());\n assertTrue(resultMatrixLatex0.getPrintRowNames());\n assertEquals(\"The width of the counts (0 = optimal).\", resultMatrixLatex0.countWidthTipText());\n assertEquals(2, resultMatrixLatex0.getStdDevPrec());\n assertEquals(\"The width of the mean (0 = optimal).\", resultMatrixLatex0.meanWidthTipText());\n assertFalse(resultMatrixLatex0.getDefaultShowStdDev());\n assertEquals(0, resultMatrixLatex0.getDefaultSignificanceWidth());\n assertEquals(1, resultMatrixLatex0.getColCount());\n assertEquals(\"Generates the matrix output in LaTeX-syntax.\", resultMatrixLatex0.globalInfo());\n assertEquals(0, resultMatrixLatex0.getDefaultColNameWidth());\n assertEquals(0, resultMatrixLatex0.getDefaultMeanWidth());\n assertFalse(resultMatrixLatex0.getDefaultRemoveFilterName());\n \n ResultMatrixCSV resultMatrixCSV0 = new ResultMatrixCSV(1, 1);\n assertFalse(resultMatrixCSV0.getDefaultShowStdDev());\n assertEquals(\"Whether to output row names or just numbers representing them.\", resultMatrixCSV0.printRowNamesTipText());\n assertEquals(\"The width of the counts (0 = optimal).\", resultMatrixCSV0.countWidthTipText());\n assertEquals(0, resultMatrixCSV0.getDefaultColNameWidth());\n assertEquals(\"The maximum width for the row names (0 = optimal).\", resultMatrixCSV0.rowNameWidthTipText());\n assertEquals(\"The number of decimals after the decimal point for the mean.\", resultMatrixCSV0.meanPrecTipText());\n assertEquals(0, resultMatrixCSV0.getDefaultSignificanceWidth());\n assertEquals(\"Generates the matrix in CSV ('comma-separated values') format.\", resultMatrixCSV0.globalInfo());\n assertEquals(0, resultMatrixCSV0.getCountWidth());\n assertFalse(resultMatrixCSV0.getDefaultRemoveFilterName());\n assertFalse(resultMatrixCSV0.getRemoveFilterName());\n assertEquals(1, resultMatrixCSV0.getColCount());\n assertEquals(1, resultMatrixCSV0.getVisibleRowCount());\n assertEquals(\"Whether to enumerate the row names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixCSV0.enumerateRowNamesTipText());\n assertEquals(0, resultMatrixCSV0.getColNameWidth());\n assertFalse(resultMatrixCSV0.getDefaultEnumerateRowNames());\n assertEquals(0, resultMatrixCSV0.getDefaultMeanWidth());\n assertEquals(\"The number of decimals after the decimal point for the standard deviation.\", resultMatrixCSV0.stdDevPrecTipText());\n assertEquals(\"Whether to enumerate the column names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixCSV0.enumerateColNamesTipText());\n assertEquals(2, resultMatrixCSV0.getMeanPrec());\n assertEquals(\"Whether to output column names or just numbers representing them.\", resultMatrixCSV0.printColNamesTipText());\n assertFalse(resultMatrixCSV0.getDefaultPrintColNames());\n assertEquals(\"Whether to remove the classname package prefixes from the filter names in datasets.\", resultMatrixCSV0.removeFilterNameTipText());\n assertEquals(\"The width of the significance indicator (0 = optimal).\", resultMatrixCSV0.significanceWidthTipText());\n assertEquals(0, resultMatrixCSV0.getDefaultStdDevWidth());\n assertTrue(resultMatrixCSV0.getPrintRowNames());\n assertEquals(2, resultMatrixCSV0.getDefaultMeanPrec());\n assertEquals(1, resultMatrixCSV0.getVisibleColCount());\n assertEquals(2, resultMatrixCSV0.getStdDevPrec());\n assertEquals(\"The width of the mean (0 = optimal).\", resultMatrixCSV0.meanWidthTipText());\n assertFalse(resultMatrixCSV0.getShowStdDev());\n assertTrue(resultMatrixCSV0.getDefaultPrintRowNames());\n assertEquals(\"Whether to display the standard deviation column.\", resultMatrixCSV0.showStdDevTipText());\n assertEquals(\"The width of the standard deviation (0 = optimal).\", resultMatrixCSV0.stdDevWidthTipText());\n assertFalse(resultMatrixCSV0.getPrintColNames());\n assertEquals(0, resultMatrixCSV0.getSignificanceWidth());\n assertEquals(25, resultMatrixCSV0.getRowNameWidth());\n assertFalse(resultMatrixCSV0.getEnumerateRowNames());\n assertFalse(resultMatrixCSV0.getDefaultShowAverage());\n assertTrue(resultMatrixCSV0.getDefaultEnumerateColNames());\n assertEquals(0, resultMatrixCSV0.getMeanWidth());\n assertTrue(resultMatrixCSV0.getEnumerateColNames());\n assertEquals(25, resultMatrixCSV0.getDefaultRowNameWidth());\n assertEquals(0, resultMatrixCSV0.getDefaultCountWidth());\n assertFalse(resultMatrixCSV0.getShowAverage());\n assertEquals(1, resultMatrixCSV0.getRowCount());\n assertEquals(2, resultMatrixCSV0.getDefaultStdDevPrec());\n assertEquals(\"The maximum width of the column names (0 = optimal).\", resultMatrixCSV0.colNameWidthTipText());\n assertEquals(0, resultMatrixCSV0.getStdDevWidth());\n assertEquals(\"Whether to show the row with averages.\", resultMatrixCSV0.showAverageTipText());\n assertEquals(\"CSV\", resultMatrixCSV0.getDisplayName());\n assertNotNull(resultMatrixCSV0);\n assertEquals(2, ResultMatrix.SIGNIFICANCE_LOSS);\n assertEquals(1, ResultMatrix.SIGNIFICANCE_WIN);\n assertEquals(0, ResultMatrix.SIGNIFICANCE_TIE);\n \n resultMatrixCSV0.m_EnumerateRowNames = true;\n assertFalse(resultMatrixCSV0.getDefaultShowStdDev());\n assertEquals(\"Whether to output row names or just numbers representing them.\", resultMatrixCSV0.printRowNamesTipText());\n assertEquals(\"The width of the counts (0 = optimal).\", resultMatrixCSV0.countWidthTipText());\n assertEquals(0, resultMatrixCSV0.getDefaultColNameWidth());\n assertEquals(\"The maximum width for the row names (0 = optimal).\", resultMatrixCSV0.rowNameWidthTipText());\n assertEquals(\"The number of decimals after the decimal point for the mean.\", resultMatrixCSV0.meanPrecTipText());\n assertTrue(resultMatrixCSV0.getEnumerateRowNames());\n assertEquals(0, resultMatrixCSV0.getDefaultSignificanceWidth());\n assertEquals(\"Generates the matrix in CSV ('comma-separated values') format.\", resultMatrixCSV0.globalInfo());\n assertEquals(0, resultMatrixCSV0.getCountWidth());\n assertFalse(resultMatrixCSV0.getDefaultRemoveFilterName());\n assertFalse(resultMatrixCSV0.getRemoveFilterName());\n assertEquals(1, resultMatrixCSV0.getColCount());\n assertEquals(1, resultMatrixCSV0.getVisibleRowCount());\n assertEquals(\"Whether to enumerate the row names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixCSV0.enumerateRowNamesTipText());\n assertEquals(0, resultMatrixCSV0.getColNameWidth());\n assertFalse(resultMatrixCSV0.getDefaultEnumerateRowNames());\n assertEquals(0, resultMatrixCSV0.getDefaultMeanWidth());\n assertEquals(\"The number of decimals after the decimal point for the standard deviation.\", resultMatrixCSV0.stdDevPrecTipText());\n assertEquals(\"Whether to enumerate the column names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixCSV0.enumerateColNamesTipText());\n assertEquals(2, resultMatrixCSV0.getMeanPrec());\n assertEquals(\"Whether to output column names or just numbers representing them.\", resultMatrixCSV0.printColNamesTipText());\n assertFalse(resultMatrixCSV0.getDefaultPrintColNames());\n assertEquals(\"Whether to remove the classname package prefixes from the filter names in datasets.\", resultMatrixCSV0.removeFilterNameTipText());\n assertEquals(\"The width of the significance indicator (0 = optimal).\", resultMatrixCSV0.significanceWidthTipText());\n assertEquals(0, resultMatrixCSV0.getDefaultStdDevWidth());\n assertTrue(resultMatrixCSV0.getPrintRowNames());\n assertEquals(2, resultMatrixCSV0.getDefaultMeanPrec());\n assertEquals(1, resultMatrixCSV0.getVisibleColCount());\n assertEquals(2, resultMatrixCSV0.getStdDevPrec());\n assertEquals(\"The width of the mean (0 = optimal).\", resultMatrixCSV0.meanWidthTipText());\n assertFalse(resultMatrixCSV0.getShowStdDev());\n assertTrue(resultMatrixCSV0.getDefaultPrintRowNames());\n assertEquals(\"Whether to display the standard deviation column.\", resultMatrixCSV0.showStdDevTipText());\n assertEquals(\"The width of the standard deviation (0 = optimal).\", resultMatrixCSV0.stdDevWidthTipText());\n assertFalse(resultMatrixCSV0.getPrintColNames());\n assertEquals(0, resultMatrixCSV0.getSignificanceWidth());\n assertEquals(25, resultMatrixCSV0.getRowNameWidth());\n assertFalse(resultMatrixCSV0.getDefaultShowAverage());\n assertTrue(resultMatrixCSV0.getDefaultEnumerateColNames());\n assertEquals(0, resultMatrixCSV0.getMeanWidth());\n assertTrue(resultMatrixCSV0.getEnumerateColNames());\n assertEquals(25, resultMatrixCSV0.getDefaultRowNameWidth());\n assertEquals(0, resultMatrixCSV0.getDefaultCountWidth());\n assertFalse(resultMatrixCSV0.getShowAverage());\n assertEquals(1, resultMatrixCSV0.getRowCount());\n assertEquals(2, resultMatrixCSV0.getDefaultStdDevPrec());\n assertEquals(\"The maximum width of the column names (0 = optimal).\", resultMatrixCSV0.colNameWidthTipText());\n assertEquals(0, resultMatrixCSV0.getStdDevWidth());\n assertEquals(\"Whether to show the row with averages.\", resultMatrixCSV0.showAverageTipText());\n assertEquals(\"CSV\", resultMatrixCSV0.getDisplayName());\n \n resultMatrixCSV0.clearHeader();\n assertFalse(resultMatrixCSV0.getDefaultShowStdDev());\n assertEquals(\"Whether to output row names or just numbers representing them.\", resultMatrixCSV0.printRowNamesTipText());\n assertEquals(\"The width of the counts (0 = optimal).\", resultMatrixCSV0.countWidthTipText());\n assertEquals(0, resultMatrixCSV0.getDefaultColNameWidth());\n assertEquals(\"The maximum width for the row names (0 = optimal).\", resultMatrixCSV0.rowNameWidthTipText());\n assertEquals(\"The number of decimals after the decimal point for the mean.\", resultMatrixCSV0.meanPrecTipText());\n assertTrue(resultMatrixCSV0.getEnumerateRowNames());\n assertEquals(0, resultMatrixCSV0.getDefaultSignificanceWidth());\n assertEquals(\"Generates the matrix in CSV ('comma-separated values') format.\", resultMatrixCSV0.globalInfo());\n assertEquals(0, resultMatrixCSV0.getCountWidth());\n assertFalse(resultMatrixCSV0.getDefaultRemoveFilterName());\n assertFalse(resultMatrixCSV0.getRemoveFilterName());\n assertEquals(1, resultMatrixCSV0.getColCount());\n assertEquals(1, resultMatrixCSV0.getVisibleRowCount());\n assertEquals(\"Whether to enumerate the row names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixCSV0.enumerateRowNamesTipText());\n assertEquals(0, resultMatrixCSV0.getColNameWidth());\n assertFalse(resultMatrixCSV0.getDefaultEnumerateRowNames());\n assertEquals(0, resultMatrixCSV0.getDefaultMeanWidth());\n assertEquals(\"The number of decimals after the decimal point for the standard deviation.\", resultMatrixCSV0.stdDevPrecTipText());\n assertEquals(\"Whether to enumerate the column names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixCSV0.enumerateColNamesTipText());\n assertEquals(2, resultMatrixCSV0.getMeanPrec());\n assertEquals(\"Whether to output column names or just numbers representing them.\", resultMatrixCSV0.printColNamesTipText());\n assertFalse(resultMatrixCSV0.getDefaultPrintColNames());\n assertEquals(\"Whether to remove the classname package prefixes from the filter names in datasets.\", resultMatrixCSV0.removeFilterNameTipText());\n assertEquals(\"The width of the significance indicator (0 = optimal).\", resultMatrixCSV0.significanceWidthTipText());\n assertEquals(0, resultMatrixCSV0.getDefaultStdDevWidth());\n assertTrue(resultMatrixCSV0.getPrintRowNames());\n assertEquals(2, resultMatrixCSV0.getDefaultMeanPrec());\n assertEquals(1, resultMatrixCSV0.getVisibleColCount());\n assertEquals(2, resultMatrixCSV0.getStdDevPrec());\n assertEquals(\"The width of the mean (0 = optimal).\", resultMatrixCSV0.meanWidthTipText());\n assertFalse(resultMatrixCSV0.getShowStdDev());\n assertTrue(resultMatrixCSV0.getDefaultPrintRowNames());\n assertEquals(\"Whether to display the standard deviation column.\", resultMatrixCSV0.showStdDevTipText());\n assertEquals(\"The width of the standard deviation (0 = optimal).\", resultMatrixCSV0.stdDevWidthTipText());\n assertFalse(resultMatrixCSV0.getPrintColNames());\n assertEquals(0, resultMatrixCSV0.getSignificanceWidth());\n assertEquals(25, resultMatrixCSV0.getRowNameWidth());\n assertFalse(resultMatrixCSV0.getDefaultShowAverage());\n assertTrue(resultMatrixCSV0.getDefaultEnumerateColNames());\n assertEquals(0, resultMatrixCSV0.getMeanWidth());\n assertTrue(resultMatrixCSV0.getEnumerateColNames());\n assertEquals(25, resultMatrixCSV0.getDefaultRowNameWidth());\n assertEquals(0, resultMatrixCSV0.getDefaultCountWidth());\n assertFalse(resultMatrixCSV0.getShowAverage());\n assertEquals(1, resultMatrixCSV0.getRowCount());\n assertEquals(2, resultMatrixCSV0.getDefaultStdDevPrec());\n assertEquals(\"The maximum width of the column names (0 = optimal).\", resultMatrixCSV0.colNameWidthTipText());\n assertEquals(0, resultMatrixCSV0.getStdDevWidth());\n assertEquals(\"Whether to show the row with averages.\", resultMatrixCSV0.showAverageTipText());\n assertEquals(\"CSV\", resultMatrixCSV0.getDisplayName());\n assertEquals(2, ResultMatrix.SIGNIFICANCE_LOSS);\n assertEquals(1, ResultMatrix.SIGNIFICANCE_WIN);\n assertEquals(0, ResultMatrix.SIGNIFICANCE_TIE);\n \n resultMatrixGnuPlot0.assign(resultMatrixCSV0);\n assertEquals(0, resultMatrixLatex0.getMeanWidth());\n assertEquals(\"Whether to remove the classname package prefixes from the filter names in datasets.\", resultMatrixLatex0.removeFilterNameTipText());\n assertTrue(resultMatrixLatex0.getEnumerateColNames());\n assertEquals(0, resultMatrixLatex0.getDefaultStdDevWidth());\n assertEquals(\"The number of decimals after the decimal point for the standard deviation.\", resultMatrixLatex0.stdDevPrecTipText());\n assertEquals(0, resultMatrixLatex0.getStdDevWidth());\n assertEquals(1, resultMatrixLatex0.getVisibleColCount());\n assertEquals(\"Whether to enumerate the column names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixLatex0.enumerateColNamesTipText());\n assertEquals(\"The maximum width of the column names (0 = optimal).\", resultMatrixLatex0.colNameWidthTipText());\n assertFalse(resultMatrixLatex0.getRemoveFilterName());\n assertEquals(\"Whether to output column names or just numbers representing them.\", resultMatrixLatex0.printColNamesTipText());\n assertEquals(0, resultMatrixLatex0.getCountWidth());\n assertEquals(\"The width of the standard deviation (0 = optimal).\", resultMatrixLatex0.stdDevWidthTipText());\n assertEquals(\"The width of the significance indicator (0 = optimal).\", resultMatrixLatex0.significanceWidthTipText());\n assertEquals(\"LaTeX\", resultMatrixLatex0.getDisplayName());\n assertEquals(\"Whether to show the row with averages.\", resultMatrixLatex0.showAverageTipText());\n assertEquals(0, resultMatrixLatex0.getSignificanceWidth());\n assertFalse(resultMatrixLatex0.getShowStdDev());\n assertEquals(0, resultMatrixLatex0.getRowNameWidth());\n assertTrue(resultMatrixLatex0.getDefaultEnumerateColNames());\n assertFalse(resultMatrixLatex0.getShowAverage());\n assertEquals(\"The maximum width for the row names (0 = optimal).\", resultMatrixLatex0.rowNameWidthTipText());\n assertEquals(0, resultMatrixLatex0.getColNameWidth());\n assertFalse(resultMatrixLatex0.getDefaultEnumerateRowNames());\n assertEquals(0, resultMatrixLatex0.getDefaultRowNameWidth());\n assertFalse(resultMatrixLatex0.getDefaultShowAverage());\n assertEquals(2, resultMatrixLatex0.getMeanPrec());\n assertEquals(\"Whether to enumerate the row names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixLatex0.enumerateRowNamesTipText());\n assertEquals(0, resultMatrixLatex0.getDefaultCountWidth());\n assertFalse(resultMatrixLatex0.getEnumerateRowNames());\n assertFalse(resultMatrixLatex0.getPrintColNames());\n assertEquals(1, resultMatrixLatex0.getVisibleRowCount());\n assertEquals(2, resultMatrixLatex0.getDefaultStdDevPrec());\n assertEquals(1, resultMatrixLatex0.getRowCount());\n assertEquals(\"The number of decimals after the decimal point for the mean.\", resultMatrixLatex0.meanPrecTipText());\n assertEquals(2, resultMatrixLatex0.getDefaultMeanPrec());\n assertTrue(resultMatrixLatex0.getDefaultPrintRowNames());\n assertEquals(\"Whether to display the standard deviation column.\", resultMatrixLatex0.showStdDevTipText());\n assertFalse(resultMatrixLatex0.getDefaultPrintColNames());\n assertEquals(\"Whether to output row names or just numbers representing them.\", resultMatrixLatex0.printRowNamesTipText());\n assertTrue(resultMatrixLatex0.getPrintRowNames());\n assertEquals(\"The width of the counts (0 = optimal).\", resultMatrixLatex0.countWidthTipText());\n assertEquals(2, resultMatrixLatex0.getStdDevPrec());\n assertEquals(\"The width of the mean (0 = optimal).\", resultMatrixLatex0.meanWidthTipText());\n assertFalse(resultMatrixLatex0.getDefaultShowStdDev());\n assertEquals(0, resultMatrixLatex0.getDefaultSignificanceWidth());\n assertEquals(1, resultMatrixLatex0.getColCount());\n assertEquals(\"Generates the matrix output in LaTeX-syntax.\", resultMatrixLatex0.globalInfo());\n assertEquals(0, resultMatrixLatex0.getDefaultColNameWidth());\n assertEquals(0, resultMatrixLatex0.getDefaultMeanWidth());\n assertFalse(resultMatrixLatex0.getDefaultRemoveFilterName());\n assertEquals(\"The width of the standard deviation (0 = optimal).\", resultMatrixGnuPlot0.stdDevWidthTipText());\n assertFalse(resultMatrixGnuPlot0.getShowAverage());\n assertEquals(0, resultMatrixGnuPlot0.getStdDevWidth());\n assertEquals(\"The width of the significance indicator (0 = optimal).\", resultMatrixGnuPlot0.significanceWidthTipText());\n assertTrue(resultMatrixGnuPlot0.getDefaultPrintColNames());\n assertEquals(\"Whether to display the standard deviation column.\", resultMatrixGnuPlot0.showStdDevTipText());\n assertEquals(\"GNUPlot\", resultMatrixGnuPlot0.getDisplayName());\n assertEquals(0, resultMatrixGnuPlot0.getSignificanceWidth());\n assertFalse(resultMatrixGnuPlot0.getPrintColNames());\n assertEquals(\"Whether to remove the classname package prefixes from the filter names in datasets.\", resultMatrixGnuPlot0.removeFilterNameTipText());\n assertEquals(50, resultMatrixGnuPlot0.getDefaultRowNameWidth());\n assertEquals(\"The width of the mean (0 = optimal).\", resultMatrixGnuPlot0.meanWidthTipText());\n assertEquals(2, resultMatrixGnuPlot0.getStdDevPrec());\n assertEquals(\"The number of decimals after the decimal point for the standard deviation.\", resultMatrixGnuPlot0.stdDevPrecTipText());\n assertTrue(resultMatrixGnuPlot0.getDefaultPrintRowNames());\n assertEquals(\"Generates output for a data and script file for GnuPlot.\", resultMatrixGnuPlot0.globalInfo());\n assertFalse(resultMatrixGnuPlot0.getShowStdDev());\n assertEquals(\"The maximum width of the column names (0 = optimal).\", resultMatrixGnuPlot0.colNameWidthTipText());\n assertEquals(0, resultMatrixGnuPlot0.getColNameWidth());\n assertEquals(0, resultMatrixGnuPlot0.getMeanWidth());\n assertEquals(0, resultMatrixGnuPlot0.getDefaultCountWidth());\n assertEquals(1, resultMatrixGnuPlot0.getRowCount());\n assertEquals(25, resultMatrixGnuPlot0.getRowNameWidth());\n assertEquals(\"Whether to show the row with averages.\", resultMatrixGnuPlot0.showAverageTipText());\n assertTrue(resultMatrixGnuPlot0.getEnumerateColNames());\n assertFalse(resultMatrixGnuPlot0.getDefaultRemoveFilterName());\n assertEquals(2, resultMatrixGnuPlot0.getDefaultStdDevPrec());\n assertEquals(0, resultMatrixGnuPlot0.getDefaultSignificanceWidth());\n assertEquals(\"The number of decimals after the decimal point for the mean.\", resultMatrixGnuPlot0.meanPrecTipText());\n assertEquals(\"Whether to enumerate the row names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixGnuPlot0.enumerateRowNamesTipText());\n assertTrue(resultMatrixGnuPlot0.getEnumerateRowNames());\n assertEquals(0, resultMatrixGnuPlot0.getCountWidth());\n assertEquals(\"Whether to output row names or just numbers representing them.\", resultMatrixGnuPlot0.printRowNamesTipText());\n assertFalse(resultMatrixGnuPlot0.getDefaultEnumerateRowNames());\n assertEquals(1, resultMatrixGnuPlot0.getColCount());\n assertEquals(1, resultMatrixGnuPlot0.getVisibleRowCount());\n assertFalse(resultMatrixGnuPlot0.getRemoveFilterName());\n assertFalse(resultMatrixGnuPlot0.getDefaultShowAverage());\n assertFalse(resultMatrixGnuPlot0.getDefaultShowStdDev());\n assertEquals(\"The maximum width for the row names (0 = optimal).\", resultMatrixGnuPlot0.rowNameWidthTipText());\n assertEquals(2, resultMatrixGnuPlot0.getMeanPrec());\n assertEquals(0, resultMatrixGnuPlot0.getDefaultStdDevWidth());\n assertEquals(50, resultMatrixGnuPlot0.getDefaultColNameWidth());\n assertEquals(\"Whether to enumerate the column names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixGnuPlot0.enumerateColNamesTipText());\n assertEquals(\"Whether to output column names or just numbers representing them.\", resultMatrixGnuPlot0.printColNamesTipText());\n assertEquals(0, resultMatrixGnuPlot0.getDefaultMeanWidth());\n assertEquals(1, resultMatrixGnuPlot0.getVisibleColCount());\n assertTrue(resultMatrixGnuPlot0.getPrintRowNames());\n assertEquals(2, resultMatrixGnuPlot0.getDefaultMeanPrec());\n assertEquals(\"The width of the counts (0 = optimal).\", resultMatrixGnuPlot0.countWidthTipText());\n assertFalse(resultMatrixGnuPlot0.getDefaultEnumerateColNames());\n assertFalse(resultMatrixCSV0.getDefaultShowStdDev());\n assertEquals(\"Whether to output row names or just numbers representing them.\", resultMatrixCSV0.printRowNamesTipText());\n assertEquals(\"The width of the counts (0 = optimal).\", resultMatrixCSV0.countWidthTipText());\n assertEquals(0, resultMatrixCSV0.getDefaultColNameWidth());\n assertEquals(\"The maximum width for the row names (0 = optimal).\", resultMatrixCSV0.rowNameWidthTipText());\n assertEquals(\"The number of decimals after the decimal point for the mean.\", resultMatrixCSV0.meanPrecTipText());\n assertTrue(resultMatrixCSV0.getEnumerateRowNames());\n assertEquals(0, resultMatrixCSV0.getDefaultSignificanceWidth());\n assertEquals(\"Generates the matrix in CSV ('comma-separated values') format.\", resultMatrixCSV0.globalInfo());\n assertEquals(0, resultMatrixCSV0.getCountWidth());\n assertFalse(resultMatrixCSV0.getDefaultRemoveFilterName());\n assertFalse(resultMatrixCSV0.getRemoveFilterName());\n assertEquals(1, resultMatrixCSV0.getColCount());\n assertEquals(1, resultMatrixCSV0.getVisibleRowCount());\n assertEquals(\"Whether to enumerate the row names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixCSV0.enumerateRowNamesTipText());\n assertEquals(0, resultMatrixCSV0.getColNameWidth());\n assertFalse(resultMatrixCSV0.getDefaultEnumerateRowNames());\n assertEquals(0, resultMatrixCSV0.getDefaultMeanWidth());\n assertEquals(\"The number of decimals after the decimal point for the standard deviation.\", resultMatrixCSV0.stdDevPrecTipText());\n assertEquals(\"Whether to enumerate the column names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixCSV0.enumerateColNamesTipText());\n assertEquals(2, resultMatrixCSV0.getMeanPrec());\n assertEquals(\"Whether to output column names or just numbers representing them.\", resultMatrixCSV0.printColNamesTipText());\n assertFalse(resultMatrixCSV0.getDefaultPrintColNames());\n assertEquals(\"Whether to remove the classname package prefixes from the filter names in datasets.\", resultMatrixCSV0.removeFilterNameTipText());\n assertEquals(\"The width of the significance indicator (0 = optimal).\", resultMatrixCSV0.significanceWidthTipText());\n assertEquals(0, resultMatrixCSV0.getDefaultStdDevWidth());\n assertTrue(resultMatrixCSV0.getPrintRowNames());\n assertEquals(2, resultMatrixCSV0.getDefaultMeanPrec());\n assertEquals(1, resultMatrixCSV0.getVisibleColCount());\n assertEquals(2, resultMatrixCSV0.getStdDevPrec());\n assertEquals(\"The width of the mean (0 = optimal).\", resultMatrixCSV0.meanWidthTipText());\n assertFalse(resultMatrixCSV0.getShowStdDev());\n assertTrue(resultMatrixCSV0.getDefaultPrintRowNames());\n assertEquals(\"Whether to display the standard deviation column.\", resultMatrixCSV0.showStdDevTipText());\n assertEquals(\"The width of the standard deviation (0 = optimal).\", resultMatrixCSV0.stdDevWidthTipText());\n assertFalse(resultMatrixCSV0.getPrintColNames());\n assertEquals(0, resultMatrixCSV0.getSignificanceWidth());\n assertEquals(25, resultMatrixCSV0.getRowNameWidth());\n assertFalse(resultMatrixCSV0.getDefaultShowAverage());\n assertTrue(resultMatrixCSV0.getDefaultEnumerateColNames());\n assertEquals(0, resultMatrixCSV0.getMeanWidth());\n assertTrue(resultMatrixCSV0.getEnumerateColNames());\n assertEquals(25, resultMatrixCSV0.getDefaultRowNameWidth());\n assertEquals(0, resultMatrixCSV0.getDefaultCountWidth());\n assertFalse(resultMatrixCSV0.getShowAverage());\n assertEquals(1, resultMatrixCSV0.getRowCount());\n assertEquals(2, resultMatrixCSV0.getDefaultStdDevPrec());\n assertEquals(\"The maximum width of the column names (0 = optimal).\", resultMatrixCSV0.colNameWidthTipText());\n assertEquals(0, resultMatrixCSV0.getStdDevWidth());\n assertEquals(\"Whether to show the row with averages.\", resultMatrixCSV0.showAverageTipText());\n assertEquals(\"CSV\", resultMatrixCSV0.getDisplayName());\n assertEquals(0, ResultMatrix.SIGNIFICANCE_TIE);\n assertEquals(1, ResultMatrix.SIGNIFICANCE_WIN);\n assertEquals(2, ResultMatrix.SIGNIFICANCE_LOSS);\n assertEquals(1, ResultMatrix.SIGNIFICANCE_WIN);\n assertEquals(2, ResultMatrix.SIGNIFICANCE_LOSS);\n assertEquals(0, ResultMatrix.SIGNIFICANCE_TIE);\n assertEquals(2, ResultMatrix.SIGNIFICANCE_LOSS);\n assertEquals(1, ResultMatrix.SIGNIFICANCE_WIN);\n assertEquals(0, ResultMatrix.SIGNIFICANCE_TIE);\n \n resultMatrixGnuPlot0.setCountWidth(661);\n assertEquals(0, resultMatrixLatex0.getMeanWidth());\n assertEquals(\"Whether to remove the classname package prefixes from the filter names in datasets.\", resultMatrixLatex0.removeFilterNameTipText());\n assertTrue(resultMatrixLatex0.getEnumerateColNames());\n assertEquals(0, resultMatrixLatex0.getDefaultStdDevWidth());\n assertEquals(\"The number of decimals after the decimal point for the standard deviation.\", resultMatrixLatex0.stdDevPrecTipText());\n assertEquals(0, resultMatrixLatex0.getStdDevWidth());\n assertEquals(1, resultMatrixLatex0.getVisibleColCount());\n assertEquals(\"Whether to enumerate the column names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixLatex0.enumerateColNamesTipText());\n assertEquals(\"The maximum width of the column names (0 = optimal).\", resultMatrixLatex0.colNameWidthTipText());\n assertFalse(resultMatrixLatex0.getRemoveFilterName());\n assertEquals(\"Whether to output column names or just numbers representing them.\", resultMatrixLatex0.printColNamesTipText());\n assertEquals(0, resultMatrixLatex0.getCountWidth());\n assertEquals(\"The width of the standard deviation (0 = optimal).\", resultMatrixLatex0.stdDevWidthTipText());\n assertEquals(\"The width of the significance indicator (0 = optimal).\", resultMatrixLatex0.significanceWidthTipText());\n assertEquals(\"LaTeX\", resultMatrixLatex0.getDisplayName());\n assertEquals(\"Whether to show the row with averages.\", resultMatrixLatex0.showAverageTipText());\n assertEquals(0, resultMatrixLatex0.getSignificanceWidth());\n assertFalse(resultMatrixLatex0.getShowStdDev());\n assertEquals(0, resultMatrixLatex0.getRowNameWidth());\n assertTrue(resultMatrixLatex0.getDefaultEnumerateColNames());\n assertFalse(resultMatrixLatex0.getShowAverage());\n assertEquals(\"The maximum width for the row names (0 = optimal).\", resultMatrixLatex0.rowNameWidthTipText());\n assertEquals(0, resultMatrixLatex0.getColNameWidth());\n assertFalse(resultMatrixLatex0.getDefaultEnumerateRowNames());\n assertEquals(0, resultMatrixLatex0.getDefaultRowNameWidth());\n assertFalse(resultMatrixLatex0.getDefaultShowAverage());\n assertEquals(2, resultMatrixLatex0.getMeanPrec());\n assertEquals(\"Whether to enumerate the row names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixLatex0.enumerateRowNamesTipText());\n assertEquals(0, resultMatrixLatex0.getDefaultCountWidth());\n assertFalse(resultMatrixLatex0.getEnumerateRowNames());\n assertFalse(resultMatrixLatex0.getPrintColNames());\n assertEquals(1, resultMatrixLatex0.getVisibleRowCount());\n assertEquals(2, resultMatrixLatex0.getDefaultStdDevPrec());\n assertEquals(1, resultMatrixLatex0.getRowCount());\n assertEquals(\"The number of decimals after the decimal point for the mean.\", resultMatrixLatex0.meanPrecTipText());\n assertEquals(2, resultMatrixLatex0.getDefaultMeanPrec());\n assertTrue(resultMatrixLatex0.getDefaultPrintRowNames());\n assertEquals(\"Whether to display the standard deviation column.\", resultMatrixLatex0.showStdDevTipText());\n assertFalse(resultMatrixLatex0.getDefaultPrintColNames());\n assertEquals(\"Whether to output row names or just numbers representing them.\", resultMatrixLatex0.printRowNamesTipText());\n assertTrue(resultMatrixLatex0.getPrintRowNames());\n assertEquals(\"The width of the counts (0 = optimal).\", resultMatrixLatex0.countWidthTipText());\n assertEquals(2, resultMatrixLatex0.getStdDevPrec());\n assertEquals(\"The width of the mean (0 = optimal).\", resultMatrixLatex0.meanWidthTipText());\n assertFalse(resultMatrixLatex0.getDefaultShowStdDev());\n assertEquals(0, resultMatrixLatex0.getDefaultSignificanceWidth());\n assertEquals(1, resultMatrixLatex0.getColCount());\n assertEquals(\"Generates the matrix output in LaTeX-syntax.\", resultMatrixLatex0.globalInfo());\n assertEquals(0, resultMatrixLatex0.getDefaultColNameWidth());\n assertEquals(0, resultMatrixLatex0.getDefaultMeanWidth());\n assertFalse(resultMatrixLatex0.getDefaultRemoveFilterName());\n assertEquals(\"The width of the standard deviation (0 = optimal).\", resultMatrixGnuPlot0.stdDevWidthTipText());\n assertFalse(resultMatrixGnuPlot0.getShowAverage());\n assertEquals(0, resultMatrixGnuPlot0.getStdDevWidth());\n assertEquals(\"The width of the significance indicator (0 = optimal).\", resultMatrixGnuPlot0.significanceWidthTipText());\n assertTrue(resultMatrixGnuPlot0.getDefaultPrintColNames());\n assertEquals(\"Whether to display the standard deviation column.\", resultMatrixGnuPlot0.showStdDevTipText());\n assertEquals(\"GNUPlot\", resultMatrixGnuPlot0.getDisplayName());\n assertEquals(0, resultMatrixGnuPlot0.getSignificanceWidth());\n assertFalse(resultMatrixGnuPlot0.getPrintColNames());\n assertEquals(\"Whether to remove the classname package prefixes from the filter names in datasets.\", resultMatrixGnuPlot0.removeFilterNameTipText());\n assertEquals(50, resultMatrixGnuPlot0.getDefaultRowNameWidth());\n assertEquals(\"The width of the mean (0 = optimal).\", resultMatrixGnuPlot0.meanWidthTipText());\n assertEquals(2, resultMatrixGnuPlot0.getStdDevPrec());\n assertEquals(\"The number of decimals after the decimal point for the standard deviation.\", resultMatrixGnuPlot0.stdDevPrecTipText());\n assertTrue(resultMatrixGnuPlot0.getDefaultPrintRowNames());\n assertEquals(\"Generates output for a data and script file for GnuPlot.\", resultMatrixGnuPlot0.globalInfo());\n assertFalse(resultMatrixGnuPlot0.getShowStdDev());\n assertEquals(\"The maximum width of the column names (0 = optimal).\", resultMatrixGnuPlot0.colNameWidthTipText());\n assertEquals(0, resultMatrixGnuPlot0.getColNameWidth());\n assertEquals(0, resultMatrixGnuPlot0.getMeanWidth());\n assertEquals(0, resultMatrixGnuPlot0.getDefaultCountWidth());\n assertEquals(1, resultMatrixGnuPlot0.getRowCount());\n assertEquals(25, resultMatrixGnuPlot0.getRowNameWidth());\n assertEquals(\"Whether to show the row with averages.\", resultMatrixGnuPlot0.showAverageTipText());\n assertTrue(resultMatrixGnuPlot0.getEnumerateColNames());\n assertFalse(resultMatrixGnuPlot0.getDefaultRemoveFilterName());\n assertEquals(2, resultMatrixGnuPlot0.getDefaultStdDevPrec());\n assertEquals(0, resultMatrixGnuPlot0.getDefaultSignificanceWidth());\n assertEquals(\"The number of decimals after the decimal point for the mean.\", resultMatrixGnuPlot0.meanPrecTipText());\n assertEquals(\"Whether to enumerate the row names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixGnuPlot0.enumerateRowNamesTipText());\n assertTrue(resultMatrixGnuPlot0.getEnumerateRowNames());\n assertEquals(\"Whether to output row names or just numbers representing them.\", resultMatrixGnuPlot0.printRowNamesTipText());\n assertFalse(resultMatrixGnuPlot0.getDefaultEnumerateRowNames());\n assertEquals(1, resultMatrixGnuPlot0.getColCount());\n assertEquals(1, resultMatrixGnuPlot0.getVisibleRowCount());\n assertFalse(resultMatrixGnuPlot0.getRemoveFilterName());\n assertFalse(resultMatrixGnuPlot0.getDefaultShowAverage());\n assertFalse(resultMatrixGnuPlot0.getDefaultShowStdDev());\n assertEquals(\"The maximum width for the row names (0 = optimal).\", resultMatrixGnuPlot0.rowNameWidthTipText());\n assertEquals(2, resultMatrixGnuPlot0.getMeanPrec());\n assertEquals(0, resultMatrixGnuPlot0.getDefaultStdDevWidth());\n assertEquals(50, resultMatrixGnuPlot0.getDefaultColNameWidth());\n assertEquals(\"Whether to enumerate the column names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixGnuPlot0.enumerateColNamesTipText());\n assertEquals(\"Whether to output column names or just numbers representing them.\", resultMatrixGnuPlot0.printColNamesTipText());\n assertEquals(0, resultMatrixGnuPlot0.getDefaultMeanWidth());\n assertEquals(661, resultMatrixGnuPlot0.getCountWidth());\n assertEquals(1, resultMatrixGnuPlot0.getVisibleColCount());\n assertTrue(resultMatrixGnuPlot0.getPrintRowNames());\n assertEquals(2, resultMatrixGnuPlot0.getDefaultMeanPrec());\n assertEquals(\"The width of the counts (0 = optimal).\", resultMatrixGnuPlot0.countWidthTipText());\n assertFalse(resultMatrixGnuPlot0.getDefaultEnumerateColNames());\n assertEquals(0, ResultMatrix.SIGNIFICANCE_TIE);\n assertEquals(1, ResultMatrix.SIGNIFICANCE_WIN);\n assertEquals(2, ResultMatrix.SIGNIFICANCE_LOSS);\n assertEquals(1, ResultMatrix.SIGNIFICANCE_WIN);\n assertEquals(2, ResultMatrix.SIGNIFICANCE_LOSS);\n assertEquals(0, ResultMatrix.SIGNIFICANCE_TIE);\n \n String string1 = resultMatrixGnuPlot0.toStringSummary();\n assertEquals(0, resultMatrixLatex0.getMeanWidth());\n assertEquals(\"Whether to remove the classname package prefixes from the filter names in datasets.\", resultMatrixLatex0.removeFilterNameTipText());\n assertTrue(resultMatrixLatex0.getEnumerateColNames());\n assertEquals(0, resultMatrixLatex0.getDefaultStdDevWidth());\n assertEquals(\"The number of decimals after the decimal point for the standard deviation.\", resultMatrixLatex0.stdDevPrecTipText());\n assertEquals(0, resultMatrixLatex0.getStdDevWidth());\n assertEquals(1, resultMatrixLatex0.getVisibleColCount());\n assertEquals(\"Whether to enumerate the column names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixLatex0.enumerateColNamesTipText());\n assertEquals(\"The maximum width of the column names (0 = optimal).\", resultMatrixLatex0.colNameWidthTipText());\n assertFalse(resultMatrixLatex0.getRemoveFilterName());\n assertEquals(\"Whether to output column names or just numbers representing them.\", resultMatrixLatex0.printColNamesTipText());\n assertEquals(0, resultMatrixLatex0.getCountWidth());\n assertEquals(\"The width of the standard deviation (0 = optimal).\", resultMatrixLatex0.stdDevWidthTipText());\n assertEquals(\"The width of the significance indicator (0 = optimal).\", resultMatrixLatex0.significanceWidthTipText());\n assertEquals(\"LaTeX\", resultMatrixLatex0.getDisplayName());\n assertEquals(\"Whether to show the row with averages.\", resultMatrixLatex0.showAverageTipText());\n assertEquals(0, resultMatrixLatex0.getSignificanceWidth());\n assertFalse(resultMatrixLatex0.getShowStdDev());\n assertEquals(0, resultMatrixLatex0.getRowNameWidth());\n assertTrue(resultMatrixLatex0.getDefaultEnumerateColNames());\n assertFalse(resultMatrixLatex0.getShowAverage());\n assertEquals(\"The maximum width for the row names (0 = optimal).\", resultMatrixLatex0.rowNameWidthTipText());\n assertEquals(0, resultMatrixLatex0.getColNameWidth());\n assertFalse(resultMatrixLatex0.getDefaultEnumerateRowNames());\n assertEquals(0, resultMatrixLatex0.getDefaultRowNameWidth());\n assertFalse(resultMatrixLatex0.getDefaultShowAverage());\n assertEquals(2, resultMatrixLatex0.getMeanPrec());\n assertEquals(\"Whether to enumerate the row names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixLatex0.enumerateRowNamesTipText());\n assertEquals(0, resultMatrixLatex0.getDefaultCountWidth());\n assertFalse(resultMatrixLatex0.getEnumerateRowNames());\n assertFalse(resultMatrixLatex0.getPrintColNames());\n assertEquals(1, resultMatrixLatex0.getVisibleRowCount());\n assertEquals(2, resultMatrixLatex0.getDefaultStdDevPrec());\n assertEquals(1, resultMatrixLatex0.getRowCount());\n assertEquals(\"The number of decimals after the decimal point for the mean.\", resultMatrixLatex0.meanPrecTipText());\n assertEquals(2, resultMatrixLatex0.getDefaultMeanPrec());\n assertTrue(resultMatrixLatex0.getDefaultPrintRowNames());\n assertEquals(\"Whether to display the standard deviation column.\", resultMatrixLatex0.showStdDevTipText());\n assertFalse(resultMatrixLatex0.getDefaultPrintColNames());\n assertEquals(\"Whether to output row names or just numbers representing them.\", resultMatrixLatex0.printRowNamesTipText());\n assertTrue(resultMatrixLatex0.getPrintRowNames());\n assertEquals(\"The width of the counts (0 = optimal).\", resultMatrixLatex0.countWidthTipText());\n assertEquals(2, resultMatrixLatex0.getStdDevPrec());\n assertEquals(\"The width of the mean (0 = optimal).\", resultMatrixLatex0.meanWidthTipText());\n assertFalse(resultMatrixLatex0.getDefaultShowStdDev());\n assertEquals(0, resultMatrixLatex0.getDefaultSignificanceWidth());\n assertEquals(1, resultMatrixLatex0.getColCount());\n assertEquals(\"Generates the matrix output in LaTeX-syntax.\", resultMatrixLatex0.globalInfo());\n assertEquals(0, resultMatrixLatex0.getDefaultColNameWidth());\n assertEquals(0, resultMatrixLatex0.getDefaultMeanWidth());\n assertFalse(resultMatrixLatex0.getDefaultRemoveFilterName());\n assertEquals(\"The width of the standard deviation (0 = optimal).\", resultMatrixGnuPlot0.stdDevWidthTipText());\n assertFalse(resultMatrixGnuPlot0.getShowAverage());\n assertEquals(0, resultMatrixGnuPlot0.getStdDevWidth());\n assertEquals(\"The width of the significance indicator (0 = optimal).\", resultMatrixGnuPlot0.significanceWidthTipText());\n assertTrue(resultMatrixGnuPlot0.getDefaultPrintColNames());\n assertEquals(\"Whether to display the standard deviation column.\", resultMatrixGnuPlot0.showStdDevTipText());\n assertEquals(\"GNUPlot\", resultMatrixGnuPlot0.getDisplayName());\n assertEquals(0, resultMatrixGnuPlot0.getSignificanceWidth());\n assertFalse(resultMatrixGnuPlot0.getPrintColNames());\n assertEquals(\"Whether to remove the classname package prefixes from the filter names in datasets.\", resultMatrixGnuPlot0.removeFilterNameTipText());\n assertEquals(50, resultMatrixGnuPlot0.getDefaultRowNameWidth());\n assertEquals(\"The width of the mean (0 = optimal).\", resultMatrixGnuPlot0.meanWidthTipText());\n assertEquals(2, resultMatrixGnuPlot0.getStdDevPrec());\n assertEquals(\"The number of decimals after the decimal point for the standard deviation.\", resultMatrixGnuPlot0.stdDevPrecTipText());\n assertTrue(resultMatrixGnuPlot0.getDefaultPrintRowNames());\n assertEquals(\"Generates output for a data and script file for GnuPlot.\", resultMatrixGnuPlot0.globalInfo());\n assertFalse(resultMatrixGnuPlot0.getShowStdDev());\n assertEquals(\"The maximum width of the column names (0 = optimal).\", resultMatrixGnuPlot0.colNameWidthTipText());\n assertEquals(0, resultMatrixGnuPlot0.getColNameWidth());\n assertEquals(0, resultMatrixGnuPlot0.getMeanWidth());\n assertEquals(0, resultMatrixGnuPlot0.getDefaultCountWidth());\n assertEquals(1, resultMatrixGnuPlot0.getRowCount());\n assertEquals(25, resultMatrixGnuPlot0.getRowNameWidth());\n assertEquals(\"Whether to show the row with averages.\", resultMatrixGnuPlot0.showAverageTipText());\n assertTrue(resultMatrixGnuPlot0.getEnumerateColNames());\n assertFalse(resultMatrixGnuPlot0.getDefaultRemoveFilterName());\n assertEquals(2, resultMatrixGnuPlot0.getDefaultStdDevPrec());\n assertEquals(0, resultMatrixGnuPlot0.getDefaultSignificanceWidth());\n assertEquals(\"The number of decimals after the decimal point for the mean.\", resultMatrixGnuPlot0.meanPrecTipText());\n assertEquals(\"Whether to enumerate the row names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixGnuPlot0.enumerateRowNamesTipText());\n assertTrue(resultMatrixGnuPlot0.getEnumerateRowNames());\n assertEquals(\"Whether to output row names or just numbers representing them.\", resultMatrixGnuPlot0.printRowNamesTipText());\n assertFalse(resultMatrixGnuPlot0.getDefaultEnumerateRowNames());\n assertEquals(1, resultMatrixGnuPlot0.getColCount());\n assertEquals(1, resultMatrixGnuPlot0.getVisibleRowCount());\n assertFalse(resultMatrixGnuPlot0.getRemoveFilterName());\n assertFalse(resultMatrixGnuPlot0.getDefaultShowAverage());\n assertFalse(resultMatrixGnuPlot0.getDefaultShowStdDev());\n assertEquals(\"The maximum width for the row names (0 = optimal).\", resultMatrixGnuPlot0.rowNameWidthTipText());\n assertEquals(2, resultMatrixGnuPlot0.getMeanPrec());\n assertEquals(0, resultMatrixGnuPlot0.getDefaultStdDevWidth());\n assertEquals(50, resultMatrixGnuPlot0.getDefaultColNameWidth());\n assertEquals(\"Whether to enumerate the column names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixGnuPlot0.enumerateColNamesTipText());\n assertEquals(\"Whether to output column names or just numbers representing them.\", resultMatrixGnuPlot0.printColNamesTipText());\n assertEquals(0, resultMatrixGnuPlot0.getDefaultMeanWidth());\n assertEquals(661, resultMatrixGnuPlot0.getCountWidth());\n assertEquals(1, resultMatrixGnuPlot0.getVisibleColCount());\n assertTrue(resultMatrixGnuPlot0.getPrintRowNames());\n assertEquals(2, resultMatrixGnuPlot0.getDefaultMeanPrec());\n assertEquals(\"The width of the counts (0 = optimal).\", resultMatrixGnuPlot0.countWidthTipText());\n assertFalse(resultMatrixGnuPlot0.getDefaultEnumerateColNames());\n assertNotNull(string1);\n assertEquals(0, ResultMatrix.SIGNIFICANCE_TIE);\n assertEquals(1, ResultMatrix.SIGNIFICANCE_WIN);\n assertEquals(2, ResultMatrix.SIGNIFICANCE_LOSS);\n assertEquals(1, ResultMatrix.SIGNIFICANCE_WIN);\n assertEquals(2, ResultMatrix.SIGNIFICANCE_LOSS);\n assertEquals(0, ResultMatrix.SIGNIFICANCE_TIE);\n assertEquals(\"-summary data not set-\", string1);\n assertFalse(string1.equals((Object)string0));\n \n int int1 = resultMatrixGnuPlot0.getStdDevWidth();\n assertEquals(0, resultMatrixLatex0.getMeanWidth());\n assertEquals(\"Whether to remove the classname package prefixes from the filter names in datasets.\", resultMatrixLatex0.removeFilterNameTipText());\n assertTrue(resultMatrixLatex0.getEnumerateColNames());\n assertEquals(0, resultMatrixLatex0.getDefaultStdDevWidth());\n assertEquals(\"The number of decimals after the decimal point for the standard deviation.\", resultMatrixLatex0.stdDevPrecTipText());\n assertEquals(0, resultMatrixLatex0.getStdDevWidth());\n assertEquals(1, resultMatrixLatex0.getVisibleColCount());\n assertEquals(\"Whether to enumerate the column names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixLatex0.enumerateColNamesTipText());\n assertEquals(\"The maximum width of the column names (0 = optimal).\", resultMatrixLatex0.colNameWidthTipText());\n assertFalse(resultMatrixLatex0.getRemoveFilterName());\n assertEquals(\"Whether to output column names or just numbers representing them.\", resultMatrixLatex0.printColNamesTipText());\n assertEquals(0, resultMatrixLatex0.getCountWidth());\n assertEquals(\"The width of the standard deviation (0 = optimal).\", resultMatrixLatex0.stdDevWidthTipText());\n assertEquals(\"The width of the significance indicator (0 = optimal).\", resultMatrixLatex0.significanceWidthTipText());\n assertEquals(\"LaTeX\", resultMatrixLatex0.getDisplayName());\n assertEquals(\"Whether to show the row with averages.\", resultMatrixLatex0.showAverageTipText());\n assertEquals(0, resultMatrixLatex0.getSignificanceWidth());\n assertFalse(resultMatrixLatex0.getShowStdDev());\n assertEquals(0, resultMatrixLatex0.getRowNameWidth());\n assertTrue(resultMatrixLatex0.getDefaultEnumerateColNames());\n assertFalse(resultMatrixLatex0.getShowAverage());\n assertEquals(\"The maximum width for the row names (0 = optimal).\", resultMatrixLatex0.rowNameWidthTipText());\n assertEquals(0, resultMatrixLatex0.getColNameWidth());\n assertFalse(resultMatrixLatex0.getDefaultEnumerateRowNames());\n assertEquals(0, resultMatrixLatex0.getDefaultRowNameWidth());\n assertFalse(resultMatrixLatex0.getDefaultShowAverage());\n assertEquals(2, resultMatrixLatex0.getMeanPrec());\n assertEquals(\"Whether to enumerate the row names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixLatex0.enumerateRowNamesTipText());\n assertEquals(0, resultMatrixLatex0.getDefaultCountWidth());\n assertFalse(resultMatrixLatex0.getEnumerateRowNames());\n assertFalse(resultMatrixLatex0.getPrintColNames());\n assertEquals(1, resultMatrixLatex0.getVisibleRowCount());\n assertEquals(2, resultMatrixLatex0.getDefaultStdDevPrec());\n assertEquals(1, resultMatrixLatex0.getRowCount());\n assertEquals(\"The number of decimals after the decimal point for the mean.\", resultMatrixLatex0.meanPrecTipText());\n assertEquals(2, resultMatrixLatex0.getDefaultMeanPrec());\n assertTrue(resultMatrixLatex0.getDefaultPrintRowNames());\n assertEquals(\"Whether to display the standard deviation column.\", resultMatrixLatex0.showStdDevTipText());\n assertFalse(resultMatrixLatex0.getDefaultPrintColNames());\n assertEquals(\"Whether to output row names or just numbers representing them.\", resultMatrixLatex0.printRowNamesTipText());\n assertTrue(resultMatrixLatex0.getPrintRowNames());\n assertEquals(\"The width of the counts (0 = optimal).\", resultMatrixLatex0.countWidthTipText());\n assertEquals(2, resultMatrixLatex0.getStdDevPrec());\n assertEquals(\"The width of the mean (0 = optimal).\", resultMatrixLatex0.meanWidthTipText());\n assertFalse(resultMatrixLatex0.getDefaultShowStdDev());\n assertEquals(0, resultMatrixLatex0.getDefaultSignificanceWidth());\n assertEquals(1, resultMatrixLatex0.getColCount());\n assertEquals(\"Generates the matrix output in LaTeX-syntax.\", resultMatrixLatex0.globalInfo());\n assertEquals(0, resultMatrixLatex0.getDefaultColNameWidth());\n assertEquals(0, resultMatrixLatex0.getDefaultMeanWidth());\n assertFalse(resultMatrixLatex0.getDefaultRemoveFilterName());\n assertEquals(\"The width of the standard deviation (0 = optimal).\", resultMatrixGnuPlot0.stdDevWidthTipText());\n assertFalse(resultMatrixGnuPlot0.getShowAverage());\n assertEquals(0, resultMatrixGnuPlot0.getStdDevWidth());\n assertEquals(\"The width of the significance indicator (0 = optimal).\", resultMatrixGnuPlot0.significanceWidthTipText());\n assertTrue(resultMatrixGnuPlot0.getDefaultPrintColNames());\n assertEquals(\"Whether to display the standard deviation column.\", resultMatrixGnuPlot0.showStdDevTipText());\n assertEquals(\"GNUPlot\", resultMatrixGnuPlot0.getDisplayName());\n assertEquals(0, resultMatrixGnuPlot0.getSignificanceWidth());\n assertFalse(resultMatrixGnuPlot0.getPrintColNames());\n assertEquals(\"Whether to remove the classname package prefixes from the filter names in datasets.\", resultMatrixGnuPlot0.removeFilterNameTipText());\n assertEquals(50, resultMatrixGnuPlot0.getDefaultRowNameWidth());\n assertEquals(\"The width of the mean (0 = optimal).\", resultMatrixGnuPlot0.meanWidthTipText());\n assertEquals(2, resultMatrixGnuPlot0.getStdDevPrec());\n assertEquals(\"The number of decimals after the decimal point for the standard deviation.\", resultMatrixGnuPlot0.stdDevPrecTipText());\n assertTrue(resultMatrixGnuPlot0.getDefaultPrintRowNames());\n assertEquals(\"Generates output for a data and script file for GnuPlot.\", resultMatrixGnuPlot0.globalInfo());\n assertFalse(resultMatrixGnuPlot0.getShowStdDev());\n assertEquals(\"The maximum width of the column names (0 = optimal).\", resultMatrixGnuPlot0.colNameWidthTipText());\n assertEquals(0, resultMatrixGnuPlot0.getColNameWidth());\n assertEquals(0, resultMatrixGnuPlot0.getMeanWidth());\n assertEquals(0, resultMatrixGnuPlot0.getDefaultCountWidth());\n assertEquals(1, resultMatrixGnuPlot0.getRowCount());\n assertEquals(25, resultMatrixGnuPlot0.getRowNameWidth());\n assertEquals(\"Whether to show the row with averages.\", resultMatrixGnuPlot0.showAverageTipText());\n assertTrue(resultMatrixGnuPlot0.getEnumerateColNames());\n assertFalse(resultMatrixGnuPlot0.getDefaultRemoveFilterName());\n assertEquals(2, resultMatrixGnuPlot0.getDefaultStdDevPrec());\n assertEquals(0, resultMatrixGnuPlot0.getDefaultSignificanceWidth());\n assertEquals(\"The number of decimals after the decimal point for the mean.\", resultMatrixGnuPlot0.meanPrecTipText());\n assertEquals(\"Whether to enumerate the row names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixGnuPlot0.enumerateRowNamesTipText());\n assertTrue(resultMatrixGnuPlot0.getEnumerateRowNames());\n assertEquals(\"Whether to output row names or just numbers representing them.\", resultMatrixGnuPlot0.printRowNamesTipText());\n assertFalse(resultMatrixGnuPlot0.getDefaultEnumerateRowNames());\n assertEquals(1, resultMatrixGnuPlot0.getColCount());\n assertEquals(1, resultMatrixGnuPlot0.getVisibleRowCount());\n assertFalse(resultMatrixGnuPlot0.getRemoveFilterName());\n assertFalse(resultMatrixGnuPlot0.getDefaultShowAverage());\n assertFalse(resultMatrixGnuPlot0.getDefaultShowStdDev());\n assertEquals(\"The maximum width for the row names (0 = optimal).\", resultMatrixGnuPlot0.rowNameWidthTipText());\n assertEquals(2, resultMatrixGnuPlot0.getMeanPrec());\n assertEquals(0, resultMatrixGnuPlot0.getDefaultStdDevWidth());\n assertEquals(50, resultMatrixGnuPlot0.getDefaultColNameWidth());\n assertEquals(\"Whether to enumerate the column names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixGnuPlot0.enumerateColNamesTipText());\n assertEquals(\"Whether to output column names or just numbers representing them.\", resultMatrixGnuPlot0.printColNamesTipText());\n assertEquals(0, resultMatrixGnuPlot0.getDefaultMeanWidth());\n assertEquals(661, resultMatrixGnuPlot0.getCountWidth());\n assertEquals(1, resultMatrixGnuPlot0.getVisibleColCount());\n assertTrue(resultMatrixGnuPlot0.getPrintRowNames());\n assertEquals(2, resultMatrixGnuPlot0.getDefaultMeanPrec());\n assertEquals(\"The width of the counts (0 = optimal).\", resultMatrixGnuPlot0.countWidthTipText());\n assertFalse(resultMatrixGnuPlot0.getDefaultEnumerateColNames());\n assertEquals(0, ResultMatrix.SIGNIFICANCE_TIE);\n assertEquals(1, ResultMatrix.SIGNIFICANCE_WIN);\n assertEquals(2, ResultMatrix.SIGNIFICANCE_LOSS);\n assertEquals(1, ResultMatrix.SIGNIFICANCE_WIN);\n assertEquals(2, ResultMatrix.SIGNIFICANCE_LOSS);\n assertEquals(0, ResultMatrix.SIGNIFICANCE_TIE);\n assertEquals(0, int1);\n assertFalse(int1 == int0);\n \n String string2 = resultMatrixLatex0.trimString(\"\", 2);\n assertEquals(0, resultMatrixLatex0.getMeanWidth());\n assertEquals(\"Whether to remove the classname package prefixes from the filter names in datasets.\", resultMatrixLatex0.removeFilterNameTipText());\n assertTrue(resultMatrixLatex0.getEnumerateColNames());\n assertEquals(0, resultMatrixLatex0.getDefaultStdDevWidth());\n assertEquals(\"The number of decimals after the decimal point for the standard deviation.\", resultMatrixLatex0.stdDevPrecTipText());\n assertEquals(0, resultMatrixLatex0.getStdDevWidth());\n assertEquals(1, resultMatrixLatex0.getVisibleColCount());\n assertEquals(\"Whether to enumerate the column names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixLatex0.enumerateColNamesTipText());\n assertEquals(\"The maximum width of the column names (0 = optimal).\", resultMatrixLatex0.colNameWidthTipText());\n assertFalse(resultMatrixLatex0.getRemoveFilterName());\n assertEquals(\"Whether to output column names or just numbers representing them.\", resultMatrixLatex0.printColNamesTipText());\n assertEquals(0, resultMatrixLatex0.getCountWidth());\n assertEquals(\"The width of the standard deviation (0 = optimal).\", resultMatrixLatex0.stdDevWidthTipText());\n assertEquals(\"The width of the significance indicator (0 = optimal).\", resultMatrixLatex0.significanceWidthTipText());\n assertEquals(\"LaTeX\", resultMatrixLatex0.getDisplayName());\n assertEquals(\"Whether to show the row with averages.\", resultMatrixLatex0.showAverageTipText());\n assertEquals(0, resultMatrixLatex0.getSignificanceWidth());\n assertFalse(resultMatrixLatex0.getShowStdDev());\n assertEquals(0, resultMatrixLatex0.getRowNameWidth());\n assertTrue(resultMatrixLatex0.getDefaultEnumerateColNames());\n assertFalse(resultMatrixLatex0.getShowAverage());\n assertEquals(\"The maximum width for the row names (0 = optimal).\", resultMatrixLatex0.rowNameWidthTipText());\n assertEquals(0, resultMatrixLatex0.getColNameWidth());\n assertFalse(resultMatrixLatex0.getDefaultEnumerateRowNames());\n assertEquals(0, resultMatrixLatex0.getDefaultRowNameWidth());\n assertFalse(resultMatrixLatex0.getDefaultShowAverage());\n assertEquals(2, resultMatrixLatex0.getMeanPrec());\n assertEquals(\"Whether to enumerate the row names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixLatex0.enumerateRowNamesTipText());\n assertEquals(0, resultMatrixLatex0.getDefaultCountWidth());\n assertFalse(resultMatrixLatex0.getEnumerateRowNames());\n assertFalse(resultMatrixLatex0.getPrintColNames());\n assertEquals(1, resultMatrixLatex0.getVisibleRowCount());\n assertEquals(2, resultMatrixLatex0.getDefaultStdDevPrec());\n assertEquals(1, resultMatrixLatex0.getRowCount());\n assertEquals(\"The number of decimals after the decimal point for the mean.\", resultMatrixLatex0.meanPrecTipText());\n assertEquals(2, resultMatrixLatex0.getDefaultMeanPrec());\n assertTrue(resultMatrixLatex0.getDefaultPrintRowNames());\n assertEquals(\"Whether to display the standard deviation column.\", resultMatrixLatex0.showStdDevTipText());\n assertFalse(resultMatrixLatex0.getDefaultPrintColNames());\n assertEquals(\"Whether to output row names or just numbers representing them.\", resultMatrixLatex0.printRowNamesTipText());\n assertTrue(resultMatrixLatex0.getPrintRowNames());\n assertEquals(\"The width of the counts (0 = optimal).\", resultMatrixLatex0.countWidthTipText());\n assertEquals(2, resultMatrixLatex0.getStdDevPrec());\n assertEquals(\"The width of the mean (0 = optimal).\", resultMatrixLatex0.meanWidthTipText());\n assertFalse(resultMatrixLatex0.getDefaultShowStdDev());\n assertEquals(0, resultMatrixLatex0.getDefaultSignificanceWidth());\n assertEquals(1, resultMatrixLatex0.getColCount());\n assertEquals(\"Generates the matrix output in LaTeX-syntax.\", resultMatrixLatex0.globalInfo());\n assertEquals(0, resultMatrixLatex0.getDefaultColNameWidth());\n assertEquals(0, resultMatrixLatex0.getDefaultMeanWidth());\n assertFalse(resultMatrixLatex0.getDefaultRemoveFilterName());\n assertNotNull(string2);\n assertEquals(0, ResultMatrix.SIGNIFICANCE_TIE);\n assertEquals(1, ResultMatrix.SIGNIFICANCE_WIN);\n assertEquals(2, ResultMatrix.SIGNIFICANCE_LOSS);\n assertEquals(\"\", string2);\n assertFalse(string2.equals((Object)string1));\n assertFalse(string2.equals((Object)string0));\n \n ResultMatrixHTML resultMatrixHTML0 = new ResultMatrixHTML(resultMatrixGnuPlot0);\n assertEquals(0, resultMatrixLatex0.getMeanWidth());\n assertEquals(\"Whether to remove the classname package prefixes from the filter names in datasets.\", resultMatrixLatex0.removeFilterNameTipText());\n assertTrue(resultMatrixLatex0.getEnumerateColNames());\n assertEquals(0, resultMatrixLatex0.getDefaultStdDevWidth());\n assertEquals(\"The number of decimals after the decimal point for the standard deviation.\", resultMatrixLatex0.stdDevPrecTipText());\n assertEquals(0, resultMatrixLatex0.getStdDevWidth());\n assertEquals(1, resultMatrixLatex0.getVisibleColCount());\n assertEquals(\"Whether to enumerate the column names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixLatex0.enumerateColNamesTipText());\n assertEquals(\"The maximum width of the column names (0 = optimal).\", resultMatrixLatex0.colNameWidthTipText());\n assertFalse(resultMatrixLatex0.getRemoveFilterName());\n assertEquals(\"Whether to output column names or just numbers representing them.\", resultMatrixLatex0.printColNamesTipText());\n assertEquals(0, resultMatrixLatex0.getCountWidth());\n assertEquals(\"The width of the standard deviation (0 = optimal).\", resultMatrixLatex0.stdDevWidthTipText());\n assertEquals(\"The width of the significance indicator (0 = optimal).\", resultMatrixLatex0.significanceWidthTipText());\n assertEquals(\"LaTeX\", resultMatrixLatex0.getDisplayName());\n assertEquals(\"Whether to show the row with averages.\", resultMatrixLatex0.showAverageTipText());\n assertEquals(0, resultMatrixLatex0.getSignificanceWidth());\n assertFalse(resultMatrixLatex0.getShowStdDev());\n assertEquals(0, resultMatrixLatex0.getRowNameWidth());\n assertTrue(resultMatrixLatex0.getDefaultEnumerateColNames());\n assertFalse(resultMatrixLatex0.getShowAverage());\n assertEquals(\"The maximum width for the row names (0 = optimal).\", resultMatrixLatex0.rowNameWidthTipText());\n assertEquals(0, resultMatrixLatex0.getColNameWidth());\n assertFalse(resultMatrixLatex0.getDefaultEnumerateRowNames());\n assertEquals(0, resultMatrixLatex0.getDefaultRowNameWidth());\n assertFalse(resultMatrixLatex0.getDefaultShowAverage());\n assertEquals(2, resultMatrixLatex0.getMeanPrec());\n assertEquals(\"Whether to enumerate the row names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixLatex0.enumerateRowNamesTipText());\n assertEquals(0, resultMatrixLatex0.getDefaultCountWidth());\n assertFalse(resultMatrixLatex0.getEnumerateRowNames());\n assertFalse(resultMatrixLatex0.getPrintColNames());\n assertEquals(1, resultMatrixLatex0.getVisibleRowCount());\n assertEquals(2, resultMatrixLatex0.getDefaultStdDevPrec());\n assertEquals(1, resultMatrixLatex0.getRowCount());\n assertEquals(\"The number of decimals after the decimal point for the mean.\", resultMatrixLatex0.meanPrecTipText());\n assertEquals(2, resultMatrixLatex0.getDefaultMeanPrec());\n assertTrue(resultMatrixLatex0.getDefaultPrintRowNames());\n assertEquals(\"Whether to display the standard deviation column.\", resultMatrixLatex0.showStdDevTipText());\n assertFalse(resultMatrixLatex0.getDefaultPrintColNames());\n assertEquals(\"Whether to output row names or just numbers representing them.\", resultMatrixLatex0.printRowNamesTipText());\n assertTrue(resultMatrixLatex0.getPrintRowNames());\n assertEquals(\"The width of the counts (0 = optimal).\", resultMatrixLatex0.countWidthTipText());\n assertEquals(2, resultMatrixLatex0.getStdDevPrec());\n assertEquals(\"The width of the mean (0 = optimal).\", resultMatrixLatex0.meanWidthTipText());\n assertFalse(resultMatrixLatex0.getDefaultShowStdDev());\n assertEquals(0, resultMatrixLatex0.getDefaultSignificanceWidth());\n assertEquals(1, resultMatrixLatex0.getColCount());\n assertEquals(\"Generates the matrix output in LaTeX-syntax.\", resultMatrixLatex0.globalInfo());\n assertEquals(0, resultMatrixLatex0.getDefaultColNameWidth());\n assertEquals(0, resultMatrixLatex0.getDefaultMeanWidth());\n assertFalse(resultMatrixLatex0.getDefaultRemoveFilterName());\n assertEquals(0, resultMatrixHTML0.getColNameWidth());\n assertEquals(\"Whether to output column names or just numbers representing them.\", resultMatrixHTML0.printColNamesTipText());\n assertEquals(\"The number of decimals after the decimal point for the standard deviation.\", resultMatrixHTML0.stdDevPrecTipText());\n assertEquals(0, resultMatrixHTML0.getDefaultMeanWidth());\n assertEquals(\"Whether to enumerate the column names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixHTML0.enumerateColNamesTipText());\n assertEquals(25, resultMatrixHTML0.getDefaultRowNameWidth());\n assertEquals(\"The maximum width of the column names (0 = optimal).\", resultMatrixHTML0.colNameWidthTipText());\n assertEquals(0, resultMatrixHTML0.getMeanWidth());\n assertTrue(resultMatrixHTML0.getPrintRowNames());\n assertEquals(1, resultMatrixHTML0.getVisibleColCount());\n assertEquals(\"Whether to show the row with averages.\", resultMatrixHTML0.showAverageTipText());\n assertEquals(2, resultMatrixHTML0.getDefaultMeanPrec());\n assertEquals(0, resultMatrixHTML0.getStdDevWidth());\n assertEquals(0, resultMatrixHTML0.getDefaultStdDevWidth());\n assertTrue(resultMatrixHTML0.getEnumerateColNames());\n assertEquals(\"The maximum width for the row names (0 = optimal).\", resultMatrixHTML0.rowNameWidthTipText());\n assertTrue(resultMatrixHTML0.getDefaultEnumerateColNames());\n assertEquals(661, resultMatrixHTML0.getCountWidth());\n assertEquals(\"The width of the significance indicator (0 = optimal).\", resultMatrixHTML0.significanceWidthTipText());\n assertFalse(resultMatrixHTML0.getPrintColNames());\n assertTrue(resultMatrixHTML0.getEnumerateRowNames());\n assertEquals(0, resultMatrixHTML0.getSignificanceWidth());\n assertEquals(\"Whether to remove the classname package prefixes from the filter names in datasets.\", resultMatrixHTML0.removeFilterNameTipText());\n assertFalse(resultMatrixHTML0.getShowStdDev());\n assertEquals(2, resultMatrixHTML0.getMeanPrec());\n assertFalse(resultMatrixHTML0.getDefaultShowAverage());\n assertFalse(resultMatrixHTML0.getDefaultEnumerateRowNames());\n assertEquals(0, resultMatrixHTML0.getDefaultCountWidth());\n assertFalse(resultMatrixHTML0.getDefaultPrintColNames());\n assertEquals(25, resultMatrixHTML0.getRowNameWidth());\n assertEquals(0, resultMatrixHTML0.getDefaultSignificanceWidth());\n assertEquals(0, resultMatrixHTML0.getDefaultColNameWidth());\n assertEquals(2, resultMatrixHTML0.getDefaultStdDevPrec());\n assertEquals(2, resultMatrixHTML0.getStdDevPrec());\n assertFalse(resultMatrixHTML0.getShowAverage());\n assertEquals(\"The width of the counts (0 = optimal).\", resultMatrixHTML0.countWidthTipText());\n assertFalse(resultMatrixHTML0.getDefaultRemoveFilterName());\n assertEquals(\"The width of the standard deviation (0 = optimal).\", resultMatrixHTML0.stdDevWidthTipText());\n assertEquals(\"Whether to output row names or just numbers representing them.\", resultMatrixHTML0.printRowNamesTipText());\n assertEquals(1, resultMatrixHTML0.getRowCount());\n assertEquals(\"The number of decimals after the decimal point for the mean.\", resultMatrixHTML0.meanPrecTipText());\n assertEquals(\"Whether to display the standard deviation column.\", resultMatrixHTML0.showStdDevTipText());\n assertEquals(1, resultMatrixHTML0.getVisibleRowCount());\n assertEquals(\"Whether to enumerate the row names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixHTML0.enumerateRowNamesTipText());\n assertFalse(resultMatrixHTML0.getRemoveFilterName());\n assertFalse(resultMatrixHTML0.getDefaultShowStdDev());\n assertEquals(\"HTML\", resultMatrixHTML0.getDisplayName());\n assertEquals(\"Generates the matrix output as HTML.\", resultMatrixHTML0.globalInfo());\n assertEquals(1, resultMatrixHTML0.getColCount());\n assertEquals(\"The width of the mean (0 = optimal).\", resultMatrixHTML0.meanWidthTipText());\n assertTrue(resultMatrixHTML0.getDefaultPrintRowNames());\n assertEquals(\"The width of the standard deviation (0 = optimal).\", resultMatrixGnuPlot0.stdDevWidthTipText());\n assertFalse(resultMatrixGnuPlot0.getShowAverage());\n assertEquals(0, resultMatrixGnuPlot0.getStdDevWidth());\n assertEquals(\"The width of the significance indicator (0 = optimal).\", resultMatrixGnuPlot0.significanceWidthTipText());\n assertTrue(resultMatrixGnuPlot0.getDefaultPrintColNames());\n assertEquals(\"Whether to display the standard deviation column.\", resultMatrixGnuPlot0.showStdDevTipText());\n assertEquals(\"GNUPlot\", resultMatrixGnuPlot0.getDisplayName());\n assertEquals(0, resultMatrixGnuPlot0.getSignificanceWidth());\n assertFalse(resultMatrixGnuPlot0.getPrintColNames());\n assertEquals(\"Whether to remove the classname package prefixes from the filter names in datasets.\", resultMatrixGnuPlot0.removeFilterNameTipText());\n assertEquals(50, resultMatrixGnuPlot0.getDefaultRowNameWidth());\n assertEquals(\"The width of the mean (0 = optimal).\", resultMatrixGnuPlot0.meanWidthTipText());\n assertEquals(2, resultMatrixGnuPlot0.getStdDevPrec());\n assertEquals(\"The number of decimals after the decimal point for the standard deviation.\", resultMatrixGnuPlot0.stdDevPrecTipText());\n assertTrue(resultMatrixGnuPlot0.getDefaultPrintRowNames());\n assertEquals(\"Generates output for a data and script file for GnuPlot.\", resultMatrixGnuPlot0.globalInfo());\n assertFalse(resultMatrixGnuPlot0.getShowStdDev());\n assertEquals(\"The maximum width of the column names (0 = optimal).\", resultMatrixGnuPlot0.colNameWidthTipText());\n assertEquals(0, resultMatrixGnuPlot0.getColNameWidth());\n assertEquals(0, resultMatrixGnuPlot0.getMeanWidth());\n assertEquals(0, resultMatrixGnuPlot0.getDefaultCountWidth());\n assertEquals(1, resultMatrixGnuPlot0.getRowCount());\n assertEquals(25, resultMatrixGnuPlot0.getRowNameWidth());\n assertEquals(\"Whether to show the row with averages.\", resultMatrixGnuPlot0.showAverageTipText());\n assertTrue(resultMatrixGnuPlot0.getEnumerateColNames());\n assertFalse(resultMatrixGnuPlot0.getDefaultRemoveFilterName());\n assertEquals(2, resultMatrixGnuPlot0.getDefaultStdDevPrec());\n assertEquals(0, resultMatrixGnuPlot0.getDefaultSignificanceWidth());\n assertEquals(\"The number of decimals after the decimal point for the mean.\", resultMatrixGnuPlot0.meanPrecTipText());\n assertEquals(\"Whether to enumerate the row names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixGnuPlot0.enumerateRowNamesTipText());\n assertTrue(resultMatrixGnuPlot0.getEnumerateRowNames());\n assertEquals(\"Whether to output row names or just numbers representing them.\", resultMatrixGnuPlot0.printRowNamesTipText());\n assertFalse(resultMatrixGnuPlot0.getDefaultEnumerateRowNames());\n assertEquals(1, resultMatrixGnuPlot0.getColCount());\n assertEquals(1, resultMatrixGnuPlot0.getVisibleRowCount());\n assertFalse(resultMatrixGnuPlot0.getRemoveFilterName());\n assertFalse(resultMatrixGnuPlot0.getDefaultShowAverage());\n assertFalse(resultMatrixGnuPlot0.getDefaultShowStdDev());\n assertEquals(\"The maximum width for the row names (0 = optimal).\", resultMatrixGnuPlot0.rowNameWidthTipText());\n assertEquals(2, resultMatrixGnuPlot0.getMeanPrec());\n assertEquals(0, resultMatrixGnuPlot0.getDefaultStdDevWidth());\n assertEquals(50, resultMatrixGnuPlot0.getDefaultColNameWidth());\n assertEquals(\"Whether to enumerate the column names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixGnuPlot0.enumerateColNamesTipText());\n assertEquals(\"Whether to output column names or just numbers representing them.\", resultMatrixGnuPlot0.printColNamesTipText());\n assertEquals(0, resultMatrixGnuPlot0.getDefaultMeanWidth());\n assertEquals(661, resultMatrixGnuPlot0.getCountWidth());\n assertEquals(1, resultMatrixGnuPlot0.getVisibleColCount());\n assertTrue(resultMatrixGnuPlot0.getPrintRowNames());\n assertEquals(2, resultMatrixGnuPlot0.getDefaultMeanPrec());\n assertEquals(\"The width of the counts (0 = optimal).\", resultMatrixGnuPlot0.countWidthTipText());\n assertFalse(resultMatrixGnuPlot0.getDefaultEnumerateColNames());\n assertNotNull(resultMatrixHTML0);\n assertEquals(0, ResultMatrix.SIGNIFICANCE_TIE);\n assertEquals(1, ResultMatrix.SIGNIFICANCE_WIN);\n assertEquals(2, ResultMatrix.SIGNIFICANCE_LOSS);\n assertEquals(0, ResultMatrix.SIGNIFICANCE_TIE);\n assertEquals(2, ResultMatrix.SIGNIFICANCE_LOSS);\n assertEquals(1, ResultMatrix.SIGNIFICANCE_WIN);\n assertEquals(1, ResultMatrix.SIGNIFICANCE_WIN);\n assertEquals(2, ResultMatrix.SIGNIFICANCE_LOSS);\n assertEquals(0, ResultMatrix.SIGNIFICANCE_TIE);\n \n resultMatrixHTML0.setSize(2417, 1);\n assertEquals(0, resultMatrixLatex0.getMeanWidth());\n assertEquals(\"Whether to remove the classname package prefixes from the filter names in datasets.\", resultMatrixLatex0.removeFilterNameTipText());\n assertTrue(resultMatrixLatex0.getEnumerateColNames());\n assertEquals(0, resultMatrixLatex0.getDefaultStdDevWidth());\n assertEquals(\"The number of decimals after the decimal point for the standard deviation.\", resultMatrixLatex0.stdDevPrecTipText());\n assertEquals(0, resultMatrixLatex0.getStdDevWidth());\n assertEquals(1, resultMatrixLatex0.getVisibleColCount());\n assertEquals(\"Whether to enumerate the column names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixLatex0.enumerateColNamesTipText());\n assertEquals(\"The maximum width of the column names (0 = optimal).\", resultMatrixLatex0.colNameWidthTipText());\n assertFalse(resultMatrixLatex0.getRemoveFilterName());\n assertEquals(\"Whether to output column names or just numbers representing them.\", resultMatrixLatex0.printColNamesTipText());\n assertEquals(0, resultMatrixLatex0.getCountWidth());\n assertEquals(\"The width of the standard deviation (0 = optimal).\", resultMatrixLatex0.stdDevWidthTipText());\n assertEquals(\"The width of the significance indicator (0 = optimal).\", resultMatrixLatex0.significanceWidthTipText());\n assertEquals(\"LaTeX\", resultMatrixLatex0.getDisplayName());\n assertEquals(\"Whether to show the row with averages.\", resultMatrixLatex0.showAverageTipText());\n assertEquals(0, resultMatrixLatex0.getSignificanceWidth());\n assertFalse(resultMatrixLatex0.getShowStdDev());\n assertEquals(0, resultMatrixLatex0.getRowNameWidth());\n assertTrue(resultMatrixLatex0.getDefaultEnumerateColNames());\n assertFalse(resultMatrixLatex0.getShowAverage());\n assertEquals(\"The maximum width for the row names (0 = optimal).\", resultMatrixLatex0.rowNameWidthTipText());\n assertEquals(0, resultMatrixLatex0.getColNameWidth());\n assertFalse(resultMatrixLatex0.getDefaultEnumerateRowNames());\n assertEquals(0, resultMatrixLatex0.getDefaultRowNameWidth());\n assertFalse(resultMatrixLatex0.getDefaultShowAverage());\n assertEquals(2, resultMatrixLatex0.getMeanPrec());\n assertEquals(\"Whether to enumerate the row names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixLatex0.enumerateRowNamesTipText());\n assertEquals(0, resultMatrixLatex0.getDefaultCountWidth());\n assertFalse(resultMatrixLatex0.getEnumerateRowNames());\n assertFalse(resultMatrixLatex0.getPrintColNames());\n assertEquals(1, resultMatrixLatex0.getVisibleRowCount());\n assertEquals(2, resultMatrixLatex0.getDefaultStdDevPrec());\n assertEquals(1, resultMatrixLatex0.getRowCount());\n assertEquals(\"The number of decimals after the decimal point for the mean.\", resultMatrixLatex0.meanPrecTipText());\n assertEquals(2, resultMatrixLatex0.getDefaultMeanPrec());\n assertTrue(resultMatrixLatex0.getDefaultPrintRowNames());\n assertEquals(\"Whether to display the standard deviation column.\", resultMatrixLatex0.showStdDevTipText());\n assertFalse(resultMatrixLatex0.getDefaultPrintColNames());\n assertEquals(\"Whether to output row names or just numbers representing them.\", resultMatrixLatex0.printRowNamesTipText());\n assertTrue(resultMatrixLatex0.getPrintRowNames());\n assertEquals(\"The width of the counts (0 = optimal).\", resultMatrixLatex0.countWidthTipText());\n assertEquals(2, resultMatrixLatex0.getStdDevPrec());\n assertEquals(\"The width of the mean (0 = optimal).\", resultMatrixLatex0.meanWidthTipText());\n assertFalse(resultMatrixLatex0.getDefaultShowStdDev());\n assertEquals(0, resultMatrixLatex0.getDefaultSignificanceWidth());\n assertEquals(1, resultMatrixLatex0.getColCount());\n assertEquals(\"Generates the matrix output in LaTeX-syntax.\", resultMatrixLatex0.globalInfo());\n assertEquals(0, resultMatrixLatex0.getDefaultColNameWidth());\n assertEquals(0, resultMatrixLatex0.getDefaultMeanWidth());\n assertFalse(resultMatrixLatex0.getDefaultRemoveFilterName());\n assertEquals(0, resultMatrixHTML0.getColNameWidth());\n assertEquals(\"Whether to output column names or just numbers representing them.\", resultMatrixHTML0.printColNamesTipText());\n assertEquals(\"The number of decimals after the decimal point for the standard deviation.\", resultMatrixHTML0.stdDevPrecTipText());\n assertEquals(0, resultMatrixHTML0.getDefaultMeanWidth());\n assertEquals(\"Whether to enumerate the column names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixHTML0.enumerateColNamesTipText());\n assertEquals(25, resultMatrixHTML0.getDefaultRowNameWidth());\n assertEquals(\"The maximum width of the column names (0 = optimal).\", resultMatrixHTML0.colNameWidthTipText());\n assertEquals(0, resultMatrixHTML0.getMeanWidth());\n assertTrue(resultMatrixHTML0.getPrintRowNames());\n assertEquals(\"Whether to show the row with averages.\", resultMatrixHTML0.showAverageTipText());\n assertEquals(2, resultMatrixHTML0.getDefaultMeanPrec());\n assertEquals(0, resultMatrixHTML0.getStdDevWidth());\n assertEquals(0, resultMatrixHTML0.getDefaultStdDevWidth());\n assertTrue(resultMatrixHTML0.getEnumerateColNames());\n assertEquals(\"The maximum width for the row names (0 = optimal).\", resultMatrixHTML0.rowNameWidthTipText());\n assertTrue(resultMatrixHTML0.getDefaultEnumerateColNames());\n assertEquals(661, resultMatrixHTML0.getCountWidth());\n assertEquals(\"The width of the significance indicator (0 = optimal).\", resultMatrixHTML0.significanceWidthTipText());\n assertFalse(resultMatrixHTML0.getPrintColNames());\n assertTrue(resultMatrixHTML0.getEnumerateRowNames());\n assertEquals(0, resultMatrixHTML0.getSignificanceWidth());\n assertEquals(\"Whether to remove the classname package prefixes from the filter names in datasets.\", resultMatrixHTML0.removeFilterNameTipText());\n assertFalse(resultMatrixHTML0.getShowStdDev());\n assertEquals(2, resultMatrixHTML0.getMeanPrec());\n assertFalse(resultMatrixHTML0.getDefaultShowAverage());\n assertFalse(resultMatrixHTML0.getDefaultEnumerateRowNames());\n assertEquals(0, resultMatrixHTML0.getDefaultCountWidth());\n assertFalse(resultMatrixHTML0.getDefaultPrintColNames());\n assertEquals(25, resultMatrixHTML0.getRowNameWidth());\n assertEquals(0, resultMatrixHTML0.getDefaultSignificanceWidth());\n assertEquals(0, resultMatrixHTML0.getDefaultColNameWidth());\n assertEquals(2, resultMatrixHTML0.getDefaultStdDevPrec());\n assertEquals(2, resultMatrixHTML0.getStdDevPrec());\n assertFalse(resultMatrixHTML0.getShowAverage());\n assertEquals(\"The width of the counts (0 = optimal).\", resultMatrixHTML0.countWidthTipText());\n assertEquals(2417, resultMatrixHTML0.getVisibleColCount());\n assertFalse(resultMatrixHTML0.getDefaultRemoveFilterName());\n assertEquals(\"The width of the standard deviation (0 = optimal).\", resultMatrixHTML0.stdDevWidthTipText());\n assertEquals(\"Whether to output row names or just numbers representing them.\", resultMatrixHTML0.printRowNamesTipText());\n assertEquals(1, resultMatrixHTML0.getRowCount());\n assertEquals(\"The number of decimals after the decimal point for the mean.\", resultMatrixHTML0.meanPrecTipText());\n assertEquals(2417, resultMatrixHTML0.getColCount());\n assertEquals(\"Whether to display the standard deviation column.\", resultMatrixHTML0.showStdDevTipText());\n assertEquals(1, resultMatrixHTML0.getVisibleRowCount());\n assertEquals(\"Whether to enumerate the row names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixHTML0.enumerateRowNamesTipText());\n assertFalse(resultMatrixHTML0.getRemoveFilterName());\n assertFalse(resultMatrixHTML0.getDefaultShowStdDev());\n assertEquals(\"HTML\", resultMatrixHTML0.getDisplayName());\n assertEquals(\"Generates the matrix output as HTML.\", resultMatrixHTML0.globalInfo());\n assertEquals(\"The width of the mean (0 = optimal).\", resultMatrixHTML0.meanWidthTipText());\n assertTrue(resultMatrixHTML0.getDefaultPrintRowNames());\n assertEquals(\"The width of the standard deviation (0 = optimal).\", resultMatrixGnuPlot0.stdDevWidthTipText());\n assertFalse(resultMatrixGnuPlot0.getShowAverage());\n assertEquals(0, resultMatrixGnuPlot0.getStdDevWidth());\n assertEquals(\"The width of the significance indicator (0 = optimal).\", resultMatrixGnuPlot0.significanceWidthTipText());\n assertTrue(resultMatrixGnuPlot0.getDefaultPrintColNames());\n assertEquals(\"Whether to display the standard deviation column.\", resultMatrixGnuPlot0.showStdDevTipText());\n assertEquals(\"GNUPlot\", resultMatrixGnuPlot0.getDisplayName());\n assertEquals(0, resultMatrixGnuPlot0.getSignificanceWidth());\n assertFalse(resultMatrixGnuPlot0.getPrintColNames());\n assertEquals(\"Whether to remove the classname package prefixes from the filter names in datasets.\", resultMatrixGnuPlot0.removeFilterNameTipText());\n assertEquals(50, resultMatrixGnuPlot0.getDefaultRowNameWidth());\n assertEquals(\"The width of the mean (0 = optimal).\", resultMatrixGnuPlot0.meanWidthTipText());\n assertEquals(2, resultMatrixGnuPlot0.getStdDevPrec());\n assertEquals(\"The number of decimals after the decimal point for the standard deviation.\", resultMatrixGnuPlot0.stdDevPrecTipText());\n assertTrue(resultMatrixGnuPlot0.getDefaultPrintRowNames());\n assertEquals(\"Generates output for a data and script file for GnuPlot.\", resultMatrixGnuPlot0.globalInfo());\n assertFalse(resultMatrixGnuPlot0.getShowStdDev());\n assertEquals(\"The maximum width of the column names (0 = optimal).\", resultMatrixGnuPlot0.colNameWidthTipText());\n assertEquals(0, resultMatrixGnuPlot0.getColNameWidth());\n assertEquals(0, resultMatrixGnuPlot0.getMeanWidth());\n assertEquals(0, resultMatrixGnuPlot0.getDefaultCountWidth());\n assertEquals(1, resultMatrixGnuPlot0.getRowCount());\n assertEquals(25, resultMatrixGnuPlot0.getRowNameWidth());\n assertEquals(\"Whether to show the row with averages.\", resultMatrixGnuPlot0.showAverageTipText());\n assertTrue(resultMatrixGnuPlot0.getEnumerateColNames());\n assertFalse(resultMatrixGnuPlot0.getDefaultRemoveFilterName());\n assertEquals(2, resultMatrixGnuPlot0.getDefaultStdDevPrec());\n assertEquals(0, resultMatrixGnuPlot0.getDefaultSignificanceWidth());\n assertEquals(\"The number of decimals after the decimal point for the mean.\", resultMatrixGnuPlot0.meanPrecTipText());\n assertEquals(\"Whether to enumerate the row names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixGnuPlot0.enumerateRowNamesTipText());\n assertTrue(resultMatrixGnuPlot0.getEnumerateRowNames());\n assertEquals(\"Whether to output row names or just numbers representing them.\", resultMatrixGnuPlot0.printRowNamesTipText());\n assertFalse(resultMatrixGnuPlot0.getDefaultEnumerateRowNames());\n assertEquals(1, resultMatrixGnuPlot0.getColCount());\n assertEquals(1, resultMatrixGnuPlot0.getVisibleRowCount());\n assertFalse(resultMatrixGnuPlot0.getRemoveFilterName());\n assertFalse(resultMatrixGnuPlot0.getDefaultShowAverage());\n assertFalse(resultMatrixGnuPlot0.getDefaultShowStdDev());\n assertEquals(\"The maximum width for the row names (0 = optimal).\", resultMatrixGnuPlot0.rowNameWidthTipText());\n assertEquals(2, resultMatrixGnuPlot0.getMeanPrec());\n assertEquals(0, resultMatrixGnuPlot0.getDefaultStdDevWidth());\n assertEquals(50, resultMatrixGnuPlot0.getDefaultColNameWidth());\n assertEquals(\"Whether to enumerate the column names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixGnuPlot0.enumerateColNamesTipText());\n assertEquals(\"Whether to output column names or just numbers representing them.\", resultMatrixGnuPlot0.printColNamesTipText());\n assertEquals(0, resultMatrixGnuPlot0.getDefaultMeanWidth());\n assertEquals(661, resultMatrixGnuPlot0.getCountWidth());\n assertEquals(1, resultMatrixGnuPlot0.getVisibleColCount());\n assertTrue(resultMatrixGnuPlot0.getPrintRowNames());\n assertEquals(2, resultMatrixGnuPlot0.getDefaultMeanPrec());\n assertEquals(\"The width of the counts (0 = optimal).\", resultMatrixGnuPlot0.countWidthTipText());\n assertFalse(resultMatrixGnuPlot0.getDefaultEnumerateColNames());\n assertEquals(0, ResultMatrix.SIGNIFICANCE_TIE);\n assertEquals(1, ResultMatrix.SIGNIFICANCE_WIN);\n assertEquals(2, ResultMatrix.SIGNIFICANCE_LOSS);\n assertEquals(0, ResultMatrix.SIGNIFICANCE_TIE);\n assertEquals(2, ResultMatrix.SIGNIFICANCE_LOSS);\n assertEquals(1, ResultMatrix.SIGNIFICANCE_WIN);\n assertEquals(1, ResultMatrix.SIGNIFICANCE_WIN);\n assertEquals(2, ResultMatrix.SIGNIFICANCE_LOSS);\n assertEquals(0, ResultMatrix.SIGNIFICANCE_TIE);\n \n String string3 = resultMatrixHTML0.toStringRanking();\n assertEquals(0, resultMatrixLatex0.getMeanWidth());\n assertEquals(\"Whether to remove the classname package prefixes from the filter names in datasets.\", resultMatrixLatex0.removeFilterNameTipText());\n assertTrue(resultMatrixLatex0.getEnumerateColNames());\n assertEquals(0, resultMatrixLatex0.getDefaultStdDevWidth());\n assertEquals(\"The number of decimals after the decimal point for the standard deviation.\", resultMatrixLatex0.stdDevPrecTipText());\n assertEquals(0, resultMatrixLatex0.getStdDevWidth());\n assertEquals(1, resultMatrixLatex0.getVisibleColCount());\n assertEquals(\"Whether to enumerate the column names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixLatex0.enumerateColNamesTipText());\n assertEquals(\"The maximum width of the column names (0 = optimal).\", resultMatrixLatex0.colNameWidthTipText());\n assertFalse(resultMatrixLatex0.getRemoveFilterName());\n assertEquals(\"Whether to output column names or just numbers representing them.\", resultMatrixLatex0.printColNamesTipText());\n assertEquals(0, resultMatrixLatex0.getCountWidth());\n assertEquals(\"The width of the standard deviation (0 = optimal).\", resultMatrixLatex0.stdDevWidthTipText());\n assertEquals(\"The width of the significance indicator (0 = optimal).\", resultMatrixLatex0.significanceWidthTipText());\n assertEquals(\"LaTeX\", resultMatrixLatex0.getDisplayName());\n assertEquals(\"Whether to show the row with averages.\", resultMatrixLatex0.showAverageTipText());\n assertEquals(0, resultMatrixLatex0.getSignificanceWidth());\n assertFalse(resultMatrixLatex0.getShowStdDev());\n assertEquals(0, resultMatrixLatex0.getRowNameWidth());\n assertTrue(resultMatrixLatex0.getDefaultEnumerateColNames());\n assertFalse(resultMatrixLatex0.getShowAverage());\n assertEquals(\"The maximum width for the row names (0 = optimal).\", resultMatrixLatex0.rowNameWidthTipText());\n assertEquals(0, resultMatrixLatex0.getColNameWidth());\n assertFalse(resultMatrixLatex0.getDefaultEnumerateRowNames());\n assertEquals(0, resultMatrixLatex0.getDefaultRowNameWidth());\n assertFalse(resultMatrixLatex0.getDefaultShowAverage());\n assertEquals(2, resultMatrixLatex0.getMeanPrec());\n assertEquals(\"Whether to enumerate the row names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixLatex0.enumerateRowNamesTipText());\n assertEquals(0, resultMatrixLatex0.getDefaultCountWidth());\n assertFalse(resultMatrixLatex0.getEnumerateRowNames());\n assertFalse(resultMatrixLatex0.getPrintColNames());\n assertEquals(1, resultMatrixLatex0.getVisibleRowCount());\n assertEquals(2, resultMatrixLatex0.getDefaultStdDevPrec());\n assertEquals(1, resultMatrixLatex0.getRowCount());\n assertEquals(\"The number of decimals after the decimal point for the mean.\", resultMatrixLatex0.meanPrecTipText());\n assertEquals(2, resultMatrixLatex0.getDefaultMeanPrec());\n assertTrue(resultMatrixLatex0.getDefaultPrintRowNames());\n assertEquals(\"Whether to display the standard deviation column.\", resultMatrixLatex0.showStdDevTipText());\n assertFalse(resultMatrixLatex0.getDefaultPrintColNames());\n assertEquals(\"Whether to output row names or just numbers representing them.\", resultMatrixLatex0.printRowNamesTipText());\n assertTrue(resultMatrixLatex0.getPrintRowNames());\n assertEquals(\"The width of the counts (0 = optimal).\", resultMatrixLatex0.countWidthTipText());\n assertEquals(2, resultMatrixLatex0.getStdDevPrec());\n assertEquals(\"The width of the mean (0 = optimal).\", resultMatrixLatex0.meanWidthTipText());\n assertFalse(resultMatrixLatex0.getDefaultShowStdDev());\n assertEquals(0, resultMatrixLatex0.getDefaultSignificanceWidth());\n assertEquals(1, resultMatrixLatex0.getColCount());\n assertEquals(\"Generates the matrix output in LaTeX-syntax.\", resultMatrixLatex0.globalInfo());\n assertEquals(0, resultMatrixLatex0.getDefaultColNameWidth());\n assertEquals(0, resultMatrixLatex0.getDefaultMeanWidth());\n assertFalse(resultMatrixLatex0.getDefaultRemoveFilterName());\n assertEquals(0, resultMatrixHTML0.getColNameWidth());\n assertEquals(\"Whether to output column names or just numbers representing them.\", resultMatrixHTML0.printColNamesTipText());\n assertEquals(\"The number of decimals after the decimal point for the standard deviation.\", resultMatrixHTML0.stdDevPrecTipText());\n assertEquals(0, resultMatrixHTML0.getDefaultMeanWidth());\n assertEquals(\"Whether to enumerate the column names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixHTML0.enumerateColNamesTipText());\n assertEquals(25, resultMatrixHTML0.getDefaultRowNameWidth());\n assertEquals(\"The maximum width of the column names (0 = optimal).\", resultMatrixHTML0.colNameWidthTipText());\n assertEquals(0, resultMatrixHTML0.getMeanWidth());\n assertTrue(resultMatrixHTML0.getPrintRowNames());\n assertEquals(\"Whether to show the row with averages.\", resultMatrixHTML0.showAverageTipText());\n assertEquals(2, resultMatrixHTML0.getDefaultMeanPrec());\n assertEquals(0, resultMatrixHTML0.getStdDevWidth());\n assertEquals(0, resultMatrixHTML0.getDefaultStdDevWidth());\n assertTrue(resultMatrixHTML0.getEnumerateColNames());\n assertEquals(\"The maximum width for the row names (0 = optimal).\", resultMatrixHTML0.rowNameWidthTipText());\n assertTrue(resultMatrixHTML0.getDefaultEnumerateColNames());\n assertEquals(661, resultMatrixHTML0.getCountWidth());\n assertEquals(\"The width of the significance indicator (0 = optimal).\", resultMatrixHTML0.significanceWidthTipText());\n assertFalse(resultMatrixHTML0.getPrintColNames());\n assertTrue(resultMatrixHTML0.getEnumerateRowNames());\n assertEquals(0, resultMatrixHTML0.getSignificanceWidth());\n assertEquals(\"Whether to remove the classname package prefixes from the filter names in datasets.\", resultMatrixHTML0.removeFilterNameTipText());\n assertFalse(resultMatrixHTML0.getShowStdDev());\n assertEquals(2, resultMatrixHTML0.getMeanPrec());\n assertFalse(resultMatrixHTML0.getDefaultShowAverage());\n assertFalse(resultMatrixHTML0.getDefaultEnumerateRowNames());\n assertEquals(0, resultMatrixHTML0.getDefaultCountWidth());\n assertFalse(resultMatrixHTML0.getDefaultPrintColNames());\n assertEquals(25, resultMatrixHTML0.getRowNameWidth());\n assertEquals(0, resultMatrixHTML0.getDefaultSignificanceWidth());\n assertEquals(0, resultMatrixHTML0.getDefaultColNameWidth());\n assertEquals(2, resultMatrixHTML0.getDefaultStdDevPrec());\n assertEquals(2, resultMatrixHTML0.getStdDevPrec());\n assertFalse(resultMatrixHTML0.getShowAverage());\n assertEquals(\"The width of the counts (0 = optimal).\", resultMatrixHTML0.countWidthTipText());\n assertEquals(2417, resultMatrixHTML0.getVisibleColCount());\n assertFalse(resultMatrixHTML0.getDefaultRemoveFilterName());\n assertEquals(\"The width of the standard deviation (0 = optimal).\", resultMatrixHTML0.stdDevWidthTipText());\n assertEquals(\"Whether to output row names or just numbers representing them.\", resultMatrixHTML0.printRowNamesTipText());\n assertEquals(1, resultMatrixHTML0.getRowCount());\n assertEquals(\"The number of decimals after the decimal point for the mean.\", resultMatrixHTML0.meanPrecTipText());\n assertEquals(2417, resultMatrixHTML0.getColCount());\n assertEquals(\"Whether to display the standard deviation column.\", resultMatrixHTML0.showStdDevTipText());\n assertEquals(1, resultMatrixHTML0.getVisibleRowCount());\n assertEquals(\"Whether to enumerate the row names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixHTML0.enumerateRowNamesTipText());\n assertFalse(resultMatrixHTML0.getRemoveFilterName());\n assertFalse(resultMatrixHTML0.getDefaultShowStdDev());\n assertEquals(\"HTML\", resultMatrixHTML0.getDisplayName());\n assertEquals(\"Generates the matrix output as HTML.\", resultMatrixHTML0.globalInfo());\n assertEquals(\"The width of the mean (0 = optimal).\", resultMatrixHTML0.meanWidthTipText());\n assertTrue(resultMatrixHTML0.getDefaultPrintRowNames());\n assertEquals(\"The width of the standard deviation (0 = optimal).\", resultMatrixGnuPlot0.stdDevWidthTipText());\n assertFalse(resultMatrixGnuPlot0.getShowAverage());\n assertEquals(0, resultMatrixGnuPlot0.getStdDevWidth());\n assertEquals(\"The width of the significance indicator (0 = optimal).\", resultMatrixGnuPlot0.significanceWidthTipText());\n assertTrue(resultMatrixGnuPlot0.getDefaultPrintColNames());\n assertEquals(\"Whether to display the standard deviation column.\", resultMatrixGnuPlot0.showStdDevTipText());\n assertEquals(\"GNUPlot\", resultMatrixGnuPlot0.getDisplayName());\n assertEquals(0, resultMatrixGnuPlot0.getSignificanceWidth());\n assertFalse(resultMatrixGnuPlot0.getPrintColNames());\n assertEquals(\"Whether to remove the classname package prefixes from the filter names in datasets.\", resultMatrixGnuPlot0.removeFilterNameTipText());\n assertEquals(50, resultMatrixGnuPlot0.getDefaultRowNameWidth());\n assertEquals(\"The width of the mean (0 = optimal).\", resultMatrixGnuPlot0.meanWidthTipText());\n assertEquals(2, resultMatrixGnuPlot0.getStdDevPrec());\n assertEquals(\"The number of decimals after the decimal point for the standard deviation.\", resultMatrixGnuPlot0.stdDevPrecTipText());\n assertTrue(resultMatrixGnuPlot0.getDefaultPrintRowNames());\n assertEquals(\"Generates output for a data and script file for GnuPlot.\", resultMatrixGnuPlot0.globalInfo());\n assertFalse(resultMatrixGnuPlot0.getShowStdDev());\n assertEquals(\"The maximum width of the column names (0 = optimal).\", resultMatrixGnuPlot0.colNameWidthTipText());\n assertEquals(0, resultMatrixGnuPlot0.getColNameWidth());\n assertEquals(0, resultMatrixGnuPlot0.getMeanWidth());\n assertEquals(0, resultMatrixGnuPlot0.getDefaultCountWidth());\n assertEquals(1, resultMatrixGnuPlot0.getRowCount());\n assertEquals(25, resultMatrixGnuPlot0.getRowNameWidth());\n assertEquals(\"Whether to show the row with averages.\", resultMatrixGnuPlot0.showAverageTipText());\n assertTrue(resultMatrixGnuPlot0.getEnumerateColNames());\n assertFalse(resultMatrixGnuPlot0.getDefaultRemoveFilterName());\n assertEquals(2, resultMatrixGnuPlot0.getDefaultStdDevPrec());\n assertEquals(0, resultMatrixGnuPlot0.getDefaultSignificanceWidth());\n assertEquals(\"The number of decimals after the decimal point for the mean.\", resultMatrixGnuPlot0.meanPrecTipText());\n assertEquals(\"Whether to enumerate the row names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixGnuPlot0.enumerateRowNamesTipText());\n assertTrue(resultMatrixGnuPlot0.getEnumerateRowNames());\n assertEquals(\"Whether to output row names or just numbers representing them.\", resultMatrixGnuPlot0.printRowNamesTipText());\n assertFalse(resultMatrixGnuPlot0.getDefaultEnumerateRowNames());\n assertEquals(1, resultMatrixGnuPlot0.getColCount());\n assertEquals(1, resultMatrixGnuPlot0.getVisibleRowCount());\n assertFalse(resultMatrixGnuPlot0.getRemoveFilterName());\n assertFalse(resultMatrixGnuPlot0.getDefaultShowAverage());\n assertFalse(resultMatrixGnuPlot0.getDefaultShowStdDev());\n assertEquals(\"The maximum width for the row names (0 = optimal).\", resultMatrixGnuPlot0.rowNameWidthTipText());\n assertEquals(2, resultMatrixGnuPlot0.getMeanPrec());\n assertEquals(0, resultMatrixGnuPlot0.getDefaultStdDevWidth());\n assertEquals(50, resultMatrixGnuPlot0.getDefaultColNameWidth());\n assertEquals(\"Whether to enumerate the column names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixGnuPlot0.enumerateColNamesTipText());\n assertEquals(\"Whether to output column names or just numbers representing them.\", resultMatrixGnuPlot0.printColNamesTipText());\n assertEquals(0, resultMatrixGnuPlot0.getDefaultMeanWidth());\n assertEquals(661, resultMatrixGnuPlot0.getCountWidth());\n assertEquals(1, resultMatrixGnuPlot0.getVisibleColCount());\n assertTrue(resultMatrixGnuPlot0.getPrintRowNames());\n assertEquals(2, resultMatrixGnuPlot0.getDefaultMeanPrec());\n assertEquals(\"The width of the counts (0 = optimal).\", resultMatrixGnuPlot0.countWidthTipText());\n assertFalse(resultMatrixGnuPlot0.getDefaultEnumerateColNames());\n assertNotNull(string3);\n assertEquals(0, ResultMatrix.SIGNIFICANCE_TIE);\n assertEquals(1, ResultMatrix.SIGNIFICANCE_WIN);\n assertEquals(2, ResultMatrix.SIGNIFICANCE_LOSS);\n assertEquals(0, ResultMatrix.SIGNIFICANCE_TIE);\n assertEquals(2, ResultMatrix.SIGNIFICANCE_LOSS);\n assertEquals(1, ResultMatrix.SIGNIFICANCE_WIN);\n assertEquals(1, ResultMatrix.SIGNIFICANCE_WIN);\n assertEquals(2, ResultMatrix.SIGNIFICANCE_LOSS);\n assertEquals(0, ResultMatrix.SIGNIFICANCE_TIE);\n assertEquals(\"-ranking data not set-\", string3);\n assertFalse(string3.equals((Object)string1));\n assertFalse(string3.equals((Object)string0));\n assertFalse(string3.equals((Object)string2));\n \n String string4 = resultMatrixCSV0.countWidthTipText();\n assertFalse(resultMatrixCSV0.getDefaultShowStdDev());\n assertEquals(\"Whether to output row names or just numbers representing them.\", resultMatrixCSV0.printRowNamesTipText());\n assertEquals(\"The width of the counts (0 = optimal).\", resultMatrixCSV0.countWidthTipText());\n assertEquals(0, resultMatrixCSV0.getDefaultColNameWidth());\n assertEquals(\"The maximum width for the row names (0 = optimal).\", resultMatrixCSV0.rowNameWidthTipText());\n assertEquals(\"The number of decimals after the decimal point for the mean.\", resultMatrixCSV0.meanPrecTipText());\n assertTrue(resultMatrixCSV0.getEnumerateRowNames());\n assertEquals(0, resultMatrixCSV0.getDefaultSignificanceWidth());\n assertEquals(\"Generates the matrix in CSV ('comma-separated values') format.\", resultMatrixCSV0.globalInfo());\n assertEquals(0, resultMatrixCSV0.getCountWidth());\n assertFalse(resultMatrixCSV0.getDefaultRemoveFilterName());\n assertFalse(resultMatrixCSV0.getRemoveFilterName());\n assertEquals(1, resultMatrixCSV0.getColCount());\n assertEquals(1, resultMatrixCSV0.getVisibleRowCount());\n assertEquals(\"Whether to enumerate the row names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixCSV0.enumerateRowNamesTipText());\n assertEquals(0, resultMatrixCSV0.getColNameWidth());\n assertFalse(resultMatrixCSV0.getDefaultEnumerateRowNames());\n assertEquals(0, resultMatrixCSV0.getDefaultMeanWidth());\n assertEquals(\"The number of decimals after the decimal point for the standard deviation.\", resultMatrixCSV0.stdDevPrecTipText());\n assertEquals(\"Whether to enumerate the column names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixCSV0.enumerateColNamesTipText());\n assertEquals(2, resultMatrixCSV0.getMeanPrec());\n assertEquals(\"Whether to output column names or just numbers representing them.\", resultMatrixCSV0.printColNamesTipText());\n assertFalse(resultMatrixCSV0.getDefaultPrintColNames());\n assertEquals(\"Whether to remove the classname package prefixes from the filter names in datasets.\", resultMatrixCSV0.removeFilterNameTipText());\n assertEquals(\"The width of the significance indicator (0 = optimal).\", resultMatrixCSV0.significanceWidthTipText());\n assertEquals(0, resultMatrixCSV0.getDefaultStdDevWidth());\n assertTrue(resultMatrixCSV0.getPrintRowNames());\n assertEquals(2, resultMatrixCSV0.getDefaultMeanPrec());\n assertEquals(1, resultMatrixCSV0.getVisibleColCount());\n assertEquals(2, resultMatrixCSV0.getStdDevPrec());\n assertEquals(\"The width of the mean (0 = optimal).\", resultMatrixCSV0.meanWidthTipText());\n assertFalse(resultMatrixCSV0.getShowStdDev());\n assertTrue(resultMatrixCSV0.getDefaultPrintRowNames());\n assertEquals(\"Whether to display the standard deviation column.\", resultMatrixCSV0.showStdDevTipText());\n assertEquals(\"The width of the standard deviation (0 = optimal).\", resultMatrixCSV0.stdDevWidthTipText());\n assertFalse(resultMatrixCSV0.getPrintColNames());\n assertEquals(0, resultMatrixCSV0.getSignificanceWidth());\n assertEquals(25, resultMatrixCSV0.getRowNameWidth());\n assertFalse(resultMatrixCSV0.getDefaultShowAverage());\n assertTrue(resultMatrixCSV0.getDefaultEnumerateColNames());\n assertEquals(0, resultMatrixCSV0.getMeanWidth());\n assertTrue(resultMatrixCSV0.getEnumerateColNames());\n assertEquals(25, resultMatrixCSV0.getDefaultRowNameWidth());\n assertEquals(0, resultMatrixCSV0.getDefaultCountWidth());\n assertFalse(resultMatrixCSV0.getShowAverage());\n assertEquals(1, resultMatrixCSV0.getRowCount());\n assertEquals(2, resultMatrixCSV0.getDefaultStdDevPrec());\n assertEquals(\"The maximum width of the column names (0 = optimal).\", resultMatrixCSV0.colNameWidthTipText());\n assertEquals(0, resultMatrixCSV0.getStdDevWidth());\n assertEquals(\"Whether to show the row with averages.\", resultMatrixCSV0.showAverageTipText());\n assertEquals(\"CSV\", resultMatrixCSV0.getDisplayName());\n assertNotNull(string4);\n assertEquals(2, ResultMatrix.SIGNIFICANCE_LOSS);\n assertEquals(1, ResultMatrix.SIGNIFICANCE_WIN);\n assertEquals(0, ResultMatrix.SIGNIFICANCE_TIE);\n assertEquals(\"The width of the counts (0 = optimal).\", string4);\n assertFalse(string4.equals((Object)string2));\n assertFalse(string4.equals((Object)string0));\n assertFalse(string4.equals((Object)string1));\n assertFalse(string4.equals((Object)string3));\n \n String string5 = resultMatrixLatex0.globalInfo();\n assertEquals(0, resultMatrixLatex0.getMeanWidth());\n assertEquals(\"Whether to remove the classname package prefixes from the filter names in datasets.\", resultMatrixLatex0.removeFilterNameTipText());\n assertTrue(resultMatrixLatex0.getEnumerateColNames());\n assertEquals(0, resultMatrixLatex0.getDefaultStdDevWidth());\n assertEquals(\"The number of decimals after the decimal point for the standard deviation.\", resultMatrixLatex0.stdDevPrecTipText());\n assertEquals(0, resultMatrixLatex0.getStdDevWidth());\n assertEquals(1, resultMatrixLatex0.getVisibleColCount());\n assertEquals(\"Whether to enumerate the column names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixLatex0.enumerateColNamesTipText());\n assertEquals(\"The maximum width of the column names (0 = optimal).\", resultMatrixLatex0.colNameWidthTipText());\n assertFalse(resultMatrixLatex0.getRemoveFilterName());\n assertEquals(\"Whether to output column names or just numbers representing them.\", resultMatrixLatex0.printColNamesTipText());\n assertEquals(0, resultMatrixLatex0.getCountWidth());\n assertEquals(\"The width of the standard deviation (0 = optimal).\", resultMatrixLatex0.stdDevWidthTipText());\n assertEquals(\"The width of the significance indicator (0 = optimal).\", resultMatrixLatex0.significanceWidthTipText());\n assertEquals(\"LaTeX\", resultMatrixLatex0.getDisplayName());\n assertEquals(\"Whether to show the row with averages.\", resultMatrixLatex0.showAverageTipText());\n assertEquals(0, resultMatrixLatex0.getSignificanceWidth());\n assertFalse(resultMatrixLatex0.getShowStdDev());\n assertEquals(0, resultMatrixLatex0.getRowNameWidth());\n assertTrue(resultMatrixLatex0.getDefaultEnumerateColNames());\n assertFalse(resultMatrixLatex0.getShowAverage());\n assertEquals(\"The maximum width for the row names (0 = optimal).\", resultMatrixLatex0.rowNameWidthTipText());\n assertEquals(0, resultMatrixLatex0.getColNameWidth());\n assertFalse(resultMatrixLatex0.getDefaultEnumerateRowNames());\n assertEquals(0, resultMatrixLatex0.getDefaultRowNameWidth());\n assertFalse(resultMatrixLatex0.getDefaultShowAverage());\n assertEquals(2, resultMatrixLatex0.getMeanPrec());\n assertEquals(\"Whether to enumerate the row names (prefixing them with '(x)', with 'x' being the index).\", resultMatrixLatex0.enumerateRowNamesTipText());\n assertEquals(0, resultMatrixLatex0.getDefaultCountWidth());\n assertFalse(resultMatrixLatex0.getEnumerateRowNames());\n assertFalse(resultMatrixLatex0.getPrintColNames());\n assertEquals(1, resultMatrixLatex0.getVisibleRowCount());\n assertEquals(2, resultMatrixLatex0.getDefaultStdDevPrec());\n assertEquals(1, resultMatrixLatex0.getRowCount());\n assertEquals(\"The number of decimals after the decimal point for the mean.\", resultMatrixLatex0.meanPrecTipText());\n assertEquals(2, resultMatrixLatex0.getDefaultMeanPrec());\n assertTrue(resultMatrixLatex0.getDefaultPrintRowNames());\n assertEquals(\"Whether to display the standard deviation column.\", resultMatrixLatex0.showStdDevTipText());\n assertFalse(resultMatrixLatex0.getDefaultPrintColNames());\n assertEquals(\"Whether to output row names or just numbers representing them.\", resultMatrixLatex0.printRowNamesTipText());\n assertTrue(resultMatrixLatex0.getPrintRowNames());\n assertEquals(\"The width of the counts (0 = optimal).\", resultMatrixLatex0.countWidthTipText());\n assertEquals(2, resultMatrixLatex0.getStdDevPrec());\n assertEquals(\"The width of the mean (0 = optimal).\", resultMatrixLatex0.meanWidthTipText());\n assertFalse(resultMatrixLatex0.getDefaultShowStdDev());\n assertEquals(0, resultMatrixLatex0.getDefaultSignificanceWidth());\n assertEquals(1, resultMatrixLatex0.getColCount());\n assertEquals(\"Generates the matrix output in LaTeX-syntax.\", resultMatrixLatex0.globalInfo());\n assertEquals(0, resultMatrixLatex0.getDefaultColNameWidth());\n assertEquals(0, resultMatrixLatex0.getDefaultMeanWidth());\n assertFalse(resultMatrixLatex0.getDefaultRemoveFilterName());\n assertNotNull(string5);\n assertEquals(0, ResultMatrix.SIGNIFICANCE_TIE);\n assertEquals(1, ResultMatrix.SIGNIFICANCE_WIN);\n assertEquals(2, ResultMatrix.SIGNIFICANCE_LOSS);\n assertEquals(\"Generates the matrix output in LaTeX-syntax.\", string5);\n assertFalse(string5.equals((Object)string0));\n assertFalse(string5.equals((Object)string4));\n assertFalse(string5.equals((Object)string2));\n assertFalse(string5.equals((Object)string1));\n assertFalse(string5.equals((Object)string3));\n \n String[][] stringArray0 = new String[6][8];\n String[] stringArray1 = new String[6];\n stringArray1[0] = \"$circ$\";\n stringArray1[1] = \"]\";\n stringArray1[2] = \" \";\n stringArray1[3] = \"]\";\n stringArray1[4] = \"v\";\n stringArray1[5] = \"The width of the counts (0 = optimal).\";\n stringArray0[0] = stringArray1;\n String[] stringArray2 = new String[9];\n assertFalse(stringArray2.equals((Object)stringArray1));\n \n stringArray2[0] = \"v\";\n stringArray2[1] = \"*\";\n stringArray2[2] = \"[\";\n stringArray2[3] = \"-summary data not set-\";\n stringArray2[4] = \"Generates the matrix output in LaTeX-syntax.\";\n stringArray2[5] = \"(\";\n stringArray2[6] = \"(\";\n stringArray2[7] = \" \";\n stringArray2[8] = \" \";\n stringArray0[1] = stringArray2;\n String[] stringArray3 = new String[2];\n assertFalse(stringArray3.equals((Object)stringArray1));\n assertFalse(stringArray3.equals((Object)stringArray2));\n \n stringArray3[0] = \"[\";\n stringArray3[1] = \"[\";\n stringArray0[2] = stringArray3;\n String[] stringArray4 = new String[1];\n assertFalse(stringArray4.equals((Object)stringArray2));\n assertFalse(stringArray4.equals((Object)stringArray1));\n assertFalse(stringArray4.equals((Object)stringArray3));\n \n stringArray4[0] = \"\";\n stringArray0[3] = stringArray4;\n String[] stringArray5 = new String[6];\n assertFalse(stringArray5.equals((Object)stringArray2));\n assertFalse(stringArray5.equals((Object)stringArray1));\n assertFalse(stringArray5.equals((Object)stringArray4));\n assertFalse(stringArray5.equals((Object)stringArray3));\n \n stringArray5[0] = \"$circ$\";\n stringArray5[1] = \"\\n##################\\n# file: plot.dat #\\n##################\\n# generated by WEKA 3.7.7\\n# contains the data for the plot\\n\\n# key for the x-axis\\n# 1 - row0\\n\\n# data for the plot\\n1 ''\\n#######\\n# end #\\n#######\\n\\n##################\\n# file: plot.scr #\\n##################\\n# generated by WEKA 3.7.7\\n# script to plot the data\\n\\n# display it in a window:\\nset terminal x11\\nset output\\n\\n# to display all data rows:\\nset xrange [0:2]\\n\\n# axis labels, e.g.:\\n#set xlabel \\\"Datasets\\\"\\n#set ylabel \\\"Accuracy in %\\\"\\n\\n# the plot commands\\nplot \\\"plot.dat\\\" using 1:2 with lines title \\\"(1)\\\"\\n\\n# generate ps:\\n#set terminal postscript\\n#set output \\\"plot.ps\\\"\\n#replot\\n\\n# generate png:\\n#set terminal png size 800,600\\n#set output \\\"plot.png\\\"\\n#replot\\n\\n# wait for user to hit <Return>\\npause -1\\n#######\\n# end #\\n#######\\n\";\n stringArray5[2] = \"*\";\n stringArray5[3] = \" \";\n stringArray5[4] = \"$circ$\";\n stringArray5[5] = \" \";\n stringArray0[4] = stringArray5;\n String[] stringArray6 = new String[7];\n assertFalse(stringArray6.equals((Object)stringArray5));\n assertFalse(stringArray6.equals((Object)stringArray3));\n assertFalse(stringArray6.equals((Object)stringArray2));\n assertFalse(stringArray6.equals((Object)stringArray1));\n assertFalse(stringArray6.equals((Object)stringArray4));\n \n stringArray6[0] = \"]\";\n stringArray6[1] = \" \";\n stringArray6[2] = \"v\";\n stringArray6[3] = \"v\";\n stringArray6[4] = \" \";\n stringArray6[5] = \"$circ$\";\n stringArray6[6] = \"v\";\n stringArray0[5] = stringArray6;\n // Undeclared exception!\n try { \n resultMatrixLatex0.getColSize(stringArray0, 2, true, true);\n fail(\"Expecting exception: ArrayIndexOutOfBoundsException\");\n \n } catch(ArrayIndexOutOfBoundsException e) {\n //\n // 2\n //\n verifyException(\"weka.experiment.ResultMatrix\", e);\n }\n }", "private static void createAnalysisInterface(List<String> genericArguments, String name, String tag, MethodFactory extMf, Environment extEnv, Environment result) {\n \t\tJavaName jname = new JavaName(result.getDefaultPackage(), \"I\"+extEnv.getName()+name);\n \t\tInterfaceDefinition extNewDef = new InterfaceDefinition(jname);\n \t\textNewDef.setTag(tag);\n \t\textNewDef.setGenericArguments(genericArguments);\n \t\tresult.addInterface(extNewDef);\n \t\tIInterfaceDefinition iAnalysis = result.lookUpType(\"IAnalysis\");\n \t\textNewDef.supers.add(iAnalysis);\n \n \t\t// Add methods for the analysis and apply functions for the classes\n \t\tfor(IClassDefinition cdef : result.getClasses())\n \t\t{\n \t\t\tEnvironment env = null;\n \t\t\tIInterfaceDefinition newDef = null;\n \t\t\tMethodFactory mf = null;\n \t\t\tif (extEnv.classToType.containsKey(cdef))\n \t\t\t{\n \t\t\t\tmf = extMf;\n \t\t\t\tnewDef = extNewDef;\n \t\t\t\tenv = extEnv;\n \t\t\t}\n \n \t\t\t// Should it have an apply method and a case in the analysis?\n \t\t\tif (mf != null)\n \t\t\t\tswitch(env.classToType.get(cdef))\n \t\t\t\t{\n \t\t\t\tcase Alternative:\n \t\t\t\tcase Token:\n \t\t\t\t{\n \t\t\t\t\tmf.updateApplyMethod(cdef, jname.getCanonicalName());\n \n \t\t\t\t\tMethod caseMethod = mf.createCaseMethod(cdef);\n \t\t\t\t\tnewDef.addMethod(caseMethod);\n \t\t\t\t\t\n \t\t\t\t\t// remove this case from IAnalysis\n \t\t\t\t\tList<Method> toBeRemoved = new LinkedList<Method>();\n \t\t\t\t\tfor(Method m : iAnalysis.getMethods())\n \t\t\t\t\t{\n \t\t\t\t\t\tif (m.classDefinition == cdef)\n \t\t\t\t\t\t\ttoBeRemoved.add(m);\n \t\t\t\t\t}\n \t\t\t\t\tiAnalysis.getMethods().removeAll(toBeRemoved);\n \n \t\t\t\t}\n \t\t\t\tbreak;\n \t\t\t\tdefault:\n \t\t\t\t\tbreak;\n \t\t\t\t}\n \t\t}\n \n \t}", "@Test\r\n\tpublic void testAddNote() throws Exception {\r\n\t\tyakshaAssert(currentTest(), \"true\", exceptionTestFile);\r\n\t}", "@Test(timeout = 4000)\n public void test124() throws Throwable {\n Frame frame0 = new Frame();\n ClassWriter classWriter0 = new ClassWriter(3131);\n classWriter0.visitField(182, \"IK\", \"IK\", \"IK\", \"The FileFilter must not be null\");\n ClassWriter classWriter1 = new ClassWriter(1);\n Item item0 = classWriter0.key2;\n FileSystemHandling.setPermissions((EvoSuiteFile) null, false, false, false);\n byte[] byteArray0 = new byte[8];\n byteArray0[0] = (byte)7;\n byteArray0[1] = (byte) (-59);\n byteArray0[2] = (byte)9;\n byteArray0[3] = (byte) (-99);\n byteArray0[4] = (byte) (-51);\n byteArray0[5] = (byte) (-80);\n byteArray0[6] = (byte)7;\n byteArray0[7] = (byte) (-80);\n FileSystemHandling.appendDataToFile((EvoSuiteFile) null, byteArray0);\n classWriter0.newClassItem(\"\");\n classWriter0.newLong((byte) (-80));\n // Undeclared exception!\n try { \n frame0.execute(16777220, (byte) (-99), classWriter1, item0);\n fail(\"Expecting exception: StringIndexOutOfBoundsException\");\n \n } catch(StringIndexOutOfBoundsException e) {\n }\n }", "public void testCount()\n\t{\n\t\tinfo.append(a1);\n\t\tinfo.append(a2);\n\t\tinfo.append(a3);\n\t\tassertEquals(3,info.getSynonymsCount());\n\t}", "public interface TestReporterAppender {\n\n void logMessage(String sMessage, boolean bError);\n\n void logMessage(String sMessage, Throwable t);\n\n void init();\n\n void traceExecution(CommandRequest cRequest, OpResult rResult);\n\n void traceExecution(HttpOpRequest request);\n}", "@Test\r\n\tpublic void testWriter() {\r\n\t\tString s = \"This is a test of the writer\";\r\n\t\tWriter w = new Writer();\r\n\t\tassertThat(w, is(notNullValue()));\r\n\t\t\r\n\t\tw.write(s);\r\n\t\tassertThat(w.read(), is(s));\r\n\t}", "@Test\n public void testWriteEntry_4args() {\n //System.out.println(\"writeEntry\");\n LemonSerializerImpl instance = new LemonSerializerImpl(null);\n LemonModel model = makeModel(instance);\n LexicalEntry entry = model.getLexica().iterator().next().getEntrys().iterator().next();\n LinguisticOntology lingOnto = new LexInfo();\n Writer target = new StringWriter();\n instance.writeEntry(model, entry, lingOnto, target);\n //System.out.println(target.toString());\n }", "@Test\n\tpublic void testWrite(){\n\t\tGameWorld gw = getGameWorld();\n\t\ttry{\n\t\t\tXMLWriter writer = new XMLWriter(\"testWrite\");\n\t\t\twriter.write(gw);\n\t\t\twriter.close();\n\t\t} catch(FileNotFoundException e){\n\t\t\te.printStackTrace();\n\t\t\tfail(\"XMLWriter, testWrite.xml not found\");\n\t\t} catch(IntrospectionException e){\n\t\t\te.printStackTrace();\n\t\t\tfail(\"XMLWriter, introspection failure\");\n\t\t}\n\t}", "@Test\n @Ignore\n public void testAdd_intArr() {\n System.out.println(\"add\");\n int[] number = null;\n AbstractMethod instance = new AbstractMethodImpl();\n int expResult = 0;\n int result = instance.add(number);\n assertEquals(expResult, result);\n // TODO Test muss noch erstellt werden..\n fail(\"Test muss noch erstellt werden.\");\n }", "public Analyse setInfoFromMethode(Analyse analysis, Methode method) {\n analysis.setMethode(method);\r\n analysis.setMethodename(method.getMethodename());\r\n //System.out.println(\" dans setInfoFromMethode avant retour \"+analysis.getSample() );\r\n analysis.setCreationdate(DateManager.getNow());\r\n return analysis;\r\n }", "@Test\n public void testWriteEntry_5args() {\n String expResult = \"@prefix lemon: <http://lemon-model.net/lemon#> . \" + ls\n + \"@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . \" + ls\n + \"\" + ls\n + \"<file:test#Cat/sense> a lemon:LexicalSense ;\" + ls\n + \" lemon:reference <http://dbpedia.org/resource/Cat> .\" + ls\n + \"\" + ls\n + \"<file:test#Cat/canonicalForm> lemon:writtenRep \\\"cat\\\"@en ;\" + ls\n + \" a lemon:Form .\" + ls\n + \"\" + ls\n + \"<file:test#Cat> lemon:sense <file:test#Cat/sense> ;\" + ls\n + \" lemon:canonicalForm <file:test#Cat/canonicalForm> ;\" + ls\n + \" a lemon:LexicalEntry .\";\n //System.out.println(\"writeEntry\");\n LemonSerializerImpl instance = new LemonSerializerImpl(null);\n LemonModel lm = makeModel(instance);\n LexicalEntry le = lm.getLexica().iterator().next().getEntrys().iterator().next();\n LinguisticOntology lo = new LexInfo();\n Writer dt = new StringWriter();\n boolean xml = false;\n instance.writeEntry(lm, le, lo, dt, xml);\n assertEquals(expResult, dt.toString().trim());\n }", "public interface ITestDataAnalyzer {\n List<INameValue> getAllTestInputs();\n INameValue getTestInput(String name);\n List<INameValue> getAllExpectedValues();\n INameValue getExpectedValue(String name);\n List<TestValueResult> getValueResults(List<INameValue> actualValues);\n}", "@Test\n public void testAddACopy() {\n }", "public void fnWriteTestSummary(String strTestCaseName, String strResult, String strDuration){\r\n \tString sColor,sRowColor;\r\n \r\n //Close the file\r\n try{ \r\n\t //Open the test case report for writing \r\n\t foutStrm = new FileOutputStream(Environment.get(\"HTMLREPORTSPATH\")+ \"\\\\SummaryReport.html\", true);\r\n\t \r\n\t //Check color result\r\n\t if (strResult.toUpperCase().equals(\"PASSED\") || strResult.toUpperCase().equals(\"PASS\")){\r\n\t sColor = \"GREEN\";\r\n\t g_iTCPassed ++;\r\n\t }\r\n\t else if (strResult.toUpperCase().equals(\"FAILED\") || strResult.toUpperCase().equals(\"FAIL\")){\r\n\t \tsColor = \"RED\";\r\n\t }\r\n\t else{\r\n\t \tsColor = \"ORANGE\";\r\n\t }\r\n\t\r\n\t g_iTestCaseNo++;\r\n\t\r\n\t if (g_iTestCaseNo % 2 == 0){sRowColor = \"#EEEEEE\";}\r\n\t else{sRowColor = \"#D3D3D3\";}\r\n\t \r\n\t //Write the result of Individual Test Case\r\n\t new PrintStream(foutStrm).println (\"<TR COLS=3 BGCOLOR=\" + sRowColor + \"><TD WIDTH=10%><FONT FACE=VERDANA SIZE=2>\" + g_iTestCaseNo + \"</FONT></TD><TD WIDTH=60%><FONT FACE=VERDANA SIZE=2>\" + strTestCaseName + \"</FONT></TD><TD WIDTH=15%><A HREF='\" + strTestCaseName + \".html'><FONT FACE=VERDANA SIZE=2 COLOR=\" + sColor + \"><B>\" + strResult + \"</B></FONT></A></TD><TD WIDTH=15%><FONT FACE=VERDANA SIZE=2>\" + strDuration+ \"</FONT></TD></TR>\");\r\n \r\n \tfoutStrm.close();\r\n }\r\n catch (IOException io) \r\n\t\t{\r\n\t\t\tio.printStackTrace();\r\n\t\t}\r\n foutStrm = null;\r\n\r\n }", "public ExplanationPipeline<I, F> addWithTest(ExplanationMapper toAdd) {\n return addWithTest(toAdd, false);\n }" ]
[ "0.64537716", "0.60981345", "0.5784195", "0.56803554", "0.5666856", "0.56443", "0.5621723", "0.5621321", "0.55791336", "0.5500442", "0.5496254", "0.5456408", "0.5449346", "0.5443142", "0.54246634", "0.53983027", "0.53906053", "0.5356966", "0.5346102", "0.5336792", "0.53323907", "0.5318616", "0.5296432", "0.52963", "0.5222543", "0.51796573", "0.5176035", "0.5168408", "0.5167164", "0.5151503", "0.5150265", "0.509916", "0.50982744", "0.50753087", "0.50688356", "0.5049257", "0.50488096", "0.5030234", "0.5013208", "0.501132", "0.50111324", "0.5008646", "0.5002598", "0.5001484", "0.49908778", "0.49905464", "0.49802297", "0.4979672", "0.49789673", "0.4967214", "0.49667677", "0.49641734", "0.49641553", "0.4961228", "0.49496624", "0.49435377", "0.49395674", "0.49382812", "0.4932129", "0.49240866", "0.49198797", "0.49187592", "0.4909967", "0.48960873", "0.48931512", "0.48883253", "0.48861977", "0.48838443", "0.4879741", "0.4876949", "0.4871322", "0.48686314", "0.48646423", "0.4860901", "0.48595855", "0.48589358", "0.48447695", "0.48356113", "0.48307735", "0.4829199", "0.48129323", "0.4812103", "0.48095724", "0.4807448", "0.48025754", "0.48000613", "0.47990298", "0.4796636", "0.47936365", "0.4790371", "0.4784573", "0.4783828", "0.47837195", "0.47822237", "0.47818562", "0.47749755", "0.47713146", "0.4769923", "0.4765888", "0.47621092" ]
0.6996735
0
Created by j on 2016/11/16.
public interface GitHubService { // @GET("article/list/1/15/1") // Call<JinXuanBean> getQuamZiData(); @GET("article/list/{page}/15/{type}") Call<JinXuanBean> getQuamZiData(@Path("page") int page, @Path("type") int type); @GET("article/{articleId}") Call<ArticleBean> getArticle(@Path("articleId") int articleId); @GET("review/article/content/{page}/15/{articleId}") Call<Comment> getComment(@Path("page") int page, @Path("articleId") int articleId); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n public void perish() {\n \n }", "@Override\n\tpublic void comer() {\n\t\t\n\t}", "@Override\n\tpublic void grabar() {\n\t\t\n\t}", "private stendhal() {\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\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}", "@Override\r\n\tpublic void tires() {\n\t\t\r\n\t}", "@Override\n\tprotected void getExras() {\n\n\t}", "@Override\n public void func_104112_b() {\n \n }", "private static void cajas() {\n\t\t\n\t}", "@Override\n\tpublic void anular() {\n\n\t}", "@Override\n\tpublic void nadar() {\n\t\t\n\t}", "private void poetries() {\n\n\t}", "@Override\n\tprotected void interr() {\n\t}", "public final void mo51373a() {\n }", "@Override\n\tpublic void entrenar() {\n\t\t\n\t}", "@Override\r\n\tpublic void dormir() {\n\t\t\r\n\t}", "public void gored() {\n\t\t\n\t}", "private void kk12() {\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\tpublic void sacrifier() {\n\t\t\n\t}", "@Override\r\n\t\t\tpublic void annadir() {\n\r\n\t\t\t}", "public void mo38117a() {\n }", "@Override\r\n\t\tpublic void init() {\n\t\t\t\r\n\t\t}", "@Override\r\n\tpublic void rozmnozovat() {\n\t}", "@Override\n\tpublic void jugar() {\n\t\t\n\t}", "protected boolean func_70814_o() { return true; }", "@Override\n\tpublic void gravarBd() {\n\t\t\n\t}", "@Override\n protected void getExras() {\n }", "@Override\n protected void initialize() {\n\n \n }", "@Override\r\n\tpublic void anularFact() {\n\t\t\r\n\t}", "private void init() {\n\n\t}", "public void mo4359a() {\n }", "@Override\n\tpublic void one() {\n\t\t\n\t}", "@Override\n public void init() {\n }", "private void m50366E() {\n }", "@Override\n\tpublic void nghe() {\n\n\t}", "@Override\n\tpublic void ligar() {\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}", "@Override\n void init() {\n }", "@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 init() {\n\n\t}", "@Override\n\tpublic void init() {\n\n\t}", "@Override\n\tpublic void init() {\n\n\t}", "@Override\n public int describeContents() { return 0; }", "@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\r\n\t\t\tpublic void ayuda() {\n\r\n\t\t\t}", "@Override\n public void init() {\n\n }", "@Override\n public void init() {\n\n }", "private void strin() {\n\n\t}", "@Override\r\n\tpublic void init() {}", "@Override\n\tpublic void einkaufen() {\n\t}", "@Override\n protected void init() {\n }", "@Override\n public void init() {}", "@Override\n\tpublic int mettreAJour() {\n\t\treturn 0;\n\t}", "@Override\r\n\tprotected void initialize() {\r\n\t\t\r\n\t\t\r\n\t}", "@Override\r\n\tpublic void init()\r\n\t{\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 init()\n\t{\n\n\t}", "@Override\n\tpublic void init() {\n\t}", "@Override\n protected void initialize() \n {\n \n }", "@Override\n public int retroceder() {\n return 0;\n }", "@Override\r\n\tprotected void doF4() {\n\t\t\r\n\t}", "@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\n\tprotected void initialize() {\n\n\t}", "@Override\n\tpublic void debite() {\n\t\t\n\t}", "Constructor() {\r\n\t\t \r\n\t }", "@Override\n public void memoria() {\n \n }", "public void mo6081a() {\n }", "public void mo21877s() {\n }", "private void init() {\n\n\n\n }", "@Override\n\t\t\tpublic void ic() {\n\t\t\t\t\n\t\t\t}", "@Override\n\tpublic void emprestimo() {\n\n\t}", "@Override\r\n\tprotected void doF8() {\n\t\t\r\n\t}", "public void mo12628c() {\n }", "@Override\r\n\tprotected void initialize() {\n\r\n\t}", "@Override\n public void inizializza() {\n\n super.inizializza();\n }" ]
[ "0.6003772", "0.5907084", "0.5885914", "0.5828333", "0.58109003", "0.58109003", "0.576941", "0.5764854", "0.573223", "0.5730639", "0.5723697", "0.5677595", "0.5664325", "0.56490415", "0.5648917", "0.56326264", "0.5622763", "0.56057656", "0.5604578", "0.5602415", "0.55998427", "0.55998427", "0.55998427", "0.55998427", "0.55998427", "0.55894613", "0.558711", "0.5585734", "0.5563081", "0.55579615", "0.55483055", "0.5547221", "0.5546282", "0.55435586", "0.5506625", "0.5497463", "0.5493746", "0.54859424", "0.548428", "0.5483883", "0.54796606", "0.54771805", "0.54732", "0.54688925", "0.54625696", "0.54625696", "0.54625696", "0.5458308", "0.5458303", "0.5458303", "0.54582435", "0.54582435", "0.54582435", "0.5450632", "0.5444455", "0.5444455", "0.5440491", "0.5440491", "0.5440491", "0.5439251", "0.5429286", "0.5429286", "0.54228055", "0.5409211", "0.5402149", "0.53985804", "0.539829", "0.5395046", "0.53828937", "0.53703666", "0.53692746", "0.53692746", "0.53692746", "0.53692746", "0.53692746", "0.53692746", "0.53692746", "0.5367659", "0.5367003", "0.53666013", "0.53656447", "0.5361334", "0.5355989", "0.5355989", "0.5355989", "0.5355989", "0.5355989", "0.5355989", "0.53488976", "0.5326805", "0.53214675", "0.5308056", "0.5306568", "0.5301879", "0.5293945", "0.5293553", "0.528397", "0.5280633", "0.527541", "0.5267945", "0.5266934" ]
0.0
-1
Adds a nested property for the item, e.g. "manager.address.street". If any intermediate getters return null values then the property becomes null and readonly.
public boolean addNullableNestedProperty(String propertyPath) { return addItemProperty( propertyPath, new NullableNestedProperty(getBean(), propertyPath)); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public DynamicReadOnlyProperties expand() {\r\n\t\tMap<String, String> map = this.asMap();\r\n\t\tmap = expand(map);\r\n\t\tthis.putAll(map);\r\n\t\treturn this;\r\n\t}", "private EntityHierarchyItemProperties innerProperties() {\n return this.innerProperties;\n }", "public void expandProperty( String name, boolean recursively )\n {\n expandRow( getRow( name ), recursively );\n }", "public interface NestedMetaProperty<METADATA_TYPE, PROPERTY_TYPE, NESTED_PROPERTIES> extends MetaProperty<METADATA_TYPE, PROPERTY_TYPE> {\n NESTED_PROPERTIES nested();\n}", "@CanIgnoreReturnValue\n @SuppressLint(\"MissingGetterMatchingBuilder\")\n @NonNull\n // @exportToFramework:startStrip()\n @RequiresFeature(\n enforcement = \"androidx.appsearch.app.Features#isFeatureSupported\",\n name = Features.SCHEMA_ADD_INDEXABLE_NESTED_PROPERTIES)\n // @exportToFramework:endStrip()\n public DocumentPropertyConfig.Builder addIndexableNestedPropertyPaths(\n @NonNull Collection<PropertyPath> indexableNestedPropertyPaths) {\n Preconditions.checkNotNull(indexableNestedPropertyPaths);\n List<PropertyPath> propertyPathList = new ArrayList<>(indexableNestedPropertyPaths);\n for (int i = 0; i < indexableNestedPropertyPaths.size(); i++) {\n mIndexableNestedPropertiesList.add(propertyPathList.get(i).toString());\n }\n return this;\n }", "@Override\n\tpublic void addProperty(String name) {\n\t}", "private ProductProperties innerProperties() {\n return this.innerProperties;\n }", "java.lang.String getNested();", "protected Item addExtensions(Item item) {\n // this can happen if the fields extension was used but properties were not included\n if (item.getProperties() == null) {\n return item;\n }\n\n Class propertiesClass = item.getProperties().getClass();\n if (cache.containsKey(propertiesClass)) {\n return item.stacExtensions(cache.get(propertiesClass));\n }\n\n Set<String> extensions = new HashSet<>();\n Class[] interfaces = propertiesClass.getInterfaces();\n for (Class clazz : interfaces) {\n try {\n Field prefixField = clazz.getDeclaredField(\"EXTENSION_PREFIX\");\n if (prefixField != null) {\n String prefix = (String) prefixField.get(item.getProperties());\n extensions.add(prefix);\n }\n } catch (Exception e) {\n // field doesn't exist, do nothing\n }\n }\n cache.put(propertiesClass, extensions);\n item.setStacExtensions(extensions);\n return item;\n }", "@CanIgnoreReturnValue\n @SuppressLint(\"MissingGetterMatchingBuilder\")\n @NonNull\n // @exportToFramework:startStrip()\n @RequiresFeature(\n enforcement = \"androidx.appsearch.app.Features#isFeatureSupported\",\n name = Features.SCHEMA_ADD_INDEXABLE_NESTED_PROPERTIES)\n // @exportToFramework:endStrip()\n public DocumentPropertyConfig.Builder addIndexableNestedPropertyPaths(\n @NonNull PropertyPath... indexableNestedPropertyPaths) {\n Preconditions.checkNotNull(indexableNestedPropertyPaths);\n return addIndexableNestedPropertyPaths(Arrays.asList(indexableNestedPropertyPaths));\n }", "Builder addProperty(String name, Thing.Builder builder);", "DefinedProperty relAddProperty( long relId, int propertyKey, Object value );", "private Object decorateNestedObject(Field field) {\n\t\tDefaultElementLocatorFactory newFactory = (DefaultElementLocatorFactory) this.factory;\n\t\ttry {\n\t\t\tObject obj = newFactory.initNestedPageObject(field);\t\t\t\n\t\t\treturn obj;\n\t\t} catch (InstantiationException e) {\n\t\t\te.printStackTrace();\n\t\t} catch (IllegalAccessException e) {\n\t\t\te.printStackTrace();\n\t\t} catch (ClassNotFoundException e) {\n\t\t\te.printStackTrace();\n\t\t} catch (IllegalArgumentException e) {\n\t\t\te.printStackTrace();\n\t\t} catch (InvocationTargetException e) {\n\t\t\te.printStackTrace();\n\t\t}\n\t\treturn null;\n\t}", "@CanIgnoreReturnValue\n @NonNull\n // @exportToFramework:startStrip()\n @RequiresFeature(\n enforcement = \"androidx.appsearch.app.Features#isFeatureSupported\",\n name = Features.SCHEMA_ADD_INDEXABLE_NESTED_PROPERTIES)\n // @exportToFramework:endStrip()\n public DocumentPropertyConfig.Builder addIndexableNestedProperties(\n @NonNull String... indexableNestedProperties) {\n Preconditions.checkNotNull(indexableNestedProperties);\n return addIndexableNestedProperties(Arrays.asList(indexableNestedProperties));\n }", "public void testBindToModelPojoWithNestedProperties() throws Exception {\r\n \r\n \t\tfinal ITextRidget ridget = getRidget();\r\n \t\tridget.setText(\"\");\r\n \r\n \t\tfinal TextPojoHolder modelHolder = new TextPojoHolder();\r\n \t\tfinal TextPojo model = new TextPojo();\r\n \t\tmodelHolder.setPojo(model);\r\n \t\tridget.bindToModel(modelHolder, \"pojo.text2\");\r\n \r\n \t\tassertEquals(\"\", ridget.getText());\r\n \r\n \t\tridget.updateFromModel();\r\n \r\n \t\tassertEquals(modelHolder.getPojo().getText2(), ridget.getText());\r\n \r\n \t\tfinal TextPojo model2 = new TextPojo();\r\n \t\tmodel2.setText2(\"three\");\r\n \t\tmodelHolder.setPojo(model2);\r\n \t\tridget.updateFromModel();\r\n \r\n \t\tassertEquals(modelHolder.getPojo().getText2(), ridget.getText());\r\n \r\n \t}", "private <K, E> Void setNested(Model<E> nestedModel, Model<? super K> keyModel, Function<? super K, ? extends E> nestedGetter, BiConsumer<? super K, ? super E> nestedSetter, Model<? extends T> model, Consumer<? super T> setter) {\r\n return followNestedPathOrSetValue(pathElement -> {\r\n K key = converter.convert(keyModel.accept(new TypeModelVisitor<>()), pathElement);\r\n nestedModel.accept(newVisitor(nestedGetter.apply(key), value -> nestedSetter.accept(key, value)));\r\n }, setter, model);\r\n }", "@Override\n\tpublic void addProperty(IProperty property) {\n\t\t\n\t}", "@JsonAnyGetter\n public Map<String, Object> additionalProperties() {\n return this.additionalProperties;\n }", "@JsonAnyGetter\n public Map<String, Object> additionalProperties() {\n return this.additionalProperties;\n }", "@JsonAnyGetter\n public Map<String, Object> additionalProperties() {\n return this.additionalProperties;\n }", "@JsonAnyGetter\n public Map<String, Object> additionalProperties() {\n return this.additionalProperties;\n }", "@JsonAnyGetter\n public Map<String, Object> additionalProperties() {\n return this.additionalProperties;\n }", "public Builder setNested(\n java.lang.String value) {\n if (value == null) {\n throw new NullPointerException();\n }\n bitField0_ |= 0x00000100;\n nested_ = value;\n onChanged();\n return this;\n }", "boolean hasNestedField();", "@JsonAnyGetter\n public Map<String, Object> getAdditionalProperties() {\n return this.additionalProperties;\n }", "@JsonAnyGetter\n public Map<String, Object> getAdditionalProperties() {\n return this.additionalProperties;\n }", "@JsonAnyGetter\n public Map<String, Object> getAdditionalProperties() {\n return this.additionalProperties;\n }", "@JsonAnySetter\n\tpublic void setAdditionalProperty(String name, Object value) {\n\t\tthis.additionalProperties.put(name, value);\n\t}", "public void setAdditionalPath(PdfTargetDictionary nested) {\n\t\tput(PdfName.T, nested);\n\t}", "private SqlContainerCreateUpdateProperties innerProperties() {\n return this.innerProperties;\n }", "public Property addPropertyLocal(String key, Object value) {\n checkRemoved();\n if (shouldAddProperty(key)) {\n ElementHelper.validateProperty(key, value);\n Property property = createProperty(key, value);\n properties.put(key, property);\n return property;\n }\n return null;\n }", "private DeepCreatedOriginGroupProperties innerProperties() {\n return this.innerProperties;\n }", "boolean hasNestedOuterField();", "@JsonAnyGetter\n\tpublic Map<String, Object> getAdditionalProperties() {\n\t\treturn this.additionalProperties;\n\t}", "public void addComplexProperty(final ComplexConfigDTO property) {\n \t\tcomplexProperties.put(property.getPropertyName(), property);\n \t}", "@ApiModelProperty(value = \"History items custom additional properties\")\n public Map<String, String> getAdditionalProperties() {\n return additionalProperties;\n }", "DefinedProperty nodeAddProperty( long nodeId, int propertyKey, Object value );", "@Override\n protected void initProperties() {\n super.initProperties();\n if (exists()) {\n // resource is serialized as system-view (xml)\n properties.add(new DefaultDavProperty<String>(DavPropertyName.GETCONTENTTYPE, \"text/xml\"));\n Node n = (Node)item;\n\n // add node-specific resource properties\n try {\n properties.add(new NodeTypeProperty(JCR_PRIMARYNODETYPE, n.getPrimaryNodeType(), false));\n properties.add(new NodeTypeProperty(JCR_MIXINNODETYPES, n.getMixinNodeTypes(), false));\n } catch (RepositoryException e) {\n log.error(\"Failed to retrieve node-specific property: \" + e);\n }\n }\n }", "public boolean shouldIndexNestedProperties() {\n return mBundle.getBoolean(INDEX_NESTED_PROPERTIES_FIELD);\n }", "@NonNull\n public List<String> getIndexableNestedProperties() {\n List<String> indexableNestedPropertiesList =\n mBundle.getStringArrayList(INDEXABLE_NESTED_PROPERTIES_LIST_FIELD);\n if (indexableNestedPropertiesList == null) {\n return Collections.emptyList();\n }\n return Collections.unmodifiableList(indexableNestedPropertiesList);\n }", "private void UpdateAddNestedValue(){\n notebookRef.document(\"IpWOjXtIgGJ2giKF4VTp\")\r\n// .update(KEY_Tags+\".tag1\", false);\r\n\r\n // ****** For Practice If we have nested over nested values likke:\r\n // tags-> tag1-> nested_tag-> nested_tag2 :true we write like\r\n .update(\"tags.tag1.nested_tag.nested_tag2\", true);\r\n\r\n }", "@SuppressWarnings({ \"unchecked\", \"rawtypes\" })\r\n protected Item toItem(final T entity) {\r\n BeanItem<T> beanItem = new NestedBeanItem<T>(entity);\r\n\r\n for (Object propertyId : queryDefinition.getPropertyIds()) {\r\n if (beanItem.getItemProperty(propertyId) == null) {\r\n beanItem.addItemProperty(\r\n propertyId,\r\n new ObjectProperty(queryDefinition.getPropertyDefaultValue(propertyId), \r\n queryDefinition.getPropertyType(propertyId),\r\n queryDefinition.isPropertyReadOnly(propertyId)));\r\n }\r\n }\r\n\r\n return beanItem;\r\n }", "private VirtualNetworkProperties innerProperties() {\n return this.innerProperties;\n }", "private ApiReleaseContractProperties innerProperties() {\n return this.innerProperties;\n }", "boolean hasFieldNested();", "private WorkspacePatchProperties innerProperties() {\n return this.innerProperties;\n }", "public PdfTargetDictionary(PdfTargetDictionary nested) {\n\t\tsuper();\n\t\tput(PdfName.R, PdfName.P);\n\t\tif (nested != null)\n\t\t\tsetAdditionalPath(nested);\n\t}", "public int addProperty(String name, String city, double rent,\r\n\t\t\tString owner, int x, int y, int width, int depth) {\r\n\t\tProperty p = new Property(name, city, rent, owner, x, y, width, depth);\r\n\t\r\n\t\tif(p == null) {\r\n\t\t\treturn -2;\r\n\t\t}\r\n\t\tif(!plot.encompasses(p.getPlot())){\r\n\t\t\treturn -3;\r\n\t\t}\r\n\t\tfor (int i=0;i<properties.length;i++) {\r\n\t\t\tif (properties[i]!=null && i<MAX_PROPERTY-1) {\r\n\t\t\t\tif(properties[i].getPlot().overlaps(p.getPlot())) {\r\n\t\t\t\t\treturn -4;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\telse if(properties[i]!=null && i>=MAX_PROPERTY-1) {\r\n\t\t\t\treturn -1;\r\n\t\t\t}\r\n\t\t\telse {\r\n\t\t\t\tproperties[i]=p;\r\n\t\t\t\treturn i;\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn -1;\r\n\t}", "@JsonGetter(\"product_details\")\n public ProductData getProductDetails ( ) { \n return this.productDetails;\n }", "@JsonAnyGetter\n public Map<String, Object[]> otherFields() {\n return disciplineFields;\n }", "public void addChild(PDFMetadataProperty property) {\n\t\tif(this.childs==null) {\n\t\t\t//mostly there is only one entry.\n\t\t\tthis.childs = new ArrayList<>(1);\n\t\t}\n\t\tthis.childs.add(property);\n\t}", "@JsonProperty(\"subpath\")\n public String getSubpath() {\n return subpath;\n }", "public void testBindToModelBeanWithNestedProperties() throws Exception {\r\n \r\n \t\tfinal ITextRidget ridget = getRidget();\r\n \t\tridget.setText(\"\");\r\n \r\n \t\tfinal TextBeanHolder modelHolder = new TextBeanHolder();\r\n \t\tfinal TextBean model = new TextBean();\r\n \t\tmodelHolder.setBean(model);\r\n \t\tridget.bindToModel(modelHolder, \"bean.text2\");\r\n \r\n \t\tassertEquals(\"\", ridget.getText());\r\n \r\n \t\tridget.updateFromModel();\r\n \r\n \t\tassertEquals(modelHolder.getBean().getText2(), ridget.getText());\r\n \r\n \t\tfinal TextBean model2 = new TextBean();\r\n \t\tmodel2.setText2(\"three\");\r\n \t\tmodelHolder.setBean(model2);\r\n \t\tridget.updateFromModel();\r\n \r\n \t\tassertEquals(modelHolder.getBean().getText2(), ridget.getText());\r\n \r\n \t}", "@ApiModelProperty(example = \"\\\"\\\"\", required = true, value = \"Sets additional data to be embedded in PDF Meta.\")\n @JsonProperty(JSON_PROPERTY_ADDITIONAL_DATA_FIELD)\n @JsonInclude(value = JsonInclude.Include.ALWAYS)\n\n public String getAdditionalDataField() {\n return additionalDataField;\n }", "public void increaseNestingLevel() {\n\t\tthis.nestingLevel++;\n\t\tthis.resolvableType = null;\n\t\tif (this.methodParameter != null) {\n\t\t\tthis.methodParameter = this.methodParameter.nested();\n\t\t}\n\t}", "private VirtualNetworkPeeringPropertiesFormat innerProperties() {\n return this.innerProperties;\n }", "private PipelineJobPropertiesUpdate innerProperties() {\n return this.innerProperties;\n }", "@NonNull\n\t\tBuilder addProperty(@NonNull String key, Object value);", "@JsonGetter(\"adjustment\")\r\n @JsonInclude(JsonInclude.Include.NON_NULL)\r\n public InventoryAdjustment getAdjustment() {\r\n return adjustment;\r\n }", "Builder addProperty(String name, String value);", "public DataModelDescriptorBuilder property(PropertyDescriptor descriptor) {\n this.properties.add(descriptor);\n return this;\n }", "private String AddToProperty(String property, String propertyAdd)\n {\n \tString ret = \"\";\n \tif(property == null)\n \t\tret = propertyAdd;\n \telse\n \t\tret = property + \",\" + propertyAdd;\n \treturn ret;\n }", "@JsonGetter(\"price_money\")\r\n public Money getPriceMoney() {\r\n return priceMoney;\r\n }", "public boolean hasNested() {\n return ((bitField0_ & 0x00000100) == 0x00000100);\n }", "public io.opencannabis.schema.commerce.OrderItem.Item.Builder addItemBuilder() {\n return getItemFieldBuilder().addBuilder(\n io.opencannabis.schema.commerce.OrderItem.Item.getDefaultInstance());\n }", "private void propagatePropertyUpdate(String name, String value, boolean force)\n {\n if (properties != null)\n {\n if (force || !declaredPropertyMap.containsKey(name))\n {\n if (value == null)\n {\n properties.remove(name);\n }\n else\n {\n properties.put(name, value);\n }\n\n //\n if (accessedChildren != null)\n {\n for (Iterator i = accessedChildren.iterator(); i.hasNext();)\n {\n PortalObjectImpl child = (PortalObjectImpl)i.next();\n child.propagatePropertyUpdate(name, value, false);\n }\n }\n }\n }\n }", "private NetworkDevicePatchParametersProperties innerProperties() {\n return this.innerProperties;\n }", "@Override\n public Object getProperty(final Object bean,\n final String name) throws IllegalAccessException, InvocationTargetException, NoSuchMethodException {\n\n if (!collections.isEmpty()) {\n final String key = getResolver().getProperty(name);\n Pair<String, Object> collectionInfo = collections.pop();\n if (bean instanceof Map) {\n Map map = (Map) bean;\n if (!map.containsKey(key)) {\n map.put(key, newNamedInstanceForCollection(collectionInfo.getA(), collectionInfo.getB(), key));\n }\n Object value = map.get(key);\n return trackCollectionOrMap(null, value, value);\n } else { // collection\n Object value = findByNameProperty(key, (Collection)bean);\n if (value == null) {\n // create it\n value = newNamedInstanceForCollection(collectionInfo.getA(), collectionInfo.getB(), key);\n ((Collection) bean).add(value);\n }\n return trackCollectionOrMap(null, value, value);\n }\n }\n\n Object resolved = null;\n\n try {\n resolved = getNestedProperty(bean, name);\n } catch (final NoSuchMethodException e) {\n // to avoid it being swallowed by caller wrap\n throw new InvocationTargetException(e, \"Cannot access property with key: \" + name);\n }\n\n return trackCollectionOrMap(name, resolved, bean);\n }", "@Override\n public Property getProperty() throws ItemNotFoundException,\n ValueFormatException, RepositoryException {\n return null;\n }", "public boolean hasNested() {\n return ((bitField0_ & 0x00000080) == 0x00000080);\n }", "public Property getLeafProperty() {\n Entity e = root;\n if (e == null) {\n if (parent != null) {\n e = parent.get(ContentType.EntityType, null);\n }\n }\n if (e == null) {\n return null;\n }\n if (isIndexSelector()) {\n return null;\n }\n Property prop = property;\n if (prop == null) {\n prop = e.getEntity().getEntityType().findProperty(tags);\n }\n return prop;\n }", "@Override\n public void copyProperty(Object dest, String name, Object value)\n throws IllegalAccessException, InvocationTargetException {\n if (value != null) {\n // attempt to check if the value is a pojo we can clone using nested calls\n if (!value.getClass().isPrimitive()\n && !value.getClass().isSynthetic()\n && !isInternal(value.getClass().getName())) {\n try {\n Object prop = super.getPropertyUtils().getProperty(dest, name);\n // get current value, if its null then clone the value and set that to the value\n if (prop == null) {\n super.setProperty(dest, name, super.cloneBean(value));\n } else {\n // get the destination value and then recursively call\n copyProperties(prop, value);\n }\n } catch (NoSuchMethodException e) {\n return;\n } catch (InstantiationException e) {\n throw new RuntimeException(\"Nested property could not be cloned.\", e);\n }\n } else {\n super.copyProperty(dest, name, value);\n }\n }\n }", "public final ReadOnlyDoubleProperty totalProperty() {\n return total.getReadOnlyProperty();\n }", "@Override\n public void depositSchemaProperty(JsonObjectFormatVisitor jsonObjectFormatVisitor) throws JsonMappingException {\n if (jsonObjectFormatVisitor == null) return;\n if (this.isRequired()) {\n jsonObjectFormatVisitor.property(this);\n return;\n }\n jsonObjectFormatVisitor.optionalProperty(this);\n }", "@Override\n\tpublic String toString() {\n\t\tString strg= \"Property Name: \"+propertyName\n\t +\"\\nLocated in \"+city\n\t +\"\\nBelonging to: \"+ owner\n\t +\"\\nRent Amount: \"+rentAmount+\"\\n\";\n\t\treturn strg;\n\t}", "public FSItemProperties getItemProperties() {\n return itemProperties;\n }", "public static MemberExpression propertyOrField(Expression expression, String propertyOfFieldName) { throw Extensions.todo(); }", "@Test\n\tpublic void addProperty() {\n\t\tXMLTagParser.addNewElement(\"Person\");\n\t\tXMLTagParser.editElement(\"Person\", \"residence\", \"milan\");\n\n\t\tXMLTagParser.editProperty(\"Person\", \"residence\", \"isRenting\", \"false\");\n\t\tassertEquals(XMLTagParser.getPropertyValueFromTag(\"Person\", \"residence\", \"isRenting\"), \"false\");\n\t\tXMLTagParser.editProperty(\"Person\", \"residence\", \"hasGarage\", \"true\");\n\t\tassertEquals(XMLTagParser.getPropertyValueFromTag(\"Person\", \"residence\", \"hasGarage\"), \"true\");\n\t}", "public com.rpg.framework.database.Protocol.Item.Builder addItemsBuilder() {\n return getItemsFieldBuilder().addBuilder(\n com.rpg.framework.database.Protocol.Item.getDefaultInstance());\n }", "public org.apache.calcite.avatica.proto.Responses.DatabasePropertyElement.Builder addPropsBuilder() {\n return getPropsFieldBuilder().addBuilder(\n org.apache.calcite.avatica.proto.Responses.DatabasePropertyElement.getDefaultInstance());\n }", "@Override\n boolean areNestedRefsProhibited() {\n return true;\n }", "public SchemaOrBoolean getAdditionalProperties() {\n\t\treturn additionalProperties;\n\t}", "private void internalSetProperty(DavProperty<?> property) throws DavException {\n if (!exists()) {\n throw new DavException(DavServletResponse.SC_NOT_FOUND);\n }\n DavPropertyName propName = property.getName();\n if (JCR_MIXINNODETYPES.equals(propName)) {\n Node n = (Node) item;\n try {\n NodeTypeProperty mix = new NodeTypeProperty(property);\n Set<String> mixins = mix.getNodeTypeNames();\n\n for (NodeType existingMixin : n.getMixinNodeTypes()) {\n String name = existingMixin.getName();\n if (mixins.contains(name)){\n // do not add existing mixins\n mixins.remove(name);\n } else {\n // remove mixin that are not contained in the new list\n n.removeMixin(name);\n }\n }\n\n // add the remaining mixing types that are not yet set\n for (String mixin : mixins) {\n n.addMixin(mixin);\n }\n } catch (RepositoryException e) {\n throw new JcrDavException(e);\n }\n } else if (JCR_PRIMARYNODETYPE.equals(propName)) {\n Node n = (Node) item;\n try {\n NodeTypeProperty ntProp = new NodeTypeProperty(property);\n Set<String> names = ntProp.getNodeTypeNames();\n if (names.size() == 1) {\n String ntName = names.iterator().next();\n n.setPrimaryType(ntName);\n } else {\n // only a single node type can be primary node type.\n throw new DavException(DavServletResponse.SC_BAD_REQUEST);\n }\n } catch (RepositoryException e) {\n throw new JcrDavException(e);\n }\n } else {\n // all props except for mixin node types and primaryType are read-only\n throw new DavException(DavServletResponse.SC_CONFLICT);\n }\n }", "@Test\n\tpublic void serializePrivateFieldsWithoutAnyGetterSetter() throws JsonProcessingException\n\t{\n\t\t// We do not have setter method in POJO class so can not set any value.\n\t\tEmployee_PrivateFieldsWithoutAnyGetterSetterMethods employee_PrivateFieldsWithoutAnyGetterSetterMethods = \n\t\t\t\tnew Employee_PrivateFieldsWithoutAnyGetterSetterMethods();\n\t\tObjectMapper objectMapper = new ObjectMapper();\n\t\tString serializedJson = objectMapper.writerWithDefaultPrettyPrinter().writeValueAsString(employee_PrivateFieldsWithoutAnyGetterSetterMethods);\n\t\tSystem.out.println(serializedJson);\t\t\n\t}", "public ObjectProp getRelationship() {\n return relationship;\n }", "public static MemberExpression property(Expression expression, PropertyInfo property) { throw Extensions.todo(); }", "public static MemberExpression property(Expression expression, String name) { throw Extensions.todo(); }", "private String saveNestedSchemaAttribute(String userId,\n String parentSchemaAttributeGUID,\n SchemaAttribute nestedSchemaAttribute,\n String methodName) throws InvalidParameterException,\n PropertyServerException,\n UserNotAuthorizedException\n {\n String schemaAttributeGUID = this.findSchemaAttribute(userId, nestedSchemaAttribute, methodName);\n\n if (schemaAttributeGUID == null)\n {\n schemaAttributeGUID = addSchemaAttribute(userId, nestedSchemaAttribute);\n\n repositoryHandler.createRelationship(userId,\n SchemaElementMapper.NESTED_ATTRIBUTE_RELATIONSHIP_TYPE_GUID,\n parentSchemaAttributeGUID,\n schemaAttributeGUID,\n null,\n methodName);\n }\n else\n {\n updateSchemaAttribute(userId, schemaAttributeGUID, nestedSchemaAttribute);\n }\n\n return schemaAttributeGUID;\n }", "interface PropItem {\n\t\t/**\n\t\t * The displayed text, including the current value\n\t\t * @return \n\t\t */\n\t\tString getText();\n\t\t/**\n\t\t * Changes the property.\n\t\t * @param up {@code true} increase value, {@code false} decrease it\n\t\t * @return {@code true} if the property has changed and the terrain should be regenerated\n\t\t */\n\t\tboolean change(boolean up);\n\t}", "DefinedProperty graphAddProperty( int propertyKey, Object value );", "private GetProperty(Builder builder) {\n super(builder);\n }", "DefinedProperty relChangeProperty( long relId, int propertyKey, Object value );", "public ReadOnlyProperty<BusinessObject> ownerProperty() {\n\t\treturn _ownerProperty();\n\t}", "public void setRootItem(Object newItem);", "private String getPropertyValue() {\n return EmfPropertyHelper.getValue(itemPropertyDescriptor, eObject);\n }", "public void addProperty(String s, Object o) {\n }", "public void addProperty(String s, Object o) {\n }", "public Object getReadOnlyObjectProperty() {\r\n return readOnlyObjectProperty;\r\n }", "private RulesEngineProperties innerProperties() {\n return this.innerProperties;\n }", "protected Map<String, Object> getAdditionalProperties()\n {\n return additionalProperties;\n }" ]
[ "0.54006714", "0.5382261", "0.48967233", "0.4892528", "0.47555712", "0.47453463", "0.47243354", "0.4674598", "0.46709713", "0.46641845", "0.4640778", "0.4625441", "0.46181065", "0.46087474", "0.46033344", "0.45716083", "0.45138547", "0.4497503", "0.4497503", "0.4497503", "0.4497503", "0.4497503", "0.44921076", "0.44837713", "0.4477097", "0.4477097", "0.4477097", "0.44741413", "0.44430137", "0.44370413", "0.4435034", "0.44333914", "0.44233683", "0.44209915", "0.43858117", "0.43829942", "0.43705204", "0.43658146", "0.43608728", "0.4359696", "0.4354026", "0.43528828", "0.43335566", "0.43190214", "0.43178657", "0.43111238", "0.42797467", "0.42705408", "0.42671785", "0.4262457", "0.42284855", "0.42153394", "0.42071697", "0.42030528", "0.42016906", "0.4200798", "0.41951433", "0.41889668", "0.41715112", "0.41543558", "0.41509324", "0.41460618", "0.41408172", "0.4135219", "0.41341147", "0.4104573", "0.40902516", "0.408538", "0.4069996", "0.40695158", "0.40481785", "0.4043351", "0.40420768", "0.40410218", "0.40384802", "0.4037605", "0.40333316", "0.40325683", "0.4030986", "0.40251362", "0.40208647", "0.40206936", "0.40156117", "0.40044716", "0.39935645", "0.39929816", "0.3985401", "0.39844662", "0.39818126", "0.39731234", "0.3968584", "0.39683163", "0.39671028", "0.39669874", "0.39629933", "0.3949834", "0.3949834", "0.39488354", "0.39470476", "0.39445633" ]
0.5462049
0
Prints tokens from a Pika file.
public static void main(String[] args) throws FileNotFoundException { checkArguments(args, className()); Tokens.setPrintLevel(Tokens.Level.TYPE_AND_VALUE); scanFile(args[0], System.out); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public static void print(String filename) {\n // create a file writer\n UTF8FileUtility.createWriter(filename);\n // create a string buffer for storing the text\n StringBuilder sBuffer = new StringBuilder();\n int numTokens = 0;\n int freq = 0;\n for (String token : UNIGRAM.keySet()) {\n freq = UNIGRAM.get(token);\n numTokens += freq;\n sBuffer.append(token).append('\\t').append(freq).append(\"\\n\");\n }\n // write the string buffer to the file\n UTF8FileUtility.write(sBuffer.toString());\n // close the writer\n UTF8FileUtility.closeWriter();\n System.err.println(\"# of tokens = \" + numTokens);\n System.err.println(\"# of unigrams = \" + UNIGRAM.size());\n }", "void print() {\r\n\t\tOperations.print(lexemes, tokens);\r\n\t}", "public static void main(String[] args) {\n BufferedReader bf = null;\r\n System.out.println(\" ********************Token***************\");\r\n try {\r\n bf = new BufferedReader(new FileReader(\"src/convertidor/Entrada.txt\"));\r\n Analizador a = new Analizador(bf);\r\n Symbol token = null;\r\n do {\r\n token = a.next_token();\r\n token.value.toString();\r\n System.out.println(token.value.toString());\r\n\r\n } while (token != null);\r\n\r\n bf.close();\r\n } catch (Exception e) {\r\n System.out.println(\"Error en \" + e.getMessage());\r\n }\r\n\r\n }", "public void readAndPrint(String fileName)\n\t{\n\t\tString[] names = null;\n\t\tFile file = new File(fileName);\n\t\tScanner sc;\n\t\ttry {\n\t\t\tsc = new Scanner(file);\n\t\t\twhile (sc.hasNextLine()) {\n\t\t\t\tString line = sc.nextLine();\n\t\t\t\tString[] tokens = line.split(\" \");\n\t\t\t\tSystem.out.println(\"Person: \" + tokens[0] + \", \" + \n\t\t\t\t\"Age: \" + tokens[1] + \" \");\n\t\t\t\tSystem.out.print(tokens[0] + \",\");\n\t\t\t}\n\t\t} \n\t\tcatch (FileNotFoundException e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\n\t\t\t//process the information\n\t\t}\n\n\t\t//System.out.println(\"readAndPrint NOT IMPLEMENTED\");\n\t}", "void printFile(String path) {\n try {\n String[] readFileOutPut = readFile(path);\n for (int i = 0; i < readFileOutPut.length;i++) System.out.println(readFileOutPut[i]);\n } catch (Exception e) {\n e.printStackTrace();\n }\n }", "public void printTokens() {\n for (int i = 0; i < tokens.size(); i++) {\n System.out.print(tokens.get(i).getValue());\n if (i + 1 < tokens.size()) {\n System.out.print(\", \");\n }\n }\n System.out.println();\n }", "public void printFile() {\n\t\t\n\t\tfor(String[] line_i: linesArray) {\n\t\t\tSystem.out.println( Arrays.toString(line_i) );\n\t\t}\n\t}", "public static void scanFile(String filename, PrintStream out) throws FileNotFoundException {\n Scanner scanner = LexicalAnalyzer.make(filename);\n\n while (scanner.hasNext()) {\n printNextToken(out, scanner);\n }\n printNextToken(out, scanner); // prints NullToken\n }", "public static void Print(String fileName)\r\n {\n File file = new File(System.getProperty(\"user.dir\")+\"\\\\\"+fileName+\".txt\"); \r\n \r\n try \r\n {\r\n Scanner sc = new Scanner(file);\r\n \r\n while (sc.hasNextLine()) \r\n {\r\n System.out.println(sc.nextLine());\r\n }\r\n }\r\n catch (FileNotFoundException ex) \r\n {\r\n Logger.getLogger(TxtReader.class.getName()).log(Level.SEVERE, null, ex);\r\n }\r\n \r\n \r\n }", "public void printToken(){\r\n System.out.println(\"Kind: \" + kind + \" , Lexeme: \" + lexeme);\r\n }", "abstract void print(String fileName);", "public static void main(String[] args) throws ParseException {\n String text;\n\n File file;\n\n /* pdfStripper = null;\n pdDoc = null;\n cosDoc = null;\n */ String parsed = parseWithTika();\n file = new File(filePath);\n try {\n /* parser = new PDFParser(new FileInputStream(file)); // update for PDFBox V 2.0\n parser.parse();\n cosDoc = parser.getDocument();\n pdfStripper = new PDFTextStripper();\n pdDoc = new PDDocument(cosDoc);\n pdDoc.getNumberOfPages();\n */ //pdfStripper.setStartPage(1);\n //pdfStripper.setEndPage(10);\n /* text = pdfStripper.getText(pdDoc);\n String resultString = text.replaceAll(\"\\\\p{C}|\\\\p{Sm}|\\\\p{Sk}|\\\\p{So}\", \" \");\n */\n\n //testDictionary();\n testOpenNlp(parsed);\n testOpenNlp(\"anas al bassit\");\n testOpenNlp(\"Anas Al Bassit\");\n testOpenNlp(\"barack obama\");\n testOpenNlp(\"Barack Obama\");\n\n\n System.out.println();\n } catch (IOException e) {\n e.printStackTrace();\n }\n// catch (ParseException e) {\n// e.printStackTrace();\n// }\n }", "private void printToken() {\n tabPrinter();\n\n if (jackTokenizer.tokenType().equals(JackTokenizer.SYMBOL_TOKEN_TYPE)) {\n\n tagBracketPrinter(currTokenType, FULL_TAG_BRACKET, replaceOpSymbol(currentToken.charAt(0)));\n } else if (jackTokenizer.tokenType().equals(JackTokenizer.STRING_CONST_TOKEN_TYPE)) {\n currentToken = currentToken.substring(1, currentToken.length() - 1);\n tagBracketPrinter(currTokenType, FULL_TAG_BRACKET, replaceOpSymbol(currentToken));\n } else {\n\n tagBracketPrinter(currTokenType, FULL_TAG_BRACKET, currentToken);\n }\n }", "public void writeTokens() throws IOException {\r\n FileOutputStream fOutStream = new FileOutputStream(\"output.txt\");\r\n PrintStream outFS = new PrintStream(fOutStream);\r\n\r\n for (int i = 0; i < tokenList.size(); i++) {\r\n outFS.println(tokenList.get(i).evaluate());\r\n }\r\n fOutStream.close();\r\n outFS.close();\r\n }", "public void fileRead() {\n\t\tString a, b;\n\t\t\n\t\twhile (input.hasNext()) {\n\t\t\ta = input.next();\n\t\t\tb = input.next();\n\t\t\tSystem.out.printf(\"%s %s\\n\", a, b);\n\t\t}\n\t}", "public static void main(String[] args) {\n Path file = Paths.get (\"courses.txt\");\n// line n1\n /* Assume the courses.txt is accessible.\n Which code fragment can be inserted at line n1 to enable the code to print the content of the*/\n //courses.txt file?\n /* A. List<String> fc = Files.list(file);\n fc.stream().forEach (s - > System.out.println(s));\n B. Stream<String> fc = Files.readAllLines (file);\n fc.forEach (s - > System.out.println(s));\n // C. List<String> fc = readAllLines(file);\n //fc.stream().forEach (s - > System.out.println(s));\n D. Stream<String> fc = Files.lines (file);///answer\n fc.forEach (s - > System.out.println(s));*/\n }", "private void posRead() throws IOException {\n\t\tFile file = new File(fullFileName());\n\t\tString line;\n\t\tBufferedReader reader = new BufferedReader(new FileReader(file));\n\t\tStringBuffer fileText = new StringBuffer();\n\t\twhile((line = reader.readLine()) != null) {\n\t\t\tStringTokenizer st = new StringTokenizer(line);\n\t\t\twhile (st.hasMoreTokens()) {\n \t\tString tokenAndPos = st.nextToken();\n \t\tint slashIndex = tokenAndPos.lastIndexOf('/');\n \t\tif (slashIndex <= 0) throw new IOException(\"invalid data\");\n \t\tString token = tokenAndPos.substring(0,slashIndex);\n \t\tString pos = tokenAndPos.substring(1+slashIndex).intern();\n \t\tint start = this.length();\n \t\tthis.append(token);\n \t\tif (st.hasMoreTokens())\n \t\t\tthis.append(\" \");\n \t\telse\n \t\t\tthis.append(\" \\n\");\n \t\tint end = this.length();\n \t\tSpan span = new Span(start,end);\n \t\tthis.annotate(\"token\", span, new FeatureSet());\n \t\tthis.annotate(\"constit\", span, new FeatureSet(\"cat\", pos));\n \t}\n\t\t}\n\t}", "public void printAll(String file) throws FileNotFoundException, IOException, ParseException {\n\t\tarrayList = pareseFile(file);\n\t\tSystem.out.println(file + \" Adress book\");\n\t\tSystem.out.println(arrayList.toString());\n\n\t}", "public String parse(File file);", "public static void main(String[] args) throws Exception {\n FileReader fr = new FileReader(\"data/text.txt\");\n\n int i;\n while ((i=fr.read()) != -1)\n System.out.print((char)i);\n\n }", "public static void main(String[] args) throws Exception {\n CharStream input = CharStreams.fromFileName(\"T2-Ejercicios/T2-Ej2/Multiplo.txt\");\n FileOutputStream f = new FileOutputStream(\"T2-Ejercicios/T2-Ej2/MultiploOut.txt\");\n System.setOut(new PrintStream(f));\n // create a lexer that feeds off of input CharStream\n MultiploLexer lexer = new MultiploLexer(input);\n // create a buffer of tokens pulled from the lexer\n CommonTokenStream tokens = new CommonTokenStream(lexer);\n // create a parser that feeds off the tokens buffer\n MultiploParser parser = new MultiploParser(tokens);\n parser.r();\n System.out.println(); // print a \\n after translation\n }", "@Override\n\tpublic void printToFile() {\n\t\t\n\t}", "public static void main(String[] args) throws IOException, ScannerException{\n Scanner scan = new Scanner(\"test_input/ex1.tiger\");\n List<Token> tokens = scan.getTokens();\n for (Token tok : tokens) {\n System.out.println(tok.allDetails());\n }\n }", "public void printData() {\n\t\ttry {\n\t\t\tFiles.lines(new File(PAYROLL_FILE_NAME).toPath())\n\t\t\t.forEach(System.out::println); \n\t\t}catch(IOException e)\n\t\t{\n\t\t\te.printStackTrace();\n\t\t}\n\t}", "public void print ()\n\t{\n\t\tSystem.out.println(\"Polyhedron File Name: \" + FileName);\n\t\tSystem.out.println(\"Object active: \" + Boolean.toString(isActive()));\n\t\tprintCoordinates();\n\t}", "public TextFilePrinter getPrinter();", "public void print() {\n for (int i=0; i<lines.size(); i++)\n {\n System.out.println(lines.get(i));\n }\n }", "public static void main(String[] args) throws IOException {\r\n BufferedReader input = new BufferedReader(new InputStreamReader(System.in,\"UTF-8\"));\r\n PrintStream output = new PrintStream(System.out, true, \"UTF-8\");\r\n \tString line;\r\n \twhile ( (line = input.readLine()) != null) {\r\n \t\tList<String> toks = tokenizeRawTweetText(line);\r\n \t\tfor (int i=0; i<toks.size(); i++) {\r\n \t\t\toutput.print(toks.get(i));\r\n \t\t\tif (i < toks.size()-1) {\r\n \t\t\t\toutput.print(\" \");\r\n \t\t\t}\r\n \t\t}\r\n \t\toutput.print(\"\\n\");\r\n \t}\r\n }", "public void readFile()\r\n\t{\r\n\t\t\r\n\t\ttry\r\n\t\t{\r\n\t\t\tx = new Scanner(new File(\"clean vipr measles results.txt\"));\r\n\t\t\t\r\n\t\t\twhile (x.hasNext())\r\n\t\t\t{\r\n\t\t\t\tString a = x.next();\r\n\t\t\t\tString b = x.next();\r\n\t\t\t\tString c = x.next();\r\n\t\t\t\t\r\n\t\t\t\tSystem.out.printf(\"%s %s %s \\n\\n\", a,b,c);\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\tx.close();\r\n\t\t}\r\n\t\tcatch (Exception e)\r\n\t\t{\r\n\t\t\tSystem.out.println(\"file not found\");\r\n\t\t}\r\n\t\r\n\t}", "void print(String fileName)\n\t{\n\t\t//Get the reference of the head of the Linked list\n\t\tNode ref = head;\n\t\t\n\t\t//Print the elements and also write them into a file if the head is initialized\n\t\tif(ref != null)\n\t\t{\n\t\t\ttry \n\t\t\t{\n\t\t\t\t//Create a file output.txt\n\t\t\t\tPrintWriter writer = new PrintWriter(fileName);\n\t\t\t\t\n\t\t\t\t//Traverse till the end of the Linked List \n\t\t\t\twhile(ref != null)\n\t\t\t\t{\n\t\t\t\t\tref = ref.next;\n\t\t\t\t\tif(ref != null)\n\t\t\t\t\t{\n\t\t\t\t\t\t//Print the elements and also write them into a file\n\t\t\t\t\t\tSystem.out.print(ref.value + \" \");\n\t\t\t\t\t\twriter.print(ref.value + \" \");\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t//Close the file\n\t\t\t\twriter.close();\n\t\t\t} \n\t\t\tcatch (FileNotFoundException e) \n\t\t\t{\n\t\t\t\t//Printing the Stack Trace if an exception has occurred\n\t\t\t\te.printStackTrace();\n\t\t\t}\n\t\t}\n\t\tSystem.out.println();\n\t}", "private void printToken(String tokenType, String token) {\n tabPrinter();\n if (tokenType.equals(JackTokenizer.SYMBOL_TOKEN_TYPE)) {\n tagBracketPrinter(tokenType, FULL_TAG_BRACKET, replaceOpSymbol(token.charAt(0)));\n } else if (tokenType.equals(JackTokenizer.STRING_CONST_TOKEN_TYPE)) {\n tagBracketPrinter(tokenType, FULL_TAG_BRACKET, replaceOpSymbol(token));\n } else {\n tagBracketPrinter(tokenType, FULL_TAG_BRACKET, token);\n }\n }", "static void echoFile() {\n BufferedReader echo = new BufferedReader(fileIn);\n String curr_char = \"\";\n try {\n while((curr_char = echo.readLine()) != null) {\n System.out.println(curr_char);\n }\n cout.println();\n }\n catch(IOException e) {\n System.out.println(\"echofile error\");\n }\n }", "static private void printSentenceTokens( final String documentId, final Iterable<String> tokenizedSentences ) {\n System.out.println( \"=========================== \" + documentId + \" ===========================\" );\n for ( String tokenizedSentence : tokenizedSentences ) {\n System.out.println( tokenizedSentence );\n }\n }", "public void tree()\n\t{\n\t\tIterable<Position<FileElement>> toPrint = fileSystem.PreOrder();\n\t\tfor (Position<FileElement> p : toPrint)\n\t\t{\n\t\t\tint depth = fileSystem.getDepth(p);\n\t\t\tfor (int i = 0; i < depth; i++)\n\t\t\t{\n\t\t\t\tSystem.out.print(\" \");\n\t\t\t}\n\t\t\tSystem.out.println(p.getValue());\n\t\t}\n\t}", "public void parseFile() {\n File file = new File(inputFile);\n try {\n Scanner scan = new Scanner(file);\n\n while (scan.hasNextLine()) {\n String line = scan.nextLine();\n line = line.replaceAll(\"\\\\s+\", \" \").trim();\n\n if (line.isEmpty()) {\n continue;\n }\n // System.out.println(line);\n String cmd = line.split(\" \")[0];\n String lineWithoutCmd = line.replaceFirst(cmd, \"\").trim();\n // System.out.println(lineWithoutCmd);\n\n // The fields following each command\n String[] fields;\n\n switch (cmd) {\n case (\"add\"):\n fields = lineWithoutCmd.split(\"<SEP>\");\n fields[0] = fields[0].trim();\n fields[1] = fields[1].trim();\n fields[2] = fields[2].trim();\n add(fields);\n break;\n case (\"delete\"):\n\n fields = split(lineWithoutCmd);\n delete(fields[0], fields[1]);\n break;\n case (\"print\"):\n if (lineWithoutCmd.equals(\"ratings\")) {\n printRatings();\n break;\n }\n fields = split(lineWithoutCmd);\n\n print(fields[0], fields[1]);\n\n break;\n case (\"list\"):\n // need to check if it is the movie or reviewer\n fields = split(lineWithoutCmd);\n list(fields[0], fields[1]);\n break;\n case (\"similar\"):\n // need to check if it is the movie or reviewer\n fields = split(lineWithoutCmd);\n similar(fields[0], fields[1]);\n break;\n default:\n break;\n }\n\n }\n\n }\n catch (FileNotFoundException e) {\n e.printStackTrace();\n }\n }", "public void print() {\r\n\t\tSystem.out.print(getUID());\r\n\t\tSystem.out.print(getTITLE());\r\n\t\tSystem.out.print(getNOOFCOPIES());\r\n\t}", "public void handlePrintFile (File printFile) {\n // not supported\n }", "public Scanner( String filename ) throws IOException\n {\n sourceFile = new PushbackInputStream(new FileInputStream(filename));\n \n nextToken = null;\n }", "private void loopThroughTokens(PrintWriter out) {\n\n for (String element : distinctTokens){\n out.println(element);\n\n }\n }", "public void showFile() throws FileNotFoundException, IOException{\r\n ArrayList<String> arxiu = new ArrayList<>();\r\n \r\n BufferedReader br = new BufferedReader(new FileReader(fitxerUsuaris));\r\n \r\n String usuari;\r\n \r\n while((usuari = br.readLine()) != null){\r\n arxiu.add(usuari);\r\n }\r\n \r\n for (int i = 0; i < arxiu.size(); i++) {\r\n System.out.println(arxiu.get(i));\r\n }\r\n }", "public static void main(String argv[]) {\n if (argv.length == 0) {\n System.out.println(\"Usage : java PasitoScanner <inputfile>\");\n }\n else {\n for (int i = 0; i < argv.length; i++) {\n PasitoScanner scanner = null;\n try {\n scanner = new PasitoScanner( new java.io.FileReader(argv[i]) );\n do {\n System.out.println(scanner.next_token());\n } while (!scanner.yy_atEOF);\n\n }\n catch (java.io.FileNotFoundException e) {\n System.out.println(\"File not found : \\\"\"+argv[i]+\"\\\"\");\n }\n catch (java.io.IOException e) {\n System.out.println(\"IO error scanning file \\\"\"+argv[i]+\"\\\"\");\n System.out.println(e);\n }\n catch (Exception e) {\n System.out.println(\"Unexpected exception:\");\n e.printStackTrace();\n }\n }\n }\n }", "private void printTree(Tree parse) {\n \t\tparse.pennPrint();\n \t}", "public void testContentsFormatting() throws Throwable{\n long start = System.currentTimeMillis();\n PluginTokenizer tokenizer = new PluginTokenizer();\n Token token;\n int len;\n int inPRE = 0;\n\n System.out.println(\"\\nStart formatting contents in \\\"\" + _path + \"\\\"\");\n \n tokenizer.setSource(new InputStreamSource(_reader));\n tokenizer.setParseFlags( Tokenizer.F_NO_CASE \n | Tokenizer.F_TOKEN_POS_ONLY \n | Tokenizer.F_RETURN_WHITESPACES);\n tokenizer.setSeparators(null);\n tokenizer.setWhitespaceHandler(this);\n tokenizer.setSequenceHandler(this);\n\n len = 0;\n while (tokenizer.hasMoreToken()) {\n token = tokenizer.nextToken();\n switch (token.getType()) {\n case Token.NORMAL:\n System.out.print(tokenizer.current());\n if (inPRE <= 0) {\n len += token.getLength();\n }\n break;\n \n case Token.SPECIAL_SEQUENCE:\n if (token.getCompanion() == PRE_START_COMPANION) {\n System.out.println();\n len = 0;\n inPRE++;\n } else if (token.getCompanion() == PRE_END_COMPANION) {\n System.out.println();\n len = 0;\n inPRE--;\n } else {\n System.out.print((String)token.getCompanion());\n }\n break;\n \n case Token.BLOCK_COMMENT:\n if (len > 0) {\n System.out.println();\n len = 0;\n }\n break;\n \n case Token.WHITESPACE:\n if (inPRE > 0) {\n System.out.print(tokenizer.current());\n } else if (len > 75) {\n System.out.println();\n len = 0;\n } else if (len > 0) {\n System.out.print(' ');\n len++;\n }\n break;\n }\n }\n\n long diff = System.currentTimeMillis() - start;\n System.out.println(\"Finished after \" + diff + \" milliseconds\");\n }", "public static void main(String[] args) throws FileNotFoundException,IOException {\n\t\tFileReader fr=new FileReader(\"E:\\\\iostreams\\\\question.txt\");\n\n\t\tBufferedReader br=new BufferedReader(fr);\n\n\t\tStreamTokenizer st=new StreamTokenizer(br);\n\n\t\tint token=0;\n\t\tdouble sum=0;\n\t\twhile((token=st.nextToken())!=StreamTokenizer.TT_EOF) {\n\n\t\t\tswitch(token) {\n\t\t\t\tcase StreamTokenizer. TT_NUMBER:\n\t\t\t\t{\n\t\t\t\t\t//System.out.println(st.nval);\n\t\t\t\t\tsum+=st.nval;\n\t\t\t\t\t//System.out.println(sum);\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t\tcase StreamTokenizer. TT_WORD:\n\t\t\t\t{\n\t\t\t\t\tif(sum!=0) {\n\t\t\t\t\t\tSystem.out.println((int)sum);\n\t\t\t\t\t}\n\t\t\t\t\tSystem.out.print(st.sval+\" \");\n\t\t\t\t\tsum=0;\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tSystem.out.println((int)sum);\n\n\t}", "public AnalysePSRFile(File file) throws IOException {\n ReadFileToString str = new ReadFileToString();\n str.read(file);\n StringTokenizer tok = new StringTokenizer(str.outputString,\"\\n\");\n boolean notfound = true;\n int count = 4;\n while(notfound && tok.hasMoreTokens()) {\n String line = tok.nextToken();\n if(line.indexOf(startKeyword) >= 0) \n count--;\n if(count == 0)\n notfound = false;\n }\n if(!notfound) {\n Temperature = getTemperature(tok);\n getMoleFractionHeader(tok);\n getMoleFractions(tok);\n int n = namesV.size();\n namesS = new String[n];\n molefractionsD = new Double[n];\n for(int i=0;i<n;i++) {\n namesS[i] = (String) namesV.elementAt(i);\n molefractionsD[i] = (Double) molefractionsV.elementAt(i);\n }\n } else {\n throw new IOException(\"PSR file incomplete: Begin not found in \\n \" + file.toString() );\n }\n \n }", "private void displayFileContents(FileInputStream fis) throws Exception {\n\t\tScanner scanner = null;\n\t\ttry {\n\t\t\tscanner = new Scanner(fis);\n\t\t\twhile (scanner.hasNextLine()) {\n\t\t\t\tSystem.out.println(scanner.nextLine());\n\t\t\t}\n\t\t} catch (Exception e) {\n\t\t\tthrow new Exception(e.getMessage());\n\t\t} finally {\n\t\t\tif (scanner != null) {\n\t\t\t\tscanner.close();\n\t\t\t}\n\t\t}\n\t}", "public static void main(String[] args)throws IOException {\n\t\tFileReader file = new FileReader(\"D:\\\\stream\\\\hello.txt\");\n\t\tBufferedReader buffer = new BufferedReader(file);\n\t//\tint k =buffer.read();\n\t//\tSystem.out.println(k);\n\t//\tString s = buffer.readLine();\n\t//\tSystem.out.println(s);\n\t\tint k;\n\t\twhile((k=buffer.read())!=-1) {\n\t\t\t\n\t\t\tSystem.out.print((char)k);\n\t\t}\n\t\tbuffer.close();\n\t\tfile.close();\n\t\t\n\t}", "public ArrayList<String> readTokens(String fileName) {\n Scanner sc1, sc2;\n ArrayList<String> wordList = new ArrayList<String>();\n\n try {\n sc1 = new Scanner(new File(fileName));\n\n while (sc1.hasNextLine()) {\n sc2 = new Scanner(sc1.nextLine());\n\n while (sc2.hasNext()) {\n String strWord = sc2.next().replaceAll(\"\\\\W\", \"\").toLowerCase();\n wordList.add(strWord);\n }\n\n sc2.close();\n }\n\n sc1.close();\n } catch (Exception e) {\n System.err.println(e.getMessage());\n e.printStackTrace();\n }\n\n return wordList;\n }", "private static void testAllTokens() throws IOException {\n\t// open input and output files\n\tFileReader inFile = null;\n\tPrintWriter outFile = null;\n\ttry {\n\t inFile = new FileReader(\"inTokens\");\n\t outFile = new PrintWriter(new FileWriter(\"inTokens.out\"));\n\t} catch (FileNotFoundException ex) {\n\t System.err.println(\"File inTokens not found.\");\n\t System.exit(-1);\n\t} catch (IOException ex) {\n\t System.err.println(\"inTokens.out cannot be opened.\");\n\t System.exit(-1);\n\t}\n\n\tSystem.err.println(\"TESTING ALL TOKENS: COMPARE inTokens and inTokens.out\\n\");\n\n\t// create and call the scanner\n\tYylex scanner = new Yylex(inFile);\n\tSymbol token = scanner.next_token();\n\twhile (token.sym != sym.EOF) {\n\t switch (token.sym) {\n\t case sym.INT:\n\t\toutFile.println(\"int\");\n\t\tbreak;\n\t case sym.DBL:\n\t\toutFile.println(\"double\");\n\t\tbreak;\n\t case sym.VOID:\n\t\toutFile.println(\"void\");\n\t\tbreak;\n\t case sym.IF:\n\t\toutFile.println(\"if\");\n\t\tbreak;\n\t case sym.ELSE:\n\t\toutFile.println(\"else\");\n\t\tbreak;\n\t case sym.WHILE:\n\t\toutFile.println(\"while\");\n\t\tbreak;\n\t case sym.RETURN:\n\t\toutFile.println(\"return\");\n\t\tbreak;\n\t case sym.SCANF:\n\t\toutFile.println(\"scanf\");\n\t\tbreak;\n\t case sym.PRINTF:\n\t\toutFile.println(\"printf\");\n\t\tbreak;\n\t case sym.ID:\n\t\toutFile.println(((IdTokenVal)token.value).idVal);\n\t\tbreak;\n\t case sym.INTLITERAL:\n\t\toutFile.println(((IntLitTokenVal)token.value).intVal);\n\t\tbreak;\n\t case sym.DBLLITERAL:\n\t\toutFile.println(((DblLitTokenVal)token.value).dblVal);\n\t\tbreak;\n\t case sym.STRINGLITERAL:\n\t\toutFile.println(((StrLitTokenVal)token.value).strVal);\n\t\tbreak;\n\t case sym.LCURLY:\n\t\toutFile.println(\"{\");\n\t\tbreak;\n\t case sym.RCURLY:\n\t\toutFile.println(\"}\");\n\t\tbreak;\n\t case sym.LPAREN:\n\t\toutFile.println(\"(\");\n\t\tbreak;\n\t case sym.RPAREN:\n\t\toutFile.println(\")\");\n\t\tbreak;\n\t case sym.COMMA:\n\t\toutFile.println(\",\");\n\t\tbreak;\n\t case sym.ASSIGN:\n\t\toutFile.println(\"=\");\n\t\tbreak;\n\t case sym.SEMICOLON:\n\t\toutFile.println(\";\");\n\t\tbreak;\n\t case sym.PLUS:\n\t\toutFile.println(\"+\");\n\t\tbreak;\n\t case sym.MINUS:\n\t\toutFile.println(\"-\");\n\t\tbreak;\n\t case sym.STAR:\n\t\toutFile.println(\"*\");\n\t\tbreak;\n\t case sym.DIVIDE:\n\t\toutFile.println(\"/\");\n\t\tbreak;\n\t case sym.PLUSPLUS:\n\t\toutFile.println(\"++\");\n\t\tbreak;\n\t case sym.MINUSMINUS:\n\t\toutFile.println(\"--\");\n\t\tbreak;\n\t case sym.NOT:\n\t\toutFile.println(\"!\");\n\t\tbreak;\n\t case sym.AND:\n\t\toutFile.println(\"&&\");\n\t\tbreak;\n\t case sym.OR:\n\t\toutFile.println(\"||\");\n\t\tbreak;\n\t case sym.EQUALS:\n\t\toutFile.println(\"==\");\n\t\tbreak;\n\t case sym.NOTEQUALS:\n\t\toutFile.println(\"!=\");\n\t\tbreak;\n\t case sym.LESS:\n\t\toutFile.println(\"<\");\n\t\tbreak;\n\t case sym.GREATER:\n\t\toutFile.println(\">\");\n\t\tbreak;\n\t case sym.LESSEQ:\n\t\toutFile.println(\"<=\");\n\t\tbreak;\n\t case sym.GREATEREQ:\n\t\toutFile.println(\">=\");\n\t\tbreak;\n\t case sym.AMPERSAND:\n\t\toutFile.println(\"&\");\n\t\tbreak;\n\t case sym.INT_FORMAT:\n\t\toutFile.println(\"\\\"%d\\\"\");\n\t\tbreak;\n\t case sym.DBL_FORMAT:\n\t\toutFile.println(\"\\\"%f\\\"\");\n\t\tbreak;\n\t }\n\n\t token = scanner.next_token();\n\t}\n\toutFile.close();\n }", "@SuppressWarnings(\"unchecked\")\r\n\tpublic void print() {\r\n\t\tSystem.out.println(\"** Metadata **\");\r\n\t\tfor (final Map<String, Object> m : _data) {\r\n\t\t\tSystem.out.println(\" + ALBUM\");\r\n\t\t\tfor (final String key : m.keySet()) {\r\n\t\t\t\tfinal Object o = m.get(key);\r\n\r\n\t\t\t\t// Most stuff is string, we can just dump that out.\r\n\t\t\t\tif (o instanceof String) {\r\n\t\t\t\t\tSystem.out.println(\" + \" + key + \": \" + (String) o);\r\n\t\t\t\t}\r\n\r\n\t\t\t\tif (o instanceof ArrayList) {\r\n\t\t\t\t\tSystem.out.println(\" + \" + key + \":\");\r\n\t\t\t\t\tfor (final Object oo : (ArrayList<GracenoteMetadataOET>) o) {\r\n\t\t\t\t\t\tif (oo instanceof GracenoteMetadataOET) {\r\n\t\t\t\t\t\t\tfinal GracenoteMetadataOET oet = (GracenoteMetadataOET) oo;\r\n\t\t\t\t\t\t\toet.print();\r\n\t\t\t\t\t\t}\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}", "public static void main(String[] args) throws IOException {\n\t\t FileInputStream file=new FileInputStream(\"C:\\\\Users\\\\DELL\\\\Desktop\\\\test.txt\");\r\n Scanner scan=new Scanner(file);\r\n while(scan.hasNextLine()){\r\n \t System.out.println(scan.nextLine());\r\n }\r\n \r\n file.close();\r\n\t}", "public void scan() throws ScanErrorException\n {\n while(! eof)\n {\n Token next = nextToken();\n if (next != null)\n System.out.println(next);\n }\n\n try\n {\n in.close();\n }\n catch (IOException e)\n {\n System.err.println(\"Catastrophic File IO error.\\n\" + e);\n System.exit(1); \n //exit with nonzero exit code to indicate catastrophic error\n }\n }", "public static void main(String[] args) throws IOException {\n\t\tCharStream input = CharStreams.fromFileName(\"C:\\\\Users\\\\User\\\\eclipse-workspace\\\\Compilateur-Aisha-Liliya\\\\src\\\\test\\\\test0.txt\");\n\t\tLangageLexer lexer = new LangageLexer( input);\n\t\tLangageParser parser = new \tLangageParser(new CommonTokenStream(lexer));\n\t\tListener l =new Listener();\n\t\tparser.addParseListener(l);\n\t\t\n\t\tParseTree tree = parser.code();\n\tl.s.printTE();\n\tl.s.printTS();\n\tl.s.printQuad();\n\tl.s.printCODEOBJET();\n\t}", "public static void main(String[] args) throws Exception {\n\n CharStream input = CharStreams.fromFileName(\"source.txt\");\n GrammarLexer textLexer = new GrammarLexer(input);\n Token token;\n while ((token = textLexer.nextToken()).getType() != GrammarLexer.EOF) {\n System.out.printf(\"Line: %d, column: %d, lexeme: '%s', code: %d, token: %s.\\n\", token.getLine(),\n token.getCharPositionInLine() + 1, token.getText(), token.getType(),\n textLexer.getVocabulary().getDisplayName(token.getType()));\n }\n\n System.out.println(\"Traza lexer finalizada\");\n }", "public void printResults(String fileName) {\n\t\ttry {\n\t\t\tPrintWriter writer = new PrintWriter(fileName, \"UTF-8\");\n\t\t\tfor (int i = 0; i < results.size(); i++) {\n\t\t\t\twriter.println(results.get(i).toString());\n\t\t\t}\n\n\t\t\twriter.close();\n\t\t} catch (IOException e) {\n\t\t\te.printStackTrace();\n\t\t\tSystem.err.println(\"Error while writing to output file\");\n\t\t} finally {\n\t\t\t/*try {\n\t\t\t\twriter.close();\n\t\t\t} catch (IOException e) {\n\t\t\t\te.printStackTrace();\n\t\t\t\tSystem.err.println(\"Error while reading input file\");\n\t\t\t}*/\n\t\t}\t\t\n\t}", "public void printFileOnconsole(File file, int tabs,int lenghtOfDirectory) throws DirectoryException{\r\n\t\tSystem.out.println(\"file ->\" + file);\r\n\t\tString fileName = file.getName();\r\n\t\tString[] split = fileName.split(HelperContstants.DELIMETER);\r\n\t\tfor (int i = 0; i < tabs; i++) {\r\n\t\t\tSystem.out.print(\" \");\r\n\t\t}\r\n\t\tSystem.out.println(\"- Document: \" + file.getName() + \" - Extension: .\" + split[split.length - 1] + \" - URL: \"\r\n\t\t\t\t+ file.getAbsolutePath().substring(lenghtOfDirectory));\r\n\t}", "private static void testAllTokens(String arg) throws IOException \r\n {\r\n\t// open input file\r\n\tFileReader inFile = null;\r\n\tPrintWriter outFile = null;\r\n /**\r\n * Returns the file after testing to a .out file which contains the output else throws FileNotFoundException\r\n */\r\n\ttry {\r\n\t inFile = new FileReader(arg);\r\n\t outFile = new PrintWriter(new FileWriter(arg+\".out\"));\r\n\t } catch (FileNotFoundException ex) \r\n {\r\n\t System.err.println(\"File \" + arg + \" not found.\");\r\n\t System.exit(-1);\r\n\t } catch (IOException ex)\r\n {\r\n\t\tSystem.err.println(arg + \" cannot be opened. ------SKIPPED\");\r\n\t\treturn;\r\n }\r\n \r\n // create and call the scanner\r\n Yylex scanner = new Yylex(inFile);\r\n Symbol token = scanner.next_token();\r\n while (token.sym != sym.EOF) {\r\n switch (token.sym) {\r\n case sym.INT:\r\n outFile.println(\"Type: INT\\nLineNum: \" + ((TokenVal)token.value).linenum + \"\\nCharNum: \" + ((TokenVal)token.value).charnum + \"\\n\");\r\n break;\r\n case sym.BOOL:\r\n outFile.println(\"Type: BOOL\\nLineNum: \" + ((TokenVal)token.value).linenum + \"\\nCharNum: \" + ((TokenVal)token.value).charnum + \"\\n\"); \r\n break;\r\n case sym.VOID:\r\n outFile.println(\"Type: VOID\\nLineNum: \" + ((TokenVal)token.value).linenum + \"\\nCharNum: \" + ((TokenVal)token.value).charnum + \"\\n\");\r\n break;\r\n case sym.TRUE:\r\n outFile.println(\"Type: TRUE\\nLineNum: \" + ((TokenVal)token.value).linenum + \"\\nCharNum: \" + ((TokenVal)token.value).charnum + \"\\n\");\r\n break;\r\n case sym.FALSE:\r\n outFile.println(\"Type: FALSE\\nLineNum: \" + ((TokenVal)token.value).linenum + \"\\nCharNum: \" + ((TokenVal)token.value).charnum + \"\\n\");\r\n break;\r\n case sym.IF:\r\n outFile.println(\"Type: IF\\nLineNum: \" + ((TokenVal)token.value).linenum + \"\\nCharNum: \" + ((TokenVal)token.value).charnum + \"\\n\");\r\n break;\r\n case sym.ELSE:\r\n outFile.println(\"Type: ELSE\\nLineNum: \" + ((TokenVal)token.value).linenum + \"\\nCharNum: \" + ((TokenVal)token.value).charnum + \"\\n\");\r\n break;\r\n case sym.WHILE:\r\n outFile.println(\"Type: WHILE\\nLineNum: \" + ((TokenVal)token.value).linenum + \"\\nCharNum: \" + ((TokenVal)token.value).charnum + \"\\n\");\r\n break;\r\n case sym.RETURN:\r\n outFile.println(\"Type: RETURN\\nLineNum: \" + ((TokenVal)token.value).linenum + \"\\nCharNum: \" + ((TokenVal)token.value).charnum + \"\\n\");\r\n break;\r\n case sym.CIN:\r\n outFile.println(\"Type: CIN\\nLineNum: \" + ((TokenVal)token.value).linenum + \"\\nCharNum: \" + ((TokenVal)token.value).charnum + \"\\n\");\r\n break;\r\n case sym.COUT:\r\n outFile.println(\"Type: COUT\\nLineNum: \" + ((TokenVal)token.value).linenum + \"\\nCharNum: \" + ((TokenVal)token.value).charnum + \"\\n\");\r\n break;\r\n case sym.ID:\r\n outFile.println(\"Type: ID\\nLineNum: \" + ((IdTokenVal)token.value).linenum + \"\\nCharNum: \" + ((IdTokenVal)token.value).charnum \r\n\t\t\t\t+ \"\\nValue: \" + ((IdTokenVal)token.value).idVal + \"\\n\");\r\n break;\r\n case sym.INTLITERAL: \r\n outFile.println(\"Type: INTLITERAL\\nLineNum: \" + ((IntLitTokenVal)token.value).linenum + \"\\nCharNum: \" + ((IntLitTokenVal)token.value).charnum \r\n\t\t\t\t+ \"\\nValue: \" + ((IntLitTokenVal)token.value).intVal + \"\\n\");\r\n break;\r\n case sym.STRINGLITERAL: \r\n outFile.println(\"Type: STRINGLITERAL\\nLineNum: \" + ((StrLitTokenVal)token.value).linenum + \"\\nCharNum: \" + ((StrLitTokenVal)token.value).charnum \r\n\t\t\t\t+ \"\\nValue: \" + ((StrLitTokenVal)token.value).strVal + \"\\n\");\r\n break; \r\n case sym.LCURLY:\r\n outFile.println(\"Type: LCURLY\\nLineNum: \" + ((TokenVal)token.value).linenum + \"\\nCharNum: \" + ((TokenVal)token.value).charnum + \"\\n\");\r\n break;\r\n case sym.RCURLY:\r\n outFile.println(\"Type: RCURLY\\nLineNum: \" + ((TokenVal)token.value).linenum + \"\\nCharNum: \" + ((TokenVal)token.value).charnum + \"\\n\");\r\n break;\r\n case sym.LPAREN:\r\n outFile.println(\"Type: LPAREN\\nLineNum: \" + ((TokenVal)token.value).linenum + \"\\nCharNum: \" + ((TokenVal)token.value).charnum + \"\\n\");\r\n break;\r\n case sym.RPAREN:\r\n outFile.println(\"Type: RPAREN\\nLineNum: \" + ((TokenVal)token.value).linenum + \"\\nCharNum: \" + ((TokenVal)token.value).charnum + \"\\n\");\r\n break;\r\n case sym.LSQBRACKET:\r\n outFile.println(\"Type: LSQBRACKET\\nLineNum: \" + ((TokenVal)token.value).linenum + \"\\nCharNum: \" + ((TokenVal)token.value).charnum + \"\\n\");\r\n break;\r\n case sym.RSQBRACKET:\r\n outFile.println(\"Type: RSQBRACKET\\nLineNum: \" + ((TokenVal)token.value).linenum + \"\\nCharNum: \" + ((TokenVal)token.value).charnum + \"\\n\");\r\n break;\r\n case sym.COMMA:\r\n outFile.println(\"Type: COMMA\\nLineNum: \" + ((TokenVal)token.value).linenum + \"\\nCharNum: \" + ((TokenVal)token.value).charnum + \"\\n\");\r\n break;\r\n case sym.ASSIGN:\r\n outFile.println(\"Type: ASSIGN\\nLineNum: \" + ((TokenVal)token.value).linenum + \"\\nCharNum: \" + ((TokenVal)token.value).charnum + \"\\n\");\r\n break;\r\n case sym.SEMICOLON:\r\n outFile.println(\"Type: SEMICOLON\\nLineNum: \" + ((TokenVal)token.value).linenum + \"\\nCharNum: \" + ((TokenVal)token.value).charnum + \"\\n\");\r\n break;\r\n case sym.PLUS:\r\n outFile.println(\"Type: PLUS\\nLineNum: \" + ((TokenVal)token.value).linenum + \"\\nCharNum: \" + ((TokenVal)token.value).charnum + \"\\n\");\r\n break;\r\n case sym.MINUS:\r\n outFile.println(\"Type: MINUS\\nLineNum: \" + ((TokenVal)token.value).linenum + \"\\nCharNum: \" + ((TokenVal)token.value).charnum + \"\\n\");\r\n break;\r\n case sym.TIMES:\r\n outFile.println(\"Type: TIMES\\nLineNum: \" + ((TokenVal)token.value).linenum + \"\\nCharNum: \" + ((TokenVal)token.value).charnum + \"\\n\");\r\n break;\r\n case sym.DIVIDE:\r\n outFile.println(\"Type: DIVIDE\\nLineNum: \" + ((TokenVal)token.value).linenum + \"\\nCharNum: \" + ((TokenVal)token.value).charnum + \"\\n\");\r\n break;\r\n case sym.NOT:\r\n outFile.println(\"Type: NOT\\nLineNum: \" + ((TokenVal)token.value).linenum + \"\\nCharNum: \" + ((TokenVal)token.value).charnum + \"\\n\");\r\n break;\r\n case sym.AND:\r\n outFile.println(\"Type: AND\\nLineNum: \" + ((TokenVal)token.value).linenum + \"\\nCharNum: \" + ((TokenVal)token.value).charnum + \"\\n\");\r\n break;\r\n case sym.OR:\r\n outFile.println(\"Type: OR\\nLineNum: \" + ((TokenVal)token.value).linenum + \"\\nCharNum: \" + ((TokenVal)token.value).charnum + \"\\n\");\r\n break;\r\n case sym.EQUALS:\r\n outFile.println(\"Type: EQUALS\\nLineNum: \" + ((TokenVal)token.value).linenum + \"\\nCharNum: \" + ((TokenVal)token.value).charnum + \"\\n\");\r\n break;\r\n case sym.NOTEQUALS:\r\n outFile.println(\"Type: NOTEQUALS\\nLineNum: \" + ((TokenVal)token.value).linenum + \"\\nCharNum: \" + ((TokenVal)token.value).charnum + \"\\n\");\r\n break;\r\n case sym.LESS:\r\n outFile.println(\"Type: LESS\\nLineNum: \" + ((TokenVal)token.value).linenum + \"\\nCharNum: \" + ((TokenVal)token.value).charnum + \"\\n\");\r\n break;\r\n case sym.GREATER:\r\n outFile.println(\"Type: GREATER\\nLineNum: \" + ((TokenVal)token.value).linenum + \"\\nCharNum: \" + ((TokenVal)token.value).charnum + \"\\n\");\r\n break;\r\n case sym.LESSEQ:\r\n outFile.println(\"Type: LESSEQ\\nLineNum: \" + ((TokenVal)token.value).linenum + \"\\nCharNum: \" + ((TokenVal)token.value).charnum + \"\\n\");\r\n break;\r\n case sym.GREATEREQ:\r\n outFile.println(\"Type: GREATEREQ\\nLineNum: \" + ((TokenVal)token.value).linenum + \"\\nCharNum: \" + ((TokenVal)token.value).charnum + \"\\n\");\r\n break;\r\n case sym.WRITE:\r\n outFile.println(\"Type: WRITE\\nLineNum: \" + ((TokenVal)token.value).linenum + \"\\nCharNum: \" + ((TokenVal)token.value).charnum + \"\\n\");\r\n break;\r\n case sym.READ:\r\n outFile.println(\"Type: READ\\nLineNum: \" + ((TokenVal)token.value).linenum + \"\\nCharNum: \" + ((TokenVal)token.value).charnum + \"\\n\");\r\n break;\r\n } // end switch\r\n\r\n token = scanner.next_token();\r\n } // end while\r\n outFile.close();\r\n }", "public void printTags() {\n String results = \"First 10 tags: \";\n for(int i = 0; i < 10; i++) {\n results += \"\\n\" + tags.get(i);\n }\n tagText.setText(results);\n }", "public JackTokenizer(File inFile) {\n\n try {\n\n Scanner scanner = new Scanner(inFile);\n String preprocessed = \"\";\n String line = \"\";\n\n while(scanner.hasNext()){\n\n line = noComments(scanner.nextLine()).trim();\n\n if (line.length() > 0) {\n preprocessed += line + \"\\n\";\n }\n }\n\n preprocessed = noBlockComments(preprocessed).trim();\n\n //init all regex\n initRegs();\n\n Matcher m = tokenPatterns.matcher(preprocessed);\n tokens = new ArrayList<String>();\n pointer = 0;\n\n while (m.find()){\n\n tokens.add(m.group());\n\n }\n\n } catch (FileNotFoundException e) {\n\n e.printStackTrace();\n\n }\n\n currentToken = \"\";\n currentTokenType = TYPE.NONE;\n\n }", "public TokenScanner(final File f) throws FileNotFoundException {\n\t\tfileScanner = new Scanner(file = f);\n\t}", "private void printStatistics() throws IOException {\n\n\t\tSystem.out.println(\"*********************** \" + analyzer\n\t\t\t\t+ \" *********************************\");\n\n\t\tidxReader = DirectoryReader\n\t\t\t\t.open(FSDirectory.open(Paths.get(indexPath)));\n\n\t\tSystem.out.println(\"Total no. of document in the corpus: \"\n\t\t\t\t+ idxReader.maxDoc());\n\n\t\tTerms vocabulary = MultiFields.getTerms(idxReader, \"TEXT\");\n\n\t\tSystem.out.println(\"Number of terms in dictionary for TEXT field:\"\n\t\t\t\t+ vocabulary.size());\n\n\t\tSystem.out.println(\"Number of tokens for TEXT field:\"\n\t\t\t\t+ vocabulary.getSumTotalTermFreq());\n\n\t\tidxReader.close();\n\t}", "public void tokenizeFile (String filePath) throws IOException {\r\n tokenList.clear();\r\n\r\n FileInputStream fInStream = new FileInputStream(filePath);\r\n Scanner inFS = new Scanner(fInStream);\r\n\r\n while (inFS.hasNextLine()) {\r\n String nextStr = inFS.nextLine();\r\n\r\n if (!nextStr.isEmpty()) {\r\n tokenList.add(theBuilder.build(nextStr));\r\n }\r\n }\r\n\r\n fInStream.close();\r\n inFS.close();\r\n }", "public void print(String line);", "private static void printNumbers(String f1) throws IOException {\n DataInputStream in = readFile(f1,f1,true);\n System.out.println(\"\\nThe numbers in \" + f1 + \" are :\");\n int i=0;\n while(i<20 && in.available()>=4){ //print first 20 numbers\n int val = in.readInt();\n System.out.print(val + \" \");\n\n i++;\n\n }\n }", "public static void main(String[] args) {\n\t\tString sampleText = \"In addition, the rook was moved too far to be effective.\";\r\n\t\tScanner scanner = new Scanner(sampleText);\r\n\t\tArrayList<String> list = new ArrayList<>();\r\n\t\t\r\n\t\twhile (scanner.hasNext()) {\r\n\t\t String token = scanner.next();\r\n\t\t list.add(token);\r\n\t\t }\r\n\r\n\t\tfor (String token : list) {\r\n\t\t System.out.println(token);\r\n\t\t}\r\n\r\n\r\n\t}", "public void print() {\n\t\tSystem.out.println(\"ONOMA IDIOKTITH: \" + fname);\n\t\tSystem.out.println(\"EPWNYMO IDIOKTITH: \" + lname);\n\t\tSystem.out.println(\"DIEUTHINSH FARMAKEIOU: \" + address);\n\t\tSystem.out.println(\"THLEFWNO FARMAKEIOU: \" + telephone);\n\t\tSystem.out.println();\n\t}", "public static void main(String[] args) {\n\t\tStringTokenizer s = new StringTokenizer(\"java programming language\");\n\t\twhile (s.hasMoreTokens()) {\n\t\t\tSystem.out.println(s.nextToken());// to print all tokens\n\t\t}\n\t}", "protected void info(String token, TextToken<BasicTextTokenType> object) {\n switch (object.getType()){\n case INVENTORY:\n if (player.getInventory().isEmpty()) {\n output.println(\"You have nothing in your inventory\");\n } else {\n output.println(player.inventoryOverview());\n }\n break;\n case MONEY:\n output.println(player.getMoney());\n break;\n case HEALTH:// this is used to for displaying the entire dictionary of the game\n String out = \"Here are all words in the system's current syntax: \";\n Set<String> words = gameData.getDictionary();\n for(String s : words) {\n if(!s.equals(\"\")) {\n out = out.concat(s).concat(\", \");\n }\n }\n out = out.substring(0, out.length() - 2);\n out = out.concat(\".\");\n output.println(out);\n break;\n case MAX_HEALTH:\n output.println(player.getMaxHealth());\n break;\n default:\n output.println(\"Nothing by that name was found\");\n }\n\n }", "@Override\n public String toString() {\n return token.toString();\n }", "public void setUp() {\n getRef().println(\"'token image' [offset, length]; tokenID name; tokenID id; token category name; <list of token context names>\\n--------------------\\n\");\n }", "public void readAndPrint(String str);", "private void printTree(Tree parse) {\n\t\tparse.pennPrint();\n\t}", "public static void verTopicos() throws IOException, InterruptedException {\n\n clearScreen();\n\n System.out.println(\"Topicos: \");\n Scanner input = new Scanner(System.in);\n File file = new File(\"Topicos.txt\");\n FileWriter writer = new FileWriter(\"Topicos.txt\",true);\n BufferedReader reader = new BufferedReader(new FileReader(file));\n int contador = 0;\n\n try {\n x = new Scanner(new File(\"Topicos.txt\"));\n } \n catch(Exception e){\n System.out.println(\"Ficheiro nao encontrado\");\n }\n\n while(x.hasNext()){ // parametros dos topicos\n\n String a = x.next(); // nome do topico\n String b = x.next(); // descricao\n String c = x.next(); // numero maximo de mensagens\n\n contador++;\n System.out.println(\"> \" + contador + \": \" + a); // listagem dos topicos 1 a 1\n }\n\n System.out.println(\"Existem \" + contador + \" topicos\");\n \n }", "public static void main(String[] args){\n SentenceParser sp = new SentenceParser (\"Peas and carrots and potatoes.\");\n System.out.println(sp);\n //then print your results\n \n\n }", "public static void demoDP(LexicalizedParser lp, String filename) {\n\t\t// This option shows loading and sentence-segmenting and tokenizing\n\t\t// a file using DocumentPreprocessor.\n\t\tTreebankLanguagePack tlp = new PennTreebankLanguagePack();\n\t\tGrammaticalStructureFactory gsf = tlp.grammaticalStructureFactory();\n\t\t// You could also create a tokenizer here (as below) and pass it\n\t\t// to DocumentPreprocessor\n\t\tfor (List<HasWord> sentence : new DocumentPreprocessor(filename)) {\n\t\t\tTree parse = lp.apply(sentence);\n\t\t\tList<Tree> testTree = new ArrayList<Tree>();\n\n\t\t\t// for (Tree subtree : parse) {\n\t\t\t// if (subtree.label().value().equals(\"VP\")) {\n\t\t\t// testTree.add(subtree);\n\t\t\t// }\n\t\t\t// }\n\t\t\t//\n//\t\t\tString pattern = \"VP < ((/VB.?/ < am|is|are|was|were) $+ (RB < /n['o]t/)) [< NP | < VP]\";// \"\\\\(VP \\\\([am|is|was|were|are]\\\\) .*\\\\)\";//\n//\t\t\tString pat = \"@NP < /NN.?/\";\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t// \"\\\\(VP \\\\(.* [am|is|are|was|were]\\\\) \\\\(RB n[o’]t\\\\) \\\\(*\\\\)\\\\)\";\n//\t\t\tTregexPattern tgrepPattern = TregexPattern.compile(pattern);\n//\t\t\tTregexMatcher m = tgrepPattern.matcher(parse);\n//\t\t\twhile (m.find()) {\n//\t\t\t\tTree subtree = m.getMatch();\n//\t\t\t\ttestTree.add(subtree);\n//\t\t\t\tSystem.out.println(subtree.toString());\n//\t\t\t}\n\n\t\t\tTregexPatternCompiler tpc = new TregexPatternCompiler();\n\t\t\ttpc.addMacro(\"@VB\", \"/^VB/\");\n\t\t\ttpc.addMacro(\"@Be\", \"am|is|are|was|were\");\n\t\t\ttpc.addMacro(\"@Aux\", \"have|has|had|do|does|did\");\n\t\t\ttpc.addMacro(\"@NEGTerm\", \"(RB < /n['o]t/)\");\n\t\t\ttpc.addMacro(\"@PRN\", \"NP|ADJP|PP|ADVP|SBAR|S\");\n\t\t\ttpc.addMacro(\"@Modal\", \"can|could|may|might|will|would|must|shall|should|ought\");\n\t\t\ttpc.addMacro(\"@Be-Not\", \"(@VB < @Be $+ @NEGTerm)\");\n//\t\t\tTregexPattern test = tpc.compile(\"NP = cnp < DT !$ PP\");\n//\t\t\tTregexPattern test = tpc.compile(\"VP < ((@VB < @Be) $+ @NEGTerm) <@PRN\");\n//\t\t\tTregexPattern test = tpc.compile(\"VP < ((@VB < @Be) $+ @NEGTerm) < @PRN\");\n//\t\t\tTregexPattern test = tpc.compile(\"VP < @VB =vb < @NEGTerm < @PRN =xc \");\n//\t\t\tTregexPattern test = tpc.compile(\"VP < ((MD < @Modal) $+ @NEGTerm) < @PRN\");\n//\t\t\tTregexPattern test = tpc.compile(\"VP < (MD $+ @NEGTerm) < VP \"); //GOOD\n//\t\t\tTregexPattern test = tpc.compile(\"VP < MD=md < VP: =md $+ @NEGTerm \");\n//\t\t\tTregexPattern test = tpc.compile(\"VP < @VB=vb : =vb < @Be : =vb $+ @NEGTerm\");\n//\t\t\tTregexPattern test = tpc.compile(\"VP < @VB=vb < @PRN :(=vb < @Be $+ @NEGTerm)\");\n//\t\t\tTregexPattern test = tpc.compile(\"@VB < @Be $+ @NEGTerm\");\n\n\t\t\tTregexPattern test = tpc.compile(\"VP < ((@VB < @Aux) $+ @NEGTerm) < VP\");\n\t\t\t\n\n\t\t\tTregexMatcher mth = test.matcher(parse);\n\t\t\tif (mth.find()) {\n\t\t\t\tTree subtree = mth.getMatch();\n\t\t\t\ttestTree.add(subtree);\n\t\t\t\tSystem.out.println(\"Ter Compiler: \"+subtree.toString());\n\t\t\t}\n//\t\t\tfor (Tree subTree : testTree) {\n//\t\t\t\tString prdPattern = \"NP\";\n//\t\t\t\t TregexPattern prd = TregexPattern.compile(prdPattern);\n//\t\t\t\t TregexMatcher macher = prd.matcher(subTree);\n//\t\t\t\t if (macher.find()) {\n//\t\t\t\t Tree prdTree = m.getMatch();\n//\t\t\t\t System.out.println(\"PRD pattern: \"+prdTree.toString());\n//\t\t\t\t }\n//\t\t\t}\n\t\t\tSystem.out.println(\"--- Pattern: \" + testTree.toString());\n\t\t\t System.out.println(\"***\" + parse.toString());\n//\t\t\tparse.pennPrint();\n//\t\t\tSystem.out.println(parse.pennString());\n\t\t\tSystem.out.println();\n\n\t\t\tGrammaticalStructure gs = gsf.newGrammaticalStructure(parse);\n\t\t\t@SuppressWarnings(\"rawtypes\")\n\t\t\tCollection tdl = gs.typedDependenciesCCprocessed();\n\t\t\t System.out.println(\"td1: \"+tdl);\n\t\t\t System.out.println();\n\t\t}\n\t}", "private void viewAllInfo(){\r\n try{\r\n Scanner scanner = new Scanner(file);\r\n String info;\r\n\r\n while (scanner.hasNext()){\r\n String line = scanner.nextLine();\r\n String[] components = line.split(separator);\r\n info = \" Name: \" + components[0] + \"\\n\";\r\n info += \" Phone No.: \"+components[1]+\"\\n\";\r\n info += \" Email: \"+components[2]+\"\\n\";\r\n info += \" Address: \"+components[3]+\"\\n\";\r\n textAreaFromAllInfo.append(info+\"\\n\");\r\n }\r\n\r\n }catch (IOException e){\r\n fileError();\r\n }\r\n }", "public void print(){\n\t\tfor (int i=0; i<_size; i++){\n\t\t\tSystem.out.print(_a[i].getKey()+\"; \");\n\t\t}\n\t\tSystem.out.println();\n\t}", "public void dumpTokens(PrintWriter pw, boolean dumpAll) {\n if (!this.mTokenMap.isEmpty()) {\n pw.println(\" Display #\" + this.mDisplayId);\n for (WindowToken token : this.mTokenMap.values()) {\n pw.print(\" \");\n pw.print(token);\n if (dumpAll) {\n pw.println(':');\n token.dump(pw, \" \", dumpAll);\n } else {\n pw.println();\n }\n }\n if (!this.mOpeningApps.isEmpty() || !this.mClosingApps.isEmpty() || !this.mChangingApps.isEmpty()) {\n pw.println();\n if (this.mOpeningApps.size() > 0) {\n pw.print(\" mOpeningApps=\");\n pw.println(this.mOpeningApps);\n }\n if (this.mClosingApps.size() > 0) {\n pw.print(\" mClosingApps=\");\n pw.println(this.mClosingApps);\n }\n if (this.mChangingApps.size() > 0) {\n pw.print(\" mChangingApps=\");\n pw.println(this.mChangingApps);\n }\n }\n this.mUnknownAppVisibilityController.dump(pw, \" \");\n }\n }", "public void read() {\n\t\tSystem.out.println(\"word document\");\r\n\t}", "public static void main(String[] args) throws IOException {\n File file = new File(\"Noten.txt\");\n FileInputStream fileInputStream = new FileInputStream(file);\n\n int byteRead;\n int count = 0;\n while ((byteRead = fileInputStream.read())!= -1) {\n char[] ch = Character.toChars(byteRead);\n System.out.println(ch[0]);\n count++;\n }\n System.out.println(count);\n fileInputStream.close();\n }", "public void printString()\r\n\t\t{\r\n\t\t\tTreeNode previousTreeNode = null; //holds the previous node\r\n\t\t\tTreeNode currentTreeNode = null; //holds current node\r\n\r\n\t\t\tData currentData = head; //start at the head of our data which is a linked list\r\n\t\t\twhile (currentData != null) //while the currentData is not null\r\n\t\t\t{\r\n\t\t\t\tcurrentTreeNode = currentData.getLT(); //get the Less Than tree\r\n\t\t\t\tif (currentTreeNode != previousTreeNode)\r\n\t\t\t\t\tcurrentTreeNode.printString(); //print the Less Than tree\r\n\t\t\t\tpreviousTreeNode = currentTreeNode;\r\n\r\n\t\t\t\tcurrentData.getWord(); //get the current word\r\n\t\t\t\tSystem.out.printf(\"%-20s\", currentData.getWord()); //print the current word\r\n\t\t\t\tArrayList locations = currentData.getLocations(); //get the word's locations in the file\r\n\t\t\t\tfor (int i = 0; i < locations.size(); i++) //print all of those\r\n\t\t\t\t{\r\n\t\t\t\t\tSystem.out.printf(\" (%s,%s)\", ((Point) locations.get(i)).x, ((Point) locations.get(i)).y);\r\n\t\t\t\t\tif ((((i + 1) % 8) == 0) && ((i + 1) != locations.size())) //only print 8 items per line\r\n\t\t\t\t\t{\r\n\t\t\t\t\t\tSystem.out.printf(\"\\n%-20s\", \"\\\"\");\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t\tSystem.out.println(); //print a newline\r\n\r\n\t\t\t\tcurrentTreeNode = currentData.getGT(); //get the Greater Than tree\r\n\t\t\t\tif (currentTreeNode != previousTreeNode)\r\n\t\t\t\t\tcurrentTreeNode.printString(); //print the Greater Than tree\r\n\t\t\t\tpreviousTreeNode = currentTreeNode;\r\n\t\t\t\tcurrentData = currentData.nextData();\r\n\t\t\t}\r\n\t\t}", "public java_cup.runtime.Symbol debug_next_token() throws java.io.IOException {\n java_cup.runtime.Symbol s = next_token();\n System.out.println( \"line:\" + (yyline+1) + \" col:\" + (yycolumn+1) + \" --\"+ yytext() + \"--\" + getTokenName(s.sym) + \"--\");\n return s;\n }", "public java_cup.runtime.Symbol debug_next_token() throws java.io.IOException {\n java_cup.runtime.Symbol s = next_token();\n System.out.println( \"line:\" + (yyline+1) + \" col:\" + (yycolumn+1) + \" --\"+ yytext() + \"--\" + getTokenName(s.sym) + \"--\");\n return s;\n }", "public java_cup.runtime.Symbol debug_next_token() throws java.io.IOException {\n java_cup.runtime.Symbol s = next_token();\n System.out.println( \"line:\" + (yyline+1) + \" col:\" + (yycolumn+1) + \" --\"+ yytext() + \"--\" + getTokenName(s.sym) + \"--\");\n return s;\n }", "public static void echoFile(Scanner in) {\n }", "public static void main(String[] args) {\n\t\tIreader reader = new FileReader();\n\t\tTokens tokens = new Tokens();\n\t\tString s = \"\";\n\t\ttry {\n\t\t\ts = reader.readFile(\"Data/code.txt\");\n\t\t} catch (IOException e) {\n\t\t\te.printStackTrace();\n\t\t}\n\t\tArrayList<Token> result = new ArrayList<>(), found = new ArrayList<>();\n\t\tfor (Token token : tokens.tokens) {\n\t\t\tfound = token.validate_2(s);\n\t\t\tif (!found.isEmpty()) {\n\t\t\t\tresult.addAll(found);\n\t\t\t\t//System.out.println(found);\n\t\t\t}\n\t\t}\n\t\t//System.out.println(result);\n\t\tCollections.sort(result, Comparator.comparing(Token::getStartpos));\n\t\tfor (int i = 0; i < result.size(); i++) {\n\t\t\tfor (int j = i + 1; j < result.size(); j++) {\n\t\t\t\tif (result.get(i).getStartpos() == result.get(j).getStartpos()) {\n\t\t\t\t\tif (result.get(j).getClassName().equals(\"ID\")) {\n\t\t\t\t\t\tresult.remove(j);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tfor (int i = 0; i < result.size(); i++) {\n\t\t\tfor (int j = i + 1; j < result.size(); j++) {\n\n\t\t\t\tif (result.get(i).getStartpos() <= result.get(j).getStartpos()\n\t\t\t\t\t\t&& result.get(i).getEndpos() >= result.get(j).getEndpos()) {\n\t\t\t\t\tif(result.get(j).getClassName().equals(\"DOT\")&&\n\t\t\t\t\t result.get(j-1).getClassName().equals(\"FLOAT\")&&\n\t\t\t\t\t result.get(j+1).getClassName().equals(\"INT_LITERAL\")) {\n\t\t\t\t\t\tresult.remove(j-1);\n\t\t\t\t\t\tj--;\n\t\t\t\t\t\tcontinue;\n\n\t\t\t\t\t}\t\t\t\t\t\t\n\t\t\t\t\tresult.remove(j);\n\t\t\t\t\tj--;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t//\tSystem.out.println(result);\n\t\tErrorHandler errorhandler = new ErrorHandler(s,result);\n\t\terrorhandler.printError();\n\t\ttry {\n\t\t\tWriter.writeTokens(result, \"Data/output.txt\");\n\t\t} catch (IOException e) {\n\t\t\te.printStackTrace();\n\t\t}\n\n\t}", "public static void main(String[] args)\n/* */ throws IOException\n/* */ {\n/* 130 */ if (args.length < 1) {\n/* 131 */ System.err.println(\"usage: java edu.stanford.nlp.process.ArabicTokenizer [-cr] filename\");\n/* 132 */ return;\n/* */ }\n/* 134 */ ArabicTokenizer tokenizer = new ArabicTokenizer(new InputStreamReader(new FileInputStream(args[(args.length - 1)]), \"UTF-8\"), args[0].equals(\"-cr\"));\n/* 135 */ PrintWriter pw = new PrintWriter(new OutputStreamWriter(System.out, \"UTF-8\"), true);\n/* 136 */ while (tokenizer.hasNext()) {\n/* 137 */ Word w = (Word)tokenizer.next();\n/* 138 */ if (w == ArabicLexer.crValue) {\n/* 139 */ pw.println(\"***CR***\");\n/* */ } else {\n/* 141 */ pw.println(w);\n/* */ }\n/* */ }\n/* */ }", "private static void letturaFilePerRiga(File file) {\n\t\ttry(FileReader reader = new FileReader(file);\n\t\t\tBufferedReader buffReader = new BufferedReader(reader)) {\n\t\t\tString riga = null;\n\t\t\t\n\t\t\tdo {\n\t\t\t\triga = buffReader.readLine();\n\t\t\t\tSystem.out.println(riga);\n\n\t\t\t} while (riga != null);\n\t\t\twhile(riga != null);\n\t\t} catch (FileNotFoundException e) {\n\t\t\t// TODO: handle exception\n\t\t} catch (IOException e) {\n\t\t\t// TODO: handle exception\n\t\t}\n\t\n\n\t}", "public String toString() {\r\n\t\tStringBuffer sb = new StringBuffer();\r\n\t\tsb.append(\"Tokens:\\n\");\r\n\t\tfor (int i = 0; i < tokens.size(); i++) {\r\n\t\t\tsb.append(tokens.get(i)).append('\\n');\r\n\t\t}\r\n\t\treturn sb.toString();\r\n\t}", "private void printDetails(FileDTO file) {\n\t\tif (file == null) {\n\t\t\tsafePrintln(\"The file could not be retrieved or does not exist!\");\n\t\t} else {\n\t\t\tsafePrintln(file.getName() + \"|\" + file.getPermission() + \"|\" + file.getSize().toString() + \" - \"\n\t\t\t\t\t+ file.getOwnerName());\n\t\t}\n\t}", "public static void main(String[] args) {\n\t\tString CorpusFilePath = \"C:\\\\Users\\\\singh\\\\Desktop\\\\mallet-2.0.8\\\\palm\\\\palm.txt\";\n\t\tString CorpusDirPath = \"C:\\\\Users\\\\singh\\\\Desktop\\\\mallet-2.0.8\\\\palm\\\\output\";\n\n\t\tBufferedWriter out = null;\n\t\tBufferedReader br = null;\n\t\ttry {\n\t\t\tSystem.out.print(\"START\");\n\t\t\tFileInputStream fis = new FileInputStream(new File(CorpusFilePath));\n\t\t\tString CorpusContent = IOUtils.toString(fis);\n\t\t\tString[] tokens = CorpusContent.split(\"ravikrsingh20\");\n\t\t\tfor (int i = 0; i < tokens.length; i++) {\n\t\t\t\ttry {\n\t\t\t\t\tFile file = new File(CorpusDirPath + File.separator + i + \".txt\");\n\t\t\t\t\tfile.createNewFile();\n\t\t\t\t\tFileWriter fstream = new FileWriter(file);\n\t\t\t\t\tout = new BufferedWriter(fstream);\n\t\t\t\t\tout.write(tokens[i]);\n\t\t\t\t} catch (IOException e) {\n\t\t\t\t\te.printStackTrace();\n\t\t\t\t} finally {\n\t\t\t\t\ttry {\n\t\t\t\t\t\tout.flush();\n\t\t\t\t\t\tout.close();\n\t\t\t\t\t} catch (IOException e) {\n\t\t\t\t\t\te.printStackTrace();\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t}\n\t\t\tSystem.out.print(\"DONE\");\n\t\t} catch (IOException e) {\n\t\t\te.printStackTrace();\n\t\t}\n\n\t}", "public static void main(String[] args) throws Exception {\n Scanner scan = new Scanner(new File(\"prob01.txt\"));\n String a = scan.nextLine();\n System.out.println(\"Greetings, O Honorable \" + a + \" the Magnificent! May I kiss your signet ring?\");\n }", "public void print();", "public void print();", "public void print();", "public void print();", "public void print() {\n\t\tSystem.out.println(word0 + \" \" + word1 + \" \" + similarity);\n\t}", "public void print() {\n\t\tfor(String subj : subjects) {\n\t\t\tSystem.out.println(subj);\n\t\t}\n\t\tSystem.out.println(\"==========\");\n\t\t\n\t\tfor(StudentMarks ssm : studMarks) {\n\t\t\tSystem.out.println(ssm.student);\n\t\t\tfor(Byte m : ssm.marks) {\n\t\t\t\tSystem.out.print(m + \" \");\n\t\t\t}\n\t\t\tSystem.out.println();\n\t\t}\n\t}", "public static void readInFile(Scanner inFile) {\n\t\twhile(inFile.hasNext()) {\n\t\t\tString strIn = inFile.nextLine();\n\t\t\tSystem.out.println(strIn);\n\t\t}\n\t\tinFile.close();\n\t}", "public Printer(File file) {\n this.file = file;\n log = LogManager.getLogManager().getLogger(Printer.class.getName());\n // initialization of the template path\n base = System.getProperty(\"user.dir\") + File.separator + \"config\"\n + File.separator + \"template\" + File.separator;\n\n // </snip>\n\n // System.out.println(\"template printing\");\n\n start();\n }" ]
[ "0.6193194", "0.5898737", "0.57893825", "0.57107675", "0.5581219", "0.5558501", "0.5458648", "0.54240763", "0.54150814", "0.5281221", "0.5225078", "0.52100855", "0.51590633", "0.51584125", "0.5155994", "0.514077", "0.5131595", "0.5130483", "0.5121427", "0.5101443", "0.5085293", "0.5055221", "0.50482935", "0.5026635", "0.5006329", "0.4953713", "0.49480364", "0.48974824", "0.4890631", "0.48777613", "0.48692974", "0.4864892", "0.48305634", "0.4829502", "0.4820096", "0.48197162", "0.48176542", "0.48108712", "0.48075294", "0.4804081", "0.47902", "0.4733674", "0.4731238", "0.47310942", "0.47239316", "0.47221872", "0.46975636", "0.46919757", "0.46860227", "0.46811032", "0.46691367", "0.4664961", "0.46574545", "0.46504083", "0.46495327", "0.46472096", "0.46399748", "0.46380502", "0.4632507", "0.4625371", "0.46209264", "0.46207672", "0.4615409", "0.46057257", "0.46054482", "0.4596112", "0.45898482", "0.4581807", "0.45717064", "0.45697457", "0.4565683", "0.45628306", "0.45619076", "0.45584294", "0.45556834", "0.45537016", "0.4546806", "0.45443574", "0.45424998", "0.45408896", "0.453906", "0.45358947", "0.45358947", "0.45358947", "0.4531645", "0.4531431", "0.45271423", "0.45255315", "0.45244023", "0.45129797", "0.45126307", "0.45104417", "0.45094204", "0.45094204", "0.45094204", "0.45094204", "0.45074043", "0.44974148", "0.44962388", "0.4493241" ]
0.4807936
38
prints the Pika tokens in the file specified by filename to the given PrintStream.
public static void scanFile(String filename, PrintStream out) throws FileNotFoundException { Scanner scanner = LexicalAnalyzer.make(filename); while (scanner.hasNext()) { printNextToken(out, scanner); } printNextToken(out, scanner); // prints NullToken }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public static void print(String filename) {\n // create a file writer\n UTF8FileUtility.createWriter(filename);\n // create a string buffer for storing the text\n StringBuilder sBuffer = new StringBuilder();\n int numTokens = 0;\n int freq = 0;\n for (String token : UNIGRAM.keySet()) {\n freq = UNIGRAM.get(token);\n numTokens += freq;\n sBuffer.append(token).append('\\t').append(freq).append(\"\\n\");\n }\n // write the string buffer to the file\n UTF8FileUtility.write(sBuffer.toString());\n // close the writer\n UTF8FileUtility.closeWriter();\n System.err.println(\"# of tokens = \" + numTokens);\n System.err.println(\"# of unigrams = \" + UNIGRAM.size());\n }", "public static void Print(String fileName)\r\n {\n File file = new File(System.getProperty(\"user.dir\")+\"\\\\\"+fileName+\".txt\"); \r\n \r\n try \r\n {\r\n Scanner sc = new Scanner(file);\r\n \r\n while (sc.hasNextLine()) \r\n {\r\n System.out.println(sc.nextLine());\r\n }\r\n }\r\n catch (FileNotFoundException ex) \r\n {\r\n Logger.getLogger(TxtReader.class.getName()).log(Level.SEVERE, null, ex);\r\n }\r\n \r\n \r\n }", "public void readAndPrint(String fileName)\n\t{\n\t\tString[] names = null;\n\t\tFile file = new File(fileName);\n\t\tScanner sc;\n\t\ttry {\n\t\t\tsc = new Scanner(file);\n\t\t\twhile (sc.hasNextLine()) {\n\t\t\t\tString line = sc.nextLine();\n\t\t\t\tString[] tokens = line.split(\" \");\n\t\t\t\tSystem.out.println(\"Person: \" + tokens[0] + \", \" + \n\t\t\t\t\"Age: \" + tokens[1] + \" \");\n\t\t\t\tSystem.out.print(tokens[0] + \",\");\n\t\t\t}\n\t\t} \n\t\tcatch (FileNotFoundException e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\n\t\t\t//process the information\n\t\t}\n\n\t\t//System.out.println(\"readAndPrint NOT IMPLEMENTED\");\n\t}", "void printFile(String path) {\n try {\n String[] readFileOutPut = readFile(path);\n for (int i = 0; i < readFileOutPut.length;i++) System.out.println(readFileOutPut[i]);\n } catch (Exception e) {\n e.printStackTrace();\n }\n }", "abstract void print(String fileName);", "public void printFile() {\n\t\t\n\t\tfor(String[] line_i: linesArray) {\n\t\t\tSystem.out.println( Arrays.toString(line_i) );\n\t\t}\n\t}", "public void printResults(String fileName) {\n\t\ttry {\n\t\t\tPrintWriter writer = new PrintWriter(fileName, \"UTF-8\");\n\t\t\tfor (int i = 0; i < results.size(); i++) {\n\t\t\t\twriter.println(results.get(i).toString());\n\t\t\t}\n\n\t\t\twriter.close();\n\t\t} catch (IOException e) {\n\t\t\te.printStackTrace();\n\t\t\tSystem.err.println(\"Error while writing to output file\");\n\t\t} finally {\n\t\t\t/*try {\n\t\t\t\twriter.close();\n\t\t\t} catch (IOException e) {\n\t\t\t\te.printStackTrace();\n\t\t\t\tSystem.err.println(\"Error while reading input file\");\n\t\t\t}*/\n\t\t}\t\t\n\t}", "void print(String fileName)\n\t{\n\t\t//Get the reference of the head of the Linked list\n\t\tNode ref = head;\n\t\t\n\t\t//Print the elements and also write them into a file if the head is initialized\n\t\tif(ref != null)\n\t\t{\n\t\t\ttry \n\t\t\t{\n\t\t\t\t//Create a file output.txt\n\t\t\t\tPrintWriter writer = new PrintWriter(fileName);\n\t\t\t\t\n\t\t\t\t//Traverse till the end of the Linked List \n\t\t\t\twhile(ref != null)\n\t\t\t\t{\n\t\t\t\t\tref = ref.next;\n\t\t\t\t\tif(ref != null)\n\t\t\t\t\t{\n\t\t\t\t\t\t//Print the elements and also write them into a file\n\t\t\t\t\t\tSystem.out.print(ref.value + \" \");\n\t\t\t\t\t\twriter.print(ref.value + \" \");\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t//Close the file\n\t\t\t\twriter.close();\n\t\t\t} \n\t\t\tcatch (FileNotFoundException e) \n\t\t\t{\n\t\t\t\t//Printing the Stack Trace if an exception has occurred\n\t\t\t\te.printStackTrace();\n\t\t\t}\n\t\t}\n\t\tSystem.out.println();\n\t}", "public static void main(String[] args) throws FileNotFoundException {\n checkArguments(args, className());\n\n Tokens.setPrintLevel(Tokens.Level.TYPE_AND_VALUE);\n scanFile(args[0], System.out);\n }", "void print() {\r\n\t\tOperations.print(lexemes, tokens);\r\n\t}", "@Override\n\tpublic void printToFile() {\n\t\t\n\t}", "public void printAll(String file) throws FileNotFoundException, IOException, ParseException {\n\t\tarrayList = pareseFile(file);\n\t\tSystem.out.println(file + \" Adress book\");\n\t\tSystem.out.println(arrayList.toString());\n\n\t}", "void setStdoutFile(File file);", "public static void printFileName(String filename) {\n System.out.println(\"\\n\" + filename + \":\");\n }", "protected PrintStream getPrintStream(File fOut)\n {\n try\n {\n OutputStream os = new FileOutputStream(fOut, true);\n return new PrintStream(new BufferedOutputStream(os));\n }\n catch (FileNotFoundException e)\n {\n // This error will never occur. The file will be created.\n throw ensureRuntimeException(e);\n }\n }", "public void handlePrintFile (File printFile) {\n // not supported\n }", "public void printFileOnconsole(File file, int tabs,int lenghtOfDirectory) throws DirectoryException{\r\n\t\tSystem.out.println(\"file ->\" + file);\r\n\t\tString fileName = file.getName();\r\n\t\tString[] split = fileName.split(HelperContstants.DELIMETER);\r\n\t\tfor (int i = 0; i < tabs; i++) {\r\n\t\t\tSystem.out.print(\" \");\r\n\t\t}\r\n\t\tSystem.out.println(\"- Document: \" + file.getName() + \" - Extension: .\" + split[split.length - 1] + \" - URL: \"\r\n\t\t\t\t+ file.getAbsolutePath().substring(lenghtOfDirectory));\r\n\t}", "public void printTokens() {\n for (int i = 0; i < tokens.size(); i++) {\n System.out.print(tokens.get(i).getValue());\n if (i + 1 < tokens.size()) {\n System.out.print(\", \");\n }\n }\n System.out.println();\n }", "public void writeTokens() throws IOException {\r\n FileOutputStream fOutStream = new FileOutputStream(\"output.txt\");\r\n PrintStream outFS = new PrintStream(fOutStream);\r\n\r\n for (int i = 0; i < tokenList.size(); i++) {\r\n outFS.println(tokenList.get(i).evaluate());\r\n }\r\n fOutStream.close();\r\n outFS.close();\r\n }", "public abstract void printToStream(PrintStream stream);", "private PrintStream getOutput(String name) {\n try {\n return new PrintStream(new File(name));\n } catch (IOException excp) {\n throw error(\"could not open %s\", name);\n }\n }", "public void println(String line);", "public Scanner( String filename ) throws IOException\n {\n sourceFile = new PushbackInputStream(new FileInputStream(filename));\n \n nextToken = null;\n }", "public static void main(String[] args) {\n Path file = Paths.get (\"courses.txt\");\n// line n1\n /* Assume the courses.txt is accessible.\n Which code fragment can be inserted at line n1 to enable the code to print the content of the*/\n //courses.txt file?\n /* A. List<String> fc = Files.list(file);\n fc.stream().forEach (s - > System.out.println(s));\n B. Stream<String> fc = Files.readAllLines (file);\n fc.forEach (s - > System.out.println(s));\n // C. List<String> fc = readAllLines(file);\n //fc.stream().forEach (s - > System.out.println(s));\n D. Stream<String> fc = Files.lines (file);///answer\n fc.forEach (s - > System.out.println(s));*/\n }", "public void dump(File file)\n {\n try\n {\n FileOutputStream out = new FileOutputStream(file);\n BufferedWriter write = new BufferedWriter(new OutputStreamWriter(out, Encoder.UTF_8));\n\n dump(write);\n\n write.close();\n }\n catch (Exception ex)\n {\n ex.printStackTrace();\n }\n }", "public void print(String line);", "public void dump(final PrintStream ps) {\n ((SegmentedInMemoryKeyValueStorage) storage).dump(ps);\n }", "void setOutput(String filename) throws FileNotFoundException{\n\t\tSystem.out.println(\"Created file: \" + filename);\t\n\t\ttry {\n\t\t\tout = new PrintStream(new FileOutputStream(filename));\n\t\t\tSystem.setOut(out);\n\t\t} catch (FileNotFoundException e) {\n\t\t\te.printStackTrace();\n\t\t}\n\t}", "public static void main(String[] args) throws FileNotFoundException {\n\t\tFile inFile = new File(\"result/in.txt\");\n\t\tFile outFile = new File(\"result/out.txt\");\n\t\tint begin = 4;\n\t\t\n\t\tScanner cs = new Scanner(inFile);\n\t\tPrintWriter out = new PrintWriter(outFile);\n\t\t\n\t\twhile(cs.hasNextLine())\n\t\t{\n\t\t\tString line = cs.nextLine();\n\t\t\tline = line.substring(begin);\n\t\t\tout.println(line);\n\t\t}\n\t\tcs.close();\n\t\tout.close();\n\t\t\n\t}", "void println(String line);", "public void print ()\n\t{\n\t\tSystem.out.println(\"Polyhedron File Name: \" + FileName);\n\t\tSystem.out.println(\"Object active: \" + Boolean.toString(isActive()));\n\t\tprintCoordinates();\n\t}", "public static void main(String[] args) {\n\t\tPrintStream gravador;\n\t\ttry {\n\t\t\tgravador = new PrintStream(\"saida.txt\");\n\t\t\tgravador.println(\"Texto\");\n\t\t\tgravador.println(\"oi\");\n\t\t\tgravador.println(\"Te\");\n\t\t\tgravador.println(\"liguei\");\n\t\t\tgravador.println(\"deve\");\n\t\t\tgravador.println(\"Ta ocupadinho\");\n\t\t\tgravador.close();\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\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 void main(String argv[]) {\n if (argv.length == 0) {\n System.out.println(\"Usage : java PasitoScanner <inputfile>\");\n }\n else {\n for (int i = 0; i < argv.length; i++) {\n PasitoScanner scanner = null;\n try {\n scanner = new PasitoScanner( new java.io.FileReader(argv[i]) );\n do {\n System.out.println(scanner.next_token());\n } while (!scanner.yy_atEOF);\n\n }\n catch (java.io.FileNotFoundException e) {\n System.out.println(\"File not found : \\\"\"+argv[i]+\"\\\"\");\n }\n catch (java.io.IOException e) {\n System.out.println(\"IO error scanning file \\\"\"+argv[i]+\"\\\"\");\n System.out.println(e);\n }\n catch (Exception e) {\n System.out.println(\"Unexpected exception:\");\n e.printStackTrace();\n }\n }\n }\n }", "public static void fileWriterPrinter() throws NumberFormatException, IOException {\n // Create File:\n\t\t\t\tFile f = new File(Common.testOutputFileDir + \"print.log\");\t\t\t\t \n\t\t\t // Write or add a String line into File:\t\n\t\t\t FileWriter fw = new FileWriter(f,true);\n\t\t\t PrintWriter pw = new PrintWriter(fw);\n\t\t\t pw.println();\n\t\t\t pw.close();\n\t\t\t // System Out Print Line:\n\t\t\t // if (printLine instanceof String) {}\n\t\t\t // if (printLine instanceof Integer) {}\n\t\t\t // if (printLine instanceof Long) {}\n\t\t\t // if (printLine instanceof Boolean) {}\n\t\t\t // if (printLine instanceof Double) {}\n\t\t\t System.out.print(\"\\n\");\t\t \n\t\t\t}", "public void printData() {\n\t\ttry {\n\t\t\tFiles.lines(new File(PAYROLL_FILE_NAME).toPath())\n\t\t\t.forEach(System.out::println); \n\t\t}catch(IOException e)\n\t\t{\n\t\t\te.printStackTrace();\n\t\t}\n\t}", "public TokenScanner(final File f) throws FileNotFoundException {\n\t\tfileScanner = new Scanner(file = f);\n\t}", "public static void main(String[] args) throws FileNotFoundException {\n\t PrintStream o = new PrintStream(new File(\"KittenAddress.txt\"));\n\t PrintStream console = System.out;\n\t \n\t System.setOut(o);\n\t System.out.println(\"LIST OF ADDRESSES: \" + \"\\n\" + \"--------------------\");\n\t \n\t // print address list into KittenAddress.txt\n\t\tReadExcel kittenAddressList = new ReadExcel();\n\t\tkittenAddressList.printer();\n\t\tSystem.setOut(console);\n\t \n\t \n\t\n\t}", "void dump(PrintStream x) {\n String str = buffer.toString();\n x.println(\"<beginning of \" + name + \" buffer>\");\n x.println(str);\n x.println(\"<end of buffer>\");\n }", "private static PrintStream determineOutputSource(String[] args) throws FileNotFoundException {\n if (args.length == 2) {\n //Writing to file\n return new PrintStream(new File(args[1]));\n } else {\n //Writing to standard Output\n return System.out;\n }\n\n }", "static void print(FileSearch fileSearch) {\n System.out.print(fileSearch.getFile().getFileName() + COLON);\n System.out.print(fileSearch.getMatchCount() * 100 / fileSearch.getLine().split(DELIMITER).length);\n System.out.println(PERCENTAGE);\n }", "public TextFilePrinter getPrinter();", "public static void main(String[] args) throws IOException {\n\t\t FileInputStream file=new FileInputStream(\"C:\\\\Users\\\\DELL\\\\Desktop\\\\test.txt\");\r\n Scanner scan=new Scanner(file);\r\n while(scan.hasNextLine()){\r\n \t System.out.println(scan.nextLine());\r\n }\r\n \r\n file.close();\r\n\t}", "public void openFile() {\n try {\n x = new Formatter(\"DistanceTraveled.txt\");\n }\n catch (Exception e) {\n System.out.println(\"You have an error.\");\n }\n }", "public static void main(String[] args) {\n BufferedReader bf = null;\r\n System.out.println(\" ********************Token***************\");\r\n try {\r\n bf = new BufferedReader(new FileReader(\"src/convertidor/Entrada.txt\"));\r\n Analizador a = new Analizador(bf);\r\n Symbol token = null;\r\n do {\r\n token = a.next_token();\r\n token.value.toString();\r\n System.out.println(token.value.toString());\r\n\r\n } while (token != null);\r\n\r\n bf.close();\r\n } catch (Exception e) {\r\n System.out.println(\"Error en \" + e.getMessage());\r\n }\r\n\r\n }", "void print(String fileName)\n\t{\n\t\t//Print the elements and also write them into a file if the array is initialized\n\t\tif(inputArray != null)\n\t\t{\n\t\t\ttry \n\t\t\t{\n\t\t\t\t//Create a file output.txt\n\t\t\t\tPrintWriter writer = new PrintWriter(fileName);\n\t\t\t\tfor(int i=0; i < inputArray.length; i++)\n\t\t\t\t{\n\t\t\t\t\t//Print the elements and also write them into a file\n\t\t\t\t\tSystem.out.print(inputArray[i] + \" \");\n\t\t\t\t\twriter.print(inputArray[i] + \" \");\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t//Close the file\n\t\t\t\twriter.close();\n\t\t\t} \n\t\t\tcatch (FileNotFoundException e) \n\t\t\t{\n\t\t\t\t//Printing the Stack Trace if an exception has occurred\n\t\t\t\te.printStackTrace();\n\t\t\t}\n\t\t}\n\t\tSystem.out.println();\n\t}", "private void sortFileToScreen() throws FileNotFoundException {\n Scanner file = new Scanner(new File(FILE_NAME));\n while (file.hasNext()) {\n addToOrderedList(file.nextInt());\n }\n file.close();\n printList();\n }", "public void searchResultsPrint(String fileName, String context) {\n\t\ttry {\n\t\t\tFileWriter fileWriter = new FileWriter(fileName);\n\t\t\tBufferedWriter writer = new BufferedWriter(fileWriter);\n\t\t\twriter.write(context);\n\t\t\twriter.close();\n\t\t\tfileWriter.close();\n\t\t} catch (IOException e) {\n\t\t\tSystem.out.println(\"IO is broken!\");\n\t\t}\n\t}", "public static void main(String[] args) {\n\t\tSystem.out.println(\"Hudai\");\r\n\t\t\r\n\t\ttry {\r\n\t\t\t//System.setIn(new Scanner(new File(E:\\\\hudai\\\\filetry.txt)));\r\n\t\t\tSystem.setOut(new PrintStream(new FileOutputStream( new File(\"E:\\\\hudai\\\\filetry.txt\"))) );\r\n\t\t\tSystem.out.println(\"Happy to see \");\r\n\t\t\tSystem.out.println(\"মোঃ জুবায়ের ইবনে মোস্তফা\");\r\n\t\t\tSystem.out.println(\"Nothing\");\r\n\t\t\t\r\n\t\t\tSystem.setOut( new PrintStream(new FileOutputStream(FileDescriptor.out)));\r\n\t\t\tSystem.out.println(\"Happy to see \");\r\n\t\t\tSystem.out.println(\"Nothing\");\r\n\t\t} catch (FileNotFoundException e) {\r\n\t\t\t// TODO Auto-generated catch block\r\n\t\t\te.printStackTrace();\r\n\t\t}\r\n\t}", "public static void main(String[] args) throws Exception {\n CharStream input = CharStreams.fromFileName(\"T2-Ejercicios/T2-Ej2/Multiplo.txt\");\n FileOutputStream f = new FileOutputStream(\"T2-Ejercicios/T2-Ej2/MultiploOut.txt\");\n System.setOut(new PrintStream(f));\n // create a lexer that feeds off of input CharStream\n MultiploLexer lexer = new MultiploLexer(input);\n // create a buffer of tokens pulled from the lexer\n CommonTokenStream tokens = new CommonTokenStream(lexer);\n // create a parser that feeds off the tokens buffer\n MultiploParser parser = new MultiploParser(tokens);\n parser.r();\n System.out.println(); // print a \\n after translation\n }", "public static void main(String[] args) throws FileNotFoundException {\n\n\t\tFile file = new File(\"B:\\\\output.txt\");\n\t\t\n\t\tScanner input = new Scanner(file);\n\t\t\n\t\twhile(input.hasNextLine()) {\n\t\t\tString tmp = input.nextLine();\n\t\t\t\n\t\t\tSystem.out.println(tmp);\n\t\t}\n\t\tinput.close();\n\t}", "static private void printSentenceTokens( final String documentId, final Iterable<String> tokenizedSentences ) {\n System.out.println( \"=========================== \" + documentId + \" ===========================\" );\n for ( String tokenizedSentence : tokenizedSentences ) {\n System.out.println( tokenizedSentence );\n }\n }", "public static void main(String[] args) throws IOException, ScannerException{\n Scanner scan = new Scanner(\"test_input/ex1.tiger\");\n List<Token> tokens = scan.getTokens();\n for (Token tok : tokens) {\n System.out.println(tok.allDetails());\n }\n }", "public Printer(File file) {\n this.file = file;\n log = LogManager.getLogManager().getLogger(Printer.class.getName());\n // initialization of the template path\n base = System.getProperty(\"user.dir\") + File.separator + \"config\"\n + File.separator + \"template\" + File.separator;\n\n // </snip>\n\n // System.out.println(\"template printing\");\n\n start();\n }", "private static void _printResource (final String filename)\n {\n try\n {\n // find the file resource\n final InputStream is = Main.class.getResourceAsStream (filename);\n if (is == null)\n throw new java.io.FileNotFoundException (filename);\n final BufferedReader br = new BufferedReader (new InputStreamReader (is));\n boolean doOutput = true;\n String line;\n while ((line = br.readLine ()) != null)\n {\n if (line.startsWith (\"@@@ \"))\n {\n // special control line\n if (line.equals (\"@@@ START DEBUG ONLY\"))\n doOutput = CSTX.DEBUG;\n else\n if (line.equals (\"@@@ END DEBUG ONLY\"))\n doOutput = true;\n // else: ignore\n continue;\n }\n if (doOutput)\n System.err.println (line);\n }\n System.err.println (\"\");\n }\n catch (final IOException ex)\n {\n log.error (\"Exception\", ex);\n }\n }", "public void print() {\n for (int i=0; i<lines.size(); i++)\n {\n System.out.println(lines.get(i));\n }\n }", "public MchPrinter(BPrinter fp, PrintStream ps) {\n\t\tprinter = fp;\n\t\tstream = ps;\n\t}", "public void outputToStream(PrintWriter dos) throws IOException {\n dos.println(fileName);\n if (lineNos != null) {\n dos.println(lineNos.length);\n for (int i = 0; i < lineNos.length; ++i) {\n dos.println(lineNos[i]);\n }\n }\n }", "public void printToFile(Path filename) {\n\t\t\n\t\tlock.lockRead();\n\t\ttry{\n//\t\t\t create a new file if it is not existed; \n//\t\t\t otherwise delete previous one and create a new one.\n\t\t\tif(!Files.exists(filename)){\n\t\t\t\ttry {\n\t\t\t\t\tFiles.createFile(filename);\n\t\t\t\t} catch (IOException e) {\n\t\t\t\t\te.printStackTrace();\n\t\t\t\t}\n\t\t\t}\n\t\t\telse{\n\t\t\t\ttry {\n\t\t\t\t\tFiles.delete(filename);\n\t\t\t\t\tFiles.createFile(filename);\n\t\t\t\t} catch (IOException e) {\n\t\t\t\t\te.printStackTrace();\n\t\t\t\t}\n\t\t\t}\n\t\t\tfor(String hotelId : hotelMap.keySet()){\n\t\t\t\tString output = this.toString(hotelId);\n\t\t\t\t\t\t\t\n\t\t\t\t// start of the hotel.\n\t\t\t\tString emptyLine = \"\\n\";\n\t\t\t\tString ast = \"********************\";\n\t\t\t\t\n\t\t\t\ttry {\n\t\t\t\t\tFiles.write(filename, emptyLine.getBytes(), StandardOpenOption.APPEND);\n\t\t\t\t\tFiles.write(filename, ast.getBytes(), StandardOpenOption.APPEND);\n\t\t\t\t\tFiles.write(filename, emptyLine.getBytes(), StandardOpenOption.APPEND);\n\t\t\t\t} catch (IOException e1) {\n\t\t\t\t\te1.printStackTrace();\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\ttry{\n\t\t\t\t\tFiles.write(filename, output.getBytes(), StandardOpenOption.APPEND);\n\t\t\t\t} catch (IOException e) {\n\t\t\t\t\te.printStackTrace();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tfinally{\n\t\t\tlock.unlockRead();\n\t\t}\n\t\t\t\n\t}", "public static void main(String[] args) throws FileNotFoundException,IOException {\n\t\tFileReader fr=new FileReader(\"E:\\\\iostreams\\\\question.txt\");\n\n\t\tBufferedReader br=new BufferedReader(fr);\n\n\t\tStreamTokenizer st=new StreamTokenizer(br);\n\n\t\tint token=0;\n\t\tdouble sum=0;\n\t\twhile((token=st.nextToken())!=StreamTokenizer.TT_EOF) {\n\n\t\t\tswitch(token) {\n\t\t\t\tcase StreamTokenizer. TT_NUMBER:\n\t\t\t\t{\n\t\t\t\t\t//System.out.println(st.nval);\n\t\t\t\t\tsum+=st.nval;\n\t\t\t\t\t//System.out.println(sum);\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t\tcase StreamTokenizer. TT_WORD:\n\t\t\t\t{\n\t\t\t\t\tif(sum!=0) {\n\t\t\t\t\t\tSystem.out.println((int)sum);\n\t\t\t\t\t}\n\t\t\t\t\tSystem.out.print(st.sval+\" \");\n\t\t\t\t\tsum=0;\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tSystem.out.println((int)sum);\n\n\t}", "public static void writeTokens(TokenStream tokens, File file) throws IOException {\n FileOutputStream fos = null;\n try {\n file.getParentFile().mkdirs();\n Logger.getLogger(ANTLRHelper.class.getName()).log(\n Level.FINE, \"Writing tokens to {0}\", file.getPath());\n fos = new FileOutputStream(file);\n fos.write(tokens.toString().getBytes());\n } finally {\n if (fos != null) {\n try {\n fos.close();\n } catch (IOException ex) {\n // TODO: catch IOException\n }\n }\n }\n }", "public void writePrintStream(String line, String path) {\n PrintStream fileStream = null;\n File file = new File(path);\n\n try {\n fileStream = new PrintStream(new FileOutputStream(file, true));\n } catch (FileNotFoundException e) {\n e.printStackTrace();\n }\n fileStream.println(line);\n fileStream.close();\n }", "public void print() {\n\t\tfor(String subj : subjects) {\n\t\t\tSystem.out.println(subj);\n\t\t}\n\t\tSystem.out.println(\"==========\");\n\t\t\n\t\tfor(StudentMarks ssm : studMarks) {\n\t\t\tSystem.out.println(ssm.student);\n\t\t\tfor(Byte m : ssm.marks) {\n\t\t\t\tSystem.out.print(m + \" \");\n\t\t\t}\n\t\t\tSystem.out.println();\n\t\t}\n\t}", "public void println();", "public void print();", "public void print();", "public void print();", "public void print();", "public static void main(String[] args) throws FileNotFoundException {\n RandomizedQueue<String> randomizedQueue = new RandomizedQueue();\n FileInputStream inputStream = new FileInputStream(args[0]);\n Scanner scanner = new Scanner(inputStream);\n while (scanner.hasNext()) {\n randomizedQueue.enqueue(scanner.next());\n }\n Iterator it = randomizedQueue.iterator();\n while (it.hasNext()) {\n StdOut.print(it.next() + \" \");\n }\n }", "public static void printOut(Talkable p) {\n System.out.println(p.getName() + \" says=\" + p.talk());\n outFile.fileWrite(p.getName() + \"|\" + p.talk());\n }", "public static void main(String[] args) throws IOException {\r\n BufferedReader input = new BufferedReader(new InputStreamReader(System.in,\"UTF-8\"));\r\n PrintStream output = new PrintStream(System.out, true, \"UTF-8\");\r\n \tString line;\r\n \twhile ( (line = input.readLine()) != null) {\r\n \t\tList<String> toks = tokenizeRawTweetText(line);\r\n \t\tfor (int i=0; i<toks.size(); i++) {\r\n \t\t\toutput.print(toks.get(i));\r\n \t\t\tif (i < toks.size()-1) {\r\n \t\t\t\toutput.print(\" \");\r\n \t\t\t}\r\n \t\t}\r\n \t\toutput.print(\"\\n\");\r\n \t}\r\n }", "public static void main(String[] args) throws FileNotFoundException {\n\t\tFile file = new File(\"Score.txt\");\r\n\t\tif(file.exists())\r\n\t\t{\r\n\t\t\tSystem.out.println(\"File is already exist! \");\r\n\t\t\tSystem.exit(0);\r\n\t\t}\r\n\t\t\r\n\t\tPrintWriter output = new PrintWriter(file);\r\n\t\t\r\n\t\toutput.print(\"John T Smith \");\r\n\t\toutput.println(90);\r\n\t\toutput.print(\"Eric asd asd: \");\r\n\t\toutput.println(80);\r\n\t\t\r\n\t\toutput.close();\r\n\t}", "static void echoFile() {\n BufferedReader echo = new BufferedReader(fileIn);\n String curr_char = \"\";\n try {\n while((curr_char = echo.readLine()) != null) {\n System.out.println(curr_char);\n }\n cout.println();\n }\n catch(IOException e) {\n System.out.println(\"echofile error\");\n }\n }", "public void printFile(String fileName)\n {\n try\n {\n //takes the output string and writes it in a new file\n //called output.txt\n FileOutputStream out = new FileOutputStream(\n new File(fileName), true);\n out.write(logImage.getBytes());\n out.flush();\n out.close(); \n }\n //catches all exceptions from writing into the .txt\n catch(Exception e)\n {\n System.out.println(\"There was an error while writing into file\");\n }\n }", "public static void fileWriterPrinter(String fileName, Object printLine) throws NumberFormatException, IOException {\n // Create File:\n\t\t\t\tFile f = new File(Common.testOutputFileDir + fileName);\t\t\t\t \n\t\t\t // Write or add a String line into File:\t\n\t\t\t FileWriter fw = new FileWriter(f,true);\n\t\t\t PrintWriter pw = new PrintWriter(fw);\n\t\t\t pw.println(printLine);\n\t\t\t pw.close();\n\t\t\t // System Out Print Line:\n\t\t\t fileWriterPrinter(printLine);\n\t\t\t}", "public static void main(String[] args) throws IOException {\n\t\tFile file = new File(\"fileAAA.txt\");\r\n\t\tPrintWriter output = new PrintWriter(file);\r\n\t\t\r\n\t\t//write name and age to file\r\n\t\toutput.println(\"Homer Akin\");\r\n\t\toutput.println(49);\r\n\t\toutput.close();\r\n\t\t\r\n\t\tScanner input = new Scanner(file);\r\n\t\tString name = input.nextLine();\r\n\t\tint age = input.nextInt();\r\n\t\t\r\n\t\tSystem.out.printf(\"Name: %s \\nAge : %d\",name, age);\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\r\n\t\t\r\n\t}", "public static void echoFile(Scanner in) {\n }", "public void print() {\r\n\t\tSystem.out.print(getUID());\r\n\t\tSystem.out.print(getTITLE());\r\n\t\tSystem.out.print(getNOOFCOPIES());\r\n\t}", "@VisibleForTesting\n void print();", "public void recordOrder(){\n PrintWriter output = null;\n try{\n output = \n new PrintWriter(new FileOutputStream(\"record.txt\", true));\n }\n catch(Exception e){//throws exception\n System.out.println(\"File not found\");\n System.exit(0);\n }\n output.println(Coffee);//prints in file contents of Coffee\n output.close();//closes file\n }", "public void printListOfFile(List<File> listToPrint) {\n\t\tthis.showNamedMessage(\"List of files:\");\n\t\tfor (int i = 0; i < listToPrint.size(); i++) {\n\t\t\tthis.showNamedMessage(\"[\" + i + \"]: \" + listToPrint.get(i));\n\t\t}\n\t}", "public void recordOrder(){ \n PrintWriter output = null;\n try{\n output = \n new PrintWriter(new FileOutputStream(\"record.txt\", true));\n }\n catch(Exception e){\n System.out.println(\"File not found\");\n System.exit(0);\n }\n output.println(Tea);//writes into the file contents of String Tea\n output.close();//closes file\n }", "public static void pf (String format, Object[] args) {\n System.out.println (spf (format, args));\n }", "static void printHeader(String fn, PrintWriter out) throws IOException\n{\n\t@SuppressWarnings(\"resource\")\n\tScanner input = new Scanner(new FileInputStream(new File(fn)));\n\twhile(input.hasNext())\n\t{\n\t\tString line = input.nextLine();\n\t\tif(line.length() == 0) continue;\n\t\tif(line.charAt(0) == '#') out.println(line);\n\t\telse break;\n\t}\n}", "public static void printMap(Map<String, Double> map, String filename) throws FileNotFoundException, UnsupportedEncodingException{\n\t\t\t\n\t\t\tPrintWriter writer = new PrintWriter(\"C:/Naveen/CCS/IR/AP89_DATA/AP_DATA/IndexWithStoppingAndWithStemming/\"+filename, \"UTF-8\");\n\t for (Entry<String, Double> entry : map.entrySet()){\n\t \t \n\t \t\twriter.println(entry.getKey()+\" \"+entry.getValue()+\" Exp\");\n\t }\n\t writer.close();\n\t }", "public void printer() throws Exception{\n File outputFile = new File(\"output.txt\");\n FileOutputStream is = new FileOutputStream(outputFile);\n OutputStreamWriter osw = new OutputStreamWriter(is);\n Writer w = new BufferedWriter(osw);\n w.write(this.result());\n w.close();\n }", "public static void main(String args[]) {\n System.out.println(\"test program for template printing\");\n String kk = \"src/Printer.java\";\n if (true || args.length > 0) {\n File file = new File(kk);\n System.out.println(\"printing file: \" + file.getName());\n if (file.exists()) {\n // this will be the standard future use of this class: fire and\n // forget\n new Printer(file);\n } else {\n System.out.println(\"file \" + file.getAbsolutePath()\n + \" doesn't exist!\");\n }\n } else {\n System.out.println(\"usage: <filename>\");\n }\n\n }", "public void readFile()\r\n\t{\r\n\t\t\r\n\t\ttry\r\n\t\t{\r\n\t\t\tx = new Scanner(new File(\"clean vipr measles results.txt\"));\r\n\t\t\t\r\n\t\t\twhile (x.hasNext())\r\n\t\t\t{\r\n\t\t\t\tString a = x.next();\r\n\t\t\t\tString b = x.next();\r\n\t\t\t\tString c = x.next();\r\n\t\t\t\t\r\n\t\t\t\tSystem.out.printf(\"%s %s %s \\n\\n\", a,b,c);\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\tx.close();\r\n\t\t}\r\n\t\tcatch (Exception e)\r\n\t\t{\r\n\t\t\tSystem.out.println(\"file not found\");\r\n\t\t}\r\n\t\r\n\t}", "public void openFile(){\n\t\ttry{\n\t\t\t//input = new Scanner (new File(\"input.txt\")); // creates file \"input.txt\" or will rewrite existing file\n\t\t\tFile inFile = new File(\"input.txt\");\n\t\t\tinput = new Scanner(inFile);\n\t\t\t//for (int i = 0; i < 25; i ++){\n\t\t\t\t//s = input.nextLine();\n\t\t\t\t//System.out.println(s);\n\t\t\t//}\n\t\t}catch (SecurityException securityException){ // catch errors\n\t\t\tSystem.err.println (\"You do not have the write access to this file.\");\n\t\t\tSystem.exit(1);\n\t\t}catch (FileNotFoundException fnf){// catch errors\n\t\t\tSystem.err.println (\"Trouble opening file\");\n\t\t\tSystem.exit(1);\n\t\t}\n\t}", "private static void printToFile(FrequencyCounter<Integer> freqCounter, ArrayList<Pair<Integer, Float>> plot) {\r\n\t\tPrintWriter writer;\r\n\t\ttry {\r\n\t\t\tString fName = \"experimentalResults\" + File.separator + \"results\" + freqCounter.getname() + \".txt\";\r\n\t\t\twriter = new PrintWriter(new File(fName));\r\n\t\t\tfor (Pair<Integer, Float> p : plot)\r\n\t\t\t\twriter.println(p);\r\n\r\n\t\t\twriter.close();\r\n\t\t} catch (FileNotFoundException e) {\r\n\t\t\te.printStackTrace();\r\n\t\t}\r\n\t}", "@Override\r\n\tpublic void handleFile(String inFilename, String outFilename) \r\n\t{\n\r\n\r\n\t\tString s = slurpFile(inFilename);\r\n\t\tDocument teiDocument = parsePlainText(s);\r\n\t\ttry \r\n\t\t{\r\n\t\t\tPrintStream pout = new PrintStream(new FileOutputStream(outFilename));\r\n\t\t\tpout.print(XML.documentToString(teiDocument));\r\n\t\t\tpout.close();\r\n\t\t} catch (FileNotFoundException e) \r\n\t\t{\r\n\t\t\te.printStackTrace\r\n\t\t\t();\r\n\r\n\t\t}\t\r\n\t}", "private static void printArrows(ClassContainer tempClass, ArrayList<String> whitelist, PrintWriter printFile) {\n\t\tprintUses(tempClass, whitelist, printFile);\n\t\tprintFields(tempClass, whitelist, printFile);\n\t\tprintInterfaces(tempClass, whitelist, printFile);\n\t\tprintSupers(tempClass, whitelist, printFile);\n\t}", "void print();", "void print();", "void print();", "void print();", "void print();", "public void printAll(){\n\t\tSystem.out.println(\"Single hits: \" + sin);\n\t\tSystem.out.println(\"Double hits: \" + doub);\n\t\tSystem.out.println(\"Triple hits: \" + trip);\n\t\tSystem.out.println(\"Homerun: \" + home);\n\t\tSystem.out.println(\"Times at bat: \" + atbat);\n\t\tSystem.out.println(\"Total hits: \" + hits);\n\t\tSystem.out.println(\"Baseball average: \" + average);\n\t}", "public static void read7() {\n //read file into stream, try-with-resources\n try (Stream<String> stream = Files.lines(Paths.get(filePath))) {\n\n stream.forEach(System.out::println);\n\n } catch (IOException e) {\n e.printStackTrace();\n }\n }", "private void outputToFile(String filename) throws FileNotFoundException, IOException {\n\t\tBufferedWriter writer = new BufferedWriter(\n\t\t\t\tnew FileWriter(filename+\".tmp\"));\n\t\twriter.write(VERIFY_STRING + \"\\n\");\n\n\t\t// output automata info\n\t\twriter.write(machine.getName() + \"\\n\");\n\t\twriter.write(machine.getType() + \"\\n\");\n\n\t\t// output state info\n\t\tfor (State state : machine.getStates()) {\n\t\t\twriter.write(\"STATE\\n\");\n\t\t\twriter.write(state.getName() + \"\\n\");\n\t\t\twriter.write(state.isAccept() + \" \" + state.isStart() + \" \" + \n\t\t\t\t\tstate.getID() + \" \" + state.getGraphic().getX() + \" \" + \n\t\t\t\t\tstate.getGraphic().getY() + \"\\n\");\n\n\t\t\t// output transitions\n\t\t\tfor (Transition t : state.getTransitions())\n\t\t\t\twriter.write(t.getID() + \" \" + t.getInput() + \" \" + \n\t\t\t\t\t\tt.getNext().getID() + \"\\n\");\n\t\t}\n\t\twriter.close();\n\t}", "private void print(Scanner input) {\n\t\tprogramStack.add(\"print\");\n\n\t\twhile (input.hasNext()){\n\t\t\tString token = input.next();\n\t\t\tif(token.equalsIgnoreCase(\"add\"))\n\t\t\t\taddOp(input);\n\t\t\telse\n\t\t\t\tprogramStack.push(token);\n\t\t}\n\n\t\tStringBuilder toPrint = new StringBuilder();\n\t\twhile (!programStack.peek().equalsIgnoreCase(\"print\")) {\n\t\t\tString popped = programStack.pop();\n\t\t\tif (isVariable(popped))\n\t\t\t\ttoPrint.insert(0, getRAMValue(popped) + \" \");\n\t\t\telse\n\t\t\t\ttoPrint.insert(0, popped + \" \");\n\t\t}\n\t\ttoPrint = new StringBuilder(toPrint.toString().trim());\n\n\t\tSystem.out.println(toPrint);\n\n\t\tprogramStack.pop();\n\t}" ]
[ "0.64082086", "0.6067209", "0.59840024", "0.5690361", "0.563831", "0.55892015", "0.5472762", "0.5444171", "0.5438442", "0.5433061", "0.54289657", "0.5309941", "0.52570313", "0.52430487", "0.51972467", "0.51374495", "0.5074248", "0.504669", "0.5042355", "0.50096965", "0.49711755", "0.49697295", "0.4965388", "0.49529296", "0.49267206", "0.49164665", "0.49144346", "0.49102244", "0.49062178", "0.49001035", "0.4898689", "0.48974037", "0.48748797", "0.48697886", "0.48538896", "0.4853121", "0.48424274", "0.4831024", "0.48249832", "0.48249826", "0.48225513", "0.48178893", "0.48131236", "0.48124856", "0.48058623", "0.4792758", "0.47826228", "0.47616622", "0.47540775", "0.47481188", "0.47120512", "0.47116965", "0.47086167", "0.47027785", "0.4694369", "0.46930334", "0.4680759", "0.46734914", "0.46721232", "0.4665258", "0.46626535", "0.4655125", "0.4641157", "0.46388337", "0.46388337", "0.46388337", "0.46388337", "0.46384862", "0.46379057", "0.4636871", "0.46333084", "0.46331906", "0.46296462", "0.46218854", "0.4608083", "0.46006954", "0.45957947", "0.45765495", "0.4573781", "0.4571157", "0.45614445", "0.45553795", "0.45496717", "0.4539135", "0.45371917", "0.45358962", "0.45328057", "0.45326737", "0.4514005", "0.45096058", "0.4507389", "0.4500564", "0.4500564", "0.4500564", "0.4500564", "0.4500564", "0.44870305", "0.44868073", "0.4482966", "0.44781086" ]
0.6711866
0
Gets the instance of the toolkit interceptor composite, that holds all registered holders
public static synchronized IToolkitInterceptor getInstance() { return getCompositeHolder().getToolkitInterceptor(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "ServletRequestInjector getRequestInjector();", "ContainerSuppliedInterceptorFactory(PicoContainer pico, Object interceptorComponentKey) {\n this.pico = pico;\n this.interceptorComponentKey = interceptorComponentKey;\n }", "public interface InjectorWrapper {\n\tApplicationInjector getInjector();\n}", "protected List<Object> getInterceptors()\r\n/* 29: */ {\r\n/* 30:68 */ List<Object> interceptors = new ArrayList();\r\n/* 31:69 */ for (InterceptorRegistration registration : this.registrations) {\r\n/* 32:70 */ interceptors.add(registration.getInterceptor());\r\n/* 33: */ }\r\n/* 34:72 */ return interceptors;\r\n/* 35: */ }", "public static HeaderHolder getRequestHeaderHolder() {\n return requestHeaderHolder;\n }", "public static ViewParameters getInstance ()\r\n {\r\n return Holder.INSTANCE;\r\n }", "public static String getInterceptorKey() {\r\n\t\treturn InterceptorsChain.NAME;\r\n\t}", "protected final Injector getInjector() {\n return injector;\n }", "ResponseHandler getInstance() {\n \t\treturn this;\n \t}", "@Override\n\tpublic InvocationInstrumenter newInvocationInstrumenter() {\n\t\treturn AuthInfoContext.current()\n\t\t\t\t.map(LocalInstrumenter::new)\n\t\t\t\t.orElse(null);\n\t}", "@Override\r\n\tpublic void configInterceptor(Interceptors me) {\n\r\n\t}", "@Basic\r\n\tpublic Holder getDirectHolder(){\r\n\t\treturn holder;\r\n\t}", "CommonWrappingFactory getCommonWrappingFactory();", "public IBinder asBinder() {\n return this;\n }", "public IBinder asBinder() {\n return this;\n }", "public Entity getLeashHolder ( ) throws IllegalStateException {\n\t\treturn extract ( handle -> handle.getLeashHolder ( ) );\n\t}", "@Override\n\tpublic abstract RequestAttributeInspectorFactory getWrapped();", "@GinModules(InjectorModule.class)\npublic interface Injector extends Ginjector {\n PlaceHistoryHandler getPlaceHistoryHandler();\n MainView getAppWidget();\n}", "private static Injector instance() {\n if (instance == null) {\n instance = new Injector();\n }\n \n return instance;\n }", "interface Injector {\n void inject(InternalContext context, Object o);\n }", "private MultibinderFactory() { }", "public static RCProxy instance(){\n\t\treturn SingletonHolder.INSTANCE;\n\t}", "@Provides\n @Singleton\n OkHttpClient provideOkHttpClient() {\n final HttpLoggingInterceptor loggingInterceptor = new HttpLoggingInterceptor();\n loggingInterceptor.setLevel(HttpLoggingInterceptor.Level.BODY);\n\n OkHttpClient.Builder clientBuilder = new OkHttpClient.Builder()\n .addInterceptor(loggingInterceptor);\n\n return clientBuilder.build();\n }", "public interface IInterceptor {\n /* renamed from: a */\n void mo26940a(HttpRequest cVar, IResponse cVar2, ConcurrentBundle aVar);\n}", "public interface Interceptor extends Instance {\n\n /**\n * First available number which you can use to set interceptor priority order. Interceptor with\n * order value = 1000 will be execute first and so on. This is valid only for interceptors\n * implemented by application and not framework.\n */\n public static final int APPLICATION_PRIORITY = 1000;\n\n /**\n * Set interceptor priority order.\n *\n * @return Interceptor priority order.\n */\n int order();\n\n}", "@VisibleForTesting\n public ActivityManagerInternal injectActivityManagerInternal() {\n return (ActivityManagerInternal) LocalServices.getService(ActivityManagerInternal.class);\n }", "@Nullable\n protected abstract MethodInterceptor getInterceptor(Method method);", "private Injector() {\n }", "public static IControllerInfo getInstance() {\r\n\t\treturn instance;\r\n\t}", "public static <T> HolderConsumer<T> holder() {\n return new HolderConsumer<>();\n }", "@Singleton\n@Component(modules = {\n ApplicationModule.class,\n NetworkModule.class,\n StorageModule.class\n})\npublic interface ApplicationComponent {\n ActivityComponent plus(ActivityModule module);\n\n void inject(MyServiceInterceptor myServiceInterceptor);\n\n}", "private CloudStackApi getApi() {\n if (_eng == null) {\n _eng = new CloudStackApi(managementServer, cloudAPIPort, false);\n }\n // regardless of whether _eng is initialized, we must make sure\n // access/secret keys are current with what's in the UserCredentials\n _eng.setApiKey(UserContext.current().getAccessKey());\n _eng.setSecretKey(UserContext.current().getSecretKey());\n return _eng;\n }", "public InterceptorRegistration addInterceptor(HandlerInterceptor interceptor)\r\n/* 14: */ {\r\n/* 15:46 */ InterceptorRegistration registration = new InterceptorRegistration(interceptor);\r\n/* 16:47 */ this.registrations.add(registration);\r\n/* 17:48 */ return registration;\r\n/* 18: */ }", "private static HistoryImpl getImpl()\n {\n HistoryImpl impl = impls.get(Context.getCurrentContext());\n if (impl == null)\n {\n impls.put(Context.getCurrentContext(), impl = new HistoryImpl());\n Context.getCurrentContext().getClient().addListener(new GwtJavaClientListener()\n {\n @Override\n public void onFinish(GwtJavaClient client)\n {\n impls.remove(Context.getCurrentContext());\n }\n\n });\n }\n return impl;\n }", "public AuthenticationInterceptor() {\r\n super(Phase.RECEIVE);\r\n }", "public Container getContainer();", "public MyCustomInterceptor(UtilisateurDAO userDAO){\r\n this.userDAO = userDAO ;\r\n }", "public Object getService() {\n return service;\n }", "@Provides\n @Singleton\n public OkHttpClient providesOkHttpClient() {\n HttpLoggingInterceptor interceptor = new HttpLoggingInterceptor();\n interceptor.setLevel(HttpLoggingInterceptor.Level.BODY);\n\n OkHttpClient.Builder httpClient = new OkHttpClient.Builder();\n httpClient.addInterceptor(interceptor);\n\n return httpClient.build();\n\n }", "IAnjaroController getController();", "public static OOCSISender getInstance() {return OOCSIholder;}", "public static Singleton instance() {\n return Holder.instance;\n }", "protected Injector() {\n }", "public BeanDefinitionHolder getDecoratedDefinition()\n/* */ {\n/* 221 */ return this.decoratedDefinition;\n/* */ }", "public BaseHttpXCapClient()\n {\n ServiceReference guiVerifyReference\n = SipActivator.getBundleContext().getServiceReference(\n CertificateService.class.getName());\n\n if(guiVerifyReference != null)\n certificateVerification\n = (CertificateService)SipActivator.getBundleContext()\n .getService(guiVerifyReference);\n }", "private InjectorManager() {\n // no prepared injectors\n }", "public static Controller getInstance() { return INSTANCE; }", "public Climber(){\n\t\tinst = this;\n\t}", "private StateHolder getStateHolder() {\n return stateHolder;\n }", "@Provides\n OkHttpClient.Builder providesOkHttpClientBuilder(){\n return new OkHttpClient.Builder()\n .connectTimeout(10, TimeUnit.SECONDS)\n .writeTimeout(20,TimeUnit.SECONDS)\n .readTimeout(20,TimeUnit.SECONDS);\n //.addInterceptor(new MyInterceptor());\n }", "public PortletRequestDispatcher getWrapped() {\n return wrapped;\n }", "private ContainerElementAccessor() {\n }", "@GinModules(MyAppGinModule.class)\npublic interface MyAppGinjector extends Ginjector {\n\n String ANNOTATED_STRING_VALUE = \"abc\";\n\n MyApp getMyApp();\n\n SimpleObject getSimple();\n\n MyService getMyService();\n\n MyServiceImpl getMyServiceImpl();\n\n MyProvided getMyProvided();\n\n @Named(\"blue\") SimpleObject getSimpleBlue();\n @Named(\"red\") SimpleObject getSimpleRed();\n\n EagerObject getEagerObject();\n\n // Providers we never bound explicitly -- they should be synthesized\n // since we bound the keys directly\n Provider<SimpleObject> getSimpleProvider();\n @Named(\"blue\") Provider<SimpleObject> getSimpleBlueProvider();\n\n @MyBindingAnnotation String getAnnotatedString();\n\n MyRemoteServiceAsync getMyRemoteServiceAsync();\n}", "private static class <init>\n implements ScopedBindingBuilder\n{\n\n public void asEagerSingleton()\n {\n }", "@Singleton\n@Component(modules = { AppModule.class, NetModule.class })\npublic interface NetComponent {\n void inject(MainHandler handler);\n}", "public interface MessageServiceInjector {\n public Consumer getConsumer() ;\n}", "public static JWTLoginModuleDataHolder getInstance() {\n return instance;\n }", "private Service getService() {\n return service;\n }", "public static IClient clientAccessor() {\n return Application.getGame().getClientAccessor();\n }", "public InjectingComponentType() {\n }", "public static MakeServiceProvidingRequestController getInstance() {\n return new MakeServiceProvidingRequestController();\n }", "public Interceptor create(Proxy proxy) throws NullPointerException {\n MethodInterceptor methodInterceptor = (MethodInterceptor) pico.getComponentInstance(interceptorComponentKey);\n if (methodInterceptor == null) {\n throw new NullPointerException(\"Interceptor with component key \" + interceptorComponentKey\n + \" + not found in PicoContainer\");\n }\n return new MethodInterceptorAdapter(methodInterceptor);\n }", "@Singleton\n@Component(modules = {AppModule.class})\npublic interface AppComponent {\n Context getContext();\n CommonUtil getComminUtil();\n}", "public Object getBean(Object obj, Interceptor interceptor) {\n return ProxyBeanUtil.getBean(obj, interceptor);\n }", "@PresenterScope\n@Component(modules = ApiServiceModule.class)\npublic interface PresenterComponent {\n\n BasePresenter inject(BasePresenter presenter);\n\n OkHttpClient getOkhttpClient();\n\n Retrofit getRetrofit();\n\n}", "public RequestUrlHandler() {\n // requestService = SpringContextHolder.getBean(ScfRequestService.class);\n }", "public IController getController();", "private static VbxService getApiInstance() {\n HttpLoggingInterceptor logger = new HttpLoggingInterceptor();\n logger.setLevel(HttpLoggingInterceptor.Level.BODY);\n\n Interceptor setAcceptType = new Interceptor() {\n @Override\n public Response intercept(Chain chain) throws IOException {\n Request request = chain.request();\n Request typedRequest = request\n .newBuilder()\n .header(\"Accept\", \"application/json\")\n .build();\n return chain.proceed(typedRequest);\n }\n };\n\n Interceptor setAuthorization = new Interceptor() {\n @Override\n public Response intercept(Chain chain) throws IOException {\n Request request = chain.request();\n if(email != null && password != null) {\n String auth = Base64.encodeToString((email + \":\" + password).getBytes(), Base64.NO_WRAP);\n Request typedRequest = request\n .newBuilder()\n .header(\"Authorization\", String.format(\"Basic %s\", auth))\n .build();\n return chain.proceed(typedRequest);\n }\n return chain.proceed(request);\n }\n };\n\n OkHttpClient apiClient = new OkHttpClient.Builder()\n .addInterceptor(logger)\n .addInterceptor(setAcceptType)\n .addInterceptor(setAuthorization)\n .build();\n\n return new Retrofit.Builder()\n .baseUrl(endpoint)\n .client(apiClient)\n .addCallAdapterFactory(RxJavaCallAdapterFactory.create())\n .addConverterFactory(GsonConverterFactory.create())\n .build()\n .create(VbxService.class);\n }", "public Service getService() {\n\t\treturn this;\n\t}", "private SOSCommunicationHandler getClient() {\r\n\t\treturn client;\r\n\t}", "public static RockboxWidgetProvider getInstance()\n {\n return mInstance;\n }", "protected OAuthProvider getOAuthProvider() {\r\n \tOAuthProvider provider = new CommonsHttpOAuthProvider(MendeleyApiUrls.OAuthUrls.REQUEST_TOKEN_URL,\r\n \t\t\tMendeleyApiUrls.OAuthUrls.ACCESS_TOKEN_URL, MendeleyApiUrls.OAuthUrls.AUTHORIZE_URL);\r\n \t\r\n \tprovider.setOAuth10a(true);\r\n// for (String headerName : requestHeaders.keySet()) {\r\n// \tprovider.setRequestHeader(headerName, requestHeaders.get(headerName));\r\n// }\r\n \t\r\n \treturn provider;\r\n\t}", "public static ColorPaletteBuilder getInstance()\n {\n return SingletonHolder.instance;\n }", "@Singleton\n@Component(modules = {AppModule.class, AppClientModule.class})\npublic interface AppComponent {\n Application getApplication();\n MainViewInteraction getWeatherInteractor();\n}", "public static OI getInstance() {\n\t\treturn INSTANCE;\n\t}", "@Singleton\n@Component(modules = {ContextModule.class, BusModule.class, GithubModule.class, GankModule.class, ZhiHuModule.class, RssModule.class})\npublic interface AppComponent {\n Context getContext();\n GankService getGankService();\n ZhiHuService getZhiHuService();\n RssService getRssService();\n EventBus getBus();\n}", "public static com.tangosol.coherence.Component get_Instance()\n {\n return new com.tangosol.coherence.component.util.collections.WrapperMap();\n }", "MyService getService() {\n return MyService.this;\n }", "public Holder getHolder() {\r\n\t\tif(!holder.isSupremeHolder())\r\n\t\t\treturn ((Item)holder).getHolder();\r\n\t\telse return holder;\r\n\t}", "public Set<PhysicalInterceptor> getInterceptors() {\n return interceptors;\n }", "public BotInteractionManager getBotInteractionsManager(){\n return botInteractionManager;\n }", "public Service getCompositeService()\n\t{\n\t\treturn compositeService;\n\t}", "public final ObjectProperty<Predicate<? extends Event>> interceptorProperty()\n {\n return myInterceptorProperty;\n }", "private static Session getInstance() {\n return SingletonHolder.INSTANCE;\n }", "public interface Interceptor {\n public void intercept(ActionInvocation invocation);\n}", "public Object getTarget() throws InvalidBinderUsageException {\n\t\treturn this.lastBeanWrapper;\n\t}", "public DelegateCredentialsProvider build() {\n return new DelegateCredentialsProvider(this);\n }", "private static OkHttpClient getOkHttpClient() {\n OkHttpClient.Builder okHttpClientBuilder = new OkHttpClient.Builder()\n .addInterceptor(new Interceptor() {\n @Override\n public Response intercept(Chain chain) throws IOException {\n Request original = chain.request();\n\n Request.Builder requestBuilder = original.newBuilder()\n .method(original.method(), original.body());\n\n addAdditionalHttpHeaders(requestBuilder);\n addParleyHttpHeaders(requestBuilder);\n\n Request request = requestBuilder.build();\n return chain.proceed(request);\n }\n })\n .connectTimeout(30, TimeUnit.SECONDS)\n .readTimeout(30, TimeUnit.SECONDS)\n .writeTimeout(30, TimeUnit.SECONDS);\n\n applySslPinning(okHttpClientBuilder);\n\n return okHttpClientBuilder.build();\n }", "Handler getHandler() {\n return getEcologyLooper().getHandler();\n }", "private AddHarnessIdInterceptor() {}", "public Container getContainer() {\r\n return container;\r\n }", "@Override\n protected Injector getInjector() {\n return Guice.createInjector(new PortalServletModule());\n }", "Builder injectionFactory(InjectionObjectFactory factory);", "@Singleton\n@Component(modules = {ApiModule.class, CarWashCardModule.class})\npublic interface CarWashCardComponent {\n void Inject(CarWashCardFrgm carWashCardFrgm);\n void Inject(CardBagAct cardBagAct);\n}", "public OAuth2Manager get() {\n OAuth2Manager a = this.f30636a.mo34992a((C11818g) this.f30637b.get(), (C11766a) this.f30638c.get(), (C13325v) this.f30639d.get(), (C11125d) this.f30640e.get(), C12020b.m31668a(this.f30641f), (C11791e) this.f30642g.get(), C12020b.m31668a(this.f30643h));\n C12021c.m31671a(a, \"Cannot return null from a non-@Nullable @Provides method\");\n return a;\n }", "private IBinder getActivityToken() {\n\t\tIBinder binder = null;\n\n\t\ttry {\n\t\t\t//Class clazz = Class.forName(\"com.qiyi.framework.surfacetransferservice.MainActivity\");\n\t\t\t//Field token = clazz.getField(\"mToken\");\n\t\t\tClass clazz = Class.forName(\"android.app.Activity\");\n\t\t\tif(MainActivity.this == null) {\n\t\t\t\tLog.d(TAG, \"ACTIVITY IS NULL!!!\");\n\t\t\t}\n\t\t\t//Class clazz = activity.getClass();\n\t\t\tField token = clazz.getDeclaredField(\"mToken\");\n\t\t\tif (token == null) return null;\n\t\t\t//mToken is private field.\n\t\t\ttoken.setAccessible(true);\n\t\t\tIBinder msg = (IBinder)token.get(MainActivity.this);\n\t\t\tbinder = msg;\n\t\t\tLog.e(TAG, \"aaaaa ====\" + msg.toString());\n\t\t} catch (ClassNotFoundException e) {\n\t\t\te.printStackTrace();\n\t\t} catch (NoSuchFieldException e) {\n\t\t\te.printStackTrace();\n\t\t} catch (IllegalAccessException e) {\n\t\t\te.printStackTrace();\n\t\t}\n\t\treturn binder;\n\t}", "@Singleton @Component(modules = {ApplicationModule.class, ApiModule.class})\npublic interface ApplicationComponent {\n Context getContext();\n Bus getBus();\n TRApi getTRApi();\n\n void inject(ZhihuApplication zhihuApplication);\n\n void inject(BaseNewActivity baseNewActivity);\n}", "private Context getThreadContext() throws NamingException {\n final ThreadContext threadContext = ThreadContext.getThreadContext();\n if (skipEjbContext(threadContext)) {\n return ContextBindings.getClassLoader();\n }\n final Context context = threadContext.getBeanContext().getJndiEnc();\n return context;\n }", "private static interface Holder\r\n {\r\n //~ Static fields/initializers -----------------------------------------\r\n\r\n public static final ViewParameters INSTANCE = new ViewParameters();\r\n\r\n }", "public final Predicate<? extends Event> getInterceptor()\n {\n return myInterceptorProperty.get();\n }" ]
[ "0.5398555", "0.53266543", "0.51928914", "0.51848924", "0.5015707", "0.49995506", "0.49906325", "0.49597237", "0.48900184", "0.48830384", "0.48773137", "0.48294407", "0.4792745", "0.4782768", "0.4782768", "0.47763175", "0.47695696", "0.475534", "0.47492602", "0.472012", "0.4697539", "0.46941328", "0.46829432", "0.4682935", "0.46820846", "0.46600607", "0.4654367", "0.4646147", "0.46423545", "0.46402505", "0.4640204", "0.46376857", "0.46360067", "0.46340275", "0.46046856", "0.45922336", "0.45883644", "0.45874238", "0.45776388", "0.45724925", "0.45242012", "0.45120957", "0.45094672", "0.45092702", "0.4504787", "0.44972944", "0.44932535", "0.44842958", "0.4477284", "0.4477204", "0.44718793", "0.44647256", "0.4458088", "0.44508097", "0.4450786", "0.44479567", "0.44429907", "0.44399709", "0.44332728", "0.44307747", "0.44306612", "0.44046703", "0.43997982", "0.43986446", "0.43972492", "0.43964148", "0.43928263", "0.43916386", "0.43800172", "0.43796983", "0.43777552", "0.4374712", "0.43737823", "0.43685433", "0.43673345", "0.43626595", "0.43607023", "0.43599537", "0.43437955", "0.43338323", "0.43316028", "0.4325035", "0.43236384", "0.4321168", "0.43111083", "0.43094447", "0.43093342", "0.4306006", "0.43013835", "0.4298475", "0.42970344", "0.42966494", "0.429551", "0.42927554", "0.42922738", "0.42905855", "0.42904726", "0.42840403", "0.42830682", "0.42809623" ]
0.73254275
0
String s = "aa"; String p = "a";
public static void main(String[] args) { String s = "adceb"; String p = "*a*b"; // String s = ""; // String p = "**"; Solution sln = new Solution(); System.out.println(sln.isMatch(s, p)); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public static void main(String[] args) {\n String s = \"aaa\";\n String b = new String(\"aaa\");\n System.out.println(b==\"aaa\");\n\n }", "public static void main(String[] args) {\nString s1= \"adya\";\nString s2= \"adyass\"+\"a\";\nString s3= \"adyassa\";\nSystem.out.println(s3==s2);\n\t}", "public static void main(String[] args) {\nString s = \"hello world\";\n\t\t\n\t\tint a = 100;\n\t\tint b = 200;\n\t\t\n\t\tSystem.out.println(a+b);\n\t\t\n\t\tSystem.out.println(a+s);\n\t\t\n\t\tSystem.out.println(a+b+s);\n\t\t\n\t\tSystem.out.println(s+a+b);\n\t\t\n\t\tSystem.out.println(s+(a+b));\n\t\t\n\t\tString p = \"Test\";\n\t\tString q = \"Automation\";\n\t\t\n\t\tSystem.out.println(p+q);\n\t\tSystem.out.println(p+\" \"+q);\n\t\t\n\t\t//ASCII\n\t\tchar c1 = 'a';//97\n\t\tchar c2 = 'b';//98\n\t\t\n\t\tSystem.out.println(c1+c2);//195\n\t\t//a-z --> 97 - 122\n\t\t//A-Z --> 65 - 90\n\t\t//0-9 --> 48 - 57\n\n\t}", "String mo3176a(String str, String str2);", "void mo131986a(String str, String str2);", "void mo1886a(String str, String str2);", "void mo12635a(String str);", "void mo37759a(String str);", "int mo54403a(String str, String str2);", "void mo3768a(String str);", "abstract String mo1747a(String str);", "int mo23347d(String str, String str2);", "int mo23349e(String str, String str2);", "int mo23353w(String str, String str2);", "void mo1791a(String str);", "void mo88522a(String str);", "String mo2801a(String str);", "public static void main(String[] args) {\n\t\tString s1 =\"Yashodhar\";//String by java string literal\r\n\t\tchar ch[] ={'y','a','s','h','o','d','h','a','r','.','s'};\r\n\t\tString s3 = new String(ch);//Creating java to string\r\n\t\tString s2= new String(\"Yash\");//creating java string by new keyword \r\n\t\tSystem.out.println(s1);\r\n\t\tSystem.out.println(s2);\r\n\t\tSystem.out.println(s3);\r\n\t\t\r\n\t\t//Immutable String in Java(Can not changed)\r\n\t\tString s4= \"YASHODSHR\";\r\n\t\ts4 =s4.concat( \"Suvarna\");\r\n\t\tSystem.out.println(\"Immutable Strin=== \"+s4);\r\n\t\t\r\n\t\t//Compare two Strings using equals\r\n\t\tString s5= \"Yash\";\t\t\r\n\t\tString s6= \"YASH\";\r\n\t\tSystem.out.println(\"Campare equal \"+s5.equals(s6));\r\n\t\tSystem.out.println(s5.equalsIgnoreCase(s6));\r\n\t\t\r\n\t\t\t\r\n\t\t String s7=\"Sachin\"; \r\n\t\t String s8=\"Sachin\"; \r\n\t\t String s9=new String(\"Sachin\"); \r\n\t\t System.out.println(s7==s8); \r\n\t\t System.out.println(s7==s9);\r\n\t\t \r\n\t\t String s10 = \"YAsh\";\r\n\t\t String s11 = \"Yash\";\r\n\t\t String s12 = new String(\"yash\");\r\n\t\t System.out.println(s10.compareTo(s11));\r\n\t\t System.out.println(s11.compareTo(s12));\r\n\t\t \r\n\t\t //SubStrings\t\t \r\n\t\t String s13=\"SachinTendulkar\"; \r\n\t\t System.out.println(s13.substring(6));\r\n\t\t System.out.println(s13.substring(0,3));\r\n\t\t \r\n\t\t System.out.println(s10.toLowerCase());\r\n\t\t System.out.println(s10.toUpperCase());\r\n\t\t System.out.println(s10.trim());//remove white space\r\n\t\t System.out.println(s7.startsWith(\"Sa\"));\r\n\t\t System.out.println(s7.endsWith(\"n\"));\r\n\t\t System.out.println(s7.charAt(4));\r\n\t\t System.out.println(s7.length());\r\n\r\n\r\n\t\t String Sreplace = s10.replace(\"Y\",\"A\");\r\n\t\t System.out.println(Sreplace);\r\n\t\t \r\n\t\t System.out.print(\"String Buffer\");\r\n\t\t StringBuffer sb = new StringBuffer(\"Hello\");\r\n\t\t sb.append(\"JavaTpoint\");\r\n\t\t sb.insert(1,\"JavaTpoint\");\r\n\t\t sb.replace(1, 5, \"JavaTpoint\");\r\n\t\t sb.delete(1, 3);\r\n\t\t sb.reverse();\r\n\t\t System.out.println(\" \"+sb);\r\n\t\t \r\n\t\t String t1 = \"Wexos Informatica Bangalore\";\r\n\t\t System.out.println(t1.contains(\"Informatica\"));\r\n\t\t System.out.println(t1.contains(\"Wexos\"));\r\n\t\t System.out.println(t1.contains(\"wexos\"));\r\n\t\t \r\n\t\t \r\n\t\t String name = \"Yashodhar\";\r\n\t\t String sf1 = String.format(name);\r\n\t\t String sf2= String .format(\"Value of %f\", 334.4);\r\n\t\t String sf3 = String.format(\"Value of % 43.6f\", 333.33);\r\n\t\t \t\t\t \r\n\t\t \r\n\t\t System.out.println(sf1);\r\n\t\t System.out.println(sf2);\r\n\t\t System.out.println(sf3);\r\n\t\t \r\n\t\t String m1 = \"ABCDEF\";\r\n\t\t byte[] brr = m1.getBytes();\r\n\t\t for(int i=1;i<brr.length;i++)\r\n\t\t {\r\n\t\t System.out.println(brr[i]);\r\n\t\t }\r\n\t\t \r\n\t\t String s16 = \"\";\r\n\t\t System.out.println(s16.isEmpty());\r\n\t\t System.out.println(m1.isEmpty());\r\n\t\t \r\n\t\t String s17 =String.join(\"Welcome \", \"To\",\"Wexos Infomatica\");\r\n\t\tSystem.out.println(s17);\r\n\t\t \r\n \r\n\t}", "void mo1329d(String str, String str2);", "public static void main(String[] args )\r\n\t{\n\t\tlong t=322342432;\r\n\t\tString p=\"welcome\";\r\n\t\tString q=\"home\";\r\n\t\tint r=5;\r\n\t\tint s=9;\r\n\r\n\t\tSystem.out.println(p+q);\r\n\t\tSystem.out.println(r+s);\r\n\t\tSystem.out.println(p+q+r);\r\n\t\tSystem.out.println(p+q+r+s);//left to right\r\n\t\tSystem.out.println(p+q+(r+s));\r\n\r\n\t\tString a= \"javatrainingTesting \";\r\n\t\t//charAt(index), contains(char seq),concat(string),contentEquals(StringBuffer/StringBuilder),EqualsIgnoreCase(String),indexOf(),\r\n\t\t//lastIndexOf(), length(),startsWith(String),endswith(String), replace(),subString(),toUpperCAse(),toLowerAcse(),trim().\r\n\t\t//st.contentEquals(StringBuffer/StringBuilder)---> to compare String with StringBuilder or String buffer\r\n\t\t//st.equals(char seq..)---> to compare String with String or String Object\r\n\t\t// equals method is also present in Object class which compares references not content. Equals method in string class overrides this to compare content\r\n\r\n\t\tSystem.out.println(a.charAt(2));\r\n\t\tSystem.out.println(a.indexOf(\"a\"));\r\n\t\tSystem.out.println(a.substring(3, 6));\r\n\t\tSystem.out.println(a.substring(5));\r\n\t\tSystem.out.println(a.concat(\"rahul teaches\"));\r\n\t\tSystem.out.println(a.replace(\"in\", \"\"));//replace in with no character(delete)\r\n\t\t\r\n\t\tSystem.out.println(a.trim());\r\n\t\tSystem.out.println(a.toUpperCase());\r\n\t\tSystem.out.println(a.toLowerCase());\r\n\t\t//split\r\n\t\tString []arr =a.split(\"t\");\r\n\t\tSystem.out.println(arr[0]);\r\n\t\tSystem.out.println(arr[1]);\r\n\t\tSystem.out.println(arr[2]);\r\n\t\tSystem.out.println(a.replace(\"t\", \"s\"));\r\n\r\n\t\t//concept: final keyword---->is used to put restriction\r\n\t\t//final variable is constant.It can't be changed again\r\n\t\t//final class can't be inherited by child class(can't be extended)\r\n\t\t//final method can't be overriden by method in child class.\r\n\r\n\t\t//There are few inbuilt packages in java like--java, lang, awt, javax, swing, net, io, util, sql etc.\r\n\t\t//java.lang is inbuilt package ..thats why we can directly use commands like system.out.println, String class etc without any import.\r\n\t\t//java/Util package--all Collection classes and other classes come from this package but we need to import it.\r\n\r\n\t\t/*access modifiers:---for variables and methods\r\n\t public--access through out project in all packages, sub packages\r\n\t protected--access in same package and sub classes of different packages also.\r\n\t Default--access only in same package\r\n\t private--access only inside same class\r\n\t protected = default + subclass of other packages(using extends)\r\n\t public= protected + Other packages\r\n\r\n\t\t */\r\n\r\n\t}", "public abstract void mo57435a(String str, String str2, C12855p pVar);", "void mo1331e(String str, String str2);", "void mo13161c(String str, String str2);", "void mo9697a(String str);", "int mo23352v(String str, String str2);", "public void pl(String s) { System.out.println(s); }", "public static void main(String[] args) {\n\t\tString s =\"abc\";\n\t\tString s1 = new String(\"abc\");\n\t\tString s3 = new String(\"abc\");\n\t\tString s2 = \"abc\";\nif(s1.equals(s3))\n\t\t\tSystem.out.println(\"true\");\n\t\telse\n\t\t\tSystem.out.println(\"false\");\n\t}", "public static void p(String s)\n\t{\n\t\tSystem.out.println(s);\n\t}", "void mo5871a(String str);", "public static void main( String[] args )\n {\n String a = new String(\"as\");\n String b = \"as\";\n System.out.println(a == \"as\");\n System.out.println(b == \"as\");\n\n }", "public void p(String s) {\n\t\tSystem.out.println(\"\" + s);\n\t}", "int mo23351i(String str, String str2);", "void mo1342w(String str, String str2);", "void mo87a(String str);", "void mo41089d(String str);", "@Test\r\n public void test8() {\r\n String s1 = \"Abc\";\r\n String s2 = \"abc\";\r\n String s3 = \"Abcd\";\r\n System.out.println(s1.compareTo(s2));\r\n System.out.println(s1.compareTo(s3));\r\n }", "void mo1932a(String str);", "public abstract void mo57437b(String str, String str2, C12855p pVar);", "public static void main(String[] args) {\n\t\tString s1 = \"My name is manish\";\n\t\t//By new keyword\n\t\tString s2 = new String(\"My name is manish\");\n\t\t//System.out.println(s1.equals(s2)); //compare values\n\t\t//System.out.println(s1==(s2));// compare references not value\n\t\t\n\t\t//Java String toUpperCase() and toLowerCase() method\n\t\tString s = \"SacHin\";\n\t\t//System.out.println(s.toUpperCase());\n\t\t//System.out.println(s.toLowerCase());\n\t\t\n\t\t//string trim() method eliminates white spaces before and after string\n\t\tString s3= \" String \";\n\t\t//System.out.println(s3.trim());\n\t\t\n\t\t//string charAt() method returns a character at specified index\n\t\tString s4 = \"Manish\";\n\t\t//System.out.println(s4.charAt(4));\n\t\t\n\t\t//string length() method returns length of the string\n\t\tString a = \"manish\";\n\t\tString a1 = \"My name is manish\";\n\t\t//System.out.println(a.length());\n\t\t//System.out.println(a1.length());\n\t\t\n\t\t//string valueOf() method coverts given type such as int, long, float, double, boolean, char and char array into string.\n\t\tint i = 23;\n\t\tchar [] ch = {'a','b','c','d'};\n\t\tString s5 = String.valueOf(i);\n\t\tString c = String.valueOf(ch);\n\t\t//System.out.println(s5+10);\n\t\t//System.out.println(s5.length());\n\t\t//System.out.println(c+10);\n\t\t//System.out.println(c.length());\n\t\t\n\t\t//string replace() method replaces all occurrence of first sequence of character with second sequence of character.\n\t\tString s6 = \"java is programming Language, java is oops language, java is easy language\";\n\t\t//String replaceString = s6.replace(\"java\",\"kava\");\n\t\t//System.out.println(replaceString);\n\t\t\n\t\t//string concat() method combines specified string at the end of this string\n\t\tString s7 = \"ram goes to home, \";\n\t\tString s8 = \"he also goes to school\";\n\t\t//System.out.println(s7.concat(s8));\n\t\t//System.out.println(s7+s8);\n\t\t\n\t\t/*\n\t\t * //string split() method splits this string against given regular expression\n\t\t * and returns a char array String s9 =\n\t\t * \"java string split method by javatpoint\"; String [] spParts = s9.split(\" \");\n\t\t * //String [] s10Parts = s9.split(\" \",4); for(int i=) {\n\t\t * System.out.print(str+\",\"); }\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\n\t}", "void mo85415a(String str);", "public static void main(String[] args) {\n\t\t\n\t\tString s1 = \"rohith\";\n\t\tchar ch[] = {'r','o','h','i','t','h'};\n\t\tString s2 = new String(ch);\n\t\tString s3 = new String(\"rohith\");\n\n\t\tSystem.out.println(s1);\n\t\tSystem.out.println(s2);\n\t\tSystem.out.println(s3);\n\t\t\n\t}", "public static void main(String[] args) {\n\t\tString s = new String(\"abc\");\r\n\t\tSystem.out.println(s.hashCode());\r\n\t\tCharacter a = 'a';\r\n\t\tCharacter b = 'b';\r\n\t\tCharacter c = 'c';\r\n\t\tint i = a;\r\n\t\tSystem.out.println(i);\r\n\t\tSystem.out.println(new Integer(b));\r\n\t\tSystem.out.println(new Integer(c));\r\n\t\tSystem.out.println(97*31*31 + 98*31 + 99);\r\n\t\t\r\n\t\tSystem.out.println(\"---------------------------\");\r\n\t\t\r\n\t\tString s3=s1+s2;\r\n\t\tString s4=\"abcdef\";\r\n\t\tSystem.out.println(s3==s4);\r\n\t\t\r\n\t\tSystem.out.println(\"---------------------------\");\r\n\t\t\r\n\t\tString sa = \"a\";\r\n\t\tString sb = \"b\";\r\n\t\tsb = sa + sb;\r\n\t\tString ab = \"a\" + \"b\";\r\n\t\tString ss = \"ab\";\r\n\t\tSystem.out.println(ab == sb);\r\n\t\tSystem.out.println(ab == ss);\r\n\t\t\r\n\t\tSystem.out.println(String.class.getSimpleName());\r\n\t\t\r\n\t\tString k0=\"kvill\";\r\n\t\tString k1=\"kvill\";\r\n\t\tString k2=\"kv\" + \"ill\";\r\n\t\tSystem.out.println( k0==k1 );\r\n\t\tSystem.out.println( k0==k2 );\r\n\t\t\r\n\t}", "public static String b(String paramString)\r\n/* 690: */ {\r\n/* 691:682 */ String str = \"\";\r\n/* 692:683 */ int i1 = -1;\r\n/* 693:684 */ int i2 = paramString.length();\r\n/* 694:686 */ while ((i1 = paramString.indexOf('§', i1 + 1)) != -1) {\r\n/* 695:687 */ if (i1 < i2 - 1)\r\n/* 696: */ {\r\n/* 697:688 */ char c1 = paramString.charAt(i1 + 1);\r\n/* 698:690 */ if (c(c1)) {\r\n/* 699:691 */ str = \"§\" + c1;\r\n/* 700:692 */ } else if (d(c1)) {\r\n/* 701:693 */ str = str + \"§\" + c1;\r\n/* 702: */ }\r\n/* 703: */ }\r\n/* 704: */ }\r\n/* 705:698 */ return str;\r\n/* 706: */ }", "static String Initialize(String s){\n s=\"Hello World\";\n return s;\n }", "static public String generateAString(String s) {\n String result;\n result = generate(s);\n if (result != null) {\n currentString = result;\n }\n return result;\n }", "public static void main(String args[]) {\r\n\t\r\n\tString x=new String(\"kajol\");\r\n\tx.concat(\"kk\");\r\n\tSystem.out.println(x);\r\n\tString z=new String(\"kedia\");\r\n\tz=z.concat(\"k\");\r\n\tSystem.out.println(z);\r\n}", "public static String lcp(String s, String t) {\n int n = Math.min(s.length(), t.length());\n for (int i = 0; i < n; i++) {\n if (s.charAt(i) != t.charAt(i))\n return s.substring(0, i);\n }\n return s.substring(0, n);\n }", "@Test\n\tpublic void prototype() {\n\t\tassertEquals(parseString().parse(\"abc\").toString(), \"abc\");\n\t\tassertEquals(parseString().parse(\"asDSD2_ff\").toString(), \"asDSD2_ff\");\n\n\t}", "public abstract void mo70711a(String str, String str2);", "public static void main(String[] args) {\n\t\t\n\t\tString s1 = \"Welcome\";\n\t String s2 = \"To this world\";\n\t String s3 = \"Welcome\";\n\t \n\t System.out.println(s1.length()); //length()\n\t System.out.println(s1.concat(s2)); //concat ()\n\t System.out.println(s1.equals(s2)); // equals()\n\t System.out.println(s1.equals(s3)); // equals()\n\t System.out.println(s1.equalsIgnoreCase(s2)); // equalsIgnoreCase()\n\t System.out.println(s1.contains(\"Wel\"));\n\t System.out.println(s1.replace(\"Wel\",\"Babu\"));\n\t System.out.println(s1.subSequence(2, 5));\n\t \n\n\t}", "int go(String s) {\n\t\treturn 0;\n\t}", "void mo1340v(String str, String str2);", "@Before\n public void createString(){\n s1 = \"casa\";\n\ts2 = \"cassa\";\n\ts3 = \"\";\n\ts4 = \"casa\";\n }", "public static void main(String[] args) {\n\n String s = \"2222\";\n String a = \"www\";\n// a.replace()\n\n s = a;\n System.out.println(s);\n }", "void mo1935c(String str);", "public static void main (String[] args) {\n\t\tString s = \"Hello\";\r\n\t\tString t = new String(s);\r\n\t\tif(\"Hello\".equals(s)) System.out.println(\"one\");\r\n\t\tif(t== s) System.out.println(\"two\");\r\n\t\tif (t.equals(s))System.out.println(\"three\");\r\n\t\tif(\"Hello\" == s) System.out.println(\"four\");\r\n\t\tif(\"Hello\" == t) System.out.println(\"five\");\r\n\t\tStringBuilder sb = new StringBuilder();\r\n\t\tsb.append(\"aaa\").insert(1,\"bb\").insert(4, \"ccc\");\r\n\t\tSystem.out.println(sb);\r\n\t\tString s1 =\"java\";\r\n\t\tStringBuilder s2 = new StringBuilder(\"java\");\r\n\t\tif (s1 == s2)\r\n\t\t\tSystem.out.print(\"1\");\r\n\t\tif (s1.contentEquals(s2))\r\n\t\t\tSystem.out.print(\"2\");\r\n\t\t\r\n\t}", "void mo1334i(String str, String str2);", "public static void main (String[] args) throws java.lang.Exception\n\t{\n\t\tString s0=\"\";\n\t\tString s1=\"HELLO\";\n\t\tString s2=new String(\"how are you\");\n\t\tSystem.out.println(s1.length());\n\t\tSystem.out.println(s1.compareTo(s2));\n\t\tSystem.out.println(s1.concat(s2));\n\t\tSystem.out.println(s0.isEmpty());\n\t\tSystem.out.println(s1.toLowerCase());\n\t\tSystem.out.println(s2.toUpperCase());\n\t\tSystem.out.println(s1.replace(\"HELLO\",\"Sarava\"));\n\t\tSystem.out.println(s2.contains(\"are\"));\n\t System.out.println(s2.endsWith(\"you\"));\n\t\t\n\t\t\n\t\t\n\t}", "java.lang.String getS1();", "public static void main(String[] args) {\n\t\tString s=\"abc\";\n\t\ts=s.concat(\"defg\");\n\t\ts.concat(\"ghi\");\n\t\tString s1=s,s2=s,s3=s,s4=s,s5=s;\n\t\tSystem.out.println(s);\n\t\tSystem.out.println(s1);\n\t\tSystem.out.println(s2);\n\t\tSystem.out.println(s3);\n\t\tSystem.out.println(s3);\n\t\tSystem.out.println(s4);\n\t\tSystem.out.println(s5);\n\t\t\n\t\t\n\t\tStringBuffer sb= new StringBuffer(\"abc\");\n\t\tsb.append(\"ABC\");\n\t\tStringBuffer sb1=sb,sb2=sb;\n\t\tSystem.out.println(sb);\n\t\tSystem.out.println(sb1);\n\t\tSystem.out.println(sb2);\n\t\t\n\t}", "@Test\n\tpublic void eg1() {\n\t\tString s=\"babad\";\n\t\tSystem.out.println(longestPalindromicSubString(s));\n\t\t\n\t}", "public boolean isMatch(String s, String p) {\n mem= new int[s.length()+1][p.length()+1];\n return match(s,p);\n }", "public static void main(String[] args) {\n\n\t\t\n\t\tString s =\"Soni Shirwani\";\n\t\t\n\t\tSystem.out.println(s.charAt(3));\n\t\t\n\t\tString s1=\"Soni\",s2=\"Soni\";\n\t\t\n\t\tSystem.out.println(s1.equals(s2));\n\t\t\n\t\tString empty=\"\";\n\t\t\n\t\tSystem.out.println(empty.isEmpty());\n\t\t\n\t\tSystem.out.println(s.length());\n\t\t\n\t\tSystem.out.println(s.replace(\"i\", \"y\"));\n\t\t\n\t\tSystem.out.println(s.substring(5));\n\t\tSystem.out.println(s.substring(3,8));\n\t\t\n\t\tSystem.out.println(s.indexOf('n'));\n\t\t\n\t\tSystem.out.println(s.lastIndexOf('n'));\n\t\t\n\t\tSystem.out.println(s.toUpperCase());\n\t\t\n\t\tSystem.out.println(s.toLowerCase());\n\t\t\n\t\tScanner ss= new Scanner(System.in);\n\t\tString input=ss.nextLine();\n\t\t\n\t\tSystem.out.println(input.trim());\n\t\t\n\t\tfinal String s1f=\"final\";\n\t\tfinal StringBuffer sb1= new StringBuffer(\"asd0\");\n\t\tsb1.append(\"tets\");\n\t\t\n\t\t\n\t\t\n\t\t\n\t}", "int stringsConstruction(String a, String b){\n a=\" \"+a+\" \";\n b=\" \"+b+\" \";\n int output = b.split(\"\"+a.charAt(1)).length - 1;\n for(char i = 'a'; i <= 'z'; i++) {\n if (a.split(\"\"+i).length > 1) {\n int tempOut = (b.split(\"\"+i).length - 1) / (a.split(\"\"+i).length - 1);\n if (output > tempOut) {\n output = tempOut;\n }//if (output > tempOut) {\n }//if (a.split(\"\"+i).length > 1) {\n }//for(char i = 'a'; i <= 'z'; i++) {\n return output;\n }", "public static void main(String[] args) {\nString a = \"abc 123\";\n//String b = \"123\";\n//String e = \"123\";\nString c = \"c\";\n//String d = b + e;\n\nint b = 123;\nint e = 123;\nint d = b +e;\n//System.out.println(d);\n\n\nObject m = \"abc123\";\nObject n = 123;\nObject n1 = 123;\nObject j = 'a';\nObject s = true;\n//Object n3 = n + n1;\n//System.out.println(n3);\n\nObject[] p= new Object[5];\np[0] = \"abc123\";\np[1] = 123;\np[2] = 124;\np[3] = 'a';\np[4] = true;\n//System.out.println(p[1]-p[2]);\n\n\t}", "java.lang.String getS2();", "public static int Main()\n\t{\n\t\tString s = new String(new char[256]);\n\t\tString z = new String(new char[256]);\n\t\tString r = new String(new char[256]);\n\t\tint i;\n\t\ts = new Scanner(System.in).nextLine();\n\t\tz = new Scanner(System.in).nextLine();\n\t\tr = new Scanner(System.in).nextLine();\n//C++ TO JAVA CONVERTER TODO TASK: Pointer arithmetic is detected on this variable, so pointers on this variable are left unchanged:\n\t\tchar * p = tangible.StringFunctions.strStr(s, z);\n\t\tif (p == null)\n\t\t{\n\t\t\tSystem.out.print(s);\n\t\t}\n\t\telse\n\t\t{\n\t\t\tString q = s;\n\t\t\tfor (i = 0; i < (p - q); i++)\n\t\t\t{\n\t\t\t\tSystem.out.print(s.charAt(i));\n\t\t\t}\n\t\t\tSystem.out.print(r);\n\t\t\tp = p + (z.length());\n\t\t\twhile (*p != '\\0')\n\t\t\t{\n\t\t\t\tSystem.out.print(p);\n\t\t\t\tp++;\n\t\t\t}\n\t\t}\n\t\treturn 0;\n\t}", "C11996a mo41079a(String str);", "public static void testZ(){\n\t\tStrings t = new Strings();\r\n\t\tt.ts = \"a\";\r\n\t\tStrings s = new Strings();\r\n\t\ts.ts = \"b\";\r\n\t\tSystem.out.printf(\"t: %s, s: %s;\\n\",t.ts,s.ts);\r\n\t\t\tswap(t, s);\r\n\t\t\tSystem.out.printf(\"t: %s, s: %s;\\n\",t.ts,s.ts);\r\n\t\t\r\n\t}", "public void construct(String s, String p, String o) {\n\tvariables.append(\" \").append(s != null ? s : \"?s\").append(\" \")\n\t\t.append(p != null ? p : \"?p\").append(\" \")\n\t\t.append(o != null ? o : \"?o\").append(\" . \");\n }", "static void pr(String s) {\n System.out.println(s);\n }", "boolean checkChar(String s1, String s2);", "public abstract void mo70715b(String str, String str2);", "static int[] lcp(char[] s) {\n return lcp(s, suffix(s));\n}", "boolean sameName(String a, String b){\n\t\tif(a.length()!=b.length()){\r\n\r\n\t\t\treturn false;\r\n\t\t}\r\n\t\tfor(int i=0;i<a.length();i++){\r\n\t\t\tif(a.charAt(i)!=b.charAt(i)){\r\n\t\t\t\treturn false;\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn true;\r\n\t}", "public static void main(String args[])\n {\n String s2 = \"Welcome\"; //new String (\"Welcome\"); // new operator\n \n \n String s1= new String(\"Welcome\");\n // String s2= new String(\"Welcome\");\n \n \n if(s1.equals(s2))\n {\n System.out.println(\"contents same\");\n }\n else\n {\n System.out.println(\"contents not same\");\n }\n \n if(s1==s2)\n {\n System.out.println(\"address same\");\n }\n else\n {\n System.out.println(\"address not same\");\n }\n \n \n \n }", "public void m23077a(String str) {\n }", "public static void main(String[] args) {\n\r\n\t\tString s=\"Programming\";\r\n\t\tString s1;\r\n\t\tCharacter ch;\r\n\t\tint count;\r\n\t\tfor(int i=0;i<s.length();i++)\r\n\t\t{\r\n\t\t\tch=s.charAt(i);\r\n\t\t\tcount=0;\r\n\t\t\tfor(int j=0;j<s.length();j++)\r\n\t\t\t{\r\n\t\t\t\tif(j<i&& ch==s.charAt(j))\r\n\t\t\t\t{\r\n\t\t\t\t\tbreak;\r\n\t\t\t\t}\r\n\t\t\t\tif(s.charAt(j)==ch)\r\n\t\t\t\t{\r\n\t\t\t\t\tcount++;\r\n\t\t\t\t}\r\n\t\t\t\tif(j==(s.length()-1))\r\n\t\t\t\t{\r\n\t\t\t\t\tSystem.out.println(ch+\" \"+count);\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\tif(count>1)\r\n\t\t\t{\r\n\t\t\t\t\ts=s.replace(ch.toString(),\"\");\r\n\t\t\t\t\t//System.out.println(s);\r\n\t\t\t}\r\n\t\t\t\r\n\t\t}\r\n\t\tSystem.out.println(s.trim());\r\n\t}", "void mo1934b(String str);", "public static void main(String args[]) {\n String str1 = new String(\"Java strings are objects.\");\n String str2 = \"They are constructed various ways.\";\n String str3 = new String(str2);\n\n String test = \"this is a string\";\n test = \"this is a new string\";\n\n String b = \" This\" + \" is \" + \"a \" + \"String\";\n\n\n System.out.println(str1);\n System.out.println(str2);\n System.out.println(str3);\n System.out.println(test);\n System.out.println(b);\n }", "public static void main(String[] args) {\n\t\t\n\t\t\tString s1=\"Sachin\"; \n\t\t String s2=\"Sachin\"; \n\t\t String s3=new String(\"Sachin\"); \n\t\t String s4=\"Saurav\"; \n\t\t String s5=\"SACHIN\";\n\t\t \n\t\t // System.out.println(s1.equalsIgnoreCase(s5));\n\t\t \n\tString s6=s1.substring(2,5);\n\tBoolean s8=s1.endsWith(\"chin\");\n\tchar s7=s1.charAt(2);\n\t\n\t//System.out.println(s8);\n\t\n\t\n\tString s9=\"Puja Kumari\";\n\t\n\tchar c[] =s9.toCharArray();\n\t\n\tSystem.out.println(c[10]);\n\t\n\n\t}", "public abstract String mo24851a(String str);", "int mo5882g(String str);", "public static String z() {\n if (f == null) {\n f = a((String) \"ss\");\n }\n return f;\n }", "private void s(String s2) {\n System.out.println(s2);\n }", "boolean mo1887a(String str);", "public static void main(String[] args) {\n\t\tString a = \"Programming\";\n\t\tString b = new String(\"Programming\");\n\t\tString c = \"Program\" + \"ming\";\n\t\t\n\t\tSystem.out.println(a == b);\n\t\tSystem.out.println(a == c);\n\t\tSystem.out.println(a.equals(b));\n\t\tSystem.out.println(a.equals(c));\n\t\tSystem.out.println(a.intern() == b.intern());\n\t\t\n\t}", "public abstract void mo70704a(String str);", "public static void main(String[] args) {\n String name = new String(\"String one\");\n String name2 = name;\n\n System.out.println(name);\n System.out.println(name2);\n\n System.out.println(name.hashCode());\n System.out.println(name2.hashCode());\n\n name2 = \"String two\";\n\n System.out.println(name);\n System.out.println(name2);\n\n System.out.println(name.hashCode());\n System.out.println(name2.hashCode());\n\n\n }", "java.lang.String getS();", "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 List<Integer> findAnagrams(String s, String p) {\n //simple case\n //s1 is within s2\n List<Integer> result= new ArrayList<Integer>();\n if(s.length()<p.length())\n return result;\n int[] p_charset = new int[26];\n int[] s_charset= new int[26];\n for(int i=0;i<p.length();i++){\n int index_p= p.charAt(i)-'a';\n p_charset[index_p]++;\n int index_s= s.charAt(i)-'a';\n s_charset[index_s]++;\n }\n\n int i=0;\n for(;i<s.length()-p.length();i++){\n if(charsetEquals(s_charset,p_charset))\n result.add(i);\n int index_old= s.charAt(i)-'a';\n int index_new= s.charAt(i+p.length())-'a';\n s_charset[index_old]--;\n s_charset[index_new]++;\n }\n if(charsetEquals(s_charset,p_charset))\n result.add(i);\n\n return result;\n }", "public static void main(String[] args) {\n String name = new String(\"String one\");\n String name2 = name;\n\n System.out.println(name);\n System.out.println(name2);\n\n System.out.println(name.hashCode());\n System.out.println(name2.hashCode());\n\n name2 = \"String two\";\n\n System.out.println(name);\n System.out.println(name2);\n\n System.out.println(name.hashCode());\n System.out.println(name2.hashCode());\n\n\n //////////////////////////////////////////////\n System.out.println(\"****************************\");\n\n StringBuilder str1 = new StringBuilder(\"Sachin\");\n// str1 = str1 + new StringBuilder(\"fsf\");\n System.out.println(str1.hashCode());\n str1 = new StringBuilder(\"Schin tendulkar\");\n\n System.out.println(str1);\n System.out.println(str1.hashCode());\n\n str1.append(\"12334\");\n System.out.println(str1);\n System.out.println(str1.hashCode());\n\n }", "public static /* synthetic */ String m109037a(String str) {\n return str;\n }", "public static void main(String[] args) {\n\t\tString a=\"shubham\";\n\t\tString b=\"Baiyas\";\n\t\tSystem.out.println(\"Before Swapping\");\n\t\tSystem.out.println(\"a:\"+a);\n\t\tSystem.out.println(\"b:\"+b);\n\t\tSystem.out.println(\"--------------------------------\");\n\t\t\n\t\t//step 1: append a and b\n\t\t a=a+b; // shubhamBaiyas\n\t\t\n\t\t//step 2: store initial string a in b\n\t\t// b=a.substring(0, a.length()-b.length());\n\t\t b=a.substring(0, a.length()-b.length());\n\t\t\n\t\t//step 3: store initial b in a\n\t\t// a=a.substring(b.length());\n\t\t a=a.substring(b.length());\n\t\t System.out.println(\"After swapping\");\n\t\t System.out.println(\"a:\"+a);\n\t\t System.out.println(\"b:\"+b);\n\t\t\n\t\t\n\t\t\n\t}", "private String pcString(String g, String d) {\n return g+\"^part_of(\"+d+\")\";\n }", "@Test\n public void variableNaming(){\n String $aString=\"bob\";\n float $owed=10f;\n int aMount=4;\n long Amount=5;\n String A0123456789bCd$f=\"ugh\";\n\n\n assertEquals(4,aMount);\n assertEquals(5,Amount);\n assertEquals(10.0F,$owed,0);\n assertEquals(\"bob\",$aString);\n assertEquals(\"ugh\",A0123456789bCd$f);\n }", "public boolean strCopies(String str, String sub, int n) {\n//Solution to problem coming soon\n}", "public static boolean checkPermutaionMap(String s1, String s2) {\n if (s1.length() != s2.length()) return false;\n\n int[] charMap = new int[128];\n for (int i = 0; i < s1.length(); ++i) {\n charMap[s1.charAt(i)]++;\n }\n\n for (int i = 0; i < s2.length(); ++i) {\n if (--charMap[s2.charAt(i)] < 0) return false;\n }\n\n return true;\n }", "static int Prec(String s){\n switch (s)\n {\n case \"+\":\n case \"-\":\n return 1;\n case \"*\":\n case \"/\":\n return 2;\n }\n return -1;\n }", "public static void main(String[] args) {\n\t\t\n\t\tString s1 = \"akshay\";\n\t\tString s2 = \"akshay\";\n\t\tString s3 = new String(\"cherry\");\n\t\tString s4 = new String(\"cherry\");\n\t\tSystem.out.println(s1==s2);\n\t\tSystem.out.println(s1.equals(s2));\n\t\tSystem.out.println(s1==s3);\n\t\tSystem.out.println(s1.equals(s3));\n\t\tSystem.out.println(s3==s4);\n\t\tSystem.out.println(s3.contentEquals(s4));\n\t}" ]
[ "0.63430417", "0.62717974", "0.62056684", "0.6205092", "0.6188679", "0.6156657", "0.6119255", "0.60872954", "0.60844946", "0.607503", "0.6064267", "0.60494924", "0.60092366", "0.59976494", "0.59360874", "0.5928352", "0.5913343", "0.58704835", "0.5863793", "0.58599454", "0.5850878", "0.5820427", "0.57961565", "0.57948303", "0.5789279", "0.5759787", "0.5756632", "0.5753689", "0.57486624", "0.57482976", "0.5745157", "0.5712678", "0.56911516", "0.56903327", "0.5688703", "0.5688609", "0.5676251", "0.5661068", "0.5655287", "0.56404734", "0.5630747", "0.5623728", "0.5598427", "0.5597664", "0.5585022", "0.55773205", "0.55704176", "0.55554676", "0.55271214", "0.5520404", "0.55190665", "0.5510438", "0.55054367", "0.5491347", "0.548843", "0.5476026", "0.54732394", "0.5471055", "0.5462568", "0.5460439", "0.5460258", "0.5458845", "0.54493004", "0.54341507", "0.54123306", "0.54001504", "0.5392283", "0.53736895", "0.5373598", "0.5370314", "0.53686374", "0.5363278", "0.5355845", "0.5355681", "0.53531283", "0.5350793", "0.53497905", "0.53451204", "0.5343585", "0.53386116", "0.53280556", "0.5325404", "0.532088", "0.531823", "0.531313", "0.53130805", "0.53036684", "0.5291743", "0.5280075", "0.5274938", "0.5270049", "0.5269589", "0.5269358", "0.5260758", "0.52580845", "0.5255384", "0.5254064", "0.52472645", "0.5238251", "0.5234658", "0.52185243" ]
0.0
-1
Method to connect zookeeper ensemble.
public ZooKeeper connect() throws InterruptedException, IOException { zooKeeper = new ZooKeeper("127.0.0.1:2181", 5000, new Watcher() { public void process(WatchedEvent watchedEvent) { if (watchedEvent.getState() == Event.KeeperState.SyncConnected) { countDownLatch.countDown(); } } }); countDownLatch.await(); return zooKeeper; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void startZK(){\n int tryConnectionCount = 0;\n try {\n tryConnectionCount++;\n this.zk = new ZooKeeper(this.hostServer + \":\" + this.port, 15000, this);\n\n } catch (IOException e) {\n LOG.error(e);\n }\n }", "public ZooKeeper connect(String host) throws Exception {\r\n zk = new ZooKeeper(host, 3000, new Watcher() {\r\n public void process(WatchedEvent event) {\r\n if (event.getState() == KeeperState.SyncConnected) {\r\n connSignal.countDown();\r\n }\r\n }\r\n });\r\n connSignal.await();\r\n return zk;\r\n }", "public ZooKeeper connect(String host) throws Exception {\n\t\tzk = new ZooKeeper(host, 2101, new Watcher() {\n\t\t\tpublic void process(WatchedEvent event) {\n\t\t\t\tif (event.getState() == KeeperState.SyncConnected) {\n\t\t\t\t\tconnSignal.countDown();\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\t\tconnSignal.await();\n\t\treturn zk;\n\t}", "public void connect() throws IOException, InterruptedException, KeeperException {\n System.out.println(\"Connecting to zookeeper server...\");\n LOG.info(\"Connecting to zookeeper server...\");\n zk = new ZooKeeper(connectString, TIMEOUT,this);\n // wait for session establishment\n connLatch.await();\n mySid = zk.getSessionId();\n LOG.info(\"Connected to zookeeper server. SessionId: {}\", mySid);\n System.out.println(\"Connected to zookeeper server. MyId: \" + Utils.getHexSid(mySid));\n if (!isValidRoot()) {\n LOG.error(\"Invalid zRoot: {}\", root);\n throw new KeeperException.NoNodeException();\n }\n }", "public void connect() {\n this.disconnect();\n\n Settings settings = ImmutableSettings.settingsBuilder()\n .put(\"cluster.name\", this.cluster)\n .put(\"client.transport.sniff\", true)\n .build();\n this.elasticClient = new TransportClient(settings).addTransportAddresses(\n new InetSocketTransportAddress(this.host, this.port)\n );\n }", "private static synchronized void startZooKeeper(int i) {\n String zkAddress = ZK_PREFIX + (ZK_START_PORT + i);\n _zkServerMap.computeIfAbsent(zkAddress, ZkTestBase::createZookeeperServer);\n _helixZkClientMap.computeIfAbsent(zkAddress, ZkTestBase::createZkClient);\n _clusterSetupMap.computeIfAbsent(zkAddress, key -> new ClusterSetup(_helixZkClientMap.get(key)));\n _baseDataAccessorMap.computeIfAbsent(zkAddress, key -> new ZkBaseDataAccessor(_helixZkClientMap.get(key)));\n }", "int zookeeperClientPort();", "public String getZookeeperUrl() {\n return zookeeper.getHost() + \":\" + zookeeper.getPort();\n }", "@Override\n\tpublic void takeLeadership(CuratorFramework curator) throws Exception\n\t{\n\n\t\tLOG.info(\"a new leader has been elected: kaboom.id={}\", config.getKaboomId());\n\t\n\t\tThread.sleep(30 * 1000);\n\n\t\twhile (true)\n\t\t{\n\t\t\tMap<String, String> partitionToHost = new HashMap<String, String>();\n\t\t\tMap<String, List<String>> hostToPartition = new HashMap<String, List<String>>();\n\t\t\tfinal Map<String, KaBoomNodeInfo> clients = new HashMap<String, KaBoomNodeInfo>();\n\t\t\tMap<String, List<String>> clientToPartitions = new HashMap<String, List<String>>();\n\t\t\tMap<String, String> partitionToClient = new HashMap<String, String>();\n\t\t\tList<String> topics = new ArrayList<String>();\n\n\t\t\t// Get a full set of metadata from Kafka\n\t\t\tStateUtils.readTopicsFromZooKeeper(config.getKafkaZkConnectionString(), topics);\n\n\t\t\t// Map partition to host and host to partition\n\t\t\tStateUtils.getPartitionHosts(config.getKafkaSeedBrokers(), topics, partitionToHost, hostToPartition);\n\n\t\t\t// Get a list of active clients from zookeeper\n\t\t\tStateUtils.getActiveClients(curator, clients);\n\n\t\t\t// Get a list of current assignments\n\t\t\t// Get a list of current assignments\n\t\t\t\n\t\t\tfor (String partition : partitionToHost.keySet())\n\t\t\t{\n\t\t\t\tStat stat = curator.checkExists().forPath(\"/kaboom/assignments/\" + partition);\n\t\t\t\t\n\t\t\t\tif (stat != null)\n\t\t\t\t{\n\t\t\t\t\t// check if the client is still connected, and delete node if it is not.\n\t\t\t\t\t\n\t\t\t\t\tString client = new String(curator.getData().forPath(\"/kaboom/assignments/\" + partition), UTF8);\n\t\t\t\t\t\n\t\t\t\t\tif (clients.containsKey(client))\n\t\t\t\t\t{\n\t\t\t\t\t\tLOG.debug(\"Partition {} : client {} is connected\", partition, client);\n\t\t\t\t\t\t\n\t\t\t\t\t\tpartitionToClient.put(partition, client);\t\t\t\t\t\t\n\t\t\t\t\t\tList<String> parts = clientToPartitions.get(client);\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (parts == null)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tparts = new ArrayList<String>();\n\t\t\t\t\t\t\tclientToPartitions.put(client, parts);\n\t\t\t\t\t\t}\n\t\t\t\t\t\tparts.add(partition);\n\t\t\t\t\t} \n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tLOG.debug(\"Partition {} : client {} is not connected\", partition, client);\n\t\t\t\t\t\tcurator.delete().forPath(\"/kaboom/assignments/\" + partition);\n\t\t\t\t\t\tstat = null;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tStateUtils.calculateLoad(partitionToHost, clients, clientToPartitions);\n\n\t\t\t// If any node is over its target by at least one, then unassign partitions until it is at or below its target\n\t\t\t\n\t\t\tfor (Entry<String, KaBoomNodeInfo> e : clients.entrySet())\n\t\t\t{\n\t\t\t\tString client = e.getKey();\n\t\t\t\tKaBoomNodeInfo info = e.getValue();\n\n\t\t\t\tif (info.getLoad() >= info.getTargetLoad() + 1)\n\t\t\t\t{\n\t\t\t\t\tList<String> localPartitions = new ArrayList<String>();\n\t\t\t\t\tList<String> remotePartitions = new ArrayList<String>();\n\n\t\t\t\t\tfor (String partition : clientToPartitions.get(client))\n\t\t\t\t\t{\n\t\t\t\t\t\tif (partitionToHost.get(partition).equals(info.getHostname()))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tlocalPartitions.add(partition);\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\tremotePartitions.add(partition);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\t\twhile (info.getLoad() > info.getTargetLoad())\n\t\t\t\t\t{\n\t\t\t\t\t\tString partitionToDelete;\n\t\t\t\t\t\tif (remotePartitions.size() > 0)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tpartitionToDelete = remotePartitions.remove(rand.nextInt(remotePartitions.size()));\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\tpartitionToDelete = localPartitions.remove(rand.nextInt(localPartitions.size()));\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tLOG.info(\"Unassgning {} from overloaded client {}\", partitionToDelete, client);\n\t\t\t\t\t\tpartitionToClient.remove(partitionToDelete);\n\t\t\t\t\t\tclientToPartitions.get(client).remove(partitionToDelete);\n\t\t\t\t\t\tinfo.setLoad(info.getLoad() - 1);\n\n\t\t\t\t\t\tcurator.delete().forPath(\"/kaboom/assignments/\" + partitionToDelete);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t// Sort the clients by percent load, then add unassigned clients to the lowest loaded client\t\t\t\n\t\t\t{\n\t\t\t\tList<String> sortedClients = new ArrayList<String>();\n\t\t\t\tComparator<String> comparator = new Comparator<String>()\n\t\t\t\t{\n\t\t\t\t\t@Override\n\t\t\t\t\tpublic int compare(String a, String b)\n\t\t\t\t\t{\n\t\t\t\t\t\tKaBoomNodeInfo infoA = clients.get(a);\n\t\t\t\t\t\tdouble valA = infoA.getLoad() / infoA.getTargetLoad();\n\n\t\t\t\t\t\tKaBoomNodeInfo infoB = clients.get(b);\n\t\t\t\t\t\tdouble valB = infoB.getLoad() / infoB.getTargetLoad();\n\n\t\t\t\t\t\tif (valA == valB)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\treturn 0;\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 (valA > valB)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\treturn 1;\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\treturn -1;\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\t\n\t\t\t\tsortedClients.addAll(clients.keySet());\n\n\t\t\t\tfor (String partition : partitionToHost.keySet())\n\t\t\t\t{\n\t\t\t\t\t// If it's already assigned, skip it\n\t\t\t\t\t\n\t\t\t\t\tif (partitionToClient.containsKey(partition))\n\t\t\t\t\t{\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\tCollections.sort(sortedClients, comparator);\n\n\t\t\t\t\t/**\n\t\t\t\t\t * \n\t\t\t\t\t * Iterate through the list until we find either a local client below capacity, or we reach the ones that are \n\t\t\t\t\t * above capacity. If we reach clients above capacity, then just assign it to the first node.\n\t\t\t\t\t */\n\t\t\t\t\t\n\t\t\t\t\tLOG.info(\"Going to assign {}\", partition);\n\t\t\t\t\tString chosenClient = null;\n\t\t\t\t\t\n\t\t\t\t\tfor (String client : sortedClients)\n\t\t\t\t\t{\n\t\t\t\t\t\tLOG.info(\"- Checking {}\", client);\t\t\t\t\t\t\n\t\t\t\t\t\tKaBoomNodeInfo info = clients.get(client);\t\t\t\t\t\t\n\t\t\t\t\t\tLOG.info(\"- Current load = {}, Target load = {}\", info.getLoad(), info.getTargetLoad());\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (info.getLoad() >= info.getTargetLoad())\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tchosenClient = sortedClients.get(0);\n\t\t\t\t\t\t\tbreak;\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 (clients.get(client).getHostname().equals(partitionToHost.get(partition)))\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tchosenClient = client;\n\t\t\t\t\t\t\t\tbreak;\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\tcontinue;\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\tif (chosenClient == null)\n\t\t\t\t\t{\n\t\t\t\t\t\tchosenClient = sortedClients.get(0);\n\t\t\t\t\t}\n\n\t\t\t\t\tLOG.info(\"Assigning partition {} to client {}\", partition, chosenClient);\n\n\t\t\t\t\tcurator\n\t\t\t\t\t\t .create()\n\t\t\t\t\t\t .withMode(CreateMode.PERSISTENT)\n\t\t\t\t\t\t .forPath(\"/kaboom/assignments/\" + partition,\n\t\t\t\t\t\t\t chosenClient.getBytes(UTF8));\n\n\t\t\t\t\tList<String> parts = clientToPartitions.get(chosenClient);\n\t\t\t\t\t\n\t\t\t\t\tif (parts == null)\n\t\t\t\t\t{\n\t\t\t\t\t\tparts = new ArrayList<String>();\n\t\t\t\t\t\tclientToPartitions.put(chosenClient, parts);\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\tparts.add(partition);\n\n\t\t\t\t\tpartitionToClient.put(partition, chosenClient);\n\n\t\t\t\t\tclients.get(chosenClient).setLoad(clients.get(chosenClient).getLoad() + 1);\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t/*\n\t\t\t * Check to see if the kafka_ready flag writer thread exists and is alive:\n\t\t\t * \n\t\t\t * If it doesn't exist or isn't running, start it. This is designed to \n\t\t\t * work well when the load balancer sleeps for 10 minutes after assigning \n\t\t\t * work. If that behavior changes then additional logic will be required\n\t\t\t * to ensure this isn't executed too often \n\t\t\t */\n\t\t\t\n\t\t\tif (readyFlagThread == null || !readyFlagThread.isAlive())\n\t\t\t{\n\t\t\t\tLOG.info(\"[ready flag writer] thread doesn't exist or is not running\");\t\t\t\t\n\t\t\t\treadyFlagWriter = new ReadyFlagWriter(config, curator);\n\t\t\t\treadyFlagWriter.addListener(this);\n\t\t\t\treadyFlagThread = new Thread(readyFlagWriter);\n\t\t\t\treadyFlagThread.start();\n\t\t\t\tLOG.info(\"[ready flag writer] thread created and started\");\n\t\t\t}\n\n\t\t\tThread.sleep(10 * 60 * 1000);\n\t\t}\n\t}", "void connect() throws UnsupportedProtocolVersionException {\n if (isShutdown) return;\n\n List<Host> hosts = new ArrayList<Host>(cluster.metadata.getContactPoints());\n // shuffle so that multiple clients with the same contact points don't all pick the same control\n // host\n Collections.shuffle(hosts);\n setNewConnection(reconnectInternal(hosts.iterator(), true));\n }", "public ZooKeeper getClient4(Watcher watcher) throws IOException{\n\t\treturn new ZooKeeper(\"node-wuc-04:2181\", SESSION_TIMEOUT, watcher);\n\t}", "String zookeeperQuorum();", "@VisibleForTesting\n protected synchronized ZooKeeper getNewZooKeeper()\n throws IOException, InterruptedException {\n ZooKeeper zk = new ZooKeeper(zkHostPort, zkSessionTimeout, null);\n zk.register(new ForwardingWatcher());\n return zk;\n }", "public ZooKeeper getClient(Watcher watcher) throws IOException{\n\t\treturn new ZooKeeper(\"node11:2181,node12:2181,node13:2181\", SESSION_TIMEOUT, watcher);\n\t}", "public void setup(){\n this.cluster = Cluster.builder().addContactPoint(\"127.0.0.1\").build();\n this.session = this.cluster.connect(\"demo\");\n }", "@Override\n\tpublic void establishCoordinatorConn() throws InterruptedException {\n\t\tList<Thread> tList= new ArrayList<Thread>();\n\t\tfor (int i = 0; i < nProc-1; i++) {\n\t\t\tint clientPid = i + 2;\n\t\t\tThread t = new Thread(new Runnable() {\n\t\t\t\t@Override\n\t\t\t\tpublic void run() {\n\t\t\t\t\ttry {\n\t\t\t\t\t\tServerConnection conn = new ServerConnection();\n\t\t\t\t\t\tsynchronized (pidToConnMap) {\n\t\t\t\t\t\t\tpidToConnMap.put(clientPid, conn);\n\t\t\t\t\t\t}\n\t\t\t\t\t\tint port = 20000 + (100 * 1) + (clientPid);\n\t\t\t\t\t\tconn.connectRetry(coordinatorHostname, port);\n\t\t\t\t\t} catch (Exception e) {\n\t\t\t\t\t\te.printStackTrace();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t});\n\t\t\ttList.add(t);\n\t\t\tt.start();\n\t\t}\n\t\tfor (Thread t : tList) {\n\t\t\tt.join();\n\t\t}\n\t\tSystem.out.println(pidToConnMap.toString());\n\t}", "protected void connect() {\n\t\treadProperties();\n\t\tif (validateProperties())\n\t\t\tjuraMqttClient = createClient();\n\t}", "private synchronized void ensureZookeeperTrackers()\n throws ZooKeeperConnectionException {\n if (zooKeeper == null) {\n zooKeeper = getZooKeeperWatcher();\n }\n if (clusterId == null) {\n clusterId = new ClusterId(zooKeeper, this);\n if (clusterId.hasId()) {\n conf.set(HConstants.CLUSTER_ID, clusterId.getId());\n }\n }\n if (masterAddressTracker == null) {\n masterAddressTracker = new MasterAddressTracker(zooKeeper, this);\n masterAddressTracker.start();\n }\n if (rootRegionTracker == null) {\n rootRegionTracker = new RootRegionTracker(zooKeeper, this);\n rootRegionTracker.start();\n }\n // RpcEngine needs access to zookeeper data, like cluster ID\n if (rpcEngine == null) {\n this.rpcEngine = HBaseRPC.getProtocolEngine(conf);\n }\n }", "public void initializeConnection() {\n\n cluster = Cluster.builder().addContactPoint(host).build();\n session = cluster.connect(keyspaceName);\n session.execute(\"USE \".concat(keyspaceName));\n }", "public void connect() {\n try {\n socket = connectToBackEnd();\n } catch (IOException ioe) {\n ioe.printStackTrace();\n }\n }", "@Override\n public void connect(String name) throws Exception {\n }", "public ZooKeeper getClient2(Watcher watcher) throws IOException{\n\t\treturn new ZooKeeper(\"node-wuc-02:2181\", SESSION_TIMEOUT, watcher);\n\t}", "@Override\n public void before() throws Exception {\n zkTestServer = new TestingServerStarter().start();\n String connectionString = zkTestServer.getConnectString();\n\n //Initialize ZK client\n if (sessionTimeoutMs == 0 && connectionTimeoutMs == 0) {\n client = CuratorFrameworkFactory.newClient(connectionString, retryPolicy);\n } else {\n client = CuratorFrameworkFactory.newClient(connectionString, sessionTimeoutMs, connectionTimeoutMs, retryPolicy);\n }\n client.start();\n storeClient = StoreClientFactory.createZKStoreClient(client);\n }", "public ZooKeeper getClient3(Watcher watcher) throws IOException{\n\t\treturn new ZooKeeper(\"node-wuc-03:2181\", SESSION_TIMEOUT, watcher);\n\t}", "private CuratorFramework createCurator() {\n // Create list of Servers\n final String serverStr = sharedZookeeperTestResource.getZookeeperConnectString();\n final List<String> serverList = Arrays.asList(Tools.splitAndTrim(serverStr));\n\n // Create config map\n final Map<String, Object> config = new HashMap<>();\n config.put(\"servers\", serverList);\n\n return CuratorFactory.createNewCuratorInstance(config, getClass().getSimpleName());\n }", "@Override\r\n\tprotected void doOpen() throws Exception {\n\t\tAssert.notNull(rootdir, \"rootdir must be specified\");\r\n\t\tAssert.notNull(master, \"master AND database must be set\");\r\n\t\tAssert.notNull(quorum, \"quorum must be set\");\r\n\t\tAssert.notNull(converter, \"converter must be set\");\r\n\t\tconfiguration = HBaseConfiguration.create();\r\n\t\tconfiguration.set(\"hbase.rootdir\", rootdir);\r\n\t\tconfiguration.set(\"hbase.cluster.distributed\", \"true\");\r\n\t\tconfiguration.set(\"hbase.master\", master);\r\n\t\tconfiguration.set(\"hbase.zookeeper.quorum\", quorum);\r\n\t\tconnection = HConnectionManager\r\n\t\t\t\t.createConnection(configuration);\r\n\t}", "@Override\n\tpublic void startDatacenters() throws Exception {\n\t}", "public static String getZookeeperConnectString(String zookeepers, int zkPort) {\r\n StringTokenizer tokens = new StringTokenizer(zookeepers, \",\");\r\n List<String> hosts = new ArrayList<String>();\r\n while (tokens.hasMoreTokens()) {\r\n hosts.add(tokens.nextToken());\r\n }\r\n Collections.shuffle(hosts); // try addressing different zookeepers as first\r\n StringBuffer result = new StringBuffer();\r\n Iterator<String> iter = hosts.iterator();\r\n while (iter.hasNext()) {\r\n result.append(iter.next());\r\n result.append(\":\");\r\n result.append(zkPort);\r\n if (iter.hasNext()) {\r\n result.append(\",\");\r\n }\r\n }\r\n return result.toString();\r\n }", "@Override\n public void connect(Properties conf) throws Exception {\n loadConfiguration(conf);\n hBaseOperation = new HBaseOperation(conf);\n hadoopConf = hBaseOperation.gethConf();\n hbaseConnections = new Connection[numConnection];\n for (int i = 0; i < numConnection; i++) {\n hbaseConnections[i] = ConnectionFactory.createConnection(hadoopConf);\n }\n currentConnectionID = new AtomicInteger(0);\n dataTableName = TableName.valueOf(this.dataTableNameString);\n logger.info(\"HBase connections established.\");\n }", "@Override\n\t\t\t\tpublic void process(WatchedEvent event) {\n\t\t\t\t\tif (event.getState() == KeeperState.SyncConnected) {\n\t\t\t\t\t\tconnectedSignal.countDown(); // 倒数-1\n\t\t\t\t\t}else if (event.getState() == KeeperState.Expired) {\n\t\t\t\t\t\tlog.error(\"zookeeper session expired! now reconnectiing\");\n\t\t\t try {\n\t\t\t\t\t\t\tclose();\n\t\t\t\t\t\t\tgetConnection(serverList);\n\t\t\t\t\t\t} catch (Exception e) {\n\t\t\t\t\t\t\tlog.error(\"zookeeper connect error!\",e);\n\t\t\t\t\t\t}\n\t\t\t }\n\t\t\t\t}", "private static void setupConfigsAndStartCluster() throws Exception {\n setUpConfigForMiniCluster(conf1);\n conf1.setFloat(\"hbase.regionserver.logroll.multiplier\", 0.0003f);\n conf1.setInt(\"replication.source.size.capacity\", 10240);\n conf1.setLong(\"replication.source.sleepforretries\", 100);\n conf1.setInt(\"hbase.regionserver.maxlogs\", 10);\n conf1.setLong(\"hbase.master.logcleaner.ttl\", 10);\n conf1.setInt(\"zookeeper.recovery.retry\", 1);\n conf1.setInt(\"zookeeper.recovery.retry.intervalmill\", 10);\n conf1.setBoolean(\"dfs.support.append\", true);\n conf1.setLong(HConstants.THREAD_WAKE_FREQUENCY, 100);\n conf1.setInt(\"replication.stats.thread.period.seconds\", 5);\n conf1.setBoolean(\"hbase.tests.use.shortcircuit.reads\", false);\n\n utility1 = new HBaseTestingUtility(conf1);\n utility1.startMiniZKCluster();\n MiniZooKeeperCluster miniZK = utility1.getZkCluster();\n // Have to reset conf1 in case zk cluster location different\n // than default\n conf1 = utility1.getConfiguration();\n zkw1 = new ZKWatcher(conf1, \"cluster1\", null, true);\n admin = ConnectionFactory.createConnection(conf1).getAdmin();\n LOGGER.info(\"Setup first Zk\");\n\n // Base conf2 on conf1 so it gets the right zk cluster, and general cluster configs\n conf2 = HBaseConfiguration.create(conf1);\n conf2.set(HConstants.ZOOKEEPER_ZNODE_PARENT, \"/2\");\n conf2.setInt(HConstants.HBASE_CLIENT_RETRIES_NUMBER, 6);\n conf2.setBoolean(\"dfs.support.append\", true);\n conf2.setBoolean(\"hbase.tests.use.shortcircuit.reads\", false);\n\n utility2 = new HBaseTestingUtility(conf2);\n utility2.setZkCluster(miniZK);\n zkw2 = new ZKWatcher(conf2, \"cluster2\", null, true);\n\n LOGGER.info(\"Setup second Zk\");\n utility1.startMiniCluster(2);\n utility2.startMiniCluster(2);\n //replicate from cluster 1 -> cluster 2, but not back again\n admin.addReplicationPeer(\"1\",\n ReplicationPeerConfig.newBuilder().setClusterKey(utility2.getClusterKey()).build());\n }", "public void connect() {\n try {\n // ghetto hardcode the parameters\n ORB orb = ORB.init(new String[]{\"-ORBInitialHost\", \"localhost\", \"-ORBInitialPort\", \"8989\"}, null);\n\n org.omg.CORBA.Object objRef = orb.resolve_initial_references(\"NameService\");\n NamingContext ncRef = NamingContextHelper.narrow(objRef);\n\n NameComponent nc = new NameComponent(station, \"\");\n NameComponent path[] = {nc};\n instance = StationInterfaceHelper.narrow(ncRef.resolve(path));\n\n this.log.log(\"Connected!\");\n } catch (Exception ex) {\n log.log(ex.toString() + ex.getMessage());\n }\n }", "@Override\n public void run(String... args) throws Exception {\n\n String path = \"/dwx/name\";\n\n curatorFramework.start();\n\n Stat stat =curatorFramework.checkExists().forPath(path);\n\n\n if ( null != stat ) {\n System.out.println(Thread.currentThread().getName() + \": node already exist: \" + stat.toString());\n for (long count = 0; count <= (long)0x1 << 32; count ++) {\n System.out.println(Thread.currentThread().getName() + \": current count value:\" + count);\n if (!curatorFramework.getZookeeperClient().isConnected()) {\n curatorFramework.getZookeeperClient().start();\n } else {\n System.out.println(\"client is connected!\");\n }\n curatorFramework.setData().forPath(path, String.valueOf(123).getBytes());\n }\n } else {\n String age = curatorFramework.create().forPath(path, String.valueOf(30).getBytes());\n System.out.println(\"set value: \" + age);\n }\n\n// TimeUnit.MINUTES.sleep(10);\n// curatorFramework.close();\n\n }", "public synchronized void connectToCohort()\n {\n if (cohortRegistry != null)\n {\n cohortRegistry.connectToCohort();\n }\n }", "@BeforeSuite\n public void beforeSuite() throws Exception {\n java.util.logging.Logger topJavaLogger = java.util.logging.Logger.getLogger(\"\");\n topJavaLogger.setLevel(Level.WARNING);\n\n // Due to ZOOKEEPER-2693 fix, we need to specify whitelist for execute zk commends\n System.setProperty(\"zookeeper.4lw.commands.whitelist\", \"*\");\n System.setProperty(SystemPropertyKeys.CONTROLLER_MESSAGE_PURGE_DELAY, \"3000\");\n\n // Start in-memory ZooKeepers\n // If multi-ZooKeeper is enabled, start more ZKs. Otherwise, just set up one ZK\n int numZkToStart = 1;\n String multiZkConfig = System.getProperty(MULTI_ZK_PROPERTY_KEY);\n if (multiZkConfig != null && multiZkConfig.equalsIgnoreCase(Boolean.TRUE.toString())) {\n String numZkFromConfig = System.getProperty(NUM_ZK_PROPERTY_KEY);\n if (numZkFromConfig != null) {\n try {\n numZkToStart = Math.max(Integer.parseInt(numZkFromConfig), numZkToStart);\n } catch (Exception e) {\n Assert.fail(\"Failed to parse the number of ZKs from config!\");\n }\n } else {\n Assert.fail(\"multiZk config is set but numZk config is missing!\");\n }\n }\n\n // Start \"numZkFromConfigInt\" ZooKeepers\n for (int i = 0; i < numZkToStart; i++) {\n startZooKeeper(i);\n }\n\n // Set the references for backward-compatibility with a single ZK environment\n _zkServer = _zkServerMap.get(ZK_ADDR);\n _gZkClient = _helixZkClientMap.get(ZK_ADDR);\n _gSetupTool = _clusterSetupMap.get(ZK_ADDR);\n _baseAccessor = _baseDataAccessorMap.get(ZK_ADDR);\n\n // Clean up all JMX objects\n for (ObjectName mbean : _server.queryNames(null, null)) {\n try {\n _server.unregisterMBean(mbean);\n } catch (Exception e) {\n // OK\n }\n }\n }", "public void init() throws Exception {\n if (\"local\".equalsIgnoreCase(cluster.provisioningMethod)) {\n zookeeper = new LocalZookeeper();\n int initValue = zookeeper.start();\n if (initValue != 0) {\n log.error(\"Failed to start Zookeeper!\");\n throw new RuntimeException(\"Failed to start Zookeeper!\");\n }\n\n ExecutorService executor = Executors.newFixedThreadPool(1, new ThreadFactoryBuilder().setNameFormat(\"nodestarter-threadpool\").build()); \n \t\t //Executors.newFixedThreadPool(Runtime.getRuntime().availableProcessors()/2+1, new ThreadFactoryBuilder().setNameFormat(\"nodestarter-threadpool\").build()); \n\n int basePort = Util.getFreePort(cluster.numSolrNodes);\n\n for (int i = 1; i <= cluster.numSolrNodes; i++) {\n \t int nodeIndex = i;\n \t Callable c = () -> {\n \t\t SolrNode node = new LocalSolrNode(solrPackagePath, nodeIndex, String.valueOf(basePort + nodeIndex - 1), cluster.startupParams, cluster.startupParamsOverrides, zookeeper);\n \t\t \n \t\t try {\n\t \t\t node.init();\n\t \t\t node.start();\n\t \t\t nodes.add(node);\n\t \t\t \n\t \t\t log.info(\"Nodes started: \"+nodes.size());\n\t \t\t \n\t \t\t //try (HttpSolrClient client = new HttpSolrClient.Builder(node.getBaseUrl()).build();) {\n\t \t\t\t //log.info(\"Health check: \"+ new HealthCheckRequest().process(client) + \", Nodes started: \"+nodes.size());\n\t \t\t //} catch (Exception ex) {\n\t \t\t\t// log.error(\"Problem starting node: \"+node.getBaseUrl());\n\t \t\t\t //throw new RuntimeException(\"Problem starting node: \"+node.getBaseUrl());\n\t \t\t //}\n\t \t\t return node;\n \t\t } catch (Exception ex) {\n \t\t\t ex.printStackTrace();\n \t\t\t log.error(\"Problem starting node: \"+node.getBaseUrl());\n \t\t\t return null;\n \t\t }\n \t };\n \t executor.submit(c);\n }\n \n executor.shutdown();\n executor.awaitTermination(1, TimeUnit.HOURS);\n\n log.info(\"Looking for healthy nodes...\");\n List<SolrNode> healthyNodes = new ArrayList<>();\n for (SolrNode node: nodes) {\n \t\ttry (HttpSolrClient client = new HttpSolrClient.Builder(node.getBaseUrl().substring(0, node.getBaseUrl().length()-1)).build();) {\n \t\t\tHealthCheckRequest req = new HealthCheckRequest();\n \t\t\tHealthCheckResponse rsp;\n \t\t\ttry {\n \t\t\t\trsp = req.process(client);\n \t\t\t} catch (Exception ex) {\n \t\t\t\tThread.sleep(100);\n \t\t\t\trsp = req.process(client);\n \t\t\t}\n \t\t\tif (rsp.getNodeStatus().equalsIgnoreCase(\"ok\") == false) {\n \t\t\t\tlog.error(\"Couldn't start node: \"+node.getBaseUrl());\n \t\t\t\tthrow new RuntimeException(\"Couldn't start node: \"+node.getBaseUrl());\n \t\t\t} else {\n \t\t\t\thealthyNodes.add(node);\n \t\t\t}\n \t\t} catch (Exception ex) {\n \t\t\tex.printStackTrace();\n \t\t\tlog.error(\"Problem starting node: \"+node.getBaseUrl());\n \t\t}\n }\n \n this.nodes = healthyNodes;\n log.info(\"Healthy nodes: \"+healthyNodes.size());\n \n try (CloudSolrClient client = new CloudSolrClient.Builder().withZkHost(getZookeeperUrl()).build();) {\n\t log.info(\"Cluster state: \" + client.getClusterStateProvider().getClusterState());\n\t log.info(\"Overseer: \" + client.request(new OverseerStatus()));\n }\n\n \n } else if (\"terraform-gcp\".equalsIgnoreCase(cluster.provisioningMethod)) {\n \tSystem.out.println(\"Solr nodes: \"+getSolrNodesFromTFState());\n \tSystem.out.println(\"ZK node: \"+getZkNodeFromTFState());\n \tzookeeper = new GenericZookeeper(getZkNodeFromTFState());\n \tfor (String host: getSolrNodesFromTFState()) {\n \t\tnodes.add(new GenericSolrNode(host, cluster.terraformGCPConfig.get(\"user\").toString()));\n \t}\n } else if (\"vagrant\".equalsIgnoreCase(cluster.provisioningMethod)) {\n \tSystem.out.println(\"Solr nodes: \"+getSolrNodesFromVagrant());\n \tSystem.out.println(\"ZK node: \"+getZkNodeFromVagrant());\n \tzookeeper = new GenericZookeeper(getZkNodeFromVagrant());\n \tfor (String host: getSolrNodesFromVagrant()) {\n \t\tnodes.add(new GenericSolrNode(host, null)); // TODO fix username for vagrant\n \t}\n } else if (\"external\".equalsIgnoreCase(cluster.provisioningMethod)) {\n log.info(\"ZK node: \" + cluster.externalSolrConfig.zkHost);\n String[] tokens = cluster.externalSolrConfig.zkHost.split(\":\");\n zookeeper = new GenericZookeeper(tokens[0], tokens.length > 1 ? Integer.parseInt(tokens[1]) : null, cluster.externalSolrConfig.zkAdminPort, cluster.externalSolrConfig.zkChroot);\n\n try (CloudSolrClient client = new CloudSolrClient.Builder().withZkHost(cluster.externalSolrConfig.zkHost).withZkChroot(cluster.externalSolrConfig.zkChroot).build()) {\n for (String liveNode : client.getClusterStateProvider().getLiveNodes()) {\n nodes.add(new ExternalSolrNode(\n liveNode.split(\"_solr\")[0].split(\":\")[0],\n Integer.valueOf(liveNode.split(\"_solr\")[0].split(\":\")[1]),\n cluster.externalSolrConfig.sshUserName,\n cluster.externalSolrConfig.restartScript));\n }\n List<SolrNode> dataNodes = getExternalDataNodes(client).stream().map(dataNode -> new ExternalSolrNode(\n dataNode.split(\"_solr\")[0].split(\":\")[0],\n Integer.valueOf(dataNode.split(\"_solr\")[0].split(\":\")[1]),\n cluster.externalSolrConfig.sshUserName,\n cluster.externalSolrConfig.restartScript)).collect(Collectors.toList());\n if (!dataNodes.isEmpty()) {\n nodesByRole.put(NodeRole.DATA, dataNodes);\n }\n List<SolrNode> queryNodes = getExternalQueryNodes(client).stream().map(queryNode -> new ExternalSolrNode(\n queryNode.split(\"_solr\")[0].split(\":\")[0],\n Integer.valueOf(queryNode.split(\"_solr\")[0].split(\":\")[1]),\n cluster.externalSolrConfig.sshUserName,\n cluster.externalSolrConfig.restartScript)).collect(Collectors.toList());\n if (!queryNodes.isEmpty()) {\n nodesByRole.put(NodeRole.COORDINATOR, queryNodes);\n }\n List<SolrNode> overseerNodes = getExternalPreferredOverseerNodes(client).stream().map(overseerNode -> new ExternalSolrNode(\n overseerNode.split(\"_solr\")[0].split(\":\")[0],\n Integer.valueOf(overseerNode.split(\"_solr\")[0].split(\":\")[1]),\n cluster.externalSolrConfig.sshUserName,\n cluster.externalSolrConfig.restartScript)).collect(Collectors.toList());\n if (!queryNodes.isEmpty()) {\n nodesByRole.put(NodeRole.OVERSEER, overseerNodes);\n }\n }\n log.info(\"Cluster initialized with nodes: \" + nodes + \", zkHost: \" + zookeeper + \", nodes by role: \" + nodesByRole);\n }\n\n\n }", "private void connectUsingToken() {\n\t\tString protocol = null;\n\t\tint port = getPortNumber();\n\t\tif (isWebSocket()) {\n\t\t\tprotocol = \"wss://\";\n\t\t\t// If there is no port specified use default\n\t\t\tif(port == -1) {\n\t\t\t\tport = WSS_PORT;\n\t\t\t}\n\t\t} else {\n\t\t\tprotocol = \"ssl://\";\n\t\t\t// If there is no port specified use default\n\t\t\tif(port == -1) {\n\t\t\t\tport = MQTTS_PORT;\n\t\t\t}\n\t\t} \n\n\t\tString mqttServer = getMQTTServer();\n\t\tif(mqttServer != null){\n\t\t\tserverURI = protocol + mqttServer + \":\" + port;\n\t\t} else {\n\t\t\tserverURI = protocol + getOrgId() + \".\" + MESSAGING + \".\" + this.getDomain() + \":\" + port;\n\t\t}\n\t\ttry {\n\t\t\tmqttAsyncClient = new MqttAsyncClient(serverURI, clientId, DATA_STORE);\n\t\t\tmqttAsyncClient.setCallback(mqttCallback);\n\t\t\tmqttClientOptions = new MqttConnectOptions();\n\t\t\tif (clientUsername != null) {\n\t\t\t\tmqttClientOptions.setUserName(clientUsername);\n\t\t\t}\n\t\t\tif (clientPassword != null) {\n\t\t\t\tmqttClientOptions.setPassword(clientPassword.toCharArray());\n\t\t\t}\n\t\t\tmqttClientOptions.setCleanSession(this.isCleanSession());\n\t\t\tif(this.keepAliveInterval != -1) {\n\t\t\t\tmqttClientOptions.setKeepAliveInterval(this.keepAliveInterval);\n\t\t\t}\n\t\t\tmqttClientOptions.setMaxInflight(getMaxInflight());\n\t\t\tmqttClientOptions.setAutomaticReconnect(isAutomaticReconnect());\n\t\t\t\n\t\t\tSSLContext sslContext = SSLContext.getInstance(\"TLSv1.2\");\n\n\t\t\tsslContext.init(null, null, null);\n\t\t\t\n\t\t\tmqttClientOptions.setSocketFactory(sslContext.getSocketFactory());\n\n\t\t} catch (Exception e) {\n\t\t\te.printStackTrace();\n\t\t}\n\t}", "public void connect();", "public void connect();", "public void connect();", "public void connect() throws Exception {\n connectCount.incrementAndGet();\n LOG.trace(\"Connecting JGroups-raft Channel {} with cluster name: {}, raftHandle: {} and using config: {}\",\n getEndpointUri(), clusterName, resolvedRaftHandle, channelProperties == null ? \"default\" : channelProperties);\n resolvedRaftHandle.channel().connect(clusterName);\n }", "public void connectClusters()\n\t{\n//\t\tfor(int i = 0; i<edges.size();i++)\n//\t\t{\n//\t\t\tEdgeElement edge = edges.get(i);\n//\t\t\tString fromNodeID = edge.fromNodeID;\n//\t\t\tNodeElement fromNode = findSubNode(fromNodeID);\n//\t\t\tString toNodeID = edge.toNodeID;\n//\t\t\tNodeElement toNode = findSubNode(toNodeID); \n//\t\t\t\n//\t\t\tif(fromNode != null && toNode != null)\n//\t\t\t{\n//\t\t\t\tPortInfo oport = new PortInfo(edge, fromNode);\n//\t\t\t\tfromNode.addOutgoingPort(oport);\n//\t\t\t\tedge.addIncomingPort(oport);\n//\t\t\t\tPortInfo iport = new PortInfo(edge, toNode);\n//\t\t\t\ttoNode.addIncomingPort(iport);\n//\t\t\t\tedge.addOutgoingPort(iport);\n//\t\t\t}\n//\t\t}\n\t}", "@Override\n public abstract void connect();", "public static void connect() {\n \t\tconnPool.start();\n \t}", "public static void getCluster(ZkClient zkClient) {\n \ttry {\n \t\tif(zkClient.getZooKeeper().getState().isAlive()){\n \t\t\tList<String> allGroupNames = ZkUtils.getChildrenParentMayNotExist(zkClient, ServerRegister.ZK_BROKER_GROUP);\n \tCollections.sort(allGroupNames);\n if (allGroupNames != null) {\n \t//LOGGER.debug(\"read all broker group count: \" + allGroupNames.size());\n \tList<Group> allGroup = new ArrayList<Group>();\n \tMap<String, String> slaveIp = new HashMap<>();\n for (String group : allGroupNames) {\n String jsonGroup = ZkUtils.readData(zkClient, ServerRegister.ZK_BROKER_GROUP + \"/\" + group);\n if(StringUtils.isNotBlank(jsonGroup)){\n \tGroup groupObj = DataUtils.json2BrokerGroup(jsonGroup);\n \tallGroup.add(groupObj);\n \tif(groupObj.getSlaveOf() != null){\n \t\tslaveIp.put(groupObj.getSlaveOf().getHost(), groupObj.getMaster().getHost());\n \t}\n \t//LOGGER.debug(\"Loading Broker Group \" + groupObj.toString());\n }\n }\n Cluster.clear();\n List<Group> noSlave = new ArrayList<Group>();\n for(Group group:allGroup){\n \tif(slaveIp.containsKey(group.getMaster().getHost())){\n \t\tgroup.getMaster().setShost(slaveIp.get(group.getMaster().getHost()));\n \t\tCluster.addGroup(group);\n \t}else{\n \t\tnoSlave.add(group);\n \t}\n }\n if(noSlave.size() > 0){\n \tCluster.addGroups(noSlave);\n \t//LOGGER.info(\"Master load success, list:\"+Cluster.getMasters().toString());\n }\n }\n \t\t}\n\t\t} catch (Exception e) {\n\t\t\tLOGGER.error(\"get cluster error\", e);\n\t\t}\n }", "@Deprecated\n public ConfigAccessor(String zkAddress) {\n _usesExternalZkClient = false;\n\n // If the multi ZK config is enabled, use FederatedZkClient on multi-realm mode\n if (Boolean.getBoolean(SystemPropertyKeys.MULTI_ZK_ENABLED) || zkAddress == null) {\n try {\n _zkClient = new FederatedZkClient(\n new RealmAwareZkClient.RealmAwareZkConnectionConfig.Builder().build(),\n new RealmAwareZkClient.RealmAwareZkClientConfig()\n .setZkSerializer(new ZNRecordSerializer()));\n return;\n } catch (InvalidRoutingDataException | IllegalStateException e) {\n throw new HelixException(\"Failed to create ConfigAccessor!\", e);\n }\n }\n\n _zkClient = SharedZkClientFactory.getInstance()\n .buildZkClient(new HelixZkClient.ZkConnectionConfig(zkAddress),\n new HelixZkClient.ZkClientConfig().setZkSerializer(new ZNRecordSerializer()));\n }", "public static void main(String[] args) {\n\t\tString configPath = null;\n\t\tString configZks = null;\n\t\t\n\t\tFileInputStream in;\n\t\ttry {\n\t\t\tin = new FileInputStream(\"ZkClient.cfg\");\n\t\t\tProperties prop = new Properties();\n\t\t\tprop.load(in);\n\t\t\tin.close();\n\t\t\tconfigZks\t= prop.getProperty(\"cfg_zks\");\n\t\t\tif (configZks == null){\n\t \treturn;\n\t }\n\t\t\tconfigPath\t= prop.getProperty(\"cfg_path\");\n\t\t\tif (configPath == null){\n\t \treturn;\n\t }\n\t\t\t\n\t\t} catch (Exception e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t\treturn;\n\t\t}\n\t\t\n\t\tFile file = new File(\"node.content\"); \n Long filelength = file.length(); \n byte[] fileContent = new byte[filelength.intValue()]; \n try {\n\t\t\tin = new FileInputStream(file);\n\t\t\tin.read(fileContent); \n\t in.close(); \n\t\t} catch (Exception e1) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te1.printStackTrace();\n\t\t} \n \n //JSONObject jsonObj = new JSONObject(filecontent); \n\t\t\n\t\tCuratorFramework client = CuratorFrameworkFactory.builder()\n\t\t\t\t.connectString(configZks)\n\t\t\t\t.sessionTimeoutMs(5000)\n\t\t\t\t.connectionTimeoutMs(3000)\n\t\t\t\t.retryPolicy(new ExponentialBackoffRetry(1000,3))\n\t\t\t\t.build();\n\t\tclient.start(); \n\t\t\n\t try { \n client.setData().forPath(configPath, fileContent); \n } catch (Exception e) { \n e.printStackTrace(); \n }\n\n\t}", "public ConnexionClass(){\n\n //sparkSession = SparkSession.builder().master(\"local[*]\").appName(\"BigDATA\").config(\"spark.master\", \"local\").getOrCreate();\n sparkSession = SparkSession\n .builder()\n .config(\"spark.master\", \"local\")\n .getOrCreate();\n }", "@Override\n\tpublic synchronized void initialize(OperatorContext context) throws Exception {\n\t\tsuper.initialize(context);\n\n // Construct a new Jest client according to configuration via factory\n JestClientFactory factory = new JestClientFactory();\n factory.setHttpClientConfig(new HttpClientConfig\n .Builder(hostName + \":\" + hostPort)\n .multiThreaded(true)\n .build());\n \n client = factory.getObject();\n\t}", "@Override\n public synchronized void connect() throws AlluxioStatusException {\n if (mConnected) {\n return;\n }\n disconnect();\n Preconditions.checkState(!mClosed, \"Client is closed, will not try to connect.\");\n\n IOException lastConnectFailure = null;\n RetryPolicy retryPolicy = mRetryPolicySupplier.get();\n\n while (retryPolicy.attempt()) {\n if (mClosed) {\n throw new FailedPreconditionException(\"Failed to connect: client has been closed\");\n }\n // Re-query the address in each loop iteration in case it has changed (e.g. master\n // failover).\n try {\n mServerAddress = queryGrpcServerAddress();\n } catch (UnavailableException e) {\n LOG.debug(\"Failed to determine {} rpc address ({}): {}\",\n getServiceName(), retryPolicy.getAttemptCount(), e.toString());\n continue;\n }\n try {\n beforeConnect();\n LOG.debug(\"Alluxio client (version {}) is trying to connect with {} @ {}\",\n RuntimeConstants.VERSION, getServiceName(), mServerAddress);\n // set up rpc group channel\n mChannel = createChannel();\n // Create stub for version service on host\n mVersionService = ServiceVersionClientServiceGrpc.newBlockingStub(mChannel);\n mConnected = true;\n afterConnect();\n checkVersion(getServiceVersion());\n\n LOG.debug(\"Alluxio client (version {}) is connected with {} @ {}\", RuntimeConstants.VERSION,\n getServiceName(), mServerAddress);\n return;\n } catch (IOException e) {\n LOG.debug(\"Failed to connect ({}) with {} @ {}\", retryPolicy.getAttemptCount(),\n getServiceName(), mServerAddress, e);\n lastConnectFailure = e;\n if (e instanceof UnauthenticatedException) {\n // If there has been a failure in opening GrpcChannel, it's possible because\n // the authentication credential has expired. Re-login.\n mContext.getUserState().relogin();\n }\n if (e instanceof NotFoundException) {\n // service is not found in the server, skip retry\n break;\n }\n }\n }\n // Reaching here indicates that we did not successfully connect.\n if (mChannel != null) {\n mChannel.shutdown();\n }\n\n if (mServerAddress == null) {\n throw new UnavailableException(\n String.format(\"Failed to determine address for %s after %s attempts\", getServiceName(),\n retryPolicy.getAttemptCount()));\n }\n\n /*\n * Throw as-is if {@link UnauthenticatedException} occurred.\n */\n if (lastConnectFailure instanceof UnauthenticatedException) {\n throw (AlluxioStatusException) lastConnectFailure;\n }\n if (lastConnectFailure instanceof NotFoundException) {\n throw new NotFoundException(lastConnectFailure.getMessage(),\n new ServiceNotFoundException(lastConnectFailure.getMessage(), lastConnectFailure));\n }\n\n throw new UnavailableException(\n String.format(\n \"Failed to connect to master (%s) after %s attempts.\"\n + \"Please check if Alluxio master is currently running on \\\"%s\\\". Service=\\\"%s\\\"\",\n mServerAddress, retryPolicy.getAttemptCount(), mServerAddress, getServiceName()),\n lastConnectFailure);\n }", "@Override\r\n\tpublic void connect(URL url) throws RemoteException {\n\t\tclientPool=ClientPoolManager.INSTANCE.getClientPool(url);\r\n\r\n\t}", "public void connect() {}", "public Status connect()\n {\n return connect(5.0);\n }", "@Override\n \t\tprotected void setup(Context context){\n \t\t\tint port = 5701 + context.getTaskAttemptID().getId()%numInstances;\n \t\t\t//System.out.println(\"Connecting to port \" + port);\n \t\t\tClientConfig clientConfig = new ClientConfig();\n \t\t\tclientConfig.addAddress(\"127.0.0.1:\" + port);\n \t\t\tthis.client = HazelcastClient.newHazelcastClient(clientConfig);\n \t\t\tthis.map = client.getMap(\"kmer\");\n \t\t}", "private void establishConnection() {\n\n try {\n\n for(Clone clone:this.clones){\n ClearConnection connection = new ClearConnection();\n connection.connect(clone.getIp(), clone.getOffloadingPort(), 5 * 1000);\n this.connections.add(connection);\n }\n\n this.protocol = new ERAMProtocol();\n this.ode = new ERAMode();\n\n } catch (Exception e) {\n Log.e(TAG,\"Connection setup with the Remote Server failed - \" + e);\n }\n }", "public Echange_Client() throws UnknownHostException, IOException {\n start_Connexion(); \n }", "public static void createClusterZkNodes(SolrZkClient zkClient)\n throws KeeperException, InterruptedException, IOException {\n ZkMaintenanceUtils.ensureExists(ZkStateReader.LIVE_NODES_ZKNODE, zkClient);\n ZkMaintenanceUtils.ensureExists(ZkStateReader.NODE_ROLES, zkClient);\n for (NodeRoles.Role role : NodeRoles.Role.values()) {\n ZkMaintenanceUtils.ensureExists(NodeRoles.getZNodeForRole(role), zkClient);\n for (String mode : role.supportedModes()) {\n ZkMaintenanceUtils.ensureExists(NodeRoles.getZNodeForRoleMode(role, mode), zkClient);\n }\n }\n\n ZkMaintenanceUtils.ensureExists(ZkStateReader.COLLECTIONS_ZKNODE, zkClient);\n ZkMaintenanceUtils.ensureExists(ZkStateReader.ALIASES, zkClient);\n byte[] emptyJson = \"{}\".getBytes(StandardCharsets.UTF_8);\n ZkMaintenanceUtils.ensureExists(ZkStateReader.SOLR_SECURITY_CONF_PATH, emptyJson, zkClient);\n repairSecurityJson(zkClient);\n }", "public static String getZookeeper() {\r\n return zookeeper.getValue();\r\n }", "@Before\n public void conn() throws Exception {\n conf = new Configuration();\n fs = FileSystem.get(URI.create(\"hdfs://hadoop001:9000\"), conf, \"hadoop\");\n\n //fs = FileSystem.get(conf);\n }", "public void connect() {\n if (isShutdown)\n return;\n\n setNewConnection(reconnectInternal());\n }", "private void connect() throws UnknownHostException {\n mongoClient = new MongoClient(configurationFile.getHost(),configurationFile.getPort());\r\n db = mongoClient.getDB(configurationFile.getDatabaseName());\r\n }", "public static void main(String[] args) throws Exception {\n zooKeeper = new ZooKeeper(\"192.168.24.120:2181\",500,new CreateNodeSyn());\n countDownLatch.await();\n String path = zooKeeper.create(\"/zk-test-book-\", \"123\".getBytes(), ZooDefs.Ids.OPEN_ACL_UNSAFE, CreateMode.EPHEMERAL);\n System.out.println(\"Success create zNode:\" + path);\n String path2 = zooKeeper.create(\"/zk-test-book-\", \"123\".getBytes(), ZooDefs.Ids.OPEN_ACL_UNSAFE, CreateMode.EPHEMERAL_SEQUENTIAL);\n System.out.println(\"Success create zNode:\" + path2);\n }", "static Cluster clusterProvider(String neptune, int BATCH_SIZE) {\n java.security.Security.setProperty(\"networkaddress.cache.ttl\", \"0\");\n java.security.Security.setProperty(\"networkaddress.cache.negative.ttl\", \"0\");\n\n Cluster.Builder clusterBuilder = Cluster.build()\n .addContactPoint(neptune) // add more ro contact points for load balancing\n .port(8182)\n .enableSsl(true)\n// .keyStore(keyStore) // optional as amazon cert will be used and should be in truststore of server\n// .keyStorePassword(keyStorePassword)\n .channelizer(SigV4WebSocketChannelizer.class)\n .serializer(Serializers.GRAPHBINARY_V1D0)\n .maxInProcessPerConnection(1) // ensure no contention for connections per batch\n .minInProcessPerConnection(1)\n .maxSimultaneousUsagePerConnection(1)\n .minSimultaneousUsagePerConnection(1)\n .maxWaitForConnection(15000)\n .minConnectionPoolSize(BATCH_SIZE)\n .maxConnectionPoolSize(BATCH_SIZE);\n\n return clusterBuilder.create();\n }", "public void setup_connections()\n {\n setup_servers();\n setup_clients();\n }", "@Test\n public void testZookeeperCacheLoader() throws InterruptedException, KeeperException, Exception {\n\n DiscoveryZooKeeperClientFactoryImpl.zk = mockZookKeeper;\n\n @SuppressWarnings(\"resource\")\n ZookeeperCacheLoader zkLoader = new ZookeeperCacheLoader(new DiscoveryZooKeeperClientFactoryImpl(), \"\", 30_000);\n\n List<String> brokers = Lists.newArrayList(\"broker-1:15000\", \"broker-2:15000\", \"broker-3:15000\");\n for (int i = 0; i < brokers.size(); i++) {\n try {\n LoadManagerReport report = i % 2 == 0 ? getSimpleLoadManagerLoadReport(brokers.get(i))\n : getModularLoadManagerLoadReport(brokers.get(i));\n zkLoader.getLocalZkCache().getZooKeeper().create(LOADBALANCE_BROKERS_ROOT + \"/\" + brokers.get(i),\n ObjectMapperFactory.getThreadLocal().writeValueAsBytes(report), ZooDefs.Ids.OPEN_ACL_UNSAFE,\n CreateMode.PERSISTENT);\n } catch (Exception e) {\n fail(\"failed while creating broker znodes\");\n }\n }\n\n // strategically wait for cache to get sync\n for (int i = 0; i < 5; i++) {\n if (zkLoader.getAvailableBrokers().size() == 3 || i == 4) {\n break;\n }\n Thread.sleep(1000);\n }\n\n // 2. get available brokers from ZookeeperCacheLoader\n List<LoadManagerReport> list = zkLoader.getAvailableBrokers();\n\n // 3. verify retrieved broker list\n Set<String> cachedBrokers = list.stream().map(loadReport -> loadReport.getWebServiceUrl())\n .collect(Collectors.toSet());\n Assert.assertEquals(list.size(), brokers.size());\n Assert.assertTrue(brokers.containsAll(cachedBrokers));\n\n // 4.a add new broker\n final String newBroker = \"broker-4:15000\";\n LoadManagerReport report = getSimpleLoadManagerLoadReport(newBroker);\n zkLoader.getLocalZkCache().getZooKeeper().create(LOADBALANCE_BROKERS_ROOT + \"/\" + newBroker,\n ObjectMapperFactory.getThreadLocal().writeValueAsBytes(report), ZooDefs.Ids.OPEN_ACL_UNSAFE,\n CreateMode.PERSISTENT);\n brokers.add(newBroker);\n\n Thread.sleep(100); // wait for 100 msec: to get cache updated\n\n // 4.b. get available brokers from ZookeeperCacheLoader\n list = zkLoader.getAvailableBrokers();\n\n // 4.c. verify retrieved broker list\n cachedBrokers = list.stream().map(loadReport -> loadReport.getWebServiceUrl()).collect(Collectors.toSet());\n Assert.assertEquals(list.size(), brokers.size());\n Assert.assertTrue(brokers.containsAll(cachedBrokers));\n\n }", "public void openConnection(){\r\n try {\r\n Driver dr = new FabricMySQLDriver();\r\n DriverManager.registerDriver(dr);\r\n log.info(\"registrable driver\");\r\n } catch (SQLException e) {\r\n log.error(e.getMessage());\r\n e.printStackTrace();\r\n }\r\n try {\r\n connection = DriverManager.getConnection(URL, USERNAME, PASSWORD);\r\n log.info(\"get connection\");\r\n } catch (SQLException e) {\r\n log.error(e.getMessage());\r\n e.printStackTrace();\r\n }\r\n }", "private void connect() throws Exception {\n\t\tConnection c = DriverManager.getConnection(\"jdbc:mysql://\" + details[0] + \":3306/\" + details[3], details[1], details[2]);\n\t\tsetConnection(c);\n\t}", "private void connectToMaster(int masterPort) throws Exception {\n // Getting the registry \n Registry registry = LocateRegistry.getRegistry(null, masterPort); \n \n // Looking up the registry for the remote object \n this.master = (Master) registry.lookup(\"master\"); \n }", "NetworkClientConnection getConnection(String uriToNode);", "public void connect() {\n\n DatabaseGlobalAccess.getInstance().setEmf(Persistence.createEntityManagerFactory(\"PU_dashboarddb\"));\n DatabaseGlobalAccess.getInstance().setEm(DatabaseGlobalAccess.getInstance().getEmf().createEntityManager());\n DatabaseGlobalAccess.getInstance().getDatabaseData();\n DatabaseGlobalAccess.getInstance().setDbReachable(true);\n }", "public void establishConnection() {\n httpNetworkService = new HTTPNetworkService(handler);\n }", "private ClientExecutorEngine() {\n ClientConfigReader.readConfig();\n DrillConnector.initConnection();\n HzConfigReader.readConfig();\n }", "private void onReconnect(Supplier<List<CoreDescriptor>> descriptorsSupplier)\n throws SessionExpiredException {\n log.info(\"ZooKeeper session re-connected ... refreshing core states after session expiration.\");\n clearZkCollectionTerms();\n try {\n // recreate our watchers first so that they exist even on any problems below\n zkStateReader.createClusterStateWatchersAndUpdate();\n\n // this is troublesome - we don't want to kill anything the old\n // leader accepted\n // though I guess sync will likely get those updates back? But\n // only if\n // he is involved in the sync, and he certainly may not be\n // ExecutorUtil.shutdownAndAwaitTermination(cc.getCmdDistribExecutor());\n // we need to create all of our lost watches\n\n // seems we don't need to do this again...\n // Overseer.createClientNodes(zkClient, getNodeName());\n\n // start the overseer first as following code may need it's processing\n if (!zkRunOnly) {\n ElectionContext context = new OverseerElectionContext(zkClient, overseer, getNodeName());\n\n ElectionContext prevContext = overseerElector.getContext();\n if (prevContext != null) {\n prevContext.cancelElection();\n prevContext.close();\n }\n\n overseerElector.setup(context);\n\n if (cc.nodeRoles.isOverseerAllowedOrPreferred()) {\n overseerElector.joinElection(context, true);\n }\n }\n\n cc.cancelCoreRecoveries();\n\n try {\n registerAllCoresAsDown(descriptorsSupplier, false);\n } catch (SessionExpiredException e) {\n // zk has to reconnect and this will all be tried again\n throw e;\n } catch (Exception e) {\n // this is really best effort - in case of races or failure cases where we now\n // need to be the leader, if anything fails, just continue\n log.warn(\"Exception while trying to register all cores as DOWN\", e);\n }\n\n // we have to register as live first to pick up docs in the buffer\n createEphemeralLiveNode();\n\n List<CoreDescriptor> descriptors = descriptorsSupplier.get();\n // re register all descriptors\n ExecutorService executorService = (cc != null) ? cc.getCoreZkRegisterExecutorService() : null;\n if (descriptors != null) {\n for (CoreDescriptor descriptor : descriptors) {\n // TODO: we need to think carefully about what happens when it was a leader\n // that was expired - as well as what to do about leaders/overseers with\n // connection loss\n try {\n // unload solr cores that have been 'failed over'\n throwErrorIfReplicaReplaced(descriptor);\n\n if (executorService != null) {\n executorService.submit(new RegisterCoreAsync(descriptor, true, true));\n } else {\n register(descriptor.getName(), descriptor, true, true, false);\n }\n } catch (Exception e) {\n log.error(\"Error registering SolrCore\", e);\n }\n }\n }\n\n // notify any other objects that need to know when the session was re-connected\n HashSet<OnReconnect> clonedListeners;\n synchronized (reconnectListeners) {\n clonedListeners = new HashSet<>(reconnectListeners);\n }\n // the OnReconnect operation can be expensive per listener, so do that async in\n // the background\n for (OnReconnect listener : clonedListeners) {\n try {\n if (executorService != null) {\n executorService.submit(new OnReconnectNotifyAsync(listener));\n } else {\n listener.command();\n }\n } catch (Exception exc) {\n // not much we can do here other than warn in the log\n log.warn(\n \"Error when notifying OnReconnect listener {} after session re-connected.\",\n listener,\n exc);\n }\n }\n } catch (InterruptedException e) {\n // Restore the interrupted status\n Thread.currentThread().interrupt();\n throw new ZooKeeperException(ErrorCode.SERVER_ERROR, \"\", e);\n } catch (SessionExpiredException e) {\n throw e;\n } catch (Exception e) {\n log.error(\"Exception during reconnect\", e);\n throw new ZooKeeperException(ErrorCode.SERVER_ERROR, \"\", e);\n }\n }", "public void onStart() {\n Configuration curatorDiscoveryConf = Configuration.root().getConfig(\"curator.service.discovery\");\n\n if (curatorDiscoveryConf == null) {\n Logger.info(\"Curator Discovery settings not found.\");\n } else {\n serviceName = curatorDiscoveryConf.getString(\"name\", \"Play2CuratorService\");\n serviceDescription = curatorDiscoveryConf.getString(\"description\", \"Play2 Curator Service\");\n servicePath = curatorDiscoveryConf.getString(\"path\", \"/play2-curator-service-discovery-plugin\");\n autoRegister = curatorDiscoveryConf.getBoolean(\"autoregister\", Boolean.TRUE);\n uriSpecParam = curatorDiscoveryConf.getString(\"uri.spec\", \"{scheme}://{address}:{port}\");\n uriSpecSslParam = curatorDiscoveryConf.getString(\"ssl.uri.spec\", \"{scheme}://{address}:{ssl-port}\");\n\n Logger.info(\"CuratorServiceDiscoveryPlugin Settings:\");\n Logger.info(\" * serviceName: \" + serviceName);\n Logger.info(\" * serviceDescription: \" + serviceDescription);\n Logger.info(\" * servicePath: \" + servicePath);\n Logger.info(\" * autoRegister: \" + autoRegister);\n Logger.info(\" * uriSpec: \" + uriSpecParam);\n Logger.info(\" * uriSpecSsl: \" + uriSpecSslParam);\n\n zooServers = curatorDiscoveryConf.getString(\"zooServers\", \"localhost:2181\");\n Logger.info(\" * zooKeeper servers: \" + zooServers);\n\n if (zooServers.toLowerCase().contains(\"mock\")) {\n try {\n mockZooKeeper = new TestingServer(2181);\n zooServers = mockZooKeeper.getConnectString();\n Logger.info(\"Mock ZooKeeper started at: \" + zooServers);\n } catch (Exception e) {\n Logger.error(\"Could not start mock ZooKeeper server on port 2181: \" + e.getMessage());\n return;\n }\n }\n\n Logger.info(\"Curator Discovery settings found. ZooKeeper servers: \" + zooServers);\n if (autoRegister) {\n int port = 0;\n String sPort = Configuration.root().getString(\"http.port\");\n if (sPort != null) {\n try {\n port = Integer.parseInt(sPort);\n Logger.info(\" * port: \" + port);\n } catch (NumberFormatException nfe) {\n Logger.debug(\"port is not valid\");\n }\n }\n\n sPort = Configuration.root().getString(\"https.port\");\n int sslPort = 0;\n if (sPort != null) {\n try {\n sslPort = Integer.parseInt(sPort);\n Logger.info(\" * sslPort: \" + sslPort);\n } catch (NumberFormatException nfe) {\n Logger.debug(\"ssl-port is not valid\");\n }\n }\n if (port == 0 && sslPort == 0) {\n Logger.error(\"Can't register service. Port / sslPort not set\");\n } else {\n register(serviceName, serviceDescription, port, sslPort);\n }\n }\n }\n }", "@BeforeMethod\n void setup() throws Exception {\n bkEnsemble = new LocalBookkeeperEnsemble(3, 0, () -> 0);\n bkEnsemble.start();\n // Start broker\n ServiceConfiguration config = new ServiceConfiguration();\n config.setLoadManagerClassName(ModularLoadManagerImpl.class.getName());\n config.setClusterName(\"use\");\n config.setWebServicePort(Optional.of(0));\n config.setMetadataStoreUrl(\"zk:127.0.0.1:\" + bkEnsemble.getZookeeperPort());\n\n config.setAdvertisedAddress(\"localhost\");\n config.setBrokerShutdownTimeoutMs(0L);\n config.setLoadBalancerOverrideBrokerNicSpeedGbps(Optional.of(1.0d));\n config.setBrokerServicePort(Optional.of(0));\n config.setBrokerServicePortTls(Optional.of(0));\n config.setWebServicePortTls(Optional.of(0));\n pulsar = new PulsarService(config);\n pulsar.start();\n }", "public void init() {\n configuration.init();\n \n //Connections connections = configuration.getBroker().getConnections(\"topic\");\n Connections connections = configuration.getBrokerPool().getBroker().getConnections(\"topic\");\n \n if (connections == null) {\n handleException(\"Couldn't find the connection factor: \" + \"topic\");\n }\n \n sensorCatalog = new SensorCatalog();\n clientCatalog = new ClientCatalog();\n \n nodeCatalog = new NodeCatalog();\n \n updateManager = new UpdateManager(configuration, sensorCatalog, this);\n updateManager.init();\n \n endpointAllocator = new EndpointAllocator(configuration, nodeCatalog);\n\n registry = new JCRRegistry(this);\n registry.init();\n\n // Initialize Public-End-Point\n if(!isPublicEndPointInit) {\n \tinitPublicEndpoint();\n }\n }", "public static void doConnect() {\r\n\t\tlogger.info(\"Connecting to server......\");\r\n\t\tChannelFuture future = null;\r\n\t\ttry {\r\n\t\t\tfuture = bootstrap.connect(new InetSocketAddress(host, port));\r\n\t\t\tfuture.addListener(channelFutureListener);\r\n\r\n\t\t} catch (Exception e) {\r\n\t\t\te.printStackTrace();\r\n\t\t\t// future.addListener(channelFutureListener);\r\n\t\t\tlogger.warn(\"Closed connection.\");\r\n\t\t}\r\n\r\n\t}", "public void connect() { \t\n \tbindService(IChatService.class, apiConnection);\n }", "public abstract void connectSystem();", "public Zookeeper(Animal[] my_zoo){\n zoo = my_zoo;\n }", "public abstract void connect(JMXServiceURL url, Map<String, Object> env) throws IOException;", "public void connecting() {\n\n }", "public static void main(String[] args) throws Exception {\n \n CuratorFramework client = null;\n ServiceDiscovery<InstanceDetails> serviceDiscovery = null;\n Map<String, ServiceProvider<InstanceDetails>> providers = Maps.newHashMap();\n try {\n client = CuratorFrameworkFactory.newClient(ZkProp.connectionString(),ZkProp.retryPolicy());\n client.start();\n \n JsonInstanceSerializer<InstanceDetails> serializer = new JsonInstanceSerializer<>(InstanceDetails.class);\n serviceDiscovery = ServiceDiscoveryBuilder.builder(InstanceDetails.class).client(client).basePath(PATH).serializer(serializer).build();\n serviceDiscovery.start();\n \n processCommands(serviceDiscovery,providers,client);\n } finally {\n for (ServiceProvider<InstanceDetails> cache : providers.values()) {\n CloseableUtils.closeQuietly(cache);\n }\n \n CloseableUtils.closeQuietly(serviceDiscovery);\n CloseableUtils.closeQuietly(client);\n }\n }", "@Environment\n public static void initialize() throws MarathonException {\n URI zkUri = startZookeeperInstance();\n startBookkeeperInstances(zkUri);\n URI controllerUri = ensureControllerRunning(zkUri);\n ensureSegmentStoreRunning(zkUri, controllerUri);\n }", "public String getZookeeperAdminUrl() {\n return \"http://\" + zookeeper.getHost() + \":\" + zookeeper.getAdminPort();\n }", "public void connect()\r\n\t{\r\n\t\tkonekcija = ConnectionClass.getConnection(adresa, port, imeBaze, korisnickoIme, sifra);\r\n\t\tSystem.out.println(\"Konekcija otvorena: \"+ konekcija.toString());\r\n\t}", "@Override\n public void establishConnectionWithYourTower() {\n }", "public void connect(ConnectionConfig config) {\n connectionManagers.computeIfAbsent(config, connectionManagerFactoryFunction).connect();\n }", "public void connect() {\n aiConfiguration = new AIConfiguration(getClientAccessToken(),\n AIConfiguration.SupportedLanguages.English,\n AIConfiguration.RecognitionEngine.System);\n aiService = AIService.getService(context, aiConfiguration);\n aiService.setListener(this);\n aiDataService = new AIDataService(context, aiConfiguration);\n }", "public void connect() throws Exception\n\t{\n\t\tHostnameVerifier hv = new HostnameVerifier()\n\t\t{\n\t\t\t@Override\n\t\t\tpublic boolean verify(String urlHostName, SSLSession session)\n\t\t\t{\n\t\t\t\treturn true;\n\t\t\t}\n\t\t};\n\t\ttrustAllHttpsCertificates();\n\t\tHttpsURLConnection.setDefaultHostnameVerifier(hv);\n\t\t// These following methods have to be called in this order.\n\t\tinitSvcInstRef();\n\t\tinitVimPort();\n\t\tinitServiceContent();\n\t\tvimPort.login(serviceContent.getSessionManager(), user, password, null);\n\t\tinitPropertyCollector();\n\t\tinitRootFolder();\n\t\tisConnected = true;\n\t}", "private void connectToABBOE() throws IOException, IllegalArgumentsException {\n Socket socket = Biomine3000Utils.connectToServer(args);\n this.connection = new ABBOEConnection(CLIENT_PARAMS, socket, log);\n this.connection.init(new ObjectHandler());\n \n }", "public abstract void connect() throws UnknownHostException, IOException;", "void connect() throws TransportException;", "public ClientCluster(Set<String> masterNames, Set<String> sentinels,\n final GenericObjectPoolConfig poolConfig, int timeout, final String password, final int database) {\n super(masterNames, sentinels, poolConfig, timeout, StringUtils.isBlank(password) ? null : password, database);\n log.info(\"masterNames={},sentinels={}\", masterNames, sentinels);\n init();\n }", "@Override\r\n\tpublic void start() {\n\t\t\r\n\t\tServerAddress serverurl=new ServerAddress(host, port);\r\n\t\tList<ServerAddress> listServer=new ArrayList<ServerAddress>();\r\n\t\tlistServer.add(serverurl);\r\n\t\tMongoCredential credential=MongoCredential.createCredential(user, database, password.toCharArray());\r\n\t\tList<MongoCredential> listCre=new ArrayList<MongoCredential>();\r\n\t\tlistCre.add(credential);\r\n\t\tmongoClient = new MongoClient(listServer, listCre);\r\n\t\tmongoDB = mongoClient.getDatabase(database);\r\n\t\tmongoCollection = mongoDB.getCollection(collection);\r\n\r\n\t}", "private void connect() {\n connectionString = \"jdbc:mysql://\" + Config.getInstance().getMySQLServerName() + \":\" + Config.getInstance().getMySQLServerPort() + \"/\" + Config.getInstance().getMySQLDatabaseName();\n\n try {\n Assassin.p.getLogger().info(\"Attempting connection to MySQL...\");\n\n // Force driver to load if not yet loaded\n Class.forName(\"com.mysql.jdbc.Driver\");\n Properties connectionProperties = new Properties();\n connectionProperties.put(\"user\", Config.getInstance().getMySQLUserName());\n connectionProperties.put(\"password\", Config.getInstance().getMySQLUserPassword());\n connectionProperties.put(\"autoReconnect\", \"false\");\n connectionProperties.put(\"maxReconnects\", \"0\");\n connection = DriverManager.getConnection(connectionString, connectionProperties);\n\n Assassin.p.getLogger().info(\"Connection to MySQL was a success!\");\n }\n catch (SQLException ex) {\n connection = null;\n\n if (reconnectAttempt == 0 || reconnectAttempt >= 11) {\n Assassin.p.getLogger().severe(\"Connection to MySQL failed!\");\n printErrors(ex);\n }\n }\n catch (ClassNotFoundException ex) {\n connection = null;\n\n if (reconnectAttempt == 0 || reconnectAttempt >= 11) {\n Assassin.p.getLogger().severe(\"MySQL database driver not found!\");\n }\n }\n }", "private void connectToNotary() throws RemoteException, InvalidSignatureException {\n\t\tfor (String notaryID : notaryServers.keySet()) {\n\t\t\tNotaryInterface notary = notaryServers.get(notaryID);\n\n\t\t\tString cnonce = cryptoUtils.generateCNonce();\n\t\t\tString toSign = notary.getNonce(this.id) + cnonce + this.id;\n\t\t\tX509Certificate res = notary\n\t\t\t\t.connectToNotary(this.id, cnonce, cryptoUtils.getStoredCert(),\n\t\t\t\t\tcryptoUtils.signMessage(toSign));\n\n\t\t\tcryptoUtils.addCertToList(notaryID, res);\n\t\t}\n\t}", "private ManagedChannel connect() throws InterruptedException {\n for (int i = 0; i < 20; i++) {\n try {\n new Socket().connect(new InetSocketAddress(\"localhost\", 8081));\n break;\n } catch (IOException e) {\n Thread.sleep(500);\n }\n }\n channel = ManagedChannelBuilder.forAddress(\"localhost\", 8081)\n .usePlaintext()\n .build();\n return channel;\n }", "void startClient(String name, Config.ClientConfig config);", "public void init(){\n taskClient.connect(\"127.0.0.1\", 9123);\n }" ]
[ "0.65535915", "0.6385718", "0.63145643", "0.6281462", "0.5802881", "0.57679635", "0.57312566", "0.571811", "0.5712204", "0.5706924", "0.5640846", "0.5588646", "0.5510704", "0.55087674", "0.5497374", "0.53596395", "0.53274554", "0.53133625", "0.5289799", "0.5240368", "0.5237852", "0.5230119", "0.52282596", "0.52258927", "0.52195156", "0.5202792", "0.5192626", "0.5190056", "0.51690114", "0.5164692", "0.515205", "0.5123087", "0.5113835", "0.5093064", "0.5074805", "0.50735974", "0.5068534", "0.5068473", "0.5068473", "0.5068473", "0.50582296", "0.5054584", "0.50541073", "0.5038516", "0.50379044", "0.50356567", "0.5019025", "0.5012495", "0.5005765", "0.50019896", "0.4995265", "0.497782", "0.49675044", "0.49567583", "0.49563885", "0.49553898", "0.49461544", "0.49433446", "0.4936441", "0.49293536", "0.49235252", "0.4913031", "0.49059007", "0.4904052", "0.4887246", "0.48772416", "0.48753136", "0.48751318", "0.4866306", "0.48580864", "0.48495117", "0.4847817", "0.48357117", "0.48350993", "0.48160204", "0.48128086", "0.48110682", "0.48028094", "0.47918454", "0.4782441", "0.47793156", "0.47775328", "0.47762737", "0.47696853", "0.47664258", "0.47615975", "0.4753245", "0.47487614", "0.47430766", "0.473848", "0.47365966", "0.47278237", "0.47244763", "0.47069556", "0.46949285", "0.46821094", "0.46772826", "0.46761677", "0.4666937", "0.46662748" ]
0.66845447
0
/ Calls minimax algorithm to search for a solution using depth or time
public Line miniMax(Board board) throws IOException { currBoard = board; if(tod == 0) { return MiniMax.timeMiniMax(currBoard, tod, prune, getColour(), otherColor); } return MiniMax.depthMiniMax(currBoard, tod, prune, getColour(), otherColor); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private Leaf minimax(AI_Domain game,boolean turn,int depth, boolean flag,String path) {\r\n\t\t\t\r\n\t\t\t// if the depth is zero or the game is over,\r\n\t\t\t// return the heuristic value of this state\r\n\t\t\tif(depth == 0 || game.gameOver()){\r\n\t\t\t\tLeaf L = new Leaf(H.calculateScore(game));\r\n\t\t\t\tL.insertPath(path);\r\n\t\t\t\treturn L;\r\n\t\t\t}\r\n\t\t\t\t\r\n\t\t\t\r\n\t\t\tArrayList<String> moves = new ArrayList<String>();\r\n\t\t\t\r\n\t\t\t// get all the possible moves\r\n\t\t\tmoves = game.allPossibleMoves(turn);\r\n\r\n\t\t\tLeaf val;\r\n\t\t\tLeaf bestVal = new Leaf(0);\r\n\t\t\t\r\n\t\t\t// its the maximizing player turn\r\n\t\t\tif(turn) {\r\n\t\t\t\t// \tset the best value to be 0 (minus infinity)\r\n\t\t\t\t\tbestVal.setValue(0);\r\n\t\t\t\t\r\n\t\t\t\t// for each possible move\r\n\t\t\t\tfor(String str : moves){\r\n\t\t\t\t\t\r\n\t\t\t\t\t//create a copy of the given problem\r\n\t\t\t\t\tAI_Domain copy = game.clone();\t\t\r\n\t\t\t\t\t\r\n\t\t\t\t\t//execute possible move\r\n\t\t\t\t\tcopy.executeCommand(str,\"MiniMax\");\r\n\t\t\t\t\r\n\t\t\t\t\t\t// if it's the first enter to the minimax :\r\n\t\t\t\t\t\t// set the path of the this root to be the first move that executed\r\n\t\t\t\t\t\t// and lead to the next leaves\r\n\t\t\t\t\t\tif(flag) {\r\n\t\t\t\t\t\t\tpath = str;\r\n\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t//recursive check the best move for the copied problem after executed the move\r\n\t\t\t\t\t\t\tval = minimax(copy,!turn,depth-1,false,path);\r\n\t\t\t\t\t\t\t// set the bestval to be the move that has higher heuristic score\r\n\t\t\t\t\t\t\tif( val.getValue() >= bestVal.getValue())\r\n\t\t\t\t\t\t\t\tbestVal = val.clone();\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t// not the first time entered to minimax\r\n\t\t\t\t\t\telse {\r\n\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t//recursive check the best move for the copied problem after executed the move\r\n\t\t\t\t\t\t\tval = minimax(copy,!turn,depth-1,false,path);\r\n\t\t\t\t\t\t\t// set the bestval to be the move that has higher heuristic score\r\n\t\t\t\t\t\t\tif( val.getValue() >= bestVal.getValue())\r\n\t\t\t\t\t\t\tbestVal = val.clone();\r\n\t\r\n\t\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\r\n\t\t\t}\r\n\t\t\t\t// it's the other player turn\r\n\t\t\t else { \r\n\t\t\t\t // set the best value to be plus infinity\r\n\t\t\t\t\tbestVal.setValue(Integer.MAX_VALUE-1);\r\n\t\t\t\t\tfor(String str : moves){\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t//create a copy of the given problem\r\n\t\t\t\t\t\tAI_Domain copy = game.clone();\r\n\t\t\t\t\t\t//execute possible move\r\n\t\t\t\t\t\tcopy.executeCommand(str,\"MiniMax\");\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t//recursive check the best move for the copied problem after executed the move\r\n\t\t\t\t\t\tval = minimax(copy,!turn,depth-1,false,path);\r\n\t\t\t\t\t\t// we assume that the other player will try to maximize his score too\r\n\t\t\t\t\t\t//and therefore it will minimize our score\r\n\t\t\t\t\t\tif(val.getValue() < bestVal.getValue())\r\n\t\t\t\t\t\t bestVal = val.clone();\r\n\r\n\t\t\t \t}\t\r\n\t\t\t }\r\n\t\t\t\r\n\t\t\t\r\n\t\t\treturn bestVal;\t\t\r\n\t}", "private Pair<Double, Move> minimax(OthelloBoard board, OthelloSide side, int depth, int max_depth, \n\t\t\t\t\t\t\t\tMove m, double alpha, double beta) {\n\t\tdouble bestScore;\n\t\tint turncount = turn;\n\t\tMove bestMove;\n\t\t//System.out.println(\"Start of minimax. Depth: \" + depth + \" Side: \" + side);\n\t /* int state = board.getState();\n\t\tif (state == OthelloBoard.DRAW)\n\t return new Pair<Double, Move>(0, m);\n\t if ((state == OthelloBoard.BLACK_WINS) && (side == OthelloSide.BLACK)) \n\t return new Pair<Double, Move>(Double.POSITIVE_INFINITY, m); \n\t if ((state == OthelloBoard.WHITE_WINS) && (side == OthelloSide.WHITE))\n\t return new Pair<Double, Move>(Double.POSITIVE_INFINITY, m);\n\t if ((state == OthelloBoard.BLACK_WINS) && (side == OthelloSide.WHITE))\n\t return new Pair<Double, Move>(Double.NEGATIVE_INFINITY, m);\n\t if ((state == OthelloBoard.WHITE_WINS) && (side == OthelloSide.BLACK))\n\t return new Pair<Double, Move>(Double.NEGATIVE_INFINITY, m);*/\n\t\tif(board.isDone()) {\n\t\t\tdouble endgame = board.countBlack() - board.countWhite();\n\t\t\treturn new Pair<Double, Move>(endgame, m);\n\t\t}\n\t\tif(depth == max_depth) {\n\t\t\tdouble mdScore = evaluator(board, side);\n\t\t\treturn new Pair<Double, Move>(mdScore, m);\t\t\t\n\t\t} else {\n\t\t\tLinkedList<Move> moveList = getMoveList(board, side);\n\t\t\tif(depth == 0) {\n\t \t\t\tLinkedList<Move> corners = new LinkedList<Move>();\n\t\t\t\tfor(Move mv : moveList) {\n\t\t\t\t\tif(board.isCorner(mv)) {\n\t\t\t\t\t\tcorners.add(mv);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tif(corners.size() != 0) {\n\t\t\t\t\tMove bcorner = null;\n\t\t\t\t\tdouble best = -Double.MAX_VALUE;\n\t\t\t\t\tfor(Move ml : corners) {\n\t\t\t\t\t\tdouble temp = evalMove(board, side, ml);\n\t\t\t\t\t\tif(temp > best) {\n\t\t\t\t\t\t\tbest = temp;\n\t\t\t\t\t\t\tbcorner = ml;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\treturn new Pair<Double, Move>(best, bcorner);\n\t\t\t\t}\n\t\t\t}\n\t\t\t//System.out.println(moveList.toString());\n\t\t\tbestScore = -Double.MAX_VALUE;\n\t\t\tbestMove = new Move(1,1);\n\t\t\tif(moveList.size() == 0) {\n\t\t\t\tdouble mdScore = evaluator(board, side);\n\t\t\t\treturn new Pair<Double, Move>(mdScore, m);\n\t\t\t} else {\n\t\t\t\tfor(int i = 0; i < moveList.size(); i++) {\n\t\t\t\t\tOthelloBoard tempBoard = board.copy();\n\t\t\t\t\tMove move = moveList.get(i);\n\t\t\t\t\ttempBoard.move(move, side);\n\t\t\t\t\talpha = -(minimax(tempBoard, side.opposite(), depth + 1, max_depth, move, -beta, -alpha)).score;\n\t\t\t\t\t//System.out.println(\"Side: \" + side);\n\t\t\t\t\t//System.out.println(\"alpha (before IF): \" + alpha);\n\t\t\t\t\t//System.out.println(\"bestScore (before IF): \" + bestScore);\n\t\t\t\t\tif(beta <= alpha) {\n\t\t\t\t\t\treturn new Pair<Double, Move>(alpha, move);\n\t\t\t\t\t}\n\t\t\t\t\tif(alpha > bestScore ) {\n\t\t\t\t\t\tbestScore = alpha;\n\t\t\t\t\t\tbestMove = move;\n\t\t\t\t\t\t//bestMove.copy(move);\n\t\t\t\t\t\t//System.out.println(\"theScore(IF): \" + alpha);\n\t\t\t\t\t\t//System.out.println(\"bestScore(IF): \" + bestScore);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\treturn new Pair<Double, Move>(bestScore, bestMove);\n\t\t\t}\n\t\t}\n\t}", "private List<Double> MinimaxAlgorithm(MinimaxNode<GameState> node, int dataCount){\n if(node.getNumberOfChildren() == 0){ //checks to see if terminal node\n List<Double> heuristics = new ArrayList();\n heuristics.addAll(calculateHeuristic(node.getState()));\n return heuristics;\n }\n else{ //will maximise all the scores for each player.\n double value = Double.NEGATIVE_INFINITY;\n double checkValue;\n int bestMove;\n List<Double> heuristics = new ArrayList();\n if(node.getIfChanceNode()){ //checks if current node is a chance node, if so, times \n for (int i = 0; i < node.getChildren().size(); i++){\n List<Double> tempHeuristics = new ArrayList();\n tempHeuristics.addAll(MinimaxAlgorithm(node.getChildren().get(i),dataCount+1));\n checkValue = node.getChildren().get(i).getProbability() * tempHeuristics.get(node.getNodeIndex());\n value = Math.max(value, checkValue);//maximises the score.\n if(checkValue == value){\n heuristics.addAll(tempHeuristics); \n }\n if(dataCount == 0){//checks if this is the root node\n if(checkValue == value){\n MinimaxPlayer.optimalMoves = node.getChildren().get(i).getState().getOrientation(node.getNodeIndex()); \n }\n } \n }\n }\n else{\n for (int i = 0; i < node.getChildren().size(); i++){\n List<Double> tempHeuristics = new ArrayList();\n tempHeuristics.addAll(MinimaxAlgorithm(node.getChildren().get(i),dataCount+1));\n checkValue = tempHeuristics.get(node.getNodeIndex());\n value = Math.max(value, checkValue);//maximises the score.\n if(checkValue == value){\n heuristics.addAll(tempHeuristics); \n }\n if(dataCount == 0){//checks if this is the root node\n if(checkValue == value){\n MinimaxPlayer.optimalMoves = node.getChildren().get(i).getState().getOrientation(node.getNodeIndex()); \n }\n } \n } \n }\n return heuristics;\n } \n }", "public int minimax(Tile[][] board, int depth, boolean isMaximizing) {\n int result = WinnerChecker.checkWinner();\r\n if(result != 2) {\r\n return result;\r\n }\r\n\r\n int bestScore = 0;\r\n if(isMaximizing){\r\n bestScore = 1;\r\n for(int i = 0; i< 3; i++){\r\n for(int j = 0; j< 3; j++){\r\n // Is the spot available?\r\n if(board[i][j].text.getText().isEmpty()){\r\n board[i][j].text.setText(\"O\");\r\n TicTacToeApp.previous_move = board[i][j];\r\n int score = minimax(board, depth+1,false);\r\n board[i][j].text.setText(\"\");\r\n bestScore = Math.min(score, bestScore);\r\n }\r\n }\r\n }\r\n }else{\r\n bestScore = -1;\r\n for(int i = 0; i< 3; i++){\r\n for(int j = 0; j< 3; j++){\r\n // Is the spot available?\r\n if(board[i][j].text.getText().isEmpty()){\r\n board[i][j].text.setText(\"X\");\r\n TicTacToeApp.previous_move = board[i][j];\r\n int score = minimax(board, depth+1,true);\r\n board[i][j].text.setText(\"\");\r\n bestScore = Math.max(score, bestScore);\r\n }\r\n }\r\n }\r\n }\r\n return bestScore;\r\n }", "public static Pair<Integer, PentagoMove> miniMaxAlgo(PentagoBoardState boardState, int depth, int playerTurn) {\n\t\t\n\t\tArrayList<PentagoMove> possibleMoves = boardState.getAllLegalMoves();\n\t\tint score = 0;\n\t\t\n\t\t//assign a high or low value to begin with, no move can have that high/low a value\n\t\tif (playerTurn == 1) {\n\t\t\tscore = Integer.MIN_VALUE;\n\t\t}\n\t\telse {\n\t\t\tscore = Integer.MAX_VALUE;\n\t\t}\n\t\t\n\t\tint currentScore;\n\t\tPentagoMove chosenMove = null;\n\t\t\n\t\t//when all moves have been propagated up to the depth desired, find the most valuated move\n\t\tif (possibleMoves.size() == 0 || depth == 0) {\n\t\t\tscore = heuristic(boardState);\n\t\t}\n\t\telse {\n\t\t\t//iterating through all possible moves\n\t\t\tfor(int i = 0; i < possibleMoves.size(); i++) {\n\t\t\t\t\n\t\t\t\t//cloning board to predict 2 moves ahead (depth is 2)\n\t\t\t\tPentagoBoardState clone = (PentagoBoardState) boardState.clone();\n\t\t\t\tclone.processMove(possibleMoves.get(i));\n\t\t\t\tint player = 1 - playerTurn;\n\t\t\t\t\n\t\t\t\t//0 = white, trying to maximize\n\t\t\t\tif (player == 0) {\n\t\t\t\t\t\n\t\t\t\t\t//if a found score is higher, make it the new current score, then use minimize at the lower depth\n\t\t\t\t\t//player will be \"swapped\" (if opponent is current player, we'll simulate the player's turn) when making the recursive call\n\t\t\t\t\tcurrentScore = miniMaxAlgo(clone, depth - 1, player).getKey();\n\t\t\t\t\t\n\t\t\t\t\tif (currentScore >= score) {\n\t\t\t\t\t\tchosenMove = possibleMoves.get(i);\n\t\t\t\t\t\tscore = currentScore;\n\t\t\t\t\t}\n\t\t\t\t} \n\t\t\t\t\n\t\t\t\t//1 = black, trying to minimize\n\t\t\t\telse if (player == 1) {\n\t\t\t\t\t\n\t\t\t\t\t//if a found score is lower, make it the new current score, then use maximize at the lower depth\n\t\t\t\t\t//player will be \"swapped\" (if opponent is current player, we'll simulate the player's turn) when making the recursive call\n\t\t\t\t\tcurrentScore = miniMaxAlgo(clone, depth - 1, player).getKey();\n\t\t\t\t\t\n\t\t\t\t\tif (currentScore <= score) {\n\t\t\t\t\t\tchosenMove = possibleMoves.get(i);\n\t\t\t\t\t\tscore = currentScore;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t//decided to go with pair to avoid having separated methods for the score and the move\n\t\t//it is easy to extract the required value using .getKey() or .getValue()\n\t\tPair<Integer, PentagoMove> answer = new Pair<>(score, chosenMove);\n\t\treturn answer;\n\t}", "public void solve() {\n// BruteForceSolver bfs = new BruteForceSolver(pointList);\n// bfs.solve(); // prints the best polygon, its area, and time needed\n// System.out.println(\"-------------\");\n\n// StarshapedSolver ss = new StarshapedSolver(pointList);\n// foundPolygons = ss.solve();\n// System.out.println(\"-------------\");\n\n// RandomAddPointHeuristic ra = new RandomAddPointHeuristic(pointList);\n// foundPolygons = ra.solve(750);\n// System.out.println(\"-------------\");\n\n// GreedyAddPointHeuristic ga = new GreedyAddPointHeuristic(pointList,false);\n// foundPolygons = ga.solve(750);\n// System.out.println(\"-------------\");\n\n// long time = 4000;\n// GreedyAddPointHeuristic gaInit = new GreedyAddPointHeuristic(pointList,false);\n// Polygon2D initSolution = gaInit.solve(time*1/4).get(0);\n// System.out.println(initSolution.area);\n// System.out.println(initSolution);\n//\n// SimulatedAnnealing sa = new SimulatedAnnealing(pointList,initSolution,3);\n// foundPolygons.addAll(sa.solve(time-gaInit.timeInit,2,0.005,0.95));\n// System.out.println(sa.maxPolygon);\n// System.out.println(\"-------------\");\n\n// foundPolygons.addAll(findMultiplePolygonsStarshaped(8,0.6));\n\n }", "private int optimize() {\n\t\t// items: Items sorted by value-to-weight ratio for linear relaxation\n\t\t// t: the decision vector being tested at each node\n\t\t// ws, vs, is, bs: stacks of weight, value, item id, whether bring item\n\t\t// p: stack pointer; i, b, weight, value: loop caches; best: max search\n\t\t// ss: stack size: Always <=2 children on stack for <=n-1 parents\n\t\tItem[] items = new Item[n];\n\t\tint ss = 2 * n;\n\t\tint[] itemsSorted = new int[n], t = new int[n], ws = new int[ss],\n\t\t\tvs = new int[ss], is = new int[ss], bs = new int[ss];\n\t\tint i, b, weight, value, best = 0, p = 0;\n\n\t\tfor (int j = 0; j < n; j++)\n\t\t\titems[j] = new Item(j);\n\t\tArrays.sort(items);\n\t\tfor (int j = 0; j < n; j++)\n\t\t\titemsSorted[j] = items[j].i();\n\t\titems = null; // For garbage collection.\n\n\t\t// Push item 0 onto the stack with and without bringing it.\n\t\tws[p] = 0; vs[p] = 0; is[p] = 0; bs[p] = 1; p++;\n\t\tws[p] = 0; vs[p] = 0; is[p] = 0; bs[p] = 0; p++;\n\n\t\twhile (p > 0) {\n\t\t\tp--; // Pop the latest item off the stack\n\t\t\ti = is[p]; b = bs[p];\n\t\t\tweight = ws[p] + w[i] * b;\n\t\t\tif (weight > k)\n\t\t\t\tcontinue;\n\t\t\tvalue = vs[p] + v[i] * b;\n\t\t\tif (bound(i, weight, value, itemsSorted) < best)\n\t\t\t\tcontinue;\n\t\t\tbest = Math.max(value, best);\n\t\t\tt[i] = b;\n\t\t\tif (i < n - 1) { // Push children onto stack w/ & w/o bringing item\n\t\t\t\tws[p] = weight; vs[p] = value; is[p] = i + 1; bs[p] = 1; p++;\n\t\t\t\tws[p] = weight; vs[p] = value; is[p] = i + 1; bs[p] = 0; p++;\n\t\t\t}\n\t\t\telse if (value >= best)\n\t\t\t\tSystem.arraycopy(t, 0, x, 0, n);\n\t\t}\n\t\treturn best;\n\t}", "private double minimax(int depth, boolean isMaximizingPlayer, double alpha, double beta) {\n // Check the hashmap for this board\n if (this.hashMap.containsKey(this.game.hashCode())) {\n try {\n double value = this.hashMap.get(this.game.hashCode());\n this.hashMapHits += 1;\n return value;\n } catch (NullPointerException ex) {\n System.out.println(\"Minimax - hashmap error\");\n }\n }\n\n // Base case\n if (depth == 0) {\n double value = -BoardEvaluator.evaluate(player, this.game.getBoard());\n this.hashMap.put(this.game.hashCode(), value);\n return value;\n }\n\n List<Move> moves = this.game.getValidMoves(this.game.getActivePlayer());\n\n if (isMaximizingPlayer) {\n double bestValue = Double.NEGATIVE_INFINITY;\n for (Move move : moves) {\n this.game.executeMove(move, false);\n this.game.endTurn(false);\n bestValue = Math.max(bestValue, minimax(depth - 1, !isMaximizingPlayer, alpha, beta));\n this.game.undoMove(move, false);\n this.game.endTurn(false);\n this.moveCount += 1;\n\n alpha = Math.max(alpha, bestValue);\n\n // Alpha-Beta pruning\n if (beta <= alpha) {\n break;\n }\n }\n return bestValue;\n } else {\n double bestValue = Double.POSITIVE_INFINITY;\n for (Move move : moves) {\n this.game.executeMove(move, false);\n this.game.endTurn(false);\n bestValue = Math.min(bestValue, minimax(depth - 1, !isMaximizingPlayer, alpha, beta));\n this.game.undoMove(move, false);\n this.game.endTurn(false);\n this.moveCount += 1;\n\n beta = Math.min(beta, bestValue);\n\n // Alpha-Beta pruning\n if (beta <= alpha) {\n break;\n }\n }\n return bestValue;\n }\n }", "public static int applyMinMax(int d, BoardModel model, boolean maximizingTeam, int alpha, int beta, boolean whiteTeam, int startDepth) {\n //base case, figure out determinaion of game over\n\n // printMap(model);\n // System.out.println(\"Depth: \"+d);\n \n\n //allPossibleMoves moveTree = new allPossibleMoves();\n int[] currentQueen;\n ArrayList<int[]> whiteQueens = new ArrayList<>();\n ArrayList<int[]> blackQueens = new ArrayList<>();\n ArrayList<int[]> myQueens = new ArrayList<>();\n // possibleMove bestestMove = null;\n\n// for (int count = 0; count < model.queenPositions.size(); count++) {\n// if (model.getTile(model.queenPositions.get(count)).equals(POS_MARKED_BLACK)) {\n// blackQueens.add(model.queenPositions.get(count));\n// // System.out.println(\"Black: \"+model.getTile(model.queenPositions.get(count)));\n// } else {\n// whiteQueens.add(model.queenPositions.get(count));\n// // System.out.println(\"White: \"+model.getTile(model.queenPositions.get(count)));\n// }\n// }\n//set black and white queens \n for (int jam = 0; jam < 10; jam++) {\n for (int pb = 0; pb < 10; pb++) {\n if (model.getTile(new int[]{jam, pb}).equals(POS_MARKED_WHITE)) {\n whiteQueens.add(new int[]{jam, pb});\n }\n if (model.getTile(new int[]{jam, pb}).equals(POS_MARKED_BLACK)) {\n blackQueens.add(new int[]{jam, pb});\n }\n }\n }\n if (maximizingTeam){\n if (whiteTeam){\n myQueens = whiteQueens;\n }\n else{\n myQueens = blackQueens;\n }\n }\n if (!maximizingTeam){\n if (whiteTeam){\n myQueens = blackQueens;\n }\n else{\n myQueens = whiteQueens;\n }\n }\n \n if (d == 0 || findAllMoves(model,myQueens).isEmpty() ) {\n return baseCase(model, whiteTeam);\n }\n\n // System.out.println(\"White Queens identified as: \" + whiteQueens.get(0)[0] + \"\" + whiteQueens.get(0)[1] + \" \" + whiteQueens.get(1)[0] + whiteQueens.get(1)[1] + \" \" + whiteQueens.get(2)[0] + whiteQueens.get(2)[1] + \" \" + whiteQueens.get(3)[0] + whiteQueens.get(3)[1]);\n //if (whiteTeam) {\n // myQueens = whiteQueens;\n //} else {\n // myQueens = blackQueens;\n // }\n // perform a check to see which side we are on. \n // System.out.println(\"Status: \"+maximizingTeam);\n if (maximizingTeam) {\n // System.out.println(\"Maximizing turn\");\n if (whiteTeam) {\n myQueens = whiteQueens;\n } else {\n myQueens = blackQueens;\n }\n\n int maxEval = -1000000;\n // considering this move was played. \n\n // printMap(model);\n // System.out.println();\n //find all children from this state\n ArrayList<ArrayList<int[]>> children = findAllMoves(model, myQueens);\n if (children.size() == 0){\n return baseCase(model, whiteTeam);\n }\n if(children.size()==0 && d == startDepth){\n System.out.println(\"We Lost :( \");\n }\n // printMap(model);\n // System.out.println();\n for (int i = 0; i < children.size(); i++) {\n\n String m1 = stringMap(model);\n\n BoardModel recursionModel = new BoardModel(10);\n\n for (int jam = 0; jam < 10; jam++) {\n for (int pb = 0; pb < 10; pb++) {\n recursionModel.setTile(new int[]{jam, pb}, model.getTile(new int[]{jam, pb}));\n }\n }\n recursionModel.queenPositions = new ArrayList<>();\n for (int x = 0; x < model.queenPositions.size(); x++) {\n recursionModel.queenPositions.add(model.queenPositions.get(x));\n }\n\n // printMap(recursionModel);\n recursionModel.moveQueen(children.get(i).get(0), children.get(i).get(1));\n recursionModel.setTile(children.get(i).get(2), POS_MARKED_ARROW);\n // System.out.println(\"max recursive call\");\n int childVal = applyMinMax(d - 1, recursionModel, false, alpha, beta, whiteTeam, startDepth);\n recursionModel.moveQueen(children.get(i).get(1), children.get(i).get(0));\n recursionModel.setTile(children.get(i).get(2), POS_AVAILABLE);\n\n String m2 = stringMap(model);\n // System.out.println(\"Check board Validity Max: \"+m1.equals(m2));\n\n maxEval = max(maxEval, childVal);\n if (d == startDepth) {\n ArrayList<int[]> blah = new ArrayList<int[]>();\n blah.add(children.get(i).get(0));\n blah.add(children.get(i).get(1));\n blah.add(children.get(i).get(2));\n blah.add(new int[]{childVal});\n maxMinMoves.add(blah);\n }\n alpha = max(maxEval, alpha);\n // System.out.println(\"A: \"+alpha);\n if (alpha >= beta) {\n break;\n }\n }\n return maxEval;\n\n } else {\n // System.out.println(\"Minimizing turn\");\n if (!whiteTeam) {\n myQueens = whiteQueens;\n } else {\n myQueens = blackQueens;\n }\n\n int maxEval = 1000000;\n // considering this move was played. \n\n // printMap(model);\n // System.out.println();\n //find all children from this state\n ArrayList<ArrayList<int[]>> children = findAllMoves(model, myQueens);\n if (children.size() == 0){\n return baseCase(model, whiteTeam);\n }\n if(children.size()==0 && d == startDepth){\n System.out.println(\"We Lost :( \");\n }\n // printMap(model);\n // System.out.println();\n for (int i = 0; i < children.size(); i++) {\n\n String m1 = stringMap(model);\n\n BoardModel recursionModel = new BoardModel(10);\n\n for (int jam = 0; jam < 10; jam++) {\n for (int pb = 0; pb < 10; pb++) {\n recursionModel.setTile(new int[]{jam, pb}, model.getTile(new int[]{jam, pb}));\n }\n }\n recursionModel.queenPositions = new ArrayList<>();\n for (int x = 0; x < model.queenPositions.size(); x++) {\n recursionModel.queenPositions.add(model.queenPositions.get(x));\n }\n\n // printMap(recursionModel);\n recursionModel.moveQueen(children.get(i).get(0), children.get(i).get(1));\n recursionModel.setTile(children.get(i).get(2), POS_MARKED_ARROW);\n // System.out.println(\"min recursive call\");\n int childVal = applyMinMax(d - 1, recursionModel, true, alpha, beta, whiteTeam, startDepth);\n recursionModel.moveQueen(children.get(i).get(1), children.get(i).get(0));\n recursionModel.setTile(children.get(i).get(2), POS_AVAILABLE);\n\n String m2 = stringMap(model);\n // System.out.println(\"Check board Validity Max: \"+m1.equals(m2));\n\n maxEval = min(maxEval, childVal);\n if (d == startDepth) {\n ArrayList<int[]> blah = new ArrayList<int[]>();\n blah.add(children.get(i).get(0));\n blah.add(children.get(i).get(1));\n blah.add(children.get(i).get(2));\n blah.add(new int[]{childVal});\n maxMinMoves.add(blah);\n }\n beta = min(maxEval, alpha);\n // System.out.println(\"A: \"+alpha);\n if (alpha >= beta) {\n break;\n }\n }\n return maxEval;\n }\n\n }", "private static List<Move> pathSolve(Level level){\n\t\tOptimisticMap optMap = new OptimisticMap(level);\n\t\t\n\t\tPoint dst = level.getExitPos();\n\t\t\n\t\t// Open nodes\n\t\tSortedMap<Integer, List<SolveNode>> nodes = new TreeMap<Integer, List<SolveNode>>();\n\t\t\n\t\t// Current costs to arrive to solve nodes\n\t\tint[][][] arrived = new int[level.getMapSize().x][level.getMapSize().y][Move.values().length];\n\t\tfor ( int x = 0 ; x < level.getMapSize().x ; x++ ){\n\t\t\tfor ( int y = 0 ; y < level.getMapSize().y ; y++ ){\n\t\t\t\tfor ( int d = 0 ; d < Move.values().length ; d++ ){\n\t\t\t\t\tarrived[x][y][d] = Integer.MAX_VALUE;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t\n\t\t// Create initial nodes\n\t\t{\n\t\t\tPoint box = level.getBoxPos();\n\t\t\tPoint player = level.getPlayerPos();\n\t\t\tfor ( Move dir : Move.values()){\n\t\t\t\tPoint playerDst = dir.nextPosition(box);\n\t\t\t\tif ( level.isClearSafe(playerDst.x, playerDst.y)){\n\t\t\t\t\tList<Move> pathNoDesiredPlayerPosition = pathTo(level, player, box, playerDst);\n\t\t\t\t\tif ( pathNoDesiredPlayerPosition != null ){\n\t\t\t\t\t\tSolveNode node = new SolveNode();\n\t\t\t\t\t\tnode.moves = pathNoDesiredPlayerPosition;\n\t\t\t\t\t\tnode.box = (Point)box.clone();\n\t\t\t\t\t\tnode.playerDir = dir;\n\t\t\t\t\t\taddSolveNode(nodes, node, node.moves.size() + optMap.getValue(node.box.x, node.box.y));\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t\n\t\twhile ( nodes.isEmpty() == false ){\n\t\t\t// Get node to process\n\t\t\tSolveNode node = removeSolveNode(nodes);\n\t\t\tif ( node.box.equals(dst) ){\n\t\t\t\t// This is the best solution\n\t\t\t\treturn node.moves;\n\t\t\t}\n\t\t\t\n\t\t\t// Create new nodes trying to move the box in each direction\n\t\t\tfor ( Move dir : Move.values() ){\n\t\t\t\tSolveNode newNode = new SolveNode();\n\t\t\t\tnewNode.box = dir.nextPosition(node.box);\n\t\t\t\tnewNode.playerDir = dir.opposite();\n\t\t\t\t\n\t\t\t\t// First check if the box can be moved to that position (is clear)\n\t\t\t\tif ( level.isClearSafe(newNode.box.x, newNode.box.y) == false ){\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t// Check if the player can move to the pushing position\n\t\t\t\tPoint player = node.playerDir.nextPosition(node.box);\n\t\t\t\tPoint playerDst = dir.opposite().nextPosition(node.box);\n\t\t\t\tList<Move> playerMoves = pathTo(level, player, node.box, playerDst);\n\t\t\t\tif ( playerMoves == null ){\n\t\t\t\t\t// The player can't move itself to the pushing position\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t// Check if the cost to arrive to the new node is less that the previous known\n\t\t\t\tif ( node.moves.size() + playerMoves.size() + 1 >= arrived[newNode.box.x][newNode.box.y][dir.index()] ){\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\tSystem.out.println(\"\" + newNode.box.x + \" \" + newNode.box.y);\n\t\t\t\t\n\t\t\t\t// Add the new node to the open nodes\n\t\t\t\tnewNode.moves.addAll(node.moves);\n\t\t\t\tnewNode.moves.addAll(playerMoves);\n\t\t\t\tnewNode.moves.add(dir);\n\t\t\t\taddSolveNode(nodes, newNode, newNode.moves.size() + optMap.getValue(newNode.box.x, newNode.box.y));\n\t\t\t\tarrived[newNode.box.x][newNode.box.y][dir.index()] = newNode.moves.size();\n\t\t\t}\n\t\t}\n\t\t\n\t\t// There is no solution\n\t\treturn null;\n\t}", "public MoveWrapper minimax(GameBoardState gameState, int depth, MoveWrapper alpha, MoveWrapper beta,\n\t\t\tboolean maximizingPlayer) {\n\n\t\tMoveWrapper maxEval = new MoveWrapper(gameState.getLeadingMove(), Integer.MIN_VALUE); // -infinity\n\n\t\tif (gameState.isTerminal() || AgentController.getAvailableMoves(gameState, playerTurn).isEmpty() || depth == 0) {\n\t\t\tnodesExamined++;\n\t\t\tmaxEval.setMoveReward((int) AgentController.getGameEvaluation(gameState, playerTurn));\n//\t\t\tSystem.out.println(\"in terminal statement \" + maxEval.getMoveReward());\n\t\t\treturn maxEval;\n\t\t}\n\n\t\tif (maximizingPlayer) {\n\n\t\t\tfor (ObjectiveWrapper move : AgentController.getAvailableMoves(gameState, playerTurn)) {\n\t\t\t\tMoveWrapper eval = minimax(AgentController.getNewState(gameState, move), depth - 1, alpha, beta, false);\n\n\t\t\t\tif (eval.getMoveReward() > maxEval.getMoveReward()) { \n\t\t\t\t\tmaxEval.setObjectiveInformation(move);\n\t\t\t\t\tmaxEval.setMoveReward(eval.getMoveReward());\n//\t\t\t\t\tSystem.out.println(\"Player: \" + playerTurn + \"Maximizing - Depth: \" + depth + \", eval value: \" + eval.getMoveReward() + \", maxEval value: \" + maxEval.getMoveReward());\n\t\t\t\t}\n\n\t\t\t\t// alpha beta pruning\n\t\t\t\t if (eval != null && alpha.compareTo(eval) < 0) {\n\t\t\t\t alpha = eval;\n\t\t\t\t }\n\t\t\t\t\n\t\t\t\t if (beta.compareTo(alpha) <= 0) {\n\t\t\t\t prunedCounter++;\n\t\t\t\t break;\n\t\t\t\t }\n\t\t\t}\n\t\t\treturn maxEval;\n\n\t\t} else {\n\t\t\tMoveWrapper minEval = new MoveWrapper(gameState.getLeadingMove(), Integer.MAX_VALUE); // +infinity\n\n\t\t\tfor (ObjectiveWrapper move : AgentController.getAvailableMoves(gameState, GameTreeUtility.getCounterPlayer(playerTurn))) {\n\t\t\t\tMoveWrapper eval = minimax(AgentController.getNewState(gameState, move), depth - 1, alpha, beta, true);\n\n\t\t\t\tif (eval.getMoveReward() < minEval.getMoveReward()) { \n\t\t\t\t\tminEval.setObjectiveInformation(move);\n\t\t\t\t\tminEval.setMoveReward(eval.getMoveReward());\n//\t\t\t\t\tSystem.out.println(\"Player: \" + playerTurn + \"Minimizing - Depth: \" + depth + \", eval value: \" + eval.getMoveReward() + \", minEval value: \" + minEval.getMoveReward());\n\t\t\t\t}\n\n\t\t\t\t// alpha beta pruning\n\t\t\t\t if (eval != null && beta.compareTo(eval) > 0) {\n\t\t\t\t beta = eval;\n\t\t\t\t }\n\t\t\t\t if (beta.compareTo(alpha) <= 0) {\n\t\t\t\t prunedCounter++;\n\t\t\t\t break;\n\t\t\t\t }\n\t\t\t}\n\t\t\treturn minEval;\n\t\t}\n\n\t}", "public Solver(Board initial) {\r\n this.board = initial;\r\n\r\n final Comparator<SearchNode> solverComparator = new Comparator<SearchNode>() {\r\n @Override\r\n public int compare(SearchNode o1, SearchNode o2) {\r\n return o1.weight() - o2.weight();\r\n }\r\n };\r\n MinPQ<SearchNode> pq = new MinPQ<SearchNode>(solverComparator);\r\n MinPQ<SearchNode> twinPq = new MinPQ<SearchNode>(solverComparator);\r\n\r\n pq.insert(new SearchNode(board, null, 0));\r\n twinPq.insert(new SearchNode(board.twin(), null, 0));\r\n do {\r\n SearchNode current = pq.delMin();\r\n SearchNode twin = twinPq.delMin();\r\n\r\n //solution.enqueue(current.getBoard());\r\n if (!current.getBoard().isGoal()) {\r\n for (Board neighbour : current.getBoard().neighbors()) {\r\n if (current.getParent() == null || current.getParent() != null && !neighbour.equals(current.getParent().getBoard())) {\r\n pq.insert(new SearchNode(neighbour, current, current.moves() + 1));\r\n }\r\n }\r\n } else {\r\n solution = new LinkedStack<Board>();\r\n SearchNode node = current;\r\n while (node != null) {\r\n solution.push(node.getBoard());\r\n node = node.getParent();\r\n }\r\n break;\r\n }\r\n\r\n if (!twin.getBoard().isGoal()) {\r\n for (Board neighbour : twin.getBoard().neighbors()) {\r\n if (twin.getParent() == null || twin.getParent() != null && !neighbour.equals(twin.getParent().getBoard())) {\r\n twinPq.insert(new SearchNode(neighbour, twin, twin.moves() + 1));\r\n }\r\n }\r\n } else {\r\n break;\r\n }\r\n } while (!pq.isEmpty() || !twinPq.isEmpty());\r\n }", "private int alphaBetaMinimax (GameTreeNode node, int alpha, int beta, boolean isMax, Map<GameTreeNode, Integer> visited) {\n\n if(node.remaining == 0) {\n //System.out.println(\"Terminal State: Up : Score \" + node.score);\n return node.score;\n }\n if(visited.containsKey(node)) {\n //System.out.println(\"Memoized State: Up : Score \" + visited.get(node));\n return visited.get(node);\n }\n \n \n if(isMax) {\n int minimaxScore = Integer.MIN_VALUE;\n for(int i = 0; i < MAX_REMOVAL; i++) {\n \n GameTreeNode expandingChild = node.generateChild(1 + i);\n \n if(expandingChild == null) {\n break;\n }\n \n //System.out.println(\"Remaining \" + node.remaining + \" Down\");\n //\n minimaxScore = Math.max(minimaxScore, alphaBetaMinimax(expandingChild, alpha, beta, false, visited));\n alpha = Math.max(alpha, minimaxScore);\n //\n //System.out.println(\"Remaining \" + node.remaining + \" Up : Score: \" + minimaxScore);\n //\n if(beta <= alpha) {\n //System.out.println(\"Pruning: \" + node.remaining + \" child index \" + i+1);\n break;\n }\n }\n visited.put(node, minimaxScore);\n node.score = minimaxScore;\n return minimaxScore;\n }\n else {\n int minimaxScore = Integer.MAX_VALUE;\n for(int i = 0; i < MAX_REMOVAL; i++) {\n \n GameTreeNode expandingChild = node.generateChild(1 + i);\n if(expandingChild == null) {\n break;\n }\n //\n \n //\n //System.out.println(\"Remaining \" + node.remaining + \" Down\");\n //\n minimaxScore = Math.min(minimaxScore, alphaBetaMinimax(expandingChild, alpha, beta, true, visited));\n beta = Math.min(beta, minimaxScore);\n //\n //System.out.println(\"Remaining \" + node.remaining + \" Up : Score: \" + minimaxScore);\n //\n if(beta <= alpha) {\n //System.out.println(\"Pruning: \" + node.remaining + \" child index \" + i+1);\n break;\n }\n }\n visited.put(node, minimaxScore);\n node.score = minimaxScore;\n return minimaxScore;\n }\n }", "private void findBestPath(){\n\t\t// The method will try to find the best path for every starting point and will use the minimum\n\t\tfor(int start = 0; start < this.getDimension(); start++){\n\t\t\tfindBestPath(start);\t\n\t\t}\t\n\t}", "@Override\n\tpublic void solve() {\n\t\tlong startTime = System.nanoTime();\n\n\t\twhile(!unvisitedPM.isEmpty()){\n\t\t\tProblemModel current = findCheapestNode();\n\t\n\t\t\tfor(ProblemModel pm : current.getSubNodes()){\n\t\t\n\t\t\t\tif(!visited.contains(pm) && !unvisitedPM.contains(pm)){\n\t\t\t\t\t\n\t\t\t\t\tunvisitedPM.add(pm);\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\n\t\t\t}\n\t\t\t\n\t\t\tif(current.getSideStart().isEmpty()){\n\t\t\t\tSystem.out.print( \"\\n\"+ \"StartSide Runners: \");\n\t\t\t\tfor(Integer r: current.getSideStart()){\n\t\t\t\t\tSystem.out.print( \" \" +r) ;\n\t\t\t\t}\n\t\t\t\tSystem.out.print( \"\\n\" + \"EndSide Runners: \");\n\t\t\t\tfor(Integer r: current.getSideEnd()){\n\t\t\t\t\tSystem.out.print( \" \" + r);\n\t\t\t\t}\n\n\t\t\t\tprintPathTaken(current);\n\t\t\t\tSystem.out.print( \"\\n\" + \"------------done--------------\");\n\t\t\t\tlong endTime = System.nanoTime();\n\t\t\t\tlong duration = ((endTime - startTime)/1000000);\n\t\t\t\tSystem.out.print( \"\\n\" + \"-AS1 Time taken: \" + duration + \"ms\");\n\t\t\t\t\n\t\t\t\t\n\t\t\t\tbreak;\n\t\t\t}\n\t\t\t\n\t\t\tvisited.add(current);\n\t\t\n\t\t}\n\t\t\n\n\t}", "public static PentagoMove excecuteMiniMax(PentagoBoardState bs, int depth) {\n\t\tlong timerStart = System.currentTimeMillis();\n\t\tPentagoMove bestMove = null;\n\t\tint highestVal = Integer.MIN_VALUE;\n\t\tint lowestVal = Integer.MAX_VALUE;\n\t\tint currentVal = 0;\n\t\tint possibleMoves = bs.getAllLegalMoves().size();\n\t\tfor (PentagoMove move : bs.getAllLegalMoves()) {\n\t\t\tPentagoBoardState stateClone = (PentagoBoardState) bs.clone();\n\t\t\tstateClone.processMove(move);\n\t\t\tif(bs.getTurnPlayer() == 0) {\n\t\t\t\tMax(stateClone, depth-1);\n\t\t\t}\n\t\t\telse if(bs.getTurnPlayer() == 1) {\n\t\t\t\tMin(stateClone, depth-1);\n\t\t\t}\n\t\t\tif (bs.getTurnPlayer() == 0 && currentVal >= highestVal) {\n\t\t\t\thighestVal = currentVal;\n\t\t\t\tbestMove = move;\n\t\t\t}\n\t\t\telse if (bs.getTurnPlayer() == 1 && currentVal <= lowestVal) {\n\t\t\t\tlowestVal = currentVal;\n\t\t\t\tbestMove = move;\n\t\t\t}\n\t\t\tif (System.currentTimeMillis() - timerStart >= 1900) {\n\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\t\tlong totalTime = System.currentTimeMillis() - timerStart;\n\t\tSystem.out.println(totalTime);\n\t\treturn bestMove;\n\t}", "private void GreedySearch(){\n\n Queue<Node> expanded = new LinkedList<>();\n ArrayList<Node> fringe = new ArrayList<>();\n ArrayList<Node> fringeTemp = new ArrayList<>();\n\n\n Node current = startNode;\n\n while(expanded.size() < 1000){\n\n if(current.getDigit().getDigitString().equals(goalNode.getDigit().getDigitString())){\n //goal is reached.\n solutionPath(current);\n expanded.add(current);\n printExpanded(expanded);\n System.exit(0);\n }\n\n\n boolean b = cycleCheck(current,expanded);\n\n if(!b) {\n expanded.add(current);\n }\n\n if(!b){\n\n if(current.getDigit().last_changed != 0){\n\n if ((Integer.parseInt(current.getDigit().getFirst_digit()) - 1 >= 0)) {\n Node child_node = new Node(current.getDigit().decreaseFirstDigit());\n child_node.setParent(current);\n child_node.getDigit().setLastChanged(0);\n\n if(!forbidden.contains(child_node.getDigit().getDigitString())){\n fringe.add(child_node);\n }\n }\n\n //+1 child first digit\n if ((Integer.parseInt(current.getDigit().getFirst_digit()) + 1 <= 9)) {\n Node child_node = new Node(current.getDigit().increaseFirstDigit());\n child_node.setParent(current);\n child_node.getDigit().setLastChanged(0);\n if(!forbidden.contains(child_node.getDigit().getDigitString())){\n fringe.add(child_node);\n }\n\n }\n }\n\n if(current.getDigit().last_changed != 1){\n\n if ((Integer.parseInt(current.getDigit().getSecond_digit()) - 1 >= 0)) {\n Node child_node = new Node(current.getDigit().decreaseSecondDigit());\n child_node.setParent(current);\n child_node.getDigit().setLastChanged(1);\n if(!forbidden.contains(child_node.getDigit().getDigitString())){\n fringe.add(child_node);\n }\n }\n\n //+1 child\n if ((Integer.parseInt(current.getDigit().getSecond_digit()) + 1 <= 9)) {\n Node child_node = new Node(current.getDigit().increaseSecondDigit());\n child_node.setParent(current);\n child_node.getDigit().setLastChanged(1);\n if(!forbidden.contains(child_node.getDigit().getDigitString())){\n fringe.add(child_node);\n }\n }\n }\n\n if(current.getDigit().last_changed != 2){\n if ((Integer.parseInt(current.getDigit().getThird_digit()) - 1 >= 0)) {\n Node child_node = new Node(current.getDigit().decreaseThirdDigit());\n child_node.setParent(current);\n child_node.getDigit().setLastChanged(2);\n if(!forbidden.contains(child_node.getDigit().getDigitString())){\n fringe.add(child_node);\n }\n }\n //+1 child\n if ((Integer.parseInt(current.getDigit().getThird_digit()) + 1 <= 9)) {\n Node child_node = new Node(current.getDigit().increaseThirdDigit());\n child_node.setParent(current);\n child_node.getDigit().setLastChanged(2);\n if(!forbidden.contains(child_node.getDigit().getDigitString())){\n fringe.add(child_node);\n }\n }\n }\n\n }\n\n\n\n for(Node n : fringe){\n heuristicSetter(n);\n\n }\n\n fringeTemp.addAll(fringe);\n //now all the nodes in fringe have the heuristic value.\n //We can get the last added minm\n Node minm;\n if(fringeTemp.size() != 0){\n minm = fringeTemp.get(0);\n }else{\n break;\n }\n for(int i = 1; i<fringeTemp.size(); i++){\n if(fringeTemp.get(i).getHeuristic() <= minm.getHeuristic()){\n minm = fringeTemp.get(i);\n }\n }\n\n //now we have the minm for the next stage.\n current = minm;\n fringeTemp.remove(minm);\n fringe.clear();\n }\n\n //While loop ends\n System.out.println(\"No solution found.\");\n printExpanded(expanded);\n\n\n\n }", "private void findSmallestCost() {\n int best = 0;\n fx = funFitness[0];\n for (int i = 1; i < population; i++) {\n if (funFitness[i] < fx) {\n fx = funFitness[i];\n best = i;\n }\n }\n //System.arraycopy(currentPopulation[best], 0, bestSolution, 0, dimension);\n copy(bestSolution, currentPopulation[best]);\n }", "public int minimax(TablutBoardState boardState, boolean isMax, int depth, int alpha, int beta) {\n\t\tif (boardState.gameOver()){\n\t\t\t//System.out.println(\"reach endgame in minimax\");\n\t\t\tif (boardState.getWinner() == boardState.MUSCOVITE) {\n\t return 1000;\n\t }else if (boardState.getWinner()==boardState.SWEDE){\n\t \treturn -1000;\n\t }else{\n\t \treturn 0;\n\t }\n\t\t}\n\t\tif (depth == 0){\n\t\t\t//System.out.println(\"reach bottom in minimax\");\n return heuristic(boardState);\n }\n\t\t//int bestValue;\n\n\t\tif(isMax){\n\t\t\tint bestValue = Integer.MIN_VALUE;\n\t\t\tHashMap<Integer,TablutMove> moveScore = new HashMap<>();\n\t\t\tfor(TablutMove move : boardState.getAllLegalMoves()){\n\t\t\t\tTablutBoardState cloneBS = (TablutBoardState) boardState.clone();\n\t\t\t\tcloneBS.processMove(move);\n\t\t\t\tint val = minimax(cloneBS,false,depth-1,alpha,beta);\n\t\t\t\tmoveScore.put(new Integer(val),move); \n\t\t\t\tbestValue = max(bestValue,val);\n\t\t\t\talpha = max(alpha,bestValue);\n\t\t\t\t//System.out.println(\"alpha: \"+alpha+\", beta: \"+beta);\n\t\t\t\tif (beta <= alpha){\n\t\t\t\t\t//System.out.println(\"prunning: alpha: \"+alpha+\" and beta: \"+beta);\n\t\t\t\t\tbreak;\n\t\t\t\t}\t\n\t\t\t}\n\t\t\tInteger index= Collections.max(moveScore.keySet());\n\t\t\tif(depth == DEPTH){\n\t\t\t\t//System.out.println(\"update move from max\");\n\t\t\t\tbestMove = moveScore.get(index);\n\t\t\t}\n\t\t\t\n moveScore = null;\n\t\t\treturn bestValue;\n\t\t\t\n\t\t}else{\n\t\t\tint bestValue = Integer.MAX_VALUE;\n\t\t\tHashMap<Integer,TablutMove> moveScore = new HashMap<>();\n\t\t\tfor(TablutMove move : boardState.getAllLegalMoves()){\n\t\t\t\tTablutBoardState cloneBS = (TablutBoardState) boardState.clone();\n\t\t\t\tcloneBS.processMove(move);\n\t\t\t\tint val = minimax(cloneBS,true,depth-1,alpha,beta);\n\t\t\t\tmoveScore.put(new Integer(val),move); \n\t\t\t\tbestValue = min(bestValue,val);\n\t\t\t\tbeta = min(beta,bestValue);\n\t\t\t\t//System.out.println(\"alpha: \"+alpha+\", beta: \"+beta);\n\t\t\t\tif(beta<= alpha){\n\t\t\t\t\t//System.out.println(\"prunning: alpha: \"+alpha+\" and beta: \"+beta);\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t\t\n\t\t\t}\n\t\t\tInteger index= Collections.min(moveScore.keySet());\n\t\t\tif(depth == DEPTH){\n\t\t\t\t//System.out.println(\"update move from min\");\n\t\t\t\tbestMove = moveScore.get(index);\n\t\t\t}\n moveScore = null;\n\t\t\treturn bestValue;\n\t\t\t\n\t\t}\n\t\t\n\t\t\n\t\t//return 0;\n\t}", "@Override\n \tpublic Solution solve() {\n \t\tfor (int i = 0; i < n; i++) {\n \t\t\tnest[i] = generator.getSolution();\n \t\t}\n \n \t\tfor (int t = 0; t < maxGeneration; t++) { // While (t<MaxGeneration) or\n \t\t\t\t\t\t\t\t\t\t\t\t\t// (stop criterion)\n \t\t\t// Get a cuckoo randomly (say, i) and replace its solution by\n \t\t\t// performing random operations;\n \t\t\tint i = r.nextInt(n);\n \t\t\tSolution randomNest = nest[i];\n \t\t\t//FIXME: randomNest = solutionModifier.modify(nest[i]);\n \n \t\t\t// Evaluate its quality/fitness\n \t\t\tint fi = randomNest.f();\n \n \t\t\t// Choose a nest among n (say, j) randomly;\n \t\t\tint j = r.nextInt(n);\n \t\t\tint fj = f[j];\n \n \t\t\tif (fi > fj) {\n \t\t\t\tnest[i] = randomNest;\n \t\t\t\tf[i] = fi;\n \t\t\t}\n \n \t\t\tsort();\n \t\t\t// A fraction (pa) of the worse nests are abandoned and new ones are built;\n\t\t\tfor(i = n-toAbandon; i<n; i++) {\n \t\t\t\tnest[i] = generator.getSolution();\n \t\t\t}\n \t\t\t\n \t\t\t// Rank the solutions/nests and find the current best;\n \t\t\tsort();\n \t\t}\n \n \t\treturn nest[0];\n \t}", "@Override\n List<NodeData> pathFind() throws NoPathException {\n System.out.println(\"Starting Scenic\");\n\n frontier.add(start);\n\n while(!frontier.isEmpty()) {\n StarNode current = frontier.getLast();\n frontier.removeLast(); // pop the priority queue\n if(current.getXCoord() == goal.getXCoord() && current.getYCoord() == goal.getYCoord()) {\n // If we are at the goal, we need to backtrack through the shortest path\n System.out.println(\"At target!\");\n finalList.add(current); // we have to add the goal to the path before we start backtracking\n while(!(current.getXCoord() == start.getXCoord() && current.getYCoord() == start.getYCoord())) {\n finalList.add(current.getPreviousNode());\n current = current.getPreviousNode();\n System.out.println(current.getNodeID());\n }\n return finalList;\n }\n else {\n // we need to get all the neighbor nodes, identify their costs, and put them into the queue\n LinkedList<StarNode> neighbors = current.getNeighbors();\n // we also need to remove the previous node from the list of neighbors because we do not want to backtrack\n neighbors.remove(current.getPreviousNode());\n\n for (StarNode newnode : neighbors) {\n int nodePlace = this.listContainsId(frontier, newnode);\n if(nodePlace > -1) {\n if (frontier.get(nodePlace).getF() > actionCost(newnode) + distanceToGo(newnode, goal)) {\n System.out.println(\"Here\");\n frontier.remove(frontier.get(nodePlace));\n newnode.setPreviousNode(current);\n frontier.add(newnode);\n newnode.setF(actionCost(newnode) + distanceToGo(newnode, goal));\n }\n }\n else {\n newnode.setPreviousNode(current);\n frontier.add(newnode);\n newnode.setF(actionCost(newnode) + distanceToGo(newnode, goal));\n }\n\n // This fixes the problem with infinitely looping elevators (I hope)\n if(current.getNodeType().equals(\"ELEV\") && newnode.getNodeType().equals(\"ELEV\")) {\n for (Iterator<StarNode> iterator = newnode.neighbors.iterator(); iterator.hasNext();) {\n StarNode newneighbor = iterator.next();\n if (newneighbor.getNodeType().equals(\"ELEV\")) {\n // Remove the current element from the iterator and the list.\n iterator.remove();\n }\n }\n }\n if(current.getNodeType().equals(\"STAI\") && newnode.getNodeType().equals(\"STAI\")) {\n for (Iterator<StarNode> iterator = newnode.neighbors.iterator(); iterator.hasNext();) {\n StarNode newneighbor = iterator.next();\n if (newneighbor.getNodeType().equals(\"STAI\")) {\n // Remove the current element from the iterator and the list.\n iterator.remove();\n }\n }\n }\n // this is where the node is put in the right place in the queue\n Collections.sort(frontier);\n }\n }\n }\n throw new NoPathException(start.getLongName(), goal.getLongName());\n }", "private int getBestMove(int[] board, int depth, boolean turn) {\n int boardCopy[];\n if (depth <= 0) {\n return 0;\n }\n if (depth > STEP_BACK_DEPTH) {\n try {\n Thread.sleep(3);\n } catch (InterruptedException e) {\n e.printStackTrace();\n if (shouldStop()) {\n Log.d(Constants.MY_TAG,\"out CalculatingBot\");\n unlock();\n return 0;\n }\n }\n }\n if (turn) {\n int minimum = MAXIMUM_POSSIPLE_SCORE_DIFFERENCE;\n for (int i = 0; i < 5; i++) {\n if (board[i] < 2) {\n continue;\n }\n boardCopy = board.clone();\n int x = playMove(boardCopy, i);\n int y = 0;\n if (!hasPlayer2Move(boardCopy)) {\n if (hasPlayer1Move(boardCopy)) {\n y = getBestMove(boardCopy, depth - 1, turn);\n } else {\n for (int j = 0; j < 5; j++) {\n y = y - boardCopy[j];\n }\n for (int j = 5; j < 10; j++) {\n y = y + boardCopy[j];\n }\n }\n } else {\n y = getBestMove(boardCopy, depth - 1, ! turn);\n }\n int z = y - x;\n if (z < minimum) {\n minimum = z;\n }\n }\n int i = 10;\n if (board[2] < 2) {\n return minimum;\n }\n boardCopy = board.clone();\n int x = playMove(boardCopy, i);\n int y = 0;\n if (!hasPlayer2Move(boardCopy)) {\n if (hasPlayer1Move(boardCopy)) {\n y = getBestMove(boardCopy, depth - 1, turn);\n } else {\n for (int j = 0; j < 5; j++) {\n y = y - boardCopy[j];\n }\n for (int j = 5; j < 10; j++) {\n y = y + boardCopy[j];\n }\n }\n } else {\n y = getBestMove(boardCopy, depth - 1, !turn);\n }\n int z = y - x;\n if (z < minimum) {\n minimum = z;\n }\n return minimum;\n } else {\n int maximum = MINIMUM_POSSIPLE_SCORE_DIFFERENCE;\n for (int i = 5; i < 10; i++) {\n if (board[i] < 2) {\n continue;\n }\n boardCopy = board.clone();\n int x = playMove(boardCopy, i);\n int y = 0;\n if (!hasPlayer1Move(boardCopy)) {\n if (hasPlayer2Move(boardCopy)) {\n y = getBestMove(boardCopy, depth - 1, turn);\n } else {\n for (int j = 0; j < 5; j++) {\n y = y - boardCopy[j];\n }\n for (int j = 5; j < 10; j++) {\n y = y + boardCopy[j];\n }\n }\n } else {\n y = getBestMove(boardCopy, depth - 1, !turn);\n }\n int z = y + x;\n if (z > maximum) {\n maximum = z;\n }\n }\n int i = 11;\n if (board[7] < 2) {\n return maximum;\n }\n boardCopy = board.clone();\n int x = playMove(boardCopy, i);\n int y = 0;\n if (!hasPlayer1Move(boardCopy)) {\n if (hasPlayer2Move(boardCopy)) {\n y = getBestMove(boardCopy, depth - 1, turn);\n } else {\n for (int j = 0; j < 5; j++) {\n y = y - boardCopy[j];\n }\n for (int j = 5; j < 10; j++) {\n y = y + boardCopy[j];\n }\n }\n } else {\n y = getBestMove(boardCopy, depth - 1, !turn);\n }\n int z = y + x;\n if (z > maximum) {\n maximum = z;\n }\n return maximum;\n }\n }", "public boolean bestFirstSearch() {\n\t\twhile(!soloution){\n\t\t\tif(open.isEmpty()){\n\t\t\t\tSystem.out.println(\"No more choices to explore\");\n\t\t\t\tSystem.out.println(\"SolutionId: \" + solutionId);\n\t\t\t\treturn false;\n\t\t\t}\n\t\t\t//chooses the most optimal X\n\t\t\tNode x = popNode();\n\t\t\tclosed.add(x);\n\t\t\tSystem.out.println(\"X:\\t\\t\" + x.state + \" \" + x.h + \" + \" + x.g + \" = \" + x.f);\n\t\t\t//checks if it is a soulution\n\t\t\tif(solution(x)){\n\t\t\t\tSystem.out.println(\"SOLUTION:\\t\" + x.state);\n\t\t\t\tSystem.out.println(\"nodes created: \" + open.size() + closed.size());\n\t\t\t\tprintSolution(x);\n\t\t\t\treturn true;\n\t\t\t}\n\t\t\t//handles the possible moves from the state x\n\t\t\tsucc = generateAllSuccesors(x);\n\t\t\tfor (Node s : succ) {\n\t\t\t\t//if this state already exist, we will use the node keeping it instead\n\t\t\t\tNode old = findOld(s);\n\t\t\t\tif(old != null)\n\t\t\t\t\ts = old;\n\t\t\t\t//makes the new node a child of x\n\t\t\t\tx.kids.add(s);\n\t\t\t\t//if its a new state it will be inserted to open after evaluation\n\t\t\t\tif(!open.contains(s) && !closed.contains(s)){\n\t\t\t\t\tattachAndEval(s,x);\n\t\t\t\t\tinsert(s);\n\t\t\t\t}\n\t\t\t\t//if its an old node and x is a better parent it will be evalueted again.\n\t\t\t\telse if(x.g + arcCost(x, s) < s.g){\n\t\t\t\t\tattachAndEval(s, x);\n\t\t\t\t\tif(closed.contains(s)){\n\t\t\t\t\t\t//if its closed all children will be evaluated with the new score of \"s\"\n\t\t\t\t\t\tpropagatePathImprovements(s);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn true;\n\t}", "public static void dynamicProgramming2(int[][] myArray){ \t\r\n\t\tint countNode = myArray.length;\r\n\t\tint rows = myArray[0].length;\r\n\t\tif(rows != countNode) {\r\n\t\t\tthrow new IllegalArgumentException();\r\n\t\t}\r\n\t\t\r\n \tint[] cost = new int[countNode];\r\n \tint[] prev = new int[countNode];\r\n \tboolean[] visited = new boolean[countNode];\r\n \t\r\n \tfor(int i = 0; i < countNode; i++) {\r\n \t\tcost[i] = myArray[0][i];\r\n \t\tprev[i] = 0;\r\n \t\tvisited[i] = false;\r\n \t}\r\n \t\r\n \tint cur = 0; \t\r\n \twhile(true)\r\n \t{\r\n \t\tfor(int i = cur; i < countNode; i++)\r\n \t\t{\r\n \t\t\tif(myArray[cur][i] + cost[cur] < cost[i])\r\n \t\t\t{\r\n \t\t\t\tcost[i] = myArray[cur][i] + cost[cur];\r\n \t\t\t\tprev[i] = cur;\r\n \t\t\t}\r\n \t\t}\r\n \t\t\r\n \t\tvisited[cur] = true;\r\n \t\tif(AllVisited(visited)) break;\r\n \t\t\r\n \t\t// Choose the node which is not visited yet\r\n \t\t// and has the minimum cost so far.\r\n \t\tint min = Integer.MAX_VALUE;\r\n \t\tfor(int i = 0; i < countNode; i++){\r\n \t\t\tif(!visited[i] && cost[i] < min) {\r\n \t\t\t\tcur = i;\r\n \t\t\t\tmin = cost[i];\r\n \t\t\t}\r\n \t\t}\r\n \t}\r\n \tSystem.out.println(\"Dynamic Programming2:\");\r\n \tSystem.out.println(\"Minimum Cost to go from 1 to \" + countNode + \" is \" + cost[countNode - 1]);\r\n \tStack<Integer> s = new Stack<Integer>();\r\n \tint traveller = countNode - 1;\r\n \ts.push(countNode);\r\n \twhile(traveller != 0)\r\n \t{\r\n \t\ts.push(prev[traveller] + 1);\r\n \t\ttraveller = prev[traveller];\r\n \t}\r\n \t\r\n \tStringBuilder sb = new StringBuilder();\r\n \twhile(!s.empty())\r\n \t{\r\n \t\tsb.append(s.pop());\r\n \t\tif (!s.empty()) {\r\n \t\tsb.append(\" -> \");\r\n \t\t}\r\n \t}\r\n \t\r\n \tSystem.out.println(\"Path from 1 to end is \" + sb.toString()); \r\n \tSystem.out.println();\r\n }", "private static double minMaxPruning(GameState state, int depth, double alpha, double beta){\n\n double v = 0;\n\n // A vector containing all possible children states if this current state\n Vector<GameState> nextStates = new Vector<GameState>();\n state.findPossibleMoves(nextStates);\n\n /**\n // Try testing win/loss before going into depth search\n Move m = state.getMove();\n\n if(m.isXWin()){\n return 1000+depth;\n }\n\n else if(m.isOWin()){\n return -1;\n }\n */\n if (depth==0 || nextStates.size()==0){\n v = evalState(state);\n }\n\n // 2 is 'O' so if nextPlayer is 2 it means that the current player is 'X'\n else if (state.getNextPlayer() == 1){\n v=Double.NEGATIVE_INFINITY;\n\n for(GameState s: nextStates){\n v = Math.max(v, minMaxPruning(s,depth-1, alpha, beta));\n alpha = Math.max(alpha, v);\n if(beta <= alpha) {\n return v;\n }\n }\n }\n // 1 is 'X' so if nextplayer is 1 it means that the current player is 'O'\n else if (state.getNextPlayer() == 2){\n v=Double.POSITIVE_INFINITY;\n\n for(GameState s: nextStates){\n v= Math.min(v,minMaxPruning(s,depth-1, alpha, beta));\n beta = Math.min(beta, v);\n if( beta <= alpha ) {\n return v;\n }\n }\n }\n return v;\n }", "public Vector<PuzzleState> aStarSearch() {\r\n System.out.println(\"Starting A*\");\r\n long startTime = (new Date()).getTime();\r\n Vector<PuzzleState> solution = new Vector<PuzzleState>();\r\n HashSet<PuzzleState> closedList = new HashSet<PuzzleState>();\r\n PriorityQueue<PuzzleState> openList = new PriorityQueue<PuzzleState>();\r\n \r\n PuzzleState searchState = state.copy();\r\n searchState.prevState = null;\r\n searchState.depth = 0;\r\n openList.add(searchState);\r\n\r\n while (!openList.isEmpty() && !isGoal(searchState)) {\r\n searchState = openList.poll();\r\n if (!closedList.contains(searchState)) {\r\n closedList.add(searchState);\r\n Vector<PuzzleState> nextStates = possibleNextStates(searchState);\r\n for (PuzzleState s : nextStates)\r\n s.depth = searchState.depth + 1;\r\n openList.addAll(nextStates);\r\n }\r\n }\r\n \r\n // If the goal has been reached, construct the solution\r\n if (isGoal(searchState)) {\r\n for (PuzzleState s = searchState; s.prevState != null; s = s.prevState) {\r\n solution.add(s);\r\n }\r\n Collections.reverse(solution);\r\n }\r\n \r\n long endTime = (new Date()).getTime();\r\n System.out.println(\"A* search ended after \" + (endTime - startTime) + \" ms\");\r\n //for (PuzzleState s : solution)\r\n // System.out.println(s);\r\n return solution;\r\n }", "public void performMove() {\n\t\tfor (int x = 0; x <= size-1; x++)\n\t\t\tfor (int y = 0; y <= size-1; y++)\n\t\t\t\tlocalBoard[y][x] = 0;\n\t\t\n\t\t//reset the flag that indicates if a move has been found that decreases the heuristic\n\t\tfoundBetterMove = false;\n\t\t\n\t\t//fill in the appropriate heuristic values\n\t\tpopulateHillValues();\n\t\tArrayList<PotentialMove> myBestList = new ArrayList<PotentialMove>();\n\n\t\t//Find the square with the lowest heuristic value. this should really write the values to an array. \n\t\tint squareDifferential = -1;\n\t\t//String outValue = \"\";\n\t\tfor (int y = 0; y <= size-1; y++) {\n\t\t\tfor (int x = 0; x <= size-1; x++){\n\t\t\t\t//outValue = outValue + localBoard[y][x];\n\t\t\t\tif (squareDifferential < 0) //lowestSquareFound not found yet \n\t\t\t\t{\n\t\t\t\t\tif ((NQueens.queens[x] != y) && //set if the current square isn't already occupied by a queen\n\t\t\t\t\t\t\t(localBoard[NQueens.queens[x]][x] >= localBoard[y][x])) {\n\t\t\t\t\t\tif (localBoard[y][x] == localBoard[NQueens.queens[x]][x])\n\t\t\t\t\t\t\tmyBestList.add(new PotentialMove(x, y, true));\n\t\t\t\t\t\telse\n\t\t\t\t\t\t\tmyBestList.add(new PotentialMove(x, y, false));\n\t\t\t\t\t\tsquareDifferential = localBoard[NQueens.queens[x]][x] - localBoard[y][x];\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\telse if ((localBoard[NQueens.queens[x]][x] - localBoard[y][x]) > squareDifferential) { // find the square with the largest differential in value from the queen in the column\n\t\t\t\t\tmyBestList.clear();\n\t\t\t\t\tmyBestList.add(new PotentialMove(x, y, false));\n\t\t\t\t\tsquareDifferential = localBoard[NQueens.queens[x]][x] - localBoard[y][x];\n\t\t\t\t}\n\t\t\t\telse if (((localBoard[NQueens.queens[x]][x] - localBoard[y][x]) == squareDifferential) && // the differential is equal to the current best differential\n\t\t\t\t\t\t(NQueens.queens[x] != y)) { // and isn't already occupied by a queen\n\t\t\t\t\tmyBestList.add(new PotentialMove(x, y, true));\n\t\t\t\t}\n\t\t\t\t//else the square is higher, has a queen or isn't marginally better than the current queen's position in the row\n\t\t\t}\n\t\t\t//outValue = outValue + \"\\n\";\n\t\t}\n\t\t//JOptionPane.showMessageDialog(null, outValue);\n\t\t\n\t\tif (myBestList.isEmpty())\n\t\t\treturn;\n\t\t\n\t\tint listSize = myBestList.size();\n\t\tPotentialMove bestMove;\n\t\t\n\t\t//grab the non-Sideways moves first\n\t\tfor (int i = 0; i < listSize; i++) {\n\t\t\tif (!(myBestList.get(i).isSideways)) {\n\t\t\t\tbestMove = myBestList.get(i);\n\t\t\t\tfoundBetterMove = true;\n\t\t\t\tsidewaysMoves = 0;\n\t\t\t\tNQueens.queens[bestMove.xCoordinate] = bestMove.yCoordinate;\n\t\t\t\treturn;\n\t\t\t}\n\t\t}\n\t\t\n\t\tif (sidewaysMoves > MAXSIDEWAYSMOVES) { // hit MAXSIDEWAYSMOVES consecutive sideways moves, mark as unsolvable\n\t\t\treturn;\n\t\t}\n\t\t\n\t\t//all available moves sideways moves, let's select one randomly\n\t\tRandom generator = new Random();\n\t\tint randomElement = generator.nextInt(listSize);\n\t\t\n\t\tbestMove = myBestList.get(randomElement);\n\t\tfoundBetterMove = true;\n\t\tsidewaysMoves++;\n\t\tNQueens.queens[bestMove.xCoordinate] = bestMove.yCoordinate;\n\t}", "public ReturnClass astar_algo(){\n long start=System.nanoTime();\n TreeStar node=new TreeStar(variables,0);\n openList.push(node);\n\n while (!openList.isEmpty())\n {\n\n TreeStar temp= openList.pollLast(); //pop the highest scoring node in openList\n refreshUsage(temp.variables); //uses the current node variables to update usageArray\n\n if((System.nanoTime()-start)/1000000000>=maxTime){\n System.out.println(\"time limit reached\");\n ReturnClass returnClass= new ReturnClass(temp.variables,temp.score,false);\n return returnClass;\n }\n\n if(temp.score==nbC){\n System.out.println(\"solution trouvée !\");\n printArray(temp.variables);\n ReturnClass returnClass= new ReturnClass(temp.variables,temp.score,true);\n return returnClass;\n }\n\n int bestVar=0;\n if(heuristic.equals(\"TD Heuristic\")){\n bestVar= chooseVTD(); //get the highest scoring unused var to use it in children\n }\n else if(heuristic.equals(\"TD-long heuristic\")){\n bestVar=chooseVTD();\n }\n else if(heuristic.equals(\"Partial-diff Heuristic\")){\n bestVar= chooseVDiff(temp.variables); //get the highest scoring unused var to use it in children\n }\n else {\n bestVar= chooseVDiff(temp.variables);\n }\n\n\n TreeStar node1= nextVar(temp.variables, 0,bestVar,temp.profondeur+1);\n TreeStar node2= nextVar(temp.variables, 1,bestVar,temp.profondeur+1);\n\n if(node1!=null){\n addToOpenList(node1);\n addToOpenList(node2);\n }\n }\n\n System.out.println(\"solution non trouvée\");\n return null;\n }", "Long[] searchSolution(int timeLimit, Graph g);", "private Outcome minMax(PossibleBoard posBoard, Icon icon, int depth) {\n Outcome outcome = new Outcome();\n Result result = posBoard.determineOutcome();\n boolean maximiseWin = icon == getIcon();\n\n // BASE CASE\n if (result.gameComplete()) {\n outcome.score = result.getBonus();\n outcome.moveToMake = posBoard.coor;\n outcome.depth = depth;\n return outcome;\n }\n\n ArrayList<PossibleBoard> posNextBoards = getPossibleNextBoards(posBoard, icon);\n int optimalScore = (maximiseWin ? Integer.MIN_VALUE : Integer.MAX_VALUE);\n Coordinate optimalCoor = new Coordinate(0,0);\n int optimalDepth = Integer.MAX_VALUE;\n\n for (PossibleBoard posNextBoard : posNextBoards) {\n Outcome nextOutcome = minMax(posNextBoard, (icon == Icon.CROSSES ? Icon.NOUGHTS : Icon.CROSSES), depth + 1);\n\n if (maximiseWin && nextOutcome.score >= optimalScore) {\n if (nextOutcome.score == optimalScore && nextOutcome.depth < optimalDepth) continue;\n optimalScore = nextOutcome.score;\n optimalCoor = posNextBoard.coor;\n optimalDepth = nextOutcome.depth;\n\n } else if (!maximiseWin && nextOutcome.score <= optimalScore){\n if (nextOutcome.score == optimalScore && nextOutcome.depth < optimalDepth) continue;\n optimalScore = nextOutcome.score;\n optimalCoor = posNextBoard.coor;\n optimalDepth = nextOutcome.depth;\n\n }\n }\n\n outcome.moveToMake = optimalCoor;\n outcome.score = optimalScore;\n outcome.depth = optimalDepth;\n return outcome;\n }", "public abstract OptimisationSolution getBestSolution();", "public Solver(Board initial) {\r\n if (initial == null) throw new IllegalArgumentException();\r\n\r\n\r\n SearchNode initialAdjacent = new SearchNode(initial.twin(), null, 0);\r\n MinPQ<SearchNode> adjacentPriorityQueue = new MinPQ<>(1);\r\n adjacentPriorityQueue.insert(initialAdjacent);\r\n\r\n\r\n SearchNode initialNode = new SearchNode(initial, null, 0);\r\n MinPQ<SearchNode> priorityQueue = new MinPQ<>(1);\r\n priorityQueue.insert(initialNode);\r\n\r\n if (initial.isGoal()) {\r\n goal = initialNode;\r\n isSolvable = true;\r\n return;\r\n } else if (initialAdjacent.board.isGoal()) {\r\n isSolvable = false;\r\n }\r\n\r\n\r\n SearchNode currentAdjacent = initialAdjacent;\r\n SearchNode currentBoard = initialNode;\r\n\r\n while (!currentAdjacent.board.isGoal() && !currentBoard.board.isGoal()) {\r\n\r\n currentAdjacent = adjacentPriorityQueue.delMin();\r\n currentBoard = priorityQueue.delMin();\r\n\r\n for (Board adjacentNeighbor : currentAdjacent.board.neighbors()) {\r\n SearchNode toBeInserted = new SearchNode(adjacentNeighbor, currentAdjacent, currentAdjacent.previousMoves + 1);\r\n if (currentAdjacent.previousSearchNode == null || !toBeInserted.board.equals(currentAdjacent.previousSearchNode.board)) {\r\n adjacentPriorityQueue.insert(toBeInserted);\r\n }\r\n }\r\n\r\n\r\n for (Board neighbor : currentBoard.board.neighbors()) {\r\n SearchNode toBeInserted = new SearchNode(neighbor, currentBoard, currentBoard.previousMoves + 1);\r\n if (currentBoard.previousSearchNode == null || !toBeInserted.board.equals(currentBoard.previousSearchNode.board)) {\r\n\r\n priorityQueue.insert(toBeInserted);\r\n }\r\n }\r\n }\r\n if (currentAdjacent.board.isGoal()) {\r\n isSolvable = false;\r\n goal = initialNode;\r\n } else {\r\n goal = currentBoard;\r\n isSolvable = true;\r\n }\r\n\r\n }", "private MoveEvaluation minimax (int ply, IComparator comp, \n\t\t\tIPlayer player, IPlayer opponent) {\n\n\t\t// Try to improve on this lower-bound (based on selector). Reflects no move possible.\n\t\tMoveEvaluation best = new MoveEvaluation (comp.initialValue());\n\n\t\t// get all moves for this player and generate the boards that result\n\t\t// from making these moves. Select maximum of children if we are MAX\n\t\t// and minimum of children if we are MIN\n\t\tIterator<IGameMove> it = player.validMoves(state).iterator(); \n\t\twhile (it.hasNext()) {\n\t\t\tIGameMove move = it.next();\n\t\t\t\n\t\t\tmove.execute(state);\n\t\t\tnumComputationalStates++;\n\t\t\t\n\t\t\t// debugging output along the way...\n\t\t\tif (numComputationalStates % 100 == 0) {\n\t\t\t\tSystem.out.println (numComputationalStates);\n\t\t\t}\n\t\t\t\n\t\t\tMoveEvaluation pathMove = alreadyDetermined(state);\n\t\t\t\n\t\t\tif (pathMove == null) {\n\t\t\t\tint trial;\n\t\t\t\tif (ply <= 0) {\n\t\t\t\t\ttrial = original.eval(state);\n\t\t\t\t} else {\n\t\t\t\t\t// Recursively evaluate position. Compute MiniMax and swap\n\t\t\t\t\t// player and opponent, synchronously with MIN and MAX. If no move is\n\t\t\t\t\t// associated, then evaluate the generated board from original player\n\t\t\t\t\tMoveEvaluation me = minimax (ply-1, comp.opposite(), opponent, player);\n\t\t\t\t\tif (me.move == null) {\n\t\t\t\t\t\ttrial = original.eval(state);\n\t\t\t\t\t} else {\n\t\t\t\t\t\ttrial = me.score;\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\tpathMove = new MoveEvaluation (move, trial);\n\t\t\t\t\t\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\tmove.undo(state);\n\t\t\t\n\t\t\t// If we are selected as the better move, then update accordingly\n\t\t\tif (comp.compare(best.score, pathMove.score) < 0) {\n\t\t\t\tbest = new MoveEvaluation (move, pathMove.score); \n\t\t\t}\n\t\t}\n\t\t\n\t\t// this move was selected for the gameState. record it. If it is null, then the game has\n\t\t// already been won or this is a draw; in either case, we will let recursive parent take\n\t\t// care of the scoring. Even add when no move, so we can keep track of the WON games.\n\t\taddToList(state, best);\n\t\t\n\t\treturn best;\n\t}", "private ProblemModel findCheapestNode(){\n\t\tProblemModel ret = unvisitedPM.peek();\n\t\t\n\t\tfor(ProblemModel p : unvisitedPM){ \n\t\t\t//f(s) = depth + cost to make this move\n\t\t\tif(p.getCost() + p.getDepth() <= ret.getCost() + ret.getDepth()) ret = p;\n\t\t}\n\t\tunvisitedPM.remove(ret);\n\t\treturn ret;\n\t}", "public Solver(Board initial) {\n \tsolutionNode = null;\n \tpq = new MinPQ<>();\n \tpq.insert(new SearchNode(initial, null, 0));\n\n \twhile (true) {\n \t\tSearchNode currNode = pq.delMin();\n\t \tBoard currBoard = currNode.getBoard();\n\n\t \tif (currBoard.isGoal()) {\n\t \t\tisSolvable = true;\n\t \t\tsolutionNode = currNode;\n\t \t\tbreak;\n\t \t}\n\n\t \tif (currBoard.hamming() == 2 && currBoard.twin().isGoal()) {\n\t \t\tisSolvable = false;\n\t \t\tbreak;\n\t \t}\n\n\t \tint moves = currNode.getMoves();\n\t \tBoard prevBoard = moves > 0 ? currNode.prev().getBoard() : null;\n\t \tfor (Board nextBoard : currBoard.neighbors()) {\n\t \t\tif (nextBoard != null && nextBoard.equals(prevBoard)) {\n\t \t\t\tcontinue;\n\t \t\t}\n\t \t\tpq.insert(new SearchNode(nextBoard, currNode, moves + 1));\n\t \t}\n \t}\n \t\n }", "public Solver(Board initial) {\n if (initial == null) {\n throw new IllegalArgumentException();\n }\n MinPQ<SearchNode> minPQ = new MinPQ<>();\n MinPQ<SearchNode> minPQTwin = new MinPQ<>();\n\n minPQ.insert(new SearchNode(initial, null, 0));\n minPQTwin.insert(new SearchNode(initial.twin(), null, 0));\n\n while (true) {\n SearchNode curr = minPQ.delMin();\n SearchNode currTwin = minPQTwin.delMin();\n\n if (curr.board.isGoal()) {\n moves = curr.moves;\n resultNode = curr;\n break;\n } else if (currTwin.board.isGoal()) {\n moves = -1;\n resultNode = null;\n break;\n }\n\n for (Board b : curr.board.neighbors()) {\n if (curr.predecessor == null || !b.equals(curr.predecessor.board))\n minPQ.insert(new SearchNode(b, curr, curr.moves + 1));\n }\n\n for (Board b : currTwin.board.neighbors()) {\n if (currTwin.predecessor == null || !b.equals(currTwin.predecessor.board))\n minPQTwin.insert(new SearchNode(b, currTwin, currTwin.moves + 1));\n }\n }\n\n }", "public MoveNode ab(PentagoBoardState pbs,int myscore, int alpha, int beta,int amimaxplayer, int depth,int requireddepth){\n\n int bestmovescore;\n PentagoMove bestmove;\n\n ArrayList<PentagoMove> legalmoves = pbs.getAllLegalMoves();\n Collections.shuffle(legalmoves); //helps avoid worst run time if all good moves are at the end of array list\n\n MoveNode moveNode =new MoveNode(new PentagoMove(0,0,0,0,0),0);\n\n if (depth==requireddepth){\n bestmovescore= evaluate(pbs);\n moveNode.MyMove = null;\n moveNode.value = evaluate(pbs);\n return moveNode;\n\n }\n else if (pbs.getWinner() != Board.NOBODY){ //check win since we are at leafnode\n bestmovescore= evaluate(pbs);\n moveNode.MyMove = null;\n int movescore = evaluate(pbs);\n if (movescore<-1200000){\n moveNode.value = -999999999; //assign loss value\n } //Losing Move\n else if (movescore>1200000){\n moveNode.value = 999999999; //assign win value\n } // Winning Move\n return moveNode;\n\n }\n //do max player\n if (amimaxplayer ==1){\n int currentvalue = -999999999;\n PentagoMove currentmove =legalmoves.get(0);\n MoveNode currentmovenode = new MoveNode(currentmove,currentvalue);\n for (int i = 0; i < legalmoves.size(); i++) {\n PentagoBoardState newboard = (PentagoBoardState) pbs.clone();\n PentagoMove movetoprocess = legalmoves.get(i);\n newboard.processMove(movetoprocess);\n\n\n MoveNode scoreAfterMove = ab(newboard, currentvalue, alpha, beta, 0, depth + 1, requireddepth); // run recursion till leaf node or depth reached\n if (scoreAfterMove.value > currentvalue) { //see if current best value is lower than the new value if so replace\n currentvalue = scoreAfterMove.value;\n currentmove = movetoprocess;\n currentmovenode.value = currentvalue;\n currentmovenode.MyMove = currentmove;\n\n //System.out.println(\"I am max plyaer at depth:\" + depth + \"\\n current move is: \" + currentmove + \"\\ncurrentvalue is: \" + currentvalue);\n\n }\n\n alpha = Math.max(alpha,currentvalue);\n if (alpha>=beta){ // break loop if alpha more than beta\n //System.out.println(\"Get pruned my alpha is \" + alpha + \" my beta is \" + beta );\n break;\n }\n }\n //System.out.println(\"I am max plyaer at depth:\" + depth + \"\\n current move is: \" + currentmove + \"\\ncurrentvalue is: \" + currentvalue+\" my alpha is \" + alpha + \" my beta is \" + beta);\n\n return currentmovenode;\n }\n //do min player\n else if (amimaxplayer==0){\n int currentvalue = 999999999;\n PentagoMove currentmove =legalmoves.get(0);\n MoveNode currentmovenode = new MoveNode(currentmove,currentvalue);\n for (int i = 0; i < legalmoves.size(); i++) {\n PentagoBoardState newboard = (PentagoBoardState) pbs.clone();\n PentagoMove movetoprocess = legalmoves.get(i);\n newboard.processMove(movetoprocess);\n\n MoveNode scoreAfterMove = ab(newboard, currentvalue, alpha, beta, 1, depth + 1, requireddepth);\n if (scoreAfterMove.value < currentvalue) {\n currentvalue = scoreAfterMove.value;\n currentmove = movetoprocess;\n currentmovenode.value = currentvalue;\n currentmovenode.MyMove = currentmove;\n //System.out.println(\"I am min plyaer at depth:\" + depth + \"\\n current move is: \" + currentmove + \"\\ncurrentvalue is: \" + currentvalue);\n }\n beta = Math.min(beta,currentvalue);\n if (alpha>=beta){\n //System.out.println(\"Get pruned my alpha is \" + alpha + \" my beta is \" + beta );\n break;\n }\n }\n return currentmovenode;\n }\n //System.out.println(\"move val \" + moveNode.value);\n return moveNode;\n }", "public Solver(Board initial)\n {\n pq = new MinPQ<>();\n pqTwin = new MinPQ<>();\n\n pq.insert(new SearchNode(initial, 0, null));\n pqTwin.insert(new SearchNode(initial.twin(), 0, null));\n\n SearchNode solution = null;\n while (!pq.isEmpty() || !pqTwin.isEmpty()) {\n solution = processQueue(pq);\n if (solution != null) break;\n\n solution = processQueue(pqTwin);\n if (solution != null) {\n solution = null;\n break;\n }\n }\n if (solution != null) {\n numberOfMoves = solution.numberOfMoves;\n\n SearchNode current = solution;\n while (current != null) {\n shortestPath.add(0, current.board);\n current = current.previous;\n }\n }\n pq = null;\n pqTwin = null;\n }", "public Solver(final Board initial) {\n\n Node solutionNodeTwin; // Solution node twin\n MinPQ<Node> thePQ; // Minimum priority queue\n MinPQ<Node> thePQTwin; // Minimum priority queue for the twin\n boolean initialSolvableTwin = false; // is initial twin board solvable\n\n solutionNode = new Node();\n solutionNodeTwin = new Node();\n\n solutionNode.theBoard = initial;\n solutionNodeTwin.theBoard = initial.twin();\n\n solutionNode.previousNode = null;\n solutionNodeTwin.previousNode = null;\n\n thePQ = new MinPQ<>(boardOrder());\n thePQTwin = new MinPQ<>(boardOrder());\n\n thePQ.insert(solutionNode);\n thePQTwin.insert(solutionNodeTwin);\n solutionBoards = new Queue<>();\n\n int count = 0;\n while (!solutionNode.theBoard.isGoal()\n || !solutionNodeTwin.theBoard.isGoal()) {\n\n solutionNode = thePQ.delMin();\n solutionBoards.enqueue(solutionNode.theBoard);\n\n if (solutionNode.theBoard.isGoal()) {\n initialSolvable = true;\n break;\n } else {\n solutionNode.numberOfMovesMade++;\n Iterable<Board> neighborBoards = solutionNode.theBoard.neighbors();\n Iterator<Board> itr = neighborBoards.iterator();\n while (itr.hasNext()) {\n Node neighborNode = new Node();\n neighborNode.theBoard = itr.next();\n neighborNode.numberOfMovesMade = solutionNode.numberOfMovesMade;\n neighborNode.previousNode = solutionNode;\n if (count == 0) {\n thePQ.insert((neighborNode));\n } else if (!neighborNode.theBoard.equals(solutionNode\n .previousNode.theBoard)) {\n thePQ.insert(neighborNode);\n }\n }\n }\n\n solutionNodeTwin = thePQTwin.delMin();\n if (solutionNodeTwin.theBoard.isGoal()) {\n initialSolvableTwin = true;\n break;\n } else {\n solutionNodeTwin.numberOfMovesMade++;\n Iterable<Board> neighborBoardsTwin = solutionNodeTwin.theBoard.neighbors();\n Iterator<Board> itr2 = neighborBoardsTwin.iterator();\n while (itr2.hasNext()) {\n Node neighborNodeTwin = new Node();\n neighborNodeTwin.theBoard = itr2.next();\n neighborNodeTwin.numberOfMovesMade = solutionNodeTwin.numberOfMovesMade;\n neighborNodeTwin.previousNode = solutionNodeTwin;\n if (count == 0) {\n thePQTwin.insert(neighborNodeTwin);\n } else if (!neighborNodeTwin.theBoard.equals(solutionNodeTwin.previousNode.theBoard)) {\n thePQTwin.insert(neighborNodeTwin);\n }\n }\n }\n count++;\n }\n }", "private int[] minValue(int[][] currentState, int[] alpha, int[] beta, int depth) {\n int[] bestMove = new int[]{MinimaxUtilties.freeCentralColumn(currentState), Integer.MAX_VALUE, 0};\n\n if (terminalTest(currentState) != 0) {\n return new int[]{0, utility(currentState), maxDepth - depth};\n }\n\n if (depth < 1){\n return new int[]{0, utility(currentState), maxDepth};\n }\n\n if (terminalTest(currentState) == 0 && depth > 0) {\n ArrayList<Integer> possibleActions = actions(currentState, 2);\n\n for (int i = 0; i < possibleActions.size(); i++) {\n int column = possibleActions.get(i);\n int[][] resultOfAction = result(currentState, column, 2);\n\n int[] currentResult = new int[]{column, maxValue(resultOfAction, alpha, beta, depth - 1)[1], maxDepth - depth};\n\n if (currentResult[1] < bestMove[1] || (currentResult[1] == bestMove[1] && currentResult[2] < bestMove[2])) {\n bestMove = currentResult;\n }\n\n if (bestMove[1] < beta[1] || (bestMove[1] == beta[1] && bestMove[2] < beta[2])) beta = bestMove;\n\n if (alpha[1] >= beta[1]) return beta;\n }\n }\n\n return bestMove;\n }", "public String[] search(boolean hybrid) {\n\t\t/*\n\t\t * Interrupt the think() thread so we can have the updated game tree\n\t\t */\n\t\t\n\t\t// MCTS and minimax response vars, respectively\n\t\tint[] response = null;\n\t\tString[] move = new String[2];\n\t\tint encodedM = 0;\n\t\tint[] m = new int[6];\n\t\t\n\t\tif(mcts) {\n\t\t\tmctsBoard = createBoard(g_board.getBoard());\n\t\t\tresponse = mcts();\n\t\t} else {\n\t\t\troot.setScore(0);\n\t\t\tleaves = 0;\n\t\t\t\n\t\t\t// Find the max or min value for the white or black player respectively\n\t\t\tfloat val = alphaBeta(root, max_depth, Double.NEGATIVE_INFINITY, Double.POSITIVE_INFINITY, player);\n\t\t\t\n\t\t\t// Retrieve the move that has the min/max vlaue\n\t\t\tArrayList<Node> moves = root.getChildren();\n\t\t\tfor(Node n : moves) {\n\t\t\t\tif(Float.compare(n.value, val) == 0) {\n\t\t\t\t\tencodedM = n.move;\n\t\t\t\t\t\n\t\t\t\t\t// Play the move on the AI's g_board, set the root to this node and break out of the loop\n\t\t\t\t\tg_board.doMove(n.move);\n\t\t\t\t\t\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\t// Switch to Monte Carlo after a set amount of moves\n\t\t\tturns += 2;\n\t\t\tif(turns > 40) {\n\t\t\t\tmcts = true;\n\t\t\t\tfirstMoves = new ArrayList<Node>();\n\t\t\t}\n\t\t}\n\t\t\n\t\t// Reset the root rather than set it to a branch since we can currently only achieve a depth of 2-ply\n\t\troot.getChildren().clear();\n\t\t\n\t\t// If we ran MCTS\n\t\tif(response != null) {\n\t\t\tencodedM = response[0];\n\t\t\tSystem.out.println(\"Simulations run: \" + response[3] + \"\\tConfidence: \" + response[1] + \"%\");\n\t\t}\n\t\t\n\t\t// Decode the move\n\t\tfor(int i = 0; i < 6; i++) {\n\t\t\tm[i] = encodedM & 0xf;\n\t\t\tencodedM >>= 4;\n\t\t}\n\t\t\n\t\t// Convert the array into a string array with the format [0] => \"a7-b7\", [1] => \"b5\"\n\t\tmove[0] = ((char)(m[0] + 97)) + \"\" + (m[1]) + \"-\" + ((char)(m[2] + 97)) + \"\" + (m[3]);\n\t\tmove[1] = ((char)(m[4] + 97)) + \"\" + (m[5]);\n\t\t\n\t\t/*\n\t\t * Start the think() thread\n\t\t */\n\t\t\n\t\treturn move;\n\t}", "public Solver(WorldState initial) {\n solution = new ArrayList<>();\n\n // create a priority queue of search nodes\n MinPQ<SNode> pq = new MinPQ<>();\n\n // insert an “initial search node” into the priority queue\n SNode start = new SNode(initial, 0, null);\n pq.insert(start);\n\n // If the search node with minimum priority is the goal node, then we’re done.\n while (!pq.min().ws.isGoal()) {\n\n // Remove the search node with minimum priority.\n SNode X = pq.delMin();\n\n // for each neighbor of X’s world state, create a new search node and\n // insert it into the priority queue.\n for (WorldState nb: X.ws.neighbors()) {\n\n // critical optimization\n if (X.prev == null || !(nb.equals(X.prev.ws))) {\n SNode nbNode = new SNode(nb, X.numberOfMove + 1, X);\n pq.insert(nbNode);\n }\n }\n }\n\n // generate the solution\n SNode goal = pq.min();\n while (goal != null) {\n solution.add(0, goal.ws);\n goal = goal.prev;\n }\n }", "public static SearchNode minimax(SearchNode root, int currentDepth, boolean maxPlayer, boolean pruning, Integer alpha, Integer beta) throws BadCoordinateException {\n\t\tInteger bestValue, currentValue;\n\t\tSearchNode bestNode = null;\n\t\tSearchNode alphaNode = root;\n\t\tSearchNode betaNode = root;\n\n\t\t//If the maximum depth has been reached or the map contains a win then return a heuristic evaluation\n\t\tint heuristic = Heuristic.evaluateMinMax(root.getMap(), true);\n\t\tif ( (currentDepth == 0) || (Math.abs(heuristic) > 500) ) {\n\t\t\troot.setValue(heuristic);\n\t\t\treturn root;\n\t\t}\n\n\t\t//Make a random move if the map is empty\n\t\tif (root.getMap().getMoves().size() == 0) {\n\t\t\tRandom random = new Random();\n\t\t\tint x = random.nextInt(4) + 1;\n\t\t\tint y = random.nextInt(12);\n\t\t\tPolarCoordinate location = new PolarCoordinate(new UnTestedCoordinates(x,y));\n\t\t\troot.setMove(location);\n\t\t\treturn root;\n\t\t}\n\t\t\n\t\tArrayList<UnTestedCoordinates> availableChildren = Status.getValidPositions(root.getMap().getMoves());\n\t\t\n\t\tif (maxPlayer) { //this is a max-player node\n\t\t\tif (!pruning) { //this is standard minimax\n\t\t\t\tbestValue = Integer.MIN_VALUE;\n\t\t\t\tfor (UnTestedCoordinates coords : availableChildren) {\n\t\t\t\t\tSearchNode child = root.addChild(coords);\n\t\t\t\t\tcurrentValue = minimax(child, currentDepth - 1, false, false, null, null).getValue();\n\t\t\t\t\tif (currentValue > bestValue) {\n\t\t\t\t\t\tbestValue = currentValue;\n\t\t\t\t\t\tbestNode = child;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tbestNode.setValue(bestValue);\n\t\t\t\treturn bestNode;\n\t\t\t} else { //this is minimax with alpha-beta pruning\n\t\t\t\tfor (UnTestedCoordinates coords : availableChildren) {\n\t\t\t\t\t//Compare heuristic value to find the best and prune if able\n\t\t\t\t\tSearchNode child = root.addChild(coords);\n\n\t\t\t\t\tcurrentValue = minimax(child, currentDepth - 1, false, true, alpha, beta).getValue();\n\t\t\t\t\tif (currentValue > alpha){ //current is largest - update alpha\n\t\t\t\t\t\talpha = currentValue;\n\t\t\t\t\t\talphaNode = child;\n\t\t\t\t\t\talphaNode.setValue(currentValue);\n\t\t\t\t\t}\n\n\t\t\t\t\tif (beta <= alpha) {\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\treturn alphaNode;\n\t\t\t}\n\t\t\t\n\t\t} else { //This is a min-player node\n\t\t\tif (!pruning) { //this is standard minimax\n\t\t\t\tbestValue = Integer.MAX_VALUE;\n\t\t\t\tfor (UnTestedCoordinates coords : availableChildren) {\n\t\t\t\t\tSearchNode child = root.addChild(coords);\n\t\t\t\t\tcurrentValue = minimax(child, currentDepth - 1, true, false, null, null).getValue();\n\t\t\t\t\tif (currentValue < bestValue) {\n\t\t\t\t\t\tbestValue = currentValue;\n\t\t\t\t\t\tbestNode = child;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tbestNode.setValue(bestValue);\n\t\t\t\treturn bestNode;\n\t\t\t} else { //this is minimax with alpha-beta pruning\n\t\t\t\tfor (UnTestedCoordinates coords : availableChildren) {\n\t\t\t\t\tSearchNode child = root.addChild(coords);\n\t\t\t\t\t//Compare heuristic value to find the best and prune if able\n\n\t\t\t\t\tcurrentValue = minimax(child, currentDepth - 1, true, true, alpha, beta).getValue();\n\t\t\t\t\tif (currentValue < beta) {\n\t\t\t\t\t\tbeta = currentValue;\n\t\t\t\t\t\tbetaNode = child;\n\t\t\t\t\t\tbetaNode.setValue(currentValue);\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\tif (beta <= alpha) { \n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\treturn betaNode;\n\t\t\t}\n\t\t}\n\t}", "public long getBestSolutionTime();", "@Override\n\t\t\tpublic void run() \n\t\t\t{\n\t\t\t\tif(!(mazeCollection.containsKey(paramArray[0])))\n\t\t\t\t{\n\t\t\t\t\tc.passError(\"Maze doesn't exist\");\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t\t/*\n\t\t\t\t//if solution for this maze exists\n\t\t\t\tif(mazeSolutions.containsKey(mazeCollection.get(paramArray[0])))\n\t\t\t\t{\n\t\t\t\t\tc.passSolve(\"Solution for \"+paramArray[0]+ \" is ready\");\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t*/\n\t\t\t\t\n\t\t\t\tif(paramArray[1].toString().equals(\"bfs\"))\n\t\t\t\t{\n\t\t\t\t\tMazeAdapter ms=new MazeAdapter(mazeCollection.get(paramArray[0]));\n\t\t\t\t\t\n\t\t\t\t\tSearcher<Position> bfs=new BFS<Position>();\n\t\t\t\t\tSolution<Position> sol=bfs.search(ms);\n\t\t\t\t\t\n\t\t\t\t\t//check if solution for the maze already exists, if so, replace it with the new one\n\t\t\t\t\tif(mazeSolutions.containsKey(mazeCollection.get(paramArray[0]))) {\n\t\t\t\t\t\tmazeSolutions.remove(mazeCollection.get(paramArray[0]));\n\t\t\t\t\t\tmazeSolutions.put(mazeCollection.get(paramArray[0]), sol);\n\t\t\t\t\t}\n\t\t\t\t\telse {\n\t\t\t\t\t\tmazeSolutions.put(mazeCollection.get(paramArray[0]), sol);\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\tc.passSolve(\"Solution for \"+paramArray[0]+ \" is ready\");\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t\telse if(paramArray[1].toString().equals(\"dfs\"))\n\t\t\t\t{\n\t\t\t\t\tMazeAdapter ms=new MazeAdapter(mazeCollection.get(paramArray[0]));\n\t\t\t\t\t\n\t\t\t\t\tSearcher<Position> dfs=new DFS<Position>();\n\t\t\t\t\tSolution<Position> sol=dfs.search(ms);\n\t\t\t\t\t\n\t\t\t\t\t//check if solution for the maze already exists, if so, replace it with the new one\n\t\t\t\t\tif(mazeSolutions.containsKey(mazeCollection.get(paramArray[0]))) {\n\t\t\t\t\t\tmazeSolutions.remove(mazeCollection.get(paramArray[0]));\n\t\t\t\t\t\tmazeSolutions.put(mazeCollection.get(paramArray[0]), sol);\n\t\t\t\t\t}\n\t\t\t\t\telse {\n\t\t\t\t\t\tmazeSolutions.put(mazeCollection.get(paramArray[0]), sol);\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\tc.passSolve(\"Solution for \"+paramArray[0]+ \" is ready\");\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\tc.passError(\"Invalid algorithm\");\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t\t\n\t\t\t}", "public Solver(Board initial)\n {\n // validate input to Solver\n if (initial == null) throw new NullPointerException();\n if (!initial.isSolvable()) throw new IllegalArgumentException();\n \n // create first search node with pointer used for each iteration of A*\n step = new SearchNode();\n step.board = initial;\n \n // create new priority queue specifying the priority function\n MinPQ<SearchNode> pq = new MinPQ<SearchNode>(new HammingPriority());\n\n // run A-star search algorithm until goal board is dequeued\n while (!step.board.isGoal()) {\n // runs iterable of neighbors and adds non duplicates to pq\n Iterable<Board> neighbors = step.board.neighbors();\n for (Board b : neighbors) {\n // skips if possible board is duplicate of 2nd board back\n if (step.prev != null) // check not needed for first iteration\n if (b.equals(step.prev.board)) continue;\n \n // creates possible board's node and adds to pq\n SearchNode nextPossibleBoard = new SearchNode();\n nextPossibleBoard.board = b;\n nextPossibleBoard.prev = step;\n nextPossibleBoard.dist = step.dist + 1;\n pq.insert(nextPossibleBoard);\n }\n step = pq.delMin(); // dequeue next step toward goal board\n }\n \n moves = step.dist;\n goalNode = step;\n\n \n }", "public int[] minimax(IBoard board,char playerSymbol){\n\n List<int[][]> array = evaluate(board);\n\n /*In that case I found max and min scores*/\n int max = 0;\n int min = 0;\n for (int[][] move:array){\n int current = evaluateLine(board,move,playerSymbol);\n int oppcurrent = evaluateLineforOpp(board,move,playerSymbol);\n\n if (max < current){\n max = current;\n }\n\n if (min < oppcurrent){\n min = oppcurrent;\n }\n }\n\n for (int[][] move:array){\n int current = evaluateLine(board,move,playerSymbol);\n int oppcurrent = evaluateLineforOpp(board,move,playerSymbol);\n\n /*Here I check end score(bestscore)*/\n int end = 0;\n if(Math.abs(min) >= max){\n end = min;\n }else{\n end = max;\n }\n\n /*Here I return next place on table*/\n if (end == current) {\n for (int[] m : move) {\n char place = board.getTileSymbol(m[0], m[1]);\n if (place == '.') {\n return new int[]{m[0], m[1]};\n }\n }\n }else if(end == oppcurrent){\n for (int[] m : move) {\n char place = board.getTileSymbol(m[0], m[1]);\n if (place == '.') {\n return new int[]{m[0], m[1]};\n }\n }\n }\n\n }\n\n throw new RuntimeException(\"I don't know where to play!\");\n }", "public void greedyBFS(String input)\r\n\t{\r\n\t\tNode root_gbfs = new Node (input);\r\n\t\tNode current = new Node(root_gbfs.getState());\r\n\t\t\r\n\t\tNodeComparator gbfs_comparator = new NodeComparator();\r\n\t\tPriorityQueue<Node> queue_gbfs = new PriorityQueue<Node>(12, gbfs_comparator);\r\n\t\tArrayList<String> visited = new ArrayList<String>();\r\n\t\tArrayList<String> children = new ArrayList<String>();\r\n\t\t\r\n\t\tint nodes_popped = 0;\r\n\t\tint pqueue_max_size = 0;\r\n\t\tint pq_size = 0;\r\n\t\t\r\n\t\tcurrent.cost = 0;\r\n\t\tcurrent.total_cost = 0;\r\n\t\t\r\n\t\twhile(!goal_gbfs)\r\n\t\t{\r\n\t\t\tvisited.add(current.getState());\r\n\t\t\tchildren = Successor.findChildren(current.getState());\r\n\t\t\t\r\n\t\t\tfor (String a : children)\r\n\t\t\t{\r\n\t\t\t\t\r\n\t\t\t\tif (visited.contains(a))\r\n\t\t\t\t{\r\n\t\t\t\t\tcontinue;\r\n\t\t\t\t}\r\n\t\t\t\t\r\n\t\t\t\t\r\n\t\t\t\t\tNode nino = new Node(a);\r\n\t\t\t\t\tcurrent.children_nodes.add(nino);\r\n\t\t\t\t\tvisited.add(nino.getState());\r\n\t\t\t\t\t\r\n\t\t\t\t\tint cost = isCost(current.getState(), nino.getState());\r\n\t\t\t\t\tnino.cost = cost;\r\n\t\t\t\t\tnino.parent = current;\r\n\t\t\t\t\tint greedy_cost = greedybfsCost(nino.getState(), root_gbfs.getState());\r\n\t\t\t\t\tnino.setTotalCost(greedy_cost);\r\n\t\t\t\t\t\r\n\t\t\t\t\tif (!queue_gbfs.contains(nino))\r\n\t\t\t\t\t{\r\n\t\t\t\t\t\tqueue_gbfs.add(nino);\r\n\t\t\t\t\t\tpq_size++;\r\n\t\t\t\t\t}\r\n\t\t\t\t\t\r\n\t\t\t\t\t// Repeated State checking. Removing the same node from PQ if the path cost is less then the current one \r\n\t\t\t\t\telse if (queue_gbfs.contains(nino))\r\n\t\t\t\t\t{\r\n\t\t\t\t\t\tfor (Node original : queue_gbfs)\r\n\t\t\t\t\t\t{\r\n\t\t\t\t\t\t\tif (original.equals(nino))\r\n\t\t\t\t\t\t\t{\r\n\t\t\t\t\t\t\t\tNode copy = original;\r\n\t\t\t\t\t\t\t\tif (nino.getTotalCost() < copy.getTotalCost())\r\n\t\t\t\t\t\t\t\t{\r\n\t\t\t\t\t\t\t\t\tqueue_gbfs.remove(copy);\r\n\t\t\t\t\t\t\t\t\tqueue_gbfs.add(nino);\r\n\t\t\t\t\t\t\t\t}\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\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\tcurrent = queue_gbfs.poll();\r\n\t\t\tnodes_popped++;\r\n\t\t\t\r\n\t\t\tif (pq_size > pqueue_max_size)\r\n\t\t\t{\r\n\t\t\t\tpqueue_max_size = pq_size;\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\tpq_size--;\r\n\t\t\tgoal_gbfs = isGoal(current.getState());\r\n\t\t\t\r\n\t\t}\r\n\t\t\r\n\t\tgoal_gbfs = false;\r\n\t\tSystem.out.println(\"GBFS Solved!!\");\r\n\t\tSolution.performSolution(current, root_gbfs, nodes_popped, pqueue_max_size);\r\n\t}", "public Stack<MazePoint> DepthFirstSearch(int row, int column)\n {\n //cMaze[row][column].wasVisited()\n if(cMaze[row][column].isExit())\n {\n sPath.push(cMaze[row][column]);\n //print out the path\n PrintPath(sPath, true);\n return sPath;\n }\n else\n {\n //when not visit\n if(!cMaze[row][column].wasVisited())\n {\n if(cMaze[row][column].hasItem())\n {\n String itemName = cMaze[row][column].pickUpItem();\n Item item = new Item(itemName);\n //check if the item is in the hashmap\n if(availableItemsHashMap.get(item) != null)\n {\n inventoryList.insert(itemName);\n }\n else\n {\n cMaze[row][column].dropItem();\n }\n }\n //mark as vist\n cMaze[row][column].markVisited();\n //push into stack\n sPath.push(cMaze[row][column]);\n }\n //determine where to traverse next (S, E, W, N)\n //recursively\n if(cMaze[row+1][column].canBeNavigated() || cMaze[row+1][column].isExit())// or (cMaze[row+1][column] != VISITED_MARKER && cMaze[row+1][column] != 'W')\n {\n return DepthFirstSearch(row+1, column);\n }\n else if(cMaze[row][column+1].canBeNavigated() || cMaze[row][column+1].isExit())\n {\n return DepthFirstSearch(row, column+1);\n }\n else if(cMaze[row][column-1].canBeNavigated() || cMaze[row][column-1].isExit())\n {\n return DepthFirstSearch(row, column-1);\n }\n else if(cMaze[row-1][column].canBeNavigated() || cMaze[row-1][column].isExit())\n {\n return DepthFirstSearch(row-1, column);\n }\n //no where could go, then return\n else\n {\n sPath.pop();\n if(sPath.isEmpty())\n {\n //print nothing found\n PrintPath(sPath, false);\n return sPath;\n }\n MazePoint mp = sPath.top();\n int mpRow = mp.getRow();\n int mpColumn = mp.getColumn();\n return DepthFirstSearch(mpRow, mpColumn);\n }\n }\n }", "public void solve() {\n /** To solve the traveling salesman problem:\n * Set up the graph, choose a starting node, then call the recursive backtracking method and pass it the starting node.\n */\n\n // We need to pass a starting node to recursive backtracking method\n Node startNode = null;\n\n // Grab a node, any node...\n for( Node n : graph.nodes() ) {\n startNode = n;\n break;\n }\n\n // Visit the first node\n startNode.visit();\n\n // Add first node to the route\n this.route[0] = startNode;\n\n // Pass the number of choices made\n int nchoices = 1;\n\n // Recursive backtracking\n explore(startNode, nchoices );\n\n\n }", "public Solver(Board initial) {\n\t\tgoal = null;\n\t\tminpq = new MinPQ<Solver.SearchNode>();\n\t\tminpqTwin = new MinPQ<SearchNode>();\n\t\tcheck = new HashMap<String, Integer>();\n\t\tcheckTwin = new HashMap<String, Integer>();\n\t\t\n\t\tminpq.insert(new SearchNode(initial, null));\n\t\tminpqTwin.insert(new SearchNode(initial.twin(), null));\n\t\t\n\t\tcheck.put(initial.toString(), 1);\n\t\tcheckTwin.put(initial.twin().toString(), 1);\n\t\t\n\t\t//StdOut.println(\"Hamming =\" + initial.hamming());\n\t\t//StdOut.println(\"Manhattan =\" + initial.manhattan());\n\t\t//StdOut.println(\"Original:\\n\" + initial.toString());\n\t\t//StdOut.println(\"Twin:\\n\" + initial.twin().toString());\n\t\t\n\t\tSearchNode minNode = minpq.delMin();\n\t\tSearchNode minNodeTwin = minpqTwin.delMin();\n\t\t\n\t\twhile (true) {\n\t\t\t\n\t\t\tif (minNode.getBoard().isGoal()) {\n\t\t\t\tgoal = minNode;\n\t\t\t\tbreak;\n\t\t\t}\n\t\t\tif (minNodeTwin.getBoard().isGoal()) {\n\t\t\t\tgoal = null;\n\t\t\t\tbreak;\n\t\t\t}\n\t\t\t\n\t\t\tpushNodes(minNode, minpq, check);\n\t\t\tpushNodes(minNodeTwin, minpqTwin, checkTwin);\n\t\t\t\n\t\t\tminNode = minpq.delMin();\n\t\t\tminNodeTwin = minpqTwin.delMin();\n\t\t}\n\t}", "public String[] search() {\n\t\t\n\t\troot.setScore(0);\n\t\tleaves = 0;\n\t\t\n\t\t/*\n\t\t * Interrupt the think() thread so we can have the updated game tree\n\t\t */\n\t\t\n\t\tString[] move = new String[2];\n\t\t\n\t\t// Find the max or min value for the white or black player respectively\n\t\tfloat val = alphaBeta(root, max_depth, Double.NEGATIVE_INFINITY, Double.POSITIVE_INFINITY, player);\n\t\t\n\t\t// Retrieve the move that has the min/max vlaue\n\t\tArrayList<Node> moves = root.getChildren();\n\t\tfor(Node n : moves) {\n\t\t\tif(Float.compare(n.value, val) == 0) {\n\t\t\t\tint[] m = new int[6];\n\t\t\t\tint encodedM = n.move;\n\t\t\t\t\n\t\t\t\t// Decode the move\n\t\t\t\tfor(int i = 0; i < 6; i++) {\n\t\t\t\t\tm[i] = encodedM & 0xf;\n\t\t\t\t\tencodedM >>= 4;\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t// Convert the array into a string array with the format [0] => \"a7-b7\", [1] => \"b5\"\n\t\t\t\tmove[0] = ((char)(m[0] + 97)) + \"\" + (m[1]) + \"-\" + ((char)(m[2] + 97)) + \"\" + (m[3]);\n\t\t\t\tmove[1] = ((char)(m[4] + 97)) + \"\" + (m[5]);\n\t\t\t\t\n\t\t\t\t// Play the move on the AI's g_board, set the root to this node and break out of the loop\n\t\t\t\tg_board.doMove(n.move);\n\t\t\t\t\n\t\t\t\t// Reset the root rather than set it to a branch since we can currently only achieve a depth of 2-ply\n\t\t\t\troot.getChildren().clear();\n\t\t\t\t\n\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\t\t\n\t\tif(leaves <= 2000) {\n\t\t\tmax_depth++;\n\t\t}\n\t\t\n\t\t/*\n\t\t * Start the think() thread\n\t\t */\n\t\t\n\t\treturn move;\n\t}", "public void aEstrella (String input)\r\n\t{\r\n\t\tNode root_aEstrella = new Node (input);\r\n\t\tNode current = new Node(root_aEstrella.getState());\r\n\t\t\r\n\t\tHeuristicComparator aEstrella_comparator = new HeuristicComparator();\r\n\t\tPriorityQueue<Node> queue_gbfs = new PriorityQueue<Node>(12, aEstrella_comparator);\r\n\t\tArrayList<String> visited = new ArrayList<String>();\r\n\t\tArrayList<String> children = new ArrayList<String>();\r\n\t\t\r\n\t\tint nodes_popped = 0;\r\n\t\tint pqueue_max_size = 0;\r\n\t\tint pq_size = 0;\r\n\t\t\r\n\t\tcurrent.cost = 0;\r\n\t\tcurrent.setTotalCost(0);\r\n\t\t\r\n\t\twhile(!goal_aEstrella)\r\n\t\t{\r\n\t\t\tvisited.add(current.getState());\r\n\t\t\tchildren = Successor.findChildren(current.getState());\r\n\t\t\t\r\n\t\t\tfor (String a : children)\r\n\t\t\t{\r\n\t\t\t\t\r\n\t\t\t\tif (visited.contains(a))\r\n\t\t\t\t{\r\n\t\t\t\t\tcontinue;\r\n\t\t\t\t}\r\n\t\t\t\t\r\n\t\t\t\t\r\n\t\t\t\t\tNode nino = new Node(a);\r\n\t\t\t\t\tcurrent.children_nodes.add(nino);\r\n\t\t\t\t\tvisited.add(nino.getState());\r\n\t\t\t\t\t\r\n\t\t\t\t\tint cost = isCost(current.getState(), nino.getState());\r\n\t\t\t\t\tnino.cost = cost;\r\n\t\t\t\t\tnino.parent = current;\r\n\t\t\t\t\tint greedy_cost = greedybfsCost(nino.getState(), root_aEstrella.getState());\r\n\t\t\t\t\tnino.setTotalCost(nino.parent.getTotalCost() + nino.cost);\r\n\t\t\t\t\t\r\n\t\t\t\t\t// f(n) = g(n) + h(n)\r\n\t\t\t\t\tnino.setHeuristicCost(nino.getTotalCost() + greedy_cost);\r\n\t\t\t\t\t\r\n\t\t\t\t\tif (!queue_gbfs.contains(nino))\r\n\t\t\t\t\t{\r\n\t\t\t\t\t\tqueue_gbfs.add(nino);\r\n\t\t\t\t\t\tpq_size++;\r\n\t\t\t\t\t}\r\n\t\t\t\t\t\r\n\t\t\t\t\t// Repeated State checking. Removing the same node from PQ if the path cost is less then the current one \r\n\t\t\t\t\telse if (queue_gbfs.contains(nino))\r\n\t\t\t\t\t{\r\n\t\t\t\t\t\tfor (Node original : queue_gbfs)\r\n\t\t\t\t\t\t{\r\n\t\t\t\t\t\t\tif (original.equals(nino))\r\n\t\t\t\t\t\t\t{\r\n\t\t\t\t\t\t\t\tNode copy = original;\r\n\t\t\t\t\t\t\t\tif (nino.getHeuristicCost() < copy.getHeuristicCost())\r\n\t\t\t\t\t\t\t\t{\r\n\t\t\t\t\t\t\t\t\tqueue_gbfs.remove(copy);\r\n\t\t\t\t\t\t\t\t\tqueue_gbfs.add(nino);\r\n\t\t\t\t\t\t\t\t}\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}\r\n\t\t\t\r\n\t\t\tcurrent = queue_gbfs.poll();\r\n\t\t\tnodes_popped++;\r\n\t\t\t\r\n\t\t\tif (pq_size > pqueue_max_size)\r\n\t\t\t{\r\n\t\t\t\tpqueue_max_size = pq_size;\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\tpq_size--;\r\n\t\t\tgoal_aEstrella = isGoal(current.getState());\r\n\t\t\t\r\n\t\t}\r\n\t\t\r\n\t\tgoal_aEstrella = false;\r\n\t\tSystem.out.println(\"A* Solved!!\");\r\n\t\tSolution.performSolution(current, root_aEstrella, nodes_popped, pqueue_max_size);\r\n\t}", "static void solveKTUtil(int x, int y, int movei,\n int sol[][], int xMove[],\n int yMove[], List<int[][]> result) {\n int k, next_x, next_y;\n if (movei == N * N){\n \tresult.add(copy(sol));\n return ;\n }\n\n /* Try all next moves from the current coordinate\n x, y */\n for (k = 0; k < 8; k++) {\n next_x = x + xMove[k];\n next_y = y + yMove[k];\n if (isSafe(next_x, next_y, sol)) {\n sol[next_x][next_y] = movei;\n solveKTUtil(next_x, next_y, movei + 1,\n sol, xMove, yMove, result);\n \n sol[next_x][next_y] = -1;// backtracking\n }\n }\n\n \n }", "@Override\n\tpublic direction[] Solve(nPuzzle aPuzzle) {\n\t\taddToFrontier(aPuzzle.StartState);\n\t\t\n\t\t// While the open list is not empty:\n\t\twhile(Frontier.size() > 0) {\n\t\t\t// Find the frontier with the lowest F value.\n\t\t\tPuzzleState q = popFrontier();\n\t\t\t\n\t\t\tArrayList<PuzzleState> newStates = q.explore();\n\t\t\t\n\t\t\tfor(PuzzleState n : newStates) {\n\t\t\t\t// If goal state return path to state.\n\t\t\t\tif(n.equals(aPuzzle.GoalState))\n\t\t\t\t\treturn n.GetPathToState();\n\t\t\t\t// Else add state to open list.\n\t\t\t\telse {\n\t\t\t\t\tn.HeuristicValue = HeuristicValue(n, aPuzzle.GoalState);\n\t\t\t\t\tn.setEvaluationFunction(n.HeuristicValue + n.Cost);\n\t\t\t\t\taddToFrontier(n);\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t}\n\t\t\n\t\treturn null;\n\t}", "private void gameTree(MinimaxNode<GameState> currentNode, int depth, int oIndex){\n currentNode.setNodeIndex(oIndex); \n if (depth == 0) {\n return;\n }\n else{\n if (currentNode.getState().isDead(oIndex)){ //checks to see if current player is dead, if so, just skips their moves\n int newIndex = (oIndex + 1) % currentNode.getState().getNrPlayers();\n/* if(oIndex == 3){\n newIndex = 0;\n }\n else{\n newIndex = oIndex + 1;\n }*/\n gameTree(currentNode, depth-1, newIndex);\n }\n else{\n //this if statement sets up chance nodes, if the target has been met it will create 5 children nodes with randomly generated new target postitions \n if(!currentNode.getState().hasTarget()){\n currentNode.setChanceNode();\n for(int i = 1; i <= 5; i++){\n try{\n GameState newState = (GameState)currentNode.getState().clone();\n newState.chooseNextTarget();\n MinimaxNode<GameState> childNode = new MinimaxNode(newState);\n childNode.setProbability(0.2);\n currentNode.addChild(childNode); \n }\n catch (CloneNotSupportedException e){\n System.out.println(\"Clone not excepted\");\n }\n \n }\n for (int i = 0; i < currentNode.getNumberOfChildren(); i++){\n gameTree(currentNode.getChildren().get(i), depth, oIndex);\n }\n\n }\n else{\n List<Integer> options = new ArrayList();\n for (int i = 1; i <= 4; i++) {\n if (currentNode.getState().isLegalMove(oIndex, i)){\n options.add(i);\n }\n }\n for (int i = 0; i < options.size(); i++){\n try{\n GameState newState = (GameState)currentNode.getState().clone();\n newState.setOrientation(oIndex, options.get(i));\n newState.updatePlayerPosition(oIndex);\n MinimaxNode<GameState> childNode = new MinimaxNode(newState);\n currentNode.addChild(childNode);\n }\n catch (CloneNotSupportedException e){\n System.out.println(\"Clone not excepted\");\n }\n }\n int newIndex = (oIndex + 1) % currentNode.getState().getNrPlayers();\n /* if(oIndex == 3){\n newIndex = 0;\n }\n else{\n newIndex = oIndex + 1;\n }*/\n for (int i = 0; i < currentNode.getNumberOfChildren(); i++){\n gameTree(currentNode.getChildren().get(i), depth-1, newIndex);\n }\n } \n } \n }\n }", "private static void findOptimalTree(int i, int j, int[][] nodeMatrix) {\n\t\tif(i!=j){\n\t\t\tint root = nodeMatrix[i][j];\n\t\t\tSystem.out.println(\" root for \"+i+\" to \"+j+\" elements would be \"+root);\n\t\t\tfindOptimalTree(i, root-1, nodeMatrix);\n\t\t\tfindOptimalTree(root+1, j, nodeMatrix);\n\t\t}\n\t}", "private void analyzeForObstacles() {\n \t\n \t\n \tStack<Rect> bestFound = new Stack<Rect>();//This is a stack as the algorithm moves along x linearly\n \tboolean[][] blackWhiteGrid = getBlackWhiteGrid();\n \tint[] cache = new int[grid.length];\n \t\n \twhile (true) {\n\t\t\tboolean noneFound = true;\n\t\t\t\n\t\t\tfor (int i = 0; i<cache.length; i++)\n\t\t\t\tcache[i] = 0;\n\t\t\tfor (int llx = grid.length -1; llx >= 0; llx--) {\n\t\t\t\tupdate_cache(blackWhiteGrid,cache, llx);\n\t\t\t\tfor (int lly = 0; lly < grid.length; lly++) {\n\t\t\t\t\tRect bestOfRound = new Rect(llx,lly,llx,lly);\n\t\t\t\t\tint y = lly;\n\t\t\t\t\tint x_max = 9999;\n\t\t\t\t\tint x = llx;\n\t\t\t\t\twhile (y+1<grid.length && blackWhiteGrid[llx][y]) {\n\t\t\t\t\t\ty++;\n\t\t\t\t\t\tx = Math.min(llx+cache[y]-1, x_max);\n\t\t\t\t\t\tx_max = x;\n\t\t\t\t\t\tRect tryRect = new Rect(llx,lly-1,x,y);\n\t\t\t\t\t\tif (tryRect.area() > bestOfRound.area()) {\n\t\t\t\t\t\t\tbestOfRound = tryRect;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tif (bestOfRound.area() > 40) {\n\t\t\t\t\t\tif (noneFound) {\n\t\t\t\t\t\t\tbestFound.push(bestOfRound);\n\t\t\t\t\t\t\tnoneFound = false;\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse {\n\t\t\t\t\t\t\tRect lastRect = bestFound.peek();\n\t\t\t\t\t\t\tif (lastRect.area() < bestOfRound.area()) {\n\t\t\t\t\t\t\t\tbestFound.pop();\n\t\t\t\t\t\t\t\tbestFound.push(bestOfRound);\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\tif (noneFound)\n\t\t\t\tbreak;\n\t\t\t\n\t\t\tclearFoundRectangle(blackWhiteGrid, bestFound.peek());\n \t}\n \t\n \t//add found rectanlges\n \tobstacles.clear();\n \tobstacles.addAll(bestFound);\n \tSystem.out.println(\"Sweep done:\");\n \tfor (Rect r : bestFound){\n \t\tSystem.out.println(\"Rect: llx=\" + (r.llx-400) + \"\\tlly=\" + (r.lly-400) + \"\\turx=\" + (r.urx-400) + \"\\tury=\" + (r.ury-400));\n \t\tList<Point2D.Double> corners = new ArrayList<Point2D.Double>();\n \t\tcorners.add(new Point2D.Double((r.llx-400),(r.lly-400)));\n \t\tcorners.add(new Point2D.Double((r.llx-400),(r.ury-400)));\n \t\tcorners.add(new Point2D.Double((r.urx-400),(r.lly-400)));\n \t\tcorners.add(new Point2D.Double((r.urx-400),(r.ury-400)));\n \t\tobstaclesF.add(new Obstacle(corners));\n \t}\n \t\n \ttoExplore.clear();\n \tint i = 0;\n \tRandom rand = new Random();\n \twhile (toExplore.size() < 10 && i < 1000) {\n \t\tint x = rand.nextInt(grid.length);\n \t\tint y = rand.nextInt(grid.length);\n \t\tif (grid[x][y] == .5) {\n \t\t\ttoExplore.add(new Flag(\"blue\",x,y));\n \t\t}\n \t}\n }", "private void solve(int x, int y, boolean draw) {\n \t\t// these are the walls of the maze, maze solver should not go beyond\n \t\t// walls\n \t\t// if (x == 0 || y == 0 || x == N + 1 || y == N + 1) {\n \t\t// return;\n \t\t// }\n \n \t\t// if we have already visited this position\n \t\t// or if deep levels of the recursion have found the target\n \t\tif (foundTarget || visited[x][y])\n \t\t\treturn;\n \n \t\t// this position is new, mark it as visited\n \t\tvisited[x][y] = true;\n \n \t\tif (draw) {\n \t\t\t// Draw a blue dot to show we have been here\n \t\t\tStdDraw.setPenColor(StdDraw.BLUE);\n \t\t\tStdDraw.filledCircle(x + 0.5, y + 0.5, 0.25);\n \t\t\tStdDraw.show(SOLVER_SPEED);\n \t\t}\n \n \t\t// if we have reached the maze solve target\n \t\tif (x == target.x && y == target.y) {\n \t\t\tfoundTarget = true;\n \t\t}\n \n \t\t// Try go another place\n \t\tif (!north[x][y])\n \t\t\tsolve(x, y + 1, draw);\n \t\tif (!east[x][y])\n \t\t\tsolve(x + 1, y, draw);\n \t\tif (!south[x][y])\n \t\t\tsolve(x, y - 1, draw);\n \t\tif (!west[x][y])\n \t\t\tsolve(x - 1, y, draw);\n \n \t\tif (foundTarget)\n \t\t\treturn;\n \n \t\tif (draw) {\n \t\t\t// Draw a grey dot to show we have backtracked\n \t\t\tStdDraw.setPenColor(StdDraw.GRAY);\n \t\t\tStdDraw.filledCircle(x + 0.5, y + 0.5, 0.25);\n \t\t\tStdDraw.show(SOLVER_SPEED);\n \t\t}\n \t}", "static double addHeuristic1(GameState c, boolean isMaxNode) {\n\t\t// Value returned will be absolute. If its max node, this config is good\n\t\t// then value will be positive. If its min node,\n\t\t// and this config is good for min, then value will be negative\n\n\t\tint i, j, vacant_spaces;\n\t\t// Compute : Feasible Moves for self\n\t\tint self_feasible_moves = 0;\n\t\tint self_remaining_moves = 0;\n\t\tint opponent_feasible_moves = 0;\n\t\tint opponent_remaining_moves = 0;\n\n\t\t// Go through the board and figure out vacant spots\n\t\tvacant_spaces = 0;\n\t\tfor (i = -GameState.HALF_BOARD; i <= GameState.HALF_BOARD; i = i + 1) {\n\t\t\tif (c.getWeight(i) == 0) {\n\t\t\t\tvacant_spaces++;\n\t\t\t}\n\t\t}\n\n\t\tfor (i = 1; i <= GameState.MAX_WEIGHT; i = i + 1) {\n\t\t\t// Check if self have the weight\n\t\t\tif (c.IHaveWeight(i)) {\n\t\t\t\tself_remaining_moves++;\n\t\t\t\t// Go through all the possible positions\n\t\t\t\tfor (j = -GameState.HALF_BOARD; j < GameState.HALF_BOARD; j++) {\n\t\t\t\t\tif (c.getWeight(j) == 0) {\n\t\t\t\t\t\t// Place it and see if you tip\n\t\t\t\t\t\tc.makeMove(i, j, PlayerName.none);\n\t\t\t\t\t\tif (!c.isTipping_old()) {\n\t\t\t\t\t\t\tself_feasible_moves++;\n\t\t\t\t\t\t}\n\t\t\t\t\t\t// Now remove the weight\n\t\t\t\t\t\tc.removeMove(j);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\t// Check if opponent has this weight\n\t\t\tif (c.opponentHasWeight(i)) {\n\t\t\t\topponent_remaining_moves++;\n\t\t\t\t// Go through all the possible positions\n\t\t\t\tfor (j = -GameState.HALF_BOARD; j < GameState.HALF_BOARD; j++) {\n\t\t\t\t\t// Place the weight and see if you tip\n\t\t\t\t\tif (c.getWeight(j) == 0) {\n\t\t\t\t\t\tc.makeMove(i, j, PlayerName.none);\n\t\t\t\t\t\tif (!c.isTipping_old()) {\n\t\t\t\t\t\t\topponent_feasible_moves++;\n\t\t\t\t\t\t}\n\t\t\t\t\t\t// Now remove the weight\n\t\t\t\t\t\tc.removeMove(j);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\t// Need to take the max because one of the players may have played one\n\t\t// chance less\n\t\tif (self_remaining_moves == 0 && opponent_remaining_moves == 0) {\n\t\t\treturn 0.0;\n\t\t} else if (self_remaining_moves > opponent_remaining_moves)\n\t\t\treturn (double) (self_feasible_moves - opponent_feasible_moves)\n\t\t\t\t\t/ (double) (self_remaining_moves * vacant_spaces);\n\t\telse\n\t\t\treturn (double) (self_feasible_moves - opponent_feasible_moves)\n\t\t\t\t\t/ (double) (opponent_remaining_moves * vacant_spaces);\n\t}", "void calculating(int depth);", "public MiniMax(HeuristicFunction H,int depth) {\r\n\t\t\tsuper(H,depth);\r\n\t\t}", "private void goForSolution(MinPQ<Node> hq) {\n\t\tNode current = hq.delMin();\n\t\tif (current.board.isGoal()) {\n\t\t\tif (hq == orig) {\n\t\t\t\tresult = new ArrayList<>();\n\t\t\t\twhile (current != null) {\n\t\t\t\t\tresult.add(0, current.board);\n\t\t\t\t\tcurrent = current.parent;\n\t\t\t\t}\n\t\t\t}\n\t\t\tsolved = true;\n\t\t\treturn;\n\t\t}\n\n\t\tfor (Board neighbour : current.board.neighbors()) {\n\t\t\tif (current.parent == null || !neighbour.equals(current.parent.board)) {\n\t\t\t\thq.insert(new Node(neighbour, current.moves + 1, current));\n\t\t\t}\n\t\t}\n\t}", "private List<Pair<Integer, Integer>> getBestPath(Pair<Integer, Integer> curLocation, Pair<Integer, Integer> dest) {\n\t\tList<Pair<Integer, Integer>> path = new LinkedList<Pair<Integer, Integer>>();\n\t\t\n\t\t\n\t\tNode current = new Node(curLocation.getX(), curLocation.getY(), getHitProbability(curLocation.getX(), curLocation.getY()));\n\t\tNode target = new Node(dest.getX(), dest.getY(), getHitProbability(dest.getX(), dest.getY()));\n\t\tList<Node> openSet = new ArrayList<>();\n List<Node> closedSet = new ArrayList<>();\n \n \n while (true) {\n openSet.remove(current);\n List<Node> adjacent = getAdjacentNodes(current, closedSet, target);\n\n // Find the adjacent node with the lowest heuristic cost.\n for (Node neighbor : adjacent) {\n \tboolean inOpenset = false;\n \tList<Node> openSetCopy = new ArrayList<>(openSet);\n \tfor (Node node : openSetCopy) {\n \t\tif (neighbor.equals(node)) {\n \t\t\tinOpenset = true;\n \t\t\tif (neighbor.getAccumulatedCost() < node.getAccumulatedCost()) {\n \t\t\t\topenSet.remove(node);\n \t\t\t\topenSet.add(neighbor);\n \t\t\t}\n \t\t}\n \t}\n \t\n \tif (!inOpenset) {\n \t\topenSet.add(neighbor);\n \t}\n }\n\n // Exit search if done.\n if (openSet.isEmpty()) {\n System.out.printf(\"Target (%d, %d) is unreachable from position (%d, %d).\\n\",\n target.getX(), target.getY(), curLocation.getX(), curLocation.getY());\n return null;\n } else if (/*isAdjacent(current, target)*/ current.equals(target)) {\n break;\n }\n\n // This node has been explored now.\n closedSet.add(current);\n\n // Find the next open node with the lowest cost.\n Node next = openSet.get(0);\n for (Node node : openSet) {\n if (node.getCost(target) < next.getCost(target)) {\n next = node;\n }\n }\n// System.out.println(\"Moving to node: \" + current);\n current = next;\n }\n \n // Rebuild the path using the node parents\n path.add(new Pair<Integer, Integer>(curLocation.getX(), curLocation.getY()));\n while(current.getParent() != null) {\n \tcurrent = current.getParent();\n \tpath.add(0, new Pair<Integer, Integer>(current.getX(), current.getY()));\n }\n \n if (path.size() > 1) {\n \tpath.remove(0);\n }\n \n\t\treturn path;\n\t}", "public Queen[] lowestHeuristic(Queen[] state){\n Queen[] min = new Queen[n];\n int minHeuristic = general.getHeuristic(state);\n Queen[] curr = new Queen[n];\n\n //Copy the state in min and curr\n for(int i = 0; i < n; i++){\n min[i] = new Queen(state[i].getRow(), state[i].getColumn());\n curr[i] = new Queen(state[i].getRow(), state[i].getColumn());\n }\n\n //Iterate all columns\n for(int i = 0; i < n; i++){\n if (i>0)\n curr[i-1] = new Queen (state[i-1].getRow(), state[i-1].getColumn());\n curr[i] = new Queen (0, curr[i].getColumn());\n //Iterate rows\n for(int j = 0; j < n; j++){\n\n //Check if a minimum is found\n if(general.getHeuristic(curr) < minHeuristic){\n minHeuristic = general.getHeuristic(curr);\n\n for(int k = 0; k < n; k++)\n min[k] = new Queen(curr[k].getRow(), curr[k].getColumn());\n }\n\n //Move the queen\n if(curr[i].getRow() != n-1)\n curr[i].move();\n }\n }\n return min;\n }", "void testSearches(Tester t) {\n Vertex v1 = new Vertex(10, 10);\n Vertex v2 = new Vertex(10, 11);\n Vertex v3 = new Vertex(10, 12);\n\n Edge e1 = new Edge(v1, v2, 1);\n Edge e2 = new Edge(v2, v3, 1);\n\n IList<Vertex> map = new Cons<Vertex>(v1, new Cons<Vertex>(v2, new Cons<Vertex>(\n v3, new Empty<Vertex>())));\n\n Player player = new Player(map);\n DepthFirst dp = new DepthFirst(map);\n BreadthFirst bp = new BreadthFirst(map);\n\n t.checkExpect(player.current, v1);\n t.checkExpect(player.finished, false);\n\n t.checkExpect(bp.hasNext(), true);\n t.checkExpect(bp.next(), new Queue<Vertex>());\n\n t.checkExpect(dp.hasNext(), true);\n t.checkExpect(dp.next(), new Stack<Vertex>());\n\n t.checkExpect(player.move(true, e1), v2);\n\n t.checkExpect(player.current, v2);\n t.checkExpect(player.finished, false);\n\n t.checkExpect(bp.hasNext(), false);\n t.checkExpect(bp.next(), v3);\n\n t.checkExpect(dp.hasNext(), false);\n t.checkExpect(dp.next(), v3);\n\n t.checkExpect(player.move(true, e2), v3);\n\n player.finished = true;\n\n t.checkExpect(player.current, v3);\n t.checkExpect(player.finished, true);\n\n Queue<Vertex> q = new Queue<Vertex>(map);\n\n q.enqueue(new Vertex(5, 5));\n\n Deque<Vertex> dq = new Deque<Vertex>();\n dq.addAtHead(v1);\n dq.addAtTail(v2);\n dq.addAtTail(new Vertex(5, 5));\n\n\n t.checkExpect(q.isEmpty(), false);\n t.checkExpect(q.contents, dq);\n\n Stack<Vertex> stack = new Stack<Vertex>(map);\n\n t.checkExpect(stack.isEmpty(), false);\n dq.removeFromHead();\n t.checkExpect(stack.pop(), dq);\n\n t.checkExpect(dp.next(), v2);\n t.checkExpect(bp.hasNext(), true);\n\n }", "protected Object[] getBestMove(Solution soln, Move[] moves, ObjectiveFunction objectiveFunction, TabuList tabuList, AspirationCriteria aspirationCriteria, boolean maximizing, boolean chooseFirstImprovingMove)\n/* */ {\n/* 260 */ int threads = getThreads();\n/* 261 */ if (threads == 1)\n/* */ {\n/* 263 */ return SingleThreadedTabuSearch.getBestMove(soln, moves, objectiveFunction, tabuList, aspirationCriteria, maximizing, chooseFirstImprovingMove, this);\n/* */ }\n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* 271 */ Move bestMove = null;\n/* 272 */ double[] bestMoveVal = null;\n/* 273 */ boolean bestMoveTabu = false;\n/* 274 */ NeighborhoodHelper[] helpers = getHelpers();\n/* */ \n/* */ \n/* 277 */ int numGroups = helpers.length;\n/* 278 */ int nominalSize = moves.length / numGroups;\n/* 279 */ Move[][] moveGroups = new Move[numGroups][];\n/* */ \n/* */ \n/* 282 */ for (int i = 0; i < numGroups - 1; i++)\n/* */ {\n/* 284 */ moveGroups[i] = new Move[nominalSize];\n/* 285 */ System.arraycopy(moves, i * nominalSize, moveGroups[i], 0, nominalSize);\n/* */ }\n/* */ \n/* */ \n/* */ \n/* */ \n/* 291 */ moveGroups[(numGroups - 1)] = new Move[nominalSize + moves.length % numGroups];\n/* 292 */ System.arraycopy(moves, (numGroups - 1) * nominalSize, moveGroups[(numGroups - 1)], 0, moveGroups[(numGroups - 1)].length);\n/* */ \n/* */ \n/* */ \n/* 296 */ for (int i = 0; i < numGroups; i++) {\n/* 297 */ helpers[i].setWork(soln, moveGroups[i], objectiveFunction, tabuList, aspirationCriteria, maximizing, chooseFirstImprovingMove, this);\n/* */ }\n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* 304 */ Object[][] bestMoves = new Object[numGroups][];\n/* 305 */ for (int i = 0; i < numGroups; i++)\n/* */ {\n/* */ \n/* 308 */ Object[] contender = helpers[i].getBestMove();\n/* */ \n/* */ \n/* 311 */ Move newMove = (Move)contender[0];\n/* 312 */ double[] newObjVal = (double[])contender[1];\n/* 313 */ boolean newMoveTabu = ((Boolean)contender[2]).booleanValue();\n/* */ \n/* */ \n/* */ \n/* 317 */ if (bestMove == null)\n/* */ {\n/* 319 */ bestMove = newMove;\n/* 320 */ bestMoveVal = newObjVal;\n/* 321 */ bestMoveTabu = newMoveTabu;\n/* */ \n/* */ \n/* */ \n/* */ \n/* */ }\n/* 327 */ else if (SingleThreadedTabuSearch.isFirstBetterThanSecond(newObjVal, bestMoveVal, maximizing))\n/* */ {\n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* 335 */ if ((bestMoveTabu) || (!newMoveTabu)) {\n/* 336 */ bestMove = newMove;\n/* 337 */ bestMoveVal = newObjVal;\n/* 338 */ bestMoveTabu = newMoveTabu;\n/* */ \n/* */ }\n/* */ \n/* */ \n/* */ }\n/* 344 */ else if ((bestMoveTabu) && (newMoveTabu)) {\n/* 345 */ bestMove = newMove;\n/* 346 */ bestMoveVal = newObjVal;\n/* 347 */ bestMoveTabu = newMoveTabu;\n/* */ }\n/* */ }\n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* 355 */ return new Object[] { bestMove, bestMoveVal, new Boolean(bestMoveTabu) };\n/* */ }", "@SuppressWarnings(\"null\")\n\tpublic static void optimalRecursiveSolution (Node Tree, int target) {\n\t\tNode Closest = null;\n\t\tClosest.val = Integer.MAX_VALUE;\n\t\tNode ret = recursiveHelper(Tree, target, Closest);\n\t\tSystem.out.println(String.format(\"%d\", ret.val));\n\t}", "public void aEstrella2 (String input)\r\n\t{\r\n\t\tNode root_aEstrella2 = new Node (input);\r\n\t\tNode current = new Node(root_aEstrella2.getState());\r\n\t\t\r\n\t\tHeuristicComparator aEstrella_comparator = new HeuristicComparator();\r\n\t\tPriorityQueue<Node> queue_gbfs = new PriorityQueue<Node>(12, aEstrella_comparator);\r\n\t\tArrayList<String> visited = new ArrayList<String>();\r\n\t\tArrayList<String> children = new ArrayList<String>();\r\n\t\t\r\n\t\tint nodes_popped = 0;\r\n\t\tint pqueue_max_size = 0;\r\n\t\tint pq_size = 0;\r\n\t\t\r\n\t\tcurrent.cost = 0;\r\n\t\t\r\n\t\twhile(!goal_aEstrella2)\r\n\t\t{\r\n\t\t\tvisited.add(current.getState());\r\n\t\t\tchildren = Successor.findChildren(current.getState());\r\n\t\t\t\r\n\t\t\tfor (String a : children)\r\n\t\t\t{\r\n\t\t\t\t\r\n\t\t\t\tif (visited.contains(a))\r\n\t\t\t\t{\r\n\t\t\t\t\tcontinue;\r\n\t\t\t\t}\r\n\t\t\t\t\r\n\t\t\t\t\r\n\t\t\t\t\tNode nino = new Node(a);\r\n\t\t\t\t\tcurrent.children_nodes.add(nino);\r\n\t\t\t\t\tvisited.add(nino.getState());\r\n\t\t\t\t\t\r\n\t\t\t\t\tint cost = isCost(current.getState(), nino.getState());\r\n\t\t\t\t\tnino.cost = cost;\r\n\t\t\t\t\tnino.parent = current;\r\n\t\t\t\t\tint manhattanD = manhattanDistance(nino.getState(), root_aEstrella2.getState());\r\n\t\t\t\t\tnino.setTotalCost(nino.parent.getTotalCost() + nino.cost);\r\n\t\t\t\t\t\r\n\t\t\t\t\t// f(n) = g(n) + h(n)\r\n\t\t\t\t\tnino.setHeuristicCost(nino.getTotalCost() + manhattanD);\r\n\t\t\t\t\t\r\n\t\t\t\t\tif (!queue_gbfs.contains(nino))\r\n\t\t\t\t\t{\r\n\t\t\t\t\t\tqueue_gbfs.add(nino);\r\n\t\t\t\t\t\tpq_size++;\r\n\t\t\t\t\t}\r\n\t\t\t\t\t\r\n\t\t\t\t\t// Repeated State checking. Removing the same node from PQ if the path cost is less then the current one \r\n\t\t\t\t\telse if (queue_gbfs.contains(nino))\r\n\t\t\t\t\t{\r\n\t\t\t\t\t\tfor (Node original : queue_gbfs)\r\n\t\t\t\t\t\t{\r\n\t\t\t\t\t\t\tif (original.equals(nino))\r\n\t\t\t\t\t\t\t{\r\n\t\t\t\t\t\t\t\tNode copy = original;\r\n\t\t\t\t\t\t\t\tif (nino.getHeuristicCost() < copy.getHeuristicCost())\r\n\t\t\t\t\t\t\t\t{\r\n\t\t\t\t\t\t\t\t\tqueue_gbfs.remove(copy);\r\n\t\t\t\t\t\t\t\t\tqueue_gbfs.add(nino);\r\n\t\t\t\t\t\t\t\t}\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}\r\n\t\t\t\r\n\t\t\tcurrent = queue_gbfs.poll();\r\n\t\t\tnodes_popped++;\r\n\t\t\t\r\n\t\t\tif (pq_size > pqueue_max_size)\r\n\t\t\t{\r\n\t\t\t\tpqueue_max_size = pq_size;\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\tpq_size--;\r\n\t\t\tgoal_aEstrella2 = isGoal(current.getState());\r\n\t\t\t\r\n\t\t}\r\n\t\t\r\n\t\tgoal_aEstrella2 = false;\r\n\t\tSystem.out.println(\"A*2 Solved!!\");\r\n\t\tSolution.performSolution(current, root_aEstrella2, nodes_popped, pqueue_max_size);\r\n\t}", "@Override\n public Solution solve(ISearchable domain) {\n if(domain==null)\n return null;\n Solution s2=domain.checkIfIsSmall();\n if(s2!=null){\n domain.isClear();\n return s2;\n }\n Solution sol = new Solution();\n temp.add(domain.getStartState());\n numOfNude++;\n domain.isVisit(domain.getStartState());\n ArrayList<AState> neighbors=new ArrayList<AState>();\n while(!temp.isEmpty()){\n AState curr=temp.poll();\n if(domain.isEqual(domain.getGoalState(),curr)){\n numOfNude++;\n sol =solutionPath(curr,sol);\n\n break;\n }\n neighbors=domain.getAllPossibleState(curr);\n for(int i=0;i<neighbors.size();i++){\n if(domain.isEqual(domain.getGoalState(),neighbors.get(i))){\n neighbors.get(i).pervState=curr;\n neighbors.get(i).setPrice(neighbors.get(i).getPrice()+curr.getPrice());\n numOfNude++;\n sol =solutionPath(neighbors.get(i),sol);\n break;\n }\n neighbors.get(i).pervState=curr;\n neighbors.get(i).setPrice(neighbors.get(i).getPrice()+curr.getPrice());\n temp.add(neighbors.get(i));\n numOfNude++;\n }\n }\n\n domain.isClear();\n return sol;\n }", "public Node solve()\n\t{\n\t\t// Initial problem state\n\t\tint[] initial_state = {0, 0};\n\n\t\t// Current node under consideration\n\t\tNode curr_node = new Node(initial_state, null, null);\n\n\t\t// List of frontier nodes at each iteration\n\t\t// Manipulated as a queue\n\t\tthis.frontier = new ArrayList<Node>();\n\n\t\t// List of nodes already explored\n\t\t// They are excluded from expanded frontier nodes at each iteration\n\t\tthis.explored = new ArrayList<int[]>();\n\n\t\tfrontier.add(curr_node);\n\n\t\twhile (true) {\n\t\t\t// If we have exhausted our frontier \n\t\t\t// we have no solution\n\t\t\tif (frontier.size() == 0) {\n\t\t\t\treturn null;\n\t\t\t}\n \n // Pop new node from frontier to consider\n\t\t\tcurr_node = frontier.remove(0);\n \n\t\t // Add chosen node to explored list if not already there\n\t\t\tif(!this.inExplored(curr_node.state)) {\n\t\t\t\texplored.add(curr_node.state);\t\t\t\t\n\t\t\t}\n\n // List of actions that can be applied based on the state\n // and the description of the problem\n\t\t\tAction[] actions = this.getFeasibleActions(curr_node.state);\n\n // Apply our transition model to generate child nodes \n // from current node\n\t\t\tfor (Action action : actions) {\n\t\t\t\tNode child = this.getChildNode(curr_node, action);\t\t\n\t\t\t\t\n\t\t\t\tif (!this.inFrontier(child) && !this.inExplored(child.state)) {\n\t\t\t\t\tif (this.isGoal(child.state)) {\n\t\t\t\t\t\treturn child;\n\t\t\t\t\t}\n\t\t\t\t\tfrontier.add(child);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}", "@Override\r\n\tpublic double min_value(GameState s, int depthLimit)\r\n\t{\r\n\t\tdouble stateEvaluationValue = stateEvaluator(s);\r\n\t\r\n\t\tif (depthLimit == 0)\r\n\t\t{\r\n\t\t\treturn -(stateEvaluationValue);\r\n\t\t}\r\n\t\telse\r\n\t\t{\r\n\t\t\tdouble currMin = Double.POSITIVE_INFINITY;\r\n\t\t\tint bestMove = 0;\r\n\t\t\tArrayList <Integer> succList = generateSuccessors(s.lastMove, s.takenList);\r\n\t\t\tif (succList.isEmpty())\r\n\t\t\t{\r\n\t\t\t\ts.leaf = true;\r\n\t\t\t\treturn 1;\r\n\t\t\t}\r\n\t\t\tIterator <Integer> myItr = succList.iterator();\r\n\t\t\t\r\n\t\t\twhile (myItr.hasNext())\r\n\t\t\t{\r\n\t\t\t\tint currNumber = myItr.next();\r\n\t\t\t\t\r\n\t\t\t\tdouble tempMin = currMin;\r\n\t\t\t\tint [] newList = s.takenList;\r\n\t\t\t\tnewList [currNumber] = 2;\r\n\t\t\t\tGameState newGameState = new GameState(newList, currNumber);\r\n\t\t\t\tcurrMin = Math.min(currMin, max_value(newGameState, depthLimit - 1));\r\n\r\n\t\t\t\tif (currMin < tempMin)\r\n\t\t\t\t{\r\n\t\t\t\t\tbestMove = currNumber;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\ts.bestMove = bestMove;\r\n\t\t\treturn currMin;\r\n\r\n\t\t}\r\n\t}", "public int minCostWJumps(int st,int sc,int er,int ec,int cost[][]){\n if(st==er&&sc==ec) return cost[st][sc];\n int c=0;\n for(int jump=1;jump+sc<=ec;jump++){\n c=Math.min(c,minCostWJumps(st,sc+jump,er,ec,cost));\n }\n for(int jump=1;jump+st<=er;jump++){\n c=Math.min(c,minCostWJumps(st+jump,sc,er,ec,cost));\n }\n for(int jump=1;jump+sc<=ec&&jump+st<=er;jump++){\n c=Math.min(c,minCostWJumps(st+jump,sc+jump,er,ec,cost));\n }\n return c+cost[st][sc];\n}", "public static void main(String args[]) {\n int input[] = {10, 12, 20, 35, 46};\n int freq[] = {34, 8, 50, 21, 16};\n OptimalTreeSearch ots = new OptimalTreeSearch();\n System.out.println(ots.minCost(input, freq));\n System.out.println(ots.minCostRec(input, freq));\n }", "public void getSolution(TaskState state){\n\n if(state.isNew) {\n state.isNew = false;\n state.hasSolution = true;\n }\n else {\n if(!(state.hasSolution = rollBack(state)))\n return;\n }\n\n while (state.moveStack.size() < 64 ||\n !state.moveStack.peek().getStandElement().hasNeighbour(state.graph.getFirst())){\n\n if(state.moveStack.size() == 64 && !rollBack(state)) {\n state.hasSolution = false;\n return;\n }\n\n if(state.moveStack.peek().hasNextMove())\n state.moveStack.push(\n new HorseMove(state.moveStack.peek().getNextMove())\n );\n\n else if(!rollBack(state)){\n state.hasSolution = false;\n return;\n }\n\n }\n\n }", "private int[] optimum(int x1, int y1, int x2, int y2) {\n if (lookupNodes[x1][y1][x2][y2] != Integer.MAX_VALUE) {\n return new int[]{lookupNodes[x1][y1][x2][y2], lookupDepth[x1][y1][x2][y2]};\n }\n if (hasOneColor(x1, y1, x2, y2)) {\n lookupNodes[x1][y1][x2][y2] = 1;\n lookupDepth[x1][y1][x2][y2] = 0;\n return new int[]{1, 0};\n }\n int nodes;\n int depth;\n for (int X = x1; X < x2; X++) {\n nodes = optimum(x1, y1, X, y2)[0] + optimum(X+1, y1, x2, y2)[0] + 1;\n depth = Math.max(optimum(x1, y1, X, y2)[1], optimum(X+1, y1, x2, y2)[1]) + 1;\n updateLookupNodes(nodes, x1, y1, x2, y2);\n updateLookupDepth(depth, x1, y1, x2, y2);\n }\n for (int Y = y1; Y < y2; Y++) {\n nodes = optimum(x1, y1, x2, Y)[0] + optimum(x1, Y+1, x2, y2)[0] + 1;\n depth = Math.max(optimum(x1, y1, x2, Y)[1], optimum(x1, Y+1, x2, y2)[1]) + 1;\n updateLookupNodes(nodes, x1, y1, x2, y2);\n updateLookupDepth(depth, x1, y1, x2, y2);\n }\n return new int[]{lookupNodes[x1][y1][x2][y2], lookupDepth[x1][y1][x2][y2]};\n }", "public static void main(String[] args) {\n SearchTree search = new SearchTree(new Node(INITIAL_STATE), GOAL_STATE);\n long startTime = System.currentTimeMillis();\n\n search.breadthFirstSearch();\n// search.depthFirstSearch();\n// search.iterativeDeepening(10);\n\n long finishTime = System.currentTimeMillis();\n long totalTime = finishTime - startTime;\n System.out.println(\"\\n[Elapsed time: \" + totalTime + \" milliseconds]\");\n System.out.println(\"========================================================\");\n }", "public static int[] alphaBeta(Board b, int depth, int alpha, int beta, int playerNum){\n //if the depth is 0 or the game is over return the last move\n if (depth == 0 || b.isGameOver()){\n return b.getLastMove();\n }\n //If player 1, maximize board score\n if (playerNum == Board.PLAYER_1){\n int[] bestMove = new int[3];\n bestMove[2] = Integer.MIN_VALUE;\n //check nodes of next tree\n for (Board board: Board.getPossibleBoards(b, Board.PLAYER_2)) {\n //calls minimax using next player to determine minimum board score possible\n int[] move = alphaBeta(board, depth - 1, alpha, beta, Board.PLAYER_2);\n if (move[2] > bestMove[2] && !isLosingMove(b, move[1], Board.PLAYER_2))\n bestMove = move;\n else if(move[2] == bestMove[2]){\n if (Math.abs(move[1] - 3) < Math.abs(bestMove[1] - 3)){\n bestMove = move;\n }\n else if (getRandom()){\n bestMove = move;\n }\n }\n //update upper bound\n if(bestMove[2] > alpha){\n alpha = bestMove[2];\n }\n //if bounds cross, node and children can be ignored\n if(beta < alpha)\n break;\n }\n return bestMove;\n }\n //if player 2, minimize board score\n else if(playerNum == 2){\n int[] bestMove = new int[3];\n bestMove[2] = Integer.MAX_VALUE;\n //check next nodes of tree\n for (Board board: Board.getPossibleBoards(b, Board.PLAYER_1)){\n //determine maximum loss using recursion\n int[] move = alphaBeta(board, depth - 1, alpha, beta, Board.PLAYER_1);\n if (move[2] < bestMove[2] && !isLosingMove(b, move[1], Board.PLAYER_2))\n bestMove = move;\n else if (move[2] == bestMove[2]){\n if (Math.abs(move[1] - 3) < Math.abs(bestMove[1] - 3)){\n bestMove = move;\n }\n else if (getRandom()){\n bestMove = move;\n }\n }\n //update lower bound\n if(bestMove[2] < beta){\n beta = bestMove[2];\n }\n //break if bounds intersect\n if(beta < alpha)\n break;\n }\n //minimizes max loss\n return bestMove;\n }\n return null;\n }", "private int minimax(TicTacToeBoard board, Cell thisTeam) throws TicTacToeException {\n\t\tint maxScore = -1;\n\t\tint multiplyer = 1;\n\t\tif(thisTeam != team) {\n\t\t\tmultiplyer = -1;\n\t\t}\n\t\tTicTacToeWinner winner = board.winner();\n\t\tif(winner != null) {\n\t\t\treturn evaluateWinner(winner.getCell());\n\t\t}\n\t\t\n\t\tList<Location> possibleMoves = board.emptySlots();\n\t\tint thisScore;\n\t\tTicTacToeBoard currentBoard;\n\t\t\n\t\tfor(Location l: possibleMoves) {\n\t\t\tcurrentBoard = board.copy();\n\t\t\tcurrentBoard.makeMove(thisTeam, l);\n\t\t\tthisScore = multiplyer*minimax(currentBoard, TicTacToeBoard.oppositePlayer(thisTeam));\n\t\t\tif(thisScore >= maxScore) {\n\t\t\t\tmaxScore = thisScore;\n\t\t\t}\n\t\t}\n\t\treturn multiplyer*maxScore;\n\t}", "static int minJumps(int[] arr){\n int n = arr.length;\n int[] dp = new int[n];\n for(int i = 0; i < n; i++) dp[i] = Integer.MAX_VALUE;\n dp[0] = 0;\n for(int i = 1; i < n; i++){\n //checking from 0 to index i that if there is a shorter path for \n //current position to reach from any of the previous indexes\n //also previous index should not be MAX_VALUE as this will show that\n //we were not able to reach this particular index\n for(int j = 0; j < i; j++){\n if(dp[j] != Integer.MAX_VALUE && arr[j] + j >= i){\n if(dp[j] + 1 < dp[i]){\n dp[i] = dp[j] + 1;\n }\n }\n }\n }\n \n if(dp[n - 1] != Integer.MAX_VALUE){\n return dp[n - 1];\n }\n \n return -1;\n }", "public boolean solve(final int startRow, final int startCol) {\r\n\r\n // TODO\r\n // validate arguments: ensure position is within maze area\r\n\r\n if(mazeData [startRow][startCol] == WALL) {\r\n throw new IllegalArgumentException(\" we're in a wall buddy\");\r\n }\r\n else if (startRow > mazeData.length-1 || startCol > mazeData.length-1 ){\r\n throw new IllegalArgumentException(\" we're out of bounds \");\r\n }\r\n\r\n\r\n\r\n\r\n\r\n // TODO create local class for row/col positions\r\n class Position {\r\n private int row;\r\n private int col;\r\n\r\n // TODO add instance variables\r\n public Position(final int row, final int col) {\r\n this.row = row;\r\n this.col= col;\r\n }\r\n\r\n\r\n\r\n // TODO toString if desired\r\n public String toString() {\r\n return \"Row: \" + this.row + \"Column: \"+ this.col;\r\n }\r\n\r\n\r\n }\r\n\r\n\r\n // define the stack (work queue)\r\n final var queue = Collections.asLifoQueue(new LinkedList<Position>());\r\n //Queue<Position> queue = new LinkedList<Position>(); // EXTRA CREDIT PART 2\r\n\r\n // put starting position in queue\r\n queue.add(new Position(startRow, startCol));\r\n\r\n\r\n\r\n\r\n\r\n // look for a way out of the maze from the current position\r\n while (!queue.isEmpty()) {\r\n\r\n\r\n final Position pos = queue.remove();\r\n\r\n // if this is a wall, then ignore this position (and skip the remaining steps of the loop body)\r\n if (mazeData [pos.row][pos.col]== WALL){\r\n continue; // jumps to next spot in que , by skipping to next iteration of loops by saying continue\r\n }\r\n\r\n\r\n // otherwise mark this place as visited (drop a breadcrumb)\r\n if (mazeData [pos.row][pos.col]== VISITED){\r\n continue; // jumps to next spot in que , by skipping to next iteration of loops by saying continue\r\n }\r\n else if(mazeData [pos.row][pos.col]== EMPTY){\r\n mazeData [pos.row][pos.col]= VISITED;\r\n }\r\n\r\n // if we're already on the perimeter, then this is a way out and we should return success (true) right away\r\n if (pos.row == 0|| pos.col ==0 || pos.row == mazeData.length-1 || pos.col == mazeData[0].length-1){\r\n mazeData[startRow][startCol] = START;\r\n return true;\r\n }\r\n\r\n queue.add(new Position(pos.row+1,pos.col ));//down\r\n queue.add(new Position(pos.row-1,pos.col ));//up\r\n queue.add(new Position(pos.row,pos.col-1 )); //left\r\n queue.add(new Position(pos.row, pos.col + 1)); //right\r\n\r\n\r\n }//end of while\r\n\r\n\r\n\r\n // mark starting position\r\n mazeData[startRow][startCol] = START;\r\n\r\n // if we've looked everywhere but haven't gotten out, then return failure (false)\r\n return false;\r\n }", "public static void userSelection_SolveMaze(int userInputN){\n\n\t\tint[] S = new int[(int) Math.pow(userInputN, 2)];\n\t\tgNode[] G = new gNode[S.length];\n\n\t\tboolean [] visited = new boolean[S.length];\t\t//Initialize\n\t\tfor(int i=0; i<visited.length;i++)\n\t\t\tvisited[i] = false;\n\n\t\tint [] path = new int[S.length];\t\t//Initialize \n\t\tfor(int i=0; i<path.length; i++)\n\t\t\tpath[i]=-1;\n\n\t\tScanner input = new Scanner(System.in);\n\t\tSystem.out.println(\"How would you like to solve the maze?\\n\"\n\t\t\t\t+ \"1.\\tBreadth-First Search\\n\"\n\t\t\t\t+ \"2.\\tDepth-First Search\\n\"\n\t\t\t\t+ \"3.\\tDepth-First Search with Recursion\");\n\t\t\n\t\tint ur = input.nextInt();\n\t\t\n\t\tif(ur==1)\t//Breadth-First Search\t\t\\///gNode && start @ position 0\n\t\t\tbfs(G, visited, path, 0);\n\t\telse if(ur==2)\t//Depth-First Search\n\t\t\tdfs_Stack(G, visited, path, 0);\n\t\telse if(ur==3)\t//Depth-First Search w/recursion\t\n\t\t\tdfsRecursion(G, visited, path, 0);\t\n\t\telse{\n\t\t\tSystem.out.println(\"Invalid option. Please enter the appropriate integer value\");\n\t\t\tuserSelection_SolveMaze(userInputN);\n\t\t}\n\t\t\n\t\tinput.close();\n\t}", "public void maximize()\n\t{\n\t\tint i,j,max=cost[0][0];\n\t\t\n\t\tfor(i=0;i<n;i++)\n\t\t{\n\t\t\tfor(j=0;j<n;j++)\n\t\t\t{\n\t\t\t\tif(cost[i][j]>max)\n\t\t\t\t{\n\t\t\t\t\tmax=cost[i][j];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t\n\t\tfor(i=0;i<n;i++)\n\t\t{\n\t\t\tfor(j=0;j<n;j++)\n\t\t\t{\t\t\n\t\t\t\tcost[i][j]=max-cost[i][j];\n\t\t\t}\n\t\t}\n\t\t\n\t}", "private static LinkedList<Integer> localSearch2Opt(File fileNameWithPath, int kNeighborHood ) throws Exception{\n\t\t\n\t\tString traceString = \"\";\n\t\tdouble bestCost = Double.POSITIVE_INFINITY;\n\t\tLinkedList<Integer> bestTspList = null;\n\t\tdouble bestCycleTime = Double.POSITIVE_INFINITY;\n\n\t\tif (Project.runId == -1 )\n\t\t\tProject.runId = 1;\n\n\t\t/* \n\t\t * read the file and build the cost table\n\t\t */\n parseEdges(fileNameWithPath);\n\n /*\n\t\t * time starts once you read the data\n */\n\t\tdouble baseTime = System.nanoTime();\n\n\t\t/*\n\t\t * invoking furthest insertion algorithm to get the tsp\n\t\t */\n\t\tlong startNodeSeed = (long)(1000.0*generator.nextDouble());\n\t\tLinkedList<Integer> currentTspList = FurthestInsertion.generateTSP(Project.sourceGTree,startNodeSeed);\n\t\t\n\t\tdouble currentTspCost = tspCost(currentTspList);\n\n\t\tbestTspList = currentTspList;\n\t\tbestCost = currentTspCost;\n\t\tbestCycleTime = System.nanoTime() - baseTime;\n\n\t\t/* print the trace file */\n\t\ttraceString = String.format(\"%.2f, %d\",Math.round(((System.nanoTime()-baseTime)/nanosecs)*100.0)/100.0,Math.round(bestCost));\n\t\tprintTrace(runId,traceString);\n\n\t\t/*\n\t\t * remove the last node as it matches the first\n\t\t */\n\t\tcurrentTspList.removeLast();\n\n\t\twhile ( true )\n\t\t{\n\t\t\t/*\n\t\t\t * reached cutoff time\n\t\t\t */\n\t\t\tif ( System.nanoTime()-baseTime >= Project.cutoffTimeSeconds*nanosecs ) {\n\t\t\t\ttimedOut=true;\n\t\t\t\tbreak;\n\t\t\t}\n\n\t\t\tdouble cycleStartTime = System.nanoTime();\n\n\t\t\tLinkedList<Integer> newTspList = currentTspList;\n\n\t\t\t/* do a 2 opt search in current k=5 neighborhood to get a newtsp */\n\t\t\t/* 1. Pick the first random element in the current tsp */\n\t\t\tint element2 = (int)((double)(newTspList.size()-1) * generator.nextDouble());\n\t\t\tint element1 = element2 - 1;\n\t\t\tif ( element1 == -1 ){\n\t\t\t\telement1 = newTspList.size()-1;\n\t\t\t}\n\t\t\t\n int delta;\n\n\t\t\t/*\n\t\t\t * search in the neighborhood specified\n * if not specified search all\n\t\t\t */\n if ( kNeighborHood != -1 ) {\n\t\t\t /* We want to search in the specified k=n neighborhoods of element1 */\n\t\t\t delta= (int)(2*kNeighborHood*generator.nextDouble()) - kNeighborHood;\n } else {\n\t\t\t delta= (int)((newTspList.size()-1)*generator.nextDouble()) - (int)(newTspList.size()/2);\n\t\t\t}\n\n\t\t\tif ( delta == 0 ) {\n\t\t\t\tdelta = 2;\n\t\t\t} else if ( delta == 1 ) {\n\t\t\t\tdelta = 2;\n\t\t\t} else if ( delta == -1) {\n\t\t\t\tdelta = -2; }\n\n\t\t\tint element4 = element2 + delta;\n\n\t\t\tif ( element4 < 0 ) {\n\t\t\t\telement4 = newTspList.size()+element4;\n\t\t\t}else if ( element4 >= newTspList.size() ) {\n\t\t\t\telement4 = element4-(newTspList.size()-1);\n\t\t\t}\n\n\t\t\tint element3 = element4 -1;\n\t\t\tif ( element3 == -1 ){\n\t\t\t\telement3 = newTspList.size()-1;\n\t\t\t}\n\n\n\t\t\t/* \n\t\t\t * the new tsp will have element2->element4.......element1->element3....\n\t\t\t */\n\t\t\tInteger vertex_3 = newTspList.get(element3);\n\t\t\tnewTspList.set(element3,newTspList.get(element2));\n\t\t\tnewTspList.set(element2,vertex_3);\n\n\t\t\t/*\n\t\t\t * from element2+1 to element3-1 swap to reverse their order\n\t\t\t */\n\t\t\twhile ( element2 < element3 ){\n\t\t\t\telement3 = element3-1;\n\t\t\t\tif ( element3 == -1 ) {\n\t\t\t\t\telement3 = newTspList.size()-1;\n\t\t\t\t}\n\n\t\t\t\telement2 = element2 + 1;\n\t\t\t\tif ( element2 == newTspList.size() ) {\n\t\t\t\t\telement3 = 0;\n\t\t\t\t}\n\n\t\t\t\tInteger tempVertex = newTspList.get(element2);\n\t\t\t\tnewTspList.set(element2,newTspList.get(element3));\n\t\t\t\tnewTspList.set(element3,tempVertex);\n\n\t\t\t}\n\n\t\t\tdouble newTspCost = tspCost(newTspList);\n\n\t\t\t/* if new local search solution is better than eariler take the search and continue search\n\t\t\t */\n\t\t\tif ( newTspCost <= currentTspCost ){\n\t\t\t\tcurrentTspList = newTspList;\n\t\t\t\tcurrentTspCost = newTspCost;\n\t\t\t} else {\n\t\t\t/* if new local search solution is not better than eariler \n\t\t\t */\n\t\t\t\tcontinue;\n\t\t\t}\n\t\n\t\t\t//Subtract the start time from the finish time to get the actual algorithm running time; divide by 10e6 to convert to milliseconds\n\t\t\tdouble cycleTime = (System.nanoTime()-cycleStartTime);\n\n\t\t\t/* first improvement , take the best each time */\n\t\t\tif ( newTspCost < bestCost ) {\n\t\t\t\tbestCost = newTspCost;\n\t\t\t\tbestTspList = newTspList;\n\t\t\t\tbestCycleTime = cycleTime;\n\t\t\t\t/* print the trace file */\n\t\t\t\ttraceString = String.format(\"%.2f, %d\",Math.round(((System.nanoTime()-baseTime)/nanosecs)*100.0)/100.0,Math.round(bestCost));\n\t\t\t\tappendToTraceFile(runId,traceString);\n\n\t\t\t\tif ( bestCost <= optimalCost )\n\t\t\t\t\tbreak;\n\t\t\t}\n\n\t\t}\n\n\t\t/* print the sol file */\n\t\tprintSol(runId,bestTspList,bestCost);\n\n\t\t/* print the tab results file */\n\t\tappendTabResults(runId,bestCycleTime,bestCost,bestTspList);\n\n\t\treturn bestTspList;\n\n\t}", "public void callMinimax(Player player) {\n rootValues.clear();\n\n if (player.getColor() == Slot.WHITE) {\n minimaxPlayerWhite(0, player, Integer.MIN_VALUE, Integer.MAX_VALUE);\n } else {\n minimaxPlayerBlack(0, player, Integer.MIN_VALUE , Integer.MAX_VALUE);\n }\n\n minimaxMove = getBestMove();\n }", "public Node newAlphaBeta(Node node, boolean isMaximizing, Node[][] gameBoard,int playerID,int depth,boolean searchOnce) throws InterruptedException {\n\t\tif(depth==0) //node equals terminal node origin ***************************\n\t\t{\n\n\t\t\t\n\t\t\treturn node; //return heuristic value accumulated Score\n\t\t}\n\t\t\n\t\tif(isMaximizing == true)//max\n\t\t{\n\t\t\t\n\t\t\tNode[][] copyOne = new Node[gameBoard.length][gameBoard.length];\n\t\t\tint enescore=0;\n\t\t\tint nodesRx = 0;\n\t\t\tint nodesRy = 0;\n\t\t\tNode temNode = node;\n\t\t\t//opponent score\n\t\t\tif(node!=null)\n\t\t\t{\tenescore = node.enemy;\n\t\t\tnodesRx = node.maxrecordSearchedX;\n\t\t\tnodesRy = node.maxrecordSearchedY;}\n\t\t\t\n\t\t for (int i = 0; i < gameBoard.length; i++) {\n\t\t \tfor(int j =0;j<gameBoard.length;j++)\n\t\t \t{\t\n\t\t \t\tNode temp = new Node(gameBoard[i][j].getScore(),gameBoard[i][j].getX(),gameBoard[i][j].getY(),gameBoard[i][j].getOwnership());\n\t\t \t\tcopyOne[i][j]=temp;\n\t\t \t}\n\t\t }\n\t\t \n\t\t \n\t\t\tPriorityQueue<Node> playerOneChildrenList = new PriorityQueue<Node>(Collections.reverseOrder()); //use priorityQueue,acsending or disacsending.\n\t\t\tQueue<Node> waitList = new LinkedList<Node>();\n\t\t\tboolean walkable = false;\n\t\t\t\n\t\t\t\tfor(int i = 0;i<gameBoard.length;i++)\n\t\t\t\t{\n\t\t\t\t\tfor(int j =0;j<gameBoard.length;j++)\n\t\t\t\t\t{\n\t\t\t\t\t\tif(copyOne[i][j].getOwnership()==0)\n\t\t\t\t\t\t{\n\t\t\t\t\t\twaitList.add(new Node(copyOne[i][j].getScore(),i,j,playerID));//everyPosition through the 2D array\n\t\t\t\t\t\twalkable = true;\n\t\t\t\t//\t\tcounter++;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\n\n\t\t\tif(walkable == false)\n\t\t\t{\n\t\t\t\treturn node;\n\t\t\t}\n\t\t\t\n\t\t\tint waitSize = waitList.size();\n\t\t\t\n\t\t\t\n\t\t\tfor(int l = 0;l<waitSize;l++)\n\t\t\t{\n\t\t\t\t\n\t\t\t\tNode[][] newCopy = new Node[gameBoard.length][gameBoard.length];\n\t\t\t\tNode temT = temNode;\n\t\t\t for (int i = 0; i < gameBoard.length; i++) {\n\t\t\t \tfor(int j =0;j<gameBoard.length;j++)\n\t\t\t \t{\t\n\t\t\t \t\tNode temp = new Node(copyOne[i][j].getScore(),copyOne[i][j].getX(),copyOne[i][j].getY(),copyOne[i][j].getOwnership());\n\t\t\t \t\tnewCopy[i][j]=temp;\n\t\t\t \t}\n\t\t\t }\n\t\t\t \n\t\t\t\tNode takenNode =waitList.poll();\n\t\t\t\tcounter++;\n\t\t\t\ttakenNode.setAccumulated(newCopy[takenNode.getX()][takenNode.getY()].getScore());\n\t\t\t\ttakenNode.enemy = 0;\n\t\t\t\tnewCopy[takenNode.getX()][takenNode.getY()].setOwnership(playerID);\n\t\t\t\tboolean connected = false;\n\t\t\t\tfor(int i = 0;i<dx.length;i++)\n\t\t\t\t{\n\t\t\t\t\t\tint newX = takenNode.getX()+dx[i];\n\t\t\t\t\t\tint newY = takenNode.getY()+dy[i];\n\t\t\t\t\t\tif((newX>=0&&newX<gameBoard.length)&&(newY>=0&&newY<gameBoard.length))\n\t\t\t\t\t\t{\n\t\t\t\t\t\tif(newCopy[newX][newY].getOwnership()==playerID)\n\t\t\t\t\t\t{\n\t\t\n\t\t\t\t\t\t\tconnected = true;\n\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(connected == true)\n\t\t\t\t{\n\n\t\t\t\t\tfor(int i = 0;i<dx.length;i++)\n\t\t\t\t\t{\n\t\t\n\t\t\t\t\t\t\tint newX = takenNode.getX()+dx[i];\n\t\t\t\t\t\t\tint newY = takenNode.getY()+dy[i];\n\t\t\t\t\t\t\tif((newX>=0&&newX<gameBoard.length)&&(newY>=0&&newY<gameBoard.length))\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\tif(newCopy[newX][newY].getOwnership()!=playerID&&newCopy[newX][newY].getOwnership()!=0)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tthis.eatOpponent(newCopy, playerID, newX, newY);\n\t\t\n\t\t\t\t\t\t\t\ttakenNode.setAccumulated(takenNode.getAccumulated()+newCopy[newX][newY].getScore());\n\t\t\t\t\t\t\t\tenescore-=newCopy[newX][newY].getScore();\n\t\t\t\t\t\t\t\ttakenNode.enemy = enescore;\n\t\t\t\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}\n\t\n\t\t\t\tif(depth==1)\n\t\t\t\t{\n\t\n\t\t\t\t\ttakenNode.setAccumulated(node.getAccumulated()+takenNode.getAccumulated());\n\n\t\t\t\t}\n\t\n\n\t\t\t\tint opponentID = 0;\n\t\t\t\tif(playerID == 1)\n\t\t\t\t{\n\t\t\t\t\topponentID = 2;\n\t\t\t\t}else if(playerID == 2)\n\t\t\t\t{\n\t\t\t\t\topponentID = 1;\n\t\t\t\t}\n\t\t\t\tif(playerOneChildrenList.isEmpty()==false)\n\t\t\t\t{\n\t\t\t\t\t//\tSystem.out.println(\"asdas\");\n\t\t\t//\t\tSystem.out.println(\"A depth: \"+depth);\n\t\t\t\t//\tThread.sleep(300);\n\t\t\t\t\t\tNode minValueNode = newAlphaBeta(takenNode,false,newCopy, opponentID, depth-1,true);\n\t\t\t\t\t\tcounter++;\n\t\t\t\t\t\n\t\t\t\t\t\t\n\n\n\t\t\t\t\t\t\tif(node!=null)\n\t\t\t\t\t\t\t{\tminValueNode.parentNode = new Node(node.getAccumulated(),node.getX(),node.getY(),node.getOwnership());\n\t\t\t\t\t\t\tif(this.beta!=null)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\tif(minValueNode.getAccumulated()<this.alpha.getAccumulated())\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t//\tSystem.out.println(\"break l should be \"+waitSize+\" now: \"+l);\n\t\t\t\t\t\t\t\tplayerOneChildrenList.add(minValueNode);\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t\t//node.noPoll = true;\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tplayerOneChildrenList.add(minValueNode);\n\t\t\t\t\t\t\tcontinue;\n\t\n\t\t\t\t\t//\t}\n\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\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\t\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t//\tSystem.out.println(\"B depth: \"+depth);\n\t\t\t\t\t//Thread.sleep(300);\n\t\t\t\t\trecordDepth = depth;\n\t\t\t\t\tNode minValueNode = newAlphaBeta(takenNode,false,newCopy, opponentID, depth-1,false);\n\t\t\t\t\t//this.alpha = minValueNode;\n\t\t\t\t\t\n\t\t\t\t\tcounter++;\n\t\t\t\t\t//playeroneNode++;\n\t\t\t\t\tif(node!=null)\n\t\t\t\t\t{\tminValueNode.parentNode = new Node(node.getAccumulated(),node.getX(),node.getY(),node.getOwnership());\n\t\t\t\t\tif(this.beta!=null)\n\t\t\t\t\t{\n\t\t\t\t\tif(minValueNode.getAccumulated()>this.beta.getAccumulated())\n\t\t\t\t\t{\n\t\t\t\t\t//\tSystem.out.println(\"break l should be \"+waitSize+\" now: \"+l);\n\t\t\t\t\t\tplayerOneChildrenList.add(minValueNode);\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t//node.noPoll = true;\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\n\t\t\t\t\t}\n\t\t\t\t\tplayerOneChildrenList.add(minValueNode);\n\t\t\n\t\t\t\t\t\tif(depth == recordDepth)\n\t\t\t\t\t\t{\n\t\t\t//\t\t\t\tSystem.out.println(\"setting alpha\");\n\t\t\t\t\t\t\t//Thread.sleep(300);\n\t\t\t\t\n\t\t\t\t\t\t\t\tthis.alpha = minValueNode;\n\t\t\t//\t\t\tSystem.out.println(\"alpha once: \"+this.alpha.getAccumulated());\n\t\t\t\t\t//\tThread.sleep(5000);\n\t\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t\n\t\t\t}\n\n\t\t\tif(playerOneChildrenList.peek().parentNode!=null||node!=null)\n\t\t\t{\n\t\t\t//\tSystem.out.println(\"returning: \"+playerOneChildrenList.peek().getAccumulated());\n\t\t\t//\tSystem.out.println(500);\n\t\t\tplayerOneChildrenList.peek().parentNode.setAccumulated(playerOneChildrenList.peek().getAccumulated());\n\t\t\tplayerOneChildrenList.peek().parentNode.noPoll = playerOneChildrenList.peek().noPoll;\n\n\t\t\treturn playerOneChildrenList.poll().parentNode;\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\tplayerOneChildrenList.peek().nodeExpanded = counter;\n\t\t\t\treturn playerOneChildrenList.poll();\n\t\t\t}\n\t\t\n\t\t}else\n\t\tif(isMaximizing == false)//min\n\t\t{\n\t\t\tNode[][] copyOne = new Node[gameBoard.length][gameBoard.length];\n\t\t\tint currentEnescore = node.enemy;\n\t\t\tint nodesRx = node.maxrecordSearchedX;\n\t\t\tint nodesRy = node.maxrecordSearchedY;\n\t\t\tNode temNode = node;\n\t\t for (int i = 0; i < gameBoard.length; i++) {\n\t\t \tfor(int j =0;j<gameBoard.length;j++)\n\t\t \t{\t\n\t\t \t\tNode temp = new Node(gameBoard[i][j].getScore(),gameBoard[i][j].getX(),gameBoard[i][j].getY(),gameBoard[i][j].getOwnership());\n\t\t \t copyOne[i][j]=temp;\n\t\t \t}\n\t\t }\n\t\t\tPriorityQueue<Node> playerTwoChildrenList = new PriorityQueue<Node>(); \n\t\t\tQueue<Node> waitList = new LinkedList<Node>();\n\t\t\tboolean walkable = false;\n\t\n\t\t\t\tfor(int i = 0;i<gameBoard.length;i++)\n\t\t\t\t{\n\t\t\t\t\tfor(int j =0;j<gameBoard.length;j++)\n\t\t\t\t\t{\n\t\t\t\t\t\tif(copyOne[i][j].getOwnership()==0)\n\t\t\t\t\t\t{\n\t\t\t\t\t\twaitList.add(new Node(copyOne[i][j].getScore(),i,j,playerID));//everyPosition through the 2D array\n\t\t\t\t\t\twalkable = true;\n\t\t\t\t//\t\tcounter++;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\n\t\t\tif(walkable == false)\n\t\t\t{\n\t\t\t\treturn node;\n\t\t\t}\n\t\t\t\n\t\t\tint waitSize = waitList.size();\n\n\t\t\tfor(int l = 0;l<waitSize;l++)\n\t\t\t{\n\n\t\t\t\tNode[][] newCopy = new Node[gameBoard.length][gameBoard.length];\n\t\t\t\tNode temT = temNode;\n\t\t\t for (int i = 0; i < gameBoard.length; i++) {\n\t\t\t \tfor(int j =0;j<gameBoard.length;j++)\n\t\t\t \t{\t\n\t\t\t \t\tNode temp = new Node(copyOne[i][j].getScore(),copyOne[i][j].getX(),copyOne[i][j].getY(),copyOne[i][j].getOwnership());\n\t\t\t \t\tnewCopy[i][j]=temp;\n\t\t\t \t}\n\t\t\t }\n\n\t\t\t\tNode takenNode = waitList.poll();\n\t\t\t\tcounter++;\n\t\t\t\tnewCopy[takenNode.getX()][takenNode.getY()].setOwnership(playerID);\n\t\t\n\t\t\t\ttakenNode.setAccumulated(node.getAccumulated());\n\n\t\t\t\ttakenNode.enemy= currentEnescore+newCopy[takenNode.getX()][takenNode.getY()].getScore();\n\t\t\t\t\n\t\t\t\tboolean connected = false;\n\t\t\t\tfor(int i = 0;i<dx.length;i++)\n\t\t\t\t{\n\t\n\t\t\t\t\t\tint newX = takenNode.getX()+dx[i];\n\t\t\t\t\t\tint newY = takenNode.getY()+dy[i];\n\t\t\t\t\t\tif((newX>=0&&newX<gameBoard.length)&&(newY>=0&&newY<gameBoard.length))\n\t\t\t\t\t\t{\n\t\t\t\t\t\tif(newCopy[newX][newY].getOwnership()==playerID)\n\t\t\t\t\t\t{\n\t\t\t\t\n\t\t\t\t\t\t\tconnected = true;\n\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(connected == true)\n\t\t\t\t{\n\t\t\t\n\t\t\t\t\tfor(int i = 0;i<dx.length;i++)\n\t\t\t\t\t{\n\t\t\n\t\t\t\t\t\t\tint newX = takenNode.getX()+dx[i];\n\t\t\t\t\t\t\tint newY = takenNode.getY()+dy[i];\n\t\t\t\t\t\t\tif((newX>=0&&newX<gameBoard.length)&&(newY>=0&&newY<gameBoard.length))\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\tif(newCopy[newX][newY].getOwnership()!=playerID&&newCopy[newX][newY].getOwnership()!=0)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tthis.eatOpponent(newCopy, playerID, newX, newY);\n\t\t\t\t\t\t\t\ttakenNode.setAccumulated(takenNode.getAccumulated()-newCopy[newX][newY].getScore());\t\n\t\t\t\t\t\t\t\ttakenNode.enemy+=newCopy[newX][newY].getScore();\n\t\t\t\t\t\t\t\t\n\t\t\t\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}\n\n\t\t\t\tint opponentID = 0;\n\t\t\t\tif(playerID == 1)\n\t\t\t\t{\n\t\t\t\t\topponentID = 2;\n\t\t\t\t}else if(playerID == 2)\n\t\t\t\t{\n\t\t\t\t\topponentID = 1;\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\tif(playerTwoChildrenList.isEmpty()==false)\n\t\t\t\t{\n\t\t\t//\t\tSystem.out.println(\" C depth: \"+depth);\n\t\t\t\t//\tThread.sleep(300);\n\t\t\t\t\t\tNode maxValueNode = newAlphaBeta(takenNode,true,newCopy, opponentID, depth-1,true);\n\t\t\t\t\t\tcounter++;\n\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\t//playeroneNode++;\n\t\t\t\t\t\tmaxValueNode.parentNode = new Node(node.getAccumulated(),node.getX(),node.getY(),node.getOwnership());\n\t\t\t\t\t\tif(this.alpha!=null)\n\t\t\t\t\t\t{\n\t\t\t\t//\t\tSystem.out.println(maxValueNode.getAccumulated()+\" \"+this.alpha.getAccumulated());\n\t\t\t\t\t//\tThread.sleep(5000);\n\t\t\t\t\t\tif(maxValueNode.getAccumulated()<this.alpha.getAccumulated())\n\t\t\t\t\t\t{\n\t\t\t\t\t//\t\tSystem.out.println(\"break l should be \"+waitSize+\" now: \"+l);\n\t\t\t\t\t\t\tplayerTwoChildrenList.add(maxValueNode);\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t//node.noPoll = 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\tplayerTwoChildrenList.add(maxValueNode);\n\t\t\t\t\t//\tif(maxValueNode.noPoll == true)\n\t\t\t\t\t//\t{\n\t\t\t\t\t//\t\tSystem.out.println(\"the discard value: \"+maxValueNode.getAccumulated()+\" compareTo: \"+this.alpha.getAccumulated());\n\t\t\t\t\t//\t\tbreak;\n\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\n\t\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t//\tSystem.out.println(\" D depth: \"+depth);\n\t\t\t\t//\tThread.sleep(300);\n\t\t\t\t\tNode maxValueNode = newAlphaBeta(takenNode,true,newCopy, opponentID, depth-1,false);\n\t\t\t\t\tcounter++;\n\t\t\t\t\t\n\t\t\t\t\tmaxValueNode.parentNode = new Node(node.getAccumulated(),node.getX(),node.getY(),node.getOwnership());\n\t\t\t\t\tif(this.alpha!=null)\n\t\t\t\t\t{\n\t\t\t\t\tif(maxValueNode.getAccumulated()<this.alpha.getAccumulated())\n\t\t\t\t\t{\n\t\t\t\t\t//\tSystem.out.println(\"break l should be \"+waitSize+\" now: \"+l);\n\t\t\t\t\t\tplayerTwoChildrenList.add(maxValueNode);\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t//node.noPoll = true;\n\t\t\t\t\t\t\n\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tif(depth == recordDepth-1)\n\t\t\t\t\t{\n\t\t//\t\t\t\tSystem.out.println(\"setting alpha\");\n\t\t\t\t\t\t//Thread.sleep(300);\n\t\t\t\n\t\t\t\t\t\t\tthis.beta = maxValueNode;\n\t\t\t\t\t\t\tSystem.out.println(\"beta: \"+this.beta.getAccumulated());\n\t\t\t\t\t\t\t//Thread.sleep(5000);\n\t\t//\t\t\tSystem.out.println(\"alpha once: \"+this.alpha.getAccumulated());\n\t\t\t\t//\tThread.sleep(5000);\n\t\t\t\t\t}\n\t\t\t\t\tplayerTwoChildrenList.add(maxValueNode);\n\t\t\t\t//\tif(maxValueNode.noPoll == true)\n\t\t\t\t//\t{\n\t\t\t\t//\t\t\n\t\t\t\t//\t\tbreak;\n\t\t\t\t//\t}\n\t\t\t\t}\n\t\t\t\n\t\t\t}\n\t\t\tplayerTwoChildrenList.peek().parentNode.setAccumulated(playerTwoChildrenList.peek().getAccumulated());\n\n\t\t\treturn playerTwoChildrenList.poll().parentNode;\n\t\t}\n\t\treturn null;\n\t\n\t}", "@SuppressWarnings(\"null\")\n\tpublic static Node optimalIterativeSolution (Node Tree, int target) {\n\t\tNode curr = Tree;\n\t\tNode Closest = null;\n\t\tClosest.val = Integer.MAX_VALUE;\n\t\twhile (curr != null) {\n\t\t\tif (Math.abs(target - Closest.val) > Math.abs(target - curr.val)) {\n\t\t\t\tClosest = curr;\n\t\t\t} else if (target < curr.val) {\n\t\t\t\tcurr = curr.left;\n\t\t\t} else if (target > curr.val) {\n\t\t\t\tcurr = curr.right;\n\t\t\t} else {\n\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\t\treturn Closest;\n\t}", "public Stack<Node> findPath(Node initial_node, Node end_node) {\r\n\r\n // TODO: check for hardcoded value 3\r\n int size = 3;\r\n boolean is_start_node = true;\r\n\r\n PriorityList priority_list = new PriorityList();\r\n LinkedList linked_list = new LinkedList();\r\n\r\n // Initialise start node\r\n initial_node.total_path_cost = 0;\r\n initial_node.cost_estimated_to_goal_node = initial_node.pathCost(end_node);\r\n initial_node.parent_node_in_path = null;\r\n priority_list.add(initial_node);\r\n\r\n // Begin exploration of grid map\r\n while (!priority_list.isEmpty()) {\r\n\r\n // Get node from head of list\r\n Node node = (Node) priority_list.removeFirst();\r\n\r\n // Determine if node is Start node\r\n if (node == initial_node)\r\n is_start_node = true;\r\n else\r\n is_start_node = false;\r\n\r\n ((Node) node).setFacing();\r\n\r\n // Determine if node is goal node\r\n if (node == end_node) {\r\n return constructPath(end_node);\r\n }\r\n\r\n // Get list of node neighbours\r\n List neighbors_list = node.getNeighbors();\r\n\r\n // Iterate through list of node neighbours\r\n for (int i = 0; i < neighbors_list.size(); i++) {\r\n\r\n // Extract neighbour node information\r\n Node node_neighbour = (Node) neighbors_list.get(i);\r\n boolean isOpen = priority_list.contains(node_neighbour);\r\n boolean isClosed = linked_list.contains(node_neighbour);\r\n boolean isObs = (node_neighbour).isObs();\r\n int clearance = node_neighbour.getClearance();\r\n float total_path_cost = node.getCost(node_neighbour, end_node, is_start_node) + 1;\r\n\r\n // Check 1. if node neighbours have not been explored OR 2. if shorter path to\r\n // neighbour node exists\r\n if ((!isOpen && !isClosed) || total_path_cost < node_neighbour.total_path_cost) {\r\n node_neighbour.parent_node_in_path = node;\r\n node_neighbour.total_path_cost = total_path_cost;\r\n node_neighbour.cost_estimated_to_goal_node = node_neighbour.pathCost(end_node);\r\n\r\n // Add neighbour node to priority_list if 1. node not in\r\n // priority_list/linked_list AND 2.\r\n // robot can reach\r\n if (!isOpen && !isObs && size == clearance) {\r\n priority_list.add(node_neighbour);\r\n }\r\n }\r\n }\r\n linked_list.add(node);\r\n }\r\n\r\n // priority_list empty; no path found\r\n\r\n return new Stack<Node>();\r\n }", "public static List<Vec2i> solve(int[][] grid, Vec2i start, Vec2i goal, Heuristic h){\n if(h == null){ //if null replace with default heuristic\n h = new Heuristic() {\n @Override\n\n public double eval(Vec2i loc) {\n double dx = (loc.x - goal.x);\n double dy = (loc.y - goal.y);\n return Math.sqrt(dx*dx + dy*dy);\n }\n };\n }\n\n PriorityQueue<GridLocation> edge = new PriorityQueue<GridLocation>(10, AStarGrid::compareGridLocations);\n edge.add(new GridLocation(start,0));\n\n Map<Vec2i, Vec2i> cameFrom = new HashMap<Vec2i, Vec2i>();\n Map<Vec2i, Double> g = new HashMap<Vec2i, Double>(); //distance to node\n g.put(start,0.0);\n Map<Vec2i, Double> f = new HashMap<Vec2i, Double>(); //distance from start to goal through this node\n f.put(start,h.eval(start));\n //f = g + h\n\n while(!edge.isEmpty()){\n\n Vec2i current = edge.poll().loc;\n if(current.x == goal.x && current.y == goal.y){\n return reconstructPath(cameFrom, current);\n }\n\n LinkedList<Vec2i> neighbors = new LinkedList<Vec2i>();\n if(current.x != 0 && grid[current.x - 1][current.y] == 0)\n neighbors.add(new Vec2i(current.x - 1,current.y));\n if(current.x != grid.length-1 && grid[current.x + 1][current.y] == 0)\n neighbors.add(new Vec2i(current.x + 1,current.y));\n if(current.y != 0 && grid[current.x][current.y - 1] == 0)\n neighbors.add(new Vec2i(current.x,current.y - 1));\n if(current.y != grid[0].length-1 && grid[current.x][current.y + 1] == 0)\n neighbors.add(new Vec2i(current.x,current.y + 1));\n\n\n for(Vec2i neighbor: neighbors){\n double score = g.get(current) + 1;\n if(!g.containsKey(neighbor) || score < g.get(neighbor)){\n cameFrom.put(neighbor,current);\n g.put(neighbor, score);\n f.put(neighbor, score + h.eval(neighbor));\n if(!edge.contains(neighbor)){\n edge.add(new GridLocation(neighbor,score + h.eval(neighbor)));\n }\n }\n }\n }\n //No path was found\n return null;\n }", "@Override\n public A makeDecision(S state) {\n metrics = new Metrics();\n StringBuffer logText = null;\n P player = game.getPlayer(state);\n List<A> results = orderActions(state, game.getActions(state), player, 0);\n timer.start();\n currDepthLimit = 0;\n do {\n incrementDepthLimit();\n if (logEnabled)\n logText = new StringBuffer(\"depth \" + currDepthLimit + \": \");\n heuristicEvaluationUsed = false;\n ActionStore<A> newResults = new ActionStore<>();\n for (A action : results) {\n double value = minValue(game.getResult(state, action), player, Double.NEGATIVE_INFINITY,\n Double.POSITIVE_INFINITY, 1);\n if (timer.timeOutOccurred())\n break; // exit from action loop\n newResults.add(action, value);\n if (logEnabled)\n logText.append(action).append(\"->\").append(value).append(\" \");\n }\n if (logEnabled)\n System.out.println(logText);\n if (newResults.size() > 0) {\n results = newResults.actions;\n if (!timer.timeOutOccurred()) {\n if (hasSafeWinner(newResults.utilValues.get(0)))\n break; // exit from iterative deepening loop\n else if (newResults.size() > 1\n && isSignificantlyBetter(newResults.utilValues.get(0), newResults.utilValues.get(1)))\n break; // exit from iterative deepening loop\n }\n }\n } while (!timer.timeOutOccurred() && heuristicEvaluationUsed);\n return results.get(0);\n }", "public static int[][] optimalBST(double[] p,double[] q, int num){\n double[][] e = new double[num+2][num+2];//子树期望代价\n double[][] w = new double[num+2][num+2];//子树总概率\n //why e and w is two bigger than num?\n //because when i==j, e[i][i-1] + e[i+1][j] + w[i][j];\n //when i = 1 or j = num, so e[1][0]、e[num+1][num]\n //here w can use the size of num+1, but in order not to so much complexity in init to judge i\n //so add a bigger w is look good!\n\n int[][] root = new int[num+1][num+1];//记录根节点\n //root[i][j] -- 用来存放i-j组成的最优二叉查找树的根节点\n\n //init--初始化\n for(int i=1; i<num+2; i++){\n e[i][i-1] = q[i-1];\n w[i][i-1] = q[i-1];\n }\n\n for(int d = 0; d<num; d++){\n //插入个数 : 0 - num-1, 从0开始\n for(int i=1; i<=num-d; i++){\n //起始下标 : 1 - num, 从1开始\n int j = i + d;\n e[i][j] = 9999;\n w[i][j] = w[i][j-1] + p[j] + q[j];//\n for(int k=i; k<=j; k++){\n //中间下标\n double temp = e[i][k-1] + e[k+1][j] + w[i][j];\n if(temp < e[i][j]){\n e[i][j] = temp;\n //找到小的,记录下来\n System.out.println(\"i--> \"+i+\", j--> \"+j);\n root[i][j] = k;\n }\n }\n }\n }\n return root;\n }", "private int BFS() {\n adjList.cleanNodeFields();\n\n //Queue for storing current shortest path\n Queue<Node<Integer, Integer>> q = new LinkedList<>();\n\n //Set source node value to 0\n q.add(adjList.getNode(startNode));\n q.peek().key = 0;\n q.peek().d = 0;\n q.peek().visited = true;\n\n //Helper variables\n LinkedList<Pair<Node<Integer, Integer>, Integer>> neighbors;//Array of pairs <neighborKey, edgeWeight>\n Node<Integer, Integer> neighbor, u;\n long speed = (long) (cellSideLength * 1.20);\n\n while (!isCancelled() && q.size() != 0) {\n u = q.poll();\n\n //Marks node as checked\n checkedNodesGC.fillRect((u.value >> 16) * cellSideLength + 0.5f,\n (u.value & 0x0000FFFF) * cellSideLength + 0.5f,\n (int) cellSideLength - 1, (int) cellSideLength - 1);\n\n //endNode found\n if (u.value == endNode) {\n //Draws shortest path\n Node<Integer, Integer> current = u, prev = u;\n\n while ((current = current.prev) != null) {\n shortestPathGC.strokeLine((prev.value >> 16) * cellSideLength + cellSideLength / 2,\n (prev.value & 0x0000FFFF) * cellSideLength + cellSideLength / 2,\n (current.value >> 16) * cellSideLength + cellSideLength / 2,\n (current.value & 0x0000FFFF) * cellSideLength + cellSideLength / 2);\n prev = current;\n }\n return u.d;\n }\n\n //Wait after checking node\n try {\n Thread.sleep(speed);\n } catch (InterruptedException interrupted) {\n if (isCancelled())\n break;\n }\n\n //Checking Neighbors\n neighbors = adjList.getNeighbors(u.value);\n for (Pair<Node<Integer, Integer>, Integer> neighborKeyValuePair : neighbors) {\n neighbor = neighborKeyValuePair.getKey();\n //Relaxation step\n //Checks if neighbor hasn't been checked, if so the assign the shortest path\n if (!neighbor.visited) {\n //Adds checked neighbor to queue\n neighbor.key = u.d + 1;\n neighbor.d = u.d + 1; //Assign shorter path found to neighbor\n neighbor.prev = u;\n neighbor.visited = true;\n q.add(neighbor);\n }\n }\n }\n return Integer.MAX_VALUE;\n }", "private float getQScore(Stone[][] board, int line, int col,\n int depth, int initialDepth){\n Chain chain = new Chain();\n Stone stone;\n if(depth % 2 == 1) stone = new Stone(color ? \"black\" : \"white\", chain);\n else stone = new Stone(color ? \"white\" : \"black\", chain);\n stone.setPosition(line, col);\n int nrStonesRemoved, chainSize, chainLiberties, score;\n board[line][col] = stone;\n //verific daca am luat pietre detinute de oponent\n nrStonesRemoved = Control.verifyNeighbourStones(board, stone.getColor(),\n line, col, false);\n //efectuez eventualele modificari ale lanturilor proprii ce pot aparea in urma plasarii pietrei\n Control.combineChains(board, stone, stone.getColor(), line, col);\n chainSize = stone.getChain().getStones().size();\n chainLiberties = stone.getChain().getLibertiesNumber();\n //aflu scorul starii\n score = nrStonesRemoved * 10 + chainSize * 30 + chainLiberties * 50;\n\n if(depth == 0){\n return (initialDepth % 2 == 1) ? -score : score;\n }\n\n float currentScore, max = 0;\n for(int i = 0; i < size; i++)\n for(int j = 0; j < size; j++){\n chain = new Chain();\n if(depth % 2 == 1) stone = new Stone(color ? \"white\" : \"black\", chain);\n else stone = new Stone(color ? \"black\" : \"white\", chain);\n stone.setPosition(i, j);\n int[] lib = Control.verifyLiberties(board, stone, i, j);\n if(board[i][j] == null && lib[0] + lib[1] != 0){\n currentScore = getQScore(board, i, j, depth - 1, initialDepth);\n if(currentScore > max){\n max = currentScore;\n }\n }\n }\n\n score += max * (depth / initialDepth);\n return (depth % 2 == 1) ? score : -score;\n }", "@Override\n\tpublic void run() {\n\t\tMap<Integer, Location> possibleStartLocations = possibleStartLocations();\n\n\t\tfor(Entry<Integer, Location> startLocation : possibleStartLocations.entrySet()) {\n\t\t\t// Add startLocation to visited locations\n\t\t\tMap<Integer, Location> visitedLocations = new HashMap<Integer, Location>();\n\t\t\tvisitedLocations.put(startLocation.getKey(), startLocation.getValue());\n\t\t\t\n\t\t\t// Add startLocation to visited order\n\t\t\tList<Location> visitedOrder = new LinkedList<Location>();\n\t\t\tvisitedOrder.add(startLocation.getValue());\n\t\t\t\n\t\t\t// Start the recursion for the following start node\n\t\t\tfindSolution(startLocation, startLocation, visitedLocations, visitedOrder, 0);\n\t\t}\n\t}", "private int minimaxPlayerWhite(int depth, Player player, int alpha, int beta) {\n if ((!playerCanMove(playerBlack) && !playerCanMove(playerWhite)) || depth > plyCutoff) {\n return getHeuristic(playerWhite);\n }\n\n ArrayList<MoveNode> moves = getAllMoves(player.getColor());\n\n if (moves.isEmpty()) {\n return getHeuristic(playerWhite);\n }\n\n ArrayList<Integer> scores = new ArrayList<>();\n\n Integer[][] savedBoard = new Integer[Board.MAX_ROW][Board.MAX_COLUMN];\n\n if (plyCutoff >= depth) {\n copyBoard(savedBoard);\n }\n\n for (int i = 0; i < moves.size(); i++) {\n MoveNode move = moves.get(i);\n\n if (player.equals(playerWhite)) {\n makeMoveFromMinimax(move);\n\n int currentScore = minimaxPlayerWhite(depth + 1, playerBlack, alpha, beta);\n scores.add(currentScore);\n\n if (alphaBetaEnable) {\n if (move.getMinimaxValue() > alpha) {\n alpha = move.getMinimaxValue();\n }\n\n if (beta <= alpha) {\n break;\n }\n }\n\n if (depth == 0) {\n move.setMinimaxValue(currentScore);\n rootValues.add(move);\n }\n } else if (player.equals(playerBlack)) {\n makeMoveFromMinimax(move);\n\n int currentScore = minimaxPlayerWhite(depth + 1, playerWhite, alpha, beta);\n scores.add(currentScore);\n\n if (alphaBetaEnable) {\n if (move.getMinimaxValue() < beta) {\n beta = move.getMinimaxValue();\n }\n\n if (alpha >= beta) {\n break;\n }\n }\n }\n\n resetBoard(savedBoard);\n }\n\n if (player.equals(playerWhite)) {\n return Collections.max(scores);\n }\n\n return Collections.min(scores);\n }", "public void findShortestPath() {\r\n\t\t\r\n\t\t//Create a circular array that will store the possible next tiles in the different paths.\r\n\t\tOrderedCircularArray<MapCell> path = new OrderedCircularArray<MapCell>();\r\n\t\t\r\n\t\t//Acquire the starting cell.\r\n\t\tMapCell starting = cityMap.getStart();\r\n\t\t\r\n\t\t//This variable is to be updated continuously with the cell with the shortest distance value in the circular array.\r\n\t\tMapCell current=null;\r\n\t\t\r\n\t\t//This variable is to check if the destination has been reached, which is initially false.\r\n\t\tboolean destination = false;\r\n\t\t\r\n\t\t//Add the starting cell into the circular array, and mark it in the list.\r\n\t\tpath.insert(starting, 0);\r\n\t\t\r\n\t\tstarting.markInList(); \r\n\t\t\r\n\t\ttry {\r\n\t\t\t\r\n\t\t\t//As long as the circular array isn't empty, and the destination hasn't been reached, run this loop.\r\n\t\t\twhile(!path.isEmpty()&&!destination) {\r\n\t\t\t\t\r\n\t\t\t\t//Take the cell with the shortest distance out of the circular array, and mark it accordingly.\r\n\t\t\t\tcurrent = path.getSmallest();\r\n\t\t\t\tcurrent.markOutList();\r\n\t\t\t\t\r\n\t\t\t\tMapCell next;\r\n\t\t\t\tint distance;\r\n\t\t\t\t\r\n\t\t\t\tif(current.isDestination()) {\r\n\t\t\t\t\t\r\n\t\t\t\t\tdestination = true; //If the current cell is the destination, end the loop.\r\n\t\t\t\t\t\r\n\t\t\t\t} else {\r\n\t\t\t\t\t\r\n\t\t\t\t\tnext = nextCell(current); //Acquire the next possible neighbour of the current cell.\r\n\t\t\t\t\t\r\n\t\t\t\t\t//Don't run if next is null, meaning there is no other possible neighbour in the path for the current cell.\r\n\t\t\t\t\twhile(next!=null) {\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\tdistance = current.getDistanceToStart() + 1;\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t//If the distance of the selected neighbouring cell is currently more than 1 more than the current cell's \r\n\t\t\t\t\t\t//distance, update the distance of the neighbouring cell. Then, set the current cell as its predecessor.\r\n\t\t\t\t\t\tif(next.getDistanceToStart()>distance) {\r\n\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\tnext.setDistanceToStart(distance);\r\n\t\t\t\t\t\t\tnext.setPredecessor(current);\r\n\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\tdistance = next.getDistanceToStart(); \r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\tif(next.isMarkedInList() && distance<path.getValue(next)) {\r\n\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\tpath.changeValue(next, distance); //If the neighbouring cell is in the circular array, but with a \r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t //larger distance value than the new updated distance, change its value.\r\n\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t} else if(!next.isMarkedInList()){\r\n\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\tpath.insert(next, distance); //If the neighbouring cell isn't in the circular array, add it in.\r\n\t\t\t\t\t\t\tnext.markInList();\r\n\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\tnext = nextCell(current); //Look for the next possible neighbour, if any.\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}\r\n\t\t\t\t\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t//Catch all the possible exceptions that might be thrown by the method calls. Print the appropriate messages.\r\n\t\t} catch (EmptyListException e) {\r\n\t\t\t\r\n\t\t\tSystem.out.println(e.getMessage());\r\n\t\t\tSystem.out.println(\"Path finding execution stopped.\");\r\n\t\t\t\r\n\t\t} catch (InvalidNeighbourIndexException e) {\r\n\t\t\t\r\n\t\t\tSystem.out.println(\"The program tried to access an invalid neighbour of a tile.\");\r\n\t\t\tSystem.out.println(\"Path finding execution stopped.\");\r\n\t\t\t\r\n\t\t} catch (InvalidDataItemException e) {\r\n\t\t\t\r\n\t\t\tSystem.out.println(e.getMessage());\r\n\t\t\tSystem.out.println(\"Path finding execution stopped.\");\r\n\t\t\t\r\n\t\t} catch (Exception e) {\r\n\t\t\t\r\n\t\t\tSystem.out.println(e.getMessage()+\" Path finding execution has stopped.\");\r\n\t\t\t\r\n\t\t}\r\n\t\t\r\n\t\t//If a path was found, print the number of tiles in the path.\r\n\t\tif(destination) {\r\n\t\t\t\r\n\t\t\tSystem.out.println(\"Number of tiles in path: \" + (current.getDistanceToStart()+1));\r\n\t\t\t\r\n\t\t} else {\r\n\t\t\t\r\n\t\t\tSystem.out.println(\"No path found.\"); //Otherwise, indicate that a path wasn't found.\r\n\t\t\t\r\n\t\t}\r\n\t\t\r\n\t}", "public ArrayList<SearchNode> search(Problem p) {\n\tfrontier = new NodeQueue();\t// The frontier is a queue of expanded SearchNodes not processed yet\n\texplored = new HashSet<SearchNode>();\t/// The explored set is a set of nodes that have been processed \n\tGridPos startState = (GridPos) p.getInitialState();\t// The start state is given\n\tfrontier.addNodeToFront(new SearchNode(startState));\t// Initialize the frontier with the start state \n\n\t\n\tpath = new ArrayList<SearchNode>();\t// Path will be empty until we find the goal\n\t\t\n\n\n\twhile(!frontier.isEmpty()){\n\n\t SearchNode s = frontier.removeFirst(); \n\t GridPos g = s.getState(); \n\n\t if ( p.isGoalState(g) ) {\n\t\tpath = s.getPathFromRoot();\t\n\t\tbreak; \n\t }\n\t \n\t explored.add(s); \t \n\t ArrayList<GridPos> childStates = p.getReachableStatesFrom(g);\n\n\t while(!childStates.isEmpty()){\n\n\t\tSearchNode child = new SearchNode(childStates.get(0), s); \n\n\t\tif(!explored.contains(child) && !frontier.contains(child)){\n\n\t\t if ( p.isGoalState(child.getState()) ) {\n\t\t\n\t\t\tpath = child.getPathFromRoot();\t\n\t\t\treturn path; \n\t\t }\n\n\t\t if(insertFront) \n\t\t\tfrontier.addNodeToFront(child); \t\t \t\t\n\t\t else\t\n\t\t\tfrontier.addNodeToBack(child); \t \n\n\n\n\t\t}\n\n\t\tchildStates.remove(0);\n\t }\t \n\t}\n\n\n\treturn path;\n\n }", "public double getBestSolutionEvaluation();", "public Solution solve(KnapsackData data);", "public void dfs (String input)\r\n\t {\r\n\t\t \tNode root_dfs = new Node (input);\r\n\t\t \tNode current = new Node(root_dfs.getState());\r\n\t\t \t\r\n\t\t\tArrayList<String> visited = new ArrayList<String>();\r\n\t\t\tArrayList<String> children = new ArrayList<String>();\r\n\t\t\tStack<Node> stack_dfs = new Stack<Node>();\r\n\t\t\t\r\n\t\t\tint nodes_popped = 0;\r\n\t\t\tint stack_max_size = 0;\r\n\t\t\tint stack_size = 0;\r\n\t\t\tcurrent.cost = 0;\r\n\t\t\t\r\n\t\t\tgoal_dfs = isGoal(current.getState());\r\n\t\t\t\r\n\t\t\twhile(!goal_dfs)\r\n\t\t\t{\r\n\t\t\t\tvisited.add(current.getState());\r\n\t\t\t\tchildren = Successor.findChildren(current.getState());\r\n\t\t\t\t\r\n\t\t\t\tfor (String a : children)\r\n\t\t\t\t{\r\n\t\t\t\t\t\r\n\t\t\t\t\tif (visited.contains(a))\r\n\t\t\t\t\t{\r\n\t\t\t\t\t\tcontinue;\r\n\t\t\t\t\t}\r\n\t\t\t\t\t\r\n\t\t\t\t\t\tNode nino = new Node(a);\r\n\t\t\t\t\t\tcurrent.children_nodes.add(nino);\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\tint cost = isCost(current.getState(), nino.getState());\r\n\t\t\t\t\t\tnino.cost = cost;\r\n\t\t\t\t\t\tnino.parent = current;\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t// Repeated state check\r\n\t\t\t\t\t\tif (!stack_dfs.contains(nino))\r\n\t\t\t\t\t\t{\r\n\t\t\t\t\t\t\tstack_dfs.add(nino);\r\n\t\t\t\t\t\t\tstack_size++;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t\r\n\t\t\t\t}\r\n\t\t\t\t\r\n\t\t\t\t// Popping off the stack. LIFO architecture\r\n\t\t\t\tcurrent = stack_dfs.pop();\r\n\t\t\t\tnodes_popped++;\r\n\t\t\t\t\r\n\t\t\t\tif (stack_size > stack_max_size)\r\n\t\t\t\t{\r\n\t\t\t\t\tstack_max_size = stack_size;\r\n\t\t\t\t}\r\n\t\t\t\t\r\n\t\t\t\tstack_size--;\r\n\t\t\t\tgoal_dfs = isGoal(current.getState());\r\n\t\t\t\t\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\tgoal_dfs = false;\r\n\t\t\tSystem.out.println(\"DFS Solved!!\");\r\n\t\t\tSolution.performSolution(current, root_dfs, nodes_popped, stack_max_size);\r\n\t }", "public int getBestMove(ModelInterface field, List<IRatingMechanism> ratingMechanisms, Token owner) {\n tree = new Tree(field, ratingMechanisms, owner);\n // minimize or maximize each level\n for (int i = Tree.MAXDEPTH - 1; i > 0; i--) {\n //System.out.println(\"max/min level \" + i);\n List<Node> currLevel = tree.getLevel(i);\n if (!currLevel.isEmpty()) {\n \n if (currLevel.get(0).getCurrentOwner() == owner) {\n \n for (Node node : currLevel) {\n maximize(node);\n }\n \n } else {\n \n for (Node node : currLevel) {\n minimize(node);\n }\n }\n }\n }\n\n // debug\n for (int i = 0; i < tree.getLevel(1).size(); i++) {\n System.out.println(tree.getLevel(1).get(i).getMove().toString());\n }\n\n PossibleMove minMove = tree.getLevel(1).get(0).getMove();\n for (int i = 0; i < tree.getLevel(1).size(); i++) {\n if (tree.getLevel(1).get(i).getMove().getRating() < minMove.getRating()) {\n minMove = tree.getLevel(1).get(i).getMove();\n }\n }\n return minMove.getMove();\n }" ]
[ "0.7082756", "0.677848", "0.65259224", "0.64711374", "0.64354116", "0.641115", "0.6357835", "0.6352923", "0.6284473", "0.62398225", "0.62252384", "0.6215247", "0.6156437", "0.6156279", "0.614207", "0.61067724", "0.61010313", "0.6081169", "0.60774", "0.60424554", "0.60412294", "0.6015004", "0.60145617", "0.60085905", "0.59966886", "0.599252", "0.59912026", "0.5986419", "0.59460807", "0.5932727", "0.59295666", "0.59262395", "0.5911452", "0.590869", "0.59073323", "0.5852535", "0.5821321", "0.5807435", "0.57931316", "0.5785322", "0.57831997", "0.57748955", "0.57745594", "0.5774438", "0.57712626", "0.57456815", "0.5734679", "0.57256067", "0.57221156", "0.5717156", "0.5685675", "0.56679845", "0.56563", "0.56466943", "0.56390786", "0.56164694", "0.5613056", "0.5612751", "0.5611703", "0.56106865", "0.5596686", "0.5588213", "0.55809015", "0.5572846", "0.55679065", "0.5565071", "0.555833", "0.5549249", "0.5545237", "0.55420226", "0.55416554", "0.55392253", "0.5537986", "0.5536933", "0.5523045", "0.55187494", "0.5517894", "0.55165684", "0.5513479", "0.55097675", "0.55038935", "0.55014485", "0.54833376", "0.54773426", "0.54739636", "0.547359", "0.54553", "0.54518384", "0.54502577", "0.54496944", "0.54488313", "0.5447408", "0.5447017", "0.5445552", "0.5444588", "0.54423314", "0.5442251", "0.54336625", "0.54319555", "0.5431585", "0.5426354" ]
0.0
-1
Used for saving and loading
public void saveObject(ObjectOutputStream out) throws IOException { out.defaultWriteObject(); out.writeObject(otherColor); out.writeObject(mode); out.writeObject(tod); out.writeObject(prune); out.writeObject(currBoard); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void save() {\t\n\t\n\t\n\t}", "@Override\n public void Save() {\n\t \n }", "@Override\n public void save() {\n \n }", "@Override\n\tpublic void save() {\n\t\t\n\t}", "@Override\n\tpublic void save() {\n\t\t\n\t}", "private void saveData() {\n }", "@Override\n public void save()\n {\n \n }", "void save();", "void save();", "void save();", "@Override\r\n\tpublic void save() {\n\r\n\t}", "@Override\r\n\tpublic void save() {\n\r\n\t}", "@Override\n public void save() {\n\n }", "public void save();", "public void save();", "public void save();", "public void save();", "public void save() {\n }", "public void saveData(){\r\n file.executeAction(modelStore);\r\n }", "@Override\n\tpublic void save(Object o, String file) {\n\t\t\n\t}", "private void serializeBeforeOpen() {\r\n sr.save(this.path);\r\n }", "public void saveData() {\n\t\t//place to save notes e.g to file\n\t}", "void save() {\n gameModelPoDao.saveToFile(file.getAbsolutePath(), gameModelPo);\n }", "public void save() throws FileNotFoundException, IOException, ClassNotFoundException ;", "public void save() {\n JAXB.marshal(this, new File(fileName));\n }", "private void saveData() {\n readViews();\n final BookEntry bookEntry = new BookEntry(mNameString, mQuantityString, mPriceString, mSupplier, mPhoneString);\n AppExecutors.getInstance().diskIO().execute(new Runnable() {\n @Override\n public void run() {\n // Insert the book only if mBookId matches DEFAULT_BOOK_ID\n // Otherwise update it\n // call finish in any case\n if (mBookId == DEFAULT_BOOK_ID) {\n mDb.bookDao().insertBook(bookEntry);\n } else {\n //update book\n bookEntry.setId(mBookId);\n mDb.bookDao().updateBook(bookEntry);\n }\n finish();\n }\n });\n }", "private void serialize() {\r\n if (newFile) {\r\n this.newFile = this.serializeAs();\r\n } else if (!newFile && !path.equals(\"\")) {\r\n sr.save(this.path);\r\n }\r\n }", "private void saveFunction() {\n }", "@Override\n public void saveValues() {\n \n }", "public static void save()\n\t{\n writeMap();\n\t}", "public void save() {\r\n IniReader.write(FILE_NAME, \"x\", x, \"y\", y, \"fullscreen\", fullscreen, \"controlType\", controlType, \"vol\", volMul,\r\n \"keyUpMouse\", getKeyUpMouseName(), \"keyDownMouse\", getKeyDownMouseName(), \"keyUp\", getKeyUpName(), \"keyDown\", keyDownName,\r\n \"keyLeft\", keyLeftName, \"keyRight\", keyRightName, \"keyShoot\", keyShootName, \"keyShoot2\", getKeyShoot2Name(),\r\n \"keyAbility\", getKeyAbilityName(), \"keyEscape\", getKeyEscapeName(), \"keyMap\", keyMapName, \"keyInventory\", keyInventoryName,\r\n \"keyTalk\", getKeyTalkName(), \"keyPause\", getKeyPauseName(), \"keyDrop\", getKeyDropName(), \"keySellMenu\", getKeySellMenuName(),\r\n \"keyBuyMenu\", getKeyBuyMenuName(), \"keyChangeShipMenu\", getKeyChangeShipMenuName(), \"keyHireShipMenu\", getKeyHireShipMenuName());\r\n }", "public void save() {\n DataBuffer.saveDataLocally();\n\n //TODO save to db must be done properly\n DataBuffer.save(session);\n\n //TODO recording saved confirmation\n }", "protected void save() {\n close();\n if(saveAction != null) {\n saveAction.accept(getObject());\n }\n }", "@Override\n\tpublic void save() {\n\t\tSystem.out.println(\"save method\");\n\t}", "private void saveData() {\n\t\tdataSaver.save(data);\n\t}", "public void Save() {\n try {\n ObjectOutputStream objUt = new ObjectOutputStream(\n new FileOutputStream(\"sparfil.txt\"));\n objUt.writeObject(this);\n } catch(Exception e) {\n System.out.println(e);}\n }", "public void saveData ( ) {\n\t\tinvokeSafe ( \"saveData\" );\n\t}", "public void saveState() { }", "@Override\r\n\tpublic void save() {\n\r\n\t\ts.save();\r\n\r\n\t}", "private void saveToStorage() {\n FileOutputStream fos = null;\n try {\n fos = context.openFileOutput(\"GeoFences\", Context.MODE_PRIVATE);\n ObjectOutputStream oos = new ObjectOutputStream(fos);\n oos.writeObject(currentList);\n oos.close();\n } catch (IOException e) {\n e.printStackTrace();\n }\n }", "@Override\n\tpublic void save(String file_name) {\n\t\tserialize(file_name);\n\t}", "private void saveCurrentObject() {\n\t}", "@Override\r\n\t\t\tprotected void saveContext() {\n\t\t\t\t\r\n\t\t\t}", "public void saveState() {\n\t\tsuper.saveState();\n\t}", "@Override\r\n\tpublic void save() throws SaveException {\n\t\t\r\n\t}", "public void saveProgress() {\n\t\tsaveUsers();\n\t\tsaveMaterials();\n\t\tsaveBorrowings();\n\t}", "public void saveState() \n\t{\n\t\tsuper.saveState();\n\t}", "synchronized public void saveToFile() {\n try {\n saveObjToFile(this, saveFilePath);\n } catch (IOException e) {\n e.printStackTrace();\n log(\"error saving resource to file\");\n }\n }", "public void save() {\n\t\tthis.setState(Constants.CWorld.STATE_SAVING);\n\t\tthis.getWorld().saveAll();\n\t\tthis.setState(Constants.CWorld.STATE_ONLINE);\n\t}", "protected abstract void doSave();", "@Override\n\tpublic void doSaveAs() {\n\n\t}", "public void save(){\r\n\t\t//System.out.println(\"call save\");\r\n\t\tmodel.printDoc();\r\n\t}", "public void saveAsSerialization() {\n try(ObjectOutputStream os = new ObjectOutputStream(new FileOutputStream(new File(\"saves/data.dat\")))){\n os.writeObject(this);\n } catch (FileNotFoundException e){\n System.out.println(\"Could not create file: \" + e.getMessage());\n } catch (IOException e){\n System.out.println(\"IO exception occurred: \" + e.getMessage());\n }\n\n }", "public void save() {\n UTILS.write(FILE.getAbsolutePath(), data);\n }", "@Override\n public void setSaveFile(File file)\n {\n \n }", "private void saveGame(){\n\t\t\n\t}", "public void save(){\r\n if (inputValidation()) {\r\n if (modifyingPart) {\r\n saveExisting();\r\n } else {\r\n saveNew();\r\n }\r\n closeWindow();\r\n }\r\n\r\n }", "public void save(){\n BoardSerializer.serialize(this);\n }", "public void save() {\n\n\t\tint[][] rawData = new int[2][CHUNK_SIZE * CHUNK_SIZE];\n\n\t\tfor (int l = 0; l < 2; l++) {\n\t\t\tLayer layer = Layer.get(l);\n\t\t\tfor (int y = 0; y < CHUNK_SIZE; y++) {\n\t\t\t\tfor (int x = 0; x < CHUNK_SIZE; x++) {\n\t\t\t\t\trawData[l][x + y * CHUNK_SIZE] = getTileId(layer, x, y);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tthis.saveData = new RawChunkData(rawData);\n\t}", "public void saveQuickly(){\r\n String quickSavePath = this.savePath + File.separator + \"QuickSave.ser\";\r\n this.save(quickSavePath);\r\n }", "@Override\n\tpublic void posSave() {\n\t\t\n\t}", "@Override\n\tpublic void posSave() {\n\t\t\n\t}", "private void updateFile() {\n try {\n this.taskStorage.save(this.taskList);\n this.aliasStorage.save(this.parser);\n } catch (IOException e) {\n System.out.println(\"Master i am unable to save the file!\");\n }\n }", "@Override\n\tpublic void doSaveAs() {\n\t}", "@Override\n\tpublic void save(DataKey arg0) {\n\t\t\n\t}", "void saveData() throws SerializerException;", "public void save() {\n //write lift information to datastore\n LiftDataAccess lda = new LiftDataAccess();\n ArrayList<Long>newKeys = new ArrayList<Long>();\n for (Lift l : lift) {\n newKeys.add(lda.insert(l));\n }\n\n //write resort information to datastore\n liftKeys = newKeys;\n dao.update(this);\n }", "public void save(){\r\n\t\ttry {\r\n\t\t\tgame.suspendLoop();\r\n\t\t\tGameStockage.getInstance().save(game);\r\n\t\t\tgame.resumeLoop();\r\n\t\t} catch (GameNotSaveException e) {\r\n\t\t\tSystem.err.println(e.getMessage());\r\n\t\t\tgame.resumeLoop();\r\n\t\t} catch (IOException e) {\r\n\t\t\tSystem.err.println(e.getMessage());\r\n\t\t\tgame.resumeLoop();\r\n\t\t}\r\n\t}", "public void saveExtraData() {}", "private void save() {\r\n\t\tif (Store.save()) {\r\n\t\t\tSystem.out.println(\" > The store has been successfully saved in the file StoreData.\\n\");\r\n\t\t} else {\r\n\t\t\tSystem.out.println(\" > An error occurred during saving.\\n\");\r\n\t\t}\r\n\t}", "public boolean save();", "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}", "void save() {\n File file = new File(main.myPath + \"state.xml\");\n Framework.backup(main.myPath + \"state.xml\");\n Framework.transform(stateDoc, new StreamResult(file), null);\n setDirty(false);\n }", "public void save(){\n Player temp = Arena.CUR_PLAYER;\n try{\n FileOutputStream outputFile = new FileOutputStream(\"./data.sec\");\n ObjectOutputStream objectOut = new ObjectOutputStream(outputFile);\n objectOut.writeObject(temp);\n objectOut.close();\n outputFile.close();\n }\n catch(FileNotFoundException e){\n System.out.print(\"Cannot create a file at that location\");\n }\n catch(SecurityException e){\n System.out.print(\"Permission Denied!\");\n }\n catch(IOException e){\n System.out.println(\"Error 203\");\n } \n }", "public void autoSave(){\n\t\ttry {\n\t\t\t//read in file\n\t\t\tFile file = new File(System.getProperty(\"user.dir\")+\"/Default.scalcsave\");\n\t\t\tObjectOutputStream output = new ObjectOutputStream(new FileOutputStream(file));\n\t\t\toutput.writeObject(SaveFile.getSaveFile());\n\t\t\toutput.close();\n\t\t\tSystem.out.println(\"Save Success\");\n\t\t\t\n\t\t} catch (Exception e) {\n\t\t\te.printStackTrace();\n\t\t}\n\t}", "public void saveData(){\n SerializableManager.saveSerializable(this,user,\"userInfo.data\");\n SerializableManager.saveSerializable(this,todayCollectedID,\"todayCollectedCoinID.data\");\n SerializableManager.saveSerializable(this,CollectedCoins,\"collectedCoin.data\");\n uploadUserData uploadUserData = new uploadUserData(this);\n uploadUserData.execute(this.Uid);\n System.out.println(Uid);\n\n }", "public void save()\n\t{\n\t\tfor(PlayerData pd : dataMap.values())\n\t\t\tpd.save();\n\t}", "@Override\n public boolean save(String file) {\n boolean ans = false;\n ObjectOutputStream oos;\n try {\n FileOutputStream fileOut = new FileOutputStream(file, true);\n oos = new ObjectOutputStream(fileOut);\n oos.writeObject(this);\n ans= true;\n }\n catch (FileNotFoundException e) {\n e.printStackTrace(); }\n catch (IOException e) {e.printStackTrace();}\n return ans;\n }", "public void save() throws Exception {\n FileOutputStream saveFile = new FileOutputStream(Config.languageModelFile);\n ObjectOutputStream save = new ObjectOutputStream(saveFile);\n save.writeObject(this);\n save.close();\n }", "public void save() {\n\t\tpreferences().flush();\n\t}", "public void save(){\r\n\t\tmanager.save(this);\r\n\t}", "@Override\n public boolean save()\n {\n return false;\n }", "private void save(){\n SharedPreferences preferences = PreferenceManager.getDefaultSharedPreferences(getApplicationContext());\n SharedPreferences.Editor editor = preferences.edit();\n Gson gson = new Gson();\n String json = gson.toJson(downloadedBooks);\n editor.putString( LISTS_DOWNLOADED, json);\n json = gson.toJson(progress);\n editor.putString( LISTS_PROGRESS, json);\n editor.apply();\n }", "private void loadData(){\n try (BufferedReader br = new BufferedReader(new FileReader(this.fileName))) {\n String line;\n while((line=br.readLine())!=null){\n E e = createEntity(line);\n super.save(e);\n }\n } catch (IOException e) {\n e.printStackTrace();\n }\n }", "@Override\n\tpublic void saveSettings() {\n\n\t}", "public void load() ;", "public void save(){\n\t\tlowresModelManager.save();\n\t}", "public void save(){\n\t\t\n\t\ttry {\n\t\t\t\t \n\t\t\t// Open Streams\n\t\t\tFileOutputStream outFile = new FileOutputStream(\"user.ser\");\n\t\t\tObjectOutputStream outObj = new ObjectOutputStream(outFile);\n\t\t\t\t \n\t\t\t// Serializing the head will save the whole list\n\t\t\toutObj.writeObject(this.head);\n\t\t\t\t \n\t\t\t// Close Streams \n\t\t\toutObj.close();\n\t\t\toutFile.close();\n\t\t}\n\n\t\tcatch(Exception e) {\n\t\t\tSystem.out.println(\"Error saving\");\n\t\t}\n\t\t\t\n\t}", "private void save() {\n File personFile = mainApp.getFilmFilePath();\n if (personFile != null) {\n mainApp.saveFilmDataToFile(personFile);\n } else {\n saveAs();\n }\n }", "public boolean save() {\n\t\treturn save(_file);\n\t}", "public void save(){\n checkpoint = chapter;\n }", "public void save() {\n\t\tFileOutputStream fos;\n\t\ttry {\n\t\t\tfos = new FileOutputStream(\"studentData.dat\");\n\n\t\t\tObjectOutputStream oos;\n\t\t\ttry {\n\t\t\t\toos = new ObjectOutputStream(fos);\n\n\t\t\t\toos.writeObject(studentList);\n\t\t\t\toos.close();\n\t\t\t} catch (IOException e) {\n\t\t\t\t// TODO Auto-generated catch block\n\t\t\t\te.printStackTrace();\n\t\t\t}\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\tSystem.out.println(\"File is finished writing to the hard drive\");\n\t}", "public void save() {\n final JFileChooser fileChooser =\n new JFileChooser(System.getProperty(\"user.dir\"));\n try {\n fileChooser.setSelectedFile(new File(\"save.ser\"));\n int saveFile = fileChooser.showSaveDialog(GameFrame.this);\n\n if (saveFile == JFileChooser.APPROVE_OPTION) {\n File saveGame = fileChooser.getSelectedFile();\n FileOutputStream fileOut = new FileOutputStream(saveGame);\n ObjectOutputStream objOut = new ObjectOutputStream(fileOut);\n objOut.writeObject(world);\n objOut.close();\n fileOut.close();\n System.out.println(\"Game saved.\");\n } else {\n return;\n }\n } catch (IOException i) {\n i.printStackTrace();\n }\n\n }", "@Override\n\tpublic void save(Religiao obj) throws Exception {\n\t\t\n\t}", "abstract public void saveData(Bundle bundle);", "@Override\n\tpublic void save() {\n\t\t\n\t\tFile savingDirectory = new File(savingFolder());\n\t\t\n\t\tif( !savingDirectory.isDirectory() ) {\n\t\t\tsavingDirectory.mkdirs();\n\t\t}\n\t\t\n\t\t\n\t\t//Create the file if it's necessary. The file is based on the name of the item. two items in the same directory shouldn't have the same name.\n\t\t\n\t\tFile savingFile = new File(savingDirectory, getIdentifier());\n\t\t\n\t\tif( !savingFile.exists() ) {\n\t\t\t\n\t\t\ttry {\n\t\t\t\tsavingFile.createNewFile();\n\t\t\t} catch (IOException e) {\n\t\t\t\tSystem.err.println(\"the following item couldn't be saved: \" + getIdentifier());\n\t\t\t\te.printStackTrace();\n\t\t\t}\n\t\t\n\t\t}\n\n\t\t\n\t\t//generate the savingTextLine and print it in the savingFile. the previous content is erased when the PrintWriter is created.\n\t\t\n\t\tString text = generateSavingTextLine();\n\n\t\ttry {\n\t\t\tPrintWriter printer = new PrintWriter(savingFile);\n\t\t\tprinter.write(text);\t\t\t\n\t\t\tprinter.close();\n\t\t\t\n\t\t} catch (FileNotFoundException e) {\n\t\t\te.printStackTrace();\n\t\t\tsave();\n\t\t} \n\t}", "public void updatePersistence() {\n\t\tFile file = new File(\"data.txt\");\n\t\tserializeToFile(file);\n\t\tupdatePersistentSettings();\n\t}", "public interface Saveable {\n void save( String key,File file,Context context);\n}", "public void save() throws Exception{\n\t\tFileOutputStream saveFile = new FileOutputStream(Config.languageModelFile);\n\t\tObjectOutputStream save = new ObjectOutputStream(saveFile);\n\t\tsave.writeObject(lm_);\n\t\tsave.close();\n\t}", "public void save()\n\t{\n\t\ttry\n\t\t{\n\t\t\tgetConnection().commit();\n\t\t\tgetPreparedStatement(\"SET FILES SCRIPT FORMAT COMPRESSED\").execute();\n\t\t\t// causes a checkpoint automatically.\n\t\t} catch (SQLException e)\n\t\t{\n\t\t\tm_logger.error(\"Couldn't cleanly save.\", e);\n\t\t}\n\t}", "public void save() {\n savePrefs();\n }" ]
[ "0.77727675", "0.746925", "0.74326175", "0.7395478", "0.7395478", "0.7388317", "0.7386643", "0.7360873", "0.7360873", "0.7360873", "0.724551", "0.724551", "0.72089916", "0.70949274", "0.70949274", "0.70949274", "0.70949274", "0.70837975", "0.7068013", "0.7031073", "0.7016762", "0.69761914", "0.6939786", "0.6938113", "0.6929688", "0.6909311", "0.690159", "0.68952787", "0.6867341", "0.6833923", "0.68034804", "0.6793731", "0.6791542", "0.67874515", "0.6762855", "0.6757456", "0.6752339", "0.6748511", "0.6731649", "0.6729524", "0.67291427", "0.6697024", "0.6678718", "0.6650084", "0.6647283", "0.6644606", "0.6619052", "0.660172", "0.65966856", "0.6590699", "0.659011", "0.65771955", "0.65769", "0.6575959", "0.6575315", "0.6541814", "0.6537232", "0.6532218", "0.65230733", "0.6513655", "0.6512888", "0.6512888", "0.65101874", "0.64948225", "0.6488797", "0.64772546", "0.6477092", "0.6463912", "0.64611256", "0.64600277", "0.64592695", "0.6458433", "0.64536047", "0.64358217", "0.6432737", "0.6432396", "0.64281064", "0.6422773", "0.64168143", "0.641287", "0.64110273", "0.6408896", "0.6403679", "0.63957345", "0.63918006", "0.63794124", "0.63732946", "0.63694674", "0.63686275", "0.63676065", "0.63659364", "0.63607997", "0.63573706", "0.6356317", "0.6353723", "0.63520086", "0.6351322", "0.63492525", "0.63469505", "0.63410515", "0.633741" ]
0.0
-1
calling the methods from the abstract class
public static void main(String[] args) { Test test = new Test(); test.addition(); test.subtraction(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public abstract void call();", "@Override\n\tvoid methodabstract() {\n\t\t\n\t}", "abstract void method();", "public abstract void afvuren();", "public void setupAbstract() {\n \r\n }", "@Override\r\n\tprotected void abstractMethod() {\n\t\tSystem.out.println(\"I'm from the abstract method\");\r\n\t}", "@Override\n\tpublic void anular() {\n\n\t}", "@Override\n public void matiz() {\n System.out.println(\"New not Abstract method\");\n }", "public void calling(){ // when the abstract method is implemented in other class 'public' keyword is used..\r\n System.out.println(\"I am calling...\");\r\n }", "@Override\n\t\tpublic void method() {\n\t\t\t\n\t\t}", "public abstract void abstractone();", "public abstract void comes();", "public abstract void operation();", "@Override\n\tvoid methodAbstractAndSubclassIsAbstract() {\n\t\t\n\t}", "public abstract void mh();", "abstract protected void execute();", "protected abstract void work();", "@Override\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}", "public void callmetoo(){\r\n\tSystem.out.println(\"This is a concrete method\");\r\n\t}", "public abstract void mo70713b();", "public abstract void method1();", "public abstract void mo35054b();", "@Override\n public void function()\n {\n }", "@Override\n public void function()\n {\n }", "public abstract void abstractMethodToImplement();", "public abstract void mo957b();", "protected abstract void execute();", "public abstract void Do();", "abstract void sub();", "@Override\n\tpublic void doStuff() {\n\t\tSystem.out.println(\"Do stuff in Abstract Car\");\n\t}", "public abstract void run() ;", "@Override\n\tpublic void call() {\n\t\t\n\t}", "public abstract void action();", "public abstract void action();", "public abstract void action();", "public abstract void action();", "public abstract void engineWork() throws Exception;", "protected void execute() {\n\t\t\n\t}", "public abstract void mo102899a();", "public abstract void mo27386d();", "public abstract void execute();", "public abstract void execute();", "public abstract void execute();", "@Override\n\tpublic void dosomething() {\n\t\t\n\t}", "@Override\r\n\t\t\tpublic void buscar() {\n\r\n\t\t\t}", "protected void execute() {\r\n }", "public abstract void mo4359a();", "@Override\n\tprotected void logic() {\n\n\t}", "private abstract void privateabstract();", "protected void execute() {}", "public abstract void mo30696a();", "@Override\n\tpublic void method2() {\n\t\tSystem.out.println(\"AbstractClass 추상메쏘드 method2()를 재정의(implement)\");\n\t}", "public abstract void alimentarse();", "public abstract void test();", "public abstract void test();", "protected void execute() {\n\n\t}", "@Override\n\tpublic void comer() {\n\t\t\n\t}", "@Override\r\n\tpublic void method() {\n\t\r\n\t}", "abstract void geometryMethod();", "protected void execute() {\n\t}", "abstract void fly();", "protected void execute() {\n }", "protected void execute() {\n }", "protected void execute() {\n }", "protected void execute() {\n }", "protected void execute() {\n }", "protected void execute() {\n }", "protected void execute() {\n }", "protected void execute() {\n }", "protected void execute() {\n }", "protected void execute() {\n }", "protected void execute() {\n }", "protected void execute() {\n }", "@Override\n\tpublic void emprestimo() {\n\n\t}", "protected void execute()\n {\n }", "public abstract void t3();", "protected void execute()\n\t{\n\t}", "public abstract void mo56925d();", "public abstract void mo2150a();", "abstract void exec();", "abstract void classRooms();", "protected abstract void execute() throws Exception;", "public abstract void calculate();", "public abstract void run();", "public abstract void run();", "public abstract void run();", "public abstract void t1();", "@Override\n\tpublic void buscar() {\n\t\t\n\t}", "abstract public void run() throws Exception;", "public abstract void mo27464a();", "abstract void execute() throws Exception;", "abstract public void performAction();", "public abstract void mo27385c();", "public void logic(){\r\n\r\n\t}", "protected abstract void switchOnCustom();", "abstract void run() throws Exception;", "public abstract void doWork();", "@Override\n protected void prot() {\n }", "@Override\n\tvoid func() {\n\t\tSystem.out.println(\"Overriden Abstract Method\");\n\t}", "@Override\r\n\tpublic void anularFact() {\n\t\t\r\n\t}", "abstract public T doSomething();" ]
[ "0.72921294", "0.7281188", "0.72805977", "0.71395487", "0.69251496", "0.69220114", "0.6884162", "0.6808107", "0.6771317", "0.6751023", "0.67442393", "0.6732579", "0.6725171", "0.66929764", "0.66595286", "0.6608917", "0.6604689", "0.6551204", "0.6540489", "0.6536004", "0.6513295", "0.6492397", "0.6481493", "0.6481493", "0.6472669", "0.64719486", "0.6457958", "0.6451963", "0.6426903", "0.6424585", "0.64144856", "0.6400209", "0.6399524", "0.6399524", "0.6399524", "0.6399524", "0.639684", "0.6394216", "0.6389665", "0.63799614", "0.6375085", "0.6375085", "0.6375085", "0.6371065", "0.636393", "0.63541555", "0.6349614", "0.6345002", "0.6344545", "0.63378817", "0.633618", "0.6334454", "0.6329234", "0.632384", "0.632384", "0.63141483", "0.63136303", "0.62806284", "0.62656903", "0.6262501", "0.6256463", "0.62490046", "0.62490046", "0.62490046", "0.62490046", "0.62490046", "0.62490046", "0.62490046", "0.62490046", "0.62490046", "0.62490046", "0.62490046", "0.62490046", "0.62259156", "0.62196827", "0.6219284", "0.62162864", "0.621506", "0.6211428", "0.62110966", "0.61962813", "0.61934996", "0.61913633", "0.6179961", "0.6179961", "0.6179961", "0.61787", "0.61746806", "0.61638147", "0.61479247", "0.61447626", "0.6138391", "0.6129431", "0.61178195", "0.6110126", "0.6109959", "0.6107062", "0.61060584", "0.6101077", "0.61005706", "0.60944957" ]
0.0
-1
hard code is when you do the operation yourself and not letting the computer handle it
public void addition() { x = 5; y = 11; z = 16; System.out.println("5 + 11 = "+z); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public abstract void operation();", "Operations operations();", "@Override\r\n\tpublic int operar() {\n\t\treturn 0;\r\n\t}", "@Override\r\n\tprotected void compute() {\n\t\t\r\n\t}", "boolean invokeOperation() {\n return false;\n }", "protected abstract void work();", "void work();", "public void work() {\n\t}", "public void work() {\n\t}", "@Override\r\n\tprotected void doF8() {\n\t\t\r\n\t}", "@Override\n\t\t\tpublic void internalWorked(double work) {\n\t\t\t\t\n\t\t\t}", "public void baocun() {\n\t\t\n\t}", "private static void notPossible () {\r\n\t\tSystem.out.println(\"This operation is not possible\");\r\n\t}", "protected final boolean exec()\n/* */ {\n/* 731 */ compute();\n/* 732 */ return false;\n/* */ }", "public void sampleOperation() {\n\t}", "@Override\r\n\tpublic void compute() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void internalWorked(double work) {\n\r\n\t}", "public void compute() {}", "@Override\n public void alRechazarOperacion() {\n }", "public void smell() {\n\t\t\n\t}", "public abstract void runOperation();", "@Override\r\n\tprotected void func03() {\n\t\t\r\n\t}", "public static void compute() {\n\n }", "protected final boolean exec() {\n/* 94 */ this.result = compute();\n/* 95 */ return true;\n/* */ }", "@Override\n\t\t\tpublic void worked(int work) {\n\t\t\t\t\n\t\t\t}", "@Override\r\n\tprotected void processCost() {\n\r\n\t}", "@Override\n protected Integer compute() {\n\n\n return null;\n }", "@Override\n public void func_104112_b() {\n \n }", "abstract void accelarator();", "@Override\n\t\tpublic void internalWorked(double arg0) {\n\n\t\t}", "private void sub() {\n\n\t}", "@Override\n\tprotected void logic() {\n\n\t}", "@Override\r\n\t\t\tpublic void func02() {\n\t\t\t\t\r\n\t\t\t}", "@Override\n\tpublic void coreProblemExecution() {\n\t\t\n\t}", "@Override\n\tpublic void coreProblemExecution() {\n\t\t\n\t}", "@Override\r\n\tpublic void tires() {\n\t\t\r\n\t}", "@Override\n\tpublic void processingInstruction() {\n\t\t\n\t}", "protected void execute() {\n \t// literally still do nothing\n }", "@Override\n\tpublic void myWork() {\n\t\t\n\t}", "public void execute()\n/* */ throws Pausable, Exception\n/* */ {\n/* 378 */ errNotWoven(this);\n/* */ }", "@Override\r\n\tpublic void worked(int work) {\n\t}", "private final void i() {\n }", "public void logic(){\r\n\r\n\t}", "public void excavate();", "private DiscretePotentialOperations() {\r\n\t}", "public final void mo51373a() {\n }", "public abstract void mo56925d();", "protected void execute() {\n\t\t\n\t}", "protected void internalRun() {\n work();\n }", "@Override\r\n \tpublic void process() {\n \t\t\r\n \t}", "@Override\n\tpublic void sacrifier() {\n\t\t\n\t}", "protected abstract long doWork();", "public void method_4270() {}", "@Override\r\n\tvoid func04() {\n\t\t\r\n\t}", "protected boolean func_70814_o() { return true; }", "public abstract void mo20900UP();", "public void mo3376r() {\n }", "public abstract void mo27385c();", "@Override\n\tpublic void additionalWeightWork() {\n\t\t\n\t}", "@Override\n\tpublic void doIt() {\n\t\t\n\t}", "private void m50366E() {\n }", "public void mo21786K() {\n }", "public void mo21877s() {\n }", "@Override\n public void function() {\n App.memory.setMemory(op2, Memory.convertBSToBoolArr(Memory.length32(Integer.toBinaryString(\n op1 * Integer.parseInt(App.memory.getMemory(op2, 1 << 2 + 2 + 1), 2)))));\n }", "public abstract void mo20899UO();", "@Override\r\n\tpublic void func01() {\n\t\t\r\n\t}", "public abstract void mo27386d();", "public abstract void compute();", "public void working()\n {\n \n \n }", "abstract String getOp();", "public void gored() {\n\t\t\n\t}", "public static double operation(int num1,int num2,int operation){\r\n \r\n int result =0 ;\r\n switch(operation){\r\n case 1:\r\n result=num1+num2;\r\n break;\r\n case 2:\r\n result=num1-num2;\r\n break;\r\n case 3:\r\n result=num1*num2;\r\n break;\r\n case 4:\r\n result=num1/num2;\r\n break;\r\n }\r\n return result ;\r\n \r\n}", "private void kk12() {\n\n\t}", "protected void doManaged() {\n // default is no-op\n }", "private void test() {\n\n\t}", "private void someUtilityMethod() {\n }", "private void someUtilityMethod() {\n }", "private static void cajas() {\n\t\t\n\t}", "public void execute(){\n\t\t\n\t}", "@Override\n\t\tpublic void worked(int arg0) {\n\n\t\t}", "public abstract void mo70713b();", "protected void additionalProcessing() {\n\t}", "public abstract void mo6549b();", "protected abstract double operation(double val);", "public final void mo92083O() {\n }", "public void mo12628c() {\n }", "@Override\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}", "public void mo6081a() {\n }", "int executeSafely();", "public void doMore(){\n\t/**\n\t * ArithmeticExceptiont this exception occurs when an integer is \n\t * divided by zero.\n\t * \n\t * */\t\n\t\tint number=500/0;\n\t\t\n\t}", "public void use()\n\t{\n\t}", "public void method_192() {}", "protected abstract Object doCalculations();", "public void mo38117a() {\n }", "private void workOnQueue() {\n }", "public void mo21825b() {\n }", "void evaluate()\n\t{\n\t\toperation.evaluate();\n\t}", "@Override\r\n\tpublic void func02() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void func02() {\n\t\t\r\n\t}", "public void mo21787L() {\n }", "public final void mo8775b() {\n }" ]
[ "0.6475295", "0.62704444", "0.6103344", "0.6084492", "0.60104704", "0.600719", "0.59963286", "0.5978683", "0.5978683", "0.5973983", "0.5959162", "0.5927948", "0.5927153", "0.5923805", "0.59109384", "0.588485", "0.5860296", "0.5838803", "0.58322656", "0.5828547", "0.5825938", "0.5812592", "0.57580143", "0.5737469", "0.57170296", "0.5705872", "0.5704206", "0.5660198", "0.5638567", "0.56287944", "0.56109047", "0.56062025", "0.55957466", "0.559249", "0.559249", "0.55789465", "0.5549086", "0.5545184", "0.55411834", "0.55268246", "0.5524116", "0.5517529", "0.55154526", "0.5511602", "0.54983133", "0.5493026", "0.5489874", "0.5489524", "0.5484242", "0.5481237", "0.547757", "0.54754907", "0.5474068", "0.54714733", "0.5459944", "0.5457726", "0.545462", "0.5454474", "0.5451976", "0.5451202", "0.544813", "0.54445565", "0.54422325", "0.5439402", "0.54363024", "0.5429965", "0.54247415", "0.5413498", "0.5409906", "0.54054695", "0.5401276", "0.5398227", "0.53980666", "0.53955185", "0.5390787", "0.53886384", "0.53886384", "0.538513", "0.5379166", "0.5375854", "0.53732616", "0.5365422", "0.53585804", "0.53518873", "0.534883", "0.5341648", "0.53405803", "0.53352714", "0.5334782", "0.5333094", "0.53330404", "0.5331227", "0.5330544", "0.53275883", "0.5325191", "0.53242075", "0.5318538", "0.53094393", "0.53094393", "0.5308493", "0.5308137" ]
0.0
-1
soft code: i let the computer do it
public void division() { x=1; y=0; z=x/y; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\r\n\tpublic void code() {\n\t\tus.code();\r\n\t\tSystem.out.println(\"我会java...\");\r\n\t}", "void mo57278c();", "void mo41086b();", "public void mo38117a() {\n }", "void mo67924c();", "void mo72114c();", "public void mo9848a() {\n }", "void mo21073d();", "void mo119582b();", "private static void cajas() {\n\t\t\n\t}", "void mo12637b();", "void mo4833b();", "void mo57277b();", "void mo12638c();", "void mo72113b();", "void mo80457c();", "void mo21072c();", "void mo27575a();", "public void mo21786K() {\n }", "void mo88524c();", "void mo119581a();", "void mo80455b();", "public void mo21785J() {\n }", "void mo41083a();", "abstract protected void pre(int code);", "public void mo33392b() {\n mo33395e();\n }", "public void mo4359a() {\n }", "void mo21074e();", "public void mo12628c() {\n }", "void bypass();", "public void mo21794S() {\n }", "@Override\r\n\tpublic void code() {\n\t\tSystem.out.println(\"我会C语言....\");\r\n\t}", "public void mo21867i() {\n mo21877s();\n }", "public void mo97908d() {\n }", "public void mo12930a() {\n }", "void mo21076g();", "void mo57275a();", "void mo60893b();", "public void mo3749d() {\n }", "private final void i() {\n }", "public void mo21782G() {\n }", "void mo67923b();", "CD withCode();", "void mo80452a();", "void mo98969a();", "public void mo6081a() {\n }", "C2841w mo7234g();", "public void mo5097b() {\n }", "void mo10148a();", "public void mo21779D() {\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 }", "public void mo55254a() {\n }", "public void mo21791P() {\n }", "private void run() {\n int code = memory[pc];\n while (code != 0) {\n nextCode(code);\n code = memory[++pc];\n }\n }", "public void mo21877s() {\n }", "void mo7350a();", "public abstract void mo27385c();", "public void mo55254a() {\n }", "protected final /* synthetic */ java.lang.Object run() {\n /*\n r4 = this;\n r0 = 1;\n r1 = 0;\n r2 = com.tencent.mm.plugin.appbrand.b.c.this;\n r2 = r2.chu();\n r3 = com.tencent.mm.plugin.appbrand.b.c.this;\n r3 = r3.iKh;\n if (r2 != r3) goto L_0x0022;\n L_0x000e:\n r2 = com.tencent.mm.plugin.appbrand.b.c.this;\n r2 = r2.iKh;\n r2 = r2.iKy;\n r2 = r2 & 1;\n if (r2 <= 0) goto L_0x0020;\n L_0x0018:\n r2 = r0;\n L_0x0019:\n if (r2 == 0) goto L_0x0022;\n L_0x001b:\n r0 = java.lang.Boolean.valueOf(r0);\n return r0;\n L_0x0020:\n r2 = r1;\n goto L_0x0019;\n L_0x0022:\n r0 = r1;\n goto L_0x001b;\n */\n throw new UnsupportedOperationException(\"Method not decompiled: com.tencent.mm.plugin.appbrand.b.c.5.run():java.lang.Object\");\n }", "void mo88523b();", "void mo88521a();", "public void mo33394d() {\n mo33393c();\n mo33395e();\n }", "public void mo21787L() {\n }", "public final void mo11687c() {\n }", "void mo1637a();", "public void mo9241ay() {\n }", "public void mo21825b() {\n }", "void mo17012c();", "public void mo21789N() {\n }", "void mo67920a();", "void mo21070b();", "public void mo3376r() {\n }", "void mo84655a();", "public void mo8738a() {\n }", "void mo13368a();", "public void mo21781F() {\n }", "public final void mo8775b() {\n }", "public void mo21780E() {\n }", "private void kk12() {\n\n\t}", "void mo38026a();", "public void mo5382o() {\n }", "void mo17021c();", "public final void mo51373a() {\n }", "public abstract void mo27386d();", "void mo28306a();", "void mo22249a();", "public void mo115190b() {\n }", "public void baocun() {\n\t\t\n\t}", "public void mo2740a() {\n }", "public void mo3287b() {\n }", "void mo12634a();", "void mo1493c();", "public void mo21784I() {\n }", "void mo37810a();", "void mo72111a();", "public void mo21795T() {\n }" ]
[ "0.6508681", "0.64074385", "0.63984114", "0.63169724", "0.63004655", "0.6280639", "0.6274963", "0.62487715", "0.6233056", "0.6208781", "0.620031", "0.6193907", "0.6187764", "0.617415", "0.6168304", "0.6161281", "0.61586964", "0.6141058", "0.61310494", "0.61290014", "0.61232394", "0.61192405", "0.6112484", "0.6099291", "0.6081012", "0.6074751", "0.6061735", "0.6050864", "0.6029414", "0.6019886", "0.60109425", "0.6010811", "0.599669", "0.59948504", "0.5994122", "0.5987135", "0.59792167", "0.597841", "0.5976678", "0.5976612", "0.5976291", "0.59735304", "0.5972566", "0.59720194", "0.59680223", "0.5967807", "0.5964867", "0.59608227", "0.5959741", "0.5958091", "0.59539723", "0.59539723", "0.59539723", "0.59539723", "0.59539723", "0.59539723", "0.59539723", "0.5947255", "0.5937555", "0.59305954", "0.5929809", "0.59274596", "0.59207356", "0.59205043", "0.5915348", "0.5914931", "0.59138596", "0.59138", "0.59088683", "0.5907563", "0.590425", "0.5888442", "0.5884838", "0.5882604", "0.58790255", "0.58783346", "0.5877975", "0.5871912", "0.5869827", "0.5869142", "0.58683217", "0.5862293", "0.58605784", "0.5859319", "0.58565533", "0.5852579", "0.5850325", "0.58479935", "0.58473724", "0.5844742", "0.584156", "0.5840167", "0.58353764", "0.58318496", "0.5827451", "0.58220536", "0.5820915", "0.58198404", "0.58177775", "0.58165675", "0.5812855" ]
0.0
-1
Creates a new SqlStatementBuilder.
public DB2SqlStatementBuilder(Delimiter defaultDelimiter) { super(defaultDelimiter); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Nonnull\n public static UBL23WriterBuilder <StatementType> statement ()\n {\n return UBL23WriterBuilder.create (StatementType.class);\n }", "Statement createStatement();", "Statement createStatement();", "Statement createStatement();", "public org.apache.calcite.avatica.proto.Common.StatementHandle.Builder getStatementBuilder() {\n \n onChanged();\n return getStatementFieldBuilder().getBuilder();\n }", "public static InsertStatementBuilder insert() {\r\n return new InsertStatementBuilder();\r\n }", "@Override\r\n\t\tpublic Statement createStatement() throws SQLException {\n\t\t\treturn this.conn.createStatement();\r\n\t\t}", "public Statement newStatement() {\r\n Statement result = null;\r\n try {\r\n result = connection.createStatement();\r\n } catch (SQLException e) {\r\n log.warning(e.getMessage());\r\n }\r\n return result;\r\n }", "void build(ISqlClauseBuilder builder);", "public SqlConnectionPool build() throws SQLException {\n HikariConfig config = new HikariConfig();\n config.setJdbcUrl(\"jdbc:mysql://\" + HOST + \":\" + PORT + \"/\" + database + \"\");\n config.setUsername(USERNAME);\n config.setPassword(PASSWORD);\n config.setPoolName(poolName);\n return new SqlConnectionPool(new HikariDataSource(config));\n }", "StatementBlock createStatementBlock();", "private CreateStatementResponse(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) {\n super(builder);\n }", "public static SqlUtil forHSQLDB() {\r\n return new SqlUtil(HSQLDB);\r\n }", "JavaStatement createJavaStatement();", "final public SqlStatement Statement() throws ParseException {SqlStatement st = null;\n switch ((jj_ntk==-1)?jj_ntk_f():jj_ntk) {\n case USE:{\n st = UseStatement();\n break;\n }\n case SET:{\n st = SetVariableStatement();\n break;\n }\n case CREATE:{\n st = CreateStatement();\n break;\n }\n case ALTER:{\n st = AlterStatement();\n break;\n }\n case DROP:{\n st = DropStatement();\n break;\n }\n case INSERT:{\n st = InsertStatement();\n break;\n }\n case LOCK:{\n st = LockTablesStatement();\n break;\n }\n case UNLOCK:{\n st = UnlockTablesStatement();\n break;\n }\n case START:{\n st = StartTransactionStatement();\n break;\n }\n case COMMIT:{\n st = CommitTransactionStatement();\n break;\n }\n default:\n jj_la1[2] = jj_gen;\nst = new EmptyStatement();\n }\nreturn st;\n}", "final public SqlStatement CreateTableStatement() throws ParseException {Token tk = null, tk2 = null;\n String tableName;\n CreateTableDefinition definition = null;\n List<CreateTableOption> options = null;\n switch ((jj_ntk==-1)?jj_ntk_f():jj_ntk) {\n case TEMPORARY:{\n tk = jj_consume_token(TEMPORARY);\n break;\n }\n default:\n jj_la1[16] = jj_gen;\n ;\n }\n jj_consume_token(TABLE);\n switch ((jj_ntk==-1)?jj_ntk_f():jj_ntk) {\n case IF:{\n tk2 = jj_consume_token(IF);\n jj_consume_token(NOT);\n jj_consume_token(EXISTS);\n break;\n }\n default:\n jj_la1[17] = jj_gen;\n ;\n }\n tableName = DbObjectName();\n switch ((jj_ntk==-1)?jj_ntk_f():jj_ntk) {\n case 118:{\n definition = CreateTableDefinition();\n break;\n }\n default:\n jj_la1[18] = jj_gen;\n ;\n }\n switch ((jj_ntk==-1)?jj_ntk_f():jj_ntk) {\n case K_DEFAULT:\n case AUTO_INCREMENT:\n case COMMENT:\n case S_IDENTIFIER:{\n options = CreateTableOptions();\n break;\n }\n default:\n jj_la1[19] = jj_gen;\n ;\n }\nreturn new CreateTableStatement(tk != null, tk2 != null, tableName, definition, options);\n}", "protected static Statement newStatement(ReviewDb db) throws SQLException {\n return ((JdbcSchema) db).getConnection().createStatement();\n }", "public Builder clearSqlState() {\n \n sqlState_ = getDefaultInstance().getSqlState();\n onChanged();\n return this;\n }", "private com.google.protobuf.SingleFieldBuilderV3<\n org.apache.calcite.avatica.proto.Common.StatementHandle, org.apache.calcite.avatica.proto.Common.StatementHandle.Builder, org.apache.calcite.avatica.proto.Common.StatementHandleOrBuilder> \n getStatementFieldBuilder() {\n if (statementBuilder_ == null) {\n statementBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<\n org.apache.calcite.avatica.proto.Common.StatementHandle, org.apache.calcite.avatica.proto.Common.StatementHandle.Builder, org.apache.calcite.avatica.proto.Common.StatementHandleOrBuilder>(\n getStatement(),\n getParentForChildren(),\n isClean());\n statement_ = null;\n }\n return statementBuilder_;\n }", "public QueryBuilder()\n {\n\tlabel = null;\n\tqueryCondition = null;\n\tselectionLimiter = null;\n\tselectionSorter = null;\n\n\tvariablesMap = new HashMap<String, Expression>();\n\tselectionLabelsReferencedByStats = new HashSet<String>();\n }", "private CreateDatabaseRequest(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) {\n super(builder);\n }", "public Sql(String sql) {\n \n this();\n append(sql);\n }", "InsertStatement(InsertStatementBuilder builder) {\r\n super();\r\n this.table = builder.getTable();\r\n this.fromTable = builder.getFromTable();\r\n this.selectStatement = builder.getSelectStatement();\r\n if (AliasedField.immutableDslEnabled()) {\r\n this.fields = ImmutableList.copyOf(builder.getFields());\r\n this.hints = ImmutableList.copyOf(builder.getHints());\r\n this.values = ImmutableList.copyOf(builder.getValues());\r\n this.fieldDefaults = ImmutableMap.copyOf(builder.getFieldDefaults());\r\n } else {\r\n this.fields = new ArrayList<>();\r\n this.hints = new ArrayList<>();\r\n this.values = new ArrayList<>();\r\n this.fieldDefaults = new HashMap<>();\r\n this.fields.addAll(builder.getFields());\r\n this.values.addAll(builder.getValues());\r\n this.fieldDefaults.putAll(builder.getFieldDefaults());\r\n this.hints.addAll(builder.getHints());\r\n }\r\n }", "public RemoteStatement createStatement() throws RemoteException {\r\n return new RemoteStatementImpl(this);\r\n }", "private Builder() {\n super(SCHEMA$);\n }", "private Builder() {\n super(SCHEMA$);\n }", "private Builder() {\n super(SCHEMA$);\n }", "private Builder() {\n super(SCHEMA$);\n }", "private Builder() {\n super(SCHEMA$);\n }", "private Builder() {\n super(SCHEMA$);\n }", "private Builder() {\n super(SCHEMA$);\n }", "private Builder() {\n super(SCHEMA$);\n }", "private Builder() {\n super(SCHEMA$);\n }", "private Builder() {\n super(SCHEMA$);\n }", "private Builder() {\n super(SCHEMA$);\n }", "private Builder() {\n super(SCHEMA$);\n }", "private Builder() {\n super(SCHEMA$);\n }", "private Builder() {\n super(SCHEMA$);\n }", "private Builder() {\n super(SCHEMA$);\n }", "private Builder() {\n super(SCHEMA$);\n }", "private Builder() {\n super(SCHEMA$);\n }", "private Builder() {\n super(SCHEMA$);\n }", "private Builder() {\n super(SCHEMA$);\n }", "private Builder() {\n super(SCHEMA$);\n }", "public com.google.cloud.networkmanagement.v1beta1.CloudSQLInstanceInfo.Builder\n getCloudSqlInstanceBuilder() {\n return getCloudSqlInstanceFieldBuilder().getBuilder();\n }", "private Builder() {\n super(edu.pa.Rat.SCHEMA$);\n }", "protected void generateFromClause( WrqInfo wrqInfo, SQLStatementWithParams sqlStatement ) throws BindingException\n {\n sqlStatement.append(\" FROM \");\n WrqBindingSet bs = wrqInfo.getResultingBindingSet();\n resolvedBindingSets.addAll(bs.getResolvedBindingSets());\n sqlStatement.append(wrqInfo.getSQLSelectWithParams()); \n }", "BSQL2Java2 createBSQL2Java2();", "public Builder clearOwnStatement() {\n \n ownStatement_ = false;\n onChanged();\n return this;\n }", "CompoundStatement createCompoundStatement();", "private RhinoScriptBuilder initScriptBuilder() {\r\n // TODO: Find a way to encapsulate this code\r\n RhinoScriptBuilder builder = null;\r\n try {\r\n if (scope == null) {\r\n builder = RhinoScriptBuilder.newChain().addJSON().evaluateChain(UglifyJs.class.getResourceAsStream(\"init.js\"),\r\n \"initScript\").evaluateChain(getScriptAsStream(), DEFAULT_UGLIFY_JS);\r\n scope = builder.getScope();\r\n } else {\r\n builder = RhinoScriptBuilder.newChain(scope);\r\n }\r\n return builder;\r\n } catch (final Exception ex) {\r\n throw new IllegalStateException(\"Failed initializing js\", ex);\r\n }\r\n }", "public static SchemaTableBuilder tableBuilder(String schemaName, String tableName) {\n return new SchemaTableBuilderImpl(schemaName, tableName);\n }", "private Builder() {\n super(QueryBankBalanceMessage.SCHEMA$);\n }", "abstract protected String buildSQL(BatchSQLEnum sql);", "protected abstract NativeSQLStatement createNativeBufferStatement(Double distance);", "static Builder builder() {\n return new SourceContextImpl.Builder();\n }", "private CreateDatabaseMetadata(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) {\n super(builder);\n }", "public Builder clearStatementId() {\n \n statementId_ = 0;\n onChanged();\n return this;\n }", "public Builder clearStatementId() {\n \n statementId_ = 0;\n onChanged();\n return this;\n }", "public Builder clearStatementId() {\n \n statementId_ = 0;\n onChanged();\n return this;\n }", "protected abstract NativeSQLStatement createNativeSridStatement();", "public LdSqlExecutionCreator createSqlExecutionCreator() {\r\n assertStatus(\"createSqlExecutionCreator\");\r\n return new LdSqlExecutionCreator() {\r\n public LdSqlExecution createSqlExecution() {\r\n final BeanMetaData bmd = createBeanMetaData();\r\n return createBatchDeleteEntitySqlExecution(bmd);\r\n }\r\n };\r\n }", "public messages.Databaseinterface.DatabaseInterface.Builder getDatabaseBuilder() {\n bitField0_ |= 0x00000010;\n onChanged();\n return getDatabaseFieldBuilder().getBuilder();\n }", "private Builder() {\n super(baconhep.TTau.SCHEMA$);\n }", "public Builder toBuilder() {\n return new Builder(this);\n }", "public Builder toBuilder() {\n return new Builder(this);\n }", "public Builder toBuilder() {\n return new Builder(this);\n }", "public Builder toBuilder() {\n return new Builder(this);\n }", "public Builder toBuilder() {\n return new Builder(this);\n }", "public Builder toBuilder() {\n return new Builder(this);\n }", "public Builder toBuilder() {\n return new Builder(this);\n }", "public Builder setSqlStateBytes(\n com.google.protobuf.ByteString value) {\n if (value == null) {\n throw new NullPointerException();\n }\n checkByteStringIsUtf8(value);\n \n sqlState_ = value;\n onChanged();\n return this;\n }", "protected void createSelectStatement() throws Exception\n {\n selectStatement = new SQLStatementWithParams();\n\n // Generate the SQL and collect all host variables needed to execute it later\n generateSelectClause( wrqInfo, selectStatement );\n generateFromClause( wrqInfo, selectStatement );\n generateWhereClause( wrqInfo, selectStatement );\n generateGroupingClause( wrqInfo, selectStatement );\n generateHavingClause( wrqInfo, selectStatement );\n generateOrderClause( wrqInfo, selectStatement );\n }", "public QueryBuilder buildQueryBuilder() {\n return dao.getQueryBuilder()\n .from(dao.getEntityClass(), (joinBuilder != null ? joinBuilder.getRootAlias() : null))\n .join(joinBuilder)\n .add(queryRestrictions)\n .debug(debug)\n .audit(isAuditQuery());\n }", "public Builder clearStatement() {\n if (statementBuilder_ == null) {\n statement_ = null;\n onChanged();\n } else {\n statement_ = null;\n statementBuilder_ = null;\n }\n\n return this;\n }", "public Builder() {}", "public Builder() {}", "public Builder() {}", "@Override\r\n\t\tpublic Statement createStatement(int resultSetType,\r\n\t\t\t\tint resultSetConcurrency, int resultSetHoldability)\r\n\t\t\t\tthrows SQLException {\n\t\t\treturn null;\r\n\t\t}", "static SchemaBuilder newInstance() {\n return new SchemaBuilderImpl();\n }", "public ContainsBuilder(DataBaseConnection dataBaseConnection) {\n super(dataBaseConnection);\n selectBuilder = new SelectBuilder(dataBaseConnection);\n }", "protected PreparedStatement prepareStmt() throws SQLException {\n if (stmt == null) {\n buildSQL();\n }\n\n return stmt;\n }", "public Builder setSqlState(\n java.lang.String value) {\n if (value == null) {\n throw new NullPointerException();\n }\n \n sqlState_ = value;\n onChanged();\n return this;\n }", "public QueryCore buildQuery() throws SQLException\n {\n if(l != null)\n {\n for(int i=0;i<l.size();i++)\n {\n prepStm.setObject(i+1,l.get(i));\n }\n }\n return this;\n }", "private Statement createStatement(Connection conn) throws SQLException {\n Statement statement = conn.createStatement(java.sql.ResultSet.TYPE_FORWARD_ONLY, java.sql.ResultSet.CONCUR_READ_ONLY);\n if (fetchSize != -1) {\n statement.setFetchSize(fetchSize);\n }\n if (queryTimeout > 0) {\n statement.setQueryTimeout(queryTimeout);\n }\n return statement;\n }", "final public SqlStatement ScriptStatement() throws ParseException {SqlStatement st = null;\n switch ((jj_ntk==-1)?jj_ntk_f():jj_ntk) {\n case USE:\n case CREATE:\n case DROP:\n case SET:\n case INSERT:\n case ALTER:\n case LOCK:\n case UNLOCK:\n case START:\n case COMMIT:\n case 117:{\n st = Statement();\n jj_consume_token(117);\n break;\n }\n case 0:{\n jj_consume_token(0);\n break;\n }\n default:\n jj_la1[1] = jj_gen;\n jj_consume_token(-1);\n throw new ParseException();\n }\nreturn st;\n}", "static Builder builder(SourceContext source) {\n return new SourceContextImpl.Builder((SourceContextImpl) source);\n }", "@Nonnull\n public static UBL23WriterBuilder <UtilityStatementType> utilityStatement ()\n {\n return UBL23WriterBuilder.create (UtilityStatementType.class);\n }", "public Builder mergeStatement(org.apache.calcite.avatica.proto.Common.StatementHandle value) {\n if (statementBuilder_ == null) {\n if (statement_ != null) {\n statement_ =\n org.apache.calcite.avatica.proto.Common.StatementHandle.newBuilder(statement_).mergeFrom(value).buildPartial();\n } else {\n statement_ = value;\n }\n onChanged();\n } else {\n statementBuilder_.mergeFrom(value);\n }\n\n return this;\n }", "private void sqlBuilder(int sqlSelector)\n {\n String sql[] = new String[3];\n switch(sqlSelector)\n {\n case 1000: sql[0] = \"SELECT DISTINCT BRANCH_CODE FROM \"\n + \"GOSALES.BRANCH ORDER BY BRANCH_CODE\";\n sql[1] = \"SELECT DISTINCT PRODUCT_BRAND_EN FROM \"\n + \"GOSALES.PRODUCT_BRAND ORDER BY \"\n + \"PRODUCT_BRAND_EN\";\n sql[2] = \"SELECT DISTINCT PRODUCT_TYPE_EN FROM \"\n + \"GOSALES.PRODUCT_TYPE ORDER BY \"\n + \"PRODUCT_TYPE_EN\";\n initializeDropBoxes(sql, sqlSelector); \n break;\n //------------------------------------------------------------------\n case 1001: sql[0] = \"SELECT DISTINCT bran.BRANCH_CODE\\n\" \n + \"FROM GOSALES.BRANCH AS bran\\n\" \n + \"JOIN GOSALES.INVENTORY_LEVELS AS invLvls\\n\" \n + \"ON invLvls.WAREHOUSE_BRANCH_CODE = \"\n + \"bran.WAREHOUSE_BRANCH_CODE\\n\" \n + \"JOIN GOSALES.PRODUCT AS prod\\n\" \n + \"ON prod.PRODUCT_NUMBER = \"\n + \"invLvls.PRODUCT_NUMBER\\n\" \n + \"JOIN GOSALES.PRODUCT_TYPE as prodType\\n\" \n + \"ON prodType.PRODUCT_TYPE_CODE = \"\n + \"prod.PRODUCT_TYPE_CODE\\n\" \n + \"WHERE UPPER(prodType.PRODUCT_TYPE_EN) LIKE \"\n + \"UPPER('\" \n + dropBox3.getSelectedItem().toString() \n + \"') ORDER BY bran.BRANCH_CODE\";\n sql[1] = \"SELECT DISTINCT prodBrand.PRODUCT_BRAND_EN \"\n + \"FROM GOSALES.PRODUCT_BRAND AS prodBrand \"\n + \"JOIN GOSALES.SALES_TARGET AS sTar \"\n + \"ON prodBrand.PRODUCT_BRAND_CODE = \"\n + \"sTar.PRODUCT_BRAND_CODE \"\n + \"WHERE sTar.PRODUCT_TYPE_CODE = \"\n + \"(SELECT prodType.PRODUCT_TYPE_CODE \"\n + \"FROM GOSALES.PRODUCT_TYPE AS prodType \"\n + \"WHERE UPPER(prodType.PRODUCT_TYPE_EN) \"\n + \"LIKE UPPER('\" \n + dropBox3.getSelectedItem().toString() \n + \"') ORDER BY prodBrand.PRODUCT_BRAND_EN)\";\n initializeDropBoxes(sql, sqlSelector);\n break;\n //------------------------------------------------------------------\n case 1010: sql[0] = \"SELECT DISTINCT bran.BRANCH_CODE\\n\" \n + \"FROM GOSALES.BRANCH AS bran\\n\" \n + \"JOIN GOSALES.INVENTORY_LEVELS AS invLvl\\n\" \n + \"ON invLvl.WAREHOUSE_BRANCH_CODE = \"\n + \"bran.BRANCH_CODE\\n\" \n + \"JOIN GOSALES.PRODUCT AS prod\\n\" \n + \"ON prod.PRODUCT_NUMBER = \"\n + \"invLvl.PRODUCT_NUMBER\\n\" \n + \"JOIN GOSALES.PRODUCT_BRAND AS prodBrand\\n\" \n + \"ON prodBrand.PRODUCT_BRAND_CODE = \"\n + \"prod.PRODUCT_BRAND_CODE\\n\" \n + \"WHERE UPPER(prodBrand.PRODUCT_BRAND_EN) \"\n + \"LIKE UPPER('\"\n + dropBox2.getSelectedItem().toString()\n + \"')\";\n sql[2] = \"SELECT DISTINCT prodType.PRODUCT_TYPE_EN\\n\" \n + \"FROM GOSALES.PRODUCT_BRAND AS prodBrand\\n\" \n + \"JOIN GOSALES.SALES_TARGET AS saleTar\\n\" \n + \"ON saleTar.PRODUCT_BRAND_CODE = \"\n + \"prodBrand.PRODUCT_BRAND_CODE\\n\" \n + \"JOIN GOSALES.PRODUCT_TYPE AS prodType\\n\" \n + \"ON saleTar.PRODUCT_TYPE_CODE = \"\n + \"prodType.PRODUCT_TYPE_CODE\\n\" \n + \"WHERE UPPER(prodBrand.PRODUCT_BRAND_EN) \"\n + \"LIKE UPPER('\" \n + dropBox2.getSelectedItem().toString()\n + \"')\";\n initializeDropBoxes(sql, sqlSelector);\n break;\n //------------------------------------------------------------------\n case 1011: sql[0] = \"SELECT DISTINCT bran.BRANCH_CODE\\n\" \n + \"FROM GOSALES.BRANCH AS bran\\n\" \n + \"JOIN GOSALES.INVENTORY_LEVELS AS invLvl\\n\" \n + \"ON invLvl.WAREHOUSE_BRANCH_CODE = \"\n + \"bran.WAREHOUSE_BRANCH_CODE\\n\" \n + \"JOIN GOSALES.PRODUCT AS prod\\n\" \n + \"ON prod.PRODUCT_NUMBER = \"\n + \"invLvl.PRODUCT_NUMBER\\n\" \n + \"JOIN GOSALES.PRODUCT_BRAND as prodBrand\\n\" \n + \"ON prod.PRODUCT_BRAND_CODE = \"\n + \"prodBrand.PRODUCT_BRAND_CODE\\n\" \n + \"JOIN GOSALES.PRODUCT_TYPE AS prodType\\n\" \n + \"ON prod.PRODUCT_TYPE_CODE = \"\n + \"prodType.PRODUCT_TYPE_CODE\\n\" \n + \"WHERE UPPER(prodBrand.PRODUCT_BRAND_EN) \"\n + \"LIKE UPPER('\"\n + dropBox2.getSelectedItem().toString()\n + \"')\\n\" \n + \"AND UPPER(prodType.PRODUCT_TYPE_EN) \"\n + \"LIKE UPPER('\"\n + dropBox3.getSelectedItem().toString()\n + \"')\\n\" \n + \"ORDER BY bran.BRANCH_CODE\";\n initializeDropBoxes(sql, sqlSelector);\n break;\n //------------------------------------------------------------------\n case 1100: sql[1] = \"SELECT DISTINCT prodBrand.PRODUCT_BRAND_EN\\n\" \n + \"FROM GOSALES.BRANCH AS bran\\n\" \n + \"JOIN GOSALES.INVENTORY_LEVELS AS invLvl\\n\" \n + \"ON invLvl.WAREHOUSE_BRANCH_CODE = \"\n + \"bran.WAREHOUSE_BRANCH_CODE\\n\" \n + \"JOIN GOSALES.PRODUCT AS prod\\n\" \n + \"ON prod.PRODUCT_NUMBER = \"\n + \"invLvl.PRODUCT_NUMBER\\n\" \n + \"JOIN GOSALES.PRODUCT_BRAND as prodBrand\\n\" \n + \"ON prod.PRODUCT_BRAND_CODE = \"\n + \"prodBrand.PRODUCT_BRAND_CODE\\n\" \n + \"JOIN GOSALES.PRODUCT_TYPE AS prodType\\n\" \n + \"ON prod.PRODUCT_TYPE_CODE = \"\n + \"prodType.PRODUCT_TYPE_CODE\\n\" \n + \"WHERE bran.BRANCH_CODE = \"\n + dropBox1.getSelectedItem().toString()\n + \" ORDER BY prodBrand.PRODUCT_BRAND_EN\";\n sql[2] = \"SELECT DISTINCT prodType.PRODUCT_TYPE_EN\\n\" \n + \"FROM GOSALES.BRANCH AS bran\\n\" \n + \"JOIN GOSALES.INVENTORY_LEVELS AS invLvl\\n\" \n + \"ON invLvl.WAREHOUSE_BRANCH_CODE = \"\n + \"bran.WAREHOUSE_BRANCH_CODE\\n\" \n + \"JOIN GOSALES.PRODUCT AS prod\\n\" \n + \"ON prod.PRODUCT_NUMBER = \"\n + \"invLvl.PRODUCT_NUMBER\\n\" \n + \"JOIN GOSALES.PRODUCT_BRAND as prodBrand\\n\" \n + \"ON prod.PRODUCT_BRAND_CODE = \"\n + \"prodBrand.PRODUCT_BRAND_CODE\\n\" \n + \"JOIN GOSALES.PRODUCT_TYPE AS prodType\\n\" \n + \"ON prod.PRODUCT_TYPE_CODE = \"\n + \"prodType.PRODUCT_TYPE_CODE\\n\" \n + \"WHERE bran.BRANCH_CODE = \"\n + dropBox1.getSelectedItem().toString()\n + \" ORDER BY prodType.PRODUCT_TYPE_EN\";\n initializeDropBoxes(sql, sqlSelector);\n break;\n //------------------------------------------------------------------\n case 1101: sql[1] = \"SELECT DISTINCT prodBrand.PRODUCT_BRAND_EN\\n\" \n + \"FROM GOSALES.BRANCH AS bran\\n\" \n + \"JOIN GOSALES.INVENTORY_LEVELS AS invLvl\\n\" \n + \"ON invLvl.WAREHOUSE_BRANCH_CODE = \"\n + \"bran.WAREHOUSE_BRANCH_CODE\\n\" \n + \"JOIN GOSALES.PRODUCT AS prod\\n\" \n + \"ON prod.PRODUCT_NUMBER = \"\n + \"invLvl.PRODUCT_NUMBER\\n\" \n + \"JOIN GOSALES.PRODUCT_BRAND as prodBrand\\n\" \n + \"ON prod.PRODUCT_BRAND_CODE = \"\n + \"prodBrand.PRODUCT_BRAND_CODE\\n\" \n + \"JOIN GOSALES.PRODUCT_TYPE AS prodType\\n\" \n + \"ON prod.PRODUCT_TYPE_CODE = \"\n + \"prodType.PRODUCT_TYPE_CODE\\n\" \n + \"WHERE bran.BRANCH_CODE = \"\n + dropBox1.getSelectedItem().toString()\n + \" AND UPPER(prodType.PRODUCT_TYPE_EN) LIKE UPPER('\"\n + dropBox3.getSelectedItem().toString()\n + \"') ORDER BY prodBrand.PRODUCT_BRAND_EN\";\n initializeDropBoxes(sql, sqlSelector);\n break;\n //------------------------------------------------------------------\n case 1110: sql[2] = \"SELECT DISTINCT prodType.PRODUCT_TYPE_EN\\n\" \n + \"FROM GOSALES.BRANCH AS bran\\n\" \n + \"JOIN GOSALES.INVENTORY_LEVELS AS invLvl\\n\" \n + \"ON invLvl.WAREHOUSE_BRANCH_CODE = \"\n + \"bran.WAREHOUSE_BRANCH_CODE\\n\" \n + \"JOIN GOSALES.PRODUCT AS prod\\n\" \n + \"ON prod.PRODUCT_NUMBER = \"\n + \"invLvl.PRODUCT_NUMBER\\n\" \n + \"JOIN GOSALES.PRODUCT_BRAND as prodBrand\\n\" \n + \"ON prod.PRODUCT_BRAND_CODE = \"\n + \"prodBrand.PRODUCT_BRAND_CODE\\n\" \n + \"JOIN GOSALES.PRODUCT_TYPE AS prodType\\n\" \n + \"ON prod.PRODUCT_TYPE_CODE = \"\n + \"prodType.PRODUCT_TYPE_CODE\\n\" \n + \"WHERE bran.BRANCH_CODE = \"\n + dropBox1.getSelectedItem().toString()\n + \" AND UPPER(prodBrand.PRODUCT_BRAND_EN) \"\n + \"LIKE UPPER('\"\n + dropBox2.getSelectedItem().toString()\n + \"') ORDER BY prodType.PRODUCT_TYPE_EN\";\n initializeDropBoxes(sql, sqlSelector);\n break;\n //------------------------------------------------------------------\n case 2111: sql[0] = \"SELECT SUM((orderDet.quantity * \"\n + \"orderDet.unit_sale_price)) AS total\\n\" \n + \"FROM GOSALES.BRANCH AS bran\\n\" \n + \"JOIN GOSALES.INVENTORY_LEVELS AS invLvl\\n\" \n + \"ON invLvl.WAREHOUSE_BRANCH_CODE = \"\n + \"bran.WAREHOUSE_BRANCH_CODE\\n\" \n + \"JOIN GOSALES.PRODUCT AS prod\\n\" \n + \"ON prod.PRODUCT_NUMBER = \"\n + \"invLvl.PRODUCT_NUMBER\\n\" \n + \"JOIN GOSALES.PRODUCT_BRAND as prodBrand\\n\" \n + \"ON prod.PRODUCT_BRAND_CODE = \"\n + \"prodBrand.PRODUCT_BRAND_CODE\\n\" \n + \"JOIN GOSALES.PRODUCT_TYPE AS prodType\\n\" \n + \"ON prod.PRODUCT_TYPE_CODE = \"\n + \"prodType.PRODUCT_TYPE_CODE\\n\" \n + \"JOIN GOSALES.ORDER_DETAILS AS orderDet\\n\" \n + \"ON orderDet.PRODUCT_NUMBER = \"\n + \"prod.PRODUCT_NUMBER\\n\" \n + \"WHERE bran.BRANCH_CODE = \"\n + dropBox1.getSelectedItem().toString()\n + \" AND UPPER(prodBrand.PRODUCT_BRAND_EN) \"\n + \"LIKE UPPER('\"\n + dropBox2.getSelectedItem().toString()\n + \"') AND UPPER(prodType.PRODUCT_TYPE_EN) \"\n + \"LIKE UPPER('\"\n + dropBox3.getSelectedItem().toString()\n + \"')\";\n initializeDropBoxes(sql, sqlSelector);\n break;\n //------------------------------------------------------------------\n case 2000: sql[0] = \"SELECT SUM((orderDet.quantity * \"\n + \"orderDet.unit_sale_price)) AS total\\n\" \n + \"FROM GOSALES.BRANCH AS bran\\n\" \n + \"JOIN GOSALES.INVENTORY_LEVELS AS invLvl\\n\" \n + \"ON invLvl.WAREHOUSE_BRANCH_CODE = \"\n + \"bran.WAREHOUSE_BRANCH_CODE\\n\" \n + \"JOIN GOSALES.PRODUCT AS prod\\n\" \n + \"ON prod.PRODUCT_NUMBER = \"\n + \"invLvl.PRODUCT_NUMBER\\n\" \n + \"JOIN GOSALES.PRODUCT_BRAND as prodBrand\\n\" \n + \"ON prod.PRODUCT_BRAND_CODE = \"\n + \"prodBrand.PRODUCT_BRAND_CODE\\n\" \n + \"JOIN GOSALES.PRODUCT_TYPE AS prodType\\n\" \n + \"ON prod.PRODUCT_TYPE_CODE = \"\n + \"prodType.PRODUCT_TYPE_CODE\\n\" \n + \"JOIN GOSALES.ORDER_DETAILS AS orderDet\\n\" \n + \"ON orderDet.PRODUCT_NUMBER = \"\n + \"prod.PRODUCT_NUMBER\\n\";\n initializeDropBoxes(sql, sqlSelector);\n break;\n //------------------------------------------------------------------\n case 2001: sql[0] = \"SELECT SUM((orderDet.quantity * \"\n + \"orderDet.unit_sale_price)) AS total\\n\" \n + \"FROM GOSALES.BRANCH AS bran\\n\" \n + \"JOIN GOSALES.INVENTORY_LEVELS AS invLvl\\n\"\n + \"ON invLvl.WAREHOUSE_BRANCH_CODE = \"\n + \"bran.WAREHOUSE_BRANCH_CODE\\n\" \n + \"JOIN GOSALES.PRODUCT AS prod\\n\" \n + \"ON prod.PRODUCT_NUMBER = \"\n + \"invLvl.PRODUCT_NUMBER\\n\" \n + \"JOIN GOSALES.PRODUCT_BRAND as prodBrand\\n\" \n + \"ON prod.PRODUCT_BRAND_CODE = \"\n + \"prodBrand.PRODUCT_BRAND_CODE\\n\" \n + \"JOIN GOSALES.PRODUCT_TYPE AS prodType\\n\" \n + \"ON prod.PRODUCT_TYPE_CODE = \"\n + \"prodType.PRODUCT_TYPE_CODE\\n\" \n + \"JOIN GOSALES.ORDER_DETAILS AS orderDet\\n\" \n + \"ON orderDet.PRODUCT_NUMBER = \"\n + \"prod.PRODUCT_NUMBER\\n\" \n + \" WHERE UPPER(prodType.PRODUCT_TYPE_EN) LIKE \"\n + \"UPPER('\"\n + dropBox3.getSelectedItem().toString()\n +\"')\";\n initializeDropBoxes(sql, sqlSelector);\n break;\n //------------------------------------------------------------------\n case 2010: sql[0] = \"SELECT SUM((orderDet.quantity * \"\n + \"orderDet.unit_sale_price)) AS total\\n\" \n + \"FROM GOSALES.BRANCH AS bran\\n\" \n + \"JOIN GOSALES.INVENTORY_LEVELS AS invLvl\\n\" \n + \"ON invLvl.WAREHOUSE_BRANCH_CODE = \"\n + \"bran.WAREHOUSE_BRANCH_CODE\\n\" \n + \"JOIN GOSALES.PRODUCT AS prod\\n\" \n + \"ON prod.PRODUCT_NUMBER = \"\n + \"invLvl.PRODUCT_NUMBER\\n\" \n + \"JOIN GOSALES.PRODUCT_BRAND as prodBrand\\n\" \n + \"ON prod.PRODUCT_BRAND_CODE = \"\n + \"prodBrand.PRODUCT_BRAND_CODE\\n\" \n + \"JOIN GOSALES.PRODUCT_TYPE AS prodType\\n\" \n + \"ON prod.PRODUCT_TYPE_CODE = \"\n + \"prodType.PRODUCT_TYPE_CODE\\n\" \n + \"JOIN GOSALES.ORDER_DETAILS AS orderDet\\n\" \n + \"ON orderDet.PRODUCT_NUMBER = \"\n + \"prod.PRODUCT_NUMBER\\n\" \n + \"WHERE UPPER(prodBrand.PRODUCT_BRAND_EN) \"\n + \"LIKE UPPER('\"\n + dropBox2.getSelectedItem().toString()\n + \"')\";\n initializeDropBoxes(sql, sqlSelector);\n break;\n //------------------------------------------------------------------\n case 2011: sql[0] = \"SELECT SUM((orderDet.quantity * \"\n + \"orderDet.unit_sale_price)) AS total\\n\" \n + \"FROM GOSALES.BRANCH AS bran\\n\" \n + \"JOIN GOSALES.INVENTORY_LEVELS AS invLvl\\n\" \n + \"ON invLvl.WAREHOUSE_BRANCH_CODE = \"\n + \"bran.WAREHOUSE_BRANCH_CODE\\n\" \n + \"JOIN GOSALES.PRODUCT AS prod\\n\" \n + \"ON prod.PRODUCT_NUMBER = \"\n + \"invLvl.PRODUCT_NUMBER\\n\" \n + \"JOIN GOSALES.PRODUCT_BRAND as prodBrand\\n\" \n + \"ON prod.PRODUCT_BRAND_CODE = \"\n + \"prodBrand.PRODUCT_BRAND_CODE\\n\" \n + \"JOIN GOSALES.PRODUCT_TYPE AS prodType\\n\" \n + \"ON prod.PRODUCT_TYPE_CODE = \"\n + \"prodType.PRODUCT_TYPE_CODE\\n\" \n + \"JOIN GOSALES.ORDER_DETAILS AS orderDet\\n\" \n + \"ON orderDet.PRODUCT_NUMBER = \"\n + \"prod.PRODUCT_NUMBER\\n\" \n + \"WHERE UPPER(prodBrand.PRODUCT_BRAND_EN) \"\n + \"LIKE UPPER('\"\n + dropBox2.getSelectedItem().toString()\n + \"') AND UPPER(prodType.PRODUCT_TYPE_EN) \"\n + \"LIKE UPPER('\"\n + dropBox3.getSelectedItem().toString()\n + \"')\";\n initializeDropBoxes(sql, sqlSelector);\n break;\n //------------------------------------------------------------------\n case 2100: sql[0] = \"SELECT SUM((orderDet.quantity * \"\n + \"orderDet.unit_sale_price)) AS total\\n\" \n + \"FROM GOSALES.BRANCH AS bran\\n\" \n + \"JOIN GOSALES.INVENTORY_LEVELS AS invLvl\\n\" \n + \"ON invLvl.WAREHOUSE_BRANCH_CODE = \"\n + \"bran.WAREHOUSE_BRANCH_CODE\\n\" \n + \"JOIN GOSALES.PRODUCT AS prod\\n\" \n + \"ON prod.PRODUCT_NUMBER = \"\n + \"invLvl.PRODUCT_NUMBER\\n\" \n + \"JOIN GOSALES.PRODUCT_BRAND as prodBrand\\n\" \n + \"ON prod.PRODUCT_BRAND_CODE = \"\n + \"prodBrand.PRODUCT_BRAND_CODE\\n\" \n + \"JOIN GOSALES.PRODUCT_TYPE AS prodType\\n\" \n + \"ON prod.PRODUCT_TYPE_CODE = \"\n + \"prodType.PRODUCT_TYPE_CODE\\n\" \n + \"JOIN GOSALES.ORDER_DETAILS AS orderDet\\n\" \n + \"ON orderDet.PRODUCT_NUMBER = \"\n + \"prod.PRODUCT_NUMBER\\n\" \n + \"WHERE bran.BRANCH_CODE = \"\n + dropBox1.getSelectedItem().toString();\n initializeDropBoxes(sql, sqlSelector);\n break;\n //------------------------------------------------------------------\n case 2101: sql[0] = \"SELECT SUM((orderDet.quantity * \"\n + \"orderDet.unit_sale_price)) AS total\\n\" \n + \"FROM GOSALES.BRANCH AS bran\\n\" \n + \"JOIN GOSALES.INVENTORY_LEVELS AS invLvl\\n\" \n + \"ON invLvl.WAREHOUSE_BRANCH_CODE = \"\n + \"bran.WAREHOUSE_BRANCH_CODE\\n\" \n + \"JOIN GOSALES.PRODUCT AS prod\\n\" \n + \"ON prod.PRODUCT_NUMBER = \"\n + \"invLvl.PRODUCT_NUMBER\\n\" \n + \"JOIN GOSALES.PRODUCT_BRAND as prodBrand\\n\" \n + \"ON prod.PRODUCT_BRAND_CODE = \"\n + \"prodBrand.PRODUCT_BRAND_CODE\\n\" \n + \"JOIN GOSALES.PRODUCT_TYPE AS prodType\\n\" \n + \"ON prod.PRODUCT_TYPE_CODE = \"\n + \"prodType.PRODUCT_TYPE_CODE\\n\" \n + \"JOIN GOSALES.ORDER_DETAILS AS orderDet\\n\" \n + \"ON orderDet.PRODUCT_NUMBER = \"\n + \"prod.PRODUCT_NUMBER\\n\" \n + \"WHERE bran.BRANCH_CODE = \"\n + dropBox1.getSelectedItem().toString()\n + \" AND UPPER(prodType.PRODUCT_TYPE_EN) \"\n + \"LIKE UPPER('\"\n + dropBox3.getSelectedItem().toString()\n + \"')\";\n initializeDropBoxes(sql, sqlSelector);\n break;\n \n }\n }", "public void makeSql() {\n\t\tfor(int i=0; i<arr_sql.length; i++) {\n\t\t\tarr_sql[i] = new StringBuffer();\n\t\t}\n\t\t\n\t\t/*\n\t\t * 공통코드 쿼리\n\t\t * 대리점구분 : CU006\n\t\t * 직판구분 : CU012\n\t\t * 지역 : SY006\n\t\t * 계약상태 : CU013\n\t\t * 사용유무 : SY011\n\t\t * 보증보험회사 : CU010\n\t\t * 하위대리점여부 : CU011\n\t\t */\n\t\tarr_sql[0].append (\"SELECT\t\t\t\t\t\t\t\t\t\t\\n\")\n\t\t\t\t .append (\"\t' ' head, ' ' detail, '전체' detail_nm \\n\")\n\t\t\t\t .append (\"FROM DUAL \\n\")\n\t\t\t\t .append (\"UNION ALL \\n\")\n\t\t\t\t .append (\"SELECT \\n\")\n\t\t\t\t .append (\"\tB.head, B.detail, B.detail_nm \\n\")\n\t\t\t\t .append (\"FROM \\n\")\n\t\t\t\t .append (\"\tSALES.TSY011 A, \\n\")\n\t\t\t\t .append (\"\tSALES.TSY010 B \\n\")\n\t\t\t\t .append (\"WHERE 1=1 \\n\")\n\t\t\t\t .append (\" AND A.head = B.head \\n\")\n\t\t\t\t .append (\" AND B.head = ? \\n\")\n\t\t\t\t .append (\" AND LENGTH (rtrim(B.detail)) > 0 \\n\");\n\t\t\n\t\t/*\n\t\t * 대리점 조회\n\t\t */\n\t\tarr_sql[1].append(\"SELECT T1.client_sid\t\t\t \t\t\t\t\t\t\t\t\t\t\t\t\t\\n\")\t/* 매출처SID \t*/\n\t \t\t .append(\"\t\t ,T1.vend_cd \t\t\t\t\t\t\t\t\t\t\t\t \t\t\t\t\\n\")\t/* [회계]거래처 코드 \t*/\n\t \t\t .append(\"\t\t ,T1.client_cd \t\t\t\t\t\t\t\t\t\t\t\t \t\t\t\t\\n\")\t/* 매출처 코드 \t*/\n\t \t\t .append(\"\t\t ,T1.client_nm \t\t\t\t\t\t\t\t\t\t\t\t \t\t\t\t\\n\")\t/* 매출처 명 \t*/\n\t \t\t .append(\"\t\t ,T1.client_gu \t\t\t\t\t\t\t\t\t\t\t\t \t\t\t\t\\n\")\t/* 매출처구분 :CU005 \t*/\n\t \t\t \n\t \t\t .append(\"\t\t ,T1.agen_gu \t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\\n\")\t/* 대리점구분 :CU006 \t*/\n\t \t\t .append(\"\t\t ,T1.dir_yn \t\t\t\t\t\t\t\t\t\t\t\t \t\t\t\t\\n\")\t/* 직판여부 :CU012 \t*/\n\t \t\t .append(\"\t\t ,T1.area_cd \t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\\n\")\t/* 지역코드 :SY006 \t*/\n\t \t\t .append(\"\t\t ,T1.sal_dam_sid \t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\\n\")\t/* 영업담당자코드[TSY410] */\n\t \t\t .append(\"\t\t ,T1.client_dam_nm \t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\\n\")\t/* 매출처담당자 \t*/\n\t \t\t \n\t \t\t .append(\"\t\t ,T1.tel_no \t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\\n\")\t/* 전화번호 \t*/\n\t \t\t .append(\"\t\t ,T1.mobile_no \t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\\n\")\t/* 휴대전화 \t*/\n\t \t\t .append(\"\t\t ,T1.fax_no \t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\\n\")\t/* FAX번호 \t*/\n\t \t\t .append(\"\t\t ,T1.e_mail \t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\\n\")\t/* 이메일 \t*/\n\t \t\t .append(\"\t\t ,T1.zip_cd \t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\\n\")\t/* 우편번호[TSY110] */\n\t \t\t \n\t \t\t .append(\"\t\t ,T1.address1 \t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\\n\")\t/* 주소1 \t*/\n\t \t\t .append(\"\t\t ,T1.address2 \t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\\n\")\t/* 주소2 \t*/\n\t \t\t .append(\"\t\t ,T1.commi_rate \t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\\n\")\t/* 수수료율 \t*/\n\t \t\t .append(\"\t\t ,T1.cunt_status \t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\\n\")\t/* 계약상태 :CU013 \t*/\n\t \t\t .append(\"\t\t ,T1.bancod \t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\\n\")\t/* 은행코드 [BANKCODE] */\n\t \t\t \n\t \t\t .append(\"\t\t ,T1.bank_acc_no \t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\\n\")\t/* 은행계좌번호 \t*/\n\t \t\t .append(\"\t\t ,T1.bank_acct_nm \t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\\n\")\t/* 예금주 \t*/\n\t \t\t .append(\"\t\t ,T1.use_yn \t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\\n\")\t/* 사용여부 :SY011 \t*/ \n\t \t\t .append(\"\t\t ,T1.client_url\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\\n\")\t/* 홈페이지 URL\t\t\t\t*/\n\t \t\t .append(\"\t\t ,T2.sal_dam_nm \t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\\n\")\t/* 영업담당자명 \t*/\n\t \t\t .append(\"\t\t ,T3.vend_nm \t\t\t\t\t\t\t\t\t\t\t\t \t\t\t\t\\n\")\t/* 거래처명 \t*/\n\t \t\t \n\t \t\t .append(\"\t\t ,T4.bannam \t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\\n\")\t/* 은행명 \t*/\n\t \t\t .append(\"\t\t ,SALES.FN_DETAIL_NM ( 'CU006',T1.agen_gu) AS agen_gu_name \t\t\t\t\t\\n\")\t/* 대리점구분명 \t\t\t\t*/ \n\t \t\t .append(\"\t\t ,SALES.FN_DETAIL_NM ( 'CU012',T1.dir_yn) AS dir_yn_name \t\t\t\t\t\\n\")\t/* 직판여부명 \t\t\t\t*/ \n\t \t\t .append(\"\t\t ,SALES.FN_DETAIL_NM ( 'SY006',T1.area_cd) AS area_nm\t\t\t\t\t\t\t\\n\")\t/* 지역명 \t\t\t\t*/\n\t \t\t .append(\"\t\t ,SALES.FN_DETAIL_NM ( 'CU013',T1.cunt_status) AS cunt_status_name \t\t\t\\n\")\t/* 계약상태명 \t\t\t\t*/\n\n\t \t\t .append(\"\t\t ,SALES.FN_DETAIL_NM ( 'SY011',T1.use_yn) AS use_yn_name \t\t\t\\n\")\t/* 사용여부명 \t\t\t \t*/\n\n\t \t\t .append(\"FROM SALES.TCU030 T1 LEFT OUTER JOIN SALES.TSY410 T2 ON T1.SAL_DAM_SID = T2.SAL_DAM_SID \\n\")\n\t \t\t .append(\"\t\t LEFT OUTER JOIN ACCOUNT.GCZM_VENDER T3 ON T1.VEND_CD = T3.VEND_CD \t\t\t\t\t\\n\")\n\t \t\t .append(\"\t\t LEFT OUTER JOIN ACCOUNT.BANKCODE T4 ON T1.BANCOD = T4.BANCOD \t\t\t\t\t\\n\")\n\t \t\t .append(\"WHERE 1 = 1 \t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\\n\")\n\t \t\t .append(\"\t\t AND T1.client_GU = '1' \t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\\n\");\n\t\t/*\n\t\t * 계약정보 조회\n\t\t */\n\t\tarr_sql[2].append(\"SELECT T1.client_sid\t\t\t\t\t\t\t\t\t\t\t\t\\n\")\t/* 매출처SID \t*/\n\t\t\t\t .append(\"\t\t ,T1.cont_date\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\\n\") \t/* 계약일자 \t*/\n\t\t\t\t .append(\"\t\t ,T1.expire_date\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\\n\")\t/* 만기일자 \t*/\n\t\t\t\t .append(\"\t\t ,TO_NUMBER(T1.insur_amt) AS insur_amt\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\\n\")\t/* 보험료 \t*/\n\t\t\t\t .append(\"\t\t ,T1.insur_comp_cd\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\\n\")\t/* 보증보험회사:CU010 \t*/\n\t\t\t\t .append(\"\t\t ,SALES.FN_DETAIL_NM ('CU010',T1.insur_comp_cd) AS insur_comp_cd_name\t\t\\n\") \t/* 보증보험회사명 \t\t*/ \n\t\t\t\t .append(\"FROM SALES.TCU031 T1 \t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\\n\")\n\t\t\t\t .append(\"WHERE 1=1\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\\n\");\n\t\t \n\t\n\t\t/*\n\t\t * 지점정보 조회\n\t\t */\n\t\tarr_sql[3].append(\"SELECT T1.client_sid\t\t\t\t\t\t\t\t\t\t\t\t\\n\") \t/* 매출처SID \t\t*/\n\t\t\t\t .append(\"\t\t ,T1.branch_cd\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\\n\")\t/* 지점코드 \t\t\t*/\n\t\t\t\t .append(\"\t\t ,T1.branch_nm \t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\\n\") \t/* 지점명 \t\t\t*/\n\t\t\t\t .append(\"\t\t ,T1.area_cd\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\\n\") \t/* 지역코드:SY006 \t\t*/\n\t\t\t\t .append(\"\t\t ,T1.client_down_yn \t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\\n\")\t/* 하위대리점여부:CU011 \t*/\n\t\t\t\t .append(\"\t\t ,T1.empno \t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\\n\")\t/* 담당자 \t\t\t*/\n\t\t\t\t .append(\"\t\t ,T1.tel_no \t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\\n\")\t/* 전화번호 \t\t\t*/\n\t\t\t\t .append(\"\t\t ,T1.mobile_no \t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\\n\")\t/* 휴대폰 \t\t\t*/\n\t\t\t\t .append(\"\t\t ,T1.fax_no \t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\\n\")\t/* 팩스번호 \t\t\t*/\n\t\t\t\t .append(\"\t\t ,T1.branch_url \t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\\n\")\t/* 지점홈페이지 \t\t\t*/\n\t\t\t\t .append(\"\t\t ,SALES.FN_DETAIL_NM ( 'SY006', T1.area_cd) AS area_nm\t\t\t\t\t\t\t\\n\") \t/* 지역명:SY006 \t\t*/\n\t\t\t\t .append(\"\t\t ,SALES.FN_DETAIL_NM ( 'CU011',T1.client_down_yn) AS client_down_yn_name \t\\n\")\t/* 하위대리점여부명 \t\t*/\n\t\t\t\t .append(\"FROM SALES.TCU032 T1\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\\n\");\n\t\t\n\t\t\n\t\t/*\n\t\t * 대리점 등록\n\t\t */\n\n\t\tarr_sql[4].append(\"INSERT INTO SALES.TCU030 (\")\n\t\t\t\t .append(\"\t\t\t\t client_sid \\n\")\t\n\t\t\t\t .append(\"\t\t\t\t,vend_cd \\n\")\t/* [회계]거래처 코드 \t*/\n\t\t\t\t .append(\"\t\t\t\t,client_cd \\n\")\t/* 매출처 코드 \t*/\n\t\t\t\t .append(\"\t\t\t\t,client_nm \\n\")\t/* 매출처 명 \t*/\n\t\t\t\t .append(\"\t\t\t\t,client_gu \\n\")\t/* 매출처구분 :CU005 \t*/\n\t\t\t\t .append(\"\t\t\t\t,agen_gu \\n\")\t/* 대리점구분 :CU006 \t*/\n\t\t\t\t \n\t\t\t\t .append(\"\t\t\t\t,dir_yn \\n\")\t/* 직판여부 :CU012 \t*/\n\t\t\t\t .append(\"\t\t\t\t,area_cd \\n\")\t/* 지역코드 :SY006 \t*/\n\t\t\t\t .append(\"\t\t\t\t,sal_dam_sid \\n\")\t/* 영업담당자코드[TSY410] \t*/\n\t\t\t\t .append(\"\t\t\t\t,client_dam_nm \\n\")\t/* 매출처담당자 \t*/\n\t\t\t\t .append(\"\t\t\t\t,tel_no \\n\")\t/* 전화번호 \t*/\n\t\t\t\t \n\t\t\t\t .append(\"\t\t\t\t,mobile_no \\n\")\t/* 핸드폰 \t*/\n\t\t\t\t .append(\"\t\t\t\t,fax_no \\n\")\t/* FAX번호 \t*/\n\t\t\t\t .append(\"\t\t\t\t,e_mail \\n\")\t/* 이메일 \t*/\n\t\t\t\t .append(\"\t\t\t\t,zip_cd \\n\")\t/* 소재지우편번호[TSY110] */\n\t\t\t\t .append(\"\t\t\t\t,address1 \\n\")\t/* 소재지주소1 \t*/\n\t\t\t\t \n\t\t\t\t .append(\"\t\t\t\t,address2 \\n\")\t/* 소재지주소2 \t*/\n\t\t\t\t .append(\"\t\t\t\t,commi_rate \t\\n\") \t/* 수수료율 \t*/\n\t\t\t\t .append(\"\t\t\t\t,cunt_status \\n\")\t/* 계약상태 :CU013 \t*/\n\t\t\t\t .append(\"\t\t\t\t,bancod\t\t\t\\n\") \t/* 은행코드 \t\t\t\t\t*/\n\t\t\t\t .append(\"\t\t\t\t,bank_acc_no \\n\")\t/* 은행계좌번호[BANKCODE] \t*/\n\t\t\t\t \n\t\t\t\t .append(\"\t\t\t\t,bank_acct_nm\t\\n\")\t/* 예금주 \t\t\t\t\t*/\n\t\t\t\t .append(\"\t\t\t\t,use_yn\t\t\t\\n\")\t/* 사용여부 \t\t\t\t\t*/\n\t\t\t\t\n\t\t\t\t .append(\"\t\t \t\t,u_date \t\\n\") \t/* 최종수정일자 \t*/\n\t \t\t .append(\"\t\t \t\t,u_empno \t\\n\")\t/* 최종수정자사번 \t*/\n\t \t\t .append(\"\t\t \t\t,u_ip \\n\")\t/* 최종수정IP */\t\t\t\n\t \t\t .append(\"\t\t\t\t,client_url\t\t\\n\")\t/* 홈페이지 */\n\t\t\t\t .append(\"\t\t\t)\t\t\t\t\t\\n\")\n\t\t\t\t \n\t\t\t\t .append(\"VALUES\t\t\t\t\t\t\\n\")\n\t\t\t\t .append(\"\t\t\t(\t \t\t\t\\n\")\n\t\t\t\t .append(\"\t\t\t\tSALES.SWS_TCU030_ID.NEXTVAL,?,?,?,?,?,\t\t\\n\")\t\n\t\t\t\t .append(\"\t\t\t\t?,?,?,?,?,\t\t\\n\")\n\t\t\t\t .append(\"\t\t\t\t?,?,?,?,?,\t\t\\n\")\n\t\t\t\t .append(\"\t\t\t\t?,?,?,?,?,\t\t\\n\")\n\t\t\t\t .append(\"\t\t\t\t?,?,SYSTIMESTAMP,?,?,?\t\\n\")\n\t\t\t\t .append(\"\t\t\t)\");\n\t\t\n\t\n\t\t\n\t\t/*\n\t\t * 계약정보 등록\n\t\t */\n\t\tarr_sql[5].append(\"INSERT INTO SALES.TCU031 ( \t\\n\")\n\t\t\t\t .append(\" \t client_SID\t\t\t\\n\")\t/* 매출처SID \t*/\n\t\t\t\t .append(\"\t\t ,cont_date\t\t\t\t\\n\") \t/* 계약일자 \t*/\n\t\t\t\t .append(\"\t\t ,expire_date\t\t\t\\n\")\t/* 만기일자 \t*/\n\t\t\t\t .append(\"\t\t ,insur_amt\t\t\t\t\\n\")\t/* 보험료 \t*/\n\t\t\t\t .append(\"\t\t ,insur_comp_cd\t\t\t\\n\")\t/* 보증보험회사:CU010 \t*/\n\t\t\t\t \n\t\t\t\t .append(\"\t\t ,u_date\t\t\t\t\\n\")\t/* 최종수정일자 \t*/\n\t\t\t\t .append(\"\t\t ,u_empno \t\t\t\t\\n\") \t/* 최종수정자사번 \t*/\n\t\t\t\t .append(\"\t\t ,u_ip\t\t\t\t\t\\n\")\t/* 최종수정IP \t*/\n\t\t\t\t .append(\"\t\t)\t\t\t\t\t\t\\n\")\n\t\t\t\t \n\t\t\t\t .append(\"VALUES\t\t\t\t\t\t\\n\")\n\t\t\t\t .append(\"\t\t\t(\t \t\t\t\\n\")\n\t\t\t\t .append(\"\t\t\t\t?,?,?,?,?,\t\t\\n\")\t\n\t\t\t\t .append(\"\t\t\t\tSYSTIMESTAMP,?,?\t\t\t\\n\")\n\t\t\t\t .append(\"\t\t\t)\");\n\t\t\t\t\t\n\t\t/*\n\t\t * 지점정보 등록\n\t\t */\n\t\t\n\t\tarr_sql[6].append(\"INSERT INTO SALES.TCU032 ( \t\\n\")\n\t\t\t\t .append(\"\t\t client_SID\t\t\t\\n\") \t/* 매출처SID \t\t*/\n\t\t\t\t .append(\"\t\t ,branch_cd\t\t\t\t\\n\")\t/* 지점코드 \t\t\t*/\n\t\t\t\t .append(\"\t\t ,branch_nm \t\t\t\\n\") \t/* 지점명 \t\t\t*/\n\t\t\t\t .append(\"\t\t ,area_cd\t\t\t\t\\n\") \t/* 지역코드:SY006 \t\t*/\n\t\t\t\t .append(\"\t\t ,client_down_yn \t\t\\n\")\t/* 하위대리점여부:CU011 \t*/\n\t\t\t\t \n\t\t\t\t .append(\"\t\t ,empno \t\t\t\t\\n\")\t/* 담당자 \t\t\t*/\n\t\t\t\t .append(\"\t\t ,tel_no \t\t\t\t\\n\")\t/* 전화번호 \t\t\t*/\n\t\t\t\t .append(\"\t\t ,mobile_no \t\t\t\\n\")\t/* 휴대폰 \t\t\t*/\n\t\t\t\t .append(\"\t\t ,fax_no \t\t\t\t\\n\")\t/* 팩스번호 \t\t\t*/\n\t\t\t\t .append(\"\t\t ,branch_url \t\t\t\\n\")\t/* 지점홈페이지 \t\t\t*/\n\t\t\t\t \n\t\t\t\t .append(\"\t\t ,u_date \t\t\t\t\\n\")\t/* 최종수정일자 \t\t\t*/\n\t\t\t\t .append(\"\t\t ,u_empno \t\t\t\t\\n\")\t/* 최종수정자사번 \t\t\t*/\n\t\t\t\t .append(\"\t\t ,u_ip \t\t\t\t\\n\")\t/* 최종수정IP \t\t*/\n\t\t\t\t .append(\"\t)\t\t\t\t\t\t\\n\")\n\t\t\t\t .append(\"VALUES\t\t\t\t\t\t\\n\")\n\t\t\t\t .append(\"\t\t\t(\t \t\t\t\\n\")\n\t\t\t\t .append(\"\t\t\t\t?,?,?,?,?,\t\t\\n\")\t\n\t\t\t\t .append(\"\t\t\t\t?,?,?,?,?,\t\t\\n\")\n\t\t\t\t .append(\"\t\t\t\tSYSTIMESTAMP,?,?\t\t\t\\n\")\n\t\t\t\t .append(\"\t\t\t)\");\n\t\t\n\t\t/*\n\t\t * 대리점 수정\n\t\t */\n\n\t\tarr_sql[7].append(\"UPDATE SALES.TCU030 SET \t\t\t\t\t\t\\n\")\n\t\t\t\t .append(\"\t\t vend_cd\t\t= ? \t\t\t\t\\n\")\t/* [회계]거래처 코드 \t*/\n\t\t\t\t .append(\"\t\t,client_nm\t\t= ? \t\t\t\t\\n\")\t/* 매출처 명 \t*/\n\t\t\t\t .append(\"\t\t,agen_gu\t\t= ? \t\t\t\t \t\\n\")\t/* 대리점구분 :CU006 \t*/\n\t\t\t\t .append(\"\t\t,dir_yn\t\t\t= ? \t\t\t\t\\n\")\t/* 직판여부 :CU012 \t*/\n\t\t\t\t .append(\"\t\t,area_cd \t= ? \t\t\t\t\t\\n\")\t/* 지역코드 :SY006 \t*/\n\n\t\t\t\t .append(\"\t\t,sal_dam_sid\t= ? \t\t\t\t\t\\n\")\t/* 영업담당자코드[TSY410] */\n\t\t\t\t .append(\"\t\t,client_dam_nm\t= ? \t\t\t\t\t\\n\")\t/* 매출처담당자 \t*/\n\t\t\t\t .append(\"\t\t,tel_no = ?\t\t\t\t\t\t\\n\")\t/* 전화번호 \t*/\n\t\t\t\t .append(\"\t\t,mobile_no = ?\t\t\t\t\t\t\\n\")\t/* 핸드폰 \t*/\n\t\t\t\t .append(\"\t\t,fax_no = ?\t\t\t\t\t\t\\n\")\t/* FAX번호 \t*/\n\n\t\t\t\t .append(\"\t\t,e_mail = ?\t\t\t\t\t\t\\n\")\t/* 이메일 \t*/\n\t\t\t\t .append(\"\t\t,zip_cd = ?\t\t\t\t\t\t\\n\")\t/* 소재지우편번호[TSY110] \t*/\n\t\t\t\t .append(\"\t\t,address1 = ?\t\t\t\t\t\t\\n\")\t/* 소재지주소1 \t*/\n\t\t\t\t .append(\"\t\t,address2 = ?\t\t\t\t\t\t\\n\")\t/* 소재지주소2 \t*/\n\t\t\t\t .append(\"\t\t,commi_rate \t= ?\t\t\t\t\t\t\\n\") \t/* 수수료율 \t*/\n\n\t\t\t\t .append(\"\t\t,cunt_status = ?\t\t\t\t\t\t\\n\")\t/* 계약상태 :CU013 \t*/\n\t\t\t\t .append(\"\t\t,bancod\t\t\t= ?\t\t\t\t\t\t\\n\") \t/* 은행코드\t \t\t\t\t*/\n\t\t\t\t .append(\"\t\t,bank_acc_no = ?\t\t\t\t\t\t\\n\")\t/* 은행계좌번호[BANKCODE]\t\t*/\n\t\t\t\t .append(\"\t\t,bank_acct_nm\t= ?\t\t\t\t\t\t\\n\")\t/* 예금주 \t\t\t\t\t*/\n\t\t\t\t .append(\"\t\t,use_yn\t\t\t= ?\t\t\t\t\t\t\\n\")\t/* 사용여부 \t\t\t\t\t*/\n\n\t\t\t\t .append(\"\t\t,u_date \t= SYSTIMESTAMP\t\t\\n\") \t/* 최종수정일자 \t*/\n\t \t\t .append(\"\t\t,u_empno \t= ?\t\t\t\t\t\t\\n\")\t/* 최종수정자사번 \t*/\n\t \t\t .append(\"\t\t,u_ip = ?\t\t\t\t\t\t\\n\")\t/* 최종수정IP */\n\t \t\t .append(\"\t,client_url = ?\t\t\t\t\t\t\\n\")\t/* 홈페이지 */\n\t\t\t\t .append (\"WHERE client_sid \t= ? \t\t\t\t\\n\");\n\t\t\t\t \n\t\t/*\n\t\t * 계약정보 수정\n\t\t */\n\t\tarr_sql[8].append(\"UPDATE SALES.TCU031 SET\t\t\t\t\t\t\\n\")\n\t\t\t\t .append(\"\t\t cont_date\t\t\t= ?\t\t\t\t\t\\n\") \t/* 계약일자 \t*/\n\t\t\t\t .append(\"\t\t ,expire_date\t\t= ?\t\t\t\t\t\\n\")\t/* 만기일자 \t*/\n\t\t\t\t .append(\"\t\t ,insur_amt\t\t\t= ?\t\t\t\t\t\\n\")\t/* 보험료 \t*/\n\t\t\t\t .append(\"\t\t ,insur_comp_cd\t\t= ?\t\t\t\t\t\\n\")\t/* 보증보험회사:CU010 \t*/\n\t\t\t\t \n\t\t\t\t .append(\"\t\t ,u_date\t\t\t= SYSTIMESTAMP\t\\n\")\t/* 최종수정일자 \t*/\n\t\t\t\t .append(\"\t\t ,u_empno \t\t\t= ?\t\t\t\t\t\\n\") \t/* 최종수정자사번 \t*/\n\t\t\t\t .append(\"\t\t ,u_ip\t\t\t\t= ?\t\t\t\t\t\\n\")\t/* 최종수정IP \t*/\n\t\t\t\t .append (\"WHERE client_sid \t\t= ? AND cont_date = ? \\n\");\n\t\t\t\t\n\t\t\t\t \n\t\t\t\t\t\n\t\t/*\n\t\t * 지점정보 수정\n\t\t */\n\t\t\n\t\tarr_sql[9].append(\"UPDATE SALES.TCU032 SET \t\t\t\t\t\t\t\\n\")\n\t\t\t\t .append(\"\t\t branch_nm \t\t= ?\t\t\t\t\t\t\\n\") \t/* 지점명 \t\t\t*/\n\t\t\t\t .append(\"\t\t ,area_cd\t\t\t= ?\t\t\t\t\t\t\\n\") \t/* 지역코드:SY006 \t\t*/\n\t\t\t\t .append(\"\t\t ,client_down_yn \t= ?\t\t\t\t\t\t\\n\")\t/* 하위대리점여부:CU011 \t*/\n\t\t\t\t \n\t\t\t\t .append(\"\t\t ,empno \t\t\t= ?\t\t\t\t\t\t\\n\")\t/* 담당자 \t\t\t*/\n\t\t\t\t .append(\"\t\t ,tel_no \t\t\t= ?\t\t\t\t\t\t\\n\")\t/* 전화번호 \t\t\t*/\n\t\t\t\t .append(\"\t\t ,mobile_no \t\t= ?\t\t\t\t\t\t\\n\")\t/* 휴대폰 \t\t\t*/\n\t\t\t\t .append(\"\t\t ,fax_no \t\t\t= ?\t\t\t\t\t\t\\n\")\t/* 팩스번호 \t\t\t*/\n\t\t\t\t .append(\"\t\t ,branch_url \t\t= ?\t\t\t\t\t\t\\n\")\t/* 지점홈페이지 \t\t\t*/\n\t\t\t\t \n\t\t\t\t .append(\"\t\t ,u_date \t\t\t= SYSTIMESTAMP\t\t\t\t\t\t\\n\")\t/* 최종수정일자 \t\t\t*/\n\t\t\t\t .append(\"\t\t ,u_empno \t\t\t= ?\t\t\\n\")\t/* 최종수정자사번 \t\t\t*/\n\t\t\t\t .append(\"\t\t ,u_ip \t\t\t= ?\t\t\t\t\t\t\\n\")\t/* 최종수정IP \t\t*/\n\t\t\t\t .append (\"WHERE client_sid = ? AND branch_cd \t= ?\t\t\\n\");\n\t\t\n\t\t arr_sql[10].append(\"DELETE FROM SALES.TCU030 WHERE client_sid = ?\");\t\n\t\t arr_sql[11].append(\"DELETE FROM SALES.TCU031 WHERE client_sid = ? AND cont_date = ?\");\n\t\t arr_sql[12].append(\"DELETE FROM SALES.TCU032 WHERE client_sid = ? AND branch_cd = ?\");\n\t\t \n\t\t \n\t\t /*\n\t\t * Client SID 얻어오기\n\t\t */\n\t\t\t\n\t\t\tarr_sql[13].append(\"SELECT client_sid FROM SALES.TCU030 WHERE client_cd = ?\\n\");\n\t\t\t\n\t\t/*\n\t\t * 수수료율 조회\n\t\t */\n\t\t\tarr_sql[14].append(\"SELECT\t\t\t\t\t\t\t\t\\n\")\n\t\t\t\t\t\t.append(\" T1.CLIENT_SID AS CLIENT_SID\t\\n\") /* 매출처SID */\n\t\t\t\t\t\t.append(\" ,T1.FR_DATE AS FR_DATE \t\\n\") /* 시작일자 */\n\t\t\t\t\t\t.append(\" ,T1.TO_DATE AS TO_DATE \t\\n\") /* 종료일자 */\n\t\t\t\t\t\t.append(\" ,T1.WEEKEND_YN AS WEEKEND_YN \t\\n\") /* 주말여부 */\n\t\t\t\t\t\t.append(\" ,T1.COMMI_RATE AS COMMI_RATE\t\\n\") /* 수수료율 */\n\t\t\t\t\t\t.append(\"FROM SALES.TCU033 T1 \t\\n\")\n\t\t\t\t\t\t.append(\"WHERE 1=1 \t\t\t\t\t\t\t\\n\");\n\t\t\t\t\t\t\n\t\t/*\n\t\t * 수수료율 등록\n\t\t */\n\t\t\t\n\t\t\tarr_sql[15].append(\"INSERT INTO SALES.TCU033 ( \t\\n\")\n\t\t\t\t\t\t .append(\" \t CLIENT_SID\t\t\t\\n\")\t/* 매출처SID \t*/\n\t\t\t\t\t\t .append(\"\t\t ,FR_DATE\t\t\t\t\\n\") \t/* 시작일자 \t*/\n\t\t\t\t\t\t .append(\"\t\t ,TO_DATE\t\t\t\\n\")\t/* 종료일자 \t*/\n\t\t\t\t\t\t .append(\"\t\t ,COMMI_RATE\t\t\t\t\\n\")\t/* 수수료율 \t*/\n\t\t\t\t\t\t .append(\"\t\t ,WEEKEND_YN\t\t\t\\n\")\t/* 주말여부 \t*/\n\t\t\t\t\t\t .append(\"\t\t ,I_DATE\t\t\t\t\\n\")\t/* 최종입력일자 \t*/\n\t\t\t\t\t\t .append(\"\t\t ,I_EMPNO \t\t\t\t\\n\") \t/* 최종입력자사번 \t*/\n\t\t\t\t\t\t .append(\"\t\t ,I_IP\t\t\t\t\t\\n\")\t/* 최종입력IP \t*/\t\t\t\t\t\t \n\t\t\t\t\t\t .append(\"\t\t ,u_date\t\t\t\t\\n\")\t/* 최종수정일자 \t*/\n\t\t\t\t\t\t .append(\"\t\t ,u_empno \t\t\t\t\\n\") \t/* 최종수정자사번 \t*/\n\t\t\t\t\t\t .append(\"\t\t ,u_ip\t\t\t\t\t\\n\")\t/* 최종수정IP \t*/\n\t\t\t\t\t\t .append(\"\t\t)\t\t\t\t\t\t\\n\")\n\t\t\t\t\t\t \n\t\t\t\t\t\t .append(\"VALUES\t\t\t\t\t\t\\n\")\n\t\t\t\t\t\t .append(\"\t\t\t(\t \t\t\t\\n\")\n\t\t\t\t\t\t .append(\"\t\t\t\t?,?,?,?, ?,\t\t\\n\")\t\n\t\t\t\t\t\t .append(\"\t\t\t\tSYSTIMESTAMP,?,?, SYSTIMESTAMP,?,?\t\\n\")\n\t\t\t\t\t\t .append(\"\t\t\t)\");\n\t\t/*\n\t\t * 수수료율 수정\n\t\t */\n\t\t\tarr_sql[16].append(\"UPDATE SALES.TCU033 SET\t\t\t\t\t\t\\n\") \n\t\t\t\t\t .append(\"\t\t TO_DATE\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\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t .append(\"\t\t ,COMMI_RATE\t\t= ?\t\t\t\t\t\\n\")\t/* 수수료율 \t*/\n\t\t\t\t\t .append(\"\t\t ,WEEKEND_YN\t\t= ?\t\t\t\t\t\\n\")\t/* 주말여부 \t*/\n\t\t\t\t\t \n\t\t\t\t\t \t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t .append(\"\t\t ,u_date\t\t\t= SYSTIMESTAMP\t\\n\")\t/* 최종수정일자 \t*/\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t .append(\"\t\t ,u_empno \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\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t .append(\"\t\t ,u_ip\t\t\t\t= ?\t\t\t\t\t\\n\")\t/* 최종수정IP \t*/\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t .append (\"WHERE client_sid \t\t= ? AND FR_DATE = ? AND WEEKEND_YN=? \\n\"); \n\t\t/*\n\t\t * 수수료율 삭제\n\t\t */\n\t\tarr_sql[17].append(\"DELETE FROM SALES.TCU033 WHERE client_sid = ? AND fr_date = ? AND WEEKEND_YN=? \");\t \n\t\t\t \n\n\t}", "public PreparedSql generatePreparedSql(BoundString prefix);", "public Builder() {\n\t\t}", "public static Builder create() {\n\t\treturn new Builder();\n\t}", "public static Builder create() {\n\t\treturn new Builder();\n\t}", "protected void setupCurrentSqlExp(StringBuilder sb, RomanticTransaction tx) {\n final TransactionCurrentSqlBuilder currentSqlBuilder = tx.getCurrentSqlBuilder();\n if (currentSqlBuilder != null) {\n final String currentSql = currentSqlBuilder.buildSql();\n sb.append(\"\\n/- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -\");\n sb.append(\" (SQL now: \");\n sb.append(tx.getCurrentTableName()).append(\"@\").append(tx.getCurrentCommand());\n final Long currentSqlBeginMillis = tx.getCurrentSqlBeginMillis();\n if (currentSqlBeginMillis != null) {\n sb.append(\" [\").append(tx.buildElapsedTimeExp(currentSqlBeginMillis)).append(\"]\");\n }\n sb.append(\")\\n\");\n sb.append(currentSql);\n sb.append(\"\\n- - - - - - - - - -/\");\n }\n }", "public PreparedSql generatePreparedSql(String prefix);", "@Nonnull\n public static UBL23WriterBuilder <WeightStatementType> weightStatement ()\n {\n return UBL23WriterBuilder.create (WeightStatementType.class);\n }", "public StatementQueryMechanism(DatabaseQuery query, SQLStatement statement) {\n super(query);\n this.sqlStatement = statement;\n }", "PreparedStatement createPreparedStatement(final Connection con, final long offset, final long recordCount)\n throws SQLException;", "private Builder() {\n super(org.apache.gora.cascading.test.storage.TestRow.SCHEMA$);\n }" ]
[ "0.6421838", "0.63008946", "0.63008946", "0.63008946", "0.61875194", "0.6052047", "0.5763112", "0.5604799", "0.55950266", "0.55506414", "0.55282205", "0.5503613", "0.54414064", "0.53896075", "0.53728116", "0.5360877", "0.52928233", "0.5284434", "0.52541524", "0.52463615", "0.5241616", "0.52345514", "0.52339125", "0.5202988", "0.5155989", "0.5155989", "0.5155989", "0.5155989", "0.5155989", "0.5155989", "0.5155989", "0.5155989", "0.5155989", "0.5155989", "0.5155989", "0.5155989", "0.5155989", "0.5155989", "0.5155989", "0.5155989", "0.5155989", "0.5155989", "0.5155989", "0.5155989", "0.51395786", "0.51266843", "0.50953466", "0.50901496", "0.5089712", "0.50781447", "0.507535", "0.507236", "0.50713384", "0.5066987", "0.50628", "0.5056611", "0.5050595", "0.5037847", "0.5037847", "0.5037847", "0.5037685", "0.5028147", "0.50208306", "0.5011414", "0.500144", "0.500144", "0.500144", "0.500144", "0.500144", "0.500144", "0.500144", "0.49899152", "0.49780208", "0.49766245", "0.4976205", "0.4970452", "0.4970452", "0.4970452", "0.4963838", "0.49582934", "0.49503702", "0.49501184", "0.49471897", "0.49412355", "0.4939206", "0.4938253", "0.4934265", "0.4934217", "0.49338987", "0.49190718", "0.49153298", "0.4913466", "0.4910211", "0.49028766", "0.49028766", "0.48986837", "0.48923758", "0.48918447", "0.48891917", "0.4888539", "0.48791403" ]
0.0
-1
Generates EODPosition with Delta values
private Map<String, ArrayList<EODPosition>> generateOutput(Map<SODPosition, Integer> sodPositionsWithDelta) { Map<String, ArrayList<EODPosition>> output = new HashMap<>(); for (Map.Entry<SODPosition, Integer> entry : sodPositionsWithDelta.entrySet()) { SODPosition position = entry.getKey(); if (output.containsKey(position.getInstrument())) { output.get(position.getInstrument()).add(new EODPosition(position.getInstrument(), position.getAccount(), position.getAccountType(), position.getQuantity(), entry.getValue())); } else { output.put(position.getInstrument(), Lists.newArrayList(new EODPosition(position.getInstrument(), position.getAccount(), position.getAccountType(), position.getQuantity(), entry.getValue()))); } } return output; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "int getDelta();", "public double getDelta() {\n return delta;\n }", "public int getDelta() {\n return delta_;\n }", "public double getDelta() {\r\n return delta;\r\n }", "public int getDelta() {\n return delta_;\n }", "Position_ordonnee createPosition_ordonnee();", "static TermVectorPosition of(int pos, PostingsEnum pe) throws IOException {\n Objects.requireNonNull(pe);\n\n int sOffset = pe.startOffset();\n int eOffset = pe.endOffset();\n if (sOffset >= 0 && eOffset >= 0) {\n return new TermVectorPosition(pos, sOffset, eOffset);\n }\n return new TermVectorPosition(pos);\n }", "int getDelta() {\n return delta;\n }", "Offset createOffset();", "public void update(long delta){\n \n if(placement <= -1000){\n placement = zPosition;\n }\n placement -= 5;\n \n \n }", "public String toString() {\n\t\treturn \"PoseDelta<\" + this.angleDelta + \", \" + this.distanceDelta + \">\"; \n\t}", "@Test\n public void testValladoTEMEofDate() {\n AbsoluteDate t0 = new AbsoluteDate(new DateComponents(2000, 182),\n new TimeComponents(0.78495062 * Constants.JULIAN_DAY),\n TimeScalesFactory.getUTC());\n\n // TEME\n PVCoordinates pvTEME =\n new PVCoordinates(new Vector3D(-9060473.73569, 4658709.52502, 813686.73153),\n new Vector3D(-2232.832783, -4110.453490, -3157.345433));\n\n // reference position in EME2000\n // note that Valado's book gives\n // PVCoordinates pvEME2000Ref =\n // new PVCoordinates(new Vector3D(-9059941.3786, 4659697.2000, 813958.8875),\n // new Vector3D(-2233.348094, -4110.136162, -3157.394074));\n // the values we use here are slightly different, they were computed using\n // Vallado's C++ companion code to the book, using the teme_j2k function with\n // all 106 nutation terms and the 2 corrections elements of the equation of the equinoxes\n PVCoordinates pvEME2000Ref =\n new PVCoordinates(new Vector3D(-9059941.5224999374914, 4659697.1225837596648, 813957.72947647583351),\n new Vector3D(-2233.3476939179299769, -4110.1362849403413335, -3157.3941963060194738));\n\n Transform t = FramesFactory.getTEME().getTransformTo(FramesFactory.getEME2000(), t0);\n\n PVCoordinates pvEME2000Computed = t.transformPVCoordinates(pvTEME);\n PVCoordinates delta = new PVCoordinates(pvEME2000Computed, pvEME2000Ref);\n Assertions.assertEquals(0.0, delta.getPosition().getNorm(), 0.025);\n Assertions.assertEquals(0.0, delta.getVelocity().getNorm(), 1.0e-4);\n\n }", "private static double calculatePosition(double position, double deltaT, double velocity) {\n return position + (deltaT * velocity);\n }", "Position createPosition();", "public static double getDelta()\n\t{\n\t\treturn delta;\n\t}", "public Vec2f getDelta() {\n\t\treturn new Vec2f(_dx, _dy);\n\t}", "public float getDelta() {\n\t\treturn delta;\n\t}", "Ogre(int xPos, int yPos, String color,int deltaX,int deltaY) {\n this.xPos = xPos;\n this.yPos = yPos;\n this.color = color;\n this.deltaX = deltaX;\n this.deltaY = deltaY;\n }", "private static Vector3f[] calculatePositionDifferences(Drone drone, Vector3f[] newVelocities, float dt) {\r\n\r\n\t\t\r\n\t\t// calculate the average linear velocity\r\n\t\tVector3f avgLinearVelocityW = average(drone.getLinearVelocity(), newVelocities[0]);\r\n\r\n\t\t// calculate the translation\r\n\t\tVector3f deltaPositionW = (Vector3f) avgLinearVelocityW.scale(dt);\r\n\r\n\t\t// calculate the average angular velocity\r\n\t\tVector3f avgAngularVelocityW = average(drone.getAngularVelocity(), newVelocities[1]);\r\n\r\n\t\t// calculate the rotation\r\n\t\tVector3f deltarotationW = ((Vector3f) avgAngularVelocityW.scale(dt));\r\n\r\n\t\treturn new Vector3f[] { deltaPositionW, deltarotationW };\r\n\t}", "Position_Position createPosition_Position();", "public int getDeltaT() {\n return deltaT;\n }", "public void setDelta(float delta) {\n\t\tthis.delta = delta;\n\t}", "public String toString() {\n\t\treturn \"[\" + deltaX + \", \" + deltaY + \"]\";\n\t}", "public void setDelta(double value) {\r\n this.delta = value;\r\n }", "DVector3C getOffsetPosition();", "public AdaDelta() {\n this(0.95,1e-6);\n }", "Vaisseau_positionner createVaisseau_positionner();", "@Override\n\t\t\tpublic Vector getPosition() {\n\t\t\t\treturn new Vector(-2709.487, -4281.02, 3861.564); //-4409.0, 2102.0, -4651.0);\n\t\t\t}", "Position getNewPosition();", "private void updateDelta() {\n\t\tbulletDelta = Delta.getDelta(\"bullet\");\n\t\tenemyDelta = Delta.getDelta(\"enemy\");\n\t}", "public int getDelta() {\n return parameter.getDelta();\n }", "public float particleOffset(int axis);", "public Document decoratePosition (Document parseTree);", "public Point getDelta()\n {\n return this.getPosition().subtract(this.getInitialPosition());\n }", "DVector3C getPosition();", "int getDeltaX() {\n return deltaX;\n }", "@Override\n public void update(float delta) {\n // Make sure to COPY the vector and not copy the reference\n position = new Vector3f(entity.getPosition()).add(offset);\n }", "Vaisseau_occupeLaPosition createVaisseau_occupeLaPosition();", "public void deltaMove(Point delta){\n originPoint.x += delta.x;\n originPoint.y += delta.y;\n endPoint.x += delta.x;\n endPoint.y += delta.y;\n }", "void copyOffsetPosition (DVector3 pos);", "public void setDeltaT(int value) {\n this.deltaT = value;\n }", "@Test\n public void testDelta() throws Exception\n {\n Cluster cluster = CacheFactory.ensureCluster();\n\n DeltaData[] aData = configDelta(cluster);\n\n String outputDir = m_temporaryFolder.newFolder().getCanonicalPath();\n \n String sReport = \"unit-test-delta.xml\";\n String sOutput = outputDir + File.separator + \"unit-test-delta.txt\";\n String sValidate = \"./unit-test-delta-base.txt\";\n String sError = \"Incorrect Delta calculations\";\n\n deleteFile(sOutput);\n\n Reporter reporter = new Reporter();\n reporter.run(sReport, outputDir + File.separator, 1, null);\n\n updateData(aData);\n\n reporter.run(sReport, outputDir + File.separator, 2, null);\n\n updateData(aData);\n\n reporter.run(sReport, outputDir + File.separator, 3, null);\n\n assertTrue(sError, compareFiles(sOutput, sValidate));\n }", "private Position createPosition(final int offset)\n throws BadLocationException {\n return component.getDocument().createPosition(offset);\n }", "@Override\n public double getPosition()\n {\n final String funcName = \"getPosition\";\n double pos = getMotorPosition() - zeroPosition;\n\n if (debugEnabled)\n {\n dbgTrace.traceEnter(funcName, TrcDbgTrace.TraceLevel.API);\n dbgTrace.traceExit(funcName, TrcDbgTrace.TraceLevel.API, \"=%f\", pos);\n }\n\n return pos;\n }", "public POS(int position) {\n \t\tthis.position = position;\n \t}", "@Override\n\tpublic void posModify() {\n\t\t\n\t}", "@Override\n\tpublic void posModify() {\n\t\t\n\t}", "public void AdvancePos() {\n \tswitch (data3d.TrackDirection){\n \tcase 0:\n \tc2.PositionValue += 1;\n \tc2.PositionValue = (c2.PositionValue % c2.getMaxPos());\n \tbreak;\n \tcase 1:\n \tc3.PositionValue += 1;\n \tc3.PositionValue = (c3.PositionValue % c3.getMaxPos());\n \tbreak;\n \tcase 2:\n \tc1.PositionValue += 1;\n \tc1.PositionValue = (c1.PositionValue % c1.getMaxPos());\n \tbreak;\n \tcase 3:\n \tdata3d.setElement((data3d.ActiveElement + 1) % data3d.Elements);\n \tcase 4:\n \tdata3d.setTime((data3d.ActiveTime + 1) % data3d.Times);\n \t}\n }", "public Builder setDelta(int value) {\n \n delta_ = value;\n onChanged();\n return this;\n }", "@Override\n public void delta() {\n \n }", "Position_changerAbscisse createPosition_changerAbscisse();", "public double getDeltaX() {\n return deltaX;\n }", "public EntityDataParticle() {\n\t\tm_speed=0.5f;\n\t\tm_rotation=0;\n\t\tm_duration=0.5f;\n\t\tm_type=0;\n\t}", "@Test\n\tpublic void simpleAdvances() {\n\t\tmodel.addParticle(new Vector(300, 300), 1.0, new Vector(), 10.0);\n\t\tmodel.advance();\n\t\t//StdOut.println(\"\" + model.getParticleAt(0).getPosition().toString());\n\t}", "Object getPosition();", "public int getOlddeltaT() {\n return olddeltaT;\n }", "public double getAbsPosition() {\n double distCM = ToFSerial.get() - startDist;\n //System.out.println(\"Dist in CM \" + distCM);\n\n double distIn = distCM * Constants.k_CMtoIn;\n //System.out.println(\"Dist in In \" + distIn);\n\n return (int) (1000 * distIn); \n\n }", "@Override\n\tpublic int getPos() {\n\t\treturn 0;\n\t}", "com.google.ortools.linearsolver.MPModelDeltaProto getModelDelta();", "public Coordinate generatePosition() {\n Random rng = new Random();\n return new Coordinate(rng.nextFloat(), rng.nextFloat());\n }", "private static synchronized double calc_deltaT(double tjd) {\n\t\tdouble ans = 0;\n\t\tdouble B, Y, Ygreg, dd;\n\t\tint iy;\n\t\tint deltat_model = sw.swed.astro_models[SweConst.SE_MODEL_DELTAT];\n\t\tif (deltat_model == 0)\n\t\t\tdeltat_model = SweConst.SEMOD_DELTAT_DEFAULT;\n\t\t/* read additional values from swedelta.txt */\n\t\t/* AS_BOOL use_espenak_meeus = DELTAT_ESPENAK_MEEUS_2006; */\n\t\tY = 2000.0 + (tjd - SwephData.J2000) / 365.25;\n\t\tYgreg = 2000.0 + (tjd - SwephData.J2000) / 365.2425;\n\t\t/*\n\t\t * Before 1633 AD, if the macro DELTAT_ESPENAK_MEEUS_2006 is TRUE:\n\t\t * Polynomials by Espenak & Meeus 2006, derived from Stephenson &\n\t\t * Morrison 2004. Note, Espenak & Meeus use their formulae only from\n\t\t * 2000 BC on. However, they use the long-term formula of Morrison &\n\t\t * Stephenson, which can be used even for the remoter past.\n\t\t */\n\t\t/* if (use_espenak_meeus && tjd < 2317746.13090277789) { */\n\t\tif (deltat_model == SweConst.SEMOD_DELTAT_ESPENAK_MEEUS_2006 && tjd < 2317746.13090277789) {\n\t\t\treturn deltat_espenak_meeus_1620(tjd);\n\t\t}\n\t\t/*\n\t\t * If the macro DELTAT_ESPENAK_MEEUS_2006 is FALSE: Before 1620, we\n\t\t * follow Stephenson & Morrsion 2004. For the tabulated values 1000 BC\n\t\t * through 1600 AD, we use linear interpolation.\n\t\t */\n\t\tif (Y < TABSTART) {\n\t\t\tif (Y < TAB2_END) {\n\t\t\t\treturn deltat_stephenson_morrison_1600(tjd);\n\t\t\t} else {\n\t\t\t\t/*\n\t\t\t\t * between 1600 and 1620: linear interpolation between end of\n\t\t\t\t * table dt2 and start of table dt\n\t\t\t\t */\n\t\t\t\tif (Y >= TAB2_END) {\n\t\t\t\t\tB = TABSTART - TAB2_END;\n\t\t\t\t\tiy = (TAB2_END - TAB2_START) / TAB2_STEP;\n\t\t\t\t\tdd = (Y - TAB2_END) / B;\n\t\t\t\t\t/* ans = dt2[iy] + dd * (dt[0] / 100.0 - dt2[iy]); */\n\t\t\t\t\tans = dt2[iy] + dd * (dt[0] - dt2[iy]);\n\t\t\t\t\tans = adjust_for_tidacc(ans, Ygreg);\n\t\t\t\t\treturn ans / 86400.0;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t/*\n\t\t * 1620 - today + a few years (tabend): Besselian interpolation from\n\t\t * tabulated values in table dt. See AA page K11.\n\t\t */\n\t\tif (Y >= TABSTART) {\n\t\t\treturn deltat_aa(tjd);\n\t\t}\n\t\treturn ans / 86400.0;\n\t}", "Position_abscisse createPosition_abscisse();", "private void updatePosition() {\n\t\tfor (int i = 0; i < encoders.length; i++) {\n\t\t\tdRot[i] = (encoders[i].get() - lastEncPos[i]) / this.cyclesPerRev;\n\t\t\tdPos[i] = dRot[i] * wheelDiameter * Math.PI;\n\t\t\tlastEncPos[i] = encoders[i].get();\n\t\t}\n\t\t\n\t\tdLinearPos = (dPos[0] + dPos[1]) / 2;\n\t\t\n\t\tposition[2] = Math.toRadians(gyro.getAngle()) + gyroOffset;\n\t\tposition[0] += dLinearPos * Math.sin(position[2]);\n\t\tposition[1] += dLinearPos * Math.cos(position[2]);\n\t}", "public double getDeltaX() {\n return deltaX;\n }", "public double getDeltaX() {\n return deltaX;\n }", "public Position origin(Position ep) throws InvalidPositionException;", "public DetonationPdu(edu.nps.moves.jaxb.dis.DetonationPdu x)\n {\n super(x); // Call superclass constructor\n\n\n edu.nps.moves.dis.EntityID foo_0;\n if(x.getMunitionID() == null)\n foo_0 = new edu.nps.moves.dis.EntityID();\n else\n foo_0 = new edu.nps.moves.dis.EntityID(x.getMunitionID() );\n this.setMunitionID(foo_0);\n\n\n edu.nps.moves.dis.EventID foo_1;\n if(x.getEventID() == null)\n foo_1 = new edu.nps.moves.dis.EventID();\n else\n foo_1 = new edu.nps.moves.dis.EventID(x.getEventID() );\n this.setEventID(foo_1);\n\n\n edu.nps.moves.dis.Vector3Float foo_2;\n if(x.getVelocity() == null)\n foo_2 = new edu.nps.moves.dis.Vector3Float();\n else\n foo_2 = new edu.nps.moves.dis.Vector3Float(x.getVelocity() );\n this.setVelocity(foo_2);\n\n\n edu.nps.moves.dis.Vector3Double foo_3;\n if(x.getLocationInWorldCoordinates() == null)\n foo_3 = new edu.nps.moves.dis.Vector3Double();\n else\n foo_3 = new edu.nps.moves.dis.Vector3Double(x.getLocationInWorldCoordinates() );\n this.setLocationInWorldCoordinates(foo_3);\n\n\n edu.nps.moves.dis.BurstDescriptor foo_4;\n if(x.getBurstDescriptor() == null)\n foo_4 = new edu.nps.moves.dis.BurstDescriptor();\n else\n foo_4 = new edu.nps.moves.dis.BurstDescriptor(x.getBurstDescriptor() );\n this.setBurstDescriptor(foo_4);\n\n this.detonationResult = x.getDetonationResult();\n this.numberOfArticulationParameters = x.getNumberOfArticulationParameters();\n this.pad = x.getPad();\n this.articulationParameters = new ArrayList();\n for(int idx = 0; idx < x.getArticulationParameters().size(); idx++)\n {\n this.articulationParameters.add( new edu.nps.moves.dis.ArticulationParameter((edu.nps.moves.jaxb.dis.ArticulationParameter) x.getArticulationParameters().get(idx)));\n }\n }", "public void EulerNextPos(Body[] bodies, int dt) {\n double ax = 0;\n double ay = 0;\n double temp_vx = this.vx;\n double temp_vy = this.vy;\n for (int i = 0; i < bodies.length; i++) {\n Body otherBody = bodies[i];\n if (otherBody.name != this.name){ // makes sure a body doesn't calculate acc on itself\n double r = Math.sqrt(Math.pow((this.x - otherBody.x),2) + Math.pow((this.y - otherBody.y),2));\n double temp_acc;\n try {\n temp_acc = (G * otherBody.mass)/Math.pow(r,3); // temp_acc * deltax = ax\n }\n catch (ArithmeticException e){ \n temp_acc = 0;\n }\n ax += temp_acc * (otherBody.x - this.x);\n ay += temp_acc * (otherBody.y - this.y);\n }\n }\n // change temp_vx and temp_vy based on acceleration\n temp_vx += ax * dt;\n temp_vy += ay * dt;\n \n this.euler_x = this.x + temp_vx * dt;\n this.euler_y = this.y + temp_vy * dt;\n }", "public static NewMovement create(PosRotScale originLoc, float ex, float ey,float ez, int duration) {\n\n/*\n\t\tVector3 posO = new Vector3();\n\t\toriginObject.transform.getTranslation(posO);\n\t\t\n\t\tQuaternion orotation = new Quaternion();\n\t\toriginObject.transform.getRotation(orotation,true); //existing rotation\n\t\t\n\t\t//first we create a matrix for the destination location reusing the same rotation\n\t\t Vector3 destination_loc = new Vector3(ex,ey,ez);\n\t\t Vector3 destination_scale = new Vector3(1,1,1);\n\t\t// Matrix4 destination = new Matrix4(destination_loc,orotation,destination_scale);\n\t\t \n\t\t //the difference is the new movement\n\t\tMatrix4 oldloc = originObject.transform.cpy();\n\t\t\n\t\t Gdx.app.log(logstag, \"_____________________________________________destination_loc:\"+destination_loc.x+\",\"+destination_loc.y+\",\"+destination_loc.z);\n\t\t\t\n\t\t Vector3 destination_loc2 = destination_loc.mul(oldloc);\n\t\t \n\t\t Gdx.app.log(logstag, \"________________________=______destination_loc:\"+destination_loc2.x+\",\"+destination_loc2.y+\",\"+destination_loc2.z);\n\t\t\t\n\t\t\t\n\t\tMatrix4 destinationmatrix = new Matrix4().setTranslation(destination_loc2);\n\t\t\n\t\t*/\n\t\t Vector3 destination_loc = new Vector3(ex,ey,ez);\n\t\t \n\t\treturn create( originLoc, destination_loc, duration);\n\t\t\n\t}", "public abstract Vec2 doorPosition();", "godot.wire.Wire.Vector2 getPosition();", "@Override\n\tpublic D3int getPos() {\n\t\treturn myPos;\n\t}", "double getOffset();", "public void setOlddeltaT(int value) {\n this.olddeltaT = value;\n }", "public logicaEnemigos(){\n\t\t//le damos una velocidad inicial al enemigo\n\t\tsuVelocidad = 50;\n\t\tsuDireccionActual = 0.0;\n\t\tposX = 500 ;\n\t\tposY = 10;\n\t}", "private Position getTestPos1() {\r\n Grid grid = GridBuilder.builder()\r\n .withMaxX(10)\r\n .withMaxY(10)\r\n .withMinY(-20)\r\n .withMinY(-20)\r\n .build();\r\n Moveable moveable = MoveableBuilder.builder()\r\n .withGrid(grid)\r\n .withShape(PositionShapeBuilder.builder()\r\n .withPosition(Positions.of(Directions.S, 0, 0, 0))\r\n .build())\r\n .withVelocity(100)\r\n .build();\r\n moveable.moveForward();\r\n moveable.turnRight();\r\n moveable = MoveableBuilder.builder()\r\n .withGrid(grid)\r\n .withShape(PositionShapeBuilder.builder()\r\n .withPosition(moveable.getPosition())\r\n .build())\r\n .withVelocity(50)\r\n .build();\r\n moveable.moveForward();\r\n PositionImpl position = (PositionImpl) moveable.getPosition();\r\n moveable.makeTurn(position.calcAbsoluteAngle() - position.getDirection().getAngle());\r\n return moveable.getPosition();\r\n }", "private void CreaCoordinate(){\n \n this.punto = new Point(80, 80);\n \n }", "public int getDelta() {\n\t\treturn (int) ((end - start) % Integer.MAX_VALUE);\n\t}", "public static float getDelta() \r\n {\r\n return (currentTime - lastTime) * DAMPING; \r\n }", "@Override\r\n default Vector3 getEnd() {\r\n return Vector3.fromXYZ(getOrgX() + getDirX(), getOrgY() + getDirY(), getOrgZ() + getDirZ());\r\n }", "Position_changerOrdonnee createPosition_changerOrdonnee();", "godot.wire.Wire.Vector3 getPosition();", "Vector getPos();", "private void adjustPosition(Element elem, BoxCoordinates pos)\n {\n try {\n if (elem.getAttribute(\"llx\") == null || elem.getAttribute(\"llx\").getDoubleValue() > pos.getLlx()) {\n elem.setAttribute(\"llx\", String.valueOf(pos.getLlx()));\n }\n if (elem.getAttribute(\"lly\") == null || elem.getAttribute(\"lly\").getDoubleValue() < pos.getLly()) {\n elem.setAttribute(\"lly\", String.valueOf(pos.getLly()));\n }\n if (elem.getAttribute(\"urx\") == null || elem.getAttribute(\"urx\").getDoubleValue() < pos.getUrx()) {\n elem.setAttribute(\"urx\", String.valueOf(pos.getUrx()));\n }\n if (elem.getAttribute(\"ury\") == null || elem.getAttribute(\"ury\").getDoubleValue() > pos.getUry()) {\n elem.setAttribute(\"ury\", String.valueOf(pos.getUry()));\n }\n }\n catch(org.jdom.DataConversionException ex)\n {\n log.error( ex.getClass().getName() + \": \" + ex.getMessage() );\n }\n }", "public Position<Edge<E>> getPosition() { return pos; }", "Position getOldPosition();", "public Position(TrackSession trackSession, String positionBody) {\r\n final String DELIMITER_TOKEN = \",\";\r\n\r\n // Parse positionBody\r\n String aux;\r\n StringTokenizer tk = new StringTokenizer(positionBody, DELIMITER_TOKEN);\r\n aux = tk.nextToken();\r\n String ltStr = aux.substring(0, aux.length() - 1);\r\n char cardinal = aux.charAt(aux.length() - 1);\r\n int factorLt = (cardinal == 'N' ? 1 : -1);\r\n double lt = Double.parseDouble(ltStr);\r\n int ltInt = (int) (lt / 100);\r\n double ltMinutes = lt % 100;\r\n double ltDegrees = ltInt + ltMinutes / 60;\r\n ltDegrees = ltDegrees * factorLt;\r\n aux = tk.nextToken();\r\n String lgStr = aux.substring(0, aux.length() - 1);\r\n cardinal = aux.charAt(aux.length() - 1);\r\n int factorLg = (cardinal == 'E' ? 1 : -1);\r\n double lg = Double.parseDouble(lgStr);\r\n int lgInt = (int) (lg / 100);\r\n double lgMinutes = lg % 100;\r\n double lgDegrees = lgInt + lgMinutes / 60;\r\n lgDegrees = lgDegrees * factorLg;\r\n String timeStr = tk.nextToken();\r\n int hour = Character.digit(timeStr.charAt(0), 10);\r\n hour = hour * 10 + Character.digit(timeStr.charAt(1), 10);\r\n int minute = Character.digit(timeStr.charAt(2), 10);\r\n minute = minute * 10 + Character.digit(timeStr.charAt(3), 10);\r\n int second = Character.digit(timeStr.charAt(4), 10);\r\n second = second * 10 + Character.digit(timeStr.charAt(5), 10);\r\n int secondsOfDay = hour * 60 * 60 + minute * 60 + second;\r\n Date time = new Date(secondsOfDay * 1000);\r\n //String dummy = tk.nextToken(); // Not used\r\n String altStr = tk.nextToken();\r\n double alt = Double.parseDouble(altStr);\r\n //String velStr = tk.nextToken(); // Not used\r\n String satStr = tk.nextToken();\r\n int nSat = Integer.parseInt(satStr);\r\n String hDopStr = tk.nextToken();\r\n double hDop = Double.parseDouble(hDopStr);\r\n String fixedStr = tk.nextToken();\r\n int fixed = Integer.parseInt(fixedStr);\r\n\r\n // Initialize object fields.\r\n mTrackSession = trackSession;\r\n if (mTrackSession != null)\r\n mTrackSessionId = trackSession.get_id();\r\n mLatitude = ltDegrees;\r\n mLongitude = lgDegrees;\r\n mTime = time;\r\n mAltitude = alt;\r\n mSat = nSat;\r\n mHdop = hDop;\r\n mFixed = fixed;\r\n\r\n// A inserção na base de dados é realizada fora do constructor.\r\n// // Add new Object into database\r\n// // Read GuardTracker database helper\r\n// GuardTrackerDbHelper dbHelper = new GuardTrackerDbHelper(context);\r\n// // Initialize database for write\r\n// final SQLiteDatabase db = dbHelper.getWritableDatabase();\r\n// // Prepare values to write to database\r\n// int latRaw = (int) (mLatitude * GPS_DEGREES_PRECISION);\r\n// int lngRaw = (int) (mLongitude * GPS_DEGREES_PRECISION);\r\n// int altRaw = (int) (mAltitude * GPS_ALTITUDE_PRECISION);\r\n// int hDopRaw = (int) (mHdop * GPS_HDOP_PRECISION);\r\n// int timeRaw = (int) time.getTime();\r\n// ContentValues contentValues = new ContentValues();\r\n// contentValues.put(GuardTrackerContract.PositionTable.COLUMN_NAME_SESSION, mTrackSessionId == 0 ? null : mTrackSessionId);\r\n// contentValues.put(GuardTrackerContract.PositionTable.COLUMN_NAME_LT, latRaw);\r\n// contentValues.put(GuardTrackerContract.PositionTable.COLUMN_NAME_LG, lngRaw);\r\n// contentValues.put(GuardTrackerContract.PositionTable.COLUMN_NAME_TIME, timeRaw);\r\n// contentValues.put(GuardTrackerContract.PositionTable.COLUMN_NAME_ALTITUDE, altRaw);\r\n// contentValues.put(GuardTrackerContract.PositionTable.COLUMN_NAME_NSAT, mSat);\r\n// contentValues.put(GuardTrackerContract.PositionTable.COLUMN_NAME_HDOP, hDopRaw);\r\n// contentValues.put(GuardTrackerContract.PositionTable.COLUMN_NAME_FIXED, mFixed);\r\n// long pkId = db.insertOrThrow(GuardTrackerContract.PositionTable.TABLE_NAME, null, contentValues);\r\n//\r\n// _id = (int) pkId;\r\n//\r\n// db.close();\r\n\r\n }", "@Override\n\tpublic int getPosition() {\n\t\treturn 0;\n\t}", "private Delta _parseDelta(Matcher matcher)\n {\n if (matcher.group(2) != null)\n {\n return _parseCoordinates(matcher);\n }\n\n return _parseCharacter(matcher);\n }", "public String getPos(){\r\n\t\t return pos;\r\n\t }", "public int deltaX() {\n\t\treturn _deltaX;\n\t}", "public Position(double degrees, GeoOrientation o){\n this.degrees = degrees;\n orientation = o;\n }", "private void adjustEViewPosition() {\n double aVec[] = theRocket.getCoordSys().getPositionVec();\n CoordSys eViewSys = new CoordSys();\n eViewSys.setZAxis(VMath.normalize(aVec));\n\n aVec = VMath.vecMultByScalar(aVec, 2.5);\n eViewSys.setPositionAsVec(aVec);\n\n double[] zAxis = VMath.normalize(eViewSys.zAxis().getVectorForm());\n double[] yAxis = VMath.normalize(theRocket.getCoordSys().yAxis().getVectorForm());\n double[] xAxis = VMath.normalize(VMath.crossprd(yAxis, zAxis));\n yAxis = VMath.crossprd(zAxis, xAxis);\n eViewSys.setXAxis(xAxis);\n eViewSys.setYAxis(yAxis);\n eViewSys.setZAxis(zAxis);\n\n eViewSys.xRotate(180);\n eViewSys.zRotate(-90);\n eView.setViewingCoordSys(eViewSys);\n }", "public void setPosEnArcos(Position<Arco<E>> pos){\r\n\t\tposLA = pos;\r\n\t}", "Double getOffset();", "public static Posicion createUpdatedEntity(EntityManager em) {\n Posicion posicion = new Posicion()\n .titulo(UPDATED_TITULO)\n .descripcion(UPDATED_DESCRIPCION)\n .numeroPuestos(UPDATED_NUMERO_PUESTOS)\n .salarioMinimo(UPDATED_SALARIO_MINIMO)\n .salarioMaximo(UPDATED_SALARIO_MAXIMO)\n .fechaAlta(UPDATED_FECHA_ALTA)\n .fechaNecesidad(UPDATED_FECHA_NECESIDAD);\n return posicion;\n }", "public ParticleEmotion(World world, Entity host, double posX, double posY, double posZ, float height, int hostType, int emoType)\r\n {\r\n super(world, posX, posY, posZ);\r\n this.host = host;\r\n this.setSize(0F, 0F);\r\n this.setPosition(posX, posY, posZ);\r\n this.prevPosX = posX;\r\n this.prevPosY = posY;\r\n this.prevPosZ = posZ;\r\n this.motionX = 0D;\r\n this.motionZ = 0D;\r\n this.motionY = 0D;\r\n this.particleType = emoType;\r\n this.particleScale = this.rand.nextFloat() * 0.05F + 0.275F;\r\n this.particleAlpha = 0F;\r\n this.playSpeed = 1F;\r\n this.playSpeedCount = 0F;\r\n this.stayTick = 10;\r\n this.stayTickCount = 0;\r\n this.fadeTick = 0;\r\n this.fadeState = 0; //0:fade in, 1:normal, 2:fade out, 3:set dead\r\n this.frameSize = 1;\r\n this.addHeight = height;\r\n this.hostType = hostType; //0:any entity, 1:entity, 2:block\r\n this.particleAge = -1; //prevent showing the emo's initial moving from posY = 0\r\n this.canCollide = false;\r\n \r\n //set icon position\r\n switch(this.particleType)\r\n {\r\n case 1: //小愛心\r\n \tthis.particleIconX = 0.0625F;\r\n \tthis.particleIconY = 0F;\r\n \tthis.particleMaxAge = 7;\r\n \tthis.playTimes = 4;\r\n \t//no stay\r\n \tthis.stayTick = 0;\r\n\t\t\tbreak;\r\n case 2: //噴汗\r\n \tthis.particleIconX = 0.0625F;\r\n \tthis.particleIconY = 0.5F;\r\n \tthis.particleMaxAge = 7;\r\n \tthis.playTimes = 3;\r\n \t//cancel fade in\r\n \tthis.particleAlpha = 1F;\r\n \tthis.fadeState = 1;\r\n \tthis.fadeTick = 5;\r\n \t//no stay\r\n \tthis.stayTick = 0;\r\n \tbreak;\r\n case 3: //問號\r\n \tthis.particleIconX = 0.125F;\r\n \tthis.particleIconY = 0F;\r\n \tthis.particleMaxAge = 7;\r\n \tthis.playTimes = 1;\r\n \t//short fade in\r\n \tthis.fadeTick = 3;\r\n\t\t\tbreak;\r\n case 4: //驚嘆號\r\n \tthis.particleIconX = 0.125F;\r\n \tthis.particleIconY = 0.5F;\r\n \tthis.particleMaxAge = 7;\r\n \tthis.playTimes = 1;\r\n \t//short fade in\r\n \tthis.fadeTick = 3;\r\n \t//long stay\r\n \tthis.stayTick = 20;\r\n \tbreak;\r\n case 5: //點點點\r\n \tthis.particleIconX = 0.1875F;\r\n \tthis.particleIconY = 0F;\r\n \tthis.particleMaxAge = 7;\r\n \tthis.playTimes = 1;\r\n \t//long stay\r\n \tthis.stayTick = 20;\r\n \t//slow play\r\n \tthis.playSpeed = 0.5F;\r\n\t\t\tbreak;\r\n case 6: //冒青筋\r\n \tthis.particleIconX = 0.1875F;\r\n \tthis.particleIconY = 0.5F;\r\n \tthis.particleMaxAge = 7;\r\n \tthis.playTimes = 1;\r\n \t//short fade in\r\n \tthis.fadeTick = 3;\r\n \tbreak;\r\n case 7: //音符\r\n \tthis.particleIconX = 0.25F;\r\n \tthis.particleIconY = 0F;\r\n \tthis.particleMaxAge = 15;\r\n \tthis.playTimes = 1;\r\n \t//cancel fade in\r\n \tthis.particleAlpha = 1F;\r\n \tthis.fadeState = 1;\r\n \tthis.fadeTick = 3;\r\n \t//short stay\r\n \tthis.stayTick = 3;\r\n \t//slow play\r\n \tthis.playSpeed = 0.7F;\r\n \tbreak;\r\n case 8: //cry\r\n \tthis.particleIconX = 0.3125F;\r\n \tthis.particleIconY = 0F;\r\n \tthis.particleMaxAge = 7;\r\n \tthis.playTimes = 3;\r\n \t//short fade in\r\n \tthis.fadeTick = 3;\r\n \t//no stay\r\n \tthis.stayTick = 0;\r\n \t//slow play\r\n \tthis.playSpeed = 0.5F;\r\n \tbreak;\r\n case 9: //流口水\r\n \tthis.particleIconX = 0.3125F;\r\n \tthis.particleIconY = 0.5F;\r\n \tthis.particleMaxAge = 7;\r\n \tthis.playTimes = 2;\r\n \t//short fade in\r\n \tthis.fadeTick = 3;\r\n \t//no stay\r\n \tthis.stayTick = 1;\r\n \t//slow play\r\n \tthis.playSpeed = 0.5F;\r\n \tbreak;\r\n case 10: //混亂\r\n \tthis.particleIconX = 0.375F;\r\n \tthis.particleIconY = 0F;\r\n \tthis.particleMaxAge = 7;\r\n \tthis.playTimes = 4;\r\n \t//cancel fade in\r\n \tthis.particleAlpha = 1F;\r\n \tthis.fadeState = 1;\r\n \tthis.fadeTick = 3;\r\n \t//short stay\r\n \tthis.stayTick = 1;\r\n \tbreak;\r\n case 11: //尋找\r\n \tthis.particleIconX = 0.375F;\r\n \tthis.particleIconY = 0.5F;\r\n \tthis.particleMaxAge = 7;\r\n \tthis.playTimes = 2;\r\n \t//cancel fade in\r\n \tthis.particleAlpha = 1F;\r\n \tthis.fadeState = 1;\r\n \tthis.fadeTick = 3;\r\n \t//short stay\r\n \tthis.stayTick = 0;\r\n \t//slow play\r\n \tthis.playSpeed = 0.75F;\r\n \tbreak;\r\n case 12: //驚嚇\r\n \tthis.particleIconX = 0.4375F;\r\n \tthis.particleIconY = 0F;\r\n \tthis.particleMaxAge = 14;\r\n \tthis.playTimes = 1;\r\n \t//cancel fade in\r\n \tthis.particleAlpha = 1F;\r\n \tthis.fadeState = 1;\r\n \tthis.fadeTick = 3;\r\n \t//long stay\r\n \tthis.stayTick = 20;\r\n \t//slow play\r\n \tthis.playSpeed = 0.75F;\r\n \t//large frame\r\n \tthis.frameSize = 2;\r\n \tbreak;\r\n case 13: //點頭\r\n \tthis.particleIconX = 0.5F;\r\n \tthis.particleIconY = 0F;\r\n \tthis.particleMaxAge = 7;\r\n \tthis.playTimes = 2;\r\n \t//cancel fade in\r\n \tthis.particleAlpha = 1F;\r\n \tthis.fadeState = 1;\r\n \tthis.fadeTick = 3;\r\n \t//no stay\r\n \tthis.stayTick = 0;\r\n \t//slow play\r\n \tthis.playSpeed = 0.75F;\r\n \tbreak;\r\n case 14: //+_+\r\n \tthis.particleIconX = 0.5F;\r\n \tthis.particleIconY = 0.5F;\r\n \tthis.particleMaxAge = 7;\r\n \tthis.playTimes = 2;\r\n \t//short fade in\r\n \tthis.fadeTick = 3;\r\n \t//no stay\r\n \tthis.stayTick = 0;\r\n \tbreak;\r\n case 15: //kiss\r\n \tthis.particleIconX = 0.5625F;\r\n \tthis.particleIconY = 0F;\r\n \tthis.particleMaxAge = 7;\r\n \tthis.playTimes = 1;\r\n \t//short fade in\r\n \tthis.fadeTick = 3;\r\n \t//long stay\r\n \tthis.stayTick = 15;\r\n \t//slow play\r\n \tthis.playSpeed = 0.7F;\r\n \tbreak;\r\n case 16: //lol\r\n \tthis.particleIconX = 0.5625F;\r\n \tthis.particleIconY = 0.5F;\r\n \tthis.particleMaxAge = 7;\r\n \tthis.playTimes = 3;\r\n \t//cancel fade in\r\n \tthis.particleAlpha = 1F;\r\n \tthis.fadeState = 1;\r\n \tthis.fadeTick = 3;\r\n \t//no stay\r\n \tthis.stayTick = 0;\r\n \tbreak;\r\n case 17: //奸笑\r\n \tthis.particleIconX = 0.625F;\r\n \tthis.particleIconY = 0F;\r\n \tthis.particleMaxAge = 15;\r\n \tthis.playTimes = 1;\r\n \t//short fade in\r\n \tthis.fadeTick = 3;\r\n \t//slow play\r\n \tthis.playSpeed = 0.5F;\r\n \tbreak;\r\n case 18: //殘念\r\n \tthis.particleIconX = 0.6875F;\r\n \tthis.particleIconY = 0F;\r\n \tthis.particleMaxAge = 7;\r\n \tthis.playTimes = 1;\r\n \t//no stay\r\n \tthis.stayTick = 0;\r\n \t//slow play\r\n \tthis.playSpeed = 0.4F;\r\n \tbreak;\r\n case 19: //舔舔\r\n \tthis.particleIconX = 0.6875F;\r\n \tthis.particleIconY = 0.5F;\r\n \tthis.particleMaxAge = 7;\r\n \tthis.playTimes = 3;\r\n \t//cancel fade in\r\n \tthis.particleAlpha = 1F;\r\n \tthis.fadeState = 1;\r\n \tthis.fadeTick = 3;\r\n \t//no stay\r\n \tthis.stayTick = 0;\r\n \t//slow play\r\n \tthis.playSpeed = 0.75F;\r\n \tbreak;\r\n case 20: //orz\r\n \tthis.particleIconX = 0.75F;\r\n \tthis.particleIconY = 0F;\r\n \tthis.particleMaxAge = 7;\r\n \tthis.playTimes = 1;\r\n \t//short fade in\r\n \tthis.fadeTick = 3;\r\n \t//long stay\r\n \tthis.stayTick = 20;\r\n \t//slow play\r\n \tthis.playSpeed = 0.5F;\r\n \tbreak;\r\n case 21: //O\r\n \tthis.particleIconX = 0.75F;\r\n \tthis.particleIconY = 0.5F;\r\n \tthis.particleMaxAge = 0;\r\n \tthis.playTimes = 1;\r\n \t//long stay\r\n \tthis.stayTick = 40;\r\n \tbreak;\r\n case 22: //X\r\n \tthis.particleIconX = 0.75F;\r\n \tthis.particleIconY = 0.5625F;\r\n \tthis.particleMaxAge = 0;\r\n \tthis.playTimes = 1;\r\n \t//long stay\r\n \tthis.stayTick = 40;\r\n \tbreak;\r\n case 23: //!?\r\n \tthis.particleIconX = 0.75F;\r\n \tthis.particleIconY = 0.625F;\r\n \tthis.particleMaxAge = 0;\r\n \tthis.playTimes = 1;\r\n \t//long stay\r\n \tthis.stayTick = 40;\r\n \tbreak;\r\n case 24: //rock\r\n \tthis.particleIconX = 0.75F;\r\n \tthis.particleIconY = 0.6875F;\r\n \tthis.particleMaxAge = 0;\r\n \tthis.playTimes = 1;\r\n \t//long stay\r\n \tthis.stayTick = 40;\r\n \tbreak;\r\n case 25: //paper\r\n \tthis.particleIconX = 0.75F;\r\n \tthis.particleIconY = 0.75F;\r\n \tthis.particleMaxAge = 0;\r\n \tthis.playTimes = 1;\r\n \t//long stay\r\n \tthis.stayTick = 40;\r\n \tbreak;\r\n case 26: //scissors\r\n \tthis.particleIconX = 0.75F;\r\n \tthis.particleIconY = 0.8125F;\r\n \tthis.particleMaxAge = 0;\r\n \tthis.playTimes = 1;\r\n \t//long stay\r\n \tthis.stayTick = 40;\r\n \tbreak;\r\n case 27: //-w-\r\n \tthis.particleIconX = 0.75F;\r\n \tthis.particleIconY = 0.875F;\r\n \tthis.particleMaxAge = 0;\r\n \tthis.playTimes = 1;\r\n \t//long stay\r\n \tthis.stayTick = 40;\r\n \tbreak;\r\n case 28: //-口-\r\n \tthis.particleIconX = 0.75F;\r\n \tthis.particleIconY = 0.9375F;\r\n \tthis.particleMaxAge = 0;\r\n \tthis.playTimes = 1;\r\n \t//long stay\r\n \tthis.stayTick = 40;\r\n \tbreak;\r\n case 29: //blink\r\n \tthis.particleIconX = 0.8125F;\r\n \tthis.particleIconY = 0F;\r\n \tthis.particleMaxAge = 7;\r\n \tthis.playTimes = 1;\r\n \t//short fade in\r\n \tthis.fadeTick = 3;\r\n \t//slow play\r\n \tthis.playSpeed = 0.35F;\r\n \t//long stay\r\n \tthis.stayTick = 20;\r\n \tbreak;\r\n case 30: //哼\r\n \tthis.particleIconX = 0.8125F;\r\n \tthis.particleIconY = 0.5F;\r\n \tthis.particleMaxAge = 7;\r\n \tthis.playTimes = 1;\r\n \t//short fade in\r\n \tthis.fadeTick = 3;\r\n \t//slow play\r\n \tthis.playSpeed = 0.75F;\r\n \t//short stay\r\n \tthis.stayTick = 3;\r\n \tbreak;\r\n case 31: //臉紅紅\r\n \tthis.particleIconX = 0.875F;\r\n \tthis.particleIconY = 0F;\r\n \tthis.particleMaxAge = 3;\r\n \tthis.particleScale += 0.2F;\r\n \tthis.playTimes = 1;\r\n \t//short fade in\r\n \tthis.fadeTick = 3;\r\n \t//slow play\r\n \tthis.playSpeed = 0.75F;\r\n \t//long stay\r\n \tthis.stayTick = 30;\r\n \tbreak;\r\n case 32: //尷尬\r\n \tthis.particleIconX = 0.875F;\r\n \tthis.particleIconY = 0.25F;\r\n \tthis.particleMaxAge = 5;\r\n \tthis.playTimes = 4;\r\n \t//slow play\r\n \tthis.playSpeed = 0.75F;\r\n \t//no stay\r\n \tthis.stayTick = 0;\r\n \tbreak;\r\n case 33: //:P\r\n \tthis.particleIconX = 0.875F;\r\n \tthis.particleIconY = 0.625F;\r\n \tthis.particleMaxAge = 4;\r\n \tthis.playTimes = 1;\r\n \t//slow play\r\n \tthis.playSpeed = 0.25F;\r\n \t//long stay\r\n \tthis.stayTick = 30;\r\n \tbreak;\r\n case 34: //|||\r\n \tthis.particleIconX = 0.875F;\r\n \tthis.particleIconY = 0.9375F;\r\n \tthis.particleMaxAge = 0;\r\n \tthis.particleScale += 0.3F;\r\n \tthis.playTimes = 1;\r\n \t//long stay\r\n \tthis.stayTick = 50;\r\n \tbreak;\r\n default: //汗\r\n \tthis.particleIconX = 0F;\r\n \tthis.particleIconY = 0F;\r\n \tthis.particleMaxAge = 15;\r\n \tthis.playTimes = 1;\r\n\t\t\tbreak;\r\n }\r\n \r\n //init position\r\n this.px = posX;\r\n this.py = posY;\r\n this.pz = posZ;\r\n this.addx = 0D;\r\n this.addy = 0D;\r\n this.addz = 0D;\r\n \r\n calcParticlePosition();\r\n }", "private MsoSmartArtNodePosition(int value) { this.value = value; }", "godot.wire.Wire.Vector2OrBuilder getPositionOrBuilder();", "public Position position();" ]
[ "0.5645123", "0.55790704", "0.5527921", "0.552554", "0.5479147", "0.54715705", "0.54562294", "0.5440366", "0.54198134", "0.5372709", "0.53726894", "0.5348761", "0.53464246", "0.532147", "0.5289407", "0.5276985", "0.5272737", "0.52556556", "0.52206415", "0.5209263", "0.5196978", "0.5189798", "0.51800615", "0.5170956", "0.51404643", "0.5127484", "0.5127448", "0.51151013", "0.5101847", "0.50983924", "0.509178", "0.50684357", "0.5067955", "0.5022723", "0.50042856", "0.5004159", "0.49892372", "0.49638602", "0.49390694", "0.49355912", "0.49329793", "0.49200666", "0.49028465", "0.4901815", "0.49006173", "0.48790297", "0.48790297", "0.487307", "0.48726445", "0.48652095", "0.48646986", "0.48564386", "0.48382613", "0.48291045", "0.48203468", "0.48193696", "0.48193204", "0.48058617", "0.48052248", "0.48024836", "0.47976527", "0.47954535", "0.47875446", "0.47861224", "0.47861224", "0.47860017", "0.47760338", "0.4775957", "0.47527617", "0.4737751", "0.47364265", "0.4736037", "0.4731171", "0.47219503", "0.4716956", "0.4716507", "0.47055355", "0.4701098", "0.46983778", "0.46977663", "0.4694787", "0.46839884", "0.46796107", "0.46758714", "0.4672787", "0.46711272", "0.46707526", "0.46700588", "0.4669311", "0.46536615", "0.4651611", "0.46472967", "0.4645944", "0.46412462", "0.46374488", "0.46349683", "0.46347862", "0.4629", "0.46272847", "0.4622366" ]
0.5742459
0
Class which updates the SOD positions by adding transactions to generate EOD Position
private Map<SODPosition, Integer> updateSODPositions() { Map<SODPosition, Integer> sodPositionsWithDelta = new HashMap<>(); // This will hold all instruments that have associated transactions // this is neede at the end to carry forward SOD transaction on which // no transactions have come. Set<String> instrumentsProcessed = new HashSet<>(); for (Transaction transaction : transactions) { List<SODPosition> positions = sodPositions.get(transaction.getInstrument()); instrumentsProcessed.add(transaction.getInstrument()); if (TransactionType.B.equals(transaction.getTranscationType())) { for (SODPosition position : positions) { if (AccountType.E.equals(position.getAccountType())) { LOGGER.debug("Processing Transaction Buy for Account Type E with account ID = " + position.getAccount() + " and instrument = " + position.getInstrument()); position.setQuantity(position.getQuantity() + transaction.getQuantity()); sodPositionsWithDelta = populateDeltaMap(sodPositionsWithDelta, position, transaction.getQuantity()); } else { LOGGER.debug("Processing Transaction Buy for Account Type I with account ID = " + position.getAccount() + " and instrument = " + position.getInstrument()); position.setQuantity(position.getQuantity() - transaction.getQuantity()); sodPositionsWithDelta = populateDeltaMap(sodPositionsWithDelta, position, (transaction.getQuantity() * -1)); } } } else { for (SODPosition position : positions) { if (AccountType.E.equals(position.getAccountType())) { LOGGER.debug("Processing Transaction Sell for Account Type E with account ID = " + position.getAccount() + " and instrument = " + position.getInstrument()); position.setQuantity(position.getQuantity() - transaction.getQuantity()); sodPositionsWithDelta = populateDeltaMap(sodPositionsWithDelta, position, (transaction.getQuantity() * -1)); } else { LOGGER.debug("Processing Transaction Sell for Account Type I with account ID = " + position.getAccount() + " and instrument = " + position.getInstrument()); position.setQuantity(position.getQuantity() + transaction.getQuantity()); sodPositionsWithDelta = populateDeltaMap(sodPositionsWithDelta, position, transaction.getQuantity()); } } } } /* Populate sodPositions with the positions on which there were no transactions */ for (Map.Entry<String, ArrayList<SODPosition>> entry : sodPositions.entrySet()) { if (!instrumentsProcessed.contains(entry.getKey())) { for (SODPosition value : entry.getValue()) { sodPositionsWithDelta.put(value, 0); } } } return sodPositionsWithDelta; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n\tpublic void posModify() {\n\t\tgetEntityManager().refresh(instance);\n\t\tcambiarTipoCuenta(instance);\n\t\tgetEntityManager().flush();\n\t\tgetEntityManager().refresh(instance);\n\t\tresultList = null;\n\t\trootNode = null;\n\t}", "public static void positions(SessionFactory sessionFactory, ArrayList<Position> positions) {\n\t\tSession session = sessionFactory.openSession();\n\t\tsession.beginTransaction();\n\t\t\n\t\tfor (Position position : positions)\n\t\t\tsession.save(position);\n\t\t\n\t\tsession.getTransaction().commit();\n\t\tsession.close();\n\t\t\n\t}", "public void updateStationPositions() {\r\n \t\tObject key;\r\n \t\tObject[] cells = graph.getDescendants(graph.getRoots());\r\n \t\tfor (Object cell : cells) {\r\n \t\t\tif (cell instanceof JmtCell) {\r\n \t\t\t\tJmtCell jcell = (JmtCell) cell;\r\n \t\t\t\tkey = ((CellComponent) jcell.getUserObject()).getKey();\r\n \t\t\t\t// Sets cell coordinate into data structure\r\n \t\t\t\tmodel.setStationPosition(key, new JMTPoint(getCellCoordinates(jcell), !jcell.isLeftInputCell()));\r\n \t\t\t}\r\n \t\t}\r\n \t}", "private void addPositions() {\n Object[] newRow = new Object[6];\n TicketPriceListPosition selectedPosition = (TicketPriceListPosition) ticketPriceListPositionJComboBox.getSelectedItem();\n newRow[0] = selectedPosition.getDay().getName();\n newRow[1] = selectedPosition.getDiscountGroup().getName();\n newRow[2] = selectedPosition.getDaytime().getName();\n newRow[3] = selectedPosition.getAttractionType().getName();\n newRow[4] = selectedPosition.getPrice();\n newRow[5] = selectedPosition.getId();\n this.tableModel.addRow(newRow);\n this.choosenPositionTable = new JTable(this.tableModel);\n ticketPriceListPositionController.createTicketPriceListPosition(\n selectedPosition.getPrice(),\n ticketPriceList.getId(),\n selectedPosition.getDay().getId(),\n selectedPosition.getDiscountGroup().getId(),\n selectedPosition.getDaytime().getId(),\n selectedPosition.getAttractionType().getId()\n );\n JOptionPane.showMessageDialog(null, \"Position has been successfully added to price list!\");\n }", "private void updateEISAndEAS(){\n eas.registerPayment(paymentDTO);\n eis.updateInventory(saleDTO);\n }", "@Override\n\tpublic void posSave() {\n\t\t\n\t}", "@Override\n\tpublic void posSave() {\n\t\t\n\t}", "@Override\n\tvoid make_deposit(DataStore ds){\n\tds.setbalancedepositAccount1(ds.getbalanceAccount1_temp()+ds.getdepositAccount1());\n\t}", "@Override\n\tpublic void updatePosition() {\n\t\t\n\t}", "@Test\r\n public void test() {\r\n Configuration.getInstance().setDeductIncomeTax(false);\r\n\r\n String symbol = \"TST\";\r\n Stock stock = new Stock(symbol, \"Test Stock\");\r\n stock.setPrice(10.00);\r\n stock.setDivRate(1.00);\r\n\r\n // Initial (empty) position.\r\n Position position = new Position(stock);\r\n Assert.assertEquals(0, position.getNoOfShares());\r\n Assert.assertEquals(0.00, position.getCurrentCost(), DELTA);\r\n Assert.assertEquals(0.00, position.getCurrentValue(), DELTA);\r\n Assert.assertEquals(0.00, position.getCurrentResult(), DELTA);\r\n Assert.assertEquals(0.00, position.getTotalCost(), DELTA);\r\n Assert.assertEquals(0.00, position.getAnnualIncome(), DELTA);\r\n Assert.assertEquals(0.00, position.getYieldOnCost(), DELTA);\r\n Assert.assertEquals(0.00, position.getTotalIncome(), DELTA);\r\n Assert.assertEquals(0.00, position.getTotalReturn(), DELTA);\r\n Assert.assertEquals(0.00, position.getTotalReturnPercentage(), DELTA);\r\n\r\n // BUY 100 @ $20 ($5 costs)\r\n stock.setPrice(20.00);\r\n position.addTransaction(TestUtil.createTransaction(1, 1L, TransactionType.BUY, symbol, 100, 20.00, 5.00));\r\n Assert.assertEquals(100, position.getNoOfShares());\r\n Assert.assertEquals(2005.00, position.getCurrentCost(), DELTA);\r\n Assert.assertEquals(2000.00, position.getCurrentValue(), DELTA);\r\n Assert.assertEquals(-5.00, position.getCurrentResult(), DELTA);\r\n Assert.assertEquals(2005.00, position.getTotalCost(), DELTA);\r\n Assert.assertEquals(100.00, position.getAnnualIncome(), DELTA);\r\n Assert.assertEquals(4.99, position.getYieldOnCost(), DELTA);\r\n Assert.assertEquals(0.00, position.getTotalIncome(), DELTA);\r\n Assert.assertEquals(-5.00, position.getTotalReturn(), DELTA);\r\n Assert.assertEquals(-0.25, position.getTotalReturnPercentage(), DELTA);\r\n\r\n // DIVIDEND 100 @ $1.00\r\n position.addTransaction(TestUtil.createTransaction(2, 2L, TransactionType.DIVIDEND, symbol, 100, 1.00, 0.00));\r\n Assert.assertEquals(100, position.getNoOfShares());\r\n Assert.assertEquals(2005.00, position.getCurrentCost(), DELTA);\r\n Assert.assertEquals(2000.00, position.getCurrentValue(), DELTA);\r\n Assert.assertEquals(-5.00, position.getCurrentResult(), DELTA);\r\n Assert.assertEquals(2005.00, position.getTotalCost(), DELTA);\r\n Assert.assertEquals(100.00, position.getAnnualIncome(), DELTA);\r\n Assert.assertEquals(4.99, position.getYieldOnCost(), DELTA);\r\n Assert.assertEquals(100.00, position.getTotalIncome(), DELTA);\r\n Assert.assertEquals(+95.00, position.getTotalReturn(), DELTA);\r\n Assert.assertEquals(+4.74, position.getTotalReturnPercentage(), DELTA);\r\n\r\n // Price drops to $10\r\n stock.setPrice(10.00);\r\n Assert.assertEquals(100, position.getNoOfShares());\r\n Assert.assertEquals(2005.00, position.getCurrentCost(), DELTA);\r\n Assert.assertEquals(1000.00, position.getCurrentValue(), DELTA);\r\n Assert.assertEquals(-1005.00, position.getCurrentResult(), DELTA);\r\n Assert.assertEquals(-50.12, position.getCurrentResultPercentage(), DELTA);\r\n Assert.assertEquals(2005.00, position.getTotalCost(), DELTA);\r\n Assert.assertEquals(100.00, position.getAnnualIncome(), DELTA);\r\n Assert.assertEquals(4.99, position.getYieldOnCost(), DELTA);\r\n Assert.assertEquals(100.00, position.getTotalIncome(), DELTA);\r\n Assert.assertEquals(-905.00, position.getTotalReturn(), DELTA);\r\n Assert.assertEquals(-45.14, position.getTotalReturnPercentage(), DELTA);\r\n\r\n // BUY another 100 @ $10 ($5 costs)\r\n position.addTransaction(TestUtil.createTransaction(3, 3L, TransactionType.BUY, symbol, 100, 10.00, 5.00));\r\n Assert.assertEquals(200, position.getNoOfShares());\r\n Assert.assertEquals(3010.00, position.getCurrentCost(), DELTA);\r\n Assert.assertEquals(2000.00, position.getCurrentValue(), DELTA);\r\n Assert.assertEquals(-1010.00, position.getCurrentResult(), DELTA);\r\n Assert.assertEquals(-33.55, position.getCurrentResultPercentage(), DELTA);\r\n Assert.assertEquals(3010.00, position.getTotalCost(), DELTA);\r\n Assert.assertEquals(200.00, position.getAnnualIncome(), DELTA);\r\n Assert.assertEquals(6.64, position.getYieldOnCost(), DELTA);\r\n Assert.assertEquals(100.00, position.getTotalIncome(), DELTA);\r\n Assert.assertEquals(-910.00, position.getTotalReturn(), DELTA);\r\n Assert.assertEquals(-30.23, position.getTotalReturnPercentage(), DELTA);\r\n\r\n // Price raises to $20 again\r\n stock.setPrice(20.00);\r\n Assert.assertEquals(200, position.getNoOfShares());\r\n Assert.assertEquals(3010.00, position.getCurrentCost(), DELTA);\r\n Assert.assertEquals(4000.00, position.getCurrentValue(), DELTA);\r\n Assert.assertEquals(+990.00, position.getCurrentResult(), DELTA);\r\n Assert.assertEquals(+32.89, position.getCurrentResultPercentage(), DELTA);\r\n Assert.assertEquals(3010.00, position.getTotalCost(), DELTA);\r\n Assert.assertEquals(200.00, position.getAnnualIncome(), DELTA);\r\n Assert.assertEquals(6.64, position.getYieldOnCost(), DELTA);\r\n Assert.assertEquals(100.00, position.getTotalIncome(), DELTA);\r\n Assert.assertEquals(+1090.00, position.getTotalReturn(), DELTA);\r\n Assert.assertEquals(+36.21, position.getTotalReturnPercentage(), DELTA);\r\n\r\n // DIVIDEND 200 @ $1.25\r\n stock.setDivRate(1.25);\r\n position.addTransaction(TestUtil.createTransaction(4, 4L, TransactionType.DIVIDEND, symbol, 200, 1.25, 0.00));\r\n Assert.assertEquals(200, position.getNoOfShares());\r\n Assert.assertEquals(3010.00, position.getCurrentCost(), DELTA);\r\n Assert.assertEquals(4000.00, position.getCurrentValue(), DELTA);\r\n Assert.assertEquals(+990.00, position.getCurrentResult(), DELTA);\r\n Assert.assertEquals(+32.89, position.getCurrentResultPercentage(), DELTA);\r\n Assert.assertEquals(3010.00, position.getTotalCost(), DELTA);\r\n Assert.assertEquals(250.00, position.getAnnualIncome(), DELTA);\r\n Assert.assertEquals(8.31, position.getYieldOnCost(), DELTA);\r\n Assert.assertEquals(350.00, position.getTotalIncome(), DELTA);\r\n Assert.assertEquals(+1340.00, position.getTotalReturn(), DELTA);\r\n Assert.assertEquals(+44.52, position.getTotalReturnPercentage(), DELTA);\r\n\r\n // SELL 200 @ $20 ($10 costs)\r\n position.addTransaction(TestUtil.createTransaction(5, 5L, TransactionType.SELL, symbol, 200, 20.00, 10.00));\r\n Assert.assertEquals(0, position.getNoOfShares());\r\n Assert.assertEquals(0.00, position.getCurrentCost(), DELTA);\r\n Assert.assertEquals(0.00, position.getCurrentValue(), DELTA);\r\n Assert.assertEquals(0.00, position.getCurrentResult(), DELTA);\r\n Assert.assertEquals(0.00, position.getCurrentResultPercentage(), DELTA);\r\n Assert.assertEquals(3020.00, position.getTotalCost(), DELTA);\r\n Assert.assertEquals(0.00, position.getAnnualIncome(), DELTA);\r\n Assert.assertEquals(0.00, position.getYieldOnCost(), DELTA);\r\n Assert.assertEquals(350.00, position.getTotalIncome(), DELTA);\r\n Assert.assertEquals(+1330.00, position.getTotalReturn(), DELTA);\r\n Assert.assertEquals(+44.04, position.getTotalReturnPercentage(), DELTA);\r\n }", "public void setPosEnSaliente(Position<Arco<E>> pos){\r\n\t\tposV1 = pos;\r\n\t}", "@Override\n\tpublic void posSave() {\n\t\tfor(ItemRequisicionEta tmpItm : itemsAgregados) {\n\t\t\ttmpItm.setReqEtapa(instance);\n\t\t\tgetEntityManager().persist(tmpItm);\n\t\t}\n\t\tgetEntityManager().refresh(etapaRepCliHome.getInstance());\n\t}", "private Map<String, ArrayList<EODPosition>> generateOutput(Map<SODPosition, Integer> sodPositionsWithDelta) {\n Map<String, ArrayList<EODPosition>> output = new HashMap<>();\n for (Map.Entry<SODPosition, Integer> entry : sodPositionsWithDelta.entrySet()) {\n SODPosition position = entry.getKey();\n if (output.containsKey(position.getInstrument())) {\n output.get(position.getInstrument()).add(new EODPosition(position.getInstrument(), position.getAccount(), position.getAccountType(), position.getQuantity(), entry.getValue()));\n } else {\n output.put(position.getInstrument(), Lists.newArrayList(new EODPosition(position.getInstrument(), position.getAccount(), position.getAccountType(), position.getQuantity(), entry.getValue())));\n }\n\n }\n return output;\n }", "Position_ordonnee createPosition_ordonnee();", "private void updateStationPositions() {\n //stations going east\n if(layout == Layout.square) {\n for (int i = 0; i < numStations; i++) {\n northbound.get(i).setPosition(i+1,2*numStations+1);\n eastbound.get(i).setPosition(0,numStations+(i+1));\n southbound.get(i).setPosition(numStations+1+i,0);\n westbound.get(i).setPosition(numStations*2+1,1+i);\n }\n }else{\n for (int i = 0; i < numStations; i++) {\n eastbound.get(i).setPosition(i,2*numStations+i);\n northbound.get(i).setPosition(numStations+i,3*numStations+i);\n southbound.get(i).setPosition(2*numStations+i,i);\n westbound.get(i).setPosition(3*numStations+i,numStations+i);\n }\n }\n\n }", "private void updatePosition(){\n updateXPosition(true);\n updateYPosition(true);\n }", "@Override\n public void recalculatePositions() { \n \n }", "Vaisseau_positionner createVaisseau_positionner();", "public void reWrite21(SaleOrderVO[] vos)\r\n/* */ {\r\n/* 202 */ Map<String, String> map = new HashMap();\r\n/* 203 */ for (SaleOrderVO vo : vos) {\r\n/* 204 */ SaleOrderHVO hvo = vo.getParentVO();\r\n/* 205 */ UFBoolean iscoop = hvo.getBpocooptomeflag();\r\n/* 206 */ if ((null != iscoop) && (iscoop.booleanValue())) {\r\n/* 207 */ String srcHid = vo.getChildrenVO()[0].getCsrcid();\r\n/* 208 */ String billcode = hvo.getVbillcode();\r\n/* 209 */ map.put(srcHid, billcode);\r\n/* */ }\r\n/* */ }\r\n/* 212 */ if (map.size() > 0) {\r\n/* 213 */ IOrderUpdateCoopFor30 service = (IOrderUpdateCoopFor30)NCLocator.getInstance().lookup(IOrderUpdateCoopFor30.class);\r\n/* */ try\r\n/* */ {\r\n/* 216 */ service.updateCoopFlag(true, map);\r\n/* */ }\r\n/* */ catch (BusinessException e) {\r\n/* 219 */ ExceptionUtils.wrappException(e);\r\n/* */ }\r\n/* */ }\r\n/* */ }", "private void updatePosition() {\n\t\tfor (int i = 0; i < encoders.length; i++) {\n\t\t\tdRot[i] = (encoders[i].get() - lastEncPos[i]) / this.cyclesPerRev;\n\t\t\tdPos[i] = dRot[i] * wheelDiameter * Math.PI;\n\t\t\tlastEncPos[i] = encoders[i].get();\n\t\t}\n\t\t\n\t\tdLinearPos = (dPos[0] + dPos[1]) / 2;\n\t\t\n\t\tposition[2] = Math.toRadians(gyro.getAngle()) + gyroOffset;\n\t\tposition[0] += dLinearPos * Math.sin(position[2]);\n\t\tposition[1] += dLinearPos * Math.cos(position[2]);\n\t}", "@Transactional\n @Override\n public StringBuffer addSalesOrder(String customerID, String cartIDs, String addressID, String paymentType,\n String orderAmount, String scoreAll, String memo, String itemCount, String itemID,\n String supplierID, String itemType, String orderType, String objID, String invoiceType,\n String invoiceTitle, String generateType, String orderID, String allFreight, String supplierFreightStr) throws Exception {\n \t\n String ids[] = cartIDs.split(\",\");\n List<ShoppingCartVO> shopCartList = new ArrayList<ShoppingCartVO>();\n for (String id : ids) {\n ShoppingCartVO shoppingCartVO = shoppingCartDAO.findShoppingCartByID(Long.valueOf(id));\n shopCartList.add(shoppingCartVO);\n }\n Map<String,List<ShoppingCartVO>> maps = new HashMap<String,List<ShoppingCartVO>>();\n for(ShoppingCartVO s:shopCartList){\n \tList<ShoppingCartVO> temp = new ArrayList<ShoppingCartVO>();\n \t String sid1= s.getSupplierID();\n String siname1= s.getSupplierName();\n for(ShoppingCartVO shoppingCartVO1 : shopCartList){\n \t//当前店铺对应的购物车集合\n \tString sid2 = shoppingCartVO1.getSupplierID();\n \tif(sid1.equals(sid2)){\n \t\ttemp.add(shoppingCartVO1);\n \t}\n }\n maps.put(sid1+\"_\"+siname1, temp);\n }\n \n //根据物流模板计算运费\n Map<String, Double> supplierFreightMap = new HashMap<String, Double>();\n String[] supplierFreightAll = supplierFreightStr.split(\"\\\\|\");\n for (int i = 0; i < supplierFreightAll.length; i++) {\n \tString[] supplierFreight = supplierFreightAll[i].split(\":\");\n \tsupplierFreightMap.put(supplierFreight[0], Double.parseDouble(supplierFreight[1]));\n\t\t} \n \n StringBuffer ordersList = new StringBuffer();\n// cachedClient.delete(customerID + orderID);\n Set<String> set = maps.keySet();\n\t\tfor(String string : set){\n\t\t List<ShoppingCartVO> temp1= maps.get(string);\n\t\t double supplierFreight = supplierFreightMap.get(string);\n\t\t Double amount = 0d;\n\t\t Integer count = 0;\n Integer score = 0;\n Double weight = 0d;\n\t\t for (ShoppingCartVO shoppingCartVO : temp1) {\n ItemVO itemVO = itemDAO.findItemById(shoppingCartVO.getItemID());\n count += shoppingCartVO.getItemCount();\n // weight += itemVO.getWeight();\n if (shoppingCartVO.getType() == 1) {\n amount += shoppingCartVO.getItemCount() * shoppingCartVO.getSalesPrice();\n } else if (shoppingCartVO.getType() == 2) {\n score += shoppingCartVO.getItemCount() * itemVO.getScore();\n } else if (shoppingCartVO.getType() == 3) {\n amount += shoppingCartVO.getItemCount() * itemVO.getScorePrice();\n score += shoppingCartVO.getItemCount() * shoppingCartVO.getSalesScore();\n }\n }\n\t\t //SalesOrderVO tempOrder = new SalesOrderVO();\n\t /*if (tempOrder == null) {\n\t throw new Exception(\"参数错误\");\n\t }\n\t if (\"012\".indexOf(invoiceType) == -1) {\n\t throw new Exception(\"参数错误\");\n\t }*/\n\t SalesOrderDTO salesOrderDTO = new SalesOrderDTO();\n\t salesOrderDTO.setMainID(randomNumeric());\n\t salesOrderDTO.setCustomerID(customerID);\n\t salesOrderDTO.setPaymentType(Integer.valueOf(paymentType));\n\t salesOrderDTO.setPaymentStatus(0);\n\n\t // salesOrderDTO.setExpressFee(tempOrder.getExpressFee());//运费\n\t salesOrderDTO.setProductAmount(amount);\n\t salesOrderDTO.setTotalAmount(amount + supplierFreight);\n\t salesOrderDTO.setPayableAmount(amount);\n\n\t salesOrderDTO.setOrderType(Integer.valueOf(orderType));\n\t salesOrderDTO.setMemo(memo);\n\t salesOrderDTO.setInvoiceType(Integer.parseInt(invoiceType));\n\t salesOrderDTO.setInvoiceTitle(invoiceTitle);\n\t salesOrderDTO.setSupplierID(string);\n\t salesOrderDTO.setExpressFee(supplierFreight);\n\t salesOrderDAO.addSalesOrder(salesOrderDTO);\n\t ordersList.append(salesOrderDTO.getMainID()+\",\");\n\t if(!paymentType.equals(\"3\")){\n\t \t CustomerDeliveryAddressVO customerDeliveryAddressVO = customerDeliveryAddressDAO.findAddressByID(Long.valueOf(addressID));\n\t \t if (customerDeliveryAddressVO != null) {\n\t \t SalesOrderDeliveryAddressDTO salesOrderDeliveryAddressDTO = new SalesOrderDeliveryAddressDTO();\n\t \t salesOrderDeliveryAddressDTO.setSalesOrderID(salesOrderDTO.getMainID());\n\t \t salesOrderDeliveryAddressDTO.setName(customerDeliveryAddressVO.getName());\n\t \t salesOrderDeliveryAddressDTO.setCountryID(customerDeliveryAddressVO.getCountryID());\n\t \t salesOrderDeliveryAddressDTO.setProvinceID(customerDeliveryAddressVO.getProvinceID());\n\t \t salesOrderDeliveryAddressDTO.setCityID(customerDeliveryAddressVO.getCityID());\n\t \t salesOrderDeliveryAddressDTO.setDisctrictID(customerDeliveryAddressVO.getDisctrictID());\n\t \t salesOrderDeliveryAddressDTO.setAddress(customerDeliveryAddressVO.getAddress());\n\t \t salesOrderDeliveryAddressDTO.setMobile(customerDeliveryAddressVO.getMobile());\n\t \t salesOrderDeliveryAddressDTO.setTelephone(customerDeliveryAddressVO.getTelephone());\n\t \t if (customerDeliveryAddressVO.getZip() != null) {\n\t \t salesOrderDeliveryAddressDTO.setZip(customerDeliveryAddressVO.getZip());\n\t \t }\n\t \t salesOrderDeliveryAddressDAO.insertSalesOrderDeliveryAddress(salesOrderDeliveryAddressDTO);\n\t \t }\n\t \t ShippingAddressVO shippingAddressVO = shippingAddressDAO.findDefaultShippingAddress();\n\t \t if (shippingAddressVO != null) {\n\t \t SalesOrderShippingAddressDTO salesOrderShippingAddressDTO = new SalesOrderShippingAddressDTO();\n\t \t salesOrderShippingAddressDTO.setSalesOrderID(salesOrderDTO.getMainID());\n\t \t salesOrderShippingAddressDTO.setName(shippingAddressVO.getName());\n\t \t salesOrderShippingAddressDTO.setCountryID(shippingAddressVO.getCountryID());\n\t \t salesOrderShippingAddressDTO.setProvinceID(shippingAddressVO.getProvinceID());\n\t \t salesOrderShippingAddressDTO.setCityID(shippingAddressVO.getCityID());\n\t \t salesOrderShippingAddressDTO.setDisctrictID(shippingAddressVO.getDisctrictID());\n\t \t salesOrderShippingAddressDTO.setAddress(shippingAddressVO.getAddress());\n\t \t salesOrderShippingAddressDTO.setMobile(shippingAddressVO.getMobile());\n\t \t salesOrderShippingAddressDTO.setTelephone(shippingAddressVO.getTelephone());\n\t \t salesOrderShippingAddressDTO.setZip(shippingAddressVO.getZip());\n\t \t salesOrderShippingAddressDAO.insertSalesOrderShippingAddress(salesOrderShippingAddressDTO);\n\t \t }\n\t }\n\t \n\t ItemDTO itemDTO = new ItemDTO();\n\t SupplierItemDTO supplierItemDTO = new SupplierItemDTO();\n\t SalesOrderLineDTO salesOrderLineDTO = new SalesOrderLineDTO();\n\t if (generateType.equals(\"quickBuy\")) {\n\t generateQuickBuyOrder(itemCount,cartIDs, itemID, supplierID, objID, salesOrderDTO, itemDTO, supplierItemDTO,\n\t salesOrderLineDTO);\n\n\t } else if (generateType.equals(\"oneKey\")) {\n\t generateOneKeyOrder(customerID, itemCount, itemType, objID, salesOrderDTO, itemDTO, supplierItemDTO,\n\t salesOrderLineDTO);\n\n\t } else if (generateType.equals(\"shoppingcart\")) {\n\t genarateShoppingCartOrder(customerID, cartIDs, itemCount, itemType, objID, salesOrderDTO, itemDTO,\n\t supplierItemDTO, salesOrderLineDTO);\n\t } else {\n\t throw new Exception(\"订单类型无法确定\");\n\t }\n\t\t}\n return ordersList;\n }", "public static void ProcessTransaction(){\r\n\t Iterator<String> iter = masterEventsFile.iterator();\r\n\t //this uses the deletePastEvents method to delete all the past events in the masterEventsFile\r\n\t while (iter.hasNext()){\r\n\t\t String e = iter.next();\r\n\t \r\n\t //for (String e : masterEventsFile){\r\n\t\t Event CheckEvent = new Event(e);\r\n\t\t boolean pastDate = deletePastEvents(CheckEvent);\r\n\t\t if (!pastDate){\r\n\t\t\t break;\r\n\t\t } \r\n\t }\r\n\t //makes each line of the masterEventFile into an Event object for easier processing\r\n\t for (String e : masterEventsFile){\r\n\t\t Event event = new Event(e);\r\n\t\t alteredEventsFile.add(event);\r\n\t }\r\n\t //makes each line into a Transaction object for easier processing\r\n\t for (String t: mergedEventTransactionFile){\r\n\t\t Transaction transaction= new Transaction(t);\r\n\t\t allTransactions.add(transaction);\r\n\t }\r\n\t \r\n\t //Iterates through each Transaction processing them one at a time based on their id\r\n\t for (Transaction t: allTransactions){\r\n\t\t //process sell, return, create, add, delete,end\r\n\t\t if(t.id == 00){\r\n\t\t\t break;\r\n\t\t }\r\n\t\t Event changeEvent = findEvent(t.name);\r\n\t\t if (changeEvent != null){\r\n\t\t\t if (t.id == 01){\t\t\t\t\t\t//sell transaction\r\n\t\t\t\t if((changeEvent.ticket -t.ticket)<0){\r\n\t\t\t\t\t System.out.println(\"Sell transaction could not be performed, not enough tickets\"); //Contraints: no event should ever have a negative nmber of ticekts\r\n\t\t\t\t }else{\r\n\t\t\t\t\t changeEvent.ticket = changeEvent.ticket -t.ticket;\r\n\t\t\t\t }\r\n\t\t\t }else if (t.id == 02){\t\t\t\t//return transaction\r\n\t\t\t\t changeEvent.ticket =changeEvent.ticket + t.ticket;\r\n\t\t\t }else if (t.id == 04){\t\t\t\t//add transaction\r\n\t\t\t\t changeEvent.ticket += t.ticket;\t\r\n\t\t\t }else if (t.id == 05){\t\t\t\t//delete transaction\r\n\t\t\t\t changeEvent = null;\r\n\t\t\t }\r\n\t\t }else{\t\t\t\t\t\t\t\t//constraint: a new event must have a name different from all existing events\r\n\t\t\t if(t.id == 03){\t\t\t\t\t\t//create transaction\r\n\t\t\t\t Event newEvent = new Event (t.getEventLine());\r\n\t\t\t\t InsertEvent(newEvent);\t\t//constraint: <asterEventFile must be kept in ascending order by date\r\n\t\t\t }\r\n\t\t }\r\n\t }\r\n\t \r\n\t String newMasterEventsFile = \"\";\r\n\t String newCurrentEventsFile = \"\"\r\n\t\t\t ;\r\n\t // creates two strings in proper format for output to currenteventsFile and MasterEventsFile\r\n\t for (Event e: alteredEventsFile){\t\t\t\t\t\t\t\t//assumes correct input... constraint:every line is exactly 33 characters(plus newline)\r\n\t\t newMasterEventsFile += e.getEventLine() +\"\\n\";\r\n\t\t newCurrentEventsFile += e.getCurrentEventLine() + \"\\n\";\r\n\t }\r\n\t \r\n\t //does file output stuff\r\n\t try{\r\n\t\t endBackEnd(newMasterEventsFile, newCurrentEventsFile);\r\n\t\t} catch (Exception e) {\r\n\t\t\t// TODO Auto-generated catch block\r\n\t\t\te.printStackTrace();\r\n\t\t}\r\n }", "@Override\n\tpublic void allocateorder(Block block) {\n\t\tint executedQty=(int) block.getQtyExecuted();\n\t\tList<Order> list = new ArrayList<Order>();\n\t\tQuery query = em.createQuery(\"from Order where blockId = :id order by orderDate\");\n\t\tquery.setParameter(\"id\", block.getBlockId());\n\t\tlist = query.getResultList();\n\t\tfor (Order order1 : list) {\n\t\tint q=order1.getQtyPlaced();\n\t\tStatus status = null;\n\t\t\tif((q<= executedQty) && (executedQty>0))\n\t\t\t{\n\t\t\t\tSystem.out.println(em);\n\t\t\t\tSystem.out.println(\"Inside first loop\");\n\t\t\t\tSystem.out.println(q);\n\t\t\t\texecutedQty=executedQty-q;\n\t\t\t\t\n\t\t\t\tQuery query1 = em.createQuery(\"Update Order set qtyExecuted=:qty1, status=:status1 where orderId=:oid\");\n\t\t\t\tquery1.setParameter(\"qty1\",q);\n\t\t\t\tquery1.setParameter(\"status1\",status.Completed.toString());\n\t\t\t\tquery1.setParameter(\"oid\",order1.getOrderId());\n\t\t\t\tSystem.out.println(query1.executeUpdate());\n\t\t\t\tSystem.out.println(executedQty + q);\n\t\t\t\t//query1.executeUpdate();\n\n\t\t\t}\n\t\t\telse if(q>=executedQty && executedQty>0){\n\t\t\t\texecutedQty=q-executedQty;\n\t\t\t\tSystem.out.println(\"Inside second loop\");\n\t\t\t\tQuery query1 = em.createQuery(\"Update Order set qtyExecuted=:qty2, status=:status2 where orderId=:oid\");\n\t\t\t\tquery1.setParameter(\"qty2\",executedQty);\n\t\t\t\tquery1.setParameter(\"status2\", status.PartiallyAllocated.toString());\n\t\t\t\tquery1.setParameter(\"oid\",order1.getOrderId());\n\t\t\t\tSystem.out.println(query1.executeUpdate());\n\t\t\t\t//query1.executeUpdate();\n\t\t\t\texecutedQty=0;\n\t\t\t\tSystem.out.println(executedQty);\n\t\t\t}\n\t\t\telse{\n\t\t\t\tQuery query2 = em.createQuery(\"update Order set status=:status3 where orderId=:oid\");\n\t\t\t\tquery2.setParameter(\"status3\", status.Open.toString());\n\t\t\t\tquery2.setParameter(\"oid\",order1.getOrderId());\n\t\t\t\tSystem.out.println(query2.executeUpdate());\n\t\t\t\t//query2.executeUpdate();\n\t\t\t}}\n\t\tSystem.out.println(\"Inside OrderDAO\");\n\n\t\t\n\t}", "public static void updatePosition() {\n\t\tfor (int i = 0; i < TitanV4.planets.length; i++) { //compute forces between all celestial corpses\n\t\t\tfor(int j=i; j<TitanV4.planets.length; j++){\n\t\t\t\tif (i != j) {\n\t\t\t\t\tdouble upper = TitanV4.G*TitanV4.planets[i].getMass() * TitanV4.planets[j].getMass();\n\t\t\t\t\tdouble lower = TitanV4.planets[i].getPosition().distanceFrom(TitanV4.planets[j].getPosition());\n\t\t\t\t\tdouble gravitation = upper/lower;\n\t\t\t\t\tVector a = new Vector();\n\t\t\t\t\ta = TitanV4.planets[i].getPosition().substract(TitanV4.planets[j].getPosition()).normalize().multiply(-1);\n\n\t\t\t\t\tTitanV4.planets[i].force.add(a.multiply(gravitation));\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\t//compute acceleration vector for each celestial corpse but the sun\n\t\tfor(int i=1; i<TitanV4.planets.length; i++){\n\t\t\tTitanV4.planets[i].acceleration = (TitanV4.planets[i].force.divide(TitanV4.planets[i].getMass()));\n\t\t}\n\n\t\t//calculate change in speed over deltaT\n\t\tfor(int i=1; i<TitanV4.planets.length; i++){\n\t\t\tVector oldVelocity = new Vector(TitanV4.planets[i].velocity);\n\t\t\tTitanV4.planets[i].velocity.add((TitanV4.planets[i].acceleration.multiply(TitanV4.deltaT)));\n\n\t\t\tVector posChange = new Vector();\n\t\t\tposChange = (oldVelocity.add(velocity).divide(2)).multiply(TitanV4.deltaT);\n\t\t\tTitanV4.planets[i].pos.add(posChange);\n\t\t}\n\t}", "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 }", "@Transactional\n @Override\n public StringBuffer addSalesOrderTparts(String customerID, String cartIDs, String addressID, String paymentType,\n String orderAmount, String scoreAll, String memo, String itemCount, String itemID,\n String supplierID, String itemType, String orderType, String objID, String invoiceType,\n String invoiceTitle, String generateType, String orderID,String memoIDs,String allFreight, String supplierFreightStr) throws Exception {\n \t\n String ids[] = cartIDs.split(\",\");\n String memos[] = memoIDs.split(\",\");\n List<ShoppingCartVO> shopCartList = new ArrayList<ShoppingCartVO>();\n for (String id : ids) {\n ShoppingCartVO shoppingCartVO = shoppingCartDAO.findShoppingCartByID(Long.valueOf(id));\n shopCartList.add(shoppingCartVO);\n }\n Map<String,List<ShoppingCartVO>> maps = new HashMap<String,List<ShoppingCartVO>>();\n for(ShoppingCartVO s:shopCartList){\n \tList<ShoppingCartVO> temp = new ArrayList<ShoppingCartVO>();\n \t String sid1= s.getSupplierID();\n String siname1= s.getSupplierName();\n for(ShoppingCartVO shoppingCartVO1 : shopCartList){\n \t//当前店铺对应的购物车集合\n \tString sid2 = shoppingCartVO1.getSupplierID();\n \tif(sid1.equals(sid2)){\n \t\ttemp.add(shoppingCartVO1);\n \t}\n }\n maps.put(sid1+\"_\"+siname1, temp);\n }\n \n //根据物流模板计算运费\n Map<String, Double> supplierFreightMap = new HashMap<String, Double>();\n String[] supplierFreightAll = null;\n if(StringUtil.isNotEmpty(supplierFreightStr))\n {\n \tsupplierFreightAll = supplierFreightStr.split(\"\\\\|\");\n for (int i = 0; i < supplierFreightAll.length; i++) {\n \tString[] supplierFreight = supplierFreightAll[i].split(\":\");\n \tsupplierFreightMap.put(supplierFreight[0], Double.parseDouble(supplierFreight[1]));\n \t\t} \t\n }\n \n \n StringBuffer ordersList = new StringBuffer();\n int num = 0;\n// cachedClient.delete(customerID + orderID);\n Set<String> set = maps.keySet();\n\t\tfor(String string : set){\n\t\t List<ShoppingCartVO> temp1= maps.get(string);\n\t\t double supplierFreight = 0d;\n\t\t if(supplierFreightMap.size()>0)\n\t\t {\n\t\t\t supplierFreight = supplierFreightMap.get(string);\n\t\t }\n\t\t Double amount = 0d;\n\t\t Integer count = 0;\n Integer score = 0;\n Double weight = 0d;\n\t\t for (ShoppingCartVO shoppingCartVO : temp1) {\n ItemVO itemVO = itemDAO.findItemById(shoppingCartVO.getItemID());\n count += shoppingCartVO.getItemCount();\n // weight += itemVO.getWeight();\n if (shoppingCartVO.getType() == 1) {\n amount += shoppingCartVO.getItemCount() * shoppingCartVO.getSalesPrice();\n } else if (shoppingCartVO.getType() == 2) {\n score += shoppingCartVO.getItemCount() * itemVO.getScore();\n } else if (shoppingCartVO.getType() == 3) {\n amount += shoppingCartVO.getItemCount() * itemVO.getScorePrice();\n score += shoppingCartVO.getItemCount() * shoppingCartVO.getSalesScore();\n }\n }\n\t\t //SalesOrderVO tempOrder = new SalesOrderVO();\n\t /*if (tempOrder == null) {\n\t throw new Exception(\"参数错误\");\n\t }\n\t if (\"012\".indexOf(invoiceType) == -1) {\n\t throw new Exception(\"参数错误\");\n\t }*/\n\t SalesOrderDTO salesOrderDTO = new SalesOrderDTO();\n\t salesOrderDTO.setMainID(randomNumeric());\n\t salesOrderDTO.setCustomerID(customerID);\n\t salesOrderDTO.setPaymentType(Integer.valueOf(paymentType));\n\t salesOrderDTO.setPaymentStatus(0);\n\n\t // salesOrderDTO.setExpressFee(tempOrder.getExpressFee());//运费\n\t salesOrderDTO.setProductAmount(amount);\n\t salesOrderDTO.setTotalAmount(amount + supplierFreight);\n\t salesOrderDTO.setPayableAmount(amount);\n\n\t salesOrderDTO.setOrderType(Integer.valueOf(orderType));\n\t salesOrderDTO.setMemo(getMemoBySupplier(memos,string.split(\"_\")[0]));\n\t salesOrderDTO.setInvoiceType(Integer.parseInt(invoiceType));\n\t salesOrderDTO.setInvoiceTitle(invoiceTitle);\n\t salesOrderDTO.setSupplierID(string);\n\t salesOrderDTO.setExpressFee(supplierFreight);\n\t salesOrderDAO.addSalesOrder(salesOrderDTO);\n\t ordersList.append(salesOrderDTO.getMainID()+\",\");\n\t // 支付方式1:余额支付2:货到付款3:在线支付4:积分礼品5:线下汇款\n\t if(!paymentType.equals(\"3\")){\n\t \t//3:在线支付\n\t \t CustomerDeliveryAddressVO customerDeliveryAddressVO = customerDeliveryAddressDAO.findAddressByID(Long.valueOf(addressID));\n\t \t if (customerDeliveryAddressVO != null) {\n\t \t SalesOrderDeliveryAddressDTO salesOrderDeliveryAddressDTO = new SalesOrderDeliveryAddressDTO();\n\t \t salesOrderDeliveryAddressDTO.setSalesOrderID(salesOrderDTO.getMainID());\n\t \t salesOrderDeliveryAddressDTO.setName(customerDeliveryAddressVO.getName());\n\t \t salesOrderDeliveryAddressDTO.setCountryID(customerDeliveryAddressVO.getCountryID());\n\t \t salesOrderDeliveryAddressDTO.setProvinceID(customerDeliveryAddressVO.getProvinceID());\n\t \t salesOrderDeliveryAddressDTO.setCityID(customerDeliveryAddressVO.getCityID());\n\t \t salesOrderDeliveryAddressDTO.setDisctrictID(customerDeliveryAddressVO.getDisctrictID());\n\t \t salesOrderDeliveryAddressDTO.setAddress(customerDeliveryAddressVO.getAddress());\n\t \t salesOrderDeliveryAddressDTO.setMobile(customerDeliveryAddressVO.getMobile());\n\t \t salesOrderDeliveryAddressDTO.setTelephone(customerDeliveryAddressVO.getTelephone());\n\t \t if (customerDeliveryAddressVO.getZip() != null) {\n\t \t salesOrderDeliveryAddressDTO.setZip(customerDeliveryAddressVO.getZip());\n\t \t }\n\t \t salesOrderDeliveryAddressDAO.insertSalesOrderDeliveryAddress(salesOrderDeliveryAddressDTO);\n\t \t }\n\t \t ShippingAddressVO shippingAddressVO = shippingAddressDAO.findDefaultShippingAddress();\n\t \t if (shippingAddressVO != null) {\n\t \t SalesOrderShippingAddressDTO salesOrderShippingAddressDTO = new SalesOrderShippingAddressDTO();\n\t \t salesOrderShippingAddressDTO.setSalesOrderID(salesOrderDTO.getMainID());\n\t \t salesOrderShippingAddressDTO.setName(shippingAddressVO.getName());\n\t \t salesOrderShippingAddressDTO.setCountryID(shippingAddressVO.getCountryID());\n\t \t salesOrderShippingAddressDTO.setProvinceID(shippingAddressVO.getProvinceID());\n\t \t salesOrderShippingAddressDTO.setCityID(shippingAddressVO.getCityID());\n\t \t salesOrderShippingAddressDTO.setDisctrictID(shippingAddressVO.getDisctrictID());\n\t \t salesOrderShippingAddressDTO.setAddress(shippingAddressVO.getAddress());\n\t \t salesOrderShippingAddressDTO.setMobile(shippingAddressVO.getMobile());\n\t \t salesOrderShippingAddressDTO.setTelephone(shippingAddressVO.getTelephone());\n\t \t salesOrderShippingAddressDTO.setZip(shippingAddressVO.getZip());\n\t \t salesOrderShippingAddressDAO.insertSalesOrderShippingAddress(salesOrderShippingAddressDTO);\n\t \t }\n\t }\n\t \n\t ItemDTO itemDTO = new ItemDTO();\n\t SupplierItemDTO supplierItemDTO = new SupplierItemDTO();\n\t SalesOrderLineDTO salesOrderLineDTO = new SalesOrderLineDTO();\n\t if (generateType.equals(\"quickBuy\")) {\n\t generateQuickBuyOrder(itemCount,cartIDs, itemID, supplierID, objID, salesOrderDTO, itemDTO, supplierItemDTO,\n\t salesOrderLineDTO);\n\n\t } else if (generateType.equals(\"oneKey\")) {\n\t generateOneKeyOrder(customerID, itemCount, itemType, objID, salesOrderDTO, itemDTO, supplierItemDTO,\n\t salesOrderLineDTO);\n\n\t } else if (generateType.equals(\"shoppingcart\")) {\n\t \tgenarateShoppingCartOrderTparts(customerID, cartIDs, itemCount, itemType, objID, salesOrderDTO, itemDTO,\n\t supplierItemDTO, salesOrderLineDTO);\n\t } else {\n\t throw new Exception(\"订单类型无法确定\");\n\t }\n\t num++;\n\t\t}\n return ordersList;\n }", "public void insertOrderedItems(TireList orderedItems){\n for(int i=0; i<orderedItems.listSize(); i++){\n int temp = Integer.parseInt(orderedItems.getTire(i).getStock()) - orderedItems.getTire(i).getQuantity();\n orderedItems.getTire(i).setStock(temp + \"\");\n orderedItems.getTire(i).updateTire();\n sql=\"Insert into OrderedItems (OrderID, TireID, Quantity) VALUES ('\"+newID+\"','\"+orderedItems.getTire(i).getStockID()+\"',\"+orderedItems.getTire(i).getQuantity()+\")\";\n db.insertDB(sql); \n }\n }", "public void update() \n\t{\n\t\tString inst = \"\";\n\t\tfloat cash = getCash();\n\t\tfloat quantity = getPosition(inst);\n\t\tfloat price = getPrice(inst);\n\n\t\t_data.add(new Float(price));\n\t\t\n\t\tif (_data.size() > _period)\n\t\t{\n\t\t\t_data.remove(0);\n\t\t\n\t\t\tfloat min = Float.MAX_VALUE;\n\t\t\tfloat max = Float.MIN_VALUE;\n\t\t\t\n\t\t\tfor (int i = 0; i < _data.size(); i++)\n\t\t\t{\n\t\t\t\tFloat value = (Float)_data.get(i);\n\t\t\t\t\n\t\t\t\tif (value.floatValue() > max)\n\t\t\t\t{\n\t\t\t\t\tmax = value.floatValue();\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\tif (value.floatValue() < min)\n\t\t\t\t{\n\t\t\t\t\tmin = value.floatValue();\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\tfloat buylevel = min + (min * _minwin);\n\t\t\tfloat sellevel = max - (max * _maxloss);\n\t\t\tfloat sellevel2 = min + (min * _maxwin);\n\t\t\t\n\t\t\t// if price has risen by min win\n\t\t\t// but is below maximum win and\n\t\t\t// below maximum loss then buy\n\t\t\tif (price > buylevel && \n\t\t\t\t\tprice < sellevel2 &&\n\t\t\t\t\tbuylevel < sellevel &&\n\t\t\t\t\tprice > _previous)\n\t\t\t{\n\t\t\t\tif (cash > 0) \n\t\t\t\t{\n\t\t\t\t\taddAmountOrder(inst, cash);\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\tif (price < sellevel &&\n\t\t\t\t\tbuylevel > sellevel &&\n\t\t\t\t\tprice < _previous)\n\t\t\t{\n\t\t\t\tif (quantity > 0)\n\t\t\t\t{\n\t\t\t\t\taddQuantityOrder(inst, -quantity);\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tif (price > sellevel2 &&\n\t\t\t\t\tprice > _previous)\n\t\t\t{\n\t\t\t\tif (quantity > 0)\n\t\t\t\t{\n\t\t\t\t\taddQuantityOrder(inst, -quantity);\n\t\t\t\t}\t\t\t\n\t\t\t}\n\t\t\t\n\t\t\t_data.remove(0);\n\t\t}\n\t\t\n\t\t_previous = price;\n\t}", "<E extends CtElement> E setPositions(SourcePosition position);", "public void updatePositioningData(PositioningData data);", "Position_changerOrdonnee createPosition_changerOrdonnee();", "public void soin() {\n if (!autoriseOperation()) {\n return;\n }\n if (tamagoStats.getXp() >= 2) {\n incrFatigue(-3);\n incrHumeur(3);\n incrFaim(-3);\n incrSale(-3);\n incrXp(-2);\n\n if (tamagoStats.getPoids() == 0) {\n incrPoids(3);\n } else if (tamagoStats.getPoids() == TamagoStats.POIDS_MAX) {\n incrPoids(-3);\n }\n\n setEtatPiece(Etat.NONE);\n tamagoStats.setEtatSante(Etat.NONE);\n\n setChanged();\n notifyObservers();\n }\n }", "@Override\r\n\tpublic void updatePosition(int id, float[] pos) {\n\r\n\t}", "@Override\n void procesarSalida(Simulacion s, Evento e) {\n e.consulta.estadistEjec_Sentencias.tiempoSalidaModulo = e.tiempo;\n e.consulta.estadistEjec_Sentencias.tiempoEnModulo = e.tiempo - e.consulta.estadistEjec_Sentencias.tiempoLlegadaModulo;\n Evento evento = new Evento(e.consulta);\n evento.tipoE = Evento.TipoEvento.ENTRADA;\n evento.modulo = Evento.TipoModulo.ADM_CONEXIONES;\n evento.tiempo = e.tiempo;\n numServOcupados--;\n s.listaE.add(evento);\n\n if (!colaC.isEmpty()) { //Si despues de una salida hay algo en cola\n Consulta consulta = colaC.remove();\n consulta.estadistEjec_Sentencias.tiempoSalidaCola = e.tiempo - consulta.estadistEjec_Sentencias.tiempoLlegadaModulo;\n s.estadisticasT.promedioColaES += colaC.size();\n Evento eventoS = new Evento(consulta);\n eventoS.tipoE = Evento.TipoEvento.SALIDA;\n eventoS.modulo = Evento.TipoModulo.EJEC_SENTENCIAS;\n ejecucionSentencia(consulta);\n eventoS.tiempo = e.tiempo + tiempoEjecucion;\n s.listaE.add(eventoS);\n numServOcupados++;\n }\n\n }", "@Override\n\tpublic int update(Forge_Order_Detail t) {\n\t\treturn 0;\n\t}", "ch.crif_online.www.webservices.crifsoapservice.v1_00.OrganizationPositionList addNewOrganizationPositionList();", "public void updatePosition() {\n \t\r\n \tx += dx;\r\n \ty += dy;\r\n \t\r\n\t}", "public DetonationPdu(edu.nps.moves.jaxb.dis.DetonationPdu x)\n {\n super(x); // Call superclass constructor\n\n\n edu.nps.moves.dis.EntityID foo_0;\n if(x.getMunitionID() == null)\n foo_0 = new edu.nps.moves.dis.EntityID();\n else\n foo_0 = new edu.nps.moves.dis.EntityID(x.getMunitionID() );\n this.setMunitionID(foo_0);\n\n\n edu.nps.moves.dis.EventID foo_1;\n if(x.getEventID() == null)\n foo_1 = new edu.nps.moves.dis.EventID();\n else\n foo_1 = new edu.nps.moves.dis.EventID(x.getEventID() );\n this.setEventID(foo_1);\n\n\n edu.nps.moves.dis.Vector3Float foo_2;\n if(x.getVelocity() == null)\n foo_2 = new edu.nps.moves.dis.Vector3Float();\n else\n foo_2 = new edu.nps.moves.dis.Vector3Float(x.getVelocity() );\n this.setVelocity(foo_2);\n\n\n edu.nps.moves.dis.Vector3Double foo_3;\n if(x.getLocationInWorldCoordinates() == null)\n foo_3 = new edu.nps.moves.dis.Vector3Double();\n else\n foo_3 = new edu.nps.moves.dis.Vector3Double(x.getLocationInWorldCoordinates() );\n this.setLocationInWorldCoordinates(foo_3);\n\n\n edu.nps.moves.dis.BurstDescriptor foo_4;\n if(x.getBurstDescriptor() == null)\n foo_4 = new edu.nps.moves.dis.BurstDescriptor();\n else\n foo_4 = new edu.nps.moves.dis.BurstDescriptor(x.getBurstDescriptor() );\n this.setBurstDescriptor(foo_4);\n\n this.detonationResult = x.getDetonationResult();\n this.numberOfArticulationParameters = x.getNumberOfArticulationParameters();\n this.pad = x.getPad();\n this.articulationParameters = new ArrayList();\n for(int idx = 0; idx < x.getArticulationParameters().size(); idx++)\n {\n this.articulationParameters.add( new edu.nps.moves.dis.ArticulationParameter((edu.nps.moves.jaxb.dis.ArticulationParameter) x.getArticulationParameters().get(idx)));\n }\n }", "private String insertarCartaVitalTransfusion() {\n int[] valoresEnemigo = {\n// this.dañoEnemigo=valoresEnemigo[0];\n 3,\n// this.curaEnemigo=valoresEnemigo[1];\n 0,\n// this.cartasEnemigo=valoresEnemigo[2];\n 0,\n// this.descarteEnemigo=valoresEnemigo[3];\n 0,\n// this.recursosEnemigo=valoresEnemigo[4];\n 0,\n// this.moverMesaAManoEnemigo=valoresEnemigo[5];\n 0,\n// this.moverDescarteAManoEnemigo=valoresEnemigo[6];\n 0,\n// this.moverDeckAManoEnemigo=valoresEnemigo[7];\n 0,\n// this.moverMesaADeckEnemigo=valoresEnemigo[8];\n 0,\n// this.moverDescarteADeckEnemigo=valoresEnemigo[9];\n 0,\n// this.moverManoADeckEnemigo=valoresEnemigo[10];\n 0,\n// this.moverMesaADescarteEnemigo=valoresEnemigo[11];\n 0,\n// this.moverManoADescarteEnemigo=valoresEnemigo[12];\n 0,\n// this.moverDeckADescarteEnemigo=valoresEnemigo[13];\n 0,\n// this.moverDescarteAMesaEnemigo=valoresEnemigo[14];\n 0,\n// this.moverManoAMesaEnemigo=valoresEnemigo[15];\n 0,\n// this.moverDeckAMesaEnemigo=valoresEnemigo[16];\n 0\n };\n int[] valoresOwner = {\n// this.dañoOwner=valoresOwner[0];\n 0,\n// this.curaOwner=valoresOwner[1];\n 2,\n// this.cartasOwner=valoresOwner[2];\n 0,\n// this.descarteOwner=valoresOwner[3];\n 0,\n// this.recursosOwner=valoresOwner[4];\n 0,\n// this.moverMesaAManoOwner=valoresOwner[5];\n 0,\n// this.moverDescarteAManoOwner=valoresOwner[6];\n 0,\n// this.moverDeckAManoOwner=valoresOwner[7];\n 0,\n// this.moverMesaADeckOwner=valoresOwner[8];\n 0,\n// this.moverDescarteADeckOwner=valoresOwner[9];\n 0,\n// this.moverManoADeckOwner=valoresOwner[10];\n 0,\n// this.moverMesaADescarteOwner=valoresOwner[11];\n 0,\n// this.moverManoADescarteOwner=valoresOwner[12];\n 0,\n// this.moverDeckADescarteOwner=valoresOwner[13];\n 0,\n// this.moverDescarteAMesaOwner=valoresOwner[14];\n 0,\n// this.moverManoAMesaOwner=valoresOwner[15];\n 0,\n// this.moverDeckAMesaOwner=valoresOwner[16];\n 0\n };\n boolean[]valoresPlay={\n //this.OnMoveMesaADescarte=valoresPlay[0];\n false,\n //this.OnMoveMesaADeck=valoresPlay[1];\n false,\n //this.OnMoveMesaAMano=valoresPlay[2];\n false,\n //this.OnMoveDescarteAMesa=valoresPlay[3];\n false,\n //this.OnMoveDescarteADeck=valoresPlay[4];\n false,\n// this.OnMoveDescarteAMano=valoresPlay[5];\n false,\n// this.OnMoveDeckADescarte=valoresPlay[6];\n false,\n// this.OnMoveDeckAMesa=valoresPlay[7];\n false,\n// this.OnMoveDeckAMano=valoresPlay[8];\n false,\n// this.OnMoveManoADescarte=valoresPlay[9];\n false,\n// this.OnMoveManoAMesa=valoresPlay[10];\n true,\n// this.OnMoveManoADeck=valoresPlay[11];\n false,\n// this.OnStartTurnTable=valoresPlay[12];\n false,\n// this.OnStartTurnHand=valoresPlay[13];\n false,\n// this.OnStartTurnDiscard=valoresPlay[14];\n false,\n// this.OnStartTurnDeck=valoresPlay[15];\n false,\n// this.OnEndTurnTable=valoresPlay[16];\n false,\n// this.OnEndTurnHand=valoresPlay[17];\n false,\n// this.OnEndTurnDiscard=valoresPlay[18];\n false,\n// this.OnEndTurnDeck=valoresPlay[19];\n false,\n };\n ArrayList<Integer> datos = new ArrayList<Integer>();\n String nombre = \"\";\n for (int i = 0; i < valoresEnemigo.length; i++) {\n datos.add(valoresEnemigo[i]);\n }\n for (int i = 0; i < valoresOwner.length; i++) {\n datos.add(valoresOwner[i]);\n }\n for (int i = 0; i < valoresPlay.length; i++) {\n if(valoresPlay[i]){\n datos.add(1);\n }else{\n datos.add(0);\n }\n }\n String insert=\"\";\n for(int i=0;i<datos.size();i++){\n if(i<datos.size()-1) {\n insert += datos.get(i) + \", \";\n }else{\n insert += datos.get(i) + \" )\";\n }\n }\n return insert;\n }", "Position getNewPosition();", "public void initShop(){\n addCountToStorage(actionProduct.findProductByName(\"Jemeson\"), 3);\n addCountToStorage(actionProduct.findProductByName(\"Red Label\"), 5);\n addCountToStorage(actionProduct.findProductByName(\"Burenka\"), 10);\n addCountToStorage(actionProduct.findProductByName(\"Kupyanskoe\"), 21);\n\n //add transaction\n int idxCustomer = actionCustomer.findCustomerByName(\"Perto\");\n int idxProduct = actionProduct.findProductByName(\"Burenka\");\n\n addTransaction(idxCustomer, idxProduct, getDate(-7), 1 , actionProduct.getPriceByIdx(idxProduct));\n\n idxProduct = actionProduct.findProductByName(\"white bread\");\n addTransaction(idxCustomer, idxProduct, getDate(-7), 1 , actionProduct.getPriceByIdx(idxProduct));\n\n idxCustomer = actionCustomer.findCustomerByName(\"Dmytro\");\n addTransaction(idxCustomer, idxProduct, getDate(-6), 2 , actionProduct.getPriceByIdx(idxProduct));\n\n idxProduct = actionProduct.findProductByName(\"burenka\");\n addTransaction(idxCustomer, idxProduct, getDate(-6), 2 , actionProduct.getPriceByIdx(idxProduct));\n\n\n }", "@Override\n\tpublic void posModify() {\n\t\t\n\t}", "@Override\n\tpublic void posModify() {\n\t\t\n\t}", "private void updateComponents() {\n try {\n java.sql.Date cDate = new java.sql.Date(System.currentTimeMillis());\n java.sql.Date sDate = Date.valueOf(\"1971-01-01\");\n DefaultTableModel tData = or.getOrderData(sDate,cDate);\n oTable.setModel(tData);\n setSales(tData);\n } catch (Exception ex) {\n System.out.println(ex);\n }\n }", "private void update_location() throws Exception {\r\n\t\tif (children.size() == 1) {\r\n\t\t\tCLocation bloc = children.get(0).get_location();\r\n\t\t\tthis.location = bloc.get_source().get_location(bloc.get_bias(), bloc.get_length());\r\n\t\t} else if (children.size() > 1) {\r\n\t\t\tCLocation eloc = children.get(children.size() - 1).get_location();\r\n\t\t\tint beg = this.location.get_bias(), end = eloc.get_bias() + eloc.get_length();\r\n\t\t\tthis.location.set_location(beg, end - beg);\r\n\t\t}\r\n\t}", "@Override\n\tpublic int updateInventory(int tranNo, int amount) throws Exception {\n\t\treturn 0;\n\t}", "public void updateTransaction(Transaction trans);", "public void newTransaction(){\n System.out.println(\"-----new transaction -----\");\n System.out.println(\"--no null value--\");\n List<Integer> idList =new LinkedList<>();\n List<Integer> cntList =new LinkedList<>();\n List<Double> discountList = new LinkedList<>();\n List<Double> actualPrice = new LinkedList<>();\n double totalPrice=0.0;\n System.out.print(\"cashier id: \");\n int cashierid=scanner.nextInt();\n System.out.print(\"store id: \");\n int storeid=scanner.nextInt();\n System.out.print(\"customer id: \");\n int customerid=scanner.nextInt();\n while(true){\n System.out.print(\"product id: \");\n idList.add(scanner.nextInt());\n System.out.print(\"count: \");\n cntList.add(scanner.nextInt());\n\n //support multiple product\n System.out.print(\"type y to continue(others would end): \");\n if(!scanner.next().equals('y')){\n break;\n }\n }\n\n try {\n //begin transaction\n connection.setSavepoint();\n connection.setAutoCommit(false);\n for(int i=0;i<idList.size();i++){\n //Step 1 load discount information\n String sql0=\"select * from onsaleproductions where ProductID=\"+idList.get(i)+\" and ValidDate > now()\";\n try {\n //first insert clubmemer\n result = statement.executeQuery(sql0);\n if(result.next()){\n discountList.add(result.getDouble(\"Discount\"));\n }else{\n discountList.add(1.0);\n }\n } catch (SQLException e) {\n //rollback when failed\n System.out.println(e.getMessage());\n connection.rollback();\n return;\n }\n\n // Step 2 reduce stock & judge whether the product expired or not\n String sql1=\"update merchandise set Quantity=Quantity-\"+cntList.get(i)+\" where ProductID=\"+idList.get(i)+\" and ExpirationDate > now()\";\n try {\n //first insert clubmemer\n int res = statement.executeUpdate(sql1);\n if(res==0){\n System.out.println(\"Transaction failed! No valid product found (may expired)\");\n connection.rollback();\n return;\n }\n } catch (SQLException e) {\n //rollback when failed\n System.out.println(\"Transaction failed! check product stock!\");\n connection.rollback();\n return;\n }\n\n String sql2=\"select * from merchandise where ProductID=\"+idList.get(i);\n try {\n //first insert clubmemer\n result = statement.executeQuery(sql2);\n double mprice=0.0;\n if(result.next()){\n mprice=result.getDouble(\"MarketPrice\");\n }\n actualPrice.add(mprice*discountList.get(i));\n totalPrice+=(cntList.get(i)*actualPrice.get(i));\n } catch (SQLException e) {\n //rollback when failed\n System.out.println(e.getMessage());\n connection.rollback();\n return;\n }\n }\n\n // Step 3 insert transaction record which include general information\n String sql3=\"insert into transactionrecords(cashierid,storeid,totalprice,date,customerid) values(\"+cashierid+\",\"+storeid+\",\"+totalPrice+\",now(), \"+customerid+\")\";\n int tid=0;\n try {\n //first insert clubmemer\n int res = statement.executeUpdate(sql3, Statement.RETURN_GENERATED_KEYS);\n ResultSet generatedKeys = statement.getGeneratedKeys();\n\n if (generatedKeys.next()) {\n //get generatedKeys for insert registration record\n tid=generatedKeys.getInt(\"GENERATED_KEY\");\n }\n } catch (SQLException e) {\n //rollback when failed\n System.out.println(e.getMessage());\n connection.rollback();\n return;\n }\n\n // Step 4 insert transaction contains which include product list\n for(int i=0;i<idList.size();i++){\n String sql4=\"insert into transactionContains(transactionid,productid,count,actualprice) values(\";\n sql4+=tid;\n sql4+=\", \";\n sql4+=idList.get(i);\n sql4+=\", \";\n sql4+=cntList.get(i);\n sql4+=\", \";\n sql4+=actualPrice.get(i);\n sql4+=\")\";\n try {\n //System.out.println(sql);\n int res = statement.executeUpdate(sql4);\n } catch (SQLException e) {\n //rollback when failed\n System.out.println(e.getMessage());\n connection.rollback();\n }\n\n }\n System.out.println(\"Success\");\n connection.commit();\n } catch (SQLException e) {\n System.out.println(e.getMessage());\n }finally {\n try {\n connection.setAutoCommit(true);\n } catch (SQLException e) {\n e.printStackTrace();\n }\n }\n }", "private void doPoint()\n\t{\n\t\tubisenseData = new UbisenseMockupData();\n\n\t\telapsedTime = 0;\n\t\t\n\t\tubisenseData.setTagID(Helper.DEFAULT_TAG_ID);\n\t\tubisenseData.setUnit(Helper.UBISENSE_UNIT);\n\t\tubisenseData.setOntology(Helper.LP_ONTOLOGY_URL);\n\t\tubisenseData.setVersion(Helper.UBISENSE_VERSION);\n\t\tubisenseData.setId(\"\");\n\t\tubisenseData.setSendTime(sendTime);\n\t\tubisenseData.setPosition(new Point3D(\tx1/100,\n\t\t\t\t\t\t\t\t\t\t\t\ty1/100,\n\t\t\t\t\t\t\t\t\t\t\t\t1.6));\n\t\tlong millis = startDate.getMillis();\n\t\tmillis += offset.toStandardDuration().getMillis();\n//\t\tmillis += parentOffset.toStandardDuration().getMillis();\n\n\t\twhile (elapsedTime < toolDuration && !this.terminate)\n\t\t{\n\t\t\tubisenseData.setId(String.valueOf(Helper.getRandomInt()));\n\t\t\tubisenseData.setTime(millis + (long)(elapsedTime*SLEEP_INTERVAL));\n\t\t\tEntryEvent event = new EntryEvent(this);\n\t\t\tthis.notifyListeners(event);\n\t\t\telapsedTime++;\n\t\t\ttry\n\t\t\t{\n\t\t\t\tif (speed > 0)\n\t\t\t\t\tThread.sleep(SLEEP_INTERVAL/speed);\n\t\t\t}\n\t\t\tcatch (InterruptedException e)\n\t\t\t{\n\t\t\t\te.printStackTrace();\n\t\t\t}\n\t\t}\n\n\t}", "@Override\n\tpublic void updateTransaction(Transaction transaction) {\n\t\t\n\t}", "public void actualizarPantallaJuego(float delta)\r\n {\r\n //recuadroInfoJuego.actualizarTiempo(delta); // Con esto actualizamos el tiempo del HUD\r\n\r\n // Con el siguiente ciclo actualizamos el movimiento o posicion de los monstruos\r\n for (int i=0; i < enemigos.size(); i++)\r\n {\r\n // Metodo encargado de renovar las posiciones dado un diferencial de tiempo\r\n enemigos.get(i).actualizarPosicion(delta);\r\n\r\n // En caso que el enemigo haya muerto entonces\r\n if (enemigos.get(i).haMuerto())\r\n {\r\n // Se lo pasamos al jugador contrario de modo que\r\n try\r\n {\r\n // Le enviamos un mensaje sobre que tipo de enemigo debe generar de manera aleatoria\r\n String aux = \"Transferir enemigo: \" + enemigos.get(i).getTipo() + \"\\n\";\r\n socketCliente.getOutputStream().write(aux.getBytes());\r\n }\r\n catch (Exception e)\r\n {\r\n e.printStackTrace();\r\n }\r\n\r\n // Se suma su valor en puntaje al puntaje general obtenido por el usuario\r\n recuadroInfoJuego.agregarPuntaje(enemigos.get(i).getPuntaje());\r\n\r\n // Luego, se suma uno al numero total de enemigos eliminados por el jugador\r\n recuadroInfoJuego.anotarEnemigo();\r\n\r\n // Y se elimina el monstruo de la lista de enemigos\r\n enemigos.remove(i);\r\n i = i - 1;\r\n }\r\n }\r\n\r\n // Si ya se cumplio el tiempo para generar otro monstruo entonces\r\n if (contaTiempo >= tiempoParaGeneracion)\r\n {\r\n // Agregamos un nuevo enemigo aleatorio en coordenas generadas tambien de manera aleatoria\r\n enemigos.add(new Monstruo(MathUtils.random(0, MainGame.ANCHO_VIRTUAL), MathUtils.random(0, MainGame.ALTO_VIRTUAL), MathUtils.random(1,5), true));\r\n\r\n // Y reseteamos el contador de tiempo\r\n contaTiempo = 0;\r\n }\r\n\r\n // O si se detecto que me pasaron un monstruo entonces\r\n if (enemigoTransferido != -1)\r\n {\r\n // Genero el tipo de monstruo especificado en coordenadas aleatorias\r\n enemigos.add(new Monstruo(MathUtils.random(0, MainGame.ANCHO_VIRTUAL), MathUtils.random(0, MainGame.ALTO_VIRTUAL), enemigoTransferido, true));\r\n\r\n // Y reinicio el dectector de monstruos tranferidos\r\n enemigoTransferido = -1;\r\n }\r\n\r\n contaTiempo = contaTiempo + delta; // Por ultimo se cuenta el tiempo\r\n }", "public Integer addPosition(Position1 pos) {\n\n //the new User's id\n Integer id = null;\n\n Session session = ConnectionFactory.getInstance().getSession();\n\n Transaction tx = null;\n\n try {\n\n tx = session.beginTransaction();\n\n session.saveOrUpdate(pos);\n tx.commit();\n\n\n } catch (HibernateException e) {\n try {\n tx.rollback(); //error\n } catch (HibernateException he) {\n System.err.println(\"Hibernate Exception\" + e.getMessage());\n throw new RuntimeException(e);\n }\n System.err.println(\"Hibernate Exception\" + e.getMessage());\n throw new RuntimeException(e);\n } /*\n * Regardless of whether the above processing resulted in an Exception\n * or proceeded normally, we want to close the Hibernate session. When\n * closing the session, we must allow for the possibility of a Hibernate\n * Exception.\n *\n */ finally {\n if (session != null) {\n try {\n\n session.close();\n } catch (HibernateException e) {\n System.err.println(\"Hibernate Exception\" + e.getMessage());\n throw new RuntimeException(e);\n }\n\n }\n }\n return id;\n }", "public void addSequencesToGraphs(){\r\n\t\t\r\n\t\t\r\n\t\tgraphSingleOutput.addSequence(\"Firm\"+firmList.get(firmList.size()-1).firmID, new SetSingleOutput(firmList.get(firmList.size()-1).firmID));\r\n\t\t\r\n\t\tgraphSinglePrice.addSequence(\"Firm\"+firmList.get(firmList.size()-1).firmID, new SetSinglePrice(firmList.get(firmList.size()-1).firmID));\r\n\t\tgraphSingleQuality.addSequence(\"Firm\"+firmList.get(firmList.size()-1).firmID, new SetSingleQuality(firmList.get(firmList.size()-1).firmID));\r\n\t\tgraphSingleFirmLocations.addSequence(\"Firm\"+firmList.get(firmList.size()-1).firmID, new SetSingleNumLocations(firmList.get(firmList.size()-1).firmID));\r\n\t graphSingleProbability.addSequence(\"Inno prob Firm\"+firmList.get(firmList.size()-1).firmID, new SetSingleInnoProbability(firmList.get(firmList.size()-1).firmID));\r\n\t graphSingleProbability.addSequence(\"Imi Prob Firm\"+firmList.get(firmList.size()-1).firmID, new SetSingleImiProbability(firmList.get(firmList.size()-1).firmID));\r\n\t graphSinglelProfit.addSequence(\"Firm\"+firmList.get(firmList.size()-1).firmID, new SetSingleProfit(firmList.get(firmList.size()-1).firmID));\r\n\t graphSingleQualityConcept.addSequence(\"Firm\"+firmList.get(firmList.size()-1).firmID, new SetSingleQualityConcept(firmList.get(firmList.size()-1).firmID));\r\n\t graphCumProfit.addSequence(\"Firm\"+firmList.get(firmList.size()-1).firmID, new SetCumProfit(firmList.get(firmList.size()-1).firmID));\r\n\t \r\n\t firmList.get(firmList.size()-1).x_coord = freeCoordinates.get(0).xCo;\r\n\t firmList.get(firmList.size()-1).y_coord = freeCoordinates.get(0).yCo;\r\n\t freeCoordinates.remove(0);\r\n\t \r\n\t\t\r\n\t}", "private void updateInventory(List<Item> items) {\r\n for(Item item : items) {\r\n inventory.put(item, STARTING_INVENTORY);\r\n inventorySold.put(item, 0);\r\n itemLocations.put(item.getSlot(), item);\r\n }\r\n }", "public void setPosition(Position pos) {\n \tthis.position = pos;\n \t//setGrade();\n }", "private void updateTransaction() {\n LogUtils.logEnterFunction(Tag);\n\n String inputtedAmount = etAmount.getText().toString().trim().replaceAll(\",\", \"\");\n if (inputtedAmount.equals(\"\") || Double.parseDouble(inputtedAmount) == 0) {\n etAmount.setError(getResources().getString(R.string.Input_Error_Amount_Empty));\n return;\n }\n\n if (mAccount == null) {\n ((ActivityMain) getActivity()).showError(getResources().getString(R.string.Input_Error_Account_Empty));\n return;\n }\n\n Double amount = Double.parseDouble(inputtedAmount);\n int categoryId = mCategory != null ? mCategory.getId() : 0;\n String description = tvDescription.getText().toString();\n int accountId = mAccount.getId();\n String strEvent = tvEvent.getText().toString();\n Event event = null;\n\n if (!strEvent.equals(\"\")) {\n event = mDbHelper.getEventByName(strEvent);\n if (event == null) {\n long eventId = mDbHelper.createEvent(new Event(0, strEvent, mCal, null));\n if (eventId != -1) {\n event = mDbHelper.getEvent(eventId);\n }\n }\n }\n\n // Less: Repayment, More: Lend\n if(mCategory.getDebtType() == Category.EnumDebt.LESS || mCategory.getDebtType() == Category.EnumDebt.MORE) {\n\n boolean isDebtValid = true;\n if(mCategory.getDebtType() == Category.EnumDebt.LESS) { // Income -> Debt Collecting\n List<Debt> debts = mDbHelper.getAllDebtByPeople(tvPeople.getText().toString());\n\n Double lend = 0.0, debtCollect = 0.0;\n for(Debt debt : debts) {\n if(mDbHelper.getCategory(debt.getCategoryId()).isExpense() && mDbHelper.getCategory(debt.getCategoryId()).getDebtType() == Category.EnumDebt.MORE) {\n lend += debt.getAmount();\n }\n\n if(!mDbHelper.getCategory(debt.getCategoryId()).isExpense() && mDbHelper.getCategory(debt.getCategoryId()).getDebtType() == Category.EnumDebt.LESS) {\n debtCollect += debt.getAmount();\n }\n }\n\n if(debtCollect + amount > lend) {\n isDebtValid = false;\n ((ActivityMain) getActivity()).showError(getResources().getString(R.string.message_debt_collect_invalid));\n }\n\n } // End DebtType() == Category.EnumDebt.LESS\n if(isDebtValid) {\n Transaction transaction = new Transaction(mTransaction.getId(),\n TransactionEnum.Income.getValue(),\n amount,\n categoryId,\n description,\n 0,\n accountId,\n mCal,\n 0.0,\n \"\",\n event);\n\n int row = mDbHelper.updateTransaction(transaction);\n if (row == 1) { // Update transaction OK\n\n if(mDbHelper.getDebtByTransactionId(mTransaction.getId()) != null) {\n Debt debt = mDbHelper.getDebtByTransactionId(mTransaction.getId());\n debt.setCategoryId(mCategory.getId());\n debt.setAmount(amount);\n debt.setPeople(tvPeople.getText().toString());\n\n int debtRow = mDbHelper.updateDebt(debt);\n if(debtRow == 1) {\n ((ActivityMain) getActivity()).showToastSuccessful(getResources().getString(R.string.message_transaction_update_successful));\n cleanup();\n // Return to last fragment\n getFragmentManager().popBackStackImmediate();\n } else {\n // Revert update\n mDbHelper.updateTransaction(mTransaction);\n ((ActivityMain) getActivity()).showToastSuccessful(getResources().getString(R.string.message_transaction_update_fail));\n }\n } else {\n Debt newDebt = new Debt();\n newDebt.setCategoryId(mCategory.getId());\n newDebt.setTransactionId((int) mTransaction.getId());\n newDebt.setAmount(amount);\n newDebt.setPeople(tvPeople.getText().toString());\n\n long debtId = mDbHelper.createDebt(newDebt);\n if(debtId != -1) {\n ((ActivityMain) getActivity()).showToastSuccessful(getResources().getString(R.string.message_transaction_create_successful));\n cleanup();\n // Return to last fragment\n getFragmentManager().popBackStackImmediate();\n } else {\n // Revert update\n mDbHelper.updateTransaction(mTransaction);\n ((ActivityMain) getActivity()).showToastSuccessful(getResources().getString(R.string.message_transaction_update_fail));\n }\n } // End create new Debt\n\n } // End Update transaction OK\n } // End isDebtValid\n\n } else { // CATEGORY NORMAL\n Transaction transaction = new Transaction(mTransaction.getId(),\n TransactionEnum.Income.getValue(),\n amount,\n categoryId,\n description,\n 0,\n accountId,\n mCal,\n 0.0,\n \"\",\n event);\n\n int row = mDbHelper.updateTransaction(transaction);\n if (row == 1) { // Update transaction OK\n if(mDbHelper.getDebtByTransactionId(mTransaction.getId()) != null) {\n mDbHelper.deleteDebt(mDbHelper.getDebtByTransactionId(mTransaction.getId()).getId());\n }\n // Return to last fragment\n getFragmentManager().popBackStackImmediate();\n }\n }\n\n LogUtils.logLeaveFunction(Tag);\n }", "private void updateSoldProductInfo() { public static final String COL_SOLD_PRODUCT_CODE = \"sells_code\";\n// public static final String COL_SOLD_PRODUCT_SELL_ID = \"sells_id\";\n// public static final String COL_SOLD_PRODUCT_PRODUCT_ID = \"sells_product_id\";\n// public static final String COL_SOLD_PRODUCT_PRICE = \"product_price\";\n// public static final String COL_SOLD_PRODUCT_QUANTITY = \"quantity\";\n// public static final String COL_SOLD_PRODUCT_TOTAL_PRICE = \"total_price\";\n// public static final String COL_SOLD_PRODUCT_PENDING_STATUS = \"pending_status\";\n//\n\n for (ProductListModel product : products){\n soldProductInfo.storeSoldProductInfo(new SoldProductModel(\n printInfo.getInvoiceTv(),\n printInfo.getInvoiceTv(),\n product.getpCode(),\n product.getpPrice(),\n product.getpSelectQuantity(),\n printInfo.getTotalAmountTv(),\n paymentStatus+\"\"\n ));\n\n }\n }", "public void parseDocument() {\n\n // Create a SAXParserFactory instance\n SAXParserFactory factory = SAXParserFactory.newInstance();\n\n // Get the today Date\n Date today = new Date(new java.util.Date().getTime());\n\n File file=new File(this.xmlFileName);\n this.fileName=file.getName();\n\n //Create Sync Status Object\n SyncStatus syncStatus= new SyncStatus();\n syncStatus.setSysMerchantNo(this.merchantNo);\n syncStatus.setSysLocation(this.userLocation);\n\n Long lastBatchIndex=syncStatusService.getLastBatchIndex(this.merchantNo, this.userLocation,SyncType.SALES, today);\n\n syncStatus.setSysBatch(lastBatchIndex!=null?lastBatchIndex+1L:1L);\n syncStatus.setSysDate(today);\n syncStatus.setSysBatchRef(this.fileName);\n syncStatus.setSysType(SyncType.SALES);\n syncStatus.setSysStatus(SyncProcessStatus.ONGOING);\n syncStatus=syncStatusService.saveSyncStatus(syncStatus);\n\n try {\n\n\n\n // Get the parser\n SAXParser parser = factory.newSAXParser();\n\n // Call the parse on the parser for the filename\n parser.parse(xmlFileName,this);\n\n //get size of salesData\n Integer noSalesData=salesData.size();\n\n //Sub list of salesData List for Batch split\n List<Sale> saleList;\n\n //To set batchEndIndex for subList\n int batchStartIndex=0;\n\n //To set batchEndIndex for subList\n int batchEndIndex=0;\n\n\n boolean isSaveStatus=true;\n\n Integer savedCount=0;\n\n //process new sales\n for(batchStartIndex=0;batchStartIndex<noSalesData;batchStartIndex=batchStartIndex+noPerBatch){\n\n //set batchEndIndex\n batchEndIndex=(batchStartIndex+noPerBatch);\n\n //set batchEndIndex as size of saleData if batchEndIndex is greater than its size\n batchEndIndex=batchEndIndex>noSalesData?noSalesData:batchEndIndex;\n\n saleList=salesData.subList(batchStartIndex,batchEndIndex);\n\n try{\n\n // Save the Sale\n saleService.saveSalesAll(saleList, auditDetails);\n\n savedCount++;\n\n }catch(InspireNetzException ex){\n\n isSaveStatus=false;\n\n log.info(\"SalesMasterXMLParser:- Save :-batch \"+syncStatus.getSysBatch()+\" : \"+batchStartIndex+\" failed\");\n\n ex.printStackTrace();\n }catch(Exception e){\n\n log.info(\"SalesMasterXMLParser:- Save :-batch sale:\"+e);\n\n e.printStackTrace();\n\n }\n\n\n }\n\n if(isSaveStatus){\n\n syncStatus.setSysStatus(SyncProcessStatus.COMPLETED);\n\n }else if(!isSaveStatus && savedCount>0){\n\n syncStatus.setSysStatus(SyncProcessStatus.PARTIALLY_COMPLETED);\n\n }else{\n\n syncStatus.setSysStatus(SyncProcessStatus.FAILED);\n\n }\n\n syncStatus=syncStatusService.saveSyncStatus(syncStatus);\n\n }catch(NullPointerException e){\n\n syncStatus.setSysStatus(SyncProcessStatus.FAILED);\n\n syncStatus=syncStatusService.saveSyncStatus(syncStatus);\n\n log.error(\"Parser Config Error \" + xmlFileName);\n\n\n e.printStackTrace();\n\n throw e;\n }\n catch (ParserConfigurationException e) {\n\n syncStatus.setSysStatus(SyncProcessStatus.FAILED);\n\n syncStatus=syncStatusService.saveSyncStatus(syncStatus);\n\n log.error(\"Parser Config Error \" + xmlFileName);\n e.printStackTrace();\n\n } catch (SAXException e) {\n\n syncStatus.setSysStatus(SyncProcessStatus.FAILED);\n\n syncStatus=syncStatusService.saveSyncStatus(syncStatus);\n\n log.error(\"SAX Exception : XML not well formed \" + xmlFileName);\n e.printStackTrace();\n\n } catch (IOException e) {\n\n syncStatus.setSysStatus(SyncProcessStatus.FAILED);\n\n syncStatus=syncStatusService.saveSyncStatus(syncStatus);\n\n log.error(\"IO Error \" + xmlFileName);\n e.printStackTrace();\n\n }catch(Exception e){\n\n syncStatus.setSysStatus(SyncProcessStatus.FAILED);\n\n syncStatus=syncStatusService.saveSyncStatus(syncStatus);\n\n log.error(e.toString() + xmlFileName);\n e.printStackTrace();\n\n }\n\n }", "public void updateOwners() {\n\t\tbuyOrder.getOwner().executedOrder(buyOrder,this);\n\t\tsellOrder.getOwner().executedOrder(sellOrder,this);\n\t}", "public void UpdateTransaction() {\n\t\tgetUsername();\n\t\tcol_transactionID.setCellValueFactory(new PropertyValueFactory<Account, Integer>(\"transactionID\"));\n\t\tcol_date.setCellValueFactory(new PropertyValueFactory<Account, Date>(\"date\"));\n\t\tcol_description.setCellValueFactory(new PropertyValueFactory<Account, String>(\"description\"));\n\t\tcol_category.setCellValueFactory(new PropertyValueFactory<Account, String>(\"category\"));\n\t\tcol_amount.setCellValueFactory(new PropertyValueFactory<Account, Double>(\"amount\"));\n\t\tmySqlCon.setUsername(username);\n\t\tlists = mySqlCon.getAccountData();\n\t\ttableTransactions.setItems(lists);\n\t}", "public void calculatePosition(Body[] bodies, int dt) {\n this.updateVelocity(bodies, dt);\n this.temp_x += this.vx * dt + 0.5 * this.ax * dt * dt;\n this.temp_y += this.vy * dt + 0.5 * this.ay * dt * dt;\n }", "public void llenarDatosTransaccion(TransactionEntity entity, int indiceLayoutHose){\n //**********************************************************\n int contador = 0;\n Log.v(\"INICIO\",\"**********************************************************\");\n\n Log.v(\"Bomba\",String.valueOf(entity.getIdBomba()));\n //**********************************************************\n //EstadoActual\n int[] tramaEstadoActual = new int[1];\n contador = 0;\n for(int i = 8; i<= 8; i++){\n tramaEstadoActual[contador] = bufferRecepcion[i];\n contador++;\n }\n //String estadoActual = byteArrayToHexString(tramaEstadoActual,tramaEstadoActual.length);\n int estadoActual = Integer.parseInt(byteArrayToHexIntGeneral(tramaEstadoActual,1));\n entity.setEstadoActual(estadoActual);\n\n Log.v(\"Estado\",String.valueOf(entity.getEstadoActual()));\n cambioEstado(indiceLayoutHose, estadoActual);\n\n //**********************************************************\n //Capturar Nro Transaccion\n int[] tramaNroTransaccion = new int[3];\n contador = 0;\n for(int i = 9; i<= 11; i++){\n tramaNroTransaccion[contador] = bufferRecepcion[i];\n contador++;\n }\n String nroTransaccion = \"\" + byteArrayToHexInt(tramaNroTransaccion,tramaNroTransaccion.length);\n entity.setNumeroTransaccion(nroTransaccion);\n Log.v(\"Nro. Transacción\",entity.getNumeroTransaccion());\n\n //**********************************************************\n //Capturar Fecha Inicio\n int[] tramaFechaInicio = new int[1];\n tramaFechaInicio[0] = bufferRecepcion[12];\n String dia = \"\" + byteArrayToHexString(tramaFechaInicio,tramaFechaInicio.length);\n tramaFechaInicio[0] = bufferRecepcion[13];\n String mes = \"\" + byteArrayToHexString(tramaFechaInicio,tramaFechaInicio.length);\n tramaFechaInicio[0] = bufferRecepcion[14];\n String anio = \"20\" + byteArrayToHexString(tramaFechaInicio,tramaFechaInicio.length);\n tramaFechaInicio[0] = bufferRecepcion[17];\n String hora = \"\" + byteArrayToHexString(tramaFechaInicio,tramaFechaInicio.length);\n tramaFechaInicio[0] = bufferRecepcion[16];\n String minuto = \"\" + byteArrayToHexString(tramaFechaInicio,tramaFechaInicio.length);\n tramaFechaInicio[0] = bufferRecepcion[15];\n String segundo = \"\" + byteArrayToHexString(tramaFechaInicio,tramaFechaInicio.length);\n\n String fechaInicio = dia + \"-\" + mes + \"-\" + anio + \"\";\n String horaInicio = hora + \":\" + minuto + \":\" + segundo;\n //fechaInicio = \"\" + hexToAscii(byteArrayToHexString(tramaFechaInicio,tramaFechaInicio.length));\n entity.setFechaInicio(fechaInicio);\n entity.setHoraInicio(horaInicio);\n Log.v(\"Fecha Inicio\",entity.getFechaInicio());\n Log.v(\"Hora Inicio\",entity.getHoraInicio());\n\n //**********************************************************\n //Capturar Turno\n int[] tramaTurno = new int[2];\n contador = 0;\n for(int i = 18; i<= 19; i++){\n tramaTurno[contador] = bufferRecepcion[i];\n contador++;\n }\n int turno = byteArrayToHexInt2(tramaTurno,tramaTurno.length);\n entity.setTurno(turno);\n Log.v(\"Turno\",\"\"+entity.getTurno());\n\n //**********************************************************\n //Numero de Tanque\n int[] tramaNumeroTanque = new int[1];\n contador = 0;\n for(int i = 21; i<= 21; i++){\n tramaNumeroTanque[contador] = bufferRecepcion[i];\n contador++;\n }\n\n int numeroTanque = Integer.parseInt(byteArrayToHexIntGeneral(tramaNumeroTanque,1));\n entity.setNumeroTanque(numeroTanque);\n\n Log.v(\"Tanque\",\"\"+entity.getNumeroTanque());\n\n //**********************************************************\n //Tipo de Vehiculo\n int[] tramaTipoVehiculo = new int[1];\n contador = 0;\n for(int i = 22; i<= 22; i++){\n tramaTipoVehiculo[contador] = bufferRecepcion[i];\n contador++;\n }\n\n int tipoVehiculo = Integer.parseInt(byteArrayToHexIntGeneral(tramaTipoVehiculo,1));\n entity.setTipoVehiculo(tipoVehiculo);\n\n Log.v(\"Tipo Vehiculo\",\"\"+entity.getTipoVehiculo());\n\n\n //**********************************************************\n //Capturar IdVehiculo\n int[] tramaIdVehiculo = new int[8];\n contador = 0;\n for(int i = 23; i<= 30; i++){\n tramaIdVehiculo[contador] = bufferRecepcion[i];\n contador++;\n }\n String IdVehiculo = hexToAscii(byteArrayToHexString(tramaIdVehiculo,tramaIdVehiculo.length));\n entity.setIdVehiculo(IdVehiculo);\n\n Log.v(\"IdVehiculo\",entity.getIdVehiculo());\n\n //**********************************************************\n //Capturar Placa\n int[] tramaPlaca = new int[10];\n contador = 0;\n for(int i = 31; i<= 40; i++){\n tramaPlaca[contador] = bufferRecepcion[i];\n contador++;\n }\n String placa = hexToAscii(byteArrayToHexString(tramaPlaca,tramaPlaca.length));\n entity.setPlaca(placa);\n\n Log.v(\"Placa\",entity.getPlaca());\n\n //**********************************************************\n //Capturar Kilometro\n\n int[] tramaKilometroParteEntera = new int[3];\n contador = 0;\n for(int i = 41; i<= 43; i++){\n tramaKilometroParteEntera[contador] = bufferRecepcion[i];\n contador++;\n }\n int kilometroParteEntera = byteArrayToHexInt(tramaKilometroParteEntera,tramaKilometroParteEntera.length);\n\n int[] tramaKilometroParteDecimal = new int[1];\n contador = 0;\n for(int i = 44; i<= 44; i++){\n tramaKilometroParteDecimal[contador] = bufferRecepcion[i];\n contador++;\n }\n int kilometroParteDecimal = byteArrayToHexInt(tramaKilometroParteDecimal,tramaKilometroParteDecimal.length);\n\n //double kilometro = kilometroParteEntera + kilometroParteDecimal*0.1;\n double kilometro = Double.valueOf(kilometroParteEntera + \".\"+kilometroParteDecimal);\n entity.setKilometraje(\"\"+kilometro);\n\n Log.v(\"Kilometro\",\"\"+kilometro);\n\n //**********************************************************\n //Capturar Horometro\n\n int[] tramaHorometroParteEntera = new int[3];\n contador = 0;\n for(int i = 45; i<= 47; i++){\n tramaHorometroParteEntera[contador] = bufferRecepcion[i];\n contador++;\n }\n int horometroParteEntera = byteArrayToHexInt(tramaHorometroParteEntera,tramaHorometroParteEntera.length);\n\n int[] tramaHorometroParteDecimal = new int[1];\n contador = 0;\n for(int i = 48; i<= 48; i++){\n tramaKilometroParteDecimal[contador] = bufferRecepcion[i];\n contador++;\n }\n\n double horometro = 0.0;\n\n if(tramaHorometroParteDecimal[0]==255){\n horometro = horometroParteEntera/10D;\n }else{\n int horometroParteDecimal = byteArrayToHexInt(tramaKilometroParteDecimal,tramaKilometroParteDecimal.length);\n //horometro = horometroParteEntera + horometroParteDecimal*0.1;\n horometro = Double.valueOf(horometroParteEntera + \".\"+horometroParteDecimal);\n }\n\n entity.setHorometro(\"\"+horometro);\n\n Log.v(\"Horometro\",\"\"+horometro);\n\n //**********************************************************\n //Capturar IdConductor\n int[] tramaIdConductor = new int[8];\n contador = 0;\n for(int i = 49; i<= 56; i++){\n tramaIdConductor[contador] = bufferRecepcion[i];\n contador++;\n }\n String IdConductor = hexToAscii(byteArrayToHexString(tramaIdConductor,tramaIdConductor.length));\n entity.setIdConductor(IdConductor);\n\n Log.v(\"IdConductor\",entity.getIdConductor());\n\n //**********************************************************\n //Capturar IdOperador\n int[] tramaIdOperador = new int[8];\n contador = 0;\n for(int i = 57; i<= 64; i++){\n tramaIdOperador[contador] = bufferRecepcion[i];\n contador++;\n }\n String IdOperador = hexToAscii(byteArrayToHexString(tramaIdOperador,tramaIdOperador.length));\n entity.setIdOperador(IdOperador);\n\n Log.v(\"IdOperador\",entity.getIdOperador());\n\n //**********************************************************\n //Tipo de Transacción\n int[] tramaTipoTransaccion = new int[1];\n contador = 0;\n for(int i = 65; i<= 65; i++){\n tramaTipoTransaccion[contador] = bufferRecepcion[i];\n contador++;\n }\n\n int tipoTransaccion = Integer.parseInt(byteArrayToHexIntGeneral(tramaTipoTransaccion,1));\n entity.setTipoTransaccion(tipoTransaccion);\n\n Log.v(\"Tipo Transacción\",\"\"+entity.getTipoTransaccion());\n\n //**********************************************************\n //Capturar Latitud\n int[] tramaLatitud = new int[12];\n contador = 0;\n for(int i = 66; i<= 77; i++){\n tramaLatitud[contador] = bufferRecepcion[i];\n contador++;\n }\n String latitud = hexToAscii(byteArrayToHexString(tramaLatitud,tramaLatitud.length));\n entity.setLatitud(latitud);\n\n Log.v(\"Latitud\",entity.getLatitud());\n\n //**********************************************************\n //Capturar Longitud\n int[] tramaLongitud = new int[12];\n contador = 0;\n for(int i = 78; i<= 89; i++){\n tramaLongitud[contador] = bufferRecepcion[i];\n contador++;\n }\n String longitud = hexToAscii(byteArrayToHexString(tramaLongitud,tramaLongitud.length));\n entity.setLongitud(longitud);\n\n Log.v(\"Longitud\",entity.getLongitud());\n\n //**********************************************************\n //Capturar Tipo Error Pre-Seteo\n int[] tramaTipoErrorPreseteo = new int[1];\n contador = 0;\n for(int i = 90; i<= 90; i++){\n tramaTipoErrorPreseteo[contador] = bufferRecepcion[i];\n contador++;\n }\n\n int tipoErrorPreseteo= Integer.parseInt(byteArrayToHexIntGeneral(tramaTipoErrorPreseteo,1));\n entity.setTipoErrorPreseteo(tipoErrorPreseteo);\n\n Log.v(\"Tipo Error Preseteo\",\"\"+entity.getTipoErrorPreseteo());\n\n //**********************************************************\n //Capturar Volumen Autorizado\n int[] tramaVolumenAutorizado = new int[2];\n contador = 0;\n for(int i = 91; i<= 92; i++){\n tramaVolumenAutorizado[contador] = bufferRecepcion[i];\n contador++;\n }\n int volumenAutorizado = byteArrayToHexInt2(tramaVolumenAutorizado,tramaVolumenAutorizado.length);\n entity.setVolumenAutorizado(volumenAutorizado);\n Log.v(\"Volumen Autorizado\",\"\"+entity.getVolumenAutorizado());\n\n //**********************************************************\n //Capturar Volumen Aceptado\n int[] tramaVolumenAceptado = new int[2];\n contador = 0;\n for(int i = 93; i<= 94; i++){\n tramaVolumenAceptado[contador] = bufferRecepcion[i];\n contador++;\n }\n int volumenAceptado = byteArrayToHexInt2(tramaVolumenAceptado,tramaVolumenAceptado.length);\n entity.setVolumenAceptado(volumenAceptado);\n Log.v(\"Volumen Aceptado\",\"\"+entity.getVolumenAceptado());\n\n //**********************************************************\n //Capturar Código Cliente\n int[] tramaCodigoCliente = new int[2];\n contador = 0;\n for(int i = 100; i<= 101; i++){\n tramaCodigoCliente[contador] = bufferRecepcion[i];\n contador++;\n }\n int codigoCliente = byteArrayToHexInt2(tramaCodigoCliente,tramaCodigoCliente.length);\n entity.setCodigoCliente(codigoCliente);\n Log.v(\"Codigo Cliente\",\"\"+entity.getCodigoCliente());\n\n //**********************************************************\n //Capturar codigo area\n int[] tramaCodigoArea = new int[1];\n contador = 0;\n for(int i = 102; i<= 102; i++){\n tramaCodigoArea[contador] = bufferRecepcion[i];\n contador++;\n }\n\n int CodigoArea = Integer.parseInt(byteArrayToHexIntGeneral(tramaCodigoArea,1));\n entity.setCodigoArea(CodigoArea);\n\n Log.v(\"Codigo Area\",\"\"+entity.getCodigoArea());\n\n //**********************************************************\n //Capturar tipo TAG\n int[] tramaTipoTAG = new int[1];\n contador = 0;\n for(int i = 103; i<= 103; i++){\n tramaTipoTAG[contador] = bufferRecepcion[i];\n contador++;\n }\n\n int tipoTAG = Integer.parseInt(byteArrayToHexIntGeneral(tramaTipoTAG,1));\n entity.setTipoTag(tipoTAG);\n\n Log.v(\"Tipo TAG\",\"\"+entity.getTipoTag());\n\n //**********************************************************\n //Capturar Volumen Abastecido\n int[] tramaVolumen = new int[9];\n contador = 0;\n for(int i = 104; i<= 112; i++){\n tramaVolumen[contador] = bufferRecepcion[i];\n contador++;\n }\n String volumen = \"\"+ hexToAscii(byteArrayToHexString(tramaVolumen,tramaVolumen.length));\n String[] parts = volumen.split(\"\\\\.\");\n if(parts.length > 1) {\n volumen = parts[0] + \".\" + parts[1].substring(0,(0+entity.getCantidadDecimales()));\n }\n\n entity.setVolumen(volumen);\n\n Log.v(\"Volumen Abastecido\",entity.getVolumen());\n\n //**********************************************************\n //Capturar Temperatura\n int[] tramaTemperatura = new int[5];\n contador = 0;\n for(int i = 113; i<= 117; i++){\n tramaTemperatura[contador] = bufferRecepcion[i];\n contador++;\n }\n String temperatura = \"\" + hexToAscii(byteArrayToHexString(tramaTemperatura,tramaTemperatura.length));\n temperatura = temperatura.substring(0,temperatura.length()-1);\n entity.setTemperatura(temperatura);\n\n Log.v(\"Temperatura\",entity.getTemperatura());\n\n //**********************************************************\n //Capturar Fecha Fin\n int[] tramaFechaFin = new int[1];\n tramaFechaFin[0] = bufferRecepcion[118];\n String diaFin = \"\" + byteArrayToHexString(tramaFechaFin,tramaFechaFin.length);\n tramaFechaFin[0] = bufferRecepcion[119];\n String mesFin = \"\" + byteArrayToHexString(tramaFechaFin,tramaFechaFin.length);\n tramaFechaFin[0] = bufferRecepcion[120];\n String anioFin = \"20\" + byteArrayToHexString(tramaFechaFin,tramaFechaFin.length);\n tramaFechaFin[0] = bufferRecepcion[123];\n String horaFin = \"\" + byteArrayToHexString(tramaFechaFin,tramaFechaFin.length);\n tramaFechaFin[0] = bufferRecepcion[122];\n String minutoFin = \"\" + byteArrayToHexString(tramaFechaFin,tramaFechaFin.length);\n tramaFechaFin[0] = bufferRecepcion[121];\n String segundoFin = \"\" + byteArrayToHexString(tramaFechaFin,tramaFechaFin.length);\n\n String fechaFin = diaFin + \"-\" + mesFin + \"-\" + anioFin + \"\" ;\n String horaFin1 = horaFin + \":\" + minutoFin + \":\" + segundoFin;\n //fechaInicio = \"\" + hexToAscii(byteArrayToHexString(tramaFechaInicio,tramaFechaInicio.length));\n entity.setFechaFin(fechaFin);\n entity.setHoraFin(horaFin1);\n\n Log.v(\"Fecha Fin\",entity.getFechaFin());\n Log.v(\"Hora Fin\",entity.getHoraFin());\n\n //**********************************************************\n //Capturar Tipo de Cierre\n int[] tramaTipoCierre = new int[1];\n contador = 0;\n for(int i = 124; i<= 124; i++){\n tramaTipoCierre[contador] = bufferRecepcion[i];\n contador++;\n }\n\n int tipoCierre = Integer.parseInt(byteArrayToHexIntGeneral(tramaTipoCierre,1));\n entity.setTipoCierre(tipoCierre);\n\n Log.v(\"Tipo Cierre\",\"\"+entity.getTipoCierre());\n\n txt_galones = (TextView) layoutsHose.get(indiceLayoutHose).inflater.findViewById(R.id.txt_galones);\n txt_ultimo_ticket = (TextView) layoutsHose.get(indiceLayoutHose).inflater.findViewById(R.id.txt_ultimo_ticket);\n txt_placa = layoutsHose.get(indiceLayoutHose).inflater.findViewById(R.id.txt_placa);\n txt_producto = layoutsHose.get(indiceLayoutHose).inflater.findViewById(R.id.txt_producto);\n txt_ultimo_galon_p2 = layoutsHose.get(indiceLayoutHose).inflater.findViewById(R.id.txt_ultimo_galon_p2);\n txt_ultimo_ticket_p2= layoutsHose.get(indiceLayoutHose).inflater.findViewById(R.id.txt_ultimo_ticket_p2);\n\n txt_producto.setText(entity.getNombreProducto());\n txt_placa.setText(entity.getPlaca());\n txt_galones.setText(entity.getVolumen());\n txt_ultimo_galon_p2.setText(entity.getVolumen());\n txt_ultimo_ticket.setText(entity.getNumeroTransaccion());\n txt_ultimo_ticket_p2.setText(entity.getNumeroTransaccion());\n\n\n guardarTransaccionBD(entity);\n\n }", "public void skystonePos2() {\n }", "@Override\n public void insertUpdate(DocumentEvent e) {\n String order = \"\";\n if(fromSplit != null && toSplit != null){\n String query = \n \"Select * from StockOut where cast(dbo.StockOut.Date as date ) between '\"+fromSplit[0]+\"' and \"\n + \" '\"+toSplit[0]+\"' and \" +\n \" (ProductId like '%\"+searchtf.getText()+\"%' or Barcode like '%\"+searchtf.getText()+\"%' or\"\n + \" ProductName like '%\"+searchtf.getText()+\"%' or ProductDesc like '%\"+searchtf.getText()+\"%' or \"\n + \"Category \" \n + \" like '%\"+searchtf.getText()+\"%' or Quantity like '%\"+searchtf.getText()+\"' or \"\n + \"SellPrice like '%\"+searchtf.getText()+\"'or Total like '%\"+searchtf.getText()+\"%' or \"\n + \"InvoiceNo like '%\"+searchtf.getText()+\"%' ) order by invoiceNo \";\n findUsers(query);\n }else{\n String query = \"Select * from StockOut where ProductId like '%\"+searchtf.getText()+\"%' or Barcode like '%\"+searchtf.getText()+\"%' or\"\n + \" ProductName like '%\"+searchtf.getText()+\"%' or ProductDesc like '%\"+searchtf.getText()+\"%' or \"\n + \"Category \" \n + \" like '%\"+searchtf.getText()+\"%' or Quantity like '%\"+searchtf.getText()+\"' or \"\n + \"SellPrice like '%\"+searchtf.getText()+\"'or Total like '%\"+searchtf.getText()+\"%' or \"\n + \"InvoiceNo like '%\"+searchtf.getText()+\"%' order by invoiceNo\";\n findUsers(query);\n }\n \n }", "public void saveOrUpdate(PosPrice posPrice) throws DataAccessException{\n super.saveOrUpdate(posPrice);\n }", "void updatePercepts() {\n clearPercepts();\n \n Location r1Loc = model.getAgPos(0);\n //Location r2Loc = model.getAgPos(1);\n \n Literal pos1 = Literal.parseLiteral(\"pos(r1,\" + r1Loc.x + \",\" + r1Loc.y + \")\");\n // Literal pos2 = Literal.parseLiteral(\"pos(r2,\" + r2Loc.x + \",\" + r2Loc.y + \")\");\n\n addPercept(pos1);\n //addPercept(pos2);\n \n if (model.hasObject(Const.ObstacleCode, r1Loc)) {\n addPercept(Const.v1);\n }\n// if (model.hasObject(Const.ObstacleCode, r2Loc)) {\n// addPercept(Const.v2);\n// }\n }", "public void insertarPos(int pos,Nodo nNodo) throws Exception {\n if(pos>this.size || pos<0){\r\n throw new Exception(\"Posicion invalida\");\r\n //Si la posicion es igual al tamaño de la lista, quiere decir que se\r\n //quiere insertar al final\r\n } else if(pos==this.size){\r\n this.agregarNodo(nNodo);\r\n //Se inserta en cualquer lugar\r\n } else {\r\n size++;\r\n Nodo temp = nIni;\r\n if(pos ==0){\r\n nIni.setnAnt(nNodo);\r\n nNodo.setnSig(nIni);\r\n nIni = nNodo;\r\n } else{\r\n for (int i = 0; i < pos-1; i++) {\r\n temp=temp.getnSig();\r\n }\r\n temp.getnSig().setnAnt(nNodo);\r\n nNodo.setnSig(temp.getnSig());\r\n nNodo.setnAnt(temp);\r\n temp.setnSig(nNodo);\r\n }\r\n }\r\n }", "private void inseredados() {\n // Insert Funcionários\n\n FuncionarioDAO daoF = new FuncionarioDAO();\n Funcionario func1 = new Funcionario();\n func1.setCpf(\"08654683970\");\n func1.setDataNasc(new Date(\"27/04/1992\"));\n func1.setEstadoCivil(\"Solteiro\");\n func1.setFuncao(\"Garcom\");\n func1.setNome(\"Eduardo Kempf\");\n func1.setRg(\"10.538.191-3\");\n func1.setSalario(1000);\n daoF.persisteObjeto(func1);\n\n Funcionario func2 = new Funcionario();\n func2.setCpf(\"08731628974\");\n func2.setDataNasc(new Date(\"21/08/1992\"));\n func2.setEstadoCivil(\"Solteira\");\n func2.setFuncao(\"Caixa\");\n func2.setNome(\"Juliana Iora\");\n func2.setRg(\"10.550.749-6\");\n func2.setSalario(1200);\n daoF.persisteObjeto(func2);\n\n Funcionario func3 = new Funcionario();\n func3.setCpf(\"08731628974\");\n func3.setDataNasc(new Date(\"03/05/1989\"));\n func3.setEstadoCivil(\"Solteiro\");\n func3.setFuncao(\"Gerente\");\n func3.setNome(\"joão da Silva\");\n func3.setRg(\"05.480.749-2\");\n func3.setSalario(3000);\n daoF.persisteObjeto(func3);\n\n Funcionario func4 = new Funcionario();\n func4.setCpf(\"01048437990\");\n func4.setDataNasc(new Date(\"13/04/1988\"));\n func4.setEstadoCivil(\"Solteiro\");\n func4.setFuncao(\"Garçon\");\n func4.setNome(\"Luiz Fernandodos Santos\");\n func4.setRg(\"9.777.688-1\");\n func4.setSalario(1000);\n daoF.persisteObjeto(func4);\n\n TransactionManager.beginTransaction();\n Funcionario func5 = new Funcionario();\n func5.setCpf(\"01048437990\");\n func5.setDataNasc(new Date(\"13/04/1978\"));\n func5.setEstadoCivil(\"Casada\");\n func5.setFuncao(\"Cozinheira\");\n func5.setNome(\"Sofia Gomes\");\n func5.setRg(\"3.757.688-8\");\n func5.setSalario(1500);\n daoF.persisteObjeto(func5);\n\n // Insert Bebidas\n BebidaDAO daoB = new BebidaDAO();\n Bebida bebi1 = new Bebida();\n bebi1.setNome(\"Coca Cola\");\n bebi1.setPreco(3.25);\n bebi1.setQtde(1000);\n bebi1.setTipo(\"Refrigerante\");\n bebi1.setDataValidade(new Date(\"27/04/2014\"));\n daoB.persisteObjeto(bebi1);\n\n Bebida bebi2 = new Bebida();\n bebi2.setNome(\"Cerveja\");\n bebi2.setPreco(4.80);\n bebi2.setQtde(1000);\n bebi2.setTipo(\"Alcoolica\");\n bebi2.setDataValidade(new Date(\"27/11/2013\"));\n daoB.persisteObjeto(bebi2);\n\n Bebida bebi3 = new Bebida();\n bebi3.setNome(\"Guaraná Antatica\");\n bebi3.setPreco(3.25);\n bebi3.setQtde(800);\n bebi3.setTipo(\"Refrigerante\");\n bebi3.setDataValidade(new Date(\"27/02/2014\"));\n daoB.persisteObjeto(bebi3);\n\n Bebida bebi4 = new Bebida();\n bebi4.setNome(\"Água com gás\");\n bebi4.setPreco(2.75);\n bebi4.setQtde(500);\n bebi4.setTipo(\"Refrigerante\");\n bebi4.setDataValidade(new Date(\"27/08/2013\"));\n daoB.persisteObjeto(bebi4);\n\n Bebida bebi5 = new Bebida();\n bebi5.setNome(\"Whisky\");\n bebi5.setPreco(3.25);\n bebi5.setQtde(1000);\n bebi5.setTipo(\"Alcoolica\");\n bebi5.setDataValidade(new Date(\"03/05/2016\"));\n daoB.persisteObjeto(bebi5);\n\n // Insert Comidas\n ComidaDAO daoC = new ComidaDAO();\n Comida comi1 = new Comida();\n comi1.setNome(\"Batata\");\n comi1.setQuantidade(30);\n comi1.setTipo(\"Kilograma\");\n comi1.setDataValidade(new Date(\"27/04/2013\"));\n daoC.persisteObjeto(comi1);\n\n Comida comi2 = new Comida();\n comi2.setNome(\"Frango\");\n comi2.setQuantidade(15);\n comi2.setTipo(\"Kilograma\");\n comi2.setDataValidade(new Date(\"22/04/2013\"));\n daoC.persisteObjeto(comi2);\n\n Comida comi3 = new Comida();\n comi3.setNome(\"Mussarela\");\n comi3.setQuantidade(15000);\n comi3.setTipo(\"Grama\");\n comi3.setDataValidade(new Date(\"18/04/2013\"));\n daoC.persisteObjeto(comi3);\n\n Comida comi4 = new Comida();\n comi4.setNome(\"Presunto\");\n comi4.setQuantidade(10000);\n comi4.setTipo(\"Grama\");\n comi4.setDataValidade(new Date(\"18/04/2013\"));\n daoC.persisteObjeto(comi4);\n\n Comida comi5 = new Comida();\n comi5.setNome(\"Bife\");\n comi5.setQuantidade(25);\n comi5.setTipo(\"Kilograma\");\n comi5.setDataValidade(new Date(\"22/04/2013\"));\n daoC.persisteObjeto(comi5);\n\n\n // Insert Mesas\n MesaDAO daoM = new MesaDAO();\n Mesa mes1 = new Mesa();\n mes1.setCapacidade(4);\n mes1.setStatus(true);\n daoM.persisteObjeto(mes1);\n\n Mesa mes2 = new Mesa();\n mes2.setCapacidade(4);\n mes2.setStatus(true);\n daoM.persisteObjeto(mes2);\n\n Mesa mes3 = new Mesa();\n mes3.setCapacidade(6);\n mes3.setStatus(true);\n daoM.persisteObjeto(mes3);\n\n Mesa mes4 = new Mesa();\n mes4.setCapacidade(6);\n mes4.setStatus(true);\n daoM.persisteObjeto(mes4);\n\n Mesa mes5 = new Mesa();\n mes5.setCapacidade(8);\n mes5.setStatus(true);\n daoM.persisteObjeto(mes5);\n\n // Insert Pratos\n PratoDAO daoPr = new PratoDAO();\n Prato prat1 = new Prato();\n List<Comida> comI = new ArrayList<Comida>();\n comI.add(comi1);\n prat1.setNome(\"Porção de Batata\");\n prat1.setIngredientes(comI);\n prat1.setQuantidadePorcoes(3);\n prat1.setPreco(13.00);\n daoPr.persisteObjeto(prat1);\n\n Prato prat2 = new Prato();\n List<Comida> comII = new ArrayList<Comida>();\n comII.add(comi2);\n prat2.setNome(\"Porção de Frango\");\n prat2.setIngredientes(comII);\n prat2.setQuantidadePorcoes(5);\n prat2.setPreco(16.00);\n daoPr.persisteObjeto(prat2);\n\n Prato prat3 = new Prato();\n List<Comida> comIII = new ArrayList<Comida>();\n comIII.add(comi1);\n comIII.add(comi3);\n comIII.add(comi4);\n prat3.setNome(\"Batata Recheada\");\n prat3.setIngredientes(comIII);\n prat3.setQuantidadePorcoes(3);\n prat3.setPreco(13.00);\n daoPr.persisteObjeto(prat3);\n\n Prato prat4 = new Prato();\n List<Comida> comIV = new ArrayList<Comida>();\n comIV.add(comi2);\n comIV.add(comi3);\n comIV.add(comi4);\n prat4.setNome(\"Lanche\");\n prat4.setIngredientes(comIV);\n prat4.setQuantidadePorcoes(3);\n prat4.setPreco(13.00);\n daoPr.persisteObjeto(prat4);\n\n Prato prat5 = new Prato();\n prat5.setNome(\"Porção especial\");\n List<Comida> comV = new ArrayList<Comida>();\n comV.add(comi1);\n comV.add(comi3);\n comV.add(comi4);\n prat5.setIngredientes(comV);\n prat5.setQuantidadePorcoes(3);\n prat5.setPreco(13.00);\n daoPr.persisteObjeto(prat5);\n\n // Insert Pedidos Bebidas\n PedidoBebidaDAO daoPB = new PedidoBebidaDAO();\n PedidoBebida pb1 = new PedidoBebida();\n pb1.setPago(false);\n List<Bebida> bebI = new ArrayList<Bebida>();\n bebI.add(bebi1);\n bebI.add(bebi2);\n pb1.setBebidas(bebI);\n pb1.setIdFuncionario(func5);\n pb1.setIdMesa(mes5);\n daoPB.persisteObjeto(pb1);\n\n PedidoBebida pb2 = new PedidoBebida();\n pb2.setPago(false);\n List<Bebida> bebII = new ArrayList<Bebida>();\n bebII.add(bebi1);\n bebII.add(bebi4);\n pb2.setBebidas(bebII);\n pb2.setIdFuncionario(func4);\n pb2.setIdMesa(mes4);\n daoPB.persisteObjeto(pb2);\n\n TransactionManager.beginTransaction();\n PedidoBebida pb3 = new PedidoBebida();\n pb3.setPago(false);\n List<Bebida> bebIII = new ArrayList<Bebida>();\n bebIII.add(bebi2);\n bebIII.add(bebi3);\n pb3.setBebidas(bebIII);\n pb3.setIdFuncionario(func2);\n pb3.setIdMesa(mes2);\n daoPB.persisteObjeto(pb3);\n\n PedidoBebida pb4 = new PedidoBebida();\n pb4.setPago(false);\n List<Bebida> bebIV = new ArrayList<Bebida>();\n bebIV.add(bebi2);\n bebIV.add(bebi5);\n pb4.setBebidas(bebIV);\n pb4.setIdFuncionario(func3);\n pb4.setIdMesa(mes3);\n daoPB.persisteObjeto(pb4);\n\n PedidoBebida pb5 = new PedidoBebida();\n pb5.setPago(false);\n List<Bebida> bebV = new ArrayList<Bebida>();\n bebV.add(bebi1);\n bebV.add(bebi2);\n bebV.add(bebi3);\n pb5.setBebidas(bebV);\n pb5.setIdFuncionario(func1);\n pb5.setIdMesa(mes5);\n daoPB.persisteObjeto(pb5);\n\n // Insert Pedidos Pratos\n PedidoPratoDAO daoPP = new PedidoPratoDAO();\n PedidoPrato pp1 = new PedidoPrato();\n pp1.setPago(false);\n List<Prato> praI = new ArrayList<Prato>();\n praI.add(prat1);\n praI.add(prat2);\n praI.add(prat3);\n pp1.setPratos(praI);\n pp1.setIdFuncionario(func5);\n pp1.setIdMesa(mes5);\n daoPP.persisteObjeto(pp1);\n\n PedidoPrato pp2 = new PedidoPrato();\n pp2.setPago(false);\n List<Prato> praII = new ArrayList<Prato>();\n praII.add(prat1);\n praII.add(prat3);\n pp2.setPratos(praII);\n pp2.setIdFuncionario(func4);\n pp2.setIdMesa(mes4);\n daoPP.persisteObjeto(pp2);\n\n PedidoPrato pp3 = new PedidoPrato();\n pp3.setPago(false);\n List<Prato> praIII = new ArrayList<Prato>();\n praIII.add(prat1);\n praIII.add(prat2);\n pp3.setPratos(praIII);\n pp3.setIdFuncionario(func2);\n pp3.setIdMesa(mes2);\n daoPP.persisteObjeto(pp3);\n\n PedidoPrato pp4 = new PedidoPrato();\n pp4.setPago(false);\n List<Prato> praIV = new ArrayList<Prato>();\n praIV.add(prat1);\n praIV.add(prat3);\n pp4.setPratos(praIV);\n pp4.setIdFuncionario(func3);\n pp4.setIdMesa(mes3);\n daoPP.persisteObjeto(pp4);\n\n PedidoPrato pp5 = new PedidoPrato();\n pp5.setPago(false);\n List<Prato> praV = new ArrayList<Prato>();\n praV.add(prat1);\n praV.add(prat2);\n praV.add(prat3);\n praV.add(prat4);\n pp5.setPratos(praV);\n pp5.setIdFuncionario(func1);\n pp5.setIdMesa(mes5);\n daoPP.persisteObjeto(pp5);\n\n }", "@Override\n\tpublic void updateTransaction(Transaction transaction) {\n\n\t}", "public void loadInitialData() {\n\t\t\texecuteTransaction(new Transaction<Boolean>() {\n\t\t\t\t@Override\n\t\t\t\tpublic Boolean execute(Connection conn) throws SQLException {\n\t\t\t\t\tList<Item> inventory;\n\t\t\t\t\tList<Location> locationList;\n\t\t\t\t\tList<User> userList;\n\t\t\t\t\tList<JointLocations> jointLocationsList;\n\t\t\t\t\t//List<Description> descriptionList; \n\t\t\t\t\t\n\t\t\t\t\ttry {\n\t\t\t\t\t\tinventory = InitialData.getInventory();\n\t\t\t\t\t\tlocationList = InitialData.getLocations(); \n\t\t\t\t\t\tuserList = InitialData.getUsers();\n\t\t\t\t\t\tjointLocationsList = InitialData.getJointLocations();\n\t\t\t\t\t\t//descriptionList = //InitialData.getDescriptions();\n\t\t\t\t\t\t\n\t\t\t\t\t} catch (IOException e) {\n\t\t\t\t\t\tthrow new SQLException(\"Couldn't read initial data\", e);\n\t\t\t\t\t}\n\n\t\t\t\t\tPreparedStatement insertItem = null;\n\t\t\t\t\tPreparedStatement insertLocation = null; \n\t\t\t\t\tPreparedStatement insertUser = null;\n\t\t\t\t\tPreparedStatement insertJointLocations = null;\n\n\t\t\t\t\ttry {\n\t\t\t\t\t\t// AD: populate locations first since location_id is foreign key in inventory table\n\t\t\t\t\t\tinsertLocation = conn.prepareStatement(\"insert into locations (description_short, description_long) values (?, ?)\" );\n\t\t\t\t\t\tfor (Location location : locationList)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tinsertLocation.setString(1, location.getShortDescription());\n\t\t\t\t\t\t\tinsertLocation.setString(2, location.getLongDescription());\n\t\t\t\t\t\t\tinsertLocation.addBatch();\n\t\t\t\t\t\t}\n\t\t\t\t\t\tinsertLocation.executeBatch(); \n\t\t\t\t\t\t\n\t\t\t\t\t\tinsertJointLocations = conn.prepareStatement(\"insert into jointLocations (fk_location_id, location_north, location_south, location_east, location_west) values (?, ?, ?, ?, ?)\" );\n\t\t\t\t\t\tfor (JointLocations jointLocations: jointLocationsList)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tinsertJointLocations.setInt(1, jointLocations.getLocationID());\n\t\t\t\t\t\t\tinsertJointLocations.setInt(2, jointLocations.getLocationNorth());\n\t\t\t\t\t\t\tinsertJointLocations.setInt(3, jointLocations.getLocationSouth());\n\t\t\t\t\t\t\tinsertJointLocations.setInt(4, jointLocations.getLocationEast());\n\t\t\t\t\t\t\tinsertJointLocations.setInt(5, jointLocations.getLocationWest());\n\t\t\t\t\t\t\tinsertJointLocations.addBatch();\n\t\t\t\t\t\t}\n\t\t\t\t\t\tinsertJointLocations.executeBatch();\n\t\t\t\t\t\t\n\t\t\t\t\t\tinsertItem = conn.prepareStatement(\"insert into inventory (location_id, item_name) values (?, ?)\");\n\t\t\t\t\t\tfor (Item item : inventory) \n\t\t\t\t\t\t{\n//\t\t\t\t\t\t\t// Auto generate itemID\n\t\t\t\t\t\t\tinsertItem.setInt(1, item.getLocationID());\n\t\t\t\t\t\t\tinsertItem.setString(2, item.getName());\n\t\t\t\t\t\t\tinsertItem.addBatch();\n\t\t\t\t\t\t}\n\t\t\t\t\t\tinsertItem.executeBatch();\n\t\t\t\t\t\t\n\t\t\t\t\t\tinsertUser = conn.prepareStatement(\"insert into users (username, password) values (?, ?)\");\n\t\t\t\t\t\tfor(User user: userList) {\n\t\t\t\t\t\t\tinsertUser.setString(1, user.getUsername());\n\t\t\t\t\t\t\tinsertUser.setString(2, user.getPassword());\n\t\t\t\t\t\t\tinsertUser.addBatch();\n\t\t\t\t\t\t}\n\t\t\t\t\t\tinsertUser.executeBatch();\n\t\t\t\t\t\t\n\t\t\t\t\t\tSystem.out.println(\"Tables populated\");\n\t\t\t\t\t\t\n\t\t\t\t\t} finally {\n\t\t\t\t\t\tDBUtil.closeQuietly(insertLocation);\t\n\t\t\t\t\t\tDBUtil.closeQuietly(insertItem);\n\t\t\t\t\t\tDBUtil.closeQuietly(insertUser);\n\t\t\t\t\t}\n\t\t\t\t\treturn true;\n\t\t\t\t}\n\t\t\t});\n\t\t}", "private void doLine()\n\t{\n\t\tubisenseData = new UbisenseMockupData();\n\t\tDecimalFormat df = new DecimalFormat(\"#0,00\");\n\n\t\telapsedTime = 0;\n\t\t\n\t\tubisenseData.setTagID(Helper.DEFAULT_TAG_ID);\n\t\tubisenseData.setUnit(Helper.UBISENSE_UNIT);\n\t\tubisenseData.setOntology(Helper.LP_ONTOLOGY_URL);\n\t\tubisenseData.setVersion(Helper.UBISENSE_VERSION);\n\t\tubisenseData.setId(\"\");\n\t\tubisenseData.setSendTime(sendTime);\n\t\t\n\t\tlong millis = startDate.getMillis();\n\t\tmillis += offset.toStandardDuration().getMillis();\n//\t\tmillis += parentOffset.toStandardDuration().getMillis();\n\t\t\n\t\t// Steigung m und Achsenabschnitt b berechnen\n//\t\tdouble m = 0.;\n//\t\tif ((x2-x1)!=0)\n//\t\t\tm = (y2-y1)/(x2-x1);\n//\t\tdouble b = y1 - (m * x1);\n\t\t\n\t\t// Abstand zwischen beiden Koordinaten d\n\t\tdouble dsquare = Math.pow((x2-x1),2) + Math.pow((y2-y1),2);\n\t\tdouble d = Math.sqrt(dsquare);\n\n\t\t// Zeit t [s] berechnen, die für die Distanz d unter gegebener Geschwindigkeit benötigt wird.\n\t\tdouble t = d / toolSpeed;\n\t\tdouble steps = Math.ceil(t) +1;\n\t\t\n\t\twhile (steps>0 && !terminate)\n\t\t{\n\t\t\tdouble x,y, currentTime=0;\n\t\t\tif (t != 0)\n\t\t\tcurrentTime = elapsedTime / t;\n\t\t\t\n\t\t\tx = (x2-x1) * currentTime + x1;\n\t\t\ty = (y2-y1) * currentTime + y1;\n\t\t\tubisenseData.setPosition(new Point3D(\tDouble.parseDouble(df.format(x)),\n\t\t\t \tDouble.parseDouble(df.format(y)),\n\t\t\t\t\t\t\t\t\t\t\t\t\t1.6));\n\t\t\tubisenseData.setId(String.valueOf(Helper.getRandomInt()));\n\t\t\tubisenseData.setTime(millis + (long)(elapsedTime*SLEEP_INTERVAL));\n\t\t\tEntryEvent event = new EntryEvent(this);\n\t\t\tnotifyListeners(event);\n\t\t\telapsedTime++;\n\t\t\tif (elapsedTime > t)\n\t\t\t\telapsedTime = t;\n\t\t\t\n\t\t\tsteps--;\n\t\t\ttry\n\t\t\t{\n\t\t\t\tif (speed > 0)\n\t\t\t\t\tThread.sleep(SLEEP_INTERVAL/speed);\n\t\t\t}\n\t\t\tcatch (InterruptedException e)\n\t\t\t{\n\t\t\t\te.printStackTrace();\n\t\t\t}\n\t\t}\n\t}", "private void updateInventory(Sale newSale)\n {\n ArrayList<SaleItem> tempSaleItems = newSale.getSaleItems();\n for(int i = 0; i < tempSaleItems.size(); i++)\n {\n //Get saleItem quantity\n double saleNum = tempSaleItems.get(i).getQuantity();\n //Loop through ingredients\n ArrayList<Ingredient> tempIng = tempSaleItems.get(i).getIngredients();\n for(int j = 0; j < tempIng.size(); j++)\n {\n //get this ingredient name and quantity\n String thisName = tempIng.get(j).getName();\n double thisQty = tempIng.get(j).getQuantity();\n\n //get InventorySingleton qty\n double oldQty = InventorySingleton.get(this).getIngredientQuantity(thisName);\n double newQty = oldQty - (thisQty*saleNum);\n //Update Inventory Singleton and Database\n InventorySingleton.get(this).setIngredientQuantity(thisName, newQty);\n inventoryDBUpdate();\n }\n }\n }", "net.opengis.gml.x32.TimePositionType addNewBeginPosition();", "@Override\n\tpublic void saveBean( SystemUser currentUser ) {\n\t\tif (oldPositionIdx!=positionIdx) {\n\t\t\t//if there's an item in this position that isn't this item\n\t\t\tBeanDao productSizeDao = new BeanDao( ProductSize.class );\n\t\t\tproductSizeDao.addWhereCriteria( \"bean.productSizeType.id=\" + productSizeType.getId() + \" AND positionIdx=\" + positionIdx );\n\t\t\tProductSize dbPs = productSizeDao.getFirstBeanResult();\n\t\t\tif (dbPs != null && !dbPs.equals(this)) {\n\t\t\t\t//make sure we keep all numbers consecutive - ie account for position changing in either direction\n\t\t\t\tif (oldPositionIdx == null){\n\n\t\t\t\t\t// increase each element from positionIdx\n\t\t\t\t\tApplicationUtil.executeSql(\"UPDATE productsize SET positionIdx=(positionIdx+1) WHERE positionIdx >= \" + positionIdx + \" AND productSizeType_id=\" + productSizeType.getId());\n\n\t\t\t\t} else if (oldPositionIdx > positionIdx) {\n\n\t\t\t\t\t// increase each element from positionIdx to oldPositionIdx-1\n\t\t\t\t\t// this closes the gap so anything above oldPositionIdx keeps its position\n\t\t\t\t\tApplicationUtil.executeSql(\"UPDATE productsize SET positionIdx=(positionIdx+1) WHERE (positionIdx >= \" + positionIdx + \" AND positionIdx < \" + oldPositionIdx + \") AND productSizeType_id=\" + productSizeType.getId());\n\n\t\t\t\t} else {\n\n\t\t\t\t\t// decrease each element from oldPositionIdx+1 to positionIdx\n\t\t\t\t\tApplicationUtil.executeSql(\"UPDATE productsize SET positionIdx=(positionIdx-1) WHERE (positionIdx > \" + oldPositionIdx + \" AND positionIdx <= \" + positionIdx + \") AND productSizeType_id=\" + productSizeType.getId());\n\t\t\t\t}\n\n\t\t\t\tsetOldPositionIdx(getPositionIdx());\n\t\t\t}\n\t\t}\n\t\tsuper.saveBean(currentUser);\n\t}", "protected void update(){\n\t\t_offx = _x.valueToPosition(0);\n\t\t_offy = _y.valueToPosition(0);\n\t}", "void update(Order order);", "void updatePosition() {\n\t\t\n\t\tcoords.x = body.getPosition().x*Simulation.meterToPixel;\n\t\tcoords.y = body.getPosition().y*Simulation.meterToPixel;\n\t\tspeed.x = body.m_linearVelocity.x;\n\t\tspeed.y = body.m_linearVelocity.y;\n\t}", "public POS(int position) {\n \t\tthis.position = position;\n \t}", "public void saveOrUpdatePosPrinter(PosPrinter posPrinter) throws DataAccessException{//start saveOrUpdate method\n \n if(log.isDebugEnabled()){\n\t\t\tlog.debug(\"start saveOrUpdatePosPrinter method\");\n\t\t}\n\t\t\n posPrinterDao.saveOrUpdate(posPrinter);\n \n if(log.isDebugEnabled()){\n\t\t\tlog.debug(\"end saveOrUpdatePosPrinter method\");\n\t\t}\n\t\t\n }", "protected abstract NewOrder getNewOrder( int NO_W_ID, int NO_D_ID ) throws TupleNotFoundException;", "public void update(long delta){\n \n if(placement <= -1000){\n placement = zPosition;\n }\n placement -= 5;\n \n \n }", "@Override\n\tpublic int update(Reservation objet) {\n\t\treturn 0;\n\t}", "@Override\r\n\tpublic void inserOrder(Good_ordVO good_ordVO, List<PointgoodsVO> list) {\n\t\t\r\n\t}", "public void AdvancePos() {\n \tswitch (data3d.TrackDirection){\n \tcase 0:\n \tc2.PositionValue += 1;\n \tc2.PositionValue = (c2.PositionValue % c2.getMaxPos());\n \tbreak;\n \tcase 1:\n \tc3.PositionValue += 1;\n \tc3.PositionValue = (c3.PositionValue % c3.getMaxPos());\n \tbreak;\n \tcase 2:\n \tc1.PositionValue += 1;\n \tc1.PositionValue = (c1.PositionValue % c1.getMaxPos());\n \tbreak;\n \tcase 3:\n \tdata3d.setElement((data3d.ActiveElement + 1) % data3d.Elements);\n \tcase 4:\n \tdata3d.setTime((data3d.ActiveTime + 1) % data3d.Times);\n \t}\n }", "public void setPosTransNo (java.lang.Long posTransNo) {\r\n\t\tthis.posTransNo = posTransNo;\r\n\t}", "@Override\n protected void trade(){\n // An example of a random trade proposal: offer peasants in exchange of soldiers\n // Pick the id of the potential partner (without checking if it is my neighbor)\n double pertnerID = (new Random()).nextInt(42)+1;\n trade[0] = pertnerID;\n // Choose the type of good demanded (peasants - 3)\n double demandType = 3;\n trade[1] = demandType;\n // Choose the amount of demanded goods\n double demand = Math.random();\n trade[2] = demand;\n // Choose the type of good offered in exchange (peasants - 2)\n double offerType = 2;\n trade[3] = offerType;\n // Choode the amount of goods offered in exchange (random but less than my total number of peasants)\n double offer = (new Random()).nextDouble()*myTerritory.getPeasants();\n trade[4] = offer;\n\n // This procedure updated the array trade, which contains the information\n // about trade proposals of the current lord\n }", "public void update(){\n\t\tdouble timeStep = (double) 1 / METERS_PER_X_TICKS;\n\t\t\n\t\tdouble newXVel = xVel + xAccel * timeStep;\n\t\tdouble newYVel = yVel + yAccel * timeStep;\n\t\t\n//\t\tdouble deltaX = timeStep * (xVel + newXVel) / 2;\n//\t\tdouble deltaY = timeStep * (yVel + newYVel) / 2;\n\t\t\n\t\tdouble deltaX = timeStep * xVel;\n\t\tdouble deltaY = timeStep * yVel;\n\t\t\n\t\txCoord += deltaX;\n\t\tyCoord += deltaY;\n\t\t\n\t\txVel = newXVel;\n\t\tyVel = newYVel;\n\t\t\n\t\t//record new location\n\t\tif(recordPath)\n\t\t\tmyEnviron.getEntityHistories().get(ID).add(new double[]{xCoord, yCoord, xVel, yVel});\n\t\t\n\t\tcontactBlock = null; // reset to the appropriate block during block collision process, if needed\n\t\tcontactBlockSideNum = -1;\n\t\tcontactBlockVertexNum = -1;\n\t\tlifetime++;\n\t}", "@Override\r\n\t\t\tpublic Object doInTransaction(TransactionStatus arg0) {\n\t\t\t\t\r\n\t\t\t\tSqlLogInspetor sqlLogInspetor = new SqlLogInspetor();\r\n\t\t\t\tsqlLogInspetor.enable();\r\n\t\t\t\t\r\n\t\t\t\t@SuppressWarnings(\"unchecked\")\r\n\t\t\t\tList<MasterBEnt> masterBEntList = \r\n\t\t\t\t\t\thbSupport.createCriteria(ss, MasterBEnt.class)\r\n\t\t\t\t\t\t\t.addOrder(OrderCompat.asc(\"compId.idA\"))\r\n\t\t\t\t\t\t\t.addOrder(OrderCompat.asc(\"compId.idB\")).list();\r\n\t\t\t\tList<Map<String, Map<String, MasterBEnt>>> masterBEntBizarreList = new ArrayList<>();\r\n\t\t\t\t\r\n\t\t\t\tfor (MasterBEnt masterB : masterBEntList) {\r\n\t\t\t\t\tSignatureBean signBean = ((IPlayerManagerImplementor) PlayerManagerTest.this.manager).generateSignature(masterB);\r\n\t\t\t\t\tString signStr = PlayerManagerTest.this.manager.serializeSignature(signBean);\r\n\t\t\t\t\tMap<String, Map<String, MasterBEnt>> mapItem = new LinkedHashMap<>();\r\n\t\t\t\t\tPlayerSnapshot<MasterBEnt> masterBPS = PlayerManagerTest.this.manager.createPlayerSnapshot(masterB);\r\n\t\t\t\t\tMap<String, MasterBEnt> mapMapItem = new LinkedHashMap<>();\r\n\t\t\t\t\tmapMapItem.put(\"wrappedSnapshot\", masterB);\r\n\t\t\t\t\tmapItem.put(signStr, mapMapItem);\r\n\t\t\t\t\tmasterBEntBizarreList.add(mapItem);\r\n\t\t\t\t}\r\n\t\t\t\t\r\n\t\t\t\tPlayerManagerTest\r\n\t\t\t\t\t.this\r\n\t\t\t\t\t\t.manager\r\n\t\t\t\t\t\t.overwriteConfigurationTemporarily(\r\n\t\t\t\t\t\t\tPlayerManagerTest\r\n\t\t\t\t\t\t\t\t.this\r\n\t\t\t\t\t\t\t\t\t.manager\r\n\t\t\t\t\t\t\t\t\t\t.getConfig()\r\n\t\t\t\t\t\t\t\t\t\t\t.clone()\r\n\t\t\t\t\t\t\t\t\t\t\t.configSerialiseBySignatureAllRelationship(false));\r\n\t\t\t\t\r\n\t\t\t\tPlayerSnapshot<List<Map<String, Map<String, MasterBEnt>>>> playerSnapshot = PlayerManagerTest.this.manager.createPlayerSnapshot(masterBEntBizarreList);\r\n\t\t\t\t\r\n\t\t\t\tFileOutputStream fos;\r\n\t\t\t\ttry {\r\n\t\t\t\t\tfos = new FileOutputStream(generatedFileResult);\r\n\t\t\t\t\tPlayerManagerTest\r\n\t\t\t\t\t\t.this\r\n\t\t\t\t\t\t\t.manager\r\n\t\t\t\t\t\t\t\t.getConfig()\r\n\t\t\t\t\t\t\t\t\t.getObjectMapper()\r\n\t\t\t\t\t\t\t\t\t\t.writerWithDefaultPrettyPrinter()\r\n\t\t\t\t\t\t\t\t\t\t\t.writeValue(fos, playerSnapshot);\r\n\t\t\t\t\t\r\n\t\t\t\t} catch (Exception e) {\r\n\t\t\t\t\t// TODO Auto-generated catch block\r\n\t\t\t\t\tthrow new RuntimeException(\"Unexpected\", e);\r\n\t\t\t\t}\r\n\t\t\t\t\r\n\t\t\t\tsqlLogInspetor.disable();\r\n\t\t\t\t\r\n\t\t\t\treturn null;\r\n\t\t\t}", "public synchronized String getUpdatedPosData() {\r\n\t\t// don't send anything if the latitude AND longitude are false\r\n\t\tif (updatedLat == false && updatedLng == false)\r\n\t\t\treturn \"\";\r\n\t\tDocument serviceDoc = createXMLDocumentStructure();\r\n\t\tElement root = serviceDoc.getDocumentElement();\t\r\n\t\tElement gpsElement = createGPSPosElement(serviceDoc);\r\n\t\tif (gpsElement != null)\r\n\t\t\troot.appendChild(gpsElement);\r\n\t\t// Set the dirty flag for position\r\n\t\tupdatedLat = updatedLng = false;\r\n\r\n\t\treturn write(serviceDoc);\r\n\t}", "Position_abscisse createPosition_abscisse();", "Position_changerAbscisse createPosition_changerAbscisse();", "private void actualizarEstado(){\n //--------------- Calcular tiempo transcurrido ---------------\n Date tiempoAnterior = tiempoActual;\n tiempoActual = new Date();\n double transcurridoAux = (tiempoActual.getTime() - tiempoAnterior.getTime());\n double transcurrido = transcurridoAux/1000.0;\n \n boolean puedeCrearTropas = false;\n boolean puedeRecogerRecursos = false;\n //--------------- Recorrer edificios ---------------\n for(Edificio e: aldea.edificios){\n \n // Actualizar minas y recolectores\n if(e.generadorRecursos() && e.estaHabilitado()){\n e.actualizarRecursos(transcurrido);\n puedeRecogerRecursos = true;\n if(e.tipo == vg.MINA){\n jTextFieldOroMina.setText(String.valueOf(e.cantidadRecurso));\n }\n else\n jTextFieldElixRec.setText(String.valueOf(e.cantidadRecurso));\n }\n \n // Verificar si hay un cuartel habilitado para poder crear tropas\n if(e.tipo == vg.CUARTEL && e.habilitado)\n puedeCrearTropas = true;\n \n }\n // Habilitar/deshabilitar boton crear tropas\n jButtonCrearTropa.setEnabled(puedeCrearTropas);\n \n // Habilitar/deshabilitar boton recoger recursos\n jButtonRecogerRecursos.setEnabled(puedeRecogerRecursos);\n \n // Verificar si hay constuctores libres para permitir la creacion de tropas\n if(aldea.constructoresLibres() > 0){\n jButtonCrearEdificio.setEnabled(true);\n jButtonMejorarEdificio.setEnabled(true);\n }\n else{\n jButtonCrearEdificio.setEnabled(false);\n jButtonMejorarEdificio.setEnabled(false);\n }\n \n //--------------- Revisar LEF ---------------\n // Recorrer en sentido inverso\n for(int i=LEF.size()-1;i>=0;i--){\n Date tiempoActual = new Date();\n // Si ocurre un evento\n if(tiempoActual.after(LEF.get(i).tiempo)){\n // Si el evento es culminar edificio\n if(LEF.get(i).tipo == vg.EV_CULMINAR_EDIF){\n culminarEdificio(aldea.edificios.get(LEF.get(i).id));\n LEF.remove(i); // Remover evento futuro de la lista\n }\n else if(LEF.get(i).tipo == vg.EV_CULMINAR_TROPA){\n boolean romperCiclo = false;\n // Recorrer edificio para buscar tropa en colaTropas\n for(Edificio e: aldea.edificios){\n // Buscar tropa\n for(Tropa t: e.colaTropas){\n if(t.id == LEF.get(i).id){\n culminarTropa(e, t); // En este evento se agrega la tropa a la aldea\n e.colaTropas.remove(t);// Remover tropa de colaTropas en edificio\n LEF.remove(i); // Remover evento futuro de la lista\n romperCiclo = true;\n break;\n }\n }\n if(romperCiclo)\n break;\n }\n }\n }\n }\n }", "@Test\n public void testCurrentMarketPosition ()\n {\n initializeService();\n accountingService.addMarketTransaction(bob,\n timeslotRepo.findBySerialNumber(2), 0.5, -45.0);\n accountingService.addMarketTransaction(bob,\n timeslotRepo.findBySerialNumber(2), 0.3, -31.0);\n accountingService.addMarketTransaction(bob,\n timeslotRepo.findBySerialNumber(3), 0.7, -43.0);\n accountingService.addMarketTransaction(jim,\n timeslotRepo.findBySerialNumber(2), 0.4, -35.0);\n accountingService.addMarketTransaction(jim,\n timeslotRepo.findBySerialNumber(2), -0.2, 20.0);\n assertEquals(5, accountingService.getPendingTransactions().size(), \"correct number in list\");\n accountingService.activate(timeService.getCurrentTime(), 3);\n // current timeslot is 4, should be 0 mkt posn\n assertEquals(0.0, accountingService.getCurrentMarketPosition (bob), 1e-6, \"correct position, bob, ts4\");\n assertEquals(0.0, accountingService.getCurrentMarketPosition (jim), 1e-6, \"correct position, jim, ts4\");\n // move forward to timeslot 5 and try again\n timeService.setCurrentTime(timeService.getCurrentTime().plus(TimeService.HOUR));\n assertEquals(0.8, accountingService.getCurrentMarketPosition (bob), 1e-6, \"correct position, bob, ts5\");\n assertEquals(0.2, accountingService.getCurrentMarketPosition (jim), 1e-6, \"correct position, jim, ts5\");\n // another hour and try again\n timeService.setCurrentTime(timeService.getCurrentTime().plus(TimeService.HOUR));\n assertEquals(0.7, accountingService.getCurrentMarketPosition (bob), 1e-6, \"correct position, bob, ts5\");\n assertEquals(0.0, accountingService.getCurrentMarketPosition (jim), 1e-6, \"correct position, jim, ts5\");\n }", "void shift() {\n deleteStart += txnOps;\n deleteEnd += txnOps;\n updateStart += txnOps;\n updateEnd += txnOps;\n insertStart += txnOps;\n insertEnd += txnOps;\n }", "private void insertPerform(){\n \tif(!verify()){\n \t\treturn;\n \t}\n \tString val=new String(\"\");\n \tval=val+\"'\"+jTextField1.getText()+\"', \"; // poNo\n \tval=val+\"'\"+\n \t\tinventorycontroller.util.DateUtil.getRawFormat(\n \t\t\t(java.util.Date)jXDatePicker1.getValue()\n \t\t)\n \t\t+\"', \"; // poDate\n \tval=val+\"'\"+vndList[jTextField2.getSelectedIndex()-1]+\"', \"; // vndNo\n \tval=val+\"'\"+jTextField3.getText()+\"', \"; // qtnNo\n \tval=val+\"'\"+\n \t\tinventorycontroller.util.DateUtil.getRawFormat(\n \t\t\t(java.util.Date)jXDatePicker2.getValue()\n \t\t)\n \t\t+\"', \"; // qtnDate\n \tval=val+\"'\"+poAmount+\"', \"; // poTotal\n \tval=val+\"'pending', \"; // poStatus\n \tval=val+\"'\"+jEditorPane1.getText()+\"' \"; // remark\n \t\n \ttry{\n \t\tdbInterface1.cmdInsert(\"poMaster\", val);\n \t\tinsertPoBomDesc();\n \t\tinsertPoDesc();\n\t \tupdateBOM();\n \t}\n \tcatch(java.sql.SQLException ex){\n \t\tSystem.out.println (ex);\n \t}\n \tresetPerform();\n }", "private void updateSeatInformation(List<Seat> seatList) {\n\n AdministratorSQLiteOpenHelper administratorSQLiteOpenHelper = new AdministratorSQLiteOpenHelper(this, \"CineTEC\", null, 1);\n SQLiteDatabase sqLiteDatabase = administratorSQLiteOpenHelper.getWritableDatabase();\n\n for(int i = 0; i < seatList.size(); i++) {\n\n Seat seat = seatList.get(i);\n\n // Getting seats by screening id, row number and column number\n sqLiteDatabase.execSQL(\"DELETE FROM SEAT WHERE Screening_id=\" + seat.getScreeningId() + \" AND Row_num=\" + seat.getRowNum() + \" AND Column_num=\" + seat.getColumnNum());\n\n ContentValues contentValues = new ContentValues();\n\n contentValues.put(\"Screening_id\", seat.getScreeningId());\n contentValues.put(\"Row_num\", seat.getRowNum());\n contentValues.put(\"Column_num\", seat.getColumnNum());\n contentValues.put(\"State\", \"sold\");\n\n // emulator or phone connected to internet\n if(checkInternetConnection()) {\n\n contentValues.put(\"Sync_status\", 1);\n\n seat.setState(\"sold\");\n\n updateSeat(seat);\n\n // emulator or phone not connected to internet\n } else {\n\n contentValues.put(\"Sync_status\", 0);\n\n }\n\n sqLiteDatabase.insert(\"SEAT\", null, contentValues);\n\n }\n\n Toast.makeText(ConfirmationActivity.this, \"Successful purchase\", Toast.LENGTH_SHORT).show();\n\n sqLiteDatabase.close();\n\n }", "@PostMapping(path = \"/update-positions\", consumes = MediaType.APPLICATION_JSON_VALUE, produces = MediaType.APPLICATION_JSON_VALUE)\n public ResponseEntity<UpdatePositionsOutDTO> updatePositions(@RequestBody UpdatePositionsRequest req) {\n return ResponseEntity.ok(positionsService.updatePositions(req.getPositions(), req.getDeletedPositions()));\n }", "void sendToDB() {add to sell SellItem\n//\n for (int i = 0; i < menuItems.size(); i++) {\n Map<String, String> params = new HashMap<>();\n params.put(\"user_sell_it_id\", session.getshared(\"id\"));\n params.put(\"sell_menu_id\", sellMenuId);\n params.put(\"item_name\", menuItems.get(i).getItem_name());\n params.put(\"item_price\", menuItems.get(i).getItem_price().toString());\n params.put(\"item_count\", menuItems.get(i).getItem_count().toString());\n params.put(\"item_id\", menuItems.get(i).getItem_id().toString());\n params.put(\"f4\", menuItems.get(i).getF4());\n // params.put(\"item_cost\", String.valueOf(menuItems.get(i).getItem_cost());\n// SimpleDateFormat sdf = new SimpleDateFormat(\"yyyy-MM-dd HH:mm:ss\", Locale.getDefault());\n// String dt = sdf.format(new Date());\n// params.put(\"datetime\", dt);\n\n//\n if (menuItems.get(i).getId() == null) {\n\n sendItems(addSellMenuItemURL, params);\n\n } else {\n //updateitems using the id and count\n Map<String, String> upParams = new HashMap<>();\n upParams.put(\"id\", menuItems.get(i).getId().toString());\n upParams.put(\"item_count\", menuItems.get(i).getItem_count().toString());\n // upParams.put(\"datetime\", dt);\n sendItems(updatURL, upParams);\n }\n\n\n\n }\n\n\n show_menu(Integer.valueOf(sellMenuId));\n\n\n }", "public void update( PVector[] positions, int[] lasers, boolean useTransformations){\n\n\t\tbyte serialPackage[] = {0};\n\t\tint bytePos = 0;\n\t\tint byteSize = 4 * activePointers();\n\n\n\t\tfor (int i = 0; i < activePointers(); i++) {\n\t\t\tPointerDevice p = pointers.get(i);\n\n\n\t\t\tif(p.active){\n\n\t\t\t\t//if(i == 0) serial.write((byte)byteSize); //first byte. number of following bytes (index, laser, servo1, servo2)\n\t\t\t\tif(i == 0){\n\t\t\t\t\tserialPackage = new byte[byteSize + 1];\n\t\t\t\t\tserialPackage[bytePos++] = (byte)byteSize;\n\t\t\t\t}\n\n\t\t\t\tp.setLaser(lasers[i]);\n\t\t\t\tserialPackage[bytePos++] = (byte)i;\n\t\t\t\tserialPackage[bytePos++] = (byte)p.laser;\n\n\n\t\t\t\t//pure position from mouse coord system\n\t\t\t\tfloat _x = positions[i].x;\n\t\t\t\tfloat _y = positions[i].y;\n\n\t\t\t\tif (useTransformations) { //TODO check calibration again\n\t\t\t\t\t//pointerTrasformations( p, _x, _y );\n\t\t\t\t\tp.target = pointerTrasformations( p, _x, _y );\n\t\t\t\t\tserialPackage[bytePos++] = (byte) servoLimit(p.target.x); //toTarget\n\t\t\t\t\tserialPackage[bytePos++] = (byte) servoLimit(p.target.y); //toTarget\n\t\t\t\t}else{\n\t\t\t\t\t//System.out.println(\"_x: \"+ _x +\" , _y:\" + _y);\n\t\t\t\t\tserialPackage[bytePos++] = (byte)_x; //toTarget\n\t\t\t\t\tserialPackage[bytePos++] = (byte)_y; //toTarget\n\t\t\t\t}\n\n\t\t\t\t//update previous status\n\t\t\t\t//p.plaser = p.laser; //done in p.onLaserChange\n\t\t\t\t//p.ppos = p.copy(); //done in p.onMoveComplete\n\t\t\t}\n\t\t}\n\t\tsendCommands(serialPackage);\n\t}", "public void step(){\r\n\t\t\r\n\t\t\r\n\t\tsuper.step();\r\n\t\t\r\n\t\t\r\n\t\t\r\n\t\tif(marketEntryHappend){\r\n\t\t\t\r\n\t\t\t\r\n\t\t\taddSequencesToGraphs();\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\t\r\n\t\tif(marketExitHappend){\r\n\t\t\t\r\n\t\t\tfor(int i =0; i < exitedFirms.size();i++){\r\n\t\t\t\r\n\t\t\t\tfreeCoordinates.add(new Coordinate(exitedFirms.get(i).x_coord,exitedFirms.get(i).y_coord)); \r\n\t\t\t\r\n\t\t\t}\r\n\t\t\t\r\n\t\t}\r\n\t\r\n\t\tgraphOutput.step();\r\n\t\tgraphPrice.step();\r\n\t\tgraphQuality.step();\r\n\t\tgraphFirmLocations.step();\r\n\t\t//graphEnteringCosts.step();\r\n\t\tgraphAverageProbability.step();\r\n\t\tgraphTotalProfit.step();\r\n\t\tgraphNumFirms.step();\r\n\t\t\r\n\t\tgraphSingleOutput.step();\r\n\t\tgraphSinglePrice.step(); \r\n\t\tgraphSingleQuality.step(); \r\n\t\tgraphSingleFirmLocations.step();\r\n\t graphSingleProbability.step(); \r\n\t\tgraphSinglelProfit.step();\r\n\t\tgraphSingleQualityConcept.step();\r\n\t\r\n\t\tgraphClusteringCoefficient.step();\r\n\t\t\r\n\t\tgraphCumProfit.step();\r\n\t\t\r\n\t\tfor(int i=0; i < dsurfList.size();i++){\r\n\t\t\t\r\n\t\t\t\r\n\t\t\tgridSpaceList.get(i).update(locationList.get(i));;\r\n\t\t\t\r\n\t\t dsurfList.get(i).updateDisplay();\r\n\t\t }\r\n\t\t\r\n\t\t\tlayout.setList(nodeList);\r\n\t\t\r\n\t\t layout.updateLayout();\r\n\t\t surface.updateDisplay();\r\n\t\t \r\n\t\t\r\n\t\t\r\n\t}" ]
[ "0.5779498", "0.5634024", "0.5617519", "0.55373245", "0.5489222", "0.5480442", "0.5480442", "0.5473795", "0.545729", "0.5451355", "0.544879", "0.54431593", "0.5430472", "0.5343518", "0.53407085", "0.5328409", "0.5325116", "0.5304784", "0.52730906", "0.5265924", "0.52554446", "0.5254099", "0.5245509", "0.52417755", "0.5229325", "0.5226286", "0.5213049", "0.52080894", "0.5190149", "0.51622564", "0.5156706", "0.5155545", "0.51500934", "0.5132087", "0.51284", "0.51224494", "0.50984895", "0.509562", "0.5057618", "0.50527155", "0.5051134", "0.5044735", "0.5044735", "0.50304633", "0.5024676", "0.50233567", "0.50206596", "0.5014371", "0.5010235", "0.5001603", "0.50004", "0.49991965", "0.49978536", "0.49965024", "0.49929473", "0.497885", "0.49686143", "0.4966078", "0.49590755", "0.49530503", "0.49523816", "0.49523032", "0.49473643", "0.49401698", "0.4939771", "0.4938584", "0.4931966", "0.49308917", "0.49306086", "0.49177176", "0.49167752", "0.49166378", "0.49136773", "0.4903927", "0.4900647", "0.48986357", "0.4891936", "0.48899144", "0.48815617", "0.48812893", "0.48781008", "0.48758724", "0.4875414", "0.4869169", "0.48586607", "0.48552153", "0.48531148", "0.4852616", "0.4852123", "0.48489827", "0.48430023", "0.48422495", "0.48356763", "0.48338917", "0.48331186", "0.48305428", "0.48298424", "0.4825438", "0.48111326", "0.4810276" ]
0.6911735
0
number 234 > 4+3+2 = 9 Scanner scan=new Scanner(System.in);
public static void main(String[] args) { int num=456; int rem1 = 456%10; System.out.println(rem1); //123 -> 12 int num2 = num/10; // 123/10 -> 12.3 -> 12 System.out.println(num2); int rem2=num2%10; // 12%10 -> 2 //12 ->1 int num3 = num2/10; // 12/10 -> 1.2 -> 1 int rem3 = num3%10; // 1%10 -> 1 System.out.println("The sum of digits: "+(rem1+rem2+rem3)); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public static void main (String[] args){\n int a,no,sum=0;\nScanner s=new Scanner(System.in);\n//System.out.println(\"Enter any number: \");\nno=s.nextInt();\nwhile(no>0)\n{\na=no%10;\nno=no/10;\nsum=sum+a;\n}\nSystem.out.println(sum);\n}", "int main()\n{\n int num;\n int q,r,sum;\n cin>>num;\n q=num/10;\n r=num%10;\n sum=q+r;\n cout<<\"Alice must go in path-\";\n cout<<sum;\n}", "public static int f_number_user(){\n Scanner keyboard=new Scanner(System.in);\r\n int digits;\r\n System.out.println(\"input the entire number \");\r\n digits=keyboard.nextInt();\r\n return digits;\r\n }", "public static void main(String args[])\n {\n Scanner in=new Scanner(System.in);\n int num=in.nextInt();\n int a=num%10;\n int b=(num/10)%10;\n int c=num/100;\n a=a*100;\n b=b*10;\n int sum=a+b+c;\n System.out.println(sum);\n }", "public static void main(String[] args) {\nint a,b,c;\r\nScanner input=new Scanner(System.in);\r\nSystem.out.println(\"Enter value for num1\");\r\na = input.nextInt();\r\nSystem.out.println(\"Enter value for num2\");\r\nb = input.nextInt();\r\nSystem.out.println(\"Enter value for num3\");\r\nc = input.nextInt();\r\n\r\nSystem.out.println(a*b+c);\r\n\t}", "public static void main(String[] args) {\n\n\n Scanner scanner = new Scanner(System.in);\n String info = \"\";\n\n int number = 0;\n while(true)\n {\n System.out.println(number);\n number++;\n if(number > 10)\n {\n break;\n }\n }\n }", "public static void main(String[] args) {\nScanner s=new Scanner(System.in);\r\nSystem.out.println(\"enter the numbr\");\r\nint n=Integer.parseInt(s.nextLine());\r\nint sum=0;int r=0;\r\nwhile(n>0)\r\n{\r\n\t\r\nr=n%10;\r\n\r\nsum=sum+n%10;\r\n\tn=n/10;\r\n\t\r\n\t\r\n\r\n}\r\nSystem.out.println( sum);\r\n\r\n\r\n\r\n\t}", "public void ex() {\n Integer num1;\n\tInteger num2;\n Scanner sc = new Scanner(System.in);\n //Solicitud de los datos\n System.out.println(\"Ingrese el valor de num1: \");\n num1 = sc.nextInt();\n System.out.println(\"Ingrese el valor de num2: \");\n num2 = sc.nextInt();\n //LLamado a los métodos\n\tdisplayNumberPlus10(num1, num2);\n displayNumberPlus100(num1, num2);\n\tdisplayNumberPlus1000(num1, num2);\n }", "public void findTotal() {\n\n int total = 0;\n Scanner input = new Scanner(System.in);\n\n int number;\n\n while ((number = input.nextInt()) != 0) {\n total = total + number;\n }\n System.out.println(total);\n }", "private int getNumber() {\n while (!scanner.hasNextInt()) {\n scanner.nextLine();\n System.out.print(\"Please, Enter a munber : \");\n }\n return scanner.nextInt();\n }", "public static void main(String[] args) {\n System.out.println(\"your number?\");\n Scanner s = new Scanner(System.in);\n int i1 = s.nextInt();\n int i2 = s.nextInt();\n int i3 = s.nextInt();\n int i4 = s.nextInt();\n int i5 = s.nextInt();\n int sum = i1 + i2 + i3 + i4 + i5;\n if (sum % 2 == 0) {\n System.out.println(sum);\n }\n }", "public static void main (String[] args){\n Scanner sc=new Scanner(System.in);\n int num=sc.nextInt();int sum=1;\n int lol=String.valueOf(num).length();\n while(num>0)\n {\n int h=num%10;\n sum=sum+fact(h);\n num=num/10;\n }\n int len=String.valueOf(sum).length();\n if(len==lol)\n System.out.println(\"Yes\");\n else\n System.out.println(\"No\");\n\t}", "public static void main(String[] args) {\n Scanner input = new Scanner(System.in);\n\n System.out.print(\"ENTER A NUMBER BETWEEN 0 AND 1000: \");\n int number = input.nextInt();\n \n //Extracting digits from the integer \n int number1 = number % 10;\n int number2 = (number / 10) % 10;\n int number3 = number / 100;\n\n //Adding the extracted digits\n int sum = number1 + number2 + number3;\n\n System.out.print(\"The sum of the digits is \" + sum +\"!\");\n \n }", "public static void main(String[] args) {\n\t\tScanner sc=new Scanner(System.in);\n\t\tSystem.out.println(\"Enter any int num\");\n\t\tint num=sc.nextInt();\n\t\t//lets say...9 is num..result--4+5,1+8\n\t\twhile(num>0)\n\t\t{\n\t\t\t\n\t\t}\n\t\t\n\t\t\n\t}", "int main() {\n \n \n int n1=0;\n int n2=0;\n int n3=0;\n int res=0;\n cin >> n1 >> n2 >> n3;\n res = n1 + n2 + n3;\n cout << res << endl;\n return 0;\n}", "public static void main(String[] args) {\n\t\tScanner s=new Scanner(System.in);\r\n\t\tSystem.out.println(\"ENTER THE NUMBER\");\r\n\t\tint number=s.nextInt();\r\n\t\tint i=0,j=0,r,sum=0;\r\n\t\tint a=number;\r\n\t\twhile(number>0)\r\n\t\t{\r\n\t\t\tr=number%10;\r\n\t\t\tsum=sum+r;\r\n\t\t\tnumber=number/10;\r\n\t\t}\r\n\t\tSystem.out.printf(\"SUM OF DIGIT=%d\", sum);\r\n\t}", "public static void main(String[] args) {\n\t\tScanner scanner = new Scanner(System.in);\n\t\t\n\t\tint result = 0;\n\t\tint number = scanner.nextInt();\n\t\t\n\t\tif(number <= 99) {\n\t\t\tSystem.out.print(number);\n\t\t}\n\t\telse {\n\t\t\t\n\t\t\tif(number == 1000){\n\t\t\t\tnumber = 999;\n\t\t\t}\n\t\t\t\n\t\t\tresult = 99 + getResult(number);\n\t\t\t\n\t\t\tSystem.out.println(result);\n\t\t}\n\t}", "public static int f_number_user() {\n Scanner keyboard = new Scanner(System.in);\n System.out.println(\"Input the number\");\n int number = keyboard.nextInt();\n return number;\n }", "public static void main (String[] args){\n Scanner in = new Scanner(System.in);\n int rem,t,sum=0;\n int n=in.nextInt();\n t=n;\n while(n!=0)\n {\n rem=n%10;\n sum=sum+(rem*rem*rem);\n n=n/10;\n }\n if(sum==t)\n System.out.println(\"Armstrong Number\");\n else\n System.out.println(\"Not a Armstrong Number\");\n }", "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 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 static void main(String[] args) {\n Scanner sc = new Scanner(System.in);\n int n;\n int result = 0;\n do {\n n = sc.nextInt();\n if (n > result) {\n result = n;\n }\n \n } while (n != 0);\n System.out.println(result);\n }", "private int getUserInput() {\n java.util.Scanner scanner = new java.util.Scanner(System.in);\n int input = scanner.nextInt();\n while(input < 1 || input > 3) {\n System.out.println(\"only enter 1 2 or 3.\");\n input = scanner.nextInt();\n }\n return input;\n }", "public static void main(String[] args) {\n\t\t\n\t\tScanner scanner=new Scanner(System.in);\n\t\tSystem.out.println(\"Enter a number to find sum of its digits \");\n\t\t\n\t\tint num = Math.abs(scanner.nextInt());\n\t\tint sum=0;\n\t\t\n\t\twhile(num!=0) {\n\t\t\t\n\t\t\tsum=sum+num%10;\n\t\t\tnum=num/10;\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t}\n\t\t\n\t\tSystem.out.println(\"the sup of digits is \"+ sum);\n\t\t\n\t\t\n\t\t \n\t\t\n\t\t\n\t\tscanner.close();\n\t}", "public static void main(String[] args) {\n\t\t\n\tScanner scan = new Scanner(System.in);\n\t\n\tSystem.out.print(\"Enter a value: \");\n\tbyte num = scan.nextByte();\n\t\n\t\n\tScanner input = new Scanner(System.in);\n\t\n\tSystem.out.print(\"Enter another value: \");\n\tint n = input.nextInt();\n\t\n\t\n\tScanner car = new Scanner(System.in);\n\t\n\tSystem.out.print(\"Enter third value: \");\n\tint nn = car.nextInt();\n\t\n\tSystem.out.print(\"The total value is: \" + (num + n + nn));\n\n\t\n\t\n\t\n\t}", "public static void main(String[]args) {\n\n System.out.println( \"enter a number:\" );\n String a = \"homosexual\";\n System.out.println( a.length() );\n\n String andrew = \"Hello\";\n Scanner can = new Scanner (System.in);\n System.out.println( \"Enter the next number\" );\n // to get the next integer\n System.out.println(can.nextInt()) ;\n\n\n\n\n\n\n\n\n\n}", "public static void main(String[] args) {\nchar c1,c2,c3;\r\nScanner cr=new Scanner(System.in);\r\nSystem.out.println(\"第一个字符:\");\r\nc1=cr.next().charAt(0);\r\nSystem.out.println(\"第二个字符:\");\r\nc2=cr.next().charAt(0);\r\nSystem.out.println(\"第三个字符:\");\r\nc3=cr.next().charAt(0);\r\nint x=(int)(c1+c2+c3);\r\nSystem.out.println(\"结果为:\"+x);\r\n\t}", "public static void main (String[] args){\n Scanner in = new Scanner(System.in);\n int n = in.nextInt();\n int count=0;\n int sum=0;\n int t;\n t=n;\n while(n>0)\n {\n int i=n%10;\n sum=sum+i*i*i;\n n=n/10; \n }\n if(sum==t)\n {\n System.out.println(\"Armstrong Number\");\n }\n else\n {\n System.out.println(\"Not a Armstrong Number\");\n }\n\t}", "@Test\n\tpublic void testInputWithMoreNumbers() {\n\t\tStringBuilder sb = new StringBuilder();\n\t\tfor (int i = 0; i <= 100; i++) {\n\t\t\tsb.append(i);\n\t\t\tif (i <100) {\n\t\t\t\tsb.append(\" \");\n\t\t\t}\n\t\t}\n\t\t\n\t\tassertEquals(\"Many numbers in input string\", 5050L, calculator.calculeteSum(sb.toString()).longValue());\n\t}", "public Ch12Ex1to9()\n {\n scan = new Scanner( System.in );\n }", "private static int validateInput() {\n Scanner genericInt = new Scanner(System.in);\n int number = 0;\n if (genericInt.hasNextInt()) {\n number = genericInt.nextInt();\n return number;\n }\n else {\n validateInput();\n }\n return number;\n }", "public static void main (String[] args){\n Scanner in = new Scanner(System.in);\n int n = in.nextInt();\n \n int temp = n;\n int copy = n;\n int sum = 0;\n int count = 0;\n int rem = 0;\n while(n!=0)\n {\n rem = n%10;\n count++;\n n = n/10;\n }\n while(temp!=0)\n {\n rem = temp%10;\n int count2 = 0;\n int expo = 1;\n int base = rem;\n \n while(count>count2)\n {\n expo = base * expo;\n count2++;\n }\n sum = sum+ expo;\n temp = temp/10;\n }\n if(sum == copy)\n {\n System.out.println(\"Armstrong Number\");\n }\n else\n {\n System.out.println(\"Not a Armstrong Number\");\n }\n\t}", "public static void main(String[] args) {\n\t\tSystem.out.println(\"enter the number:\");\r\n\t\tScanner sc=new Scanner(System.in);\r\n\t\tint a=sc.nextInt();\r\n\t\tint i=0,j=0;\r\n\t\tint n=a;\r\n\t\twhile(n>0)\r\n\t\t{\r\n\t\t\ti=n%10;\r\n\t\t\tj=j*10+i;\r\n\t\t\tn=n/10;\r\n\t\t\r\n\t\t}\r\n\t\tSystem.out.println(j);\r\n\t\t\r\n\r\n\t}", "public static void main(String[] args) {\nScanner sc=new Scanner(System.in);\nint a= sc.nextInt();\nint b=sc.nextInt();\nint c=sc.nextInt();\nif(a+b==10 || b+c==10 || c+a==10)\n{\nSystem.out.println(\"The out put value is: \"+10);\n}\nelse if ((a+b)==(b+c)+10 || (a+b)==(c+a)+10 )\n\t\n{\n\tSystem.out.println(\"The out put value is: \"+5);\n}\nelse{\n\tSystem.out.println(\"The out put value is: \"+0);\n}\n\t}", "public static int getInt()\n {\n int num=0;\n while (true)\n {\n Scanner keyboard = new Scanner(System.in);\n try{\n num = keyboard.nextInt();\n return num;\n }\n catch (java.util.InputMismatchException textException)\n {\n System.out.printf(\"result:\");\n }\n }\n }", "public static void main(String args[]){\n int d, n, m = 0;\n \n //ENTRADA\n \n Scanner teclado = new Scanner(System.in);\n System.out.print(\"Numero : \");\n n = teclado.nextInt(); \n \n //PROCESO\n \n while(n > 0){\n d = n % 10;\n if(d > m){\n m = d;\n }\n n = n / 10;\n System.out.println(\"Valor de n: \"+n+\",\"+\" Valor de d: \"+d+\" ,Valor de m: \"+m );\n\n }\n \n //SALIDA \n System.out.println(\"\");\n System.out.println(\"Digito Mayor: \" + m);\n \n }", "private static void task44() {\n System.out.print(\"Enter value: \");\n int n = scanInt();\n\n String str = n + \" + \" + n + \"\" + n + \" + \" + n + \"\" + n + \"\" + n;\n System.out.println(\"\\n\" + str);\n System.out.printf(\"%d + %d%d + %d%d%d\", n, n, n, n, n, n);\n }", "public static Integer scanInt() {\n\t\tboolean is_Nb = false; int i = 0;\r\n\t\tdo {\r\n\t\t\ttry {\r\n\t\t\t\ti = Integer.parseInt(scan.nextLine());\r\n\t\t\t\tis_Nb= true;\r\n\t\t\t}\r\n\t\t\tcatch(NumberFormatException e) {\r\n\t\t\t\tSystem.out.println(\"Enter a number\");\r\n\t\t\t}\r\n\t\t}while(!is_Nb);\r\n\t\treturn i;\r\n\t}", "public static void main (String[] args){\n Scanner in = new Scanner (System.in);\n int num = in.nextInt();\n int sum=1,sum1=0,n,check=num;\n for(;num!=0;)\n {\n n=num%10;\n sum=1;\n for( int i=n;i>0;i--){\n sum=sum*i;\n }\n sum1 = sum1+sum;\n num=num/10;\n \n }\n if(check==sum1)\n System.out.println(\"Yes\");\n else\n System.out.println(\"No\");\n\n\n\t}", "public static void main(String[] args) {\n int a = 2;\n int b = 3;\n int c = 4;\n int d = 5;\n System.out.println(\"Result: \"+a*b*c*d);\n\n// Part 2: Use scanner to provide numbers\n Scanner s1 = new Scanner (System.in);\n System.out.println(\"Enter one integer to e: \" );\n int e = s1.nextInt();\n System.out.println(\"Enter one integer to f: \" );\n int f = s1.nextInt();\n System.out.println(\"Enter one integer to g: \" );\n int g = s1.nextInt();\n System.out.println(\"Enter one integer to h: \" );\n int h = s1.nextInt();\n System.out.println(\"Result: \" +e*f*g*h);\n\n// 3. way\n int result = 2; // 2\n result = result * 3; // 2 * 3 = 6\n result = result * 4; // 6 * 4 = 24\n result = result * 5; // 24 * 5 = 120\n System.out.println( \"3. way: \" + result );\n }", "public static void main(String[] args){\n int number = scn.nextInt();\n \n \n int a = num(number);\n System.out.println(a);\n \n \n }", "public static void main(String[] args) {\n Scanner scan = new Scanner(System.in);\n System.out.print(\"Input a number: \");\n int number = scan.nextInt();\n if (number > 0) {\n while (number % 2 == 0) {\n System.out.print(2 + \" \");\n number /= 2;\n }\n\n for (int i = 3; i <= Math.sqrt(number); i += 2) {\n while (number % i == 0) {\n System.out.print(i + \" \");\n number /= i;\n }\n }\n if (number > 2)\n System.out.print(number);\n }\n }", "public static void main(String[] args) {\n\n Scanner sc = new Scanner(System.in);\n System.out.println(\"Enter a number: \");\n int number = sc.nextInt();\n\n int remainder;\n int sum = 0;\n int newSum = 0;\n int singleDigitNumber;\n if (number < 0) {\n System.exit(1);\n }\n while (number != 0) {\n remainder = number % 10;\n sum += remainder;\n number = number / 10;\n }\n\n if (sum < 10) {\n System.out.println(\"The sum of digits in entered number is: \" + sum);\n } else {\n while (sum != 0) {\n singleDigitNumber = sum % 10;\n newSum += singleDigitNumber;\n sum = sum / 10;\n\n }\n if (newSum == 10) {\n System.out.println(\"The sum of digits in entered number is: \" + 1);\n System.exit(1);\n }\n System.out.println(\"The sum of digits in entered number is: \" + newSum);\n }\n }", "public static void main(String[] args) {\n Scanner s = new Scanner(System.in);\n System.out.println(\"Input first number:\");\n int nr1 = s.nextInt();\n System.out.println(\"Input second number:\");\n int nr2 = s.nextInt();\n System.out.println(\"Input third number:\");\n int nr3 = s.nextInt();\n System.out.println(compareNumbers(nr1,nr2,nr3));\n}", "public static void main(String[] args) {\n\t\tScanner scan = new Scanner(System.in);\n\t\t\n\t\tint sum = 0;\n\t\tint count=1;\n\t\t\n\t\twhile(count<20) {\n\t\t\t\n\t\t\tsum= sum+count;\n\t\t\tSystem.out.println(\"current sum is: \" + sum + \"and\"+ \"count is: \" +count);\n\t\t\t//System.out.println(count);\n\t\t\tcount++;\n\t\t}\n\t\tSystem.out.println(\"total sum is: \"+sum);\n\t\t\n\t\t/*Birinin:\n\t\t * int firstNumber = 0;\n int secondNumber = 0;\n int total = 0;\n int tempNumber = 0;\n \n Scanner scan = new Scanner(System.in);\n System.out.println(\"Enter first number: \");\n firstNumber = scan.nextInt();\n System.out.println(\"Enter second number: \");\n secondNumber = scan.nextInt();\n \n if ( firstNumber > secondNumber) {\n tempNumber = firstNumber;\n firstNumber = secondNumber;\n secondNumber = tempNumber;\n }\n int x = firstNumber;\n while (x <=secondNumber) {\n total = total + x++;\n }\n System.out.println(\"The total :\"+total);\n\t\t */\n\t\t\n\t\t\n\t\t// how do you get the the sum of number \n\t\t\t\t// starting from one till desiged number \n\t\t\t\t// user input 5 --> 1+2+3+4+5 = 15 ; \n\t\t\t\t\n\t\t\t//\tint sum = 0 ; \n\t\t\t\t// 1 + 0 = 1 \n\t\t\t\t// 2 + 1 = 3 \n\t\t\t\t// 3 + 3 = 6 \n\t\t\t\t// ..... \n\t\t\t\t//int count = 1 ; \n\t\t\t\t\n\t\t\t\t//while(count <=100) {\n\t\t\t\t\t\n\t\t\t\t//\tsum = sum + count ; \n\t\t\t\t//\tSystem.out.println(\"current sum :\"+sum + \" count is \"+ count );\n\t\t\t\t\t//System.out.println(count);\n\t\t\t\t\t//count++;\n\t\t\t\t//}\n\t\t\t\t\n\t\t\t\t//System.out.println(sum);\n\n\t\t\n\t}", "public static void main(String[] args) {\n\n\n Scanner scan = new Scanner(System.in);\n\n System.out.print(\"Bir Sayı Girin: \");\n\n int num = scan.nextInt();\n\n int adet = 0,toplam=0;\n\n while(num != 0) {\n toplam=(num%10)+toplam;\n num /= 10;\n ++adet;\n }\n\n System.out.println(\"Basamak Toplamı: \" + toplam);\n }", "public static void main (String[] args){\n Scanner in = new Scanner ( System.in ); \n int n = in.nextInt ( ); \n int n1=n;\n int n2 =n;\n int count=0;\n int digit;\n int sum=0;\n while (n1>0)\n {\n n1=n1/10;\n count++;\n }\n while (n>0)\n {\n digit=n%10;\n n=n/10;\n sum=sum+ (digit*digit*digit);\n }\n if (sum==n2)\n System.out.println ( \"Armstrong Number\");\n else\n System.out.println ( \"Not a Armstrong Number\");\n\t}", "public static void main(String[] args) {\n Scanner scn =new Scanner(System.in);\n boolean b=true;\n while(b)\n {\n \n char ch=scn.next().charAt(0);\n \n if(ch=='+'||ch=='-'||ch=='*'||ch=='/'||ch=='%')\n {\n\t int N1 =scn.nextInt();\n\t int N2 =scn.nextInt();\n\t calculator(ch,N1,N2);\n }\n else if(ch!='X'&&ch=='x')\n\t {System.out.println(\"try again\");}\n else\n\tbreak;\n }\n }", "public static void main(String[] args) {\n\t\tScanner kb = new Scanner(System.in);\r\n\t\tSystem.out.print(\"Input a number: \");\r\n\t\tint n = kb.nextInt();\r\n\t\tdo\r\n\t\t{\r\n\t\t\tn = SoD(n);\r\n\t\t}\r\n\t\twhile (n > 9);\r\n\t\tSystem.out.println(n);\r\n\t}", "public static void main (String[] args){\n Scanner sc = new Scanner(System.in);\n int num = sc.nextInt();\n int temp = num;\n int c = 0;\n \n while (num != 0)\n {\n int a = num%10;\n num = num/10;\n c = c + (a*a*a);\n \n }\n \n \n \n if(c == temp)\n System.out.println(\"Armstrong Number\");\n else\n System.out.println(\"Not a Armstrong Number\");\n \n\t}", "public static void main(String[] args) {\r\n\t\tScanner scan = new Scanner(System.in);\r\n\t\tString a = scan.next();\r\n\t\tint x = Integer.parseInt(a);\r\n\t\tList<Integer> list = new ArrayList<>();\r\n\t\twhile (scan.hasNextInt()) {\r\n\t\t\tlist.add(scan.nextInt());\r\n\t\t}\r\n\t\tif (x > list.size()) {\r\n\t\t\tSystem.out.println(\"NIL\");\r\n\t\t\treturn;\r\n\t\t}\r\n\t\tSystem.out.println(list.get(list.size() - x));\r\n\t}", "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}", "public static <integer> void main(String[] args) {\n Scanner scanner = new Scanner(System.in);\n System.out.print(\"Please enter the first number: \");\n String first, second;\n first = scanner.nextLine();\n int convertedFirst = Integer.parseInt(first);\n System.out.print(\"Please enter the second number: \");\n second = scanner.nextLine();\n int convertedSecond = Integer.parseInt(second);\n\n int resultAdd, resultSub;\n resultAdd = convertedFirst + convertedSecond;\n resultSub = convertedFirst - convertedSecond;\n System.out.println(\"Addition result is \" + resultAdd);\n System.out.println(\"Subtraction result is \" + resultSub);\n\n\n\n\n\n\n\n\n }", "public static void main(String[] args) {\n Scanner sc = new Scanner(System.in);\r\n\r\n System.out.println(\"Enter a number you want to find the sum of it's digits: \");\r\n\r\n\r\n // Numerical data input\r\n //To read numerical values of a certain data type XYZ, the function to use is nextXYZ().\r\n int sum_of_digits = sc.nextInt();\r\n\r\n //call function and assign to variable\r\n int result = sumDigits(sum_of_digits);\r\n\r\n //print all sum\r\n System.out.println(\"The sum of the digits in \" + sum_of_digits + \" is: \" + result);\r\n\r\n }", "public static void twoNumbers() {\n\n\t\tint x;\n\t\tint z;\n\t\tScanner input = new Scanner(System.in);\n\n\t\tSystem.out.println(\"skriv in två olika tal\");\n\n\t\tx = input.nextInt();\n\t\tz = input.nextInt();\n\n\t\tSystem.out.println(minstaTal(x, z));\n\n\t}", "public static void main (String[] args){\n int num;\n Scanner n = new Scanner(System.in);\n num = n.nextInt();\n int sod = sum(num);\n System.out.println(sod);\n\t}", "public static void main(String[] args) {\nScanner Sc= new Scanner(System.in);\nSystem.out.printf(\"Nhap vao so N = \");\nint N = Sc.nextInt();\nint S=0,i;\nfor (i=1;i<=N;i++)\n S=S+(10*i+i);\nSystem.out.printf(\"\\n%d\",S);\n\n\t}", "public static void main(String args[])\n\t{\n\t\tint rem,temp,i=1;\n\t\t//temp variable is ued to store initial value of num.\n\t\t//i variabble is used as starting point.\n\t\tScanner scr=new Scanner(System.in);\n\t\tSystem.out.println(\"enter a number here :\");\n\t\tint num=scr.nextInt();\n\t\ttemp=num;\n\t\twhile(num>0)\n\t\t{\n\t\t\trem=num%10;\n\t\t\tSystem.out.print(rem+\" \");\n\t\t\tnum=num/10;\n\t\t\t\n\t\t}\n\t\t\n\t\t\n\t\t\n\t}", "private int receiveNumberInput() {\n int number;\n while (true) {\n try {\n String temp = userInput.nextLine();\n number = Integer.parseInt(temp);\n break;\n } catch (NumberFormatException e) {\n System.out.println(\"Invalid Input. Please enter a valid number.\");\n continue;\n }\n\n }\n return number;\n }", "public static void main(String[] args) {\n\n\n Scanner scanner = new Scanner(System.in);\n System.out.println(\"Testing Int Inputs\");\n System.out.print(\"Enter Number 1: \");\n int number1 = scanner.nextInt();\n System.out.println(number1);\n System.out.println(\"Enter Number 2: \");\n int number2 = scanner.nextInt();\n System.out.println(number2);\n }", "private void nextNumber() {\n\t\tint old=pos;\n\t\tmany(digits);\n\t\ttoken=new Token(\"num\",program.substring(old,pos));\n }", "private static double getNumber() {\n double number;\n\n // Repeat reading until the user enters a valid number.\n while (true) {\n try {\n number = scanner.nextDouble();\n scanner.nextLine(); // Remove \\n from the scanner.\n break;\n } catch (java.util.InputMismatchException ex) {\n System.out.println(\"Enter double\");\n scanner.nextLine(); // Remove invalid data from the scanner.\n }\n }\n\n return number;\n }", "public static void main(String args[])\n {\n Scanner input = new Scanner(System.in);\n int num = input.nextInt();\n int d1 = num%10;\n num /= 10;\n int d2 = num%10;\n num /= 10;\n num += (d2*10 + d1*100);\n System.out.print(num);\n }", "public void codeJ(int number) {\n\tString d;\n\t\n\t//Scanner scan = new Scanner(System.in);\n\tdo {\n\tdo{\n\t\t\n\t\tif (App.SCANNER.hasNextInt()) {\n\t\t\n\t\t}else {\n\t\t\tSystem.out.println(\" Entrez Uniquement un code a \" + number + \"chiffres\");\n\t\t\tApp.SCANNER.next();\n\t\t}\n\t\t\n\t\n\t}while(!App.SCANNER.hasNextInt()) ;\n\tthis.codeHumain=App.SCANNER.nextInt();\n\td = Integer.toString(codeHumain);\n\t\n\tif(d.length() != number) {\n\t\tSystem.out.println(\" Entrez Uniquement un code a \" + number + \"chiffres svp\" );\n\t}else if(d.length() == number) {\n\t}\n\t\n\t\n\t\n\t}while(d.length() != number) ;\n\t\n\t//scan.close();\n\t}", "public static void main(String[] args) {\n int num;\n Scanner sc = new Scanner(System.in);\n\n //Getting inputs\n System.out.print(\"Enter number: \");\n num = sc.nextInt();\n\n //Do the thing while num>1\n while(num>1){\n if(num%2==0){\n num = num/2;\n }else{\n num = num*3 + 1;\n }\n System.out.print(num+\" \");\n }\n\n //Close the Scanner\n sc.close();\n }", "int promptNumber();", "public static void main (String[] args) throws java.lang.Exception\n\t{\n int T, N;\nScanner sc= new Scanner(System.in);\n T=sc.nextInt();\n for(int i=0;i<T;i++)\n {\n N=sc.nextInt();\n int K=N;\n String str=N+\"\";\n if(N==0)\n {\n System.out.println(\"Case #\"+(i+1)+\": INSOMNIA\");\n continue;\n }\n while(true)\n {\n if(str.contains(\"0\") && str.contains(\"1\") && str.contains(\"2\") && str.contains(\"3\") &&str.contains(\"4\")\n && str.contains(\"5\") &&str.contains(\"6\") &&str.contains(\"7\") && str.contains(\"8\") &&str.contains(\"9\"))\n {\n System.out.println(\"Case #\"+(i+1)+\": \"+N);\n break;\n }\n else\n {\n N+=K;\n str+=N;\n } \n }\n\t}\n}", "public static void main(String[] args) {\n\t\tScanner sc = new Scanner(System.in);\r\n\t\tint number,sum = 0;\r\n\t\tdo\r\n\t\t{\r\n\t\t\tSystem.out.println(\"Nhap so:\");\r\n\t\t\tnumber = sc.nextInt();\r\n\t\t\tsum += number;\r\n\t\t\tif(sum>100)\r\n\t\t\t\tbreak;\r\n\t\t}while(number>0);\r\n\t\tSystem.out.println(\"Tong =\" + sum);\r\n\r\n\t}", "public static void main(String[] args) {\n\t Scanner numara=new Scanner(System.in);\n\t System.out.println(\"Please enter your first number\");\n\t int num1=numara.nextInt();\n\t \n\t System.out.println(\"please enter your second number\");\n int num2=numara.nextInt();\n \n if(num1>num2) {System.out.println(num1+\" larger than \"+num2);}\n else if(num1==num2) {System.out.println(num1+\" equel \"+num2);}\n else {System.out.println(num1+\" smaller than \"+num2);}\n \n \n\t \n\t \n}", "static void DanrleiMethod() {\n\n int input1, input2, multiply;\n\n try {\n BufferedReader myKB = new BufferedReader(new InputStreamReader(System.in));\n\n System.out.println(\"Please enter a number\");\n input1 = Integer.parseInt(myKB.readLine());\n\n System.out.println(\"Please enter another number\");\n input2 = Integer.parseInt(myKB.readLine());\n multiply = input1 * input2;\n\n System.out.println(input1 + \" multiplied by \" + input2 + \" is \" + multiply);\n\n } catch (Exception e) {\n System.out.println(\"Invalid input, please enter only numbers\");\n\n }\n\n }", "public static void main(String[] args) {\n Scanner scanner = new Scanner(System.in);\n\n //Reads ints from user\n int class1 = scanner.nextInt();\n int class2 = scanner.nextInt();\n int class3 = scanner.nextInt();\n\n //Your code goes here\n class1 = class1/2 + class1%2;\n class2 = class2/2 + class2%2;\n class3 = class3/2 + class3%2;\n int total = class1 + class2 + class3;\n System.out.print(total);\n\n // closing the scanner object\n scanner.close();\n }", "public static void main (String[] args) {\n Scanner s = new Scanner(System.in);\n String input = s.nextLine();\n int result = Integer.parseInt(input);\n System.out.println(SimpleAdding(result));\n }", "public static void main(String[] args) {\n\r\n\t\t\r\n\tint prix=1, paiement=0,montant=0,Reste, Nb10E, Nb5E;\r\n\tchar rep='t';\r\n\tdo {\r\n\t\tSystem.out.println(\"saisir un prix\");\r\n\t\tScanner saisie = new Scanner(System.in);\r\n\t\tprix= saisie.nextInt();\r\n\t\t\r\n\t\tmontant=montant+prix; \r\n\t\t\r\n\t\tSystem.out.println(\"Voulez vous entrer un autre prix ? c pour continuer et t pour terminer\");\r\n\t\tScanner clavier=new Scanner (System.in);\r\n\t\trep= clavier.nextLine().charAt(0);\r\n\t\t\r\n\t}\r\n\t\t\r\n\t\r\n\t while (rep!='t');\r\n\t{\r\n\t\t System.out.println(\"saisir un prix\");\r\n\t\t\tScanner sc = new Scanner(System.in);\r\n\t\t\tprix= sc.nextInt();\r\n\t\t\t\r\n\t }\r\n\t\r\n\tSystem.out.println(\"le montant total est\"+montant); \r\n\r\n\tSystem.out.println(\"Saisir le paiement\");\r\n\tScanner sp = new Scanner(System.in);\r\n\tpaiement= sp.nextInt();\r\n\t\r\n\tReste = paiement-montant;\r\n\r\n\tNb10E = 0;\r\n\t\r\n\twhile (Reste >= 10 ) {\r\n\t Nb10E = Nb10E + 1;\r\n\t Reste = Reste-10;\r\n\t}\r\n\t Nb5E = 0;\r\n\t if (Reste >= 5) {\r\n\t\t Nb5E= 1;\r\n\t\t Reste = Reste-5;\r\n\t }\r\n\t\r\n\r\n\tSystem.out.println(\"Rendu de la monnaie\"); \r\n\tSystem.out.println(\"10 E\"+ Nb10E);\r\n\tSystem.out.println(\"Billets de 5 E\"+Nb5E); \r\n\tSystem.out.println(\"Pièces de 1 E\"+Reste);\r\n\r\n\t\r\n\tsp.close();\r\n\t\t\r\n\t\t\r\n\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\r\n\t\t\r\n\t\t\r\n\t}", "public static void main(String[] args) {\n Scanner sc=new Scanner(System.in);\n\n int count=0;\n\n for(int i=1;i<=10;i++)\n\n {\n System.out.println(\"Enter value: \\t\");\n\n int x=sc.nextInt(); //assign the next integer to x\n\n count=count+x;\n Scanner close;\n\n }\n\n System.out.println(\"The sum is: \"+count);\n\n }", "public static void main(String[] args) {\n\n\t\t Scanner sc = new Scanner(System.in);\n\t\t String numb = sc.nextLine();\n\t\t char[] numbArr = numb.toCharArray();\n\t\t int sum =0;\n\t\t for(int i =0 ; i < numbArr.length ; i++){\n\t\t sum += Math.pow(Character.getNumericValue(numbArr[i]),3);\n\t\t }\n\t\t \n\t\t if(sum == Integer.parseInt(numb)){\n\t\t System.out.println(true);\n\t\t }else{\n\t\t System.out.println(false);\n\t\t }\n\n\t\t }", "@Test\n\tpublic void one()\n\t{\n\t\tScanner sc = new Scanner(System.in);\n\t\t\n\t\tSystem.out.println(\"enter the value of a\");\n\t\tint a = sc.nextInt();\n\t\tSystem.out.println(\"value of a is: \" +a);\n\t}", "public static void main(String args[])\n {\n \n Scanner in = new Scanner(System.in);\n int n = in.nextInt();\n int f = n/100;\n int s = ((n/10)%10);\n int t = n%10;\n int r = (t*100)+(s*10)+f;\n System.out.println(r);\n }", "public static void main(String[] args) {\n int sum = 0;\n int num;\n System.out.println(\"Give your no:\");\n Scanner keyboard = new Scanner(System.in);\n\n num = keyboard.nextInt();\n for (int i = 1; i <= num; i++) {\n sum = sum + i;}\n System.out.println(sum);\n\n }", "private int read()\r\n {\r\n Scanner keyboard = new Scanner(System.in);\r\n System.out.println(\"Enter the number: \");\r\n int i = keyboard.nextInt();\r\n if (i > 999999999){\r\n System.out.println(\"The number you have introduced is too big!\");\r\n i = read();\r\n }\r\n if (i < 0){\r\n System.out.println(\"The number you have introduced is negative!\");\r\n i = read();\r\n }\r\n return i;\r\n }", "static void AlineMethod(){\n \n int a, l, total;\n Scanner myKb = new Scanner(System.in);\n \n try {\n \n \n System.out.println(\"Please, enter a number.\");\n a = Integer.parseInt(myKb.nextLine());\n \n System.out.println(\"Please, enter a second number.\");\n l = Integer.parseInt(myKb.nextLine());\n \n total = a - l;\n \n System.out.println(\"If you subtracted the second number of the first number is: \" + total + \".\");\n }\n \n catch(Exception e){\n \n System.out.println(\"Sorry, only integers allowed.\");\n \n }\n \n \n }", "public static void main (String[] args){\n\tScanner in = new Scanner(System.in);\n\t\n\tSystem.out.print(\"Enter the first number: \");\n\tint n1 = in.nextInt();\n\t\n\tSystem.out.print(\"Enter the second numer: \");\n\tint n2 = in.nextInt();\n\t\n\tint ans = n1 + n2;\n\tSystem.out.printf(\"%d + %d = %d\\n\", n1, n2, ans);\n\t\n\tans = n1 - n2;\n\tSystem.out.printf(\"%d - %d = %d\\n\", n1, n2, ans);\n\t\n\tans = n1 * n2;\n\tSystem.out.printf(\"%d * %d = %d\\n\", n1, n2, ans);\n\t\n\tans = n1 / n2;\n\tSystem.out.printf(\"%d / %d = %d\\n\", n1, n2, ans);\n\t\n\tin.close();\n\t\t\n\t}", "public static void main (String[] args) throws java.lang.Exception\n\t{\n Scanner sc = new Scanner(System.in);\n int t= Integer.parseInt(sc.next());\n \n while(t-->0)\n {\n int[] arr = new int[5];\n int sum=0;\n for(int i=0;i<5;i++)\n {\n arr[i]=Integer.parseInt(sc.next());\n sum+=arr[i];\n }\n \n int p =Integer.parseInt(sc.next());\n if(p*sum>120)\n {\n System.out.println(\"Yes\");\n }\n else\n {\n System.out.println(\"No\");\n }\n } \n }", "public static void main(String[] args) {\n \r\n Scanner sc = new Scanner(System.in);\r\n ArrayList<Integer> digits = new ArrayList<Integer>();\r\n System.out.println(\"Enter the input\");\r\n int n = sc.nextInt();\r\n for (int i=1;i<=n;i++) {\r\n int digit = sc.nextInt();\r\n digits.add(digit);\r\n }\r\n int b = sc.nextInt();\r\n int c = sc.nextInt();\r\n int res = solve(digits, b, c);\r\n\r\n\r\n }", "public void execute() {\n String input;\n boolean isInputValid;\n\n do {\n isInputValid = true;\n\n System.out.print(\"Please send me the numbers using space between them like \\\"1 2 3\\\": \");\n input = sc.nextLine();\n\n try {\n validateData(input);\n } catch (NumberFormatException e) {\n System.err.println(\"NumberFormatException \" + e.getMessage());\n isInputValid = false;\n }\n\n } while (!isInputValid);\n\n System.out.println(\"Result: \" + find(input));\n }", "int main()\n{\n int a,b,c;\n std::cin>>a>>b>>c;\n std::cout<<a*b-a*c-100;\n}", "public static void main (String[] args){\n Scanner joe= new Scanner(System.in);\n int n= joe.nextInt();\n int cd=0;\n int temp=n;\n int digit;\n int sum=0;\n while(n>0)\n {\n int prod=1;\n digit = n % 10;\n for(int i =1;i<=digit;i++)\n {\n prod = prod * i;\n }\n //System.out.println(prod);\n sum = sum+prod;\n n = n/10;\n\t }\n if(temp==sum)\n {\n System.out.println(\"Yes\");\n //System.out.println(sum);\n }\n else\n {\n System.out.println(\"No\");\n // System.out.println(sum);\n }\n }", "private int takeChangeInput() {\n\t\tSystem.out.println(\"Enter desired change amount\");\n\n\t\tString amount = scan.next();\n\t\twhile (!amount.matches(\"\\\\d+\")) {\n\t\t\tSystem.out.println(\"Invalid input, please try again.\");\n\t\t\tamount = scan.next();\n\t\t}\n\n\t\tint change = Integer.valueOf(amount);\n\n\t\treturn change;\n\t}", "public static void main(final String[] args) {\n int remainder;\n int sum = 0;\n final int tensPlace = 10;\n System.out.println(\"Enter a Number:\"); // prints Hello World\n final Scanner inputScan = new Scanner(System.in);\n try {\n remainder = inputScan.nextInt();\n while (remainder > 0) {\n sum = sum + remainder % tensPlace;\n remainder = remainder / tensPlace;\n }\n System.out.println(\"Sum of digits is = \" + sum);\n } catch (InputMismatchException e) {\n System.out.println(\"Invalid input\");\n } finally {\n inputScan.close();\n }\n }", "public static void main(String[] args) throws IOException {\n\r\n\t\tScanner sc = new Scanner(System.in);\r\n\t\tint num1 = sc.nextInt();\r\n\t\tint num2 = sc.nextInt();\r\n\t\tint num3 = sc.nextInt();\r\n\t\tint result = num1 * num2 * num3;\r\n\r\n\t\tint[] number = new int[10];\r\n\t\twhile (result > 0) {\r\n\t\t\tnumber[result % 10]++;\r\n\t\t\tresult /= 10;\r\n\t\t}\r\n\r\n\t\tfor (int a : number) {// 각 숫자 갯수 출력\r\n\t\t\tSystem.out.println(a);\r\n\t\t}\r\n\r\n\t}", "public static int inputInt(String p) {\n String tmp;\n int i = 0;\n\n do {\n System.out.print(p);\n try {\n tmp = in.nextLine();\n if (Integer.parseInt(tmp) == Integer.parseInt(tmp)) {\n i = Integer.parseInt(tmp);\n }\n break;\n } catch (Exception e) {\n System.err.print(\"You must be enter interger number, enter again.\\n\");\n }\n } while (true);\n return i;\n }", "private int getOrderNumber()\n {\n Scanner scanner = new Scanner(System.in);\n System.out.println(\"\");\n System.out.print(\"Indtast ordrenummer: \");\n return scanner.nextInt();\n }", "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 }", "public static void milestone2(Scanner scanner) {\n Scanner sc = new Scanner(System.in);\n int average = 0;\n int counter = 0;\n int sum = 0;\n int num3 = 0;\n num3 = sc.nextInt();\n while (num3 >= 0)\n {\n counter++;\n sum +=num3;\n \n num3 = sc.nextInt();\n }\n if (counter == 0)\n counter = 1;\n average = sum/counter;\n System.out.println(\"this is the average:\" + average);\n sc.close();\n }", "include<stdio.h>\nint main()\n{\n int num,first_digit,last_digit,sum;\n scanf(\"%d\",&num);\n last_digit = num%10;\n first_digit=num;\n while(num>10)\n {\n num=num/10;\n }\n first_digit=num;\n sum = first_digit + last_digit;\n printf(\"%d\",sum);\n return 0;\n}", "public static int Num1() {\n\t\t Scanner s=new Scanner(System.in);\r\n\t\t System.out.println(\"Enter Num1 & Num2\");\r\n\t\t int num1=s.nextInt();\r\n\t\t int num2=s.nextInt();\r\n //System.out.println(num1*num2);\r\n\t\t int res=num1*num2;\r\n\t\t return res;\r\n\t}", "public static void main(String[] args) {\n\t\tInteger n;\nScanner sc= new Scanner (System.in);\n System.out.print (\"Introdusca un Numero\");\n\t\tn = sc. nextInt();\n\t\tif (n%2==0);\n\t\t\tSystem.out.print(\"Es un numero par\");\n\t\n\telse\n\t\t\tSystem.out.print(\"es un numero impar\");\n\t\t\n\n\t}", "public static void main(String[] args) {\n\t\tScanner num= new Scanner(System.in);\n\t\tSystem.out.println(\"Enter Your First Number=\");\n\t\tint a =num.nextInt();\n\t\t\n//\t\tSystem.out.println(\"Yoour Number is =\"+a);\n\t\tSystem.out.println(\"Enter Your Second Number=\");\n\t\tint b =num.nextInt();\n\t\tSystem.out.println(\"Enter Your Operation=\");\n\t\tnum.nextLine();\n\t\tchar operation=num.nextLine().charAt(0);\n\t\tint result=0;\n\t\t\n\t\tswitch(operation) {\n\t\tcase '+':\n\t\t\tresult =a+b;\n\t\t\tbreak;\n\t\tcase '-':\n\t\t\tresult =a-b;\n\t\t\tbreak;\n\t\tcase '*':\n\t\t\tresult =a*b;\n\t\t\tbreak;\n\t\tcase '/':\n\t\t\tresult =a/b;\n\t\t\tbreak;\n\t\tdefault:\n\t\t\tSystem.out.println(\"Enter Value Are Invalid\");\n\t\t}\n\t\tSystem.out.println(\"Answer For Your Operation \"+ result);\n\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t\n\t}", "public static void main(String[] args) {\n\t\tScanner scn = new Scanner(System.in);\n\t \n while(true){\n int flag = 0, N2 = 0, N1 = 0,N3=0;\n char ch = scn.next().charAt(0);\n if (ch == 'x'|| ch == 'X')\n {\n System.out.println(ch);\n return;\n }\n else if(ch== '+') flag = 1;\n else if (ch =='-')flag = 1;\n else if (ch =='*')flag = 1;\n else if(ch =='%')flag = 1;\n else if(ch =='/')flag = 1;\n \n if(flag!=1)System.out.println(\"Invalid operation. Try again.\");\n else\n {\n N1 = scn.nextInt();\n N2 = scn.nextInt();\n if(ch == '+') N3 = N2+ N1;\n else if (ch =='-')N3 =N2-N1;\n else if (ch =='*')N3 = N2*N1;\n else if(ch =='%')N3 = N2%N1;\n else if(ch =='/')N3 = N2/N1;\n System.out.println(N3);\n }\n }\n\t}", "public static int getNumber(Scanner input) {\r\n int number = 6;\r\n try {\r\n while (true) {\r\n System.out.print(\"Input a number: \");\r\n if (input.hasNextInt())\r\n number = input.nextInt();\r\n else {\r\n System.out.println(\"Incorrect input!\");\r\n input.next();\r\n continue;\r\n }\r\n break;\r\n }\r\n } catch (Exception ignored) { }\r\n return number;\r\n }", "public static float readNumFromConsole(Scanner scan1) {\n \t String str = null;\r\n \t Pattern p = Pattern.compile(\"^\\\\d+(?:\\\\.\\\\d+)?$\");\r\n \t Matcher m = null;\r\n \t int counter = 0;\r\n \t \tdo {\r\n \t \t\tif (counter != 0) {\r\n \t \t\t\tSystem.out.println(\"Invalid numeric input\");\r\n \t \t\t}\r\n \t \t\tstr = scan1.nextLine();\r\n \t \t\tm = p.matcher(str);\r\n \t \t\tcounter++;\r\n\t \t} while(!m.matches());\r\n \t //scan1.close();\r\n \t return Float.parseFloat(str);\r\n\t }", "public int sjekkOmTall() {\r\n Scanner scan2 = new Scanner(System.in);\r\n int valg;\r\n while(true) {\r\n if(scan.hasNextInt()) {\r\n return valg = Integer.parseInt(scan.nextLine());\r\n }\r\n else {\r\n System.out.println(\"Du skrev ikke inn et tall\");\r\n scan.nextLine();\r\n }\r\n }\r\n }" ]
[ "0.6615837", "0.6550914", "0.6536964", "0.6505783", "0.64903754", "0.64712256", "0.640575", "0.6404393", "0.637293", "0.63086814", "0.63029146", "0.6277727", "0.6242653", "0.624132", "0.6237749", "0.62245774", "0.61820334", "0.6177538", "0.6172276", "0.6150135", "0.60956544", "0.60935533", "0.6092596", "0.60914207", "0.6087639", "0.60634613", "0.6057289", "0.60276306", "0.6019971", "0.60096264", "0.5994501", "0.5985734", "0.5980023", "0.5979389", "0.5957346", "0.5951136", "0.5948747", "0.5946173", "0.59432685", "0.59428203", "0.5940695", "0.5940449", "0.5914402", "0.5914299", "0.59097517", "0.59015363", "0.58939135", "0.58777755", "0.5872127", "0.58677465", "0.5866409", "0.5863192", "0.58549035", "0.58320355", "0.5827832", "0.5816233", "0.5815504", "0.58112395", "0.5810081", "0.5802241", "0.5800462", "0.5798299", "0.57963854", "0.57930994", "0.5790671", "0.5787378", "0.57825464", "0.5782407", "0.5782225", "0.5780567", "0.5779228", "0.57778484", "0.5768088", "0.57676554", "0.5764064", "0.5762837", "0.5760417", "0.574837", "0.57466084", "0.5741556", "0.573056", "0.5727053", "0.572473", "0.5724609", "0.5722167", "0.5719603", "0.5713626", "0.57053167", "0.5705306", "0.5702341", "0.5701273", "0.56999695", "0.569994", "0.56988424", "0.5694115", "0.5693376", "0.5682958", "0.56807184", "0.56744355", "0.567417", "0.5668706" ]
0.0
-1
Creates a new ShootBall.
public ShootBall() { addRequirements(Robot.shooterBall); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "Ball create(int xpos, int ypos);", "private Ball createBall(Vektor v) {\n \t\tBall ball = new Ball(v, ballsize);\n \t\tball.color = Color.random();\n \t\tballs.add(ball);\n \t\treturn ball;\n \t}", "public Ball()\n {\n Random randomSpeed = new Random ();\n xSpeed = randomSpeed.nextInt(7);\n if (xSpeed == 0)\n { xSpeed = randomSpeed.nextInt(7);\n }\n else\n {}\n ySpeed = randomSpeed.nextInt(7);\n if (ySpeed == 0)\n { ySpeed = randomSpeed.nextInt(7);\n }\n else\n {}\n colors = new ArrayList <String>();\n colors.add(new String (\"red\"));\n colors.add(new String (\"blue\"));\n colors.add(new String (\"green\"));\n colors.add(new String (\"cyan\"));\n colors.add(new String (\"magenta\"));\n colors.add(new String (\"yellow\"));\n colors.add(new String (\"pink\"));\n colors.add(new String (\"orange\"));\n Random randomColor = new Random();\n\n int index = randomColor.nextInt(8);\n color = colors.get(index);\n diameter = 35;\n xPosition = leftBound;\n yPosition = upBound;\n ballTouched = null;\n\n draw(); //draws the ball on the screen\n }", "private void createBall(GL2 gl)\n\t{\n\t\tif(!change)\n\t\t{\n\t\t\tif(shape2)\n\t\t\t{\n\t\t\t\tsetColor(gl, 0, 0, 0, 255 - (13 * hitCount));\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\tsetColor(gl, 0, 0, 0, 255);\n\t\t\t}\n\t\t\t\n\t\t\tdrawGon(gl, 20, currentPoint.getX(), currentPoint.getY(), 10);\n\t\t}\n\t\telse\n\t\t{\n\t\t\tsetColor(gl, 0, 0, 0, 255);\n\t\t\tcurrentPoint.setLocation(640, 360);\n\t\t\tdrawGon(gl, 20, currentPoint.getX(), currentPoint.getY(), 10);\n\t\t\tchange = false;\n\t\t\thitCount = 0;\n\t\t}\n\t}", "void addBallObject() {\n\t\tint ballObjectHeight = ScreenManager.getSizeFromPercentageOfWindowY((float) 10.0);\n\t\tint ballObjectWidth = ballObjectHeight;\n\t\t\n\t\t// Spawning BallObject on the racket\n\t\tint ballObjectX = (int) (racketObject.getX() + (racketObject.width/4.0));\n\t\tint ballObjectY = (int) racketObject.getY() - ballObjectHeight;\n\t\t\n\t\t// BallObject's mass\n\t\tfloat ballObjectMass = (float) 1.075;\n\t\t\n\t\t// Ball velocity X\n\t\tint ballObjectDistanceFromRacketX = -35*(racketObject.getCenterOfWidth() - mouseX);\n\t\tint ballObjectVelocityX = (int) ballObjectDistanceFromRacketX/ScreenManager.getWindowWidth();\n\t\t\n\t\t// Ball velocity Y\n\t\tint ballObjectDistanceFromRacketY = (int) (-35*((racketObject.getY() + racketObject.getHeight()) - mouseY));\n\t\tint ballObjectVelocityY = (int) ballObjectDistanceFromRacketY/ScreenManager.getWindowHeight();\n\t\t\n\t\tballObjects.add(new BallObject(ballObjectX, ballObjectY, ballObjectWidth, ballObjectHeight, ballObjectGravity, ballObjectMass, ballObjectVelocityX, ballObjectVelocityY));\n\t\t\n\t\t// Reduces the amount of time left by 5 seconds\n\t\tMainPanel.gameDuration -= 5;\n\t}", "Ball(int x, int y, int dx, int dy){\n this.x = this.originalX = x;\n this.y = this.originalY = y;\n this.dx = this.originalDX = dx;\n this.dy = this.originalDY = dy;\n s = new ShapeRenderer();\n s.setColor(1,1,1,1);//white\n }", "public Ball(Binge game, int x, int y, int diameter){\n\t\tsuper(game,x,y);\n\t\tthis.xcenter = x + diameter/2;\n\t\tthis.ycenter = y + diameter/2;\n\t\tthis.diameter = diameter;\n\t\tthis.theball = new Ellipse2D.Double(x,y,diameter,diameter);\n\t}", "private GOval drawBall(){\n GOval ball = new GOval(getWidth() / 2.0 - BALL_RADIUS, getHeight() - PADDLE_Y_OFFSET - 2 * BALL_RADIUS,\n 2 * BALL_RADIUS, 2 * BALL_RADIUS);\n ball.setFilled(true);\n ball.setColor(Color.gray);\n add(ball);\n return ball;\n }", "public BouncingBall()\n {\n ballCanvas = new BallPanel( this ); // create new BallPanel\n add( ballCanvas ); // add BallPanel to JFrame\n\n pack(); // make window just large enough for its GUI\n setVisible( true ); // show window\n }", "public BoxBall(int xPos, int yPos, int ballDiameter, Color ballColor,\n int groundPos1, int groundPos2, int groundPos3, int groundPos4, Canvas drawingCanvas)\n {\n xPosition = xPos; // Initial position\n yPosition = yPos; // Initial position\n color = ballColor;\n diameter = ballDiameter;\n groundPositionX1 = groundPos1;\n groundPositionY1 = groundPos2;\n groundPositionX2 = groundPos3;\n groundPositionY2 = groundPos4;\n canvas = drawingCanvas; \n \n Random aleatorio = new Random();\n int y = aleatorio.nextInt(2);\n if(y == 0){\n ySpeed = -ySpeed;\n }\n int x = aleatorio.nextInt(2);\n if(x == 0){\n xSpeed = -xSpeed;\n }\n }", "private void createBallsOnTopOfPaddle() {\r\n for (int i = 0; i < levelInformation.numberOfBalls(); i++) {\r\n Ball ball = new Ball((guiWidth / 2) - ((levelInformation.numberOfBalls() - 1) * ballRadius)\r\n + (i * (ballRadius * 2)), 550, ballRadius, Color.WHITE, environment);\r\n ball.setVelocity(levelInformation.initialBallVelocities().get(i));\r\n ball.addToGame(this);\r\n }\r\n ballCounter.increase(levelInformation.numberOfBalls());\r\n }", "public void ballShoot() {\n\n ballRight.setPower(-1);\n ballLeft.setPower(1);\n\n wait(2.0);\n\n flipper.setPosition(0.7);\n\n wait(0.5);\n\n flipper.setPosition(0.9);\n ballLeft.setPower(0);\n ballRight.setPower(0);\n\n\n }", "public Ball(int x, int y, int diameter)\n {\n currentBallX = x;\n currentBallY = y;\n this.diameter = diameter;\n }", "public Ball(int x, int y, int radius, Color color, int xVelocity, int yVelocity, int xWall, int yWall){\n this.x=x;\n this.y=y;\n this.radius=radius;\n this.color=color;\n this.xVelocity=xVelocity;\n this.yVelocity=yVelocity;\n this.xWall=xWall;\n this.yWall=yWall;\n\n}", "public void createBalls() {\n // add the required amount of balls according to the levelinfo.\n for (int i = 0; i < this.levelInfo.numberOfBalls(); i++) {\n Ball ball = new Ball(new Point(400, 580), 5, java.awt.Color.WHITE);\n // let the ball know the frame limits.\n ball.updateFrame(this.upper, this.lower, this.right, this.left);\n // let the ball know the collidables.\n ball.setGameEnvironment(this.environment);\n // use the velocity from the velocity list of levelinfo.\n Velocity v = this.levelInfo.initialBallVelocities().get(i);\n ball.setVelocity(v);\n // add the ball to the game.\n ball.addToGame(this);\n // increase the ball counter by 1.\n this.ballCounter.increase(1);\n }\n }", "BouncingBall(int maxSpawnX, int maxSpawnY) {\n\n\t\t// Random is used to create a variety of ball variables\n\t\tRandom rand = new Random();\n\t\t\n\t\t// Diameter is between 5 and 20\n\t\tthis.diameter = rand.nextInt(10) + 5;\n\t\t\n\t\t// Ball is spawned based such that it doesn't go out of the screen\n\t\tthis.x = (int) (rand.nextInt((maxSpawnX - diameter) + 1)) + diameter;\n\t\tthis.y = (int) (rand.nextInt((maxSpawnY - diameter) + 1)) + diameter;\n\n\t\t// Ball angle is randomized and velocities are determined using TLAP\n\t\tthis.angle = Math.random() * 2 * Math.PI;\n\t\tthis.velocity = rand.nextDouble() * BounceTester.VELOCITY_MAXIMUM;\n\t\tthis.xChange = (velocity * Math.cos(angle)) + 1;\n\t\tthis.yChange = (velocity * Math.sin(angle)) + 1;\n\n\t\t// Randomly chooses the direction of x and y velocities\n\t\tif (Math.random() > 0.5) {\n\t\t\txChange = xChange * -1;\n\t\t}\n\t\tif (Math.random() > 0.5) {\n\t\t\tyChange = yChange * -1;\n\t\t}\n\n\t\t// Makes sure that none of the velocities are 0\n\t\tif ((int) xChange == 0) {\n\t\t\txChange++;\n\t\t}\n\t\tif ((int) yChange == 0) {\n\t\t\tyChange++;\n\t\t}\n\n\t\t// Randomly sets a color for a ball\n\t\tdouble random = Math.random();\n\t\tdouble red = 0 + Math.floor((255 - 0) * random);\n\t\tdouble green = 0 + Math.floor((182 - 0) * random);\n\t\tdouble blue = 0 + Math.floor((193 - 0) * random);\n\t\tthis.color = new Color((int) red, (int) green, (int) blue);\n\t}", "public Ball() {\r\n\t\tsetWidth(Settings.BALL_WIDTH);\t\t// sets width of ball from variable in settings\r\n\t\tsetHeight(Settings.BALL_HEIGHT);\t// ''width''\r\n\t\tresetPosition();\t\t\t\t\t// Call resetPosition\r\n\t}", "public Ball(AbstractGame world) {\n super(world);\n innerColor = Color.WHITE;\n myCircle = new Circle(15);\n myCircle.setFill(innerColor);\n myCircle.setCenterX(x);\n myCircle.setCenterY(y);\n myShape = myCircle;\n }", "public Boat() {\n batch = new SpriteBatch();\n }", "public void setBallInitial(){\n\tvalidBall = new Ball(Player.getxPlayerLoc(),Player.getyPlayerLoc(), angle,true,ballImage,game.getDifficulty());\n}", "public Ball(Vector2 position) {\n this.position = position;\n build();\n }", "public Ball(Point c)\n\t{\n\t\tcenter = c;\n\t\t// Random velocity\n\t\tvelocity = new Point((int)(Math.random()*20-10), (int)(Math.random()*20-10));\n\t\tradius = 20;\n\t\t//\n\t\trepaint();\n\t}", "public void setBall(Ball b){\r\n\t\tthis.ball = b;\r\n\t}", "public Ball(int x, int y, int radius, Color c, int sp) {\n\t\tsetBounds(x, y, 2 * radius, 2 * radius);\n\t\tdx = sp;\n\t\tdy = -sp;\n\t\tcolor = c;\n\t\t// message = \"\";\n\t}", "public SnowmanShape(int x, int y, int width) {\n\t\tsuper(x, y);\n\t\tthis.width = width;\n\t\tUNIT = width/3;\n\t\tfinal double ARM_OFFSET = 5;\n\t\tdouble diameter = UNIT;\n\t\tdouble topLeft = x + ((width / 2) - (UNIT / 2));\n\t\tdouble topTop = y;\n\t\tEllipse2D.Double topBall = \n\t\t\t\tnew Ellipse2D.Double(topLeft, topTop, diameter, diameter);\n\n\t\ttopTop = topTop + diameter;\n\t\tEllipse2D.Double midBall = \n\t\t\t\tnew Ellipse2D.Double(topLeft, topTop, diameter, diameter);\n\t\tPoint2D.Double armLeftStart = new Point2D.Double(topLeft, topTop + (diameter/2));\n\t\tPoint2D.Double armRightStart = new Point2D.Double(topLeft + diameter, topTop + (diameter/2));\n\t\tPoint2D.Double armLeftEnd = new Point2D.Double(x, topTop + (diameter/2) - ARM_OFFSET);\n\t\tPoint2D.Double armRightEnd = new Point2D.Double(x + width, topTop + (diameter/2) - ARM_OFFSET);\n\t\t\n\t\ttopTop = topTop + diameter;\n\t\tEllipse2D.Double botBall = \n\t\t\t\tnew Ellipse2D.Double(topLeft, topTop, diameter, diameter);\n\t\t\n\t\t\n\t\tLine2D.Double armLeft = new Line2D.Double(armLeftStart, armLeftEnd);\n\t\tLine2D.Double armRight = new Line2D.Double(armRightStart, armRightEnd);\n\t\t\n\t\tadd(topBall);\n\t\tadd(midBall);\n\t\tadd(botBall);\n\t\tadd(armLeft);\n\t\tadd(armRight);\n\t\t\n\t}", "public BallGame() {\n\t\tmyCanvas = new Canvas(\"Ball Demo\", 600, 500, Color.WHITE);\n\t\tmyCanvas.setVisible(true);\n\t\t// Aufgabe 1: MouseListener registrieren\n\t\tmyCanvas.addMouseListener(new DartArrow());\t\t\n\t}", "@Override \n public void collide(Ball ball, Collidable collidable) {\n super.collide(ball, collidable);\n Vect transferLoc = new Vect(this.getLocation().x()+0.5, this.getLocation().y()+0.5);\n Double theta = Math.random()*2*Math.PI;\n board.addBall(new Ball(transferLoc, new Vect(Constants.SPAWNER_SHOOT_VELOCITY*Math.cos(theta),Constants.SPAWNER_SHOOT_VELOCITY*Math.sin(theta) ), this.getName()+\"SpawnedBall\"+this.spawnCount, board.getGravity(), board.getFriction1(), board.getFriction2()));\n spawnCount += 1;\n this.trigger();\n }", "void addBall(Ball b) {\n\t\t\tthis.balls.add(b);\n\n\t\t\tthis.t += b.t;\n\t\t\tthis.w += b.w;\n\n\t\t\tthis.bitRep |= 1 << b.index;\n\t\t}", "static Ball physics ( Ball aBall ) {\n\t// return ... physicsForPosns( ... aBall.pos ... ) ... aBall.xvelocity ... ;\n\t/*\n\treturn new Ball ( ... physicsForPosns( ... aBall.pos ... ) ... aBall.xvelocity ...,\n\t\t\t ... physicsForPosns( ... aBall.pos ... ) ... aBall.xvelocity ... );\n\t*/\n\treturn new Ball ( physicsForPosns( aBall.pos, aBall.xvelocity ),\n\t\t\t aBall.xvelocity );\n\n }", "public void setUpBall(){\n new OrangeBall().setUpOrangeBall();\n }", "public Big_shot(double x,double y,double velocity,double angle){\n\t\tsuper(x,y,velocity,angle,100,30);\n\t}", "Boat(String name)\n {\n this.name = name;\n speed = 0;\n sail = true;\n }", "public Paddle(int screenWidth, int screenHeight){\n myScreenWidth = screenWidth;\n myScreenHeight = screenHeight;\n initialXLocation = myScreenWidth / 2 - myLength / 2;\n initialYLocation = myScreenHeight/2 + initialYLocationAdjustment;\n\n myRectangle = new Rectangle(initialXLocation, initialYLocation, PADDLE_LENGTH, PADDLE_HEIGHT);\n myRectangle.setFill(PADDLE_COLOR);\n }", "public final BallJoint newBallJoint( Body body1, Body body2 )\n {\n BallJoint joint = newBallJointImpl( body1, body2 );\n \n //addJoint( joint );\n \n return ( joint );\n }", "public aBall(double Xi,double Yi, double Vo, double theta, double bSize, Color bColor, double loss, bSim link) {\r\n\t\tthis.Xi = Xi; \t\t\t\t\t//Get simulation parameters\r\n\t\tthis.Yi = Yi;\r\n\t\tthis.Vo = Vo;\r\n\t\tthis.theta = theta;\r\n\t\tthis.bSize = bSize;\r\n\t\tthis.bColor = bColor;\r\n\t\tthis.loss = loss; \r\n\t\tthis.link = link;\r\n\t\tthis.SIMRunning = true;\r\n\t\t\r\n\t\tthis.left=null;\r\n\t\tthis.right= null;\r\n\t\t\r\n\t\t\r\n\t\tmyBall = new GOval(Xi*SCALE,Yi*SCALE,2*bSize*SCALE,2*bSize*SCALE); \r\n\t\tmyBall.setFilled(true);\r\n\t\tmyBall.setFillColor(bColor);\r\n\t\t}", "public Shot() {\n }", "public void add(Ball b) {\r\n balls.add(b);\r\n }", "public Bathroom(int size) {\n this.size = size;\n myBathtub = new Bathtub(100); //instantiate bathtub object during Bathroom object creation\n }", "public Flappy() \r\n\t{\r\n\t\t//sets the properties of the bird\r\n\t\tx = 100;\r\n\t\ty = 150;\r\n\t\tyVel = 0;\r\n\t\twidth = 45;\r\n\t\theight = 32;\r\n\t\tgravity = 0.5;\r\n\t\tjDelay = 0;\r\n\t\trotate = 0.0;\r\n\t\talive = true;\r\n\t}", "Strobo createStrobo();", "protected void moveBall() {\n int width = getWidth();\n int height = getHeight();\n int min, max, randomX, randomY;\n min = 0;\n max = 200;\n randomX = min + (int)(Math.random() * ((max - min)+1));\n randomY = min + (int)(Math.random() * ((max - min)+1));\n //System.out.println(randomX + \", \" + randomY);\n\n Rectangle ballBounds = ball.getBounds();\n// //System.out.println(ballBounds.x + \", \" + ballBounds.y);\n// if (ballBounds.x + randomX < 0) {\n// randomX = 200;\n// } else if (ballBounds.x + ballBounds.width + randomX > width) {\n// randomX = -200;\n// }\n// if (ballBounds.y + randomY < 0) {\n// randomY = 200;\n// } else if (ballBounds.y + ballBounds.height + randomY > height) {\n// randomY = -200;\n// } \n\n ballBounds.x = randomX;\n ballBounds.y = randomY;\n _ballXpos = ballBounds.x;\n _ballYpos = ballBounds.y;\n ball.setFrame(ballBounds);\n thePlacebo.repaint();\n }", "public void shoot(){\n // boss bullete attract to player\n int bulletPosX = PApplet.parseInt(posX + (speed * cos(angle)));\n int bulletPosY = (int)(posY + hei / 2);\n float bulletAngle = atan2(Main.player.posY - bulletPosY, Main.player.posX - bulletPosX);\n int bulletVelX = (int)(8 * cos(bulletAngle));\n int bulletVelY = (int)(8 * sin(bulletAngle));\n bossBullets.add(new Bullet(bulletPosX,bulletPosY,bulletVelX,bulletVelY,1,attack));\n }", "@Override\n\tpublic void startAction() {\n\t if (!balls.isEmpty() && firingBall == null) {\n\t gb.addToActiveList(this);\n\t //fire next ball\n\t firingBall = (Ball)balls.remove(0);\n\t firingBall.setAbsorbed(false);\n\t firingBall.setVy(-50*25);\n\t //align balls that are being held\n\t if (!balls.isEmpty()) setBalls();\n\t }\n\t}", "public Game(int balls) {\r\n currentLevel = new NullLevel();\r\n totalScore = 0;\r\n this.balls = balls;\r\n }", "public Ball(int xl, int yl){\n xLoc = xl;\n yLoc = yl;\n xVel = (Math.random()-.5)*3;\n if(Math.abs(xVel)<2){\n if(xVel>0)\n xVel+=2;\n if(xVel<0)\n xVel-=2;\n }\n yVel = Math.random()*3;\n }", "public void addBall(Ball newBall) {\n\t\tBALL_LIST.add(newBall);\n\t\tSPRITE_LIST.add(newBall);\n\t}", "Snake(){\n T=new Text(String.valueOf(numBalls));\n body=new ArrayList<Circle>();\n setNumBalls(4);\n \n }", "static Football getFootBall(){\n return new Football();\n }", "static RenderBall[] make(Box box)\n\t{\n RenderBall[] rB = new RenderBall[box.nbBalls];\n\t\tfor (int i = 0; i < box.nbBalls; i++)\n\t\t{\n\t\t\trB[i] = new RenderBall();\n\t\t\trB[i].c.r = (int)(Math.random() * 195 + 30);\n\t\t\trB[i].c.v = (int)(Math.random() * 195 + 30);\n\t\t\trB[i].c.b = (int)(Math.random() * 195 + 30);\n\t\t\tif (i == box.nbBalls - 1)\n\t\t\t{\n\t\t\t\trB[i].c.r = 255;\n\t\t\t\trB[i].c.v = 255;\n\t\t\t\trB[i].c.b = 255;\n\t\t\t}\n\t\t}\n return rB;\n\t}", "private void drawBall(Graphics g) {\n Ball b = game.getBall();\n Color savedCol = g.getColor();\n g.setColor(Ball.COLOR);\n g.fillOval(b.getX() - Ball.SIZE / 2, b.getY() - Ball.SIZE / 2, Ball.SIZE, Ball.SIZE);\n g.setColor(savedCol);\n }", "public Ball(Game game) { // constructor that initializes the class Game\r\n this.game = game; // initializes the class Game\r\n }", "@Override\n\tpublic List getBoundaryShape(Ball b) {\n\t List shapes = new ArrayList();\n\t double x2 = x+width*GameBoard.PixelsPerL - 1;\n\t double y2 = y+height*GameBoard.PixelsPerL - 1;\n\t \n\t if (b.equals(firingBall)) {\n\t //leave out section of top and corner cirle so ball being fired\n\t //can exit\n\t shapes.add(new LineSegment(x, y, x2-GameBoard.PixelsPerL, y));\n\t } else {\n\t shapes.add(new Circle(x2, y, 0));\n\t shapes.add(new LineSegment(x, y, x2, y));\n\t }\n\n\t shapes.add(new LineSegment(x, y, x, y2));\n\t shapes.add(new LineSegment(x2, y, x2, y2));\n\t shapes.add(new LineSegment(x, y2, x2, y2));\n\t //0-radius circles at corners\n\t \n\t shapes.add(new Circle(x2, y2, 0));\n\t shapes.add(new Circle(x, y2, 0));\n\t shapes.add(new Circle(x, y, 0));\n\t return shapes;\n\t}", "public Bomb(int x, int y, String xFunction, String yFunction)\r\n\t{\t\r\n\t\tsuper(x, y, new Image[] { bombImage } , 0, 0, 1000, xFunction, yFunction);\r\n\t\tstartX = x;\r\n\t\tstartY = y;\r\n\t\t\r\n\t\t// Play the bomb sound when a bomb is made\r\n\t\tbombSound = new Sound(\"bomb.wav\");\r\n bombSound.playOnce();\r\n\t}", "public void attachBall(ppBall myBall) {\n this.myBall = myBall;\n }", "@Override\n\t\t\tpublic Render<EntityBall> createRenderFor(RenderManager manager) {\n\t\t\t\treturn new RenderBall(manager);\n\t\t\t}", "public void shootAimingBullet(){\n bossBullet = new BossBullet(bossBulletImage,this.getXposition() + 100, this.getYposition() + 100, 8, player, true);\n bulletList.add(bossBullet);\n }", "private static Bat createBat(){\n try {\n UtilityMethods.print(\"Creating Big bat for you...!\"); \n BatGenerator batGenerator = new BatGenerator();\n BatBuilder bigBatBuilder = new BigBatBuilder();\n batGenerator.setBatBuilder(bigBatBuilder);\n batGenerator.constructBat(\n \"Bat\", \n \"Male\",\n 25,\n \"Scavenger\"\n );\n Bat bigBat = bigBatBuilder.getBat();\n UtilityMethods.print(\"\\n\"); \n bigBat.eat();\n UtilityMethods.print(\"\\n\"); \n bigBat.speak();\n UtilityMethods.print(\"\\n\"); \n bigBat.walk();\n UtilityMethods.print(\"\\n\"); \n } catch (Exception e) {\n UtilityMethods.print(e.getMessage()); \n }\n return null; \n }", "void hitBall() {\n \n System.out.println(this.golfBall.vel_vector.x + \",\"\n + this.golfBall.vel_vector.y + \",\"\n + this.golfBall.acc_vector.x + \",\"\n + this.golfBall.acc_vector.y);\n \n if (this.golfBall.stopped) {\n new Sound(\"resources/hit.wav\").play();\n this.golfBall.stopped = false;\n this.golfBall.acc(this.strokeAcc.x, this.strokeAcc.y);\n this.strokes += 1;\n }\n \n }", "public void addBall (int slot, int pidx, int roundId, long seed)\n {\n new DropContext(_flipObj, _observer, pidx, roundId, slot, seed);\n }", "public Bomb newBomb() {\r\n return new Bomb(id(), position().containingCell(),\r\n Ticks.BOMB_FUSE_TICKS, bombRange);\r\n }", "public Shooter() {\n fire1 = new Solenoid(1);\n fire2 = new Solenoid(4);\n returnValve = new Solenoid(3);\n latchSolenoid = new Solenoid(2);\n FFM = true;\n m_enabled = true;\n shooting = false;\n reloading = false;\n initShooter();\n }", "public Robots(PApplet p) {\n\t\tbSpeed = 6;\n\t\tbSize = 1;\n\t\tparent = p;\n\t\tx = parent.random (bobWidth, parent.width/2 - bobWidth); // Bob starts in a random place on the screen\n\t\ty = parent.random (bobWidth,parent.width/2 - bobWidth); \n\t}", "public void setBallTouched(Ball ball)\n {\n ballTouched = ball;\n }", "public Bomb(int x, int y, Mouse mouse)\r\n\t{\r\n\t\tthis.x = x;\r\n\t\tthis.y = y;\r\n\t\tthis.mouse = mouse;\r\n\t\tdetonated = false;\r\n\t}", "public void bounce(Ball ball) {\n\t\tPoint location = ball.getLocation();\n\t\tPoint velocity = ball.getVelocity();\n\t\tint radius = ball.getRadius();\n\n\t\tif (location.x < 0) {\n\t\t\tlocation.x = -location.x;\n\t\t\tvelocity.x = -velocity.x;\n\t\t}\n\n\t\tif (location.x + 1 * radius > BallWorldModel.returnBounds().width) {\n\t\t\tlocation.x = BallWorldModel.returnBounds().width * 2 - location.x - 2 * radius;\n\t\t\tvelocity.x = -velocity.x;\n\n\t\t}\n\t\tif (location.y < 0) {\n\t\t\tlocation.y = -location.y;\n\t\t\tvelocity.y = -velocity.y;\n\t\t}\n\t\tif (location.y + 1 * radius > BallWorldModel.returnBounds().height) {\n\t\t\tlocation.y = BallWorldModel.returnBounds().height * 2 - location.y - 2 * radius;\n\t\t\tvelocity.y = -velocity.y;\n\n\t\t}\n\t}", "public GameObject spawnBomber(LogicEngine in_logicEngine){\n\t\tGameObject ship = new GameObject(\"data/\"+GameRenderer.dpiFolder+\"/bomber.png\",((float)LogicEngine.SCREEN_WIDTH)+50,LogicEngine.SCREEN_HEIGHT-50,0);\r\n\t\tship.i_animationFrameSizeHeight = 58;\r\n\t\tship.i_animationFrameSizeWidth = 58;\r\n\t\t\r\n\t\t//fly back and forth\r\n\t\tLoopWaypointsStep s = new LoopWaypointsStep();\r\n\t\ts.waypoints.add(new Point2d(-30,LogicEngine.SCREEN_HEIGHT-50));\r\n\t\ts.waypoints.add(new Point2d(LogicEngine.SCREEN_WIDTH+50,LogicEngine.SCREEN_HEIGHT-50));\r\n\t\t\r\n\t\tship.b_mirrorImageHorizontal = true;\r\n\t\t\r\n\t\tship.stepHandlers.add(s);\r\n\t\tship.v.setMaxForce(5.0f);\r\n\t\tship.v.setMaxVel(5.0f);\r\n\t\tship.allegiance = GameObject.ALLEGIANCES.ENEMIES;\r\n\r\n\r\n\t\t//tadpole bullets\r\n\t\tGameObject go_tadpole = this.spawnTadpole(in_logicEngine);\r\n\t\tgo_tadpole.stepHandlers.clear();\r\n\t\tFlyStraightStep fly = new FlyStraightStep(new Vector2d(0,-0.5f));\r\n\t\tfly.setIsAccelleration(true);\r\n\t\t\r\n\t\t\r\n\t\tif(Difficulty.isHard())\r\n\t\t{\tgo_tadpole.v.setMaxVel(5);\r\n\t\t\tgo_tadpole.v.setMaxForce(5);\r\n\t\t}\r\n\t\telse\r\n\t\t{\tgo_tadpole.v.setMaxVel(10);\r\n\t\t\tgo_tadpole.v.setMaxForce(5);\r\n\t\t}\r\n\t\tgo_tadpole.stepHandlers.add(fly);\r\n\t\tgo_tadpole.v.setVel(new Vector2d(-2.5f,0f));\r\n\t\t\r\n\t\t\r\n\t\t//bounce on hard and medium\r\n\t\tif(Difficulty.isHard() || Difficulty.isMedium())\r\n\t\t{\r\n\t\t\tBounceOfScreenEdgesStep bounce = new BounceOfScreenEdgesStep();\r\n\t\t\tbounce.b_sidesOnly = true;\r\n\t\t\tgo_tadpole.stepHandlers.add(bounce);\r\n\t\t}\r\n\t\t\r\n\t\t//drop bombs\r\n\t\tLaunchShipsStep launch = new LaunchShipsStep(go_tadpole, 20, 5, 3, true);\r\n\t\tlaunch.b_addToBullets = true;\r\n\t\tlaunch.b_forceVelocityChangeBasedOnParentMirror = true;\r\n\t\t\r\n\t\tship.stepHandlers.add(launch);\r\n\t\tship.rotateToV=true;\r\n\t\t\r\n\t\t//give it some hp\r\n\t\tHitpointShipCollision c = new HitpointShipCollision(ship, 50, 50f);\r\n\t\tc.setSimpleExplosion();\r\n\t\tship.collisionHandler = c;\r\n\t\t\r\n\t\tin_logicEngine.objectsEnemies.add(ship);\r\n\t\t\r\n\t\treturn ship;\r\n\t\r\n\t}", "public Bomb(int x, int y){\r\n\t\t\r\n\t\t//Bomb image.\r\n\t\tImageIcon bombIMG = new ImageIcon(\"src/sprites/bullet9.png\");\r\n\t\tsetImage(bombIMG.getImage());\r\n\t\t\r\n\t\t//It just so works out that the bombs drop nicely from the alien sprite so no offset is needed.\r\n\t\tsetx(x);\r\n\t\tsety(y);\r\n\t\t\r\n\t}", "public Ball(double x, double y, int r, java.awt.Color color) {\n this.center = new Point(x, y);\n this.r = r;\n this.color = color;\n this.gameEnvironment = new GameEnvironment();\n }", "public static void addBalls() {\n\t\tfor (int i = 0; i < numberOfBalls; i++) {\n\t\t\tPanel.balls.add(new Ball());\n\t\t}\n\t}", "void addEventPaddle(DefaultPlayer player, DefaultBall ball);", "public NewShape() {\r\n\t\tsuper();\r\n\t}", "public LightShot(AbstractGame world) {\n super(world);\n innerColor = Color.WHITE;\n myCircle = new Circle(3);\n myCircle.setCenterX(0);\n myCircle.setCenterY(0);\n myCircle.setFill(innerColor);\n myShape = myCircle;\n speed = 10;\n GaussianBlur blur = new GaussianBlur();\n blur.setRadius(5);\n myShape.setEffect(blur);\n FadeTransition fadeOut = new FadeTransition(Duration.seconds(2), myShape);\n fadeOut.setFromValue(1);\n fadeOut.setToValue(0);\n fadeOut.playFromStart();\n // new AudioClipPlayer(AudioClipPlayer.HEARTBEAT).start();\n }", "public Skull(double x, double y) {\n\t\tsuper(x, y);\n\t\t\n\t\tangle = 0;\n\t\t\n\t\tnumberGen = 694.2953; //681.7969; was ok\n\t\t\n\t\tjesusFuckingChrist = false;\n\t\t\n\t\tkeptSeedX = new double[2];\n\t\twipeSeedRecord();\n\t\t\n\t\ttargetX = 320;\n\t\t\n\t\timLeaving = false;\n\t\t\n\t\thavePetals = petals;\n\t\t\n\t\tme = this;\n\t\tmySeed = null;\n\t\t\n\t\tseedClaimedWhistle = null;\n\t\t\n\t\tflowerX = 0;\n\t\tflowerY = 0;\n\t\t\n\t\tjetpackTimer = -1;\n\t\t\n\t\tsqueezeTimer = -1;\n\t\t\n\t\thurt = -1;\n\t\t\n\t\tsetDepth(-10);\n\t\tsetCollisionGroup(Global.BASICENEMY, Global.DEACTIVATEME);\n\t\t\n\t\thealth = maxHealth;\n\t\t//health = 1;\n\t\tanimateSpeed = .3;\n\t\t\n\t\tspd = new double[stemParts];\n\t\ttoSpd = new double[stemParts];\n\t\tang = new double[stemParts];\n\t\t\n\t\tdist = new double[petals];\n\t\t\n\t\tfor (int i=0; i<stemParts; i++){\n\t\t\tif (i == 0)\n\t\t\t\tang[i] = 90 + Calc.rangedRandom(20);\n\t\t\telse\n\t\t\t\tang[i] = Calc.rangedRandom(12 - (11.0 * ((double)i/(double)stemParts)));\n\t\t\tspd[i] = 2 + (4 * ((double)i / (double)stemParts));\n\t\t\tspd[i] *= (Double)Calc.choose(1.0,-1.0);\n\t\t\ttoSpd[i] = spd[i];\n\t\t}\n\t\t\n\t\tfor (int i=0; i<petals; i++){\n\t\t\tdist[i] = 0;\n\t\t}\n\t\t\n\t\tquiverPetals(30);\n\t}", "public Square createWall() {Collect.Hit(\"BoardFactory.java\",\"createWall()\"); Collect.Hit(\"BoardFactory.java\",\"createWall()\", \"1976\");return new Wall(sprites.getWallSprite()) ; }", "public Paddle(int width, int height) {\r\n \r\n this.width = width;\r\n this.height = height;\r\n \r\n }", "public Shape() {\n\t\tthis(DEFAULT_X_POS, DEFAULT_Y_POS, DEFAULT_DELTA_X, DEFAULT_DELTA_Y, DEFAULT_WIDTH, DEFAULT_HEIGHT);\n\t}", "protected abstract BallJoint newBallJointImpl( Body body1, Body body2 );", "public void startGame() {\n\t\t\n\t\tmyCanvas.setVisible(true);\n\n\t\t// draw the ground\n\t\tmyCanvas.drawLine(50, GROUNDLINE, 550, GROUNDLINE);\n\n\t\t// B�lle erzeugen\n\t\tvar r = new Random();\n\t\t// Aufgabe 6: ein Ball ist nicht genug, oder?\n\t\t// Erweitern Sie die Erzeugung mit Random Zahlen und generieren Sie B�lle in einer Schleife\n\t\tfor(var i = 0; i < 5; ++i) {\n\t\t\tballs.add( new BouncingBall(20 + r.nextInt(80), 100, 20 + r.nextInt(60), new Color(r.nextInt(200)+56,r.nextInt(256),r.nextInt(256)), GROUNDLINE, myCanvas) );\n\t\t}\n\t\t\n\t\t\t\t\t\t\n\t\t// draw every ball in the list\n\t\tfor (BouncingBall ball : balls) {\n\t\t\tball.draw();\n\t\t}\t\t\n\t\t\n\t\t// make them bounce\n\t\tvar finished = false;\n\t\twhile (!finished) {\n\t\t\tmyCanvas.wait(50); // small delay\n\t\t\t\n\t\t\t// move every ball in the list\n\t\t\tfor (BouncingBall ball : balls) {\n\t\t\t\tball.move();\n\t\t\t}\t\t\n\t\t\t\n\t\t\t// stop if a ball has travelled a certain distance on x axis\n\t\t\tfor (BouncingBall ball : balls) {\t\t\t\t\n\t\t\t\tif (ball.getXPosition() >= 550) {\n\t\t\t\t\tfinished = true;\n\t\t\t\t\t// Aufgabe 5: Gameover\n\t\t\t\t\t// ...\n\t\t\t\t\tvar image = new ImageIcon(\"src/app/images/gameover.jpg\").getImage();\n\t\t\t\t\tmyCanvas.drawImage(image, 340, 240);\n\t\t\t\t}\n\t\t\t}\t\t\n\t\t\t\n\t\t\t// Aufgabe 3: Alle B�lle getroffen?\n\t\t\tif (balls.size()==0) {\n\t\t\t\tfinished = true;\n\t\t\t\tvar image = new ImageIcon(\"src/app/images/gewonnen.jpg\").getImage();\n\t\t\t\tmyCanvas.drawImage(image, 340, 240);\n\t\t\t\t// Bild ausgeben, Gewonnen\n\t\t\t}\n\t\t\t\n\t\t}\n\t\t\n\t\t// erase every ball from the canvas\n\t\tfor (var ball : balls) {\n\t\t\tball.erase();\n\t\t}\t\t\n\t}", "public Flame_Tank(int defx, int defy) {\n\t\tsuper(defx,defy);\n\t\twidth = 58;\n\t\theight = 31;\n\t\thitBox = new Rectangle(defx, defy, width, height); // fix this\n\t\txMaxSpeed = 0.3f;\n\t\tfriction = 0.01f;\n\t\tjumpStrength = 0.5f;\n\t\telasticity = 0.2f;\n\t\thp = 1000;\n\t\t\n\t\ttry {\n\t\t\tblank = new Image (\"res/blank.png\");\n\t\t\tft1 = new Image (\"res/Flare_Tank1.png\");\n\t\t\tft2 = new Image (\"res/Flare_Tank2.png\");\n\t\t\tftb1 = new Image (\"res/Flare_Tank_b1.png\");\n\t\t\tftb2 = new Image (\"res/Flare_Tank_b2.png\");\n\t\t\tftb3 = new Image (\"res/Flare_Tank_b3.png\");\n\t\t\tftb4 = new Image (\"res/Flare_Tank_b4.png\");\n\t\t} catch (SlickException e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t}\n\t\tftank[0] = ft1;\n\t\tftank[1] = ft2;\n\t\tftank[2] = ft2;\n\t\tftank[3] = ftb1;\n\t\tftank[4] = ftb2;\n\t\tftank[5] = ftb3;\n\t\tftank[6] = ftb4;\n\t\tftank[7] = blank;\n\t\tFlame_tank = new Animation(ftank,200,true);\n\t\t\n\t\tweapons.add(new Weapon(Weapon.getWeapons().get(7)));\n\t\tfor(Weapon w : weapons) {\n\t\t\tw.setEnemy(true);\n\t\t}\n\t\tcurrentWeapon = weapons.get(1);\n\t}", "Bullet(int posX,int posY,int velX,int velY,int classOfObejct,int attack){\n this.posX = posX;\n this.posY = posY;\n this.velX = velX;\n this.velY = velY;\n this.classOfObejct = classOfObejct;\n this.attack = attack;\n\n }", "public DumbEnemy(){\n setImage(new GreenfootImage(SPRITE_W,SPRITE_H));\n }", "public void shoot(){\n int bulletPosX = posX;\n int bulletPosY = posY;\n int bulletVelX = 0;\n int bulletVelY = -9;\n //add the new bullets to the array of bullets\n bullets.add(new Bullet(bulletPosX,bulletPosY,bulletVelX,bulletVelY,0,attack));\n }", "public void moveBall() {\n\t\tif (BrickPanel.getBrickCount() == -1) {\n\t\t\t\n \t\tcontrolPanel.resetGame();\n \t\tcontrolPanel.gameWonText();\n \t}\n\t\tif (BrickPanel.getBallShape().getY() >= 300) {\n\t\t\t \n\t\t\tcontrolPanel.resetGame();\n\t\t\t controlPanel.gameOverText();\n\t\t\t \n\t\t\t}\n\t\t//calls the moveBall method to move the ball\n\t\tBrickPanel.moveBall();\n\t}", "public void ballManagement(){\n\t\t\n//\t\tUpdates the Ball's X Position\n\t\tif (validBall.getxLoc() <0)\n\t\t\tvalidBall.setActiveBall(false);\n\t\telse\n\t\t\tvalidBall.updateBallXPos();\n\n//\t\tUpdates the Ball's Y Position\n\t\tif (validBall.getyLoc() > screenHeight)\n\t\t\tvalidBall.setActiveBall(false);\n\t\telse\n\t\t\tvalidBall.updateBallYPos();\n\t\t\n//\t\tUpdates the Ball Count of the Level\n\t\tupdateBallCount();\n\t\t\n//\t\tDraw the Ball on the Screen\n\t\tbatch.draw(validBall.getBallImage(), validBall.getxLoc(),validBall.getyLoc(), validBall.getBallImage().getWidth() * validBall.getBallScale(),validBall.getBallImage().getHeight() * validBall.getBallScale() );\n\t\t\n\t}", "protected void drawBallCount(int ballCount){\n ballBox = new Rectangle(55, 725, 50, 20);\n ballBox.setFillColor(pink);\n ballBox.setFilled(true);\n canvas.add(ballBox);\n int radius = 10;\n for (int i = 0; i < ballCount; i++){\n Ellipse circle = new Ellipse(60 + i*(radius + 5), 730, radius, radius);\n circle.setFillColor(Color.black);\n circle.setFilled(true);\n canvas.add(circle);\n }\n\n }", "public void createBullet(String name, double x, double y) {\n Player player = (Player) players.get(name);\r\n if (player != null) {\r\n Bullet bullet = new Bullet(x, y);\r\n bullet.player = name;\r\n playAudio(\"shoot\");\r\n }\r\n }", "abstract public void performCollision(Ball ball);", "public Ball(int x, int y, int radius, Color color, GameLevel gameLevel) {\n this.center = new Point(x, y);\n if (radius > 0) {\n this.radius = radius;\n } else {\n this.radius = DEFAULT_RADIUS;\n }\n this.color = color;\n this.velocity = new Velocity(0, 0);\n\n this.gameLevel = gameLevel;\n }", "public void moveBall()\n\t{\n\t\tx -= vx;\n\t\ty += vy;\n\t}", "public Ball(int xWall, int yWall, Random rand){\n this(\n rand.nextInt(xWall-2*MAX_RADIUS),//set all to random\n rand.nextInt(yWall-2*MAX_RADIUS),\n rand.nextInt(MAX_RADIUS-MIN_RADIUS)+MIN_RADIUS,\n new Color(\n rand.nextInt(MAX_CHANNEL_VAL),\n rand.nextInt(MAX_CHANNEL_VAL),\n rand.nextInt(MAX_CHANNEL_VAL),\n rand.nextInt(MAX_CHANNEL_VAL-MIN_ALPHA_VAL)+MIN_ALPHA_VAL),\n rand.nextInt(MAX_VELOCITY-MIN_VELOCITY)+MIN_VELOCITY,\n rand.nextInt(MAX_VELOCITY-MIN_VELOCITY)+MIN_VELOCITY,\n xWall,\n yWall\n );\n }", "@Override\n\tpublic void create() {\n\t\t// This should come from the platform\n\t\theight = platform.getScreenDimension().getHeight();\n\t\twidth = platform.getScreenDimension().getWidth();\n\n\t\t// create the drawing boards\n\t\tsb = new SpriteBatch();\n\t\tsr = new ShapeRenderer();\n\n\t\t// Push in first state\n\t\tgsm.push(new CountDownState(gsm));\n//\t\tgsm.push(new PlayState(gsm));\n\t}", "public Ball(double x, double y, double diameter, String col, int layer)\n\t{\n\t\tthis.xPosition = x;\n\t\tthis.yPosition = y;\n\t\tthis.size = diameter;\n\t\tthis.colour = col;\n\t\tthis.layer = layer;\n\t}", "public Absorber(String name, int x, int y, int width, int height) {\n this.name = name;\n this.boundingBoxPosition = new Vect(x,y);\n this.width = width;\n this.height = height;\n this.storedBalls = new LinkedList<Ball>(); //initially has no stored ball\n this.storePosition = new Vect(boundingBoxPosition.x()+this.width-.25,boundingBoxPosition.y()+this.height-.25);\n\n //construct bounding lines\n LineSegment top = new LineSegment(x,y,x+width,y);\n LineSegment left = new LineSegment(x,y,x,y+height);\n LineSegment right = new LineSegment(x+width,y,x+width,y+height);\n LineSegment bottom = new LineSegment(x,y+height,x+width,y+height);\n this.boundaries = new ArrayList<LineSegment>(Arrays.asList(left,right,top,bottom));\n \n instanceUID = NetworkProtocol.getUID();\n }", "public void createBike() {\n createFrame();\n addWheels();\n addPedals();\n getPrice();\n }", "public void paddleVSball(Paddle p, Ball b) {\n Rectangle p_box = new Rectangle(p.getX(), p.getY(), p.getWidth(), p.getHeight());\r\n // System.out.println(\"X: \"+p.getX()+\"Y: \"+p.getY()+\"W: \"+p.getWidth()+\"H: \"+p.getHeight());\r\n Rectangle b_box = new Rectangle(b.getX(), b.getY(), b.getWidth(), b.getHeight());\r\n\r\n if (p_box.intersects(b_box)) {\r\n //collision\r\n //if ball is going +y and -x\r\n if (b.getVY() > 0 || b.getVY() < 0) {\r\n b.setVY(b.getVY() * -1);\r\n }\r\n if (b.getY() < p.getY()) {//if the ball is inside the paddle\r\n b.setVX(b.getVX() * -1);\r\n b.setVX(b.getVX() * -1);\r\n }\r\n }\r\n }", "public void createDeathBlock(HitListener ballrmv) {\n Block death = new Block(new Rectangle(new Point(0, 600), 800, 10), Color.DARK_GRAY);\n death.addHitListener(ballrmv);\n death.addToGame(this);\n death.setHitPoints(100);\n }", "public static void moveBalls() {\n\t\tfor (Ball b : Panel.balls) {\n\t\t\tif (b.getxPOS() + b.getxVelocity() < 410 || b.getxPOS() + b.getxVelocity() > (1200 - (b.getMass() * 7))) { //checking next frame for boundry collision\n\t\t\t\tb.setxVelocity(-b.getxVelocity());\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t//reverseing velocity if true\n\t\t\t}\n\t\t\tif (b.getyPOS() + b.getyVelocity() < 0) {\n\t\t\t\tb.setyVelocity(-(b.getyVelocity()));\n\t\t\t}\n\t\t\tif (b.getyPOS() + b.getyVelocity() > (800 - (b.getMass() * 7)) - 22) { //on each collision with the floor, decrease the balls X and Y velocity\n\t\t\t\tb.setyVelocity(-(b.getyVelocity() - energyLost));\n\t\t\t\tif (Panel.tick % 7 == 0 && Panel.Gravity) {\n\t\t\t\t\tif (b.getxVelocity() < 0) {\n\t\t\t\t\t\tb.setxVelocity(b.getxVelocity() + 1);\n\t\t\t\t\t}\n\t\t\t\t\tif (b.getxVelocity() > 0) {\n\t\t\t\t\t\tb.setxVelocity(b.getxVelocity() - 1);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (!(b.getyPOS() + b.getyVelocity() > (800 - (b.getMass() * 7)) - 22)) { //applying motion in the Y direction only if the ball is not resting on the floor\n\t\t\t\tb.setyPOS(b.getyPOS() + b.getyVelocity());\n\t\t\t}\n\t\t\telse {\n\t\t\t\tb.setyPOS((800 - (b.getMass() * 7)) - 22);\n\t\t\t}\n\t\t\t\n\t\t\tb.setxPOS(b.getxPOS() + b.getxVelocity()); //motion is always applied in the X direction\n\t\t}\n\t}", "@Override\n\tpublic void render(float delta) {\n\t\tif(paused) {\n\t\t\tif (Gdx.input.isKeyPressed(Keys.P)) {\n\t\t\t\tpaused = false;\n\t\t\t\t\n\t\t\t\ttry {\n\t\t\t\t\tThread.sleep(150);\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}\n\t\telse {\n\t\t\n\t\t//Clear the screen\n\t\tGdx.gl.glClear(GL20.GL_COLOR_BUFFER_BIT);\n\t\t\n\n\t\t//Controlled ball\n\t\tcontrol.color = Color.CYAN;\n\t\tcontrol.update();\n\t\tshape.begin(ShapeRenderer.ShapeType.Filled);\n\t\tcontrol.draw(shape);\n\t\tshape.end(); \t\t\n\t\t\n\t\t\n\t\t\n\t\t//Create bouncing balls\n\t\tfor (Ball ball : balls) {\n\t\t\t\n\t\t\tball.update();\n\t\t\tshape.begin(ShapeRenderer.ShapeType.Filled);\n\t\t\tball.draw(shape);\n\t\t\tshape.end();\n\t\t\t\n\t\t\t//When ball and controller collide make collision sound effect and flash to Red\n\t\t\tif (control.overlaps(ball) == true) {\n\t\t\t\tif (Options.isFxOn == true)\n\t\t\t\t\tcollideSound.render();\n\t\t\t\tcontrol.color = Color.RED;\n\t\t\t\tshape.begin(ShapeRenderer.ShapeType.Filled);\n\t\t\t\tcontrol.draw(shape);\n\t\t\t\tshape.end();\n\t\t\t\thasCollided = 1;\t\t\t\t\t\t\t\t\n\t\t\t}\n\t\t\t\n\t\t\tif (control.overlaps(ball) == false && hasCollided == 1) {\n\t\t\t\thealthcounter++;\n\t\t\t\thasCollided = 0;\n\t\t\t}\n\t\t\t\n\t\t}\n\t\t\t\t\n\t\t//Drawing the timer\n\t\tbatch.begin();\n\t\ttime.drawTime(batch);\n\t\tbatch.end();\n\t\t\n\t\t//Adding Balls Every 30 seconds\n\t\tif (time.thirtySecPassed() == true && hasThirty == 0) {\n\t\t\t\n\t\t\tballs.add(new Ball(gen.nextInt(100) + size, gen.nextInt(100) + size, \n\t\t\t\t\tgen.nextInt(25) + 5, gen.nextInt(15) + 1, gen.nextInt(15) + 1));\n\t\t\t\n\t\t\thasThirty = 1;\n\t\t}\n\t\t\n\t\tif ((int)time.dt % 30 != 0)\n\t\t\thasThirty = 0;\n\t\t\n\t\t//Setting T or F Var for Ball Spawn\n\t\tif (time.tenSecPrior())\n\t\t\ttenPrior = 1;\n\t\t\n\t\tif (time.thirtySecPassed())\n\t\t\ttenPrior = 0;\n\t\t\n\t\t//Setting T or F Var for speed and size change\n\t\tif (time.fiveSecPrior())\n\t\t\tfivePrior = 1;\n\t\t\n\t\tif (time.fifteenSecPassed())\n\t\t\tfivePrior = 0;\n\t\t\n\t\tif (tenPrior == 1) {\n\t\t\t\n\t\t\tbatch.begin();\n\t\t\talert.showAlertTwenty(batch);\t\t\t\t\n\t\t\tbatch.end();\n\t\t\t\n\t\t}\n\t\t\n\t\tif (fivePrior == 1) {\n\t\t\t\n\t\t\tbatch.begin();\n\t\t\talert.showAlertTen(batch);\t\t\t\t\n\t\t\tbatch.end();\t\t\t\n\t\t}\n\t\t\n\t\t\n\t\t//Draw the healthbar\n\t\tbatch.begin();\n\t\tHealthbar.health.get(healthcounter).setSize(180f, 30f);\n\t\tHealthbar.health.get(healthcounter).setPosition(2, 450);\n\t\tHealthbar.health.get(healthcounter).draw(batch);;\n\t\tbatch.end();\n\t\t\n\t\tif (healthcounter >= 4) {\n\t\t\t\n\t\t\tscore = time.dt;\n\t\t\tactualScore = df.format(score);\n\t\t\tSystem.out.println(actualScore);\n\t\t\tdispose();\n\t\t\tgoToEndScreen();\t\t\t\n\t\t}\n\n\t\t}\n\t\t\n\t}", "public DrawGraphics() {\r\n box = new BouncingBox(200, 50, Color.RED);\r\n\tbox.setMovementVector(1,1);\r\n\r\n\tboxes = new ArrayList<BouncingBox>();\r\n\tboxes.add(new BouncingBox(35,40, Color.BLUE));\r\n\tboxes.get(0).setMovementVector(2,-1);\r\n\tboxes.add(new BouncingBox(120,80, Color.GREEN));\r\n\tboxes.get(1).setMovementVector(-1,2);\r\n\tboxes.add(new BouncingBox(500,80, Color.PINK));\r\n\tboxes.get(2).setMovementVector(-2,-2);\r\n }", "public Turtle(String name, int x, int y) {\n\tthis.name= name;\n\tLocX1 = 0;\n\tLocY1 = 0;\n\tLocX2 = 0;\n\tLocY2 = 0;\n\tangle = 0; // rotation angle \n\twriting = true; // default pen down\n\tcolor = Color.BLACK; // default color\n\theading = 90; // default facing north, 90 degrees\n\tdelta = 0;\n\tdraw = true;\n\ttry {\n bimg = ImageIO.read(new File(\"./Images/TurtleBlue.png\"));\n } catch (Exception e) {\n e.printStackTrace();\n }\n}" ]
[ "0.7573614", "0.672805", "0.6612634", "0.65753275", "0.6564399", "0.6527666", "0.6435138", "0.63497275", "0.63182765", "0.6283789", "0.62576544", "0.62386984", "0.6219011", "0.6159565", "0.6101164", "0.61001915", "0.6076165", "0.6039667", "0.59851664", "0.59850395", "0.5961851", "0.5921357", "0.5869642", "0.58648896", "0.5844289", "0.5820243", "0.5789271", "0.57329273", "0.5651", "0.56444025", "0.5603351", "0.5588704", "0.55632824", "0.5544235", "0.552465", "0.55054617", "0.55053926", "0.55049217", "0.5491302", "0.54823816", "0.54699063", "0.54612136", "0.5452438", "0.54445285", "0.5439898", "0.54253113", "0.54237235", "0.54234445", "0.5415381", "0.53760225", "0.53706896", "0.5349176", "0.53360814", "0.5331812", "0.5322255", "0.5315932", "0.53152424", "0.53106636", "0.53078777", "0.5294552", "0.52735513", "0.5268072", "0.52654535", "0.5261855", "0.5258555", "0.52175415", "0.5216518", "0.5212762", "0.5212706", "0.52021956", "0.52009386", "0.51938146", "0.51934224", "0.51926947", "0.51744294", "0.5173153", "0.5169555", "0.51601094", "0.5157881", "0.51504326", "0.5144136", "0.5143072", "0.51320857", "0.5124514", "0.5123612", "0.5121967", "0.51192355", "0.51130056", "0.5103763", "0.50894403", "0.50845915", "0.5083447", "0.5083036", "0.5082234", "0.5082148", "0.507961", "0.5077966", "0.5076799", "0.5075922", "0.5071234" ]
0.77855015
0
Called when the command is initially scheduled.
@Override public void initialize() {}
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private void beginSchedule(){\n\t\tDivaApp.getInstance().submitScheduledTask(new RandomUpdater(this), RandomUpdater.DELAY, RandomUpdater.PERIOD);\n\t}", "@Override\n protected void initialize() {\n System.out.println(\"CargoWheelSuckOrSpitCommand init\");\n _timer.reset();\n _timer.start();\n }", "@Override\n public void autonomousInit() {\n //ds.set(Value.kForward);\n /*m_autonomousCommand = m_chooser.getSelected();\n\n /*\n * String autoSelected = SmartDashboard.getString(\"Auto Selector\",\n * \"Default\"); switch(autoSelected) { case \"My Auto\": autonomousCommand\n * = new MyAutoCommand(); break; case \"Default Auto\": default:\n * autonomousCommand = new ExampleCommand(); break; }\n * \n */\n\n // schedule the autonomous command (example)\n /*if (m_autonomousCommand != null) {\n m_autonomousCommand.start();\n }*/\n //new VisionProcess().start();\n //SmartDashboard.putNumber(\"heerer\", value)\n new TeleOpCommands().start();\n }", "public void autonomousInit() {\n\t\tautonomousCommand.start();\r\n\t}", "@Override\n public void autonomousInit() {\n\tgameData.readGameData();\n\tautonomousCommand = (Command) chooserMode.getSelected();\n\tdriveSubsystem.resetEncoders();\n\televatorSubsystem.resetEncoder();\n\t// schedule the autonomous command\n\tif (autonomousCommand != null) {\n\t // SmartDashboard.putString(\"i\", \"nit\");\n\t autonomousCommand.start();\n\t}\n }", "@Override\n\tpublic void teleopInit() {\n\n\t\tSystem.out.println(\"Teleop init\");\n\t\tif (autonomousCommand != null)\n\t\t\tautonomousCommand.cancel();\n\t\tScheduler.getInstance().add(new DriveCommand());\n\n\t\t\n\t}", "@Override\r\n\tpublic void doInitialSchedules() {\n\t}", "public void autonomousInit() {\n if (autonomousCommand != null) autonomousCommand.start();\n }", "@Override\n public void autonomousInit() {\n //Diagnostics.writeString(\"State\", \"AUTO\");\n //m_autonomousCommand = m_chooser.getSelected();\n\n /*\n * String autoSelected = SmartDashboard.getString(\"Auto Selector\", \"Default\");\n * switch(autoSelected) { case \"My Auto\": autonomousCommand = new\n * MyAutoCommand(); break; case \"Default Auto\": default: autonomousCommand = new\n * ExampleCommand(); break; }\n */\n\n // schedule the autonomous command (example)\n /*if (m_autonomousCommand != null) {\n m_autonomousCommand.start();\n }*/\n\n teleopInit();\n }", "@Override\n\tpublic void autonomousInit() {\n\t\tautonomousCommand = new Auto();\n\n\t\t/*\n\t\t * String autoSelected = SmartDashboard.getString(\"Auto Selector\",\n\t\t * \"Default\"); switch(autoSelected) { case \"My Auto\": autonomousCommand\n\t\t * = new MyAutoCommand(); break; case \"Default Auto\": default:\n\t\t * autonomousCommand = new ExampleCommand(); break; }\n\t\t */\n\n\t\t// schedule the autonomous command (example)\n\t\tif (autonomousCommand != null)\n\t\t\tautonomousCommand.start();\n\t}", "protected void initialize() {\n\t\tRobot.firstAutonomousCommandDone = true;\n\t}", "@Override\n public void autonomousInit() {\n\n Robot.m_driveTrain.driveTrainLeftFrontMotor.setSelectedSensorPosition(0);\n Robot.m_driveTrain.driveTrainRightFrontMotor.setSelectedSensorPosition(0);\n Robot.m_driveTrain.driveTrainRightRearMotor.setSelectedSensorPosition(0);\n Robot.m_driveTrain.driveTrainLeftRearMotor.setSelectedSensorPosition(0);\n\n /*\n * String autoSelected = SmartDashboard.getString(\"Auto Selector\",\n * \"Default\"); switch(autoSelected) { case \"My Auto\": autonomousCommand\n * = new MyAutoCommand(); break; case \"Default Auto\": default:\n * autonomousCommand = new ExampleCommand(); break; }\n */\n\n // schedule the autonomous command (example)\n }", "@Override\n public void autonomousInit()\n {\n autonomousCommand = chooser.getSelected();\n \n /*\n * String autoSelected = SmartDashboard.getString(\"Auto Selector\",\n * \"Default\"); switch(autoSelected) { case \"My Auto\": autonomousCommand\n * = new MyAutoCommand(); break; case \"Default Auto\": default:\n * autonomousCommand = new ExampleCommand(); break; }\n */\n \n // schedule the autonomous command (example)\n if (autonomousCommand != null) \n {\n autonomousCommand.start();\n }\n }", "@Override\n public void execute() {\n if (System.currentTimeMillis() - currentMs >= timeMs) {\n // Delay has passed so initialize object11\n super.initialize();\n }\n }", "@Scheduled(fixedRate = 2000, initialDelay = 5000)\n\tpublic void scheduleTaskWithInitialDelay() {\n\t\tlog.info(\"Fixed Rate Task With Initial Delay :: Execution Time - {}\", dateTimeFormatter.format(LocalDateTime.now()));\n\t}", "@Override\n\tpublic void autonomousInit() //initialization of the autonomous code\n\t{\n\t\t//m_autonomousCommand = m_chooser.getSelected();\n\n\t\t/*\n\t\t * String autoSelected = SmartDashboard.getString(\"Auto Selector\",\n\t\t * \"Default\"); switch(autoSelected) { case \"My Auto\": autonomousCommand\n\t\t * = new MyAutoCommand(); break; case \"Default Auto\": default:\n\t\t * autonomousCommand = new ExampleCommand(); break; }\n\t\t */\n\n\t\t// schedule the autonomous command (example)\n\t\tif (m_autonomousCommand != null) //if we have any autonomous code, start it\n\t\t{\n\t\t\tm_autonomousCommand.start();\n\t\t}\n\t\tRobotMap.encoderLeft.reset(); //reset the values of the encoder\n\t\tRobotMap.encoderRight.reset(); //reset the values of the encoder\n\t\tultrasonic.getInitialDist(); //if nullPointerException, use \"first\" boolean inside the method and run in periodic()\n\t}", "protected abstract void scheduler_init();", "@Override\r\n public void robotPeriodic() {\r\n // Runs the Scheduler. This is responsible for polling buttons, adding newly-scheduled\r\n // commands, running already-scheduled commands, removing finished or interrupted commands,\r\n // and running subsystem periodic() methods. This must be called from the robot's periodic\r\n // block in order for anything in the Command-based framework to work.\r\n CommandScheduler.getInstance().run();\r\n }", "@Override\n public void periodic() {\n // This method will be called once per scheduler run\n }", "@Scheduled(fixedRate = 2000, initialDelay = 5000)\n public void scheduleTaskWithInitialDelay() {\n logger.info(\"Fixed Rate Task with Initial Delay :: Execution Time - {}\", formatter.format(LocalDateTime.now()));\n }", "@Override\n public void taskStarting() {\n\n }", "@Override\n public void robotPeriodic() {\n // Runs the Scheduler. This is responsible for polling buttons, adding newly-scheduled\n // commands, running already-scheduled commands, removing finished or interrupted commands,\n // and running subsystem periodic() methods. This must be called from the robot's periodic\n // block in order for anything in the Command-based framework to work.\n CommandScheduler.getInstance().run();\n }", "public InstantCommand() {\n\t\t//let's all laugh really hard at the style checker...\n\t\tm_toRun = () -> {};\n\t}", "@Override\n\tpublic void autonomousInit() {\n\t\t//SmartDashboard.getData(\"Driver File\");\n\t\t//SmartDashboard.getData(\"Operator File\");\n\t\tautonomousCommand = chooser.getSelected();\n\t\tisAutonomous = true;\n\t\tisTeleoperated = false;\n\t\tisEnabled = true;\n\t\tRobot.numToSend = 3;\n\t\tdrivebase.resetGyro();\n\n\t\t/*\n\t\t * String autoSelected = SmartDashboard.getString(\"Auto Selector\",\n\t\t * \"Default\"); switch(autoSelected) { case \"My Auto\": autonomousCommand\n\t\t * = new MyAutoCommand(); break; case \"Default Auto\": default:\n\t\t * autonomousCommand = new ExampleCommand(); break; }\n\t\t */\n\n\t\t// schedule the autonomous command (example)\n\t\tRobot.gearManipulator.gearManipulatorPivot.setPosition(0);\n\t\tRobot.gearManipulator.gearManipulatorPivot.setSetpoint(0);\n\t\tif (autonomousCommand != null)\n\t\t\tautonomousCommand.start();\n\t}", "public void autonomousPeriodic() {\r\n\t\tScheduler.getInstance().run();\r\n\t}", "public void autonomousInit(){\n\t \t//resetAndDisableSystems();\n\t\t \n\t \tautonomousCommand = (Command) autoChooser.getSelected();\n\t \tautonomousCommand.start();\n\t \t\n\t \t\n\t }", "public void autonomousPeriodic() {\n if (m_apFirstRun) {\n System.out.println(\"Default autonomousPeriodic() method... Override me!\");\n m_apFirstRun = false;\n }\n }", "public final void activate(){\n waitingToExecute = true;\n }", "public void autonomousPeriodic() {\r\n Scheduler.getInstance().run();\r\n }", "public void startExecuting()\n {\n super.startExecuting();\n this.breakingTime = 0;\n }", "public Command() {\n this.executed = false;\n }", "@Override\n\tpublic void teleopInit() {\n\t\tif (autonomousCommand != null)\n\t\t\tlowGearCommand.start();\n\t\tautonomousCommand.cancel();\n\t}", "public void autonomousPeriodic() {\n // RobotMap.helmsman.trackPosition();\n Scheduler.getInstance().run();\n }", "public void autonomousInit() {\n //autonomousCommand = (Command) chooser.getSelected();\n autoLoopCounter = 0; //This resets the loop counter to 0\n //if (autonomousCommand != null) autonomousCommand.start();\n }", "public void autonomousPeriodic() {\n Scheduler.getInstance().run();\n }", "public void autonomousPeriodic() {\n Scheduler.getInstance().run();\n }", "public void autonomousPeriodic() {\n Scheduler.getInstance().run();\n }", "public void autonomousPeriodic() {\n Scheduler.getInstance().run();\n }", "public void autonomousPeriodic() {\n Scheduler.getInstance().run();\n }", "public void autonomousPeriodic() {\n Scheduler.getInstance().run();\n }", "@Override\n protected void initializeMacroCommand() {\n \n addSubCommand(new PrepareControllerCommand());\n addSubCommand(new PrepareModelCommand());\n addSubCommand(new PrepareViewCommand());\n \n // Remove the command because it never be called more than once\n // getFacade().removeCommand(ApplicationConstants.STARTUP);\n }", "@Override\n public void autonomousPeriodic() {\n \n Scheduler.getInstance().run();\n \n }", "@Override\n public void autonomousPeriodic() {\n Scheduler.getInstance().run();\n }", "private void schedule() {\n service.scheduleDelayed(task, schedulingInterval);\n isScheduled = true;\n }", "@Override\n\tpublic void autonomousPeriodic() {\n\t\tScheduler.getInstance().run();\t\n\t}", "@Override\n public void disabledInit() {\n\t// new SetElevator(0).start();\n\tif (autonomousCommand != null)\n\t autonomousCommand.cancel();\n\tScheduler.getInstance().removeAll();\n }", "@Override\n\tpublic void autonomousInit() {\n\t\tif (autonomousCommand != null)\n\t\t\tlowGearCommand.start();\n\t\tautonomousCommand.start();\n\t}", "@Override\n public void autonomousInit() {\n\n autonomousCommand = new Autonomous(start.getSelected(), chooser.getSelected());\n \n autonomousCommand.start();\n }", "@Override\n\tpublic void autonomousPeriodic() {\n\t\tScheduler.getInstance().run();\n\t}", "@Override\n\tpublic void autonomousPeriodic() {\n\t\tScheduler.getInstance().run();\n\t}", "@Override\n\tpublic void autonomousPeriodic() {\n\t\tScheduler.getInstance().run();\n\t}", "@Override\n\tpublic void autonomousPeriodic() {\n\t\tScheduler.getInstance().run();\n\t}", "@Override\n public void autonomousPeriodic()\n {\n Scheduler.getInstance().run();\n }", "@Override\n\t\tvoid runCommand() {\n\t\t\ttrigger.execute();\n\t\t}", "public void autonomousPeriodic()\n\t{\n\t\tScheduler.getInstance().run();\n\t}", "public void initDefaultCommand() {\n setDefaultCommand(new shooterStart());\n }", "void beginPeriodic() {\n\t\t// if some subsystems need to get called in all modes at the beginning\n\t\t// of periodic, do it here\n\n\t\t// don't need to do anything\n\t}", "public void autonomousPeriodic() \n {\n Scheduler.getInstance().run();\n }", "public void autonomousInit() {\n autonomousCommand = (Command) autoChooser.getSelected();\n autonomousCommand.start();\n// \n }", "@PostConstruct\n public void init() {\n threadPoolTaskScheduler.scheduleWithFixedDelay(this::process, Instant.now(), Duration.ofSeconds(30));\n }", "@Override\n public void execute() {\n Time.sleep(3000);\n Starting.execute();\n }", "public void intialRun() {\n }", "protected void execute() {\n \tRobot.chassisSubsystem.shootHighM.set(0.75);\n \tif(timeSinceInitialized() >= 1.25){\n \t\tRobot.chassisSubsystem.liftM.set(1.0);\n \t}\n }", "void doManualStart();", "protected void initialize() {\n \tRobot.telemetry.setAutonomousStatus(\"Starting \" + commandName + \": \" + distance);\n \tRobot.drivetrain.resetEncoder();\n \t\n \tRobot.driveDistancePID.setSetpoint(distance);\n \tRobot.driveDistancePID.setRawTolerance(RobotPreferences.drivetrainTolerance());\n \tRobot.driveDistancePID.enable();\n \t\n \texpireTime = timeSinceInitialized() + (RobotPreferences.timeOut());\n }", "@Override\r\n protected void initialize() {\n if (getCommandName().equals(COMMAND_NAME)) {\r\n logMessage(getParmDesc() + \" starting\");\r\n }\r\n\r\n driveSubsystem.setSpeed(speed, speed);\r\n }", "public void autonomousInit() {\n\t\ttimer.start();\n\t\tautonomousCommand = autoChooser.getSelected();\n\t\t//This outputs what we've chosen in the SmartDashboard as a string.\n\t\tSystem.out.println(autonomousCommand);\n\t\tif (DriverStation.getInstance().isFMSAttached()) {\n\t\t\tgameData = DriverStation.getInstance().getGameSpecificMessage();\n\t\t}\n\t\telse {\n\t\t\tgameData=\"RLR\";\n\t\t}\n\t\t//armSwing.setAngle(90); //hopefully this will swing the arms down. not sure what angle it wants though\n\t}", "private void scheduleJob() {\n\n }", "@Override\r\n\tpublic void tellStarting() {\r\n\t\t// TODO Auto-generated method stub\r\n\r\n\t\t// Not used here\r\n\t}", "public void robotPeriodic() {\n if (m_rpFirstRun) {\n System.out.println(\"Default robotPeriodic() method... Override me!\");\n m_rpFirstRun = false;\n }\n }", "@Override\n\tpublic void start()\n\t{\n\t\tarena = \"scenarios/boxpushing/arena/pioneer.controller.arena.txt\"; \n\n\t\t\n\t\tschedule.reset();\n\n\t\tsuper.start();\n\n\t\tresetBehavior();\n\n\t}", "@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}", "@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}", "public void teleopInit() {\n\t\tif (autonomousCommand != null)\n\t\t\tautonomousCommand.cancel();\n\t\t\n//\t\tif ((intake.intakeIsUp() || intake.intakeSolenoidIsOff()) && shooterArm.getAngle() > 45) {\n//\t\t\traiseArm90.start();\t\t\t\n//\t\t}\n\t\tshooterArm.setBrakeOff();\n\t\t\n\t\tvision.enableCameraSaving();\n\t\tvision.setCameraPeriod(1);\n\t}", "public void prePerform() {\n // nothing to do by default\n }", "@Override\n public void teleopInit() {\n\t// This makes sure that the autonomous stops running when\n\t// teleop starts running. If you want the autonomous to\n\t// continue until interrupted by another command, remove\n\t// this line or comment it out.\n\tif (autonomousCommand != null) {\n\t autonomousCommand.cancel();\n\t}\n }", "@Override\r\n\t\t\tpublic void autInitProcess() {\n\t\t\t}", "public void initDefaultCommand() \n {\n }", "public static void init(){\r\n CommandBase.magazine.setSpeed(0.0);\r\n CommandBase.loader.setSpeed(0.0);\r\n Init.manualTankDrive.start(); \r\n Init.runCompressor.start();\r\n Init.stopGyroDrift.start();\r\n \r\n }", "public void teleopPeriodic() {\n if (m_tpFirstRun) {\n System.out.println(\"Default teleopPeriodic() method... Override me!\");\n m_tpFirstRun = false;\n }\n }", "public void initDefaultCommand() {\n \n }", "public void initDefaultCommand() {\n }", "public void initDefaultCommand() {\n }", "public void initDefaultCommand() {\n }", "public void initDefaultCommand() {\n }", "public void initDefaultCommand() {\n }", "public void initDefaultCommand() {\n }", "public void initDefaultCommand() {\n }", "public void initDefaultCommand() {\n }", "public void initDefaultCommand() {\n }", "public void initDefaultCommand() {\n }", "public void initDefaultCommand() {\n }", "public void initDefaultCommand() {\n }", "public void initDefaultCommand() {\n }", "public void initDefaultCommand() {\n }", "public void initDefaultCommand() {\n }" ]
[ "0.694831", "0.6869797", "0.6774711", "0.67235124", "0.66945976", "0.66753703", "0.6657486", "0.66475713", "0.6604096", "0.6577765", "0.6561175", "0.6482039", "0.64754146", "0.644672", "0.6402472", "0.6344543", "0.6339042", "0.6322262", "0.63140696", "0.62958276", "0.62720674", "0.62664163", "0.6261111", "0.62571466", "0.6251572", "0.62421125", "0.62352216", "0.6234025", "0.623369", "0.62323254", "0.6217575", "0.6216372", "0.62088937", "0.620569", "0.62020177", "0.62020177", "0.62020177", "0.62020177", "0.62020177", "0.62020177", "0.62004745", "0.61980206", "0.61886495", "0.6185543", "0.6185411", "0.6181534", "0.61769086", "0.61761785", "0.61623883", "0.61623883", "0.61623883", "0.61623883", "0.61563826", "0.6153124", "0.6151394", "0.61498344", "0.61463493", "0.6144683", "0.61263484", "0.6116391", "0.61108017", "0.6102207", "0.6097001", "0.60824543", "0.60712206", "0.6067445", "0.606492", "0.6063349", "0.60496444", "0.60440403", "0.6025948", "0.60228336", "0.60228336", "0.60194737", "0.60194737", "0.60194737", "0.60194737", "0.60194737", "0.6002024", "0.60005176", "0.5997005", "0.5992159", "0.59915394", "0.59911036", "0.59857327", "0.5979954", "0.5972569", "0.5972569", "0.5972569", "0.5972569", "0.5972569", "0.5972569", "0.5972569", "0.5972569", "0.5972569", "0.5972569", "0.5972569", "0.5972569", "0.5972569", "0.5972569", "0.5972569" ]
0.0
-1
Called every time the scheduler runs while the command is scheduled.
@Override public void execute() {}
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n public void periodic() {\n // This method will be called once per scheduler run\n }", "@Override\n public void autonomousPeriodic() {\n \n Scheduler.getInstance().run();\n \n }", "@Override\n public void autonomousPeriodic() {\n Scheduler.getInstance().run();\n }", "@Override\n public void autonomousPeriodic()\n {\n Scheduler.getInstance().run();\n }", "@Override\n\tpublic void autonomousPeriodic() {\n\t\tScheduler.getInstance().run();\t\n\t}", "@Override\n public void run() {\n schedule();\n }", "public void autonomousPeriodic() {\r\n Scheduler.getInstance().run();\r\n }", "public void autonomousPeriodic() \n {\n Scheduler.getInstance().run();\n }", "@Override\n\tpublic void autonomousPeriodic() {\n\t\tScheduler.getInstance().run();\n\t}", "@Override\n\tpublic void autonomousPeriodic() {\n\t\tScheduler.getInstance().run();\n\t}", "@Override\n\tpublic void autonomousPeriodic() {\n\t\tScheduler.getInstance().run();\n\t}", "@Override\n\tpublic void autonomousPeriodic() {\n\t\tScheduler.getInstance().run();\n\t}", "public void autonomousPeriodic() {\n Scheduler.getInstance().run();\n }", "public void autonomousPeriodic() {\n Scheduler.getInstance().run();\n }", "public void autonomousPeriodic() {\n Scheduler.getInstance().run();\n }", "public void autonomousPeriodic() {\n Scheduler.getInstance().run();\n }", "public void autonomousPeriodic() {\n Scheduler.getInstance().run();\n }", "public void autonomousPeriodic() {\n Scheduler.getInstance().run();\n }", "public void autonomousPeriodic() {\r\n\t\tScheduler.getInstance().run();\r\n\t}", "@Override\n public void teleopPeriodic()\n {\n Scheduler.getInstance().run();\n }", "public void run() {\n\t\t\t\tIMSScheduleManager.super.startCron();\r\n\t\t\t\t\r\n\t\t\t}", "private void schedule() {\n service.scheduleDelayed(task, schedulingInterval);\n isScheduled = true;\n }", "private void scheduleJob() {\n\n }", "@Override\n\tpublic void teleopPeriodic() {\n\t\tScheduler.getInstance().run();\n\t}", "@Override\n\tpublic void teleopPeriodic() {\n\t\tScheduler.getInstance().run();\n\t}", "@Override\n\tpublic void teleopPeriodic() {\n\t\tScheduler.getInstance().run();\n\t}", "@Override\n public void autonomousPeriodic() \n {\n Scheduler.getInstance().run();\n log();\n }", "@Override\r\n public void robotPeriodic() {\r\n // Runs the Scheduler. This is responsible for polling buttons, adding newly-scheduled\r\n // commands, running already-scheduled commands, removing finished or interrupted commands,\r\n // and running subsystem periodic() methods. This must be called from the robot's periodic\r\n // block in order for anything in the Command-based framework to work.\r\n CommandScheduler.getInstance().run();\r\n }", "private void beginSchedule(){\n\t\tDivaApp.getInstance().submitScheduledTask(new RandomUpdater(this), RandomUpdater.DELAY, RandomUpdater.PERIOD);\n\t}", "@Override\n public void robotPeriodic() {\n // Runs the Scheduler. This is responsible for polling buttons, adding newly-scheduled\n // commands, running already-scheduled commands, removing finished or interrupted commands,\n // and running subsystem periodic() methods. This must be called from the robot's periodic\n // block in order for anything in the Command-based framework to work.\n CommandScheduler.getInstance().run();\n }", "public void autonomousPeriodic()\n\t{\n\t\tScheduler.getInstance().run();\n\t}", "public void teleopPeriodic() {\r\n\t\tScheduler.getInstance().run();\r\n\t}", "private void runPeriodic() {\n boolean ok = ScheduledFutureTask.super.runAndReset();\n boolean down = isShutdown();\n // Reschedule if not cancelled and not shutdown or policy allows\n if (ok && !down) {\n updateNextExecutionTime();\n MeasurableScheduler.super.getQueue().add(this);\n }\n // This might have been the final executed delayed\n // task. Wake up threads to check.\n else if (down)\n interruptIdleWorkers();\n }", "@Override\n public void autonomousPeriodic() {\n \tbeginPeriodic();\n Scheduler.getInstance().run();\n endPeriodic();\n }", "@Override\n public void autonomousPeriodic() {\n\t// updateDiagnostics();9\n\tScheduler.getInstance().run();\n }", "@Override\n\tpublic void autonomousPeriodic() {\n\t\tScheduler.getInstance().run();\n\t\tlog();\n\t}", "public void teleopPeriodic()\n\t{\n\t\tScheduler.getInstance().run();\n\t}", "@Override\n public void teleopPeriodic() {\n Scheduler.getInstance().run();\n \n }", "public void teleopPeriodic() {\n Scheduler.getInstance().run();\n }", "public void teleopPeriodic() {\n Scheduler.getInstance().run();\n }", "public void teleopPeriodic() {\n Scheduler.getInstance().run();\n }", "public void teleopPeriodic() {\n Scheduler.getInstance().run();\n }", "public void autonomousPeriodic() {\n // RobotMap.helmsman.trackPosition();\n Scheduler.getInstance().run();\n }", "@Override\n public void teleopPeriodic() {\n\tupdateDiagnostics();\n\tScheduler.getInstance().run();\n }", "@Override\n public void teleopPeriodic() {\n Scheduler.getInstance().run();\n log();\n }", "@Override\n public void teleopPeriodic() {\n \tbeginPeriodic();\n Scheduler.getInstance().run();\n endPeriodic();\n }", "protected void runEachMinute() {\n \n }", "@Override\n public void autonomousPeriodic() {\n\n }", "@Override\n public void autonomousPeriodic() {\n \n }", "@Override\n public void autonomousPeriodic() {\n }", "@Override\n public void run() {\n // 获取最近一次执行时间并将其格式化。\n SimpleDateFormat simpleDateFormat = new SimpleDateFormat(\"yyyy-MM-dd HH:mm:ss\");\n System.out.println(\"Scheduled exec time is: \" + simpleDateFormat.format(scheduledExecutionTime()));\n System.out.println(\"Dancing...\");\n }", "@Override\n public void autonomousPeriodic() {\n }", "@Override\n public void autonomousPeriodic() {\n }", "@Override\n public void autonomousPeriodic() {\n }", "public void onScheduled(long scheduledTime);", "@Override\n public void autonomousPeriodic() {\n teleopPeriodic();\n //Scheduler.getInstance().run();\n }", "@Override\n public void run() {\n\n\n\n System.out.println(\"run scheduled jobs.\");\n\n\n checkBlackOutPeriod();\n\n\n\n checkOfficeActionPeriod1();\n\n checkAcceptedFilings();\n\n checkNOAPeriod();\n checkFilingExtensions();\n\n\n\n }", "void cronScheduledProcesses();", "@Override\n\tpublic void teleopPeriodic() {\n\t\tOI.refreshAll();\n\t\tScheduler.getInstance().run();\n\t\tlog();\n\t}", "@Override\n public void periodic() {\n UpdateDashboard();\n }", "public void teleopPeriodic() {\r\n Scheduler.getInstance().run();\r\n OI.poll();\r\n }", "protected void runEachDay() {\n \n }", "@Override\npublic void autonomousPeriodic() {\n\n}", "public void teleopPeriodic() {\n Scheduler.getInstance().run();\n rumbleInYourPants();\n turnSpindleIfNeeded();\n turnWinchIfNeeded();\n if (arcadeDrive != null) \n arcadeDrive.start();\n }", "public void autonomousPeriodic() {\r\n }", "public void autonomousPeriodic() {\r\n }", "@Override\n public void periodic() {\n\n }", "@Override\n public void periodic() {\n\n }", "public void run(){\n Timer time = new Timer(); // Instantiate Timer Object\n\n ScheduledClass st = new ScheduledClass(this.job,this.shm,time,this.stopp); // Instantiate SheduledTask class\n time.schedule(st, 0, this.periodicwait); // Create Repetitively task for every 1 secs\n }", "public abstract void schedule();", "public void autonomousPeriodic() {\n }", "public void autonomousPeriodic() {\n }", "@Override\r\n\tpublic void doInitialSchedules() {\n\t}", "public void autonomousPeriodic() {\n \n }", "public void autonomousPeriodic() {\n\n }", "public void autonomousPeriodic() {\n\n }", "public void autonomousPeriodic()\r\n {\r\n \r\n }", "protected void runEach10Minutes() {\n try {\n saveHistoryData();\n if (isEnabledScheduler()) {\n boolean action = getLightSchedule().getCurrentSchedule();\n if (action) {\n if (!currentState) switchOn();\n } else {\n if (currentState) switchOff();\n }\n }\n } catch (RemoteHomeManagerException e) {\n RemoteHomeManager.log.error(44,e);\n } catch (RemoteHomeConnectionException e) {\n RemoteHomeManager.log.error(45,e);\n }\n }", "public void teleopPeriodic() {\n Scheduler.getInstance().run();\n \n if(switchesSubsystem.readyToFire()) {\n \t\tSmartDashboard.putString(\"DB/String \"+0, \"ready to fire\");\n \t} else {\n \t\tSmartDashboard.putString(\"DB/String \"+0, \"reloading\");\n \t}\n \n SmartDashboard.putString(\"DB/String \"+1, \"Wound switch: \" + switchesSubsystem.isBarDown());\n \tSmartDashboard.putString(\"DB/String \"+2, \"Taut switch: \" + switchesSubsystem.isTaut());\n \tSmartDashboard.putString(\"DB/String \"+3, \"Fired switch: \" + switchesSubsystem.isLauncherFired());\n }", "public void testPeriodic() {\n Scheduler.getInstance().run();\n }", "@Override\n public void periodic() {\n\n }", "@Override\n public void periodic() {\n\n }", "@Override\n public void periodic() {\n\n }", "@Override\n public void periodic() {\n\n }", "public void scheduledUpdate() {\n\n if (isUpdating.compareAndSet(false, true)) {\n\n if (getCurrentChannel() != null) {\n\n updateData();\n }\n }\n\n timer.cancel();\n timer.purge();\n\n timer = new Timer();\n timer.scheduleAtFixedRate(new UpdateTask(), 3600000,\n 3600000);\n\n }", "@Override\n public void periodic() {\n }", "@Override\n public void periodic() {\n }", "@Override\n public void periodic() {\n }", "@Override\n public void periodic() {\n }", "@Override\n public void periodic() {\n }", "@Override\n public void periodic() {\n }", "@Override\n public void periodic() {\n }", "@Override\n public void periodic() {\n }", "@Override\n public void periodic() {\n }", "@Override\n public void periodic() {\n }", "@Override\n public void periodic() {\n }", "@Override\n public void periodic() {\n }", "@Override\n public void periodic() {\n }", "@Override\n public void periodic() {\n }", "@Override\n public void periodic() {\n }", "@Override\n public void periodic() {\n }" ]
[ "0.7797155", "0.75579756", "0.7485269", "0.7467775", "0.7382154", "0.73779386", "0.7344967", "0.73379356", "0.73203003", "0.73203003", "0.73203003", "0.73203003", "0.72729415", "0.72729415", "0.72729415", "0.72729415", "0.72729415", "0.72729415", "0.72440255", "0.72350013", "0.7199525", "0.71991044", "0.7198259", "0.7188848", "0.7188848", "0.7188848", "0.71826595", "0.71779203", "0.7170612", "0.7170059", "0.7169006", "0.7136016", "0.7131986", "0.7098389", "0.7089777", "0.70814157", "0.7062465", "0.7056574", "0.6983436", "0.6983436", "0.6983436", "0.6983436", "0.6949763", "0.6930449", "0.69208777", "0.69174796", "0.69049305", "0.6881868", "0.6853307", "0.6842861", "0.68399465", "0.68391114", "0.68391114", "0.68391114", "0.68215394", "0.67745733", "0.67699224", "0.6757896", "0.67248124", "0.6713118", "0.6688953", "0.66419864", "0.6630138", "0.659021", "0.658735", "0.658735", "0.65869117", "0.65869117", "0.6581126", "0.65682644", "0.65569943", "0.65569943", "0.65448445", "0.653665", "0.65355444", "0.65355444", "0.65314204", "0.6524012", "0.6521731", "0.65205854", "0.6515615", "0.6515615", "0.6515615", "0.6515615", "0.6512178", "0.6506252", "0.6506252", "0.6506252", "0.6506252", "0.6506252", "0.6506252", "0.6506252", "0.6506252", "0.6506252", "0.6506252", "0.6506252", "0.6506252", "0.6506252", "0.6506252", "0.6506252", "0.6506252" ]
0.0
-1
Called once the command ends or is interrupted.
@Override public void end(boolean interrupted) {}
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void endCommand();", "@Override\n protected void end() {\n System.out.println(\"elevator down command ended\");\n }", "@Override\n public void end(boolean interrupted) {\n return;\n }", "@Override\n protected void interrupted() {\n end();\n }", "@Override\n protected void interrupted() {\n end();\n }", "@Override\n protected void interrupted() {\n end();\n }", "@Override\n protected void interrupted() {\n end();\n }", "@Override\n protected void interrupted() {\n end();\n }", "@Override\n protected void interrupted() {\n end();\n }", "@Override\n protected void interrupted() {\n end();\n }", "@Override\n protected void interrupted() {\n end();\n }", "@Override\n protected void interrupted() {\n end();\n }", "@Override\n protected void interrupted() {\n end();\n }", "@Override\n protected void interrupted() {\n end();\n }", "@Override\n protected void interrupted() {\n end();\n }", "@Override\n protected void interrupted() {\n end();\n }", "@Override\n protected void interrupted() {\n end();\n }", "@Override\n protected void interrupted() {\n // isFinished = true;\n // end();\n }", "@Override\n protected void interrupted() {\n end();\n }", "@Override\n protected void interrupted() {\n end();\n }", "@Override\n protected void interrupted() {\n end();\n }", "@Override\n protected void interrupted() {\n end();\n }", "@Override\n public void end(boolean interrupted) {\n }", "@Override\n public void end(boolean interrupted) {\n }", "@Override\n public void end(boolean interrupted) {\n }", "@Override\n public void end(boolean interrupted) {\n }", "@Override\n public void end(boolean interrupted) {\n }", "@Override\n public void end(boolean interrupted) {\n }", "@Override\n public void end(boolean interrupted) {\n }", "@Override\n public void end(boolean interrupted) {\n }", "@Override\n public void end(boolean interrupted) {\n }", "@Override\n public void end(boolean interrupted) {\n }", "@Override\n public void end(boolean interrupted) {\n }", "@Override\n public void end(boolean interrupted) {\n }", "protected void interrupted() {\n end();\n }", "protected void interrupted() {\n end();\n }", "protected void interrupted() {\n end();\n }", "protected void interrupted() {\r\n end();\r\n }", "@Override\n protected void interrupted() \n {\n end();\n }", "protected void end() {\n \tRobot.telemetry.setAutonomousStatus(\"Finishing \" + commandName + \": \" + distance);\n Robot.driveDistancePID.disable();\n \tRobot.drivetrain.arcadeDrive(0.0, 0.0);\n }", "protected void end() {\n \tlogger.info(\"Ending AutoMoveLiftUp Command, encoder inches = {}\", Robot.liftSubsystem.readEncoderInInches());\n \t\n }", "@Override\r\n protected void interrupted() {\r\n \tend();\r\n }", "@Override\n public void end(boolean interrupted) {\n\n }", "protected void interrupted() {\r\n end();\r\n }", "protected void interrupted()\n {\n this.end();\n }", "@Override\n\tprotected void interrupted() {\n\t\tend();\n\t}", "protected void interrupted() {\n \t\n \tend();\n }", "protected void interrupted() {\n end();\r\n }", "protected void interrupted() {\n\t\tend();\n\t}", "protected void interrupted() {\n\t\tend();\n\t}", "protected void interrupted() {\n\t\tend();\n\t}", "protected void interrupted() {\n\t\tend();\n\t}", "protected void interrupted() {\n\t\tend();\n\t}", "protected void interrupted() {\n\t\tend();\n\t}", "protected void interrupted() {\n\t\tend();\n\t}", "protected void interrupted() {\n \tend();\n }", "protected void interrupted() {\n \tend();\n }", "protected void interrupted() {\n \tend();\n }", "protected void interrupted() {\n \tend();\n }", "protected void interrupted() {\n \tend();\n }", "protected void interrupted() {\n \tend();\n }", "protected void interrupted() {\n \tend();\n }", "protected void interrupted() {\n \tend();\n }", "protected void interrupted() {\n \tend();\n }", "protected void interrupted() {\n \tend();\n }", "protected void interrupted() {\n \tend();\n }", "protected void interrupted() {\n \tend();\n }", "protected void interrupted() {\n \tend();\n }", "protected void interrupted() {\n \tend();\n }", "protected void interrupted() {\n \tend();\n }", "protected void interrupted() {\n \tend();\n }", "protected void interrupted() {\n \tend();\n }", "protected void interrupted() {\n \tend();\n }", "protected void interrupted() {\n \tend();\n }", "protected void interrupted() {\n \tend();\n }", "protected void interrupted() {\n \tend();\n }", "protected void interrupted() {\n \tend();\n }", "protected void end() {\n isFinished();\n }", "@Override\n\tprotected void interrupted() {\n\t\tthis.end();\n\t}", "protected void end() {\r\n // stop motor, reset position on the dumper, enable closed loop\r\n }", "@Override\n public void end(boolean interrupted) {\n Robot.Climber.stop();\n SmartDashboard.putBoolean(\"Climb:\", false);\n }", "@Override\n\tpublic void end(boolean interrupted) {\n\t}", "protected void interrupted()\n\t{\n\t\tend();\n\t}", "protected void waitUntilCommandFinished() {\n }", "protected void interrupted() {\n\t\tSystem.out.println(\"AlignAndDrive interupted\");\n\t\tend();\n\t}", "public void end() {\n\t\tsigue = false;\n\t}", "protected void end()\n\t{\n\t\tstop();\n\t}", "@Override\n protected void end() {\n Robot.toteLifterSubsystem.setEjectorState(EjectorState.STOPPED, 0.0);\n }", "public void end() throws Exception;", "protected void end() {\n \t//Just let the lift keep holding the current motion magic\n \t//setpoint after this command ends\n \tRobot.debug.Stop();\n }", "@Override\n public void execute() {\n System.out.println(\"programm closed\");\n System.exit(0);\n }", "protected void end() {\n \tRobot.conveyor.stop();\n }", "@Override\n\tprotected void onTermination() throws SimControlException {\n\t\t\n\t}", "protected void exit() throws IOException {\r\n\t\tstop();\r\n\t\tkeepRunning = false;\r\n\t}", "protected void end() {\n\t\tRobot.conveyor.Stop();\n\t}", "protected void interrupted() {\n \n }", "protected void end() {\n \n \n }" ]
[ "0.7605449", "0.7176284", "0.7039006", "0.7019191", "0.7019191", "0.7019191", "0.7019191", "0.7019191", "0.7019191", "0.7019191", "0.7019191", "0.7019191", "0.7019191", "0.7019191", "0.7019191", "0.7019191", "0.7019191", "0.70119756", "0.6996919", "0.6995794", "0.6995794", "0.6995794", "0.6969432", "0.69664836", "0.69664836", "0.69664836", "0.69664836", "0.69664836", "0.69664836", "0.69664836", "0.69664836", "0.69664836", "0.69664836", "0.69664836", "0.69322675", "0.69322675", "0.69322675", "0.69310844", "0.6927687", "0.68840873", "0.6883039", "0.68731415", "0.68478703", "0.68441886", "0.68368876", "0.67998195", "0.6795387", "0.6781225", "0.6780453", "0.6780453", "0.6780453", "0.6780453", "0.6780453", "0.6780453", "0.6780453", "0.6738514", "0.6738514", "0.6738514", "0.6738514", "0.6738514", "0.6738514", "0.6738514", "0.6738514", "0.6738514", "0.6738514", "0.6738514", "0.6738514", "0.6738514", "0.6738514", "0.6738514", "0.6738514", "0.6738514", "0.6738514", "0.6738514", "0.6738514", "0.6738514", "0.6738514", "0.67380494", "0.67253214", "0.66523486", "0.66510886", "0.66411275", "0.6639811", "0.6628616", "0.6599552", "0.6560897", "0.64974415", "0.6470508", "0.64387596", "0.6426708", "0.6426392", "0.63940674", "0.63899684", "0.6385863", "0.6374579", "0.63668466", "0.6351061" ]
0.7074365
5
Returns true when the command should end.
@Override public boolean isFinished() { return false; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public abstract boolean shouldEnd();", "private Boolean quitCommand() {\n output.println(\"QUIT COMMAND\");\n return false;\n }", "protected boolean isFinished() {\r\n\t \treturn (timeSinceInitialized() > .25) && (Math.abs(RobotMap.armarm_talon.getClosedLoopError()) < ARM_END_COMMAND_DIFFERENCE_VALUE); //TODO:\r\n\t }", "public void endCommand();", "private boolean isComplete() {\n return redisCommand != null && redisCommand.getAction() != null && !\"\".equals(redisCommand.getAction().trim()) && redisCommand.getArgList().size() == argSize - 1;\n }", "@Override\n public boolean isFinished() {\n return System.currentTimeMillis() >= endtime;\n }", "@Override\n\tprotected boolean isFinished() {\n\t\treturn (System.currentTimeMillis() > Endtime);\n\t}", "@Override\n public boolean isEnding() {\n return false;\n }", "@Override\n\tpublic boolean isFinished() {\n\t\treturn (this.timeRemaining == 0);\n\t}", "private boolean quit(Command command) \n {\n if(command.hasSecondWord()) {\n Logger.Log(\"Quit what?\");\n return false;\n }\n else {\n return true; // signal that we want to quit\n }\n }", "@Override\r\n\tpublic boolean isFinished() {\n\t\treturn finish;\r\n\t}", "private boolean quit(Command command) \n {\n if(command.hasSecondWord()) {\n System.out.println(\"Quit what?\");\n return false;\n }\n else {\n return true; // these shows that we want to quit\n }\n }", "protected boolean isFinished() {\n\t\treturn true;\n\t}", "protected boolean isFinished() {\n\t\treturn true;\n\t}", "protected boolean isFinished() {\n\t\treturn true;\n\t}", "protected boolean isFinished() {\n \t//ends \n \treturn isTimedOut();\n }", "protected boolean isFinished() {\n\t\treturn pid.onTarget();\n\t}", "private boolean quit(Command command) \n {\n if(command.hasSecondWord()) {\n System.out.println(\"Quit what?\");\n return false;\n }\n else {\n return true; // signal that we want to quit\n }\n }", "private boolean quit(Command command) \n {\n if(command.hasSecondWord()) {\n System.out.println(\"Quit what?\");\n return false;\n }\n else {\n return true; // signal that we want to quit\n }\n }", "protected boolean isFinished()\n\t{\n\t\treturn true;\n\t}", "@Override\n\tpublic boolean isFinished() {\n\t\treturn true;\n\t}", "public boolean isFinished() {\n\t\tif (getRemaining() <= 0) {\n\t\t\treturn true;\n\t\t}\n\t\treturn false;\n\t}", "protected boolean isFinished() {\n return Math.abs(pid.getError()) < 0.25;\n }", "protected boolean isFinished() {\n return true;\n }", "protected boolean isFinished() {\n return true;\n }", "protected boolean isFinished() {\n return true;\n }", "protected boolean isFinished() {\n return true;\n }", "protected boolean isFinished() {\n return true;\n }", "protected boolean isFinished() {\n return true;\n }", "public boolean isFinished() {\n return true;\n }", "public Guard isFinishedExecution() {\n if (depth == PSymGlobal.getConfiguration().getMaxStepBound()) {\n return Guard.constTrue();\n } else {\n return allMachinesHalted;\n }\n }", "@Override\n\tpublic boolean isFinished()\n\t{\n\t\treturn false;\n\t}", "public boolean quit(Command command) \n {\n if(command.hasSecondWord()) {\n System.out.println(\"Quit what?\");\n return false;\n }\n else {\n return true; // signal that we want to quit\n }\n }", "protected boolean isFinished() {\n logger.info(\"Ending left drive\");\n \treturn timer.get()>howLongWeWantToMove;\n }", "static private boolean quit(Command command) {\n if (command.hasSecondWord()) {\n System.out.println(\"Quit what?\");\n return false;\n } else {\n return true;\n }\n }", "public boolean isFinished(){\n return true;\n }", "protected boolean isFinished()\n\t{\n\t\treturn false;\n\t}", "protected boolean isFinished() {\n\t\treturn false;\n\t\t//return timeOnTarget >= finishTime;\n }", "protected boolean isFinished(){\r\n return true;\r\n }", "public Boolean isEnd() {\n\t\t// keep running\n\t\tif (currentNo == -1) {\n\t\t\treturn false;\n\t\t}\n\t\t\n\t\t// car production for this production line is done\n\t\telse if (currentNo >= expectedNo) {\n//\t\t\tSystem.out.println(\"isEnd of car Production line is \");\n//\t\t\tSystem.out.print(currentNo >= expectedNo);\n\n\t\t\treturn true;\n\t\t} else {\n//\t\t\tSystem.out.println(\"isEnd of car Production line is \");\n//\t\t\tSystem.out.print(currentNo >= expectedNo);\n\t\t\treturn false;\n\t\t}\n\n\t}", "public boolean end() {\n\t\ttry {\n\t\t\tbyte[] buffer = \"END\".getBytes();\n\t\t\toos.writeObject(buffer);\n\t\t} catch (Exception e) {\n\t\t\te.printStackTrace();\n\t\t\treturn false;\n\t\t}\n\t\treturn true;\n\t}", "@Override\n public boolean isExit() {\n return true;\n }", "protected boolean isFinished() {\n\t\treturn Robot.elevator.isInPosition(newPosition, direction);\n\t}", "protected boolean isFinished() {\n //return !RobotMap.TOTE_SWITCH.get();\n \treturn false;\n }", "public static boolean isDone(String command) {\r\n\t\tassert command != null;\r\n\t\tcommandType = Logic.determineCommandType(command);\r\n\t\tswitch (commandType) {\r\n\t\tcase DONE:\r\n\t\t\treturn true;\r\n\t\tdefault:\r\n\t\t\tbreak;\r\n\t\t}\r\n\t\treturn false;\r\n\t}", "@Override\n\t\tpublic boolean isFinished() {\n\t\t\treturn false;\n\t\t}", "protected boolean isFinished() {\n\t\treturn false;\n\t}", "protected boolean isFinished() {\n\t\treturn false;\n\t}", "protected boolean isFinished() {\n\t\treturn false;\n\t}", "protected boolean isFinished() {\n\t\treturn false;\n\t}", "protected boolean isFinished() {\n\t\treturn false;\n\t}", "protected boolean isFinished() {\n\t\treturn false;\n\t}", "protected boolean isFinished() {\r\n if (state == STATE_SUCCESS) {\r\n // Success\r\n return true;\r\n }\r\n if (state == STATE_FAILURE) {\r\n // Failure\r\n return true;\r\n }\r\n return false;\r\n }", "protected boolean isFinished() {\n\t\treturn false;\r\n\t}", "protected boolean isFinished() {\n\t\treturn isFinished;\n\t}", "@Override\r\n\tprotected boolean isFinished() {\n\t\treturn true;\r\n\t}", "@Override\r\n\tprotected boolean isFinished() {\n\t\treturn true;\r\n\t}", "protected boolean isFinished() {\n \t// wait for a time out\n return false;\n }", "@Override\n\tpublic boolean isFinished() {\n\t\treturn false;\n\t}", "@Override\n\tprotected boolean isFinished() {\n\t\treturn done; \n\t}", "public boolean isFinished();", "@Override\r\n protected boolean isFinished() {\n if (super.isFinished()) {\r\n return true;\r\n }\r\n\r\n return false;\r\n }", "protected boolean isFinished()\n\t{\n\t\treturn !Robot.oi.respoolWinch.get();\n\t}", "protected boolean isFinished() {\n \treturn (Robot.sonar.getDistance() <= distance);\n }", "@Override\n\tprotected boolean isFinished()\n\t{\n\t\treturn false;\n\t}", "protected abstract boolean end();", "protected boolean isFinished() {\n return finished;\n }", "protected boolean isFinished() {\n return Robot.claw.isRetracted();\n }", "protected boolean isFinished() {\n return isFinished;\n }", "@Override\n\tprotected boolean isFinished() {\n\t\treturn false;\n\t}", "@Override\n\tprotected boolean isFinished() {\n\t\treturn false;\n\t}", "@Override\n\tprotected boolean isFinished() {\n\t\treturn false;\n\t}", "@Override\n\tprotected boolean isFinished() {\n\t\treturn false;\n\t}", "@Override\n\tprotected boolean isFinished() {\n\t\treturn false;\n\t}", "@Override\n\tprotected boolean isFinished() {\n\t\treturn false;\n\t}", "@Override\n\tprotected boolean isFinished() {\n\t\treturn false;\n\t}", "@Override\n\tprotected boolean isFinished() {\n\t\treturn false;\n\t}", "@Override\n\tprotected boolean isFinished() {\n\t\treturn false;\n\t}", "protected boolean isFinished() {\r\n\treturn false;\r\n }", "protected boolean isFinished() {\n return false;\n }", "protected boolean isFinished() {\n return false;\n }", "protected boolean isFinished() {\n return false;\n }", "protected boolean isFinished() {\n return false;\n }", "protected boolean isFinished() {\n return false;\n }", "protected boolean isFinished() {\n return false;\n }", "protected boolean isFinished() {\n return false;\n }", "protected boolean isFinished() {\n return false;\n }", "protected boolean isFinished() {\n return false;\n }", "protected boolean isFinished() {\n return false;\n }", "protected boolean isFinished() {\n return false;\n }", "protected boolean isFinished() {\n return false;\n }", "protected boolean isFinished() {\n return false;\n }", "protected boolean isFinished() {\n return false;\n }", "protected boolean isFinished() {\n return false;\n }", "protected boolean isFinished() {\n return false;\n }", "protected boolean isFinished() {\n return false;\n }", "protected boolean isFinished() {\n return false;\n }", "protected boolean isFinished() {\n return false;\n }", "protected boolean isFinished() {\n return false;\n }", "protected boolean isFinished() {\n return false;\n }", "protected boolean isFinished() {\n return false;\n }" ]
[ "0.75273657", "0.73602504", "0.73465896", "0.71294767", "0.7033159", "0.7012778", "0.700753", "0.6994238", "0.6931957", "0.6927545", "0.6915831", "0.68845886", "0.68594575", "0.68594575", "0.68594575", "0.6853999", "0.68532574", "0.6851464", "0.6851464", "0.6837983", "0.68260324", "0.67944705", "0.6790352", "0.6787929", "0.6787929", "0.6787929", "0.6787929", "0.6787929", "0.6787929", "0.67818975", "0.67786217", "0.6778202", "0.6770069", "0.6765901", "0.6757644", "0.67570454", "0.675351", "0.6746853", "0.67448765", "0.673654", "0.67348415", "0.6729635", "0.67287415", "0.67188156", "0.6715925", "0.6713165", "0.6708804", "0.6708804", "0.6708804", "0.6708804", "0.6708804", "0.6708804", "0.6702017", "0.66926044", "0.66913027", "0.668989", "0.668989", "0.6679259", "0.6670593", "0.6662767", "0.6659927", "0.66539127", "0.665286", "0.6633671", "0.6629671", "0.6624843", "0.66048396", "0.6600003", "0.65889597", "0.65866053", "0.65866053", "0.65866053", "0.65866053", "0.65866053", "0.65866053", "0.65866053", "0.65866053", "0.65866053", "0.65853024", "0.65815485", "0.65815485", "0.65815485", "0.65815485", "0.65815485", "0.65815485", "0.65815485", "0.65815485", "0.65815485", "0.65815485", "0.65815485", "0.65815485", "0.65815485", "0.65815485", "0.65815485", "0.65815485", "0.65815485", "0.65815485", "0.65815485", "0.65815485", "0.65815485", "0.65815485" ]
0.0
-1
Constructor to create a new instance of this class
public JscriptWorkflowNode(String name, String title, String description, boolean isTaskNode, ArrayList<JscriptWorkflowTransition> transitions, Scriptable scope, ServiceRegistry serviceRegistry) { this.name = name; this.title = title; this.description = description; this.isTaskNode = isTaskNode; this.transitions = transitions; this.scope = scope; this.serviceRegistry = serviceRegistry; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "Constructor() {\r\n\t\t \r\n\t }", "private Instantiation(){}", "public Constructor(){\n\t\t\n\t}", "public CyanSus() {\n\n }", "public PSRelation()\n {\n }", "Reproducible newInstance();", "public _355() {\n\n }", "public Trening() {\n }", "public Chick() {\n\t}", "public Instance() {\n }", "public Pitonyak_09_02() {\r\n }", "public Vector() {\n construct();\n }", "public Cohete() {\n\n\t}", "public Lanceur() {\n\t}", "public Chauffeur() {\r\n\t}", "public Mitarbeit() {\r\n }", "public Stack() {\r\n this(20);\r\n }", "public Ov_Chipkaart() {\n\t\t\n\t}", "public Curso() {\r\n }", "public Orbiter() {\n }", "private TMCourse() {\n\t}", "public Factory() {\n\t\tsuper();\n\t}", "public Supercar() {\r\n\t\t\r\n\t}", "public Pasien() {\r\n }", "public Magazzino() {\r\n }", "@SuppressWarnings(\"unused\")\n public NoConstructor() {\n // Empty\n }", "public Phl() {\n }", "public Clade() {}", "public Classroom() {\n\t}", "public Odontologo() {\n }", "public Coche() {\n super();\n }", "public Classe() {\r\n }", "public Parser()\n {\n //nothing to do\n }", "public Car() {\r\n this(\"\", \"\", \"\", 0, Category.EMPTY, 0.00, \"\", 0, \"\", 0.00, \"\", DriveTrain.EMPTY,\r\n Aspiration.EMPTY, 0.00, 0.00, 0.00, 0.00, 0.0, 0.0, 0.0, 0.0, 0.0);\r\n }", "protected abstract void construct();", "public CustomerNew () {\n\t\tsuper();\n\t}", "private Sequence() {\n this(\"<Sequence>\", null, null);\n }", "public TV() {\r\n\t}", "public ClassTemplate() {\n\t}", "public Carrera(){\n }", "public ExamMB() {\n }", "public PjxParser()\r\n {\r\n LOG.info(this + \" instantiated\");\r\n }", "public Self__1() {\n }", "public TTau() {}", "public Book() {\n\t\t// Default constructor\n\t}", "public Livro() {\n\n\t}", "public Person() {\n\t\t\n\t}", "public Aanbieder() {\r\n\t\t}", "public Libro() {\r\n }", "public CSSTidier() {\n\t}", "public Card() { this(12, 3); }", "public ObjectFactory() {\n super(grammarInfo);\n }", "public Alojamiento() {\r\n\t}", "public Account() {\n this(0, 0.0, \"Unknown name\"); // Invole the 2-param constructor\n }", "private ATCres() {\r\n // prevent to instantiate this class\r\n }", "public Mueble() {\n }", "public Data() {\n \n }", "public SgaexpedbultoImpl()\n {\n }", "public Node(){\n this(9);\n }", "public Model() {\n\t}", "public Model() {\n\t}", "public OVChipkaart() {\n\n }", "private Composite() {\n }", "public SlanjePoruke() {\n }", "public Achterbahn() {\n }", "public RngObject() {\n\t\t\n\t}", "public ContasCorrentes(){\n this(0,\"\",0.0,0.0,0);\n }", "public Goodsinfo() {\n super();\n }", "defaultConstructor(){}", "private SingleObject()\r\n {\r\n }", "public Rol() {}", "private Node() {\n\n }", "private Recommendation() {\r\n }", "public Overview() {\n\t\t// It will work whenever i create object with using no parameter const\n\t\tSystem.out.println(\"This is constructor\");\n\t}", "private Marinator() {\n }", "private Marinator() {\n }", "public Tigre() {\r\n }", "public Node(){\n\n\t\t}", "public Tbdtokhaihq3() {\n super();\n }", "public Property() {\n this(0, 0, 0, 0);\n }", "public Corso() {\n\n }", "public Vaccine() {\n\t}", "public Generic(){\n\t\tthis(null);\n\t}", "private MazeBuilder() {\n\t}", "public Gasto() {\r\n\t}", "public AFMV() {\r\n }", "public Individual()\r\n\t{\r\n\t}", "public Soil()\n\t{\n\n\t}", "public Excellon ()\n {}", "public BaseballCard(){\r\n\r\n\t}", "public Potencial() {\r\n }", "public Kullanici() {}", "public Anschrift() {\r\n }", "public Data() {\n }", "public Data() {\n }", "public Zeffit()\n {\n // TODO: initialize instance variable(s)\n }", "public Nota() {\n }", "public Supermarket() {\n }", "public CMN() {\n\t}", "private TweetRiver() { }", "public Supermarket() {\n }" ]
[ "0.77971274", "0.76510614", "0.76498926", "0.70715857", "0.70629346", "0.6980835", "0.6962109", "0.69327337", "0.6925592", "0.68914145", "0.67711043", "0.6751771", "0.67508894", "0.6749375", "0.67429984", "0.67364454", "0.6734315", "0.6725938", "0.6724877", "0.6712362", "0.67114896", "0.6692464", "0.66847986", "0.6683667", "0.6679851", "0.66769063", "0.6668356", "0.66652954", "0.6664963", "0.6664594", "0.6664264", "0.6655483", "0.6646083", "0.66414046", "0.6632077", "0.6622188", "0.66177535", "0.6606332", "0.66055894", "0.6600899", "0.65892416", "0.6583163", "0.6579198", "0.6578802", "0.6577392", "0.65771836", "0.6576829", "0.65726", "0.65668416", "0.65638983", "0.6563303", "0.65547985", "0.65543973", "0.6554222", "0.65507054", "0.65507007", "0.65504533", "0.6545288", "0.654499", "0.65392226", "0.65392226", "0.6538521", "0.6534794", "0.6534172", "0.6527709", "0.65273315", "0.65209603", "0.65202975", "0.6516447", "0.6515067", "0.6513504", "0.6509165", "0.650265", "0.6485943", "0.6481158", "0.6481158", "0.6480838", "0.6471843", "0.6466889", "0.64659745", "0.64649034", "0.64637554", "0.64621216", "0.6460095", "0.6456744", "0.64541775", "0.64535064", "0.64495367", "0.6440642", "0.64397866", "0.64382595", "0.6437081", "0.64370334", "0.6437021", "0.6437021", "0.642292", "0.6421321", "0.6420398", "0.641948", "0.64139223", "0.64136535" ]
0.0
-1
Constructor to create a new instance of this class from an existing instance of WorkflowNode from the CMR workflow object model
public JscriptWorkflowNode(WorkflowNode workflowNode, Scriptable scope, ServiceRegistry serviceRegistry) { this.name = workflowNode.name; this.title = workflowNode.title; this.description = workflowNode.description; this.isTaskNode = workflowNode.isTaskNode; this.transitions = new ArrayList<JscriptWorkflowTransition>(); WorkflowTransition[] cmrWorkflowTransitions = workflowNode.transitions; for (WorkflowTransition cmrWorkflowTransition : cmrWorkflowTransitions) { transitions.add(new JscriptWorkflowTransition(cmrWorkflowTransition)); } this.scope = scope; this.serviceRegistry = serviceRegistry; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public Workflow() {\n\t\tsuper();\n\t}", "public WorkflowConfiguration() {\n\t\t\n\t}", "public FlowNodeInstance() {\n\t}", "public WorkflowResource() {\r\n\t}", "public JscriptWorkflowNode(String name, String title, String description,\n \tboolean isTaskNode, ArrayList<JscriptWorkflowTransition> transitions,\n \tScriptable scope, ServiceRegistry serviceRegistry)\n\t{\n \tthis.name = name;\n \tthis.title = title;\n \tthis.description = description;\n \tthis.isTaskNode = isTaskNode;\n \tthis.transitions = transitions;\n \tthis.scope = scope;\n \tthis.serviceRegistry = serviceRegistry;\n\t}", "protected CreateMachineNodeModel() {\r\n super(0,1);\r\n }", "public EWorkflowFactoryImpl() {\n\t\tsuper();\n\t}", "public Workflow(ArrayList<Component> components) {\n\t\tsuper();\n\t\tsetSubComponents(components);\n\t}", "public WorkflowsExample() {\n oredCriteria = new ArrayList<Criteria>();\n }", "protected AddTranscriptNodeModel() {\r\n this(1,2);\r\n }", "public static WorkflowDTO fromGenericValue(GenericValue gv) {\n return new WorkflowDTO(\n gv.getLong(\"id\"),\n gv.getString(\"name\"),\n gv.getString(\"creator\"),\n gv.getString(\"descriptor\"),\n gv.getString(\"islocked\")\n );\n }", "public Node(){}", "public Node(){\n\n\t\t}", "public WorkflowTheme(java.lang.Object instance) throws Throwable {\n super(instance);\n if (instance instanceof JCObject) {\n classInstance = (JCObject) instance;\n } else\n throw new Exception(\"Cannot manage object, it is not a JCObject\");\n }", "public NotebookWorkspaceInner() {\n }", "protected IndigoValenceCheckerNodeModel()\r\n {\r\n super(1, 3);\r\n }", "public Node() {}", "public Node() {}", "public Node() {}", "public Node() {}", "Node(Team v){\r\n value = v;\r\n }", "protected GraphNode() {\n }", "protected GraphNode() {\n }", "public Node() {\n name = null;\n missionDescription = null;\n roles = null;\n stateValueBindings = null;\n nodeRuntime = null;\n isNetworkSingleton = false;\n }", "public Node() {\r\n\t}", "public Node() {\r\n\t}", "public SynapseNotebookActivity() {}", "private FlowWorkspaces()\r\n {\r\n // Private constructor to prevent instantiation\r\n }", "public Task(Task source) {\n if (source.Application != null) {\n this.Application = new Application(source.Application);\n }\n if (source.TaskName != null) {\n this.TaskName = new String(source.TaskName);\n }\n if (source.TaskInstanceNum != null) {\n this.TaskInstanceNum = new Long(source.TaskInstanceNum);\n }\n if (source.ComputeEnv != null) {\n this.ComputeEnv = new AnonymousComputeEnv(source.ComputeEnv);\n }\n if (source.EnvId != null) {\n this.EnvId = new String(source.EnvId);\n }\n if (source.RedirectInfo != null) {\n this.RedirectInfo = new RedirectInfo(source.RedirectInfo);\n }\n if (source.RedirectLocalInfo != null) {\n this.RedirectLocalInfo = new RedirectLocalInfo(source.RedirectLocalInfo);\n }\n if (source.InputMappings != null) {\n this.InputMappings = new InputMapping[source.InputMappings.length];\n for (int i = 0; i < source.InputMappings.length; i++) {\n this.InputMappings[i] = new InputMapping(source.InputMappings[i]);\n }\n }\n if (source.OutputMappings != null) {\n this.OutputMappings = new OutputMapping[source.OutputMappings.length];\n for (int i = 0; i < source.OutputMappings.length; i++) {\n this.OutputMappings[i] = new OutputMapping(source.OutputMappings[i]);\n }\n }\n if (source.OutputMappingConfigs != null) {\n this.OutputMappingConfigs = new OutputMappingConfig[source.OutputMappingConfigs.length];\n for (int i = 0; i < source.OutputMappingConfigs.length; i++) {\n this.OutputMappingConfigs[i] = new OutputMappingConfig(source.OutputMappingConfigs[i]);\n }\n }\n if (source.EnvVars != null) {\n this.EnvVars = new EnvVar[source.EnvVars.length];\n for (int i = 0; i < source.EnvVars.length; i++) {\n this.EnvVars[i] = new EnvVar(source.EnvVars[i]);\n }\n }\n if (source.Authentications != null) {\n this.Authentications = new Authentication[source.Authentications.length];\n for (int i = 0; i < source.Authentications.length; i++) {\n this.Authentications[i] = new Authentication(source.Authentications[i]);\n }\n }\n if (source.FailedAction != null) {\n this.FailedAction = new String(source.FailedAction);\n }\n if (source.MaxRetryCount != null) {\n this.MaxRetryCount = new Long(source.MaxRetryCount);\n }\n if (source.Timeout != null) {\n this.Timeout = new Long(source.Timeout);\n }\n if (source.MaxConcurrentNum != null) {\n this.MaxConcurrentNum = new Long(source.MaxConcurrentNum);\n }\n if (source.RestartComputeNode != null) {\n this.RestartComputeNode = new Boolean(source.RestartComputeNode);\n }\n if (source.ResourceMaxRetryCount != null) {\n this.ResourceMaxRetryCount = new Long(source.ResourceMaxRetryCount);\n }\n }", "public Node() {\n\n }", "@Override\n protected Workflow copy(CompoundWorkflow parent) {\n return copyImpl(new AssignmentWorkflow(getNode().clone(), parent, newTaskTemplate, newTaskClass, newTaskOutcomes));\n }", "public Node() {\n\t}", "public NetworkNode(Node treeNode) {\n height = treeNode.getHeight();\n label = treeNode.getID();\n metaDataString = treeNode.metaDataString;\n for (String metaDataKey: treeNode.getMetaDataNames()) {\n Object metaDataValue = treeNode.getMetaData(metaDataKey);\n metaData.put(metaDataKey, metaDataValue);\n }\n }", "public Node(){\n this(9);\n }", "public Node(){\n }", "public static Object createTaskObject(){\n try {\n\n return taskModel.make()\n .load(ClassLoader.getSystemClassLoader(), ClassLoadingStrategy.Default.WRAPPER)\n .getLoaded()\n .newInstance();\n\n\n } catch (InstantiationException e) {\n e.printStackTrace();\n } catch (IllegalAccessException e) {\n e.printStackTrace();\n }\n\n return null;\n }", "InstanceModel createInstanceOfInstanceModel();", "protected IndigoReactionAutomapperNodeModel() {\n super(1, 2);\n }", "public AddNodeWorkflow(AddNodeRequest request) {\n this.id = UUID.randomUUID();\n this.request = request;\n actions = ImmutableList.of(new BootstrapNode(),\n new AddNodeToLayout(),\n new RestoreRedundancy());\n }", "public FlowRule() {\r\n }", "public Node()\r\n {\r\n initialize(null);\r\n lbl = id;\r\n }", "public Node() {\n }", "public Node(Node< ? > node)\n {\n id = node.getId();\n name = node.getName();\n idVirtualAppliance = node.getIdVirtualAppliance();\n nodeType = node.getNodeType();\n posX = node.getPosX();\n posY = node.getPosY();\n modified = node.getModified();\n }", "public VISNode() {\n this.model = new VISNodeModel();\n }", "Node(Object newItem){\n item = newItem; //--points to a different\n next = null;\n }", "public WorkflowApplication(WorkflowApplication other) {\n __isset_bitfield = other.__isset_bitfield;\n if (other.isSetId()) {\n this.id = other.id;\n }\n if (other.isSetProcessId()) {\n this.processId = other.processId;\n }\n if (other.isSetApplicationInterfaceId()) {\n this.applicationInterfaceId = other.applicationInterfaceId;\n }\n if (other.isSetComputeResourceId()) {\n this.computeResourceId = other.computeResourceId;\n }\n if (other.isSetQueueName()) {\n this.queueName = other.queueName;\n }\n this.nodeCount = other.nodeCount;\n this.coreCount = other.coreCount;\n this.wallTimeLimit = other.wallTimeLimit;\n this.physicalMemory = other.physicalMemory;\n if (other.isSetStatuses()) {\n java.util.List<ApplicationStatus> __this__statuses = new java.util.ArrayList<ApplicationStatus>(other.statuses.size());\n for (ApplicationStatus other_element : other.statuses) {\n __this__statuses.add(new ApplicationStatus(other_element));\n }\n this.statuses = __this__statuses;\n }\n if (other.isSetErrors()) {\n java.util.List<org.apache.airavata.model.commons.ErrorModel> __this__errors = new java.util.ArrayList<org.apache.airavata.model.commons.ErrorModel>(other.errors.size());\n for (org.apache.airavata.model.commons.ErrorModel other_element : other.errors) {\n __this__errors.add(new org.apache.airavata.model.commons.ErrorModel(other_element));\n }\n this.errors = __this__errors;\n }\n this.createdAt = other.createdAt;\n this.updatedAt = other.updatedAt;\n }", "private Node() {\n\n }", "public ModuleObjectAttributeItem() {}", "public ClassNode(OInstance instance) {\n\t\tname = instance.getName();\n\t\tsource = instance;\n\t}", "public TaskBoardModel() {\n\n }", "public T caseWorkflow(Workflow object) {\n\t\treturn null;\n\t}", "@Override\n\tpublic ITaskInstance createTaskInstance(WorkflowSession workflowSession,\n\t\t\tRuntimeContext rtCtx, IToken token,\n\t\t\tIProcessInstance processInstance, Task task, Activity activity) {\n\t\treturn null;\n\t}", "public Node(Node cloneNode) {\n\t\tthis.name = cloneNode.getName();\n\t\tthis.type = cloneNode.getType();\n\t\tthis.setX(cloneNode.getX());\n\t\tthis.setY(cloneNode.getY());\n\t\tthis.position = new Vector2(cloneNode.getPosition());\n\t}", "public Object clone()\r\n\t\tthrows CloneNotSupportedException\r\n\t{\r\n\t\tWorkflowTaskDescriptor clone = (WorkflowTaskDescriptor) super.clone();\r\n\r\n\t\t// Perform a deep copy\r\n\t\tclone.copyFrom(this, Copyable.COPY_DEEP);\r\n\r\n\t\treturn clone;\r\n\t}", "public ForkTask(RepositoryActivity activity) {\n mTarget = new WeakReference<RepositoryActivity>(activity);\n }", "public MMPCOrderNode(Properties ctx, int MPC_Order_Node_ID, String trxName) {\n\n super(ctx, MPC_Order_Node_ID, trxName);\n\n if (MPC_Order_Node_ID == 0) {\n\n // setMPC_Order_Node_ID (0);\n // setMPC_Order_Workflow_ID (0);\n // setValue (null);\n // setName (null);\n setAction(ACTION_WaitSleep);\n setCost(Env.ZERO);\n\n // setDuration (Env.ZERO);\n setEntityType(ENTITYTYPE_UserMaintained);\t\t// U\n setIsCentrallyMaintained(true);\t\t\t// Y\n setJoinElement(JOINELEMENT_XOR);\t\t\t// X\n setDurationLimit(0);\n setSplitElement(SPLITELEMENT_XOR);\t\t\t// X\n\n// setWaitingTime (0);\n setXPosition(0);\n setYPosition(0);\n setAD_Column_ID(0);\n setAD_WF_Responsible_ID(0);\n\n // setAD_Imagen_ID(0);\n setSubflowExecution(SUBFLOWEXECUTION_Synchronously);\n setDocAction(DOCACTION_None);\n setStartMode(STARTMODE_Manual);\n setFinishMode(FINISHMODE_Manual);\n\n // setDurationLimit(0);\n setPriority(0);\n\n // setDuration(Env.ZERO);\n // setWorkingTime(0);\n // fjv e-evolution\n setWaitingTime(0);\n\n // setWaitingTime(Env.ZERO);\n // end e-evolution\n }\n\n // Save to Cache\n if (getID() != 0) {\n s_cache.put(new Integer(getMPC_Order_Node_ID()), this);\n }\n\n }", "public AssessmentStudenttrainingworkflow() {\n this(\"assessment_studenttrainingworkflow\", null);\n }", "public WorkflowResource(String workid) {\r\n\t\tthis.workflowid = workid;\r\n\t\tthis.resources = new LinkedHashMap<String, List<String>>();\r\n\t}", "public ComponentNode(Hierarchy hierarchy) {\n super(null, true);\n this.hierarchy = hierarchy;\n map = new WeakHashMap();\n }", "protected DirectProductNodeModel() {\n\t\tsuper(2, 1);\n\t}", "@Override\n\tpublic IAlgoInstance createInstance(String id,\n\t\t\tIGenlabWorkflowInstance workflow) {\n\t\treturn null;\n\t}", "public Node (Object newItem) {\n next = null; // set intially to null\n item = newItem;\n }", "public static WMProcessDefinition fromWorkflowProcess(\r\n WorkflowProcess workflow )\r\n {\r\n return new WMProcessDefinitionImpl( workflow.getId(),\r\n workflow.getPackage().getId(), workflow.getName(),\r\n WMProcessDefinitionState.fromInt( workflow.getState() ) );\r\n }", "public Node() {\r\n\t\tthis.input = null;\r\n\t\tthis.inputWeights = null;\r\n\t}", "public Node() \r\n\t{\r\n\t\tincludedNode = new ArrayList<Node>();\r\n\t\tin = false; \r\n\t\tout = false;\r\n\t}", "public Workflow(int workFlowId, String name, int arrivalTime, double makespan, int deadline)\n\t{\n\t\tthis.workflowId = workFlowId;\n\t\tthis.workflowName = name;\n\t\tthis.arrivalTime = arrivalTime;\n\t\tthis.makespan = makespan;\n\t\tthis.deadline = deadline;\n\t\t\n\t\tthis.taskList = new ArrayList<WTask>(); \n\t\tthis.startedFlag = false;\n\t\tthis.finishTime = -1;\n\t\tthis.successfulOrNot = false;\n\t}", "private Workflow context(Action a) {\n\t\tString workflowClassName = param.workflowName;\n\t\t//Independent actions may be part of some other workflow, fill them in first.\n\t\tfor(Workflow w : workflows) {\n\t\t\tif(w.isSatisfiable(a)) {\n\t\t\t\treturn w;\n\t\t\t}\n\t\t}\n\t\t//The action do not satisfy any existing workflow. We check whether the action is independent.\n\t\t//If it is, we start a new workflow with head = this action.\n\t\ttry {\n\t\t\tClass workflowClass = Class.forName(workflowClassName);\n\t\t\tWorkflow w = (Workflow) workflowClass.newInstance();\n\t\t\tw.sys = this;\n\n\t\t\tif(w.isIndependentAction(a) && w.isSatisfiable(a)) {\n\t\t\t\tworkflows.add(w);\n\t\t\t\tSimLogger.log(Level.FINEST, \"New workflow created with action \" + a);\n\t\t\t\treturn w;\n\t\t\t}\n\t\t} catch(ClassNotFoundException e) {\n\t\t\tSimLogger.log(Level.SEVERE, \"Class not found for workflow class: \" + workflowClassName);\n\t\t\te.printStackTrace();\n\t\t} catch(InstantiationException e) {\n\t\t\tSimLogger.log(Level.SEVERE, \"Default Constructor not found for workflow class: \" + workflowClassName);\n\t\t\te.printStackTrace();\n\t\t} catch(IllegalAccessException e) {\n\t\t\tSimLogger.log(Level.SEVERE, \"Default Constructor not found for workflow class: \" + workflowClassName);\n\t\t\te.printStackTrace();\n\t\t}\n\n\t\tSimLogger.log(Level.FINE, \"No workflow can be found to satisify action \" + a +\n\t\t \". Action is execution is cancelled.\");\n\t\treturn null;\n\t}", "public TempWorkflow(String name)\n\t{\n\t\tthis.workflowName = name;\t\t\n\t\tthis.taskList = new ArrayList<TempWTask>(); //Initialize a list to record the set of tasks\n\t}", "public Mapping createInstance(Document xbrlDocument) {\n List<Document> docList = new ArrayList<>();\n docList.add(xbrlDocument);\n return createInstance(docList);\n }", "public BaselineTaskInstanceDto(BaselineTaskInstanceDto source) {\n if (source.Id != null) {\n this.Id = new Long(source.Id);\n }\n if (source.BaselineInstanceId != null) {\n this.BaselineInstanceId = new Long(source.BaselineInstanceId);\n }\n if (source.BaselineType != null) {\n this.BaselineType = new String(source.BaselineType);\n }\n if (source.BaselineDataTime != null) {\n this.BaselineDataTime = new String(source.BaselineDataTime);\n }\n if (source.UpstreamInstanceIds != null) {\n this.UpstreamInstanceIds = new String(source.UpstreamInstanceIds);\n }\n if (source.DownstreamInstanceIds != null) {\n this.DownstreamInstanceIds = new String(source.DownstreamInstanceIds);\n }\n if (source.IsPromiseTask != null) {\n this.IsPromiseTask = new Boolean(source.IsPromiseTask);\n }\n if (source.TaskId != null) {\n this.TaskId = new String(source.TaskId);\n }\n if (source.CurRunDate != null) {\n this.CurRunDate = new String(source.CurRunDate);\n }\n if (source.TaskName != null) {\n this.TaskName = new String(source.TaskName);\n }\n if (source.InCriticalPath != null) {\n this.InCriticalPath = new Long(source.InCriticalPath);\n }\n if (source.InFirstLevel != null) {\n this.InFirstLevel = new Boolean(source.InFirstLevel);\n }\n if (source.EstimatedCostTime != null) {\n this.EstimatedCostTime = new Long(source.EstimatedCostTime);\n }\n if (source.ActualCostTime != null) {\n this.ActualCostTime = new Long(source.ActualCostTime);\n }\n if (source.LatestStartTime != null) {\n this.LatestStartTime = new String(source.LatestStartTime);\n }\n if (source.ActualStartTime != null) {\n this.ActualStartTime = new String(source.ActualStartTime);\n }\n if (source.EstimatedEndTime != null) {\n this.EstimatedEndTime = new String(source.EstimatedEndTime);\n }\n if (source.LatestEndTime != null) {\n this.LatestEndTime = new String(source.LatestEndTime);\n }\n if (source.ActualEndTime != null) {\n this.ActualEndTime = new String(source.ActualEndTime);\n }\n if (source.TaskInstanceStatus != null) {\n this.TaskInstanceStatus = new String(source.TaskInstanceStatus);\n }\n if (source.ProjectId != null) {\n this.ProjectId = new String(source.ProjectId);\n }\n if (source.ShardKey != null) {\n this.ShardKey = new String(source.ShardKey);\n }\n if (source.CreateTime != null) {\n this.CreateTime = new String(source.CreateTime);\n }\n if (source.UpdateTime != null) {\n this.UpdateTime = new String(source.UpdateTime);\n }\n if (source.UserUin != null) {\n this.UserUin = new String(source.UserUin);\n }\n if (source.OwnerUin != null) {\n this.OwnerUin = new String(source.OwnerUin);\n }\n if (source.AppId != null) {\n this.AppId = new String(source.AppId);\n }\n }", "public SNode(object obj)\r\n {\r\n\t\r\n\toop=obj;\r\n }", "public Task(Task task) {\n id = task.id;\n taskType = task.taskType;\n title = task.title;\n period = task.period;\n deadline = task.deadline;\n wcet = task.wcet;\n //execTime = task.execTime;\n priority = task.priority;\n initialOffset = task.initialOffset;\n nextReleaseTime = task.nextReleaseTime;\n isSporadicTask = task.isSporadicTask;\n }", "public CommitNode(CommitNode parent, CommitNode toCopy) {\r\n\t\tparentCommit = parent;\r\n\t\t//ID to be set in Gitlet.java\r\n\t\tmessage = toCopy.message();\r\n\t\tdate = Calendar.getInstance().getTime();\r\n\t\ttrackedFiles = toCopy.trackedFiles();\r\n\t\tbranchesPartOf = toCopy.branches();\r\n\t\tchildren = toCopy.getChildren();\r\n\t}", "public Node(SimacogoBoard board) {\n nodeType = MAXNODE;\n bestScore = Integer.MIN_VALUE;\n limit = board.getAvailableSlotArray();\n parent = null;\n depth = 0;\n }", "public Node(Node node) {\n board = new int[BOARD_SIZE][BOARD_SIZE];\n for (int i = 0; i < node.board.length; i++) {\n board[i] = Arrays.copyOf(node.board[i], node.board[i].length);\n }\n if (node.move != null)\n this.move = new Move(node.move);\n this.turn = node.turn;\n this.phase2 = node.phase2;\n this.canRemove = node.canRemove;\n unplaced = node.unplaced;\n zobrist_key = node.zobrist_key;\n }", "InteractionFlowModel createInteractionFlowModel();", "public Branch() { }", "public ClassNode(OClass clas) {\n\t\tname = clas.getName();\n\t\tsource = clas;\n\t}", "void addWorkflow(Workflow workflow);", "public ModifyWorkflowScheduleRequest(ModifyWorkflowScheduleRequest source) {\n if (source.ProjectId != null) {\n this.ProjectId = new String(source.ProjectId);\n }\n if (source.WorkflowId != null) {\n this.WorkflowId = new String(source.WorkflowId);\n }\n if (source.DelayTime != null) {\n this.DelayTime = new Long(source.DelayTime);\n }\n if (source.StartupTime != null) {\n this.StartupTime = new Long(source.StartupTime);\n }\n if (source.SelfDepend != null) {\n this.SelfDepend = new Long(source.SelfDepend);\n }\n if (source.CycleType != null) {\n this.CycleType = new Long(source.CycleType);\n }\n if (source.CycleStep != null) {\n this.CycleStep = new Long(source.CycleStep);\n }\n if (source.StartTime != null) {\n this.StartTime = new String(source.StartTime);\n }\n if (source.EndTime != null) {\n this.EndTime = new String(source.EndTime);\n }\n if (source.TaskAction != null) {\n this.TaskAction = new String(source.TaskAction);\n }\n if (source.CrontabExpression != null) {\n this.CrontabExpression = new String(source.CrontabExpression);\n }\n if (source.ExecutionStartTime != null) {\n this.ExecutionStartTime = new String(source.ExecutionStartTime);\n }\n if (source.ExecutionEndTime != null) {\n this.ExecutionEndTime = new String(source.ExecutionEndTime);\n }\n if (source.DependencyWorkflow != null) {\n this.DependencyWorkflow = new String(source.DependencyWorkflow);\n }\n }", "public Node(Board board){\n children = new ArrayList<>();\n counter = 0;\n this.board = board;\n parent = null;\n }", "public CMObject newInstance();", "public Node(TNode tNode) {\n this.tNode = tNode;\n this.predecessor = null;\n initFingers();\n initSuccessorList();\n }", "public Workflow init() throws IOException, ReflectiveOperationException {\n List<UtteranceProcessor> processors = new ArrayList<>();\n for (UtteranceProcessorConfig upc : processorConfigs) {\n processors.add(upc.init());\n }\n \n List<IntentMatcher> matchers = new ArrayList<>();\n if (matcherConfigs.size() < 1) {\n matchers.add(IntentMatcherConfig.getDefault());\n } else {\n for (IntentMatcherConfig imc : matcherConfigs) {\n matchers.add(imc.init());\n }\n }\n \n List<IntentResolver> resolvers = new ArrayList<>();\n if (resolverConfigs.size() < 1) {\n resolvers.add(IntentResolverConfig.getDefault());\n } else {\n for (IntentResolverConfig irc : resolverConfigs) {\n resolvers.add(irc.init());\n }\n }\n \n List<PromptHandler> promptHandlers = new ArrayList<>();\n if (promptHandlerConfigs.size() < 1) {\n promptHandlers.add(PromptHandlerConfig.getDefault());\n } else {\n for (PromptHandlerConfig phc : promptHandlerConfigs) {\n promptHandlers.add(phc.init());\n }\n }\n return DefaultWorkflowFactory.get().createDefaultWorkflow(\n name, processors, matchers, resolvers, promptHandlers);\n }", "public Node(ActivationFunction f) {\n\t\tnodeActivationFunction = f;\n\t}", "@SuppressWarnings(\"unchecked\")\n\tpublic AnalysisGraph createNewInstance() {\n\t\tAnalysisGraph graph = new AnalysisGraph();\n\t\tgraph.currentIndex = currentIndex;\n\t\t\n\t\tgraph.nodes = (HashMap<String, Node>) nodes.clone();\n\t\tgraph.nodeList = (ArrayList<Node>)((ArrayList<Node>) nodeList).clone();\n\t\tgraph.links = (ArrayList<Link>)((ArrayList<Link>) links).clone();\n\t\treturn graph;\n\t}", "public Node() {\n this.nodeMap = new HashMap<>();\n }", "@Override\n protected T createInstance() throws Exception {\n return this.isSingleton() ? this.builder().build() : XMLObjectSupport.cloneXMLObject(this.builder().build());\n }", "public Task(Task task) {\r\n\t\tthis.id = task.id;\r\n\t\tthis.description = task.description;\r\n\t\tthis.processor = task.processor;\r\n\t\tthis.status = task.status;\r\n\r\n\t\tthis.dueDate = new GregorianCalendar(task.dueDate.get(GregorianCalendar.YEAR), \r\n\t\t\t\ttask.dueDate.get(GregorianCalendar.MONTH), \r\n\t\t\t\ttask.dueDate.get(GregorianCalendar.DAY_OF_MONTH));\r\n\r\n\t\tSimpleDateFormat sdf = new SimpleDateFormat(\"dd.MM.yyyy\");\r\n\t\tthis.formatedDueDate = sdf.format(dueDate.getTime());\r\n\t\tthis.next = task.next;\r\n\t}", "public Branch(String label, Node node) {\n super(label);\n\n if (node == null) {\n throw new InvalidParameterException(\"Cannot create branch with no node.\");\n }\n\n this.node = node;\n }", "public XmlAdaptedTask() {}", "public XmlAdaptedTask() {}", "public Cell(Cell original){\n this.i = original.i;\n this.j = original.j;\n this.type = original.type;\n if (original.entity != null) {\n if (original.entity instanceof Agent) {\n Agent agent = (Agent) original.entity;\n this.entity = new Agent(agent);\n }\n else if (original.entity instanceof Box) {\n Box box = (Box) original.entity;\n this.entity = new Box(box);\n }\n }\n else {\n this.entity = null;\n }\n this.goalLetter = original.goalLetter;\n }", "public QuestionPoolDataModel(Tree tree, DataModel model)\n {\n this.model = model;\n this.tree=tree;\n //buildTree();\n }", "public BoxNode() {\n initProperties();\n }", "public NodeConstraints createNodeConstraintsObject() {\n NodeConstraints c = new NodeConstraints(getClass().getCanonicalName(), getReturnTypes(), numChildren, NodeConstraints.ERC);\n Object[] args = getConstructorArgs();\n if (args != null) {\n c.setArgs(args);\n }\n return c;\n }", "@Override\n\tpublic Task constructInstance(Robot robot) {\n\t\treturn null;\n\t}", "public FlowMonMessage(){}", "public CloneNodeCommand() {\n// validator.configureTemplate().add(new StringToken(Commands.CLONE.getValue()))\n// .add(new StringToken()).add(new StringToken(\"from\"))\n// .add(new StringToken());\n validator.configureTemplate().add(new StringToken(Commands.CLONE.getValue()))\n .add(new MapListToken());\n }", "protected AST_Node() {\r\n\t}" ]
[ "0.65248513", "0.6093612", "0.5975738", "0.5936241", "0.5722351", "0.55876005", "0.5391978", "0.5276545", "0.5236174", "0.5186371", "0.5175215", "0.5172617", "0.514809", "0.5126293", "0.50885427", "0.507774", "0.505223", "0.505223", "0.505223", "0.505223", "0.5038715", "0.5017837", "0.5017837", "0.50159776", "0.4998359", "0.4998359", "0.49981958", "0.49801323", "0.4975992", "0.49704593", "0.49622", "0.49536455", "0.4944325", "0.49393222", "0.49369228", "0.4920657", "0.49178877", "0.4903772", "0.4891101", "0.48878738", "0.4887582", "0.48837635", "0.48818615", "0.4878792", "0.48728305", "0.48705956", "0.48685926", "0.4850486", "0.4846673", "0.48194608", "0.48140278", "0.48118436", "0.48034394", "0.47961226", "0.47958016", "0.47841933", "0.4776989", "0.4753775", "0.47527725", "0.4741519", "0.47387236", "0.47376445", "0.47371134", "0.47317007", "0.47259682", "0.4718988", "0.4717568", "0.47158784", "0.47093874", "0.47065195", "0.46967626", "0.46926248", "0.46909833", "0.4683653", "0.46773478", "0.46772", "0.46744537", "0.4673443", "0.4672585", "0.46691886", "0.4665142", "0.46587744", "0.4655405", "0.46531934", "0.4647073", "0.46403438", "0.46271735", "0.46195024", "0.46179408", "0.4617504", "0.46156698", "0.46156698", "0.46149883", "0.4608741", "0.46066546", "0.45987722", "0.4596584", "0.45929447", "0.457892", "0.45750043" ]
0.6712639
0
Gets the value of the name property
public String getName() { return name; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public String getName() {\n return (String) getValue(NAME);\n }", "PropertyName getName();", "public String getName(){\n\n //returns the value of the name field\n return this.name;\n }", "public String getName() {\n\t\treturn (String) get_Value(\"Name\");\n\t}", "public String getName() {\n\t\treturn (String) get_Value(\"Name\");\n\t}", "public String getName() {\n\t\treturn (String) get_Value(\"Name\");\n\t}", "@Override\n\tpublic String getValue() {\n\t\treturn name;\n\t}", "public String getName() { return name.get(); }", "public String getName() { return (String)get(\"Name\"); }", "public YangString getNameValue() throws JNCException {\n return (YangString)getValue(\"name\");\n }", "public YangString getNameValue() throws JNCException {\n return (YangString)getValue(\"name\");\n }", "public String getName() {\n return getProperty(Property.NAME);\n }", "public String getName() {\r\n\t\treturn name.get();\r\n\t}", "public String getName() {\n return name.get();\n }", "public AXValue getName() {\n return name;\n }", "public String getName() {\n return (String) mProperties.get(FIELD_NAME);\n }", "public String name() {\n return getString(FhirPropertyNames.PROPERTY_NAME);\n }", "@JsonProperty(PROP_NAME)\n @Nonnull\n public String getName() {\n return _name;\n }", "String getPropertyName();", "public java.lang.String getName() {\r\n return this._name;\r\n }", "public String get_name() {\r\n return name;\r\n }", "public java.lang.String getName() {\r\n return name;\r\n }", "public java.lang.String getName() {\r\n return name;\r\n }", "public java.lang.String getName() {\r\n return name;\r\n }", "public java.lang.String getName() {\r\n return name;\r\n }", "public java.lang.String getName() {\r\n return name;\r\n }", "public java.lang.String getName() {\r\n return name;\r\n }", "public String getName() {\r\n \treturn name;\r\n }", "public String getName()\r\n\t{\r\n\t\treturn name; // gives the value of the name to the caller\r\n\t}", "public String getname() {\n return name;\n }", "public String getName() { //declare public type, return type: String\r\n\t\treturn mName; //return mName value\r\n\t}", "@Override\n\tpublic String getName() {\n\t\treturn (String) attributes.get(\"name\");\n\t}", "public java.lang.String getName() {\n return this.name;\n }", "public Object getName() {\n\t\treturn this.name;\n\t}", "public Object getName() {\n\t\treturn this.name;\n\t}", "@gw.internal.gosu.parser.ExtendedProperty\n public java.lang.String getName() {\n return (java.lang.String)__getInternalInterface().getFieldValueForCodegen(NAME_PROP.get());\n }", "@Basic @Raw\r\n\tpublic String getName() {\r\n\t\treturn name;\r\n\t}", "public java.lang.String getName() {\n return name;\n }", "@gw.internal.gosu.parser.ExtendedProperty\n public java.lang.String getName() {\n return (java.lang.String)__getInternalInterface().getFieldValueForCodegen(NAME_PROP.get());\n }", "public\tString\tgetName() {\n\t\t\treturn\tthis.name;\n\t\t}", "public String GetName() {\n\t\treturn this.name;\n\t}", "public String name() {\n return myStrVal;\n }", "public String getName() {\r\n \t\t\treturn name;\r\n \t\t}", "public String getProperty(String name) {\n return this.getProperty(name, null);\n }", "public String get(final String name) {\r\n return (String) properties.get(name);\r\n }", "public String getName() {\n return (this.name);\n }", "public String getName() \n {\n \treturn name;\n }", "public String getName() {\r\n assert name != null;\r\n return name;\r\n }", "public java.lang.String getName() {\n return name;\n }", "public final String getName() {\n\treturn name.getName();\n }", "public java.lang.String getName() {\n return name;\n }", "public java.lang.String getName() {\n return name;\n }", "public java.lang.String getName() {\n return name;\n }", "public java.lang.String getName() {\n return name;\n }", "public java.lang.String getName() {\n return name;\n }", "public java.lang.String getName() {\n return name;\n }", "public java.lang.String getName() {\n return name;\n }", "public java.lang.String getName() {\n return name;\n }", "public java.lang.String getName() {\n return name;\n }", "public java.lang.String getName() {\n return name;\n }", "public java.lang.String getName() {\n return name;\n }", "@Override\n\tpublic String get_name() {\n\t\treturn name;\n\t}", "private String getName() {\n\t\treturn name;\n\t}", "public java.lang.String getName() {\n\treturn name;\n}", "public java.lang.String getName() {\n\treturn name;\n}", "public java.lang.String getName() {\n\treturn name;\n}", "public String getname() {\n\t\treturn name;\n\t}", "public java.lang.String getName()\n {\n return name;\n }", "public java.lang.String getName()\n {\n return name;\n }", "public String getName() { \n\t\treturn getNameElement().getValue();\n\t}", "public String getName() { \n\t\treturn getNameElement().getValue();\n\t}", "public String getName() { \n\t\treturn getNameElement().getValue();\n\t}", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();", "java.lang.String getName();" ]
[ "0.7922632", "0.7908402", "0.78744376", "0.78363454", "0.78363454", "0.78363454", "0.7829283", "0.78174627", "0.78057605", "0.7791134", "0.7791134", "0.7777322", "0.7761777", "0.7685398", "0.76415443", "0.7620194", "0.760026", "0.7559629", "0.75085604", "0.75006497", "0.7482794", "0.74569213", "0.74569213", "0.74569213", "0.74569213", "0.74569213", "0.74569213", "0.7451523", "0.74459916", "0.7443974", "0.7443487", "0.74416304", "0.74327075", "0.7429725", "0.7429725", "0.74248874", "0.7424862", "0.74213743", "0.741683", "0.74042624", "0.74019784", "0.73923135", "0.73887014", "0.73866385", "0.738655", "0.73855406", "0.7376942", "0.7375681", "0.7372128", "0.73715323", "0.7368923", "0.7368923", "0.7368923", "0.7368923", "0.7368923", "0.7368923", "0.7368923", "0.7368923", "0.7368923", "0.7368923", "0.73675656", "0.73605055", "0.7354265", "0.7354198", "0.7354198", "0.7354198", "0.7353367", "0.7344304", "0.7344304", "0.7343616", "0.7343616", "0.7343616", "0.73426914", "0.73426914", "0.73426914", "0.73426914", "0.73426914", "0.73426914", "0.73426914", "0.73426914", "0.73426914", "0.73426914", "0.73426914", "0.73426914", "0.73426914", "0.73426914", "0.73426914", "0.73426914", "0.73426914", "0.73426914", "0.73426914", "0.73426914", "0.73426914", "0.73426914", "0.73426914", "0.73426914", "0.73426914", "0.73426914", "0.73426914", "0.73426914", "0.73426914" ]
0.0
-1
Gets the value of the title property
public String getTitle() { return title; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public String getTitle() {\r\n\t\treturn (String) getProperty(\"title\");\t\r\n\t}", "public String getTitle() {\n return getProperty(Property.TITLE);\n }", "public java.lang.Object getTitle() {\n return title;\n }", "public String get(String title) {\n\t\treturn prop.getProperty(title);\n\t}", "public java.lang.String getTitle() {\n return title;\n }", "public java.lang.String getTitle() {\n return title;\n }", "public java.lang.String getTitle() {\n return title;\n }", "public java.lang.String getTitle() {\n return title;\n }", "public java.lang.String getTitle() {\n return title;\n }", "public String getTitle()\n {\n return (this.title);\n }", "public String getTitle() {\r\n return this.title;\r\n }", "public String getTitle()\r\n {\r\n return this.title;\r\n }", "public java.lang.String getTitle()\n {\n return this.title;\n }", "public String getTitle()\r\n {\r\n return title;\r\n }", "public String getTitle()\r\n {\r\n return title;\r\n }", "public String getTitle() {\r\n return title;\r\n }", "public String getTitle() {\r\n return title;\r\n }", "public String getTitle() {\r\n return title;\r\n }", "public String getTitle() {\r\n return title;\r\n }", "public String getTitle() {\r\n return title;\r\n }", "public String getTitle() {\r\n return title;\r\n }", "public String getTitle() {\r\n return title;\r\n }", "public String getTitle() {\r\n return title;\r\n }", "public String getTitle() \r\n\t{\r\n\t\treturn this.title;\r\n\t}", "public String getTitle()\r\n {\r\n return getSemanticObject().getProperty(swb_title);\r\n }", "public String getTitle() {\n return this.title;\n }", "public String getTitle() {\n return this.title;\n }", "public String getTitle() {\n return this.title;\n }", "public String getTitle() {\n return this.title;\n }", "public String getTitle() {\n return this.title;\n }", "public java.lang.String getTitle()\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(TITLE$2);\n if (target == null)\n {\n return null;\n }\n return target.getStringValue();\n }\n }", "public String getTitle()\n {\n return title;\n }", "private String getTitle() {\n return title;\n }", "public String getTitle() {\n\t\treturn this.title;\n\t}", "public String getTitle() {\n\t\treturn this.title;\n\t}", "public String getTitle() {\n\t\treturn this.title;\n\t}", "public String getTitle() {\n \t\treturn title;\n \t}", "public String getTitle() {\r\n\t\treturn title;\r\n\t}", "public String getTitle() {\r\n\t\treturn title;\r\n\t}", "public String getTitle() {\r\n\t\treturn title;\r\n\t}", "public String getTitle() {\r\n\t\treturn title;\r\n\t}", "public String getTitle() {\r\n\t\treturn title;\r\n\t}", "public String getTitle() {\r\n\t\treturn title;\r\n\t}", "public String getTitle() {\r\n\t\treturn title;\r\n\t}", "public String getTitle() {\n return this.title;\n }", "public String getTitle() {\r\n return _title;\r\n }", "public String getTitle() {\n return title;\n }", "public String getTitle() {\n return title;\n }", "public String getTitle() {\n return title;\n }", "public String getTitle() {\n return title;\n }", "public String getTitle() {\n return title;\n }", "public String getTitle() {\n return title;\n }", "public String getTitle() {\n return title;\n }", "public String getTitle() {\n return title;\n }", "public String getTitle() {\n return title;\n }", "public String getTitle() {\n return title;\n }", "public String getTitle() {\n return title;\n }", "public String getTitle() {\n return title;\n }", "public String getTitle() {\n return title;\n }", "public String getTitle() {\n return title;\n }", "public String getTitle() {\n return title;\n }", "public String getTitle() {\n return title;\n }", "public String getTitle() {\n return title;\n }", "public String getTitle() {\n return title;\n }", "public String getTitle() {\n return title;\n }", "public String getTitle() {\n return title;\n }", "public String getTitle() {\n return title;\n }", "public String getTitle() {\n return title;\n }", "public String getTitle() {\n return title;\n }", "public String getTitle() {\n return title;\n }", "public String getTitle() {\n return title;\n }", "public String getTitle() {\n return title;\n }", "public String getTitle() {\n return title;\n }", "public String getTitle() {\n return title;\n }", "public String getTitle() {\n return title;\n }", "public String getTitle() {\n return title;\n }", "public String getTitle() {\n return title;\n }", "public String getTitle() {\n return title;\n }", "public String getTitle() {\n return title;\n }", "public String getTitle() {\n return title;\n }", "public String getTitle() {\n return title;\n }", "public String getTitle() {\n return title;\n }", "public String getTitle() {\n return title;\n }", "public String getTitle() {\n return title;\n }", "public String getTitle() {\n return title;\n }", "public String getTitle() {\n return title;\n }", "public String getTitle() {\n return title;\n }", "public String getTitle() {\n return title;\n }", "public String getTitle() {\n return title;\n }", "public String getTitle() {\n return title;\n }", "public String getTitle() {\n return title;\n }", "public String getTitle() {\n return title;\n }", "public String getTitle() {\n return title;\n }", "public String getTitle() {\n return title;\n }", "public String getTitle() {\n return title;\n }", "public String getTitle() {\n return title;\n }", "public String getTitle() {\n return title;\n }", "public String getTitle() {\n return title;\n }", "public String getTitle() {\n return title;\n }", "public String getTitle() {\n return title;\n }", "public String getTitle() {\n return title;\n }" ]
[ "0.88091385", "0.8663215", "0.8641707", "0.85751545", "0.8547922", "0.85143226", "0.85143226", "0.85143226", "0.85081065", "0.84919906", "0.8459733", "0.8456798", "0.84458077", "0.84439266", "0.84439266", "0.8442832", "0.8442832", "0.8442832", "0.8442832", "0.8442832", "0.8442832", "0.8442832", "0.8420806", "0.84205604", "0.8415789", "0.8412528", "0.8412528", "0.8412528", "0.8412528", "0.8412528", "0.8410939", "0.84016925", "0.8395965", "0.8391129", "0.8391129", "0.8391129", "0.83903027", "0.83872724", "0.83872724", "0.83872724", "0.83872724", "0.83872724", "0.83872724", "0.83872724", "0.83848584", "0.8380441", "0.83742267", "0.83742267", "0.83725804", "0.83725804", "0.83725804", "0.83725804", "0.83725804", "0.83725804", "0.83725804", "0.83725804", "0.83725804", "0.83725804", "0.83725804", "0.83725804", "0.83725804", "0.83725804", "0.83725804", "0.83725804", "0.83725804", "0.83725804", "0.83725804", "0.83725804", "0.83725804", "0.83725804", "0.83725804", "0.83725804", "0.83725804", "0.83725804", "0.83725804", "0.83725804", "0.83725804", "0.83725804", "0.83725804", "0.83725804", "0.83725804", "0.83725804", "0.83725804", "0.83725804", "0.83725804", "0.83725804", "0.83725804", "0.83725804", "0.83725804", "0.83725804", "0.83725804", "0.83725804", "0.83725804", "0.83725804", "0.83725804", "0.83725804", "0.83725804", "0.83725804", "0.8370201", "0.8370201", "0.8370201" ]
0.0
-1
Gets the value of the description property
public String getDescription() { return description; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public String getDescription() {\n\t\treturn (String) get_Value(\"Description\");\n\t}", "public String getDescription() {\n\t\treturn (String) get_Value(\"Description\");\n\t}", "public String getDescription() {\n\t\treturn (String) get_Value(\"Description\");\n\t}", "public String getDescription() {\n\t\treturn (String) get_Value(\"Description\");\n\t}", "public String getDescription(){\n\n //returns the value of the description field\n return this.description;\n }", "public String getDescription() {\n return getProperty(Property.DESCRIPTION);\n }", "public java.lang.Object getDescription() {\n return description;\n }", "public java.lang.String getDescription(){\r\n return this.description;\r\n }", "public String getDescription(){\r\n \tString retVal = this.description;\r\n return retVal;\r\n }", "public java.lang.String getDescription() {\r\n return this._description;\r\n }", "public java.lang.String getDescription() {\r\n return this._description;\r\n }", "public String getDescription() {\n return getGenericFieldValue(\"Description\");\n }", "public String getDescription() {\r\n\t\treturn this.description;\r\n\t}", "public String getDescription() {\r\n\t\treturn this.description;\r\n\t}", "public String getDescription() {\r\n\t\treturn this.description;\r\n\t}", "public String getDescription() {\r\n\t\treturn this.description;\r\n\t}", "public String getDescription() {\r\n\t\treturn this.description;\r\n\t}", "public String getDescription() {\r\n return this.description;\r\n }", "public String getDescription() {\r\n return this.description;\r\n }", "@gw.internal.gosu.parser.ExtendedProperty\n public java.lang.String getDescription() {\n return (java.lang.String)__getInternalInterface().getFieldValueForCodegen(DESCRIPTION_PROP.get());\n }", "public String getDesc()\r\n {\r\n return description;\r\n }", "public String getDescription() {\n\t\treturn this.description;\n\t}", "public java.lang.String getDescription() {\n return this._description;\n }", "public String getDescription()\r\n {\r\n return this.aDescription ;\r\n }", "@Override\n\tpublic String getdescription() {\n\t\treturn this.description.getDesc();\n\t}", "public String getDescription()\n {\n return this.mDescription;\n }", "public String getDescription() {\n return this.description;\n }", "public String getDescription() {\n\n return this.description;\n }", "@gw.internal.gosu.parser.ExtendedProperty\n public java.lang.String getDescription() {\n return (java.lang.String)__getInternalInterface().getFieldValueForCodegen(DESCRIPTION_PROP.get());\n }", "public String getDescription() {\n return this.description;\n }", "public String getDescription() {\n return this.description;\n }", "public String getDescription() {\n return this.description;\n }", "public String getDescription() {\n return this.description;\n }", "public String getDescription() {\n return this.description;\n }", "public String getDescription() {\n return this.description;\n }", "public String getDescription() {\n return this.description;\n }", "public String getDescription() {\n return this.description;\n }", "public String getDescription() {\n return this.description;\n }", "public String getDescription() {\n return this.description;\n }", "public String getDescription() {\n return this.description;\n }", "public String getDescription() {\n return this.description;\n }", "public String getDescription() {\n return this.description;\n }", "public String getDescription() {\n return this.description;\n }", "public String getDescription() {\n return this.description;\n }", "public String getDescription() {\n return this.description;\n }", "public String getDescription() {\n return this.description;\n }", "public String getDescription() {\n return this.description;\n }", "public String getDescription() {\n return this.Description;\n }", "public java.lang.String getDescription() {\r\n return description;\r\n }", "public java.lang.String getDescription() {\r\n return description;\r\n }", "public java.lang.String getDescription() {\r\n return description;\r\n }", "public String getDescription() {\n return this.description;\n }", "public String getDescription() {\n return this.description;\n }", "public String getDescription() {\n return this.description;\n }", "public java.lang.String getDescription()\n {\n return this._description;\n }", "public String description() {\n return this.descr;\n }", "public String getDescription() {\r\n return _description;\r\n }", "@Nullable\n public String getDescription() {\n return this.description;\n }", "public String getDescription() {\n return this.description;\n }", "public String description() {\r\n\t\treturn this.description;\r\n\t}", "public String get_description() {\n return description;\n }", "public String getDescription() { \n\t\treturn getDescriptionElement().getValue();\n\t}", "public String getDescription() { \n\t\treturn getDescriptionElement().getValue();\n\t}", "public java.lang.String getDescription() {\n return description;\n }", "public String getDescription() {\r\n return description;\r\n }", "public String getDescription() {\r\n return description;\r\n }", "public String getDescription() {\r\n return description;\r\n }", "public String getDescription() {\r\n return description;\r\n }", "public String getDescription() {\r\n return description;\r\n }", "public String getDescription() {\r\n return description;\r\n }", "public String getDescription() {\r\n return description;\r\n }", "public String getDescription() {\r\n return description;\r\n }", "public String getDescription() {\r\n return description;\r\n }", "public String getDescription() {\r\n return description;\r\n }", "String getdescription() {\n\t\treturn description;\n\t}", "public String getDescription() {\n return _description;\n }", "public String getDescription() {\n return _description;\n }", "public String getDescription() {\r\n\t\treturn description;\r\n\t}", "public String getDescription() {\r\n\t\treturn description;\r\n\t}", "public String getDescription() {\r\n\t\treturn description;\r\n\t}", "public String getDescription() {\r\n\t\treturn description;\r\n\t}", "public String getDescription() {\r\n\t\treturn description;\r\n\t}", "public String getDescription() {\r\n\t\treturn description;\r\n\t}", "public String getDescription() {\r\n\t\treturn description;\r\n\t}", "public String getDescription() {\r\n\t\treturn description;\r\n\t}", "public String getDescription() {\n return (String)getAttributeInternal(DESCRIPTION);\n }", "public String getDescription() {\n return (String)getAttributeInternal(DESCRIPTION);\n }", "public String getDescription()\n {\n return this.description;\n }", "public String getDescription()\r\n\t{\treturn this.description;\t}", "public com.commercetools.api.models.common.LocalizedString getDescription() {\n return this.description;\n }", "public String getDescription()\r\n {\r\n return description;\r\n }", "public java.lang.String getDescription()\r\n {\r\n synchronized (monitor())\r\n {\r\n check_orphaned();\r\n org.apache.xmlbeans.SimpleValue target = null;\r\n target = (org.apache.xmlbeans.SimpleValue)get_store().find_attribute_user(DESCRIPTION$8);\r\n if (target == null)\r\n {\r\n return null;\r\n }\r\n return target.getStringValue();\r\n }\r\n }", "public java.lang.String getDescription() {\n return description;\n }", "public java.lang.String getDescription() {\n return description;\n }", "public java.lang.String getDescription() {\n return description;\n }", "public java.lang.String getDescription() {\n return description;\n }", "public java.lang.String getDescription() {\n return description;\n }", "public java.lang.String getDescription() {\n return description;\n }", "public java.lang.String getDescription() {\n return description;\n }", "public java.lang.String getDescription() {\n return description;\n }", "public java.lang.String getDescription() {\n return description;\n }" ]
[ "0.85231507", "0.85231507", "0.85231507", "0.85231507", "0.8500969", "0.8471982", "0.83464086", "0.83217204", "0.83088493", "0.828395", "0.828395", "0.8254358", "0.8246433", "0.8246433", "0.8246433", "0.8246433", "0.8246433", "0.8239126", "0.8239126", "0.8235883", "0.8225111", "0.82196087", "0.82145363", "0.82106465", "0.8210267", "0.8208066", "0.8207555", "0.8203381", "0.8199718", "0.8198108", "0.8198108", "0.8198108", "0.8198108", "0.8198108", "0.8198108", "0.8198108", "0.8198108", "0.8198108", "0.8198108", "0.8198108", "0.8198108", "0.8198108", "0.8198108", "0.8198108", "0.8198108", "0.8198108", "0.8198108", "0.8188837", "0.8164568", "0.8164568", "0.8164568", "0.81630594", "0.81630594", "0.81630594", "0.8158234", "0.8154826", "0.815368", "0.8151817", "0.81413645", "0.8130463", "0.8125595", "0.81248945", "0.81248945", "0.8122591", "0.8120487", "0.8120487", "0.8120487", "0.8120487", "0.8120487", "0.8120487", "0.8120487", "0.8120487", "0.8120487", "0.8120487", "0.8114921", "0.81145877", "0.81145877", "0.8106651", "0.8106651", "0.8106651", "0.8106651", "0.8106651", "0.8106651", "0.8106651", "0.8106651", "0.8098488", "0.8098488", "0.80960906", "0.8092056", "0.8086054", "0.8083056", "0.8080666", "0.8080074", "0.8080074", "0.8080074", "0.8080074", "0.8080074", "0.8080074", "0.8080074", "0.8080074", "0.8080074" ]
0.0
-1
Gets the value of the isTaskNode property
public boolean isTaskNode() { return isTaskNode; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "TaskNode getNode(Task task);", "@Override\r\n\tpublic boolean hasChildren() {\n\t\tif (taskNodeList != null)\r\n\t\t\treturn true;\r\n\t\telse\r\n\t\t\treturn false;\r\n\t}", "public boolean hasTaskId() {\n return fieldSetFlags()[9];\n }", "public boolean isNode() {\n return (kids != null);\n }", "public boolean hasTaskId() {\n return fieldSetFlags()[23];\n }", "public boolean isNodeProp() {\n \t\treturn isNodeProp;\n \t}", "public String getTask() {\n return task;\n }", "public String getTask() {\n return task;\n }", "boolean hasTask();", "public Node getNode() {\n return thread;\n }", "public ITask getTask() {\n \t\treturn task;\n \t}", "public String getNode() {\n return node;\n }", "boolean hasHasNodeID();", "public String getNode() {\n return node;\n }", "public TMNode getNode() {\n return node;\n }", "public String getNode()\n {\n return node;\n }", "public boolean getShowInTaskInfo() {\n return showInTaskInfo;\n }", "boolean hasNodeId();", "public Task getTask() {\n return task;\n }", "boolean hasIsNodeOf();", "boolean hasHasNodeSettings();", "public boolean hasTreeNodeId() {\n return treeNodeId_ != null;\n }", "public boolean getNodeVisited(){\r\n\t \treturn this.nodeVisited;\r\n\t }", "public boolean getUsedInTasks() {\n return usedInTasks;\n }", "public java.lang.String getTaskId() {\n return taskId;\n }", "public java.lang.String getTaskId() {\n return taskId;\n }", "public boolean isRealNode();", "public boolean isRealNode();", "public Task getTask() { return task; }", "public String getTaskId() {\n return taskId;\n }", "public String getTaskId() {\n return taskId;\n }", "public Boolean getPrimaryNode() {\n return primaryNode;\n }", "public String getTaskType() {\n return taskType;\n }", "public java.lang.String getTaskId() {\n return taskId;\n }", "public java.lang.String getTaskId() {\n return taskId;\n }", "boolean hasNode();", "boolean hasNode();", "public String getTaskName() {\n return taskName;\n }", "public String getTaskName() {\n return taskName;\n }", "public String getTaskName() {\n return taskName;\n }", "public String getTaskName() {\n return taskName;\n }", "public String getTaskId() {\n\t\treturn taskId;\n\t}", "public TaskType getTaskType() {\n return taskType;\n }", "public int getTaskType() {\n\t\treturn fieldTaskType;\n\t}", "public boolean getTreeNodeIdNull() {\n return treeNodeIdNull_;\n }", "public String taskName() {\n return this.taskName;\n }", "public boolean getTreeNodeIdNull() {\n return treeNodeIdNull_;\n }", "public boolean hasNode() {\n return nodeBuilder_ != null || node_ != null;\n }", "public boolean hasNode() {\n return nodeBuilder_ != null || node_ != null;\n }", "public String getTaskId() {\n return this.taskId;\n }", "public int getMaxTasksPerNode() {\n return maxTasksPerNode;\n }", "public String getTaskDefinition() {\n return this.taskDefinition;\n }", "public String getTaskDefinition() {\n return this.taskDefinition;\n }", "public String getTaskName(){\r\n\t\treturn this.taskName;\r\n\t}", "int getTask() {\n return task;\n }", "public String getTaskId(){\r\n\t\treturn this.taskId;\r\n\t}", "public java.lang.Object getTaskID() {\n return taskID;\n }", "public String getOrginTaskID() {\n\t\treturn orginTaskID;\n\t}", "public static String getNodeType() {\n\t\treturn NODE_TYPE;\n\t}", "public String getTaskType() { return \"?\"; }", "@java.lang.Override\n public boolean hasNode() {\n return node_ != null;\n }", "@java.lang.Override\n public boolean hasNode() {\n return node_ != null;\n }", "public String getTask(){\n\treturn task;\n}", "public Task getTaskInstance() {\n\t\treturn taskInstance;\n\t}", "public Integer getTaskId() {\n return taskId;\n }", "public Integer getTaskId() {\n return taskId;\n }", "public TaskName getTaskName() {\n return this.taskName;\n }", "public boolean hasTreeNodeId() {\n return treeNodeIdBuilder_ != null || treeNodeId_ != null;\n }", "@Override\n public String getTaskType() {\n return this.taskType;\n }", "public Boolean getShowNodes() {\n return showNodes;\n }", "public Node getNode() {\n return node;\n }", "public Node getNode() {\n return node;\n }", "public BPM getNode() {\n return BPMNode;\n }", "public Integer getTaskId() {\n\t\treturn this.taskId;\n\t}", "Object getTaskId();", "public int getTaskId() {\n return taskId;\n }", "public boolean get_task_completion()\n {\n return task_completion_boolean;\n }", "protected String getTaskId() {\n\t\tDisplay.debug(\"getTaskId() devuelve %s\", taskId);\n\t\treturn taskId;\n\t}", "public int getCustTask()\n\t{\n\t\treturn task;\n\t}", "public String getTaskName() {\n return this.taskDescription;\n }", "public String getType() {\n return theTaskType ;\n }", "boolean getTreeNodeIdNull();", "@Override\n\tpublic String getTaskElementName() {\n\t\treturn null;\n\t}", "public String getType() {\n return \"Task\";\n }", "public String getNode_pid() {\r\n\t\treturn node_pid;\r\n\t}", "public Boolean getShowNodeLabels() {\n return showNodeLabels;\n }", "@Override\n\tpublic String getTaskUrl() {\n\t\treturn URLMAP.get(MenuType.GA_READ.getNodeName());\n\t}", "public boolean hasSubTasks() {\n\t\treturn (getSubTasks() != null) && (getSubTasks().size() > 0);\n\t}", "String getTaskId();", "public boolean getSteady() {\n\t\treturn (getTaskType() == TASK_STEADY);\n\t}", "@Override\n public String getTaskType() {\n return \"T\";\n }", "public boolean getShowInTaskList(){\n Boolean show = getGeneralProperties().getBooleanAsObj(PROP_GET_SHOW_IN_TASK_LIST);\n if (show==null){\n return true;\n } else {\n return show.booleanValue();\n }\n }", "public TaskState getTaskState() {\n return this.taskState;\n }", "public String getName()\r\n {\r\n return taskName;\r\n }", "protected final boolean isRootNode() {\n return isRootNode;\n }", "public String getNode_id() {\r\n\t\treturn node_id;\r\n\t}", "public boolean isDAG() {\n return false;\n }", "public String getTaskName();", "public boolean getShowProjectSummaryTask()\r\n {\r\n return m_showProjectSummaryTask;\r\n }", "public String getTargetTaskID() {\n\t\treturn this.targetTaskId;\n\t}" ]
[ "0.68982625", "0.64285684", "0.6420674", "0.6416944", "0.63443327", "0.62286776", "0.61853987", "0.61853987", "0.61823577", "0.6138173", "0.6071749", "0.60600704", "0.6042756", "0.60195714", "0.6009996", "0.60070443", "0.5992387", "0.5979634", "0.5976709", "0.5976456", "0.59721583", "0.59192735", "0.5888117", "0.58804476", "0.58781666", "0.58781666", "0.5869639", "0.5869639", "0.5849644", "0.5826457", "0.5826457", "0.5824316", "0.5823479", "0.58168733", "0.58168733", "0.5816493", "0.5816493", "0.5809555", "0.5809555", "0.5809555", "0.5809555", "0.580449", "0.580213", "0.58019847", "0.57877785", "0.5773076", "0.57683194", "0.5764118", "0.5764118", "0.5754066", "0.57486737", "0.5735895", "0.5735895", "0.572963", "0.5726513", "0.57253504", "0.5717522", "0.57066935", "0.5697299", "0.56703186", "0.56672484", "0.56672484", "0.5665405", "0.56567115", "0.56554264", "0.56554264", "0.5653759", "0.5650969", "0.56468946", "0.5634452", "0.56290525", "0.56290525", "0.5619939", "0.5603838", "0.559633", "0.55953586", "0.55919814", "0.5581534", "0.5572534", "0.5569952", "0.5563542", "0.5550383", "0.5547996", "0.5547086", "0.5543784", "0.553537", "0.5531346", "0.5530838", "0.5527675", "0.55258864", "0.550637", "0.55055183", "0.5503985", "0.5488185", "0.54819196", "0.5466575", "0.54625714", "0.54614", "0.54580367", "0.5452361" ]
0.8842332
0
Gets the value of the transitions property
public Scriptable getTransitions() { Scriptable transitionsScriptable = (Scriptable)new ValueConverter().convertValueForScript( this.serviceRegistry, this.scope, null, this.transitions); return transitionsScriptable; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public double getTransition(){\n\t\treturn transition;\n\t}", "public int getNombreTransitions()\n {\n return nombreTransitions;\n }", "@Override\n public double getTransitionValue() {\n return value.doubleValue();\n }", "@Override\n\tpublic synchronized Collection<Transition> getTransitions() {\n\t\treturn this.transitions;\n\t}", "public List<Transition> getInTransitions() {\r\n\t\treturn inTransitions;\r\n\t}", "public TransitionElements getTransitionAccess() {\r\n\t\treturn pTransition;\r\n\t}", "@ApiModelProperty(value = \"The transitions that can be performed on the issue.\")\n public List<IssueTransition> getTransitions() {\n return transitions;\n }", "public int getTotalTransitions() {\n\t\t\treturn mTotalTransitions;\n\t\t}", "public float getTimeInTransitions() {\n\t\t\treturn (float) ((long) getTotalTransitions() * (long) getTransitionLatency() / 1E9);\n\t\t}", "public long[][] getTransitionIds() {\n\t\treturn this.transitionIds;\n\t}", "public String getTransitionStyle() {\n\t\treturn transitionStyle;\n\t}", "public MMPCOrderNodeNext[] getTransitions() {\n\n MMPCOrderNodeNext[]\tretValue\t= new MMPCOrderNodeNext[m_next.size()];\n\n m_next.toArray(retValue);\n\n return retValue;\n\n }", "public List<Transition> getOutTransitions() {\r\n\t\treturn outTransitions;\r\n\t}", "public StateTransition getStateTransition() {\n\t\treturn (sb);\n\t}", "public Map<Action, String> transitionMessages() {\n return transitionMessages;\n }", "public String getTransition(int subsystem) {\n return _avTable.get(ATTR_TRANSITION, subsystem);\n }", "public List<Transition> getSelfTransitions() {\r\n\t\treturn selfTransitions;\r\n\t}", "protected TransitionFunction transitionFunction() {\n\t\treturn (TransitionFunction) this.transitions;\n\t}", "public UserScript getTransitionScript() {\n\t\treturn this.transitionScript;\n\t}", "String convertTransition(Transition instanceValue);", "public int getPropertyFade()\n {\n return iPropertyFade.getValue();\n }", "public int getTransitionSize() {\n return _transitionSize;\n }", "public int[][] getTransitionMatrix() {\n\t\treturn null;\n\t}", "public boolean isTransition() {\n/* 4839 */ return this.isTransition;\n/* */ }", "public native final Transition transition()/*-{\n\t\treturn this.transition();\n\t}-*/;", "public Transition getCurrentTransition () {\n return ttb.getCurrentTransition();\n }", "public Iterable<Transition> getTransitions() {\n return new TransitionsIterable();\n }", "public TransitionDependencyElements getTransitionDependencyAccess() {\r\n\t\treturn pTransitionDependency;\r\n\t}", "public int getPropertyFade();", "protected Class<? extends edu.duke.cs.jflap.automata.Transition> getTransitionClass() {\n\t\treturn edu.duke.cs.jflap.automata.Transition.class;\n\t}", "public int getBacktrackedTransitionCount() {\n return ttb.getBacksteppedTransitions();\n }", "@Nullable\n public ExitTransition getExitTransition() {\n if (mImpl.hasExitTransition()) {\n return ExitTransition.fromProto(mImpl.getExitTransition());\n } else {\n return null;\n }\n }", "public IRTransitionColl getEnabledTransitions()\n throws OculusException;", "public Boolean getAnimate () {\r\n\t\treturn (Boolean) getStateHelper().eval(PropertyKeys.animate);\r\n\t}", "public String getIsmtransitionCurrentstateName() {\n\t\treturn ismtransitionCurrentstateName;\n\t}", "public BGMTransition getEffect()\n\t{\n\t\treturn effect;\n\t}", "@Nullable\n public FadeOutTransition getFadeOut() {\n if (mImpl.hasFadeOut()) {\n return FadeOutTransition.fromProto(mImpl.getFadeOut());\n } else {\n return null;\n }\n }", "@Nullable\n public FadeInTransition getFadeIn() {\n if (mImpl.hasFadeIn()) {\n return FadeInTransition.fromProto(mImpl.getFadeIn());\n } else {\n return null;\n }\n }", "public String getIsmtransitionCurrentstateCode() {\n\t\treturn ismtransitionCurrentstateCode;\n\t}", "public int getTransitionLatency() {\n\t\t\tif (mTransitionLatency == 0) {\n\t\t\t\tList<String> list = ShellHelper.cat(\n\t\t\t\t\tmRoot.getAbsolutePath() + TRANSITION_LATENCY);\n\t\t\t\tif (list == null || list.isEmpty()) return 0;\n\t\t\t\tint value = 0;\n\t\t\t\ttry { value = Integer.valueOf(list.get(0)); }\n\t\t\t\tcatch (NumberFormatException ignored) {}\n\t\t\t\tmTransitionLatency = value;\t\t\t\n\t\t\t}\n\t\t\treturn mTransitionLatency;\n\t\t}", "public List<NextStateInfo> getTransitions(String state) {\r\n \t\treturn transitions.get(state).getNextStateInfo();\r\n \t}", "public String getIsmtransitionCareflowstepName() {\n\t\treturn ismtransitionCareflowstepName;\n\t}", "public String getIsmtransitionCareflowstepCode() {\n\t\treturn ismtransitionCareflowstepCode;\n\t}", "ReadOnlyObjectProperty<VitalModel.State> modelStateTransitionConditionProperty();", "public TransitionIterator transitionIterator () {\n\t\t\treturn transitionIterator (null, 0, null, 0);\n\t\t}", "int getStateValue();", "int getStateValue();", "int getStateValue();", "@Override\n public StochasticTransitionFeature getFeatureTransition() {\n return StochasticTransitionFeature.newDeterministicInstance(value,weight);\n }", "public double getTargetValue(StateTransition nextStateTransition) {\n return nextStateTransition.tdTarget;\n }", "public int getTransitionConstraint(Scope<?> scope, StateModelDefId stateModelDefId,\n Transition transition) {\n // set up attributes to match based on the scope\n ClusterConstraints transitionConstraints =\n getConstraintMap().get(ConstraintType.MESSAGE_CONSTRAINT);\n Map<ConstraintAttribute, String> matchAttributes = Maps.newHashMap();\n matchAttributes.put(ConstraintAttribute.STATE_MODEL, stateModelDefId.toString());\n matchAttributes.put(ConstraintAttribute.MESSAGE_TYPE, MessageType.STATE_TRANSITION.toString());\n matchAttributes.put(ConstraintAttribute.TRANSITION, transition.toString());\n switch (scope.getType()) {\n case CLUSTER:\n // cluster is implicit\n break;\n case RESOURCE:\n matchAttributes.put(ConstraintAttribute.RESOURCE, scope.getScopedId().stringify());\n break;\n case PARTICIPANT:\n matchAttributes.put(ConstraintAttribute.INSTANCE, scope.getScopedId().stringify());\n break;\n default:\n LOG.error(\"Unsupported scope for transition constraints: \" + scope);\n return Integer.MAX_VALUE;\n }\n Set<ConstraintItem> matches = transitionConstraints.match(matchAttributes);\n int value = Integer.MAX_VALUE;\n for (ConstraintItem item : matches) {\n String constraintValue = item.getConstraintValue();\n if (constraintValue != null) {\n try {\n int current = Integer.parseInt(constraintValue);\n if (current < value) {\n value = current;\n }\n } catch (NumberFormatException e) {\n LOG.error(\"Invalid in-flight transition cap: \" + constraintValue);\n }\n }\n }\n return value;\n }", "public LinkedList<Pair<String, State>> getTrans() {\n return trans;\n }", "public TreeSet<StateTransition> getSampledStateTransitions() {\n return getFunctionEstimator().getSampledStateTransitions();\n }", "public long getAnimDuration() {\n return (long) (Settings.Global.getFloat(this.mContext.getContentResolver(), \"transition_animation_scale\", this.mContext.getResources().getFloat(17105053)) * 336.0f);\n }", "public long getPropertyFadeMax();", "public ScreenshotController.TransitionDestination takeTransitionDestinationCallback() {\n return mTransitionDestinationCallback.getAndSet(null);\n }", "public long getPropertyFadeMax()\n {\n return iPropertyFadeMax.getValue();\n }", "final public int getAnimationDuration()\n {\n return ComponentUtils.resolveInteger(getProperty(ANIMATION_DURATION_KEY), 1000);\n }", "@Nullable\n public SlideOutTransition getSlideOut() {\n if (mImpl.hasSlideOut()) {\n return SlideOutTransition.fromProto(mImpl.getSlideOut());\n } else {\n return null;\n }\n }", "int getStateValue3();", "Transition createTransition();", "Transition createTransition();", "@RestrictTo(Scope.LIBRARY_GROUP)\n @NonNull\n public ModifiersProto.FadeInTransition toProto() {\n return mImpl;\n }", "public SimpleStringProperty durationProperty(){\r\n\t\treturn duration;\r\n\t}", "@RestrictTo(Scope.LIBRARY_GROUP)\n @NonNull\n public ModifiersProto.FadeOutTransition toProto() {\n return mImpl;\n }", "int getStateValue2();", "TransitionType createTransitionType();", "public int getAnimation() {\n\t\t\treturn animation;\n\t\t}", "@objid (\"5fbc4043-71c3-4fa2-8c35-72372f15ccb1\")\n EList<Transition> getSends();", "public String describeTransition (double cutoff) { return \"\"; }", "public States transition(Alphabet sym) {\n return transitions.get(new Pair<>(currentState, sym));\n }", "public Color getNodeFadeDestinationColor() {\n return (_nodeFadeDestinationColor);\n }", "public Float getValue () {\r\n\t\treturn (Float) getStateHelper().eval(PropertyKeys.value);\r\n\t}", "public final EObject ruleTransitionRoot() throws RecognitionException {\r\n EObject current = null;\r\n\r\n Token otherlv_0=null;\r\n EObject lv_def_1_0 = null;\r\n\r\n\r\n enterRule(); \r\n \r\n try {\r\n // ../org.yakindu.sct.model.stext/src-gen/org/yakindu/sct/model/stext/parser/antlr/internal/InternalSText.g:255:28: ( (otherlv_0= '@@transition@@' ( (lv_def_1_0= ruleTransitionSpecification ) ) ) )\r\n // ../org.yakindu.sct.model.stext/src-gen/org/yakindu/sct/model/stext/parser/antlr/internal/InternalSText.g:256:1: (otherlv_0= '@@transition@@' ( (lv_def_1_0= ruleTransitionSpecification ) ) )\r\n {\r\n // ../org.yakindu.sct.model.stext/src-gen/org/yakindu/sct/model/stext/parser/antlr/internal/InternalSText.g:256:1: (otherlv_0= '@@transition@@' ( (lv_def_1_0= ruleTransitionSpecification ) ) )\r\n // ../org.yakindu.sct.model.stext/src-gen/org/yakindu/sct/model/stext/parser/antlr/internal/InternalSText.g:256:3: otherlv_0= '@@transition@@' ( (lv_def_1_0= ruleTransitionSpecification ) )\r\n {\r\n otherlv_0=(Token)match(input,16,FOLLOW_16_in_ruleTransitionRoot567); if (state.failed) return current;\r\n if ( state.backtracking==0 ) {\r\n\r\n \tnewLeafNode(otherlv_0, grammarAccess.getTransitionRootAccess().getTransitionKeyword_0());\r\n \r\n }\r\n // ../org.yakindu.sct.model.stext/src-gen/org/yakindu/sct/model/stext/parser/antlr/internal/InternalSText.g:260:1: ( (lv_def_1_0= ruleTransitionSpecification ) )\r\n // ../org.yakindu.sct.model.stext/src-gen/org/yakindu/sct/model/stext/parser/antlr/internal/InternalSText.g:261:1: (lv_def_1_0= ruleTransitionSpecification )\r\n {\r\n // ../org.yakindu.sct.model.stext/src-gen/org/yakindu/sct/model/stext/parser/antlr/internal/InternalSText.g:261:1: (lv_def_1_0= ruleTransitionSpecification )\r\n // ../org.yakindu.sct.model.stext/src-gen/org/yakindu/sct/model/stext/parser/antlr/internal/InternalSText.g:262:3: lv_def_1_0= ruleTransitionSpecification\r\n {\r\n if ( state.backtracking==0 ) {\r\n \r\n \t newCompositeNode(grammarAccess.getTransitionRootAccess().getDefTransitionSpecificationParserRuleCall_1_0()); \r\n \t \r\n }\r\n pushFollow(FOLLOW_ruleTransitionSpecification_in_ruleTransitionRoot588);\r\n lv_def_1_0=ruleTransitionSpecification();\r\n\r\n state._fsp--;\r\n if (state.failed) return current;\r\n if ( state.backtracking==0 ) {\r\n\r\n \t if (current==null) {\r\n \t current = createModelElementForParent(grammarAccess.getTransitionRootRule());\r\n \t }\r\n \t\tset(\r\n \t\t\tcurrent, \r\n \t\t\t\"def\",\r\n \t\tlv_def_1_0, \r\n \t\t\"TransitionSpecification\");\r\n \t afterParserOrEnumRuleCall();\r\n \t \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 if ( state.backtracking==0 ) {\r\n leaveRule(); \r\n }\r\n }\r\n \r\n catch (RecognitionException re) { \r\n recover(input,re); \r\n appendSkippedTokens();\r\n } \r\n finally {\r\n }\r\n return current;\r\n }", "public abstract Etat transition();", "public State step(int c) {\n assert c >= 0;\n for (int i=0;i<numTransitions;i++) {\n final Transition t = transitionsArray[i];\n if (t.min <= c && c <= t.max) return t.to;\n }\n return null;\n }", "public int getStates() {\n return states;\n }", "public synchronized RegionState\n getRegionTransitionState(final String regionName) {\n return regionsInTransition.get(regionName);\n }", "@Test\n public void stateTransitionsTest() throws ApiException {\n Long loanId = null;\n PostSelfLoansLoanIdRequest body = null;\n String command = null;\n PostSelfLoansLoanIdResponse response = api.stateTransitions(loanId, body, command);\n\n // TODO: test validations\n }", "public static java.util.Comparator getIS_SAME_TRANSITION() {\n if (org.xms.g.utils.GlobalEnvSetting.isHms()) {\n org.xms.g.utils.XmsLog.d(\"XMSRouter\", \"com.huawei.hms.location.ActivityConversionRequest.IS_EQUAL_CONVERSION\");\n return com.huawei.hms.location.ActivityConversionRequest.IS_EQUAL_CONVERSION;\n } else {\n org.xms.g.utils.XmsLog.d(\"XMSRouter\", \"com.google.android.gms.location.ActivityTransitionRequest.IS_SAME_TRANSITION\");\n return com.google.android.gms.location.ActivityTransitionRequest.IS_SAME_TRANSITION;\n }\n }", "@Nullable\n public EnterTransition getEnterTransition() {\n if (mImpl.hasEnterTransition()) {\n return EnterTransition.fromProto(mImpl.getEnterTransition());\n } else {\n return null;\n }\n }", "public boolean getAnimated() {\r\n return animated.get();\r\n }", "public int getFadeLevel() {\r\n\t\treturn fadeLevel;\r\n\t}", "public int getDuration() {\n return animationDuration;\n }", "public boolean getShowAnimation()\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(SHOWANIMATION$20);\n if (target == null)\n {\n target = (org.apache.xmlbeans.SimpleValue)get_default_attribute_value(SHOWANIMATION$20);\n }\n if (target == null)\n {\n return false;\n }\n return target.getBooleanValue();\n }\n }", "Animation getAnimation() {\n return currAnimation;\n }", "public long getPropertyCurrentAction()\n {\n return iPropertyCurrentAction.getValue();\n }", "public void setTransition(final String transition) {\n\t\tthis.transition = transition;\n\t}", "public static AnimationModeTransition obtainAnimationModeTransition() {\n\t\treturn animationModeTransitionPool.obtain();\n\t}", "public void setTransition(String value, int subsystem) {\n _avTable.set(ATTR_TRANSITION, value, subsystem);\n }", "@java.lang.Override public int getStateValue() {\n return state_;\n }", "public String getTransitionModesString() {\r\n\t\tString s = \"\";\r\n\t\tfor (TransitionMode mode : transitionModes) {\r\n\t\t\ts = s.concat(mode.getName() + \"; \");\r\n\t\t}\r\n\t\treturn s;\r\n\t}", "@java.lang.Override public int getStateValue() {\n return state_;\n }", "public double getAnimationSeconds()\n\t{\n\t\treturn seconds_passed;\n\t}", "public int getBackward() {\n return this.backward;\n }", "int getMove3Value();", "public int getFadeLength() {\r\n\t\treturn fadeLength;\r\n\t}", "int getStateValue1();", "public java.lang.Integer getDuracion() {\n return duracion;\n }", "public Set<Transition> getGridSectionDataAsTransitionSet(String sectionName) {\r\n\t\tListGridRecord[] records = super.getGridData(sectionName);\r\n\t\tif (records != null) {\r\n\t\t\tSet<Transition> transitions = new HashSet<Transition>();\r\n\t\t\tfor (ListGridRecord r : records) {\r\n\t\t\t\tTransitionRecord record = (TransitionRecord) r;\r\n\t\t\t\tTransition trans = record.getTransition();\r\n\t\t\t\tif (trans != null) {\r\n\t\t\t\t\ttransitions.add(trans);\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\treturn transitions;\r\n\t\t}\r\n\r\n\t\treturn null;\r\n\t}" ]
[ "0.7721865", "0.7175959", "0.7100796", "0.6943869", "0.69011796", "0.6842781", "0.6528409", "0.6514374", "0.64033765", "0.63613105", "0.6347248", "0.6338081", "0.63311946", "0.63236886", "0.6299215", "0.6295501", "0.6240029", "0.6197193", "0.6193282", "0.6191869", "0.6183769", "0.61639714", "0.6155768", "0.6138616", "0.6086692", "0.60584635", "0.600636", "0.58116376", "0.5791362", "0.5735675", "0.55713886", "0.55378634", "0.5515379", "0.5476444", "0.54729205", "0.54580164", "0.54560024", "0.54482824", "0.53592175", "0.5323734", "0.5321271", "0.52761096", "0.5262363", "0.52498233", "0.5222497", "0.52074045", "0.52074045", "0.52074045", "0.51425195", "0.5139104", "0.5134237", "0.5111458", "0.5096039", "0.5095315", "0.5082311", "0.505552", "0.5043974", "0.5000599", "0.49980313", "0.4972223", "0.49490085", "0.49490085", "0.49460852", "0.49455673", "0.48956084", "0.48928675", "0.488561", "0.48840612", "0.4865917", "0.48631588", "0.4861838", "0.48614773", "0.48589998", "0.48475093", "0.48435003", "0.48280776", "0.48260552", "0.48153272", "0.48125383", "0.48092335", "0.48082292", "0.48064137", "0.47971028", "0.47714525", "0.47682095", "0.47672984", "0.47670358", "0.47651884", "0.47648814", "0.476343", "0.47568774", "0.47416016", "0.47408783", "0.47356096", "0.4732495", "0.47245976", "0.47188815", "0.47186697", "0.47181663", "0.47148076" ]
0.6544141
6
TODO Autogenerated method stub
@Override public double fiyatlandir() { return 7.95; }
{ "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
/ Converts a direction in degrees (0...360) to x and y coordinates. The length of this vector is the second parameter
public static Point2D directionToVector(double directionInDegrees, double length) { double directionInRadians = directionInDegrees / 180 * Math.PI; Point2D heading = new Point2D(length * Math.sin(directionInRadians), - length * Math.cos(directionInRadians)); return heading; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public double direction(){\n return Math.atan2(this.y, this.x);\n }", "public void pointToXY(int x, int y) {\n PVector targetVector;\n targetVector = new PVector(x, y);\n direction = (p.degrees(p.atan2(pos.x - (targetVector.x), pos.y - (targetVector.y))))+90;\n if (direction < 0) direction += 360;\n }", "void turnToDir(float angle) { \n float radian = radians(angle);\n _rotVector.set(cos(radian), sin(radian));\n _rotVector.setMag(1);\n }", "public void getDirection (float xDir, float yDir){\n this.xDir = xDir;\n this.yDir = yDir;\n }", "private Point extractVectorFromAngle(int arg) {\n double theta = Math.toRadians( 2* (double)arg );\n double dx = Cell.move_dist * Math.cos(theta);\n double dy = Cell.move_dist * Math.sin(theta);\n return new Point(dx, dy);\n }", "public double getXDirection() {\r\n return Math.cos(Math.toRadians(angle));\r\n }", "public Vector getDirection(){\n\t\treturn new Vector(_direction);\n\t}", "float getDir() {\n return degrees(_rotVector.heading());\n }", "public static int vectorAngle(int x, int y) {\n return (Math.round((float)Math.toDegrees(Math.atan2(x, y))));\n }", "public Vector3fc dir(float x, float y, Vector3f dir) {\n float y1x = nxnyX + (nxpyX - nxnyX) * y;\n float y1y = nxnyY + (nxpyY - nxnyY) * y;\n float y1z = nxnyZ + (nxpyZ - nxnyZ) * y;\n float y2x = pxnyX + (pxpyX - pxnyX) * y;\n float y2y = pxnyY + (pxpyY - pxnyY) * y;\n float y2z = pxnyZ + (pxpyZ - pxnyZ) * y;\n float dx = y1x + (y2x - y1x) * x;\n float dy = y1y + (y2y - y1y) * x;\n float dz = y1z + (y2z - y1z) * x;\n // normalize the vector\n float invLen = Math.invsqrt(dx * dx + dy * dy + dz * dz);\n dir.x = dx * invLen;\n dir.y = dy * invLen;\n dir.z = dz * invLen;\n return dir;\n }", "@Generated\n @Selector(\"direction\")\n @ByValue\n public native CGVector direction();", "double direction (IPoint other);", "public position convertToPosition(){\n\t\tdouble x = r * Math.cos(theta);\n\t\tdouble y = r * Math.sin(theta);\n\t\treturn new position(x, y);\n\t}", "private void setDirection() {\n directionX = corePos.getX() - projectile.getX();\n directionY = corePos.getY() - projectile.getY();\n\n double length = Math.sqrt(directionX*directionX + directionY*directionY);\n\n if (length != 0) {\n directionX = directionX/length;\n directionY = directionY/length;\n }\n }", "public Vector2D(double angle)\n\t{\n\t\tx = Math.cos(Math.toRadians(angle));\n\t\ty = Math.sin(Math.toRadians(angle));\n\t}", "default Vector3 getDirection() {\r\n return Vector3.fromXYZ(getDirX(), getDirY(), getDirZ());\r\n }", "public abstract Vector3 directionFrom(Point3 point);", "public double toAngle()\n\t{\n\t\treturn Math.toDegrees(Math.atan2(y, x));\n\t}", "public double getYDirection() {\r\n return Math.sin(Math.toRadians(angle));\r\n }", "public void setDirection(Vector direction){\n\t\t_direction = direction;\n\t}", "public double theta() { return Math.atan2(y, x); }", "public float getDirection();", "public Velocity changeDirection(double x, double y) {\n if (Double.isNaN(x) || x == 0) {\n x = 1;\n }\n if (Double.isNaN(y) || y == 0) {\n y = 1;\n }\n return new Velocity(this.dx * Math.signum(x), this.dy * Math.signum(y));\n }", "public void pointAt(int x, int y){\n int dx=x-this.x;\n int dy=y-this.y;\n if(dx!=0)\n dir=Math.atan(((double)(dy))/((dx)))/ratioDegRad;\n else if(dy>0){\n dir=0;\n }\n else if (dy<0)\n dir=180;\n if(dx<0) {\n dir=(dir+180)%360;\n }\n\n }", "public Direction(int degrees)\n {\n dirInDegrees = degrees % FULL_CIRCLE;\n if ( dirInDegrees < 0 )\n dirInDegrees += FULL_CIRCLE;\n }", "@Override\n public Vector getFacingVector() {\n double[] rotation = {Math.cos(this.rot), Math.sin(this.rot)};\n Vector v = new Vector(rotation);\n v = VectorUtil.direction(v);\n Vector w = VectorUtil.direction(this.getR());\n v.plus(w);\n return v;\n }", "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}", "private float reverseDirection(float dir) {\n if (dir < Math.PI) return (float) (dir+Math.PI);\n else return (float) (dir-Math.PI);\n }", "public int[] direction(Node from, Node to) {\n int dx = to.getX() - from.getX();\n int dy = to.getY() - from.getY();\n int[] direction = {0, 0};\n \n if (dx != 0) {\n direction[0] = dx/Math.abs(dx);\n }\n \n if (dy != 0) {\n direction[1] = dy/Math.abs(dy);\n }\n \n return direction;\n }", "public static int vectorAngle(Point p) {\n \treturn (Math.round((float)Math.toDegrees(Math.atan2(p.x, p.y))));\n\t}", "public Direction()\n {\n dirInDegrees = 0; // default to North\n }", "public double getOrientation()\r\n\t{\r\n\t\treturn Math.atan2(-end.getY()+start.getY(), end.getX()-start.getX());\r\n\t}", "public double translateAngle( Figure f, double angle, double dir);", "public Direction reverse()\n {\n return new Direction(dirInDegrees + (FULL_CIRCLE / 2));\n }", "public int inDegrees()\n {\n return dirInDegrees;\n }", "public void faceDirection(Vector direction) {\n \tVector originalFaceDirection = new Vector(0,0,-1);\n \t\n \tfloat angle;\n \t\n \tif (direction.size() == 0)\n \t\tangle = 0;\n \telse\n \t\tangle = (float)Math.toDegrees( direction.angleBetween(originalFaceDirection) );\n \t\n \tVector orientation = player.getOrientation();\n \tplayer.setOrientation( angle , orientation.y(), orientation.z());\n }", "public double getAngleXY() {\r\n\t\tdouble l = this.lenght();\r\n\t\tif (l==0)\r\n\t\t\treturn 0;\r\n\t\treturn Math.asin(this.z/l);\r\n\t}", "public void setDir(Vector2 dirVec) {\n this.dirVec = dirVec;\n // Travelling horizontally\n if (dirVec.x == 0) {\n setAngle(Math.PI);\n }\n else {\n setAngle(Math.PI/2);\n }\n }", "public void setDirection(float directionDegree);", "public double angle() {\n return Math.atan2(_y,_x);\n }", "public Vector2D toVector2D ( );", "private void calculateMovement() {\r\n \tmovementY = (int)(movementSpeed * Math.sin(Math.toRadians(movementDirection - 90)));\r\n \tmovementX = (int)(movementSpeed * Math.cos(Math.toRadians(movementDirection - 90)));\r\n }", "private static int yCor(final int len, final double dir) {return (int)(len * Math.cos(dir));}", "public Vector2D toPolar()\n {\n return new Vector2D(Math.sqrt(this.x * this.x + this.y * this.y), Math.atan2(this.y, this.x));\n }", "public double\nangleInXYPlane()\n{\n\tBVector2d transPt = new BVector2d(\n\t\tthis.getP2().getX() - this.getP1().getX(),\n\t\tthis.getP2().getY() - this.getP1().getY());\n\t\n\t// debug(\"transPt: \" + transPt);\n\n\tdouble angle = MathDefines.RadToDeg * new Vector2d(1.0, 0.0).angle(transPt);\n\tif (transPt.getY() < 0.0)\n\t{\n\t\t// debug(\"ang0: \" + (360.0 - angle));\n\t\treturn(360.0 - angle);\n\t}\n\t// debug(\"ang1: \" + angle);\n\treturn(angle);\n}", "private PVector angleAsVector(float theta) {\n\t\tPVector result = new PVector(0,0);\r\n\t\tresult.x = (float) Math.cos(theta);\r\n\t\tresult.y = (float) Math.sin(theta);\r\n\t\treturn result;\r\n\t}", "public double betweenAngle(Coordinates vectorA, Coordinates vectorB);", "public static float AngleOfVectorInDegrees(final Vector vector) {\n return degrees(AngleOfVector(vector));\n }", "public double getDirectionFace();", "@NotNull\n @Override\n public OctilinearDirection toOctilinear() {\n Direction direction;\n double diff = angle % 45;\n if (diff < 45 / 2) {\n direction = fromAngle(angle - diff);\n }\n else {\n direction = fromAngle(angle + (45 - diff));\n }\n return direction.toOctilinear();\n }", "public void setDirection(int dir) {\n if((dir % 10) == 0 && dir <=350 && dir >=0) {\n this.directionDegree = dir; \n } else {\n throw new IllegalArgumentException(\"Direction \" + dir +\" is not valid. Directions must be between 0/350 in multiples of 10\"); \n }\n }", "public double getStartAngle();", "public Coordinate checkDirection(Direction direction){\r\n\t\treturn new Coordinate(x + direction.getX(), y + direction.getY());\r\n\t}", "private float calculateAngle() {\r\n\r\n\t\tdouble angleTemp = Math.atan2(Target.getY() - y, Target.getX() - x);\r\n\t\t// I needed to use wikipedia to get this i\r\n\t\t// did not learn this in math and needed\r\n\t\t// to use a couplle youtube tutorials to\r\n\t\t// find out how to do the math in java\r\n\t\t// aswell thank fully one had the exact\r\n\t\t// way of doing this\r\n\t\treturn (float) Math.toDegrees(angleTemp) + 90;\r\n\t}", "public PositionRadians(double v) {\n\t\tvalue = v;\n\t}", "public Vector3f getDirection() {\r\n\t\treturn new Vector3f(mDirection);\r\n\t}", "public static PVector toServos( PVector in ){\n\t\tfloat x = in.x * 180;\n\t\tfloat y = in.y * 180;\n\t\treturn new PVector( x, y );\n\t}", "public double betweenAngle(Coordinates a, Coordinates b, Coordinates origin);", "public void orientation(Double ...coords);", "public ForgeDirection toForgeDirection()\n {\n for (ForgeDirection direction : ForgeDirection.VALID_DIRECTIONS)\n {\n if (this.x == direction.offsetX && this.y == direction.offsetY && this.z == direction.offsetZ)\n {\n return direction;\n }\n }\n\n return ForgeDirection.UNKNOWN;\n }", "@Override\n\tpublic Vector2 angleToVector(Vector2 outVector, float angle) {\n\t\treturn Constants.angleToVector(outVector, angle);\n\t}", "public float getAngle() {\n if(vectorAngle < 0 )\n return (float) Math.toDegrees(Math.atan(longComponent / latComponent));\n else\n return vectorAngle;\n\n }", "public Direction getDirection(float x1, float y1, float x2, float y2){\n double angle = getAngle(x1, y1, x2, y2);\n return Direction.fromAngle(angle);\n }", "private void lookAt(double x, double y) {\n\t\t// http://www.gamefromscratch.com/post/2012/11/18/GameDev-math-recipes-Rotating-to-face-a-point.aspx\n\t\tdesiredDirection = Math.atan2(y - sens.getYPos(), x - sens.getXPos()) * (180 / Math.PI);\n\t\tfixDirections();\n\t}", "public static float AngleOfVector(final Vector vector) {\n return atan2(vector.x, vector.y);\n }", "public double angleTo(Point point){\n \treturn facingVector.angleDegrees(vectorTo(point));\n }", "private void rotate(int direction){\n\t\t//Gdx.app.debug(TAG, \"rotating, this.x: \" + this.x + \", this.y: \" + this.y);\n\t\tif (direction == 1 || direction == -1){\n\t\t\tthis.orientation = (this.orientation + (direction*-1) + 4) % 4;\n\t\t\t//this.orientation = (this.orientation + direction) % 4;\n\t\t} else{\n\t\t\tthrow new RuntimeException(\"Tile invalid direction\");\n\t\t}\n\t}", "public static void setDirection(float x, float y) {\n PlayerDirectionSystem.directionX = x;\r\n PlayerDirectionSystem.directionY = y;\r\n }", "private Vector3f calculateVectorDirectionBetweenEyeAndCenter() {\n\t\tVector3f br = new Vector3f();\n\n\t\tbr.x = player.getPosition().x - camera.getPosition().x;\n\t\tbr.y = player.getPosition().y - camera.getPosition().y;\n\t\tbr.z = player.getPosition().z - camera.getPosition().z;\n\n\t\treturn br;\n\t}", "@Override\n\tpublic float vectorToAngle(Vector2 vector) {\n\t\treturn Constants.vectorToAngle(vector);\n\t}", "int getDirection();", "void turnToPoint(float x, float y) {\n _rotVector.set(x - _x, y - _y, 0);\n _rotVector.setMag(1);\n }", "public Direction toRight()\n {\n return new Direction(dirInDegrees + (FULL_CIRCLE / 4));\n }", "public Vector3d getDirection() { return mDirection; }", "public static Vector VectorRotate2D(final Vector vector, final float angle) {\n float dx = vector.x, dy = vector.y;\n float c = cos(angle), s = sin(angle);\n\n return new Vector((dx * c) - (dy * s),\n (dx * s) + (dy * c),\n vector.z);\n }", "public static int computeDir(Point dronePos, Point desPos) {\r\n\t\tvar droneLat = dronePos.latitude();\r\n\t\tvar droneLon = dronePos.longitude();\r\n\t\tvar desLat = desPos.latitude();\r\n\t\tvar desLon = desPos.longitude();\r\n\t\tvar angleInRad = Math.atan2(droneLat-desLat, droneLon-desLon) + Math.PI;\r\n\t\tvar angle = Math.toDegrees(angleInRad);\r\n\t\tif(multipleOfTen(angle)==false && withinDirRange(angle)== true) {\r\n\t\t\tangle= angle - (angle%10); //equivalent to rounding down the angle to the nearest 10\r\n\t\t}\r\n\t\telse if (multipleOfTen(angle)==true && withinDirRange(angle) == false) {\r\n\t\t\tif(Math.abs(angle)>350) {\r\n\t\t\t\tangle = (angle%360); //converts angle to be between -360 and 360\r\n\t\t\t}\r\n\t\t\tif(angle<0) {\r\n\t\t\t\tangle = 360 + angle; //converts negative angle into its equivalent positive angle\r\n\t\t\t}\r\n\t\t}\r\n\t\telse if(validDir(angle) == false) {\r\n\t\t\tif(Math.abs(angle)>350) {\r\n\t\t\t\tangle = (angle%360); \r\n\t\t\t}\r\n\t\t\tif(angle<0) {\r\n\t\t\t\tangle = 360 + angle; \r\n\t\t\t}\r\n\t\t\tangle = angle - (angle%10);\r\n\r\n\t\t}\r\n\t\treturn (int) angle;\r\n\t}", "public double angle()\n {\n return Math.atan2(this.y, this.x);\n }", "public double getDirectionView();", "public Coordinates unitVector(Coordinates vector, Coordinates origin);", "protected static double[] rotateVector(double x, double y, double angle) {\r\n\t\tdouble cosA = Math.cos(angle * (3.14159 / 180.0));\r\n\t\tdouble sinA = Math.sin(angle * (3.14159 / 180.0));\r\n\t\tdouble[] out = new double[2];\r\n\t\tout[0] = x * cosA - y * sinA;\r\n\t\tout[1] = x * sinA + y * cosA;\r\n\t\treturn out;\r\n\t}", "public double angleToSide1(double x,double y)\n\t{\n\t\tif(x1==x)\n\t\t{\t\n\t\t\t//Then either the angle is 90 or 270\n\t\t\tif(y1>y)\n\t\t\t\treturn Math.PI/2;\n\t\t\telse\n\t\t\t\treturn 3*Math.PI/2;\n\t\t}\n\t\t\n\t\t\n\t\tdouble slope = (y1-y)/(x1-x);\n\t\tdouble angle = Math.atan(slope);\n\t\t\n\t\tif(x1<x)\n\t\t{\n\t\t\t//Then we have to change the angle\n\t\t\t//since it is on the left side of the x axis\n\t\t\treturn angle+Math.PI;\t\n\t\t}\n\t\telse\n\t\t{\n\t\t\tif(angle>=0)\n\t\t\t\treturn angle;\n\t\t\treturn angle+2*Math.PI;\n\t\t}\n\t\t\n\t}", "public float getDirection()\r\n {\r\n return direction;\r\n }", "private static float getComponentInAxis(Vector3f vector, Vector3f direction)\n\t{\n\t\treturn Vector3f.dot(vector, direction) / vector.length();\n\t}", "double getAngle();", "double getAngle();", "public void setDirection(int dir)\r\n\t{\r\n\t\tdirection = dir;\r\n\t}", "Point rotate (double angle);", "public static double degreeToRadians(double num) { return (num*0.0174533); }", "private Vector(double x, double y) {\n\t\tthis.x = x;\n\t\tthis.y = y;\n\t\tmagnitude = Math.sqrt(x * x + y * y);\n\t\tangle = Math.toDegrees(Math.atan2(y, x));\n\t}", "Angle createAngle();", "public Position(double degrees, GeoOrientation o){\n this.degrees = degrees;\n orientation = o;\n }", "public Coordinates unitVector(Coordinates vector);", "public double angleToSide2(double x,double y)\n\t{\n\t\tif(x2==x)\n\t\t{\t\n\t\t\t//Then either the angle is 90 or 270\n\t\t\tif(y2>y)\n\t\t\t\treturn Math.PI/2;\n\t\t\telse\n\t\t\t\treturn 3*Math.PI/2;\n\t\t}\n\t\t\n\t\t\n\t\tdouble slope = (y2-y)/(x2-x);\n\t\tdouble angle = Math.atan(slope);\n\t\t\n\t\tif(x2<x)\n\t\t{\n\t\t\t//Then we have to change the angle\n\t\t\t//since it is on the left side of the x axis\n\t\t\treturn angle+Math.PI;\t\n\t\t}\n\t\telse\n\t\t{\n\t\t\tif(angle>=0)\n\t\t\t\treturn angle;\n\t\t\treturn angle+2*Math.PI;\n\t\t}\n\t}", "private static double convertBearingTo360(double dBearing){\n\t\t\n\t\t//dOut = output\n\t\t\n\t\tdouble dOut;\n\t\t\n\t\tdOut = dBearing;\n\t\t\n\t\twhile(dOut>360){\n\t\t\tdOut=dOut-360.;\n\t\t}\n\t\twhile(dOut<0){\n\t\t\tdOut=dOut+360.;\n\t\t}\n\t\t\n\t\treturn dOut;\n\t}", "private Point translatePoint(Point start, double angle, double distance) {\n\t\tif (distance==0)\n\t\t\treturn start;\n\t\tangle = angle*0.0174532778; //Convert to radians = pi/180\n\t\tPoint p = new Point(start.x+distance*Math.sin(angle), start.y-distance*Math.cos(angle) );\n\t\treturn p;\n\t}", "private Point2D getEndPoint(int angle, int length, Point2D startingPoint) {\n int startingX = startingPoint.getX();\n int startingY = startingPoint.getY();\n double aRadian = Math.toRadians(angle);\n\n return new CursorPoint ((int)Math.round((startingX + length * Math.cos(aRadian))),\n (int)Math.round((startingY + length * Math.sin(aRadian))));\n\n }", "public double getAngle();", "public int getDirection();", "public static float rad2deg(float rad) {return rad/D2R;}", "public final Vector3f getDirection() {\r\n return direction;\r\n }" ]
[ "0.6655147", "0.64097416", "0.6287844", "0.62279123", "0.6188382", "0.5980375", "0.5947708", "0.5909932", "0.58972806", "0.58952296", "0.5890471", "0.5791171", "0.5780265", "0.5752293", "0.5744832", "0.5739751", "0.5715899", "0.5708068", "0.5675446", "0.5590805", "0.5559294", "0.5546037", "0.5543117", "0.5525551", "0.55211437", "0.5477365", "0.54703414", "0.5465707", "0.54471344", "0.5430066", "0.53870386", "0.53809756", "0.5374388", "0.5373578", "0.537238", "0.5365594", "0.5359087", "0.5340146", "0.53340566", "0.5310807", "0.5310647", "0.53091305", "0.53022945", "0.52963394", "0.52946883", "0.52941126", "0.52896065", "0.52812755", "0.52702945", "0.52617466", "0.5255823", "0.52547914", "0.52517325", "0.5240395", "0.5240145", "0.5238688", "0.5219748", "0.521363", "0.5206206", "0.51944536", "0.5189553", "0.5187056", "0.51759666", "0.5171429", "0.5171035", "0.5169736", "0.51629007", "0.515459", "0.515436", "0.51436496", "0.5137296", "0.51309097", "0.51247764", "0.51193875", "0.5106241", "0.5100366", "0.5094035", "0.5086456", "0.50850564", "0.50824004", "0.5072765", "0.50696385", "0.50654465", "0.5063782", "0.5063782", "0.50631005", "0.5059332", "0.5056283", "0.50551045", "0.50466466", "0.5045309", "0.50438064", "0.50434333", "0.50378495", "0.5025168", "0.5013995", "0.5011651", "0.5011192", "0.49948356", "0.4993049" ]
0.6758707
0
Adds blinking animation to Text the node
public static void animateBlinkingTextNode(Text text, String content) { text.setText(content); text.setFont(Font.font ("Verdana", 20)); text.setFill(Color.WHITE); FadeTransition fadeTransition = new FadeTransition(Duration.seconds(1.1), text); fadeTransition.setFromValue(1.0); fadeTransition.setToValue(0.0); fadeTransition.setCycleCount(Animation.INDEFINITE); fadeTransition.play(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private void blink() {\r\n\r\n\t\t_timer = new Timer(50, new TimerListener());\r\n\t\t_timer.start();\r\n\r\n\r\n\t}", "public void setBlinkTime(float blinkTime)\n\t{ this.BLINK_TIME = blinkTime; }", "public String blink() {\n if (this.styledValueElements instanceof BlinkOffText) {\n this.styledValueElements = new ShiftedText(this.styledValue);\n } else {\n this.styledValueElements = new BlinkOffText(this.styledValue);\n }\n\n this.value = this.styledValueElements.stringify();\n return this.value;\n }", "@Override\n public void run() {\n Animation fadeIn = new AlphaAnimation(0, 1);\n fadeIn.setInterpolator(new LinearInterpolator());\n fadeIn.setDuration(1500);\n txtArrays[i].setAnimation(fadeIn);\n txtArrays[i].setText(texts[i]);\n txtArrays[i].setTypeface(G.mitra);\n txtArrays[i].setTextSize(TypedValue.COMPLEX_UNIT_DIP,17);\n }", "public abstract void setBlinking(boolean status);", "private void setTvSplashTextDesapiarAnimator() {\n ValueAnimator valueAnimator = ValueAnimator.ofFloat(0f, 1f);\n valueAnimator.setDuration(2500);\n valueAnimator.addUpdateListener(new ValueAnimator.AnimatorUpdateListener() {\n @Override\n public void onAnimationUpdate(ValueAnimator animation) {\n float alpha = (float) animation.getAnimatedValue();\n tvSplashDesc.setAlpha(alpha);\n tvSplashTitle.setAlpha(alpha);\n }\n });\n valueAnimator.start();\n }", "public void update(){\n y -= 1; // Making the text float up\n // Making the text more transparent\n color = new Color(color.getRed(), color.getGreen(), color.getBlue(), color.getAlpha() - 2);\n }", "public void run() {\n if (color != blinkColor && delay > 1) {\n delay--;\n blink(blinkColor);\n } else {\n blink(color);\n if (color != blinkColor) {\n color = blinkColor;\n }\n }\n }", "@Override\n public void onClick(View v) {\n Animation animation1 = AnimationUtils.loadAnimation(getApplicationContext(),\n R.anim.blink);\n tsTripsheetsLayout.startAnimation(animation1);\n\n }", "private void highlightText(Text text){\r\n\t text.changeColor(AnimalScript.COLORCHANGE_COLOR, Color.RED, new TicksTiming(0), new TicksTiming(0));\r\n\t }", "@Override\n public void onClick(View v) {\n\n\n txtAndroid.animate().scaleX(0.2f).scaleY(0.4f).setDuration(3000);\n }", "public void run() {\n mTextView.setTranslationY(-mTextView.getHeight());\n mTextView.animate().setDuration(duration / 2).translationY(0).alpha(1)\n .setInterpolator(sDecelerator);\n }", "@Override\n public void onAnimationEnd(Animation animation) {\n if (animation == animBlink) {\n }\n\n }", "private void colorFoundNode(String s, double x, double y, double delay) {\n Text nn = new Text(x + 18 - s.length(), y + 30, s);\n nn.setFill(Color.WHITE);\n nn.setFont(Font.font(\"Verdana\", FontWeight.EXTRA_BOLD, 14));\n\n Rectangle rect = new Rectangle(x, y, 50, 50); // Draw a node\n rect.setFill(Color.rgb(140, 211, 255));\n rect.setStroke(Color.rgb( 245, 245, 245));\n rect.setArcHeight(15); rect.setArcWidth(20);\n\n //adding the created box to tree's node\n this.getChildren().addAll(rect, nn);\n\n // make fill transition ...this makes node change its colors when it is traversed on\n FillTransition fill = new FillTransition();\n\n\n //Setting auto reverse value to false //The transition will set to be auto reserved by setting this to true\n //Simply it is done so that colour does not turn back to blue.\n fill.setAutoReverse(true);\n\n //setting cycle count for the fill transition\n //making it 1 cause we don't want it ot change again back to blue\n fill.setCycleCount(1);\n //setting the time to be taken for transition\n fill.setDelay(Duration.seconds(delay));\n fill.setDuration(Duration.seconds(.5));\n\n //setting the first colour\n fill.setFromValue(Color.rgb(140, 211, 255));\n //setting the final colour\n fill.setToValue(Color.rgb(255, 206, 10));\n\n //adding the fill \"characteristic\" to rectangular box created before\n fill.setShape(rect);\n\n //starting the transition\n fill.play();\n }", "void setNewFrameText(Motion m);", "private void blink(final boolean lit){\n \n if(mRobot != null){\n \n //If not lit, send command to show blue light, or else, send command to show no light\n if(lit){\n RGBLEDOutputCommand.sendCommand(mRobot, 0, 0, 0);\n }else{\n RGBLEDOutputCommand.sendCommand(mRobot, 0, 0, 255);\n }\n \n //Send delayed message on a handler to run blink again\n final Handler handler = new Handler();\n handler.postDelayed(new Runnable() {\n public void run() {\n blink(!lit);\n }\n }, 1000);\n }\n }", "private void blink(final boolean lit) {\n\t\tif (mRobot == null) {\n\t\t\tblinking = false;\n\t\t\treturn;\n\t\t}\n\n\t\t// If not lit, send command to show blue light, or else, send command to\n\t\t// show no light\n\t\tif (lit) {\n\t\t\tmRobot.setColor(0, 0, 0);\n\n\t\t} else {\n\t\t\tmRobot.setColor(0, 255, 0);\n\t\t}\n\n\t\tif (blinking) {\n\t\t\t// Send delayed message on a handler to run blink again\n\t\t\tfinal Handler handler = new Handler();\n\t\t\thandler.postDelayed(new Runnable() {\n\t\t\t\tpublic void run() {\n\t\t\t\t\tblink(!lit);\n\t\t\t\t}\n\t\t\t}, 2000);\n\t\t}\n\t}", "public void act() \n {\n GreenfootImage img = new GreenfootImage(200,200); \n img.setFont(new Font(font, false, true,28));\n img.setColor(color);\n img.drawString(text,50,50);\n setImage(img);\n blink();\n //blink(); \n //if(Greenfoot.mouseClicked(this))\n \n }", "private void unhighlightText(Text text){\r\n\t text.changeColor(AnimalScript.COLORCHANGE_COLOR, Color.BLACK, new TicksTiming(0), new TicksTiming(0));\r\n\r\n\t }", "public void makeCursorBlink() {\n final Timeline timeline = new Timeline();\n // The rectangle should continue blinking forever.\n timeline.setCycleCount(Timeline.INDEFINITE);\n Cursor.CursorBlinkEventHandler cursorChange = new Cursor.CursorBlinkEventHandler();\n KeyFrame keyFrame = new KeyFrame(Duration.seconds(0.5), cursorChange);\n timeline.getKeyFrames().add(keyFrame);\n timeline.play();\n }", "public void setBlinking(boolean status) {\r\n statusIndicator.setBlinking(status);\r\n }", "@Override\n\t public void onAnimationEnd(Animation animation) {\n\t\t findViewById(R.id.textView8).setVisibility(View.GONE);\n\t\t findViewById(R.id.textView81).setVisibility(View.GONE);\n\t \tfindViewById(R.id.textView9).setVisibility(View.GONE);\n\t \tfindViewById(R.id.textView10).setVisibility(View.GONE);\t \t\n\t \tfindViewById(R.id.textView11).startAnimation(animb);\n\t }", "public void anim() {\n // start the timer\n t.start();\n }", "public float getBlinkTime()\n\t{ return BLINK_TIME; }", "public void blink(){\r\n boolean p = false;\r\n for (int i=1; i<=5; i++){\r\n buzzer(p); \r\n p = !p;\r\n try {\r\n Thread.sleep(500);\r\n } catch (InterruptedException ex) {\r\n ex.printStackTrace();\r\n }\r\n }\r\n }", "public void animateButtons ()\r\n\t{\r\n\t\tGraphics g = getGraphics ();\r\n\t\t\r\n\t\tif (display == true){\r\n\t\t\tdelay (1000);\r\n\t\t\tdisplayCode(g);\r\n\t\t}\r\n\t\telse if (display == false){\r\n\t\t\thandleAction(g);\r\n\t\t}\r\n\t}", "public void blink(double frequency) {\n timer = new Timer((int) Math.round(1000 / frequency));\n if (timer.timeout()) {\n this.status = !this.status;\n if (status)\n update(this.redValue, this.greenValue, this.blueValue);\n else\n update(0,0,0);\n }\n }", "public abstract void animation(double seconds);", "private void draw_text() {\n\t\tcopy_text_into_buffer();\n\t\tVoteVisApp.instance().image(text_buffer_, frame_height_ / 2,\n\t\t\t-text_graphics_.height / 2);\n\t}", "public void animate()\n\t{\n\t\tanimation.read();\n\t}", "protected abstract void animate(int anim);", "@Override\n public void animate() {\n }", "public void add1UpText(Pane root) throws FileNotFoundException {\n\t\toneUp=new Text(level.columnX(2),level.rowX(-2)+10,\"1UP\");\n\t\toneUp.setFill(Color.WHITE);\n\t\toneUp.setFont(Font.loadFont(\"file:recources\\\\Font\\\\PressStart2P-Regular.ttf\", 20));\t\t\n\t\tif(Level.getHieght()==720)\n\t\t\toneUp.setFont(Font.loadFont(\"file:recources\\\\Font\\\\PressStart2P-Regular.ttf\", 10));\n\t\troot.getChildren().add(oneUp);\n\t\tanimator = new AnimationTimer(){\n @Override\n public void handle(long arg0) {\n \tt+=0.08;\n \t\tif(t>1) \n \t\t\toneUp.setVisible(false);\n \t\tif(t>3) {\n \t\t\toneUp.setVisible(true);\n \t\t\tt=0;\n \t\t}\n } \n\t\t };\n\t\t animator.start(); \n\t}", "void fadeIn(boolean animation);", "private void setNotificationAnimation(String labelText, Color color) {\n\t\tif(sequentialTransition.getStatus() != Status.RUNNING) {\n\t\t\tnotificationLabel.setText(labelText);\n\t\t\tnotificationLabel.setTextFill(color);\n\n\t\t\tFadeTransition fadeInTransition = new FadeTransition(Duration.seconds(1.5));\n\t\t\tfadeInTransition.setFromValue(0);\n\t\t\tfadeInTransition.setToValue(1);\n\n\t\t\tPauseTransition pauseTransition = new PauseTransition(Duration.seconds(5));\n\n\t\t\tFadeTransition fadeOutTransition = new FadeTransition(Duration.seconds(1.5));\n\t\t\tfadeOutTransition.setFromValue(1);\n\t\t\tfadeOutTransition.setToValue(0);\n\n\t\t\tsequentialTransition = new SequentialTransition(notificationLabel, fadeInTransition, pauseTransition, fadeOutTransition);\n\t\t\tsequentialTransition.setCycleCount(1);\n\t\t\tsequentialTransition.playFromStart();\n\t\t} // End if statement\n\t\telse {\n\t\t\tsequentialTransition.stop();\n\n\t\t\tnotificationLabel.setText(labelText);\n\t\t\tnotificationLabel.setTextFill(color);\n\n\t\t\tFadeTransition fadeInTransition = new FadeTransition(Duration.seconds(1.5));\n\t\t\tfadeInTransition.setFromValue(0);\n\t\t\tfadeInTransition.setToValue(1);\n\n\t\t\tPauseTransition pauseTransition = new PauseTransition(Duration.seconds(5));\n\n\t\t\tFadeTransition fadeOutTransition = new FadeTransition(Duration.seconds(1.5));\n\t\t\tfadeOutTransition.setFromValue(1);\n\t\t\tfadeOutTransition.setToValue(0);\n\n\t\t\tsequentialTransition = new SequentialTransition(notificationLabel, fadeInTransition, pauseTransition, fadeOutTransition);\n\t\t\tsequentialTransition.setCycleCount(1);\n\t\t\tsequentialTransition.playFromStart();\n\t\t} // End else statement \n\t}", "public void addText(String text){\n try{\n FXMLLoader battleLogEntryLoader = new FXMLLoader(getClass().getClassLoader().getResource(\"FXML/BattleLogEntry.fxml\"));\n Label battleLogEntryLabel = battleLogEntryLoader.load();\n battleLogEntryLabel.setText(text);\n if(count % 2 == 0){\n battleLogEntryLabel.setBackground(new Background(new BackgroundFill(Color.LIGHTGRAY, CornerRadii.EMPTY, Insets.EMPTY)));\n } else{\n battleLogEntryLabel.setBackground(new Background(new BackgroundFill(Color.TRANSPARENT, CornerRadii.EMPTY, Insets.EMPTY)));\n }\n textSpace.getChildren().add(battleLogEntryLabel);\n count++;\n } catch(Exception e) {\n\n }\n }", "public void setTextSettings(){\n\n ArrayList<Text> headlines = new ArrayList<>();\n //Add any text element here\n //headlines.add(this.newText);\n\n Color textColorHeadlines = new Color(0.8,0.8,0.8,1);\n\n for ( Text text : headlines ){\n text.setFont(Font.font(\"verdana\", FontWeight.BOLD, FontPosture.REGULAR, 20));\n text.setFill(textColorHeadlines);\n text.setEffect(new DropShadow(30, Color.BLACK));\n\n }\n\n }", "public void display() {\t\t\n\t\tparent.pushStyle();\n\t\t\n\t\t//parent.noStroke();\n\t\t//parent.fill(255);\n\t\tparent.noFill();\n\t\tparent.ellipse(pos.x, pos.y, diam, diam);\n\t\tnodeSpin.drawNode(pos.x, pos.y, diam);\n\t\t\n\t\t//This should match what happens in the hover animation\n\t\tif (focused && userId >= 0) {\n\t\t\tparent.fill(Sequencer.colors[userId]);\n\t\t\tparent.ellipse(pos.x, pos.y, diam, diam);\n\t\t}\n\t\t\n\t\trunAnimations();\n\t\t\n\t\tparent.popStyle();\n\t}", "private void pauseAndPlay(Label textId) {\n textId.setVisible(false);\n textId.setText(\"O\");\n PauseTransition pause = new PauseTransition(Duration.seconds(1));\n pause.setOnFinished(event -> enableAll(textId));\n pause.play();\n\n }", "public Direction moveBlinky(Ghost g);", "public /* synthetic */ void lambda$new$0(ValueAnimator valueAnimator) {\n float animatedFraction = valueAnimator.getAnimatedFraction();\n TextView textView = this.currentView;\n CubicBezierInterpolator cubicBezierInterpolator = CubicBezierInterpolator.DEFAULT;\n textView.setAlpha(cubicBezierInterpolator.getInterpolation(animatedFraction));\n this.nextView.setAlpha(cubicBezierInterpolator.getInterpolation(1.0f - animatedFraction));\n }", "public Circle blinkStar(Star s)\r\n\t{\r\n\t\treturn lang.newCircle(getStarPosition(s.x, s.y), 1, \"blinkStar\" + s.x + \"\" + s.y, null, blinkingPoints);\r\n\t}", "public void blink(int color) {\n setActivityBackgroundColor(color);\n colorTimer.schedule(new TimerTask() {\n public void run() {\n setActivityBackgroundColor(defaultColor);\n }\n }, colorDelay);\n }", "public void displayText() {\n\n // Draws the border on the slideshow aswell as the text\n image(border, slideshowPosX - borderDisplace, textPosY - textMargin - borderDisplace);\n\n // color of text background\n fill(textBackground);\n\n //background for text\n rect(textPosX - textMargin, textPosY - textMargin, textSizeWidth + textMargin * 2, textSizeHeight + textMargin * 2);\n\n //draw text\n image(texts[scene], textPosX, textPosY, textSizeWidth, textSizeHeight, 0, 0 + scrolled, texts[scene].width, textSizeHeight + scrolled);\n }", "public void flash() {\n mFlash = true;\n invalidate();\n }", "private void startAnimating() {\t\n\t\t// Fade in bottom title after a built-in delay.\n\t\tTextView logo2 = (TextView) findViewById(R.id.TextViewBottomTitle);\n\t\tAnimation fade2 = AnimationUtils.loadAnimation(this, R.anim.fade_in2);\n\t\tlogo2.startAnimation(fade2);\n\t\t// Transition to Main Menu when bottom title finishes animating\n\t\tfade2.setAnimationListener(new AnimationListener() {\n\t\t\tpublic void onAnimationEnd(Animation animation) {\n\t\t\t\t// The animation has ended, transition to the Main Menu screen\n\t\t\t\tstartActivity(new Intent(SplashActivity.this, MainMenu.class));\n\t\t\t\tSplashActivity.this.finish();\n\t\t\t}\n\n\t\t\tpublic void onAnimationRepeat(Animation animation) {\n\t\t\t}\n\n\t\t\tpublic void onAnimationStart(Animation animation) {\n\t\t\t}\n\t\t});\n\t}", "@Override\r\n public void onAnimationStart(Animator animation) {\n mTitle.setVisibility(View.VISIBLE);\r\n }", "protected void OnInfoTextAnimationComplete()\r\n\t{\n\t\tswitch(this.m_infoTextFadeState)\r\n\t\t{\r\n\t\t\tcase FADING_OUT:\r\n\t\t\t{\r\n\t\t\t\t// Set the menu state to be FADE_OUT\r\n\t\t\t\tthis.m_infoTextFadeState = FadeState.FADE_OUT;\r\n\t\t\t\tthis.infoTextAlpha = 0.0f;\r\n\t\t\t\tthis.m_infoText.setAlpha(this.infoTextAlpha);\r\n\t\t\t\t\r\n\t\t\t\tbreak;\r\n\t\t\t}\r\n\t\t\tcase FADING_IN:\r\n\t\t\t{\r\n\t\t\t\t// Set the menu state to be FADE_IN\r\n\t\t\t\tthis.m_infoTextFadeState = FadeState.FADE_IN;\r\n\t\t\t\tthis.infoTextAlpha = 1.0f;\r\n\t\t\t\tthis.m_infoText.setAlpha(this.infoTextAlpha);\r\n\t\t\t\t\r\n\t\t\t\tbreak;\r\n\t\t\t}\r\n\t\t\tdefault:\r\n\t\t\t\tbreak;\r\n\t\t}\r\n\t}", "public void setCaretBlinkRate(int rate) {\n if (rate >= 0) {\n getCaret().setBlinkRate(rate);\n }\n }", "private void setAlphaAnimation() {\n\n AlphaAnimation alphaAnim = new AlphaAnimation(1.0f,0.0f);\n alphaAnim.setStartOffset(5000); // start in 5 seconds\n alphaAnim.setDuration(400);\n alphaAnim.setAnimationListener(new Animation.AnimationListener()\n {\n @Override\n public void onAnimationStart(Animation animation) {\n\n }\n\n public void onAnimationEnd(Animation animation)\n {\n // make invisible when animation completes, you could also remove the view from the layout\n txtNotifications.setVisibility(View.INVISIBLE);\n imgNotifications.setImageResource(0);\n }\n\n @Override\n public void onAnimationRepeat(Animation animation) {\n\n }\n });\n txtNotifications.setAnimation(alphaAnim);\n imgNotifications.setAnimation(alphaAnim);\n }", "public void setGreenAnimation(){\n va.setDuration(75);\n va.setEvaluator(new ArgbEvaluator());\n va.setRepeatCount(ValueAnimator.INFINITE);\n va.setRepeatMode(ValueAnimator.REVERSE);\n va.start();\n\n //va.cancel();\n }", "public void FadeInBottomBar() {\n //define alpha animation\n AlphaAnimation fadeIn = new AlphaAnimation(0.0f, 1.0f);\n //set duration\n fadeIn.setDuration(1200);\n //set animation listener\n fadeIn.setAnimationListener(new Animation.AnimationListener() {\n @Override\n public void onAnimationStart(Animation animation) {\n\n }\n\n @Override\n public void onAnimationEnd(Animation animation) {\n //set textview visible on animation ends\n textViewImageName.setVisibility(View.VISIBLE);\n }\n\n @Override\n public void onAnimationRepeat(Animation animation) {\n\n }\n });\n //start animation\n textViewImageName.startAnimation(fadeIn);\n isBottomBarVisible = true;\n }", "@Override\r\n public void onAnimationEnd(Animator animation) {\n mTitle.setVisibility(View.INVISIBLE);\r\n }", "private void createAnimation () {\n // KeyFrame frame = new KeyFrame(Duration.millis(MILLISECOND_DELAY), e -> myManager.step());\n // myAnimation = new Timeline();\n // myAnimation.setCycleCount(Timeline.INDEFINITE);\n // myAnimation.getKeyFrames().add(frame);\n }", "@Override\n public void onAnimationUpdate(ValueAnimator\n animator) {\n etiqueta.setBackgroundColor((Integer)animator.getAnimatedValue());\n }", "void fadeIn();", "void toggleStyle(XYChart.Series<Number, Number> temp)\n {\n if (temp.getData().size() > 0)\n {\n Node n = temp.getData().get(0).getNode();\n try\n {\n for (int i = 0; i < 3; i++)\n {\n n.getStyleClass().add(\"bulge-symbol-sending\");\n n.getStyleClass().add(\"bulge-symbol-sending\");\n Thread.currentThread().sleep(150);\n n.getStyleClass().add(\"bulge-symbol-receiving\");\n n.getStyleClass().add(\"bulge-symbol-receiving\");\n Thread.currentThread().sleep(100);\n }\n }\n catch (Exception e)\n {\n\n }\n }\n }", "public void updateAnimation() {\n\t\tif (anim < 1000) {\n\t\t\tanim++;\n\t\t} else anim = 0;\n\t}", "private static Animation m25226b() {\n Animation alphaAnimation = new AlphaAnimation(1.0f, 0.0f);\n alphaAnimation.setInterpolator(new AccelerateInterpolator());\n alphaAnimation.setDuration(350);\n return alphaAnimation;\n }", "private void setText(Text text) {\n \t\tthis.text = text;\n \t}", "@Override\n public void onTick(long millisUntilFinished) {\n\n odliczanie2--;\n Animation animationprzyciski= AnimationUtils.loadAnimation(getApplicationContext(),R.anim.mixed_anim);\n odliczanie.startAnimation(animationprzyciski);\n odliczanie.setText(odliczanie2+\"\");\n\n }", "@Override\n public void updateDrawState(TextPaint ds) {\n }", "void animation() {\n LinearLayout linearLayout = findViewById(R.id.loginLinear);\n animationDrawable = (AnimationDrawable)linearLayout.getBackground();\n animationDrawable.setEnterFadeDuration(5000);\n animationDrawable.setExitFadeDuration(5000);\n\n }", "protected void drawRainbowTitle(Graphics2D g2d, Font font, List<Color> colors, int offsetX, String text)\n {\n g2d.setFont(new Font(font.getName(), Font.PLAIN, 140));\n Color curr = colors.get(0);\n g2d.setColor(curr);\n\n for (int i = 0; i < text.length(); i++)\n {\n g2d.drawString(String.valueOf(text.charAt(i)), 80 * i + offsetX, 200);\n\n if (text.charAt(i) == ' ') continue;\n curr = colors.get((colors.indexOf(curr) + 1) % colors.size());\n g2d.setColor(curr);\n\n }\n }", "@Override\n public void updateDrawState(TextPaint ds) {\n ds.setUnderlineText(false);\n }", "public AnimationFX(Node node) {\n super();\n setNode(node);\n\n }", "@Override\n\t\t\t\tpublic void run() {\n\t\t\t\t\ttry{\n\t\t\t\t\t\tThread.sleep(2000);\n\t\t\t\t\t}catch(Exception e){\n\t\t\t\t\t\te.printStackTrace();\n\t\t\t\t\t}\n\t\t\t\t\tanimDraw.stop();\n\t\t\t\t\tanimDraw2.stop();\t\t\t\t\n\t\t\t\t\thandler3.sendMessage(handler3.obtainMessage());\n\t\t\t\t}", "void animate( LightCondition lights );", "@Override\n protected void animateWalking() {\n if (seqIdx > 7) {\n seqIdx = 0;\n }\n if (walking) {\n this.setImage(\"images/bat/bat_\" + seqIdx + FILE_SUFFIX);\n } else {\n this.setImage(\"images/bat/bat_0.png\");\n }\n seqIdx++;\n }", "void startAnimation();", "@Override\n public void run()\n {\n while(Sprite.threadActive)\n {\n Sprite.Delay();\n this.Move();\n this.laser.Fire();\n\n //Blink character if hit\n //if(this.damaged)\n //{\n //this.Blink(2);\n //}\n }\n }", "public void blink234() {\n printMessage(\"Entering method blink234\\n\");\r\n // Set pin 7 to be output.\r\n if (pin2Out == null) {\r\n pin2Out = new OutPin(2, DEBUGGING, PRINTTRACE);\r\n }\r\n \r\n if (pin3Out == null) {\r\n pin3Out = new OutPin(3, DEBUGGING, PRINTTRACE);\r\n }\r\n \r\n if (pin4Out == null) {\r\n pin4Out = new OutPin(4, DEBUGGING, PRINTTRACE);\r\n }\r\n \r\n pin2Out.setValue(true);\r\n delayMilliSec(5000);\r\n pin2Out.setValue(false);\r\n pin3Out.setValue(true);\r\n delayMilliSec(5000);\r\n pin3Out.setValue(false);\r\n pin4Out.setValue(true);\r\n delayMilliSec(5000);\r\n pin4Out.setValue(false);\r\n \r\n for (int j = 0; j < 120; j++) {\r\n pin2Out.setValue(true);\r\n pin3Out.setValue(true);\r\n pin4Out.setValue(true);\r\n delayMilliSec(250);\r\n pin2Out.setValue(false);\r\n pin3Out.setValue(false);\r\n pin4Out.setValue(false);\r\n delayMilliSec(250);\r\n }\r\n \r\n printMessage(\"End of method blink234\");\r\n }", "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}", "public void changeLivesDisplay()\r\n {\r\n removeObject(text);\r\n //Add the lives text\r\n text = new Text(\"Lives: \" + health);\r\n addObject(text, 60, 15);\r\n }", "@Override\r\n\t\tpublic void updateDrawState(TextPaint ds) {\n\t\t\tsuper.updateDrawState(ds);\r\n\t\t\tds.setUnderlineText(false);\r\n\t\t}", "@Override\n\tpublic void render() {\n\t\tif (this.hidden) {\n\t\t\treturn;\n\t\t}\n\n\t\tsuper.render();\n\n\t\tthis.font.draw(Graphics.batch, this.label, this.getX(),\n\t\t\tthis.getY() + (this.getHeight() - this.font.getLineHeight()) / 2);\n\t}", "public void setlblMoveText(String text){\n \t moveTimer = new Timer(45, new ActionListener() {\n\t\t\t\tint charIndex = 0;\n\t\t\t\tpublic void actionPerformed(ActionEvent e) {\n\t\t\t\t\t String labelText = lblMoveText.getText();\n\t\t labelText += text.charAt(charIndex);\n\t\t lblMoveText.setText(labelText);\n\t\t charIndex++;\n\t\t if (charIndex >= text.length()) {\n\t\t moveTimer.stop();\n\t\t }\t\n\t\t\t\t} \n });\n moveTimer.start();\n\t}", "@Override\r\n\tprotected void onResume() {\n\t\tmTextView.postDelayed(animation_runnable, 1000);\r\n\t\tsuper.onResume();\r\n\t}", "@Override\n\t\t\t\tpublic void run() {\n\t\t\t\t\ttry{\n\t\t\t\t\t\tThread.sleep(2000);\n\t\t\t\t\t}catch(Exception e){\n\t\t\t\t\t\te.printStackTrace();\n\t\t\t\t\t}\n\t\t\t\t\tanimDraw.stop();\n\t\t\t\t\tanimDraw2.stop();\n\t\t\t\t\thandler.sendMessage(handler.obtainMessage());\n\t\t\t\t}", "private void crossFade() {\n robotIv.setAlpha(0f);\n robotIv.setVisibility(View.VISIBLE);\n\n // Animate the content view to 100% opacity, and clear any animation\n // listener set on the view.\n robotIv.animate()\n .alpha(1f)\n .setDuration(1800)\n .setListener(new AnimatorListenerAdapter() {\n @Override\n public void onAnimationEnd(Animator animation) {\n welcomeTv.setVisibility(View.VISIBLE);\n }\n });\n\n }", "protected void doToggleTextBackgrounds() {\r\n\t\trenderer.textBackgrounds = ui.viewTextBackgrounds.isSelected();\r\n\t\trenderer.repaint();\r\n\t}", "public void update (String text)\n {\n buttonText = text;\n GreenfootImage tempTextImage = new GreenfootImage (text, 20, Color.RED, Color.WHITE);\n myImage = new GreenfootImage (tempTextImage.getWidth() + 8, tempTextImage.getHeight() + 8);\n myImage.setColor (Color.WHITE);\n myImage.fill();\n myImage.drawImage (tempTextImage, 4, 4);\n\n myImage.setColor (Color.BLACK);\n myImage.drawRect (0,0,tempTextImage.getWidth() + 7, tempTextImage.getHeight() + 7);\n setImage(myImage);\n }", "private void showLabel(String text, Color color) {\n GLabel result = new GLabel(text);\n result.setFont(\"Verdana-60\");\n result.setColor(color);\n result.sendToFront();\n add(result, (getWidth() - result.getWidth()) /2, (getHeight() - result.getHeight()) / 2 );\n pause(FREEZE_TIME);\n remove(result);\n }", "public void testLeds(int duration) {\n\t\tledBlinking.startThread();\n\t\ttry {\n\t\t\tThread.sleep(duration);\n\t\t} catch (InterruptedException e) {\n\t\t\te.printStackTrace();\n\t\t}\n\t\tstopBlinking();\n\t}", "@Override\n\t\t\t\tpublic void run() {\n\t\t\t\t\ttry{\t\t\t\t\t\t\n\t\t\t\t\t\tThread.sleep(2000);\n\t\t\t\t\t}catch(Exception e){\n\t\t\t\t\t\te.printStackTrace();\n\t\t\t\t\t}\n\t\t\t\t\tanimDraw.stop();\n\t\t\t\t\tanimDraw2.stop();\t\t\t\t\n\t\t\t\t\thandler2.sendMessage(handler2.obtainMessage());\n\t\t\t\t}", "public void animate() throws InterruptedException {\n for (int x = 0; x < repeat; x++) {\n for (int i = 0; i < MAX_FRAMES; i++) {\n nextFrame();\n pause();\n }\n changeDelay();\n }\n }", "@Override\n public void draw(Bullet b){\n Draw.color(Palette.lightFlame, Palette.darkFlame, Color.GRAY, b.fin());\n Fill.circle(b.x, b.y, 3f * b.fout());\n Draw.reset();\n }", "public void hide(){\n background.setOpacity(0);\n text.setOpacity(0);\n }", "public void enterStats(View v){\n /*\n * Flash animation code found on StackOverflow\n * Posted by user sany in response to question from user David Prun\n * Post dated Aug 10, 2010\n * http://stackoverflow.com/questions/3450839/blinking-text-in-android-view\n * */\n Animation flashText = new AlphaAnimation(0.0f, 1.0f);\n flashText.setDuration(250);\n flashText.setStartOffset(20);\n flashText.setRepeatMode(Animation.REVERSE);\n flashText.setRepeatCount(8);\n\n Animation flashScore = new AlphaAnimation(0.0f, 1.0f);\n flashScore.setDuration(250);\n flashScore.setStartOffset(20);\n flashScore.setRepeatMode(Animation.REVERSE);\n flashScore.setRepeatCount(1);\n\n // home selected WITHOUT minus stat selected\n if(home.isSelected() && !minusstat.isSelected()){\n if(!fgmade.isSelected() && !fgattempt.isSelected() && !threeptmade.isSelected() && !threeattempt.isSelected() && !ftmade.isSelected()\n && !ftattempt.isSelected() && !oreb.isSelected() && !dreb.isSelected() && !block.isSelected() && !steal.isSelected()\n && !assist.isSelected() && !turnover.isSelected() && !foul.isSelected()){\n Toast.makeText(getApplicationContext(), minusWarning, Toast.LENGTH_SHORT).show();\n } // end if no stat selected\n if (fgmade.isSelected()) {\n homescore = homescore + 2;\n scoreString = homescore + \" - \" + awayscore;\n score.setText(scoreString);\n score.startAnimation(flashScore);\n homefg++;\n homefga++;\n statUpdate = homefg + \"/\" + homefga;\n hfgma.setText(statUpdate);\n hfgma.startAnimation(flashText);\n statUpdate = ((homefg * 100) / homefga) + \"%\";\n hfgp.setText(statUpdate);\n hfgp.startAnimation(flashText);\n fgmade.setSelected(false);\n fgmade.getBackground().setColorFilter(0xFFFF9900, PorterDuff.Mode.MULTIPLY);\n } // end fgmade selected\n if(fgattempt.isSelected()){\n homefga++;\n statUpdate = homefg + \"/\" + homefga;\n hfgma.setText(statUpdate);\n hfgma.startAnimation(flashText);\n statUpdate = ((homefg * 100) / homefga) + \"%\";\n hfgp.setText(statUpdate);\n hfgp.startAnimation(flashText);\n fgattempt.setSelected(false);\n fgattempt.getBackground().setColorFilter(0xFFFF9900, PorterDuff.Mode.MULTIPLY);\n } // end fgattempt selected\n if (threeptmade.isSelected()) {\n homescore = homescore + 3;\n scoreString = homescore + \" - \" + awayscore;\n score.setText(scoreString);\n score.startAnimation(flashScore);\n homethree++;\n homethreea++;\n statUpdate = homethree + \"/\" + homethreea;\n hthreema.setText(statUpdate);\n hthreema.startAnimation(flashText);\n statUpdate = ((homethree * 100) / homethreea) + \"%\";\n hthreep.setText(statUpdate);\n hthreep.startAnimation(flashText);\n threeptmade.setSelected(false);\n threeptmade.getBackground().setColorFilter(0xFFFF9900, PorterDuff.Mode.MULTIPLY);\n } // end threeptmade selected\n if(threeattempt.isSelected()){\n homethreea++;\n statUpdate = homethree + \"/\" + homethreea;\n hthreema.setText(statUpdate);\n hthreema.startAnimation(flashText);\n statUpdate = ((homethree * 100) / homethreea) + \"%\";\n hthreep.setText(statUpdate);\n hthreep.startAnimation(flashText);\n threeattempt.setSelected(false);\n threeattempt.getBackground().setColorFilter(0xFFFF9900, PorterDuff.Mode.MULTIPLY);\n } // end threeattempt selected\n if (ftmade.isSelected()) {\n homescore = homescore + 1;\n scoreString = homescore + \" - \" + awayscore;\n score.setText(scoreString);\n score.startAnimation(flashScore);\n homeft++;\n homefta++;\n statUpdate = homeft + \"/\" + homefta;\n hftma.setText(statUpdate);\n hftma.startAnimation(flashText);\n statUpdate = ((homeft * 100) / homefta) + \"%\";\n hftp.setText(statUpdate);\n hftp.startAnimation(flashText);\n ftmade.setSelected(false);\n ftmade.getBackground().setColorFilter(0xFFFF9900, PorterDuff.Mode.MULTIPLY);\n } // end ftmade selected\n if(ftattempt.isSelected()){\n homefta++;\n statUpdate = homeft + \"/\" + homefta;\n hftma.setText(statUpdate);\n hftma.startAnimation(flashText);\n statUpdate = ((homeft * 100) / homefta) + \"%\";\n hftp.setText(statUpdate);\n hftp.startAnimation(flashText);\n ftattempt.setSelected(false);\n ftattempt.getBackground().setColorFilter(0xFFFF9900, PorterDuff.Mode.MULTIPLY);\n } // end ftattempt selected\n if(oreb.isSelected()){\n homeorb++;\n statUpdate = homeorb + \"\";\n hor.setText(statUpdate);\n hor.startAnimation(flashText);\n oreb.setSelected(false);\n oreb.getBackground().setColorFilter(0xFFFF9900, PorterDuff.Mode.MULTIPLY);\n } // end oreb selected\n if(dreb.isSelected()){\n homedrb++;\n statUpdate = homedrb + \"\";\n hdr.setText(statUpdate);\n hdr.startAnimation(flashText);\n dreb.setSelected(false);\n dreb.getBackground().setColorFilter(0xFFFF9900, PorterDuff.Mode.MULTIPLY);\n } // end dreb selected\n if(block.isSelected()){\n homeblock++;\n statUpdate = homeblock + \"\";\n hb.setText(statUpdate);\n hb.startAnimation(flashText);\n block.setSelected(false);\n block.getBackground().setColorFilter(0xFFFF9900, PorterDuff.Mode.MULTIPLY);\n } // end block selected\n if(steal.isSelected()){\n homesteal++;\n statUpdate = homesteal + \"\";\n hs.setText(statUpdate);\n hs.startAnimation(flashText);\n steal.setSelected(false);\n steal.getBackground().setColorFilter(0xFFFF9900, PorterDuff.Mode.MULTIPLY);\n } // end steal selected\n if(assist.isSelected()){\n homeassist++;\n statUpdate = homeassist + \"\";\n ha.setText(statUpdate);\n ha.startAnimation(flashText);\n assist.setSelected(false);\n assist.getBackground().setColorFilter(0xFFFF9900, PorterDuff.Mode.MULTIPLY);\n } // end assist selected\n if(turnover.isSelected()){\n hometurnover++;\n statUpdate = hometurnover + \"\";\n ht.setText(statUpdate);\n ht.startAnimation(flashText);\n turnover.setSelected(false);\n turnover.getBackground().setColorFilter(0xFFFF9900, PorterDuff.Mode.MULTIPLY);\n } // end turnover selected\n if(foul.isSelected()){\n homefoul++;\n statUpdate = homefoul + \"\";\n hfouls.setText(statUpdate);\n hfouls.startAnimation(flashText);\n foul.setSelected(false);\n foul.getBackground().setColorFilter(0xFFFF9900, PorterDuff.Mode.MULTIPLY);\n } // end foul selected\n\n home.setSelected(false);\n home.getBackground().setColorFilter(0xFFFF9900, PorterDuff.Mode.MULTIPLY);\n } // end if home selected and minus stat IS NOT selected\n\n // home selected AND minus stat selected\n else if(home.isSelected() && minusstat.isSelected()){\n if(!fgmade.isSelected() && !fgattempt.isSelected() && !threeptmade.isSelected() && !threeattempt.isSelected() && !ftmade.isSelected()\n && !ftattempt.isSelected() && !oreb.isSelected() && !dreb.isSelected() && !block.isSelected() && !steal.isSelected()\n && !assist.isSelected() && !turnover.isSelected() && !foul.isSelected()){\n Toast.makeText(getApplicationContext(), minusWarning, Toast.LENGTH_SHORT).show();\n } // end if no stat selected\n if (fgmade.isSelected()) {\n homescore = homescore - 2;\n scoreString = homescore + \" - \" + awayscore;\n score.setText(scoreString);\n score.startAnimation(flashScore);\n homefg--;\n homefga--;\n statUpdate = homefg + \"/\" + homefga;\n hfgma.setText(statUpdate);\n hfgma.startAnimation(flashText);\n statUpdate = ((homefg * 100) / homefga) + \"%\";\n hfgp.setText(statUpdate);\n hfgp.startAnimation(flashText);\n fgmade.setSelected(false);\n fgmade.getBackground().setColorFilter(0xFFFF9900, PorterDuff.Mode.MULTIPLY);\n } // end fgmade selected\n if(fgattempt.isSelected()){\n homefga--;\n statUpdate = homefg + \"/\" + homefga;\n hfgma.setText(statUpdate);\n hfgma.startAnimation(flashText);\n statUpdate = ((homefg * 100) / homefga) + \"%\";\n hfgp.setText(statUpdate);\n hfgp.startAnimation(flashText);\n fgattempt.setSelected(false);\n fgattempt.getBackground().setColorFilter(0xFFFF9900, PorterDuff.Mode.MULTIPLY);\n } // end fgattempt selected\n if (threeptmade.isSelected()) {\n homescore = homescore - 3;\n scoreString = homescore + \" - \" + awayscore;\n score.setText(scoreString);\n score.startAnimation(flashScore);\n homethree--;\n homethreea--;\n statUpdate = homethree + \"/\" + homethreea;\n hthreema.setText(statUpdate);\n hthreema.startAnimation(flashText);\n statUpdate = ((homethree * 100) / homethreea) + \"%\";\n hthreep.setText(statUpdate);\n hthreep.startAnimation(flashText);\n threeptmade.setSelected(false);\n threeptmade.getBackground().setColorFilter(0xFFFF9900, PorterDuff.Mode.MULTIPLY);\n } // end threeptmade selected\n if(threeattempt.isSelected()){\n homethreea--;\n statUpdate = homethree + \"/\" + homethreea;\n hthreema.setText(statUpdate);\n hthreema.startAnimation(flashText);\n statUpdate = ((homethree * 100) / homethreea) + \"%\";\n hthreep.setText(statUpdate);\n hthreep.startAnimation(flashText);\n threeattempt.setSelected(false);\n threeattempt.getBackground().setColorFilter(0xFFFF9900, PorterDuff.Mode.MULTIPLY);\n } // end threeattempt selected\n if (ftmade.isSelected()) {\n homescore = homescore - 1;\n scoreString = homescore + \" - \" + awayscore;\n score.setText(scoreString);\n score.startAnimation(flashScore);\n homeft--;\n homefta--;\n statUpdate = homeft + \"/\" + homefta;\n hftma.setText(statUpdate);\n hftma.startAnimation(flashText);\n statUpdate = ((homeft * 100) / homefta) + \"%\";\n hftp.setText(statUpdate);\n hftp.startAnimation(flashText);\n ftmade.setSelected(false);\n ftmade.getBackground().setColorFilter(0xFFFF9900, PorterDuff.Mode.MULTIPLY);\n } // end ftmade selected\n if(ftattempt.isSelected()){\n homefta--;\n statUpdate = homeft + \"/\" + homefta;\n hftma.setText(statUpdate);\n hftma.startAnimation(flashText);\n statUpdate = ((homeft * 100) / homefta) + \"%\";\n hftp.setText(statUpdate);\n hftp.startAnimation(flashText);\n ftattempt.setSelected(false);\n ftattempt.getBackground().setColorFilter(0xFFFF9900, PorterDuff.Mode.MULTIPLY);\n } // end ftattempt selected\n if(oreb.isSelected()){\n homeorb--;\n statUpdate = homeorb + \"\";\n hor.setText(statUpdate);\n hor.startAnimation(flashText);\n oreb.setSelected(false);\n oreb.getBackground().setColorFilter(0xFFFF9900, PorterDuff.Mode.MULTIPLY);\n } // end oreb selected\n if(dreb.isSelected()){\n homedrb--;\n statUpdate = homedrb + \"\";\n hdr.setText(statUpdate);\n hdr.startAnimation(flashText);\n dreb.setSelected(false);\n dreb.getBackground().setColorFilter(0xFFFF9900, PorterDuff.Mode.MULTIPLY);\n } // end dreb selected\n if(block.isSelected()){\n homeblock--;\n statUpdate = homeblock + \"\";\n hb.setText(statUpdate);\n hb.startAnimation(flashText);\n block.setSelected(false);\n block.getBackground().setColorFilter(0xFFFF9900, PorterDuff.Mode.MULTIPLY);\n } // end block selected\n if(steal.isSelected()){\n homesteal--;\n statUpdate = homesteal + \"\";\n hs.setText(statUpdate);\n hs.startAnimation(flashText);\n steal.setSelected(false);\n steal.getBackground().setColorFilter(0xFFFF9900, PorterDuff.Mode.MULTIPLY);\n } // end steal selected\n if(assist.isSelected()){\n homeassist--;\n statUpdate = homeassist + \"\";\n ha.setText(statUpdate);\n ha.startAnimation(flashText);\n assist.setSelected(false);\n assist.getBackground().setColorFilter(0xFFFF9900, PorterDuff.Mode.MULTIPLY);\n } // end assist selected\n if(turnover.isSelected()){\n hometurnover--;\n statUpdate = hometurnover + \"\";\n ht.setText(statUpdate);\n ht.startAnimation(flashText);\n turnover.setSelected(false);\n turnover.getBackground().setColorFilter(0xFFFF9900, PorterDuff.Mode.MULTIPLY);\n } // end turnover selected\n if(foul.isSelected()){\n homefoul--;\n statUpdate = homefoul + \"\";\n hfouls.setText(statUpdate);\n hfouls.startAnimation(flashText);\n foul.setSelected(false);\n foul.getBackground().setColorFilter(0xFFFF9900, PorterDuff.Mode.MULTIPLY);\n } // end foul selected\n\n home.setSelected(false);\n home.getBackground().setColorFilter(0xFFFF9900, PorterDuff.Mode.MULTIPLY);\n minusstat.setSelected(false);\n minusstat.getBackground().setColorFilter(0xFFFF9900, PorterDuff.Mode.MULTIPLY);\n } // end if home selected and minus stat IS selected\n\n else if(away.isSelected()){\n // away selected WITHOUT minus stat selected\n if(away.isSelected() && !minusstat.isSelected()){\n if(!fgmade.isSelected() && !fgattempt.isSelected() && !threeptmade.isSelected() && !threeattempt.isSelected() && !ftmade.isSelected()\n && !ftattempt.isSelected() && !oreb.isSelected() && !dreb.isSelected() && !block.isSelected() && !steal.isSelected()\n && !assist.isSelected() && !turnover.isSelected() && !foul.isSelected()){\n Toast.makeText(getApplicationContext(), minusWarning, Toast.LENGTH_SHORT).show();\n } // end if no stat selected\n if (fgmade.isSelected()) {\n awayscore = awayscore + 2;\n scoreString = homescore + \" - \" + awayscore;\n score.setText(scoreString);\n score.startAnimation(flashScore);\n awayfg++;\n awayfga++;\n statUpdate = awayfg + \"/\" + awayfga;\n vfgma.setText(statUpdate);\n vfgma.startAnimation(flashText);\n statUpdate = ((awayfg * 100) / awayfga) + \"%\";\n vfgp.setText(statUpdate);\n vfgp.startAnimation(flashText);\n fgmade.setSelected(false);\n fgmade.getBackground().setColorFilter(0xFFFF9900, PorterDuff.Mode.MULTIPLY);\n } // end fgmade selected\n if(fgattempt.isSelected()){\n awayfga++;\n statUpdate = awayfg + \"/\" + awayfga;\n vfgma.setText(statUpdate);\n vfgma.startAnimation(flashText);\n statUpdate = ((awayfg * 100) / awayfga) + \"%\";\n vfgp.setText(statUpdate);\n vfgp.startAnimation(flashText);\n fgattempt.setSelected(false);\n fgattempt.getBackground().setColorFilter(0xFFFF9900, PorterDuff.Mode.MULTIPLY);\n } // end fgattempt selected\n if (threeptmade.isSelected()) {\n awayscore = awayscore + 3;\n scoreString = homescore + \" - \" + awayscore;\n score.setText(scoreString);\n score.startAnimation(flashScore);\n awaythree++;\n awaythreea++;\n statUpdate = awaythree + \"/\" + awaythreea;\n vthreema.setText(statUpdate);\n vthreema.startAnimation(flashText);\n statUpdate = ((awaythree * 100) / awaythreea) + \"%\";\n vthreep.setText(statUpdate);\n vthreep.startAnimation(flashText);\n threeptmade.setSelected(false);\n threeptmade.getBackground().setColorFilter(0xFFFF9900, PorterDuff.Mode.MULTIPLY);\n } // end threeptmade selected\n if(threeattempt.isSelected()){\n awaythreea++;\n statUpdate = awaythree + \"/\" + awaythreea;\n vthreema.setText(statUpdate);\n vthreema.startAnimation(flashText);\n statUpdate = ((awaythree * 100) / awaythreea) + \"%\";\n vthreep.setText(statUpdate);\n vthreep.startAnimation(flashText);\n threeattempt.setSelected(false);\n threeattempt.getBackground().setColorFilter(0xFFFF9900, PorterDuff.Mode.MULTIPLY);\n } // end threeattempt selected\n if (ftmade.isSelected()) {\n awayscore = awayscore + 1;\n scoreString = homescore + \" - \" + awayscore;\n score.setText(scoreString);\n score.startAnimation(flashScore);\n awayft++;\n awayfta++;\n statUpdate = awayft + \"/\" + awayfta;\n vftma.setText(statUpdate);\n vftma.startAnimation(flashText);\n statUpdate = ((awayft * 100) / awayfta) + \"%\";\n vftp.setText(statUpdate);\n vftp.startAnimation(flashText);\n ftmade.setSelected(false);\n ftmade.getBackground().setColorFilter(0xFFFF9900, PorterDuff.Mode.MULTIPLY);\n } // end ftmade selected\n if(ftattempt.isSelected()){\n awayfta++;\n statUpdate = awayft + \"/\" + awayfta;\n vftma.setText(statUpdate);\n vftma.startAnimation(flashText);\n statUpdate = ((awayft * 100) / awayfta) + \"%\";\n vftp.setText(statUpdate);\n vftp.startAnimation(flashText);\n ftattempt.setSelected(false);\n ftattempt.getBackground().setColorFilter(0xFFFF9900, PorterDuff.Mode.MULTIPLY);\n } // end ftattempt selected\n if(oreb.isSelected()){\n awayorb++;\n statUpdate = awayorb + \"\";\n vor.setText(statUpdate);\n vor.startAnimation(flashText);\n oreb.setSelected(false);\n oreb.getBackground().setColorFilter(0xFFFF9900, PorterDuff.Mode.MULTIPLY);\n } // end oreb selected\n if(dreb.isSelected()){\n awaydrb++;\n statUpdate = awaydrb + \"\";\n vdr.setText(statUpdate);\n vdr.startAnimation(flashText);\n dreb.setSelected(false);\n dreb.getBackground().setColorFilter(0xFFFF9900, PorterDuff.Mode.MULTIPLY);\n } // end dreb selected\n if(block.isSelected()){\n awayblock++;\n statUpdate = awayblock + \"\";\n vb.setText(statUpdate);\n vb.startAnimation(flashText);\n block.setSelected(false);\n block.getBackground().setColorFilter(0xFFFF9900, PorterDuff.Mode.MULTIPLY);\n } // end block selected\n if(steal.isSelected()){\n awaysteal++;\n statUpdate = awaysteal + \"\";\n vs.setText(statUpdate);\n vs.startAnimation(flashText);\n steal.setSelected(false);\n steal.getBackground().setColorFilter(0xFFFF9900, PorterDuff.Mode.MULTIPLY);\n } // end steal selected\n if(assist.isSelected()){\n awayassist++;\n statUpdate = awayassist + \"\";\n va.setText(statUpdate);\n va.startAnimation(flashText);\n assist.setSelected(false);\n assist.getBackground().setColorFilter(0xFFFF9900, PorterDuff.Mode.MULTIPLY);\n } // end assist selected\n if(turnover.isSelected()){\n awayturnover++;\n statUpdate = awayturnover + \"\";\n vt.setText(statUpdate);\n vt.startAnimation(flashText);\n turnover.setSelected(false);\n turnover.getBackground().setColorFilter(0xFFFF9900, PorterDuff.Mode.MULTIPLY);\n } // end turnover selected\n if(foul.isSelected()){\n awayfoul++;\n statUpdate = awayfoul + \"\";\n vfouls.setText(statUpdate);\n vfouls.startAnimation(flashText);\n foul.setSelected(false);\n foul.getBackground().setColorFilter(0xFFFF9900, PorterDuff.Mode.MULTIPLY);\n } // end foul selected\n\n away.setSelected(false);\n away.getBackground().setColorFilter(0xFFFF9900, PorterDuff.Mode.MULTIPLY);\n } // end if away selected and minus stat IS NOT selected\n\n // away selected AND minus stat selected\n else if(away.isSelected() && minusstat.isSelected()){\n if(!fgmade.isSelected() && !fgattempt.isSelected() && !threeptmade.isSelected() && !threeattempt.isSelected() && !ftmade.isSelected()\n && !ftattempt.isSelected() && !oreb.isSelected() && !dreb.isSelected() && !block.isSelected() && !steal.isSelected()\n && !assist.isSelected() && !turnover.isSelected() && !foul.isSelected()){\n Toast.makeText(getApplicationContext(), minusWarning, Toast.LENGTH_SHORT).show();\n } // end if no stat selected\n if (fgmade.isSelected()) {\n awayscore = awayscore - 2;\n scoreString = homescore + \" - \" + awayscore;\n score.setText(scoreString);\n score.startAnimation(flashScore);\n awayfg--;\n awayfga--;\n statUpdate = awayfg + \"/\" + awayfga;\n vfgma.setText(statUpdate);\n vfgma.startAnimation(flashText);\n statUpdate = ((awayfg * 100) / awayfga) + \"%\";\n vfgp.setText(statUpdate);\n vfgp.startAnimation(flashText);\n fgmade.setSelected(false);\n fgmade.getBackground().setColorFilter(0xFFFF9900, PorterDuff.Mode.MULTIPLY);\n } // end fgmade selected\n if(fgattempt.isSelected()){\n awayfga--;\n statUpdate = awayfg + \"/\" + awayfga;\n vfgma.setText(statUpdate);\n vfgma.startAnimation(flashText);\n statUpdate = ((awayfg * 100) / awayfga) + \"%\";\n vfgp.setText(statUpdate);\n vfgp.startAnimation(flashText);\n fgattempt.setSelected(false);\n fgattempt.getBackground().setColorFilter(0xFFFF9900, PorterDuff.Mode.MULTIPLY);\n } // end fgattempt selected\n if (threeptmade.isSelected()) {\n awayscore = awayscore - 3;\n scoreString = homescore + \" - \" + awayscore;\n score.setText(scoreString);\n score.startAnimation(flashScore);\n awaythree--;\n awaythreea--;\n statUpdate = awaythree + \"/\" + awaythreea;\n vthreema.setText(statUpdate);\n vthreema.startAnimation(flashText);\n statUpdate = ((awaythree * 100) / awaythreea) + \"%\";\n vthreep.setText(statUpdate);\n vthreep.startAnimation(flashText);\n threeptmade.setSelected(false);\n threeptmade.getBackground().setColorFilter(0xFFFF9900, PorterDuff.Mode.MULTIPLY);\n } // end threeptmade selected\n if(threeattempt.isSelected()){\n awaythreea--;\n statUpdate = awaythree + \"/\" + awaythreea;\n vthreema.setText(statUpdate);\n vthreema.startAnimation(flashText);\n statUpdate = ((awaythree * 100) / awaythreea) + \"%\";\n vthreep.setText(statUpdate);\n vthreep.startAnimation(flashText);\n threeattempt.setSelected(false);\n threeattempt.getBackground().setColorFilter(0xFFFF9900, PorterDuff.Mode.MULTIPLY);\n } // end threeattempt selected\n if (ftmade.isSelected()) {\n awayscore = awayscore - 1;\n scoreString = homescore + \" - \" + awayscore;\n score.setText(scoreString);\n score.startAnimation(flashScore);\n awayft--;\n awayfta--;\n statUpdate = awayft + \"/\" + awayfta;\n vftma.setText(statUpdate);\n vftma.startAnimation(flashText);\n statUpdate = ((awayft * 100) / awayfta) + \"%\";\n vftp.setText(statUpdate);\n vftp.startAnimation(flashText);\n ftmade.setSelected(false);\n ftmade.getBackground().setColorFilter(0xFFFF9900, PorterDuff.Mode.MULTIPLY);\n } // end ftmade selected\n if(ftattempt.isSelected()){\n awayfta--;\n statUpdate = awayft + \"/\" + awayfta;\n vftma.setText(statUpdate);\n vftma.startAnimation(flashText);\n statUpdate = ((awayft * 100) / awayfta) + \"%\";\n vftp.setText(statUpdate);\n vftp.startAnimation(flashText);\n ftattempt.setSelected(false);\n ftattempt.getBackground().setColorFilter(0xFFFF9900, PorterDuff.Mode.MULTIPLY);\n } // end ftattempt selected\n if(oreb.isSelected()){\n awayorb--;\n statUpdate = awayorb + \"\";\n vor.setText(statUpdate);\n vor.startAnimation(flashText);\n oreb.setSelected(false);\n oreb.getBackground().setColorFilter(0xFFFF9900, PorterDuff.Mode.MULTIPLY);\n } // end oreb selected\n if(dreb.isSelected()){\n awaydrb--;\n statUpdate = awaydrb + \"\";\n vdr.setText(statUpdate);\n vdr.startAnimation(flashText);\n dreb.setSelected(false);\n dreb.getBackground().setColorFilter(0xFFFF9900, PorterDuff.Mode.MULTIPLY);\n } // end dreb selected\n if(block.isSelected()){\n awayblock--;\n statUpdate = awayblock + \"\";\n vb.setText(statUpdate);\n vb.startAnimation(flashText);\n block.setSelected(false);\n block.getBackground().setColorFilter(0xFFFF9900, PorterDuff.Mode.MULTIPLY);\n } // end block selected\n if(steal.isSelected()){\n awaysteal--;\n statUpdate = awaysteal + \"\";\n vs.setText(statUpdate);\n vs.startAnimation(flashText);\n steal.setSelected(false);\n steal.getBackground().setColorFilter(0xFFFF9900, PorterDuff.Mode.MULTIPLY);\n } // end steal selected\n if(assist.isSelected()){\n awayassist--;\n statUpdate = awayassist + \"\";\n va.setText(statUpdate);\n va.startAnimation(flashText);\n assist.setSelected(false);\n assist.getBackground().setColorFilter(0xFFFF9900, PorterDuff.Mode.MULTIPLY);\n } // end assist selected\n if(turnover.isSelected()){\n awayturnover--;\n statUpdate = awayturnover + \"\";\n vt.setText(statUpdate);\n vt.startAnimation(flashText);\n turnover.setSelected(false);\n turnover.getBackground().setColorFilter(0xFFFF9900, PorterDuff.Mode.MULTIPLY);\n } // end turnover selected\n if(foul.isSelected()){\n awayfoul--;\n statUpdate = awayfoul + \"\";\n vfouls.setText(statUpdate);\n vfouls.startAnimation(flashText);\n foul.setSelected(false);\n foul.getBackground().setColorFilter(0xFFFF9900, PorterDuff.Mode.MULTIPLY);\n } // end foul selected\n\n away.setSelected(false);\n away.getBackground().setColorFilter(0xFFFF9900, PorterDuff.Mode.MULTIPLY);\n minusstat.setSelected(false);\n minusstat.getBackground().setColorFilter(0xFFFF9900, PorterDuff.Mode.MULTIPLY);\n } // end if away selected and minus stat IS selected\n\n } // end if away selected\n\n else{\n Toast.makeText(getApplicationContext(), teamToast, Toast.LENGTH_SHORT).show();\n } // end if no team selected\n\n }", "public void setText(String text) {\n\t\t\n\t}", "public void strokeString(float x, float y, String text);", "@Override\n protected void animStart() {\n }", "public void drawAnimationAtStart(){\n animationThread = new AnimationThread(this.getGraphics(), getWidth(), getHeight());\n animationThread.start();\n music.playAudio(\"LoadingScreenMusic\");\n musicName = \"LoadingScreenMusic\";\n }", "@Override\n\t\t\tpublic void onClick(View arg0) {\n\t\t\t\tAnimation alpha=AnimationUtils.loadAnimation(MainActivity.this,\n\t\t\t\t\t\tR.anim.alpha_animation);\n\t\t\t\ttv.startAnimation(alpha);\n\t\t\t}", "protected void fading(float alpha) { }", "public void startAnimation() {\n animationStart = System.currentTimeMillis();\n }", "void updateText(int c) {\n postInvalidate();\n }", "@Override\n public void run() {\n MaterialAnimator.animate(Transition.ZOOMOUT, btnFAB, 1000);\n btnFAB.setVisibility(Style.Visibility.HIDDEN);\n btnFAB.setOpacity(0);\n\n // Setting the visibility of the music panel\n musicPanel.setVisibility(Style.Visibility.VISIBLE);\n musicPanel.setOpacity(1);\n\n // Setting the music label with Bounce up animation\n lblMusic.setText(\"Pharell Williams / Love Yourself to Dance\");\n MaterialAnimator.animate(Transition.BOUNCEINUP, lblMusic, 1000);\n\n // Setting the image of the artist\n imgMusic.setUrl(\"http://thatgrapejuice.net/wp-content/uploads/2013/08/pharrell-williams-that-grape-juice.png\");\n }", "public void doAnimateStep () {\n\t\tadvanceSimulation();\n\t\tpaint();\n\t}", "public void setText(String text) {\r\n\r\n\t}" ]
[ "0.674298", "0.6214041", "0.6101411", "0.6047159", "0.6017949", "0.5989827", "0.58265257", "0.58114636", "0.573465", "0.5662831", "0.5616491", "0.5595139", "0.55595416", "0.5521266", "0.5447695", "0.5445179", "0.54214853", "0.5414272", "0.5401287", "0.54010195", "0.53981245", "0.5385806", "0.53833926", "0.53315556", "0.53226566", "0.532214", "0.5275899", "0.5251839", "0.52498823", "0.52219045", "0.52115554", "0.5194728", "0.51552063", "0.5130678", "0.5119472", "0.51030684", "0.5071132", "0.5068039", "0.5035096", "0.5027998", "0.5021441", "0.50138474", "0.50067604", "0.49856064", "0.49690053", "0.49669635", "0.4962331", "0.49593407", "0.495559", "0.4948723", "0.4946163", "0.4932467", "0.4909404", "0.49068433", "0.48980427", "0.48968142", "0.48967254", "0.48785743", "0.48754352", "0.48707923", "0.48637724", "0.48635697", "0.4862831", "0.48622632", "0.48548162", "0.48453066", "0.4844033", "0.48406804", "0.4838334", "0.48370117", "0.4817928", "0.48131785", "0.4808878", "0.48030955", "0.48014754", "0.4801177", "0.48000377", "0.47960237", "0.47896528", "0.4788156", "0.4779672", "0.4774644", "0.47718775", "0.47689205", "0.476048", "0.47351286", "0.47282577", "0.4723194", "0.47203392", "0.47040287", "0.4702663", "0.47018975", "0.46932787", "0.4683934", "0.46793765", "0.4673162", "0.46706998", "0.4669549", "0.46640572", "0.4660219" ]
0.81218314
0
Moves the platforms position by accesing its parent
@Override public void update() { update(Pong.STANDARD_FRAMETIME); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void moveplatform()\r\n\t{\r\n\t\tfor (Platforms platform : platforms)\r\n\t\t{\r\n\t\t\tif (platforms.indexOf(platform)==0 || platforms.indexOf(platform)==3 || platforms.indexOf(platform)==6 || platforms.indexOf(platform)==9)\r\n\t\t\t{\r\n\t\t\t\tif (platform.getXCord() == 6 )\r\n\t\t\t\t{\r\n\t\t\t\t\tchangeDirection = 1;\r\n\t\t\t\t}\r\n\t\t\t\tif (platform.getXCord() == 0)\r\n\t\t\t\t{\r\n\t\t\t\t\tchangeDirection = 0;\r\n\t\t\t\t}\r\n\t\t\t\tchangeDir(platform);\r\n\t\t\t}\r\n\t\t\tif (platforms.indexOf(platform)==1 ||platforms.indexOf(platform)==4 ||platforms.indexOf(platform)== 7 || platforms.indexOf(platform)== 10)\r\n\t\t\t{\r\n\t\t\t\tif (platform.getXCord() == 7 )\r\n\t\t\t\t{\r\n\t\t\t\t\tchangeDirection = 1;\r\n\t\t\t\t}\r\n\t\t\t\tif (platform.getXCord() == 1)\r\n\t\t\t\t{\r\n\t\t\t\t\tchangeDirection = 0;\r\n\t\t\t\t}\r\n\t\t\t\tchangeDir(platform);\r\n\t\t\t}\r\n\t\t\tif (platforms.indexOf(platform)==2 || platforms.indexOf(platform)==5 || platforms.indexOf(platform)== 8 || platforms.indexOf(platform)== 11)\r\n\t\t\t{\r\n\t\t\t\tif (platform.getXCord() == 8 )\r\n\t\t\t\t{\r\n\t\t\t\t\tchangeDirection = 1;\r\n\t\t\t\t}\r\n\t\t\t\tif (platform.getXCord() == 2)\r\n\t\t\t\t{\r\n\t\t\t\t\tchangeDirection = 0;\r\n\t\t\t\t}\r\n\t\t\t\tchangeDir(platform);\r\n\t\t\t}\r\n\t\t\t//Other\r\n\t\t\tif (platforms.indexOf(platform)==12 || platforms.indexOf(platform)==15 || platforms.indexOf(platform)==18 || platforms.indexOf(platform)==21)\r\n\t\t\t{\r\n\t\t\t\tif (platform.getXCord() == 6)\r\n\t\t\t\t{\r\n\t\t\t\t\tchangeDirectionReverse = 1;\r\n\t\t\t\t}\r\n\t\t\t\tif (platform.getXCord() == 0)\r\n\t\t\t\t{\r\n\t\t\t\t\tchangeDirectionReverse = 0;\r\n\t\t\t\t}\r\n\t\t\t\tchangeDirReverse(platform);\r\n\t\t\t}\r\n\t\t\tif (platforms.indexOf(platform)==13 || platforms.indexOf(platform)==16 || platforms.indexOf(platform)==19 || platforms.indexOf(platform)==22)\r\n\t\t\t{\r\n\t\t\t\tif (platform.getXCord() == 7)\r\n\t\t\t\t{\r\n\t\t\t\t\tchangeDirectionReverse = 1;\r\n\t\t\t\t}\r\n\t\t\t\tif (platform.getXCord() == 1)\r\n\t\t\t\t{\r\n\t\t\t\t\tchangeDirectionReverse = 0;\r\n\t\t\t\t}\r\n\t\t\t\tchangeDirReverse(platform);\r\n\t\t\t}\r\n\t\t\tif (platforms.indexOf(platform)==14 || platforms.indexOf(platform)==17 || platforms.indexOf(platform)==20 || platforms.indexOf(platform)==23)\r\n\t\t\t{\r\n\t\t\t\tif (platform.getXCord() == 8)\r\n\t\t\t\t{\r\n\t\t\t\t\tchangeDirectionReverse = 1;\r\n\t\t\t\t}\r\n\t\t\t\tif (platform.getXCord() == 2)\r\n\t\t\t\t{\r\n\t\t\t\t\tchangeDirectionReverse = 0;\r\n\t\t\t\t}\r\n\t\t\t\tchangeDirReverse(platform);\r\n\t\t\t}\r\n\t\t}\r\n\t}", "public void act() \n {\n // Add code to move platforms if right key is pressed\n if( Greenfoot.isKeyDown(\"right\") )\n {\n move(-1);\n }\n \n // Add code to remove platforms if it's x coordinate is < 0\n if( getX() < 0 )\n {\n getWorld().removeObject(this);\n }\n \n }", "public void moving()\n {\n if(onPlatform()&&endPlatform()){\n direction();\n }\n if(onPlatform()&&!endPlatform()){\n changeDirection();\n direction();\n }\n collideMoveLocation(horzVelocity,1);\n //sharaz\n if(isTouching(PushObject.class)){\n changeDirection();\n direction();\n }\n \n \n }", "private void moveAround()\n {\n if(getY()>75)\n {\n setRotation(270);\n }\n else if(getX()<75)\n {\n setRotation(0);\n }\n else if (getX()>getWorld().getWidth()-50)\n {\n setRotation(180);\n }\n else if (isTouching(Player.class))\n {\n Actor actor = getOneIntersectingObject(Player.class);\n turnTowards(actor.getX(), actor.getY());\n turn(180);\n }\n else if(Greenfoot.getRandomNumber(100) < 3)\n {\n setRotation(Greenfoot.getRandomNumber(360));\n }\n move(1);\n }", "public void move() {\n\t\tGrid<Actor> gr = getGrid();\n\t\tif (gr == null) {\n\t\t\treturn;\n\t\t}\n\t\tLocation loc = getLocation();\n\t\tLocation next = loc.getAdjacentLocation(getDirection());\n\t\t\n\t\tLocation next2 = next.getAdjacentLocation(getDirection());\n\t\tif (gr.isValid(next2)) {\n\t\t\tmoveTo(next2);\n\t\t} else {\n\t\t\tremoveSelfFromGrid();\n\t\t}\n\t}", "@Override\n public void doMove() {\n if (((-Transform.getOffsetTranslation().getX() - (Game.getWindowWidth()) < getPosition().getX()\n && (-Transform.getOffsetTranslation().getX() + (Game.getWindowWidth() * 2)) > getPosition().getX()\n && (-Transform.getOffsetTranslation().getY() - (Game.getWindowHeight())) < getPosition().getY()\n && (-Transform.getOffsetTranslation().getY() + (Game.getWindowHeight() * 2)) > getPosition().getY()))) {\n addPosition(new Vector(Velocity).mult(Game.getDelta()));\n } else {\n Level().RemoveObject(this);\n }\n }", "@Override\n\tpublic void moveXUnder(XAxisNode newXParent) {\n\t}", "protected void internalMove(IMoveShapeContext context) {\n \t\tShape shapeToMove = context.getShape();\n \t\tContainerShape oldContainerShape = context.getSourceContainer();\n \t\tContainerShape newContainerShape = context.getTargetContainer();\n \n \t\tint x = context.getX();\n \t\tint y = context.getY();\n \n \t\tif (oldContainerShape != newContainerShape) {\n \t\t\t// the following is a workaround due to an MMR bug\n \t\t\tif (oldContainerShape != null) {\n \t\t\t\tCollection<Shape> children = oldContainerShape.getChildren();\n \t\t\t\tif (children != null) {\n \t\t\t\t\tchildren.remove(shapeToMove);\n \t\t\t\t}\n \t\t\t}\n \n \t\t\tshapeToMove.setContainer(newContainerShape);\n \t\t\tif (shapeToMove.getGraphicsAlgorithm() != null) {\n \t\t\t\tGraphiti.getGaService().setLocation(shapeToMove.getGraphicsAlgorithm(), x, y,\n \t\t\t\t\t\tavoidNegativeCoordinates());\n \t\t\t}\n \t\t} else { // move within the same container\n \t\t\tif (shapeToMove.getGraphicsAlgorithm() != null) {\n \t\t\t\tGraphiti.getGaService().setLocation(shapeToMove.getGraphicsAlgorithm(), x, y,\n \t\t\t\t\t\tavoidNegativeCoordinates());\n \t\t\t}\n \t\t}\n \t}", "public void moveEverythingALittle(){\n //ponieważ wszystko idealnie jest zsynchronizowane to else nie wykona sie gdy current = getDestination\n if(player.getCurrentX()<player.getDestinationX())\n player.currentX += 1;\n else if(player.getCurrentX()>player.getDestinationX())\n player.currentX -= 1;\n\n if( player.getCurrentY()<player.getDestinationY())\n player.currentY += 1;\n else if( player.getCurrentY()>player.getDestinationY())\n player.currentY -= 1;\n\n for(int i = 0; i < boxes.size(); i++){\n Box item = boxes.get(i);\n if(item.getCurrentX()<item.getDestinationX())\n item.currentX += 1;\n else if(item.getCurrentX()>item.getDestinationX())\n item.currentX -= 1;\n\n if( item.getCurrentY()<item.getDestinationY())\n item.currentY += 1;\n else if ( item.getCurrentY()>item.getDestinationY())\n item.currentY -= 1;\n }\n }", "public void move() {\n\t\tthis.hero.setPF(1);\n\t\tthis.hero.setState(this.hero.getMoved());\n\t}", "public void move() {\n\t\tmoveX();\n\t\tmoveY();\n\t}", "public void move(){\n super.move();\n if(getX() >= Main.WIDTH - getWidth() * 1.5) {\n setDirection(-1);\n } else if(getX() <= 50) {\n setDirection(1);\n }\n }", "private void move() {\n\n if(currentPosition.getX() == -1 && currentPosition.getY() == -1) {\n System.out.println(\"Robot is not placed, yet.\");\n return;\n }\n\n Position.Direction direction = currentPosition.getDirection();\n int newX = -1;\n int newY = -1;\n switch (direction) {\n case EAST:\n newX = currentPosition.getX() + 1;\n newY = currentPosition.getY();\n break;\n case WEST:\n newX = currentPosition.getX() - 1;\n newY = currentPosition.getY();\n break;\n case NORTH:\n newX = currentPosition.getX();\n newY = currentPosition.getY() + 1;\n break;\n case SOUTH:\n newX = currentPosition.getX();\n newY = currentPosition.getY() - 1;\n break;\n }\n\n if(newX < lowerBound.getX() || newY < lowerBound.getY()\n || newX > upperBound.getX() || newY > upperBound.getY()) {\n System.out.println(\"Cannot move to \" + direction);\n return;\n }\n\n currentPosition.setX(newX);\n currentPosition.setY(newY);\n }", "@Override\n protected void execute() \n {\n move(Robot.oi.mechJoystick);\n }", "public void move() {\n\n\tGrid<Actor> gr = getGrid();\n\tif (gr == null) {\n\n\t return;\n\t}\n\n\tLocation loc = getLocation();\n\tif (gr.isValid(next)) {\n\n\t setDirection(loc.getDirectionToward(next));\n\t moveTo(next);\n\n\t int counter = dirCounter.get(getDirection());\n\t dirCounter.put(getDirection(), ++counter);\n\n\t if (!crossLocation.isEmpty()) {\n\t\t\n\t\t//reset the node of previously occupied location\n\t\tArrayList<Location> lastNode = crossLocation.pop();\n\t\tlastNode.add(next);\n\t\tcrossLocation.push(lastNode);\t\n\t\t\n\t\t//push the node of current location\n\t\tArrayList<Location> currentNode = new ArrayList<Location>();\n\t\tcurrentNode.add(getLocation());\n\t\tcurrentNode.add(loc);\n\n\t\tcrossLocation.push(currentNode);\t\n\t }\n\n\t} else {\n\t removeSelfFromGrid();\n\t}\n\n\tFlower flower = new Flower(getColor());\n\tflower.putSelfInGrid(gr, loc);\n\t\n\tlast = loc;\n\t\t\n }", "public void move(){\n\t\t\n\t}", "public void changeDir(Platforms platform)\r\n\t{\r\n\t\tif (changeDirection==0)\r\n\t\t{\r\n\t\t\t//TextBasedPart\r\n\t\t\tplatform.setXCord(platform.getXCord()+1);\r\n\t\t}\r\n\t\tif(changeDirection==1)\r\n\t\t{\r\n\t\t\tplatform.setXCord(platform.getXCord()-1);\r\n\t\t}\r\n\t}", "private void move() {\n\t\t\tangle += Math.PI/24;\n\t\n\t\t\tcow.locX = Math.sin(angle) * 2.5 + player.getLocation().getX();\n\t\t\tcow.locZ = Math.cos(angle) * 2.5 + player.getLocation().getZ();\n\t\t\t\n\t\t\tLocation loc = new Location(player.getWorld(), cow.locX, player.getLocation().getY() + 1.5, cow.locZ);\n\t\t\tloc.setDirection(player.getLocation().subtract(loc).toVector()); //Look at the player\n\t\t\t\n\t\t\tPacketHandler.teleportFakeEntity(player, cow.getId(), loc);\n\t\t}", "@Override\r\n public void move(int deltaX, int deltaY) {\r\n\r\n for(IShape shape : children) {\r\n shape.move(deltaX,deltaY);\r\n }\r\n }", "public void move() {\n this.pposX = this.posX;\n this.pposY = this.posY;\n this.posX = newPosX;\n this.posY = newPosY;\n }", "public void move() {\n\t\t// Override move so we don't move, then get location set by owner.\n\t}", "@Override\n void move(int ScreenHeight, int ScreenWidth) {\n turnAround();\n moveRightLeft(ScreenWidth);\n moveUpDown(ScreenHeight);\n }", "@Override\n public void mouseDragged(MouseEvent e) {\n int thisX = parent.getLocation().x;\n int thisY = parent.getLocation().y;\n\n // Determine how much the mouse moved since the initial click\n int xMoved = (thisX + e.getX()) - (thisX + initialClick.x);\n int yMoved = (thisY + e.getY()) - (thisY + initialClick.y);\n\n // Move window to this position\n int X = thisX + xMoved;\n int Y = thisY + yMoved;\n parent.setLocation(X, Y);\n }", "public void move() {\r\n\t\tthis.swim();\r\n\t\tthis.swim();\r\n\t\tthis.swim();\r\n\t\tthis.swim();\r\n\t\tthis.swim();\r\n\t\tthis.swim();\r\n\t\tthis.swim();\r\n\t\tthis.swim();\r\n\t\tthis.swim();\r\n\t\tthis.swim();\r\n\t}", "public void move() {\n\r\n\t}", "public void movePlayer(String nomeArq, int px, int py) {\r\n if(Main.player1.Vez()) {\r\n if(nomeArq.equals(Main.PLAYER_LEFT)){\r\n \tMain.player1.MudaLado(true,false);\r\n }\r\n else {\r\n \tMain.player1.MudaLado(false,true);\r\n } \r\n pos = Main.player1.Position();\r\n int x = pos[0]+px;\r\n int y = pos[1];\r\n double t = 0.1;\r\n int OrigemY = y;\r\n double g=10;\r\n if(andar.BatidaFrente(x,y,Main.player1.Size()[0]+1,Main.player1.Size()[1]+1)==false) {\r\n \tMain.player1.NovaPosition(x,y); \r\n }\r\n Main.Fase.repinta(); \r\n while(andar.temChao(x,y,Main.player1.Size()[0]+1,Main.player1.Size()[1]+1)==false && andar.Paredao((int)x,(int)y,Main.player1.Size()[0],Main.player1.Size()[1])==false)\r\n {\r\n \tMain.player1.NovaPosition(x,y);\r\n \tMain.Fase.repinta(); \r\n y = (int)(OrigemY - (0-(g * (t*t))/2.0));\r\n t = t + 0.1; \r\n }\r\n Main.Fase.repinta(); \r\n }\r\n else {\r\n if(nomeArq.equals(Main.PLAYER_LEFT)) {\r\n \tMain.player2.MudaLado(true,false);\r\n }\r\n else {\r\n \tMain.player2.MudaLado(false,true);\r\n } \r\n pos = Main.player2.Position();\r\n int x = pos[0]+px;\r\n int y = pos[1];\r\n double t = 0;\r\n int OrigemY = y;\r\n double g=10;\r\n if(andar.BatidaFrente(x,y,Main.player2.Size()[0]+1,Main.player2.Size()[1]+1)==false) {\r\n \tMain.player2.NovaPosition(x,y); \r\n }\r\n Main.Fase.repinta(); \r\n while(andar.temChao(x,y,Main.player2.Size()[0]+1,Main.player2.Size()[1]+1)==false && andar.Paredao((int)x,(int)y,Main.player2.Size()[0]+1,Main.player2.Size()[1]+1)==false)\r\n {\r\n \tMain.player2.NovaPosition(x,y);\r\n \tMain.Fase.repinta(); \r\n y = (int)(OrigemY - (0-(g * (t*t))/2.0));\r\n t = t + 0.1; \r\n }\r\n }\r\n }", "@Override\r\n\t\t\tpublic void mouseMove(MouseEvent e) {\n\t\t\t\tif(x>0)\r\n\t\t\t\t{\r\n\t\t\t\t\tshell.setLocation(e.x-x + shell.getLocation().x,\r\n\t\t\t\t\t\te.y-y + shell.getLocation().y);\r\n\t\t\t\t}\r\n\t\t\t}", "public void move() {\n if (!canMove) {\n return;\n }\n int moveX = currDirection == EAST ? PACE : currDirection == WEST ? -PACE : 0;\n int moveY = currDirection == NORTH ? PACE : currDirection == SOUTH ? -PACE : 0;\n if (grid == null || grid.isOutside(currX + moveX, currY + moveY)) {\n return;\n }\n currX += moveX;\n currY += moveY;\n }", "public void update() {\n\t\tactSX=parent.actSX*scaleX;\n\t\tactSY=parent.actSY*scaleY;\n\t\tw=posW*actSX;\n\t\th=posH*actSY;\n\t\tswitch (align) {\n\t\tcase DEFAULT:\n\t\t\tx=parent.x+posX*actSX;\n\t\t\ty=parent.y+posY*actSY;\n\t\t\tbreak;\n\t\tcase TOPRIGHT:\n\t\t\tx=parent.x+parent.w-(posX+posW)*actSX;\n\t\t\ty=parent.y+posY*actSY;\n\t\t\tbreak;\n\t\tcase BOTTOMLEFT:\n\t\t\tx=parent.x+posX*actSX;\n\t\t\ty=parent.y+parent.h-(posY+posH)*actSY;\n\t\t\tbreak;\n\t\tcase BOTTOMRIGHT:\n\t\t\tx=parent.x+parent.w-(posX+posW)*actSX;\n\t\t\ty=parent.y+parent.h-(posY+posH)*actSY;\n\t\t\tbreak;\n\t\tcase CENTEREDX:\n\t\t\tx=parent.x+parent.w/2-w/2+posX*actSX;\n\t\t\ty=parent.y+posY*actSY;\n\t\t\tbreak;\n\t\tcase CENTEREDY:\n\t\t\tx=parent.x+posX*actSX;\n\t\t\ty=parent.y+parent.h/2-h/2+posY*actSY;\n\t\t\tbreak;\n\t\tcase CENTEREDXY:\n\t\t\tx=parent.x+parent.w/2-w/2+posX*actSX;\n\t\t\ty=parent.y+parent.h/2-h/2+posY*actSY;\n\t\t\tbreak;\n\t\t}\n\t}", "@Override\n\tpublic void move(int xPos, int yPos) {\n\t}", "public void move() {\n\t\tif (!visible) {\r\n\t\t\thideTurtle();\r\n\t\t}\r\n\t}", "private void turnAround() {\r\n this.setCurrentDirection(-getCurrentDirection());\r\n }", "public void moveChild( ChildType child, int index );", "public void move() {\n float xpos = thing.getX(), ypos = thing.getY();\n int xdir = 0, ydir = 0;\n if (left) xdir -= SPEED; if (right) xdir += SPEED;\n if (up) ydir -= SPEED; if (down) ydir += SPEED;\n xpos += xdir; ypos += ydir;\n\n VeggieCopter game = thing.getGame();\n int w = game.getWindowWidth(), h = game.getWindowHeight();\n int width = thing.getWidth(), height = thing.getHeight();\n if (xpos < 1) xpos = 1; if (xpos + width >= w) xpos = w - width - 1;\n if (ypos < 1) ypos = 1; if (ypos + height >= h) ypos = h - height - 1;\n thing.setPos(xpos, ypos);\n }", "public void act(){\n // Removing object, if out of the simulated zone\n if (atWorldEdge()){\n getWorld().removeObject(this);\n return;\n }\n\n //Move Thanos up\n setLocation (getX(), getY() - speed);\n }", "public void go_to_base_position() {\n stop_hold_arm();\n Dispatcher.get_instance().add_job(new JMoveArm(RobotMap.Arm.pot_value_base, 0.9, 0.7, 0.7, 0.2, 0.8, false, false));\n // Extend the arm after getting to the base position\n Dispatcher.get_instance().add_job(new JRunnable(() -> Pneumatics.get_instance().set_solenoids(true), this));\n hold_arm();\n }", "public void startExecuting() {\n\t\t\tRandom random = this.parentEntity.getRNG();\n\t\t\tdouble d0 = this.parentEntity.posX + (double)((random.nextFloat() * 2.0F - 1.0F) * 16.0F);\n\t\t\tdouble d1 = this.parentEntity.posY + (double)((random.nextFloat() * 2.0F - 1.0F) * 16.0F);\n\t\t\tdouble d2 = this.parentEntity.posZ + (double)((random.nextFloat() * 2.0F - 1.0F) * 16.0F);\n\t\t\tthis.parentEntity.getMoveHelper().setMoveTo(d0, d1, d2, 0.3D);\n\t\t}", "public void move() {\n if(Objects.nonNull(this.position)) {\n Position position = this.getPosition();\n Function<Position, Position> move = moveRobotInDirectionMap.get(position.getDirection());\n this.position = move.apply(position);\n }\n }", "@Override\r\n public void mousePressed(MouseEvent e) {\n frame.addPlatform(e.getPoint());\r\n }", "@Override\n\tpublic void move() {\n\n\t}", "@Override\n public void movement() {\n if (isAlive()) {\n //Prüfung ob A oder die linke Pfeiltaste gedrückt ist\n if (Keyboard.isKeyDown(KeyEvent.VK_LEFT) || Keyboard.isKeyDown(KeyEvent.VK_A)) {\n //Änder die X Position um den speed wert nach link (verkleinert sie)\n setPosX(getPosX() - getSpeed());\n //Prüft ob der Spieler den linken Rand des Fensters erreicht hat\n if (getPosX() <= 0) {\n //Setzt die X Position des Spielers an den Rand des Fensters zurück\n setPosX(0);\n }\n }\n //Prüfung ob D oder die rechte Pfeiltaste gedrückt ist\n if (Keyboard.isKeyDown(KeyEvent.VK_RIGHT) || Keyboard.isKeyDown(KeyEvent.VK_D)) {\n //Änder die X Position um den speed wert nach rechts (vergrößert sie)\n setPosX(getPosX() + getSpeed());\n //Prüft ob der Spieler den rechten Rand des Fensters erreicht hat\n if (getPosX() >= Renderer.getWindowSizeX() - getWight() - 7) {\n //Setzt die X Position des Spielers an den Rand des Fensters zurück\n setPosX(Renderer.getWindowSizeX() - getWight() - 7);\n }\n }\n //Aktualsiert die Hitbox\n setBounds();\n }\n }", "private void move(double newXPos){\n this.setX(newXPos);\n }", "void move() {\r\n\t\tif (x + xa < 0){\r\n\t\t\txa = mov;\r\n\t\t\tgame.puntuacion++;\r\n\t\t}\r\n\t\telse if (x + xa > game.getWidth() - diameter){\r\n\t\t\txa = -mov;\r\n\t\t\tgame.puntuacion++;\r\n\t\t}\r\n\t\tif (y + ya < 0){\r\n\t\t\tya = mov;\r\n\t\t\tgame.puntuacion++;\r\n\t\t}\r\n\t\telse if (y + ya > game.getHeight() - diameter){\r\n\t\t\tgame.gameOver();\r\n\t\t\tgame.puntuacion++;\r\n\t\t}\r\n\t\tif (colisionPalas()){\r\n\t\t\tya = -mov;\r\n\t\t}\r\n\t\telse if(colisionEstorbos()){\r\n\t\t\tgame.puntuacion+=2;\r\n\t\t}\r\n\t\t\r\n\t\tx = x + xa;\r\n\t\ty = y + ya;\r\n\t}", "public void chasePlayer() {\n refreshObstructionMatrix();\n Coordinate currPosition = new Coordinate(getX(), getY());\n Player player = this.dungeon.getPlayer();\n Coordinate playerPosition = new Coordinate(player.getX(), player.getY());\n\n if (currPosition.equals(playerPosition)) {\n // Debug.printC(\"Enemy has reached the player!\", Debug.RED);\n player.useItem(this);\n } else {\n this.pathToDest = pathFinder.getPathToDest(currPosition, playerPosition);\n if (!this.pathToDest.empty()) {\n Coordinate nextPosition = this.pathToDest.pop();\n // this.setCoordinate(nextPosition);\n if (getX() + 1 == nextPosition.x) {\n moveRight();\n } else if (getX() - 1 == nextPosition.x) {\n moveLeft();\n } else if (getY() + 1 == nextPosition.y) {\n moveDown();\n } else if (getY() - 1 == nextPosition.y) {\n moveUp();\n }\n }\n }\n }", "private void move(){\n \n currentAnimation = idleDown;\n \n if(playerKeyInput.allKeys[VK_W]){\n int ty = (int) (objectCoordinateY - speed + bounds.y) / 16;\n \n if(!collisionDetection((int) (objectCoordinateX + bounds.x)/16, ty)){\n objectCoordinateY -= speed;\n currentAnimation = upWalk;\n }\n } \n \n if(playerKeyInput.allKeys[VK_S]){\n int ty = (int) (objectCoordinateY + speed + bounds.y + bounds.height) / 16;\n if(!collisionDetection((int) (objectCoordinateX + bounds.x)/16, ty)){\n objectCoordinateY += speed;\n currentAnimation = downWalk;\n }\n } \n \n if(playerKeyInput.allKeys[VK_A]){\n int tx = (int) (objectCoordinateX - speed + bounds.x) / 16;\n if(!collisionDetection(tx, (int) (objectCoordinateY + bounds.y)/16)){\n objectCoordinateX -= speed;\n currentAnimation = sideWalkLeft;\n }\n } \n \n if(playerKeyInput.allKeys[VK_D]){\n int tx = (int) (objectCoordinateX + speed + bounds.x + bounds.width) / 16;\n if(!collisionDetection(tx, (int) (objectCoordinateY + bounds.y)/16)){\n objectCoordinateX += speed;\n currentAnimation = sideWalkRight;\n }\n } \n \n if(playerKeyInput.allKeys[VK_E]){\n currentAnimation = pickUp;\n } \n }", "@Override\r\n\tpublic void move() {\n\r\n\t}", "@Override\n\tpublic void move() {\n\t\t\n\t}", "private void move() {\n resetUpdate();\n\n gameMessage.setSpace1(clientMessage.getSpace1());\n gameMessage.resetGameMessage();\n gameMessage.notify(gameMessage);\n\n\n if( liteGame.isWinner() ) endOfTheGame = true;\n }", "@Override\n \t\t\t\tpublic void doMove() {\n \n \t\t\t\t}", "@Override\r\n public void act() \r\n {\n int posx = this.getX();\r\n int posy = this.getY();\r\n //calculamos las nuevas coordenadas\r\n int nuevox = posx + incx;\r\n int nuevoy = posy + incy;\r\n \r\n //accedemos al mundo para conocer su tamaño\r\n World mundo = this.getWorld();\r\n if(nuevox > mundo.getWidth())//rebota lado derecho\r\n {\r\n incx = -incx;\r\n }\r\n if(nuevoy > mundo.getHeight())//rebota en la parte de abajo\r\n {\r\n incy = -incy;\r\n }\r\n \r\n if(nuevoy < 0)//rebota arriba\r\n {\r\n incy = -incy;\r\n }\r\n if(nuevox < 0)//rebota izquierda\r\n {\r\n incx = -incx;\r\n }\r\n //cambiamos de posicion a la pelota\r\n this.setLocation(nuevox,nuevoy);\r\n }", "public void movement() {\n\n\t\t// If the player wants to move left ie presses 'a' key..\n\t\tif (spaceInvadersGame.getKeyManager().left) {\n\n\t\t\t// If the player is on the left bound of the window do not move.\n\t\t\tif (xPosition <= 0) {\n\n\t\t\t\t// Move the player's xPosition left.\n\t\t\t} else {\n\t\t\t\txPosition -= playerSpeed;\n\t\t\t}\n\n\t\t} else if (spaceInvadersGame.getKeyManager().right) {\n\t\t\tif (xPosition >= 500 - width) {\n\n\t\t\t} else {\n\t\t\t\txPosition += playerSpeed;\n\t\t\t}\n\t\t}\n\t}", "public void move() {\r\n posX += movementX;\r\n posY += movementY;\r\n anchorX += movementX;\r\n anchorY += movementY;\r\n }", "public abstract void move(Position position);", "public void relocateToPoint(boolean isUserClick){\n// System.out.println(\"Scene x: \"+point.getX()+\", y: \"+point.getY());\n// System.out.println(\"Local x: \"+getParent().sceneToLocal(point).getX()+\", y: \"+getParent().sceneToLocal(point).getY());\n// System.out.println(\"Relocate x: \"+(getParent().sceneToLocal(point).getX() - (getWidth() / 2))+\", y: \"+(getParent().sceneToLocal(point).getY() - (getHeight() / 2)));\n// System.out.println(getBoundsInLocal().getWidth());\n// System.out.println(widthProperty());\n\n if (isUserClick) {\n double new_x=getParent().sceneToLocal(x,y).getX();\n double new_y=getParent().sceneToLocal(x,y).getY();\n setX(new_x);\n setY(new_y);\n relocate(\n// (getParent().sceneToLocal(x,y).getX() - (widthCountry / 2)),\n// (getParent().sceneToLocal(x,y).getY() - (heightCountry / 2))\n new_x,new_y\n );\n } else {\n relocate(x,y);\n }\n\n\n }", "private void moveMonsters() {\r\n\t\tfor (AreaOrMonster obj : areas) {\r\n\t\t\tif(obj.getLeftRight()) {\r\n\t\t\t\tif(!pirate1.currentLocation.equals(new Point(obj.getX()+1, obj.getY())) && !pirate2.currentLocation.equals(new Point(obj.getX()+1, obj.getY()))) {\r\n\t\t\t\t\tobj.move();\r\n\t\t\t\t\tobj.getImageView().setX(obj.getX() * scalingFactor);\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\telse {\r\n\t\t\t\tif(!pirate1.currentLocation.equals(new Point(obj.getX()-1, obj.getY())) && !pirate2.currentLocation.equals(new Point(obj.getX()-1, obj.getY()))) {\r\n\t\t\t\t\tobj.move();\r\n\t\t\t\t\tobj.getImageView().setX(obj.getX() * scalingFactor);\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t}", "@Override\n\tpublic void moveYUnder(YAxisNode newXParent) {\n\t}", "@Override\n public void onMove(boolean absolute) {\n \n }", "@Override\n\tpublic void move() {\n\t}", "public void moveUp()\n\t{\n\t\tthis.grid.moveUp();\n\t}", "public void moveX(){\n\t\tfor(int i = 0; i < level.solids.size(); i++){\n\t\t\tBlock solid = level.solids.get(i);\n\t\t\tif(solid != this && isColliding(solid, x, y)){\n\t\t\t\tif(solid.type.equals(\"Projectile\") && this.type.equals(\"Projectile\")){\n\t\t\t\t\tPlayer parent = ((Projectile)this).parent;\n\t\t\t\t\tPlayer other = ((Projectile)solid).parent;\n\n\t\t\t\t\tif(parent != other){ \n\t\t\t\t\t\tstun(parent);\n\t\t\t\t\t\tstun(other);\n\t\t\t\t\t}\n\n\t\t\t\t\tlevel.solids.remove(this);\n\t\t\t\t\tlevel.solids.remove(solid);\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t\telse if(solid.type.equals(\"Hitbox\")){\n\t\t\t\t\tif(solid != parent.hitbox){\n\t\t\t\t\t\tdouble dist = Math.abs(solid.x - this.x);\n\t\t\t\t\t\tfor(int n = 1; n <= dist && !isColliding(solid, x + Math.signum(velX), y) && Math.signum(velX) != 0; n++){\n\t\t\t\t\t\t\tx += Math.signum(velX);\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\trelativeX += velX;\n\t\tvelX += accelX;\n\t\tx = (float) (parent.x + parent.hitbox.width / 2.0 + relativeX); //start it at the center of the player's hitbox, then move to its relative x\n\t}", "private void moveSiblings(NodeAlignment newAlignment, List<GeoMindMapNode> childGeos,\n\t\t\tList<DrawMindMap> children) {\n\t\tint spaceGained = decreaseDistanceBetweenChildren(newAlignment, children);\n\n\t\tif (newAlignment.isVertical()) {\n\t\t\tdouble toMove = marginLeft(newAlignment, children.size())\n\t\t\t\t\t+ GeoMindMapNode.MIN_WIDTH - spaceGained;\n\t\t\tMoveGeos.moveObjects(childGeos, new Coords(-view.getInvXscale() * toMove / 2, 0, 0),\n\t\t\t\t\tnull, null, view);\n\t\t} else {\n\t\t\tdouble toMove = marginTop(newAlignment, children.size())\n\t\t\t\t\t+ GeoMindMapNode.CHILD_HEIGHT - spaceGained;\n\t\t\tMoveGeos.moveObjects(childGeos, new Coords(0, view.getInvYscale() * toMove / 2, 0),\n\t\t\t\t\tnull, null, view);\n\t\t}\n\t}", "public void move() {\n super.move(DIRECTION.getRandom());\n }", "private void moveMhos() {\n\t\tmoveAllignedMhos();\n\t\tmoveDiagonalMhos();\n\t\tmoveHorizontalMhos();\n\t\tmoveVerticalMhos();\n\t\tmoveRemainingMhos();\n\t\tupdateMhoLocationList();\n\t}", "@Override\n public void moveGlobalLowerLeft(Point p, World world) {\n TileContainer oldContainer = this.getSuperContainer();\n super.moveGlobalLowerLeft(p, world);\n if (!getSuperContainer().equals(oldContainer)) {\n oldContainer.removeElement(this);\n this.getSuperContainer().addElement(this);\n }\n }", "public void move() {\r\n\t\tsetY(getY() + 134);\r\n\t\tmyImage = myImage.getScaledInstance(100, 300, 60);\r\n\r\n\t}", "public void move()\n {\n universe.erase(this);\n \n // compute new position\n \n yPosition += ySpeed;\n xPosition += xSpeed;\n\n // check if it has hit the ground\n if(yPosition >= (groundPosition - diameter) && ySpeed > 0) {\n yPosition = groundPosition - diameter;\n ySpeed = -ySpeed; \n }\n // check if top\n if(yPosition <= 0 && ySpeed < 0){\n ySpeed = -ySpeed; \n }\n //check right\n if(xPosition >= (universe.getLength() - diameter) && xSpeed >0){\n xSpeed = -xSpeed;\n }\n //check left\n if(xPosition <= 0 && xSpeed < 0){\n xSpeed = -xSpeed;\n }\n \n // draw again at new position\n universe.draw(this);\n }", "private void movePlayer() {\r\n\t\tshipImageView.setX(ship.getCurrentLocation().x * scalingFactor);\r\n\t\tshipImageView.setY(ship.getCurrentLocation().y * scalingFactor);\r\n\t\tship.notifyObservers();\r\n\t}", "@Override\n public void move () {\n }", "public void move() {\n\t\t// tolerance of angle at which the Base starts moving\n\t\tint tolerance = 10;\n\t\tif(Math.abs(angle) < Math.abs(angleDesired)+tolerance && Math.abs(angleDesired)-tolerance < Math.abs(angle)) {\n\t\t\tdouble vX = Math.cos(Math.toRadians(this.angle + 90)) * v;\n\t\t\tdouble vY = Math.sin(Math.toRadians(this.angle + 90)) * v;\n\t\t\t\n\t\t\tthis.x += vX;\n\t\t\tthis.y += vY;\t\n\t\t\tthis.rectHitbox = new Rectangle((int)(x-rectHitbox.width/2),(int)(y-rectHitbox.height/2),rectHitbox.width,rectHitbox.height);\n\t\t}\n\t\t// curTargetPathBoardRectangle\n\t\tRectangle curTPBR = pathBoardRectangles.get(curTargetPathCellIndex).rect;\n\t\tRectangle rectSmallerBR = new Rectangle((int)curTPBR.getCenterX()-5,(int)curTPBR.getCenterY()-5,10,10);\n\t\t// updates the index when it crosses a pathCell so it counts down from pathCell to pathCell,\n\t\t// always having the next pathCell in the array as the target until the end is reached then it stops\n\t\tif(rectSmallerBR.contains(new Point((int)x,(int)y))) {\n\t\t\tif(curTargetPathCellIndex < pathBoardRectangles.size()-1) {\n\t\t\t\tcurTargetPathCellIndex++;\n\t\t\t\tparentGP.boardRect = pathBoardRectangles.get(curTargetPathCellIndex-1);\n\t\t\t\ttAutoDirectionCorrection.restart();\n\t\t\t}else {\n\t\t\t\tparentGP.isMoving = false;\n\t\t\t\tparentGP.boardRect = pathBoardRectangles.get(curTargetPathCellIndex);\n\t\t\t\tpathBoardRectangles.clear();\n\t\t\t\ttAutoDirectionCorrection.stop();\n\t\t\t\tStagePanel.tryCaptureGoldMine(parentGP);\n\t\t\t}\n\t\t}\n\t}", "void moveElement(int elementId, double xCoordinate, double yCoordinate);", "@Override\n protected void moveOver(){\n incrementXPos(getWidth()/2);\n if(pointUp){\n incrementYPos(-1*getHeight());\n } else {\n incrementYPos(getHeight());\n }\n incrementCol();\n setPointDirection();\n }", "public void moveObjects() {\n // move ball and paddles\n ball.moveBall();\n playerOnePaddle.movePaddle();\n playerTwoPaddle.movePaddle();\n }", "@FXML\n private void move() {\n TranslateTransition transition = new TranslateTransition();\n transition.setNode(move);\n transition.setDuration(Duration.seconds(1.5));\n transition.setFromX(-1000);\n transition.setToX(1000);\n transition.setAutoReverse(true);\n transition.setCycleCount(Timeline.INDEFINITE);\n transition.play();\n }", "public void move() {\n\t\tGrid<Actor> gr = getGrid();\n\t\tif (gr == null) {\n\t\t\treturn;\n\t\t}\n\t\tLocation loc = getLocation();\n\t\tif (gr.isValid(next)) {\n\t\t\tsetDirection(getLocation().getDirectionToward(next));\n\t\t\tmoveTo(next);\n\t\t} else {\n\t\t\tremoveSelfFromGrid();\n\t\t}\n\t\tFlower flower = new Flower(getColor());\n\t\tflower.putSelfInGrid(gr, loc);\n\t}", "public static void changePosition() {\n int direction;\n int speed;\n int newTopX;\n int newTopY;\n\n for (int i = 0; i < numShapes; ++i) {\n direction = moveDirection[i];\n speed = moveSpeed[i];\n newTopX = xTopLeft[i];\n newTopY = yTopLeft[i];\n\n //the switch uses the direction the speed should be applied to in order to find the new positions\n switch (direction) {\n case 0 -> {\n newTopX = newTopX - (speed);\n xTopLeft[i] = newTopX;\n }\n //upper left 135 degrees\n case 1 -> {\n newTopX = newTopX - (speed);\n xTopLeft[i] = newTopX;\n newTopY = newTopY - (speed);\n yTopLeft[i] = newTopY;\n }\n case 2 -> {\n newTopY = newTopY - (speed);\n yTopLeft[i] = newTopY;\n }\n //upper right 45 degrees\n case 3 -> {\n newTopX = newTopX + (speed);\n xTopLeft[i] = newTopX;\n newTopY = newTopY - (speed);\n yTopLeft[i] = newTopY;\n }\n case 4 -> {\n newTopX = newTopX + (speed);\n xTopLeft[i] = newTopX;\n }\n //bottom right 315 degrees\n case 5 -> {\n newTopX = newTopX + (speed);\n xTopLeft[i] = newTopX;\n newTopY = newTopY + (speed);\n yTopLeft[i] = newTopY;\n }\n case 6 -> {\n newTopY = newTopY + (speed);\n yTopLeft[i] = newTopY;\n }\n //bottom left 225 degrees\n case 7 -> {\n newTopX = newTopX - (speed);\n xTopLeft[i] = newTopX;\n newTopY = newTopY + (speed);\n yTopLeft[i] = newTopY;\n }\n }\n }\n }", "public void move (long delta){\r\n\r\n super.move(delta);\r\n }", "public void move();", "public void move();", "@Override\r\n\tprotected void onMove() {\n\t\t\r\n\t}", "public void Move()\n {\n this.x += this.speed;\n\n //Cutoff the position\n if (this.x <= 2)\n {\n this.x = 2;\n }\n else if (this.x >= GameConstants.SCREEN_WIDTH - 2 * this.imageWidth)\n {\n this.x = GameConstants.SCREEN_WIDTH - 2 * this.imageWidth;\n }\n }", "public void setPlayerPosition(Player player) {\n if (player.getPositionX() < 0 && (player.getPositionY() > screenHeight / 2 - doorSize && player.getPositionY() < screenHeight / 2 + doorSize)) {\n //left exit to right entry\n player.position.x = screenWidth - wallSize - player.getRadius();\n player.position.y = player.getPositionY();\n } else if ((player.getPositionX() > screenWidth / 2 - doorSize && player.getPositionX() < screenWidth / 2 + doorSize) && player.getPositionY() < 0) {\n //top exit to bottom entry\n player.position.x = player.getPositionX();\n player.position.y = screenHeight - wallSize - player.getRadius();\n } else if (player.getPositionX() > screenWidth && (player.getPositionY() > screenHeight / 2 - doorSize && player.getPositionY() < screenHeight / 2 + doorSize)) {\n //right exit to left entry\n player.position.x = wallSize + player.getRadius();\n player.position.y = player.getPositionY();\n } else {\n //bottom exit to top entry\n player.position.x = player.getPositionX();\n player.position.y = wallSize + player.getRadius();\n }\n }", "public void change_hero_pos() {\n\t\tif (labirinto.getLab()[heroi.getX_coord()][heroi.getY_coord()] == 'O')\n\t\t\theroi.setShielded(true);\n\t\tif (heroi.isArmado())\n\t\t\tlabirinto.setLabCell(heroi.getX_coord(), heroi.getY_coord(), 'A');\n\t\telse\n\t\t\tlabirinto.setLabCell(heroi.getX_coord(), heroi.getY_coord(), 'H');\n\t}", "void moveEast() {\n xpos = xpos + xspeed;\n if (xpos > width){\n xpos = 0; // 30\n }\n }", "public abstract void move(int newXPosition, int newYPosition, PiecePosition position) throws BoardException;", "void setPlayerXRelative(int x) {\n }", "public void move() {\n\t\tdouble xv = 0;\r\n\t\tdouble yv = 0;\r\n\t\t//this method allows the entity to hold both up and down (or left and right) and not move. gives for smooth direction change and movement\r\n\t\tif (moveRight) {\r\n\t\t\txv+=getSpeed();\r\n\t\t\torientation = Orientation.EAST;\r\n\t\t}\r\n\t\tif (moveLeft) {\r\n\t\t\txv-=getSpeed();\r\n\t\t\torientation = Orientation.WEST;\r\n\t\t}\r\n\t\tif (moveUp)\r\n\t\t\tyv-=getSpeed();\r\n\t\tif (moveDown)\r\n\t\t\tyv+=getSpeed();\r\n\t\tif (!doubleEquals(xv,0) || !doubleEquals(yv,0)) {\r\n\t\t\t((Player)this).useMana(0.1);\r\n\t\t\tImageIcon img = new ImageIcon(\"lib/assets/images/fireball.png\");\r\n\t\t\tBufferedImage image = new BufferedImage(32,32,BufferedImage.TYPE_INT_ARGB);\r\n\t\t\tGraphics g = image.getGraphics();\r\n\t\t\tg.drawImage(img.getImage(), 0, 0, image.getWidth(), image.getHeight(), null);\r\n\t\t\tColor n = loop[ind%loop.length];\r\n\t\t\tind++;\r\n\t\t\timage = ImageProcessor.scaleToColor(image, n);\r\n\t\t\t//PopMessage.addPopMessage(new PopMessage(image,getX(),getY()));\r\n\t\t}\r\n\t\telse\r\n\t\t\t((Player)this).useMana(-0.1);\r\n\t\tmove(xv,yv);\r\n\t}", "public void processCamera() {\n\t\tif (Mario.getX() > 300) {\n\t\t\tlevelCompound.move(-Mario.xVel, 0);\n\t\t\tPhysics.moveHitboxes(-Mario.xVel, 0);\n\t\t\tPhysics.moveEnemies(-Mario.xVel, 0);\n\t\t\tMario.setLocation(299, Mario.getY());\n\n\t\t\tlevelCompound.move(-3, 0);\n\t\t\tPhysics.moveHitboxes(-3, 0);\n\t\t\tPhysics.moveEnemies(-3, 0);\n\t\t}\n\t}", "@Override\n\tpublic void update() {\n\t\tmove();\n\t\tplace();\n\t}", "public void moveLeft() {\n locX = locX - 1;\n }", "private void updatePosition(){\n updateXPosition(true);\n updateYPosition(true);\n }", "public void moveUp() {\n locY = locY + 1;\n }", "public void go_to_switch_position() {\n stop_hold_arm();\n Dispatcher.get_instance().add_job(new JMoveArm(RobotMap.Arm.pot_value_switch, 0.9, 0.7, 0.7, 0.2, 0.8, false, false));\n hold_arm();\n }", "public void move() {\n for (int i = 0; i < Vampiro.getNumVamp(); i++) {\n\n lista[i].move();\n }\n }", "public void move() {\n\t\tthis.position.stepForwad();\n\t\tthis.position.spin();\n\t}", "public abstract void move();", "public abstract void move();", "public abstract void move();", "public abstract void move();", "public abstract void move();", "public abstract void move();", "public abstract void move();" ]
[ "0.7133848", "0.64479625", "0.61261094", "0.59907824", "0.5982865", "0.59753126", "0.59578013", "0.5946574", "0.5930666", "0.59257495", "0.589286", "0.58881396", "0.5879715", "0.58361083", "0.58337086", "0.58303076", "0.5826981", "0.5801316", "0.57979774", "0.5794723", "0.57681644", "0.57565564", "0.5751334", "0.57403564", "0.5733547", "0.57279396", "0.57177883", "0.5705917", "0.56892776", "0.56865203", "0.5679278", "0.567651", "0.56638426", "0.5660706", "0.56606156", "0.5655599", "0.5654594", "0.5653567", "0.5652697", "0.5647972", "0.56462616", "0.5645036", "0.5642309", "0.5633593", "0.56326", "0.5627367", "0.56218576", "0.56056577", "0.56048423", "0.55945987", "0.5580504", "0.5566921", "0.5566577", "0.55663055", "0.55660313", "0.5562497", "0.5554964", "0.55528027", "0.55461437", "0.553833", "0.5529175", "0.5526042", "0.550532", "0.54948175", "0.548907", "0.5481746", "0.5477868", "0.54757625", "0.5474366", "0.5473649", "0.5471329", "0.54713136", "0.5470051", "0.5447074", "0.54470646", "0.5443617", "0.54428846", "0.54428846", "0.5436604", "0.54362", "0.5429498", "0.5423883", "0.5423392", "0.54206216", "0.5420535", "0.54184455", "0.54177946", "0.54163986", "0.54120153", "0.54095215", "0.54016966", "0.54005545", "0.53992516", "0.5398618", "0.5391939", "0.5391939", "0.5391939", "0.5391939", "0.5391939", "0.5391939", "0.5391939" ]
0.0
-1
Create the Vantiq endpoint based on the URI provided. We have some special handling for the URI. If it's null (generally harder to do except from beanstyle configurations), we'll let that through. In such cases, our superclass will call our overridden method createEndpointUri(). This will construct the URI from the information in the containing connector's server.config file (if any). As noted, this is sometimes hard to do given programmatic route construction. So, the alternative is to allow for a URI of "vantiq://server.config". If we see a "host" name of "server.config", we will call the superclass constructor with a uri of null, and the processing described above will take over. This capability is primarily of use in the case of the Camel connector, allowing the user to avoid repeatedly having to specify the connection information.
public VantiqEndpoint(String uri, VantiqComponent component) throws Exception { // A bit of a strange construct, but necessary given the required interface and Java's requirement that the // super() call be the first functional line of a constructor. A "factory method" here might be a better // choice, but the constructor interface is fixed by Camel. super( (uri != null && new URI(uri).getHost().equalsIgnoreCase(SERVER_CONFIG_FILENAME)) ? null : uri, component); log.debug("Creating VantiqEndpoint for uri: {} with sourceName: {}, accessToken: {}", uri, sourceName, accessTokenForLog()); utils = new InstanceConfigUtils(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n public String createEndpointUri() {\n \n Properties scProps = utils.obtainServerConfig();\n String baseUri = scProps.getProperty(TARGET_SERVER_PROPERTY_NAME);\n String accessToken = scProps.getProperty(AUTH_TOKEN_PROPERTY_NAME);\n String sourceName = scProps.getProperty(SOURCES_PROPERTY_NAME);\n String sendPings = scProps.getProperty(SEND_PING_PROPERTY_NAME);\n if (StringUtils.isEmpty(baseUri) || StringUtils.isEmpty(accessToken)) {\n throw new IllegalArgumentException(\"source.config file is missing or does not contain sufficient \" +\n \"information from which to construct an endpoint URI.\");\n }\n if (StringUtils.isEmpty(sourceName) || sourceName.contains(\",\")) {\n throw new IllegalArgumentException(\"Default vantiq: endpoints require a source.config file with a single\" +\n \" source name. Found: '\" + sourceName + \"'.\");\n }\n \n try {\n URI vantiqURI = new URI(baseUri);\n this.setEndpointUri(baseUri);\n String origScheme = vantiqURI.getScheme();\n \n StringBuilder epString = new StringBuilder(vantiqURI.toString());\n epString.append(\"?sourceName=\").append(sourceName);\n this.sourceName = sourceName;\n epString.append(\"&accessToken=\").append(accessToken);\n this.accessToken = accessToken;\n if (sendPings != null) {\n epString.append(\"&sendPings=\").append(sendPings);\n this.sendPings = Boolean.parseBoolean(sendPings);\n }\n if (origScheme.equals(\"http\") || origScheme.equals(\"ws\")) {\n epString.append(\"&noSsl=\").append(\"true\");\n noSsl = true;\n }\n epString.replace(0, origScheme.length(), \"vantiq\");\n URI endpointUri = URI.create(String.valueOf(epString));\n return endpointUri.toString();\n } catch (URISyntaxException mue) {\n throw new IllegalArgumentException(TARGET_SERVER_PROPERTY_NAME + \" from server config file is invalid\",\n mue);\n }\n }", "public abstract Endpoint createEndpoint(String bindingId, Object implementor);", "void setDefaultEndpointUri(String endpointUri);", "public abstract Endpoint createAndPublishEndpoint(String address, Object implementor);", "public Endpoint getEndpoint(String uri) {\n Endpoint answer;\n synchronized (endpoints) {\n answer = endpoints.get(uri);\n if (answer == null) {\n try {\n\n String splitURI[] = ObjectHelper.splitOnCharacter(uri, \":\", 2);\n if (splitURI[1] != null) {\n String scheme = splitURI[0];\n Component component = getComponent(scheme);\n\n if (component != null) {\n answer = component.createEndpoint(uri);\n\n if (answer != null && LOG.isDebugEnabled()) {\n LOG.debug(uri + \" converted to endpoint: \" + answer + \" by component: \"+ component);\n }\n }\n }\n if (answer == null) {\n answer = createEndpoint(uri);\n }\n\n if (answer != null && answer.isSingleton()) {\n startServices(answer);\n endpoints.put(uri, answer);\n \tlifecycleStrategy.onEndpointAdd(answer);\n }\n } catch (Exception e) {\n throw new ResolveEndpointFailedException(uri, e);\n }\n }\n }\n return answer;\n }", "public Builder url(URI endpoint) {\n return server(endpoint);\n }", "public RouteInterface setUri(String uri);", "public URIBuilder() {\n super();\n this.port = -1;\n }", "public Builder setEndpoint(String endpoint) {\n this.endpoint = Preconditions.checkNotNull(endpoint, \"Endpoint is null.\");\n return this;\n }", "public HttpEndpoint( String theEndpoint ) {\n\t\tthis( theEndpoint, true );\n\t}", "void configureEndpoint(Endpoint endpoint);", "EndPoint createEndPoint();", "@Override\r\n\tpublic void init(EndpointConfig arg0) {\n\t\t\r\n\t}", "UMOEndpointURI getEndpointURI();", "public com.google.cloud.servicedirectory.v1beta1.Endpoint createEndpoint(\n com.google.cloud.servicedirectory.v1beta1.CreateEndpointRequest request) {\n return io.grpc.stub.ClientCalls.blockingUnaryCall(\n getChannel(), getCreateEndpointMethod(), getCallOptions(), request);\n }", "void setEndpoint(String endpoint);", "protected abstract String getBaseEndpoint();", "@Override\n\tpublic void init(EndpointConfig arg0) {\n\t\t\n\t}", "@Override\n\tpublic void init(EndpointConfig arg0) {\n\t\t\n\t}", "static RabbitConnectionFactoryConfig uriToConnectionConfig(String uri) {\n RabbitConnectionFactoryConfig properties = new RabbitConnectionFactoryConfig();\n if (isNotEmpty(uri)) {\n String username = StringUtils.substringBetween(uri, \"amqp://\", \":\");\n String password = StringUtils.substringBetween(uri, username + \":\", \"@\");\n String hostWithPort = StringUtils.substringBetween(uri, \"@\", \"/\");\n\n // If no virtual host is specified\n if (isEmpty(hostWithPort)) {\n hostWithPort = StringUtils.substringAfter(uri, \"@\");\n }\n\n int port = properties.getPort();\n String host = hostWithPort;\n boolean hasPort = StringUtils.contains(hostWithPort, \":\");\n if (hasPort) {\n host = StringUtils.substringBefore(hostWithPort, \":\");\n port = NumberUtils.toInt(StringUtils.substringAfter(hostWithPort, \":\"));\n }\n String virtualHost = StringUtils.substringAfter(uri, hostWithPort + \"/\");\n\n\n properties.setUsername(username);\n properties.setPassword(password);\n properties.setHost(host);\n properties.setPort(port);\n\n if (isNotEmpty(virtualHost)) {\n properties.setVirtualHost(virtualHost);\n }\n\n }\n return properties;\n }", "@Override\n public CreateEndpointResult createEndpoint(CreateEndpointRequest request) {\n request = beforeClientExecution(request);\n return executeCreateEndpoint(request);\n }", "private String createURLWithPort(String uri) {\n\t\treturn HOST + port + uri;\n\t}", "public com.google.common.util.concurrent.ListenableFuture<\n com.google.cloud.servicedirectory.v1beta1.Endpoint>\n createEndpoint(com.google.cloud.servicedirectory.v1beta1.CreateEndpointRequest request) {\n return io.grpc.stub.ClientCalls.futureUnaryCall(\n getChannel().newCall(getCreateEndpointMethod(), getCallOptions()), request);\n }", "@Override\n public URI createUri(String url) {\n try {\n this.uri = new URI(url);\n } catch (URISyntaxException e) {\n e.printStackTrace();\n }\n return uri;\n }", "public static URIElement buildURIElement(String uri) throws AmazonException{\r\n\t\tint questionIndex = uri.indexOf('?');\r\n\t\tif(questionIndex > 0){\r\n\t\t\turi = uri.substring(0, questionIndex);\r\n\t\t}\r\n\t\tString[] uriElements = uri.split(\"/\");\r\n\t\tif(uriElements.length < 4){\r\n\t\t\tthrow new AmazonException(\"InCompatible URI: \" + uri);\r\n\t\t}\r\n\t\tString context = uriElements[1];\r\n\t\tString module = uriElements[2];\r\n\t\tString command = uriElements[3];\r\n\t\tString method = \"execute\";\r\n\t\tif(uriElements.length == 5 ){\r\n\t\t\tif(uriElements[4] != null || !uriElements[4].isEmpty()){\r\n\t\t\t\tmethod = uriElements[4];\r\n\t\t\t}\r\n\t\t}\r\n\t\tint dotIndex = method.indexOf('.');\r\n\t\tif(dotIndex > 0){\r\n\t\t\tmethod = method.substring(0, dotIndex);\r\n\t\t}\r\n\t\t\r\n\t\treturn new URIElement(context, module, command, method);\r\n\t}", "public URIImpl(String uriString) {\r\n\t\tthis(uriString, true);\r\n\t}", "protected abstract String getBaseEndpointPath();", "public Builder setUri(String uri) {\n this.uri = uri;\n return this;\n }", "public RgwAdminBuilder endpoint(String endpoint) {\n this.endpoint = endpoint;\n return this;\n }", "public URIBuilder(final URI uri) {\n super();\n digestURI(uri);\n }", "public void init(EndpointConfig arg0) {\n\t\t\n\t}", "public ResourceTypeExtension withEndpointUri(String endpointUri) {\n this.endpointUri = endpointUri;\n return this;\n }", "Endpoint getDefaultEndpoint();", "URI createURI();", "public Builder server(URI endpoint) {\n if (endpoint != null) {\n this.servers = Collections.singletonList(endpoint);\n }\n return this;\n }", "UMOImmutableEndpoint createOutboundEndpoint(UMOEndpointBuilder builder, UMOManagementContext managementContext) throws UMOException;", "void setDefaultEndpoint(Endpoint defaultEndpoint);", "public void setEndpoint(org.hl7.fhir.Uri endpoint)\n {\n generatedSetterHelperImpl(endpoint, ENDPOINT$8, 0, org.apache.xmlbeans.impl.values.XmlObjectBase.KIND_SETTERHELPER_SINGLETON);\n }", "public VersionInfo withEndpointUrl(String endpointUrl) {\n this.endpointUrl = endpointUrl;\n return this;\n }", "public Bpmn2ResourceImpl(URI uri) {\r\n super(uri);\r\n this.xmlHelper = new BpmnXmlHelper(this);\r\n this.uriHandler = new QNameURIHandler(xmlHelper);\r\n this.getDefaultLoadOptions().put(XMLResource.OPTION_URI_HANDLER, uriHandler);\r\n this.getDefaultSaveOptions().put(XMLResource.OPTION_URI_HANDLER, uriHandler);\r\n }", "public org.hl7.fhir.Uri addNewEndpoint()\n {\n synchronized (monitor())\n {\n check_orphaned();\n org.hl7.fhir.Uri target = null;\n target = (org.hl7.fhir.Uri)get_store().add_element_user(ENDPOINT$8);\n return target;\n }\n }", "default void createEndpoint(\n com.google.cloud.servicedirectory.v1beta1.CreateEndpointRequest request,\n io.grpc.stub.StreamObserver<com.google.cloud.servicedirectory.v1beta1.Endpoint>\n responseObserver) {\n io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(\n getCreateEndpointMethod(), responseObserver);\n }", "FullUriTemplateString baseUri();", "public HttpMethodBase(String uri) \n throws IllegalArgumentException, IllegalStateException {\n\n try {\n\n // create a URI and allow for null/empty uri values\n if (uri == null || uri.equals(\"\")) {\n uri = \"/\";\n }\n URI parsedURI = new URI(uri.toCharArray());\n \n // only set the host if specified by the URI\n if (parsedURI.isAbsoluteURI()) {\n hostConfiguration = new HostConfiguration();\n hostConfiguration.setHost(\n parsedURI.getHost(),\n parsedURI.getPort(),\n parsedURI.getScheme()\n ); \n }\n \n // set the path, defaulting to root\n setPath(\n parsedURI.getPath() == null\n ? \"/\"\n : parsedURI.getEscapedPath()\n );\n setQueryString(parsedURI.getEscapedQuery());\n\n } catch (URIException e) {\n throw new IllegalArgumentException(\"Invalid uri '\" \n + uri + \"': \" + e.getMessage() \n );\n }\n }", "@Deprecated\r\n\tpublic static URI create(String uriString) {\r\n\t\treturn new URIImpl(uriString);\r\n\t}", "public void setEndpointId(String endpointId);", "String createEndpoint(String userId,\n String assetManagerGUID,\n String assetManagerName,\n boolean assetManagerIsHome,\n ExternalIdentifierProperties externalIdentifierProperties,\n EndpointProperties endpointProperties) throws InvalidParameterException,\n UserNotAuthorizedException,\n PropertyServerException;", "public String createEndpoint(EndpointProperties endpointProperties) throws InvalidParameterException,\n UserNotAuthorizedException,\n PropertyServerException\n {\n return connectionManagerClient.createEndpoint(userId, null, null, endpointProperties);\n }", "public String endpointUri() {\n return this.endpointUri;\n }", "public Builder uri(String uri) {\n this.uri = uri;\n return this;\n }", "private void setupBroker(String uri) {\n try {\n broker = BrokerFactory.createBroker(uri);\n\n VirtualDestinationInterceptor interceptor = new VirtualDestinationInterceptor();\n VirtualTopic virtualTopic = new VirtualTopic();\n virtualTopic.setName(\"VirtualOrders.>\");\n virtualTopic.setSelectorAware(true);\n VirtualDestination[] virtualDestinations = { virtualTopic };\n interceptor.setVirtualDestinations(virtualDestinations);\n broker.setDestinationInterceptors(new DestinationInterceptor[]{interceptor});\n\n SubQueueSelectorCacheBrokerPlugin subQueueSelectorCacheBrokerPlugin = new SubQueueSelectorCacheBrokerPlugin();\n BrokerPlugin[] updatedPlugins = {subQueueSelectorCacheBrokerPlugin};\n broker.setPlugins(updatedPlugins);\n\n broker.setUseJmx(false);\n broker.start();\n broker.waitUntilStarted();\n } catch (Exception e) {\n LOG.error(\"Failed creating broker\", e);\n }\n }", "URISegment createURISegment();", "public SimpleUriGenerator(String uriPrefix) {\n this.namedGraphURIPrefix = uriPrefix;\n }", "public UriSegment(String uriSegment) {\n this.pattern = extractPattern(uriSegment);\n this.paramId = extractParamId();\n this.paramClass = extractParamClass();\n this.paramField = extractParamField();\n this.paramMethod = extractParamMethod();\n this.segments = new HashSet<>();\n }", "@Deprecated\r\n\tpublic static URI createURIWithoutChecking(String uriString) {\r\n\t\treturn new URIImpl(uriString, false);\r\n\t}", "public Endpoint createEndpoint(String bindingId, Class<?> implementorClass, Invoker invoker,\n WebServiceFeature... features) {\n throw new UnsupportedOperationException(\n \"JAX-WS 2.2 implementation must override this default behaviour.\");\n }", "void setEndpointParameter(Endpoint endpoint, String name, Object value) throws RuntimeCamelException;", "public void createEndpoint(\n com.google.cloud.servicedirectory.v1beta1.CreateEndpointRequest request,\n io.grpc.stub.StreamObserver<com.google.cloud.servicedirectory.v1beta1.Endpoint>\n responseObserver) {\n io.grpc.stub.ClientCalls.asyncUnaryCall(\n getChannel().newCall(getCreateEndpointMethod(), getCallOptions()),\n request,\n responseObserver);\n }", "public void buildPathPart(Appendable buffer, String uri) throws WebAppConfigurationException, IOException {\n buildPathPart(buffer, uri, null);\n }", "public Builder setApiEndpoint(java.lang.String value) {\n if (value == null) {\n throw new NullPointerException();\n }\n apiEndpoint_ = value;\n bitField0_ |= 0x00080000;\n onChanged();\n return this;\n }", "public interface ApiEndpointDefinition extends Serializable {\n\n\t/**\n\t * Get the endpoint class.\n\t * @return the endpoint class\n\t */\n\tClass<?> getEndpointClass();\n\n\t/**\n\t * Get the endpoint type.\n\t * @return the endpoint type\n\t */\n\tApiEndpointType getType();\n\n\t/**\n\t * Get the scanner type.\n\t * @return the scanner type\n\t */\n\tJaxrsScannerType getScannerType();\n\n\t/**\n\t * Get the endpoint path.\n\t * @return the endpoint path\n\t */\n\tString getPath();\n\n\t/**\n\t * Get the API context id to which the endpoint is bound.\n\t * @return the API context id to which the endpoint is bound\n\t */\n\tString getContextId();\n\n\t/**\n\t * Init the endpoint context.\n\t * @return <code>true</code> if initialized, <code>false</code> if already initialized\n\t */\n\tboolean init();\n\n\t/**\n\t * Create a new {@link ApiEndpointDefinition}.\n\t * @param endpointClass The endpoint class (not null)\n\t * @param type The endpoint type\n\t * @param scannerType The scanner type\n\t * @param path The endpoint path\n\t * @param contextId the API context id to which the endpoint is bound\n\t * @param initializer Initializer (not null)\n\t * @return A new {@link ApiEndpointDefinition} instance\n\t */\n\tstatic ApiEndpointDefinition create(Class<?> endpointClass, ApiEndpointType type, JaxrsScannerType scannerType,\n\t\t\tString path, String contextId, Callable<Void> initializer) {\n\t\treturn new DefaultApiEndpointDefinition(endpointClass, type, scannerType, path, contextId, initializer);\n\t}\n\n}", "public URI() {\n }", "public EndPointAdapter(final SequelDatabase database) {\n\t\tsuper(database, \"endpoint\");\n\t}", "EndpointType endpointType();", "private void createEndpointElement(JsonObject swaggerObject, String swaggerVersion) throws RegistryException {\n\t\t/*\n\t\tExtracting endpoint url from the swagger document.\n\t\t */\n\t\tif (SwaggerConstants.SWAGGER_VERSION_12.equals(swaggerVersion)) {\n\t\t\tJsonElement endpointUrlElement = swaggerObject.get(SwaggerConstants.BASE_PATH);\n\t\t\tif (endpointUrlElement == null) {\n\t\t\t\tlog.warn(\"Endpoint url is not specified in the swagger document. Endpoint creation might fail. \");\n\t\t\t\treturn;\n\t\t\t} else {\n\t\t\t\tendpointUrl = endpointUrlElement.getAsString();\n\t\t\t}\n\t\t} else if (SwaggerConstants.SWAGGER_VERSION_2.equals(swaggerVersion)) {\n\t\t\tJsonElement transportsElement = swaggerObject.get(SwaggerConstants.SCHEMES);\n\t\t\tJsonArray transports = (transportsElement != null) ? transportsElement.getAsJsonArray() : null;\n\t\t\tString transport = (transports != null) ? transports.get(0).getAsString() + \"://\" : DEFAULT_TRANSPORT;\n\t\t\tJsonElement hostElement = swaggerObject.get(SwaggerConstants.HOST);\n\t\t\tString host = (hostElement != null) ? hostElement.getAsString() : null;\n if (host == null) {\n log.warn(\"Endpoint(host) url is not specified in the swagger document. \"\n + \"The host serving the documentation is to be used(including the port) as endpoint host\");\n\n if(requestContext.getSourceURL() != null) {\n URL sourceURL = null;\n try {\n sourceURL = new URL(requestContext.getSourceURL());\n } catch (MalformedURLException e) {\n throw new RegistryException(\"Error in parsing the source URL. \", e);\n }\n host = sourceURL.getAuthority();\n }\n }\n\n if (host == null) {\n log.warn(\"Can't derive the endpoint(host) url when uploading swagger from file. \"\n + \"Endpoint creation might fail. \");\n return;\n }\n\n\t\t\tJsonElement basePathElement = swaggerObject.get(SwaggerConstants.BASE_PATH);\n\t\t\tString basePath = (basePathElement != null) ? basePathElement.getAsString() : DEFAULT_BASE_PATH;\n\n\t\t\tendpointUrl = transport + host + basePath;\n\t\t}\n\t\t/*\n\t\tCreating endpoint artifact\n\t\t */\n\t\tOMFactory factory = OMAbstractFactory.getOMFactory();\n\t\tendpointLocation = EndpointUtils.deriveEndpointFromUrl(endpointUrl);\n\t\tString endpointName = EndpointUtils.deriveEndpointNameWithNamespaceFromUrl(endpointUrl);\n\t\tString endpointContent = EndpointUtils\n\t\t\t\t.getEndpointContentWithOverview(endpointUrl, endpointLocation, endpointName, documentVersion);\n\t\ttry {\n\t\t\tendpointElement = AXIOMUtil.stringToOM(factory, endpointContent);\n\t\t} catch (XMLStreamException e) {\n\t\t\tthrow new RegistryException(\"Error in creating the endpoint element. \", e);\n\t\t}\n\n\t}", "public URI(String p_uriSpec) throws MalformedURIException {\n this((URI)null, p_uriSpec);\n }", "String endpoint();", "UMOImmutableEndpoint createResponseEndpoint(UMOEndpointBuilder builder, UMOManagementContext managementContext) throws UMOException;", "public Endpoint createEndpoint(String bindingId, Object implementor, WebServiceFeature... features) {\n throw new UnsupportedOperationException(\n \"JAX-WS 2.2 implementation must override this default behaviour.\");\n }", "public Endpoint addNewEndpoint(String entity)\n\t\t{\n\t\t\tElement endpointElement = document.createElement(ENDPOINT_ELEMENT_NAME);\n\t\t\tEndpoint endpoint = new Endpoint(endpointElement);\n\t\t\tendpoint.setEntity(entity);\n\n\t\t\tuserElement.appendChild(endpointElement);\n\t\t\tendpointsList.add(endpoint);\n\n\t\t\treturn endpoint;\n\t\t}", "public interface RpcURI {\n String rpcproto = \"http\";\n String rpcssl = \"https\";\n String rpchost = \"127.0.0.1\";\n String rpcfile = \"/\";\n\n int RPCPORT_MAINNET = 8332;\n int RPCPORT_TESTNET = 18332;\n int RPCPORT_REGTEST = 18443; // Was same port as TESTNET until Bitcoin Core 0.16.0\n\n URI DEFAULT_MAINNET_URI = rpcURI( rpchost, RPCPORT_MAINNET);\n URI DEFAULT_TESTNET_URI = rpcURI( rpchost, RPCPORT_TESTNET );\n URI DEFAULT_REGTEST_URI = rpcURI( rpchost, RPCPORT_REGTEST);\n\n // TODO: Deprecate?\n URI defaultMainNetURI = DEFAULT_MAINNET_URI;\n URI defaultTestNetURI = DEFAULT_TESTNET_URI;\n URI defaultRegTestURI = DEFAULT_REGTEST_URI;\n\n static URI getDefaultMainNetURI() {\n return DEFAULT_MAINNET_URI;\n }\n\n static URI getDefaultTestNetURI() {\n return DEFAULT_TESTNET_URI;\n }\n\n static URI getDefaultRegTestURI() {\n return DEFAULT_REGTEST_URI;\n }\n\n static URI getDefaultRegTestWalletURI() {\n return getRegTestWalletURI(rpchost);\n }\n\n static URI getRegTestWalletURI(String hostName) {\n return rpcWalletURI(hostName, RPCPORT_REGTEST, BitcoinExtendedClient.REGTEST_WALLET_NAME);\n }\n\n static URI rpcURI(String hostName, int port) {\n return URI.create(rpcproto + \"://\" + hostName + \":\" + port + rpcfile);\n }\n\n static URI rpcWalletURI(String hostName, int port, String walletName) {\n return URI.create(rpcproto + \"://\" + hostName + \":\" + port + \"/wallet/\" + walletName);\n }\n}", "public Resource createResourceFromUri(String uri)\n\t{\n\t\turi = this.replaceNamespacePrefixes(uri);\n\t\treturn this.model.createResource(uri);\n\t}", "public void setEndpointUrl(final String endpointUrl) {\n\t\tthis.endpointUrl = endpointUrl;\n\t}", "private void initialize(URI p_base, String p_uriSpec)\n throws MalformedURIException {\n \n String uriSpec = p_uriSpec;\n int uriSpecLen = (uriSpec != null) ? uriSpec.length() : 0;\n \n if (p_base == null && uriSpecLen == 0) {\n throw new MalformedURIException(\n \"Cannot initialize URI with empty parameters.\");\n }\n \n // just make a copy of the base if spec is empty\n if (uriSpecLen == 0) {\n initialize(p_base);\n return;\n }\n \n int index = 0;\n \n // Check for scheme, which must be before '/', '?' or '#'. Also handle\n // names with DOS drive letters ('D:'), so 1-character schemes are not\n // allowed.\n int colonIdx = uriSpec.indexOf(':');\n if (colonIdx != -1) {\n final int searchFrom = colonIdx - 1;\n // search backwards starting from character before ':'.\n int slashIdx = uriSpec.lastIndexOf('/', searchFrom);\n int queryIdx = uriSpec.lastIndexOf('?', searchFrom);\n int fragmentIdx = uriSpec.lastIndexOf('#', searchFrom);\n \n if (colonIdx < 2 || slashIdx != -1 || \n queryIdx != -1 || fragmentIdx != -1) {\n // A standalone base is a valid URI according to spec\n if (colonIdx == 0 || (p_base == null && fragmentIdx != 0)) {\n throw new MalformedURIException(\"No scheme found in URI.\");\n }\n }\n else {\n initializeScheme(uriSpec);\n index = m_scheme.length()+1;\n \n // Neither 'scheme:' or 'scheme:#fragment' are valid URIs.\n if (colonIdx == uriSpecLen - 1 || uriSpec.charAt(colonIdx+1) == '#') {\n throw new MalformedURIException(\"Scheme specific part cannot be empty.\"); \n }\n }\n }\n else if (p_base == null && uriSpec.indexOf('#') != 0) {\n throw new MalformedURIException(\"No scheme found in URI.\"); \n }\n \n // Two slashes means we may have authority, but definitely means we're either\n // matching net_path or abs_path. These two productions are ambiguous in that\n // every net_path (except those containing an IPv6Reference) is an abs_path. \n // RFC 2396 resolves this ambiguity by applying a greedy left most matching rule. \n // Try matching net_path first, and if that fails we don't have authority so \n // then attempt to match abs_path.\n //\n // net_path = \"//\" authority [ abs_path ]\n // abs_path = \"/\" path_segments\n if (((index+1) < uriSpecLen) &&\n (uriSpec.charAt(index) == '/' && uriSpec.charAt(index+1) == '/')) {\n index += 2;\n int startPos = index;\n \n // Authority will be everything up to path, query or fragment\n char testChar = '\\0';\n while (index < uriSpecLen) {\n testChar = uriSpec.charAt(index);\n if (testChar == '/' || testChar == '?' || testChar == '#') {\n break;\n }\n index++;\n }\n \n // Attempt to parse authority. If the section is an empty string\n // this is a valid server based authority, so set the host to this\n // value.\n if (index > startPos) {\n // If we didn't find authority we need to back up. Attempt to\n // match against abs_path next.\n if (!initializeAuthority(uriSpec.substring(startPos, index))) {\n index = startPos - 2;\n }\n }\n else {\n m_host = \"\";\n }\n }\n \n initializePath(uriSpec, index);\n \n // Resolve relative URI to base URI - see RFC 2396 Section 5.2\n // In some cases, it might make more sense to throw an exception\n // (when scheme is specified is the string spec and the base URI\n // is also specified, for example), but we're just following the\n // RFC specifications\n if (p_base != null) {\n \n // check to see if this is the current doc - RFC 2396 5.2 #2\n // note that this is slightly different from the RFC spec in that\n // we don't include the check for query string being null\n // - this handles cases where the urispec is just a query\n // string or a fragment (e.g. \"?y\" or \"#s\") -\n // see <http://www.ics.uci.edu/~fielding/url/test1.html> which\n // identified this as a bug in the RFC\n if (m_path.length() == 0 && m_scheme == null &&\n m_host == null && m_regAuthority == null) {\n m_scheme = p_base.getScheme();\n m_userinfo = p_base.getUserinfo();\n m_host = p_base.getHost();\n m_port = p_base.getPort();\n m_regAuthority = p_base.getRegBasedAuthority();\n m_path = p_base.getPath();\n \n if (m_queryString == null) {\n m_queryString = p_base.getQueryString();\n }\n return;\n }\n \n // check for scheme - RFC 2396 5.2 #3\n // if we found a scheme, it means absolute URI, so we're done\n if (m_scheme == null) {\n m_scheme = p_base.getScheme();\n }\n else {\n return;\n }\n \n // check for authority - RFC 2396 5.2 #4\n // if we found a host, then we've got a network path, so we're done\n if (m_host == null && m_regAuthority == null) {\n m_userinfo = p_base.getUserinfo();\n m_host = p_base.getHost();\n m_port = p_base.getPort();\n m_regAuthority = p_base.getRegBasedAuthority();\n }\n else {\n return;\n }\n \n // check for absolute path - RFC 2396 5.2 #5\n if (m_path.length() > 0 &&\n m_path.startsWith(\"/\")) {\n return;\n }\n \n // if we get to this point, we need to resolve relative path\n // RFC 2396 5.2 #6\n String path = \"\";\n String basePath = p_base.getPath();\n \n // 6a - get all but the last segment of the base URI path\n if (basePath != null && basePath.length() > 0) {\n int lastSlash = basePath.lastIndexOf('/');\n if (lastSlash != -1) {\n path = basePath.substring(0, lastSlash+1);\n }\n }\n else if (m_path.length() > 0) {\n path = \"/\";\n }\n \n // 6b - append the relative URI path\n path = path.concat(m_path);\n \n // 6c - remove all \"./\" where \".\" is a complete path segment\n index = -1;\n while ((index = path.indexOf(\"/./\")) != -1) {\n path = path.substring(0, index+1).concat(path.substring(index+3));\n }\n \n // 6d - remove \".\" if path ends with \".\" as a complete path segment\n if (path.endsWith(\"/.\")) {\n path = path.substring(0, path.length()-1);\n }\n \n // 6e - remove all \"<segment>/../\" where \"<segment>\" is a complete\n // path segment not equal to \"..\"\n index = 1;\n int segIndex = -1;\n String tempString = null;\n \n while ((index = path.indexOf(\"/../\", index)) > 0) {\n tempString = path.substring(0, path.indexOf(\"/../\"));\n segIndex = tempString.lastIndexOf('/');\n if (segIndex != -1) {\n if (!tempString.substring(segIndex).equals(\"..\")) {\n path = path.substring(0, segIndex+1).concat(path.substring(index+4));\n index = segIndex;\n }\n else\n index += 4;\n }\n else\n index += 4;\n }\n \n // 6f - remove ending \"<segment>/..\" where \"<segment>\" is a\n // complete path segment\n if (path.endsWith(\"/..\")) {\n tempString = path.substring(0, path.length()-3);\n segIndex = tempString.lastIndexOf('/');\n if (segIndex != -1) {\n path = path.substring(0, segIndex+1);\n }\n }\n m_path = path;\n }\n }", "URISegmentWithParameter createURISegmentWithParameter();", "@Override\n\tpublic URI create(URI uri) throws StorageSecuirtyException,\n\t\t\tResourceAccessException {\n\t\treturn null;\n\t}", "public static PilosaClient withURI(URI uri) {\n return PilosaClient.withURI(uri, null);\n }", "public void setEndpoint(com.quikj.server.app.EndPointInterface endpoint) {\n\t\tthis.endpoint = endpoint;\n\t}", "void setupEndpoint(String userId,\n String assetManagerGUID,\n String assetManagerName,\n boolean assetManagerIsHome,\n String connectionGUID,\n String endpointGUID,\n Date effectiveFrom,\n Date effectiveTo,\n Date effectiveTime,\n boolean forLineage,\n boolean forDuplicateProcessing) throws InvalidParameterException,\n UserNotAuthorizedException,\n PropertyServerException;", "@WebMethod\n URI exposeEndpoint(Endpoint endpoint);", "void setMeasurementControllerURI(String uriStr) throws ConfigurationException;", "@Override\r\n public UriBuilder getBaseUriBuilder() {\n return null;\r\n }", "@Override\n\tpublic URI createURI(String... parts) throws URISyntaxException {\n\t\treturn null;\n\t}", "private ResolverService(Peer peer, EndpointService epService)\n {\n super(peer, RESSERVICE_NAME);\n\n // init fields\n initFields();\n \n \n this.epService = epService;\n epService.addListener(serviceName, this); //adding listener to end\n // point service\n\n cache = Cache.createInstance(); //creating cache\n cache.addResource(peer);\n \n\n // get SeedPeerList\n EndpointAddress[] seedPeerList = getSeedURIs();\n \n if (seedPeerList != null && seedPeerList.length > 0)\n {\n int seedListSize = (neighbors > seedPeerList.length ? seedPeerList.length : neighbors);\n seedURI = new EndpointAddress[seedListSize][1];\n for (int i = 0; i < seedListSize; i++)\n {\n seedURI[i][0] = seedPeerList[i];\n }\n }\n// try\n// {\n// mcastURI = new EndpointAddress(null, null, 0);\n// } catch (Exception e)\n// {\n// e.printStackTrace();\n// }\n\n// myPeer = peer;\n peerId = peer.getID().toString(); //TBD kuldeep - Is this needed?\n// peername = myPeer.getName();\n }", "public void setUri(String uri) {\n this.uri = uri;\n }", "public void setUri(String uri) {\n this.uri = uri;\n }", "public void setUri(String uri) {\n this.uri = uri;\n }", "public void setHostUri(final String uri) {\n\t\tthis.put(\"hostUri\", uri);\n\t}", "void setBaseUri(String baseUri);", "public void setUri(URI uri)\n {\n this.uri = uri;\n }", "public com.google.cloud.networkmanagement.v1beta1.EndpointInfo.Builder getEndpointBuilder() {\n return getEndpointFieldBuilder().getBuilder();\n }", "abstract String getUri();", "private static URI GetEndpoint(String accountName) throws URISyntaxException {\n String endpoint = EndpointTemplate.replace(\"{account-name}\", accountName);\n return new URI(endpoint);\n }", "Object create(String uri) throws IOException, SAXException, ParserConfigurationException;", "UMOImmutableEndpoint createInboundEndpoint(UMOEndpointBuilder builder, UMOManagementContext managementContext) throws UMOException;", "public void setUri(String uri) {\n\t\tthis.uri = uri;\n\t}", "public XMLTypeResourceImpl(URI uri)\n {\n super(uri);\n }", "public URI(URI p_base, String p_uriSpec) throws MalformedURIException {\n initialize(p_base, p_uriSpec);\n }", "@javax.annotation.Nullable\n @ApiModelProperty(value = \"The URI for this resource, relative to /apiserver.\")\n\n public String getUri() {\n return uri;\n }", "public void initPublicEndpoint() {\n \t//TODO: Register the new Public End Point with in the Content Repository Node\n \tString uniqueId = UUID.randomUUID().toString();\n \t\n \tpublicEndPoint = new JMSEndpoint();\n \tpublicEndPoint.setAddress(uniqueId + \"/public\");\n \t\n \tpublicEndPoint.setProperties(configuration.getBrokerPool().getBroker().getConnections(\"topic\").getParameters());\n \n // save the public endpoint from the registry\n registry.createPublicEndpoint();\n \n publicSender = initPublicSender(new JMSSenderFactory().create(publicEndPoint));\n \t\n \tisPublicEndPointInit = true;\n }" ]
[ "0.7040298", "0.649976", "0.64721745", "0.6262303", "0.6001687", "0.5983515", "0.58701396", "0.5622667", "0.55689853", "0.55658436", "0.5554132", "0.554933", "0.55202895", "0.5494142", "0.54871994", "0.5471838", "0.54665697", "0.546543", "0.546543", "0.5390522", "0.5384391", "0.5375272", "0.53741807", "0.53109217", "0.5309598", "0.52817756", "0.5270608", "0.52609175", "0.5236015", "0.5204149", "0.5202055", "0.5199055", "0.51966697", "0.5185761", "0.5184134", "0.51708716", "0.51567835", "0.5143302", "0.51227266", "0.5086811", "0.5077409", "0.5076954", "0.50675136", "0.5064641", "0.5062568", "0.5039195", "0.502281", "0.5021103", "0.500195", "0.49986804", "0.49801525", "0.4972504", "0.4963754", "0.49272066", "0.49261838", "0.49135247", "0.49066913", "0.48995224", "0.48939264", "0.4882919", "0.48660508", "0.48505715", "0.4850561", "0.48415345", "0.4829621", "0.48246348", "0.48182043", "0.4809387", "0.48076433", "0.47987872", "0.47934094", "0.47876653", "0.47780633", "0.47735634", "0.4772267", "0.4766606", "0.47590554", "0.47541815", "0.47532755", "0.4746387", "0.4734623", "0.4724699", "0.47217056", "0.47118455", "0.4703914", "0.4703914", "0.4703914", "0.4701091", "0.46930465", "0.4689973", "0.46893358", "0.46748078", "0.4658371", "0.46568203", "0.465575", "0.46303523", "0.46257323", "0.46141607", "0.46139312", "0.4612205" ]
0.78318584
0
Constructs & returns an ExtensionWebSocketClient. This is here primarily to override for unit testing. In unit test cases, we override to return a client that doesn't send to the (nonexistent) Vantiq installation;
protected ExtensionWebSocketClient buildVantiqClient(String source, int msgQueueSize) { return new ExtensionWebSocketClient(sourceName, failedMessageQueueSize, utils); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public abstract DefaultWOWebSocket create(Channel channel);", "public static RpcClient getInstance() {\n\t\tif (instance == null) {\n\t\t\tsynchronized (RpcClient.class) {\n\t\t\t\tif (instance == null) {\n\t\t\t\t\tinstance = new RpcClient(\"ye-cheng.duckdns.org\", 8980); // FIXME: ugly hard code\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn instance;\n\t}", "private static WebClient getClient(final Context context) {\n if (sInstance == null) {\n sInstance = new WebClient(context);\n }\n return sInstance;\n }", "public TelemetryClientClient()\n {\n TelemetryClient tc = new TelemetryClient();\n if (!tc.getOnlineStatus())\n tc.connect(\"a connection string\");\n\n tc.send(\"some message\");\n\n String response = tc.receive();\n\n tc.disconnect();\n\n }", "private ClientContainer getWebSocketsContainer(){\n return ( ClientContainer ) ContainerProvider.getWebSocketContainer(); \n }", "private SshClient createClient() {\n java.security.Security.addProvider(\n new org.bouncycastle.jce.provider.BouncyCastleProvider());\n final SshClient client = SshClient.setUpDefaultClient();\n client.setForwardingFilter(AcceptAllForwardingFilter.INSTANCE);\n client.setServerKeyVerifier(AcceptAllServerKeyVerifier.INSTANCE);\n return client;\n }", "public WebSocketExtension(Builder builder)\n {\n super(builder);\n }", "private SubscriptionAdminClient createSubscriptionClient() throws IOException {\n if (useEmulator) {\n SubscriptionAdminSettings adminSettings = SubscriptionAdminSettings.newBuilder()\n .setCredentialsProvider(pubsubCredsProvider)\n .setTransportChannelProvider(channelProvider)\n .build();\n return SubscriptionAdminClient.create(adminSettings);\n } else {\n return SubscriptionAdminClient.create(); // todo arz shutdown listener\n }\n }", "@Override\n public WsClient build() {\n header(HEADER_UPGRADE_WS);\n header(HEADER_WS_VERSION);\n header(Http.HeaderValues.CONTENT_LENGTH_ZERO);\n if (subprotocols.isEmpty()) {\n removeHeader(HEADER_WS_PROTOCOL);\n } else {\n header(HEADER_WS_PROTOCOL, subprotocols);\n }\n\n return new WsClientImpl(this);\n }", "Client createNewClient(Client client);", "WebSocketConnection getWebSocketConnection();", "public static Client createClient() {\n JacksonJaxbJsonProvider provider = new JacksonJaxbJsonProvider();\n provider.setAnnotationsToUse(new Annotations[]{Annotations.JACKSON});\n\n ClientConfig config = new ClientConfig(provider);\n //Allow delete request with entity\n config.property(ClientProperties.SUPPRESS_HTTP_COMPLIANCE_VALIDATION, true);\n //It helps to handle cookies\n config.property(ClientProperties.FOLLOW_REDIRECTS, Boolean.FALSE);\n //Allow PATCH\n config.property(HttpUrlConnectorProvider.SET_METHOD_WORKAROUND, true);\n\n Logger logger = Logger.getLogger(\"Client\");\n Feature feature = new LoggingFeature(logger, Level.INFO, LoggingFeature.Verbosity.PAYLOAD_ANY,\n null);\n\n //Allow self trusted certificates\n SSLContext sslcontext;\n try {\n sslcontext = SSLContext.getInstance(\"TLS\");\n sslcontext.init(null, new TrustManager[]{new X509TrustManager() {\n public void checkClientTrusted(X509Certificate[] arg0, String arg1) {\n }\n\n public void checkServerTrusted(X509Certificate[] arg0, String arg1) {\n }\n\n public X509Certificate[] getAcceptedIssuers() {\n return new X509Certificate[0];\n }\n }}, new java.security.SecureRandom());\n } catch (KeyManagementException | NoSuchAlgorithmException e) {\n throw new RuntimeException(e);\n }\n\n return ClientBuilder\n .newBuilder()\n .withConfig(config)\n .sslContext(sslcontext)\n .build()\n .register(feature)\n .register(MultiPartFeature.class);\n }", "@Override\n public TsiHandshaker newHandshaker() {\n ManagedChannel channel = HandshakerServiceChannel.get();\n return AltsTsiHandshaker.newClient(\n HandshakerServiceGrpc.newStub(channel), handshakerOptions);\n }", "@NonNull\n public static ExtensionWindowBackend getInstance(@NonNull Context context) {\n if (sInstance == null) {\n synchronized (sLock) {\n if (sInstance == null) {\n ExtensionInterfaceCompat windowExtension = initAndVerifyExtension(context);\n sInstance = new ExtensionWindowBackend(windowExtension);\n }\n }\n }\n return sInstance;\n }", "private WebClient getWebClient() {\n if (webClient == null) {\n webClient = new WebClient();\n webClient.getOptions().setUseInsecureSSL(true);\n webClient.getOptions().setThrowExceptionOnScriptError(false);\n webClient.getOptions().setCssEnabled(false);\n\n silenceWebClient(webClient);\n }\n\n return webClient;\n }", "public abstract Client getClient();", "private NotificationClient() { }", "public static @NonNull ChannelFactory<? extends Channel> clientChannelFactory() {\n return CURR_NETTY_TRANSPORT.clientChannelFactory();\n }", "public static Client getInstance() {\n if(client == null) {\n client = new Client();\n }\n return client;\n }", "public Client getSomeClient() {\n return new Client(3L, \"Yulian\", \"Tsvetkovskiy\", 20, null);\n }", "private static HttpClient createClient() {\n return HttpClients.createMinimal();\n }", "public Client create() {\n RequestProvider provider = RequestProviders.lookup();\n return provider.newClient(this);\n }", "@Override\n public Client get(String uuid) {\n return null;\n }", "Extension createExtension();", "@Override\n\tpublic void createClient() {\n\t\t\n\t}", "@Override\n public HelixZkClient buildZkClient(HelixZkClient.ZkConnectionConfig connectionConfig,\n HelixZkClient.ZkClientConfig clientConfig) {\n return new ZkClient(createZkConnection(connectionConfig),\n (int) clientConfig.getConnectInitTimeout(), clientConfig.getOperationRetryTimeout(),\n clientConfig.getZkSerializer(), clientConfig.getMonitorType(), clientConfig.getMonitorKey(),\n clientConfig.getMonitorInstanceName(), clientConfig.isMonitorRootPathOnly());\n }", "@BeforeClass\n public static void startEmbeddedJetty_9_1_1() throws Exception {\n server = new Server( 8080 );\n \n WebAppContext webapp = new WebAppContext();\n webapp.setContextPath( \"/websock-webapp\" );\n //But the .war should already have WebSocketServerEndpoint.class in it \n webapp.setWar( new File( \".\", \"../webapp/target/\" + WebAppConstants.WEBSOCKET_WEBAPP_NAME + \".war\" ).getPath() );\n server.setHandler( webapp );\n // Initialize the WebSocket Server Container\n WebSocketServerContainerInitializer.configureContext( webapp ); \n server.start();\n \n // After Jetty started and WebSocket Server Container was initialized, obtain it\n webSocketServerContainer = ( ServerContainer ) webapp.getServletContext().getAttribute( \n javax.websocket.server.ServerContainer.class.getName() );\n assertNotNull( webSocketServerContainer );\n System.out.println( \"--->> webSocketServerContainer [\" + webSocketServerContainer + \"] of class [\" + \n ( webSocketServerContainer == null ? null : webSocketServerContainer.getClass().getName() ) + \"]\" );\n \n //This should really NOT be needed since WebSocketServerEndpoint is in the .war and should be\n //picked up via annotation. PLUS this requires refactoring WebSocketServerEndpoint from out of the\n // /webapp child module into /common which is really unnecessary at this point.\n // webSocketServerContainer.addEndpoint( WebSocketServerEndpoint.class );\n \n WebSocketContainer container = ContainerProvider.getWebSocketContainer();\n assertNotNull( \"Jetty WebSockets Container is null\", container );\n container.connectToServer( WebSocketClientEndpoint.class,\n// // \"ws://localhost:8080/websock-webapp/echo\"\n new URI( WebAppConstants.WEBSOCKET_FULL_URL ) );\n \n/* This still throws the same damn, exception\n \nCaused by: org.eclipse.jetty.websocket.api.UpgradeException: Didn't switch protocols\n\tat org.eclipse.jetty.websocket.client.io.UpgradeConnection.validateResponse(UpgradeConnection.java:272)\n\tat org.eclipse.jetty.websocket.client.io.UpgradeConnection.read(UpgradeConnection.java:203)\n\tat org.eclipse.jetty.websocket.client.io.UpgradeConnection.onFillable(UpgradeConnection.java:148) \n*/ \n \n /* \n Running server as standalone and client as standalone via Spring work though.\n \n final ServletHolder servletHolder = new ServletHolder( new DefaultServlet() );\n final ServletContextHandler context = new ServletContextHandler();\n\n context.setContextPath( \"/\" );\n context.addServlet( servletHolder, \"/*\" );\n context.addEventListener( new ContextLoaderListener() ); \n context.setInitParameter( \"contextClass\", AnnotationConfigWebApplicationContext.class.getName() );\n context.setInitParameter( \"contextConfigLocation\", AppConfig.class.getName() );\n */\n \n }", "Client getClient();", "public static Client getClient() {\n if (ClientHandler.client == null) {\n ClientHandler.client = new Client();\n }\n return ClientHandler.client;\n }", "public ClientLoginService(){\n this(MessageConnection.CHANNEL_DEFAULT_RELIABLE);\n }", "public Client getClient() {\n\t\tcheckInit();\n\t\tfinal Client cli = tenant.getContext().getBean(Client.class);\n\t\tif (cli.getEventMapper()==null) {\n\t\t\tcli.setEventMapper(getEventMapper());\n\t\t}\n\t\treturn cli;\n\t}", "protected NetworkEmulatorTransport createWebsocketTransport() {\n return new NetworkEmulatorTransport(\n Transport.bindAwait(\n TransportConfig.defaultConfig().transportFactory(new WebsocketTransportFactory())));\n }", "public static Client getClient(){\n // Create a new client if it hasn't been created yet\n if(client == null) client = new Client(60000,60000);\n return client;\n }", "private MyClientEndpoint(){\n // private to prevent anyone else from instantiating\n }", "@Override\n\tpublic SwimConnection createInstance() {\n\t\tSwimConnection connection = null;\n\t\t\n\t\tif (this.hasSpecification()) {\n\t\t\tif (this.getSpecification().getId().equals(Specification.CONNECTION_SWIM_SIMULATED_ID)) {\n\t\t\t\tSimulatedSwimConnectionProperties properties = (SimulatedSwimConnectionProperties) this.getSpecification().getProperties();\n\t\t\t\tconnection = new SimulatedSwimConnection(\n\t\t\t\t\t\tproperties.getResourceDirectory(),\n\t\t\t\t\t\tDuration.ofMillis(properties.getUpdatePeriod()),\n\t\t\t\t\t\tproperties.getUpdateProbability(),\n\t\t\t\t\t\tproperties.getUpdateQuantity());\n\t\t\t\tif (properties.getSubscribesAIXM())\n\t\t\t\t\tconnection.subscribe(SwimProtocol.AIXM);\n\t\t\t\tif (properties.getSubscribesFIXM())\n\t\t\t\t\tconnection.subscribe(SwimProtocol.FIXM);\n\t\t\t\tif (properties.getSubscribesWXXM())\n\t\t\t\t\tconnection.subscribe(SwimProtocol.WXXM);\n\t\t\t\tif (properties.getSubscribesIWXXM())\n\t\t\t\t\tconnection.subscribe(SwimProtocol.IWXXM);\n\t\t\t\tif (properties.getSubscribesAMXM())\n\t\t\t\t\tconnection.subscribe(SwimProtocol.AMXM);\n\t\t\t} else if (this.getSpecification().getId().equals(Specification.CONNECTION_SWIM_LIVE_ID)) {\n\t\t\t\tLiveSwimConnectionProperties properties = (LiveSwimConnectionProperties) this.getSpecification().getProperties();\n\t\t\t\tconnection = new LiveSwimConnection();\n\t\t\t\t// TODO: set properties for live SWIM connection\n\t\t\t\tif (properties.getSubscribesAIXM())\n\t\t\t\t\tconnection.subscribe(SwimProtocol.AIXM);\n\t\t\t\tif (properties.getSubscribesFIXM())\n\t\t\t\t\tconnection.subscribe(SwimProtocol.FIXM);\n\t\t\t\tif (properties.getSubscribesWXXM())\n\t\t\t\t\tconnection.subscribe(SwimProtocol.WXXM);\n\t\t\t\tif (properties.getSubscribesIWXXM())\n\t\t\t\t\tconnection.subscribe(SwimProtocol.IWXXM);\n\t\t\t\tif (properties.getSubscribesAMXM())\n\t\t\t\t\tconnection.subscribe(SwimProtocol.AMXM);\n\t\t\t}\n\t\t}\n\t\t\n\t\treturn connection;\n\t}", "public static EventClient getEventClient() {\n if (EVENT_CLIENT == null) {\n EVENT_CLIENT = new NetworkEventClient(\n NetworkProvider.SERVER_URL,\n new DefaultNetworkProvider());\n }\n return EVENT_CLIENT;\n }", "private void createClient() {\n tc = new TestClient();\n }", "public Client() {}", "public BaseHttpXCapClient()\n {\n ServiceReference guiVerifyReference\n = SipActivator.getBundleContext().getServiceReference(\n CertificateService.class.getName());\n\n if(guiVerifyReference != null)\n certificateVerification\n = (CertificateService)SipActivator.getBundleContext()\n .getService(guiVerifyReference);\n }", "static Http1Client create() {\n return create(Http1ClientConfig.create());\n }", "public void createClientFromCredential() {\n WebPubSubServiceAsyncClient serverClient = new WebPubSubServiceClientBuilder()\n .connectionString(\"<connection-string>\")\n .hub(\"<hub>>\")\n .buildAsyncClient();\n\n // wrap WebPubSubServiceAsyncClient.getClientAccessToken as WebPubSubClientCredential\n WebPubSubClientCredential clientCredential = new WebPubSubClientCredential(Mono.defer(() ->\n serverClient.getClientAccessToken(new GetClientAccessTokenOptions()\n .setUserId(\"<user-name>\")\n .addRole(\"webpubsub.joinLeaveGroup\")\n .addRole(\"webpubsub.sendToGroup\"))\n .map(WebPubSubClientAccessToken::getUrl)));\n\n // create WebPubSub client\n WebPubSubClient client = new WebPubSubClientBuilder()\n .credential(clientCredential)\n .buildClient();\n // END: readme-sample-createClientFromCredential\n }", "public static DucktalesClient getClient() {\n \treturn client;\n }", "private Socket createClient()\n\t{\n\t\tSocket client = null;\n\t\ttry {\n\t\t\tclient = this.server.accept();\n\t\t}\n\t\tcatch(IOException e)\n\t\t{\n\t\t\tinsertLogEntry(e.getMessage(), e.getStackTrace().toString());\n\t\t}\n\t\t\n\t\treturn client;\n\t}", "public ReportiumClient createLoggerClient() {\n return new LoggerReportiumClient();\n }", "@Override\n protected SessionTicketTLSExtensionMessage createExtensionMessage() {\n return new SessionTicketTLSExtensionMessage();\n }", "public JDispatcherService getClientProxy() {\n\t\t try {\r\n\t\t\t Bundle bundle = Platform.getBundle(\"au.edu.unimelb.plantcell.io.ws.multialign\");\r\n\t\t\t URL u = FileLocator.find(bundle, new Path(\"META-INF/wsdl/tcoffee.wsdl\"), null);\r\n\t\t\t \r\n\t\t\t // must not call default constructor for local WSDL... so...\r\n\t\t\t JDispatcherService_Service cli = new JDispatcherService_Service(u,\r\n\t\t\t\t\t new QName(\"http://soap.jdispatcher.ebi.ac.uk\", \"JDispatcherService\"));\r\n\t\t\t return cli.getJDispatcherServiceHttpPort();\r\n\t\t } catch (Exception e) {\r\n\t\t\t e.printStackTrace();\r\n\t\t\t Logger.getAnonymousLogger().warning(\"Unable to get TCoffee proxy: \"+e.getMessage());\r\n\t\t\t return null;\r\n\t\t }\r\n\t}", "private static Client createDummyClient() {\n\n PhoneNumber num1 = new PhoneNumber(\"Arnold Schubert\",\"0151234567\", \"Ehemann\");\n PhoneNumber num2 = new PhoneNumber(\"Helene Schubert\",\"0171234567\", \"Tochter\");\n ArrayList<PhoneNumber> phoneNumbers1 = new ArrayList<>();\n phoneNumbers1.add(num1);\n phoneNumbers1.add(num2);\n DummyVitalValues vital1 = new DummyVitalValues();\n\n ArrayList<Integer> pictograms1 = new ArrayList<>();\n\n DummyClientMedicine medicine1 = new DummyClientMedicine(DummyMedicine.ITEMS_PRESCRIBED_Erna, DummyMedicine.ITEMS_TEMPORARY, DummyMedicine.ITEMS_SELF_ORDERED);\n\n Client c = new Client(0,R.drawable.erna, \"Erna\",\"Schubert\",\"17.08.1943\",medicine1,DummyNotes.ITEMS_Erna, DummyFixedNotes.ITEMS_Erna, DummyToDos.ITEMS_Erna, vital1.vitalValues, \"Diabetes mellitus, Adipositas, Schilddrüsenunterfuntion\",1,\"Blankenfelder Str. 82, 13127 Berlin\",phoneNumbers1, pictograms1);\n\n return c;\n }", "private WebClient getWebClient() {\n\t\treturn ClientSecurityUtils.applySecurityToRest(\n\t\t\t\tWebClient.fromClient(customerRestWebClient, true),\n\t\t\t\tpropertyManager.getRemoteUsername(),\n\t\t\t\tpropertyManager.getRemotePassword());\n\t}", "public WebClient getWebClient() {\n if (this.webClient == null) {\n this.webClient = WebClient.builder().baseUrl(getServiceEndpoint()).build();\n }\n\n return this.webClient;\n }", "public ClientWebSocket(String url) {\n try {\n URI endpointURI = new URI(url);\n WebSocketContainer container = ContainerProvider.getWebSocketContainer();\n container.connectToServer(this, endpointURI);\n\n } catch (URISyntaxException e) {\n e.printStackTrace();\n\n } catch (Exception e) {\n e.printStackTrace();\n }\n }", "private Vertx createVertxInstance() {\n String originalValue = System.getProperty(DISABLE_DNS_RESOLVER_PROP_NAME);\n Vertx vertx;\n try {\n System.setProperty(DISABLE_DNS_RESOLVER_PROP_NAME, \"true\");\n vertx = Vertx.vertx(new VertxOptions().setFileSystemOptions(\n new FileSystemOptions().setFileCachingEnabled(false).setClassPathResolvingEnabled(false)));\n } finally {\n // Restore the original value\n if (originalValue == null) {\n System.clearProperty(DISABLE_DNS_RESOLVER_PROP_NAME);\n } else {\n System.setProperty(DISABLE_DNS_RESOLVER_PROP_NAME, originalValue);\n }\n }\n return vertx;\n }", "@java.lang.Deprecated\n public io.kubernetes.client.openapi.models.ApiextensionsV1WebhookClientConfig getClientConfig();", "public WebSocketRPC() {\n\t}", "static Http1Client create(Http1ClientConfig clientConfig) {\n return new Http1ClientImpl(WebClient.create(it -> it.from(clientConfig)), clientConfig);\n }", "protected NuxeoClient getClient() {\n if (client == null) {\n initClient();\n }\n return client;\n }", "public XWalkExtensionClient(String name, String jsApi, XWalkExtensionContextClient context) {\n this(name, jsApi, null, context);\n }", "private void createClient() throws NFFGClientException {\n\t\ttry {\n\t\t\ttestNFFGClient = NFFGClientFactory.newInstance().newNFFGClient();\n\t\t} catch (FactoryConfigurationError fce) {\n\t\t\tfce.printStackTrace();\n\t\t}\n\t\tassertNotNull(\"The implementation under test generated a null NFFGClient\", testNFFGClient);\n\t}", "public interface IXioClientFactory\n{\n /**\n * Returns a client that is connected to the specified address, or is going to be connected to the specified address.\n * If the client is not connected, the caller must not connect the client to any other address but the one specified.\n * @param address The address.\n * @return Returns a new XioClient.\n */\n public XioClient newInstance( InetSocketAddress address);\n}", "@Override\n public Client createClient(Client client)\n throws RemoteException {\n client=clientManager.create(client);\n \n return client;\n }", "public static WebSocketSelectionKeyAPI getInstance ()\r\n {\r\n return theAPI;\r\n }", "@Override\n\tpublic void createClient(Client clt) {\n\t\t\n\t}", "ClientMessageSender() {\n\n\t}", "public static NettyAvroRpcClient getStockLocalClient(int port) {\n Properties props = new Properties();\n\n return getStockLocalClient(port, props);\n }", "abstract Optional<ByteString> clientId();", "public AbaloneClient() {\n server = new AbaloneServer();\n clientTUI = new AbaloneClientTUI();\n }", "@Bean\n\tpublic ServletServerContainerFactoryBean createWebSocketContainer() {\n\n\t\tServletServerContainerFactoryBean container = new ServletServerContainerFactoryBean();\n\t\tcontainer.setMaxBinaryMessageBufferSize(1024000);\n\t\treturn container;\n\t}", "protected ClientFacade createClientFacade(IFlushable flushable, IProtocolLogger logger) {\n return new ClientFacade(flushable, logger);\n }", "private SOSCommunicationHandler getClient() {\r\n\t\treturn client;\r\n\t}", "protected HeavyClient getClient() {\n\t\treturn client;\n\t}", "private OkHttpClient Create() {\n final OkHttpClient.Builder baseClient = new OkHttpClient().newBuilder()\n .connectTimeout(CONNECTION_TIMEOUT, TimeUnit.SECONDS)\n .writeTimeout(WRITE_TIMEOUT, TimeUnit.SECONDS)\n .readTimeout(READ_TIMEOUT, TimeUnit.SECONDS);\n\n // If there's no proxy just create a normal client\n if (appProps.getProxyHost().isEmpty()) {\n return baseClient.build();\n }\n\n final OkHttpClient.Builder proxyClient = baseClient\n .proxy(new java.net.Proxy(java.net.Proxy.Type.HTTP, new InetSocketAddress(appProps.getProxyHost(), Integer.parseInt(appProps.getProxyPort()))));\n\n if (!appProps.getProxyUsername().isEmpty() && !appProps.getProxyPassword().isEmpty()) {\n\n Authenticator proxyAuthenticator;\n String credentials;\n\n credentials = Credentials.basic(appProps.getProxyUsername(), appProps.getProxyPassword());\n\n // authenticate the proxy\n proxyAuthenticator = (route, response) -> response.request().newBuilder()\n .header(\"Proxy-Authorization\", credentials)\n .build();\n proxyClient.proxyAuthenticator(proxyAuthenticator);\n }\n return proxyClient.build();\n\n }", "@FunctionalInterface\npublic interface SocketInitializer {\n /**\n * The actual method used to initialize a pre-created WebSocket before a connection is made with it.\n * @param socket A WebSocket instance.\n * @return A <b>not-null</b> WebSocket instance with the updated properties.\n */\n @Nonnull WebSocket initialize(WebSocket socket);\n}", "public interface Client {\n \n /**\n * Get the unique id of current client.\n *\n * @return id of client\n */\n String getClientId();\n \n /**\n * Whether is ephemeral of current client.\n *\n * @return true if client is ephemeral, otherwise false\n */\n boolean isEphemeral();\n \n /**\n * Set the last time for updating current client as current time.\n */\n void setLastUpdatedTime();\n \n /**\n * Get the last time for updating current client.\n *\n * @return last time for updating\n */\n long getLastUpdatedTime();\n \n /**\n * Add a new instance for service for current client.\n *\n * @param service publish service\n * @param instancePublishInfo instance\n * @return true if add successfully, otherwise false\n */\n boolean addServiceInstance(Service service, InstancePublishInfo instancePublishInfo);\n \n /**\n * Remove service instance from client.\n *\n * @param service service of instance\n * @return instance info if exist, otherwise {@code null}\n */\n InstancePublishInfo removeServiceInstance(Service service);\n \n /**\n * Get instance info of service from client.\n *\n * @param service service of instance\n * @return instance info\n */\n InstancePublishInfo getInstancePublishInfo(Service service);\n \n /**\n * Get all published service of current client.\n *\n * @return published services\n */\n Collection<Service> getAllPublishedService();\n \n /**\n * Add a new subscriber for target service.\n *\n * @param service subscribe service\n * @param subscriber subscriber\n * @return true if add successfully, otherwise false\n */\n boolean addServiceSubscriber(Service service, Subscriber subscriber);\n \n /**\n * Remove subscriber for service.\n *\n * @param service service of subscriber\n * @return true if remove successfully, otherwise false\n */\n boolean removeServiceSubscriber(Service service);\n \n /**\n * Get subscriber of service from client.\n *\n * @param service service of subscriber\n * @return subscriber\n */\n Subscriber getSubscriber(Service service);\n \n /**\n * Get all subscribe service of current client.\n *\n * @return subscribe services\n */\n Collection<Service> getAllSubscribeService();\n \n /**\n * Generate sync data.\n *\n * @return sync data\n */\n ClientSyncData generateSyncData();\n \n /**\n * Whether current client is expired.\n *\n * @param currentTime unified current timestamp\n * @return true if client has expired, otherwise false\n */\n boolean isExpire(long currentTime);\n \n /**\n * Release current client and release resources if neccessary.\n */\n void release();\n \n /**\n * Recalculate client revision and get its value.\n * @return recalculated revision value\n */\n long recalculateRevision();\n \n /**\n * Get client revision.\n * @return current revision without recalculation\n */\n long getRevision();\n \n /**\n * Set client revision.\n * @param revision revision of this client to update\n */\n void setRevision(long revision);\n \n}", "public static Client create() {\n ClientConfig clientConfig = new ClientConfig(JacksonFeature.class,\n JacksonJaxbJsonProvider.class,\n JacksonJsonProvider.class);\n return ClientBuilder.newClient(clientConfig);\n }", "Wcs111Factory getWcs111Factory();", "public static WebResource getJerseyClient(String url){\n\t\tif(url == null || url.isEmpty()){\n\t\t\treturn null;\n\t\t}\n\t\tClient client = null;\n\n\t\tClientConfig clientConfigRegisterUser = new DefaultClientConfig();\n\t\tclientConfigRegisterUser.getFeatures().put(JSONConfiguration.FEATURE_POJO_MAPPING,Boolean.TRUE);\n\n\t\tclient = Client.create(clientConfigRegisterUser);\n\n\t\treturn client.resource(url);\n\t}", "public void newClient() throws StatsDClientException {\n Lock wl = lock.writeLock();\n StatsDClient newClient = null;\n try {\n newClient = new NonBlockingStatsDClient(prefix, hostname, port);\n LOGGER.info(\"New StatsD client created. \" + newClient.hashCode());\n } catch (StatsDClientException e) {\n LOGGER.warning(\"Could not refresh client, will continue to use old instance\");\n\n if (this.client == null) {\n throw e;\n }\n return;\n }\n\n // only acquire write lock if hostname resolution succeeded.\n wl.lock();\n try {\n if (this.client != null) {\n // this will flush remaining messages out of queue.\n this.client.stop();\n }\n this.client = newClient;\n } catch (Exception e) {\n LOGGER.warning(\"Could not refresh client, will continue to use old instance\");\n if (this.client == null) {\n throw e;\n }\n } finally {\n wl.unlock();\n }\n }", "protected FHIRClient getClient(Properties properties) throws Exception {\n return FHIRClientFactory.getClient(properties);\n }", "public static Test suite() {\r\n\t\tHyadesTestSuite testTPBridgeClient = new HyadesTestSuite(\r\n\t\t\t\t\"TestTPBridgeClient\");\r\n\t\ttestTPBridgeClient.setArbiter(DefaultTestArbiter.INSTANCE).setId(\r\n\t\t\t\t\"F968DA8CBEFEFE1A799AE350F11611DB\");\r\n\t\r\n\t\ttestTPBridgeClient.addTest(new TestTPBridgeClient(\"testTPBridgeClient\")\r\n\t\t\t\t.setId(\"F968DA8CBEFEFE1AAC5A86B9F11611DB\").setTestInvocationId(\r\n\t\t\t\t\t\t\"F968DA8CBEFEFE1A34EBB2E0F11911DB\"));\r\n\t\treturn testTPBridgeClient;\r\n\t}", "public static ReqIsntCertainSender get(Object senderObject) { return new ReqIsntCertainSender(senderObject); }", "ICordysGatewayClient getGatewayClientInstance();", "private static TypedProperties getClientConfig() throws Exception {\n final Map<String, Object> bindings = new HashMap<>();\n bindings.put(\"$nbDrivers\", nbDrivers);\n bindings.put(\"$nbNodes\", nbNodes);\n return ConfigurationHelper.createConfigFromTemplate(BaseSetup.DEFAULT_CONFIG.clientConfig, bindings);\n }", "public static ZubhiumSDK getZubhiumSDKInstance(final Context context) {\n return ZubhiumSDK.getZubhiumSDKInstance(\n context, ZUBHIUM_APP_SECRET_KEY);\n }", "public static Comms connect() {\r\n\t\tComms client = null;\r\n\t\ttry(ServerSocket server = new ServerSocket(4444)) {\r\n\t\t\tclient = new Comms(server.accept());\r\n\t\t} catch(Exception e) {\r\n\t\t\te.printStackTrace();\r\n\t\t}\r\n\t\treturn client;\r\n\t}", "public CreChqTrnValVerUVOClient() {\n }", "HostPlayer registerClient(ClientPlayer client);", "UUID clientId();", "@Test\n public void testAddActions() {\n springWebSocketClientActionFactory.addActions(DemoClientInterface.class);\n DemoClientInterface client = springWebSocketClientActionFactory.getClient(DemoClientInterface.class);\n assertSame(client, applicationContext.getBean(DemoClientInterface.class));\n assertNotSame(client, demoClientInterface2);\n }", "@Bean(initMethod = \"start\", destroyMethod = \"stop\")\n public WireMockServer wireMockServer() {\n return new WireMockServer(9561);\n }", "protected BaseWicketTester newWicketTester() {\n return new BaseWicketTester(newApplication());\n }", "public static IWifiExt getWifiPlugin(Context context) {\n IWifiExt ext;\n try {\n ext = (IWifiExt)PluginManager.createPluginObject(context,\n IWifiExt.class.getName());\n Xlog.d(TAG , \"IWifiExt plugin object created\");\n } catch (Plugin.ObjectCreationException e) {\n ext = new DefaultWifiExt(context); \n Xlog.d(TAG , \"DefaultWifiExt plugin object created, e = \" + e);\n }\n return ext;\n }", "Communicator createCommunicator();", "@CoverageIgnore\n public static HeadlessMediaPlayer newPlayer()\n {\n \n // Usage with the atLeast directive is taken from VLC's own media player \n // factory. The 2.1.0 version appears to correspond to a watershed release \n // that added critical functionality, so we keep it as is. For more info,\n // see: http://git.io/pV0u\n final LibVlc lib = LibVlcFactory.factory().atLeast(\"2.1.0\").create(); \n final String[] libvlcArgs = new String[]{\"\"};\n final libvlc_instance_t instance = lib.libvlc_new(libvlcArgs.length, libvlcArgs);\n return new DefaultHeadlessMediaPlayer(lib, instance);\n }", "private WebDriver createChromeDriver() {\n\t\tsetDriverPropertyIfRequired(\"webdriver.chrome.driver\", \"chromedriver.exe\");\n\n\t\tChromeOptions options = new ChromeOptions();\n\t\toptions.addArguments(\"disable-plugins\");\n\t\toptions.addArguments(\"disable-extensions\");\n\t\toptions.addArguments(\"test-type\");\n\n\t\t\n\t\t_driver = new ChromeDriver(options);\n\t\treturn _driver;\n\t}", "protected PcepClientDriver getPcepClientInstance(PceId pceId, int sessionID, PcepVersion pv,\n PcepPacketStats pktStats) {\n PcepClientDriver pcepClientDriver = new PcepClientImpl();\n pcepClientDriver.init(pceId, pv, pktStats);\n pcepClientDriver.setAgent(agent);\n return pcepClientDriver;\n }", "private byte[] createHandshake(String base64Key) {\n StringBuilder builder = new StringBuilder();\n\n String path = uri.getRawPath();\n String query = uri.getRawQuery();\n\n String requestUri;\n if (query == null) {\n requestUri = path;\n } else {\n requestUri = path + \"?\" + query;\n }\n\n builder.append(\"GET \" + requestUri + \" HTTP/1.1\");\n builder.append(\"\\r\\n\");\n\n String host;\n if (uri.getPort() == -1) {\n host = uri.getHost();\n } else {\n host = uri.getHost() + \":\" + uri.getPort();\n }\n\n builder.append(\"Host: \" + host);\n builder.append(\"\\r\\n\");\n\n builder.append(\"Upgrade: websocket\");\n builder.append(\"\\r\\n\");\n\n builder.append(\"Connection: Upgrade\");\n builder.append(\"\\r\\n\");\n\n builder.append(\"Sec-WebSocket-Key: \" + base64Key);\n builder.append(\"\\r\\n\");\n\n builder.append(\"Sec-WebSocket-Version: 13\");\n builder.append(\"\\r\\n\");\n\n for (Map.Entry<String, String> entry : headers.entrySet()) {\n builder.append(entry.getKey() + \": \" + entry.getValue());\n builder.append(\"\\r\\n\");\n }\n\n builder.append(\"\\r\\n\");\n\n String handshake = builder.toString();\n return handshake.getBytes(Charset.forName(\"ASCII\"));\n }", "public UPKClient() {\n connectToServer(BASE_URL);\n }", "@Override\n\tpublic Client getClientById(int id) {\n\t\treturn null;\n\t}", "static IDiscordClient getBuiltDiscordClient(String token) {\r\n // The ClientBuilder object is where you will attach your params for configuring the instance of your bot.\r\n // Such as withToken, setDaemon etc\r\n return new ClientBuilder()\r\n .withToken(token)\r\n .withPingTimeout(1)\r\n .withRecommendedShardCount()\r\n .build();\r\n }", "public Client() {\n }", "public Factory() {\n this(getInternalClient());\n }" ]
[ "0.60373616", "0.55269843", "0.54628164", "0.5413103", "0.5401731", "0.5389291", "0.5365168", "0.53365463", "0.53111404", "0.53001267", "0.52496874", "0.52227694", "0.51601547", "0.5159424", "0.51515156", "0.51177084", "0.5089461", "0.50309926", "0.49601853", "0.49473512", "0.49400216", "0.49389443", "0.49192134", "0.4908935", "0.48974112", "0.48757583", "0.48751146", "0.4850417", "0.48408878", "0.4834562", "0.4831865", "0.48281348", "0.48191464", "0.48118737", "0.48014882", "0.47734407", "0.47709224", "0.47697955", "0.47664043", "0.47302273", "0.47216415", "0.47141716", "0.4705584", "0.47022608", "0.46945995", "0.46895042", "0.46849772", "0.46828678", "0.4681859", "0.46803424", "0.46749574", "0.46492612", "0.46489537", "0.46218276", "0.46143398", "0.46036592", "0.4597901", "0.45837554", "0.45693448", "0.45634183", "0.4561777", "0.45532653", "0.4552417", "0.45512044", "0.45451814", "0.45432502", "0.45403934", "0.45401216", "0.45301765", "0.45297316", "0.45278138", "0.45232657", "0.4521713", "0.4520779", "0.45123908", "0.45120165", "0.45070508", "0.44988987", "0.44802803", "0.44757307", "0.44719723", "0.44653213", "0.44620997", "0.44620016", "0.44582573", "0.44557187", "0.44488502", "0.44488215", "0.44452864", "0.44335383", "0.4431718", "0.44252267", "0.44203663", "0.44190937", "0.4417188", "0.441557", "0.4413721", "0.43988532", "0.43983567", "0.43873814" ]
0.63653535
0
Does nothing in the real case. Overridden in FauxVantiqEndpoint.
protected void completeFuturesForFauxInstances() { }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public ChannelFuture method_4126() {\n return null;\n }", "public ChannelFuture method_4120() {\n return null;\n }", "public ChannelFuture method_4097() {\n return null;\n }", "@Override\n public int getResponseQueueLength() {\n return 0;\n }", "public ChannelFuture method_4092() {\n return null;\n }", "public ChannelFuture method_4130() {\n return null;\n }", "@Override\n\t\t\tpublic IAMQPExchange exchange() {\n\t\t\t\treturn null;\n\t\t\t}", "@Override\n\t\t\tpublic IAMQPExchange exchange() {\n\t\t\t\treturn null;\n\t\t\t}", "@Override\r\n\tpublic Response invoke() {\n\t\treturn null;\r\n\t}", "@Override\n public long getResponseQueueSize() {\n return 0;\n }", "ManagedEndpoint next();", "protected abstract String getBaseEndpoint();", "@Override\n public void onByteArrayMessage(ReceivedByteArrayMessage message) {\n //ignore the message\n }", "@Override\r\n\tprotected void processRespond() {\n\r\n\t}", "@Override\r\n\tprotected void processRespond() {\n\r\n\t}", "public Channel method_4121() {\n return null;\n }", "@Override\n public void onOffportRequestCompleted(int requestId) {\n\n }", "protected void onEndpointConnected(Endpoint endpoint) {}", "public Channel method_4112() {\n return null;\n }", "public Channel method_4090() {\n return null;\n }", "@Override\n protected void prot() {\n }", "@Override\n public void perish() {\n \n }", "public void processBlockwiseResponseTransferFailed() {\n //to be overridden by extending classes\n }", "@Override\n\tpublic int method() {\n\t\treturn 0;\n\t}", "@Override\n\tprotected void channelRead0(ChannelHandlerContext ctx, WsClientMessage msg) throws Exception {\n\t}", "public void cbEmptyResponse()\n {\n }", "@Override\n\t\tpublic void rest() {\n\t\t\t\n\t\t}", "@Override\n public void channelActive(ChannelHandlerContext ctx) throws Exception {\n super.channelActive(ctx);\n \n }", "@Override\n public void socket() {\n }", "@Override\n public void onSuccess(Void unusedResult) {\n Discoverer.this.eventListener.trigger(EVENT_LOG, \"Connection requested with: \" + endpointId);\n }", "public ChannelPromise method_4109() {\n return null;\n }", "@Override\n\tpublic void receiveRequest() {\n\n\t}", "@Override\n\tvoid receiveCall() {\n\n\t}", "@Override\n\tpublic void init(EndpointConfig arg0) {\n\t\t\n\t}", "@Override\n\tpublic void init(EndpointConfig arg0) {\n\t\t\n\t}", "public boolean hasEndpoint() { return true; }", "@Override\n\tpublic void sendResponse() {\n\t\t\n\t}", "@Override\n\tpublic void replyOperationCompleted() { ; }", "@Override\n protected void prepareHandshakeMessageContents() {\n }", "public ChannelPipeline method_4119() {\n return null;\n }", "protected void beforeConsume() {\n // Do nothing\n }", "protected void onConnectionFailed(Endpoint endpoint) {}", "@Override\n\tpublic Service upstreamDeliverServiceInit() {\n\t\treturn null;\n\t}", "public void __noop() {\n __send(__buildMessage(FTPCommand.getCommand(32), null));\n __getReplyNoReport();\n }", "@Override\n\tpublic void sendResponse() {\n\n\t}", "@Override\n\tpublic void receive() {\n\t}", "public ChannelPromise method_4101() {\n return null;\n }", "@Override\r\n\tpublic void init(EndpointConfig arg0) {\n\t\t\r\n\t}", "public ChannelProgressivePromise method_4127() {\n return null;\n }", "@Override\n public void handleClientRequest(User sender, ISFSObject params) {\n }", "@Override\n\tpublic String ping() {\n\t\treturn null;\n\t}", "@Override\n public void onEndpointDiscovered(String id, String name) {\n Log.d(TAG, \"endpoint discovered: \" + id + \" \" + name);\n }", "private AdesaNetworkCall(){ }", "@Override\n\t\t\t\t\tpublic void onReqStart() {\n\t\t\t\t\t}", "private HeartBeatMessage() {\n initFields();\n }", "@Override\n\t\tpublic void readyToRead(Vector<byte[]> outQ) {\n\t\t\t\n\t\t}", "protected void nop() throws Exception {\n reply_ok();\n }", "public ChannelFuture method_4116(SocketAddress var1) {\n return null;\n }", "public ChannelFuture method_4115(SocketAddress var1) {\n return null;\n }", "@Override\n\tprotected void initializeRegionAndEndpoint(ProcessContext context) {\n\t}", "public void request() {\n }", "@Override\n\tpublic void interpretBytes() {\n\t\t\n\t}", "protected void mo6255a() {\n }", "public interface EndpointBase {\n\n boolean isIdleNow();\n\n /**\n * @param connectionTimeout\n * @param methodTimeout\n */\n void setTimeouts(int connectionTimeout, int methodTimeout);\n\n /**\n * @param alwaysMainThread\n */\n void setCallbackThread(boolean alwaysMainThread);\n\n /**\n * @param flags\n */\n void setDebugFlags(int flags);\n\n int getDebugFlags();\n\n /**\n * @param delay\n */\n void setDelay(int delay);\n\n void addErrorLogger(ErrorLogger logger);\n\n void removeErrorLogger(ErrorLogger logger);\n\n void setOnRequestEventListener(OnRequestEventListener listener);\n\n\n void setPercentLoss(float percentLoss);\n\n int getThreadPriority();\n\n void setThreadPriority(int threadPriority);\n\n\n ProtocolController getProtocolController();\n\n void setUrlModifier(UrlModifier urlModifier);\n\n /**\n * No log.\n */\n int NO_DEBUG = 0;\n\n /**\n * Log time of requests.\n */\n int TIME_DEBUG = 1;\n\n /**\n * Log request content.\n */\n int REQUEST_DEBUG = 2;\n\n /**\n * Log response content.\n */\n int RESPONSE_DEBUG = 4;\n\n /**\n * Log cache behavior.\n */\n int CACHE_DEBUG = 8;\n\n /**\n * Log request code line.\n */\n int REQUEST_LINE_DEBUG = 16;\n\n /**\n * Log request and response headers.\n */\n int HEADERS_DEBUG = 32;\n\n /**\n * Log request errors\n */\n int ERROR_DEBUG = 64;\n\n /**\n * Log cancellations\n */\n int CANCEL_DEBUG = 128;\n\n /**\n * Log cancellations\n */\n int THREAD_DEBUG = 256;\n\n /**\n * Log everything.\n */\n int FULL_DEBUG = TIME_DEBUG | REQUEST_DEBUG | RESPONSE_DEBUG | CACHE_DEBUG | REQUEST_LINE_DEBUG | HEADERS_DEBUG | ERROR_DEBUG | CANCEL_DEBUG;\n\n int INTERNAL_DEBUG = FULL_DEBUG | THREAD_DEBUG;\n\n /**\n * Created by Kuba on 17/07/14.\n */\n interface UrlModifier {\n\n String createUrl(String url);\n\n }\n\n interface OnRequestEventListener {\n\n void onStart(Request request, int requestsCount);\n\n void onStop(Request request, int requestsCount);\n\n }\n}", "@Override\r\n\tprotected void processRespond() throws SGSException {\n\r\n\t}", "public void connect_NoPERequest(BOOL newIV){\n NoPERequest = newIV;\n }", "protected void onEndpointDisconnected(Endpoint endpoint) {}", "public boolean hasEndpoint2() { return true; }", "private void clearHeartBeatReq() {\n if (reqCase_ == 5) {\n reqCase_ = 0;\n req_ = null;\n }\n }", "protected byte[] onRequest(String topic, String item, int uFmt)\n {\n return null;\n }", "public void beforeReceive() {\n\t}", "@Override\n public void onChange(boolean selfChange) {\n super.onChange(selfChange);\n int[] bytesAndStatus = getBytesAndStatus(tag_id);\n if (bytesAndStatus[0] == -1 || bytesAndStatus[1] == -1) {\n hdHandler.sendMessage(hdHandler.obtainMessage(0, 0,\n -1));\n } else {\n hdHandler.sendMessage(hdHandler.obtainMessage(0,\n bytesAndStatus[0], bytesAndStatus[1]));\n }\n }", "@Override\n public void channelActive(ChannelHandlerContext ctx) throws Exception {\n }", "@java.lang.Override\n public boolean hasEndpoint() {\n return stepInfoCase_ == 8;\n }", "@Override\n\tpublic void nadar() {\n\t\t\n\t}", "private void offer() {\n\t\t\t\n\t\t}", "OptimizeResponse() {\n\n\t}", "@java.lang.Override\n public boolean hasEndpoint() {\n return stepInfoCase_ == 8;\n }", "@Override\n\t\tpublic void operationComplete(ChannelFuture arg0) throws Exception {\n\t\t\t\n\t\t}", "public void communicationChannelBroken() {\n\n }", "void faild_response();", "@Override\n\tpublic void call() {\n\t\t\n\t}", "@Override\n\tpublic String sendMsg1() {\n\t\treturn null;\n\t}", "@Override\r\n public void handleMessage(Message msg) {\n }", "@Override\n\tpublic String init_request() {\n\t\treturn null;\n\t}", "@Override\n\t\tpublic void onDirectMessage(DirectMessage arg0) {\n\t\t\t\n\t\t}", "@Override\n protected void onHubRequest(Tuple input) throws Exception {\n }", "@Override\n public long getUUID() {\n return endpointHandler.getUUID();\n }", "private void clearDeleteFriendServerToB() {\n if (rspCase_ == 18) {\n rspCase_ = 0;\n rsp_ = null;\n }\n }", "@Override\n\tprotected void handleServiceConnected()\n\t{\n\t\t\n\t}", "public void send() {\n\t}", "@Override\n public Object getPayloadInstance() {\n return null;\n }", "private FIXResponseImpl()\r\n {\r\n mBrokerID=null;\r\n mOriginator=null;\r\n mActorID=null;\r\n mViewerID=null;\r\n }", "@Override\n\tpublic void onResourceDelivered(ResourceResponse arg0) {\n\t\t\n\t}", "@Test\n public void testNoImageID(final TestContext aContext) {\n final String imageIDNull = null;\n final Async asyncTask = aContext.async();\n\n deployNewVerticle(myConfigs).compose(verticleID -> {\n myVertID = verticleID;\n return sendMessage(imageIDNull);\n }).onFailure(failure -> {\n if (Integer.parseInt(failure.getMessage()) == HTTP.INTERNAL_SERVER_ERROR) {\n TestUtils.complete(asyncTask);\n } else {\n aContext.fail();\n }\n }).onSuccess(success -> {\n aContext.fail();\n });\n }", "@Override\n\tpublic void conferenceroom() {\n\t\t\n\t}", "@Override\n\tprotected void interr() {\n\t}", "@Override\r\n\t\t\tpublic void buscar() {\n\r\n\t\t\t}", "private void clearSeenServerToB() {\n if (rspCase_ == 19) {\n rspCase_ = 0;\n rsp_ = null;\n }\n }", "@Override\n\tpublic Service duplexstreamDeliverServiceInit() {\n\t\treturn null;\n\t}", "@Override\r\n\t\t\tpublic void onRequest() {\n\t\t\t\t\r\n\t\t\t}" ]
[ "0.61069185", "0.604008", "0.59831816", "0.59560156", "0.59007096", "0.58817357", "0.58036894", "0.58036894", "0.5797905", "0.5795806", "0.5785952", "0.57843375", "0.5775668", "0.57754", "0.57754", "0.5737406", "0.57029235", "0.56965965", "0.56605405", "0.56447154", "0.5586332", "0.5582241", "0.5577394", "0.5564287", "0.5553763", "0.5543459", "0.55386907", "0.5529674", "0.5494914", "0.5491348", "0.5479738", "0.5433632", "0.5429431", "0.5418323", "0.5418323", "0.5417391", "0.5411162", "0.54109234", "0.5400133", "0.5392054", "0.53890777", "0.53857285", "0.53710437", "0.5356649", "0.5355342", "0.53523636", "0.53418607", "0.5339402", "0.5338173", "0.5317038", "0.5310044", "0.5303295", "0.5299889", "0.5281118", "0.52729046", "0.52639514", "0.52535355", "0.52496475", "0.52489173", "0.5247498", "0.52441776", "0.52335894", "0.52302206", "0.522616", "0.52172375", "0.5216876", "0.5216591", "0.5216524", "0.52052224", "0.5205167", "0.5196201", "0.519592", "0.51726365", "0.516605", "0.5165294", "0.51644355", "0.5163838", "0.516002", "0.51541144", "0.5152568", "0.5147266", "0.5145665", "0.5128121", "0.51265204", "0.51212037", "0.5120294", "0.5117285", "0.5109092", "0.5105906", "0.5104946", "0.5102899", "0.5102401", "0.509998", "0.50956744", "0.50931484", "0.5091626", "0.5091037", "0.509045", "0.50881267", "0.50879544", "0.5086708" ]
0.0
-1
Create and endpoint URI for our VantiqEndpoint. This is used by the DefaultEndpoint code when no endpoint URI is specified. In the Vantiq case, we will interpret the lack of URI specification to mean that this VantiqEndpoint is to connect to the Vantiq described in the standard connector server.config file. We will provide the parameters as is appropriate from data gleaned from the server.config file.
@Override public String createEndpointUri() { Properties scProps = utils.obtainServerConfig(); String baseUri = scProps.getProperty(TARGET_SERVER_PROPERTY_NAME); String accessToken = scProps.getProperty(AUTH_TOKEN_PROPERTY_NAME); String sourceName = scProps.getProperty(SOURCES_PROPERTY_NAME); String sendPings = scProps.getProperty(SEND_PING_PROPERTY_NAME); if (StringUtils.isEmpty(baseUri) || StringUtils.isEmpty(accessToken)) { throw new IllegalArgumentException("source.config file is missing or does not contain sufficient " + "information from which to construct an endpoint URI."); } if (StringUtils.isEmpty(sourceName) || sourceName.contains(",")) { throw new IllegalArgumentException("Default vantiq: endpoints require a source.config file with a single" + " source name. Found: '" + sourceName + "'."); } try { URI vantiqURI = new URI(baseUri); this.setEndpointUri(baseUri); String origScheme = vantiqURI.getScheme(); StringBuilder epString = new StringBuilder(vantiqURI.toString()); epString.append("?sourceName=").append(sourceName); this.sourceName = sourceName; epString.append("&accessToken=").append(accessToken); this.accessToken = accessToken; if (sendPings != null) { epString.append("&sendPings=").append(sendPings); this.sendPings = Boolean.parseBoolean(sendPings); } if (origScheme.equals("http") || origScheme.equals("ws")) { epString.append("&noSsl=").append("true"); noSsl = true; } epString.replace(0, origScheme.length(), "vantiq"); URI endpointUri = URI.create(String.valueOf(epString)); return endpointUri.toString(); } catch (URISyntaxException mue) { throw new IllegalArgumentException(TARGET_SERVER_PROPERTY_NAME + " from server config file is invalid", mue); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public VantiqEndpoint(String uri, VantiqComponent component) throws Exception {\n // A bit of a strange construct, but necessary given the required interface and Java's requirement that the\n // super() call be the first functional line of a constructor. A \"factory method\" here might be a better\n // choice, but the constructor interface is fixed by Camel.\n super( (uri != null && new URI(uri).getHost().equalsIgnoreCase(SERVER_CONFIG_FILENAME)) ?\n null : uri, component);\n log.debug(\"Creating VantiqEndpoint for uri: {} with sourceName: {}, accessToken: {}\",\n uri, sourceName, accessTokenForLog());\n utils = new InstanceConfigUtils();\n }", "void setDefaultEndpointUri(String endpointUri);", "UMOEndpointURI getEndpointURI();", "public abstract Endpoint createEndpoint(String bindingId, Object implementor);", "public abstract Endpoint createAndPublishEndpoint(String address, Object implementor);", "protected abstract String getBaseEndpoint();", "protected abstract String getBaseEndpointPath();", "String endpoint();", "void setEndpoint(String endpoint);", "public String createEndpoint(EndpointProperties endpointProperties) throws InvalidParameterException,\n UserNotAuthorizedException,\n PropertyServerException\n {\n return connectionManagerClient.createEndpoint(userId, null, null, endpointProperties);\n }", "public String endpointUri() {\n return this.endpointUri;\n }", "String createEndpoint(String userId,\n String assetManagerGUID,\n String assetManagerName,\n boolean assetManagerIsHome,\n ExternalIdentifierProperties externalIdentifierProperties,\n EndpointProperties endpointProperties) throws InvalidParameterException,\n UserNotAuthorizedException,\n PropertyServerException;", "private String getEndPointUrl()\r\n\t{\r\n\t\t// TODO - Get the URL from WSRR\r\n\t\treturn \"http://localhost:8093/mockCustomerBinding\";\r\n\t}", "FullUriTemplateString baseUri();", "Endpoint getDefaultEndpoint();", "String serviceEndpoint();", "public void setEndpointId(String endpointId);", "public RgwAdminBuilder endpoint(String endpoint) {\n this.endpoint = endpoint;\n return this;\n }", "public Builder url(URI endpoint) {\n return server(endpoint);\n }", "void configureEndpoint(Endpoint endpoint);", "EndPoint createEndPoint();", "public static String setURL(String endpoint) {\n String url = hostName + endpoint;\n\n log.info(\"Enpoint: \" + endpoint);\n\n return url;\n\n }", "private static URI GetEndpoint(String accountName) throws URISyntaxException {\n String endpoint = EndpointTemplate.replace(\"{account-name}\", accountName);\n return new URI(endpoint);\n }", "void setupEndpoint(String userId,\n String assetManagerGUID,\n String assetManagerName,\n boolean assetManagerIsHome,\n String connectionGUID,\n String endpointGUID,\n Date effectiveFrom,\n Date effectiveTo,\n Date effectiveTime,\n boolean forLineage,\n boolean forDuplicateProcessing) throws InvalidParameterException,\n UserNotAuthorizedException,\n PropertyServerException;", "public HttpEndpoint( String theEndpoint ) {\n\t\tthis( theEndpoint, true );\n\t}", "@Override\n public CreateEndpointResult createEndpoint(CreateEndpointRequest request) {\n request = beforeClientExecution(request);\n return executeCreateEndpoint(request);\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}", "@Override\r\n\tpublic void init(EndpointConfig arg0) {\n\t\t\r\n\t}", "void setDefaultEndpoint(Endpoint defaultEndpoint);", "public String getEndpoint() {\n\t\treturn null;\n\t}", "@Override\n\tprotected String getWebServiceUri() {\n\t\treturn this.uri;\n\t}", "@Override\n public String toString() {\n return endpoint;\n }", "public Builder setEndpoint(String endpoint) {\n this.endpoint = Preconditions.checkNotNull(endpoint, \"Endpoint is null.\");\n return this;\n }", "public void setEndpoint(com.quikj.server.app.EndPointInterface endpoint) {\n\t\tthis.endpoint = endpoint;\n\t}", "@WebMethod\n URI exposeEndpoint(Endpoint endpoint);", "UMOImmutableEndpoint createOutboundEndpoint(UMOEndpointBuilder builder, UMOManagementContext managementContext) throws UMOException;", "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 }", "public String getEndpointId();", "public com.google.cloud.servicedirectory.v1beta1.Endpoint createEndpoint(\n com.google.cloud.servicedirectory.v1beta1.CreateEndpointRequest request) {\n return io.grpc.stub.ClientCalls.blockingUnaryCall(\n getChannel(), getCreateEndpointMethod(), getCallOptions(), request);\n }", "EndpointType endpointType();", "public URIBuilder() {\n super();\n this.port = -1;\n }", "public static String endpoint(KubevirtApiConfig apiConfig) {\n return endpoint(apiConfig.scheme(), apiConfig.ipAddress(), apiConfig.port());\n }", "public void initPublicEndpoint() {\n \t//TODO: Register the new Public End Point with in the Content Repository Node\n \tString uniqueId = UUID.randomUUID().toString();\n \t\n \tpublicEndPoint = new JMSEndpoint();\n \tpublicEndPoint.setAddress(uniqueId + \"/public\");\n \t\n \tpublicEndPoint.setProperties(configuration.getBrokerPool().getBroker().getConnections(\"topic\").getParameters());\n \n // save the public endpoint from the registry\n registry.createPublicEndpoint();\n \n publicSender = initPublicSender(new JMSSenderFactory().create(publicEndPoint));\n \t\n \tisPublicEndPointInit = true;\n }", "public String getEndpoint() {\n return this.endpoint;\n }", "public String getEndpoint() {\n return this.endpoint;\n }", "default void createEndpoint(\n com.google.cloud.servicedirectory.v1beta1.CreateEndpointRequest request,\n io.grpc.stub.StreamObserver<com.google.cloud.servicedirectory.v1beta1.Endpoint>\n responseObserver) {\n io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(\n getCreateEndpointMethod(), responseObserver);\n }", "private void createEndpointElement(JsonObject swaggerObject, String swaggerVersion) throws RegistryException {\n\t\t/*\n\t\tExtracting endpoint url from the swagger document.\n\t\t */\n\t\tif (SwaggerConstants.SWAGGER_VERSION_12.equals(swaggerVersion)) {\n\t\t\tJsonElement endpointUrlElement = swaggerObject.get(SwaggerConstants.BASE_PATH);\n\t\t\tif (endpointUrlElement == null) {\n\t\t\t\tlog.warn(\"Endpoint url is not specified in the swagger document. Endpoint creation might fail. \");\n\t\t\t\treturn;\n\t\t\t} else {\n\t\t\t\tendpointUrl = endpointUrlElement.getAsString();\n\t\t\t}\n\t\t} else if (SwaggerConstants.SWAGGER_VERSION_2.equals(swaggerVersion)) {\n\t\t\tJsonElement transportsElement = swaggerObject.get(SwaggerConstants.SCHEMES);\n\t\t\tJsonArray transports = (transportsElement != null) ? transportsElement.getAsJsonArray() : null;\n\t\t\tString transport = (transports != null) ? transports.get(0).getAsString() + \"://\" : DEFAULT_TRANSPORT;\n\t\t\tJsonElement hostElement = swaggerObject.get(SwaggerConstants.HOST);\n\t\t\tString host = (hostElement != null) ? hostElement.getAsString() : null;\n if (host == null) {\n log.warn(\"Endpoint(host) url is not specified in the swagger document. \"\n + \"The host serving the documentation is to be used(including the port) as endpoint host\");\n\n if(requestContext.getSourceURL() != null) {\n URL sourceURL = null;\n try {\n sourceURL = new URL(requestContext.getSourceURL());\n } catch (MalformedURLException e) {\n throw new RegistryException(\"Error in parsing the source URL. \", e);\n }\n host = sourceURL.getAuthority();\n }\n }\n\n if (host == null) {\n log.warn(\"Can't derive the endpoint(host) url when uploading swagger from file. \"\n + \"Endpoint creation might fail. \");\n return;\n }\n\n\t\t\tJsonElement basePathElement = swaggerObject.get(SwaggerConstants.BASE_PATH);\n\t\t\tString basePath = (basePathElement != null) ? basePathElement.getAsString() : DEFAULT_BASE_PATH;\n\n\t\t\tendpointUrl = transport + host + basePath;\n\t\t}\n\t\t/*\n\t\tCreating endpoint artifact\n\t\t */\n\t\tOMFactory factory = OMAbstractFactory.getOMFactory();\n\t\tendpointLocation = EndpointUtils.deriveEndpointFromUrl(endpointUrl);\n\t\tString endpointName = EndpointUtils.deriveEndpointNameWithNamespaceFromUrl(endpointUrl);\n\t\tString endpointContent = EndpointUtils\n\t\t\t\t.getEndpointContentWithOverview(endpointUrl, endpointLocation, endpointName, documentVersion);\n\t\ttry {\n\t\t\tendpointElement = AXIOMUtil.stringToOM(factory, endpointContent);\n\t\t} catch (XMLStreamException e) {\n\t\t\tthrow new RegistryException(\"Error in creating the endpoint element. \", e);\n\t\t}\n\n\t}", "public interface RpcURI {\n String rpcproto = \"http\";\n String rpcssl = \"https\";\n String rpchost = \"127.0.0.1\";\n String rpcfile = \"/\";\n\n int RPCPORT_MAINNET = 8332;\n int RPCPORT_TESTNET = 18332;\n int RPCPORT_REGTEST = 18443; // Was same port as TESTNET until Bitcoin Core 0.16.0\n\n URI DEFAULT_MAINNET_URI = rpcURI( rpchost, RPCPORT_MAINNET);\n URI DEFAULT_TESTNET_URI = rpcURI( rpchost, RPCPORT_TESTNET );\n URI DEFAULT_REGTEST_URI = rpcURI( rpchost, RPCPORT_REGTEST);\n\n // TODO: Deprecate?\n URI defaultMainNetURI = DEFAULT_MAINNET_URI;\n URI defaultTestNetURI = DEFAULT_TESTNET_URI;\n URI defaultRegTestURI = DEFAULT_REGTEST_URI;\n\n static URI getDefaultMainNetURI() {\n return DEFAULT_MAINNET_URI;\n }\n\n static URI getDefaultTestNetURI() {\n return DEFAULT_TESTNET_URI;\n }\n\n static URI getDefaultRegTestURI() {\n return DEFAULT_REGTEST_URI;\n }\n\n static URI getDefaultRegTestWalletURI() {\n return getRegTestWalletURI(rpchost);\n }\n\n static URI getRegTestWalletURI(String hostName) {\n return rpcWalletURI(hostName, RPCPORT_REGTEST, BitcoinExtendedClient.REGTEST_WALLET_NAME);\n }\n\n static URI rpcURI(String hostName, int port) {\n return URI.create(rpcproto + \"://\" + hostName + \":\" + port + rpcfile);\n }\n\n static URI rpcWalletURI(String hostName, int port, String walletName) {\n return URI.create(rpcproto + \"://\" + hostName + \":\" + port + \"/wallet/\" + walletName);\n }\n}", "private String createURLWithPort(String uri) {\n\t\treturn HOST + port + uri;\n\t}", "URI createURI();", "public com.google.common.util.concurrent.ListenableFuture<\n com.google.cloud.servicedirectory.v1beta1.Endpoint>\n createEndpoint(com.google.cloud.servicedirectory.v1beta1.CreateEndpointRequest request) {\n return io.grpc.stub.ClientCalls.futureUnaryCall(\n getChannel().newCall(getCreateEndpointMethod(), getCallOptions()), request);\n }", "public Endpoint addNewEndpoint(String entity)\n\t\t{\n\t\t\tElement endpointElement = document.createElement(ENDPOINT_ELEMENT_NAME);\n\t\t\tEndpoint endpoint = new Endpoint(endpointElement);\n\t\t\tendpoint.setEntity(entity);\n\n\t\t\tuserElement.appendChild(endpointElement);\n\t\t\tendpointsList.add(endpoint);\n\n\t\t\treturn endpoint;\n\t\t}", "String webSocketUri();", "public String endpoint() {\n return this.endpoint;\n }", "public void setEndpointUrl(final String endpointUrl) {\n\t\tthis.endpointUrl = endpointUrl;\n\t}", "public void setEndpoint(org.hl7.fhir.Uri endpoint)\n {\n generatedSetterHelperImpl(endpoint, ENDPOINT$8, 0, org.apache.xmlbeans.impl.values.XmlObjectBase.KIND_SETTERHELPER_SINGLETON);\n }", "public String endpointUrl() {\n return this.endpointUrl;\n }", "public void init(EndpointConfig arg0) {\n\t\t\n\t}", "public org.hl7.fhir.Uri addNewEndpoint()\n {\n synchronized (monitor())\n {\n check_orphaned();\n org.hl7.fhir.Uri target = null;\n target = (org.hl7.fhir.Uri)get_store().add_element_user(ENDPOINT$8);\n return target;\n }\n }", "public String getEndpointAsString() {\r\n\t\tString host;\r\n\r\n\t\ttry {\r\n\t\t\thost = InetAddress.getByName(m_hostString).toString();\r\n\t\t} catch (UnknownHostException e) {\r\n\t\t\thost = m_hostString;\r\n\t\t}\r\n\r\n\t\treturn host + \":\" + m_port;\r\n\t}", "UMOImmutableEndpoint createResponseEndpoint(UMOEndpointBuilder builder, UMOManagementContext managementContext) throws UMOException;", "@Nonnull\n\tprivate URI getPossiblyInsecureBaseUri() {\n\t\tUriInfo ui = getUriInfo();\n\t\tif (ui != null && ui.getBaseUri() != null)\n\t\t\treturn ui.getBaseUri();\n\t\t// See if JAX-WS *cannot* supply the info\n\t\tif (jaxws == null || jaxws.getMessageContext() == null)\n\t\t\t// Hack to make the test suite work\n\t\t\treturn URI.create(\"http://\" + DEFAULT_HOST\n\t\t\t\t\t+ \"/taverna-server/rest/\");\n\t\tString pathInfo = (String) jaxws.getMessageContext().get(PATH_INFO);\n\t\tpathInfo = pathInfo.replaceFirst(\"/soap$\", \"/rest/\");\n\t\tpathInfo = pathInfo.replaceFirst(\"/rest/.+$\", \"/rest/\");\n\t\treturn URI.create(\"http://\" + getHostLocation() + pathInfo);\n\t}", "void setEndpointParameter(Endpoint endpoint, String name, Object value) throws RuntimeCamelException;", "public SimpleUriGenerator(String uriPrefix) {\n this.namedGraphURIPrefix = uriPrefix;\n }", "public static String getDefaultEndpoint() {\n return WorkflowsStubSettings.getDefaultEndpoint();\n }", "UMOImmutableEndpoint createInboundEndpoint(UMOEndpointBuilder builder, UMOManagementContext managementContext) throws UMOException;", "public void createEndpoint(\n com.google.cloud.servicedirectory.v1beta1.CreateEndpointRequest request,\n io.grpc.stub.StreamObserver<com.google.cloud.servicedirectory.v1beta1.Endpoint>\n responseObserver) {\n io.grpc.stub.ClientCalls.asyncUnaryCall(\n getChannel().newCall(getCreateEndpointMethod(), getCallOptions()),\n request,\n responseObserver);\n }", "public VersionInfo withEndpointUrl(String endpointUrl) {\n this.endpointUrl = endpointUrl;\n return this;\n }", "void setMeasurementControllerURI(String uriStr) throws ConfigurationException;", "public Builder setApiEndpoint(java.lang.String value) {\n if (value == null) {\n throw new NullPointerException();\n }\n apiEndpoint_ = value;\n bitField0_ |= 0x00080000;\n onChanged();\n return this;\n }", "public void setEndpointAddress(java.lang.String portName, java.lang.String address) throws javax.xml.rpc.ServiceException {\n \nif (\"UGSRuntimeServiceXfireImplHttpPort\".equals(portName)) {\n setUGSRuntimeServiceXfireImplHttpPortEndpointAddress(address);\n }\n else \n{ // Unknown Port Name\n throw new javax.xml.rpc.ServiceException(\" Cannot set Endpoint Address for Unknown Port\" + portName);\n }\n }", "public String getSparqlEndPoint() {\n\t\treturn this.sparqlEndPointURL;\n\t}", "public com.quikj.server.app.EndPointInterface getEndpoint() {\n\t\treturn endpoint;\n\t}", "public com.google.cloud.networkmanagement.v1beta1.EndpointInfo.Builder getEndpointBuilder() {\n return getEndpointFieldBuilder().getBuilder();\n }", "public static String getDefaultEndpoint() {\n return \"biglake.googleapis.com:443\";\n }", "private void setupMqttEndpoint() {\n\n this.mqttEndpoint\n .publishHandler(this::publishHandler)\n .publishAcknowledgeHandler(this::pubackHandler)\n .publishReleaseHandler(this::pubrelHandler)\n .publishReceivedHandler(this::pubrecHandler)\n .publishCompletionHandler(this::pubcompHandler)\n .subscribeHandler(this::subscribeHandler)\n .unsubscribeHandler(this::unsubscribeHandler)\n .disconnectHandler(this::disconnectHandler)\n .closeHandler(this::closeHandler);\n }", "abstract String getUri();", "protected void onEndpointConnected(Endpoint endpoint) {}", "public URL getEndPoint();", "String createEndpointFromTemplate(String userId,\n String assetManagerGUID,\n String assetManagerName,\n boolean assetManagerIsHome,\n String templateGUID,\n ExternalIdentifierProperties externalIdentifierProperties,\n TemplateProperties templateProperties) throws InvalidParameterException,\n UserNotAuthorizedException,\n PropertyServerException;", "@Deprecated // Use TrcApplicationContext\n URI getApiEndpoint();", "EndpointDetails getEndpointDetails();", "public static String adjustVantiqTarget(String baseUrl, boolean noSsl) throws CamelException {\n String correctedUrl = null;\n String protocol = \"https\";\n if (noSsl) {\n // This is used in development or edge servers.\n protocol = \"http\";\n }\n try {\n URI vtqUri = new URI(baseUrl);\n if (vtqUri.getScheme().equalsIgnoreCase(\"vantiq\")) {\n vtqUri = new URI(protocol, null, vtqUri.getHost(), vtqUri.getPort(), vtqUri.getPath(), null,\n null);\n correctedUrl = vtqUri.toASCIIString();\n } else {\n correctedUrl = baseUrl;\n }\n log.trace(\"Adjusted Vantiq URL: {} (from {})\", correctedUrl, baseUrl);\n } catch (URISyntaxException uriSE) {\n throw new CamelException(\"Unable to connect to provided URI: \" + baseUrl +\n \" (adjusted: \" + correctedUrl + \")\", uriSE);\n }\n return correctedUrl;\n }", "public String getUriString() {\n return \"mina:\" + getProtocol() + \":\" + getHost() + \":\" + getPort();\n }", "private String getBaseUri() {\n\t\treturn null;\n\t}", "public final String getEndpointOverrideUrl() {\n return properties.get(ENDPOINT_OVERRIDE_URL_PROPERTY);\n }", "void setBaseUri(String baseUri);", "public Endpoint getEndpoint(String uri) {\n Endpoint answer;\n synchronized (endpoints) {\n answer = endpoints.get(uri);\n if (answer == null) {\n try {\n\n String splitURI[] = ObjectHelper.splitOnCharacter(uri, \":\", 2);\n if (splitURI[1] != null) {\n String scheme = splitURI[0];\n Component component = getComponent(scheme);\n\n if (component != null) {\n answer = component.createEndpoint(uri);\n\n if (answer != null && LOG.isDebugEnabled()) {\n LOG.debug(uri + \" converted to endpoint: \" + answer + \" by component: \"+ component);\n }\n }\n }\n if (answer == null) {\n answer = createEndpoint(uri);\n }\n\n if (answer != null && answer.isSingleton()) {\n startServices(answer);\n endpoints.put(uri, answer);\n \tlifecycleStrategy.onEndpointAdd(answer);\n }\n } catch (Exception e) {\n throw new ResolveEndpointFailedException(uri, e);\n }\n }\n }\n return answer;\n }", "public void setEndpointInterface(String endpointInterface)\r\n {\r\n this.endpointInterface = endpointInterface;\r\n }", "private String getPingUri() {\n\t\treturn BASE_URI + \"?_wadl\";\n\t}", "java.lang.String getUri();", "java.lang.String getUri();", "public void setEndpointAddress(java.lang.String portName, java.lang.String address) throws javax.xml.rpc.ServiceException {\n \nif (\"publicService\".equals(portName)) {\n setpublicServiceEndpointAddress(address);\n }\n else \n{ // Unknown Port Name\n throw new javax.xml.rpc.ServiceException(\" Cannot set Endpoint Address for Unknown Port\" + portName);\n }\n }", "@Override\n public URI createUri(String url) {\n try {\n this.uri = new URI(url);\n } catch (URISyntaxException e) {\n e.printStackTrace();\n }\n return uri;\n }", "String getUri();", "URISegmentWithParameter createURISegmentWithParameter();", "public String getEndpointId()\n {\n return endpointId; // Field is final; no need to sync.\n }", "public void setEndpointAddress(java.lang.String portName, java.lang.String address) throws javax.xml.rpc.ServiceException {\r\n \r\nif (\"PublishAPIServiceSoap\".equals(portName)) {\r\n setPublishAPIServiceSoapEndpointAddress(address);\r\n }\r\n else \r\n{ // Unknown Port Name\r\n throw new javax.xml.rpc.ServiceException(\" Cannot set Endpoint Address for Unknown Port\" + portName);\r\n }\r\n }", "public String getUri();" ]
[ "0.70834357", "0.661958", "0.652771", "0.63322186", "0.6290597", "0.62129146", "0.60801333", "0.6054193", "0.596823", "0.5922479", "0.5912255", "0.5855527", "0.58389586", "0.5672686", "0.5657092", "0.5621561", "0.5604965", "0.55847484", "0.558382", "0.55740297", "0.55647945", "0.5529159", "0.55205876", "0.55119634", "0.5471024", "0.5447908", "0.5439516", "0.5439516", "0.5429746", "0.54257435", "0.53990066", "0.53894776", "0.53704035", "0.53590363", "0.5356531", "0.534972", "0.53425896", "0.5316122", "0.5314465", "0.53126293", "0.5305474", "0.52929604", "0.5262866", "0.52526915", "0.5251497", "0.5251497", "0.5248981", "0.52325016", "0.5224204", "0.52093065", "0.5202944", "0.5193027", "0.51903945", "0.5189482", "0.517832", "0.5173712", "0.51506245", "0.51435655", "0.5129378", "0.51228386", "0.5110244", "0.50837624", "0.50714034", "0.5064297", "0.504698", "0.5029735", "0.5014556", "0.5013228", "0.4987362", "0.49871853", "0.49674678", "0.49669686", "0.49509856", "0.49415314", "0.49412176", "0.4941036", "0.49326718", "0.49201873", "0.49109855", "0.49056354", "0.49050975", "0.490339", "0.48998526", "0.489292", "0.4881495", "0.4880558", "0.4879797", "0.48795193", "0.48713487", "0.4868629", "0.4867931", "0.48651627", "0.48651627", "0.4858058", "0.4857606", "0.48499885", "0.4844948", "0.4841624", "0.4840154", "0.48388526" ]
0.8138989
0
Adjust Vantiq URL. If using a standard vantiq:// connection, set the adjusted URL to a more reasonable protocol. If the URL does not have a scheme of "vantiq", then leave it alone. No adjustment is necessary
public static String adjustVantiqTarget(String baseUrl, boolean noSsl) throws CamelException { String correctedUrl = null; String protocol = "https"; if (noSsl) { // This is used in development or edge servers. protocol = "http"; } try { URI vtqUri = new URI(baseUrl); if (vtqUri.getScheme().equalsIgnoreCase("vantiq")) { vtqUri = new URI(protocol, null, vtqUri.getHost(), vtqUri.getPort(), vtqUri.getPath(), null, null); correctedUrl = vtqUri.toASCIIString(); } else { correctedUrl = baseUrl; } log.trace("Adjusted Vantiq URL: {} (from {})", correctedUrl, baseUrl); } catch (URISyntaxException uriSE) { throw new CamelException("Unable to connect to provided URI: " + baseUrl + " (adjusted: " + correctedUrl + ")", uriSE); } return correctedUrl; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "protected static void setURL(PURL u, String protocol, String host, int port,\n\t\t String authority, String userInfo, String path,\n String query, String ref) {\n\n\t// ensure that no one can reset the protocol on a given URL.\n u.set(u.getProtocol(), host, port, authority, userInfo, path, query, ref);\n }", "IParser setServerBaseUrl(String theUrl);", "private GenericUrl generateFitbitVitalConnectUrl(Vital vitalToSync, OAuth oAuth) {\n final String user_id = oAuth.getUser_id();\n String additionalPart = vitalToSync.getType().getFitbitURL();\n return new GenericUrl(fitBitBaseURL + \"/\" + user_id + additionalPart);\n }", "@DisplayName(\"The URL for the Marketcetera Exchange Server\")\n public void setURL(@DisplayName(\"The URL for the Marketcetera Exchange Server\")\n String inURL);", "public void changeUrl() {\n url();\n }", "public void setOrigURL(String v) {\n if (MetadataUGWD_Type.featOkTst && ((MetadataUGWD_Type)jcasType).casFeat_origURL == null)\n jcasType.jcas.throwFeatMissing(\"origURL\", \"de.aitools.ie.uima.type.argumentation.MetadataUGWD\");\n jcasType.ll_cas.ll_setStringValue(addr, ((MetadataUGWD_Type)jcasType).casFeatCode_origURL, v);}", "public void setUrl(String tmp) {\n this.url = tmp;\n }", "public void setServerUrl(String newUrl) {\n if(newUrl == null){\n return;\n }\n props.setProperty(\"url\", newUrl);\n saveProps();\n }", "private URL mergeUrl(URL providerUrl) {\n\n providerUrl = ClusterUtils.mergeUrl(providerUrl, queryMap);\n\n List<Configurator> localConfigurators = this.configurators;\n if (!Objects.isNull(localConfigurators) && localConfigurators.size() > 0){\n for (Configurator configurator : localConfigurators) {\n configurator.configure(providerUrl);\n }\n }\n\n providerUrl = providerUrl.addParameter(Constants.CHECK_KEY, String.valueOf(false));\n\n this.overrideDirectoryUrl = this.overrideDirectoryUrl.addParametersIfAbsent(providerUrl.getParameters());\n if ((Objects.isNull(providerUrl.getPath()) || providerUrl.getPath().length() == 0) && \"mandal\".equals(providerUrl.getProtocol())){\n String path = directoryUrl.getParameter(Constants.INTERFACE_KEY);\n if (!Objects.isNull(path)){\n int i = path.indexOf(\"/\");\n if (i >= 0){\n path = path.substring(i + 1);\n }\n i = path.lastIndexOf(':');\n if (i >= 0){\n path = path.substring(0, i);\n }\n providerUrl = providerUrl.setPath(path);\n }\n }\n return providerUrl;\n }", "private String createUrlWithPort(String gadgetUrl) {\n try {\n URL origUrl = new URL(gadgetUrl);\n URL urlWithPort = null;\n String origHost = origUrl.getHost();\n if (origUrl.getPort() <= 0 && origHost != null && origHost.length() != 0\n && !STAR.equals(origHost)) {\n if (origUrl.getProtocol().equalsIgnoreCase(HTTP)) {\n urlWithPort = new URL(origUrl.getProtocol(), origUrl.getHost(), HTTP_PORT, origUrl.getFile());\n }\n else if (origUrl.getProtocol().equalsIgnoreCase(HTTPS)) {\n urlWithPort = new URL(origUrl.getProtocol(), origUrl.getHost(), HTTPS_PORT, origUrl.getFile());\n }\n return urlWithPort == null ? origUrl.toString() : urlWithPort.toString();\n } else {\n return origUrl.toString();\n }\n } catch (MalformedURLException e) {\n return gadgetUrl;\n }\n }", "public URL standardizeURL(URL startingURL);", "String rewriteUrl(String originalUrl);", "public final static String transformUrl(String url) {\n \n int c = url.indexOf('?');\n if (c > -1) {\n url = url.substring(0, c);\n }\n \n // temporary work around to enable authorization on opendap URLs\n url = url.replace(\"dodsC\", \"fileServer\").replace(\".ascii\", \"\").replace(\".dods\", \"\").replace(\".das\", \"\").replace(\".ddds\", \"\");\n \n return url;\n }", "private String makeServerUrl(){\n\t\tURL url = null;\n\t\t\n\t\t//Make sure we have a valid url\n\t\tString complete = this.preferences.getString(\"server\", \"\");\n\t\ttry {\n\t\t\turl = new URL( complete );\n\t\t} catch( Exception e ) {\n\t\t\tonCreateDialog(DIALOG_INVALID_URL).show();\n\t\t\treturn null;\n\t\t}\n\t\treturn url.toExternalForm();\n\t}", "protected String adjustHost(final String host) {\n if (host.startsWith(HTTP_PROTOCOL)) {\n return host.replace(HTTP_PROTOCOL, EMPTY_STRING);\n } else if (host.startsWith(HTTPS_PROTOCOL)) {\n return host.replace(HTTPS_PROTOCOL, EMPTY_STRING);\n }\n return host;\n }", "public NewReferenceValueStrategy replaceWithFullUrl() {\n return update -> linkProperties.r4().readUrl(update.resourceType(), update.newResourceId());\n }", "public static URL adjustURL(URL resource) throws MalformedURLException {\n \t\tString urlStr = resource.getFile();\n \t\tif (urlStr.startsWith(\"file://\"))\n \t\t\turlStr.replaceFirst(\"file://localhost\", \"file://\");\n \t\telse\n \t\t\turlStr = \"file:///\" + urlStr;\n \t\treturn new URL(urlStr);\n \t}", "public void setHTTP_URL(String url) {\r\n\t\ttry {\r\n\t\t\tURL u = new URL(url);\r\n\t\t\tu.toURI();\r\n\t\t} catch (MalformedURLException e) {\r\n\t\t\tSystem.out.println(e.getMessage());\r\n\t\t} catch (URISyntaxException e) {\r\n\t\t\tSystem.out.println(e.getMessage());\r\n\t\t}\r\n\t\tthis.settings.setProperty(\"HTTP_URL\", url);\r\n\t\tthis.saveChanges();\r\n\t}", "@Override\n public String createEndpointUri() {\n \n Properties scProps = utils.obtainServerConfig();\n String baseUri = scProps.getProperty(TARGET_SERVER_PROPERTY_NAME);\n String accessToken = scProps.getProperty(AUTH_TOKEN_PROPERTY_NAME);\n String sourceName = scProps.getProperty(SOURCES_PROPERTY_NAME);\n String sendPings = scProps.getProperty(SEND_PING_PROPERTY_NAME);\n if (StringUtils.isEmpty(baseUri) || StringUtils.isEmpty(accessToken)) {\n throw new IllegalArgumentException(\"source.config file is missing or does not contain sufficient \" +\n \"information from which to construct an endpoint URI.\");\n }\n if (StringUtils.isEmpty(sourceName) || sourceName.contains(\",\")) {\n throw new IllegalArgumentException(\"Default vantiq: endpoints require a source.config file with a single\" +\n \" source name. Found: '\" + sourceName + \"'.\");\n }\n \n try {\n URI vantiqURI = new URI(baseUri);\n this.setEndpointUri(baseUri);\n String origScheme = vantiqURI.getScheme();\n \n StringBuilder epString = new StringBuilder(vantiqURI.toString());\n epString.append(\"?sourceName=\").append(sourceName);\n this.sourceName = sourceName;\n epString.append(\"&accessToken=\").append(accessToken);\n this.accessToken = accessToken;\n if (sendPings != null) {\n epString.append(\"&sendPings=\").append(sendPings);\n this.sendPings = Boolean.parseBoolean(sendPings);\n }\n if (origScheme.equals(\"http\") || origScheme.equals(\"ws\")) {\n epString.append(\"&noSsl=\").append(\"true\");\n noSsl = true;\n }\n epString.replace(0, origScheme.length(), \"vantiq\");\n URI endpointUri = URI.create(String.valueOf(epString));\n return endpointUri.toString();\n } catch (URISyntaxException mue) {\n throw new IllegalArgumentException(TARGET_SERVER_PROPERTY_NAME + \" from server config file is invalid\",\n mue);\n }\n }", "public void setURL(String url);", "public sparqles.avro.discovery.DGETInfo.Builder setURL(java.lang.CharSequence value) {\n validate(fields()[2], value);\n this.URL = value;\n fieldSetFlags()[2] = true;\n return this; \n }", "private GenericUrl generateAPIURL(Vital vitalToSync, OAuth oAuth) {\n GenericUrl url = null;\n switch (vitalToSync.getWearableType()) {\n case FITBIT:\n url = generateFitbitVitalConnectUrl(vitalToSync, oAuth);\n break;\n case WITHINGS:\n //TODO: Create withings URL\n url = new GenericUrl(withingsBaseURL);\n logger.warn(\"WITHINGS CONNECTION NOT IMPLEMENTED\");\n break;\n }\n return url;\n }", "@Test\n public void testMakeRelativeURL3() throws Exception {\n URL base = new URL(\"http://ahost.invalid/a/b/c\");\n assertEquals(new URL(\"http://host.invalid/e\"),ConversionUtils.makeRelativeURL(base ,\"http://host.invalid/e\"));\n assertEquals(new URL(\"https://host.invalid/e\"),ConversionUtils.makeRelativeURL(base ,\"https://host.invalid/e\"));\n assertEquals(new URL(\"http://host.invalid:8081/e\"),ConversionUtils.makeRelativeURL(base ,\"http://host.invalid:8081/e\"));\n assertEquals(new URL(\"https://host.invalid:8081/e\"),ConversionUtils.makeRelativeURL(base ,\"https://host.invalid:8081/e\"));\n }", "public void setURL(String _url) { url = _url; }", "public void setUrl(String url){\n this.URL3 = url;\n }", "public static String removeProtocolAndTrailingSlash(String url , boolean toLowerCase) {\n return removeTrailingSlash(removeProtocal(toLowerCase ? url.toLowerCase() : url));\n }", "private String resolveAbsoluteURL(String defaultUrlContext, String urlFromConfig, String tenantDomain) throws IdentityProviderManagementServerException {\n\n if (!IdentityTenantUtil.isTenantQualifiedUrlsEnabled() && StringUtils.isNotBlank(urlFromConfig)) {\n if (log.isDebugEnabled()) {\n log.debug(\"Resolved URL:\" + urlFromConfig + \" from file configuration for default url context: \" +\n defaultUrlContext);\n }\n return urlFromConfig;\n }\n\n try {\n ServiceURLBuilder serviceURLBuilder = ServiceURLBuilder.create().setTenant(tenantDomain);\n return serviceURLBuilder.addPath(defaultUrlContext).build().getAbsolutePublicURL();\n } catch (URLBuilderException e) {\n throw IdentityProviderManagementException.error(IdentityProviderManagementServerException.class,\n \"Error while building URL: \" + defaultUrlContext, e);\n }\n }", "public void setUrl(String newUrl) {\r\n\t\turl = newUrl;\r\n\t\t\r\n\t\ttry {\r\n\t\t\tif (cn != null) {\r\n\t\t\t\tcn.close();\r\n\t\t\t}\r\n\t\t} catch (SQLException e) {\r\n\t\t\te.printStackTrace();\r\n\t\t}\r\n\t\tcn = null;\r\n\t\tinit();\r\n\t}", "public Builder setVmUrl(\n String value) {\n if (value == null) {\n throw new NullPointerException();\n }\n bitField0_ |= 0x00000002;\n vmUrl_ = value;\n onChanged();\n return this;\n }", "public void updateKBeaconToEddyUrl() {\n if (!mBeacon.isConnected()) {\n return;\n }\n\n //change parameters\n KBCfgCommon commonPara = new KBCfgCommon();\n KBCfgEddyURL urlPara = new KBCfgEddyURL();\n try {\n //set adv type to iBeacon\n commonPara.setAdvType(KBAdvType.KBAdvTypeEddyURL);\n\n //url para\n urlPara.setUrl(\"https://www.google.com/\");\n } catch (KBException excpt) {\n toastShow(\"input data invalid\");\n excpt.printStackTrace();\n }\n\n ArrayList<KBCfgBase> cfgList = new ArrayList<>(2);\n cfgList.add(commonPara);\n cfgList.add(urlPara);\n mBeacon.modifyConfig(cfgList, new KBeacon.ActionCallback() {\n @Override\n public void onActionComplete(boolean bConfigSuccess, KBException error) {\n if (bConfigSuccess)\n {\n toastShow(\"config data to beacon success\");\n }\n else\n {\n toastShow(\"config failed for error:\" + error.errorCode);\n }\n }\n });\n }", "public String fixForScheme(String url) {\n\t\tStringBuffer returnUrl = new StringBuffer(url);\n\t\tif(StringUtils.contains(url, \"returnurl=\"))\n\t\t{\n\t\t\treturnUrl = new StringBuffer(StringUtils.substring(url,0, \n\t\t\t\t\tStringUtils.indexOf(url, \"returnurl=\")));\n\t\t\t\n\t\t\treturnUrl.append(\"returnurl=\");\n\t\t\tString returnurl = StringUtils.substring(url, \n\t\t\t\t\tStringUtils.indexOf(url, \"returnurl=\")+10);\n\t\t\t\n\t\t\ttry {\n\t\t\t\treturnUrl.append(URLEncoder.encode(new String(Base64.encodeBase64(returnurl.getBytes())),\"UTF-8\"));\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}\n\t\treturn returnUrl.toString();\n\t}", "public void setURL() {\n\t\tURL = Constant.HOST_KALTURA+\"/api_v3/?service=\"+Constant.SERVICE_KALTURA_LOGIN+\"&action=\"\n\t\t\t\t\t\t+Constant.ACTION_KALTURA_LOGIN+\"&loginId=\"+Constant.USER_KALTURA+\"&password=\"+Constant.PASSWORD_KALTURA+\"&format=\"+Constant.FORMAT_KALTURA;\n\t}", "void setUrl(String url) {\n this.url = Uri.parse(url);\n }", "public static String removeProtocal(String url) {\n String u = url;\n int in = u.indexOf(\"://\");\n if (in > 0) { \n u = u.substring(in + 3);\n }\n return u;\n }", "public String convertString() {\n\t\tString urlToConvert = tfURL.getText();\n\t\tString is_youtube_link_s = \"youtu.be\";\n\t\tif (urlToConvert.contains(\"watch?v=\")) {\n\t\t\tnew_URL = urlToConvert.replace(\"watch?v=\", \"embed/\");\n\t\t} else if (urlToConvert.contains(is_youtube_link_s)) {\n\t\t\tnew_URL = urlToConvert.replace(\"youtu.be\", \"youtube.com/embed\");\n\t\t}\n\t\ttfNewURL.setText(new_URL);\n\t\tSystem.out.println(new_URL);\n\t\treturn new_URL;\n\t}", "private String getURL() {\n String url = profileLocation.getText().toString();\n if (url == null || url.length() == 0) {\n return url;\n }\n // if it's not the last (which should be \"Raw\") choice, we'll use the prefix\n if (!url.contains(\"://\")) { // if there is no (http|jr):// prefix, we'll assume it's a http://bit.ly/ URL\n url = \"http://bit.ly/\" + url;\n }\n return url;\n }", "public static String fixUrlFromPathInfo(final String pathInfo) {\n\t\treturn pathInfo.replaceAll(\":/([^/])\", \"://$1\");\n\t}", "public void setUrl(String url);", "public void setUrl(String url);", "private String normalizeHostName(String host) {\n if (host == null || host.length() == 0) {\n host = AddressUtils.getHostToAdvertise();\n } else {\n if (URLUtil.hasScheme(host)) {\n host = URLUtil.removeScheme(host);\n }\n }\n\n return host;\n }", "public String mopUrl2RealUrl(String url) {\n LOG.mo8825d(\"url \" + url);\n String ret = url.substring(6);\n if (StringUtils.isEmpty(this.mTerminalid)) {\n this.mTerminalid = SystemProperties.get(\"ro.serialno\");\n }\n String user = SWSysProp.getStringParam(\"user_name\", XmlPullParser.NO_NAMESPACE);\n LOG.mo8825d(\"user \" + user);\n String curOisUrl = this.mSdkRemoteManager.getCurOisUrl();\n LOG.mo8825d(\"curOisUrl \" + curOisUrl);\n String ret2 = \"http://\" + curOisUrl.replace(\"5001\", \"5000/\") + ret + \".m3u8?protocal=hls&user=\" + user + \"&tid=\" + this.mTerminalid + \"&sid=\" + ((MediaBean) this.mAllChannelList.get(this.clickIndex)).getId() + \"&type=stb&token=\" + this.mSdkRemoteManager.getOisToken();\n LOG.mo8825d(\"mopUrl2RealUrl \" + ret2);\n return ret2;\n }", "LDAPUrl( com.github.terefang.jldap.ldap.LDAPUrl novellURL ){\n this.url = novellURL;\n }", "private void setUrl(\n java.lang.String value) {\n value.getClass();\n bitField0_ |= 0x00000001;\n url_ = value;\n }", "private void setUrl(\n java.lang.String value) {\n value.getClass();\n bitField0_ |= 0x00000002;\n url_ = value;\n }", "private static String getBaseUrl() {\n StringBuilder url = new StringBuilder();\n url.append(getProtocol());\n url.append(getHost());\n url.append(getPort());\n url.append(getVersion());\n url.append(getService());\n Log.d(TAG, \"url_base: \" + url.toString());\n return url.toString();\n }", "public static void setTestConnectionUrl(String url) {\n TEST_CONNECTION_URL = url;\n }", "@Test\n void setUrl() {\n g.setUrl(url);\n assertEquals(url, g.getUrl(), \"URL mismatch\");\n }", "void setQueryRequestUrl(String queryRequestUrl);", "private String extractRealUrl(String url) {\n return acceptsURL(url) ? url.replace(\"p6spy:\", \"\") : url;\n }", "public String getUnproxiedFieldDataServerUrl() {\n\t\tSharedPreferences prefs = PreferenceManager.getDefaultSharedPreferences(ctx);\n\t\tString hostName = prefs.getString(\"serverHostName\", \"\");\n\t\tString context = \"bdrs-core\";//prefs.getString(\"contextName\", \"\");\n\t\tString path = prefs.getString(\"path\", \"\");\n\t\t\n\t\tStringBuilder url = new StringBuilder();\n\t\turl.append(\"http://\").append(hostName).append(\"/\").append(context);\n\t\t\n\t\tif (path.length() > 0) {\n\t\t\turl.append(\"/\").append(path);\n\t\t}\n\t\t\n\t\treturn url.toString();\n\t}", "@Override\n protected URLConnection openConnection(URL url, Proxy proxy) throws IOException {\n\n final HttpsURLConnectionImpl httpsURLConnection = (HttpsURLConnectionImpl) super.openConnection(url, proxy);\n if (\"artisan.okta.com\".equals(url.getHost()) && \"/home/amazon_aws/0oad7khqw5gSO701p0x7/272\".equals(url.getPath())) {\n\n return new URLConnection(url) {\n @Override\n public void connect() throws IOException {\n httpsURLConnection.connect();\n }\n\n public InputStream getInputStream() throws IOException {\n byte[] content = IOUtils.toByteArray(httpsURLConnection.getInputStream());\n String contentAsString = new String(content, \"UTF-8\");\n\n //System.out.println(\"########################## got stream content ##############################\");\n //System.out.println(contentAsString);\n ByteArrayOutputStream baos = new ByteArrayOutputStream();\n //contentAsString = contentAsString.replaceAll(\",\\\"ENG_ENABLE_SCRIPT_INTEGRITY\\\"\", \"\"); // nested SRIs?\n baos.write(contentAsString.replaceAll(\"integrity ?=\", \"integrity.disabled=\").getBytes(\"UTF-8\"));\n return new ByteArrayInputStream(baos.toByteArray());\n }\n\n public OutputStream getOutputStream() throws IOException {\n return httpsURLConnection.getOutputStream();\n }\n\n };\n\n } else {\n return httpsURLConnection;\n }\n }", "public void setURL(java.lang.CharSequence value) {\n this.URL = value;\n }", "void addHadithUrl(Object newHadithUrl);", "public void setVideoUrl(String newVideoUrl) {\n this.videoUrl = newVideoUrl;\n }", "public void setServer(URL url) {\n\n\t}", "public void setUrl(String url) {\n\t\tthis.url = utf8URLencode(url);\n\t}", "Builder addUrl(String value);", "public static String formatUrl(String url) {\n if (!url.startsWith(\"http://\") && !url.startsWith(\"https://\")) {\n url = \"http://\" + url;\n }\n return url;\n }", "@Override\n protected String inferProtocol() {\n return \"http\";\n }", "public static String setRemoteUrlReplacements(Project project) {\n String replacements = SourcegraphConfig.getInstance(project).getRemoteUrlReplacements();\n if (replacements == null || replacements.length() == 0) {\n Properties props = readProps();\n replacements = props.getProperty(\"remoteUrlReplacements\", null);\n }\n return replacements;\n }", "public static String setURL(String endpoint) {\n String url = hostName + endpoint;\n\n log.info(\"Enpoint: \" + endpoint);\n\n return url;\n\n }", "public static String getDongtuServerUrl() {\n return BaseAppServerUrl.videoUrl + \"?service=\";\n }", "public void setURL(java.lang.String uRL) {\n this.uRL = uRL;\n }", "public void uriParse() {\n uri = Uri.parse(getUrlVideo());\n }", "@Override\n\tpublic String buildURL(String string) {\n\t\treturn null;\n\t}", "public static String formURL(String url)\n\t{\n\t\tString newurl;\n\t\tif (url.contains(\"http://\") || url.contains(\"https://\"))\n\t\t{\n\t\t\tnewurl = url;\n\t\t}\n\t\telse\n\t\t{\n\t\t\tnewurl = \"http://\" + url;\n\t\t}\n\t\treturn newurl;\n\t}", "Builder addSameAs(URL value);", "protected static ConfigurationOption<URL> createUrlOption(String key, URL dflt) {\r\n return new ConfigurationOption<URL>(key, dflt, PropertyReader.URL_READER);\r\n }", "@Deprecated\n/* */ protected void setURL(URL paramURL, String paramString1, String paramString2, int paramInt, String paramString3, String paramString4) {\n/* 572 */ String str1 = null;\n/* 573 */ String str2 = null;\n/* 574 */ if (paramString2 != null && paramString2.length() != 0) {\n/* 575 */ str1 = (paramInt == -1) ? paramString2 : (paramString2 + \":\" + paramInt);\n/* 576 */ int i = paramString2.lastIndexOf('@');\n/* 577 */ if (i != -1) {\n/* 578 */ str2 = paramString2.substring(0, i);\n/* 579 */ paramString2 = paramString2.substring(i + 1);\n/* */ } \n/* */ } \n/* */ \n/* */ \n/* */ \n/* */ \n/* 586 */ String str3 = null;\n/* 587 */ String str4 = null;\n/* 588 */ if (paramString3 != null) {\n/* 589 */ int i = paramString3.lastIndexOf('?');\n/* 590 */ if (i != -1) {\n/* 591 */ str4 = paramString3.substring(i + 1);\n/* 592 */ str3 = paramString3.substring(0, i);\n/* */ } else {\n/* 594 */ str3 = paramString3;\n/* */ } \n/* 596 */ } setURL(paramURL, paramString1, paramString2, paramInt, str1, str2, str3, str4, paramString4);\n/* */ }", "public final URL mo15944a(String str) {\n try {\n return new URL(String.format(\"https://%s/%s/%s\", new Object[]{\"firebaseinstallations.googleapis.com\", \"v1\", str}));\n } catch (MalformedURLException e) {\n throw new C4291f(e.getMessage(), C4291f.C4292a.UNAVAILABLE);\n }\n }", "private static String composeApiUrl(String string){\r\n\t\treturn API_BASE + API_VERSION + string;\r\n\t}", "public static String convertUrlToPunycodeIfNeeded(String url) {\n if (!Charset.forName(\"US-ASCII\").newEncoder().canEncode(url)) {\n if (url.toLowerCase().startsWith(\"http://\")) {\n url = \"http://\" + IDN.toASCII(url.substring(7));\n } else if (url.toLowerCase().startsWith(\"https://\")) {\n url = \"https://\" + IDN.toASCII(url.substring(8));\n } else {\n url = IDN.toASCII(url);\n }\n }\n return url;\n }", "public native final void setUrl(String url)/*-{\n this.url = url;\n }-*/;", "private void setURL(String url) {\n try {\n URL setURL = new URL(url);\n } catch (IOException e) {\n throw new RuntimeException(e);\n }\n }", "public static String normalizeUrl(String url) throws URISyntaxException {\n\t\tURI uri = new URI(url);\n\t\tString scheme = uri.getScheme().toLowerCase();\n\t\tString authority = uri.getAuthority().toLowerCase();\n\t\tint port = uri.getPort();\n\t\t\n\t\tStringBuilder sb = new StringBuilder();\n\t\tsb.append(scheme)\n\t\t .append(\"://\")\n\t\t .append(authority);\n\t\t\n\t\t//Port\n\t\tif (port != -1 &&\n\t\t\t((\"http\".equals(scheme) && 80 != port) ||\n\t\t\t (\"https\".equals(scheme) && 443 != port))) {\n\t\t\tsb.append(\":\").append(port);\n\t\t}\n\t\t\n\t\t//Path\n\t\tsb.append(uri.getPath());\n\t\treturn sb.toString();\n\t}", "private String getUrlBaseForLocalServer() {\n\t HttpServletRequest request = ((ServletRequestAttributes) \n\t\t\t RequestContextHolder.getRequestAttributes()).getRequest();\n\t String base = \"http://\" + request.getServerName() + ( \n\t (request.getServerPort() != 80) \n\t \t\t ? \":\" + request.getServerPort() \n\t\t\t\t : \"\");\n\t return base;\n\t}", "public void setDPURL(String value){\n\t\tthis.m_bIsDirty = (this.m_bIsDirty || (!value.equals(this.m_sDPURL)));\n\t\tthis.m_sDPURL=value;\n\t}", "public UvScanUrl(String stringID , String baseUrl)\r\n\t{\r\n\t\tthis.stringID = stringID;\r\n\t\tthis.baseUrl = baseUrl;\r\n\t\t\r\n\t\t\r\n\t\tfollowsConfigUrlPattern = false;\r\n\t\tfollowsConfigRedirectedUrlPattern = false;\r\n\t\t\r\n\t\tfollowsExactConfigUrlPattern = false;\r\n\t\tfollowsExactConfigRedirectedUrlPattern = false;\r\n\t\t\r\n\t\tisBaseUrlLocalized = false;\r\n\t\tisRedirectedUrlLocalized = false;\r\n\t\t\r\n\t\tisDeleted=false;\r\n\t\tisErrorPage= true;\r\n\r\n\t\texceptionType =UrlExceptionLevel.None;\r\n\t\t\r\n\t\tbaseUrlPatternMatchResult = \"\";\r\n\t\tredirectedUrlPatternMatchResult = \"\";\r\n\t\t\r\n\t\texceptionOccurred = \"\";\r\n\t}", "@Override\n\t\t\tpublic void onConnectRemoteNode(String url) {\t \t\t\t\n\t\t\t}", "public abstract String getURL();", "public void setVoteurl(String voteurl) {\n this.voteurl = voteurl;\n }", "protected void setURL(URL paramURL, String paramString1, String paramString2, int paramInt, String paramString3, String paramString4, String paramString5, String paramString6, String paramString7) {\n/* 538 */ if (this != paramURL.handler) {\n/* 539 */ throw new SecurityException(\"handler for url different from this handler\");\n/* */ }\n/* 541 */ if (paramString2 != null && paramURL.isBuiltinStreamHandler(this)) {\n/* 542 */ String str = IPAddressUtil.checkHostString(paramString2);\n/* 543 */ if (str != null) throw new IllegalArgumentException(str);\n/* */ \n/* */ } \n/* 546 */ paramURL.set(paramURL.getProtocol(), paramString2, paramInt, paramString3, paramString4, paramString5, paramString6, paramString7);\n/* */ }", "public void setHL7ServerLocationURL(String val) {\n\t\tmLocationURL = val;\n\t}", "protected abstract String getPublicUrl(URL url);", "public String fixURIPrefixIssue(String sql, Map<String, String> v2prefix) {\n\t\tString varPtn = \"CAST\\\\(CONCAT\\\\('(http[^,]*)', (((?!CHAR\\\\(8000\\\\) CHARACTER SET utf8\\\\) AS `).)*)\\\\) AS CHAR\\\\(8000\\\\) CHARACTER SET utf8\\\\) AS `([^`]*)`\";\n\t\tPattern r = Pattern.compile(varPtn);\n\t\t\n\t\tMatcher m = r.matcher(sql);\n\t\tString newSQL = \"\";\n\t\tint curPos = 0;\n\t\twhile(m.find()) {\n\t\t\tString v = m.group(4);\n\t\t\tString prefix = m.group(1);\n\t\t\tString fieldConstruct = m.group(2);\n\t\t\tif (fieldConstruct.indexOf(\",\") > 0) {\n\t\t\t\tfieldConstruct = String.format(\"concat(%s)\", fieldConstruct);\n\t\t\t}\n\t\t\tnewSQL += String.format(\"%s%s AS `%s`\", sql.substring(curPos, m.start()),\n\t\t\t\t\tfieldConstruct, v);\n\t\t\tcurPos = m.end();\n\t\t\tv2prefix.put(v, prefix);\n\t\t}\n\t\tnewSQL += sql.substring(curPos);\n\t\t_logger.info(String.format(\"[%s] converted to new SQL: [%s]\", sql, newSQL));\n\t\treturn newSQL;\n\t}", "@Test\n public void testResolveUrl() {\n System.out.println(\"resolveUrl\");\n String svcia = SVCID;\n String expResult = \"http://localhost:4848/reliablemessaging/intermediary\";\n String result = instance.resolveUrl(svcia);\n assertEquals(expResult, result);\n }", "public TagTAS(String newurl) {\n\t\tstrbaseUrlTas=newurl;\n\t\ttry {\n\t\t\turlTas = new URL(newurl);\n\t\t} catch (MalformedURLException e) {\n\t\t\te.printStackTrace();\n\t\t\turlValid=false;\n\t\t}\n\t\turlValid=true;\n\t\t\n\t\t\n\t}", "@Test\n public void testNormalizeToStringWithSpaceURL() throws Exception {\n AbstractURLHandler handler = new TestURLHandler();\n String normalizedUrl = handler.normalizeToString(new URL(\n \"http://ant.apache.org/ivy/url with space/ivy-1.0.xml\"));\n assertEquals(\"http://ant.apache.org/ivy/url%20with%20space/ivy-1.0.xml\", normalizedUrl);\n }", "static String makeAuId(String baseUrlPath) {\n String baseUrlHost = \"import%2Elockss%2Eorg\";\n return PLUGIN_KEY + \"&base_url~http%3A%2F%2F\" + baseUrlHost + \"%2F\"\n\t+ baseUrlPath;\n }", "public String getCorrectURL() {\n\t\treturn defineCorrectURL(); \t\r\n\t}", "private String buildSearchURL(String companyTicker) {\n Uri.Builder builder = new Uri.Builder();\n builder.scheme(\"https\")\n .authority(\"finance.google.com\")\n .appendPath(\"finance\")\n .appendPath(\"info\")\n .appendQueryParameter(\"client\", \"iq\")\n .appendQueryParameter(\"q\", companyTicker);\n String myUrl = builder.build().toString();\n return myUrl; // return a url\n }", "public static String getURLRedirect(){\n\t\treturn \"https://54.247.74.173:8443\";\r\n\t}", "public void determineBaseUrl() {\n if (Environment.isLatest()) {\n baseUrl = \"api-latest.wdpro.starwave.com\";\n } else if (Environment.isStage()) {\n baseUrl = \"api-stage.wdpro.starwave.com\";\n } else if (Environment.isENV4()) {\n baseUrl = \"api-latest.wdpro.starwave.com\";\n } else if (Environment.isENV2()) {\n // baseUrl = \"api-qa.wdpro.disney.go.com:8088\";\n baseUrl = \"api-env2.wdpro.starwave.com\";\n } else if (Environment.isSoftLaunch()) {\n baseUrl = \"api.wdpro.disney.go.com\";\n } else if (Environment.isShadow()) {\n baseUrl = \"api-shadow.wdpro.starwave.com\";\n } else if (Environment.isProduction()) {\n baseUrl = \"api.wdpro.disney.go.com\";\n } else {\n baseUrl = \"api.wdpro.disney.go.com\";\n }\n }", "public void setHttpEquiv(String newValue);", "public void createURL(){\n urlDB = ( PREFACE + server + \"/\" + database + options);\n }", "public void SetUrl(String url)\n\t{\n\t if (video_view.isPlaying())\n\t {\n\t video_view.stopPlayback();\n\t }\n\t \n Uri uri = Uri.parse(url);\n video_view.setVideoURI(uri);\n\t}", "public String generateQueryPath(String str, AVRequestParams aVRequestParams) {\n return buildUrl(str, aVRequestParams);\n }", "@Override\n\tpublic String shortenUrl(String longUrl){\n\t\tString encodedUrl = \"\";\n\t\tInteger hashKey = (int) UUID.nameUUIDFromBytes(longUrl.getBytes()).getMostSignificantBits();\n\t\tencodedUrl = Integer.toString(hashKey, 36);\n\t\treturn \"http://localhost:8080/URLShortner/short/\" +encodedUrl;\n\t}", "protected void setBrokerOptions(ClientOptions clientOptions, String brokerUrl) {\n\n String uriProtocol = null;\n if (Boolean.parseBoolean(clientOptions.getOption(ClientOptions.CON_RECONNECT).getValue())) {\n // use failover mechanism by default, discovery otherwise\n uriProtocol = ClientOptions.FAILOVER_PROTO;\n }\n if (uriProtocol != null) {\n checkAndSetOption(ClientOptions.PROTOCOL, uriProtocol, clientOptions);\n // Set the whole url as failoverUrl. Do not parse it. connection options should come as input \"conn-*\"\n\n // failover:(dhcp-75-212.lab.eng.brq.redhat.com:5672,dhcp-75-219.lab.eng.brq.redhat.com:5672) -->\n // failover:(tcp://dhcp-75-212.lab.eng.brq.redhat.com:5672,tcp://dhcp-75-219.lab.eng.brq.redhat.com:5672) -->\n // TODO discovery..\n // discovery:(tcp://dhcp-75-212.lab.eng.brq.redhat.com:5672,tcp://dhcp-75-219.lab.eng.brq.redhat.com:5672) -->\n brokerUrl = appendMissingProtocol(brokerUrl);\n\n // If Failover-url list contains a broker value, add it here\n if (clientOptions.getOption(ClientOptions.CON_FAILOVER_URLS).hasParsedValue()) {\n StringBuilder failoverBrokers = new StringBuilder(\",\");\n String reconnectBrokers = clientOptions.getOption(ClientOptions.CON_FAILOVER_URLS).getValue();\n\n for (String brokerFailover : reconnectBrokers.split(\",\")) {\n failoverBrokers.append(appendMissingProtocol(brokerFailover)).append(\",\");\n }\n failoverBrokers.deleteCharAt(failoverBrokers.length() - 1);\n brokerUrl += failoverBrokers;\n }\n\n checkAndSetOption(ClientOptions.FAILOVER_URL, brokerUrl, clientOptions);\n } else {\n super.setBrokerOptions(clientOptions, brokerUrl);\n }\n }", "private static String fixRemoteAddress(String remoteAddress) {\n if (remoteAddress.contains(\"%\")) {\n remoteAddress = remoteAddress.substring(0, remoteAddress.indexOf(\"%\"));\n }\n return remoteAddress;\n }" ]
[ "0.5495141", "0.54482615", "0.5360441", "0.5356293", "0.53462327", "0.52482754", "0.5202981", "0.519136", "0.51898754", "0.51505613", "0.514298", "0.51376015", "0.51181865", "0.5074385", "0.50692326", "0.5054834", "0.4975772", "0.49703315", "0.49599916", "0.49561635", "0.49270606", "0.4915246", "0.4909305", "0.4893442", "0.4893317", "0.48788983", "0.48778048", "0.48753658", "0.48623133", "0.48606932", "0.4856076", "0.48232073", "0.4822742", "0.48169664", "0.4812017", "0.4795386", "0.4776075", "0.4770732", "0.4770732", "0.47608945", "0.4756919", "0.47485", "0.47434333", "0.4734623", "0.47336903", "0.47206777", "0.47159338", "0.47149217", "0.4712483", "0.47112843", "0.47094163", "0.47026277", "0.4701447", "0.46946964", "0.46912494", "0.4683425", "0.46780828", "0.46780097", "0.46766925", "0.46652883", "0.4642409", "0.46317887", "0.46305108", "0.4629787", "0.46256006", "0.46195936", "0.46105474", "0.46046335", "0.46018934", "0.45932263", "0.45882607", "0.45802313", "0.4574543", "0.45737672", "0.45723742", "0.45696145", "0.4568014", "0.45674917", "0.45663783", "0.45602176", "0.4560048", "0.4558809", "0.45522317", "0.45493796", "0.45461702", "0.454591", "0.45457402", "0.4545471", "0.4544318", "0.45439935", "0.4541862", "0.4537099", "0.45324332", "0.4530542", "0.452679", "0.45183244", "0.45156", "0.45116767", "0.45097506", "0.45093456" ]
0.69139254
0
TODO: Pool min/max sizes should be configurable in URI or properties
public ExecutorService createExecutor() { return getCamelContext().getExecutorServiceManager().newThreadPool(this, endpointName, 1, 5); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "OMMPool getPool();", "int getPoolSize();", "public int getPoolSize() {\n return poolSize;\n }", "protected abstract void createPool();", "int getMinPoolSize();", "int getMaxPoolSize();", "private void initialisePools() {\r\n Integer[] bigPoolInts = {25, 50, 75, 100};\r\n Integer[] smallPoolInts = {1,2,3,4,5,6,7,8,9,10,1,2,3,4,5,6,7,8,9,10};\r\n bigPool = new ArrayList<Integer>( Arrays.asList(bigPoolInts) );\r\n smallPool = new ArrayList<Integer>(Arrays.asList(smallPoolInts));\r\n //mix them up\r\n Collections.shuffle( bigPool );\r\n Collections.shuffle( smallPool );\r\n }", "int getPoolNumber();", "public void setPoolSize(int aPoolSize) {\n poolSize = aPoolSize;\n }", "@Override\n\tpublic synchronized StorageOperationResponse<GetStoragePoolsResponse> getStoragePools(\n\t\t\tGetStoragePoolsRequest request) {\n\t\tlogger.log(IJavaEeLog.SEVERITY_DEBUG, this.getClass().getName(), \"getStoragePools: request:\" + request, null);\n\t\tGetStoragePoolsResponse payload = new GetStoragePoolsResponse();\n\t\tArrayList<StoragePool> storagePools = new ArrayList<StoragePool>();\n\t\tList<String> zones = null;\n\t\t BlockLimits blockLimits=openstackClient.getBlockStorageLimits();\n\t\t long totalSpaceGB=blockLimits.getAbsolute().getMaxTotalVolumeGigabytes();\n\t\t long usedSpaceGB=blockLimits.getAbsolute().getTotalGigabytesUsed();\n\t\t \n\t\tif (request.storageSystemId != null) {\n\t\t\tString region = openstackClient.getOpenstackId(request.storageSystemId);\n\t\t\ttry {\n\t\t\t\tzones = openstackClient.listAvailabilityZones(region);\n\t\t\n\t\t\t} catch (Exception e) {\n\t\t\t\tlogger.traceThrowable(IJavaEeLog.SEVERITY_DEBUG, this.getClass().getName(), \"getStoragePools:\" + e.getMessage(), null,e);\n\t\t\t \treturn StorageAdapterImplHelper.createFailedResponse(e.getMessage(), GetStoragePoolsResponse.class); \n\t\t\t}\n\t\t\n\t\t\tfor (String zone:zones) {\n\t\t\t\tstoragePools.add(OpenstackAdapterUtil.createStoragePool(zone, region, accountId, totalSpaceGB, usedSpaceGB));\n\t\t\t}\n\t\t\n\t\t} else {\n\t\t if (request.storagePoolIds == null || request.storagePoolIds.isEmpty()) {\n\t\t\t return StorageAdapterImplHelper.createFailedResponse(\"Bad request: both storageSystemId and storagePoolIds are null\", GetStoragePoolsResponse.class); \n\t\t }\n\t\t try {\n \n\t\t\t String zone = null;\n\t\t\t String region = null;\t\t \n\t\t\t for (String poolId:request.storagePoolIds) {\n\t\t\t\tif (poolId == null || poolId.indexOf(':') == -1) {\n\t\t\t\t\tstoragePools.add(null);\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\t\t\t\tzone = openstackClient.getOpenstackId(poolId);\n\t\t\t\tregion = openstackClient.getRegion(poolId);\n\t\t\t\t if (zone.equals(OpenstackConstants.Openstack_POOL_SNAPSHOTS)) {\n\t\t\t\t\t storagePools.add(OpenstackAdapterUtil.createStoragePool(OpenstackConstants.Openstack_POOL_SNAPSHOTS, region, accountId,totalSpaceGB, usedSpaceGB));\n\t\t\t\t } else {\n\t\t\t\t zones = openstackClient.listAvailabilityZones(region);\n\t\t\t\t if (zones.contains(zone)) {\n\t\t\t\t \tstoragePools.add(OpenstackAdapterUtil.createStoragePool(zone, region, accountId,totalSpaceGB, usedSpaceGB));\t\n\t\t\t\t\t} else {\n\t\t\t\t storagePools.add(null);\n\t\t\t\t }\n\t\t\t\t }\n\t\t\t }\n\n\t\t } catch (Exception e) {\n\t\t\tlogger.traceThrowable(IJavaEeLog.SEVERITY_DEBUG, this.getClass().getName(), \"getStoragePools:\" + e.getMessage(), null,e);\n\t\t\treturn StorageAdapterImplHelper.createFailedResponse(e.getMessage(), GetStoragePoolsResponse.class); \n\t\t }\n\t\t \n\t\t}\n\t\tlogger.log(IJavaEeLog.SEVERITY_DEBUG, this.getClass().getName(), \"getStoragePools: pools found: \" + storagePools.size() + \" pools: \" + storagePools , null);\n\t\tpayload.storagePools = storagePools;\n\t\tStorageOperationResponse<GetStoragePoolsResponse> response = new StorageOperationResponse<GetStoragePoolsResponse>(payload);\n\t\tresponse.setPercentCompleted(100);\n\t\tresponse.setStatus(StorageOperationStatus.COMPLETED);\n\t\treturn response;\n\t}", "int getMaximumPoolSize();", "private int getPoolSize() {\n\t\tint numberOfTasks = SpectralDescriptionType.values().length;\n\t\tint procs = Runtime.getRuntime().availableProcessors();\n\t\treturn numberOfTasks < procs ? numberOfTasks : procs > 1 ? procs - 1\n\t\t\t\t: 1;\n\t}", "private static void useFixedSizePool(){\n ExecutorService executor = Executors.newFixedThreadPool(10);\n\n System.out.println(((ThreadPoolExecutor) executor).getActiveCount());\n\n IntStream.range(0, 20).boxed().forEach(i -> {\n executor.execute(() -> {\n sleepSeconds(10);\n System.out.println(Thread.currentThread().getName() + \"[\" + i + \"]\");\n });\n });\n sleepSeconds(1);\n System.out.println(((ThreadPoolExecutor) executor).getActiveCount());\n }", "public int getActivePoolSize(){return activePoolSize;}", "public void setPoolSize(final int poolSize) {\n this.poolSize = poolSize;\n }", "public BlockingObjectPool(int size) {\n synchronized (pool) {\n range(0, size)\n .forEach(i -> pool.add(new Object()));\n }\n }", "@DefaultValue(\"20\")\n int getApiClientThreadPoolSize();", "int getChunkSize();", "public int getMaxPoolSize(Env env) {\n return client.getMaxPoolSize();\n }", "private void initPool() throws SQLException {\n\t\tint POOL_SIZE = 90;\n\t\tthis.connectionPool = new LinkedBlockingQueue<>(POOL_SIZE);\n\t\tfor(int i = 0; i < POOL_SIZE; i++) {\n\t\t\tConnection con = DriverManager.getConnection(dburl, user, password);\n\t\t\tconnectionPool.offer(con);\n\t\t}\n\t}", "public final int getCapacity()\n {\n return m_pool.length;\n }", "long getChunkSize();", "long getChunkSize();", "long getChunkSize();", "long getChunkSize();", "void setPoolNumber(int poolNumber);", "public Mono<PoolCollection> getPools(Integer limit, Integer offset) throws WebClientResponseException {\n Object postBody = null;\n // create path and map variables\n final Map<String, Object> pathParams = new HashMap<String, Object>();\n\n final MultiValueMap<String, String> queryParams = new LinkedMultiValueMap<String, String>();\n final HttpHeaders headerParams = new HttpHeaders();\n final MultiValueMap<String, String> cookieParams = new LinkedMultiValueMap<String, String>();\n final MultiValueMap<String, Object> formParams = new LinkedMultiValueMap<String, Object>();\n\n queryParams.putAll(apiClient.parameterToMultiValueMap(null, \"limit\", limit));\n queryParams.putAll(apiClient.parameterToMultiValueMap(null, \"offset\", offset));\n\n final String[] localVarAccepts = { \n \"application/json\"\n };\n final List<MediaType> localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);\n final String[] localVarContentTypes = { };\n final MediaType localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);\n\n String[] localVarAuthNames = new String[] { };\n\n ParameterizedTypeReference<PoolCollection> localVarReturnType = new ParameterizedTypeReference<PoolCollection>() {};\n return apiClient.invokeAPI(\"/pools\", HttpMethod.GET, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);\n }", "private void readPools(String bucketToFind) throws ConfigurationException {\n // the intent with this method is to encapsulate all of the walking of URIs\n // and populating an internal object model of the configuration to one place\n for (URI baseUri : baseList) {\n try {\n // get and parse the response from the current base uri\n URLConnection baseConnection = urlConnBuilder(null, baseUri);\n String base = readToString(baseConnection);\n if (\"\".equals(base)) {\n getLogger().warn(\"Provided URI \" + baseUri + \" has an empty response... skipping\");\n continue;\n }\n Map<String, Pool> pools = this.configurationParser.parseBase(base);\n\n // check for the default pool name\n if (!pools.containsKey(DEFAULT_POOL_NAME)) {\n getLogger().warn(\"Provided URI \" + baseUri + \" has no default pool... skipping\");\n continue;\n }\n // load pools\n for (Pool pool : pools.values()) {\n URLConnection poolConnection = urlConnBuilder(baseUri, pool.getUri());\n String poolString = readToString(poolConnection);\n configurationParser.loadPool(pool, poolString);\n URLConnection poolBucketsConnection = urlConnBuilder(baseUri, pool.getBucketsUri());\n String sBuckets = readToString(poolBucketsConnection);\n Map<String, Bucket> bucketsForPool = configurationParser.parseBuckets(sBuckets);\n pool.replaceBuckets(bucketsForPool);\n\n }\n // did we find our bucket?\n boolean bucketFound = false;\n for (Pool pool : pools.values()) {\n if (pool.hasBucket(bucketToFind)) {\n bucketFound = true;\n\t\t\tbreak;\n }\n }\n if (bucketFound) {\n for (Pool pool : pools.values()) {\n for (Map.Entry<String, Bucket> bucketEntry : pool.getROBuckets().entrySet()) {\n this.buckets.put(bucketEntry.getKey(), bucketEntry.getValue());\n }\n }\n this.loadedBaseUri = baseUri;\n return;\n }\n } catch (ParseException e) {\n\t\tgetLogger().warn(\"Provided URI \" + baseUri + \" has an unparsable response...skipping\", e);\n\t\tcontinue;\n } catch (IOException e) {\n\t\tgetLogger().warn(\"Connection problems with URI \" + baseUri + \" ...skipping\", e);\n\t\tcontinue;\n }\n\t throw new ConfigurationException(\"Configuration for bucket \" + bucketToFind + \" was not found.\");\n }\n }", "@Override\n public int getMaxCapacity() {\n return 156250000;\n }", "int getExecutorPoolSize();", "@Override\n\tpublic void setConnectionPoolSize(int arg0) {\n\n\t}", "public HttpClient setMaxPoolSize(Env env, NumberValue size) {\n client.setMaxPoolSize(size.toInt());\n return this;\n }", "public BufferPool(int numPages) {\n // some code goes here\n this.numPages = numPages;\n this.bufferPool = new PageBufferPool(numPages);\n }", "int getExecutorLargestPoolSize();", "public GraphPool() {\n\t\tmMetadataPool = new PoolNodeMetadata();\n\t\tmIdentifierPool = new PoolNodeIdentifier(mMetadataPool);\n\t\tmLinkPool = new PoolExpandedLink(mIdentifierPool, mMetadataPool);\n\t}", "public String getDatabaseConnectionPoolMinNumberConnections(){\n \t\treturn getProperty(\"org.sagebionetworks.pool.min.number.connections\");\n \t}", "protected void divideWorkersBySkill() {\n ResourcePool myResourcePool;\n\n for (Person person : this.getPersons()) {\n myResourcePool = this.getResourcePools().get(person.getSkill());\n\n // Create the pool if no other workers have yet been discovered with this skill\n if (myResourcePool == null) {\n myResourcePool = new ResourcePool(new ArrayList<>(), person.getSkill(),\n this.getName());\n this.getResourcePools().put(person.getSkill(), myResourcePool);\n }\n\n myResourcePool.addPerson(person);\n }\n }", "protected interface Pool<T> {\n /** Retrieves the give object from the pool if it is found, or null otherwise. */\n @Nullable\n T get(T input);\n\n /** Stores the given object into the pool. */\n void put(T input);\n\n /** Clears the pool. */\n void clear();\n\n /** Returns the size of the pool. */\n int size();\n }", "public String poolName();", "public void initialize() {\n if (factory == null || poolName == null)\n throw new IllegalStateException(\"Factory and Name must be set before pool initialization!\");\n if (initialized)\n throw new IllegalStateException(\"Cannot initialize more than once!\");\n initialized = true;\n permits = new FIFOSemaphore(maxSize);\n factory.poolStarted(this);\n lastGC = System.currentTimeMillis();\n //fill pool to min size\n fillToMin();\n /*\n int max = maxSize <= 0 ? minSize : Math.min(minSize, maxSize);\n Collection cs = new LinkedList();\n for(int i=0; i<max; i++)\n {\n cs.add(getObject(null));\n }\n while (Iterator i = cs.iterator(); i.hasNext();)\n {\n releaseObject(i.next());\n } // end of while ()\n */\n collector.addPool(this);\n }", "public CacheThreadPool(final int size)\n {\n synchronized (m_lock)\n {\n m_pool = new PooledThread[size];\n \n // We assume that a list is expanded once it reaches half of its capacity\n // and it doesn't harm if the assumption is wrong.\n m_index = new ArrayList(size + 1 + (size / 2));\n }\n }", "int getExecutorMaximumPoolSize();", "public PoolingHttpClientConnectionManager buildPoolingHttpClientConnectionManager(int maxTotal, int defaultMaxPerRoute)\n/* */ {\n/* 203 */ PoolingHttpClientConnectionManager connectionManager = new PoolingHttpClientConnectionManager();\n/* 204 */ connectionManager.setMaxTotal(maxTotal);\n/* 205 */ connectionManager.setDefaultMaxPerRoute(defaultMaxPerRoute);\n/* 206 */ return connectionManager;\n/* */ }", "public BufferPool(int numPages) {\n // some code goes here\n this.pageNum = numPages;\n this.bufferedPages = new ConcurrentHashMap<PageId, Node>();\n currentTransactions = new ConcurrentHashMap<TransactionId, Long>();\n lockManager = new LockManager();\n }", "private BlocksPool() {\n this(DEFAULT_BLOCK_SIZE_BYTES);\n }", "public String getDatabaseConnectionPoolMaxNumberConnections(){\n \t\treturn getProperty(\"org.sagebionetworks.pool.max.number.connections\");\n \t}", "public int getPassivePoolSize(){return passivePoolSize;}", "public ListPool(int capacity) {\n pool = new ArrayBlockingQueue<>(capacity);\n }", "@Test\n public void testLimitPool() {\n List<Pool> subscribedTo = new ArrayList<Pool>();\n Consumer guestConsumer = TestUtil.createConsumer(systemType, owner);\n guestConsumer.setFact(\"virt.is_guest\", \"true\");\n \n consumerCurator.create(guestConsumer);\n Pool parentPool = null;\n \n assertTrue(limitPools != null && limitPools.size() == 2);\n for (Pool p : limitPools) {\n // bonus pools have the attribute pool_derived\n if (null != p.getAttributeValue(\"pool_derived\")) {\n // consume 2 times so one can get revoked later.\n consumerResource.bind(guestConsumer.getUuid(), p.getId(), null,\n 10, null, null, false, null);\n consumerResource.bind(guestConsumer.getUuid(), p.getId(), null,\n 10, null, null, false, null);\n // ensure the correct # consumed from the bonus pool\n assertTrue(p.getConsumed() == 20);\n assertTrue(p.getQuantity() == 100);\n poolManager.refreshPools(owner);\n // double check after pools refresh\n assertTrue(p.getConsumed() == 20);\n assertTrue(p.getQuantity() == 100);\n // keep this list so we don't need to search again\n subscribedTo.add(p);\n }\n else {\n parentPool = p;\n }\n }\n // manifest consume from the physical pool and then check bonus pool quantities\n consumerResource.bind(manifestConsumer.getUuid(), parentPool.getId(), null, 7, null,\n null, false, null);\n for (Pool p : subscribedTo) {\n assertTrue(p.getConsumed() == 20);\n assertTrue(p.getQuantity() == 30);\n poolManager.refreshPools(owner);\n // double check after pools refresh\n assertTrue(p.getConsumed() == 20);\n assertTrue(p.getQuantity() == 30);\n }\n // manifest consume from the physical pool and then check bonus pool quantities.\n // Should result in a revocation of one of the 10 count entitlements.\n consumerResource.bind(manifestConsumer.getUuid(), parentPool.getId(), null, 2, null,\n null, false, null);\n for (Pool p : subscribedTo) {\n assertTrue(p.getConsumed() == 10);\n assertTrue(p.getQuantity() == 10);\n poolManager.refreshPools(owner);\n // double check after pools refresh\n assertTrue(p.getConsumed() == 10);\n assertTrue(p.getQuantity() == 10);\n }\n // system consume from the physical pool and then check bonus pool quantities.\n // Should result in no change in the entitlements for the guest.\n consumerResource.bind(systemConsumer.getUuid(), parentPool.getId(), null, 1, null,\n null, false, null);\n for (Pool p : subscribedTo) {\n assertTrue(p.getConsumed() == 10);\n assertTrue(p.getQuantity() == 10);\n poolManager.refreshPools(owner);\n // double check after pools refresh\n assertTrue(p.getConsumed() == 10);\n assertTrue(p.getQuantity() == 10);\n }\n }", "@Override\r\n public int getMaxConcurrentProcessingInstances() {\r\n return 1;\r\n }", "public boolean isPoolingEnabled();", "public ThreadPool( int totalPoolSize ) {\n\n\tpoolLocked = false;\n\n\ttry {\n\n\t initializePools( null, totalPoolSize );\n\n\t} catch( Exception exc ) {}\n\n }", "ManagePool(List DefaultList,List AllocList)\r\n\t{\r\n\t\tthis.DefaultList = DefaultList;\r\n\t\tthis.AllocList = AllocList;\r\n\t}", "public int getChunkSize() {\n return chunkSize;\n }", "@Test\n public void orgApacheFelixEventadminThreadPoolSizeTest() {\n // TODO: test orgApacheFelixEventadminThreadPoolSize\n }", "int batchSize();", "public static int getNumberCreated() {\n return numberOfPools;\n }", "public BoneCP getPool() {\n return pool;\n }", "private ConnectionPool() {\r\n\t\tResourceManagerDB resourceManager = ResourceManagerDB.getInstance();\r\n\t\tthis.driver = resourceManager.getValue(ParameterDB.DRIVER_DB);\r\n\t\tthis.url = resourceManager.getValue(ParameterDB.URL_DB);\r\n\t\tthis.user = resourceManager.getValue(ParameterDB.USER_DB);\r\n\t\tthis.password = resourceManager.getValue(ParameterDB.PASSWORD_DB);\r\n\t\tthis.poolsize = Integer.parseInt(resourceManager.getValue(ParameterDB.POOLSIZE_DB));\r\n\t}", "public String toString() {\n return poolName + \" [\" + getUsedCount() + \"/\" + (objects == null ? 0 : objects.size()) + \"/\" + (maxSize == 0 ? \"Unlimited\" : Integer.toString(maxSize)) + \"]\";\n }", "@VisibleForTesting\n static int getInstanceThreadPoolSize() {\n return instanceThreadPoolSize;\n }", "public WorkerPool(String name) {\n this.name = name;\n\n log = LogFactory.getLog(WorkerPool.class.getName() + \":\" + name);\n }", "@Test\n public void launchesEventhandlerThreadpoolMaxsizeTest() {\n // TODO: test launchesEventhandlerThreadpoolMaxsize\n }", "public abstract int getMaxIntermediateSize();", "public interface Pool {\n public PooledConnection getConnection();\n\n public void createConnection(int ocunt);\n}", "public void setThreadPoolSize(int size) {\r\n if(size <= 0) {\r\n throw new IllegalArgumentException(\"size invalid: \" + size + \". The size of the threadpool must be greater than 0.\");\r\n }\r\n threadPoolSize = size;\r\n }", "@Override\n public void changeMaxPoolSize(int size) {\n sessionPool.setMaxSize(size);\n }", "public MemManager( int poolSize )\n {\n\n this.poolSize = poolSize;\n memoryPool = new byte[poolSize];\n // creates a twoWayLinkedList that will store HashMaps defining the\n // blocks\n // of free space within our pool\n freeBlock = new HashMap<Integer, Integer>( 1 );\n freeBlock.put( 0, poolSize );\n freeBlockList = new TwoWayLinkedList<HashMap<Integer, Integer>>();\n // Initially adds the entire memory\n freeBlockList.add( freeBlock );\n\n }", "public int getMinPoolSize() {\n return minPoolSize;\n }", "private void readConstantPool() throws IOException, ClassFormatException {\n constant_pool = new ConstantPool(dataInputStream);\n }", "public void setMaxSize(int size) {\n if (initialized)\n throw new IllegalStateException(INITIALIZED);\n maxSize = size;\n if (maxSize != 0 && minSize > maxSize) {\n minSize = maxSize;\n log.warn(\"pool min size set to \" + minSize + \" to stay <= max size\");\n }\n }", "public void setPoolId(Long poolId);", "@Override\n\tpublic long maxSize() {\n\t\treturn Main.chunkStoreAllocationSize;\n\t}", "public synchronized T doCreate() throws PoolException {\n if (maxSize == INFINITE || inUse < maxSize) {\n T item = create();\n inUse++;\n return item;\n } else {\n throw new PoolException(\"pool at capacity: \" + inUse + \" item(s) checked out. \" + getStack().size() + \" items in getStack().\");\n }\n }", "public void setTotalPoolSize(int totalPoolSize) throws ClientsUnderServiceException, IllegalClassException, IllegalAccessException, InstantiationException{\n\n\tif(totalPoolSize == this.totalPoolSize)return;\n\n\tif(totalPoolSize > this.totalPoolSize){\n\n\t for(int i=0;i<(totalPoolSize-this.totalPoolSize);i++){\n\n\t\ttempThreadCapsule=new ThreadCapsule(threadClass);\n\t\ttempThreadCapsule.setActivePool(activePool);\n\t\ttempThreadCapsule.setPassivePool(passivePool);\n\t\tpassivePool.push(tempThreadCapsule);\n\n\t\tactivePoolSize=activePool.getPresentSize();\n\t\tpassivePoolSize=passivePool.getPresentSize();\n\n\t }//for closing\n\n\t}//if closing\n\n\telse{\n\n\t poolLocked=true;\n\n\t int reduce=this.totalPoolSize-totalPoolSize;\n\n\t if(reduce > passivePoolSize){\n\n\t\tpoolLocked=false; \n\t\tthrow new ClientsUnderServiceException(\"Clients under service, cannot reduce pool size\");\n\n\t }//if closing\n\n\t else if(reduce == passivePoolSize){poolLocked=false; return;}\n\t else {passivePool.setSize(this.totalPoolSize-reduce); poolLocked=false;}\n\n\t}//else closing\n\n }", "public abstract int getFromPool(int x);", "int getExecutorCorePoolSize();", "protected abstract int getMaxDesiredSize();", "private void init() {\n\t\tJedisPoolConfig config = new JedisPoolConfig();\r\n\t\tconfig.setMaxTotal(1024);\r\n\t\tconfig.setMaxIdle(200);\r\n\t\tconfig.setMaxWaitMillis(1000);\r\n\t\tconfig.setTestOnBorrow(false);\r\n\t\tconfig.setTestOnReturn(true);\r\n\t\tString ip = \"sg-redis-new.jo1mjq.0001.apse1.cache.amazonaws.com\";\r\n\t\tint port = 6379;\r\n\t\tjedisPool = new JedisPool(config, ip, port);\r\n\t\tlog.info(\"init redis pool[ip:\" + ip + \",port:\" + port + \"]\");\r\n\t}", "public Pool() {\n\t\t// inicializaDataSource();\n\t}", "public int getMaxPoolSize() {\n return maxPoolSize;\n }", "public static void main(String[] args){ new ThreadPoolBlockingServer().processRequests(); }", "int getMaxSetSize(Object modelID) throws Exception;", "public interface PoolStrategy<T> {\n T onPoolExhausted() throws PoolException;\n\n boolean onNoImpactRecycle() throws PoolException;\n }", "private void setSize() {\n width = AppConfig.width;\n height = (int) (AppConfig.width * 0.56);\n requestOptions = new RequestOptions()\n .diskCacheStrategy(DiskCacheStrategy.AUTOMATIC);\n \n }", "public void setMinPoolSize(int minPoolSize) {\n this.minPoolSize = minPoolSize;\n }", "@Override\n public int getNumIdle() {\n return _pool.size();\n }", "private JedisPool getPool() {\n if (pool == null) {\n JedisPoolConfig config = new JedisPoolConfig();\n config.setMinIdle(poolMinIdle);\n config.setMaxIdle(poolMaxIdle);\n config.setMaxTotal(poolMaxTotal);\n pool = new JedisPool(config, host, port, (int) timeout);\n logger.debug(\"Creando jedisPool@ \" + host + \":\" + port + \". MinIdle/MaxIdle/MaxTotal: \" + poolMinIdle + \"/\" + poolMaxIdle + \"/\" + poolMaxTotal + \". Timeout: \" + timeout);\n }\n return pool;\n }", "abstract protected int getCapacity();", "public StealingPool getPool() {\n return pool;\n }", "public void setMinSize(int size) {\n if (initialized)\n throw new IllegalStateException(INITIALIZED);\n minSize = size;\n if (maxSize != 0 && minSize > maxSize) {\n maxSize = minSize;\n log.warn(\"pool max size set to \" + maxSize + \" to stay >= min size\");\n }\n }", "@Override\n public int getMaxConnections() throws ResourceException {\n return Integer.MAX_VALUE;\n }", "protected ClassPool getClassPool() {\r\n return pool;\r\n }", "@Override\n protected List<StoragePool> matchStoragePoolsWithAttributeOn(\n List<StoragePool> allPools, Map<String, Object> attributeMap,\n StringBuffer errorMessage) {\n boolean checkIP = false;\n boolean checkFC = false;\n // If not a block vpool, then everything matches.\n if (false == attributeMap.get(Attributes.vpool_type.toString())\n .equals(VirtualPool.Type.block.name())) {\n return allPools;\n }\n // If Vplex high availability is used, then do not filter on maxPaths because\n // the VPlex itself contains no pools, and the underlying array pools should match\n // regardless of the maxPath settings.\n Object highAvailabilityType = attributeMap.get(Attributes.high_availability_type.toString());\n if (highAvailabilityType != null\n && NullColumnValueGetter.isNotNullValue(highAvailabilityType.toString())) {\n return allPools;\n }\n // If protocols is not specified, can't determine which type of ports to check.\n Set<String> protocols = (Set<String>) attributeMap.get(Attributes.protocols.toString());\n Set<String> vArrays = (Set<String>) attributeMap.get(Attributes.varrays.toString());\n if (protocols != null && protocols.contains(Block.FC.name())) {\n checkFC = true;\n }\n if (protocols != null && protocols.contains(Block.iSCSI.name())) {\n checkIP = true;\n }\n Integer maxPaths = (Integer) attributeMap.get(Attributes.max_paths.toString());\n Map<URI, Integer> cachedUsableFCPorts = new HashMap<URI, Integer>();\n Map<URI, Integer> cachedUsableIPPorts = new HashMap<URI, Integer>();\n Map<URI, Integer> cachedUsableFCHADomains = new HashMap<URI, Integer>();\n Map<URI, Integer> cachedUsableIPHADomains = new HashMap<URI, Integer>();\n List<StoragePool> matchedPools = new ArrayList<StoragePool>();\n Map<URI, StorageSystem> storageSystemMap = new HashMap<URI, StorageSystem>();\n for (StoragePool pool : allPools) {\n URI dev = pool.getStorageDevice();\n StorageSystem system = getStorageSystem(storageSystemMap, pool);\n if (checkFC) {\n if (numberOfUsablePorts(dev, Transport.FC, vArrays, cachedUsableFCPorts, cachedUsableFCHADomains)\n < maxPaths) {\n _logger.info(\"NumPathsMatcher disqualified pool: \" + pool.getNativeGuid()\n + \" max_paths: \" + maxPaths\n + \" because insufficient FC ports\");\n continue;\n }\n // If we need two or more paths, must have at least two HA Domains\n if (!system.getIsDriverManaged()\n && !system.getSystemType().equals(DiscoveredSystemObject.Type.scaleio.name())\n && !system.getSystemType().equals(DiscoveredSystemObject.Type.xtremio.name())\n && !system.getSystemType().equals(DiscoveredSystemObject.Type.ceph.name())) {\n if (maxPaths >= 2 && cachedUsableFCHADomains.get(dev) < 2) {\n _logger.info(\"NumPathsMatcher disqualified pool: \" + pool.getNativeGuid() + \" max_paths: \" + maxPaths\n + \" because insufficient FC cpus (StorageHADomains)\");\n continue;\n }\n }\n }\n if (checkIP) {\n if (numberOfUsablePorts(dev, Transport.IP, vArrays, cachedUsableIPPorts, cachedUsableIPHADomains)\n < maxPaths) {\n _logger.info(\"NumPathsMatcher disqualified pool: \" + pool.getNativeGuid()\n + \" max_paths: \" + maxPaths\n + \" because insufficient IP ports\");\n continue;\n }\n\n StorageDriverManager storageDriverManager = (StorageDriverManager) StorageDriverManager.getApplicationContext().getBean(\n StorageDriverManager.STORAGE_DRIVER_MANAGER);\n // If we need two or more paths, must have at least two HA Domains\n if (!storageDriverManager.isDriverManaged(system.getSystemType())\n && !system.getSystemType().equals(DiscoveredSystemObject.Type.scaleio.name())\n && !system.getSystemType().equals(DiscoveredSystemObject.Type.xtremio.name())\n && !system.getSystemType().equals(DiscoveredSystemObject.Type.ceph.name())) {\n if (maxPaths >= 2 && cachedUsableIPHADomains.get(dev) < 2) {\n _logger.info(\"NumPathsMatcher disqualified pool: \" + pool.getNativeGuid() + \" max_paths: \" + maxPaths\n + \" because insufficient IP cpus (StorageHADomains)\");\n continue;\n }\n }\n }\n matchedPools.add(pool);\n }\n if (CollectionUtils.isEmpty(matchedPools)) {\n errorMessage.append(String.format(\"No storage pool is matching with the VPool maximum path parameter %d. \", maxPaths));\n _logger.error(errorMessage.toString());\n }\n _logger.info(\"NumPathsMatcher maxPaths: \" + maxPaths + \" passed \" + matchedPools.size() + \" pools\");\n return matchedPools;\n }", "public void InitializeMaxNumInstances(int num) {\n }", "public BufferPool(String fileName, int numBuffers)\n throws IOException\n {\n BLOCK_SIZE = 4096;\n // create linked list of buffers, open file, create pointer tempArray\n this.pool = new LinkedList<Buffer>();\n this.buffArr = new Buffer[numBuffers];\n this.file = new RandomAccessFile(fileName, \"rw\");\n this.tempArray = new byte[BLOCK_SIZE];\n\n // initialize all the statistics to zero\n cacheHits = cacheMisses = diskReads = diskWrites = 0;\n\n Buffer newBuf;\n // initialize the appropriate number of buffers\n for (int i = 0; i < numBuffers; i++)\n {\n newBuf = new Buffer(tempArray, -1);\n pool.append(newBuf);\n buffArr[i] = newBuf;\n }\n }", "public List<CaptureTask> loadTaskToTaskPool(int poolSize) {\n\t\treturn null;\r\n\t}", "public MapWorkPool(int nThreads) {\n\t\tthis.nThreads = nThreads;\n\n\t}", "private void init(int threadCount, Type type) {\r\n //The backend starts to polling threads.\r\n mPoolThread=new Thread(){\r\n @Override\r\n public void run() {\r\n Looper.prepare();\r\n mPoolThreadHandler=new Handler(){\r\n @Override\r\n public void handleMessage(Message msg) {\r\n //take a thread from the thread pool and execute it.\r\n mThreadPool.execute(getTask());\r\n try {\r\n mSemaphoreThreadPool.acquire();\r\n } catch (InterruptedException e) {\r\n e.printStackTrace();\r\n }\r\n }\r\n };\r\n //if this thread is finished, release a signal to the handler.\r\n mSemaphorePoolThreadHandler.release();\r\n Looper.loop();\r\n }\r\n };\r\n mPoolThread.start();\r\n //Get the maximum available memory for our service.\r\n int maxMemory= (int) Runtime.getRuntime().maxMemory();\r\n int cacheMemory = maxMemory / 8;//8\r\n mLruCache=new LruCache<String, Bitmap>(cacheMemory){\r\n @Override\r\n protected int sizeOf(String key, Bitmap value) {\r\n return value.getRowBytes()*value.getHeight();\r\n }\r\n };\r\n mThreadPool= Executors.newFixedThreadPool(threadCount);\r\n mTaskQueue=new LinkedList<>();\r\n mType=type==null? Type.LIFO:type;\r\n mSemaphoreThreadPool=new Semaphore(threadCount);\r\n\r\n }", "private int readChunkSize(int desired) {\n return Math.min(availableFirst(), desired);\n }", "public Mono<Pool> createPool(Pool pool) throws WebClientResponseException {\n Object postBody = pool;\n // verify the required parameter 'pool' is set\n if (pool == null) {\n throw new WebClientResponseException(\"Missing the required parameter 'pool' when calling createPool\", HttpStatus.BAD_REQUEST.value(), HttpStatus.BAD_REQUEST.getReasonPhrase(), null, null, null);\n }\n // create path and map variables\n final Map<String, Object> pathParams = new HashMap<String, Object>();\n\n final MultiValueMap<String, String> queryParams = new LinkedMultiValueMap<String, String>();\n final HttpHeaders headerParams = new HttpHeaders();\n final MultiValueMap<String, String> cookieParams = new LinkedMultiValueMap<String, String>();\n final MultiValueMap<String, Object> formParams = new LinkedMultiValueMap<String, Object>();\n\n final String[] localVarAccepts = { \n \"application/json\"\n };\n final List<MediaType> localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);\n final String[] localVarContentTypes = { \n \"application/json\"\n };\n final MediaType localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);\n\n String[] localVarAuthNames = new String[] { };\n\n ParameterizedTypeReference<Pool> localVarReturnType = new ParameterizedTypeReference<Pool>() {};\n return apiClient.invokeAPI(\"/pools\", HttpMethod.POST, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);\n }" ]
[ "0.68830585", "0.65997624", "0.6428758", "0.6415057", "0.6307157", "0.6278332", "0.6170646", "0.61505973", "0.6065459", "0.6041987", "0.6035231", "0.5984352", "0.5978211", "0.59502006", "0.5900191", "0.5896633", "0.5879137", "0.5850322", "0.58495796", "0.57670915", "0.57598066", "0.5722287", "0.5722287", "0.5722287", "0.5722287", "0.5713792", "0.5664182", "0.5656794", "0.5591499", "0.55821204", "0.55815977", "0.5569783", "0.55636966", "0.55513394", "0.5522804", "0.5517672", "0.5512841", "0.5494483", "0.549331", "0.5490633", "0.54859096", "0.54748243", "0.54728496", "0.54497474", "0.5448446", "0.5444189", "0.54374737", "0.5433427", "0.54298383", "0.54296", "0.5409204", "0.5407435", "0.5394548", "0.5375995", "0.5365648", "0.5353456", "0.5349801", "0.5339151", "0.5331406", "0.5323084", "0.5315376", "0.5293216", "0.52912533", "0.5282031", "0.5272817", "0.5272582", "0.52721125", "0.52674246", "0.5265711", "0.52574164", "0.525718", "0.5248825", "0.52458835", "0.523366", "0.52189785", "0.5215544", "0.5205212", "0.5203555", "0.51985234", "0.5198224", "0.5194868", "0.5192509", "0.5192273", "0.51916945", "0.5182917", "0.5161002", "0.515168", "0.5150442", "0.5145794", "0.51421046", "0.5127535", "0.5127144", "0.5118916", "0.5105418", "0.51011294", "0.509982", "0.5099308", "0.50970966", "0.5097055", "0.5090697", "0.50904304" ]
0.0
-1
Sanitize access token for logging
private String accessTokenForLog() { return StringUtils.isEmpty(accessToken) ? "null/empty" : "present"; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public String getToken(final HttpServletRequest request) {\n final String param = ofNullable(request.getHeader(AUTHORIZATION))\n .orElse(request.getParameter(\"t\"));\n\n return ofNullable(param)\n .map(value -> removeStart(value, BEARER))\n .map(String::trim)\n .orElseThrow(() -> new BadCredentialsException(Constants.AUTHENTICATION_FILTER_MISSING_TOKEN));\n }", "public static String getAccessToken() {\n return \"\";\n }", "private String getToken(HttpServletRequest request){\n String header = request.getHeader(\"Authorization\");\n if(header != null && header.startsWith(\"Bearer\"))\n \t// Sacamos al bearer del token\n return header.replace(\"Bearer \", \"\");\n return null;\n }", "public static String invalidToken() {\n\n return holder.format(\"invalidToken\", \"<HIDDEN>\");\n }", "private String prepareSecurityToken() {\r\n\t\tint time = ((int) System.currentTimeMillis() % SECURITY_TOKEN_TIMESTAMP_RANGE);\r\n\t\treturn String.valueOf(time + (new Random().nextLong() - SECURITY_TOKEN_TIMESTAMP_RANGE));\r\n\t}", "String getAccessToken();", "String getAccessToken();", "String getUsernameFromToken(String token);", "public java.lang.String getOauth_token(){\r\n return localOauth_token;\r\n }", "private String getTokenizedUrl() {\n SharedPreferences sharedPreferences = getSharedPreferences();\n String tokenKey = MainActivity.sharedPrefKeys.TOKENIZED_URL.toString();\n\n if (sharedPreferences.contains(tokenKey)) {\n return sharedPreferences.getString(tokenKey, \"\");\n }\n return \"\";\n }", "String httpSafe();", "java.lang.String getToken();", "java.lang.String getToken();", "java.lang.String getToken();", "java.lang.String getToken();", "java.lang.String getToken();", "java.lang.String getToken();", "public String getAccessToken();", "@Override\n protected void doFilterInternal(HttpServletRequest request, HttpServletResponse response, FilterChain chain) throws ServletException, IOException {\n String token = provider.getTokenFromHttpHeader(request);\n\n try {\n if (token != null && provider.validateToken(token)) {\n Authentication authentication = provider.getAuthentication(token);\n SecurityContextHolder.getContext().setAuthentication(authentication);\n }\n } catch (Exception ex) {\n System.out.println(ex);\n SecurityContextHolder.clearContext();\n }\n\n chain.doFilter(request, response);\n }", "private String validateToken(String url, String apiKey, String userId, String format, String token)\n throws AuthenticationFailedException {\n BufferedReader in = null;\n HttpURLConnection urlConnection = null;\n StringBuilder builder;\n if (log.isDebugEnabled()) {\n log.debug(\"Token validation URL: \" + url);\n }\n if (StringUtils.isEmpty(url)) {\n return \"\";\n } else {\n try {\n URL obj = new URL(url + Token2Constants.API + Token2Constants.EQUAL + apiKey + Token2Constants.AMPERSAND +\n Token2Constants.TOKEN + Token2Constants.EQUAL + token + Token2Constants.AMPERSAND +\n Token2Constants.USER_ID + Token2Constants.EQUAL + userId + Token2Constants.AMPERSAND +\n Token2Constants.FORMAT + Token2Constants.EQUAL + format);\n urlConnection = (HttpURLConnection) obj.openConnection();\n urlConnection.setRequestMethod(Token2Constants.GET_METHOD);\n in = new BufferedReader(new InputStreamReader(urlConnection.getInputStream()));\n builder = new StringBuilder();\n String inputLine = in.readLine();\n while (inputLine != null) {\n builder.append(inputLine).append(\"\\n\");\n inputLine = in.readLine();\n }\n if (log.isDebugEnabled()) {\n log.debug(\"response: \" + builder.toString());\n }\n } catch (MalformedURLException e) {\n throw new AuthenticationFailedException(\"Invalid URL\", e);\n } catch (ProtocolException e) {\n throw new AuthenticationFailedException(\"Error while setting the HTTP request method\", e);\n } catch (IOException e) {\n throw new AuthenticationFailedException(\"Error in I/O Streams\" + e.getMessage(), e);\n } finally {\n try {\n if (in != null) {\n in.close();\n }\n } catch (IOException e) {\n log.error(\"Couldn't close the I/O Streams\", e);\n }\n if (urlConnection != null) {\n urlConnection.disconnect();\n }\n }\n return builder.toString();\n }\n }", "String getTokenString();", "private String getAccessToken(String url) {\n int accessTokenIndex = url.indexOf(\"access_token\");\n\n // url would be like www.example.com/access_token=abcd&otherparameters\n int loopStartIndex = accessTokenIndex + \"access_token\".length() + 1;\n int andIndex = url.indexOf(\"&\");\n StringBuilder sb = new StringBuilder(\"\");\n for (int i = loopStartIndex; i < andIndex; i++) {\n sb.append(url.charAt(i));\n }\n return sb.toString();\n }", "@Override\n public void intercept(RequestInterceptor.RequestFacade request) {\n if ((mCredentials != null) && (mCredentials.accessToken != null)) {\n request.addEncodedQueryParam(PARAM_ACCESS_TOKEN, mCredentials.accessToken);\n }\n }", "@Override\n protected void doFilterInternal(HttpServletRequest httpServletRequest, HttpServletResponse httpServletResponse, FilterChain filterChain) throws ServletException, IOException {\n\n String header = httpServletRequest.getHeader(jwtConfig.getHeader());\n\n\n //if(header == null || !header.startsWith(jwtConfig.getPrefix())) {\n // filterChain.doFilter(httpServletRequest, httpServletResponse); \t\t// If not valid, go to the next filter.\n // return;\n // }\n\n\n try{\n String token = header.replace(jwtConfig.getPrefix(), \"\");\n String username = jwtUtils.extractUsername(token);\n\n System.out.println(username);\n\n if (username != null && SecurityContextHolder.getContext().getAuthentication() == null) {\n if (jwtUtils.validateToken(token)) {\n\n UsernamePasswordAuthenticationToken usernamePasswordAuthenticationToken = new UsernamePasswordAuthenticationToken(username, null, null);\n usernamePasswordAuthenticationToken.setDetails(token);\n SecurityContextHolder.getContext().setAuthentication(usernamePasswordAuthenticationToken);\n System.out.println(username);\n }\n }\n\n }catch(Exception e){\n SecurityContextHolder.clearContext();\n }\n\n filterChain.doFilter(httpServletRequest, httpServletResponse);\n }", "void removeAccessToken() {\n SharedPreferences prefs = // because rest also needs token\n context.getSharedPreferences(SHARED_PREFS_NAME, Context.MODE_PRIVATE);\n prefs.edit()\n .remove(KEY_ACCESS_TOKEN)\n .apply();\n // notification to all listeners\n state.onNext(new AuthState(false));\n\n }", "protected void validateToken() {\n\n authToken = preferences.getString(getString(R.string.auth_token), \"\");\n saplynService = new SaplynService(preferences.getInt(debugLvl, -1), authToken);\n\n // Check if user already authenticated\n if (authToken.equals(\"\")) {\n Intent intent = new Intent(HomeActivity.this, AuthenticationActivity.class);\n startActivityForResult(intent, 0);\n }\n else {\n populateUser();\n }\n }", "private String getJwt(HttpServletRequest request) {\n String authHeader = request.getHeader(\"Authorization\");\n if (authHeader != null && authHeader.startsWith(\"Bearer \")) {\n return authHeader.replace(\"Bearer \", \"\");\n }\n return null;\n }", "private boolean validateAccessToken(String clientId, String clientSecret) {\n log.info(\"Client Id:{} Client Secret:{}\", clientId, clientSecret);\n\n // Enable the Below code when the Introspection URL is ready to test\n /**\n * String auth = clientId + clientSecret; RestTemplate restTemplate = new RestTemplate();\n * HttpHeaders headers = new HttpHeaders(); headers.add(\"Content-Type\",\n * MediaType.APPLICATION_JSON_VALUE); headers.add(\"Authorization\", \"Basic \" +\n * Base64.getEncoder().encodeToString(auth.getBytes())); HttpEntity<String> request = new\n * HttpEntity<String>(headers);\n *\n * <p>log.info(\"Sending Token Intropsection request to Endpoint::::: {}\",\n * tokenIntrospectionURL); ResponseEntity<String> response =\n * restTemplate.exchange(tokenIntrospectionURL, HttpMethod.POST, request, String.class); *\n */\n return true;\n }", "private void checkAuthSessionToken() {\n val auth = config.getString(\"authSessionToken\");\n\n checkArgument(auth.length() > 10, \"auth string (sessionToken) length is less than or equal to 10!\");\n }", "public String validateToken(HttpServletRequest request, HttpServletResponse response) {\n String[] cookieTokens = extractAndDecodeCookie(request, response);\n return validateToken(cookieTokens, request, response);\n }", "public static String invalidAuthentication() {\n return holder.format(\"invalidAuthentication\");\n }", "public String getAccess_token() {\r\n\t\treturn access_token;\r\n\t}", "public String getAccessToken() {\n\t\t\n\t\tString access_token = \"\";\n\t\t\n\t\tif (securityContext != null) {\n\t\t\taccess_token = securityContext.getTokenString();\n\t\t}\n\t\t\n\t\treturn access_token;\n\t}", "String getToken();", "String getToken();", "String getToken();", "String getToken();", "String getToken();", "public synchronized String accessToken(String knownInvalidToken) {\n if (accessToken == null || (knownInvalidToken != null && accessToken.equals(knownInvalidToken))) {\n loadTokens();\n }\n\n return accessToken;\n }", "private Boolean ignoreTokenExpiration(String token) {\n return false;\r\n }", "private void clearAccessToken() {\n SharedPreferences sharedPref = this\n .getSharedPreferences(getString(R.string.authorization_preference_file), Context.MODE_PRIVATE);\n if(sharedPref.contains(getResources().getString(R.string.authorization))){\n SharedPreferences.Editor editor = sharedPref.edit();\n editor.remove(getResources().getString(R.string.authorization));\n editor.apply();\n }\n }", "public static /* synthetic */ String m1254a(OAuthTokenProvider oAuthTokenProvider, String str) {\n OAuthToken a = oAuthTokenProvider.mo3469a(str);\n if (a == null) {\n return null;\n }\n oAuthTokenProvider.f1255c.put(str, new n20(a.getAccessToken(), a.getExpiresIn(), System.currentTimeMillis() / 1000));\n oAuthTokenProvider.mo3471a();\n return a.getAccessToken();\n }", "TokenFilter(TokenProvider provider) {\n this.provider = provider;\n }", "public static void setAccessToken(String accessToken) {\n }", "@RequestMapping(value = \"\", method = RequestMethod.GET)\n\tpublic void validateToken(HttpServletRequest request, HttpServletResponse response) throws IOException {\n\t\tString signature = request.getParameter(\"signature\");\n\t\tSystem.out.println(\"signature: \" + signature);\n\t\tString timestamp = request.getParameter(\"timestamp\");\n\t\tSystem.out.println(\"timestamp: \" + timestamp);\n\t\tString nonce = request.getParameter(\"nonce\");\n\t\tSystem.out.println(\"nonce: \" + nonce);\n\t\tString echostr = request.getParameter(\"echostr\");\n\t\tSystem.out.println(\"echostr: \" + echostr);\n\t\tList<String> params = new ArrayList<String>();\n\t\tparams.add(TOKEN);\n\t\tparams.add(timestamp);\n\t\tparams.add(nonce);\n\n\t\tCollections.sort(params, new Comparator<String>() {\n\t\t\tpublic int compare(String o1, String o2) {\n\t\t\t\treturn o1.compareTo(o2);\n\t\t\t}\n\t\t});\n\t\tString temp = SHA1.encode(params.get(0) + params.get(1) + params.get(2));\n\t\tif (temp.equals(signature)) {\n\t\t\tresponse.getWriter().write(echostr);\n\t\t}\n\t}", "@Test\n public void when_token_has_no_prefix_then_user_does_not_get_authentication() throws ServletException, IOException {\n test(\"eyJhbGciOiJQUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiYWRtaW4iOnRydWUsImlhdCI6MTUxNjIzOTAyMn0.hZnl5amPk_I3tb4O-Otci_5XZdVWhPlFyVRvcqSwnDo_srcysDvhhKOD01DigPK1lJvTSTolyUgKGtpLqMfRDXQlekRsF4XhAjYZTmcynf-C-6wO5EI4wYewLNKFGGJzHAknMgotJFjDi_NCVSjHsW3a10nTao1lB82FRS305T226Q0VqNVJVWhE4G0JQvi2TssRtCxYTqzXVt22iDKkXeZJARZ1paXHGV5Kd1CljcZtkNZYIGcwnj65gvuCwohbkIxAnhZMJXCLaVvHqv9l-AAUV7esZvkQR1IpwBAiDQJh4qxPjFGylyXrHMqh5NlT_pWL2ZoULWTg_TJjMO9TuQ\",\n null);\n }", "@Override\n public void handleTokenExpiration(){\n JWTToken.removeTokenSharedPref(this);\n }", "@Override\r\n\tpublic String accessToken() throws OAuthSystemException {\n\t\treturn null;\r\n\t}", "public String getToken();", "@Override\n\t\t\t\t\t\t\tpublic void onTokenIncorrect() {\n\t\t\t\t\t\t\t\t Log.d(\"LoginActivity\", \"--onTokenIncorrect\");\n\t\t\t\t\t\t\t}", "protected static String sanitise(final String name) {\n // Replace illegal chars with\n return name.replaceAll(\"[^\\\\w\\\\.\\\\s\\\\-#&_]\", \"_\");\n }", "AccessToken getOAuthAccessToken(String oauthVerifier) throws MoefouException;", "public interface Sanitizer {\n String sanitize(String input);\n }", "AccessToken getOAuthAccessToken(RequestToken requestToken) throws MoefouException;", "private String escape(String token) {\n return token.replace(\",\" , \"\");\n }", "public static String tokenWithoutPrefix(final String bearerToken) {\n\t\treturn bearerToken.replace(BEARER_TOKEN_PREFIX, \"\");\n\t}", "public static String getAccessToken(Context context){\n\t\t\tSharedPreferences prefs = PreferenceManager.getDefaultSharedPreferences(context);\n\t\t\treturn prefs.getString(TWITTER_ACCESS_TOKEN, null);\n\t\t}", "private void m2192d(String str) {\n this.f980b.m1158c().getSharedPreferences(\"com.facebook.login.AuthorizationClient.WebViewAuthHandler.TOKEN_STORE_KEY\", 0).edit().putString(\"TOKEN\", str).apply();\n }", "@FormUrlEncoded\n @POST(\"/oauth/access_token\")\n Flowable<ResponseBody> getAccessToken(@Field(\"oauth_verifier\") String oauthVerifier);", "private String getTokenTooOldMessage(long currentTimeInMillis, long timeStampSkewMillis, long issuedAtTimeMillis, long rejectBeforeMillis) {\n StringBuilder tmp = new StringBuilder();\n tmp.append(\"JSON Web Token is issued before the allowed time.\");\n tmp.append(\" Issued At Time(ms) : \");\n tmp.append(issuedAtTimeMillis);\n tmp.append(\", Reject before limit(ms) : \");\n tmp.append(rejectBeforeMillis);\n tmp.append(\", TimeStamp Skew : \");\n tmp.append(timeStampSkewMillis);\n tmp.append(\", Current Time : \");\n tmp.append(currentTimeInMillis);\n tmp.append(\". JWT Rejected and validation terminated\");\n return tmp.toString();\n }", "@Override \n public String getHeader(String name) { \n String value = super.getHeader(encodeXSS(name)); \n //the following sentences will be replaced by logging sentence in actual project \n //System.out.println(\"The original value received from getHeader() is:\"+value); \n if (value != null) { \n value = encodeXSS(value); \n } \n \n //the following sentences will be replaced by logging sentence in actual project \n // System.out.println(\"After handling XSS ,the actual value is:\"+value); \n // System.out.println(); \n \n return value; \n }", "Pokemon.RequestEnvelop.AuthInfo.JWT getToken();", "private String sanitizeSpecialChars(String value) {\n return value.replaceAll(\"[^a-zA-Z0-9_]\", \"_\");\n }", "public static String urlSafeRandomToken() {\n SecureRandom random = new SecureRandom();\n byte bytes[] = new byte[20];\n random.nextBytes(bytes);\n Base64.Encoder encoder = Base64.getUrlEncoder().withoutPadding();\n String token = encoder.encodeToString(bytes);\n return token;\n }", "AccessToken getOAuthAccessToken(RequestToken requestToken, String oauthVerifier) throws MoefouException;", "void setAccessToken(String accessToken);", "@Override\n public void filter(ContainerRequestContext requestContext) throws IOException {\n String authorizationHeader = requestContext.getHeaderString(HttpHeaders.AUTHORIZATION);\n\n // Check if the HTTP Authorization header is present and formatted correctly\n if (authorizationHeader == null || !authorizationHeader.startsWith(\"Bearer \")) {\n throw new NotAuthorizedException(\"Authorization header must be provided\");\n }\n\n // Extract the token from the HTTP Authorization header\n String token = authorizationHeader.substring(\"Bearer\".length()).trim();\n\n // Validate the token\n if (!userService.validateToken(token)) {\n requestContext.abortWith(Response.status(Response.Status.UNAUTHORIZED).build());\n }\n }", "public String getAccessToken()\n {\n if (accessToken == null)\n {\n if (DEBUG)\n {\n System.out.println(\"Access token is empty\");\n }\n try\n {\n FileReader fileReader = new FileReader(getCache(\"token\"));\n BufferedReader bufferedReader = new BufferedReader(fileReader);\n accessToken = bufferedReader.readLine();\n if (DEBUG)\n {\n System.out.println(\"BufferReader line: \" + accessToken);\n }\n } catch (FileNotFoundException e)\n {\n e.printStackTrace();\n } catch (IOException e)\n {\n e.printStackTrace();\n }\n }\n return accessToken;\n }", "@Override\r\n protected String appSecret() {\r\n return \"\";\r\n }", "@Test\n @DisplayName(\"valid access token is accepted\")\n public void validOAuthJwtShouldReturnUsername() throws Exception {\n String tokenEndpoint = keycloakContainer.getAuthServerUrl() + \"/realms/calamitaid/protocol/openid-connect/token\";\n var restTemplate = new RestTemplate();\n var headers = new HttpHeaders();\n headers.setContentType(MediaType.APPLICATION_FORM_URLENCODED);\n headers.setBasicAuth(\"pvt-access\", \"6cf9e105-f5cb-477d-9b65-45b40d1df8f8\");\n var map = new LinkedMultiValueMap<>();\n map.add(\"grant_type\", \"password\");\n map.add(\"username\", \"calmuser\");\n map.add(\"password\", \"calm123\");\n var token = restTemplate.postForObject(tokenEndpoint, new HttpEntity<>(map, headers), KeycloakToken.class);\n assertThat(token).isNotNull();\n\n String accessToken = token.getAccessToken();\n\n mvc.perform(MockMvcRequestBuilders.get(\"/protected\")\n .header(\"Authorization\", \"Bearer \" + accessToken))\n .andExpect(status().isOk());\n }", "public static String obtenerTokenAcceso(HttpServletRequest request) {\n String tokenId = \"\";\n try {\n String authorization = request.getHeader(\"Authorization\");\n if (authorization != null && authorization.contains(\"Bearer\")) {\n tokenId = authorization.replace(\"Bearer\", \"\");\n }\n String[] contenidoToken = tokenId.split(\"\\\\.\");\n return contenidoToken[1];\n } catch (Exception e) {\n // TODO: handle exception\n return \"\";\n }\n }", "@Override\n\t\t\t\tpublic void onAuthenticationTokenError(@Nullable String errorMessage) {\n\t\t\t\t\tLog.e(TAG, \"onIdTokenError: Unable to get authentication token, error: \" + errorMessage);\n\t\t\t\t}", "public String getUsernameFromToken() {\n\t\tHttpServletRequest request = ((ServletRequestAttributes) RequestContextHolder.getRequestAttributes()).getRequest();\n\t\tfinal String requestTokenHeader = request.getHeader(AUTH);\n\t\tString jwtToken = requestTokenHeader.substring(BEARER.length());\n\t\treturn getClaimFromToken(jwtToken, Claims::getSubject);\n\t}", "public static String streamingEnabledToken() {\n return \"{\" +\n \" \\\"pushEnabled\\\": true,\" +\n \" \\\"token\\\": \\\"eyJhbGciOiJIUzI1NiIsImtpZCI6IjVZOU05US45QnJtR0EiLCJ0eXAiOiJKV1QifQ.eyJ4LWFibHktY2FwYWJpbGl0eSI6IntcIk16TTVOamMwT0RjeU5nPT1fTVRFeE16Z3dOamd4X01UY3dOVEkyTVRNME1nPT1fbXlTZWdtZW50c1wiOltcInN1YnNjcmliZVwiXSxcIk16TTVOamMwT0RjeU5nPT1fTVRFeE16Z3dOamd4X3NwbGl0c1wiOltcInN1YnNjcmliZVwiXSxcImNvbnRyb2xfcHJpXCI6W1wic3Vic2NyaWJlXCIsXCJjaGFubmVsLW1ldGFkYXRhOnB1Ymxpc2hlcnNcIl0sXCJjb250cm9sX3NlY1wiOltcInN1YnNjcmliZVwiLFwiY2hhbm5lbC1tZXRhZGF0YTpwdWJsaXNoZXJzXCJdfSIsIngtYWJseS1jbGllbnRJZCI6ImNsaWVudElkIiwiZXhwIjoyMjA4OTg4ODAwLCJpYXQiOjE1ODc0MDQzODh9.LcKAXnkr-CiYVxZ7l38w9i98Y-BMAv9JlGP2i92nVQY\\\"\" +\n \"}\";\n\n }", "@Override\n public void authenticate() throws IOException, BadAccessIdOrKeyException {\n try{\n HttpPost post = new HttpPost(Constants.FRGXAPI_TOKEN);\n List<NameValuePair> params = new ArrayList<>();\n params.add(new BasicNameValuePair(\"grant_type\", \"apiAccessKey\"));\n params.add(new BasicNameValuePair(\"apiAccessId\", accessId));\n params.add(new BasicNameValuePair(\"apiAccessKey\", accessKey));\n post.setEntity(new UrlEncodedFormEntity(params, \"UTF-8\"));\n\n HttpResponse response = client.execute(post);\n String a = response.getStatusLine().toString();\n\n if(a.equals(\"HTTP/1.1 400 Bad Request\")){\n throw (new BadAccessIdOrKeyException(\"Bad Access Id Or Key\"));\n }\n HttpEntity entity = response.getEntity();\n String responseString = EntityUtils.toString(response.getEntity());\n\n JsonParser jsonParser = new JsonParser();\n JsonObject jo = (JsonObject) jsonParser.parse(responseString);\n if(jo.get(\"access_token\") == null){\n throw new NullResponseException(\"The Access Token you get is null.\");\n }\n String accessToken = jo.get(\"access_token\").getAsString();\n List<Header> headers = new ArrayList<>();\n headers.add(new BasicHeader(HttpHeaders.CONTENT_TYPE, \"application/json\"));\n headers.add(new BasicHeader(\"Authorization\", \"Bearer \" + accessToken));\n\n client = HttpClients.custom().setDefaultHeaders(headers).build();\n } catch (NullResponseException e) {\n System.out.println(e.getMsg());\n }\n }", "static AccessToken m9937a(Bundle bundle, C2453c cVar, String str) {\n Date a = C2479ad.m9436a(bundle, \"com.facebook.platform.extra.EXPIRES_SECONDS_SINCE_EPOCH\", new Date(0));\n ArrayList stringArrayList = bundle.getStringArrayList(\"com.facebook.platform.extra.PERMISSIONS\");\n String string = bundle.getString(\"com.facebook.platform.extra.ACCESS_TOKEN\");\n if (C2479ad.m9456a(string)) {\n return null;\n }\n AccessToken accessToken = new AccessToken(string, str, bundle.getString(\"com.facebook.platform.extra.USER_ID\"), stringArrayList, null, cVar, a, new Date());\n return accessToken;\n }", "public static String getAccessToken() {\n return accessToken;\n }", "OAuth2Token getToken();", "@SuppressLint(\"CommitPrefEdits\") // Preferences change needs to be synchronous\n public void invalidateToken() {\n preferences.edit().remove(getString(R.string.auth_token)).commit();\n validateToken();\n }", "public static void setAccessToken(String token, Context context){\n\t\t\tSharedPreferences prefs = PreferenceManager.getDefaultSharedPreferences(context);\n\t\t\tSharedPreferences.Editor prefEditor = prefs.edit();\n\t\t\tprefEditor.putString(TWITTER_ACCESS_TOKEN, token);\n\t\t\tprefEditor.commit();\n\t\t\t\n\t\t}", "@Test\n public void testMalformedCredentialsHeader() {\n String header =\n authHeaderBearer(\"malformed_token\");\n\n Response r = target(\"/token\")\n .request()\n .header(AUTHORIZATION, header)\n .get();\n\n assertEquals(Status.UNAUTHORIZED.getStatusCode(), r.getStatus());\n }", "private String encodeTokenString(String tokenPortion) {\n log.info(\"Entering encodeTokenString\");\n String base64EncodedTokenString = Base64.getEncoder().encodeToString(tokenPortion.getBytes());\n String replacedEncodedTokenString = base64EncodedTokenString.replaceAll(\"={1,2}$\", \"\");\n return encodeURILikeJavascript(replacedEncodedTokenString);\n }", "public void storeToken(AuthorizationToken token);", "@Override\r\n\tpublic void filter(ContainerRequestContext requestContext) throws IOException {\n\t String authorizationHeader = \r\n\t requestContext.getHeaderString(HttpHeaders.AUTHORIZATION);\r\n\t \r\n\t // Check if the HTTP Authorization header is present and formatted correctly\r\n\t if (authorizationHeader != null && authorizationHeader.startsWith(\"Bearer \")) {\r\n\t \t\r\n\t \t//abgelaufene Tokens werden gelöscht\r\n\t \tsservice.deleteInvalidTokens();\r\n\t \t\r\n\t \t// Extract the token from the HTTP Authorization header\r\n\t \tString token = authorizationHeader.substring(\"Bearer\".length()).trim();\r\n\t \tif (validateToken(token) == true){\r\n\t \t\t\r\n\t \t\t//Get the user by this token\r\n\t \t User user = authService.getUserByToken(token);\r\n\t \t System.out.println(\"Nutzer: \" + user.toString());\r\n\t \t requestContext.setSecurityContext(new MySecurityContext(user));\r\n\t \t return;\r\n\t \t}\r\n\t }\r\n\t \r\n\t throw new UnauthorizedException(\"Client has to be logged in to access the ressource\");\r\n\t \r\n\t\t\r\n\t}", "private static HashMap<String, String> getHeaderWithAccessToken(\n final String accessToken)\n {\n final HashMap<String, String> headers = new HashMap<String, String>(2);\n headers.put(\"Authorization\", String.format(\"SSO %s\", accessToken));\n headers.put(\"Content-Type\", \"application/json\");\n return headers;\n }", "@PostMapping(\"/token\")\n public ResponseEntity<Object> validateToken(@RequestParam(\"token\") String token) { \t\n \t\tUserLog userlog = authenticationService.authenticateByToken(token); \n \t\tif(userlog == null) {\n \t\t\t// risp.: 401\n \t\t\treturn new ResponseEntity<>(new UserLog(), HttpStatus.NOT_FOUND);\n \t\t}\n \t\treturn new ResponseEntity<>(userlog, HttpStatus.OK); \t\n }", "private String getApiToken(final Account account) {\r\n return account.getStringProperty(PROPERTY_ACCOUNT_api_token);\r\n }", "AccessToken getOAuthAccessToken() throws MoefouException;", "@Test\n public void testTokenEndPointNoParams() throws Exception {\n refreshRequestAndResponse();\n request.setRequestURI(\"/v2/token\");\n request.setMethod(\"POST\");\n handlerAdapter.handle(request, response, controller);\n logger.info(\"testTokenEndPointNoParams() => \" + response.getContentAsString());\n \n assertTrue(response.getContentAsString().contains(ERR_RESPONSE));\n assertTrue( response.getStatus() == HttpServletResponse.SC_BAD_REQUEST ||\n response.getStatus() == HttpServletResponse.SC_UNAUTHORIZED );\n }", "String getShortToken();", "String getShortToken();", "String getShortToken();", "String getShortToken();", "String getShortToken();", "String getShortToken();", "String getShortToken();", "String getShortToken();", "String getShortToken();", "String getShortToken();", "private String filterOutRestEasyError(String error) {\n if (error != null && error.startsWith(RESTEASY_PREFIX) && error.contains(\":\")) {\n return null;\n } else {\n return error;\n }\n }" ]
[ "0.59972626", "0.5472017", "0.5412323", "0.53958964", "0.5348236", "0.5338922", "0.5338922", "0.52456194", "0.5153197", "0.5146844", "0.5113164", "0.5106873", "0.5106873", "0.5106873", "0.5106873", "0.5106873", "0.5106873", "0.50886834", "0.5082802", "0.5051137", "0.50484675", "0.5045792", "0.5031453", "0.50247854", "0.50217897", "0.500268", "0.5000002", "0.49985027", "0.4995872", "0.4946936", "0.49465713", "0.49361897", "0.49298978", "0.49286765", "0.49286765", "0.49286765", "0.49286765", "0.49286765", "0.49257094", "0.49215227", "0.4866962", "0.48653972", "0.48627427", "0.48389852", "0.48379257", "0.48356107", "0.48327884", "0.48310187", "0.48285264", "0.48237887", "0.48204643", "0.48123297", "0.481154", "0.47969472", "0.4794075", "0.4786242", "0.47856495", "0.47733605", "0.47725335", "0.47684476", "0.4750769", "0.47399044", "0.47289753", "0.4728044", "0.47255164", "0.47157735", "0.47114092", "0.47088084", "0.47051504", "0.46956742", "0.46936247", "0.46840277", "0.46824646", "0.46750367", "0.46706054", "0.4659008", "0.46524048", "0.46509984", "0.46418607", "0.46402046", "0.46383393", "0.4632459", "0.4630605", "0.46144375", "0.46116206", "0.46083167", "0.46060959", "0.45983818", "0.45970398", "0.45718515", "0.45718515", "0.45718515", "0.45718515", "0.45718515", "0.45718515", "0.45718515", "0.45718515", "0.45718515", "0.45718515", "0.45703092" ]
0.6005213
0
In private constr we check if instance already initialized and then if someone call this constructor then we throw exception Check in private constructor will block reflection, which made constructor public on runtime
private Singleton2A(){ if(instance != null){ throw new RuntimeException("One instance already created cant create other"); } System.out.println("I am private constructor"); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private DPSingletonLazyLoading(){\r\n\t\tthrow new RuntimeException();//You can still access private constructor by reflection and calling setAccessible(true)\r\n\t}", "@Test( expected = IllegalStateException.class )\n\tpublic void constructorShouldNotBeInstantiable() {\n\t\tnew ReflectionUtil() {\n\t\t\t// constructor is protected\n\t\t};\n\t}", "@Test\n public void testPrivateCtor() throws Exception {\n Constructor<?> privateCtor = Helper.class.getDeclaredConstructors()[0];\n assertTrue(Modifier.isPrivate(privateCtor.getModifiers()));\n privateCtor.setAccessible(true);\n privateCtor.newInstance(new Object[] {});\n }", "private Consts(){\n //this prevents even the native class from \n //calling this ctor as well :\n throw new AssertionError();\n }", "private Validate(){\n //private empty constructor to prevent object initiation\n }", "private Instantiation(){}", "private LazySingleton() {\n if (null != INSTANCE) {\n throw new InstantiationError(\"Instance creation not allowed\");\n }\n }", "private SystemInfo() {\r\n // forbid object construction \r\n }", "Reproducible newInstance();", "private void validateConstructor () throws ModelValidationException\n\t\t\t{\n\t\t\t\t// no constructor or no arg constructor\n\t\t\t\tModel model = getModel();\n\t\t\t\tboolean hasConstr = model.hasConstructor(keyClassName);\n\t\t\t\tObject noArgConstr = \n\t\t\t\t\tmodel.getConstructor(keyClassName, Model.NO_ARGS);\n\t\t\t\tint modifiers = model.getModifiers(noArgConstr);\n\n\t\t\t\tif (hasConstr && \n\t\t\t\t\t((noArgConstr == null) || !Modifier.isPublic(modifiers)))\n\t\t\t\t{\n\t\t\t\t\tthrow new ModelValidationException(keyClass,\n\t\t\t\t\t\tI18NHelper.getMessage(getMessages(), \n\t\t\t\t\t\t\"util.validation.key_class_constructor\", //NOI18N\n\t\t\t\t\t\tkeyClassName, getClassName()));\n\t\t\t\t}\n\t\t\t}", "private ATCres() {\r\n // prevent to instantiate this class\r\n }", "private Foo() {\n\t\tSystem.out.println(\"Private Constructor.\");\n\t}", "@Test\n void constructorTest() {\n super.checkConstruction();\n }", "private SingletonDoubleCheck() {}", "private Security() { }", "private NullSafe()\n {\n super();\n }", "private InterpreterDependencyChecks() {\r\n\t\t// Hides default constructor\r\n\t}", "public StubPrivateConstructorPair() {\r\n this(null, null);\r\n }", "protected Object buildNewInstanceUsingDefaultConstructor() throws DescriptorException {\n try {\n if (PrivilegedAccessHelper.shouldUsePrivilegedAccess()){\n try {\n return AccessController.doPrivileged(new PrivilegedInvokeConstructor(this.getDefaultConstructor(), (Object[])null));\n } catch (PrivilegedActionException exception) {\n Exception throwableException = exception.getException();\n if (throwableException instanceof InvocationTargetException){\n throw DescriptorException.targetInvocationWhileConstructorInstantiationOfFactory(this.getDescriptor(), throwableException);\n } else if (throwableException instanceof IllegalAccessException){\n throw DescriptorException.illegalAccessWhileConstructorInstantiationOfFactory(this.getDescriptor(), throwableException); \n } else {\n throw DescriptorException.instantiationWhileConstructorInstantiationOfFactory(this.getDescriptor(), throwableException); \n }\n }\n } else {\n return PrivilegedAccessHelper.invokeConstructor(this.getDefaultConstructor(), (Object[])null);\n }\n } catch (InvocationTargetException exception) {\n throw DescriptorException.targetInvocationWhileConstructorInstantiation(this.getDescriptor(), exception);\n } catch (IllegalAccessException exception) {\n throw DescriptorException.illegalAccessWhileConstructorInstantiation(this.getDescriptor(), exception);\n } catch (InstantiationException exception) {\n throw DescriptorException.instantiationWhileConstructorInstantiation(this.getDescriptor(), exception);\n } catch (NoSuchMethodError exception) {\n // This exception is not documented but gets thrown.\n throw DescriptorException.noSuchMethodWhileConstructorInstantiation(this.getDescriptor(), exception);\n } catch (NullPointerException exception) {\n // Some JVMs will throw a NULL pointer exception here\n throw DescriptorException.nullPointerWhileConstructorInstantiation(this.getDescriptor(), exception);\n }\n }", "protected abstract void construct();", "public void testConstructor() {\r\n assertNotNull(\"unable to create instance\", instance);\r\n }", "private InstanceUtil() {\n }", "private MigrationInstantiationUtil() {\n\t\tthrow new IllegalAccessError();\n\t}", "private A(){\n System.out.println(\"Instance created\");\n }", "private TagCacheManager(){\n //AssertionError不是必须的. 但它可以避免不小心在类的内部调用构造器. 保证该类在任何情况下都不会被实例化.\n //see 《Effective Java》 2nd\n throw new AssertionError(\"No \" + getClass().getName() + \" instances for you!\");\n }", "private Validations() {\n\t\tthrow new IllegalAccessError(\"Shouldn't be instantiated.\");\n\t}", "public T instantiatePrivate() throws NoSuchMethodException, IllegalAccessException, InvocationTargetException, InstantiationException {\n Constructor<T> constructor = clazz.getDeclaredConstructor();\n constructor.setAccessible(true);\n return constructor.newInstance();\n }", "public void testCtor1() {\r\n try {\r\n new DbBaseFilterFactory(null);\r\n fail(\"IllegalArgumentException expected.\");\r\n } catch (IllegalArgumentException iae) {\r\n //good\r\n }\r\n }", "private Verify(){\n\t\t// Private constructor to prevent instantiation\n\t}", "private ObjectFactory() { }", "private SingletonObject() {\n\n\t}", "public OrderServiceSecurityException() {\n\t}", "@SuppressWarnings(\"unused\")\r\n\tprivate Person() {\r\n\t}", "protected abstract void init() throws Throwable;", "@Override\n public boolean getAllowPrivateConstructors()\n {\n \treturn allowPrivateConstructors;\n }", "defaultConstructor(){}", "private Singleton() {\n if (instance != null){\n throw new RuntimeException(\"Use getInstance() to create Singleton\");\n }\n }", "private Singleton() {\n\t}", "private Ex() {\n }", "@Override\n protected boolean checkConstructorInvocation(AnnotatedDeclaredType dt,\n AnnotatedExecutableType constructor, NewClassTree src) {\n return true;\n }", "protected void _init(){}", "public abstract void init() throws Throwable;", "public void test_ctor() {\n assertNotNull(\"instance should be created.\", instance);\n }", "private void checkInitialization()\n {\n if (!initialized)\n throw new SecurityException(\"VectorStack object is not initialized \" +\n \"properly.\");\n }", "@Override\n public boolean isInstantiable() {\n return false;\n }", "private Singleton() { }", "private Singleton()\n\t\t{\n\t\t}", "private PropertiesLoader() {\r\n\t\t// not instantiable\r\n\t}", "@DSComment(\"Private Method\")\n @DSBan(DSCat.PRIVATE_METHOD)\n @DSGenerator(tool_name = \"Doppelganger\", tool_version = \"2.0\", generated_on = \"2013-12-30 12:32:41.996 -0500\", hash_original_method = \"CB9D9CAF93B6F7C6AC078700B30D5B3A\", hash_generated_method = \"6EEF3712392D06942F0E7086316BBAB4\")\n \n private void nativeConstructor(){\n }", "private Example() {\n\t\tthrow new Error(\"no instantiation is permitted\");\n\t}", "private void checkInitialization()\n {\n if (!initialized)\n throw new SecurityException(\"ArrayQueue object is corrupt.\");\n }", "private ExampleVersion() {\n throw new UnsupportedOperationException(\"Illegal constructor call.\");\n }", "private LOCFacade() {\r\n\r\n\t}", "private EagerInitializedSingleton() {\n\t}", "private EagerInitializedSingleton() {\n\t}", "@Test(expected = IllegalArgumentException.class)\r\n public void constructorExceptionTest(){\n Owner invalid = new Owner(\"First\", \"Last\", \"333\");\r\n }", "protected abstract void init() throws Exception;", "private Validador() {\r\n }", "@SuppressWarnings(\"unused\")\n public NoConstructor() {\n // Empty\n }", "private LazySingleton(){}", "private void _init() throws Exception {\n }", "private Topography()\n\t{\n\t\tthrow new IllegalStateException(\"This is an utility class, it can not be instantiated\");\n\t}", "public void testConstructorNPE2() {\r\n try {\r\n new SimpleCreditCardValidator(null, new ValidationLUHN());\r\n fail(\"an NPE is expected\");\r\n }\r\n catch (NullPointerException npe) {\r\n //pass\r\n }\r\n }", "private PermissionUtil() {\n throw new IllegalStateException(\"you can't instantiate PermissionUtil!\");\n }", "private ContactFactory() {\n throw new AssertionError();\n }", "private void checkInitialization()\n {\n if (!initialized)\n throw new SecurityException(\"ArrayBag object is not initialized \" +\n \"properly.\");\n }", "private Constructor getConstructor() throws Exception {\r\n return type.getConstructor(Contact.class, label, Format.class);\r\n }", "public Constructor(){\n\t\t\n\t}", "private Util()\n {\n // Empty default ctor, defined to override access scope.\n }", "private void _init() throws Exception {\n }", "private void _init() throws Exception {\n }", "private void checkInitialization()\r\n\t{\r\n\t\tif ( !initialized )\r\n\t\t{\r\n\t\t\tthrow new SecurityException( \"Calculator is not properly initialized.\" );\r\n\t\t}//end if\r\n\t}", "private void __sep__Constructors__() {}", "private ChainingMethods() {\n // private constructor\n\n }", "public abstract void init() throws Exception;", "@Test\n\tvoid testConstructor() {\n\t\tassertDoesNotThrow(() -> {UdpCommunicator communicator = this.getCommunicatorImplementation(64324);});\n\t\tassertThrows(IllegalArgumentException.class, () -> {UdpCommunicator communicator = this.getCommunicatorImplementation(-54);});\n\t\tassertThrows(IllegalArgumentException.class, () -> {UdpCommunicator communicator = this.getCommunicatorImplementation(70000);});\n\t}", "private ClassUtil() {}", "@Test\r\n public void testBadConstructor() {\r\n try {\r\n SnakeSquare instance = new SnakeSquare(33,44);\r\n fail();\r\n } catch (IllegalArgumentException e) { }\r\n }", "private Log()\n {\n //Hides implicit constructor.\n }", "private ReflectionUtil()\n {\n }", "private TemplateFactory(){\n //AssertionError不是必须的. 但它可以避免不小心在类的内部调用构造器. 保证该类在任何情况下都不会被实例化.\n //see 《Effective Java》 2nd\n throw new AssertionError(\"No \" + getClass().getName() + \" instances for you!\");\n }", "private EagerInitializationSingleton() {\n\t}", "private Singleton(){}", "private SingleObject()\r\n {\r\n }", "private Supervisor() {\r\n\t}", "private Utils()\n {\n // Private constructor to prevent instantiation\n }", "private SupplierLoaderUtil() {\n\t}", "private Terms(){\n\t\t //this prevents even the native class from calling this ctor as well :\n\t\t throw new AssertionError();\n\t\t }", "private void _init() {\n }", "private static Constructor getZeroArgumentConstructor(Class cls) {\n \t\treturn ClassUtils.getConstructor(cls, new Class[] { }, zeroArgumentConstructors);\n \t}", "private Singleton(){\n }", "@SuppressWarnings(\"unused\")\r\n\tprivate TransporterException(){\r\n\t\t\r\n\t}", "private Facade() {\n }", "@Test\n public void validate_Constructor() {\n try {\n Service testService = new Service(\"Camera Installation\", 250, \"category_test\");\n assertEquals(\"Service getter Failed - name\", \"Camera Installation\", testService.getName());\n assertEquals(\"Service getter Failed - rate\", 250, testService.getRate());\n assertEquals(\"Service getter Failed - categoryID\", \"category_test\", testService.getCategoryKey());\n } catch (InvalidDataException e) {\n fail(\"Availability construction failed. Error: \" + e.getMessage());\n }\n\n // Make sure InvalidDataException is thrown for invalid data\n try {\n new Service(\"Illegal-service+name\", 45, \"categoryKey\");\n fail(\"Service Constructor Failed - Illegal Name\");\n } catch (InvalidDataException ignore) {}\n try {\n new Service(\"service name\", -45, \"categoryKey\");\n fail(\"Service Constructor Failed - Illegal rate\");\n } catch (InvalidDataException ignore) {}\n try {\n new Service(\"service name\", 45, \"\");\n fail(\"Service Constructor Failed - Illegal category key\");\n } catch (InvalidDataException ignore) {}\n\n }", "public void testCtorNPE() {\r\n try {\r\n new UploadRequestValidator(null);\r\n fail(\"if the argument is null, throw NullPointerExcetpion\");\r\n } catch (NullPointerException e) {\r\n // good\r\n }\r\n }", "private MApi() {}", "protected Object buildFactoryUsingDefaultConstructor() throws DescriptorException {\n try {\n if (PrivilegedAccessHelper.shouldUsePrivilegedAccess()){\n try {\n return AccessController.doPrivileged(new PrivilegedInvokeConstructor(this.buildFactoryDefaultConstructor(), (Object[])null));\n } catch (PrivilegedActionException exception) {\n Exception throwableException = exception.getException();\n if (throwableException instanceof InvocationTargetException){\n throw DescriptorException.targetInvocationWhileConstructorInstantiationOfFactory(this.getDescriptor(), throwableException);\n } else if (throwableException instanceof IllegalAccessException){\n throw DescriptorException.illegalAccessWhileConstructorInstantiationOfFactory(this.getDescriptor(), throwableException); \n } else {\n throw DescriptorException.instantiationWhileConstructorInstantiationOfFactory(this.getDescriptor(), throwableException); \n }\n }\n } else {\n return PrivilegedAccessHelper.invokeConstructor(this.buildFactoryDefaultConstructor(), (Object[])null);\n }\n } catch (InvocationTargetException exception) {\n throw DescriptorException.targetInvocationWhileConstructorInstantiationOfFactory(this.getDescriptor(), exception);\n } catch (IllegalAccessException exception) {\n throw DescriptorException.illegalAccessWhileConstructorInstantiationOfFactory(this.getDescriptor(), exception);\n } catch (InstantiationException exception) {\n throw DescriptorException.instantiationWhileConstructorInstantiationOfFactory(this.getDescriptor(), exception);\n } catch (NoSuchMethodError exception) {\n // This exception is not documented but gets thrown.\n throw DescriptorException.noSuchMethodWhileConstructorInstantiationOfFactory(this.getDescriptor(), exception);\n } catch (NullPointerException exception) {\n // Some JVMs will throw a NULL pointer exception here\n throw DescriptorException.nullPointerWhileConstructorInstantiationOfFactory(this.getDescriptor(), exception);\n }\n }", "@Test\n @Order(3)\n void testInvalidClassId() {\n assertNull(noArgsRegistry.getConstructor(0));\n }", "private void setConstructors(Class<?> token) throws ImplerException {\n Constructor<?>[] constructors = token.getDeclaredConstructors();\n if (!token.isInterface() &&\n Arrays.stream(constructors)\n .allMatch(constructor -> Modifier.isPrivate(constructor.getModifiers()))) {\n throw new ImplerException(\"token hasn't non-private constructor\");\n }\n for (Constructor<?> constructor : constructors) {\n setExecutable(constructor, \"\", new StringBuilder(\"super(\"), true);\n }\n }", "private EagerlySinleton()\n\t{\n\t}" ]
[ "0.75005805", "0.7357375", "0.73190284", "0.72503966", "0.7117739", "0.70014304", "0.68349916", "0.6782089", "0.66364545", "0.6621322", "0.6572179", "0.6492476", "0.647039", "0.646954", "0.64529556", "0.6442742", "0.64349097", "0.64034015", "0.6400386", "0.6381032", "0.63808227", "0.6368949", "0.6362901", "0.6360089", "0.6350247", "0.6342998", "0.6340659", "0.633599", "0.63284814", "0.6326372", "0.63253266", "0.6314866", "0.6305442", "0.6301471", "0.6298037", "0.62921345", "0.6287074", "0.6285624", "0.62820715", "0.62771446", "0.62560517", "0.625417", "0.6252957", "0.6243714", "0.62421775", "0.62187237", "0.621773", "0.620274", "0.6191598", "0.6190891", "0.61810654", "0.61807996", "0.61734736", "0.617239", "0.617239", "0.61642647", "0.6157096", "0.61547804", "0.615393", "0.6153257", "0.6141701", "0.6138935", "0.6133711", "0.611241", "0.6097508", "0.6092516", "0.6079052", "0.6073152", "0.60725784", "0.60725534", "0.60725534", "0.60702246", "0.60691816", "0.60621405", "0.60611576", "0.6053052", "0.60529274", "0.6050802", "0.60455185", "0.60402423", "0.6038484", "0.60368395", "0.6028304", "0.6019247", "0.60191125", "0.6012369", "0.6010143", "0.6005712", "0.59966445", "0.59935987", "0.59922993", "0.5985752", "0.5984456", "0.59810346", "0.59763324", "0.5969184", "0.59670115", "0.59658873", "0.5957397", "0.5952926" ]
0.6959553
6
Singleton obj1 = new Singleton(); compiler error as constr is private and cannot be used from outside class
public static void main(String [] args) throws ClassNotFoundException, NoSuchMethodException, SecurityException, InstantiationException, IllegalAccessException, IllegalArgumentException, InvocationTargetException{ Singleton2A obj1 = Singleton2A.getInstance(); Singleton2A obj2 = Singleton2A.getInstance(); printme("obj1", obj1); // obj1, 2018699554 printme("obj2", obj2); // obj2, 2018699554 System.out.println(obj1.equals(obj2)); // true //Breaking singleton code using reflection: Class cls = Class.forName("advjava.Singleton2"); Constructor<Singleton2A> constr = cls.getDeclaredConstructor(); constr.setAccessible(true); // call constructor Singleton2A obj3 = constr.newInstance(); // new object created printme("obj3", obj3); // obj3, 1311053135 System.out.println(obj1.equals(obj3)); // false }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private Singleton(){}", "private SingletonObject() {\n\n\t}", "private Singleton(){\n }", "private SingletonSample() {}", "private Singleton() { }", "private MySingleton() {\r\n\t\tSystem.out.println(\"Only 1 object will be created\");\r\n\t}", "private Singleton() {\n\t}", "private Singleton()\n\t\t{\n\t\t}", "private Singleton()\r\n\t{\r\n\t\tSystem.out.println(\"1st instance of class Singleton created\");\r\n\t\tstr = \"Constructor init\";\r\n\t}", "private SingletonSigar(){}", "private static void createSingletonObject() {\n\t\tSingleton s1 = Singleton.getInstance();\n\t\tSingleton s2 = Singleton.getInstance();\n\n\t\tprint(\"S1\", s1);\n\t\tprint(\"S2\", s2);\n\t}", "private J2_Singleton() {}", "private SingletonDoubleCheck() {}", "private Singleton2A(){\n\t\tif(instance != null){\n\t\t\tthrow new RuntimeException(\"One instance already created cant create other\");\n\t\t}\t\t\n\t\tSystem.out.println(\"I am private constructor\");\n\t}", "private LazySingleton(){}", "static void useSingleton(){\n\t\tSingleton singleton = Singleton.getInstance();\n\t\tprint(\"singleton\", singleton);\n\t}", "private SingletonEager(){\n \n }", "public static Replica1Singleton getInstance() {\r\n\t\tif (instance==null){\r\n\t\t/*System.err.println(\"Istanza creata\");*/\r\n\t\tinstance = new Replica1Singleton();\r\n\t\t}\r\n\t\treturn instance;\r\n\t\r\n\t}", "private Singleton() {\n if (instance != null){\n throw new RuntimeException(\"Use getInstance() to create Singleton\");\n }\n }", "public static void main(String[] args) throws Exception {\n\n Singleton3 ins = Singleton3.getInstance();\n Constructor constructor = Singleton3.class.getDeclaredConstructor();\n constructor.setAccessible(true);\n Singleton3 ins1 = (Singleton3)constructor.newInstance();\n System.out.println(ins == ins1);\n }", "private InnerClassSingleton(){}", "public static Singleton getInstance() {\t\t//getInstance nam omogucava da instanciramo klasu jedinstveno ako vec nismo!\r\n\t\tif (instance == null) {\t\t\t\t\t// inace nam vraca instancu ako je vec napravljena!\r\n\t\t\tinstance = new Singleton();\r\n\t\t}\r\n\t\treturn instance;\r\n\t}", "private SingletonH() {\n System.out.println(Thread.currentThread().getName()\n + \": creating SingletonH\");\n }", "public static Singleton getInstance( ) {\n return singleton;\n }", "public static Singleton getInstance( ) {\n return singleton;\n }", "private SingletonClass()\n {\n s = \"Hello I am a string part of Singleton class\";\n }", "public static void main(String[] args) throws IOException, ClassNotFoundException, NoSuchMethodException, IllegalAccessException, InvocationTargetException, InstantiationException {\n\n Class objectClass = LazyMethodSingleton.class;\n\n Constructor constructor = objectClass.getDeclaredConstructor();\n constructor.setAccessible(true);\n\n LazyMethodSingleton instance = LazyMethodSingleton.getInstance();\n LazyMethodSingleton newInstance = (LazyMethodSingleton) constructor.newInstance();\n\n// HungrySingleton instance = HungrySingleton.getInstance();\n// HungrySingleton newInstance = (HungrySingleton) constructor.newInstance();\n\n// LazyStaticInnerClassSingleton instance = LazyStaticInnerClassSingleton.getInstance();\n// LazyStaticInnerClassSingleton newInstance = (LazyStaticInnerClassSingleton) constructor.newInstance();\n\n System.out.println(instance);\n System.out.println(newInstance);\n System.out.println(instance == newInstance);\n\n\n\n\n }", "private SingletonClass() {\n x = 10;\n }", "private LazySingleton() {\n if (null != INSTANCE) {\n throw new InstantiationError(\"Instance creation not allowed\");\n }\n }", "private SingletonClass() {\n objects = new ArrayList<>();\n }", "private LoggerSingleton() {\n\n }", "public static void main(String[] args) {\r\n\t\t\r\n//\t\t// **** attempt to instantiate the constructor (compiler prevents it) ****\r\n//\t\tSingleton singleton = new Singleton();\r\n\t\t\r\n\t\t// **** instantiate the singleton ****\r\n\t\tSingleton w = Singleton.getSingleInstance();\r\n\t\tSystem.out.println(\"main <<< w.str ==>\" + w.str + \"<==\");\r\n\t\t\r\n\t\t// ***** instantiate the singleton ****\r\n\t\tSingleton x = Singleton.getSingleInstance();\r\n\t\t\r\n\t\t// **** alter the string ****\r\n\t\tx.str = x.str.toUpperCase();\r\n\t\tSystem.out.println(\"main <<< x.str ==>\" + x.str + \"<==\");\r\n\t\t\r\n\t\t// **** w and x refer to the same instance ****\r\n\t\tSystem.out.println(\"main <<< w.str ==>\" + w.str + \"<==\");\r\n\t\tSystem.out.println();\r\n\t\t\r\n\t\t\r\n//\t\t// **** attempt to instantiate the constructor (compiler prevents it) ****\r\n//\t\tMySingleton mySingleton = new MySingleton();\r\n\t\t\r\n\t\t// **** instantiate the my singleton ****\r\n\t\tMySingleton y = MySingleton.MySingleton();\r\n\t\tSystem.out.println(\"main <<< y.str ==>\" + y.str + \"<==\");\r\n\t\t\r\n\t\t// **** instantiate my singleton ****\r\n\t\tMySingleton z = MySingleton.MySingleton();\r\n\t\t\r\n\t\t// **** alter the string ****\r\n\t\tz.str = z.str.toUpperCase();\r\n\t\tSystem.out.println(\"main <<< z.str ==>\" + z.str + \"<==\");\r\n\t\t\r\n\t\t// **** y and z refer to the same instance ****\r\n\t\tSystem.out.println(\"main <<< y.str ==>\" + y.str + \"<==\");\r\n\t}", "public static LazyInitializedSingleton getInstance(){ // method for create/return Object\n if(instance == null){//if instance null?\n instance = new LazyInitializedSingleton();//create new Object\n }\n return instance; // return early created object\n }", "public static synchronized Singleton getInstance(){\n if(instance == null){\n instance = new Singleton();\n }\n return instance;\n }", "private SingletonAR() {\n System.out.println(Thread.currentThread().getName()\n + \": creating SingletonAR\");\n }", "public static Singleton print(String param)\n {\n return new Singleton();\n}", "public static SingleObject getInstance(){\n return instance;\n }", "public static Singleton getInstance(){\n if(instance == null)\n {\n synchronized (Singleton.class) {\n if (instance == null) {\n instance = new Singleton();\n Log.d(\"***\", \"made new Singleton\");\n }\n }\n }\n return instance;\n }", "public static Singleton getInstance() {\n\t //Je-li promenna instance null, tak se vytvori objekt\n\t if (instance == null) {\n\t instance = new Singleton();\n\t }\n\t //Vratime jedinacka\n\t return instance;\n\t }", "public static void main(String[] args) {\n ClassicSingleton singleton = ClassicSingleton.getInstance();\n ClassicSingleton singleton1 = ClassicSingleton.getInstance();\n\n }", "public static SingleObject getInstance(){\n\t\treturn instance;\n\t}", "public static J2_Singleton getInstance() {\n\t\tif(singletonInstance == null ) {\n\t\t\tsynchronized(J2_Singleton.class) {\n\t\t\t\tif(singletonInstance == null) {\n\t\t\t\t\tsingletonInstance = new J2_Singleton();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn singletonInstance;\n\t}", "public static synchronized Singleton getInstance() {\n\t\tif(instance ==null) {\n\t\t\tinstance= new Singleton();\n\t\t\t\n\t\t}\n\t\treturn instance;\n\t}", "public static SingletonClass getInstance() {\n\t\tif(singletonObj == null){\n\t\t\tsingletonObj = new SingletonClass();\n\t\t}\n\t\treturn singletonObj;\n\t}", "public SingletonVerifier() {\n }", "public static void main(String[] args) {\n\t\tSingleton tmp = Singleton.getInstance();\n\t\ttmp.demoMethod();\n\t\t\n\t/*\tClassicSingleton tmp = ClassicSingleton.getInstance();\n\t\ttmp.getInstance();*/\n\t}", "public static MySingleTon getInstance(){\n if(myObj == null){\n myObj = new MySingleTon();\n }\n return myObj;\n }", "private SingleObject(){\n }", "public static void main(String[] args) {\n SingletonClass singletonClass = SingletonClass.getInstance();\n System.out.println(\"SingletonClass instance Created.Having value of x : \" + singletonClass.getX());\n// Setting the value of private variable of SingletonClass\n singletonClass.setX(11);\n// Getting the another instance of SingletonClass.This will return the same instance used before.\n SingletonClass singletonClass1 = SingletonClass.getInstance();\n System.out.println(\"SingletonClass instance used Having value of x : \" + singletonClass.getX());\n }", "public static SingleObject getInstance()\r\n {\r\n return instance;\r\n }", "public DPSingletonLazyLoading getInstance(){ //not synchronize whole method. Instance oluşmuş olsa bile sürekli burada bekleme olur.\r\n\t\tif (instance == null){//check\r\n\t\t\tsynchronized(DPSingletonLazyLoading.class){ //critical section code NOT SYNCRONIZED(this) !!\r\n\t\t\t\tif (instance == null){ //double check\r\n\t\t\t\t\tinstance = new DPSingletonLazyLoading();//We are creating instance lazily at the time of the first request comes.\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t\t\r\n\t\treturn instance;\r\n\t}", "public static Singleton getInstance() {\n return mSing;\n }", "public static ThreadSafeSingleton getInstanceWithDoubleCheck() {\n\t\tif (instance == null) {\n\t\t\tsynchronized (ThreadSafeSingleton.class) {\n\t\t\t\tif (instance == null) {\n\t\t\t\t\tinstance = new ThreadSafeSingleton();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn instance;\n\t}", "private SingleObject()\r\n {\r\n }", "public static void main(String[] args)\r\n\t{\n\t\tSingleton obj1 = Singleton.getInstance(); // new instance created\r\n\t\tSingleton obj2 = Singleton.getInstance(); // reference for previously created object\r\n\t\tSingleton obj3 = Singleton.getInstance(); // same\r\n\r\n\t\tobj2.str = obj2.str.toUpperCase();\r\n\t\tSystem.out.println(\"str in obj1 is \" + obj1.str); // Capitalized\r\n\t\tSystem.out.println(\"str in obj2 is \" + obj2.str); // Capitalized\r\n\t\tSystem.out.println(\"str in obj3 is \" + obj3.str); // Capitalized\r\n\r\n\t\tSystem.out.println(\"Addr of obj1 is \" + obj1); // Address\r\n\t\tSystem.out.println(\"Addr of obj2 is \" + obj2); // Address\r\n\t\tSystem.out.println(\"Addr of obj3 is \" + obj3); // Address\r\n\r\n\t\t/* Some developers prefer to print hashcode of objs to ensure that it is the same object. Actually,\r\n\t\t hashcode is not the address of object in memory and is unreliable. It is some integer value which\r\n\t\t collections like hashmap or hashtable use to hash or calc hash addr of objs while inserting them\r\n\t\t into the collection. Hashcode is same if Object's class equals() returns true. Same hashcode may be\r\n\t\t returned for unequal objects.\r\n\t\t */\r\n\r\n\t\tSystem.out.println(\"Hashcode of obj1 is \" + obj1.hashCode());\r\n\t\tSystem.out.println(\"Hashcode of obj2 is \" + obj2.hashCode());\r\n\t\tSystem.out.println(\"Hashcode of obj3 is \" + obj3.hashCode());\r\n\r\n\t}", "private SingletonLectorPropiedades() {\n\t}", "public static CarSingleton2 getInstance() {\n\t\treturn singleton_instance;\n\t}", "public static Singleton getInstance() {\n return SingletonHolder.SINGLETON_INSTANCE;\n }", "public static utilitys getInstance(){\n\r\n\t\treturn instance;\r\n\t}", "private EagerInitializedSingleton() {\n\t}", "private EagerInitializedSingleton() {\n\t}", "public static synchronized Singleton getInstanceTS() {\n\t\tif (_instance == null) {\n\t\t\t_instance = new Singleton();\n\t\t}\n\t\treturn _instance;\n\t}", "public static synchronized Singleton getInstance() {\n\t\tif (mContext == null) {\n\t\t\tthrow new IllegalArgumentException(\"Impossible to get the instance. This class must be initialized before\");\n\t\t}\n\n\t\tif (instance == null) {\n\t\t\tinstance = new Singleton();\n\t\t}\n\n\t\treturn instance;\n\t}", "public static void main(String[] args) {\n\n Singleton mySingleton = new Singleton();\n mySingleton.getInstance();\n \n }", "private SingleObject(){}", "public static MySingleton getInstance() {\r\n\t\tif(instance==null){\r\n\t\t\tinstance= new MySingleton();\r\n\t\t}\r\n\t\treturn instance;\r\n\t}", "private SingletonThreadSafeExample(){\n this.invoke++;\n }", "public static Singleton getInstance() {\n if (instance == null) {\n synchronized (Singleton.class){\n if (instance == null) {\n instance = new Singleton();\n }\n }\n }\n return instance;\n }", "public boolean isSingleton()\n\t{\n\t\treturn true;\n\t}", "public static Singleton getInstance() {\n\t\tif (_instance == null) {\n\t\t\t_instance = new Singleton();\n\t\t}\n\t\treturn _instance;\n\t}", "@Override\n public boolean isSingleton() {\n return false;\n }", "public static Singleton getInstance()\r\n\t{\r\n\t\t// check if the instance is already created or not, required only for lazy init\r\n\t\tif (instance == null)\r\n\t\t\tinstance = new Singleton();\r\n\t\treturn instance;\r\n\t}", "public static class_config getinstance(){\n\t\tif (instance==null){\n\t\t\tinstance = new class_config();\n\t\t\t\n singleton.mongo=new Mongo_DB();\n singleton.nom_bd=singleton.mongo.getNom_bd();\n singleton.nom_table=singleton.mongo.getNom_table();\n singleton.client = Mongo_DB.connect();\n if (singleton.client != null) {\n singleton.db = singleton.mongo.getDb();\n singleton.collection = singleton.mongo.getCollection();\n }\n \n\t\t\tsingleton_admin.admin= new ArrayList<admin_class>();\n\t\t\tsingleton_client.client= new ArrayList<client_class>();\n\t\t\tsingleton_reg.reg= new ArrayList<reg_user_class>();\n\t\t\t\n// A_auto_json.auto_openjson_admin();\n// C_auto_json.auto_openjson_client();\n R_auto_json.auto_openjson_reg();\n //funtions_files.auto_open();\n\t\t\tauto_config.auto_openconfig();\n //class_language.getinstance();\n\t\t\tsingleton_config.lang=new class_language();\n \n connectionDB.init_BasicDataSourceFactory();\n \n\t\t}\n\t\treturn instance;\n\t}", "public static void main(String[] args){\n\n DbSingleton instance = DbSingleton.getInstance();\n\n //DbSingleton test = new DbSingleton();\n DbSingleton instance2 = DbSingleton.getInstance();\n\n System.out.println(instance);\n System.out.println(instance2);\n\n }", "private SparkeyServiceSingleton(){}", "@SuppressWarnings(\"unchecked\")\n public static <T> Singleton<T> instance() {\n // Return the singleton instance from the SingletonHolder.\n return (Singleton<T>) SingletonHolder.INSTANCE;\n }", "public static SingletonEager get_instance(){\n }", "public static synchronized SingletonImpl getSingleton() {\n\t\t\n\t\tif(mySingleton == null){\n\t\t\tmySingleton = new SingletonImpl();\n\t\t}\n\t\treturn mySingleton;\n\t}", "public boolean isSingleton() {\n\t\treturn false;\r\n\t}", "private InstanceUtil() {\n }", "public static void main(String[] args) {\n\n System.out.println(SingletonExample.getInstance());\n System.out.println(SingletonExample.getInstance());\n }", "public static Singleton getInstance() {\n\n if (_instance == null) {\n synchronized (Singleton.class) {\n if (_instance == null)\n _instance = new Singleton();\n }\n }\n return _instance;\n }", "public static void main (String[] args) {\n\n\n Thread t1= new Thread(new Runnable() {\n @Override\n public void run() {\n System.out.println(\"Output: \"+Singleton.getInstance());\n Singleton.setObjName(\"Meow!!\");\n System.out.println(\"t1 Name: \"+Singleton.getName());\n }\n });\n\n Thread t2 = new Thread(new Runnable() {\n @Override\n public void run() {\n\n System.out.println(\"Output: \"+Singleton.getInstance());\n System.out.println(\"t2 Name: \"+Singleton.getName());\n\n }\n });\n\n Thread t3 = new Thread(new Runnable() {\n @Override\n public void run() {\n\n System.out.println(\"Output: \"+Singleton.getInstance());\n Singleton.setObjName(\"WolWol\");\n System.out.println(\"t3 Name: \"+Singleton.getName());\n\n }\n });\n\n Thread t4 = new Thread(new Runnable() {\n @Override\n public void run() {\n\n System.out.println(\"Output: \"+Singleton.getInstance());\n System.out.println(\"t4 Name: \"+Singleton.getName());\n\n }\n });\n\n// t1.start();\n// t2.start();\n// t3.start();\n// t4.start();\n\n \n }", "public static ChatSingleton getInstance( ) {\n return singleton;\n }", "public boolean isSingleton() {\n\t\treturn false;\n\t}", "public static LazySingleton getInstance()\n {\n // Check null\n if (instance == null)\n instance = new LazySingleton();\n return instance;\n\n }", "public static synchronized N_ThreadSafeSingalton getInstance() throws InterruptedException{\n\t\t\n\t\tif (uniqueInstance == null){\n\t\t\tThread.sleep(1000);// just to show multithreading issue.\n\t\t\tuniqueInstance=new N_ThreadSafeSingalton();\n\t\t}\t\t\n\t\t\n\t\treturn uniqueInstance;\n\t}", "private SingleTon() {\n\t}", "public static Singleton getInstanceDC() {\n\t\tif (_instance == null) {\n\t\t\tsynchronized (Singleton.class) {\n\t\t\t\tif (_instance == null) {\n\t\t\t\t\t_instance = new Singleton();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn _instance;\n\t}", "public static synchronized MultiThreadedSingleton getInstance() {\n\t\t//Lazy instantiation using double locking mechanism.\n\t\tif (singleton == null) {\n\t\t\tsynchronized (MultiThreadedSingleton.class) {\n\t\t\t\tif (singleton == null) {\n\t\t\t\t\tsimulateRandomActivity();\n\t\t\t\t\tsingleton = new MultiThreadedSingleton();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tlogger.info(\"created singleton: \" + singleton);\n\t\treturn singleton;\n\t}", "public static synchronized ThreadSafeSingleton getInstance() {\n\t\tif (instance == null) {\n\t\t\tinstance = new ThreadSafeSingleton();\n\t\t}\n\t\treturn instance;\n\t}", "private SingletonStatementGenerator() {\n\t}", "public static void main(String[] args) {\n\n\t\tSystem.out.println(Singleton.getInstance());\n\t\tSystem.out.println(Singleton.getInstance());\n\t\tSystem.out.println(Singleton.getInstance());\n\t\tSystem.out.println(Singleton.getInstance());\n\t\tSystem.out.println(Singleton.getInstance());\n\n\t}", "public static synchronized ThreadSafeSingleton getInstance() {\n\t\tif (null == instance) {\n\t\t\tinstance = new ThreadSafeSingleton();\n\t\t}\n\n\t\treturn instance;\n\t}", "static public Abc getObject() //Double Chcked Locking\n {\n if(obj1==null) {\n synchronized (Abc.class) {\n if (obj1 == null) {\n obj1 = new Abc();\n }\n }\n\n }\n return obj1;\n }", "public static SingletonDoubleCheck getInstance() {\n\t\tif (_instance == null) {\n\t\t\tsynchronized (SingletonDoubleCheck.class) {\n\t\t\t\tif (_instance == null) {\n\t\t\t\t\t_instance = new SingletonDoubleCheck();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn _instance;\n\t}", "public static SingletonClass getInstance() {\n if (instance == null) {\n instance = new SingletonClass();\n }\n return instance;\n }", "private static void multiThreading(){\n\t\tSystem.out.println(\"\\nCreating new two separate instances of Singleton using Multi threading\");\n\t\tExecutorService service = Executors.newFixedThreadPool(2);\n\t\tservice.submit(TestSingleton::useSingleton);\n\t\tservice.submit(TestSingleton::useSingleton);\n\t\tservice.shutdown();\n\t}", "private EagerInitializationSingleton() {\n\t}", "public static FacadeMiniBank getInstance(){\r\n\r\n\t\tif(singleton==null){\r\n\t\t\ttry {\r\n\t\t\t\t//premier essai : implementation locale\r\n\t\t\t\tsingleton=(FacadeMiniBank) Class.forName(implFacadePackage + \".\" + localeFacadeClassName).newInstance();\r\n\t\t\t} catch (Exception e) {\r\n\t\t\t\tSystem.err.println(e.getMessage() + \" not found or not created\");\r\n\t\t\t}\t\t\t\t\t\t\r\n\t\t}\r\n\t\tif(singleton==null){\r\n\t\t\t//deuxieme essai : business delegate \r\n\t\t singleton=getRemoteInstance();\r\n\t\t\t\t\t\t\t\t\r\n\t\t}\r\n\t\treturn singleton;\r\n\t}" ]
[ "0.75671196", "0.74382573", "0.7322226", "0.72984177", "0.7298084", "0.7268935", "0.72566724", "0.7240669", "0.72326374", "0.7137617", "0.7119361", "0.7117404", "0.7033886", "0.7024177", "0.6983242", "0.6786956", "0.67426693", "0.6737815", "0.6717743", "0.67039406", "0.67030805", "0.6664301", "0.6613738", "0.65693885", "0.6549063", "0.6524898", "0.6506904", "0.6503473", "0.6472681", "0.6467211", "0.64382595", "0.6411902", "0.6401886", "0.63978434", "0.6380915", "0.6371675", "0.6368586", "0.6325927", "0.6302207", "0.6288554", "0.62850666", "0.62818414", "0.6266368", "0.6261126", "0.6254631", "0.6220901", "0.6217398", "0.6200986", "0.61549973", "0.61438924", "0.6116812", "0.6102879", "0.60930574", "0.60768783", "0.60744923", "0.6069889", "0.6063638", "0.60588396", "0.60533124", "0.60473555", "0.60473555", "0.6046825", "0.6041881", "0.60296005", "0.6026709", "0.60224336", "0.60104007", "0.5979281", "0.59747285", "0.59453255", "0.5932985", "0.5921906", "0.5916458", "0.5911452", "0.58973885", "0.58489376", "0.58368385", "0.58355033", "0.5829719", "0.5819424", "0.5818143", "0.5814761", "0.58117336", "0.5797579", "0.578949", "0.57770467", "0.5742528", "0.57346857", "0.5733554", "0.5733535", "0.5730572", "0.5721535", "0.57034737", "0.56960547", "0.56955045", "0.5678197", "0.56765854", "0.5668205", "0.5667508", "0.5667186" ]
0.6518402
26
Sets the value for this key to that which is less than all possible values for the key domain.
void setMinValue();
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void lowerKey(){\n\t\tkey = clamp(key-INCREMENT, MINKEY, MAXKEY);\n\t}", "@Override\n\tprotected void setLowerBound() {\n\t\t\n\t}", "public void setLower(int value) {\n this.lower = value;\n }", "public void raiseKey(){\n\t\tkey = clamp(key+INCREMENT, MINKEY, MAXKEY);\n\t}", "public Query lessThan(String key, Object value) {\n Preconditions.checkNotNull(key);\n builder.addFilter(builder.getOperator(QueryFilterBuilder.Operators.LESSTHAN), key, value);\n return this;\n }", "public void setLowerBound (int lowerBound) throws ModelException;", "public void setMinValue(int x) {\r\n\t\tminValue = x;\r\n\t}", "public void SetMinVal(int min_val);", "public Query lessThanEqualTo(String key, Object value) {\n Preconditions.checkNotNull(key);\n builder.addFilter(builder.getOperator(QueryFilterBuilder.Operators.LESSTHANEQUAL), key, value);\n return this;\n }", "public void set_min(byte value) {\n setSIntBEElement(offsetBits_min(), 8, value);\n }", "public void setLowerBound (int lowerBound) throws ModelException\n\t{\n\t\tif ((lowerBound > getUpperBound()) || (lowerBound < 0))\n\t\t{\n\t\t\tthrow new ModelException(I18NHelper.getMessage(getMessages(),\n\t\t\t\t\"jdo.relationship.lower_cardinality_invalid\"));\t\t// NOI18N\n\t\t}\n\n\t\tgetRelationshipImpl().setLowerBound(lowerBound);\n\t}", "protected void mapValueToWithinBounds() {\n if (getAllele() != null) {\n \tFloat d_value = ( (Float) getAllele());\n if (d_value.isInfinite()) {\n // Here we have to break to avoid a stack overflow.\n // ------------------------------------------------\n return;\n }\n // If the value exceeds either the upper or lower bounds, then\n // map the value to within the legal range. To do this, we basically\n // calculate the distance between the value and the float min,\n // then multiply it with a random number and then care that the lower\n // boundary is added.\n // ------------------------------------------------------------------\n if (d_value.floatValue() > m_upperBound ||\n d_value.floatValue() < m_lowerBound) {\n RandomGenerator rn;\n if (getConfiguration() != null) {\n rn = getConfiguration().getRandomGenerator();\n }\n else {\n rn = new StockRandomGenerator();\n }\n setAllele(new Float((rn.nextFloat()\n * ((m_upperBound - m_lowerBound))) + m_lowerBound));\n }\n }\n }", "public void setLowerBound(final int lowerBound) {\r\n this.lowerBound = lowerBound;\r\n }", "@Override\n public void setSoftLowerLimit(double position)\n {\n final String funcName = \"setSoftLowerLimit\";\n\n if (debugEnabled)\n {\n dbgTrace.traceEnter(funcName, TrcDbgTrace.TraceLevel.API, \"position=%f\", position);\n dbgTrace.traceExit(funcName, TrcDbgTrace.TraceLevel.API);\n }\n\n softLowerLimit = position;\n }", "public Key min();", "public void setMinValue(int minValue) {\n this.minValue = minValue;\n }", "public void setMinValue(double x) {\r\n\t\tminValue = x;\r\n\t}", "private void setMinThreshold() {\n minThreshold = value + value * postBoundChange / 100;\n }", "void setMaxValue();", "public SettingInteger setValidRange(int min, int max) { _minValue = min; _maxValue = max; return this; }", "public void setLowerBound(String lower) {\n lowerBound = lower;\n }", "public int clamp(String value){\n return (value.hashCode() & capacityMinusOne());\n }", "@Override\n public void adjustFilter(int key_min, int key_max) {\n //do nothing\n }", "default DiscreteSet2D superLevelSet(double value) {\r\n\t\treturn pointsSatisfying(d -> d >= value);\r\n\t}", "private void setTrappedPeople(long trappedPeople) throws NumberOutOfBoundsException {\n if (!isValidTrappedPeople(trappedPeople)) {\n throw new NumberOutOfBoundsException(String.format(\"Number of trapped people must be larger or equal to zero and not \\\"%s\\\"\", trappedPeople));\n }\n this.trappedPeople = trappedPeople;\n }", "public synchronized int getLowerSizeLimit() {\n \t\treturn lower;\n \t}", "public void changeConstraintsToLessThan() throws IloException {\n /*\n IloRange notes:\n for expr == rhs, set lb = ub = rhs\n for expr <= rhs, set lb = -infinity and ub = rhs\n for expr >= rhs, set lb = rhs and ub = infinity\n */\n for (int i = 0; i < matrix.getNrows(); i++) {\n IloRange rangedExpression = matrix.getRange(i);\n if (rangedExpression.getUB() >= Double.POSITIVE_INFINITY) {\n rangedExpression.setBounds(Double.NEGATIVE_INFINITY, -rangedExpression.getUB());\n for (int j = 0; j < matrix.getNrows(); j++) {\n matrix.setNZ(i, j, -matrix.getNZ(i, j));\n }\n }\n }\n }", "public SigningMethodBuilder minKeySize(Integer keySize) {\n this.object().setMinKeySize(keySize);\n return this;\n }", "public boolean minSize(){\n\t\tboolean result; \n\t\tif(keys.size() < (MAXKEYS/2) -1){\n\t\t\tresult = true;\n\t\t}\n\t\telse{ \n\t\t\tresult = false;\n\t\t}\n\t\treturn result;\n\t}", "public void setLowKey(KeyClass low_key) throws ChainException, IOException {\n\t\tthis.lowKey = low_key;\r\n\t\tRID rid = new RID();\r\n\t\t\r\n\t\tKeyDataEntry dEntry = leaf.getFirst(rid);\r\n\t\tKeyClass curKey = dEntry.key;\r\n\t\t\r\n\t\twhile( BT.keyCompare(curKey, low_key) != 0 ){\r\n\t\t\tdEntry = leaf.getNext(rid);\r\n\t\t\tif( dEntry != null ){\r\n\t\t\t\tcurKey = dEntry.key;\r\n\t\t\t}else{\r\n\t\t\t\tPageId nextPageId = leaf.getNextPage();\r\n\t\t\t\tif( nextPageId.pid != -1){\r\n\t\t\t\t\tSystemDefs.JavabaseBM.unpinPage(leaf.getCurPage(), true);\r\n\t\t\t\t\tSystemDefs.JavabaseBM.pinPage( nextPageId, leaf, false);\r\n\t\t\t\t\tleaf.dumpPage();\r\n\t\t\t\t\tdEntry = leaf.getFirst(rid);\r\n\t\t\t\t\tcurKey = dEntry.key;\r\n\t\t\t\t}else{\r\n\t\t\t\t\t//wasal le 2a5er 7aga:\r\n\t\t\t\t\tSystem.out.println(\"Invalid lower keyyyyyyy.\");\r\n\t\t\t\t\tbreak;\r\n\t\t\t\t}//end else.\r\n\t\t\t\t\r\n\t\t\t}//end else.\r\n\t\t\t\r\n\t\t}//end while.\r\n\t\t\r\n\t\t\r\n\t}", "private long minKey() {\n if (left.size == 0) return key;\n // make key 'absolute' (i.e. relative to the parent of this):\n return left.minKey() + this.key;\n }", "private static <Key extends Comparable<Key>> boolean less(Key v, Key w) \n\t{\n\t\treturn (v.compareTo (w) < 0);\n\t}", "public void setKey(int nKey){\n\t\tkey = clamp(nKey, MINKEY, MAXKEY);\n\t}", "public RowKeyRange fill(int keyLength) {\n byte[] lowerRange = this.getLowerRange();\n byte[] newLowerRange = lowerRange;\n if (!this.lowerUnbound()) {\n // If lower range is inclusive, fill with 0x00 since conceptually these bytes are included in the range\n newLowerRange = fillKey(lowerRange, keyLength);\n }\n byte[] upperRange = this.getUpperRange();\n byte[] newUpperRange = upperRange;\n if (!this.upperUnbound()) {\n // If upper range is inclusive, fill with 0xFF since conceptually these bytes are included in the range\n newUpperRange = fillKey(upperRange, keyLength);\n }\n if (newLowerRange != lowerRange || newUpperRange != upperRange) {\n return RowKeyRange.getKeyRange(newLowerRange, this.isLowerInclusive(), newUpperRange, this.isUpperInclusive());\n }\n return this;\n }", "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\r\n public Integer minLowerBound() {\r\n return this.getImpl().minLowerBound();\r\n }", "public int getLowerBound() {\r\n return lowerBound;\r\n }", "public void insertKey(int key) {\n\t\t\tif (heap_size == capacity) {\n\t\t\t\tSystem.out.println(\"Overflow : couldn't insert key!\");\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\t// First insert the new key at the end\n\t\t\theap_size++;\n\t\t\tint i = heap_size - 1;\n\t\t\tharr[i] = key;\n\n\t\t\t// Fix the min heap property if it is violated\n\t\t\twhile (i != 0 && harr[parent(i)] > harr[i]) {\n\t\t\t\tswap(i, parent(i));\n\t\t\t\ti = parent(i);\n\t\t\t}\n\t\t}", "private int hashValue(K key) {\r\n\t\treturn (Math.abs(key.hashCode()) % currentCapacity);\r\n\t}", "public void setMin(int min) {\n this.min = min;\n }", "public void setMin(int min) {\n this.min = min;\n }", "void setNilMultipleBetMinimum();", "public abstract int getMinimumValue();", "public void setCurrentLengthOverMin(double newLengthOverMinInMeters) {\n if (newLengthOverMinInMeters >= 0 && newLengthOverMinInMeters <= maxLengthOverMin)\n this.currentLengthOverMin = newLengthOverMinInMeters;\n else if (newLengthOverMinInMeters < 0)\n this.currentLengthOverMin = 0;\n else\n this.currentLengthOverMin = maxLengthOverMin;\n }", "public void setMinValue (String minValue) {\n this.minValue = minValue;\n }", "public int getLowerThreshold() {\n return lowerThreshold;\n }", "public String getLowerLimit() {\n return lowerLimit;\n }", "IntTree<V> changeKeysAbove(final long key, final int delta) {\n if (size == 0 || delta == 0) return this;\n\n if (this.key >= key)\n // adding delta to this.key changes the keys of _all_ children of this,\n // so we now need to un-change the children of this smaller than key,\n // all of which are to the left. note that we still use the 'old' relative key...:\n return new IntTree<V>(\n this.key + delta, value, left.changeKeysBelow(key - this.key, -delta), right);\n\n // otherwise, doesn't apply yet, look to the right:\n IntTree<V> newRight = right.changeKeysAbove(key - this.key, delta);\n if (newRight == right) return this;\n return new IntTree<V>(this.key, value, left, newRight);\n }", "private void setValidFrom(String key) {\n redisTemplate.<String, String>boundHashOps(key).put(VALID_FROM, String.valueOf(System.currentTimeMillis()));\n }", "public void insertKey(int k)\n\t{\n\t if (size == maxsize)\n\t {\n\t System.out.println(\"Overflow: Could not insertKey\");\n\t return;\n\t }\n\t \n\t // First insert the new key at the end\n\t size++;\n\t int i = size - 1;\n\t Heap[i] = k;\n\t \n\t // Fix the min heap property if it is violated\n\t while (i != 0 && Heap[parent(i)] < Heap[i])\n\t {\n\t swap(i, parent(i));\n\t i = parent(i);\n\t }\n\t}", "public void changeConstraintsToMoreThan() throws IloException {\n /*\n IloRange notes:\n for expr == rhs, set lb = ub = rhs\n for expr <= rhs, set lb = -infinity and ub = rhs\n for expr >= rhs, set lb = rhs and ub = infinity\n */\n for (int i = 0; i < matrix.getNrows(); i++) {\n IloRange rangedExpression = matrix.getRange(i);\n if (rangedExpression.getLB() <= Double.NEGATIVE_INFINITY) {\n rangedExpression.setBounds(-rangedExpression.getLB(), Double.POSITIVE_INFINITY);\n for (int j = 0; j < matrix.getNrows(); j++) {\n matrix.setNZ(i, j, -matrix.getNZ(i, j));\n }\n }\n }\n }", "public void setMax(){\n for (int i = 0; i < Nodes.size(); i++){\n this.MinDistance.add(Double.MAX_VALUE);\n }\n }", "@Override\n public int compareTo(Priority other) {\n return Integer.compare(this.value, other.value) * -1;\n }", "public void setValue(int n) {\r\n Throwable t = new Throwable();\r\n t.printStackTrace();\r\n int newValue = Math.max(n, min);\r\n if (newValue + getExtent() > max) {\r\n newValue = max - getExtent();\r\n }\r\n\r\n setRangeProperties(newValue, getExtent(), min, max, isAdjusting);\r\n }", "public void removeSmaller(double value){\r\n\t DoubleNode cursor2; \r\n\tfor(cursor = head; cursor != null; cursor = cursor.getLink()){\r\n\t\tif(cursor.getData() < value){\r\n\t\t\tif(cursor == head){\r\n\t\t\t\thead = head.getLink(); \r\n\t\t\t\tmanyNodes--; \r\n\t\t\t}\r\n\t\t\telse{\r\n\t\t\t\tcursor2 = cursor; \r\n\t\t\t\tthis.removeCurrent();\r\n\t\t\t\tcursor = cursor2;\r\n\t\t\t\tmanyNodes--; \r\n\t\t\t}\r\n\t\t}\r\n\t}\r\n }", "public Comparable<?> a(DiscreteDomain<Comparable<?>> discreteDomain) {\n return discreteDomain.minValue();\n }", "void setNilSingleBetMinimum();", "private void setEmbeddingTokenLow(long value) {\n bitField0_ |= 0x00000001;\n embeddingTokenLow_ = value;\n }", "public SamFilterParamsBuilder minLength(int value) {\n mMinReadLength = value;\n return this;\n }", "ChangeObserver<T> setInitialMaxValue(Object value);", "@Override\n public UInt256 getPriorStorageValue(final Address address, final UInt256 key) {\n return getStorageValue(address, key);\n }", "public void setExhaustion ( float value ) {\n\t\texecute ( handle -> handle.setExhaustion ( value ) );\n\t}", "public void setMinimum(int n) {\r\n int newMax = Math.max(n, max);\r\n int newValue = Math.max(n, getValue());\r\n int newExtent = Math.min(newMax - newValue, getExtent());\r\n setRangeProperties(newValue, newExtent, n, newMax, isAdjusting);\r\n }", "public Long getMinValue() {\n return minValue;\n }", "public void setLow(int L)\t\n\t{\t//start of setLow method\n\t\tLOW_NUM = L;\n\t}", "private void setDefaultValidRange ()\r\n\t{\r\n\t\tm_lowerBounds = Integer.MIN_VALUE;\r\n\t\tm_upperBounds = Integer.MAX_VALUE;\r\n\t}", "public void setLow(double value) {\n this.low = value;\n }", "public void setMinimum( final int value ) {\n checkWidget();\n if( 0 <= value && value < maximum ) {\n minimum = value;\n if( selection < minimum ) {\n selection = minimum;\n }\n }\n if( thumb >= maximum - minimum ) {\n thumb = maximum - minimum;\n selection = minimum;\n }\n }", "private void setEmbeddingTokenLow(long value) {\n bitField0_ |= 0x00000002;\n embeddingTokenLow_ = value;\n }", "public int getMinValue() {\n return minValue;\n }", "public void setMaxValue(int x) {\r\n\t\tmaxValue = x;\r\n\t}", "public void setLessThanTimes(Integer lessThanTimes) {\n this.lessThanTimes = lessThanTimes;\n }", "@BeforeAll\n public void before() {\n Accumulator<Index> acc = create();\n var it = values().iterator();\n while (it.hasNext()) {\n long value = it.nextLong();\n min = Math.min(min, value);\n max = Math.max(max, value);\n ++count;\n acc.add(value);\n }\n this.index = acc.seal();\n }", "@Override\n\t@TimeComplexity(\"O(log n)\")\n\tpublic Entry<K, V> lowerEntry(K key) {\n\t/* TCJ\n\t * Binary search operation: log n\n\t */\n\t\treturn safeEntry(findIndex(key) - 1);\n\t}", "public void setMinimumValue (double min) {\r\n\t\tminValue = new Double(min);\r\n\t\tvalidateMin = (minValue.compareTo(DOUBLE_ZERO) != 1);\r\n\t}", "public int nextLessThan(int range) {\n return (0x7fffffff & this.nextInt()) % range;\n }", "void checkRange(Long value) throws TdtTranslationException {\r\n\t\tif (hasRange) {\r\n\t\t\tif ((value.compareTo(minimum) < 0)\r\n\t\t\t\t\t|| (value.compareTo(maximum) > 0)) {\r\n\t\t\t\tthrow new TdtTranslationException(\"Value {\" + value\r\n\t\t\t\t\t\t+ \"} out of range [{\" + minimum + \"},{\" + maximum\r\n\t\t\t\t\t\t+ \"}] in field \" + getId());\r\n\t\t\t}\r\n\t\t}\r\n\t}", "@Override\n protected int getMinEntries(final PropertyContext context) {\n return 2;\n }", "@Override\n\tpublic int compareTo(Key o) {\n\t\tint temp = 0;\n\t\t\t\t\n\t\tif (this.value > o.value) \t\ttemp = 1;\n\t\telse if (this.value < o.value) temp = -1;\n\t\telse \t\t\t\t\t\t\ttemp = 0;\n\t\t\n\t\treturn temp;\n\t}", "@Override\n\tprotected double getLowerBound() {\n\t\treturn 0;\n\t}", "public void inc(String key) { \n \t//a 1 b 1 a 2\n // get key and update\n int val=\tmap.getOrDefault(key, 0)+1;\n if(val>max) {\n \t max=val;\n \t maxkey=key;\n }\n if(val==1||val<min) {\n \t min=val;\n \t minkey=key;\n }\n \t map.put(key,val); \t\n }", "private static int minKey(int[] key, Boolean[] mstSet, int V)\r\n {\r\n // Initialize min value\r\n int min = Integer.MAX_VALUE, min_index=-1;\r\n\r\n for (int v = 0; v < V; v++)\r\n if (!mstSet[v] && key[v] < min)\r\n {\r\n min = key[v];\r\n min_index = v;\r\n }\r\n\r\n return min_index;\r\n }", "public Cut<Comparable<?>> c(DiscreteDomain<Comparable<?>> discreteDomain) {\n try {\n return Cut.b(discreteDomain.minValue());\n } catch (NoSuchElementException unused) {\n return this;\n }\n }", "public void inc(String key) {\n map.put(key, map.getOrDefault(key, 0) + 1);\n int val = map.get(key);\n vals.putIfAbsent(val, new HashSet<>());\n vals.get(val).add(key);\n if (vals.containsKey(val - 1)) {\n vals.get(val - 1).remove(key);\n if (vals.get(val - 1).size() == 0)\n vals.remove(val - 1);\n }\n if (map.get(key) > max) {\n max = map.get(key);\n maxKey = key;\n }\n if (map.get(key) - 1 == min) {\n if (vals.get(min) == null || vals.get(min).size() == 0) {\n min++;\n minKey = key;\n } else {\n minKey = vals.get(min).iterator().next();\n }\n }\n if (map.get(key) == 1) {\n min = 1;\n minKey = key;\n }\n }", "private double getMin() {\n return Collections.min(values.values());\n }", "public abstract Key getSmallest();", "protected final void setMin() {\n\tint prevmin = this.min;\n\n\tint i1 = this.low;\n\tint i2 = left.min;\n\tint i3 = right.min;\n\n\tif (i2 == -1) \n\t i2 = i1;\n\tif (i3 == -1) \n\t i3 = i1;\n\n\tif ((i1 <= i2) && (i1 <= i3)) {\n\t this.min = i1;\n\t} else if ((i2 <= i1) && (i2 <= i3)) {\n\t this.min = i2;\n\t} else {\n\t this.min = i3;\n\t}\n\n\tif ((p != IntervalNode.nullIntervalNode) &&\n\t (prevmin != this.min)) {\n \t p.setMin();\n\t}\n }", "private void setProcessorConstraints(ProcessorDistributionKey key)\n {\n myProcessorBuilder\n .setPositiveConstraints(new Constraints(new StrictTimeConstraint(key.getConstraintKey(), key.getTimeSpan())));\n myProcessorBuilder.setNegativeConstraints(\n new Constraints(TimeConstraint.getNegativeTimeConstraint(key.getConstraintKey(), key.getTimeSpan())));\n }", "public void clamp() //TODO: implement\n {\n System.out.println(\"clamp was called!\"); //DEBUGG: check if called, delete if i know when\n /*\n IntegerVectorSpecies _species = (IntegerVectorSpecies)species;\n for (int i = 0; i < genomeLength(); i++)\n {\n int minGene = (int)_species.minGene(i);\n if (genome[i].getValue() < minGene)\n genome[i].setValue(minGene); //what do do for the TraceID?\n else\n {\n int maxGene = (int)_species.maxGene(i);\n if (genome[i].getValue() > maxGene)\n genome[i] = maxGene;\n }\n }\n\n */\n }", "public void setLowerThreshold(int lowerThreshold) {\n this.lowerThreshold = lowerThreshold;\n }", "public void setLowerThreshold(int setLowerThreshold) {\r\n\t\tthis.lowerThreshold = setLowerThreshold;\t\t\r\n\t}", "public void setMinEdad(int min);", "@Test\n\tpublic void testLPushLimit() {\n\t\tJedisUtils.del(\"k1\");\n\t\tJedisUtils.HASH.hget(\"k1\", \"k1\");\n\t\tJedisUtils.LIST.lpushLimit(\"gen_rule_file_tasks-ssy1\", 1, \"新增了开启状态规则文件\");\n\t\tJedisUtils.LIST.lpushLimit(\"gen_rule_file_tasks-ssy1\", 1, \"新增了开启状态规则文件\");\n\t}", "E minVal();", "public boolean valueLargerThan(Money other);", "private void buildBoundary(Set<String> dict) {\n for (String s : dict) {\n int len = s.length();\n min = Math.min(min, len);\n max = Math.max(max, len);\n }\n }", "public void setMinimumValue(double minimumValue)\n {\n this.minimumValue = minimumValue;\n }", "public abstract Key getLargest();", "@Override\n\tpublic void setValue(int value) {\n\t\tif (!(value >= 0 && value <= this.maxValue)) {\n\t\t\tthrow new IllegalArgumentException(\n\t\t\t\t\t\"DawsonBallotItem Error - value must be >= 0 and <= to maxValue.\" + \" Invalid value = \" + value);\n\t\t}\n\t\tthis.value = value;\n\n\t}", "public void setLenghtPop (int value) {\r\n long_poblacion = value; }" ]
[ "0.6249063", "0.5717499", "0.55941963", "0.55887085", "0.552789", "0.5508811", "0.5435953", "0.54165095", "0.52463466", "0.52426964", "0.5217832", "0.5217602", "0.5210336", "0.5151636", "0.51360023", "0.51238924", "0.5091101", "0.50587493", "0.5055922", "0.50263906", "0.498897", "0.4977405", "0.49598497", "0.49580953", "0.48695284", "0.4860981", "0.48498073", "0.48330185", "0.4826284", "0.48179314", "0.4809302", "0.4801471", "0.4793301", "0.47931036", "0.47927612", "0.47926483", "0.47894213", "0.47863716", "0.4785304", "0.47632197", "0.47632197", "0.47620502", "0.47575465", "0.47571594", "0.47512677", "0.47493058", "0.47441822", "0.47318605", "0.47257206", "0.47099206", "0.470538", "0.46834412", "0.46816212", "0.46799436", "0.46663728", "0.46522087", "0.46504375", "0.46469593", "0.46397892", "0.4639488", "0.46365267", "0.46356353", "0.4615058", "0.46119297", "0.46111536", "0.46027774", "0.45975202", "0.45952585", "0.45920476", "0.4591339", "0.45909402", "0.45886979", "0.4586507", "0.45802036", "0.45712402", "0.4570398", "0.4570383", "0.45613417", "0.45597333", "0.45531654", "0.45522612", "0.4549217", "0.45425043", "0.4540937", "0.45379236", "0.45347276", "0.45342156", "0.4532948", "0.45285943", "0.45262992", "0.45202023", "0.45096567", "0.4507373", "0.45056745", "0.45056638", "0.4499602", "0.44965515", "0.4495385", "0.44818228", "0.44807833" ]
0.544525
6
Sets the value for this key to that which is greater than all possible values for the key domain.
void setMaxValue();
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void setMaxValue(int x) {\r\n\t\tmaxValue = x;\r\n\t}", "protected void mapValueToWithinBounds() {\n if (getAllele() != null) {\n \tFloat d_value = ( (Float) getAllele());\n if (d_value.isInfinite()) {\n // Here we have to break to avoid a stack overflow.\n // ------------------------------------------------\n return;\n }\n // If the value exceeds either the upper or lower bounds, then\n // map the value to within the legal range. To do this, we basically\n // calculate the distance between the value and the float min,\n // then multiply it with a random number and then care that the lower\n // boundary is added.\n // ------------------------------------------------------------------\n if (d_value.floatValue() > m_upperBound ||\n d_value.floatValue() < m_lowerBound) {\n RandomGenerator rn;\n if (getConfiguration() != null) {\n rn = getConfiguration().getRandomGenerator();\n }\n else {\n rn = new StockRandomGenerator();\n }\n setAllele(new Float((rn.nextFloat()\n * ((m_upperBound - m_lowerBound))) + m_lowerBound));\n }\n }\n }", "public Query greaterThan(String key, Object value) {\n Preconditions.checkNotNull(key);\n builder.addFilter(builder.getOperator(QueryFilterBuilder.Operators.GREATERTHAN), key, value);\n return this;\n }", "private void setMaxThreshold() {\n maxThreshold = value - value * postBoundChange / 100;\n }", "public Query greaterThanEqualTo(String key, Object value) {\n Preconditions.checkNotNull(key);\n builder.addFilter(builder.getOperator(QueryFilterBuilder.Operators.GREATERTHANEQUAL), key, value);\n return this;\n }", "public void setMaxValue(double x) {\r\n\t\tmaxValue = x;\r\n\t}", "public void raiseKey(){\n\t\tkey = clamp(key+INCREMENT, MINKEY, MAXKEY);\n\t}", "@Override\n\tprotected void setUpperBound() {\n\t\t\n\t}", "public void changeConstraintsToMoreThan() throws IloException {\n /*\n IloRange notes:\n for expr == rhs, set lb = ub = rhs\n for expr <= rhs, set lb = -infinity and ub = rhs\n for expr >= rhs, set lb = rhs and ub = infinity\n */\n for (int i = 0; i < matrix.getNrows(); i++) {\n IloRange rangedExpression = matrix.getRange(i);\n if (rangedExpression.getLB() <= Double.NEGATIVE_INFINITY) {\n rangedExpression.setBounds(-rangedExpression.getLB(), Double.POSITIVE_INFINITY);\n for (int j = 0; j < matrix.getNrows(); j++) {\n matrix.setNZ(i, j, -matrix.getNZ(i, j));\n }\n }\n }\n }", "public Comparable<?> b(DiscreteDomain<Comparable<?>> discreteDomain) {\n return discreteDomain.maxValue();\n }", "public boolean valueLargerThan(Money other);", "public void setMaxValue(int maxValue) {\n this.maxValue = maxValue;\n }", "ChangeObserver<T> setInitialMaxValue(Object value);", "public void lowerKey(){\n\t\tkey = clamp(key-INCREMENT, MINKEY, MAXKEY);\n\t}", "@Override\n\tprotected void setLowerBound() {\n\t\t\n\t}", "default DiscreteSet2D superLevelSet(double value) {\r\n\t\treturn pointsSatisfying(d -> d >= value);\r\n\t}", "public void SetMaxVal(int max_val);", "@Override\n public void adjustFilter(int key_min, int key_max) {\n //do nothing\n }", "@Override\n\tpublic void decreaseKey(int value, double newPriority) {\n\n\t}", "public SettingInteger setValidRange(int min, int max) { _minValue = min; _maxValue = max; return this; }", "public void set_max(byte value) {\n setSIntBEElement(offsetBits_max(), 8, value);\n }", "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 public void postGlobal() {\n for(int i=1;i<_chkMaxs.length;++i)\n _chkMaxs[i] = _chkMaxs[i-1] > _chkMaxs[i] ? _chkMaxs[i-1] : _chkMaxs[i];\n }", "public abstract Key getLargest();", "public Value<?> gt(Value<?> v) {\r\n Integer cmp = compare(v);\r\n if (cmp == null)\r\n throw unsupported(\">\", v);\r\n return new ValueBoolean(cmp > 0);\r\n }", "public int clamp(String value){\n return (value.hashCode() & capacityMinusOne());\n }", "private void tooHigh() {\n if (this.hitPoints > 255) {\n System.out.println(\"You set the value too high! Setting it to 255\");\n this.hitPoints = 255;\n }\n }", "protected final void setMax() {\n\n\tint prevmax = this.max;\n\n\tint i1 = this.high;\n\tint i2 = left.max;\n\tint i3 = right.max;\n\n\tif ((i1 >= i2) && (i1 >= i3)) {\n\t this.max = i1;\n\t} else if ((i2 >= i1) && (i2 >= i3)) {\n\t this.max = i2;\n\t} else {\n\t this.max = i3;\n\t}\n\t\n\tif ((p != IntervalNode.nullIntervalNode) &&\n\t (prevmax != this.max)) {\n \t p.setMax();\n\t}\n }", "@Override\n public int compareTo(Priority other) {\n return Integer.compare(this.value, other.value) * -1;\n }", "public boolean setPropertyBalanceMax(long aValue);", "public boolean setMax(int barID, double value) {\r\n\t\t// If the index is valid;\r\n\t\tif (barID >= 0 && barID < barCount) {\r\n\t\t\t// Update the maximum capacity to the magnitude of the given value.\r\n\t\t\tmaxValue[barID] = Math.abs(value);\r\n\t\t\treturn true;\r\n\t\t}\r\n\t\treturn false;\r\n\t}", "public void setExhaustion ( float value ) {\n\t\texecute ( handle -> handle.setExhaustion ( value ) );\n\t}", "void setMinValue();", "@Override\n public void setSoftUpperLimit(double position)\n {\n final String funcName = \"setSoftUpperLimit\";\n\n if (debugEnabled)\n {\n dbgTrace.traceEnter(funcName, TrcDbgTrace.TraceLevel.API, \"position=%f\", position);\n dbgTrace.traceExit(funcName, TrcDbgTrace.TraceLevel.API);\n }\n\n softUpperLimit = position;\n }", "@Override\n\tpublic void setValue(int value) {\n\t\tif (!(value >= 0 && value <= this.maxValue)) {\n\t\t\tthrow new IllegalArgumentException(\n\t\t\t\t\t\"DawsonBallotItem Error - value must be >= 0 and <= to maxValue.\" + \" Invalid value = \" + value);\n\t\t}\n\t\tthis.value = value;\n\n\t}", "public Value<?> gte(Value<?> v) {\r\n Integer cmp = compare(v);\r\n if (cmp == null)\r\n throw unsupported(\">=\", v);\r\n return new ValueBoolean(cmp >= 0);\r\n }", "public void setLowerBound (int lowerBound) throws ModelException;", "public int searchStrictlyGreater(T key) {\n if ((array.length == 1) ||\n (array[0].compareTo(key) == -1) ||\n (array[array.length - 1].compareTo(key) == 1)) {\n return 0;\n }\n\n int start = 0, end = array.length - 2;\n\n do {\n int mid = start + (end - start)/2;\n if (array[mid].compareTo(key) <= 0) {\n if (array[mid + 1].compareTo(key) > 0) {\n return mid + 1;\n }\n else {\n start = mid + 1;\n }\n }\n else {\n end = mid - 1;\n }\n }\n while (start <= end);\n\n return 0;\n }", "public boolean overMax() {\n if (this.levelMessage.getDoubleParameter() > this.configuration.getMaximalLimitLevel()) {\n return true;\n }\n return false;\n }", "public void setMaxValue (String maxValue) {\n this.maxValue = maxValue;\n }", "public void setLenghtPop (int value) {\r\n long_poblacion = value; }", "public void setUpperValue(int value) {\n // Compute new extent.\n int lowerValue = getValue();\n int newExtent = Math.min(Math.max(0, value - lowerValue), getMaximum() - lowerValue);\n \n // Set extent to set upper value.\n setExtent(newExtent);\n }", "public void dec(String key) {\n \t int val=\tmap.getOrDefault(key, 0)-1;\n \t if(val==0)map.remove(key);\n if(val==max||val>max) {\n \t maxkey=key;\n }\n if(val<min) {\n \t min=val;\n \t minkey=key;\n }\n \t map.put(key,val);\n }", "public void update_domain(int value, int lowerBound, int upperBound) {\n domain_history.push(domain.copy());\n domain.getDomain().remove((Integer) value);\n domain.getDomain().removeIf(d -> d > upperBound || d < lowerBound);\n }", "public boolean setVal(Integer newVal)\n {\n Integer currentVal = this.getVal();\n if (currentVal == null) {\n this.value = newVal;\n return true;\n } else {\n if (this.getTipo() == TipoNodo.MAX) {\n if (newVal > currentVal) {\n this.value = newVal;\n return true;\n } else {\n return false;\n }\n } else {\n if (newVal < currentVal) {\n this.value = newVal;\n return true;\n } else {\n return false;\n }\n }\n }\n }", "public QueryElement addGreaterEqualsThen(String property, Object value);", "void checkRange(Long value) throws TdtTranslationException {\r\n\t\tif (hasRange) {\r\n\t\t\tif ((value.compareTo(minimum) < 0)\r\n\t\t\t\t\t|| (value.compareTo(maximum) > 0)) {\r\n\t\t\t\tthrow new TdtTranslationException(\"Value {\" + value\r\n\t\t\t\t\t\t+ \"} out of range [{\" + minimum + \"},{\" + maximum\r\n\t\t\t\t\t\t+ \"}] in field \" + getId());\r\n\t\t\t}\r\n\t\t}\r\n\t}", "public CategoryBuilder setUpperBound(float upperBound)\n {\n fUpperBound = upperBound;\n return this;\n }", "public void setMaxEvictionQueueEntries(int val) {\n this.mMaxEvictionQueueEntries = val;\n }", "private void checkBound(int lowerBound, int upperBound) {\n\t\tSet setKeys = Utility.vocabHM.keySet();\n\t\tIterator i = setKeys.iterator();\n\n\t\twhile (i.hasNext()) {\n\t\t\tString s = (String) i.next();\n\t\t\tInteger df = (Integer) Utility.vocabHM.get(s);\n\n\t\t\tif ((df.intValue() <= lowerBound) || (df.intValue() >= upperBound))\n\t\t\t\ti.remove();\n\t\t}\n\t}", "public void setUpperBound(final int upperBound) {\r\n this.upperBound = upperBound;\r\n }", "public void SetMinVal(int min_val);", "public void setValue(int n) {\r\n Throwable t = new Throwable();\r\n t.printStackTrace();\r\n int newValue = Math.max(n, min);\r\n if (newValue + getExtent() > max) {\r\n newValue = max - getExtent();\r\n }\r\n\r\n setRangeProperties(newValue, getExtent(), min, max, isAdjusting);\r\n }", "protected final void setMax(Comparable max)\r\n {\r\n myMax = max;\r\n }", "public final void setUnbounded() {_occ.setUnbounded();}", "@Override\n public void reduce(Text key, Iterable<LongWritable> values,\n Context context\n ) throws IOException, InterruptedException { \n \n for (LongWritable val : values) { \n if( max.compareTo(val) < 0) {\n max.set(new Long(val.toString()));\n } \n }\n context.write(key, max);\n }", "private int hashValue(K key) {\r\n\t\treturn (Math.abs(key.hashCode()) % currentCapacity);\r\n\t}", "@Override\r\n\tpublic String getReferenceKey() {\n\t\treturn \"max\";\r\n\t}", "public void clamp() //TODO: implement\n {\n System.out.println(\"clamp was called!\"); //DEBUGG: check if called, delete if i know when\n /*\n IntegerVectorSpecies _species = (IntegerVectorSpecies)species;\n for (int i = 0; i < genomeLength(); i++)\n {\n int minGene = (int)_species.minGene(i);\n if (genome[i].getValue() < minGene)\n genome[i].setValue(minGene); //what do do for the TraceID?\n else\n {\n int maxGene = (int)_species.maxGene(i);\n if (genome[i].getValue() > maxGene)\n genome[i] = maxGene;\n }\n }\n\n */\n }", "@Override\n\tpublic int compareTo(Key o) {\n\t\tint temp = 0;\n\t\t\t\t\n\t\tif (this.value > o.value) \t\ttemp = 1;\n\t\telse if (this.value < o.value) temp = -1;\n\t\telse \t\t\t\t\t\t\ttemp = 0;\n\t\t\n\t\treturn temp;\n\t}", "public static long sanitizeUserArgs(String key, long valueTocheck,\n String baseKey, long baseValue, long minFactor, long maxFactor) {\n long minLimit = baseValue * minFactor;\n long maxLimit = baseValue * maxFactor;\n if (valueTocheck < minLimit) {\n LOG.warn(\n \"{} value = {} is smaller than min = {} based on\"\n + \" the key value of {}, reset to the min value {}.\",\n key, valueTocheck, minLimit, baseKey, minLimit);\n valueTocheck = minLimit;\n } else if (valueTocheck > maxLimit) {\n LOG.warn(\n \"{} value = {} is larger than max = {} based on\"\n + \" the key value of {}, reset to the max value {}.\",\n key, valueTocheck, maxLimit, baseKey, maxLimit);\n valueTocheck = maxLimit;\n }\n\n return valueTocheck;\n }", "public Query lessThanEqualTo(String key, Object value) {\n Preconditions.checkNotNull(key);\n builder.addFilter(builder.getOperator(QueryFilterBuilder.Operators.LESSTHANEQUAL), key, value);\n return this;\n }", "public Query lessThan(String key, Object value) {\n Preconditions.checkNotNull(key);\n builder.addFilter(builder.getOperator(QueryFilterBuilder.Operators.LESSTHAN), key, value);\n return this;\n }", "default DiscreteSet2D subLevelSet(double value) {\r\n\t\treturn pointsSatisfying(d -> d <= value);\r\n\t}", "private void setTrappedPeople(long trappedPeople) throws NumberOutOfBoundsException {\n if (!isValidTrappedPeople(trappedPeople)) {\n throw new NumberOutOfBoundsException(String.format(\"Number of trapped people must be larger or equal to zero and not \\\"%s\\\"\", trappedPeople));\n }\n this.trappedPeople = trappedPeople;\n }", "public Builder setMaxHP(int value) {\n bitField0_ |= 0x00002000;\n maxHP_ = value;\n onChanged();\n return this;\n }", "public final boolean greaterThanEquals() {\n\n\t\tif (size > 1) {\n\n\t\t\tdouble topMostValue = pop();\n\t\t\tdouble secondTopMostValue = pop();\n\t\t\tif (secondTopMostValue >= topMostValue) {\n\t\t\t\treturn true;\n\t\t\t}\n\t\t}\n\t\treturn false;\n\t}", "public int getMaxValue() {\n return maxValue;\n }", "public boolean setPropertyVolumeMax(long aValue);", "private void setMinThreshold() {\n minThreshold = value + value * postBoundChange / 100;\n }", "@JSProperty(\"maxRange\")\n void setMaxRange(double value);", "public Long getMaxValue() {\n return maxValue;\n }", "public int getMaxValue(){\n\t\treturn maxValue;\n\t}", "public void dec(String key) {\n if (map.containsKey(key)) {\n if (map.get(key) == 1) {\n map.remove(key);\n vals.get(1).remove(key);\n if (vals.get(1).size() > 0) {\n min = 1;\n minKey = vals.get(1).iterator().next();\n if (max == 1)\n maxKey = minKey;\n } else {\n vals.remove(1);\n if (map.size() > 0) {\n int tempMin = Integer.MAX_VALUE;\n for (Map.Entry<Integer, Set<String>> e : vals.entrySet()) {\n if (e.getValue().size() > 0)\n tempMin = Math.min(tempMin, e.getKey());\n }\n min = tempMin;\n minKey = vals.get(tempMin).iterator().next();\n } else {\n min = 0;\n max = 0;\n }\n }\n } else {\n map.put(key, map.get(key) - 1);\n int val = map.get(key);\n vals.get(val + 1).remove(key);\n if (vals.get(val + 1).size() == 0)\n vals.remove(val + 1);\n vals.putIfAbsent(val, new HashSet<>());\n vals.get(val).add(key);\n if (val + 1 == max) {\n if (vals.get(max) == null || vals.get(max).size() == 0)\n max--;\n else\n maxKey = vals.get(max).iterator().next();\n }\n if (val + 1 == min) {\n min--;\n minKey = key;\n }\n }\n }\n }", "public void setMax(){\n for (int i = 0; i < Nodes.size(); i++){\n this.MinDistance.add(Double.MAX_VALUE);\n }\n }", "public void setUpperBound(String upper) {\n upperBound = upper;\n }", "public Cut<Comparable<?>> c(DiscreteDomain<Comparable<?>> discreteDomain) {\n try {\n return Cut.b(discreteDomain.minValue());\n } catch (NoSuchElementException unused) {\n return this;\n }\n }", "public final void ensureMax() {\n\t\tfinal int temp = findMax(lookupPrefix) + 1;\n\t\tif (temp > currentSequenceNumber) {\n\t\t\tcurrentSequenceNumber = temp;\n\t\t}\n\t}", "@Override\n public void setSoftLowerLimit(double position)\n {\n final String funcName = \"setSoftLowerLimit\";\n\n if (debugEnabled)\n {\n dbgTrace.traceEnter(funcName, TrcDbgTrace.TraceLevel.API, \"position=%f\", position);\n dbgTrace.traceExit(funcName, TrcDbgTrace.TraceLevel.API);\n }\n\n softLowerLimit = position;\n }", "public QueryElement addGreaterThen(String property, Object value);", "public Builder setMaximumCapacity(int value) {\n \n maximumCapacity_ = value;\n onChanged();\n return this;\n }", "@Test(expected = IllegalArgumentException.class)\n\tpublic void endGreaterException() {\n\n\t\tset.endAt(set.size() + 1);\n\t}", "@Override\r\n public K ceilingKey(final K key) {\n return null;\r\n }", "public boolean greaterThanOrEqual(int gtPos) {\n if (isLastPosition()) {\n return true;\n }\n return this.value >= gtPos;\n }", "boolean isSetMaximum();", "public SigningMethodBuilder maxKeySize(Integer keySize) {\n this.object().setMaxKeySize(keySize);\n return this;\n }", "public boolean greaterThan(int gtPos) {\n if (isLastPosition()) {\n return true;\n }\n return this.value > gtPos;\n }", "LengthGreater createLengthGreater();", "public void param_value_max_SET(float src)\n { set_bytes(Float.floatToIntBits(src) & -1L, 4, data, 17); }", "public void setMaximum(int n) {\r\n int newMin = Math.min(n, min);\r\n int newValue = Math.min(n, getValue());\r\n int newExtent = Math.min(n - newValue, getExtent());\r\n setRangeProperties(newValue, newExtent, newMin, n, isAdjusting);\r\n }", "boolean updatePolicy() {\n double maxUtilityVal = -Double.MAX_VALUE;\n //if(x==19&&y==0)\n // System.out.println(\"minVal: \"+maxUtilityVal);\n for (int i = 0; i < AbsoluteDirection.values().length; i++) {\n double proposedValue = calculateUtility(AbsoluteDirection.values()[i]);\n // if(x==19&&y==0) {\n // System.out.println(\"Proposed value at cell \" + x + \", \" + y + \" is\" + proposedValue);\n\n // }\n if (proposedValue > maxUtilityVal) {\n policyDirection = AbsoluteDirection.values()[i];\n nextUtilityValue = proposedValue; // update curValues to nextValues at the end of iteration\n maxUtilityVal = proposedValue;\n }\n }\n\n return true;\n }", "public boolean setPropertyBalanceMax(long aValue)\n {\n return setPropertyUint(iPropertyBalanceMax, aValue);\n }", "public void setCurrentLengthOverMin(double newLengthOverMinInMeters) {\n if (newLengthOverMinInMeters >= 0 && newLengthOverMinInMeters <= maxLengthOverMin)\n this.currentLengthOverMin = newLengthOverMinInMeters;\n else if (newLengthOverMinInMeters < 0)\n this.currentLengthOverMin = 0;\n else\n this.currentLengthOverMin = maxLengthOverMin;\n }", "@DesireNoWarning(\"TQ\")\n public void set(@CheckForSigned int possibleNegativeValue) {\n if (possibleNegativeValue >= 0)\n nonNegativeValue = possibleNegativeValue;\n }", "public Builder setMaxHP(int value) {\n bitField0_ |= 0x00000040;\n maxHP_ = value;\n onChanged();\n return this;\n }", "public Builder setMaxHP(int value) {\n bitField0_ |= 0x00000040;\n maxHP_ = value;\n onChanged();\n return this;\n }", "public Builder setMaxHP(int value) {\n bitField0_ |= 0x00000040;\n maxHP_ = value;\n onChanged();\n return this;\n }", "public void setLower(int value) {\n this.lower = value;\n }", "public Builder setMaxHP(int value) {\n bitField0_ |= 0x00000010;\n maxHP_ = value;\n onChanged();\n return this;\n }", "public void setMinValue(int x) {\r\n\t\tminValue = x;\r\n\t}" ]
[ "0.535428", "0.53021044", "0.5262767", "0.5237858", "0.5198891", "0.51581746", "0.50987184", "0.5087891", "0.50375885", "0.5019532", "0.5005632", "0.49903324", "0.49725038", "0.4969487", "0.49645022", "0.49374336", "0.49367657", "0.49349645", "0.4932491", "0.4913041", "0.4899055", "0.48791403", "0.4871627", "0.4856595", "0.4841489", "0.48406637", "0.48391578", "0.4824826", "0.48227048", "0.48213023", "0.48165947", "0.47996604", "0.47885638", "0.4765282", "0.47622335", "0.47294658", "0.47269887", "0.4720719", "0.47116184", "0.47021425", "0.46988147", "0.46967056", "0.4694357", "0.46865693", "0.46765557", "0.46724927", "0.46682125", "0.46672228", "0.46397814", "0.46388587", "0.46259266", "0.46257916", "0.46175474", "0.46156725", "0.4610701", "0.46103948", "0.46093434", "0.46067235", "0.45967153", "0.45952797", "0.45868608", "0.45819637", "0.45786247", "0.45633388", "0.45598435", "0.45596626", "0.4556316", "0.4556234", "0.45558992", "0.45544374", "0.45522773", "0.45487666", "0.45482427", "0.4548215", "0.45344704", "0.4533033", "0.45247874", "0.45223582", "0.45202592", "0.45169094", "0.4514878", "0.44947538", "0.44814485", "0.44812492", "0.4474499", "0.44743025", "0.44521886", "0.44515517", "0.44512716", "0.44512275", "0.44510475", "0.4450245", "0.44496933", "0.44451764", "0.443928", "0.443928", "0.4438191", "0.44365504", "0.4434666", "0.44244993" ]
0.5729117
0
Gets the row identifier appended to this key, if there is one.
RID getRID();
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private Object _getRowKey()\n {\n Object data = getRowData();\n \n assert (_rowKeyProperty != null);\n return __resolveProperty(data, _rowKeyProperty);\n }", "public Object getRowKey()\n {\n if (isRowAvailable())\n {\n Object rowKey = _getRowKey();\n return rowKey;\n }\n else\n {\n return null;\n }\n }", "public Long getRowKey() {\n return (Long) getAttributeInternal(ROWKEY);\n }", "String get_row_id()\n {\n return row_id;\n }", "public Integer getRowId() {\n return rowId;\n }", "public RowID getRowID() {\n return (RowID)getAttributeInternal(ROWID);\n }", "public RowID getRowID() {\n return (RowID)getAttributeInternal(ROWID);\n }", "public int getRowId() {\n return rowId_;\n }", "public int getRowId() {\n return rowId_;\n }", "public int getRowId() {\n return rowId_;\n }", "public int getRowId() {\n return rowId_;\n }", "public int getRowId() {\n return rowId_;\n }", "public String getIdForRow(int row);", "public int getRowId() {\n return rowId_;\n }", "public int getRowId() {\n return rowId_;\n }", "public int getRowId() {\n return rowId_;\n }", "public int getRowId() {\n return rowId_;\n }", "public int getRowId() {\n return rowId_;\n }", "public int getRowid() {\n\t\treturn rowid;\n\t}", "public String getUniqueId(int row);", "protected Object getRowKey(Object row)\n {\n assert (_rowKeyProperty != null);\n return __resolveProperty(row, _rowKeyProperty);\n }", "public long getRowID()\n\t{ return m_nRowID ; }", "public String getRowKeyProperty()\n {\n return _rowKeyProperty;\n }", "public Integer getRowNumber() {\n\t\tif (isRowNumber) {\n\t\t\treturn (int) lineId;\n\t\t}\n\t\treturn null;\n\t}", "public Comparable getRowKey(int row) { return this.underlying.getRowKey(row); }", "public String[] getRowID() {\n \treturn rowID;\n }", "public String getKey() {\r\n\t\tStringBuilder builder = new StringBuilder();\r\n\t\tif (getLineNo() != null) {\r\n\t\t\tbuilder.append(getLineNo());\r\n\t\t} else if (this.getEntityId() != null) {\r\n\t\t\tbuilder.append(getEntityId());\r\n\t\t}\r\n\t\treturn builder.toString();\r\n\t}", "public String getRowID(int i) {\n \treturn rowID[i];\n }", "int getRowId();", "int getRowId();", "int getRowId();", "int getRowId();", "int getRowId();", "public Integer getRowNo() {\n return rowNo;\n }", "public String getKey() {\n\t\treturn id + \"\";\n\t}", "@Override\n\tpublic Object getRowKey(InvitoDTO arg0) {\n\t\treturn arg0.getId();\n\t}", "public String getPrimaryKey() throws CloneNotSupportedException {\r\n\t\tString key=\"\";\r\n\t\tfor (int i = 0; i < this.state.getSizeCol(); i++) {\r\n\t\t\tfor (int j = 0; j < this.state.getSizeRow(); j++) {\r\n\t\t\t\tkey+=this.state.getValue(new Position(i,j));\r\n\t\t\t}\r\n\t\t}\r\n\t\tkey+=\"?\"+this.state.getTractor().getPosition().toString();\r\n\t\treturn key;\r\n\t}", "public int getRowNumber()\r\n\t{\r\n\t\treturn this.rowNumber;\r\n\t}", "Key getPrimaryKey();", "@Override\n\tpublic String getKey() {\n\t\treturn id+\"\";\n\t}", "public String getSelectedRowID()\n\t{\n\t\tint selectedRow = recordTable.getSelectedRow();\n\t\tString returnData = null;\n\t\tif(selectedRow==-1)\n\t\t{//If there is no row selected...\n\t\t\treturn null;\n\t\t}\n\t\treturnData = (String)recordTable.getValueAt(selectedRow, Information.FIELDID);\n\t\treturn returnData;\n\t}", "public int getRowNumber() {\n\t\treturn rowNumber;\n\t}", "public int getRowNo() {\n return rowIndex+1;\n }", "public String getPrimaryKey() {\n return this.getString(R.string.primaryKey);\n }", "public void setRowKeyProperty(String rowKeyProperty)\n {\n _rowKeyProperty = rowKeyProperty;\n }", "public String fetchPrimaryKey(){\n\t\treturn primaryKey;\n\t}", "public long getKeyID()\n {\n return keyID;\n }", "public int getRow() {\n\t\t\treturn rowNumber;\n\t\t}", "public int keyId() {\n return keyId;\n }", "@Override\n\tpublic long getPrimaryKey() {\n\t\treturn _dictData.getPrimaryKey();\n\t}", "@Override\n\tpublic Object key() {\n\t\treturn id;\n\t}", "public IdKey getKey() {\n return idKey;\n }", "private String getRowIdColumn(ConnectorTableMetadata meta)\n {\n String rowIdColumn = AccumuloTableProperties.getRowId(meta.getProperties());\n if (rowIdColumn == null) {\n rowIdColumn = meta.getColumns().get(0).getName();\n }\n return rowIdColumn.toLowerCase();\n }", "public TableKey getKey() {\n \treturn key;\n }", "byte[] getActualRowKey(ConsumerConfig consumerConfig, byte[] originalRowKey);", "@Override\n\tpublic long getPrimaryKey() {\n\t\treturn _state.getPrimaryKey();\n\t}", "@Override\r\n public final Integer getIdentifier() {\r\n return getIdent();\r\n }", "public String getPrimaryKey() {\n if (primaryKey == null) primaryKey = \"id\";\n return primaryKey;\n }", "public int getRowNum(){ return this.rowNum; }", "@Basic( optional = false )\r\n\t@Column( name = \"table_row_id\", nullable = false )\r\n\tpublic Integer getTableRowId() {\r\n\t\treturn this.tableRowId;\r\n\t\t\r\n\t}", "public byte getValueInRowKey() {\n return valueInRowKey;\n }", "private String getRowIdName(String tableName) {\n String rowId = \"\";\n switch(tableName) {\n case SchemaConstants.MEETINGS_TABLE:\n rowId = SchemaConstants.MEETING_ROWID;\n break;\n case SchemaConstants.RACES_TABLE:\n rowId = SchemaConstants.RACE_ROWID;\n break;\n case SchemaConstants.RUNNERS_TABLE:\n rowId = SchemaConstants.RUNNER_ROWID;\n break;\n }\n return rowId;\n }", "public static int getIdentifier(){\n\t\tif(index > ids.size() - 1){\n\t\t\tindex = 0;\n\t\t}\n\t\t// Post increment is used here, returns index then increments index\n\t\treturn ids.get(index++);\n\t}", "public String getPrimaryKey() {\r\n\t\treturn primaryKey;\r\n\t}", "public Number getRfrtHeaderIdPk() {\r\n return (Number) getAttributeInternal(RFRTHEADERIDPK);\r\n }", "@Override\n\tpublic long getPrimaryKey() {\n\t\treturn _employee.getPrimaryKey();\n\t}", "public StrColumn getEntryId() {\n return delegate.getColumn(\"entry_id\", DelegatingStrColumn::new);\n }", "public StrColumn getEntryId() {\n return delegate.getColumn(\"entry_id\", DelegatingStrColumn::new);\n }", "public StrColumn getEntryId() {\n return delegate.getColumn(\"entry_id\", DelegatingStrColumn::new);\n }", "java.lang.String getHeaderTableId();", "public String getPrimaryKey() {\r\n return primaryKey;\r\n }", "public String getPrimaryKey() {\n return getBasicChar().getPrimaryKey();\n }", "public int getRowIndex(Comparable key) { return this.underlying.getRowIndex(key); }", "@Override\n\tpublic long getPrimaryKey() {\n\t\treturn _second.getPrimaryKey();\n\t}", "public StrColumn getIprId() {\n return delegate.getColumn(\"ipr_id\", DelegatingStrColumn::new);\n }", "public String getPrimaryKey() {\n\t\treturn primaryKey;\n\t}", "@Override\n\tpublic long getPrimaryKey() {\n\t\treturn _expandoColumn.getPrimaryKey();\n\t}", "java.lang.String getClientRecordId();", "public RowId getRowId(int columnIndex) throws SQLException {\n\n throw Message.getUnsupportedException();\n }", "public int getRow() {\r\n\t\treturn this.row;\r\n\t}", "private Integer newPrimaryKey( )\n {\n DAOUtil daoUtil = new DAOUtil( SQL_QUERY_NEW_PK );\n daoUtil.executeQuery( );\n Integer nKey = null;\n\n if ( daoUtil.next( ) )\n {\n nKey = daoUtil.getInt( 1 );\n }\n else\n {\n nKey = 1;\n }\n daoUtil.close( );\n\n return nKey.intValue( );\n }", "public int getKey()\n {\n return key;\n }", "public int getKey()\n {\n return key;\n }", "public int getKey()\n {\n return key;\n }", "public int getKey()\n {\n return key;\n }", "public Integer getKey()\r\n {\r\n return key;\r\n }", "public String getKey() {\r\n return getAttribute(\"id\");\r\n }", "public int getRow()\r\n\t{\r\n\t\treturn this.row;\r\n\t}", "public int getKey() {\r\n return key;\r\n }", "public Key getID () {\n\t\treturn id;\n\t}", "public String getId() {\n int result;\n result = (key != null ? key.hashCode() : 0);\n result = 31 * result + (overridable ? 1 : 0);\n result = 31 * result + (value != null ? value.hashCode() : 0);\n result = 31 * result + (set ? 1 : 0);\n if (result < 0)\n result = result * -1;\n return String.valueOf(result);\n }", "public RowId getRowId(String columnName) throws SQLException {\n\n throw Message.getUnsupportedException();\n }", "public java.lang.String getIdentifierKey() {\r\n return localIdentifierKey;\r\n }", "public String keyIdentifier() {\n return this.keyIdentifier;\n }", "public String keyIdentifier() {\n return this.keyIdentifier;\n }", "public int getRow() {\n return this.row;\n }", "public int getRow() {\n return this.row;\n }", "public int getRow() {\r\n return this.row;\r\n }", "@Override\n public int getKey() {\n return this.key;\n }", "public long getPrimaryKey() {\n\t\treturn _tempNoTiceShipMessage.getPrimaryKey();\n\t}", "public int getKey() {\n return key;\n }" ]
[ "0.7891971", "0.7637856", "0.75355524", "0.7193784", "0.69829595", "0.6959704", "0.6959704", "0.691728", "0.691728", "0.691728", "0.691728", "0.691728", "0.6865013", "0.68579423", "0.68579423", "0.68579423", "0.68579423", "0.68579423", "0.68576235", "0.6820404", "0.68075687", "0.6709473", "0.67078257", "0.66882265", "0.66787237", "0.6586468", "0.6560647", "0.6548541", "0.6545238", "0.6545238", "0.6545238", "0.6545238", "0.6545238", "0.654108", "0.6503509", "0.64709467", "0.6468823", "0.64373696", "0.6365814", "0.6339501", "0.63215435", "0.6281361", "0.6270618", "0.62538415", "0.6240505", "0.6236368", "0.61827385", "0.61763114", "0.61747134", "0.6168711", "0.6159693", "0.6139091", "0.61277366", "0.61130756", "0.61069995", "0.6101782", "0.60970825", "0.608816", "0.60735565", "0.60614157", "0.60274816", "0.60147494", "0.6014587", "0.6010088", "0.60016423", "0.5988476", "0.59848255", "0.59848255", "0.59848255", "0.5977064", "0.5965558", "0.5965344", "0.59638315", "0.59576225", "0.5941006", "0.59400755", "0.59355843", "0.59271413", "0.5926027", "0.59236544", "0.59186655", "0.59159523", "0.59159523", "0.59159523", "0.59159523", "0.59050536", "0.59019136", "0.5900896", "0.5893812", "0.5889181", "0.58887845", "0.58873343", "0.5886721", "0.5882181", "0.5882181", "0.58797914", "0.58797914", "0.5877959", "0.58770543", "0.58744293", "0.58640987" ]
0.0
-1
Sets the row identifier for this key. If the row identifier is nonnull then it will be appended to the value of the key in order to establish the key's uniqueness. A reference to the RID object is kept in this key, so subsequent changes to the RID object will be reflected in the value of the key.
void setRID(RID rid);
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void setRowId(Integer rowId) {\n this.rowId = rowId;\n }", "public void setRowKey(Long value) {\n setAttributeInternal(ROWKEY, value);\n }", "public void setRowKeyProperty(String rowKeyProperty)\n {\n _rowKeyProperty = rowKeyProperty;\n }", "public void setRowKey(Object key)\n {\n if (key == null)\n {\n setRowIndex(-1);\n return;\n }\n\n if (getRowKey() != null && getRowKey().equals(key))\n return;\n \n for (int i = 0; i < getRowCount(); i++)\n {\n setRowIndex(i);\n Object prop = getRowKey();\n if (key.equals(prop))\n {\n return;\n }\n }\n\n // if we didn't find an element with a matching key,\n // then don't make any rows current\n setRowIndex(-1);\n }", "public Dargle setRowID( long nID )\n\t{ m_nRowID = nID ; return this ; }", "public Builder setRowId(int value) {\n \n rowId_ = value;\n onChanged();\n return this;\n }", "public Builder setRowId(int value) {\n \n rowId_ = value;\n onChanged();\n return this;\n }", "public Builder setRowId(int value) {\n \n rowId_ = value;\n onChanged();\n return this;\n }", "public Builder setRowId(int value) {\n \n rowId_ = value;\n onChanged();\n return this;\n }", "public Builder setRowId(int value) {\n \n rowId_ = value;\n onChanged();\n return this;\n }", "public void setPrimaryKey(String primaryKey);", "public void setPrimaryKey(String primaryKey);", "public void setPrimaryKey(String primaryKey);", "public void setPrimaryKey(long primaryKey);", "public void setPrimaryKey(long primaryKey);", "public void setPrimaryKey(long primaryKey);", "public void setPrimaryKey(long primaryKey);", "public void setPrimaryKey(long primaryKey);", "public void setPrimaryKey(long primaryKey);", "public void setPrimaryKey(long primaryKey);", "public void setPrimaryKey(long primaryKey);", "public void setPrimaryKey(long primaryKey);", "public void setPrimaryKey(long primaryKey);", "public void setPrimaryKey(long primaryKey);", "public void setPrimaryKey(long primaryKey);", "public void setPrimaryKey(long primaryKey);", "public void setPrimaryKey(long primaryKey);", "public void setPrimaryKey(long primaryKey);", "public void setPrimaryKey(long primaryKey);", "public void setPrimaryKey(long primaryKey);", "@Override\n\tpublic void setRowId(int parameterIndex, RowId x) throws SQLException {\n\t\t\n\t}", "public void setTableRowId(final Integer tableRowId) {\r\n\t\tthis.tableRowId = tableRowId;\r\n\t}", "public void setRid(Integer rid) {\r\n this.rid = rid;\r\n }", "public void setRId(long value) {\r\n this.rId = value;\r\n }", "public Integer getRowId() {\n return rowId;\n }", "public int getRowId() {\n return rowId_;\n }", "public int getRowId() {\n return rowId_;\n }", "public int getRowId() {\n return rowId_;\n }", "public int getRowId() {\n return rowId_;\n }", "public int getRowId() {\n return rowId_;\n }", "public int getRowId() {\n return rowId_;\n }", "public int getRowId() {\n return rowId_;\n }", "public int getRowId() {\n return rowId_;\n }", "public int getRowId() {\n return rowId_;\n }", "public int getRowId() {\n return rowId_;\n }", "public void setPrimaryKey(int primaryKey);", "public void setRid(Integer rid) {\n this.rid = rid;\n }", "@Override\n\tpublic void setPrimaryKey(long primaryKey) {\n\t\t_dictData.setPrimaryKey(primaryKey);\n\t}", "@Override\n\tpublic void setPrimaryKey(long primaryKey) {\n\t\t_state.setPrimaryKey(primaryKey);\n\t}", "public SQLRowIdentifier() {\n\t\tsuper(EnumSQLType.SqlRowIdentifier, LENGTH);\n\t\t\n\t\tthis.page = new SQLInteger();\n\t\tthis.slot = new SQLInteger();\n\t}", "public void setPrimaryKey(long primaryKey) {\n this.primaryKey = primaryKey;\n }", "public Long getRowKey() {\n return (Long) getAttributeInternal(ROWKEY);\n }", "public void setRowNo(Integer rowNo) {\n this.rowNo = rowNo;\n }", "public int getRowid() {\n\t\treturn rowid;\n\t}", "@Override\n\tpublic void setPrimaryKey(long primaryKey) {\n\t\t_candidate.setPrimaryKey(primaryKey);\n\t}", "private Object _getRowKey()\n {\n Object data = getRowData();\n \n assert (_rowKeyProperty != null);\n return __resolveProperty(data, _rowKeyProperty);\n }", "@Override\n\tpublic void setPrimaryKey(long primaryKey) {\n\t\t_esfTournament.setPrimaryKey(primaryKey);\n\t}", "@Override\n\tpublic void setPrimaryKey(long primaryKey) {\n\t\t_changesetEntry.setPrimaryKey(primaryKey);\n\t}", "public long getRowID()\n\t{ return m_nRowID ; }", "@Override\n\tpublic void setPrimaryKey(long primaryKey) {\n\t\t_employee.setPrimaryKey(primaryKey);\n\t}", "public void setRecordId(RecordId rid) {\n\t\trecordId = rid;\n\n\t}", "public void setRowId(int parameterIndex, RowId x) throws SQLException {\n currentPreparedStatement.setRowId(parameterIndex, x);\n }", "@Override\n\tpublic void setPrimaryKey(long primaryKey) {\n\t\t_phieugiahan.setPrimaryKey(primaryKey);\n\t}", "@OfMethod({\"setRowId(java.lang.String,java.sql.RowId)\",\"setRowId(int,java.sql.RowId)\"})\n public void testSetRowId() throws Exception {\n String parameterName = getParameterName();\n int parameterIndex = getParameterIndex();\n RowId x = null;\n CallableStatement instance = newClosedCall();\n\n try {\n instance.setRowId(parameterName, x);\n fail(\"Allowed set row id by parameter name after close\");\n } catch (SQLException ex) {\n checkException(ex);\n }\n\n try {\n instance.setRowId(parameterIndex, x);\n fail(\"Allowed set row id by parameter index after close\");\n } catch (SQLException ex) {\n checkException(ex);\n }\n }", "public void setPrimaryKey(String primaryKey) {\r\n this.primaryKey = primaryKey;\r\n }", "String get_row_id()\n {\n return row_id;\n }", "public void setPrimaryKey(String primaryKey) {\r\n\t\tthis.primaryKey = primaryKey;\r\n\t}", "@Override\n\tpublic void setPrimaryKey(int primaryKey) {\n\t\t_locMstLocation.setPrimaryKey(primaryKey);\n\t}", "public void setRid(String rid) {\n this.rid = rid;\n }", "public void setPrimaryKey(String primaryKey) {\n this.primaryKey = primaryKey;\n }", "protected Object getRowKey(Object row)\n {\n assert (_rowKeyProperty != null);\n return __resolveProperty(row, _rowKeyProperty);\n }", "public void setRow(int newRow) {\n this.row = newRow;\n }", "@Override\n\tpublic void setPrimaryKey(long primaryKey) {\n\t\t_second.setPrimaryKey(primaryKey);\n\t}", "public void setRow(int r) {\n\t\tthis.row = r;\n\t}", "@Override\n\tpublic void setPrimaryKey(long primaryKey) {\n\t\t_buySellProducts.setPrimaryKey(primaryKey);\n\t}", "public void setPrimaryKey(long primaryKey) {\n _courseImage.setPrimaryKey(primaryKey);\n }", "public void setPrimaryKey(long primaryKey) {\n _sTransaction.setPrimaryKey(primaryKey);\n }", "public RowID getRowID() {\n return (RowID)getAttributeInternal(ROWID);\n }", "public RowID getRowID() {\n return (RowID)getAttributeInternal(ROWID);\n }", "@Override\n\tpublic void setPrimaryKey(long primaryKey) {\n\t\t_paper.setPrimaryKey(primaryKey);\n\t}", "@Override\n\tpublic void setPrimaryKey(long primaryKey) {\n\t\t_dlSyncEvent.setPrimaryKey(primaryKey);\n\t}", "@Override\n\tpublic void setPrimaryKey(int primaryKey) {\n\t\t_keHoachKiemDemNuoc.setPrimaryKey(primaryKey);\n\t}", "@Override\n\tpublic void setPrimaryKey(long primaryKey) {\n\t\tmodel.setPrimaryKey(primaryKey);\n\t}", "@Override\n\tpublic void setPrimaryKey(long primaryKey) {\n\t\tmodel.setPrimaryKey(primaryKey);\n\t}", "@Override\n\tpublic void setPrimaryKey(long primaryKey) {\n\t\tmodel.setPrimaryKey(primaryKey);\n\t}", "private void setRowInfo(int rowIndex, T rowValue) {\n this.rowIndex = rowIndex;\n this.rowValueKey = cellTable.getValueKey(rowValue);\n this.subrowIndex = 0; // Reset the subrow.\n }", "public void setRowNumber(int rowNumber) {\n this.rowNumber = rowNumber;\n }", "public void setPrimaryKey(int primaryKey) {\n\t\tthis.primaryKey = primaryKey;\n\t}", "@Override\n public void setPrimaryKey(long primaryKey) {\n _partido.setPrimaryKey(primaryKey);\n }", "public void setPrimaryKey(String primaryKey) {\n\t\tthis.primaryKey = primaryKey;\n\t}", "public void updateRowId(String columnName, RowId x) throws SQLException {\n\n throw Message.getUnsupportedException();\n }", "public static void setRowNumber(int pRowNumber) {\r\n\t\trowNumber = pRowNumber;\r\n\t}", "@Override\n\tpublic void setPrimaryKey(long primaryKey) {\n\t\t_lineaGastoCategoria.setPrimaryKey(primaryKey);\n\t}", "public IndexKey(BpCoord start, long lineId, boolean isRowNumber) {\n\t\tthis(start, lineId);\n\t\tthis.isRowNumber = isRowNumber;\n\t}", "public void setPrimaryKey(long primaryKey) {\n\t\t_telefonoSolicitudProducto.setPrimaryKey(primaryKey);\n\t}", "public void updateRowId(int columnIndex, RowId x) throws SQLException {\n\n throw Message.getUnsupportedException();\n }", "public void setRfrtHeaderIdPk(Number value) {\r\n setAttributeInternal(RFRTHEADERIDPK, value);\r\n }", "@Override\n\tpublic void setPrimaryKey(long primaryKey) {\n\t\t_scienceApp.setPrimaryKey(primaryKey);\n\t}", "@Override\n\tpublic void setPrimaryKey(long primaryKey) {\n\t\t_userSync.setPrimaryKey(primaryKey);\n\t}", "public void setKey(String nkey) {\r\n setAttribute(\"id\", nkey);\r\n }" ]
[ "0.6987444", "0.6615994", "0.6517639", "0.63442534", "0.6028835", "0.59812224", "0.59812224", "0.59812224", "0.59812224", "0.59812224", "0.5935996", "0.5935996", "0.5935996", "0.5887033", "0.5887033", "0.5887033", "0.5887033", "0.5887033", "0.5887033", "0.5887033", "0.5887033", "0.5887033", "0.5887033", "0.5887033", "0.5887033", "0.5887033", "0.5887033", "0.5887033", "0.5887033", "0.5887033", "0.587001", "0.58454806", "0.5818892", "0.5808094", "0.5802314", "0.5790443", "0.5790443", "0.5790443", "0.5790443", "0.5790443", "0.5786948", "0.5786948", "0.5786948", "0.5786948", "0.5786948", "0.5785297", "0.5756363", "0.57224417", "0.56838053", "0.5663436", "0.5651804", "0.5647377", "0.5639576", "0.56125754", "0.55954725", "0.556799", "0.55612695", "0.55444086", "0.55427593", "0.5529547", "0.55119306", "0.54980016", "0.54886985", "0.5488198", "0.5476989", "0.5466103", "0.54616934", "0.54440624", "0.5439659", "0.54250634", "0.54179865", "0.5412975", "0.54077786", "0.5396921", "0.5382759", "0.5378857", "0.5372572", "0.5369989", "0.5369989", "0.5367009", "0.53653115", "0.53636855", "0.5362594", "0.5362594", "0.5362594", "0.5353943", "0.5335009", "0.53297496", "0.5326798", "0.5320042", "0.5314761", "0.531259", "0.5306632", "0.53052294", "0.52781016", "0.5277465", "0.5263307", "0.5252947", "0.524556", "0.5235748" ]
0.6382738
3
TODO Autogenerated method stub
@Override public void checkClientTrusted(X509Certificate[] chain, String authType) throws CertificateException { }
{ "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 void checkServerTrusted(X509Certificate[] chain, String authType) throws CertificateException { }
{ "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 X509Certificate[] getAcceptedIssuers() { 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
====================================== = Protected Methods = ======================================
private String getMessage(FacesContext facesContext, String msgKey, Object... args) { Locale locale = facesContext.getViewRoot().getLocale(); ClassLoader classLoader = Thread.currentThread().getContextClassLoader(); ResourceBundle bundle = ResourceBundle.getBundle("Messages", locale, classLoader); String msgValue = bundle.getString(msgKey); return MessageFormat.format(msgValue, args); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n public void perish() {\n \n }", "@Override\n protected void prot() {\n }", "@Override\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}", "@Override\n\tprotected void interr() {\n\t}", "private stendhal() {\n\t}", "@Override\n\tpublic void grabar() {\n\t\t\n\t}", "@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\n\tpublic void comer() {\n\t\t\n\t}", "@Override\n\tpublic void sacrifier() {\n\t\t\n\t}", "@Override\n protected void init() {\n }", "@Override\n protected void initialize() \n {\n \n }", "@Override\n protected void initialize() {\n\n \n }", "@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 entrenar() {\n\t\t\n\t}", "@Override\n public void init() {\n\n }", "@Override\n\tpublic void anular() {\n\n\t}", "@Override\n\tprotected void initialize() {\n\t\t\n\t}", "@Override\n\tprotected void initialize() {\n\t\t\n\t}", "@Override\n void init() {\n }", "@Override\n public void init() {\n }", "private Rekenhulp()\n\t{\n\t}", "@Override\r\n\t\tpublic void init() {\n\t\t\t\r\n\t\t}", "@Override\r\n\tprotected void initialize() {\r\n\t\t\r\n\t\t\r\n\t}", "@Override\n\tprotected void getExras() {\n\n\t}", "@Override\n\tprotected void logic() {\n\n\t}", "@Override\r\n\tpublic void tires() {\n\t\t\r\n\t}", "@Override\r\n\tprotected void initSelfData() {\n\t\t\r\n\t}", "@Override\r\n\tprotected void initSelfData() {\n\t\t\r\n\t}", "@Override\n public void function()\n {\n }", "@Override\n public void function()\n {\n }", "@Override\r\n\tpublic void dormir() {\n\t\t\r\n\t}", "protected Doodler() {\n\t}", "@Override\n\tprotected void initialize() {\n\n\t}", "@Override\n\tprotected void getData() {\n\t\t\n\t}", "@Override\r\n\tpublic void rozmnozovat() {\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\r\n\tprotected void initialize() {\n\r\n\t}", "@Override\n protected void getExras() {\n }", "@Override\r\n \tpublic void process() {\n \t\t\r\n \t}", "@Override\n\tpublic void nadar() {\n\t\t\n\t}", "@Override\r\n\tpublic void init() {}", "@Override\n\tprotected void initialize() {\n\t}", "@Override\n\tprotected void initialize() {\n\t}", "@Override\n\tprotected void initData() {\n\t\t\n\t}", "@Override\n public void init() {}", "protected void initialize() {}", "protected void initialize() {}", "public final void mo51373a() {\n }", "protected MetadataUGWD() {/* intentionally empty block */}", "@Override\n public void inizializza() {\n\n super.inizializza();\n }", "@Override\r\n\tpublic void stehReagieren() {\r\n\t\t//\r\n\t}", "@Override\n public void func_104112_b() {\n \n }", "@Override\n public void initialize() { \n }", "protected void init() {\n // to override and use this method\n }", "@Override\r\n\t\tprotected void run() {\n\t\t\t\r\n\t\t}", "@Override\r\n\tpublic void init()\r\n\t{\n\t}", "@Override\n public void initialize() {\n \n }", "@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 protected void initData() {\n }", "@Override\n protected void initData() {\n }", "@Override\n public void init() {\n\n }", "@Override\n public void init() {\n\n }", "@Override\r\n\tprotected void initData() {\n\r\n\t}", "@Override\r\n\t\t\tpublic void annadir() {\n\r\n\t\t\t}", "@Override\n\tpublic void ligar() {\n\t\t\n\t}", "@Override\r\n\tprotected void prepare()\r\n\t{\r\n\r\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\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}", "@Override\n public void initialize() {}", "@Override\n public void initialize() {}", "@Override\n public void initialize() {}", "@Override\n\tprotected void update() {\n\t\t\n\t}", "@Override\n\tprotected void lazyLoad() {\n\t\t\n\t}", "@Override\n public void init() {\n }", "@Override\r\n\tpublic final void init() {\r\n\r\n\t}", "protected Problem() {/* intentionally empty block */}", "@Override\n public void initialize() {\n }", "@Override\n public void initialize() {\n }", "@Override\n public void initialize() {\n }", "@Override\n public void initialize() {\n }", "@Override\n public void initialize() {\n }", "@Override\n public void initialize() {\n }", "@Override\n public void initialize() {\n }" ]
[ "0.69798076", "0.6753445", "0.6727543", "0.6699109", "0.666481", "0.66411823", "0.66272616", "0.66272616", "0.66272616", "0.66272616", "0.66272616", "0.66272616", "0.6621906", "0.65120304", "0.6504848", "0.65000165", "0.6468775", "0.6441049", "0.6441049", "0.6332303", "0.63258946", "0.63233054", "0.6313272", "0.6313272", "0.6304897", "0.6296638", "0.6290519", "0.6274266", "0.62595755", "0.6258982", "0.6256918", "0.6251692", "0.6247437", "0.6247437", "0.62364006", "0.62364006", "0.6234843", "0.623109", "0.62247205", "0.6222881", "0.62175286", "0.6208056", "0.6208056", "0.61988556", "0.6170194", "0.61624634", "0.61599225", "0.6159476", "0.61582994", "0.61582994", "0.61489886", "0.61428887", "0.61403984", "0.61403984", "0.6136136", "0.6120698", "0.6120052", "0.611052", "0.61087275", "0.6098291", "0.6094383", "0.6093784", "0.60926664", "0.60867506", "0.60785496", "0.60785496", "0.60785496", "0.6071416", "0.6071416", "0.60711664", "0.60711664", "0.60659987", "0.6055661", "0.6049739", "0.60399336", "0.6035919", "0.6035919", "0.6035919", "0.6035919", "0.6035919", "0.6033435", "0.6033435", "0.6033435", "0.6033435", "0.6033435", "0.6033435", "0.60316336", "0.60316336", "0.60316336", "0.60193443", "0.6000265", "0.59989715", "0.59981304", "0.599769", "0.59943837", "0.59943837", "0.59943837", "0.59943837", "0.59943837", "0.59943837", "0.59943837" ]
0.0
-1