blob_id
stringlengths 40
40
| directory_id
stringlengths 40
40
| path
stringlengths 7
390
| content_id
stringlengths 40
40
| detected_licenses
listlengths 0
35
| license_type
stringclasses 2
values | repo_name
stringlengths 6
132
| snapshot_id
stringlengths 40
40
| revision_id
stringlengths 40
40
| branch_name
stringclasses 539
values | visit_date
timestamp[us]date 2016-08-02 21:09:20
2023-09-06 10:10:07
| revision_date
timestamp[us]date 1990-01-30 01:55:47
2023-09-05 21:45:37
| committer_date
timestamp[us]date 2003-07-12 18:48:29
2023-09-05 21:45:37
| github_id
int64 7.28k
684M
⌀ | star_events_count
int64 0
77.7k
| fork_events_count
int64 0
48k
| gha_license_id
stringclasses 13
values | gha_event_created_at
timestamp[us]date 2012-06-11 04:05:37
2023-09-14 21:59:18
⌀ | gha_created_at
timestamp[us]date 2008-05-22 07:58:19
2023-08-28 02:39:21
⌀ | gha_language
stringclasses 62
values | src_encoding
stringclasses 26
values | language
stringclasses 1
value | is_vendor
bool 1
class | is_generated
bool 2
classes | length_bytes
int64 128
12.8k
| extension
stringclasses 11
values | content
stringlengths 128
8.19k
| authors
listlengths 1
1
| author_id
stringlengths 1
79
|
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
79e6ece2c35ba3ab93f78a5542d0d07e47dd95f3
|
924358c01502fc238789e780465d5d169729e944
|
/modules/server/src/main/java/org/zodiark/service/wowza/WowzaUUID.java
|
9e68cc025000ba7ed0a8588e5b7f75142c935a6f
|
[
"Apache-2.0"
] |
permissive
|
francisdesjardins/zodiark
|
23e8896ac3b09bd5b4fe4bbb0d1620aa95a996a9
|
746337135b29179698c1af44ee3fa2c06318bc53
|
refs/heads/master
| 2021-01-14T14:23:23.783798
| 2014-11-30T06:26:27
| 2014-11-30T06:26:27
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 923
|
java
|
/*
* Copyright 2013-2014 High-Level Technologies
*
* 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://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 org.zodiark.service.wowza;
public class WowzaUUID {
private String uuid;
public WowzaUUID(){}
public WowzaUUID(String uuid) {
this.uuid = uuid;
}
public String getUuid() {
return uuid;
}
public void setUuid(String uuid) {
this.uuid = uuid;
}
}
|
[
"jfarcand@apache.org"
] |
jfarcand@apache.org
|
76563e29929170d2386d8c8cb0dcc113e924241e
|
47798511441d7b091a394986afd1f72e8f9ff7ab
|
/src/main/java/com/alipay/api/response/AlipayTrustUserScoreGetResponse.java
|
d767345eb365a65c39574508d0d42b90014d0f9e
|
[
"Apache-2.0"
] |
permissive
|
yihukurama/alipay-sdk-java-all
|
c53d898371032ed5f296b679fd62335511e4a310
|
0bf19c486251505b559863998b41636d53c13d41
|
refs/heads/master
| 2022-07-01T09:33:14.557065
| 2020-05-07T11:20:51
| 2020-05-07T11:20:51
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 793
|
java
|
package com.alipay.api.response;
import com.alipay.api.internal.mapping.ApiField;
import com.alipay.api.domain.AliTrustScore;
import com.alipay.api.AlipayResponse;
/**
* ALIPAY API: alipay.trust.user.score.get response.
*
* @author auto create
* @since 1.0, 2019-03-08 15:29:11
*/
public class AlipayTrustUserScoreGetResponse extends AlipayResponse {
private static final long serialVersionUID = 2728776898664187328L;
/**
* 芝麻信用通过模型计算出的该用户的芝麻信用评分
*/
@ApiField("ali_trust_score")
private AliTrustScore aliTrustScore;
public void setAliTrustScore(AliTrustScore aliTrustScore) {
this.aliTrustScore = aliTrustScore;
}
public AliTrustScore getAliTrustScore( ) {
return this.aliTrustScore;
}
}
|
[
"ben.zy@antfin.com"
] |
ben.zy@antfin.com
|
b2dc277355058251153d0aee755e78ec272413fc
|
d89f77bcbcd3474cbb038d79a407c912c6e00cf9
|
/src/main/java/com/tencentcloudapi/tcaplusdb/v20190823/models/TagsInfoOfTable.java
|
fc8c4275a07dbc0413ac4f807099554e6fd84b46
|
[
"Apache-2.0"
] |
permissive
|
victoryckl/tencentcloud-sdk-java
|
23e5486445d7e4316f85247b35a2e2ba69b92546
|
73a6e6632e0273cfdebd5487cc7ecff920c5e89c
|
refs/heads/master
| 2022-11-20T16:14:11.452984
| 2020-07-28T01:08:50
| 2020-07-28T01:08:50
| 283,146,154
| 0
| 1
|
Apache-2.0
| 2020-07-28T08:14:10
| 2020-07-28T08:14:09
| null |
UTF-8
|
Java
| false
| false
| 5,290
|
java
|
/*
* Copyright (c) 2017-2018 THL A29 Limited, a Tencent company. All Rights Reserved.
*
* 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://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 com.tencentcloudapi.tcaplusdb.v20190823.models;
import com.tencentcloudapi.common.AbstractModel;
import com.google.gson.annotations.SerializedName;
import com.google.gson.annotations.Expose;
import java.util.HashMap;
public class TagsInfoOfTable extends AbstractModel{
/**
* 表格实例ID
注意:此字段可能返回 null,表示取不到有效值。
*/
@SerializedName("TableInstanceId")
@Expose
private String TableInstanceId;
/**
* 表格名称
注意:此字段可能返回 null,表示取不到有效值。
*/
@SerializedName("TableName")
@Expose
private String TableName;
/**
* 表格组ID
注意:此字段可能返回 null,表示取不到有效值。
*/
@SerializedName("TableGroupId")
@Expose
private String TableGroupId;
/**
* 标签信息
注意:此字段可能返回 null,表示取不到有效值。
*/
@SerializedName("Tags")
@Expose
private TagInfoUnit [] Tags;
/**
* 错误信息
注意:此字段可能返回 null,表示取不到有效值。
*/
@SerializedName("Error")
@Expose
private ErrorInfo Error;
/**
* Get 表格实例ID
注意:此字段可能返回 null,表示取不到有效值。
* @return TableInstanceId 表格实例ID
注意:此字段可能返回 null,表示取不到有效值。
*/
public String getTableInstanceId() {
return this.TableInstanceId;
}
/**
* Set 表格实例ID
注意:此字段可能返回 null,表示取不到有效值。
* @param TableInstanceId 表格实例ID
注意:此字段可能返回 null,表示取不到有效值。
*/
public void setTableInstanceId(String TableInstanceId) {
this.TableInstanceId = TableInstanceId;
}
/**
* Get 表格名称
注意:此字段可能返回 null,表示取不到有效值。
* @return TableName 表格名称
注意:此字段可能返回 null,表示取不到有效值。
*/
public String getTableName() {
return this.TableName;
}
/**
* Set 表格名称
注意:此字段可能返回 null,表示取不到有效值。
* @param TableName 表格名称
注意:此字段可能返回 null,表示取不到有效值。
*/
public void setTableName(String TableName) {
this.TableName = TableName;
}
/**
* Get 表格组ID
注意:此字段可能返回 null,表示取不到有效值。
* @return TableGroupId 表格组ID
注意:此字段可能返回 null,表示取不到有效值。
*/
public String getTableGroupId() {
return this.TableGroupId;
}
/**
* Set 表格组ID
注意:此字段可能返回 null,表示取不到有效值。
* @param TableGroupId 表格组ID
注意:此字段可能返回 null,表示取不到有效值。
*/
public void setTableGroupId(String TableGroupId) {
this.TableGroupId = TableGroupId;
}
/**
* Get 标签信息
注意:此字段可能返回 null,表示取不到有效值。
* @return Tags 标签信息
注意:此字段可能返回 null,表示取不到有效值。
*/
public TagInfoUnit [] getTags() {
return this.Tags;
}
/**
* Set 标签信息
注意:此字段可能返回 null,表示取不到有效值。
* @param Tags 标签信息
注意:此字段可能返回 null,表示取不到有效值。
*/
public void setTags(TagInfoUnit [] Tags) {
this.Tags = Tags;
}
/**
* Get 错误信息
注意:此字段可能返回 null,表示取不到有效值。
* @return Error 错误信息
注意:此字段可能返回 null,表示取不到有效值。
*/
public ErrorInfo getError() {
return this.Error;
}
/**
* Set 错误信息
注意:此字段可能返回 null,表示取不到有效值。
* @param Error 错误信息
注意:此字段可能返回 null,表示取不到有效值。
*/
public void setError(ErrorInfo Error) {
this.Error = Error;
}
/**
* Internal implementation, normal users should not use it.
*/
public void toMap(HashMap<String, String> map, String prefix) {
this.setParamSimple(map, prefix + "TableInstanceId", this.TableInstanceId);
this.setParamSimple(map, prefix + "TableName", this.TableName);
this.setParamSimple(map, prefix + "TableGroupId", this.TableGroupId);
this.setParamArrayObj(map, prefix + "Tags.", this.Tags);
this.setParamObj(map, prefix + "Error.", this.Error);
}
}
|
[
"tencentcloudapi@tenent.com"
] |
tencentcloudapi@tenent.com
|
f6a7446e2e518ac53995a75bc3465de05b6848c2
|
da8263da02dda9a718d733cddb435ec19887374f
|
/modules/citrus-java-dsl/src/test/java/com/consol/citrus/dsl/design/ApplyTestDesignBehaviorTest.java
|
2a5770e53164863029bb994394f676218b51f49b
|
[
"Apache-2.0"
] |
permissive
|
TimeInvestor/citrus
|
c45ae9f8eb9315489957227bb3e1288648a90e24
|
5604dabba96ec0ca5fca0d9e415ae9c8ab89ba39
|
refs/heads/master
| 2020-05-29T11:05:35.221557
| 2016-05-12T16:23:24
| 2016-05-12T16:23:24
| 58,848,173
| 1
| 0
| null | 2016-05-15T06:50:36
| 2016-05-15T06:50:36
| null |
UTF-8
|
Java
| false
| false
| 7,744
|
java
|
/*
* Copyright 2006-2013 the original author or authors.
*
* 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://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 com.consol.citrus.dsl.design;
import com.consol.citrus.TestCase;
import com.consol.citrus.TestCaseMetaInfo;
import com.consol.citrus.actions.EchoAction;
import com.consol.citrus.testng.AbstractTestNGUnitTest;
import org.testng.Assert;
import org.testng.annotations.Test;
/**
* @author Christoph Deppisch
*/
public class ApplyTestDesignBehaviorTest extends AbstractTestNGUnitTest {
@Test
public void testBehaviorFrontPosition() {
MockTestDesigner builder = new MockTestDesigner(applicationContext, context) {
@Override
public void configure() {
applyBehavior(new FooBehavior());
description("This is a Test");
author("Christoph");
status(TestCaseMetaInfo.Status.FINAL);
echo("test");
}
};
builder.configure();
TestCase test = builder.getTestCase();
Assert.assertEquals(test.getActionCount(), 2);
Assert.assertEquals(test.getDescription(), "This is a Test");
Assert.assertEquals(test.getMetaInfo().getAuthor(), "Christoph");
Assert.assertEquals(test.getMetaInfo().getStatus(), TestCaseMetaInfo.Status.FINAL);
Assert.assertEquals(test.getActions().get(0).getClass(), EchoAction.class);
Assert.assertEquals(((EchoAction)test.getActions().get(0)).getMessage(), "fooBehavior");
Assert.assertEquals(test.getActions().get(1).getClass(), EchoAction.class);
Assert.assertEquals(((EchoAction)test.getActions().get(1)).getMessage(), "test");
}
@Test
public void testBehaviorWithFinally() {
MockTestDesigner builder = new MockTestDesigner(applicationContext, context) {
@Override
public void configure() {
description("This is a Test");
author("Christoph");
status(TestCaseMetaInfo.Status.FINAL);
echo("test");
doFinally(
echo("finally")
);
applyBehavior(new AbstractTestBehavior() {
@Override
public void apply() {
echo("behavior");
doFinally(
echo("behaviorFinally")
);
}
});
}
};
builder.configure();
TestCase test = builder.getTestCase();
Assert.assertEquals(test.getActionCount(), 2);
Assert.assertEquals(test.getDescription(), "This is a Test");
Assert.assertEquals(test.getMetaInfo().getAuthor(), "Christoph");
Assert.assertEquals(test.getMetaInfo().getStatus(), TestCaseMetaInfo.Status.FINAL);
Assert.assertEquals(test.getActions().get(0).getClass(), EchoAction.class);
Assert.assertEquals(((EchoAction)test.getActions().get(0)).getMessage(), "test");
Assert.assertEquals(test.getActions().get(1).getClass(), EchoAction.class);
Assert.assertEquals(((EchoAction)test.getActions().get(1)).getMessage(), "behavior");
Assert.assertEquals(test.getFinalActions().size(), 2);
Assert.assertEquals(test.getFinalActions().get(0).getClass(), EchoAction.class);
Assert.assertEquals(((EchoAction)test.getFinalActions().get(0)).getMessage(), "finally");
Assert.assertEquals(test.getFinalActions().get(1).getClass(), EchoAction.class);
Assert.assertEquals(((EchoAction)test.getFinalActions().get(1)).getMessage(), "behaviorFinally");
}
@Test
public void testApplyBehavior() {
MockTestDesigner builder = new MockTestDesigner(applicationContext, context) {
@Override
public void configure() {
description("This is a Test");
author("Christoph");
status(TestCaseMetaInfo.Status.FINAL);
variable("test", "test");
applyBehavior(new FooBehavior());
echo("test");
applyBehavior(new BarBehavior());
}
};
builder.configure();
TestCase test = builder.getTestCase();
Assert.assertEquals(test.getActionCount(), 3);
Assert.assertEquals(test.getDescription(), "This is a Test");
Assert.assertEquals(test.getMetaInfo().getAuthor(), "Christoph");
Assert.assertEquals(test.getMetaInfo().getStatus(), TestCaseMetaInfo.Status.FINAL);
Assert.assertEquals(test.getActions().get(0).getClass(), EchoAction.class);
Assert.assertEquals(((EchoAction)test.getActions().get(0)).getMessage(), "fooBehavior");
Assert.assertEquals(test.getActions().get(1).getClass(), EchoAction.class);
Assert.assertEquals(((EchoAction)test.getActions().get(1)).getMessage(), "test");
Assert.assertEquals(test.getActions().get(2).getClass(), EchoAction.class);
Assert.assertEquals(((EchoAction)test.getActions().get(2)).getMessage(), "barBehavior");
Assert.assertEquals(builder.getVariables().size(), 3);
Assert.assertEquals(builder.getVariables().get("test"), "test");
Assert.assertEquals(builder.getVariables().get("foo"), "test");
Assert.assertEquals(builder.getVariables().get("bar"), "test");
}
@Test
public void testApplyBehaviorTwice() {
MockTestDesigner builder = new MockTestDesigner(applicationContext, context) {
@Override
public void configure() {
description("This is a Test");
author("Christoph");
status(TestCaseMetaInfo.Status.FINAL);
FooBehavior behavior = new FooBehavior();
applyBehavior(behavior);
echo("test");
applyBehavior(behavior);
}
};
builder.configure();
TestCase test = builder.getTestCase();
Assert.assertEquals(test.getActionCount(), 3);
Assert.assertEquals(test.getDescription(), "This is a Test");
Assert.assertEquals(test.getMetaInfo().getAuthor(), "Christoph");
Assert.assertEquals(test.getMetaInfo().getStatus(), TestCaseMetaInfo.Status.FINAL);
Assert.assertEquals(test.getActions().get(0).getClass(), EchoAction.class);
Assert.assertEquals(((EchoAction)test.getActions().get(0)).getMessage(), "fooBehavior");
Assert.assertEquals(test.getActions().get(1).getClass(), EchoAction.class);
Assert.assertEquals(((EchoAction)test.getActions().get(1)).getMessage(), "test");
Assert.assertEquals(test.getActions().get(2).getClass(), EchoAction.class);
Assert.assertEquals(((EchoAction)test.getActions().get(2)).getMessage(), "fooBehavior");
}
private static class FooBehavior extends AbstractTestBehavior {
public void apply() {
variable("foo", "test");
echo("fooBehavior");
}
}
private static class BarBehavior extends AbstractTestBehavior {
public void apply() {
variable("bar", "test");
echo("barBehavior");
}
}
}
|
[
"deppisch@consol.de"
] |
deppisch@consol.de
|
240205b52de67124f9000f4396b8e8a93e6f6208
|
1eaf18d3198d4279a3b538949cadf0926c8b775f
|
/src/zcy_大厂算法和数据结构刷题班/class16/Code02_SmallestUnFormedSum.java
|
5ab1420cdf810599f9b8262b45730298e5017d89
|
[] |
no_license
|
jhhelloworld/coding
|
0006645a4c9115f843c4b5f82608861b35de84b9
|
eff9d949c0b3d3b048717f49d7c9cc2a71c34d5b
|
refs/heads/master
| 2023-04-10T12:38:54.402231
| 2023-03-27T11:13:16
| 2023-03-27T11:13:16
| 129,262,492
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 3,055
|
java
|
package zcy_大厂算法和数据结构刷题班.class16;
import java.util.Arrays;
import java.util.HashSet;
public class Code02_SmallestUnFormedSum {
public static int unformedSum1(int[] arr) {
if (arr == null || arr.length == 0) {
return 1;
}
HashSet<Integer> set = new HashSet<Integer>();
process(arr, 0, 0, set);
int min = Integer.MAX_VALUE;
for (int i = 0; i != arr.length; i++) {
min = Math.min(min, arr[i]);
}
for (int i = min + 1; i != Integer.MIN_VALUE; i++) {
if (!set.contains(i)) {
return i;
}
}
return 0;
}
public static void process(int[] arr, int i, int sum, HashSet<Integer> set) {
if (i == arr.length) {
set.add(sum);
return;
}
process(arr, i + 1, sum, set);
process(arr, i + 1, sum + arr[i], set);
}
public static int unformedSum2(int[] arr) {
if (arr == null || arr.length == 0) {
return 1;
}
int sum = 0;
int min = Integer.MAX_VALUE;
for (int i = 0; i != arr.length; i++) {
sum += arr[i];
min = Math.min(min, arr[i]);
}
// boolean[][] dp ...
int N = arr.length;
boolean[][] dp = new boolean[N][sum + 1];
for (int i = 0; i < N; i++) {// arr[0..i] 0
dp[i][0] = true;
}
dp[0][arr[0]] = true;
for (int i = 1; i < N; i++) {
for (int j = 1; j <= sum; j++) {
dp[i][j] = dp[i - 1][j] || ((j - arr[i] >= 0) ? dp[i - 1][j - arr[i]] : false);
}
}
for (int j = min; j <= sum; j++) {
if (!dp[N - 1][j]) {
return j;
}
}
return sum + 1;
}
// 已知arr中肯定有1这个数
public static int unformedSum3(int[] arr) {
if (arr == null || arr.length == 0) {
return 0;
}
Arrays.sort(arr); // O (N * logN)
int range = 1;
// arr[0] == 1
for (int i = 1; i != arr.length; i++) {
if (arr[i] > range + 1) {
return range + 1;
} else {
range += arr[i];
}
}
return range + 1;
}
public static int[] generateArray(int len, int maxValue) {
int[] res = new int[len];
for (int i = 0; i != res.length; i++) {
res[i] = (int) (Math.random() * maxValue) + 1;
}
return res;
}
public static void printArray(int[] arr) {
for (int i = 0; i != arr.length; i++) {
System.out.print(arr[i] + " ");
}
System.out.println();
}
public static void main(String[] args) {
int len = 27;
int max = 30;
int[] arr = generateArray(len, max);
printArray(arr);
long start = System.currentTimeMillis();
System.out.println(unformedSum1(arr));
long end = System.currentTimeMillis();
System.out.println("cost time: " + (end - start) + " ms");
System.out.println("======================================");
start = System.currentTimeMillis();
System.out.println(unformedSum2(arr));
end = System.currentTimeMillis();
System.out.println("cost time: " + (end - start) + " ms");
System.out.println("======================================");
System.out.println("set arr[0] to 1");
arr[0] = 1;
start = System.currentTimeMillis();
System.out.println(unformedSum3(arr));
end = System.currentTimeMillis();
System.out.println("cost time: " + (end - start) + " ms");
}
}
|
[
"jianghua07@meituan.com"
] |
jianghua07@meituan.com
|
413b703f03bdc1c179dfb68b0476683c42345c63
|
065c1f648e8dd061a20147ff9c0dbb6b5bc8b9be
|
/checkstyle_cluster/12233/src_192.java
|
7d12739290f5952588be568ab6b291614c2bc396
|
[] |
no_license
|
martinezmatias/GenPat-data-C3
|
63cfe27efee2946831139747e6c20cf952f1d6f6
|
b360265a6aa3bb21bd1d64f1fc43c3b37d0da2a4
|
refs/heads/master
| 2022-04-25T17:59:03.905613
| 2020-04-15T14:41:34
| 2020-04-15T14:41:34
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 953
|
java
|
package com.puppycrawl.tools.checkstyle.checks.whitespace;
import com.puppycrawl.tools.checkstyle.BaseCheckTestCase;
import com.puppycrawl.tools.checkstyle.DefaultConfiguration;
public class TabCharacterCheckTest
extends BaseCheckTestCase
{
public void testIt() throws Exception
{
final DefaultConfiguration checkConfig =
createCheckConfig(TabCharacterCheck.class);
final String[] expected = {
"19:25: Line contains a tab character.",
"145:35: Line contains a tab character.",
"146:64: Line contains a tab character.",
"154:9: Line contains a tab character.",
"155:10: Line contains a tab character.",
"156:1: Line contains a tab character.",
"157:3: Line contains a tab character.",
"158:3: Line contains a tab character."
};
verify(checkConfig, getPath("InputSimple.java"), expected);
}
}
|
[
"375833274@qq.com"
] |
375833274@qq.com
|
690ce0f123ee94268532e628aa7923b88c5ce3e5
|
61e3ff6d34297cf444e5749c1e1d7ed5ba93cecd
|
/com/android/common/C0770w.java
|
ff3b482422763105e5c52a730d5ef11cb31c7411
|
[] |
no_license
|
BeYkeRYkt/nubia_cam_smali
|
b49beafe60b989fab02753601735e493f2f72d16
|
39dad22d05b0a2dfd4e9d04acad9673ac1add410
|
refs/heads/master
| 2020-03-17T18:31:12.851246
| 2018-05-17T15:24:14
| 2018-05-17T15:24:14
| 133,825,725
| 2
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 3,654
|
java
|
package com.android.common;
import android.os.Handler;
import android.os.Message;
import android.view.KeyEvent;
import com.android.common.appService.CameraMember;
import com.android.common.camerastate.FunctionState;
import com.android.common.custom.C0421M;
import com.p010a.C0090a;
class C0770w extends Handler {
final /* synthetic */ ActivityBase ajS;
C0770w(ActivityBase activityBase) {
this.ajS = activityBase;
}
public void handleMessage(Message message) {
if (!this.ajS.aiG.SO()) {
switch (message.what) {
case 2:
this.ajS.atj();
break;
case 4:
this.ajS.arX(0);
break;
case 5:
this.ajS.asp();
break;
case 18:
this.ajS.auU();
this.ajS.auT();
break;
case 19:
this.ajS.auP();
break;
case 35:
if (this.ajS.asL() != FunctionState.SPEED_MULTISHOOTING) {
this.ajS.aiG.Tk(false);
break;
}
break;
case 37:
this.ajS.ajg = true;
break;
case 38:
this.ajS.aiG.Ti().alY(null);
break;
case 60:
this.ajS.arI();
break;
case 86:
if (!(this.ajS.aiG.SP() == CameraMember.VIDEO_RECORD || this.ajS.aiG.SP() == CameraMember.VIDEO_SLOMO)) {
this.ajS.aiG.SU().Ro();
break;
}
case 87:
this.ajS.aiG.SU().RL();
break;
case 91:
if (C0421M.dC().dD().bD()) {
this.ajS.arG(this.ajS.arR());
break;
}
break;
case 94:
this.ajS.atT();
break;
case 95:
this.ajS.atZ();
break;
case 97:
this.ajS.asf();
break;
case 103:
if (this.ajS.atp()) {
KeyEvent keyEvent = new KeyEvent(0, 10004);
this.ajS.onKeyDown(10004, keyEvent);
this.ajS.onKeyUp(10004, keyEvent);
C0616j.apa(this.ajS, "fingerprint", "fingerprint");
break;
}
return;
case 104:
this.ajS.asd();
break;
case 107:
this.ajS.aiG.Tc().Mb();
break;
case 112:
if (!this.ajS.aiG.SO()) {
this.ajS.getWindow().clearFlags(128);
C0090a.bvo("ActivityBase", "Close camera time arrived.");
this.ajS.aiG.SU().Ru(true);
this.ajS.aiG.SU().RD(true);
this.ajS.aiG.Xm();
this.ajS.auW();
this.ajS.ass();
this.ajS.asA(true);
break;
}
break;
case 113:
this.ajS.aul();
break;
}
}
}
}
|
[
"beykerykt@gmail.com"
] |
beykerykt@gmail.com
|
4e9e6e4e081953dec82e97aa09ebdbe60014b392
|
d7eb1163ee81f3284ecba13350547f3c98450be3
|
/app/src/main/java/star/liuwen/com/cash_books/bean/AccountModel.java
|
e07844b1b7d03cdfbeeac2c46208fa23865fb06f
|
[] |
no_license
|
bhavikgandhi007/Cash_Book
|
9b584d8151f2a30fae0328b3ac5389ab63aa45d8
|
e89631897bb78b151d81735ed35e180a926ae35f
|
refs/heads/master
| 2020-03-11T12:38:45.583197
| 2017-07-07T06:11:10
| 2017-07-07T06:11:10
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 5,606
|
java
|
package star.liuwen.com.cash_books.bean;
import org.greenrobot.greendao.annotation.Entity;
import org.greenrobot.greendao.annotation.Generated;
import org.greenrobot.greendao.annotation.Id;
import java.io.Serializable;
/**
* Created by liuwen on 2017/1/6.
*/
@Entity
public class AccountModel implements Serializable {
private static final long serialVersionUID = 1L;//为了避免反序列化失败 加的一个uid
@Id(autoincrement = true)
private Long id;
private String AccountType;//账户类型 (账户名)
private String Data;//日期 2017-2-28
private double Money; //消费或者支出金额
private String ConsumeType; //消费类型 (信用卡还是储蓄卡)
private int url; //图片(消费的图片或者是收入的图片)
private String timeMinSec;//时分秒 精确到到时分秒消费 2017-2-28-12-30-31
private String zhiChuShouRuType; //是否是支出或者是收入
private float consumePercent;//百分比
private double zhiCHuAdd; //总支出
private double sHouRuAdd; //总收入
private double AccountYuer;//账户余额
private String ShowFirstDate;//用来标识是否显示开启了记账之路
private long choiceAccountId;//用来标识查询账户的唯一数据
private String budget;//预算金额
public AccountModel() {
}
public AccountModel(String consumeType, int url, double money, float consumePercent, String data) {
ConsumeType = consumeType;
this.url = url;
Money = money;
this.consumePercent = consumePercent;
Data = data;
}
public AccountModel(double money, String consumeType, int url) {
Money = money;
ConsumeType = consumeType;
this.url = url;
}
public AccountModel(String accountType, String data, double money, String consumeType, int url, String timeMinSec, String zhiChuShouRuType, long id) {
AccountType = accountType;
Data = data;
Money = money;
ConsumeType = consumeType;
this.url = url;
this.timeMinSec = timeMinSec;
this.zhiChuShouRuType = zhiChuShouRuType;
this.choiceAccountId = id;
}
@Generated(hash = 1182184895)
public AccountModel(Long id, String AccountType, String Data, double Money, String ConsumeType, int url, String timeMinSec, String zhiChuShouRuType,
float consumePercent, double zhiCHuAdd, double sHouRuAdd, double AccountYuer, String ShowFirstDate, long choiceAccountId, String budget) {
this.id = id;
this.AccountType = AccountType;
this.Data = Data;
this.Money = Money;
this.ConsumeType = ConsumeType;
this.url = url;
this.timeMinSec = timeMinSec;
this.zhiChuShouRuType = zhiChuShouRuType;
this.consumePercent = consumePercent;
this.zhiCHuAdd = zhiCHuAdd;
this.sHouRuAdd = sHouRuAdd;
this.AccountYuer = AccountYuer;
this.ShowFirstDate = ShowFirstDate;
this.choiceAccountId = choiceAccountId;
this.budget = budget;
}
public long getChoiceAccountId() {
return this.choiceAccountId;
}
public void setChoiceAccountId(long choiceAccountId) {
this.choiceAccountId = choiceAccountId;
}
public String getShowFirstDate() {
return this.ShowFirstDate;
}
public void setShowFirstDate(String ShowFirstDate) {
this.ShowFirstDate = ShowFirstDate;
}
public double getAccountYuer() {
return this.AccountYuer;
}
public void setAccountYuer(double AccountYuer) {
this.AccountYuer = AccountYuer;
}
public double getSHouRuAdd() {
return this.sHouRuAdd;
}
public void setSHouRuAdd(double sHouRuAdd) {
this.sHouRuAdd = sHouRuAdd;
}
public double getZhiCHuAdd() {
return this.zhiCHuAdd;
}
public void setZhiCHuAdd(double zhiCHuAdd) {
this.zhiCHuAdd = zhiCHuAdd;
}
public float getConsumePercent() {
return this.consumePercent;
}
public void setConsumePercent(float consumePercent) {
this.consumePercent = consumePercent;
}
public String getZhiChuShouRuType() {
return this.zhiChuShouRuType;
}
public void setZhiChuShouRuType(String zhiChuShouRuType) {
this.zhiChuShouRuType = zhiChuShouRuType;
}
public String getTimeMinSec() {
return this.timeMinSec;
}
public void setTimeMinSec(String timeMinSec) {
this.timeMinSec = timeMinSec;
}
public int getUrl() {
return this.url;
}
public void setUrl(int url) {
this.url = url;
}
public String getConsumeType() {
return this.ConsumeType;
}
public void setConsumeType(String ConsumeType) {
this.ConsumeType = ConsumeType;
}
public double getMoney() {
return this.Money;
}
public void setMoney(double Money) {
this.Money = Money;
}
public String getData() {
return this.Data;
}
public void setData(String Data) {
this.Data = Data;
}
public String getAccountType() {
return this.AccountType;
}
public void setAccountType(String AccountType) {
this.AccountType = AccountType;
}
public Long getId() {
return this.id;
}
public void setId(Long id) {
this.id = id;
}
public String getBudget() {
return budget;
}
public void setBudget(String budget) {
this.budget = budget;
}
}
|
[
"370494581@qq.com"
] |
370494581@qq.com
|
331a0f4a8361637b146bda8f564c7bf522f95e27
|
ebea2e1fcefb0a00d9c8c4758b96825cf574c3de
|
/level/src/main/java/com/sskj/level/presenter/LevelPanKouFragmentPresenter.java
|
c30bec53a4dacac9a66820cdd11e087557adbea5
|
[] |
no_license
|
hailinliu/yj-jiaoyisuo
|
ec6b7c4ed9ddf0c8d3afaddf418a406dfc6d16ec
|
68bc459e42a238da2ca5a2dc639a4289c9baedc0
|
refs/heads/master
| 2023-07-17T07:53:53.430796
| 2021-08-28T09:27:44
| 2021-08-28T09:27:44
| 394,162,489
| 1
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 6,984
|
java
|
package com.sskj.level.presenter;
import android.annotation.SuppressLint;
import com.google.gson.Gson;
import com.google.gson.reflect.TypeToken;
import com.lzy.okgo.OkGo;
import com.lzy.okgo.callback.StringCallback;
import com.lzy.okgo.model.Response;
import com.sskj.common.base.HttpData;
import com.sskj.common.log.LogUtil;
import com.sskj.common.util.DisposUtil;
import com.sskj.common.util.GSonUtil;
import com.sskj.hangqing.bean.AskBean;
import com.sskj.hangqing.bean.BidBean;
import com.sskj.level.bean.WSFiveBean1;
import com.sskj.level.http.HttpConfig;
import com.sskj.level.ui.fragment.LevelPanKouFragment;
import com.sskj.lib.RxBusCode;
import com.sskj.lib.bean.BaseBean;
import com.sskj.lib.bean.CoinBean;
import com.sskj.lib.bean.CoinBean1;
import com.sskj.lib.bean.RateBean;
import com.sskj.lib.bean.WSFiveBean;
import com.sskj.lib.box.LiveDataBus;
import com.sskj.lib.http.CallBackOption;
import com.sskj.lib.http.JsonCallBack;
import com.sskj.lib.util.CommonUtil;
import com.sskj.lib.util.MyWebSocketServer;
import java.util.List;
import io.reactivex.Flowable;
import io.reactivex.android.schedulers.AndroidSchedulers;
import io.reactivex.disposables.CompositeDisposable;
import io.reactivex.disposables.Disposable;
import io.reactivex.schedulers.Schedulers;
import ua.naiksoftware.stomp.Stomp;
import ua.naiksoftware.stomp.StompClient;
import ua.naiksoftware.stomp.dto.StompMessage;
public class LevelPanKouFragmentPresenter extends BasePresenter<LevelPanKouFragment> {
StompClient mStompClient;
private CompositeDisposable compositeDisposable;
private CompositeDisposable compositeDisposable1;
// private MyWebSocketServer stockSocket1;
public void getData(String code) {
httpService.getProduct1(null).execute(new StringCallback() {
@Override
public void onSuccess(Response<String> response) {
Gson gson = new Gson();
List<CoinBean1> list = gson.fromJson(response.body(), new TypeToken<List<CoinBean1>>() {
}.getType());
mView.updateUI(list);
}
});
}
/* public void getPankou(String code) {
OkGo.<String>get(HttpConfig.BASE_URL + HttpConfig.GET_PANKOU)
.params("symbol", CommonUtil.dealReuqestCode(code))
.tag(this)
.execute(new StringCallback() {
@Override
public void onSuccess(Response<String> response) {
com.sskj.level.bean.WSFiveBean1 bean = GSonUtil.GsonToBean(response.body(), WSFiveBean1.class);
mView.updateFive(bean);
}
});
}*/
public void getRate(String fromUnit,String toUnit){
httpService.getRate(fromUnit,toUnit).execute(new CallBackOption<BaseBean>() {
}.loadBind(mView).execute(httpService->{
String rate= httpService.getData().toString();
RateBean bean = new RateBean();
bean.setName(toUnit);
bean.setRate(rate);
mView.updateRate(bean);
// LiveDataBus.get().with(RxBusCode.RATE, RateBean.class).postValue(bean);
//RxBus.getDefault().send(RxBusCode.RATE,rate);
}));
}
StompClient mStompClient1;
public void initHangqingSocket(){
String url = "/topic/level/thumb";
if(mStompClient1==null){
mStompClient1 = Stomp.over(Stomp.ConnectionProvider.OKHTTP, HttpConfig.WS_BASE_URL);
mStompClient1.lifecycle().subscribeOn(Schedulers.io()).observeOn(AndroidSchedulers.mainThread()).subscribe(lifecycleEvent -> {
lifecycleEvent.getType();
});
mStompClient1.withClientHeartbeat(60000).withServerHeartbeat(60000).reconnect();
}
resetSubscriptions1();
Disposable dispTopic = mStompClient1.topic(url).subscribeOn(Schedulers.io()).observeOn(AndroidSchedulers.mainThread())
.subscribe((StompMessage topicMessage)->{
CoinBean1 bean = GSonUtil.GsonToBean(topicMessage.getPayload(),CoinBean1.class);
mView.refreshCoin(bean);
// mView.updateUI(bean);
},throwable -> {
LogUtil.e("链接错误",throwable);
});
compositeDisposable1.add(dispTopic);
mStompClient1.connect();
/*stockSocket1 = httpService.pushCoin1();
stockSocket1.map(s->new Gson().fromJson(s, CoinBean1.class))
.subscribe(newcoinbean->mView.refreshCoin(newcoinbean),Throwable::getMessage);*/
}
public void initSocket(String code) {
if (code==null)
return;
code= CommonUtil.dealReuqestCode(code);
String url = "/topic/level/trade-plate/"+code;
if(mStompClient==null){
mStompClient = Stomp.over(Stomp.ConnectionProvider.OKHTTP, "wss://www.bitflnex.pro/level-market/market-ws/websocket");
mStompClient.lifecycle().subscribeOn(Schedulers.io()).observeOn(AndroidSchedulers.mainThread()).subscribe(lifecycleEvent -> {
lifecycleEvent.getType();
});
mStompClient.withClientHeartbeat(60000).withServerHeartbeat(60000).reconnect();
}
resetSubscriptions();
Disposable dispTopic = mStompClient.topic(url).subscribeOn(Schedulers.io()).observeOn(AndroidSchedulers.mainThread())
.subscribe((StompMessage topicMessage)->{
// topicMessage.getPayload();
WSFiveBean bean = GSonUtil.GsonToBean(topicMessage.getPayload(),WSFiveBean.class);
mView.updateUI(bean);
LiveDataBus.get().with(RxBusCode.NEW_LEVEL_HANG,WSFiveBean.class).postValue(bean);
},throwable -> {
LogUtil.e("链接错误",throwable);
});
compositeDisposable.add(dispTopic);
mStompClient.connect();
}
private void resetSubscriptions() {
if (compositeDisposable != null) {
compositeDisposable.dispose();
}
compositeDisposable = new CompositeDisposable();
}
private void resetSubscriptions1() {
if (compositeDisposable1 != null) {
compositeDisposable1.dispose();
}
compositeDisposable1 = new CompositeDisposable();
}
@Override
public void detachView() {
closeWebSocket();
super.detachView();
}
public void closeWebSocket() {
if(mStompClient!=null&&mStompClient.isConnected()){
mStompClient.disconnect();
mStompClient=null;
}
if(mStompClient1!=null&&mStompClient1.isConnected()){
mStompClient1.disconnect();
mStompClient1=null;
}
if (compositeDisposable != null){
compositeDisposable.dispose();}
if (compositeDisposable1 != null){
compositeDisposable1.dispose();}
}
}
|
[
"1135231523@qq.com"
] |
1135231523@qq.com
|
23c09c009004dc0dfbbb1869a106cdc2fcc3e9f3
|
fa91450deb625cda070e82d5c31770be5ca1dec6
|
/Diff-Raw-Data/6/6_0c7237f1c7b5029d86ae74f8d46aa4d8375ee9a7/SearchCondition/6_0c7237f1c7b5029d86ae74f8d46aa4d8375ee9a7_SearchCondition_s.java
|
5ec3c2a8dc581936975ac076968cef6174d077e1
|
[] |
no_license
|
zhongxingyu/Seer
|
48e7e5197624d7afa94d23f849f8ea2075bcaec0
|
c11a3109fdfca9be337e509ecb2c085b60076213
|
refs/heads/master
| 2023-07-06T12:48:55.516692
| 2023-06-22T07:55:56
| 2023-06-22T07:55:56
| 259,613,157
| 6
| 2
| null | 2023-06-22T07:55:57
| 2020-04-28T11:07:49
| null |
UTF-8
|
Java
| false
| false
| 4,443
|
java
|
package models.support;
import com.avaje.ebean.ExpressionList;
import controllers.AbstractPostingApp;
import controllers.IssueApp;
import models.*;
import models.enumeration.State;
import org.apache.commons.collections.CollectionUtils;
import utils.LabelSearchUtil;
import java.util.HashSet;
import java.util.Set;
import static com.avaje.ebean.Expr.icontains;
public class SearchCondition extends AbstractPostingApp.SearchCondition {
public String state;
public Boolean commentedCheck;
public Long milestoneId;
public Set<Long> labelIds = new HashSet<>();
public Long authorId;
public Long assigneeId;
public SearchCondition clone() {
SearchCondition one = new SearchCondition();
one.orderBy = this.orderBy;
one.orderDir = this.orderDir;
one.filter = this.filter;
one.pageNum = one.pageNum;
one.state = this.state;
one.commentedCheck = this.commentedCheck;
one.milestoneId = this.milestoneId;
one.labelIds = new HashSet<Long>(this.labelIds);
one.authorId = this.authorId;
one.assigneeId = this.assigneeId;
return one;
}
public SearchCondition setOrderBy(String orderBy) {
this.orderBy = orderBy;
return this;
}
public SearchCondition setOrderDir(String orderDir) {
this.orderDir = orderDir;
return this;
}
public SearchCondition setFilter(String filter) {
this.filter = filter;
return this;
}
public SearchCondition setPageNum(int pageNum) {
this.pageNum = pageNum;
return this;
}
public SearchCondition setState(String state) {
this.state = state;
return this;
}
public SearchCondition setState(State state) {
this.state = state.state();
return this;
}
public SearchCondition setCommentedCheck(Boolean commentedCheck) {
this.commentedCheck = commentedCheck;
return this;
}
public SearchCondition setMilestoneId(Long milestoneId) {
this.milestoneId = milestoneId;
return this;
}
public SearchCondition setLabelIds(Set<Long> labelIds) {
this.labelIds = labelIds;
return this;
}
public SearchCondition addLabelId(Long labelId) {
labelIds.add(labelId);
return this;
}
public SearchCondition setAuthorId(Long authorId) {
this.authorId = authorId;
return this;
}
public SearchCondition setAssigneeId(Long assigneeId) {
this.assigneeId = assigneeId;
return this;
}
public SearchCondition() {
super();
milestoneId = null;
state = State.OPEN.name();
commentedCheck = false;
}
public ExpressionList<Issue> asExpressionList(Project project) {
ExpressionList<Issue> el = Issue.finder.where().eq("project.id", project.id);
if (filter != null) {
el.or(icontains("title", filter), icontains("body", filter));
}
if (authorId != null) {
if (authorId == User.anonymous.id) {
el.isNull("authorId");
} else {
el.eq("authorId", authorId);
}
}
if (assigneeId != null) {
if (assigneeId == User.anonymous.id) {
el.isNull("assignee");
} else {
el.eq("assignee.user.id", assigneeId);
el.eq("assignee.project.id", project.id);
}
}
if (milestoneId != null) {
if (milestoneId == Milestone.NULL_MILESTONE_ID) {
el.isNull("milestone");
} else {
el.eq("milestone.id", milestoneId);
}
}
if (commentedCheck) {
el.ge("numOfComments", AbstractPosting.NUMBER_OF_ONE_MORE_COMMENTS);
}
State st = State.getValue(state);
if (st.equals(State.OPEN) || st.equals(State.CLOSED)) {
el.eq("state", st);
}
if (CollectionUtils.isNotEmpty(labelIds)) {
el.add(LabelSearchUtil.createLabelSearchExpression(el.query(), labelIds));
}
if (orderBy != null) {
el.orderBy(orderBy + " " + orderDir);
}
return el;
}
}
|
[
"yuzhongxing88@gmail.com"
] |
yuzhongxing88@gmail.com
|
1b04fdae66d00e493334cff257eed3eaf860b030
|
2dcc440fa85d07e225104f074bcf9f061fe7a7ae
|
/gameserver/src/main/java/org/mmocore/gameserver/scripts/events/custom/impl/Ctf/CtfFlagObject.java
|
56e6adee4a543b45844a72c663ca4e59c62ac139
|
[] |
no_license
|
VitaliiBashta/L2Jts
|
a113bc719f2d97e06db3e0b028b2adb62f6e077a
|
ffb95b5f6e3da313c5298731abc4fcf4aea53fd5
|
refs/heads/master
| 2020-04-03T15:48:57.786720
| 2018-10-30T17:34:29
| 2018-10-30T17:35:04
| 155,378,710
| 0
| 3
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 5,100
|
java
|
package org.mmocore.gameserver.scripts.events.custom.impl.Ctf;
import org.apache.commons.lang3.ArrayUtils;
import org.mmocore.commons.database.dao.JdbcEntityState;
import org.mmocore.gameserver.model.base.TeamType;
import org.mmocore.gameserver.model.entity.events.Event;
import org.mmocore.gameserver.model.entity.events.objects.SpawnableObject;
import org.mmocore.gameserver.network.lineage.components.SystemMsg;
import org.mmocore.gameserver.network.lineage.serverpackets.SystemMessage;
import org.mmocore.gameserver.object.Creature;
import org.mmocore.gameserver.object.GameObject;
import org.mmocore.gameserver.object.Player;
import org.mmocore.gameserver.object.components.items.ItemInstance;
import org.mmocore.gameserver.object.components.items.attachments.FlagItemAttachment;
import org.mmocore.gameserver.scripts.events.custom.CaptureTeamFlagEvent;
import org.mmocore.gameserver.skills.SkillEntry;
import org.mmocore.gameserver.utils.ItemFunctions;
import org.mmocore.gameserver.utils.Location;
import org.mmocore.gameserver.world.GameObjectsStorage;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
/**
* @author VISTALL
* @date 20:38/03.04.2012
*/
public class CtfFlagObject implements SpawnableObject, FlagItemAttachment {
private static final Logger _log = LoggerFactory.getLogger(CtfFlagObject.class);
private ItemInstance _item;
private final Location _location;
private Event _event;
private final TeamType _teamType;
public CtfFlagObject(Location location, TeamType teamType) {
_location = location;
_teamType = teamType;
}
@Override
public void spawnObject(Event event) {
if (_item != null) {
_log.info("CtfFlagObject: can't spawn twice: " + event);
return;
}
_item = ItemFunctions.createItem(9819);
_item.setAttachment(this);
_item.dropMe(null, _location);
_item.setReflection(event.getReflection());
_item.setDropTime(0);
_event = event;
}
@Override
public void despawnObject(Event event) {
if (_item == null)
return;
Player owner = GameObjectsStorage.getPlayer(_item.getOwnerId());
if (owner != null) {
owner.getInventory().destroyItem(_item);
owner.sendDisarmMessage(_item);
}
_item.setAttachment(null);
_item.setJdbcState(JdbcEntityState.UPDATED);
_item.delete();
_item.deleteMe();
_item = null;
_event = null;
}
@Override
public void respawnObject(Event event) {
}
@Override
public void refreshObject(Event event) {
}
@Override
public void onLogout(Player player) {
onDeath(player, null);
}
@Override
public void onDeath(Player owner, Creature killer) {
owner.getInventory().removeItem(_item);
_item.setLocation(ItemInstance.ItemLocation.VOID);
_item.setJdbcState(JdbcEntityState.UPDATED);
_item.update();
owner.sendPacket(new SystemMessage(SystemMsg.YOU_HAVE_DROPPED_S1).addItemName(_item.getItemId()));
_item.dropMe(null, _location);
_item.setDropTime(0);
}
@Override
public boolean canPickUp(Player player) {
if (player.getActiveWeaponFlagAttachment() != null || player.isMounted())
return false;
CaptureTeamFlagEvent event = player.getEvent(CaptureTeamFlagEvent.class);
if (event != _event)
return false;
if (player.getTeam() == TeamType.NONE || player.getTeam() == _teamType)
return false;
return true;
}
@Override
public void pickUp(Player player) {
player.getInventory().equipItem(_item);
CaptureTeamFlagEvent event = player.getEvent(CaptureTeamFlagEvent.class);
event.sendPacket(new SystemMessage(SystemMsg.C1_HAS_ACQUIRED_THE_FLAG).addName(player), _teamType.revert());
}
@Override
public boolean canAttack(Player player) {
player.sendPacket(SystemMsg.THAT_WEAPON_CANNOT_PERFORM_ANY_ATTACKS);
return false;
}
@Override
public boolean canCast(Player player, SkillEntry skill) {
SkillEntry[] skills = player.getActiveWeaponItem().getAttachedSkills();
if (!ArrayUtils.contains(skills, skill)) {
player.sendPacket(SystemMsg.THAT_WEAPON_CANNOT_USE_ANY_OTHER_SKILL_EXCEPT_THE_WEAPONS_SKILL);
return false;
} else
return true;
}
@Override
public void setItem(ItemInstance item) {
// ignored
}
public Location getLocation() {
GameObject owner = getOwner();
if (owner != null)
return owner.getLoc();
else if (_item != null)
return _item.getLoc();
else
return _location;
}
public GameObject getOwner() {
return _item == null ? null : GameObjectsStorage.getPlayer(_item.getOwnerId());
}
public Event getEvent() {
return _event;
}
public TeamType getTeamType() {
return _teamType;
}
}
|
[
"Vitalii.Bashta@accenture.com"
] |
Vitalii.Bashta@accenture.com
|
ce0997df5cc8a2ffd97780f2da0600c8da7477f7
|
61f0628d3da0d7d77d72f3581bad7766dd49ea48
|
/httpdlog/httpdlog-parser/src/test/java/nl/basjes/parse/httpdlog/dissectors/TestModUniqueIdDissector.java
|
c0e74f3999630fad836b5725eb91d9be46b217dc
|
[
"Apache-2.0"
] |
permissive
|
herzcthu/logparser
|
725d7af5efbaf304488362cbb08ffb9e593aa6dc
|
121f4c53c26fc6862b4350ec8df11c9360aac325
|
refs/heads/master
| 2020-03-07T08:59:42.711657
| 2018-03-30T07:43:59
| 2018-03-30T07:43:59
| 127,395,052
| 0
| 0
|
Apache-2.0
| 2018-03-30T07:14:21
| 2018-03-30T07:14:21
| null |
UTF-8
|
Java
| false
| false
| 3,648
|
java
|
/*
* Apache HTTPD & NGINX Access log parsing made easy
* Copyright (C) 2011-2018 Niels Basjes
*
* 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://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 nl.basjes.parse.httpdlog.dissectors;
import nl.basjes.parse.core.test.DissectorTester;
import org.junit.Test;
public class TestModUniqueIdDissector {
@Test
public void testUniqueId1() {
// This test case was verified using https://github.com/web-online/mod-unique-id-decode
//$ ./mod_unique_id_uudecoder -i VaGTKApid0AAALpaNo0AAAAC
//unique_id.stamp = Sun Jul 12 00:05:28 2015
//unique_id.in_addr = 10.98.119.64
//unique_id.pid = 47706
//unique_id.counter = 13965
//unique_id.threadIndex = 2
DissectorTester.create()
.withDissector(new ModUniqueIdDissector())
.withInput("VaGTKApid0AAALpaNo0AAAAC")
.expect("TIME.EPOCH:epoch", "1436652328000")
.expect("IP:ip", "10.98.119.64")
.expect("PROCESSID:processid", "47706")
.expect("COUNTER:counter", "13965")
.expect("THREAD_INDEX:threadindex", "2")
.checkExpectations();
}
@Test
public void testUniqueId2() {
// This test case was verified using https://github.com/web-online/mod-unique-id-decode
//$ ./mod_unique_id_uudecoder -i Ucdv38CoEJwAAEusp6EAAADz
//unique_id.stamp = Sun Jun 23 23:59:59 2013
//unique_id.in_addr = 192.168.16.156
//unique_id.pid = 19372
//unique_id.counter = 42913
//unique_id.threadIndex = 243
DissectorTester.create()
.withDissector(new ModUniqueIdDissector())
.withInput("Ucdv38CoEJwAAEusp6EAAADz")
.expect("TIME.EPOCH:epoch", "1372024799000")
.expect("IP:ip", "192.168.16.156")
.expect("PROCESSID:processid", "19372")
.expect("COUNTER:counter", "42913")
.expect("THREAD_INDEX:threadindex", "243")
.checkExpectations();
}
@Test
public void testBadUniqueIdTooShort() {
DissectorTester.create()
.withDissector(new ModUniqueIdDissector())
.withInput("Ucdv38CoEJwAAEusp6EAAAD") // BAD: 1 letter too short
.expectAbsentString("TIME.EPOCH:epoch")
.expectAbsentString("IP:ip")
.expectAbsentString("PROCESSID:processid")
.expectAbsentString("COUNTER:counter")
.expectAbsentString("THREAD_INDEX:threadindex")
.checkExpectations();
}
@Test
public void testBadUniqueIdNotBase64() {
DissectorTester.create()
.withDissector(new ModUniqueIdDissector())
.withInput("Ucdv38CoEJwAAEusp6EAAAD!") // BAD: 1 letter wrong
.expectAbsentString("TIME.EPOCH:epoch")
.expectAbsentString("IP:ip")
.expectAbsentString("PROCESSID:processid")
.expectAbsentString("COUNTER:counter")
.expectAbsentString("THREAD_INDEX:threadindex")
.checkExpectations();
}
}
|
[
"niels@basjes.nl"
] |
niels@basjes.nl
|
320704c28636759e7a46e8ca9122e473f40ddb6d
|
d9493c1a388fb7d505db859a46ab16f09b9456a4
|
/java/OpenDental/TableZips.java
|
c5c7d9dfdffb2e03fa12240e6c52ec0b2483bf4c
|
[] |
no_license
|
leelingco/opendental
|
f29c51a76bf455496bbc307ab0a5cd588792e7a0
|
aaf621b2b5b64e1d8d0f3318050d143abeefe594
|
refs/heads/master
| 2021-01-21T00:25:30.774258
| 2016-02-16T04:23:27
| 2016-02-16T04:23:27
| 51,807,222
| 0
| 0
| null | 2016-02-16T04:12:27
| 2016-02-16T04:12:27
| null |
UTF-8
|
Java
| false
| false
| 1,546
|
java
|
//
// Translated by CS2J (http://www.cs2j.com): 2/15/2016 8:00:26 PM
//
package OpenDental;
import OpenDental.Lan;
/**
*
*/
public class TableZips extends OpenDental.ContrTable
{
private System.ComponentModel.IContainer components = null;
/**
*
*/
public TableZips() throws Exception {
initializeComponent();
MaxRows = 50;
MaxCols = 4;
ShowScroll = true;
FieldsArePresent = true;
HeadingIsPresent = false;
instantClassesPar();
setRowHeight(0,19,14);
Fields[0] = Lan.g("TableZips","ZipCode");
Fields[1] = Lan.g("TableZips","City");
Fields[2] = Lan.g("TableZips","State");
Fields[3] = Lan.g("TableZips","Frequent");
ColWidth[0] = 100;
ColWidth[1] = 200;
ColWidth[2] = 100;
ColWidth[3] = 100;
DefaultGridColor = Color.LightGray;
layoutTables();
}
/**
*
*/
protected void dispose(boolean disposing) throws Exception {
if (disposing)
{
if (components != null)
{
components.Dispose();
}
}
super.dispose(disposing);
}
private void initializeComponent() throws Exception {
//
// TableZips
//
this.Name = "TableZips";
this.Load += new System.EventHandler(this.TableZips_Load);
}
private void tableZips_Load(Object sender, System.EventArgs e) throws Exception {
layoutTables();
}
}
|
[
"leelingco@yahoo.com"
] |
leelingco@yahoo.com
|
1a4ed58b63291036762471b2927ce413d959139f
|
b6bfba71956589aa6f56729ec9ebce824a5fb8f4
|
/src/main/java/org/zhenchao/flyweight/sincere/FidVisitorFlyweight.java
|
c43cf9375be43d39ddd7cb0fef06353ad319abf3
|
[
"Apache-2.0"
] |
permissive
|
plotor/design-pattern
|
5d78d0ef7349a2d637bea5b7270c9557820e5f60
|
4614bab50921b61610693b9b1ed06feddcee9ce6
|
refs/heads/master
| 2022-12-20T17:49:13.396939
| 2020-10-13T14:37:14
| 2020-10-13T14:37:14
| 67,619,122
| 0
| 0
|
Apache-2.0
| 2020-10-13T14:37:15
| 2016-09-07T15:21:45
|
Java
|
UTF-8
|
Java
| false
| false
| 1,001
|
java
|
package org.zhenchao.flyweight.sincere;
import org.apache.commons.lang3.RandomUtils;
/**
* fid类型游客处理器享元
*
* @author zhenchao.wang 2017-04-09 18:26
* @version 1.0.0
*/
public class FidVisitorFlyweight extends VisitorFlyweight {
/** 内部状态:委托处理器 */
private VisitorFlyweight delegateFlyweight;
public FidVisitorFlyweight() {
}
public FidVisitorFlyweight(VisitorFlyweight delegateFlyweight) {
this.delegateFlyweight = delegateFlyweight;
}
@Override
public void createOrRecoverVisitor(String fid) {
System.out.println("Create or recover visitor info by fid : " + fid);
if (null != delegateFlyweight && !this.mockCreateOrRecoverVisitor()) {
// 调用委托处理器处理
delegateFlyweight.createOrRecoverVisitor(fid);
}
}
private boolean mockCreateOrRecoverVisitor() {
// 模拟操作是否成功
return RandomUtils.nextInt(0, 10) > 5;
}
}
|
[
"zhenchao.wang@hotmail.com"
] |
zhenchao.wang@hotmail.com
|
c1d1fccb7d6800f471900494d5acb59974454d4e
|
e82e1c4a539b0b62f126ef331b18f71686051992
|
/serviceImpl/src/main/java/com/cxylk/component/CancelOrderReceiver.java
|
ddf9165c4019a59a9ca3548eabf012290dfb7ef6
|
[
"Apache-2.0"
] |
permissive
|
likuisuper/mod-seckill
|
c6a653c606e1859e0088de4fd9475613b2f7faa8
|
1be25bfbd322386de8891f52521c20a4d48c76b5
|
refs/heads/main
| 2023-06-06T09:37:49.202007
| 2021-06-24T15:02:00
| 2021-06-24T15:02:00
| 332,600,100
| 3
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 1,207
|
java
|
package com.cxylk.component;
import com.cxylk.biz.OrderInfoService;
import com.cxylk.constant.ConstantField;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.amqp.rabbit.annotation.RabbitHandler;
import org.springframework.amqp.rabbit.annotation.RabbitListener;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.messaging.handler.annotation.Payload;
import org.springframework.stereotype.Service;
/**
* @Classname CancelOrderReceiver
* @Description 取消订单消息接收
* @Author likui
* @Date 2021/4/9 17:08
**/
@Service
public class CancelOrderReceiver {
@Autowired
private OrderInfoService orderInfoService;
private static Logger logger = LoggerFactory.getLogger(CancelOrderReceiver.class);
/**
* 1.RabbitListener注解加在类上会无限循环;2.orderId要加上@Payload注解,否则会报错:Payload value must not be empty
* @param orderId
*/
@RabbitListener(queues = ConstantField.ORDER_CANCEL_PLUGIN)
public void handle(@Payload Long orderId){
logger.info("receive delay message orderId:{}",orderId);
orderInfoService.cancelOrder(orderId);
}
}
|
[
"cxylikui@163.com"
] |
cxylikui@163.com
|
1f68671de122175d3968cd8e608b11d7bb80867b
|
1f90b86cb54987c53397d8b57295d291ba512d02
|
/tests/geom/ConnectTest6.java
|
d553f726834af2d97a0486b4db80f7ce8d589a82
|
[
"LicenseRef-scancode-unknown-license-reference",
"LicenseRef-scancode-public-domain"
] |
permissive
|
BillZaumen/libbzdev
|
2bd97fc98b92320f079e4615e0aad700813c0a53
|
948f0a1fa2bdba91d55b2a2f792f3c89679742af
|
refs/heads/master
| 2023-09-01T11:24:14.811257
| 2023-08-25T03:04:17
| 2023-08-25T03:04:17
| 459,379,399
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 3,384
|
java
|
import java.io.FileOutputStream;
import org.bzdev.geom.*;
import org.bzdev.math.VectorOps;
import org.bzdev.math.stats.BasicStats;
import org.bzdev.math.stats.BasicStats.Population;
import org.bzdev.p3d.Model3D;
public class ConnectTest6 {
public static void main(String argv[]) throws Exception {
boolean makeImages = (argv.length > 0 && argv[0].equals("--isq"));
boolean split = (argv.length > 0 && argv[0].equals("--split"));
int N = 41;
int NC = N/2;
Point3D[][] array1 = new Point3D[N][N];
double r = 100.0;
for (int i = 0; i < N; i++) {
for (int j = 0; j < N; j++) {
int k = Math.max(Math.abs(i-NC),Math.abs(j-NC));
double theta = k*(Math.PI/(N-1));
double x, y, z;
if (k == 0) {
x = 0.0; y = 0.0; z = r;
} else {
int nanglesHalf = k*4;
double delta = Math.PI/(nanglesHalf);
double angle;
if (i == NC+k) {
angle = -(NC-j)*delta;
} else if (j == NC-k) {
angle = -(NC + 2*k - i)*delta;
} else if (i == NC-k) {
angle = -((j-NC) + 4*k)*delta;
} else if (j == NC+k) {
angle = (NC+2*k-i)*delta;
} else {
throw new Error();
}
x = r * Math.cos(angle) * Math.sin(theta);
y = r * Math.sin(angle) * Math.sin(theta);
z = r * Math.cos(theta);
}
if (k == NC) z = 0.0;
array1[i][j] = new Point3D.Double(x, y, z);
}
}
// Create the sphere
BezierGrid grid1 = new BezierGrid(array1);
grid1.remove(NC-3, NC-3, 6, 6);
grid1.startSpline(NC-3, NC-3);
grid1.moveU(6);
grid1.moveV(6);
grid1.moveU(-6);
grid1.moveV(-6);
grid1.endSpline(true);
grid1.printSplines();
BezierGrid grid2 = new BezierGrid(grid1, true, (p) -> {
double x = p.getX();
double y = p.getY();
double z = p.getZ();
if (z > 0.0) z = -z;
return new Point3D.Double(x, y, z);
});
Surface3D surface = new Surface3D.Double();
surface.append(grid1);
surface.append(grid2);
System.out.println("creating connections ...");
BezierGrid[] connections = grid1.createConnectionsTo(grid2, 2, split);
System.out.println("... connections created");
for (BezierGrid g: connections) {
surface.append(g);
System.out.format("connection width: %d, closed = %b\n",
g.getVArrayLength(), g.isVClosed());
}
if (!surface.isWellFormed(System.out)) {
System.out.println("surface not well formed");
System.exit(1);
}
connections = grid1.createConnectionsTo(grid2, 2, split, 23, 20);
System.out.println("number of connections for (23, 20) = "
+ connections.length);
Path3D boundary = surface.getBoundary();
if (boundary == null) {
System.out.println("no boundary because not well formed");
System.exit(1);
} else if (boundary.isEmpty()) {
System.out.println("boundary is empty as expected");
} else {
System.out.println("boundary:");
Path3DInfo.printSegments(boundary);
System.exit(1);
}
if (surface.numberOfComponents() != 1) {
System.out.println("number of components for surface = "
+ surface.numberOfComponents());
System.exit(1);
}
Model3D m3d = new Model3D();
m3d.append(surface);
m3d.setTessellationLevel(2);
if (m3d.notPrintable()) {
System.out.println("m3d is not printable");
System.exit(1);
}
if (makeImages) {
m3d.createImageSequence(new FileOutputStream("connection6.isq"),
"png", 8, 6, 0.0, 0.0, 0.0, false);
}
System.exit(0);
}
}
|
[
"bzdev.org@gmail.com"
] |
bzdev.org@gmail.com
|
5a9f838b4ab13f835615b091303fa8af4c20f5c9
|
4365604e3579b526d473c250853548aed38ecb2a
|
/modules/dfp_axis/src/main/java/com/google/api/ads/admanager/axis/v202011/CreativeWrapperStatus.java
|
8f11807a2edf3f2aaf3104af898bbb3f1df48098
|
[
"Apache-2.0"
] |
permissive
|
lmaeda/googleads-java-lib
|
6e73572b94b6dcc46926f72dd4e1a33a895dae61
|
cc5b2fc8ef76082b72f021c11ff9b7e4d9326aca
|
refs/heads/master
| 2023-08-12T19:03:46.808180
| 2021-09-28T16:48:04
| 2021-09-28T16:48:04
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 3,409
|
java
|
// Copyright 2020 Google LLC
//
// 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://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.
/**
* CreativeWrapperStatus.java
*
* This file was auto-generated from WSDL
* by the Apache Axis 1.4 Mar 02, 2009 (07:08:06 PST) WSDL2Java emitter.
*/
package com.google.api.ads.admanager.axis.v202011;
public class CreativeWrapperStatus implements java.io.Serializable {
private java.lang.String _value_;
private static java.util.HashMap _table_ = new java.util.HashMap();
// Constructor
protected CreativeWrapperStatus(java.lang.String value) {
_value_ = value;
_table_.put(_value_,this);
}
public static final java.lang.String _ACTIVE = "ACTIVE";
public static final java.lang.String _INACTIVE = "INACTIVE";
public static final CreativeWrapperStatus ACTIVE = new CreativeWrapperStatus(_ACTIVE);
public static final CreativeWrapperStatus INACTIVE = new CreativeWrapperStatus(_INACTIVE);
public java.lang.String getValue() { return _value_;}
public static CreativeWrapperStatus fromValue(java.lang.String value)
throws java.lang.IllegalArgumentException {
CreativeWrapperStatus enumeration = (CreativeWrapperStatus)
_table_.get(value);
if (enumeration==null) throw new java.lang.IllegalArgumentException();
return enumeration;
}
public static CreativeWrapperStatus fromString(java.lang.String value)
throws java.lang.IllegalArgumentException {
return fromValue(value);
}
public boolean equals(java.lang.Object obj) {return (obj == this);}
public int hashCode() { return toString().hashCode();}
public java.lang.String toString() { return _value_;}
public java.lang.Object readResolve() throws java.io.ObjectStreamException { return fromValue(_value_);}
public static org.apache.axis.encoding.Serializer getSerializer(
java.lang.String mechType,
java.lang.Class _javaType,
javax.xml.namespace.QName _xmlType) {
return
new org.apache.axis.encoding.ser.EnumSerializer(
_javaType, _xmlType);
}
public static org.apache.axis.encoding.Deserializer getDeserializer(
java.lang.String mechType,
java.lang.Class _javaType,
javax.xml.namespace.QName _xmlType) {
return
new org.apache.axis.encoding.ser.EnumDeserializer(
_javaType, _xmlType);
}
// Type metadata
private static org.apache.axis.description.TypeDesc typeDesc =
new org.apache.axis.description.TypeDesc(CreativeWrapperStatus.class);
static {
typeDesc.setXmlType(new javax.xml.namespace.QName("https://www.google.com/apis/ads/publisher/v202011", "CreativeWrapperStatus"));
}
/**
* Return type metadata object
*/
public static org.apache.axis.description.TypeDesc getTypeDesc() {
return typeDesc;
}
}
|
[
"christopherseeley@users.noreply.github.com"
] |
christopherseeley@users.noreply.github.com
|
8469aa8daaae7195bae98cc256580c4fd13abed6
|
74cdd491cdd44806f5daeb2b6923e38d67abe85f
|
/demo/src/main/java/tech/qijin/incubator/demo/ServerApplication.java
|
5011c03bd819f236ba1389dd9e580940475f8ba9
|
[] |
no_license
|
my1free/qijin-tech-incubator
|
4dad7f865f348020ad85a985cd9bcd0d0458f93a
|
584beaa63ced26818d00c9326c19e56c89b12c50
|
refs/heads/master
| 2022-07-12T05:13:09.997585
| 2021-08-06T13:04:38
| 2021-08-06T13:04:38
| 157,062,215
| 0
| 1
| null | 2022-06-21T04:18:18
| 2018-11-11T08:48:37
|
Java
|
UTF-8
|
Java
| false
| false
| 1,973
|
java
|
package tech.qijin.incubator.demo;
import com.alibaba.fastjson.serializer.SerializerFeature;
import com.alibaba.fastjson.support.config.FastJsonConfig;
import com.alibaba.fastjson.support.spring.FastJsonHttpMessageConverter;
import com.github.pagehelper.autoconfigure.PageHelperAutoConfiguration;
import com.google.common.collect.Lists;
import org.mybatis.spring.annotation.MapperScan;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.boot.autoconfigure.http.HttpMessageConverters;
import org.springframework.context.annotation.Bean;
import org.springframework.http.MediaType;
import org.springframework.http.converter.HttpMessageConverter;
import java.nio.charset.Charset;
/**
* author SYSTEM
*/
@SpringBootApplication(exclude = PageHelperAutoConfiguration.class)
public class ServerApplication {
public static void main(String[] args) {
SpringApplication.run(ServerApplication.class, args);
}
//引入Fastjson解析json,不使用默认的jackson
//必须在pom.xml引入fastjson的jar包,并且版必须大于1.2.10
@Bean
public HttpMessageConverters fastJsonHttpMessageConverters() {
//1、定义一个convert转换消息的对象
FastJsonHttpMessageConverter fastConverter = new FastJsonHttpMessageConverter();
//2、添加fastjson的配置信息
FastJsonConfig fastJsonConfig = new FastJsonConfig();
fastJsonConfig.setSerializerFeatures(SerializerFeature.PrettyFormat);
//3、在convert中添加配置信息
fastConverter.setFastJsonConfig(fastJsonConfig);
fastConverter.setSupportedMediaTypes(Lists.newArrayList(
new MediaType("application", "json", Charset.forName("UTF-8"))));
//4、将convert添加到converters中
HttpMessageConverter<?> converter = fastConverter;
return new HttpMessageConverters(converter);
}
}
|
[
"yangshangqiang@inke.cn"
] |
yangshangqiang@inke.cn
|
07d27a0097235a5ed987dbdd683e7152bd573992
|
a3a54e8c694730ea5ae071cc198db50582ca7ab6
|
/学习笔记/Android notes/2.手机卫士项目&只能短信管理(后看)/5.【黑马52】day44_手机安全卫士/code/小火箭/src/com/example/rocket/BackgrounActivity.java
|
242ed2418e08d80d8c953f1875b124c1119fac2f
|
[] |
no_license
|
zhhqiang9198/Giovani-resource
|
3f807c97f231a00b694a1bd8adaa7816aab90af4
|
aa30dcac2af0b34c6f14f55635199a9319ef3685
|
refs/heads/master
| 2021-10-18T17:15:22.759832
| 2019-01-16T10:01:20
| 2019-01-16T10:01:20
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 990
|
java
|
package com.example.rocket;
import android.app.Activity;
import android.os.Bundle;
import android.os.Handler;
import android.view.animation.AlphaAnimation;
import android.widget.ImageView;
/**
* 火箭烟雾背景的activit
*
* @author Administrator
*
*/
public class BackgrounActivity extends Activity {
private ImageView ivTop;
private ImageView ivBottom;
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_backgroun);
ivTop = (ImageView) findViewById(R.id.iv_top);
ivBottom = (ImageView) findViewById(R.id.iv_bottom);
AlphaAnimation anim = new AlphaAnimation(0, 1);
anim.setDuration(1000);
// 动画结束后不变回原样
anim.setFillAfter(true);
// 启动动画
ivTop.startAnimation(anim);
ivBottom.startAnimation(anim);
// 延时1秒关闭activit
new Handler().postDelayed(new Runnable() {
public void run() {
finish();
}
}, 1000);
}
}
|
[
"15219331778@163.com"
] |
15219331778@163.com
|
65cd7f54f64052161d99dc7d5030549e57057c50
|
c885ef92397be9d54b87741f01557f61d3f794f3
|
/results/Cli-31/org.apache.commons.cli.OptionBuilder/BBC-F0-opt-20/tests/30/org/apache/commons/cli/OptionBuilder_ESTest_scaffolding.java
|
d339833cd83eaa51548854df48074bb083941099
|
[
"CC-BY-4.0",
"MIT"
] |
permissive
|
pderakhshanfar/EMSE-BBC-experiment
|
f60ac5f7664dd9a85f755a00a57ec12c7551e8c6
|
fea1a92c2e7ba7080b8529e2052259c9b697bbda
|
refs/heads/main
| 2022-11-25T00:39:58.983828
| 2022-04-12T16:04:26
| 2022-04-12T16:04:26
| 309,335,889
| 0
| 1
| null | 2021-11-05T11:18:43
| 2020-11-02T10:30:38
| null |
UTF-8
|
Java
| false
| false
| 3,373
|
java
|
/**
* Scaffolding file used to store all the setups needed to run
* tests automatically generated by EvoSuite
* Sat Oct 23 13:37:41 GMT 2021
*/
package org.apache.commons.cli;
import org.evosuite.runtime.annotation.EvoSuiteClassExclude;
import org.junit.BeforeClass;
import org.junit.Before;
import org.junit.After;
import org.evosuite.runtime.sandbox.Sandbox;
import org.evosuite.runtime.sandbox.Sandbox.SandboxMode;
@EvoSuiteClassExclude
public class OptionBuilder_ESTest_scaffolding {
@org.junit.Rule
public org.evosuite.runtime.vnet.NonFunctionalRequirementRule nfr = new org.evosuite.runtime.vnet.NonFunctionalRequirementRule();
private org.evosuite.runtime.thread.ThreadStopper threadStopper = new org.evosuite.runtime.thread.ThreadStopper (org.evosuite.runtime.thread.KillSwitchHandler.getInstance(), 3000);
@BeforeClass
public static void initEvoSuiteFramework() {
org.evosuite.runtime.RuntimeSettings.className = "org.apache.commons.cli.OptionBuilder";
org.evosuite.runtime.GuiSupport.initialize();
org.evosuite.runtime.RuntimeSettings.maxNumberOfThreads = 100;
org.evosuite.runtime.RuntimeSettings.maxNumberOfIterationsPerLoop = 10000;
org.evosuite.runtime.RuntimeSettings.mockSystemIn = true;
org.evosuite.runtime.RuntimeSettings.sandboxMode = org.evosuite.runtime.sandbox.Sandbox.SandboxMode.RECOMMENDED;
org.evosuite.runtime.sandbox.Sandbox.initializeSecurityManagerForSUT();
org.evosuite.runtime.classhandling.JDKClassResetter.init();
setSystemProperties();
initializeClasses();
org.evosuite.runtime.Runtime.getInstance().resetRuntime();
}
@Before
public void initTestCase(){
threadStopper.storeCurrentThreads();
threadStopper.startRecordingTime();
org.evosuite.runtime.jvm.ShutdownHookHandler.getInstance().initHandler();
org.evosuite.runtime.sandbox.Sandbox.goingToExecuteSUTCode();
org.evosuite.runtime.GuiSupport.setHeadless();
org.evosuite.runtime.Runtime.getInstance().resetRuntime();
org.evosuite.runtime.agent.InstrumentingAgent.activate();
}
@After
public void doneWithTestCase(){
threadStopper.killAndJoinClientThreads();
org.evosuite.runtime.jvm.ShutdownHookHandler.getInstance().safeExecuteAddedHooks();
org.evosuite.runtime.classhandling.JDKClassResetter.reset();
resetClasses();
org.evosuite.runtime.sandbox.Sandbox.doneWithExecutingSUTCode();
org.evosuite.runtime.agent.InstrumentingAgent.deactivate();
org.evosuite.runtime.GuiSupport.restoreHeadlessMode();
}
public static void setSystemProperties() {
/*No java.lang.System property to set*/
}
private static void initializeClasses() {
org.evosuite.runtime.classhandling.ClassStateSupport.initializeClasses(OptionBuilder_ESTest_scaffolding.class.getClassLoader() ,
"org.apache.commons.cli.OptionBuilder",
"org.apache.commons.cli.OptionValidator",
"org.apache.commons.cli.Option"
);
}
private static void resetClasses() {
org.evosuite.runtime.classhandling.ClassResetter.getInstance().setClassLoader(OptionBuilder_ESTest_scaffolding.class.getClassLoader());
org.evosuite.runtime.classhandling.ClassStateSupport.resetClasses(
"org.apache.commons.cli.OptionBuilder",
"org.apache.commons.cli.Option",
"org.apache.commons.cli.OptionValidator"
);
}
}
|
[
"pderakhshanfar@serg2.ewi.tudelft.nl"
] |
pderakhshanfar@serg2.ewi.tudelft.nl
|
dd71c24d47b71c8158d31801570dad7633ae46ff
|
34f9553f2f0ec7ebb9c3380156fd2182d45f6d52
|
/maply-pdf/src/main/java/com/diamondq/maply/pdf/PDFNodePointer.java
|
516b206244d51d0e30fcfdc6c7daf26ca646b17b
|
[
"Apache-2.0"
] |
permissive
|
diamondq/maply
|
c2b7ba5062fb57b10b9d7f3c4ecc2fb2c379d997
|
21cbe23167848d66ab1914da47f1936cec2bb354
|
refs/heads/master
| 2023-06-01T11:58:06.185386
| 2021-03-06T00:24:00
| 2021-03-06T00:24:00
| 275,422,164
| 0
| 0
|
Apache-2.0
| 2021-06-15T16:06:08
| 2020-06-27T17:34:21
|
Java
|
UTF-8
|
Java
| false
| false
| 2,747
|
java
|
package com.diamondq.maply.pdf;
import org.apache.commons.jxpath.ri.QName;
import org.apache.commons.jxpath.ri.compiler.NodeTest;
import org.apache.commons.jxpath.ri.model.NodeIterator;
import org.apache.commons.jxpath.ri.model.NodePointer;
import org.apache.pdfbox.pdmodel.PDDocument;
import org.checkerframework.checker.nullness.qual.Nullable;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
public class PDFNodePointer extends NodePointer {
private static final long serialVersionUID = -1296008897669489549L;
@SuppressWarnings("unused")
private static final Logger sLogger = LoggerFactory.getLogger(PDFNodePointer.class);
private final PDDocument mDocument;
private final QName mName;
public PDFNodePointer(NodePointer pParent, QName pName, PDFMapObject pMapObject) {
super(pParent);
mName = pName;
mDocument = pMapObject.document;
}
/**
* @see org.apache.commons.jxpath.ri.model.NodePointer#isLeaf()
*/
@Override
public boolean isLeaf() {
return false;
}
/**
* @see org.apache.commons.jxpath.ri.model.NodePointer#isCollection()
*/
@Override
public boolean isCollection() {
return true;
}
/**
* @see org.apache.commons.jxpath.ri.model.NodePointer#getLength()
*/
@Override
public int getLength() {
return 1;
}
/**
* @see org.apache.commons.jxpath.ri.model.NodePointer#getName()
*/
@Override
public @Nullable QName getName() {
return mName;
}
/**
* @see org.apache.commons.jxpath.ri.model.NodePointer#getBaseValue()
*/
@Override
public Object getBaseValue() {
return mDocument;
}
/**
* @see org.apache.commons.jxpath.ri.model.NodePointer#getImmediateNode()
*/
@Override
public Object getImmediateNode() {
return mDocument;
}
/**
* @see org.apache.commons.jxpath.ri.model.NodePointer#setValue(java.lang.Object)
*/
@Override
public void setValue(@Nullable Object pValue) {
throw new UnsupportedOperationException();
}
/**
* @see org.apache.commons.jxpath.ri.model.NodePointer#childIterator(org.apache.commons.jxpath.ri.compiler.NodeTest,
* boolean, org.apache.commons.jxpath.ri.model.NodePointer)
*/
@Override
public NodeIterator childIterator(@Nullable NodeTest pTest, boolean pReverse, @Nullable NodePointer pStartWith) {
throw new UnsupportedOperationException();
}
/**
* @see org.apache.commons.jxpath.ri.model.NodePointer#compareChildNodePointers(org.apache.commons.jxpath.ri.model.NodePointer,
* org.apache.commons.jxpath.ri.model.NodePointer)
*/
@Override
public int compareChildNodePointers(NodePointer pPointer1, NodePointer pPointer2) {
throw new UnsupportedOperationException();
}
}
|
[
"me@michaelmansell.com"
] |
me@michaelmansell.com
|
5173275d319e122f3c92d89bb3eadf52a86cf428
|
3b7f2ec02509c03624366c1ff0a9a1e8a49d1c6b
|
/src/main/java/com/sleepycat/je/rep/impl/RepConfigManager.java
|
faf6b9d4637e593ba8adc44d286439e17f6f1082
|
[
"Apache-2.0",
"BSD-3-Clause",
"LicenseRef-scancode-unknown-license-reference"
] |
permissive
|
andyglick/berkeley-db-java-edition
|
ae09295a6489ea61d23be346fe1676adc13d2b82
|
5b0b4a653a696ff415a388df3cbb0cbf7e85001f
|
refs/heads/master
| 2023-01-30T16:40:31.198418
| 2020-12-09T03:12:15
| 2020-12-09T03:12:15
| 319,814,512
| 0
| 3
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 4,283
|
java
|
/*-
* Copyright (C) 2002, 2018, Oracle and/or its affiliates. All rights reserved.
*
* This file was distributed by Oracle as part of a version of Oracle Berkeley
* DB Java Edition made available at:
*
* http://www.oracle.com/technetwork/database/database-technologies/berkeleydb/downloads/index.html
*
* Please see the LICENSE file included in the top-level directory of the
* appropriate version of Oracle Berkeley DB Java Edition for a copy of the
* license and additional information.
*/
package com.sleepycat.je.rep.impl;
import java.util.Enumeration;
import java.util.Properties;
import com.sleepycat.je.EnvironmentConfig;
import com.sleepycat.je.EnvironmentFailureException;
import com.sleepycat.je.config.ConfigParam;
import com.sleepycat.je.config.EnvironmentParams;
import com.sleepycat.je.dbi.DbConfigManager;
import com.sleepycat.je.dbi.RepConfigProxy;
import com.sleepycat.je.rep.RepInternal;
import com.sleepycat.je.rep.ReplicationConfig;
public class RepConfigManager extends DbConfigManager {
/**
* If the replication configuration object was set with overridden
* validation, we need to continue to override when we generate a new
* configuration.
*/
private final boolean validateParams;
public RepConfigManager(EnvironmentConfig envConfig,
RepConfigProxy repConfigProxy) {
super(envConfig);
checkEnvConfig(envConfig);
ReplicationConfig repConfig = (ReplicationConfig) repConfigProxy;
props.putAll(repConfig.getProps());
repConfig.verify();
this.validateParams = repConfig.getValidateParams();
}
/**
* Verifies that the environment config is suitable for a replicated
* environment.
*
* @param envConfig the environment config being checked.
*
* @throws IllegalArgumentException via ReplicatedEnvironment ctor.
*/
private static void checkEnvConfig(EnvironmentConfig envConfig)
throws IllegalArgumentException {
if (!envConfig.getTransactional()) {
throw new IllegalArgumentException
("A replicated environment must be transactional");
}
String logMemOnly = envConfig.getConfigParam
(EnvironmentParams.LOG_MEMORY_ONLY.getName());
if (Boolean.parseBoolean(logMemOnly)) {
throw new IllegalArgumentException
("A replicated environment must not log to memory");
}
}
/**
* Create a new ReplicationConfig for use in creating Replicator handles.
* Be sure to only pick out replication related properties.
*/
public ReplicationConfig makeReplicationConfig() {
/*
* TODO: the code would be nicer if we replaced the properties bag with
* a class that knows how to iterate over the param values, associating
* the ConfigParam object with it. As a future task, this is similar to
* code in DbConfigManager, and ought to be refactored out. We can also
* strip out the multivalued param support.
*/
Properties repProperties = new Properties();
/* Check that the properties have valid names and values. */
Enumeration<?> propNames = props.propertyNames();
while (propNames.hasMoreElements()) {
String name = (String) propNames.nextElement();
/* Is this a valid property name? */
ConfigParam param =
EnvironmentParams.SUPPORTED_PARAMS.get(name);
if (param == null) {
/* See if the parameter is an multi-value parameter. */
String mvParamName = ConfigParam.multiValueParamName(name);
param = EnvironmentParams.SUPPORTED_PARAMS.get(mvParamName);
if (param == null) {
throw EnvironmentFailureException.unexpectedState
(name +
" is not a valid BDBJE environment configuration");
}
}
if (param.isForReplication()) {
repProperties.setProperty(name, props.getProperty(name));
}
}
return RepInternal.makeReplicationConfig
(repProperties, validateParams);
}
}
|
[
"andyglick@gmail.com"
] |
andyglick@gmail.com
|
fdd35bb9422daff0cb88b65a0e007166e6a5de08
|
8b9190a8c5855d5753eb8ba7003e1db875f5d28f
|
/sources/com/google/zxing/datamatrix/DataMatrixWriter.java
|
d7a720620adb98431dc254052dbf90cfa57ecdf5
|
[] |
no_license
|
stevehav/iowa-caucus-app
|
6aeb7de7487bd800f69cb0b51cc901f79bd4666b
|
e3c7eb39de0be6bbfa8b6b063aaa85dcbcee9044
|
refs/heads/master
| 2020-12-29T10:25:28.354117
| 2020-02-05T23:15:52
| 2020-02-05T23:15:52
| 238,565,283
| 21
| 3
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 5,524
|
java
|
package com.google.zxing.datamatrix;
import com.google.zxing.BarcodeFormat;
import com.google.zxing.Dimension;
import com.google.zxing.EncodeHintType;
import com.google.zxing.Writer;
import com.google.zxing.common.BitMatrix;
import com.google.zxing.datamatrix.encoder.DefaultPlacement;
import com.google.zxing.datamatrix.encoder.ErrorCorrection;
import com.google.zxing.datamatrix.encoder.HighLevelEncoder;
import com.google.zxing.datamatrix.encoder.SymbolInfo;
import com.google.zxing.datamatrix.encoder.SymbolShapeHint;
import com.google.zxing.qrcode.encoder.ByteMatrix;
import java.util.Map;
public final class DataMatrixWriter implements Writer {
public BitMatrix encode(String str, BarcodeFormat barcodeFormat, int i, int i2) {
return encode(str, barcodeFormat, i, i2, (Map<EncodeHintType, ?>) null);
}
public BitMatrix encode(String str, BarcodeFormat barcodeFormat, int i, int i2, Map<EncodeHintType, ?> map) {
Dimension dimension;
if (str.isEmpty()) {
throw new IllegalArgumentException("Found empty contents");
} else if (barcodeFormat != BarcodeFormat.DATA_MATRIX) {
throw new IllegalArgumentException("Can only encode DATA_MATRIX, but got ".concat(String.valueOf(barcodeFormat)));
} else if (i < 0 || i2 < 0) {
throw new IllegalArgumentException("Requested dimensions can't be negative: " + i + 'x' + i2);
} else {
SymbolShapeHint symbolShapeHint = SymbolShapeHint.FORCE_NONE;
Dimension dimension2 = null;
if (map != null) {
SymbolShapeHint symbolShapeHint2 = (SymbolShapeHint) map.get(EncodeHintType.DATA_MATRIX_SHAPE);
if (symbolShapeHint2 != null) {
symbolShapeHint = symbolShapeHint2;
}
dimension = (Dimension) map.get(EncodeHintType.MIN_SIZE);
if (dimension == null) {
dimension = null;
}
Dimension dimension3 = (Dimension) map.get(EncodeHintType.MAX_SIZE);
if (dimension3 != null) {
dimension2 = dimension3;
}
} else {
dimension = null;
}
String encodeHighLevel = HighLevelEncoder.encodeHighLevel(str, symbolShapeHint, dimension, dimension2);
SymbolInfo lookup = SymbolInfo.lookup(encodeHighLevel.length(), symbolShapeHint, dimension, dimension2, true);
DefaultPlacement defaultPlacement = new DefaultPlacement(ErrorCorrection.encodeECC200(encodeHighLevel, lookup), lookup.getSymbolDataWidth(), lookup.getSymbolDataHeight());
defaultPlacement.place();
return encodeLowLevel(defaultPlacement, lookup, i, i2);
}
}
private static BitMatrix encodeLowLevel(DefaultPlacement defaultPlacement, SymbolInfo symbolInfo, int i, int i2) {
int symbolDataWidth = symbolInfo.getSymbolDataWidth();
int symbolDataHeight = symbolInfo.getSymbolDataHeight();
ByteMatrix byteMatrix = new ByteMatrix(symbolInfo.getSymbolWidth(), symbolInfo.getSymbolHeight());
int i3 = 0;
for (int i4 = 0; i4 < symbolDataHeight; i4++) {
if (i4 % symbolInfo.matrixHeight == 0) {
int i5 = 0;
for (int i6 = 0; i6 < symbolInfo.getSymbolWidth(); i6++) {
byteMatrix.set(i5, i3, i6 % 2 == 0);
i5++;
}
i3++;
}
int i7 = 0;
for (int i8 = 0; i8 < symbolDataWidth; i8++) {
if (i8 % symbolInfo.matrixWidth == 0) {
byteMatrix.set(i7, i3, true);
i7++;
}
byteMatrix.set(i7, i3, defaultPlacement.getBit(i8, i4));
i7++;
if (i8 % symbolInfo.matrixWidth == symbolInfo.matrixWidth - 1) {
byteMatrix.set(i7, i3, i4 % 2 == 0);
i7++;
}
}
i3++;
if (i4 % symbolInfo.matrixHeight == symbolInfo.matrixHeight - 1) {
int i9 = 0;
for (int i10 = 0; i10 < symbolInfo.getSymbolWidth(); i10++) {
byteMatrix.set(i9, i3, true);
i9++;
}
i3++;
}
}
return convertByteMatrixToBitMatrix(byteMatrix, i, i2);
}
private static BitMatrix convertByteMatrixToBitMatrix(ByteMatrix byteMatrix, int i, int i2) {
BitMatrix bitMatrix;
int width = byteMatrix.getWidth();
int height = byteMatrix.getHeight();
int max = Math.max(i, width);
int max2 = Math.max(i2, height);
int min = Math.min(max / width, max2 / height);
int i3 = (max - (width * min)) / 2;
int i4 = (max2 - (height * min)) / 2;
if (i2 < height || i < width) {
bitMatrix = new BitMatrix(width, height);
i3 = 0;
i4 = 0;
} else {
bitMatrix = new BitMatrix(i, i2);
}
bitMatrix.clear();
int i5 = 0;
while (i5 < height) {
int i6 = i3;
int i7 = 0;
while (i7 < width) {
if (byteMatrix.get(i7, i5) == 1) {
bitMatrix.setRegion(i6, i4, min, min);
}
i7++;
i6 += min;
}
i5++;
i4 += min;
}
return bitMatrix;
}
}
|
[
"steve@havelka.co"
] |
steve@havelka.co
|
fd2b6aa45a6f92acb11dd45c275ad3e52c93e670
|
0c7ef2792fb579c5be53d77497e7ed26674b4915
|
/gmall-pms/src/main/java/com/atguigu/gmall/pms/controller/SpuCommentController.java
|
6c7841a6beb50e6d7ad0a7abc20ad98f1152e21e
|
[
"Apache-2.0"
] |
permissive
|
lui1798/gmall-0508
|
2f33e07a4da4307be62d8a4bdbb98ea7c0fb6bd8
|
1b58c7f2abc69104d7f11f566df852846a743e31
|
refs/heads/master
| 2022-11-17T22:31:14.777488
| 2019-10-16T07:44:39
| 2019-10-16T07:44:39
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 2,379
|
java
|
package com.atguigu.gmall.pms.controller;
import com.atguigu.core.bean.PageVo;
import com.atguigu.core.bean.QueryCondition;
import com.atguigu.core.bean.Resp;
import com.atguigu.gmall.pms.entity.SpuCommentEntity;
import com.atguigu.gmall.pms.service.SpuCommentService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.security.access.prepost.PreAuthorize;
import org.springframework.web.bind.annotation.*;
import java.util.Arrays;
/**
* 商品评价
*
* @author lixianfeng
* @email lxf@atguigu.com
* @date 2019-09-21 11:05:50
*/
@Api(tags = "商品评价 管理")
@RestController
@RequestMapping("pms/spucomment")
public class SpuCommentController {
@Autowired
private SpuCommentService spuCommentService;
/**
* 列表
*/
@ApiOperation("分页查询(排序)")
@GetMapping("/list")
@PreAuthorize("hasAuthority('pms:spucomment:list')")
public Resp<PageVo> list(QueryCondition queryCondition) {
PageVo page = spuCommentService.queryPage(queryCondition);
return Resp.ok(page);
}
/**
* 信息
*/
@ApiOperation("详情查询")
@GetMapping("/info/{id}")
@PreAuthorize("hasAuthority('pms:spucomment:info')")
public Resp<SpuCommentEntity> info(@PathVariable("id") Long id){
SpuCommentEntity spuComment = spuCommentService.getById(id);
return Resp.ok(spuComment);
}
/**
* 保存
*/
@ApiOperation("保存")
@PostMapping("/save")
@PreAuthorize("hasAuthority('pms:spucomment:save')")
public Resp<Object> save(@RequestBody SpuCommentEntity spuComment){
spuCommentService.save(spuComment);
return Resp.ok(null);
}
/**
* 修改
*/
@ApiOperation("修改")
@PostMapping("/update")
@PreAuthorize("hasAuthority('pms:spucomment:update')")
public Resp<Object> update(@RequestBody SpuCommentEntity spuComment){
spuCommentService.updateById(spuComment);
return Resp.ok(null);
}
/**
* 删除
*/
@ApiOperation("删除")
@PostMapping("/delete")
@PreAuthorize("hasAuthority('pms:spucomment:delete')")
public Resp<Object> delete(@RequestBody Long[] ids){
spuCommentService.removeByIds(Arrays.asList(ids));
return Resp.ok(null);
}
}
|
[
"joedy23@aliyun.com"
] |
joedy23@aliyun.com
|
55fe940cc2eb93deb2c3dac09007a9a537e54ff8
|
c8c689d44b6f8f47f721894d51c544dd024dbbb1
|
/pTest/mj/bts/BtMain.java
|
ccb746d09f007522649a705000e6eb96e8ea7cfd
|
[] |
no_license
|
luoph/mahjongServer
|
e9644bb056b6206403a71f39427b1f5aeed387ae
|
ababf00cd8e61542148c5ca8ee8e8a8b46f3d5e5
|
refs/heads/master
| 2020-08-30T06:20:27.296522
| 2019-01-27T05:12:47
| 2019-01-27T05:12:47
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 1,331
|
java
|
package bts;
import jbt.execution.core.BTExecutorFactory;
import jbt.execution.core.ContextFactory;
import jbt.execution.core.ExecutionTask.Status;
import jbt.execution.core.IBTExecutor;
import jbt.execution.core.IBTLibrary;
import jbt.execution.core.IContext;
import jbt.model.core.ModelTask;
import bts.btlibrary.TerranMarineBTLibrary;
/**
* @author vinceruan qq_404086388
* @Description:
*
*/
public class BtMain {
public static void main(String[] args) throws Exception {
IBTLibrary btLibrary = new TerranMarineBTLibrary();
/* Then we create the initial context that the tree will use. */
IContext context = ContextFactory.createContext(btLibrary);
context.setVariable("userName", "vinceruan");
context.setVariable("password", "123456");
context.setVariable("serverIp", "127.0.0.1");
context.setVariable("serverPort", 5000);
ModelTask terranMarineTree = btLibrary.getBT("Poker");
// /* Then we create the BT Executor to run the tree. */
IBTExecutor btExecutor = BTExecutorFactory.createBTExecutor(terranMarineTree, context);
// /* And finally we run the tree through the BT Executor. */
do {
System.out.println("===============================================");
btExecutor.tick();
Thread.sleep(1000);
} while (btExecutor.getStatus() == Status.RUNNING);
System.exit(0);
}
}
|
[
"fiekajie@163.com"
] |
fiekajie@163.com
|
9d84e57ae189c4179de33a6cf8e2e5e9706d87da
|
76852b1b29410436817bafa34c6dedaedd0786cd
|
/sources-2020-11-04-tempmail/sources/androidx/appcompat/widget/AppCompatPopupWindow.java
|
6b9da1a5a46fbd048b5c39ea140c52ab1fb2b07e
|
[] |
no_license
|
zteeed/tempmail-apks
|
040e64e07beadd8f5e48cd7bea8b47233e99611c
|
19f8da1993c2f783b8847234afb52d94b9d1aa4c
|
refs/heads/master
| 2023-01-09T06:43:40.830942
| 2020-11-04T18:55:05
| 2020-11-04T18:55:05
| 310,075,224
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 1,968
|
java
|
package androidx.appcompat.widget;
import a.a.j;
import android.content.Context;
import android.os.Build;
import android.util.AttributeSet;
import android.view.View;
import android.widget.PopupWindow;
import androidx.core.widget.h;
class AppCompatPopupWindow extends PopupWindow {
/* renamed from: b reason: collision with root package name */
private static final boolean f972b = (Build.VERSION.SDK_INT < 21);
/* renamed from: a reason: collision with root package name */
private boolean f973a;
public AppCompatPopupWindow(Context context, AttributeSet attributeSet, int i) {
super(context, attributeSet, i);
a(context, attributeSet, i, 0);
}
private void a(Context context, AttributeSet attributeSet, int i, int i2) {
b0 u = b0.u(context, attributeSet, j.PopupWindow, i, i2);
if (u.r(j.PopupWindow_overlapAnchor)) {
b(u.a(j.PopupWindow_overlapAnchor, false));
}
setBackgroundDrawable(u.g(j.PopupWindow_android_popupBackground));
u.v();
}
private void b(boolean z) {
if (f972b) {
this.f973a = z;
} else {
h.a(this, z);
}
}
public void showAsDropDown(View view, int i, int i2) {
if (f972b && this.f973a) {
i2 -= view.getHeight();
}
super.showAsDropDown(view, i, i2);
}
public void update(View view, int i, int i2, int i3, int i4) {
if (f972b && this.f973a) {
i2 -= view.getHeight();
}
super.update(view, i, i2, i3, i4);
}
public AppCompatPopupWindow(Context context, AttributeSet attributeSet, int i, int i2) {
super(context, attributeSet, i, i2);
a(context, attributeSet, i, i2);
}
public void showAsDropDown(View view, int i, int i2, int i3) {
if (f972b && this.f973a) {
i2 -= view.getHeight();
}
super.showAsDropDown(view, i, i2, i3);
}
}
|
[
"zteeed@minet.net"
] |
zteeed@minet.net
|
5828cf601dc35ed3b44ca96722e266e544a87b16
|
bed2f1e45e9e6ab7595ee7bd22c9adaed0c5d6db
|
/src/gitTest/holle.java
|
e03c82850d260ec330deb40adef6431cb9e93da4
|
[] |
no_license
|
RoheeXi/TestKu
|
62954aa35b2f96b697749b51b6efc5e77faf8443
|
b8856269139d78f7fc0829d119da84b67f1feb5b
|
refs/heads/master
| 2022-11-10T21:46:04.945164
| 2020-06-28T07:05:22
| 2020-06-28T07:05:22
| 272,867,719
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 342
|
java
|
package gitTest;
public class holle {
public static void main(String[] args) {
System.out.println("master本身代码");
System.out.println("master第一次修改");
System.out.println("hisfix紧急事件处理");
System.out.println("iss53错误修改中");
System.out.println("iss53修改完成");
}
}
|
[
"123456@qq.com"
] |
123456@qq.com
|
f3f720d98642c3cca7729f72389842db1d92409d
|
5014a84424e8be3c57262e53a94c4c67cdc2494b
|
/basicKnowledge/src/com/xdc/basic/api/reflection/annotation/AnnotationTest.java
|
0e94f88dc9defc820cd74bc73bdc5fa6f0b049b8
|
[] |
no_license
|
hustssy/java-code
|
3aea8d0e2b92cf16e9df8eade19cf82960a22053
|
383d283ae811ca16143f3c4fdc4787505c09c871
|
refs/heads/master
| 2021-01-18T05:20:52.156966
| 2014-08-11T15:44:15
| 2014-08-11T15:44:15
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 1,363
|
java
|
package com.xdc.basic.api.reflection.annotation;
import java.lang.reflect.Method;
import java.util.HashSet;
import java.util.Set;
/**
* http://blog.csdn.net/sooneasy/article/details/4384888
*
* @author xdc
*
*/
public class AnnotationTest
{
/**
* author lighter 说明:具体关天Annotation的API的用法请参见javaDoc文档
*/
public static void main(String[] args) throws Exception
{
Class<?> clazz = JavaEyer.class;
Method[] method = clazz.getMethods();
boolean flag = clazz.isAnnotationPresent(Description.class);
if (flag)
{
Description des = clazz.getAnnotation(Description.class);
System.out.println("描述:" + des.value());
System.out.println("-----------------");
}
// 把JavaEyer这一类有利用到@Name的全部方法保存到Set中去
Set<Method> set = new HashSet<Method>();
for (int i = 0; i < method.length; i++)
{
boolean otherFlag = method[i].isAnnotationPresent(Name.class);
if (otherFlag)
set.add(method[i]);
}
for (Method m : set)
{
Name name = m.getAnnotation(Name.class);
System.out.println(name.originate());
System.out.println("创建的社区:" + name.community());
}
}
}
|
[
"xdc0209@qq.com"
] |
xdc0209@qq.com
|
a105758b82b11936ac77fe29752760fd34c71077
|
ca95555a6ce6410807699face40f070f92d41d20
|
/LQian-Learn-Reactor/src/main/java/com/zl/reactor/learn/Part01Flux.java
|
816464951352a10e4fad107762bb083ae2b025df
|
[] |
no_license
|
SaberSola/LQian
|
0000adef39a0940c2771f76e69790643acc6c892
|
b8a42ffe46d37968ecdbf70b402f7b1b09549f55
|
refs/heads/master
| 2022-12-20T23:43:19.657158
| 2021-12-27T13:18:45
| 2021-12-27T13:18:45
| 144,002,792
| 9
| 3
| null | 2022-12-16T04:33:33
| 2018-08-08T11:15:53
|
Java
|
UTF-8
|
Java
| false
| false
| 1,077
|
java
|
package com.zl.reactor.learn;
import reactor.core.publisher.Flux;
import java.time.Duration;
import java.util.Arrays;
public class Part01Flux {
/**
*
* 返回一个空的 Flux
* @return
*/
public Flux<String> emptyFlux (){return null;}
/**
* 返回一个包含俩个Value的 Flux
*
* @return
*/
public Flux<String> fooBarFluxFromValues() {
return Flux.just("foo", "bar");
}
/**
*
* create a Flux form a List that contains tow valuse "foo" and "bar"
* @return
*/
public Flux<String> fooBarFluxFromList(){
return Flux.fromIterable(Arrays.asList("foo","bar"));
}
/**
* create a Flux emits(发出) an IllegalStateException
* @return
*/
public Flux<String> errorFlux(){
return Flux.error(new IllegalStateException());
}
/**
* create a Flux that emits increasing values from 0 to 9 each 100ms
* @return
*/
public Flux<Long> counter() {
return Flux.interval(Duration.ofMillis(100)).take(10);
}
}
|
[
"1198902364@qq.com"
] |
1198902364@qq.com
|
284a704e75803a7aa41c45983eb554785441793c
|
139960e2d7d55e71c15e6a63acb6609e142a2ace
|
/mobile_app1/module293/src/main/java/module293packageJava0/Foo23.java
|
85abff742a5f2732377dcfe702eccba1df55e67d
|
[
"Apache-2.0"
] |
permissive
|
uber-common/android-build-eval
|
448bfe141b6911ad8a99268378c75217d431766f
|
7723bfd0b9b1056892cef1fef02314b435b086f2
|
refs/heads/master
| 2023-02-18T22:25:15.121902
| 2023-02-06T19:35:34
| 2023-02-06T19:35:34
| 294,831,672
| 83
| 7
|
Apache-2.0
| 2021-09-24T08:55:30
| 2020-09-11T23:27:37
|
Java
|
UTF-8
|
Java
| false
| false
| 520
|
java
|
package module293packageJava0;
import java.lang.Integer;
public class Foo23 {
Integer int0;
Integer int1;
Integer int2;
Integer int3;
Integer int4;
public void foo0() {
new module293packageJava0.Foo22().foo7();
}
public void foo1() {
foo0();
}
public void foo2() {
foo1();
}
public void foo3() {
foo2();
}
public void foo4() {
foo3();
}
public void foo5() {
foo4();
}
public void foo6() {
foo5();
}
public void foo7() {
foo6();
}
}
|
[
"oliviern@uber.com"
] |
oliviern@uber.com
|
36d82f37a99cceb4699719732a590c8cfb57fac5
|
bb6f78a899a1a0deada689157668b4cc22d6e8cd
|
/project/AndroidCnblogs/app/src/main/java/com/cnblogs/android/core/FavListHelper.java
|
f8f8503eefdbfdf6b5f1b3f900d42b029a571085
|
[] |
no_license
|
HAIWWH/androidobj
|
1f6c8889c31ef8b69fac90b1283d2a87b34baa6f
|
f77a4993621c188e6bd4efea96fffe87c211b0e0
|
refs/heads/master
| 2021-09-09T22:51:21.718243
| 2018-03-20T03:39:00
| 2018-03-20T03:39:00
| 125,815,460
| 0
| 1
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 2,548
|
java
|
package com.cnblogs.android.core;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;
import android.content.Context;
import com.cnblogs.android.dal.BlogDalHelper;
import com.cnblogs.android.dal.FavDalHelper;
import com.cnblogs.android.entity.FavList;
import com.cnblogs.android.enums.EnumResultType;
/**
* 收藏操作类
* @author walkingp
*
*/
public class FavListHelper {
static FavDalHelper helper;
/**
* 得到实体类
* @param contentId
* @param contentType
* @param context
* @return
*/
public static FavList GetFavEntity(int contentId,FavList.EnumContentType contentType,Context context){
helper=new FavDalHelper(context);
return helper.GetFavEntity(contentId,contentType);
}
/**
* 返回被引用的类
* @param contentId
* @param contentType
* @param context
* @return
*/
public static Object GetFavRefEntity(int contentId,FavList.EnumContentType contentType,Context context){
Object obj=null;
switch(contentType){
case Blog:
default:
obj=new BlogDalHelper(context).GetBlogEntity(contentId);
break;
}
return obj;
}
/**
* 根据页码得到List
* @param pageIndex
* @param pageSize
* @param contentType
* @param context
* @return
*/
public static List<FavList> GetFavListByPage(int pageIndex,FavList.EnumContentType contentType, Context context){
helper=new FavDalHelper(context);
int pageSize=Config.COMMENT_PAGE_SIZE;
List<FavList> list=helper.GetFavListByPage(pageIndex, pageSize, contentType);
return list;
}
/**
* 添加到收藏
* @param contentId
* @param contentType
* @param context
*/
public static EnumResultType.EnumActionResultType AddFav(int contentId,FavList.EnumContentType contentType,Context context){
helper=new FavDalHelper(context);
FavList favList=new FavList();
favList.SetContentId(contentId);
favList.SetContentType(contentType);
Date datetime = new java.util.Date();
favList.SetAddTime(datetime);
List<FavList> listFav=new ArrayList<FavList>();
listFav.add(favList);
return helper.SynchronyData2DB(listFav);
}
/**
* 移除收藏
* @param favId
* @param context
*/
public static boolean RemoveFav(int favId,Context context){
helper=new FavDalHelper(context);
return helper.Delete(favId);
}
/**
* 移除收藏
* @param favId
* @param context
*/
public static boolean RemoveFav(int contentId,FavList.EnumContentType contentType,Context context){
helper=new FavDalHelper(context);
return helper.Delete(contentId,contentType);
}
}
|
[
"1455166220@qq.com"
] |
1455166220@qq.com
|
90fb3d767ae1d3e0b11c5ac294ef164b1b21381a
|
704507754a9e7f300dfab163e97cd976b677661b
|
/src/com/sun/org/apache/bcel/internal/generic/AllocationInstruction.java
|
671a7623a9aac7ba7ff6fe110928b5d8b82671d9
|
[] |
no_license
|
ossaw/jdk
|
60e7ca5e9f64541d07933af25c332e806e914d2a
|
b9d61d6ade341b4340afb535b499c09a8be0cfc8
|
refs/heads/master
| 2020-03-27T02:23:14.010857
| 2019-08-07T06:32:34
| 2019-08-07T06:32:34
| 145,785,700
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 2,980
|
java
|
/*
* Copyright (c) 2007, 2017, Oracle and/or its affiliates. All rights reserved.
* ORACLE PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
*/
package com.sun.org.apache.bcel.internal.generic;
/*
* ====================================================================
* The Apache Software License, Version 1.1
* Copyright (c) 2001 The Apache Software Foundation. All rights
* reserved.
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
* 2. Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in
* the documentation and/or other materials provided with the
* distribution.
* 3. The end-user documentation included with the redistribution,
* if any, must include the following acknowledgment:
* "This product includes software developed by the
* Apache Software Foundation (http://www.apache.org/)."
* Alternately, this acknowledgment may appear in the software itself,
* if and wherever such third-party acknowledgments normally appear.
* 4. The names "Apache" and "Apache Software Foundation" and
* "Apache BCEL" must not be used to endorse or promote products
* derived from this software without prior written permission. For
* written permission, please contact apache@apache.org.
* 5. Products derived from this software may not be called "Apache",
* "Apache BCEL", nor may "Apache" appear in their name, without
* prior written permission of the Apache Software Foundation.
* THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
* OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
* ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
* LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
* USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
* ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
* OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
* OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
* ====================================================================
* This software consists of voluntary contributions made by many
* individuals on behalf of the Apache Software Foundation. For more
* information on the Apache Software Foundation, please see
* <http://www.apache.org/>.
*/
/**
* Denote family of instructions that allocates space in the heap.
*
* @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
*/
public interface AllocationInstruction {}
|
[
"jianghao7625@gmail.com"
] |
jianghao7625@gmail.com
|
4acbd242a2a5c4a034fdb04184cbd5c8b637d289
|
8b5295d2383d70b8338b749cc264b34c10e84d43
|
/src/main/java/gigaherz/elementsofpower/spells/effects/SpellEffect.java
|
8ad5ad71dfc7113c43df6c534473ab56e7ed73f9
|
[] |
no_license
|
mortie/ElementsOfPower
|
177b646653789e0cbc54e9e11e0772a97c453b0e
|
0134b3445e54a5c2a17ef15a4a39726826910c16
|
refs/heads/master
| 2021-01-12T20:26:12.868589
| 2016-07-29T22:36:49
| 2016-07-29T22:36:49
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 1,766
|
java
|
package gigaherz.elementsofpower.spells.effects;
import gigaherz.elementsofpower.spells.Spellcast;
import net.minecraft.block.state.IBlockState;
import net.minecraft.entity.Entity;
import net.minecraft.entity.EntityLivingBase;
import net.minecraft.potion.Potion;
import net.minecraft.potion.PotionEffect;
import net.minecraft.util.math.BlockPos;
import net.minecraft.util.math.RayTraceResult;
import net.minecraft.util.math.Vec3d;
import javax.annotation.Nullable;
public abstract class SpellEffect
{
public abstract int getColor(Spellcast cast);
public abstract int getDuration(Spellcast cast);
public abstract int getInterval(Spellcast cast);
public int getForceModifier(Spellcast cast)
{
return 0;
}
public abstract void processDirectHit(Spellcast cast, Entity entity, Vec3d hitVec);
public abstract boolean processEntitiesAroundBefore(Spellcast cast, Vec3d hitVec);
public abstract void processEntitiesAroundAfter(Spellcast cast, Vec3d hitVec);
public abstract void spawnBallParticles(Spellcast cast, RayTraceResult mop);
public abstract void processBlockWithinRadius(Spellcast cast, BlockPos blockPos, IBlockState currentState, float distance, @Nullable RayTraceResult mop);
protected static void causePotionEffect(Spellcast cast, EntityLivingBase e, Potion potion, int amplifier, double distance, double durationBase)
{
if (potion.isInstant())
{
potion.affectEntity(cast.projectile, cast.player, e, amplifier, distance);
}
else
{
int j = (int) (distance * durationBase + 0.5D);
if (j > 20)
{
e.addPotionEffect(new PotionEffect(potion, j, amplifier));
}
}
}
}
|
[
"gigaherz@gmail.com"
] |
gigaherz@gmail.com
|
9b6e746c7fc73bd84445b9eed663c72638c291c5
|
9bc31f50a3519a1410629804a4d174734694afc2
|
/src/com/richie/caipiao/vo/CaipiaoComparator.java
|
51edd9ac6c5f272be4f8e1f4a0bcd7989c8186a5
|
[] |
no_license
|
richiewang/caipiao
|
e25a0cd046842a7f2c6473f450e6d7a3c450fadf
|
e20ab96ef223b72642db8801b298f440574e7fb7
|
refs/heads/master
| 2020-12-30T19:11:36.097472
| 2013-05-21T10:57:51
| 2013-05-21T10:57:51
| null | 0
| 0
| null | null | null | null |
GB18030
|
Java
| false
| false
| 427
|
java
|
package com.richie.caipiao.vo;
import java.util.Comparator;
public class CaipiaoComparator implements Comparator {
@Override
public int compare(Object o1, Object o2) {
ReportVo vo0 = (ReportVo) o1;
ReportVo vo1 = (ReportVo) o2;
// 首先比较年龄,如果年龄相同,则比较名字
if (vo0.getCaipiaoNo().compareTo(vo1.getCaipiaoNo())<0) {
return -1;
} else {
return 1;
}
}
}
|
[
"elfkingw@gmail.com"
] |
elfkingw@gmail.com
|
6096e4a26f5ded5b6b0117f29f2a241ca2aabe91
|
4ae0b0946427d9c8bf964560a5086a84be901492
|
/jcincms_base/syst3_module/src/main/java/com/jcin/cms/modules/pro/service/IOrderService.java
|
d2e6590a670b8df46c02ae68bfb823ac4c5cae40
|
[] |
no_license
|
huangjixin/MyBingya
|
efeb96a57c027365f7ea5b514efa888bfb234468
|
8833443ec35f90ca65a6ae49e99a4ceb04959efe
|
refs/heads/master
| 2020-04-06T07:05:15.983855
| 2016-06-23T04:03:28
| 2016-06-23T04:03:28
| 11,780,797
| 0
| 1
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 660
|
java
|
package com.jcin.cms.modules.pro.service;
import java.util.List;
import com.jcin.cms.modules.pro.domain.Order;
import com.jcin.cms.modules.pro.domain.OrderCriteria;
import com.jcin.cms.modules.pro.service.IOrderService;
import com.jcin.cms.service.IBaseService;
import com.jcin.cms.utils.Page;
public interface IOrderService extends IBaseService<Order, String> {
/**
* 封装查询条件,返回Page对象。
* @param criteria
* @return
*/
Page select(OrderCriteria criteria);
/**
* 根据查询条件进行查询
* @param dictionaryCriteria
* @return
*/
List<Order> selectByExample(OrderCriteria criteria);
}
|
[
"635152644@qq.com"
] |
635152644@qq.com
|
f2dccba827a8f3e2aeb7a9bd2a744bcac1fca8fa
|
83148140a1bf76077a7e9f71d424b5108edfc453
|
/QuickestPhoneBooster/app/src/main/java/utility/quickest/phonebooster/model_helper/fz.java
|
341b9a6dfb4df8cf5bb5bbbcc4f355eb49ddc9ed
|
[] |
no_license
|
kotdark/clone_phone_booster
|
adcf593aae69cd5dc3b070bf8072c6a1006ba58d
|
8b6d84055739b1269ce64e1d59c7f4bc0adbcd88
|
refs/heads/master
| 2020-03-17T13:24:03.837851
| 2018-05-18T07:10:44
| 2018-05-18T07:10:44
| 133,630,146
| 1
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 2,812
|
java
|
package utility.quickest.phonebooster.model_helper;
import android.os.SystemClock;
import utility.quickest.phonebooster.p114d.C2445c;
import utility.quickest.phonebooster.p114d.C2451i;
import utility.quickest.phonebooster.util.C2541l;
import utility.quickest.phonebooster.util.ThreadUtil;
import java.util.List;
/* compiled from: DeepJunkHelper */
class fz implements Runnable {
final /* synthetic */ List f14248a;
final /* synthetic */ long f14249b;
final /* synthetic */ long f14250c;
final /* synthetic */ fw f14251d;
fz(fw fwVar, List list, long j, long j2) {
this.f14251d = fwVar;
this.f14248a = list;
this.f14249b = j;
this.f14250c = j2;
}
public void run() {
Throwable th;
try {
long j;
long j2;
if (this.f14248a.isEmpty()) {
j = 0;
} else {
if (this.f14249b < 0) {
j2 = 0;
} else {
j2 = this.f14249b;
}
j = Math.max(j2 / ((long) this.f14248a.size()), this.f14250c);
}
long[] jArr = new long[]{0};
int i = 0;
for (C2445c c2445c : this.f14248a) {
int i2;
int i3 = i + 1;
long elapsedRealtime = SystemClock.elapsedRealtime();
i = (int) ((((float) i3) * 100.0f) / ((float) this.f14248a.size()));
if (i < 0) {
i2 = 0;
} else if (i > 100) {
i2 = 100;
} else {
i2 = i;
}
for (C2451i c2451i : c2445c.m17625b()) {
C2541l.m19070b(c2451i.m17675a());
ThreadUtil.m19099a(false, new ga(this, c2445c, c2451i));
long elapsedRealtime2 = SystemClock.elapsedRealtime();
if (elapsedRealtime2 - jArr[0] >= 100) {
jArr[0] = elapsedRealtime2;
ThreadUtil.m19099a(false, new gb(this, c2451i, i2));
}
}
ThreadUtil.m19099a(false, new gc(this, c2445c));
j2 = SystemClock.elapsedRealtime() - elapsedRealtime;
if (j2 < 0) {
j2 = 0;
}
if (j2 < j) {
try {
Thread.sleep(j - j2);
} catch (Throwable th2) {
}
}
i = i3;
}
th = null;
} catch (Throwable th3) {
th = th3;
}
ThreadUtil.m19099a(false, new gd(this));
if (th != null) {
throw new RuntimeException(th);
}
}
}
|
[
"tranduyvn91@gmail.com"
] |
tranduyvn91@gmail.com
|
58eb454647e8259a20b5d722c000d23a998b8a72
|
1114250b3dfea6494fcfc0e79894f79c5bedb23e
|
/src/integrationTest/java/uk/co/mruoc/promo/repository/mongo/LocalDockerMongo.java
|
4eda9fc8155c35d6b15d6c394de345cf9f070527
|
[
"MIT"
] |
permissive
|
michaelruocco/burger-promo
|
a6b4bd556f818e9c8970a46e4812bd5bcf958e65
|
77b1936082db302cf4debf2d3a650449aca166ea
|
refs/heads/master
| 2023-05-29T21:12:35.856807
| 2021-06-20T08:27:45
| 2021-06-20T08:27:45
| 373,911,017
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 2,644
|
java
|
package uk.co.mruoc.promo.repository.mongo;
import com.mongodb.ConnectionString;
import com.mongodb.MongoClientSettings;
import com.mongodb.client.MongoClients;
import com.mongodb.client.MongoDatabase;
import lombok.extern.slf4j.Slf4j;
import org.bson.codecs.configuration.CodecRegistry;
import org.testcontainers.containers.GenericContainer;
import org.testcontainers.containers.output.OutputFrame;
import java.time.Duration;
import java.util.concurrent.Callable;
import static org.awaitility.Awaitility.await;
import static org.testcontainers.utility.MountableFile.forHostPath;
@Slf4j
public class LocalDockerMongo extends GenericContainer<LocalDockerMongo> {
private static final String USERNAME = "promo-user";
private static final String PASSWORD = "welcome01";
private static final String DATABASE = "promo-local";
private static final int PORT = 27017;
public LocalDockerMongo() {
super("mongo");
withEnv("MONGO_INITDB_ROOT_USERNAME", USERNAME);
withEnv("MONGO_INITDB_ROOT_PASSWORD", PASSWORD);
withEnv("MONGO_INITDB_DATABASE", DATABASE);
withCopyFileToContainer(forHostPath("mongo/mongo-init.js"), "/docker-entrypoint-initdb.d/mongo-init.js");
withExposedPorts(PORT);
withLogConsumer(this::logInfo);
}
public MongoDatabase getDatabase(CodecRegistry codecRegistry) {
log.info("waiting for mongo to start...");
waitForStartupToComplete();
log.info("mongo startup complete");
var settings = MongoClientSettings.builder()
.applyConnectionString(getConnectionString())
.codecRegistry(codecRegistry)
.build();
var client = MongoClients.create(settings);
return client.getDatabase(DATABASE);
}
private void waitForStartupToComplete() {
await().atMost(Duration.ofSeconds(150))
.pollDelay(Duration.ofSeconds(120))
.pollInterval(Duration.ofMillis(500))
.until(containerIsRunning());
}
private ConnectionString getConnectionString() {
String ip = getContainerIpAddress();
int port = getMappedPort(PORT);
return new ConnectionString(String.format("mongodb://%s:%s@%s:%d/%s", USERNAME, PASSWORD, ip, port, DATABASE));
}
private void logInfo(OutputFrame frame) {
log.info(frame.getUtf8String());
}
private Callable<Boolean> containerIsRunning() {
return () -> {
boolean running = this.isRunning();
log.info("checking mongo container is running {}", running);
return running;
};
}
}
|
[
"michael.ruocco@hotmail.com"
] |
michael.ruocco@hotmail.com
|
f9db1d5bfa23387a26788c4ea867d21c517af704
|
7634ba9faef3726e8fcdf68e5579831387cb9921
|
/virtdata-lib-basics/src/test/java/io/virtdata/basicsmappers/ExprTest.java
|
e0eca68590e98f9fd4624fe96c3679c5ff12bcb1
|
[
"Apache-2.0"
] |
permissive
|
jeromatron/virtdata-java
|
7ccc7f581233624af78c68e5d74dff2a76cc5a26
|
7f2b56ea5cd61328a20b8d65f39cd9d5c4fc2b5f
|
refs/heads/master
| 2020-04-02T11:41:59.733111
| 2018-10-24T14:05:54
| 2018-10-24T14:05:54
| 154,402,350
| 0
| 0
|
Apache-2.0
| 2018-10-23T22:01:37
| 2018-10-23T22:01:37
| null |
UTF-8
|
Java
| false
| false
| 2,269
|
java
|
package io.virtdata.basicsmappers;
import org.assertj.core.data.Offset;
import org.testng.annotations.Test;
import static org.assertj.core.api.Assertions.assertThat;
@Test
public class ExprTest {
@Test
public void testLongUnaryExpr() {
io.virtdata.basicsmappers.from_long.to_long.Expr mod5 =
new io.virtdata.basicsmappers.from_long.to_long.Expr("cycle % 5");
long three = mod5.applyAsLong(23);
assertThat(three).isEqualTo(3);
}
@Test
public void testDoubleUnaryExpr() {
io.virtdata.basicsmappers.from_double.to_double.Expr plus3point5 =
new io.virtdata.basicsmappers.from_double.to_double.Expr("cycle + 3.5");
double r = plus3point5.applyAsDouble(32.5);
assertThat(r).isCloseTo(36.0, Offset.offset(0.001d));
}
@Test
public void testLongToIntExpr() {
io.virtdata.basicsmappers.from_long.to_int.Expr minus7 =
new io.virtdata.basicsmappers.from_long.to_int.Expr("cycle - 7");
int r = minus7.applyAsInt(234233);
assertThat(r).isEqualTo(234226);
}
@Test
public void testUnaryIntExpr() {
io.virtdata.basicsmappers.unary_int.Expr times2 =
new io.virtdata.basicsmappers.unary_int.Expr("cycle * 2");
int fourtytwo = times2.applyAsInt(21);
assertThat(fourtytwo).isEqualTo(42);
}
@Test
public void testLongExprSpeed() {
//Expr mod5 = new Expr("(cycle / 10)*10 + (cycle % 5)");
io.virtdata.basicsmappers.from_long.to_long.Expr mod5 =
new io.virtdata.basicsmappers.from_long.to_long.Expr("(cycle / 10)*10 + (cycle % 5)");
long three = mod5.applyAsLong(23);
long start = System.nanoTime();
int min=0;
int max=1000000;
for (int i = min; i < max; i++) {
long l = mod5.applyAsLong(i);
//System.out.format("input=%d output=%d\n", i, l);
//assertThat(l).isEqualTo((i%5));
}
long end = System.nanoTime();
long duration = end-start;
double nsperop = (double) duration / (double) (max-min);
System.out.format("(ops/time)=(%d/%dns) rate=%.3f\n", (max-min), duration, ((double) max-min)*1000000000.0/duration);
}
}
|
[
"jshook@gmail.com"
] |
jshook@gmail.com
|
e4da203057b80a2954c865f286c1fec15d63ed76
|
42ead7782f5624a1df7bc10260f095e1e5fe4745
|
/app/src/main/java/com/example/dell/dkcwallet/fragment/TransferFragment.java
|
7c1f3997c5a9c0f41916c71c392841e7703c043a
|
[] |
no_license
|
duanchaozhong/DKCWallet
|
4db351b9409879b2bd27026cf68fd66914f55ebc
|
14a33182f0d489156a7f151065ee0edee955cdf9
|
refs/heads/master
| 2021-04-12T04:47:28.379530
| 2018-05-18T02:57:56
| 2018-05-18T02:57:56
| 125,952,120
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 2,325
|
java
|
package com.example.dell.dkcwallet.fragment;
import android.Manifest;
import android.content.Intent;
import android.view.View;
import android.widget.TextView;
import com.example.dell.dkcwallet.R;
import com.example.dell.dkcwallet.activity.ReceivablesAct;
import com.example.dell.dkcwallet.base.BaseFragment;
import com.example.dell.dkcwallet.helper.UserHelper;
import butterknife.InjectView;
import butterknife.OnClick;
/**
* Created by DELL on 2017/8/8.
*/
public class TransferFragment extends BaseFragment{
@InjectView(R.id.title_name)
TextView titleName;
private String[] perimissionCheck = new String[]{
Manifest.permission.VIBRATE, Manifest.permission.CAMERA
};
public static TransferFragment newInstance() {
TransferFragment fragment = new TransferFragment();
return fragment;
}
@Override
protected void initView() {
titleName.setText(R.string.transfer);
}
@Override
protected void lazyLoad() {
}
@Override
protected int setLayoutResouceId() {
return R.layout.fragment_transfer;
}
@OnClick({R.id.receivables_relative, R.id.qr_code_relative})
public void onViewClicked(View view) {
switch (view.getId()) {
case R.id.receivables_relative:
startActivity(new Intent(getActivity(), ReceivablesAct.class));
break;
case R.id.qr_code_relative:
// if (EasyPermissions.hasPermissions(getActivity(), perimissionCheck)) {//检查是否获取该权限
// startActivity(new Intent(getActivity(), CaptureActivity.class));
// } else {
// EasyPermissions.requestPermissions(getActivity(), getString(R.string.necessary_permisson), 0, perimissionCheck);
// }
/*PermissionHelper.get(mActivity, perimissionCheck)
.subscribe(new Consumer<Boolean>() {
@Override
public void accept(@NonNull Boolean aBoolean) throws Exception {
startActivity(new Intent(mActivity, CaptureActivity.class));
}
});*/
UserHelper.toCapture(mActivity);
break;
}
}
}
|
[
"857999639@qq.com"
] |
857999639@qq.com
|
a23892d566a1e24904e286d4cb01aa5faf0fb7a5
|
fa91450deb625cda070e82d5c31770be5ca1dec6
|
/Diff-Raw-Data/15/15_aed1f9d6496b2a746d497132e058305128322c65/ColorPanel/15_aed1f9d6496b2a746d497132e058305128322c65_ColorPanel_t.java
|
873f986789a96ebd4f950cf922779064402f5af9
|
[] |
no_license
|
zhongxingyu/Seer
|
48e7e5197624d7afa94d23f849f8ea2075bcaec0
|
c11a3109fdfca9be337e509ecb2c085b60076213
|
refs/heads/master
| 2023-07-06T12:48:55.516692
| 2023-06-22T07:55:56
| 2023-06-22T07:55:56
| 259,613,157
| 6
| 2
| null | 2023-06-22T07:55:57
| 2020-04-28T11:07:49
| null |
UTF-8
|
Java
| false
| false
| 6,816
|
java
|
package org.newdawn.slick.tools.peditor;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
import javax.swing.BorderFactory;
import javax.swing.BoxLayout;
import javax.swing.ButtonGroup;
import javax.swing.JCheckBox;
import javax.swing.JPanel;
import javax.swing.JRadioButton;
import org.newdawn.slick.Color;
import org.newdawn.slick.particles.ConfigurableEmitter;
import org.newdawn.slick.particles.Particle;
import org.newdawn.slick.particles.ConfigurableEmitter.ColorRecord;
/**
* A panel allowing the configuration of the colour and alpha values of the
* particles.
*
* @author kevin
*/
public class ColorPanel extends ControlPanel {
/** The editor used to define the change in color */
private GradientEditor grad;
/** True if we should ignore update events */
private boolean blockUpdates = false;
/** The selection for inherit the rendering settings */
private JRadioButton inherit;
/** The selection for using quads */
private JRadioButton quads;
/** The selection for using points */
private JRadioButton points;
/** The selection for using oriented quads */
private JCheckBox oriented;
/** The selection for additive blend mode */
private JCheckBox additive;
/** The panel displaying the starting alpha value */
private ValuePanel startAlpha;
/** The panel displayint the ending alpha value */
private ValuePanel endAlpha;
/**
* Create a new panel to allow particle colour configuration
*/
public ColorPanel() {
grad = new GradientEditor();
grad.setBorder(BorderFactory.createTitledBorder("Color Change"));
grad.setBounds(0,0,280,100);
add(grad);
grad.addActionListener(new ActionListener() {
public void actionPerformed(ActionEvent e) {
updateColors();
}
});
yPos+=70;
startAlpha= new ValuePanel("Starting Alpha",0,255,255,"The alpha value for particles at their birth",false);
addValue("startAlpha", startAlpha );
endAlpha= new ValuePanel("Ending Alpha",0,255,0,"The alpha value for particles at their death",false);
addValue("endAlpha", endAlpha );
// rendering panel
JPanel renderingPrimitivePanel = new DefaultPanel();
renderingPrimitivePanel.setLayout(new BoxLayout( renderingPrimitivePanel, BoxLayout.X_AXIS ));
inherit = new JRadioButton("Inherit");
quads = new JRadioButton("Quads");
points = new JRadioButton("Points");
ButtonGroup group = new ButtonGroup();
group.add(inherit);
group.add(quads);
group.add(points);
ActionListener al = new ActionListener() {
public void actionPerformed(ActionEvent e) {
updateRender();
}
};
inherit.addActionListener(al);
inherit.setOpaque(false);
inherit.setSelected(true);
renderingPrimitivePanel.add(inherit);
quads.addActionListener(al);
quads.setOpaque(false);
renderingPrimitivePanel.add(quads);
points.addActionListener(al);
points.setOpaque(false);
renderingPrimitivePanel.add(points);
renderingPrimitivePanel.setBounds(0,yPos+15,280,45);
add(renderingPrimitivePanel);
yPos+=35;
// rendering type panel
JPanel renderingTypePanel = new DefaultPanel();
renderingTypePanel.setLayout(new BoxLayout( renderingTypePanel, BoxLayout.X_AXIS ));
oriented = new JCheckBox("Oriented Quad");
oriented.addActionListener(al);
oriented.setOpaque(false);
renderingTypePanel.add( oriented );
additive = new JCheckBox("Additive Blending");
additive.addActionListener(al);
additive.setOpaque(false);
renderingTypePanel.add( additive );
renderingTypePanel.setBounds(0,yPos+15,230,45);
add(renderingTypePanel);
yPos+=35;
}
/**
* Update the render setting
*/
private void updateRender() {
if (inherit.isSelected())
{
emitter.usePoints = Particle.INHERIT_POINTS;
oriented.setEnabled( true );
}
if (quads.isSelected())
{
emitter.usePoints = Particle.USE_QUADS;
oriented.setEnabled( true );
}
if (points.isSelected())
{
emitter.usePoints = Particle.USE_POINTS;
oriented.setEnabled( false );
oriented.setSelected( false );
}
// oriented
if( oriented.isSelected())
emitter.useOriented= true;
else
emitter.useOriented= false;
// additive blending
if( additive.isSelected())
emitter.useAdditive= true;
else
emitter.useAdditive= false;
}
/**
* Update the state of the emitter based on colours in the editor
*/
private void updateColors() {
if (blockUpdates) {
return;
}
emitter.colors.clear();
for (int i=0;i<grad.getControlPointCount();i++) {
float pos = grad.getPointPos(i);
java.awt.Color col = grad.getColor(i);
Color slick = new Color(col.getRed() / 255.0f, col.getGreen() / 255.0f, col.getBlue() / 255.0f, 1.0f);
emitter.addColorPoint(pos, slick);
}
}
/**
* @see org.newdawn.slick.tools.peditor.ControlPanel#linkEmitterToFields(org.newdawn.slick.particles.ConfigurableEmitter)
*/
protected void linkEmitterToFields(ConfigurableEmitter emitter) {
blockUpdates = true;
link(emitter.startAlpha, "startAlpha");
link(emitter.endAlpha, "endAlpha");
grad.clearPoints();
Color start = ((ColorRecord) emitter.colors.get(0)).col;
Color end = ((ColorRecord) emitter.colors.get(emitter.colors.size()-1)).col;
grad.setStart(new java.awt.Color(start.r,start.g,start.b,1.0f));
grad.setEnd(new java.awt.Color(end.r,end.g,end.b,1.0f));
for (int i=1;i<emitter.colors.size()-1;i++) {
float pos = ((ColorRecord) emitter.colors.get(i)).pos;
Color col = ((ColorRecord) emitter.colors.get(i)).col;
grad.addPoint(pos, new java.awt.Color(col.r,col.g,col.b,1.0f));
}
blockUpdates = false;
if (emitter.usePoints == Particle.INHERIT_POINTS) {
inherit.setSelected(true);
}
if (emitter.usePoints == Particle.USE_POINTS) {
points.setSelected(true);
}
if (emitter.usePoints == Particle.USE_QUADS) {
quads.setSelected(true);
}
oriented.setSelected( emitter.useOriented );
additive.setSelected( emitter.useAdditive );
}
/**
* Get the panel controlling the alpha value of particles at the
* end of their life
*
* @return The panel controlling the alpha value
*/
public ValuePanel getEndAlpha() {
return endAlpha;
}
/**
* Get the panel controlling the alpha value of particles at the
* start of their life
*
* @return The panel controlling the alpha value
*/
public ValuePanel getStartAlpha() {
return startAlpha;
}
}
|
[
"yuzhongxing88@gmail.com"
] |
yuzhongxing88@gmail.com
|
852d4836ed26ac4553cb8f606dff04db2c53f6c8
|
fce7410ed7cdfa279f2963b63edff8d5faab295a
|
/DynamicFragrentsAssignment/app/src/main/java/com/example/ujjwalsmahapatra/dynamicfragrentsassignment/MainActivity.java
|
7cbc2860f7e5ee12a019ca61fe2f3a0209b8736e
|
[] |
no_license
|
usmahapatra/First-Android-Apps
|
f3f4d163fffbdfa157e9f70e4264a5f73444063d
|
0c91cb43a95a2cdd8f02846b82a50c288dcca8f0
|
refs/heads/master
| 2020-03-11T23:28:41.251337
| 2019-05-08T12:37:44
| 2019-05-08T12:37:44
| 130,322,712
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 1,537
|
java
|
package com.example.ujjwalsmahapatra.dynamicfragrentsassignment;
import android.support.v4.app.FragmentManager;
import android.support.v4.app.FragmentTransaction;
import android.support.v7.app.AppCompatActivity;
import android.os.Bundle;
import android.view.View;
import android.widget.Button;
import android.widget.EditText;
import android.widget.TextView;
public class MainActivity extends AppCompatActivity {
EditText editText;
Button button;
TextView textView;
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main);
editText=(EditText)findViewById(R.id.editText1);
textView=(TextView)findViewById(R.id.textView1);
button=(Button)findViewById(R.id.button1);
button.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View view) {
FragmentManager mgr=getSupportFragmentManager();
final FragmentTransaction trans=mgr.beginTransaction();
final FragmentOne f1=new FragmentOne();
trans.add(R.id.container1,f1);
String name=editText.getText().toString();
Bundle bn= new Bundle();
bn.putString("name","Name: "+name);
f1.setArguments(bn);
trans.commit();
}
});
}
public void receive(String qualification)
{
textView.setText(qualification);
}
}
|
[
"usmahapatra@gmail.com"
] |
usmahapatra@gmail.com
|
c6a1509f3b19f03f70de35a4fdaa0f2b71fde4ae
|
dab1c92d50242301da831d5a803a1a8bdbf9738c
|
/legendshop_util/src/java/com/legendshop/plugins/PluginClassLoader.java
|
e8ecadac7f5de74809639b5b39d3489abee33ca9
|
[
"Apache-2.0"
] |
permissive
|
js-superion/gomall.la
|
6dda41aca73a10d5d581cc40779eb2c4bdcb36ea
|
456ba07ee53a07ed5c472fd1d29b8994807f673f
|
refs/heads/master
| 2021-01-21T10:04:46.895300
| 2015-12-24T15:17:33
| 2015-12-24T15:17:33
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 595
|
java
|
/*
*
* LegendShop 多用户商城系统
*
* 版权所有,并保留所有权利。
*
*/
package com.legendshop.plugins;
import java.net.URL;
import java.net.URLClassLoader;
/**
* The Class PluginClassLoader.
*/
public class PluginClassLoader extends URLClassLoader {
/**
* Construtor.
*
* @param urls
* Array of urls with own libraries and all exported libraries of
* plugins that are required to this plugin
* @param parent
* the parent
*/
public PluginClassLoader(URL[] urls, ClassLoader parent) {
super(urls, parent);
}
}
|
[
"611041314@qq.com"
] |
611041314@qq.com
|
9e90918a4ae426f762cd25e3311a6499112d55c0
|
5e3235edf3de262f4d10b9e9e1fcc3bd13d6b8b1
|
/Code Snippet Repository/Hibernate/Hibernate5860.java
|
bb1182a205d61f82bd0e9d8fca80d80dfb68b7f7
|
[] |
no_license
|
saber13812002/DeepCRM
|
3336a244d4852a364800af3181e03e868cf6f9f5
|
be3e5e50e34a042d5ba7259ff5ff75c08ab32bb9
|
refs/heads/master
| 2023-03-16T00:08:06.473699
| 2018-04-18T05:29:50
| 2018-04-18T05:29:50
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 1,385
|
java
|
@Test
@TestForIssue( jiraKey = "")
public void fetchUsingHql() {
// This test is here only for comparison with results from fetchAttributeNodeFromSubgraph.
// At the time this was written, the generated SQL from the HQL is the same as that generated with the
// query hint in fetchAttributeNodeFromSubgraph. I am leaving this here for future debugging purposes.
EntityManager em = getOrCreateEntityManager();
em.getTransaction().begin();
Address address = new Address();
address.city = "TestCity";
CustomerOrder customerOrder = new CustomerOrder();
customerOrder.shippingAddress = address;
Product product = new Product();
OrderPosition orderPosition = new OrderPosition();
orderPosition.product = product;
customerOrder.orderPosition = orderPosition;
em.persist( address );
em.persist( orderPosition );
em.persist( product );
em.persist( customerOrder );
em.getTransaction().commit();
em.clear();
em.getTransaction().begin();
TypedQuery<CustomerOrder> query = em.createQuery(
"SELECT o FROM EntityGraphUsingFetchGraphTest$CustomerOrder o left join fetch o.orderPosition pos left join fetch pos.product left join fetch o.shippingAddress", CustomerOrder.class
);
final List<CustomerOrder> results = query.getResultList();
assertTrue( Hibernate.isInitialized( results ) );
em.getTransaction().commit();
em.close();
}
|
[
"Qing.Mi@my.cityu.edu.hk"
] |
Qing.Mi@my.cityu.edu.hk
|
88a6039bea1fea0e296eea45b20914ba47f0c624
|
8beef846b44983c749c63dc428f7c531738aa57e
|
/Workspace/org.aieonf.commons.ui/src/org/aieonf/commons/ui/session/PushSession.java
|
6cfd45ec8469726359b35632036b525d44fcdda8
|
[
"Apache-2.0"
] |
permissive
|
condast/AieonF
|
6d4455812cdb6971a7d1a6a4afcdef5a3ae24251
|
7c096a63b0c2b0eb6c43a34e011e6b2ad7d678f8
|
refs/heads/master
| 2021-06-24T00:00:01.186191
| 2021-01-18T15:27:29
| 2021-01-18T15:27:29
| 22,102,220
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 2,333
|
java
|
package org.aieonf.commons.ui.session;
import java.util.ArrayList;
import java.util.Collection;
import java.util.LinkedList;
import java.util.Timer;
import java.util.TimerTask;
import org.eclipse.rap.rwt.service.ServerPushSession;
import org.eclipse.swt.widgets.Display;
public class PushSession<T> {
public static final int DEFAULT_TIMEOUT = 5000;
private Display display;
private ServerPushSession session;
private boolean refresh;
private int sleep;
private boolean started;
private Timer timer;
private Collection<ISessionListener<T>> listeners;
private LinkedList<T> data;
public PushSession() {
this( DEFAULT_TIMEOUT );
}
protected PushSession( int sleep ) {
listeners = new ArrayList<ISessionListener<T>>();
data = new LinkedList<T>();
this.sleep = sleep;
this.started = false;
timer = new Timer();
timer.schedule(new PollTask(), 5000, this.sleep);
}
public void addSessionListener( ISessionListener<T> listener ){
this.listeners.add( listener );
}
public void removeSessionListener( ISessionListener<T> listener ){
this.listeners.remove( listener );
}
public void init( Display display ){
this.display = display;
}
public synchronized void addData( T dt ){
if(!started )
return;
data.add(dt);
this.refresh = !data.isEmpty();
}
/**
* @author Kees
* Start the push session. Put in try/catch to prevent a system freeze on
* the server. Not quite sure why java.util.concurrent.RejectedExecutionException occurs
*/
public void start(){
session = new ServerPushSession();
try {
session.start();
this.started = true;
}
catch( Exception ex ) {
ex.printStackTrace();
}
}
public void stop(){
this.started = false;
}
public void dispose(){
if( this.listeners != null )
this.listeners.clear();
this.display = null;
this.stop();
}
private class PollTask extends TimerTask {
@Override
public void run() {
if( !refresh || !started || ( display == null ) || ( display.isDisposed()))
return;
display.asyncExec( new Runnable() {
@Override
public void run() {
for(ISessionListener<T> listener: listeners){
while( !data.isEmpty())
listener.notifySessionChanged( new SessionEvent<T>( this, data.removeFirst() ));
}
session.stop();
start();
}
});
};
}
}
|
[
"info@condast.com"
] |
info@condast.com
|
98ee86ea81ba60ac6a47d75a33f4cb967c4e6029
|
332e7cd168b162e30aefee3edd6743d1a785ff7b
|
/Old code/nac-software-2017/robot/branches/Simulator/FRCSimFiles/GearsBot_CmdDemo/src/org/usfirst/frc/team93/robot/commands/OpenClaw.java
|
2075a162df87e8f7a30ca567f7f2f75412b626e4
|
[] |
no_license
|
first-team-93-new-apple-corp/OldSvnRepos
|
6a9ab7adcae96c5c1aec1cd07f94e9a27f6c5218
|
91a8bc09fc48f77ac32ca8fa182456fa7f0cba25
|
refs/heads/master
| 2020-05-21T03:51:03.176033
| 2019-05-10T01:22:11
| 2019-05-10T01:22:11
| 185,892,238
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 1,129
|
java
|
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package org.usfirst.frc.team93.robot.commands;
import edu.wpi.first.wpilibj.command.Command;
import org.usfirst.frc.team93.robot.Robot;
/**
* Opens the claw for one second. Real robots should use sensors, stalling
* motors is BAD!
*/
public class OpenClaw extends Command {
public OpenClaw() {
requires(Robot.claw);
setTimeout(1);
}
// Called just before this Command runs the first time
protected void initialize() {
Robot.claw.open();
}
// Called repeatedly when this Command is scheduled to run
protected void execute() {
}
// Make this return true when this Command no longer needs to run execute()
protected boolean isFinished() {
return isTimedOut();
}
// Called once after isFinished returns true
protected void end() {
Robot.claw.stop();
}
// Called when another command which requires one or more of the same
// subsystems is scheduled to run
protected void interrupted() {
end();
}
}
|
[
"plexus@aasd.k12.wi.us"
] |
plexus@aasd.k12.wi.us
|
1356a09d8352a53a7dddcfe985abef037cfdfd77
|
d09bf50682d2d65873142f6a5e334fa3e488af4f
|
/app/src/main/java/org/jiangtao/lifetime/WelcomeActivity.java
|
eaa391a4628117dcecb423a5b40a9451407ac629
|
[] |
no_license
|
Labradors/LifeTime
|
6bdcda5e3b3511c9cb1bd3c1acfe4077987ccd05
|
7f06e48fadbdfdd8b9277aacf72a4d6f005a4808
|
refs/heads/master
| 2021-05-31T14:40:43.589556
| 2016-04-20T17:13:59
| 2016-04-20T17:13:59
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 3,762
|
java
|
package org.jiangtao.lifetime;
import android.content.Intent;
import android.content.SharedPreferences;
import android.graphics.Bitmap;
import android.os.Bundle;
import android.os.Handler;
import android.os.Message;
import android.support.v7.app.ActionBar;
import android.support.v7.app.AppCompatActivity;
import android.widget.ImageView;
import org.jiangtao.application.LifeApplication;
import org.jiangtao.networkutils.WelcomeLoadPicture;
import org.jiangtao.utils.ConstantValues;
/**
* 应用欢迎界面
*/
public class WelcomeActivity extends AppCompatActivity {
private static final int TIME = 2000;
private static final int GO_HOME = 1000;
private static final int GO_GUIDE = 1001;
private ImageView mWelcomeImageView;
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_welcome);
mWelcomeImageView = (ImageView) findViewById(R.id.iv_welcome_activity_welcome);
hideActionBar();
if (LifeApplication.getInstance().isNetworkAvailable()) {
updateImageView();
} else {
mWelcomeImageView.setImageResource(R.drawable.t);
}
init();
}
private Handler handler = new Handler() {
@Override
public void handleMessage(Message msg) {
switch (msg.what) {
case GO_HOME: {
goHome();
break;
}
case GO_GUIDE: {
goGuide();
break;
}
}
}
};
/**
* 多次使用,主界面
*/
private void goHome() {
Intent intent = new Intent(WelcomeActivity.this, IndexActivity.class);
startActivity(intent);
}
/**
* 第一次使用,引导界面
*/
private void goGuide() {
Intent intent = new Intent(WelcomeActivity.this, GuideActivity.class);
startActivity(intent);
}
/**
* 从SharedPreferences中获取数据,查看是否是第一次登陆
*/
private void init() {
SharedPreferences perPreferences = getSharedPreferences("Jiangtao", MODE_PRIVATE);
boolean isFirstIn = perPreferences.getBoolean("isFirstIn", true);
if (!isFirstIn) {
handler.sendEmptyMessageDelayed(GO_HOME, TIME);
} else {
handler.sendEmptyMessageDelayed(GO_GUIDE, TIME);
SharedPreferences.Editor editor = perPreferences.edit();
editor.putBoolean("isFirstIn", false);
editor.apply();
}
}
/**
* 隐藏actionbar
*/
private void hideActionBar() {
ActionBar actionBar = getSupportActionBar();
assert actionBar != null;
actionBar.hide();
}
/**
* 联网的情况下从从网络中更新图片
*/
private void updateImageView() {
new Thread(new Runnable() {
@Override
public void run() {
WelcomeLoadPicture welcomeLoadPicture = WelcomeLoadPicture.getInstance();
try {
final Bitmap bitmap = welcomeLoadPicture.loadImageFromLifeTime(ConstantValues
.welcomeUrl);
runOnUiThread(new Runnable() {
@Override
public void run() {
mWelcomeImageView.setImageBitmap(bitmap);
}
});
} catch (Exception e) {
e.printStackTrace();
}
}
}).start();
}
@Override
protected void onStop() {
super.onStop();
finish();
}
}
|
[
"jiangtao103cp@163.com"
] |
jiangtao103cp@163.com
|
8dd179068084e8a4502e41f24af1ee49ff21971b
|
db8d0016325aec485bf8b66a7d0f84bb925cc7d0
|
/shop-service-api/src/main/java/com/rt/shop/entity/query/ShippingQueryObject.java
|
6bd3fdd4f7cffb1ddf8a2a2130ab96ad86745770
|
[] |
no_license
|
jjmnbv/shop
|
a0ff70e235de91198cea0a7b0efc270a8719ccd0
|
48c6d47f12468b5692f13c20f7c7f24592acb1b0
|
refs/heads/master
| 2021-06-12T14:09:31.784490
| 2017-04-07T02:59:12
| 2017-04-07T02:59:12
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 402
|
java
|
package com.rt.shop.entity.query;
import org.springframework.web.servlet.ModelAndView;
import com.rt.shop.query.QueryObject;
public class ShippingQueryObject extends QueryObject
{
public ShippingQueryObject(String currentPage, ModelAndView mv, String orderBy, String orderType)
{
super(currentPage, mv, orderBy, orderType);
}
public ShippingQueryObject()
{
}
}
|
[
"bl.jiwenlei@gmail.com"
] |
bl.jiwenlei@gmail.com
|
5f09fb4893a46ac1b970e3c3767228a69e840641
|
ffbc38abf50892422d73c8d3d09b5efb5405fd1f
|
/app/src/androidTest/java/com/tranxit/app/ExampleInstrumentedTest.java
|
f893602111826a9c75ac375012a8bca6d756a8a8
|
[] |
no_license
|
aartisoft/DIffride
|
423d412bc748c6416ac0f3479a1f0afe0aba0cae
|
8b48424b5434b65856f0089532d8a75913fad062
|
refs/heads/master
| 2020-05-26T13:14:24.987311
| 2018-09-29T06:32:14
| 2018-09-29T06:32:14
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 740
|
java
|
package com.diff.app;
import android.content.Context;
import android.support.test.InstrumentationRegistry;
import android.support.test.runner.AndroidJUnit4;
import org.junit.Test;
import org.junit.runner.RunWith;
import static org.junit.Assert.assertEquals;
/**
* Instrumentation test, which will execute on an Android device.
*
* @see <a href="http://d.android.com/tools/testing">Testing documentation</a>
*/
@RunWith(AndroidJUnit4.class)
public class ExampleInstrumentedTest {
@Test
public void useAppContext() throws Exception {
// Context of the app under test.
Context appContext = InstrumentationRegistry.getTargetContext();
assertEquals("com.xuber.app", appContext.getPackageName());
}
}
|
[
"sundar@appoets.com"
] |
sundar@appoets.com
|
a54209648e6d326567031bc516c71b0cadc7f40a
|
f91f56c85be271f6e5db7a17caa2395fccd09082
|
/externals/src/main/java/llnl/gnem/core/util/Passband.java
|
7a91927286ad1262477d4e22ab5f0cca08fd16a8
|
[
"Apache-2.0"
] |
permissive
|
imtseismic/Lgcoda
|
e8c078181169efb82c4b9427971b5d41c8a03927
|
41f251c141d130a87651db480a00586efe40e711
|
refs/heads/master
| 2022-07-17T21:37:03.298416
| 2020-04-03T18:41:56
| 2020-04-03T18:41:56
| 265,893,735
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 3,230
|
java
|
/*
* Copyright (c) 2018, Lawrence Livermore National Security, LLC. Produced at the Lawrence Livermore National Laboratory
* CODE-743439.
* All rights reserved.
* This file is part of CCT. For details, see https://github.com/LLNL/coda-calibration-tool.
*
* Licensed under the Apache License, Version 2.0 (the “Licensee”); 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.
*
* This work was performed under the auspices of the U.S. Department of Energy
* by Lawrence Livermore National Laboratory under Contract DE-AC52-07NA27344.
*/
package llnl.gnem.core.util;
/**
* A type-safe enum that describes the passband for a filter.
*
* @author Doug Dodge
*/
public class Passband {
private final String name;
private Passband(String name) {
this.name = name;
}
/**
* A string representation of the passband for a filter suitable for use
* with the dbh.ButterworthFilter..
*
* @return A String with the one of the values "LP", or "HP", "BP", "BR"
*/
public String toString() {
return name;
}
/**
* Get all the passband codes known to this class
*
* @return A String array containing all the passband codes
*/
public static String[] getPassBandCodes() {
String[] codes = { "BP", "BR", "LP", "HP" };
return codes;
}
/**
* Returns a Passband object given a 2-character String descriptor. Only
* recognized codes are "BP", "LP", "HP", "BR". Any other String will result
* in a null Passband object.
*
* @param code
* The code of the desired passband object.
* @return The specified Passband object.
*/
public static Passband getPassbandFromString(final String code) {
if (code.equals("BP"))
return Passband.BAND_PASS;
else if (code.equals("LP"))
return Passband.LOW_PASS;
else if (code.equals("HP"))
return Passband.HIGH_PASS;
else if (code.equals("BR"))
return Passband.BAND_REJECT;
else
return null;
}
public static Passband[] getAvailablePassBands() {
Passband[] result = new Passband[4];
result[0] = BAND_PASS;
result[1] = BAND_REJECT;
result[2] = LOW_PASS;
result[3] = HIGH_PASS;
return result;
}
/**
* Specifies a band-pass filter
*/
public final static Passband BAND_PASS = new Passband("BP");
/**
* Specifies a band-reject filter
*/
public final static Passband BAND_REJECT = new Passband("BR");
/**
* Specifies a low-pass filter
*/
public final static Passband LOW_PASS = new Passband("LP");
/**
* Specifies a high-pass filter
*/
public final static Passband HIGH_PASS = new Passband("HP");
}
|
[
"barno1@llnl.gov"
] |
barno1@llnl.gov
|
d480216e8b424fc0e8c2adc67948a24d1c1228e5
|
647ec12ce50f06e7380fdbfb5b71e9e2d1ac03b4
|
/com.tencent.mm/classes.jar/com/tencent/mm/boot/svg/code/drawable/connected_router_state_succ.java
|
8b3e26ea7f84f3b420b21b810c51a41eb3354dd8
|
[] |
no_license
|
tsuzcx/qq_apk
|
0d5e792c3c7351ab781957bac465c55c505caf61
|
afe46ef5640d0ba6850cdefd3c11badbd725a3f6
|
refs/heads/main
| 2022-07-02T10:32:11.651957
| 2022-02-01T12:41:38
| 2022-02-01T12:41:38
| 453,860,108
| 36
| 9
| null | 2022-01-31T09:46:26
| 2022-01-31T02:43:22
|
Java
|
UTF-8
|
Java
| false
| false
| 3,969
|
java
|
package com.tencent.mm.boot.svg.code.drawable;
import android.graphics.Canvas;
import android.graphics.Paint;
import android.graphics.Paint.Cap;
import android.graphics.Paint.Join;
import android.graphics.Paint.Style;
import android.graphics.Path;
import android.os.Looper;
import com.tencent.mm.svg.WeChatSVGRenderC2Java;
import com.tencent.mm.svg.c;
public class connected_router_state_succ
extends c
{
private final int height = 240;
private final int width = 240;
public int doCommand(int paramInt, Object... paramVarArgs)
{
switch (paramInt)
{
}
for (;;)
{
return 0;
return 240;
return 240;
Canvas localCanvas = (Canvas)paramVarArgs[0];
paramVarArgs = (Looper)paramVarArgs[1];
c.instanceMatrix(paramVarArgs);
c.instanceMatrixArray(paramVarArgs);
Paint localPaint = c.instancePaint(paramVarArgs);
localPaint.setFlags(385);
localPaint.setStyle(Paint.Style.FILL);
Object localObject = c.instancePaint(paramVarArgs);
((Paint)localObject).setFlags(385);
((Paint)localObject).setStyle(Paint.Style.STROKE);
localPaint.setColor(-16777216);
((Paint)localObject).setStrokeWidth(1.0F);
((Paint)localObject).setStrokeCap(Paint.Cap.BUTT);
((Paint)localObject).setStrokeJoin(Paint.Join.MITER);
((Paint)localObject).setStrokeMiter(4.0F);
((Paint)localObject).setPathEffect(null);
c.instancePaint((Paint)localObject, paramVarArgs).setStrokeWidth(1.0F);
localCanvas.save();
localObject = c.instancePaint(localPaint, paramVarArgs);
((Paint)localObject).setColor(-16139513);
Path localPath = c.instancePath(paramVarArgs);
localPath.moveTo(213.0F, 121.14815F);
localPath.cubicTo(213.0F, 68.636444F, 171.36356F, 27.0F, 118.85185F, 27.0F);
localPath.cubicTo(68.636444F, 27.0F, 27.0F, 68.636444F, 27.0F, 121.14815F);
localPath.cubicTo(27.0F, 171.36356F, 68.636444F, 213.0F, 118.85185F, 213.0F);
localPath.cubicTo(171.36356F, 213.0F, 213.0F, 171.36356F, 213.0F, 121.14815F);
localPath.close();
WeChatSVGRenderC2Java.setFillType(localPath, 2);
localCanvas.drawPath(localPath, (Paint)localObject);
localCanvas.restore();
localCanvas.save();
localPaint = c.instancePaint(localPaint, paramVarArgs);
localPaint.setColor(-1);
localObject = c.instancePath(paramVarArgs);
((Path)localObject).moveTo(73.845436F, 126.13097F);
((Path)localObject).cubicTo(73.461357F, 125.73346F, 73.409508F, 125.05811F, 73.746353F, 124.59977F);
((Path)localObject).lineTo(77.934059F, 118.90164F);
((Path)localObject).cubicTo(78.26342F, 118.45349F, 78.884964F, 118.36194F, 79.323456F, 118.69801F);
((Path)localObject).lineTo(104.23569F, 137.79182F);
((Path)localObject).cubicTo(104.67368F, 138.1275F, 105.37836F, 138.10837F, 105.79235F, 137.76349F);
((Path)localObject).lineTo(166.43353F, 87.244484F);
((Path)localObject).cubicTo(166.85526F, 86.89315F, 167.51759F, 86.924812F, 167.91162F, 87.31395F);
((Path)localObject).lineTo(171.86308F, 91.2164F);
((Path)localObject).cubicTo(172.25768F, 91.606102F, 172.26135F, 92.233208F, 171.86464F, 92.623634F);
((Path)localObject).lineTo(105.73968F, 157.70047F);
((Path)localObject).cubicTo(105.34595F, 158.08797F, 104.71127F, 158.07556F, 104.33132F, 157.68234F);
((Path)localObject).lineTo(73.845436F, 126.13097F);
((Path)localObject).close();
WeChatSVGRenderC2Java.setFillType((Path)localObject, 2);
localCanvas.drawPath((Path)localObject, localPaint);
localCanvas.restore();
c.done(paramVarArgs);
}
}
}
/* Location: L:\local\mybackup\temp\qq_apk\com.tencent.mm\classes12.jar
* Qualified Name: com.tencent.mm.boot.svg.code.drawable.connected_router_state_succ
* JD-Core Version: 0.7.0.1
*/
|
[
"98632993+tsuzcx@users.noreply.github.com"
] |
98632993+tsuzcx@users.noreply.github.com
|
fd0b15863871d8cbd449450b359765f889072e2c
|
c4256d8cea6c7c0849f83a4e8e06c87131a3e08f
|
/primitive/src/main/java/io/atomix/primitive/proxy/impl/AbstractProxyClient.java
|
a62a8190124ac92db182cd3550baad78ea106ece
|
[
"Apache-2.0"
] |
permissive
|
zeebe-io/atomix
|
6ecb716d6909f928f99ba2db64bade8752c65512
|
fc935da2fe948c1f1ceef4ae4cadd60eb8333f49
|
refs/heads/develop
| 2020-05-06T12:13:20.377869
| 2020-03-24T14:25:08
| 2020-03-24T14:25:08
| 180,109,626
| 0
| 3
|
Apache-2.0
| 2020-04-06T09:59:00
| 2019-04-08T08:58:17
|
Java
|
UTF-8
|
Java
| false
| false
| 5,459
|
java
|
/*
* Copyright 2018-present Open Networking Foundation
*
* 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://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 io.atomix.primitive.proxy.impl;
import com.google.common.collect.Maps;
import com.google.common.collect.Sets;
import io.atomix.primitive.PrimitiveState;
import io.atomix.primitive.PrimitiveType;
import io.atomix.primitive.partition.PartitionId;
import io.atomix.primitive.protocol.PrimitiveProtocol;
import io.atomix.primitive.proxy.ProxyClient;
import io.atomix.primitive.proxy.ProxySession;
import io.atomix.utils.concurrent.Futures;
import java.util.Collection;
import java.util.Collections;
import java.util.List;
import java.util.Map;
import java.util.Set;
import java.util.concurrent.CompletableFuture;
import java.util.concurrent.CopyOnWriteArrayList;
import java.util.function.Consumer;
import java.util.stream.Collectors;
import static com.google.common.base.Preconditions.checkNotNull;
/**
* Default primitive proxy.
*/
public abstract class AbstractProxyClient<S> implements ProxyClient<S> {
private final String name;
private final PrimitiveType type;
private final PrimitiveProtocol protocol;
private final List<PartitionId> partitionIds = new CopyOnWriteArrayList<>();
private final Map<PartitionId, ProxySession<S>> partitions = Maps.newConcurrentMap();
private final Set<Consumer<PrimitiveState>> stateChangeListeners = Sets.newCopyOnWriteArraySet();
private final Map<PartitionId, PrimitiveState> states = Maps.newHashMap();
private volatile PrimitiveState state = PrimitiveState.CLOSED;
public AbstractProxyClient(
String name,
PrimitiveType type,
PrimitiveProtocol protocol,
Collection<ProxySession<S>> partitions) {
this.name = checkNotNull(name, "name cannot be null");
this.type = checkNotNull(type, "type cannot be null");
this.protocol = checkNotNull(protocol, "protocol cannot be null");
partitions.forEach(partition -> {
this.partitionIds.add(partition.partitionId());
this.partitions.put(partition.partitionId(), partition);
states.put(partition.partitionId(), PrimitiveState.CLOSED);
partition.addStateChangeListener(state -> onStateChange(partition.partitionId(), state));
});
Collections.sort(partitionIds);
}
@Override
public String name() {
return name;
}
@Override
public PrimitiveType type() {
return type;
}
@Override
public PrimitiveProtocol protocol() {
return protocol;
}
@Override
public PrimitiveState getState() {
return state;
}
@Override
public Collection<ProxySession<S>> getPartitions() {
return partitions.values();
}
@Override
public List<PartitionId> getPartitionIds() {
return partitionIds;
}
@Override
public ProxySession<S> getPartition(PartitionId partitionId) {
return partitions.get(partitionId);
}
@Override
public void addStateChangeListener(Consumer<PrimitiveState> listener) {
stateChangeListeners.add(listener);
}
@Override
public void removeStateChangeListener(Consumer<PrimitiveState> listener) {
stateChangeListeners.remove(listener);
}
@Override
public CompletableFuture<ProxyClient<S>> connect() {
partitions.forEach((partitionId, partition) -> {
partition.addStateChangeListener(state -> onStateChange(partitionId, state));
});
return Futures.allOf(partitions.values()
.stream()
.map(ProxySession::connect)
.collect(Collectors.toList()))
.thenApply(v -> this);
}
@Override
public CompletableFuture<Void> delete() {
return Futures.allOf(partitions.values()
.stream()
.map(ProxySession::delete)
.collect(Collectors.toList()))
.thenApply(v -> null);
}
@Override
public CompletableFuture<Void> close() {
return Futures.allOf(partitions.values()
.stream()
.map(ProxySession::close)
.collect(Collectors.toList()))
.thenApply(v -> null);
}
/**
* Handles a partition proxy state change.
*/
private synchronized void onStateChange(PartitionId partitionId, PrimitiveState state) {
states.put(partitionId, state);
switch (state) {
case CONNECTED:
if (this.state != PrimitiveState.CONNECTED && !states.containsValue(PrimitiveState.SUSPENDED) && !states.containsValue(PrimitiveState.CLOSED)) {
this.state = PrimitiveState.CONNECTED;
stateChangeListeners.forEach(l -> l.accept(PrimitiveState.CONNECTED));
}
break;
case SUSPENDED:
if (this.state == PrimitiveState.CONNECTED) {
this.state = PrimitiveState.SUSPENDED;
stateChangeListeners.forEach(l -> l.accept(PrimitiveState.SUSPENDED));
}
break;
case CLOSED:
if (this.state != PrimitiveState.CLOSED) {
this.state = PrimitiveState.CLOSED;
stateChangeListeners.forEach(l -> l.accept(PrimitiveState.CLOSED));
}
break;
}
}
}
|
[
"jordan.halterman@gmail.com"
] |
jordan.halterman@gmail.com
|
e1f1be4a144b681410316b82a8c35ad4f5b57dd5
|
cdee2fd05c4c309f219d304497b0379854ccbdff
|
/Sesion-08/Ejemplo-03/ejemplo03/src/main/java/org/bedu/testing/demo/monitoreo/services/ReporteSemanalService.java
|
eb7556de8e0a604e1275dd2d61a4a05c781351e2
|
[] |
no_license
|
PerlaGCastillo/C2-Java-Testing
|
bf2b75b828354e723e3eb71c7a367f44ecbfacb2
|
45ca4edc902e20f1fb9cbc03b4f3fcd4afa8e238
|
refs/heads/master
| 2020-11-26T02:06:42.575078
| 2019-11-18T14:10:13
| 2019-11-18T14:10:13
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 461
|
java
|
/*
* 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 org.bedu.testing.demo.monitoreo.services;
import java.time.LocalDate;
/**
*
* @author Fernando
*/
public interface ReporteSemanalService {
String getXLSX(LocalDate fechaInicio, LocalDate fechaFin);
String getPDF(LocalDate fechaInicio, LocalDate fechaFin);
}
|
[
"amonmar2000@hotmail.com"
] |
amonmar2000@hotmail.com
|
12971c381d058159709aeaf95ba0aedd42355973
|
5741045375dcbbafcf7288d65a11c44de2e56484
|
/reddit-decompilada/android/support/transition/PropertyValuesHolderUtilsImpl.java
|
cb9efa894e5d40f60ae6b1a8b25da30fa785ea19
|
[] |
no_license
|
miarevalo10/ReporteReddit
|
18dd19bcec46c42ff933bb330ba65280615c281c
|
a0db5538e85e9a081bf268cb1590f0eeb113ed77
|
refs/heads/master
| 2020-03-16T17:42:34.840154
| 2018-05-11T10:16:04
| 2018-05-11T10:16:04
| 132,843,706
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 295
|
java
|
package android.support.transition;
import android.animation.PropertyValuesHolder;
import android.graphics.Path;
import android.graphics.PointF;
import android.util.Property;
interface PropertyValuesHolderUtilsImpl {
PropertyValuesHolder mo156a(Property<?, PointF> property, Path path);
}
|
[
"mi.arevalo10@uniandes.edu.co"
] |
mi.arevalo10@uniandes.edu.co
|
877c8cfbeeaaa89ea0e0aa1ad9d790794aae431a
|
b349c68a7d99a97cfdca0115cb9a050f26078867
|
/src/main/java/cn/hgxsp/miaosha_1/controller/UserController.java
|
295a4194beccf1265f86e5b97ba46919986a5565
|
[] |
no_license
|
houlinan/miaosha_1
|
5232333a64d591a8948ae9c1a026754ab1a4fd2a
|
d222ea84b88c434d37c7bd635783e2b7816cb1d6
|
refs/heads/master
| 2020-03-29T18:52:31.116209
| 2018-10-22T10:05:45
| 2018-10-22T10:05:45
| 150,235,938
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 960
|
java
|
package cn.hgxsp.miaosha_1.controller;
import cn.hgxsp.miaosha_1.Domain.User;
import cn.hgxsp.miaosha_1.resultVO.Result;
import cn.hgxsp.miaosha_1.service.UserService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
/**
* DESC:用户Controller层
* CREATED BY :@hou.linan
* CREATED DATE :2018/9/25
* Time : 16:27
*/
@RequestMapping("/user")
@RestController
public class UserController {
@Autowired
private UserService userService ;
@GetMapping("/getById")
public Result<User> getById(){
return Result.success(userService.getById(0));
}
@GetMapping("/add")
public void add(){
User user = new User();
user.setId(1);
user.setUsername("houlinan");
userService.add(user );
}
}
|
[
"houlinan@vip.qq.com"
] |
houlinan@vip.qq.com
|
6f02eea3ee67e96b70216ea93924b2ba5d6ef70a
|
d1bd1246f161b77efb418a9c24ee544d59fd1d20
|
/android/myapplication/trunk/src/org/javenstudio/android/app/SettingOperation.java
|
30d7f6a0af8cebf8ae66e73dd7fbae89448aab0d
|
[] |
no_license
|
navychen2003/javen
|
f9a94b2e69443291d4b5c3db5a0fc0d1206d2d4a
|
a3c2312bc24356b1c58b1664543364bfc80e816d
|
refs/heads/master
| 2021-01-20T12:12:46.040953
| 2015-03-03T06:14:46
| 2015-03-03T06:14:46
| 30,912,222
| 0
| 1
| null | 2023-03-20T11:55:50
| 2015-02-17T10:24:28
|
Java
|
UTF-8
|
Java
| false
| false
| 1,217
|
java
|
package org.javenstudio.android.app;
import android.app.Activity;
import org.javenstudio.cocoka.app.IMenuItem;
import org.javenstudio.common.util.Logger;
public class SettingOperation extends MenuOperation.Operation {
private static final Logger LOG = Logger.getLogger(SettingOperation.class);
public SettingOperation(int itemId) {
super(itemId);
}
@Override
public boolean isEnabled() { return true; }
@Override
public boolean onOptionsItemSelected(final Activity activity, IMenuItem item) {
if (activity == null || item == null)
return false;
if (item.getItemId() != getItemId()) {
//if (LOG.isDebugEnabled()) {
// LOG.debug("onOptionsItemSelected: activity=" + activity + " item=" + item
// + ", itemId=" + item.getItemId() + " not equals to operationItemId=" + getItemId());
//}
return false;
}
if (LOG.isDebugEnabled()) {
LOG.debug("onOptionsItemSelected: activity=" + activity + " item=" + item
+ " itemId=" + item.getItemId());
}
//if (activity instanceof IActivity) {
// //IActivity a = (IActivity)activity;
//}
onActionSetting(activity);
return true;
}
protected void onActionSetting(Activity activity) {}
}
|
[
"navychen2003@hotmail.com"
] |
navychen2003@hotmail.com
|
7a6dbba2dc9ed7b91c024e794d9e33d57a4e19dc
|
d00af6c547e629983ff777abe35fc9c36b3b2371
|
/jboss-all/console/src/main/org/jboss/console/plugins/helpers/jmx/DomainData.java
|
41388b7ddc345b678852e804bc9ddd817b965971
|
[] |
no_license
|
aosm/JBoss
|
e4afad3e0d6a50685a55a45209e99e7a92f974ea
|
75a042bd25dd995392f3dbc05ddf4bbf9bdc8cd7
|
refs/heads/master
| 2023-07-08T21:50:23.795023
| 2013-03-20T07:43:51
| 2013-03-20T07:43:51
| 8,898,416
| 1
| 1
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 1,099
|
java
|
package org.jboss.console.plugins.helpers.jmx;
import java.util.Arrays;
import java.util.TreeSet;
/** The MBeanData for a given JMX domain name
*
* @author Scott.Stark@jboss.org
* @version $Revision: 1.1.2.1 $
*/
public class DomainData
{
String domainName;
TreeSet domainData = new TreeSet();
/** Creates a new instance of MBeanInfo */
public DomainData(String domainName)
{
this.domainName = domainName;
}
public DomainData(String domainName, MBeanData[] data)
{
this.domainName = domainName;
domainData.addAll(Arrays.asList(data));
}
public int hashCode()
{
return domainName.hashCode();
}
public boolean equals(Object obj)
{
DomainData data = (DomainData) obj;
return domainName.equals(data.domainName);
}
public String getDomainName()
{
return domainName;
}
public MBeanData[] getData()
{
MBeanData[] data = new MBeanData[domainData.size()];
domainData.toArray(data);
return data;
}
public void addData(MBeanData data)
{
domainData.add(data);
}
}
|
[
"rasmus@dll.nu"
] |
rasmus@dll.nu
|
30a13658939697a1189d741a5d9d1cabfbb70a54
|
8071ef15949cf98c59867ca739cfb757b6ba7dfa
|
/app/src/main/java/com/res/cloudspot/util/HttpUtil.java
|
ed010085c3f7d77bba29cbdb32aa378128d5be7e
|
[] |
no_license
|
ajacker/CloudSpot
|
a20c632d74edd4a27b7f5a6335314834216a4dbb
|
fc54e0c68901176ace2b956f77cba895fc65e020
|
refs/heads/master
| 2020-08-15T12:00:18.662327
| 2019-10-15T15:51:36
| 2019-10-15T15:51:36
| 215,337,646
| 3
| 1
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 3,569
|
java
|
package com.res.cloudspot.util;
import android.os.Handler;
import android.os.Message;
import com.google.gson.Gson;
import com.google.gson.GsonBuilder;
import com.google.gson.reflect.TypeToken;
import com.res.cloudspot.util.bean.ArticleData;
import org.jetbrains.annotations.NotNull;
import java.io.File;
import java.io.IOException;
import java.util.List;
import java.util.concurrent.TimeUnit;
import okhttp3.Call;
import okhttp3.Callback;
import okhttp3.MediaType;
import okhttp3.MultipartBody;
import okhttp3.OkHttpClient;
import okhttp3.Request;
import okhttp3.RequestBody;
import okhttp3.Response;
/**
* @author ajacker
*/
public class HttpUtil {
public static final int UPLOAD_MESSAGE = 444;
public static final int ARTICLE_MESSAGE = 555;
public static final int READ_MESSAGE = 666;
private static MediaType mediaType = MediaType.parse("application/octet-stream");
private static OkHttpClient okHttpClient = new OkHttpClient.Builder()
.connectTimeout(10, TimeUnit.SECONDS)
.readTimeout(10, TimeUnit.SECONDS)
.build();
public static void upLoadPic(File file, Handler handler) {
final String url = "http://39.106.202.5:8888";
String filename = file.getName();
MultipartBody body = new MultipartBody.Builder()
.setType(MultipartBody.FORM)
.addFormDataPart("file", filename, RequestBody.create(file, mediaType))
.build();
final Request request = new Request.Builder()
.url(url)
.post(body)
.build();
Call call = okHttpClient.newCall(request);
call.enqueue(new Callback() {
@Override
public void onFailure(@NotNull Call call, @NotNull IOException e) {
Message message = handler.obtainMessage(UPLOAD_MESSAGE);
message.arg1 = -1;
handler.sendMessage(message);
}
@Override
public void onResponse(@NotNull Call call, @NotNull Response response) throws IOException {
String body = response.body().string();
Message message = handler.obtainMessage(UPLOAD_MESSAGE);
try {
message.arg1 = Integer.parseInt(body.trim());
} catch (Exception e) {
e.printStackTrace();
message.arg1 = -1;
}
handler.sendMessage(message);
}
});
}
public static void getArticleList(Handler handler) {
final String url = "http://39.106.202.5:8080/articles";
Request request = new Request.Builder()
.url(url)
.post(RequestBody.create("", null))
.build();
Call call = okHttpClient.newCall(request);
call.enqueue(new Callback() {
@Override
public void onFailure(@NotNull Call call, @NotNull IOException e) {
}
@Override
public void onResponse(@NotNull Call call, @NotNull Response response) throws IOException {
String result = response.body().string();
Message message = handler.obtainMessage(ARTICLE_MESSAGE);
Gson gson = new GsonBuilder().setDateFormat("yyyy-MM-dd HH:mm:ss").create();
message.obj = gson.<List<ArticleData>>fromJson(result, new TypeToken<List<ArticleData>>() {
}.getType());
handler.sendMessage(message);
}
});
}
}
|
[
"ajacker@foxmail.com"
] |
ajacker@foxmail.com
|
39c4cd0dba26f6e8c9e0071bf1e8f964e4990535
|
dc06652c4030ac2f8c9ebc3fa125a7c2e72fbf67
|
/Java/HelloWorld/src/ch8/Factorial.java
|
7d3337e01f3a4ccbaeea78acb2c781a8dd4ee026
|
[] |
no_license
|
sshhhGit/TIL
|
9b485edae8d381f3143db7e85db8c2727e0dbf87
|
fce88811ed2784dc6d0b0f76b0d824afb30d7d24
|
refs/heads/main
| 2023-09-02T12:05:32.033811
| 2021-11-10T12:04:10
| 2021-11-10T12:04:10
| 400,414,121
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 137
|
java
|
package ch8;
public class Factorial {
int compute(int x) {
if(x==1) {
return 1;
} else {
return x * compute(x - 1);
}
}
}
|
[
"seungho0497@hanmail.net"
] |
seungho0497@hanmail.net
|
9dd86f54b7825731c901a038220bae85003de471
|
f5aacd77191465d923ad982adaf32460737f94d2
|
/energy/services/user-service/user-service-infras/src/main/java/com/smxknife/energy/services/user/infras/converter/UserConverter.java
|
c19adac60ba5390431e507601225e189b2775b09
|
[] |
no_license
|
smxknife/smxknife
|
a0a87b5624aaa2bf3c82b05f2180a79bcbc65170
|
f6f3ed40bb998d9aea8cba4936ccfa738e4a35b9
|
refs/heads/master
| 2023-03-15T03:43:16.570846
| 2022-04-05T06:07:47
| 2022-04-05T06:07:47
| 122,691,839
| 1
| 0
| null | 2023-03-08T17:25:34
| 2018-02-24T01:46:19
|
Java
|
UTF-8
|
Java
| false
| false
| 533
|
java
|
package com.smxknife.energy.services.user.infras.converter;
import com.smxknife.energy.services.user.infras.entity.UserMeta;
import com.smxknife.energy.services.user.spi.domain.User;
import org.mapstruct.Mapper;
import org.mapstruct.Mappings;
import java.util.List;
/**
* @author smxknife
* 2021/5/19
*/
@Mapper(componentModel = "spring")
public interface UserConverter {
@Mappings({})
UserMeta toMeta(User user);
@Mappings({})
User fromMeta(UserMeta meta);
@Mappings({})
List<User> fromMetas(List<UserMeta> metas);
}
|
[
"2323937771@qq.com"
] |
2323937771@qq.com
|
a61cf80e78ede6740b7734fbdc7b28dc1e8868e9
|
e7d209cdaf1b3175ec9da96f0468ed176d666889
|
/common/util/src/main/java/com/alibaba/citrus/util/Utils.java
|
7288121152677b0bf0e59fd5d10857d153c62d30
|
[] |
no_license
|
unixcrh/citrus
|
04bceee7b5cbd7ae28603bebf90cb4d2c3839466
|
305dc121d046fbd749ccff222ed9f8bfeeb545f8
|
refs/heads/master
| 2020-04-03T16:46:28.721749
| 2012-08-22T23:58:28
| 2012-08-22T23:58:28
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 6,294
|
java
|
/*
* Copyright (c) 2002-2012 Alibaba Group Holding Limited.
* All rights reserved.
*
* 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://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 com.alibaba.citrus.util;
import static com.alibaba.citrus.util.ArrayUtil.*;
import java.util.Collections;
import java.util.Map;
import com.alibaba.citrus.util.i18n.LocaleUtil;
import com.alibaba.citrus.util.internal.StaticFunctionDelegatorBuilder;
import com.alibaba.citrus.util.io.StreamUtil;
/**
* 集成常用的工具类。
*
* @author Michael Zhou
*/
public class Utils {
private static final ArrayUtil ARRAY_UTIL = new ArrayUtil();
private static final ClassLoaderUtil CLASS_LOADER_UTIL = new ClassLoaderUtil();
private static final ClassUtil CLASS_UTIL = new ClassUtil();
private static final ExceptionUtil EXCEPTION_UTIL = new ExceptionUtil();
private static final FileUtil FILE_UTIL = new FileUtil();
private static final LocaleUtil LOCALE_UTIL = new LocaleUtil();
private static final MessageUtil MESSAGE_UTIL = new MessageUtil();
private static final ObjectUtil OBJECT_UTIL = new ObjectUtil();
private static final StreamUtil STREAM_UTIL = new StreamUtil();
private static final StringEscapeUtil STRING_ESCAPE_UTIL = new StringEscapeUtil();
private static final StringUtil STRING_UTIL = new StringUtil();
private static final SystemUtil SYSTEM_UTIL = new SystemUtil();
private static final Object MATH_UTIL = createMixin(Math.class);
private static final Object MIXIN_UTILS = createMixin( //
ArrayUtil.class, //
ClassLoaderUtil.class, //
ClassUtil.class, //
ExceptionUtil.class, //
FileUtil.class, //
LocaleUtil.class, //
MessageUtil.class, //
ObjectUtil.class, //
StreamUtil.class, //
StringEscapeUtil.class, //
StringUtil.class, //
SystemUtil.class, //
Math.class);
private static final Map<String, Object> ALL_UTILS = Collections.unmodifiableMap(arrayToMap(new Object[][] { //
{ "arrayUtil", ARRAY_UTIL }, //
{ "classLoaderUtil", CLASS_LOADER_UTIL }, //
{ "classUtil", CLASS_UTIL }, //
{ "exceptionUtil", EXCEPTION_UTIL }, //
{ "fileUtil", FILE_UTIL }, //
{ "localeUtil", LOCALE_UTIL }, //
{ "messageUtil", MESSAGE_UTIL }, //
{ "objectUtil", OBJECT_UTIL }, //
{ "streamUtil", STREAM_UTIL }, //
{ "stringEscapeUtil", STRING_ESCAPE_UTIL }, //
{ "stringUtil", STRING_UTIL }, //
{ "systemUtil", SYSTEM_UTIL }, //
{ "mathUtil", MATH_UTIL }, //
{ "utils", MIXIN_UTILS } //
}, String.class, Object.class));
private static Object createMixin(Class<?>... classes) {
StaticFunctionDelegatorBuilder builder = new StaticFunctionDelegatorBuilder();
builder.setClassLoader(Utils.class.getClassLoader());
for (Class<?> clazz : classes) {
builder.addClass(clazz);
}
return builder.toObject();
}
/**
* 取得包含所有utils的map
*
* @return utils map
*/
public static Map<String, Object> getUtils() {
return ALL_UTILS;
}
}
|
[
"yizhi@taobao.com"
] |
yizhi@taobao.com
|
27284782cb63ac40ac07d155685c98dd0e1b0406
|
c474b03758be154e43758220e47b3403eb7fc1fc
|
/apk/decompiled/com.tinder_2018-07-26_source_from_JADX/sources/com/google/gson/DefaultDateTypeAdapter.java
|
2bf3ee64f02f01cbd9b6f4b36872821f01bf3e2a
|
[] |
no_license
|
EstebanDalelR/tinderAnalysis
|
f80fe1f43b3b9dba283b5db1781189a0dd592c24
|
941e2c634c40e5dbf5585c6876ef33f2a578b65c
|
refs/heads/master
| 2020-04-04T09:03:32.659099
| 2018-11-23T20:41:28
| 2018-11-23T20:41:28
| 155,805,042
| 0
| 0
| null | 2018-11-18T16:02:45
| 2018-11-02T02:44:34
| null |
UTF-8
|
Java
| false
| false
| 5,137
|
java
|
package com.google.gson;
import com.google.gson.stream.JsonReader;
import com.google.gson.stream.JsonToken;
import com.google.gson.stream.JsonWriter;
import java.io.IOException;
import java.sql.Timestamp;
import java.text.DateFormat;
import java.text.SimpleDateFormat;
import java.util.Date;
import java.util.Locale;
final class DefaultDateTypeAdapter extends TypeAdapter<Date> {
private static final String SIMPLE_NAME = "DefaultDateTypeAdapter";
private final Class<? extends Date> dateType;
private final DateFormat enUsFormat;
private final DateFormat localFormat;
DefaultDateTypeAdapter(Class<? extends Date> cls) {
this((Class) cls, DateFormat.getDateTimeInstance(2, 2, Locale.US), DateFormat.getDateTimeInstance(2, 2));
}
DefaultDateTypeAdapter(Class<? extends Date> cls, String str) {
this((Class) cls, new SimpleDateFormat(str, Locale.US), new SimpleDateFormat(str));
}
DefaultDateTypeAdapter(Class<? extends Date> cls, int i) {
this((Class) cls, DateFormat.getDateInstance(i, Locale.US), DateFormat.getDateInstance(i));
}
public DefaultDateTypeAdapter(int i, int i2) {
this(Date.class, DateFormat.getDateTimeInstance(i, i2, Locale.US), DateFormat.getDateTimeInstance(i, i2));
}
public DefaultDateTypeAdapter(Class<? extends Date> cls, int i, int i2) {
this((Class) cls, DateFormat.getDateTimeInstance(i, i2, Locale.US), DateFormat.getDateTimeInstance(i, i2));
}
DefaultDateTypeAdapter(Class<? extends Date> cls, DateFormat dateFormat, DateFormat dateFormat2) {
if (cls == Date.class || cls == java.sql.Date.class || cls == Timestamp.class) {
this.dateType = cls;
this.enUsFormat = dateFormat;
this.localFormat = dateFormat2;
return;
}
dateFormat2 = new StringBuilder();
dateFormat2.append("Date type must be one of ");
dateFormat2.append(Date.class);
dateFormat2.append(", ");
dateFormat2.append(Timestamp.class);
dateFormat2.append(", or ");
dateFormat2.append(java.sql.Date.class);
dateFormat2.append(" but was ");
dateFormat2.append(cls);
throw new IllegalArgumentException(dateFormat2.toString());
}
public void write(JsonWriter jsonWriter, Date date) throws IOException {
if (date == null) {
jsonWriter.nullValue();
return;
}
synchronized (this.localFormat) {
jsonWriter.value(this.enUsFormat.format(date));
}
}
public Date read(JsonReader jsonReader) throws IOException {
if (jsonReader.peek() == JsonToken.NULL) {
jsonReader.nextNull();
return null;
}
jsonReader = deserializeToDate(jsonReader.nextString());
if (this.dateType == Date.class) {
return jsonReader;
}
if (this.dateType == Timestamp.class) {
return new Timestamp(jsonReader.getTime());
}
if (this.dateType == java.sql.Date.class) {
return new java.sql.Date(jsonReader.getTime());
}
throw new AssertionError();
}
private java.util.Date deserializeToDate(java.lang.String r4) {
/* JADX: method processing error */
/*
Error: java.lang.NullPointerException
*/
/*
r3 = this;
r0 = r3.localFormat;
monitor-enter(r0);
r1 = r3.localFormat; Catch:{ ParseException -> 0x000d }
r1 = r1.parse(r4); Catch:{ ParseException -> 0x000d }
monitor-exit(r0); Catch:{ all -> 0x000b }
return r1;
L_0x000b:
r4 = move-exception;
goto L_0x0028;
L_0x000d:
r1 = r3.enUsFormat; Catch:{ ParseException -> 0x0015 }
r1 = r1.parse(r4); Catch:{ ParseException -> 0x0015 }
monitor-exit(r0); Catch:{ all -> 0x000b }
return r1;
L_0x0015:
r1 = new java.text.ParsePosition; Catch:{ ParseException -> 0x0021 }
r2 = 0; Catch:{ ParseException -> 0x0021 }
r1.<init>(r2); Catch:{ ParseException -> 0x0021 }
r1 = com.google.gson.internal.bind.util.ISO8601Utils.parse(r4, r1); Catch:{ ParseException -> 0x0021 }
monitor-exit(r0); Catch:{ all -> 0x000b }
return r1; Catch:{ all -> 0x000b }
L_0x0021:
r1 = move-exception; Catch:{ all -> 0x000b }
r2 = new com.google.gson.JsonSyntaxException; Catch:{ all -> 0x000b }
r2.<init>(r4, r1); Catch:{ all -> 0x000b }
throw r2; Catch:{ all -> 0x000b }
L_0x0028:
monitor-exit(r0); Catch:{ all -> 0x000b }
throw r4;
*/
throw new UnsupportedOperationException("Method not decompiled: com.google.gson.DefaultDateTypeAdapter.deserializeToDate(java.lang.String):java.util.Date");
}
public String toString() {
StringBuilder stringBuilder = new StringBuilder();
stringBuilder.append(SIMPLE_NAME);
stringBuilder.append('(');
stringBuilder.append(this.localFormat.getClass().getSimpleName());
stringBuilder.append(')');
return stringBuilder.toString();
}
}
|
[
"jdguzmans@hotmail.com"
] |
jdguzmans@hotmail.com
|
9de31d6d8c66ca3f9714f51f0fb23a2c66f2ef5d
|
75604d83db3d7c6e783a54097687a1bb9d1be338
|
/src/BaekJoon/P1773.java
|
5b46267b1efea758795dbb6680c045cfe041cb85
|
[] |
no_license
|
nn98/Algorithm
|
262cbe20c71ff9b5de292c244b95a2a0c25e5bd7
|
c1999a8ef3bfc1370abee56c0597c286a1cb81af
|
refs/heads/master
| 2023-08-17T04:39:41.236707
| 2022-09-07T06:22:56
| 2022-09-07T06:22:56
| 178,701,901
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 378
|
java
|
package BaekJoon;
import java.util.Scanner;
public class P1773 {
public static void main(String[] args) {
Scanner s=new Scanner(System.in);
int n=s.nextInt(),m=s.nextInt(),r=0;
boolean[]a=new boolean[m+1];
for(int i=0;i<n;i++) {
int t=s.nextInt(),j=t;
for(;j<=m;j+=t)
a[j]=true;
}
for(boolean c:a)if(c)r++;
System.out.print(r);
}
}
|
[
"jkllhgb@gmail.com"
] |
jkllhgb@gmail.com
|
be521ab82a7ca45185dc776601a6372ed6614a69
|
8bb41fec534588900fec81383df4032263626086
|
/app/src/main/java/com/example/arttower/Frame/Token.java
|
186d16a118591ec6be2d95add695d1ab6c94f7d2
|
[] |
no_license
|
zsq-sq/zrttower
|
39819e105c1b0f892217be3c0501601588d518bc
|
c6d679e6ba736ea46a76645375e123f07531a426
|
refs/heads/master
| 2022-12-16T19:05:08.909926
| 2020-09-14T11:56:07
| 2020-09-14T11:56:07
| 295,399,098
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 811
|
java
|
package com.example.arttower.Frame;
import android.util.Log;
import com.example.arttower.Frame.BaseToken;
import com.example.arttower.local_utils.SharedPrefrenceUtils;
//存储信息
public class Token extends BaseToken {
private static String cookie;
private static String COOKIE = "Set-Cookie";
public static String getCookie() {
if (!"".equals(cookie) && cookie != null) {
Log.e("cookie", "getCookie: "+cookie );
return cookie;
} else {
cookie = SharedPrefrenceUtils.getString(BaseToken.getContext(), Token.COOKIE, "");
return cookie;
}
}
public static void setCookie(String cookie) {
Token.cookie = cookie;
SharedPrefrenceUtils.saveString(BaseToken.getContext(),Token.COOKIE,cookie);
}
}
|
[
"floveandroid@sina.com"
] |
floveandroid@sina.com
|
fbf79842617577dc0c7ee4470ce41562ea5487c8
|
0a67a01e9a29b3fcde6d97988c15738b17a9d1c3
|
/server/src/main/java/io/github/cloudiator/rest/api/DecryptionApi.java
|
eabe4f7605685592de50e78bee14e76a4d4842e6
|
[
"Apache-2.0"
] |
permissive
|
cloudiator/rest-server
|
710ced3213030d546f1dfd7211e92f5bc8ea81e3
|
48f4269b04c0eb9ca4f6d18b9ccbe32f32edf349
|
refs/heads/master
| 2022-03-12T01:02:03.250212
| 2020-01-13T09:44:26
| 2020-01-13T09:44:26
| 91,566,694
| 0
| 1
|
Apache-2.0
| 2022-02-09T23:23:47
| 2017-05-17T11:00:26
|
Java
|
UTF-8
|
Java
| false
| false
| 1,652
|
java
|
/**
* NOTE: This class is auto generated by the swagger code generator program (2.4.0-SNAPSHOT).
* https://github.com/swagger-api/swagger-codegen
* Do not edit the class manually.
*/
package io.github.cloudiator.rest.api;
import io.github.cloudiator.rest.model.Text;
import io.swagger.annotations.*;
import org.springframework.http.ResponseEntity;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestHeader;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RequestPart;
import org.springframework.web.multipart.MultipartFile;
import javax.validation.Valid;
import javax.validation.constraints.*;
import java.util.List;
@Api(value = "decryption", description = "the decryption API")
public interface DecryptionApi {
@ApiOperation(value = "", nickname = "decrypt", notes = "Decrypts the given string", response = Text.class, authorizations = {
@Authorization(value = "ApiKeyAuth")
}, tags={ "security", })
@ApiResponses(value = {
@ApiResponse(code = 200, message = "OK", response = Text.class) })
@RequestMapping(value = "/decryption/{text}",
produces = { "application/json" },
method = RequestMethod.GET)
ResponseEntity<Text> decrypt(@ApiParam(value = "Text to decrypt",required=true) @PathVariable("text") String text);
}
|
[
"daniel.baur@uni-ulm.de"
] |
daniel.baur@uni-ulm.de
|
cdd7083dc87635150dacf78467991591faa8f2ac
|
bc9dbe2e47c6194223d8eb2a0a6dae966359d8a7
|
/android/app/src/main/java/com/gonevertical/chatterbox/AnalyticsTrackers.java
|
18527bd76d9ea9bf1d0d2db4345a1673e999d433
|
[] |
no_license
|
jessk1801/chatterbox
|
feb4ff7dd91d7bdf3bea62b8f04261a9a186f1d9
|
4e0aa9f061bc6e83006ad5e7865f6d009e8ec6a6
|
refs/heads/master
| 2021-03-01T06:14:37.841010
| 2016-06-17T05:55:41
| 2016-06-17T05:55:41
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 1,990
|
java
|
package com.gonevertical.chatterbox;
import android.content.Context;
import com.google.android.gms.analytics.GoogleAnalytics;
import com.google.android.gms.analytics.Tracker;
import java.util.HashMap;
import java.util.Map;
/**
* A collection of Google Analytics trackers. Fetch the tracker you need using
* {@code AnalyticsTrackers.getInstance().get(...)}
* <p/>
* This code was generated by Android Studio but can be safely modified by
* hand at this point.
* <p/>
* TODO: Call {@link #initialize(Context)} from an entry point in your app
* before using this!
*/
public final class AnalyticsTrackers {
public enum Target {
APP,
// Add more trackers here if you need, and update the code in #get(Target) below
}
private static AnalyticsTrackers sInstance;
public static synchronized void initialize(Context context) {
if (sInstance != null) {
throw new IllegalStateException("Extra call to initialize analytics trackers");
}
sInstance = new AnalyticsTrackers(context);
}
public static synchronized AnalyticsTrackers getInstance() {
if (sInstance == null) {
throw new IllegalStateException("Call initialize() before getInstance()");
}
return sInstance;
}
private final Map<Target, Tracker> mTrackers = new HashMap<Target, Tracker>();
private final Context mContext;
/**
* Don't instantiate directly - use {@link #getInstance()} instead.
*/
private AnalyticsTrackers(Context context) {
mContext = context.getApplicationContext();
}
public synchronized Tracker get(Target target) {
if (!mTrackers.containsKey(target)) {
Tracker tracker;
switch (target) {
case APP:
tracker = GoogleAnalytics.getInstance(mContext).newTracker(R.xml.app_tracker);
break;
default:
throw new IllegalArgumentException("Unhandled analytics target " + target);
}
mTrackers.put(target, tracker);
}
return mTrackers.get(target);
}
}
|
[
"branflake2267@gmail.com"
] |
branflake2267@gmail.com
|
4e018d42bae4da6205cdba36d986f5c14f2c0263
|
6e57bdc0a6cd18f9f546559875256c4570256c45
|
/packages/apps/Bluetooth/src/com/android/bluetooth/mapclient/obex/RequestPushMessage.java
|
bc109392ac3f848baff28bb1b40523f920fd5fcc
|
[] |
no_license
|
dongdong331/test
|
969d6e945f7f21a5819cd1d5f536d12c552e825c
|
2ba7bcea4f9d9715cbb1c4e69271f7b185a0786e
|
refs/heads/master
| 2023-03-07T06:56:55.210503
| 2020-12-07T04:15:33
| 2020-12-07T04:15:33
| 134,398,935
| 2
| 1
| null | 2022-11-21T07:53:41
| 2018-05-22T10:26:42
| null |
UTF-8
|
Java
| false
| false
| 2,704
|
java
|
/*
* Copyright (C) 2014 The Android Open Source Project
*
* 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://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 com.android.bluetooth.mapclient;
import com.android.bluetooth.mapclient.MasClient.CharsetType;
import java.io.IOException;
import java.math.BigInteger;
import javax.obex.ClientSession;
import javax.obex.HeaderSet;
import javax.obex.ResponseCodes;
/* Place a message into current directory on MSE. */
final class RequestPushMessage extends Request {
private static final String TYPE = "x-bt/message";
private Bmessage mMsg;
private String mMsgHandle;
private RequestPushMessage(String folder) {
mHeaderSet.setHeader(HeaderSet.TYPE, TYPE);
if (folder == null) {
folder = "";
}
mHeaderSet.setHeader(HeaderSet.NAME, folder);
}
RequestPushMessage(String folder, Bmessage msg, CharsetType charset, boolean transparent,
boolean retry) {
this(folder);
mMsg = msg;
ObexAppParameters oap = new ObexAppParameters();
oap.add(OAP_TAGID_TRANSPARENT, transparent ? TRANSPARENT_ON : TRANSPARENT_OFF);
oap.add(OAP_TAGID_RETRY, retry ? RETRY_ON : RETRY_OFF);
oap.add(OAP_TAGID_CHARSET, charset == CharsetType.NATIVE ? CHARSET_NATIVE : CHARSET_UTF8);
oap.addToHeaderSet(mHeaderSet);
}
@Override
protected void readResponseHeaders(HeaderSet headerset) {
try {
String handle = (String) headerset.getHeader(HeaderSet.NAME);
if (handle != null) {
/* just to validate */
new BigInteger(handle, 16);
mMsgHandle = handle;
}
} catch (NumberFormatException e) {
mResponseCode = ResponseCodes.OBEX_HTTP_INTERNAL_ERROR;
} catch (IOException e) {
mResponseCode = ResponseCodes.OBEX_HTTP_INTERNAL_ERROR;
}
}
public Bmessage getBMsg() {
return mMsg;
}
public String getMsgHandle() {
return mMsgHandle;
}
@Override
public void execute(ClientSession session) throws IOException {
executePut(session, BmessageBuilder.createBmessage(mMsg).getBytes());
}
}
|
[
"dongdong331@163.com"
] |
dongdong331@163.com
|
f96894f48bfaab9215611340452bc5bf4eb79c9c
|
03a901383633a1eb34eb43aafe4eeb5860fa63cb
|
/taotaoparent/taotao-content/taotao-content-interface/src/main/java/com/taotao/content/service/ContentCategoryService.java
|
b2def61eb01b96ffc275cbcb2d52aa5d29eb3545
|
[] |
no_license
|
TaoWang4446/taotao
|
71b53175900cfe4cc8323654941326bb6b9fac33
|
6bff3dee7269f7f56787968374c67761dcbf8140
|
refs/heads/master
| 2020-03-23T00:09:01.168577
| 2018-07-13T13:05:37
| 2018-07-13T13:05:37
| 140,847,174
| 1
| 1
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 320
|
java
|
package com.taotao.content.service;
import java.util.List;
import com.taotao.common.pojo.EasyUITreeNode;
import com.taotao.common.pojo.TaotaoResult;
public interface ContentCategoryService {
List<EasyUITreeNode> getContentCategoryList(long parentId);
TaotaoResult addContentCategory(Long parentId, String name);
}
|
[
"2825586682@qq.com"
] |
2825586682@qq.com
|
1140d2efe1199891f9222321c7b2fa91ffa91381
|
604e715c03b75cd33d3795b1fb652b501a84c6d1
|
/Mobile App/HeartRateMonitor/sources/com/google/appinventor/components/common/ScreenAnimation.java
|
ceb2bf78d1af959bef20a249f8209579520ba563
|
[] |
no_license
|
aish21/CE3002-Sensors-Lab
|
902ad691acd208e30e47a40c799bfcb5731bfc86
|
eb0c9cf0f3d3a9b5d63336057ff95c0a00ec3507
|
refs/heads/main
| 2023-08-18T19:25:04.338391
| 2021-10-11T08:21:57
| 2021-10-11T08:21:57
| 415,335,117
| 1
| 1
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 863
|
java
|
package com.google.appinventor.components.common;
import java.util.HashMap;
import java.util.Map;
public enum ScreenAnimation implements OptionList<String> {
Default("default"),
Fade("fade"),
Zoom("zoom"),
SlideHorizontal("slidehorizontal"),
SlideVertical("slidevertical"),
None("none");
private static final Map<String, ScreenAnimation> lookup = null;
private final String value;
static {
int i;
lookup = new HashMap();
for (ScreenAnimation anim : values()) {
lookup.put(anim.toUnderlyingValue(), anim);
}
}
private ScreenAnimation(String anim) {
this.value = anim;
}
public String toUnderlyingValue() {
return this.value;
}
public static ScreenAnimation fromUnderlyingValue(String anim) {
return lookup.get(anim);
}
}
|
[
"aish.akshu@gmail.com"
] |
aish.akshu@gmail.com
|
50d1593c1412f95641b0752e637df36be16f9878
|
f766baf255197dd4c1561ae6858a67ad23dcda68
|
/app/src/main/java/com/jg/Level.java
|
fc9d4040e1f320a4cde3b5bd9298f3d4d767f2ea
|
[] |
no_license
|
jianghan200/wxsrc6.6.7
|
d83f3fbbb77235c7f2c8bc945fa3f09d9bac3849
|
eb6c56587cfca596f8c7095b0854cbbc78254178
|
refs/heads/master
| 2020-03-19T23:40:49.532494
| 2018-06-12T06:00:50
| 2018-06-12T06:00:50
| 137,015,278
| 4
| 2
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 375
|
java
|
package com.jg;
public class Level
{
public static final int LEVEL_HIGH = 2;
public static final int LEVEL_LOW = 0;
public static final int LEVEL_NORMAL = 1;
}
/* Location: /Users/Han/Desktop/wxall/微信反编译/反编译 6.6.7/dex2jar-2.0/classes5-dex2jar.jar!/com/jg/Level.class
* Java compiler version: 6 (50.0)
* JD-Core Version: 0.7.1
*/
|
[
"526687570@qq.com"
] |
526687570@qq.com
|
610182b5fe16dd92989c3e1708c66d3fb25b576b
|
705879dc61c41198fb2c4f4f6328bba190c8a465
|
/src/main/java/org/virtualbox/IMachineGetAccelerate2DVideoEnabledResponse.java
|
b4d611bb5e59278776f97f9cf859063f06187248
|
[] |
no_license
|
abiquo/hypervisor-mock
|
dcd1d6c8a2fdbc4db01c7a6e9a64edd101e8ed42
|
e49e4ca84930415eca72ab6c73140a0f2eea4bbe
|
refs/heads/master
| 2021-01-19T09:40:57.840712
| 2013-08-23T08:54:17
| 2013-08-23T08:54:17
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 1,286
|
java
|
package org.virtualbox;
import javax.xml.bind.annotation.XmlAccessType;
import javax.xml.bind.annotation.XmlAccessorType;
import javax.xml.bind.annotation.XmlRootElement;
import javax.xml.bind.annotation.XmlType;
/**
* <p>Java class for anonymous complex type.
*
* <p>The following schema fragment specifies the expected content contained within this class.
*
* <pre>
* <complexType>
* <complexContent>
* <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
* <sequence>
* <element name="returnval" type="{http://www.w3.org/2001/XMLSchema}boolean"/>
* </sequence>
* </restriction>
* </complexContent>
* </complexType>
* </pre>
*
*
*/
@XmlAccessorType(XmlAccessType.FIELD)
@XmlType(name = "", propOrder = {
"returnval"
})
@XmlRootElement(name = "IMachine_getAccelerate2DVideoEnabledResponse")
public class IMachineGetAccelerate2DVideoEnabledResponse {
protected boolean returnval;
/**
* Gets the value of the returnval property.
*
*/
public boolean isReturnval() {
return returnval;
}
/**
* Sets the value of the returnval property.
*
*/
public void setReturnval(boolean value) {
this.returnval = value;
}
}
|
[
"serafin.sedano@abiquo.com"
] |
serafin.sedano@abiquo.com
|
700a8b5f770343cef664f1d1c976940f3d342a17
|
f8dd489b1eb1c33b7151eeadaddeeda47e09c243
|
/app/src/main/java/project/astix/com/ltfoodsfaindirect/DeletePic.java
|
524658a19abcd1406ea83f8b42697e364b16c2f3
|
[] |
no_license
|
AstixIntelligenceManagementSystem/LTFoodSFAIndirect
|
681e5ce2b98a9cfa427560a18dbfa1c4c64de547
|
fcc96f4784fd72eb085ea0c76418bc6d536fd5fd
|
refs/heads/master
| 2020-03-17T17:55:08.151816
| 2019-02-04T13:05:22
| 2019-02-04T13:05:22
| 133,807,649
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 223
|
java
|
package project.astix.com.ltfoodsfaindirect;
import android.graphics.Bitmap;
public interface DeletePic {
public void delPic(Bitmap bmp, String imageName);
public void getProductPhotoDetail(String productIdTag);
}
|
[
"astixset2@gmail.com"
] |
astixset2@gmail.com
|
4fa5886d1f0e4878336dcbb644e49b44aab25c1b
|
6d60a8adbfdc498a28f3e3fef70366581aa0c5fd
|
/codebase/default/80413.java
|
6fdfe51422e3f58e5591a69499ef45504abfa5db
|
[] |
no_license
|
rayhan-ferdous/code2vec
|
14268adaf9022d140a47a88129634398cd23cf8f
|
c8ca68a7a1053d0d09087b14d4c79a189ac0cf00
|
refs/heads/master
| 2022-03-09T08:40:18.035781
| 2022-02-27T23:57:44
| 2022-02-27T23:57:44
| 140,347,552
| 0
| 1
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 4,500
|
java
|
import coopnetclient.Client;
import coopnetclient.Globals;
import coopnetclient.enums.LogTypes;
import coopnetclient.utils.Logger;
import coopnetclient.utils.Settings;
import java.io.File;
import java.io.IOException;
import javax.swing.JOptionPane;
public class Main {
public static void main(String[] args) {
try {
System.getProperty("os.name");
} catch (SecurityException e) {
JOptionPane.showMessageDialog(null, "An error occured while trying to detect your operating system!" + "\nPlease make sure that your security policy in java is not set too tight." + "\nException message: " + e.getLocalizedMessage(), "ERROR", JOptionPane.ERROR_MESSAGE);
System.exit(1);
}
Globals.detectOperatingSystem();
checkArgs(args);
Globals.init();
Logger.log(LogTypes.LOG, "Starting ...");
cleanUpdater();
Client.startup();
}
private static void checkArgs(String[] args) {
for (int i = 0; i < args.length; i++) {
if (args[i].equals("--safemode")) {
Settings.resetSettings();
break;
}
}
for (int i = 0; i < args.length; i++) {
if (args[i].equals("--safemode")) {
continue;
} else if (args[i].equals("--server")) {
if (args.length < i + 1 || args[i].indexOf(":") == -1) {
try {
String ip = args[i + 1].substring(0, args[i + 1].indexOf(":"));
Globals.setServerIP(ip);
int port = Integer.parseInt(args[i + 1].substring(args[i + 1].indexOf(":") + 1));
Globals.setServerPort(port);
i++;
} catch (NumberFormatException e) {
System.out.println("ERROR: invalid value for <PORT>, number expected");
} catch (java.lang.StringIndexOutOfBoundsException e) {
System.out.println("ERROR: invalid value for <PORT>, number expected");
}
} else {
System.out.println("ERROR: --server expects data in the form of \"127.0.0.1:6667\"");
printHelp();
}
} else if (args[i].equals("--debug")) {
Globals.enableDebug();
} else if (args[i].equals("--help")) {
printHelp();
} else {
printHelp();
}
}
}
private static void printHelp() {
System.out.println("\nCoopnetClient " + Globals.CLIENT_VERSION + " usage:\n" + " java -jar CoopnetClient.jar [--server <IP>:<PORT>] [--debug]\n" + "\n" + " --safemode resets all settings\n" + " --server ip and port of the server to connect to\n" + " --debug print debug messages during operation\n" + " --help print this help and exit\n");
System.exit(1);
}
private static void cleanUpdater() {
final File tmpDir = new File("./UPDATER_TMP");
final File updaterFile = new File("./CoopnetUpdater.jar");
if (tmpDir.exists() || updaterFile.exists()) {
Logger.log(LogTypes.LOG, "Updater files queued for deletion ...");
new Thread() {
@Override
public void run() {
try {
sleep(10);
} catch (InterruptedException ex) {
}
try {
if (tmpDir.exists()) {
Logger.log(LogTypes.LOG, "Deleting ./UPDATER_TMP recursively");
deleteFile(tmpDir);
}
} catch (IOException e) {
}
try {
if (updaterFile.exists()) {
Logger.log(LogTypes.LOG, "Deleting ./CoopnetUpdater.jar");
deleteFile(updaterFile);
}
} catch (IOException e) {
}
}
}.start();
}
}
private static boolean deleteFile(File resource) throws IOException {
if (resource.isDirectory()) {
File[] childFiles = resource.listFiles();
for (File child : childFiles) {
deleteFile(child);
}
}
return resource.delete();
}
}
|
[
"aaponcseku@gmail.com"
] |
aaponcseku@gmail.com
|
27b3ebce77c63175851663249473e2752cd9950e
|
7d28d457ababf1b982f32a66a8896b764efba1e8
|
/platform-pojo-bl/src/main/java/ua/com/fielden/platform/sample/domain/ITgAuthorship.java
|
4277d42c3d9687e5ee2b53cc7276c5df6d9046cf
|
[
"MIT"
] |
permissive
|
fieldenms/tg
|
f742f332343f29387e0cb7a667f6cf163d06d101
|
f145a85a05582b7f26cc52d531de9835f12a5e2d
|
refs/heads/develop
| 2023-08-31T16:10:16.475974
| 2023-08-30T08:23:18
| 2023-08-30T08:23:18
| 20,488,386
| 17
| 9
|
MIT
| 2023-09-14T17:07:35
| 2014-06-04T15:09:44
|
JavaScript
|
UTF-8
|
Java
| false
| false
| 265
|
java
|
package ua.com.fielden.platform.sample.domain;
import ua.com.fielden.platform.dao.IEntityDao;
/**
* Companion object constract for entity {@link TgAuthorship}.
*
* @author Developers
*
*/
public interface ITgAuthorship extends IEntityDao<TgAuthorship> {
}
|
[
"oles.hodych@gmail.com"
] |
oles.hodych@gmail.com
|
9477c2498e9b9e42c9924b808d234e0434f3c6b0
|
f38d8e69234d6004086c832f7b2265fabed8fba4
|
/src/main/java/com/jeecg/trafficaccident/service/TrafficAccidentServiceI.java
|
625773d7423f0fe0cbf920ae0cde787be3a8c482
|
[] |
no_license
|
qpy1992/20180626
|
befd1eae204b741b7e5dbc46027163efe301a49c
|
ebf8dfefc4676ddd2f58b964c74eaff6f51f38af
|
refs/heads/master
| 2020-04-04T08:46:11.980490
| 2018-11-02T09:02:42
| 2018-11-02T09:02:42
| 155,793,891
| 1
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 494
|
java
|
package com.jeecg.trafficaccident.service;
import com.jeecg.trafficaccident.entity.TrafficAccidentEntity;
import org.jeecgframework.core.common.service.CommonService;
import java.io.Serializable;
public interface TrafficAccidentServiceI extends CommonService{
public void delete(TrafficAccidentEntity entity) throws Exception;
public Serializable save(TrafficAccidentEntity entity) throws Exception;
public void saveOrUpdate(TrafficAccidentEntity entity) throws Exception;
}
|
[
"794429910@qq.com"
] |
794429910@qq.com
|
d8ad708f5f5f074e9cb81bd13c043d67775ccb83
|
2fbb920555d82dc6fdadc129749acf6c632fb7d4
|
/gdsap-framework/src/main/java/uk/co/quidos/gdsap/framework/authority/services/impl/AppCopy.java
|
12fb35eb3d29863dffa24b266a0c2ffe5ecaa682
|
[
"Apache-2.0"
] |
permissive
|
ZhangPeng1990/crm
|
3cd31b6a121418c47032979354af0886a236a0cf
|
c5b176718924c024a13cc6ceccb2e737e70cedd3
|
refs/heads/master
| 2020-06-05T18:25:41.600112
| 2015-04-29T10:38:01
| 2015-04-29T10:38:01
| 34,787,517
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 1,545
|
java
|
package uk.co.quidos.gdsap.framework.authority.services.impl;
import java.lang.reflect.Field;
import java.util.ArrayList;
/**
* @author peng.shi
*
*/
public class AppCopy
{
public static void main(String[] args) throws SecurityException, ClassNotFoundException
{
String class2 = "uk.co.quidos.gdsap.framework.authority.persistence.object.AdminDO";// 输出类路径,返回值
String class1 = "uk.co.quidos.gdsap.framework.authority.Admin";// 读取类路径,参数
String name1[] = class1.split("\\.");
String cname1 = name1[name1.length - 1];
cname1 = cname1.substring(0,1).toLowerCase() + cname1.substring(1);
String name2[] = class2.split("\\.");
String cname2 = name2[name2.length - 1];
cname2 = cname2.substring(0,1).toLowerCase() + cname2.substring(1);
Field[] fds1 = Class.forName(class1).getDeclaredFields();
Field[] fds2 = Class.forName(class2).getDeclaredFields();
ArrayList<String> a = new ArrayList<String>();
for (int i = 0; i < fds2.length; i++)
{
a.add(fds2[i].getName());
}
for (int i = 0; i < fds1.length; i++)
{
String flname = fds1[i].getName();
String fname = toFirstUpper(fds1[i].getName());
if (a.contains(flname))
{
if (fname.indexOf("SerialVersionUID") == -1)
{
System.out.println(cname1 + ".set" + fname + "(" + cname2 + ".get" + fname + "());");
}
}
}
}
private static String toFirstUpper(String s)
{
String s1 = s.substring(0, 1).toUpperCase() + s.substring(1);
return s1;
}
}
|
[
"peng.zhang@argylesoftware.co.uk"
] |
peng.zhang@argylesoftware.co.uk
|
abca6cafb87a96f90b9c56e1812fa190cbd8806b
|
c885ef92397be9d54b87741f01557f61d3f794f3
|
/tests-without-trycatch/Mockito-19/org.mockito.internal.configuration.injection.filter.TypeBasedCandidateFilter/default/22/org/mockito/internal/configuration/injection/filter/TypeBasedCandidateFilter_ESTest_scaffolding.java
|
0e5e0d2feead1cbe340df253c45253e69ce1511b
|
[
"CC-BY-4.0",
"MIT"
] |
permissive
|
pderakhshanfar/EMSE-BBC-experiment
|
f60ac5f7664dd9a85f755a00a57ec12c7551e8c6
|
fea1a92c2e7ba7080b8529e2052259c9b697bbda
|
refs/heads/main
| 2022-11-25T00:39:58.983828
| 2022-04-12T16:04:26
| 2022-04-12T16:04:26
| 309,335,889
| 0
| 1
| null | 2021-11-05T11:18:43
| 2020-11-02T10:30:38
| null |
UTF-8
|
Java
| false
| false
| 7,711
|
java
|
/**
* Scaffolding file used to store all the setups needed to run
* tests automatically generated by EvoSuite
* Fri Jul 30 14:39:38 GMT 2021
*/
package org.mockito.internal.configuration.injection.filter;
import org.evosuite.runtime.annotation.EvoSuiteClassExclude;
import org.junit.BeforeClass;
import org.junit.Before;
import org.junit.After;
import org.junit.AfterClass;
import org.evosuite.runtime.sandbox.Sandbox;
import org.evosuite.runtime.sandbox.Sandbox.SandboxMode;
@EvoSuiteClassExclude
public class TypeBasedCandidateFilter_ESTest_scaffolding {
@org.junit.Rule
public org.evosuite.runtime.vnet.NonFunctionalRequirementRule nfr = new org.evosuite.runtime.vnet.NonFunctionalRequirementRule();
private static final java.util.Properties defaultProperties = (java.util.Properties) java.lang.System.getProperties().clone();
private org.evosuite.runtime.thread.ThreadStopper threadStopper = new org.evosuite.runtime.thread.ThreadStopper (org.evosuite.runtime.thread.KillSwitchHandler.getInstance(), 3000);
@BeforeClass
public static void initEvoSuiteFramework() {
org.evosuite.runtime.RuntimeSettings.className = "org.mockito.internal.configuration.injection.filter.TypeBasedCandidateFilter";
org.evosuite.runtime.GuiSupport.initialize();
org.evosuite.runtime.RuntimeSettings.maxNumberOfThreads = 100;
org.evosuite.runtime.RuntimeSettings.maxNumberOfIterationsPerLoop = 10000;
org.evosuite.runtime.RuntimeSettings.mockSystemIn = true;
org.evosuite.runtime.RuntimeSettings.sandboxMode = org.evosuite.runtime.sandbox.Sandbox.SandboxMode.RECOMMENDED;
org.evosuite.runtime.sandbox.Sandbox.initializeSecurityManagerForSUT();
org.evosuite.runtime.classhandling.JDKClassResetter.init();
setSystemProperties();
initializeClasses();
org.evosuite.runtime.Runtime.getInstance().resetRuntime();
}
@AfterClass
public static void clearEvoSuiteFramework(){
Sandbox.resetDefaultSecurityManager();
java.lang.System.setProperties((java.util.Properties) defaultProperties.clone());
}
@Before
public void initTestCase(){
threadStopper.storeCurrentThreads();
threadStopper.startRecordingTime();
org.evosuite.runtime.jvm.ShutdownHookHandler.getInstance().initHandler();
org.evosuite.runtime.sandbox.Sandbox.goingToExecuteSUTCode();
setSystemProperties();
org.evosuite.runtime.GuiSupport.setHeadless();
org.evosuite.runtime.Runtime.getInstance().resetRuntime();
org.evosuite.runtime.agent.InstrumentingAgent.activate();
}
@After
public void doneWithTestCase(){
threadStopper.killAndJoinClientThreads();
org.evosuite.runtime.jvm.ShutdownHookHandler.getInstance().safeExecuteAddedHooks();
org.evosuite.runtime.classhandling.JDKClassResetter.reset();
resetClasses();
org.evosuite.runtime.sandbox.Sandbox.doneWithExecutingSUTCode();
org.evosuite.runtime.agent.InstrumentingAgent.deactivate();
org.evosuite.runtime.GuiSupport.restoreHeadlessMode();
}
public static void setSystemProperties() {
java.lang.System.setProperties((java.util.Properties) defaultProperties.clone());
java.lang.System.setProperty("user.dir", "/experiment");
java.lang.System.setProperty("java.io.tmpdir", "/tmp");
}
private static void initializeClasses() {
org.evosuite.runtime.classhandling.ClassStateSupport.initializeClasses(TypeBasedCandidateFilter_ESTest_scaffolding.class.getClassLoader() ,
"org.mockito.internal.configuration.injection.filter.FinalMockCandidateFilter$2",
"org.mockito.internal.configuration.injection.filter.TypeBasedCandidateFilter",
"org.mockito.internal.configuration.injection.filter.OngoingInjecter",
"org.mockito.internal.configuration.injection.filter.FinalMockCandidateFilter",
"org.mockito.internal.configuration.injection.filter.MockCandidateFilter"
);
}
private static void resetClasses() {
org.evosuite.runtime.classhandling.ClassResetter.getInstance().setClassLoader(TypeBasedCandidateFilter_ESTest_scaffolding.class.getClassLoader());
org.evosuite.runtime.classhandling.ClassStateSupport.resetClasses(
"org.mockito.internal.configuration.injection.filter.TypeBasedCandidateFilter",
"org.mockito.internal.configuration.injection.filter.FinalMockCandidateFilter",
"org.mockito.internal.configuration.injection.filter.NameBasedCandidateFilter",
"org.mockito.internal.configuration.plugins.PluginRegistry",
"org.mockito.internal.configuration.plugins.PluginLoader",
"org.mockito.internal.configuration.plugins.DefaultPluginSwitch",
"org.mockito.internal.configuration.plugins.PluginFinder",
"org.mockito.internal.util.collections.Iterables",
"org.mockito.internal.creation.bytebuddy.ByteBuddyMockMaker",
"org.mockito.internal.creation.bytebuddy.CachingMockBytecodeGenerator",
"org.mockito.internal.creation.bytebuddy.MockBytecodeGenerator",
"net.bytebuddy.ByteBuddy",
"net.bytebuddy.ClassFileVersion",
"net.bytebuddy.utility.ByteBuddyCommons",
"net.bytebuddy.NamingStrategy$Unbound$Default",
"net.bytebuddy.implementation.auxiliary.AuxiliaryType$NamingStrategy$SuffixingRandom",
"net.bytebuddy.utility.RandomString",
"net.bytebuddy.matcher.FilterableList$Empty",
"net.bytebuddy.description.type.TypeList$Empty",
"net.bytebuddy.matcher.ElementMatchers",
"net.bytebuddy.matcher.ElementMatcher$Junction$AbstractBase",
"net.bytebuddy.matcher.NameMatcher",
"net.bytebuddy.matcher.StringMatcher",
"net.bytebuddy.matcher.StringMatcher$Mode",
"net.bytebuddy.matcher.MethodParameterMatcher",
"net.bytebuddy.matcher.CollectionSizeMatcher",
"net.bytebuddy.matcher.ElementMatcher$Junction$Conjunction",
"net.bytebuddy.description.ModifierReviewable$AbstractModifierReviewable",
"net.bytebuddy.description.type.TypeDescription$AbstractTypeDescription",
"net.bytebuddy.description.type.TypeDescription$ForLoadedType",
"net.bytebuddy.matcher.EqualityMatcher",
"net.bytebuddy.matcher.MethodReturnTypeMatcher",
"net.bytebuddy.matcher.DeclaringTypeMatcher",
"net.bytebuddy.matcher.ModifierMatcher",
"net.bytebuddy.matcher.ModifierMatcher$Mode",
"net.bytebuddy.matcher.MethodSortMatcher",
"net.bytebuddy.matcher.MethodSortMatcher$Sort",
"net.bytebuddy.matcher.NegatingMatcher",
"net.bytebuddy.matcher.ElementMatcher$Junction$Disjunction",
"net.bytebuddy.dynamic.scaffold.BridgeMethodResolver$Simple$ConflictHandler$Default",
"net.bytebuddy.dynamic.scaffold.BridgeMethodResolver$Simple$Factory",
"net.bytebuddy.asm.ClassVisitorWrapper$Chain",
"net.bytebuddy.dynamic.scaffold.MethodRegistry$Default",
"net.bytebuddy.ByteBuddy$Definable$Undefined",
"net.bytebuddy.implementation.attribute.TypeAttributeAppender$NoOp",
"net.bytebuddy.dynamic.scaffold.MethodLookupEngine$Default$Factory",
"net.bytebuddy.implementation.attribute.FieldAttributeAppender$NoOp",
"net.bytebuddy.implementation.attribute.MethodAttributeAppender$NoOp",
"net.bytebuddy.implementation.attribute.MethodAttributeAppender$ForInstrumentedMethod",
"net.bytebuddy.implementation.attribute.TypeAttributeAppender$ForSuperType",
"org.mockito.internal.exceptions.stacktrace.DefaultStackTraceCleanerProvider",
"org.mockito.internal.configuration.plugins.Plugins",
"org.mockito.internal.util.MockUtil",
"org.mockito.internal.configuration.injection.filter.FinalMockCandidateFilter$2",
"org.mockito.internal.configuration.injection.filter.FinalMockCandidateFilter$1"
);
}
}
|
[
"pouria.derakhshanfar@gmail.com"
] |
pouria.derakhshanfar@gmail.com
|
85376ef980ce2129c82ee8d34806164d58a44bba
|
88223fcec3030c77cc70af4516a251b7744e3560
|
/2.Multidimentional Arrays/src/MatrixShuffling.java
|
a20d18be03b9292e94ec49a8c4d2b18f4d901b13
|
[] |
no_license
|
aarabadjieva/SoftUni-Java-Advanced
|
2f8fb25840d2cf47702d0b931886df85f2dc2d7a
|
e2828404005e672432ed7d395d238ca0a3a36f9a
|
refs/heads/master
| 2022-05-12T10:34:39.727189
| 2020-04-28T11:17:12
| 2020-04-28T11:17:12
| 259,614,875
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 2,510
|
java
|
import java.util.Arrays;
import java.util.Scanner;
public class MatrixShuffling {
public static void main(String[] args) {
Scanner scanner = new Scanner(System.in);
int[] size = Arrays.stream(scanner.nextLine().split(" "))
.mapToInt(Integer::parseInt)
.toArray();
int rows = size[0];
int cols = size[1];
String[][] matrix = new String[rows][cols];
matrix = readMatrix(rows,scanner,matrix);
String[] cmd = scanner.nextLine().split(" ");
while (!cmd[0].equals("END")){
boolean isValid = checkCmd(cmd,rows,cols);
if (isValid){
int row1 = Integer.parseInt(cmd[1]);
int col1 = Integer.parseInt(cmd[2]);
int row2 = Integer.parseInt(cmd[3]);
int col2 = Integer.parseInt(cmd[4]);
matrix = swapMatrix(matrix, row1, col1,row2,col2);
printMatrix(matrix);
}else{
System.out.println("Invalid input!");
}
cmd = scanner.nextLine().split(" ");
}
}
private static void printMatrix(String[][] matrix) {
for (int row = 0; row < matrix.length; row++) {
for (int col = 0; col < matrix[0].length; col++) {
System.out.print(matrix[row][col] + " ");
}
System.out.println();
}
}
private static String[][] swapMatrix(String[][] matrix, int row1, int col1, int row2, int col2) {
String temp = matrix[row1][col1];
matrix[row1][col1] = matrix[row2][col2];
matrix[row2][col2] = temp;
return matrix;
}
private static boolean checkCmd(String[] cmd, int rows, int cols) {
if(cmd.length<5||cmd.length>5){
return false;
}else if (!cmd[0].equals("swap")){
return false;
}else if (Integer.parseInt(cmd[1])<0||Integer.parseInt(cmd[1])>=rows||Integer.parseInt(cmd[2])<0
||Integer.parseInt(cmd[2])>=cols||Integer.parseInt(cmd[3])<0|| Integer.parseInt(cmd[3])>=rows
||Integer.parseInt(cmd[4])<0||Integer.parseInt(cmd[4])>=cols){
return false;
}
return true;
}
private static String[][] readMatrix(int rows, Scanner scanner, String[][] matrix) {
for (int row = 0; row < rows; row++) {
String[] input = scanner.nextLine().split(" ");
matrix[row] = input;
}
return matrix;
}
}
|
[
"l.i.n@abv.bg"
] |
l.i.n@abv.bg
|
577a529059a6e2a60a3d65ed87fad5904a48428a
|
78b7c12de8829261f533014fe2c01282b548165c
|
/src/main/java/org/censorship/config/CloudDatabaseConfiguration.java
|
161683b9b86580ab9dc7279e472303245a271531
|
[] |
no_license
|
monjurmorshed793/CensorshipDetector
|
4c55c001ea4df11a5e28d11e64cd608ebe2214fd
|
ac2f1bb5f04b9aba9161584bffd98a5b0a3060f6
|
refs/heads/master
| 2020-04-28T22:41:24.092690
| 2019-03-26T18:30:46
| 2019-03-26T18:30:46
| 175,626,631
| 0
| 0
| null | 2019-03-25T20:24:25
| 2019-03-14T13:22:14
|
Java
|
UTF-8
|
Java
| false
| false
| 931
|
java
|
package org.censorship.config;
import io.github.jhipster.config.JHipsterConstants;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.cloud.config.java.AbstractCloudConfig;
import org.springframework.context.annotation.*;
import javax.sql.DataSource;
import org.springframework.boot.context.properties.ConfigurationProperties;
@Configuration
@Profile(JHipsterConstants.SPRING_PROFILE_CLOUD)
public class CloudDatabaseConfiguration extends AbstractCloudConfig {
private final Logger log = LoggerFactory.getLogger(CloudDatabaseConfiguration.class);
private static final String CLOUD_CONFIGURATION_HIKARI_PREFIX = "spring.datasource.hikari";
@Bean
@ConfigurationProperties(CLOUD_CONFIGURATION_HIKARI_PREFIX)
public DataSource dataSource() {
log.info("Configuring JDBC datasource from a cloud provider");
return connectionFactory().dataSource();
}
}
|
[
"monjurmorshed793@gmail.com"
] |
monjurmorshed793@gmail.com
|
a206bc668ab26f03c190884fa39cc74e782e18a2
|
b741741c827a0420e125078d154ae0a160a9ef15
|
/redstonegang-wire/src/main/java/dev/feldmann/redstonegang/wire/game/base/addonconfigs/db/DefaultCatalog.java
|
2d916c0f7aea8a8975e61ecb818bcebe816c32ca
|
[] |
no_license
|
net32/redstonegang
|
f2da0630980f1b25e520b72721785d1e0064dc6d
|
73e7f9b3800116489eefdf869b1df004273d05b4
|
refs/heads/master
| 2023-03-10T01:56:02.206043
| 2021-02-14T17:38:37
| 2021-02-14T17:38:37
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| true
| 1,375
|
java
|
/*
* This file is generated by jOOQ.
*/
package dev.feldmann.redstonegang.wire.game.base.addonconfigs.db;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.List;
import javax.annotation.Generated;
import org.jooq.Schema;
import org.jooq.impl.CatalogImpl;
/**
* This class is generated by jOOQ.
*/
@Generated(
value = {
"http://www.jooq.org",
"jOOQ version:3.11.7"
},
comments = "This class is generated by jOOQ"
)
@SuppressWarnings({ "all", "unchecked", "rawtypes" })
public class DefaultCatalog extends CatalogImpl {
private static final long serialVersionUID = -1793267248;
/**
* The reference redstonegang of <code></code>
*/
public static final DefaultCatalog DEFAULT_CATALOG = new DefaultCatalog();
/**
* The schema <code>redstonegang_common</code>.
*/
public final RedstonegangCommon REDSTONEGANG_COMMON = RedstonegangCommon.REDSTONEGANG_COMMON;
/**
* No further instances allowed
*/
private DefaultCatalog() {
super("");
}
@Override
public final List<Schema> getSchemas() {
List result = new ArrayList();
result.addAll(getSchemas0());
return result;
}
private final List<Schema> getSchemas0() {
return Arrays.<Schema>asList(
RedstonegangCommon.REDSTONEGANG_COMMON);
}
}
|
[
"feldmannjunior@gmail.com"
] |
feldmannjunior@gmail.com
|
79648462a547923198fdf110771a76d4649aca83
|
c8c949b3710fbb4b983d03697ec9173a0ad3f79f
|
/src/Arrays/MaximumAverageSubarrayI.java
|
8a85598ca652b563c9a38ca4e6efdc9ee9b89df3
|
[] |
no_license
|
mxx626/myleet
|
ae4409dec30d81eaaef26518cdf52a75fd3810bc
|
5da424b2f09342947ba6a9fffb1cca31b7101cf0
|
refs/heads/master
| 2020-03-22T15:11:07.145406
| 2018-07-09T05:12:28
| 2018-07-09T05:12:28
| 140,234,151
| 2
| 1
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 1,355
|
java
|
package Arrays;
// TAG: Array
public class MaximumAverageSubarrayI {
/**
* Given an array consisting of n integers, find the contiguous subarray of given length k
* that has the maximum average value. And you need to output the maximum average value.
Example 1:
Input: [1,12,-5,-6,50,3], k = 4
Output: 12.75
Explanation: Maximum average is (12-5-6+50)/4 = 51/4 = 12.75
Note:
1 <= k <= n <= 30,000.
Elements of the given array will be in the range [-10,000, 10,000].
* @param nums
* @param k
* @return
*/
public double findMaxAverage(int[] nums, int k) {
double max=0.0, sum=0.0;
for (int i=0; i<k; ++i){
sum+=nums[i];
}
max=sum;
for (int i=k; i<nums.length; ++i){
sum += nums[i]-nums[i-k];
if (sum>max) max=sum;
}
return max/k;
}
public double findMaxAverage2(int[] nums, int k) {
Double res = null;
int[] sum = new int[nums.length+1];
for (int i=0; i<nums.length; ++i) sum[i+1]=sum[i]+nums[i];
for (int i=k; i<sum.length; ++i){
if (res==null) res = (double)(sum[i]-sum[i-k])/k;
else res = Math.max(res, (double)(sum[i]-sum[i-k])/k);
}
return res;
}
}
|
[
"mxx626@outlook.com"
] |
mxx626@outlook.com
|
8e1d070b635b43797a7892ff89076b29b0bbb35b
|
d534b1da383456c7608b9e93697139521c9551b0
|
/src/main/java/com/food/manager/config/LocaleConfiguration.java
|
c014b7aa7ff99358b76a8a58aab02a057c29f782
|
[] |
no_license
|
Sp0ky/jhipsterOnlineFoodManager
|
f6ba9eb9eb0bf7e4cc7dfb33845742610be495a4
|
29c15243833a0d873464929ebbdc17b616c4947c
|
refs/heads/master
| 2021-04-28T20:59:37.167082
| 2018-02-18T10:33:01
| 2018-02-18T10:33:01
| 121,941,710
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 1,390
|
java
|
package com.food.manager.config;
import io.github.jhipster.config.locale.AngularCookieLocaleResolver;
import org.springframework.context.EnvironmentAware;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.core.env.Environment;
import org.springframework.web.servlet.LocaleResolver;
import org.springframework.web.servlet.config.annotation.InterceptorRegistry;
import org.springframework.web.servlet.config.annotation.WebMvcConfigurerAdapter;
import org.springframework.web.servlet.i18n.LocaleChangeInterceptor;
@Configuration
public class LocaleConfiguration extends WebMvcConfigurerAdapter implements EnvironmentAware {
@Override
public void setEnvironment(Environment environment) {
// unused
}
@Bean(name = "localeResolver")
public LocaleResolver localeResolver() {
AngularCookieLocaleResolver cookieLocaleResolver = new AngularCookieLocaleResolver();
cookieLocaleResolver.setCookieName("NG_TRANSLATE_LANG_KEY");
return cookieLocaleResolver;
}
@Override
public void addInterceptors(InterceptorRegistry registry) {
LocaleChangeInterceptor localeChangeInterceptor = new LocaleChangeInterceptor();
localeChangeInterceptor.setParamName("language");
registry.addInterceptor(localeChangeInterceptor);
}
}
|
[
"jhipster-bot@users.noreply.github.com"
] |
jhipster-bot@users.noreply.github.com
|
5407e343c8a8400bd46d04645219aedd093840ec
|
c885ef92397be9d54b87741f01557f61d3f794f3
|
/tests-without-trycatch/Gson-10/com.google.gson.internal.bind.ReflectiveTypeAdapterFactory/BBC-F0-opt-80/10/com/google/gson/internal/bind/ReflectiveTypeAdapterFactory_ESTest.java
|
690a1d9c2e44bf0b41a9d424c2baecd5577f4ef8
|
[
"CC-BY-4.0",
"MIT"
] |
permissive
|
pderakhshanfar/EMSE-BBC-experiment
|
f60ac5f7664dd9a85f755a00a57ec12c7551e8c6
|
fea1a92c2e7ba7080b8529e2052259c9b697bbda
|
refs/heads/main
| 2022-11-25T00:39:58.983828
| 2022-04-12T16:04:26
| 2022-04-12T16:04:26
| 309,335,889
| 0
| 1
| null | 2021-11-05T11:18:43
| 2020-11-02T10:30:38
| null |
UTF-8
|
Java
| false
| false
| 6,276
|
java
|
/*
* This file was automatically generated by EvoSuite
* Thu Oct 14 02:31:07 GMT 2021
*/
package com.google.gson.internal.bind;
import org.junit.Test;
import static org.junit.Assert.*;
import static org.evosuite.runtime.EvoAssertions.*;
import com.google.gson.FieldNamingPolicy;
import com.google.gson.FieldNamingStrategy;
import com.google.gson.Gson;
import com.google.gson.internal.ConstructorConstructor;
import com.google.gson.internal.Excluder;
import com.google.gson.internal.ObjectConstructor;
import com.google.gson.internal.bind.ReflectiveTypeAdapterFactory;
import com.google.gson.reflect.TypeToken;
import com.google.gson.stream.JsonReader;
import java.io.CharArrayWriter;
import java.io.IOException;
import java.io.StringReader;
import java.lang.reflect.Field;
import java.lang.reflect.Type;
import java.util.HashMap;
import java.util.Map;
import org.evosuite.runtime.EvoRunner;
import org.evosuite.runtime.EvoRunnerParameters;
import org.junit.runner.RunWith;
@RunWith(EvoRunner.class) @EvoRunnerParameters(mockJVMNonDeterminism = true, useVFS = true, useVNET = true, resetStaticState = true, separateClassLoader = true)
public class ReflectiveTypeAdapterFactory_ESTest extends ReflectiveTypeAdapterFactory_ESTest_scaffolding {
@Test(timeout = 4000)
public void test0() throws Throwable {
ReflectiveTypeAdapterFactory.Adapter<Object> reflectiveTypeAdapterFactory_Adapter0 = new ReflectiveTypeAdapterFactory.Adapter<Object>((ObjectConstructor<Object>) null, (Map<String, ReflectiveTypeAdapterFactory.BoundField>) null);
Gson gson0 = new Gson();
StringReader stringReader0 = new StringReader("lTuL9*6|Lz");
JsonReader jsonReader0 = gson0.newJsonReader(stringReader0);
// try {
reflectiveTypeAdapterFactory_Adapter0.read(jsonReader0);
// fail("Expecting exception: IOException");
// } catch(IOException e) {
// //
// // Use JsonReader.setLenient(true) to accept malformed JSON at line 1 column 1 path $
// //
// verifyException("com.google.gson.stream.JsonReader", e);
// }
}
@Test(timeout = 4000)
public void test1() throws Throwable {
Excluder excluder0 = Excluder.DEFAULT;
// Undeclared exception!
// try {
ReflectiveTypeAdapterFactory.excludeField((Field) null, false, excluder0);
// fail("Expecting exception: NullPointerException");
// } catch(NullPointerException e) {
// //
// // no message in exception (getMessage() returned null)
// //
// verifyException("com.google.gson.internal.bind.ReflectiveTypeAdapterFactory", e);
// }
}
@Test(timeout = 4000)
public void test2() throws Throwable {
Gson gson0 = new Gson();
Excluder excluder0 = gson0.excluder();
ReflectiveTypeAdapterFactory reflectiveTypeAdapterFactory0 = new ReflectiveTypeAdapterFactory((ConstructorConstructor) null, (FieldNamingStrategy) null, excluder0);
Class<Object> class0 = Object.class;
TypeToken<Object> typeToken0 = TypeToken.get(class0);
// Undeclared exception!
// try {
reflectiveTypeAdapterFactory0.create(gson0, typeToken0);
// fail("Expecting exception: NullPointerException");
// } catch(NullPointerException e) {
// //
// // no message in exception (getMessage() returned null)
// //
// verifyException("com.google.gson.internal.bind.ReflectiveTypeAdapterFactory", e);
// }
}
@Test(timeout = 4000)
public void test3() throws Throwable {
HashMap<String, ReflectiveTypeAdapterFactory.BoundField> hashMap0 = new HashMap<String, ReflectiveTypeAdapterFactory.BoundField>();
ReflectiveTypeAdapterFactory.Adapter<Integer> reflectiveTypeAdapterFactory_Adapter0 = new ReflectiveTypeAdapterFactory.Adapter<Integer>((ObjectConstructor<Integer>) null, hashMap0);
String string0 = reflectiveTypeAdapterFactory_Adapter0.toJson((Integer) null);
assertEquals("null", string0);
}
@Test(timeout = 4000)
public void test4() throws Throwable {
Gson gson0 = new Gson();
Class<Type> class0 = Type.class;
// Undeclared exception!
// try {
gson0.fromJson("com.google.gson.internal.bind.ReflectiveTypeAdapterFactory", class0);
// fail("Expecting exception: RuntimeException");
// } catch(RuntimeException e) {
// //
// // Unable to invoke no-args constructor for interface java.lang.reflect.Type. Register an InstanceCreator with Gson for this type may fix this problem.
// //
// verifyException("com.google.gson.internal.ConstructorConstructor$14", e);
// }
}
@Test(timeout = 4000)
public void test5() throws Throwable {
Gson gson0 = new Gson();
CharArrayWriter charArrayWriter0 = new CharArrayWriter(1246);
gson0.toJson((Object) charArrayWriter0, (Appendable) charArrayWriter0);
assertEquals(5920, charArrayWriter0.size());
}
@Test(timeout = 4000)
public void test6() throws Throwable {
HashMap<String, ReflectiveTypeAdapterFactory.BoundField> hashMap0 = new HashMap<String, ReflectiveTypeAdapterFactory.BoundField>();
ReflectiveTypeAdapterFactory.Adapter<Integer> reflectiveTypeAdapterFactory_Adapter0 = new ReflectiveTypeAdapterFactory.Adapter<Integer>((ObjectConstructor<Integer>) null, hashMap0);
Integer integer0 = reflectiveTypeAdapterFactory_Adapter0.fromJson("null");
assertNull(integer0);
}
@Test(timeout = 4000)
public void test7() throws Throwable {
FieldNamingPolicy fieldNamingPolicy0 = FieldNamingPolicy.UPPER_CAMEL_CASE;
Excluder excluder0 = new Excluder();
ReflectiveTypeAdapterFactory reflectiveTypeAdapterFactory0 = new ReflectiveTypeAdapterFactory((ConstructorConstructor) null, fieldNamingPolicy0, excluder0);
// Undeclared exception!
// try {
reflectiveTypeAdapterFactory0.excludeField((Field) null, false);
// fail("Expecting exception: NullPointerException");
// } catch(NullPointerException e) {
// //
// // no message in exception (getMessage() returned null)
// //
// verifyException("com.google.gson.internal.bind.ReflectiveTypeAdapterFactory", e);
// }
}
}
|
[
"pouria.derakhshanfar@gmail.com"
] |
pouria.derakhshanfar@gmail.com
|
bc73d65eed669aaad7fb76a19ae9fdd790d1f136
|
7249c7b4508ce9c0a11a78d73044767eb26e32a9
|
/app/src/main/java/com/roka/ticketing/rest/response/flight/helperpojo/listbooking/Others.java
|
4d5194802235894d4ec17201083f3910eb2e2aef
|
[] |
no_license
|
multimedioplus/Proyek-RNI-Kereta-Api
|
d9961941776676a0ca003770738d82ef03928c1e
|
42ecb0d9c4cbe03c7d4d898cf52fda50c8dc90ce
|
refs/heads/master
| 2020-03-24T02:27:45.416659
| 2018-07-26T03:18:38
| 2018-07-26T03:18:38
| 142,376,662
| 0
| 1
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 499
|
java
|
package com.roka.ticketing.rest.response.flight.helperpojo.listbooking;
import javax.annotation.Generated;
import com.google.gson.annotations.SerializedName;
@Generated("com.robohorse.robopojogenerator")
public class Others{
@SerializedName("value")
private String value;
public void setValue(String value){
this.value = value;
}
public String getValue(){
return value;
}
@Override
public String toString(){
return
"Others{" +
"value = '" + value + '\'' +
"}";
}
}
|
[
"nikkoeka04@gmail.com"
] |
nikkoeka04@gmail.com
|
ee5c8a3938f63a09dddd1d462a6dc69c4d5ce075
|
e0b6551f88d12a68dd1eb6811aa5abb7ba3fce37
|
/draw-service/src/main/java/com/wyc/draw/service/BattleModelStageIndexService.java
|
e353303d1846a2450dc87693dab87bd8611a09de
|
[] |
no_license
|
wangyuchuan12/luck-draw
|
ecef2eccb757fbf95eb74244f179498d9e0d04a8
|
a8f4e45c5690e80cdfc3e1ffe3879eba9a66599f
|
refs/heads/master
| 2021-01-12T05:03:40.772785
| 2017-08-21T09:28:14
| 2017-08-21T09:28:14
| 77,839,368
| 0
| 1
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 580
|
java
|
package com.wyc.draw.service;
import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.wyc.draw.domain.BattleModelStageIndex;
import com.wyc.draw.repositories.BattleModelStageIndexRepository;
@Service
public class BattleModelStageIndexService {
@Autowired
private BattleModelStageIndexRepository battleModelStageIndexRepository;
public List<BattleModelStageIndex> findAllByBattleModelId(String modelId) {
return battleModelStageIndexRepository.findAllByBattleModelId(modelId);
}
}
|
[
"root@dawang.local"
] |
root@dawang.local
|
b03b118f51fccc86ca8945643022f2d6d27a40a5
|
8f0b4cb270c8dfb72f03d25f439dd0f50bbd1b7c
|
/JobAdminX/src/main/java/com/stylefeng/guns/config/web/ShiroConfig.java
|
84c7eca3fbdd85c3d55c20d95713cf9f281c0588
|
[] |
no_license
|
hadenxx/ScheduleCenter
|
b6121511fb925f047fa3414657bc008c846ac6b3
|
9870ade202d858d931fe3369669403e8404fe6c4
|
refs/heads/master
| 2020-09-23T19:11:41.594603
| 2019-05-22T16:04:54
| 2019-05-22T16:04:54
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 6,765
|
java
|
package com.stylefeng.guns.config.web;
import com.stylefeng.guns.config.properties.GunsProperties;
import com.stylefeng.guns.core.shiro.ShiroDbRealm;
import org.apache.shiro.cache.CacheManager;
import org.apache.shiro.cache.ehcache.EhCacheManager;
import org.apache.shiro.codec.Base64;
import org.apache.shiro.spring.LifecycleBeanPostProcessor;
import org.apache.shiro.spring.security.interceptor.AuthorizationAttributeSourceAdvisor;
import org.apache.shiro.spring.web.ShiroFilterFactoryBean;
import org.apache.shiro.web.mgt.CookieRememberMeManager;
import org.apache.shiro.web.mgt.DefaultWebSecurityManager;
import org.apache.shiro.web.servlet.Cookie;
import org.apache.shiro.web.servlet.ShiroHttpSession;
import org.apache.shiro.web.servlet.SimpleCookie;
import org.apache.shiro.web.session.mgt.DefaultWebSessionManager;
import org.springframework.aop.framework.autoproxy.DefaultAdvisorAutoProxyCreator;
import org.springframework.beans.factory.config.MethodInvokingFactoryBean;
import org.springframework.cache.ehcache.EhCacheManagerFactoryBean;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.annotation.DependsOn;
import java.util.HashMap;
import java.util.Map;
/**
* shiro权限管理的配置
*
* @author fengshuonan
* @date 2016年11月14日 下午3:03:44
*/
@Configuration
public class ShiroConfig {
/**
* 安全管理器
*/
@Bean
public DefaultWebSecurityManager securityManager(CookieRememberMeManager rememberMeManager, CacheManager cacheShiroManager, DefaultWebSessionManager defaultWebSessionManager) {
DefaultWebSecurityManager securityManager = new DefaultWebSecurityManager();
securityManager.setRealm(this.shiroDbRealm());
securityManager.setCacheManager(cacheShiroManager);
securityManager.setRememberMeManager(rememberMeManager);
securityManager.setSessionManager(defaultWebSessionManager);
return securityManager;
}
/**
* session管理器
*/
@Bean
public DefaultWebSessionManager defaultWebSessionManager(CacheManager cacheShiroManager, GunsProperties gunsProperties) {
DefaultWebSessionManager sessionManager = new DefaultWebSessionManager();
sessionManager.setCacheManager(cacheShiroManager);
sessionManager.setSessionValidationInterval(gunsProperties.getSessionValidationInterval() * 1000);
sessionManager.setGlobalSessionTimeout(gunsProperties.getSessionInvalidateTime() * 1000);
sessionManager.setDeleteInvalidSessions(true);
sessionManager.setSessionValidationSchedulerEnabled(true);
Cookie cookie = new SimpleCookie(ShiroHttpSession.DEFAULT_SESSION_ID_NAME);
cookie.setName("shiroCookie");
cookie.setHttpOnly(true);
sessionManager.setSessionIdCookie(cookie);
return sessionManager;
}
/**
* 缓存管理器 使用Ehcache实现
*/
@Bean
public CacheManager getCacheShiroManager(EhCacheManagerFactoryBean ehcache) {
EhCacheManager ehCacheManager = new EhCacheManager();
ehCacheManager.setCacheManager(ehcache.getObject());
return ehCacheManager;
}
/**
* 项目自定义的Realm
*/
@Bean
public ShiroDbRealm shiroDbRealm() {
return new ShiroDbRealm();
}
/**
* rememberMe管理器, cipherKey生成见{@code Base64Test.java}
*/
@Bean
public CookieRememberMeManager rememberMeManager(SimpleCookie rememberMeCookie) {
CookieRememberMeManager manager = new CookieRememberMeManager();
manager.setCipherKey(Base64.decode("Z3VucwAAAAAAAAAAAAAAAA=="));
manager.setCookie(rememberMeCookie);
return manager;
}
/**
* 记住密码Cookie
*/
@Bean
public SimpleCookie rememberMeCookie() {
SimpleCookie simpleCookie = new SimpleCookie("rememberMe");
simpleCookie.setHttpOnly(true);
simpleCookie.setMaxAge(7 * 24 * 60 * 60);//7天
return simpleCookie;
}
/**
* Shiro的过滤器链
*/
@Bean
public ShiroFilterFactoryBean shiroFilter(DefaultWebSecurityManager securityManager) {
ShiroFilterFactoryBean shiroFilter = new ShiroFilterFactoryBean();
shiroFilter.setSecurityManager(securityManager);
/**
* 默认的登陆访问url
*/
shiroFilter.setLoginUrl("/login");
/**
* 登陆成功后跳转的url
*/
shiroFilter.setSuccessUrl("/");
/**
* 没有权限跳转的url
*/
shiroFilter.setUnauthorizedUrl("/global/error");
/**
* 配置shiro拦截器链
*
* anon 不需要认证
* authc 需要认证
* user 验证通过或RememberMe登录的都可以
*
*/
Map<String, String> hashMap = new HashMap<>();
hashMap.put("/static/**", "anon");
hashMap.put("/login", "anon");
hashMap.put("/global/sessionError", "anon");
hashMap.put("/kaptcha", "anon");
hashMap.put("/job/list", "anon");
hashMap.put("/appList/get/list", "anon");
hashMap.put("/jobList/get/list", "anon");
hashMap.put("/**", "user");
shiroFilter.setFilterChainDefinitionMap(hashMap);
return shiroFilter;
}
/**
* 在方法中 注入 securityManager,进行代理控制
*/
@Bean
public MethodInvokingFactoryBean methodInvokingFactoryBean(DefaultWebSecurityManager securityManager) {
MethodInvokingFactoryBean bean = new MethodInvokingFactoryBean();
bean.setStaticMethod("org.apache.shiro.SecurityUtils.setSecurityManager");
bean.setArguments(new Object[]{securityManager});
return bean;
}
/**
* 保证实现了Shiro内部lifecycle函数的bean执行
*/
@Bean
public LifecycleBeanPostProcessor lifecycleBeanPostProcessor() {
return new LifecycleBeanPostProcessor();
}
/**
* 启用shrio授权注解拦截方式,AOP式方法级权限检查
*/
@Bean
@DependsOn(value = "lifecycleBeanPostProcessor") //依赖其他bean的初始化
public DefaultAdvisorAutoProxyCreator defaultAdvisorAutoProxyCreator() {
return new DefaultAdvisorAutoProxyCreator();
}
@Bean
public AuthorizationAttributeSourceAdvisor authorizationAttributeSourceAdvisor(DefaultWebSecurityManager securityManager) {
AuthorizationAttributeSourceAdvisor authorizationAttributeSourceAdvisor =
new AuthorizationAttributeSourceAdvisor();
authorizationAttributeSourceAdvisor.setSecurityManager(securityManager);
return authorizationAttributeSourceAdvisor;
}
}
|
[
"20207075@qq.com"
] |
20207075@qq.com
|
68e200f174c8e971b662213da88643a56ae7cfff
|
7707b1d1d63198e86a0b8a7ae27c00e2f27a8831
|
/model/com.netxforge.netxscript/src-gen/com/netxforge/netxscript/impl/UnequalImpl.java
|
b00aa9ce222e5775fe6cab04d45ecf4a92cd132e
|
[] |
no_license
|
dzonekl/netxstudio
|
20535f66e5bbecd1cdd9c55a4d691fc48a1a83aa
|
f12c118b1ef08fe770e5ac29828653a93fea9352
|
refs/heads/master
| 2016-08-04T17:28:38.486076
| 2015-10-02T16:20:00
| 2015-10-02T16:20:00
| 6,561,565
| 2
| 0
| null | 2014-10-27T06:49:59
| 2012-11-06T12:18:44
|
Java
|
UTF-8
|
Java
| false
| false
| 6,631
|
java
|
/**
* <copyright>
* </copyright>
*
*/
package com.netxforge.netxscript.impl;
import com.netxforge.netxscript.Expression;
import com.netxforge.netxscript.NetxscriptPackage;
import com.netxforge.netxscript.Unequal;
import org.eclipse.emf.common.notify.Notification;
import org.eclipse.emf.common.notify.NotificationChain;
import org.eclipse.emf.ecore.EClass;
import org.eclipse.emf.ecore.InternalEObject;
import org.eclipse.emf.ecore.impl.ENotificationImpl;
/**
* <!-- begin-user-doc -->
* An implementation of the model object '<em><b>Unequal</b></em>'.
* <!-- end-user-doc -->
* <p>
* The following features are implemented:
* <ul>
* <li>{@link com.netxforge.netxscript.impl.UnequalImpl#getLeft <em>Left</em>}</li>
* <li>{@link com.netxforge.netxscript.impl.UnequalImpl#getRight <em>Right</em>}</li>
* </ul>
* </p>
*
* @generated
*/
public class UnequalImpl extends ExpressionImpl implements Unequal
{
/**
* The cached value of the '{@link #getLeft() <em>Left</em>}' containment reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @see #getLeft()
* @generated
* @ordered
*/
protected Expression left;
/**
* The cached value of the '{@link #getRight() <em>Right</em>}' containment reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @see #getRight()
* @generated
* @ordered
*/
protected Expression right;
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
protected UnequalImpl()
{
super();
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
@Override
protected EClass eStaticClass()
{
return NetxscriptPackage.Literals.UNEQUAL;
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public Expression getLeft()
{
return left;
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public NotificationChain basicSetLeft(Expression newLeft, NotificationChain msgs)
{
Expression oldLeft = left;
left = newLeft;
if (eNotificationRequired())
{
ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, NetxscriptPackage.UNEQUAL__LEFT, oldLeft, newLeft);
if (msgs == null) msgs = notification; else msgs.add(notification);
}
return msgs;
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public void setLeft(Expression newLeft)
{
if (newLeft != left)
{
NotificationChain msgs = null;
if (left != null)
msgs = ((InternalEObject)left).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - NetxscriptPackage.UNEQUAL__LEFT, null, msgs);
if (newLeft != null)
msgs = ((InternalEObject)newLeft).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - NetxscriptPackage.UNEQUAL__LEFT, null, msgs);
msgs = basicSetLeft(newLeft, msgs);
if (msgs != null) msgs.dispatch();
}
else if (eNotificationRequired())
eNotify(new ENotificationImpl(this, Notification.SET, NetxscriptPackage.UNEQUAL__LEFT, newLeft, newLeft));
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public Expression getRight()
{
return right;
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public NotificationChain basicSetRight(Expression newRight, NotificationChain msgs)
{
Expression oldRight = right;
right = newRight;
if (eNotificationRequired())
{
ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, NetxscriptPackage.UNEQUAL__RIGHT, oldRight, newRight);
if (msgs == null) msgs = notification; else msgs.add(notification);
}
return msgs;
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public void setRight(Expression newRight)
{
if (newRight != right)
{
NotificationChain msgs = null;
if (right != null)
msgs = ((InternalEObject)right).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - NetxscriptPackage.UNEQUAL__RIGHT, null, msgs);
if (newRight != null)
msgs = ((InternalEObject)newRight).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - NetxscriptPackage.UNEQUAL__RIGHT, null, msgs);
msgs = basicSetRight(newRight, msgs);
if (msgs != null) msgs.dispatch();
}
else if (eNotificationRequired())
eNotify(new ENotificationImpl(this, Notification.SET, NetxscriptPackage.UNEQUAL__RIGHT, newRight, newRight));
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
@Override
public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs)
{
switch (featureID)
{
case NetxscriptPackage.UNEQUAL__LEFT:
return basicSetLeft(null, msgs);
case NetxscriptPackage.UNEQUAL__RIGHT:
return basicSetRight(null, msgs);
}
return super.eInverseRemove(otherEnd, featureID, msgs);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
@Override
public Object eGet(int featureID, boolean resolve, boolean coreType)
{
switch (featureID)
{
case NetxscriptPackage.UNEQUAL__LEFT:
return getLeft();
case NetxscriptPackage.UNEQUAL__RIGHT:
return getRight();
}
return super.eGet(featureID, resolve, coreType);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
@Override
public void eSet(int featureID, Object newValue)
{
switch (featureID)
{
case NetxscriptPackage.UNEQUAL__LEFT:
setLeft((Expression)newValue);
return;
case NetxscriptPackage.UNEQUAL__RIGHT:
setRight((Expression)newValue);
return;
}
super.eSet(featureID, newValue);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
@Override
public void eUnset(int featureID)
{
switch (featureID)
{
case NetxscriptPackage.UNEQUAL__LEFT:
setLeft((Expression)null);
return;
case NetxscriptPackage.UNEQUAL__RIGHT:
setRight((Expression)null);
return;
}
super.eUnset(featureID);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
@Override
public boolean eIsSet(int featureID)
{
switch (featureID)
{
case NetxscriptPackage.UNEQUAL__LEFT:
return left != null;
case NetxscriptPackage.UNEQUAL__RIGHT:
return right != null;
}
return super.eIsSet(featureID);
}
} //UnequalImpl
|
[
"dzonekl@gmail.com"
] |
dzonekl@gmail.com
|
d54cf559e4830a4d1dc879b1b120a9fa34300726
|
53d677a55e4ece8883526738f1c9d00fa6560ff7
|
/com/tencent/mm/ui/bizchat/BizChatConversationUI$BizChatConversationFmUI$10.java
|
3b8722ead4c948d25737ff732d7777da10a7f681
|
[] |
no_license
|
0jinxing/wechat-apk-source
|
544c2d79bfc10261eb36389c1edfdf553d8f312a
|
f75eefd87e9b9ecf2f76fc6d48dbba8e24afcf3d
|
refs/heads/master
| 2020-06-07T20:06:03.580028
| 2019-06-21T09:17:26
| 2019-06-21T09:17:26
| 193,069,132
| 9
| 4
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 2,131
|
java
|
package com.tencent.mm.ui.bizchat;
import android.database.Cursor;
import com.tencent.matrix.trace.core.AppMethodBeat;
import com.tencent.mm.aj.a.a;
import com.tencent.mm.aj.a.b;
import com.tencent.mm.aj.a.c;
import com.tencent.mm.aj.a.d;
import com.tencent.mm.aj.a.h;
import com.tencent.mm.aj.z;
import com.tencent.mm.sdk.platformtools.ab;
import java.util.LinkedList;
final class BizChatConversationUI$BizChatConversationFmUI$10
implements Runnable
{
BizChatConversationUI$BizChatConversationFmUI$10(BizChatConversationUI.BizChatConversationFmUI paramBizChatConversationFmUI)
{
}
public final void run()
{
AppMethodBeat.i(30067);
ab.i("MicroMsg.BizChatConversationFmUI", "updateChatInfoFromSvr");
LinkedList localLinkedList1 = new LinkedList();
LinkedList localLinkedList2 = new LinkedList();
Cursor localCursor = z.aeU().rn(BizChatConversationUI.BizChatConversationFmUI.a(this.yEp));
if (localCursor.moveToFirst())
while (!localCursor.isAfterLast())
{
Object localObject = new a();
((a)localObject).d(localCursor);
localCursor.moveToNext();
localObject = z.aeT().aK(((a)localObject).field_bizChatId);
if (((c)localObject).afh())
if (((c)localObject).isGroup())
localLinkedList2.add(((c)localObject).field_bizChatServId);
else
localLinkedList1.add(((c)localObject).field_bizChatServId);
}
localCursor.close();
if (localLinkedList2.size() > 0)
z.aeZ().a(localLinkedList2, BizChatConversationUI.BizChatConversationFmUI.a(this.yEp));
BizChatConversationUI.BizChatConversationFmUI.a(this.yEp, localLinkedList1);
if (localLinkedList1.size() > 0)
z.aeZ().b(localLinkedList1, BizChatConversationUI.BizChatConversationFmUI.a(this.yEp));
AppMethodBeat.o(30067);
}
}
/* Location: C:\Users\Lin\Downloads\dex-tools-2.1-SNAPSHOT\dex-tools-2.1-SNAPSHOT\classes7-dex2jar.jar
* Qualified Name: com.tencent.mm.ui.bizchat.BizChatConversationUI.BizChatConversationFmUI.10
* JD-Core Version: 0.6.2
*/
|
[
"172601673@qq.com"
] |
172601673@qq.com
|
7d3aabbb7cab3091e6d0287f94e5c4c199e65112
|
2f4a058ab684068be5af77fea0bf07665b675ac0
|
/app/com/facebook/orca/server/module/MessagesServiceModule$OrcaServiceHandlerForZeroTokenProvider.java
|
d1756ad62f4a344cbadf5b34f0070eb4c3709de4
|
[] |
no_license
|
cengizgoren/facebook_apk_crack
|
ee812a57c746df3c28fb1f9263ae77190f08d8d2
|
a112d30542b9f0bfcf17de0b3a09c6e6cfe1273b
|
refs/heads/master
| 2021-05-26T14:44:04.092474
| 2013-01-16T08:39:00
| 2013-01-16T08:39:00
| 8,321,708
| 1
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 774
|
java
|
package com.facebook.orca.server.module;
import com.facebook.orca.inject.AbstractProvider;
import com.facebook.orca.server.OrcaServiceHandler;
import com.facebook.zero.ZeroTokenHandler;
class MessagesServiceModule$OrcaServiceHandlerForZeroTokenProvider extends AbstractProvider<OrcaServiceHandler>
{
private MessagesServiceModule$OrcaServiceHandlerForZeroTokenProvider(MessagesServiceModule paramMessagesServiceModule)
{
}
public OrcaServiceHandler a()
{
return (OrcaServiceHandler)b(ZeroTokenHandler.class);
}
}
/* Location: /data1/software/jd-gui/com.facebook.katana_2.0_liqucn.com-dex2jar.jar
* Qualified Name: com.facebook.orca.server.module.MessagesServiceModule.OrcaServiceHandlerForZeroTokenProvider
* JD-Core Version: 0.6.0
*/
|
[
"macluz@msn.com"
] |
macluz@msn.com
|
23b4d18f3a5c675caea7d9682c6ac33e80143355
|
a89200e50a30b6fc07d300a14eaf81ecce6c75ce
|
/builder/RomizerShell.java
|
a08fe2674a7f6db51261dcbd6cbe955bd5f44dec
|
[] |
no_license
|
dougxc/SquawkVM
|
d54b5cad63cacaa14570b07048b0ee6a7d507885
|
da46a90c5c2c7e46b0c9ba26339ff29f6aa1a83c
|
refs/heads/master
| 2022-12-26T07:46:32.598567
| 2020-09-29T09:54:49
| 2020-09-29T09:54:49
| 299,574,927
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 1,332
|
java
|
import java.awt.*;
import java.awt.event.*;
import java.io.*;
import java.util.*;
import javax.swing.*;
import javax.swing.event.*;
public class RomizerShell extends GuiShell {
Option[] options;
Command[] commands;
RomizerShell() {
options = new Option[] {
new Option("image", true, "image", " "),
new Option("dis", false, "dis.txt", " "),
new Option("toc", false, "toc.txt", " "),
new Option("heap", false, "heap.txt", " "),
new Option("classStats", false),
new Option("traceLoading", false),
new Option("traceParser", false),
new Option("disassemble", false),
new Option("traceImage", false),
new Option("help", false),
new Option("Other", true, "@j2me/classes;samples/classes;tck/classes;tck/agent.jar")
};
commands = new Command[] {
new Command("Romize", "romizer", false, options)
};
}
Option[] getOptions() { return options; }
Command[] getCommands() { return commands; }
String getDefaultLogFileNameBase() { return "romizer";}
}
|
[
"doug.simon@oracle.com"
] |
doug.simon@oracle.com
|
58cb2a2f92fa51c772f038b146f6276bf2cee8db
|
a33aac97878b2cb15677be26e308cbc46e2862d2
|
/data/libgdx/btGjkPairDetector_getFixContactNormalDirection.java
|
0b26ba581b15f44024265e438a2af8938840a782
|
[] |
no_license
|
GabeOchieng/ggnn.tensorflow
|
f5d7d0bca52258336fc12c9de6ae38223f28f786
|
7c62c0e8427bea6c8bec2cebf157b6f1ea70a213
|
refs/heads/master
| 2022-05-30T11:17:42.278048
| 2020-05-02T11:33:31
| 2020-05-02T11:33:31
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 135
|
java
|
public int getFixContactNormalDirection() {
return CollisionJNI.btGjkPairDetector_fixContactNormalDirection_get(swigCPtr, this);
}
|
[
"bdqnghi@gmail.com"
] |
bdqnghi@gmail.com
|
500d03d20f6f949aae8e3d272c16b2fbed2fabf4
|
7f20b1bddf9f48108a43a9922433b141fac66a6d
|
/core3/impl/tags/3.0.0/biopax-impl/src/main/java/org/cytoscape/biopax/internal/view/BioPaxCytoPanelComponent.java
|
c5ee803b73eb5e070fae16d47675384b73064c01
|
[] |
no_license
|
ahdahddl/cytoscape
|
bf783d44cddda313a5b3563ea746b07f38173022
|
a3df8f63dba4ec49942027c91ecac6efa920c195
|
refs/heads/master
| 2020-06-26T16:48:19.791722
| 2013-08-28T04:08:31
| 2013-08-28T04:08:31
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 1,715
|
java
|
package org.cytoscape.biopax.internal.view;
/*
* #%L
* Cytoscape BioPAX Impl (biopax-impl)
* $Id:$
* $HeadURL:$
* %%
* Copyright (C) 2006 - 2013 The Cytoscape Consortium
* %%
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as
* published by the Free Software Foundation, either version 2.1 of the
* License, or (at your option) any later version.
*
* This program 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 Lesser Public License for more details.
*
* You should have received a copy of the GNU General Lesser Public
* License along with this program. If not, see
* <http://www.gnu.org/licenses/lgpl-2.1.html>.
* #L%
*/
import java.awt.Component;
import java.net.URL;
import javax.swing.Icon;
import javax.swing.ImageIcon;
import org.cytoscape.application.swing.CytoPanelComponent;
import org.cytoscape.application.swing.CytoPanelName;
public class BioPaxCytoPanelComponent implements CytoPanelComponent {
private final BioPaxContainer bpContainer;
private final Icon icon;
public BioPaxCytoPanelComponent(BioPaxContainer bpContainer) {
this.bpContainer = bpContainer;
URL url = getClass().getResource("read_obj.gif");
icon = new ImageIcon(url);
}
@Override
public Component getComponent() {
return bpContainer;
}
@Override
public CytoPanelName getCytoPanelName() {
return CytoPanelName.EAST;
}
@Override
public String getTitle() {
return "Node Details";
}
@Override
public Icon getIcon() {
return icon;
}
}
|
[
"kono@0ecc0d97-ab19-0410-9704-bfe1a75892f5"
] |
kono@0ecc0d97-ab19-0410-9704-bfe1a75892f5
|
2bd3070c0238c34af8cfbb38511dec5f5c3d17db
|
01b67b2ba9b1d251b8158279c18e7ea69c888fd5
|
/backend/meduo-bus-starter/src/main/java/org/springframework/messaging/converter/CompositeMessageConverter.java
|
5c924c7be31773aa76a3e435851b8bcc76210445
|
[] |
no_license
|
suwinner1987/meduo
|
7489e24a4623c95ed4794d3262839478f65566d5
|
34c8d707a423dfbcf1b0f103a527eb1f3735c188
|
refs/heads/master
| 2023-06-10T11:02:53.867308
| 2020-11-23T07:43:48
| 2020-11-23T07:43:48
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 4,146
|
java
|
/*
* Copyright 2002-2016 the original author or authors.
*
* 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
*
* https://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 org.springframework.messaging.converter;
import java.util.ArrayList;
import java.util.Collection;
import java.util.List;
import com.alibaba.fastjson.support.spring.messaging.MappingFastJsonMessageConverter;
import org.springframework.lang.Nullable;
import org.springframework.messaging.Message;
import org.springframework.messaging.MessageHeaders;
import org.springframework.util.Assert;
/**
* A {@link MessageConverter} that delegates to a list of registered converters
* to be invoked until one of them returns a non-null result.
*
* <p>As of 4.2.1, this composite converter implements {@link SmartMessageConverter}
* in order to support the delegation of conversion hints.
*
* @author Rossen Stoyanchev
* @author Juergen Hoeller
* @since 4.0
*/
public class CompositeMessageConverter implements SmartMessageConverter {
private final List<MessageConverter> converters;
/**
* Create an instance with the given converters.
*/
public CompositeMessageConverter(Collection<MessageConverter> converters) {
Assert.notEmpty(converters, "Converters must not be empty");
this.converters = new ArrayList<>();
this.converters.add(new MappingFastJsonMessageConverter());
this.converters.addAll(converters);
}
@Override
@Nullable
public Object fromMessage(Message<?> message, Class<?> targetClass) {
for (MessageConverter converter : getConverters()) {
Object result = converter.fromMessage(message, targetClass);
if (result != null) {
return result;
}
}
return null;
}
@Override
@Nullable
public Object fromMessage(Message<?> message, Class<?> targetClass, @Nullable Object conversionHint) {
for (MessageConverter converter : getConverters()) {
Object result = (converter instanceof SmartMessageConverter ?
((SmartMessageConverter) converter).fromMessage(message, targetClass, conversionHint) :
converter.fromMessage(message, targetClass));
if (result != null) {
return result;
}
}
return null;
}
@Override
@Nullable
public Message<?> toMessage(Object payload, @Nullable MessageHeaders headers) {
try {
for (MessageConverter converter : getConverters()) {
Message<?> result = converter.toMessage(payload, headers);
if (result != null) {
return result;
}
}
}catch (Exception ex){
return null;
}
return null;
}
@Override
@Nullable
public Message<?> toMessage(Object payload, @Nullable MessageHeaders headers, @Nullable Object conversionHint) {
for (MessageConverter converter : getConverters()) {
Message<?> result = (converter instanceof SmartMessageConverter ?
((SmartMessageConverter) converter).toMessage(payload, headers, conversionHint) :
converter.toMessage(payload, headers));
if (result != null) {
return result;
}
}
return null;
}
/**
* Return the underlying list of delegate converters.
*/
public List<MessageConverter> getConverters() {
return this.converters;
}
@Override
public String toString() {
return "CompositeMessageConverter[converters=" + getConverters() + "]";
}
}
|
[
"gao.brian@gmail.com"
] |
gao.brian@gmail.com
|
02ca76ca59d668984c2e9c0b50c3155854ec771c
|
e27942cce249f7d62b7dc8c9b86cd40391c1ddd4
|
/modules/adwords_axis/src/main/java/com/google/api/ads/adwords/axis/v201708/cm/SizeLimitErrorReason.java
|
568e8b35b46778048303e234425919d9248ecea9
|
[
"Apache-2.0"
] |
permissive
|
mo4ss/googleads-java-lib
|
b4b6178747d25d16ae6aa0c80d80ee18a2dfe01a
|
efaa9c3bd8a46a3ed4b00963dc9760c6dd8bd641
|
refs/heads/master
| 2022-12-05T00:30:56.740813
| 2022-11-16T10:47:15
| 2022-11-16T10:47:15
| 108,132,394
| 0
| 0
|
Apache-2.0
| 2022-11-16T10:47:16
| 2017-10-24T13:41:43
|
Java
|
UTF-8
|
Java
| false
| false
| 3,952
|
java
|
// Copyright 2017 Google Inc. All Rights Reserved.
//
// 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://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.
/**
* SizeLimitErrorReason.java
*
* This file was auto-generated from WSDL
* by the Apache Axis 1.4 Mar 02, 2009 (07:08:06 PST) WSDL2Java emitter.
*/
package com.google.api.ads.adwords.axis.v201708.cm;
public class SizeLimitErrorReason implements java.io.Serializable {
private java.lang.String _value_;
private static java.util.HashMap _table_ = new java.util.HashMap();
// Constructor
protected SizeLimitErrorReason(java.lang.String value) {
_value_ = value;
_table_.put(_value_,this);
}
public static final java.lang.String _REQUEST_SIZE_LIMIT_EXCEEDED = "REQUEST_SIZE_LIMIT_EXCEEDED";
public static final java.lang.String _RESPONSE_SIZE_LIMIT_EXCEEDED = "RESPONSE_SIZE_LIMIT_EXCEEDED";
public static final java.lang.String _INTERNAL_STORAGE_ERROR = "INTERNAL_STORAGE_ERROR";
public static final java.lang.String _UNKNOWN = "UNKNOWN";
public static final SizeLimitErrorReason REQUEST_SIZE_LIMIT_EXCEEDED = new SizeLimitErrorReason(_REQUEST_SIZE_LIMIT_EXCEEDED);
public static final SizeLimitErrorReason RESPONSE_SIZE_LIMIT_EXCEEDED = new SizeLimitErrorReason(_RESPONSE_SIZE_LIMIT_EXCEEDED);
public static final SizeLimitErrorReason INTERNAL_STORAGE_ERROR = new SizeLimitErrorReason(_INTERNAL_STORAGE_ERROR);
public static final SizeLimitErrorReason UNKNOWN = new SizeLimitErrorReason(_UNKNOWN);
public java.lang.String getValue() { return _value_;}
public static SizeLimitErrorReason fromValue(java.lang.String value)
throws java.lang.IllegalArgumentException {
SizeLimitErrorReason enumeration = (SizeLimitErrorReason)
_table_.get(value);
if (enumeration==null) throw new java.lang.IllegalArgumentException();
return enumeration;
}
public static SizeLimitErrorReason fromString(java.lang.String value)
throws java.lang.IllegalArgumentException {
return fromValue(value);
}
public boolean equals(java.lang.Object obj) {return (obj == this);}
public int hashCode() { return toString().hashCode();}
public java.lang.String toString() { return _value_;}
public java.lang.Object readResolve() throws java.io.ObjectStreamException { return fromValue(_value_);}
public static org.apache.axis.encoding.Serializer getSerializer(
java.lang.String mechType,
java.lang.Class _javaType,
javax.xml.namespace.QName _xmlType) {
return
new org.apache.axis.encoding.ser.EnumSerializer(
_javaType, _xmlType);
}
public static org.apache.axis.encoding.Deserializer getDeserializer(
java.lang.String mechType,
java.lang.Class _javaType,
javax.xml.namespace.QName _xmlType) {
return
new org.apache.axis.encoding.ser.EnumDeserializer(
_javaType, _xmlType);
}
// Type metadata
private static org.apache.axis.description.TypeDesc typeDesc =
new org.apache.axis.description.TypeDesc(SizeLimitErrorReason.class);
static {
typeDesc.setXmlType(new javax.xml.namespace.QName("https://adwords.google.com/api/adwords/cm/v201708", "SizeLimitError.Reason"));
}
/**
* Return type metadata object
*/
public static org.apache.axis.description.TypeDesc getTypeDesc() {
return typeDesc;
}
}
|
[
"jradcliff@users.noreply.github.com"
] |
jradcliff@users.noreply.github.com
|
69c08516a691c4916a381cf40d5191d0d5f6dcc6
|
2b74e8b95644f7e31104840e274151ba5083caa3
|
/src/main/java/js/com/proxy/Subject.java
|
93d8921880cf6fa520cf49359a8e9be8c53e3105
|
[] |
no_license
|
chy2z/designpattern
|
dec6bc7d7be411f7b89ba57290c846816b266881
|
a4224275d017af3df629c44fee6ff3b95f5cf17f
|
refs/heads/master
| 2022-03-12T18:09:07.506048
| 2022-02-20T16:24:26
| 2022-02-20T16:24:26
| 135,687,900
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 167
|
java
|
package js.com.proxy;
/**
* @Title: Subject
* @Description: 目标
* @author chy
* @date 2018/5/12 16:23
*/
public interface Subject {
public void request();
}
|
[
"chenghy.js@eakay.cn"
] |
chenghy.js@eakay.cn
|
70358f55780ca5f8a0426273cd4572abb77f4b61
|
3843b09d7c81a6367abb2546211fb6c05f420ae4
|
/Java OOP Advanced/6.2 OpenClosed, Liskov Substitution Principles - Exercises/OpenClosedLiskovExercises/src/main/java/implementations/appenders/FileAppender.java
|
5ce5576bd06a97870126ea4b92af8484cc97ada8
|
[] |
no_license
|
Deyan-Stoyanov/SoftUni_Java_Fundamentals
|
11021a94ee3ff8908f38b038d626e1e85a57a6c3
|
987c7565d4587530d4f590d1322a8c13ad2beed6
|
refs/heads/master
| 2020-03-17T10:17:37.224710
| 2018-08-19T16:58:40
| 2018-08-19T16:58:40
| 133,507,185
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 954
|
java
|
package implementations.appenders;
import abstractions.Layout;
import enums.ReportLevel;
import implementations.files.LogFile;
public class FileAppender extends BaseAppender{
public FileAppender(Layout layout) {
super(layout);
this.setFile(new LogFile());
}
public void append(String dateTime, String level, String message) {
if(this.getReportLevel() == null){
super.getFile().write(this.getLayout().layoutString(dateTime, level, message));
this.increaseMessageCount();
} else {
if(this.getReportLevel().ordinal() <= Enum.valueOf(ReportLevel.class, level).ordinal()){
super.getFile().write(this.getLayout().layoutString(dateTime, level, message));
this.increaseMessageCount();
}
}
}
@Override
public String toString() {
return super.toString() + ", File size: " + this.getFile().getSize();
}
}
|
[
"32268625+Deyan-Stoyanov@users.noreply.github.com"
] |
32268625+Deyan-Stoyanov@users.noreply.github.com
|
bc6a841d8d3ff9175ced7ff25e9db414e4ecc298
|
fd0c857bf539e9fd01a560655f90bb0e7a8e24c3
|
/src/main/java/de/gematik/ti/schema/gen/vsd/v5_2/pd/VSD_Versicherter.java
|
943518b7de8074719fea857c6a359c487eb3f794
|
[
"Apache-2.0"
] |
permissive
|
gematik/data-model-vsd
|
600f0b9fdd21481ded86c456be28a4e6656d39cb
|
2fca15b8b921e731feddef573c587f1a4426098a
|
refs/heads/master
| 2020-12-19T02:48:01.951320
| 2020-01-28T09:47:12
| 2020-01-28T09:47:12
| 235,597,600
| 1
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 3,678
|
java
|
/*
* Copyright (c) 2020 gematik GmbH
*
* 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://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.
*/
//
// This is a generated file, do not edit.
// This file was generated from an xsd file and represents a simple or complex type of it.
// Generated by a fork of xsd2cocoa (see https://github.com/Daij-Djan/xsd2cocoa) and a specified custom transform template.
//
package de.gematik.ti.schema.gen.vsd.v5_2.pd;
import de.gematik.ti.schema.gen.vsd.utils.*;
import java.util.*;
import org.w3c.dom.*;
/** Generated Java class */
public class VSD_Versicherter {
public static final String NAMESPACE_PREFIX = "VSD";
public static final String NAMESPACE_URI = "http://ws.gematik.de/fa/vsdm/vsd/v5.2";
// attributes:
// elements:
/*@isNotSingleOrNotOptionalValue*/
public String Versicherten_ID;
/*@isNotSingleOrNotOptionalValue*/
public VSD_Person Person;
// default Constructor
public VSD_Versicherter() {
this.Versicherten_ID = new String();
this.Person = new VSD_Person();
}
// copy Constructor
public VSD_Versicherter(VSD_Versicherter _VSD_Versicherter) {
this.Versicherten_ID = _VSD_Versicherter.Versicherten_ID;
this.Person = _VSD_Versicherter.Person;
}
public static VSD_Versicherter deserialize(Node node) {
if (node == null) {
return null;
}
Element element = (Element) node;
VSD_Versicherter _VSD_Versicherter = new VSD_Versicherter();
NodeList nodeListVersicherten_ID = element.getElementsByTagNameNS(VSD_Versicherter.NAMESPACE_URI ,"Versicherten_ID");
if (nodeListVersicherten_ID.getLength() == 0) {
_VSD_Versicherter.Versicherten_ID = null;
} else {
_VSD_Versicherter.Versicherten_ID = String.valueOf(((Element) nodeListVersicherten_ID.item(0)).getTextContent());
}
NodeList nodeListPerson = element.getElementsByTagNameNS(VSD_Person.NAMESPACE_URI ,"Person");
Node nodePerson = nodeListPerson.item(0);
_VSD_Versicherter.Person = VSD_Person.deserialize(nodePerson);
return _VSD_Versicherter;
}
public static List deserializeToList(List<Node> nodeList) {
List result = new ArrayList<VSD_Versicherter>();
for( Node node : nodeList) {
result.add(deserialize(node));
}
return result;
}
/**
* Returns a map of attributes
*/
public Map<String, Object> getAttributes() {
HashMap<String, Object> attributesDict = new HashMap<>();
return attributesDict;
}
/**
* Returns a LinkedHashMap of the elements. LinkedHashMap is used as a workaround to provide the needed
* functionality of a ordered array of tuples.
*/
public LinkedHashMap<String, Object> getElements() {
LinkedHashMap<String, Object> elemArray = new LinkedHashMap<>();
elemArray.put("Versicherten_ID", this.Versicherten_ID);
elemArray.put("Person", this.Person);
return elemArray;
}
}
|
[
"referenzimplementierung@gematik.de"
] |
referenzimplementierung@gematik.de
|
3231567f3be49617a753ea05cac5c92418a824af
|
945d0e45a22fd280955ee9f9dc7a63d3aa7b5e53
|
/loan-user/src/main/java/com/hwc/framework/modules/third/business/carrier/dto/PackageItem.java
|
6c21bf4406d02ae2b642815228b53781117d726c
|
[] |
no_license
|
liangchch/loan
|
cb1bd4f767cc89bf78d88dbed6a7ae73b08c1c2b
|
f535eba487715dc13986d87a655af9000c0ce6ea
|
refs/heads/master
| 2022-04-23T11:27:59.348843
| 2020-04-26T06:26:20
| 2020-04-26T06:26:20
| 258,930,371
| 0
| 0
| null | 2020-04-26T05:45:59
| 2020-04-26T03:29:09
| null |
UTF-8
|
Java
| false
| false
| 1,293
|
java
|
/**
* Project Name:api-webhook
* File Name:PackageItem.java
* Package Name:com.example.service.webhook.business.carrier.dto
* Date:2016年7月25日下午2:57:38
* Copyright (c) 2016, yuandong@51dojo.com All Rights Reserved.
*
*/
package com.hwc.framework.modules.third.business.carrier.dto;
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
/**
* ClassName:PackageItem <br/>
* Function: TODO ADD FUNCTION. <br/>
* Reason: TODO ADD REASON. <br/>
* Date: 2016年7月25日 下午2:57:38 <br/>
* @author yuandong
* @version
* @since JDK 1.6
* @see
*/
@JsonIgnoreProperties(ignoreUnknown=true)
public class PackageItem {
private String item;//项目名称. e.g.手机上网自选30元包(500MB)
private String total;
private String used;
private String unit;
public String getItem() {
return item;
}
public void setItem(String item) {
this.item = item;
}
public String getTotal() {
return total;
}
public void setTotal(String total) {
this.total = total;
}
public String getUsed() {
return used;
}
public void setUsed(String used) {
this.used = used;
}
public String getUnit() {
return unit;
}
public void setUnit(String unit) {
this.unit = unit;
}
}
|
[
"jizhongliang@jizhongliangdeiMac.local"
] |
jizhongliang@jizhongliangdeiMac.local
|
6426c7c39003a7afa91edc408056d587131a43fe
|
cc1b47db2b25d7f122d0fb48a4917fd01f129ff8
|
/test/it-domino-jnx/src/test/java/org/apache/commons/mail/DataSourceResolver.java
|
fc251fbfb2d9852474e288ad65858cede81ae805
|
[
"LicenseRef-scancode-unknown-license-reference",
"Apache-2.0"
] |
permissive
|
savlpavel/domino-jnx
|
666f7e12abdf5e36b471cdd7c99086db589f923f
|
2d94e42cdfa56de3b117231f4488685f8e084e83
|
refs/heads/main
| 2023-09-04T10:20:43.968949
| 2023-07-31T16:41:34
| 2023-07-31T16:41:34
| 392,598,440
| 0
| 1
|
Apache-2.0
| 2021-08-04T07:49:29
| 2021-08-04T07:49:29
| null |
UTF-8
|
Java
| false
| false
| 1,866
|
java
|
/*
* 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 org.apache.commons.mail;
import java.io.IOException;
import jakarta.activation.DataSource;
/**
* Creates a {@code DataSource} based on an URL.
*
* @since 1.3
*/
public interface DataSourceResolver {
/**
* Resolves the given resource location to a {@code DataSource}.
*
* @param resourceLocation the location of the resource
* @return the {@code DataSource}
* @throws IOException the resource was not found
*/
DataSource resolve(final String resourceLocation) throws IOException;
/**
* Resolves the given resource location to a {@code DataSource}.
*
* @param resourceLocation the location of the resource
* @param isLenient shall we ignore resources not found or complain with
* an exception?
* @return the data source containing the resource or null if the resource was
* not found in lenient mode
* @throws IOException resolving the resource failed
*/
DataSource resolve(final String resourceLocation, final boolean isLenient)
throws IOException;
}
|
[
"jesse@secondfoundation.org"
] |
jesse@secondfoundation.org
|
b86379392eb8617e37b873bcfca356af1493371a
|
4a60dae96020270dabf4f308a3bc826c889af270
|
/JavaRushTasks/3.JavaMultithreading/src/com/javarush/task/task25/task2504/Solution.java
|
1fb005c6338d1e44b2301b38e98e0a20d91a9cac
|
[] |
no_license
|
atnimak/JavaRushTasks
|
b6c9c7271f48c4050cb2541ab77b4a341fc1841c
|
f9b79a98d1d0657cef34f89b10f211adebb12d28
|
refs/heads/master
| 2023-04-21T14:22:02.703112
| 2023-04-19T19:10:09
| 2023-04-19T19:10:09
| 112,734,260
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 1,094
|
java
|
package com.javarush.task.task25.task2504;
import static java.lang.Thread.State.NEW;
import static java.lang.Thread.State.WAITING;
/*
Switch для нитей
*/
public class Solution {
public static void processThreads(Thread... threads) {
//implement this method - реализуйте этот метод
for(Thread thread : threads){
switch (thread.getState()){
case NEW:
thread.start();
break;
case WAITING:
thread.interrupt();
break;
case BLOCKED:
thread.interrupt();
break;
case TIMED_WAITING:
thread.interrupt();
break;
case RUNNABLE:
thread.isInterrupted();
break;
case TERMINATED:
System.out.println(thread.getPriority());
break;
}
}
}
public static void main(String[] args) {
}
}
|
[
"x.pouls@gmail.com"
] |
x.pouls@gmail.com
|
0a2c3aef6e09e370ce48476e0d00dbb4253b7391
|
572071ee133309caf78e076b669f9b33a868d60c
|
/org.activebpel.rt.bpel/classes/org/activebpel/rt/bpel/impl/expr/xpath/.svn/text-base/AeWSBPELXPathLinkVariableContext.java.svn-base
|
9d2d2c4a648a95c9948d6fc044a9c901cb8e1dcc
|
[] |
no_license
|
deib-polimi/DyBPEL
|
3809bb3f9f453750db52bc1ce1ffd5af412a2c8b
|
7043cec7032858cfd889c9022e935c946e130a6e
|
refs/heads/master
| 2021-01-20T12:21:50.392988
| 2014-12-18T15:07:24
| 2014-12-18T15:07:24
| 28,188,077
| 0
| 1
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 3,916
|
// $Header: /gestionale/org.activebpel.rt.bpel/src/org/activebpel/rt/bpel/impl/expr/xpath/AeWSBPELXPathLinkVariableContext.java,v 1.1 2009/09/23 13:09:50 zampognaro Exp $
/////////////////////////////////////////////////////////////////////////////
// PROPRIETARY RIGHTS STATEMENT
// The contents of this file represent confidential information that is the
// proprietary property of Active Endpoints, Inc. Viewing or use of
// this information is prohibited without the express written consent of
// Active Endpoints, Inc. Removal of this PROPRIETARY RIGHTS STATEMENT
// is strictly forbidden. Copyright (c) 2002-2006 All rights reserved.
/////////////////////////////////////////////////////////////////////////////
package org.activebpel.rt.bpel.impl.expr.xpath;
import java.util.ArrayList;
import java.util.List;
import org.activebpel.rt.bpel.AeMessages;
import org.activebpel.rt.bpel.function.AeFunctionCallException;
import org.activebpel.rt.bpel.function.IAeFunction;
import org.activebpel.rt.bpel.function.IAeFunctionExecutionContext;
import org.activebpel.rt.bpel.impl.function.AeGetLinkStatusFunction;
import org.activebpel.rt.util.AeUtil;
import org.jaxen.UnresolvableException;
import org.jaxen.VariableContext;
/**
* An implementation of a Jaxen variable context. This class is used in the BPEL 2.0 version of
* the XPath expression runner in order to resolve variable references using the syntax outlined
* in that version of BPEL. This class differs from the AeWSBPELXPathVariableContext class in
* that it resolves XPath variable references to link names rather than BPEL variables.
*/
public class AeWSBPELXPathLinkVariableContext implements VariableContext
{
/** The function exec context. */
private IAeFunctionExecutionContext mFunctionExecutionContext;
/**
* Constructor.
*
* @param aContext
*/
public AeWSBPELXPathLinkVariableContext(IAeFunctionExecutionContext aContext)
{
setFunctionExecutionContext(aContext);
}
/**
* @see org.jaxen.VariableContext#getVariableValue(java.lang.String, java.lang.String, java.lang.String)
*/
public Object getVariableValue(String aNamespaceURI, String aPrefix, String aLocalName) throws UnresolvableException
{
Object result = null;
// The variable must be unqualified.
if (AeUtil.isNullOrEmpty(aNamespaceURI))
{
String linkName = aLocalName;
IAeFunction function = new AeGetLinkStatusFunction();
List args = new ArrayList();
args.add(linkName);
try
{
result = function.call(getFunctionExecutionContext(), args);
}
catch (AeFunctionCallException ex)
{
throw new UnresolvableException(ex.getMessage());
}
}
else
{
// This is the case of the qualified variable - which could not possibly be resolved.
//
// Note that this exception should never happen, since we would presumably have caught
// this during validation (qualified variable reference).
throw new UnresolvableException(AeMessages.format("AeWSBPELXPathLinkVariableContext.UnresolvedLinkError", aLocalName)); //$NON-NLS-1$
}
// Convert the variable value to something that Jaxen can properly use.
return getFunctionExecutionContext().getTypeConverter().convertToExpressionType(result);
}
/**
* @return Returns the functionExecutionContext.
*/
protected IAeFunctionExecutionContext getFunctionExecutionContext()
{
return mFunctionExecutionContext;
}
/**
* @param mContext The functionExecutionContext to set.
*/
protected void setFunctionExecutionContext(IAeFunctionExecutionContext mContext)
{
mFunctionExecutionContext = mContext;
}
}
|
[
"giovanniquattrocchi@MacBook-Pro-di-Giovanni.local"
] |
giovanniquattrocchi@MacBook-Pro-di-Giovanni.local
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.