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
a323aad5125437189923d73d6e26d95e2126cc68
6e9a5bddddfb841999a00bec00b9466d266cd1f0
/jun_ureport2/ureport2-console/src/main/java/com/bstek/ureport/console/chart/ChartServletAction.java
9abd53d33d47ebc6dae3d3623d8c5dd0beb4f61b
[ "LicenseRef-scancode-unknown-license-reference", "LicenseRef-scancode-warranty-disclaimer", "Apache-2.0" ]
permissive
cuilong1009/jun_bigdata
9c36dde7a5fe8fe85abfe43398f797decc7cb1d4
1ad4194eaab24735e3864831c9fede787361599a
refs/heads/master
2023-06-05T05:21:58.095287
2020-11-25T16:01:26
2020-11-25T16:01:26
null
0
0
null
null
null
null
UTF-8
Java
false
false
2,360
java
/******************************************************************************* * Copyright 2017 Bstek * * 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.bstek.ureport.console.chart; import java.io.IOException; import javax.servlet.ServletException; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; import com.bstek.ureport.cache.CacheUtils; import com.bstek.ureport.chart.ChartData; import com.bstek.ureport.console.RenderPageServletAction; import com.bstek.ureport.utils.UnitUtils; /** * @author Wujun * @since 2017年6月30日 */ public class ChartServletAction extends RenderPageServletAction { @Override public void execute(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException { String method=retriveMethod(req); if(method!=null){ invokeMethod(method, req, resp); } } public void storeData(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException { String file=req.getParameter("_u"); file=decode(file); String chartId=req.getParameter("_chartId"); ChartData chartData=CacheUtils.getChartData(chartId); if(chartData==null){ return; } String base64Data=req.getParameter("_base64Data"); String prefix="data:image/png;base64,"; if(base64Data!=null){ if(base64Data.startsWith(prefix)){ base64Data=base64Data.substring(prefix.length(),base64Data.length()); } } chartData.setBase64Data(base64Data); String width=req.getParameter("_width"); String height=req.getParameter("_height"); chartData.setHeight(UnitUtils.pixelToPoint(Integer.valueOf(height))); chartData.setWidth(UnitUtils.pixelToPoint(Integer.valueOf(width))); } @Override public String url() { return "/chart"; } }
[ "wujun728@hotmail.com" ]
wujun728@hotmail.com
38b88128aa0c844994a70c2a24f134f4f39b365c
9436a38c04cdb0e587c5fcb5ecf69fd818f0ac64
/hsweb-commons/hsweb-commons-service/hsweb-commons-service-api/src/main/java/org/hswebframework/web/service/CreateEntityService.java
22b20c2aa3d05adfd5305b378136846af3635a7d
[ "Apache-2.0" ]
permissive
pzhao12testb/hsweb-framework
2450341fe6634e315c3f45f16ab4bd2255ee0dff
3107b2277419435ff870656d35521570ffb0a2c3
refs/heads/master
2021-01-25T14:10:18.794026
2018-03-03T07:16:04
2018-03-03T07:16:04
123,659,939
0
0
Apache-2.0
2018-03-03T04:48:40
2018-03-03T04:48:40
null
UTF-8
Java
false
false
1,119
java
/* * * * Copyright 2016 http://www.hswebframework.org * * * * 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.hswebframework.web.service; /** * 实体创建服务接口,通过此接口创建实体.在创建实体类时,建议使用此接口进行创建,而不是使用new * 如: * <code> * YourBean bean = service.createEntity(); * </code> * * @author zhouhao * @since 3.0 */ public interface CreateEntityService<E> { /** * 创建实体 * * @return 实体 */ E createEntity(); Class<E> getEntityInstanceType(); }
[ "zh.sqy@qq.com" ]
zh.sqy@qq.com
08ba4e4e54bfdca338fffe028d5300aaa07dee9f
88ae80380c1a2a5b760c62b4ab996c8349bbf2c7
/src/mmp-application-sms/src/main/java/com/mymobileapi/api5/CreditsSTRResponse.java
f6ab3187c3e7e572058b32b08faa228523e62908
[ "Apache-2.0" ]
permissive
marcusportmann/mmp-java
abfb83c48a406a295d836b4d43fbe14e6dc80a1b
97b347a00e4f6d1c003a144cfb08721ebfaeba97
refs/heads/master
2021-01-17T13:05:36.607430
2018-05-24T10:31:04
2018-05-24T10:31:04
58,325,716
1
0
null
null
null
null
UTF-8
Java
false
false
1,578
java
package com.mymobileapi.api5; import javax.xml.bind.annotation.XmlAccessType; import javax.xml.bind.annotation.XmlAccessorType; import javax.xml.bind.annotation.XmlElement; 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> * &lt;complexType> * &lt;complexContent> * &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"> * &lt;sequence> * &lt;element name="Credits_STRResult" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/> * &lt;/sequence> * &lt;/restriction> * &lt;/complexContent> * &lt;/complexType> * </pre> * * */ @XmlAccessorType(XmlAccessType.FIELD) @XmlType(name = "", propOrder = { "creditsSTRResult" }) @XmlRootElement(name = "Credits_STRResponse") public class CreditsSTRResponse { @XmlElement(name = "Credits_STRResult") protected String creditsSTRResult; /** * Gets the value of the creditsSTRResult property. * * @return * possible object is * {@link String } * */ public String getCreditsSTRResult() { return creditsSTRResult; } /** * Sets the value of the creditsSTRResult property. * * @param value * allowed object is * {@link String } * */ public void setCreditsSTRResult(String value) { this.creditsSTRResult = value; } }
[ "marcus@mmp.guru" ]
marcus@mmp.guru
c060f36079d71cbbf828e40c93fbb58f308011c6
9a921cbc0f28633ad4fca9d8ec4107b718739c88
/src/org/benf/cfr/reader/bytecode/analysis/parse/expression/NewAnonymousArray.java
6a615a67bf90971a7b3359a31e58eea375add88f
[]
no_license
OndraZizka/CFR-decompiler
7a4aebd6e5a4f6a0d4a6672740b3bdc08c5ade2f
872571f535ff396e52271e1a3cfaf7175960d0f6
refs/heads/master
2021-01-19T06:58:18.317704
2014-05-10T00:45:20
2014-05-10T00:45:20
19,629,858
8
1
null
null
null
null
UTF-8
Java
false
false
7,313
java
/* * Decompiled with CFR 0_78. */ package org.benf.cfr.reader.bytecode.analysis.parse.expression; import java.util.Collection; import java.util.List; import org.benf.cfr.reader.bytecode.analysis.opgraph.op4rewriters.PrimitiveBoxingRewriter; import org.benf.cfr.reader.bytecode.analysis.parse.Expression; import org.benf.cfr.reader.bytecode.analysis.parse.StatementContainer; import org.benf.cfr.reader.bytecode.analysis.parse.expression.AbstractNewArray; import org.benf.cfr.reader.bytecode.analysis.parse.expression.misc.Precedence; import org.benf.cfr.reader.bytecode.analysis.parse.expression.rewriteinterface.BoxingProcessor; import org.benf.cfr.reader.bytecode.analysis.parse.rewriters.CloneHelper; import org.benf.cfr.reader.bytecode.analysis.parse.rewriters.DeepCloneable; import org.benf.cfr.reader.bytecode.analysis.parse.rewriters.ExpressionRewriter; import org.benf.cfr.reader.bytecode.analysis.parse.rewriters.ExpressionRewriterFlags; import org.benf.cfr.reader.bytecode.analysis.parse.utils.EquivalenceConstraint; import org.benf.cfr.reader.bytecode.analysis.parse.utils.LValueRewriter; import org.benf.cfr.reader.bytecode.analysis.parse.utils.LValueUsageCollector; import org.benf.cfr.reader.bytecode.analysis.parse.utils.SSAIdentifiers; import org.benf.cfr.reader.bytecode.analysis.types.JavaTypeInstance; import org.benf.cfr.reader.bytecode.analysis.types.RawJavaType; import org.benf.cfr.reader.bytecode.analysis.types.discovery.InferredJavaType; import org.benf.cfr.reader.state.TypeUsageCollector; import org.benf.cfr.reader.util.ListFactory; import org.benf.cfr.reader.util.TypeUsageCollectable; import org.benf.cfr.reader.util.output.CommaHelp; import org.benf.cfr.reader.util.output.Dumpable; import org.benf.cfr.reader.util.output.Dumper; public class NewAnonymousArray extends AbstractNewArray implements BoxingProcessor { private JavaTypeInstance allocatedType; private int numDims; private List<Expression> values = ListFactory.newList(); private boolean isCompletelyAnonymous = false; public NewAnonymousArray(InferredJavaType type, int numDims, List<Expression> values, boolean isCompletelyAnonymous) { super(type); this.numDims = numDims; this.allocatedType = type.getJavaTypeInstance().getArrayStrippedType(); if (this.allocatedType instanceof RawJavaType) { for (Expression value : values) { value.getInferredJavaType().useAsWithoutCasting((RawJavaType)this.allocatedType); } } for (Expression value : values) { if (value instanceof NewAnonymousArray) { NewAnonymousArray newAnonymousArrayInner = (NewAnonymousArray)value; newAnonymousArrayInner.isCompletelyAnonymous = true; } this.values.add(value); } this.isCompletelyAnonymous = isCompletelyAnonymous; } @Override public void collectTypeUsages(TypeUsageCollector collector) { collector.collect(this.allocatedType); collector.collectFrom((Collection<? extends TypeUsageCollectable>)this.values); } @Override public boolean rewriteBoxing(PrimitiveBoxingRewriter boxingRewriter) { for (int i = 0; i < this.values.size(); ++i) { this.values.set(i, boxingRewriter.sugarNonParameterBoxing(this.values.get(i), this.allocatedType)); } return false; } @Override public void applyNonArgExpressionRewriter(ExpressionRewriter expressionRewriter, SSAIdentifiers ssaIdentifiers, StatementContainer statementContainer, ExpressionRewriterFlags flags) { } @Override public Expression deepClone(CloneHelper cloneHelper) { return new NewAnonymousArray(this.getInferredJavaType(), this.numDims, cloneHelper.replaceOrClone(this.values), this.isCompletelyAnonymous); } @Override public Precedence getPrecedence() { return Precedence.PAREN_SUB_MEMBER; } @Override public Dumper dumpInner(Dumper d) { if (!this.isCompletelyAnonymous) { d.print("new ").dump(this.allocatedType); for (int x = 0; x < this.numDims; ++x) { d.print("[]"); } } d.print("{"); boolean first = true; for (Expression value : this.values) { first = CommaHelp.comma(first, d); d.dump(value); } d.print("}"); return d; } public List<Expression> getValues() { return this.values; } @Override public Expression replaceSingleUsageLValues(LValueRewriter lValueRewriter, SSAIdentifiers ssaIdentifiers, StatementContainer statementContainer) { for (int x = 0; x < this.values.size(); ++x) { this.values.set(x, this.values.get(x).replaceSingleUsageLValues(lValueRewriter, ssaIdentifiers, statementContainer)); } return this; } @Override public Expression applyExpressionRewriter(ExpressionRewriter expressionRewriter, SSAIdentifiers ssaIdentifiers, StatementContainer statementContainer, ExpressionRewriterFlags flags) { for (int x = 0; x < this.values.size(); ++x) { this.values.set(x, expressionRewriter.rewriteExpression(this.values.get(x), ssaIdentifiers, statementContainer, flags)); } return this; } @Override public void collectUsedLValues(LValueUsageCollector lValueUsageCollector) { } @Override public int getNumDims() { return this.numDims; } @Override public int getNumSizedDims() { return 0; } @Override public Expression getDimSize(int dim) { throw new UnsupportedOperationException(); } @Override public JavaTypeInstance getInnerType() { return this.allocatedType; } @Override public boolean equals(Object o) { if (this == o) { return true; } if (o == null || this.getClass() != o.getClass()) { return false; } NewAnonymousArray that = (NewAnonymousArray)o; if (this.isCompletelyAnonymous != that.isCompletelyAnonymous) { return false; } if (this.numDims != that.numDims) { return false; } if (this.allocatedType != null ? !this.allocatedType.equals(that.allocatedType) : that.allocatedType != null) { return false; } if (!(this.values != null ? !this.values.equals(that.values) : that.values != null)) return true; return false; } @Override public boolean equivalentUnder(Object o, EquivalenceConstraint constraint) { if (o == null) { return false; } if (o == this) { return true; } if (this.getClass() != o.getClass()) { return false; } NewAnonymousArray other = (NewAnonymousArray)o; if (this.isCompletelyAnonymous != other.isCompletelyAnonymous) { return false; } if (this.numDims != other.numDims) { return false; } if (!constraint.equivalent(this.allocatedType, other.allocatedType)) { return false; } if (constraint.equivalent(this.values, other.values)) return true; return false; } }
[ "zizka@seznam.cz" ]
zizka@seznam.cz
417ebd2a6f3e79083f2eb638468f33c289ee0f1e
4aa90348abcb2119011728dc067afd501f275374
/app/src/main/java/com/tencent/mm/a.java
d85d3269c8128bb3621d00fc44a07f27a774620b
[]
no_license
jambestwick/HackWechat
0d4ceb2d79ccddb45004ca667e9a6a984a80f0f6
6a34899c8bfd50d19e5a5ec36a58218598172a6b
refs/heads/master
2022-01-27T12:48:43.446804
2021-12-29T10:36:30
2021-12-29T10:36:30
249,366,791
0
0
null
2020-03-23T07:48:32
2020-03-23T07:48:32
null
UTF-8
Java
false
false
2,128
java
package com.tencent.mm; import android.content.Context; import com.tencent.mm.api.b; import com.tencent.mm.api.j; import com.tencent.mm.api.k; import com.tencent.mm.api.m; import com.tencent.mm.api.m.c; import com.tencent.mm.cache.ArtistCacheManager; import com.tencent.mm.cache.ArtistCacheManager.1; import com.tencent.mm.sdk.f.e; import com.tencent.mm.sdk.platformtools.bh; public final class a extends m { private com.tencent.mm.view.a bpM; private k bpN; public final b ai(Context context) { if (this.bpM == null) { if (this.fdC.fdE == c.fdJ) { this.bpM = new com.tencent.mm.view.c(context, this.fdC); } else if (this.fdC.fdE == c.fdK) { this.bpM = new com.tencent.mm.view.b(context, this.fdC); } } return this.bpM; } public final void a(j jVar) { this.bpM.cAl().a(jVar, !sT().tf()); } public final boolean sS() { return this.bpM.cAl().sS(); } public final void a(com.tencent.mm.api.m.a aVar) { super.a(aVar); ArtistCacheManager xu = ArtistCacheManager.xu(); String az = bh.az(this.fdC.path, "MicroMsg.MMPhotoEditorImpl"); xu.gBq = az; if (!ArtistCacheManager.gBo.containsKey(az)) { ArtistCacheManager.gBo.put(az, new a(xu)); } } public final void onDestroy() { if (!this.fdC.fdF) { ArtistCacheManager xu = ArtistCacheManager.xu(); String az = bh.az(this.fdC.path, "MicroMsg.MMPhotoEditorImpl"); xu.gBq = null; if (ArtistCacheManager.gBo.containsKey(az)) { ((a) ArtistCacheManager.gBo.get(az)).clearAll(); ArtistCacheManager.gBo.remove(az); } e.cgR(); e.post(new 1(xu), "MicroMsg.ArtistCacheManager[clearAllCache]"); } if (this.bpM != null) { this.bpM.cAl().onDestroy(); } } public final k sT() { if (this.bpN == null) { this.bpN = new com.tencent.mm.bt.a(this.bpM.cAl()); } return this.bpN; } }
[ "malin.myemail@163.com" ]
malin.myemail@163.com
c74778267882e5a244fb9dc5e3bf3a840cf7ba50
f55e0f08bbbbde3bbf06b83c822a93d54819b1e8
/app/src/main/java/com/jqsoft/nursing/di/ui/selectadress/adapter/AddressListAdapter.java
9c4364308a4b80f3347c78f54a3681555e726d14
[]
no_license
moshangqianye/nursing
27e58e30a51424502f1b636ae47b60b81a3b2ca0
20cd5aace59555ef9d708df0fb03639b2fc843d0
refs/heads/master
2020-09-08T13:39:55.939252
2020-03-20T09:55:34
2020-03-20T09:55:34
221,147,807
0
0
null
null
null
null
UTF-8
Java
false
false
926
java
package com.jqsoft.nursing.di.ui.selectadress.adapter; import android.support.v4.view.PagerAdapter; import android.support.v4.view.ViewPager; import android.view.View; import java.util.List; public class AddressListAdapter extends PagerAdapter { private List<View> views; public AddressListAdapter( List<View> views) { this.views = views; } @Override public int getCount() { if (views != null) { return views.size(); } return 0; } @Override public void destroyItem(View arg0, int arg1, Object arg2) { ((ViewPager) arg0).removeView(views.get(arg1)); } @Override public Object instantiateItem(View arg0, int arg1) { ((ViewPager) arg0).addView(views.get(arg1), 0); return views.get(arg1); } @Override public boolean isViewFromObject(View arg0, Object arg1) { return arg0 == arg1; } }
[ "123456" ]
123456
85b998921c62a0058703f7ebb5270f98ed7f39b4
e9ce9e01edf7dcf39d440ca24ab5bdd45beccd66
/.svn/pristine/76/76f59975ba8ddd1e460b2923625de5e8f59ef26f.svn-base
ee937ff619010a5a90d967c064161fbc733d57de
[]
no_license
pab993/Acme-Raffle2.0
e01ec3dc40c073282d44b8a79cb4f963744896a4
55622f8dab720e3104058a011b0bc174f2736d0d
refs/heads/master
2021-08-30T16:14:18.736789
2017-12-18T15:44:36
2017-12-18T15:44:36
114,653,845
0
0
null
null
null
null
UTF-8
Java
false
false
495
package converters; import javax.transaction.Transactional; import org.springframework.core.convert.converter.Converter; import org.springframework.stereotype.Component; import domain.Comment; @Component @Transactional public class CommentToStringConverter implements Converter<Comment, String>{ @Override public String convert(Comment comment) { String result; if(comment == null){ result = null; }else{ result = String.valueOf(comment.getId()); } return result; } }
[ "pab993@gmail.com" ]
pab993@gmail.com
db5933bf00c27d580e6214afe62ecf8957a29ecb
a3e59a698c23b9ecfd5e300ec3e55029d75616bd
/app/src/main/java/com/example/juicekaaa/fireserver/manager/FaceEnvironment.java
09426c88fdd22108af014876f9f850fdc753df94
[]
no_license
ChrisTiiii/FaceServer
2e2eaf9d0fb6a222b132c32a7caa16e3cf540f2c
d3bc72282b2fb9a29b22e93cd66f84dba0fcf7a8
refs/heads/master
2020-04-27T04:19:31.900771
2019-03-06T05:33:52
2019-03-06T05:33:52
174,051,120
0
1
null
null
null
null
UTF-8
Java
false
false
4,305
java
package com.example.juicekaaa.fireserver.manager;/* * Copyright (C) 2018 Baidu, Inc. All Rights Reserved. */ import com.baidu.idl.facesdk.FaceDetect; import com.baidu.idl.facesdk.model.BDFaceSDKConfig; /** * SDK全局配置信息 */ public class FaceEnvironment { // SDK版本号 public static final String VERSION = "2.0.0"; public static final float LIVENESS_RGB_THRESHOLD = 0.8f; public static final float LIVENESS_IR_THRESHOLD = 0.8f; public static final float LIVENESS_DEPTH_THRESHOLD = 0.8f; public static boolean isFeatureDetect = false; private BDFaceSDKConfig config; /** * 最小人脸检测大小 建议50 */ public int minFaceSize; /** * 最大人脸检测大小 建议-1(不做限制) */ public int maxFaceSize; /** * 人脸跟踪,检测的时间间隔 默认 500ms */ public int trackInterval; /** * 人脸跟踪,跟踪时间间隔 默认 1000ms */ public int detectInterval; /** * 人脸置信度阈值,建议值0.5 */ public float noFaceSize; /** * 人脸姿态角 pitch,yaw,roll */ public int pitch; public int yaw; public int roll; /** * 质量检测模糊,遮挡,光照,默认不做质量检测 */ public boolean isCheckBlur; public boolean isOcclusion; public boolean isIllumination; /** * 检测图片类型,可见光或者红外 */ public FaceDetect.DetectType detectMethodType; public BDFaceSDKConfig getConfig() { if (config == null) { config = new BDFaceSDKConfig(); config.minFaceSize = getMinFaceSize(); config.maxFaceSize = getMaxFaceSize(); config.trackInterval = getTrackInterval(); config.detectInterval = getDetectInterval(); config.noFaceSize = getNoFaceSize(); config.pitch = getPitch(); config.yaw = getYaw(); config.roll = getRoll(); config.isCheckBlur = isCheckBlur; config.isOcclusion = isOcclusion; config.isIllumination = isIllumination; config.detectMethodType = getDetectMethodType(); } return config; } public void setConfig(BDFaceSDKConfig config) { this.config = config; } public int getMinFaceSize() { return minFaceSize; } public void setMinFaceSize(int minFaceSize) { this.minFaceSize = minFaceSize; } public int getMaxFaceSize() { return maxFaceSize; } public void setMaxFaceSize(int maxFaceSize) { this.maxFaceSize = maxFaceSize; } public int getTrackInterval() { return trackInterval; } public void setTrackInterval(int trackInterval) { this.trackInterval = trackInterval; } public int getDetectInterval() { return detectInterval; } public void setDetectInterval(int detectInterval) { this.detectInterval = detectInterval; } public float getNoFaceSize() { return noFaceSize; } public void setNoFaceSize(float noFaceSize) { this.noFaceSize = noFaceSize; } public int getPitch() { return pitch; } public void setPitch(int pitch) { this.pitch = pitch; } public int getYaw() { return yaw; } public void setYaw(int yaw) { this.yaw = yaw; } public int getRoll() { return roll; } public void setRoll(int roll) { this.roll = roll; } public boolean isCheckBlur() { return isCheckBlur; } public void setCheckBlur(boolean checkBlur) { isCheckBlur = checkBlur; } public boolean isOcclusion() { return isOcclusion; } public void setOcclusion(boolean occlusion) { isOcclusion = occlusion; } public boolean isIllumination() { return isIllumination; } public void setIllumination(boolean illumination) { isIllumination = illumination; } public FaceDetect.DetectType getDetectMethodType() { return detectMethodType; } public void setDetectMethodType(FaceDetect.DetectType detectMethodType) { this.detectMethodType = detectMethodType; } }
[ "454837243@qq.com" ]
454837243@qq.com
582920758e2bd7975d10e345bcd51abb58610450
97ac56789526363c207bc0c08e835d9bd0ae22c8
/padroes-20152/src/p06_builder/parte1/Teste.java
54b6d52a351a60e241d4c3324b2db7b35403541f
[]
no_license
joaoslz/padroes-20152
4a386d51d7f90219f0e88ec23657a18f12373392
bccf9a690185dcab792d9b677307264ae283ea4f
refs/heads/master
2021-01-10T09:52:55.954860
2016-01-14T21:21:09
2016-01-14T21:21:09
45,565,444
0
2
null
2016-01-27T15:47:42
2015-11-04T20:28:13
Java
UTF-8
Java
false
false
990
java
package p06_builder.parte1; import java.util.Arrays; import java.util.Calendar; import java.util.List; class Teste { public static void main(String[] args) { NotaFiscalBuilder builder = new NotaFiscalBuilder(); // builder.paraEmpresa("Empresa XYZ").comCnpj("23.456.789/0001-12").comItem(new Item("Monitor", 500)) // .comItem(new Item("Ultrabook", 2500)).comItem(new Item("Tablet", 1500)) // .comObservacoes("Observação qualquer").naDataAtual(); // // NotaFiscal notaFiscal = builder.constroi(); // // List<Item> itens = Arrays.asList(new Item("Monitor", 500), new Item("Ultrabook", 2500), // new Item("Tablet", 1500)); // double valorTotal = 0; // // for (Item item : itens) { // valorTotal += item.getValorUnitario(); // } // double impostos = valorTotal * 0.05; // // NotaFiscal nf = new NotaFiscal("razao social qualquer", "um cnpj", Calendar.getInstance(), valorTotal, impostos, // itens, "observacoes quaisquer aqui"); } }
[ "joaoslz@gmail.com" ]
joaoslz@gmail.com
fdc31d7feec5619977b46f3dc8e8d137377ce1b3
08ac5d41603383fb9a3707628deee02281812e42
/ds/p2p-api/src/main/java/com/yx/p2p/ds/model/account/DebtSubAccFlow.java
26a949a7fe465c3f66dedbae08ad8ad85751b868
[]
no_license
yaoxin003/p2p
62ecbaa48f1c9008fef56c0ac34dcfd6f89a7d0d
03b580fd398148f625340fa9130fdccfd70fb8e8
refs/heads/master
2022-06-28T13:12:35.378945
2020-07-14T11:49:22
2020-07-14T11:49:22
252,041,185
0
1
null
2022-06-21T03:23:55
2020-04-01T01:31:58
CSS
UTF-8
Java
false
false
1,992
java
package com.yx.p2p.ds.model.account; import com.yx.p2p.ds.model.base.BaseModel; import javax.persistence.Table; import java.io.Serializable; import java.math.BigDecimal; /** * @description:债务子账户流水 * @author: yx * @date: 2020/05/06/16:08 */ @Table(name="p2p_debt_sub_acc_flow") public class DebtSubAccFlow extends BaseModel implements Serializable { private Integer debtSubId ;//债务分户主键 private Integer customerId; //客户编号 private String bizId;//业务编号,如borrow.id private String orderSn;//订单(系统前缀+年月日时分秒毫秒+时间戳) private BigDecimal amount; //金额 private String remark;//备注 public Integer getDebtSubId() { return debtSubId; } public void setDebtSubId(Integer debtSubId) { this.debtSubId = debtSubId; } public Integer getCustomerId() { return customerId; } public void setCustomerId(Integer customerId) { this.customerId = customerId; } public String getBizId() { return bizId; } public void setBizId(String bizId) { this.bizId = bizId; } public String getOrderSn() { return orderSn; } public void setOrderSn(String orderSn) { this.orderSn = orderSn; } public BigDecimal getAmount() { return amount; } public void setAmount(BigDecimal amount) { this.amount = amount; } public String getRemark() { return remark; } public void setRemark(String remark) { this.remark = remark; } @Override public String toString() { return "DebtSubAccFlow{" + "debtSubId=" + debtSubId + ", customerId=" + customerId + ", bizId='" + bizId + '\'' + ", orderSn='" + orderSn + '\'' + ", amount=" + amount + ", remark='" + remark + '\'' + '}' + super.toString(); } }
[ "yaoxin003@aliyun.com" ]
yaoxin003@aliyun.com
ec8c1cf226c0f277282661f70fe2f171951d9fab
028d6009f3beceba80316daa84b628496a210f8d
/core/com.nokia.carbide.templatewizard/src/com/nokia/carbide/templatewizard/TemplateWizardPlugin.java
0fd9a439f851cabef6f239697fe4f657d15801b4
[]
no_license
JamesLinus/oss.FCL.sftools.dev.ide.carbidecpp
fa50cafa69d3e317abf0db0f4e3e557150fd88b3
4420f338bc4e522c563f8899d81201857236a66a
refs/heads/master
2020-12-30T16:45:28.474973
2010-10-20T16:19:31
2010-10-20T16:19:31
null
0
0
null
null
null
null
UTF-8
Java
false
false
1,805
java
/* * Copyright (c) 2006, 2008 Nokia Corporation and/or its subsidiary(-ies). * All rights reserved. * This component and the accompanying materials are made available * under the terms of the License "Eclipse Public License v1.0" * which accompanies this distribution, and is available * at the URL "http://www.eclipse.org/legal/epl-v10.html". * * Initial Contributors: * Nokia Corporation - initial contribution. * * Contributors: * * Description: * */ package com.nokia.carbide.templatewizard; import org.eclipse.jface.resource.ImageDescriptor; import org.eclipse.ui.plugin.AbstractUIPlugin; import org.osgi.framework.BundleContext; /** * The main plugin class to be used in the desktop. */ public class TemplateWizardPlugin extends AbstractUIPlugin { public static final String ID = "com.nokia.carbide.templatewizard"; //$NON-NLS-1$ //The shared instance. private static TemplateWizardPlugin plugin; /** * The constructor. */ public TemplateWizardPlugin() { plugin = this; } /** * This method is called upon plug-in activation */ public void start(BundleContext context) throws Exception { super.start(context); } /** * This method is called when the plug-in is stopped */ public void stop(BundleContext context) throws Exception { super.stop(context); plugin = null; } /** * Returns the shared instance. */ public static TemplateWizardPlugin getDefault() { return plugin; } /** * Returns an image descriptor for the image file at the given * plug-in relative path. * * @param path the path * @return the image descriptor */ public static ImageDescriptor getImageDescriptor(String path) { return AbstractUIPlugin.imageDescriptorFromPlugin(ID, path); } }
[ "Deepak.Modgil@Nokia.com" ]
Deepak.Modgil@Nokia.com
b21c7b042190043e09765245c6718cf7c6993d7a
89dccd331e349cdc5672f3d1b008a0233df1e9e1
/tests/org/elixir_lang/reference/callable/Issue354Test.java
7c72fb8734fc71e62bc1cd571e52d3388dc1335f
[ "Apache-2.0" ]
permissive
hanawa-suzuki/intellij-elixir
7208e1f8fe8e1711be8c801c38d54ebe3597420e
0104c86a4735525439266541299f20fa4368bac6
refs/heads/master
2021-07-16T01:35:25.258205
2017-10-21T15:03:36
2017-10-21T15:03:36
107,917,421
1
0
null
2017-10-23T01:23:36
2017-10-23T01:23:35
null
UTF-8
Java
false
false
2,783
java
package org.elixir_lang.reference.callable; import com.intellij.psi.PsiElement; import com.intellij.psi.PsiReference; import com.intellij.psi.impl.source.tree.LeafPsiElement; import com.intellij.testFramework.fixtures.LightCodeInsightFixtureTestCase; import org.elixir_lang.psi.ElixirIdentifier; import org.elixir_lang.psi.call.Call; import org.elixir_lang.psi.operation.Match; import org.elixir_lang.structure_view.element.CallDefinitionClause; public class Issue354Test extends LightCodeInsightFixtureTestCase { /* * Tests */ public void testLoggerLogstashBackend() { myFixture.configureByFile("logger_logstash_backend.ex"); PsiElement elementAtCaret = myFixture.getFile().findElementAt(myFixture.getCaretOffset()); assertNotNull(elementAtCaret); assertInstanceOf(elementAtCaret, LeafPsiElement.class); PsiElement parent = elementAtCaret.getParent(); assertNotNull(parent); assertInstanceOf(parent, ElixirIdentifier.class); PsiElement grandParent = parent.getParent(); assertNotNull(grandParent); assertInstanceOf(grandParent, Call.class); Call grandParentCall = (Call) grandParent; PsiReference reference = grandParentCall.getReference(); assertNotNull(reference); PsiElement resolved = reference.resolve(); assertNotNull(resolved); assertInstanceOf(resolved, Call.class); PsiElement resolvedParent = resolved.getParent(); assertNotNull(resolvedParent); assertInstanceOf(resolvedParent, Match.class); PsiElement resolvedGrandParent = resolvedParent.getParent(); assertNotNull(resolvedGrandParent); PsiElement resolvedGreatGrandParent = resolvedGrandParent.getParent(); assertNotNull(resolvedGreatGrandParent); PsiElement resolvedGreatGreatGrandParent = resolvedGreatGrandParent.getParent(); assertNotNull(resolvedGreatGreatGrandParent); PsiElement resolvedGreatGreatGreatGrandParent = resolvedGreatGreatGrandParent.getParent(); assertNotNull(resolvedGreatGreatGreatGrandParent); PsiElement resolvedGreatGreatGreatGreatGrandParent = resolvedGreatGreatGreatGrandParent.getParent(); assertNotNull(resolvedGreatGreatGreatGreatGrandParent); assertInstanceOf(resolvedGreatGreatGreatGreatGrandParent, Call.class); Call resolvedGreatGreatGreatGreatGrandParentCall = (Call) resolvedGreatGreatGreatGreatGrandParent; assertTrue(CallDefinitionClause.is(resolvedGreatGreatGreatGreatGrandParentCall)); } /* * Protected Instance Methods */ @Override protected String getTestDataPath() { return "testData/org/elixir_lang/reference/callable/issue_354"; } }
[ "Kronic.Deth@gmail.com" ]
Kronic.Deth@gmail.com
b92643d49eeb3eacdac55dbf10870ce4ad206127
7c75934e75f8af24f2302f1d90ad71a3ea0f76d2
/src/com/uniubi/common/oldlogic/AttendanceLogicCommonTest2Assert12.java
81f4582f59eefba772e6229bf396a7063722a836
[]
no_license
FeeLzheng/InterfaceTest
f6f4749584576c449bd7ec72095a7a838979a445
5d3cca20fd8aeef5daaf6b5e55f3cb86ade0929b
refs/heads/master
2021-01-20T07:20:53.331411
2017-05-02T05:39:40
2017-05-02T05:39:40
89,994,929
0
0
null
null
null
null
UTF-8
Java
false
false
1,490
java
package com.uniubi.common.oldlogic; import static org.junit.Assert.*; public class AttendanceLogicCommonTest2Assert12 extends AttendanceLogicCommonTest2AssertBase { @Override public void Textx_x_last() { assertEquals(employeeDay.getDelayDur(),0); assertEquals(employeeDay.getLeaveDur(),convertMsToMinutes(e1.getTime()-t1_n.getTime())); assertEquals(employeeDay.getAllLeaveDur(),convertMsToMinutes(B1.getTime()-e1.getTime()+f2.getTime()-e2.getTime())); assertEquals(employeeNextDay.getDelayDur(),0); assertEquals(employeeNextDay.getLeaveDur(),convertMsToMinutes(B2.getTime()-t2_n.getTime())); assertEquals(employeeNextDay.getAllLeaveDur(),convertMsToMinutes(f1.getTime()-A2.getTime())); } @Override public void Testx_x_1_all() { assertEquals(employeeDay.getWorkDur(),convertMsToMinutes(t1_n.getTime()-t1_1.getTime())); assertEquals(employeeDay.getDelayDur(),0); assertEquals(employeeDay.getLeaveDur(),convertMsToMinutes(e1.getTime()-t1_n.getTime())); assertEquals(employeeDay.getAllLeaveDur(),convertMsToMinutes(B1.getTime()-e1.getTime())); } @Override public void Testx_x_2_all() { assertEquals(employeeNextDay.getWorkDur(),convertMsToMinutes(t2_n.getTime()-t2_1.getTime()-(f1.getTime()-A2.getTime()))); assertEquals(employeeNextDay.getDelayDur(),0); assertEquals(employeeNextDay.getLeaveDur(),convertMsToMinutes(B2.getTime()-t2_n.getTime())); assertEquals(employeeNextDay.getAllLeaveDur(),convertMsToMinutes(f1.getTime()-A2.getTime())); } }
[ "zhengxiaolong@uni-ubi.com" ]
zhengxiaolong@uni-ubi.com
37995765d3dd8b1ec33b735f7a5bd09df9b14a58
ef70f07c34292814c99a9f42c63efd76da32f9e3
/modules/activiti-form-engine/src/main/java/org/activiti/form/engine/impl/persistence/entity/FormEntityImpl.java
032a9e03f268b35ef3b4b12163959c94a8b0e2eb
[ "Apache-2.0" ]
permissive
inventure/Activiti
e7f8d612296d5d24dda834f99e2b832f51a969fc
b8b429fef335937f0af2b12b05af319407b14bc8
refs/heads/release-next
2020-03-22T10:35:57.002356
2018-07-31T22:34:13
2018-07-31T22:34:13
139,913,870
0
1
Apache-2.0
2018-07-31T22:34:14
2018-07-06T00:26:32
Java
UTF-8
Java
false
false
3,033
java
/* 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.activiti.form.engine.impl.persistence.entity; import java.io.Serializable; import java.util.HashMap; import java.util.Map; import org.activiti.form.engine.FormEngineConfiguration; /** * @author Joram Barrez * @author Tijs Rademakers */ public class FormEntityImpl implements FormEntity, Serializable { private static final long serialVersionUID = 1L; protected String id; protected String name; protected String description; protected String key; protected int version; protected String category; protected String deploymentId; protected String parentDeploymentId; protected String resourceName; protected String tenantId = FormEngineConfiguration.NO_TENANT_ID; public Object getPersistentState() { Map<String, Object> persistentState = new HashMap<String, Object>(); persistentState.put("category", this.category); return persistentState; } // getters and setters // ////////////////////////////////////////////////////// public String getKey() { return key; } public void setKey(String key) { this.key = key; } public String getName() { return name; } public void setName(String name) { this.name = name; } public void setDescription(String description) { this.description = description; } public String getDescription() { return description; } public String getDeploymentId() { return deploymentId; } public void setDeploymentId(String deploymentId) { this.deploymentId = deploymentId; } public String getParentDeploymentId() { return parentDeploymentId; } public void setParentDeploymentId(String parentDeploymentId) { this.parentDeploymentId = parentDeploymentId; } public int getVersion() { return version; } public void setVersion(int version) { this.version = version; } public String getId() { return id; } public void setId(String id) { this.id = id; } public String getResourceName() { return resourceName; } public void setResourceName(String resourceName) { this.resourceName = resourceName; } public String getTenantId() { return tenantId; } public void setTenantId(String tenantId) { this.tenantId = tenantId; } public String getCategory() { return category; } public void setCategory(String category) { this.category = category; } public String toString() { return "FormEntity[" + id + "]"; } }
[ "tijs.rademakers@gmail.com" ]
tijs.rademakers@gmail.com
0dcdc84eec98e7f8046ad059912d1e99811f0a03
ed3cb95dcc590e98d09117ea0b4768df18e8f99e
/project_1_3/src/b/j/f/h/Calc_1_3_19574.java
96c290a51aa0032f367368cc42c6f8ecbaff68ac
[]
no_license
chalstrick/bigRepo1
ac7fd5785d475b3c38f1328e370ba9a85a751cff
dad1852eef66fcec200df10083959c674fdcc55d
refs/heads/master
2016-08-11T17:59:16.079541
2015-12-18T14:26:49
2015-12-18T14:26:49
48,244,030
0
0
null
null
null
null
UTF-8
Java
false
false
134
java
package b.j.f.h; public class Calc_1_3_19574 { /** @return the sum of a and b */ public int add(int a, int b) { return a+b; } }
[ "christian.halstrick@sap.com" ]
christian.halstrick@sap.com
25bbd1bbfacbc20a6acaaee07064708dfd3d0034
258de8e8d556901959831bbdc3878af2d8933997
/washington/washington-core/src/main/java/com/voxlearning/washington/net/message/exam/AfentiExtraRequest.java
661d88ac14ec6a27c3754a6496b18e4303626a41
[]
no_license
Explorer1092/vox
d40168b44ccd523748647742ec376fdc2b22160f
701160b0417e5a3f1b942269b0e7e2fd768f4b8e
refs/heads/master
2020-05-14T20:13:02.531549
2019-04-17T06:54:06
2019-04-17T06:54:06
181,923,482
0
4
null
2019-04-17T15:53:25
2019-04-17T15:53:25
null
UTF-8
Java
false
false
1,016
java
package com.voxlearning.washington.net.message.exam; import com.voxlearning.utopia.api.constant.AfentiState; import com.voxlearning.utopia.service.afenti.api.constant.AfentiLearningType; import lombok.Data; import java.io.Serializable; @Data public class AfentiExtraRequest implements Serializable { private static final long serialVersionUID = 8388236104563275811L; private String bookId; //课本ID private String unitId; //单元ID private Integer rank; //关卡 private AfentiLearningType learningType; // afenti 类型 区分城堡和预习 private AfentiState afentiState; //因子工厂用到 private int successiveSilver; //连对奖励 private String originQuestionId; // 做类题的原题,因子工厂用到 private String scoreCoefficient; // 算法权重,用于数据上报 private Integer unitRank; //单元排序 private boolean skipped; //是否跳过, 因子工厂用到 }
[ "wangahai@300.cn" ]
wangahai@300.cn
25070d8aca88c9d25040da3737de1477a46f9220
1043c01b7637098d046fbb9dba79b15eefbad509
/core/testsuite/src/test/java/com/blazebit/persistence/testsuite/DistinctTest.java
460faa8b466e6b37b0440717e58d25dbf969171b
[ "Apache-2.0", "LicenseRef-scancode-unknown-license-reference" ]
permissive
ares3/blaze-persistence
45c06a3ec25c98236a109ab55a3205fc766734ed
2258e9d9c44bb993d41c5295eccbc894f420f263
refs/heads/master
2020-10-01T16:13:01.380347
2019-12-06T01:24:34
2019-12-09T09:29:49
null
0
0
null
null
null
null
UTF-8
Java
false
false
1,602
java
/* * Copyright 2014 - 2019 Blazebit. * * 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.blazebit.persistence.testsuite; import static org.junit.Assert.assertEquals; import org.junit.Test; import com.blazebit.persistence.CriteriaBuilder; import com.blazebit.persistence.testsuite.AbstractCoreTest; import com.blazebit.persistence.testsuite.entity.Document; /** * * @author Christian Beikov * @author Moritz Becker * @since 1.0.0 */ public class DistinctTest extends AbstractCoreTest { @Test public void testDistinct() { CriteriaBuilder<Document> criteria = cbf.create(em, Document.class, "d"); criteria.select("d.partners.name").distinct(); assertEquals("SELECT DISTINCT partners_1.name FROM Document d LEFT JOIN d.partners partners_1", criteria.getQueryString()); } @Test public void testDistinctWithoutSelect() { CriteriaBuilder<Document> criteria = cbf.create(em, Document.class, "d"); criteria.distinct(); assertEquals("SELECT DISTINCT d FROM Document d", criteria.getQueryString()); } }
[ "christian.beikov@gmail.com" ]
christian.beikov@gmail.com
aab4048098b6f35c495d75a6a1b9ddbbfdaac18e
267fbab5e2fb76e2f37f759fa6c5da4a78f5d779
/src/main/java/ivorius/reccomplex/world/gen/feature/selector/MixingStructureSelector.java
29269451b2f358bb544646baf4ea65cf42f7cee6
[ "MIT" ]
permissive
Ivorforce/RecurrentComplex
4e1caaea47e7fd6a834c092ca9233a169cda24f0
0a17e8d6376b8d998555220258f14bf2f77dd662
refs/heads/master
2023-07-22T10:48:58.962026
2023-07-14T09:22:04
2023-07-14T09:22:04
20,901,878
63
54
MIT
2023-07-14T11:18:29
2014-06-16T21:45:41
Java
UTF-8
Java
false
false
2,586
java
/* * Copyright (c) 2014, Lukas Tenbrink. * * http://ivorius.net */ package ivorius.reccomplex.world.gen.feature.selector; import ivorius.ivtoolkit.random.WeightedSelector; import ivorius.reccomplex.world.gen.feature.structure.Structure; import ivorius.reccomplex.world.gen.feature.structure.generic.generation.GenerationType; import net.minecraft.world.WorldProvider; import net.minecraft.world.biome.Biome; import org.apache.commons.lang3.tuple.Pair; import javax.annotation.Nullable; import java.util.List; import java.util.Map; import java.util.Random; import java.util.stream.Collectors; import java.util.stream.IntStream; /** * Created by lukas on 24.09.16. */ public class MixingStructureSelector<T extends GenerationType & EnvironmentalSelection<C>, C extends MixingStructureSelector.Category> extends StructureSelector<T, C> { public MixingStructureSelector(Map<String, Structure<?>> structures, WorldProvider provider, Biome biome, Class<T> typeClass) { super(structures, provider, biome, typeClass); } public int structuresInBiome(C category, WorldProvider worldProvider, Biome biome, Float distanceToSpawn, Random random) { return category != null ? category.structuresInBiome(biome, worldProvider, totalWeight(category), distanceToSpawn, random) : 0; } public List<Pair<Structure<?>, T>> generatedStructures(Random random, Biome biome, WorldProvider provider, Float distanceToSpawn) { return weightedStructureInfos.keySet().stream() .flatMap(category -> IntStream.range(0, structuresInBiome(category, provider, biome, distanceToSpawn, random)).mapToObj(i -> category)) .map(category -> WeightedSelector.select(random, weightedStructureInfos.get(category))) .collect(Collectors.toList()); } @Nullable public Pair<Structure<?>, T> selectOne(Random random, WorldProvider provider, Biome biome, @Nullable C c, Float distanceToSpawn) { if (c != null) return super.selectOne(random, c); List<WeightedSelector.SimpleItem<C>> list = weightedStructureInfos.keySet().stream() .map(category -> new WeightedSelector.SimpleItem<>(structuresInBiome(category, provider, biome, distanceToSpawn, random), category)) .collect(Collectors.toList()); return selectOne(random, WeightedSelector.select(random, list)); } interface Category { int structuresInBiome(Biome biome, WorldProvider worldProvider, double totalWeight, Float distanceToSpawn, Random random); } }
[ "lukastenbrink@googlemail.com" ]
lukastenbrink@googlemail.com
95cafe1901bf9706a6f8a872afbdf7016f9bd0a3
95c49f466673952b465e19a5ee3ae6eff76bee00
/src/main/java/com/zhihu/android/picture/util/PictureMatrixUtils.java
152940b0a2c3e102373544ddfbf47aebf93db981
[]
no_license
Phantoms007/zhihuAPK
58889c399ae56b16a9160a5f48b807e02c87797e
dcdbd103436a187f9c8b4be8f71bdf7813b6d201
refs/heads/main
2023-01-24T01:34:18.716323
2020-11-25T17:14:55
2020-11-25T17:14:55
null
0
0
null
null
null
null
UTF-8
Java
false
false
2,238
java
package com.zhihu.android.picture.util; import android.graphics.Matrix; import android.graphics.RectF; /* renamed from: com.zhihu.android.picture.util.m */ /* compiled from: PictureMatrixUtils */ public class PictureMatrixUtils { /* renamed from: a */ private static Matrix f82234a = new Matrix(); /* renamed from: a */ public static void m114827a(float f, RectF rectF, RectF rectF2) { m114826a(f, 0, rectF, rectF2); } /* renamed from: a */ public static void m114826a(float f, int i, RectF rectF, RectF rectF2) { f82234a.reset(); if (f == -90.0f || f == 270.0f) { f82234a.postTranslate(0.0f, -rectF.height()); } else if (f == -180.0f || f == 180.0f) { f82234a.postTranslate(-rectF.width(), -rectF.height()); } else if (f == -270.0f || f == 90.0f) { f82234a.postTranslate(-rectF.width(), 0.0f); } f82234a.postRotate(-f); float centerX = rectF.centerX(); float centerY = rectF.centerY(); if (!PictureMathUtils.m114824a(f)) { centerX = centerY; centerY = centerX; } switch (i) { case 1: f82234a.postScale(-1.0f, 1.0f, centerY, centerX); break; case 2: f82234a.postScale(1.0f, -1.0f, centerY, centerX); break; } if (!f82234a.isIdentity()) { f82234a.mapRect(rectF2); } } /* renamed from: a */ public static void m114828a(RectF rectF, RectF rectF2, RectF rectF3, float f) { float f2; float f3; float width = rectF.width() / 2.0f; float height = rectF.height() / 2.0f; if (PictureMathUtils.m114824a(f)) { f3 = (rectF.width() * 1.0f) / rectF2.height(); f2 = (rectF.height() * 1.0f) / rectF2.width(); } else { f3 = (rectF.height() * 1.0f) / rectF2.height(); f2 = (rectF.width() * 1.0f) / rectF2.width(); } float min = Math.min(f3, f2); f82234a.reset(); f82234a.postRotate(f, width, height); f82234a.postScale(min, min, width, height); f82234a.mapRect(rectF3, rectF2); } }
[ "seasonpplp@qq.com" ]
seasonpplp@qq.com
11165ae3d481d92c437b5aacbb3906f478b59ae1
f60aefe7dfc2e8a2969b1acab53430089abcebc1
/eladmin/eladmin-system/src/main/java/me/zhengjie/modules/system/sms/service/SendSmsServiceImpl.java
9b3cf531a0f9d9fe34dd02e21149fc7b9dcea535
[ "Apache-2.0" ]
permissive
luolxb/blockChain
f835529a86929630df714fce02788aec5dd334f5
72432f649cd047eb330b521c35b5cc4ced16fa5b
refs/heads/master
2023-01-08T20:07:21.452840
2020-11-04T05:30:09
2020-11-04T05:30:09
309,875,649
1
0
null
null
null
null
UTF-8
Java
false
false
2,775
java
package me.zhengjie.modules.system.sms.service; import com.alibaba.fastjson.JSONObject; import lombok.extern.slf4j.Slf4j; import me.zhengjie.exception.BadRequestException; import me.zhengjie.modules.system.sms.entity.SendSmsEntity; import me.zhengjie.utils.NtsUtil; import me.zhengjie.utils.RedisKey; import me.zhengjie.utils.RedisUtils; import me.zhengjie.utils.StringUtils; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Value; import org.springframework.http.ResponseEntity; import org.springframework.stereotype.Service; import org.springframework.web.client.RestTemplate; @Service @Slf4j public class SendSmsServiceImpl { @Value("${sms.send.url}") private String sendUrl; @Value("${sms.send.templateid}") private String templateid; @Value("${sms.sid}") private String sid; @Value("${sms.token}") private String token; @Value("${sms.appid}") private String appid; @Autowired private RestTemplate restTemplate; @Autowired private RedisUtils redisUtils; /** * 获取短信验证码 * * @param mobile * @return */ public String getCode(String mobile) { // 验证手机号是否正确 if (!NtsUtil.isPhone(mobile)) { throw new BadRequestException("手机号不正确"); } // 删除之前的验证码 redisUtils.del(RedisKey.SMS_SEND + mobile); // 获取随机验证码 String code = NtsUtil.generateCode2(6); // 验证码有效时间 5分钟 int time = 5; String param = code + "," + time; SendSmsEntity sendSmsEntity = new SendSmsEntity(); sendSmsEntity.setAppid(appid); sendSmsEntity.setMobile(mobile); sendSmsEntity.setTemplateid(templateid); sendSmsEntity.setSid(sid); sendSmsEntity.setToken(token); sendSmsEntity.setParam(param); // 发送 ResponseEntity<String> stringResponseEntity = restTemplate.postForEntity(sendUrl, sendSmsEntity, String.class); String body = stringResponseEntity.getBody(); if (null == body) { log.error("获取验证码异常=>{}", stringResponseEntity); throw new BadRequestException("获取验证码失败"); } JSONObject jsonObject = JSONObject.parseObject(body); String resCode = (String) jsonObject.get("code"); if (!StringUtils.equals(resCode, "000000")) { log.error("获取验证码异常=>{}", body); throw new BadRequestException("获取验证码失败"); } // 加入到redis 5分钟过时 redisUtils.set(RedisKey.SMS_SEND + mobile, code, 60 * time); return code; } }
[ "18687269789@163.com" ]
18687269789@163.com
eb2c16a78e8906af2cc811f31078fa67d356f757
fde12555b15598267c8042deea260e841f4b93a0
/06 - Spring Data/03 - Introduction to Hibernate/jpa-intro/src/main/java/course/springdata/jpaintro/JpaInroMain.java
e7368096b3feff86ed0bac4c92a0d519c4eaac9a
[]
no_license
elenaborisova/SoftUni-Java-Web-Developer-Path
de4cc3c0bb85784815246f23c186aff3f56cc4e8
49b435de458df4d89fcb88742ce96461c325270e
refs/heads/master
2023-07-14T21:10:46.689598
2021-09-03T13:06:28
2021-09-03T13:06:28
null
0
0
null
null
null
null
UTF-8
Java
false
false
1,900
java
package course.springdata.jpaintro; import course.springdata.jpaintro.entity.Student; import javax.persistence.EntityManager; import javax.persistence.EntityManagerFactory; import javax.persistence.Persistence; public class JpaInroMain { public static void main(String[] args) { EntityManagerFactory emf = Persistence.createEntityManagerFactory("school_jpa"); EntityManager em = emf.createEntityManager(); Student student = new Student("Grigor Pavlov"); em.getTransaction().begin(); em.persist(student); em.getTransaction().commit(); Student student2 = new Student("Grigor Pavlov"); em.getTransaction().begin(); em.persist(student2); em.getTransaction().commit(); em.getTransaction().begin(); Student found = em.find(Student.class, 2L); System.out.printf("Found student: %s%n", found); em.getTransaction().commit(); em.getTransaction().begin(); em.createQuery("SELECT s FROM Student s WHERE s.name LIKE :name ORDER BY s.name") .setParameter("name", "%") .getResultList().forEach(System.out::println); em.getTransaction().commit(); em.getTransaction().begin(); // em.remove(found); em.detach(found); found.setName("Atanas Petrov"); Student managedEntity = em.merge(found); // System.out.printf("Same reference: %b", managedEntity == found); System.out.printf("!!! Given student identity: %s, Returned from merge student identity: %s\n", Integer.toHexString(System.identityHashCode(found)), Integer.toHexString(System.identityHashCode(managedEntity))); // Student removed = em.find(Student.class, 1L); // System.out.printf("Removed entity: %s",removed ); em.getTransaction().commit(); em.close(); } }
[ "p.bozidarova@gmail.com" ]
p.bozidarova@gmail.com
430939cbf2443eb05b19a3aad7153ed5ac97c6a1
65ebd9cc9b8ac76522f77c84b70fdc8b2c6d77e6
/src/main/java/com/github/leetcode/hard/Leetcode1159.java
2fa014eaa2af999181c812f9704dcd7ec3a671ce
[]
no_license
SlumDunk/leetcode
30af765c7f5e61317983af43230bafa23362e25a
c242f13e7b3a3ea67cdd70f3d8b216e83bd65829
refs/heads/master
2021-08-20T01:58:11.309819
2021-07-25T17:07:10
2021-07-25T17:07:10
121,602,686
0
0
null
2020-11-08T03:34:35
2018-02-15T07:38:45
Java
UTF-8
Java
false
false
4,667
java
package com.github.leetcode.hard; /** * @Author: zerongliu * @Date: 9/12/19 14:14 * @Description: Table: Users * <p> * +----------------+---------+ * | Column Name | Type | * +----------------+---------+ * | user_id | int | * | join_date | date | * | favorite_brand | varchar | * +----------------+---------+ * user_id is the primary key of this table. * This table has the info of the users of an online shopping website where users can sell and buy items. * Table: Orders * <p> * +---------------+---------+ * | Column Name | Type | * +---------------+---------+ * | order_id | int | * | order_date | date | * | item_id | int | * | buyer_id | int | * | seller_id | int | * +---------------+---------+ * order_id is the primary key of this table. * item_id is a foreign key to the Items table. * buyer_id and seller_id are foreign keys to the Users table. * Table: Items * <p> * +---------------+---------+ * | Column Name | Type | * +---------------+---------+ * | item_id | int | * | item_brand | varchar | * +---------------+---------+ * item_id is the primary key of this table. * <p> * <p> * Write an SQL query to find for each user, whether the brand of the second item (by date) they sold is their favorite brand. If a user sold less than two items, report the answer for that user as no. * <p> * It is guaranteed that no seller sold more than one item on a day. * <p> * The query result format is in the following example: * <p> * Users table: * +---------+------------+----------------+ * | user_id | join_date | favorite_brand | * +---------+------------+----------------+ * | 1 | 2019-01-01 | Lenovo | * | 2 | 2019-02-09 | Samsung | * | 3 | 2019-01-19 | LG | * | 4 | 2019-05-21 | HP | * +---------+------------+----------------+ * <p> * Orders table: * +----------+------------+---------+----------+-----------+ * | order_id | order_date | item_id | buyer_id | seller_id | * +----------+------------+---------+----------+-----------+ * | 1 | 2019-08-01 | 4 | 1 | 2 | * | 2 | 2019-08-02 | 2 | 1 | 3 | * | 3 | 2019-08-03 | 3 | 2 | 3 | * | 4 | 2019-08-04 | 1 | 4 | 2 | * | 5 | 2019-08-04 | 1 | 3 | 4 | * | 6 | 2019-08-05 | 2 | 2 | 4 | * +----------+------------+---------+----------+-----------+ * <p> * Items table: * +---------+------------+ * | item_id | item_brand | * +---------+------------+ * | 1 | Samsung | * | 2 | Lenovo | * | 3 | LG | * | 4 | HP | * +---------+------------+ * <p> * Result table: * +-----------+--------------------+ * | seller_id | 2nd_item_fav_brand | * +-----------+--------------------+ * | 1 | no | * | 2 | yes | * | 3 | yes | * | 4 | no | * +-----------+--------------------+ * <p> * The answer for the user with id 1 is no because they sold nothing. * The answer for the users with id 2 and 3 is yes because the brands of their second sold items are their favorite brands. * The answer for the user with id 4 is no because the brand of their second sold item is not their favorite brand. */ public class Leetcode1159 { public static void main(String[] args) { System.out.println("SELECT\n" + "\tu.user_id AS seller_id,\n" + "CASE\n" + "\t\t\n" + "\t\tWHEN i.item_brand = u.favorite_brand THEN\n" + "\t\t\"yes\" ELSE \"no\" \n" + "\tEND AS 2 nd_item_fav_brand \n" + "FROM\n" + "\tusers u\n" + "\tLEFT JOIN (\n" + "\tSELECT\n" + "\t\to2.order_id,\n" + "\t\to1.seller_id,\n" + "\t\to2.item_id \n" + "\tFROM\n" + "\t\torders o1\n" + "\t\tLEFT JOIN orders o2 ON o1.order_date < o2.order_date \n" + "\t\tAND o1.seller_id = o2.seller_id \n" + "\tGROUP BY\n" + "\t\to2.order_id \n" + "\tHAVING\n" + "\t\tcount( o1.order_id ) = 1 \n" + "\t) o ON u.user_id = o.seller_id\n" + "\tLEFT JOIN items i ON o.item_id = i.item_id \n" + "ORDER BY\n" + "\tseller_id"); } }
[ "1430701240@qq.com" ]
1430701240@qq.com
17505b90667376bf4c702236413607c41a03e353
6d2d4af76f82e154b3aa06531adc248e3201c09b
/src/main/java/com/robertx22/mine_and_slash/database/unique_items/IElementalUnique.java
f150cb73d6fcf7ba1b1e711d68062a1dfdf345f1
[ "LicenseRef-scancode-warranty-disclaimer" ]
no_license
AzureDoom/Mine-and-Slash
4bd16494be00bde5a038bcc01dd66fb45209fe7f
a772326882824039eee814dcff4af321923a5736
refs/heads/AzureBranch
2021-07-10T03:32:16.672923
2020-08-16T03:59:14
2020-08-16T03:59:14
188,708,742
1
3
NOASSERTION
2020-02-24T09:12:49
2019-05-26T16:48:17
Java
UTF-8
Java
false
false
617
java
package com.robertx22.mine_and_slash.database.unique_items; import com.robertx22.mine_and_slash.uncommon.enumclasses.Elements; import com.robertx22.mine_and_slash.uncommon.interfaces.IGenerated; import java.util.ArrayList; import java.util.List; public interface IElementalUnique extends IGenerated<IUnique>, IUnique { IUnique newInstance(Elements element); @Override default List<IUnique> generateAllPossibleStatVariations() { List<IUnique> list = new ArrayList<>(); Elements.getAllSingleElementals() .forEach(x -> list.add(newInstance(x))); return list; } }
[ "treborx555@gmail.com" ]
treborx555@gmail.com
b03d0fb80eb71a8e9e748f658bb5b3ee7bc0691d
bf68fb7ff98d468eccbfa6cd333312d603c1b413
/navslidelibrary/src/main/java/com/yarolegovich/slidingrootnav/transform/root/XTranslationRootTransformation.java
54de834723305178e99d1b4491c76aa210c03651
[]
no_license
hudongcheng/ForkLib
d3f3ad449627db51c4509c71f3ae97bb401c9d7f
bec2213a3d7830fc53cd93106524c1855577a6d4
refs/heads/master
2021-09-23T17:52:55.002429
2018-09-26T03:33:19
2018-09-26T03:33:19
null
0
0
null
null
null
null
UTF-8
Java
false
false
719
java
package com.yarolegovich.slidingrootnav.transform.root; import android.view.View; import com.yarolegovich.slidingrootnav.util.SideNavUtils; /** * Created by yarolegovich on 25.03.2017. */ public class XTranslationRootTransformation implements RootTransformation { private static final float START_TRANSLATION = 0f; private final float endTranslation; public XTranslationRootTransformation(float endTranslation) { this.endTranslation = endTranslation; } @Override public void transform(float dragProgress, View rootView) { float translation = SideNavUtils.evaluate(dragProgress, START_TRANSLATION, endTranslation); rootView.setTranslationX(translation); } }
[ "3521829873@qq.com" ]
3521829873@qq.com
e17c215e6e192c01ca41a4c3c8d058f001ad3adc
2e7f183e5cff6bbfc8c50f66e307138f6e3282e7
/trunk/Launcher/LoginForm$8.java
635147ccf6bb738fb9110687873670effe81c4fe
[]
no_license
BGCX261/zombie-craft-svn-to-git
2e7aee87c90711139e1aa41d2c240c4f4bc1a3f1
72217710ec9f899339478b01f021e2c10b38474c
refs/heads/master
2016-09-05T10:03:04.075184
2015-08-25T15:22:26
2015-08-25T15:22:26
41,586,607
0
0
null
null
null
null
UTF-8
Java
false
false
1,195
java
// Decompiled by Jad v1.5.8g. Copyright 2001 Pavel Kouznetsov. // Jad home page: http://www.kpdus.com/jad.html // Decompiler options: packimports(3) fieldsfirst nonlb safe // Source File Name: LoginForm.java package net.minecraft; import java.awt.*; // Referenced classes of package net.minecraft: // TransparentLabel, LoginForm class LoginForm$8 extends TransparentLabel { private static final long serialVersionUID = 0L; public void paint(Graphics g) { super.paint(g); int x = 0; int y = 0; FontMetrics fm = g.getFontMetrics(); int width = fm.stringWidth(getText()); int height = fm.getHeight(); if(getAlignmentX() == 2.0F) x = 0; else if(getAlignmentX() == 0.0F) x = getBounds().width / 2 - width / 2; else if(getAlignmentX() == 4F) x = getBounds().width - width; y = (getBounds().height / 2 + height / 2) - 1; g.drawLine(x + 2, y, (x + width) - 2, y); } public void update(Graphics g) { paint(g); } LoginForm$8(String $anonymous0) { super($anonymous0); } }
[ "you@example.com" ]
you@example.com
7016bfd60c3ad386a81612fbf92a26272fcdc68f
fb6344bd32572ad2ccedb1e8bed90777f09261ea
/src/main/java/net/jcip/examples/Animals.java
219c866c1e6269fbbd57d01d4316bf212e049ab6
[]
no_license
mosoft521/jcip
1b6f8e6024ee8c71a9543f09aa4c1b924bb4a272
bb6d1042192cdd95f924c23127e9c37b38c9a905
refs/heads/master
2020-12-25T10:59:59.434743
2017-08-15T05:27:54
2017-08-15T05:27:54
64,585,143
0
1
null
null
null
null
UTF-8
Java
false
false
2,332
java
package net.jcip.examples; import java.util.Collection; import java.util.Comparator; import java.util.HashSet; import java.util.Set; import java.util.SortedSet; import java.util.TreeSet; /** * Animals * <p/> * Thread confinement of local primitive and reference variables * * @author Brian Goetz and Tim Peierls */ public class Animals { Ark ark; Species species; Gender gender; public int loadTheArk(Collection<Animal> candidates) { SortedSet<Animal> animals; int numPairs = 0; Animal candidate = null; // animals confined to method, don't let them escape! animals = new TreeSet<Animal>(new SpeciesGenderComparator()); animals.addAll(candidates); for (Animal a : animals) { if (candidate == null || !candidate.isPotentialMate(a)) candidate = a; else { ark.load(new AnimalPair(candidate, a)); ++numPairs; candidate = null; } } return numPairs; } enum Species { AARDVARK, BENGAL_TIGER, CARIBOU, DINGO, ELEPHANT, FROG, GNU, HYENA, IGUANA, JAGUAR, KIWI, LEOPARD, MASTADON, NEWT, OCTOPUS, PIRANHA, QUETZAL, RHINOCEROS, SALAMANDER, THREE_TOED_SLOTH, UNICORN, VIPER, WEREWOLF, XANTHUS_HUMMINBIRD, YAK, ZEBRA } enum Gender { MALE, FEMALE } class Animal { Species species; Gender gender; public boolean isPotentialMate(Animal other) { return species == other.species && gender != other.gender; } } class AnimalPair { private final Animal one, two; public AnimalPair(Animal one, Animal two) { this.one = one; this.two = two; } } class SpeciesGenderComparator implements Comparator<Animal> { public int compare(Animal one, Animal two) { int speciesCompare = one.species.compareTo(two.species); return (speciesCompare != 0) ? speciesCompare : one.gender.compareTo(two.gender); } } class Ark { private final Set<AnimalPair> loadedAnimals = new HashSet<AnimalPair>(); public void load(AnimalPair pair) { loadedAnimals.add(pair); } } }
[ "mosoft521@gmail.com" ]
mosoft521@gmail.com
d1f61222ae619af0fa0433066c94c10626396b1a
5e942a8522f4f8b841a5af408fca90be23482283
/src/main/java/com/yjg/frame/mybatis/UseMybatis.java
7d6e7106e8bbae2f9a885b10f1205dab78eefdc4
[]
no_license
zymap/databases
2f5d64404c46047e990f3e9e6f0acbbeb04f8493
b6160770beff78f5f569d23b0d0265606dfbc42c
refs/heads/master
2021-04-09T16:17:34.564646
2018-03-19T01:48:07
2018-03-19T01:48:07
125,786,863
0
0
null
null
null
null
UTF-8
Java
false
false
2,224
java
package com.yjg.frame.mybatis; import com.yjg.pojo.mybatis.Nyy_org_device; import com.yjg.pojo.mybatis.Nyy_org_tem_data; import org.apache.ibatis.io.Resources; import org.apache.ibatis.session.SqlSession; import org.apache.ibatis.session.SqlSessionFactory; import org.apache.ibatis.session.SqlSessionFactoryBuilder; import java.io.IOException; import java.io.InputStream; import java.util.Collection; import java.util.Iterator; import java.util.List; /** * Created by evan on 17-9-3. */ public class UseMybatis { private static SqlSession sqlSession; private static void init(){ try { InputStream inputStream = Resources.getResourceAsStream("mybatis-config.xml"); SqlSessionFactory sqlSessionFactory = new SqlSessionFactoryBuilder().build(inputStream); Iterator<String> iterator = sqlSessionFactory.getConfiguration().getParameterMapNames().iterator(); // while(iterator.hasNext()){ // String st = iterator.next(); // System.out.println(st); // } // Collection<Object> values = sqlSessionFactory.getConfiguration().getVariables().values(); // for(Object o: values){ // System.out.println(o); // } SqlSession session = sqlSessionFactory.openSession(); sqlSession = session; } catch (IOException e) { e.printStackTrace(); } } public static void insertIntoTem(Nyy_org_tem_data data){ try { init(); MybatisInterface mybatisInterface = sqlSession.getMapper(MybatisInterface.class); mybatisInterface.insertData(data); sqlSession.commit(); }finally { close(); } } public static List<Nyy_org_device> getDeviceList(){ List<Nyy_org_device> devices = null; init(); MybatisInterface mybatisInterface = sqlSession.getMapper(MybatisInterface.class); devices = mybatisInterface.getDevice(); close(); return devices; } public static void close(){ sqlSession.close(); } public static void main(String[] args) { UseMybatis.init(); } }
[ "734206637@qq.com" ]
734206637@qq.com
6d7b46f387cd76b6aa44999cc773c06d0594e830
3a59bd4f3c7841a60444bb5af6c859dd2fe7b355
/sources/kotlin/comparisons/ComparisonsKt__ComparisonsKt$thenByDescending$2.java
ccef0317df12d9de331406e33601a2a2ded19fc8
[]
no_license
sengeiou/KnowAndGo-android-thunkable
65ac6882af9b52aac4f5a4999e095eaae4da3c7f
39e809d0bbbe9a743253bed99b8209679ad449c9
refs/heads/master
2023-01-01T02:20:01.680570
2020-10-22T04:35:27
2020-10-22T04:35:27
null
0
0
null
null
null
null
UTF-8
Java
false
false
1,436
java
package kotlin.comparisons; import java.util.Comparator; import kotlin.Metadata; import kotlin.jvm.functions.Function1; @Metadata(mo39784bv = {1, 0, 3}, mo39785d1 = {"\u0000\n\n\u0000\n\u0002\u0010\b\n\u0002\b\u0007\u0010\u0000\u001a\u00020\u0001\"\u0004\b\u0000\u0010\u0002\"\u0004\b\u0001\u0010\u00032\u000e\u0010\u0004\u001a\n \u0005*\u0004\u0018\u0001H\u0002H\u00022\u000e\u0010\u0006\u001a\n \u0005*\u0004\u0018\u0001H\u0002H\u0002H\n¢\u0006\u0004\b\u0007\u0010\b"}, mo39786d2 = {"<anonymous>", "", "T", "K", "a", "kotlin.jvm.PlatformType", "b", "compare", "(Ljava/lang/Object;Ljava/lang/Object;)I"}, mo39787k = 3, mo39788mv = {1, 1, 15}) /* compiled from: Comparisons.kt */ public final class ComparisonsKt__ComparisonsKt$thenByDescending$2<T> implements Comparator<T> { final /* synthetic */ Comparator $comparator; final /* synthetic */ Function1 $selector; final /* synthetic */ Comparator $this_thenByDescending; public ComparisonsKt__ComparisonsKt$thenByDescending$2(Comparator comparator, Comparator comparator2, Function1 function1) { this.$this_thenByDescending = comparator; this.$comparator = comparator2; this.$selector = function1; } public final int compare(T t, T t2) { int compare = this.$this_thenByDescending.compare(t, t2); return compare != 0 ? compare : this.$comparator.compare(this.$selector.invoke(t2), this.$selector.invoke(t)); } }
[ "joshuahj.tsao@gmail.com" ]
joshuahj.tsao@gmail.com
28e2e531ff41d1f71720ff64ed11574e144ae385
ef0ef41e3cb874cfe762a1905a792b40064fa98b
/codjo-database-sybase/src/main/java/net/codjo/database/sybase/repository/SybaseDatabaseRepository.java
352f1e6c414aeaf3d6f52175dd8c66125b51853c
[]
no_license
codjo-sandbox/codjo-database
6cfa444ca7418f5ad67c8c3a56557b858f0af95a
5c5c1ae80c4ac36d2892da753bd8c61b7c4a603d
refs/heads/integration
2021-01-18T12:19:45.446539
2015-10-19T14:19:57
2015-10-19T14:19:57
3,430,920
0
0
null
null
null
null
UTF-8
Java
false
false
3,290
java
package net.codjo.database.sybase.repository; import net.codjo.database.common.api.DatabaseHelper; import net.codjo.database.common.api.DatabaseQueryHelper; import net.codjo.database.common.api.DatabaseScriptHelper; import net.codjo.database.common.api.confidential.DatabaseTranscoder; import net.codjo.database.common.impl.comparator.DefaultTableComparatorBuilder; import net.codjo.database.common.repository.AbstractDatabaseRepository; import net.codjo.database.common.repository.builder.DatabaseComparatorBuilder; import net.codjo.database.common.repository.builder.ExecSqlScriptBuilder; import net.codjo.database.common.repository.builder.JdbcFixtureBuilder; import net.codjo.database.common.repository.builder.RelationshipBuilder; import net.codjo.database.common.repository.builder.SQLFieldListBuilder; import net.codjo.database.common.repository.builder.TableComparatorBuilder; import net.codjo.database.sybase.impl.SybaseDatabaseTranscoder; import net.codjo.database.sybase.impl.comparator.SybaseDatabaseComparatorBuilder; import net.codjo.database.sybase.impl.fixture.SybaseJdbcFixtureBuilder; import net.codjo.database.sybase.impl.helper.SybaseDatabaseHelper; import net.codjo.database.sybase.impl.helper.SybaseDatabaseScriptHelper; import net.codjo.database.sybase.impl.query.SybaseDatabaseQueryHelper; import net.codjo.database.sybase.impl.relation.SybaseRelationshipBuilder; import net.codjo.database.sybase.impl.script.SybaseExecSqlScriptBuilder; import net.codjo.database.sybase.impl.sqlfield.SybaseSQLFieldListBuilder; public class SybaseDatabaseRepository extends AbstractDatabaseRepository { @Override protected Class<? extends DatabaseHelper> getDatabaseHelperImplementationClass() { return SybaseDatabaseHelper.class; } @Override protected Class<? extends DatabaseQueryHelper> getDatabaseQueryHelperImplementationClass() { return SybaseDatabaseQueryHelper.class; } @Override protected Class<? extends DatabaseScriptHelper> getDatabaseScriptHelperImplementationClass() { return SybaseDatabaseScriptHelper.class; } @Override protected Class<? extends DatabaseTranscoder> getDatabaseTranscoderImplementationClass() { return SybaseDatabaseTranscoder.class; } @Override protected Class<? extends ExecSqlScriptBuilder> getExecSqlScriptBuilderImplementationClass() { return SybaseExecSqlScriptBuilder.class; } @Override public Class<? extends RelationshipBuilder> getRelationshipBuilderImplementationClass() { return SybaseRelationshipBuilder.class; } @Override protected Class<? extends SQLFieldListBuilder> getSQLFIeldListBuilderImplementationClass() { return SybaseSQLFieldListBuilder.class; } @Override protected Class<? extends JdbcFixtureBuilder> getJdbcFixtureBuilderImplementationClass() { return SybaseJdbcFixtureBuilder.class; } @Override protected Class<? extends DatabaseComparatorBuilder> getDatabaseComparatorBuilderImplementationClass() { return SybaseDatabaseComparatorBuilder.class; } @Override protected Class<? extends TableComparatorBuilder> getTableComparatorBuilderImplementationClass() { return DefaultTableComparatorBuilder.class; } }
[ "admin@codjo.net" ]
admin@codjo.net
149ebfb0c932787cc39bcbcd6ba5fe3798e34988
1d928c3f90d4a0a9a3919a804597aa0a4aab19a3
/java/neo4j/2019/8/RelationshipTraversalCursorTest.java
7044d7d4f306ed99b8e171cb8c48b4b334b95932
[]
no_license
rosoareslv/SED99
d8b2ff5811e7f0ffc59be066a5a0349a92cbb845
a062c118f12b93172e31e8ca115ce3f871b64461
refs/heads/main
2023-02-22T21:59:02.703005
2021-01-28T19:40:51
2021-01-28T19:40:51
306,497,459
1
1
null
2020-11-24T20:56:18
2020-10-23T01:18:07
null
UTF-8
Java
false
false
1,014
java
/* * Copyright (c) 2002-2019 "Neo4j," * Neo4j Sweden AB [http://neo4j.com] * * This file is part of Neo4j. * * Neo4j is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation, either version 3 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 Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program. If not, see <http://www.gnu.org/licenses/>. */ package org.neo4j.kernel.impl.newapi; public class RelationshipTraversalCursorTest extends RelationshipTraversalCursorTestBase<ReadTestSupport> { @Override public ReadTestSupport newTestSupport() { return new ReadTestSupport(); } }
[ "rodrigosoaresilva@gmail.com" ]
rodrigosoaresilva@gmail.com
8ed1871baf58ab5575a993d5fae95a12e213fb6c
9dea961c5d203219a683599b1faa94e134a7dac6
/src/main/java/jp/winschool/spring/test10/Test10Controller.java
671d0c773182e647f994acb704ff8933745a0728
[]
no_license
y-akuzawa/SampleTest10
f2bb6d59bcd61a18e82712da0140cbdab589c793
0a69f54ac5d96a3fb7b822767df4c6585302cb40
refs/heads/master
2022-11-07T22:11:07.842412
2020-06-24T02:23:15
2020-06-24T02:23:15
274,549,170
0
0
null
null
null
null
UTF-8
Java
false
false
1,328
java
package jp.winschool.spring.test10; import java.sql.ResultSet; import java.sql.SQLException; import java.util.List; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.jdbc.core.JdbcTemplate; import org.springframework.jdbc.core.RowMapper; import org.springframework.stereotype.Controller; import org.springframework.ui.Model; import org.springframework.web.bind.annotation.GetMapping; @Controller public class Test10Controller { @Autowired private JdbcTemplate jdbcTemplate; @GetMapping("/") public String index(Model model) { String sql = "SELECT id, name, mail, age, gender, contents FROM inquiry"; RowMapper<Inquiry> rowMapper = new RowMapper<Inquiry>() { @Override public Inquiry mapRow(ResultSet rs, int rowNum) throws SQLException { Inquiry inquiry = new Inquiry(); inquiry.setId(rs.getInt("id")); inquiry.setName(rs.getString("name")); inquiry.setMail(rs.getString("mail")); inquiry.setAge(rs.getInt("age")); inquiry.setGender(rs.getString("gender")); inquiry.setContents(rs.getString("contents")); return inquiry; } }; List<Inquiry> inquiries = jdbcTemplate.query(sql, rowMapper); model.addAttribute("inquiries", inquiries); return "index"; } }
[ "=" ]
=
a39ffd23616438582736df922f7ccd0fe26f6932
544cfadc742536618168fc80a5bd81a35a5f2c99
/external/conscrypt/repackaged/benchmark-base/src/main/java/com/android/org/conscrypt/EngineWrapBenchmark.java
5595485e4ce42f114e349c5a29b2a198b2e6df08
[ "Apache-2.0" ]
permissive
ZYHGOD-1/Aosp11
0400619993b559bf4380db2da0addfa9cccd698d
78a61ca023cbf1a0cecfef8b97df2b274ac3a988
refs/heads/main
2023-04-21T20:13:54.629813
2021-05-22T05:28:21
2021-05-22T05:28:21
null
0
0
null
null
null
null
UTF-8
Java
false
false
6,226
java
/* GENERATED SOURCE. DO NOT MODIFY. */ /* * Copyright 2017 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. */ /* * Copyright 2017 The Netty Project * * The Netty Project 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 com.android.org.conscrypt; import static com.android.org.conscrypt.TestUtils.doEngineHandshake; import static com.android.org.conscrypt.TestUtils.newTextMessage; import static org.junit.Assert.assertEquals; import java.nio.ByteBuffer; import java.util.Locale; import javax.net.ssl.SSLEngine; import javax.net.ssl.SSLEngineResult; import javax.net.ssl.SSLException; /** * Benchmark comparing performance of various engine implementations to conscrypt. * @hide This class is not part of the Android public SDK API */ public final class EngineWrapBenchmark { /** * Provider for the benchmark configuration */ interface Config { BufferType bufferType(); EngineFactory engineFactory(); int messageSize(); String cipher(); } private final EngineFactory engineFactory; private final String cipher; private final SSLEngine clientEngine; private final SSLEngine serverEngine; private final ByteBuffer messageBuffer; private final ByteBuffer clientApplicationBuffer; private final ByteBuffer clientPacketBuffer; private final ByteBuffer serverApplicationBuffer; private final ByteBuffer serverPacketBuffer; private final ByteBuffer preEncryptedBuffer; EngineWrapBenchmark(Config config) throws Exception { engineFactory = config.engineFactory(); cipher = config.cipher(); BufferType bufferType = config.bufferType(); clientEngine = engineFactory.newClientEngine(cipher, false); serverEngine = engineFactory.newServerEngine(cipher, false); // Create the application and packet buffers for both endpoints. clientApplicationBuffer = bufferType.newApplicationBuffer(clientEngine); serverApplicationBuffer = bufferType.newApplicationBuffer(serverEngine); clientPacketBuffer = bufferType.newPacketBuffer(clientEngine); serverPacketBuffer = bufferType.newPacketBuffer(serverEngine); // Generate the message to be sent from the client. int messageSize = config.messageSize(); messageBuffer = bufferType.newBuffer(messageSize); messageBuffer.put(newTextMessage(messageSize)); messageBuffer.flip(); // Complete the initial TLS handshake. doEngineHandshake(clientEngine, serverEngine, clientApplicationBuffer, clientPacketBuffer, serverApplicationBuffer, serverPacketBuffer, true); // Populate the pre-encrypted buffer for use with the unwrap benchmark. preEncryptedBuffer = bufferType.newBuffer(clientEngine.getSession().getPacketBufferSize()); doWrap(messageBuffer, preEncryptedBuffer); doUnwrap(preEncryptedBuffer, serverApplicationBuffer); } void teardown() { engineFactory.dispose(clientEngine); engineFactory.dispose(serverEngine); } void wrap() throws SSLException { // Reset the buffers. messageBuffer.position(0); clientPacketBuffer.clear(); // Wrap the original message and create the encrypted data. doWrap(messageBuffer, clientPacketBuffer); // Lightweight comparison - just make sure the data length is correct. assertEquals(preEncryptedBuffer.limit(), clientPacketBuffer.limit()); } /** * Simple benchmark that sends a single message from client to server. */ void wrapAndUnwrap() throws SSLException { // Reset the buffers. messageBuffer.position(0); clientPacketBuffer.clear(); serverApplicationBuffer.clear(); // Wrap the original message and create the encrypted data. doWrap(messageBuffer, clientPacketBuffer); // Unwrap the encrypted data and get back the original result. doUnwrap(clientPacketBuffer, serverApplicationBuffer); // Lightweight comparison - just make sure the unencrypted data length is correct. assertEquals(messageBuffer.limit(), serverApplicationBuffer.limit()); } private void doWrap(ByteBuffer src, ByteBuffer dst) throws SSLException { // Wrap the original message and create the encrypted data. verifyResult(src, clientEngine.wrap(src, dst)); dst.flip(); } private void doUnwrap(ByteBuffer src, ByteBuffer dst) throws SSLException { verifyResult(src, serverEngine.unwrap(src, dst)); dst.flip(); } private void verifyResult(ByteBuffer src, SSLEngineResult result) { if (result.getStatus() != SSLEngineResult.Status.OK) { throw new RuntimeException("Operation returned unexpected result " + result); } if (result.bytesConsumed() != src.limit()) { throw new RuntimeException( String.format(Locale.US, "Operation didn't consume all bytes. Expected %d, consumed %d.", src.limit(), result.bytesConsumed())); } } }
[ "rick_tan@qq.com" ]
rick_tan@qq.com
fde4dc9c4841e59c2a9e8dee7d73a18d803b823c
9661b969a0b1dc82b687db1fa068f67cfa454e66
/code/jackson-core-jackson-core-2.0.0-RC1/src/main/java/com/fasterxml/jackson/core/JsonStreamContext.java
0e39ad24f6e9cdec0b085ad3fdf98b8d75ec15e0
[]
no_license
netwelfare/jsonstar
c68289490435e6b86ed5cde945a81b70fcbf0a08
56c8e653c1343fd49e93bb4c70793a322a770968
refs/heads/master
2020-06-14T00:43:30.396653
2016-12-18T10:27:59
2016-12-18T10:27:59
75,537,290
0
0
null
null
null
null
UTF-8
Java
false
false
3,800
java
/* Jackson JSON-processor. * * Copyright (c) 2007- Tatu Saloranta, tatu.saloranta@iki.fi * * Licensed under the License specified in file LICENSE, included with * the source code and binary code bundles. * You may not use this file except in compliance with the License. * * 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.fasterxml.jackson.core; /** * Shared base class for streaming processing contexts used during * reading and writing of Json content using Streaming API. * This context is also exposed to applications: * context object can be used by applications to get an idea of * relative position of the parser/generator within json content * being processed. This allows for some contextual processing: for * example, output within Array context can differ from that of * Object context. */ public abstract class JsonStreamContext { // // // Type constants used internally protected final static int TYPE_ROOT = 0; protected final static int TYPE_ARRAY = 1; protected final static int TYPE_OBJECT = 2; protected int _type; /** * Index of the currently processed entry. Starts with -1 to signal * that no entries have been started, and gets advanced each * time a new entry is started, either by encountering an expected * separator, or with new values if no separators are expected * (the case for root context). */ protected int _index; /* /********************************************************** /* Life-cycle /********************************************************** */ protected JsonStreamContext() { } /* /********************************************************** /* Public API, accessors /********************************************************** */ /** * Accessor for finding parent context of this context; will * return null for root context. */ public abstract JsonStreamContext getParent(); /** * Method that returns true if this context is an Array context; * that is, content is being read from or written to a Json Array. */ public final boolean inArray() { return _type == TYPE_ARRAY; } /** * Method that returns true if this context is a Root context; * that is, content is being read from or written to without * enclosing array or object structure. */ public final boolean inRoot() { return _type == TYPE_ROOT; } /** * Method that returns true if this context is an Object context; * that is, content is being read from or written to a Json Object. */ public final boolean inObject() { return _type == TYPE_OBJECT; } /** * Method for accessing simple type description of current context; * either ROOT (for root-level values), OBJECT (for field names and * values of JSON Objects) or ARRAY (for values of JSON Arrays) */ public final String getTypeDesc() { switch (_type) { case TYPE_ROOT: return "ROOT"; case TYPE_ARRAY: return "ARRAY"; case TYPE_OBJECT: return "OBJECT"; } return "?"; } /** * @return Number of entries that are complete and started. */ public final int getEntryCount() { return _index + 1; } /** * @return Index of the currently processed entry, if any */ public final int getCurrentIndex() { return (_index < 0) ? 0 : _index; } /** * Method for accessing name associated with the current location. * Non-null for <code>FIELD_NAME</code> and value events that directly * follow field names; null for root level and array values. */ public abstract String getCurrentName(); }
[ "didawangxiaofei@126.com" ]
didawangxiaofei@126.com
42cd2fe06952d97d53276ece3cb6d8f84694e1d0
8630fd79c115cd92d08353904c41f140642336f2
/spring-cloud-provider/src/main/java/com/xwj/auth/AuthUtil.java
ba9f30617ca01b9bace1a4600729cf4d09088540
[]
no_license
xuwenjin/springcloud
2ed85c2bd12b1ec5d4f1e8f10491b50a2f4c56bf
15f6d00da25425d65c9ef08f232be7488eef32a2
refs/heads/master
2023-01-06T11:31:31.140399
2021-05-30T14:09:07
2021-05-30T14:09:07
141,363,314
0
0
null
2022-12-27T14:41:04
2018-07-18T01:14:14
Java
UTF-8
Java
false
false
883
java
package com.xwj.auth; import java.util.concurrent.ConcurrentHashMap; import java.util.concurrent.ConcurrentMap; import java.util.concurrent.atomic.AtomicBoolean; import com.xwj.common.RsaKey; /** * 访问控制 */ public class AuthUtil { /** * 开启鉴权 */ public static AtomicBoolean auth = new AtomicBoolean(false); /** * 启用加密传输 */ public static AtomicBoolean security = new AtomicBoolean(false); // /** // * 保存ip做为黑名单 // */ // public static Set<String> blackLimit = Sets.newConcurrentHashSet(); /** * 保存ip做为白名单,白名单是为了设置访问ip例外的 */ public static ConcurrentMap<String, String> whiteLimit = new ConcurrentHashMap<>();// 操作限制 /** * 记录appId对应的RSA秘钥 */ public static ConcurrentMap<String, RsaKey> rsaKeyMap = new ConcurrentHashMap<>();// 注册操作限制 }
[ "563210736@qq.com" ]
563210736@qq.com
1f515ee33d51bc21dbdc9f606d8b86a722f8cd45
732a6fa36e14baf7f828ef19a62b515312f9a109
/sb/trunk/src/main/java/com/mindalliance/sb/mvc/SubcommitteCapabilityController.java
da2a20df381203d56e88246e2f84efef4eadeea1
[]
no_license
gauravbvt/test
4e991ad3e7dd5ea670ab88f3a74fe8a42418ec20
04e48c87ff5c2209fc4bc703795be3f954909c3a
refs/heads/master
2020-11-24T02:43:32.565109
2014-10-07T23:47:39
2014-10-07T23:47:39
100,468,202
0
0
null
null
null
null
UTF-8
Java
false
false
503
java
package com.mindalliance.sb.mvc; import com.mindalliance.sb.model.SubcommitteeCapability; import org.springframework.roo.addon.web.mvc.controller.scaffold.RooWebScaffold; import org.springframework.stereotype.Controller; import org.springframework.web.bind.annotation.RequestMapping; @RequestMapping("/lists/subcommitteecapabilitys") @Controller @RooWebScaffold(path = "lists/subcommitteecapabilitys", formBackingObject = SubcommitteeCapability.class) public class SubcommitteCapabilityController { }
[ "denis@baad322d-9929-0410-88f0-f92e8ff3e1bd" ]
denis@baad322d-9929-0410-88f0-f92e8ff3e1bd
5ac49677c3caaa5c32ebd96aa4840cc101e15d3f
6989ee91a89d894f78e0f5dcc838ade2821516cd
/src/com/phei/netty/pio/TimeServer.java
11d65b8df90f455fa9d0a9b788c602ce5bfcd38d
[]
no_license
birdstudiocn/NettyDefinitiveGuideSource
54d47cc7b4ddacf4a49c1db178a211d6275ca002
6b0afa812b05fd15782b3d7a754274a9807cf6dc
refs/heads/master
2021-01-01T04:26:37.674627
2016-05-18T02:58:01
2016-05-18T02:58:01
56,043,408
1
1
null
null
null
null
UTF-8
Java
false
false
1,784
java
/* * Copyright 2013-2018 Lilinfeng. * * 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.phei.netty.pio; import java.io.IOException; import java.net.ServerSocket; import java.net.Socket; import com.phei.netty.bio.TimeServerHandler; /** * @author lilinfeng * @date 2014年2月14日 * @version 1.0 */ public class TimeServer { /** * @param args * @throws IOException */ public static void main(String[] args) throws IOException { int port = 8080; if (args != null && args.length > 0) { try { port = Integer.valueOf(args[0]); } catch (NumberFormatException e) { // 采用默认值 } } ServerSocket server = null; try { server = new ServerSocket(port); System.out.println("The time server is start in port : " + port); Socket socket = null; TimeServerHandlerExecutePool singleExecutor = new TimeServerHandlerExecutePool( 50, 10000);// 创建IO任务线程池 while (true) { socket = server.accept(); singleExecutor.execute(new TimeServerHandler(socket)); } } finally { if (server != null) { System.out.println("The time server close"); server.close(); server = null; } } } }
[ "bird_studio@163.com" ]
bird_studio@163.com
51bbb79bebe310c3249dcdd596e2b43ac53714ce
a7c85a1e89063038e17ed2fa0174edf14dc9ed56
/spring-aop-perf-tests/src/main/java/coas/perf/TargetClass500/Advice293.java
7392c64282e331ef2945640173086743d8e56c75
[]
no_license
pmaslankowski/java-contracts
28b1a3878f68fdd759d88b341c8831716533d682
46518bb9a83050956e631faa55fcdf426589830f
refs/heads/master
2021-03-07T13:15:28.120769
2020-09-07T20:06:31
2020-09-07T20:06:31
246,267,189
0
0
null
null
null
null
UTF-8
Java
false
false
738
java
package coas.perf.TargetClass500; import org.aspectj.lang.ProceedingJoinPoint; import org.aspectj.lang.annotation.Around; import org.aspectj.lang.annotation.Aspect; import org.springframework.stereotype.Component; import coas.perf.TargetClass500.Subject500; @Aspect @Component("Advice_500_293") public class Advice293 { private int counter = 0; @Around("execution(* Subject500.*(..))") public Object onTarget(ProceedingJoinPoint joinPoint) throws Throwable { int res = (int) joinPoint.proceed(); for (int i=0; i < 1000; i++) { if (res % 2 == 0) { res /= 2; } else { res = 2 * res + 1; } } return res; } }
[ "pmaslankowski@gmail.com" ]
pmaslankowski@gmail.com
42337b38d24e47d60c7354e1b672f8aada7214ac
5d1077d3d646e587ec3ff5bd69471cf490913761
/platform/src/main/java/com/audio/electric/mapper/AccountMapper.java
50e488d13e9da5d7f9c79b19ba197f0a1901eacc
[]
no_license
yangwu203x/audio_electric
46f55b0e0d478dfab9728d64ad254ce34908491a
39167a9542e3922eea6b1faa00a480bb1ee66be2
refs/heads/master
2021-01-19T20:03:29.689431
2017-07-24T10:35:24
2017-07-24T10:35:24
85,699,571
0
0
null
null
null
null
UTF-8
Java
false
false
1,158
java
package com.audio.electric.mapper; import com.audio.electric.domain.Account; import com.audio.electric.domain.AccountExample; import java.sql.SQLException; import java.util.List; import org.apache.ibatis.annotations.Param; import org.springframework.stereotype.Component; @Component public interface AccountMapper { int countByExample(AccountExample example)throws SQLException; int deleteByExample(AccountExample example)throws SQLException; int deleteByPrimaryKey(Integer id)throws SQLException; int insert(Account record)throws SQLException; int insertSelective(Account record)throws SQLException; List<Account> selectByExample(AccountExample example)throws SQLException; Account selectByPrimaryKey(Integer id)throws SQLException; int updateByExampleSelective(@Param("record") Account record, @Param("example") AccountExample example)throws SQLException; int updateByExample(@Param("record") Account record, @Param("example") AccountExample example)throws SQLException; int updateByPrimaryKeySelective(Account record)throws SQLException; int updateByPrimaryKey(Account record)throws SQLException; }
[ "125667528@qq.com" ]
125667528@qq.com
d4f5e6c93b4be62bf8a82f45d5329b15830d4f3f
84285f6f44ac23fcac02463bb0ab2782c72e1026
/yifubao/core-service-order/src/main/java/com/efubao/core/order/service/impl/GenerateSerialNumberServiceImpl.java
7f91a42e93b82e1eebebc75314ba2287f59b5613
[]
no_license
lichao20000/projects-web
f68122493861dd2a9f141c941534e55faacbd535
da34ce2468731eeff5ba0ae3948e4814e2413ac5
refs/heads/master
2021-12-10T09:41:30.578734
2016-08-05T04:13:41
2016-08-05T04:13:41
null
0
0
null
null
null
null
UTF-8
Java
false
false
837
java
package com.efubao.core.order.service.impl; import java.util.HashMap; import java.util.Map; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; import com.efubao.core.order.mapper.GenerateSerialNumberMapper; import com.efubao.core.order.service.GenerateSerialNumberService; @Service public class GenerateSerialNumberServiceImpl implements GenerateSerialNumberService { @Autowired private GenerateSerialNumberMapper generateSerialNumberMapper; @Override public String getSerialNumber(SerialNumberEnum Type) { Map<String,Object> parameterMap = new HashMap<String,Object>(); parameterMap.put("type", Type.getValue()); parameterMap.put("orderNo", -1); generateSerialNumberMapper.getSerialNumber(parameterMap); return (String)parameterMap.get("orderNo"); } }
[ "duandingyang@bjtu.edu.cn" ]
duandingyang@bjtu.edu.cn
ff5f5228cb09a6986a98c86f20e14f6a8f2d7452
efb7efbbd6baa5951748dfbe4139e18c0c3608be
/sources/kotlin/jvm/internal/TypeReference$asString$args$1.java
bc5273590ec50f49184b7775706e8c3b31fae666
[]
no_license
blockparty-sh/600302-1_source_from_JADX
08b757291e7c7a593d7ec20c7c47236311e12196
b443bbcde6def10895756b67752bb1834a12650d
refs/heads/master
2020-12-31T22:17:36.845550
2020-02-07T23:09:42
2020-02-07T23:09:42
239,038,650
0
0
null
null
null
null
UTF-8
Java
false
false
1,055
java
package kotlin.jvm.internal; import kotlin.Metadata; import kotlin.jvm.functions.Function1; import kotlin.reflect.KTypeProjection; import org.jetbrains.annotations.NotNull; @Metadata(mo37403bv = {1, 0, 3}, mo37404d1 = {"\u0000\u000e\n\u0000\n\u0002\u0010\u000e\n\u0000\n\u0002\u0018\u0002\n\u0000\u0010\u0000\u001a\u00020\u00012\u0006\u0010\u0002\u001a\u00020\u0003H\n¢\u0006\u0002\b\u0004"}, mo37405d2 = {"<anonymous>", "", "it", "Lkotlin/reflect/KTypeProjection;", "invoke"}, mo37406k = 3, mo37407mv = {1, 1, 15}) /* compiled from: TypeReference.kt */ final class TypeReference$asString$args$1 extends Lambda implements Function1<KTypeProjection, String> { final /* synthetic */ TypeReference this$0; TypeReference$asString$args$1(TypeReference typeReference) { this.this$0 = typeReference; super(1); } @NotNull public final String invoke(@NotNull KTypeProjection kTypeProjection) { Intrinsics.checkParameterIsNotNull(kTypeProjection, "it"); return this.this$0.asString(kTypeProjection); } }
[ "hello@blockparty.sh" ]
hello@blockparty.sh
2946f17065d8ea31696ca26a16076382af527b09
d47fccd04dfdcc65fbedafc33b8ef765c792f7e4
/graphql-java-runtime/src/main/java/com/graphql_java_generator/client/SubscriptionCallback.java
87a6209e7cb74f414e5b458d183030ba6393a81c
[ "MIT", "LicenseRef-scancode-unknown-license-reference" ]
permissive
crypitor/graphql-maven-plugin-project
b7450ab07c90931d95486686d5f321d9dc44273d
ef9035154997b617e9eebc9eff37a2b64ce4ad4f
refs/heads/master
2023-07-16T23:19:44.006171
2021-08-30T20:27:52
2021-08-30T20:27:52
null
0
0
null
null
null
null
UTF-8
Java
false
false
1,778
java
/** * */ package com.graphql_java_generator.client; import org.eclipse.jetty.websocket.api.annotations.OnWebSocketClose; import org.eclipse.jetty.websocket.api.annotations.OnWebSocketError; import org.eclipse.jetty.websocket.api.annotations.OnWebSocketMessage; /** * This interface will receive the notification for each message that comes from a subscription. The message sent by the * server is mapped on the T class. * * @param <T> * The java class that maps to the GraphQL type returned by the subscription.<BR/> * For instance, for the subscription the T parameter should be <I>Human</I> * * <PRE> * subscribeNewHumanForEpisode(episode: Episode!): Human! * </PRE> * * @author etienne-sf */ public interface SubscriptionCallback<T> { /** * This method is called once the subscription has been submitted to the GraphQL server. It's an information call: * no special action is expected. */ public void onConnect(); /** * This method is called each time a message is sent by the server, for this subscription. It's an information call: * no special action is expected. * * @param t * @see {@link OnWebSocketMessage} */ public void onMessage(T t); /** * A callback to make the program aware of the end of the subscription channel. It's an information call: no special * action is expected. * * @param statusCode * @param reason * @see {@link OnWebSocketClose} */ public void onClose(int statusCode, String reason); /** * Whenever an error occurs, at any time of the subscription processing. It's an information call: no special action * is expected. * * @param cause * @see {@link OnWebSocketError} */ public void onError(Throwable cause); }
[ "etienne_sf@users.sf.net" ]
etienne_sf@users.sf.net
93bf4a85ad3f23a1886f056e4df8c75c44b10407
028e127d616e5a94b3c7ebd1b7a83560082925a2
/chapter03/src/main/java/com/ssmr/chapter03/dao/RoleDao.java
45b89dae0652e5217480fa9cc9a5744b33e39442
[]
no_license
JeeLearner/learning-ssmr
3caf8375495a553dc7c09a78512f6ed51222de45
810f1fe1f2cf280e5f1f86a802d55f9cf20b79bc
refs/heads/master
2021-09-01T06:08:14.116431
2017-12-25T08:43:16
2017-12-25T08:43:16
112,420,950
11
3
null
null
null
null
UTF-8
Java
false
false
321
java
package com.ssmr.chapter03.dao; import com.ssmr.chapter03.pojo.Role; import java.util.List; public interface RoleDao { public int insertRole(Role role); public int deleteRole(Long id); public int updateRole(Role role); public Role getRole(Long id); public List<Role> findRoles(String roleName); }
[ "15501112566@163.com" ]
15501112566@163.com
111ccf70fd6bf3c310a60f8cb53345287bceb4c6
f0f130ad22385bce8f1a8718509e708bca4620f8
/src/com/example/CourierApp/util/CommonUtil.java
2e01676cc7e5a2337b67df72826dae91a69471d2
[]
no_license
eryiyi/CourierApp1
e183a8c2e35940cb3169707474058f8b518e7707
90038e9e7cd2c803f2ad6f14a419defffd18b10a
refs/heads/master
2021-01-10T11:50:40.700236
2016-02-28T10:09:37
2016-02-28T10:09:37
51,970,197
0
0
null
null
null
null
UTF-8
Java
false
false
928
java
package com.example.CourierApp.util; import android.content.Context; import com.android.volley.RequestQueue; import com.android.volley.toolbox.Volley; import com.google.gson.Gson; /** * Created by apple on 15/4/3. */ public class CommonUtil { private volatile static RequestQueue requestQueue; private volatile static Gson gson; public static RequestQueue getRequestQueue(Context context){ if (requestQueue == null){ synchronized (CommonUtil.class){ if (requestQueue == null){ requestQueue = Volley.newRequestQueue(context); } } } return requestQueue; } public static Gson getGson(){ if (gson == null){ synchronized (CommonUtil.class){ if (gson == null){ gson = new Gson(); } } } return gson; } }
[ "826321978@qq.com" ]
826321978@qq.com
9aab6ecb8616b2bc46ddba28c10023a3590cbb7b
a4bffc00df9feca2ae6baad2a724ca3662bc9fc7
/library/src/test/java/com/dslplatform/json/generated/types/Boolean/OneSetOfOneBooleansDefaultValueTurtle.java
cbb8931554e1e13304fb9d78b33d6b349951aa9b
[ "BSD-3-Clause" ]
permissive
ngs-doo/dsl-json
746db2156f4b5693b6df551aabf8e0d761caa32b
f560001ce8a0702977240f60e48aae0d6a4b70af
refs/heads/master
2023-08-04T14:07:00.271727
2023-07-23T12:12:45
2023-07-23T12:12:45
45,384,078
1,000
134
BSD-3-Clause
2023-07-23T12:09:00
2015-11-02T09:17:39
Java
UTF-8
Java
false
false
3,268
java
package com.dslplatform.json.generated.types.Boolean; import com.dslplatform.json.generated.types.StaticJson; import com.dslplatform.json.generated.ocd.javaasserts.BooleanAsserts; import java.io.IOException; public class OneSetOfOneBooleansDefaultValueTurtle { private static StaticJson.JsonSerialization jsonSerialization; @org.junit.BeforeClass public static void initializeJsonSerialization() throws IOException { jsonSerialization = StaticJson.getSerialization(); } @org.junit.Test public void testDefaultValueEquality() throws IOException { final java.util.Set<Boolean> defaultValue = new java.util.HashSet<Boolean>(0); final StaticJson.Bytes defaultValueJsonSerialized = jsonSerialization.serialize(defaultValue); final java.util.List<Boolean> deserializedTmpList = jsonSerialization.deserializeList(Boolean.class, defaultValueJsonSerialized.content, defaultValueJsonSerialized.length); final java.util.Set<Boolean> defaultValueJsonDeserialized = deserializedTmpList == null ? null : new java.util.HashSet<Boolean>(deserializedTmpList); BooleanAsserts.assertOneSetOfOneEquals(defaultValue, defaultValueJsonDeserialized); } @org.junit.Test public void testBorderValue1Equality() throws IOException { final java.util.Set<Boolean> borderValue1 = new java.util.HashSet<Boolean>(java.util.Arrays.asList(false)); final StaticJson.Bytes borderValue1JsonSerialized = jsonSerialization.serialize(borderValue1); final java.util.List<Boolean> deserializedTmpList = jsonSerialization.deserializeList(Boolean.class, borderValue1JsonSerialized.content, borderValue1JsonSerialized.length); final java.util.Set<Boolean> borderValue1JsonDeserialized = deserializedTmpList == null ? null : new java.util.HashSet<Boolean>(deserializedTmpList); BooleanAsserts.assertOneSetOfOneEquals(borderValue1, borderValue1JsonDeserialized); } @org.junit.Test public void testBorderValue2Equality() throws IOException { final java.util.Set<Boolean> borderValue2 = new java.util.HashSet<Boolean>(java.util.Arrays.asList(true)); final StaticJson.Bytes borderValue2JsonSerialized = jsonSerialization.serialize(borderValue2); final java.util.List<Boolean> deserializedTmpList = jsonSerialization.deserializeList(Boolean.class, borderValue2JsonSerialized.content, borderValue2JsonSerialized.length); final java.util.Set<Boolean> borderValue2JsonDeserialized = deserializedTmpList == null ? null : new java.util.HashSet<Boolean>(deserializedTmpList); BooleanAsserts.assertOneSetOfOneEquals(borderValue2, borderValue2JsonDeserialized); } @org.junit.Test public void testBorderValue3Equality() throws IOException { final java.util.Set<Boolean> borderValue3 = new java.util.HashSet<Boolean>(java.util.Arrays.asList(false, true)); final StaticJson.Bytes borderValue3JsonSerialized = jsonSerialization.serialize(borderValue3); final java.util.List<Boolean> deserializedTmpList = jsonSerialization.deserializeList(Boolean.class, borderValue3JsonSerialized.content, borderValue3JsonSerialized.length); final java.util.Set<Boolean> borderValue3JsonDeserialized = deserializedTmpList == null ? null : new java.util.HashSet<Boolean>(deserializedTmpList); BooleanAsserts.assertOneSetOfOneEquals(borderValue3, borderValue3JsonDeserialized); } }
[ "rikard@ngs.hr" ]
rikard@ngs.hr
26175eea74ce551707d66e622e5a9c7de8f67bd0
e04c596465a5099bfb968cff1510f495e8e83fde
/AM-Resources/src/main/java/am/main/data/jaxb/am/logger/AMApplications.java
7ab3183e678244b3f2d8614cfc98e0f91f5f2602
[]
no_license
AhmedMater/AM
47adb350706656081683ec6cca05f63e472531b9
1e0d11f16d71abd37e83348073e32cf1885a6ccc
refs/heads/master
2021-01-13T09:47:00.052056
2018-02-13T03:47:05
2018-02-13T03:47:05
71,176,787
0
0
null
null
null
null
UTF-8
Java
false
false
1,992
java
package am.main.data.jaxb.am.logger; import java.util.ArrayList; import java.util.List; import javax.xml.bind.annotation.XmlAccessType; import javax.xml.bind.annotation.XmlAccessorType; import javax.xml.bind.annotation.XmlElement; import javax.xml.bind.annotation.XmlType; /** * <p>Java class for AM-Applications complex type. * * <p>The following schema fragment specifies the expected content contained within this class. * * <pre> * &lt;complexType name="AM-Applications"> * &lt;complexContent> * &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"> * &lt;sequence> * &lt;element name="AM-Application" type="{}AM-Application" maxOccurs="unbounded"/> * &lt;/sequence> * &lt;/restriction> * &lt;/complexContent> * &lt;/complexType> * </pre> * * */ @XmlAccessorType(XmlAccessType.FIELD) @XmlType(name = "AM-Applications", propOrder = { "amApplication" }) public class AMApplications { @XmlElement(name = "AM-Application", required = true) protected List<AMApplication> amApplication; /** * Gets the value of the amApplication property. * * <p> * This accessor method returns a reference to the live list, * not a snapshot. Therefore any modification you make to the * returned list will be present inside the JAXB object. * This is why there is not a <CODE>set</CODE> method for the amApplication property. * * <p> * For example, to add a new item, do as follows: * <pre> * getAMApplication().add(newItem); * </pre> * * * <p> * Objects of the following type(s) are allowed in the list * {@link AMApplication } * * */ public List<AMApplication> getAMApplication() { if (amApplication == null) { amApplication = new ArrayList<AMApplication>(); } return this.amApplication; } }
[ "ahmedmotair@gmail.com" ]
ahmedmotair@gmail.com
13e997338dd6c26be5b91faf128964d6d13a8a58
869b4845a43c53b65273edb00a255256f17011c0
/regression/TimingFrameworkDemo/src/org/jdesktop/core/animation/timing/sources/ScheduledExecutorTimingSource.java
334f75145bb7cb976fdd192f4c3fd625a5418841
[]
no_license
surelogic/regression
62879ef0b7dd197dfc6961e08fc2f71e3e0ced2a
a391ebc3959f730d2607e3bdfa9239a999b861c5
refs/heads/master
2021-04-30T23:41:12.571603
2016-04-20T16:50:26
2016-04-20T16:50:26
50,687,446
0
0
null
null
null
null
UTF-8
Java
false
false
2,978
java
package org.jdesktop.core.animation.timing.sources; import java.util.concurrent.Executors; import java.util.concurrent.ScheduledExecutorService; import java.util.concurrent.TimeUnit; import org.jdesktop.core.animation.timing.TimingSource; import com.surelogic.ThreadSafe; import com.surelogic.Vouch; /** * A timing source using a {@link ScheduledExecutorService} as returned from * {@link Executors#newSingleThreadScheduledExecutor()}. * <p> * A typical use, where {@code tl} is a {@code TickListener} object, would be * * <pre> * TimingSource ts = new ScheduledExecutorTimingSource(15, TimeUnit.MILLISECONDS); * ts.init(); // starts the timer * * ts.addTickListener(tl); // tl gets tick notifications * * ts.removeTickListener(tl); // tl stops getting notifications * * ts.dispose(); // done using ts * </pre> * * If you are not sure what period to set, use the * {@link #ScheduledExecutorTimingSource()} constructor which uses a reasonable * default value of 15 milliseconds. * <p> * Calls to registered {@code TickListener} and {@code PostTickListener} objects * from this timing source are always made in the context of a single thread. * This thread is the thread created by * {@link Executors#newSingleThreadScheduledExecutor()}. Further, any tasks * submitted to {@link #submit(Runnable)} are run in this thread context as * well. * * @author Tim Halloran */ @ThreadSafe public final class ScheduledExecutorTimingSource extends TimingSource { @Vouch("ThreadSafe") private final ScheduledExecutorService f_executor; private final long f_period; private final TimeUnit f_periodTimeUnit; /** * Constructs a new instance. The {@link #init()} must be called on the new * instance to start the timer. The {@link #dispose()} method should be called * to stop the timer. * * @param period * the period of time between "tick" events. * @param unit * the time unit of period parameter. */ public ScheduledExecutorTimingSource(long period, TimeUnit unit) { f_period = period; f_periodTimeUnit = unit; f_executor = Executors.newSingleThreadScheduledExecutor(); } /** * Constructs a new instance with a period of 15 milliseconds. The * {@link #init()} must be called on the new instance to start the timer. The * {@link #dispose()} method should be called to stop the timer. */ public ScheduledExecutorTimingSource() { this(15, TimeUnit.MILLISECONDS); } @Override public void init() { f_executor.scheduleAtFixedRate(new Runnable() { @Override public void run() { getNotifyTickListenersTask().run(); } }, 0, f_period, f_periodTimeUnit); } @Override public void dispose() { f_executor.shutdown(); } @Override protected void runTaskInThreadContext(Runnable task) { f_executor.submit(task); } }
[ "edwin.chan@surelogic.com" ]
edwin.chan@surelogic.com
7ad3dbb520572f9485bcc45fd5411cb40d3e607a
19c6fc6fc87617a6164de9d6388d896b2d9e441e
/cpucode_spring_aop/src/main/java/com/cpucode/proxy/jdk/Target.java
1302aa55068e831062bbefb63d5c2022642ca7da
[]
no_license
CPU-Code/Spring
455e3f47ef8229506a7e8a51963e408a65693385
82a193d8e10283b689a2bedf5c55adb34c1e4181
refs/heads/main
2023-06-13T22:40:48.768319
2021-07-05T12:25:48
2021-07-05T12:25:48
339,593,326
0
0
null
null
null
null
UTF-8
Java
false
false
326
java
package com.cpucode.proxy.jdk; /** * @author : cpucode * @date : 2021/2/18 * @time : 9:43 * @github : https://githfub.com/CPU-Code * @csdn : https://blog.csdn.net/qq_44226094 */ public class Target implements TargetInterface{ public void save() { System.out.println("Target 中 save 跑起来了"); } }
[ "923992029@qq.com" ]
923992029@qq.com
fe35a560537c08c69d235a7a4d57da9c4346275a
5076d14c853effaa65be6103fa4d47e246b3ca27
/src/main/java/com/tyc/service/TblCustomTypeService.java
1d4171d9deba175cfa5b88a792291aceb06ec46f
[]
no_license
Tang5566/family_service_platform
cea82017c5517518e0f501f19491da0591a5ab25
2b02d39198ae0ef8baa33456a81ab79a28370aba
refs/heads/master
2023-03-06T14:20:38.861485
2021-02-23T13:56:37
2021-02-23T13:56:37
341,571,675
0
0
null
null
null
null
UTF-8
Java
false
false
304
java
package com.tyc.service; import com.tyc.bean.TblCustomType; import com.baomidou.mybatisplus.extension.service.IService; /** * <p> * 自定义类型 服务类 * </p> * * @author tyc * @since 2021-02-20 */ public interface TblCustomTypeService extends IService<TblCustomType> { }
[ "1213859735@qq.com" ]
1213859735@qq.com
ab22b41eb6da6d3836fd2a2be540b46333a1359f
96f50632c678f7a6232e9fdb5ccd9b5de2288279
/app/src/main/java/com/tshang/peipei/model/request/RequestRewardJoin.java
46f6059f6955e75458f729428d92eb38b45a9ceb
[]
no_license
iuvei/peipei
629c17c2f8ddee98d4747d2cbec37b2209e78af4
0497dc9389287664e96e9d14381cd6078e114979
refs/heads/master
2020-11-26T22:20:32.990823
2019-03-16T07:19:40
2019-03-16T07:19:40
null
0
0
null
null
null
null
UTF-8
Java
false
false
2,439
java
package com.tshang.peipei.model.request; import java.math.BigInteger; import com.tshang.peipei.model.interfaces.ISocketMsgCallBack; import com.tshang.peipei.network.socket.AppQueueManager; import com.tshang.peipei.network.socket.PeiPeiRequest; import com.tshang.peipei.protocol.asn.AsnBase; import com.tshang.peipei.protocol.asn.gogirl.GoGirlPkt; import com.tshang.peipei.protocol.asn.gogirl.ReqParticipateAward; import com.tshang.peipei.protocol.asn.gogirl.RspParticipateAward; import com.tshang.peipei.protocol.asn.ydmxall.PKTS; import com.tshang.peipei.protocol.asn.ydmxall.YdmxMsg; /** * @Title: RequestRewardPrivateChat.java * * @Description: 悬赏私聊 * * @author Aaron * * @date 2015-8-17 下午7:47:03 * * @version V1.0 */ public class RequestRewardJoin extends AsnBase implements ISocketMsgCallBack { private GetRewardJoinCallBack callBack; public void requestJoinReward(byte[] auth, int ver, int uid, int type, int awarduid, int selfuid, int awardid, GetRewardJoinCallBack callBack) { YdmxMsg ydmxMsg = super.createYdmx(auth, ver); ReqParticipateAward req = new ReqParticipateAward(); req.type = BigInteger.valueOf(type); req.awarduid = BigInteger.valueOf(awarduid); req.selfuid = BigInteger.valueOf(selfuid); req.awardid = BigInteger.valueOf(awardid); // 整合成完整消息体 GoGirlPkt goGirlPkt = new GoGirlPkt(); goGirlPkt.choiceId = GoGirlPkt.REQPARTICIPATEAWARD_CID; goGirlPkt.reqparticipateaward = req; PKTS body = new PKTS(); body.choiceId = PKTS.GOGIRLPKT_CID; body.gogirlpkt = goGirlPkt; ydmxMsg.body = body; byte[] msg = encode(ydmxMsg); PeiPeiRequest request = new PeiPeiRequest(msg, this, false); this.callBack = callBack; AppQueueManager.getInstance().addRequest(request); } @Override public void succuess(byte[] msg) { // 解包 YdmxMsg ydmxMsg = (YdmxMsg) AsnBase.decode(msg); GoGirlPkt pkt = ydmxMsg.body.gogirlpkt; if (null != callBack) { RspParticipateAward rsp = pkt.rspparticipateaward; int retCode = rsp.retcode.intValue(); String message = new String(rsp.retmsg); callBack.onJoinSuccess(retCode, message); } } @Override public void error(int resultCode) { callBack.onJoinError(resultCode); } public interface GetRewardJoinCallBack { public void onJoinSuccess(int code, String msg); public void onJoinError(int code); } }
[ "xumin2@evergrande.com" ]
xumin2@evergrande.com
62878d00e43676af7fa9d5591727fa4eb072eb35
a770e95028afb71f3b161d43648c347642819740
/sources/org/telegram/messenger/MessagesController$$ExternalSyntheticLambda274.java
1ac73e5b3b4d5dd7bbd78b4d477e2f371713da72
[]
no_license
Edicksonjga/TGDecompiledBeta
d7aa48a2b39bbaefd4752299620ff7b72b515c83
d1db6a445d5bed43c1dc8213fb8dbefd96f6c51b
refs/heads/master
2023-08-25T04:12:15.592281
2021-10-28T20:24:07
2021-10-28T20:24:07
null
0
0
null
null
null
null
UTF-8
Java
false
false
1,312
java
package org.telegram.messenger; import org.telegram.tgnet.RequestDelegate; import org.telegram.tgnet.TLObject; import org.telegram.tgnet.TLRPC$TL_error; import org.telegram.tgnet.TLRPC$TL_messages_editChatDefaultBannedRights; import org.telegram.ui.ActionBar.BaseFragment; public final /* synthetic */ class MessagesController$$ExternalSyntheticLambda274 implements RequestDelegate { public final /* synthetic */ MessagesController f$0; public final /* synthetic */ long f$1; public final /* synthetic */ BaseFragment f$2; public final /* synthetic */ TLRPC$TL_messages_editChatDefaultBannedRights f$3; public final /* synthetic */ boolean f$4; public /* synthetic */ MessagesController$$ExternalSyntheticLambda274(MessagesController messagesController, long j, BaseFragment baseFragment, TLRPC$TL_messages_editChatDefaultBannedRights tLRPC$TL_messages_editChatDefaultBannedRights, boolean z) { this.f$0 = messagesController; this.f$1 = j; this.f$2 = baseFragment; this.f$3 = tLRPC$TL_messages_editChatDefaultBannedRights; this.f$4 = z; } public final void run(TLObject tLObject, TLRPC$TL_error tLRPC$TL_error) { this.f$0.lambda$setDefaultBannedRole$70(this.f$1, this.f$2, this.f$3, this.f$4, tLObject, tLRPC$TL_error); } }
[ "fabian_pastor@msn.com" ]
fabian_pastor@msn.com
f28b96fb7147679b8bc3fd75ce2de9dc914b5d68
768754287090c335417da829e2c68c7482225c95
/2190/470908_AC_1480MS_1500K.java
6ad49ea485a2ed796e529bdbf3dc7cff39c4a783
[]
no_license
zhangfaen/pku-online-judge
f6a276eaac28a39b00133133ccaf3402f5334184
e770ce41debe1cf832f4859528c7c751509ab97c
refs/heads/master
2021-04-23T16:52:00.365894
2020-03-25T09:59:52
2020-03-25T09:59:52
249,941,140
0
0
null
null
null
null
UTF-8
Java
false
false
884
java
import java.util.*; import java.io.*; public class Main { public static void main(String [] args)throws Exception { //InputStream in=new FileInputStream("c:\\in.txt"); Scanner cin=new Scanner(System.in); String s=cin.next(); int index=-1; int sum=0; for(int i=0;i<s.length();i++) { if(s.charAt(i)=='?') index=i; else { int t; if(s.charAt(i)=='X') t=10; else t=s.charAt(i)-'0'; sum+=(10-i)*(t); } } int d=10-index; if(d==1) { for(int i=0;i<=10;i++) { if((sum+i*d)%11==0) { if(i!=10) System.out.println(i); else System.out.println('X'); return; } } } else { for(int i=0;i<=9;i++) { if((sum+i*d)%11==0) { System.out.println(i); return; } } } System.out.println("-1"); } }
[ "zhangfaen@ainnovation.com" ]
zhangfaen@ainnovation.com
087d8a6e97004a8f5974fcb326ef094ffdf880fa
5b7b57c14b91d3d578855abebae59549048b1fd9
/AppCommon/src/main/java/com/trade/eight/view/picker/comm/util/DateUtils.java
91980c8db2ac08b8dffeee926aadffa30f8c2be5
[]
no_license
xanhf/8yuan
8c4f50fa7c95ae5f0dfb282f67a7b1c39b0b4711
a8b7f351066f479b3bc8a6037036458008e1624c
refs/heads/master
2021-05-14T19:58:44.462393
2017-11-16T10:31:29
2017-11-16T10:31:55
114,601,135
0
0
null
null
null
null
UTF-8
Java
false
false
7,489
java
package com.trade.eight.view.picker.comm.util; import android.annotation.SuppressLint; import android.support.annotation.IntDef; import android.support.annotation.NonNull; import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; import java.text.SimpleDateFormat; import java.util.Arrays; import java.util.Calendar; import java.util.Date; import java.util.List; import java.util.Locale; /** * 日期时间工具类 * * * @since 2015/8/5 */ public class DateUtils extends android.text.format.DateUtils { public static final int Second = 0; public static final int Minute = 1; public static final int Hour = 2; public static final int Day = 3; @IntDef(value = {Second, Minute, Hour, Day}) @Retention(RetentionPolicy.SOURCE) public @interface DifferenceMode { } public static long calculateDifferentSecond(Date startDate, Date endDate) { return calculateDifference(startDate, endDate, Second); } public static long calculateDifferentMinute(Date startDate, Date endDate) { return calculateDifference(startDate, endDate, Minute); } public static long calculateDifferentHour(Date startDate, Date endDate) { return calculateDifference(startDate, endDate, Hour); } public static long calculateDifferentDay(Date startDate, Date endDate) { return calculateDifference(startDate, endDate, Day); } public static long calculateDifferentSecond(long startTimeMillis, long endTimeMillis) { return calculateDifference(startTimeMillis, endTimeMillis, Second); } public static long calculateDifferentMinute(long startTimeMillis, long endTimeMillis) { return calculateDifference(startTimeMillis, endTimeMillis, Minute); } public static long calculateDifferentHour(long startTimeMillis, long endTimeMillis) { return calculateDifference(startTimeMillis, endTimeMillis, Hour); } public static long calculateDifferentDay(long startTimeMillis, long endTimeMillis) { return calculateDifference(startTimeMillis, endTimeMillis, Day); } /** * 计算两个时间戳之间相差的时间戳数 */ public static long calculateDifference(long startTimeMillis, long endTimeMillis, @DifferenceMode int mode) { return calculateDifference(new Date(startTimeMillis), new Date(endTimeMillis), mode); } /** * 计算两个日期之间相差的时间戳数 */ public static long calculateDifference(Date startDate, Date endDate, @DifferenceMode int mode) { long[] different = calculateDifference(startDate, endDate); if (mode == Minute) { return different[2]; } else if (mode == Hour) { return different[1]; } else if (mode == Day) { return different[0]; } else { return different[3]; } } private static long[] calculateDifference(Date startDate, Date endDate) { return calculateDifference(endDate.getTime() - startDate.getTime()); } private static long[] calculateDifference(long differentMilliSeconds) { long secondsInMilli = 1000;//1s==1000ms long minutesInMilli = secondsInMilli * 60; long hoursInMilli = minutesInMilli * 60; long daysInMilli = hoursInMilli * 24; long elapsedDays = differentMilliSeconds / daysInMilli; differentMilliSeconds = differentMilliSeconds % daysInMilli; long elapsedHours = differentMilliSeconds / hoursInMilli; differentMilliSeconds = differentMilliSeconds % hoursInMilli; long elapsedMinutes = differentMilliSeconds / minutesInMilli; differentMilliSeconds = differentMilliSeconds % minutesInMilli; long elapsedSeconds = differentMilliSeconds / secondsInMilli; LogUtils.debug(String.format(Locale.CHINA, "different: %d ms, %d days, %d hours, %d minutes, %d seconds", differentMilliSeconds, elapsedDays, elapsedHours, elapsedMinutes, elapsedSeconds)); return new long[]{elapsedDays, elapsedHours, elapsedMinutes, elapsedSeconds}; } /** * 计算每月的天数 */ public static int calculateDaysInMonth(int month) { return calculateDaysInMonth(0, month); } /** * 根据年份及月份计算每月的天数 */ public static int calculateDaysInMonth(int year, int month) { // 添加大小月月份并将其转换为list,方便之后的判断 String[] bigMonths = {"1", "3", "5", "7", "8", "10", "12"}; String[] littleMonths = {"4", "6", "9", "11"}; List<String> bigList = Arrays.asList(bigMonths); List<String> littleList = Arrays.asList(littleMonths); // 判断大小月及是否闰年,用来确定"日"的数据 if (bigList.contains(String.valueOf(month))) { return 31; } else if (littleList.contains(String.valueOf(month))) { return 30; } else { if (year <= 0) { return 29; } // 是否闰年 if ((year % 4 == 0 && year % 100 != 0) || year % 400 == 0) { return 29; } else { return 28; } } } /** * 月日时分秒,0-9前补0 */ @NonNull public static String fillZero(int number) { return number < 10 ? "0" + number : "" + number; } /** * 截取掉前缀0以便转换为整数 * * @see #fillZero(int) */ public static int trimZero(@NonNull String text) { if (text.startsWith("0")) { text = text.substring(1); } return Integer.parseInt(text); } /** * 功能:判断日期是否和当前date对象在同一天。 * 参见:http://www.cnblogs.com/myzhijie/p/3330970.html * * @param date 比较的日期 * @return boolean 如果在返回true,否则返回false。 */ public static boolean isSameDay(Date date) { if (date == null) { throw new IllegalArgumentException("date is null"); } Calendar nowCalendar = Calendar.getInstance(); Calendar newCalendar = Calendar.getInstance(); newCalendar.setTime(date); return (nowCalendar.get(Calendar.ERA) == newCalendar.get(Calendar.ERA) && nowCalendar.get(Calendar.YEAR) == newCalendar.get(Calendar.YEAR) && nowCalendar.get(Calendar.DAY_OF_YEAR) == newCalendar.get(Calendar.DAY_OF_YEAR)); } /** * 将yyyy-MM-dd HH:mm:ss字符串转换成日期<br/> * * @param dateStr 时间字符串 * @param dataFormat 当前时间字符串的格式。 * @return Date 日期 ,转换异常时返回null。 */ public static Date parseDate(String dateStr, String dataFormat) { try { @SuppressLint("SimpleDateFormat") SimpleDateFormat dateFormat = new SimpleDateFormat(dataFormat); Date date = dateFormat.parse(dateStr); return new Date(date.getTime()); } catch (Exception e) { LogUtils.warn(e); return null; } } /** * 将yyyy-MM-dd HH:mm:ss字符串转换成日期<br/> * * @param dateStr yyyy-MM-dd HH:mm:ss字符串 * @return Date 日期 ,转换异常时返回null。 */ public static Date parseDate(String dateStr) { return parseDate(dateStr, "yyyy-MM-dd HH:mm:ss"); } }
[ "enricozhang@126.com" ]
enricozhang@126.com
f5e4d29b658e5f8e76113c556e52d86ec77af227
3864406df6f75378a2e15c176f0250b2b4c775e6
/src/esocial-jt-service/src/test/java/br/jus/tst/esocialjt/ret/empregado/Processador2200Test.java
2cf4c1d4244428d08717b7e40ee151c6e794f214
[ "BSD-3-Clause" ]
permissive
tst-labs/esocial
272a4ccfc1a33868e669e454e976f848e79cf6c9
8be5092a80709521597189c3413de10dfd910f89
refs/heads/master
2023-07-23T07:26:43.590176
2023-07-18T13:23:20
2023-07-18T13:23:20
136,499,720
119
75
BSD-3-Clause
2023-09-08T12:24:41
2018-06-07T15:50:24
Java
UTF-8
Java
false
false
1,506
java
package br.jus.tst.esocialjt.ret.empregado; import br.jus.tst.esocial.ret.empregado.Empregado; import br.jus.tst.esocialjt.dominio.Ocorrencia; import br.jus.tst.esocialjt.util.OcorrenciaUtil; import org.junit.jupiter.api.Test; import java.util.ArrayList; import static org.assertj.core.api.Assertions.assertThat; class Processador2200Test { @Test void deveProcessar2200Novo() { Ocorrencia ocorrencia = OcorrenciaUtil.lerOcorrencia("ret/empregado/s2200/admissao.json"); Empregado esperado = OcorrenciaUtil.lerEmpregado("ret/empregado/s2200/esperado.json"); ArrayList<RetEmpregado> listaRetEmpregado = new ArrayList<>(); Processador2200 processador = new Processador2200(); processador.processaRegistro(listaRetEmpregado, ocorrencia); assertThat(listaRetEmpregado).hasSize(1); assertThat(listaRetEmpregado.get(0).empregado).usingRecursiveComparison().isEqualTo(esperado); assertThat(listaRetEmpregado.get(0).ocorrencias).contains(ocorrencia); } @Test void deveProcessar2200NovoMesmoComUmJaExistente() { Ocorrencia ocorrencia = OcorrenciaUtil.lerOcorrencia("ret/empregado/s2200/admissao.json"); Processador2200 processador = new Processador2200(); ArrayList<RetEmpregado> listaRetEmpregado = new ArrayList<>(); listaRetEmpregado.add(new RetEmpregado()); processador.processaRegistro(listaRetEmpregado, ocorrencia); assertThat(listaRetEmpregado).hasSize(2); } }
[ "tiago.bento@tst.jus.br" ]
tiago.bento@tst.jus.br
08fe14e09b69e05d7dd2447c646c92d387dbd187
afe061e084c2b650277a16f7e0150ed303ba2abd
/src/cl/bithaus/qfix/fields/MassCancelRejectReason.java
c80a5f0ed50f60dccf740f15f358a4a5d128be7f
[]
no_license
bithauschile/BithausQfixMessages
b9903f4625569e03fd6f91c5601e423c9dd9b009
f33b984ea017ac2b78271385a4d4918590afceb4
refs/heads/master
2021-08-30T02:22:54.617284
2017-12-15T17:30:48
2017-12-15T17:30:48
114,395,813
0
0
null
null
null
null
UTF-8
Java
false
false
1,603
java
/* Generated Java Source File */ /******************************************************************************* * Copyright (c) quickfixengine.org All rights reserved. * * This file is part of the QuickFIX FIX Engine * * This file may be distributed under the terms of the quickfixengine.org * license as defined by quickfixengine.org and appearing in the file * LICENSE included in the packaging of this file. * * This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A * PARTICULAR PURPOSE. * * See http://www.quickfixengine.org/LICENSE for licensing information. * * Contact ask@quickfixengine.org if any conditions of this licensing * are not clear to you. ******************************************************************************/ package cl.bithaus.qfix.fields; import quickfix.CharField; public class MassCancelRejectReason extends CharField { static final long serialVersionUID = 20050617; public static final int FIELD = 532; public static final char MASS_CANCEL_NOT_SUPPORTED = '0'; public static final char INVALID_OR_UNKNOWN_SECURITY = '1'; public static final char INVALID_OR_UNKNOWN_UNDERLYING = '2'; public static final char INVALID_OR_UNKNOWN_PRODUCT = '3'; public static final char INVALID_OR_UNKNOWN_CFICODE = '4'; public static final char INVALID_OR_UNKNOWN_SECURITY_TYPE = '5'; public static final char INVALID_OR_UNKNOWN_TRADING_SESSION = '6'; public MassCancelRejectReason() { super(532); } public MassCancelRejectReason(char data) { super(532, data); } }
[ "jmakuc@bithaus.cl" ]
jmakuc@bithaus.cl
7f3b2c50256e6bfff44529e529484e9df7cd7ab7
a6e2cd9ea01bdc5cfe58acce25627786fdfe76e9
/src/main/java/com/alipay/api/domain/AlipayInsMarketingDiscountPreuseModel.java
af337bbc03a228d61fb5e28195224917febe8ad3
[ "Apache-2.0" ]
permissive
cc-shifo/alipay-sdk-java-all
38b23cf946b73768981fdeee792e3dae568da48c
938d6850e63160e867d35317a4a00ed7ba078257
refs/heads/master
2022-12-22T14:06:26.961978
2020-09-23T04:00:10
2020-09-23T04:00:10
null
0
0
null
null
null
null
UTF-8
Java
false
false
3,179
java
package com.alipay.api.domain; import java.util.List; import com.alipay.api.AlipayObject; import com.alipay.api.internal.mapping.ApiField; import com.alipay.api.internal.mapping.ApiListField; /** * 保险营销优惠预核销 * * @author auto create * @since 1.0, 2019-08-26 17:23:36 */ public class AlipayInsMarketingDiscountPreuseModel extends AlipayObject { private static final long serialVersionUID = 4347227152155647416L; /** * 保险营销账号Id */ @ApiField("account_id") private String accountId; /** * 保险营销账号类型 */ @ApiField("account_type") private Long accountType; /** * 保险营销业务类型 */ @ApiField("business_type") private Long businessType; /** * 优惠决策因子 */ @ApiListField("factors") @ApiField("ins_mkt_factor_d_t_o") private List<InsMktFactorDTO> factors; /** * 营销市场列表 */ @ApiListField("market_types") @ApiField("number") private List<Long> marketTypes; /** * 权益活动列表 */ @ApiListField("mkt_coupon_campaigns") @ApiField("ins_mkt_coupon_cmpgn_base_d_t_o") private List<InsMktCouponCmpgnBaseDTO> mktCouponCampaigns; /** * 用户选择的权益列表 */ @ApiListField("mkt_coupons") @ApiField("ins_mkt_coupon_base_d_t_o") private List<InsMktCouponBaseDTO> mktCoupons; /** * 营销标的列表 */ @ApiListField("mkt_objects") @ApiField("ins_mkt_object_d_t_o") private List<InsMktObjectDTO> mktObjects; /** * 请求流水id */ @ApiField("request_id") private String requestId; public String getAccountId() { return this.accountId; } public void setAccountId(String accountId) { this.accountId = accountId; } public Long getAccountType() { return this.accountType; } public void setAccountType(Long accountType) { this.accountType = accountType; } public Long getBusinessType() { return this.businessType; } public void setBusinessType(Long businessType) { this.businessType = businessType; } public List<InsMktFactorDTO> getFactors() { return this.factors; } public void setFactors(List<InsMktFactorDTO> factors) { this.factors = factors; } public List<Long> getMarketTypes() { return this.marketTypes; } public void setMarketTypes(List<Long> marketTypes) { this.marketTypes = marketTypes; } public List<InsMktCouponCmpgnBaseDTO> getMktCouponCampaigns() { return this.mktCouponCampaigns; } public void setMktCouponCampaigns(List<InsMktCouponCmpgnBaseDTO> mktCouponCampaigns) { this.mktCouponCampaigns = mktCouponCampaigns; } public List<InsMktCouponBaseDTO> getMktCoupons() { return this.mktCoupons; } public void setMktCoupons(List<InsMktCouponBaseDTO> mktCoupons) { this.mktCoupons = mktCoupons; } public List<InsMktObjectDTO> getMktObjects() { return this.mktObjects; } public void setMktObjects(List<InsMktObjectDTO> mktObjects) { this.mktObjects = mktObjects; } public String getRequestId() { return this.requestId; } public void setRequestId(String requestId) { this.requestId = requestId; } }
[ "ben.zy@antfin.com" ]
ben.zy@antfin.com
25916d13ba5cc5e3f5d48f03ff7577fd8422e077
da43836d728650803c8ae5ce776fbcc8c1513f07
/ace-modules/bitcola-launchpad/src/main/java/com/bitcola/exchange/launchpad/feign/IConfigFeign.java
5ebc8a79de47c7c8a349d53f7a0f601528d73f74
[ "Apache-2.0" ]
permissive
wxpkerpk/exchange-base-examlple
36253f96a1e478365feabad183636675ee1e4f4c
acb61eb9d8316c5cf290481362560203eaf682a7
refs/heads/master
2022-06-28T12:19:17.730542
2019-07-11T16:38:51
2019-07-11T16:38:51
196,430,856
1
4
Apache-2.0
2022-06-21T01:26:27
2019-07-11T16:34:47
Java
UTF-8
Java
false
false
697
java
package com.bitcola.exchange.launchpad.feign; import com.alicp.jetcache.anno.CacheType; import com.alicp.jetcache.anno.Cached; import org.springframework.cloud.openfeign.FeignClient; import org.springframework.stereotype.Service; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RequestMethod; import org.springframework.web.bind.annotation.RequestParam; @FeignClient(value = "dataservice") @Service public interface IConfigFeign { @RequestMapping(value = "config/getConfig",method = RequestMethod.GET) @Cached(cacheType = CacheType.LOCAL, expire = 30) public String getConfig(@RequestParam("config") String config); }
[ "120443910@qq.com" ]
120443910@qq.com
846450850df3a34c013caff0f760688ff6d081ce
fe774f001d93d28147baec987a1f0afe0a454370
/ml-model/files/old-files/set3/expert/gniranjana_birthday-cake-candles_solution.java
55a8ff169a71b9e1b7740c9de48944311370087c
[]
no_license
gabrielchl/ml-novice-expert-dev-classifier
9dee42e04e67ab332cff9e66030c27d475592fe9
bcfca5870a3991dcfc1750c32ebbc9897ad34ea3
refs/heads/master
2023-03-20T05:07:20.148988
2021-03-19T01:38:13
2021-03-19T01:38:13
348,934,427
0
0
null
null
null
null
UTF-8
Java
false
false
1,511
java
import java.io.*; import java.math.*; import java.security.*; import java.text.*; import java.util.*; import java.util.concurrent.*; import java.util.regex.*; public class Solution { // Complete the birthdayCakeCandles function below. static int birthdayCakeCandles(int[] ar) { int retVal = 0; if (ar.length ==0) return retVal; if(ar.length > 0) { Arrays.sort(ar); int maxHeight = ar[ar.length -1]; retVal =1; for (int i = ar.length -2; i > 0;i--) { if (ar[i] == maxHeight) retVal++; } } return retVal; } private static final Scanner scanner = new Scanner(System.in); public static void main(String[] args) throws IOException { BufferedWriter bufferedWriter = new BufferedWriter(new FileWriter(System.getenv("OUTPUT_PATH"))); int arCount = scanner.nextInt(); scanner.skip("(\r\n|[\n\r\u2028\u2029\u0085])?"); int[] ar = new int[arCount]; String[] arItems = scanner.nextLine().split(" "); scanner.skip("(\r\n|[\n\r\u2028\u2029\u0085])?"); for (int i = 0; i < arCount; i++) { int arItem = Integer.parseInt(arItems[i]); ar[i] = arItem; } int result = birthdayCakeCandles(ar); bufferedWriter.write(String.valueOf(result)); bufferedWriter.newLine(); bufferedWriter.close(); scanner.close(); } }
[ "chihonglee777@gmail.com" ]
chihonglee777@gmail.com
309c5c4147fb11543bea5e9d38f12ca0f42ae872
1930d97ebfc352f45b8c25ef715af406783aabe2
/src/main/java/com/alipay/api/response/AlipayOpenAppAppcontentItemModifyResponse.java
c675a96a166894d1788bb458b9163dcf0ae95dda
[ "Apache-2.0" ]
permissive
WQmmm/alipay-sdk-java-all
57974d199ee83518523e8d354dcdec0a9ce40a0c
66af9219e5ca802cff963ab86b99aadc59cc09dd
refs/heads/master
2023-06-28T03:54:17.577332
2021-08-02T10:05:10
2021-08-02T10:05:10
null
0
0
null
null
null
null
UTF-8
Java
false
false
633
java
package com.alipay.api.response; import com.alipay.api.internal.mapping.ApiField; import com.alipay.api.AlipayResponse; /** * ALIPAY API: alipay.open.app.appcontent.item.modify response. * * @author auto create * @since 1.0, 2021-01-15 11:39:18 */ public class AlipayOpenAppAppcontentItemModifyResponse extends AlipayResponse { private static final long serialVersionUID = 1644118739623677927L; /** * 商品ID */ @ApiField("item_id") private String itemId; public void setItemId(String itemId) { this.itemId = itemId; } public String getItemId( ) { return this.itemId; } }
[ "ben.zy@antfin.com" ]
ben.zy@antfin.com
fa2c1984f401fabaa1c8165cc48faefe7d3f3dac
f7295dfe3c303e1d656e7dd97c67e49f52685564
/smali/org/apache/http/client/utils/CloneUtils.java
088f3a035881beb06108deb9b54356ed85968cf7
[]
no_license
Eason-Chen0452/XiaoMiGame
36a5df0cab79afc83120dab307c3014e31f36b93
ba05d72a0a0c7096d35d57d3b396f8b5d15729ef
refs/heads/master
2022-04-14T11:08:31.280151
2020-04-14T08:57:25
2020-04-14T08:57:25
255,541,211
0
1
null
null
null
null
UTF-8
Java
false
false
490
java
package org.apache.http.client.utils; @Deprecated public class CloneUtils { CloneUtils() { throw new RuntimeException("Stub!"); } public static Object clone(Object paramObject) throws CloneNotSupportedException { throw new RuntimeException("Stub!"); } } /* Location: C:\Users\Administrator\Desktop\apk\dex2jar\classes-dex2jar.jar!\org\apache\http\client\utils\CloneUtils.class * Java compiler version: 6 (50.0) * JD-Core Version: 0.7.1 */
[ "chen_guiq@163.com" ]
chen_guiq@163.com
196f5edc74dd6281954b0408de037584c81fd8e0
b87ec73f50d5c6131bf270a7eb2d8f33b3223b4f
/src/main/java/so/sao/shop/supplier/util/DownTemplateUtil.java
d0179b3957f24cdc145606f84c1be8487ef62e28
[]
no_license
chenhaujing/supplier
976fada60fb6fef7a9061cbab027fc6da3dd97a9
4b523ec98807a8641494a6c8b880fef4d4c74880
refs/heads/master
2021-05-04T21:12:23.754125
2018-02-02T02:04:49
2018-02-02T02:04:57
119,918,261
0
0
null
null
null
null
UTF-8
Java
false
false
2,125
java
package so.sao.shop.supplier.util; import javax.servlet.ServletOutputStream; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; import java.io.*; import java.net.URL; /** * Created by acer on 2017/7/25. */ public class DownTemplateUtil { public static void downLoadExcel(HttpServletRequest request, HttpServletResponse response, String templateName, String fileName) throws IOException { URL save = Thread.currentThread().getContextClassLoader().getResource(""); String str = save.toString(); str = str.substring(6, str.length()); str = str.replaceAll("%20", " "); int num = str.lastIndexOf("shop");//supplier 为项目名,应用到不同的项目中,这个需要修改! str = str.substring(0, num + "shop".length()); str = str + "/file/"+templateName;//Excel模板所在的路径。 File f = new File(str); // 设置response参数,可以打开下载页面 response.reset(); response.setContentType("application/vnd.ms-excel;charset=utf-8"); // String filename = "供应商信息.xlsx"; fileName = new String(fileName.getBytes("Utf-8"), "iso-8859-1"); response.setHeader("Content-Disposition", "attachment; filename=\"" + fileName + "\""); response.setCharacterEncoding("UTF-8"); response.setHeader("Content-Type", "application/octet-stream"); ServletOutputStream out = response.getOutputStream(); BufferedInputStream bis = null; BufferedOutputStream bos = null; try { bis = new BufferedInputStream(new FileInputStream(f)); bos = new BufferedOutputStream(out); byte[] buff = new byte[2048]; int bytesRead; while (-1 != (bytesRead = bis.read(buff, 0, buff.length))) { bos.write(buff, 0, bytesRead); } } catch (final IOException e) { throw e; } finally { if (bis != null) bis.close(); if (bos != null) bos.close(); } } }
[ "1032291008@qq.com" ]
1032291008@qq.com
8755207c4ffb092f1b7fc3cb92ced90c85c8d904
78047967a6837240fac057eb982d05ceff5820ba
/open_erp/src/main/java/org/rhl/open_erp/service/impl/DeviceMaintainServiceImpl.java
528184c376b29ef4f78ef176a8796250dee5b096
[]
no_license
renhengli518/open_erp
4b4080e71a2096d440260447b29d7129bad1506e
487297505200676387404bc24a6b4396b459ef03
refs/heads/master
2020-12-03T03:45:21.811986
2017-06-30T03:56:29
2017-06-30T03:56:29
95,768,634
0
0
null
null
null
null
UTF-8
Java
false
false
3,664
java
package org.rhl.open_erp.service.impl; import java.util.List; import org.rhl.open_erp.domain.DeviceMaintain; import org.rhl.open_erp.domain.customize.CustomResult; import org.rhl.open_erp.domain.customize.EUDataGridResult; import org.rhl.open_erp.mapper.DeviceMaintainMapper; import org.rhl.open_erp.service.DeviceMaintainService; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; import com.github.pagehelper.PageHelper; import com.github.pagehelper.PageInfo; @Service public class DeviceMaintainServiceImpl implements DeviceMaintainService{ @Autowired DeviceMaintainMapper deviceMaintainMapper; @Override public EUDataGridResult getList(int page, int rows, DeviceMaintain deviceMaintain) throws Exception { //分页处理 PageHelper.startPage(page, rows); List<DeviceMaintain> list = deviceMaintainMapper.find(deviceMaintain); //创建一个返回值对象 EUDataGridResult result = new EUDataGridResult(); result.setRows(list); //取记录总条数 PageInfo<DeviceMaintain> pageInfo = new PageInfo<>(list); result.setTotal(pageInfo.getTotal()); return result; } @Override public DeviceMaintain get(String id) throws Exception { return deviceMaintainMapper.selectByPrimaryKey(id); } @Override public CustomResult insert(DeviceMaintain deviceMaintain) throws Exception { int i = deviceMaintainMapper.insert(deviceMaintain); if(i>=0){ return CustomResult.ok(); }else{ return CustomResult.build(101, "新增设备维修信息失败"); } } @Override public CustomResult delete(String deviceMaintainId) throws Exception { int i = deviceMaintainMapper.deleteByPrimaryKey(deviceMaintainId); if(i>=0){ return CustomResult.ok(); }else{ return null; } } @Override public CustomResult deleteBatch(String[] deviceMaintainIds) throws Exception { int i = deviceMaintainMapper.deleteBatch(deviceMaintainIds); if(i>=0){ return CustomResult.ok(); }else{ return null; } } @Override public CustomResult update(DeviceMaintain deviceMaintain) throws Exception { int i = deviceMaintainMapper.updateByPrimaryKeySelective(deviceMaintain); if(i>=0){ return CustomResult.ok(); }else{ return CustomResult.build(101, "修改设备维修信息失败"); } } @Override public CustomResult updateNote(DeviceMaintain deviceMaintain) throws Exception { int i = deviceMaintainMapper.updateNote(deviceMaintain); if(i>0){ return CustomResult.ok(); }else{ return CustomResult.build(101, "新增设备维修备注失败"); } } @Override public EUDataGridResult searchDeviceMaintainByDeviceMaintainId( Integer page, Integer rows, String deviceMaintainId) { //分页处理 PageHelper.startPage(page, rows); List<DeviceMaintain> list = deviceMaintainMapper.searchDeviceMaintainByDeviceMaintainId(deviceMaintainId); //创建一个返回值对象 EUDataGridResult result = new EUDataGridResult(); result.setRows(list); //取记录总条数 PageInfo<DeviceMaintain> pageInfo = new PageInfo<>(list); result.setTotal(pageInfo.getTotal()); return result; } @Override public EUDataGridResult searchDeviceMaintainByDeviceFaultId(Integer page, Integer rows, String deviceFaultId) { //分页处理 PageHelper.startPage(page, rows); List<DeviceMaintain> list = deviceMaintainMapper.searchDeviceMaintainByDeviceFaultId(deviceFaultId); //创建一个返回值对象 EUDataGridResult result = new EUDataGridResult(); result.setRows(list); //取记录总条数 PageInfo<DeviceMaintain> pageInfo = new PageInfo<>(list); result.setTotal(pageInfo.getTotal()); return result; } }
[ "372594984@qq.com" ]
372594984@qq.com
61aa61f804eff61b3cd26bd99b4a5291362f818e
459960cf5c9a0e5e254f83ae3971347c30434fdb
/src/legacy/com/fsrin/menumine/core/menumine/sharetable/legacy/StatisticalTableMenuStatusKeyFinder.java
415d9d9e600026711780a5e6b123e0d645129eb7
[]
no_license
bradym80/MenuMine_Java
92374fbc0fd0b76c209a155ce57d6af4a975fd6f
d33ff38d34c133038a97c587631ec4abc30ffbc6
refs/heads/master
2021-01-17T22:41:58.089105
2014-01-31T03:52:29
2014-01-31T03:52:29
16,398,936
0
0
null
null
null
null
UTF-8
Java
false
false
707
java
/* * Created on Mar 29, 2005 * * */ package com.fsrin.menumine.core.menumine.sharetable.legacy; import com.fsrin.menumine.core.menumine.masterfood.MasterFood; import com.fsrin.menumine.core.menumine.sharetable.StatisticalTableKeyFinder; /** * @author Nick * * */ public class StatisticalTableMenuStatusKeyFinder implements StatisticalTableKeyFinder { public StatisticalTableMenuStatusKeyFinder() { super(); } public Object getKey(MasterFood masterFood) { Object result; result = masterFood.getMenuStatus(); if (result == null) { return "Not On Menu"; } return result; } }
[ "matthewbrady@Matthews-MacBook-Air.local" ]
matthewbrady@Matthews-MacBook-Air.local
c9f4ec4186c29344912c01815e7c2c44fc61ebf5
e3896cf755d5f399464d175c226f8c4b7b5de44b
/src/main/java/com/payAm/core/constant/BaseConstants.java
d7978bbb60f6c8897ef125b45f217f8f7d17d7c5
[]
no_license
mhsh88/ics
138c5e97616ad625b9bac48ae21e3e2f81c3876d
e9535042a1eb809c8251a9fab4e738d0d4ca688c
refs/heads/master
2020-03-09T14:27:39.285066
2018-04-30T15:38:27
2018-04-30T15:38:27
128,835,019
0
0
null
null
null
null
UTF-8
Java
false
false
658
java
package com.payAm.core.constant; import com.payAm.core.util.StringUtil; import java.io.Serializable; /** * Created by Payam Mostafaei * Creation Time: 2017/Jan/05 - 09:35 AM */ public interface BaseConstants extends Serializable { //String ENTITY = "baseEntity"; String SINGULAR = "singular"; String PLURAL = "plural"; String ID = "id"; String DELETED = "deleted"; String REQUIRED = "required"; String MAX_LENGTH = "maxLength"; String ERROR = "error"; String DOT = StringUtil.DOT; String QUERY = "query"; String YES = "yes"; String NO = "no"; String HAS = "has"; String HAS_NOT = "hasNot"; }
[ "hosseinsharifi@hotmail.com" ]
hosseinsharifi@hotmail.com
27f550904b3c8bb03ac072a93b4cab0331c10b22
9b01ffa3db998c4bca312fd28aa977f370c212e4
/app/src/streamC/java/com/loki/singlemoduleapp/stub/SampleClass4614.java
f3c0c052c645f87046588b27ea13ca9680452606
[]
no_license
SergiiGrechukha/SingleModuleApp
932488a197cb0936785caf0e73f592ceaa842f46
b7fefea9f83fd55dbbb96b506c931cc530a4818a
refs/heads/master
2022-05-13T17:15:21.445747
2017-07-30T09:55:36
2017-07-30T09:56:11
null
0
0
null
null
null
null
UTF-8
Java
false
false
281
java
package com.loki.singlemoduleapp.stub; public class SampleClass4614 { private SampleClass4615 sampleClass; public SampleClass4614(){ sampleClass = new SampleClass4615(); } public String getClassName() { return sampleClass.getClassName(); } }
[ "sergey.grechukha@gmail.com" ]
sergey.grechukha@gmail.com
b739d1ac1afc85339520d9d98da548976aeaa679
37d8b470e71ea6edff6ed108ffd2b796322b7943
/joffice/src/com/htsoft/oa/dao/personal/DutySystemDao.java
6142f1a9718708677d22103ffd02385c289ec048
[]
no_license
haifeiforwork/myfcms
ef9575be5fc7f476a048d819e7c0c0f2210be8ca
fefce24467df59d878ec5fef2750b91a29e74781
refs/heads/master
2020-05-15T11:37:50.734759
2014-06-28T08:31:55
2014-06-28T08:31:55
null
0
0
null
null
null
null
UTF-8
Java
false
false
350
java
package com.htsoft.oa.dao.personal; import java.util.List; import com.htsoft.core.dao.BaseDao; import com.htsoft.oa.model.personal.DutySystem; public abstract interface DutySystemDao extends BaseDao<DutySystem> { public abstract void updateForNotDefult(); public abstract List<DutySystem> getDefaultDutySystem(); }
[ "xiacc1984@gmail.com@c1c2bf6e-ae9d-b823-7fc2-ff1dc594729e" ]
xiacc1984@gmail.com@c1c2bf6e-ae9d-b823-7fc2-ff1dc594729e
74876fbfeb52282faac4afe54a885d26b2855e3a
fa91450deb625cda070e82d5c31770be5ca1dec6
/Diff-Raw-Data/28/28_9f31612f7df54b1c41bed5ff3ae0242791b134b9/DefaultRetryPolicy/28_9f31612f7df54b1c41bed5ff3ae0242791b134b9_DefaultRetryPolicy_t.java
789038a1f916d41344adab9acc233ce7c14e90d6
[]
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
5,702
java
package com.datastax.driver.core.policies; import com.datastax.driver.core.*; /** * The default retry policy. * <p> * This policy retries queries in only two cases: * <ul> * <li>On a read timeout, if enough replica replied but data was not retrieved.</li> * <li>On a write timeout, if we timeout while writing the distributed log used by batch statements.</li> * </ul> * <p> * This retry policy is conservative in that it will never retry with a * different consistency level than the one of the initial operation. * <p> * In some cases, it may be convenient to use a more aggressive retry policy * like {@link DowngradingConsistencyRetryPolicy}. */ public class DefaultRetryPolicy implements RetryPolicy { public static final DefaultRetryPolicy INSTANCE = new DefaultRetryPolicy(); private DefaultRetryPolicy() {} /** * Defines whether to retry and at which consistency level on a read timeout. * <p> * This method triggers a maximum of one retry, and only if enough * replica had responded to the read request but data was not retrieved * amongst those. Indeed, that case usually means that enough replica * are alive to satisfy the consistency but the coordinator picked a * dead one for data retrieval, not having detecte that replica as dead * yet. The reasoning for retrying then is that by the time we get the * timeout the dead replica will likely have been detected as dead and * the retry has a high change of success. * * @param query the original query that timeouted. * @param cl the original consistency level of the read that timeouted. * @param requiredResponses the number of responses that were required to * achieve the requested consistency level. * @param receivedResponses the number of responses that had been received * by the time the timeout exception was raised. * @param dataRetrieved whether actual data (by opposition to data checksum) * was present in the received responses. * @param nbRetry the number of retry already performed for this operation. * @return {@code RetryDecision.retry(cl)} if no retry attempt has yet been tried and * {@code receivedResponses >= requiredResponses && !dataRetrieved}, {@code RetryDecision.rethrow()} otherwise. */ public RetryDecision onReadTimeout(Query query, ConsistencyLevel cl, int requiredResponses, int receivedResponses, boolean dataRetrieved, int nbRetry) { if (nbRetry != 0) return RetryDecision.rethrow(); return receivedResponses >= requiredResponses && !dataRetrieved ? RetryDecision.retry(cl) : RetryDecision.rethrow(); } /** * Defines whether to retry and at which consistency level on a write timeout. * <p> * This method triggers a maximum of one retry, and only in the case of * a {@code WriteType.BATCH_LOG} write. The reasoning for the retry in * that case is that write to the distributed batch log is tried by the * coordinator of the write against a small subset of all the node alive * in the local datacenter. Hence, a timeout usually means that none of * the nodes in that subset were alive but the coordinator hasn't * detected them as dead. By the time we get the timeout the dead * nodes will likely have been detected as dead and the retry has thus a * high change of success. * * @param query the original query that timeouted. * @param cl the original consistency level of the write that timeouted. * @param writeType the type of the write that timeouted. * @param requiredAcks the number of acknowledgments that were required to * achieve the requested consistency level. * @param receivedAcks the number of acknowledgments that had been received * by the time the timeout exception was raised. * @param nbRetry the number of retry already performed for this operation. * @return {@code RetryDecision.retry(cl)} if no retry attempt has yet been tried and * {@code writeType == WriteType.BATCH_LOG}, {@code RetryDecision.rethrow()} otherwise. */ public RetryDecision onWriteTimeout(Query query, ConsistencyLevel cl, WriteType writeType, int requiredAcks, int receivedAcks, int nbRetry) { if (nbRetry != 0) return RetryDecision.rethrow(); // If the batch log write failed, retry the operation as this might just be we were unlucky at picking candidtes return writeType == WriteType.BATCH_LOG ? RetryDecision.retry(cl) : RetryDecision.rethrow(); } /** * Defines whether to retry and at which consistency level on an * unavailable exception. * <p> * This method never retries as a retry on an unavailable exception * using the same consistency level has almost no change of success. * * @param query the original query for which the consistency level cannot * be achieved. * @param cl the original consistency level for the operation. * @param requiredReplica the number of replica that should have been * (known) alive for the operation to be attempted. * @param aliveReplica the number of replica that were know to be alive by * the coordinator of the operation. * @param nbRetry the number of retry already performed for this operation. * @return {@code RetryDecision.rethrow()}. */ public RetryDecision onUnavailable(Query query, ConsistencyLevel cl, int requiredReplica, int aliveReplica, int nbRetry) { return RetryDecision.rethrow(); } }
[ "yuzhongxing88@gmail.com" ]
yuzhongxing88@gmail.com
720ac531aa11ff1a444b512ac2f91bbcaf473e77
53e53a43a23ac71ff421ce19a40efd9a90a78b26
/src/main/java/com/feed_the_beast/ftbl/api_impl/FTBLibAPI_Impl.java
2baef8c7b004bb36030eb04b4138f6254ef3d8d9
[]
no_license
Tory05/FTBLib
4de11072dc400976adfe544b7b6daf6f6eb754cf
f3def1c1969d57dc314db20473de9f6a72cf6c15
refs/heads/master
2021-01-20T06:46:52.925648
2017-08-25T13:06:42
2017-08-25T13:06:42
null
0
0
null
null
null
null
UTF-8
Java
false
false
6,917
java
package com.feed_the_beast.ftbl.api_impl; import com.feed_the_beast.ftbl.FTBLibMod; import com.feed_the_beast.ftbl.FTBLibModCommon; import com.feed_the_beast.ftbl.api.EnumReloadType; import com.feed_the_beast.ftbl.api.FTBLibAPI; import com.feed_the_beast.ftbl.api.IForgePlayer; import com.feed_the_beast.ftbl.api.IRankConfig; import com.feed_the_beast.ftbl.api.ISharedClientData; import com.feed_the_beast.ftbl.api.ISharedServerData; import com.feed_the_beast.ftbl.api.IUniverse; import com.feed_the_beast.ftbl.api.config.IConfigContainer; import com.feed_the_beast.ftbl.api.config.IConfigValue; import com.feed_the_beast.ftbl.api.config.IConfigValueProvider; import com.feed_the_beast.ftbl.api.events.LoadWorldDataEvent; import com.feed_the_beast.ftbl.api.events.ReloadEvent; import com.feed_the_beast.ftbl.api.gui.IContainerProvider; import com.feed_the_beast.ftbl.client.FTBLibClientConfig; import com.feed_the_beast.ftbl.lib.BroadcastSender; import com.feed_the_beast.ftbl.lib.Notification; import com.feed_the_beast.ftbl.lib.guide.GuidePage; import com.feed_the_beast.ftbl.lib.internal.FTBLibFinals; import com.feed_the_beast.ftbl.lib.internal.FTBLibLang; import com.feed_the_beast.ftbl.lib.net.MessageBase; import com.feed_the_beast.ftbl.lib.util.CommonUtils; import com.feed_the_beast.ftbl.lib.util.ServerUtils; import com.feed_the_beast.ftbl.lib.util.StringUtils; import com.feed_the_beast.ftbl.net.MessageDisplayGuide; import com.feed_the_beast.ftbl.net.MessageEditConfig; import com.feed_the_beast.ftbl.net.MessageOpenGui; import com.feed_the_beast.ftbl.net.MessageReload; import com.google.common.base.Preconditions; import net.minecraft.command.ICommandSender; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.entity.player.EntityPlayerMP; import net.minecraft.inventory.Container; import net.minecraft.nbt.NBTTagCompound; import net.minecraft.server.MinecraftServer; import net.minecraft.util.ITickable; import net.minecraft.util.ResourceLocation; import net.minecraft.util.math.BlockPos; import net.minecraft.util.text.TextComponentString; import net.minecraft.util.text.TextFormatting; import net.minecraftforge.fml.common.LoaderState; import net.minecraftforge.fml.common.network.simpleimpl.MessageContext; import net.minecraftforge.fml.relauncher.Side; import javax.annotation.Nullable; import java.util.Collection; import java.util.HashSet; import java.util.Map; /** * @author LatvianModder */ public class FTBLibAPI_Impl extends FTBLibAPI { public static final boolean LOG_NET = System.getProperty("ftbl.logNetwork", "0").equals("1"); @Override public Collection<ITickable> ticking() { return TickHandler.INSTANCE.TICKABLES; } @Override public ISharedServerData getServerData() { return SharedServerData.INSTANCE; } @Override public ISharedClientData getClientData() { return SharedClientData.INSTANCE; } @Override public IUniverse getUniverse() { Preconditions.checkNotNull(Universe.INSTANCE); return Universe.INSTANCE; } @Override public void addServerCallback(int timer, Runnable runnable) { TickHandler.INSTANCE.addServerCallback(timer, runnable); } @Override public void loadWorldData(MinecraftServer server) { new LoadWorldDataEvent(server).post(); } @Override public void reload(Side side, ICommandSender sender, EnumReloadType type, ResourceLocation id) { long ms = System.currentTimeMillis(); boolean serverSide = side.isServer(); if (serverSide) { Preconditions.checkNotNull(Universe.INSTANCE, "Can't reload yet!"); FTBLibMod.PROXY.reloadConfig(LoaderState.ModState.AVAILABLE); } HashSet<ResourceLocation> failed = new HashSet<>(); new ReloadEvent(side, sender, type, id, failed).post(); if (serverSide && ServerUtils.hasOnlinePlayers()) { for (EntityPlayerMP ep : ServerUtils.getServer().getPlayerList().getPlayers()) { NBTTagCompound syncData = new NBTTagCompound(); IForgePlayer p = Universe.INSTANCE.getPlayer(ep); FTBLibModCommon.SYNCED_DATA.forEach((key, value) -> syncData.setTag(key, value.writeSyncData(ep, p))); new MessageReload(type, syncData, id).sendTo(ep); } } String millis = (System.currentTimeMillis() - ms) + "ms"; if (type != EnumReloadType.CREATED) { if (!serverSide) { FTBLibLang.RELOAD_CLIENT.printChat(BroadcastSender.INSTANCE, millis); } if (serverSide && type == EnumReloadType.RELOAD_COMMAND) { Notification notification = Notification.of(FTBLibFinals.get("reload_client_config")); notification.addLine(FTBLibLang.RELOAD_SERVER.textComponent(millis)); String cmd = FTBLibClientConfig.MIRROR_COMMANDS.getBoolean() ? "/reload_client" : "/ftbc reload_client"; notification.addLine(FTBLibLang.RELOAD_CLIENT_CONFIG.textComponent(StringUtils.color(new TextComponentString(cmd), TextFormatting.GOLD))); notification.setTimer(140); notification.send(null); } } FTBLibFinals.LOGGER.info("Reloaded " + side + " in " + millis); } @Override public void openGui(ResourceLocation guiId, EntityPlayerMP player, BlockPos pos, @Nullable NBTTagCompound data) { IContainerProvider containerProvider = FTBLibModCommon.GUI_CONTAINER_PROVIDERS.get(guiId); if (containerProvider == null) { return; } Container c = containerProvider.getContainer(player, pos, data); player.getNextWindowId(); player.closeContainer(); if (c != null) { player.openContainer = c; } player.openContainer.windowId = player.currentWindowId; player.openContainer.addListener(player); new MessageOpenGui(guiId, pos, data, player.currentWindowId).sendTo(player); } @Override public void editServerConfig(EntityPlayerMP player, @Nullable NBTTagCompound nbt, IConfigContainer configContainer) { new MessageEditConfig(player.getGameProfile().getId(), nbt, configContainer).sendTo(player); } @Override public void displayGuide(EntityPlayer player, GuidePage page) { if (player.world.isRemote) { FTBLibMod.PROXY.displayGuide(page); } else { new MessageDisplayGuide(page).sendTo(player); } } @Override public IConfigValue getConfigValueFromID(String id) { IConfigValueProvider provider = FTBLibModCommon.CONFIG_VALUE_PROVIDERS.get(id); Preconditions.checkNotNull(provider, "Unknown Config ID: " + id); return provider.createConfigValue(); } @Override public Map<String, IRankConfig> getRankConfigRegistry() { return FTBLibModCommon.RANK_CONFIGS_MIRROR; } @Override public void handleMessage(MessageBase<?> message, MessageContext context, Side side) { if (side.isServer()) { context.getServerHandler().player.mcServer.addScheduledTask(() -> { message.onMessage(CommonUtils.cast(message), context.getServerHandler().player); if (LOG_NET) { CommonUtils.DEV_LOGGER.info("TX MessageBase: " + message.getClass().getName()); } }); } else { FTBLibMod.PROXY.handleClientMessage(message); } } }
[ "latvianmodder@gmail.com" ]
latvianmodder@gmail.com
4ad8c58027d64d7ed31afc258c73a592a0cc9b76
71b6f25a08a2325a65445f2dedb40075f8562a02
/TLRPC$TL_inputMessagesFilterDocument.java
2440e323d80bbcd3fe69580de21ad81dcfb73882
[]
no_license
CustomIcon/tgnet
7bb8a81700e66a2255a94ff3bb07beb211996a1d
10567a64d33f846c552a4ea98d576925484f875b
refs/heads/main
2023-09-01T02:42:07.693180
2021-09-09T07:52:29
2021-09-09T07:52:29
null
0
0
null
null
null
null
UTF-8
Java
false
false
352
java
package org.telegram.tgnet; public class TLRPC$TL_inputMessagesFilterDocument extends TLRPC$MessagesFilter { public static int constructor = -1629621880; @Override // org.telegram.tgnet.TLObject public void serializeToStream(AbstractSerializedData abstractSerializedData) { abstractSerializedData.writeInt32(constructor); } }
[ "aman_a@aol.com" ]
aman_a@aol.com
95ff7e8826c2cafcc45bd75d850546b43692b530
69a4f2d51ebeea36c4d8192e25cfb5f3f77bef5e
/methods/Method_37972.java
89b41a995d4c9ba918e36a4e38319695de990f8f
[]
no_license
P79N6A/icse_20_user_study
5b9c42c6384502fdc9588430899f257761f1f506
8a3676bc96059ea2c4f6d209016f5088a5628f3c
refs/heads/master
2020-06-24T08:25:22.606717
2019-07-25T15:31:16
2019-07-25T15:31:16
null
0
0
null
null
null
null
UTF-8
Java
false
false
240
java
/** * Determines if a string is blank (<code>null</code> or {@link #containsOnlyWhitespaces(CharSequence)}). */ public static boolean isBlank(final CharSequence string){ return ((string == null) || containsOnlyWhitespaces(string)); }
[ "sonnguyen@utdallas.edu" ]
sonnguyen@utdallas.edu
2692e5497c60a6b78f1a39d513577f52ed9e4cda
2a524d52d21861637188c25b7e1d3d8a1806401a
/src/main/java/com/nokia/mp/testdatacenter/service/ProductService.java
f04290514da86c3377020c9b85e01786b6867b3e
[]
no_license
slimsymphony/test-reporting-system
b102b8f61c66a9e3367f01a839127496281331da
c241dc60b8bbc79e2f10dc1cdf5d1982661c62c8
refs/heads/master
2021-01-20T06:25:42.435736
2014-07-24T09:30:02
2014-07-24T09:30:02
null
0
0
null
null
null
null
UTF-8
Java
false
false
199
java
package com.nokia.mp.testdatacenter.service; import java.util.List; import com.nokia.mp.testdatacenter.model.Product; public interface ProductService { public List<Product> findProducts(); }
[ "slimsymphony@gmail.com" ]
slimsymphony@gmail.com
620d26bf1e86c5bd4e78318db99eb0acc4c5b48d
5289e40e25fe505c0bf483aca75080c0f3ae69b4
/java/java-analysis-impl/src/com/intellij/codeInspection/dataFlow/rangeSet/LongRangeBinOp.java
5d6b6d923cf41bb6ceb00c49787320c57890f2c3
[ "Apache-2.0" ]
permissive
haarlemmer/Jvav-Studio-Community
507e4fa1b4873cd1ede5442219d105757a91abbb
de80b70f5507f0110de89a95d72b8f902ca72b3e
refs/heads/main
2023-06-30T10:09:28.470066
2021-08-04T08:39:35
2021-08-04T08:39:35
392,603,002
0
0
Apache-2.0
2021-08-04T08:04:52
2021-08-04T08:04:51
null
UTF-8
Java
false
false
4,065
java
// Copyright 2000-2020 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file. package com.intellij.codeInspection.dataFlow.rangeSet; import com.intellij.psi.JavaTokenType; import com.intellij.psi.tree.IElementType; import org.jetbrains.annotations.NotNull; import org.jetbrains.annotations.Nullable; /** * Supported binary operations over long ranges. */ public enum LongRangeBinOp { PLUS("+"), MINUS("-"), AND("&"), OR("|"), XOR("^"), MUL("*"), MOD("%"), DIV("/"), SHL("<<"), SHR(">>"), USHR(">>>"); final String mySymbol; LongRangeBinOp(String symbol) { mySymbol = symbol; } /** * Performs a binary operation on ranges. * * @param left a left-hand operand * @param right a right-hand operand * @param isLong true if operation should be performed on long types (otherwise int is assumed) * @return the resulting LongRangeSet which covers possible results of the operation (probably including some more elements). */ public @NotNull LongRangeSet eval(@NotNull LongRangeSet left, @NotNull LongRangeSet right, boolean isLong) { switch (this) { case PLUS: return left.plus(right, isLong); case MINUS: return left.minus(right, isLong); case AND: return left.bitwiseAnd(right); case OR: return left.bitwiseOr(right, isLong); case XOR: return left.bitwiseXor(right, isLong); case MUL: return left.mul(right, isLong); case MOD: return left.mod(right); case DIV: return left.div(right, isLong); case SHL: return left.shiftLeft(right, isLong); case SHR: return left.shiftRight(right, isLong); case USHR: return left.unsignedShiftRight(right, isLong); default: throw new IllegalStateException("Unexpected value: " + this); } } /** * Performs a binary operation on ranges with possible widening, so that if operation is performed repeatedly * it will eventually converge. * * @param left a left-hand operand * @param right a right-hand operand * @param isLong true if operation should be performed on long types (otherwise int is assumed) * @return the resulting LongRangeSet which covers possible results of the operation (probably including some more elements). */ public @NotNull LongRangeSet evalWide(@NotNull LongRangeSet left, @NotNull LongRangeSet right, boolean isLong) { switch (this) { case PLUS: return left.plusWiden(right, isLong); case MINUS: if (Long.valueOf(0).equals(left.getConstantValue())) { // Unary minus return left.minus(right, isLong); } return left.plusWiden(right.negate(isLong), isLong); case MUL: return left.mulWiden(right, isLong); default: return eval(left, right, isLong); } } @Override public String toString() { return mySymbol; } /** * @param token Java token (like {@link JavaTokenType#PLUS}) * @return a corresponding {@link LongRangeBinOp} constant; null if no constant corresponds for a given token */ public static @Nullable LongRangeBinOp fromToken(IElementType token) { if (token == null) return null; if (token.equals(JavaTokenType.PLUS)) { return PLUS; } if (token.equals(JavaTokenType.MINUS)) { return MINUS; } if (token.equals(JavaTokenType.AND)) { return AND; } if (token.equals(JavaTokenType.OR)) { return OR; } if (token.equals(JavaTokenType.XOR)) { return XOR; } if (token.equals(JavaTokenType.PERC)) { return MOD; } if (token.equals(JavaTokenType.DIV)) { return DIV; } if (token.equals(JavaTokenType.LTLT)) { return SHL; } if (token.equals(JavaTokenType.GTGT)) { return SHR; } if (token.equals(JavaTokenType.GTGTGT)) { return USHR; } if (token.equals(JavaTokenType.ASTERISK)) { return MUL; } return null; } }
[ "luckystar5408@github.com" ]
luckystar5408@github.com
f46bac38ef78e44e879fba05262a3065bfc1b43e
7344866370bd60505061fcc7e8c487339a508bb9
/OpenConcerto/src/org/openconcerto/erp/core/common/ui/AcompteField.java
ba937a63fbc1575a1621504784a0fded7f226fce
[]
no_license
sanogotech/openconcerto_ERP_JAVA
ed3276858f945528e96a5ccfdf01a55b58f92c8d
4d224695be0a7a4527851a06d8b8feddfbdd3d0e
refs/heads/master
2023-04-11T09:51:29.952287
2021-04-21T14:39:18
2021-04-21T14:39:18
360,197,474
0
0
null
null
null
null
UTF-8
Java
false
false
7,814
java
/* * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER. * * Copyright 2011 OpenConcerto, by ILM Informatique. All rights reserved. * * The contents of this file are subject to the terms of the GNU General Public License Version 3 * only ("GPL"). You may not use this file except in compliance with the License. You can obtain a * copy of the License at http://www.gnu.org/licenses/gpl-3.0.html See the License for the specific * language governing permissions and limitations under the License. * * When distributing the software, include this License Header Notice in each file. */ package org.openconcerto.erp.core.common.ui; import org.openconcerto.sql.model.SQLField; import org.openconcerto.sql.request.SQLRowItemView; import org.openconcerto.sql.sqlobject.itemview.RowItemViewComponent; import org.openconcerto.ui.valuewrapper.ValueWrapper; import org.openconcerto.utils.checks.ValidListener; import org.openconcerto.utils.checks.ValidState; import org.openconcerto.utils.doc.Documented; import org.openconcerto.utils.text.SimpleDocumentListener; import java.awt.Font; import java.awt.event.FocusAdapter; import java.awt.event.FocusEvent; import java.awt.event.KeyAdapter; import java.awt.event.KeyEvent; import java.awt.event.MouseAdapter; import java.awt.event.MouseEvent; import java.beans.PropertyChangeListener; import java.beans.PropertyChangeSupport; import java.math.BigDecimal; import javax.swing.JComponent; import javax.swing.JTextField; import javax.swing.event.DocumentEvent; public class AcompteField extends JTextField implements ValueWrapper<Acompte>, Documented, RowItemViewComponent { private SQLField field; private BigDecimal total; private final PropertyChangeSupport supp; // does this component just gained focus private boolean gained; private boolean mousePressed; // the content of this text field when it gained focus private String initialText; public AcompteField() { this(15); } private AcompteField(int columns) { super(columns); this.supp = new PropertyChangeSupport(this); this.gained = false; this.getDocument().addDocumentListener(new SimpleDocumentListener() { public void update(DocumentEvent e) { AcompteField.this.textModified(); } }); this.init(); } public void setTotal(BigDecimal total) { this.total = total; } public BigDecimal getTotal() { return total; } /** * Methode appelée quand le texte est modifié */ protected void textModified() { this.supp.firePropertyChange("value", null, this.getValue()); } @Override public void init(SQLRowItemView v) { this.field = v.getFields().get(0); } private void init() { // TODO use JFormattedTextField => conflit getValue() // DefaultFormatterFactory NumberFormatter (getAllowsInvalid) NumberFormat addFilteringKeyListener(this); // select all on focus gained // except if the user is selecting with the mouse this.addFocusListener(new FocusAdapter() { public void focusGained(FocusEvent e) { AcompteField.this.gained = true; AcompteField.this.initialText = getText(); if (!AcompteField.this.mousePressed) { selectAll(); } } }); this.addMouseListener(new MouseAdapter() { public void mousePressed(MouseEvent e) { AcompteField.this.mousePressed = true; } public void mouseReleased(MouseEvent e) { // don't override the user selection if (AcompteField.this.gained && getSelectedText() == null) { selectAll(); } // don't select all for each mouse released AcompteField.this.gained = false; AcompteField.this.mousePressed = false; } }); this.addKeyListener(new KeyAdapter() { public void keyTyped(KeyEvent keyEvent) { // Sert a annuler une saisie if (keyEvent.getKeyChar() == KeyEvent.VK_ESCAPE) { AcompteField.this.setValue(AcompteField.this.initialText); selectAll(); } } }); } public static void addFilteringKeyListener(final AcompteField textField) { textField.addKeyListener(new KeyAdapter() { public void keyTyped(java.awt.event.KeyEvent keyEvent) { final char keychar = keyEvent.getKeyChar(); if (keychar == KeyEvent.VK_BACK_SPACE) { return; } // pas plus de 2 chiffres apres la virgule int pointPosition = textField.getText().indexOf('.'); if (Character.isDigit(keychar)) { if (pointPosition > -1) { // System.err.println("Text Selected :: " + textField.getSelectedText()); if (textField.getSelectedText() == null) { if (textField.getCaretPosition() <= pointPosition) { return; } else { if (textField.getText().substring(pointPosition).length() <= 6) { return; } } } else { return; } } else { return; } } if (keychar == KeyEvent.VK_PERIOD && textField.getText().indexOf('.') < 0) return; if (keychar == '%' && (textField.getText().indexOf('%') < 0) && textField.getCaretPosition() > 0 && textField.getCaretPosition() == textField.getText().length()) return; keyEvent.consume(); } }); } @Override public final void resetValue() { this.setValue((Acompte) null); } @Override public void setValue(Acompte val) { this.setValue(val == null ? "" : val.toString()); } private final void setValue(String val) { if (!this.getText().equals(val)) this.setText(val); } public void setBold() { this.setFont(getFont().deriveFont(Font.BOLD)); } @Override public String toString() { return this.getClass().getSimpleName(); } @Override public Acompte getValue() { return Acompte.fromString(this.getText().trim()); } @Override public void addValueListener(PropertyChangeListener l) { this.supp.addPropertyChangeListener(l); } @Override public void rmValueListener(PropertyChangeListener l) { this.supp.removePropertyChangeListener(l); } public SQLField getField() { return this.field; } @Override public ValidState getValidState() { // TODO // return "La valeur saisie n'est pas correcte"; return ValidState.getTrueInstance(); } @Override public void addValidListener(ValidListener l) { // FIXME } @Override public void removeValidListener(ValidListener l) { // FIXME } @Override public JComponent getComp() { return this; } public String getDocId() { return "ACOMPTE"; } public String getGenericDoc() { return ""; } public boolean onScreen() { return true; } public boolean isDocTransversable() { return false; } }
[ "davask.42@gmail.com" ]
davask.42@gmail.com
b42768d2deb50a19ca40cdb531b07d761088ee38
b327a374de29f80d9b2b3841db73f3a6a30e5f0d
/out/host/linux-x86/obj/EXECUTABLES/vm-tests_intermediates/main_files/dot/junit/opcodes/float_to_long/Main_testVFE5.java
36e264fa40f36b7176c0fbb29632592de9330ed0
[]
no_license
nikoltu/aosp
6409c386ed6d94c15d985dd5be2c522fefea6267
f99d40c9d13bda30231fb1ac03258b6b6267c496
refs/heads/master
2021-01-22T09:26:24.152070
2011-09-27T15:10:30
2011-09-27T15:10:30
null
0
0
null
null
null
null
UTF-8
Java
false
false
534
java
//autogenerated by util.build.BuildDalvikSuite, do not change package dot.junit.opcodes.float_to_long; import dot.junit.opcodes.float_to_long.d.*; import dot.junit.*; public class Main_testVFE5 extends DxAbstractMain { public static void main(String[] args) throws Exception { try { Class.forName("dot.junit.opcodes.float_to_long.d.T_float_to_long_5"); fail("expected a verification exception"); } catch (Throwable t) { DxUtil.checkVerifyException(t); } } }
[ "fred.faust@gmail.com" ]
fred.faust@gmail.com
f6faf2de43b0139c6824b1147f7ce8a0d629ee12
163e37c8899cd6689828980baa6d058a064dc98e
/o1kuaixue-demo/src/com/gdpph/o1kuaixue/demo/chapter09/section2/section19/CompareObject.java
2606e4cf31c2b806394d10d5cee1e8e3b391d273
[]
no_license
sh2268411762/Java
f4ffb76decac318d99334251615c5b26bee86b99
1d6e89338e02dddb67056b5353eb498876ef381c
refs/heads/master
2023-01-09T10:51:23.847574
2020-11-11T11:24:51
2020-11-11T11:24:51
257,934,424
0
0
null
null
null
null
UTF-8
Java
false
false
444
java
package com.gdpph.o1kuaixue.demo.chapter09.section2.section19; /** * 对象值类型比较 * @author 零壹学堂 */ public class CompareObject { public static void main(String[] args) { String name1 = "对象值"; String name2 = "对象值"; System.out.println("name1和name2是值相等的:" + name1.equals(name2)); System.out.println("name1和name2是引用相等的:" + (name1 == name2)); } }
[ "2268411762@qq.com" ]
2268411762@qq.com
12ba1de6a2da1eb449fa4fce173f8db9f0ebcec4
eeb243c69553ef56ac3d07c4613216ebb5fbaa88
/Chapter3/src/com/geoffrey/tdd/part1/BetaHeroHandler.java
e95116efe8444fad57f0e4a02ab7b2c242179d67
[]
no_license
geoffreymouton520/technical-programing-3-repo
5b561cf374f191bb9169db4688981b47fa20d3c3
3d8b5058c30073c7648d5d7e51cc62072751fef2
refs/heads/master
2020-04-24T19:54:52.835300
2013-10-07T10:15:07
2013-10-07T10:15:07
34,409,413
0
0
null
null
null
null
UTF-8
Java
false
false
722
java
/* * To change this template, choose Tools | Templates * and open the template in the editor. */ package com.geoffrey.tdd.part1; /** * * @author geoffrey */ public class BetaHeroHandler implements HeroHandler { private HeroHandler nextHeroHandler; @Override public void setNext(HeroHandler heroHandler) { nextHeroHandler = heroHandler; } @Override public Hero handleRequest(String type, String heroName, String battleCry) { if ("beta".equals(type) || nextHeroHandler == null) { return new BetaHero(heroName, battleCry); } else { return nextHeroHandler.handleRequest(type, heroName, battleCry); } } }
[ "emokid250@gmail.com@9c931025-5e0e-c7c7-95f7-f36e5c148c03" ]
emokid250@gmail.com@9c931025-5e0e-c7c7-95f7-f36e5c148c03
631f9f18604733d9b889d4e4a095c186de371df8
647ec12ce50f06e7380fdbfb5b71e9e2d1ac03b4
/com.tencent.mm/classes.jar/com/google/android/gms/wearable/zzc.java
18bb23ab79cc02369a050142e261a923e7629b35
[]
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
276
java
package com.google.android.gms.wearable; @Deprecated public abstract interface zzc {} /* Location: L:\local\mybackup\temp\qq_apk\com.tencent.mm\classes7.jar * Qualified Name: com.google.android.gms.wearable.zzc * JD-Core Version: 0.7.0.1 */
[ "98632993+tsuzcx@users.noreply.github.com" ]
98632993+tsuzcx@users.noreply.github.com
bcd325990387b66bef91d45541b2ef9bd3b09538
4be72dee04ebb3f70d6e342aeb01467e7e8b3129
/bin/ext-integration/customerticketingc4cb2bintegration/src/de/hybris/platform/customerticketingc4cb2bintegration/constants/Customerticketingc4cb2bintegrationConstants.java
aac049568069080310747800bc63667bd58cfe20
[]
no_license
lun130220/hybris
da00774767ba6246d04cdcbc49d87f0f4b0b1b26
03c074ea76779f96f2db7efcdaa0b0538d1ce917
refs/heads/master
2021-05-14T01:48:42.351698
2018-01-07T07:21:53
2018-01-07T07:21:53
null
0
0
null
null
null
null
UTF-8
Java
false
false
974
java
/* * [y] hybris Platform * * Copyright (c) 2000-2013 hybris AG * All rights reserved. * * This software is the confidential and proprietary information of hybris * ("Confidential Information"). You shall not disclose such Confidential * Information and shall use it only in accordance with the terms of the * license agreement you entered into with hybris. * * */ package de.hybris.platform.customerticketingc4cb2bintegration.constants; /** * Global class for all Customerticketingc4cb2bintegration constants. You can add global constants for your extension into this class. */ public final class Customerticketingc4cb2bintegrationConstants extends GeneratedCustomerticketingc4cb2bintegrationConstants { public static final String EXTENSIONNAME = "customerticketingc4cb2bintegration"; private Customerticketingc4cb2bintegrationConstants() { //empty to avoid instantiating this constant class } // implement here constants used by this extension }
[ "lun130220@gamil.com" ]
lun130220@gamil.com
c6b89a84e5d5ca701a9ba8cd0535fda9ea3e320a
2869fc39e2e63d994d5dd8876476e473cb8d3986
/pet/pet_ebk_push/src/main/java/com/lvmama/push/model/SessionManager.java
3051b7a867e30732b2fb2f17406594db96928502
[]
no_license
kavt/feiniu_pet
bec739de7c4e2ee896de50962dbd5fb6f1e28fe9
82963e2e87611442d9b338d96e0343f67262f437
refs/heads/master
2020-12-25T17:45:16.166052
2016-06-13T10:02:42
2016-06-13T10:02:42
61,026,061
0
0
null
2016-06-13T10:02:01
2016-06-13T10:02:01
null
UTF-8
Java
false
false
1,897
java
/* * Copyright (C) 2010 Moduad Co., Ltd. * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 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 Public License for more details. * * You should have received a copy of the GNU General Public License along * with this program; if not, write to the Free Software Foundation, Inc., * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. */ package com.lvmama.push.model; import java.util.HashMap; import java.util.Map; import org.apache.mina.core.session.IoSession; /** * This class manages the sessions connected to the server. * * @author Sehwan Noh (devnoh@gmail.com) */ public class SessionManager { private static SessionManager instance; private Map<String,ClientSessionInfo> sessionMap = new HashMap<String, ClientSessionInfo>(); /** * Returns the singleton instance of SessionManager. * * @return the instance */ public static SessionManager getInstance() { if (instance == null) { synchronized (SessionManager.class) { instance = new SessionManager(); } } return instance; } public void putSession(String udid,ClientSessionInfo session){ sessionMap.put(udid, session); } public Map<String,ClientSessionInfo> getSessions(){ return this.sessionMap; } public void removeSession(String udid){ sessionMap.remove(udid); } }
[ "feiniu7903@163.com" ]
feiniu7903@163.com
04d3b0d4cfa95003d3b4b0a5616ebc43508e29af
433eae1806c7c4a0b2ddbc16bb59d296df2482ea
/WMb2b-third/src/main/java/com/wangmeng/expand/ssq/utils/WkHtmlToPdfUtil.java
988a91a6355d5b101b4438e4c8ace04b2619ba6d
[]
no_license
tomdev2008/zxzshop-parent
23dbb7dadcf2d342abb8685f8970312a73199d81
c08568df051b8e592ac35f7ca13e0d4940780a72
refs/heads/master
2021-01-12T01:03:25.156508
2017-01-06T05:39:40
2017-01-06T05:39:40
null
0
0
null
null
null
null
UTF-8
Java
false
false
5,759
java
/* * @(#)WkHtml2PdfUtil.java 2016-10-20上午11:13:38 * Copyright © 2016 网盟. All rights reserved. */ package com.wangmeng.expand.ssq.utils; import java.io.File; import java.io.FileOutputStream; import java.io.OutputStream; import org.apache.commons.lang.builder.ToStringBuilder; import org.apache.log4j.Logger; import com.wangmeng.expand.ssq.utils.ProcessUtils.ProcessStatus; /** * <ul> * <li> * <p> * 系统名程     : 浙江网盟B2B平台项目 <br/> * 子系统名称    : 系统 <br/> * 类/接口名    : WkHtmlToPdfUtil <br/> * 版本信息     : 1.00 <br/> * 新建日期     : 2016-10-20上午11:13:38 <br/> * 作者       : 陈春磊 <br/> * 修改历史 <br/> * 作者 : 衣奎德 * 修改日志  : 2016-11-06 * <b>通过配置文件执行命令,不在运行时判断操作系统 </b> <br/> * <b>增加命令执行超时以及状态判断</b> <br/> * <br/> * * WkHtmlToPdfUtil * * Copyright (c) wangmeng Co., Ltd. 2016. All rights reserved. * </p> * * </li> * </ul> */ public class WkHtmlToPdfUtil { /** * 日志 */ protected static Logger logger = Logger.getLogger(WkHtmlToPdfUtil.class); // 临时目录的路径 public static final String TEMP_DIR_PATH = WkHtmlToPdfUtil.class.getResource("/").getPath().substring(1)+"temp/"; private static String fileFolderPath = WkHtmlToPdfUtil.class.getResource("/").getPath().substring(1)+ "files/"; //--协议模板文件,存放在files中 // public static String htmlModelFilePath = fileFolderPath + "ThrAgreementNew.html"; public static String htmlModelFilePath = "ThrAgreementNew.html"; static { // 生成临时目录 new File(TEMP_DIR_PATH).mkdirs(); // filePath=new FileInputStream(""); } /** * * 将HTML文件内容输出为PDF文件 * * * * @param htmlFilePath * HTML文件路径 * * @param pdfFilePath * PDF文件路径 */ public static void htmlToPdf(String htmlFilePath, String pdfFilePath) { try { String cmd = getCommand(htmlFilePath, pdfFilePath); Process process = Runtime.getRuntime().exec(cmd); new Thread(new ClearBufferThread(process.getInputStream())).start(); new Thread(new ClearBufferThread(process.getErrorStream())).start(); process.waitFor(); } catch (Exception e) { throw new RuntimeException(e); } } /** * * 将HTML字符串转换为HTML文件 * * * * @param htmlStr * HTML字符串 * * @return HTML文件的绝对路径 */ public static void strToHtmlFile(String htmlStr,String htmlFilePath) { OutputStream outputStream = null; try { outputStream = new FileOutputStream(htmlFilePath); outputStream.write(htmlStr.getBytes("UTF-8")); } catch (Exception e) { throw new RuntimeException(e); } finally { try { if (outputStream != null) { outputStream.close(); outputStream = null; } } catch (Exception e) { throw new RuntimeException(e); } } } /** * * 获得HTML转PDF的命令语句 * * * * @param htmlFilePath * HTML文件路径 * * @param pdfFilePath * PDF文件路径 * * @return HTML转PDF的命令语句 */ private static String getCommand(String htmlFilePath, String pdfFilePath) { String osName = System.getProperty("os.name"); // Windows if (osName.startsWith("Windows")) { return String.format(fileFolderPath + "wkhtmltopdf.exe %s %s", htmlFilePath, pdfFilePath); } // Linux else { return String.format(fileFolderPath + "wkhtmltopdf %s %s", htmlFilePath, pdfFilePath); } } /** * 直接返回执行命令 * * @author 衣奎德 * @creationDate. Nov 6, 2016 9:58:46 AM * @param htmlFilePath HTML文件路径 * @param pdfFilePath PDF文件路径 * @param cmdPath 执行文件路径 * @return */ private static String getCommand(String htmlFilePath, String pdfFilePath, String cmdPath) { return String.format(cmdPath + " %s %s", htmlFilePath, pdfFilePath); } /** * 通过ProcessUtils执行 * * @author 衣奎德 * @creationDate. Nov 6, 2016 9:59:33 AM * @param htmlFilePath HTML文件路径 * @param pdfFilePath PDF文件路径 * @param cmdPath 执行文件路径 * @param timeout 超时设置 * @return */ public static boolean htmlToPdf(String htmlFilePath, String pdfFilePath, String cmdPath, long timeout) { if (timeout<=0) { boolean f = true; Process process = null; try { String cmd = getCommand(htmlFilePath, pdfFilePath, cmdPath); process = Runtime.getRuntime().exec(cmd); new Thread(new ClearBufferThread(process.getInputStream())).start(); new Thread(new ClearBufferThread(process.getErrorStream())).start(); process.waitFor(); } catch (Exception e) { f = false; throw new RuntimeException(e); }finally { if (process!=null) { try { process.destroy(); } catch (Exception e) { e.printStackTrace(); } } } return f; }else{ ProcessStatus status = null; try { //获取执行命令 String cmd = getCommand(htmlFilePath, pdfFilePath, cmdPath); logger.info("gen pdf cmd: " + cmd); //执行命令 status = ProcessUtils.execute(timeout, cmd); logger.info("gen pdf status:" + ToStringBuilder.reflectionToString(status)); } catch (Exception e) { throw new RuntimeException(e); } //判断是否执行成功 return status!=null && status.exitCode != ProcessStatus.CODE_STARTED; } } }
[ "admin" ]
admin
faab7babf6761aac19ad2272fc30a1296f77d86a
61c6164c22142c4369d525a0997b695875865e29
/middleware/src/main/java/com/spirit/contabilidad/entity/TipoAsientoIf.java
665289ac8848dcf7d1c7c045c7085de821b62251
[]
no_license
xruiz81/spirit-creacional
e5a6398df65ac8afa42be65886b283007d190eae
382ee7b1a6f63924b8eb895d4781576627dbb3e5
refs/heads/master
2016-09-05T14:19:24.440871
2014-11-10T17:12:34
2014-11-10T17:12:34
26,328,756
1
0
null
null
null
null
UTF-8
Java
false
false
757
java
package com.spirit.contabilidad.entity; import com.spirit.server.SpiritIf; /** * * @author www.versality.com.ec * */ public interface TipoAsientoIf extends SpiritIf{ java.lang.Long getPrimaryKey(); void setPrimaryKey(java.lang.Long pk); java.lang.Long getId(); void setId(java.lang.Long id); java.lang.String getCodigo(); void setCodigo(java.lang.String codigo); java.lang.String getNombre(); void setNombre(java.lang.String nombre); java.lang.Long getEmpresaId(); void setEmpresaId(java.lang.Long empresaId); java.lang.Long getOrden(); void setOrden(java.lang.Long orden); java.lang.String getStatus(); void setStatus(java.lang.String status); }
[ "xruiz@creacional.com" ]
xruiz@creacional.com
8429c9bf6c1a544ff9d23b579d5a97769aa7eefc
48ffebecc569275ea0d60a649f690aae8492f07d
/3310 2018/src/main/java/org/usfirst/frc/team3310/robot/commands/auton/SideStartToSwitch2.java
89ebd133369a08a1e4d251868725204c9f38135f
[]
no_license
Matthew-Ruane/Team-207
3022037135e4046f0e161a2ab1ec8bdd7f254a10
0a61ec6aec557af0d6299b6a30ac7bbabe77fd32
refs/heads/master
2022-12-21T15:18:04.265974
2019-06-17T17:59:28
2019-06-17T17:59:28
182,201,878
1
0
null
2022-12-16T08:18:09
2019-04-19T04:33:27
Java
UTF-8
Java
false
false
2,621
java
package org.usfirst.frc.team3310.robot.commands.auton; import org.usfirst.frc.team3310.paths.PathContainer; import org.usfirst.frc.team3310.robot.commands.DriveAbsoluteTurnMP; import org.usfirst.frc.team3310.robot.commands.DrivePathAdaptivePursuit; import org.usfirst.frc.team3310.robot.commands.DriveResetPoseFromPath; import org.usfirst.frc.team3310.robot.commands.DriveStraightMP; import org.usfirst.frc.team3310.robot.commands.ElevatorSetPositionMP; import org.usfirst.frc.team3310.robot.commands.ElevatorSetZero; import org.usfirst.frc.team3310.robot.commands.IntakeCubeAndLiftAbortDrive; import org.usfirst.frc.team3310.robot.commands.IntakeSetSpeedTimed; import org.usfirst.frc.team3310.robot.commands.RunAfterMarker; import org.usfirst.frc.team3310.robot.subsystems.Drive; import org.usfirst.frc.team3310.robot.subsystems.Elevator; import org.usfirst.frc.team3310.robot.subsystems.Intake; import org.usfirst.frc.team3310.utility.MPSoftwarePIDController.MPSoftwareTurnType; import edu.wpi.first.wpilibj.command.CommandGroup; /** * */ public class SideStartToSwitch2 extends CommandGroup { public SideStartToSwitch2(PathContainer sideStartToCenterStart, PathContainer switchToCenter, PathContainer centerToSwitch, boolean isRight) { addSequential(new ElevatorSetZero(0)); addSequential(new DriveStraightMP(-60, Drive.MP_AUTON_MAX_STRAIGHT_VELOCITY_INCHES_PER_SEC, true, true, 0)); addSequential(new DriveAbsoluteTurnMP(isRight ? 90 : -90, Drive.MP_AUTON_MAX_TURN_RATE_DEG_PER_SEC, MPSoftwareTurnType.TANK)); addSequential(new DriveResetPoseFromPath(sideStartToCenterStart, true)); addParallel(new RunAfterMarker("raiseElevator", 4.0, new ElevatorSetPositionMP(Elevator.SWITCH_POSITION_INCHES))); addSequential(new DrivePathAdaptivePursuit(sideStartToCenterStart)); addSequential(new IntakeSetSpeedTimed(Intake.INTAKE_EJECT_SPEED, 0.5)); addSequential(new DriveResetPoseFromPath(switchToCenter, true)); addParallel(new ElevatorSetPositionMP(Elevator.MIN_POSITION_INCHES)); addSequential(new DrivePathAdaptivePursuit(switchToCenter)); addParallel(new IntakeCubeAndLiftAbortDrive(false)); addSequential(new DriveStraightMP(50, Drive.MP_SLOW_VELOCITY_INCHES_PER_SEC, true, true, 0)); addSequential(new DriveStraightMP(-40, Drive.MP_AUTON_MAX_STRAIGHT_VELOCITY_INCHES_PER_SEC, true, true, 0)); addSequential(new CenterStartToSwitch1(centerToSwitch, false, 0.0)); addParallel(new ElevatorSetPositionMP(Elevator.MIN_POSITION_INCHES)); addSequential(new DriveStraightMP(-15, Drive.MP_AUTON_MAX_STRAIGHT_VELOCITY_INCHES_PER_SEC, true, true, 0)); } }
[ "49774263+Matthew-Ruane@users.noreply.github.com" ]
49774263+Matthew-Ruane@users.noreply.github.com
f7251967d954ca92ba75d4ed61cf3d45df66ddf0
c5c698e88e213121f147dd54b08835c04ce8d1da
/rdfbean-core/src/main/java/com/mysema/rdfbean/schema/ReferenceClass.java
cc0e2c17716876bcdaa97d82298c6916af0f0bb9
[]
no_license
mysema/rdfbean
1cdef5bd6f2a4c8c731380721364a0fe43199494
0808e72c25f6baeb0de9102a56616a6e94e80fe5
refs/heads/master
2023-08-31T14:28:40.299095
2016-01-14T08:39:52
2016-01-14T08:39:52
2,488,848
7
5
null
2013-10-29T10:22:09
2011-09-30T12:16:42
Java
UTF-8
Java
false
false
449
java
/* * Copyright (c) 2010 Mysema Ltd. * All rights reserved. * */ package com.mysema.rdfbean.schema; import com.mysema.rdfbean.annotations.ClassMapping; import com.mysema.rdfbean.model.ID; import com.mysema.rdfbean.owl.OWL; import com.mysema.rdfbean.owl.OWLClass; /** * @author sasa * */ @ClassMapping(ns = OWL.NS, ln = "Class") public class ReferenceClass extends OWLClass { public ReferenceClass(ID id) { super(id); } }
[ "timo.westkamper@mysema.com" ]
timo.westkamper@mysema.com
f21b057efcac32a6f71dc8173a508709227e6b1e
99e267dfdc08bfd956bcc62421265eacf291480e
/newWish/src/thread/ThreadGroupDemo.java
e44fe52f7e846d756e72a352e95b541d41b00517
[]
no_license
agarwalmohit43/Java-Practice
70906101ebe31a003a3401500114303c6fa847df
73b305da3f6777a036fc11e19b689f09d29374bf
refs/heads/master
2021-01-19T16:45:53.028435
2017-09-12T12:11:41
2017-09-12T12:11:41
101,024,586
0
0
null
null
null
null
UTF-8
Java
false
false
496
java
package thread; public class ThreadGroupDemo implements Runnable { @Override public void run() { System.out.println(Thread.currentThread().getName()); } public static void main(String[] args) { ThreadGroupDemo runnable=new ThreadGroupDemo(); ThreadGroup tg= new ThreadGroup("Parent thread"); Thread t=new Thread(tg,runnable,"one"); t.start(); Thread t2=new Thread(tg,runnable,"two"); t2.start(); Thread t3=new Thread(tg,runnable,"three"); t3.start(); } }
[ "agarwalmohit43@gmail.com" ]
agarwalmohit43@gmail.com
ab24607f2126538ece5053f1b87dd42884434453
1c6fe1c9ad917dc9dacaf03eade82d773ccf3c8a
/acm-module-szxm/src/main/java/com/wisdom/acm/szxm/po/sysscore/ObjectScoreDetailPo.java
4b52752273e6020f9cbb2b2df502968706a633a7
[ "Apache-2.0" ]
permissive
daiqingsong2021/ord_project
332056532ee0d3f7232a79a22e051744e777dc47
a8167cee2fbdc79ea8457d706ec1ccd008f2ceca
refs/heads/master
2023-09-04T12:11:51.519578
2021-10-28T01:58:43
2021-10-28T01:58:43
406,659,566
0
0
null
null
null
null
UTF-8
Java
false
false
1,131
java
package com.wisdom.acm.szxm.po.sysscore; /** * Author:wqd * Date:2019-12-30 16:19 * Description:<描述> */ import com.wisdom.base.common.po.BasePo; import lombok.Data; import javax.persistence.Column; import javax.persistence.Table; import java.math.BigDecimal; /** * 系统评分____客观评分明细表 */ @Table(name = "szxm_sys_objectivescore_detail") @Data public class ObjectScoreDetailPo extends BasePo { /** * 项目ID */ @Column(name = "project_id") private Integer projectId; /** * 标段ID */ @Column(name = "section_id") private Integer sectionId; /** * 评分所属年份 */ @Column(name = "year") private Integer year; /** * 评分所属月份 */ @Column(name = "month") private Integer month; /** * 考核项编码 */ @Column(name = "item_code") private String itemCode; /** * 扣分次数 */ @Column(name = "deduction_count") private Integer deductionCount; /** * 扣分值 */ @Column(name = "deduction") private BigDecimal deduction; }
[ "homeli@126.com" ]
homeli@126.com
25df411faa63c8f65eae25d562b2c33db0d46622
a717accc33dd52b29132c406e5328e360384272c
/app/src/main/java/com/d2cmall/shopkeeper/ui/view/TransparentPop.java
db3b46e8629cd0516702783c5b679df6765cd421
[]
no_license
sinbara0813/shopKeeper
41e4bf339cbeb069b62e00b272b24c97d1a0a8e3
00be143baf4a69a44bcc06abb6d4d54628e998c8
refs/heads/master
2020-06-15T03:09:17.458288
2019-08-17T01:32:52
2019-08-17T01:32:52
195,188,798
0
0
null
null
null
null
UTF-8
Java
false
false
7,931
java
package com.d2cmall.shopkeeper.ui.view; import android.content.Context; import android.graphics.Rect; import android.graphics.drawable.ColorDrawable; import android.os.Build; import android.view.Gravity; import android.view.LayoutInflater; import android.view.View; import android.view.View.OnClickListener; import android.view.animation.Animation; import android.view.animation.Animation.AnimationListener; import android.widget.LinearLayout; import android.widget.LinearLayout.LayoutParams; import android.widget.PopupWindow; import android.widget.RelativeLayout; import com.d2cmall.shopkeeper.R; public class TransparentPop extends PopupWindow { private Context mContext; private InvokeListener mInvokeListener; private DismissListener dismissListener; private View contentView; private boolean defineWidth = false; private int mWidth; private boolean defineHeight = false; private int mHeight; private LinearLayout parent; private RelativeLayout rootLayout; private Animation inAnimation; private Animation outAnimation; private boolean hasAnimation = true; private boolean isClickDismiss = true; public TransparentPop(Context context, InvokeListener listener) { this(context, -1, -1, true, listener); } public TransparentPop(Context context, boolean isClickDismiss, InvokeListener listener) { this(context, -1, -1, isClickDismiss, listener); } public TransparentPop(Context context, int width, int height, boolean isClickDismiss, InvokeListener listener) { super(context); this.mContext = context.getApplicationContext(); this.isClickDismiss=isClickDismiss; this.mInvokeListener = listener; if (width > 0) { defineWidth = true; mWidth = width; } if (height > 0) { defineHeight = true; mHeight = height; } init(); } private void init() { contentView = LayoutInflater.from(mContext).inflate(R.layout.layout_transparent_pop, new RelativeLayout(mContext), false); parent = (LinearLayout) contentView.findViewById(R.id.content); rootLayout = (RelativeLayout) contentView.findViewById(R.id.root); if (mInvokeListener != null) { mInvokeListener.invokeView(parent); } if (defineWidth) { setWidth(mWidth); } else { setWidth(LayoutParams.MATCH_PARENT); } if (defineHeight) { setHeight(mHeight); } else { setHeight(LayoutParams.MATCH_PARENT); } setContentView(contentView); setFocusable(true); setOutsideTouchable(false); setBackgroundDrawable(new ColorDrawable()); if (isClickDismiss){ contentView.setOnClickListener(new OnClickListener() { @Override public void onClick(View v) { dismiss(hasAnimation); } }); } setOnDismissListener(new OnDismissListener() { @Override public void onDismiss() { if (mInvokeListener!=null){ mInvokeListener.releaseView(parent); } if (dismissListener!=null){ dismissListener.dismissEnd(); } } }); } public void setOnkey(View.OnKeyListener onkey){ rootLayout.setOnKeyListener(onkey); } private void setAnimationListener() { outAnimation.setAnimationListener(new AnimationListener() { @Override public void onAnimationStart(Animation animation) { if (dismissListener!=null){ dismissListener.dismissStart(); } } @Override public void onAnimationRepeat(Animation animation) { } @Override public void onAnimationEnd(Animation animation) { contentView.post(new Runnable() { @Override public void run() { dismiss(); } }); } }); } public void setRootLayoutBackground(int id) { if (rootLayout != null) { rootLayout.setBackgroundResource(id); } } public void dismissFromOut() { contentView.setOnClickListener(new OnClickListener() { @Override public void onClick(View v) { dismiss(hasAnimation); } }); } public interface InvokeListener { void invokeView(LinearLayout v); void releaseView(LinearLayout v); } public void show(View reference) { show(reference, true); } public void show(View reference, boolean hasAnimation) { show(reference, 0, 0, hasAnimation); } public void show(View reference, int width, int height, boolean hasAnimation) { if (hasAnimation&&inAnimation!=null) { int childCount=parent.getChildCount(); if (childCount>0){ parent.getChildAt(0).startAnimation(inAnimation); }else { parent.startAnimation(inAnimation); } } showAtLocation(reference, Gravity.CENTER, width, height); } public void show(View reference,int gravity, int width, int height, boolean hasAnimation) { if (hasAnimation&&inAnimation!=null) { int childCount=parent.getChildCount(); if (childCount>0){ parent.getChildAt(0).startAnimation(inAnimation); }else { parent.startAnimation(inAnimation); } } showAtLocation(reference, gravity, width, height); } public void showAsParent(View view,boolean hasAnimation){ if (hasAnimation&&inAnimation!=null) { int childCount=parent.getChildCount(); if (childCount>0){ parent.getChildAt(0).startAnimation(inAnimation); }else { parent.startAnimation(inAnimation); } } showAsDropDown(this,view); } public void dismiss(boolean hasAnimation) { if (hasAnimation&&outAnimation!=null) { int childCount=parent.getChildCount(); if (childCount>0){ parent.getChildAt(0).startAnimation(outAnimation); }else { parent.startAnimation(outAnimation); } } else { dismiss(); } } public void setInAnimation(Animation inAnimation) { this.inAnimation = inAnimation; } public void setOutAnimation(Animation outAnimation) { this.outAnimation = outAnimation; setAnimationListener(); } public void setBackGroundResource(int id) { if (contentView != null) { contentView.setBackgroundResource(id); } } public View getParent() { return parent; } public void setDismissListener(DismissListener dismissListener) { this.dismissListener = dismissListener; } public interface DismissListener{ void dismissStart(); void dismissEnd(); } public void showAsDropDown(PopupWindow pw, View anchor) { //7.0以上popwindow在高度matchparent,并且弹窗的Gravity不是 Gravity.START | Gravity.TOP,弹窗的显示效果没有在锚点View下的bug兼容 if (Build.VERSION.SDK_INT >= 24) { Rect visibleFrame = new Rect(); anchor.getGlobalVisibleRect(visibleFrame); int height = anchor.getResources().getDisplayMetrics().heightPixels - visibleFrame.bottom; pw.setHeight(height); pw.showAsDropDown(anchor); } else { pw.showAsDropDown(anchor); } } }
[ "940258169@qq.com" ]
940258169@qq.com
dfa91e44d65c82ac65a68551f390cf6b8fcf2868
f8af02dd6d14287f6bfbb8725e3b11094261875b
/deps/src/main/java/com/newrelic/deps/org/apache/http/protocol/HttpProcessor.java
9b6cea1e33312ac631e9385581cd6134b588addb
[]
no_license
masonmei/mx
fca12bedf2c9fef30452a485b81e23d416a0b534
38e0909f9a1720f32d59af280d7fd9a591c45f6c
refs/heads/master
2021-01-11T04:57:18.501563
2015-07-30T08:20:28
2015-07-30T08:20:31
39,553,289
2
3
null
null
null
null
UTF-8
Java
false
false
2,374
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. * ==================================================================== * * 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/>. * */ package com.newrelic.deps.org.apache.http.protocol; import com.newrelic.deps.org.apache.http.HttpRequestInterceptor; import com.newrelic.deps.org.apache.http.HttpResponseInterceptor; /** * HTTP protocol processor is a collection of protocol interceptors that * implements the 'Chain of Responsibility' pattern, where each individual * protocol interceptor is expected to work on a particular aspect of the HTTP * protocol the interceptor is responsible for. * <p> * Usually the order in which interceptors are executed should not matter as * long as they do not depend on a particular state of the execution context. * If protocol interceptors have interdependencies and therefore must be * executed in a particular order, they should be added to the protocol * processor in the same sequence as their expected execution order. * <p> * Protocol interceptors must be implemented as thread-safe. Similarly to * servlets, protocol interceptors should not use instance variables unless * access to those variables is synchronized. * * @since 4.0 */ public interface HttpProcessor extends HttpRequestInterceptor, HttpResponseInterceptor { // no additional methods }
[ "dongxu.m@gmail.com" ]
dongxu.m@gmail.com
7d0092de0a1f636abf47dfdd08c58eef7c813ed5
fa91450deb625cda070e82d5c31770be5ca1dec6
/Diff-Raw-Data/15/15_ca173537dd6765ca29e471d843c4ebeb42c3ba95/KloConfigGraph/15_ca173537dd6765ca29e471d843c4ebeb42c3ba95_KloConfigGraph_s.java
91f601ea37032d9e4fe7bf3abf058e93d96e60f3
[]
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
3,203
java
/******************************************************************************* * Copyright (c) 2011 Thales Corporate Services SAS * * Author : Aravindan Mahendran * * * * Permission is hereby granted, free of charge, to any person obtaining a copy * * of this software and associated documentation files (the "Software"), to deal* * in the Software without restriction, including without limitation the rights * * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell * * copies of the Software, and to permit persons to whom the Software is * * furnished to do so, subject to the following conditions: * * * * The above copyright notice and this permission notice shall be included in * * all copies or substantial portions of the Software. * * * * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR * * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, * * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE * * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER * * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,* * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN * * THE SOFTWARE. * *******************************************************************************/ package com.thalesgroup.hudson.plugins.klocwork.config; import com.thalesgroup.hudson.plugins.klocwork.graph.KloGraph; import java.io.Serializable; public class KloConfigGraph implements Serializable { private int xSize = KloGraph.DEFAULT_CHART_WIDTH; private int ySize = KloGraph.DEFAULT_CHART_HEIGHT; private boolean displayAllError = true; private boolean displayHighSeverity = true; private boolean displayLowSeverity = true; public KloConfigGraph() { } public KloConfigGraph(int xSize, int ySize, boolean diplayAllError, boolean displayHighSeverity, boolean displayLowSeverity) { super(); this.xSize = xSize; this.ySize = ySize; this.displayAllError = diplayAllError; this.displayHighSeverity = displayHighSeverity; this.displayLowSeverity = displayLowSeverity; } public int getXSize() { return xSize; } public int getYSize() { return ySize; } public boolean isDisplayAllError() { return displayAllError; } public boolean isDisplayHighSeverity() { return displayHighSeverity; } public boolean isDisplayLowSeverity() { return displayLowSeverity; } }
[ "yuzhongxing88@gmail.com" ]
yuzhongxing88@gmail.com
ce40958aa15f5f75bb6b1d8ceb9443b17effe1b9
f54e185f653d025c971cda63c3db24e7ff9100a1
/src/main/java/pt/gapiap/servlets/language/en/UploadErrorsContentEN.java
e7d553cca817ed98a02d3a7c05b6cabcf2a489a1
[]
no_license
fabm/cloud-beans
b559582040a74cd6fa2673e8dd36759fd50ee7ab
f5b386a1099ba61358acb1d4091c0cbff418d80c
refs/heads/master
2021-01-23T02:29:40.798543
2014-10-26T15:45:19
2014-10-26T15:45:19
null
0
0
null
null
null
null
UTF-8
Java
false
false
1,336
java
package pt.gapiap.servlets.language.en; import com.google.common.collect.ImmutableMap; import pt.gapiap.cloud.endpoints.errors.ErrorTemplate; import pt.gapiap.cloud.endpoints.errors.ParametrizedErrorTemplate; import pt.gapiap.cloud.endpoints.errors.SimpleErrorTemplate; import pt.gapiap.servlets.language.UploadErrorsContent; import java.util.Iterator; import java.util.Map; public class UploadErrorsContentEN implements UploadErrorsContent { private Map<Integer, ErrorTemplate> map; public UploadErrorsContentEN() { init(); } private void init() { map = ImmutableMap.<Integer, ErrorTemplate>builder() .put(NO_ACTION_PARAMETER, new SimpleErrorTemplate("There is no parameter for the action")) .put(NO_UPLOAD_ACTION_REGISTERED, new ParametrizedErrorTemplate("There is no upload registered for the action '{0}'")) .put(KEY_NOT_NULL_STRING, new ParametrizedErrorTemplate("Key of method {0} must be a not null String")) .put(KEY_ALREADY_EXISTS, new ParametrizedErrorTemplate("The key {0} already exists")) .build(); } @Override public String getLanguage() { return "en"; } @Override public Map<String, ?> getArgs() { return null; } @Override public Iterator<Map.Entry<Integer, ErrorTemplate>> iterator() { return map.entrySet().iterator(); } }
[ "francisco.ab.monteiro@gmail.com" ]
francisco.ab.monteiro@gmail.com
2d5177bb310ddae26a8e83e039428cf650ea50ec
b5c0433f0ebe46018457dd8ae8763f7ff9bcb06b
/src/com/others/Senjata.java
83071d672a7e811ba778cedf68b59cb82d1e7ff5
[]
no_license
hendrosteven/lithan-oop
8a204a2b0a25784e8b419909e547f438b2a71665
389059a4008e07ecfbeaf6e90ad94a52ce2f1d78
refs/heads/master
2022-06-24T07:15:51.955582
2020-05-06T15:05:07
2020-05-06T15:05:07
261,794,024
0
0
null
null
null
null
UTF-8
Java
false
false
427
java
package com.others; public class Senjata { int peluru; public Senjata(){ } public Senjata(int peluru){ this.reload(peluru); } public void tembak(){ if(peluru>0){ System.out.println("doorr.."); --peluru; }else{ System.out.println("please reload!"); } } public void reload(int peluru){ this.peluru = peluru; } }
[ "hendro.steven@gmail.com" ]
hendro.steven@gmail.com
7f0c9f4f6fe64840f7be4338b5b204bc3d1a6685
a9e8b12208850187f515bbb22813932f609f3c49
/src/lcdNumbers/LcdLine.java
21f0b565d733818c22cef1283f6e26dc29310373
[]
no_license
mustafa1mashtah/Butterfly-Business
f2571624f9bde3ac57c45331597c532be24955c6
5a66ab6c96a3ffdf3eb45881b6b4004757421fd7
refs/heads/master
2020-06-07T07:53:43.262571
2019-06-20T18:12:01
2019-06-20T18:12:01
192,966,482
0
0
null
null
null
null
UTF-8
Java
false
false
1,049
java
package lcdNumbers; import java.util.Objects; public class LcdLine { private String part1; private String part2; private String part3; public LcdLine(String part1, String part2, String part3) { this.part1 = part1; this.part2 = part2; this.part3 = part3; } public String getPart1() { return part1; } public String getPart2() { return part2; } public String getPart3() { return part3; } @Override public boolean equals(Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; LcdLine line = (LcdLine) o; return Objects.equals(part1, line.part1) && Objects.equals(part2, line.part2) && Objects.equals(part3, line.part3); } @Override public int hashCode() { return Objects.hash(part1, part2, part3); } @Override public String toString() { return part1 + "\n" + part2 + "\n" + part3 + "\n"; } }
[ "mashtah.moustafa@gmail.com" ]
mashtah.moustafa@gmail.com
64cf266d3026bcb5b19afae409a91c055af4d439
e4d553ac65f9d3968ca848b2fccb91cf306240ae
/flink-table/flink-table-runtime-blink/src/main/java/org/apache/flink/table/runtime/operators/bundle/trigger/BundleTriggerCallback.java
43a64a369c09ef111ccd69dc3c675168cb19289f
[]
no_license
cshang2017/myread
57ad6e6012ea234109b71d4f3b75d7fdb41b121a
7c510bdc1144931a7a08ae74483d6ee3ead27bea
refs/heads/main
2023-05-07T04:05:24.938688
2021-05-27T01:40:17
2021-05-27T01:40:17
362,284,939
0
1
null
null
null
null
UTF-8
Java
false
false
561
java
package org.apache.flink.table.runtime.operators.bundle.trigger; import org.apache.flink.annotation.Internal; /** * Interface for bundle trigger callbacks that can be registered to a {@link BundleTrigger}. */ @Internal public interface BundleTriggerCallback { /** * This method is invoked to finish current bundle and start a new one when the trigger was fired. * * @throws Exception This method may throw exceptions. Throwing an exception will cause the operation * to fail and may trigger recovery. */ void finishBundle() throws Exception; }
[ "shangcs@yahoo.com" ]
shangcs@yahoo.com
290b1ec381d9e2934276466416a602de698913f9
fa93c9be2923e697fb8a2066f8fb65c7718cdec7
/sources/a2/a/a/g2/c/b/b.java
45f7f0a17d3486bf3f05d0acb7f4512a19296596
[]
no_license
Auch-Auch/avito_source
b6c9f4b0e5c977b36d5fbc88c52f23ff908b7f8b
76fdcc5b7e036c57ecc193e790b0582481768cdc
refs/heads/master
2023-05-06T01:32:43.014668
2021-05-25T10:19:22
2021-05-25T10:19:22
370,650,685
0
0
null
null
null
null
UTF-8
Java
false
false
466
java
package a2.a.a.g2.c.b; import io.reactivex.annotations.NonNull; import io.reactivex.functions.Function; import kotlin.jvm.functions.Function1; public final class b implements Function { public final /* synthetic */ Function1 a; public b(Function1 function1) { this.a = function1; } @Override // io.reactivex.functions.Function public final /* synthetic */ Object apply(@NonNull Object obj) { return this.a.invoke(obj); } }
[ "auchhunter@gmail.com" ]
auchhunter@gmail.com
c23d28894ae1c0d85d270068aab16c42a0c3f66d
c32d1d567d12928ffe7b52ffe09de9a64db0b39e
/new/201907/src/函数式编程/方法引用.java
8413d5d49ddd6c2fd1c678b71644251c28b3c81a
[]
no_license
madokast/JavaLearning
fdafb1f1770ff4839898bbfacaec25dd651a72e6
b6c419e152f13c2d8688644b102b80624ae8b433
refs/heads/master
2022-12-24T13:14:44.659868
2020-01-03T07:10:18
2020-01-03T07:10:18
159,938,675
0
0
null
2022-12-16T06:44:43
2018-12-01T11:40:59
HTML
UTF-8
Java
false
false
487
java
package 函数式编程; public class 方法引用 { public static void main(String[] args) { printString(方法引用::printTwice); printString(new 方法引用()::print3); printString(new Son()::print3); } public static void printString(Printable p){ p.print("hello"); } public static void printTwice(String s){ System.out.println(s+s); } public void print3(String s){ System.out.println(s+s+s); } }
[ "578562554@qq.com" ]
578562554@qq.com
3105065de23a36dca9439a5560b014c6cf82c0a1
88d3bc0441bcb4f679f1351066e7103a5e1daad4
/BigNews-master/sample/src/main/java/ha/excited/sample/MainActivity.java
7b278a69385ac7f1488c34cb985fa30418786377
[ "Apache-2.0" ]
permissive
ShaoqiangPei/IncrementUpdate
611bd2147869f87875cc8d9a3d63707c02077118
9f9cc150687b92e7178ffedf1005eebb7e5d1a9e
refs/heads/master
2020-12-27T13:23:44.374081
2020-02-04T06:56:24
2020-02-04T06:56:24
237,917,496
0
0
null
null
null
null
UTF-8
Java
false
false
3,623
java
package ha.excited.sample; import android.Manifest; import android.app.Activity; import android.content.Intent; import android.content.pm.PackageManager; import android.net.Uri; import android.os.Build; import android.os.Bundle; import android.os.Environment; import android.view.View; import android.widget.Toast; import androidx.core.app.ActivityCompat; import androidx.core.content.ContextCompat; import androidx.core.content.FileProvider; import java.io.File; public class MainActivity extends Activity { private static final String PATH = Environment.getExternalStorageDirectory().getPath(); private static final String NEW_APK = PATH + File.separator + "new.apk"; private static final String OUT_APK = PATH + File.separator + "out.apk"; private static final String PATCH_FILE = PATH + File.separator + "patch"; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_main); findViewById(R.id.buttonDiff).setOnClickListener(new View.OnClickListener() { @Override public void onClick(View v) { diff(); } }); findViewById(R.id.buttonMake).setOnClickListener(new View.OnClickListener() { @Override public void onClick(View v) { make(); } }); } @Override public void onRequestPermissionsResult(int requestCode, String[] permissions, int[] grantResults) { super.onRequestPermissionsResult(requestCode, permissions, grantResults); } private void diff() { if(!hasPermission()) return; if (PatchUtil.diff(this, NEW_APK, PATCH_FILE)) { Toast.makeText(this, getString(R.string.diff_done) + PATCH_FILE, Toast.LENGTH_SHORT).show(); } else { Toast.makeText(this, getString(R.string.diff_failed), Toast.LENGTH_SHORT).show(); } } private void make() { if(!hasPermission()) return; if (PatchUtil.make(this, OUT_APK, PATCH_FILE)) { Toast.makeText(this, getString(R.string.make_done) + OUT_APK, Toast.LENGTH_SHORT).show(); install(OUT_APK); } else { Toast.makeText(this, getString(R.string.make_failed), Toast.LENGTH_SHORT).show(); } } private void install(String apkPath) { if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.N) { startActivity(new Intent(Intent.ACTION_VIEW).setFlags(Intent.FLAG_GRANT_READ_URI_PERMISSION).setDataAndType(FileProvider.getUriForFile(this, BuildConfig.APPLICATION_ID + ".provider", new File(apkPath)), "application/vnd.android.package-archive")); } else { startActivity(new Intent(Intent.ACTION_VIEW).setDataAndType(Uri.fromFile(new File(apkPath)), "application/vnd.android.package-archive")); } } private boolean hasPermission() { if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.M) { int i = ContextCompat.checkSelfPermission(this, Manifest.permission.WRITE_EXTERNAL_STORAGE); if (i == PackageManager.PERMISSION_GRANTED) { return true; } } Toast.makeText(this, getString(R.string.permission_invalid), Toast.LENGTH_SHORT).show(); requestPermission(); return false; } private void requestPermission() { ActivityCompat.requestPermissions(this, new String[] { Manifest.permission.REQUEST_INSTALL_PACKAGES, Manifest.permission.READ_EXTERNAL_STORAGE, Manifest.permission.WRITE_EXTERNAL_STORAGE }, 0x0001); } }
[ "769936726@qq.com" ]
769936726@qq.com
303ae736ab735ce4ee01cf6469fa2c5aea520f26
6c841819570a4034014fbf0cd5f5471f415693ce
/app/src/main/java/ru/pavlenty/roomexample/room/TaskDao.java
922102785dc8c23716f2db8daa3c4584e2228c80
[]
no_license
pavlentytest/1329_room_rxjava
1601b9247eb107189e1c372975f58036c893ee0d
d5527963c28e5b7228a4e47319369851bac9b3ca
refs/heads/master
2023-03-24T06:34:35.187510
2021-03-11T13:22:42
2021-03-11T13:22:42
346,709,369
1
0
null
null
null
null
UTF-8
Java
false
false
455
java
package ru.pavlenty.roomexample.room; import java.util.List; import androidx.room.Dao; import androidx.room.Delete; import androidx.room.Insert; import androidx.room.Query; import androidx.room.Update; import io.reactivex.Flowable; @Dao public interface TaskDao { @Query("SELECT * FROM task") Flowable<List<Task>> getAll(); @Insert void insert(Task t); @Delete void delete(Task t); @Update void update(Task t); }
[ "impetus@yandex.ru" ]
impetus@yandex.ru
21dbd48916e9d41d9c0c9f3c8acddd28e30431d8
95c49f466673952b465e19a5ee3ae6eff76bee00
/src/main/java/com/baidu/tts/client/SynthesizerTool.java
962eedcc1db204488679f555a00ae39b7df6cfcc
[]
no_license
Phantoms007/zhihuAPK
58889c399ae56b16a9160a5f48b807e02c87797e
dcdbd103436a187f9c8b4be8f71bdf7813b6d201
refs/heads/main
2023-01-24T01:34:18.716323
2020-11-25T17:14:55
2020-11-25T17:14:55
null
0
0
null
null
null
null
UTF-8
Java
false
false
1,171
java
package com.baidu.tts.client; import com.baidu.tts.jni.EmbeddedSynthesizerEngine; import com.baidu.tts.tools.ResourceTools; import com.baidu.tts.tools.StringTool; import java.io.File; public class SynthesizerTool { public static boolean verifyModelFile(String str) { if (StringTool.isEmpty(str)) { return false; } try { if (EmbeddedSynthesizerEngine.bdTTSVerifyDataFile(ResourceTools.stringToByteArrayAddNull(str)) >= 0) { return true; } return false; } catch (Exception unused) { return false; } } public static String getEngineInfo() { return EmbeddedSynthesizerEngine.bdTTSGetEngineParam(); } public static int getEngineVersion() { return EmbeddedSynthesizerEngine.getEngineMinVersion(); } public static String getModelInfo(String str) { if (StringTool.isEmpty(str)) { return null; } File file = new File(str); if (!file.exists() || !file.canRead()) { return null; } return EmbeddedSynthesizerEngine.bdTTSGetDatParam(str); } }
[ "seasonpplp@qq.com" ]
seasonpplp@qq.com
79fef17993fc8a2c207a29c19ed6220eb0bf89ae
5bc9d8f92f38967cc9ecc03000c0606dbbb38f74
/sca4j2/modules/trunk/kernel/impl/sca4j-fabric/src/main/java/org/sca4j/fabric/generator/wire/ResourceWireCommandGenerator.java
235ddca61ea9e6b17c7a4be0c065e6c9e2cc425d
[]
no_license
codehaus/service-conduit
795332fad474e12463db22c5e57ddd7cd6e2956e
4687d4cfc16f7a863ced69ce9ca81c6db3adb6d2
refs/heads/master
2023-07-20T00:35:11.240347
2011-08-24T22:13:28
2011-08-24T22:13:28
36,342,601
2
0
null
null
null
null
UTF-8
Java
false
false
3,524
java
/* * SCA4J * Copyright (c) 2008-2012 Service Symphony Limited * * This proprietary software may be used only in connection with the SCA4J license * (the ?License?), a copy of which is included in the software or may be obtained * at: http://www.servicesymphony.com/licenses/license.html. * * Software distributed under the License is distributed on an as is basis, without * warranties or conditions of any kind. See the License for the specific language * governing permissions and limitations of use of the software. This software is * distributed in conjunction with other software licensed under different terms. * See the separate licenses for those programs included in the distribution for the * permitted and restricted uses of such software. * */ /* * 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.sca4j.fabric.generator.wire; import org.osoa.sca.annotations.Property; import org.osoa.sca.annotations.Reference; import org.sca4j.fabric.command.AttachWireCommand; import org.sca4j.spi.generator.AddCommandGenerator; import org.sca4j.spi.generator.GenerationException; import org.sca4j.spi.model.instance.LogicalComponent; import org.sca4j.spi.model.instance.LogicalCompositeComponent; import org.sca4j.spi.model.instance.LogicalResource; import org.sca4j.spi.model.physical.PhysicalWireDefinition; /** * Generate a command to attach local wires from a component to its resources. * * @version $Revision: 5249 $ $Date: 2008-08-21 02:07:42 +0100 (Thu, 21 Aug 2008) $ */ public class ResourceWireCommandGenerator implements AddCommandGenerator { private final PhysicalWireGenerator physicalWireGenerator; private final int order; public ResourceWireCommandGenerator(@Reference PhysicalWireGenerator physicalWireGenerator, @Property(name = "order")int order) { this.physicalWireGenerator = physicalWireGenerator; this.order = order; } public int getOrder() { return order; } public AttachWireCommand generate(LogicalComponent<?> component) throws GenerationException { if (component instanceof LogicalCompositeComponent) { return null; } AttachWireCommand command = new AttachWireCommand(order); generatePhysicalWires(component, command); return command; } private void generatePhysicalWires(LogicalComponent<?> component, AttachWireCommand command) throws GenerationException { if (component.isProvisioned()) { return; } for (LogicalResource<?> resource : component.getResources()) { PhysicalWireDefinition pwd = physicalWireGenerator.generateResourceWire(component, resource); command.addPhysicalWireDefinition(pwd); } } }
[ "meerajk@15bcc2b3-4398-4609-aa7c-97eea3cd106e" ]
meerajk@15bcc2b3-4398-4609-aa7c-97eea3cd106e
134538f515b5d9058f976d43b2f40c20519f959e
1132cef0ea0246b0ef505ee8daa3cdb342499fbc
/LeetCode/src/Challenge_30_Day/May/week3/Minimum_Path_Sum_.java
e62383c213932bd77d1a74700c014486961de251
[]
no_license
zhhaochen/Algorithm
fd92a748fd727700abba8ad92db0d72663058666
509a8f29f00ed665182c8314c11c5a67b023701f
refs/heads/master
2023-07-02T08:14:13.918245
2021-08-05T16:31:08
2021-08-05T16:31:08
288,951,652
0
0
null
null
null
null
UTF-8
Java
false
false
1,884
java
package Challenge_30_Day.May.week3; /** * Given a m x n grid filled with non-negative numbers, find a path from top left to bottom right which minimizes the sum of all numbers along its path. * Note: You can only move either down or right at any point in time * Input: * [ * [1,3,1], * [1,5,1], * [4,2,1] * ] * Output: 7 * Explanation: Because the path 1→3→1→1→1 minimizes the sum. * 本来以为是用dfs,然而在数据量大的时候超时,后来知道这是一个动态规划问题 */ public class Minimum_Path_Sum_ { public static void main(String[] args) { int[][] grid = new int[][]{{1, 3, 1}, {1, 5, 1}, {4, 2, 1}}; } public int minPathSum(int[][] grid) { int m = grid.length; int n = grid[0].length; int[][] dp = new int[m][n]; dp[0][0] = grid[0][0]; //首行和首列上的最小路径是固定的 for (int i=1; i<m; i++){ dp[i][0] = grid[i][0] + dp[i-1][0]; } for (int j=1; j<n;j++){ dp[0][j] = grid[0][j] + dp[0][j-1]; } for (int i=1; i<m; i++){ for (int j=1; j<n; j++){ dp[i][j] = grid[i][j] + Math.min(dp[i-1][j], dp[i][j-1]); } } return dp[m-1][n-1]; } public int minPathSum2(int[][] grid) { int m = grid.length; int n = grid[0].length; //首行和首列上的最小路径是固定的 for (int i=0; i<m; i++){ for (int j=0; j<n; j++){ if (i==0 && j!=0){ grid[i][j] += grid[i][j-1]; }else if (i!=0&&j==0){ grid[i][j] += grid[i-1][j]; } if (i!=0 && j!=0){ grid[i][j] += Math.min(grid[i-1][j], grid[i][j-1]); } } } return grid[m-1][n-1]; } }
[ "zhhaochen@gmail.com" ]
zhhaochen@gmail.com
3ef76f8ba44f6985f3463c1b59c211004878317f
0874d515fb8c23ae10bf140ee5336853bceafe0b
/l2j-universe-lindvior/Lindvior Source/gameserver/src/main/java/l2p/gameserver/handler/admincommands/impl/AdminGm.java
ecaee64bd3a2fe6d70f2f8d2561b24f2b2cde078
[]
no_license
NotorionN/l2j-universe
8dfe529c4c1ecf0010faead9e74a07d0bc7fa380
4d05cbd54f5586bf13e248e9c853068d941f8e57
refs/heads/master
2020-12-24T16:15:10.425510
2013-11-23T19:35:35
2013-11-23T19:35:35
37,354,291
0
1
null
null
null
null
UTF-8
Java
false
false
1,424
java
package l2p.gameserver.handler.admincommands.impl; import l2p.gameserver.handler.admincommands.IAdminCommandHandler; import l2p.gameserver.model.Player; /** * This class handles following admin commands: - gm = turns gm mode on/off */ public class AdminGm implements IAdminCommandHandler { private static enum Commands { admin_gm } @SuppressWarnings("rawtypes") @Override public boolean useAdminCommand(Enum comm, String[] wordList, String fullString, Player activeChar) { Commands command = (Commands) comm; // TODO зачем отключено? if (Boolean.TRUE) return false; if (!activeChar.getPlayerAccess().CanEditChar) return false; switch (command) { case admin_gm: handleGm(activeChar); break; } return true; } @SuppressWarnings("rawtypes") @Override public Enum[] getAdminCommandEnum() { return Commands.values(); } private void handleGm(Player activeChar) { if (activeChar.isGM()) { activeChar.getPlayerAccess().IsGM = false; activeChar.sendMessage("You no longer have GM status."); } else { activeChar.getPlayerAccess().IsGM = true; activeChar.sendMessage("You have GM status now."); } } }
[ "jmendezsr@gmail.com" ]
jmendezsr@gmail.com
a56bbb10e643e299cd0de603030eab7214c93399
0348bc8d7e7454840fccc9c91f621a5a232b71c5
/sources/com/google/android/gms/internal/aa.java
9f9312558021c8010767bdd28b10fcc5b5823cac
[]
no_license
nhannguyen95/jump-monster
c5927a0f0bd2b4c96a10f9ee5dcc0e8e5717aebe
8b7debabfe06cdd4d7cdbcb6253167acd6aea9fd
refs/heads/master
2020-05-03T07:42:02.128702
2019-03-30T03:47:19
2019-03-30T03:47:19
178,505,506
0
0
null
null
null
null
UTF-8
Java
false
false
1,404
java
package com.google.android.gms.internal; import java.util.ArrayList; import java.util.WeakHashMap; public final class aa implements ac { private final Object li = new Object(); private WeakHashMap<dh, ab> lj = new WeakHashMap(); private ArrayList<ab> lk = new ArrayList(); /* renamed from: a */ public ab m1988a(ak akVar, dh dhVar) { ab abVar; synchronized (this.li) { if (m1990c(dhVar)) { abVar = (ab) this.lj.get(dhVar); } else { abVar = new ab(akVar, dhVar); abVar.m594a((ac) this); this.lj.put(dhVar, abVar); this.lk.add(abVar); } } return abVar; } /* renamed from: a */ public void mo1587a(ab abVar) { synchronized (this.li) { if (!abVar.at()) { this.lk.remove(abVar); } } } /* renamed from: c */ public boolean m1990c(dh dhVar) { boolean z; synchronized (this.li) { ab abVar = (ab) this.lj.get(dhVar); z = abVar != null && abVar.at(); } return z; } /* renamed from: d */ public void m1991d(dh dhVar) { synchronized (this.li) { ab abVar = (ab) this.lj.get(dhVar); if (abVar != null) { abVar.ar(); } } } }
[ "nhannguyenmath95@gmail.com" ]
nhannguyenmath95@gmail.com