blob_id
stringlengths
40
40
__id__
int64
225
39,780B
directory_id
stringlengths
40
40
path
stringlengths
6
313
content_id
stringlengths
40
40
detected_licenses
list
license_type
stringclasses
2 values
repo_name
stringlengths
6
132
repo_url
stringlengths
25
151
snapshot_id
stringlengths
40
40
revision_id
stringlengths
40
40
branch_name
stringlengths
4
70
visit_date
timestamp[ns]
revision_date
timestamp[ns]
committer_date
timestamp[ns]
github_id
int64
7.28k
689M
star_events_count
int64
0
131k
fork_events_count
int64
0
48k
gha_license_id
stringclasses
23 values
gha_fork
bool
2 classes
gha_event_created_at
timestamp[ns]
gha_created_at
timestamp[ns]
gha_updated_at
timestamp[ns]
gha_pushed_at
timestamp[ns]
gha_size
int64
0
40.4M
gha_stargazers_count
int32
0
112k
gha_forks_count
int32
0
39.4k
gha_open_issues_count
int32
0
11k
gha_language
stringlengths
1
21
gha_archived
bool
2 classes
gha_disabled
bool
1 class
content
stringlengths
7
4.37M
src_encoding
stringlengths
3
16
language
stringclasses
1 value
length_bytes
int64
7
4.37M
extension
stringclasses
24 values
filename
stringlengths
4
174
language_id
stringclasses
1 value
entities
list
contaminating_dataset
stringclasses
0 values
malware_signatures
list
redacted_content
stringlengths
7
4.37M
redacted_length_bytes
int64
7
4.37M
alphanum_fraction
float32
0.25
0.94
alpha_fraction
float32
0.25
0.94
num_lines
int32
1
84k
avg_line_length
float32
0.76
99.9
std_line_length
float32
0
220
max_line_length
int32
5
998
is_vendor
bool
2 classes
is_generated
bool
1 class
max_hex_length
int32
0
319
hex_fraction
float32
0
0.38
max_unicode_length
int32
0
408
unicode_fraction
float32
0
0.36
max_base64_length
int32
0
506
base64_fraction
float32
0
0.5
avg_csv_sep_count
float32
0
4
is_autogen_header
bool
1 class
is_empty_html
bool
1 class
shard
stringclasses
16 values
d44a9a29408b2c3271364bcd2edaff3c4d2ceded
33,878,702,053,482
b71d65f7b96f0fd27bf67b2ee1ebd33efb2b1c12
/05-SSM个人博客/blog/src/test/java/test/TestJedis.java
3473501a73e2a4a1a81710ac4b9d61da7ac11b5e
[]
no_license
luguanxing/JavaWeb-Apps
https://github.com/luguanxing/JavaWeb-Apps
81082420edc718734e2df1b8e8d70e80cea33a78
49881bdec84320ba2990c87a9e87519bc25522c6
refs/heads/master
2021-09-08T03:24:57.547000
2018-03-06T18:08:26
2018-03-06T18:08:26
103,841,721
1
0
null
null
null
null
null
null
null
null
null
null
null
null
null
package test; import org.junit.Test; import redis.clients.jedis.Jedis; public class TestJedis { @Test public void testJedis() throws Exception { Jedis jedis = new Jedis("127.0.0.1", 6379); jedis.set("test", "helloworld"); String str = jedis.get("test"); System.out.println(str); jedis.close(); } }
UTF-8
Java
317
java
TestJedis.java
Java
[ { "context": "s() throws Exception {\n\t\tJedis jedis = new Jedis(\"127.0.0.1\", 6379);\n\t\tjedis.set(\"test\", \"helloworld\");\n\t\tStr", "end": 187, "score": 0.9570953845977783, "start": 178, "tag": "IP_ADDRESS", "value": "127.0.0.1" } ]
null
[]
package test; import org.junit.Test; import redis.clients.jedis.Jedis; public class TestJedis { @Test public void testJedis() throws Exception { Jedis jedis = new Jedis("127.0.0.1", 6379); jedis.set("test", "helloworld"); String str = jedis.get("test"); System.out.println(str); jedis.close(); } }
317
0.678233
0.646688
18
16.611111
15.713189
45
false
false
0
0
0
0
0
0
1.333333
false
false
9
68b31c80016cb4541909770f42572d1c6f0ced87
33,878,702,051,560
509b012dd70c2bc2b55431ca57733733e5a626c3
/Proyecto Frameset Dinamico con hipervinculos dinamicos/FRAMESETDINAMICO9/src/java/PaqueteServlets/Servlet3.java
a6862ddb3495cb5e8f9e642a2f30d663eb13125a
[]
no_license
MartinBarriga/Web-Technologies
https://github.com/MartinBarriga/Web-Technologies
f42055aec4370564ee24f3e8e9b14c63db14bdc0
05482abc32f4c443bcecb3808a97942b626178dd
refs/heads/master
2020-06-12T17:57:09.284000
2019-06-29T07:49:59
2019-06-29T07:49:59
194,379,243
0
1
null
null
null
null
null
null
null
null
null
null
null
null
null
package PaqueteServlets; import java.io.IOException; import java.io.PrintWriter; import javax.servlet.ServletException; import javax.servlet.http.HttpServlet; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; import javax.servlet.http.HttpSession; public class Servlet3 extends HttpServlet { @Override protected void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { response.setContentType("text/html;charset=UTF-8"); HttpSession session = request.getSession(); String numero = (String)session.getAttribute("numero"); int numeroInt = Integer.parseInt(numero); PrintWriter out = response.getWriter(); out.println("<!DOCTYPE html>"); out.println("<html>"); out.println("<head>"); out.println("<title>Servlet1</title>"); out.println("</head>"); out.println("<body>"); for(int i = 0; i<numeroInt; i++) { out.println("<a href = '" +request.getParameter("href" +i) + "' target = 'derecho'>" + request.getParameter("texto" + i) + "</a>"); } out.println("</body>"); out.println("</html>"); } }
UTF-8
Java
1,346
java
Servlet3.java
Java
[]
null
[]
package PaqueteServlets; import java.io.IOException; import java.io.PrintWriter; import javax.servlet.ServletException; import javax.servlet.http.HttpServlet; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; import javax.servlet.http.HttpSession; public class Servlet3 extends HttpServlet { @Override protected void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { response.setContentType("text/html;charset=UTF-8"); HttpSession session = request.getSession(); String numero = (String)session.getAttribute("numero"); int numeroInt = Integer.parseInt(numero); PrintWriter out = response.getWriter(); out.println("<!DOCTYPE html>"); out.println("<html>"); out.println("<head>"); out.println("<title>Servlet1</title>"); out.println("</head>"); out.println("<body>"); for(int i = 0; i<numeroInt; i++) { out.println("<a href = '" +request.getParameter("href" +i) + "' target = 'derecho'>" + request.getParameter("texto" + i) + "</a>"); } out.println("</body>"); out.println("</html>"); } }
1,346
0.601783
0.598811
36
36.333332
28.089144
148
false
false
0
0
0
0
0
0
0.75
false
false
9
b0ea29488e982a0136af647325ae51f4f4ca9b2f
33,878,702,052,841
dba11f957bfe5da6f754de13a0256a997983f674
/src/main/java/com/leetcode/weekly/weekly202/_1553_Minimum_Number_of_Days_to_Eat_N_Oranges.java
715c0761db558df1b39f6999656b2577e5c4eba2
[]
no_license
chenxi-null/leetcode
https://github.com/chenxi-null/leetcode
d0945f146d7a37c6012755679195c71b567218e6
5a391c8e5177596bcd560da8ef68c5c4ea8deeae
refs/heads/master
2023-06-24T22:07:31.293000
2021-05-29T17:22:47
2021-05-29T17:24:01
77,845,371
0
0
null
false
2023-06-14T22:30:54
2017-01-02T16:08:53
2021-05-29T17:24:21
2023-06-14T22:30:53
282
0
0
1
Java
false
false
package com.leetcode.weekly.weekly202; /* Given an integer array arr, return true if there are three consecutive odd numbers in the array. Otherwise, return false. Example 1: Input: arr = [2,6,4,1] Output: false Explanation: There are no three consecutive odds. Example 2: Input: arr = [1,2,34,3,4,5,7,23,12] Output: true Explanation: [5,7,23] are three consecutive odds. Constraints: 1 <= arr.length <= 1000 1 <= arr[i] <= 1000 https://leetcode-cn.com/problems/three-consecutive-odds --- #[Trying] issue: Out Of Memory */ class _1553_Minimum_Number_of_Days_to_Eat_N_Oranges { public int minDays(int n) { int[] dp = new int[n + 1]; dp[0] = 0; dp[1] = 1; for (int i = 2; i <= n; i++) { int min = dp[i - 1]; if (i % 2 == 0) { min = Math.min(min, dp[i/2]); } if (i % 3 == 0) { min = Math.min(min, dp[i/3]); } dp[i] = min + 1; } return dp[n]; } }
UTF-8
Java
1,013
java
_1553_Minimum_Number_of_Days_to_Eat_N_Oranges.java
Java
[]
null
[]
package com.leetcode.weekly.weekly202; /* Given an integer array arr, return true if there are three consecutive odd numbers in the array. Otherwise, return false. Example 1: Input: arr = [2,6,4,1] Output: false Explanation: There are no three consecutive odds. Example 2: Input: arr = [1,2,34,3,4,5,7,23,12] Output: true Explanation: [5,7,23] are three consecutive odds. Constraints: 1 <= arr.length <= 1000 1 <= arr[i] <= 1000 https://leetcode-cn.com/problems/three-consecutive-odds --- #[Trying] issue: Out Of Memory */ class _1553_Minimum_Number_of_Days_to_Eat_N_Oranges { public int minDays(int n) { int[] dp = new int[n + 1]; dp[0] = 0; dp[1] = 1; for (int i = 2; i <= n; i++) { int min = dp[i - 1]; if (i % 2 == 0) { min = Math.min(min, dp[i/2]); } if (i % 3 == 0) { min = Math.min(min, dp[i/3]); } dp[i] = min + 1; } return dp[n]; } }
1,013
0.537019
0.484699
47
20.574469
22.226824
121
false
false
0
0
0
0
0
0
0.595745
false
false
9
62db89736d69193fd0c79d1d02bc94bbddb63e27
10,161,892,633,376
c04ac585cf7799ac06ccb9d1f46ce265b6f847d6
/src/com/company/controleur/Controleur.java
c2cda545eec3f8817873c6e6fa7f5893021c595e
[]
no_license
jbachayani/Burger_King_Desktop
https://github.com/jbachayani/Burger_King_Desktop
224055c1949d5c12233ad5a4b0bd6102e56dda5c
06f9bff148dd6864f861ebe51a5667dd6ffe1784
refs/heads/master
2021-06-05T06:14:46.769000
2016-06-09T15:56:38
2016-06-09T15:56:38
null
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
package com.company.controleur; import com.company.vue.VueConnexion; public class Controleur { public static void main (String args[]) { new VueConnexion(); } }
UTF-8
Java
175
java
Controleur.java
Java
[]
null
[]
package com.company.controleur; import com.company.vue.VueConnexion; public class Controleur { public static void main (String args[]) { new VueConnexion(); } }
175
0.708571
0.708571
11
14.909091
16.334316
42
false
false
0
0
0
0
0
0
0.454545
false
false
9
0fc2464fc0be06c39983fefe3f07c986f21dcec0
23,785,528,928,656
b9fc12a0eb9ee89cea236944eb6c05ca3646df11
/my-web/src/main/java/com/shotgun/my/web/util/newExcel/Excel.java
8833b728b17743cae1c4fdbae2e31194d50144b8
[ "Apache-2.0" ]
permissive
JonSnow592622272/my
https://github.com/JonSnow592622272/my
fdb3f4483f854a78554ca38df8cd837938b0866b
238ceac817e0f4978939b4c21eda324aa1e24b04
refs/heads/master
2021-07-10T18:45:05.332000
2020-12-14T03:14:49
2020-12-14T03:14:49
220,402,748
1
0
null
null
null
null
null
null
null
null
null
null
null
null
null
package com.shotgun.my.web.util.newExcel; import java.io.InputStream; import java.io.OutputStream; /** * @author wulm * @desc **/ public interface Excel { // /** // * 添加sheet表 // */ // <T> Sheet<T> addSheet(String name, List<T> list); /** * @author wulm * @desc 设置导入文件或导出的模板文件 **/ Excel setFile(InputStream inputStream); void getOrCreateSheet(String sheetname); /** * @author wulm * @desc 导出数据 **/ Excel export(OutputStream outputStream); // /** // * @author wulm // * @desc 对wookbook处理并导出数据 // **/ // Excel export(OutputStream outputStream, Consumer<Workbook> consumer) throws IOException; /** * @author wulm * @desc 执行 **/ void execute(); }
UTF-8
Java
821
java
Excel.java
Java
[ { "context": "ream;\nimport java.io.OutputStream;\n\n/**\n * @author wulm\n * @desc\n **/\npublic interface Excel {\n\n// /**", "end": 120, "score": 0.9996145367622375, "start": 116, "tag": "USERNAME", "value": "wulm" }, { "context": "tring name, List<T> list);\n\n /**\n * @author wulm\n * @desc 设置导入文件或导出的模板文件\n **/\n Excel se", "end": 283, "score": 0.9996634125709534, "start": 279, "tag": "USERNAME", "value": "wulm" }, { "context": "teSheet(String sheetname);\n\n /**\n * @author wulm\n * @desc 导出数据\n **/\n Excel export(Outpu", "end": 439, "score": 0.999643862247467, "start": 435, "tag": "USERNAME", "value": "wulm" }, { "context": "tStream outputStream);\n\n// /**\n// * @author wulm\n// * @desc 对wookbook处理并导出数据\n// **/\n// ", "end": 544, "score": 0.9996404647827148, "start": 540, "tag": "USERNAME", "value": "wulm" }, { "context": "sumer) throws IOException;\n\n /**\n * @author wulm\n * @desc 执行\n **/\n void execute();\n}\n", "end": 711, "score": 0.9995667934417725, "start": 707, "tag": "USERNAME", "value": "wulm" } ]
null
[]
package com.shotgun.my.web.util.newExcel; import java.io.InputStream; import java.io.OutputStream; /** * @author wulm * @desc **/ public interface Excel { // /** // * 添加sheet表 // */ // <T> Sheet<T> addSheet(String name, List<T> list); /** * @author wulm * @desc 设置导入文件或导出的模板文件 **/ Excel setFile(InputStream inputStream); void getOrCreateSheet(String sheetname); /** * @author wulm * @desc 导出数据 **/ Excel export(OutputStream outputStream); // /** // * @author wulm // * @desc 对wookbook处理并导出数据 // **/ // Excel export(OutputStream outputStream, Consumer<Workbook> consumer) throws IOException; /** * @author wulm * @desc 执行 **/ void execute(); }
821
0.57971
0.57971
42
17.071428
18.572115
94
false
false
0
0
0
0
0
0
0.261905
false
false
9
052e1028524b6f21de561c220c08ba2f187d35c9
9,045,201,173,311
c181d5385bf397c4d1b46d4b13f3929c7f2282d8
/Fuentes/siapv2-mvn/src/main/java/sv/gob/mined/apps/siapv2/mvn/dao/impl/PgTiposBonosDaoImpl.java
06f8a78313dc50712924eba948cfe40e86750311
[]
no_license
InfoSoftSystem/SIAPWEB-Project
https://github.com/InfoSoftSystem/SIAPWEB-Project
ce92e7bd0d3636cb288b41ee6485d5c447837fcd
eabd9eee692f94a94aed3d353c39f11ca6add70c
refs/heads/master
2021-01-15T10:18:53.824000
2014-05-30T03:52:15
2014-05-30T03:52:15
null
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
/* * To change this template, choose Tools | Templates * and open the template in the editor. */ package sv.gob.mined.apps.siapv2.mvn.dao.impl; import java.util.List; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.jdbc.core.BeanPropertyRowMapper; import org.springframework.jdbc.core.JdbcTemplate; import org.springframework.stereotype.Repository; import sv.gob.mined.apps.siapv2.mvn.dao.PgTiposBonosDao; import sv.gob.mined.apps.siapv2.mvn.modelo.PgTiposBonos; /** * * @author Infosoft */ @Repository public class PgTiposBonosDaoImpl implements PgTiposBonosDao { public PgTiposBonosDaoImpl() { } @Autowired JdbcTemplate jdbcTemplate; public JdbcTemplate getJdbcTemplate() { return jdbcTemplate; } public void setJdbcTemplate(JdbcTemplate jdbcTemplate) { this.jdbcTemplate = jdbcTemplate; } @Override public List<PgTiposBonos> findAll() { String sql = "SELECT * FROM pg_tipos_bonos"; List<PgTiposBonos> pgtiposbonos = getJdbcTemplate().query(sql, new BeanPropertyRowMapper(PgTiposBonos.class)); return pgtiposbonos; } }
UTF-8
Java
1,159
java
PgTiposBonosDaoImpl.java
Java
[ { "context": "siapv2.mvn.modelo.PgTiposBonos;\n\n/**\n *\n * @author Infosoft\n */\n@Repository\npublic class PgTiposBonosDaoImpl ", "end": 536, "score": 0.9994208216667175, "start": 528, "tag": "USERNAME", "value": "Infosoft" } ]
null
[]
/* * To change this template, choose Tools | Templates * and open the template in the editor. */ package sv.gob.mined.apps.siapv2.mvn.dao.impl; import java.util.List; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.jdbc.core.BeanPropertyRowMapper; import org.springframework.jdbc.core.JdbcTemplate; import org.springframework.stereotype.Repository; import sv.gob.mined.apps.siapv2.mvn.dao.PgTiposBonosDao; import sv.gob.mined.apps.siapv2.mvn.modelo.PgTiposBonos; /** * * @author Infosoft */ @Repository public class PgTiposBonosDaoImpl implements PgTiposBonosDao { public PgTiposBonosDaoImpl() { } @Autowired JdbcTemplate jdbcTemplate; public JdbcTemplate getJdbcTemplate() { return jdbcTemplate; } public void setJdbcTemplate(JdbcTemplate jdbcTemplate) { this.jdbcTemplate = jdbcTemplate; } @Override public List<PgTiposBonos> findAll() { String sql = "SELECT * FROM pg_tipos_bonos"; List<PgTiposBonos> pgtiposbonos = getJdbcTemplate().query(sql, new BeanPropertyRowMapper(PgTiposBonos.class)); return pgtiposbonos; } }
1,159
0.739431
0.736842
41
27.268293
26.41325
118
false
false
0
0
0
0
0
0
0.414634
false
false
9
8c90c222f5a3f93624046ae2965fc635282f49e1
20,263,655,765,776
d0a3b9689aa093e28e715281833e83bd2a613699
/arraylist/ArrayListOfStrings.java
502b079e995065f5bd743e4dc2fd757b50c1f2f7
[]
no_license
daanderso/programming-by-doing
https://github.com/daanderso/programming-by-doing
48578fab5f10ecdcfaeec028a5dca88b58734dd1
5529ea842a50d7a811a36cb210e1caeca9bc5a8f
refs/heads/master
2021-01-21T21:14:28.239000
2017-08-27T11:55:19
2017-08-27T11:55:19
92,320,054
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
package arraylist; import java.util.ArrayList; import java.util.Arrays; import java.util.Collections; public class ArrayListOfStrings { public static void main(String[] args) { String sentence = "Ask not what your country can do for you but"; String sentence2 = sentence.toLowerCase(); String[] strValues = sentence2.split(" "); ArrayList<String> sentenceArray = new ArrayList<String>(Arrays.asList(strValues)); Collections.sort(sentenceArray); System.out.println(sentenceArray); } }
UTF-8
Java
513
java
ArrayListOfStrings.java
Java
[]
null
[]
package arraylist; import java.util.ArrayList; import java.util.Arrays; import java.util.Collections; public class ArrayListOfStrings { public static void main(String[] args) { String sentence = "Ask not what your country can do for you but"; String sentence2 = sentence.toLowerCase(); String[] strValues = sentence2.split(" "); ArrayList<String> sentenceArray = new ArrayList<String>(Arrays.asList(strValues)); Collections.sort(sentenceArray); System.out.println(sentenceArray); } }
513
0.738791
0.734893
23
21.304348
23.486231
84
false
false
0
0
0
0
0
0
1.304348
false
false
9
6774dadc7c08d6e96ff43cfdf94736a8aeb69925
31,284,541,847,326
153d4588e75d320b3164d84a3343fbd8c137ac58
/tenacity-core/src/main/java/com/yammer/tenacity/core/resources/TenacityCircuitBreakersResource.java
7da4168b3ac58768f09952ed1fce36ffe7a73864
[ "Apache-2.0" ]
permissive
guilhermejccavalcanti/tenacity
https://github.com/guilhermejccavalcanti/tenacity
8119450ec390dbf5c38abb8dce24aa8450ac6315
8716a550b61beacb112b7101afde3d9400c1b525
refs/heads/master
2020-03-25T05:49:15.801000
2019-02-08T14:37:45
2019-02-08T14:37:45
143,467,265
0
0
Apache-2.0
true
2018-08-03T19:44:25
2018-08-03T19:44:25
2018-06-14T12:52:27
2017-10-12T16:59:39
7,651
0
0
0
null
false
null
package com.yammer.tenacity.core.resources; import com.google.common.collect.ImmutableList; import com.netflix.hystrix.HystrixCircuitBreaker; import com.codahale.metrics.annotation.Timed; import com.yammer.tenacity.core.TenacityCommand; import com.yammer.tenacity.core.core.CircuitBreaker; import com.yammer.tenacity.core.properties.TenacityPropertyKey; import javax.ws.rs.GET; import javax.ws.rs.Path; import javax.ws.rs.Produces; import javax.ws.rs.core.MediaType; import static com.google.common.base.Preconditions.checkNotNull; @Path("/tenacity/circuitbreakers") public class TenacityCircuitBreakersResource { private final Iterable<TenacityPropertyKey> keys; public TenacityCircuitBreakersResource(Iterable<TenacityPropertyKey> keys) { this.keys = checkNotNull(keys); } @GET @Timed @Produces(MediaType.APPLICATION_JSON) public Iterable<CircuitBreaker> circuitBreakers() { final ImmutableList.Builder<CircuitBreaker> circuitBreakerBuilder = ImmutableList.builder(); for (TenacityPropertyKey key : keys) { final HystrixCircuitBreaker circuitBreaker = TenacityCommand.getCircuitBreaker(key); if (circuitBreaker != null) { circuitBreakerBuilder.add(new CircuitBreaker(key, circuitBreaker.isOpen())); } } return circuitBreakerBuilder.build(); } }
UTF-8
Java
1,377
java
TenacityCircuitBreakersResource.java
Java
[]
null
[]
package com.yammer.tenacity.core.resources; import com.google.common.collect.ImmutableList; import com.netflix.hystrix.HystrixCircuitBreaker; import com.codahale.metrics.annotation.Timed; import com.yammer.tenacity.core.TenacityCommand; import com.yammer.tenacity.core.core.CircuitBreaker; import com.yammer.tenacity.core.properties.TenacityPropertyKey; import javax.ws.rs.GET; import javax.ws.rs.Path; import javax.ws.rs.Produces; import javax.ws.rs.core.MediaType; import static com.google.common.base.Preconditions.checkNotNull; @Path("/tenacity/circuitbreakers") public class TenacityCircuitBreakersResource { private final Iterable<TenacityPropertyKey> keys; public TenacityCircuitBreakersResource(Iterable<TenacityPropertyKey> keys) { this.keys = checkNotNull(keys); } @GET @Timed @Produces(MediaType.APPLICATION_JSON) public Iterable<CircuitBreaker> circuitBreakers() { final ImmutableList.Builder<CircuitBreaker> circuitBreakerBuilder = ImmutableList.builder(); for (TenacityPropertyKey key : keys) { final HystrixCircuitBreaker circuitBreaker = TenacityCommand.getCircuitBreaker(key); if (circuitBreaker != null) { circuitBreakerBuilder.add(new CircuitBreaker(key, circuitBreaker.isOpen())); } } return circuitBreakerBuilder.build(); } }
1,377
0.751634
0.751634
38
35.236843
28.141966
100
false
false
0
0
0
0
0
0
0.5
false
false
9
21b6c3d607167cef95706271bf8691dbf57df3ca
23,922,967,886,756
59ba4749455e21d770f0c7e12442480e465d1b36
/src/CS1802/Week5/CLS1_76.MinimumWindowSubstring.java
9ab4735b9302aa0487228c02291b9ffe754307c3
[]
no_license
junj0619/CodeLab
https://github.com/junj0619/CodeLab
b24977e4d96a6bb3aa066f01a8d58e1b8d8d079d
84e52859bc97b1f0e8c5a79e3e05e8c4aa8c4c67
refs/heads/master
2021-06-07T21:45:50.037000
2020-04-14T18:55:17
2020-04-14T18:55:17
93,473,161
1
0
null
null
null
null
null
null
null
null
null
null
null
null
null
class Solution { public String minWindow(String s, String t) { int len = s.length(); int total = 0; int start = 0; int minLen = Integer.MAX_VALUE; HashMap<Character, Integer> map = new HashMap<>(); for(char c : t.toCharArray()) { map.put(c, map.getOrDefault(c, 0) + 1); total++; } for (int low = 0, hi = 0; hi < len; hi++) { char hiChar = s.charAt(hi); if (map.containsKey(hiChar)) { int count = map.get(hiChar) - 1; map.put(hiChar, count); if (count >= 0) { total--; } } while (total == 0) { if (hi - low < minLen) { start = low; minLen = hi - low; } char lowChar = s.charAt(low); if (map.containsKey(lowChar)) { int count = map.get(lowChar) + 1; map.put(lowChar, count); if (count > 0) { total++; } } low++; } } return minLen == Integer.MAX_VALUE ? "" : s.substring(start, start + minLen + 1); } }
UTF-8
Java
1,469
java
CLS1_76.MinimumWindowSubstring.java
Java
[]
null
[]
class Solution { public String minWindow(String s, String t) { int len = s.length(); int total = 0; int start = 0; int minLen = Integer.MAX_VALUE; HashMap<Character, Integer> map = new HashMap<>(); for(char c : t.toCharArray()) { map.put(c, map.getOrDefault(c, 0) + 1); total++; } for (int low = 0, hi = 0; hi < len; hi++) { char hiChar = s.charAt(hi); if (map.containsKey(hiChar)) { int count = map.get(hiChar) - 1; map.put(hiChar, count); if (count >= 0) { total--; } } while (total == 0) { if (hi - low < minLen) { start = low; minLen = hi - low; } char lowChar = s.charAt(low); if (map.containsKey(lowChar)) { int count = map.get(lowChar) + 1; map.put(lowChar, count); if (count > 0) { total++; } } low++; } } return minLen == Integer.MAX_VALUE ? "" : s.substring(start, start + minLen + 1); } }
1,469
0.339006
0.330837
48
29.604166
17.109621
89
false
false
0
0
0
0
0
0
0.604167
false
false
9
bf12b18d672727351bf2da37d8ee0f4500dea0c7
31,318,901,572,336
c964d99746591d296270bb6c8a0b1e2811acc175
/src/interviews/Lowest_Common_Ancester.java
6c8bd3589fa25397bd61d2d29bfcbb3a0250f7cc
[]
no_license
lijing2441/leetcode
https://github.com/lijing2441/leetcode
03c1be2c1faab8bb3742d0a8c5cb4bbda4d52a7f
ae147173105e5a9bd4797d80b15e2d3602779485
refs/heads/master
2021-01-24T17:54:17.609000
2016-02-01T17:18:25
2016-02-01T17:18:25
42,365,288
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
package interviews; public class Lowest_Common_Ancester { // given the root public TreeNode LCA(TreeNode root, TreeNode p, TreeNode q) { if (null == root) return null; if (root == p || root == q) return root; TreeNode left = LCA(root.left, p, q); TreeNode right = LCA(root.right, p, q); // if from both side we can find the LCA, the only common node is root if (left != null && right != null) { return root; } else { //only one side we can find LCA return left == null ? right : left; } } // bst public TreeNode lowestCommonAncestor(TreeNode root, TreeNode p, TreeNode q) { if(root == null || p == null || q == null) { return null; } if ((p.val <= root.val && q.val >= root.val) || (p.val >= root.val && q.val <= root.val)) return root; if (p.val < root.val && q.val < root.val) return lowestCommonAncestor(root.left, p, q); else return lowestCommonAncestor(root.right, p, q); } // given the parent node of each node, O(logn), O(1) public TreeNodeWithP LCA2(TreeNodeWithP p, TreeNodeWithP q) { int d_p = depth(p); int d_q = depth(q); if (d_p > d_q) { for (int i = 0; i < d_p - d_q; i++) { p = p.parent; } } else { for (int i = 0; i < d_q - d_p; i++) { q = q.parent; } } while (p != q) { p = p.parent; q = q.parent; } return p; } public int depth(TreeNodeWithP node) { int height = 0; while (node != null) { node = node.parent; height++; } return height; } }
UTF-8
Java
1,514
java
Lowest_Common_Ancester.java
Java
[]
null
[]
package interviews; public class Lowest_Common_Ancester { // given the root public TreeNode LCA(TreeNode root, TreeNode p, TreeNode q) { if (null == root) return null; if (root == p || root == q) return root; TreeNode left = LCA(root.left, p, q); TreeNode right = LCA(root.right, p, q); // if from both side we can find the LCA, the only common node is root if (left != null && right != null) { return root; } else { //only one side we can find LCA return left == null ? right : left; } } // bst public TreeNode lowestCommonAncestor(TreeNode root, TreeNode p, TreeNode q) { if(root == null || p == null || q == null) { return null; } if ((p.val <= root.val && q.val >= root.val) || (p.val >= root.val && q.val <= root.val)) return root; if (p.val < root.val && q.val < root.val) return lowestCommonAncestor(root.left, p, q); else return lowestCommonAncestor(root.right, p, q); } // given the parent node of each node, O(logn), O(1) public TreeNodeWithP LCA2(TreeNodeWithP p, TreeNodeWithP q) { int d_p = depth(p); int d_q = depth(q); if (d_p > d_q) { for (int i = 0; i < d_p - d_q; i++) { p = p.parent; } } else { for (int i = 0; i < d_q - d_p; i++) { q = q.parent; } } while (p != q) { p = p.parent; q = q.parent; } return p; } public int depth(TreeNodeWithP node) { int height = 0; while (node != null) { node = node.parent; height++; } return height; } }
1,514
0.570674
0.567371
58
25.103449
24.140886
110
false
false
0
0
0
0
0
0
2.534483
false
false
9
e8337314f4368715ea7a8bf667af7447a7967d6d
8,426,725,902,153
301e5bebb11e42862adb0014a862a7d6612b3dd2
/java_prog/DiffHashMapWeakHashMap.java
907ac07c0ad585a3b18eb5a1dc4be858c80f41ca
[]
no_license
sudheertalluri5/My_Java_Programs
https://github.com/sudheertalluri5/My_Java_Programs
5cd00cf3696d0a476348acaad2d725d459d5fc5e
8cefd0240384466adaa02f6794daf358fbcd3094
refs/heads/master
2022-04-17T02:20:03.970000
2020-04-15T18:57:51
2020-04-15T18:57:51
256,006,757
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
import java.util.*; class DiffHashMapWeakHashMap{ public static void main(String ar[]) throws Exception{ HashMap m=new HashMap(); WeakHashMap m1=new WeakHashMap(); Temp t=new Temp(); m.put(t,"it won't disappear"); System.out.println(m); t=null; System.out.println(m); System.gc(); Thread.sleep(1000); t=new Temp(); System.out.println(m); m1.put(t,"it will disappear"); System.out.println(m1); t=null; System.out.println(m1); System.gc(); Thread.sleep(1000); System.out.println(m1); t=new Temp(); m.put("will it",t); t=null; System.out.println(m); System.gc(); Thread.sleep(1000); System.out.println(m); t=new Temp(); m1.put("will it",t); t=null; System.out.println(m1); System.gc(); Thread.sleep(1000); System.out.println(m1); } } class Temp{ public void finalize(){//overriding System.out.println("GC killed Temp"); } }
UTF-8
Java
893
java
DiffHashMapWeakHashMap.java
Java
[]
null
[]
import java.util.*; class DiffHashMapWeakHashMap{ public static void main(String ar[]) throws Exception{ HashMap m=new HashMap(); WeakHashMap m1=new WeakHashMap(); Temp t=new Temp(); m.put(t,"it won't disappear"); System.out.println(m); t=null; System.out.println(m); System.gc(); Thread.sleep(1000); t=new Temp(); System.out.println(m); m1.put(t,"it will disappear"); System.out.println(m1); t=null; System.out.println(m1); System.gc(); Thread.sleep(1000); System.out.println(m1); t=new Temp(); m.put("will it",t); t=null; System.out.println(m); System.gc(); Thread.sleep(1000); System.out.println(m); t=new Temp(); m1.put("will it",t); t=null; System.out.println(m1); System.gc(); Thread.sleep(1000); System.out.println(m1); } } class Temp{ public void finalize(){//overriding System.out.println("GC killed Temp"); } }
893
0.650616
0.62374
43
19.744186
11.037132
55
false
false
0
0
0
0
0
0
2.511628
false
false
9
efc1edad31012b60fca458f533cc205c462f6514
18,665,927,907,077
6b7db7325cba4d01aff4a3d575b98f58d2309b3b
/app/src/main/java/com/spotify/gil/spotifystreamer/player/service/MediaPlayerListener.java
82f013262de1e6361514f8d15fc97e8eafafc28f
[]
no_license
AlexBravo/Spotify_Streamer
https://github.com/AlexBravo/Spotify_Streamer
29ffb631b1fb41f93eb5f397320efbcf1a076284
f81b874a403a2b0306cc798d5388a669c7862099
refs/heads/master
2021-01-21T05:36:17.468000
2015-06-29T16:50:57
2015-06-29T16:50:57
null
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
package com.spotify.gil.spotifystreamer.player.service; import android.media.MediaPlayer; import com.spotify.gil.spotifystreamer.internal.SpotifyArtist; import com.spotify.gil.spotifystreamer.internal.SpotifyTrack; /** * Created by GIL on 18/06/2015 for Spotify Streamer. */ public interface MediaPlayerListener { void onPlayStateChanged(MediaPlayer mp, SpotifyTrack track, SpotifyArtist mArtist); boolean onError(MediaPlayer mp, int what, int extra); void onPrepared(MediaPlayer mp, SpotifyTrack track, SpotifyArtist artist); }
UTF-8
Java
549
java
MediaPlayerListener.java
Java
[ { "context": "streamer.internal.SpotifyTrack;\n\n/**\n * Created by GIL on 18/06/2015 for Spotify Streamer.\n */\npublic in", "end": 239, "score": 0.9584497213363647, "start": 236, "tag": "USERNAME", "value": "GIL" } ]
null
[]
package com.spotify.gil.spotifystreamer.player.service; import android.media.MediaPlayer; import com.spotify.gil.spotifystreamer.internal.SpotifyArtist; import com.spotify.gil.spotifystreamer.internal.SpotifyTrack; /** * Created by GIL on 18/06/2015 for Spotify Streamer. */ public interface MediaPlayerListener { void onPlayStateChanged(MediaPlayer mp, SpotifyTrack track, SpotifyArtist mArtist); boolean onError(MediaPlayer mp, int what, int extra); void onPrepared(MediaPlayer mp, SpotifyTrack track, SpotifyArtist artist); }
549
0.795993
0.781421
18
29.5
30.901726
87
false
false
0
0
0
0
0
0
0.722222
false
false
9
003c2907a7deca2c63cee3791afddc07bf414e0a
23,768,349,040,389
2c1a40e80228db30410370f3b4f2ce04b2f03c01
/serverv2/src/main/java/com/kiwihouse/vo/kiwihouse/GroupAddVo.java
52a0a273ce37085352320c3741809095d2012db3
[]
no_license
SxxGDZB/SxxGDZB-customization
https://github.com/SxxGDZB/SxxGDZB-customization
5bbc6508dae521812d8e72ee7cd4fc8e90b13a16
85873f6033b6c2bd81018d0197aba52566d85a80
refs/heads/master
2023-02-16T23:33:19.442000
2021-01-11T07:16:29
2021-01-11T07:16:29
289,149,752
0
2
null
null
null
null
null
null
null
null
null
null
null
null
null
package com.kiwihouse.vo.kiwihouse; import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import lombok.Getter; import lombok.Setter; import lombok.ToString; /** * @author yjzn * @date 2020-3-5 16:12:11 */ @ToString @Getter @Setter @ApiModel(description = "添加分组参数") public class GroupAddVo { @ApiModelProperty(name = "分组名称(不允许重复)",value = "groupName") private String groupName; @ApiModelProperty(hidden = true) private String roleId; @ApiModelProperty(hidden = true) private String cron; @ApiModelProperty(hidden = true) private String groupId; @ApiModelProperty(hidden = true) private String addTime; }
UTF-8
Java
715
java
GroupAddVo.java
Java
[ { "context": "ok.Setter;\nimport lombok.ToString;\n\n/**\n * @author yjzn\n * @date 2020-3-5 16:12:11\n */\n@ToString\n@Getter\n", "end": 213, "score": 0.999715268611908, "start": 209, "tag": "USERNAME", "value": "yjzn" } ]
null
[]
package com.kiwihouse.vo.kiwihouse; import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import lombok.Getter; import lombok.Setter; import lombok.ToString; /** * @author yjzn * @date 2020-3-5 16:12:11 */ @ToString @Getter @Setter @ApiModel(description = "添加分组参数") public class GroupAddVo { @ApiModelProperty(name = "分组名称(不允许重复)",value = "groupName") private String groupName; @ApiModelProperty(hidden = true) private String roleId; @ApiModelProperty(hidden = true) private String cron; @ApiModelProperty(hidden = true) private String groupId; @ApiModelProperty(hidden = true) private String addTime; }
715
0.728467
0.710949
30
21.833334
15.897763
63
false
false
0
0
0
0
0
0
0.4
false
false
9
5f7d06782f00c8de3e83d46094c315b568f74502
35,235,911,703,349
6ed482a6b3c9716f585d04b965a75964c8efd35d
/java/l2trunk/scripts/ai/GuardianAltar.java
173c752644587bc59b5f67cad12a898d6fed983a
[]
no_license
VitaliiBashta/Trunk
https://github.com/VitaliiBashta/Trunk
0796d1be73f0ced917fd3ebf725403f30ebb6a84
9f58afca0deb4e6f69fc89e3b47b5fc02d2a31e9
refs/heads/master
2021-10-24T20:56:55.327000
2019-03-28T15:36:37
2019-03-28T15:36:37
155,664,256
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
package l2trunk.scripts.ai; import l2trunk.commons.util.Rnd; import l2trunk.gameserver.ai.CtrlEvent; import l2trunk.gameserver.ai.DefaultAI; import l2trunk.gameserver.model.Creature; import l2trunk.gameserver.model.Player; import l2trunk.gameserver.model.SimpleSpawner; import l2trunk.gameserver.model.Summon; import l2trunk.gameserver.model.instances.NpcInstance; import l2trunk.gameserver.model.instances.PetInstance; import l2trunk.gameserver.model.instances.SummonInstance; import l2trunk.gameserver.scripts.Functions; import l2trunk.gameserver.utils.Location; /** * AI 18811 Guardian of the Altar - Спавит рандомных охранников если атакован * - если у игрока есть Protection Souls Pendant 14848 - спавнит мини-рб * - не использует random walk * - не отвечает на атаки */ public final class GuardianAltar extends DefaultAI { private static final int DarkShamanVarangka = 18808; public GuardianAltar(NpcInstance actor) { super(actor); actor.setInvul(true); } @Override public void onEvtAttacked(Creature attacker, int damage) { NpcInstance actor = getActor(); if (attacker == null) return; Player player = attacker.getPlayer(); if (Rnd.chance(40) && player.getInventory().destroyItemByItemId(14848, "GuardianAltar")) { if (actor.getAroundNpc(1500, 300) .filter(npc -> npc.getNpcId() == 18808) .peek(npc -> Functions.npcSay(actor, "I can sense the presence of Dark Shaman already!")) .findFirst().isPresent()) return; SimpleSpawner sp = new SimpleSpawner(DarkShamanVarangka); sp.setLoc(Location.findPointToStay(actor, 400, 420)); NpcInstance npc = sp.doSpawn(true); if (attacker instanceof Summon) npc.getAI().notifyEvent(CtrlEvent.EVT_AGGRESSION, attacker, Rnd.get(2, 100)); npc.getAI().notifyEvent(CtrlEvent.EVT_AGGRESSION, attacker.getPlayer(), Rnd.get(1, 100)); } else if (Rnd.chance(5)) { if (actor.getAroundNpc(1000, 300) .anyMatch(npc -> npc.getNpcId() == 22702)) return; for (int i = 0; i < 2; i++) { SimpleSpawner sp = new SimpleSpawner(22702); sp.setLoc(Location.findPointToStay(actor, 150, 160)); NpcInstance npc = sp.doSpawn(true); if (attacker instanceof Summon) npc.getAI().notifyEvent(CtrlEvent.EVT_AGGRESSION, attacker, Rnd.get(2, 100)); npc.getAI().notifyEvent(CtrlEvent.EVT_AGGRESSION, attacker.getPlayer(), Rnd.get(1, 100)); } } } @Override public boolean randomWalk() { return false; } }
UTF-8
Java
2,876
java
GuardianAltar.java
Java
[]
null
[]
package l2trunk.scripts.ai; import l2trunk.commons.util.Rnd; import l2trunk.gameserver.ai.CtrlEvent; import l2trunk.gameserver.ai.DefaultAI; import l2trunk.gameserver.model.Creature; import l2trunk.gameserver.model.Player; import l2trunk.gameserver.model.SimpleSpawner; import l2trunk.gameserver.model.Summon; import l2trunk.gameserver.model.instances.NpcInstance; import l2trunk.gameserver.model.instances.PetInstance; import l2trunk.gameserver.model.instances.SummonInstance; import l2trunk.gameserver.scripts.Functions; import l2trunk.gameserver.utils.Location; /** * AI 18811 Guardian of the Altar - Спавит рандомных охранников если атакован * - если у игрока есть Protection Souls Pendant 14848 - спавнит мини-рб * - не использует random walk * - не отвечает на атаки */ public final class GuardianAltar extends DefaultAI { private static final int DarkShamanVarangka = 18808; public GuardianAltar(NpcInstance actor) { super(actor); actor.setInvul(true); } @Override public void onEvtAttacked(Creature attacker, int damage) { NpcInstance actor = getActor(); if (attacker == null) return; Player player = attacker.getPlayer(); if (Rnd.chance(40) && player.getInventory().destroyItemByItemId(14848, "GuardianAltar")) { if (actor.getAroundNpc(1500, 300) .filter(npc -> npc.getNpcId() == 18808) .peek(npc -> Functions.npcSay(actor, "I can sense the presence of Dark Shaman already!")) .findFirst().isPresent()) return; SimpleSpawner sp = new SimpleSpawner(DarkShamanVarangka); sp.setLoc(Location.findPointToStay(actor, 400, 420)); NpcInstance npc = sp.doSpawn(true); if (attacker instanceof Summon) npc.getAI().notifyEvent(CtrlEvent.EVT_AGGRESSION, attacker, Rnd.get(2, 100)); npc.getAI().notifyEvent(CtrlEvent.EVT_AGGRESSION, attacker.getPlayer(), Rnd.get(1, 100)); } else if (Rnd.chance(5)) { if (actor.getAroundNpc(1000, 300) .anyMatch(npc -> npc.getNpcId() == 22702)) return; for (int i = 0; i < 2; i++) { SimpleSpawner sp = new SimpleSpawner(22702); sp.setLoc(Location.findPointToStay(actor, 150, 160)); NpcInstance npc = sp.doSpawn(true); if (attacker instanceof Summon) npc.getAI().notifyEvent(CtrlEvent.EVT_AGGRESSION, attacker, Rnd.get(2, 100)); npc.getAI().notifyEvent(CtrlEvent.EVT_AGGRESSION, attacker.getPlayer(), Rnd.get(1, 100)); } } } @Override public boolean randomWalk() { return false; } }
2,876
0.642344
0.608196
73
37.123287
28.874289
109
false
false
0
0
0
0
0
0
0.767123
false
false
9
1238cd8ce51b49aebab2a9c863ece112a9de4bcf
27,084,063,792,827
0f12b8d94bb748ad6e4a4969a487d41a67756732
/halyard-deploy/src/main/java/com/netflix/spinnaker/halyard/deploy/spinnaker/v1/profile/deck/PluginManifestProfileFactory.java
0a114b646efdbcf97887c1d1471250d8c8cf0e10
[ "Apache-2.0" ]
permissive
Jaskaranbir/halyard
https://github.com/Jaskaranbir/halyard
da138988a409e44886a5013494cf1fbfefcb23cf
fa89dcddb4b41d4b4c3ecb8765a19940eef1eafd
refs/heads/master
2021-02-13T06:40:47.581000
2020-03-02T19:38:24
2020-03-02T19:38:24
244,671,359
1
0
Apache-2.0
true
2020-03-03T15:25:16
2020-03-03T15:25:15
2020-03-02T19:38:28
2020-03-03T04:27:00
7,026
0
0
0
null
false
false
package com.netflix.spinnaker.halyard.deploy.spinnaker.v1.profile.deck; import com.netflix.spinnaker.halyard.config.model.v1.node.DeploymentConfiguration; import com.netflix.spinnaker.halyard.config.model.v1.plugins.Plugin; import com.netflix.spinnaker.halyard.config.services.v1.PluginService; import com.netflix.spinnaker.halyard.deploy.spinnaker.v1.SpinnakerArtifact; import com.netflix.spinnaker.halyard.deploy.spinnaker.v1.SpinnakerRuntimeSettings; import com.netflix.spinnaker.halyard.deploy.spinnaker.v1.profile.Profile; import com.netflix.spinnaker.halyard.deploy.spinnaker.v1.profile.StringBackedProfileFactory; import java.util.Map; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Component; @Component public class PluginManifestProfileFactory extends StringBackedProfileFactory { @Autowired PluginService pluginService; private static String PLUGIN_ENTRY = "{id: \"%s\", version: \"%s\", url: \"%s\"}"; @Override protected void setProfile( Profile profile, DeploymentConfiguration deploymentConfiguration, SpinnakerRuntimeSettings endpoints) { profile.appendContents("plugins = ["); Map<String, Plugin> plugins = pluginService.getPlugins(deploymentConfiguration.getName()); plugins.entrySet().stream() .filter( v -> { Plugin p = v.getValue(); return p.getEnabled() && p.getUiResourceLocation() != null && p.getUiResourceLocation() != ""; }) .forEach( v -> { Plugin p = v.getValue(); profile.appendContents( String.format( PLUGIN_ENTRY, p.getId(), p.getVersion(), p.getUiResourceLocation())); }); profile.appendContents("]"); } @Override protected String getRawBaseProfile() { return ""; } @Override public SpinnakerArtifact getArtifact() { return SpinnakerArtifact.DECK; } @Override protected String commentPrefix() { return "// "; } }
UTF-8
Java
2,079
java
PluginManifestProfileFactory.java
Java
[]
null
[]
package com.netflix.spinnaker.halyard.deploy.spinnaker.v1.profile.deck; import com.netflix.spinnaker.halyard.config.model.v1.node.DeploymentConfiguration; import com.netflix.spinnaker.halyard.config.model.v1.plugins.Plugin; import com.netflix.spinnaker.halyard.config.services.v1.PluginService; import com.netflix.spinnaker.halyard.deploy.spinnaker.v1.SpinnakerArtifact; import com.netflix.spinnaker.halyard.deploy.spinnaker.v1.SpinnakerRuntimeSettings; import com.netflix.spinnaker.halyard.deploy.spinnaker.v1.profile.Profile; import com.netflix.spinnaker.halyard.deploy.spinnaker.v1.profile.StringBackedProfileFactory; import java.util.Map; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Component; @Component public class PluginManifestProfileFactory extends StringBackedProfileFactory { @Autowired PluginService pluginService; private static String PLUGIN_ENTRY = "{id: \"%s\", version: \"%s\", url: \"%s\"}"; @Override protected void setProfile( Profile profile, DeploymentConfiguration deploymentConfiguration, SpinnakerRuntimeSettings endpoints) { profile.appendContents("plugins = ["); Map<String, Plugin> plugins = pluginService.getPlugins(deploymentConfiguration.getName()); plugins.entrySet().stream() .filter( v -> { Plugin p = v.getValue(); return p.getEnabled() && p.getUiResourceLocation() != null && p.getUiResourceLocation() != ""; }) .forEach( v -> { Plugin p = v.getValue(); profile.appendContents( String.format( PLUGIN_ENTRY, p.getId(), p.getVersion(), p.getUiResourceLocation())); }); profile.appendContents("]"); } @Override protected String getRawBaseProfile() { return ""; } @Override public SpinnakerArtifact getArtifact() { return SpinnakerArtifact.DECK; } @Override protected String commentPrefix() { return "// "; } }
2,079
0.689274
0.685426
60
33.650002
28.451025
94
false
false
0
0
0
0
0
0
0.533333
false
false
9
2ebbbd770529e1637de92e94919b633201305f54
11,948,599,036,978
0d30cb72126cfcd1ea747c7af74dc04306ac0510
/Codes/Data Structure/src/main/java/com/XRewrite/bean/impl/Literal.java
d8bd83c8fd216825b8d83bdba25c9ca64c0503a1
[]
no_license
CheungVane/XRewrite
https://github.com/CheungVane/XRewrite
37a51add1072114f8e05880dbd0390043dfd37e2
5bc816422777aa4ffc3fa9ba85917f9c0045068e
refs/heads/main
2023-07-03T07:39:35.465000
2021-08-11T02:14:15
2021-08-11T02:14:15
392,864,769
0
0
null
false
2021-08-11T02:14:15
2021-08-05T01:09:16
2021-08-06T00:18:00
2021-08-11T02:14:15
6,960
0
0
0
Java
false
false
package com.XRewrite.bean.impl; import com.XRewrite.bean.IAtom; import com.XRewrite.bean.ILiteral; import org.apache.commons.lang3.builder.HashCodeBuilder; import java.io.Serializable; public class Literal implements ILiteral, Serializable { private final boolean positive; private final IAtom atom; Literal(final IAtom atom) { this(true, atom); } Literal(final boolean positive, final IAtom atom) { this.atom = atom; this.positive = positive; } public boolean isPositive() { return positive; } public IAtom getAtom() { return atom; } public int compareTo(final ILiteral oo) { ILiteral o = (ILiteral) oo; if ((positive != o.isPositive()) && positive) { return 1; } else if ((positive != o.isPositive()) && !positive) { return -1; } return atom.compareTo(o.getAtom()); } @Override public int hashCode() { return new HashCodeBuilder(19, 83).append(atom).append(positive).toHashCode(); } public boolean equals(final Object o) { if (o == this) { return true; } if (!(o instanceof Literal)) { return false; } Literal l = (Literal) o; return atom.equals(l.atom) && (positive == l.positive); } public String toString() { return (positive ? "" : "!") + atom; } }
UTF-8
Java
1,240
java
Literal.java
Java
[]
null
[]
package com.XRewrite.bean.impl; import com.XRewrite.bean.IAtom; import com.XRewrite.bean.ILiteral; import org.apache.commons.lang3.builder.HashCodeBuilder; import java.io.Serializable; public class Literal implements ILiteral, Serializable { private final boolean positive; private final IAtom atom; Literal(final IAtom atom) { this(true, atom); } Literal(final boolean positive, final IAtom atom) { this.atom = atom; this.positive = positive; } public boolean isPositive() { return positive; } public IAtom getAtom() { return atom; } public int compareTo(final ILiteral oo) { ILiteral o = (ILiteral) oo; if ((positive != o.isPositive()) && positive) { return 1; } else if ((positive != o.isPositive()) && !positive) { return -1; } return atom.compareTo(o.getAtom()); } @Override public int hashCode() { return new HashCodeBuilder(19, 83).append(atom).append(positive).toHashCode(); } public boolean equals(final Object o) { if (o == this) { return true; } if (!(o instanceof Literal)) { return false; } Literal l = (Literal) o; return atom.equals(l.atom) && (positive == l.positive); } public String toString() { return (positive ? "" : "!") + atom; } }
1,240
0.672581
0.666936
61
19.311476
19.279261
80
false
false
0
0
0
0
0
0
1.590164
false
false
9
2f485c25ec69bfed7666dabd5edf4431b379bc49
15,101,105,031,977
6ad6d0909f458e6660793e50c49c072aaaa56c89
/stan-seckill-api/src/main/java/com/stan/seckill/mq/MQSendService.java
f24d4795b59fa1453920c55755baa10116d7f819
[]
no_license
sidanchen/stan-seckill
https://github.com/sidanchen/stan-seckill
8fb6222f5baced90505389967e51801b778d8212
9af9bc8ab0877dd209ab932f369cb78e3a9870bf
refs/heads/master
2020-05-05T07:21:37.349000
2019-05-05T09:35:00
2019-05-05T09:35:00
179,822,206
1
0
null
null
null
null
null
null
null
null
null
null
null
null
null
package com.stan.seckill.mq; import com.stan.config.mqconfig.QueueConfig; import com.stan.seckill.redis.RedisService; import org.springframework.amqp.core.AmqpTemplate; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; /** * Created by sdc on 2019/4/21. */ @Service public class MQSendService { @Autowired AmqpTemplate amqpTemplate; public void send(SeckillMessage seckillMessage){ String seckillMessageString = RedisService.beanToString(seckillMessage); amqpTemplate.convertAndSend(QueueConfig.SCKILL_QUEUE,seckillMessageString); } }
UTF-8
Java
633
java
MQSendService.java
Java
[ { "context": "ngframework.stereotype.Service;\n\n/**\n * Created by sdc on 2019/4/21.\n */\n@Service\npublic class MQSendSer", "end": 302, "score": 0.9991974830627441, "start": 299, "tag": "USERNAME", "value": "sdc" } ]
null
[]
package com.stan.seckill.mq; import com.stan.config.mqconfig.QueueConfig; import com.stan.seckill.redis.RedisService; import org.springframework.amqp.core.AmqpTemplate; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; /** * Created by sdc on 2019/4/21. */ @Service public class MQSendService { @Autowired AmqpTemplate amqpTemplate; public void send(SeckillMessage seckillMessage){ String seckillMessageString = RedisService.beanToString(seckillMessage); amqpTemplate.convertAndSend(QueueConfig.SCKILL_QUEUE,seckillMessageString); } }
633
0.78515
0.774092
22
27.772728
26.11327
83
false
false
0
0
0
0
0
0
0.454545
false
false
9
d7d8ce0a9e58c2bc2ce2393f56ca91015179061c
27,728,308,900,797
8c6f3e178633dd7f081c1500389807cfe3089412
/Chapter8PC5/src/FinalExam.java
d41b95068b57c90be2861d0709fa4185e3250065
[]
no_license
ralphorteza/FANBOYS
https://github.com/ralphorteza/FANBOYS
7ad447e0c5634fc21c66eaf1b7843349fe0c5ae2
558a049b38b91f2e2b52731b63206275353dea42
refs/heads/master
2020-03-31T18:25:03.875000
2019-08-16T20:26:52
2019-08-16T20:26:52
152,458,373
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
public class FinalExam extends GradedActivity{ private int numQuestions; private double pointsEach; private int numMissed; public FinalExam (int questions, int missed) { double numericScore, tempScore; numQuestions = questions; numMissed = missed; pointsEach = 100.0/ questions; tempScore = 100.0 -(missed * pointsEach); numericScore = round(tempScore,2); //call the inherited setScore method to set //numericScore setScore(numericScore); } /** * getPointsEach returns amount of points per question * @return pointsEach */ public double getPointsEach() { return pointsEach; } /** * getNumMissed retrieves the amount of questions missed * @return numMissed */ public int getNumMissed() { return numMissed; } public static double round(double value, int places) { if (places < 0) throw new IllegalArgumentException(); long factor = (long) Math.pow(10, places); value = value * factor; long tmp = Math.round(value); return (double) tmp / factor; } }
UTF-8
Java
1,207
java
FinalExam.java
Java
[]
null
[]
public class FinalExam extends GradedActivity{ private int numQuestions; private double pointsEach; private int numMissed; public FinalExam (int questions, int missed) { double numericScore, tempScore; numQuestions = questions; numMissed = missed; pointsEach = 100.0/ questions; tempScore = 100.0 -(missed * pointsEach); numericScore = round(tempScore,2); //call the inherited setScore method to set //numericScore setScore(numericScore); } /** * getPointsEach returns amount of points per question * @return pointsEach */ public double getPointsEach() { return pointsEach; } /** * getNumMissed retrieves the amount of questions missed * @return numMissed */ public int getNumMissed() { return numMissed; } public static double round(double value, int places) { if (places < 0) throw new IllegalArgumentException(); long factor = (long) Math.pow(10, places); value = value * factor; long tmp = Math.round(value); return (double) tmp / factor; } }
1,207
0.597349
0.587407
47
24.659575
18.008598
60
false
false
0
0
0
0
0
0
0.468085
false
false
9
d228f456611c7fb94664ec7e776b703162ae69df
14,216,341,814,707
8e9824382cae0c95a7622ec06025a52a7d2e0df8
/src/ubic/basecode/ontology/jena/JenaUtils.java
3c3f10654a33199dbfec18a4f183509c05b07d3b
[ "Apache-2.0" ]
permissive
PavlidisLab/baseCode
https://github.com/PavlidisLab/baseCode
a61a301ecc76323c77b6bc914cda548327a62e99
6aaf59439818bca54bb74ed0c67a97a38d7008de
refs/heads/development
2023-07-20T05:03:46.760000
2023-07-05T18:39:07
2023-07-05T18:43:43
51,547,648
3
0
Apache-2.0
false
2023-06-28T19:30:40
2016-02-11T21:17:22
2023-03-30T03:17:55
2023-06-28T19:30:37
34,750
5
0
4
Java
false
false
package ubic.basecode.ontology.jena; import com.hp.hpl.jena.ontology.OntClass; import com.hp.hpl.jena.ontology.OntModel; import com.hp.hpl.jena.ontology.Restriction; import com.hp.hpl.jena.rdf.model.*; import com.hp.hpl.jena.util.iterator.ExtendedIterator; import com.hp.hpl.jena.util.iterator.Filter; import com.hp.hpl.jena.util.iterator.UniqueExtendedIterator; import org.apache.commons.lang3.time.StopWatch; import javax.annotation.Nullable; import java.util.*; import java.util.function.Predicate; import java.util.stream.Collectors; import static com.hp.hpl.jena.reasoner.ReasonerRegistry.makeDirect; class JenaUtils { public static Collection<OntClass> getParents( OntModel model, Collection<OntClass> ontClasses, boolean direct, @Nullable Set<Restriction> additionalRestrictions ) { ontClasses = ontClasses.stream() .map( t -> t.inModel( model ) ) .filter( t -> t.canAs( OntClass.class ) ) .map( t -> t.as( OntClass.class ) ) .collect( Collectors.toList() ); if ( ontClasses.isEmpty() ) { return Collections.emptySet(); } Iterator<OntClass> it = ontClasses.iterator(); ExtendedIterator<OntClass> iterator = it.next().listSuperClasses( direct ); while ( it.hasNext() ) { iterator = iterator.andThen( it.next().listSuperClasses( direct ) ); } Collection<OntClass> result = new HashSet<>(); while ( iterator.hasNext() ) { OntClass c = iterator.next(); // handles part of some {parent container} or part of all {parent container} if ( additionalRestrictions != null && !additionalRestrictions.isEmpty() && c.isRestriction() ) { Restriction r = c.asRestriction(); if ( additionalRestrictions.contains( r ) ) { Resource value = getRestrictionValue( r ); if ( value instanceof OntClass ) { c = ( OntClass ) value; } else { continue; } } } // bnode if ( c.getURI() == null ) continue; // owl:Thing if ( c.equals( model.getProfile().THING() ) ) continue; result.add( c ); } return result; } public static Collection<OntClass> getChildren( OntModel model, Collection<OntClass> terms, boolean direct, @Nullable Set<Restriction> additionalRestrictions ) { terms = terms.stream() .map( t -> t.inModel( model ) ) .filter( t -> t.canAs( OntClass.class ) ) .map( t -> t.as( OntClass.class ) ) .collect( Collectors.toList() ); if ( terms.isEmpty() ) { return Collections.emptySet(); } StopWatch timer = StopWatch.createStarted(); Iterator<OntClass> it = terms.iterator(); ExtendedIterator<OntClass> iterator = it.next().listSubClasses( direct ); while ( it.hasNext() ) { iterator = iterator.andThen( it.next().listSubClasses( direct ) ); } Set<OntClass> result = iterator .filterDrop( new BnodeFilter<>() ) .filterDrop( new PredicateFilter<>( o -> o.equals( model.getProfile().NOTHING() ) ) ) .toSet(); if ( additionalRestrictions != null && !additionalRestrictions.isEmpty() ) { timer.reset(); timer.start(); Property subClassOf = model.getProfile().SUB_CLASS_OF(); if ( direct ) { subClassOf = ResourceFactory.createProperty( makeDirect( subClassOf.getURI() ) ); } Set<Restriction> restrictions = UniqueExtendedIterator.create( additionalRestrictions.iterator() ) .filterKeep( new RestrictionWithValuesFromFilter( terms ) ) .toSet(); for ( Restriction r : restrictions ) { result.addAll( model.listResourcesWithProperty( subClassOf, r ) .filterDrop( new BnodeFilter<>() ) .mapWith( r2 -> r2.as( OntClass.class ) ) .toSet() ); } } return result; } public static Resource getRestrictionValue( Restriction r ) { if ( r.isSomeValuesFromRestriction() ) { return r.asSomeValuesFromRestriction().getSomeValuesFrom(); } else if ( r.isAllValuesFromRestriction() ) { return r.asAllValuesFromRestriction().getAllValuesFrom(); } else { return null; } } /** * Use to pretty-print a RDFNode */ public static String asString( RDFNode object ) { return ( String ) object.visitWith( new RDFVisitor() { @Override public Object visitBlank( Resource r, AnonId id ) { return r.getLocalName(); } @Override public Object visitLiteral( Literal l ) { return l.toString().replaceAll( "\\^\\^.+", "" ); } @Override public Object visitURI( Resource r, String uri ) { return r.getLocalName(); } } ); } public static <T> Filter<T> where( Predicate<T> predicate ) { return new PredicateFilter<>( predicate ); } }
UTF-8
Java
5,459
java
JenaUtils.java
Java
[]
null
[]
package ubic.basecode.ontology.jena; import com.hp.hpl.jena.ontology.OntClass; import com.hp.hpl.jena.ontology.OntModel; import com.hp.hpl.jena.ontology.Restriction; import com.hp.hpl.jena.rdf.model.*; import com.hp.hpl.jena.util.iterator.ExtendedIterator; import com.hp.hpl.jena.util.iterator.Filter; import com.hp.hpl.jena.util.iterator.UniqueExtendedIterator; import org.apache.commons.lang3.time.StopWatch; import javax.annotation.Nullable; import java.util.*; import java.util.function.Predicate; import java.util.stream.Collectors; import static com.hp.hpl.jena.reasoner.ReasonerRegistry.makeDirect; class JenaUtils { public static Collection<OntClass> getParents( OntModel model, Collection<OntClass> ontClasses, boolean direct, @Nullable Set<Restriction> additionalRestrictions ) { ontClasses = ontClasses.stream() .map( t -> t.inModel( model ) ) .filter( t -> t.canAs( OntClass.class ) ) .map( t -> t.as( OntClass.class ) ) .collect( Collectors.toList() ); if ( ontClasses.isEmpty() ) { return Collections.emptySet(); } Iterator<OntClass> it = ontClasses.iterator(); ExtendedIterator<OntClass> iterator = it.next().listSuperClasses( direct ); while ( it.hasNext() ) { iterator = iterator.andThen( it.next().listSuperClasses( direct ) ); } Collection<OntClass> result = new HashSet<>(); while ( iterator.hasNext() ) { OntClass c = iterator.next(); // handles part of some {parent container} or part of all {parent container} if ( additionalRestrictions != null && !additionalRestrictions.isEmpty() && c.isRestriction() ) { Restriction r = c.asRestriction(); if ( additionalRestrictions.contains( r ) ) { Resource value = getRestrictionValue( r ); if ( value instanceof OntClass ) { c = ( OntClass ) value; } else { continue; } } } // bnode if ( c.getURI() == null ) continue; // owl:Thing if ( c.equals( model.getProfile().THING() ) ) continue; result.add( c ); } return result; } public static Collection<OntClass> getChildren( OntModel model, Collection<OntClass> terms, boolean direct, @Nullable Set<Restriction> additionalRestrictions ) { terms = terms.stream() .map( t -> t.inModel( model ) ) .filter( t -> t.canAs( OntClass.class ) ) .map( t -> t.as( OntClass.class ) ) .collect( Collectors.toList() ); if ( terms.isEmpty() ) { return Collections.emptySet(); } StopWatch timer = StopWatch.createStarted(); Iterator<OntClass> it = terms.iterator(); ExtendedIterator<OntClass> iterator = it.next().listSubClasses( direct ); while ( it.hasNext() ) { iterator = iterator.andThen( it.next().listSubClasses( direct ) ); } Set<OntClass> result = iterator .filterDrop( new BnodeFilter<>() ) .filterDrop( new PredicateFilter<>( o -> o.equals( model.getProfile().NOTHING() ) ) ) .toSet(); if ( additionalRestrictions != null && !additionalRestrictions.isEmpty() ) { timer.reset(); timer.start(); Property subClassOf = model.getProfile().SUB_CLASS_OF(); if ( direct ) { subClassOf = ResourceFactory.createProperty( makeDirect( subClassOf.getURI() ) ); } Set<Restriction> restrictions = UniqueExtendedIterator.create( additionalRestrictions.iterator() ) .filterKeep( new RestrictionWithValuesFromFilter( terms ) ) .toSet(); for ( Restriction r : restrictions ) { result.addAll( model.listResourcesWithProperty( subClassOf, r ) .filterDrop( new BnodeFilter<>() ) .mapWith( r2 -> r2.as( OntClass.class ) ) .toSet() ); } } return result; } public static Resource getRestrictionValue( Restriction r ) { if ( r.isSomeValuesFromRestriction() ) { return r.asSomeValuesFromRestriction().getSomeValuesFrom(); } else if ( r.isAllValuesFromRestriction() ) { return r.asAllValuesFromRestriction().getAllValuesFrom(); } else { return null; } } /** * Use to pretty-print a RDFNode */ public static String asString( RDFNode object ) { return ( String ) object.visitWith( new RDFVisitor() { @Override public Object visitBlank( Resource r, AnonId id ) { return r.getLocalName(); } @Override public Object visitLiteral( Literal l ) { return l.toString().replaceAll( "\\^\\^.+", "" ); } @Override public Object visitURI( Resource r, String uri ) { return r.getLocalName(); } } ); } public static <T> Filter<T> where( Predicate<T> predicate ) { return new PredicateFilter<>( predicate ); } }
5,459
0.561275
0.560725
143
37.174824
30.545692
169
false
false
0
0
0
0
0
0
0.426573
false
false
9
7d3f2a607dbcc3f9a2468407fa07933af8733c00
15,384,572,918,349
a0d92f5974795085c558534f98b665adb946a965
/Alph_Beta_Pruning/Simple_Alpha_Beta/simple_alpha_beta.java
eee361a3b8461c8765395434b6a61229cfc0b547
[]
no_license
AartiBhagtani/AI-Algorithms
https://github.com/AartiBhagtani/AI-Algorithms
4091e21e5ea3d9825714213bfecf35485159e968
478e82c3d51d6cabdceb5bad835339dfbe44af61
refs/heads/master
2020-03-29T16:51:32.256000
2018-10-18T16:34:32
2018-10-18T16:34:32
150,130,760
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
import java.util.*; class simple_alpha_beta{ static int max = 1000; static int min = -1000; static int minmax(int depth, int nodeIndex, boolean maxPlayer, int values[], int alpha, int beta) { int best; if(depth == 3) { return values[nodeIndex]; } if(maxPlayer) { best = min; // recur for left and right child for(int i=0; i<2; i++) { int val = minmax(depth+1, nodeIndex*2 + i, false, values, alpha, beta); best = Math.max(best, val); alpha = Math.max(best, alpha); if(alpha>=beta) { break; } } } else { best = max; // recur for left and right child for(int i=0; i<2; i++) { int val = minmax(depth+1, nodeIndex*2 + i, true, values, alpha, beta); best = Math.min(best, val); beta = Math.min(best, beta); if(alpha>=beta) { break; } } } return best; } public static void main(String args[]) { int values[] = {3,5,6,9,1,2,0,-1}; System.out.println("optimal value : "+minmax(0,0,true,values, min, max)); } }
UTF-8
Java
1,035
java
simple_alpha_beta.java
Java
[]
null
[]
import java.util.*; class simple_alpha_beta{ static int max = 1000; static int min = -1000; static int minmax(int depth, int nodeIndex, boolean maxPlayer, int values[], int alpha, int beta) { int best; if(depth == 3) { return values[nodeIndex]; } if(maxPlayer) { best = min; // recur for left and right child for(int i=0; i<2; i++) { int val = minmax(depth+1, nodeIndex*2 + i, false, values, alpha, beta); best = Math.max(best, val); alpha = Math.max(best, alpha); if(alpha>=beta) { break; } } } else { best = max; // recur for left and right child for(int i=0; i<2; i++) { int val = minmax(depth+1, nodeIndex*2 + i, true, values, alpha, beta); best = Math.min(best, val); beta = Math.min(best, beta); if(alpha>=beta) { break; } } } return best; } public static void main(String args[]) { int values[] = {3,5,6,9,1,2,0,-1}; System.out.println("optimal value : "+minmax(0,0,true,values, min, max)); } }
1,035
0.571981
0.545894
55
17.836363
21.289146
98
false
false
0
0
0
0
0
0
3.272727
false
false
9
78670b7c2c2b1cea142c00dc02d35fd0a22f67d3
32,658,931,384,582
3f976fee8af57e7dab92bc34a778c4f12be1698b
/src/main/java/gr/blackswamp/awesorm/EncryptedDatabase.java
45bceabed0fc5135c9d278b844201d3501e01fd6
[ "Apache-2.0" ]
permissive
Nekrull/Awesorm
https://github.com/Nekrull/Awesorm
5011c8dcefbca824e3fad25f8636141d60f1d920
89111119fd63428ebd15395138cf42daf4e6d26b
refs/heads/master
2018-10-16T17:15:10.768000
2018-08-21T07:21:56
2018-08-21T07:21:56
140,695,341
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
package gr.blackswamp.awesorm; import android.content.Context; import android.database.Cursor; import net.sqlcipher.database.SQLiteDatabase; import net.sqlcipher.database.SQLiteOpenHelper; class EncryptedDatabase extends SQLiteOpenHelper implements IDBConnection { private final String _password; public EncryptedDatabase(Context context, String name, String password) { super(context, name, null, 1); _password = password; } @Override public void onCreate(SQLiteDatabase sqLiteDatabase) { } @Override public void onUpgrade(SQLiteDatabase sqLiteDatabase, int oldVersion, int newVersion) { } @Override public Cursor rawQuery(boolean writeable, String sql, String[] selectionArgs) { return get_database(writeable).rawQuery(sql, selectionArgs); } @Override public void execSQL(boolean writeable, String query, Object[] args) { if (args == null) get_database(writeable).execSQL(query); else get_database(writeable).execSQL(query, args); } public void beginTransaction() { get_database(true).beginTransaction(); } @Override public boolean inTransaction() { return get_database(true).inTransaction(); } @Override public void commitTransaction() { get_database(true).setTransactionSuccessful(); get_database(true).endTransaction(); } @Override public void rollbackTransaction() { get_database(true).endTransaction(); } private SQLiteDatabase get_database(boolean writeable) { return writeable ? getWritableDatabase(_password) : getReadableDatabase(_password); } }
UTF-8
Java
1,696
java
EncryptedDatabase.java
Java
[ { "context": "super(context, name, null, 1);\n _password = password;\n }\n\n @Override\n public void onCreate(SQ", "end": 451, "score": 0.9987246990203857, "start": 443, "tag": "PASSWORD", "value": "password" } ]
null
[]
package gr.blackswamp.awesorm; import android.content.Context; import android.database.Cursor; import net.sqlcipher.database.SQLiteDatabase; import net.sqlcipher.database.SQLiteOpenHelper; class EncryptedDatabase extends SQLiteOpenHelper implements IDBConnection { private final String _password; public EncryptedDatabase(Context context, String name, String password) { super(context, name, null, 1); _password = <PASSWORD>; } @Override public void onCreate(SQLiteDatabase sqLiteDatabase) { } @Override public void onUpgrade(SQLiteDatabase sqLiteDatabase, int oldVersion, int newVersion) { } @Override public Cursor rawQuery(boolean writeable, String sql, String[] selectionArgs) { return get_database(writeable).rawQuery(sql, selectionArgs); } @Override public void execSQL(boolean writeable, String query, Object[] args) { if (args == null) get_database(writeable).execSQL(query); else get_database(writeable).execSQL(query, args); } public void beginTransaction() { get_database(true).beginTransaction(); } @Override public boolean inTransaction() { return get_database(true).inTransaction(); } @Override public void commitTransaction() { get_database(true).setTransactionSuccessful(); get_database(true).endTransaction(); } @Override public void rollbackTransaction() { get_database(true).endTransaction(); } private SQLiteDatabase get_database(boolean writeable) { return writeable ? getWritableDatabase(_password) : getReadableDatabase(_password); } }
1,698
0.6875
0.68691
63
25.920635
26.667442
91
false
false
0
0
0
0
0
0
0.47619
false
false
9
2c5712e7eded2765940ad95d8bd8c129ec1fa6e4
3,650,722,242,854
6ea190fe889302725ca83949fbf249d2976509c9
/WEB-INF/classes/RegistroProyecto.java
f04c3b03cf30a71c50b32172f80e686e1e0af61f
[]
no_license
AlanZavala/FinalDataBase
https://github.com/AlanZavala/FinalDataBase
282a8728e90b647f603f173c321af2f31fca487d
a6d45717e3ad6d98a551ca174e6b5ddcfad8cf7e
refs/heads/master
2020-05-18T13:40:58.023000
2019-11-13T20:24:39
2019-11-13T20:24:39
184,447,902
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
/*import java.sql.*; import java.text.SimpleDateFormat; import java.io.*; import javax.servlet.*; import javax.servlet.http.*; import java.util.Date; import objetos.Proyecto; import javax.servlet.annotation.WebServlet; import java.util.Vector; @WebServlet("/RegistroProyecto") public class RegistroProyecto extends HttpServlet{ public void doPost(HttpServletRequest request, HttpServletResponse response){ try{ String base = getServletContext().getInitParameter("base"); String usuario = getServletContext().getInitParameter("usuario"); String pass = getServletContext().getInitParameter("pass"); Class.forName("com.mysql.jdbc.Driver"); String url = "jdbc:mysql://localhost/"+base+"?useSSL=false&allowPublicKeyRetrieval=true"; Connection con = DriverManager.getConnection(url,usuario,pass); Statement stat = con.createStatement(); String nombres=request.getParameter("nombre"); int cuenta=Integer.parseInt(request.getParameter("cuenta")); int window=Integer.parseInt(request.getParameter("pestana")); int id= Integer.parseInt(request.getParameter("id")); String nombre = request.getParameter("nombre"); String fechaInicio = request.getParameter("fechaInicio"); String fechaFin = request.getParameter("fechaFin"); int duracion = Integer.parseInt(request.getParameter("duracion")) ; String descripcion = request.getParameter("descripcion"); int idCliente = Integer.parseInt(request.getParameter("idCliente")) ; int cantidad = Integer.parseInt(request.getParameter("cantidad")) ; float precioTotal = Float.parseFloat(request.getParameter("precioTotal")) ; Proyecto newProyecto = new Proyecto(id, nombre, fechaInicio, fechaFin, duracion, descripcion, idCliente, cantidad, precioTotal); String sql = "INSERT INTO proyecto values("+id+",'"+nombre+"','" + fechaInicio + "', '" + fechaFin + "', " + duracion + ", '" + descripcion + "',"+idCliente+","+cantidad+","+precioTotal+");"; stat.executeUpdate(sql); System.out.println("se agrego el nuevo proyecto"); String sql2 = "SELECT * FROM proyecto where idProyecto="+id+";"; ResultSet res = stat.executeQuery(sql2); Vector<Proyecto> proyectos = new Vector<Proyecto>(); while(res.next()){ Proyecto aux = new Proyecto(); aux.setId(res.getInt("idProyecto")); aux.setNombre(res.getString("nombre")); aux.setFechaInicio(res.getString("fechaDeInicio")); aux.setFechaFin(res.getString("fechaDeTermino")); aux.setDuracion(res.getInt("duracion")); aux.setDescripcion(res.getString("descripcion")); aux.setCuenta(res.getInt("idCliente")); aux.setCantidad(res.getInt("cantidad")); aux.setPrecioTotal(res.getFloat("precioTotal")); proyectos.add(aux); } stat.close(); con.close(); request.setAttribute("proyectos", proyectos); request.setAttribute("response", nombres); request.setAttribute("response2", cuenta); request.setAttribute("response3", window); RequestDispatcher disp = getServletContext().getRequestDispatcher("/proyectoRegistrado.jsp"); if(disp!=null){ disp.forward(request,response); } } catch(Exception e){ try{ e.printStackTrace(); } catch(Exception e2){ try{ e.printStackTrace(); } catch(Exception e3){ e3.printStackTrace(); } } } } }*/
UTF-8
Java
4,183
java
RegistroProyecto.java
Java
[]
null
[]
/*import java.sql.*; import java.text.SimpleDateFormat; import java.io.*; import javax.servlet.*; import javax.servlet.http.*; import java.util.Date; import objetos.Proyecto; import javax.servlet.annotation.WebServlet; import java.util.Vector; @WebServlet("/RegistroProyecto") public class RegistroProyecto extends HttpServlet{ public void doPost(HttpServletRequest request, HttpServletResponse response){ try{ String base = getServletContext().getInitParameter("base"); String usuario = getServletContext().getInitParameter("usuario"); String pass = getServletContext().getInitParameter("pass"); Class.forName("com.mysql.jdbc.Driver"); String url = "jdbc:mysql://localhost/"+base+"?useSSL=false&allowPublicKeyRetrieval=true"; Connection con = DriverManager.getConnection(url,usuario,pass); Statement stat = con.createStatement(); String nombres=request.getParameter("nombre"); int cuenta=Integer.parseInt(request.getParameter("cuenta")); int window=Integer.parseInt(request.getParameter("pestana")); int id= Integer.parseInt(request.getParameter("id")); String nombre = request.getParameter("nombre"); String fechaInicio = request.getParameter("fechaInicio"); String fechaFin = request.getParameter("fechaFin"); int duracion = Integer.parseInt(request.getParameter("duracion")) ; String descripcion = request.getParameter("descripcion"); int idCliente = Integer.parseInt(request.getParameter("idCliente")) ; int cantidad = Integer.parseInt(request.getParameter("cantidad")) ; float precioTotal = Float.parseFloat(request.getParameter("precioTotal")) ; Proyecto newProyecto = new Proyecto(id, nombre, fechaInicio, fechaFin, duracion, descripcion, idCliente, cantidad, precioTotal); String sql = "INSERT INTO proyecto values("+id+",'"+nombre+"','" + fechaInicio + "', '" + fechaFin + "', " + duracion + ", '" + descripcion + "',"+idCliente+","+cantidad+","+precioTotal+");"; stat.executeUpdate(sql); System.out.println("se agrego el nuevo proyecto"); String sql2 = "SELECT * FROM proyecto where idProyecto="+id+";"; ResultSet res = stat.executeQuery(sql2); Vector<Proyecto> proyectos = new Vector<Proyecto>(); while(res.next()){ Proyecto aux = new Proyecto(); aux.setId(res.getInt("idProyecto")); aux.setNombre(res.getString("nombre")); aux.setFechaInicio(res.getString("fechaDeInicio")); aux.setFechaFin(res.getString("fechaDeTermino")); aux.setDuracion(res.getInt("duracion")); aux.setDescripcion(res.getString("descripcion")); aux.setCuenta(res.getInt("idCliente")); aux.setCantidad(res.getInt("cantidad")); aux.setPrecioTotal(res.getFloat("precioTotal")); proyectos.add(aux); } stat.close(); con.close(); request.setAttribute("proyectos", proyectos); request.setAttribute("response", nombres); request.setAttribute("response2", cuenta); request.setAttribute("response3", window); RequestDispatcher disp = getServletContext().getRequestDispatcher("/proyectoRegistrado.jsp"); if(disp!=null){ disp.forward(request,response); } } catch(Exception e){ try{ e.printStackTrace(); } catch(Exception e2){ try{ e.printStackTrace(); } catch(Exception e3){ e3.printStackTrace(); } } } } }*/
4,183
0.562993
0.56132
102
39.009804
34.744583
205
false
false
0
0
0
0
0
0
0.95098
false
false
9
6850e933f36b05f539f1bc3d69170fa27c052429
9,981,504,058,376
a4ae88a3821e1d60a80f2b0b5ac856e815377b81
/swiftcom2Ejb/src/test/java/com/jnj/gtsc/swiftcom2/business/swiftcom/valueobject/filter/CharacterFilter_removeReplacePairs_Test.java
68a8a01de88ab25e6976706eb61701b068db1d83
[]
no_license
rcommers/swiftcom
https://github.com/rcommers/swiftcom
8138927c96414cb0fef88efb6354d128c3501bb1
fb036f93b8e7d445ad06cca49127eb5502b6ee9e
refs/heads/master
2017-10-03T01:45:44.645000
2016-09-20T18:27:04
2016-09-20T18:27:04
68,741,031
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
package com.jnj.gtsc.swiftcom2.business.swiftcom.valueobject.filter; import org.junit.Assert; import org.junit.Test; public class CharacterFilter_removeReplacePairs_Test { private CharacterFilter filter = new CharacterFilter(); @Test public void givenMatchingRegex_thenReplacePairIsRemoved() { // given ReplacePair replacePair = new ReplacePair("&", "n"); filter.addReplacePair(replacePair); // when filter.removeReplacePairs("&"); // then Assert.assertFalse(filter.getReplacePairs().contains(replacePair)); } @Test public void givenNonMatchingRegex_thenNothingIsRemoved() { // given ReplacePair replacePair = new ReplacePair("#", "?"); filter.addReplacePair(replacePair); // when filter.removeReplacePairs("&"); // then Assert.assertTrue(filter.getReplacePairs().contains(replacePair)); } @Test public void givenMultipleMatchingRegexes_thenAllReplacePairsAreRemoved() { // given ReplacePair replacePair1 = new ReplacePair("&", "n"); ReplacePair replacePair2 = new ReplacePair("&", "nn"); filter.addReplacePair(replacePair1); filter.addReplacePair(replacePair2); // when filter.removeReplacePairs("&"); // then Assert.assertFalse(filter.getReplacePairs().contains(replacePair1)); Assert.assertFalse(filter.getReplacePairs().contains(replacePair2)); } }
UTF-8
Java
1,536
java
CharacterFilter_removeReplacePairs_Test.java
Java
[]
null
[]
package com.jnj.gtsc.swiftcom2.business.swiftcom.valueobject.filter; import org.junit.Assert; import org.junit.Test; public class CharacterFilter_removeReplacePairs_Test { private CharacterFilter filter = new CharacterFilter(); @Test public void givenMatchingRegex_thenReplacePairIsRemoved() { // given ReplacePair replacePair = new ReplacePair("&", "n"); filter.addReplacePair(replacePair); // when filter.removeReplacePairs("&"); // then Assert.assertFalse(filter.getReplacePairs().contains(replacePair)); } @Test public void givenNonMatchingRegex_thenNothingIsRemoved() { // given ReplacePair replacePair = new ReplacePair("#", "?"); filter.addReplacePair(replacePair); // when filter.removeReplacePairs("&"); // then Assert.assertTrue(filter.getReplacePairs().contains(replacePair)); } @Test public void givenMultipleMatchingRegexes_thenAllReplacePairsAreRemoved() { // given ReplacePair replacePair1 = new ReplacePair("&", "n"); ReplacePair replacePair2 = new ReplacePair("&", "nn"); filter.addReplacePair(replacePair1); filter.addReplacePair(replacePair2); // when filter.removeReplacePairs("&"); // then Assert.assertFalse(filter.getReplacePairs().contains(replacePair1)); Assert.assertFalse(filter.getReplacePairs().contains(replacePair2)); } }
1,536
0.64388
0.639323
45
32.133335
26.458017
78
false
false
0
0
0
0
0
0
0.511111
false
false
9
d3c9b9f0e3a43b6ae9cbe4ef4c382c0f145bb64b
34,548,716,941,313
47395304a4c32ac5d3deaeb55795d177df89527c
/src/main/java/ws/MyWebSocketHandler.java
79d840877c33b7e20546377464e1a19669bc16dd
[]
no_license
isxcode/websocket_simple
https://github.com/isxcode/websocket_simple
88778e3a37edec99c44f62f5e84dc11eb91e6ca4
6d9080ffb8246508aa786cd0bf84782b2d48094c
refs/heads/master
2020-07-13T19:12:53.344000
2018-01-12T08:45:23
2018-01-12T08:45:23
null
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
package ws; import java.util.ArrayList; import java.util.Map; import org.slf4j.Logger; import org.slf4j.LoggerFactory; import org.springframework.web.socket.CloseStatus; import org.springframework.web.socket.TextMessage; import org.springframework.web.socket.WebSocketHandler; import org.springframework.web.socket.WebSocketMessage; import org.springframework.web.socket.WebSocketSession; import com.google.gson.Gson; import com.google.gson.reflect.TypeToken; public class MyWebSocketHandler implements WebSocketHandler { private static final Logger log = LoggerFactory .getLogger(MyWebSocketHandler.class); // 保存所有的用户session private static final ArrayList<WebSocketSession> users = new ArrayList<WebSocketSession>(); // 连接 就绪时 @Override public void afterConnectionEstablished(WebSocketSession session) throws Exception { System.out.println("connect to the websocket success......"); session.sendMessage(new TextMessage("Server:connected OK!")); System.out.println("session:" + session); users.add(session); } // 处理信息 @Override public void handleMessage(WebSocketSession session, WebSocketMessage<?> message) throws Exception { TextMessage returnMessage = new TextMessage(message.getPayload() + " received at server"); System.out.println(session.getHandshakeHeaders().getFirst("Cookie")); session.sendMessage(returnMessage); Gson gson = new Gson(); // 将消息JSON格式通过Gson转换成Map // message.getPayload().toString() 获取消息具体内容 Map<String, Object> msg = gson.fromJson( message.getPayload().toString(), new TypeToken<Map<String, Object>>() { }.getType()); log.info("handleMessage......." + message.getPayload() + "..........." + msg); // session.sendMessage(message); // 处理消息 msgContent消息内容 TextMessage textMessage = new TextMessage(msg.get("msgContent") .toString(), true); // 调用方法(发送消息给所有人) sendMsgToAllUsers(textMessage); } // 处理传输时异常 @Override public void handleTransportError(WebSocketSession session, Throwable exception) throws Exception { // TODO Auto-generated method stub } // 关闭 连接时 @Override public void afterConnectionClosed(WebSocketSession session, CloseStatus closeStatus) throws Exception { log.info("connect websocket closed......."); users.remove(session); } @Override public boolean supportsPartialMessages() { // TODO Auto-generated method stub return false; } // 给所有用户发送 信息 public void sendMsgToAllUsers(WebSocketMessage<?> message) throws Exception { for (WebSocketSession user : users) { user.sendMessage(message); } } }
UTF-8
Java
2,731
java
MyWebSocketHandler.java
Java
[]
null
[]
package ws; import java.util.ArrayList; import java.util.Map; import org.slf4j.Logger; import org.slf4j.LoggerFactory; import org.springframework.web.socket.CloseStatus; import org.springframework.web.socket.TextMessage; import org.springframework.web.socket.WebSocketHandler; import org.springframework.web.socket.WebSocketMessage; import org.springframework.web.socket.WebSocketSession; import com.google.gson.Gson; import com.google.gson.reflect.TypeToken; public class MyWebSocketHandler implements WebSocketHandler { private static final Logger log = LoggerFactory .getLogger(MyWebSocketHandler.class); // 保存所有的用户session private static final ArrayList<WebSocketSession> users = new ArrayList<WebSocketSession>(); // 连接 就绪时 @Override public void afterConnectionEstablished(WebSocketSession session) throws Exception { System.out.println("connect to the websocket success......"); session.sendMessage(new TextMessage("Server:connected OK!")); System.out.println("session:" + session); users.add(session); } // 处理信息 @Override public void handleMessage(WebSocketSession session, WebSocketMessage<?> message) throws Exception { TextMessage returnMessage = new TextMessage(message.getPayload() + " received at server"); System.out.println(session.getHandshakeHeaders().getFirst("Cookie")); session.sendMessage(returnMessage); Gson gson = new Gson(); // 将消息JSON格式通过Gson转换成Map // message.getPayload().toString() 获取消息具体内容 Map<String, Object> msg = gson.fromJson( message.getPayload().toString(), new TypeToken<Map<String, Object>>() { }.getType()); log.info("handleMessage......." + message.getPayload() + "..........." + msg); // session.sendMessage(message); // 处理消息 msgContent消息内容 TextMessage textMessage = new TextMessage(msg.get("msgContent") .toString(), true); // 调用方法(发送消息给所有人) sendMsgToAllUsers(textMessage); } // 处理传输时异常 @Override public void handleTransportError(WebSocketSession session, Throwable exception) throws Exception { // TODO Auto-generated method stub } // 关闭 连接时 @Override public void afterConnectionClosed(WebSocketSession session, CloseStatus closeStatus) throws Exception { log.info("connect websocket closed......."); users.remove(session); } @Override public boolean supportsPartialMessages() { // TODO Auto-generated method stub return false; } // 给所有用户发送 信息 public void sendMsgToAllUsers(WebSocketMessage<?> message) throws Exception { for (WebSocketSession user : users) { user.sendMessage(message); } } }
2,731
0.743112
0.742336
104
23.788462
23.654839
92
false
false
0
0
0
0
0
0
1.471154
false
false
9
dc3a5e8b52add274b166d7d86764f3ff07565a40
38,113,539,785,421
74f3e0bd6527246be75a87ce22d578ab0a72d941
/coloniaweb/src/main/java/com/springbootapp/coloniaweb/models/dao/INetworkDao.java
262464b9177ea90496266a9448b67d8c0769948d
[]
no_license
AlfonsoBallesteros/ColoniaWeb_Repository
https://github.com/AlfonsoBallesteros/ColoniaWeb_Repository
98b5db18a9ac4fdf5ffc257ecc02f1319de12d32
f668a6ac728adcaaf7b63eb2c1b1574b7cde9ae0
refs/heads/master
2022-12-05T06:20:54.158000
2020-09-03T16:56:12
2020-09-03T16:56:12
292,629,060
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
package com.springbootapp.coloniaweb.models.dao; import com.springbootapp.coloniaweb.models.entity.Network; import org.springframework.data.jpa.repository.JpaRepository; public interface INetworkDao extends JpaRepository<Network, Long>{ }
UTF-8
Java
242
java
INetworkDao.java
Java
[]
null
[]
package com.springbootapp.coloniaweb.models.dao; import com.springbootapp.coloniaweb.models.entity.Network; import org.springframework.data.jpa.repository.JpaRepository; public interface INetworkDao extends JpaRepository<Network, Long>{ }
242
0.842975
0.842975
9
26
29.177616
66
false
false
0
0
0
0
0
0
0.444444
false
false
9
192b76b59915fe249cb46671bf8060a60c1ea498
36,275,293,782,083
34fd3343e32fcf3df943e6b45e0df7f09c6ffe0b
/src/net/lemonrs/lemonpicker/bytecode/tree/FlowGraph.java
d7cea23a765071e7c6082ee0c41facc76974237a
[]
no_license
lemonrs/LemonPicker
https://github.com/lemonrs/LemonPicker
8b1e5f2a1fd9700942f73ce66fb6c336ba4032e1
9c5e9e99bac6ec3e43f8db1f0ccd11122ad457ea
refs/heads/master
2016-08-08T01:34:46.964000
2014-10-09T01:39:58
2014-10-09T01:39:58
24,122,024
1
1
null
null
null
null
null
null
null
null
null
null
null
null
null
package net.lemonrs.lemonpicker.bytecode.tree; import net.lemonrs.lemonpicker.bytecode.element.ClassElement; import net.lemonrs.lemonpicker.bytecode.element.MethodElement; import net.lemonrs.lemonpicker.bytecode.tree.field.FieldInsnVisitor; import net.lemonrs.lemonpicker.bytecode.tree.method.MethodInsnVisitor; import net.lemonrs.lemonpicker.tree.MethodVisitor; import org.objectweb.asm.ClassReader; import org.objectweb.asm.tree.MethodNode; import java.io.IOException; /** * @author : const_ */ public class FlowGraph { private ClassElement element; private MethodElement method; public FlowGraph(ClassElement element, MethodElement method) { this.element = element; this.method = method; } public MethodVisitor visit() { return new MethodVisitor(method); } public <E extends AbstractMethodVisitor> E visit(Class<E> visitor) { try { E instance = visitor.newInstance(); method.node().accept(instance); return instance; } catch (InstantiationException | IllegalAccessException e) { e.printStackTrace(); } return null; } }
UTF-8
Java
1,171
java
FlowGraph.java
Java
[ { "context": "de;\n\nimport java.io.IOException;\n\n/**\n * @author : const_\n */\npublic class FlowGraph {\n\n private ClassEl", "end": 497, "score": 0.9996521472930908, "start": 491, "tag": "USERNAME", "value": "const_" } ]
null
[]
package net.lemonrs.lemonpicker.bytecode.tree; import net.lemonrs.lemonpicker.bytecode.element.ClassElement; import net.lemonrs.lemonpicker.bytecode.element.MethodElement; import net.lemonrs.lemonpicker.bytecode.tree.field.FieldInsnVisitor; import net.lemonrs.lemonpicker.bytecode.tree.method.MethodInsnVisitor; import net.lemonrs.lemonpicker.tree.MethodVisitor; import org.objectweb.asm.ClassReader; import org.objectweb.asm.tree.MethodNode; import java.io.IOException; /** * @author : const_ */ public class FlowGraph { private ClassElement element; private MethodElement method; public FlowGraph(ClassElement element, MethodElement method) { this.element = element; this.method = method; } public MethodVisitor visit() { return new MethodVisitor(method); } public <E extends AbstractMethodVisitor> E visit(Class<E> visitor) { try { E instance = visitor.newInstance(); method.node().accept(instance); return instance; } catch (InstantiationException | IllegalAccessException e) { e.printStackTrace(); } return null; } }
1,171
0.704526
0.704526
40
28.275
23.550995
72
false
false
0
0
0
0
0
0
0.525
false
false
9
ed8aee8a6306d284f52cebefd5de2bbec1e861e7
36,653,250,904,831
602d67a07f5f7c1b31984de59140f6a14337a279
/ksb-client/src/main/java/com/ksb/web/thirdpart/openapi/service/WaybillWebServiceImpl.java
624fbd20374a3bf0d68cbdb40166beb6f20c94ae
[]
no_license
caocf/ksb-client
https://github.com/caocf/ksb-client
3ec613041603b31885117d467ab22b74b616c4ce
d994ce138642b6c773af8db06e5ee4b2e2816ccd
refs/heads/master
2021-01-16T22:28:42.964000
2015-10-10T05:42:33
2015-10-10T05:42:33
null
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
package com.ksb.web.thirdpart.openapi.service; import org.springframework.stereotype.Service; @Service public class WaybillWebServiceImpl implements WaybillWebService { @Override public void demo() { // TODO Auto-generated method stub } }
UTF-8
Java
254
java
WaybillWebServiceImpl.java
Java
[]
null
[]
package com.ksb.web.thirdpart.openapi.service; import org.springframework.stereotype.Service; @Service public class WaybillWebServiceImpl implements WaybillWebService { @Override public void demo() { // TODO Auto-generated method stub } }
254
0.767717
0.767717
16
14.875
20.657551
65
false
false
0
0
0
0
0
0
0.625
false
false
9
55a22eb0f2e34464a589cc7f73deded52b4e49b2
25,606,595,087,716
986982a3b4ab0c73d849201761ac564d9f343ab7
/src/main/java/com/github/rmannibucau/beam/dq/build/ReadmeUpdater.java
fa3b185a627507a74682d3d1788ae81c51bc715a
[]
no_license
rmannibucau/beam-dq
https://github.com/rmannibucau/beam-dq
cc1a7571681ee5716b3756e36c55c8fc27eb0887
2d5d74ff30c5d44a19df35284805a41a07ddce51
refs/heads/master
2022-12-07T02:15:10.613000
2019-10-03T13:54:13
2019-10-03T13:54:13
212,066,290
0
0
null
false
2022-11-15T23:30:38
2019-10-01T10:15:36
2019-10-03T13:54:21
2022-11-15T23:30:37
63
0
0
2
Java
false
false
/** * Copyright (C) 2006-2019 Talend Inc. - www.talend.com * <p> * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * <p> * http://www.apache.org/licenses/LICENSE-2.0 * <p> * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package com.github.rmannibucau.beam.dq.build; import static java.util.stream.Collectors.joining; import static lombok.AccessLevel.PRIVATE; import java.io.IOException; import java.nio.charset.StandardCharsets; import java.nio.file.Files; import java.nio.file.Path; import java.nio.file.Paths; import java.nio.file.StandardOpenOption; import com.github.rmannibucau.beam.dq.registry.AnalyzerRegistry; import lombok.NoArgsConstructor; import lombok.extern.slf4j.Slf4j; @Slf4j @NoArgsConstructor(access = PRIVATE) public final class ReadmeUpdater { public static void main(final String[] args) throws IOException { final Path path = Paths.get(args[0]); // readme final String content = Files.lines(path).collect(joining("\n")); final String output = replace(content, "list_of_available_components", generateComponentList()); if (!output.equals(content)) { Files.write(path, output.getBytes(StandardCharsets.UTF_8), StandardOpenOption.WRITE, StandardOpenOption.TRUNCATE_EXISTING); log.info("Updated '{}'", path); } else { log.info("'{}' didn't change", path); } } private static String replace(final String document, final String marker, final String newContent) { final String startText = "//begin:" + marker + '\n'; final int start = document.indexOf(startText); final int end = document.indexOf("//end:" + marker + '\n'); if (start < 0 || end <= start) { throw new IllegalStateException("No block found for '" + marker + "'"); } return document.substring(0, start) + startText + '\n' + newContent + '\n' + document.substring(end); } private static String generateComponentList() { return new AnalyzerRegistry().models() .map(m -> "=== " + m.getIdentifier() + "\n\n" + m.getDescription() + '\n') .sorted() .collect(joining("\n")); } }
UTF-8
Java
2,592
java
ReadmeUpdater.java
Java
[ { "context": "tations under the License.\n */\npackage com.github.rmannibucau.beam.dq.build;\n\nimport static java.util.stream.Co", "end": 660, "score": 0.9987979531288147, "start": 649, "tag": "USERNAME", "value": "rmannibucau" }, { "context": "a.nio.file.StandardOpenOption;\n\nimport com.github.rmannibucau.beam.dq.registry.AnalyzerRegistry;\n\nimport lombok", "end": 995, "score": 0.9984884262084961, "start": 984, "tag": "USERNAME", "value": "rmannibucau" } ]
null
[]
/** * Copyright (C) 2006-2019 Talend Inc. - www.talend.com * <p> * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * <p> * http://www.apache.org/licenses/LICENSE-2.0 * <p> * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package com.github.rmannibucau.beam.dq.build; import static java.util.stream.Collectors.joining; import static lombok.AccessLevel.PRIVATE; import java.io.IOException; import java.nio.charset.StandardCharsets; import java.nio.file.Files; import java.nio.file.Path; import java.nio.file.Paths; import java.nio.file.StandardOpenOption; import com.github.rmannibucau.beam.dq.registry.AnalyzerRegistry; import lombok.NoArgsConstructor; import lombok.extern.slf4j.Slf4j; @Slf4j @NoArgsConstructor(access = PRIVATE) public final class ReadmeUpdater { public static void main(final String[] args) throws IOException { final Path path = Paths.get(args[0]); // readme final String content = Files.lines(path).collect(joining("\n")); final String output = replace(content, "list_of_available_components", generateComponentList()); if (!output.equals(content)) { Files.write(path, output.getBytes(StandardCharsets.UTF_8), StandardOpenOption.WRITE, StandardOpenOption.TRUNCATE_EXISTING); log.info("Updated '{}'", path); } else { log.info("'{}' didn't change", path); } } private static String replace(final String document, final String marker, final String newContent) { final String startText = "//begin:" + marker + '\n'; final int start = document.indexOf(startText); final int end = document.indexOf("//end:" + marker + '\n'); if (start < 0 || end <= start) { throw new IllegalStateException("No block found for '" + marker + "'"); } return document.substring(0, start) + startText + '\n' + newContent + '\n' + document.substring(end); } private static String generateComponentList() { return new AnalyzerRegistry().models() .map(m -> "=== " + m.getIdentifier() + "\n\n" + m.getDescription() + '\n') .sorted() .collect(joining("\n")); } }
2,592
0.671682
0.664352
64
39.5
31.510414
135
false
false
0
0
0
0
0
0
0.640625
false
false
9
d2a6e2bf990a5593e2151b4b39811951f72ccb18
25,898,652,851,604
e8b85d48845e859caaa22f9613b5da24afc56e59
/app/src/main/java/com/net/BaiduAI.java
fa76fd50092245b7a7f2d817f5dc38c859a201b5
[]
no_license
5854665/TrashClassify_android_app
https://github.com/5854665/TrashClassify_android_app
66c29e14e72afe3426d528396a950a69bee431b0
292364a2819a12b53f975d19f91b0f9274a3b0a2
refs/heads/master
2020-12-28T14:20:08.525000
2019-12-17T04:41:08
2019-12-17T04:41:08
null
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
package com.net; import android.annotation.SuppressLint; import android.app.Activity; import android.content.Context; import android.content.Intent; import android.content.SharedPreferences; import android.os.Handler; import android.os.Message; import android.widget.CheckBox; import android.widget.EditText; import android.widget.TextView; import android.widget.Toast; import androidx.annotation.NonNull; import com.activities.MainActivity; import com.activities.SearchActivity; import com.activities.signUpSuccess; import com.utils.Base64Util; import com.utils.FileUtil; import com.utils.HttpUtil; import java.io.BufferedReader; import java.io.DataOutputStream; import java.io.File; import java.io.IOException; import java.io.InputStream; import java.io.InputStreamReader; import java.net.HttpURLConnection; import java.net.URL; import java.net.URLEncoder; import java.text.SimpleDateFormat; import java.util.Date; import java.util.Locale; public class BaiduAI { private Context context; public BaiduAI(Context context){ this.context = context; } public void advancedGeneral(final String filePath,final File picPath) { new Thread(new Runnable() { @Override public void run() { // 请求url String url = "https://aip.baidubce.com/rest/2.0/image-classify/v2/advanced_general"; try { // 本地文件路径 byte[] imgData = FileUtil.readFileByBytes(filePath); String imgStr = Base64Util.encode(imgData); String imgParam = URLEncoder.encode(imgStr, "UTF-8"); String param = "image=" + imgParam; // 注意这里仅为了简化编码每一次请求都去获取access_token,线上环境access_token有过期时间, 客户端可自行缓存,过期后重新获取。 String accessToken = "24.263f05c71100d1ef02365e9c86bcc233.2592000.1576939477.282335-17275731"; String result = HttpUtil.post(url, accessToken, param); Message message = Message.obtain(); message.what = 0; message.obj = result+"^"+ picPath; advancedGeneralHandel.sendMessage(message); } catch (Exception e) { e.printStackTrace(); Message message = Message.obtain(); message.what = 1; advancedGeneralHandel.sendMessage(message); } } }).start(); } @SuppressLint("HandlerLeak") private Handler advancedGeneralHandel = new Handler(){ @Override public void handleMessage(@NonNull Message msg) { super.handleMessage(msg); switch (msg.what){ case 0: StringBuilder s = new StringBuilder(); String[] reg = msg.obj.toString().split("\\{"); for(int i = 2; i < reg.length; i++){ s.append(reg[i].split(",")[2]); } String[] reg1 = s.toString().split("\""); s = new StringBuilder(); for (String value : reg1) { if (value.matches("[\\u4e00-\\u9fa5]*")) { s.append(value); break; } } SharedPreferences sharedPreferences = context.getSharedPreferences("history",Context.MODE_PRIVATE); SharedPreferences.Editor editor = sharedPreferences.edit(); editor.putString("search_photo_path",sharedPreferences.getString("search_photo_path","") + new SimpleDateFormat("yyyy-MM-dd hh:mm:ss", Locale.getDefault()).format(new Date()) + msg.obj.toString().split("\\^")[1]+s.toString()); editor.apply(); System.out.println(sharedPreferences.getString("search_photo_path","")); Intent intent = new Intent(context, SearchActivity.class); intent.putExtra("s",s.toString()); context.startActivity(intent); break; case 1: Toast.makeText(context,"!!!!!!!!!!!!!!error",Toast.LENGTH_LONG).show(); break; } } }; }
UTF-8
Java
4,494
java
BaiduAI.java
Java
[ { "context": "期后重新获取。\n String accessToken = \"24.263f05c71100d1ef02365e9c86bcc233.2592000.1576939477.282335-17275731\";\n\n ", "end": 1860, "score": 0.9989966154098511, "start": 1827, "tag": "KEY", "value": "24.263f05c71100d1ef02365e9c86bcc2" } ]
null
[]
package com.net; import android.annotation.SuppressLint; import android.app.Activity; import android.content.Context; import android.content.Intent; import android.content.SharedPreferences; import android.os.Handler; import android.os.Message; import android.widget.CheckBox; import android.widget.EditText; import android.widget.TextView; import android.widget.Toast; import androidx.annotation.NonNull; import com.activities.MainActivity; import com.activities.SearchActivity; import com.activities.signUpSuccess; import com.utils.Base64Util; import com.utils.FileUtil; import com.utils.HttpUtil; import java.io.BufferedReader; import java.io.DataOutputStream; import java.io.File; import java.io.IOException; import java.io.InputStream; import java.io.InputStreamReader; import java.net.HttpURLConnection; import java.net.URL; import java.net.URLEncoder; import java.text.SimpleDateFormat; import java.util.Date; import java.util.Locale; public class BaiduAI { private Context context; public BaiduAI(Context context){ this.context = context; } public void advancedGeneral(final String filePath,final File picPath) { new Thread(new Runnable() { @Override public void run() { // 请求url String url = "https://aip.baidubce.com/rest/2.0/image-classify/v2/advanced_general"; try { // 本地文件路径 byte[] imgData = FileUtil.readFileByBytes(filePath); String imgStr = Base64Util.encode(imgData); String imgParam = URLEncoder.encode(imgStr, "UTF-8"); String param = "image=" + imgParam; // 注意这里仅为了简化编码每一次请求都去获取access_token,线上环境access_token有过期时间, 客户端可自行缓存,过期后重新获取。 String accessToken = "<KEY>33.2592000.1576939477.282335-17275731"; String result = HttpUtil.post(url, accessToken, param); Message message = Message.obtain(); message.what = 0; message.obj = result+"^"+ picPath; advancedGeneralHandel.sendMessage(message); } catch (Exception e) { e.printStackTrace(); Message message = Message.obtain(); message.what = 1; advancedGeneralHandel.sendMessage(message); } } }).start(); } @SuppressLint("HandlerLeak") private Handler advancedGeneralHandel = new Handler(){ @Override public void handleMessage(@NonNull Message msg) { super.handleMessage(msg); switch (msg.what){ case 0: StringBuilder s = new StringBuilder(); String[] reg = msg.obj.toString().split("\\{"); for(int i = 2; i < reg.length; i++){ s.append(reg[i].split(",")[2]); } String[] reg1 = s.toString().split("\""); s = new StringBuilder(); for (String value : reg1) { if (value.matches("[\\u4e00-\\u9fa5]*")) { s.append(value); break; } } SharedPreferences sharedPreferences = context.getSharedPreferences("history",Context.MODE_PRIVATE); SharedPreferences.Editor editor = sharedPreferences.edit(); editor.putString("search_photo_path",sharedPreferences.getString("search_photo_path","") + new SimpleDateFormat("yyyy-MM-dd hh:mm:ss", Locale.getDefault()).format(new Date()) + msg.obj.toString().split("\\^")[1]+s.toString()); editor.apply(); System.out.println(sharedPreferences.getString("search_photo_path","")); Intent intent = new Intent(context, SearchActivity.class); intent.putExtra("s",s.toString()); context.startActivity(intent); break; case 1: Toast.makeText(context,"!!!!!!!!!!!!!!error",Toast.LENGTH_LONG).show(); break; } } }; }
4,466
0.563441
0.545869
113
37.778763
27.159227
119
false
false
0
0
0
0
0
0
0.752212
false
false
9
97294c3ec7e6c2eb2cb36b06c2e72d321445148f
36,945,308,684,431
7bd104eb9f87d85f91e5ba6f182c38afdd09a4ba
/Android/Trueques-beta/src/uy/trueques_beta/entities/Objeto.java
a0a6dcc9a818c0413029743e6493383ce294bc5b
[]
no_license
gonzalomelov/baas
https://github.com/gonzalomelov/baas
c6cd9f3352202bdce11ea6224815ad36ec5c334c
c2299d8cbd47a6d409214c5366d6836e123aa7db
refs/heads/master
2021-01-23T11:47:38.625000
2014-05-25T19:24:56
2014-05-25T19:24:56
null
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
package uy.trueques_beta.entities; import java.util.UUID; public class Objeto { private String idObjeto; private String nombre; private String descripcion; private float valor; private String duenio; //private BufferedImage foto; public Objeto(String nombre, String descripcion, float valor, String duenio) { this.idObjeto = UUID.randomUUID().toString(); this.nombre = nombre; this.descripcion = descripcion; this.valor = valor; this.duenio = duenio; } public String getIdObjeto() { return idObjeto; } public void setIdObjeto(String id) { this.idObjeto = id; } public String getNombre() { return nombre; } public void setNombre(String nombre) { this.nombre = nombre; } public String getDescripcion() { return descripcion; } public void setDescripcion(String descripcion) { this.descripcion = descripcion; } public float getValor() { return valor; } public void setValor(float valor) { this.valor = valor; } public String getDuenio() { return duenio; } public void setDuenio(String duenio) { this.duenio = duenio; } //++++++++++++++++ }
UTF-8
Java
1,174
java
Objeto.java
Java
[]
null
[]
package uy.trueques_beta.entities; import java.util.UUID; public class Objeto { private String idObjeto; private String nombre; private String descripcion; private float valor; private String duenio; //private BufferedImage foto; public Objeto(String nombre, String descripcion, float valor, String duenio) { this.idObjeto = UUID.randomUUID().toString(); this.nombre = nombre; this.descripcion = descripcion; this.valor = valor; this.duenio = duenio; } public String getIdObjeto() { return idObjeto; } public void setIdObjeto(String id) { this.idObjeto = id; } public String getNombre() { return nombre; } public void setNombre(String nombre) { this.nombre = nombre; } public String getDescripcion() { return descripcion; } public void setDescripcion(String descripcion) { this.descripcion = descripcion; } public float getValor() { return valor; } public void setValor(float valor) { this.valor = valor; } public String getDuenio() { return duenio; } public void setDuenio(String duenio) { this.duenio = duenio; } //++++++++++++++++ }
1,174
0.663543
0.663543
60
17.566668
16.174431
79
false
false
0
0
0
0
0
0
1.533333
false
false
9
9036e4d18ed0b461ddcbb4c547b848d265073eae
28,303,834,527,895
12ca5827eb8c93b6b1f21ab1ae0ce7d90eb13e49
/java/my-java11/src/src/module-info.java
30623979fafc327e548d5c36c7f753f6a1c6a3bf
[]
no_license
vimalsingh56/learning
https://github.com/vimalsingh56/learning
786d8173c0ad7ca5da7c79de6ff49e4a9b11c0b1
1b0a60790fc71d907126e2cbcc3b0518a98d64df
refs/heads/master
2020-09-21T22:05:53.929000
2020-08-15T09:40:31
2020-08-15T09:40:31
224,948,058
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
module com.philips.test { }
UTF-8
Java
27
java
module-info.java
Java
[]
null
[]
module com.philips.test { }
27
0.740741
0.740741
2
13
12
25
false
false
0
0
0
0
0
0
0
false
false
9
1dc3753ab5a8f4115a264122cc080481d75aba5a
14,946,486,256,100
6c861347dcf8076666bdaee3a086d80151c6524e
/GOV_MCABI7.0/mcabi/src/client/gov/ui/mcabi/bgbillsend/headershandler/BgbillSendStrategy.java
269da408c8898a444b4bbb2017c56ef949d9a781
[]
no_license
liuhan/mcabi
https://github.com/liuhan/mcabi
3029ba18a3b373559bb432530446dbd7e0ea3924
14731103be8251b0859fb3a4b137b085cceb1deb
refs/heads/master
2016-09-16T14:17:57.566000
2015-03-26T13:09:48
2015-03-26T13:09:48
32,873,647
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
package gov.ui.mcabi.bgbillsend.headershandler; import gov.vo.mcabi.AggBgBillVO; import gov.vo.mcabi.BgBillDetailBVO; import gov.vo.mcabi.BgBillHVO; import nc.bs.framework.common.NCLocator; import nc.md.data.access.DASFacade; import nc.md.data.access.NCObject; import nc.ui.pub.bill.BillListPanel; import nc.ui.pub.bill.BillModel; import nc.ui.tcs.taskexec.VOBillListPanelValueSetter; import nc.vo.pub.BusinessException; import nc.vo.pub.bill.BillTabVO; import nc.vo.pub.pf.IPfRetCheckInfo; public class BgbillSendStrategy extends VOBillListPanelValueSetter{ BillListStatusView view = null; @Override public void setBodyData(BillListPanel listPanel, Object selectedData) { //super.setBodyData(listPanel, selectedData); // TODO 自动生成的方法存根 String[] tablecodes = listPanel.getBillListData().getBodyTableCodes(); if (tablecodes == null || tablecodes.length == 0) return; listPanel.getBillListData().setBodyValueObjectByMetaData(selectedData); BillModel groupModel = listPanel.getBillListData().getBodyBillModel( tablecodes[0]); if (selectedData == null) { return; } String parentId = ((AggBgBillVO) selectedData).getPrimaryKey(); gov.itf.mcabi.bgbillsend.IBgbillSendMaintain service = NCLocator.getInstance() .lookup(gov.itf.mcabi.bgbillsend.IBgbillSendMaintain.class); try { BgBillDetailBVO[] vos = service.getBgBillDetailBVO(parentId); groupModel.setBodyDataVO(vos); // listPanel.getBillListData().setBodyValueObjectByMetaData(vos); } catch (BusinessException e) { // TODO 自动生成的 catch 块 e.printStackTrace(); } groupModel.loadLoadRelationItemValue(); listPanel.getBillListData().getBodyBillModel().execLoadFormula(); } @Override public void setHeaderDatas(BillListPanel listPanel, Object[] allDatas) { //super.setHeaderDatas(listPanel, allDatas); // 业务处理,对数据做不同状态的展现 if(view ==null){ view = (BillListStatusView) listPanel.getParent().getParent().getParent().getParent(); } BillTabVO pending = view.getHeadBillListPanel().getBillListData().getTabVO(1, "BgBillHVO"); BillTabVO approve = view.getHeadBillListPanel().getBillListData().getTabVO(1, "yss"); int j=0; for(int i=0;i<allDatas.length;i++){ AggBgBillVO billVO = (AggBgBillVO) allDatas[i]; int status = billVO.getParentVO().getApprovestatus(); if(IPfRetCheckInfo.PASSING ==status){ j++; } } NCObject[] ncos = new NCObject[j]; NCObject[] ncos1 = new NCObject[allDatas.length]; int m =0; int n =0; for (int i = 0; i < allDatas.length; i++) { AggBgBillVO billVO = (AggBgBillVO) allDatas[i]; int status = billVO.getParentVO().getApprovestatus(); if (IPfRetCheckInfo.PASSING== status) { ncos[m] = DASFacade.newInstanceWithContainedObject( approve.getBillMetaDataBusinessEntity(), allDatas[i]); m++; } else { ncos1[n] = DASFacade.newInstanceWithContainedObject( pending.getBillMetaDataBusinessEntity(), allDatas[i]); n++; } } String[] tablecodes = view.getHeadBillListPanel().getBillListData() .getBodyTableCodes(); if (tablecodes == null || tablecodes.length == 0) return; nc.ui.pub.bill.BillModel undoModel = view.getBillListPanel().getBillListData() .getBodyBillModel(tablecodes[0]); undoModel.clearBodyData(); // undoModel.setBodyObjectByMetaData(ncos1); // // doModel.setBodyRowObjectByMetaData(allDatas, 0); // nc.ui.pub.bill.BillModel unDoModel = view.getBillListPanel().getBillListData() .getBodyBillModel(tablecodes[1]); unDoModel.clearBodyData(); // doModel.getRowNOTableModel().setRowCount(ncos1.length); // unDoModel.setBodyObjectByMetaData(ncos); // unDoModel.setBodyRowObjectByMetaData(allDatas, 0); view.getHeadBillListPanel().getBillListData().getBodyBillModel() .execLoadFormula(); } @Override public void setHeaderRowData(BillListPanel listPanel, Object rowData, int row) { // super.setHeaderRowData(listPanel, rowData, row); String[] tablecodes = view.getHeadBillListPanel().getBillListData() .getBodyTableCodes(); if (tablecodes == null || tablecodes.length == 0) return; if (rowData == null) { return; } int approvestatus = ((BgBillHVO) ((AggBgBillVO) rowData) .getParent()).getApprovestatus(); BillModel doModel = view.getBillListPanel().getBillListData() .getBodyBillModel(tablecodes[0]); BillModel unDoModel = view.getBillListPanel().getBillListData() .getBodyBillModel(tablecodes[1]); if (approvestatus == 3) { doModel.addRowAttributeObject(row, "", rowData); } else { unDoModel.addRowAttributeObject(row, "", rowData); } doModel.execLoadFormula(); unDoModel.execLoadFormula(); try { view.getPaginationBar().getPaginationModel().refresh(); } catch (BusinessException e) { e.printStackTrace(); } } }
GB18030
Java
4,834
java
BgbillSendStrategy.java
Java
[]
null
[]
package gov.ui.mcabi.bgbillsend.headershandler; import gov.vo.mcabi.AggBgBillVO; import gov.vo.mcabi.BgBillDetailBVO; import gov.vo.mcabi.BgBillHVO; import nc.bs.framework.common.NCLocator; import nc.md.data.access.DASFacade; import nc.md.data.access.NCObject; import nc.ui.pub.bill.BillListPanel; import nc.ui.pub.bill.BillModel; import nc.ui.tcs.taskexec.VOBillListPanelValueSetter; import nc.vo.pub.BusinessException; import nc.vo.pub.bill.BillTabVO; import nc.vo.pub.pf.IPfRetCheckInfo; public class BgbillSendStrategy extends VOBillListPanelValueSetter{ BillListStatusView view = null; @Override public void setBodyData(BillListPanel listPanel, Object selectedData) { //super.setBodyData(listPanel, selectedData); // TODO 自动生成的方法存根 String[] tablecodes = listPanel.getBillListData().getBodyTableCodes(); if (tablecodes == null || tablecodes.length == 0) return; listPanel.getBillListData().setBodyValueObjectByMetaData(selectedData); BillModel groupModel = listPanel.getBillListData().getBodyBillModel( tablecodes[0]); if (selectedData == null) { return; } String parentId = ((AggBgBillVO) selectedData).getPrimaryKey(); gov.itf.mcabi.bgbillsend.IBgbillSendMaintain service = NCLocator.getInstance() .lookup(gov.itf.mcabi.bgbillsend.IBgbillSendMaintain.class); try { BgBillDetailBVO[] vos = service.getBgBillDetailBVO(parentId); groupModel.setBodyDataVO(vos); // listPanel.getBillListData().setBodyValueObjectByMetaData(vos); } catch (BusinessException e) { // TODO 自动生成的 catch 块 e.printStackTrace(); } groupModel.loadLoadRelationItemValue(); listPanel.getBillListData().getBodyBillModel().execLoadFormula(); } @Override public void setHeaderDatas(BillListPanel listPanel, Object[] allDatas) { //super.setHeaderDatas(listPanel, allDatas); // 业务处理,对数据做不同状态的展现 if(view ==null){ view = (BillListStatusView) listPanel.getParent().getParent().getParent().getParent(); } BillTabVO pending = view.getHeadBillListPanel().getBillListData().getTabVO(1, "BgBillHVO"); BillTabVO approve = view.getHeadBillListPanel().getBillListData().getTabVO(1, "yss"); int j=0; for(int i=0;i<allDatas.length;i++){ AggBgBillVO billVO = (AggBgBillVO) allDatas[i]; int status = billVO.getParentVO().getApprovestatus(); if(IPfRetCheckInfo.PASSING ==status){ j++; } } NCObject[] ncos = new NCObject[j]; NCObject[] ncos1 = new NCObject[allDatas.length]; int m =0; int n =0; for (int i = 0; i < allDatas.length; i++) { AggBgBillVO billVO = (AggBgBillVO) allDatas[i]; int status = billVO.getParentVO().getApprovestatus(); if (IPfRetCheckInfo.PASSING== status) { ncos[m] = DASFacade.newInstanceWithContainedObject( approve.getBillMetaDataBusinessEntity(), allDatas[i]); m++; } else { ncos1[n] = DASFacade.newInstanceWithContainedObject( pending.getBillMetaDataBusinessEntity(), allDatas[i]); n++; } } String[] tablecodes = view.getHeadBillListPanel().getBillListData() .getBodyTableCodes(); if (tablecodes == null || tablecodes.length == 0) return; nc.ui.pub.bill.BillModel undoModel = view.getBillListPanel().getBillListData() .getBodyBillModel(tablecodes[0]); undoModel.clearBodyData(); // undoModel.setBodyObjectByMetaData(ncos1); // // doModel.setBodyRowObjectByMetaData(allDatas, 0); // nc.ui.pub.bill.BillModel unDoModel = view.getBillListPanel().getBillListData() .getBodyBillModel(tablecodes[1]); unDoModel.clearBodyData(); // doModel.getRowNOTableModel().setRowCount(ncos1.length); // unDoModel.setBodyObjectByMetaData(ncos); // unDoModel.setBodyRowObjectByMetaData(allDatas, 0); view.getHeadBillListPanel().getBillListData().getBodyBillModel() .execLoadFormula(); } @Override public void setHeaderRowData(BillListPanel listPanel, Object rowData, int row) { // super.setHeaderRowData(listPanel, rowData, row); String[] tablecodes = view.getHeadBillListPanel().getBillListData() .getBodyTableCodes(); if (tablecodes == null || tablecodes.length == 0) return; if (rowData == null) { return; } int approvestatus = ((BgBillHVO) ((AggBgBillVO) rowData) .getParent()).getApprovestatus(); BillModel doModel = view.getBillListPanel().getBillListData() .getBodyBillModel(tablecodes[0]); BillModel unDoModel = view.getBillListPanel().getBillListData() .getBodyBillModel(tablecodes[1]); if (approvestatus == 3) { doModel.addRowAttributeObject(row, "", rowData); } else { unDoModel.addRowAttributeObject(row, "", rowData); } doModel.execLoadFormula(); unDoModel.execLoadFormula(); try { view.getPaginationBar().getPaginationModel().refresh(); } catch (BusinessException e) { e.printStackTrace(); } } }
4,834
0.731769
0.727158
139
33.330936
24.733803
93
false
false
0
0
0
0
0
0
2.820144
false
false
9
83fffb2b4da78ce5eef92de14c8a9956deacfecc
37,357,625,545,249
95a87398c6d152548527c393f054557d9c2c2c5b
/src/functionalJava07/FunctionalJava.java
99cda0f4cb75cb93c2a067e5db98ff61a187bc70
[]
no_license
maxproof/functionalJava
https://github.com/maxproof/functionalJava
464854034b31c6c8ac3a83dc2eaf923235b51370
cb7c98ed27393b648f5b6209e97ab7231f4e54a2
refs/heads/master
2021-04-28T14:44:19.590000
2018-03-02T18:55:53
2018-03-02T18:55:53
121,972,394
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
package functionalJava07; public class FunctionalJava { public static void main(String[] args) { callExecution(() -> System.out.println("execution")); MyInterface myFunction = () -> System.out.println("delayed execution"); myFunction.execute(); MyClass myObject = new MyClass(); myFunction = myObject::execute; myFunction.execute(); callExecution(myObject::execute);//address method object } public static void callExecution(MyInterface mi) { mi.execute(); } }
UTF-8
Java
510
java
FunctionalJava.java
Java
[]
null
[]
package functionalJava07; public class FunctionalJava { public static void main(String[] args) { callExecution(() -> System.out.println("execution")); MyInterface myFunction = () -> System.out.println("delayed execution"); myFunction.execute(); MyClass myObject = new MyClass(); myFunction = myObject::execute; myFunction.execute(); callExecution(myObject::execute);//address method object } public static void callExecution(MyInterface mi) { mi.execute(); } }
510
0.688235
0.684314
27
17.888889
21.486143
73
false
false
0
0
0
0
0
0
1.703704
false
false
9
04da16c4bbb5d44029b51255748a8607b7468e76
24,653,112,336,600
1b3b36bc45f2ff1f2d2ee95d3df85769a0a0f718
/study_projects/spring_projects/springboot_test/src/main/java/org/cyrestrepo/test/springboot/app/service/AccountServiceImpl.java
1cd97ee1812415ea0a12f77439b72010a1dea66e
[]
no_license
chrizrestrepo/prueba_accenture
https://github.com/chrizrestrepo/prueba_accenture
62704e82ec6c221f4375911c638ad1f6a782c356
ab2ee8b7f809f86616a509db186915ef0cdb4852
refs/heads/main
2023-03-16T16:16:42.440000
2022-11-21T16:15:16
2022-11-21T16:15:16
347,481,975
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
package org.cyrestrepo.test.springboot.app.service; import lombok.RequiredArgsConstructor; import org.cyrestrepo.test.springboot.app.model.Account; import org.cyrestrepo.test.springboot.app.model.Bank; import org.cyrestrepo.test.springboot.app.repository.AccountRepository; import org.cyrestrepo.test.springboot.app.repository.BankRepository; import org.springframework.stereotype.Service; import org.springframework.transaction.annotation.Transactional; import java.math.BigDecimal; import java.util.List; import java.util.NoSuchElementException; @RequiredArgsConstructor @Service("accountService") public class AccountServiceImpl implements IAccountService{ private final AccountRepository accountRepository; private final BankRepository bankRepository; @Override public Account save(Account account) { return accountRepository.save(account); } @Override public List<Account> findAll() { return this.accountRepository.findAll(); } /** * la anoptacion @Transactional sirve para envolver cada transsacion de manera unica, por lo que de esta manera le indicamos a * spring cuando se hara un commit o no de algo, mediando el parametro readOnly, por lo que en el caso de que vayamos hacer una * transaccion tal como guardar o actualizar, es importante tener en cuenta que el parametro readOnly es false por defecto, * adcional que la anotacion puede usarse a nivel de metodo o clase */ @Override @Transactional(readOnly = true) public Account findById(Long id) { return accountRepository.findById(id) .orElseThrow(() -> new NoSuchElementException("the account with id: ".concat(String.valueOf(id)).concat(" does´t exist"))); } @Override @Transactional(readOnly = true) public int getTotalTransfer(Long bankId) { Bank bank = bankRepository.findById(bankId) .orElseThrow(() -> new NoSuchElementException("the bank with id: ".concat(String.valueOf(bankId)).concat(" does´t exist"))); return bank.getTotalTransfer(); } @Override @Transactional(readOnly = true) public BigDecimal getBalance(Long accountId) { return accountRepository.findById(accountId) .orElseThrow(() -> new NoSuchElementException("the account with id: ".concat(String.valueOf(accountId)).concat(" does´t exist"))).getBalance(); } @Override @Transactional public void transfer(Long origin, Long destiny, BigDecimal balance, Long bankId) { Account originAccount = accountRepository.findById(origin) .orElseThrow(() -> new NoSuchElementException("the account with id: ".concat(String.valueOf(origin)).concat(" does´t exist"))); Account destinyAccount = accountRepository.findById(destiny) .orElseThrow(() -> new NoSuchElementException("the account with id: ".concat(String.valueOf(destiny)).concat(" does´t exist"))); originAccount.debit(balance); accountRepository.save(originAccount); destinyAccount.credit(balance); accountRepository.save(destinyAccount); Bank bank = bankRepository.findById(bankId) .orElseThrow(() -> new NoSuchElementException("the bank with id: ".concat(String.valueOf(bankId)).concat(" does´t exist"))); int totalTransfer = bank.getTotalTransfer(); bank.setTotalTransfer(++totalTransfer); bankRepository.save(bank); } }
UTF-8
Java
3,471
java
AccountServiceImpl.java
Java
[]
null
[]
package org.cyrestrepo.test.springboot.app.service; import lombok.RequiredArgsConstructor; import org.cyrestrepo.test.springboot.app.model.Account; import org.cyrestrepo.test.springboot.app.model.Bank; import org.cyrestrepo.test.springboot.app.repository.AccountRepository; import org.cyrestrepo.test.springboot.app.repository.BankRepository; import org.springframework.stereotype.Service; import org.springframework.transaction.annotation.Transactional; import java.math.BigDecimal; import java.util.List; import java.util.NoSuchElementException; @RequiredArgsConstructor @Service("accountService") public class AccountServiceImpl implements IAccountService{ private final AccountRepository accountRepository; private final BankRepository bankRepository; @Override public Account save(Account account) { return accountRepository.save(account); } @Override public List<Account> findAll() { return this.accountRepository.findAll(); } /** * la anoptacion @Transactional sirve para envolver cada transsacion de manera unica, por lo que de esta manera le indicamos a * spring cuando se hara un commit o no de algo, mediando el parametro readOnly, por lo que en el caso de que vayamos hacer una * transaccion tal como guardar o actualizar, es importante tener en cuenta que el parametro readOnly es false por defecto, * adcional que la anotacion puede usarse a nivel de metodo o clase */ @Override @Transactional(readOnly = true) public Account findById(Long id) { return accountRepository.findById(id) .orElseThrow(() -> new NoSuchElementException("the account with id: ".concat(String.valueOf(id)).concat(" does´t exist"))); } @Override @Transactional(readOnly = true) public int getTotalTransfer(Long bankId) { Bank bank = bankRepository.findById(bankId) .orElseThrow(() -> new NoSuchElementException("the bank with id: ".concat(String.valueOf(bankId)).concat(" does´t exist"))); return bank.getTotalTransfer(); } @Override @Transactional(readOnly = true) public BigDecimal getBalance(Long accountId) { return accountRepository.findById(accountId) .orElseThrow(() -> new NoSuchElementException("the account with id: ".concat(String.valueOf(accountId)).concat(" does´t exist"))).getBalance(); } @Override @Transactional public void transfer(Long origin, Long destiny, BigDecimal balance, Long bankId) { Account originAccount = accountRepository.findById(origin) .orElseThrow(() -> new NoSuchElementException("the account with id: ".concat(String.valueOf(origin)).concat(" does´t exist"))); Account destinyAccount = accountRepository.findById(destiny) .orElseThrow(() -> new NoSuchElementException("the account with id: ".concat(String.valueOf(destiny)).concat(" does´t exist"))); originAccount.debit(balance); accountRepository.save(originAccount); destinyAccount.credit(balance); accountRepository.save(destinyAccount); Bank bank = bankRepository.findById(bankId) .orElseThrow(() -> new NoSuchElementException("the bank with id: ".concat(String.valueOf(bankId)).concat(" does´t exist"))); int totalTransfer = bank.getTotalTransfer(); bank.setTotalTransfer(++totalTransfer); bankRepository.save(bank); } }
3,471
0.716883
0.716883
81
41.777779
41.187916
159
false
false
0
0
0
0
0
0
0.45679
false
false
9
e3739cf0e56636888f2c1f5a848172449bf5ba95
8,340,826,559,723
dd51379514d070d5f9b223755afc29f63f5400fa
/app/src/main/java/com/luigima/gymlogger/data/db/tables/SplitTable.java
dc81272345c381f28713f356ef2e0307d7f9abf7
[]
no_license
luigima/GymLogger-Android-App
https://github.com/luigima/GymLogger-Android-App
1dc8301a3d2c27a439b98ae5a88860054b3dbab8
16183dde37d5e19ebaecc0bef33a747fbcc417b4
refs/heads/master
2020-03-21T14:49:32.025000
2018-06-26T03:15:01
2018-06-26T03:15:01
138,677,411
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
package com.luigima.gymlogger.data.db.tables; public class SplitTable { public static final String TABLE = "split"; public static final String COLUMN_ID = "_id"; public static final String COLUMN_TITLE = "title"; }
UTF-8
Java
230
java
SplitTable.java
Java
[]
null
[]
package com.luigima.gymlogger.data.db.tables; public class SplitTable { public static final String TABLE = "split"; public static final String COLUMN_ID = "_id"; public static final String COLUMN_TITLE = "title"; }
230
0.713043
0.713043
9
24.555555
22.973951
54
false
false
0
0
0
0
0
0
0.444444
false
false
9
f283b7d1f094a782b9716c8f30d8ec1e18184544
38,732,015,081,778
cd92417069f3393ace369d4d19e1bdc50184dd4d
/app/src/main/java/com/example/cann/mustafacanyilmazmu/MainActivity.java
ef2e6a02f6969923eb7ee0a00fb56ddd2e93bdca
[]
no_license
mcanyilmaz/Bi-Kitap-
https://github.com/mcanyilmaz/Bi-Kitap-
c309f7336d6945af34a89161a60f59bf87a0b1e8
f5b91297e7ac7b03fc2ea1da936abd3292be9605
refs/heads/master
2020-04-20T16:58:49.973000
2019-02-03T18:21:55
2019-02-03T18:21:55
168,975,490
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
package com.example.cann.mustafacanyilmazmu; import android.content.Intent; import android.database.Cursor; import android.database.sqlite.SQLiteDatabase; import android.support.v7.app.AppCompatActivity; import android.os.Bundle; import android.view.View; import android.widget.AdapterView; import android.widget.ArrayAdapter; import android.widget.ListView; import android.widget.Toast; import java.util.ArrayList; public class MainActivity extends AppCompatActivity { Veritabanim veritabanim; public static int idSnf; String KitapAdi; String KitapDetayim; String KitapYazarim; private String[] SELECT = { "id", "kitapAdi", "kitapDetayi","kitapYazari"}; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_main); veritabanim = new Veritabanim(this); SQLiteDatabase db = veritabanim.getReadableDatabase(); Cursor cursor = db.query("kitaplar", SELECT, null,null, null, null, null);//select islemi final ListView listemiz=(ListView) findViewById(R.id.listview1); startManagingCursor(cursor); final ArrayList<String> txt = new ArrayList<String>(); final ArrayList<String> ad = new ArrayList<String>(); final ArrayList<String> detay = new ArrayList<String>(); final ArrayList<String> yazar = new ArrayList<String>(); final ArrayList<Integer> idtxt = new ArrayList<Integer>(); int i = 1; while(cursor.moveToNext()){ KitapAdi = cursor.getString((cursor.getColumnIndex("kitapAdi"))); // long id = cursor.getLong(cursor.getColumnIndex("id")); KitapDetayim = cursor.getString((cursor.getColumnIndex("kitapDetayi"))); KitapYazarim = cursor.getString((cursor.getColumnIndex("kitapYazari"))); // int h_No = cursor.getInt((cursor.getColumnIndex("hesap_no"))); //idtxt.add((int)id); ad.add(KitapAdi); detay.add(KitapDetayim); yazar.add(KitapYazarim); txt.add(KitapAdi); // txt.add(k_adi+ " , "+ sifrem+ " , "+k_yeri); i++; } ArrayAdapter<String> veriAdaptoru=new ArrayAdapter<String> (this, android.R.layout.simple_list_item_1, android.R.id.text1, txt); listemiz.setAdapter(veriAdaptoru); listemiz.setOnItemClickListener(new AdapterView.OnItemClickListener() {//listview in click metodu @Override public void onItemClick(AdapterView<?> arg0, View arg1, int arg2, long arg3) { // idSnf = idtxt.get(arg2 );//seçilenin ID degerini integer degiskenine atariz. // Toast.makeText(getApplicationContext(), txt.get(arg2) , Toast.LENGTH_LONG).show(); Intent i = new Intent(MainActivity.this,KitapDetay.class); i.putExtra("veri1",ad.get(arg2)); i.putExtra("veri2",detay.get(arg2)); i.putExtra("veri3",yazar.get(arg2)); // i.putExtra("veri2",sifrem); // i.putExtra("veri3",k_yeri); startActivity(i); } }); } }
UTF-8
Java
3,245
java
MainActivity.java
Java
[ { "context": "package com.example.cann.mustafacanyilmazmu;\n\nimport android.content.Inten", "end": 24, "score": 0.8667930364608765, "start": 20, "tag": "USERNAME", "value": "cann" } ]
null
[]
package com.example.cann.mustafacanyilmazmu; import android.content.Intent; import android.database.Cursor; import android.database.sqlite.SQLiteDatabase; import android.support.v7.app.AppCompatActivity; import android.os.Bundle; import android.view.View; import android.widget.AdapterView; import android.widget.ArrayAdapter; import android.widget.ListView; import android.widget.Toast; import java.util.ArrayList; public class MainActivity extends AppCompatActivity { Veritabanim veritabanim; public static int idSnf; String KitapAdi; String KitapDetayim; String KitapYazarim; private String[] SELECT = { "id", "kitapAdi", "kitapDetayi","kitapYazari"}; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_main); veritabanim = new Veritabanim(this); SQLiteDatabase db = veritabanim.getReadableDatabase(); Cursor cursor = db.query("kitaplar", SELECT, null,null, null, null, null);//select islemi final ListView listemiz=(ListView) findViewById(R.id.listview1); startManagingCursor(cursor); final ArrayList<String> txt = new ArrayList<String>(); final ArrayList<String> ad = new ArrayList<String>(); final ArrayList<String> detay = new ArrayList<String>(); final ArrayList<String> yazar = new ArrayList<String>(); final ArrayList<Integer> idtxt = new ArrayList<Integer>(); int i = 1; while(cursor.moveToNext()){ KitapAdi = cursor.getString((cursor.getColumnIndex("kitapAdi"))); // long id = cursor.getLong(cursor.getColumnIndex("id")); KitapDetayim = cursor.getString((cursor.getColumnIndex("kitapDetayi"))); KitapYazarim = cursor.getString((cursor.getColumnIndex("kitapYazari"))); // int h_No = cursor.getInt((cursor.getColumnIndex("hesap_no"))); //idtxt.add((int)id); ad.add(KitapAdi); detay.add(KitapDetayim); yazar.add(KitapYazarim); txt.add(KitapAdi); // txt.add(k_adi+ " , "+ sifrem+ " , "+k_yeri); i++; } ArrayAdapter<String> veriAdaptoru=new ArrayAdapter<String> (this, android.R.layout.simple_list_item_1, android.R.id.text1, txt); listemiz.setAdapter(veriAdaptoru); listemiz.setOnItemClickListener(new AdapterView.OnItemClickListener() {//listview in click metodu @Override public void onItemClick(AdapterView<?> arg0, View arg1, int arg2, long arg3) { // idSnf = idtxt.get(arg2 );//seçilenin ID degerini integer degiskenine atariz. // Toast.makeText(getApplicationContext(), txt.get(arg2) , Toast.LENGTH_LONG).show(); Intent i = new Intent(MainActivity.this,KitapDetay.class); i.putExtra("veri1",ad.get(arg2)); i.putExtra("veri2",detay.get(arg2)); i.putExtra("veri3",yazar.get(arg2)); // i.putExtra("veri2",sifrem); // i.putExtra("veri3",k_yeri); startActivity(i); } }); } }
3,245
0.632244
0.626387
90
35.044445
29.141384
105
false
false
0
0
0
0
0
0
0.888889
false
false
9
5fa82ea5eebf60cc52ee03d2a82a24ee20553098
34,368,328,317,368
094451a637abeec2c700a8a28e72733236396c49
/app/src/main/java/com/egg8/ui/calendar/CalendarActivity.java
df11e94ae1b290ef5f25df76ee9f74f85f585aa5
[]
no_license
egg8/egg8
https://github.com/egg8/egg8
865a69e30f87f447fec0d3aacfd671d4e49ece73
6c3b85cd0078ee1995494f852d941c8ae0da3cb9
refs/heads/master
2023-03-01T13:40:52
2021-02-05T08:22:21
2021-02-05T08:22:21
326,608,982
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
package com.egg8.ui.calendar; import androidx.annotation.NonNull; import androidx.appcompat.app.AppCompatActivity; import androidx.fragment.app.FragmentManager; import androidx.recyclerview.widget.GridLayoutManager; import androidx.recyclerview.widget.RecyclerView; import android.app.Activity; import android.content.Context; import android.content.Intent; import android.os.Bundle; import android.util.Log; import android.view.View; import android.widget.Button; import android.widget.CalendarView; import android.widget.LinearLayout; import android.widget.TextView; import com.egg8.R; import com.egg8.action.surgery.getTimeAction; import com.egg8.adapter.recyclerview.OnItemClickListener; import com.egg8.adapter.recyclerview.TimeAdapter; import com.egg8.common.GlobalApplication; import com.egg8.common.function.GetDayFormat; import com.egg8.common.function.MakeTimeButton; import com.egg8.common.manager.SharedPreferenceManager; import com.egg8.common.retrofit.RetrofitBuilder; import com.egg8.common.retrofit.RetrofitService; import com.egg8.model.resrvation.ResDTO; import com.egg8.model.string.ButtonDTO; import com.egg8.ui.fragment.BottomSheetDialog; import java.text.SimpleDateFormat; import java.util.ArrayList; import java.util.Date; import retrofit2.Call; import retrofit2.Callback; import retrofit2.Response; public class CalendarActivity extends AppCompatActivity { CalendarView calendarView; TextView Tv_Shop_Name; RecyclerView RecyclerView_time; LinearLayout ll_applist; TimeAdapter timeAdapter; RetrofitBuilder retrofitBuilder; RetrofitService retrofitService; ArrayList<ButtonDTO> list; Context mCon; Intent intent; public static String code; public static String name; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_calender); findId(this); mCon = this; } private String getToday(){ Date now = new Date(); SimpleDateFormat sdf = new SimpleDateFormat("yyyyMMdd"); return sdf.format(now); } private void findId(Activity v){ intent = getIntent(); code = intent.getExtras().getString("supp_code"); name = intent.getExtras().getString("supp_name"); Log.d("code",code); RecyclerView_time = v.findViewById(R.id.RecyclerView_time); ll_applist = v.findViewById(R.id.ll_applist); calendarView = v.findViewById(R.id.calendar_view); Tv_Shop_Name=findViewById(R.id.Tv_Shop_Name); btnListener(); setLayoutManager(); getBaseTime(getToday()); } private void btnListener(){ calendarView.setOnDateChangeListener(dateChangeListener); } private void setLayoutManager(){ GridLayoutManager gridLayoutManager = new GridLayoutManager(mCon, 3); RecyclerView_time.setLayoutManager(gridLayoutManager); } CalendarView.OnDateChangeListener dateChangeListener = new CalendarView.OnDateChangeListener() { @Override public void onSelectedDayChange(@NonNull CalendarView view, int year, int month, int dayOfMonth) { String day = GetDayFormat.MakeToday(year,month+1,dayOfMonth); SharedPreferenceManager.setString(view.getContext(),"tmp_v_date",year+"년 "+(month+1)+"월 "+dayOfMonth+"일"); SharedPreferenceManager.setString(view.getContext(),"tmp_date",day); getBaseTime(day); } }; public void createTimeButton(String time) { list = new ArrayList<>(); list = MakeTimeButton.MakeTimeBtn(time); timeAdapter = new TimeAdapter(mCon,list); RecyclerView_time.setAdapter(timeAdapter); timeAdapter.setOnItemClickListener(new OnItemClickListener() { @Override public void onItemClick(View v, int pos,String a) { BottomSheetDialog fragment = new BottomSheetDialog(); FragmentManager fragmentManager = getSupportFragmentManager(); fragment.show(fragmentManager,"tag"); } }); } public void getBaseTime(String Days) { retrofitBuilder = new RetrofitBuilder("http://222.100.239.140:8888/"); retrofitService = retrofitBuilder.getRetrofitService(); Call<ResDTO> call = retrofitService.getBaseTime(code,Days); call.enqueue(new Callback<ResDTO>() { @Override public void onResponse(Call<ResDTO> call, Response<ResDTO> response) { if(response.isSuccessful()) { ResDTO result = response.body(); if(response.body() != null) { createTimeButton(result.getResult()); } else { GlobalApplication.showToastMsg(mCon,"에러가 발생하였습니다. 관리자에게 문의하세요."); } } else { GlobalApplication.showToastMsg(mCon,"에러가 발생하였습니다. 관리자에게 문의하세요."); Log.d("error!!","onResponse failed"); } } @Override public void onFailure(Call<ResDTO> call, Throwable t) { GlobalApplication.showToastMsg(mCon,"에러가 발생하였습니다. 관리자에게 문의하세요."); Log.d("error!!","onFailure" + t.getMessage()); } }); } }
UTF-8
Java
5,485
java
CalendarActivity.java
Java
[ { "context": " retrofitBuilder = new RetrofitBuilder(\"http://222.100.239.140:8888/\");\n retrofitService = retrofitBuild", "end": 4242, "score": 0.9989885687828064, "start": 4228, "tag": "IP_ADDRESS", "value": "222.100.239.14" } ]
null
[]
package com.egg8.ui.calendar; import androidx.annotation.NonNull; import androidx.appcompat.app.AppCompatActivity; import androidx.fragment.app.FragmentManager; import androidx.recyclerview.widget.GridLayoutManager; import androidx.recyclerview.widget.RecyclerView; import android.app.Activity; import android.content.Context; import android.content.Intent; import android.os.Bundle; import android.util.Log; import android.view.View; import android.widget.Button; import android.widget.CalendarView; import android.widget.LinearLayout; import android.widget.TextView; import com.egg8.R; import com.egg8.action.surgery.getTimeAction; import com.egg8.adapter.recyclerview.OnItemClickListener; import com.egg8.adapter.recyclerview.TimeAdapter; import com.egg8.common.GlobalApplication; import com.egg8.common.function.GetDayFormat; import com.egg8.common.function.MakeTimeButton; import com.egg8.common.manager.SharedPreferenceManager; import com.egg8.common.retrofit.RetrofitBuilder; import com.egg8.common.retrofit.RetrofitService; import com.egg8.model.resrvation.ResDTO; import com.egg8.model.string.ButtonDTO; import com.egg8.ui.fragment.BottomSheetDialog; import java.text.SimpleDateFormat; import java.util.ArrayList; import java.util.Date; import retrofit2.Call; import retrofit2.Callback; import retrofit2.Response; public class CalendarActivity extends AppCompatActivity { CalendarView calendarView; TextView Tv_Shop_Name; RecyclerView RecyclerView_time; LinearLayout ll_applist; TimeAdapter timeAdapter; RetrofitBuilder retrofitBuilder; RetrofitService retrofitService; ArrayList<ButtonDTO> list; Context mCon; Intent intent; public static String code; public static String name; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_calender); findId(this); mCon = this; } private String getToday(){ Date now = new Date(); SimpleDateFormat sdf = new SimpleDateFormat("yyyyMMdd"); return sdf.format(now); } private void findId(Activity v){ intent = getIntent(); code = intent.getExtras().getString("supp_code"); name = intent.getExtras().getString("supp_name"); Log.d("code",code); RecyclerView_time = v.findViewById(R.id.RecyclerView_time); ll_applist = v.findViewById(R.id.ll_applist); calendarView = v.findViewById(R.id.calendar_view); Tv_Shop_Name=findViewById(R.id.Tv_Shop_Name); btnListener(); setLayoutManager(); getBaseTime(getToday()); } private void btnListener(){ calendarView.setOnDateChangeListener(dateChangeListener); } private void setLayoutManager(){ GridLayoutManager gridLayoutManager = new GridLayoutManager(mCon, 3); RecyclerView_time.setLayoutManager(gridLayoutManager); } CalendarView.OnDateChangeListener dateChangeListener = new CalendarView.OnDateChangeListener() { @Override public void onSelectedDayChange(@NonNull CalendarView view, int year, int month, int dayOfMonth) { String day = GetDayFormat.MakeToday(year,month+1,dayOfMonth); SharedPreferenceManager.setString(view.getContext(),"tmp_v_date",year+"년 "+(month+1)+"월 "+dayOfMonth+"일"); SharedPreferenceManager.setString(view.getContext(),"tmp_date",day); getBaseTime(day); } }; public void createTimeButton(String time) { list = new ArrayList<>(); list = MakeTimeButton.MakeTimeBtn(time); timeAdapter = new TimeAdapter(mCon,list); RecyclerView_time.setAdapter(timeAdapter); timeAdapter.setOnItemClickListener(new OnItemClickListener() { @Override public void onItemClick(View v, int pos,String a) { BottomSheetDialog fragment = new BottomSheetDialog(); FragmentManager fragmentManager = getSupportFragmentManager(); fragment.show(fragmentManager,"tag"); } }); } public void getBaseTime(String Days) { retrofitBuilder = new RetrofitBuilder("http://172.16.31.100:8888/"); retrofitService = retrofitBuilder.getRetrofitService(); Call<ResDTO> call = retrofitService.getBaseTime(code,Days); call.enqueue(new Callback<ResDTO>() { @Override public void onResponse(Call<ResDTO> call, Response<ResDTO> response) { if(response.isSuccessful()) { ResDTO result = response.body(); if(response.body() != null) { createTimeButton(result.getResult()); } else { GlobalApplication.showToastMsg(mCon,"에러가 발생하였습니다. 관리자에게 문의하세요."); } } else { GlobalApplication.showToastMsg(mCon,"에러가 발생하였습니다. 관리자에게 문의하세요."); Log.d("error!!","onResponse failed"); } } @Override public void onFailure(Call<ResDTO> call, Throwable t) { GlobalApplication.showToastMsg(mCon,"에러가 발생하였습니다. 관리자에게 문의하세요."); Log.d("error!!","onFailure" + t.getMessage()); } }); } }
5,483
0.67326
0.666542
150
34.733334
25.227146
118
false
false
0
0
0
0
0
0
0.766667
false
false
9
827d21c9348df4e680efcd7c09afdc6e565899fb
34,179,349,773,444
8dd596a15bd569b3397398b5e472b6af7a66bb4a
/app/src/main/java/com/thirdarm/projectmissingkids/data/remote/RemoteSync.java
2ee163faa66b7e0d989e5c176468f2dbb2f5b4a9
[]
no_license
trod-123/ProjectMissingKids
https://github.com/trod-123/ProjectMissingKids
96709c9d45bd7bc137220dc2d54689774940f7da
14516ca6ce1d7f0b585e7204c6d8ce1edf2a1e62
refs/heads/master
2020-03-08T02:42:17.880000
2018-11-07T05:05:35
2018-11-07T05:05:35
127,868,247
1
2
null
false
2018-11-07T08:19:25
2018-04-03T07:25:23
2018-11-07T05:05:40
2018-11-07T08:19:24
1,085
1
0
0
Java
false
null
package com.thirdarm.projectmissingkids.data.remote; import android.support.annotation.Nullable; import android.util.Log; import com.thirdarm.projectmissingkids.data.model.MissingKid; import com.thirdarm.projectmissingkids.util.DataParsingUtils; import com.thirdarm.projectmissingkids.util.NetworkUtils; import org.json.JSONArray; import org.json.JSONException; import org.json.JSONObject; import java.util.ArrayList; import java.util.List; import java.util.concurrent.ExecutorService; /** * Responsible for fetching remote data * Created by trod 11/3/2018 */ public class RemoteSync { private static final String TAG = RemoteSync.class.getSimpleName(); public static final int NO_DATA_RETURNED = -1; private ExecutorService mExecutor; public RemoteSync(ExecutorService executor) { mExecutor = executor; } /** * Callback for fetching data remotely. To be used with {@link RunnableCallback} * * @param <T> */ public interface RemoteSyncCallback<T> { /** * To be called when usable data is returned from a server * * @param response */ void onDataReceived(T response); /** * To be called when there is no data returned, which could be due to no network connection, * no server response, or just simply nothing to be returned * * @param message */ void onNoDataReturned(String message); /** * To be called when there is a general failure during or before getting a server response * * @param e * @param message */ void onFailure(Exception e, @Nullable String message); } /** * Runnable that takes a callback for passing in fetched data * * @param <T> */ private class RunnableCallback<T> implements Runnable { RemoteSyncCallback<T> callback; RunnableCallback(RemoteSyncCallback<T> callback) { this.callback = callback; } public void run() { } } /** * Response object for fetching data remotely, consisting of a list of results and * the total number of pages available in the response * * @param <T> */ public class PageResponse<T> { public List<T> results; public int numPages; PageResponse(List<T> results, int numPages) { this.results = results; this.numPages = numPages; } } /** * Asynchronously fetches a single page of online data * * @param pageNum */ public void fetchSinglePage(int pageNum, RemoteSyncCallback<PageResponse<MissingKid>> callback) { mExecutor.submit(new FetchKidsRunnable(pageNum, callback)); } /** * Asynchronously fetches the num of total pages of search results. May return * {@link RemoteSync#NO_DATA_RETURNED} if there is no response * * @param callback */ public void fetchNumPages(RemoteSyncCallback<Integer> callback) { mExecutor.submit(new FetchNumPagesRunnable(callback)); } /** * Gets the number of pages in the query * * TODO: We should be able to get the number of pages from the individual page search results too */ private class FetchNumPagesRunnable extends RunnableCallback<Integer> { FetchNumPagesRunnable(RemoteSyncCallback<Integer> callback) { super(callback); } @Override public void run() { try { int numPages = RemoteSync.getNumPages(); if (numPages != NO_DATA_RETURNED) { callback.onDataReceived(numPages); } else { callback.onNoDataReturned("No data returned from server"); } } catch (JSONException e) { e.printStackTrace(); callback.onFailure(e, "Error getting numPages"); } } } /** * Fetches kids online */ private class FetchKidsRunnable extends RunnableCallback<PageResponse<MissingKid>> { private int pageNum; private static final int ALL_PAGES = -1; FetchKidsRunnable(int pageNum, RemoteSyncCallback<PageResponse<MissingKid>> callback) { super(callback); this.pageNum = pageNum; } @Override public void run() { try { int numPages = getNumPages(); List<MissingKid> kids = null; if (pageNum != ALL_PAGES) { if (pageNum <= numPages) { kids = RemoteSync.fetchSinglePageOfKids(pageNum); } } else { kids = RemoteSync.fetchAllPagesOfKids(); } if (kids != null) { callback.onDataReceived(new PageResponse<>(kids, numPages)); } else { callback.onNoDataReturned("No data returned from server"); } } catch (JSONException e) { e.printStackTrace(); callback.onFailure(e, "Error getting search results"); } } } /** * See {@link FetchAppendedDetailRunnable} */ public void fetchSingleDetail(MissingKid partialKidData, RemoteSyncCallback<JSONObject> callback) { mExecutor.execute(new FetchAppendedDetailRunnable(partialKidData, callback)); } /** * Fetches detail kid info online. May return a null MissingKid in the event the kid does not * exist in the database, or if the kid already has details */ private class FetchAppendedDetailRunnable extends RunnableCallback<JSONObject> { private MissingKid partialKidData; FetchAppendedDetailRunnable(@Nullable MissingKid partialKidData, RemoteSyncCallback<JSONObject> callback) { super(callback); this.partialKidData = partialKidData; } @Override public void run() { if (partialKidData != null) { if (partialKidData.description == null || partialKidData.description.trim().isEmpty()) { callback.onDataReceived(fetchDetailData(partialKidData.caseNum, partialKidData.orgPrefix)); } else { callback.onNoDataReturned("Kid already has detail. Did not fetch"); } } else { callback.onFailure(new Exception("Partial kid data was null"), null); } } } /** * Fetch search results from a single page and convert into a list MissingKid objects * <p> * Needs to be called on a background thread since we're downloading from a network * <p> * Logs an error and returns null if there is no data returned from the server, or if there was * something wrong with fetching the results * * @param pageNum */ @Nullable synchronized private static List<MissingKid> fetchSinglePageOfKids(int pageNum) throws JSONException { JSONArray searchResults = NetworkUtils.getSearchResultPageJsonArray(pageNum); if (searchResults != null) { return DataParsingUtils.getMissingKidListFromJsonArray(searchResults); } else { Log.e(TAG + "/fetchSinglePage", "There was no data returned from the server."); } return null; } /** * Gets the number of pages. Returns {@link RemoteSync#NO_DATA_RETURNED} if there is no data * returned from the server * * TODO: We can get this easily from the same search result page, instead of having to call * the first url over and over again * * @return * @throws JSONException */ synchronized private static int getNumPages() throws JSONException { JSONObject searchResults = NetworkUtils.getSearchResultsMetadataJson(); if (searchResults != null) { return NetworkUtils.getTotalPagesFromMetadata(searchResults); } else { Log.e(TAG + "/getNumPages", "There was no data returned from the server."); return NO_DATA_RETURNED; } } /** * Fetches results from all pages, one at a time, and returns the list of all kids from * the search. Consider this a single-task operation, in which the return occurs after ALL * pages have been collected. * <p> * Needs to be called on a background thread since we're downloading from a network * <p> * Logs an error if there is no data returned from the server, or if there was something wrong * with fetching the results */ @Nullable synchronized private static List<MissingKid> fetchAllPagesOfKids() throws JSONException { List<MissingKid> results = new ArrayList<>(); // get the number of pages to iterate through int numPages = getNumPages(); if (numPages != NO_DATA_RETURNED) { for (int i = 1; i <= numPages; i++) { results.addAll(fetchSinglePageOfKids(i)); } return results; } else { Log.e(TAG + "/fetchAllPages", "There was no data returned from the server."); return null; } } /** * Fetches the JSONObject detail data for a single kid. This will need to be merged with * a MissingKid object fetched from the local data source * <p> * Needs to be called on a background thread since we're downloading from a network * <p> * Logs an error if there is no data returned from the server, or if there was something wrong * with fetching the results */ @Nullable synchronized private static JSONObject fetchDetailData(final String caseNum, final String orgPrefix) { try { return NetworkUtils.getDetailDataJson(caseNum, orgPrefix); } catch (JSONException e) { e.printStackTrace(); Log.e(TAG + "/fetchDetailData", "There was a problem grabbing the detail data from the provided caseNumber (" + caseNum + ") and orgPrefix (" + orgPrefix + ")"); } return null; } }
UTF-8
Java
10,309
java
RemoteSync.java
Java
[ { "context": "Responsible for fetching remote data\n * Created by trod 11/3/2018\n */\npublic class RemoteSync {\n\n priv", "end": 553, "score": 0.9985200762748718, "start": 549, "tag": "USERNAME", "value": "trod" } ]
null
[]
package com.thirdarm.projectmissingkids.data.remote; import android.support.annotation.Nullable; import android.util.Log; import com.thirdarm.projectmissingkids.data.model.MissingKid; import com.thirdarm.projectmissingkids.util.DataParsingUtils; import com.thirdarm.projectmissingkids.util.NetworkUtils; import org.json.JSONArray; import org.json.JSONException; import org.json.JSONObject; import java.util.ArrayList; import java.util.List; import java.util.concurrent.ExecutorService; /** * Responsible for fetching remote data * Created by trod 11/3/2018 */ public class RemoteSync { private static final String TAG = RemoteSync.class.getSimpleName(); public static final int NO_DATA_RETURNED = -1; private ExecutorService mExecutor; public RemoteSync(ExecutorService executor) { mExecutor = executor; } /** * Callback for fetching data remotely. To be used with {@link RunnableCallback} * * @param <T> */ public interface RemoteSyncCallback<T> { /** * To be called when usable data is returned from a server * * @param response */ void onDataReceived(T response); /** * To be called when there is no data returned, which could be due to no network connection, * no server response, or just simply nothing to be returned * * @param message */ void onNoDataReturned(String message); /** * To be called when there is a general failure during or before getting a server response * * @param e * @param message */ void onFailure(Exception e, @Nullable String message); } /** * Runnable that takes a callback for passing in fetched data * * @param <T> */ private class RunnableCallback<T> implements Runnable { RemoteSyncCallback<T> callback; RunnableCallback(RemoteSyncCallback<T> callback) { this.callback = callback; } public void run() { } } /** * Response object for fetching data remotely, consisting of a list of results and * the total number of pages available in the response * * @param <T> */ public class PageResponse<T> { public List<T> results; public int numPages; PageResponse(List<T> results, int numPages) { this.results = results; this.numPages = numPages; } } /** * Asynchronously fetches a single page of online data * * @param pageNum */ public void fetchSinglePage(int pageNum, RemoteSyncCallback<PageResponse<MissingKid>> callback) { mExecutor.submit(new FetchKidsRunnable(pageNum, callback)); } /** * Asynchronously fetches the num of total pages of search results. May return * {@link RemoteSync#NO_DATA_RETURNED} if there is no response * * @param callback */ public void fetchNumPages(RemoteSyncCallback<Integer> callback) { mExecutor.submit(new FetchNumPagesRunnable(callback)); } /** * Gets the number of pages in the query * * TODO: We should be able to get the number of pages from the individual page search results too */ private class FetchNumPagesRunnable extends RunnableCallback<Integer> { FetchNumPagesRunnable(RemoteSyncCallback<Integer> callback) { super(callback); } @Override public void run() { try { int numPages = RemoteSync.getNumPages(); if (numPages != NO_DATA_RETURNED) { callback.onDataReceived(numPages); } else { callback.onNoDataReturned("No data returned from server"); } } catch (JSONException e) { e.printStackTrace(); callback.onFailure(e, "Error getting numPages"); } } } /** * Fetches kids online */ private class FetchKidsRunnable extends RunnableCallback<PageResponse<MissingKid>> { private int pageNum; private static final int ALL_PAGES = -1; FetchKidsRunnable(int pageNum, RemoteSyncCallback<PageResponse<MissingKid>> callback) { super(callback); this.pageNum = pageNum; } @Override public void run() { try { int numPages = getNumPages(); List<MissingKid> kids = null; if (pageNum != ALL_PAGES) { if (pageNum <= numPages) { kids = RemoteSync.fetchSinglePageOfKids(pageNum); } } else { kids = RemoteSync.fetchAllPagesOfKids(); } if (kids != null) { callback.onDataReceived(new PageResponse<>(kids, numPages)); } else { callback.onNoDataReturned("No data returned from server"); } } catch (JSONException e) { e.printStackTrace(); callback.onFailure(e, "Error getting search results"); } } } /** * See {@link FetchAppendedDetailRunnable} */ public void fetchSingleDetail(MissingKid partialKidData, RemoteSyncCallback<JSONObject> callback) { mExecutor.execute(new FetchAppendedDetailRunnable(partialKidData, callback)); } /** * Fetches detail kid info online. May return a null MissingKid in the event the kid does not * exist in the database, or if the kid already has details */ private class FetchAppendedDetailRunnable extends RunnableCallback<JSONObject> { private MissingKid partialKidData; FetchAppendedDetailRunnable(@Nullable MissingKid partialKidData, RemoteSyncCallback<JSONObject> callback) { super(callback); this.partialKidData = partialKidData; } @Override public void run() { if (partialKidData != null) { if (partialKidData.description == null || partialKidData.description.trim().isEmpty()) { callback.onDataReceived(fetchDetailData(partialKidData.caseNum, partialKidData.orgPrefix)); } else { callback.onNoDataReturned("Kid already has detail. Did not fetch"); } } else { callback.onFailure(new Exception("Partial kid data was null"), null); } } } /** * Fetch search results from a single page and convert into a list MissingKid objects * <p> * Needs to be called on a background thread since we're downloading from a network * <p> * Logs an error and returns null if there is no data returned from the server, or if there was * something wrong with fetching the results * * @param pageNum */ @Nullable synchronized private static List<MissingKid> fetchSinglePageOfKids(int pageNum) throws JSONException { JSONArray searchResults = NetworkUtils.getSearchResultPageJsonArray(pageNum); if (searchResults != null) { return DataParsingUtils.getMissingKidListFromJsonArray(searchResults); } else { Log.e(TAG + "/fetchSinglePage", "There was no data returned from the server."); } return null; } /** * Gets the number of pages. Returns {@link RemoteSync#NO_DATA_RETURNED} if there is no data * returned from the server * * TODO: We can get this easily from the same search result page, instead of having to call * the first url over and over again * * @return * @throws JSONException */ synchronized private static int getNumPages() throws JSONException { JSONObject searchResults = NetworkUtils.getSearchResultsMetadataJson(); if (searchResults != null) { return NetworkUtils.getTotalPagesFromMetadata(searchResults); } else { Log.e(TAG + "/getNumPages", "There was no data returned from the server."); return NO_DATA_RETURNED; } } /** * Fetches results from all pages, one at a time, and returns the list of all kids from * the search. Consider this a single-task operation, in which the return occurs after ALL * pages have been collected. * <p> * Needs to be called on a background thread since we're downloading from a network * <p> * Logs an error if there is no data returned from the server, or if there was something wrong * with fetching the results */ @Nullable synchronized private static List<MissingKid> fetchAllPagesOfKids() throws JSONException { List<MissingKid> results = new ArrayList<>(); // get the number of pages to iterate through int numPages = getNumPages(); if (numPages != NO_DATA_RETURNED) { for (int i = 1; i <= numPages; i++) { results.addAll(fetchSinglePageOfKids(i)); } return results; } else { Log.e(TAG + "/fetchAllPages", "There was no data returned from the server."); return null; } } /** * Fetches the JSONObject detail data for a single kid. This will need to be merged with * a MissingKid object fetched from the local data source * <p> * Needs to be called on a background thread since we're downloading from a network * <p> * Logs an error if there is no data returned from the server, or if there was something wrong * with fetching the results */ @Nullable synchronized private static JSONObject fetchDetailData(final String caseNum, final String orgPrefix) { try { return NetworkUtils.getDetailDataJson(caseNum, orgPrefix); } catch (JSONException e) { e.printStackTrace(); Log.e(TAG + "/fetchDetailData", "There was a problem grabbing the detail data from the provided caseNumber (" + caseNum + ") and orgPrefix (" + orgPrefix + ")"); } return null; } }
10,309
0.607527
0.606557
300
33.363335
30.825823
121
false
false
0
0
0
0
0
0
0.35
false
false
9
ab2395981db1055e35c21a4d48a8a76936264e7c
30,185,030,200,864
9e048428ca10f604c557784f4b28c68ce9b5cccb
/bitcamp-java-basic/src/step11/ex09/Exam01.java
0b6b6b2ae92cd52435f44d34e1cf9a93af8b7c26
[]
no_license
donhee/bitcamp
https://github.com/donhee/bitcamp
6c90ec687e00de07315f647bdb1fda0e277c3937
860aa16d86cbd6faeb56b1f5c70b5ea5d297aef0
refs/heads/master
2021-01-24T11:44:48.812000
2019-02-20T00:06:07
2019-02-20T00:06:07
123,054,172
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
// 다형성 - 다형적 변수(polymorphic variables) package step11.ex09; public class Exam01 { public static void main(String[] args) { Vehicle v = new Vehicle(); Bike b = new Bike(); Car c = new Car(); Sedan s = new Sedan(); Truck t = new Truck(); // 레퍼런스는 같은 타입의 객체를 가리킬 수 있을 뿐만아니라 // 그 클래스의 서브클래스 객체까지 가리킬 수 있다. // => 서브 클래스는 항상 상위 클래스의 모든 것을 사용할 수 있기 때문이다. // v2 "다형적 변수"의 기능을 갖고 있다 말한다. Vehicle v2 = null; v2 = b; //OK v2 = c; //OK v2 = s; //OK Bike b2 = null; //b2 = v; //컴파일 오류 //b2 = c; //컴파일 오류 //b2 = s; //컴파일 오류 //b2 = t; //컴파일 오류 Car c2 = null; //c2 = v; //컴파일 오류 //c2 = b; //컴파일 오류 c2 = s; //OK c2 = t; //OK Sedan s2 = null; //s2 = v; //컴파일 오류 //s2 = b; //컴파일 오류 //s2 = c; //컴파일 오류 //s2 = t; //컴파일 오류 } }
UTF-8
Java
1,293
java
Exam01.java
Java
[]
null
[]
// 다형성 - 다형적 변수(polymorphic variables) package step11.ex09; public class Exam01 { public static void main(String[] args) { Vehicle v = new Vehicle(); Bike b = new Bike(); Car c = new Car(); Sedan s = new Sedan(); Truck t = new Truck(); // 레퍼런스는 같은 타입의 객체를 가리킬 수 있을 뿐만아니라 // 그 클래스의 서브클래스 객체까지 가리킬 수 있다. // => 서브 클래스는 항상 상위 클래스의 모든 것을 사용할 수 있기 때문이다. // v2 "다형적 변수"의 기능을 갖고 있다 말한다. Vehicle v2 = null; v2 = b; //OK v2 = c; //OK v2 = s; //OK Bike b2 = null; //b2 = v; //컴파일 오류 //b2 = c; //컴파일 오류 //b2 = s; //컴파일 오류 //b2 = t; //컴파일 오류 Car c2 = null; //c2 = v; //컴파일 오류 //c2 = b; //컴파일 오류 c2 = s; //OK c2 = t; //OK Sedan s2 = null; //s2 = v; //컴파일 오류 //s2 = b; //컴파일 오류 //s2 = c; //컴파일 오류 //s2 = t; //컴파일 오류 } }
1,293
0.397602
0.371628
42
22.833334
11.649477
53
false
false
0
0
0
0
0
0
0.595238
false
false
9
f0dd747464e3ccac8a751cf34cc0f41b02f126f4
34,282,428,990,090
26b3ff7402158f82a8a20324942dd1dd6f60a4d3
/hmx-user/src/main/java/com/hmx/fileupload/controller/FileController.java
2f6f4ed2e55600b8968cffe48657719894b5c5f8
[]
no_license
teamwh/hmx
https://github.com/teamwh/hmx
ec0e7cd27c700a3249f8db7352a3c2b383950efe
40f0e769002238ca039d235d18b2578421557a35
refs/heads/master
2020-04-27T08:24:12.304000
2019-04-22T02:33:30
2019-04-22T02:33:30
174,169,927
0
1
null
false
2019-04-15T02:58:52
2019-03-06T15:23:20
2019-04-15T02:58:52
2019-04-15T02:58:50
11,562
0
1
0
Java
false
false
package com.hmx.fileupload.controller; import java.io.File; import java.util.List; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.util.StringUtils; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RequestParam; import org.springframework.web.bind.annotation.ResponseBody; import org.springframework.web.bind.annotation.RestController; import org.springframework.web.multipart.MultipartFile; import com.hmx.utils.enums.UploadFileType; import com.hmx.utils.oss.upload.UploadUtil; import com.hmx.utils.result.Config; import com.hmx.utils.result.ResultBean; /** * oss文件上传 * @author liY * */ @RestController @RequestMapping("/fileUpload") public class FileController { @Autowired private UploadUtil uploadUtil; /** * @param file * @param module * @return */ @RequestMapping("/upload") @ResponseBody public ResultBean fileUpload( @RequestParam MultipartFile file ,@RequestParam Integer fileType, @RequestParam( required = false) String module ){ if ( file == null ) { return new ResultBean().setCode(Config.UPLOAD_ERROR).setContent("文件为空"); } String path = ""; if ( StringUtils.isEmpty( module ) ) { path = File.separator+"files"+File.separator+"default"+File.separator; }else{ path = File.separator+"files"+File.separator+module+File.separator; } if(fileType == null){ return new ResultBean().setCode(Config.UPLOAD_ERROR).setContent("文件不能为空"); } List<String> fileTypeStr = UploadFileType.getName(fileType); if(fileTypeStr == null){ return new ResultBean().setCode(Config.UPLOAD_ERROR).setContent("文件类型不正确"); } try { String virtualPath = uploadUtil.uploadFile( file , path, fileTypeStr ); if ( StringUtils.isEmpty( virtualPath ) ) { return new ResultBean().setCode(Config.UPLOAD_ERROR).setContent("文件上传异常"); } return new ResultBean().setCode(Config.SUCCESS_CODE).setContent("上传成功").put("virtualPath", virtualPath); } catch (Exception e) { e.printStackTrace(); return new ResultBean().setCode(Config.UPLOAD_ERROR).setContent("文件上传异常:"+ e.getMessage() ); } } }
UTF-8
Java
2,232
java
FileController.java
Java
[ { "context": "tils.result.ResultBean;\n\n/**\n * oss文件上传\n * @author liY\n *\n */\n@RestController\n@RequestMapping(\"/fileUplo", "end": 691, "score": 0.9991352558135986, "start": 688, "tag": "USERNAME", "value": "liY" } ]
null
[]
package com.hmx.fileupload.controller; import java.io.File; import java.util.List; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.util.StringUtils; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RequestParam; import org.springframework.web.bind.annotation.ResponseBody; import org.springframework.web.bind.annotation.RestController; import org.springframework.web.multipart.MultipartFile; import com.hmx.utils.enums.UploadFileType; import com.hmx.utils.oss.upload.UploadUtil; import com.hmx.utils.result.Config; import com.hmx.utils.result.ResultBean; /** * oss文件上传 * @author liY * */ @RestController @RequestMapping("/fileUpload") public class FileController { @Autowired private UploadUtil uploadUtil; /** * @param file * @param module * @return */ @RequestMapping("/upload") @ResponseBody public ResultBean fileUpload( @RequestParam MultipartFile file ,@RequestParam Integer fileType, @RequestParam( required = false) String module ){ if ( file == null ) { return new ResultBean().setCode(Config.UPLOAD_ERROR).setContent("文件为空"); } String path = ""; if ( StringUtils.isEmpty( module ) ) { path = File.separator+"files"+File.separator+"default"+File.separator; }else{ path = File.separator+"files"+File.separator+module+File.separator; } if(fileType == null){ return new ResultBean().setCode(Config.UPLOAD_ERROR).setContent("文件不能为空"); } List<String> fileTypeStr = UploadFileType.getName(fileType); if(fileTypeStr == null){ return new ResultBean().setCode(Config.UPLOAD_ERROR).setContent("文件类型不正确"); } try { String virtualPath = uploadUtil.uploadFile( file , path, fileTypeStr ); if ( StringUtils.isEmpty( virtualPath ) ) { return new ResultBean().setCode(Config.UPLOAD_ERROR).setContent("文件上传异常"); } return new ResultBean().setCode(Config.SUCCESS_CODE).setContent("上传成功").put("virtualPath", virtualPath); } catch (Exception e) { e.printStackTrace(); return new ResultBean().setCode(Config.UPLOAD_ERROR).setContent("文件上传异常:"+ e.getMessage() ); } } }
2,232
0.741427
0.741427
67
31.208956
31.059662
146
false
false
0
0
0
0
0
0
1.701493
false
false
9
37582ae9f644d0c5833da9aab37484338f5e7583
36,627,481,112,060
3ba6e326194ad2e931eb6e796264dad73eefd970
/springcloudclient/src/main/java/springcloud/eureka/client/controller/ControllerTest.java
aa7500156c6a9b6d4d5164e91a462667f1f2feb1
[]
no_license
fangxuefeng/springcloud
https://github.com/fangxuefeng/springcloud
151f9f739fac55baec4e1f790b8585e90c044e6f
79c175f85dc43645e84dd464f996067c84c54fc9
refs/heads/master
2020-04-15T20:54:16.251000
2019-01-12T15:32:28
2019-01-12T15:32:28
165,012,388
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
package springcloud.eureka.client.controller; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RequestParam; import org.springframework.web.bind.annotation.RestController; import springcloud.eureka.client.service.impl.HelloRemote; @RestController @RequestMapping(value = "/test") public class ControllerTest { @Autowired HelloRemote helloRemote; @RequestMapping(value = "/hello") public String index(@RequestParam String name) { // return "hello "+name+",this is producer 2 send first messge"; // return restTemplate.getForObject(a"http://spring-cloud-provicer/provider?name="+name,String.class); return helloRemote.hello(name); } }
UTF-8
Java
811
java
ControllerTest.java
Java
[]
null
[]
package springcloud.eureka.client.controller; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RequestParam; import org.springframework.web.bind.annotation.RestController; import springcloud.eureka.client.service.impl.HelloRemote; @RestController @RequestMapping(value = "/test") public class ControllerTest { @Autowired HelloRemote helloRemote; @RequestMapping(value = "/hello") public String index(@RequestParam String name) { // return "hello "+name+",this is producer 2 send first messge"; // return restTemplate.getForObject(a"http://spring-cloud-provicer/provider?name="+name,String.class); return helloRemote.hello(name); } }
811
0.76267
0.761434
26
30.115385
29.68725
110
false
false
0
0
0
0
0
0
0.423077
false
false
9
17e4a71f999d865e750170dcd08e33e1ef3c787f
26,336,739,516,650
1c8c20f861bd8383e1d99c97ceb2803adef27872
/src/test/java/michid/crdt/AtomicCounterTest.java
1d7416ac62361f0f4c9029dfa504f4db5dcd16e7
[ "Apache-2.0" ]
permissive
jelmini/oak-crdt
https://github.com/jelmini/oak-crdt
a8dc5963e0088a838e825e20d5b9f6e9fd0bcc35
cce8e54f1dbccd6a6b00a7fcdf2ff5ea393d1467
refs/heads/master
2021-12-06T05:15:47.119000
2015-09-29T09:51:40
2015-09-29T09:51:40
null
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
/* * Licensed to the Apache Software Foundation (ASF) under one * or more contributor license agreements. See the NOTICE file * distributed with this work for additional information * regarding copyright ownership. The ASF licenses this file * to you under the Apache License, Version 2.0 (the * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY * KIND, either express or implied. See the License for the * specific language governing permissions and limitations * under the License. */ package michid.crdt; import static org.apache.jackrabbit.oak.plugins.atomic.AtomicCounterEditor.PROP_COUNTER; import static org.apache.jackrabbit.oak.plugins.atomic.AtomicCounterEditor.PROP_INCREMENT; import static org.junit.Assert.assertEquals; import java.util.List; import java.util.Random; import java.util.concurrent.Callable; import java.util.concurrent.ExecutionException; import javax.jcr.Node; import javax.jcr.RepositoryException; import javax.jcr.Session; import com.google.common.collect.Lists; import com.google.common.util.concurrent.ListenableFutureTask; import org.junit.Before; import org.junit.Test; public class AtomicCounterTest extends TestBase { private static final Random RND = new Random(); @Before public void setup() throws RepositoryException { Session session = createAdminSession(); try { Node root = session.getRootNode(); Node counter = root.addNode("counter"); counter.addMixin("mix:atomicCounter"); session.save(); } finally { session.logout(); } } @Test public void counter() throws RepositoryException, ExecutionException, InterruptedException { List<ListenableFutureTask<Long>> tasks = Lists.newArrayList(); for (int k = 0; k < 100; k ++) { tasks.add(updateCounter(RND.nextInt(21 - 10))); } long expectedCount = 0; for (ListenableFutureTask<Long> task : tasks) { expectedCount += task.get(); } Session session = createAdminSession(); try { assertEquals(expectedCount, session.getProperty("/counter/" + PROP_COUNTER).getLong()); } finally { session.logout(); } } private ListenableFutureTask<Long> updateCounter(final long delta) { ListenableFutureTask<Long> task = ListenableFutureTask.create(new Callable<Long>() { @Override public Long call() throws Exception { Session session = createAdminSession(); try { session.getNode("/counter").setProperty(PROP_INCREMENT, delta); session.save(); return delta; } finally { session.logout(); } } }); new Thread(task).start(); return task; } }
UTF-8
Java
3,210
java
AtomicCounterTest.java
Java
[]
null
[]
/* * Licensed to the Apache Software Foundation (ASF) under one * or more contributor license agreements. See the NOTICE file * distributed with this work for additional information * regarding copyright ownership. The ASF licenses this file * to you under the Apache License, Version 2.0 (the * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY * KIND, either express or implied. See the License for the * specific language governing permissions and limitations * under the License. */ package michid.crdt; import static org.apache.jackrabbit.oak.plugins.atomic.AtomicCounterEditor.PROP_COUNTER; import static org.apache.jackrabbit.oak.plugins.atomic.AtomicCounterEditor.PROP_INCREMENT; import static org.junit.Assert.assertEquals; import java.util.List; import java.util.Random; import java.util.concurrent.Callable; import java.util.concurrent.ExecutionException; import javax.jcr.Node; import javax.jcr.RepositoryException; import javax.jcr.Session; import com.google.common.collect.Lists; import com.google.common.util.concurrent.ListenableFutureTask; import org.junit.Before; import org.junit.Test; public class AtomicCounterTest extends TestBase { private static final Random RND = new Random(); @Before public void setup() throws RepositoryException { Session session = createAdminSession(); try { Node root = session.getRootNode(); Node counter = root.addNode("counter"); counter.addMixin("mix:atomicCounter"); session.save(); } finally { session.logout(); } } @Test public void counter() throws RepositoryException, ExecutionException, InterruptedException { List<ListenableFutureTask<Long>> tasks = Lists.newArrayList(); for (int k = 0; k < 100; k ++) { tasks.add(updateCounter(RND.nextInt(21 - 10))); } long expectedCount = 0; for (ListenableFutureTask<Long> task : tasks) { expectedCount += task.get(); } Session session = createAdminSession(); try { assertEquals(expectedCount, session.getProperty("/counter/" + PROP_COUNTER).getLong()); } finally { session.logout(); } } private ListenableFutureTask<Long> updateCounter(final long delta) { ListenableFutureTask<Long> task = ListenableFutureTask.create(new Callable<Long>() { @Override public Long call() throws Exception { Session session = createAdminSession(); try { session.getNode("/counter").setProperty(PROP_INCREMENT, delta); session.save(); return delta; } finally { session.logout(); } } }); new Thread(task).start(); return task; } }
3,210
0.65514
0.65109
94
33.148937
26.274717
99
false
false
0
0
0
0
0
0
0.510638
false
false
9
caf96818dcacdd129ddf1a49fc463c0b2d0ed168
17,171,279,296,431
2f70db829d81aa97dd5170c8893bc0e0bda73bc5
/src/main/java/edu/gmu/cs659/twitter/words/ShortWordFilter.java
cc3c0ca19e530122c35581b1ba4a344af12179af
[]
no_license
aaronleeucla/twitter
https://github.com/aaronleeucla/twitter
72c8d87f4878c54dd369c16cffa9bc06832828e0
455908888aa73de36a7681ecb138fc5af3f16123
refs/heads/master
2020-06-15T23:53:54.076000
2014-04-23T05:06:38
2014-04-23T05:06:38
null
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
package edu.gmu.cs659.twitter.words; import java.util.Arrays; import java.util.Collections; import java.util.HashSet; import java.util.Set; public class ShortWordFilter implements WordChecker { public static final int MIN_LENGTH = 3; private int minLength; public ShortWordFilter() { this(MIN_LENGTH); } public ShortWordFilter(int minLength) { this.minLength = minLength; } public Set<String> checkWord(String word) { if(word.length() < minLength) { return Collections.emptySet(); } return new HashSet<String>(Arrays.asList(word)); } }
UTF-8
Java
573
java
ShortWordFilter.java
Java
[]
null
[]
package edu.gmu.cs659.twitter.words; import java.util.Arrays; import java.util.Collections; import java.util.HashSet; import java.util.Set; public class ShortWordFilter implements WordChecker { public static final int MIN_LENGTH = 3; private int minLength; public ShortWordFilter() { this(MIN_LENGTH); } public ShortWordFilter(int minLength) { this.minLength = minLength; } public Set<String> checkWord(String word) { if(word.length() < minLength) { return Collections.emptySet(); } return new HashSet<String>(Arrays.asList(word)); } }
573
0.726003
0.719023
31
17.483871
17.429806
53
false
false
0
0
0
0
0
0
1.225806
false
false
9
b9a62f66c462f7d102a7b2eb88f8c3394a2308cb
22,660,247,514,957
0f76f64b9a215edcce8e4319357b8fc47799f34f
/src/main/java/com/hourmaps/service/bingmaps/BMTransitRouteService.java
da61dfa32b7661026d59423952a2822f756a8b7c
[]
no_license
christopheryang/TravelTimeAndDistance
https://github.com/christopheryang/TravelTimeAndDistance
eda7751fae0855c71a3278c3a9342c9835adb1bf
ffb503f7b3f9c63eb61a8c59ca43b0e25a36d7a2
refs/heads/master
2015-08-20T15:24:11.390000
2015-08-20T08:51:45
2015-08-20T08:51:45
30,729,364
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
package com.hourmaps.service.bingmaps; import org.slf4j.Logger; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.http.HttpStatus; import org.springframework.http.ResponseEntity; import org.springframework.stereotype.Service; import org.springframework.web.client.HttpClientErrorException; import org.springframework.web.client.HttpServerErrorException; import org.springframework.web.client.RestOperations; import com.hourmaps.data.Grid; import com.hourmaps.data.bingmaps.ErrorResponse; import com.hourmaps.data.bingmaps.RouteRequest; import com.hourmaps.data.bingmaps.RouteResponse; import com.hourmaps.data.bingmaps.TransitRoute; import com.hourmaps.data.bingmaps.enums.OptimizeEnum; import com.hourmaps.data.bingmaps.enums.TimeTypeEnum; import com.hourmaps.repo.BMTransitRouteRepo; import com.hourmaps.util.JsonUtil; @Service public class BMTransitRouteService extends BMAbstractRouteService { private static final Logger logger = LoggerFactory.getLogger(BMTransitRouteService.class); public static final String TRANSIT_ROUTE_URL_TEMPLATE = "http://dev.virtualearth.net/REST/V1/Routes/Transit?"+ "wp.0=${from}&wp.1=${to}"+ "&timeType=${timeType}&dateTime=${dateTime}"+ "&optimize=${optimize}&maxSolns=${maxSolns}"+ "&output=${outputType}&key=${key}"; // protected static final SimpleDateFormat sdf = new SimpleDateFormat("MM/dd/yyyy HH:mm:ss"); @Autowired protected BMTransitRouteRepo routeRepo; @Autowired protected RestOperations restTemplate; /** * Find route between 2 grid assuming: * * 1. Arrive by 9:00 am on 5/13/2015 * 2. Optimized by shortest time. * 3. Max solution = 1 * 4. JSON response * * @param from * @param to */ public TransitRoute findTransitRoute(Grid from, Grid to){ RouteRequest request = new RouteRequest(); request.setDateTime(RouteRequest.ARRIVE_BY_PEAK_AM_HOUR); request.setFrom(from); request.setMaxSolns(1); request.setOptimize(OptimizeEnum.time); request.setTimeType(TimeTypeEnum.Arrival); request.setTo(to); return findTransitRoute(request); } /** * * @param request * @return */ public TransitRoute findTransitRoute(RouteRequest request) throws HttpClientErrorException, HttpServerErrorException { String url = TRANSIT_ROUTE_URL_TEMPLATE .replace("${from}", request.getFrom().getCenter().toString()) .replace("${to}", request.getTo().getCenter().toString()) .replace("${timeType}", request.getTimeType().toString()) .replace("${dateTime}", request.getDateTime()) .replace("${optimize}", request.getOptimize().toString()) .replace("${maxSolns}", request.getMaxSolns()+"") .replace("${outputType}", "json") .replace("${key}", BING_KEY); TransitRoute tr; try{ ResponseEntity<RouteResponse> response = restTemplate.getForEntity(url, RouteResponse.class); tr = new TransitRoute(request, response.getBody()); logger.trace("Bing transit route: "+JsonUtil.serialize(tr)); } // HTTP 4xx catch(HttpClientErrorException ex){ // Sample error response: HTTP 404, body: {"authenticationResultCode":"ValidCredentials","brandLogoUri":"http:\/\/dev.virtualearth.net\/Branding\/logo_powered_by.png","copyright":"Copyright © 2015 Microsoft and its suppliers. All rights reserved. This API cannot be accessed and the content and any results may not be used, reproduced or transmitted in any manner without express written permission from Microsoft Corporation.","errorDetails":["The transit stops are too close."],"resourceSets":[],"statusCode":404,"statusDescription":"Not Found","traceId":"9a8759f934f84fc0af99c94b7a8fe42a|BN20130442|1.0.0.0|BN20271629, BN20010644"} logger.trace("Bing Maps threw an error: "+ex.getResponseBodyAsString()); ErrorResponse errorResponse = JsonUtil.deserialize(ex.getResponseBodyAsString(), ErrorResponse.class); // if this is a HTTP 404 with error details containing "The transit stops are too close." or "No route was found for the waypoints provided.", just return null. if(HttpStatus.NOT_FOUND.value() == errorResponse.getStatusCode() && ( errorResponse.getErrorDetails().contains(ErrorResponse.TRANSIT_STOPS_TOO_CLOSE_ERROR) || errorResponse.getErrorDetails().contains(ErrorResponse.TRANSIT_NO_ROUTE_FOUND_FOR_TWO_WAYPOINTS_ERROR) || errorResponse.getErrorDetails().contains(ErrorResponse.TRANSIT_NO_ROUTE_TOO_FAR_FROM_ROADS) || errorResponse.getErrorDetails().contains(ErrorResponse.TRANSIT_WORSE_THAN_WALKING) )){ tr = new TransitRoute(request, errorResponse); } // Else, throw runtime exception else{ throw new RuntimeException(ex); } } // HTTP 5xx catch(HttpServerErrorException ex){ // Sample error response: {"authenticationResultCode":"ValidCredentials","brandLogoUri":"http:\/\/dev.virtualearth.net\/Branding\/logo_powered_by.png","copyright":"Copyright © 2015 Microsoft and its suppliers. All rights reserved. This API cannot be accessed and the content and any results may not be used, reproduced or transmitted in any manner without express written permission from Microsoft Corporation.","errorDetails":["Your request could not be completed because there was a problem with the service."],"resourceSets":[],"statusCode":500,"statusDescription":"Internal Server Error","traceId":"a10e9a3ddb1d46ec8838be3ec92861c9|BN20130533|1.0.0.0|BN20290822, BN20010560"} logger.trace("Bing Maps threw an error: "+ex.getResponseBodyAsString()); ErrorResponse errorResponse = JsonUtil.deserialize(ex.getResponseBodyAsString(), ErrorResponse.class); tr = new TransitRoute(request, errorResponse); } return routeRepo.save(tr); } }
UTF-8
Java
5,709
java
BMTransitRouteService.java
Java
[]
null
[]
package com.hourmaps.service.bingmaps; import org.slf4j.Logger; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.http.HttpStatus; import org.springframework.http.ResponseEntity; import org.springframework.stereotype.Service; import org.springframework.web.client.HttpClientErrorException; import org.springframework.web.client.HttpServerErrorException; import org.springframework.web.client.RestOperations; import com.hourmaps.data.Grid; import com.hourmaps.data.bingmaps.ErrorResponse; import com.hourmaps.data.bingmaps.RouteRequest; import com.hourmaps.data.bingmaps.RouteResponse; import com.hourmaps.data.bingmaps.TransitRoute; import com.hourmaps.data.bingmaps.enums.OptimizeEnum; import com.hourmaps.data.bingmaps.enums.TimeTypeEnum; import com.hourmaps.repo.BMTransitRouteRepo; import com.hourmaps.util.JsonUtil; @Service public class BMTransitRouteService extends BMAbstractRouteService { private static final Logger logger = LoggerFactory.getLogger(BMTransitRouteService.class); public static final String TRANSIT_ROUTE_URL_TEMPLATE = "http://dev.virtualearth.net/REST/V1/Routes/Transit?"+ "wp.0=${from}&wp.1=${to}"+ "&timeType=${timeType}&dateTime=${dateTime}"+ "&optimize=${optimize}&maxSolns=${maxSolns}"+ "&output=${outputType}&key=${key}"; // protected static final SimpleDateFormat sdf = new SimpleDateFormat("MM/dd/yyyy HH:mm:ss"); @Autowired protected BMTransitRouteRepo routeRepo; @Autowired protected RestOperations restTemplate; /** * Find route between 2 grid assuming: * * 1. Arrive by 9:00 am on 5/13/2015 * 2. Optimized by shortest time. * 3. Max solution = 1 * 4. JSON response * * @param from * @param to */ public TransitRoute findTransitRoute(Grid from, Grid to){ RouteRequest request = new RouteRequest(); request.setDateTime(RouteRequest.ARRIVE_BY_PEAK_AM_HOUR); request.setFrom(from); request.setMaxSolns(1); request.setOptimize(OptimizeEnum.time); request.setTimeType(TimeTypeEnum.Arrival); request.setTo(to); return findTransitRoute(request); } /** * * @param request * @return */ public TransitRoute findTransitRoute(RouteRequest request) throws HttpClientErrorException, HttpServerErrorException { String url = TRANSIT_ROUTE_URL_TEMPLATE .replace("${from}", request.getFrom().getCenter().toString()) .replace("${to}", request.getTo().getCenter().toString()) .replace("${timeType}", request.getTimeType().toString()) .replace("${dateTime}", request.getDateTime()) .replace("${optimize}", request.getOptimize().toString()) .replace("${maxSolns}", request.getMaxSolns()+"") .replace("${outputType}", "json") .replace("${key}", BING_KEY); TransitRoute tr; try{ ResponseEntity<RouteResponse> response = restTemplate.getForEntity(url, RouteResponse.class); tr = new TransitRoute(request, response.getBody()); logger.trace("Bing transit route: "+JsonUtil.serialize(tr)); } // HTTP 4xx catch(HttpClientErrorException ex){ // Sample error response: HTTP 404, body: {"authenticationResultCode":"ValidCredentials","brandLogoUri":"http:\/\/dev.virtualearth.net\/Branding\/logo_powered_by.png","copyright":"Copyright © 2015 Microsoft and its suppliers. All rights reserved. This API cannot be accessed and the content and any results may not be used, reproduced or transmitted in any manner without express written permission from Microsoft Corporation.","errorDetails":["The transit stops are too close."],"resourceSets":[],"statusCode":404,"statusDescription":"Not Found","traceId":"9a8759f934f84fc0af99c94b7a8fe42a|BN20130442|1.0.0.0|BN20271629, BN20010644"} logger.trace("Bing Maps threw an error: "+ex.getResponseBodyAsString()); ErrorResponse errorResponse = JsonUtil.deserialize(ex.getResponseBodyAsString(), ErrorResponse.class); // if this is a HTTP 404 with error details containing "The transit stops are too close." or "No route was found for the waypoints provided.", just return null. if(HttpStatus.NOT_FOUND.value() == errorResponse.getStatusCode() && ( errorResponse.getErrorDetails().contains(ErrorResponse.TRANSIT_STOPS_TOO_CLOSE_ERROR) || errorResponse.getErrorDetails().contains(ErrorResponse.TRANSIT_NO_ROUTE_FOUND_FOR_TWO_WAYPOINTS_ERROR) || errorResponse.getErrorDetails().contains(ErrorResponse.TRANSIT_NO_ROUTE_TOO_FAR_FROM_ROADS) || errorResponse.getErrorDetails().contains(ErrorResponse.TRANSIT_WORSE_THAN_WALKING) )){ tr = new TransitRoute(request, errorResponse); } // Else, throw runtime exception else{ throw new RuntimeException(ex); } } // HTTP 5xx catch(HttpServerErrorException ex){ // Sample error response: {"authenticationResultCode":"ValidCredentials","brandLogoUri":"http:\/\/dev.virtualearth.net\/Branding\/logo_powered_by.png","copyright":"Copyright © 2015 Microsoft and its suppliers. All rights reserved. This API cannot be accessed and the content and any results may not be used, reproduced or transmitted in any manner without express written permission from Microsoft Corporation.","errorDetails":["Your request could not be completed because there was a problem with the service."],"resourceSets":[],"statusCode":500,"statusDescription":"Internal Server Error","traceId":"a10e9a3ddb1d46ec8838be3ec92861c9|BN20130533|1.0.0.0|BN20290822, BN20010560"} logger.trace("Bing Maps threw an error: "+ex.getResponseBodyAsString()); ErrorResponse errorResponse = JsonUtil.deserialize(ex.getResponseBodyAsString(), ErrorResponse.class); tr = new TransitRoute(request, errorResponse); } return routeRepo.save(tr); } }
5,709
0.754862
0.730857
119
46.966385
86.567886
683
false
false
0
0
0
0
0
0
2.697479
false
false
9
c1650ef9a80af658e82c85f95e691eac268629b5
17,901,423,740,343
a99849372e5fce4fc797bcd7aad9dd5af2cd4ed1
/app/src/main/java/com/ehelp/user/history/HistoryAdapter.java
8aa5bdcd084b11ea835c0deca9a1474e61f84fa7
[]
no_license
hugj/Ehelp
https://github.com/hugj/Ehelp
7d02e5651087b33df02e3865d7eaabb80c9d5fca
3a9f8acce48ca5aadebe052f5b1da647074f8583
refs/heads/backup2
2021-01-25T08:29:44.124000
2015-08-14T10:38:54
2015-08-14T10:38:54
39,109,782
4
52
null
false
2015-08-14T10:38:55
2015-07-15T01:35:54
2015-08-05T02:09:50
2015-08-14T10:38:54
26,257
0
6
0
Java
null
null
package com.ehelp.user.history; import android.content.Context; import android.graphics.Bitmap; import android.graphics.BitmapFactory; import android.os.StrictMode; import android.view.View; import android.view.ViewGroup; import android.widget.BaseAdapter; import android.widget.FrameLayout; import android.widget.ImageView; import android.widget.ImageView.ScaleType; import android.widget.LinearLayout; import android.widget.ListView; import android.widget.RelativeLayout; import android.widget.TextView; import com.ehelp.R; import com.ehelp.entity.Event; import com.ehelp.home.ACache; import com.ehelp.utils.RequestHandler; import com.google.gson.Gson; import org.json.JSONArray; import org.json.JSONException; import org.json.JSONObject; import java.io.IOException; import java.io.InputStream; import java.net.HttpURLConnection; import java.net.MalformedURLException; import java.net.URL; import java.util.ArrayList; import java.util.HashMap; import java.util.List; import java.util.Map; /** * Created by gj on 2015/7/27. */ public class HistoryAdapter extends BaseAdapter { private static final int REFRESH_COMPLETE = 2; private Context context=null; private List<Map<String,Object>> list = new ArrayList<Map<String,Object>>(); private Map<String,Object> item; private int user_id; private int type; private List<Event> events; private ACache eventCache; // event cache private Bitmap bitmap = null; private Bitmap defaultPortrait = null; private JSONArray HisList; Gson gson = new Gson(); HistoryAdapter(Context context, int id, int io, int type_, ACache eventCache_){ this.context=context; user_id = id; type = type_; eventCache = eventCache_; // 使用后台线程运行网络连接功能 StrictMode.setThreadPolicy( new StrictMode.ThreadPolicy.Builder(). detectDiskReads().detectDiskWrites().detectNetwork().penaltyLog().build()); StrictMode.setVmPolicy(new StrictMode.VmPolicy.Builder(). detectLeakedSqlLiteObjects().detectLeakedClosableObjects(). penaltyLog().penaltyDeath().build()); //数据初始化 init(io); } public void init(int io){ //数据初始化 getDefault(); getTitleList(io); setList(io); } //发起的 public String setListo() { //数据初始化 String jsonStrng = "{" + "\"id\":" + user_id + ",\"type\":" + type +"}"; String message = RequestHandler.sendPostRequest( "http://120.24.208.130:1501/event/query_launch", jsonStrng); return message; } //参与的 public String setListi() { //数据初始化 String jsonStrng = "{" + "\"id\":" + user_id + ",\"type\":2"+"}"; String message = RequestHandler.sendPostRequest( "http://120.24.208.130:1501/event/query_join", jsonStrng); return message; } //关注的 public String setListc() { //数据初始化 String jsonStrng = "{" + "\"id\":" + user_id + ",\"type\":1"+ "}"; String message = RequestHandler.sendPostRequest( "http://120.24.208.130:1501/event/query_join", jsonStrng); return message; } /* * 获取默认头像 * */ public void getDefault() { if (eventCache.getAsBitmap("morentouxiang") == null) { String url = "http://120.24.208.130:1501/avatar/touxiang.jpg"; defaultPortrait = returnFirstBitMap(url); eventCache.put("morentouxiang", defaultPortrait); } } /* * get cache as a list(for test only) * @param * @return a list contain cache */ public void getTitleList(int io){ if (io == 1) { //发起的事件 if (eventCache.getAsJSONArray(type + "sponsorHistory") == null) { getFirstRemoteTitleList(io); } else { HisList = eventCache.getAsJSONArray(type + "sponsorHistory"); } } else if(io == 2){ //接受的事件 if (eventCache.getAsJSONArray(type + "acceptedHistory") == null) { getFirstRemoteTitleList(io); } else { HisList = eventCache.getAsJSONArray(type + "acceptedHistory"); } }else {//关注的事件 if (eventCache.getAsJSONArray(type + "concernHistory") == null) { getFirstRemoteTitleList(io); } else { HisList = eventCache.getAsJSONArray(type + "concernHistory"); } } } /* * get events' titles from server as a list * only return title * @param * @return a list contains events' titles */ public ACache getFirstRemoteTitleList(int io){ String message; if (io == 1) { //发起的事件 message = setListo(); } else if(io == 2){ //接受的事件 message = setListi(); }else{//关注的事件 message = setListc(); } if (message.equals("false")) { eventCache = null; } else { JSONObject j1 = null; try { j1 = new JSONObject(message); if (j1.getInt("status") == 500) { eventCache = null; } else { JSONArray eventArray = j1.getJSONArray("event_list"); if (io == 1) { //发起的事件 eventCache.put(type + "sponsorHistory", eventArray); } else if(io == 2){ //接受的事件 eventCache.put(type + "acceptedHistory", eventArray); }else{//关注的事件 eventCache.put(type + "concernHistory", eventArray); } for (int i = 0; i < eventArray.length(); i++) { int auncher_id = eventArray.getJSONObject(i).getInt("launcher_id"); String url = "http://120.24.208.130:1501/avatar/" + auncher_id + ".jpg"; Bitmap image = returnFirstBitMap(url); if (image == null) { image = eventCache.getAsBitmap("morentouxiang"); } if (io == 1) { //发起的事件 eventCache.put(type + "sponsorHistory" + "touxiang" + i, image); } else if(io == 2){ //接受的事件 eventCache.put(type + "acceptedHistory" + "touxiang" + i, image); }else{//关注的事件 eventCache.put(type + "concernHistory" + "touxiang" + i, image); } } } } catch (JSONException e) { e.printStackTrace(); } } return eventCache; } /* * get events' titles from server as a list * only return title * @param * @return a list contains events' titles */ public ACache getRemoteTitleList(int type_, int io_){ final int type = type_; final int io = io_; new Thread(new Runnable() { @Override public void run() { String message; if (io == 1) { //发起的事件 message = setListo(); } else if(io == 2){ //接受的事件 message = setListi(); }else{//关注的事件 message = setListc(); } if (message.equals("false")) { eventCache = null; } else { JSONObject j1 = null; try { j1 = new JSONObject(message); if (j1.getInt("status") == 500) { eventCache = null; } else { JSONArray eventArray = j1.getJSONArray("event_list"); if (io == 1) { //发起的事件 eventCache.put(type + "sponsorHistory", eventArray); } else if(io == 2){ //接受的事件 eventCache.put(type + "acceptedHistory", eventArray); }else{//关注的事件 eventCache.put(type + "concernHistory", eventArray); } for (int i = 0; i < eventArray.length(); i++) { int launcher_id = eventArray.getJSONObject(i).getInt("launcher_id"); String url = "http://120.24.208.130:1501/avatar/" + launcher_id + ".jpg"; Bitmap image = returnBitMap(url); if (image == null) { image = eventCache.getAsBitmap("morentouxiang"); } if (io == 1) { //发起的事件 eventCache.put(type + "sponsorHistory" + "touxiang" + i, image); } else if(io == 2){ //接受的事件 eventCache.put(type + "acceptedHistory" + "touxiang" + i, image); }else{//关注的事件 eventCache.put(type + "concernHistory" + "touxiang" + i, image); } } } } catch (JSONException e) { e.printStackTrace(); } } } }).start(); return eventCache; } public void setList(int io) { try { if (HisList == null) { item=new HashMap<String,Object>(); item.put("Avatar", R.drawable.icon); item.put("标题", "连接失败,请检查网络是否连接并重试"); item.put("用户", ""); item.put("时间", ""); item.put("悬赏", ""); list.add(item); } else { for (int i = 0; i < HisList.length(); i++) { item=new HashMap<String,Object>(); if (io == 1) { //发起的事件 item.put("Avatar", eventCache.getAsBitmap(type + "sponsorHistory" + "touxiang" + i)); } else if(io == 2){ //接受的事件 item.put("Avatar", eventCache.getAsBitmap(type + "acceptedHistory" + "touxiang" + i)); }else{//关注的事件 item.put("Avatar", eventCache.getAsBitmap(type + "" + "concernHistory" + "touxiang" + i)); } item.put("标题", HisList.getJSONObject(i).getString("title")); item.put("用户", HisList.getJSONObject(i).getString("launcher")); item.put("时间", HisList.getJSONObject(i).getString("time")); int state = HisList.getJSONObject(i).getInt("state"); if (state == 0) { item.put("悬赏", "进行中"); } else { item.put("悬赏", "已结束"); } list.add(item); } } } catch (JSONException e) { e.printStackTrace(); } } public Bitmap returnFirstBitMap(String url_){ final String url = url_; URL myFileUrl = null; try { myFileUrl = new URL(url); } catch (MalformedURLException e) { e.printStackTrace(); } try { HttpURLConnection conn = (HttpURLConnection) myFileUrl .openConnection(); conn.setDoInput(true); conn.connect(); InputStream is = conn.getInputStream(); bitmap = BitmapFactory.decodeStream(is); is.close(); } catch (IOException e) { e.printStackTrace(); } return bitmap; } public Bitmap returnBitMap(String url_){ final String url = url_; new Thread(new Runnable() { @Override public void run() { URL myFileUrl = null; try { myFileUrl = new URL(url); } catch (MalformedURLException e) { e.printStackTrace(); } try { HttpURLConnection conn = (HttpURLConnection) myFileUrl .openConnection(); conn.setDoInput(true); conn.connect(); InputStream is = conn.getInputStream(); bitmap = BitmapFactory.decodeStream(is); is.close(); } catch (IOException e) { e.printStackTrace(); } } }).start(); return bitmap; } public JSONArray getEventList() { return HisList; } public int getCount() {return list.size();} public Object getItem(int position) {return position;} public long getItemId(int position) {return position;} public View getView(int position, View convertView, ViewGroup parent) { //Avatar ImageView iv=new ImageView(context); RelativeLayout.LayoutParams lp_iv=new RelativeLayout.LayoutParams(80,80); lp_iv.addRule(RelativeLayout.ALIGN_PARENT_LEFT); iv.setLayoutParams(lp_iv); iv.setScaleType(ScaleType.CENTER_INSIDE); Bitmap image = ((Bitmap) (list.get(position)).get("Avatar")); if (image != null) { iv.setImageBitmap(image); } //标题 TextView title=new TextView(context); RelativeLayout.LayoutParams lp_tv=new RelativeLayout.LayoutParams(-2,-2); lp_tv.addRule(RelativeLayout.ALIGN_PARENT_LEFT); title.setLayoutParams(lp_tv); title.setTextSize(title.getTextSize()); title.setText((String) (list.get(position).get("标题"))); //用户 TextView user=new TextView(context); RelativeLayout.LayoutParams lp_sex=new RelativeLayout.LayoutParams(-2,-2); lp_sex.addRule(RelativeLayout.ALIGN_PARENT_LEFT); user.setLayoutParams(lp_sex); user.setText((String)(list.get(position).get("用户"))); //时间 TextView time=new TextView(context); RelativeLayout.LayoutParams lp_time=new RelativeLayout.LayoutParams(-2,-2); lp_sex.addRule(RelativeLayout.ALIGN_PARENT_LEFT); time.setLayoutParams(lp_sex); time.setText((String)(list.get(position).get("时间"))); //悬赏 TextView Reward=new TextView(context); RelativeLayout.LayoutParams lp_age=new RelativeLayout.LayoutParams(-2,-2); lp_age.addRule(RelativeLayout.ALIGN_PARENT_RIGHT); Reward.setLayoutParams(lp_age); Reward.setText((String) (list.get(position).get("悬赏"))); //线性布局1 LinearLayout l11=new LinearLayout(context); l11.setLayoutParams(new LinearLayout.LayoutParams(-1, -2)); l11.setOrientation(LinearLayout.VERTICAL); l11.addView(user); l11.addView(time); //线性布局2 LinearLayout l12=new LinearLayout(context); l12.setLayoutParams(new LinearLayout.LayoutParams(-1, -2)); l12.setOrientation(LinearLayout.HORIZONTAL); l12.addView(iv); l12.addView(l11); //相对布局1 RelativeLayout rl1=new RelativeLayout(context); rl1.setLayoutParams(new RelativeLayout.LayoutParams(-1, -2)); rl1.addView(l12); rl1.addView(Reward); //返回视图 final int margin = 16; ListView.LayoutParams params = new ListView.LayoutParams(ListView.LayoutParams.MATCH_PARENT, FrameLayout.LayoutParams.MATCH_PARENT); //params.setMargins(margin, margin, margin, margin); LinearLayout returnView=new LinearLayout(context); returnView.setLayoutParams(new ListView.LayoutParams(-1,-2));//注意:ListView.LayoutParams returnView.setOrientation(LinearLayout.VERTICAL); returnView.addView(rl1); returnView.addView(title); return returnView; } }
UTF-8
Java
16,766
java
HistoryAdapter.java
Java
[ { "context": "il.List;\nimport java.util.Map;\n\n\n/**\n * Created by gj on 2015/7/27.\n */\npublic class HistoryAdapter ext", "end": 1017, "score": 0.9995537996292114, "start": 1015, "tag": "USERNAME", "value": "gj" }, { "context": "tHandler.sendPostRequest(\n \"http://120.24.208.130:1501/event/query_launch\", jsonStrng);\n ret", "end": 2591, "score": 0.9868870377540588, "start": 2577, "tag": "IP_ADDRESS", "value": "120.24.208.130" }, { "context": "tHandler.sendPostRequest(\n \"http://120.24.208.130:1501/event/query_join\", jsonStrng);\n retur", "end": 2903, "score": 0.9882546663284302, "start": 2889, "tag": "IP_ADDRESS", "value": "120.24.208.130" }, { "context": "tHandler.sendPostRequest(\n \"http://120.24.208.130:1501/event/query_join\", jsonStrng);\n retur", "end": 3214, "score": 0.9615882039070129, "start": 3200, "tag": "IP_ADDRESS", "value": "120.24.208.130" }, { "context": "ang\") == null) {\n String url = \"http://120.24.208.130:1501/avatar/touxiang.jpg\";\n defaultPor", "end": 3452, "score": 0.9972923994064331, "start": 3438, "tag": "IP_ADDRESS", "value": "120.24.208.130" }, { "context": "d\");\n String url = \"http://120.24.208.130:1501/avatar/\" +\n a", "end": 5932, "score": 0.9992527961730957, "start": 5918, "tag": "IP_ADDRESS", "value": "120.24.208.130" }, { "context": " String url = \"http://120.24.208.130:1501/avatar/\" +\n ", "end": 8593, "score": 0.9996940493583679, "start": 8579, "tag": "IP_ADDRESS", "value": "120.24.208.130" } ]
null
[]
package com.ehelp.user.history; import android.content.Context; import android.graphics.Bitmap; import android.graphics.BitmapFactory; import android.os.StrictMode; import android.view.View; import android.view.ViewGroup; import android.widget.BaseAdapter; import android.widget.FrameLayout; import android.widget.ImageView; import android.widget.ImageView.ScaleType; import android.widget.LinearLayout; import android.widget.ListView; import android.widget.RelativeLayout; import android.widget.TextView; import com.ehelp.R; import com.ehelp.entity.Event; import com.ehelp.home.ACache; import com.ehelp.utils.RequestHandler; import com.google.gson.Gson; import org.json.JSONArray; import org.json.JSONException; import org.json.JSONObject; import java.io.IOException; import java.io.InputStream; import java.net.HttpURLConnection; import java.net.MalformedURLException; import java.net.URL; import java.util.ArrayList; import java.util.HashMap; import java.util.List; import java.util.Map; /** * Created by gj on 2015/7/27. */ public class HistoryAdapter extends BaseAdapter { private static final int REFRESH_COMPLETE = 2; private Context context=null; private List<Map<String,Object>> list = new ArrayList<Map<String,Object>>(); private Map<String,Object> item; private int user_id; private int type; private List<Event> events; private ACache eventCache; // event cache private Bitmap bitmap = null; private Bitmap defaultPortrait = null; private JSONArray HisList; Gson gson = new Gson(); HistoryAdapter(Context context, int id, int io, int type_, ACache eventCache_){ this.context=context; user_id = id; type = type_; eventCache = eventCache_; // 使用后台线程运行网络连接功能 StrictMode.setThreadPolicy( new StrictMode.ThreadPolicy.Builder(). detectDiskReads().detectDiskWrites().detectNetwork().penaltyLog().build()); StrictMode.setVmPolicy(new StrictMode.VmPolicy.Builder(). detectLeakedSqlLiteObjects().detectLeakedClosableObjects(). penaltyLog().penaltyDeath().build()); //数据初始化 init(io); } public void init(int io){ //数据初始化 getDefault(); getTitleList(io); setList(io); } //发起的 public String setListo() { //数据初始化 String jsonStrng = "{" + "\"id\":" + user_id + ",\"type\":" + type +"}"; String message = RequestHandler.sendPostRequest( "http://192.168.3.11:1501/event/query_launch", jsonStrng); return message; } //参与的 public String setListi() { //数据初始化 String jsonStrng = "{" + "\"id\":" + user_id + ",\"type\":2"+"}"; String message = RequestHandler.sendPostRequest( "http://192.168.3.11:1501/event/query_join", jsonStrng); return message; } //关注的 public String setListc() { //数据初始化 String jsonStrng = "{" + "\"id\":" + user_id + ",\"type\":1"+ "}"; String message = RequestHandler.sendPostRequest( "http://192.168.3.11:1501/event/query_join", jsonStrng); return message; } /* * 获取默认头像 * */ public void getDefault() { if (eventCache.getAsBitmap("morentouxiang") == null) { String url = "http://192.168.3.11:1501/avatar/touxiang.jpg"; defaultPortrait = returnFirstBitMap(url); eventCache.put("morentouxiang", defaultPortrait); } } /* * get cache as a list(for test only) * @param * @return a list contain cache */ public void getTitleList(int io){ if (io == 1) { //发起的事件 if (eventCache.getAsJSONArray(type + "sponsorHistory") == null) { getFirstRemoteTitleList(io); } else { HisList = eventCache.getAsJSONArray(type + "sponsorHistory"); } } else if(io == 2){ //接受的事件 if (eventCache.getAsJSONArray(type + "acceptedHistory") == null) { getFirstRemoteTitleList(io); } else { HisList = eventCache.getAsJSONArray(type + "acceptedHistory"); } }else {//关注的事件 if (eventCache.getAsJSONArray(type + "concernHistory") == null) { getFirstRemoteTitleList(io); } else { HisList = eventCache.getAsJSONArray(type + "concernHistory"); } } } /* * get events' titles from server as a list * only return title * @param * @return a list contains events' titles */ public ACache getFirstRemoteTitleList(int io){ String message; if (io == 1) { //发起的事件 message = setListo(); } else if(io == 2){ //接受的事件 message = setListi(); }else{//关注的事件 message = setListc(); } if (message.equals("false")) { eventCache = null; } else { JSONObject j1 = null; try { j1 = new JSONObject(message); if (j1.getInt("status") == 500) { eventCache = null; } else { JSONArray eventArray = j1.getJSONArray("event_list"); if (io == 1) { //发起的事件 eventCache.put(type + "sponsorHistory", eventArray); } else if(io == 2){ //接受的事件 eventCache.put(type + "acceptedHistory", eventArray); }else{//关注的事件 eventCache.put(type + "concernHistory", eventArray); } for (int i = 0; i < eventArray.length(); i++) { int auncher_id = eventArray.getJSONObject(i).getInt("launcher_id"); String url = "http://192.168.3.11:1501/avatar/" + auncher_id + ".jpg"; Bitmap image = returnFirstBitMap(url); if (image == null) { image = eventCache.getAsBitmap("morentouxiang"); } if (io == 1) { //发起的事件 eventCache.put(type + "sponsorHistory" + "touxiang" + i, image); } else if(io == 2){ //接受的事件 eventCache.put(type + "acceptedHistory" + "touxiang" + i, image); }else{//关注的事件 eventCache.put(type + "concernHistory" + "touxiang" + i, image); } } } } catch (JSONException e) { e.printStackTrace(); } } return eventCache; } /* * get events' titles from server as a list * only return title * @param * @return a list contains events' titles */ public ACache getRemoteTitleList(int type_, int io_){ final int type = type_; final int io = io_; new Thread(new Runnable() { @Override public void run() { String message; if (io == 1) { //发起的事件 message = setListo(); } else if(io == 2){ //接受的事件 message = setListi(); }else{//关注的事件 message = setListc(); } if (message.equals("false")) { eventCache = null; } else { JSONObject j1 = null; try { j1 = new JSONObject(message); if (j1.getInt("status") == 500) { eventCache = null; } else { JSONArray eventArray = j1.getJSONArray("event_list"); if (io == 1) { //发起的事件 eventCache.put(type + "sponsorHistory", eventArray); } else if(io == 2){ //接受的事件 eventCache.put(type + "acceptedHistory", eventArray); }else{//关注的事件 eventCache.put(type + "concernHistory", eventArray); } for (int i = 0; i < eventArray.length(); i++) { int launcher_id = eventArray.getJSONObject(i).getInt("launcher_id"); String url = "http://192.168.3.11:1501/avatar/" + launcher_id + ".jpg"; Bitmap image = returnBitMap(url); if (image == null) { image = eventCache.getAsBitmap("morentouxiang"); } if (io == 1) { //发起的事件 eventCache.put(type + "sponsorHistory" + "touxiang" + i, image); } else if(io == 2){ //接受的事件 eventCache.put(type + "acceptedHistory" + "touxiang" + i, image); }else{//关注的事件 eventCache.put(type + "concernHistory" + "touxiang" + i, image); } } } } catch (JSONException e) { e.printStackTrace(); } } } }).start(); return eventCache; } public void setList(int io) { try { if (HisList == null) { item=new HashMap<String,Object>(); item.put("Avatar", R.drawable.icon); item.put("标题", "连接失败,请检查网络是否连接并重试"); item.put("用户", ""); item.put("时间", ""); item.put("悬赏", ""); list.add(item); } else { for (int i = 0; i < HisList.length(); i++) { item=new HashMap<String,Object>(); if (io == 1) { //发起的事件 item.put("Avatar", eventCache.getAsBitmap(type + "sponsorHistory" + "touxiang" + i)); } else if(io == 2){ //接受的事件 item.put("Avatar", eventCache.getAsBitmap(type + "acceptedHistory" + "touxiang" + i)); }else{//关注的事件 item.put("Avatar", eventCache.getAsBitmap(type + "" + "concernHistory" + "touxiang" + i)); } item.put("标题", HisList.getJSONObject(i).getString("title")); item.put("用户", HisList.getJSONObject(i).getString("launcher")); item.put("时间", HisList.getJSONObject(i).getString("time")); int state = HisList.getJSONObject(i).getInt("state"); if (state == 0) { item.put("悬赏", "进行中"); } else { item.put("悬赏", "已结束"); } list.add(item); } } } catch (JSONException e) { e.printStackTrace(); } } public Bitmap returnFirstBitMap(String url_){ final String url = url_; URL myFileUrl = null; try { myFileUrl = new URL(url); } catch (MalformedURLException e) { e.printStackTrace(); } try { HttpURLConnection conn = (HttpURLConnection) myFileUrl .openConnection(); conn.setDoInput(true); conn.connect(); InputStream is = conn.getInputStream(); bitmap = BitmapFactory.decodeStream(is); is.close(); } catch (IOException e) { e.printStackTrace(); } return bitmap; } public Bitmap returnBitMap(String url_){ final String url = url_; new Thread(new Runnable() { @Override public void run() { URL myFileUrl = null; try { myFileUrl = new URL(url); } catch (MalformedURLException e) { e.printStackTrace(); } try { HttpURLConnection conn = (HttpURLConnection) myFileUrl .openConnection(); conn.setDoInput(true); conn.connect(); InputStream is = conn.getInputStream(); bitmap = BitmapFactory.decodeStream(is); is.close(); } catch (IOException e) { e.printStackTrace(); } } }).start(); return bitmap; } public JSONArray getEventList() { return HisList; } public int getCount() {return list.size();} public Object getItem(int position) {return position;} public long getItemId(int position) {return position;} public View getView(int position, View convertView, ViewGroup parent) { //Avatar ImageView iv=new ImageView(context); RelativeLayout.LayoutParams lp_iv=new RelativeLayout.LayoutParams(80,80); lp_iv.addRule(RelativeLayout.ALIGN_PARENT_LEFT); iv.setLayoutParams(lp_iv); iv.setScaleType(ScaleType.CENTER_INSIDE); Bitmap image = ((Bitmap) (list.get(position)).get("Avatar")); if (image != null) { iv.setImageBitmap(image); } //标题 TextView title=new TextView(context); RelativeLayout.LayoutParams lp_tv=new RelativeLayout.LayoutParams(-2,-2); lp_tv.addRule(RelativeLayout.ALIGN_PARENT_LEFT); title.setLayoutParams(lp_tv); title.setTextSize(title.getTextSize()); title.setText((String) (list.get(position).get("标题"))); //用户 TextView user=new TextView(context); RelativeLayout.LayoutParams lp_sex=new RelativeLayout.LayoutParams(-2,-2); lp_sex.addRule(RelativeLayout.ALIGN_PARENT_LEFT); user.setLayoutParams(lp_sex); user.setText((String)(list.get(position).get("用户"))); //时间 TextView time=new TextView(context); RelativeLayout.LayoutParams lp_time=new RelativeLayout.LayoutParams(-2,-2); lp_sex.addRule(RelativeLayout.ALIGN_PARENT_LEFT); time.setLayoutParams(lp_sex); time.setText((String)(list.get(position).get("时间"))); //悬赏 TextView Reward=new TextView(context); RelativeLayout.LayoutParams lp_age=new RelativeLayout.LayoutParams(-2,-2); lp_age.addRule(RelativeLayout.ALIGN_PARENT_RIGHT); Reward.setLayoutParams(lp_age); Reward.setText((String) (list.get(position).get("悬赏"))); //线性布局1 LinearLayout l11=new LinearLayout(context); l11.setLayoutParams(new LinearLayout.LayoutParams(-1, -2)); l11.setOrientation(LinearLayout.VERTICAL); l11.addView(user); l11.addView(time); //线性布局2 LinearLayout l12=new LinearLayout(context); l12.setLayoutParams(new LinearLayout.LayoutParams(-1, -2)); l12.setOrientation(LinearLayout.HORIZONTAL); l12.addView(iv); l12.addView(l11); //相对布局1 RelativeLayout rl1=new RelativeLayout(context); rl1.setLayoutParams(new RelativeLayout.LayoutParams(-1, -2)); rl1.addView(l12); rl1.addView(Reward); //返回视图 final int margin = 16; ListView.LayoutParams params = new ListView.LayoutParams(ListView.LayoutParams.MATCH_PARENT, FrameLayout.LayoutParams.MATCH_PARENT); //params.setMargins(margin, margin, margin, margin); LinearLayout returnView=new LinearLayout(context); returnView.setLayoutParams(new ListView.LayoutParams(-1,-2));//注意:ListView.LayoutParams returnView.setOrientation(LinearLayout.VERTICAL); returnView.addView(rl1); returnView.addView(title); return returnView; } }
16,754
0.511372
0.499816
451
35.07317
24.666134
140
false
false
0
0
0
0
0
0
0.618625
false
false
9
26d73840b0c4d9bb1fcb03acd3e4afb20790b2ec
4,329,327,070,931
6b9575eb4b30fa8c4252139927bf6e9c5f15d3ca
/app/src/main/java/de/fzi/dream/ploc/ui/fragment/FeedbackRatingFragment.java
6754ba99fc16361f8edf44bd157d928dd283ea91
[ "BSD-3-Clause", "Apache-2.0" ]
permissive
fzi-forschungszentrum-informatik/dream-ploc
https://github.com/fzi-forschungszentrum-informatik/dream-ploc
a6901e2b6265f641b5567e7ac230f361d3bc5eb9
d795486ae4b228176ec1666ee507e3fdf6d51a63
refs/heads/master
2020-12-06T03:15:24.212000
2020-01-17T15:23:14
2020-01-17T15:23:14
232,323,920
3
0
null
null
null
null
null
null
null
null
null
null
null
null
null
package de.fzi.dream.ploc.ui.fragment; import android.os.Bundle; import android.view.LayoutInflater; import android.view.Menu; import android.view.MenuInflater; import android.view.View; import android.view.ViewGroup; import android.widget.CheckBox; import androidx.fragment.app.Fragment; import androidx.lifecycle.ViewModelProvider; import com.google.android.material.button.MaterialButton; import com.google.android.material.snackbar.Snackbar; import de.fzi.dream.ploc.R; import de.fzi.dream.ploc.data.structure.Feedback; import de.fzi.dream.ploc.ui.activity.FeedbackActivity; import de.fzi.dream.ploc.utility.Constants; import de.fzi.dream.ploc.utility.Notification; import de.fzi.dream.ploc.viewmodel.FeedbackPreviewViewModel; /** * The FeedbackRatingFragment is embedded in the {@link FeedbackActivity} and displays the rating page * for writing a feedback for a specific paper. * * @author Felix Melcher */ public class FeedbackRatingFragment extends Fragment { /** * Public class identifier tag */ public static final String TAG = FeedbackRatingFragment.class.getSimpleName(); // Parameters private int mRecordID; // ViewModel private FeedbackPreviewViewModel mViewModel; // View private CheckBox mRelevance; private CheckBox mPresentation; private CheckBox mMethodology; /** * Fragments require an empty public constructor. */ public FeedbackRatingFragment() { } /** * Use this factory method to create a new instance of * this fragment using the provided parameters. * * @param recordID ID of the record to write a feedback for. * @return A new instance of fragment FeedbackRatingFragment. */ public static FeedbackRatingFragment newInstance(int recordID) { FeedbackRatingFragment fragment = new FeedbackRatingFragment(); Bundle args = new Bundle(); args.putInt(Constants.EXTRA_ID, recordID); fragment.setArguments(args); return fragment; } /* * Lifecycle Methods */ @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); if (getArguments() != null) { mRecordID = getArguments().getInt(Constants.EXTRA_ID); } setHasOptionsMenu(true); mViewModel = obtainViewModel(); observeNotifications(); } @Override public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) { View rootView = inflater.inflate(R.layout.fragment_feedback_rating, container, false); MaterialButton button = rootView.findViewById(R.id.button_save_feedback_rating_fragment); mRelevance = rootView.findViewById(R.id.check_box_relevance_rating_fragment); mPresentation = rootView.findViewById(R.id.check_box_presentation_rating_fragment); mMethodology = rootView.findViewById(R.id.check_box_methodology_rating_fragment); button.setOnClickListener(view1 -> mViewModel.createFeedback(new Feedback(mRecordID, mRelevance.isChecked(), mPresentation.isChecked(), mMethodology.isChecked()))); return rootView; } @Override public void onCreateOptionsMenu(Menu menu, MenuInflater inflater) { menu.clear(); inflater.inflate(R.menu.activity_feedback_rating_toolbar, menu); super.onCreateOptionsMenu(menu, inflater); } /* * ViewModel Methods */ /** * Obtain the ViewModel instance responsible for getting the data from the remote or local * data source. * * @return FeedbackPreviewViewModel */ private FeedbackPreviewViewModel obtainViewModel() { return new ViewModelProvider(this).get(FeedbackPreviewViewModel.class); } /** * Observe and react to new notifications form the ViewModel. */ private void observeNotifications() { mViewModel.getNotificationMessage().observe(this, message -> { if (message != null) { showSnackbar(message); } }); } /* * Fragment specific helper methods */ /** * Show a snackbar within the current fragment. * * @param notification The notification to display in the snackbar. */ private void showSnackbar(Notification notification) { Snackbar snackbar = Snackbar .make((getActivity()).findViewById(R.id.feedback_rating_layout), notification.getMessage(), Snackbar.LENGTH_SHORT); snackbar.addCallback(new Snackbar.Callback() { @Override public void onDismissed(Snackbar snackbar, int event) { getActivity().onBackPressed(); } @Override public void onShown(Snackbar snackbar) { } }); snackbar.show(); } }
UTF-8
Java
5,047
java
FeedbackRatingFragment.java
Java
[ { "context": "g a feedback for a specific paper.\r\n *\r\n * @author Felix Melcher\r\n */\r\npublic class FeedbackRatingFragment extends", "end": 947, "score": 0.999674379825592, "start": 934, "tag": "NAME", "value": "Felix Melcher" } ]
null
[]
package de.fzi.dream.ploc.ui.fragment; import android.os.Bundle; import android.view.LayoutInflater; import android.view.Menu; import android.view.MenuInflater; import android.view.View; import android.view.ViewGroup; import android.widget.CheckBox; import androidx.fragment.app.Fragment; import androidx.lifecycle.ViewModelProvider; import com.google.android.material.button.MaterialButton; import com.google.android.material.snackbar.Snackbar; import de.fzi.dream.ploc.R; import de.fzi.dream.ploc.data.structure.Feedback; import de.fzi.dream.ploc.ui.activity.FeedbackActivity; import de.fzi.dream.ploc.utility.Constants; import de.fzi.dream.ploc.utility.Notification; import de.fzi.dream.ploc.viewmodel.FeedbackPreviewViewModel; /** * The FeedbackRatingFragment is embedded in the {@link FeedbackActivity} and displays the rating page * for writing a feedback for a specific paper. * * @author <NAME> */ public class FeedbackRatingFragment extends Fragment { /** * Public class identifier tag */ public static final String TAG = FeedbackRatingFragment.class.getSimpleName(); // Parameters private int mRecordID; // ViewModel private FeedbackPreviewViewModel mViewModel; // View private CheckBox mRelevance; private CheckBox mPresentation; private CheckBox mMethodology; /** * Fragments require an empty public constructor. */ public FeedbackRatingFragment() { } /** * Use this factory method to create a new instance of * this fragment using the provided parameters. * * @param recordID ID of the record to write a feedback for. * @return A new instance of fragment FeedbackRatingFragment. */ public static FeedbackRatingFragment newInstance(int recordID) { FeedbackRatingFragment fragment = new FeedbackRatingFragment(); Bundle args = new Bundle(); args.putInt(Constants.EXTRA_ID, recordID); fragment.setArguments(args); return fragment; } /* * Lifecycle Methods */ @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); if (getArguments() != null) { mRecordID = getArguments().getInt(Constants.EXTRA_ID); } setHasOptionsMenu(true); mViewModel = obtainViewModel(); observeNotifications(); } @Override public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) { View rootView = inflater.inflate(R.layout.fragment_feedback_rating, container, false); MaterialButton button = rootView.findViewById(R.id.button_save_feedback_rating_fragment); mRelevance = rootView.findViewById(R.id.check_box_relevance_rating_fragment); mPresentation = rootView.findViewById(R.id.check_box_presentation_rating_fragment); mMethodology = rootView.findViewById(R.id.check_box_methodology_rating_fragment); button.setOnClickListener(view1 -> mViewModel.createFeedback(new Feedback(mRecordID, mRelevance.isChecked(), mPresentation.isChecked(), mMethodology.isChecked()))); return rootView; } @Override public void onCreateOptionsMenu(Menu menu, MenuInflater inflater) { menu.clear(); inflater.inflate(R.menu.activity_feedback_rating_toolbar, menu); super.onCreateOptionsMenu(menu, inflater); } /* * ViewModel Methods */ /** * Obtain the ViewModel instance responsible for getting the data from the remote or local * data source. * * @return FeedbackPreviewViewModel */ private FeedbackPreviewViewModel obtainViewModel() { return new ViewModelProvider(this).get(FeedbackPreviewViewModel.class); } /** * Observe and react to new notifications form the ViewModel. */ private void observeNotifications() { mViewModel.getNotificationMessage().observe(this, message -> { if (message != null) { showSnackbar(message); } }); } /* * Fragment specific helper methods */ /** * Show a snackbar within the current fragment. * * @param notification The notification to display in the snackbar. */ private void showSnackbar(Notification notification) { Snackbar snackbar = Snackbar .make((getActivity()).findViewById(R.id.feedback_rating_layout), notification.getMessage(), Snackbar.LENGTH_SHORT); snackbar.addCallback(new Snackbar.Callback() { @Override public void onDismissed(Snackbar snackbar, int event) { getActivity().onBackPressed(); } @Override public void onShown(Snackbar snackbar) { } }); snackbar.show(); } }
5,040
0.658411
0.658213
153
30.986929
30.034401
172
false
false
0
0
0
0
0
0
0.431373
false
false
9
fabe4783655e1018b4f0c0ad9e9ab38efeed8c81
3,805,341,028,071
614db4d6793b4c0951479021070510f3ded528a7
/java/Sin sprites/Tetris_bueno/src/tetris/Tetris.java
d2572c02efc58015a3ac268201019de6f4a6e636
[]
no_license
pablo-rr/java_2ev
https://github.com/pablo-rr/java_2ev
6352ecfc1e661fbf352d97c3dd1f863416f6f079
fd98ce7b6aa7519e2bacda04d515b7f792d0f559
refs/heads/master
2020-05-02T23:22:30.265000
2019-03-28T20:43:26
2019-03-28T20:43:26
178,276,814
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
package tetris; import java.awt.Frame; import java.awt.Graphics; import java.util.Random; public class Tetris extends Frame implements Runnable{ int resolutionX, resolutionY; Thread game; Figure figures[]; Figure figure; Random randomGenerator; public static void main(String args[]){ Tetris app = new Tetris(); } public Tetris(){ super("T E T R I S"); setup(); pack(); resize(resolutionX, resolutionY); show(); } public void setup(){ setupFrame(); setupGame(); setupThread(); } public void setupFrame(){ setResizable(false); } public void setupGame(){ resolutionX = 400; resolutionY = 800; } public void setupThread(){ game = new Thread(this); game.start(); } public void paint(Graphics g) { //figure.drawFigure(g); } public void run(){ do{ try{ Thread.sleep(1000); } catch (InterruptedException IE) { } figure.updateFigure(); repaint(); }while(true); } }
UTF-8
Java
1,198
java
Tetris.java
Java
[]
null
[]
package tetris; import java.awt.Frame; import java.awt.Graphics; import java.util.Random; public class Tetris extends Frame implements Runnable{ int resolutionX, resolutionY; Thread game; Figure figures[]; Figure figure; Random randomGenerator; public static void main(String args[]){ Tetris app = new Tetris(); } public Tetris(){ super("T E T R I S"); setup(); pack(); resize(resolutionX, resolutionY); show(); } public void setup(){ setupFrame(); setupGame(); setupThread(); } public void setupFrame(){ setResizable(false); } public void setupGame(){ resolutionX = 400; resolutionY = 800; } public void setupThread(){ game = new Thread(this); game.start(); } public void paint(Graphics g) { //figure.drawFigure(g); } public void run(){ do{ try{ Thread.sleep(1000); } catch (InterruptedException IE) { } figure.updateFigure(); repaint(); }while(true); } }
1,198
0.520033
0.511686
60
18.966667
13.07028
54
false
false
0
0
0
0
0
0
0.5
false
false
9
c718173edc9fdea2346da3b383b3f6487ce86736
31,181,462,624,648
4cac9ad7d99efc5df7e6451b38dcb2f5f6fc5030
/Zork Assignment/src/com/bayviewglen/zork/Weapon.java
ddd40ab450debe247fdcfc2f7be3cbc291b43229
[]
no_license
AlbertPangilinan-zz/Zork-Art-Offline
https://github.com/AlbertPangilinan-zz/Zork-Art-Offline
30b695ba523976ff60d41d91a3294c16647f6c28
b0ab7b1e0f75345a84c4b5700901ca37d1daa036
refs/heads/master
2021-03-27T16:59:54.891000
2015-06-13T02:40:53
2015-06-13T02:40:53
null
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
package com.bayviewglen.zork; import java.io.Serializable; @SuppressWarnings("serial") public class Weapon extends Item implements Serializable { private int minDamage; private int maxDamage; private int damageRange; public Weapon() { super(); this.minDamage = 1; this.maxDamage = 2; this.damageRange = 2; } public Weapon(String name, int weight, int minDamage, int maxDamage, int damageRange) { super(name, weight); this.minDamage = minDamage; this.maxDamage = maxDamage; this.damageRange = damageRange; } public void setMinDamage(int minDamage) { this.minDamage = minDamage; } public int getMinDamage() { return this.minDamage; } public void setMaxDamage(int maxDamage) { this.maxDamage = maxDamage; } public int getMaxDamage() { return this.maxDamage; } public void setDamageRange(int damageRange) { this.damageRange = damageRange; } public int getDamageRange() { return this.damageRange; } public boolean isWeapon() { return true; } }
UTF-8
Java
1,057
java
Weapon.java
Java
[]
null
[]
package com.bayviewglen.zork; import java.io.Serializable; @SuppressWarnings("serial") public class Weapon extends Item implements Serializable { private int minDamage; private int maxDamage; private int damageRange; public Weapon() { super(); this.minDamage = 1; this.maxDamage = 2; this.damageRange = 2; } public Weapon(String name, int weight, int minDamage, int maxDamage, int damageRange) { super(name, weight); this.minDamage = minDamage; this.maxDamage = maxDamage; this.damageRange = damageRange; } public void setMinDamage(int minDamage) { this.minDamage = minDamage; } public int getMinDamage() { return this.minDamage; } public void setMaxDamage(int maxDamage) { this.maxDamage = maxDamage; } public int getMaxDamage() { return this.maxDamage; } public void setDamageRange(int damageRange) { this.damageRange = damageRange; } public int getDamageRange() { return this.damageRange; } public boolean isWeapon() { return true; } }
1,057
0.68685
0.684011
54
17.574074
17.891237
88
false
false
0
0
0
0
0
0
1.407407
false
false
9
ff8659e3e69ad04b07878df0bf500a5c733e8bf8
6,846,177,937,003
eb5b39d63bcb0d0c54b2175b8379c65ff6f44046
/src/main/java/com/involves/desafio/entity/Representante.java
cf36e0812d3d5e9a29bba87dc89e54db328f7327
[]
no_license
gthiesen/desafio-involves
https://github.com/gthiesen/desafio-involves
8b62d9b6b3b2edba81b349a16c4c8d0b196e924e
bb3f07d861523be9cbe64dc85bc2aecfc6abadc6
refs/heads/master
2020-05-05T12:53:54.243000
2019-04-08T14:21:28
2019-04-08T14:21:28
180,050,054
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
package com.involves.desafio.entity; import java.util.Date; import java.util.List; import javax.persistence.Entity; import javax.persistence.GeneratedValue; import javax.persistence.Id; import javax.persistence.OneToMany; import javax.persistence.OrderBy; import javax.persistence.SequenceGenerator; import javax.persistence.Table; @Entity @Table(name="tbl_representante") @SequenceGenerator(name = "seq_representante", sequenceName = "seq_representante", allocationSize = 1, initialValue = 1) public class Representante extends DesafioEntity { @Id @GeneratedValue(generator="seq_representante") private Long id; private String nome; private Double latitude; private Double longitude; private Date dataRemocao; // Atributo de remoção lógica; @OneToMany(mappedBy="representante") @OrderBy("nome ASC") private List<Loja> lojas; @OneToMany(mappedBy="representante") @OrderBy("distancia ASC") private List<RepresentanteLoja> lojasProximas; public String getNome() { return nome; } public void setNome(String nome) { this.nome = nome; } public Long getId() { return id; } public void setId(Long id) { this.id = id; } public Double getLatitude() { return latitude; } public void setLatitude(Double latitude) { this.latitude = latitude; } public Double getLongitude() { return longitude; } public void setLongitude(Double longitude) { this.longitude = longitude; } public List<Loja> getLojas() { return lojas; } public void setLojas(List<Loja> lojas) { this.lojas = lojas; } public List<RepresentanteLoja> getLojasProximas() { return lojasProximas; } public void setLojasProximas(List<RepresentanteLoja> lojasProximas) { this.lojasProximas = lojasProximas; } public Date getDataRemocao() { return dataRemocao; } public void setDataRemocao(Date dataRemocao) { this.dataRemocao = dataRemocao; } }
UTF-8
Java
1,891
java
Representante.java
Java
[]
null
[]
package com.involves.desafio.entity; import java.util.Date; import java.util.List; import javax.persistence.Entity; import javax.persistence.GeneratedValue; import javax.persistence.Id; import javax.persistence.OneToMany; import javax.persistence.OrderBy; import javax.persistence.SequenceGenerator; import javax.persistence.Table; @Entity @Table(name="tbl_representante") @SequenceGenerator(name = "seq_representante", sequenceName = "seq_representante", allocationSize = 1, initialValue = 1) public class Representante extends DesafioEntity { @Id @GeneratedValue(generator="seq_representante") private Long id; private String nome; private Double latitude; private Double longitude; private Date dataRemocao; // Atributo de remoção lógica; @OneToMany(mappedBy="representante") @OrderBy("nome ASC") private List<Loja> lojas; @OneToMany(mappedBy="representante") @OrderBy("distancia ASC") private List<RepresentanteLoja> lojasProximas; public String getNome() { return nome; } public void setNome(String nome) { this.nome = nome; } public Long getId() { return id; } public void setId(Long id) { this.id = id; } public Double getLatitude() { return latitude; } public void setLatitude(Double latitude) { this.latitude = latitude; } public Double getLongitude() { return longitude; } public void setLongitude(Double longitude) { this.longitude = longitude; } public List<Loja> getLojas() { return lojas; } public void setLojas(List<Loja> lojas) { this.lojas = lojas; } public List<RepresentanteLoja> getLojasProximas() { return lojasProximas; } public void setLojasProximas(List<RepresentanteLoja> lojasProximas) { this.lojasProximas = lojasProximas; } public Date getDataRemocao() { return dataRemocao; } public void setDataRemocao(Date dataRemocao) { this.dataRemocao = dataRemocao; } }
1,891
0.745763
0.744703
95
18.873684
20.23246
120
false
false
0
0
0
0
0
0
1.157895
false
false
9
1a6c99778e0885fbbf3d00c44de09727855ea009
14,053,133,041,496
ce82a1a8d565f3d1cec2557bf4575ad8d3006bd0
/schema-wizard/src/main/java/com/deleidos/sw/realms/H2Realm.java
36800227d2572da87a7dac43576a779603f03675
[ "Apache-2.0", "MIT" ]
permissive
deleidos/de-schema-wizard
https://github.com/deleidos/de-schema-wizard
772ecbd40875ac5dd5f0a31a305be4cf59669415
644d3a48b5356590f3bf0d4758d62a7ce3458270
refs/heads/master
2020-05-22T01:14:03.283000
2017-03-15T18:13:11
2017-03-15T18:13:11
60,182,702
1
3
null
false
2016-08-26T20:03:16
2016-06-01T14:11:29
2016-07-23T20:01:57
2016-08-26T20:03:16
11,670
1
1
0
Java
null
null
package com.deleidos.sw.realms; import java.util.Set; import org.apache.log4j.Logger; import org.apache.shiro.authc.AccountException; import org.apache.shiro.authc.AuthenticationException; import org.apache.shiro.authc.AuthenticationInfo; import org.apache.shiro.authc.AuthenticationToken; import org.apache.shiro.authc.SimpleAuthenticationInfo; import org.apache.shiro.authc.UnknownAccountException; import org.apache.shiro.authc.UsernamePasswordToken; import org.apache.shiro.authz.AuthorizationException; import org.apache.shiro.authz.AuthorizationInfo; import org.apache.shiro.authz.SimpleAuthorizationInfo; import org.apache.shiro.realm.jdbc.JdbcRealm; import org.apache.shiro.subject.PrincipalCollection; import org.apache.shiro.util.SimpleByteSource; import com.deleidos.dmf.accessor.ServiceLayerAccessor; import com.deleidos.dp.beans.User; import com.deleidos.dp.exceptions.H2DataAccessException; /** * An extension of Shiro's default JDBC realm. This class was customized to use * the Schema Wizard standard data access protocols. * * @author yoonj1 * */ public class H2Realm extends JdbcRealm { ServiceLayerAccessor sla = new ServiceLayerAccessor(); private static Logger logger = Logger.getLogger(H2Realm.class); public H2Realm() { setSaltStyle(SaltStyle.COLUMN); } /** * Authenticates a user with a given token. Passwords are encrypted with * SHA-256 hashing. */ @Override protected AuthenticationInfo doGetAuthenticationInfo(AuthenticationToken token) throws AuthenticationException { UsernamePasswordToken upToken = (UsernamePasswordToken) token; String username = upToken.getUsername(); SimpleAuthenticationInfo info = null; try { User user= sla.getPasswordForUser(username); // Null username is invalid if (username == null) { logger.error("Null usernames are not allowed."); throw new AccountException("Null usernames are not allowed by this realm."); } if (user.getPassword() == null) { logger.error("No account found for user: " + username + ".'"); throw new UnknownAccountException("No account found for user [" + username + "]"); } info = new SimpleAuthenticationInfo(username, user.getPassword(), getName()); if (user.getSalt() != null) { info.setCredentialsSalt(new SimpleByteSource(user.getSalt())); } return info; } catch (H2DataAccessException e) { logger.error(e.getMessage()); throw new AuthorizationException("Error querying H2 for the user's password."); } } @Override /** * Responsible for checking roles and permissions of a user (principal). */ protected AuthorizationInfo doGetAuthorizationInfo(PrincipalCollection principals) { // null usernames are invalid if (principals == null) { throw new AuthorizationException("PrincipalCollection method argument cannot be null."); } String username = (String) getAvailablePrincipal(principals); try { Set<String> roleNames = sla.getRoleNamesForUser(username); Set<String> permissions = sla.getPermissions(username, roleNames); SimpleAuthorizationInfo info = new SimpleAuthorizationInfo(roleNames); info.setStringPermissions(permissions); return info; } catch (H2DataAccessException e) { logger.error(e.getMessage()); throw new AuthorizationException("Error querying H2 for role names and permissions."); } } }
UTF-8
Java
3,341
java
H2Realm.java
Java
[ { "context": "ard standard data access protocols.\n * \n * @author yoonj1\n *\n */\npublic class H2Realm extends JdbcRealm {\n\t", "end": 1067, "score": 0.9996598362922668, "start": 1061, "tag": "USERNAME", "value": "yoonj1" } ]
null
[]
package com.deleidos.sw.realms; import java.util.Set; import org.apache.log4j.Logger; import org.apache.shiro.authc.AccountException; import org.apache.shiro.authc.AuthenticationException; import org.apache.shiro.authc.AuthenticationInfo; import org.apache.shiro.authc.AuthenticationToken; import org.apache.shiro.authc.SimpleAuthenticationInfo; import org.apache.shiro.authc.UnknownAccountException; import org.apache.shiro.authc.UsernamePasswordToken; import org.apache.shiro.authz.AuthorizationException; import org.apache.shiro.authz.AuthorizationInfo; import org.apache.shiro.authz.SimpleAuthorizationInfo; import org.apache.shiro.realm.jdbc.JdbcRealm; import org.apache.shiro.subject.PrincipalCollection; import org.apache.shiro.util.SimpleByteSource; import com.deleidos.dmf.accessor.ServiceLayerAccessor; import com.deleidos.dp.beans.User; import com.deleidos.dp.exceptions.H2DataAccessException; /** * An extension of Shiro's default JDBC realm. This class was customized to use * the Schema Wizard standard data access protocols. * * @author yoonj1 * */ public class H2Realm extends JdbcRealm { ServiceLayerAccessor sla = new ServiceLayerAccessor(); private static Logger logger = Logger.getLogger(H2Realm.class); public H2Realm() { setSaltStyle(SaltStyle.COLUMN); } /** * Authenticates a user with a given token. Passwords are encrypted with * SHA-256 hashing. */ @Override protected AuthenticationInfo doGetAuthenticationInfo(AuthenticationToken token) throws AuthenticationException { UsernamePasswordToken upToken = (UsernamePasswordToken) token; String username = upToken.getUsername(); SimpleAuthenticationInfo info = null; try { User user= sla.getPasswordForUser(username); // Null username is invalid if (username == null) { logger.error("Null usernames are not allowed."); throw new AccountException("Null usernames are not allowed by this realm."); } if (user.getPassword() == null) { logger.error("No account found for user: " + username + ".'"); throw new UnknownAccountException("No account found for user [" + username + "]"); } info = new SimpleAuthenticationInfo(username, user.getPassword(), getName()); if (user.getSalt() != null) { info.setCredentialsSalt(new SimpleByteSource(user.getSalt())); } return info; } catch (H2DataAccessException e) { logger.error(e.getMessage()); throw new AuthorizationException("Error querying H2 for the user's password."); } } @Override /** * Responsible for checking roles and permissions of a user (principal). */ protected AuthorizationInfo doGetAuthorizationInfo(PrincipalCollection principals) { // null usernames are invalid if (principals == null) { throw new AuthorizationException("PrincipalCollection method argument cannot be null."); } String username = (String) getAvailablePrincipal(principals); try { Set<String> roleNames = sla.getRoleNamesForUser(username); Set<String> permissions = sla.getPermissions(username, roleNames); SimpleAuthorizationInfo info = new SimpleAuthorizationInfo(roleNames); info.setStringPermissions(permissions); return info; } catch (H2DataAccessException e) { logger.error(e.getMessage()); throw new AuthorizationException("Error querying H2 for role names and permissions."); } } }
3,341
0.762945
0.759054
101
32.089108
28.945528
113
false
false
0
0
0
0
0
0
1.70297
false
false
9
d4523ce17e6d06e6b7e7102d7fca0b9f0013f248
21,199,958,619,806
908e1f2dfd7b2ec9a510ef54e245fa379188da2a
/trunk/muzi-system/src/main/java/com/muzi/design/strategy/PriceOne.java
e230348e82efb468933c7314c90fd3002a53e8c7
[]
no_license
muzi-jiang/muzi
https://github.com/muzi-jiang/muzi
4c1d963e3952fe14b867d34880a14f4cfe9717fb
fcc8791a50c16d6160b84cc5795912d92595197f
refs/heads/master
2022-12-26T07:22:22.556000
2020-12-16T07:39:26
2020-12-16T07:39:26
220,027,459
1
0
null
null
null
null
null
null
null
null
null
null
null
null
null
package com.muzi.design.strategy; import java.math.BigDecimal; /** * 1000以内不打折 */ @PriceRegion(max = 1000) public class PriceOne implements Price { @Override public BigDecimal getPrice(BigDecimal bigDecimal) { return bigDecimal; } }
UTF-8
Java
267
java
PriceOne.java
Java
[]
null
[]
package com.muzi.design.strategy; import java.math.BigDecimal; /** * 1000以内不打折 */ @PriceRegion(max = 1000) public class PriceOne implements Price { @Override public BigDecimal getPrice(BigDecimal bigDecimal) { return bigDecimal; } }
267
0.70428
0.673152
14
17.357143
16.667364
55
false
false
0
0
0
0
0
0
0.214286
false
false
9
e07c2a28a6072e9d184352694eb3daf96a232bbc
26,001,732,065,895
72c03e7b32c8216cf772d92ce10fbd161e833f3c
/K-BA-Android/app/src/main/java/projet/k_ba/network/NetworkGetTask.java
230afa82a0b890187950c7e7ced09dd926db84ed
[]
no_license
lyrocs-etna/K-BA
https://github.com/lyrocs-etna/K-BA
2db91fc776a424b5cf32612f447e6e904d0c81ae
1cb63e3b543987484afcfb2771a4e348e7e127df
refs/heads/master
2019-01-25T01:06:08.704000
2017-07-20T13:31:10
2017-07-20T13:31:10
97,837,791
0
0
null
true
2017-07-20T13:19:59
2017-07-20T13:19:59
2017-05-17T17:16:23
2017-07-18T17:05:35
14,189
0
0
0
null
null
null
package projet.k_ba.network; import android.os.AsyncTask; import android.util.Log; /** * Created by candice on 16/07/2017. */ public class NetworkGetTask extends AsyncTask<String, Void, NetworkResponse> { private INetworkListener listener; public NetworkGetTask(INetworkListener listener) { this.listener = listener; } @Override protected NetworkResponse doInBackground(String... url) { try { return WebService.get(url[0]); } catch (Exception e) { Log.e("Network", "GET", e); return null; } } @Override protected void onPostExecute(NetworkResponse nr) { this.listener.onComplete(nr); } }
UTF-8
Java
709
java
NetworkGetTask.java
Java
[ { "context": "cTask;\nimport android.util.Log;\n\n/**\n * Created by candice on 16/07/2017.\n */\npublic class NetworkGetTask ex", "end": 110, "score": 0.9996411204338074, "start": 103, "tag": "USERNAME", "value": "candice" } ]
null
[]
package projet.k_ba.network; import android.os.AsyncTask; import android.util.Log; /** * Created by candice on 16/07/2017. */ public class NetworkGetTask extends AsyncTask<String, Void, NetworkResponse> { private INetworkListener listener; public NetworkGetTask(INetworkListener listener) { this.listener = listener; } @Override protected NetworkResponse doInBackground(String... url) { try { return WebService.get(url[0]); } catch (Exception e) { Log.e("Network", "GET", e); return null; } } @Override protected void onPostExecute(NetworkResponse nr) { this.listener.onComplete(nr); } }
709
0.634697
0.622003
32
21.15625
21.035847
78
false
false
0
0
0
0
0
0
0.40625
false
false
9
58be2e50a3ae2de2282232644829a45f39089f21
7,267,084,713,799
7e3a37d4559c6426490104f244b942ef06069082
/src/main/java/com/zero/common/security/AuthUser.java
b0d5559fb639c97e9bcd2df17264e3b6df894c78
[]
no_license
LinXiuke/base-project
https://github.com/LinXiuke/base-project
ad997d39ad0b36776bb63cfd212f1e1d01bd3404
95fd6528f3c2aae60d53ebeaf252b9a4d03554e1
refs/heads/master
2023-07-25T17:56:01.769000
2020-02-13T05:54:30
2020-02-13T05:54:30
149,122,725
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
package com.zero.common.security; import lombok.Data; /** * @Description: */ @Data public class AuthUser { private Long userId; private String username; private String openId; }
UTF-8
Java
198
java
AuthUser.java
Java
[]
null
[]
package com.zero.common.security; import lombok.Data; /** * @Description: */ @Data public class AuthUser { private Long userId; private String username; private String openId; }
198
0.681818
0.681818
17
10.647058
11.851737
33
false
false
0
0
0
0
0
0
0.294118
false
false
9
ade5aaec803c26610c488fd18ab606577a4ab52c
7,292,854,518,751
5f2b5eb147f845bd7b57b03f0412d4480f98c417
/src/main/java/isc/spring/annotation/MyAppConfig.java
e7bd9ff7ac0582065cf9dd0835c0293c0704a4f9
[]
no_license
ISC-Training/springcore
https://github.com/ISC-Training/springcore
8773bd3dc2f3072d2b2dc5bf5c709ceb532fcf48
97e6de270bee19bff35305790578c6cf8ebbc2a1
refs/heads/master
2023-01-27T17:29:38.001000
2020-12-05T10:58:12
2020-12-05T10:58:12
318,766,573
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
package isc.spring.annotation; import org.springframework.context.annotation.ComponentScan; import org.springframework.context.annotation.Configuration; @Configuration @ComponentScan({"isc.spring.annotation"}) public class MyAppConfig { }
UTF-8
Java
241
java
MyAppConfig.java
Java
[]
null
[]
package isc.spring.annotation; import org.springframework.context.annotation.ComponentScan; import org.springframework.context.annotation.Configuration; @Configuration @ComponentScan({"isc.spring.annotation"}) public class MyAppConfig { }
241
0.834025
0.834025
9
25.777779
22.787802
60
false
false
0
0
0
0
0
0
0.333333
false
false
9
203a9f1921e03120859e31a89d335a1f849614d7
17,394,617,606,366
b8ba5f560fc6898aacf776699f9eb4611a5d2a99
/core/src/main/java/com/axon/market/core/service/ishop/ShopTemporaryTaskService.java
0b04823af11665331e419675bf61a6486cad9211
[]
no_license
cckmit/ivalue
https://github.com/cckmit/ivalue
4189a83579096edb49b5ee73b47f7a5fcdde09c2
73bc6a07d0f853e80697ab05f2c57d044f3ef1ee
refs/heads/master
2023-03-23T23:05:13.541000
2018-08-21T03:22:10
2018-08-21T03:22:10
null
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
package com.axon.market.core.service.ishop; import com.axon.market.common.bean.ServiceResult; import com.axon.market.common.bean.SmsConfigBean; import com.axon.market.common.constant.ischeduling.ShopTaskStatusEnum; import com.axon.market.common.constant.ishop.ShopTaskClassifyEnum; import com.axon.market.common.domain.ishop.*; import com.axon.market.common.domain.isystem.UserDomain; import com.axon.market.common.util.*; import com.axon.market.core.service.icommon.SendSmsService; import com.axon.market.core.service.isystem.UserService; import com.axon.market.dao.mapper.iscene.IPositionBaseMapper; import com.axon.market.dao.mapper.ishop.IShopListMapper; import com.axon.market.dao.mapper.ishop.IShopTaskMapper; import com.axon.market.dao.mapper.ishop.IShopTemporaryTaskMapper; import com.fasterxml.jackson.core.type.TypeReference; import org.apache.commons.collections.CollectionUtils; import org.apache.commons.lang.StringUtils; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Qualifier; import org.springframework.stereotype.Component; import java.text.MessageFormat; import java.util.*; import org.apache.log4j.Logger; import org.springframework.transaction.annotation.Transactional; /** * 炒店任务service * Created by zengcr on 2017/2/14. */ @Component("shopTemporaryTaskService") public class ShopTemporaryTaskService { private static final Logger LOG = Logger.getLogger(ShopTemporaryTaskService.class.getName()); @Qualifier("shopTemporaryTaskDao") @Autowired private IShopTemporaryTaskMapper iShopTempTaskMapper; @Autowired @Qualifier("shopListDao") private IShopListMapper iShopListMapper; @Qualifier("shopTaskDao") @Autowired private IShopTaskMapper iShopTaskMapper; @Autowired @Qualifier("userService") private UserService userService; @Autowired @Qualifier("axonEncrypt") private AxonEncryptUtil axonEncrypt; @Autowired @Qualifier("smsConfigBean") private SmsConfigBean smsConfigBean; @Autowired @Qualifier("sendSmsService") private SendSmsService sendSmsService; @Qualifier("positionBaseDao") @Autowired private IPositionBaseMapper iPositionBaseMapper; public static ShopTemporaryTaskService getInstance() { return (ShopTemporaryTaskService) SpringUtil.getSingletonBean("shopTemporaryTaskService"); } /** * 获取炒店任务总数 * shopTaskId 炒店任务ID,shopTaskName 炒店任务名称,taskStatus 炒店任务状态 * * @return 总数 */ public int queryShopTempTaskTotal(Map<String, Object> paras) { return iShopTempTaskMapper.queryShopTempTaskTotal(paras); } /** * 分页查询炒店任务 * offset 起始标记位,limit 限制大小,shopTaskId 炒店任务ID,shopTaskName 炒店任务名称,taskStatus 炒店任务状态 * * @return */ public List<ShopTemporaryTaskDomain> queryShopTempTaskByPage(Map<String, Object> paras) { return iShopTempTaskMapper.queryShopTempTaskByPage(paras); } /** * 查询单个炒店任务 * offset 起始标记位,limit 限制大小,shopTaskId 炒店任务ID,shopTaskName 炒店任务名称,taskStatus 炒店任务状态 * * @return */ public ShopTemporaryTaskDomain queryShopTempTaskById(Integer taskId) { return iShopTempTaskMapper.queryShopTempTaskById(taskId); } /** * 插入炒店临时任务 * * @param taskDomain * @return */ @Transactional public ServiceResult insertShopTempTask(ShopTemporaryTaskDomain taskDomain, UserDomain userDomain) { ServiceResult result = new ServiceResult(); taskDomain = setDefault(taskDomain); ShopListDomain baseinfo = setBaseinfo(taskDomain, userDomain); //任务名称不能重复 Map<String, Object> parasMap = new HashMap<String, Object>(); parasMap.put("taskName", taskDomain.getTaskName()); if (validateTaskName(parasMap)) { result.setRetValue(-1); result.setDesc("项目名称重复"); return result; } try { //第一步:插入炒店临时任务打点信息 iShopListMapper.insertMyShopList(baseinfo, userDomain.getId()); //String businIdStr = String.valueOf(baseinfo.getBaseId()); //taskDomain.setBaseAreaId(Integer.parseInt(businIdStr)); taskDomain.setBaseIds(String.valueOf(baseinfo.getBaseId())); //第二步:插入炒店临时促销任务 iShopTempTaskMapper.insertShopTempTask(taskDomain); //第三步:插入炒店临时促销任务对应的炒店 String baseIds = taskDomain.getBaseIds(); iShopTaskMapper.insertShopTaskToBaseByIds(taskDomain); //第三步:审批通过,插入待执行任务池 if (ShopTaskStatusEnum.TASK_READY.getValue() == taskDomain.getStatus()) { long currentTime = System.currentTimeMillis(); long startTime = MarketTimeUtils.formatDate(taskDomain.getStartTime() + " 00:00:00").getTime(); long endTime = MarketTimeUtils.formatDate(taskDomain.getStopTime() + " 23:59:00").getTime(); if (currentTime > startTime && currentTime < endTime) { iShopTaskMapper.insertShopTaskPool(taskDomain); //第四步:修改炒店任务的下次营销时间 Map<String, Object> paras = new HashMap<String, Object>(); paras.put("shopTaskId", taskDomain.getId()); iShopTaskMapper.updateShopTaskNextTime(paras); } //开始时间大于当前时间 if (currentTime < startTime && currentTime < endTime) { //修改炒店任务的下次营销时间 Map<String, Object> paras = new HashMap<String, Object>(); paras.put("shopTaskId", taskDomain.getId()); iShopTaskMapper.updateShopTaskNextTimeAsStart(paras); } } else { //催单 if (userDomain != null) { reminderItem(taskDomain.getId(), taskDomain.getTaskName(), userDomain); } } } catch (Exception e) { LOG.error("shop task insert error", e); result.setRetValue(-1); result.setDesc("炒店任务新增操作失败"); } return result; } /** * 催单炒店任务 * * @param id * @return */ public ServiceResult reminderItem(Integer id, String taskName, UserDomain loginDomain) { ServiceResult serviceResult = new ServiceResult(); try { Map<String, Object> paras = new HashMap<String, Object>(); paras.put("taskId", id); paras.put("reminder", true); List<ShopTaskAuditHistoryDomain> shopTaskAuditHistories = iShopTaskMapper.queryShopTaskAuditHistoryDomain(paras); String auditUsers = loginDomain.getMarketingAuditUsers(); List<Map<String, Object>> auditUserList = JsonUtil.stringToObject(auditUsers, new TypeReference<List<Map<String, Object>>>() { }); List<Integer> needApproveUsers = queryAllAuditUserId(auditUserList); for (ShopTaskAuditHistoryDomain shopTaskAuditHistory : shopTaskAuditHistories) { needApproveUsers.remove(shopTaskAuditHistory.getAuditUser()); } //如果贷审批人为空 if (CollectionUtils.isEmpty(needApproveUsers)) { serviceResult.setRetValue(-1); serviceResult.setDesc("该任务的审批人为空,请找系统管理员核实!"); } else { Integer userId = needApproveUsers.get(0); UserDomain userDomain = userService.queryUserById(userId); String telephone = axonEncrypt.decrypt(userDomain.getTelephone()); if (StringUtils.isNotEmpty(telephone)) { String message = MessageFormat.format(smsConfigBean.getReminderNoticeSmsContent(), userDomain.getName(), "炒店营销任务[" + taskName + "]"); sendSmsService.sendReminderNoticeSms(telephone, message); } } } catch (Exception e) { serviceResult.setRetValue(-1); serviceResult.setDesc("炒店临时任务催单处理失败"); LOG.error("shop task炒店催单功能处理失败", e); } return serviceResult; } private List<Integer> queryAllAuditUserId(List<Map<String, Object>> auditUserList) { List<Integer> result = new ArrayList<Integer>(); for (Map<String, Object> map : auditUserList) { result.add(Integer.parseInt(String.valueOf(map.get("auditUser")))); } return result; } /** * 更新炒店临时任务 * * @param taskDomain * @return */ @Transactional public ServiceResult updateShopTempTask(ShopTemporaryTaskDomain taskDomain, UserDomain userDomain) { ServiceResult result = new ServiceResult(); taskDomain = setDefault(taskDomain); ShopListDomain baseinfo = setBaseinfo(taskDomain, userDomain); Map<String, Object> parasMap = new HashMap<String, Object>(); parasMap.put("taskName", taskDomain.getTaskName()); parasMap.put("shopTaskId", taskDomain.getId()); if (validateTaskName(parasMap)) { result.setRetValue(-1); result.setDesc("项目名称重复"); return result; } try { //根据taskid查询临时促销点 try { Long baseId = Long.valueOf(iShopTaskMapper.queryBaseIdByTaskId(taskDomain.getId())); baseinfo.setBaseId(baseId); taskDomain.setBaseIds(String.valueOf(baseId)); } catch (NumberFormatException e) { result.setRetValue(-1); result.setDesc("无法获取临时促销点"); return result; } //第一步:更新炒店临时任务打点信息 /*Integer createUserId = userDomain.getId(); String baseIdArray = taskDomain.getBaseIds(); String cityCode = taskDomain.getCityCode();*/ int number = iShopListMapper.updateMyShopList(baseinfo, userDomain.getId(), "", ""); //第二步:更新炒店临时任务 int rowsSult = iShopTempTaskMapper.updateShopTempTask(taskDomain); //临时任务编辑后,炒店id并没有变,因此shop_task_2_base也不需要重建 //iShopTaskMapper.deleteShopTaskToBase(taskDomain); //iShopTaskMapper.insertShopTaskToBaseByIds(taskDomain); //审批通过,插入待执行任务池 if (ShopTaskStatusEnum.TASK_READY.getValue() == taskDomain.getStatus()) { iShopTaskMapper.updateShopTaskPool(taskDomain); //第三步:修改炒店任务的下次营销时间 Map<String, Object> paras = new HashMap<String, Object>(); paras.put("shopTaskId", taskDomain.getId()); iShopTaskMapper.updateShopTaskNextTime(paras); } else { //催单 if (userDomain != null) { reminderItem(taskDomain.getId(), taskDomain.getTaskName(), userDomain); } } } catch (Exception e) { LOG.error("shop task insert error", e); result.setRetValue(-1); result.setDesc("炒店临时任务更新操作失败"); } return result; } /** * 根据用户ID校验任务是否重复 * * @param paras * @return */ public boolean validateTaskName(Map<String, Object> paras) { int num = 0; try { num = iShopTempTaskMapper.queryShopTempTaskNumByName(paras); } catch (Exception e) { num = 0; LOG.error("shop task validateTaskName error", e); } if (num > 0) { return true; } return false; } /** * 炒店新增修改时默认是配置 * * @param taskDomain * @return */ private ShopTemporaryTaskDomain setDefault(ShopTemporaryTaskDomain taskDomain) { taskDomain.setBeginTime("09:00"); taskDomain.setEndTime("18:00"); if (null != taskDomain.getMarketUser() && "4".equals(taskDomain.getMarketUser())) { taskDomain.setSceneType(31); taskDomain.setSceneTypeName("精细化平台"); } else { taskDomain.setSceneType(1); taskDomain.setSceneTypeName("互联网部"); } taskDomain.setMonitorInterval(1); taskDomain.setChannelId(1); taskDomain.setMonitorType(1); taskDomain.setTriggerChannelId(0); taskDomain.setTaskWeight(99); //taskDomain.setTaskClassifyId(ShopTaskClassifyEnum.TASK_TEMP_PROMOTION.getValue()); taskDomain.setStatus(1); taskDomain.setBaseAreaId(taskDomain.getCityCode()); taskDomain.setBaseAreaTypes("3"); return taskDomain; } /** * 炒店新增修改时默认是配置 * * @param taskDomain * @return */ private ShopListDomain setBaseinfo(ShopTemporaryTaskDomain taskDomain, UserDomain userDomain) { ShopListDomain baseinfo = new ShopListDomain(); baseinfo.setBaseName("临时促销点"); baseinfo.setStatus("1"); baseinfo.setAddress(taskDomain.getAddressDetail()); // 地址 baseinfo.setLat(taskDomain.getLatitude()); // 经度 baseinfo.setLng(taskDomain.getLongitude());// 纬度 baseinfo.setRadius(taskDomain.getRadius());// 半径 baseinfo.setCityName(taskDomain.getBaseAreaName());// 城市名称 baseinfo.setCityCode(taskDomain.getCityCode());// 城市编码 baseinfo.setDistrictCode(taskDomain.getAreaId()); // 地区编码 baseinfo.setCityAreaCode(taskDomain.getCityId()); baseinfo.setcreateUserid(userDomain.getId());//创建用户id baseinfo.setLocationTypeId(3);//3表示临时促销点 if (ShopTaskClassifyEnum.TASK_TEMP_PROMOTION_XY.getValue() == taskDomain.getTaskClassifyId()) { baseinfo.setBusinessHallCode("XY"+String.format("%03d", taskDomain.getCityCode())+TimeUtil.formatDateToYMDHMS(new Date())); } else if (ShopTaskClassifyEnum.TASK_TEMP_PROMOTION_JK.getValue() == taskDomain.getTaskClassifyId()) { baseinfo.setBusinessHallCode("JK"+String.format("%03d", taskDomain.getCityCode())+TimeUtil.formatDateToYMDHMS(new Date())); } else if(ShopTaskClassifyEnum.TASK_TEMP_PROMOTION_GZ.getValue() == taskDomain.getTaskClassifyId()) { baseinfo.setBusinessHallCode("GZ"+String.format("%03d", taskDomain.getCityCode())+TimeUtil.formatDateToYMDHMS(new Date())); } return baseinfo; } /** * 根据ID删除炒店临时任务 * 根据ID备注删除原因,执行者,操作时间 * * @return */ @Transactional public ServiceResult deleteShopTempTaskById(int shopTaskId) { ServiceResult result = new ServiceResult(); //查询任务对应的临时任务点baseid Integer baseId = Integer.valueOf(iShopTaskMapper.queryBaseIdByTaskId(shopTaskId)); if (baseId==null){ result.setRetValue(-1); result.setDesc("炒店临时任务删除操作失败"); } //将临时任务点置为失效 iPositionBaseMapper.deletePositionBaseById(baseId); //将临时任务置为失效 int rowsSult = iShopTempTaskMapper.deleteShopTempTaskById(shopTaskId); if (rowsSult < 1) { result.setRetValue(-1); result.setDesc("炒店临时任务删除操作失败"); } return result; } /** * 终止任务 * * @param id * @return */ @Transactional public ServiceResult pauseItem(Integer id) { ServiceResult serviceResult = new ServiceResult(); try { //1从次日起不再生成待办任务 iShopTaskMapper.updateShopTaskById(id, ShopTaskStatusEnum.TASK_STOP.getValue()); // 终止现在正在执行的任务 iShopTaskMapper.updateShopTaskPoolBySystemId(id, ShopTaskStatusEnum.TASK_STOP.getValue()); iShopTaskMapper.updateShopTaskExecuteBySystemId(id, null, ShopTaskStatusEnum.TASK_STOP.getValue()); //查询任务对应的临时任务点baseid Integer baseId = Integer.valueOf(iShopTaskMapper.queryBaseIdByTaskId(id)); if (baseId!=null){ //将临时任务点置为失效 iPositionBaseMapper.deletePositionBaseById(baseId); } } catch (Exception e) { serviceResult.setRetValue(-1); serviceResult.setDesc("终止任务处理失败"); LOG.error("shop task终止任务功能处理失败", e); } return serviceResult; } }
UTF-8
Java
17,572
java
ShopTemporaryTaskService.java
Java
[ { "context": ".Transactional;\n\n\n/**\n * 炒店任务service\n * Created by zengcr on 2017/2/14.\n */\n@Component(\"shopTemporaryTaskSe", "end": 1303, "score": 0.9997102618217468, "start": 1297, "tag": "USERNAME", "value": "zengcr" } ]
null
[]
package com.axon.market.core.service.ishop; import com.axon.market.common.bean.ServiceResult; import com.axon.market.common.bean.SmsConfigBean; import com.axon.market.common.constant.ischeduling.ShopTaskStatusEnum; import com.axon.market.common.constant.ishop.ShopTaskClassifyEnum; import com.axon.market.common.domain.ishop.*; import com.axon.market.common.domain.isystem.UserDomain; import com.axon.market.common.util.*; import com.axon.market.core.service.icommon.SendSmsService; import com.axon.market.core.service.isystem.UserService; import com.axon.market.dao.mapper.iscene.IPositionBaseMapper; import com.axon.market.dao.mapper.ishop.IShopListMapper; import com.axon.market.dao.mapper.ishop.IShopTaskMapper; import com.axon.market.dao.mapper.ishop.IShopTemporaryTaskMapper; import com.fasterxml.jackson.core.type.TypeReference; import org.apache.commons.collections.CollectionUtils; import org.apache.commons.lang.StringUtils; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Qualifier; import org.springframework.stereotype.Component; import java.text.MessageFormat; import java.util.*; import org.apache.log4j.Logger; import org.springframework.transaction.annotation.Transactional; /** * 炒店任务service * Created by zengcr on 2017/2/14. */ @Component("shopTemporaryTaskService") public class ShopTemporaryTaskService { private static final Logger LOG = Logger.getLogger(ShopTemporaryTaskService.class.getName()); @Qualifier("shopTemporaryTaskDao") @Autowired private IShopTemporaryTaskMapper iShopTempTaskMapper; @Autowired @Qualifier("shopListDao") private IShopListMapper iShopListMapper; @Qualifier("shopTaskDao") @Autowired private IShopTaskMapper iShopTaskMapper; @Autowired @Qualifier("userService") private UserService userService; @Autowired @Qualifier("axonEncrypt") private AxonEncryptUtil axonEncrypt; @Autowired @Qualifier("smsConfigBean") private SmsConfigBean smsConfigBean; @Autowired @Qualifier("sendSmsService") private SendSmsService sendSmsService; @Qualifier("positionBaseDao") @Autowired private IPositionBaseMapper iPositionBaseMapper; public static ShopTemporaryTaskService getInstance() { return (ShopTemporaryTaskService) SpringUtil.getSingletonBean("shopTemporaryTaskService"); } /** * 获取炒店任务总数 * shopTaskId 炒店任务ID,shopTaskName 炒店任务名称,taskStatus 炒店任务状态 * * @return 总数 */ public int queryShopTempTaskTotal(Map<String, Object> paras) { return iShopTempTaskMapper.queryShopTempTaskTotal(paras); } /** * 分页查询炒店任务 * offset 起始标记位,limit 限制大小,shopTaskId 炒店任务ID,shopTaskName 炒店任务名称,taskStatus 炒店任务状态 * * @return */ public List<ShopTemporaryTaskDomain> queryShopTempTaskByPage(Map<String, Object> paras) { return iShopTempTaskMapper.queryShopTempTaskByPage(paras); } /** * 查询单个炒店任务 * offset 起始标记位,limit 限制大小,shopTaskId 炒店任务ID,shopTaskName 炒店任务名称,taskStatus 炒店任务状态 * * @return */ public ShopTemporaryTaskDomain queryShopTempTaskById(Integer taskId) { return iShopTempTaskMapper.queryShopTempTaskById(taskId); } /** * 插入炒店临时任务 * * @param taskDomain * @return */ @Transactional public ServiceResult insertShopTempTask(ShopTemporaryTaskDomain taskDomain, UserDomain userDomain) { ServiceResult result = new ServiceResult(); taskDomain = setDefault(taskDomain); ShopListDomain baseinfo = setBaseinfo(taskDomain, userDomain); //任务名称不能重复 Map<String, Object> parasMap = new HashMap<String, Object>(); parasMap.put("taskName", taskDomain.getTaskName()); if (validateTaskName(parasMap)) { result.setRetValue(-1); result.setDesc("项目名称重复"); return result; } try { //第一步:插入炒店临时任务打点信息 iShopListMapper.insertMyShopList(baseinfo, userDomain.getId()); //String businIdStr = String.valueOf(baseinfo.getBaseId()); //taskDomain.setBaseAreaId(Integer.parseInt(businIdStr)); taskDomain.setBaseIds(String.valueOf(baseinfo.getBaseId())); //第二步:插入炒店临时促销任务 iShopTempTaskMapper.insertShopTempTask(taskDomain); //第三步:插入炒店临时促销任务对应的炒店 String baseIds = taskDomain.getBaseIds(); iShopTaskMapper.insertShopTaskToBaseByIds(taskDomain); //第三步:审批通过,插入待执行任务池 if (ShopTaskStatusEnum.TASK_READY.getValue() == taskDomain.getStatus()) { long currentTime = System.currentTimeMillis(); long startTime = MarketTimeUtils.formatDate(taskDomain.getStartTime() + " 00:00:00").getTime(); long endTime = MarketTimeUtils.formatDate(taskDomain.getStopTime() + " 23:59:00").getTime(); if (currentTime > startTime && currentTime < endTime) { iShopTaskMapper.insertShopTaskPool(taskDomain); //第四步:修改炒店任务的下次营销时间 Map<String, Object> paras = new HashMap<String, Object>(); paras.put("shopTaskId", taskDomain.getId()); iShopTaskMapper.updateShopTaskNextTime(paras); } //开始时间大于当前时间 if (currentTime < startTime && currentTime < endTime) { //修改炒店任务的下次营销时间 Map<String, Object> paras = new HashMap<String, Object>(); paras.put("shopTaskId", taskDomain.getId()); iShopTaskMapper.updateShopTaskNextTimeAsStart(paras); } } else { //催单 if (userDomain != null) { reminderItem(taskDomain.getId(), taskDomain.getTaskName(), userDomain); } } } catch (Exception e) { LOG.error("shop task insert error", e); result.setRetValue(-1); result.setDesc("炒店任务新增操作失败"); } return result; } /** * 催单炒店任务 * * @param id * @return */ public ServiceResult reminderItem(Integer id, String taskName, UserDomain loginDomain) { ServiceResult serviceResult = new ServiceResult(); try { Map<String, Object> paras = new HashMap<String, Object>(); paras.put("taskId", id); paras.put("reminder", true); List<ShopTaskAuditHistoryDomain> shopTaskAuditHistories = iShopTaskMapper.queryShopTaskAuditHistoryDomain(paras); String auditUsers = loginDomain.getMarketingAuditUsers(); List<Map<String, Object>> auditUserList = JsonUtil.stringToObject(auditUsers, new TypeReference<List<Map<String, Object>>>() { }); List<Integer> needApproveUsers = queryAllAuditUserId(auditUserList); for (ShopTaskAuditHistoryDomain shopTaskAuditHistory : shopTaskAuditHistories) { needApproveUsers.remove(shopTaskAuditHistory.getAuditUser()); } //如果贷审批人为空 if (CollectionUtils.isEmpty(needApproveUsers)) { serviceResult.setRetValue(-1); serviceResult.setDesc("该任务的审批人为空,请找系统管理员核实!"); } else { Integer userId = needApproveUsers.get(0); UserDomain userDomain = userService.queryUserById(userId); String telephone = axonEncrypt.decrypt(userDomain.getTelephone()); if (StringUtils.isNotEmpty(telephone)) { String message = MessageFormat.format(smsConfigBean.getReminderNoticeSmsContent(), userDomain.getName(), "炒店营销任务[" + taskName + "]"); sendSmsService.sendReminderNoticeSms(telephone, message); } } } catch (Exception e) { serviceResult.setRetValue(-1); serviceResult.setDesc("炒店临时任务催单处理失败"); LOG.error("shop task炒店催单功能处理失败", e); } return serviceResult; } private List<Integer> queryAllAuditUserId(List<Map<String, Object>> auditUserList) { List<Integer> result = new ArrayList<Integer>(); for (Map<String, Object> map : auditUserList) { result.add(Integer.parseInt(String.valueOf(map.get("auditUser")))); } return result; } /** * 更新炒店临时任务 * * @param taskDomain * @return */ @Transactional public ServiceResult updateShopTempTask(ShopTemporaryTaskDomain taskDomain, UserDomain userDomain) { ServiceResult result = new ServiceResult(); taskDomain = setDefault(taskDomain); ShopListDomain baseinfo = setBaseinfo(taskDomain, userDomain); Map<String, Object> parasMap = new HashMap<String, Object>(); parasMap.put("taskName", taskDomain.getTaskName()); parasMap.put("shopTaskId", taskDomain.getId()); if (validateTaskName(parasMap)) { result.setRetValue(-1); result.setDesc("项目名称重复"); return result; } try { //根据taskid查询临时促销点 try { Long baseId = Long.valueOf(iShopTaskMapper.queryBaseIdByTaskId(taskDomain.getId())); baseinfo.setBaseId(baseId); taskDomain.setBaseIds(String.valueOf(baseId)); } catch (NumberFormatException e) { result.setRetValue(-1); result.setDesc("无法获取临时促销点"); return result; } //第一步:更新炒店临时任务打点信息 /*Integer createUserId = userDomain.getId(); String baseIdArray = taskDomain.getBaseIds(); String cityCode = taskDomain.getCityCode();*/ int number = iShopListMapper.updateMyShopList(baseinfo, userDomain.getId(), "", ""); //第二步:更新炒店临时任务 int rowsSult = iShopTempTaskMapper.updateShopTempTask(taskDomain); //临时任务编辑后,炒店id并没有变,因此shop_task_2_base也不需要重建 //iShopTaskMapper.deleteShopTaskToBase(taskDomain); //iShopTaskMapper.insertShopTaskToBaseByIds(taskDomain); //审批通过,插入待执行任务池 if (ShopTaskStatusEnum.TASK_READY.getValue() == taskDomain.getStatus()) { iShopTaskMapper.updateShopTaskPool(taskDomain); //第三步:修改炒店任务的下次营销时间 Map<String, Object> paras = new HashMap<String, Object>(); paras.put("shopTaskId", taskDomain.getId()); iShopTaskMapper.updateShopTaskNextTime(paras); } else { //催单 if (userDomain != null) { reminderItem(taskDomain.getId(), taskDomain.getTaskName(), userDomain); } } } catch (Exception e) { LOG.error("shop task insert error", e); result.setRetValue(-1); result.setDesc("炒店临时任务更新操作失败"); } return result; } /** * 根据用户ID校验任务是否重复 * * @param paras * @return */ public boolean validateTaskName(Map<String, Object> paras) { int num = 0; try { num = iShopTempTaskMapper.queryShopTempTaskNumByName(paras); } catch (Exception e) { num = 0; LOG.error("shop task validateTaskName error", e); } if (num > 0) { return true; } return false; } /** * 炒店新增修改时默认是配置 * * @param taskDomain * @return */ private ShopTemporaryTaskDomain setDefault(ShopTemporaryTaskDomain taskDomain) { taskDomain.setBeginTime("09:00"); taskDomain.setEndTime("18:00"); if (null != taskDomain.getMarketUser() && "4".equals(taskDomain.getMarketUser())) { taskDomain.setSceneType(31); taskDomain.setSceneTypeName("精细化平台"); } else { taskDomain.setSceneType(1); taskDomain.setSceneTypeName("互联网部"); } taskDomain.setMonitorInterval(1); taskDomain.setChannelId(1); taskDomain.setMonitorType(1); taskDomain.setTriggerChannelId(0); taskDomain.setTaskWeight(99); //taskDomain.setTaskClassifyId(ShopTaskClassifyEnum.TASK_TEMP_PROMOTION.getValue()); taskDomain.setStatus(1); taskDomain.setBaseAreaId(taskDomain.getCityCode()); taskDomain.setBaseAreaTypes("3"); return taskDomain; } /** * 炒店新增修改时默认是配置 * * @param taskDomain * @return */ private ShopListDomain setBaseinfo(ShopTemporaryTaskDomain taskDomain, UserDomain userDomain) { ShopListDomain baseinfo = new ShopListDomain(); baseinfo.setBaseName("临时促销点"); baseinfo.setStatus("1"); baseinfo.setAddress(taskDomain.getAddressDetail()); // 地址 baseinfo.setLat(taskDomain.getLatitude()); // 经度 baseinfo.setLng(taskDomain.getLongitude());// 纬度 baseinfo.setRadius(taskDomain.getRadius());// 半径 baseinfo.setCityName(taskDomain.getBaseAreaName());// 城市名称 baseinfo.setCityCode(taskDomain.getCityCode());// 城市编码 baseinfo.setDistrictCode(taskDomain.getAreaId()); // 地区编码 baseinfo.setCityAreaCode(taskDomain.getCityId()); baseinfo.setcreateUserid(userDomain.getId());//创建用户id baseinfo.setLocationTypeId(3);//3表示临时促销点 if (ShopTaskClassifyEnum.TASK_TEMP_PROMOTION_XY.getValue() == taskDomain.getTaskClassifyId()) { baseinfo.setBusinessHallCode("XY"+String.format("%03d", taskDomain.getCityCode())+TimeUtil.formatDateToYMDHMS(new Date())); } else if (ShopTaskClassifyEnum.TASK_TEMP_PROMOTION_JK.getValue() == taskDomain.getTaskClassifyId()) { baseinfo.setBusinessHallCode("JK"+String.format("%03d", taskDomain.getCityCode())+TimeUtil.formatDateToYMDHMS(new Date())); } else if(ShopTaskClassifyEnum.TASK_TEMP_PROMOTION_GZ.getValue() == taskDomain.getTaskClassifyId()) { baseinfo.setBusinessHallCode("GZ"+String.format("%03d", taskDomain.getCityCode())+TimeUtil.formatDateToYMDHMS(new Date())); } return baseinfo; } /** * 根据ID删除炒店临时任务 * 根据ID备注删除原因,执行者,操作时间 * * @return */ @Transactional public ServiceResult deleteShopTempTaskById(int shopTaskId) { ServiceResult result = new ServiceResult(); //查询任务对应的临时任务点baseid Integer baseId = Integer.valueOf(iShopTaskMapper.queryBaseIdByTaskId(shopTaskId)); if (baseId==null){ result.setRetValue(-1); result.setDesc("炒店临时任务删除操作失败"); } //将临时任务点置为失效 iPositionBaseMapper.deletePositionBaseById(baseId); //将临时任务置为失效 int rowsSult = iShopTempTaskMapper.deleteShopTempTaskById(shopTaskId); if (rowsSult < 1) { result.setRetValue(-1); result.setDesc("炒店临时任务删除操作失败"); } return result; } /** * 终止任务 * * @param id * @return */ @Transactional public ServiceResult pauseItem(Integer id) { ServiceResult serviceResult = new ServiceResult(); try { //1从次日起不再生成待办任务 iShopTaskMapper.updateShopTaskById(id, ShopTaskStatusEnum.TASK_STOP.getValue()); // 终止现在正在执行的任务 iShopTaskMapper.updateShopTaskPoolBySystemId(id, ShopTaskStatusEnum.TASK_STOP.getValue()); iShopTaskMapper.updateShopTaskExecuteBySystemId(id, null, ShopTaskStatusEnum.TASK_STOP.getValue()); //查询任务对应的临时任务点baseid Integer baseId = Integer.valueOf(iShopTaskMapper.queryBaseIdByTaskId(id)); if (baseId!=null){ //将临时任务点置为失效 iPositionBaseMapper.deletePositionBaseById(baseId); } } catch (Exception e) { serviceResult.setRetValue(-1); serviceResult.setDesc("终止任务处理失败"); LOG.error("shop task终止任务功能处理失败", e); } return serviceResult; } }
17,572
0.624769
0.620711
453
34.898457
30.234234
153
false
false
0
0
0
0
0
0
0.545254
false
false
9
33e8b6fb48a1334f31752d310c06ad26fd7a87c4
14,946,486,237,739
0a532b9d7ebc356ab684a094b3cf840b6b6a17cd
/java-source/src/main/java/security/PermissionCollection.java
e2ad8e350793b16ae9e36538e0a45f69ea69298a
[ "Apache-2.0" ]
permissive
XWxiaowei/JavaCode
https://github.com/XWxiaowei/JavaCode
ac70d87cdb0dfc6b7468acf46c84565f9d198e74
a7e7cd7a49c36db3ee479216728dd500eab9ebb2
refs/heads/master
2022-12-24T10:21:28.144000
2020-08-22T08:01:43
2020-08-22T08:01:43
98,070,624
10
4
Apache-2.0
false
2022-12-16T04:23:38
2017-07-23T02:51:51
2021-12-29T12:11:37
2022-12-16T04:23:37
77,255
7
4
22
Java
false
false
/* * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. * ORACLE PROPRIETARY/CONFIDENTIAL. Use is subject to license terms. * * * * * * * * * * * * * * * * * * * * */ package java.security; import java.util.*; /** * Abstract class representing a collection of Permission objects. * * <p>With a PermissionCollection, you can: * <UL> * <LI> add a permission to the collection using the {@code add} method. * <LI> check to see if a particular permission is implied in the * collection, using the {@code implies} method. * <LI> enumerate all the permissions, using the {@code elements} method. * </UL> * * <p>When it is desirable to group together a number of Permission objects * of the same type, the {@code newPermissionCollection} method on that * particular type of Permission object should first be called. The default * behavior (from the Permission class) is to simply return null. * Subclasses of class Permission override the method if they need to store * their permissions in a particular PermissionCollection object in order * to provide the correct semantics when the * {@code PermissionCollection.implies} method is called. * If a non-null value is returned, that PermissionCollection must be used. * If null is returned, then the caller of {@code newPermissionCollection} * is free to store permissions of the * given type in any PermissionCollection they choose * (one that uses a Hashtable, one that uses a Vector, etc). * * <p>The PermissionCollection returned by the * {@code Permission.newPermissionCollection} * method is a homogeneous collection, which stores only Permission objects * for a given Permission type. A PermissionCollection may also be * heterogeneous. For example, Permissions is a PermissionCollection * subclass that represents a collection of PermissionCollections. * That is, its members are each a homogeneous PermissionCollection. * For example, a Permissions object might have a FilePermissionCollection * for all the FilePermission objects, a SocketPermissionCollection for all the * SocketPermission objects, and so on. Its {@code add} method adds a * permission to the appropriate collection. * * <p>Whenever a permission is added to a heterogeneous PermissionCollection * such as Permissions, and the PermissionCollection doesn't yet contain a * PermissionCollection of the specified permission's type, the * PermissionCollection should call * the {@code newPermissionCollection} method on the permission's class * to see if it requires a special PermissionCollection. If * {@code newPermissionCollection} * returns null, the PermissionCollection * is free to store the permission in any type of PermissionCollection it * desires (one using a Hashtable, one using a Vector, etc.). For example, * the Permissions object uses a default PermissionCollection implementation * that stores the permission objects in a Hashtable. * * <p> Subclass implementations of PermissionCollection should assume * that they may be called simultaneously from multiple threads, * and therefore should be synchronized properly. Furthermore, * Enumerations returned via the {@code elements} method are * not <em>fail-fast</em>. Modifications to a collection should not be * performed while enumerating over that collection. * * @see Permission * @see Permissions * * * @author Roland Schemers */ public abstract class PermissionCollection implements java.io.Serializable { private static final long serialVersionUID = -6727011328946861783L; // when set, add will throw an exception. private volatile boolean readOnly; /** * Adds a permission object to the current collection of permission objects. * * @param permission the Permission object to add. * * @exception SecurityException - if this PermissionCollection object * has been marked readonly * @exception IllegalArgumentException - if this PermissionCollection * object is a homogeneous collection and the permission * is not of the correct type. */ public abstract void add(Permission permission); /** * Checks to see if the specified permission is implied by * the collection of Permission objects held in this PermissionCollection. * * @param permission the Permission object to compare. * * @return true if "permission" is implied by the permissions in * the collection, false if not. */ public abstract boolean implies(Permission permission); /** * Returns an enumeration of all the Permission objects in the collection. * * @return an enumeration of all the Permissions. */ public abstract Enumeration<Permission> elements(); /** * Marks this PermissionCollection object as "readonly". After * a PermissionCollection object * is marked as readonly, no new Permission objects can be added to it * using {@code add}. */ public void setReadOnly() { readOnly = true; } /** * Returns true if this PermissionCollection object is marked as readonly. * If it is readonly, no new Permission objects can be added to it * using {@code add}. * * <p>By default, the object is <i>not</i> readonly. It can be set to * readonly by a call to {@code setReadOnly}. * * @return true if this PermissionCollection object is marked as readonly, * false otherwise. */ public boolean isReadOnly() { return readOnly; } /** * Returns a string describing this PermissionCollection object, * providing information about all the permissions it contains. * The format is: * <pre> * super.toString() ( * // enumerate all the Permission * // objects and call toString() on them, * // one per line.. * )</pre> * * {@code super.toString} is a call to the {@code toString} * method of this * object's superclass, which is Object. The result is * this PermissionCollection's type name followed by this object's * hashcode, thus enabling clients to differentiate different * PermissionCollections object, even if they contain the same permissions. * * @return information about this PermissionCollection object, * as described above. * */ public String toString() { Enumeration<Permission> enum_ = elements(); StringBuilder sb = new StringBuilder(); sb.append(super.toString()+" (\n"); while (enum_.hasMoreElements()) { try { sb.append(" "); sb.append(enum_.nextElement().toString()); sb.append("\n"); } catch (NoSuchElementException e){ // ignore } } sb.append(")\n"); return sb.toString(); } }
UTF-8
Java
6,987
java
PermissionCollection.java
Java
[ { "context": "ee Permission\n * @see Permissions\n *\n *\n * @author Roland Schemers\n */\n\npublic abstract class PermissionCollection i", "end": 3437, "score": 0.998883068561554, "start": 3422, "tag": "NAME", "value": "Roland Schemers" } ]
null
[]
/* * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. * ORACLE PROPRIETARY/CONFIDENTIAL. Use is subject to license terms. * * * * * * * * * * * * * * * * * * * * */ package java.security; import java.util.*; /** * Abstract class representing a collection of Permission objects. * * <p>With a PermissionCollection, you can: * <UL> * <LI> add a permission to the collection using the {@code add} method. * <LI> check to see if a particular permission is implied in the * collection, using the {@code implies} method. * <LI> enumerate all the permissions, using the {@code elements} method. * </UL> * * <p>When it is desirable to group together a number of Permission objects * of the same type, the {@code newPermissionCollection} method on that * particular type of Permission object should first be called. The default * behavior (from the Permission class) is to simply return null. * Subclasses of class Permission override the method if they need to store * their permissions in a particular PermissionCollection object in order * to provide the correct semantics when the * {@code PermissionCollection.implies} method is called. * If a non-null value is returned, that PermissionCollection must be used. * If null is returned, then the caller of {@code newPermissionCollection} * is free to store permissions of the * given type in any PermissionCollection they choose * (one that uses a Hashtable, one that uses a Vector, etc). * * <p>The PermissionCollection returned by the * {@code Permission.newPermissionCollection} * method is a homogeneous collection, which stores only Permission objects * for a given Permission type. A PermissionCollection may also be * heterogeneous. For example, Permissions is a PermissionCollection * subclass that represents a collection of PermissionCollections. * That is, its members are each a homogeneous PermissionCollection. * For example, a Permissions object might have a FilePermissionCollection * for all the FilePermission objects, a SocketPermissionCollection for all the * SocketPermission objects, and so on. Its {@code add} method adds a * permission to the appropriate collection. * * <p>Whenever a permission is added to a heterogeneous PermissionCollection * such as Permissions, and the PermissionCollection doesn't yet contain a * PermissionCollection of the specified permission's type, the * PermissionCollection should call * the {@code newPermissionCollection} method on the permission's class * to see if it requires a special PermissionCollection. If * {@code newPermissionCollection} * returns null, the PermissionCollection * is free to store the permission in any type of PermissionCollection it * desires (one using a Hashtable, one using a Vector, etc.). For example, * the Permissions object uses a default PermissionCollection implementation * that stores the permission objects in a Hashtable. * * <p> Subclass implementations of PermissionCollection should assume * that they may be called simultaneously from multiple threads, * and therefore should be synchronized properly. Furthermore, * Enumerations returned via the {@code elements} method are * not <em>fail-fast</em>. Modifications to a collection should not be * performed while enumerating over that collection. * * @see Permission * @see Permissions * * * @author <NAME> */ public abstract class PermissionCollection implements java.io.Serializable { private static final long serialVersionUID = -6727011328946861783L; // when set, add will throw an exception. private volatile boolean readOnly; /** * Adds a permission object to the current collection of permission objects. * * @param permission the Permission object to add. * * @exception SecurityException - if this PermissionCollection object * has been marked readonly * @exception IllegalArgumentException - if this PermissionCollection * object is a homogeneous collection and the permission * is not of the correct type. */ public abstract void add(Permission permission); /** * Checks to see if the specified permission is implied by * the collection of Permission objects held in this PermissionCollection. * * @param permission the Permission object to compare. * * @return true if "permission" is implied by the permissions in * the collection, false if not. */ public abstract boolean implies(Permission permission); /** * Returns an enumeration of all the Permission objects in the collection. * * @return an enumeration of all the Permissions. */ public abstract Enumeration<Permission> elements(); /** * Marks this PermissionCollection object as "readonly". After * a PermissionCollection object * is marked as readonly, no new Permission objects can be added to it * using {@code add}. */ public void setReadOnly() { readOnly = true; } /** * Returns true if this PermissionCollection object is marked as readonly. * If it is readonly, no new Permission objects can be added to it * using {@code add}. * * <p>By default, the object is <i>not</i> readonly. It can be set to * readonly by a call to {@code setReadOnly}. * * @return true if this PermissionCollection object is marked as readonly, * false otherwise. */ public boolean isReadOnly() { return readOnly; } /** * Returns a string describing this PermissionCollection object, * providing information about all the permissions it contains. * The format is: * <pre> * super.toString() ( * // enumerate all the Permission * // objects and call toString() on them, * // one per line.. * )</pre> * * {@code super.toString} is a call to the {@code toString} * method of this * object's superclass, which is Object. The result is * this PermissionCollection's type name followed by this object's * hashcode, thus enabling clients to differentiate different * PermissionCollections object, even if they contain the same permissions. * * @return information about this PermissionCollection object, * as described above. * */ public String toString() { Enumeration<Permission> enum_ = elements(); StringBuilder sb = new StringBuilder(); sb.append(super.toString()+" (\n"); while (enum_.hasMoreElements()) { try { sb.append(" "); sb.append(enum_.nextElement().toString()); sb.append("\n"); } catch (NoSuchElementException e){ // ignore } } sb.append(")\n"); return sb.toString(); } }
6,978
0.68699
0.683126
195
34.830769
28.899242
80
false
false
0
0
0
0
0
0
0.271795
false
false
5
6da330ca23624fc969641e8243cb5aa7e5433fe2
30,150,670,473,255
1961285a3388cae1149080f18167d18b4e3ea3d4
/intf/src/main/java/com/ipeony/project/intf/entity/Authorities.java
db65c0f2e7039b2fdebd34358444bb5a4be8b8a3
[]
no_license
beiwang/spring-security-mybaitis
https://github.com/beiwang/spring-security-mybaitis
6a47cd5c7d535766f94e8f6866321631d1233710
7d22c6edddfec0c654dbdbc1cb59faa396e48b24
refs/heads/master
2016-09-26T15:51:00.795000
2014-06-30T10:14:14
2014-06-30T10:14:14
null
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
package com.ipeony.project.intf.entity; import java.io.Serializable; import javax.persistence.Column; import javax.persistence.Entity; import javax.persistence.GeneratedValue; import javax.persistence.GenerationType; import javax.persistence.Id; @Entity(name = "TT_AUTHORITIES") public class Authorities implements Serializable { private static final long serialVersionUID = 8778766430523917279L; /** 权限ID */ @Id @GeneratedValue(strategy = GenerationType.TABLE) @Column(name = "AUTHORITY_ID") private String authorityId; /** 权限名称 */ @Column(name = "AUTHORITY_NAME") private String authorityName; /** 权限描述 */ @Column(name = "AUTHORITY_DESC") private String authorityDesc; /** 是否启用 */ @Column(name = "ENABLED") private int enabled; /** 是否超级权限 */ @Column(name = "IS_SYS") private int isSys; //权限对应 public Authorities() { } public Authorities(String authorityId, String authorityName, String authorityDesc, int enabled, int isSys) { super(); this.authorityId = authorityId; this.authorityName = authorityName; this.authorityDesc = authorityDesc; this.enabled = enabled; this.isSys = isSys; } /** * @return the authorityId */ public String getAuthorityId() { return authorityId; } /** * @param authorityId * the authorityId to set */ public void setAuthorityId(String authorityId) { this.authorityId = authorityId; } /** * @return the authorityName */ public String getAuthorityName() { return authorityName; } /** * @param authorityName * the authorityName to set */ public void setAuthorityName(String authorityName) { this.authorityName = authorityName; } /** * @return the authorityDesc */ public String getAuthorityDesc() { return authorityDesc; } /** * @param authorityDesc * the authorityDesc to set */ public void setAuthorityDesc(String authorityDesc) { this.authorityDesc = authorityDesc; } /** * @return the enabled */ public int getEnabled() { return enabled; } /** * @param enabled * the enabled to set */ public void setEnabled(int enabled) { this.enabled = enabled; } /** * @return the isSys */ public int getIsSys() { return isSys; } /** * @param isSys * the isSys to set */ public void setIsSys(int isSys) { this.isSys = isSys; } }
UTF-8
Java
2,535
java
Authorities.java
Java
[]
null
[]
package com.ipeony.project.intf.entity; import java.io.Serializable; import javax.persistence.Column; import javax.persistence.Entity; import javax.persistence.GeneratedValue; import javax.persistence.GenerationType; import javax.persistence.Id; @Entity(name = "TT_AUTHORITIES") public class Authorities implements Serializable { private static final long serialVersionUID = 8778766430523917279L; /** 权限ID */ @Id @GeneratedValue(strategy = GenerationType.TABLE) @Column(name = "AUTHORITY_ID") private String authorityId; /** 权限名称 */ @Column(name = "AUTHORITY_NAME") private String authorityName; /** 权限描述 */ @Column(name = "AUTHORITY_DESC") private String authorityDesc; /** 是否启用 */ @Column(name = "ENABLED") private int enabled; /** 是否超级权限 */ @Column(name = "IS_SYS") private int isSys; //权限对应 public Authorities() { } public Authorities(String authorityId, String authorityName, String authorityDesc, int enabled, int isSys) { super(); this.authorityId = authorityId; this.authorityName = authorityName; this.authorityDesc = authorityDesc; this.enabled = enabled; this.isSys = isSys; } /** * @return the authorityId */ public String getAuthorityId() { return authorityId; } /** * @param authorityId * the authorityId to set */ public void setAuthorityId(String authorityId) { this.authorityId = authorityId; } /** * @return the authorityName */ public String getAuthorityName() { return authorityName; } /** * @param authorityName * the authorityName to set */ public void setAuthorityName(String authorityName) { this.authorityName = authorityName; } /** * @return the authorityDesc */ public String getAuthorityDesc() { return authorityDesc; } /** * @param authorityDesc * the authorityDesc to set */ public void setAuthorityDesc(String authorityDesc) { this.authorityDesc = authorityDesc; } /** * @return the enabled */ public int getEnabled() { return enabled; } /** * @param enabled * the enabled to set */ public void setEnabled(int enabled) { this.enabled = enabled; } /** * @return the isSys */ public int getIsSys() { return isSys; } /** * @param isSys * the isSys to set */ public void setIsSys(int isSys) { this.isSys = isSys; } }
2,535
0.642943
0.635304
128
17.429688
17.826281
109
false
false
0
0
0
0
0
0
1.125
false
false
5
3ccfefafe65c567503ef48a4a39281a9148e64b3
7,679,401,577,341
c5d45653c4836d556d51db22fc5909cba4582589
/aula2/src/aula2/ExercicioGit6.java
52ee7e96b0d6b80eed8395d7a5d72b9a63659d5c
[]
no_license
filipeoassis/java-prog2
https://github.com/filipeoassis/java-prog2
971c177f1f3acf389fbd7a680c481afef6d1bd68
6ca07fa96e28d3f9fadd7518ad7d4764676dab94
refs/heads/master
2021-04-15T10:05:24.575000
2018-03-29T00:29:08
2018-03-29T00:29:08
null
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
package aula2; import java.util.Scanner; public class ExercicioGit6 { public static void main(String[] args) { Scanner scanln = new Scanner(System.in); int[] num = new int[5]; double media; for(int i=0;i<5;i++){ System.out.println("\nDigite o valor"+(i+1)+":"); num[i] = scanln.nextInt(); } media = //Ler "Java use a cabeša" } }
IBM852
Java
373
java
ExercicioGit6.java
Java
[]
null
[]
package aula2; import java.util.Scanner; public class ExercicioGit6 { public static void main(String[] args) { Scanner scanln = new Scanner(System.in); int[] num = new int[5]; double media; for(int i=0;i<5;i++){ System.out.println("\nDigite o valor"+(i+1)+":"); num[i] = scanln.nextInt(); } media = //Ler "Java use a cabeša" } }
373
0.599462
0.583333
17
19.882353
16.753866
52
false
false
0
0
0
0
0
0
1.823529
false
false
5
ea813ea74d2209139e38e36771adde329719c245
32,804,960,259,620
6d71378273ec6e9ef22b55e03f53032b6d6924b8
/src/main/java/swf/army/mil/dealership/inventory/InventoryController.java
a55a7c79610347ca6250a60a984b800ee1f192d9
[]
no_license
WarlockInResidence/Sprint_Virtual_Car_Dealership
https://github.com/WarlockInResidence/Sprint_Virtual_Car_Dealership
39a92285fe2141dd7f5f3d8d78a414f967285353
9839d8071028cfa2128dd074bcdaae3dbd12fe73
refs/heads/master
2023-07-15T10:42:13.696000
2021-08-16T16:50:57
2021-08-16T16:50:57
396,875,471
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
package swf.army.mil.dealership.inventory; import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.ResponseBody; import org.springframework.web.bind.annotation.RestController; import java.util.List; @RestController public class InventoryController { private CarService carService; public InventoryController(CarService carService) { this.carService = carService; } @GetMapping("/inventory/cars") public @ResponseBody List<Car> cars() { return carService.getAvailableCars(); } }
UTF-8
Java
574
java
InventoryController.java
Java
[]
null
[]
package swf.army.mil.dealership.inventory; import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.ResponseBody; import org.springframework.web.bind.annotation.RestController; import java.util.List; @RestController public class InventoryController { private CarService carService; public InventoryController(CarService carService) { this.carService = carService; } @GetMapping("/inventory/cars") public @ResponseBody List<Car> cars() { return carService.getAvailableCars(); } }
574
0.761324
0.761324
22
25.09091
22.580984
62
false
false
0
0
0
0
0
0
0.363636
false
false
5
3da21b443a3d9b3267df4b1b97d8f6f5e7a24eb6
2,190,433,369,599
39d7c670f6bc5498f502054c2a1e239b497c50dd
/app/src/main/java/com/aqnichol/circleui/CircleDrawableFragment.java
e08c36d3996572ac903b9fced1a9bca26376a22c
[]
no_license
unixpickle/CircleUI
https://github.com/unixpickle/CircleUI
34cec34a920fa99b2d024b36952f27a7daaa68e3
31a83f38b2669d8a03e335220f3376219d6cf24d
refs/heads/master
2021-01-10T02:06:15.126000
2015-05-23T18:20:21
2015-05-23T18:20:21
36,098,458
1
1
null
null
null
null
null
null
null
null
null
null
null
null
null
package com.aqnichol.circleui; import android.content.Context; import android.graphics.Canvas; import android.graphics.Color; import android.graphics.Paint; import android.graphics.Rect; import android.graphics.drawable.Drawable; import android.os.Bundle; import android.view.LayoutInflater; import android.view.View; import android.view.ViewGroup; /** * A CircleImageFragment is a CircleFragment with an image. */ public class CircleDrawableFragment extends CircleFragment { private Drawable drawable = null; public void draw(Canvas canvas, Rect bounds, float alpha) { super.draw(canvas, bounds, alpha); if (drawable == null) { return; } int inset = bounds.width() / 4; bounds.inset(inset, inset); drawable.setBounds(bounds); drawable.setAlpha(Math.round(alpha * 255.0f)); drawable.draw(canvas); } public Drawable getDrawable() { return drawable; } public void setDrawable(Drawable drawable) { this.drawable = drawable; } }
UTF-8
Java
1,056
java
CircleDrawableFragment.java
Java
[]
null
[]
package com.aqnichol.circleui; import android.content.Context; import android.graphics.Canvas; import android.graphics.Color; import android.graphics.Paint; import android.graphics.Rect; import android.graphics.drawable.Drawable; import android.os.Bundle; import android.view.LayoutInflater; import android.view.View; import android.view.ViewGroup; /** * A CircleImageFragment is a CircleFragment with an image. */ public class CircleDrawableFragment extends CircleFragment { private Drawable drawable = null; public void draw(Canvas canvas, Rect bounds, float alpha) { super.draw(canvas, bounds, alpha); if (drawable == null) { return; } int inset = bounds.width() / 4; bounds.inset(inset, inset); drawable.setBounds(bounds); drawable.setAlpha(Math.round(alpha * 255.0f)); drawable.draw(canvas); } public Drawable getDrawable() { return drawable; } public void setDrawable(Drawable drawable) { this.drawable = drawable; } }
1,056
0.688447
0.683712
43
23.55814
18.923717
63
false
false
0
0
0
0
0
0
0.604651
false
false
5
f339e64dde88ace2f490ae20d3d9d9bc97ad12d9
2,190,433,373,032
d85eb3439291f90aeb4f1d00b9748093adb06d10
/src/main/java/com/angsentech/ssm/easyui/Json.java
a7bb78cd8c8e54eec1b52c5ffa3b976751ba12bb
[]
no_license
FANLIYANG-OPS/netschool
https://github.com/FANLIYANG-OPS/netschool
0c12a1187443c5fb724819581c2e148ee756e65f
1806b21e424f57a3be18991746b2df973fd9a459
refs/heads/master
2020-03-26T18:45:56.707000
2018-08-21T06:51:15
2018-08-21T06:51:15
null
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
package com.angsentech.ssm.easyui; import java.util.List; import com.angsentech.ssm.entity.SxExam; /** * * JSON模型 * * 用户后台向前台返回的JSON对象 * * @author zh * */ public class Json implements java.io.Serializable { private Integer count =15; private String msg = ""; private Integer code = 0; private Object data = null; public String getMsg() { return msg; } public void setMsg(String msg) { this.msg = msg; } public Object getData() { return data; } public void setData(Object data) { this.data = data; } public Integer getCount() { return count; } public void setCount(Integer count) { this.count = count; } public Integer getCode() { return code; } public void setCode(Integer code) { this.code = code; } @Override public String toString() { return "Json [count=" + count + ", msg=" + msg + ", code=" + code + ", data=" + data + "]"; } }
UTF-8
Java
935
java
Json.java
Java
[ { "context": " \n * JSON模型\n * \n * 用户后台向前台返回的JSON对象\n * \n * @author zh\n * \n */\npublic class Json implements java.io.Seri", "end": 161, "score": 0.9981174468994141, "start": 159, "tag": "USERNAME", "value": "zh" } ]
null
[]
package com.angsentech.ssm.easyui; import java.util.List; import com.angsentech.ssm.entity.SxExam; /** * * JSON模型 * * 用户后台向前台返回的JSON对象 * * @author zh * */ public class Json implements java.io.Serializable { private Integer count =15; private String msg = ""; private Integer code = 0; private Object data = null; public String getMsg() { return msg; } public void setMsg(String msg) { this.msg = msg; } public Object getData() { return data; } public void setData(Object data) { this.data = data; } public Integer getCount() { return count; } public void setCount(Integer count) { this.count = count; } public Integer getCode() { return code; } public void setCode(Integer code) { this.code = code; } @Override public String toString() { return "Json [count=" + count + ", msg=" + msg + ", code=" + code + ", data=" + data + "]"; } }
935
0.636163
0.632856
64
13.171875
16.695391
93
false
false
0
0
0
0
0
0
0.96875
false
false
5
45766a2eb219ff7fe82bffc9f091f1ee38b9855e
28,870,770,226,313
cf52b3064d536af626339ddd30b28c0b8e15aaee
/gameserver/src/main/java/org/l2junity/gameserver/data/txt/gen/NpcDatasParser.java
f603baf407ad5ef737f4da838efdff1ba73c1e10
[]
no_license
LegacyofAden/emu-ungp
https://github.com/LegacyofAden/emu-ungp
7aaa7d9fd60698cb784d8c2c1eaaa20ef0a8d59b
b76dc91157e43d67f886b6926afd11b110ed5dce
refs/heads/master
2021-01-01T18:21:03.529000
2017-04-08T23:08:37
2017-04-08T23:08:37
null
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
// Generated from org\l2junity\gameserver\data\txt\gen\NpcDatas.g4 by ANTLR 4.7 package org.l2junity.gameserver.data.txt.gen; import org.l2junity.gameserver.data.txt.model.constants.*; import org.apache.commons.math3.geometry.euclidean.threed.Vector3D; import org.l2junity.gameserver.data.txt.model.constants.AttributeType; import org.l2junity.gameserver.data.txt.model.item.AttributeAttack; import org.antlr.v4.runtime.atn.*; import org.antlr.v4.runtime.dfa.DFA; import org.antlr.v4.runtime.*; import org.antlr.v4.runtime.misc.*; import org.antlr.v4.runtime.tree.*; import java.util.List; import java.util.Iterator; import java.util.ArrayList; @SuppressWarnings({"all", "warnings", "unchecked", "unused", "cast"}) public class NpcDatasParser extends Parser { static { RuntimeMetaData.checkVersion("4.7", RuntimeMetaData.VERSION); } protected static final DFA[] _decisionToDFA; protected static final PredictionContextCache _sharedContextCache = new PredictionContextCache(); public static final int T__0=1, T__1=2, T__2=3, T__3=4, T__4=5, T__5=6, T__6=7, T__7=8, T__8=9, T__9=10, T__10=11, T__11=12, T__12=13, T__13=14, T__14=15, T__15=16, T__16=17, T__17=18, T__18=19, T__19=20, T__20=21, T__21=22, T__22=23, T__23=24, T__24=25, T__25=26, T__26=27, T__27=28, T__28=29, T__29=30, T__30=31, T__31=32, T__32=33, T__33=34, T__34=35, T__35=36, T__36=37, T__37=38, T__38=39, T__39=40, T__40=41, T__41=42, T__42=43, T__43=44, T__44=45, T__45=46, T__46=47, T__47=48, T__48=49, T__49=50, T__50=51, T__51=52, T__52=53, T__53=54, T__54=55, T__55=56, T__56=57, T__57=58, T__58=59, T__59=60, T__60=61, T__61=62, T__62=63, T__63=64, T__64=65, T__65=66, T__66=67, T__67=68, T__68=69, T__69=70, T__70=71, T__71=72, T__72=73, T__73=74, T__74=75, T__75=76, T__76=77, T__77=78, T__78=79, T__79=80, T__80=81, T__81=82, T__82=83, T__83=84, T__84=85, T__85=86, T__86=87, T__87=88, T__88=89, T__89=90, T__90=91, T__91=92, T__92=93, MALE=94, FEMALE=95, ETC=96, CATEGORY=97, BOOLEAN=98, INTEGER=99, DOUBLE=100, FIRE=101, WATER=102, EARTH=103, WIND=104, UNHOLY=105, HOLY=106, SEMICOLON=107, NONE=108, FAIRY=109, ANIMAL=110, HUMANOID=111, PLANT=112, UNDEAD=113, CONSTRUCT=114, BEAST=115, BUG=116, ELEMENTAL=117, DEMONIC=118, GIANT=119, DRAGON=120, DIVINE=121, SUMMON=122, PET=123, HOLYTHING=124, DWARF=125, MERCHANT=126, ELF=127, KAMAEL=128, ORC=129, SIEGE_WEAPON=130, FRIEND=131, MERCENARY=132, CASTLE_GUARD=133, HUMAN=134, BOSS=135, ZZOLDAGU=136, WORLD_TRAP=137, MONRACE=138, DARKELF=139, GUARD=140, TELEPORTER=141, WAREHOUSE_KEEPER=142, WARRIOR=143, CITIZEN=144, TREASURE=145, FIELDBOSS=146, BLACKSMITH=147, GUILD_MASTER=148, GUILD_COACH=149, PC_TRAP=150, XMASTREE=151, DOPPELGANGER=152, OWNTHING=153, SIEGE_ATTACKER=154, MRKEEPER=155, COLLECTION=156, PACKAGE_KEEPER=157, SWORD=158, BLUNT=159, BOW=160, POLE=161, DAGGER=162, DUAL=163, FIST=164, DUALFIST=165, FISHINGROD=166, RAPIER=167, ANCIENTSWORD=168, CROSSBOW=169, FLAG=170, DUALDAGGER=171, LIGHT=172, HEAVY=173, MAGIC=174, SIGIL=175, RHAND=176, LRHAND=177, LHAND=178, CHEST=179, LEGS=180, FEET=181, HEAD=182, GLOVES=183, ONEPIECE=184, REAR=185, LEAR=186, RFINGER=187, LFINGER=188, NECK=189, BACK=190, UNDERWEAR=191, HAIR=192, HAIR2=193, HAIRALL=194, ALLDRESS=195, RBRACELET=196, LBRACELET=197, WAIST=198, DECO1=199, STEEL=200, FINE_STEEL=201, WOOD=202, CLOTH=203, LEATHER=204, BONE=205, BRONZE=206, ORIHARUKON=207, MITHRIL=208, DAMASCUS=209, ADAMANTAITE=210, BLOOD_STEEL=211, PAPER=212, GOLD=213, LIQUID=214, FISH=215, SILVER=216, CHRYSOLITE=217, CRYSTAL=218, HORN=219, SCALE_OF_DRAGON=220, COTTON=221, DYESTUFF=222, COBWEB=223, RUNE_XP=224, RUNE_SP=225, RUNE_REMOVE_PENALTY=226, NAME=227, WS=228, LINE_COMMENT=229, STAR_COMMENT=230; public static final int RULE_file = 0, RULE_npc = 1, RULE_npc_type = 2, RULE_npc_id = 3, RULE_npc_name = 4, RULE_category = 5, RULE_level = 6, RULE_exp = 7, RULE_ex_crt_effect = 8, RULE_unique = 9, RULE_s_npc_prop_hp_rate = 10, RULE_race = 11, RULE_sex = 12, RULE_skill_list = 13, RULE_slot_chest = 14, RULE_slot_rhand = 15, RULE_slot_lhand = 16, RULE_empty_name_object = 17, RULE_collision_radius = 18, RULE_collision_height = 19, RULE_hit_time_factor = 20, RULE_hit_time_factor_skill = 21, RULE_ground_high = 22, RULE_ground_low = 23, RULE_str = 24, RULE_int_ = 25, RULE_dex = 26, RULE_wit = 27, RULE_con = 28, RULE_men = 29, RULE_org_hp = 30, RULE_org_hp_regen = 31, RULE_org_mp = 32, RULE_org_mp_regen = 33, RULE_base_attack_type = 34, RULE_base_attack_range = 35, RULE_base_damage_range = 36, RULE_base_rand_dam = 37, RULE_base_physical_attack = 38, RULE_base_critical = 39, RULE_physical_hit_modify = 40, RULE_base_attack_speed = 41, RULE_base_reuse_delay = 42, RULE_base_magic_attack = 43, RULE_base_defend = 44, RULE_base_magic_defend = 45, RULE_base_attribute_defend = 46, RULE_physical_avoid_modify = 47, RULE_shield_defense_rate = 48, RULE_shield_defense = 49, RULE_safe_height = 50, RULE_soulshot_count = 51, RULE_spiritshot_count = 52, RULE_clan = 53, RULE_ignore_clan_list = 54, RULE_clan_help_range = 55, RULE_undying = 56, RULE_can_be_attacked = 57, RULE_corpse_time = 58, RULE_no_sleep_mode = 59, RULE_agro_range = 60, RULE_passable_door = 61, RULE_can_move = 62, RULE_flying = 63, RULE_has_summoner = 64, RULE_targetable = 65, RULE_show_name_tag = 66, RULE_abnormal_resist = 67, RULE_is_death_penalty = 68, RULE_npc_ai = 69, RULE_ai_param = 70, RULE_param_value = 71, RULE_npc_privates = 72, RULE_fstring_object = 73, RULE_event_flag = 74, RULE_unsowing = 75, RULE_private_respawn_log = 76, RULE_acquire_exp_rate = 77, RULE_acquire_sp = 78, RULE_acquire_rp = 79, RULE_corpse_make_list = 80, RULE_make_item_list = 81, RULE_make_item = 82, RULE_additional_make_list = 83, RULE_additional_make_multi_list = 84, RULE_make_group_list = 85, RULE_ex_item_drop_list = 86, RULE_vitality_item_drop_list = 87, RULE_mp_reward = 88, RULE_mp_reward_type = 89, RULE_mp_reward_affect_type = 90, RULE_fake_class_id = 91, RULE_event_drop = 92, RULE_ex_drop = 93, RULE_enable_move_after_talk = 94, RULE_broadcast_cond = 95, RULE_identifier_object = 96, RULE_bool_object = 97, RULE_byte_object = 98, RULE_int_object = 99, RULE_long_object = 100, RULE_double_object = 101, RULE_string_object = 102, RULE_name_object = 103, RULE_category_object = 104, RULE_vector3D_object = 105, RULE_empty_list = 106, RULE_identifier_list = 107, RULE_int_list = 108, RULE_double_list = 109, RULE_base_attribute_attack = 110, RULE_attack_attribute = 111, RULE_attribute = 112, RULE_category_list = 113; public static final String[] ruleNames = { "file", "npc", "npc_type", "npc_id", "npc_name", "category", "level", "exp", "ex_crt_effect", "unique", "s_npc_prop_hp_rate", "race", "sex", "skill_list", "slot_chest", "slot_rhand", "slot_lhand", "empty_name_object", "collision_radius", "collision_height", "hit_time_factor", "hit_time_factor_skill", "ground_high", "ground_low", "str", "int_", "dex", "wit", "con", "men", "org_hp", "org_hp_regen", "org_mp", "org_mp_regen", "base_attack_type", "base_attack_range", "base_damage_range", "base_rand_dam", "base_physical_attack", "base_critical", "physical_hit_modify", "base_attack_speed", "base_reuse_delay", "base_magic_attack", "base_defend", "base_magic_defend", "base_attribute_defend", "physical_avoid_modify", "shield_defense_rate", "shield_defense", "safe_height", "soulshot_count", "spiritshot_count", "clan", "ignore_clan_list", "clan_help_range", "undying", "can_be_attacked", "corpse_time", "no_sleep_mode", "agro_range", "passable_door", "can_move", "flying", "has_summoner", "targetable", "show_name_tag", "abnormal_resist", "is_death_penalty", "npc_ai", "ai_param", "param_value", "npc_privates", "fstring_object", "event_flag", "unsowing", "private_respawn_log", "acquire_exp_rate", "acquire_sp", "acquire_rp", "corpse_make_list", "make_item_list", "make_item", "additional_make_list", "additional_make_multi_list", "make_group_list", "ex_item_drop_list", "vitality_item_drop_list", "mp_reward", "mp_reward_type", "mp_reward_affect_type", "fake_class_id", "event_drop", "ex_drop", "enable_move_after_talk", "broadcast_cond", "identifier_object", "bool_object", "byte_object", "int_object", "long_object", "double_object", "string_object", "name_object", "category_object", "vector3D_object", "empty_list", "identifier_list", "int_list", "double_list", "base_attribute_attack", "attack_attribute", "attribute", "category_list" }; private static final String[] _LITERAL_NAMES = { null, "'npc_begin'", "'npc_end'", "'category'", "'='", "'{'", "'}'", "'level'", "'exp'", "'ex_crt_effect'", "'unique'", "'s_npc_prop_hp_rate'", "'race'", "'sex'", "'skill_list'", "'slot_chest'", "'slot_rhand'", "'slot_lhand'", "'['", "']'", "'collision_radius'", "'collision_height'", "'hit_time_factor'", "'hit_time_factor_skill'", "'ground_high'", "'ground_low'", "'str'", "'int'", "'dex'", "'wit'", "'con'", "'men'", "'org_hp'", "'org_hp_regen'", "'org_mp'", "'org_mp_regen'", "'base_attack_type'", "'base_attack_range'", "'base_damage_range'", "'base_rand_dam'", "'base_physical_attack'", "'base_critical'", "'physical_hit_modify'", "'base_attack_speed'", "'base_reuse_delay'", "'base_magic_attack'", "'base_defend'", "'base_magic_defend'", "'base_attribute_defend'", "'physical_avoid_modify'", "'shield_defense_rate'", "'shield_defense'", "'safe_height'", "'soulshot_count'", "'spiritshot_count'", "'clan'", "'ignore_clan_list'", "'clan_help_range'", "'undying'", "'can_be_attacked'", "'corpse_time'", "'no_sleep_mode'", "'agro_range'", "'passable_door'", "'can_move'", "'flying'", "'has_summoner'", "'targetable'", "'show_name_tag'", "'abnormal_resist'", "'is_death_penalty'", "'npc_ai'", "'event_flag'", "'unsowing'", "'private_respawn_log'", "'acquire_exp_rate'", "'acquire_sp'", "'acquire_rp'", "'corpse_make_list'", "'additional_make_list'", "'additional_make_multi_list'", "'ex_item_drop_list'", "'vitality_item_drop_list'", "'mp_reward'", "'per'", "'diff'", "'solo'", "'party'", "'fake_class_id'", "'event_drop'", "'ex_drop'", "'enable_move_after_talk'", "'broadcast_cond'", "'base_attribute_attack'", "'male'", "'female'", "'etc'", null, null, null, null, "'fire'", "'water'", "'earth'", "'wind'", "'unholy'", "'holy'", "';'", "'none'", "'fairy'", "'animal'", "'humanoid'", "'plant'", "'undead'", "'construct'", "'beast'", "'bug'", "'elemental'", "'demonic'", "'giant'", "'dragon'", "'divine'", "'summon'", "'pet'", "'holything'", "'dwarf'", "'merchant'", "'elf'", "'kamael'", "'orc'", "'siege_weapon'", "'friend'", "'mercenary'", "'castle_guard'", "'human'", "'boss'", "'zzoldagu'", "'world_trap'", "'monrace'", "'darkelf'", "'guard'", "'teleporter'", "'warehouse_keeper'", "'warrior'", "'citizen'", "'treasure'", "'fieldboss'", "'blacksmith'", "'guild_master'", "'guild_coach'", "'pc_trap'", "'xmastree'", "'doppelganger'", "'ownthing'", "'siege_attacker'", "'mrkeeper'", "'collection'", "'package_keeper'", "'sword'", "'blunt'", "'bow'", "'pole'", "'dagger'", "'dual'", "'fist'", "'dualfist'", "'fishingrod'", "'rapier'", "'ancientsword'", "'crossbow'", "'flag'", "'dualdagger'", "'light'", "'heavy'", "'magic'", "'sigil'", "'rhand'", "'lrhand'", "'lhand'", "'chest'", "'legs'", "'feet'", "'head'", "'gloves'", "'onepiece'", "'rear'", "'lear'", "'rfinger'", "'lfinger'", "'neck'", "'back'", "'underwear'", "'hair'", "'hair2'", "'hairall'", "'alldress'", "'rbracelet'", "'lbracelet'", "'waist'", "'deco1'", "'steel'", "'fine_steel'", "'wood'", "'cloth'", "'leather'", "'bone'", "'bronze'", "'oriharukon'", "'mithril'", "'damascus'", "'adamantaite'", "'blood_steel'", "'paper'", "'gold'", "'liquid'", "'fish'", "'silver'", "'chrysolite'", "'crystal'", "'horn'", "'scale_of_dragon'", "'cotton'", "'dyestuff'", "'cobweb'", "'rune_xp'", "'rune_sp'", "'rune_remove_penalty'" }; private static final String[] _SYMBOLIC_NAMES = { null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, "MALE", "FEMALE", "ETC", "CATEGORY", "BOOLEAN", "INTEGER", "DOUBLE", "FIRE", "WATER", "EARTH", "WIND", "UNHOLY", "HOLY", "SEMICOLON", "NONE", "FAIRY", "ANIMAL", "HUMANOID", "PLANT", "UNDEAD", "CONSTRUCT", "BEAST", "BUG", "ELEMENTAL", "DEMONIC", "GIANT", "DRAGON", "DIVINE", "SUMMON", "PET", "HOLYTHING", "DWARF", "MERCHANT", "ELF", "KAMAEL", "ORC", "SIEGE_WEAPON", "FRIEND", "MERCENARY", "CASTLE_GUARD", "HUMAN", "BOSS", "ZZOLDAGU", "WORLD_TRAP", "MONRACE", "DARKELF", "GUARD", "TELEPORTER", "WAREHOUSE_KEEPER", "WARRIOR", "CITIZEN", "TREASURE", "FIELDBOSS", "BLACKSMITH", "GUILD_MASTER", "GUILD_COACH", "PC_TRAP", "XMASTREE", "DOPPELGANGER", "OWNTHING", "SIEGE_ATTACKER", "MRKEEPER", "COLLECTION", "PACKAGE_KEEPER", "SWORD", "BLUNT", "BOW", "POLE", "DAGGER", "DUAL", "FIST", "DUALFIST", "FISHINGROD", "RAPIER", "ANCIENTSWORD", "CROSSBOW", "FLAG", "DUALDAGGER", "LIGHT", "HEAVY", "MAGIC", "SIGIL", "RHAND", "LRHAND", "LHAND", "CHEST", "LEGS", "FEET", "HEAD", "GLOVES", "ONEPIECE", "REAR", "LEAR", "RFINGER", "LFINGER", "NECK", "BACK", "UNDERWEAR", "HAIR", "HAIR2", "HAIRALL", "ALLDRESS", "RBRACELET", "LBRACELET", "WAIST", "DECO1", "STEEL", "FINE_STEEL", "WOOD", "CLOTH", "LEATHER", "BONE", "BRONZE", "ORIHARUKON", "MITHRIL", "DAMASCUS", "ADAMANTAITE", "BLOOD_STEEL", "PAPER", "GOLD", "LIQUID", "FISH", "SILVER", "CHRYSOLITE", "CRYSTAL", "HORN", "SCALE_OF_DRAGON", "COTTON", "DYESTUFF", "COBWEB", "RUNE_XP", "RUNE_SP", "RUNE_REMOVE_PENALTY", "NAME", "WS", "LINE_COMMENT", "STAR_COMMENT" }; public static final Vocabulary VOCABULARY = new VocabularyImpl(_LITERAL_NAMES, _SYMBOLIC_NAMES); /** * @deprecated Use {@link #VOCABULARY} instead. */ @Deprecated public static final String[] tokenNames; static { tokenNames = new String[_SYMBOLIC_NAMES.length]; for (int i = 0; i < tokenNames.length; i++) { tokenNames[i] = VOCABULARY.getLiteralName(i); if (tokenNames[i] == null) { tokenNames[i] = VOCABULARY.getSymbolicName(i); } if (tokenNames[i] == null) { tokenNames[i] = "<INVALID>"; } } } @Override @Deprecated public String[] getTokenNames() { return tokenNames; } @Override public Vocabulary getVocabulary() { return VOCABULARY; } @Override public String getGrammarFileName() { return "NpcDatas.g4"; } @Override public String[] getRuleNames() { return ruleNames; } @Override public String getSerializedATN() { return _serializedATN; } @Override public ATN getATN() { return _ATN; } public NpcDatasParser(TokenStream input) { super(input); _interp = new ParserATNSimulator(this,_ATN,_decisionToDFA,_sharedContextCache); } public static class FileContext extends ParserRuleContext { public List<NpcContext> npc() { return getRuleContexts(NpcContext.class); } public NpcContext npc(int i) { return getRuleContext(NpcContext.class,i); } public FileContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_file; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterFile(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitFile(this); } } public final FileContext file() throws RecognitionException { FileContext _localctx = new FileContext(_ctx, getState()); enterRule(_localctx, 0, RULE_file); int _la; try { enterOuterAlt(_localctx, 1); { setState(229); _errHandler.sync(this); _la = _input.LA(1); do { { { setState(228); npc(); } } setState(231); _errHandler.sync(this); _la = _input.LA(1); } while ( _la==T__0 ); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class NpcContext extends ParserRuleContext { public Npc_typeContext npc_type() { return getRuleContext(Npc_typeContext.class,0); } public Npc_idContext npc_id() { return getRuleContext(Npc_idContext.class,0); } public Npc_nameContext npc_name() { return getRuleContext(Npc_nameContext.class,0); } public CategoryContext category() { return getRuleContext(CategoryContext.class,0); } public LevelContext level() { return getRuleContext(LevelContext.class,0); } public ExpContext exp() { return getRuleContext(ExpContext.class,0); } public Ex_crt_effectContext ex_crt_effect() { return getRuleContext(Ex_crt_effectContext.class,0); } public UniqueContext unique() { return getRuleContext(UniqueContext.class,0); } public S_npc_prop_hp_rateContext s_npc_prop_hp_rate() { return getRuleContext(S_npc_prop_hp_rateContext.class,0); } public RaceContext race() { return getRuleContext(RaceContext.class,0); } public SexContext sex() { return getRuleContext(SexContext.class,0); } public Skill_listContext skill_list() { return getRuleContext(Skill_listContext.class,0); } public Slot_chestContext slot_chest() { return getRuleContext(Slot_chestContext.class,0); } public Slot_rhandContext slot_rhand() { return getRuleContext(Slot_rhandContext.class,0); } public Slot_lhandContext slot_lhand() { return getRuleContext(Slot_lhandContext.class,0); } public Collision_radiusContext collision_radius() { return getRuleContext(Collision_radiusContext.class,0); } public Collision_heightContext collision_height() { return getRuleContext(Collision_heightContext.class,0); } public Hit_time_factorContext hit_time_factor() { return getRuleContext(Hit_time_factorContext.class,0); } public Hit_time_factor_skillContext hit_time_factor_skill() { return getRuleContext(Hit_time_factor_skillContext.class,0); } public Ground_highContext ground_high() { return getRuleContext(Ground_highContext.class,0); } public Ground_lowContext ground_low() { return getRuleContext(Ground_lowContext.class,0); } public StrContext str() { return getRuleContext(StrContext.class,0); } public Int_Context int_() { return getRuleContext(Int_Context.class,0); } public DexContext dex() { return getRuleContext(DexContext.class,0); } public WitContext wit() { return getRuleContext(WitContext.class,0); } public ConContext con() { return getRuleContext(ConContext.class,0); } public MenContext men() { return getRuleContext(MenContext.class,0); } public Org_hpContext org_hp() { return getRuleContext(Org_hpContext.class,0); } public Org_hp_regenContext org_hp_regen() { return getRuleContext(Org_hp_regenContext.class,0); } public Org_mpContext org_mp() { return getRuleContext(Org_mpContext.class,0); } public Org_mp_regenContext org_mp_regen() { return getRuleContext(Org_mp_regenContext.class,0); } public Base_attack_typeContext base_attack_type() { return getRuleContext(Base_attack_typeContext.class,0); } public Base_attack_rangeContext base_attack_range() { return getRuleContext(Base_attack_rangeContext.class,0); } public Base_damage_rangeContext base_damage_range() { return getRuleContext(Base_damage_rangeContext.class,0); } public Base_rand_damContext base_rand_dam() { return getRuleContext(Base_rand_damContext.class,0); } public Base_physical_attackContext base_physical_attack() { return getRuleContext(Base_physical_attackContext.class,0); } public Base_criticalContext base_critical() { return getRuleContext(Base_criticalContext.class,0); } public Physical_hit_modifyContext physical_hit_modify() { return getRuleContext(Physical_hit_modifyContext.class,0); } public Base_attack_speedContext base_attack_speed() { return getRuleContext(Base_attack_speedContext.class,0); } public Base_reuse_delayContext base_reuse_delay() { return getRuleContext(Base_reuse_delayContext.class,0); } public Base_magic_attackContext base_magic_attack() { return getRuleContext(Base_magic_attackContext.class,0); } public Base_defendContext base_defend() { return getRuleContext(Base_defendContext.class,0); } public Base_magic_defendContext base_magic_defend() { return getRuleContext(Base_magic_defendContext.class,0); } public Base_attribute_attackContext base_attribute_attack() { return getRuleContext(Base_attribute_attackContext.class,0); } public Base_attribute_defendContext base_attribute_defend() { return getRuleContext(Base_attribute_defendContext.class,0); } public Physical_avoid_modifyContext physical_avoid_modify() { return getRuleContext(Physical_avoid_modifyContext.class,0); } public Shield_defense_rateContext shield_defense_rate() { return getRuleContext(Shield_defense_rateContext.class,0); } public Shield_defenseContext shield_defense() { return getRuleContext(Shield_defenseContext.class,0); } public Safe_heightContext safe_height() { return getRuleContext(Safe_heightContext.class,0); } public Soulshot_countContext soulshot_count() { return getRuleContext(Soulshot_countContext.class,0); } public Spiritshot_countContext spiritshot_count() { return getRuleContext(Spiritshot_countContext.class,0); } public ClanContext clan() { return getRuleContext(ClanContext.class,0); } public Ignore_clan_listContext ignore_clan_list() { return getRuleContext(Ignore_clan_listContext.class,0); } public Clan_help_rangeContext clan_help_range() { return getRuleContext(Clan_help_rangeContext.class,0); } public UndyingContext undying() { return getRuleContext(UndyingContext.class,0); } public Can_be_attackedContext can_be_attacked() { return getRuleContext(Can_be_attackedContext.class,0); } public Corpse_timeContext corpse_time() { return getRuleContext(Corpse_timeContext.class,0); } public No_sleep_modeContext no_sleep_mode() { return getRuleContext(No_sleep_modeContext.class,0); } public Agro_rangeContext agro_range() { return getRuleContext(Agro_rangeContext.class,0); } public Passable_doorContext passable_door() { return getRuleContext(Passable_doorContext.class,0); } public Can_moveContext can_move() { return getRuleContext(Can_moveContext.class,0); } public FlyingContext flying() { return getRuleContext(FlyingContext.class,0); } public Has_summonerContext has_summoner() { return getRuleContext(Has_summonerContext.class,0); } public TargetableContext targetable() { return getRuleContext(TargetableContext.class,0); } public Show_name_tagContext show_name_tag() { return getRuleContext(Show_name_tagContext.class,0); } public Abnormal_resistContext abnormal_resist() { return getRuleContext(Abnormal_resistContext.class,0); } public Is_death_penaltyContext is_death_penalty() { return getRuleContext(Is_death_penaltyContext.class,0); } public Npc_aiContext npc_ai() { return getRuleContext(Npc_aiContext.class,0); } public Event_flagContext event_flag() { return getRuleContext(Event_flagContext.class,0); } public UnsowingContext unsowing() { return getRuleContext(UnsowingContext.class,0); } public Private_respawn_logContext private_respawn_log() { return getRuleContext(Private_respawn_logContext.class,0); } public Acquire_exp_rateContext acquire_exp_rate() { return getRuleContext(Acquire_exp_rateContext.class,0); } public Acquire_spContext acquire_sp() { return getRuleContext(Acquire_spContext.class,0); } public Acquire_rpContext acquire_rp() { return getRuleContext(Acquire_rpContext.class,0); } public Corpse_make_listContext corpse_make_list() { return getRuleContext(Corpse_make_listContext.class,0); } public Additional_make_listContext additional_make_list() { return getRuleContext(Additional_make_listContext.class,0); } public Additional_make_multi_listContext additional_make_multi_list() { return getRuleContext(Additional_make_multi_listContext.class,0); } public Ex_item_drop_listContext ex_item_drop_list() { return getRuleContext(Ex_item_drop_listContext.class,0); } public Vitality_item_drop_listContext vitality_item_drop_list() { return getRuleContext(Vitality_item_drop_listContext.class,0); } public Mp_rewardContext mp_reward() { return getRuleContext(Mp_rewardContext.class,0); } public Fake_class_idContext fake_class_id() { return getRuleContext(Fake_class_idContext.class,0); } public Event_dropContext event_drop() { return getRuleContext(Event_dropContext.class,0); } public Ex_dropContext ex_drop() { return getRuleContext(Ex_dropContext.class,0); } public Enable_move_after_talkContext enable_move_after_talk() { return getRuleContext(Enable_move_after_talkContext.class,0); } public Broadcast_condContext broadcast_cond() { return getRuleContext(Broadcast_condContext.class,0); } public NpcContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_npc; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterNpc(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitNpc(this); } } public final NpcContext npc() throws RecognitionException { NpcContext _localctx = new NpcContext(_ctx, getState()); enterRule(_localctx, 2, RULE_npc); try { enterOuterAlt(_localctx, 1); { setState(233); match(T__0); setState(234); npc_type(); setState(235); npc_id(); setState(236); npc_name(); setState(237); category(); setState(238); level(); setState(239); exp(); setState(240); ex_crt_effect(); setState(241); unique(); setState(242); s_npc_prop_hp_rate(); setState(243); race(); setState(244); sex(); setState(245); skill_list(); setState(246); slot_chest(); setState(247); slot_rhand(); setState(248); slot_lhand(); setState(249); collision_radius(); setState(250); collision_height(); setState(251); hit_time_factor(); setState(252); hit_time_factor_skill(); setState(253); ground_high(); setState(254); ground_low(); setState(255); str(); setState(256); int_(); setState(257); dex(); setState(258); wit(); setState(259); con(); setState(260); men(); setState(261); org_hp(); setState(262); org_hp_regen(); setState(263); org_mp(); setState(264); org_mp_regen(); setState(265); base_attack_type(); setState(266); base_attack_range(); setState(267); base_damage_range(); setState(268); base_rand_dam(); setState(269); base_physical_attack(); setState(270); base_critical(); setState(271); physical_hit_modify(); setState(272); base_attack_speed(); setState(273); base_reuse_delay(); setState(274); base_magic_attack(); setState(275); base_defend(); setState(276); base_magic_defend(); setState(277); base_attribute_attack(); setState(278); base_attribute_defend(); setState(279); physical_avoid_modify(); setState(280); shield_defense_rate(); setState(281); shield_defense(); setState(282); safe_height(); setState(283); soulshot_count(); setState(284); spiritshot_count(); setState(285); clan(); setState(286); ignore_clan_list(); setState(287); clan_help_range(); setState(288); undying(); setState(289); can_be_attacked(); setState(290); corpse_time(); setState(291); no_sleep_mode(); setState(292); agro_range(); setState(293); passable_door(); setState(294); can_move(); setState(295); flying(); setState(296); has_summoner(); setState(297); targetable(); setState(298); show_name_tag(); setState(299); abnormal_resist(); setState(300); is_death_penalty(); setState(301); npc_ai(); setState(302); event_flag(); setState(303); unsowing(); setState(304); private_respawn_log(); setState(305); acquire_exp_rate(); setState(306); acquire_sp(); setState(307); acquire_rp(); setState(308); corpse_make_list(); setState(309); additional_make_list(); setState(310); additional_make_multi_list(); setState(311); ex_item_drop_list(); setState(312); vitality_item_drop_list(); setState(313); mp_reward(); setState(314); fake_class_id(); setState(315); event_drop(); setState(316); ex_drop(); setState(317); enable_move_after_talk(); setState(318); broadcast_cond(); setState(319); match(T__1); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Npc_typeContext extends ParserRuleContext { public NpcType value; public TerminalNode WARRIOR() { return getToken(NpcDatasParser.WARRIOR, 0); } public TerminalNode TREASURE() { return getToken(NpcDatasParser.TREASURE, 0); } public TerminalNode CITIZEN() { return getToken(NpcDatasParser.CITIZEN, 0); } public TerminalNode ZZOLDAGU() { return getToken(NpcDatasParser.ZZOLDAGU, 0); } public TerminalNode BOSS() { return getToken(NpcDatasParser.BOSS, 0); } public TerminalNode FIELDBOSS() { return getToken(NpcDatasParser.FIELDBOSS, 0); } public TerminalNode WORLD_TRAP() { return getToken(NpcDatasParser.WORLD_TRAP, 0); } public TerminalNode MERCHANT() { return getToken(NpcDatasParser.MERCHANT, 0); } public TerminalNode HOLYTHING() { return getToken(NpcDatasParser.HOLYTHING, 0); } public TerminalNode WAREHOUSE_KEEPER() { return getToken(NpcDatasParser.WAREHOUSE_KEEPER, 0); } public TerminalNode BLACKSMITH() { return getToken(NpcDatasParser.BLACKSMITH, 0); } public TerminalNode TELEPORTER() { return getToken(NpcDatasParser.TELEPORTER, 0); } public TerminalNode GUILD_MASTER() { return getToken(NpcDatasParser.GUILD_MASTER, 0); } public TerminalNode GUILD_COACH() { return getToken(NpcDatasParser.GUILD_COACH, 0); } public TerminalNode GUARD() { return getToken(NpcDatasParser.GUARD, 0); } public TerminalNode MONRACE() { return getToken(NpcDatasParser.MONRACE, 0); } public TerminalNode PC_TRAP() { return getToken(NpcDatasParser.PC_TRAP, 0); } public TerminalNode XMASTREE() { return getToken(NpcDatasParser.XMASTREE, 0); } public TerminalNode PET() { return getToken(NpcDatasParser.PET, 0); } public TerminalNode SUMMON() { return getToken(NpcDatasParser.SUMMON, 0); } public TerminalNode DOPPELGANGER() { return getToken(NpcDatasParser.DOPPELGANGER, 0); } public TerminalNode OWNTHING() { return getToken(NpcDatasParser.OWNTHING, 0); } public TerminalNode SIEGE_ATTACKER() { return getToken(NpcDatasParser.SIEGE_ATTACKER, 0); } public TerminalNode MRKEEPER() { return getToken(NpcDatasParser.MRKEEPER, 0); } public TerminalNode COLLECTION() { return getToken(NpcDatasParser.COLLECTION, 0); } public TerminalNode PACKAGE_KEEPER() { return getToken(NpcDatasParser.PACKAGE_KEEPER, 0); } public Npc_typeContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_npc_type; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterNpc_type(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitNpc_type(this); } } public final Npc_typeContext npc_type() throws RecognitionException { Npc_typeContext _localctx = new Npc_typeContext(_ctx, getState()); enterRule(_localctx, 4, RULE_npc_type); try { setState(373); _errHandler.sync(this); switch (_input.LA(1)) { case WARRIOR: enterOuterAlt(_localctx, 1); { setState(321); match(WARRIOR); _localctx.value = NpcType.WARRIOR; } break; case TREASURE: enterOuterAlt(_localctx, 2); { setState(323); match(TREASURE); _localctx.value = NpcType.TREASURE; } break; case CITIZEN: enterOuterAlt(_localctx, 3); { setState(325); match(CITIZEN); _localctx.value = NpcType.CITIZEN; } break; case ZZOLDAGU: enterOuterAlt(_localctx, 4); { setState(327); match(ZZOLDAGU); _localctx.value = NpcType.ZZOLDAGU; } break; case BOSS: enterOuterAlt(_localctx, 5); { setState(329); match(BOSS); _localctx.value = NpcType.BOSS; } break; case FIELDBOSS: enterOuterAlt(_localctx, 6); { setState(331); match(FIELDBOSS); _localctx.value = NpcType.FIELDBOSS; } break; case WORLD_TRAP: enterOuterAlt(_localctx, 7); { setState(333); match(WORLD_TRAP); _localctx.value = NpcType.WORLD_TRAP; } break; case MERCHANT: enterOuterAlt(_localctx, 8); { setState(335); match(MERCHANT); _localctx.value = NpcType.MERCHANT; } break; case HOLYTHING: enterOuterAlt(_localctx, 9); { setState(337); match(HOLYTHING); _localctx.value = NpcType.HOLYTHING; } break; case WAREHOUSE_KEEPER: enterOuterAlt(_localctx, 10); { setState(339); match(WAREHOUSE_KEEPER); _localctx.value = NpcType.WAREHOUSE_KEEPER; } break; case BLACKSMITH: enterOuterAlt(_localctx, 11); { setState(341); match(BLACKSMITH); _localctx.value = NpcType.BLACKSMITH; } break; case TELEPORTER: enterOuterAlt(_localctx, 12); { setState(343); match(TELEPORTER); _localctx.value = NpcType.TELEPORTER; } break; case GUILD_MASTER: enterOuterAlt(_localctx, 13); { setState(345); match(GUILD_MASTER); _localctx.value = NpcType.GUILD_MASTER; } break; case GUILD_COACH: enterOuterAlt(_localctx, 14); { setState(347); match(GUILD_COACH); _localctx.value = NpcType.GUILD_COACH; } break; case GUARD: enterOuterAlt(_localctx, 15); { setState(349); match(GUARD); _localctx.value = NpcType.GUARD; } break; case MONRACE: enterOuterAlt(_localctx, 16); { setState(351); match(MONRACE); _localctx.value = NpcType.MONRACE; } break; case PC_TRAP: enterOuterAlt(_localctx, 17); { setState(353); match(PC_TRAP); _localctx.value = NpcType.PC_TRAP; } break; case XMASTREE: enterOuterAlt(_localctx, 18); { setState(355); match(XMASTREE); _localctx.value = NpcType.XMASTREE; } break; case PET: enterOuterAlt(_localctx, 19); { setState(357); match(PET); _localctx.value = NpcType.PET; } break; case SUMMON: enterOuterAlt(_localctx, 20); { setState(359); match(SUMMON); _localctx.value = NpcType.SUMMON; } break; case DOPPELGANGER: enterOuterAlt(_localctx, 21); { setState(361); match(DOPPELGANGER); _localctx.value = NpcType.DOPPELGANGER; } break; case OWNTHING: enterOuterAlt(_localctx, 22); { setState(363); match(OWNTHING); _localctx.value = NpcType.OWNTHING; } break; case SIEGE_ATTACKER: enterOuterAlt(_localctx, 23); { setState(365); match(SIEGE_ATTACKER); _localctx.value = NpcType.SIEGE_ATTACKER; } break; case MRKEEPER: enterOuterAlt(_localctx, 24); { setState(367); match(MRKEEPER); _localctx.value = NpcType.MRKEEPER; } break; case COLLECTION: enterOuterAlt(_localctx, 25); { setState(369); match(COLLECTION); _localctx.value = NpcType.COLLECTION; } break; case PACKAGE_KEEPER: enterOuterAlt(_localctx, 26); { setState(371); match(PACKAGE_KEEPER); _localctx.value = NpcType.PACKAGE_KEEPER; } break; default: throw new NoViableAltException(this); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Npc_idContext extends ParserRuleContext { public int value; public Int_objectContext io; public Int_objectContext int_object() { return getRuleContext(Int_objectContext.class,0); } public Npc_idContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_npc_id; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterNpc_id(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitNpc_id(this); } } public final Npc_idContext npc_id() throws RecognitionException { Npc_idContext _localctx = new Npc_idContext(_ctx, getState()); enterRule(_localctx, 6, RULE_npc_id); try { enterOuterAlt(_localctx, 1); { setState(375); ((Npc_idContext)_localctx).io = int_object(); _localctx.value = ((Npc_idContext)_localctx).io.value; } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Npc_nameContext extends ParserRuleContext { public String value; public Name_objectContext no; public Name_objectContext name_object() { return getRuleContext(Name_objectContext.class,0); } public Npc_nameContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_npc_name; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterNpc_name(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitNpc_name(this); } } public final Npc_nameContext npc_name() throws RecognitionException { Npc_nameContext _localctx = new Npc_nameContext(_ctx, getState()); enterRule(_localctx, 8, RULE_npc_name); try { enterOuterAlt(_localctx, 1); { setState(378); ((Npc_nameContext)_localctx).no = name_object(); _localctx.value = ((Npc_nameContext)_localctx).no.value; } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class CategoryContext extends ParserRuleContext { public CategoryContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_category; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterCategory(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitCategory(this); } } public final CategoryContext category() throws RecognitionException { CategoryContext _localctx = new CategoryContext(_ctx, getState()); enterRule(_localctx, 10, RULE_category); try { enterOuterAlt(_localctx, 1); { setState(381); match(T__2); setState(382); match(T__3); setState(383); match(T__4); setState(384); match(T__5); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class LevelContext extends ParserRuleContext { public Int_objectContext io; public Int_objectContext int_object() { return getRuleContext(Int_objectContext.class,0); } public LevelContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_level; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterLevel(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitLevel(this); } } public final LevelContext level() throws RecognitionException { LevelContext _localctx = new LevelContext(_ctx, getState()); enterRule(_localctx, 12, RULE_level); try { enterOuterAlt(_localctx, 1); { setState(386); match(T__6); setState(387); match(T__3); setState(388); ((LevelContext)_localctx).io = int_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class ExpContext extends ParserRuleContext { public Long_objectContext lo; public Long_objectContext long_object() { return getRuleContext(Long_objectContext.class,0); } public ExpContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_exp; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterExp(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitExp(this); } } public final ExpContext exp() throws RecognitionException { ExpContext _localctx = new ExpContext(_ctx, getState()); enterRule(_localctx, 14, RULE_exp); try { enterOuterAlt(_localctx, 1); { setState(390); match(T__7); setState(391); match(T__3); setState(392); ((ExpContext)_localctx).lo = long_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Ex_crt_effectContext extends ParserRuleContext { public Bool_objectContext bo; public Bool_objectContext bool_object() { return getRuleContext(Bool_objectContext.class,0); } public Ex_crt_effectContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_ex_crt_effect; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterEx_crt_effect(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitEx_crt_effect(this); } } public final Ex_crt_effectContext ex_crt_effect() throws RecognitionException { Ex_crt_effectContext _localctx = new Ex_crt_effectContext(_ctx, getState()); enterRule(_localctx, 16, RULE_ex_crt_effect); try { enterOuterAlt(_localctx, 1); { setState(394); match(T__8); setState(395); match(T__3); setState(401); _errHandler.sync(this); switch (_input.LA(1)) { case BOOLEAN: { setState(396); ((Ex_crt_effectContext)_localctx).bo = bool_object(); } break; case T__4: { setState(397); match(T__4); setState(398); ((Ex_crt_effectContext)_localctx).bo = bool_object(); setState(399); match(T__5); } break; default: throw new NoViableAltException(this); } } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class UniqueContext extends ParserRuleContext { public Bool_objectContext bo; public Bool_objectContext bool_object() { return getRuleContext(Bool_objectContext.class,0); } public UniqueContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_unique; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterUnique(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitUnique(this); } } public final UniqueContext unique() throws RecognitionException { UniqueContext _localctx = new UniqueContext(_ctx, getState()); enterRule(_localctx, 18, RULE_unique); try { enterOuterAlt(_localctx, 1); { setState(403); match(T__9); setState(404); match(T__3); setState(405); ((UniqueContext)_localctx).bo = bool_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class S_npc_prop_hp_rateContext extends ParserRuleContext { public Double_objectContext d; public Double_objectContext double_object() { return getRuleContext(Double_objectContext.class,0); } public S_npc_prop_hp_rateContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_s_npc_prop_hp_rate; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterS_npc_prop_hp_rate(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitS_npc_prop_hp_rate(this); } } public final S_npc_prop_hp_rateContext s_npc_prop_hp_rate() throws RecognitionException { S_npc_prop_hp_rateContext _localctx = new S_npc_prop_hp_rateContext(_ctx, getState()); enterRule(_localctx, 20, RULE_s_npc_prop_hp_rate); try { enterOuterAlt(_localctx, 1); { setState(407); match(T__10); setState(408); match(T__3); setState(409); ((S_npc_prop_hp_rateContext)_localctx).d = double_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class RaceContext extends ParserRuleContext { public RaceType value; public TerminalNode FAIRY() { return getToken(NpcDatasParser.FAIRY, 0); } public TerminalNode ANIMAL() { return getToken(NpcDatasParser.ANIMAL, 0); } public TerminalNode HUMANOID() { return getToken(NpcDatasParser.HUMANOID, 0); } public TerminalNode PLANT() { return getToken(NpcDatasParser.PLANT, 0); } public TerminalNode UNDEAD() { return getToken(NpcDatasParser.UNDEAD, 0); } public TerminalNode CONSTRUCT() { return getToken(NpcDatasParser.CONSTRUCT, 0); } public TerminalNode BEAST() { return getToken(NpcDatasParser.BEAST, 0); } public TerminalNode BUG() { return getToken(NpcDatasParser.BUG, 0); } public TerminalNode ELEMENTAL() { return getToken(NpcDatasParser.ELEMENTAL, 0); } public TerminalNode DEMONIC() { return getToken(NpcDatasParser.DEMONIC, 0); } public TerminalNode DRAGON() { return getToken(NpcDatasParser.DRAGON, 0); } public TerminalNode GIANT() { return getToken(NpcDatasParser.GIANT, 0); } public TerminalNode DIVINE() { return getToken(NpcDatasParser.DIVINE, 0); } public TerminalNode ETC() { return getToken(NpcDatasParser.ETC, 0); } public TerminalNode SUMMON() { return getToken(NpcDatasParser.SUMMON, 0); } public TerminalNode PET() { return getToken(NpcDatasParser.PET, 0); } public TerminalNode HOLYTHING() { return getToken(NpcDatasParser.HOLYTHING, 0); } public TerminalNode DWARF() { return getToken(NpcDatasParser.DWARF, 0); } public TerminalNode MERCHANT() { return getToken(NpcDatasParser.MERCHANT, 0); } public TerminalNode ELF() { return getToken(NpcDatasParser.ELF, 0); } public TerminalNode KAMAEL() { return getToken(NpcDatasParser.KAMAEL, 0); } public TerminalNode ORC() { return getToken(NpcDatasParser.ORC, 0); } public TerminalNode MERCENARY() { return getToken(NpcDatasParser.MERCENARY, 0); } public TerminalNode CASTLE_GUARD() { return getToken(NpcDatasParser.CASTLE_GUARD, 0); } public TerminalNode HUMAN() { return getToken(NpcDatasParser.HUMAN, 0); } public TerminalNode BOSS() { return getToken(NpcDatasParser.BOSS, 0); } public TerminalNode ZZOLDAGU() { return getToken(NpcDatasParser.ZZOLDAGU, 0); } public TerminalNode WORLD_TRAP() { return getToken(NpcDatasParser.WORLD_TRAP, 0); } public TerminalNode MONRACE() { return getToken(NpcDatasParser.MONRACE, 0); } public TerminalNode GUARD() { return getToken(NpcDatasParser.GUARD, 0); } public TerminalNode TELEPORTER() { return getToken(NpcDatasParser.TELEPORTER, 0); } public TerminalNode WAREHOUSE_KEEPER() { return getToken(NpcDatasParser.WAREHOUSE_KEEPER, 0); } public TerminalNode DARKELF() { return getToken(NpcDatasParser.DARKELF, 0); } public TerminalNode SIEGE_WEAPON() { return getToken(NpcDatasParser.SIEGE_WEAPON, 0); } public TerminalNode FRIEND() { return getToken(NpcDatasParser.FRIEND, 0); } public RaceContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_race; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterRace(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitRace(this); } } public final RaceContext race() throws RecognitionException { RaceContext _localctx = new RaceContext(_ctx, getState()); enterRule(_localctx, 22, RULE_race); try { enterOuterAlt(_localctx, 1); { setState(411); match(T__11); setState(412); match(T__3); setState(483); _errHandler.sync(this); switch (_input.LA(1)) { case FAIRY: { setState(413); match(FAIRY); _localctx.value = RaceType.FAIRY; } break; case ANIMAL: { setState(415); match(ANIMAL); _localctx.value = RaceType.ANIMAL; } break; case HUMANOID: { setState(417); match(HUMANOID); _localctx.value = RaceType.HUMANOID; } break; case PLANT: { setState(419); match(PLANT); _localctx.value = RaceType.PLANT; } break; case UNDEAD: { setState(421); match(UNDEAD); _localctx.value = RaceType.UNDEAD; } break; case CONSTRUCT: { setState(423); match(CONSTRUCT); _localctx.value = RaceType.CONSTRUCT; } break; case BEAST: { setState(425); match(BEAST); _localctx.value = RaceType.BEAST; } break; case BUG: { setState(427); match(BUG); _localctx.value = RaceType.BUG; } break; case ELEMENTAL: { setState(429); match(ELEMENTAL); _localctx.value = RaceType.ELEMENTAL; } break; case DEMONIC: { setState(431); match(DEMONIC); _localctx.value = RaceType.DEMONIC; } break; case DRAGON: { setState(433); match(DRAGON); _localctx.value = RaceType.DRAGON; } break; case GIANT: { setState(435); match(GIANT); _localctx.value = RaceType.GIANT; } break; case DIVINE: { setState(437); match(DIVINE); _localctx.value = RaceType.DIVINE; } break; case ETC: { setState(439); match(ETC); _localctx.value = RaceType.ETC; } break; case SUMMON: { setState(441); match(SUMMON); _localctx.value = RaceType.SUMMON; } break; case PET: { setState(443); match(PET); _localctx.value = RaceType.PET; } break; case HOLYTHING: { setState(445); match(HOLYTHING); _localctx.value = RaceType.HOLYTHING; } break; case DWARF: { setState(447); match(DWARF); _localctx.value = RaceType.DWARF; } break; case MERCHANT: { setState(449); match(MERCHANT); _localctx.value = RaceType.MERCHANT; } break; case ELF: { setState(451); match(ELF); _localctx.value = RaceType.ELF; } break; case KAMAEL: { setState(453); match(KAMAEL); _localctx.value = RaceType.KAMAEL; } break; case ORC: { setState(455); match(ORC); _localctx.value = RaceType.ORC; } break; case MERCENARY: { setState(457); match(MERCENARY); _localctx.value = RaceType.MERCENARY; } break; case CASTLE_GUARD: { setState(459); match(CASTLE_GUARD); _localctx.value = RaceType.CASTLE_GUARD; } break; case HUMAN: { setState(461); match(HUMAN); _localctx.value = RaceType.HUMAN; } break; case BOSS: { setState(463); match(BOSS); _localctx.value = RaceType.BOSS; } break; case ZZOLDAGU: { setState(465); match(ZZOLDAGU); _localctx.value = RaceType.ZZOLDAGU; } break; case WORLD_TRAP: { setState(467); match(WORLD_TRAP); _localctx.value = RaceType.WORLD_TRAP; } break; case MONRACE: { setState(469); match(MONRACE); _localctx.value = RaceType.MONRACE; } break; case GUARD: { setState(471); match(GUARD); _localctx.value = RaceType.GUARD; } break; case TELEPORTER: { setState(473); match(TELEPORTER); _localctx.value = RaceType.TELEPORTER; } break; case WAREHOUSE_KEEPER: { setState(475); match(WAREHOUSE_KEEPER); _localctx.value = RaceType.WAREHOUSE_KEEPER; } break; case DARKELF: { setState(477); match(DARKELF); _localctx.value = RaceType.DARKELF; } break; case SIEGE_WEAPON: { setState(479); match(SIEGE_WEAPON); _localctx.value = RaceType.SIEGE_WEAPON; } break; case FRIEND: { setState(481); match(FRIEND); _localctx.value = RaceType.FRIEND; } break; default: throw new NoViableAltException(this); } } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class SexContext extends ParserRuleContext { public Sex value; public TerminalNode MALE() { return getToken(NpcDatasParser.MALE, 0); } public TerminalNode FEMALE() { return getToken(NpcDatasParser.FEMALE, 0); } public TerminalNode ETC() { return getToken(NpcDatasParser.ETC, 0); } public SexContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_sex; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterSex(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitSex(this); } } public final SexContext sex() throws RecognitionException { SexContext _localctx = new SexContext(_ctx, getState()); enterRule(_localctx, 24, RULE_sex); try { enterOuterAlt(_localctx, 1); { setState(485); match(T__12); setState(486); match(T__3); setState(493); _errHandler.sync(this); switch (_input.LA(1)) { case MALE: { setState(487); match(MALE); _localctx.value = Sex.MALE; } break; case FEMALE: { setState(489); match(FEMALE); _localctx.value = Sex.FEMALE; } break; case ETC: { setState(491); match(ETC); _localctx.value = Sex.ETC; } break; default: throw new NoViableAltException(this); } } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Skill_listContext extends ParserRuleContext { public Category_listContext category_list() { return getRuleContext(Category_listContext.class,0); } public Skill_listContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_skill_list; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterSkill_list(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitSkill_list(this); } } public final Skill_listContext skill_list() throws RecognitionException { Skill_listContext _localctx = new Skill_listContext(_ctx, getState()); enterRule(_localctx, 26, RULE_skill_list); try { enterOuterAlt(_localctx, 1); { setState(495); match(T__13); setState(496); match(T__3); setState(497); category_list(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Slot_chestContext extends ParserRuleContext { public Empty_name_objectContext empty_name_object() { return getRuleContext(Empty_name_objectContext.class,0); } public Name_objectContext name_object() { return getRuleContext(Name_objectContext.class,0); } public Slot_chestContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_slot_chest; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterSlot_chest(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitSlot_chest(this); } } public final Slot_chestContext slot_chest() throws RecognitionException { Slot_chestContext _localctx = new Slot_chestContext(_ctx, getState()); enterRule(_localctx, 28, RULE_slot_chest); try { enterOuterAlt(_localctx, 1); { setState(499); match(T__14); setState(500); match(T__3); setState(503); _errHandler.sync(this); switch ( getInterpreter().adaptivePredict(_input,5,_ctx) ) { case 1: { setState(501); empty_name_object(); } break; case 2: { setState(502); name_object(); } break; } } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Slot_rhandContext extends ParserRuleContext { public Empty_name_objectContext empty_name_object() { return getRuleContext(Empty_name_objectContext.class,0); } public Name_objectContext name_object() { return getRuleContext(Name_objectContext.class,0); } public Slot_rhandContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_slot_rhand; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterSlot_rhand(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitSlot_rhand(this); } } public final Slot_rhandContext slot_rhand() throws RecognitionException { Slot_rhandContext _localctx = new Slot_rhandContext(_ctx, getState()); enterRule(_localctx, 30, RULE_slot_rhand); try { enterOuterAlt(_localctx, 1); { setState(505); match(T__15); setState(506); match(T__3); setState(509); _errHandler.sync(this); switch ( getInterpreter().adaptivePredict(_input,6,_ctx) ) { case 1: { setState(507); empty_name_object(); } break; case 2: { setState(508); name_object(); } break; } } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Slot_lhandContext extends ParserRuleContext { public Empty_name_objectContext empty_name_object() { return getRuleContext(Empty_name_objectContext.class,0); } public Name_objectContext name_object() { return getRuleContext(Name_objectContext.class,0); } public Slot_lhandContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_slot_lhand; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterSlot_lhand(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitSlot_lhand(this); } } public final Slot_lhandContext slot_lhand() throws RecognitionException { Slot_lhandContext _localctx = new Slot_lhandContext(_ctx, getState()); enterRule(_localctx, 32, RULE_slot_lhand); try { enterOuterAlt(_localctx, 1); { setState(511); match(T__16); setState(512); match(T__3); setState(515); _errHandler.sync(this); switch ( getInterpreter().adaptivePredict(_input,7,_ctx) ) { case 1: { setState(513); empty_name_object(); } break; case 2: { setState(514); name_object(); } break; } } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Empty_name_objectContext extends ParserRuleContext { public Empty_name_objectContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_empty_name_object; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterEmpty_name_object(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitEmpty_name_object(this); } } public final Empty_name_objectContext empty_name_object() throws RecognitionException { Empty_name_objectContext _localctx = new Empty_name_objectContext(_ctx, getState()); enterRule(_localctx, 34, RULE_empty_name_object); try { enterOuterAlt(_localctx, 1); { setState(517); match(T__17); setState(518); match(T__18); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Collision_radiusContext extends ParserRuleContext { public Double_listContext double_list() { return getRuleContext(Double_listContext.class,0); } public Collision_radiusContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_collision_radius; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterCollision_radius(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitCollision_radius(this); } } public final Collision_radiusContext collision_radius() throws RecognitionException { Collision_radiusContext _localctx = new Collision_radiusContext(_ctx, getState()); enterRule(_localctx, 36, RULE_collision_radius); try { enterOuterAlt(_localctx, 1); { setState(520); match(T__19); setState(521); match(T__3); setState(522); double_list(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Collision_heightContext extends ParserRuleContext { public Double_listContext double_list() { return getRuleContext(Double_listContext.class,0); } public Collision_heightContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_collision_height; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterCollision_height(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitCollision_height(this); } } public final Collision_heightContext collision_height() throws RecognitionException { Collision_heightContext _localctx = new Collision_heightContext(_ctx, getState()); enterRule(_localctx, 38, RULE_collision_height); try { enterOuterAlt(_localctx, 1); { setState(524); match(T__20); setState(525); match(T__3); setState(526); double_list(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Hit_time_factorContext extends ParserRuleContext { public Double_objectContext double_object() { return getRuleContext(Double_objectContext.class,0); } public Hit_time_factorContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_hit_time_factor; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterHit_time_factor(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitHit_time_factor(this); } } public final Hit_time_factorContext hit_time_factor() throws RecognitionException { Hit_time_factorContext _localctx = new Hit_time_factorContext(_ctx, getState()); enterRule(_localctx, 40, RULE_hit_time_factor); try { enterOuterAlt(_localctx, 1); { setState(528); match(T__21); setState(529); match(T__3); setState(530); double_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Hit_time_factor_skillContext extends ParserRuleContext { public Int_objectContext int_object() { return getRuleContext(Int_objectContext.class,0); } public Hit_time_factor_skillContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_hit_time_factor_skill; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterHit_time_factor_skill(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitHit_time_factor_skill(this); } } public final Hit_time_factor_skillContext hit_time_factor_skill() throws RecognitionException { Hit_time_factor_skillContext _localctx = new Hit_time_factor_skillContext(_ctx, getState()); enterRule(_localctx, 42, RULE_hit_time_factor_skill); try { enterOuterAlt(_localctx, 1); { setState(532); match(T__22); setState(533); match(T__3); setState(534); int_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Ground_highContext extends ParserRuleContext { public Double_listContext double_list() { return getRuleContext(Double_listContext.class,0); } public Ground_highContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_ground_high; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterGround_high(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitGround_high(this); } } public final Ground_highContext ground_high() throws RecognitionException { Ground_highContext _localctx = new Ground_highContext(_ctx, getState()); enterRule(_localctx, 44, RULE_ground_high); try { enterOuterAlt(_localctx, 1); { setState(536); match(T__23); setState(537); match(T__3); setState(538); double_list(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Ground_lowContext extends ParserRuleContext { public Double_listContext double_list() { return getRuleContext(Double_listContext.class,0); } public Ground_lowContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_ground_low; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterGround_low(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitGround_low(this); } } public final Ground_lowContext ground_low() throws RecognitionException { Ground_lowContext _localctx = new Ground_lowContext(_ctx, getState()); enterRule(_localctx, 46, RULE_ground_low); try { enterOuterAlt(_localctx, 1); { setState(540); match(T__24); setState(541); match(T__3); setState(542); double_list(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class StrContext extends ParserRuleContext { public Int_objectContext int_object() { return getRuleContext(Int_objectContext.class,0); } public StrContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_str; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterStr(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitStr(this); } } public final StrContext str() throws RecognitionException { StrContext _localctx = new StrContext(_ctx, getState()); enterRule(_localctx, 48, RULE_str); try { enterOuterAlt(_localctx, 1); { setState(544); match(T__25); setState(545); match(T__3); setState(546); int_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Int_Context extends ParserRuleContext { public Int_objectContext int_object() { return getRuleContext(Int_objectContext.class,0); } public Int_Context(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_int_; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterInt_(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitInt_(this); } } public final Int_Context int_() throws RecognitionException { Int_Context _localctx = new Int_Context(_ctx, getState()); enterRule(_localctx, 50, RULE_int_); try { enterOuterAlt(_localctx, 1); { setState(548); match(T__26); setState(549); match(T__3); setState(550); int_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class DexContext extends ParserRuleContext { public Int_objectContext int_object() { return getRuleContext(Int_objectContext.class,0); } public DexContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_dex; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterDex(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitDex(this); } } public final DexContext dex() throws RecognitionException { DexContext _localctx = new DexContext(_ctx, getState()); enterRule(_localctx, 52, RULE_dex); try { enterOuterAlt(_localctx, 1); { setState(552); match(T__27); setState(553); match(T__3); setState(554); int_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class WitContext extends ParserRuleContext { public Int_objectContext int_object() { return getRuleContext(Int_objectContext.class,0); } public WitContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_wit; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterWit(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitWit(this); } } public final WitContext wit() throws RecognitionException { WitContext _localctx = new WitContext(_ctx, getState()); enterRule(_localctx, 54, RULE_wit); try { enterOuterAlt(_localctx, 1); { setState(556); match(T__28); setState(557); match(T__3); setState(558); int_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class ConContext extends ParserRuleContext { public Int_objectContext int_object() { return getRuleContext(Int_objectContext.class,0); } public ConContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_con; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterCon(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitCon(this); } } public final ConContext con() throws RecognitionException { ConContext _localctx = new ConContext(_ctx, getState()); enterRule(_localctx, 56, RULE_con); try { enterOuterAlt(_localctx, 1); { setState(560); match(T__29); setState(561); match(T__3); setState(562); int_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class MenContext extends ParserRuleContext { public Int_objectContext int_object() { return getRuleContext(Int_objectContext.class,0); } public MenContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_men; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterMen(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitMen(this); } } public final MenContext men() throws RecognitionException { MenContext _localctx = new MenContext(_ctx, getState()); enterRule(_localctx, 58, RULE_men); try { enterOuterAlt(_localctx, 1); { setState(564); match(T__30); setState(565); match(T__3); setState(566); int_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Org_hpContext extends ParserRuleContext { public Double_objectContext double_object() { return getRuleContext(Double_objectContext.class,0); } public Org_hpContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_org_hp; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterOrg_hp(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitOrg_hp(this); } } public final Org_hpContext org_hp() throws RecognitionException { Org_hpContext _localctx = new Org_hpContext(_ctx, getState()); enterRule(_localctx, 60, RULE_org_hp); try { enterOuterAlt(_localctx, 1); { setState(568); match(T__31); setState(569); match(T__3); setState(570); double_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Org_hp_regenContext extends ParserRuleContext { public Double_objectContext double_object() { return getRuleContext(Double_objectContext.class,0); } public Org_hp_regenContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_org_hp_regen; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterOrg_hp_regen(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitOrg_hp_regen(this); } } public final Org_hp_regenContext org_hp_regen() throws RecognitionException { Org_hp_regenContext _localctx = new Org_hp_regenContext(_ctx, getState()); enterRule(_localctx, 62, RULE_org_hp_regen); try { enterOuterAlt(_localctx, 1); { setState(572); match(T__32); setState(573); match(T__3); setState(574); double_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Org_mpContext extends ParserRuleContext { public Double_objectContext double_object() { return getRuleContext(Double_objectContext.class,0); } public Org_mpContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_org_mp; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterOrg_mp(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitOrg_mp(this); } } public final Org_mpContext org_mp() throws RecognitionException { Org_mpContext _localctx = new Org_mpContext(_ctx, getState()); enterRule(_localctx, 64, RULE_org_mp); try { enterOuterAlt(_localctx, 1); { setState(576); match(T__33); setState(577); match(T__3); setState(578); double_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Org_mp_regenContext extends ParserRuleContext { public Double_objectContext double_object() { return getRuleContext(Double_objectContext.class,0); } public Org_mp_regenContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_org_mp_regen; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterOrg_mp_regen(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitOrg_mp_regen(this); } } public final Org_mp_regenContext org_mp_regen() throws RecognitionException { Org_mp_regenContext _localctx = new Org_mp_regenContext(_ctx, getState()); enterRule(_localctx, 66, RULE_org_mp_regen); try { enterOuterAlt(_localctx, 1); { setState(580); match(T__34); setState(581); match(T__3); setState(582); double_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Base_attack_typeContext extends ParserRuleContext { public WeaponType value; public TerminalNode SWORD() { return getToken(NpcDatasParser.SWORD, 0); } public TerminalNode BLUNT() { return getToken(NpcDatasParser.BLUNT, 0); } public TerminalNode BOW() { return getToken(NpcDatasParser.BOW, 0); } public TerminalNode DAGGER() { return getToken(NpcDatasParser.DAGGER, 0); } public TerminalNode FIST() { return getToken(NpcDatasParser.FIST, 0); } public TerminalNode POLE() { return getToken(NpcDatasParser.POLE, 0); } public TerminalNode DUAL() { return getToken(NpcDatasParser.DUAL, 0); } public TerminalNode DUALFIST() { return getToken(NpcDatasParser.DUALFIST, 0); } public Base_attack_typeContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_base_attack_type; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterBase_attack_type(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitBase_attack_type(this); } } public final Base_attack_typeContext base_attack_type() throws RecognitionException { Base_attack_typeContext _localctx = new Base_attack_typeContext(_ctx, getState()); enterRule(_localctx, 68, RULE_base_attack_type); try { enterOuterAlt(_localctx, 1); { setState(584); match(T__35); setState(585); match(T__3); setState(602); _errHandler.sync(this); switch (_input.LA(1)) { case SWORD: { setState(586); match(SWORD); _localctx.value = WeaponType.SWORD; } break; case BLUNT: { setState(588); match(BLUNT); _localctx.value = WeaponType.BLUNT; } break; case BOW: { setState(590); match(BOW); _localctx.value = WeaponType.BOW; } break; case DAGGER: { setState(592); match(DAGGER); _localctx.value = WeaponType.DAGGER; } break; case FIST: { setState(594); match(FIST); _localctx.value = WeaponType.FIST; } break; case POLE: { setState(596); match(POLE); _localctx.value = WeaponType.POLE; } break; case DUAL: { setState(598); match(DUAL); _localctx.value = WeaponType.DUAL; } break; case DUALFIST: { setState(600); match(DUALFIST); _localctx.value = WeaponType.DUALFIST; } break; default: throw new NoViableAltException(this); } } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Base_attack_rangeContext extends ParserRuleContext { public Int_objectContext io; public Int_objectContext int_object() { return getRuleContext(Int_objectContext.class,0); } public Base_attack_rangeContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_base_attack_range; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterBase_attack_range(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitBase_attack_range(this); } } public final Base_attack_rangeContext base_attack_range() throws RecognitionException { Base_attack_rangeContext _localctx = new Base_attack_rangeContext(_ctx, getState()); enterRule(_localctx, 70, RULE_base_attack_range); try { enterOuterAlt(_localctx, 1); { setState(604); match(T__36); setState(605); match(T__3); setState(606); ((Base_attack_rangeContext)_localctx).io = int_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Base_damage_rangeContext extends ParserRuleContext { public Int_listContext il; public Int_listContext int_list() { return getRuleContext(Int_listContext.class,0); } public Base_damage_rangeContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_base_damage_range; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterBase_damage_range(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitBase_damage_range(this); } } public final Base_damage_rangeContext base_damage_range() throws RecognitionException { Base_damage_rangeContext _localctx = new Base_damage_rangeContext(_ctx, getState()); enterRule(_localctx, 72, RULE_base_damage_range); try { enterOuterAlt(_localctx, 1); { setState(608); match(T__37); setState(609); match(T__3); setState(610); ((Base_damage_rangeContext)_localctx).il = int_list(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Base_rand_damContext extends ParserRuleContext { public Int_objectContext io; public Int_objectContext int_object() { return getRuleContext(Int_objectContext.class,0); } public Base_rand_damContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_base_rand_dam; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterBase_rand_dam(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitBase_rand_dam(this); } } public final Base_rand_damContext base_rand_dam() throws RecognitionException { Base_rand_damContext _localctx = new Base_rand_damContext(_ctx, getState()); enterRule(_localctx, 74, RULE_base_rand_dam); try { enterOuterAlt(_localctx, 1); { setState(612); match(T__38); setState(613); match(T__3); setState(614); ((Base_rand_damContext)_localctx).io = int_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Base_physical_attackContext extends ParserRuleContext { public Double_objectContext d; public Double_objectContext double_object() { return getRuleContext(Double_objectContext.class,0); } public Base_physical_attackContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_base_physical_attack; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterBase_physical_attack(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitBase_physical_attack(this); } } public final Base_physical_attackContext base_physical_attack() throws RecognitionException { Base_physical_attackContext _localctx = new Base_physical_attackContext(_ctx, getState()); enterRule(_localctx, 76, RULE_base_physical_attack); try { enterOuterAlt(_localctx, 1); { setState(616); match(T__39); setState(617); match(T__3); setState(618); ((Base_physical_attackContext)_localctx).d = double_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Base_criticalContext extends ParserRuleContext { public Double_objectContext d; public Double_objectContext double_object() { return getRuleContext(Double_objectContext.class,0); } public Base_criticalContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_base_critical; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterBase_critical(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitBase_critical(this); } } public final Base_criticalContext base_critical() throws RecognitionException { Base_criticalContext _localctx = new Base_criticalContext(_ctx, getState()); enterRule(_localctx, 78, RULE_base_critical); try { enterOuterAlt(_localctx, 1); { setState(620); match(T__40); setState(621); match(T__3); setState(622); ((Base_criticalContext)_localctx).d = double_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Physical_hit_modifyContext extends ParserRuleContext { public Double_objectContext d; public Double_objectContext double_object() { return getRuleContext(Double_objectContext.class,0); } public Physical_hit_modifyContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_physical_hit_modify; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterPhysical_hit_modify(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitPhysical_hit_modify(this); } } public final Physical_hit_modifyContext physical_hit_modify() throws RecognitionException { Physical_hit_modifyContext _localctx = new Physical_hit_modifyContext(_ctx, getState()); enterRule(_localctx, 80, RULE_physical_hit_modify); try { enterOuterAlt(_localctx, 1); { setState(624); match(T__41); setState(625); match(T__3); setState(626); ((Physical_hit_modifyContext)_localctx).d = double_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Base_attack_speedContext extends ParserRuleContext { public Double_objectContext doBas; public Double_objectContext double_object() { return getRuleContext(Double_objectContext.class,0); } public Base_attack_speedContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_base_attack_speed; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterBase_attack_speed(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitBase_attack_speed(this); } } public final Base_attack_speedContext base_attack_speed() throws RecognitionException { Base_attack_speedContext _localctx = new Base_attack_speedContext(_ctx, getState()); enterRule(_localctx, 82, RULE_base_attack_speed); try { enterOuterAlt(_localctx, 1); { setState(628); match(T__42); setState(629); match(T__3); setState(630); ((Base_attack_speedContext)_localctx).doBas = double_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Base_reuse_delayContext extends ParserRuleContext { public Int_objectContext io; public Int_objectContext int_object() { return getRuleContext(Int_objectContext.class,0); } public Base_reuse_delayContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_base_reuse_delay; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterBase_reuse_delay(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitBase_reuse_delay(this); } } public final Base_reuse_delayContext base_reuse_delay() throws RecognitionException { Base_reuse_delayContext _localctx = new Base_reuse_delayContext(_ctx, getState()); enterRule(_localctx, 84, RULE_base_reuse_delay); try { enterOuterAlt(_localctx, 1); { setState(632); match(T__43); setState(633); match(T__3); setState(634); ((Base_reuse_delayContext)_localctx).io = int_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Base_magic_attackContext extends ParserRuleContext { public Double_objectContext d; public Double_objectContext double_object() { return getRuleContext(Double_objectContext.class,0); } public Base_magic_attackContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_base_magic_attack; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterBase_magic_attack(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitBase_magic_attack(this); } } public final Base_magic_attackContext base_magic_attack() throws RecognitionException { Base_magic_attackContext _localctx = new Base_magic_attackContext(_ctx, getState()); enterRule(_localctx, 86, RULE_base_magic_attack); try { enterOuterAlt(_localctx, 1); { setState(636); match(T__44); setState(637); match(T__3); setState(638); ((Base_magic_attackContext)_localctx).d = double_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Base_defendContext extends ParserRuleContext { public Double_objectContext d; public Double_objectContext double_object() { return getRuleContext(Double_objectContext.class,0); } public Base_defendContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_base_defend; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterBase_defend(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitBase_defend(this); } } public final Base_defendContext base_defend() throws RecognitionException { Base_defendContext _localctx = new Base_defendContext(_ctx, getState()); enterRule(_localctx, 88, RULE_base_defend); try { enterOuterAlt(_localctx, 1); { setState(640); match(T__45); setState(641); match(T__3); setState(642); ((Base_defendContext)_localctx).d = double_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Base_magic_defendContext extends ParserRuleContext { public Double_objectContext d; public Double_objectContext double_object() { return getRuleContext(Double_objectContext.class,0); } public Base_magic_defendContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_base_magic_defend; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterBase_magic_defend(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitBase_magic_defend(this); } } public final Base_magic_defendContext base_magic_defend() throws RecognitionException { Base_magic_defendContext _localctx = new Base_magic_defendContext(_ctx, getState()); enterRule(_localctx, 90, RULE_base_magic_defend); try { enterOuterAlt(_localctx, 1); { setState(644); match(T__46); setState(645); match(T__3); setState(646); ((Base_magic_defendContext)_localctx).d = double_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Base_attribute_defendContext extends ParserRuleContext { public List<Double> value; public Double_listContext il; public Double_listContext double_list() { return getRuleContext(Double_listContext.class,0); } public Base_attribute_defendContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_base_attribute_defend; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterBase_attribute_defend(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitBase_attribute_defend(this); } } public final Base_attribute_defendContext base_attribute_defend() throws RecognitionException { Base_attribute_defendContext _localctx = new Base_attribute_defendContext(_ctx, getState()); enterRule(_localctx, 92, RULE_base_attribute_defend); try { enterOuterAlt(_localctx, 1); { setState(648); match(T__47); setState(649); match(T__3); setState(650); ((Base_attribute_defendContext)_localctx).il = double_list(); _localctx.value = ((Base_attribute_defendContext)_localctx).il.value; } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Physical_avoid_modifyContext extends ParserRuleContext { public Int_objectContext io; public Int_objectContext int_object() { return getRuleContext(Int_objectContext.class,0); } public Physical_avoid_modifyContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_physical_avoid_modify; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterPhysical_avoid_modify(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitPhysical_avoid_modify(this); } } public final Physical_avoid_modifyContext physical_avoid_modify() throws RecognitionException { Physical_avoid_modifyContext _localctx = new Physical_avoid_modifyContext(_ctx, getState()); enterRule(_localctx, 94, RULE_physical_avoid_modify); try { enterOuterAlt(_localctx, 1); { setState(653); match(T__48); setState(654); match(T__3); setState(655); ((Physical_avoid_modifyContext)_localctx).io = int_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Shield_defense_rateContext extends ParserRuleContext { public Int_objectContext io; public Int_objectContext int_object() { return getRuleContext(Int_objectContext.class,0); } public Shield_defense_rateContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_shield_defense_rate; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterShield_defense_rate(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitShield_defense_rate(this); } } public final Shield_defense_rateContext shield_defense_rate() throws RecognitionException { Shield_defense_rateContext _localctx = new Shield_defense_rateContext(_ctx, getState()); enterRule(_localctx, 96, RULE_shield_defense_rate); try { enterOuterAlt(_localctx, 1); { setState(657); match(T__49); setState(658); match(T__3); setState(659); ((Shield_defense_rateContext)_localctx).io = int_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Shield_defenseContext extends ParserRuleContext { public Double_objectContext d; public Double_objectContext double_object() { return getRuleContext(Double_objectContext.class,0); } public Shield_defenseContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_shield_defense; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterShield_defense(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitShield_defense(this); } } public final Shield_defenseContext shield_defense() throws RecognitionException { Shield_defenseContext _localctx = new Shield_defenseContext(_ctx, getState()); enterRule(_localctx, 98, RULE_shield_defense); try { enterOuterAlt(_localctx, 1); { setState(661); match(T__50); setState(662); match(T__3); setState(663); ((Shield_defenseContext)_localctx).d = double_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Safe_heightContext extends ParserRuleContext { public Int_objectContext io; public Int_objectContext int_object() { return getRuleContext(Int_objectContext.class,0); } public Safe_heightContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_safe_height; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterSafe_height(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitSafe_height(this); } } public final Safe_heightContext safe_height() throws RecognitionException { Safe_heightContext _localctx = new Safe_heightContext(_ctx, getState()); enterRule(_localctx, 100, RULE_safe_height); try { enterOuterAlt(_localctx, 1); { setState(665); match(T__51); setState(666); match(T__3); setState(667); ((Safe_heightContext)_localctx).io = int_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Soulshot_countContext extends ParserRuleContext { public Int_objectContext io; public Int_objectContext int_object() { return getRuleContext(Int_objectContext.class,0); } public Soulshot_countContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_soulshot_count; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterSoulshot_count(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitSoulshot_count(this); } } public final Soulshot_countContext soulshot_count() throws RecognitionException { Soulshot_countContext _localctx = new Soulshot_countContext(_ctx, getState()); enterRule(_localctx, 102, RULE_soulshot_count); try { enterOuterAlt(_localctx, 1); { setState(669); match(T__52); setState(670); match(T__3); setState(671); ((Soulshot_countContext)_localctx).io = int_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Spiritshot_countContext extends ParserRuleContext { public Int_objectContext io; public Int_objectContext int_object() { return getRuleContext(Int_objectContext.class,0); } public Spiritshot_countContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_spiritshot_count; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterSpiritshot_count(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitSpiritshot_count(this); } } public final Spiritshot_countContext spiritshot_count() throws RecognitionException { Spiritshot_countContext _localctx = new Spiritshot_countContext(_ctx, getState()); enterRule(_localctx, 104, RULE_spiritshot_count); try { enterOuterAlt(_localctx, 1); { setState(673); match(T__53); setState(674); match(T__3); setState(675); ((Spiritshot_countContext)_localctx).io = int_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class ClanContext extends ParserRuleContext { public Int_objectContext int_object() { return getRuleContext(Int_objectContext.class,0); } public Category_listContext category_list() { return getRuleContext(Category_listContext.class,0); } public ClanContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_clan; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterClan(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitClan(this); } } public final ClanContext clan() throws RecognitionException { ClanContext _localctx = new ClanContext(_ctx, getState()); enterRule(_localctx, 106, RULE_clan); try { enterOuterAlt(_localctx, 1); { setState(677); match(T__54); setState(678); match(T__3); setState(684); _errHandler.sync(this); switch ( getInterpreter().adaptivePredict(_input,9,_ctx) ) { case 1: { setState(679); match(T__4); setState(680); int_object(); setState(681); match(T__5); } break; case 2: { setState(683); category_list(); } break; } } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Ignore_clan_listContext extends ParserRuleContext { public Category_listContext category_list() { return getRuleContext(Category_listContext.class,0); } public Ignore_clan_listContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_ignore_clan_list; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterIgnore_clan_list(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitIgnore_clan_list(this); } } public final Ignore_clan_listContext ignore_clan_list() throws RecognitionException { Ignore_clan_listContext _localctx = new Ignore_clan_listContext(_ctx, getState()); enterRule(_localctx, 108, RULE_ignore_clan_list); try { enterOuterAlt(_localctx, 1); { setState(686); match(T__55); setState(687); match(T__3); setState(688); category_list(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Clan_help_rangeContext extends ParserRuleContext { public Int_objectContext io; public Int_objectContext int_object() { return getRuleContext(Int_objectContext.class,0); } public Clan_help_rangeContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_clan_help_range; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterClan_help_range(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitClan_help_range(this); } } public final Clan_help_rangeContext clan_help_range() throws RecognitionException { Clan_help_rangeContext _localctx = new Clan_help_rangeContext(_ctx, getState()); enterRule(_localctx, 110, RULE_clan_help_range); try { enterOuterAlt(_localctx, 1); { setState(690); match(T__56); setState(691); match(T__3); setState(692); ((Clan_help_rangeContext)_localctx).io = int_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class UndyingContext extends ParserRuleContext { public Bool_objectContext bo; public Bool_objectContext bool_object() { return getRuleContext(Bool_objectContext.class,0); } public UndyingContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_undying; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterUndying(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitUndying(this); } } public final UndyingContext undying() throws RecognitionException { UndyingContext _localctx = new UndyingContext(_ctx, getState()); enterRule(_localctx, 112, RULE_undying); try { enterOuterAlt(_localctx, 1); { setState(694); match(T__57); setState(695); match(T__3); setState(696); ((UndyingContext)_localctx).bo = bool_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Can_be_attackedContext extends ParserRuleContext { public Bool_objectContext bo; public Bool_objectContext bool_object() { return getRuleContext(Bool_objectContext.class,0); } public Can_be_attackedContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_can_be_attacked; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterCan_be_attacked(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitCan_be_attacked(this); } } public final Can_be_attackedContext can_be_attacked() throws RecognitionException { Can_be_attackedContext _localctx = new Can_be_attackedContext(_ctx, getState()); enterRule(_localctx, 114, RULE_can_be_attacked); try { enterOuterAlt(_localctx, 1); { setState(698); match(T__58); setState(699); match(T__3); setState(700); ((Can_be_attackedContext)_localctx).bo = bool_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Corpse_timeContext extends ParserRuleContext { public Int_objectContext io; public Int_objectContext int_object() { return getRuleContext(Int_objectContext.class,0); } public Corpse_timeContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_corpse_time; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterCorpse_time(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitCorpse_time(this); } } public final Corpse_timeContext corpse_time() throws RecognitionException { Corpse_timeContext _localctx = new Corpse_timeContext(_ctx, getState()); enterRule(_localctx, 116, RULE_corpse_time); try { enterOuterAlt(_localctx, 1); { setState(702); match(T__59); setState(703); match(T__3); setState(704); ((Corpse_timeContext)_localctx).io = int_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class No_sleep_modeContext extends ParserRuleContext { public Bool_objectContext bo; public Bool_objectContext bool_object() { return getRuleContext(Bool_objectContext.class,0); } public No_sleep_modeContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_no_sleep_mode; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterNo_sleep_mode(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitNo_sleep_mode(this); } } public final No_sleep_modeContext no_sleep_mode() throws RecognitionException { No_sleep_modeContext _localctx = new No_sleep_modeContext(_ctx, getState()); enterRule(_localctx, 118, RULE_no_sleep_mode); try { enterOuterAlt(_localctx, 1); { setState(706); match(T__60); setState(707); match(T__3); setState(708); ((No_sleep_modeContext)_localctx).bo = bool_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Agro_rangeContext extends ParserRuleContext { public Int_objectContext io; public Int_objectContext int_object() { return getRuleContext(Int_objectContext.class,0); } public Agro_rangeContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_agro_range; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterAgro_range(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitAgro_range(this); } } public final Agro_rangeContext agro_range() throws RecognitionException { Agro_rangeContext _localctx = new Agro_rangeContext(_ctx, getState()); enterRule(_localctx, 120, RULE_agro_range); try { enterOuterAlt(_localctx, 1); { setState(710); match(T__61); setState(711); match(T__3); setState(712); ((Agro_rangeContext)_localctx).io = int_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Passable_doorContext extends ParserRuleContext { public Int_objectContext io; public Int_objectContext int_object() { return getRuleContext(Int_objectContext.class,0); } public Passable_doorContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_passable_door; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterPassable_door(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitPassable_door(this); } } public final Passable_doorContext passable_door() throws RecognitionException { Passable_doorContext _localctx = new Passable_doorContext(_ctx, getState()); enterRule(_localctx, 122, RULE_passable_door); try { enterOuterAlt(_localctx, 1); { setState(714); match(T__62); setState(715); match(T__3); setState(716); ((Passable_doorContext)_localctx).io = int_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Can_moveContext extends ParserRuleContext { public Bool_objectContext bo; public Bool_objectContext bool_object() { return getRuleContext(Bool_objectContext.class,0); } public Can_moveContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_can_move; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterCan_move(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitCan_move(this); } } public final Can_moveContext can_move() throws RecognitionException { Can_moveContext _localctx = new Can_moveContext(_ctx, getState()); enterRule(_localctx, 124, RULE_can_move); try { enterOuterAlt(_localctx, 1); { setState(718); match(T__63); setState(719); match(T__3); setState(720); ((Can_moveContext)_localctx).bo = bool_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class FlyingContext extends ParserRuleContext { public Bool_objectContext bo; public Bool_objectContext bool_object() { return getRuleContext(Bool_objectContext.class,0); } public FlyingContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_flying; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterFlying(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitFlying(this); } } public final FlyingContext flying() throws RecognitionException { FlyingContext _localctx = new FlyingContext(_ctx, getState()); enterRule(_localctx, 126, RULE_flying); try { enterOuterAlt(_localctx, 1); { setState(722); match(T__64); setState(723); match(T__3); setState(724); ((FlyingContext)_localctx).bo = bool_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Has_summonerContext extends ParserRuleContext { public Bool_objectContext bo; public Bool_objectContext bool_object() { return getRuleContext(Bool_objectContext.class,0); } public Has_summonerContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_has_summoner; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterHas_summoner(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitHas_summoner(this); } } public final Has_summonerContext has_summoner() throws RecognitionException { Has_summonerContext _localctx = new Has_summonerContext(_ctx, getState()); enterRule(_localctx, 128, RULE_has_summoner); try { enterOuterAlt(_localctx, 1); { setState(726); match(T__65); setState(727); match(T__3); setState(728); ((Has_summonerContext)_localctx).bo = bool_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class TargetableContext extends ParserRuleContext { public Bool_objectContext bo; public Bool_objectContext bool_object() { return getRuleContext(Bool_objectContext.class,0); } public TargetableContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_targetable; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterTargetable(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitTargetable(this); } } public final TargetableContext targetable() throws RecognitionException { TargetableContext _localctx = new TargetableContext(_ctx, getState()); enterRule(_localctx, 130, RULE_targetable); try { enterOuterAlt(_localctx, 1); { setState(730); match(T__66); setState(731); match(T__3); setState(732); ((TargetableContext)_localctx).bo = bool_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Show_name_tagContext extends ParserRuleContext { public Bool_objectContext bo; public Bool_objectContext bool_object() { return getRuleContext(Bool_objectContext.class,0); } public Show_name_tagContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_show_name_tag; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterShow_name_tag(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitShow_name_tag(this); } } public final Show_name_tagContext show_name_tag() throws RecognitionException { Show_name_tagContext _localctx = new Show_name_tagContext(_ctx, getState()); enterRule(_localctx, 132, RULE_show_name_tag); try { enterOuterAlt(_localctx, 1); { setState(734); match(T__67); setState(735); match(T__3); setState(736); ((Show_name_tagContext)_localctx).bo = bool_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Abnormal_resistContext extends ParserRuleContext { public Int_listContext int_list() { return getRuleContext(Int_listContext.class,0); } public Abnormal_resistContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_abnormal_resist; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterAbnormal_resist(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitAbnormal_resist(this); } } public final Abnormal_resistContext abnormal_resist() throws RecognitionException { Abnormal_resistContext _localctx = new Abnormal_resistContext(_ctx, getState()); enterRule(_localctx, 134, RULE_abnormal_resist); try { enterOuterAlt(_localctx, 1); { setState(738); match(T__68); setState(739); match(T__3); setState(740); int_list(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Is_death_penaltyContext extends ParserRuleContext { public Bool_objectContext bo; public Bool_objectContext bool_object() { return getRuleContext(Bool_objectContext.class,0); } public Is_death_penaltyContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_is_death_penalty; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterIs_death_penalty(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitIs_death_penalty(this); } } public final Is_death_penaltyContext is_death_penalty() throws RecognitionException { Is_death_penaltyContext _localctx = new Is_death_penaltyContext(_ctx, getState()); enterRule(_localctx, 136, RULE_is_death_penalty); try { enterOuterAlt(_localctx, 1); { setState(742); match(T__69); setState(743); match(T__3); setState(744); ((Is_death_penaltyContext)_localctx).bo = bool_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Npc_aiContext extends ParserRuleContext { public Name_objectContext no; public Name_objectContext name_object() { return getRuleContext(Name_objectContext.class,0); } public List<Ai_paramContext> ai_param() { return getRuleContexts(Ai_paramContext.class); } public Ai_paramContext ai_param(int i) { return getRuleContext(Ai_paramContext.class,i); } public Npc_aiContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_npc_ai; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterNpc_ai(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitNpc_ai(this); } } public final Npc_aiContext npc_ai() throws RecognitionException { Npc_aiContext _localctx = new Npc_aiContext(_ctx, getState()); enterRule(_localctx, 138, RULE_npc_ai); int _la; try { enterOuterAlt(_localctx, 1); { setState(746); match(T__70); setState(747); match(T__3); setState(748); match(T__4); setState(749); ((Npc_aiContext)_localctx).no = name_object(); { setState(755); _errHandler.sync(this); _la = _input.LA(1); while (_la==SEMICOLON) { { setState(753); _errHandler.sync(this); switch ( getInterpreter().adaptivePredict(_input,10,_ctx) ) { case 1: { setState(750); match(SEMICOLON); } break; case 2: { setState(751); match(SEMICOLON); setState(752); ai_param(); } break; } } setState(757); _errHandler.sync(this); _la = _input.LA(1); } } setState(758); match(T__5); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Ai_paramContext extends ParserRuleContext { public Name_objectContext no1; public Param_valueContext param_value() { return getRuleContext(Param_valueContext.class,0); } public Name_objectContext name_object() { return getRuleContext(Name_objectContext.class,0); } public Ai_paramContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_ai_param; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterAi_param(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitAi_param(this); } } public final Ai_paramContext ai_param() throws RecognitionException { Ai_paramContext _localctx = new Ai_paramContext(_ctx, getState()); enterRule(_localctx, 140, RULE_ai_param); try { enterOuterAlt(_localctx, 1); { setState(760); match(T__4); setState(761); ((Ai_paramContext)_localctx).no1 = name_object(); setState(762); match(T__3); setState(763); param_value(); setState(764); match(T__5); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Param_valueContext extends ParserRuleContext { public Int_objectContext int_object() { return getRuleContext(Int_objectContext.class,0); } public Double_objectContext double_object() { return getRuleContext(Double_objectContext.class,0); } public Category_objectContext category_object() { return getRuleContext(Category_objectContext.class,0); } public Npc_privatesContext npc_privates() { return getRuleContext(Npc_privatesContext.class,0); } public Fstring_objectContext fstring_object() { return getRuleContext(Fstring_objectContext.class,0); } public Identifier_objectContext identifier_object() { return getRuleContext(Identifier_objectContext.class,0); } public Param_valueContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_param_value; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterParam_value(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitParam_value(this); } } public final Param_valueContext param_value() throws RecognitionException { Param_valueContext _localctx = new Param_valueContext(_ctx, getState()); enterRule(_localctx, 142, RULE_param_value); try { setState(772); _errHandler.sync(this); switch ( getInterpreter().adaptivePredict(_input,12,_ctx) ) { case 1: enterOuterAlt(_localctx, 1); { setState(766); int_object(); } break; case 2: enterOuterAlt(_localctx, 2); { setState(767); double_object(); } break; case 3: enterOuterAlt(_localctx, 3); { setState(768); category_object(); } break; case 4: enterOuterAlt(_localctx, 4); { setState(769); npc_privates(); } break; case 5: enterOuterAlt(_localctx, 5); { setState(770); fstring_object(); } break; case 6: enterOuterAlt(_localctx, 6); { setState(771); identifier_object(); } break; } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Npc_privatesContext extends ParserRuleContext { public List<Identifier_objectContext> identifier_object() { return getRuleContexts(Identifier_objectContext.class); } public Identifier_objectContext identifier_object(int i) { return getRuleContext(Identifier_objectContext.class,i); } public Npc_privatesContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_npc_privates; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterNpc_privates(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitNpc_privates(this); } } public final Npc_privatesContext npc_privates() throws RecognitionException { Npc_privatesContext _localctx = new Npc_privatesContext(_ctx, getState()); enterRule(_localctx, 144, RULE_npc_privates); int _la; try { enterOuterAlt(_localctx, 1); { setState(774); match(T__17); setState(775); identifier_object(); setState(780); _errHandler.sync(this); _la = _input.LA(1); while (_la==SEMICOLON) { { { setState(776); match(SEMICOLON); setState(777); identifier_object(); } } setState(782); _errHandler.sync(this); _la = _input.LA(1); } setState(783); match(T__18); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Fstring_objectContext extends ParserRuleContext { public Int_objectContext io; public Int_objectContext int_object() { return getRuleContext(Int_objectContext.class,0); } public Fstring_objectContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_fstring_object; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterFstring_object(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitFstring_object(this); } } public final Fstring_objectContext fstring_object() throws RecognitionException { Fstring_objectContext _localctx = new Fstring_objectContext(_ctx, getState()); enterRule(_localctx, 146, RULE_fstring_object); try { enterOuterAlt(_localctx, 1); { setState(785); match(T__17); setState(786); ((Fstring_objectContext)_localctx).io = int_object(); setState(787); match(T__18); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Event_flagContext extends ParserRuleContext { public Int_objectContext int_object() { return getRuleContext(Int_objectContext.class,0); } public Event_flagContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_event_flag; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterEvent_flag(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitEvent_flag(this); } } public final Event_flagContext event_flag() throws RecognitionException { Event_flagContext _localctx = new Event_flagContext(_ctx, getState()); enterRule(_localctx, 148, RULE_event_flag); try { enterOuterAlt(_localctx, 1); { setState(789); match(T__71); setState(790); match(T__3); setState(791); match(T__4); setState(792); int_object(); setState(793); match(T__5); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class UnsowingContext extends ParserRuleContext { public Bool_objectContext bo; public Bool_objectContext bool_object() { return getRuleContext(Bool_objectContext.class,0); } public UnsowingContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_unsowing; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterUnsowing(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitUnsowing(this); } } public final UnsowingContext unsowing() throws RecognitionException { UnsowingContext _localctx = new UnsowingContext(_ctx, getState()); enterRule(_localctx, 150, RULE_unsowing); try { enterOuterAlt(_localctx, 1); { setState(795); match(T__72); setState(796); match(T__3); setState(797); ((UnsowingContext)_localctx).bo = bool_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Private_respawn_logContext extends ParserRuleContext { public Bool_objectContext bo; public Bool_objectContext bool_object() { return getRuleContext(Bool_objectContext.class,0); } public Private_respawn_logContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_private_respawn_log; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterPrivate_respawn_log(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitPrivate_respawn_log(this); } } public final Private_respawn_logContext private_respawn_log() throws RecognitionException { Private_respawn_logContext _localctx = new Private_respawn_logContext(_ctx, getState()); enterRule(_localctx, 152, RULE_private_respawn_log); try { enterOuterAlt(_localctx, 1); { setState(799); match(T__73); setState(800); match(T__3); setState(801); ((Private_respawn_logContext)_localctx).bo = bool_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Acquire_exp_rateContext extends ParserRuleContext { public Double_objectContext d; public Double_objectContext double_object() { return getRuleContext(Double_objectContext.class,0); } public Acquire_exp_rateContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_acquire_exp_rate; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterAcquire_exp_rate(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitAcquire_exp_rate(this); } } public final Acquire_exp_rateContext acquire_exp_rate() throws RecognitionException { Acquire_exp_rateContext _localctx = new Acquire_exp_rateContext(_ctx, getState()); enterRule(_localctx, 154, RULE_acquire_exp_rate); try { enterOuterAlt(_localctx, 1); { setState(803); match(T__74); setState(804); match(T__3); setState(805); ((Acquire_exp_rateContext)_localctx).d = double_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Acquire_spContext extends ParserRuleContext { public Double_objectContext d; public Double_objectContext double_object() { return getRuleContext(Double_objectContext.class,0); } public Acquire_spContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_acquire_sp; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterAcquire_sp(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitAcquire_sp(this); } } public final Acquire_spContext acquire_sp() throws RecognitionException { Acquire_spContext _localctx = new Acquire_spContext(_ctx, getState()); enterRule(_localctx, 156, RULE_acquire_sp); try { enterOuterAlt(_localctx, 1); { setState(807); match(T__75); setState(808); match(T__3); setState(809); ((Acquire_spContext)_localctx).d = double_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Acquire_rpContext extends ParserRuleContext { public Double_objectContext d; public Double_objectContext double_object() { return getRuleContext(Double_objectContext.class,0); } public Acquire_rpContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_acquire_rp; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterAcquire_rp(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitAcquire_rp(this); } } public final Acquire_rpContext acquire_rp() throws RecognitionException { Acquire_rpContext _localctx = new Acquire_rpContext(_ctx, getState()); enterRule(_localctx, 158, RULE_acquire_rp); try { enterOuterAlt(_localctx, 1); { setState(811); match(T__76); setState(812); match(T__3); setState(813); ((Acquire_rpContext)_localctx).d = double_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Corpse_make_listContext extends ParserRuleContext { public Make_item_listContext make_item_list() { return getRuleContext(Make_item_listContext.class,0); } public Corpse_make_listContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_corpse_make_list; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterCorpse_make_list(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitCorpse_make_list(this); } } public final Corpse_make_listContext corpse_make_list() throws RecognitionException { Corpse_make_listContext _localctx = new Corpse_make_listContext(_ctx, getState()); enterRule(_localctx, 160, RULE_corpse_make_list); try { enterOuterAlt(_localctx, 1); { setState(815); match(T__77); setState(816); match(T__3); setState(817); make_item_list(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Make_item_listContext extends ParserRuleContext { public List<Make_itemContext> make_item() { return getRuleContexts(Make_itemContext.class); } public Make_itemContext make_item(int i) { return getRuleContext(Make_itemContext.class,i); } public Make_item_listContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_make_item_list; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterMake_item_list(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitMake_item_list(this); } } public final Make_item_listContext make_item_list() throws RecognitionException { Make_item_listContext _localctx = new Make_item_listContext(_ctx, getState()); enterRule(_localctx, 162, RULE_make_item_list); int _la; try { setState(832); _errHandler.sync(this); switch ( getInterpreter().adaptivePredict(_input,15,_ctx) ) { case 1: enterOuterAlt(_localctx, 1); { setState(819); match(T__4); setState(820); match(T__5); } break; case 2: enterOuterAlt(_localctx, 2); { setState(821); match(T__4); setState(822); make_item(); setState(827); _errHandler.sync(this); _la = _input.LA(1); while (_la==SEMICOLON) { { { setState(823); match(SEMICOLON); setState(824); make_item(); } } setState(829); _errHandler.sync(this); _la = _input.LA(1); } setState(830); match(T__5); } break; } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Make_itemContext extends ParserRuleContext { public Int_objectContext min; public Int_objectContext max; public Double_objectContext chance; public Name_objectContext name_object() { return getRuleContext(Name_objectContext.class,0); } public List<Int_objectContext> int_object() { return getRuleContexts(Int_objectContext.class); } public Int_objectContext int_object(int i) { return getRuleContext(Int_objectContext.class,i); } public Double_objectContext double_object() { return getRuleContext(Double_objectContext.class,0); } public Make_itemContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_make_item; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterMake_item(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitMake_item(this); } } public final Make_itemContext make_item() throws RecognitionException { Make_itemContext _localctx = new Make_itemContext(_ctx, getState()); enterRule(_localctx, 164, RULE_make_item); try { enterOuterAlt(_localctx, 1); { setState(834); match(T__4); setState(835); name_object(); setState(836); match(SEMICOLON); setState(837); ((Make_itemContext)_localctx).min = int_object(); setState(838); match(SEMICOLON); setState(839); ((Make_itemContext)_localctx).max = int_object(); setState(840); match(SEMICOLON); setState(841); ((Make_itemContext)_localctx).chance = double_object(); setState(842); match(T__5); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Additional_make_listContext extends ParserRuleContext { public Make_item_listContext make_item_list() { return getRuleContext(Make_item_listContext.class,0); } public Additional_make_listContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_additional_make_list; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterAdditional_make_list(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitAdditional_make_list(this); } } public final Additional_make_listContext additional_make_list() throws RecognitionException { Additional_make_listContext _localctx = new Additional_make_listContext(_ctx, getState()); enterRule(_localctx, 166, RULE_additional_make_list); try { enterOuterAlt(_localctx, 1); { setState(844); match(T__78); setState(845); match(T__3); setState(846); make_item_list(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Additional_make_multi_listContext extends ParserRuleContext { public Make_group_listContext make_group_list() { return getRuleContext(Make_group_listContext.class,0); } public Additional_make_multi_listContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_additional_make_multi_list; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterAdditional_make_multi_list(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitAdditional_make_multi_list(this); } } public final Additional_make_multi_listContext additional_make_multi_list() throws RecognitionException { Additional_make_multi_listContext _localctx = new Additional_make_multi_listContext(_ctx, getState()); enterRule(_localctx, 168, RULE_additional_make_multi_list); try { enterOuterAlt(_localctx, 1); { setState(848); match(T__79); setState(849); match(T__3); setState(850); make_group_list(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Make_group_listContext extends ParserRuleContext { public Double_objectContext gc; public List<Make_item_listContext> make_item_list() { return getRuleContexts(Make_item_listContext.class); } public Make_item_listContext make_item_list(int i) { return getRuleContext(Make_item_listContext.class,i); } public List<Double_objectContext> double_object() { return getRuleContexts(Double_objectContext.class); } public Double_objectContext double_object(int i) { return getRuleContext(Double_objectContext.class,i); } public Make_group_listContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_make_group_list; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterMake_group_list(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitMake_group_list(this); } } public final Make_group_listContext make_group_list() throws RecognitionException { Make_group_listContext _localctx = new Make_group_listContext(_ctx, getState()); enterRule(_localctx, 170, RULE_make_group_list); int _la; try { setState(874); _errHandler.sync(this); switch ( getInterpreter().adaptivePredict(_input,17,_ctx) ) { case 1: enterOuterAlt(_localctx, 1); { setState(852); match(T__4); setState(853); match(T__5); } break; case 2: enterOuterAlt(_localctx, 2); { setState(854); match(T__4); setState(855); match(T__4); setState(856); make_item_list(); setState(857); match(SEMICOLON); setState(858); ((Make_group_listContext)_localctx).gc = double_object(); setState(859); match(T__5); setState(869); _errHandler.sync(this); _la = _input.LA(1); while (_la==SEMICOLON) { { { setState(860); match(SEMICOLON); setState(861); match(T__4); setState(862); make_item_list(); setState(863); match(SEMICOLON); setState(864); ((Make_group_listContext)_localctx).gc = double_object(); setState(865); match(T__5); } } setState(871); _errHandler.sync(this); _la = _input.LA(1); } setState(872); match(T__5); } break; } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Ex_item_drop_listContext extends ParserRuleContext { public Make_group_listContext make_group_list() { return getRuleContext(Make_group_listContext.class,0); } public Ex_item_drop_listContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_ex_item_drop_list; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterEx_item_drop_list(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitEx_item_drop_list(this); } } public final Ex_item_drop_listContext ex_item_drop_list() throws RecognitionException { Ex_item_drop_listContext _localctx = new Ex_item_drop_listContext(_ctx, getState()); enterRule(_localctx, 172, RULE_ex_item_drop_list); try { enterOuterAlt(_localctx, 1); { setState(876); match(T__80); setState(877); match(T__3); setState(878); make_group_list(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Vitality_item_drop_listContext extends ParserRuleContext { public Make_group_listContext make_group_list() { return getRuleContext(Make_group_listContext.class,0); } public Vitality_item_drop_listContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_vitality_item_drop_list; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterVitality_item_drop_list(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitVitality_item_drop_list(this); } } public final Vitality_item_drop_listContext vitality_item_drop_list() throws RecognitionException { Vitality_item_drop_listContext _localctx = new Vitality_item_drop_listContext(_ctx, getState()); enterRule(_localctx, 174, RULE_vitality_item_drop_list); try { enterOuterAlt(_localctx, 1); { setState(880); match(T__81); setState(881); match(T__3); setState(882); make_group_list(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Mp_rewardContext extends ParserRuleContext { public Double_objectContext rewardValue; public Double_objectContext rewardAffectValue; public Mp_reward_typeContext mp_reward_type() { return getRuleContext(Mp_reward_typeContext.class,0); } public Mp_reward_affect_typeContext mp_reward_affect_type() { return getRuleContext(Mp_reward_affect_typeContext.class,0); } public List<Double_objectContext> double_object() { return getRuleContexts(Double_objectContext.class); } public Double_objectContext double_object(int i) { return getRuleContext(Double_objectContext.class,i); } public Mp_rewardContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_mp_reward; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterMp_reward(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitMp_reward(this); } } public final Mp_rewardContext mp_reward() throws RecognitionException { Mp_rewardContext _localctx = new Mp_rewardContext(_ctx, getState()); enterRule(_localctx, 176, RULE_mp_reward); try { enterOuterAlt(_localctx, 1); { setState(884); match(T__82); setState(885); match(T__3); setState(886); match(T__4); setState(887); ((Mp_rewardContext)_localctx).rewardValue = double_object(); setState(888); match(SEMICOLON); setState(889); mp_reward_type(); setState(890); match(SEMICOLON); setState(891); ((Mp_rewardContext)_localctx).rewardAffectValue = double_object(); setState(892); match(SEMICOLON); setState(893); mp_reward_affect_type(); setState(894); match(T__5); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Mp_reward_typeContext extends ParserRuleContext { public MpRewardType value; public Mp_reward_typeContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_mp_reward_type; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterMp_reward_type(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitMp_reward_type(this); } } public final Mp_reward_typeContext mp_reward_type() throws RecognitionException { Mp_reward_typeContext _localctx = new Mp_reward_typeContext(_ctx, getState()); enterRule(_localctx, 178, RULE_mp_reward_type); try { enterOuterAlt(_localctx, 1); { setState(900); _errHandler.sync(this); switch (_input.LA(1)) { case T__83: { setState(896); match(T__83); _localctx.value = MpRewardType.PER; } break; case T__84: { setState(898); match(T__84); _localctx.value = MpRewardType.DIFF; } break; default: throw new NoViableAltException(this); } } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Mp_reward_affect_typeContext extends ParserRuleContext { public MpRewardAffectType value; public Mp_reward_affect_typeContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_mp_reward_affect_type; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterMp_reward_affect_type(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitMp_reward_affect_type(this); } } public final Mp_reward_affect_typeContext mp_reward_affect_type() throws RecognitionException { Mp_reward_affect_typeContext _localctx = new Mp_reward_affect_typeContext(_ctx, getState()); enterRule(_localctx, 180, RULE_mp_reward_affect_type); try { enterOuterAlt(_localctx, 1); { setState(906); _errHandler.sync(this); switch (_input.LA(1)) { case T__85: { setState(902); match(T__85); _localctx.value = MpRewardAffectType.SOLO; } break; case T__86: { setState(904); match(T__86); _localctx.value = MpRewardAffectType.PARTY; } break; default: throw new NoViableAltException(this); } } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Fake_class_idContext extends ParserRuleContext { public Int_objectContext io; public Int_objectContext int_object() { return getRuleContext(Int_objectContext.class,0); } public Fake_class_idContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_fake_class_id; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterFake_class_id(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitFake_class_id(this); } } public final Fake_class_idContext fake_class_id() throws RecognitionException { Fake_class_idContext _localctx = new Fake_class_idContext(_ctx, getState()); enterRule(_localctx, 182, RULE_fake_class_id); try { enterOuterAlt(_localctx, 1); { setState(908); match(T__87); setState(909); match(T__3); setState(910); ((Fake_class_idContext)_localctx).io = int_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Event_dropContext extends ParserRuleContext { public Int_objectContext int_object() { return getRuleContext(Int_objectContext.class,0); } public Event_dropContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_event_drop; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterEvent_drop(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitEvent_drop(this); } } public final Event_dropContext event_drop() throws RecognitionException { Event_dropContext _localctx = new Event_dropContext(_ctx, getState()); enterRule(_localctx, 184, RULE_event_drop); try { enterOuterAlt(_localctx, 1); { setState(912); match(T__88); setState(913); match(T__3); setState(914); int_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Ex_dropContext extends ParserRuleContext { public Int_listContext int_list() { return getRuleContext(Int_listContext.class,0); } public Ex_dropContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_ex_drop; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterEx_drop(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitEx_drop(this); } } public final Ex_dropContext ex_drop() throws RecognitionException { Ex_dropContext _localctx = new Ex_dropContext(_ctx, getState()); enterRule(_localctx, 186, RULE_ex_drop); try { enterOuterAlt(_localctx, 1); { setState(916); match(T__89); setState(917); match(T__3); setState(918); int_list(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Enable_move_after_talkContext extends ParserRuleContext { public Bool_objectContext bool_object() { return getRuleContext(Bool_objectContext.class,0); } public Enable_move_after_talkContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_enable_move_after_talk; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterEnable_move_after_talk(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitEnable_move_after_talk(this); } } public final Enable_move_after_talkContext enable_move_after_talk() throws RecognitionException { Enable_move_after_talkContext _localctx = new Enable_move_after_talkContext(_ctx, getState()); enterRule(_localctx, 188, RULE_enable_move_after_talk); try { enterOuterAlt(_localctx, 1); { setState(920); match(T__90); setState(921); match(T__3); setState(922); bool_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Broadcast_condContext extends ParserRuleContext { public Int_listContext int_list() { return getRuleContext(Int_listContext.class,0); } public Broadcast_condContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_broadcast_cond; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterBroadcast_cond(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitBroadcast_cond(this); } } public final Broadcast_condContext broadcast_cond() throws RecognitionException { Broadcast_condContext _localctx = new Broadcast_condContext(_ctx, getState()); enterRule(_localctx, 190, RULE_broadcast_cond); try { enterOuterAlt(_localctx, 1); { setState(924); match(T__91); setState(925); match(T__3); setState(926); int_list(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Identifier_objectContext extends ParserRuleContext { public String value; public TerminalNode DAGGER() { return getToken(NpcDatasParser.DAGGER, 0); } public TerminalNode BOW() { return getToken(NpcDatasParser.BOW, 0); } public TerminalNode CROSSBOW() { return getToken(NpcDatasParser.CROSSBOW, 0); } public TerminalNode RAPIER() { return getToken(NpcDatasParser.RAPIER, 0); } public TerminalNode GLOVES() { return getToken(NpcDatasParser.GLOVES, 0); } public TerminalNode STEEL() { return getToken(NpcDatasParser.STEEL, 0); } public TerminalNode LEATHER() { return getToken(NpcDatasParser.LEATHER, 0); } public TerminalNode ORIHARUKON() { return getToken(NpcDatasParser.ORIHARUKON, 0); } public TerminalNode NAME() { return getToken(NpcDatasParser.NAME, 0); } public TerminalNode NONE() { return getToken(NpcDatasParser.NONE, 0); } public TerminalNode ORC() { return getToken(NpcDatasParser.ORC, 0); } public TerminalNode BOSS() { return getToken(NpcDatasParser.BOSS, 0); } public Identifier_objectContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_identifier_object; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterIdentifier_object(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitIdentifier_object(this); } } public final Identifier_objectContext identifier_object() throws RecognitionException { Identifier_objectContext _localctx = new Identifier_objectContext(_ctx, getState()); enterRule(_localctx, 192, RULE_identifier_object); int _la; try { enterOuterAlt(_localctx, 1); { setState(928); _la = _input.LA(1); if ( !(_la==T__16 || _la==T__29 || ((((_la - 108)) & ~0x3f) == 0 && ((1L << (_la - 108)) & ((1L << (NONE - 108)) | (1L << (ORC - 108)) | (1L << (BOSS - 108)) | (1L << (BOW - 108)) | (1L << (DAGGER - 108)) | (1L << (RAPIER - 108)) | (1L << (CROSSBOW - 108)))) != 0) || ((((_la - 183)) & ~0x3f) == 0 && ((1L << (_la - 183)) & ((1L << (GLOVES - 183)) | (1L << (STEEL - 183)) | (1L << (LEATHER - 183)) | (1L << (ORIHARUKON - 183)) | (1L << (NAME - 183)))) != 0)) ) { _errHandler.recoverInline(this); } else { if ( _input.LA(1)==Token.EOF ) matchedEOF = true; _errHandler.reportMatch(this); consume(); } } _ctx.stop = _input.LT(-1); _localctx.value = _input.getText(_localctx.start, _input.LT(-1)); } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Bool_objectContext extends ParserRuleContext { public boolean value; public TerminalNode BOOLEAN() { return getToken(NpcDatasParser.BOOLEAN, 0); } public Bool_objectContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_bool_object; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterBool_object(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitBool_object(this); } } public final Bool_objectContext bool_object() throws RecognitionException { Bool_objectContext _localctx = new Bool_objectContext(_ctx, getState()); enterRule(_localctx, 194, RULE_bool_object); try { enterOuterAlt(_localctx, 1); { setState(930); match(BOOLEAN); } _ctx.stop = _input.LT(-1); _localctx.value = _input.getText(_localctx.start, _input.LT(-1)).equals("1"); } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Byte_objectContext extends ParserRuleContext { public byte value; public TerminalNode BOOLEAN() { return getToken(NpcDatasParser.BOOLEAN, 0); } public TerminalNode INTEGER() { return getToken(NpcDatasParser.INTEGER, 0); } public Byte_objectContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_byte_object; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterByte_object(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitByte_object(this); } } public final Byte_objectContext byte_object() throws RecognitionException { Byte_objectContext _localctx = new Byte_objectContext(_ctx, getState()); enterRule(_localctx, 196, RULE_byte_object); int _la; try { enterOuterAlt(_localctx, 1); { setState(932); _la = _input.LA(1); if ( !(_la==BOOLEAN || _la==INTEGER) ) { _errHandler.recoverInline(this); } else { if ( _input.LA(1)==Token.EOF ) matchedEOF = true; _errHandler.reportMatch(this); consume(); } } _ctx.stop = _input.LT(-1); _localctx.value = Byte.valueOf(_input.getText(_localctx.start, _input.LT(-1))); } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Int_objectContext extends ParserRuleContext { public int value; public TerminalNode BOOLEAN() { return getToken(NpcDatasParser.BOOLEAN, 0); } public TerminalNode INTEGER() { return getToken(NpcDatasParser.INTEGER, 0); } public Int_objectContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_int_object; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterInt_object(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitInt_object(this); } } public final Int_objectContext int_object() throws RecognitionException { Int_objectContext _localctx = new Int_objectContext(_ctx, getState()); enterRule(_localctx, 198, RULE_int_object); int _la; try { enterOuterAlt(_localctx, 1); { setState(934); _la = _input.LA(1); if ( !(_la==BOOLEAN || _la==INTEGER) ) { _errHandler.recoverInline(this); } else { if ( _input.LA(1)==Token.EOF ) matchedEOF = true; _errHandler.reportMatch(this); consume(); } } _ctx.stop = _input.LT(-1); _localctx.value = Integer.valueOf(_input.getText(_localctx.start, _input.LT(-1))); } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Long_objectContext extends ParserRuleContext { public long value; public TerminalNode BOOLEAN() { return getToken(NpcDatasParser.BOOLEAN, 0); } public TerminalNode INTEGER() { return getToken(NpcDatasParser.INTEGER, 0); } public Long_objectContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_long_object; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterLong_object(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitLong_object(this); } } public final Long_objectContext long_object() throws RecognitionException { Long_objectContext _localctx = new Long_objectContext(_ctx, getState()); enterRule(_localctx, 200, RULE_long_object); int _la; try { enterOuterAlt(_localctx, 1); { setState(936); _la = _input.LA(1); if ( !(_la==BOOLEAN || _la==INTEGER) ) { _errHandler.recoverInline(this); } else { if ( _input.LA(1)==Token.EOF ) matchedEOF = true; _errHandler.reportMatch(this); consume(); } } _ctx.stop = _input.LT(-1); _localctx.value = Long.valueOf(_input.getText(_localctx.start, _input.LT(-1))); } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Double_objectContext extends ParserRuleContext { public double value; public TerminalNode BOOLEAN() { return getToken(NpcDatasParser.BOOLEAN, 0); } public TerminalNode INTEGER() { return getToken(NpcDatasParser.INTEGER, 0); } public TerminalNode DOUBLE() { return getToken(NpcDatasParser.DOUBLE, 0); } public Double_objectContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_double_object; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterDouble_object(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitDouble_object(this); } } public final Double_objectContext double_object() throws RecognitionException { Double_objectContext _localctx = new Double_objectContext(_ctx, getState()); enterRule(_localctx, 202, RULE_double_object); int _la; try { enterOuterAlt(_localctx, 1); { setState(938); _la = _input.LA(1); if ( !(((((_la - 98)) & ~0x3f) == 0 && ((1L << (_la - 98)) & ((1L << (BOOLEAN - 98)) | (1L << (INTEGER - 98)) | (1L << (DOUBLE - 98)))) != 0)) ) { _errHandler.recoverInline(this); } else { if ( _input.LA(1)==Token.EOF ) matchedEOF = true; _errHandler.reportMatch(this); consume(); } } _ctx.stop = _input.LT(-1); _localctx.value = Double.valueOf(_input.getText(_localctx.start, _input.LT(-1))); } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class String_objectContext extends ParserRuleContext { public String value; public TerminalNode BOOLEAN() { return getToken(NpcDatasParser.BOOLEAN, 0); } public TerminalNode INTEGER() { return getToken(NpcDatasParser.INTEGER, 0); } public TerminalNode DOUBLE() { return getToken(NpcDatasParser.DOUBLE, 0); } public String_objectContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_string_object; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterString_object(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitString_object(this); } } public final String_objectContext string_object() throws RecognitionException { String_objectContext _localctx = new String_objectContext(_ctx, getState()); enterRule(_localctx, 204, RULE_string_object); int _la; try { enterOuterAlt(_localctx, 1); { setState(940); _la = _input.LA(1); if ( !(((((_la - 98)) & ~0x3f) == 0 && ((1L << (_la - 98)) & ((1L << (BOOLEAN - 98)) | (1L << (INTEGER - 98)) | (1L << (DOUBLE - 98)))) != 0)) ) { _errHandler.recoverInline(this); } else { if ( _input.LA(1)==Token.EOF ) matchedEOF = true; _errHandler.reportMatch(this); consume(); } } _ctx.stop = _input.LT(-1); _localctx.value = _input.getText(_localctx.start, _input.LT(-1)); } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Name_objectContext extends ParserRuleContext { public String value; public Identifier_objectContext io; public Identifier_objectContext identifier_object() { return getRuleContext(Identifier_objectContext.class,0); } public Name_objectContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_name_object; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterName_object(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitName_object(this); } } public final Name_objectContext name_object() throws RecognitionException { Name_objectContext _localctx = new Name_objectContext(_ctx, getState()); enterRule(_localctx, 206, RULE_name_object); try { enterOuterAlt(_localctx, 1); { setState(942); match(T__17); setState(943); ((Name_objectContext)_localctx).io = identifier_object(); setState(944); match(T__18); _localctx.value = ((Name_objectContext)_localctx).io.value; } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Category_objectContext extends ParserRuleContext { public TerminalNode CATEGORY() { return getToken(NpcDatasParser.CATEGORY, 0); } public Category_objectContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_category_object; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterCategory_object(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitCategory_object(this); } } public final Category_objectContext category_object() throws RecognitionException { Category_objectContext _localctx = new Category_objectContext(_ctx, getState()); enterRule(_localctx, 208, RULE_category_object); try { enterOuterAlt(_localctx, 1); { setState(947); match(CATEGORY); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Vector3D_objectContext extends ParserRuleContext { public Vector3D value; public Int_objectContext x; public Int_objectContext y; public Int_objectContext z; public List<TerminalNode> SEMICOLON() { return getTokens(NpcDatasParser.SEMICOLON); } public TerminalNode SEMICOLON(int i) { return getToken(NpcDatasParser.SEMICOLON, i); } public List<Int_objectContext> int_object() { return getRuleContexts(Int_objectContext.class); } public Int_objectContext int_object(int i) { return getRuleContext(Int_objectContext.class,i); } public Vector3D_objectContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_vector3D_object; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterVector3D_object(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitVector3D_object(this); } } public final Vector3D_objectContext vector3D_object() throws RecognitionException { Vector3D_objectContext _localctx = new Vector3D_objectContext(_ctx, getState()); enterRule(_localctx, 210, RULE_vector3D_object); try { enterOuterAlt(_localctx, 1); { setState(949); match(T__4); setState(950); ((Vector3D_objectContext)_localctx).x = int_object(); setState(951); match(SEMICOLON); setState(952); ((Vector3D_objectContext)_localctx).y = int_object(); setState(953); match(SEMICOLON); setState(954); ((Vector3D_objectContext)_localctx).z = int_object(); setState(955); match(T__5); } _ctx.stop = _input.LT(-1); _localctx.value = new Vector3D(((Vector3D_objectContext)_localctx).x.value, ((Vector3D_objectContext)_localctx).y.value, ((Vector3D_objectContext)_localctx).z.value); } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Empty_listContext extends ParserRuleContext { public List<String> value; public Empty_listContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_empty_list; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterEmpty_list(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitEmpty_list(this); } } public final Empty_listContext empty_list() throws RecognitionException { Empty_listContext _localctx = new Empty_listContext(_ctx, getState()); enterRule(_localctx, 212, RULE_empty_list); _localctx.value = new ArrayList<>(); try { enterOuterAlt(_localctx, 1); { setState(957); match(T__4); setState(958); match(T__5); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Identifier_listContext extends ParserRuleContext { public List<String> value; public Identifier_objectContext io; public Empty_listContext empty_list() { return getRuleContext(Empty_listContext.class,0); } public List<Identifier_objectContext> identifier_object() { return getRuleContexts(Identifier_objectContext.class); } public Identifier_objectContext identifier_object(int i) { return getRuleContext(Identifier_objectContext.class,i); } public List<TerminalNode> SEMICOLON() { return getTokens(NpcDatasParser.SEMICOLON); } public TerminalNode SEMICOLON(int i) { return getToken(NpcDatasParser.SEMICOLON, i); } public Identifier_listContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_identifier_list; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterIdentifier_list(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitIdentifier_list(this); } } public final Identifier_listContext identifier_list() throws RecognitionException { Identifier_listContext _localctx = new Identifier_listContext(_ctx, getState()); enterRule(_localctx, 214, RULE_identifier_list); _localctx.value = new ArrayList<>(); int _la; try { setState(975); _errHandler.sync(this); switch ( getInterpreter().adaptivePredict(_input,21,_ctx) ) { case 1: enterOuterAlt(_localctx, 1); { setState(960); empty_list(); } break; case 2: enterOuterAlt(_localctx, 2); { setState(961); match(T__4); setState(962); ((Identifier_listContext)_localctx).io = identifier_object(); _localctx.value.add(((Identifier_listContext)_localctx).io.value); setState(970); _errHandler.sync(this); _la = _input.LA(1); while (_la==SEMICOLON) { { { setState(964); match(SEMICOLON); setState(965); ((Identifier_listContext)_localctx).io = identifier_object(); _localctx.value.add(((Identifier_listContext)_localctx).io.value); } } setState(972); _errHandler.sync(this); _la = _input.LA(1); } setState(973); match(T__5); } break; } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Int_listContext extends ParserRuleContext { public List<Integer> value; public Int_objectContext io; public Empty_listContext empty_list() { return getRuleContext(Empty_listContext.class,0); } public List<Int_objectContext> int_object() { return getRuleContexts(Int_objectContext.class); } public Int_objectContext int_object(int i) { return getRuleContext(Int_objectContext.class,i); } public List<TerminalNode> SEMICOLON() { return getTokens(NpcDatasParser.SEMICOLON); } public TerminalNode SEMICOLON(int i) { return getToken(NpcDatasParser.SEMICOLON, i); } public Int_listContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_int_list; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterInt_list(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitInt_list(this); } } public final Int_listContext int_list() throws RecognitionException { Int_listContext _localctx = new Int_listContext(_ctx, getState()); enterRule(_localctx, 216, RULE_int_list); _localctx.value = new ArrayList<>(); int _la; try { setState(992); _errHandler.sync(this); switch ( getInterpreter().adaptivePredict(_input,23,_ctx) ) { case 1: enterOuterAlt(_localctx, 1); { setState(977); empty_list(); } break; case 2: enterOuterAlt(_localctx, 2); { setState(978); match(T__4); setState(979); ((Int_listContext)_localctx).io = int_object(); _localctx.value.add(((Int_listContext)_localctx).io.value); setState(987); _errHandler.sync(this); _la = _input.LA(1); while (_la==SEMICOLON) { { { setState(981); match(SEMICOLON); setState(982); ((Int_listContext)_localctx).io = int_object(); _localctx.value.add(((Int_listContext)_localctx).io.value); } } setState(989); _errHandler.sync(this); _la = _input.LA(1); } setState(990); match(T__5); } break; } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Double_listContext extends ParserRuleContext { public List<Double> value; public Double_objectContext d; public Empty_listContext empty_list() { return getRuleContext(Empty_listContext.class,0); } public List<Double_objectContext> double_object() { return getRuleContexts(Double_objectContext.class); } public Double_objectContext double_object(int i) { return getRuleContext(Double_objectContext.class,i); } public List<TerminalNode> SEMICOLON() { return getTokens(NpcDatasParser.SEMICOLON); } public TerminalNode SEMICOLON(int i) { return getToken(NpcDatasParser.SEMICOLON, i); } public Double_listContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_double_list; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterDouble_list(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitDouble_list(this); } } public final Double_listContext double_list() throws RecognitionException { Double_listContext _localctx = new Double_listContext(_ctx, getState()); enterRule(_localctx, 218, RULE_double_list); _localctx.value = new ArrayList<>(); int _la; try { setState(1009); _errHandler.sync(this); switch ( getInterpreter().adaptivePredict(_input,25,_ctx) ) { case 1: enterOuterAlt(_localctx, 1); { setState(994); empty_list(); } break; case 2: enterOuterAlt(_localctx, 2); { setState(995); match(T__4); setState(996); ((Double_listContext)_localctx).d = double_object(); _localctx.value.add(Double.valueOf((((Double_listContext)_localctx).d!=null?_input.getText(((Double_listContext)_localctx).d.start,((Double_listContext)_localctx).d.stop):null))); setState(1004); _errHandler.sync(this); _la = _input.LA(1); while (_la==SEMICOLON) { { { setState(998); match(SEMICOLON); setState(999); ((Double_listContext)_localctx).d = double_object(); _localctx.value.add(Double.valueOf((((Double_listContext)_localctx).d!=null?_input.getText(((Double_listContext)_localctx).d.start,((Double_listContext)_localctx).d.stop):null))); } } setState(1006); _errHandler.sync(this); _la = _input.LA(1); } setState(1007); match(T__5); } break; } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Base_attribute_attackContext extends ParserRuleContext { public AttributeAttack value; public Attack_attributeContext aa; public Attack_attributeContext attack_attribute() { return getRuleContext(Attack_attributeContext.class,0); } public Base_attribute_attackContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_base_attribute_attack; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterBase_attribute_attack(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitBase_attribute_attack(this); } } public final Base_attribute_attackContext base_attribute_attack() throws RecognitionException { Base_attribute_attackContext _localctx = new Base_attribute_attackContext(_ctx, getState()); enterRule(_localctx, 220, RULE_base_attribute_attack); try { enterOuterAlt(_localctx, 1); { setState(1011); match(T__92); setState(1012); match(T__3); setState(1013); ((Base_attribute_attackContext)_localctx).aa = attack_attribute(); _localctx.value = ((Base_attribute_attackContext)_localctx).aa.value; } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Attack_attributeContext extends ParserRuleContext { public AttributeAttack value; public AttributeContext attribute; public Int_objectContext io; public AttributeContext attribute() { return getRuleContext(AttributeContext.class,0); } public TerminalNode SEMICOLON() { return getToken(NpcDatasParser.SEMICOLON, 0); } public Int_objectContext int_object() { return getRuleContext(Int_objectContext.class,0); } public Attack_attributeContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_attack_attribute; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterAttack_attribute(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitAttack_attribute(this); } } public final Attack_attributeContext attack_attribute() throws RecognitionException { Attack_attributeContext _localctx = new Attack_attributeContext(_ctx, getState()); enterRule(_localctx, 222, RULE_attack_attribute); try { enterOuterAlt(_localctx, 1); { setState(1016); match(T__4); setState(1017); ((Attack_attributeContext)_localctx).attribute = attribute(); setState(1018); match(SEMICOLON); setState(1019); ((Attack_attributeContext)_localctx).io = int_object(); setState(1020); match(T__5); _localctx.value = new AttributeAttack(((Attack_attributeContext)_localctx).attribute.value, ((Attack_attributeContext)_localctx).io.value); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class AttributeContext extends ParserRuleContext { public AttributeType value; public TerminalNode NONE() { return getToken(NpcDatasParser.NONE, 0); } public TerminalNode FIRE() { return getToken(NpcDatasParser.FIRE, 0); } public TerminalNode WATER() { return getToken(NpcDatasParser.WATER, 0); } public TerminalNode EARTH() { return getToken(NpcDatasParser.EARTH, 0); } public TerminalNode WIND() { return getToken(NpcDatasParser.WIND, 0); } public TerminalNode HOLY() { return getToken(NpcDatasParser.HOLY, 0); } public TerminalNode UNHOLY() { return getToken(NpcDatasParser.UNHOLY, 0); } public AttributeContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_attribute; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterAttribute(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitAttribute(this); } } public final AttributeContext attribute() throws RecognitionException { AttributeContext _localctx = new AttributeContext(_ctx, getState()); enterRule(_localctx, 224, RULE_attribute); try { setState(1037); _errHandler.sync(this); switch (_input.LA(1)) { case NONE: enterOuterAlt(_localctx, 1); { setState(1023); match(NONE); _localctx.value = AttributeType.NONE; } break; case FIRE: enterOuterAlt(_localctx, 2); { setState(1025); match(FIRE); _localctx.value = AttributeType.FIRE; } break; case WATER: enterOuterAlt(_localctx, 3); { setState(1027); match(WATER); _localctx.value = AttributeType.WATER; } break; case EARTH: enterOuterAlt(_localctx, 4); { setState(1029); match(EARTH); _localctx.value = AttributeType.EARTH; } break; case WIND: enterOuterAlt(_localctx, 5); { setState(1031); match(WIND); _localctx.value = AttributeType.WIND; } break; case HOLY: enterOuterAlt(_localctx, 6); { setState(1033); match(HOLY); _localctx.value = AttributeType.HOLY; } break; case UNHOLY: enterOuterAlt(_localctx, 7); { setState(1035); match(UNHOLY); _localctx.value = AttributeType.UNHOLY; } break; default: throw new NoViableAltException(this); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Category_listContext extends ParserRuleContext { public List<String> value; public Category_objectContext co; public Empty_listContext empty_list() { return getRuleContext(Empty_listContext.class,0); } public List<Category_objectContext> category_object() { return getRuleContexts(Category_objectContext.class); } public Category_objectContext category_object(int i) { return getRuleContext(Category_objectContext.class,i); } public List<TerminalNode> SEMICOLON() { return getTokens(NpcDatasParser.SEMICOLON); } public TerminalNode SEMICOLON(int i) { return getToken(NpcDatasParser.SEMICOLON, i); } public Category_listContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_category_list; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterCategory_list(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitCategory_list(this); } } public final Category_listContext category_list() throws RecognitionException { Category_listContext _localctx = new Category_listContext(_ctx, getState()); enterRule(_localctx, 226, RULE_category_list); _localctx.value = new ArrayList<>(); int _la; try { setState(1054); _errHandler.sync(this); switch ( getInterpreter().adaptivePredict(_input,28,_ctx) ) { case 1: enterOuterAlt(_localctx, 1); { setState(1039); empty_list(); } break; case 2: enterOuterAlt(_localctx, 2); { setState(1040); match(T__4); setState(1041); ((Category_listContext)_localctx).co = category_object(); _localctx.value.add((((Category_listContext)_localctx).co!=null?_input.getText(((Category_listContext)_localctx).co.start,((Category_listContext)_localctx).co.stop):null)); setState(1049); _errHandler.sync(this); _la = _input.LA(1); while (_la==SEMICOLON) { { { setState(1043); match(SEMICOLON); setState(1044); ((Category_listContext)_localctx).co = category_object(); _localctx.value.add((((Category_listContext)_localctx).co!=null?_input.getText(((Category_listContext)_localctx).co.start,((Category_listContext)_localctx).co.stop):null)); } } setState(1051); _errHandler.sync(this); _la = _input.LA(1); } setState(1052); match(T__5); } break; } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static final String _serializedATN = "\3\u608b\ua72a\u8133\ub9ed\u417c\u3be7\u7786\u5964\3\u00e8\u0423\4\2\t"+ "\2\4\3\t\3\4\4\t\4\4\5\t\5\4\6\t\6\4\7\t\7\4\b\t\b\4\t\t\t\4\n\t\n\4\13"+ "\t\13\4\f\t\f\4\r\t\r\4\16\t\16\4\17\t\17\4\20\t\20\4\21\t\21\4\22\t\22"+ "\4\23\t\23\4\24\t\24\4\25\t\25\4\26\t\26\4\27\t\27\4\30\t\30\4\31\t\31"+ "\4\32\t\32\4\33\t\33\4\34\t\34\4\35\t\35\4\36\t\36\4\37\t\37\4 \t \4!"+ "\t!\4\"\t\"\4#\t#\4$\t$\4%\t%\4&\t&\4\'\t\'\4(\t(\4)\t)\4*\t*\4+\t+\4"+ ",\t,\4-\t-\4.\t.\4/\t/\4\60\t\60\4\61\t\61\4\62\t\62\4\63\t\63\4\64\t"+ "\64\4\65\t\65\4\66\t\66\4\67\t\67\48\t8\49\t9\4:\t:\4;\t;\4<\t<\4=\t="+ "\4>\t>\4?\t?\4@\t@\4A\tA\4B\tB\4C\tC\4D\tD\4E\tE\4F\tF\4G\tG\4H\tH\4I"+ "\tI\4J\tJ\4K\tK\4L\tL\4M\tM\4N\tN\4O\tO\4P\tP\4Q\tQ\4R\tR\4S\tS\4T\tT"+ "\4U\tU\4V\tV\4W\tW\4X\tX\4Y\tY\4Z\tZ\4[\t[\4\\\t\\\4]\t]\4^\t^\4_\t_\4"+ "`\t`\4a\ta\4b\tb\4c\tc\4d\td\4e\te\4f\tf\4g\tg\4h\th\4i\ti\4j\tj\4k\t"+ "k\4l\tl\4m\tm\4n\tn\4o\to\4p\tp\4q\tq\4r\tr\4s\ts\3\2\6\2\u00e8\n\2\r"+ "\2\16\2\u00e9\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3"+ "\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3"+ "\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3"+ "\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3"+ "\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3"+ "\3\3\3\3\3\3\3\3\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3"+ "\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4"+ "\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3"+ "\4\3\4\3\4\3\4\5\4\u0178\n\4\3\5\3\5\3\5\3\6\3\6\3\6\3\7\3\7\3\7\3\7\3"+ "\7\3\b\3\b\3\b\3\b\3\t\3\t\3\t\3\t\3\n\3\n\3\n\3\n\3\n\3\n\3\n\5\n\u0194"+ "\n\n\3\13\3\13\3\13\3\13\3\f\3\f\3\f\3\f\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3"+ "\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r"+ "\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3"+ "\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r"+ "\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\5\r\u01e6\n\r\3\16\3"+ "\16\3\16\3\16\3\16\3\16\3\16\3\16\5\16\u01f0\n\16\3\17\3\17\3\17\3\17"+ "\3\20\3\20\3\20\3\20\5\20\u01fa\n\20\3\21\3\21\3\21\3\21\5\21\u0200\n"+ "\21\3\22\3\22\3\22\3\22\5\22\u0206\n\22\3\23\3\23\3\23\3\24\3\24\3\24"+ "\3\24\3\25\3\25\3\25\3\25\3\26\3\26\3\26\3\26\3\27\3\27\3\27\3\27\3\30"+ "\3\30\3\30\3\30\3\31\3\31\3\31\3\31\3\32\3\32\3\32\3\32\3\33\3\33\3\33"+ "\3\33\3\34\3\34\3\34\3\34\3\35\3\35\3\35\3\35\3\36\3\36\3\36\3\36\3\37"+ "\3\37\3\37\3\37\3 \3 \3 \3 \3!\3!\3!\3!\3\"\3\"\3\"\3\"\3#\3#\3#\3#\3"+ "$\3$\3$\3$\3$\3$\3$\3$\3$\3$\3$\3$\3$\3$\3$\3$\3$\3$\5$\u025d\n$\3%\3"+ "%\3%\3%\3&\3&\3&\3&\3\'\3\'\3\'\3\'\3(\3(\3(\3(\3)\3)\3)\3)\3*\3*\3*\3"+ "*\3+\3+\3+\3+\3,\3,\3,\3,\3-\3-\3-\3-\3.\3.\3.\3.\3/\3/\3/\3/\3\60\3\60"+ "\3\60\3\60\3\60\3\61\3\61\3\61\3\61\3\62\3\62\3\62\3\62\3\63\3\63\3\63"+ "\3\63\3\64\3\64\3\64\3\64\3\65\3\65\3\65\3\65\3\66\3\66\3\66\3\66\3\67"+ "\3\67\3\67\3\67\3\67\3\67\3\67\5\67\u02af\n\67\38\38\38\38\39\39\39\3"+ "9\3:\3:\3:\3:\3;\3;\3;\3;\3<\3<\3<\3<\3=\3=\3=\3=\3>\3>\3>\3>\3?\3?\3"+ "?\3?\3@\3@\3@\3@\3A\3A\3A\3A\3B\3B\3B\3B\3C\3C\3C\3C\3D\3D\3D\3D\3E\3"+ "E\3E\3E\3F\3F\3F\3F\3G\3G\3G\3G\3G\3G\3G\7G\u02f4\nG\fG\16G\u02f7\13G"+ "\3G\3G\3H\3H\3H\3H\3H\3H\3I\3I\3I\3I\3I\3I\5I\u0307\nI\3J\3J\3J\3J\7J"+ "\u030d\nJ\fJ\16J\u0310\13J\3J\3J\3K\3K\3K\3K\3L\3L\3L\3L\3L\3L\3M\3M\3"+ "M\3M\3N\3N\3N\3N\3O\3O\3O\3O\3P\3P\3P\3P\3Q\3Q\3Q\3Q\3R\3R\3R\3R\3S\3"+ "S\3S\3S\3S\3S\7S\u033c\nS\fS\16S\u033f\13S\3S\3S\5S\u0343\nS\3T\3T\3T"+ "\3T\3T\3T\3T\3T\3T\3T\3U\3U\3U\3U\3V\3V\3V\3V\3W\3W\3W\3W\3W\3W\3W\3W"+ "\3W\3W\3W\3W\3W\3W\3W\7W\u0366\nW\fW\16W\u0369\13W\3W\3W\5W\u036d\nW\3"+ "X\3X\3X\3X\3Y\3Y\3Y\3Y\3Z\3Z\3Z\3Z\3Z\3Z\3Z\3Z\3Z\3Z\3Z\3Z\3[\3[\3[\3"+ "[\5[\u0387\n[\3\\\3\\\3\\\3\\\5\\\u038d\n\\\3]\3]\3]\3]\3^\3^\3^\3^\3"+ "_\3_\3_\3_\3`\3`\3`\3`\3a\3a\3a\3a\3b\3b\3c\3c\3d\3d\3e\3e\3f\3f\3g\3"+ "g\3h\3h\3i\3i\3i\3i\3i\3j\3j\3k\3k\3k\3k\3k\3k\3k\3k\3l\3l\3l\3m\3m\3"+ "m\3m\3m\3m\3m\3m\7m\u03cb\nm\fm\16m\u03ce\13m\3m\3m\5m\u03d2\nm\3n\3n"+ "\3n\3n\3n\3n\3n\3n\7n\u03dc\nn\fn\16n\u03df\13n\3n\3n\5n\u03e3\nn\3o\3"+ "o\3o\3o\3o\3o\3o\3o\7o\u03ed\no\fo\16o\u03f0\13o\3o\3o\5o\u03f4\no\3p"+ "\3p\3p\3p\3p\3q\3q\3q\3q\3q\3q\3q\3r\3r\3r\3r\3r\3r\3r\3r\3r\3r\3r\3r"+ "\3r\3r\5r\u0410\nr\3s\3s\3s\3s\3s\3s\3s\3s\7s\u041a\ns\fs\16s\u041d\13"+ "s\3s\3s\5s\u0421\ns\3s\2\2t\2\4\6\b\n\f\16\20\22\24\26\30\32\34\36 \""+ "$&(*,.\60\62\64\668:<>@BDFHJLNPRTVXZ\\^`bdfhjlnprtvxz|~\u0080\u0082\u0084"+ "\u0086\u0088\u008a\u008c\u008e\u0090\u0092\u0094\u0096\u0098\u009a\u009c"+ "\u009e\u00a0\u00a2\u00a4\u00a6\u00a8\u00aa\u00ac\u00ae\u00b0\u00b2\u00b4"+ "\u00b6\u00b8\u00ba\u00bc\u00be\u00c0\u00c2\u00c4\u00c6\u00c8\u00ca\u00cc"+ "\u00ce\u00d0\u00d2\u00d4\u00d6\u00d8\u00da\u00dc\u00de\u00e0\u00e2\u00e4"+ "\2\5\20\2\23\23 nn\u0083\u0083\u0089\u0089\u00a2\u00a2\u00a4\u00a4\u00a9"+ "\u00a9\u00ab\u00ab\u00b9\u00b9\u00ca\u00ca\u00ce\u00ce\u00d1\u00d1\u00e5"+ "\u00e5\3\2de\3\2df\2\u0416\2\u00e7\3\2\2\2\4\u00eb\3\2\2\2\6\u0177\3\2"+ "\2\2\b\u0179\3\2\2\2\n\u017c\3\2\2\2\f\u017f\3\2\2\2\16\u0184\3\2\2\2"+ "\20\u0188\3\2\2\2\22\u018c\3\2\2\2\24\u0195\3\2\2\2\26\u0199\3\2\2\2\30"+ "\u019d\3\2\2\2\32\u01e7\3\2\2\2\34\u01f1\3\2\2\2\36\u01f5\3\2\2\2 \u01fb"+ "\3\2\2\2\"\u0201\3\2\2\2$\u0207\3\2\2\2&\u020a\3\2\2\2(\u020e\3\2\2\2"+ "*\u0212\3\2\2\2,\u0216\3\2\2\2.\u021a\3\2\2\2\60\u021e\3\2\2\2\62\u0222"+ "\3\2\2\2\64\u0226\3\2\2\2\66\u022a\3\2\2\28\u022e\3\2\2\2:\u0232\3\2\2"+ "\2<\u0236\3\2\2\2>\u023a\3\2\2\2@\u023e\3\2\2\2B\u0242\3\2\2\2D\u0246"+ "\3\2\2\2F\u024a\3\2\2\2H\u025e\3\2\2\2J\u0262\3\2\2\2L\u0266\3\2\2\2N"+ "\u026a\3\2\2\2P\u026e\3\2\2\2R\u0272\3\2\2\2T\u0276\3\2\2\2V\u027a\3\2"+ "\2\2X\u027e\3\2\2\2Z\u0282\3\2\2\2\\\u0286\3\2\2\2^\u028a\3\2\2\2`\u028f"+ "\3\2\2\2b\u0293\3\2\2\2d\u0297\3\2\2\2f\u029b\3\2\2\2h\u029f\3\2\2\2j"+ "\u02a3\3\2\2\2l\u02a7\3\2\2\2n\u02b0\3\2\2\2p\u02b4\3\2\2\2r\u02b8\3\2"+ "\2\2t\u02bc\3\2\2\2v\u02c0\3\2\2\2x\u02c4\3\2\2\2z\u02c8\3\2\2\2|\u02cc"+ "\3\2\2\2~\u02d0\3\2\2\2\u0080\u02d4\3\2\2\2\u0082\u02d8\3\2\2\2\u0084"+ "\u02dc\3\2\2\2\u0086\u02e0\3\2\2\2\u0088\u02e4\3\2\2\2\u008a\u02e8\3\2"+ "\2\2\u008c\u02ec\3\2\2\2\u008e\u02fa\3\2\2\2\u0090\u0306\3\2\2\2\u0092"+ "\u0308\3\2\2\2\u0094\u0313\3\2\2\2\u0096\u0317\3\2\2\2\u0098\u031d\3\2"+ "\2\2\u009a\u0321\3\2\2\2\u009c\u0325\3\2\2\2\u009e\u0329\3\2\2\2\u00a0"+ "\u032d\3\2\2\2\u00a2\u0331\3\2\2\2\u00a4\u0342\3\2\2\2\u00a6\u0344\3\2"+ "\2\2\u00a8\u034e\3\2\2\2\u00aa\u0352\3\2\2\2\u00ac\u036c\3\2\2\2\u00ae"+ "\u036e\3\2\2\2\u00b0\u0372\3\2\2\2\u00b2\u0376\3\2\2\2\u00b4\u0386\3\2"+ "\2\2\u00b6\u038c\3\2\2\2\u00b8\u038e\3\2\2\2\u00ba\u0392\3\2\2\2\u00bc"+ "\u0396\3\2\2\2\u00be\u039a\3\2\2\2\u00c0\u039e\3\2\2\2\u00c2\u03a2\3\2"+ "\2\2\u00c4\u03a4\3\2\2\2\u00c6\u03a6\3\2\2\2\u00c8\u03a8\3\2\2\2\u00ca"+ "\u03aa\3\2\2\2\u00cc\u03ac\3\2\2\2\u00ce\u03ae\3\2\2\2\u00d0\u03b0\3\2"+ "\2\2\u00d2\u03b5\3\2\2\2\u00d4\u03b7\3\2\2\2\u00d6\u03bf\3\2\2\2\u00d8"+ "\u03d1\3\2\2\2\u00da\u03e2\3\2\2\2\u00dc\u03f3\3\2\2\2\u00de\u03f5\3\2"+ "\2\2\u00e0\u03fa\3\2\2\2\u00e2\u040f\3\2\2\2\u00e4\u0420\3\2\2\2\u00e6"+ "\u00e8\5\4\3\2\u00e7\u00e6\3\2\2\2\u00e8\u00e9\3\2\2\2\u00e9\u00e7\3\2"+ "\2\2\u00e9\u00ea\3\2\2\2\u00ea\3\3\2\2\2\u00eb\u00ec\7\3\2\2\u00ec\u00ed"+ "\5\6\4\2\u00ed\u00ee\5\b\5\2\u00ee\u00ef\5\n\6\2\u00ef\u00f0\5\f\7\2\u00f0"+ "\u00f1\5\16\b\2\u00f1\u00f2\5\20\t\2\u00f2\u00f3\5\22\n\2\u00f3\u00f4"+ "\5\24\13\2\u00f4\u00f5\5\26\f\2\u00f5\u00f6\5\30\r\2\u00f6\u00f7\5\32"+ "\16\2\u00f7\u00f8\5\34\17\2\u00f8\u00f9\5\36\20\2\u00f9\u00fa\5 \21\2"+ "\u00fa\u00fb\5\"\22\2\u00fb\u00fc\5&\24\2\u00fc\u00fd\5(\25\2\u00fd\u00fe"+ "\5*\26\2\u00fe\u00ff\5,\27\2\u00ff\u0100\5.\30\2\u0100\u0101\5\60\31\2"+ "\u0101\u0102\5\62\32\2\u0102\u0103\5\64\33\2\u0103\u0104\5\66\34\2\u0104"+ "\u0105\58\35\2\u0105\u0106\5:\36\2\u0106\u0107\5<\37\2\u0107\u0108\5>"+ " \2\u0108\u0109\5@!\2\u0109\u010a\5B\"\2\u010a\u010b\5D#\2\u010b\u010c"+ "\5F$\2\u010c\u010d\5H%\2\u010d\u010e\5J&\2\u010e\u010f\5L\'\2\u010f\u0110"+ "\5N(\2\u0110\u0111\5P)\2\u0111\u0112\5R*\2\u0112\u0113\5T+\2\u0113\u0114"+ "\5V,\2\u0114\u0115\5X-\2\u0115\u0116\5Z.\2\u0116\u0117\5\\/\2\u0117\u0118"+ "\5\u00dep\2\u0118\u0119\5^\60\2\u0119\u011a\5`\61\2\u011a\u011b\5b\62"+ "\2\u011b\u011c\5d\63\2\u011c\u011d\5f\64\2\u011d\u011e\5h\65\2\u011e\u011f"+ "\5j\66\2\u011f\u0120\5l\67\2\u0120\u0121\5n8\2\u0121\u0122\5p9\2\u0122"+ "\u0123\5r:\2\u0123\u0124\5t;\2\u0124\u0125\5v<\2\u0125\u0126\5x=\2\u0126"+ "\u0127\5z>\2\u0127\u0128\5|?\2\u0128\u0129\5~@\2\u0129\u012a\5\u0080A"+ "\2\u012a\u012b\5\u0082B\2\u012b\u012c\5\u0084C\2\u012c\u012d\5\u0086D"+ "\2\u012d\u012e\5\u0088E\2\u012e\u012f\5\u008aF\2\u012f\u0130\5\u008cG"+ "\2\u0130\u0131\5\u0096L\2\u0131\u0132\5\u0098M\2\u0132\u0133\5\u009aN"+ "\2\u0133\u0134\5\u009cO\2\u0134\u0135\5\u009eP\2\u0135\u0136\5\u00a0Q"+ "\2\u0136\u0137\5\u00a2R\2\u0137\u0138\5\u00a8U\2\u0138\u0139\5\u00aaV"+ "\2\u0139\u013a\5\u00aeX\2\u013a\u013b\5\u00b0Y\2\u013b\u013c\5\u00b2Z"+ "\2\u013c\u013d\5\u00b8]\2\u013d\u013e\5\u00ba^\2\u013e\u013f\5\u00bc_"+ "\2\u013f\u0140\5\u00be`\2\u0140\u0141\5\u00c0a\2\u0141\u0142\7\4\2\2\u0142"+ "\5\3\2\2\2\u0143\u0144\7\u0091\2\2\u0144\u0178\b\4\1\2\u0145\u0146\7\u0093"+ "\2\2\u0146\u0178\b\4\1\2\u0147\u0148\7\u0092\2\2\u0148\u0178\b\4\1\2\u0149"+ "\u014a\7\u008a\2\2\u014a\u0178\b\4\1\2\u014b\u014c\7\u0089\2\2\u014c\u0178"+ "\b\4\1\2\u014d\u014e\7\u0094\2\2\u014e\u0178\b\4\1\2\u014f\u0150\7\u008b"+ "\2\2\u0150\u0178\b\4\1\2\u0151\u0152\7\u0080\2\2\u0152\u0178\b\4\1\2\u0153"+ "\u0154\7~\2\2\u0154\u0178\b\4\1\2\u0155\u0156\7\u0090\2\2\u0156\u0178"+ "\b\4\1\2\u0157\u0158\7\u0095\2\2\u0158\u0178\b\4\1\2\u0159\u015a\7\u008f"+ "\2\2\u015a\u0178\b\4\1\2\u015b\u015c\7\u0096\2\2\u015c\u0178\b\4\1\2\u015d"+ "\u015e\7\u0097\2\2\u015e\u0178\b\4\1\2\u015f\u0160\7\u008e\2\2\u0160\u0178"+ "\b\4\1\2\u0161\u0162\7\u008c\2\2\u0162\u0178\b\4\1\2\u0163\u0164\7\u0098"+ "\2\2\u0164\u0178\b\4\1\2\u0165\u0166\7\u0099\2\2\u0166\u0178\b\4\1\2\u0167"+ "\u0168\7}\2\2\u0168\u0178\b\4\1\2\u0169\u016a\7|\2\2\u016a\u0178\b\4\1"+ "\2\u016b\u016c\7\u009a\2\2\u016c\u0178\b\4\1\2\u016d\u016e\7\u009b\2\2"+ "\u016e\u0178\b\4\1\2\u016f\u0170\7\u009c\2\2\u0170\u0178\b\4\1\2\u0171"+ "\u0172\7\u009d\2\2\u0172\u0178\b\4\1\2\u0173\u0174\7\u009e\2\2\u0174\u0178"+ "\b\4\1\2\u0175\u0176\7\u009f\2\2\u0176\u0178\b\4\1\2\u0177\u0143\3\2\2"+ "\2\u0177\u0145\3\2\2\2\u0177\u0147\3\2\2\2\u0177\u0149\3\2\2\2\u0177\u014b"+ "\3\2\2\2\u0177\u014d\3\2\2\2\u0177\u014f\3\2\2\2\u0177\u0151\3\2\2\2\u0177"+ "\u0153\3\2\2\2\u0177\u0155\3\2\2\2\u0177\u0157\3\2\2\2\u0177\u0159\3\2"+ "\2\2\u0177\u015b\3\2\2\2\u0177\u015d\3\2\2\2\u0177\u015f\3\2\2\2\u0177"+ "\u0161\3\2\2\2\u0177\u0163\3\2\2\2\u0177\u0165\3\2\2\2\u0177\u0167\3\2"+ "\2\2\u0177\u0169\3\2\2\2\u0177\u016b\3\2\2\2\u0177\u016d\3\2\2\2\u0177"+ "\u016f\3\2\2\2\u0177\u0171\3\2\2\2\u0177\u0173\3\2\2\2\u0177\u0175\3\2"+ "\2\2\u0178\7\3\2\2\2\u0179\u017a\5\u00c8e\2\u017a\u017b\b\5\1\2\u017b"+ "\t\3\2\2\2\u017c\u017d\5\u00d0i\2\u017d\u017e\b\6\1\2\u017e\13\3\2\2\2"+ "\u017f\u0180\7\5\2\2\u0180\u0181\7\6\2\2\u0181\u0182\7\7\2\2\u0182\u0183"+ "\7\b\2\2\u0183\r\3\2\2\2\u0184\u0185\7\t\2\2\u0185\u0186\7\6\2\2\u0186"+ "\u0187\5\u00c8e\2\u0187\17\3\2\2\2\u0188\u0189\7\n\2\2\u0189\u018a\7\6"+ "\2\2\u018a\u018b\5\u00caf\2\u018b\21\3\2\2\2\u018c\u018d\7\13\2\2\u018d"+ "\u0193\7\6\2\2\u018e\u0194\5\u00c4c\2\u018f\u0190\7\7\2\2\u0190\u0191"+ "\5\u00c4c\2\u0191\u0192\7\b\2\2\u0192\u0194\3\2\2\2\u0193\u018e\3\2\2"+ "\2\u0193\u018f\3\2\2\2\u0194\23\3\2\2\2\u0195\u0196\7\f\2\2\u0196\u0197"+ "\7\6\2\2\u0197\u0198\5\u00c4c\2\u0198\25\3\2\2\2\u0199\u019a\7\r\2\2\u019a"+ "\u019b\7\6\2\2\u019b\u019c\5\u00ccg\2\u019c\27\3\2\2\2\u019d\u019e\7\16"+ "\2\2\u019e\u01e5\7\6\2\2\u019f\u01a0\7o\2\2\u01a0\u01e6\b\r\1\2\u01a1"+ "\u01a2\7p\2\2\u01a2\u01e6\b\r\1\2\u01a3\u01a4\7q\2\2\u01a4\u01e6\b\r\1"+ "\2\u01a5\u01a6\7r\2\2\u01a6\u01e6\b\r\1\2\u01a7\u01a8\7s\2\2\u01a8\u01e6"+ "\b\r\1\2\u01a9\u01aa\7t\2\2\u01aa\u01e6\b\r\1\2\u01ab\u01ac\7u\2\2\u01ac"+ "\u01e6\b\r\1\2\u01ad\u01ae\7v\2\2\u01ae\u01e6\b\r\1\2\u01af\u01b0\7w\2"+ "\2\u01b0\u01e6\b\r\1\2\u01b1\u01b2\7x\2\2\u01b2\u01e6\b\r\1\2\u01b3\u01b4"+ "\7z\2\2\u01b4\u01e6\b\r\1\2\u01b5\u01b6\7y\2\2\u01b6\u01e6\b\r\1\2\u01b7"+ "\u01b8\7{\2\2\u01b8\u01e6\b\r\1\2\u01b9\u01ba\7b\2\2\u01ba\u01e6\b\r\1"+ "\2\u01bb\u01bc\7|\2\2\u01bc\u01e6\b\r\1\2\u01bd\u01be\7}\2\2\u01be\u01e6"+ "\b\r\1\2\u01bf\u01c0\7~\2\2\u01c0\u01e6\b\r\1\2\u01c1\u01c2\7\177\2\2"+ "\u01c2\u01e6\b\r\1\2\u01c3\u01c4\7\u0080\2\2\u01c4\u01e6\b\r\1\2\u01c5"+ "\u01c6\7\u0081\2\2\u01c6\u01e6\b\r\1\2\u01c7\u01c8\7\u0082\2\2\u01c8\u01e6"+ "\b\r\1\2\u01c9\u01ca\7\u0083\2\2\u01ca\u01e6\b\r\1\2\u01cb\u01cc\7\u0086"+ "\2\2\u01cc\u01e6\b\r\1\2\u01cd\u01ce\7\u0087\2\2\u01ce\u01e6\b\r\1\2\u01cf"+ "\u01d0\7\u0088\2\2\u01d0\u01e6\b\r\1\2\u01d1\u01d2\7\u0089\2\2\u01d2\u01e6"+ "\b\r\1\2\u01d3\u01d4\7\u008a\2\2\u01d4\u01e6\b\r\1\2\u01d5\u01d6\7\u008b"+ "\2\2\u01d6\u01e6\b\r\1\2\u01d7\u01d8\7\u008c\2\2\u01d8\u01e6\b\r\1\2\u01d9"+ "\u01da\7\u008e\2\2\u01da\u01e6\b\r\1\2\u01db\u01dc\7\u008f\2\2\u01dc\u01e6"+ "\b\r\1\2\u01dd\u01de\7\u0090\2\2\u01de\u01e6\b\r\1\2\u01df\u01e0\7\u008d"+ "\2\2\u01e0\u01e6\b\r\1\2\u01e1\u01e2\7\u0084\2\2\u01e2\u01e6\b\r\1\2\u01e3"+ "\u01e4\7\u0085\2\2\u01e4\u01e6\b\r\1\2\u01e5\u019f\3\2\2\2\u01e5\u01a1"+ "\3\2\2\2\u01e5\u01a3\3\2\2\2\u01e5\u01a5\3\2\2\2\u01e5\u01a7\3\2\2\2\u01e5"+ "\u01a9\3\2\2\2\u01e5\u01ab\3\2\2\2\u01e5\u01ad\3\2\2\2\u01e5\u01af\3\2"+ "\2\2\u01e5\u01b1\3\2\2\2\u01e5\u01b3\3\2\2\2\u01e5\u01b5\3\2\2\2\u01e5"+ "\u01b7\3\2\2\2\u01e5\u01b9\3\2\2\2\u01e5\u01bb\3\2\2\2\u01e5\u01bd\3\2"+ "\2\2\u01e5\u01bf\3\2\2\2\u01e5\u01c1\3\2\2\2\u01e5\u01c3\3\2\2\2\u01e5"+ "\u01c5\3\2\2\2\u01e5\u01c7\3\2\2\2\u01e5\u01c9\3\2\2\2\u01e5\u01cb\3\2"+ "\2\2\u01e5\u01cd\3\2\2\2\u01e5\u01cf\3\2\2\2\u01e5\u01d1\3\2\2\2\u01e5"+ "\u01d3\3\2\2\2\u01e5\u01d5\3\2\2\2\u01e5\u01d7\3\2\2\2\u01e5\u01d9\3\2"+ "\2\2\u01e5\u01db\3\2\2\2\u01e5\u01dd\3\2\2\2\u01e5\u01df\3\2\2\2\u01e5"+ "\u01e1\3\2\2\2\u01e5\u01e3\3\2\2\2\u01e6\31\3\2\2\2\u01e7\u01e8\7\17\2"+ "\2\u01e8\u01ef\7\6\2\2\u01e9\u01ea\7`\2\2\u01ea\u01f0\b\16\1\2\u01eb\u01ec"+ "\7a\2\2\u01ec\u01f0\b\16\1\2\u01ed\u01ee\7b\2\2\u01ee\u01f0\b\16\1\2\u01ef"+ "\u01e9\3\2\2\2\u01ef\u01eb\3\2\2\2\u01ef\u01ed\3\2\2\2\u01f0\33\3\2\2"+ "\2\u01f1\u01f2\7\20\2\2\u01f2\u01f3\7\6\2\2\u01f3\u01f4\5\u00e4s\2\u01f4"+ "\35\3\2\2\2\u01f5\u01f6\7\21\2\2\u01f6\u01f9\7\6\2\2\u01f7\u01fa\5$\23"+ "\2\u01f8\u01fa\5\u00d0i\2\u01f9\u01f7\3\2\2\2\u01f9\u01f8\3\2\2\2\u01fa"+ "\37\3\2\2\2\u01fb\u01fc\7\22\2\2\u01fc\u01ff\7\6\2\2\u01fd\u0200\5$\23"+ "\2\u01fe\u0200\5\u00d0i\2\u01ff\u01fd\3\2\2\2\u01ff\u01fe\3\2\2\2\u0200"+ "!\3\2\2\2\u0201\u0202\7\23\2\2\u0202\u0205\7\6\2\2\u0203\u0206\5$\23\2"+ "\u0204\u0206\5\u00d0i\2\u0205\u0203\3\2\2\2\u0205\u0204\3\2\2\2\u0206"+ "#\3\2\2\2\u0207\u0208\7\24\2\2\u0208\u0209\7\25\2\2\u0209%\3\2\2\2\u020a"+ "\u020b\7\26\2\2\u020b\u020c\7\6\2\2\u020c\u020d\5\u00dco\2\u020d\'\3\2"+ "\2\2\u020e\u020f\7\27\2\2\u020f\u0210\7\6\2\2\u0210\u0211\5\u00dco\2\u0211"+ ")\3\2\2\2\u0212\u0213\7\30\2\2\u0213\u0214\7\6\2\2\u0214\u0215\5\u00cc"+ "g\2\u0215+\3\2\2\2\u0216\u0217\7\31\2\2\u0217\u0218\7\6\2\2\u0218\u0219"+ "\5\u00c8e\2\u0219-\3\2\2\2\u021a\u021b\7\32\2\2\u021b\u021c\7\6\2\2\u021c"+ "\u021d\5\u00dco\2\u021d/\3\2\2\2\u021e\u021f\7\33\2\2\u021f\u0220\7\6"+ "\2\2\u0220\u0221\5\u00dco\2\u0221\61\3\2\2\2\u0222\u0223\7\34\2\2\u0223"+ "\u0224\7\6\2\2\u0224\u0225\5\u00c8e\2\u0225\63\3\2\2\2\u0226\u0227\7\35"+ "\2\2\u0227\u0228\7\6\2\2\u0228\u0229\5\u00c8e\2\u0229\65\3\2\2\2\u022a"+ "\u022b\7\36\2\2\u022b\u022c\7\6\2\2\u022c\u022d\5\u00c8e\2\u022d\67\3"+ "\2\2\2\u022e\u022f\7\37\2\2\u022f\u0230\7\6\2\2\u0230\u0231\5\u00c8e\2"+ "\u02319\3\2\2\2\u0232\u0233\7 \2\2\u0233\u0234\7\6\2\2\u0234\u0235\5\u00c8"+ "e\2\u0235;\3\2\2\2\u0236\u0237\7!\2\2\u0237\u0238\7\6\2\2\u0238\u0239"+ "\5\u00c8e\2\u0239=\3\2\2\2\u023a\u023b\7\"\2\2\u023b\u023c\7\6\2\2\u023c"+ "\u023d\5\u00ccg\2\u023d?\3\2\2\2\u023e\u023f\7#\2\2\u023f\u0240\7\6\2"+ "\2\u0240\u0241\5\u00ccg\2\u0241A\3\2\2\2\u0242\u0243\7$\2\2\u0243\u0244"+ "\7\6\2\2\u0244\u0245\5\u00ccg\2\u0245C\3\2\2\2\u0246\u0247\7%\2\2\u0247"+ "\u0248\7\6\2\2\u0248\u0249\5\u00ccg\2\u0249E\3\2\2\2\u024a\u024b\7&\2"+ "\2\u024b\u025c\7\6\2\2\u024c\u024d\7\u00a0\2\2\u024d\u025d\b$\1\2\u024e"+ "\u024f\7\u00a1\2\2\u024f\u025d\b$\1\2\u0250\u0251\7\u00a2\2\2\u0251\u025d"+ "\b$\1\2\u0252\u0253\7\u00a4\2\2\u0253\u025d\b$\1\2\u0254\u0255\7\u00a6"+ "\2\2\u0255\u025d\b$\1\2\u0256\u0257\7\u00a3\2\2\u0257\u025d\b$\1\2\u0258"+ "\u0259\7\u00a5\2\2\u0259\u025d\b$\1\2\u025a\u025b\7\u00a7\2\2\u025b\u025d"+ "\b$\1\2\u025c\u024c\3\2\2\2\u025c\u024e\3\2\2\2\u025c\u0250\3\2\2\2\u025c"+ "\u0252\3\2\2\2\u025c\u0254\3\2\2\2\u025c\u0256\3\2\2\2\u025c\u0258\3\2"+ "\2\2\u025c\u025a\3\2\2\2\u025dG\3\2\2\2\u025e\u025f\7\'\2\2\u025f\u0260"+ "\7\6\2\2\u0260\u0261\5\u00c8e\2\u0261I\3\2\2\2\u0262\u0263\7(\2\2\u0263"+ "\u0264\7\6\2\2\u0264\u0265\5\u00dan\2\u0265K\3\2\2\2\u0266\u0267\7)\2"+ "\2\u0267\u0268\7\6\2\2\u0268\u0269\5\u00c8e\2\u0269M\3\2\2\2\u026a\u026b"+ "\7*\2\2\u026b\u026c\7\6\2\2\u026c\u026d\5\u00ccg\2\u026dO\3\2\2\2\u026e"+ "\u026f\7+\2\2\u026f\u0270\7\6\2\2\u0270\u0271\5\u00ccg\2\u0271Q\3\2\2"+ "\2\u0272\u0273\7,\2\2\u0273\u0274\7\6\2\2\u0274\u0275\5\u00ccg\2\u0275"+ "S\3\2\2\2\u0276\u0277\7-\2\2\u0277\u0278\7\6\2\2\u0278\u0279\5\u00ccg"+ "\2\u0279U\3\2\2\2\u027a\u027b\7.\2\2\u027b\u027c\7\6\2\2\u027c\u027d\5"+ "\u00c8e\2\u027dW\3\2\2\2\u027e\u027f\7/\2\2\u027f\u0280\7\6\2\2\u0280"+ "\u0281\5\u00ccg\2\u0281Y\3\2\2\2\u0282\u0283\7\60\2\2\u0283\u0284\7\6"+ "\2\2\u0284\u0285\5\u00ccg\2\u0285[\3\2\2\2\u0286\u0287\7\61\2\2\u0287"+ "\u0288\7\6\2\2\u0288\u0289\5\u00ccg\2\u0289]\3\2\2\2\u028a\u028b\7\62"+ "\2\2\u028b\u028c\7\6\2\2\u028c\u028d\5\u00dco\2\u028d\u028e\b\60\1\2\u028e"+ "_\3\2\2\2\u028f\u0290\7\63\2\2\u0290\u0291\7\6\2\2\u0291\u0292\5\u00c8"+ "e\2\u0292a\3\2\2\2\u0293\u0294\7\64\2\2\u0294\u0295\7\6\2\2\u0295\u0296"+ "\5\u00c8e\2\u0296c\3\2\2\2\u0297\u0298\7\65\2\2\u0298\u0299\7\6\2\2\u0299"+ "\u029a\5\u00ccg\2\u029ae\3\2\2\2\u029b\u029c\7\66\2\2\u029c\u029d\7\6"+ "\2\2\u029d\u029e\5\u00c8e\2\u029eg\3\2\2\2\u029f\u02a0\7\67\2\2\u02a0"+ "\u02a1\7\6\2\2\u02a1\u02a2\5\u00c8e\2\u02a2i\3\2\2\2\u02a3\u02a4\78\2"+ "\2\u02a4\u02a5\7\6\2\2\u02a5\u02a6\5\u00c8e\2\u02a6k\3\2\2\2\u02a7\u02a8"+ "\79\2\2\u02a8\u02ae\7\6\2\2\u02a9\u02aa\7\7\2\2\u02aa\u02ab\5\u00c8e\2"+ "\u02ab\u02ac\7\b\2\2\u02ac\u02af\3\2\2\2\u02ad\u02af\5\u00e4s\2\u02ae"+ "\u02a9\3\2\2\2\u02ae\u02ad\3\2\2\2\u02afm\3\2\2\2\u02b0\u02b1\7:\2\2\u02b1"+ "\u02b2\7\6\2\2\u02b2\u02b3\5\u00e4s\2\u02b3o\3\2\2\2\u02b4\u02b5\7;\2"+ "\2\u02b5\u02b6\7\6\2\2\u02b6\u02b7\5\u00c8e\2\u02b7q\3\2\2\2\u02b8\u02b9"+ "\7<\2\2\u02b9\u02ba\7\6\2\2\u02ba\u02bb\5\u00c4c\2\u02bbs\3\2\2\2\u02bc"+ "\u02bd\7=\2\2\u02bd\u02be\7\6\2\2\u02be\u02bf\5\u00c4c\2\u02bfu\3\2\2"+ "\2\u02c0\u02c1\7>\2\2\u02c1\u02c2\7\6\2\2\u02c2\u02c3\5\u00c8e\2\u02c3"+ "w\3\2\2\2\u02c4\u02c5\7?\2\2\u02c5\u02c6\7\6\2\2\u02c6\u02c7\5\u00c4c"+ "\2\u02c7y\3\2\2\2\u02c8\u02c9\7@\2\2\u02c9\u02ca\7\6\2\2\u02ca\u02cb\5"+ "\u00c8e\2\u02cb{\3\2\2\2\u02cc\u02cd\7A\2\2\u02cd\u02ce\7\6\2\2\u02ce"+ "\u02cf\5\u00c8e\2\u02cf}\3\2\2\2\u02d0\u02d1\7B\2\2\u02d1\u02d2\7\6\2"+ "\2\u02d2\u02d3\5\u00c4c\2\u02d3\177\3\2\2\2\u02d4\u02d5\7C\2\2\u02d5\u02d6"+ "\7\6\2\2\u02d6\u02d7\5\u00c4c\2\u02d7\u0081\3\2\2\2\u02d8\u02d9\7D\2\2"+ "\u02d9\u02da\7\6\2\2\u02da\u02db\5\u00c4c\2\u02db\u0083\3\2\2\2\u02dc"+ "\u02dd\7E\2\2\u02dd\u02de\7\6\2\2\u02de\u02df\5\u00c4c\2\u02df\u0085\3"+ "\2\2\2\u02e0\u02e1\7F\2\2\u02e1\u02e2\7\6\2\2\u02e2\u02e3\5\u00c4c\2\u02e3"+ "\u0087\3\2\2\2\u02e4\u02e5\7G\2\2\u02e5\u02e6\7\6\2\2\u02e6\u02e7\5\u00da"+ "n\2\u02e7\u0089\3\2\2\2\u02e8\u02e9\7H\2\2\u02e9\u02ea\7\6\2\2\u02ea\u02eb"+ "\5\u00c4c\2\u02eb\u008b\3\2\2\2\u02ec\u02ed\7I\2\2\u02ed\u02ee\7\6\2\2"+ "\u02ee\u02ef\7\7\2\2\u02ef\u02f5\5\u00d0i\2\u02f0\u02f4\7m\2\2\u02f1\u02f2"+ "\7m\2\2\u02f2\u02f4\5\u008eH\2\u02f3\u02f0\3\2\2\2\u02f3\u02f1\3\2\2\2"+ "\u02f4\u02f7\3\2\2\2\u02f5\u02f3\3\2\2\2\u02f5\u02f6\3\2\2\2\u02f6\u02f8"+ "\3\2\2\2\u02f7\u02f5\3\2\2\2\u02f8\u02f9\7\b\2\2\u02f9\u008d\3\2\2\2\u02fa"+ "\u02fb\7\7\2\2\u02fb\u02fc\5\u00d0i\2\u02fc\u02fd\7\6\2\2\u02fd\u02fe"+ "\5\u0090I\2\u02fe\u02ff\7\b\2\2\u02ff\u008f\3\2\2\2\u0300\u0307\5\u00c8"+ "e\2\u0301\u0307\5\u00ccg\2\u0302\u0307\5\u00d2j\2\u0303\u0307\5\u0092"+ "J\2\u0304\u0307\5\u0094K\2\u0305\u0307\5\u00c2b\2\u0306\u0300\3\2\2\2"+ "\u0306\u0301\3\2\2\2\u0306\u0302\3\2\2\2\u0306\u0303\3\2\2\2\u0306\u0304"+ "\3\2\2\2\u0306\u0305\3\2\2\2\u0307\u0091\3\2\2\2\u0308\u0309\7\24\2\2"+ "\u0309\u030e\5\u00c2b\2\u030a\u030b\7m\2\2\u030b\u030d\5\u00c2b\2\u030c"+ "\u030a\3\2\2\2\u030d\u0310\3\2\2\2\u030e\u030c\3\2\2\2\u030e\u030f\3\2"+ "\2\2\u030f\u0311\3\2\2\2\u0310\u030e\3\2\2\2\u0311\u0312\7\25\2\2\u0312"+ "\u0093\3\2\2\2\u0313\u0314\7\24\2\2\u0314\u0315\5\u00c8e\2\u0315\u0316"+ "\7\25\2\2\u0316\u0095\3\2\2\2\u0317\u0318\7J\2\2\u0318\u0319\7\6\2\2\u0319"+ "\u031a\7\7\2\2\u031a\u031b\5\u00c8e\2\u031b\u031c\7\b\2\2\u031c\u0097"+ "\3\2\2\2\u031d\u031e\7K\2\2\u031e\u031f\7\6\2\2\u031f\u0320\5\u00c4c\2"+ "\u0320\u0099\3\2\2\2\u0321\u0322\7L\2\2\u0322\u0323\7\6\2\2\u0323\u0324"+ "\5\u00c4c\2\u0324\u009b\3\2\2\2\u0325\u0326\7M\2\2\u0326\u0327\7\6\2\2"+ "\u0327\u0328\5\u00ccg\2\u0328\u009d\3\2\2\2\u0329\u032a\7N\2\2\u032a\u032b"+ "\7\6\2\2\u032b\u032c\5\u00ccg\2\u032c\u009f\3\2\2\2\u032d\u032e\7O\2\2"+ "\u032e\u032f\7\6\2\2\u032f\u0330\5\u00ccg\2\u0330\u00a1\3\2\2\2\u0331"+ "\u0332\7P\2\2\u0332\u0333\7\6\2\2\u0333\u0334\5\u00a4S\2\u0334\u00a3\3"+ "\2\2\2\u0335\u0336\7\7\2\2\u0336\u0343\7\b\2\2\u0337\u0338\7\7\2\2\u0338"+ "\u033d\5\u00a6T\2\u0339\u033a\7m\2\2\u033a\u033c\5\u00a6T\2\u033b\u0339"+ "\3\2\2\2\u033c\u033f\3\2\2\2\u033d\u033b\3\2\2\2\u033d\u033e\3\2\2\2\u033e"+ "\u0340\3\2\2\2\u033f\u033d\3\2\2\2\u0340\u0341\7\b\2\2\u0341\u0343\3\2"+ "\2\2\u0342\u0335\3\2\2\2\u0342\u0337\3\2\2\2\u0343\u00a5\3\2\2\2\u0344"+ "\u0345\7\7\2\2\u0345\u0346\5\u00d0i\2\u0346\u0347\7m\2\2\u0347\u0348\5"+ "\u00c8e\2\u0348\u0349\7m\2\2\u0349\u034a\5\u00c8e\2\u034a\u034b\7m\2\2"+ "\u034b\u034c\5\u00ccg\2\u034c\u034d\7\b\2\2\u034d\u00a7\3\2\2\2\u034e"+ "\u034f\7Q\2\2\u034f\u0350\7\6\2\2\u0350\u0351\5\u00a4S\2\u0351\u00a9\3"+ "\2\2\2\u0352\u0353\7R\2\2\u0353\u0354\7\6\2\2\u0354\u0355\5\u00acW\2\u0355"+ "\u00ab\3\2\2\2\u0356\u0357\7\7\2\2\u0357\u036d\7\b\2\2\u0358\u0359\7\7"+ "\2\2\u0359\u035a\7\7\2\2\u035a\u035b\5\u00a4S\2\u035b\u035c\7m\2\2\u035c"+ "\u035d\5\u00ccg\2\u035d\u0367\7\b\2\2\u035e\u035f\7m\2\2\u035f\u0360\7"+ "\7\2\2\u0360\u0361\5\u00a4S\2\u0361\u0362\7m\2\2\u0362\u0363\5\u00ccg"+ "\2\u0363\u0364\7\b\2\2\u0364\u0366\3\2\2\2\u0365\u035e\3\2\2\2\u0366\u0369"+ "\3\2\2\2\u0367\u0365\3\2\2\2\u0367\u0368\3\2\2\2\u0368\u036a\3\2\2\2\u0369"+ "\u0367\3\2\2\2\u036a\u036b\7\b\2\2\u036b\u036d\3\2\2\2\u036c\u0356\3\2"+ "\2\2\u036c\u0358\3\2\2\2\u036d\u00ad\3\2\2\2\u036e\u036f\7S\2\2\u036f"+ "\u0370\7\6\2\2\u0370\u0371\5\u00acW\2\u0371\u00af\3\2\2\2\u0372\u0373"+ "\7T\2\2\u0373\u0374\7\6\2\2\u0374\u0375\5\u00acW\2\u0375\u00b1\3\2\2\2"+ "\u0376\u0377\7U\2\2\u0377\u0378\7\6\2\2\u0378\u0379\7\7\2\2\u0379\u037a"+ "\5\u00ccg\2\u037a\u037b\7m\2\2\u037b\u037c\5\u00b4[\2\u037c\u037d\7m\2"+ "\2\u037d\u037e\5\u00ccg\2\u037e\u037f\7m\2\2\u037f\u0380\5\u00b6\\\2\u0380"+ "\u0381\7\b\2\2\u0381\u00b3\3\2\2\2\u0382\u0383\7V\2\2\u0383\u0387\b[\1"+ "\2\u0384\u0385\7W\2\2\u0385\u0387\b[\1\2\u0386\u0382\3\2\2\2\u0386\u0384"+ "\3\2\2\2\u0387\u00b5\3\2\2\2\u0388\u0389\7X\2\2\u0389\u038d\b\\\1\2\u038a"+ "\u038b\7Y\2\2\u038b\u038d\b\\\1\2\u038c\u0388\3\2\2\2\u038c\u038a\3\2"+ "\2\2\u038d\u00b7\3\2\2\2\u038e\u038f\7Z\2\2\u038f\u0390\7\6\2\2\u0390"+ "\u0391\5\u00c8e\2\u0391\u00b9\3\2\2\2\u0392\u0393\7[\2\2\u0393\u0394\7"+ "\6\2\2\u0394\u0395\5\u00c8e\2\u0395\u00bb\3\2\2\2\u0396\u0397\7\\\2\2"+ "\u0397\u0398\7\6\2\2\u0398\u0399\5\u00dan\2\u0399\u00bd\3\2\2\2\u039a"+ "\u039b\7]\2\2\u039b\u039c\7\6\2\2\u039c\u039d\5\u00c4c\2\u039d\u00bf\3"+ "\2\2\2\u039e\u039f\7^\2\2\u039f\u03a0\7\6\2\2\u03a0\u03a1\5\u00dan\2\u03a1"+ "\u00c1\3\2\2\2\u03a2\u03a3\t\2\2\2\u03a3\u00c3\3\2\2\2\u03a4\u03a5\7d"+ "\2\2\u03a5\u00c5\3\2\2\2\u03a6\u03a7\t\3\2\2\u03a7\u00c7\3\2\2\2\u03a8"+ "\u03a9\t\3\2\2\u03a9\u00c9\3\2\2\2\u03aa\u03ab\t\3\2\2\u03ab\u00cb\3\2"+ "\2\2\u03ac\u03ad\t\4\2\2\u03ad\u00cd\3\2\2\2\u03ae\u03af\t\4\2\2\u03af"+ "\u00cf\3\2\2\2\u03b0\u03b1\7\24\2\2\u03b1\u03b2\5\u00c2b\2\u03b2\u03b3"+ "\7\25\2\2\u03b3\u03b4\bi\1\2\u03b4\u00d1\3\2\2\2\u03b5\u03b6\7c\2\2\u03b6"+ "\u00d3\3\2\2\2\u03b7\u03b8\7\7\2\2\u03b8\u03b9\5\u00c8e\2\u03b9\u03ba"+ "\7m\2\2\u03ba\u03bb\5\u00c8e\2\u03bb\u03bc\7m\2\2\u03bc\u03bd\5\u00c8"+ "e\2\u03bd\u03be\7\b\2\2\u03be\u00d5\3\2\2\2\u03bf\u03c0\7\7\2\2\u03c0"+ "\u03c1\7\b\2\2\u03c1\u00d7\3\2\2\2\u03c2\u03d2\5\u00d6l\2\u03c3\u03c4"+ "\7\7\2\2\u03c4\u03c5\5\u00c2b\2\u03c5\u03cc\bm\1\2\u03c6\u03c7\7m\2\2"+ "\u03c7\u03c8\5\u00c2b\2\u03c8\u03c9\bm\1\2\u03c9\u03cb\3\2\2\2\u03ca\u03c6"+ "\3\2\2\2\u03cb\u03ce\3\2\2\2\u03cc\u03ca\3\2\2\2\u03cc\u03cd\3\2\2\2\u03cd"+ "\u03cf\3\2\2\2\u03ce\u03cc\3\2\2\2\u03cf\u03d0\7\b\2\2\u03d0\u03d2\3\2"+ "\2\2\u03d1\u03c2\3\2\2\2\u03d1\u03c3\3\2\2\2\u03d2\u00d9\3\2\2\2\u03d3"+ "\u03e3\5\u00d6l\2\u03d4\u03d5\7\7\2\2\u03d5\u03d6\5\u00c8e\2\u03d6\u03dd"+ "\bn\1\2\u03d7\u03d8\7m\2\2\u03d8\u03d9\5\u00c8e\2\u03d9\u03da\bn\1\2\u03da"+ "\u03dc\3\2\2\2\u03db\u03d7\3\2\2\2\u03dc\u03df\3\2\2\2\u03dd\u03db\3\2"+ "\2\2\u03dd\u03de\3\2\2\2\u03de\u03e0\3\2\2\2\u03df\u03dd\3\2\2\2\u03e0"+ "\u03e1\7\b\2\2\u03e1\u03e3\3\2\2\2\u03e2\u03d3\3\2\2\2\u03e2\u03d4\3\2"+ "\2\2\u03e3\u00db\3\2\2\2\u03e4\u03f4\5\u00d6l\2\u03e5\u03e6\7\7\2\2\u03e6"+ "\u03e7\5\u00ccg\2\u03e7\u03ee\bo\1\2\u03e8\u03e9\7m\2\2\u03e9\u03ea\5"+ "\u00ccg\2\u03ea\u03eb\bo\1\2\u03eb\u03ed\3\2\2\2\u03ec\u03e8\3\2\2\2\u03ed"+ "\u03f0\3\2\2\2\u03ee\u03ec\3\2\2\2\u03ee\u03ef\3\2\2\2\u03ef\u03f1\3\2"+ "\2\2\u03f0\u03ee\3\2\2\2\u03f1\u03f2\7\b\2\2\u03f2\u03f4\3\2\2\2\u03f3"+ "\u03e4\3\2\2\2\u03f3\u03e5\3\2\2\2\u03f4\u00dd\3\2\2\2\u03f5\u03f6\7_"+ "\2\2\u03f6\u03f7\7\6\2\2\u03f7\u03f8\5\u00e0q\2\u03f8\u03f9\bp\1\2\u03f9"+ "\u00df\3\2\2\2\u03fa\u03fb\7\7\2\2\u03fb\u03fc\5\u00e2r\2\u03fc\u03fd"+ "\7m\2\2\u03fd\u03fe\5\u00c8e\2\u03fe\u03ff\7\b\2\2\u03ff\u0400\bq\1\2"+ "\u0400\u00e1\3\2\2\2\u0401\u0402\7n\2\2\u0402\u0410\br\1\2\u0403\u0404"+ "\7g\2\2\u0404\u0410\br\1\2\u0405\u0406\7h\2\2\u0406\u0410\br\1\2\u0407"+ "\u0408\7i\2\2\u0408\u0410\br\1\2\u0409\u040a\7j\2\2\u040a\u0410\br\1\2"+ "\u040b\u040c\7l\2\2\u040c\u0410\br\1\2\u040d\u040e\7k\2\2\u040e\u0410"+ "\br\1\2\u040f\u0401\3\2\2\2\u040f\u0403\3\2\2\2\u040f\u0405\3\2\2\2\u040f"+ "\u0407\3\2\2\2\u040f\u0409\3\2\2\2\u040f\u040b\3\2\2\2\u040f\u040d\3\2"+ "\2\2\u0410\u00e3\3\2\2\2\u0411\u0421\5\u00d6l\2\u0412\u0413\7\7\2\2\u0413"+ "\u0414\5\u00d2j\2\u0414\u041b\bs\1\2\u0415\u0416\7m\2\2\u0416\u0417\5"+ "\u00d2j\2\u0417\u0418\bs\1\2\u0418\u041a\3\2\2\2\u0419\u0415\3\2\2\2\u041a"+ "\u041d\3\2\2\2\u041b\u0419\3\2\2\2\u041b\u041c\3\2\2\2\u041c\u041e\3\2"+ "\2\2\u041d\u041b\3\2\2\2\u041e\u041f\7\b\2\2\u041f\u0421\3\2\2\2\u0420"+ "\u0411\3\2\2\2\u0420\u0412\3\2\2\2\u0421\u00e5\3\2\2\2\37\u00e9\u0177"+ "\u0193\u01e5\u01ef\u01f9\u01ff\u0205\u025c\u02ae\u02f3\u02f5\u0306\u030e"+ "\u033d\u0342\u0367\u036c\u0386\u038c\u03cc\u03d1\u03dd\u03e2\u03ee\u03f3"+ "\u040f\u041b\u0420"; public static final ATN _ATN = new ATNDeserializer().deserialize(_serializedATN.toCharArray()); static { _decisionToDFA = new DFA[_ATN.getNumberOfDecisions()]; for (int i = 0; i < _ATN.getNumberOfDecisions(); i++) { _decisionToDFA[i] = new DFA(_ATN.getDecisionState(i), i); } } }
UTF-8
Java
245,819
java
NpcDatasParser.java
Java
[]
null
[]
// Generated from org\l2junity\gameserver\data\txt\gen\NpcDatas.g4 by ANTLR 4.7 package org.l2junity.gameserver.data.txt.gen; import org.l2junity.gameserver.data.txt.model.constants.*; import org.apache.commons.math3.geometry.euclidean.threed.Vector3D; import org.l2junity.gameserver.data.txt.model.constants.AttributeType; import org.l2junity.gameserver.data.txt.model.item.AttributeAttack; import org.antlr.v4.runtime.atn.*; import org.antlr.v4.runtime.dfa.DFA; import org.antlr.v4.runtime.*; import org.antlr.v4.runtime.misc.*; import org.antlr.v4.runtime.tree.*; import java.util.List; import java.util.Iterator; import java.util.ArrayList; @SuppressWarnings({"all", "warnings", "unchecked", "unused", "cast"}) public class NpcDatasParser extends Parser { static { RuntimeMetaData.checkVersion("4.7", RuntimeMetaData.VERSION); } protected static final DFA[] _decisionToDFA; protected static final PredictionContextCache _sharedContextCache = new PredictionContextCache(); public static final int T__0=1, T__1=2, T__2=3, T__3=4, T__4=5, T__5=6, T__6=7, T__7=8, T__8=9, T__9=10, T__10=11, T__11=12, T__12=13, T__13=14, T__14=15, T__15=16, T__16=17, T__17=18, T__18=19, T__19=20, T__20=21, T__21=22, T__22=23, T__23=24, T__24=25, T__25=26, T__26=27, T__27=28, T__28=29, T__29=30, T__30=31, T__31=32, T__32=33, T__33=34, T__34=35, T__35=36, T__36=37, T__37=38, T__38=39, T__39=40, T__40=41, T__41=42, T__42=43, T__43=44, T__44=45, T__45=46, T__46=47, T__47=48, T__48=49, T__49=50, T__50=51, T__51=52, T__52=53, T__53=54, T__54=55, T__55=56, T__56=57, T__57=58, T__58=59, T__59=60, T__60=61, T__61=62, T__62=63, T__63=64, T__64=65, T__65=66, T__66=67, T__67=68, T__68=69, T__69=70, T__70=71, T__71=72, T__72=73, T__73=74, T__74=75, T__75=76, T__76=77, T__77=78, T__78=79, T__79=80, T__80=81, T__81=82, T__82=83, T__83=84, T__84=85, T__85=86, T__86=87, T__87=88, T__88=89, T__89=90, T__90=91, T__91=92, T__92=93, MALE=94, FEMALE=95, ETC=96, CATEGORY=97, BOOLEAN=98, INTEGER=99, DOUBLE=100, FIRE=101, WATER=102, EARTH=103, WIND=104, UNHOLY=105, HOLY=106, SEMICOLON=107, NONE=108, FAIRY=109, ANIMAL=110, HUMANOID=111, PLANT=112, UNDEAD=113, CONSTRUCT=114, BEAST=115, BUG=116, ELEMENTAL=117, DEMONIC=118, GIANT=119, DRAGON=120, DIVINE=121, SUMMON=122, PET=123, HOLYTHING=124, DWARF=125, MERCHANT=126, ELF=127, KAMAEL=128, ORC=129, SIEGE_WEAPON=130, FRIEND=131, MERCENARY=132, CASTLE_GUARD=133, HUMAN=134, BOSS=135, ZZOLDAGU=136, WORLD_TRAP=137, MONRACE=138, DARKELF=139, GUARD=140, TELEPORTER=141, WAREHOUSE_KEEPER=142, WARRIOR=143, CITIZEN=144, TREASURE=145, FIELDBOSS=146, BLACKSMITH=147, GUILD_MASTER=148, GUILD_COACH=149, PC_TRAP=150, XMASTREE=151, DOPPELGANGER=152, OWNTHING=153, SIEGE_ATTACKER=154, MRKEEPER=155, COLLECTION=156, PACKAGE_KEEPER=157, SWORD=158, BLUNT=159, BOW=160, POLE=161, DAGGER=162, DUAL=163, FIST=164, DUALFIST=165, FISHINGROD=166, RAPIER=167, ANCIENTSWORD=168, CROSSBOW=169, FLAG=170, DUALDAGGER=171, LIGHT=172, HEAVY=173, MAGIC=174, SIGIL=175, RHAND=176, LRHAND=177, LHAND=178, CHEST=179, LEGS=180, FEET=181, HEAD=182, GLOVES=183, ONEPIECE=184, REAR=185, LEAR=186, RFINGER=187, LFINGER=188, NECK=189, BACK=190, UNDERWEAR=191, HAIR=192, HAIR2=193, HAIRALL=194, ALLDRESS=195, RBRACELET=196, LBRACELET=197, WAIST=198, DECO1=199, STEEL=200, FINE_STEEL=201, WOOD=202, CLOTH=203, LEATHER=204, BONE=205, BRONZE=206, ORIHARUKON=207, MITHRIL=208, DAMASCUS=209, ADAMANTAITE=210, BLOOD_STEEL=211, PAPER=212, GOLD=213, LIQUID=214, FISH=215, SILVER=216, CHRYSOLITE=217, CRYSTAL=218, HORN=219, SCALE_OF_DRAGON=220, COTTON=221, DYESTUFF=222, COBWEB=223, RUNE_XP=224, RUNE_SP=225, RUNE_REMOVE_PENALTY=226, NAME=227, WS=228, LINE_COMMENT=229, STAR_COMMENT=230; public static final int RULE_file = 0, RULE_npc = 1, RULE_npc_type = 2, RULE_npc_id = 3, RULE_npc_name = 4, RULE_category = 5, RULE_level = 6, RULE_exp = 7, RULE_ex_crt_effect = 8, RULE_unique = 9, RULE_s_npc_prop_hp_rate = 10, RULE_race = 11, RULE_sex = 12, RULE_skill_list = 13, RULE_slot_chest = 14, RULE_slot_rhand = 15, RULE_slot_lhand = 16, RULE_empty_name_object = 17, RULE_collision_radius = 18, RULE_collision_height = 19, RULE_hit_time_factor = 20, RULE_hit_time_factor_skill = 21, RULE_ground_high = 22, RULE_ground_low = 23, RULE_str = 24, RULE_int_ = 25, RULE_dex = 26, RULE_wit = 27, RULE_con = 28, RULE_men = 29, RULE_org_hp = 30, RULE_org_hp_regen = 31, RULE_org_mp = 32, RULE_org_mp_regen = 33, RULE_base_attack_type = 34, RULE_base_attack_range = 35, RULE_base_damage_range = 36, RULE_base_rand_dam = 37, RULE_base_physical_attack = 38, RULE_base_critical = 39, RULE_physical_hit_modify = 40, RULE_base_attack_speed = 41, RULE_base_reuse_delay = 42, RULE_base_magic_attack = 43, RULE_base_defend = 44, RULE_base_magic_defend = 45, RULE_base_attribute_defend = 46, RULE_physical_avoid_modify = 47, RULE_shield_defense_rate = 48, RULE_shield_defense = 49, RULE_safe_height = 50, RULE_soulshot_count = 51, RULE_spiritshot_count = 52, RULE_clan = 53, RULE_ignore_clan_list = 54, RULE_clan_help_range = 55, RULE_undying = 56, RULE_can_be_attacked = 57, RULE_corpse_time = 58, RULE_no_sleep_mode = 59, RULE_agro_range = 60, RULE_passable_door = 61, RULE_can_move = 62, RULE_flying = 63, RULE_has_summoner = 64, RULE_targetable = 65, RULE_show_name_tag = 66, RULE_abnormal_resist = 67, RULE_is_death_penalty = 68, RULE_npc_ai = 69, RULE_ai_param = 70, RULE_param_value = 71, RULE_npc_privates = 72, RULE_fstring_object = 73, RULE_event_flag = 74, RULE_unsowing = 75, RULE_private_respawn_log = 76, RULE_acquire_exp_rate = 77, RULE_acquire_sp = 78, RULE_acquire_rp = 79, RULE_corpse_make_list = 80, RULE_make_item_list = 81, RULE_make_item = 82, RULE_additional_make_list = 83, RULE_additional_make_multi_list = 84, RULE_make_group_list = 85, RULE_ex_item_drop_list = 86, RULE_vitality_item_drop_list = 87, RULE_mp_reward = 88, RULE_mp_reward_type = 89, RULE_mp_reward_affect_type = 90, RULE_fake_class_id = 91, RULE_event_drop = 92, RULE_ex_drop = 93, RULE_enable_move_after_talk = 94, RULE_broadcast_cond = 95, RULE_identifier_object = 96, RULE_bool_object = 97, RULE_byte_object = 98, RULE_int_object = 99, RULE_long_object = 100, RULE_double_object = 101, RULE_string_object = 102, RULE_name_object = 103, RULE_category_object = 104, RULE_vector3D_object = 105, RULE_empty_list = 106, RULE_identifier_list = 107, RULE_int_list = 108, RULE_double_list = 109, RULE_base_attribute_attack = 110, RULE_attack_attribute = 111, RULE_attribute = 112, RULE_category_list = 113; public static final String[] ruleNames = { "file", "npc", "npc_type", "npc_id", "npc_name", "category", "level", "exp", "ex_crt_effect", "unique", "s_npc_prop_hp_rate", "race", "sex", "skill_list", "slot_chest", "slot_rhand", "slot_lhand", "empty_name_object", "collision_radius", "collision_height", "hit_time_factor", "hit_time_factor_skill", "ground_high", "ground_low", "str", "int_", "dex", "wit", "con", "men", "org_hp", "org_hp_regen", "org_mp", "org_mp_regen", "base_attack_type", "base_attack_range", "base_damage_range", "base_rand_dam", "base_physical_attack", "base_critical", "physical_hit_modify", "base_attack_speed", "base_reuse_delay", "base_magic_attack", "base_defend", "base_magic_defend", "base_attribute_defend", "physical_avoid_modify", "shield_defense_rate", "shield_defense", "safe_height", "soulshot_count", "spiritshot_count", "clan", "ignore_clan_list", "clan_help_range", "undying", "can_be_attacked", "corpse_time", "no_sleep_mode", "agro_range", "passable_door", "can_move", "flying", "has_summoner", "targetable", "show_name_tag", "abnormal_resist", "is_death_penalty", "npc_ai", "ai_param", "param_value", "npc_privates", "fstring_object", "event_flag", "unsowing", "private_respawn_log", "acquire_exp_rate", "acquire_sp", "acquire_rp", "corpse_make_list", "make_item_list", "make_item", "additional_make_list", "additional_make_multi_list", "make_group_list", "ex_item_drop_list", "vitality_item_drop_list", "mp_reward", "mp_reward_type", "mp_reward_affect_type", "fake_class_id", "event_drop", "ex_drop", "enable_move_after_talk", "broadcast_cond", "identifier_object", "bool_object", "byte_object", "int_object", "long_object", "double_object", "string_object", "name_object", "category_object", "vector3D_object", "empty_list", "identifier_list", "int_list", "double_list", "base_attribute_attack", "attack_attribute", "attribute", "category_list" }; private static final String[] _LITERAL_NAMES = { null, "'npc_begin'", "'npc_end'", "'category'", "'='", "'{'", "'}'", "'level'", "'exp'", "'ex_crt_effect'", "'unique'", "'s_npc_prop_hp_rate'", "'race'", "'sex'", "'skill_list'", "'slot_chest'", "'slot_rhand'", "'slot_lhand'", "'['", "']'", "'collision_radius'", "'collision_height'", "'hit_time_factor'", "'hit_time_factor_skill'", "'ground_high'", "'ground_low'", "'str'", "'int'", "'dex'", "'wit'", "'con'", "'men'", "'org_hp'", "'org_hp_regen'", "'org_mp'", "'org_mp_regen'", "'base_attack_type'", "'base_attack_range'", "'base_damage_range'", "'base_rand_dam'", "'base_physical_attack'", "'base_critical'", "'physical_hit_modify'", "'base_attack_speed'", "'base_reuse_delay'", "'base_magic_attack'", "'base_defend'", "'base_magic_defend'", "'base_attribute_defend'", "'physical_avoid_modify'", "'shield_defense_rate'", "'shield_defense'", "'safe_height'", "'soulshot_count'", "'spiritshot_count'", "'clan'", "'ignore_clan_list'", "'clan_help_range'", "'undying'", "'can_be_attacked'", "'corpse_time'", "'no_sleep_mode'", "'agro_range'", "'passable_door'", "'can_move'", "'flying'", "'has_summoner'", "'targetable'", "'show_name_tag'", "'abnormal_resist'", "'is_death_penalty'", "'npc_ai'", "'event_flag'", "'unsowing'", "'private_respawn_log'", "'acquire_exp_rate'", "'acquire_sp'", "'acquire_rp'", "'corpse_make_list'", "'additional_make_list'", "'additional_make_multi_list'", "'ex_item_drop_list'", "'vitality_item_drop_list'", "'mp_reward'", "'per'", "'diff'", "'solo'", "'party'", "'fake_class_id'", "'event_drop'", "'ex_drop'", "'enable_move_after_talk'", "'broadcast_cond'", "'base_attribute_attack'", "'male'", "'female'", "'etc'", null, null, null, null, "'fire'", "'water'", "'earth'", "'wind'", "'unholy'", "'holy'", "';'", "'none'", "'fairy'", "'animal'", "'humanoid'", "'plant'", "'undead'", "'construct'", "'beast'", "'bug'", "'elemental'", "'demonic'", "'giant'", "'dragon'", "'divine'", "'summon'", "'pet'", "'holything'", "'dwarf'", "'merchant'", "'elf'", "'kamael'", "'orc'", "'siege_weapon'", "'friend'", "'mercenary'", "'castle_guard'", "'human'", "'boss'", "'zzoldagu'", "'world_trap'", "'monrace'", "'darkelf'", "'guard'", "'teleporter'", "'warehouse_keeper'", "'warrior'", "'citizen'", "'treasure'", "'fieldboss'", "'blacksmith'", "'guild_master'", "'guild_coach'", "'pc_trap'", "'xmastree'", "'doppelganger'", "'ownthing'", "'siege_attacker'", "'mrkeeper'", "'collection'", "'package_keeper'", "'sword'", "'blunt'", "'bow'", "'pole'", "'dagger'", "'dual'", "'fist'", "'dualfist'", "'fishingrod'", "'rapier'", "'ancientsword'", "'crossbow'", "'flag'", "'dualdagger'", "'light'", "'heavy'", "'magic'", "'sigil'", "'rhand'", "'lrhand'", "'lhand'", "'chest'", "'legs'", "'feet'", "'head'", "'gloves'", "'onepiece'", "'rear'", "'lear'", "'rfinger'", "'lfinger'", "'neck'", "'back'", "'underwear'", "'hair'", "'hair2'", "'hairall'", "'alldress'", "'rbracelet'", "'lbracelet'", "'waist'", "'deco1'", "'steel'", "'fine_steel'", "'wood'", "'cloth'", "'leather'", "'bone'", "'bronze'", "'oriharukon'", "'mithril'", "'damascus'", "'adamantaite'", "'blood_steel'", "'paper'", "'gold'", "'liquid'", "'fish'", "'silver'", "'chrysolite'", "'crystal'", "'horn'", "'scale_of_dragon'", "'cotton'", "'dyestuff'", "'cobweb'", "'rune_xp'", "'rune_sp'", "'rune_remove_penalty'" }; private static final String[] _SYMBOLIC_NAMES = { null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, "MALE", "FEMALE", "ETC", "CATEGORY", "BOOLEAN", "INTEGER", "DOUBLE", "FIRE", "WATER", "EARTH", "WIND", "UNHOLY", "HOLY", "SEMICOLON", "NONE", "FAIRY", "ANIMAL", "HUMANOID", "PLANT", "UNDEAD", "CONSTRUCT", "BEAST", "BUG", "ELEMENTAL", "DEMONIC", "GIANT", "DRAGON", "DIVINE", "SUMMON", "PET", "HOLYTHING", "DWARF", "MERCHANT", "ELF", "KAMAEL", "ORC", "SIEGE_WEAPON", "FRIEND", "MERCENARY", "CASTLE_GUARD", "HUMAN", "BOSS", "ZZOLDAGU", "WORLD_TRAP", "MONRACE", "DARKELF", "GUARD", "TELEPORTER", "WAREHOUSE_KEEPER", "WARRIOR", "CITIZEN", "TREASURE", "FIELDBOSS", "BLACKSMITH", "GUILD_MASTER", "GUILD_COACH", "PC_TRAP", "XMASTREE", "DOPPELGANGER", "OWNTHING", "SIEGE_ATTACKER", "MRKEEPER", "COLLECTION", "PACKAGE_KEEPER", "SWORD", "BLUNT", "BOW", "POLE", "DAGGER", "DUAL", "FIST", "DUALFIST", "FISHINGROD", "RAPIER", "ANCIENTSWORD", "CROSSBOW", "FLAG", "DUALDAGGER", "LIGHT", "HEAVY", "MAGIC", "SIGIL", "RHAND", "LRHAND", "LHAND", "CHEST", "LEGS", "FEET", "HEAD", "GLOVES", "ONEPIECE", "REAR", "LEAR", "RFINGER", "LFINGER", "NECK", "BACK", "UNDERWEAR", "HAIR", "HAIR2", "HAIRALL", "ALLDRESS", "RBRACELET", "LBRACELET", "WAIST", "DECO1", "STEEL", "FINE_STEEL", "WOOD", "CLOTH", "LEATHER", "BONE", "BRONZE", "ORIHARUKON", "MITHRIL", "DAMASCUS", "ADAMANTAITE", "BLOOD_STEEL", "PAPER", "GOLD", "LIQUID", "FISH", "SILVER", "CHRYSOLITE", "CRYSTAL", "HORN", "SCALE_OF_DRAGON", "COTTON", "DYESTUFF", "COBWEB", "RUNE_XP", "RUNE_SP", "RUNE_REMOVE_PENALTY", "NAME", "WS", "LINE_COMMENT", "STAR_COMMENT" }; public static final Vocabulary VOCABULARY = new VocabularyImpl(_LITERAL_NAMES, _SYMBOLIC_NAMES); /** * @deprecated Use {@link #VOCABULARY} instead. */ @Deprecated public static final String[] tokenNames; static { tokenNames = new String[_SYMBOLIC_NAMES.length]; for (int i = 0; i < tokenNames.length; i++) { tokenNames[i] = VOCABULARY.getLiteralName(i); if (tokenNames[i] == null) { tokenNames[i] = VOCABULARY.getSymbolicName(i); } if (tokenNames[i] == null) { tokenNames[i] = "<INVALID>"; } } } @Override @Deprecated public String[] getTokenNames() { return tokenNames; } @Override public Vocabulary getVocabulary() { return VOCABULARY; } @Override public String getGrammarFileName() { return "NpcDatas.g4"; } @Override public String[] getRuleNames() { return ruleNames; } @Override public String getSerializedATN() { return _serializedATN; } @Override public ATN getATN() { return _ATN; } public NpcDatasParser(TokenStream input) { super(input); _interp = new ParserATNSimulator(this,_ATN,_decisionToDFA,_sharedContextCache); } public static class FileContext extends ParserRuleContext { public List<NpcContext> npc() { return getRuleContexts(NpcContext.class); } public NpcContext npc(int i) { return getRuleContext(NpcContext.class,i); } public FileContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_file; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterFile(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitFile(this); } } public final FileContext file() throws RecognitionException { FileContext _localctx = new FileContext(_ctx, getState()); enterRule(_localctx, 0, RULE_file); int _la; try { enterOuterAlt(_localctx, 1); { setState(229); _errHandler.sync(this); _la = _input.LA(1); do { { { setState(228); npc(); } } setState(231); _errHandler.sync(this); _la = _input.LA(1); } while ( _la==T__0 ); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class NpcContext extends ParserRuleContext { public Npc_typeContext npc_type() { return getRuleContext(Npc_typeContext.class,0); } public Npc_idContext npc_id() { return getRuleContext(Npc_idContext.class,0); } public Npc_nameContext npc_name() { return getRuleContext(Npc_nameContext.class,0); } public CategoryContext category() { return getRuleContext(CategoryContext.class,0); } public LevelContext level() { return getRuleContext(LevelContext.class,0); } public ExpContext exp() { return getRuleContext(ExpContext.class,0); } public Ex_crt_effectContext ex_crt_effect() { return getRuleContext(Ex_crt_effectContext.class,0); } public UniqueContext unique() { return getRuleContext(UniqueContext.class,0); } public S_npc_prop_hp_rateContext s_npc_prop_hp_rate() { return getRuleContext(S_npc_prop_hp_rateContext.class,0); } public RaceContext race() { return getRuleContext(RaceContext.class,0); } public SexContext sex() { return getRuleContext(SexContext.class,0); } public Skill_listContext skill_list() { return getRuleContext(Skill_listContext.class,0); } public Slot_chestContext slot_chest() { return getRuleContext(Slot_chestContext.class,0); } public Slot_rhandContext slot_rhand() { return getRuleContext(Slot_rhandContext.class,0); } public Slot_lhandContext slot_lhand() { return getRuleContext(Slot_lhandContext.class,0); } public Collision_radiusContext collision_radius() { return getRuleContext(Collision_radiusContext.class,0); } public Collision_heightContext collision_height() { return getRuleContext(Collision_heightContext.class,0); } public Hit_time_factorContext hit_time_factor() { return getRuleContext(Hit_time_factorContext.class,0); } public Hit_time_factor_skillContext hit_time_factor_skill() { return getRuleContext(Hit_time_factor_skillContext.class,0); } public Ground_highContext ground_high() { return getRuleContext(Ground_highContext.class,0); } public Ground_lowContext ground_low() { return getRuleContext(Ground_lowContext.class,0); } public StrContext str() { return getRuleContext(StrContext.class,0); } public Int_Context int_() { return getRuleContext(Int_Context.class,0); } public DexContext dex() { return getRuleContext(DexContext.class,0); } public WitContext wit() { return getRuleContext(WitContext.class,0); } public ConContext con() { return getRuleContext(ConContext.class,0); } public MenContext men() { return getRuleContext(MenContext.class,0); } public Org_hpContext org_hp() { return getRuleContext(Org_hpContext.class,0); } public Org_hp_regenContext org_hp_regen() { return getRuleContext(Org_hp_regenContext.class,0); } public Org_mpContext org_mp() { return getRuleContext(Org_mpContext.class,0); } public Org_mp_regenContext org_mp_regen() { return getRuleContext(Org_mp_regenContext.class,0); } public Base_attack_typeContext base_attack_type() { return getRuleContext(Base_attack_typeContext.class,0); } public Base_attack_rangeContext base_attack_range() { return getRuleContext(Base_attack_rangeContext.class,0); } public Base_damage_rangeContext base_damage_range() { return getRuleContext(Base_damage_rangeContext.class,0); } public Base_rand_damContext base_rand_dam() { return getRuleContext(Base_rand_damContext.class,0); } public Base_physical_attackContext base_physical_attack() { return getRuleContext(Base_physical_attackContext.class,0); } public Base_criticalContext base_critical() { return getRuleContext(Base_criticalContext.class,0); } public Physical_hit_modifyContext physical_hit_modify() { return getRuleContext(Physical_hit_modifyContext.class,0); } public Base_attack_speedContext base_attack_speed() { return getRuleContext(Base_attack_speedContext.class,0); } public Base_reuse_delayContext base_reuse_delay() { return getRuleContext(Base_reuse_delayContext.class,0); } public Base_magic_attackContext base_magic_attack() { return getRuleContext(Base_magic_attackContext.class,0); } public Base_defendContext base_defend() { return getRuleContext(Base_defendContext.class,0); } public Base_magic_defendContext base_magic_defend() { return getRuleContext(Base_magic_defendContext.class,0); } public Base_attribute_attackContext base_attribute_attack() { return getRuleContext(Base_attribute_attackContext.class,0); } public Base_attribute_defendContext base_attribute_defend() { return getRuleContext(Base_attribute_defendContext.class,0); } public Physical_avoid_modifyContext physical_avoid_modify() { return getRuleContext(Physical_avoid_modifyContext.class,0); } public Shield_defense_rateContext shield_defense_rate() { return getRuleContext(Shield_defense_rateContext.class,0); } public Shield_defenseContext shield_defense() { return getRuleContext(Shield_defenseContext.class,0); } public Safe_heightContext safe_height() { return getRuleContext(Safe_heightContext.class,0); } public Soulshot_countContext soulshot_count() { return getRuleContext(Soulshot_countContext.class,0); } public Spiritshot_countContext spiritshot_count() { return getRuleContext(Spiritshot_countContext.class,0); } public ClanContext clan() { return getRuleContext(ClanContext.class,0); } public Ignore_clan_listContext ignore_clan_list() { return getRuleContext(Ignore_clan_listContext.class,0); } public Clan_help_rangeContext clan_help_range() { return getRuleContext(Clan_help_rangeContext.class,0); } public UndyingContext undying() { return getRuleContext(UndyingContext.class,0); } public Can_be_attackedContext can_be_attacked() { return getRuleContext(Can_be_attackedContext.class,0); } public Corpse_timeContext corpse_time() { return getRuleContext(Corpse_timeContext.class,0); } public No_sleep_modeContext no_sleep_mode() { return getRuleContext(No_sleep_modeContext.class,0); } public Agro_rangeContext agro_range() { return getRuleContext(Agro_rangeContext.class,0); } public Passable_doorContext passable_door() { return getRuleContext(Passable_doorContext.class,0); } public Can_moveContext can_move() { return getRuleContext(Can_moveContext.class,0); } public FlyingContext flying() { return getRuleContext(FlyingContext.class,0); } public Has_summonerContext has_summoner() { return getRuleContext(Has_summonerContext.class,0); } public TargetableContext targetable() { return getRuleContext(TargetableContext.class,0); } public Show_name_tagContext show_name_tag() { return getRuleContext(Show_name_tagContext.class,0); } public Abnormal_resistContext abnormal_resist() { return getRuleContext(Abnormal_resistContext.class,0); } public Is_death_penaltyContext is_death_penalty() { return getRuleContext(Is_death_penaltyContext.class,0); } public Npc_aiContext npc_ai() { return getRuleContext(Npc_aiContext.class,0); } public Event_flagContext event_flag() { return getRuleContext(Event_flagContext.class,0); } public UnsowingContext unsowing() { return getRuleContext(UnsowingContext.class,0); } public Private_respawn_logContext private_respawn_log() { return getRuleContext(Private_respawn_logContext.class,0); } public Acquire_exp_rateContext acquire_exp_rate() { return getRuleContext(Acquire_exp_rateContext.class,0); } public Acquire_spContext acquire_sp() { return getRuleContext(Acquire_spContext.class,0); } public Acquire_rpContext acquire_rp() { return getRuleContext(Acquire_rpContext.class,0); } public Corpse_make_listContext corpse_make_list() { return getRuleContext(Corpse_make_listContext.class,0); } public Additional_make_listContext additional_make_list() { return getRuleContext(Additional_make_listContext.class,0); } public Additional_make_multi_listContext additional_make_multi_list() { return getRuleContext(Additional_make_multi_listContext.class,0); } public Ex_item_drop_listContext ex_item_drop_list() { return getRuleContext(Ex_item_drop_listContext.class,0); } public Vitality_item_drop_listContext vitality_item_drop_list() { return getRuleContext(Vitality_item_drop_listContext.class,0); } public Mp_rewardContext mp_reward() { return getRuleContext(Mp_rewardContext.class,0); } public Fake_class_idContext fake_class_id() { return getRuleContext(Fake_class_idContext.class,0); } public Event_dropContext event_drop() { return getRuleContext(Event_dropContext.class,0); } public Ex_dropContext ex_drop() { return getRuleContext(Ex_dropContext.class,0); } public Enable_move_after_talkContext enable_move_after_talk() { return getRuleContext(Enable_move_after_talkContext.class,0); } public Broadcast_condContext broadcast_cond() { return getRuleContext(Broadcast_condContext.class,0); } public NpcContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_npc; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterNpc(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitNpc(this); } } public final NpcContext npc() throws RecognitionException { NpcContext _localctx = new NpcContext(_ctx, getState()); enterRule(_localctx, 2, RULE_npc); try { enterOuterAlt(_localctx, 1); { setState(233); match(T__0); setState(234); npc_type(); setState(235); npc_id(); setState(236); npc_name(); setState(237); category(); setState(238); level(); setState(239); exp(); setState(240); ex_crt_effect(); setState(241); unique(); setState(242); s_npc_prop_hp_rate(); setState(243); race(); setState(244); sex(); setState(245); skill_list(); setState(246); slot_chest(); setState(247); slot_rhand(); setState(248); slot_lhand(); setState(249); collision_radius(); setState(250); collision_height(); setState(251); hit_time_factor(); setState(252); hit_time_factor_skill(); setState(253); ground_high(); setState(254); ground_low(); setState(255); str(); setState(256); int_(); setState(257); dex(); setState(258); wit(); setState(259); con(); setState(260); men(); setState(261); org_hp(); setState(262); org_hp_regen(); setState(263); org_mp(); setState(264); org_mp_regen(); setState(265); base_attack_type(); setState(266); base_attack_range(); setState(267); base_damage_range(); setState(268); base_rand_dam(); setState(269); base_physical_attack(); setState(270); base_critical(); setState(271); physical_hit_modify(); setState(272); base_attack_speed(); setState(273); base_reuse_delay(); setState(274); base_magic_attack(); setState(275); base_defend(); setState(276); base_magic_defend(); setState(277); base_attribute_attack(); setState(278); base_attribute_defend(); setState(279); physical_avoid_modify(); setState(280); shield_defense_rate(); setState(281); shield_defense(); setState(282); safe_height(); setState(283); soulshot_count(); setState(284); spiritshot_count(); setState(285); clan(); setState(286); ignore_clan_list(); setState(287); clan_help_range(); setState(288); undying(); setState(289); can_be_attacked(); setState(290); corpse_time(); setState(291); no_sleep_mode(); setState(292); agro_range(); setState(293); passable_door(); setState(294); can_move(); setState(295); flying(); setState(296); has_summoner(); setState(297); targetable(); setState(298); show_name_tag(); setState(299); abnormal_resist(); setState(300); is_death_penalty(); setState(301); npc_ai(); setState(302); event_flag(); setState(303); unsowing(); setState(304); private_respawn_log(); setState(305); acquire_exp_rate(); setState(306); acquire_sp(); setState(307); acquire_rp(); setState(308); corpse_make_list(); setState(309); additional_make_list(); setState(310); additional_make_multi_list(); setState(311); ex_item_drop_list(); setState(312); vitality_item_drop_list(); setState(313); mp_reward(); setState(314); fake_class_id(); setState(315); event_drop(); setState(316); ex_drop(); setState(317); enable_move_after_talk(); setState(318); broadcast_cond(); setState(319); match(T__1); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Npc_typeContext extends ParserRuleContext { public NpcType value; public TerminalNode WARRIOR() { return getToken(NpcDatasParser.WARRIOR, 0); } public TerminalNode TREASURE() { return getToken(NpcDatasParser.TREASURE, 0); } public TerminalNode CITIZEN() { return getToken(NpcDatasParser.CITIZEN, 0); } public TerminalNode ZZOLDAGU() { return getToken(NpcDatasParser.ZZOLDAGU, 0); } public TerminalNode BOSS() { return getToken(NpcDatasParser.BOSS, 0); } public TerminalNode FIELDBOSS() { return getToken(NpcDatasParser.FIELDBOSS, 0); } public TerminalNode WORLD_TRAP() { return getToken(NpcDatasParser.WORLD_TRAP, 0); } public TerminalNode MERCHANT() { return getToken(NpcDatasParser.MERCHANT, 0); } public TerminalNode HOLYTHING() { return getToken(NpcDatasParser.HOLYTHING, 0); } public TerminalNode WAREHOUSE_KEEPER() { return getToken(NpcDatasParser.WAREHOUSE_KEEPER, 0); } public TerminalNode BLACKSMITH() { return getToken(NpcDatasParser.BLACKSMITH, 0); } public TerminalNode TELEPORTER() { return getToken(NpcDatasParser.TELEPORTER, 0); } public TerminalNode GUILD_MASTER() { return getToken(NpcDatasParser.GUILD_MASTER, 0); } public TerminalNode GUILD_COACH() { return getToken(NpcDatasParser.GUILD_COACH, 0); } public TerminalNode GUARD() { return getToken(NpcDatasParser.GUARD, 0); } public TerminalNode MONRACE() { return getToken(NpcDatasParser.MONRACE, 0); } public TerminalNode PC_TRAP() { return getToken(NpcDatasParser.PC_TRAP, 0); } public TerminalNode XMASTREE() { return getToken(NpcDatasParser.XMASTREE, 0); } public TerminalNode PET() { return getToken(NpcDatasParser.PET, 0); } public TerminalNode SUMMON() { return getToken(NpcDatasParser.SUMMON, 0); } public TerminalNode DOPPELGANGER() { return getToken(NpcDatasParser.DOPPELGANGER, 0); } public TerminalNode OWNTHING() { return getToken(NpcDatasParser.OWNTHING, 0); } public TerminalNode SIEGE_ATTACKER() { return getToken(NpcDatasParser.SIEGE_ATTACKER, 0); } public TerminalNode MRKEEPER() { return getToken(NpcDatasParser.MRKEEPER, 0); } public TerminalNode COLLECTION() { return getToken(NpcDatasParser.COLLECTION, 0); } public TerminalNode PACKAGE_KEEPER() { return getToken(NpcDatasParser.PACKAGE_KEEPER, 0); } public Npc_typeContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_npc_type; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterNpc_type(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitNpc_type(this); } } public final Npc_typeContext npc_type() throws RecognitionException { Npc_typeContext _localctx = new Npc_typeContext(_ctx, getState()); enterRule(_localctx, 4, RULE_npc_type); try { setState(373); _errHandler.sync(this); switch (_input.LA(1)) { case WARRIOR: enterOuterAlt(_localctx, 1); { setState(321); match(WARRIOR); _localctx.value = NpcType.WARRIOR; } break; case TREASURE: enterOuterAlt(_localctx, 2); { setState(323); match(TREASURE); _localctx.value = NpcType.TREASURE; } break; case CITIZEN: enterOuterAlt(_localctx, 3); { setState(325); match(CITIZEN); _localctx.value = NpcType.CITIZEN; } break; case ZZOLDAGU: enterOuterAlt(_localctx, 4); { setState(327); match(ZZOLDAGU); _localctx.value = NpcType.ZZOLDAGU; } break; case BOSS: enterOuterAlt(_localctx, 5); { setState(329); match(BOSS); _localctx.value = NpcType.BOSS; } break; case FIELDBOSS: enterOuterAlt(_localctx, 6); { setState(331); match(FIELDBOSS); _localctx.value = NpcType.FIELDBOSS; } break; case WORLD_TRAP: enterOuterAlt(_localctx, 7); { setState(333); match(WORLD_TRAP); _localctx.value = NpcType.WORLD_TRAP; } break; case MERCHANT: enterOuterAlt(_localctx, 8); { setState(335); match(MERCHANT); _localctx.value = NpcType.MERCHANT; } break; case HOLYTHING: enterOuterAlt(_localctx, 9); { setState(337); match(HOLYTHING); _localctx.value = NpcType.HOLYTHING; } break; case WAREHOUSE_KEEPER: enterOuterAlt(_localctx, 10); { setState(339); match(WAREHOUSE_KEEPER); _localctx.value = NpcType.WAREHOUSE_KEEPER; } break; case BLACKSMITH: enterOuterAlt(_localctx, 11); { setState(341); match(BLACKSMITH); _localctx.value = NpcType.BLACKSMITH; } break; case TELEPORTER: enterOuterAlt(_localctx, 12); { setState(343); match(TELEPORTER); _localctx.value = NpcType.TELEPORTER; } break; case GUILD_MASTER: enterOuterAlt(_localctx, 13); { setState(345); match(GUILD_MASTER); _localctx.value = NpcType.GUILD_MASTER; } break; case GUILD_COACH: enterOuterAlt(_localctx, 14); { setState(347); match(GUILD_COACH); _localctx.value = NpcType.GUILD_COACH; } break; case GUARD: enterOuterAlt(_localctx, 15); { setState(349); match(GUARD); _localctx.value = NpcType.GUARD; } break; case MONRACE: enterOuterAlt(_localctx, 16); { setState(351); match(MONRACE); _localctx.value = NpcType.MONRACE; } break; case PC_TRAP: enterOuterAlt(_localctx, 17); { setState(353); match(PC_TRAP); _localctx.value = NpcType.PC_TRAP; } break; case XMASTREE: enterOuterAlt(_localctx, 18); { setState(355); match(XMASTREE); _localctx.value = NpcType.XMASTREE; } break; case PET: enterOuterAlt(_localctx, 19); { setState(357); match(PET); _localctx.value = NpcType.PET; } break; case SUMMON: enterOuterAlt(_localctx, 20); { setState(359); match(SUMMON); _localctx.value = NpcType.SUMMON; } break; case DOPPELGANGER: enterOuterAlt(_localctx, 21); { setState(361); match(DOPPELGANGER); _localctx.value = NpcType.DOPPELGANGER; } break; case OWNTHING: enterOuterAlt(_localctx, 22); { setState(363); match(OWNTHING); _localctx.value = NpcType.OWNTHING; } break; case SIEGE_ATTACKER: enterOuterAlt(_localctx, 23); { setState(365); match(SIEGE_ATTACKER); _localctx.value = NpcType.SIEGE_ATTACKER; } break; case MRKEEPER: enterOuterAlt(_localctx, 24); { setState(367); match(MRKEEPER); _localctx.value = NpcType.MRKEEPER; } break; case COLLECTION: enterOuterAlt(_localctx, 25); { setState(369); match(COLLECTION); _localctx.value = NpcType.COLLECTION; } break; case PACKAGE_KEEPER: enterOuterAlt(_localctx, 26); { setState(371); match(PACKAGE_KEEPER); _localctx.value = NpcType.PACKAGE_KEEPER; } break; default: throw new NoViableAltException(this); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Npc_idContext extends ParserRuleContext { public int value; public Int_objectContext io; public Int_objectContext int_object() { return getRuleContext(Int_objectContext.class,0); } public Npc_idContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_npc_id; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterNpc_id(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitNpc_id(this); } } public final Npc_idContext npc_id() throws RecognitionException { Npc_idContext _localctx = new Npc_idContext(_ctx, getState()); enterRule(_localctx, 6, RULE_npc_id); try { enterOuterAlt(_localctx, 1); { setState(375); ((Npc_idContext)_localctx).io = int_object(); _localctx.value = ((Npc_idContext)_localctx).io.value; } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Npc_nameContext extends ParserRuleContext { public String value; public Name_objectContext no; public Name_objectContext name_object() { return getRuleContext(Name_objectContext.class,0); } public Npc_nameContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_npc_name; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterNpc_name(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitNpc_name(this); } } public final Npc_nameContext npc_name() throws RecognitionException { Npc_nameContext _localctx = new Npc_nameContext(_ctx, getState()); enterRule(_localctx, 8, RULE_npc_name); try { enterOuterAlt(_localctx, 1); { setState(378); ((Npc_nameContext)_localctx).no = name_object(); _localctx.value = ((Npc_nameContext)_localctx).no.value; } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class CategoryContext extends ParserRuleContext { public CategoryContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_category; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterCategory(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitCategory(this); } } public final CategoryContext category() throws RecognitionException { CategoryContext _localctx = new CategoryContext(_ctx, getState()); enterRule(_localctx, 10, RULE_category); try { enterOuterAlt(_localctx, 1); { setState(381); match(T__2); setState(382); match(T__3); setState(383); match(T__4); setState(384); match(T__5); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class LevelContext extends ParserRuleContext { public Int_objectContext io; public Int_objectContext int_object() { return getRuleContext(Int_objectContext.class,0); } public LevelContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_level; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterLevel(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitLevel(this); } } public final LevelContext level() throws RecognitionException { LevelContext _localctx = new LevelContext(_ctx, getState()); enterRule(_localctx, 12, RULE_level); try { enterOuterAlt(_localctx, 1); { setState(386); match(T__6); setState(387); match(T__3); setState(388); ((LevelContext)_localctx).io = int_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class ExpContext extends ParserRuleContext { public Long_objectContext lo; public Long_objectContext long_object() { return getRuleContext(Long_objectContext.class,0); } public ExpContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_exp; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterExp(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitExp(this); } } public final ExpContext exp() throws RecognitionException { ExpContext _localctx = new ExpContext(_ctx, getState()); enterRule(_localctx, 14, RULE_exp); try { enterOuterAlt(_localctx, 1); { setState(390); match(T__7); setState(391); match(T__3); setState(392); ((ExpContext)_localctx).lo = long_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Ex_crt_effectContext extends ParserRuleContext { public Bool_objectContext bo; public Bool_objectContext bool_object() { return getRuleContext(Bool_objectContext.class,0); } public Ex_crt_effectContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_ex_crt_effect; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterEx_crt_effect(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitEx_crt_effect(this); } } public final Ex_crt_effectContext ex_crt_effect() throws RecognitionException { Ex_crt_effectContext _localctx = new Ex_crt_effectContext(_ctx, getState()); enterRule(_localctx, 16, RULE_ex_crt_effect); try { enterOuterAlt(_localctx, 1); { setState(394); match(T__8); setState(395); match(T__3); setState(401); _errHandler.sync(this); switch (_input.LA(1)) { case BOOLEAN: { setState(396); ((Ex_crt_effectContext)_localctx).bo = bool_object(); } break; case T__4: { setState(397); match(T__4); setState(398); ((Ex_crt_effectContext)_localctx).bo = bool_object(); setState(399); match(T__5); } break; default: throw new NoViableAltException(this); } } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class UniqueContext extends ParserRuleContext { public Bool_objectContext bo; public Bool_objectContext bool_object() { return getRuleContext(Bool_objectContext.class,0); } public UniqueContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_unique; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterUnique(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitUnique(this); } } public final UniqueContext unique() throws RecognitionException { UniqueContext _localctx = new UniqueContext(_ctx, getState()); enterRule(_localctx, 18, RULE_unique); try { enterOuterAlt(_localctx, 1); { setState(403); match(T__9); setState(404); match(T__3); setState(405); ((UniqueContext)_localctx).bo = bool_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class S_npc_prop_hp_rateContext extends ParserRuleContext { public Double_objectContext d; public Double_objectContext double_object() { return getRuleContext(Double_objectContext.class,0); } public S_npc_prop_hp_rateContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_s_npc_prop_hp_rate; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterS_npc_prop_hp_rate(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitS_npc_prop_hp_rate(this); } } public final S_npc_prop_hp_rateContext s_npc_prop_hp_rate() throws RecognitionException { S_npc_prop_hp_rateContext _localctx = new S_npc_prop_hp_rateContext(_ctx, getState()); enterRule(_localctx, 20, RULE_s_npc_prop_hp_rate); try { enterOuterAlt(_localctx, 1); { setState(407); match(T__10); setState(408); match(T__3); setState(409); ((S_npc_prop_hp_rateContext)_localctx).d = double_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class RaceContext extends ParserRuleContext { public RaceType value; public TerminalNode FAIRY() { return getToken(NpcDatasParser.FAIRY, 0); } public TerminalNode ANIMAL() { return getToken(NpcDatasParser.ANIMAL, 0); } public TerminalNode HUMANOID() { return getToken(NpcDatasParser.HUMANOID, 0); } public TerminalNode PLANT() { return getToken(NpcDatasParser.PLANT, 0); } public TerminalNode UNDEAD() { return getToken(NpcDatasParser.UNDEAD, 0); } public TerminalNode CONSTRUCT() { return getToken(NpcDatasParser.CONSTRUCT, 0); } public TerminalNode BEAST() { return getToken(NpcDatasParser.BEAST, 0); } public TerminalNode BUG() { return getToken(NpcDatasParser.BUG, 0); } public TerminalNode ELEMENTAL() { return getToken(NpcDatasParser.ELEMENTAL, 0); } public TerminalNode DEMONIC() { return getToken(NpcDatasParser.DEMONIC, 0); } public TerminalNode DRAGON() { return getToken(NpcDatasParser.DRAGON, 0); } public TerminalNode GIANT() { return getToken(NpcDatasParser.GIANT, 0); } public TerminalNode DIVINE() { return getToken(NpcDatasParser.DIVINE, 0); } public TerminalNode ETC() { return getToken(NpcDatasParser.ETC, 0); } public TerminalNode SUMMON() { return getToken(NpcDatasParser.SUMMON, 0); } public TerminalNode PET() { return getToken(NpcDatasParser.PET, 0); } public TerminalNode HOLYTHING() { return getToken(NpcDatasParser.HOLYTHING, 0); } public TerminalNode DWARF() { return getToken(NpcDatasParser.DWARF, 0); } public TerminalNode MERCHANT() { return getToken(NpcDatasParser.MERCHANT, 0); } public TerminalNode ELF() { return getToken(NpcDatasParser.ELF, 0); } public TerminalNode KAMAEL() { return getToken(NpcDatasParser.KAMAEL, 0); } public TerminalNode ORC() { return getToken(NpcDatasParser.ORC, 0); } public TerminalNode MERCENARY() { return getToken(NpcDatasParser.MERCENARY, 0); } public TerminalNode CASTLE_GUARD() { return getToken(NpcDatasParser.CASTLE_GUARD, 0); } public TerminalNode HUMAN() { return getToken(NpcDatasParser.HUMAN, 0); } public TerminalNode BOSS() { return getToken(NpcDatasParser.BOSS, 0); } public TerminalNode ZZOLDAGU() { return getToken(NpcDatasParser.ZZOLDAGU, 0); } public TerminalNode WORLD_TRAP() { return getToken(NpcDatasParser.WORLD_TRAP, 0); } public TerminalNode MONRACE() { return getToken(NpcDatasParser.MONRACE, 0); } public TerminalNode GUARD() { return getToken(NpcDatasParser.GUARD, 0); } public TerminalNode TELEPORTER() { return getToken(NpcDatasParser.TELEPORTER, 0); } public TerminalNode WAREHOUSE_KEEPER() { return getToken(NpcDatasParser.WAREHOUSE_KEEPER, 0); } public TerminalNode DARKELF() { return getToken(NpcDatasParser.DARKELF, 0); } public TerminalNode SIEGE_WEAPON() { return getToken(NpcDatasParser.SIEGE_WEAPON, 0); } public TerminalNode FRIEND() { return getToken(NpcDatasParser.FRIEND, 0); } public RaceContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_race; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterRace(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitRace(this); } } public final RaceContext race() throws RecognitionException { RaceContext _localctx = new RaceContext(_ctx, getState()); enterRule(_localctx, 22, RULE_race); try { enterOuterAlt(_localctx, 1); { setState(411); match(T__11); setState(412); match(T__3); setState(483); _errHandler.sync(this); switch (_input.LA(1)) { case FAIRY: { setState(413); match(FAIRY); _localctx.value = RaceType.FAIRY; } break; case ANIMAL: { setState(415); match(ANIMAL); _localctx.value = RaceType.ANIMAL; } break; case HUMANOID: { setState(417); match(HUMANOID); _localctx.value = RaceType.HUMANOID; } break; case PLANT: { setState(419); match(PLANT); _localctx.value = RaceType.PLANT; } break; case UNDEAD: { setState(421); match(UNDEAD); _localctx.value = RaceType.UNDEAD; } break; case CONSTRUCT: { setState(423); match(CONSTRUCT); _localctx.value = RaceType.CONSTRUCT; } break; case BEAST: { setState(425); match(BEAST); _localctx.value = RaceType.BEAST; } break; case BUG: { setState(427); match(BUG); _localctx.value = RaceType.BUG; } break; case ELEMENTAL: { setState(429); match(ELEMENTAL); _localctx.value = RaceType.ELEMENTAL; } break; case DEMONIC: { setState(431); match(DEMONIC); _localctx.value = RaceType.DEMONIC; } break; case DRAGON: { setState(433); match(DRAGON); _localctx.value = RaceType.DRAGON; } break; case GIANT: { setState(435); match(GIANT); _localctx.value = RaceType.GIANT; } break; case DIVINE: { setState(437); match(DIVINE); _localctx.value = RaceType.DIVINE; } break; case ETC: { setState(439); match(ETC); _localctx.value = RaceType.ETC; } break; case SUMMON: { setState(441); match(SUMMON); _localctx.value = RaceType.SUMMON; } break; case PET: { setState(443); match(PET); _localctx.value = RaceType.PET; } break; case HOLYTHING: { setState(445); match(HOLYTHING); _localctx.value = RaceType.HOLYTHING; } break; case DWARF: { setState(447); match(DWARF); _localctx.value = RaceType.DWARF; } break; case MERCHANT: { setState(449); match(MERCHANT); _localctx.value = RaceType.MERCHANT; } break; case ELF: { setState(451); match(ELF); _localctx.value = RaceType.ELF; } break; case KAMAEL: { setState(453); match(KAMAEL); _localctx.value = RaceType.KAMAEL; } break; case ORC: { setState(455); match(ORC); _localctx.value = RaceType.ORC; } break; case MERCENARY: { setState(457); match(MERCENARY); _localctx.value = RaceType.MERCENARY; } break; case CASTLE_GUARD: { setState(459); match(CASTLE_GUARD); _localctx.value = RaceType.CASTLE_GUARD; } break; case HUMAN: { setState(461); match(HUMAN); _localctx.value = RaceType.HUMAN; } break; case BOSS: { setState(463); match(BOSS); _localctx.value = RaceType.BOSS; } break; case ZZOLDAGU: { setState(465); match(ZZOLDAGU); _localctx.value = RaceType.ZZOLDAGU; } break; case WORLD_TRAP: { setState(467); match(WORLD_TRAP); _localctx.value = RaceType.WORLD_TRAP; } break; case MONRACE: { setState(469); match(MONRACE); _localctx.value = RaceType.MONRACE; } break; case GUARD: { setState(471); match(GUARD); _localctx.value = RaceType.GUARD; } break; case TELEPORTER: { setState(473); match(TELEPORTER); _localctx.value = RaceType.TELEPORTER; } break; case WAREHOUSE_KEEPER: { setState(475); match(WAREHOUSE_KEEPER); _localctx.value = RaceType.WAREHOUSE_KEEPER; } break; case DARKELF: { setState(477); match(DARKELF); _localctx.value = RaceType.DARKELF; } break; case SIEGE_WEAPON: { setState(479); match(SIEGE_WEAPON); _localctx.value = RaceType.SIEGE_WEAPON; } break; case FRIEND: { setState(481); match(FRIEND); _localctx.value = RaceType.FRIEND; } break; default: throw new NoViableAltException(this); } } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class SexContext extends ParserRuleContext { public Sex value; public TerminalNode MALE() { return getToken(NpcDatasParser.MALE, 0); } public TerminalNode FEMALE() { return getToken(NpcDatasParser.FEMALE, 0); } public TerminalNode ETC() { return getToken(NpcDatasParser.ETC, 0); } public SexContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_sex; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterSex(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitSex(this); } } public final SexContext sex() throws RecognitionException { SexContext _localctx = new SexContext(_ctx, getState()); enterRule(_localctx, 24, RULE_sex); try { enterOuterAlt(_localctx, 1); { setState(485); match(T__12); setState(486); match(T__3); setState(493); _errHandler.sync(this); switch (_input.LA(1)) { case MALE: { setState(487); match(MALE); _localctx.value = Sex.MALE; } break; case FEMALE: { setState(489); match(FEMALE); _localctx.value = Sex.FEMALE; } break; case ETC: { setState(491); match(ETC); _localctx.value = Sex.ETC; } break; default: throw new NoViableAltException(this); } } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Skill_listContext extends ParserRuleContext { public Category_listContext category_list() { return getRuleContext(Category_listContext.class,0); } public Skill_listContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_skill_list; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterSkill_list(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitSkill_list(this); } } public final Skill_listContext skill_list() throws RecognitionException { Skill_listContext _localctx = new Skill_listContext(_ctx, getState()); enterRule(_localctx, 26, RULE_skill_list); try { enterOuterAlt(_localctx, 1); { setState(495); match(T__13); setState(496); match(T__3); setState(497); category_list(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Slot_chestContext extends ParserRuleContext { public Empty_name_objectContext empty_name_object() { return getRuleContext(Empty_name_objectContext.class,0); } public Name_objectContext name_object() { return getRuleContext(Name_objectContext.class,0); } public Slot_chestContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_slot_chest; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterSlot_chest(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitSlot_chest(this); } } public final Slot_chestContext slot_chest() throws RecognitionException { Slot_chestContext _localctx = new Slot_chestContext(_ctx, getState()); enterRule(_localctx, 28, RULE_slot_chest); try { enterOuterAlt(_localctx, 1); { setState(499); match(T__14); setState(500); match(T__3); setState(503); _errHandler.sync(this); switch ( getInterpreter().adaptivePredict(_input,5,_ctx) ) { case 1: { setState(501); empty_name_object(); } break; case 2: { setState(502); name_object(); } break; } } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Slot_rhandContext extends ParserRuleContext { public Empty_name_objectContext empty_name_object() { return getRuleContext(Empty_name_objectContext.class,0); } public Name_objectContext name_object() { return getRuleContext(Name_objectContext.class,0); } public Slot_rhandContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_slot_rhand; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterSlot_rhand(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitSlot_rhand(this); } } public final Slot_rhandContext slot_rhand() throws RecognitionException { Slot_rhandContext _localctx = new Slot_rhandContext(_ctx, getState()); enterRule(_localctx, 30, RULE_slot_rhand); try { enterOuterAlt(_localctx, 1); { setState(505); match(T__15); setState(506); match(T__3); setState(509); _errHandler.sync(this); switch ( getInterpreter().adaptivePredict(_input,6,_ctx) ) { case 1: { setState(507); empty_name_object(); } break; case 2: { setState(508); name_object(); } break; } } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Slot_lhandContext extends ParserRuleContext { public Empty_name_objectContext empty_name_object() { return getRuleContext(Empty_name_objectContext.class,0); } public Name_objectContext name_object() { return getRuleContext(Name_objectContext.class,0); } public Slot_lhandContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_slot_lhand; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterSlot_lhand(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitSlot_lhand(this); } } public final Slot_lhandContext slot_lhand() throws RecognitionException { Slot_lhandContext _localctx = new Slot_lhandContext(_ctx, getState()); enterRule(_localctx, 32, RULE_slot_lhand); try { enterOuterAlt(_localctx, 1); { setState(511); match(T__16); setState(512); match(T__3); setState(515); _errHandler.sync(this); switch ( getInterpreter().adaptivePredict(_input,7,_ctx) ) { case 1: { setState(513); empty_name_object(); } break; case 2: { setState(514); name_object(); } break; } } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Empty_name_objectContext extends ParserRuleContext { public Empty_name_objectContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_empty_name_object; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterEmpty_name_object(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitEmpty_name_object(this); } } public final Empty_name_objectContext empty_name_object() throws RecognitionException { Empty_name_objectContext _localctx = new Empty_name_objectContext(_ctx, getState()); enterRule(_localctx, 34, RULE_empty_name_object); try { enterOuterAlt(_localctx, 1); { setState(517); match(T__17); setState(518); match(T__18); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Collision_radiusContext extends ParserRuleContext { public Double_listContext double_list() { return getRuleContext(Double_listContext.class,0); } public Collision_radiusContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_collision_radius; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterCollision_radius(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitCollision_radius(this); } } public final Collision_radiusContext collision_radius() throws RecognitionException { Collision_radiusContext _localctx = new Collision_radiusContext(_ctx, getState()); enterRule(_localctx, 36, RULE_collision_radius); try { enterOuterAlt(_localctx, 1); { setState(520); match(T__19); setState(521); match(T__3); setState(522); double_list(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Collision_heightContext extends ParserRuleContext { public Double_listContext double_list() { return getRuleContext(Double_listContext.class,0); } public Collision_heightContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_collision_height; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterCollision_height(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitCollision_height(this); } } public final Collision_heightContext collision_height() throws RecognitionException { Collision_heightContext _localctx = new Collision_heightContext(_ctx, getState()); enterRule(_localctx, 38, RULE_collision_height); try { enterOuterAlt(_localctx, 1); { setState(524); match(T__20); setState(525); match(T__3); setState(526); double_list(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Hit_time_factorContext extends ParserRuleContext { public Double_objectContext double_object() { return getRuleContext(Double_objectContext.class,0); } public Hit_time_factorContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_hit_time_factor; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterHit_time_factor(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitHit_time_factor(this); } } public final Hit_time_factorContext hit_time_factor() throws RecognitionException { Hit_time_factorContext _localctx = new Hit_time_factorContext(_ctx, getState()); enterRule(_localctx, 40, RULE_hit_time_factor); try { enterOuterAlt(_localctx, 1); { setState(528); match(T__21); setState(529); match(T__3); setState(530); double_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Hit_time_factor_skillContext extends ParserRuleContext { public Int_objectContext int_object() { return getRuleContext(Int_objectContext.class,0); } public Hit_time_factor_skillContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_hit_time_factor_skill; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterHit_time_factor_skill(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitHit_time_factor_skill(this); } } public final Hit_time_factor_skillContext hit_time_factor_skill() throws RecognitionException { Hit_time_factor_skillContext _localctx = new Hit_time_factor_skillContext(_ctx, getState()); enterRule(_localctx, 42, RULE_hit_time_factor_skill); try { enterOuterAlt(_localctx, 1); { setState(532); match(T__22); setState(533); match(T__3); setState(534); int_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Ground_highContext extends ParserRuleContext { public Double_listContext double_list() { return getRuleContext(Double_listContext.class,0); } public Ground_highContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_ground_high; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterGround_high(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitGround_high(this); } } public final Ground_highContext ground_high() throws RecognitionException { Ground_highContext _localctx = new Ground_highContext(_ctx, getState()); enterRule(_localctx, 44, RULE_ground_high); try { enterOuterAlt(_localctx, 1); { setState(536); match(T__23); setState(537); match(T__3); setState(538); double_list(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Ground_lowContext extends ParserRuleContext { public Double_listContext double_list() { return getRuleContext(Double_listContext.class,0); } public Ground_lowContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_ground_low; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterGround_low(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitGround_low(this); } } public final Ground_lowContext ground_low() throws RecognitionException { Ground_lowContext _localctx = new Ground_lowContext(_ctx, getState()); enterRule(_localctx, 46, RULE_ground_low); try { enterOuterAlt(_localctx, 1); { setState(540); match(T__24); setState(541); match(T__3); setState(542); double_list(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class StrContext extends ParserRuleContext { public Int_objectContext int_object() { return getRuleContext(Int_objectContext.class,0); } public StrContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_str; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterStr(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitStr(this); } } public final StrContext str() throws RecognitionException { StrContext _localctx = new StrContext(_ctx, getState()); enterRule(_localctx, 48, RULE_str); try { enterOuterAlt(_localctx, 1); { setState(544); match(T__25); setState(545); match(T__3); setState(546); int_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Int_Context extends ParserRuleContext { public Int_objectContext int_object() { return getRuleContext(Int_objectContext.class,0); } public Int_Context(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_int_; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterInt_(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitInt_(this); } } public final Int_Context int_() throws RecognitionException { Int_Context _localctx = new Int_Context(_ctx, getState()); enterRule(_localctx, 50, RULE_int_); try { enterOuterAlt(_localctx, 1); { setState(548); match(T__26); setState(549); match(T__3); setState(550); int_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class DexContext extends ParserRuleContext { public Int_objectContext int_object() { return getRuleContext(Int_objectContext.class,0); } public DexContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_dex; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterDex(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitDex(this); } } public final DexContext dex() throws RecognitionException { DexContext _localctx = new DexContext(_ctx, getState()); enterRule(_localctx, 52, RULE_dex); try { enterOuterAlt(_localctx, 1); { setState(552); match(T__27); setState(553); match(T__3); setState(554); int_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class WitContext extends ParserRuleContext { public Int_objectContext int_object() { return getRuleContext(Int_objectContext.class,0); } public WitContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_wit; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterWit(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitWit(this); } } public final WitContext wit() throws RecognitionException { WitContext _localctx = new WitContext(_ctx, getState()); enterRule(_localctx, 54, RULE_wit); try { enterOuterAlt(_localctx, 1); { setState(556); match(T__28); setState(557); match(T__3); setState(558); int_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class ConContext extends ParserRuleContext { public Int_objectContext int_object() { return getRuleContext(Int_objectContext.class,0); } public ConContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_con; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterCon(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitCon(this); } } public final ConContext con() throws RecognitionException { ConContext _localctx = new ConContext(_ctx, getState()); enterRule(_localctx, 56, RULE_con); try { enterOuterAlt(_localctx, 1); { setState(560); match(T__29); setState(561); match(T__3); setState(562); int_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class MenContext extends ParserRuleContext { public Int_objectContext int_object() { return getRuleContext(Int_objectContext.class,0); } public MenContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_men; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterMen(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitMen(this); } } public final MenContext men() throws RecognitionException { MenContext _localctx = new MenContext(_ctx, getState()); enterRule(_localctx, 58, RULE_men); try { enterOuterAlt(_localctx, 1); { setState(564); match(T__30); setState(565); match(T__3); setState(566); int_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Org_hpContext extends ParserRuleContext { public Double_objectContext double_object() { return getRuleContext(Double_objectContext.class,0); } public Org_hpContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_org_hp; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterOrg_hp(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitOrg_hp(this); } } public final Org_hpContext org_hp() throws RecognitionException { Org_hpContext _localctx = new Org_hpContext(_ctx, getState()); enterRule(_localctx, 60, RULE_org_hp); try { enterOuterAlt(_localctx, 1); { setState(568); match(T__31); setState(569); match(T__3); setState(570); double_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Org_hp_regenContext extends ParserRuleContext { public Double_objectContext double_object() { return getRuleContext(Double_objectContext.class,0); } public Org_hp_regenContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_org_hp_regen; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterOrg_hp_regen(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitOrg_hp_regen(this); } } public final Org_hp_regenContext org_hp_regen() throws RecognitionException { Org_hp_regenContext _localctx = new Org_hp_regenContext(_ctx, getState()); enterRule(_localctx, 62, RULE_org_hp_regen); try { enterOuterAlt(_localctx, 1); { setState(572); match(T__32); setState(573); match(T__3); setState(574); double_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Org_mpContext extends ParserRuleContext { public Double_objectContext double_object() { return getRuleContext(Double_objectContext.class,0); } public Org_mpContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_org_mp; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterOrg_mp(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitOrg_mp(this); } } public final Org_mpContext org_mp() throws RecognitionException { Org_mpContext _localctx = new Org_mpContext(_ctx, getState()); enterRule(_localctx, 64, RULE_org_mp); try { enterOuterAlt(_localctx, 1); { setState(576); match(T__33); setState(577); match(T__3); setState(578); double_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Org_mp_regenContext extends ParserRuleContext { public Double_objectContext double_object() { return getRuleContext(Double_objectContext.class,0); } public Org_mp_regenContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_org_mp_regen; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterOrg_mp_regen(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitOrg_mp_regen(this); } } public final Org_mp_regenContext org_mp_regen() throws RecognitionException { Org_mp_regenContext _localctx = new Org_mp_regenContext(_ctx, getState()); enterRule(_localctx, 66, RULE_org_mp_regen); try { enterOuterAlt(_localctx, 1); { setState(580); match(T__34); setState(581); match(T__3); setState(582); double_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Base_attack_typeContext extends ParserRuleContext { public WeaponType value; public TerminalNode SWORD() { return getToken(NpcDatasParser.SWORD, 0); } public TerminalNode BLUNT() { return getToken(NpcDatasParser.BLUNT, 0); } public TerminalNode BOW() { return getToken(NpcDatasParser.BOW, 0); } public TerminalNode DAGGER() { return getToken(NpcDatasParser.DAGGER, 0); } public TerminalNode FIST() { return getToken(NpcDatasParser.FIST, 0); } public TerminalNode POLE() { return getToken(NpcDatasParser.POLE, 0); } public TerminalNode DUAL() { return getToken(NpcDatasParser.DUAL, 0); } public TerminalNode DUALFIST() { return getToken(NpcDatasParser.DUALFIST, 0); } public Base_attack_typeContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_base_attack_type; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterBase_attack_type(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitBase_attack_type(this); } } public final Base_attack_typeContext base_attack_type() throws RecognitionException { Base_attack_typeContext _localctx = new Base_attack_typeContext(_ctx, getState()); enterRule(_localctx, 68, RULE_base_attack_type); try { enterOuterAlt(_localctx, 1); { setState(584); match(T__35); setState(585); match(T__3); setState(602); _errHandler.sync(this); switch (_input.LA(1)) { case SWORD: { setState(586); match(SWORD); _localctx.value = WeaponType.SWORD; } break; case BLUNT: { setState(588); match(BLUNT); _localctx.value = WeaponType.BLUNT; } break; case BOW: { setState(590); match(BOW); _localctx.value = WeaponType.BOW; } break; case DAGGER: { setState(592); match(DAGGER); _localctx.value = WeaponType.DAGGER; } break; case FIST: { setState(594); match(FIST); _localctx.value = WeaponType.FIST; } break; case POLE: { setState(596); match(POLE); _localctx.value = WeaponType.POLE; } break; case DUAL: { setState(598); match(DUAL); _localctx.value = WeaponType.DUAL; } break; case DUALFIST: { setState(600); match(DUALFIST); _localctx.value = WeaponType.DUALFIST; } break; default: throw new NoViableAltException(this); } } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Base_attack_rangeContext extends ParserRuleContext { public Int_objectContext io; public Int_objectContext int_object() { return getRuleContext(Int_objectContext.class,0); } public Base_attack_rangeContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_base_attack_range; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterBase_attack_range(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitBase_attack_range(this); } } public final Base_attack_rangeContext base_attack_range() throws RecognitionException { Base_attack_rangeContext _localctx = new Base_attack_rangeContext(_ctx, getState()); enterRule(_localctx, 70, RULE_base_attack_range); try { enterOuterAlt(_localctx, 1); { setState(604); match(T__36); setState(605); match(T__3); setState(606); ((Base_attack_rangeContext)_localctx).io = int_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Base_damage_rangeContext extends ParserRuleContext { public Int_listContext il; public Int_listContext int_list() { return getRuleContext(Int_listContext.class,0); } public Base_damage_rangeContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_base_damage_range; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterBase_damage_range(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitBase_damage_range(this); } } public final Base_damage_rangeContext base_damage_range() throws RecognitionException { Base_damage_rangeContext _localctx = new Base_damage_rangeContext(_ctx, getState()); enterRule(_localctx, 72, RULE_base_damage_range); try { enterOuterAlt(_localctx, 1); { setState(608); match(T__37); setState(609); match(T__3); setState(610); ((Base_damage_rangeContext)_localctx).il = int_list(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Base_rand_damContext extends ParserRuleContext { public Int_objectContext io; public Int_objectContext int_object() { return getRuleContext(Int_objectContext.class,0); } public Base_rand_damContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_base_rand_dam; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterBase_rand_dam(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitBase_rand_dam(this); } } public final Base_rand_damContext base_rand_dam() throws RecognitionException { Base_rand_damContext _localctx = new Base_rand_damContext(_ctx, getState()); enterRule(_localctx, 74, RULE_base_rand_dam); try { enterOuterAlt(_localctx, 1); { setState(612); match(T__38); setState(613); match(T__3); setState(614); ((Base_rand_damContext)_localctx).io = int_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Base_physical_attackContext extends ParserRuleContext { public Double_objectContext d; public Double_objectContext double_object() { return getRuleContext(Double_objectContext.class,0); } public Base_physical_attackContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_base_physical_attack; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterBase_physical_attack(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitBase_physical_attack(this); } } public final Base_physical_attackContext base_physical_attack() throws RecognitionException { Base_physical_attackContext _localctx = new Base_physical_attackContext(_ctx, getState()); enterRule(_localctx, 76, RULE_base_physical_attack); try { enterOuterAlt(_localctx, 1); { setState(616); match(T__39); setState(617); match(T__3); setState(618); ((Base_physical_attackContext)_localctx).d = double_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Base_criticalContext extends ParserRuleContext { public Double_objectContext d; public Double_objectContext double_object() { return getRuleContext(Double_objectContext.class,0); } public Base_criticalContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_base_critical; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterBase_critical(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitBase_critical(this); } } public final Base_criticalContext base_critical() throws RecognitionException { Base_criticalContext _localctx = new Base_criticalContext(_ctx, getState()); enterRule(_localctx, 78, RULE_base_critical); try { enterOuterAlt(_localctx, 1); { setState(620); match(T__40); setState(621); match(T__3); setState(622); ((Base_criticalContext)_localctx).d = double_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Physical_hit_modifyContext extends ParserRuleContext { public Double_objectContext d; public Double_objectContext double_object() { return getRuleContext(Double_objectContext.class,0); } public Physical_hit_modifyContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_physical_hit_modify; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterPhysical_hit_modify(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitPhysical_hit_modify(this); } } public final Physical_hit_modifyContext physical_hit_modify() throws RecognitionException { Physical_hit_modifyContext _localctx = new Physical_hit_modifyContext(_ctx, getState()); enterRule(_localctx, 80, RULE_physical_hit_modify); try { enterOuterAlt(_localctx, 1); { setState(624); match(T__41); setState(625); match(T__3); setState(626); ((Physical_hit_modifyContext)_localctx).d = double_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Base_attack_speedContext extends ParserRuleContext { public Double_objectContext doBas; public Double_objectContext double_object() { return getRuleContext(Double_objectContext.class,0); } public Base_attack_speedContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_base_attack_speed; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterBase_attack_speed(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitBase_attack_speed(this); } } public final Base_attack_speedContext base_attack_speed() throws RecognitionException { Base_attack_speedContext _localctx = new Base_attack_speedContext(_ctx, getState()); enterRule(_localctx, 82, RULE_base_attack_speed); try { enterOuterAlt(_localctx, 1); { setState(628); match(T__42); setState(629); match(T__3); setState(630); ((Base_attack_speedContext)_localctx).doBas = double_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Base_reuse_delayContext extends ParserRuleContext { public Int_objectContext io; public Int_objectContext int_object() { return getRuleContext(Int_objectContext.class,0); } public Base_reuse_delayContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_base_reuse_delay; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterBase_reuse_delay(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitBase_reuse_delay(this); } } public final Base_reuse_delayContext base_reuse_delay() throws RecognitionException { Base_reuse_delayContext _localctx = new Base_reuse_delayContext(_ctx, getState()); enterRule(_localctx, 84, RULE_base_reuse_delay); try { enterOuterAlt(_localctx, 1); { setState(632); match(T__43); setState(633); match(T__3); setState(634); ((Base_reuse_delayContext)_localctx).io = int_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Base_magic_attackContext extends ParserRuleContext { public Double_objectContext d; public Double_objectContext double_object() { return getRuleContext(Double_objectContext.class,0); } public Base_magic_attackContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_base_magic_attack; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterBase_magic_attack(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitBase_magic_attack(this); } } public final Base_magic_attackContext base_magic_attack() throws RecognitionException { Base_magic_attackContext _localctx = new Base_magic_attackContext(_ctx, getState()); enterRule(_localctx, 86, RULE_base_magic_attack); try { enterOuterAlt(_localctx, 1); { setState(636); match(T__44); setState(637); match(T__3); setState(638); ((Base_magic_attackContext)_localctx).d = double_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Base_defendContext extends ParserRuleContext { public Double_objectContext d; public Double_objectContext double_object() { return getRuleContext(Double_objectContext.class,0); } public Base_defendContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_base_defend; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterBase_defend(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitBase_defend(this); } } public final Base_defendContext base_defend() throws RecognitionException { Base_defendContext _localctx = new Base_defendContext(_ctx, getState()); enterRule(_localctx, 88, RULE_base_defend); try { enterOuterAlt(_localctx, 1); { setState(640); match(T__45); setState(641); match(T__3); setState(642); ((Base_defendContext)_localctx).d = double_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Base_magic_defendContext extends ParserRuleContext { public Double_objectContext d; public Double_objectContext double_object() { return getRuleContext(Double_objectContext.class,0); } public Base_magic_defendContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_base_magic_defend; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterBase_magic_defend(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitBase_magic_defend(this); } } public final Base_magic_defendContext base_magic_defend() throws RecognitionException { Base_magic_defendContext _localctx = new Base_magic_defendContext(_ctx, getState()); enterRule(_localctx, 90, RULE_base_magic_defend); try { enterOuterAlt(_localctx, 1); { setState(644); match(T__46); setState(645); match(T__3); setState(646); ((Base_magic_defendContext)_localctx).d = double_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Base_attribute_defendContext extends ParserRuleContext { public List<Double> value; public Double_listContext il; public Double_listContext double_list() { return getRuleContext(Double_listContext.class,0); } public Base_attribute_defendContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_base_attribute_defend; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterBase_attribute_defend(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitBase_attribute_defend(this); } } public final Base_attribute_defendContext base_attribute_defend() throws RecognitionException { Base_attribute_defendContext _localctx = new Base_attribute_defendContext(_ctx, getState()); enterRule(_localctx, 92, RULE_base_attribute_defend); try { enterOuterAlt(_localctx, 1); { setState(648); match(T__47); setState(649); match(T__3); setState(650); ((Base_attribute_defendContext)_localctx).il = double_list(); _localctx.value = ((Base_attribute_defendContext)_localctx).il.value; } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Physical_avoid_modifyContext extends ParserRuleContext { public Int_objectContext io; public Int_objectContext int_object() { return getRuleContext(Int_objectContext.class,0); } public Physical_avoid_modifyContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_physical_avoid_modify; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterPhysical_avoid_modify(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitPhysical_avoid_modify(this); } } public final Physical_avoid_modifyContext physical_avoid_modify() throws RecognitionException { Physical_avoid_modifyContext _localctx = new Physical_avoid_modifyContext(_ctx, getState()); enterRule(_localctx, 94, RULE_physical_avoid_modify); try { enterOuterAlt(_localctx, 1); { setState(653); match(T__48); setState(654); match(T__3); setState(655); ((Physical_avoid_modifyContext)_localctx).io = int_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Shield_defense_rateContext extends ParserRuleContext { public Int_objectContext io; public Int_objectContext int_object() { return getRuleContext(Int_objectContext.class,0); } public Shield_defense_rateContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_shield_defense_rate; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterShield_defense_rate(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitShield_defense_rate(this); } } public final Shield_defense_rateContext shield_defense_rate() throws RecognitionException { Shield_defense_rateContext _localctx = new Shield_defense_rateContext(_ctx, getState()); enterRule(_localctx, 96, RULE_shield_defense_rate); try { enterOuterAlt(_localctx, 1); { setState(657); match(T__49); setState(658); match(T__3); setState(659); ((Shield_defense_rateContext)_localctx).io = int_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Shield_defenseContext extends ParserRuleContext { public Double_objectContext d; public Double_objectContext double_object() { return getRuleContext(Double_objectContext.class,0); } public Shield_defenseContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_shield_defense; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterShield_defense(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitShield_defense(this); } } public final Shield_defenseContext shield_defense() throws RecognitionException { Shield_defenseContext _localctx = new Shield_defenseContext(_ctx, getState()); enterRule(_localctx, 98, RULE_shield_defense); try { enterOuterAlt(_localctx, 1); { setState(661); match(T__50); setState(662); match(T__3); setState(663); ((Shield_defenseContext)_localctx).d = double_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Safe_heightContext extends ParserRuleContext { public Int_objectContext io; public Int_objectContext int_object() { return getRuleContext(Int_objectContext.class,0); } public Safe_heightContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_safe_height; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterSafe_height(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitSafe_height(this); } } public final Safe_heightContext safe_height() throws RecognitionException { Safe_heightContext _localctx = new Safe_heightContext(_ctx, getState()); enterRule(_localctx, 100, RULE_safe_height); try { enterOuterAlt(_localctx, 1); { setState(665); match(T__51); setState(666); match(T__3); setState(667); ((Safe_heightContext)_localctx).io = int_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Soulshot_countContext extends ParserRuleContext { public Int_objectContext io; public Int_objectContext int_object() { return getRuleContext(Int_objectContext.class,0); } public Soulshot_countContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_soulshot_count; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterSoulshot_count(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitSoulshot_count(this); } } public final Soulshot_countContext soulshot_count() throws RecognitionException { Soulshot_countContext _localctx = new Soulshot_countContext(_ctx, getState()); enterRule(_localctx, 102, RULE_soulshot_count); try { enterOuterAlt(_localctx, 1); { setState(669); match(T__52); setState(670); match(T__3); setState(671); ((Soulshot_countContext)_localctx).io = int_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Spiritshot_countContext extends ParserRuleContext { public Int_objectContext io; public Int_objectContext int_object() { return getRuleContext(Int_objectContext.class,0); } public Spiritshot_countContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_spiritshot_count; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterSpiritshot_count(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitSpiritshot_count(this); } } public final Spiritshot_countContext spiritshot_count() throws RecognitionException { Spiritshot_countContext _localctx = new Spiritshot_countContext(_ctx, getState()); enterRule(_localctx, 104, RULE_spiritshot_count); try { enterOuterAlt(_localctx, 1); { setState(673); match(T__53); setState(674); match(T__3); setState(675); ((Spiritshot_countContext)_localctx).io = int_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class ClanContext extends ParserRuleContext { public Int_objectContext int_object() { return getRuleContext(Int_objectContext.class,0); } public Category_listContext category_list() { return getRuleContext(Category_listContext.class,0); } public ClanContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_clan; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterClan(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitClan(this); } } public final ClanContext clan() throws RecognitionException { ClanContext _localctx = new ClanContext(_ctx, getState()); enterRule(_localctx, 106, RULE_clan); try { enterOuterAlt(_localctx, 1); { setState(677); match(T__54); setState(678); match(T__3); setState(684); _errHandler.sync(this); switch ( getInterpreter().adaptivePredict(_input,9,_ctx) ) { case 1: { setState(679); match(T__4); setState(680); int_object(); setState(681); match(T__5); } break; case 2: { setState(683); category_list(); } break; } } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Ignore_clan_listContext extends ParserRuleContext { public Category_listContext category_list() { return getRuleContext(Category_listContext.class,0); } public Ignore_clan_listContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_ignore_clan_list; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterIgnore_clan_list(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitIgnore_clan_list(this); } } public final Ignore_clan_listContext ignore_clan_list() throws RecognitionException { Ignore_clan_listContext _localctx = new Ignore_clan_listContext(_ctx, getState()); enterRule(_localctx, 108, RULE_ignore_clan_list); try { enterOuterAlt(_localctx, 1); { setState(686); match(T__55); setState(687); match(T__3); setState(688); category_list(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Clan_help_rangeContext extends ParserRuleContext { public Int_objectContext io; public Int_objectContext int_object() { return getRuleContext(Int_objectContext.class,0); } public Clan_help_rangeContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_clan_help_range; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterClan_help_range(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitClan_help_range(this); } } public final Clan_help_rangeContext clan_help_range() throws RecognitionException { Clan_help_rangeContext _localctx = new Clan_help_rangeContext(_ctx, getState()); enterRule(_localctx, 110, RULE_clan_help_range); try { enterOuterAlt(_localctx, 1); { setState(690); match(T__56); setState(691); match(T__3); setState(692); ((Clan_help_rangeContext)_localctx).io = int_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class UndyingContext extends ParserRuleContext { public Bool_objectContext bo; public Bool_objectContext bool_object() { return getRuleContext(Bool_objectContext.class,0); } public UndyingContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_undying; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterUndying(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitUndying(this); } } public final UndyingContext undying() throws RecognitionException { UndyingContext _localctx = new UndyingContext(_ctx, getState()); enterRule(_localctx, 112, RULE_undying); try { enterOuterAlt(_localctx, 1); { setState(694); match(T__57); setState(695); match(T__3); setState(696); ((UndyingContext)_localctx).bo = bool_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Can_be_attackedContext extends ParserRuleContext { public Bool_objectContext bo; public Bool_objectContext bool_object() { return getRuleContext(Bool_objectContext.class,0); } public Can_be_attackedContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_can_be_attacked; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterCan_be_attacked(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitCan_be_attacked(this); } } public final Can_be_attackedContext can_be_attacked() throws RecognitionException { Can_be_attackedContext _localctx = new Can_be_attackedContext(_ctx, getState()); enterRule(_localctx, 114, RULE_can_be_attacked); try { enterOuterAlt(_localctx, 1); { setState(698); match(T__58); setState(699); match(T__3); setState(700); ((Can_be_attackedContext)_localctx).bo = bool_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Corpse_timeContext extends ParserRuleContext { public Int_objectContext io; public Int_objectContext int_object() { return getRuleContext(Int_objectContext.class,0); } public Corpse_timeContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_corpse_time; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterCorpse_time(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitCorpse_time(this); } } public final Corpse_timeContext corpse_time() throws RecognitionException { Corpse_timeContext _localctx = new Corpse_timeContext(_ctx, getState()); enterRule(_localctx, 116, RULE_corpse_time); try { enterOuterAlt(_localctx, 1); { setState(702); match(T__59); setState(703); match(T__3); setState(704); ((Corpse_timeContext)_localctx).io = int_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class No_sleep_modeContext extends ParserRuleContext { public Bool_objectContext bo; public Bool_objectContext bool_object() { return getRuleContext(Bool_objectContext.class,0); } public No_sleep_modeContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_no_sleep_mode; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterNo_sleep_mode(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitNo_sleep_mode(this); } } public final No_sleep_modeContext no_sleep_mode() throws RecognitionException { No_sleep_modeContext _localctx = new No_sleep_modeContext(_ctx, getState()); enterRule(_localctx, 118, RULE_no_sleep_mode); try { enterOuterAlt(_localctx, 1); { setState(706); match(T__60); setState(707); match(T__3); setState(708); ((No_sleep_modeContext)_localctx).bo = bool_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Agro_rangeContext extends ParserRuleContext { public Int_objectContext io; public Int_objectContext int_object() { return getRuleContext(Int_objectContext.class,0); } public Agro_rangeContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_agro_range; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterAgro_range(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitAgro_range(this); } } public final Agro_rangeContext agro_range() throws RecognitionException { Agro_rangeContext _localctx = new Agro_rangeContext(_ctx, getState()); enterRule(_localctx, 120, RULE_agro_range); try { enterOuterAlt(_localctx, 1); { setState(710); match(T__61); setState(711); match(T__3); setState(712); ((Agro_rangeContext)_localctx).io = int_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Passable_doorContext extends ParserRuleContext { public Int_objectContext io; public Int_objectContext int_object() { return getRuleContext(Int_objectContext.class,0); } public Passable_doorContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_passable_door; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterPassable_door(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitPassable_door(this); } } public final Passable_doorContext passable_door() throws RecognitionException { Passable_doorContext _localctx = new Passable_doorContext(_ctx, getState()); enterRule(_localctx, 122, RULE_passable_door); try { enterOuterAlt(_localctx, 1); { setState(714); match(T__62); setState(715); match(T__3); setState(716); ((Passable_doorContext)_localctx).io = int_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Can_moveContext extends ParserRuleContext { public Bool_objectContext bo; public Bool_objectContext bool_object() { return getRuleContext(Bool_objectContext.class,0); } public Can_moveContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_can_move; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterCan_move(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitCan_move(this); } } public final Can_moveContext can_move() throws RecognitionException { Can_moveContext _localctx = new Can_moveContext(_ctx, getState()); enterRule(_localctx, 124, RULE_can_move); try { enterOuterAlt(_localctx, 1); { setState(718); match(T__63); setState(719); match(T__3); setState(720); ((Can_moveContext)_localctx).bo = bool_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class FlyingContext extends ParserRuleContext { public Bool_objectContext bo; public Bool_objectContext bool_object() { return getRuleContext(Bool_objectContext.class,0); } public FlyingContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_flying; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterFlying(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitFlying(this); } } public final FlyingContext flying() throws RecognitionException { FlyingContext _localctx = new FlyingContext(_ctx, getState()); enterRule(_localctx, 126, RULE_flying); try { enterOuterAlt(_localctx, 1); { setState(722); match(T__64); setState(723); match(T__3); setState(724); ((FlyingContext)_localctx).bo = bool_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Has_summonerContext extends ParserRuleContext { public Bool_objectContext bo; public Bool_objectContext bool_object() { return getRuleContext(Bool_objectContext.class,0); } public Has_summonerContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_has_summoner; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterHas_summoner(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitHas_summoner(this); } } public final Has_summonerContext has_summoner() throws RecognitionException { Has_summonerContext _localctx = new Has_summonerContext(_ctx, getState()); enterRule(_localctx, 128, RULE_has_summoner); try { enterOuterAlt(_localctx, 1); { setState(726); match(T__65); setState(727); match(T__3); setState(728); ((Has_summonerContext)_localctx).bo = bool_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class TargetableContext extends ParserRuleContext { public Bool_objectContext bo; public Bool_objectContext bool_object() { return getRuleContext(Bool_objectContext.class,0); } public TargetableContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_targetable; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterTargetable(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitTargetable(this); } } public final TargetableContext targetable() throws RecognitionException { TargetableContext _localctx = new TargetableContext(_ctx, getState()); enterRule(_localctx, 130, RULE_targetable); try { enterOuterAlt(_localctx, 1); { setState(730); match(T__66); setState(731); match(T__3); setState(732); ((TargetableContext)_localctx).bo = bool_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Show_name_tagContext extends ParserRuleContext { public Bool_objectContext bo; public Bool_objectContext bool_object() { return getRuleContext(Bool_objectContext.class,0); } public Show_name_tagContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_show_name_tag; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterShow_name_tag(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitShow_name_tag(this); } } public final Show_name_tagContext show_name_tag() throws RecognitionException { Show_name_tagContext _localctx = new Show_name_tagContext(_ctx, getState()); enterRule(_localctx, 132, RULE_show_name_tag); try { enterOuterAlt(_localctx, 1); { setState(734); match(T__67); setState(735); match(T__3); setState(736); ((Show_name_tagContext)_localctx).bo = bool_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Abnormal_resistContext extends ParserRuleContext { public Int_listContext int_list() { return getRuleContext(Int_listContext.class,0); } public Abnormal_resistContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_abnormal_resist; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterAbnormal_resist(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitAbnormal_resist(this); } } public final Abnormal_resistContext abnormal_resist() throws RecognitionException { Abnormal_resistContext _localctx = new Abnormal_resistContext(_ctx, getState()); enterRule(_localctx, 134, RULE_abnormal_resist); try { enterOuterAlt(_localctx, 1); { setState(738); match(T__68); setState(739); match(T__3); setState(740); int_list(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Is_death_penaltyContext extends ParserRuleContext { public Bool_objectContext bo; public Bool_objectContext bool_object() { return getRuleContext(Bool_objectContext.class,0); } public Is_death_penaltyContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_is_death_penalty; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterIs_death_penalty(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitIs_death_penalty(this); } } public final Is_death_penaltyContext is_death_penalty() throws RecognitionException { Is_death_penaltyContext _localctx = new Is_death_penaltyContext(_ctx, getState()); enterRule(_localctx, 136, RULE_is_death_penalty); try { enterOuterAlt(_localctx, 1); { setState(742); match(T__69); setState(743); match(T__3); setState(744); ((Is_death_penaltyContext)_localctx).bo = bool_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Npc_aiContext extends ParserRuleContext { public Name_objectContext no; public Name_objectContext name_object() { return getRuleContext(Name_objectContext.class,0); } public List<Ai_paramContext> ai_param() { return getRuleContexts(Ai_paramContext.class); } public Ai_paramContext ai_param(int i) { return getRuleContext(Ai_paramContext.class,i); } public Npc_aiContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_npc_ai; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterNpc_ai(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitNpc_ai(this); } } public final Npc_aiContext npc_ai() throws RecognitionException { Npc_aiContext _localctx = new Npc_aiContext(_ctx, getState()); enterRule(_localctx, 138, RULE_npc_ai); int _la; try { enterOuterAlt(_localctx, 1); { setState(746); match(T__70); setState(747); match(T__3); setState(748); match(T__4); setState(749); ((Npc_aiContext)_localctx).no = name_object(); { setState(755); _errHandler.sync(this); _la = _input.LA(1); while (_la==SEMICOLON) { { setState(753); _errHandler.sync(this); switch ( getInterpreter().adaptivePredict(_input,10,_ctx) ) { case 1: { setState(750); match(SEMICOLON); } break; case 2: { setState(751); match(SEMICOLON); setState(752); ai_param(); } break; } } setState(757); _errHandler.sync(this); _la = _input.LA(1); } } setState(758); match(T__5); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Ai_paramContext extends ParserRuleContext { public Name_objectContext no1; public Param_valueContext param_value() { return getRuleContext(Param_valueContext.class,0); } public Name_objectContext name_object() { return getRuleContext(Name_objectContext.class,0); } public Ai_paramContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_ai_param; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterAi_param(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitAi_param(this); } } public final Ai_paramContext ai_param() throws RecognitionException { Ai_paramContext _localctx = new Ai_paramContext(_ctx, getState()); enterRule(_localctx, 140, RULE_ai_param); try { enterOuterAlt(_localctx, 1); { setState(760); match(T__4); setState(761); ((Ai_paramContext)_localctx).no1 = name_object(); setState(762); match(T__3); setState(763); param_value(); setState(764); match(T__5); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Param_valueContext extends ParserRuleContext { public Int_objectContext int_object() { return getRuleContext(Int_objectContext.class,0); } public Double_objectContext double_object() { return getRuleContext(Double_objectContext.class,0); } public Category_objectContext category_object() { return getRuleContext(Category_objectContext.class,0); } public Npc_privatesContext npc_privates() { return getRuleContext(Npc_privatesContext.class,0); } public Fstring_objectContext fstring_object() { return getRuleContext(Fstring_objectContext.class,0); } public Identifier_objectContext identifier_object() { return getRuleContext(Identifier_objectContext.class,0); } public Param_valueContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_param_value; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterParam_value(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitParam_value(this); } } public final Param_valueContext param_value() throws RecognitionException { Param_valueContext _localctx = new Param_valueContext(_ctx, getState()); enterRule(_localctx, 142, RULE_param_value); try { setState(772); _errHandler.sync(this); switch ( getInterpreter().adaptivePredict(_input,12,_ctx) ) { case 1: enterOuterAlt(_localctx, 1); { setState(766); int_object(); } break; case 2: enterOuterAlt(_localctx, 2); { setState(767); double_object(); } break; case 3: enterOuterAlt(_localctx, 3); { setState(768); category_object(); } break; case 4: enterOuterAlt(_localctx, 4); { setState(769); npc_privates(); } break; case 5: enterOuterAlt(_localctx, 5); { setState(770); fstring_object(); } break; case 6: enterOuterAlt(_localctx, 6); { setState(771); identifier_object(); } break; } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Npc_privatesContext extends ParserRuleContext { public List<Identifier_objectContext> identifier_object() { return getRuleContexts(Identifier_objectContext.class); } public Identifier_objectContext identifier_object(int i) { return getRuleContext(Identifier_objectContext.class,i); } public Npc_privatesContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_npc_privates; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterNpc_privates(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitNpc_privates(this); } } public final Npc_privatesContext npc_privates() throws RecognitionException { Npc_privatesContext _localctx = new Npc_privatesContext(_ctx, getState()); enterRule(_localctx, 144, RULE_npc_privates); int _la; try { enterOuterAlt(_localctx, 1); { setState(774); match(T__17); setState(775); identifier_object(); setState(780); _errHandler.sync(this); _la = _input.LA(1); while (_la==SEMICOLON) { { { setState(776); match(SEMICOLON); setState(777); identifier_object(); } } setState(782); _errHandler.sync(this); _la = _input.LA(1); } setState(783); match(T__18); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Fstring_objectContext extends ParserRuleContext { public Int_objectContext io; public Int_objectContext int_object() { return getRuleContext(Int_objectContext.class,0); } public Fstring_objectContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_fstring_object; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterFstring_object(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitFstring_object(this); } } public final Fstring_objectContext fstring_object() throws RecognitionException { Fstring_objectContext _localctx = new Fstring_objectContext(_ctx, getState()); enterRule(_localctx, 146, RULE_fstring_object); try { enterOuterAlt(_localctx, 1); { setState(785); match(T__17); setState(786); ((Fstring_objectContext)_localctx).io = int_object(); setState(787); match(T__18); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Event_flagContext extends ParserRuleContext { public Int_objectContext int_object() { return getRuleContext(Int_objectContext.class,0); } public Event_flagContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_event_flag; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterEvent_flag(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitEvent_flag(this); } } public final Event_flagContext event_flag() throws RecognitionException { Event_flagContext _localctx = new Event_flagContext(_ctx, getState()); enterRule(_localctx, 148, RULE_event_flag); try { enterOuterAlt(_localctx, 1); { setState(789); match(T__71); setState(790); match(T__3); setState(791); match(T__4); setState(792); int_object(); setState(793); match(T__5); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class UnsowingContext extends ParserRuleContext { public Bool_objectContext bo; public Bool_objectContext bool_object() { return getRuleContext(Bool_objectContext.class,0); } public UnsowingContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_unsowing; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterUnsowing(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitUnsowing(this); } } public final UnsowingContext unsowing() throws RecognitionException { UnsowingContext _localctx = new UnsowingContext(_ctx, getState()); enterRule(_localctx, 150, RULE_unsowing); try { enterOuterAlt(_localctx, 1); { setState(795); match(T__72); setState(796); match(T__3); setState(797); ((UnsowingContext)_localctx).bo = bool_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Private_respawn_logContext extends ParserRuleContext { public Bool_objectContext bo; public Bool_objectContext bool_object() { return getRuleContext(Bool_objectContext.class,0); } public Private_respawn_logContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_private_respawn_log; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterPrivate_respawn_log(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitPrivate_respawn_log(this); } } public final Private_respawn_logContext private_respawn_log() throws RecognitionException { Private_respawn_logContext _localctx = new Private_respawn_logContext(_ctx, getState()); enterRule(_localctx, 152, RULE_private_respawn_log); try { enterOuterAlt(_localctx, 1); { setState(799); match(T__73); setState(800); match(T__3); setState(801); ((Private_respawn_logContext)_localctx).bo = bool_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Acquire_exp_rateContext extends ParserRuleContext { public Double_objectContext d; public Double_objectContext double_object() { return getRuleContext(Double_objectContext.class,0); } public Acquire_exp_rateContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_acquire_exp_rate; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterAcquire_exp_rate(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitAcquire_exp_rate(this); } } public final Acquire_exp_rateContext acquire_exp_rate() throws RecognitionException { Acquire_exp_rateContext _localctx = new Acquire_exp_rateContext(_ctx, getState()); enterRule(_localctx, 154, RULE_acquire_exp_rate); try { enterOuterAlt(_localctx, 1); { setState(803); match(T__74); setState(804); match(T__3); setState(805); ((Acquire_exp_rateContext)_localctx).d = double_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Acquire_spContext extends ParserRuleContext { public Double_objectContext d; public Double_objectContext double_object() { return getRuleContext(Double_objectContext.class,0); } public Acquire_spContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_acquire_sp; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterAcquire_sp(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitAcquire_sp(this); } } public final Acquire_spContext acquire_sp() throws RecognitionException { Acquire_spContext _localctx = new Acquire_spContext(_ctx, getState()); enterRule(_localctx, 156, RULE_acquire_sp); try { enterOuterAlt(_localctx, 1); { setState(807); match(T__75); setState(808); match(T__3); setState(809); ((Acquire_spContext)_localctx).d = double_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Acquire_rpContext extends ParserRuleContext { public Double_objectContext d; public Double_objectContext double_object() { return getRuleContext(Double_objectContext.class,0); } public Acquire_rpContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_acquire_rp; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterAcquire_rp(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitAcquire_rp(this); } } public final Acquire_rpContext acquire_rp() throws RecognitionException { Acquire_rpContext _localctx = new Acquire_rpContext(_ctx, getState()); enterRule(_localctx, 158, RULE_acquire_rp); try { enterOuterAlt(_localctx, 1); { setState(811); match(T__76); setState(812); match(T__3); setState(813); ((Acquire_rpContext)_localctx).d = double_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Corpse_make_listContext extends ParserRuleContext { public Make_item_listContext make_item_list() { return getRuleContext(Make_item_listContext.class,0); } public Corpse_make_listContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_corpse_make_list; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterCorpse_make_list(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitCorpse_make_list(this); } } public final Corpse_make_listContext corpse_make_list() throws RecognitionException { Corpse_make_listContext _localctx = new Corpse_make_listContext(_ctx, getState()); enterRule(_localctx, 160, RULE_corpse_make_list); try { enterOuterAlt(_localctx, 1); { setState(815); match(T__77); setState(816); match(T__3); setState(817); make_item_list(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Make_item_listContext extends ParserRuleContext { public List<Make_itemContext> make_item() { return getRuleContexts(Make_itemContext.class); } public Make_itemContext make_item(int i) { return getRuleContext(Make_itemContext.class,i); } public Make_item_listContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_make_item_list; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterMake_item_list(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitMake_item_list(this); } } public final Make_item_listContext make_item_list() throws RecognitionException { Make_item_listContext _localctx = new Make_item_listContext(_ctx, getState()); enterRule(_localctx, 162, RULE_make_item_list); int _la; try { setState(832); _errHandler.sync(this); switch ( getInterpreter().adaptivePredict(_input,15,_ctx) ) { case 1: enterOuterAlt(_localctx, 1); { setState(819); match(T__4); setState(820); match(T__5); } break; case 2: enterOuterAlt(_localctx, 2); { setState(821); match(T__4); setState(822); make_item(); setState(827); _errHandler.sync(this); _la = _input.LA(1); while (_la==SEMICOLON) { { { setState(823); match(SEMICOLON); setState(824); make_item(); } } setState(829); _errHandler.sync(this); _la = _input.LA(1); } setState(830); match(T__5); } break; } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Make_itemContext extends ParserRuleContext { public Int_objectContext min; public Int_objectContext max; public Double_objectContext chance; public Name_objectContext name_object() { return getRuleContext(Name_objectContext.class,0); } public List<Int_objectContext> int_object() { return getRuleContexts(Int_objectContext.class); } public Int_objectContext int_object(int i) { return getRuleContext(Int_objectContext.class,i); } public Double_objectContext double_object() { return getRuleContext(Double_objectContext.class,0); } public Make_itemContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_make_item; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterMake_item(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitMake_item(this); } } public final Make_itemContext make_item() throws RecognitionException { Make_itemContext _localctx = new Make_itemContext(_ctx, getState()); enterRule(_localctx, 164, RULE_make_item); try { enterOuterAlt(_localctx, 1); { setState(834); match(T__4); setState(835); name_object(); setState(836); match(SEMICOLON); setState(837); ((Make_itemContext)_localctx).min = int_object(); setState(838); match(SEMICOLON); setState(839); ((Make_itemContext)_localctx).max = int_object(); setState(840); match(SEMICOLON); setState(841); ((Make_itemContext)_localctx).chance = double_object(); setState(842); match(T__5); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Additional_make_listContext extends ParserRuleContext { public Make_item_listContext make_item_list() { return getRuleContext(Make_item_listContext.class,0); } public Additional_make_listContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_additional_make_list; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterAdditional_make_list(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitAdditional_make_list(this); } } public final Additional_make_listContext additional_make_list() throws RecognitionException { Additional_make_listContext _localctx = new Additional_make_listContext(_ctx, getState()); enterRule(_localctx, 166, RULE_additional_make_list); try { enterOuterAlt(_localctx, 1); { setState(844); match(T__78); setState(845); match(T__3); setState(846); make_item_list(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Additional_make_multi_listContext extends ParserRuleContext { public Make_group_listContext make_group_list() { return getRuleContext(Make_group_listContext.class,0); } public Additional_make_multi_listContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_additional_make_multi_list; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterAdditional_make_multi_list(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitAdditional_make_multi_list(this); } } public final Additional_make_multi_listContext additional_make_multi_list() throws RecognitionException { Additional_make_multi_listContext _localctx = new Additional_make_multi_listContext(_ctx, getState()); enterRule(_localctx, 168, RULE_additional_make_multi_list); try { enterOuterAlt(_localctx, 1); { setState(848); match(T__79); setState(849); match(T__3); setState(850); make_group_list(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Make_group_listContext extends ParserRuleContext { public Double_objectContext gc; public List<Make_item_listContext> make_item_list() { return getRuleContexts(Make_item_listContext.class); } public Make_item_listContext make_item_list(int i) { return getRuleContext(Make_item_listContext.class,i); } public List<Double_objectContext> double_object() { return getRuleContexts(Double_objectContext.class); } public Double_objectContext double_object(int i) { return getRuleContext(Double_objectContext.class,i); } public Make_group_listContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_make_group_list; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterMake_group_list(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitMake_group_list(this); } } public final Make_group_listContext make_group_list() throws RecognitionException { Make_group_listContext _localctx = new Make_group_listContext(_ctx, getState()); enterRule(_localctx, 170, RULE_make_group_list); int _la; try { setState(874); _errHandler.sync(this); switch ( getInterpreter().adaptivePredict(_input,17,_ctx) ) { case 1: enterOuterAlt(_localctx, 1); { setState(852); match(T__4); setState(853); match(T__5); } break; case 2: enterOuterAlt(_localctx, 2); { setState(854); match(T__4); setState(855); match(T__4); setState(856); make_item_list(); setState(857); match(SEMICOLON); setState(858); ((Make_group_listContext)_localctx).gc = double_object(); setState(859); match(T__5); setState(869); _errHandler.sync(this); _la = _input.LA(1); while (_la==SEMICOLON) { { { setState(860); match(SEMICOLON); setState(861); match(T__4); setState(862); make_item_list(); setState(863); match(SEMICOLON); setState(864); ((Make_group_listContext)_localctx).gc = double_object(); setState(865); match(T__5); } } setState(871); _errHandler.sync(this); _la = _input.LA(1); } setState(872); match(T__5); } break; } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Ex_item_drop_listContext extends ParserRuleContext { public Make_group_listContext make_group_list() { return getRuleContext(Make_group_listContext.class,0); } public Ex_item_drop_listContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_ex_item_drop_list; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterEx_item_drop_list(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitEx_item_drop_list(this); } } public final Ex_item_drop_listContext ex_item_drop_list() throws RecognitionException { Ex_item_drop_listContext _localctx = new Ex_item_drop_listContext(_ctx, getState()); enterRule(_localctx, 172, RULE_ex_item_drop_list); try { enterOuterAlt(_localctx, 1); { setState(876); match(T__80); setState(877); match(T__3); setState(878); make_group_list(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Vitality_item_drop_listContext extends ParserRuleContext { public Make_group_listContext make_group_list() { return getRuleContext(Make_group_listContext.class,0); } public Vitality_item_drop_listContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_vitality_item_drop_list; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterVitality_item_drop_list(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitVitality_item_drop_list(this); } } public final Vitality_item_drop_listContext vitality_item_drop_list() throws RecognitionException { Vitality_item_drop_listContext _localctx = new Vitality_item_drop_listContext(_ctx, getState()); enterRule(_localctx, 174, RULE_vitality_item_drop_list); try { enterOuterAlt(_localctx, 1); { setState(880); match(T__81); setState(881); match(T__3); setState(882); make_group_list(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Mp_rewardContext extends ParserRuleContext { public Double_objectContext rewardValue; public Double_objectContext rewardAffectValue; public Mp_reward_typeContext mp_reward_type() { return getRuleContext(Mp_reward_typeContext.class,0); } public Mp_reward_affect_typeContext mp_reward_affect_type() { return getRuleContext(Mp_reward_affect_typeContext.class,0); } public List<Double_objectContext> double_object() { return getRuleContexts(Double_objectContext.class); } public Double_objectContext double_object(int i) { return getRuleContext(Double_objectContext.class,i); } public Mp_rewardContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_mp_reward; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterMp_reward(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitMp_reward(this); } } public final Mp_rewardContext mp_reward() throws RecognitionException { Mp_rewardContext _localctx = new Mp_rewardContext(_ctx, getState()); enterRule(_localctx, 176, RULE_mp_reward); try { enterOuterAlt(_localctx, 1); { setState(884); match(T__82); setState(885); match(T__3); setState(886); match(T__4); setState(887); ((Mp_rewardContext)_localctx).rewardValue = double_object(); setState(888); match(SEMICOLON); setState(889); mp_reward_type(); setState(890); match(SEMICOLON); setState(891); ((Mp_rewardContext)_localctx).rewardAffectValue = double_object(); setState(892); match(SEMICOLON); setState(893); mp_reward_affect_type(); setState(894); match(T__5); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Mp_reward_typeContext extends ParserRuleContext { public MpRewardType value; public Mp_reward_typeContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_mp_reward_type; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterMp_reward_type(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitMp_reward_type(this); } } public final Mp_reward_typeContext mp_reward_type() throws RecognitionException { Mp_reward_typeContext _localctx = new Mp_reward_typeContext(_ctx, getState()); enterRule(_localctx, 178, RULE_mp_reward_type); try { enterOuterAlt(_localctx, 1); { setState(900); _errHandler.sync(this); switch (_input.LA(1)) { case T__83: { setState(896); match(T__83); _localctx.value = MpRewardType.PER; } break; case T__84: { setState(898); match(T__84); _localctx.value = MpRewardType.DIFF; } break; default: throw new NoViableAltException(this); } } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Mp_reward_affect_typeContext extends ParserRuleContext { public MpRewardAffectType value; public Mp_reward_affect_typeContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_mp_reward_affect_type; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterMp_reward_affect_type(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitMp_reward_affect_type(this); } } public final Mp_reward_affect_typeContext mp_reward_affect_type() throws RecognitionException { Mp_reward_affect_typeContext _localctx = new Mp_reward_affect_typeContext(_ctx, getState()); enterRule(_localctx, 180, RULE_mp_reward_affect_type); try { enterOuterAlt(_localctx, 1); { setState(906); _errHandler.sync(this); switch (_input.LA(1)) { case T__85: { setState(902); match(T__85); _localctx.value = MpRewardAffectType.SOLO; } break; case T__86: { setState(904); match(T__86); _localctx.value = MpRewardAffectType.PARTY; } break; default: throw new NoViableAltException(this); } } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Fake_class_idContext extends ParserRuleContext { public Int_objectContext io; public Int_objectContext int_object() { return getRuleContext(Int_objectContext.class,0); } public Fake_class_idContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_fake_class_id; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterFake_class_id(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitFake_class_id(this); } } public final Fake_class_idContext fake_class_id() throws RecognitionException { Fake_class_idContext _localctx = new Fake_class_idContext(_ctx, getState()); enterRule(_localctx, 182, RULE_fake_class_id); try { enterOuterAlt(_localctx, 1); { setState(908); match(T__87); setState(909); match(T__3); setState(910); ((Fake_class_idContext)_localctx).io = int_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Event_dropContext extends ParserRuleContext { public Int_objectContext int_object() { return getRuleContext(Int_objectContext.class,0); } public Event_dropContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_event_drop; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterEvent_drop(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitEvent_drop(this); } } public final Event_dropContext event_drop() throws RecognitionException { Event_dropContext _localctx = new Event_dropContext(_ctx, getState()); enterRule(_localctx, 184, RULE_event_drop); try { enterOuterAlt(_localctx, 1); { setState(912); match(T__88); setState(913); match(T__3); setState(914); int_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Ex_dropContext extends ParserRuleContext { public Int_listContext int_list() { return getRuleContext(Int_listContext.class,0); } public Ex_dropContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_ex_drop; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterEx_drop(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitEx_drop(this); } } public final Ex_dropContext ex_drop() throws RecognitionException { Ex_dropContext _localctx = new Ex_dropContext(_ctx, getState()); enterRule(_localctx, 186, RULE_ex_drop); try { enterOuterAlt(_localctx, 1); { setState(916); match(T__89); setState(917); match(T__3); setState(918); int_list(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Enable_move_after_talkContext extends ParserRuleContext { public Bool_objectContext bool_object() { return getRuleContext(Bool_objectContext.class,0); } public Enable_move_after_talkContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_enable_move_after_talk; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterEnable_move_after_talk(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitEnable_move_after_talk(this); } } public final Enable_move_after_talkContext enable_move_after_talk() throws RecognitionException { Enable_move_after_talkContext _localctx = new Enable_move_after_talkContext(_ctx, getState()); enterRule(_localctx, 188, RULE_enable_move_after_talk); try { enterOuterAlt(_localctx, 1); { setState(920); match(T__90); setState(921); match(T__3); setState(922); bool_object(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Broadcast_condContext extends ParserRuleContext { public Int_listContext int_list() { return getRuleContext(Int_listContext.class,0); } public Broadcast_condContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_broadcast_cond; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterBroadcast_cond(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitBroadcast_cond(this); } } public final Broadcast_condContext broadcast_cond() throws RecognitionException { Broadcast_condContext _localctx = new Broadcast_condContext(_ctx, getState()); enterRule(_localctx, 190, RULE_broadcast_cond); try { enterOuterAlt(_localctx, 1); { setState(924); match(T__91); setState(925); match(T__3); setState(926); int_list(); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Identifier_objectContext extends ParserRuleContext { public String value; public TerminalNode DAGGER() { return getToken(NpcDatasParser.DAGGER, 0); } public TerminalNode BOW() { return getToken(NpcDatasParser.BOW, 0); } public TerminalNode CROSSBOW() { return getToken(NpcDatasParser.CROSSBOW, 0); } public TerminalNode RAPIER() { return getToken(NpcDatasParser.RAPIER, 0); } public TerminalNode GLOVES() { return getToken(NpcDatasParser.GLOVES, 0); } public TerminalNode STEEL() { return getToken(NpcDatasParser.STEEL, 0); } public TerminalNode LEATHER() { return getToken(NpcDatasParser.LEATHER, 0); } public TerminalNode ORIHARUKON() { return getToken(NpcDatasParser.ORIHARUKON, 0); } public TerminalNode NAME() { return getToken(NpcDatasParser.NAME, 0); } public TerminalNode NONE() { return getToken(NpcDatasParser.NONE, 0); } public TerminalNode ORC() { return getToken(NpcDatasParser.ORC, 0); } public TerminalNode BOSS() { return getToken(NpcDatasParser.BOSS, 0); } public Identifier_objectContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_identifier_object; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterIdentifier_object(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitIdentifier_object(this); } } public final Identifier_objectContext identifier_object() throws RecognitionException { Identifier_objectContext _localctx = new Identifier_objectContext(_ctx, getState()); enterRule(_localctx, 192, RULE_identifier_object); int _la; try { enterOuterAlt(_localctx, 1); { setState(928); _la = _input.LA(1); if ( !(_la==T__16 || _la==T__29 || ((((_la - 108)) & ~0x3f) == 0 && ((1L << (_la - 108)) & ((1L << (NONE - 108)) | (1L << (ORC - 108)) | (1L << (BOSS - 108)) | (1L << (BOW - 108)) | (1L << (DAGGER - 108)) | (1L << (RAPIER - 108)) | (1L << (CROSSBOW - 108)))) != 0) || ((((_la - 183)) & ~0x3f) == 0 && ((1L << (_la - 183)) & ((1L << (GLOVES - 183)) | (1L << (STEEL - 183)) | (1L << (LEATHER - 183)) | (1L << (ORIHARUKON - 183)) | (1L << (NAME - 183)))) != 0)) ) { _errHandler.recoverInline(this); } else { if ( _input.LA(1)==Token.EOF ) matchedEOF = true; _errHandler.reportMatch(this); consume(); } } _ctx.stop = _input.LT(-1); _localctx.value = _input.getText(_localctx.start, _input.LT(-1)); } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Bool_objectContext extends ParserRuleContext { public boolean value; public TerminalNode BOOLEAN() { return getToken(NpcDatasParser.BOOLEAN, 0); } public Bool_objectContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_bool_object; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterBool_object(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitBool_object(this); } } public final Bool_objectContext bool_object() throws RecognitionException { Bool_objectContext _localctx = new Bool_objectContext(_ctx, getState()); enterRule(_localctx, 194, RULE_bool_object); try { enterOuterAlt(_localctx, 1); { setState(930); match(BOOLEAN); } _ctx.stop = _input.LT(-1); _localctx.value = _input.getText(_localctx.start, _input.LT(-1)).equals("1"); } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Byte_objectContext extends ParserRuleContext { public byte value; public TerminalNode BOOLEAN() { return getToken(NpcDatasParser.BOOLEAN, 0); } public TerminalNode INTEGER() { return getToken(NpcDatasParser.INTEGER, 0); } public Byte_objectContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_byte_object; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterByte_object(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitByte_object(this); } } public final Byte_objectContext byte_object() throws RecognitionException { Byte_objectContext _localctx = new Byte_objectContext(_ctx, getState()); enterRule(_localctx, 196, RULE_byte_object); int _la; try { enterOuterAlt(_localctx, 1); { setState(932); _la = _input.LA(1); if ( !(_la==BOOLEAN || _la==INTEGER) ) { _errHandler.recoverInline(this); } else { if ( _input.LA(1)==Token.EOF ) matchedEOF = true; _errHandler.reportMatch(this); consume(); } } _ctx.stop = _input.LT(-1); _localctx.value = Byte.valueOf(_input.getText(_localctx.start, _input.LT(-1))); } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Int_objectContext extends ParserRuleContext { public int value; public TerminalNode BOOLEAN() { return getToken(NpcDatasParser.BOOLEAN, 0); } public TerminalNode INTEGER() { return getToken(NpcDatasParser.INTEGER, 0); } public Int_objectContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_int_object; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterInt_object(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitInt_object(this); } } public final Int_objectContext int_object() throws RecognitionException { Int_objectContext _localctx = new Int_objectContext(_ctx, getState()); enterRule(_localctx, 198, RULE_int_object); int _la; try { enterOuterAlt(_localctx, 1); { setState(934); _la = _input.LA(1); if ( !(_la==BOOLEAN || _la==INTEGER) ) { _errHandler.recoverInline(this); } else { if ( _input.LA(1)==Token.EOF ) matchedEOF = true; _errHandler.reportMatch(this); consume(); } } _ctx.stop = _input.LT(-1); _localctx.value = Integer.valueOf(_input.getText(_localctx.start, _input.LT(-1))); } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Long_objectContext extends ParserRuleContext { public long value; public TerminalNode BOOLEAN() { return getToken(NpcDatasParser.BOOLEAN, 0); } public TerminalNode INTEGER() { return getToken(NpcDatasParser.INTEGER, 0); } public Long_objectContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_long_object; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterLong_object(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitLong_object(this); } } public final Long_objectContext long_object() throws RecognitionException { Long_objectContext _localctx = new Long_objectContext(_ctx, getState()); enterRule(_localctx, 200, RULE_long_object); int _la; try { enterOuterAlt(_localctx, 1); { setState(936); _la = _input.LA(1); if ( !(_la==BOOLEAN || _la==INTEGER) ) { _errHandler.recoverInline(this); } else { if ( _input.LA(1)==Token.EOF ) matchedEOF = true; _errHandler.reportMatch(this); consume(); } } _ctx.stop = _input.LT(-1); _localctx.value = Long.valueOf(_input.getText(_localctx.start, _input.LT(-1))); } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Double_objectContext extends ParserRuleContext { public double value; public TerminalNode BOOLEAN() { return getToken(NpcDatasParser.BOOLEAN, 0); } public TerminalNode INTEGER() { return getToken(NpcDatasParser.INTEGER, 0); } public TerminalNode DOUBLE() { return getToken(NpcDatasParser.DOUBLE, 0); } public Double_objectContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_double_object; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterDouble_object(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitDouble_object(this); } } public final Double_objectContext double_object() throws RecognitionException { Double_objectContext _localctx = new Double_objectContext(_ctx, getState()); enterRule(_localctx, 202, RULE_double_object); int _la; try { enterOuterAlt(_localctx, 1); { setState(938); _la = _input.LA(1); if ( !(((((_la - 98)) & ~0x3f) == 0 && ((1L << (_la - 98)) & ((1L << (BOOLEAN - 98)) | (1L << (INTEGER - 98)) | (1L << (DOUBLE - 98)))) != 0)) ) { _errHandler.recoverInline(this); } else { if ( _input.LA(1)==Token.EOF ) matchedEOF = true; _errHandler.reportMatch(this); consume(); } } _ctx.stop = _input.LT(-1); _localctx.value = Double.valueOf(_input.getText(_localctx.start, _input.LT(-1))); } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class String_objectContext extends ParserRuleContext { public String value; public TerminalNode BOOLEAN() { return getToken(NpcDatasParser.BOOLEAN, 0); } public TerminalNode INTEGER() { return getToken(NpcDatasParser.INTEGER, 0); } public TerminalNode DOUBLE() { return getToken(NpcDatasParser.DOUBLE, 0); } public String_objectContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_string_object; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterString_object(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitString_object(this); } } public final String_objectContext string_object() throws RecognitionException { String_objectContext _localctx = new String_objectContext(_ctx, getState()); enterRule(_localctx, 204, RULE_string_object); int _la; try { enterOuterAlt(_localctx, 1); { setState(940); _la = _input.LA(1); if ( !(((((_la - 98)) & ~0x3f) == 0 && ((1L << (_la - 98)) & ((1L << (BOOLEAN - 98)) | (1L << (INTEGER - 98)) | (1L << (DOUBLE - 98)))) != 0)) ) { _errHandler.recoverInline(this); } else { if ( _input.LA(1)==Token.EOF ) matchedEOF = true; _errHandler.reportMatch(this); consume(); } } _ctx.stop = _input.LT(-1); _localctx.value = _input.getText(_localctx.start, _input.LT(-1)); } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Name_objectContext extends ParserRuleContext { public String value; public Identifier_objectContext io; public Identifier_objectContext identifier_object() { return getRuleContext(Identifier_objectContext.class,0); } public Name_objectContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_name_object; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterName_object(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitName_object(this); } } public final Name_objectContext name_object() throws RecognitionException { Name_objectContext _localctx = new Name_objectContext(_ctx, getState()); enterRule(_localctx, 206, RULE_name_object); try { enterOuterAlt(_localctx, 1); { setState(942); match(T__17); setState(943); ((Name_objectContext)_localctx).io = identifier_object(); setState(944); match(T__18); _localctx.value = ((Name_objectContext)_localctx).io.value; } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Category_objectContext extends ParserRuleContext { public TerminalNode CATEGORY() { return getToken(NpcDatasParser.CATEGORY, 0); } public Category_objectContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_category_object; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterCategory_object(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitCategory_object(this); } } public final Category_objectContext category_object() throws RecognitionException { Category_objectContext _localctx = new Category_objectContext(_ctx, getState()); enterRule(_localctx, 208, RULE_category_object); try { enterOuterAlt(_localctx, 1); { setState(947); match(CATEGORY); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Vector3D_objectContext extends ParserRuleContext { public Vector3D value; public Int_objectContext x; public Int_objectContext y; public Int_objectContext z; public List<TerminalNode> SEMICOLON() { return getTokens(NpcDatasParser.SEMICOLON); } public TerminalNode SEMICOLON(int i) { return getToken(NpcDatasParser.SEMICOLON, i); } public List<Int_objectContext> int_object() { return getRuleContexts(Int_objectContext.class); } public Int_objectContext int_object(int i) { return getRuleContext(Int_objectContext.class,i); } public Vector3D_objectContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_vector3D_object; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterVector3D_object(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitVector3D_object(this); } } public final Vector3D_objectContext vector3D_object() throws RecognitionException { Vector3D_objectContext _localctx = new Vector3D_objectContext(_ctx, getState()); enterRule(_localctx, 210, RULE_vector3D_object); try { enterOuterAlt(_localctx, 1); { setState(949); match(T__4); setState(950); ((Vector3D_objectContext)_localctx).x = int_object(); setState(951); match(SEMICOLON); setState(952); ((Vector3D_objectContext)_localctx).y = int_object(); setState(953); match(SEMICOLON); setState(954); ((Vector3D_objectContext)_localctx).z = int_object(); setState(955); match(T__5); } _ctx.stop = _input.LT(-1); _localctx.value = new Vector3D(((Vector3D_objectContext)_localctx).x.value, ((Vector3D_objectContext)_localctx).y.value, ((Vector3D_objectContext)_localctx).z.value); } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Empty_listContext extends ParserRuleContext { public List<String> value; public Empty_listContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_empty_list; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterEmpty_list(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitEmpty_list(this); } } public final Empty_listContext empty_list() throws RecognitionException { Empty_listContext _localctx = new Empty_listContext(_ctx, getState()); enterRule(_localctx, 212, RULE_empty_list); _localctx.value = new ArrayList<>(); try { enterOuterAlt(_localctx, 1); { setState(957); match(T__4); setState(958); match(T__5); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Identifier_listContext extends ParserRuleContext { public List<String> value; public Identifier_objectContext io; public Empty_listContext empty_list() { return getRuleContext(Empty_listContext.class,0); } public List<Identifier_objectContext> identifier_object() { return getRuleContexts(Identifier_objectContext.class); } public Identifier_objectContext identifier_object(int i) { return getRuleContext(Identifier_objectContext.class,i); } public List<TerminalNode> SEMICOLON() { return getTokens(NpcDatasParser.SEMICOLON); } public TerminalNode SEMICOLON(int i) { return getToken(NpcDatasParser.SEMICOLON, i); } public Identifier_listContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_identifier_list; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterIdentifier_list(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitIdentifier_list(this); } } public final Identifier_listContext identifier_list() throws RecognitionException { Identifier_listContext _localctx = new Identifier_listContext(_ctx, getState()); enterRule(_localctx, 214, RULE_identifier_list); _localctx.value = new ArrayList<>(); int _la; try { setState(975); _errHandler.sync(this); switch ( getInterpreter().adaptivePredict(_input,21,_ctx) ) { case 1: enterOuterAlt(_localctx, 1); { setState(960); empty_list(); } break; case 2: enterOuterAlt(_localctx, 2); { setState(961); match(T__4); setState(962); ((Identifier_listContext)_localctx).io = identifier_object(); _localctx.value.add(((Identifier_listContext)_localctx).io.value); setState(970); _errHandler.sync(this); _la = _input.LA(1); while (_la==SEMICOLON) { { { setState(964); match(SEMICOLON); setState(965); ((Identifier_listContext)_localctx).io = identifier_object(); _localctx.value.add(((Identifier_listContext)_localctx).io.value); } } setState(972); _errHandler.sync(this); _la = _input.LA(1); } setState(973); match(T__5); } break; } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Int_listContext extends ParserRuleContext { public List<Integer> value; public Int_objectContext io; public Empty_listContext empty_list() { return getRuleContext(Empty_listContext.class,0); } public List<Int_objectContext> int_object() { return getRuleContexts(Int_objectContext.class); } public Int_objectContext int_object(int i) { return getRuleContext(Int_objectContext.class,i); } public List<TerminalNode> SEMICOLON() { return getTokens(NpcDatasParser.SEMICOLON); } public TerminalNode SEMICOLON(int i) { return getToken(NpcDatasParser.SEMICOLON, i); } public Int_listContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_int_list; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterInt_list(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitInt_list(this); } } public final Int_listContext int_list() throws RecognitionException { Int_listContext _localctx = new Int_listContext(_ctx, getState()); enterRule(_localctx, 216, RULE_int_list); _localctx.value = new ArrayList<>(); int _la; try { setState(992); _errHandler.sync(this); switch ( getInterpreter().adaptivePredict(_input,23,_ctx) ) { case 1: enterOuterAlt(_localctx, 1); { setState(977); empty_list(); } break; case 2: enterOuterAlt(_localctx, 2); { setState(978); match(T__4); setState(979); ((Int_listContext)_localctx).io = int_object(); _localctx.value.add(((Int_listContext)_localctx).io.value); setState(987); _errHandler.sync(this); _la = _input.LA(1); while (_la==SEMICOLON) { { { setState(981); match(SEMICOLON); setState(982); ((Int_listContext)_localctx).io = int_object(); _localctx.value.add(((Int_listContext)_localctx).io.value); } } setState(989); _errHandler.sync(this); _la = _input.LA(1); } setState(990); match(T__5); } break; } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Double_listContext extends ParserRuleContext { public List<Double> value; public Double_objectContext d; public Empty_listContext empty_list() { return getRuleContext(Empty_listContext.class,0); } public List<Double_objectContext> double_object() { return getRuleContexts(Double_objectContext.class); } public Double_objectContext double_object(int i) { return getRuleContext(Double_objectContext.class,i); } public List<TerminalNode> SEMICOLON() { return getTokens(NpcDatasParser.SEMICOLON); } public TerminalNode SEMICOLON(int i) { return getToken(NpcDatasParser.SEMICOLON, i); } public Double_listContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_double_list; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterDouble_list(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitDouble_list(this); } } public final Double_listContext double_list() throws RecognitionException { Double_listContext _localctx = new Double_listContext(_ctx, getState()); enterRule(_localctx, 218, RULE_double_list); _localctx.value = new ArrayList<>(); int _la; try { setState(1009); _errHandler.sync(this); switch ( getInterpreter().adaptivePredict(_input,25,_ctx) ) { case 1: enterOuterAlt(_localctx, 1); { setState(994); empty_list(); } break; case 2: enterOuterAlt(_localctx, 2); { setState(995); match(T__4); setState(996); ((Double_listContext)_localctx).d = double_object(); _localctx.value.add(Double.valueOf((((Double_listContext)_localctx).d!=null?_input.getText(((Double_listContext)_localctx).d.start,((Double_listContext)_localctx).d.stop):null))); setState(1004); _errHandler.sync(this); _la = _input.LA(1); while (_la==SEMICOLON) { { { setState(998); match(SEMICOLON); setState(999); ((Double_listContext)_localctx).d = double_object(); _localctx.value.add(Double.valueOf((((Double_listContext)_localctx).d!=null?_input.getText(((Double_listContext)_localctx).d.start,((Double_listContext)_localctx).d.stop):null))); } } setState(1006); _errHandler.sync(this); _la = _input.LA(1); } setState(1007); match(T__5); } break; } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Base_attribute_attackContext extends ParserRuleContext { public AttributeAttack value; public Attack_attributeContext aa; public Attack_attributeContext attack_attribute() { return getRuleContext(Attack_attributeContext.class,0); } public Base_attribute_attackContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_base_attribute_attack; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterBase_attribute_attack(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitBase_attribute_attack(this); } } public final Base_attribute_attackContext base_attribute_attack() throws RecognitionException { Base_attribute_attackContext _localctx = new Base_attribute_attackContext(_ctx, getState()); enterRule(_localctx, 220, RULE_base_attribute_attack); try { enterOuterAlt(_localctx, 1); { setState(1011); match(T__92); setState(1012); match(T__3); setState(1013); ((Base_attribute_attackContext)_localctx).aa = attack_attribute(); _localctx.value = ((Base_attribute_attackContext)_localctx).aa.value; } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Attack_attributeContext extends ParserRuleContext { public AttributeAttack value; public AttributeContext attribute; public Int_objectContext io; public AttributeContext attribute() { return getRuleContext(AttributeContext.class,0); } public TerminalNode SEMICOLON() { return getToken(NpcDatasParser.SEMICOLON, 0); } public Int_objectContext int_object() { return getRuleContext(Int_objectContext.class,0); } public Attack_attributeContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_attack_attribute; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterAttack_attribute(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitAttack_attribute(this); } } public final Attack_attributeContext attack_attribute() throws RecognitionException { Attack_attributeContext _localctx = new Attack_attributeContext(_ctx, getState()); enterRule(_localctx, 222, RULE_attack_attribute); try { enterOuterAlt(_localctx, 1); { setState(1016); match(T__4); setState(1017); ((Attack_attributeContext)_localctx).attribute = attribute(); setState(1018); match(SEMICOLON); setState(1019); ((Attack_attributeContext)_localctx).io = int_object(); setState(1020); match(T__5); _localctx.value = new AttributeAttack(((Attack_attributeContext)_localctx).attribute.value, ((Attack_attributeContext)_localctx).io.value); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class AttributeContext extends ParserRuleContext { public AttributeType value; public TerminalNode NONE() { return getToken(NpcDatasParser.NONE, 0); } public TerminalNode FIRE() { return getToken(NpcDatasParser.FIRE, 0); } public TerminalNode WATER() { return getToken(NpcDatasParser.WATER, 0); } public TerminalNode EARTH() { return getToken(NpcDatasParser.EARTH, 0); } public TerminalNode WIND() { return getToken(NpcDatasParser.WIND, 0); } public TerminalNode HOLY() { return getToken(NpcDatasParser.HOLY, 0); } public TerminalNode UNHOLY() { return getToken(NpcDatasParser.UNHOLY, 0); } public AttributeContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_attribute; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterAttribute(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitAttribute(this); } } public final AttributeContext attribute() throws RecognitionException { AttributeContext _localctx = new AttributeContext(_ctx, getState()); enterRule(_localctx, 224, RULE_attribute); try { setState(1037); _errHandler.sync(this); switch (_input.LA(1)) { case NONE: enterOuterAlt(_localctx, 1); { setState(1023); match(NONE); _localctx.value = AttributeType.NONE; } break; case FIRE: enterOuterAlt(_localctx, 2); { setState(1025); match(FIRE); _localctx.value = AttributeType.FIRE; } break; case WATER: enterOuterAlt(_localctx, 3); { setState(1027); match(WATER); _localctx.value = AttributeType.WATER; } break; case EARTH: enterOuterAlt(_localctx, 4); { setState(1029); match(EARTH); _localctx.value = AttributeType.EARTH; } break; case WIND: enterOuterAlt(_localctx, 5); { setState(1031); match(WIND); _localctx.value = AttributeType.WIND; } break; case HOLY: enterOuterAlt(_localctx, 6); { setState(1033); match(HOLY); _localctx.value = AttributeType.HOLY; } break; case UNHOLY: enterOuterAlt(_localctx, 7); { setState(1035); match(UNHOLY); _localctx.value = AttributeType.UNHOLY; } break; default: throw new NoViableAltException(this); } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static class Category_listContext extends ParserRuleContext { public List<String> value; public Category_objectContext co; public Empty_listContext empty_list() { return getRuleContext(Empty_listContext.class,0); } public List<Category_objectContext> category_object() { return getRuleContexts(Category_objectContext.class); } public Category_objectContext category_object(int i) { return getRuleContext(Category_objectContext.class,i); } public List<TerminalNode> SEMICOLON() { return getTokens(NpcDatasParser.SEMICOLON); } public TerminalNode SEMICOLON(int i) { return getToken(NpcDatasParser.SEMICOLON, i); } public Category_listContext(ParserRuleContext parent, int invokingState) { super(parent, invokingState); } @Override public int getRuleIndex() { return RULE_category_list; } @Override public void enterRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).enterCategory_list(this); } @Override public void exitRule(ParseTreeListener listener) { if ( listener instanceof NpcDatasListener ) ((NpcDatasListener)listener).exitCategory_list(this); } } public final Category_listContext category_list() throws RecognitionException { Category_listContext _localctx = new Category_listContext(_ctx, getState()); enterRule(_localctx, 226, RULE_category_list); _localctx.value = new ArrayList<>(); int _la; try { setState(1054); _errHandler.sync(this); switch ( getInterpreter().adaptivePredict(_input,28,_ctx) ) { case 1: enterOuterAlt(_localctx, 1); { setState(1039); empty_list(); } break; case 2: enterOuterAlt(_localctx, 2); { setState(1040); match(T__4); setState(1041); ((Category_listContext)_localctx).co = category_object(); _localctx.value.add((((Category_listContext)_localctx).co!=null?_input.getText(((Category_listContext)_localctx).co.start,((Category_listContext)_localctx).co.stop):null)); setState(1049); _errHandler.sync(this); _la = _input.LA(1); while (_la==SEMICOLON) { { { setState(1043); match(SEMICOLON); setState(1044); ((Category_listContext)_localctx).co = category_object(); _localctx.value.add((((Category_listContext)_localctx).co!=null?_input.getText(((Category_listContext)_localctx).co.start,((Category_listContext)_localctx).co.stop):null)); } } setState(1051); _errHandler.sync(this); _la = _input.LA(1); } setState(1052); match(T__5); } break; } } catch (RecognitionException re) { _localctx.exception = re; _errHandler.reportError(this, re); _errHandler.recover(this, re); } finally { exitRule(); } return _localctx; } public static final String _serializedATN = "\3\u608b\ua72a\u8133\ub9ed\u417c\u3be7\u7786\u5964\3\u00e8\u0423\4\2\t"+ "\2\4\3\t\3\4\4\t\4\4\5\t\5\4\6\t\6\4\7\t\7\4\b\t\b\4\t\t\t\4\n\t\n\4\13"+ "\t\13\4\f\t\f\4\r\t\r\4\16\t\16\4\17\t\17\4\20\t\20\4\21\t\21\4\22\t\22"+ "\4\23\t\23\4\24\t\24\4\25\t\25\4\26\t\26\4\27\t\27\4\30\t\30\4\31\t\31"+ "\4\32\t\32\4\33\t\33\4\34\t\34\4\35\t\35\4\36\t\36\4\37\t\37\4 \t \4!"+ "\t!\4\"\t\"\4#\t#\4$\t$\4%\t%\4&\t&\4\'\t\'\4(\t(\4)\t)\4*\t*\4+\t+\4"+ ",\t,\4-\t-\4.\t.\4/\t/\4\60\t\60\4\61\t\61\4\62\t\62\4\63\t\63\4\64\t"+ "\64\4\65\t\65\4\66\t\66\4\67\t\67\48\t8\49\t9\4:\t:\4;\t;\4<\t<\4=\t="+ "\4>\t>\4?\t?\4@\t@\4A\tA\4B\tB\4C\tC\4D\tD\4E\tE\4F\tF\4G\tG\4H\tH\4I"+ "\tI\4J\tJ\4K\tK\4L\tL\4M\tM\4N\tN\4O\tO\4P\tP\4Q\tQ\4R\tR\4S\tS\4T\tT"+ "\4U\tU\4V\tV\4W\tW\4X\tX\4Y\tY\4Z\tZ\4[\t[\4\\\t\\\4]\t]\4^\t^\4_\t_\4"+ "`\t`\4a\ta\4b\tb\4c\tc\4d\td\4e\te\4f\tf\4g\tg\4h\th\4i\ti\4j\tj\4k\t"+ "k\4l\tl\4m\tm\4n\tn\4o\to\4p\tp\4q\tq\4r\tr\4s\ts\3\2\6\2\u00e8\n\2\r"+ "\2\16\2\u00e9\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3"+ "\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3"+ "\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3"+ "\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3"+ "\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3\3"+ "\3\3\3\3\3\3\3\3\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3"+ "\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4"+ "\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3"+ "\4\3\4\3\4\3\4\5\4\u0178\n\4\3\5\3\5\3\5\3\6\3\6\3\6\3\7\3\7\3\7\3\7\3"+ "\7\3\b\3\b\3\b\3\b\3\t\3\t\3\t\3\t\3\n\3\n\3\n\3\n\3\n\3\n\3\n\5\n\u0194"+ "\n\n\3\13\3\13\3\13\3\13\3\f\3\f\3\f\3\f\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3"+ "\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r"+ "\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3"+ "\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r"+ "\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\3\r\5\r\u01e6\n\r\3\16\3"+ "\16\3\16\3\16\3\16\3\16\3\16\3\16\5\16\u01f0\n\16\3\17\3\17\3\17\3\17"+ "\3\20\3\20\3\20\3\20\5\20\u01fa\n\20\3\21\3\21\3\21\3\21\5\21\u0200\n"+ "\21\3\22\3\22\3\22\3\22\5\22\u0206\n\22\3\23\3\23\3\23\3\24\3\24\3\24"+ "\3\24\3\25\3\25\3\25\3\25\3\26\3\26\3\26\3\26\3\27\3\27\3\27\3\27\3\30"+ "\3\30\3\30\3\30\3\31\3\31\3\31\3\31\3\32\3\32\3\32\3\32\3\33\3\33\3\33"+ "\3\33\3\34\3\34\3\34\3\34\3\35\3\35\3\35\3\35\3\36\3\36\3\36\3\36\3\37"+ "\3\37\3\37\3\37\3 \3 \3 \3 \3!\3!\3!\3!\3\"\3\"\3\"\3\"\3#\3#\3#\3#\3"+ "$\3$\3$\3$\3$\3$\3$\3$\3$\3$\3$\3$\3$\3$\3$\3$\3$\3$\5$\u025d\n$\3%\3"+ "%\3%\3%\3&\3&\3&\3&\3\'\3\'\3\'\3\'\3(\3(\3(\3(\3)\3)\3)\3)\3*\3*\3*\3"+ "*\3+\3+\3+\3+\3,\3,\3,\3,\3-\3-\3-\3-\3.\3.\3.\3.\3/\3/\3/\3/\3\60\3\60"+ "\3\60\3\60\3\60\3\61\3\61\3\61\3\61\3\62\3\62\3\62\3\62\3\63\3\63\3\63"+ "\3\63\3\64\3\64\3\64\3\64\3\65\3\65\3\65\3\65\3\66\3\66\3\66\3\66\3\67"+ "\3\67\3\67\3\67\3\67\3\67\3\67\5\67\u02af\n\67\38\38\38\38\39\39\39\3"+ "9\3:\3:\3:\3:\3;\3;\3;\3;\3<\3<\3<\3<\3=\3=\3=\3=\3>\3>\3>\3>\3?\3?\3"+ "?\3?\3@\3@\3@\3@\3A\3A\3A\3A\3B\3B\3B\3B\3C\3C\3C\3C\3D\3D\3D\3D\3E\3"+ "E\3E\3E\3F\3F\3F\3F\3G\3G\3G\3G\3G\3G\3G\7G\u02f4\nG\fG\16G\u02f7\13G"+ "\3G\3G\3H\3H\3H\3H\3H\3H\3I\3I\3I\3I\3I\3I\5I\u0307\nI\3J\3J\3J\3J\7J"+ "\u030d\nJ\fJ\16J\u0310\13J\3J\3J\3K\3K\3K\3K\3L\3L\3L\3L\3L\3L\3M\3M\3"+ "M\3M\3N\3N\3N\3N\3O\3O\3O\3O\3P\3P\3P\3P\3Q\3Q\3Q\3Q\3R\3R\3R\3R\3S\3"+ "S\3S\3S\3S\3S\7S\u033c\nS\fS\16S\u033f\13S\3S\3S\5S\u0343\nS\3T\3T\3T"+ "\3T\3T\3T\3T\3T\3T\3T\3U\3U\3U\3U\3V\3V\3V\3V\3W\3W\3W\3W\3W\3W\3W\3W"+ "\3W\3W\3W\3W\3W\3W\3W\7W\u0366\nW\fW\16W\u0369\13W\3W\3W\5W\u036d\nW\3"+ "X\3X\3X\3X\3Y\3Y\3Y\3Y\3Z\3Z\3Z\3Z\3Z\3Z\3Z\3Z\3Z\3Z\3Z\3Z\3[\3[\3[\3"+ "[\5[\u0387\n[\3\\\3\\\3\\\3\\\5\\\u038d\n\\\3]\3]\3]\3]\3^\3^\3^\3^\3"+ "_\3_\3_\3_\3`\3`\3`\3`\3a\3a\3a\3a\3b\3b\3c\3c\3d\3d\3e\3e\3f\3f\3g\3"+ "g\3h\3h\3i\3i\3i\3i\3i\3j\3j\3k\3k\3k\3k\3k\3k\3k\3k\3l\3l\3l\3m\3m\3"+ "m\3m\3m\3m\3m\3m\7m\u03cb\nm\fm\16m\u03ce\13m\3m\3m\5m\u03d2\nm\3n\3n"+ "\3n\3n\3n\3n\3n\3n\7n\u03dc\nn\fn\16n\u03df\13n\3n\3n\5n\u03e3\nn\3o\3"+ "o\3o\3o\3o\3o\3o\3o\7o\u03ed\no\fo\16o\u03f0\13o\3o\3o\5o\u03f4\no\3p"+ "\3p\3p\3p\3p\3q\3q\3q\3q\3q\3q\3q\3r\3r\3r\3r\3r\3r\3r\3r\3r\3r\3r\3r"+ "\3r\3r\5r\u0410\nr\3s\3s\3s\3s\3s\3s\3s\3s\7s\u041a\ns\fs\16s\u041d\13"+ "s\3s\3s\5s\u0421\ns\3s\2\2t\2\4\6\b\n\f\16\20\22\24\26\30\32\34\36 \""+ "$&(*,.\60\62\64\668:<>@BDFHJLNPRTVXZ\\^`bdfhjlnprtvxz|~\u0080\u0082\u0084"+ "\u0086\u0088\u008a\u008c\u008e\u0090\u0092\u0094\u0096\u0098\u009a\u009c"+ "\u009e\u00a0\u00a2\u00a4\u00a6\u00a8\u00aa\u00ac\u00ae\u00b0\u00b2\u00b4"+ "\u00b6\u00b8\u00ba\u00bc\u00be\u00c0\u00c2\u00c4\u00c6\u00c8\u00ca\u00cc"+ "\u00ce\u00d0\u00d2\u00d4\u00d6\u00d8\u00da\u00dc\u00de\u00e0\u00e2\u00e4"+ "\2\5\20\2\23\23 nn\u0083\u0083\u0089\u0089\u00a2\u00a2\u00a4\u00a4\u00a9"+ "\u00a9\u00ab\u00ab\u00b9\u00b9\u00ca\u00ca\u00ce\u00ce\u00d1\u00d1\u00e5"+ "\u00e5\3\2de\3\2df\2\u0416\2\u00e7\3\2\2\2\4\u00eb\3\2\2\2\6\u0177\3\2"+ "\2\2\b\u0179\3\2\2\2\n\u017c\3\2\2\2\f\u017f\3\2\2\2\16\u0184\3\2\2\2"+ "\20\u0188\3\2\2\2\22\u018c\3\2\2\2\24\u0195\3\2\2\2\26\u0199\3\2\2\2\30"+ "\u019d\3\2\2\2\32\u01e7\3\2\2\2\34\u01f1\3\2\2\2\36\u01f5\3\2\2\2 \u01fb"+ "\3\2\2\2\"\u0201\3\2\2\2$\u0207\3\2\2\2&\u020a\3\2\2\2(\u020e\3\2\2\2"+ "*\u0212\3\2\2\2,\u0216\3\2\2\2.\u021a\3\2\2\2\60\u021e\3\2\2\2\62\u0222"+ "\3\2\2\2\64\u0226\3\2\2\2\66\u022a\3\2\2\28\u022e\3\2\2\2:\u0232\3\2\2"+ "\2<\u0236\3\2\2\2>\u023a\3\2\2\2@\u023e\3\2\2\2B\u0242\3\2\2\2D\u0246"+ "\3\2\2\2F\u024a\3\2\2\2H\u025e\3\2\2\2J\u0262\3\2\2\2L\u0266\3\2\2\2N"+ "\u026a\3\2\2\2P\u026e\3\2\2\2R\u0272\3\2\2\2T\u0276\3\2\2\2V\u027a\3\2"+ "\2\2X\u027e\3\2\2\2Z\u0282\3\2\2\2\\\u0286\3\2\2\2^\u028a\3\2\2\2`\u028f"+ "\3\2\2\2b\u0293\3\2\2\2d\u0297\3\2\2\2f\u029b\3\2\2\2h\u029f\3\2\2\2j"+ "\u02a3\3\2\2\2l\u02a7\3\2\2\2n\u02b0\3\2\2\2p\u02b4\3\2\2\2r\u02b8\3\2"+ "\2\2t\u02bc\3\2\2\2v\u02c0\3\2\2\2x\u02c4\3\2\2\2z\u02c8\3\2\2\2|\u02cc"+ "\3\2\2\2~\u02d0\3\2\2\2\u0080\u02d4\3\2\2\2\u0082\u02d8\3\2\2\2\u0084"+ "\u02dc\3\2\2\2\u0086\u02e0\3\2\2\2\u0088\u02e4\3\2\2\2\u008a\u02e8\3\2"+ "\2\2\u008c\u02ec\3\2\2\2\u008e\u02fa\3\2\2\2\u0090\u0306\3\2\2\2\u0092"+ "\u0308\3\2\2\2\u0094\u0313\3\2\2\2\u0096\u0317\3\2\2\2\u0098\u031d\3\2"+ "\2\2\u009a\u0321\3\2\2\2\u009c\u0325\3\2\2\2\u009e\u0329\3\2\2\2\u00a0"+ "\u032d\3\2\2\2\u00a2\u0331\3\2\2\2\u00a4\u0342\3\2\2\2\u00a6\u0344\3\2"+ "\2\2\u00a8\u034e\3\2\2\2\u00aa\u0352\3\2\2\2\u00ac\u036c\3\2\2\2\u00ae"+ "\u036e\3\2\2\2\u00b0\u0372\3\2\2\2\u00b2\u0376\3\2\2\2\u00b4\u0386\3\2"+ "\2\2\u00b6\u038c\3\2\2\2\u00b8\u038e\3\2\2\2\u00ba\u0392\3\2\2\2\u00bc"+ "\u0396\3\2\2\2\u00be\u039a\3\2\2\2\u00c0\u039e\3\2\2\2\u00c2\u03a2\3\2"+ "\2\2\u00c4\u03a4\3\2\2\2\u00c6\u03a6\3\2\2\2\u00c8\u03a8\3\2\2\2\u00ca"+ "\u03aa\3\2\2\2\u00cc\u03ac\3\2\2\2\u00ce\u03ae\3\2\2\2\u00d0\u03b0\3\2"+ "\2\2\u00d2\u03b5\3\2\2\2\u00d4\u03b7\3\2\2\2\u00d6\u03bf\3\2\2\2\u00d8"+ "\u03d1\3\2\2\2\u00da\u03e2\3\2\2\2\u00dc\u03f3\3\2\2\2\u00de\u03f5\3\2"+ "\2\2\u00e0\u03fa\3\2\2\2\u00e2\u040f\3\2\2\2\u00e4\u0420\3\2\2\2\u00e6"+ "\u00e8\5\4\3\2\u00e7\u00e6\3\2\2\2\u00e8\u00e9\3\2\2\2\u00e9\u00e7\3\2"+ "\2\2\u00e9\u00ea\3\2\2\2\u00ea\3\3\2\2\2\u00eb\u00ec\7\3\2\2\u00ec\u00ed"+ "\5\6\4\2\u00ed\u00ee\5\b\5\2\u00ee\u00ef\5\n\6\2\u00ef\u00f0\5\f\7\2\u00f0"+ "\u00f1\5\16\b\2\u00f1\u00f2\5\20\t\2\u00f2\u00f3\5\22\n\2\u00f3\u00f4"+ "\5\24\13\2\u00f4\u00f5\5\26\f\2\u00f5\u00f6\5\30\r\2\u00f6\u00f7\5\32"+ "\16\2\u00f7\u00f8\5\34\17\2\u00f8\u00f9\5\36\20\2\u00f9\u00fa\5 \21\2"+ "\u00fa\u00fb\5\"\22\2\u00fb\u00fc\5&\24\2\u00fc\u00fd\5(\25\2\u00fd\u00fe"+ "\5*\26\2\u00fe\u00ff\5,\27\2\u00ff\u0100\5.\30\2\u0100\u0101\5\60\31\2"+ "\u0101\u0102\5\62\32\2\u0102\u0103\5\64\33\2\u0103\u0104\5\66\34\2\u0104"+ "\u0105\58\35\2\u0105\u0106\5:\36\2\u0106\u0107\5<\37\2\u0107\u0108\5>"+ " \2\u0108\u0109\5@!\2\u0109\u010a\5B\"\2\u010a\u010b\5D#\2\u010b\u010c"+ "\5F$\2\u010c\u010d\5H%\2\u010d\u010e\5J&\2\u010e\u010f\5L\'\2\u010f\u0110"+ "\5N(\2\u0110\u0111\5P)\2\u0111\u0112\5R*\2\u0112\u0113\5T+\2\u0113\u0114"+ "\5V,\2\u0114\u0115\5X-\2\u0115\u0116\5Z.\2\u0116\u0117\5\\/\2\u0117\u0118"+ "\5\u00dep\2\u0118\u0119\5^\60\2\u0119\u011a\5`\61\2\u011a\u011b\5b\62"+ "\2\u011b\u011c\5d\63\2\u011c\u011d\5f\64\2\u011d\u011e\5h\65\2\u011e\u011f"+ "\5j\66\2\u011f\u0120\5l\67\2\u0120\u0121\5n8\2\u0121\u0122\5p9\2\u0122"+ "\u0123\5r:\2\u0123\u0124\5t;\2\u0124\u0125\5v<\2\u0125\u0126\5x=\2\u0126"+ "\u0127\5z>\2\u0127\u0128\5|?\2\u0128\u0129\5~@\2\u0129\u012a\5\u0080A"+ "\2\u012a\u012b\5\u0082B\2\u012b\u012c\5\u0084C\2\u012c\u012d\5\u0086D"+ "\2\u012d\u012e\5\u0088E\2\u012e\u012f\5\u008aF\2\u012f\u0130\5\u008cG"+ "\2\u0130\u0131\5\u0096L\2\u0131\u0132\5\u0098M\2\u0132\u0133\5\u009aN"+ "\2\u0133\u0134\5\u009cO\2\u0134\u0135\5\u009eP\2\u0135\u0136\5\u00a0Q"+ "\2\u0136\u0137\5\u00a2R\2\u0137\u0138\5\u00a8U\2\u0138\u0139\5\u00aaV"+ "\2\u0139\u013a\5\u00aeX\2\u013a\u013b\5\u00b0Y\2\u013b\u013c\5\u00b2Z"+ "\2\u013c\u013d\5\u00b8]\2\u013d\u013e\5\u00ba^\2\u013e\u013f\5\u00bc_"+ "\2\u013f\u0140\5\u00be`\2\u0140\u0141\5\u00c0a\2\u0141\u0142\7\4\2\2\u0142"+ "\5\3\2\2\2\u0143\u0144\7\u0091\2\2\u0144\u0178\b\4\1\2\u0145\u0146\7\u0093"+ "\2\2\u0146\u0178\b\4\1\2\u0147\u0148\7\u0092\2\2\u0148\u0178\b\4\1\2\u0149"+ "\u014a\7\u008a\2\2\u014a\u0178\b\4\1\2\u014b\u014c\7\u0089\2\2\u014c\u0178"+ "\b\4\1\2\u014d\u014e\7\u0094\2\2\u014e\u0178\b\4\1\2\u014f\u0150\7\u008b"+ "\2\2\u0150\u0178\b\4\1\2\u0151\u0152\7\u0080\2\2\u0152\u0178\b\4\1\2\u0153"+ "\u0154\7~\2\2\u0154\u0178\b\4\1\2\u0155\u0156\7\u0090\2\2\u0156\u0178"+ "\b\4\1\2\u0157\u0158\7\u0095\2\2\u0158\u0178\b\4\1\2\u0159\u015a\7\u008f"+ "\2\2\u015a\u0178\b\4\1\2\u015b\u015c\7\u0096\2\2\u015c\u0178\b\4\1\2\u015d"+ "\u015e\7\u0097\2\2\u015e\u0178\b\4\1\2\u015f\u0160\7\u008e\2\2\u0160\u0178"+ "\b\4\1\2\u0161\u0162\7\u008c\2\2\u0162\u0178\b\4\1\2\u0163\u0164\7\u0098"+ "\2\2\u0164\u0178\b\4\1\2\u0165\u0166\7\u0099\2\2\u0166\u0178\b\4\1\2\u0167"+ "\u0168\7}\2\2\u0168\u0178\b\4\1\2\u0169\u016a\7|\2\2\u016a\u0178\b\4\1"+ "\2\u016b\u016c\7\u009a\2\2\u016c\u0178\b\4\1\2\u016d\u016e\7\u009b\2\2"+ "\u016e\u0178\b\4\1\2\u016f\u0170\7\u009c\2\2\u0170\u0178\b\4\1\2\u0171"+ "\u0172\7\u009d\2\2\u0172\u0178\b\4\1\2\u0173\u0174\7\u009e\2\2\u0174\u0178"+ "\b\4\1\2\u0175\u0176\7\u009f\2\2\u0176\u0178\b\4\1\2\u0177\u0143\3\2\2"+ "\2\u0177\u0145\3\2\2\2\u0177\u0147\3\2\2\2\u0177\u0149\3\2\2\2\u0177\u014b"+ "\3\2\2\2\u0177\u014d\3\2\2\2\u0177\u014f\3\2\2\2\u0177\u0151\3\2\2\2\u0177"+ "\u0153\3\2\2\2\u0177\u0155\3\2\2\2\u0177\u0157\3\2\2\2\u0177\u0159\3\2"+ "\2\2\u0177\u015b\3\2\2\2\u0177\u015d\3\2\2\2\u0177\u015f\3\2\2\2\u0177"+ "\u0161\3\2\2\2\u0177\u0163\3\2\2\2\u0177\u0165\3\2\2\2\u0177\u0167\3\2"+ "\2\2\u0177\u0169\3\2\2\2\u0177\u016b\3\2\2\2\u0177\u016d\3\2\2\2\u0177"+ "\u016f\3\2\2\2\u0177\u0171\3\2\2\2\u0177\u0173\3\2\2\2\u0177\u0175\3\2"+ "\2\2\u0178\7\3\2\2\2\u0179\u017a\5\u00c8e\2\u017a\u017b\b\5\1\2\u017b"+ "\t\3\2\2\2\u017c\u017d\5\u00d0i\2\u017d\u017e\b\6\1\2\u017e\13\3\2\2\2"+ "\u017f\u0180\7\5\2\2\u0180\u0181\7\6\2\2\u0181\u0182\7\7\2\2\u0182\u0183"+ "\7\b\2\2\u0183\r\3\2\2\2\u0184\u0185\7\t\2\2\u0185\u0186\7\6\2\2\u0186"+ "\u0187\5\u00c8e\2\u0187\17\3\2\2\2\u0188\u0189\7\n\2\2\u0189\u018a\7\6"+ "\2\2\u018a\u018b\5\u00caf\2\u018b\21\3\2\2\2\u018c\u018d\7\13\2\2\u018d"+ "\u0193\7\6\2\2\u018e\u0194\5\u00c4c\2\u018f\u0190\7\7\2\2\u0190\u0191"+ "\5\u00c4c\2\u0191\u0192\7\b\2\2\u0192\u0194\3\2\2\2\u0193\u018e\3\2\2"+ "\2\u0193\u018f\3\2\2\2\u0194\23\3\2\2\2\u0195\u0196\7\f\2\2\u0196\u0197"+ "\7\6\2\2\u0197\u0198\5\u00c4c\2\u0198\25\3\2\2\2\u0199\u019a\7\r\2\2\u019a"+ "\u019b\7\6\2\2\u019b\u019c\5\u00ccg\2\u019c\27\3\2\2\2\u019d\u019e\7\16"+ "\2\2\u019e\u01e5\7\6\2\2\u019f\u01a0\7o\2\2\u01a0\u01e6\b\r\1\2\u01a1"+ "\u01a2\7p\2\2\u01a2\u01e6\b\r\1\2\u01a3\u01a4\7q\2\2\u01a4\u01e6\b\r\1"+ "\2\u01a5\u01a6\7r\2\2\u01a6\u01e6\b\r\1\2\u01a7\u01a8\7s\2\2\u01a8\u01e6"+ "\b\r\1\2\u01a9\u01aa\7t\2\2\u01aa\u01e6\b\r\1\2\u01ab\u01ac\7u\2\2\u01ac"+ "\u01e6\b\r\1\2\u01ad\u01ae\7v\2\2\u01ae\u01e6\b\r\1\2\u01af\u01b0\7w\2"+ "\2\u01b0\u01e6\b\r\1\2\u01b1\u01b2\7x\2\2\u01b2\u01e6\b\r\1\2\u01b3\u01b4"+ "\7z\2\2\u01b4\u01e6\b\r\1\2\u01b5\u01b6\7y\2\2\u01b6\u01e6\b\r\1\2\u01b7"+ "\u01b8\7{\2\2\u01b8\u01e6\b\r\1\2\u01b9\u01ba\7b\2\2\u01ba\u01e6\b\r\1"+ "\2\u01bb\u01bc\7|\2\2\u01bc\u01e6\b\r\1\2\u01bd\u01be\7}\2\2\u01be\u01e6"+ "\b\r\1\2\u01bf\u01c0\7~\2\2\u01c0\u01e6\b\r\1\2\u01c1\u01c2\7\177\2\2"+ "\u01c2\u01e6\b\r\1\2\u01c3\u01c4\7\u0080\2\2\u01c4\u01e6\b\r\1\2\u01c5"+ "\u01c6\7\u0081\2\2\u01c6\u01e6\b\r\1\2\u01c7\u01c8\7\u0082\2\2\u01c8\u01e6"+ "\b\r\1\2\u01c9\u01ca\7\u0083\2\2\u01ca\u01e6\b\r\1\2\u01cb\u01cc\7\u0086"+ "\2\2\u01cc\u01e6\b\r\1\2\u01cd\u01ce\7\u0087\2\2\u01ce\u01e6\b\r\1\2\u01cf"+ "\u01d0\7\u0088\2\2\u01d0\u01e6\b\r\1\2\u01d1\u01d2\7\u0089\2\2\u01d2\u01e6"+ "\b\r\1\2\u01d3\u01d4\7\u008a\2\2\u01d4\u01e6\b\r\1\2\u01d5\u01d6\7\u008b"+ "\2\2\u01d6\u01e6\b\r\1\2\u01d7\u01d8\7\u008c\2\2\u01d8\u01e6\b\r\1\2\u01d9"+ "\u01da\7\u008e\2\2\u01da\u01e6\b\r\1\2\u01db\u01dc\7\u008f\2\2\u01dc\u01e6"+ "\b\r\1\2\u01dd\u01de\7\u0090\2\2\u01de\u01e6\b\r\1\2\u01df\u01e0\7\u008d"+ "\2\2\u01e0\u01e6\b\r\1\2\u01e1\u01e2\7\u0084\2\2\u01e2\u01e6\b\r\1\2\u01e3"+ "\u01e4\7\u0085\2\2\u01e4\u01e6\b\r\1\2\u01e5\u019f\3\2\2\2\u01e5\u01a1"+ "\3\2\2\2\u01e5\u01a3\3\2\2\2\u01e5\u01a5\3\2\2\2\u01e5\u01a7\3\2\2\2\u01e5"+ "\u01a9\3\2\2\2\u01e5\u01ab\3\2\2\2\u01e5\u01ad\3\2\2\2\u01e5\u01af\3\2"+ "\2\2\u01e5\u01b1\3\2\2\2\u01e5\u01b3\3\2\2\2\u01e5\u01b5\3\2\2\2\u01e5"+ "\u01b7\3\2\2\2\u01e5\u01b9\3\2\2\2\u01e5\u01bb\3\2\2\2\u01e5\u01bd\3\2"+ "\2\2\u01e5\u01bf\3\2\2\2\u01e5\u01c1\3\2\2\2\u01e5\u01c3\3\2\2\2\u01e5"+ "\u01c5\3\2\2\2\u01e5\u01c7\3\2\2\2\u01e5\u01c9\3\2\2\2\u01e5\u01cb\3\2"+ "\2\2\u01e5\u01cd\3\2\2\2\u01e5\u01cf\3\2\2\2\u01e5\u01d1\3\2\2\2\u01e5"+ "\u01d3\3\2\2\2\u01e5\u01d5\3\2\2\2\u01e5\u01d7\3\2\2\2\u01e5\u01d9\3\2"+ "\2\2\u01e5\u01db\3\2\2\2\u01e5\u01dd\3\2\2\2\u01e5\u01df\3\2\2\2\u01e5"+ "\u01e1\3\2\2\2\u01e5\u01e3\3\2\2\2\u01e6\31\3\2\2\2\u01e7\u01e8\7\17\2"+ "\2\u01e8\u01ef\7\6\2\2\u01e9\u01ea\7`\2\2\u01ea\u01f0\b\16\1\2\u01eb\u01ec"+ "\7a\2\2\u01ec\u01f0\b\16\1\2\u01ed\u01ee\7b\2\2\u01ee\u01f0\b\16\1\2\u01ef"+ "\u01e9\3\2\2\2\u01ef\u01eb\3\2\2\2\u01ef\u01ed\3\2\2\2\u01f0\33\3\2\2"+ "\2\u01f1\u01f2\7\20\2\2\u01f2\u01f3\7\6\2\2\u01f3\u01f4\5\u00e4s\2\u01f4"+ "\35\3\2\2\2\u01f5\u01f6\7\21\2\2\u01f6\u01f9\7\6\2\2\u01f7\u01fa\5$\23"+ "\2\u01f8\u01fa\5\u00d0i\2\u01f9\u01f7\3\2\2\2\u01f9\u01f8\3\2\2\2\u01fa"+ "\37\3\2\2\2\u01fb\u01fc\7\22\2\2\u01fc\u01ff\7\6\2\2\u01fd\u0200\5$\23"+ "\2\u01fe\u0200\5\u00d0i\2\u01ff\u01fd\3\2\2\2\u01ff\u01fe\3\2\2\2\u0200"+ "!\3\2\2\2\u0201\u0202\7\23\2\2\u0202\u0205\7\6\2\2\u0203\u0206\5$\23\2"+ "\u0204\u0206\5\u00d0i\2\u0205\u0203\3\2\2\2\u0205\u0204\3\2\2\2\u0206"+ "#\3\2\2\2\u0207\u0208\7\24\2\2\u0208\u0209\7\25\2\2\u0209%\3\2\2\2\u020a"+ "\u020b\7\26\2\2\u020b\u020c\7\6\2\2\u020c\u020d\5\u00dco\2\u020d\'\3\2"+ "\2\2\u020e\u020f\7\27\2\2\u020f\u0210\7\6\2\2\u0210\u0211\5\u00dco\2\u0211"+ ")\3\2\2\2\u0212\u0213\7\30\2\2\u0213\u0214\7\6\2\2\u0214\u0215\5\u00cc"+ "g\2\u0215+\3\2\2\2\u0216\u0217\7\31\2\2\u0217\u0218\7\6\2\2\u0218\u0219"+ "\5\u00c8e\2\u0219-\3\2\2\2\u021a\u021b\7\32\2\2\u021b\u021c\7\6\2\2\u021c"+ "\u021d\5\u00dco\2\u021d/\3\2\2\2\u021e\u021f\7\33\2\2\u021f\u0220\7\6"+ "\2\2\u0220\u0221\5\u00dco\2\u0221\61\3\2\2\2\u0222\u0223\7\34\2\2\u0223"+ "\u0224\7\6\2\2\u0224\u0225\5\u00c8e\2\u0225\63\3\2\2\2\u0226\u0227\7\35"+ "\2\2\u0227\u0228\7\6\2\2\u0228\u0229\5\u00c8e\2\u0229\65\3\2\2\2\u022a"+ "\u022b\7\36\2\2\u022b\u022c\7\6\2\2\u022c\u022d\5\u00c8e\2\u022d\67\3"+ "\2\2\2\u022e\u022f\7\37\2\2\u022f\u0230\7\6\2\2\u0230\u0231\5\u00c8e\2"+ "\u02319\3\2\2\2\u0232\u0233\7 \2\2\u0233\u0234\7\6\2\2\u0234\u0235\5\u00c8"+ "e\2\u0235;\3\2\2\2\u0236\u0237\7!\2\2\u0237\u0238\7\6\2\2\u0238\u0239"+ "\5\u00c8e\2\u0239=\3\2\2\2\u023a\u023b\7\"\2\2\u023b\u023c\7\6\2\2\u023c"+ "\u023d\5\u00ccg\2\u023d?\3\2\2\2\u023e\u023f\7#\2\2\u023f\u0240\7\6\2"+ "\2\u0240\u0241\5\u00ccg\2\u0241A\3\2\2\2\u0242\u0243\7$\2\2\u0243\u0244"+ "\7\6\2\2\u0244\u0245\5\u00ccg\2\u0245C\3\2\2\2\u0246\u0247\7%\2\2\u0247"+ "\u0248\7\6\2\2\u0248\u0249\5\u00ccg\2\u0249E\3\2\2\2\u024a\u024b\7&\2"+ "\2\u024b\u025c\7\6\2\2\u024c\u024d\7\u00a0\2\2\u024d\u025d\b$\1\2\u024e"+ "\u024f\7\u00a1\2\2\u024f\u025d\b$\1\2\u0250\u0251\7\u00a2\2\2\u0251\u025d"+ "\b$\1\2\u0252\u0253\7\u00a4\2\2\u0253\u025d\b$\1\2\u0254\u0255\7\u00a6"+ "\2\2\u0255\u025d\b$\1\2\u0256\u0257\7\u00a3\2\2\u0257\u025d\b$\1\2\u0258"+ "\u0259\7\u00a5\2\2\u0259\u025d\b$\1\2\u025a\u025b\7\u00a7\2\2\u025b\u025d"+ "\b$\1\2\u025c\u024c\3\2\2\2\u025c\u024e\3\2\2\2\u025c\u0250\3\2\2\2\u025c"+ "\u0252\3\2\2\2\u025c\u0254\3\2\2\2\u025c\u0256\3\2\2\2\u025c\u0258\3\2"+ "\2\2\u025c\u025a\3\2\2\2\u025dG\3\2\2\2\u025e\u025f\7\'\2\2\u025f\u0260"+ "\7\6\2\2\u0260\u0261\5\u00c8e\2\u0261I\3\2\2\2\u0262\u0263\7(\2\2\u0263"+ "\u0264\7\6\2\2\u0264\u0265\5\u00dan\2\u0265K\3\2\2\2\u0266\u0267\7)\2"+ "\2\u0267\u0268\7\6\2\2\u0268\u0269\5\u00c8e\2\u0269M\3\2\2\2\u026a\u026b"+ "\7*\2\2\u026b\u026c\7\6\2\2\u026c\u026d\5\u00ccg\2\u026dO\3\2\2\2\u026e"+ "\u026f\7+\2\2\u026f\u0270\7\6\2\2\u0270\u0271\5\u00ccg\2\u0271Q\3\2\2"+ "\2\u0272\u0273\7,\2\2\u0273\u0274\7\6\2\2\u0274\u0275\5\u00ccg\2\u0275"+ "S\3\2\2\2\u0276\u0277\7-\2\2\u0277\u0278\7\6\2\2\u0278\u0279\5\u00ccg"+ "\2\u0279U\3\2\2\2\u027a\u027b\7.\2\2\u027b\u027c\7\6\2\2\u027c\u027d\5"+ "\u00c8e\2\u027dW\3\2\2\2\u027e\u027f\7/\2\2\u027f\u0280\7\6\2\2\u0280"+ "\u0281\5\u00ccg\2\u0281Y\3\2\2\2\u0282\u0283\7\60\2\2\u0283\u0284\7\6"+ "\2\2\u0284\u0285\5\u00ccg\2\u0285[\3\2\2\2\u0286\u0287\7\61\2\2\u0287"+ "\u0288\7\6\2\2\u0288\u0289\5\u00ccg\2\u0289]\3\2\2\2\u028a\u028b\7\62"+ "\2\2\u028b\u028c\7\6\2\2\u028c\u028d\5\u00dco\2\u028d\u028e\b\60\1\2\u028e"+ "_\3\2\2\2\u028f\u0290\7\63\2\2\u0290\u0291\7\6\2\2\u0291\u0292\5\u00c8"+ "e\2\u0292a\3\2\2\2\u0293\u0294\7\64\2\2\u0294\u0295\7\6\2\2\u0295\u0296"+ "\5\u00c8e\2\u0296c\3\2\2\2\u0297\u0298\7\65\2\2\u0298\u0299\7\6\2\2\u0299"+ "\u029a\5\u00ccg\2\u029ae\3\2\2\2\u029b\u029c\7\66\2\2\u029c\u029d\7\6"+ "\2\2\u029d\u029e\5\u00c8e\2\u029eg\3\2\2\2\u029f\u02a0\7\67\2\2\u02a0"+ "\u02a1\7\6\2\2\u02a1\u02a2\5\u00c8e\2\u02a2i\3\2\2\2\u02a3\u02a4\78\2"+ "\2\u02a4\u02a5\7\6\2\2\u02a5\u02a6\5\u00c8e\2\u02a6k\3\2\2\2\u02a7\u02a8"+ "\79\2\2\u02a8\u02ae\7\6\2\2\u02a9\u02aa\7\7\2\2\u02aa\u02ab\5\u00c8e\2"+ "\u02ab\u02ac\7\b\2\2\u02ac\u02af\3\2\2\2\u02ad\u02af\5\u00e4s\2\u02ae"+ "\u02a9\3\2\2\2\u02ae\u02ad\3\2\2\2\u02afm\3\2\2\2\u02b0\u02b1\7:\2\2\u02b1"+ "\u02b2\7\6\2\2\u02b2\u02b3\5\u00e4s\2\u02b3o\3\2\2\2\u02b4\u02b5\7;\2"+ "\2\u02b5\u02b6\7\6\2\2\u02b6\u02b7\5\u00c8e\2\u02b7q\3\2\2\2\u02b8\u02b9"+ "\7<\2\2\u02b9\u02ba\7\6\2\2\u02ba\u02bb\5\u00c4c\2\u02bbs\3\2\2\2\u02bc"+ "\u02bd\7=\2\2\u02bd\u02be\7\6\2\2\u02be\u02bf\5\u00c4c\2\u02bfu\3\2\2"+ "\2\u02c0\u02c1\7>\2\2\u02c1\u02c2\7\6\2\2\u02c2\u02c3\5\u00c8e\2\u02c3"+ "w\3\2\2\2\u02c4\u02c5\7?\2\2\u02c5\u02c6\7\6\2\2\u02c6\u02c7\5\u00c4c"+ "\2\u02c7y\3\2\2\2\u02c8\u02c9\7@\2\2\u02c9\u02ca\7\6\2\2\u02ca\u02cb\5"+ "\u00c8e\2\u02cb{\3\2\2\2\u02cc\u02cd\7A\2\2\u02cd\u02ce\7\6\2\2\u02ce"+ "\u02cf\5\u00c8e\2\u02cf}\3\2\2\2\u02d0\u02d1\7B\2\2\u02d1\u02d2\7\6\2"+ "\2\u02d2\u02d3\5\u00c4c\2\u02d3\177\3\2\2\2\u02d4\u02d5\7C\2\2\u02d5\u02d6"+ "\7\6\2\2\u02d6\u02d7\5\u00c4c\2\u02d7\u0081\3\2\2\2\u02d8\u02d9\7D\2\2"+ "\u02d9\u02da\7\6\2\2\u02da\u02db\5\u00c4c\2\u02db\u0083\3\2\2\2\u02dc"+ "\u02dd\7E\2\2\u02dd\u02de\7\6\2\2\u02de\u02df\5\u00c4c\2\u02df\u0085\3"+ "\2\2\2\u02e0\u02e1\7F\2\2\u02e1\u02e2\7\6\2\2\u02e2\u02e3\5\u00c4c\2\u02e3"+ "\u0087\3\2\2\2\u02e4\u02e5\7G\2\2\u02e5\u02e6\7\6\2\2\u02e6\u02e7\5\u00da"+ "n\2\u02e7\u0089\3\2\2\2\u02e8\u02e9\7H\2\2\u02e9\u02ea\7\6\2\2\u02ea\u02eb"+ "\5\u00c4c\2\u02eb\u008b\3\2\2\2\u02ec\u02ed\7I\2\2\u02ed\u02ee\7\6\2\2"+ "\u02ee\u02ef\7\7\2\2\u02ef\u02f5\5\u00d0i\2\u02f0\u02f4\7m\2\2\u02f1\u02f2"+ "\7m\2\2\u02f2\u02f4\5\u008eH\2\u02f3\u02f0\3\2\2\2\u02f3\u02f1\3\2\2\2"+ "\u02f4\u02f7\3\2\2\2\u02f5\u02f3\3\2\2\2\u02f5\u02f6\3\2\2\2\u02f6\u02f8"+ "\3\2\2\2\u02f7\u02f5\3\2\2\2\u02f8\u02f9\7\b\2\2\u02f9\u008d\3\2\2\2\u02fa"+ "\u02fb\7\7\2\2\u02fb\u02fc\5\u00d0i\2\u02fc\u02fd\7\6\2\2\u02fd\u02fe"+ "\5\u0090I\2\u02fe\u02ff\7\b\2\2\u02ff\u008f\3\2\2\2\u0300\u0307\5\u00c8"+ "e\2\u0301\u0307\5\u00ccg\2\u0302\u0307\5\u00d2j\2\u0303\u0307\5\u0092"+ "J\2\u0304\u0307\5\u0094K\2\u0305\u0307\5\u00c2b\2\u0306\u0300\3\2\2\2"+ "\u0306\u0301\3\2\2\2\u0306\u0302\3\2\2\2\u0306\u0303\3\2\2\2\u0306\u0304"+ "\3\2\2\2\u0306\u0305\3\2\2\2\u0307\u0091\3\2\2\2\u0308\u0309\7\24\2\2"+ "\u0309\u030e\5\u00c2b\2\u030a\u030b\7m\2\2\u030b\u030d\5\u00c2b\2\u030c"+ "\u030a\3\2\2\2\u030d\u0310\3\2\2\2\u030e\u030c\3\2\2\2\u030e\u030f\3\2"+ "\2\2\u030f\u0311\3\2\2\2\u0310\u030e\3\2\2\2\u0311\u0312\7\25\2\2\u0312"+ "\u0093\3\2\2\2\u0313\u0314\7\24\2\2\u0314\u0315\5\u00c8e\2\u0315\u0316"+ "\7\25\2\2\u0316\u0095\3\2\2\2\u0317\u0318\7J\2\2\u0318\u0319\7\6\2\2\u0319"+ "\u031a\7\7\2\2\u031a\u031b\5\u00c8e\2\u031b\u031c\7\b\2\2\u031c\u0097"+ "\3\2\2\2\u031d\u031e\7K\2\2\u031e\u031f\7\6\2\2\u031f\u0320\5\u00c4c\2"+ "\u0320\u0099\3\2\2\2\u0321\u0322\7L\2\2\u0322\u0323\7\6\2\2\u0323\u0324"+ "\5\u00c4c\2\u0324\u009b\3\2\2\2\u0325\u0326\7M\2\2\u0326\u0327\7\6\2\2"+ "\u0327\u0328\5\u00ccg\2\u0328\u009d\3\2\2\2\u0329\u032a\7N\2\2\u032a\u032b"+ "\7\6\2\2\u032b\u032c\5\u00ccg\2\u032c\u009f\3\2\2\2\u032d\u032e\7O\2\2"+ "\u032e\u032f\7\6\2\2\u032f\u0330\5\u00ccg\2\u0330\u00a1\3\2\2\2\u0331"+ "\u0332\7P\2\2\u0332\u0333\7\6\2\2\u0333\u0334\5\u00a4S\2\u0334\u00a3\3"+ "\2\2\2\u0335\u0336\7\7\2\2\u0336\u0343\7\b\2\2\u0337\u0338\7\7\2\2\u0338"+ "\u033d\5\u00a6T\2\u0339\u033a\7m\2\2\u033a\u033c\5\u00a6T\2\u033b\u0339"+ "\3\2\2\2\u033c\u033f\3\2\2\2\u033d\u033b\3\2\2\2\u033d\u033e\3\2\2\2\u033e"+ "\u0340\3\2\2\2\u033f\u033d\3\2\2\2\u0340\u0341\7\b\2\2\u0341\u0343\3\2"+ "\2\2\u0342\u0335\3\2\2\2\u0342\u0337\3\2\2\2\u0343\u00a5\3\2\2\2\u0344"+ "\u0345\7\7\2\2\u0345\u0346\5\u00d0i\2\u0346\u0347\7m\2\2\u0347\u0348\5"+ "\u00c8e\2\u0348\u0349\7m\2\2\u0349\u034a\5\u00c8e\2\u034a\u034b\7m\2\2"+ "\u034b\u034c\5\u00ccg\2\u034c\u034d\7\b\2\2\u034d\u00a7\3\2\2\2\u034e"+ "\u034f\7Q\2\2\u034f\u0350\7\6\2\2\u0350\u0351\5\u00a4S\2\u0351\u00a9\3"+ "\2\2\2\u0352\u0353\7R\2\2\u0353\u0354\7\6\2\2\u0354\u0355\5\u00acW\2\u0355"+ "\u00ab\3\2\2\2\u0356\u0357\7\7\2\2\u0357\u036d\7\b\2\2\u0358\u0359\7\7"+ "\2\2\u0359\u035a\7\7\2\2\u035a\u035b\5\u00a4S\2\u035b\u035c\7m\2\2\u035c"+ "\u035d\5\u00ccg\2\u035d\u0367\7\b\2\2\u035e\u035f\7m\2\2\u035f\u0360\7"+ "\7\2\2\u0360\u0361\5\u00a4S\2\u0361\u0362\7m\2\2\u0362\u0363\5\u00ccg"+ "\2\u0363\u0364\7\b\2\2\u0364\u0366\3\2\2\2\u0365\u035e\3\2\2\2\u0366\u0369"+ "\3\2\2\2\u0367\u0365\3\2\2\2\u0367\u0368\3\2\2\2\u0368\u036a\3\2\2\2\u0369"+ "\u0367\3\2\2\2\u036a\u036b\7\b\2\2\u036b\u036d\3\2\2\2\u036c\u0356\3\2"+ "\2\2\u036c\u0358\3\2\2\2\u036d\u00ad\3\2\2\2\u036e\u036f\7S\2\2\u036f"+ "\u0370\7\6\2\2\u0370\u0371\5\u00acW\2\u0371\u00af\3\2\2\2\u0372\u0373"+ "\7T\2\2\u0373\u0374\7\6\2\2\u0374\u0375\5\u00acW\2\u0375\u00b1\3\2\2\2"+ "\u0376\u0377\7U\2\2\u0377\u0378\7\6\2\2\u0378\u0379\7\7\2\2\u0379\u037a"+ "\5\u00ccg\2\u037a\u037b\7m\2\2\u037b\u037c\5\u00b4[\2\u037c\u037d\7m\2"+ "\2\u037d\u037e\5\u00ccg\2\u037e\u037f\7m\2\2\u037f\u0380\5\u00b6\\\2\u0380"+ "\u0381\7\b\2\2\u0381\u00b3\3\2\2\2\u0382\u0383\7V\2\2\u0383\u0387\b[\1"+ "\2\u0384\u0385\7W\2\2\u0385\u0387\b[\1\2\u0386\u0382\3\2\2\2\u0386\u0384"+ "\3\2\2\2\u0387\u00b5\3\2\2\2\u0388\u0389\7X\2\2\u0389\u038d\b\\\1\2\u038a"+ "\u038b\7Y\2\2\u038b\u038d\b\\\1\2\u038c\u0388\3\2\2\2\u038c\u038a\3\2"+ "\2\2\u038d\u00b7\3\2\2\2\u038e\u038f\7Z\2\2\u038f\u0390\7\6\2\2\u0390"+ "\u0391\5\u00c8e\2\u0391\u00b9\3\2\2\2\u0392\u0393\7[\2\2\u0393\u0394\7"+ "\6\2\2\u0394\u0395\5\u00c8e\2\u0395\u00bb\3\2\2\2\u0396\u0397\7\\\2\2"+ "\u0397\u0398\7\6\2\2\u0398\u0399\5\u00dan\2\u0399\u00bd\3\2\2\2\u039a"+ "\u039b\7]\2\2\u039b\u039c\7\6\2\2\u039c\u039d\5\u00c4c\2\u039d\u00bf\3"+ "\2\2\2\u039e\u039f\7^\2\2\u039f\u03a0\7\6\2\2\u03a0\u03a1\5\u00dan\2\u03a1"+ "\u00c1\3\2\2\2\u03a2\u03a3\t\2\2\2\u03a3\u00c3\3\2\2\2\u03a4\u03a5\7d"+ "\2\2\u03a5\u00c5\3\2\2\2\u03a6\u03a7\t\3\2\2\u03a7\u00c7\3\2\2\2\u03a8"+ "\u03a9\t\3\2\2\u03a9\u00c9\3\2\2\2\u03aa\u03ab\t\3\2\2\u03ab\u00cb\3\2"+ "\2\2\u03ac\u03ad\t\4\2\2\u03ad\u00cd\3\2\2\2\u03ae\u03af\t\4\2\2\u03af"+ "\u00cf\3\2\2\2\u03b0\u03b1\7\24\2\2\u03b1\u03b2\5\u00c2b\2\u03b2\u03b3"+ "\7\25\2\2\u03b3\u03b4\bi\1\2\u03b4\u00d1\3\2\2\2\u03b5\u03b6\7c\2\2\u03b6"+ "\u00d3\3\2\2\2\u03b7\u03b8\7\7\2\2\u03b8\u03b9\5\u00c8e\2\u03b9\u03ba"+ "\7m\2\2\u03ba\u03bb\5\u00c8e\2\u03bb\u03bc\7m\2\2\u03bc\u03bd\5\u00c8"+ "e\2\u03bd\u03be\7\b\2\2\u03be\u00d5\3\2\2\2\u03bf\u03c0\7\7\2\2\u03c0"+ "\u03c1\7\b\2\2\u03c1\u00d7\3\2\2\2\u03c2\u03d2\5\u00d6l\2\u03c3\u03c4"+ "\7\7\2\2\u03c4\u03c5\5\u00c2b\2\u03c5\u03cc\bm\1\2\u03c6\u03c7\7m\2\2"+ "\u03c7\u03c8\5\u00c2b\2\u03c8\u03c9\bm\1\2\u03c9\u03cb\3\2\2\2\u03ca\u03c6"+ "\3\2\2\2\u03cb\u03ce\3\2\2\2\u03cc\u03ca\3\2\2\2\u03cc\u03cd\3\2\2\2\u03cd"+ "\u03cf\3\2\2\2\u03ce\u03cc\3\2\2\2\u03cf\u03d0\7\b\2\2\u03d0\u03d2\3\2"+ "\2\2\u03d1\u03c2\3\2\2\2\u03d1\u03c3\3\2\2\2\u03d2\u00d9\3\2\2\2\u03d3"+ "\u03e3\5\u00d6l\2\u03d4\u03d5\7\7\2\2\u03d5\u03d6\5\u00c8e\2\u03d6\u03dd"+ "\bn\1\2\u03d7\u03d8\7m\2\2\u03d8\u03d9\5\u00c8e\2\u03d9\u03da\bn\1\2\u03da"+ "\u03dc\3\2\2\2\u03db\u03d7\3\2\2\2\u03dc\u03df\3\2\2\2\u03dd\u03db\3\2"+ "\2\2\u03dd\u03de\3\2\2\2\u03de\u03e0\3\2\2\2\u03df\u03dd\3\2\2\2\u03e0"+ "\u03e1\7\b\2\2\u03e1\u03e3\3\2\2\2\u03e2\u03d3\3\2\2\2\u03e2\u03d4\3\2"+ "\2\2\u03e3\u00db\3\2\2\2\u03e4\u03f4\5\u00d6l\2\u03e5\u03e6\7\7\2\2\u03e6"+ "\u03e7\5\u00ccg\2\u03e7\u03ee\bo\1\2\u03e8\u03e9\7m\2\2\u03e9\u03ea\5"+ "\u00ccg\2\u03ea\u03eb\bo\1\2\u03eb\u03ed\3\2\2\2\u03ec\u03e8\3\2\2\2\u03ed"+ "\u03f0\3\2\2\2\u03ee\u03ec\3\2\2\2\u03ee\u03ef\3\2\2\2\u03ef\u03f1\3\2"+ "\2\2\u03f0\u03ee\3\2\2\2\u03f1\u03f2\7\b\2\2\u03f2\u03f4\3\2\2\2\u03f3"+ "\u03e4\3\2\2\2\u03f3\u03e5\3\2\2\2\u03f4\u00dd\3\2\2\2\u03f5\u03f6\7_"+ "\2\2\u03f6\u03f7\7\6\2\2\u03f7\u03f8\5\u00e0q\2\u03f8\u03f9\bp\1\2\u03f9"+ "\u00df\3\2\2\2\u03fa\u03fb\7\7\2\2\u03fb\u03fc\5\u00e2r\2\u03fc\u03fd"+ "\7m\2\2\u03fd\u03fe\5\u00c8e\2\u03fe\u03ff\7\b\2\2\u03ff\u0400\bq\1\2"+ "\u0400\u00e1\3\2\2\2\u0401\u0402\7n\2\2\u0402\u0410\br\1\2\u0403\u0404"+ "\7g\2\2\u0404\u0410\br\1\2\u0405\u0406\7h\2\2\u0406\u0410\br\1\2\u0407"+ "\u0408\7i\2\2\u0408\u0410\br\1\2\u0409\u040a\7j\2\2\u040a\u0410\br\1\2"+ "\u040b\u040c\7l\2\2\u040c\u0410\br\1\2\u040d\u040e\7k\2\2\u040e\u0410"+ "\br\1\2\u040f\u0401\3\2\2\2\u040f\u0403\3\2\2\2\u040f\u0405\3\2\2\2\u040f"+ "\u0407\3\2\2\2\u040f\u0409\3\2\2\2\u040f\u040b\3\2\2\2\u040f\u040d\3\2"+ "\2\2\u0410\u00e3\3\2\2\2\u0411\u0421\5\u00d6l\2\u0412\u0413\7\7\2\2\u0413"+ "\u0414\5\u00d2j\2\u0414\u041b\bs\1\2\u0415\u0416\7m\2\2\u0416\u0417\5"+ "\u00d2j\2\u0417\u0418\bs\1\2\u0418\u041a\3\2\2\2\u0419\u0415\3\2\2\2\u041a"+ "\u041d\3\2\2\2\u041b\u0419\3\2\2\2\u041b\u041c\3\2\2\2\u041c\u041e\3\2"+ "\2\2\u041d\u041b\3\2\2\2\u041e\u041f\7\b\2\2\u041f\u0421\3\2\2\2\u0420"+ "\u0411\3\2\2\2\u0420\u0412\3\2\2\2\u0421\u00e5\3\2\2\2\37\u00e9\u0177"+ "\u0193\u01e5\u01ef\u01f9\u01ff\u0205\u025c\u02ae\u02f3\u02f5\u0306\u030e"+ "\u033d\u0342\u0367\u036c\u0386\u038c\u03cc\u03d1\u03dd\u03e2\u03ee\u03f3"+ "\u040f\u041b\u0420"; public static final ATN _ATN = new ATNDeserializer().deserialize(_serializedATN.toCharArray()); static { _decisionToDFA = new DFA[_ATN.getNumberOfDecisions()]; for (int i = 0; i < _ATN.getNumberOfDecisions(); i++) { _decisionToDFA[i] = new DFA(_ATN.getDecisionState(i), i); } } }
245,819
0.669273
0.601764
7,303
31.660276
29.504276
465
false
false
0
0
72
0.002465
0
0
3.216349
false
false
5
80158ddfe159aba412b030d59c74bd29a951603d
19,997,367,779,029
49644796e57f427c3d106eb401ec5c352dd352e1
/app/src/main/java/com/squalle0nhart/hoctienganh/ui/activity/ConversationListActivity.java
c5d58f01c41d23a824b8cc846e5c63468b31b617
[]
no_license
squalle0nhart/hoctienganhmoingay
https://github.com/squalle0nhart/hoctienganhmoingay
4e649caee786666aba8520842a8f89824fa739f8
6b93e0d6c3010f20971efba064a00a060b559fc1
refs/heads/master
2020-04-06T09:49:09.347000
2018-11-13T09:56:24
2018-11-13T09:56:24
157,357,811
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
package com.squalle0nhart.hoctienganh.ui.activity; import android.app.Activity; import android.content.Context; import android.os.Bundle; import android.support.annotation.Nullable; import android.support.v7.widget.LinearLayoutManager; import android.support.v7.widget.RecyclerView; import com.squalle0nhart.hoctienganh.R; import com.squalle0nhart.hoctienganh.model.PharseInfo; import com.squalle0nhart.hoctienganh.ui.adapter.ConversationListAdapter; import com.squalle0nhart.hoctienganh.ui.view.EqualSpaceItemDecoration; import org.w3c.dom.Document; import org.w3c.dom.Element; import org.w3c.dom.Node; import org.w3c.dom.NodeList; import org.xml.sax.SAXException; import java.io.IOException; import java.io.InputStream; import java.util.ArrayList; import javax.xml.parsers.DocumentBuilder; import javax.xml.parsers.DocumentBuilderFactory; import javax.xml.parsers.ParserConfigurationException; /** * Created by squalleonhart on 3/19/2017. */ public class ConversationListActivity extends Activity { Context mContext; RecyclerView mRecycleView; ConversationListAdapter mConversationListAdapter; ArrayList<PharseInfo> mListPharse; @Override protected void onCreate(@Nullable Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_grammar); mContext = this; initView(); } private void initView() { mRecycleView = (RecyclerView) findViewById(R.id.rv_grammar); RecyclerView.LayoutManager layoutManager = new LinearLayoutManager(mContext); mRecycleView.setLayoutManager(layoutManager); mRecycleView.setHasFixedSize(true); mRecycleView.addItemDecoration(new EqualSpaceItemDecoration(10)); mListPharse = loadConversationListFromXML(); mConversationListAdapter = new ConversationListAdapter(mContext, mListPharse); mRecycleView.setAdapter(mConversationListAdapter); } /** * Lấy danh sách hội thoại file XML */ private ArrayList<PharseInfo> loadConversationListFromXML() { ArrayList<PharseInfo> listPharse = new ArrayList<>(); InputStream is = getResources().openRawResource(R.raw.lesson_titles); DocumentBuilderFactory documentBuilderFactory = DocumentBuilderFactory.newInstance(); try { DocumentBuilder documentBuilder = documentBuilderFactory.newDocumentBuilder(); Document document = documentBuilder.parse(is); Element root = document.getDocumentElement(); NodeList list = root.getChildNodes(); for (int i = 0; i < list.getLength(); i++) { Node note = list.item(i); if (note instanceof Element) { Element element = (Element) note; String enText = element.getAttribute("en_title"); String viText = element.getAttribute("local_title"); listPharse.add(new PharseInfo(enText, viText, 0)); } } } catch (ParserConfigurationException e) { e.printStackTrace(); } catch (SAXException e) { e.printStackTrace(); } catch (IOException e) { e.printStackTrace(); } return listPharse; } }
UTF-8
Java
3,294
java
ConversationListActivity.java
Java
[ { "context": "s.ParserConfigurationException;\n\n/**\n * Created by squalleonhart on 3/19/2017.\n */\n\npublic class ConversationListA", "end": 933, "score": 0.9995007514953613, "start": 920, "tag": "USERNAME", "value": "squalleonhart" } ]
null
[]
package com.squalle0nhart.hoctienganh.ui.activity; import android.app.Activity; import android.content.Context; import android.os.Bundle; import android.support.annotation.Nullable; import android.support.v7.widget.LinearLayoutManager; import android.support.v7.widget.RecyclerView; import com.squalle0nhart.hoctienganh.R; import com.squalle0nhart.hoctienganh.model.PharseInfo; import com.squalle0nhart.hoctienganh.ui.adapter.ConversationListAdapter; import com.squalle0nhart.hoctienganh.ui.view.EqualSpaceItemDecoration; import org.w3c.dom.Document; import org.w3c.dom.Element; import org.w3c.dom.Node; import org.w3c.dom.NodeList; import org.xml.sax.SAXException; import java.io.IOException; import java.io.InputStream; import java.util.ArrayList; import javax.xml.parsers.DocumentBuilder; import javax.xml.parsers.DocumentBuilderFactory; import javax.xml.parsers.ParserConfigurationException; /** * Created by squalleonhart on 3/19/2017. */ public class ConversationListActivity extends Activity { Context mContext; RecyclerView mRecycleView; ConversationListAdapter mConversationListAdapter; ArrayList<PharseInfo> mListPharse; @Override protected void onCreate(@Nullable Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_grammar); mContext = this; initView(); } private void initView() { mRecycleView = (RecyclerView) findViewById(R.id.rv_grammar); RecyclerView.LayoutManager layoutManager = new LinearLayoutManager(mContext); mRecycleView.setLayoutManager(layoutManager); mRecycleView.setHasFixedSize(true); mRecycleView.addItemDecoration(new EqualSpaceItemDecoration(10)); mListPharse = loadConversationListFromXML(); mConversationListAdapter = new ConversationListAdapter(mContext, mListPharse); mRecycleView.setAdapter(mConversationListAdapter); } /** * Lấy danh sách hội thoại file XML */ private ArrayList<PharseInfo> loadConversationListFromXML() { ArrayList<PharseInfo> listPharse = new ArrayList<>(); InputStream is = getResources().openRawResource(R.raw.lesson_titles); DocumentBuilderFactory documentBuilderFactory = DocumentBuilderFactory.newInstance(); try { DocumentBuilder documentBuilder = documentBuilderFactory.newDocumentBuilder(); Document document = documentBuilder.parse(is); Element root = document.getDocumentElement(); NodeList list = root.getChildNodes(); for (int i = 0; i < list.getLength(); i++) { Node note = list.item(i); if (note instanceof Element) { Element element = (Element) note; String enText = element.getAttribute("en_title"); String viText = element.getAttribute("local_title"); listPharse.add(new PharseInfo(enText, viText, 0)); } } } catch (ParserConfigurationException e) { e.printStackTrace(); } catch (SAXException e) { e.printStackTrace(); } catch (IOException e) { e.printStackTrace(); } return listPharse; } }
3,294
0.697901
0.691208
89
35.932583
25.025738
93
false
false
0
0
0
0
0
0
0.662921
false
false
5
b572028b16481b55cf07e3fed9f386002efebabe
1,013,612,351,322
14b23b02386063c8c161620fe4c750c971958e9c
/p2p-integration/src/main/java/com/icebreak/p2p/integration/openapi/order/RepaySubOrder.java
b514a65434810b98006e99b6d38a1aed13b6dd51
[]
no_license
RalphSu/789
https://github.com/RalphSu/789
d6d60fa0ae6131871d2cd4782c547cc76f1e08f6
1a066f6d0429e8490df03e4e11063533cbcaa217
refs/heads/master
2021-01-24T04:55:32.398000
2016-03-13T09:28:41
2016-03-13T09:28:41
52,210,852
0
0
null
true
2016-02-21T14:40:36
2016-02-21T14:40:36
2015-03-04T14:45:32
2015-03-04T14:45:27
25,072
0
0
0
null
null
null
package com.icebreak.p2p.integration.openapi.order; import org.springframework.util.Assert; import com.icebreak.util.service.Order; public class RepaySubOrder implements Order { private static final long serialVersionUID = -4785083019448254123L; /** 转账明细订单号 */ private String orderNo; /** 转账订单名称 */ private String tradeName = ""; /** 还款的收款人ID */ private String payeeUserId = ""; /** 分润金额 */ protected String transferAmount; /** 备注 */ private String memo = ""; @Override public void check() { Assert.hasText(orderNo); } public String getOrderNo() { return this.orderNo; } public void setOrderNo(String orderNo) { this.orderNo = orderNo; } public String getTradeName() { return this.tradeName; } public void setTradeName(String tradeName) { this.tradeName = tradeName; } public String getPayeeUserId() { return this.payeeUserId; } public void setPayeeUserId(String payeeUserId) { this.payeeUserId = payeeUserId; } public String getTransferAmount() { return this.transferAmount; } public void setTransferAmount(String transferAmount) { this.transferAmount = transferAmount; } public String getMemo() { return this.memo; } public void setMemo(String memo) { this.memo = memo; } }
UTF-8
Java
1,321
java
RepaySubOrder.java
Java
[]
null
[]
package com.icebreak.p2p.integration.openapi.order; import org.springframework.util.Assert; import com.icebreak.util.service.Order; public class RepaySubOrder implements Order { private static final long serialVersionUID = -4785083019448254123L; /** 转账明细订单号 */ private String orderNo; /** 转账订单名称 */ private String tradeName = ""; /** 还款的收款人ID */ private String payeeUserId = ""; /** 分润金额 */ protected String transferAmount; /** 备注 */ private String memo = ""; @Override public void check() { Assert.hasText(orderNo); } public String getOrderNo() { return this.orderNo; } public void setOrderNo(String orderNo) { this.orderNo = orderNo; } public String getTradeName() { return this.tradeName; } public void setTradeName(String tradeName) { this.tradeName = tradeName; } public String getPayeeUserId() { return this.payeeUserId; } public void setPayeeUserId(String payeeUserId) { this.payeeUserId = payeeUserId; } public String getTransferAmount() { return this.transferAmount; } public void setTransferAmount(String transferAmount) { this.transferAmount = transferAmount; } public String getMemo() { return this.memo; } public void setMemo(String memo) { this.memo = memo; } }
1,321
0.708104
0.692368
71
16.901409
17.296223
68
false
false
0
0
0
0
0
0
1.323944
false
false
13
fd0964ef59d8ba60f2ad455240076507f2e1005e
26,731,876,452,607
b4013ccf7408f84886ffe02667dcac4cccab544d
/src/main/java/com/datarank/api/util/strings/Strings.java
e8f876da33e85eef4ee2375983bdbb577f4623de
[]
no_license
datarank/datarank-java
https://github.com/datarank/datarank-java
403370bfc0a3791387019eaec2dff09e801ab1c3
77af7d4a5e65a798dda6e6096bc48404b897c421
refs/heads/master
2016-09-02T04:18:40.772000
2015-11-07T14:03:09
2015-11-07T14:03:09
34,058,407
2
0
null
false
2015-09-04T14:31:03
2015-04-16T13:48:00
2015-05-07T07:01:12
2015-09-04T14:31:03
288
2
0
5
Java
null
null
package com.datarank.api.util.strings; import java.util.List; /** * Created by kenny on 4/21/15. * * created to minimize dependencies */ public class Strings { public static String[] transform(final String[] from, final Transform transform) { final String[] to = new String[from.length]; for(int i = 0; i < from.length; i++) { to[i] = transform.transform(from[i]); } return to; } public static String[] fromLongs(final long[] from) { final String[] to = new String[from.length]; for(int i = 0; i < from.length; i++) { to[i] = String.valueOf(from[i]); } return to; } public static String join(final String[] array) { return join(array, ","); } public static String join(final String[] array, final String joiner) { final StringBuilder stringBuilder = new StringBuilder(); int i = 0; for(String from : array) { stringBuilder.append(from); if(i++ < array.length - 1) { stringBuilder.append(joiner); } } return stringBuilder.toString(); } public static String join(final List<?> list) { return join(list, ","); } public static String join(final List<?> list, final String joiner) { final StringBuilder stringBuilder = new StringBuilder(); int i = 0; for(Object from : list) { stringBuilder.append(from); if(i++ < list.size() - 1) { stringBuilder.append(joiner); } } return stringBuilder.toString(); } public static boolean isBlank(final String s) { return s == null || s.trim().length() == 0; } }
UTF-8
Java
1,759
java
Strings.java
Java
[ { "context": "trings;\n\nimport java.util.List;\n\n/**\n * Created by kenny on 4/21/15.\n *\n * created to minimize dependencie", "end": 87, "score": 0.992302417755127, "start": 82, "tag": "USERNAME", "value": "kenny" } ]
null
[]
package com.datarank.api.util.strings; import java.util.List; /** * Created by kenny on 4/21/15. * * created to minimize dependencies */ public class Strings { public static String[] transform(final String[] from, final Transform transform) { final String[] to = new String[from.length]; for(int i = 0; i < from.length; i++) { to[i] = transform.transform(from[i]); } return to; } public static String[] fromLongs(final long[] from) { final String[] to = new String[from.length]; for(int i = 0; i < from.length; i++) { to[i] = String.valueOf(from[i]); } return to; } public static String join(final String[] array) { return join(array, ","); } public static String join(final String[] array, final String joiner) { final StringBuilder stringBuilder = new StringBuilder(); int i = 0; for(String from : array) { stringBuilder.append(from); if(i++ < array.length - 1) { stringBuilder.append(joiner); } } return stringBuilder.toString(); } public static String join(final List<?> list) { return join(list, ","); } public static String join(final List<?> list, final String joiner) { final StringBuilder stringBuilder = new StringBuilder(); int i = 0; for(Object from : list) { stringBuilder.append(from); if(i++ < list.size() - 1) { stringBuilder.append(joiner); } } return stringBuilder.toString(); } public static boolean isBlank(final String s) { return s == null || s.trim().length() == 0; } }
1,759
0.554861
0.548039
64
26.484375
22.910145
86
false
false
0
0
0
0
0
0
0.53125
false
false
13
cf7d5aa0a58483693bc5966357b5bc921fbef61f
24,670,292,155,935
062a506ccf410981629f502480ebeb8a44791e9c
/Tarea3/LoginApp/app/src/main/java/com/androidatc/loginapp/MainActivity.java
a5fb8ebb9bc16db5859afd4a492b8bf8da91b56e
[]
no_license
EdgarPozas/Curso-Seguridad-Android
https://github.com/EdgarPozas/Curso-Seguridad-Android
86609fde67c6fdf4de49f1bf77afc8c8255983c4
934789ec114ee180956fc4a6742ea9bc34fc10ca
refs/heads/master
2021-01-11T21:22:20.712000
2017-01-12T18:49:58
2017-01-12T18:49:58
78,773,255
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
package com.androidatc.loginapp; import android.app.Activity; import android.content.Intent; import android.support.v7.app.AppCompatActivity; import android.os.Bundle; import android.view.Menu; import android.view.View; import android.widget.EditText; public class MainActivity extends Activity { EditText e1,e2; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_main); e1=(EditText) findViewById(R.id.editText1); e2=(EditText) findViewById(R.id.editText2); } public void submitInfo(View v){ Intent intent=new Intent(); intent.putExtra("Username",e1.getText().toString()); intent.putExtra("Password",e2.getText().toString()); intent.setClassName("com.androidatc.loginapp","com.androidatc.IntentReceiverActivity"); //intent.setAction("testlogin"); intent.addCategory(Intent.CATEGORY_DEFAULT); startActivity(intent); } }
UTF-8
Java
1,017
java
MainActivity.java
Java
[ { "context": ").toString());\n intent.putExtra(\"Password\",e2.getText().toString());\n intent.setClassName(\"com.a", "end": 773, "score": 0.8432313799858093, "start": 763, "tag": "PASSWORD", "value": "e2.getText" }, { "context": ";\n intent.putExtra(\"Password\",e2.getText().toString());\n intent.setClassName(\"com.androidatc.l", "end": 784, "score": 0.5418021082878113, "start": 776, "tag": "PASSWORD", "value": "toString" } ]
null
[]
package com.androidatc.loginapp; import android.app.Activity; import android.content.Intent; import android.support.v7.app.AppCompatActivity; import android.os.Bundle; import android.view.Menu; import android.view.View; import android.widget.EditText; public class MainActivity extends Activity { EditText e1,e2; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_main); e1=(EditText) findViewById(R.id.editText1); e2=(EditText) findViewById(R.id.editText2); } public void submitInfo(View v){ Intent intent=new Intent(); intent.putExtra("Username",e1.getText().toString()); intent.putExtra("Password",<PASSWORD>().<PASSWORD>()); intent.setClassName("com.androidatc.loginapp","com.androidatc.IntentReceiverActivity"); //intent.setAction("testlogin"); intent.addCategory(Intent.CATEGORY_DEFAULT); startActivity(intent); } }
1,019
0.711898
0.703048
32
30.78125
22.52878
95
false
false
0
0
0
0
0
0
0.75
false
false
13
36b259aafbab02bf17109c7d29bb7cc8759f15ed
532,575,975,411
f1affc0b0442a0968e5de27a751384c27e4adeda
/web/src/test/java/com/thor/pipeapple/Test.java
e727531019119f0afa53a43da797c540d09ffc46
[ "Apache-2.0" ]
permissive
lyjloveabc/pineapple
https://github.com/lyjloveabc/pineapple
439a2b8e730169ea14ceac179502fb355c2c4493
968dd1a37bca1b83bfd51e0fc16d739ed18538e8
refs/heads/master
2017-10-10T16:57:44.190000
2017-05-08T11:28:00
2017-05-08T11:28:00
85,387,081
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
package com.thor.pipeapple; import com.google.common.collect.Lists; import com.google.common.collect.Maps; import java.io.UnsupportedEncodingException; import java.net.URLEncoder; import java.util.ArrayList; import java.util.Collections; import java.util.Map; /** * Created by Thor on 2017/3/3. * happy coding - 1203! */ public class Test { public static void main(String[] args) throws UnsupportedEncodingException { Map<String, String> params = Maps.newConcurrentMap(); params.put("SignatureVersion", "1.0"); params.put("Format", "JSON"); params.put("Timestamp", "2015-08-06T02:19:46Z"); params.put("AccessKeyId", "testid"); params.put("SignatureMethod", "HMAC-SHA1"); params.put("Version", "2014-11-11"); params.put("Action", "DescribeCdnService"); params.put("SignatureNonce", "9b7a44b0-3be1-11e5-8c73-08002700c460"); StringBuffer content = new StringBuffer(); ArrayList<String> keys = Lists.newArrayList(params.keySet()); Collections.sort(keys); for (int i = 0; i < keys.size(); ++i) { String key = keys.get(i); String value = params.get(key); content.append(i == 0 ? "" : "&").append(key).append("=").append(value); } //System.out.println(content); String encodeString = URLEncoder.encode(content.toString(), "UTF-8"); System.out.println(encodeString); System.out.println(URLEncoder.encode("/", "UTF-8")); System.out.println(URLEncoder.encode("&", "UTF-8")); } } //GET&%2F&AccessKeyId%3Dtestid%26Action%3DDescribeCdnService%26Format%3DJSON%26SignatureMethod%3DHMAC-SHA1%26SignatureNonce%3D9b7a44b0-3be1-11e5-8c73-08002700c460%26SignatureVersion%3D1.0%26Timestamp%3D2015-08-06T02%3A19%3A46Z%26Version%3D2014-11-11 //GET&%2F&AccessKeyId%3Dtestid&Action%3DDescribeCdnService&Format%3DJSON&SignatureMethod%3DHMAC-SHA1&SignatureNonce%3D9b7a44b0-3be1-11e5-8c73-08002700c460&SignatureVersion%3D1.0&Timestamp%3D2015-08-06T02%253A19%253A46Z&Version%3D2014-11-11
UTF-8
Java
2,069
java
Test.java
Java
[ { "context": "lections;\nimport java.util.Map;\n\n/**\n * Created by Thor on 2017/3/3.\n * happy coding - 1203!\n */\npublic c", "end": 285, "score": 0.9968780279159546, "start": 281, "tag": "USERNAME", "value": "Thor" }, { "context": "6T02:19:46Z\");\n params.put(\"AccessKeyId\", \"testid\");\n params.put(\"SignatureMethod\", \"HMAC-SH", "end": 673, "score": 0.9987616539001465, "start": 667, "tag": "KEY", "value": "testid" }, { "context": "6Version%3D2014-11-11\n//GET&%2F&AccessKeyId%3Dtestid&Action%3DDescribeCdnService&Format%3DJSON&Signatu", "end": 1860, "score": 0.6837122440338135, "start": 1858, "tag": "KEY", "value": "id" } ]
null
[]
package com.thor.pipeapple; import com.google.common.collect.Lists; import com.google.common.collect.Maps; import java.io.UnsupportedEncodingException; import java.net.URLEncoder; import java.util.ArrayList; import java.util.Collections; import java.util.Map; /** * Created by Thor on 2017/3/3. * happy coding - 1203! */ public class Test { public static void main(String[] args) throws UnsupportedEncodingException { Map<String, String> params = Maps.newConcurrentMap(); params.put("SignatureVersion", "1.0"); params.put("Format", "JSON"); params.put("Timestamp", "2015-08-06T02:19:46Z"); params.put("AccessKeyId", "testid"); params.put("SignatureMethod", "HMAC-SHA1"); params.put("Version", "2014-11-11"); params.put("Action", "DescribeCdnService"); params.put("SignatureNonce", "9b7a44b0-3be1-11e5-8c73-08002700c460"); StringBuffer content = new StringBuffer(); ArrayList<String> keys = Lists.newArrayList(params.keySet()); Collections.sort(keys); for (int i = 0; i < keys.size(); ++i) { String key = keys.get(i); String value = params.get(key); content.append(i == 0 ? "" : "&").append(key).append("=").append(value); } //System.out.println(content); String encodeString = URLEncoder.encode(content.toString(), "UTF-8"); System.out.println(encodeString); System.out.println(URLEncoder.encode("/", "UTF-8")); System.out.println(URLEncoder.encode("&", "UTF-8")); } } //GET&%2F&AccessKeyId%3Dtestid%26Action%3DDescribeCdnService%26Format%3DJSON%26SignatureMethod%3DHMAC-SHA1%26SignatureNonce%3D9b7a44b0-3be1-11e5-8c73-08002700c460%26SignatureVersion%3D1.0%26Timestamp%3D2015-08-06T02%3A19%3A46Z%26Version%3D2014-11-11 //GET&%2F&AccessKeyId%3Dtestid&Action%3DDescribeCdnService&Format%3DJSON&SignatureMethod%3DHMAC-SHA1&SignatureNonce%3D9b7a44b0-3be1-11e5-8c73-08002700c460&SignatureVersion%3D1.0&Timestamp%3D2015-08-06T02%253A19%253A46Z&Version%3D2014-11-11
2,069
0.687289
0.589657
52
38.807693
48.010029
249
false
false
0
0
0
0
0
0
0.807692
false
false
13
ba6c9269b9c21517182f93389758ca0f64b58795
10,084,583,220,320
57cc9cd2dfabfafa49ae363bf353e3cdf6246f0b
/project-webmagic-learn/src/main/java/xyy/java/note/webmagic/scheduler/QueueScheduler.java
3498ae464085e6e822d6d8cba60786728aa3864b
[ "Apache-2.0" ]
permissive
i37oC/java-note
https://github.com/i37oC/java-note
44902d8e6ee0b3218ff5e20941a8e1822504a3fb
5c5e43ccb161e03cda5fcf014a6cd5acaafe14db
refs/heads/master
2020-04-16T01:45:10.813000
2017-06-15T09:53:48
2017-06-15T09:53:48
83,394,700
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
package xyy.java.note.webmagic.scheduler; import xyy.java.note.webmagic.Request; import xyy.java.note.webmagic.Task; import java.util.concurrent.BlockingDeque; import java.util.concurrent.LinkedBlockingDeque; /** * @author xyy * @version 1.0 2017/4/13. * @since 1.0 */ public class QueueScheduler extends DuplicateRemovedScheduler implements MonitorableScheduler{ private BlockingDeque<Request> queque = new LinkedBlockingDeque<>(); @Override public int getLeftReqeustsCount(Task task) { return 0; } @Override public int getTotalReqeustCount(Task task) { return 0; } @Override public Request poll(Task task) { return null; } @Override protected void pushWhenNoDuplicate(Request request, Task task) { } }
UTF-8
Java
793
java
QueueScheduler.java
Java
[ { "context": "l.concurrent.LinkedBlockingDeque;\n\n\n/**\n * @author xyy\n * @version 1.0 2017/4/13.\n * @since 1.0\n */\npubl", "end": 231, "score": 0.9996428489685059, "start": 228, "tag": "USERNAME", "value": "xyy" } ]
null
[]
package xyy.java.note.webmagic.scheduler; import xyy.java.note.webmagic.Request; import xyy.java.note.webmagic.Task; import java.util.concurrent.BlockingDeque; import java.util.concurrent.LinkedBlockingDeque; /** * @author xyy * @version 1.0 2017/4/13. * @since 1.0 */ public class QueueScheduler extends DuplicateRemovedScheduler implements MonitorableScheduler{ private BlockingDeque<Request> queque = new LinkedBlockingDeque<>(); @Override public int getLeftReqeustsCount(Task task) { return 0; } @Override public int getTotalReqeustCount(Task task) { return 0; } @Override public Request poll(Task task) { return null; } @Override protected void pushWhenNoDuplicate(Request request, Task task) { } }
793
0.704918
0.688525
37
20.432432
23.442327
94
false
false
0
0
0
0
0
0
0.27027
false
false
13
af9dc2a9acd7a2f2735bee98b30d4ac46eb37a86
37,288,906,092,638
d7fd036c017138899797eaa76e9905283df63d69
/app/src/main/java/com/example/acgallery/Model/Comparators/NameComparator.java
b8a8f64fdaca7c75bf2b93efd72f770715d69b48
[]
no_license
cio24/Tp-Final-Objetos
https://github.com/cio24/Tp-Final-Objetos
3151d94a53188fdb84db27d5d4a5d7dd833c6526
5c8e834029b23cf31ba958f3ad16e05a836f373a
refs/heads/master
2022-12-18T14:53:18.120000
2020-09-24T18:16:43
2020-09-24T18:16:43
234,602,956
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
package com.example.acgallery.Model.Comparators; import com.example.acgallery.Model.Composite.AbstractFile; import java.io.Serializable; public class NameComparator implements Comparable, Serializable { @Override public boolean lessThan(AbstractFile a, AbstractFile b){ for(int i = 0; i < Math.min(a.getName().length(),b.getName().length()); i++){ if(a.getName().toLowerCase().charAt(i) != b.getName().toLowerCase().charAt(i)) return a.getName().toLowerCase().charAt(i) < b.getName().toLowerCase().charAt(i); } return false; } }
UTF-8
Java
595
java
NameComparator.java
Java
[]
null
[]
package com.example.acgallery.Model.Comparators; import com.example.acgallery.Model.Composite.AbstractFile; import java.io.Serializable; public class NameComparator implements Comparable, Serializable { @Override public boolean lessThan(AbstractFile a, AbstractFile b){ for(int i = 0; i < Math.min(a.getName().length(),b.getName().length()); i++){ if(a.getName().toLowerCase().charAt(i) != b.getName().toLowerCase().charAt(i)) return a.getName().toLowerCase().charAt(i) < b.getName().toLowerCase().charAt(i); } return false; } }
595
0.667227
0.665546
16
36.25
34.189728
97
false
false
0
0
0
0
0
0
0.625
false
false
13
f31b1d37c451fc1daf5825b0ea67e3b0d5d0e65d
17,154,099,432,024
e8c4b662c615da3ec501674063697fe72242d5cd
/src/main/java/lettcode/Q100/Q148.java
98a5ca4d4f4b4d136b637a4736b48e89212bee29
[]
no_license
wangzd4661/algorithm
https://github.com/wangzd4661/algorithm
d1b27133ea3d494b47cc1e5d39e232a237034b48
37e25c9b939eb12ee1e9cd80880da8b8881657c3
refs/heads/master
2022-01-19T17:46:20.908000
2022-01-18T02:48:21
2022-01-18T02:48:21
156,797,783
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
package lettcode.Q100; import lettcode.tree.ListNode; public class Q148 { public ListNode sortList(ListNode head) { if (head == null || head.next == null) return head; ListNode fast = head, slow = head, pre = head; while (fast != null && fast.next != null) { pre = slow; slow = slow.next; fast = fast.next.next; } pre.next = null; return merge(sortList(head), sortList(slow)); } private ListNode merge(ListNode l1, ListNode l2) { if (l1 == null) return l2; if (l2 == null) return l1; if (l1.val < l2.val) { l1.next = merge(l1.next, l2); return l1; } else { l2.next = merge(l1, l2.next); return l2; } } public static void main(String[] args) { ListNode node=new Q148().sortList(new ListNode(new int[]{4, 2, 1, 3})); System.out.println(node); } }
UTF-8
Java
961
java
Q148.java
Java
[]
null
[]
package lettcode.Q100; import lettcode.tree.ListNode; public class Q148 { public ListNode sortList(ListNode head) { if (head == null || head.next == null) return head; ListNode fast = head, slow = head, pre = head; while (fast != null && fast.next != null) { pre = slow; slow = slow.next; fast = fast.next.next; } pre.next = null; return merge(sortList(head), sortList(slow)); } private ListNode merge(ListNode l1, ListNode l2) { if (l1 == null) return l2; if (l2 == null) return l1; if (l1.val < l2.val) { l1.next = merge(l1.next, l2); return l1; } else { l2.next = merge(l1, l2.next); return l2; } } public static void main(String[] args) { ListNode node=new Q148().sortList(new ListNode(new int[]{4, 2, 1, 3})); System.out.println(node); } }
961
0.523413
0.493236
34
27.264706
20.016624
79
false
false
0
0
0
0
0
0
0.823529
false
false
13
c5897390d9939dfa7de194ddfb57adfbce3aebf2
38,173,669,348,721
28dc7ef397c32aedca13ab5f685394b81a8ea7aa
/src/main/java/fr/heavenmoon/lobby/listeners/GlobalFixer.java
b56097aadc41fce43c7cffaeb7e53f11551717cc
[]
no_license
HeavenMoon/MoonLobby
https://github.com/HeavenMoon/MoonLobby
41ab20b3ad112162515143f277fcb647c6cb4312
7265fc0dceee21fe462e3b666f28091c08d5b6cc
refs/heads/master
2023-03-07T17:19:06.657000
2021-02-19T10:56:49
2021-02-19T10:56:49
338,448,107
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
package fr.heavenmoon.lobby.listeners; import fr.heavenmoon.core.bukkit.MoonBukkitCore; import fr.heavenmoon.lobby.MoonLobby; import fr.heavenmoon.persistanceapi.customs.player.CustomPlayer; import fr.heavenmoon.persistanceapi.customs.player.data.RankList; import org.bukkit.Bukkit; import org.bukkit.Location; import org.bukkit.World; import org.bukkit.entity.Animals; import org.bukkit.entity.Monster; import org.bukkit.entity.Player; import org.bukkit.event.EventHandler; import org.bukkit.event.Listener; import org.bukkit.event.block.BlockBreakEvent; import org.bukkit.event.block.BlockPlaceEvent; import org.bukkit.event.entity.*; import org.bukkit.event.inventory.InventoryClickEvent; import org.bukkit.event.player.PlayerDropItemEvent; import org.bukkit.event.player.PlayerMoveEvent; import org.bukkit.event.weather.WeatherChangeEvent; public class GlobalFixer implements Listener { private final MoonLobby plugin; public GlobalFixer(MoonLobby plugin) { this.plugin = plugin; } @EventHandler public void on(EntityDamageEvent event) { event.setCancelled(true); } @EventHandler public void on(FoodLevelChangeEvent event) { event.setCancelled(true); } @EventHandler public void on(WeatherChangeEvent event) { event.setCancelled(true); } @EventHandler public void on(EntitySpawnEvent event) { if (event.getEntity() instanceof Monster || event.getEntity() instanceof Animals) event.setCancelled(true); } @EventHandler public void on(PlayerDropItemEvent event) { event.setCancelled(true); } @EventHandler public void on(PlayerDeathEvent event) { Bukkit.getScheduler().scheduleSyncDelayedTask(plugin, () -> event.getEntity().spigot().respawn(), 1L); } @EventHandler public void on(BlockBreakEvent event) { Player player = event.getPlayer(); CustomPlayer customPlayer = plugin.getPersistanceManager().getPlayerManager().getCustomPlayer(player.getUniqueId()); if (customPlayer.getModerationData().isBypass()) return; event.setCancelled(true); } @EventHandler public void on(BlockPlaceEvent event) { Player player = event.getPlayer(); CustomPlayer customPlayer = plugin.getPersistanceManager().getPlayerManager().getCustomPlayer(player.getUniqueId()); if (customPlayer.getModerationData().isBypass()) return; event.setCancelled(true); } @EventHandler public void on(PlayerMoveEvent event) { Player player = event.getPlayer(); if (player.getLocation().getY() <= 43) { CustomPlayer customPlayer = plugin.getPersistanceManager().getPlayerManager().getCustomPlayer(player.getUniqueId()); if (customPlayer.getModerationData().isBypass()) return; Location spawn = new Location(Bukkit.getWorld("lobby"), 283.5, 74, -216.5, 0.0F, 0.0F); event.getPlayer().teleport(spawn); } } @EventHandler public void on(InventoryClickEvent event) { Player player = (Player) event.getView().getPlayer(); CustomPlayer customPlayer = plugin.getPersistanceManager().getPlayerManager().getCustomPlayer(player.getUniqueId()); if (customPlayer.getModerationData().isBypass() && (!event.getView().getTitle().equals("Navigation") || !event.getView().getTitle().equals("Boutique"))) return; event.setCancelled(true); } @EventHandler public void on(EntityChangeBlockEvent event) { event.setCancelled(true); } }
UTF-8
Java
3,579
java
GlobalFixer.java
Java
[]
null
[]
package fr.heavenmoon.lobby.listeners; import fr.heavenmoon.core.bukkit.MoonBukkitCore; import fr.heavenmoon.lobby.MoonLobby; import fr.heavenmoon.persistanceapi.customs.player.CustomPlayer; import fr.heavenmoon.persistanceapi.customs.player.data.RankList; import org.bukkit.Bukkit; import org.bukkit.Location; import org.bukkit.World; import org.bukkit.entity.Animals; import org.bukkit.entity.Monster; import org.bukkit.entity.Player; import org.bukkit.event.EventHandler; import org.bukkit.event.Listener; import org.bukkit.event.block.BlockBreakEvent; import org.bukkit.event.block.BlockPlaceEvent; import org.bukkit.event.entity.*; import org.bukkit.event.inventory.InventoryClickEvent; import org.bukkit.event.player.PlayerDropItemEvent; import org.bukkit.event.player.PlayerMoveEvent; import org.bukkit.event.weather.WeatherChangeEvent; public class GlobalFixer implements Listener { private final MoonLobby plugin; public GlobalFixer(MoonLobby plugin) { this.plugin = plugin; } @EventHandler public void on(EntityDamageEvent event) { event.setCancelled(true); } @EventHandler public void on(FoodLevelChangeEvent event) { event.setCancelled(true); } @EventHandler public void on(WeatherChangeEvent event) { event.setCancelled(true); } @EventHandler public void on(EntitySpawnEvent event) { if (event.getEntity() instanceof Monster || event.getEntity() instanceof Animals) event.setCancelled(true); } @EventHandler public void on(PlayerDropItemEvent event) { event.setCancelled(true); } @EventHandler public void on(PlayerDeathEvent event) { Bukkit.getScheduler().scheduleSyncDelayedTask(plugin, () -> event.getEntity().spigot().respawn(), 1L); } @EventHandler public void on(BlockBreakEvent event) { Player player = event.getPlayer(); CustomPlayer customPlayer = plugin.getPersistanceManager().getPlayerManager().getCustomPlayer(player.getUniqueId()); if (customPlayer.getModerationData().isBypass()) return; event.setCancelled(true); } @EventHandler public void on(BlockPlaceEvent event) { Player player = event.getPlayer(); CustomPlayer customPlayer = plugin.getPersistanceManager().getPlayerManager().getCustomPlayer(player.getUniqueId()); if (customPlayer.getModerationData().isBypass()) return; event.setCancelled(true); } @EventHandler public void on(PlayerMoveEvent event) { Player player = event.getPlayer(); if (player.getLocation().getY() <= 43) { CustomPlayer customPlayer = plugin.getPersistanceManager().getPlayerManager().getCustomPlayer(player.getUniqueId()); if (customPlayer.getModerationData().isBypass()) return; Location spawn = new Location(Bukkit.getWorld("lobby"), 283.5, 74, -216.5, 0.0F, 0.0F); event.getPlayer().teleport(spawn); } } @EventHandler public void on(InventoryClickEvent event) { Player player = (Player) event.getView().getPlayer(); CustomPlayer customPlayer = plugin.getPersistanceManager().getPlayerManager().getCustomPlayer(player.getUniqueId()); if (customPlayer.getModerationData().isBypass() && (!event.getView().getTitle().equals("Navigation") || !event.getView().getTitle().equals("Boutique"))) return; event.setCancelled(true); } @EventHandler public void on(EntityChangeBlockEvent event) { event.setCancelled(true); } }
3,579
0.710254
0.705504
102
34.088234
32.689899
160
false
false
0
0
0
0
0
0
0.558824
false
false
13
8ce45c5d9b91d0ce247b1bf1c9e91473ffdc12e9
36,009,005,853,964
ee17accc35b1d3a36898c4a56694fcbcd036b8e9
/TidyNumbers/src/UI/main.java
3b108ae6023c044b5ec7b504e47b72cea3b4021e
[]
no_license
mohamedhalim1998/Java
https://github.com/mohamedhalim1998/Java
6f95570288bc729862a9ba931cc4bcf4c2238568
e3ca4b5382c108fe24060eaa03d510f9c2e74373
refs/heads/master
2020-05-31T05:14:15.249000
2019-06-05T02:38:54
2019-06-05T02:38:54
190,115,474
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
package UI; import java.util.Arrays; public class main { public static void main(String[] args) { int t = 265184791; t = Integer.reverse(t); char[] arr = ("" + t).toCharArray(); // t = getTidyNum(arr); System.out.println(); } /** * @param arr : a char array of the numbers * @return int of tidy number * * given an array of number gets the closest tidy number of it */ public static int getTidyNum(char[] arr){ int result = 0; char[] subArr; for (int i = 0;i < arr.length-1 ;i++){ int present = Character.getNumericValue(arr[i]); int next = Character.getNumericValue(arr[i+1]); if(next > present) { if (present == 1) { subArr = Arrays.copyOfRange(arr,i+1 , arr.length -1); result = Integer.valueOf(new String(arr)) - Integer.valueOf(new String(subArr)) -1; return result; } else { arr[i+1] = ("" + (present)).charAt(0); } } } result = Integer.valueOf(new String(arr)); return result; } /** * @param arr : a char array of numbers * @return boolean * * return true if the number can be tidy by * the same number of digits */ boolean sameDigitsNumber(char [] arr){ return arr[arr.length - 1] > 1 ; } }
UTF-8
Java
1,465
java
main.java
Java
[]
null
[]
package UI; import java.util.Arrays; public class main { public static void main(String[] args) { int t = 265184791; t = Integer.reverse(t); char[] arr = ("" + t).toCharArray(); // t = getTidyNum(arr); System.out.println(); } /** * @param arr : a char array of the numbers * @return int of tidy number * * given an array of number gets the closest tidy number of it */ public static int getTidyNum(char[] arr){ int result = 0; char[] subArr; for (int i = 0;i < arr.length-1 ;i++){ int present = Character.getNumericValue(arr[i]); int next = Character.getNumericValue(arr[i+1]); if(next > present) { if (present == 1) { subArr = Arrays.copyOfRange(arr,i+1 , arr.length -1); result = Integer.valueOf(new String(arr)) - Integer.valueOf(new String(subArr)) -1; return result; } else { arr[i+1] = ("" + (present)).charAt(0); } } } result = Integer.valueOf(new String(arr)); return result; } /** * @param arr : a char array of numbers * @return boolean * * return true if the number can be tidy by * the same number of digits */ boolean sameDigitsNumber(char [] arr){ return arr[arr.length - 1] > 1 ; } }
1,465
0.506485
0.49215
51
27.725491
22.301041
103
false
false
0
0
0
0
0
0
0.431373
false
false
13
3705bb91c3c7cbd3bad979e1cb9541325f166e7f
39,384,850,124,443
411160edab67835a023158ccbfd0036c7c155828
/Codigo/ProyectoSAF/src/java/SAF/Facade/Stock/FacadeStock.java
952f78c71682d819f50d4d12c0ba20f5c92744e2
[]
no_license
mdf27/springapp
https://github.com/mdf27/springapp
8186493c2d81c66715910b251a7d572ddcb74759
f455f8007193193fc13da0fc54d3cd0615171c80
refs/heads/master
2021-01-13T02:03:16.996000
2014-10-03T04:02:49
2014-10-03T04:02:49
null
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
/* * To change this license header, choose License Headers in Project Properties. * To change this template file, choose Tools | Templates * and open the template in the editor. */ package SAF.Facade.Stock; import SAF.Logica.Stock.AjustarStockManager; import SAF.Logica.Stock.BuscarProductoManager; import SAF.Logica.Stock.ModificarProductoManager; import SAF.VO.Stock.DatosCompletosMedProdVO; import SAF.VO.Stock.ProductoVO; import SAF.VO.Stock.StockVO; import java.io.IOException; import java.sql.SQLException; import java.util.Date; import java.util.Iterator; import java.util.List; import java.util.Map; import org.apache.lucene.queryparser.classic.ParseException; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; /** * * @author majo */ @Service public class FacadeStock { @Autowired BuscarProductoManager bpm; @Autowired AjustarStockManager atm; // @Autowired // ModificarProductoManager mpm; public List<DatosCompletosMedProdVO> buscarProducto(String texto_buscar, String filtro) throws ClassNotFoundException, ParseException, SQLException, IOException, java.text.ParseException{ return bpm.buscarProducto(texto_buscar, filtro); } public List<DatosCompletosMedProdVO> ajustarStock() throws ClassNotFoundException, ParseException, SQLException, IOException, java.text.ParseException{ return atm.ajustarStock(); } public void ajustarCantidadStock (int idProducto, int cantidad) throws java.text.ParseException, ClassNotFoundException, SQLException, IOException, ParseException{ StockVO stock = new StockVO(); stock.setCantidad(cantidad); stock.setIdProducto(idProducto); atm.ajustarCantidadStock(stock); } @Autowired ModificarProductoManager mpm; public Map <String, List<ProductoVO>> actualizarProductosDUSA(Date fecha) { Map <String, List<ProductoVO>> ret = mpm.actualizarProductosDUSA(fecha); return ret; //return mpm.actualizarProductosDUSA(fecha); } }
UTF-8
Java
2,157
java
FacadeStock.java
Java
[ { "context": "amework.stereotype.Service;\r\n\r\n/**\r\n *\r\n * @author majo\r\n */\r\n@Service\r\npublic class FacadeStock {\r\n @", "end": 832, "score": 0.9755371809005737, "start": 828, "tag": "USERNAME", "value": "majo" } ]
null
[]
/* * To change this license header, choose License Headers in Project Properties. * To change this template file, choose Tools | Templates * and open the template in the editor. */ package SAF.Facade.Stock; import SAF.Logica.Stock.AjustarStockManager; import SAF.Logica.Stock.BuscarProductoManager; import SAF.Logica.Stock.ModificarProductoManager; import SAF.VO.Stock.DatosCompletosMedProdVO; import SAF.VO.Stock.ProductoVO; import SAF.VO.Stock.StockVO; import java.io.IOException; import java.sql.SQLException; import java.util.Date; import java.util.Iterator; import java.util.List; import java.util.Map; import org.apache.lucene.queryparser.classic.ParseException; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; /** * * @author majo */ @Service public class FacadeStock { @Autowired BuscarProductoManager bpm; @Autowired AjustarStockManager atm; // @Autowired // ModificarProductoManager mpm; public List<DatosCompletosMedProdVO> buscarProducto(String texto_buscar, String filtro) throws ClassNotFoundException, ParseException, SQLException, IOException, java.text.ParseException{ return bpm.buscarProducto(texto_buscar, filtro); } public List<DatosCompletosMedProdVO> ajustarStock() throws ClassNotFoundException, ParseException, SQLException, IOException, java.text.ParseException{ return atm.ajustarStock(); } public void ajustarCantidadStock (int idProducto, int cantidad) throws java.text.ParseException, ClassNotFoundException, SQLException, IOException, ParseException{ StockVO stock = new StockVO(); stock.setCantidad(cantidad); stock.setIdProducto(idProducto); atm.ajustarCantidadStock(stock); } @Autowired ModificarProductoManager mpm; public Map <String, List<ProductoVO>> actualizarProductosDUSA(Date fecha) { Map <String, List<ProductoVO>> ret = mpm.actualizarProductosDUSA(fecha); return ret; //return mpm.actualizarProductosDUSA(fecha); } }
2,157
0.732499
0.732499
61
33.327869
37.913502
191
false
false
0
0
0
0
0
0
0.803279
false
false
13
6b68fc53fc77d6db3910589f17e92d1b29e59141
4,269,197,559,414
7204bbdf8d82ba2527f849952c902084443bb0c2
/src/main/java/com/zcon/mobileris/config/ProjectConstants.java
e7bc5c0b1ddb15e57011e16048b7840cfff5b39d
[]
no_license
manojk-ct/test
https://github.com/manojk-ct/test
c9a6c4ec21c9815cbc1f82cb079221c8f2756456
8ebee57f2e7754166a5c50fb24075246d87e40e7
refs/heads/master
2021-05-02T05:39:39.712000
2016-12-21T17:25:05
2016-12-21T17:25:05
77,071,476
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
package com.zcon.mobileris.config; public class ProjectConstants { public static final String TEMP_FILE_UPLOAD_DIR = "D:\\test\\"; public static final String FINAL_FILE_UPLOAD_DIR = "D:\\MobileRIS_Files\\Tenent_1\\User_ProfilePhoto\\"; public static final long MAX_MULTIPART_REQUEST_SIZE = 20971520; public static final long MAX_FILE_SIZE = 5242880; public static final int THRESHOLD_FILE_SIZE = 0; }
UTF-8
Java
422
java
ProjectConstants.java
Java
[]
null
[]
package com.zcon.mobileris.config; public class ProjectConstants { public static final String TEMP_FILE_UPLOAD_DIR = "D:\\test\\"; public static final String FINAL_FILE_UPLOAD_DIR = "D:\\MobileRIS_Files\\Tenent_1\\User_ProfilePhoto\\"; public static final long MAX_MULTIPART_REQUEST_SIZE = 20971520; public static final long MAX_FILE_SIZE = 5242880; public static final int THRESHOLD_FILE_SIZE = 0; }
422
0.732228
0.691943
9
45.888889
32.181583
108
false
false
0
0
0
0
0
0
0.666667
false
false
13
49bb7f44fab88e8cd1025c2b55ac4e9498d11f83
4,269,197,558,795
3f380ad21c38733ff1852daf86e67c91941bcb8f
/src/main/java/com/amazonaws/fps/mock/AmazonFPSMock.java
311d548a3d066c68d661e55d6e3d2ffc61ecb9f8
[]
no_license
justinedelson/amazon-fps-client
https://github.com/justinedelson/amazon-fps-client
04f1fdedd1fed06e8be396b148f5d68a95c1670b
fa3543931af1c820f94ce4e42d394558ebc4c920
refs/heads/master
2016-09-16T01:28:54.295000
2010-02-11T21:49:55
2010-02-11T21:49:55
null
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
/******************************************************************************* * Copyright 2008 Amazon Technologies, Inc. * Licensed under the Apache License, Version 2.0 (the "License"); * * You may not use this file except in compliance with the License. * You may obtain a copy of the License at: http://aws.amazon.com/apache2.0 * This file is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR * CONDITIONS OF ANY KIND, either express or implied. See the License for the * specific language governing permissions and limitations under the License. * ***************************************************************************** * __ _ _ ___ * ( )( \/\/ )/ __) * /__\ \ / \__ \ * (_)(_) \/\/ (___/ * * Amazon FPS Java Library * API Version: 2008-09-17 * Generated: Tue Sep 29 03:25:00 PDT 2009 * */ package com.amazonaws.fps.mock; import com.amazonaws.fps.model.*; import com.amazonaws.fps.*; import javax.xml.bind.JAXBContext; import javax.xml.bind.JAXBException; import javax.xml.bind.Unmarshaller; import org.apache.commons.logging.Log; import org.apache.commons.logging.LogFactory; import org.xml.sax.InputSource; /** * * AmazonFPSMock is the implementation of AmazonFPS based on the pre-populated * set of XML files that serve local data. It simulates responses from Amazon * FPS service. * * Use this to test your application without making a call to Amazon FPS * * Note, current Mock Service implementation does not valiadate requests * */ public class AmazonFPSMock implements AmazonFPS { private final Log log = LogFactory.getLog(AmazonFPSMock.class); private static JAXBContext jaxbContext; private static ThreadLocal<Unmarshaller> unmarshaller; /** Initialize JAXBContext and Unmarshaller **/ static { try { jaxbContext = JAXBContext.newInstance("com.amazonaws.fps.model", AmazonFPS.class.getClassLoader()); } catch (JAXBException ex) { throw new ExceptionInInitializerError(ex); } unmarshaller = new ThreadLocal<Unmarshaller>() { protected synchronized Unmarshaller initialValue() { try { return jaxbContext.createUnmarshaller(); } catch (JAXBException e) { throw new ExceptionInInitializerError(e); } } }; } // Public API ------------------------------------------------------------// /** * Cancel Token * * * Cancels any token installed by the calling application on its own * account. * * @param request CancelToken Action * @return CancelToken Response from the service * * @throws AmazonFPSException */ public CancelTokenResponse cancelToken(CancelTokenRequest request) throws AmazonFPSException { CancelTokenResponse response; try { response = (CancelTokenResponse) getUnmarshaller().unmarshal( new InputSource(this.getClass().getResourceAsStream("CancelTokenResponse.xml"))); log.debug("Response from Mock Service: " + response.toXML()); } catch (JAXBException jbe) { throw new AmazonFPSException("Unable to process mock response", jbe); } return response; } /** * Cancel * * * Cancels an ongoing transaction and puts it in cancelled state. * * @param request Cancel Action * @return Cancel Response from the service * * @throws AmazonFPSException */ public CancelResponse cancel(CancelRequest request) throws AmazonFPSException { CancelResponse response; try { response = (CancelResponse) getUnmarshaller().unmarshal( new InputSource(this.getClass().getResourceAsStream("CancelResponse.xml"))); log.debug("Response from Mock Service: " + response.toXML()); } catch (JAXBException jbe) { throw new AmazonFPSException("Unable to process mock response", jbe); } return response; } /** * Fund Prepaid * * * Funds the prepaid balance on the given prepaid instrument. * * @param request FundPrepaid Action * @return FundPrepaid Response from the service * * @throws AmazonFPSException */ public FundPrepaidResponse fundPrepaid(FundPrepaidRequest request) throws AmazonFPSException { FundPrepaidResponse response; try { response = (FundPrepaidResponse) getUnmarshaller().unmarshal( new InputSource(this.getClass().getResourceAsStream("FundPrepaidResponse.xml"))); log.debug("Response from Mock Service: " + response.toXML()); } catch (JAXBException jbe) { throw new AmazonFPSException("Unable to process mock response", jbe); } return response; } /** * Get Account Activity * * * Returns transactions for a given date range. * * @param request GetAccountActivity Action * @return GetAccountActivity Response from the service * * @throws AmazonFPSException */ public GetAccountActivityResponse getAccountActivity(GetAccountActivityRequest request) throws AmazonFPSException { GetAccountActivityResponse response; try { response = (GetAccountActivityResponse) getUnmarshaller().unmarshal( new InputSource(this.getClass().getResourceAsStream("GetAccountActivityResponse.xml"))); log.debug("Response from Mock Service: " + response.toXML()); } catch (JAXBException jbe) { throw new AmazonFPSException("Unable to process mock response", jbe); } return response; } /** * Get Account Balance * * * Returns the account balance for an account in real time. * * @param request GetAccountBalance Action * @return GetAccountBalance Response from the service * * @throws AmazonFPSException */ public GetAccountBalanceResponse getAccountBalance(GetAccountBalanceRequest request) throws AmazonFPSException { GetAccountBalanceResponse response; try { response = (GetAccountBalanceResponse) getUnmarshaller().unmarshal( new InputSource(this.getClass().getResourceAsStream("GetAccountBalanceResponse.xml"))); log.debug("Response from Mock Service: " + response.toXML()); } catch (JAXBException jbe) { throw new AmazonFPSException("Unable to process mock response", jbe); } return response; } /** * Get Debt Balance * * * Returns the balance corresponding to the given credit instrument. * * @param request GetDebtBalance Action * @return GetDebtBalance Response from the service * * @throws AmazonFPSException */ public GetDebtBalanceResponse getDebtBalance(GetDebtBalanceRequest request) throws AmazonFPSException { GetDebtBalanceResponse response; try { response = (GetDebtBalanceResponse) getUnmarshaller().unmarshal( new InputSource(this.getClass().getResourceAsStream("GetDebtBalanceResponse.xml"))); log.debug("Response from Mock Service: " + response.toXML()); } catch (JAXBException jbe) { throw new AmazonFPSException("Unable to process mock response", jbe); } return response; } /** * Get Outstanding Debt Balance * * * Returns the total outstanding balance for all the credit instruments for * the given creditor account. * * @param request GetOutstandingDebtBalance Action * @return GetOutstandingDebtBalance Response from the service * * @throws AmazonFPSException */ public GetOutstandingDebtBalanceResponse getOutstandingDebtBalance(GetOutstandingDebtBalanceRequest request) throws AmazonFPSException { GetOutstandingDebtBalanceResponse response; try { response = (GetOutstandingDebtBalanceResponse) getUnmarshaller().unmarshal( new InputSource(this.getClass().getResourceAsStream("GetOutstandingDebtBalanceResponse.xml"))); log.debug("Response from Mock Service: " + response.toXML()); } catch (JAXBException jbe) { throw new AmazonFPSException("Unable to process mock response", jbe); } return response; } /** * Get Prepaid Balance * * * Returns the balance available on the given prepaid instrument. * * @param request GetPrepaidBalance Action * @return GetPrepaidBalance Response from the service * * @throws AmazonFPSException */ public GetPrepaidBalanceResponse getPrepaidBalance(GetPrepaidBalanceRequest request) throws AmazonFPSException { GetPrepaidBalanceResponse response; try { response = (GetPrepaidBalanceResponse) getUnmarshaller().unmarshal( new InputSource(this.getClass().getResourceAsStream("GetPrepaidBalanceResponse.xml"))); log.debug("Response from Mock Service: " + response.toXML()); } catch (JAXBException jbe) { throw new AmazonFPSException("Unable to process mock response", jbe); } return response; } /** * Get Token By Caller * * * Returns the details of a particular token installed by this calling * application using the subway co-branded UI. * * @param request GetTokenByCaller Action * @return GetTokenByCaller Response from the service * * @throws AmazonFPSException */ public GetTokenByCallerResponse getTokenByCaller(GetTokenByCallerRequest request) throws AmazonFPSException { GetTokenByCallerResponse response; try { response = (GetTokenByCallerResponse) getUnmarshaller().unmarshal( new InputSource(this.getClass().getResourceAsStream("GetTokenByCallerResponse.xml"))); log.debug("Response from Mock Service: " + response.toXML()); } catch (JAXBException jbe) { throw new AmazonFPSException("Unable to process mock response", jbe); } return response; } /** * Cancel Subscription And Refund * * * Cancels a subscription. * * @param request CancelSubscriptionAndRefund Action * @return CancelSubscriptionAndRefund Response from the service * * @throws AmazonFPSException */ public CancelSubscriptionAndRefundResponse cancelSubscriptionAndRefund(CancelSubscriptionAndRefundRequest request) throws AmazonFPSException { CancelSubscriptionAndRefundResponse response; try { response = (CancelSubscriptionAndRefundResponse) getUnmarshaller().unmarshal( new InputSource(this.getClass().getResourceAsStream("CancelSubscriptionAndRefundResponse.xml"))); log.debug("Response from Mock Service: " + response.toXML()); } catch (JAXBException jbe) { throw new AmazonFPSException("Unable to process mock response", jbe); } return response; } /** * Get Token Usage * * * Returns the usage of a token. * * @param request GetTokenUsage Action * @return GetTokenUsage Response from the service * * @throws AmazonFPSException */ public GetTokenUsageResponse getTokenUsage(GetTokenUsageRequest request) throws AmazonFPSException { GetTokenUsageResponse response; try { response = (GetTokenUsageResponse) getUnmarshaller().unmarshal( new InputSource(this.getClass().getResourceAsStream("GetTokenUsageResponse.xml"))); log.debug("Response from Mock Service: " + response.toXML()); } catch (JAXBException jbe) { throw new AmazonFPSException("Unable to process mock response", jbe); } return response; } /** * Get Tokens * * * Returns a list of tokens installed on the given account. * * @param request GetTokens Action * @return GetTokens Response from the service * * @throws AmazonFPSException */ public GetTokensResponse getTokens(GetTokensRequest request) throws AmazonFPSException { GetTokensResponse response; try { response = (GetTokensResponse) getUnmarshaller().unmarshal( new InputSource(this.getClass().getResourceAsStream("GetTokensResponse.xml"))); log.debug("Response from Mock Service: " + response.toXML()); } catch (JAXBException jbe) { throw new AmazonFPSException("Unable to process mock response", jbe); } return response; } /** * Get Total Prepaid Liability * * * Returns the total liability held by the given account corresponding to * all the prepaid instruments owned by the account. * * @param request GetTotalPrepaidLiability Action * @return GetTotalPrepaidLiability Response from the service * * @throws AmazonFPSException */ public GetTotalPrepaidLiabilityResponse getTotalPrepaidLiability(GetTotalPrepaidLiabilityRequest request) throws AmazonFPSException { GetTotalPrepaidLiabilityResponse response; try { response = (GetTotalPrepaidLiabilityResponse) getUnmarshaller().unmarshal( new InputSource(this.getClass().getResourceAsStream("GetTotalPrepaidLiabilityResponse.xml"))); log.debug("Response from Mock Service: " + response.toXML()); } catch (JAXBException jbe) { throw new AmazonFPSException("Unable to process mock response", jbe); } return response; } /** * Get Transaction * * * Returns all details of a transaction. * * @param request GetTransaction Action * @return GetTransaction Response from the service * * @throws AmazonFPSException */ public GetTransactionResponse getTransaction(GetTransactionRequest request) throws AmazonFPSException { GetTransactionResponse response; try { response = (GetTransactionResponse) getUnmarshaller().unmarshal( new InputSource(this.getClass().getResourceAsStream("GetTransactionResponse.xml"))); log.debug("Response from Mock Service: " + response.toXML()); } catch (JAXBException jbe) { throw new AmazonFPSException("Unable to process mock response", jbe); } return response; } /** * Get Transaction Status * * * Gets the latest status of a transaction. * * @param request GetTransactionStatus Action * @return GetTransactionStatus Response from the service * * @throws AmazonFPSException */ public GetTransactionStatusResponse getTransactionStatus(GetTransactionStatusRequest request) throws AmazonFPSException { GetTransactionStatusResponse response; try { response = (GetTransactionStatusResponse) getUnmarshaller().unmarshal( new InputSource(this.getClass().getResourceAsStream("GetTransactionStatusResponse.xml"))); log.debug("Response from Mock Service: " + response.toXML()); } catch (JAXBException jbe) { throw new AmazonFPSException("Unable to process mock response", jbe); } return response; } /** * Get Payment Instruction * * * Gets the payment instruction of a token. * * @param request GetPaymentInstruction Action * @return GetPaymentInstruction Response from the service * * @throws AmazonFPSException */ public GetPaymentInstructionResponse getPaymentInstruction(GetPaymentInstructionRequest request) throws AmazonFPSException { GetPaymentInstructionResponse response; try { response = (GetPaymentInstructionResponse) getUnmarshaller().unmarshal( new InputSource(this.getClass().getResourceAsStream("GetPaymentInstructionResponse.xml"))); log.debug("Response from Mock Service: " + response.toXML()); } catch (JAXBException jbe) { throw new AmazonFPSException("Unable to process mock response", jbe); } return response; } /** * Install Payment Instruction * * Installs a payment instruction for caller. * * @param request InstallPaymentInstruction Action * @return InstallPaymentInstruction Response from the service * * @throws AmazonFPSException */ public InstallPaymentInstructionResponse installPaymentInstruction(InstallPaymentInstructionRequest request) throws AmazonFPSException { InstallPaymentInstructionResponse response; try { response = (InstallPaymentInstructionResponse) getUnmarshaller().unmarshal( new InputSource(this.getClass().getResourceAsStream("InstallPaymentInstructionResponse.xml"))); log.debug("Response from Mock Service: " + response.toXML()); } catch (JAXBException jbe) { throw new AmazonFPSException("Unable to process mock response", jbe); } return response; } /** * Pay * * * Allows calling applications to move money from a sender to a recipient. * * @param request Pay Action * @return Pay Response from the service * * @throws AmazonFPSException */ public PayResponse pay(PayRequest request) throws AmazonFPSException { PayResponse response; try { response = (PayResponse) getUnmarshaller().unmarshal( new InputSource(this.getClass().getResourceAsStream("PayResponse.xml"))); log.debug("Response from Mock Service: " + response.toXML()); } catch (JAXBException jbe) { throw new AmazonFPSException("Unable to process mock response", jbe); } return response; } /** * Refund * * * Refunds a previously completed transaction. * * @param request Refund Action * @return Refund Response from the service * * @throws AmazonFPSException */ public RefundResponse refund(RefundRequest request) throws AmazonFPSException { RefundResponse response; try { response = (RefundResponse) getUnmarshaller().unmarshal( new InputSource(this.getClass().getResourceAsStream("RefundResponse.xml"))); log.debug("Response from Mock Service: " + response.toXML()); } catch (JAXBException jbe) { throw new AmazonFPSException("Unable to process mock response", jbe); } return response; } /** * Reserve * * * Reserve API is part of the Reserve and Settle API conjunction that serve * the purpose of a pay where the authorization and settlement have a timing * difference. * * @param request Reserve Action * @return Reserve Response from the service * * @throws AmazonFPSException */ public ReserveResponse reserve(ReserveRequest request) throws AmazonFPSException { ReserveResponse response; try { response = (ReserveResponse) getUnmarshaller().unmarshal( new InputSource(this.getClass().getResourceAsStream("ReserveResponse.xml"))); log.debug("Response from Mock Service: " + response.toXML()); } catch (JAXBException jbe) { throw new AmazonFPSException("Unable to process mock response", jbe); } return response; } /** * Settle * * * The Settle API is used in conjunction with the Reserve API and is used to * settle previously reserved transaction. * * @param request Settle Action * @return Settle Response from the service * * @throws AmazonFPSException */ public SettleResponse settle(SettleRequest request) throws AmazonFPSException { SettleResponse response; try { response = (SettleResponse) getUnmarshaller().unmarshal( new InputSource(this.getClass().getResourceAsStream("SettleResponse.xml"))); log.debug("Response from Mock Service: " + response.toXML()); } catch (JAXBException jbe) { throw new AmazonFPSException("Unable to process mock response", jbe); } return response; } /** * Settle Debt * * * Allows a caller to initiate a transaction that atomically transfers money * from a sender’s payment instrument to the recipient, while decreasing * corresponding debt balance. * * @param request SettleDebt Action * @return SettleDebt Response from the service * * @throws AmazonFPSException */ public SettleDebtResponse settleDebt(SettleDebtRequest request) throws AmazonFPSException { SettleDebtResponse response; try { response = (SettleDebtResponse) getUnmarshaller().unmarshal( new InputSource(this.getClass().getResourceAsStream("SettleDebtResponse.xml"))); log.debug("Response from Mock Service: " + response.toXML()); } catch (JAXBException jbe) { throw new AmazonFPSException("Unable to process mock response", jbe); } return response; } /** * Write Off Debt * * * Allows a creditor to write off the debt balance accumulated partially or * fully at any time. * * @param request WriteOffDebt Action * @return WriteOffDebt Response from the service * * @throws AmazonFPSException */ public WriteOffDebtResponse writeOffDebt(WriteOffDebtRequest request) throws AmazonFPSException { WriteOffDebtResponse response; try { response = (WriteOffDebtResponse) getUnmarshaller().unmarshal( new InputSource(this.getClass().getResourceAsStream("WriteOffDebtResponse.xml"))); log.debug("Response from Mock Service: " + response.toXML()); } catch (JAXBException jbe) { throw new AmazonFPSException("Unable to process mock response", jbe); } return response; } /** * Verify Signature * * * Verify the signature that FPS sent in IPN or callback urls. * * @param request VerifySignature Action * @return VerifySignature Response from the service * * @throws AmazonFPSException */ public VerifySignatureResponse verifySignature(VerifySignatureRequest request) throws AmazonFPSException { VerifySignatureResponse response; try { response = (VerifySignatureResponse) getUnmarshaller().unmarshal( new InputSource(this.getClass().getResourceAsStream("VerifySignatureResponse.xml"))); log.debug("Response from Mock Service: " + response.toXML()); } catch (JAXBException jbe) { throw new AmazonFPSException("Unable to process mock response", jbe); } return response; } /** * Get unmarshaller for current thread */ private Unmarshaller getUnmarshaller() { return unmarshaller.get(); } }
UTF-8
Java
23,713
java
AmazonFPSMock.java
Java
[]
null
[]
/******************************************************************************* * Copyright 2008 Amazon Technologies, Inc. * Licensed under the Apache License, Version 2.0 (the "License"); * * You may not use this file except in compliance with the License. * You may obtain a copy of the License at: http://aws.amazon.com/apache2.0 * This file is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR * CONDITIONS OF ANY KIND, either express or implied. See the License for the * specific language governing permissions and limitations under the License. * ***************************************************************************** * __ _ _ ___ * ( )( \/\/ )/ __) * /__\ \ / \__ \ * (_)(_) \/\/ (___/ * * Amazon FPS Java Library * API Version: 2008-09-17 * Generated: Tue Sep 29 03:25:00 PDT 2009 * */ package com.amazonaws.fps.mock; import com.amazonaws.fps.model.*; import com.amazonaws.fps.*; import javax.xml.bind.JAXBContext; import javax.xml.bind.JAXBException; import javax.xml.bind.Unmarshaller; import org.apache.commons.logging.Log; import org.apache.commons.logging.LogFactory; import org.xml.sax.InputSource; /** * * AmazonFPSMock is the implementation of AmazonFPS based on the pre-populated * set of XML files that serve local data. It simulates responses from Amazon * FPS service. * * Use this to test your application without making a call to Amazon FPS * * Note, current Mock Service implementation does not valiadate requests * */ public class AmazonFPSMock implements AmazonFPS { private final Log log = LogFactory.getLog(AmazonFPSMock.class); private static JAXBContext jaxbContext; private static ThreadLocal<Unmarshaller> unmarshaller; /** Initialize JAXBContext and Unmarshaller **/ static { try { jaxbContext = JAXBContext.newInstance("com.amazonaws.fps.model", AmazonFPS.class.getClassLoader()); } catch (JAXBException ex) { throw new ExceptionInInitializerError(ex); } unmarshaller = new ThreadLocal<Unmarshaller>() { protected synchronized Unmarshaller initialValue() { try { return jaxbContext.createUnmarshaller(); } catch (JAXBException e) { throw new ExceptionInInitializerError(e); } } }; } // Public API ------------------------------------------------------------// /** * Cancel Token * * * Cancels any token installed by the calling application on its own * account. * * @param request CancelToken Action * @return CancelToken Response from the service * * @throws AmazonFPSException */ public CancelTokenResponse cancelToken(CancelTokenRequest request) throws AmazonFPSException { CancelTokenResponse response; try { response = (CancelTokenResponse) getUnmarshaller().unmarshal( new InputSource(this.getClass().getResourceAsStream("CancelTokenResponse.xml"))); log.debug("Response from Mock Service: " + response.toXML()); } catch (JAXBException jbe) { throw new AmazonFPSException("Unable to process mock response", jbe); } return response; } /** * Cancel * * * Cancels an ongoing transaction and puts it in cancelled state. * * @param request Cancel Action * @return Cancel Response from the service * * @throws AmazonFPSException */ public CancelResponse cancel(CancelRequest request) throws AmazonFPSException { CancelResponse response; try { response = (CancelResponse) getUnmarshaller().unmarshal( new InputSource(this.getClass().getResourceAsStream("CancelResponse.xml"))); log.debug("Response from Mock Service: " + response.toXML()); } catch (JAXBException jbe) { throw new AmazonFPSException("Unable to process mock response", jbe); } return response; } /** * Fund Prepaid * * * Funds the prepaid balance on the given prepaid instrument. * * @param request FundPrepaid Action * @return FundPrepaid Response from the service * * @throws AmazonFPSException */ public FundPrepaidResponse fundPrepaid(FundPrepaidRequest request) throws AmazonFPSException { FundPrepaidResponse response; try { response = (FundPrepaidResponse) getUnmarshaller().unmarshal( new InputSource(this.getClass().getResourceAsStream("FundPrepaidResponse.xml"))); log.debug("Response from Mock Service: " + response.toXML()); } catch (JAXBException jbe) { throw new AmazonFPSException("Unable to process mock response", jbe); } return response; } /** * Get Account Activity * * * Returns transactions for a given date range. * * @param request GetAccountActivity Action * @return GetAccountActivity Response from the service * * @throws AmazonFPSException */ public GetAccountActivityResponse getAccountActivity(GetAccountActivityRequest request) throws AmazonFPSException { GetAccountActivityResponse response; try { response = (GetAccountActivityResponse) getUnmarshaller().unmarshal( new InputSource(this.getClass().getResourceAsStream("GetAccountActivityResponse.xml"))); log.debug("Response from Mock Service: " + response.toXML()); } catch (JAXBException jbe) { throw new AmazonFPSException("Unable to process mock response", jbe); } return response; } /** * Get Account Balance * * * Returns the account balance for an account in real time. * * @param request GetAccountBalance Action * @return GetAccountBalance Response from the service * * @throws AmazonFPSException */ public GetAccountBalanceResponse getAccountBalance(GetAccountBalanceRequest request) throws AmazonFPSException { GetAccountBalanceResponse response; try { response = (GetAccountBalanceResponse) getUnmarshaller().unmarshal( new InputSource(this.getClass().getResourceAsStream("GetAccountBalanceResponse.xml"))); log.debug("Response from Mock Service: " + response.toXML()); } catch (JAXBException jbe) { throw new AmazonFPSException("Unable to process mock response", jbe); } return response; } /** * Get Debt Balance * * * Returns the balance corresponding to the given credit instrument. * * @param request GetDebtBalance Action * @return GetDebtBalance Response from the service * * @throws AmazonFPSException */ public GetDebtBalanceResponse getDebtBalance(GetDebtBalanceRequest request) throws AmazonFPSException { GetDebtBalanceResponse response; try { response = (GetDebtBalanceResponse) getUnmarshaller().unmarshal( new InputSource(this.getClass().getResourceAsStream("GetDebtBalanceResponse.xml"))); log.debug("Response from Mock Service: " + response.toXML()); } catch (JAXBException jbe) { throw new AmazonFPSException("Unable to process mock response", jbe); } return response; } /** * Get Outstanding Debt Balance * * * Returns the total outstanding balance for all the credit instruments for * the given creditor account. * * @param request GetOutstandingDebtBalance Action * @return GetOutstandingDebtBalance Response from the service * * @throws AmazonFPSException */ public GetOutstandingDebtBalanceResponse getOutstandingDebtBalance(GetOutstandingDebtBalanceRequest request) throws AmazonFPSException { GetOutstandingDebtBalanceResponse response; try { response = (GetOutstandingDebtBalanceResponse) getUnmarshaller().unmarshal( new InputSource(this.getClass().getResourceAsStream("GetOutstandingDebtBalanceResponse.xml"))); log.debug("Response from Mock Service: " + response.toXML()); } catch (JAXBException jbe) { throw new AmazonFPSException("Unable to process mock response", jbe); } return response; } /** * Get Prepaid Balance * * * Returns the balance available on the given prepaid instrument. * * @param request GetPrepaidBalance Action * @return GetPrepaidBalance Response from the service * * @throws AmazonFPSException */ public GetPrepaidBalanceResponse getPrepaidBalance(GetPrepaidBalanceRequest request) throws AmazonFPSException { GetPrepaidBalanceResponse response; try { response = (GetPrepaidBalanceResponse) getUnmarshaller().unmarshal( new InputSource(this.getClass().getResourceAsStream("GetPrepaidBalanceResponse.xml"))); log.debug("Response from Mock Service: " + response.toXML()); } catch (JAXBException jbe) { throw new AmazonFPSException("Unable to process mock response", jbe); } return response; } /** * Get Token By Caller * * * Returns the details of a particular token installed by this calling * application using the subway co-branded UI. * * @param request GetTokenByCaller Action * @return GetTokenByCaller Response from the service * * @throws AmazonFPSException */ public GetTokenByCallerResponse getTokenByCaller(GetTokenByCallerRequest request) throws AmazonFPSException { GetTokenByCallerResponse response; try { response = (GetTokenByCallerResponse) getUnmarshaller().unmarshal( new InputSource(this.getClass().getResourceAsStream("GetTokenByCallerResponse.xml"))); log.debug("Response from Mock Service: " + response.toXML()); } catch (JAXBException jbe) { throw new AmazonFPSException("Unable to process mock response", jbe); } return response; } /** * Cancel Subscription And Refund * * * Cancels a subscription. * * @param request CancelSubscriptionAndRefund Action * @return CancelSubscriptionAndRefund Response from the service * * @throws AmazonFPSException */ public CancelSubscriptionAndRefundResponse cancelSubscriptionAndRefund(CancelSubscriptionAndRefundRequest request) throws AmazonFPSException { CancelSubscriptionAndRefundResponse response; try { response = (CancelSubscriptionAndRefundResponse) getUnmarshaller().unmarshal( new InputSource(this.getClass().getResourceAsStream("CancelSubscriptionAndRefundResponse.xml"))); log.debug("Response from Mock Service: " + response.toXML()); } catch (JAXBException jbe) { throw new AmazonFPSException("Unable to process mock response", jbe); } return response; } /** * Get Token Usage * * * Returns the usage of a token. * * @param request GetTokenUsage Action * @return GetTokenUsage Response from the service * * @throws AmazonFPSException */ public GetTokenUsageResponse getTokenUsage(GetTokenUsageRequest request) throws AmazonFPSException { GetTokenUsageResponse response; try { response = (GetTokenUsageResponse) getUnmarshaller().unmarshal( new InputSource(this.getClass().getResourceAsStream("GetTokenUsageResponse.xml"))); log.debug("Response from Mock Service: " + response.toXML()); } catch (JAXBException jbe) { throw new AmazonFPSException("Unable to process mock response", jbe); } return response; } /** * Get Tokens * * * Returns a list of tokens installed on the given account. * * @param request GetTokens Action * @return GetTokens Response from the service * * @throws AmazonFPSException */ public GetTokensResponse getTokens(GetTokensRequest request) throws AmazonFPSException { GetTokensResponse response; try { response = (GetTokensResponse) getUnmarshaller().unmarshal( new InputSource(this.getClass().getResourceAsStream("GetTokensResponse.xml"))); log.debug("Response from Mock Service: " + response.toXML()); } catch (JAXBException jbe) { throw new AmazonFPSException("Unable to process mock response", jbe); } return response; } /** * Get Total Prepaid Liability * * * Returns the total liability held by the given account corresponding to * all the prepaid instruments owned by the account. * * @param request GetTotalPrepaidLiability Action * @return GetTotalPrepaidLiability Response from the service * * @throws AmazonFPSException */ public GetTotalPrepaidLiabilityResponse getTotalPrepaidLiability(GetTotalPrepaidLiabilityRequest request) throws AmazonFPSException { GetTotalPrepaidLiabilityResponse response; try { response = (GetTotalPrepaidLiabilityResponse) getUnmarshaller().unmarshal( new InputSource(this.getClass().getResourceAsStream("GetTotalPrepaidLiabilityResponse.xml"))); log.debug("Response from Mock Service: " + response.toXML()); } catch (JAXBException jbe) { throw new AmazonFPSException("Unable to process mock response", jbe); } return response; } /** * Get Transaction * * * Returns all details of a transaction. * * @param request GetTransaction Action * @return GetTransaction Response from the service * * @throws AmazonFPSException */ public GetTransactionResponse getTransaction(GetTransactionRequest request) throws AmazonFPSException { GetTransactionResponse response; try { response = (GetTransactionResponse) getUnmarshaller().unmarshal( new InputSource(this.getClass().getResourceAsStream("GetTransactionResponse.xml"))); log.debug("Response from Mock Service: " + response.toXML()); } catch (JAXBException jbe) { throw new AmazonFPSException("Unable to process mock response", jbe); } return response; } /** * Get Transaction Status * * * Gets the latest status of a transaction. * * @param request GetTransactionStatus Action * @return GetTransactionStatus Response from the service * * @throws AmazonFPSException */ public GetTransactionStatusResponse getTransactionStatus(GetTransactionStatusRequest request) throws AmazonFPSException { GetTransactionStatusResponse response; try { response = (GetTransactionStatusResponse) getUnmarshaller().unmarshal( new InputSource(this.getClass().getResourceAsStream("GetTransactionStatusResponse.xml"))); log.debug("Response from Mock Service: " + response.toXML()); } catch (JAXBException jbe) { throw new AmazonFPSException("Unable to process mock response", jbe); } return response; } /** * Get Payment Instruction * * * Gets the payment instruction of a token. * * @param request GetPaymentInstruction Action * @return GetPaymentInstruction Response from the service * * @throws AmazonFPSException */ public GetPaymentInstructionResponse getPaymentInstruction(GetPaymentInstructionRequest request) throws AmazonFPSException { GetPaymentInstructionResponse response; try { response = (GetPaymentInstructionResponse) getUnmarshaller().unmarshal( new InputSource(this.getClass().getResourceAsStream("GetPaymentInstructionResponse.xml"))); log.debug("Response from Mock Service: " + response.toXML()); } catch (JAXBException jbe) { throw new AmazonFPSException("Unable to process mock response", jbe); } return response; } /** * Install Payment Instruction * * Installs a payment instruction for caller. * * @param request InstallPaymentInstruction Action * @return InstallPaymentInstruction Response from the service * * @throws AmazonFPSException */ public InstallPaymentInstructionResponse installPaymentInstruction(InstallPaymentInstructionRequest request) throws AmazonFPSException { InstallPaymentInstructionResponse response; try { response = (InstallPaymentInstructionResponse) getUnmarshaller().unmarshal( new InputSource(this.getClass().getResourceAsStream("InstallPaymentInstructionResponse.xml"))); log.debug("Response from Mock Service: " + response.toXML()); } catch (JAXBException jbe) { throw new AmazonFPSException("Unable to process mock response", jbe); } return response; } /** * Pay * * * Allows calling applications to move money from a sender to a recipient. * * @param request Pay Action * @return Pay Response from the service * * @throws AmazonFPSException */ public PayResponse pay(PayRequest request) throws AmazonFPSException { PayResponse response; try { response = (PayResponse) getUnmarshaller().unmarshal( new InputSource(this.getClass().getResourceAsStream("PayResponse.xml"))); log.debug("Response from Mock Service: " + response.toXML()); } catch (JAXBException jbe) { throw new AmazonFPSException("Unable to process mock response", jbe); } return response; } /** * Refund * * * Refunds a previously completed transaction. * * @param request Refund Action * @return Refund Response from the service * * @throws AmazonFPSException */ public RefundResponse refund(RefundRequest request) throws AmazonFPSException { RefundResponse response; try { response = (RefundResponse) getUnmarshaller().unmarshal( new InputSource(this.getClass().getResourceAsStream("RefundResponse.xml"))); log.debug("Response from Mock Service: " + response.toXML()); } catch (JAXBException jbe) { throw new AmazonFPSException("Unable to process mock response", jbe); } return response; } /** * Reserve * * * Reserve API is part of the Reserve and Settle API conjunction that serve * the purpose of a pay where the authorization and settlement have a timing * difference. * * @param request Reserve Action * @return Reserve Response from the service * * @throws AmazonFPSException */ public ReserveResponse reserve(ReserveRequest request) throws AmazonFPSException { ReserveResponse response; try { response = (ReserveResponse) getUnmarshaller().unmarshal( new InputSource(this.getClass().getResourceAsStream("ReserveResponse.xml"))); log.debug("Response from Mock Service: " + response.toXML()); } catch (JAXBException jbe) { throw new AmazonFPSException("Unable to process mock response", jbe); } return response; } /** * Settle * * * The Settle API is used in conjunction with the Reserve API and is used to * settle previously reserved transaction. * * @param request Settle Action * @return Settle Response from the service * * @throws AmazonFPSException */ public SettleResponse settle(SettleRequest request) throws AmazonFPSException { SettleResponse response; try { response = (SettleResponse) getUnmarshaller().unmarshal( new InputSource(this.getClass().getResourceAsStream("SettleResponse.xml"))); log.debug("Response from Mock Service: " + response.toXML()); } catch (JAXBException jbe) { throw new AmazonFPSException("Unable to process mock response", jbe); } return response; } /** * Settle Debt * * * Allows a caller to initiate a transaction that atomically transfers money * from a sender’s payment instrument to the recipient, while decreasing * corresponding debt balance. * * @param request SettleDebt Action * @return SettleDebt Response from the service * * @throws AmazonFPSException */ public SettleDebtResponse settleDebt(SettleDebtRequest request) throws AmazonFPSException { SettleDebtResponse response; try { response = (SettleDebtResponse) getUnmarshaller().unmarshal( new InputSource(this.getClass().getResourceAsStream("SettleDebtResponse.xml"))); log.debug("Response from Mock Service: " + response.toXML()); } catch (JAXBException jbe) { throw new AmazonFPSException("Unable to process mock response", jbe); } return response; } /** * Write Off Debt * * * Allows a creditor to write off the debt balance accumulated partially or * fully at any time. * * @param request WriteOffDebt Action * @return WriteOffDebt Response from the service * * @throws AmazonFPSException */ public WriteOffDebtResponse writeOffDebt(WriteOffDebtRequest request) throws AmazonFPSException { WriteOffDebtResponse response; try { response = (WriteOffDebtResponse) getUnmarshaller().unmarshal( new InputSource(this.getClass().getResourceAsStream("WriteOffDebtResponse.xml"))); log.debug("Response from Mock Service: " + response.toXML()); } catch (JAXBException jbe) { throw new AmazonFPSException("Unable to process mock response", jbe); } return response; } /** * Verify Signature * * * Verify the signature that FPS sent in IPN or callback urls. * * @param request VerifySignature Action * @return VerifySignature Response from the service * * @throws AmazonFPSException */ public VerifySignatureResponse verifySignature(VerifySignatureRequest request) throws AmazonFPSException { VerifySignatureResponse response; try { response = (VerifySignatureResponse) getUnmarshaller().unmarshal( new InputSource(this.getClass().getResourceAsStream("VerifySignatureResponse.xml"))); log.debug("Response from Mock Service: " + response.toXML()); } catch (JAXBException jbe) { throw new AmazonFPSException("Unable to process mock response", jbe); } return response; } /** * Get unmarshaller for current thread */ private Unmarshaller getUnmarshaller() { return unmarshaller.get(); } }
23,713
0.635865
0.634684
691
33.315483
32.194534
119
false
false
0
0
0
0
0
0
0.24602
false
false
13
39c77cbdf4e3053e35d7b1d5f18f547d19f4f030
34,170,759,861,737
c2ecb5a836f140e1c93c8c13a324aea7beab0a0a
/PeersIp.java
752a2b5696c2cecb1f4a40a19ff4e40ac2ba5509
[]
no_license
mahmoudmohey97/p2p-chat
https://github.com/mahmoudmohey97/p2p-chat
dc53c3b2147c45e1f45438442bf15b39e146efa5
b4f2b27bbba9b599eb08673916604ce3dff52a47
refs/heads/master
2023-02-17T05:36:40.793000
2021-01-17T20:26:50
2021-01-17T20:26:50
174,877,185
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
package DRD; import java.io.IOException; import java.util.Vector; public class PeersIp { private static Vector<String> peers = new Vector<>(); public static Vector<String> getPeers() { return peers; } public static void addto(String newIp) { peers.add(newIp); } // public static void setPeers() // { // peers = new Vector<>(); // } // public static void addPeer(String peerIp) throws IOException { System.out.println("----------> : " + peers); if(!peers.contains(peerIp)) { System.out.println("Peer of IP : " + peerIp + " " + "joined"); addto(peerIp); //System.out.println(peers); MulticastSend socketSender = new MulticastSend(peerIp); socketSender.start(); } } public void showPeers() { System.out.println(peers); } }
UTF-8
Java
820
java
PeersIp.java
Java
[]
null
[]
package DRD; import java.io.IOException; import java.util.Vector; public class PeersIp { private static Vector<String> peers = new Vector<>(); public static Vector<String> getPeers() { return peers; } public static void addto(String newIp) { peers.add(newIp); } // public static void setPeers() // { // peers = new Vector<>(); // } // public static void addPeer(String peerIp) throws IOException { System.out.println("----------> : " + peers); if(!peers.contains(peerIp)) { System.out.println("Peer of IP : " + peerIp + " " + "joined"); addto(peerIp); //System.out.println(peers); MulticastSend socketSender = new MulticastSend(peerIp); socketSender.start(); } } public void showPeers() { System.out.println(peers); } }
820
0.612195
0.612195
43
18.069767
19.694641
71
false
false
0
0
0
0
0
0
1.209302
false
false
13
f4db6ad037c59395e0359599c66a8a0693ca5feb
3,719,441,706,472
4691208bfe83e618f71e2df329d42a7946281812
/testng-playground/src/test/java/org/geetha/testng/TestExcepSubClass.java
60bf272e97dbc8ed9d2788296f8e0c2761d0b95c
[]
no_license
geetharm/Selenium
https://github.com/geetharm/Selenium
de9d80a5f931e7a227e827d3c815eeeb60748ad6
b391963711187735fb4b95911c7fe9319695b3a5
refs/heads/master
2021-05-11T03:28:21.401000
2018-02-04T06:50:21
2018-02-04T06:50:21
117,917,052
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
package org.geetha.testng; import java.io.IOException; import org.testng.annotations.Test; public class TestExcepSubClass extends testException { // public static void main(String[] args) throws IOException{ // TestExcepSubClass c1 = new TestExcepSubClass(); // c1.test(); // } @Test public void testMethod(){ System.out.println("test include method"); } }
UTF-8
Java
374
java
TestExcepSubClass.java
Java
[]
null
[]
package org.geetha.testng; import java.io.IOException; import org.testng.annotations.Test; public class TestExcepSubClass extends testException { // public static void main(String[] args) throws IOException{ // TestExcepSubClass c1 = new TestExcepSubClass(); // c1.test(); // } @Test public void testMethod(){ System.out.println("test include method"); } }
374
0.727273
0.721925
20
17.700001
20.579359
61
false
false
0
0
0
0
0
0
1
false
false
13
cc845fc89109c31f6af9c7552e78a3ca191addf1
21,217,138,474,292
c560934cd8992fb40b9abc9696d0e9e5967d582a
/bundle/src/main/java/aem/pokego/lure/services/PokeGoApiService.java
c00aa3bfd27c848fdec0a76e83b89cc312b59f36
[ "MIT" ]
permissive
mickleroy/aem-pokego-lure-client
https://github.com/mickleroy/aem-pokego-lure-client
6b86019efdd1c3c86a565d5477ce2eab53225ffc
1425e9a7305b6991a332d3ed04240d3b1890d06d
refs/heads/master
2020-05-21T16:42:28.259000
2016-10-03T10:53:56
2016-10-03T10:53:56
65,785,584
0
1
null
false
2016-10-03T10:29:43
2016-08-16T03:46:52
2016-08-26T12:32:53
2016-10-03T10:29:43
1,229
0
0
1
Java
null
null
package aem.pokego.lure.services; import aem.pokego.lure.models.PokeStop; import com.pokegoapi.api.PokemonGo; import com.pokegoapi.api.map.fort.Pokestop; import java.util.List; public interface PokeGoApiService { boolean refreshSession(); boolean login(String username, String password); boolean login(String token); void logout(); PokemonGo getApi(); Pokestop getPokeStop(PokeStop pokeStop); String getTrainerName(); List<PokeStop> getNearbyPokestops(double latitude, double longitude, double altitude); int luresInInventory(); }
UTF-8
Java
572
java
PokeGoApiService.java
Java
[]
null
[]
package aem.pokego.lure.services; import aem.pokego.lure.models.PokeStop; import com.pokegoapi.api.PokemonGo; import com.pokegoapi.api.map.fort.Pokestop; import java.util.List; public interface PokeGoApiService { boolean refreshSession(); boolean login(String username, String password); boolean login(String token); void logout(); PokemonGo getApi(); Pokestop getPokeStop(PokeStop pokeStop); String getTrainerName(); List<PokeStop> getNearbyPokestops(double latitude, double longitude, double altitude); int luresInInventory(); }
572
0.755245
0.755245
21
26.238094
21.720968
90
false
false
0
0
0
0
0
0
0.809524
false
false
13
2e8cb528bbd8f6f6fc9f04bde3cffe00aca58686
29,678,224,044,378
ca0c486589d2e67915634af639ccf4d36750b4f1
/eclipseNeonEE_workspace/TestBusiness2/src/main/java/de/any/crawl/SaxXmlParser.java
3645f4e3b8056618385c8938a57ec55781e8a4f4
[]
no_license
gituserDoesNotExist/java-playground
https://github.com/gituserDoesNotExist/java-playground
3fc4aa49e50c4d24cf5ddf08440b94f77a72e829
6ca3a3ad676b8dec5e58423bd136db0c1f44710d
refs/heads/master
2020-04-09T05:13:28.104000
2018-12-02T16:56:03
2018-12-02T16:56:03
160,056,260
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
/* * Created on 29.08.2018 * * Dimensions - Versionierung * $Workfile: %PM% $ * $Revision: %PR% $ * $Date: %Date% $ * $Author: %Author% $ * * (c) Copyright SV Informatik GmbH 2010 */ package de.any.crawl; import java.io.IOException; import java.net.URL; import java.util.ArrayList; import java.util.List; import org.jdom2.Document; import org.jdom2.Element; import org.jdom2.JDOMException; import org.jdom2.filter.ElementFilter; import org.jdom2.input.SAXBuilder; import org.jdom2.util.IteratorIterable; /** * Zweck dieser Klasse: <br> * (Hier Zweck eintragen - bis zu 2 Zeilen). * <p> * Angewandte Pattern: <br> * (Hier Pattern nennen) * <p> * Zusammenhaenge / Partnerklassen <br> * (Hier erlaeutern) * <p> * Abgrenzung zu anderen Klassen <br> * (Hier erlaeutern) * <p> * Weitere Informationen <br> * (Hier auffuehren) * * @author N0008244 */ public class SaxXmlParser implements XmlParser { @Override public Element getRootElementOfXmlFile(URL resource) { return tryBuildingDocument(resource).getRootElement(); } @Override public List<Element> extractTagsFromXmlFile(URL resource, String tagName) { Element rootElement = getRootElementOfXmlFile(resource); return findDescendantTagsInParentTagByName(rootElement, tagName); } @Override public boolean hasParentDescendantTagsWithName(Element parentTag, String name) { List<Element> elements = findDescendantTagsInParentTagByName(parentTag, name); return !elements.isEmpty(); } @Override public List<Element> findDescendantTagsInParentTagByName(Element parentTag, String nameDescendantTag) { IteratorIterable<Element> descendants = parentTag.getDescendants(new ElementFilter(nameDescendantTag)); return convertIterableIteratorToList(descendants); } private List<Element> convertIterableIteratorToList(IteratorIterable<Element> descendants) { List<Element> elements = new ArrayList<>(); for (Element element : descendants) { elements.add(element); } return elements; } private Document tryBuildingDocument(URL resource) { SAXBuilder builder = new SAXBuilder(); try { return builder.build(resource); } catch (JDOMException | IOException e) { throw new RuntimeException("unable to load file : " + resource, e); } } }
UTF-8
Java
2,256
java
SaxXmlParser.java
Java
[ { "context": "rmationen <br>\n * (Hier auffuehren)\n * \n * @author N0008244\n */\npublic class SaxXmlParser implements XmlParse", "end": 872, "score": 0.9994620680809021, "start": 864, "tag": "USERNAME", "value": "N0008244" } ]
null
[]
/* * Created on 29.08.2018 * * Dimensions - Versionierung * $Workfile: %PM% $ * $Revision: %PR% $ * $Date: %Date% $ * $Author: %Author% $ * * (c) Copyright SV Informatik GmbH 2010 */ package de.any.crawl; import java.io.IOException; import java.net.URL; import java.util.ArrayList; import java.util.List; import org.jdom2.Document; import org.jdom2.Element; import org.jdom2.JDOMException; import org.jdom2.filter.ElementFilter; import org.jdom2.input.SAXBuilder; import org.jdom2.util.IteratorIterable; /** * Zweck dieser Klasse: <br> * (Hier Zweck eintragen - bis zu 2 Zeilen). * <p> * Angewandte Pattern: <br> * (Hier Pattern nennen) * <p> * Zusammenhaenge / Partnerklassen <br> * (Hier erlaeutern) * <p> * Abgrenzung zu anderen Klassen <br> * (Hier erlaeutern) * <p> * Weitere Informationen <br> * (Hier auffuehren) * * @author N0008244 */ public class SaxXmlParser implements XmlParser { @Override public Element getRootElementOfXmlFile(URL resource) { return tryBuildingDocument(resource).getRootElement(); } @Override public List<Element> extractTagsFromXmlFile(URL resource, String tagName) { Element rootElement = getRootElementOfXmlFile(resource); return findDescendantTagsInParentTagByName(rootElement, tagName); } @Override public boolean hasParentDescendantTagsWithName(Element parentTag, String name) { List<Element> elements = findDescendantTagsInParentTagByName(parentTag, name); return !elements.isEmpty(); } @Override public List<Element> findDescendantTagsInParentTagByName(Element parentTag, String nameDescendantTag) { IteratorIterable<Element> descendants = parentTag.getDescendants(new ElementFilter(nameDescendantTag)); return convertIterableIteratorToList(descendants); } private List<Element> convertIterableIteratorToList(IteratorIterable<Element> descendants) { List<Element> elements = new ArrayList<>(); for (Element element : descendants) { elements.add(element); } return elements; } private Document tryBuildingDocument(URL resource) { SAXBuilder builder = new SAXBuilder(); try { return builder.build(resource); } catch (JDOMException | IOException e) { throw new RuntimeException("unable to load file : " + resource, e); } } }
2,256
0.743351
0.731826
87
24.94253
25.273382
105
false
false
0
0
0
0
0
0
0.988506
false
false
13
022388dce3451b506dd9d75c3fabed61064e39ea
13,597,866,487,470
4b934bec49e2cbd429d91492601c101154b2c9b7
/ToDoAppFinalVersion/ToDoListApp/src/com/todo/dao/CheckStatusDAO.java
568ac3017ee8e9d930ce8b91fbe18f77e0d573c5
[]
no_license
Jimbo51000/Java-Web-Apps
https://github.com/Jimbo51000/Java-Web-Apps
d10d94f1086dc040864412b527fd28482bd827f9
8ce1f12c5d371ff58fab7f6ec18a8aa7079433fa
refs/heads/master
2020-04-02T06:20:22.757000
2016-07-05T18:07:25
2016-07-05T18:07:25
62,579,357
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
package com.todo.dao; import java.sql.SQLException; public interface CheckStatusDAO { public boolean checkTaskStatus(String username) throws SQLException; }
UTF-8
Java
161
java
CheckStatusDAO.java
Java
[]
null
[]
package com.todo.dao; import java.sql.SQLException; public interface CheckStatusDAO { public boolean checkTaskStatus(String username) throws SQLException; }
161
0.813665
0.813665
8
19.125
22.931623
69
false
false
0
0
0
0
0
0
0.5
false
false
13
548fd4b286fcbf6157db8e2c750ecf7514cf9498
16,690,242,947,009
a19f95777f03452b2d2acc41b3553118038be804
/api/src/main/java/com/capitalone/dashboard/webhook/github/GitHubHookController.java
87f409b6469a39295203a40031fb911685644301
[ "Apache-2.0" ]
permissive
walmartlabs/Hygieia
https://github.com/walmartlabs/Hygieia
891a10630255f87fca091d4f8d3ff5fa62daddde
64f47cc48c2c44ebb18e6fb45df0a07b4559a856
refs/heads/master
2023-07-24T10:20:39.072000
2023-07-18T21:40:33
2023-07-18T21:40:33
119,907,025
4
6
Apache-2.0
true
2020-04-23T21:52:21
2018-02-01T23:39:22
2019-07-02T22:21:54
2020-04-23T21:52:20
73,423
2
5
6
JavaScript
false
false
package com.capitalone.dashboard.webhook.github; import com.capitalone.dashboard.misc.HygieiaException; import org.json.simple.JSONObject; import org.json.simple.parser.ParseException; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.http.HttpStatus; import org.springframework.http.ResponseEntity; import org.springframework.web.bind.annotation.RequestBody; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RestController; import java.net.MalformedURLException; import static org.springframework.http.MediaType.APPLICATION_JSON_VALUE; import static org.springframework.web.bind.annotation.RequestMethod.POST; @RestController @RequestMapping("/webhook") public class GitHubHookController { private final GitHubHookService gitHubHookService; @Autowired public GitHubHookController(GitHubHookService gitHubHookService) { this.gitHubHookService = gitHubHookService; } @RequestMapping(value = "/github/v3", method = POST, consumes = APPLICATION_JSON_VALUE, produces = APPLICATION_JSON_VALUE) public ResponseEntity<String> createGitHubv3(@RequestBody JSONObject request) throws ParseException, HygieiaException, MalformedURLException { String response = gitHubHookService.createFromGitHubv3(request); return ResponseEntity .status(HttpStatus.CREATED) .body(response); } }
UTF-8
Java
1,471
java
GitHubHookController.java
Java
[]
null
[]
package com.capitalone.dashboard.webhook.github; import com.capitalone.dashboard.misc.HygieiaException; import org.json.simple.JSONObject; import org.json.simple.parser.ParseException; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.http.HttpStatus; import org.springframework.http.ResponseEntity; import org.springframework.web.bind.annotation.RequestBody; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RestController; import java.net.MalformedURLException; import static org.springframework.http.MediaType.APPLICATION_JSON_VALUE; import static org.springframework.web.bind.annotation.RequestMethod.POST; @RestController @RequestMapping("/webhook") public class GitHubHookController { private final GitHubHookService gitHubHookService; @Autowired public GitHubHookController(GitHubHookService gitHubHookService) { this.gitHubHookService = gitHubHookService; } @RequestMapping(value = "/github/v3", method = POST, consumes = APPLICATION_JSON_VALUE, produces = APPLICATION_JSON_VALUE) public ResponseEntity<String> createGitHubv3(@RequestBody JSONObject request) throws ParseException, HygieiaException, MalformedURLException { String response = gitHubHookService.createFromGitHubv3(request); return ResponseEntity .status(HttpStatus.CREATED) .body(response); } }
1,471
0.791298
0.789259
36
39.861111
31.172596
146
false
false
0
0
0
0
0
0
0.611111
false
false
13
da052e2474e14d35d7085655203eb99a580c5704
32,779,190,444,852
63a06ea7dc8b42c35c3d9ff351ad059fa7a34ce4
/src/main/java/com/thorinhood/data/s3object/S3Object.java
e284317d7313e19e2f15a1733b3d42b9ca710330
[]
no_license
THORinHOOD/s3server
https://github.com/THORinHOOD/s3server
36ecb4e9bb8b01d7eef953df23857c50065616cf
670d5457b71c3274762282ddd8285e5c3b1bb099
refs/heads/master
2023-06-20T22:12:21.368000
2021-08-05T06:43:30
2021-08-05T06:43:30
330,171,065
1
1
null
false
2021-08-05T06:50:30
2021-01-16T13:39:44
2021-08-05T06:43:33
2021-08-05T06:49:35
742
0
0
3
Java
false
false
package com.thorinhood.data.s3object; import com.thorinhood.data.S3FileObjectPath; import java.io.File; import java.util.Map; public class S3Object implements HasAbsolutePath, HasS3Path, HasETag, HasFile, HasRawBytes, HasLastModified, HasMetaData { private String absolutePath; private S3FileObjectPath s3FileObjectPath; private String ETag; private File file; private byte[] bytes; private String lastModified; private Map<String, String> metadata; private S3Object() { } public static HasAbsolutePath build() { return new S3Object(); } @Override public HasS3Path setAbsolutePath(String absolutePath) { this.absolutePath = absolutePath; return this; } @Override public HasFile setETag(String ETag) { this.ETag = ETag; return this; } @Override public HasRawBytes setFile(File file) { this.file = file; return this; } @Override public HasETag setS3Path(S3FileObjectPath s3FileObjectPath) { this.s3FileObjectPath = s3FileObjectPath; return this; } @Override public HasLastModified setRawBytes(byte[] rawBytes) { bytes = rawBytes; return this; } @Override public HasMetaData setLastModified(String lastModified) { this.lastModified = lastModified; return this; } @Override public String getAbsolutePath() { return absolutePath; } @Override public String getETag() { return ETag; } @Override public File getFile() { return file; } @Override public S3FileObjectPath getS3Path() { return s3FileObjectPath; } @Override public String getLastModified() { return lastModified; } @Override public byte[] getRawBytes() { return bytes; } @Override public S3Object setMetaData(Map<String, String> metadata) { this.metadata = metadata; return this; } @Override public Map<String, String> getMetaData() { return metadata; } }
UTF-8
Java
2,118
java
S3Object.java
Java
[]
null
[]
package com.thorinhood.data.s3object; import com.thorinhood.data.S3FileObjectPath; import java.io.File; import java.util.Map; public class S3Object implements HasAbsolutePath, HasS3Path, HasETag, HasFile, HasRawBytes, HasLastModified, HasMetaData { private String absolutePath; private S3FileObjectPath s3FileObjectPath; private String ETag; private File file; private byte[] bytes; private String lastModified; private Map<String, String> metadata; private S3Object() { } public static HasAbsolutePath build() { return new S3Object(); } @Override public HasS3Path setAbsolutePath(String absolutePath) { this.absolutePath = absolutePath; return this; } @Override public HasFile setETag(String ETag) { this.ETag = ETag; return this; } @Override public HasRawBytes setFile(File file) { this.file = file; return this; } @Override public HasETag setS3Path(S3FileObjectPath s3FileObjectPath) { this.s3FileObjectPath = s3FileObjectPath; return this; } @Override public HasLastModified setRawBytes(byte[] rawBytes) { bytes = rawBytes; return this; } @Override public HasMetaData setLastModified(String lastModified) { this.lastModified = lastModified; return this; } @Override public String getAbsolutePath() { return absolutePath; } @Override public String getETag() { return ETag; } @Override public File getFile() { return file; } @Override public S3FileObjectPath getS3Path() { return s3FileObjectPath; } @Override public String getLastModified() { return lastModified; } @Override public byte[] getRawBytes() { return bytes; } @Override public S3Object setMetaData(Map<String, String> metadata) { this.metadata = metadata; return this; } @Override public Map<String, String> getMetaData() { return metadata; } }
2,118
0.63881
0.630312
101
19.970297
19.82021
122
false
false
0
0
0
0
0
0
0.415842
false
false
13
c7ae972dd490be586240c0b0797d37825be02bc0
26,817,775,828,210
06bff03e08f79cc090eaa146212d38442feed68a
/src/main/java/mythPlayer/litter/exercise/RocketPanel.java
5c8256702991bb09e5bfb8b246c092082aec93ee
[]
no_license
wzunique/mythPlayer
https://github.com/wzunique/mythPlayer
3a6d6d4ee69b907ee28af0d1f8b13ab51a705cfd
b020727712e948e8494ac7c1db908d1299f1196d
refs/heads/master
2021-06-16T18:42:57.247000
2017-06-08T07:40:46
2017-06-08T07:40:46
null
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
package mythPlayer.litter.exercise; import java.awt.Color; import java.awt.Dimension; import java.awt.Graphics; import javax.swing.JFrame; import javax.swing.JPanel; public class RocketPanel extends JPanel { public static void main(String[] args) { JFrame jframe = new JFrame("Rocket"); jframe.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE); jframe.getContentPane().add(new RocketPanel()); jframe.pack(); jframe.setVisible(true); } private int[] xRocket = { 100, 120, 120, 130, 130, 70, 70, 80, 80 }; private int[] yRocket = { 15, 40, 115, 125, 150, 150, 125, 115, 40 }; private int[] xWindow = { 95, 105, 110, 90 }; private int[] yWindow = { 45, 45, 70, 70 }; private int[] xFlame = { 70, 70, 75, 80, 90, 100, 110, 115, 120, 130, 130 }; private int[] yFlame = { 155, 170, 165, 190, 170, 175, 160, 185, 160, 175, 155 }; public RocketPanel() { setBackground(Color.cyan); setPreferredSize(new Dimension(200, 200)); } public void paintComponent(Graphics g) { super.paintComponent(g); g.setColor(Color.red); g.fillPolygon(xRocket, yRocket, xRocket.length); g.setColor(Color.black); g.fillPolygon(xWindow, yWindow, xWindow.length); // g.drawPolyline(xFlame, yFlame, xFlame.length); g.setColor(Color.red); g.drawPolyline(xFlame, yFlame, xFlame.length); } }
UTF-8
Java
1,360
java
RocketPanel.java
Java
[]
null
[]
package mythPlayer.litter.exercise; import java.awt.Color; import java.awt.Dimension; import java.awt.Graphics; import javax.swing.JFrame; import javax.swing.JPanel; public class RocketPanel extends JPanel { public static void main(String[] args) { JFrame jframe = new JFrame("Rocket"); jframe.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE); jframe.getContentPane().add(new RocketPanel()); jframe.pack(); jframe.setVisible(true); } private int[] xRocket = { 100, 120, 120, 130, 130, 70, 70, 80, 80 }; private int[] yRocket = { 15, 40, 115, 125, 150, 150, 125, 115, 40 }; private int[] xWindow = { 95, 105, 110, 90 }; private int[] yWindow = { 45, 45, 70, 70 }; private int[] xFlame = { 70, 70, 75, 80, 90, 100, 110, 115, 120, 130, 130 }; private int[] yFlame = { 155, 170, 165, 190, 170, 175, 160, 185, 160, 175, 155 }; public RocketPanel() { setBackground(Color.cyan); setPreferredSize(new Dimension(200, 200)); } public void paintComponent(Graphics g) { super.paintComponent(g); g.setColor(Color.red); g.fillPolygon(xRocket, yRocket, xRocket.length); g.setColor(Color.black); g.fillPolygon(xWindow, yWindow, xWindow.length); // g.drawPolyline(xFlame, yFlame, xFlame.length); g.setColor(Color.red); g.drawPolyline(xFlame, yFlame, xFlame.length); } }
1,360
0.661029
0.563971
51
24.666666
23.598494
82
false
false
0
0
0
0
0
0
2.588235
false
false
13
7404366aee02933550c890bf03baca9356a93e12
16,355,235,508,162
85053c7412539209a98c36275657c5bfd911a0c9
/portfolio2/src/calendarForm/Schedule.java
05327ff1528b8b479a0f5c959f53b5ae75cdd79b
[]
no_license
mnishimoto/portfolio
https://github.com/mnishimoto/portfolio
6fe0a4ce6e80d1a40f5c6c92baf1c06b3a53d54d
42d277be4916f301c5460f085e1f0199f3d746ea
refs/heads/master
2022-11-16T20:09:08.617000
2020-06-30T07:36:00
2020-06-30T07:36:00
275,064,267
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
package calendarForm; import java.io.IOException; import java.sql.SQLException; import javax.servlet.RequestDispatcher; import javax.servlet.ServletContext; import javax.servlet.ServletException; import javax.servlet.annotation.WebServlet; import javax.servlet.http.HttpServlet; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; import dbAccess.DBAccess; import dbAccess.InsertSchedule; /** * Servlet implementation class Schedule */ @WebServlet("/Schedule") public class Schedule extends HttpServlet { private static final long serialVersionUID = 1L; /** * @see HttpServlet#doGet(HttpServletRequest request, HttpServletResponse response) */ protected void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { // TODO Auto-generated method stub response.getWriter().append("Served at: ").append(request.getContextPath()); } /** * @see HttpServlet#doPost(HttpServletRequest request, HttpServletResponse response) */ protected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { request.setCharacterEncoding("UTF-8"); DBAccess s = new InsertSchedule(); try { s.execute(request); } catch (SQLException e) { // TODO �����������ꂽ catch �u���b�N e.printStackTrace(); } ServletContext context = getServletContext(); RequestDispatcher dis = context.getRequestDispatcher("/TopSelect.jsp"); dis.forward(request, response); } }
UTF-8
Java
1,605
java
Schedule.java
Java
[]
null
[]
package calendarForm; import java.io.IOException; import java.sql.SQLException; import javax.servlet.RequestDispatcher; import javax.servlet.ServletContext; import javax.servlet.ServletException; import javax.servlet.annotation.WebServlet; import javax.servlet.http.HttpServlet; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; import dbAccess.DBAccess; import dbAccess.InsertSchedule; /** * Servlet implementation class Schedule */ @WebServlet("/Schedule") public class Schedule extends HttpServlet { private static final long serialVersionUID = 1L; /** * @see HttpServlet#doGet(HttpServletRequest request, HttpServletResponse response) */ protected void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { // TODO Auto-generated method stub response.getWriter().append("Served at: ").append(request.getContextPath()); } /** * @see HttpServlet#doPost(HttpServletRequest request, HttpServletResponse response) */ protected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { request.setCharacterEncoding("UTF-8"); DBAccess s = new InsertSchedule(); try { s.execute(request); } catch (SQLException e) { // TODO �����������ꂽ catch �u���b�N e.printStackTrace(); } ServletContext context = getServletContext(); RequestDispatcher dis = context.getRequestDispatcher("/TopSelect.jsp"); dis.forward(request, response); } }
1,605
0.749841
0.748568
49
30.061224
29.312119
119
false
false
0
0
0
0
0
0
1.428571
false
false
13
2709ca0678080688af19a6a6230f319a398badea
28,973,849,417,732
a151d0bc51201df33b65f1ac5e204ea20f7c9ed2
/LibraryApp/src/com/dxc/dao/IAdminDao.java
e71b584329ba20ee2997c3f6477e3932dfd25448
[]
no_license
himadri1-tanaya/Library_management_System
https://github.com/himadri1-tanaya/Library_management_System
5468a92609bbc24319b763c2938c047882efd070
1489b730211d4fb652ef8c51fa428205726cc70c
refs/heads/master
2022-12-26T02:55:52.362000
2020-10-04T10:13:57
2020-10-04T10:13:57
275,343,083
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
package com.dxc.dao; import java.util.List; import com.dxc.pojo.Book; import com.dxc.pojo.User; public interface IAdminDao { public boolean passwordCheck(String name,String password); public void addUser(int id, String name, String password, double balance); public void addBook(int id, String bName, String auther, int qnt); public List<Book> getUserBookList(int id); public void closeConnection(); public double getUserBalance(int id); public List<Book> getTotalBookList(); public void deleteUser(int id); public List<User> getUserList(); }
UTF-8
Java
599
java
IAdminDao.java
Java
[]
null
[]
package com.dxc.dao; import java.util.List; import com.dxc.pojo.Book; import com.dxc.pojo.User; public interface IAdminDao { public boolean passwordCheck(String name,String password); public void addUser(int id, String name, String password, double balance); public void addBook(int id, String bName, String auther, int qnt); public List<Book> getUserBookList(int id); public void closeConnection(); public double getUserBalance(int id); public List<Book> getTotalBookList(); public void deleteUser(int id); public List<User> getUserList(); }
599
0.714524
0.714524
30
17.966667
22.09296
75
false
false
0
0
0
0
0
0
1.033333
false
false
13
9a6ae90096a377c8f15e76db8a6c9d87db430376
274,877,952,040
df87cd25a5bb29bb5246a5477c20e766f24c3345
/manager/src/main/java/jt/sensordata/server/TopDataHandler.java
cbaa4e09b3d84c549d48cd09c17bf288ac0a7dce
[]
no_license
wallellen/zhoushan
https://github.com/wallellen/zhoushan
07c16b5b0bb33d12640ba0c51d7eb348310d04fc
38077895e2131b8fa1ac1af3d2bb98029f94e3de
refs/heads/master
2020-04-06T07:03:20.339000
2014-09-15T03:30:54
2014-09-15T03:30:54
null
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
/** * */ package jt.sensordata.server; import jt.sensordata.main.ClientManager; import org.apache.log4j.Logger; import com.alibaba.fastjson.JSON; import com.alibaba.fastjson.JSONArray; import com.alibaba.fastjson.JSONObject; import com.yongboy.socketio.server.IOHandlerAbs; import com.yongboy.socketio.server.transport.IOClient; /** * @author Administartor * */ public class TopDataHandler extends IOHandlerAbs { Logger log = Logger.getLogger(this.getClass()); /* (non-Javadoc) * @see com.yongboy.socketio.server.IOHandler#OnConnect(com.yongboy.socketio.server.transport.IOClient) */ public void OnConnect(IOClient client) { // TODO Auto-generated method stub log.debug("A user connected :: "+client.getSessionID()); } /* (non-Javadoc) * @see com.yongboy.socketio.server.IOHandler#OnDisconnect(com.yongboy.socketio.server.transport.IOClient) */ public void OnDisconnect(IOClient client) { // TODO Auto-generated method stub log.debug("A user disconnected :: " + client.getSessionID()); //remove this client from topclientlist ClientManager.removeClient(client, 1); } /* (non-Javadoc) * @see com.yongboy.socketio.server.IOHandler#OnMessage(com.yongboy.socketio.server.transport.IOClient, java.lang.String) */ public void OnMessage(IOClient client, String oriMessage) { // TODO Auto-generated method stub String jsonString = oriMessage.substring(oriMessage.indexOf('{')); jsonString = jsonString.replaceAll("\\\\", ""); JSONObject jsonObject = JSON.parseObject(jsonString); String eventName = jsonObject.get("name").toString(); log.debug("get a message:"+oriMessage+" from "+client.getSessionID()); if (eventName.equals("GetTop")) { JSONArray argsArray = jsonObject.getJSONArray("args"); String [] commandName = argsArray.getString(0).split(","); //commandName = ["Now",storageId] if(commandName[0].equals("Now")){ //立即发送一次拓扑结构 ClientManager.sendTopToAClient(client,commandName[1]); } //将请求某Zigbee拓扑结构的client加入列表当中用于统一发送,以设备短地址为标识符 ClientManager.addClientToList(client, commandName[1], 1); } } /* (non-Javadoc) * @see com.yongboy.socketio.server.IOHandler#OnShutdown() */ public void OnShutdown() { // TODO Auto-generated method stub log.debug("A connect shutdown...."); } }
UTF-8
Java
2,450
java
TopDataHandler.java
Java
[ { "context": "ocketio.server.transport.IOClient;\n\n/**\n * @author Administartor\n *\n */\npublic class TopDataHandler extends IOHand", "end": 363, "score": 0.9988958835601807, "start": 350, "tag": "USERNAME", "value": "Administartor" } ]
null
[]
/** * */ package jt.sensordata.server; import jt.sensordata.main.ClientManager; import org.apache.log4j.Logger; import com.alibaba.fastjson.JSON; import com.alibaba.fastjson.JSONArray; import com.alibaba.fastjson.JSONObject; import com.yongboy.socketio.server.IOHandlerAbs; import com.yongboy.socketio.server.transport.IOClient; /** * @author Administartor * */ public class TopDataHandler extends IOHandlerAbs { Logger log = Logger.getLogger(this.getClass()); /* (non-Javadoc) * @see com.yongboy.socketio.server.IOHandler#OnConnect(com.yongboy.socketio.server.transport.IOClient) */ public void OnConnect(IOClient client) { // TODO Auto-generated method stub log.debug("A user connected :: "+client.getSessionID()); } /* (non-Javadoc) * @see com.yongboy.socketio.server.IOHandler#OnDisconnect(com.yongboy.socketio.server.transport.IOClient) */ public void OnDisconnect(IOClient client) { // TODO Auto-generated method stub log.debug("A user disconnected :: " + client.getSessionID()); //remove this client from topclientlist ClientManager.removeClient(client, 1); } /* (non-Javadoc) * @see com.yongboy.socketio.server.IOHandler#OnMessage(com.yongboy.socketio.server.transport.IOClient, java.lang.String) */ public void OnMessage(IOClient client, String oriMessage) { // TODO Auto-generated method stub String jsonString = oriMessage.substring(oriMessage.indexOf('{')); jsonString = jsonString.replaceAll("\\\\", ""); JSONObject jsonObject = JSON.parseObject(jsonString); String eventName = jsonObject.get("name").toString(); log.debug("get a message:"+oriMessage+" from "+client.getSessionID()); if (eventName.equals("GetTop")) { JSONArray argsArray = jsonObject.getJSONArray("args"); String [] commandName = argsArray.getString(0).split(","); //commandName = ["Now",storageId] if(commandName[0].equals("Now")){ //立即发送一次拓扑结构 ClientManager.sendTopToAClient(client,commandName[1]); } //将请求某Zigbee拓扑结构的client加入列表当中用于统一发送,以设备短地址为标识符 ClientManager.addClientToList(client, commandName[1], 1); } } /* (non-Javadoc) * @see com.yongboy.socketio.server.IOHandler#OnShutdown() */ public void OnShutdown() { // TODO Auto-generated method stub log.debug("A connect shutdown...."); } }
2,450
0.704565
0.701606
76
30.131578
28.562647
122
false
false
0
0
0
0
0
0
1.236842
false
false
13
e850601223978279d6b495ac5123ba8937b5b24c
635,655,201,794
9a061054b4028fc36f6f0e5fa9229a9c0490b9fb
/src/ch11/test/FileOutputTest.java
73cfedd96edeb227fb3b1fb49b64af19c539104d
[]
no_license
livelikeabel/Acon-Java
https://github.com/livelikeabel/Acon-Java
e32ad402ba93115bc4bd86490862c3e881a1d4f0
51dd58dcd725d206e4693b8425087c4eb0bb1aeb
refs/heads/master
2021-07-05T08:13:55.457000
2017-09-29T04:22:13
2017-09-29T04:22:13
104,035,438
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
package ch11.test; import java.io.FileOutputStream; import java.io.IOException; import java.util.Scanner; public class FileOutputTest { public static void main(String[] args) throws IOException { FileOutputStream fos = null; fos = new FileOutputStream("C://Users/acorn/Desktop/ccc.txt"); Scanner sc = new Scanner(System.in); String str = sc.next(); while(!str.equals("close")) { for(int i=0; i < str.length(); i++) { fos.write(str.charAt(i)); } fos.write(13); str = sc.next(); } fos.write(104); fos.close(); } }
UTF-8
Java
580
java
FileOutputTest.java
Java
[ { "context": " = null;\r\n\t\tfos = new FileOutputStream(\"C://Users/acorn/Desktop/ccc.txt\");\r\n\t\tScanner sc = new Scanner(Sy", "end": 286, "score": 0.9962495565414429, "start": 281, "tag": "USERNAME", "value": "acorn" } ]
null
[]
package ch11.test; import java.io.FileOutputStream; import java.io.IOException; import java.util.Scanner; public class FileOutputTest { public static void main(String[] args) throws IOException { FileOutputStream fos = null; fos = new FileOutputStream("C://Users/acorn/Desktop/ccc.txt"); Scanner sc = new Scanner(System.in); String str = sc.next(); while(!str.equals("close")) { for(int i=0; i < str.length(); i++) { fos.write(str.charAt(i)); } fos.write(13); str = sc.next(); } fos.write(104); fos.close(); } }
580
0.627586
0.613793
25
21.200001
17.408045
64
false
false
0
0
0
0
0
0
2.16
false
false
13
cc3412b2292dbe5ae94116f543354f77ddc52d5a
14,525,579,445,832
fdd23f21fbbe5ff5444294b75494c94044750a2c
/MyWorkManagerWithNotification/app/src/main/java/com/muneiah/myworkmanagerwithnotification/SecondWork.java
728c8279a44a3b20005f6d1bc2d578597893d612
[]
no_license
AP-Skill-Development-Corporation/AAD-STP-BATCH-8
https://github.com/AP-Skill-Development-Corporation/AAD-STP-BATCH-8
24510afe99c65efa9a991bc76b53f9ac233c6893
4bc24bbed0321550620ee4d04a852f3ae7ec5f72
refs/heads/master
2022-12-11T22:23:18.344000
2020-08-21T04:17:04
2020-08-21T04:17:04
284,318,186
0
1
null
null
null
null
null
null
null
null
null
null
null
null
null
package com.muneiah.myworkmanagerwithnotification; import android.app.Notification; import android.app.NotificationChannel; import android.app.NotificationManager; import android.app.PendingIntent; import android.content.Context; import android.content.Intent; import android.graphics.Color; import android.os.Build; import androidx.annotation.NonNull; import androidx.core.app.NotificationCompat; import androidx.work.ListenableWorker; import androidx.work.Worker; import androidx.work.WorkerParameters; public class SecondWork extends Worker { NotificationManager nm; NotificationCompat.Builder builder; NotificationChannel nc; public static final String CHANNEL_ID="muneiahtellaakula.apssdc"; PendingIntent pi; Intent i; public SecondWork(@NonNull Context context, @NonNull WorkerParameters workerParams) { super(context, workerParams); } @NonNull @Override public ListenableWorker.Result doWork() { i=new Intent(getApplicationContext(),MainActivity.class); pi=PendingIntent.getActivity(getApplicationContext(),123,i, PendingIntent.FLAG_UPDATE_CURRENT); nm= (NotificationManager) getApplicationContext().getSystemService(Context.NOTIFICATION_SERVICE); createChannel(); showNotification(); return ListenableWorker.Result.success(); } public void createChannel(){ if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.O){ nc=new NotificationChannel(CHANNEL_ID,"workshopChannel",NotificationManager.IMPORTANCE_HIGH); nc.setLightColor(Color.BLUE); nc.enableVibration(true); nm.createNotificationChannel(nc); } } public void showNotification(){ builder=new NotificationCompat.Builder(getApplicationContext(),CHANNEL_ID); builder.setContentTitle("Apssdc Notification"); builder.setContentText("this is our Second Workclass Notification"); builder.setSmallIcon(R.drawable.ic_notifications_black_24dp); builder.setDefaults(Notification.DEFAULT_ALL); builder.setContentIntent(pi); nm.notify(12,builder.build()); } }
UTF-8
Java
2,167
java
SecondWork.java
Java
[]
null
[]
package com.muneiah.myworkmanagerwithnotification; import android.app.Notification; import android.app.NotificationChannel; import android.app.NotificationManager; import android.app.PendingIntent; import android.content.Context; import android.content.Intent; import android.graphics.Color; import android.os.Build; import androidx.annotation.NonNull; import androidx.core.app.NotificationCompat; import androidx.work.ListenableWorker; import androidx.work.Worker; import androidx.work.WorkerParameters; public class SecondWork extends Worker { NotificationManager nm; NotificationCompat.Builder builder; NotificationChannel nc; public static final String CHANNEL_ID="muneiahtellaakula.apssdc"; PendingIntent pi; Intent i; public SecondWork(@NonNull Context context, @NonNull WorkerParameters workerParams) { super(context, workerParams); } @NonNull @Override public ListenableWorker.Result doWork() { i=new Intent(getApplicationContext(),MainActivity.class); pi=PendingIntent.getActivity(getApplicationContext(),123,i, PendingIntent.FLAG_UPDATE_CURRENT); nm= (NotificationManager) getApplicationContext().getSystemService(Context.NOTIFICATION_SERVICE); createChannel(); showNotification(); return ListenableWorker.Result.success(); } public void createChannel(){ if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.O){ nc=new NotificationChannel(CHANNEL_ID,"workshopChannel",NotificationManager.IMPORTANCE_HIGH); nc.setLightColor(Color.BLUE); nc.enableVibration(true); nm.createNotificationChannel(nc); } } public void showNotification(){ builder=new NotificationCompat.Builder(getApplicationContext(),CHANNEL_ID); builder.setContentTitle("Apssdc Notification"); builder.setContentText("this is our Second Workclass Notification"); builder.setSmallIcon(R.drawable.ic_notifications_black_24dp); builder.setDefaults(Notification.DEFAULT_ALL); builder.setContentIntent(pi); nm.notify(12,builder.build()); } }
2,167
0.730964
0.727734
59
35.728813
25.526211
105
false
false
0
0
0
0
0
0
0.813559
false
false
13
bbd43258dc40ca0b915e015737d3b82e8252e0c2
27,066,883,922,008
8c80da0a51d64d0547b92fea5e00b8fa2fbb4bad
/src/NhanVienThoiVu.java
a635bec9e40327ff99c932422643f8b59d9bf895
[]
no_license
Bangtx/Java0
https://github.com/Bangtx/Java0
57c25006c167f5fb2e0e9d387baaf0dbc17ef540
4ef3dc8608ddf329fcf34500285c366fb913e114
refs/heads/master
2023-09-03T05:20:42.563000
2021-11-11T06:50:31
2021-11-11T06:50:31
426,678,378
0
1
null
null
null
null
null
null
null
null
null
null
null
null
null
public class NhanVienThoiVu extends NhanVIen{ @Override public int luong() { return 0; } }
UTF-8
Java
111
java
NhanVienThoiVu.java
Java
[]
null
[]
public class NhanVienThoiVu extends NhanVIen{ @Override public int luong() { return 0; } }
111
0.621622
0.612613
6
17.5
14.419315
45
false
false
0
0
0
0
0
0
0.166667
false
false
13
73a183c194a31030be9dd8750ab6a2288cadbe1f
21,105,469,323,040
3db31a63b61470d50ad59e2c251c1ca9fb892085
/src/com/ing/usedbooks/net/SellTime.java
3a51bb049161dd948582bd02154999da7464c0cc
[]
no_license
antdlx/UsedBooks
https://github.com/antdlx/UsedBooks
773ab3c43b269a01b42e64900efa002f886b1140
ad8f656c6ee2aa76b952cfb9c28b1b1cc3ff71a1
refs/heads/master
2021-01-10T13:48:58.390000
2016-03-08T13:39:24
2016-03-08T13:39:24
53,413,560
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
package com.ing.usedbooks.net; public class SellTime { public SellTime(String sell_time,String id,final SuccessCallback successCallback,final FailCallback failCallback){ new NetConnection(Config.SERVER_URL_SELLTIME, new NetConnection.SuccessCallback() { @Override public void onSuccess(String result) { } }, new NetConnection.FailCallback() { @Override public void onFail() { } }, Config.KEY_SELLTIME,sell_time, Config.KEY_BID,id); } public static interface SuccessCallback{ void onSuccess(); } public static interface FailCallback{ void onFail(); } }
UTF-8
Java
618
java
SellTime.java
Java
[]
null
[]
package com.ing.usedbooks.net; public class SellTime { public SellTime(String sell_time,String id,final SuccessCallback successCallback,final FailCallback failCallback){ new NetConnection(Config.SERVER_URL_SELLTIME, new NetConnection.SuccessCallback() { @Override public void onSuccess(String result) { } }, new NetConnection.FailCallback() { @Override public void onFail() { } }, Config.KEY_SELLTIME,sell_time, Config.KEY_BID,id); } public static interface SuccessCallback{ void onSuccess(); } public static interface FailCallback{ void onFail(); } }
618
0.705502
0.705502
31
18.935484
25.700428
115
false
false
0
0
0
0
0
0
2.225806
false
false
13
a1e5a2a25f194733b10155b1b2b75d65f41c5626
4,776,003,659,893
d04fa76985bd3f40d1af726e76806dbe8870e0cb
/xiyou-shop-admin/src/main/java/com/xiyou/admin/controller/ProductController.java
2a3ca148c2441791d9ae8eb58f384628ec122c44
[]
no_license
Sunbefore/xiyou-shop
https://github.com/Sunbefore/xiyou-shop
962705b5560199ebe30a298884a190f70be738e3
6497fc925881f0ebff35d43be1a3d9ad256991e4
refs/heads/master
2022-06-30T13:10:04.437000
2019-06-24T15:58:25
2019-06-24T15:58:25
187,659,759
0
0
null
false
2022-06-17T02:14:07
2019-05-20T14:45:46
2019-06-24T15:58:42
2022-06-17T02:14:05
910
0
0
14
CSS
false
false
package com.xiyou.admin.controller; import com.xiyou.admin.service.ProductDetailService; import com.xiyou.admin.service.ProductService; import com.xiyou.common.model.Product; import com.xiyou.common.model.ProductDetail; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Controller; import org.springframework.ui.Model; import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.PathVariable; import org.springframework.web.bind.annotation.PostMapping; import java.util.Date; import java.util.List; @Controller public class ProductController { @Autowired private ProductService productService; @Autowired private ProductDetailService productDetailService; /** * 通过productTypeId查询Product * @param proudctTypeId * @return */ @GetMapping(value = "/listProductOut/{proudctTypeId}") public String listProductOut(@PathVariable("proudctTypeId") Integer proudctTypeId, Model model){ List<Product> productList = productService.listProductOut(proudctTypeId); model.addAttribute("productList", productList); return "listproduct"; } /** * 跳转到新增商品的页面 * @return */ @GetMapping("/toInsertProduct") public String toInsertProduct(){ return "addproduct"; } /** * 添加商品 * @param product * @return */ @PostMapping("/insertProduct") public void insertProduct(Product product){ product.setCreatetime(new Date()); product.setSellnum(0); // 默认是上架 product.setProductstatus(0); productService.insertOutProduct(product); } /** * 根据id删除某一个产品 * @param id */ @GetMapping("/deleteProduct/{id}") public String deleteProduct(@PathVariable Integer id){ productService.deleteOutProduct(id); return "listproduct"; } /** * 根據id查看其产品信息 * @param id * @param model * @return */ @GetMapping("/toViewProduct/{id}") public String toViewProduct(@PathVariable Integer id, Model model){ Product product = productService.viewOutProduct(id); model.addAttribute("product", product); return "viewproduct"; } /** * 跳转到更改信息的界面 * @param id * @return */ @GetMapping("/toUpdateProduct/{id}") public String toUpdateProduct(@PathVariable Integer id, Model model){ Product product = productService.viewOutProduct(id); model.addAttribute("product", product); return "updateproduct"; } /** * 更改产品的相关信息 * @param product */ @PostMapping("/updateProduct") public void updateProduct(Product product){ productService.updateOutProduct(product); } /** * 跳转到新增产品信息页面 * @param id * @param model * @return */ @GetMapping(value = "/toAddProductDetail/{id}") public String toAddProductDetail(@PathVariable Integer id, Model model){ model.addAttribute("id", id); return "addproductdetail"; } /** * 新增产品详情 * @param productDetail */ @PostMapping(value = "/insertProductDetail") public void insertProductDetail(ProductDetail productDetail){ productDetailService.insertProductDetail(productDetail); } }
UTF-8
Java
3,494
java
ProductController.java
Java
[]
null
[]
package com.xiyou.admin.controller; import com.xiyou.admin.service.ProductDetailService; import com.xiyou.admin.service.ProductService; import com.xiyou.common.model.Product; import com.xiyou.common.model.ProductDetail; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Controller; import org.springframework.ui.Model; import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.PathVariable; import org.springframework.web.bind.annotation.PostMapping; import java.util.Date; import java.util.List; @Controller public class ProductController { @Autowired private ProductService productService; @Autowired private ProductDetailService productDetailService; /** * 通过productTypeId查询Product * @param proudctTypeId * @return */ @GetMapping(value = "/listProductOut/{proudctTypeId}") public String listProductOut(@PathVariable("proudctTypeId") Integer proudctTypeId, Model model){ List<Product> productList = productService.listProductOut(proudctTypeId); model.addAttribute("productList", productList); return "listproduct"; } /** * 跳转到新增商品的页面 * @return */ @GetMapping("/toInsertProduct") public String toInsertProduct(){ return "addproduct"; } /** * 添加商品 * @param product * @return */ @PostMapping("/insertProduct") public void insertProduct(Product product){ product.setCreatetime(new Date()); product.setSellnum(0); // 默认是上架 product.setProductstatus(0); productService.insertOutProduct(product); } /** * 根据id删除某一个产品 * @param id */ @GetMapping("/deleteProduct/{id}") public String deleteProduct(@PathVariable Integer id){ productService.deleteOutProduct(id); return "listproduct"; } /** * 根據id查看其产品信息 * @param id * @param model * @return */ @GetMapping("/toViewProduct/{id}") public String toViewProduct(@PathVariable Integer id, Model model){ Product product = productService.viewOutProduct(id); model.addAttribute("product", product); return "viewproduct"; } /** * 跳转到更改信息的界面 * @param id * @return */ @GetMapping("/toUpdateProduct/{id}") public String toUpdateProduct(@PathVariable Integer id, Model model){ Product product = productService.viewOutProduct(id); model.addAttribute("product", product); return "updateproduct"; } /** * 更改产品的相关信息 * @param product */ @PostMapping("/updateProduct") public void updateProduct(Product product){ productService.updateOutProduct(product); } /** * 跳转到新增产品信息页面 * @param id * @param model * @return */ @GetMapping(value = "/toAddProductDetail/{id}") public String toAddProductDetail(@PathVariable Integer id, Model model){ model.addAttribute("id", id); return "addproductdetail"; } /** * 新增产品详情 * @param productDetail */ @PostMapping(value = "/insertProductDetail") public void insertProductDetail(ProductDetail productDetail){ productDetailService.insertProductDetail(productDetail); } }
3,494
0.664371
0.663772
131
24.496183
22.138487
100
false
false
0
0
0
0
0
0
0.328244
false
false
13
86b17c8b44356fd634c85d0077dc2f9c927ae7a3
18,537,078,875,889
7835ce234bd27c3de6ad3723b0918b0b15caf903
/distributed-systems/SDFS/source/SDFSServer/src/org/sdfs/server/service/Server2ClientNEW.java
e06a6a9feefd45ca93033f75e58351b09f5babdb
[]
no_license
IcaroJerry/sand-box
https://github.com/IcaroJerry/sand-box
e3b8ac5c7d344c22f7ff61c178a138d6ee3ebfb4
b50c885d26566a130a062c76802d87aa194cbadc
refs/heads/master
2021-01-19T21:55:37.051000
2017-04-30T01:27:08
2017-04-30T01:27:08
88,724,919
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
package org.sdfs.server.service; import java.io.IOException; import java.io.ObjectInputStream; import java.io.ObjectOutputStream; import java.net.ServerSocket; import java.net.Socket; import java.util.HashMap; import java.util.Map; import java.util.logging.Level; import java.util.logging.Logger; public class Server2ClientNEW { public Server2ClientNEW() { try { tcpSocket = new ServerSocket(0); while (true) { socket = tcpSocket.accept(); new Thread(new ListenerSocket(socket)).start(); } } catch (IOException ex) { Logger.getLogger(Server2ClientNEW.class.getName()).log(Level.SEVERE, null, ex); } } private ServerSocket tcpSocket; private Socket socket; private Map<String, ObjectOutputStream> onlines = new HashMap<>(); private class ListenerSocket implements Runnable { public ListenerSocket(Socket socket) { try { this.objOut = new ObjectOutputStream(socket.getOutputStream()); this.objIn = new ObjectInputStream(socket.getInputStream()); } catch (IOException ex) { Logger.getLogger(Server2ClientNEW.class.getName()).log(Level.SEVERE, null, ex); } } @Override public void run() { // ClientAction message = null; // // try { // while ((message = (ClientAction) objIn.readObject()) != null) { // //message // } // } catch (IOException ex) { // Logger.getLogger(Server2ClientNEW.class.getName()).log(Level.SEVERE, null, ex); // } catch (ClassNotFoundException ex) { // Logger.getLogger(Server2ClientNEW.class.getName()).log(Level.SEVERE, null, ex); // } } private ObjectOutputStream objOut; private ObjectInputStream objIn; } }
UTF-8
Java
1,934
java
Server2ClientNEW.java
Java
[]
null
[]
package org.sdfs.server.service; import java.io.IOException; import java.io.ObjectInputStream; import java.io.ObjectOutputStream; import java.net.ServerSocket; import java.net.Socket; import java.util.HashMap; import java.util.Map; import java.util.logging.Level; import java.util.logging.Logger; public class Server2ClientNEW { public Server2ClientNEW() { try { tcpSocket = new ServerSocket(0); while (true) { socket = tcpSocket.accept(); new Thread(new ListenerSocket(socket)).start(); } } catch (IOException ex) { Logger.getLogger(Server2ClientNEW.class.getName()).log(Level.SEVERE, null, ex); } } private ServerSocket tcpSocket; private Socket socket; private Map<String, ObjectOutputStream> onlines = new HashMap<>(); private class ListenerSocket implements Runnable { public ListenerSocket(Socket socket) { try { this.objOut = new ObjectOutputStream(socket.getOutputStream()); this.objIn = new ObjectInputStream(socket.getInputStream()); } catch (IOException ex) { Logger.getLogger(Server2ClientNEW.class.getName()).log(Level.SEVERE, null, ex); } } @Override public void run() { // ClientAction message = null; // // try { // while ((message = (ClientAction) objIn.readObject()) != null) { // //message // } // } catch (IOException ex) { // Logger.getLogger(Server2ClientNEW.class.getName()).log(Level.SEVERE, null, ex); // } catch (ClassNotFoundException ex) { // Logger.getLogger(Server2ClientNEW.class.getName()).log(Level.SEVERE, null, ex); // } } private ObjectOutputStream objOut; private ObjectInputStream objIn; } }
1,934
0.598759
0.59514
63
29.698412
26.64382
97
false
false
0
0
0
0
0
0
0.539683
false
false
13
28a82a013324738524db904f3744291e02790e86
27,187,143,004,380
e4fc5d3753fbf1ee60fc316875eea5ff7ed94941
/src/main/java/com/project/DigitalBank/dtos/RegistrationInformationDto.java
c63cd2ddf9a5c46e52c41482e6699b37c55e274a
[]
no_license
cavieira/DigitalBank
https://github.com/cavieira/DigitalBank
4b6c6cff275b4c200029546b8309086cba2a7f4b
3b3b2a824173ad5679905c47c48b246a1285aaad
refs/heads/main
2023-01-02T02:23:21.241000
2020-10-28T09:45:46
2020-10-28T09:45:46
304,959,186
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
package com.project.DigitalBank.dtos; import lombok.AllArgsConstructor; import lombok.Builder; import lombok.Value; import java.time.LocalDate; @Value @AllArgsConstructor @Builder(toBuilder = true) public class RegistrationInformationDto { String firstName; String lastName; String email; LocalDate birthDate; String cpf; String cep; String rua; String bairro; String complemento; String cidade; String estado; }
UTF-8
Java
471
java
RegistrationInformationDto.java
Java
[ { "context": "lic class RegistrationInformationDto {\n\n String firstName;\n\n String lastName;\n\n String email;\n\n Lo", "end": 264, "score": 0.9615813493728638, "start": 255, "tag": "NAME", "value": "firstName" }, { "context": "nformationDto {\n\n String firstName;\n\n String lastName;\n\n String email;\n\n LocalDate birthDate;\n\n ", "end": 286, "score": 0.977154552936554, "start": 278, "tag": "NAME", "value": "lastName" } ]
null
[]
package com.project.DigitalBank.dtos; import lombok.AllArgsConstructor; import lombok.Builder; import lombok.Value; import java.time.LocalDate; @Value @AllArgsConstructor @Builder(toBuilder = true) public class RegistrationInformationDto { String firstName; String lastName; String email; LocalDate birthDate; String cpf; String cep; String rua; String bairro; String complemento; String cidade; String estado; }
471
0.719745
0.719745
35
12.457143
12.278536
41
false
false
0
0
0
0
0
0
0.457143
false
false
13
d88e95e9038f0fa4c9d98a671bf662c9c2763f10
4,621,384,849,133
53de1f6248ce038af05fb9885ec4cc5fdddf5bbe
/src/main/java/com/infinityraider/infinitylib/block/tile/InfinityTileEntityType.java
51fc0b28b785fcfa1ff36a6554e5bd2c752ce137
[ "MIT" ]
permissive
ArthixFR/InfinityLib
https://github.com/ArthixFR/InfinityLib
b1dad6ade2d1313e49c94b118f6dd02de0fc3225
5c90048cfe931edd127e566546c7dc42f4a14fcf
refs/heads/master
2023-08-01T06:52:08.307000
2021-09-11T15:59:44
2021-09-11T15:59:44
405,420,312
0
0
MIT
true
2021-09-11T15:54:35
2021-09-11T15:54:35
2021-09-06T21:52:37
2021-09-06T21:52:34
1,296
0
0
0
null
false
false
package com.infinityraider.infinitylib.block.tile; import com.google.common.collect.Sets; import com.infinityraider.infinitylib.render.tile.ITileRenderer; import net.minecraft.block.Block; import net.minecraft.tileentity.TileEntity; import net.minecraft.tileentity.TileEntityType; import net.minecraftforge.api.distmarker.Dist; import net.minecraftforge.api.distmarker.OnlyIn; import javax.annotation.Nonnull; import javax.annotation.Nullable; import java.util.Arrays; import java.util.Collection; import java.util.Set; import java.util.function.Supplier; public class InfinityTileEntityType<T extends TileEntity> extends TileEntityType<T> implements IInfinityTileEntityType { private final String name; private final IRenderFactory<T> renderFactory; @OnlyIn(Dist.CLIENT) private ITileRenderer<T> renderer; private InfinityTileEntityType(String name, Supplier<? extends T> factory, Set<Block> validBlocks, IRenderFactory<T> renderFactory) { super(factory, validBlocks, null); this.name = name; this.renderFactory = renderFactory; } @Nonnull @Override public String getInternalName() { return this.name; } @Override public boolean isEnabled() { return true; } @Override @Nullable @OnlyIn(Dist.CLIENT) public ITileRenderer<T> getRenderer() { if (this.renderer == null) { this.renderer = this.renderFactory.createRenderer(); } return this.renderer; } public static <T extends TileEntity> Builder<T> builder(String name, Supplier<? extends T> factory) { return new Builder<>(name, factory); } public static final class Builder<T extends TileEntity> { private final String name; private final Supplier<? extends T> factory; private final Set<Block> blocks; private IRenderFactory<T> renderFactory; private Builder(String name, Supplier<? extends T> factory) { this.name = name; this.factory = factory; this.blocks = Sets.newIdentityHashSet(); this.renderFactory = noRenderer(); } public Builder<T> addBlock(Block block) { this.blocks.add(block); return this; } public Builder<T> addBlocks(Collection<Block> block) { this.blocks.addAll(block); return this; } public Builder<T> addBlocks(Block... blocks) { Arrays.stream(blocks).forEach(this::addBlock); return this; } public Builder<T> setRenderFactory(IRenderFactory<T> factory) { this.renderFactory = factory; return this; } public InfinityTileEntityType<T> build() { return new InfinityTileEntityType<T>(this.name, this.factory, this.blocks, this.renderFactory); } } public static <T extends TileEntity> IRenderFactory<T> noRenderer() { return new NoRenderFactory<>(); } public interface IRenderFactory<T extends TileEntity> { @Nullable @OnlyIn(Dist.CLIENT) ITileRenderer<T> createRenderer(); } private static final class NoRenderFactory<T extends TileEntity> implements IRenderFactory<T> { @Override @Nullable @OnlyIn(Dist.CLIENT) public ITileRenderer<T> createRenderer() { return null; } } }
UTF-8
Java
3,425
java
InfinityTileEntityType.java
Java
[]
null
[]
package com.infinityraider.infinitylib.block.tile; import com.google.common.collect.Sets; import com.infinityraider.infinitylib.render.tile.ITileRenderer; import net.minecraft.block.Block; import net.minecraft.tileentity.TileEntity; import net.minecraft.tileentity.TileEntityType; import net.minecraftforge.api.distmarker.Dist; import net.minecraftforge.api.distmarker.OnlyIn; import javax.annotation.Nonnull; import javax.annotation.Nullable; import java.util.Arrays; import java.util.Collection; import java.util.Set; import java.util.function.Supplier; public class InfinityTileEntityType<T extends TileEntity> extends TileEntityType<T> implements IInfinityTileEntityType { private final String name; private final IRenderFactory<T> renderFactory; @OnlyIn(Dist.CLIENT) private ITileRenderer<T> renderer; private InfinityTileEntityType(String name, Supplier<? extends T> factory, Set<Block> validBlocks, IRenderFactory<T> renderFactory) { super(factory, validBlocks, null); this.name = name; this.renderFactory = renderFactory; } @Nonnull @Override public String getInternalName() { return this.name; } @Override public boolean isEnabled() { return true; } @Override @Nullable @OnlyIn(Dist.CLIENT) public ITileRenderer<T> getRenderer() { if (this.renderer == null) { this.renderer = this.renderFactory.createRenderer(); } return this.renderer; } public static <T extends TileEntity> Builder<T> builder(String name, Supplier<? extends T> factory) { return new Builder<>(name, factory); } public static final class Builder<T extends TileEntity> { private final String name; private final Supplier<? extends T> factory; private final Set<Block> blocks; private IRenderFactory<T> renderFactory; private Builder(String name, Supplier<? extends T> factory) { this.name = name; this.factory = factory; this.blocks = Sets.newIdentityHashSet(); this.renderFactory = noRenderer(); } public Builder<T> addBlock(Block block) { this.blocks.add(block); return this; } public Builder<T> addBlocks(Collection<Block> block) { this.blocks.addAll(block); return this; } public Builder<T> addBlocks(Block... blocks) { Arrays.stream(blocks).forEach(this::addBlock); return this; } public Builder<T> setRenderFactory(IRenderFactory<T> factory) { this.renderFactory = factory; return this; } public InfinityTileEntityType<T> build() { return new InfinityTileEntityType<T>(this.name, this.factory, this.blocks, this.renderFactory); } } public static <T extends TileEntity> IRenderFactory<T> noRenderer() { return new NoRenderFactory<>(); } public interface IRenderFactory<T extends TileEntity> { @Nullable @OnlyIn(Dist.CLIENT) ITileRenderer<T> createRenderer(); } private static final class NoRenderFactory<T extends TileEntity> implements IRenderFactory<T> { @Override @Nullable @OnlyIn(Dist.CLIENT) public ITileRenderer<T> createRenderer() { return null; } } }
3,425
0.658102
0.658102
113
29.309734
27.254642
137
false
false
0
0
0
0
0
0
0.495575
false
false
13
8b73eea56b24a55809dde1ca4d075866fcfa5428
21,079,699,501,240
f38b812c0970ca16318d64b8a03d6095a67d0232
/app/src/main/java/com/example/la/myclass/beans/periodic/Month.java
d556d077cbf3eec810bef5d3bd6ee692460ffc43
[]
no_license
Gaminho/MyClass
https://github.com/Gaminho/MyClass
feb23c0e11086d1051b68a2de3dc2acedd1da71c
d87c3d47ac06e72ae4825a74906b5495421a40cf
refs/heads/master
2021-05-03T19:15:09.535000
2018-10-01T11:50:25
2018-10-01T11:50:25
70,047,704
1
0
null
null
null
null
null
null
null
null
null
null
null
null
null
package com.example.la.myclass.beans.periodic; import com.example.la.myclass.C; import java.util.Calendar; /** * Created by Gaminho on 21/09/2016. */ public class Month extends PeriodicItem { public Month(int nbOfCourses, double money, long beginning) { this.beginning = beginning; this.money = money; this.nbCourse = nbOfCourses; Calendar calendar = Calendar.getInstance(); calendar.setTimeInMillis(beginning); this.label = C.formatDate(beginning, C.MONTH_YEAR); } @Override public String toString() { return "Month{" + "beginning=" + beginning + ", label='" + label + '\'' + ", money=" + money + ", nbOfCourses=" + nbCourse + '}'; } }
UTF-8
Java
802
java
Month.java
Java
[ { "context": ".C;\n\nimport java.util.Calendar;\n\n/**\n * Created by Gaminho on 21/09/2016.\n */\npublic class Month extends ", "end": 133, "score": 0.5711430311203003, "start": 128, "tag": "NAME", "value": "Gamin" }, { "context": "mport java.util.Calendar;\n\n/**\n * Created by Gaminho on 21/09/2016.\n */\npublic class Month extends Pe", "end": 135, "score": 0.6424539685249329, "start": 133, "tag": "USERNAME", "value": "ho" } ]
null
[]
package com.example.la.myclass.beans.periodic; import com.example.la.myclass.C; import java.util.Calendar; /** * Created by Gaminho on 21/09/2016. */ public class Month extends PeriodicItem { public Month(int nbOfCourses, double money, long beginning) { this.beginning = beginning; this.money = money; this.nbCourse = nbOfCourses; Calendar calendar = Calendar.getInstance(); calendar.setTimeInMillis(beginning); this.label = C.formatDate(beginning, C.MONTH_YEAR); } @Override public String toString() { return "Month{" + "beginning=" + beginning + ", label='" + label + '\'' + ", money=" + money + ", nbOfCourses=" + nbCourse + '}'; } }
802
0.571072
0.561097
31
24.870968
19.981834
65
false
false
0
0
0
0
0
0
0.516129
false
false
13
1f1a475812dd643623a705e245c1ed7c9259b908
7,636,451,868,531
4914865e5738f79555a7452139456c861ff310d2
/src/main/java/com/hll/test/dao/domain/UserInfo.java
7476066b6b64464ca90cfbf7f9b1cf9d61375187
[]
no_license
AshShawn/devConsole
https://github.com/AshShawn/devConsole
b114d14de5d82129c5c8bddcd7b6e7e75cb11753
165e76f1e4f6d7d8889d132e3440200733fb9a20
refs/heads/master
2022-12-21T19:25:35.370000
2019-06-10T15:31:16
2019-06-10T15:31:16
188,207,210
0
0
null
false
2022-12-16T01:26:42
2019-05-23T09:52:07
2019-06-10T15:31:29
2022-12-16T01:26:39
4,237
0
0
8
Java
false
false
package com.hll.test.dao.domain; /** * * This class was generated by MyBatis Generator. * This class corresponds to the database table userinfo * * @mbg.generated do_not_delete_during_merge */ public class UserInfo { /** * Database Column Remarks: * 用户编号 * * This field was generated by MyBatis Generator. * This field corresponds to the database column userinfo.userID * * @mbg.generated */ private Integer userID; /** * Database Column Remarks: * 角色编号 0需求人员,1开发人员 2测试人员 3超级管理员 * * This field was generated by MyBatis Generator. * This field corresponds to the database column userinfo.roleID * * @mbg.generated */ private Integer roleID; /** * Database Column Remarks: * 是否为领导 0不是 1是 * * This field was generated by MyBatis Generator. * This field corresponds to the database column userinfo.isLeader * * @mbg.generated */ private Integer isLeader; /** * Database Column Remarks: * 密码 最多20位 md5加密 * * This field was generated by MyBatis Generator. * This field corresponds to the database column userinfo.password * * @mbg.generated */ private String password; /** * Database Column Remarks: * 用户名,显示名称 * * This field was generated by MyBatis Generator. * This field corresponds to the database column userinfo.userName * * @mbg.generated */ private String userName; /** * This method was generated by MyBatis Generator. * This method returns the value of the database column userinfo.userID * * @return the value of userinfo.userID * * @mbg.generated */ public Integer getUserID() { return userID; } /** * This method was generated by MyBatis Generator. * This method sets the value of the database column userinfo.userID * * @param userID the value for userinfo.userID * * @mbg.generated */ public void setUserID(Integer userID) { this.userID = userID; } /** * This method was generated by MyBatis Generator. * This method returns the value of the database column userinfo.roleID * * @return the value of userinfo.roleID * * @mbg.generated */ public Integer getRoleID() { return roleID; } /** * This method was generated by MyBatis Generator. * This method sets the value of the database column userinfo.roleID * * @param roleID the value for userinfo.roleID * * @mbg.generated */ public void setRoleID(Integer roleID) { this.roleID = roleID; } /** * This method was generated by MyBatis Generator. * This method returns the value of the database column userinfo.isLeader * * @return the value of userinfo.isLeader * * @mbg.generated */ public Integer getIsLeader() { return isLeader; } /** * This method was generated by MyBatis Generator. * This method sets the value of the database column userinfo.isLeader * * @param isLeader the value for userinfo.isLeader * * @mbg.generated */ public void setIsLeader(Integer isLeader) { this.isLeader = isLeader; } /** * This method was generated by MyBatis Generator. * This method returns the value of the database column userinfo.password * * @return the value of userinfo.password * * @mbg.generated */ public String getPassword() { return password; } /** * This method was generated by MyBatis Generator. * This method sets the value of the database column userinfo.password * * @param password the value for userinfo.password * * @mbg.generated */ public void setPassword(String password) { this.password = password == null ? null : password.trim(); } /** * This method was generated by MyBatis Generator. * This method returns the value of the database column userinfo.userName * * @return the value of userinfo.userName * * @mbg.generated */ public String getUserName() { return userName; } /** * This method was generated by MyBatis Generator. * This method sets the value of the database column userinfo.userName * * @param userName the value for userinfo.userName * * @mbg.generated */ public void setUserName(String userName) { this.userName = userName == null ? null : userName.trim(); } }
UTF-8
Java
4,764
java
UserInfo.java
Java
[]
null
[]
package com.hll.test.dao.domain; /** * * This class was generated by MyBatis Generator. * This class corresponds to the database table userinfo * * @mbg.generated do_not_delete_during_merge */ public class UserInfo { /** * Database Column Remarks: * 用户编号 * * This field was generated by MyBatis Generator. * This field corresponds to the database column userinfo.userID * * @mbg.generated */ private Integer userID; /** * Database Column Remarks: * 角色编号 0需求人员,1开发人员 2测试人员 3超级管理员 * * This field was generated by MyBatis Generator. * This field corresponds to the database column userinfo.roleID * * @mbg.generated */ private Integer roleID; /** * Database Column Remarks: * 是否为领导 0不是 1是 * * This field was generated by MyBatis Generator. * This field corresponds to the database column userinfo.isLeader * * @mbg.generated */ private Integer isLeader; /** * Database Column Remarks: * 密码 最多20位 md5加密 * * This field was generated by MyBatis Generator. * This field corresponds to the database column userinfo.password * * @mbg.generated */ private String password; /** * Database Column Remarks: * 用户名,显示名称 * * This field was generated by MyBatis Generator. * This field corresponds to the database column userinfo.userName * * @mbg.generated */ private String userName; /** * This method was generated by MyBatis Generator. * This method returns the value of the database column userinfo.userID * * @return the value of userinfo.userID * * @mbg.generated */ public Integer getUserID() { return userID; } /** * This method was generated by MyBatis Generator. * This method sets the value of the database column userinfo.userID * * @param userID the value for userinfo.userID * * @mbg.generated */ public void setUserID(Integer userID) { this.userID = userID; } /** * This method was generated by MyBatis Generator. * This method returns the value of the database column userinfo.roleID * * @return the value of userinfo.roleID * * @mbg.generated */ public Integer getRoleID() { return roleID; } /** * This method was generated by MyBatis Generator. * This method sets the value of the database column userinfo.roleID * * @param roleID the value for userinfo.roleID * * @mbg.generated */ public void setRoleID(Integer roleID) { this.roleID = roleID; } /** * This method was generated by MyBatis Generator. * This method returns the value of the database column userinfo.isLeader * * @return the value of userinfo.isLeader * * @mbg.generated */ public Integer getIsLeader() { return isLeader; } /** * This method was generated by MyBatis Generator. * This method sets the value of the database column userinfo.isLeader * * @param isLeader the value for userinfo.isLeader * * @mbg.generated */ public void setIsLeader(Integer isLeader) { this.isLeader = isLeader; } /** * This method was generated by MyBatis Generator. * This method returns the value of the database column userinfo.password * * @return the value of userinfo.password * * @mbg.generated */ public String getPassword() { return password; } /** * This method was generated by MyBatis Generator. * This method sets the value of the database column userinfo.password * * @param password the value for userinfo.password * * @mbg.generated */ public void setPassword(String password) { this.password = password == null ? null : password.trim(); } /** * This method was generated by MyBatis Generator. * This method returns the value of the database column userinfo.userName * * @return the value of userinfo.userName * * @mbg.generated */ public String getUserName() { return userName; } /** * This method was generated by MyBatis Generator. * This method sets the value of the database column userinfo.userName * * @param userName the value for userinfo.userName * * @mbg.generated */ public void setUserName(String userName) { this.userName = userName == null ? null : userName.trim(); } }
4,764
0.617559
0.615632
185
24.24865
22.959019
77
false
false
0
0
0
0
0
0
0.097297
false
false
13
db71b0fa14e0e7fecb3f1081fa9cd97ec5aa54c2
26,903,675,199,033
5fd23d3b8edf19b36c2fe38c1469198b93ec2fbe
/src/com/bank/dao/CustomerDAO.java
908fbaf06af07ea8048b91cffff4bd9559c47b18
[]
no_license
mahesh4kc/test
https://github.com/mahesh4kc/test
8fcb91b0225cca1fb549615ac9ff1db631cfcc58
c69de6c06854c6e3d0f7b724296697cfb3624290
refs/heads/master
2021-07-17T06:52:32.773000
2018-07-07T07:55:04
2018-07-07T07:55:04
140,059,890
1
0
null
null
null
null
null
null
null
null
null
null
null
null
null
package com.bank.dao; import java.sql.Connection; import java.sql.PreparedStatement; import java.sql.ResultSet; import java.sql.SQLException; import java.util.ArrayList; import java.util.List; import com.bank.bo.CustomerBO; import com.bank.bo.ParametersBO; import com.bank.form.SearchMasterScreenForm; import com.bank.helper.CustomerHelper; import com.bank.util.BankConstant; import com.bank.util.FilterClausesConstant; public class CustomerDAO extends BankDAO{ public static final String CLASS_NAME = "CusomterDatabase"; public static final String CREATE_CUSTOMER = "INSERT INTO CUSTOMER (CUSTOMERID, " + "CUSTOMERNAME, ADDRESS, STREET, AREA, DISTRICT, STATE, COUNTRY, PINCODE, PHOTO, " + "PHONENO, MOBILENO, MAILID , RELATIONSHIP, RELATIONNAME) VALUES (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)"; public static final String UPDATE_CUSTOMER = "UPDATE CUSTOMER SET CUSTOMERNAME = ?, " + " ADDRESS = ?, STREET =? , AREA = ?, DISTRICT =? , STATE = ?, COUNTRY =? , PINCODE = ?, " + "PHOTO =? , PHONENO = ?, MOBILENO =? , MAILID = ?, RELATIONSHIP = ? , RELATIONNAME = ? WHERE CUSTOMERID = ?"; public static final String DELETE_CUSTOMER = "DELETE FROM CUSTOMER WHERE CUSTOMERID = ?"; public static final String SELECT_ALL_CUSTOMER = "SELECT " + "CUSTOMERID, CUSTOMERNAME, ADDRESS, STREET, AREA, DISTRICT, STATE, COUNTRY, PINCODE, PHOTO, " + "PHONENO, MOBILENO, MAILID,RELATIONSHIP, RELATIONNAME FROM CUSTOMER "; public static final String SELECT_CUSTOMER_ID_EQUAL = SELECT_ALL_CUSTOMER + FilterClausesConstant.WHERE + " CUSTOMERID " + FilterClausesConstant.EQUAL + FilterClausesConstant.QUESTIONAIRE ; public static final String SELECT_CUSTOMER_NAME_EQUAL = SELECT_ALL_CUSTOMER + FilterClausesConstant.WHERE + " CUSTOMERNAME " + FilterClausesConstant.EQUAL + FilterClausesConstant.QUESTIONAIRE ; public static final String SELECT_CUSTOMER_ID_IN = SELECT_ALL_CUSTOMER + FilterClausesConstant.WHERE + " CUSTOMERID " + FilterClausesConstant.IN ; public static final String SELECT_CUSTOMER_ID_NAME_LIKE = SELECT_ALL_CUSTOMER + FilterClausesConstant.WHERE + //" CUSTOMERID " + FilterClauses.LIKE + FilterClauses.QUESTIONAIRE + FilterClauses.AND + " CUSTOMERNAME " + FilterClausesConstant.LIKE + FilterClausesConstant.QUESTIONAIRE ; public static final String SELECT_CUSTOMER_NAME_LIKE = SELECT_ALL_CUSTOMER + FilterClausesConstant.WHERE + //" CUSTOMERID " + FilterClauses.LIKE + FilterClauses.QUESTIONAIRE + FilterClauses.AND + " CUSTOMERNAME " + FilterClausesConstant.LIKE + FilterClausesConstant.QUESTIONAIRE ; public static final String SELECT_CUSTOMER_ID_NAME_ADDRESS_STREET_AREA_MOBILE_LIKE = SELECT_ALL_CUSTOMER + FilterClausesConstant.WHERE + " CUSTOMERID " + FilterClausesConstant.LIKE + FilterClausesConstant.QUESTIONAIRE + FilterClausesConstant.AND + " CUSTOMERNAME " + FilterClausesConstant.LIKE + FilterClausesConstant.QUESTIONAIRE + FilterClausesConstant.AND + " ADDRESS " + FilterClausesConstant.LIKE + FilterClausesConstant.QUESTIONAIRE + FilterClausesConstant.AND + " STREET " + FilterClausesConstant.LIKE + FilterClausesConstant.QUESTIONAIRE + FilterClausesConstant.AND + " AREA " + FilterClausesConstant.LIKE + FilterClausesConstant.QUESTIONAIRE + FilterClausesConstant.AND + " MOBILENO " + FilterClausesConstant.LIKE + FilterClausesConstant.QUESTIONAIRE ; /* *public static final String SELECT_CUSTOMER_CODE = "SELECT PRODUCTTYPENO, " + "PRODUCTTYPECODE, PRODUCTTYPEDESCRIPTION, RATEOFINTEREST FROM PRODUCTTYPE WHERE " + "PRODUCTTYPECODE = ?"; */ public static final String SELECT_CUSTOMER_MAX_NO = "SELECT MAX(CUSTOMERID) FROM CUSTOMER"; private String jndiName; public String getJndiName() { return this.jndiName; } public void setJndiName(String jndiName) { this.jndiName = jndiName; } /* * */ public CustomerDAO(String jndiName) { super(); //objConnection = getConnection(jndiName); this.jndiName = jndiName; } public void createCustomer(CustomerBO objCustomerBO ) throws SQLException{ final String METHOD_NAME = "createCustomer"; Connection objConnection = getConnection(this.jndiName); PreparedStatement objPreparedStatement = null; int noOfInsertedRecords =0; int customerSequence =0; try{ //objConnection = getConnection(); //System.out.println("Connection is Alive : " + !objConnection.isClosed()); objPreparedStatement = objConnection.prepareStatement(CREATE_CUSTOMER); customerSequence = getMaxCustomerNo();//System.out.println(" Next Sequence for Customer is : " + customerSequence); objPreparedStatement.setInt(1, new Integer(customerSequence)); objPreparedStatement.setString(2, objCustomerBO.getName() != null ? objCustomerBO.getName().toUpperCase():""); objPreparedStatement.setString(3, objCustomerBO.getAddress() != null ? objCustomerBO.getAddress().toUpperCase():""); objPreparedStatement.setString(4, objCustomerBO.getStreet() != null ? objCustomerBO.getStreet().toUpperCase():""); objPreparedStatement.setString(5, objCustomerBO.getArea() != null ? objCustomerBO.getArea().toUpperCase():""); objPreparedStatement.setString(6, objCustomerBO.getDistrict() != null ? objCustomerBO.getDistrict().toUpperCase():""); objPreparedStatement.setString(7, objCustomerBO.getState() != null ? objCustomerBO.getState().toUpperCase():""); objPreparedStatement.setString(8, objCustomerBO.getCountry() != null ? objCustomerBO.getCountry().toUpperCase():""); objPreparedStatement.setInt(9, objCustomerBO.getPincode() != null ? objCustomerBO.getPincode():0); objPreparedStatement.setString(10, objCustomerBO.getPhoto() != null ? objCustomerBO.getPhoto().toUpperCase():""); objPreparedStatement.setLong(11, objCustomerBO.getPhoneNo() != null ? objCustomerBO.getPhoneNo():0); objPreparedStatement.setLong(12, objCustomerBO.getMobileNo() != null ? objCustomerBO.getMobileNo():0); objPreparedStatement.setString(13, objCustomerBO.getMailID() != null ? objCustomerBO.getMailID().toUpperCase():""); objPreparedStatement.setString(14, objCustomerBO.getRelationShip() != null ? objCustomerBO.getRelationShip().toUpperCase():""); objPreparedStatement.setString(15, objCustomerBO.getRelationName() != null ? objCustomerBO.getRelationName().toUpperCase():""); noOfInsertedRecords = objPreparedStatement.executeUpdate(); // System.out.println(noOfInsertedRecords + " Record inserted"); }finally{ try { objConnection.close(); } catch (SQLException e) { // TODO Auto-generated catch block e.printStackTrace(); } objConnection = null; } } public void updateCustomer(CustomerBO objCustomerBO ){ final String METHOD_NAME = "updateCustomer"; int noOfInsertedRecords =0; Connection objConnection = getConnection(this.jndiName); PreparedStatement objPreparedStatement = null; try{ //objConnection = getConnection(); //System.out.println("Connection is Alive : " + !objConnection.isClosed()); objPreparedStatement = objConnection.prepareStatement(UPDATE_CUSTOMER); objPreparedStatement.setString(1, objCustomerBO.getName() != null ? objCustomerBO.getName().toUpperCase():""); objPreparedStatement.setString(2, objCustomerBO.getAddress() != null ? objCustomerBO.getAddress().toUpperCase():""); objPreparedStatement.setString(3, objCustomerBO.getStreet() != null ? objCustomerBO.getStreet().toUpperCase():""); objPreparedStatement.setString(4, objCustomerBO.getArea() != null ? objCustomerBO.getArea().toUpperCase():""); objPreparedStatement.setString(5, objCustomerBO.getDistrict() != null ? objCustomerBO.getDistrict().toUpperCase():""); objPreparedStatement.setString(6, objCustomerBO.getState() != null ? objCustomerBO.getState().toUpperCase():""); objPreparedStatement.setString(7, objCustomerBO.getCountry() != null ? objCustomerBO.getCountry().toUpperCase():""); objPreparedStatement.setInt(8, objCustomerBO.getPincode() != null ? objCustomerBO.getPincode():0); objPreparedStatement.setString(9, objCustomerBO.getPhoto() != null ? objCustomerBO.getPhoto().toUpperCase():""); objPreparedStatement.setLong(10, objCustomerBO.getPhoneNo() != null ? objCustomerBO.getPhoneNo():0); objPreparedStatement.setLong(11, objCustomerBO.getMobileNo() != null ? objCustomerBO.getMobileNo():0); objPreparedStatement.setString(12, objCustomerBO.getMailID() != null ? objCustomerBO.getMailID().toUpperCase():""); objPreparedStatement.setString(13, objCustomerBO.getRelationShip() != null ? objCustomerBO.getRelationShip().toUpperCase():""); objPreparedStatement.setString(14, objCustomerBO.getRelationName() != null ? objCustomerBO.getRelationName().toUpperCase():""); //System.out.println("Customer ID : "+objCustomerBO.getCustomerID()); objPreparedStatement.setInt(15, objCustomerBO.getCustomerID()); // noOfInsertedRecords = objPreparedStatement.executeUpdate(); noOfInsertedRecords = objPreparedStatement.executeUpdate(); //System.out.println(noOfInsertedRecords + " Record updated"); } catch(SQLException sqlex){ System.out.println("Class Name : " + CLASS_NAME + "Method Name : " + METHOD_NAME + sqlex.getMessage()); }finally{ try { objConnection.close(); } catch (SQLException e) { // TODO Auto-generated catch block e.printStackTrace(); } objPreparedStatement = null; objConnection = null; } } public int deleteCustomer(CustomerBO objCustomerBO ){ final String METHOD_NAME = "deleteCustomer"; int noOfInsertedRecords =0; Connection objConnection = getConnection(this.jndiName); PreparedStatement objPreparedStatement = null; ResultSet resultSet = null; try{ //objConnection = getConnection(); //System.out.println("Connection is Alive : " + !objConnection.isClosed()); objPreparedStatement = objConnection.prepareStatement(DELETE_CUSTOMER); objPreparedStatement.setInt(1, objCustomerBO.getCustomerID()); // objPreparedStatement.setString(2, objCustomerBO.getCustomerDescription().toUpperCase()); //objPreparedStatement.setDouble(3, objCustomerBO.getCustomerRateOfInterest()); //objPreparedStatement.setInt(4, objCustomerBO.getCustomerNo()); noOfInsertedRecords = objPreparedStatement.executeUpdate(); //System.out.println(noOfInsertedRecords + " Record updated"); } catch(SQLException sqlex){ System.out.println("Class Name : " + CLASS_NAME + "Method Name : " + METHOD_NAME + sqlex.getMessage()); }finally{ try { objConnection.close(); } catch (SQLException e) { // TODO Auto-generated catch block e.printStackTrace(); } resultSet = null; objPreparedStatement = null; objConnection = null; } return noOfInsertedRecords; } public CustomerBO executeCustomerID(String customerID ) throws SQLException{ final String METHOD_NAME = "executeCustomerNo"; CustomerBO customerBO=null; Connection objConnection = getConnection(this.jndiName); PreparedStatement objPreparedStatement = null; ResultSet resultSet = null; try{ // objConnection = getConnection(); //System.out.println("Connection is Alive in executeCustomerNo: " + !objConnection.isClosed()); objPreparedStatement = objConnection.prepareStatement(SELECT_CUSTOMER_ID_EQUAL); //System.out.println(" Customer id = " + customerID); //System.out.println(SELECT_CUSTOMER_ID_EQUAL + customerID ); objPreparedStatement.setInt(1, Integer.parseInt(customerID)); ResultSet objCustomerResultSet = objPreparedStatement.executeQuery(); while (objCustomerResultSet.next()){ customerBO = CustomerHelper.getCustomerBOFromResultSet(objCustomerResultSet); } //executeCustomer(); } catch(SQLException sqlex){ System.out.println("Class Name : " + CLASS_NAME + "Method Name : " + METHOD_NAME + sqlex.getMessage()); } catch(Exception ex){ System.out.println("Class Name : " + CLASS_NAME + "Method Name : " + METHOD_NAME + ex.getMessage()); }finally{ try { objConnection.close(); } catch (SQLException e) { // TODO Auto-generated catch block e.printStackTrace(); } resultSet = null; objPreparedStatement = null; objConnection = null; } return customerBO; } public CustomerBO executeCustomerName(String customerName ) throws SQLException{ final String METHOD_NAME = "executeCustomerName"; CustomerBO customerBO=null; Connection objConnection = getConnection(this.jndiName); PreparedStatement objPreparedStatement = null; ResultSet resultSet = null; try{ //objConnection = getConnection(); //System.out.println("Connection is Alive in executeCustomerName: " + !objConnection.isClosed()); objPreparedStatement = objConnection.prepareStatement(SELECT_CUSTOMER_NAME_EQUAL); //System.out.println(" Customer Name = " + customerName); //System.out.println(SELECT_CUSTOMER_NAME_EQUAL + customerName.trim() ); objPreparedStatement.setString(1, customerName); ResultSet objCustomerResultSet = objPreparedStatement.executeQuery(); while (objCustomerResultSet.next()){ customerBO = CustomerHelper.getCustomerBOFromResultSet(objCustomerResultSet); } //executeCustomer(); } catch(SQLException sqlex){ System.out.println("Class Name : " + CLASS_NAME + "Method Name : " + METHOD_NAME + sqlex.getMessage()); } catch(Exception ex){ System.out.println("Class Name : " + CLASS_NAME + "Method Name : " + METHOD_NAME + ex.getMessage()); }finally{ try { objConnection.close(); } catch (SQLException e) { // TODO Auto-generated catch block e.printStackTrace(); } resultSet = null; objPreparedStatement = null; objConnection = null; } return customerBO; } public List<CustomerBO> executeAllCustomers() throws SQLException{ //final String METHOD_NAME = "executeAllCustomers"; List<CustomerBO> customerList=new ArrayList<CustomerBO>(); Connection objConnection = getConnection(this.jndiName); PreparedStatement objPreparedStatement = null; ResultSet resultSet = null; try{ //objConnection= getConnection(); //System.out.println("Connection is Alive in executeCustomer: " + !objConnection.isClosed()); //objPreparedStatement.clearParameters(); objPreparedStatement = objConnection.prepareStatement(SELECT_ALL_CUSTOMER); resultSet = objPreparedStatement.executeQuery(); customerList = CustomerHelper.getCustomerListFromResultSet(resultSet, customerList); }finally{ try { objConnection.close(); } catch (SQLException e) { // TODO Auto-generated catch block e.printStackTrace(); } resultSet = null; objPreparedStatement = null; objConnection = null; } /*} catch(SQLException sqlex){ System.out.println("Class Name : " + CLASS_NAME + "Method Name : " + METHOD_NAME + sqlex.getMessage()); }*/ return customerList; } public List<CustomerBO> executeAllCustomers(int recordsPerPage, String customerID,String customerName) throws SQLException{ //final String METHOD_NAME = "executeAllCustomers"; List<CustomerBO> customerList=new ArrayList<CustomerBO>(); ResultSet customerResultSet=null; Connection objConnection = getConnection(this.jndiName); PreparedStatement objPreparedStatement = null; ResultSet resultSet = null; try{ //objConnection= getConnection(); // System.out.println("Connection is Alive in executeCustomer: " + !objConnection.isClosed()); //objPreparedStatement.clearParameters(); objPreparedStatement = objConnection.prepareStatement(SELECT_CUSTOMER_ID_NAME_LIKE); //System.out.println(SELECT_CUSTOMER_ID_NAME_LIKE + customerID + ","+ customerName); // objPreparedStatement.setString(1, customerID+"%"); // objPreparedStatement.setInt(1, "3"); objPreparedStatement.setString(1, customerName+"%"); customerResultSet = objPreparedStatement.executeQuery(); customerList = CustomerHelper.getCustomerListFromResultSet(customerResultSet, customerList); }finally{ try { objConnection.close(); } catch (SQLException e) { // TODO Auto-generated catch block e.printStackTrace(); } resultSet = null; objPreparedStatement = null; objConnection = null; } /*} catch(SQLException sqlex){ System.out.println("Class Name : " + CLASS_NAME + "Method Name : " + METHOD_NAME + sqlex.getMessage()); }*/ return customerList; } public List<CustomerBO> executeAllCustomers(String customerNameLike) throws SQLException{ //final String METHOD_NAME = "executeAllCustomers"; List<CustomerBO> customerList=new ArrayList<CustomerBO>(); Connection objConnection = getConnection(this.jndiName); PreparedStatement objPreparedStatement = null; ResultSet resultSet = null; try{ //objConnection= getConnection(); // System.out.println("Connection is Alive in executeCustomer: " + !objConnection.isClosed()); //objPreparedStatement.clearParameters(); objPreparedStatement = objConnection.prepareStatement(SELECT_CUSTOMER_NAME_LIKE); //System.out.println(SELECT_CUSTOMER_NAME_LIKE + customerNameLike); // objPreparedStatement.setString(1, customerID+"%"); // objPreparedStatement.setInt(1, "3"); objPreparedStatement.setString(1, customerNameLike+"%"); resultSet = objPreparedStatement.executeQuery(); customerList = CustomerHelper.getCustomerListFromResultSet(resultSet, customerList); }finally{ try { objConnection.close(); } catch (SQLException e) { // TODO Auto-generated catch block e.printStackTrace(); } resultSet = null; objPreparedStatement = null; objConnection = null; } /*} catch(SQLException sqlex){ System.out.println("Class Name : " + CLASS_NAME + "Method Name : " + METHOD_NAME + sqlex.getMessage()); }*/ return customerList; } public List<CustomerBO> executeAllCustomersByCustomerIdIn(String customerIds) throws SQLException{ //final String METHOD_NAME = "executeAllCustomersByCustomerIdIn"; List<CustomerBO> customerList=new ArrayList<CustomerBO>(); Connection objConnection = getConnection(this.jndiName); PreparedStatement objPreparedStatement = null; ResultSet resultSet = null; try{ //objConnection= getConnection(); // System.out.println("Connection is Alive in executeCustomer: " + !objConnection.isClosed()); //objPreparedStatement.clearParameters(); objPreparedStatement = objConnection.prepareStatement(SELECT_CUSTOMER_ID_IN +FilterClausesConstant.LEFT_PARANTHESIS + customerIds + FilterClausesConstant.RIGHT_PARANTHESIS); //System.out.println(SELECT_CUSTOMER_ID_IN + customerIds); // objPreparedStatement.setString(1, customerID+"%"); // objPreparedStatement.setInt(1, "3"); //objPreparedStatement.setString(1, customerIds); resultSet = objPreparedStatement.executeQuery(); customerList = CustomerHelper.getCustomerListFromResultSet(resultSet, customerList); }finally{ try { objConnection.close(); } catch (SQLException e) { // TODO Auto-generated catch block e.printStackTrace(); } resultSet = null; objPreparedStatement = null; objConnection = null; } /*} catch(SQLException sqlex){ System.out.println("Class Name : " + CLASS_NAME + "Method Name : " + METHOD_NAME + sqlex.getMessage()); }*/ return customerList; } public List<CustomerBO> executeAllCustomers(int recordsPerPage, int currentRecord,SearchMasterScreenForm searchMasterScreenForm , String jndiName, String customerID,String customerName,String address, String street,String area,String mobileNumber) throws SQLException,Exception{ //final String METHOD_NAME = "executeAllCustomers"; List<CustomerBO> customerList=new ArrayList<CustomerBO>(); Connection objConnection = getConnection(this.jndiName); PreparedStatement objPreparedStatement = null; ResultSet resultSet = null; try{ ParametersBO parametersBO=null; ParametersDAO parametersDAO = new ParametersDAO(jndiName); parametersBO = parametersDAO.executeParameterIDEqual(BankConstant.RECORDS_PER_PAGE); //objConnection= getConnection(); // System.out.println("BankConstant.RECORDS_PER_PAGE " + parametersBO.getParamValue()); //objPreparedStatement.clearParameters(); objPreparedStatement = objConnection.prepareStatement(SELECT_CUSTOMER_ID_NAME_ADDRESS_STREET_AREA_MOBILE_LIKE ); // + " LIMIT " + parametersBO.getParamValue()); /* System.out.println(SELECT_CUSTOMER_ID_NAME_ADDRESS_STREET_AREA_MOBILE_LIKE + customerID + ","+ customerName + ","+ address + "," + street + ","+ area + ","+ mobileNumber + " LIMIT " + parametersBO.getParamValue());*/ // objPreparedStatement.setString(1, customerID+"%"); // objPreparedStatement.setInt(1, "3"); objPreparedStatement.setString(1, customerID+"%"); objPreparedStatement.setString(2, customerName+"%"); objPreparedStatement.setString(3, address+"%"); objPreparedStatement.setString(4, street+"%"); objPreparedStatement.setString(5, area+"%"); objPreparedStatement.setString(6, mobileNumber+"%"); resultSet = objPreparedStatement.executeQuery(); CustomerHelper customerHelper = new CustomerHelper(); customerList = customerHelper.getSearchCustomerListFromResultSet(recordsPerPage, currentRecord,searchMasterScreenForm,resultSet, customerList); }catch(Exception ex){ ex.printStackTrace(); }finally{ try { objConnection.close(); } catch (SQLException e) { // TODO Auto-generated catch block e.printStackTrace(); } resultSet = null; objPreparedStatement = null; objConnection = null; } /*} catch(SQLException sqlex){ System.out.println("Class Name : " + CLASS_NAME + "Method Name : " + METHOD_NAME + sqlex.getMessage()); }*/ return customerList; } /* * public CustomerBO executeCustomerCode(String customerCode ){ final String METHOD_NAME = "executeCustomerCode"; CustomerBO objCustomerBO = new CustomerBO(); try{ objConnection = new MySQLConnection().getConnection(); System.out.println("Connection is Alive : " + !objConnection.isClosed()); objPreparedStatement = objConnection.prepareStatement(SELECT_CUSTOMER_CODE); System.out.println(" Value for Product Type is : " + customerCode); objPreparedStatement.setString(1, customerCode); ResultSet objCustomerResultSet = objPreparedStatement.executeQuery(); if (objCustomerResultSet == null) System.out.println("No records found" +objCustomerResultSet.getInt(1) ); while (objCustomerResultSet.next()){ objCustomerBO.setCustomerNo(objCustomerResultSet.getInt(1)); objCustomerBO.setCustomerCode(objCustomerResultSet.getString(2)); objCustomerBO.setCustomerDescription(objCustomerResultSet.getString(3)); objCustomerBO.setCustomerRateOfInterest(objCustomerResultSet.getDouble(4)); } } catch(SQLException sqlex){ System.out.println("Class Name : " + CLASS_NAME + "Method Name : " + METHOD_NAME + sqlex.getMessage()); } catch(Exception ex){ System.out.println("Class Name : " + CLASS_NAME + "Method Name : " + METHOD_NAME + ex.getMessage()); } return objCustomerBO; } */ private Integer getMaxCustomerNo(){ final String METHOD_NAME = "getMaxCustomerNo"; PreparedStatement objPreparedStatementQuery; int maxCustomer =0; Connection objConnection = getConnection(this.jndiName); PreparedStatement objPreparedStatement = null; ResultSet resultSet = null; try{ //objConnection = getConnection(); //System.out.println("Connection is Alive : " + !objConnection.isClosed()); objPreparedStatement = objConnection.prepareStatement(SELECT_CUSTOMER_MAX_NO); resultSet = objPreparedStatement.executeQuery(); while (resultSet.next()){ maxCustomer = resultSet.getInt(1); } } catch(SQLException sqlex){ System.out.println("Class Name : " + CLASS_NAME + "Method Name : " + METHOD_NAME + sqlex.getMessage()); } catch(Exception ex){ System.out.println("Class Name : " + CLASS_NAME + "Method Name : " + METHOD_NAME + ex.getMessage()); }finally{ try { objConnection.close(); } catch (SQLException e) { // TODO Auto-generated catch block e.printStackTrace(); } resultSet = null; objPreparedStatement = null; objConnection = null; } // System.out.println("Next Sequence for Customer : " + maxCustomer); return (maxCustomer+1); } public boolean customerExistsByCustomerId(String customerID) throws SQLException{ boolean customerExists = false; try{ CustomerBO customerBO; customerBO = executeCustomerID(customerID); if (customerBO != null){ customerExists = true; } }finally{ } return customerExists; } public boolean customerExistsByCustomerName(String customerName) throws SQLException{ boolean customerExists = false; try{ CustomerBO customerBO; customerBO = executeCustomerName(customerName); if (customerBO != null){ customerExists = true; } }finally{ } return customerExists; } }
UTF-8
Java
25,342
java
CustomerDAO.java
Java
[]
null
[]
package com.bank.dao; import java.sql.Connection; import java.sql.PreparedStatement; import java.sql.ResultSet; import java.sql.SQLException; import java.util.ArrayList; import java.util.List; import com.bank.bo.CustomerBO; import com.bank.bo.ParametersBO; import com.bank.form.SearchMasterScreenForm; import com.bank.helper.CustomerHelper; import com.bank.util.BankConstant; import com.bank.util.FilterClausesConstant; public class CustomerDAO extends BankDAO{ public static final String CLASS_NAME = "CusomterDatabase"; public static final String CREATE_CUSTOMER = "INSERT INTO CUSTOMER (CUSTOMERID, " + "CUSTOMERNAME, ADDRESS, STREET, AREA, DISTRICT, STATE, COUNTRY, PINCODE, PHOTO, " + "PHONENO, MOBILENO, MAILID , RELATIONSHIP, RELATIONNAME) VALUES (?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)"; public static final String UPDATE_CUSTOMER = "UPDATE CUSTOMER SET CUSTOMERNAME = ?, " + " ADDRESS = ?, STREET =? , AREA = ?, DISTRICT =? , STATE = ?, COUNTRY =? , PINCODE = ?, " + "PHOTO =? , PHONENO = ?, MOBILENO =? , MAILID = ?, RELATIONSHIP = ? , RELATIONNAME = ? WHERE CUSTOMERID = ?"; public static final String DELETE_CUSTOMER = "DELETE FROM CUSTOMER WHERE CUSTOMERID = ?"; public static final String SELECT_ALL_CUSTOMER = "SELECT " + "CUSTOMERID, CUSTOMERNAME, ADDRESS, STREET, AREA, DISTRICT, STATE, COUNTRY, PINCODE, PHOTO, " + "PHONENO, MOBILENO, MAILID,RELATIONSHIP, RELATIONNAME FROM CUSTOMER "; public static final String SELECT_CUSTOMER_ID_EQUAL = SELECT_ALL_CUSTOMER + FilterClausesConstant.WHERE + " CUSTOMERID " + FilterClausesConstant.EQUAL + FilterClausesConstant.QUESTIONAIRE ; public static final String SELECT_CUSTOMER_NAME_EQUAL = SELECT_ALL_CUSTOMER + FilterClausesConstant.WHERE + " CUSTOMERNAME " + FilterClausesConstant.EQUAL + FilterClausesConstant.QUESTIONAIRE ; public static final String SELECT_CUSTOMER_ID_IN = SELECT_ALL_CUSTOMER + FilterClausesConstant.WHERE + " CUSTOMERID " + FilterClausesConstant.IN ; public static final String SELECT_CUSTOMER_ID_NAME_LIKE = SELECT_ALL_CUSTOMER + FilterClausesConstant.WHERE + //" CUSTOMERID " + FilterClauses.LIKE + FilterClauses.QUESTIONAIRE + FilterClauses.AND + " CUSTOMERNAME " + FilterClausesConstant.LIKE + FilterClausesConstant.QUESTIONAIRE ; public static final String SELECT_CUSTOMER_NAME_LIKE = SELECT_ALL_CUSTOMER + FilterClausesConstant.WHERE + //" CUSTOMERID " + FilterClauses.LIKE + FilterClauses.QUESTIONAIRE + FilterClauses.AND + " CUSTOMERNAME " + FilterClausesConstant.LIKE + FilterClausesConstant.QUESTIONAIRE ; public static final String SELECT_CUSTOMER_ID_NAME_ADDRESS_STREET_AREA_MOBILE_LIKE = SELECT_ALL_CUSTOMER + FilterClausesConstant.WHERE + " CUSTOMERID " + FilterClausesConstant.LIKE + FilterClausesConstant.QUESTIONAIRE + FilterClausesConstant.AND + " CUSTOMERNAME " + FilterClausesConstant.LIKE + FilterClausesConstant.QUESTIONAIRE + FilterClausesConstant.AND + " ADDRESS " + FilterClausesConstant.LIKE + FilterClausesConstant.QUESTIONAIRE + FilterClausesConstant.AND + " STREET " + FilterClausesConstant.LIKE + FilterClausesConstant.QUESTIONAIRE + FilterClausesConstant.AND + " AREA " + FilterClausesConstant.LIKE + FilterClausesConstant.QUESTIONAIRE + FilterClausesConstant.AND + " MOBILENO " + FilterClausesConstant.LIKE + FilterClausesConstant.QUESTIONAIRE ; /* *public static final String SELECT_CUSTOMER_CODE = "SELECT PRODUCTTYPENO, " + "PRODUCTTYPECODE, PRODUCTTYPEDESCRIPTION, RATEOFINTEREST FROM PRODUCTTYPE WHERE " + "PRODUCTTYPECODE = ?"; */ public static final String SELECT_CUSTOMER_MAX_NO = "SELECT MAX(CUSTOMERID) FROM CUSTOMER"; private String jndiName; public String getJndiName() { return this.jndiName; } public void setJndiName(String jndiName) { this.jndiName = jndiName; } /* * */ public CustomerDAO(String jndiName) { super(); //objConnection = getConnection(jndiName); this.jndiName = jndiName; } public void createCustomer(CustomerBO objCustomerBO ) throws SQLException{ final String METHOD_NAME = "createCustomer"; Connection objConnection = getConnection(this.jndiName); PreparedStatement objPreparedStatement = null; int noOfInsertedRecords =0; int customerSequence =0; try{ //objConnection = getConnection(); //System.out.println("Connection is Alive : " + !objConnection.isClosed()); objPreparedStatement = objConnection.prepareStatement(CREATE_CUSTOMER); customerSequence = getMaxCustomerNo();//System.out.println(" Next Sequence for Customer is : " + customerSequence); objPreparedStatement.setInt(1, new Integer(customerSequence)); objPreparedStatement.setString(2, objCustomerBO.getName() != null ? objCustomerBO.getName().toUpperCase():""); objPreparedStatement.setString(3, objCustomerBO.getAddress() != null ? objCustomerBO.getAddress().toUpperCase():""); objPreparedStatement.setString(4, objCustomerBO.getStreet() != null ? objCustomerBO.getStreet().toUpperCase():""); objPreparedStatement.setString(5, objCustomerBO.getArea() != null ? objCustomerBO.getArea().toUpperCase():""); objPreparedStatement.setString(6, objCustomerBO.getDistrict() != null ? objCustomerBO.getDistrict().toUpperCase():""); objPreparedStatement.setString(7, objCustomerBO.getState() != null ? objCustomerBO.getState().toUpperCase():""); objPreparedStatement.setString(8, objCustomerBO.getCountry() != null ? objCustomerBO.getCountry().toUpperCase():""); objPreparedStatement.setInt(9, objCustomerBO.getPincode() != null ? objCustomerBO.getPincode():0); objPreparedStatement.setString(10, objCustomerBO.getPhoto() != null ? objCustomerBO.getPhoto().toUpperCase():""); objPreparedStatement.setLong(11, objCustomerBO.getPhoneNo() != null ? objCustomerBO.getPhoneNo():0); objPreparedStatement.setLong(12, objCustomerBO.getMobileNo() != null ? objCustomerBO.getMobileNo():0); objPreparedStatement.setString(13, objCustomerBO.getMailID() != null ? objCustomerBO.getMailID().toUpperCase():""); objPreparedStatement.setString(14, objCustomerBO.getRelationShip() != null ? objCustomerBO.getRelationShip().toUpperCase():""); objPreparedStatement.setString(15, objCustomerBO.getRelationName() != null ? objCustomerBO.getRelationName().toUpperCase():""); noOfInsertedRecords = objPreparedStatement.executeUpdate(); // System.out.println(noOfInsertedRecords + " Record inserted"); }finally{ try { objConnection.close(); } catch (SQLException e) { // TODO Auto-generated catch block e.printStackTrace(); } objConnection = null; } } public void updateCustomer(CustomerBO objCustomerBO ){ final String METHOD_NAME = "updateCustomer"; int noOfInsertedRecords =0; Connection objConnection = getConnection(this.jndiName); PreparedStatement objPreparedStatement = null; try{ //objConnection = getConnection(); //System.out.println("Connection is Alive : " + !objConnection.isClosed()); objPreparedStatement = objConnection.prepareStatement(UPDATE_CUSTOMER); objPreparedStatement.setString(1, objCustomerBO.getName() != null ? objCustomerBO.getName().toUpperCase():""); objPreparedStatement.setString(2, objCustomerBO.getAddress() != null ? objCustomerBO.getAddress().toUpperCase():""); objPreparedStatement.setString(3, objCustomerBO.getStreet() != null ? objCustomerBO.getStreet().toUpperCase():""); objPreparedStatement.setString(4, objCustomerBO.getArea() != null ? objCustomerBO.getArea().toUpperCase():""); objPreparedStatement.setString(5, objCustomerBO.getDistrict() != null ? objCustomerBO.getDistrict().toUpperCase():""); objPreparedStatement.setString(6, objCustomerBO.getState() != null ? objCustomerBO.getState().toUpperCase():""); objPreparedStatement.setString(7, objCustomerBO.getCountry() != null ? objCustomerBO.getCountry().toUpperCase():""); objPreparedStatement.setInt(8, objCustomerBO.getPincode() != null ? objCustomerBO.getPincode():0); objPreparedStatement.setString(9, objCustomerBO.getPhoto() != null ? objCustomerBO.getPhoto().toUpperCase():""); objPreparedStatement.setLong(10, objCustomerBO.getPhoneNo() != null ? objCustomerBO.getPhoneNo():0); objPreparedStatement.setLong(11, objCustomerBO.getMobileNo() != null ? objCustomerBO.getMobileNo():0); objPreparedStatement.setString(12, objCustomerBO.getMailID() != null ? objCustomerBO.getMailID().toUpperCase():""); objPreparedStatement.setString(13, objCustomerBO.getRelationShip() != null ? objCustomerBO.getRelationShip().toUpperCase():""); objPreparedStatement.setString(14, objCustomerBO.getRelationName() != null ? objCustomerBO.getRelationName().toUpperCase():""); //System.out.println("Customer ID : "+objCustomerBO.getCustomerID()); objPreparedStatement.setInt(15, objCustomerBO.getCustomerID()); // noOfInsertedRecords = objPreparedStatement.executeUpdate(); noOfInsertedRecords = objPreparedStatement.executeUpdate(); //System.out.println(noOfInsertedRecords + " Record updated"); } catch(SQLException sqlex){ System.out.println("Class Name : " + CLASS_NAME + "Method Name : " + METHOD_NAME + sqlex.getMessage()); }finally{ try { objConnection.close(); } catch (SQLException e) { // TODO Auto-generated catch block e.printStackTrace(); } objPreparedStatement = null; objConnection = null; } } public int deleteCustomer(CustomerBO objCustomerBO ){ final String METHOD_NAME = "deleteCustomer"; int noOfInsertedRecords =0; Connection objConnection = getConnection(this.jndiName); PreparedStatement objPreparedStatement = null; ResultSet resultSet = null; try{ //objConnection = getConnection(); //System.out.println("Connection is Alive : " + !objConnection.isClosed()); objPreparedStatement = objConnection.prepareStatement(DELETE_CUSTOMER); objPreparedStatement.setInt(1, objCustomerBO.getCustomerID()); // objPreparedStatement.setString(2, objCustomerBO.getCustomerDescription().toUpperCase()); //objPreparedStatement.setDouble(3, objCustomerBO.getCustomerRateOfInterest()); //objPreparedStatement.setInt(4, objCustomerBO.getCustomerNo()); noOfInsertedRecords = objPreparedStatement.executeUpdate(); //System.out.println(noOfInsertedRecords + " Record updated"); } catch(SQLException sqlex){ System.out.println("Class Name : " + CLASS_NAME + "Method Name : " + METHOD_NAME + sqlex.getMessage()); }finally{ try { objConnection.close(); } catch (SQLException e) { // TODO Auto-generated catch block e.printStackTrace(); } resultSet = null; objPreparedStatement = null; objConnection = null; } return noOfInsertedRecords; } public CustomerBO executeCustomerID(String customerID ) throws SQLException{ final String METHOD_NAME = "executeCustomerNo"; CustomerBO customerBO=null; Connection objConnection = getConnection(this.jndiName); PreparedStatement objPreparedStatement = null; ResultSet resultSet = null; try{ // objConnection = getConnection(); //System.out.println("Connection is Alive in executeCustomerNo: " + !objConnection.isClosed()); objPreparedStatement = objConnection.prepareStatement(SELECT_CUSTOMER_ID_EQUAL); //System.out.println(" Customer id = " + customerID); //System.out.println(SELECT_CUSTOMER_ID_EQUAL + customerID ); objPreparedStatement.setInt(1, Integer.parseInt(customerID)); ResultSet objCustomerResultSet = objPreparedStatement.executeQuery(); while (objCustomerResultSet.next()){ customerBO = CustomerHelper.getCustomerBOFromResultSet(objCustomerResultSet); } //executeCustomer(); } catch(SQLException sqlex){ System.out.println("Class Name : " + CLASS_NAME + "Method Name : " + METHOD_NAME + sqlex.getMessage()); } catch(Exception ex){ System.out.println("Class Name : " + CLASS_NAME + "Method Name : " + METHOD_NAME + ex.getMessage()); }finally{ try { objConnection.close(); } catch (SQLException e) { // TODO Auto-generated catch block e.printStackTrace(); } resultSet = null; objPreparedStatement = null; objConnection = null; } return customerBO; } public CustomerBO executeCustomerName(String customerName ) throws SQLException{ final String METHOD_NAME = "executeCustomerName"; CustomerBO customerBO=null; Connection objConnection = getConnection(this.jndiName); PreparedStatement objPreparedStatement = null; ResultSet resultSet = null; try{ //objConnection = getConnection(); //System.out.println("Connection is Alive in executeCustomerName: " + !objConnection.isClosed()); objPreparedStatement = objConnection.prepareStatement(SELECT_CUSTOMER_NAME_EQUAL); //System.out.println(" Customer Name = " + customerName); //System.out.println(SELECT_CUSTOMER_NAME_EQUAL + customerName.trim() ); objPreparedStatement.setString(1, customerName); ResultSet objCustomerResultSet = objPreparedStatement.executeQuery(); while (objCustomerResultSet.next()){ customerBO = CustomerHelper.getCustomerBOFromResultSet(objCustomerResultSet); } //executeCustomer(); } catch(SQLException sqlex){ System.out.println("Class Name : " + CLASS_NAME + "Method Name : " + METHOD_NAME + sqlex.getMessage()); } catch(Exception ex){ System.out.println("Class Name : " + CLASS_NAME + "Method Name : " + METHOD_NAME + ex.getMessage()); }finally{ try { objConnection.close(); } catch (SQLException e) { // TODO Auto-generated catch block e.printStackTrace(); } resultSet = null; objPreparedStatement = null; objConnection = null; } return customerBO; } public List<CustomerBO> executeAllCustomers() throws SQLException{ //final String METHOD_NAME = "executeAllCustomers"; List<CustomerBO> customerList=new ArrayList<CustomerBO>(); Connection objConnection = getConnection(this.jndiName); PreparedStatement objPreparedStatement = null; ResultSet resultSet = null; try{ //objConnection= getConnection(); //System.out.println("Connection is Alive in executeCustomer: " + !objConnection.isClosed()); //objPreparedStatement.clearParameters(); objPreparedStatement = objConnection.prepareStatement(SELECT_ALL_CUSTOMER); resultSet = objPreparedStatement.executeQuery(); customerList = CustomerHelper.getCustomerListFromResultSet(resultSet, customerList); }finally{ try { objConnection.close(); } catch (SQLException e) { // TODO Auto-generated catch block e.printStackTrace(); } resultSet = null; objPreparedStatement = null; objConnection = null; } /*} catch(SQLException sqlex){ System.out.println("Class Name : " + CLASS_NAME + "Method Name : " + METHOD_NAME + sqlex.getMessage()); }*/ return customerList; } public List<CustomerBO> executeAllCustomers(int recordsPerPage, String customerID,String customerName) throws SQLException{ //final String METHOD_NAME = "executeAllCustomers"; List<CustomerBO> customerList=new ArrayList<CustomerBO>(); ResultSet customerResultSet=null; Connection objConnection = getConnection(this.jndiName); PreparedStatement objPreparedStatement = null; ResultSet resultSet = null; try{ //objConnection= getConnection(); // System.out.println("Connection is Alive in executeCustomer: " + !objConnection.isClosed()); //objPreparedStatement.clearParameters(); objPreparedStatement = objConnection.prepareStatement(SELECT_CUSTOMER_ID_NAME_LIKE); //System.out.println(SELECT_CUSTOMER_ID_NAME_LIKE + customerID + ","+ customerName); // objPreparedStatement.setString(1, customerID+"%"); // objPreparedStatement.setInt(1, "3"); objPreparedStatement.setString(1, customerName+"%"); customerResultSet = objPreparedStatement.executeQuery(); customerList = CustomerHelper.getCustomerListFromResultSet(customerResultSet, customerList); }finally{ try { objConnection.close(); } catch (SQLException e) { // TODO Auto-generated catch block e.printStackTrace(); } resultSet = null; objPreparedStatement = null; objConnection = null; } /*} catch(SQLException sqlex){ System.out.println("Class Name : " + CLASS_NAME + "Method Name : " + METHOD_NAME + sqlex.getMessage()); }*/ return customerList; } public List<CustomerBO> executeAllCustomers(String customerNameLike) throws SQLException{ //final String METHOD_NAME = "executeAllCustomers"; List<CustomerBO> customerList=new ArrayList<CustomerBO>(); Connection objConnection = getConnection(this.jndiName); PreparedStatement objPreparedStatement = null; ResultSet resultSet = null; try{ //objConnection= getConnection(); // System.out.println("Connection is Alive in executeCustomer: " + !objConnection.isClosed()); //objPreparedStatement.clearParameters(); objPreparedStatement = objConnection.prepareStatement(SELECT_CUSTOMER_NAME_LIKE); //System.out.println(SELECT_CUSTOMER_NAME_LIKE + customerNameLike); // objPreparedStatement.setString(1, customerID+"%"); // objPreparedStatement.setInt(1, "3"); objPreparedStatement.setString(1, customerNameLike+"%"); resultSet = objPreparedStatement.executeQuery(); customerList = CustomerHelper.getCustomerListFromResultSet(resultSet, customerList); }finally{ try { objConnection.close(); } catch (SQLException e) { // TODO Auto-generated catch block e.printStackTrace(); } resultSet = null; objPreparedStatement = null; objConnection = null; } /*} catch(SQLException sqlex){ System.out.println("Class Name : " + CLASS_NAME + "Method Name : " + METHOD_NAME + sqlex.getMessage()); }*/ return customerList; } public List<CustomerBO> executeAllCustomersByCustomerIdIn(String customerIds) throws SQLException{ //final String METHOD_NAME = "executeAllCustomersByCustomerIdIn"; List<CustomerBO> customerList=new ArrayList<CustomerBO>(); Connection objConnection = getConnection(this.jndiName); PreparedStatement objPreparedStatement = null; ResultSet resultSet = null; try{ //objConnection= getConnection(); // System.out.println("Connection is Alive in executeCustomer: " + !objConnection.isClosed()); //objPreparedStatement.clearParameters(); objPreparedStatement = objConnection.prepareStatement(SELECT_CUSTOMER_ID_IN +FilterClausesConstant.LEFT_PARANTHESIS + customerIds + FilterClausesConstant.RIGHT_PARANTHESIS); //System.out.println(SELECT_CUSTOMER_ID_IN + customerIds); // objPreparedStatement.setString(1, customerID+"%"); // objPreparedStatement.setInt(1, "3"); //objPreparedStatement.setString(1, customerIds); resultSet = objPreparedStatement.executeQuery(); customerList = CustomerHelper.getCustomerListFromResultSet(resultSet, customerList); }finally{ try { objConnection.close(); } catch (SQLException e) { // TODO Auto-generated catch block e.printStackTrace(); } resultSet = null; objPreparedStatement = null; objConnection = null; } /*} catch(SQLException sqlex){ System.out.println("Class Name : " + CLASS_NAME + "Method Name : " + METHOD_NAME + sqlex.getMessage()); }*/ return customerList; } public List<CustomerBO> executeAllCustomers(int recordsPerPage, int currentRecord,SearchMasterScreenForm searchMasterScreenForm , String jndiName, String customerID,String customerName,String address, String street,String area,String mobileNumber) throws SQLException,Exception{ //final String METHOD_NAME = "executeAllCustomers"; List<CustomerBO> customerList=new ArrayList<CustomerBO>(); Connection objConnection = getConnection(this.jndiName); PreparedStatement objPreparedStatement = null; ResultSet resultSet = null; try{ ParametersBO parametersBO=null; ParametersDAO parametersDAO = new ParametersDAO(jndiName); parametersBO = parametersDAO.executeParameterIDEqual(BankConstant.RECORDS_PER_PAGE); //objConnection= getConnection(); // System.out.println("BankConstant.RECORDS_PER_PAGE " + parametersBO.getParamValue()); //objPreparedStatement.clearParameters(); objPreparedStatement = objConnection.prepareStatement(SELECT_CUSTOMER_ID_NAME_ADDRESS_STREET_AREA_MOBILE_LIKE ); // + " LIMIT " + parametersBO.getParamValue()); /* System.out.println(SELECT_CUSTOMER_ID_NAME_ADDRESS_STREET_AREA_MOBILE_LIKE + customerID + ","+ customerName + ","+ address + "," + street + ","+ area + ","+ mobileNumber + " LIMIT " + parametersBO.getParamValue());*/ // objPreparedStatement.setString(1, customerID+"%"); // objPreparedStatement.setInt(1, "3"); objPreparedStatement.setString(1, customerID+"%"); objPreparedStatement.setString(2, customerName+"%"); objPreparedStatement.setString(3, address+"%"); objPreparedStatement.setString(4, street+"%"); objPreparedStatement.setString(5, area+"%"); objPreparedStatement.setString(6, mobileNumber+"%"); resultSet = objPreparedStatement.executeQuery(); CustomerHelper customerHelper = new CustomerHelper(); customerList = customerHelper.getSearchCustomerListFromResultSet(recordsPerPage, currentRecord,searchMasterScreenForm,resultSet, customerList); }catch(Exception ex){ ex.printStackTrace(); }finally{ try { objConnection.close(); } catch (SQLException e) { // TODO Auto-generated catch block e.printStackTrace(); } resultSet = null; objPreparedStatement = null; objConnection = null; } /*} catch(SQLException sqlex){ System.out.println("Class Name : " + CLASS_NAME + "Method Name : " + METHOD_NAME + sqlex.getMessage()); }*/ return customerList; } /* * public CustomerBO executeCustomerCode(String customerCode ){ final String METHOD_NAME = "executeCustomerCode"; CustomerBO objCustomerBO = new CustomerBO(); try{ objConnection = new MySQLConnection().getConnection(); System.out.println("Connection is Alive : " + !objConnection.isClosed()); objPreparedStatement = objConnection.prepareStatement(SELECT_CUSTOMER_CODE); System.out.println(" Value for Product Type is : " + customerCode); objPreparedStatement.setString(1, customerCode); ResultSet objCustomerResultSet = objPreparedStatement.executeQuery(); if (objCustomerResultSet == null) System.out.println("No records found" +objCustomerResultSet.getInt(1) ); while (objCustomerResultSet.next()){ objCustomerBO.setCustomerNo(objCustomerResultSet.getInt(1)); objCustomerBO.setCustomerCode(objCustomerResultSet.getString(2)); objCustomerBO.setCustomerDescription(objCustomerResultSet.getString(3)); objCustomerBO.setCustomerRateOfInterest(objCustomerResultSet.getDouble(4)); } } catch(SQLException sqlex){ System.out.println("Class Name : " + CLASS_NAME + "Method Name : " + METHOD_NAME + sqlex.getMessage()); } catch(Exception ex){ System.out.println("Class Name : " + CLASS_NAME + "Method Name : " + METHOD_NAME + ex.getMessage()); } return objCustomerBO; } */ private Integer getMaxCustomerNo(){ final String METHOD_NAME = "getMaxCustomerNo"; PreparedStatement objPreparedStatementQuery; int maxCustomer =0; Connection objConnection = getConnection(this.jndiName); PreparedStatement objPreparedStatement = null; ResultSet resultSet = null; try{ //objConnection = getConnection(); //System.out.println("Connection is Alive : " + !objConnection.isClosed()); objPreparedStatement = objConnection.prepareStatement(SELECT_CUSTOMER_MAX_NO); resultSet = objPreparedStatement.executeQuery(); while (resultSet.next()){ maxCustomer = resultSet.getInt(1); } } catch(SQLException sqlex){ System.out.println("Class Name : " + CLASS_NAME + "Method Name : " + METHOD_NAME + sqlex.getMessage()); } catch(Exception ex){ System.out.println("Class Name : " + CLASS_NAME + "Method Name : " + METHOD_NAME + ex.getMessage()); }finally{ try { objConnection.close(); } catch (SQLException e) { // TODO Auto-generated catch block e.printStackTrace(); } resultSet = null; objPreparedStatement = null; objConnection = null; } // System.out.println("Next Sequence for Customer : " + maxCustomer); return (maxCustomer+1); } public boolean customerExistsByCustomerId(String customerID) throws SQLException{ boolean customerExists = false; try{ CustomerBO customerBO; customerBO = executeCustomerID(customerID); if (customerBO != null){ customerExists = true; } }finally{ } return customerExists; } public boolean customerExistsByCustomerName(String customerName) throws SQLException{ boolean customerExists = false; try{ CustomerBO customerBO; customerBO = executeCustomerName(customerName); if (customerBO != null){ customerExists = true; } }finally{ } return customerExists; } }
25,342
0.719872
0.7164
619
39.940228
34.767883
139
false
false
0
0
0
0
0
0
3.481422
false
false
13
ab28e43b11c70dbf6d49901b4f3cfd5a7b109675
8,014,409,038,839
13870d43419e997d9c3f8b363c3a03f8564a3c3c
/src/test/java/be/pengo/demoDependencyInjection/DemoDependencyInjectionApplicationTests.java
c5dfc375eaf1af792652ac9b160c67fe93a2edd2
[]
no_license
apietsch/demoDependencyInjection
https://github.com/apietsch/demoDependencyInjection
c3537cb6cea24c1a1edd2bc7a2985cd13629acba
4eef0084c3b4dd868feccc4c7ed84baac2c563d2
refs/heads/master
2020-12-31T08:27:14.800000
2020-02-07T16:01:20
2020-02-07T16:01:20
238,952,202
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
package be.pengo.demoDependencyInjection; import static org.junit.jupiter.api.Assertions.assertFalse; import static org.junit.jupiter.api.Assertions.assertTrue; import static org.mockito.Mockito.when; import org.junit.jupiter.api.Test; import org.mockito.ArgumentMatchers; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.boot.test.context.SpringBootTest; import org.springframework.boot.test.mock.mockito.MockBean; import org.springframework.context.ApplicationContext; @SpringBootTest class DemoDependencyInjectionApplicationTests { @Autowired ApplicationContext context; @MockBean MessageService messageService; @Test void contextLoads() { when(this.messageService.sendMessage(ArgumentMatchers.anyString(), ArgumentMatchers.anyString())).thenReturn(false); when(this.messageService.sendMessage("hello", "rec")).thenReturn(true); when(this.messageService.sendMessage("hello1", "rec")).thenReturn(true); MyMessageApplication bean = context.getBean(MyMessageApplication.class); boolean processMessage = bean.processMessage("hello", "rec"); assertTrue(processMessage); boolean processMessage2 = bean.processMessage("hello4", "rec"); assertFalse(processMessage2); boolean processMessage3 = bean.processMessage("hello1", "rec"); assertTrue(processMessage3); } }
UTF-8
Java
1,337
java
DemoDependencyInjectionApplicationTests.java
Java
[]
null
[]
package be.pengo.demoDependencyInjection; import static org.junit.jupiter.api.Assertions.assertFalse; import static org.junit.jupiter.api.Assertions.assertTrue; import static org.mockito.Mockito.when; import org.junit.jupiter.api.Test; import org.mockito.ArgumentMatchers; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.boot.test.context.SpringBootTest; import org.springframework.boot.test.mock.mockito.MockBean; import org.springframework.context.ApplicationContext; @SpringBootTest class DemoDependencyInjectionApplicationTests { @Autowired ApplicationContext context; @MockBean MessageService messageService; @Test void contextLoads() { when(this.messageService.sendMessage(ArgumentMatchers.anyString(), ArgumentMatchers.anyString())).thenReturn(false); when(this.messageService.sendMessage("hello", "rec")).thenReturn(true); when(this.messageService.sendMessage("hello1", "rec")).thenReturn(true); MyMessageApplication bean = context.getBean(MyMessageApplication.class); boolean processMessage = bean.processMessage("hello", "rec"); assertTrue(processMessage); boolean processMessage2 = bean.processMessage("hello4", "rec"); assertFalse(processMessage2); boolean processMessage3 = bean.processMessage("hello1", "rec"); assertTrue(processMessage3); } }
1,337
0.807031
0.801795
39
33.282051
29.260939
118
false
false
0
0
0
0
0
0
1.435897
false
false
13
84dffa0378671ecf78cdc65a138f34f34bc2aa82
16,956,530,911,471
cc6f9dc69eed98ec63c1786582ad28f292bdb0f8
/src/com/ssynhtn/easy/ReverseLinkedList.java
d1b9d20c063f42a00b33ad6eb2d0c3fd861a0e1e
[ "Apache-2.0" ]
permissive
ssynhtn/leetcode
https://github.com/ssynhtn/leetcode
6512e1251e5929ed4a68751a085ad6d0cae9e157
511f65845097782127bae825b07a51fe9921c561
refs/heads/master
2023-02-15T04:08:40.586000
2021-01-08T05:56:33
2021-01-08T05:56:33
295,075,844
0
0
null
null
null
null
null
null
null
null
null
null
null
null
null
package com.ssynhtn.easy; import com.ssynhtn.common.ListNode; import java.util.ArrayDeque; import java.util.Arrays; public class ReverseLinkedList { public ListNode reverseListRec(ListNode head) { if (head == null || head.next == null) return head; ListNode next = head.next; ListNode reverseNext = reverseListRec(next); next.next = head; head.next = null; return reverseNext; } public ListNode reverseListStack(ListNode head) { ArrayDeque<ListNode> stack = new ArrayDeque<>(); while (head != null) { stack.push(head); head = head.next; } if (stack.isEmpty()) return null; ListNode res = stack.poll(); ListNode node = res; while (!stack.isEmpty()) { node.next = stack.poll(); node = node.next; } node.next = null; return res; } public ListNode reverseList(ListNode head) { ListNode prev = null; ListNode curr = head; while (curr != null) { ListNode next = curr.next; curr.next = prev; prev = curr; curr = next; } return prev; } public ListNode reverseBetween(ListNode head, int m, int n) { if (head == null || head.next == null) return head; if (m == n) return head; int len = n - m + 1; m--; ListNode prev = null; ListNode curr = head; while (m > 0) { prev = curr; curr = curr.next; m--; } ListNode tail = curr; ListNode reversed = null; while (len > 0) { ListNode next = curr.next; curr.next = reversed; reversed = curr; curr = next; len--; } tail.next = curr; if (prev == null) { return reversed; } else { prev.next = reversed; return head; } } public ListNode reverseBetweenRec(ListNode head, int m, int n) { if (m == n) return head; if (m == 1) { return reverseHead(head, n - m + 1); } head.next = reverseBetween(head.next, m -1, n-1); return head; } private ListNode reverseHead(ListNode head, int n) { if (n <= 1) return head; ListNode next = head.next; ListNode newHead = reverseHead(next, n-1); head.next = next.next; next.next = head; return newHead; } public static void main(String[] args) { System.out.println(new ReverseLinkedList().reverseBetweenRec(ListNode.makeList(Arrays.asList(1, 2, 3, 4, 5)), 2, 4)); } }
UTF-8
Java
2,735
java
ReverseLinkedList.java
Java
[]
null
[]
package com.ssynhtn.easy; import com.ssynhtn.common.ListNode; import java.util.ArrayDeque; import java.util.Arrays; public class ReverseLinkedList { public ListNode reverseListRec(ListNode head) { if (head == null || head.next == null) return head; ListNode next = head.next; ListNode reverseNext = reverseListRec(next); next.next = head; head.next = null; return reverseNext; } public ListNode reverseListStack(ListNode head) { ArrayDeque<ListNode> stack = new ArrayDeque<>(); while (head != null) { stack.push(head); head = head.next; } if (stack.isEmpty()) return null; ListNode res = stack.poll(); ListNode node = res; while (!stack.isEmpty()) { node.next = stack.poll(); node = node.next; } node.next = null; return res; } public ListNode reverseList(ListNode head) { ListNode prev = null; ListNode curr = head; while (curr != null) { ListNode next = curr.next; curr.next = prev; prev = curr; curr = next; } return prev; } public ListNode reverseBetween(ListNode head, int m, int n) { if (head == null || head.next == null) return head; if (m == n) return head; int len = n - m + 1; m--; ListNode prev = null; ListNode curr = head; while (m > 0) { prev = curr; curr = curr.next; m--; } ListNode tail = curr; ListNode reversed = null; while (len > 0) { ListNode next = curr.next; curr.next = reversed; reversed = curr; curr = next; len--; } tail.next = curr; if (prev == null) { return reversed; } else { prev.next = reversed; return head; } } public ListNode reverseBetweenRec(ListNode head, int m, int n) { if (m == n) return head; if (m == 1) { return reverseHead(head, n - m + 1); } head.next = reverseBetween(head.next, m -1, n-1); return head; } private ListNode reverseHead(ListNode head, int n) { if (n <= 1) return head; ListNode next = head.next; ListNode newHead = reverseHead(next, n-1); head.next = next.next; next.next = head; return newHead; } public static void main(String[] args) { System.out.println(new ReverseLinkedList().reverseBetweenRec(ListNode.makeList(Arrays.asList(1, 2, 3, 4, 5)), 2, 4)); } }
2,735
0.516636
0.510786
110
23.863636
19.878027
125
false
false
0
0
0
0
0
0
0.7
false
false
13
a18cdce443e2a4159d7c7141bf2fffbc48ed49ae
14,894,946,638,332
f5114bdafba7fd7a2e8082076abedd671e086d6c
/VMConsole-API-OpenJDK-Linux/src/main/java/com/sun/tools/jdi/ProcessAttachingConnector.java
35d209a690fb053dfa0bf790ec5f91477f21e3f3
[ "Apache-2.0" ]
permissive
tzfun/VmConsole-Api
https://github.com/tzfun/VmConsole-Api
c1f8dd688a9c90acbb891d5e4dae7def5f5324b7
20920d8310d417e8ca2af2cdbcaa4084d789d900
refs/heads/master
2023-04-13T09:47:48.693000
2023-04-07T14:04:07
2023-04-07T14:04:07
188,955,946
45
15
Apache-2.0
false
2023-04-07T14:04:08
2019-05-28T04:50:22
2022-09-23T02:45:11
2023-04-07T14:04:07
2,140
42
16
2
Java
false
false
/* * Copyright (c) 2005, 2011, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License version 2 only, as * published by the Free Software Foundation. Oracle designates this * particular file as subject to the "Classpath" exception as provided * by Oracle in the LICENSE file that accompanied this code. * * This code is distributed in the hope that it will be useful, but WITHOUT * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License * version 2 for more details (a copy is included in the LICENSE file that * accompanied this code). * * You should have received a copy of the GNU General Public License version * 2 along with this work; if not, write to the Free Software Foundation, * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. * * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA * or visit www.oracle.com if you need additional information or have any * questions. */ package com.sun.tools.jdi; import java.io.IOException; import java.io.UnsupportedEncodingException; import java.util.Map; import java.util.Properties; import com.sun.jdi.Bootstrap; import com.sun.jdi.VirtualMachine; import com.sun.jdi.connect.*; import com.sun.jdi.connect.spi.*; /* * An AttachingConnector that connects to a debuggee by specifying the process * id (pid) as the connector argument. If the process is a debuggee listening * on a transport address then this connector reads the transport address * and attempts to attach to it using the appropriate transport. */ public class ProcessAttachingConnector extends ConnectorImpl implements AttachingConnector { /* * The arguments that this connector supports */ static final String ARG_PID = "pid"; static final String ARG_TIMEOUT = "timeout"; com.sun.tools.attach.VirtualMachine vm; Transport transport; public ProcessAttachingConnector() { addStringArgument( ARG_PID, getString("process_attaching.pid.label"), getString("process_attaching.pid"), "", true); addIntegerArgument( ARG_TIMEOUT, getString("generic_attaching.timeout.label"), // use generic keys to keep getString("generic_attaching.timeout"), // resource bundle small "", false, 0, Integer.MAX_VALUE); transport = new Transport() { public String name() { return "local"; } }; } /** * Attach to a target VM using the specified address and Connector arguments. */ public VirtualMachine attach(Map<String,? extends Connector.Argument> args) throws IOException, IllegalConnectorArgumentsException { String pid = argument(ARG_PID, args).value(); String t = argument(ARG_TIMEOUT, args).value(); int timeout = 0; if (t.length() > 0) { timeout = Integer.decode(t).intValue(); } // Use Attach API to attach to target VM and read value of // sun.jdwp.listenAddress property. String address = null; com.sun.tools.attach.VirtualMachine vm = null; try { vm = com.sun.tools.attach.VirtualMachine.attach(pid); Properties props = vm.getAgentProperties(); address = props.getProperty("sun.jdwp.listenerAddress"); } catch (Exception x) { throw new IOException(x.getMessage()); } finally { if (vm != null) vm.detach(); } // check that the property value is formatted correctly if (address == null) { throw new IOException("Not a debuggee, or not listening for debugger to attach"); } int pos = address.indexOf(':'); if (pos < 1) { throw new IOException("Unable to determine transport endpoint"); } // parse into transport library name and address final String lib = address.substring(0, pos); address = address.substring(pos+1, address.length()); TransportService ts = null; if (lib.equals("dt_socket")) { ts = new SocketTransportService(); } else { if (lib.equals("dt_shmem")) { try { Class<?> c = Class.forName("com.sun.tools.jdi.SharedMemoryTransportService"); ts = (TransportService)c.newInstance(); } catch (Exception x) { } } } if (ts == null) { throw new IOException("Transport " + lib + " not recognized"); } // connect to the debuggee Connection connection = ts.attach(address, timeout, 0); return Bootstrap.virtualMachineManager().createVirtualMachine(connection); } public String name() { return "com.sun.jdi.ProcessAttach"; } public String description() { return getString("process_attaching.description"); } public Transport transport() { if (transport == null) { return new Transport() { public String name() { return "local"; } }; } return transport; } }
UTF-8
Java
5,530
java
ProcessAttachingConnector.java
Java
[]
null
[]
/* * Copyright (c) 2005, 2011, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License version 2 only, as * published by the Free Software Foundation. Oracle designates this * particular file as subject to the "Classpath" exception as provided * by Oracle in the LICENSE file that accompanied this code. * * This code is distributed in the hope that it will be useful, but WITHOUT * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License * version 2 for more details (a copy is included in the LICENSE file that * accompanied this code). * * You should have received a copy of the GNU General Public License version * 2 along with this work; if not, write to the Free Software Foundation, * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. * * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA * or visit www.oracle.com if you need additional information or have any * questions. */ package com.sun.tools.jdi; import java.io.IOException; import java.io.UnsupportedEncodingException; import java.util.Map; import java.util.Properties; import com.sun.jdi.Bootstrap; import com.sun.jdi.VirtualMachine; import com.sun.jdi.connect.*; import com.sun.jdi.connect.spi.*; /* * An AttachingConnector that connects to a debuggee by specifying the process * id (pid) as the connector argument. If the process is a debuggee listening * on a transport address then this connector reads the transport address * and attempts to attach to it using the appropriate transport. */ public class ProcessAttachingConnector extends ConnectorImpl implements AttachingConnector { /* * The arguments that this connector supports */ static final String ARG_PID = "pid"; static final String ARG_TIMEOUT = "timeout"; com.sun.tools.attach.VirtualMachine vm; Transport transport; public ProcessAttachingConnector() { addStringArgument( ARG_PID, getString("process_attaching.pid.label"), getString("process_attaching.pid"), "", true); addIntegerArgument( ARG_TIMEOUT, getString("generic_attaching.timeout.label"), // use generic keys to keep getString("generic_attaching.timeout"), // resource bundle small "", false, 0, Integer.MAX_VALUE); transport = new Transport() { public String name() { return "local"; } }; } /** * Attach to a target VM using the specified address and Connector arguments. */ public VirtualMachine attach(Map<String,? extends Connector.Argument> args) throws IOException, IllegalConnectorArgumentsException { String pid = argument(ARG_PID, args).value(); String t = argument(ARG_TIMEOUT, args).value(); int timeout = 0; if (t.length() > 0) { timeout = Integer.decode(t).intValue(); } // Use Attach API to attach to target VM and read value of // sun.jdwp.listenAddress property. String address = null; com.sun.tools.attach.VirtualMachine vm = null; try { vm = com.sun.tools.attach.VirtualMachine.attach(pid); Properties props = vm.getAgentProperties(); address = props.getProperty("sun.jdwp.listenerAddress"); } catch (Exception x) { throw new IOException(x.getMessage()); } finally { if (vm != null) vm.detach(); } // check that the property value is formatted correctly if (address == null) { throw new IOException("Not a debuggee, or not listening for debugger to attach"); } int pos = address.indexOf(':'); if (pos < 1) { throw new IOException("Unable to determine transport endpoint"); } // parse into transport library name and address final String lib = address.substring(0, pos); address = address.substring(pos+1, address.length()); TransportService ts = null; if (lib.equals("dt_socket")) { ts = new SocketTransportService(); } else { if (lib.equals("dt_shmem")) { try { Class<?> c = Class.forName("com.sun.tools.jdi.SharedMemoryTransportService"); ts = (TransportService)c.newInstance(); } catch (Exception x) { } } } if (ts == null) { throw new IOException("Transport " + lib + " not recognized"); } // connect to the debuggee Connection connection = ts.attach(address, timeout, 0); return Bootstrap.virtualMachineManager().createVirtualMachine(connection); } public String name() { return "com.sun.jdi.ProcessAttach"; } public String description() { return getString("process_attaching.description"); } public Transport transport() { if (transport == null) { return new Transport() { public String name() { return "local"; } }; } return transport; } }
5,530
0.622423
0.615732
164
32.719513
27.283638
97
false
false
0
0
0
0
0
0
0.487805
false
false
13