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
ab34c42eb762bd243d88f0bea247d41b5fa624f8
ba9192f4aeb635d5c49d80878a04512bc3b645e9
/src/hasor-core/src/main/java/net/hasor/core/gift/aop/BeforeChainInvocation.java
a16044058f240494df26cfd57e9a19a5113ffc21
[ "Apache-2.0" ]
permissive
ivanDannels/hasor
789e9183a5878cfc002466c9738c9bd2741fd76a
3b9f4ae6355c6dad2ea8818750b3e04e90cc3e39
refs/heads/master
2020-04-15T10:10:22.453889
2013-09-14T10:02:01
2013-09-14T10:02:01
12,828,661
1
0
null
null
null
null
WINDOWS-1252
Java
false
false
2,558
java
/* * Copyright 2008-2009 the original ÕÔÓÀ´º(zyc@hasor.net). * * 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 net.hasor.core.gift.aop; import java.lang.reflect.AccessibleObject; import java.lang.reflect.Method; import java.util.ArrayList; import java.util.List; import net.hasor.core.AppContext; import org.aopalliance.intercept.MethodInterceptor; import org.aopalliance.intercept.MethodInvocation; /** * * @version : 2013-4-13 * @author ÕÔÓÀ´º (zyc@hasor.net) */ class BeforeChainInvocation implements MethodInvocation { private MethodInterceptor[] beforeInterceptor = null; private MethodInvocation invocation = null; private int index = -1; // public BeforeChainInvocation(AppContext appContext, List<Class<? extends MethodInterceptor>> interTypeList, MethodInvocation invocation) { List<MethodInterceptor> beforeList = new ArrayList<MethodInterceptor>(); for (Class<? extends MethodInterceptor> interType : interTypeList) { if (interType != null) beforeList.add(appContext.getInstance(interType)); } this.beforeInterceptor = beforeList.toArray(new MethodInterceptor[beforeList.size()]); this.invocation = invocation; } public Object invoke(MethodInvocation invocation) throws Throwable { index++; if (index < beforeInterceptor.length) { return beforeInterceptor[index].invoke(this); } else { return invocation.proceed(); } } //----------------------------------------------------------- public Object[] getArguments() { return invocation.getArguments(); } public Object proceed() throws Throwable { return this.invoke(this.invocation); } public Object getThis() { return invocation.getThis(); } public AccessibleObject getStaticPart() { return invocation.getStaticPart(); } public Method getMethod() { return invocation.getMethod(); } }
[ "zyc@byshell.org" ]
zyc@byshell.org
6f4e98aa50765e5f8e99a653266f623764221bc4
13ea5da0b7b8d4ba87d622a5f733dcf6b4c5f1e3
/crash-reproduction-ws/results/XWIKI-13942-1-12-Single_Objective_GGA-WeightedSum/org/xwiki/model/internal/reference/ExplicitStringEntityReferenceResolver_ESTest_scaffolding.java
2547ab3a510d5351aefc63e253c4dc0a72a9c001
[ "MIT", "CC-BY-4.0" ]
permissive
STAMP-project/Botsing-basic-block-coverage-application
6c1095c6be945adc0be2b63bbec44f0014972793
80ea9e7a740bf4b1f9d2d06fe3dcc72323b848da
refs/heads/master
2022-07-28T23:05:55.253779
2022-04-20T13:54:11
2022-04-20T13:54:11
285,771,370
0
0
null
null
null
null
UTF-8
Java
false
false
3,059
java
/** * Scaffolding file used to store all the setups needed to run * tests automatically generated by EvoSuite * Mon Mar 30 17:05:49 UTC 2020 */ package org.xwiki.model.internal.reference; import org.evosuite.runtime.annotation.EvoSuiteClassExclude; import org.junit.BeforeClass; import org.junit.Before; import org.junit.After; import static org.evosuite.shaded.org.mockito.Mockito.*; @EvoSuiteClassExclude public class ExplicitStringEntityReferenceResolver_ESTest_scaffolding { @org.junit.Rule public org.evosuite.runtime.vnet.NonFunctionalRequirementRule nfr = new org.evosuite.runtime.vnet.NonFunctionalRequirementRule(); private org.evosuite.runtime.thread.ThreadStopper threadStopper = new org.evosuite.runtime.thread.ThreadStopper (org.evosuite.runtime.thread.KillSwitchHandler.getInstance(), 3000); @BeforeClass public static void initEvoSuiteFramework() { org.evosuite.runtime.RuntimeSettings.className = "org.xwiki.model.internal.reference.ExplicitStringEntityReferenceResolver"; org.evosuite.runtime.GuiSupport.initialize(); org.evosuite.runtime.RuntimeSettings.maxNumberOfIterationsPerLoop = 10000; org.evosuite.runtime.RuntimeSettings.mockSystemIn = true; org.evosuite.runtime.Runtime.getInstance().resetRuntime(); try { initMocksToAvoidTimeoutsInTheTests(); } catch(ClassNotFoundException e) {} } @Before public void initTestCase(){ threadStopper.storeCurrentThreads(); threadStopper.startRecordingTime(); org.evosuite.runtime.GuiSupport.setHeadless(); org.evosuite.runtime.Runtime.getInstance().resetRuntime(); org.evosuite.runtime.agent.InstrumentingAgent.activate(); } @After public void doneWithTestCase(){ threadStopper.killAndJoinClientThreads(); org.evosuite.runtime.agent.InstrumentingAgent.deactivate(); org.evosuite.runtime.GuiSupport.restoreHeadlessMode(); } private static void initializeClasses() { org.evosuite.runtime.classhandling.ClassStateSupport.initializeClasses(ExplicitStringEntityReferenceResolver_ESTest_scaffolding.class.getClassLoader() , "org.xwiki.model.reference.EntityReferenceResolver", "org.xwiki.model.internal.reference.ExplicitStringEntityReferenceResolver", "org.xwiki.component.annotation.Role", "org.xwiki.component.phase.Initializable", "org.xwiki.stability.Unstable", "org.xwiki.component.annotation.Component", "org.xwiki.model.reference.EntityReference", "org.xwiki.model.internal.reference.SymbolScheme", "org.xwiki.model.internal.reference.AbstractEntityReferenceResolver", "org.xwiki.model.internal.reference.AbstractStringEntityReferenceResolver", "org.xwiki.model.EntityType", "org.xwiki.component.phase.InitializationException" ); } private static void initMocksToAvoidTimeoutsInTheTests() throws ClassNotFoundException { mock(Class.forName("org.xwiki.model.internal.reference.SymbolScheme", false, ExplicitStringEntityReferenceResolver_ESTest_scaffolding.class.getClassLoader())); } }
[ "pouria.derakhshanfar@gmail.com" ]
pouria.derakhshanfar@gmail.com
f6bd72fdcc282984620a2ee06576deab7b326fab
1658bea262f4e812082c7ed4b4fcb6ca50d1199d
/src/main/java/kstradeapija/CThostFtdcQryFrontStatusField.java
added28a3146d5e3805aeec321de7a57b58c4410
[]
no_license
kingstar007/kingstarJA
8d6ed04cedd47cf7fc8ba89d320ceaee06b882d2
d6fa94fcb7ad6634d7b3bfe65df65059a63f6da7
refs/heads/master
2020-12-28T17:24:57.597022
2013-09-11T02:50:30
2013-09-11T02:50:30
null
0
0
null
null
null
null
UTF-8
Java
false
false
1,309
java
package kstradeapija; import org.bridj.Pointer; import org.bridj.StructObject; import org.bridj.ann.Field; import org.bridj.ann.Library; /** * \ufffd\ufffd\u046f\u01f0\ufffd\ufffd\u05f4\u032c<br> * <i>native declaration : linuxapi/CTP/KSUserApiStructEx.h:2175</i><br> * This file was autogenerated by <a href="http://jnaerator.googlecode.com/">JNAerator</a>,<br> * a tool written by <a href="http://ochafik.com/">Olivier Chafik</a> that <a href="http://code.google.com/p/jnaerator/wiki/CreditsAndLicense">uses a few opensource projects.</a>.<br> * For help, please visit <a href="http://nativelibs4java.googlecode.com/">NativeLibs4Java</a> or <a href="http://bridj.googlecode.com/">BridJ</a> . */ @Library("kstradeapija") public class CThostFtdcQryFrontStatusField extends StructObject { /** * \u01f0\ufffd\u00f1\ufffd\ufffd<br> * C type : TThostFtdcFrontIDType */ @Field(0) public int FrontID() { return this.io.getIntField(this, 0); } /** * \u01f0\ufffd\u00f1\ufffd\ufffd<br> * C type : TThostFtdcFrontIDType */ @Field(0) public CThostFtdcQryFrontStatusField FrontID(int FrontID) { this.io.setIntField(this, 0, FrontID); return this; } public CThostFtdcQryFrontStatusField() { super(); } public CThostFtdcQryFrontStatusField(Pointer pointer) { super(pointer); } }
[ "trade@ubuntu.(none)" ]
trade@ubuntu.(none)
e514adfa4682eb54ba8268e04f7fa4c7e5440e97
4b0bf4787e89bcae7e4759bde6d7f3ab2c81f849
/aliyun-java-sdk-mindlive-biz/src/main/java/com/aliyuncs/mindlive_biz/model/v20210214/AuthorizeUserResponse.java
f98287d2414abeb8e3bf7b04e083810282d8e2dd
[ "Apache-2.0" ]
permissive
aliyun/aliyun-openapi-java-sdk
a263fa08e261f12d45586d1b3ad8a6609bba0e91
e19239808ad2298d32dda77db29a6d809e4f7add
refs/heads/master
2023-09-03T12:28:09.765286
2023-09-01T09:03:00
2023-09-01T09:03:00
39,555,898
1,542
1,317
NOASSERTION
2023-09-14T07:27:05
2015-07-23T08:41:13
Java
UTF-8
Java
false
false
1,855
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 com.aliyuncs.mindlive_biz.model.v20210214; import com.aliyuncs.AcsResponse; import com.aliyuncs.mindlive_biz.transform.v20210214.AuthorizeUserResponseUnmarshaller; import com.aliyuncs.transform.UnmarshallerContext; /** * @author auto create * @version */ public class AuthorizeUserResponse extends AcsResponse { private String errorMessage; private String requestId; private Boolean success; private String errorCode; public String getErrorMessage() { return this.errorMessage; } public void setErrorMessage(String errorMessage) { this.errorMessage = errorMessage; } public String getRequestId() { return this.requestId; } public void setRequestId(String requestId) { this.requestId = requestId; } public Boolean getSuccess() { return this.success; } public void setSuccess(Boolean success) { this.success = success; } public String getErrorCode() { return this.errorCode; } public void setErrorCode(String errorCode) { this.errorCode = errorCode; } @Override public AuthorizeUserResponse getInstance(UnmarshallerContext context) { return AuthorizeUserResponseUnmarshaller.unmarshall(this, context); } @Override public boolean checkShowJsonItemName() { return false; } }
[ "sdk-team@alibabacloud.com" ]
sdk-team@alibabacloud.com
7386342801db58e6342e1096c396b2f694a13fe6
3a568be34324d54a89c25b005e58f2313d3a8275
/hl7processor/src/main/java/com/founder/hl7/xml/StringValueHandler.java
922b734a9d0a7e29f22b97e07c04b3bc90448bf2
[]
no_license
neil-ms/szbj-code
9384e74481e5b4d9065a00c0becd5b73ea67ab01
92a8b8006b3198f2ed51daeb0f2c33e428a82edc
refs/heads/master
2020-12-11T03:46:35.455388
2016-09-19T07:22:07
2016-09-19T07:22:07
68,563,282
0
0
null
2016-09-19T02:50:32
2016-09-19T02:50:32
null
UTF-8
Java
false
false
659
java
package com.founder.hl7.xml; import java.lang.reflect.Field; import org.w3c.dom.Node; public class StringValueHandler implements ValueHandler { @Override public void getValue(Node node, Field field, Object obj) throws Exception { String value = node.getTextContent(); field.set(obj, value == null ? "" : value); } @Override public void updateValue(Node node, Field field, Object obj) throws Exception { Object value = field.get(obj); node.setTextContent(value == null ? "" : String.valueOf(value)); } public void setValue(Node node, Field field, Object obj) { } }
[ "149516374@qq.com" ]
149516374@qq.com
54b0f2252a431079c09d28c1ecf7978074b9bc10
793df459501d0113d6acdd41faf590122a242796
/confu-master/benchmarks/xalan/original_source_from_jdcore/org/apache/xerces/xni/parser/XMLComponent.java
e8de1e5fe51629cff56a23d0e0d5b96b6d74a316
[ "Apache-2.0" ]
permissive
tsmart-date/nasac-2017-demo
fc9c927eb6cc88e090066fc351b58c74a79d936e
07f2d3107f1b40984ffda9e054fa744becd8c8a3
refs/heads/master
2021-07-15T21:29:42.245245
2017-10-24T14:28:14
2017-10-24T14:28:14
105,340,725
0
1
null
null
null
null
UTF-8
Java
false
false
676
java
package org.apache.xerces.xni.parser; public abstract interface XMLComponent { public abstract void reset(XMLComponentManager paramXMLComponentManager) throws XMLConfigurationException; public abstract String[] getRecognizedFeatures(); public abstract void setFeature(String paramString, boolean paramBoolean) throws XMLConfigurationException; public abstract String[] getRecognizedProperties(); public abstract void setProperty(String paramString, Object paramObject) throws XMLConfigurationException; public abstract Boolean getFeatureDefault(String paramString); public abstract Object getPropertyDefault(String paramString); }
[ "liuhan0518@gmail.com" ]
liuhan0518@gmail.com
1edc2d54ac6438ec2c212bc40803cdc3890a7ceb
51a172696626ff4eecd69e24178db52212de1b7d
/mall/dao/src/main/java/com/dao/order/AfterSaleImageRepository.java
13540f6e1c1b2fa01d32dea7960fc70b1ccddc9c
[]
no_license
295647706/mall
eb2bf9d9c8efd326aa01fb5b7e7dd8ff7bb814e5
141643f92bc7edff8c5888ba18df6d4029233503
refs/heads/master
2020-05-16T18:35:31.123120
2019-04-24T13:20:29
2019-04-24T13:20:29
183,231,222
0
0
null
null
null
null
UTF-8
Java
false
false
277
java
package com.dao.order; import org.springframework.stereotype.Repository; import com.dao.BaseRepository; import com.model.order.AfterSaleImage; /** * * @Author Ruan * */ @Repository public interface AfterSaleImageRepository extends BaseRepository<AfterSaleImage> { }
[ "295647706@qq.com" ]
295647706@qq.com
aad5b09835dcaa16ae50148e60ff57c0542b8753
69a4f2d51ebeea36c4d8192e25cfb5f3f77bef5e
/methods/Method_10155.java
096b56ce34f68c81904cf05678d148bcfd2e83f4
[]
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
160
java
/** * Escapes the specified string. * @param str the specified string */ public static String escapeHTML(final String str){ return Encode.forHtml(str); }
[ "sonnguyen@utdallas.edu" ]
sonnguyen@utdallas.edu
26e3b13af7e110e81316648d9122a872e93b5042
703cefa4816cef1f18b823232e77a4911d45fa71
/src/main/java/com/laptrinhjavaweb/repositoty/impl/BuildingRepository.java
9030e94f3649ce33f7031965e905ef56c8790b01
[]
no_license
tranntuanduong/Insert-24-5
03e3f03e51aec1be2ff3202103f3f54addc3384b
6ba85438e36fdc490598f529c6b9337e7b07f430
refs/heads/master
2022-12-06T10:26:07.207142
2019-05-24T03:22:33
2019-05-24T03:22:33
188,345,309
0
0
null
2022-11-16T05:40:32
2019-05-24T03:20:11
Java
UTF-8
Java
false
false
534
java
package com.laptrinhjavaweb.repositoty.impl; import com.laptrinhjavaweb.entity.BuildingEntity; import com.laptrinhjavaweb.repository.IBuildingRepository; public class BuildingRepository extends AbstractJDBC<BuildingEntity> implements IBuildingRepository{ @Override public Long insert(BuildingEntity buildingEntity) { String sql = Query.queryInsert(buildingEntity.getClass()); Object[] parameters = (Object[]) RunGetter.runGetter(buildingEntity); System.out.println(sql); return this.insert(sql, parameters); } }
[ "=" ]
=
20ce6a15018fb4846c7b9562322992ec1359820c
95e944448000c08dd3d6915abb468767c9f29d3c
/sources/com/facebook/ads/DefaultMediaViewVideoRenderer.java
9f0084a5ada372b69c9be65464fdaa70521e4c84
[]
no_license
xrealm/tiktok-src
261b1faaf7b39d64bb7cb4106dc1a35963bd6868
90f305b5f981d39cfb313d75ab231326c9fca597
refs/heads/master
2022-11-12T06:43:07.401661
2020-07-04T20:21:12
2020-07-04T20:21:12
null
0
0
null
null
null
null
UTF-8
Java
false
false
1,482
java
package com.facebook.ads; import android.content.Context; import android.util.AttributeSet; import com.facebook.ads.internal.api.DefaultMediaViewVideoRendererApi; import com.facebook.ads.internal.dynamicloading.DynamicLoaderFactory; public final class DefaultMediaViewVideoRenderer extends MediaViewVideoRenderer { private DefaultMediaViewVideoRendererApi mDefaultMediaViewVideoRendererApi; public final void onPrepared() { super.onPrepared(); this.mDefaultMediaViewVideoRendererApi.onPrepared(); } public DefaultMediaViewVideoRenderer(Context context) { super(context); initializeSelf(context); } private void initializeSelf(Context context) { this.mDefaultMediaViewVideoRendererApi = DynamicLoaderFactory.makeLoader(context).createDefaultMediaViewVideoRendererApi(); this.mDefaultMediaViewVideoRendererApi.initialize(context, this, getMediaViewVideoRendererApi(), 0); } public DefaultMediaViewVideoRenderer(Context context, AttributeSet attributeSet) { super(context, attributeSet); initializeSelf(context); } public DefaultMediaViewVideoRenderer(Context context, AttributeSet attributeSet, int i) { super(context, attributeSet, i); initializeSelf(context); } public DefaultMediaViewVideoRenderer(Context context, AttributeSet attributeSet, int i, int i2) { super(context, attributeSet, i, i2); initializeSelf(context); } }
[ "65450641+Xyzdesk@users.noreply.github.com" ]
65450641+Xyzdesk@users.noreply.github.com
f607fdf21c5d4aa06c5ff5d9ee0ddfdc80c4f5ab
87f55dcd7b14db3912adfab68ed7b812493af76e
/src/main/java/headfirst/others/builder/ChickenBurger.java
49a79de07ff89ddd0efeb23b2f9ecc4632eeb68f
[]
no_license
1000-7/headfirst
1f5fc371da0c71e56629151e0bd17e40679a5109
09ec4d79687baec4fc7dcac9dbf1c2d34ffe371d
refs/heads/master
2020-03-27T04:57:29.346998
2018-09-08T13:24:42
2018-09-08T13:24:42
145,982,139
1
0
null
null
null
null
UTF-8
Java
false
false
231
java
package headfirst.others.builder; public class ChickenBurger extends Burger { @Override public float price() { return 50.5f; } @Override public String name() { return "Chicken Burger"; } }
[ "1256656057@qq.com" ]
1256656057@qq.com
56a14808aa7ea0e520c14f54030e619c2c7b8983
90f9d0d74e6da955a34a97b1c688e58df9f627d0
/com.ibm.ccl.soa.deploy.db2/src/com/ibm/ccl/soa/deploy/db2/validation/WindowsDB2ClientInstanceValidator.java
3bc755ae187529c4f810c51d93d41a9bfbc93305
[]
no_license
kalapriyakannan/UMLONT
0431451674d7b3eb744fb436fab3d13e972837a4
560d9f5d2ba6a800398a24fd8265e5a946179fd3
refs/heads/master
2020-03-30T03:16:44.327160
2018-09-28T03:28:11
2018-09-28T03:28:11
150,679,726
1
1
null
null
null
null
UTF-8
Java
false
false
1,205
java
/******************************************************************************* * Copyright (c) 2003, 2007 IBM Corporation Licensed Material - Property of IBM. All rights reserved. * * US Government Users Restricted Rights - Use, duplication or disclosure v1.0 restricted by GSA ADP * Schedule Contract with IBM Corp. * * Contributors: IBM Corporation - initial API and implementation *******************************************************************************/ package com.ibm.ccl.soa.deploy.db2.validation; import com.ibm.ccl.soa.deploy.db2.WindowsInstanceTypeType; /** * A sample validator interface for {@link com.ibm.ccl.soa.deploy.db2.WindowsDB2ClientInstance}. * This doesn't really do anything, and it's not a real EMF artifact. It was generated by the * org.eclipse.emf.examples.generator.validator plug-in to illustrate how EMF's code generator can * be extended. This can be disabled with -vmargs * -Dorg.eclipse.emf.examples.generator.validator=false. */ public interface WindowsDB2ClientInstanceValidator { boolean validate(); boolean validateDefaultInstance(boolean value); boolean validateInstanceType(WindowsInstanceTypeType value); }
[ "kalapriya.kannan@in.ibm.com" ]
kalapriya.kannan@in.ibm.com
a8501e435c00da96df7b42a6a3baf519f8d73b21
ecb347a820405fd7c7a7c77f7c7c5a1b3a82c1f2
/main/coreplugins/io.sarl.eclipse/src/io/sarl/eclipse/launching/dialog/SARLApplicationLaunchConfigurationTabGroup.java
757726f4f7d28a7d480f7f08c1291651211c426a
[ "Apache-2.0" ]
permissive
interventionlabs/sarl
6003c303382eb7b22a18bf131764f607488fc46f
e0ba1a47c93b2be01bcb5f5af7125a8d86dcd548
refs/heads/master
2020-07-10T18:09:32.442040
2019-08-22T15:59:54
2019-08-22T15:59:54
null
0
0
null
null
null
null
UTF-8
Java
false
false
1,837
java
/* * $Id$ * * SARL is an general-purpose agent programming language. * More details on http://www.sarl.io * * Copyright (C) 2014-2019 the original authors or authors. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package io.sarl.eclipse.launching.dialog; import org.eclipse.debug.ui.CommonTab; import org.eclipse.debug.ui.EnvironmentTab; import org.eclipse.debug.ui.ILaunchConfigurationDialog; import org.eclipse.debug.ui.ILaunchConfigurationTab; import org.eclipse.debug.ui.sourcelookup.SourceLookupTab; import org.eclipse.jdt.debug.ui.launchConfigurations.JavaArgumentsTab; /** * Tab group object for configuring the run of a Java application embedding SARL. * * @author $Author: sgalland$ * @version $FullVersion$ * @mavengroupid $GroupId$ * @mavenartifactid $ArtifactId$ * @since 0.7 */ public class SARLApplicationLaunchConfigurationTabGroup extends AbstractSARLLaunchConfigurationTabGroup { @Override public void createTabs(ILaunchConfigurationDialog dialog, String mode) { final ILaunchConfigurationTab[] tabs = new ILaunchConfigurationTab[] { new SARLApplicationMainLaunchConfigurationTab(), new JavaArgumentsTab(), new SARLRuntimeEnvironmentTab(false), getClasspathTab(dialog), new SourceLookupTab(), new EnvironmentTab(), new CommonTab(), }; setTabs(tabs); } }
[ "galland@arakhne.org" ]
galland@arakhne.org
8e374298c552105b624d98e540d4a6ad8c84c781
930c207e245c320b108e9699bbbb036260a36d6a
/BRICK-RDF4J/generatedCode/src/main/java/brickschema/org/schema/_1_0_2/Brick/IHeating_Command.java
20649504cf7195b8ee729106a8cbc3bbca31dfd2
[]
no_license
InnovationSE/BRICK-Generated-By-OLGA
24d278f543471e1ce622f5f45d9e305790181fff
7874dfa450a8a2b6a6f9927c0f91f9c7d2abd4d2
refs/heads/master
2021-07-01T14:13:11.302860
2017-09-21T12:44:17
2017-09-21T12:44:17
104,251,784
1
0
null
null
null
null
UTF-8
Java
false
false
406
java
/** * This file is automatically generated by OLGA * @author OLGA * @version 1.0 */ package brickschema.org.schema._1_0_2.Brick; import java.util.ArrayList; import java.util.List; import org.eclipse.rdf4j.model.IRI; import org.eclipse.rdf4j.model.vocabulary.RDF; import brickschema.org.schema._1_0_2.Brick.ICommand; public interface IHeating_Command extends ICommand { public IRI iri(); }
[ "Andre.Ponnouradjane@non.schneider-electric.com" ]
Andre.Ponnouradjane@non.schneider-electric.com
58735a1760361c23ad7299999467dbe1e02d6b6e
81b0bb3cfb2e9501f53451e7f03ec072ee2b0e13
/src/com/squareup/picasso/PicassoDrawable.java
d39996dc374729afd959415517acedb9549ffabb
[]
no_license
reverseengineeringer/me.lyft.android
48bb85e8693ce4dab50185424d2ec51debf5c243
8c26caeeb54ffbde0711d3ce8b187480d84968ef
refs/heads/master
2021-01-19T02:32:03.752176
2016-07-19T16:30:00
2016-07-19T16:30:00
63,710,356
3
0
null
null
null
null
UTF-8
Java
false
false
4,462
java
package com.squareup.picasso; import android.content.Context; import android.content.res.Resources; import android.graphics.Bitmap; import android.graphics.Canvas; import android.graphics.ColorFilter; import android.graphics.Paint; import android.graphics.Path; import android.graphics.Point; import android.graphics.Rect; import android.graphics.drawable.AnimationDrawable; import android.graphics.drawable.BitmapDrawable; import android.graphics.drawable.Drawable; import android.os.Build.VERSION; import android.os.SystemClock; import android.util.DisplayMetrics; import android.widget.ImageView; final class PicassoDrawable extends BitmapDrawable { private static final Paint DEBUG_PAINT = new Paint(); private static final float FADE_DURATION = 200.0F; int alpha = 255; boolean animating; private final boolean debugging; private final float density; private final Picasso.LoadedFrom loadedFrom; Drawable placeholder; long startTimeMillis; PicassoDrawable(Context paramContext, Bitmap paramBitmap, Drawable paramDrawable, Picasso.LoadedFrom paramLoadedFrom, boolean paramBoolean1, boolean paramBoolean2) { super(paramContext.getResources(), paramBitmap); debugging = paramBoolean2; density = getResourcesgetDisplayMetricsdensity; loadedFrom = paramLoadedFrom; if ((paramLoadedFrom != Picasso.LoadedFrom.MEMORY) && (!paramBoolean1)) {} for (int i = 1;; i = 0) { if (i != 0) { placeholder = paramDrawable; animating = true; startTimeMillis = SystemClock.uptimeMillis(); } return; } } private void drawDebugIndicator(Canvas paramCanvas) { DEBUG_PAINT.setColor(-1); paramCanvas.drawPath(getTrianglePath(new Point(0, 0), (int)(16.0F * density)), DEBUG_PAINT); DEBUG_PAINT.setColor(loadedFrom.debugColor); paramCanvas.drawPath(getTrianglePath(new Point(0, 0), (int)(15.0F * density)), DEBUG_PAINT); } private static Path getTrianglePath(Point paramPoint, int paramInt) { Point localPoint1 = new Point(x + paramInt, y); Point localPoint2 = new Point(x, y + paramInt); Path localPath = new Path(); localPath.moveTo(x, y); localPath.lineTo(x, y); localPath.lineTo(x, y); return localPath; } static void setBitmap(ImageView paramImageView, Context paramContext, Bitmap paramBitmap, Picasso.LoadedFrom paramLoadedFrom, boolean paramBoolean1, boolean paramBoolean2) { Drawable localDrawable = paramImageView.getDrawable(); if ((localDrawable instanceof AnimationDrawable)) { ((AnimationDrawable)localDrawable).stop(); } paramImageView.setImageDrawable(new PicassoDrawable(paramContext, paramBitmap, localDrawable, paramLoadedFrom, paramBoolean1, paramBoolean2)); } static void setPlaceholder(ImageView paramImageView, Drawable paramDrawable) { paramImageView.setImageDrawable(paramDrawable); if ((paramImageView.getDrawable() instanceof AnimationDrawable)) { ((AnimationDrawable)paramImageView.getDrawable()).start(); } } public void draw(Canvas paramCanvas) { if (!animating) { super.draw(paramCanvas); } for (;;) { if (debugging) { drawDebugIndicator(paramCanvas); } return; float f = (float)(SystemClock.uptimeMillis() - startTimeMillis) / 200.0F; if (f >= 1.0F) { animating = false; placeholder = null; super.draw(paramCanvas); } else { if (placeholder != null) { placeholder.draw(paramCanvas); } super.setAlpha((int)(alpha * f)); super.draw(paramCanvas); super.setAlpha(alpha); if (Build.VERSION.SDK_INT <= 10) { invalidateSelf(); } } } } protected void onBoundsChange(Rect paramRect) { if (placeholder != null) { placeholder.setBounds(paramRect); } super.onBoundsChange(paramRect); } public void setAlpha(int paramInt) { alpha = paramInt; if (placeholder != null) { placeholder.setAlpha(paramInt); } super.setAlpha(paramInt); } public void setColorFilter(ColorFilter paramColorFilter) { if (placeholder != null) { placeholder.setColorFilter(paramColorFilter); } super.setColorFilter(paramColorFilter); } } /* Location: * Qualified Name: com.squareup.picasso.PicassoDrawable * Java Class Version: 6 (50.0) * JD-Core Version: 0.7.1 */
[ "reverseengineeringer@hackeradmin.com" ]
reverseengineeringer@hackeradmin.com
8dffd6ea006619c6c2a1217287f451b590ebddb0
9edaab04d69efe838137c38f28cceaf65bcb2e51
/test/T8.java
fc83a3c3ad63ca6e3498ed7901b7aed5f4e19773
[]
no_license
qiang2010/LeetCode_jq
d28b921f4ff098dd8bd2cc71e51c5e1449c26c6b
2e46668c0c1877a66683ff75a110575f4662c82f
refs/heads/master
2020-12-24T06:31:31.384823
2016-07-21T06:06:45
2016-07-21T06:06:45
39,242,942
0
0
null
null
null
null
UTF-8
Java
false
false
525
java
package qiang.test; import java.util.LinkedList; public class T8 { public static void main(String[] args) { String str = "abc"; System.out.println("sub:"+str.substring(0,0)); System.out.println("sub:"+str.substring(0,1)); System.out.println("sub:"+str.substring(0,2)); System.out.println("sub:"+str.substring(0,3)); System.out.println("sub:"+str.substring(1)); LinkedList<Integer> ass = new LinkedList<>(); ass.toArray(); System.out.println( 3 + (4>>1)); System.out.println( 3<<2|1); } }
[ "qiangji1991@gmail.com" ]
qiangji1991@gmail.com
b862444add45d8dfdba2ce733614192302339194
d23ecc01fa86b70e6fb4405d86b1e52a16fda976
/src/ConditionalStatementsAndLoops/MegaPixels.java
19f25fc4834fb91bb1067f02cc2ea289ea1438f2
[ "MIT" ]
permissive
VladimirMetodiev/JavaFundamentals
09df800430ab06e59b8823b845359f64a26d44ec
5061bd45d42c0465421a2ae5faf382f012d5e627
refs/heads/main
2023-03-05T22:24:11.820375
2021-02-19T09:25:08
2021-02-19T09:25:08
340,016,711
0
0
null
null
null
null
UTF-8
Java
false
false
401
java
package ConditionalStatementsAndLoops; import java.util.Scanner; public class MegaPixels { public static void main(String[] args) { Scanner input = new Scanner(System.in); int width = Integer.parseInt(input.nextLine()); int height = Integer.parseInt(input.nextLine()); double mPic = width * height / 1000000d; System.out.printf("%.1fMP", mPic); } }
[ "iarilomail@gmail.com" ]
iarilomail@gmail.com
8b178e34c6ae91162ad9c302bbc5bfc323cd4bdc
832c1e4157f70c59e41d91a97a8475224abb4e40
/src/main/java/ni/org/ics/estudios/cohorte/muestreoanual/service/VacunaService.java
e4ce20f8c06f7cbb4f8a910b4d3b87abd9f37d78
[]
no_license
wmonterrey/muestreo-anual
3acf4eaf12796d025c239fe531285b420e557284
ab67d6da5c87e82f9d323785d264185fba47119a
refs/heads/master
2020-04-17T11:24:53.057087
2017-07-30T19:59:52
2017-07-30T19:59:52
67,811,859
0
1
null
null
null
null
UTF-8
Java
false
false
2,612
java
package ni.org.ics.estudios.cohorte.muestreoanual.service; import java.sql.Timestamp; import java.util.List; import javax.annotation.Resource; import ni.org.ics.estudios.cohorte.muestreoanual.domain.Vacuna; import ni.org.ics.estudios.cohorte.muestreoanual.domain.VacunaId; import org.hibernate.Query; import org.hibernate.Session; import org.hibernate.SessionFactory; import org.springframework.stereotype.Service; import org.springframework.transaction.annotation.Transactional; /** * Servicio para el objeto Vacuna * * @author Brenda Lopez * **/ @Service("vacunaService") @Transactional public class VacunaService { @Resource(name="sessionFactory") private SessionFactory sessionFactory; /** * Regresa todos las Vacunas * * @return una lista de <code>Vacuna</code>(s) */ @SuppressWarnings("unchecked") public List<Vacuna> getVacunas() { // Retrieve session from Hibernate Session session = sessionFactory.getCurrentSession(); // Create a Hibernate query (HQL) Query query = session.createQuery("FROM Vacuna"); // Retrieve all return query.list(); } /** * Regresa una Vacuna * * @return un <code>Vacuna</code> */ public Vacuna getVacuna(VacunaId vacId) { // Retrieve session from Hibernate Session session = sessionFactory.getCurrentSession(); Timestamp timeStamp = new Timestamp(vacId.getFechaVacuna().getTime()); Query query = session.createQuery("FROM Vacuna vac where " + "vac.vacunaId.codigo = " + vacId.getCodigo() + " AND vac.vacunaId.fechaVacuna = :fechaV"); query.setTimestamp("fechaV", timeStamp); Vacuna vacuna = (Vacuna) query.uniqueResult(); return vacuna; } /** * Verifica una Vacuna * * @return true or false */ public Boolean checkVacuna(VacunaId vacId) { // Retrieve session from Hibernate Session session = sessionFactory.getCurrentSession(); Timestamp timeStamp = new Timestamp(vacId.getFechaVacuna().getTime()); Query query = session.createQuery("FROM Vacuna vac where " + "vac.vacunaId.codigo = " + vacId.getCodigo() + " AND vac.vacunaId.fechaVacuna = :fechaV"); query.setTimestamp("fechaV", timeStamp); Vacuna vacuna = (Vacuna) query.uniqueResult(); if(vacuna!=null){ return true; } else{ return false; } } /** * Agrega un Vacuna * * */ public void addVacuna(Vacuna vacuna) { Session session = sessionFactory.getCurrentSession(); session.save(vacuna); } /** * Actualiza un Vacuna * * */ public void updateVacuna(Vacuna vacuna) { Session session = sessionFactory.getCurrentSession(); session.update(vacuna); } }
[ "waviles@icsnicaragua.org" ]
waviles@icsnicaragua.org
68f05d7d363609fea56fb4127a451926a9d090a0
4c2e83907706317c147433e4560a49d431badf1b
/app/src/main/java/com/google/android/gms/common/internal/zza.java
5479c61e3daec46e4db91d6171278391b8b8b00e
[ "Unlicense" ]
permissive
renyuanceshi/KingKingRE
92c80328556853029eb5b7bbf3a48a19182cf056
b15295bec2cee47867b786dbe0841c1a4edaff5e
refs/heads/master
2020-12-13T14:41:26.365794
2020-01-17T04:27:21
2020-01-17T04:27:21
234,442,774
0
0
null
null
null
null
UTF-8
Java
false
false
1,425
java
package com.google.android.gms.common.internal; import android.accounts.Account; import android.content.Context; import android.os.Binder; import android.os.RemoteException; import android.util.Log; import com.google.android.gms.common.zzo; public final class zza extends zzam { private int zzaGG; public static Account zza(zzal zzal) { Account account = null; if (zzal != null) { long clearCallingIdentity = Binder.clearCallingIdentity(); try { account = zzal.getAccount(); } catch (RemoteException e) { Log.w("AccountAccessor", "Remote account accessor probably died"); } finally { Binder.restoreCallingIdentity(clearCallingIdentity); } } return account; } public final boolean equals(Object obj) { if (this == obj) { return true; } if (!(obj instanceof zza)) { return false; } throw new NullPointerException(); } public final Account getAccount() { int callingUid = Binder.getCallingUid(); if (callingUid != this.zzaGG) { if (zzo.zzf((Context) null, callingUid)) { this.zzaGG = callingUid; } else { throw new SecurityException("Caller is not GooglePlayServices"); } } return null; } }
[ "lewis@spectratech.com" ]
lewis@spectratech.com
fcd69b263cfadba9d43c937f7dadc0cb477bc18b
b111b77f2729c030ce78096ea2273691b9b63749
/db-example-large-multi-project/project82/src/main/java/org/gradle/test/performance/mediumjavamultiproject/project82/p411/Production8229.java
7c4d198060e483ed42508c59c07288aa1067fd87
[]
no_license
WeilerWebServices/Gradle
a1a55bdb0dd39240787adf9241289e52f593ccc1
6ab6192439f891256a10d9b60f3073cab110b2be
refs/heads/master
2023-01-19T16:48:09.415529
2020-11-28T13:28:40
2020-11-28T13:28:40
256,249,773
1
0
null
null
null
null
UTF-8
Java
false
false
1,968
java
package org.gradle.test.performance.mediumjavamultiproject.project82.p411; public class Production8229 { private Production8226 property0; public Production8226 getProperty0() { return property0; } public void setProperty0(Production8226 value) { property0 = value; } private Production8227 property1; public Production8227 getProperty1() { return property1; } public void setProperty1(Production8227 value) { property1 = value; } private Production8228 property2; public Production8228 getProperty2() { return property2; } public void setProperty2(Production8228 value) { property2 = value; } private String property3; public String getProperty3() { return property3; } public void setProperty3(String value) { property3 = value; } private String property4; public String getProperty4() { return property4; } public void setProperty4(String value) { property4 = value; } private String property5; public String getProperty5() { return property5; } public void setProperty5(String value) { property5 = value; } private String property6; public String getProperty6() { return property6; } public void setProperty6(String value) { property6 = value; } private String property7; public String getProperty7() { return property7; } public void setProperty7(String value) { property7 = value; } private String property8; public String getProperty8() { return property8; } public void setProperty8(String value) { property8 = value; } private String property9; public String getProperty9() { return property9; } public void setProperty9(String value) { property9 = value; } }
[ "nateweiler84@gmail.com" ]
nateweiler84@gmail.com
88062de2f024d8381552ce0c336cc999be0c5991
1b6ecad3272337928f5819bfc8683eeee1f19d89
/branches/findbugs/system-tests/src/test/java/org/terracotta/ehcache/tests/container/hibernate/nontransactional/EmptySecondLevelCacheEntryServlet.java
14510e8e8acb93f9464a8308d44c74227d9904d6
[]
no_license
MatthewRBruce/ehcache
77540643da5ca20b6fd5638221f4410a1baefe02
4365fc6cc87516344e95688c368d6a3d2cebbe5a
refs/heads/master
2020-12-27T18:55:00.785157
2015-01-21T07:11:38
2015-01-21T07:11:38
null
0
0
null
null
null
null
UTF-8
Java
false
false
2,880
java
/* * All content copyright Terracotta, Inc., unless otherwise indicated. All rights reserved. */ package org.terracotta.ehcache.tests.container.hibernate.nontransactional; import org.hibernate.Session; import org.hibernate.Transaction; import org.hibernate.stat.SecondLevelCacheStatistics; import org.hibernate.stat.Statistics; import org.junit.Assert; import org.terracotta.ehcache.tests.container.hibernate.BaseClusteredRegionFactoryTestServlet; import org.terracotta.ehcache.tests.container.hibernate.domain.Item; import java.util.Map; import java.util.concurrent.Callable; import javax.servlet.http.HttpSession; public class EmptySecondLevelCacheEntryServlet extends BaseClusteredRegionFactoryTestServlet { @Override protected void doServer0(HttpSession session, Map<String, String[]> parameters) throws Exception { HibernateUtil.dropAndCreateDatabaseSchema(); Session s = HibernateUtil.getSessionFactory().openSession(); Transaction t = s.beginTransaction(); Item i = new Item(); i.setName("widget"); i.setDescription("A really top-quality, full-featured widget."); s.persist(i); t.commit(); s.close(); Statistics stats = HibernateUtil.getSessionFactory().getStatistics(); final SecondLevelCacheStatistics statistics = stats.getSecondLevelCacheStatistics(Item.class.getName()); Assert.assertEquals(1, statistics.getElementCountOnDisk()); boolean foundInMemory = waitUntilTrue(new Callable<Boolean>() { public Boolean call() throws Exception { long elementCountInMemory = statistics.getElementCountInMemory(); System.out.println("Checking stats, elementCountInMemory: " + elementCountInMemory); return elementCountInMemory == 1; } }); Assert.assertEquals(true, foundInMemory); } private boolean waitUntilTrue(final Callable<Boolean> callable) throws Exception { for (int i = 0; i < 120; i++) { // wait up to two minutes, which is a long time, but far less than the overal test // time-out Boolean rv = callable.call(); System.out.println("Waiting until callable returns true, returned: " + rv); if (rv == true) { return true; } Thread.sleep(1000); } return false; } @Override protected void doServer1(HttpSession session, Map<String, String[]> parameters) throws Exception { Statistics stats = HibernateUtil.getSessionFactory().getStatistics(); SecondLevelCacheStatistics cacheStats = stats.getSecondLevelCacheStatistics(Item.class.getName()); long size = cacheStats.getElementCountInMemory() + cacheStats.getElementCountOnDisk(); Assert.assertEquals(1L, size); HibernateUtil.getSessionFactory().evictEntity(Item.class.getName()); size = cacheStats.getElementCountInMemory() + cacheStats.getElementCountOnDisk(); Assert.assertEquals(0L, size); } }
[ "hhuynh@b9324663-ca0f-0410-8574-be9b3887307d" ]
hhuynh@b9324663-ca0f-0410-8574-be9b3887307d
878faf0866d1f5e013be24ff4faa931a1cfb4b73
445c3cf84dd4bbcbbccf787b2d3c9eb8ed805602
/aliyun-java-sdk-ecsops/src/main/java/com/aliyuncs/ecsops/model/v20160401/OpsDeleteMigrationPreferenceResponse.java
0d9802714631e0b0d721082e0576dba331e41b65
[ "Apache-2.0" ]
permissive
caojiele/aliyun-openapi-java-sdk
b6367cc95469ac32249c3d9c119474bf76fe6db2
ecc1c949681276b3eed2500ec230637b039771b8
refs/heads/master
2023-06-02T02:30:02.232397
2021-06-18T04:08:36
2021-06-18T04:08:36
172,076,930
0
0
NOASSERTION
2019-02-22T14:08:29
2019-02-22T14:08:29
null
UTF-8
Java
false
false
1,278
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 com.aliyuncs.ecsops.model.v20160401; import com.aliyuncs.AcsResponse; import com.aliyuncs.ecsops.transform.v20160401.OpsDeleteMigrationPreferenceResponseUnmarshaller; import com.aliyuncs.transform.UnmarshallerContext; /** * @author auto create * @version */ public class OpsDeleteMigrationPreferenceResponse extends AcsResponse { private String requestId; public String getRequestId() { return this.requestId; } public void setRequestId(String requestId) { this.requestId = requestId; } @Override public OpsDeleteMigrationPreferenceResponse getInstance(UnmarshallerContext context) { return OpsDeleteMigrationPreferenceResponseUnmarshaller.unmarshall(this, context); } }
[ "sdk-team@alibabacloud.com" ]
sdk-team@alibabacloud.com
391a1a9864da91f3cbf325e45ae79d598eb3cc07
24fae99a278e8022b3944908a4db05b3d3148551
/sources/com/google/android/gms/internal/firebase_database/zzit.java
471d6648d9b2716ddbdc84f4db20ffacfbc165fc
[]
no_license
bigmanstan/FurniAR-college-Minor-project
53cad4bc90d65aadcb76613ba386306672cfd011
3ceba7e1fcaf5e847e3a72dd92712c308d484189
refs/heads/master
2020-05-26T03:04:18.538119
2019-05-26T12:33:47
2019-05-26T12:33:47
188,084,904
3
0
null
null
null
null
UTF-8
Java
false
false
4,134
java
package com.google.android.gms.internal.firebase_database; import com.google.firebase.database.collection.ImmutableSortedSet; import java.util.ArrayList; import java.util.Collections; import java.util.Iterator; import java.util.List; public final class zzit implements Iterable<zziz> { private static final ImmutableSortedSet<zziz> zzrw = new ImmutableSortedSet(Collections.emptyList(), null); private final zzis zzpd; private final zzja zzrx; private ImmutableSortedSet<zziz> zzry; private zzit(zzja zzja, zzis zzis) { this.zzpd = zzis; this.zzrx = zzja; this.zzry = null; } private zzit(zzja zzja, zzis zzis, ImmutableSortedSet<zziz> immutableSortedSet) { this.zzpd = zzis; this.zzrx = zzja; this.zzry = immutableSortedSet; } public static zzit zza(zzja zzja, zzis zzis) { return new zzit(zzja, zzis); } private final void zzfy() { if (this.zzry == null) { if (!this.zzpd.equals(zziu.zzgb())) { List arrayList = new ArrayList(); Object obj = null; for (zziz zziz : this.zzrx) { if (obj == null) { if (!this.zzpd.zzi(zziz.zzd())) { obj = null; arrayList.add(new zziz(zziz.zzge(), zziz.zzd())); } } obj = 1; arrayList.add(new zziz(zziz.zzge(), zziz.zzd())); } if (obj != null) { this.zzry = new ImmutableSortedSet(arrayList, this.zzpd); return; } } this.zzry = zzrw; } } public static zzit zzj(zzja zzja) { return new zzit(zzja, zzjf.zzgf()); } public final Iterator<zziz> iterator() { zzfy(); return this.zzry == zzrw ? this.zzrx.iterator() : this.zzry.iterator(); } public final Iterator<zziz> reverseIterator() { zzfy(); return this.zzry == zzrw ? this.zzrx.reverseIterator() : this.zzry.reverseIterator(); } public final zzid zza(zzid zzid, zzja zzja, zzis zzis) { if (!this.zzpd.equals(zziu.zzgb())) { if (!this.zzpd.equals(zzis)) { throw new IllegalArgumentException("Index not available in IndexedNode!"); } } zzfy(); if (this.zzry == zzrw) { return this.zzrx.zzl(zzid); } zziz zziz = (zziz) this.zzry.getPredecessorEntry(new zziz(zzid, zzja)); return zziz != null ? zziz.zzge() : null; } public final zzja zzd() { return this.zzrx; } public final zziz zzfz() { if (!(this.zzrx instanceof zzif)) { return null; } zzfy(); if (this.zzry != zzrw) { return (zziz) this.zzry.getMinEntry(); } zzid zzfm = ((zzif) this.zzrx).zzfm(); return new zziz(zzfm, this.zzrx.zzm(zzfm)); } public final zzit zzg(zzid zzid, zzja zzja) { zzja zze = this.zzrx.zze(zzid, zzja); if (this.zzry == zzrw && !this.zzpd.zzi(zzja)) { return new zzit(zze, this.zzpd, zzrw); } if (this.zzry != null) { if (this.zzry != zzrw) { ImmutableSortedSet remove = this.zzry.remove(new zziz(zzid, this.zzrx.zzm(zzid))); if (!zzja.isEmpty()) { remove = remove.insert(new zziz(zzid, zzja)); } return new zzit(zze, this.zzpd, remove); } } return new zzit(zze, this.zzpd, null); } public final zziz zzga() { if (!(this.zzrx instanceof zzif)) { return null; } zzfy(); if (this.zzry != zzrw) { return (zziz) this.zzry.getMaxEntry(); } zzid zzfn = ((zzif) this.zzrx).zzfn(); return new zziz(zzfn, this.zzrx.zzm(zzfn)); } public final zzit zzk(zzja zzja) { return new zzit(this.zzrx.zzf(zzja), this.zzpd, this.zzry); } }
[ "theonlyrealemailid@gmail.com" ]
theonlyrealemailid@gmail.com
dac408ae52af328d4d3febb9bbbe04e065120d70
0b1804971806ad54bc88bd6832b2f71a58c57bba
/Qualifier-Dependency-Injection/src/main/java/com/springinaction/annotation/Creamy.java
ab493b719853b37b80fbb72b38b37a7196c36b10
[]
no_license
david2999999/Spring-In-Action
706a3f48ff32df562776df06f945dd2d5f3c1329
4a6ec16f31aafeeb91a8825ad1ac1c10ad65f913
refs/heads/master
2021-04-15T04:11:47.437223
2018-04-07T03:28:31
2018-04-07T03:28:31
126,224,453
1
0
null
null
null
null
UTF-8
Java
false
false
450
java
package com.springinaction.annotation; import java.lang.annotation.ElementType; import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; import java.lang.annotation.Target; import org.springframework.beans.factory.annotation.Qualifier; @Target({ElementType.CONSTRUCTOR, ElementType.FIELD, ElementType.METHOD, ElementType.TYPE}) @Retention(RetentionPolicy.RUNTIME) @Qualifier public @interface Creamy { }
[ "djiang86@binghamton.edu" ]
djiang86@binghamton.edu
47f50d227dab293b7398f5600e5665d3c1091db2
a10d6cc2980298b087e210f914e61b92bab3f67e
/src/main.java
1669aa955ac17e96d3d9fb91fe4eebe275ca6e21
[]
no_license
Seraphim-lyx/Leetcode
98607462fb7ca1cccf6e12a3a8c79eb06418a500
8aa641f22d2742bf2f69c0c59fff8b182a566eba
refs/heads/master
2020-03-29T04:10:38.585355
2018-09-19T22:30:51
2018-09-19T22:30:51
149,519,380
0
0
null
null
null
null
UTF-8
Java
false
false
241
java
import java.util.ArrayList; import java.util.HashMap; import java.util.List; import java.util.Map; public class main { public static void main(String[] args) { // TODO Auto-generated constructor stub int[] nums1 = new int[3]; } }
[ "563150079@qq.com" ]
563150079@qq.com
8705a60fe4ef1c7ed75195561cf02ecaeb9d3675
84125a032c2b2e150f62616c15f0089016aca05d
/src/com/leet/algo/Prob518.java
8d71d1a7c4049ae007a27071d151478144399f16
[]
no_license
achowdhury80/leetcode
c577acc1bc8bce3da0c99e12d6d447c74fbed5c3
5ec97794cc5617cd7f35bafb058ada502ee7d802
refs/heads/master
2023-02-06T01:08:49.888440
2023-01-22T03:23:37
2023-01-22T03:23:37
115,574,715
1
0
null
null
null
null
UTF-8
Java
false
false
509
java
package com.leet.algo; import java.util.*; public class Prob518 { public int change(int amount, int[] coins) { int[] dp = new int[amount + 1]; dp[0] = 1; for (int i = 0; i < coins.length; i++) { for (int j = 0; j <= amount; j++) { if (j >= coins[i]) dp[j] += dp[j - coins[i]]; } } return dp[amount]; } public static void main(String[] args) { Prob518 prob = new Prob518(); System.out.println(prob.change(5, new int[] {1, 2, 5})); } }
[ "aychowdh@microsoft.com" ]
aychowdh@microsoft.com
035a03c2390273778b7f67d1a10914e3da67f551
83110fbb179713c411ddf301c90ef4b814285846
/src/ComputeDiskPartitionInfoForResizeRequestType.java
30af11d86e7ca746fa5a75013d5cf9f5e962b9db
[]
no_license
mikelopez/jvm
f10590edf42b498f2d81dec71b0fee120e381c9a
36a960897062224eabd0c18a1434f7c8961ee81c
refs/heads/master
2021-01-19T05:36:54.710665
2013-06-09T04:36:41
2013-06-09T04:36:41
3,783,647
2
0
null
null
null
null
UTF-8
Java
false
false
3,865
java
package com.vmware.vim25; 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 ComputeDiskPartitionInfoForResizeRequestType complex type. * * <p>The following schema fragment specifies the expected content contained within this class. * * <pre> * &lt;complexType name="ComputeDiskPartitionInfoForResizeRequestType"> * &lt;complexContent> * &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"> * &lt;sequence> * &lt;element name="_this" type="{urn:vim25}ManagedObjectReference"/> * &lt;element name="partition" type="{urn:vim25}HostScsiDiskPartition"/> * &lt;element name="blockRange" type="{urn:vim25}HostDiskPartitionBlockRange"/> * &lt;element name="partitionFormat" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/> * &lt;/sequence> * &lt;/restriction> * &lt;/complexContent> * &lt;/complexType> * </pre> * * */ @XmlAccessorType(XmlAccessType.FIELD) @XmlType(name = "ComputeDiskPartitionInfoForResizeRequestType", propOrder = { "_this", "partition", "blockRange", "partitionFormat" }) public class ComputeDiskPartitionInfoForResizeRequestType { @XmlElement(required = true) protected ManagedObjectReference _this; @XmlElement(required = true) protected HostScsiDiskPartition partition; @XmlElement(required = true) protected HostDiskPartitionBlockRange blockRange; protected String partitionFormat; /** * Gets the value of the this property. * * @return * possible object is * {@link ManagedObjectReference } * */ public ManagedObjectReference getThis() { return _this; } /** * Sets the value of the this property. * * @param value * allowed object is * {@link ManagedObjectReference } * */ public void setThis(ManagedObjectReference value) { this._this = value; } /** * Gets the value of the partition property. * * @return * possible object is * {@link HostScsiDiskPartition } * */ public HostScsiDiskPartition getPartition() { return partition; } /** * Sets the value of the partition property. * * @param value * allowed object is * {@link HostScsiDiskPartition } * */ public void setPartition(HostScsiDiskPartition value) { this.partition = value; } /** * Gets the value of the blockRange property. * * @return * possible object is * {@link HostDiskPartitionBlockRange } * */ public HostDiskPartitionBlockRange getBlockRange() { return blockRange; } /** * Sets the value of the blockRange property. * * @param value * allowed object is * {@link HostDiskPartitionBlockRange } * */ public void setBlockRange(HostDiskPartitionBlockRange value) { this.blockRange = value; } /** * Gets the value of the partitionFormat property. * * @return * possible object is * {@link String } * */ public String getPartitionFormat() { return partitionFormat; } /** * Sets the value of the partitionFormat property. * * @param value * allowed object is * {@link String } * */ public void setPartitionFormat(String value) { this.partitionFormat = value; } }
[ "dev@scidentify.info" ]
dev@scidentify.info
34d26bcf849030e8a5a785e6ba8a0ca836777121
7dc8e2e08c9eb25e4ef41568a561b503437b11f6
/src/main/java/cn/minalz/adapter/loginadapter/LoginForThirdAdapter.java
2dacfa77d29cfb19f65af09e839df3106502a4d8
[]
no_license
minalz/design-pattern
249f787d0af3866d189cfae8af8cf63d1b5ac529
43f7599f5a88c2636fd8a93cf8eb074b286424ac
refs/heads/master
2023-04-15T21:07:00.270968
2021-04-18T16:36:48
2021-04-18T16:36:48
350,778,652
0
0
null
null
null
null
UTF-8
Java
false
false
922
java
package cn.minalz.adapter.loginadapter; /** * @description: * @author: minalz * @date: 2021-04-18 12:23 **/ public class LoginForThirdAdapter extends LoginService implements ILoginForThird { @Override public ResultMsg loginForQQ(String opid) { return loginForRegist(opid, null); } @Override public ResultMsg loginForWechat(String opid) { return loginForRegist(opid, null); } @Override public ResultMsg loginForToken(String token) { return loginForRegist(token, null); } @Override public ResultMsg loginForTelphone(String phone, String code) { return loginForRegist(phone, null); } private ResultMsg loginForRegist(String username, String password) { if (null == password) { password = "THIRD_EMPTY"; } super.regist(username, password); return super.login(username, password); } }
[ "119687281@qq.com" ]
119687281@qq.com
68a7be8b60be2f1c3118f75dfcc660fd32ebcdfc
06b84a787aaf6080c9c64152eca6ac5314d3247f
/workcraft/DfsPlugin/src/org/workcraft/plugins/dfs/commands/InsertCounterflowLogicTransformationCommand.java
9258f0f4a26b33b58c554e751645345def2a7f2e
[ "MIT" ]
permissive
workcraft/workcraft
d2b2aeb90013c3c862d8f2ad502767d70429f5c9
19a18bd2b2fd0eb26481321bd9d4b551f50df77e
refs/heads/master
2023-08-31T01:49:46.457080
2023-08-24T18:39:07
2023-08-24T18:39:07
51,246,530
44
270
MIT
2023-09-07T08:26:52
2016-02-07T12:18:49
Java
UTF-8
Java
false
false
402
java
package org.workcraft.plugins.dfs.commands; import org.workcraft.plugins.dfs.CounterflowLogic; public class InsertCounterflowLogicTransformationCommand extends AbstractInsertTransformationCommand { @Override public String getTypeName() { return "counterflow logic"; } @Override public CounterflowLogic createComponent() { return new CounterflowLogic(); } }
[ "danilovesky@gmail.com" ]
danilovesky@gmail.com
76a8cf0d37073da108a2d49eec3dd866bb042a74
94d0ae644f53f76dabf71d6c29e2b5dfe7698a11
/luban-coupons/src/main/java/com/luban/domain/SmsCouponHistoryDetail.java
99b9811eb891ec7ed70df4070faacd7c5ef2616f
[]
no_license
Amselx/mall-dcs
c71576c87285c663b08e62647d08c974e3fb6598
3a06d9f4a12dcf736112b38b69d523d3746af1b5
refs/heads/master
2023-05-03T01:54:26.068740
2021-05-14T01:28:39
2021-05-14T01:28:39
367,217,183
0
0
null
null
null
null
UTF-8
Java
false
false
1,340
java
package com.luban.domain; import com.luban.model.SmsCoupon; import com.luban.model.SmsCouponHistory; import com.luban.model.SmsCouponProductCategoryRelation; import com.luban.model.SmsCouponProductRelation; import java.util.List; /** * 优惠券领取历史详情封装 * Created by macro on 2018/8/29. */ public class SmsCouponHistoryDetail extends SmsCouponHistory { //相关优惠券信息 private SmsCoupon coupon; //优惠券关联商品 private List<SmsCouponProductRelation> productRelationList; //优惠券关联商品分类 private List<SmsCouponProductCategoryRelation> categoryRelationList; public SmsCoupon getCoupon() { return coupon; } public void setCoupon(SmsCoupon coupon) { this.coupon = coupon; } public List<SmsCouponProductRelation> getProductRelationList() { return productRelationList; } public void setProductRelationList(List<SmsCouponProductRelation> productRelationList) { this.productRelationList = productRelationList; } public List<SmsCouponProductCategoryRelation> getCategoryRelationList() { return categoryRelationList; } public void setCategoryRelationList(List<SmsCouponProductCategoryRelation> categoryRelationList) { this.categoryRelationList = categoryRelationList; } }
[ "123" ]
123
2686171c62c1d4437b2b0a37758da5c71ade0b16
8b57aee022a2c3509fe302a52accbb472005da50
/src/main/java/com/qian/demo/common/ResultCode.java
1b0878649f65fcc8e88915e2681c8a0ebdbb1d6c
[]
no_license
Me-to/qian_guanli
b0115c1d8c77ec4a6146262448dd72692f4ced2e
b0cb9aace76093b24d3fce2df7a8818bbbbe880b
refs/heads/main
2023-01-03T01:55:08.287866
2020-10-09T15:08:25
2020-10-09T15:08:25
302,643,660
1
0
null
null
null
null
UTF-8
Java
false
false
584
java
package com.qian.demo.common; public enum ResultCode implements IErrorCode { SUCCESS(200, "操作成功"), FAILED(500, "操作失败"), VALIDATE_FAILED(404, "参数检验失败"), UNAUTHORIZED(401, "暂未登录或token已经过期"), FORBIDDEN(403, "没有相关权限"); private long code; private String message; private ResultCode(long code, String message) { this.code = code; this.message = message; } public long getCode() { return code; } public String getMessage() { return message; } }
[ "694656210@qq.com" ]
694656210@qq.com
f3bb7e213de015fe745010de20649c2ef85d25eb
15e40f8ce43fcf999378da5047365cc84a3c6bb5
/src/main/java/com/zssi/framework/app/sjbb/service/CbtjService.java
eb2c36b5ab1c5a2438be4da0488dbf52959a0993
[]
no_license
itxiaojian/myfirstgit
e7a758c5df85238b95ac8432aa6eb79c170bd2bd
050b1ae8be8b6289ad6d49b62ebea09b54ee45f9
refs/heads/master
2021-01-19T16:08:55.757067
2017-04-14T15:05:04
2017-04-14T15:05:04
88,250,609
0
0
null
null
null
null
UTF-8
Java
false
false
3,949
java
package com.zssi.framework.app.sjbb.service; import java.util.ArrayList; import java.util.List; import java.util.Map; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.security.authentication.encoding.Md5PasswordEncoder; import org.springframework.stereotype.Service; import org.springframework.transaction.annotation.Transactional; import com.likegene.framework.core.BaseBO; import com.zssi.framework.app.cbgl.dao.YcwCbxxDao; import com.zssi.framework.app.sjbb.dao.CbtjDao; import com.zssi.framework.app.util.ExportExcelUtil; @Service public class CbtjService extends BaseBO<YcwCbxxDao>{ @Autowired private Md5PasswordEncoder md5PasswordEncoder; @Autowired private CbtjDao dao; /** * 后台:成本信息列表 * @author wangyong * @date 2015年10月12日 * @param start * @param limit * @param code * @return */ public List<Map<String, Object>> getCbtjList(String ksmc,String ksyf,String jsyf){ return dao.getCbtjList(ksmc, ksyf,jsyf); } /** * 查看成本明细页面 * @author wangyong * @date 2016年1月20日 * @param request * @param response * @return */ public List<Map<String, Object>> getCbmx(String ksmccx,String ksyf,String jsyf){ return dao.getCbmx(ksmccx,ksyf,jsyf); } /** * 查询成本明细页面部门名称 * @author wangyong * @date 2016年1月20日 * @param request * @param response * @return */ public List<Map<String, Object>> getBmmc(String ksmccx){ return dao.getBmmc(ksmccx); } /** * 成本统计导出Excle * @author wangyong * @date 2016年1月26日 * @param ksmccx * @param ssyfcx * @throws Exception */ @Transactional public void exportExcel(HttpServletRequest request,HttpServletResponse response,String ksmc,String ksyf,String jsyf) throws Exception{ List<Map<String,Object>> CbtjList=dao.getCbtjExcel(ksmc, ksyf,jsyf); List<Map<String,Object>> CbtjBfbList=dao.getCbtjBfbExcel(ksmc, ksyf,jsyf); List<Map<String,Object>> list= new ArrayList<Map<String,Object>>(); for(int i=0;i<CbtjList.size();i++){ Map<String,Object> CbtjMap = CbtjList.get(i); Map<String,Object> CbtjBfbMap = CbtjBfbList.get(i); list.add(CbtjMap); list.add(CbtjBfbMap); } String[] header=new String[]{"科室名称","工资薪金(占比)","差旅费(占比)","材料工器具(占比)","办公费(占比)","交通费(占比)","招待费(占比)","修缮检定(占比)","培训费(占比)","会议费(占比)","邮电费(占比)","文印费(占比)","水电费(占比)","物管费(占比)","租赁费(占比)","技术服务费(占比)","业务协作费(占比)","咨询费(占比)","劳务费(占比)","外委检验费(占比)","折旧费(占比)","公务用车费(占比)","其他(占比)","合计"}; String[] keys=new String[]{"BMMC","GZXJ","CLF","CLGQJ","BGF","JTF","ZDF","XSJD","PXF","HYF","YD","WYF","SDF","WGF","ZLF","JF","YWXZF","ZXF","LWF","JYF","ZJF","GWYCF","QTFY","HJ"}; ExportExcelUtil.exportExcel(request, response, header, keys, list); } /** * 成本统计明细导出Excle * @author wangyong * @date 2016年1月26日 * @param ksmccx * @param ssyfcx * @throws Exception */ @Transactional public void exportCbtjmx(HttpServletRequest request,HttpServletResponse response,String ksmc,String ksyf,String jsyf) throws Exception{ if(ksmc!=null){ ksmc=java.net.URLDecoder.decode(ksmc,"UTF-8"); } List<Map<String,Object>> list=dao.getCbmx(ksmc, ksyf,jsyf); String[] header=new String[]{"科目","凭证代码","摘要","金额"}; String[] keys=new String[]{"FYLX","","FYXQ","JE"}; ExportExcelUtil.exportExcel(request, response, header, keys, list); } }
[ "2629690209@qq.com" ]
2629690209@qq.com
1543abde8c5619a3feac64e7ca2a5f34d6bb483f
8982c38c298225ad7e29627e11a9b1e08d1cd1a9
/src/main/java/com/aerothinker/plandb/service/ParaClassQueryService.java
921b638dd504bd06b6dd9f1c1e6926bc4e1a2985
[]
no_license
bigjungle/example-multitenancy
4e49b110e4909d7f5945337f286740df36662cdf
6c42d8f0832f90e2b8f63c1d4aeeadc6d670ffb1
refs/heads/master
2020-04-16T22:30:14.949844
2019-03-19T03:40:16
2019-03-19T03:40:16
null
0
0
null
null
null
null
UTF-8
Java
false
false
7,777
java
package com.aerothinker.plandb.service; import java.util.List; import javax.persistence.criteria.JoinType; import org.slf4j.Logger; import org.slf4j.LoggerFactory; import org.springframework.data.domain.Page; import org.springframework.data.domain.Pageable; import org.springframework.data.jpa.domain.Specification; import org.springframework.stereotype.Service; import org.springframework.transaction.annotation.Transactional; import io.github.jhipster.service.QueryService; import com.aerothinker.plandb.domain.ParaClass; import com.aerothinker.plandb.domain.*; // for static metamodels import com.aerothinker.plandb.repository.ParaClassRepository; import com.aerothinker.plandb.repository.search.ParaClassSearchRepository; import com.aerothinker.plandb.service.dto.ParaClassCriteria; import com.aerothinker.plandb.service.dto.ParaClassDTO; import com.aerothinker.plandb.service.mapper.ParaClassMapper; /** * Service for executing complex queries for ParaClass entities in the database. * The main input is a {@link ParaClassCriteria} which gets converted to {@link Specification}, * in a way that all the filters must apply. * It returns a {@link List} of {@link ParaClassDTO} or a {@link Page} of {@link ParaClassDTO} which fulfills the criteria. */ @Service @Transactional(readOnly = true) public class ParaClassQueryService extends QueryService<ParaClass> { private final Logger log = LoggerFactory.getLogger(ParaClassQueryService.class); private final ParaClassRepository paraClassRepository; private final ParaClassMapper paraClassMapper; private final ParaClassSearchRepository paraClassSearchRepository; public ParaClassQueryService(ParaClassRepository paraClassRepository, ParaClassMapper paraClassMapper, ParaClassSearchRepository paraClassSearchRepository) { this.paraClassRepository = paraClassRepository; this.paraClassMapper = paraClassMapper; this.paraClassSearchRepository = paraClassSearchRepository; } /** * Return a {@link List} of {@link ParaClassDTO} which matches the criteria from the database * @param criteria The object which holds all the filters, which the entities should match. * @return the matching entities. */ @Transactional(readOnly = true) public List<ParaClassDTO> findByCriteria(ParaClassCriteria criteria) { log.debug("find by criteria : {}", criteria); final Specification<ParaClass> specification = createSpecification(criteria); return paraClassMapper.toDto(paraClassRepository.findAll(specification)); } /** * Return a {@link Page} of {@link ParaClassDTO} which matches the criteria from the database * @param criteria The object which holds all the filters, which the entities should match. * @param page The page, which should be returned. * @return the matching entities. */ @Transactional(readOnly = true) public Page<ParaClassDTO> findByCriteria(ParaClassCriteria criteria, Pageable page) { log.debug("find by criteria : {}, page: {}", criteria, page); final Specification<ParaClass> specification = createSpecification(criteria); return paraClassRepository.findAll(specification, page) .map(paraClassMapper::toDto); } /** * Return the number of matching entities in the database * @param criteria The object which holds all the filters, which the entities should match. * @return the number of matching entities. */ @Transactional(readOnly = true) public long countByCriteria(ParaClassCriteria criteria) { log.debug("count by criteria : {}", criteria); final Specification<ParaClass> specification = createSpecification(criteria); return paraClassRepository.count(specification); } /** * Function to convert ParaClassCriteria to a {@link Specification} */ private Specification<ParaClass> createSpecification(ParaClassCriteria criteria) { Specification<ParaClass> specification = Specification.where(null); if (criteria != null) { if (criteria.getId() != null) { specification = specification.and(buildSpecification(criteria.getId(), ParaClass_.id)); } if (criteria.getName() != null) { specification = specification.and(buildStringSpecification(criteria.getName(), ParaClass_.name)); } if (criteria.getSerialNumber() != null) { specification = specification.and(buildStringSpecification(criteria.getSerialNumber(), ParaClass_.serialNumber)); } if (criteria.getSortString() != null) { specification = specification.and(buildStringSpecification(criteria.getSortString(), ParaClass_.sortString)); } if (criteria.getDescString() != null) { specification = specification.and(buildStringSpecification(criteria.getDescString(), ParaClass_.descString)); } if (criteria.getImageBlobName() != null) { specification = specification.and(buildStringSpecification(criteria.getImageBlobName(), ParaClass_.imageBlobName)); } if (criteria.getUsingFlag() != null) { specification = specification.and(buildSpecification(criteria.getUsingFlag(), ParaClass_.usingFlag)); } if (criteria.getRemarks() != null) { specification = specification.and(buildStringSpecification(criteria.getRemarks(), ParaClass_.remarks)); } if (criteria.getValidType() != null) { specification = specification.and(buildSpecification(criteria.getValidType(), ParaClass_.validType)); } if (criteria.getValidBegin() != null) { specification = specification.and(buildRangeSpecification(criteria.getValidBegin(), ParaClass_.validBegin)); } if (criteria.getValidEnd() != null) { specification = specification.and(buildRangeSpecification(criteria.getValidEnd(), ParaClass_.validEnd)); } if (criteria.getInsertTime() != null) { specification = specification.and(buildRangeSpecification(criteria.getInsertTime(), ParaClass_.insertTime)); } if (criteria.getUpdateTime() != null) { specification = specification.and(buildRangeSpecification(criteria.getUpdateTime(), ParaClass_.updateTime)); } if (criteria.getVerifyTime() != null) { specification = specification.and(buildRangeSpecification(criteria.getVerifyTime(), ParaClass_.verifyTime)); } if (criteria.getCreatedById() != null) { specification = specification.and(buildSpecification(criteria.getCreatedById(), root -> root.join(ParaClass_.createdBy, JoinType.LEFT).get(RmsUser_.id))); } if (criteria.getModifiedById() != null) { specification = specification.and(buildSpecification(criteria.getModifiedById(), root -> root.join(ParaClass_.modifiedBy, JoinType.LEFT).get(RmsUser_.id))); } if (criteria.getVerifiedById() != null) { specification = specification.and(buildSpecification(criteria.getVerifiedById(), root -> root.join(ParaClass_.verifiedBy, JoinType.LEFT).get(RmsUser_.id))); } if (criteria.getParentId() != null) { specification = specification.and(buildSpecification(criteria.getParentId(), root -> root.join(ParaClass_.parent, JoinType.LEFT).get(ParaClass_.id))); } } return specification; } }
[ "ccpitcmp@outlook.com" ]
ccpitcmp@outlook.com
2232b35845c19551172d66bf759ffe3e4d071430
45ee32435c345790cae1f10111e37f860395f1ea
/art-extension/opttests/src/OptimizationTests/LoopUnrolling/IntLoopTryCatchAfter/Main.java
dd86219bb90e9c9f62d9c842859f0cfd2cc70f63
[ "Apache-2.0", "NCSA", "LicenseRef-scancode-unknown-license-reference" ]
permissive
android-art-intel/Nougat
b93eb0bc947088ba55d03e62324af88d332c5e93
ea41b6bfe5c6b62a3163437438b21568cc783a24
refs/heads/master
2020-07-05T18:53:19.370466
2016-12-16T04:23:40
2016-12-16T04:23:40
73,984,816
9
1
null
null
null
null
UTF-8
Java
false
false
1,517
java
/* * Copyright (C) 2016 Intel Corporation * * 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 OptimizationTests.LoopUnrolling.IntLoopTryCatchAfter; public class Main { public class TestClass { private int value; public void setValue(int value) { this.value += value; } public int getValue() { return value; } } final int testLoop(TestClass tClass) { for (int i = 0; i < 10; i++) { tClass.setValue(i); } return tClass.getValue(); } final int testTryCatch() { int res = 0; TestClass tClass = new TestClass(); try { throw new Exception("My exception"); } catch (Exception e) { } finally { } res *= testLoop(tClass); return res; } public void test() { System.out.println(testTryCatch()); } public static void main(String[] args) { new Main().test(); } }
[ "aleksey.v.ignatenko@intel.com" ]
aleksey.v.ignatenko@intel.com
1a6b335adb666378b921603814c7c766a712a7d6
0a3a773d5d65c07a3e05ff5ac1e56492c4557645
/yuki-hiroshi-design-patterns/src/main/java/com/pearl/genius/composite/example02/Keyboard.java
18e7334e16e24d917d09a7a52426542c19d0f234
[]
no_license
hgs-study/enjoy-design-pattern
d0db4d20f9da85af3b92a3f5874f20fe2d4eeaaf
fe93dce07bcfc025c42347b17adc0307d668dc01
refs/heads/master
2023-01-24T21:55:49.326016
2020-12-08T09:39:19
2020-12-08T09:39:19
null
0
0
null
null
null
null
UTF-8
Java
false
false
338
java
package com.pearl.genius.composite.example02; public class Keyboard extends ComputerDevice { private int price; private int power; public Keyboard(int power, int price) { this.price = price; this.power = power; } @Override public int getPrice() { return price; } @Override public int getPower() { return power; } }
[ "csj4032@gmail.com" ]
csj4032@gmail.com
0dc414e077d6fbf17d8a61e5fe643633083e996e
ffbe549bb245a140ff86ba8213723cc7e803ca68
/src/main/java/de/origindd/mpeg/mpegv/dcv/HeatingType.java
287b9ed2f3e57d0b7ac0d0a84fe3285af9bde6fc
[]
no_license
OriginDD/mpeg-7-extractor
43259f3a1b0dea1cc204395039e6221624599717
c7c1cb5e9d7d09286ff95e1e4baa8dff9a0483bb
refs/heads/master
2021-01-17T09:58:54.051776
2017-03-17T06:46:25
2017-03-17T06:46:25
83,997,792
0
0
null
null
null
null
UTF-8
Java
false
false
1,843
java
// // This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.4-2 // See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a> // Any modifications to this file will be lost upon recompilation of the source schema. // Generated on: 2015.01.12 at 06:39:36 PM BRST // package de.origindd.mpeg.mpegv.dcv; import java.math.BigInteger; import javax.xml.bind.annotation.XmlAccessType; import javax.xml.bind.annotation.XmlAccessorType; import javax.xml.bind.annotation.XmlAttribute; import javax.xml.bind.annotation.XmlType; import de.origindd.mpeg.mpegv.iidl.DeviceCommandBaseType; /** * <p>Java class for HeatingType complex type. * * <p>The following schema fragment specifies the expected content contained within this class. * * <pre> * &lt;complexType name="HeatingType"> * &lt;complexContent> * &lt;extension base="{urn:mpeg:mpeg-v:2010:01-IIDL-NS}DeviceCommandBaseType"> * &lt;attribute name="intensity" type="{http://www.w3.org/2001/XMLSchema}integer" /> * &lt;/extension> * &lt;/complexContent> * &lt;/complexType> * </pre> * * */ @XmlAccessorType(XmlAccessType.FIELD) @XmlType(name = "HeatingType") public class HeatingType extends DeviceCommandBaseType { @XmlAttribute(name = "intensity") protected BigInteger intensity; /** * Gets the value of the intensity property. * * @return * possible object is * {@link BigInteger } * */ public BigInteger getIntensity() { return intensity; } /** * Sets the value of the intensity property. * * @param value * allowed object is * {@link BigInteger } * */ public void setIntensity(BigInteger value) { this.intensity = value; } }
[ "ulrich.kowohl@zalando.de" ]
ulrich.kowohl@zalando.de
e66ec2441bb34eeb105ae66d8b188e725b48687d
e7d9b7ab98625538df2b0d2f7df97e4f4bc331fd
/commons/src/main/java/com/enliple/pudding/commons/network/vo/API46.java
9fdae11d6a28dabc4441a3fe3cf89c066a5f2bae
[]
no_license
ssang83/Pudding
5c9f1703c5f7101b65c63db5af604f70474fee99
474fa922a1bc663bd3504c852837474da32617e8
refs/heads/main
2023-03-11T10:02:06.471278
2021-02-24T07:07:34
2021-02-24T07:07:34
341,803,579
0
0
null
null
null
null
UTF-8
Java
false
false
863
java
package com.enliple.pudding.commons.network.vo; import java.util.List; public class API46 { public String result; public String nTotalCount; public List<ReviewItem> data; public static class ReviewItem { public String is_id; public String ct_id; public String is_type; public String is_score; public String is_subject; public String is_content; public String photo_thumb; public List<String> is_photo; public String is_time; public String mb_id; public String mb_nick; public String mb_user_img; public String ct_option; public String recommend; public String not_recommend; public String is_mine; public String is_recommend; // 0: 추천안함, 1:추천, 2:비추천 } }
[ "js.kim@petdoc.co.kr" ]
js.kim@petdoc.co.kr
5ac78630e642753b04b67491d2a8cd56a442cc2d
7857f4db914addc09edebc292cadb227d23664b8
/ph-stx-engine/src/main/java/net/sf/joost/emitter/FOPEmitter.java
ae812a09af05592ec5a8287c0ebee23ed6f6e550
[ "Apache-2.0", "MPL-1.1" ]
permissive
phax/ph-stx
7da41b3bed977e5ec2a44bc8f0fb91ce3ae9bced
1f2fa92027491b91d70674838fd28944357edcbb
refs/heads/master
2023-08-27T20:40:25.960281
2018-02-02T15:03:09
2018-02-02T15:03:09
62,889,250
5
3
Apache-2.0
2018-01-05T12:22:15
2016-07-08T13:06:19
Java
UTF-8
Java
false
false
2,918
java
/** * The contents of this file are subject to the Mozilla Public License * Version 1.1 (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.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * The Original Code is: this file * * The Initial Developer of the Original Code is Oliver Becker. * * Portions created by Philip Helger * are Copyright (C) 2016-2017 Philip Helger * All Rights Reserved. */ package net.sf.joost.emitter; import java.io.OutputStream; import org.apache.avalon.framework.logger.ConsoleLogger; import org.apache.fop.apps.Driver; import org.apache.fop.messaging.MessageHandler; import org.xml.sax.ContentHandler; import org.xml.sax.helpers.XMLFilterImpl; /** * Wrapper class which passes SAX events to * <a href="http://xml.apache.org/fop">FOP</a> * * @version $Revision: 1.3 $ $Date: 2005/03/13 17:12:48 $, tested with FOP * 0.20.4 * @author Oliver Becker */ public class FOPEmitter extends XMLFilterImpl implements IStxEmitter { /** The system identifier required by {@link IStxEmitter} */ private String m_sSystemID; /** * Constructs a new FOPEmitter wrapper object. * * @param os * the stream to which the PDF output will be written by FOP */ public FOPEmitter (final OutputStream os) { setContentHandler (getFOPContentHandler (os)); } /** * @param os * the stream to which the PDF output will be written by FOP * @return the content handler of a FOP Driver object which is used to process * FO data */ public static ContentHandler getFOPContentHandler (final OutputStream os) { final Driver fop = new Driver (); // Avalon logging framework final ConsoleLogger log = new ConsoleLogger (ConsoleLogger.LEVEL_WARN); MessageHandler.setScreenLogger (log); fop.setLogger (log); // Default: produce PDF fop.setRenderer (Driver.RENDER_PDF); fop.setOutputStream (os); return fop.getContentHandler (); } // // Methods from interface LexicalHandler // no need to pass them to FOP: provide emtpy implementations // public void startDTD (final String name, final String pubId, final String sysId) {} public void endDTD () {} public void startEntity (final String name) {} public void endEntity (final String name) {} public void startCDATA () {} public void endCDATA () {} public void comment (final char [] ch, final int start, final int length) {} public String getSystemId () { return m_sSystemID; } public void setSystemId (final String systemId) { this.m_sSystemID = systemId; } }
[ "philip@helger.com" ]
philip@helger.com
61801da54da18486c1360c281dc1113f0a53cfc3
f9bd66094f6e69de51cfe372ce7a0abfb88dc789
/src/main/java/com/example/demo/dao/RouteLogMongoDao.java
62ceb05448474c2bd38da9344468ccb77a5c1f5b
[]
no_license
llgeill/gateway-demo
268566af5bcd3e15ac2cbb0860b15383cf863664
b3da8a44203feaedbf4474dcedcf7b00e4c32d56
refs/heads/master
2022-06-23T01:32:12.898971
2019-10-18T07:47:06
2019-10-18T07:47:06
211,823,059
0
0
null
2021-04-26T19:35:22
2019-09-30T09:22:40
Java
UTF-8
Java
false
false
251
java
package com.example.demo.dao; import com.example.demo.entity.RouteLogVo; import org.springframework.data.mongodb.repository.MongoRepository; import java.util.List; public interface RouteLogMongoDao extends MongoRepository<RouteLogVo,String> { }
[ "903857227@qq.com" ]
903857227@qq.com
394c9f9c733bcd3a7dfeace26072401e53f39ccc
48631c3851b15fbc20e61e29b82480b64eec2885
/poi/src/main/java/com/prosayj/springboot/report/exception/ReportErrorEnum.java
0caec37dced32093f780d9b68af35035bfd56680
[ "Apache-2.0" ]
permissive
ProSayJ/springbootstudy
56cb7f80502888d2c564d7a4bda23dd0650750f7
04b5ce563b9e6163ab6d6217292d7dd266e105c3
refs/heads/master
2022-12-25T10:42:49.047945
2021-04-09T15:20:12
2021-04-09T15:20:12
147,488,466
0
0
Apache-2.0
2022-12-16T03:22:22
2018-09-05T08:52:00
Java
UTF-8
Java
false
false
1,085
java
package com.prosayj.springboot.report.exception; /** * <b><code>ReportErrorEnum</code></b> * <p/> * Description:报告声场异常MSG * <p/> * <b>Creation Time:</b> 2018/10/31 22:41. * * @author Hu Weihui */ public enum ReportErrorEnum { /********************** 报告读取失败 **********************/ READ_FAIL("读取文件失败"), /********************** 数据读取失败 **********************/ CHART_DATA_ERROR("图表数据读取失败"), CHART_SERIER_DATA_ERROR("图表系列数据读取失败"), /********************** 构造图表失败 **********************/ LINE_CHART_SERIER_ERROR("折线图系列读取失败"), BAR_CHART_SERIER_ERROR("柱状图系列读取失败"), PIE_CHART_SERIER_ERROR("饼图系列读取失败"), BAR_LINE_CHART_ERROR("构造柱状+折线图失败,传入数据系列<1"); private String msg; public String getMsg() { return msg; } public void setMsg(String msg) { this.msg = msg; } ReportErrorEnum(String msg) { this.msg = msg; } }
[ "yangjian@bubi.cn" ]
yangjian@bubi.cn
db3f38a3471f47f1cfddfeec6990dbf9da8578b6
dcc8307fa0788f0ef4c5d450fec977572227edaf
/Server/first_workspace/07_Ajax/src/com/ajax/controller/JsonBasicServlet.java
4042c2ebf5a13f61dbb8dcadb372f1c1e8f3fc99
[]
no_license
fggo/KH_java
87833bf2630f24273c56ad99b0e029eef8f1d199
283dcb6b7c7a38a23b61e61b5ddf7d0467a3457d
refs/heads/master
2022-12-23T18:02:26.681769
2019-11-17T13:21:56
2019-11-17T13:21:56
183,197,132
0
3
null
2022-12-16T00:41:00
2019-04-24T09:38:21
Java
UTF-8
Java
false
false
3,176
java
package com.ajax.controller; import java.io.IOException; import java.util.ArrayList; import java.util.List; import javax.servlet.ServletException; import javax.servlet.annotation.WebServlet; import javax.servlet.http.HttpServlet; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; import com.ajax.model.vo.User; import com.google.gson.Gson; /** * Servlet implementation class JsonBasicServlet */ @WebServlet("/jsonData") public class JsonBasicServlet extends HttpServlet { private static final long serialVersionUID = 1L; /** * @see HttpServlet#HttpServlet() */ public JsonBasicServlet() { super(); // TODO Auto-generated constructor stub } /** * @see HttpServlet#doGet(HttpServletRequest request, HttpServletResponse response) */ protected void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { //server에서 javascript 객체로 프론트에 전송하기! //JSON 라이브러리가 있어야지 가능! //JSONObject객체를 이용 // JSONObject jobj = new JSONObject(); // jobj.put("name", "유병승"); // jobj.put("age", 19); // jobj.put("weight", 65.5); // jobj.put("address", "경기도 시흥시"); // jobj.put("hobby", "클래식,독서,여행"); // jobj.put("breaktime", 50); // User u = new User(1, "user01", "유병승", "경기도 시흥시"); // jobj.put("userNo", u.getUserNo()); // jobj.put("userId", u.getUserId()); // jobj.put("userName", u.getUserName()); // jobj.put("userAddr", u.getUserAddr()); //1. JSONObject 전송 // response.setContentType("application/json;charset=utf-8"); //object 타입임을 client에 알림 // response.getWriter().print(jobj); //2. JSON List 객체를 보내보자 List<User> list = new ArrayList<User>(); list.add(new User(1, "user01", "유병승", "경기도 시흥")); list.add(new User(2, "user02", "유병송", "경기동 시홍")); list.add(new User(3, "user03", "유병숭", "경기둥 시훙")); list.add(new User(4, "user04", "유병슨", "경기둉 시흉")); //JSONArray 객체를 이용해서 list를 보냄 // JSONArray jlist = new JSONArray(); // // for(User u : list){ // JSONObject jo = new JSONObject(); // jo.put("userNo", u.getUserNo()); // jo.put("userId", u.getUserId()); // jo.put("userName", u.getUserName()); // jo.put("userAddr", u.getUserAddr()); // // jlist.add(jo); // } // response.setContentType("application/json;charset=utf-8"); // response.getWriter().print(jlist); response.setContentType("application/json;charset=utf-8"); new Gson().toJson(list, response.getWriter()); // new Gson().toJson(new User(1, "user01", "유병승", "경기도 시흥"), response.getWriter()); } /** * @see HttpServlet#doPost(HttpServletRequest request, HttpServletResponse response) */ protected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { // TODO Auto-generated method stub doGet(request, response); } }
[ "jnuho@outlook.com" ]
jnuho@outlook.com
9eea5200789b7f8a561ded47564789c52543502f
2b8c47031dddd10fede8bcf16f8db2b52521cb4f
/subject SPLs and test cases/Lampiro(6)/Lampiro_P3/evosuite-tests3/it/yup/xml/Element_ESTest_scaffolding3.java
22bedfd758b3e3f31de9786363c8b846fdc02a6b
[]
no_license
psjung/SRTST_experiments
6f1ff67121ef43c00c01c9f48ce34f31724676b6
40961cb4b4a1e968d1e0857262df36832efb4910
refs/heads/master
2021-06-20T04:45:54.440905
2019-09-06T04:05:38
2019-09-06T04:05:38
206,693,757
1
0
null
2020-10-13T15:50:41
2019-09-06T02:10:06
Java
UTF-8
Java
false
false
1,462
java
/** * Scaffolding file used to store all the setups needed to run * tests automatically generated by EvoSuite * Sun Jul 01 14:27:32 KST 2018 */ package it.yup.xml; import org.evosuite.runtime.annotation.EvoSuiteClassExclude; import org.junit.BeforeClass; import org.junit.Before; import org.junit.After; @EvoSuiteClassExclude public class Element_ESTest_scaffolding3 { @org.junit.Rule public org.evosuite.runtime.vnet.NonFunctionalRequirementRule nfr = new org.evosuite.runtime.vnet.NonFunctionalRequirementRule(); private org.evosuite.runtime.thread.ThreadStopper threadStopper = new org.evosuite.runtime.thread.ThreadStopper (org.evosuite.runtime.thread.KillSwitchHandler.getInstance(), 3000); @BeforeClass public static void initEvoSuiteFramework() { org.evosuite.runtime.RuntimeSettings.className = "it.yup.xml.Element"; org.evosuite.runtime.GuiSupport.initialize(); org.evosuite.runtime.RuntimeSettings.maxNumberOfIterationsPerLoop = 10000; } @Before public void initTestCase(){ threadStopper.storeCurrentThreads(); threadStopper.startRecordingTime(); org.evosuite.runtime.GuiSupport.setHeadless(); org.evosuite.runtime.agent.InstrumentingAgent.activate(); } @After public void doneWithTestCase(){ threadStopper.killAndJoinClientThreads(); org.evosuite.runtime.agent.InstrumentingAgent.deactivate(); org.evosuite.runtime.GuiSupport.restoreHeadlessMode(); } }
[ "psjung@kaist.ac.kr" ]
psjung@kaist.ac.kr
1684c3a98a509d76963d5221f95a90c0e6f5c69e
f5d5b368c1ae220b59cfb26bc26526b494c54d0e
/kishordguptahockytracker2/src/com/kd/hockymain/AwayData.java
92a6ff36d131b6445f9160a777272da3ba4f34f4
[]
no_license
kishordgupta/2012_bkup
3778c26082697b1cf223e27822d8efe90b35fc76
53ef4014fb3e11158c3f9242cb1f829e02e3ef69
refs/heads/master
2021-01-10T08:25:57.122415
2020-10-16T12:06:52
2020-10-16T12:06:52
47,512,520
0
0
null
null
null
null
UTF-8
Java
false
false
190
java
package com.kd.hockymain; public class AwayData { public String period=""; public String playerrank=""; public String time=""; public String type=""; public String minus=""; }
[ "kdgupta87@gmail.com" ]
kdgupta87@gmail.com
794a943b973ba71e1b90669014a107a7ce0045e0
d5515553d071bdca27d5d095776c0e58beeb4a9a
/src/net/sourceforge/plantuml/graph/ALinkImpl.java
8652f562d4e5afd12ac31fa0cb601ce9a468aeaa
[]
no_license
ccamel/plantuml
29dfda0414a3dbecc43696b63d4dadb821719489
3100d49b54ee8e98537051e071915e2060fe0b8e
refs/heads/master
2022-07-07T12:03:37.351931
2016-12-14T21:01:03
2016-12-14T21:01:03
77,067,872
1
0
null
2022-05-30T09:56:21
2016-12-21T16:26:58
Java
UTF-8
Java
false
false
1,755
java
/* ======================================================================== * PlantUML : a free UML diagram generator * ======================================================================== * * (C) Copyright 2009-2017, Arnaud Roques * * Project Info: http://plantuml.com * * This file is part of PlantUML. * * PlantUML 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. * * PlantUML 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 library; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, * USA. * * * Original Author: Arnaud Roques * * */ package net.sourceforge.plantuml.graph; public class ALinkImpl implements ALink { private final ANode node1; private final ANode node2; private final Object userData; private final int diffHeight; @Override public String toString() { return "" + node1 + " -> " + node2; } public ALinkImpl(ANode n1, ANode n2, int diffHeight, Object userData) { this.node1 = n1; this.node2 = n2; this.userData = userData; this.diffHeight = diffHeight; } public int getDiffHeight() { return diffHeight; } public ANode getNode1() { return node1; } public ANode getNode2() { return node2; } public final Object getUserData() { return userData; } }
[ "plantuml@gmail.com" ]
plantuml@gmail.com
cd64fc2ab1c57bfd8b25b3f47ce823e5e3ca2302
01d77b565b4396067bd0271308be8fc270029458
/ThinkingJava/src/com/syl/basic/chapter3/OverFlow.java
2e1168ac104a154bea3bc07f6df8022de9683a50
[]
no_license
Icarours/JavaWeb
547210d6e00001c94ef404029709bb04e32fa0d4
df39a20feb28a6492ca44e92417b5460e9994e3b
refs/heads/master
2021-01-01T17:20:44.785356
2017-08-11T16:45:57
2017-08-11T16:45:57
98,049,529
0
0
null
null
null
null
UTF-8
Java
false
false
455
java
package com.syl.basic.chapter3; /** * @ClassName: OverFlow * @Description:int取值范围溢出 * @author Bright * @date 2017年7月7日 下午4:27:21 */ public class OverFlow { public static void main(String[] args) { int intMax = Integer.MAX_VALUE / 2; System.out.println("intMax=" + intMax); int bigger = intMax * 3; System.out.println("bigger=" + bigger); System.out.println(Integer.MAX_VALUE); System.out.println(0x7fffffff); } }
[ "j376787348@163.com" ]
j376787348@163.com
c7b1b7bee5665111f33e9e158eee340ca5c763a0
c2698426be70515a3f5f53a04774171910aa154b
/24_Socket_Multi/src/com/mystudy/net_muliti2/TCPClientMultiChat.java
367c6fa5130318f84b8577b82ad732278b6eff8a
[]
no_license
rexypark/Java-Basic
64780ae62d4be6a3f63c1c889a961da79a2ab2e5
469abd29d9f95b3a9fa2df94c1c8d8f26f374a2f
refs/heads/master
2021-02-04T23:06:10.523555
2020-02-28T09:02:36
2020-02-28T09:02:36
243,719,033
0
0
null
null
null
null
UHC
Java
false
false
2,901
java
package com.mystudy.net_muliti2; import java.io.DataInput; import java.io.DataInputStream; import java.io.DataOutput; import java.io.DataOutputStream; import java.io.IOException; import java.net.InetAddress; import java.net.Socket; import java.net.UnknownHostException; import java.util.Scanner; import javax.swing.InputMap; // 메세지 작성 전송 독립적으로 동작하는 쓰레드 생성 // 메세지 수신 독립적으로 동작하는 쓰레드 생성 public class TCPClientMultiChat { public static void main(String[] args) { //송신, 수신 쓰레드 생성하고 실행 Scanner scan = new Scanner(System.in); System.out.println("사용할 ID를 입력 하세요"); System.out.print(">>"); String name = scan.nextLine(); Socket socket = null; //"192.168.0.100" try { //접속할 서버의 IP와 포트 설정 socket = new Socket("192.168.0.69", 10000); //메세지 보내기 쓰래드 생성 실행(쓰레드로 동작) ClientSender clientSender = new ClientSender(name,socket); clientSender.start(); //메세지 받기 쓰레드 생성 실행(쓰레드로 동작) ClientReceiver clientRecevier = new ClientReceiver(socket); clientRecevier.start(); } catch (IOException e) { e.printStackTrace(); } } //메세지 보내기 static class ClientSender extends Thread{ Socket socket; String name; DataOutputStream out; ClientSender(String name, Socket socket) { this.name = name; this.socket = socket; try { out = new DataOutputStream(socket.getOutputStream()); } catch (IOException e) { System.out.println("[ 예외발생 ] ClientSender 생성자 out 객체 생성 실패"); } } @Override public void run() { //메세지 작성하고, 작성된 메세지 서버로 전송 Scanner sc = new Scanner(System.in); if (out == null) { System.out.println("[예외발생] out 객체가 null입니다."); return; } try { //첫번째 메세지 전송 : 이름(별명/아이디) out.writeUTF(name); while (true) { //client 입력값 String msg = sc.nextLine(); // 입력값 서버로 출력 out.writeUTF(msg); } } catch (IOException e) { e.printStackTrace(); } }//ClientSender run method }//ClientSender class // 메세지 받기 쓰레드 작성 static class ClientReceiver extends Thread { Socket socket; DataInputStream in; public ClientReceiver(Socket socket) { this.socket = socket; try { in = new DataInputStream(socket.getInputStream()); } catch (IOException e) { e.printStackTrace(); } } @Override public void run() { while(true) { try { String msg = in.readUTF(); System.out.println(msg); } catch (IOException e) { e.printStackTrace(); } } } // run method }// ClientReceiver class }//TCPClientMultiChat class
[ "hotboa3091@naver.com" ]
hotboa3091@naver.com
04fef7d4622981705b5825dc4d9885aa4bd7a9f5
bbafa52f5496f4381dce505f783b6dd840a89456
/src/main/java/com/irurueta/ar/slam/SlamException.java
cdf24b5a8f76b8f00dcd2ff27ae0a98fc2c2145d
[ "Apache-2.0" ]
permissive
albertoirurueta/irurueta-ar
806e0747e59524faa346817184cd97971975b3bb
ca0f99c92660243026faf3ed74042aee6f9d9cfd
refs/heads/master
2023-03-08T22:01:14.537555
2023-03-04T19:51:27
2023-03-04T19:51:27
157,613,070
1
0
Apache-2.0
2023-03-04T19:52:20
2018-11-14T21:26:17
Java
UTF-8
Java
false
false
1,628
java
/* * Copyright (C) 2016 Alberto Irurueta Carro (alberto@irurueta.com) * * 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.irurueta.ar.slam; import com.irurueta.ar.ARException; /** * Base exception for all exceptions related to SLAM. */ public class SlamException extends ARException { /** * Constructor. */ public SlamException() { super(); } /** * Constructor with String containing message. * * @param message message indicating the cause of the exception. */ public SlamException(final String message) { super(message); } /** * Constructor with message and cause. * * @param message message describing the cause of the exception. * @param cause instance containing the cause */ public SlamException(final String message, final Throwable cause) { super(message, cause); } /** * Constructor with cause. * * @param cause instance containing the cause of the exception. */ public SlamException(final Throwable cause) { super(cause); } }
[ "alberto@irurueta.com" ]
alberto@irurueta.com
0d159398e1d890ea0f78fc234df3703f11185d1f
28782d17391ff43d9e23e43302969ea8f3a4f284
/java/android/support/design/internal/BaselineLayout.java
f660b154fe000c7d7fd1743f929ff4e69918e17a
[]
no_license
UltraSoundX/Fucking-AJN-APP
115f7c2782e089c48748516b77e37266438f998b
11354917502f442ab212e5cada168a8031b48436
refs/heads/master
2021-05-19T11:05:42.588930
2020-03-31T16:27:26
2020-03-31T16:27:26
251,662,642
0
0
null
null
null
null
UTF-8
Java
false
false
3,005
java
package android.support.design.internal; import android.content.Context; import android.util.AttributeSet; import android.view.View; import android.view.ViewGroup; public class BaselineLayout extends ViewGroup { private int a = -1; public BaselineLayout(Context context) { super(context, null, 0); } public BaselineLayout(Context context, AttributeSet attributeSet) { super(context, attributeSet, 0); } public BaselineLayout(Context context, AttributeSet attributeSet, int i) { super(context, attributeSet, i); } /* access modifiers changed from: protected */ public void onMeasure(int i, int i2) { int childCount = getChildCount(); int i3 = 0; int i4 = 0; int i5 = -1; int i6 = 0; int i7 = 0; int i8 = -1; while (i3 < childCount) { View childAt = getChildAt(i3); if (childAt.getVisibility() != 8) { measureChild(childAt, i, i2); int baseline = childAt.getBaseline(); if (baseline != -1) { i5 = Math.max(i5, baseline); i8 = Math.max(i8, childAt.getMeasuredHeight() - baseline); } i7 = Math.max(i7, childAt.getMeasuredWidth()); i6 = Math.max(i6, childAt.getMeasuredHeight()); i4 = View.combineMeasuredStates(i4, childAt.getMeasuredState()); } int i9 = i4; int i10 = i5; i3++; i8 = i8; i5 = i10; i4 = i9; } if (i5 != -1) { i6 = Math.max(i6, Math.max(i8, getPaddingBottom()) + i5); this.a = i5; } setMeasuredDimension(View.resolveSizeAndState(Math.max(i7, getSuggestedMinimumWidth()), i, i4), View.resolveSizeAndState(Math.max(i6, getSuggestedMinimumHeight()), i2, i4 << 16)); } /* access modifiers changed from: protected */ public void onLayout(boolean z, int i, int i2, int i3, int i4) { int i5; int childCount = getChildCount(); int paddingLeft = getPaddingLeft(); int paddingRight = ((i3 - i) - getPaddingRight()) - paddingLeft; int paddingTop = getPaddingTop(); for (int i6 = 0; i6 < childCount; i6++) { View childAt = getChildAt(i6); if (childAt.getVisibility() != 8) { int measuredWidth = childAt.getMeasuredWidth(); int measuredHeight = childAt.getMeasuredHeight(); int i7 = paddingLeft + ((paddingRight - measuredWidth) / 2); if (this.a == -1 || childAt.getBaseline() == -1) { i5 = paddingTop; } else { i5 = (this.a + paddingTop) - childAt.getBaseline(); } childAt.layout(i7, i5, measuredWidth + i7, measuredHeight + i5); } } } public int getBaseline() { return this.a; } }
[ "haroldxin@foxmail.com" ]
haroldxin@foxmail.com
dd0c5a6033a011c13a18e4a503593741438ade10
127b3f3be47561ba076a22b9bbdc4d911469292e
/app/src/androidTest/java/com/cqyanyu/networkcar/driver/ExampleInstrumentedTest.java
5849ca8ee04f85edf54cb75651c008b5a7b1487a
[]
no_license
csw14n0/AndroidProtect1
4b6566ff8b88d4824c37e6667db8fb31a39e80ae
68dc13be32507264db5bc679d915430a124277b0
refs/heads/master
2020-06-16T18:14:44.903232
2017-11-08T10:32:05
2017-11-08T10:32:05
null
0
0
null
null
null
null
UTF-8
Java
false
false
789
java
package com.cqyanyu.networkcar.driver; import android.content.Context; import android.support.test.InstrumentationRegistry; import android.support.test.runner.AndroidJUnit4; import org.junit.Test; import org.junit.runner.RunWith; import static org.junit.Assert.assertEquals; /** * Instrumentation test, which will execute on an Android device. * * @see <a href="http://d.android.com/tools/testing">Testing documentation</a> */ @RunWith(AndroidJUnit4.class) public class ExampleInstrumentedTest { @Test public void useAppContext() throws Exception { // Context of the app under test. Context appContext = InstrumentationRegistry.getTargetContext(); assertEquals("com.cqyanyu.networkcardriver.networkcardriver", appContext.getPackageName()); } }
[ "1763831144@qq.com" ]
1763831144@qq.com
8c911e69aef3575bef4c4eba38b62d573353907e
4ecc390ae66bbb8bad8a6bba636fd19702205d34
/minecraft 1.8/bj.java
2c39cd3c5b2f0991c017a577e4cc5b75db458098
[]
no_license
project-ion/Decompile-Minecraft
d9c967e57ff7d24ada8c4c49f832dac25f18bb9e
12882633319383b7652b475b4f08b6f72acdddc4
refs/heads/master
2021-01-23T15:28:54.832366
2014-09-20T09:57:54
2014-09-20T09:57:54
null
0
0
null
null
null
null
UTF-8
Java
false
false
2,614
java
/* 1: */ import java.util.List; /* 2: */ import net.minecraft.server.MinecraftServer; /* 3: */ /* 4: */ public class bj /* 5: */ extends z /* 6: */ { /* 7: */ public String c() /* 8: */ { /* 9:21 */ return "entitydata"; /* 10: */ } /* 11: */ /* 12: */ public int a() /* 13: */ { /* 14:26 */ return 2; /* 15: */ } /* 16: */ /* 17: */ public String c(ae paramae) /* 18: */ { /* 19:31 */ return "commands.entitydata.usage"; /* 20: */ } /* 21: */ /* 22: */ public void a(ae paramae, String[] paramArrayOfString) /* 23: */ { /* 24:36 */ if (paramArrayOfString.length < 2) { /* 25:37 */ throw new dp("commands.entitydata.usage", new Object[0]); /* 26: */ } /* 27:40 */ wv localwv = b(paramae, paramArrayOfString[0]); /* 28:41 */ if ((localwv instanceof ahd)) { /* 29:42 */ throw new di("commands.entitydata.noPlayers", new Object[] { localwv.e_() }); /* 30: */ } /* 31:45 */ fn localfn1 = new fn(); /* 32:46 */ localwv.e(localfn1); /* 33:47 */ fn localfn2 = (fn)localfn1.b(); /* 34: */ fn localfn3; /* 35: */ try /* 36: */ { /* 37:51 */ localfn3 = gg.a(a(paramae, paramArrayOfString, 1).c()); /* 38: */ } /* 39: */ catch (gf localgf) /* 40: */ { /* 41:53 */ throw new di("commands.entitydata.tagError", new Object[] { localgf.getMessage() }); /* 42: */ } /* 43:56 */ localfn3.o("UUIDMost"); /* 44:57 */ localfn3.o("UUIDLeast"); /* 45: */ /* 46:59 */ localfn1.a(localfn3); /* 47:61 */ if (localfn1.equals(localfn2)) { /* 48:62 */ throw new di("commands.entitydata.failed", new Object[] { localfn1.toString() }); /* 49: */ } /* 50:65 */ localwv.f(localfn1); /* 51: */ /* 52:67 */ a(paramae, this, "commands.entitydata.success", new Object[] { localfn1.toString() }); /* 53: */ } /* 54: */ /* 55: */ public List a(ae paramae, String[] paramArrayOfString, dt paramdt) /* 56: */ { /* 57:73 */ if (paramArrayOfString.length == 1) { /* 58:74 */ return a(paramArrayOfString, MinecraftServer.M().I()); /* 59: */ } /* 60:76 */ return null; /* 61: */ } /* 62: */ /* 63: */ public boolean b(String[] paramArrayOfString, int paramInt) /* 64: */ { /* 65:81 */ return paramInt == 0; /* 66: */ } /* 67: */ } /* Location: C:\Users\Hugo Haldi\Desktop\Decompile Minecraft\1.8.jar * Qualified Name: bj * JD-Core Version: 0.7.0.1 */
[ "projection-team@hotmail.com" ]
projection-team@hotmail.com
d2799ae3528489cb963e196761709191b5e28db0
7a1bb60ca85dd388ed50aac2eda2217b75bb23d6
/android/app/src/main/java/com/hcs/uclient/utils/ReadAddressBook.java
5f6f4bc6fc5a0f3d36a3a9a4093e25e1fca96301
[]
no_license
sqwu/jgj_RN
5b8c83891294cf926fe5165b3e0908f375293c94
7c8c41c88f10819eda4f8450be3fec3eb5c5edfc
refs/heads/master
2022-01-08T06:28:47.865575
2019-05-28T08:06:04
2019-05-28T08:06:04
null
0
0
null
null
null
null
UTF-8
Java
false
false
4,792
java
package com.hcs.uclient.utils; import android.content.ContentResolver; import android.content.Context; import android.database.Cursor; import android.provider.ContactsContract; import android.text.TextUtils; import com.jizhi.jlongg.main.bean.AddressBook; import com.jizhi.jlongg.main.bean.GroupMemberInfo; import com.jizhi.jlongg.main.bean.PersonBean; import com.jizhi.jlongg.main.bean.SynBill; import java.util.ArrayList; import java.util.List; /** * 获取手机通讯录 * * @author hcs * @time 2016年3月11日 10:54:20 */ public class ReadAddressBook { public static List<AddressBook> getAddrBook(Context context) { ContentResolver cr = context.getContentResolver(); String str[] = {ContactsContract.CommonDataKinds.Phone.NUMBER, ContactsContract.CommonDataKinds.Phone.DISPLAY_NAME}; Cursor cur = cr.query(ContactsContract.CommonDataKinds.Phone.CONTENT_URI, str, null, null, null); List<AddressBook> list = null; if (cur != null) { while (cur.moveToNext()) { if (list == null) { list = new ArrayList<>(); } String telphone = cur.getString(cur.getColumnIndex(str[0])); String realName = cur.getString(cur.getColumnIndex(str[1])); telphone = telphone.replaceAll("\\+86", ""); telphone = telphone.replaceAll(" ", ""); realName = realName.replaceAll(" ", ""); if (!TextUtils.isEmpty(realName) && realName.length() > 8) { realName = realName.substring(0, 8); } AddressBook addressBook = new AddressBook(); addressBook.setName(realName); addressBook.setTelph(telphone); list.add(addressBook); } cur.close(); } return list; } // ----------------得到本地联系人信息------------------------------------- public static List getLocalContactsInfos(Context context, boolean isPerson) { ContentResolver cr = context.getContentResolver(); String str[] = {ContactsContract.CommonDataKinds.Phone.NUMBER, ContactsContract.CommonDataKinds.Phone.DISPLAY_NAME}; Cursor cur = cr.query(ContactsContract.CommonDataKinds.Phone.CONTENT_URI, str, null, null, null); List<Object> list = null; if (cur != null) { while (cur.moveToNext()) { if (list == null) { list = new ArrayList<>(); } String telphone = cur.getString(cur.getColumnIndex(str[0])); String realName = cur.getString(cur.getColumnIndex(str[1])); telphone = telphone.replaceAll("\\+86", ""); telphone = telphone.replaceAll(" ", ""); realName = realName.replaceAll(" ", ""); if (!TextUtils.isEmpty(realName) && realName.length() > 8) { realName = realName.substring(0, 8); } if (isPerson) { PersonBean personBean = new PersonBean(); personBean.setName(realName); personBean.setTelph(telphone); list.add(personBean); } else { SynBill syn = new SynBill(); syn.setReal_name(realName); syn.setTelephone(telphone); list.add(syn); } } cur.close(); } return list; } public static ArrayList<GroupMemberInfo> getLocalContactsInfo(Context context) { ContentResolver cr = context.getContentResolver(); String str[] = {ContactsContract.CommonDataKinds.Phone.NUMBER, ContactsContract.CommonDataKinds.Phone.DISPLAY_NAME}; Cursor cur = cr.query(ContactsContract.CommonDataKinds.Phone.CONTENT_URI, str, null, null, null); ArrayList<GroupMemberInfo> list = new ArrayList<>(); if (cur != null) { while (cur.moveToNext()) { String telphone = cur.getString(cur.getColumnIndex(str[0])); if (TextUtils.isEmpty(telphone)) { continue; } String realName = cur.getString(cur.getColumnIndex(str[1])); telphone = telphone.replaceAll("\\+86", ""); telphone = telphone.replaceAll(" ", ""); realName = realName.replaceAll(" ", ""); if (!TextUtils.isEmpty(realName) && realName.length() > 8) { realName = realName.substring(0, 8); } list.add(new GroupMemberInfo(realName, telphone)); } cur.close(); } return list; } }
[ "1261545300@qq.com" ]
1261545300@qq.com
e38a5714f979a38dd7afecca4029edf4fdf4641a
1ad9e2fa88d964c379810ffab75a00ecf95d3d55
/src/main/java/com/peace/ostp/service/impl/PositionInfoServiceImpl.java
4c5c86961b553e4bf122f1b183d736a820b5de05
[]
no_license
GuoGuiRong/ostp
08d8fddf6750806cfb58f2717ac43fd896396d38
669c22bca8a85b71da1f5dcee3c5c78ec88eb5bf
refs/heads/master
2021-05-04T04:54:21.924122
2016-11-20T02:11:15
2016-11-20T02:11:15
74,247,413
1
2
null
null
null
null
UTF-8
Java
false
false
3,735
java
package com.peace.ostp.service.impl; import java.util.List; import java.util.Map; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; import com.peace.ostp.domain.PositionDetailInfo; import com.peace.ostp.persistence.PositionDetailInfoMapper; import com.peace.ostp.persistence.PositionTypeInfoMapper; import com.peace.ostp.service.IPositionInfo; /** * 位置实现 * @author YLS * */ //@Service("one")当一个接口有多个实现类的时候,可以使用@Qualifier中的参数和@Service中的参数配合使用,从而实现多实现的自动注入 @Service public class PositionInfoServiceImpl implements IPositionInfo { @Autowired private PositionDetailInfoMapper positionDetailInfoMapper; @Autowired private PositionTypeInfoMapper positionTypeInfoMapper; /** * 加载初始数据 */ @Override public List<Map<String, String>> getPositionType() { try { return positionTypeInfoMapper.getPositionType(); } catch (Exception e) { if (e.getClass().getName().equals("org.springframework.dao.DuplicateKeyException")) throw new RuntimeException("duplicate-username"); else throw new RuntimeException(e.getMessage()); } } /** * 添加位置 */ @Override public int insert(PositionDetailInfo positionDetailInfo) { try { return positionDetailInfoMapper.insert(positionDetailInfo); } catch (Exception e) { if (e.getClass().getName().equals("org.springframework.dao.DuplicateKeyException")) throw new RuntimeException("duplicate-username"); else throw new RuntimeException(e.getMessage()); } } /** * 查询位置 */ @Override public List<PositionDetailInfo> getPositionInfos( PositionDetailInfo positionDetailInfo, Map<String, Integer> map) { try { return positionDetailInfoMapper.getPositionInfos(positionDetailInfo, map); } catch (Exception e) { if (e.getClass().getName().equals("org.springframework.dao.DuplicateKeyException")) throw new RuntimeException("duplicate-username"); else throw new RuntimeException(e.getMessage()); } } /** * 查看位置详细信息 */ @Override public PositionDetailInfo getPositionInfo(String positionid, String positiontypeid, String sporttypeid) { try { return positionDetailInfoMapper.getPositionInfo(positionid, positiontypeid, sporttypeid); } catch (Exception e) { if (e.getClass().getName().equals("org.springframework.dao.DuplicateKeyException")) throw new RuntimeException("duplicate-username"); else throw new RuntimeException(e.getMessage()); } } /** * 更新位置信息 */ @Override public int updatePositionInfo(PositionDetailInfo positionDetailInfo) { try { return positionDetailInfoMapper.updatePositionInfo(positionDetailInfo); } catch (Exception e) { if (e.getClass().getName().equals("org.springframework.dao.DuplicateKeyException")) throw new RuntimeException("duplicate-username"); else throw new RuntimeException(e.getMessage()); } } /** * 删除位置 */ @Override public void deleteByPrimaryKey(String positionid) { try { positionDetailInfoMapper.deleteByPrimaryKey(positionid); } catch (Exception e) { if (e.getClass().getName().equals("org.springframework.dao.DuplicateKeyException")) throw new RuntimeException("duplicate-username"); else throw new RuntimeException(e.getMessage()); } } @Override public int getTotalRecord(PositionDetailInfo positionDetailInfo) { // TODO Auto-generated method stub return positionDetailInfoMapper.getTotalRecord(positionDetailInfo); } }
[ "3095764372@qq.com" ]
3095764372@qq.com
56beb5bdf6ec769cb7846afdda9d39736658ae3a
d35e29b35dcc98f8ac736f79117a21e57024b08f
/demos/substance-demo/src/main/java/org/pushingpixels/demo/substance/main/check/VAlignmentPanel.java
d2f810cb9566dba3b91b25bed01893556f937559
[ "BSD-3-Clause" ]
permissive
shaneorama/radiance
b810dffb8a353ac9102a52c85f54739a347a1a10
c14988b53a4c12b511265f3b3b0cc28fb1e1bbe3
refs/heads/master
2020-09-02T12:37:24.029021
2019-11-02T00:41:38
2019-11-02T00:41:38
null
0
0
null
null
null
null
UTF-8
Java
false
false
7,609
java
/* * Copyright (c) 2005-2019 Radiance Kirill Grouchnikov. All Rights Reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * * o Redistributions of source code must retain the above copyright notice, * this list of conditions and the following disclaimer. * * o Redistributions in binary form must reproduce the above copyright notice, * this list of conditions and the following disclaimer in the documentation * and/or other materials provided with the distribution. * * o Neither the name of the copyright holder nor the names of * its contributors may be used to endorse or promote products derived * from this software without specific prior written permission. * * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ package org.pushingpixels.demo.substance.main.check; import com.jgoodies.forms.factories.Paddings; import org.pushingpixels.substance.api.*; import org.pushingpixels.substance.api.skin.BusinessBlackSteelSkin; import javax.swing.*; import java.awt.*; import java.awt.event.ActionEvent; public class VAlignmentPanel extends ControllablePanel implements Deferrable { private boolean isInitialized; private JCheckBox toPaintGuiderLines; private JCheckBox toPaintBounds; @Override public boolean isInitialized() { return this.isInitialized; } public VAlignmentPanel() { this.setLayout(new BorderLayout()); } @Override public synchronized void initialize() { TestFormLayoutBuilder builder = new TestFormLayoutBuilder("left:pref:grow", 1, 15) .border(Paddings.DIALOG); for (int fontSize = 11; fontSize < 25; fontSize++) { builder.append(getSubPanel(fontSize)); } this.add(new JScrollPane(builder.build())); TestFormLayoutBuilder controlPanelBuilder = new TestFormLayoutBuilder("fill:pref:grow", 1, 2); toPaintGuiderLines = new JCheckBox("guider lines"); toPaintGuiderLines.addActionListener((ActionEvent e) -> repaint()); controlPanelBuilder.append(toPaintGuiderLines); toPaintBounds = new JCheckBox("bounds"); toPaintBounds.addActionListener((ActionEvent e) -> repaint()); controlPanelBuilder.append(toPaintBounds); this.controlPanel = controlPanelBuilder.build(); this.isInitialized = true; } private JPanel getSubPanel(int size) { final JPanel result = new JPanel() { @Override public void paint(Graphics g) { super.paint(g); Graphics2D g2d = (Graphics2D) g.create(); if (toPaintGuiderLines.isSelected()) { int w = getWidth(); int h = getHeight(); for (int x = 0; x < w; x += 4) { if (x % 20 == 0) { g2d.setColor(new Color(240, 0, 0, 128)); } else { g2d.setColor(new Color(0, 0, 255, 64)); } g2d.drawLine(x, 0, x, h); } for (int y = 0; y < h; y += 4) { if (y % 20 == 0) { g2d.setColor(new Color(240, 0, 0, 128)); } else { g2d.setColor(new Color(0, 0, 255, 64)); } g2d.drawLine(0, y, w, y); } } if (toPaintBounds.isSelected()) { for (int i = 0; i < getComponentCount(); i++) { Component child = getComponent(i); Rectangle bounds = child.getBounds(); g2d.setColor(new Color(128, 0, 255, 128)); g2d.fill(bounds); } } g2d.dispose(); } }; result.setLayout(new BorderLayout()); TestFormLayoutBuilder builder = new TestFormLayoutBuilder("left:pref", 1, 9).border(Paddings.DIALOG); String fontName = "Tahoma"; Font font = new Font(fontName, Font.PLAIN, size); if (UIManager.getLookAndFeel() instanceof SubstanceLookAndFeel) { Font base = SubstanceCortex.GlobalScope.getFontPolicy().getFontSet() .getControlFont(); fontName = base.getFamily(); font = base.deriveFont((float) size); } JLabel label = new JLabel(fontName + " " + size); label.setFont(font); builder.append(label); JRadioButton radio = new JRadioButton("sample"); radio.setFont(font); builder.append(radio); JCheckBox check = new JCheckBox("sample"); check.setFont(font); builder.append(check); JButton button = new JButton("sample"); button.setFont(font); builder.append(button); JComboBox cb = new JComboBox(new Object[] { "sample" }); cb.setFont(font); builder.append(cb); JComboBox ecb = new JComboBox(new Object[] { "sample" }) { @Override public void updateUI() { super.updateUI(); ((JTextField) getEditor().getEditorComponent()).setColumns(5); } }; ecb.setFont(font); ecb.setEditable(true); // the next line is to make the combobox not too wide ecb.setPrototypeDisplayValue("sample"); builder.append(ecb); JSpinner s = new JSpinner( new SpinnerListModel(new Object[] { "sample0", "sample", "sample2" })); s.getModel().setValue("sample"); s.setFont(font); builder.append(s); JTextField tf = new JTextField("sample"); tf.setFont(font); builder.append(tf); JPasswordField pf = new JPasswordField("sample"); pf.setFont(font); builder.append(pf); result.add(builder.build(), BorderLayout.CENTER); SwingUtilities.invokeLater(result::revalidate); return result; } public static void main(String[] args) throws Exception { JFrame.setDefaultLookAndFeelDecorated(true); SwingUtilities.invokeLater(() -> { SubstanceCortex.GlobalScope.setSkin(new BusinessBlackSteelSkin()); JFrame frame = new JFrame("Alignment"); frame.setSize(600, 400); frame.setLocationRelativeTo(null); frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE); VAlignmentPanel panel = new VAlignmentPanel(); panel.initialize(); frame.add(panel, BorderLayout.CENTER); frame.setVisible(true); }); } }
[ "kirill.grouchnikov@gmail.com" ]
kirill.grouchnikov@gmail.com
9e605b14ed445aa264e0c65b31130a29305f8c18
48f0b3e029b304bf2cfb64419aad795445862856
/Evolution/plugins/org.modelrefactoring.evolution.operators.resource.operators.ui/src-gen/org/modelrefactoring/evolution/operators/resource/operators/ui/OperatorsPropertyTester.java
adcb40fc5716f5c595073deaa5f0e35d6d656270
[]
no_license
jreimone/refactory
09dda0718d5d8117f858d3e4497e8c1371530518
837f1ca3d8537250d024ead3be3ba95f7845409e
refs/heads/master
2021-07-18T15:34:02.469855
2021-02-23T07:55:25
2021-02-23T07:55:25
56,208,480
2
1
null
2020-10-13T06:52:33
2016-04-14T05:01:02
Java
UTF-8
Java
false
false
248
java
/** * <copyright> * </copyright> * * */ package org.modelrefactoring.evolution.operators.resource.operators.ui; public class OperatorsPropertyTester { // This class is currently empty, because launch support was disabled for this DSL. }
[ "jreimone@users.noreply.github.com" ]
jreimone@users.noreply.github.com
404fbdeec60861360ec449fd183d86435642598d
fa444cda81bf78a21b634718d1b30f078b7087e1
/src/main/java/com/learn/interview_questions/patterns/creational/singleton/tolena/Main.java
b3d9097737828f96f9472dc556e0aed05aa3fc1a
[]
no_license
dmitrybilyk/interviews
8fb4356a77ef63d74db613295bbbb296e3e652b7
f48d00bd348bab871304578c0c6c423c24db175e
refs/heads/master
2022-12-22T08:11:35.366586
2022-04-29T17:36:20
2022-04-29T17:36:20
23,141,851
4
0
null
2022-12-16T03:39:20
2014-08-20T08:42:27
Java
UTF-8
Java
false
false
269
java
package com.learn.interview_questions.patterns.creational.singleton.tolena; /** * Created by dik81 on 08.02.19. */ public class Main { public static void main(String[] args) { Student student = new Student.StudentBuilder("dima").age(44).build(); } }
[ "dmitry.b@scopicsoftware.com" ]
dmitry.b@scopicsoftware.com
9e655f4e75cdcdd12d700840817265f2b46bb776
381325a109e35a67425dedfc9973da4a6b83959c
/volume-scheduler/trunk/src/main/java/appcloud/vs/strategy/filter/DiskFilter.java
c9ee492f1031e9f5c769971447958f1faca484a0
[]
no_license
ShangfengDing/IaaS
213287571e2ba3c06814565fbb229ef9c964a91a
89d7120ceac53d22520e353325f193c7cdf3a6ff
refs/heads/master
2022-12-22T21:01:06.596557
2019-11-07T13:12:14
2019-11-07T13:12:14
220,217,355
0
1
null
2022-12-16T04:01:46
2019-11-07T11:07:33
JavaScript
UTF-8
Java
false
false
1,370
java
package appcloud.vs.strategy.filter; import org.apache.commons.logging.Log; import org.apache.log4j.Logger; import appcloud.common.model.Host; import appcloud.common.model.VmInstance; import appcloud.common.model.VmInstanceType; import appcloud.vs.Conf; import appcloud.vs.impl.DBUtil; /** * judge the host by disk! * */ public class DiskFilter extends BaseHostFilter { private static final Logger logger = Logger.getLogger(DiskFilter.class); @Override public boolean hostPass(Host host, Integer size, Host exHost) { try { //本身硬盘预留量 Integer freeDisk = Conf.config.getInt(Conf.FREE_DISK, Conf.DEFAULT_FREE_DISK); //获取超卖比例 Integer overSell = DBUtil.getInstance().getClusterById(host.getClusterId()).getDiskOversell(); //计算此主机可卖出的硬盘大小 Integer overSellDiskCap = (int) ((host.getDiskMb() * (1.0*overSell/Conf.OVER_SELL_BASE))/1024); //获取剩余可买量 Integer diskUsed = DBUtil.getInstance().getHostUsedDisk(host.getUuid()); float diskLeft = overSellDiskCap - diskUsed; logger.info(host.getIp()+", overSellDiskCap:"+ overSellDiskCap +"G, diskUsed:" + diskUsed + "G, diskLeft: "+diskLeft +"G"+", imgSize:"+size+"G, freedisk:"+freeDisk+"G"); if(diskLeft > size + freeDisk){ return true; } } catch (Exception e) { e.printStackTrace(); } return false; } }
[ "747879583@qq.com" ]
747879583@qq.com
abb61e1fe7caa223d6adfecbfe2219451b79bad3
a4a51084cfb715c7076c810520542af38a854868
/src/main/java/com/tencent/rtmp/sharp/jni/TraeAudioSessionHost.java
2b3df64c3b605141ac1fbc99b1f46685538ac0cf
[]
no_license
BharathPalanivelu/repotest
ddaf56a94eb52867408e0e769f35bef2d815da72
f78ae38738d2ba6c9b9b4049f3092188fabb5b59
refs/heads/master
2020-09-30T18:55:04.802341
2019-12-02T10:52:08
2019-12-02T10:52:08
null
0
0
null
null
null
null
UTF-8
Java
false
false
2,086
java
package com.tencent.rtmp.sharp.jni; import android.content.Context; import android.content.Intent; import java.util.ArrayList; import java.util.concurrent.locks.ReentrantLock; public class TraeAudioSessionHost { private ArrayList<a> _sessionInfoList = new ArrayList<>(); private ReentrantLock mLock = new ReentrantLock(); public class a { /* renamed from: a reason: collision with root package name */ public long f32465a; /* renamed from: b reason: collision with root package name */ public TraeAudioSession f32466b; public a() { } } public a find(long j) { a aVar; this.mLock.lock(); int i = 0; while (true) { if (i >= this._sessionInfoList.size()) { aVar = null; break; } aVar = this._sessionInfoList.get(i); if (aVar.f32465a == j) { break; } i++; } this.mLock.unlock(); return aVar; } public void add(TraeAudioSession traeAudioSession, long j, Context context) { if (find(j) == null) { a aVar = new a(); aVar.f32465a = j; aVar.f32466b = traeAudioSession; this.mLock.lock(); this._sessionInfoList.add(aVar); this.mLock.unlock(); } } public void remove(long j) { this.mLock.lock(); int i = 0; while (true) { if (i >= this._sessionInfoList.size()) { break; } else if (this._sessionInfoList.get(i).f32465a == j) { this._sessionInfoList.remove(i); break; } else { i++; } } this.mLock.unlock(); } public void sendToAudioSessionMessage(Intent intent) { this.mLock.lock(); for (int i = 0; i < this._sessionInfoList.size(); i++) { this._sessionInfoList.get(i).f32466b.onReceiveCallback(intent); } this.mLock.unlock(); } }
[ "noiz354@gmail.com" ]
noiz354@gmail.com
5496949fc06b52596e75bca9dedbda52fb597c9b
9a513db24f6d400f5aafc97615c1d0653b8d05a1
/OCCJava/TShort_Array1OfShortReal.java
0c4d706d4de152e640910dfe8085c332422a95a3
[]
no_license
Aircraft-Design-UniNa/jpad-occt
71d44cb3c2a906554caeae006199e1885b6ebc6c
f0aae35a8ae7c25c860d6c5ca5262f2b9da53432
refs/heads/master
2020-05-01T04:52:43.335920
2019-03-23T15:08:04
2019-03-23T15:08:04
177,285,955
3
1
null
null
null
null
UTF-8
Java
false
false
3,995
java
package opencascade; public class TShort_Array1OfShortReal { protected long swigCPtr; protected boolean swigCMemOwn; protected Object swigParent; TShort_Array1OfShortReal(long cPtr, boolean cMemoryOwn) { swigCMemOwn = cMemoryOwn; swigCPtr = cPtr; } TShort_Array1OfShortReal(long cPtr, boolean cMemoryOwn, Object Parent) { swigCMemOwn = cMemoryOwn; swigCPtr = cPtr; if ( ! cMemoryOwn ) swigParent = Parent; // keep reference to assumed parent object } static long getCPtr(TShort_Array1OfShortReal obj) { return (obj == null) ? 0 : obj.swigCPtr; } protected void finalize() { delete(); } public synchronized void delete() { if (swigCPtr != 0) { if (swigCMemOwn) { swigCMemOwn = false; OCCwrapJavaJNI.delete_TShort_Array1OfShortReal(swigCPtr); } swigCPtr = 0; } } public TShort_Array1OfShortReal() { this(OCCwrapJavaJNI.new_TShort_Array1OfShortReal__SWIG_0(), true); } public TShort_Array1OfShortReal(int theLower, int theUpper) { this(OCCwrapJavaJNI.new_TShort_Array1OfShortReal__SWIG_1(theLower, theUpper), true); } public TShort_Array1OfShortReal( TShort_Array1OfShortReal theOther) { this(OCCwrapJavaJNI.new_TShort_Array1OfShortReal__SWIG_2(TShort_Array1OfShortReal.getCPtr(theOther), theOther), true); } public TShort_Array1OfShortReal( float theBegin, int theLower, int theUpper) { this(OCCwrapJavaJNI.new_TShort_Array1OfShortReal__SWIG_4( theBegin , theLower, theUpper), true); } public void Init( float theValue) { OCCwrapJavaJNI.TShort_Array1OfShortReal_Init(swigCPtr, this, theValue ); } public int Size() { return OCCwrapJavaJNI.TShort_Array1OfShortReal_Size(swigCPtr, this); } public int Length() { return OCCwrapJavaJNI.TShort_Array1OfShortReal_Length(swigCPtr, this); } public long IsEmpty() { return OCCwrapJavaJNI.TShort_Array1OfShortReal_IsEmpty(swigCPtr, this); } public int Lower() { return OCCwrapJavaJNI.TShort_Array1OfShortReal_Lower(swigCPtr, this); } public int Upper() { return OCCwrapJavaJNI.TShort_Array1OfShortReal_Upper(swigCPtr, this); } public long IsDeletable() { return OCCwrapJavaJNI.TShort_Array1OfShortReal_IsDeletable(swigCPtr, this); } public long IsAllocated() { return OCCwrapJavaJNI.TShort_Array1OfShortReal_IsAllocated(swigCPtr, this); } public TShort_Array1OfShortReal Assign( TShort_Array1OfShortReal theOther) { TShort_Array1OfShortReal ret = new TShort_Array1OfShortReal(OCCwrapJavaJNI.TShort_Array1OfShortReal_Assign(swigCPtr, this, TShort_Array1OfShortReal.getCPtr(theOther), theOther), false, this); return ret; } public TShort_Array1OfShortReal Move( TShort_Array1OfShortReal theOther) { TShort_Array1OfShortReal ret = new TShort_Array1OfShortReal(OCCwrapJavaJNI.TShort_Array1OfShortReal_Move(swigCPtr, this, TShort_Array1OfShortReal.getCPtr(theOther), theOther), false, this); return ret; } public float First() { return OCCwrapJavaJNI.TShort_Array1OfShortReal_First(swigCPtr, this); } public float[] ChangeFirst() {return OCCwrapJavaJNI.TShort_Array1OfShortReal_ChangeFirst(swigCPtr, this);} public float Last() { return OCCwrapJavaJNI.TShort_Array1OfShortReal_Last(swigCPtr, this); } public float[] ChangeLast() {return OCCwrapJavaJNI.TShort_Array1OfShortReal_ChangeLast(swigCPtr, this);} public float Value(int theIndex) { return OCCwrapJavaJNI.TShort_Array1OfShortReal_Value(swigCPtr, this, theIndex); } public float[] ChangeValue(int theIndex) {return OCCwrapJavaJNI.TShort_Array1OfShortReal_ChangeValue(swigCPtr, this, theIndex);} public void SetValue(int theIndex, float theItem) { OCCwrapJavaJNI.TShort_Array1OfShortReal_SetValue(swigCPtr, this, theIndex, theItem ); } public void Resize(int theLower, int theUpper, long theToCopyData) { OCCwrapJavaJNI.TShort_Array1OfShortReal_Resize(swigCPtr, this, theLower, theUpper, theToCopyData); } }
[ "agostino.demarco@unina.it" ]
agostino.demarco@unina.it
2c2587d94eef1284abdef7ac6ac203b600092f79
fa93c9be2923e697fb8a2066f8fb65c7718cdec7
/sources/com/google/android/gms/internal/ads/zzbmj.java
99dc5f36e257333bf034a40c364a07a3ab8414df
[]
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
2,210
java
package com.google.android.gms.internal.ads; import com.google.android.gms.common.util.Clock; import java.util.concurrent.Executor; import org.json.JSONException; import org.json.JSONObject; public final class zzbmj implements zzqu { private final Clock zzbpw; private boolean zzbvt = false; private zzbfq zzdgc; private final zzbly zzfmh; private final Executor zzfmk; private zzbmc zzfmm = new zzbmc(); private boolean zzfnf = false; public zzbmj(Executor executor, zzbly zzbly, Clock clock) { this.zzfmk = executor; this.zzfmh = zzbly; this.zzbpw = clock; } private final void zzahb() { try { JSONObject zza = this.zzfmh.zzj(this.zzfmm); if (this.zzdgc != null) { this.zzfmk.execute(new Runnable(this, zza) { // from class: com.google.android.gms.internal.ads.zzbmm private final JSONObject zzfmf; private final zzbmj zzfng; { this.zzfng = r1; this.zzfmf = r2; } @Override // java.lang.Runnable public final void run() { this.zzfng.zzi(this.zzfmf); } }); } } catch (JSONException e) { zzaxy.zza("Failed to call video active view js", e); } } public final void disable() { this.zzbvt = false; } public final void enable() { this.zzbvt = true; zzahb(); } @Override // com.google.android.gms.internal.ads.zzqu public final void zza(zzqr zzqr) { zzbmc zzbmc = this.zzfmm; zzbmc.zzbrk = this.zzfnf ? false : zzqr.zzbrk; zzbmc.timestamp = this.zzbpw.elapsedRealtime(); this.zzfmm.zzfmw = zzqr; if (this.zzbvt) { zzahb(); } } public final void zzbf(boolean z) { this.zzfnf = z; } public final void zzg(zzbfq zzbfq) { this.zzdgc = zzbfq; } public final /* synthetic */ void zzi(JSONObject jSONObject) { this.zzdgc.zza("AFMA_updateActiveView", jSONObject); } }
[ "auchhunter@gmail.com" ]
auchhunter@gmail.com
bd267dc7ee6a9d8c439e01b1d3228fa41a9eb83b
9926a6a4ac88171c98b07b848f5861728fd18239
/.history/assignment8_20211031172903.java
61a6b97705fcf683f51fb6478b4b5e02de4f830d
[]
no_license
magikflowz/JavaAssignments
4dadee2f0f23d581f94c998680ab188c1247013c
a4f01f60cedd08dd216841ba98fadac9c09bbe76
refs/heads/master
2023-08-28T13:08:43.877417
2021-11-02T10:47:55
2021-11-02T10:47:55
423,601,478
0
0
null
null
null
null
UTF-8
Java
false
false
1,826
java
/* Programming Assignment 8. CSET 1200. * University of Toledo. * Instructor: Jared Oluoch, Ph.D. * Due Date: Sunday October 31, 2021 at 11:59 PM. * Total Points:20 */ /* Your program must compile and run to get credit. * If your program does not compile, you may get 0. * If you copy from your classmate, both of you get 0. * If you copy from a website, you get 0. * Your program must have the following information at the top. # Name : Your First and Last Name # Class: CSET 1200 # Instructor: Dr. Jared Oluoch # Programming Assignment: 8 # Date: MMDDYY # Summary: A brief description of what the program does. # You must put this line as a comment at the top of your Java source file. “This code is my own work. I did not get any help from any online source such as chegg.com; from a classmate, or any other person other than the instructor or TA for this course. I understand that getting outside help from this course other than from the instructor or TA will result in a grade of 0 in this assignment and other disciplinary actions for academic dishonesty.” */ import java.util.*; public class assignment8{ public static void main(String[] args){ Scanner keyboard = new Scanner(System.in); String Name; int Income; String Status; taxfilling taxInfo = new taxfilling(); System.out.print("What is your name: "); Name = keyboard.next(); System.out.println("What is annual income: "); Income = keyboard.nextInt(); System.out.println("Enter 0 - Single, '\n' 2 - head of household ' 3 - married filling jointly "\n" 4 - married filling "\n" Enter your option: "); Status = keyboard.next(); if(Status.equals("0")){ taxinfo.single(name, Income, status); } } }
[ "75277480+ImNotMagik@users.noreply.github.com" ]
75277480+ImNotMagik@users.noreply.github.com
d541b11f5f3b94fc6bfea477c77fb4954f64bcdb
0af8b92686a58eb0b64e319b22411432aca7a8f3
/large-multiproject/project39/src/main/java/org/gradle/test/performance39_1/Production39_96.java
c59a7de5abe6b140a5e19b9bf1671a465af728a4
[]
no_license
gradle/performance-comparisons
b0d38db37c326e0ce271abebdb3c91769b860799
e53dc7182fafcf9fedf07920cbbea8b40ee4eef4
refs/heads/master
2023-08-14T19:24:39.164276
2022-11-24T05:18:33
2022-11-24T05:18:33
80,121,268
17
15
null
2022-09-30T08:04:35
2017-01-26T14:25:33
null
UTF-8
Java
false
false
302
java
package org.gradle.test.performance39_1; public class Production39_96 extends org.gradle.test.performance13_1.Production13_96 { private final String property; public Production39_96() { this.property = "foo"; } public String getProperty() { return property; } }
[ "cedric.champeau@gmail.com" ]
cedric.champeau@gmail.com
447a41d3f113914485a8be98569c4a30e36cfa0d
c753b739b8e5484c0251113b797c442ef0b3bb49
/src/org/greatfree/cache/factory/StoreKeyCreator.java
904cfeed9831eb3b859f5a52df4dc0a5dd81c147
[]
no_license
640351963/Wind
144c0e9e9f3fdf3ee398f9f1a26a3434ca2dfabf
0493d95a1fa8de2de218e651e8ce16be00b8ba38
refs/heads/master
2023-05-03T03:17:06.737980
2021-05-22T19:24:41
2021-05-22T19:24:41
null
0
0
null
null
null
null
UTF-8
Java
false
false
447
java
package org.greatfree.cache.factory; import org.greatfree.cache.CompoundKeyCreatable; import org.greatfree.util.Tools; // Created: 06/07/2017, Bing Li public class StoreKeyCreator implements CompoundKeyCreatable<String> { @Override public String createCompoundKey(String prefix, String key) { return Tools.getHash(prefix + key); } /* @Override public String createPrefixKey(String prefix) { return Tools.getAHash(prefix); } */ }
[ "bing.li@asu.edu" ]
bing.li@asu.edu
ccde95ccb81a72e64344c57f3d494c7e07b4404c
13ea5da0b7b8d4ba87d622a5f733dcf6b4c5f1e3
/crash-reproduction-ws/results/MOCKITO-21b-3-11-Single_Objective_GGA-WeightedSum/org/mockito/internal/creation/instance/ConstructorInstantiator_ESTest.java
b20fdc783d10ad34d5d579a34add318e2028d1aa
[ "MIT", "CC-BY-4.0" ]
permissive
STAMP-project/Botsing-basic-block-coverage-application
6c1095c6be945adc0be2b63bbec44f0014972793
80ea9e7a740bf4b1f9d2d06fe3dcc72323b848da
refs/heads/master
2022-07-28T23:05:55.253779
2022-04-20T13:54:11
2022-04-20T13:54:11
285,771,370
0
0
null
null
null
null
UTF-8
Java
false
false
964
java
/* * This file was automatically generated by EvoSuite * Tue Mar 31 13:03:04 UTC 2020 */ package org.mockito.internal.creation.instance; import org.junit.Test; import static org.junit.Assert.*; import static org.evosuite.runtime.EvoAssertions.*; import org.evosuite.runtime.EvoRunner; import org.evosuite.runtime.EvoRunnerParameters; import org.junit.runner.RunWith; import org.mockito.internal.creation.instance.ConstructorInstantiator; @RunWith(EvoRunner.class) @EvoRunnerParameters(useVFS = true, useJEE = true) public class ConstructorInstantiator_ESTest extends ConstructorInstantiator_ESTest_scaffolding { @Test(timeout = 4000) public void test0() throws Throwable { Object object0 = new Object(); ConstructorInstantiator constructorInstantiator0 = new ConstructorInstantiator(object0); Class<Integer> class0 = Integer.class; // Undeclared exception! constructorInstantiator0.newInstance((Class<?>) class0); } }
[ "pouria.derakhshanfar@gmail.com" ]
pouria.derakhshanfar@gmail.com
76989523e1bd03ebce93b2f615824163877d9fdc
647ec12ce50f06e7380fdbfb5b71e9e2d1ac03b4
/com.tencent.minihd.qq/assets/exlibs.1.jar/classes.jar/tencent/im/oidb/cmd0x799/oidb_0x799.java
057fd5039d2e7e6d535db83aaff5c35bc17a9fee
[]
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
282
java
package tencent.im.oidb.cmd0x799; public final class oidb_0x799 {} /* Location: L:\local\mybackup\temp\qq_apk\com.tencent.minihd.qq\assets\exlibs.1.jar\classes.jar * Qualified Name: tencent.im.oidb.cmd0x799.oidb_0x799 * JD-Core Version: 0.7.0.1 */
[ "98632993+tsuzcx@users.noreply.github.com" ]
98632993+tsuzcx@users.noreply.github.com
167432b2ae22ce40c85903233e3f8f7fb284da16
f37e90775a158ea0ae644e334eac5bba341f4989
/Java+/Libs+/Lucene+/Lucene9/test/lucene9/indexing/reader/IterateAllTermsTest.java
bda69a3999495e631810c6d3159fb4baf6fbfac6
[]
no_license
Aleks-Ya/yaal_examples
0087bbaf314ca5127051c93b89c8fc2dcd14c1e3
ec282968abf1b86e54fc2116c39f2d657b51baac
refs/heads/master
2023-09-01T07:40:44.404550
2023-08-27T15:24:34
2023-08-29T22:01:46
14,327,752
4
2
null
2021-06-16T20:39:19
2013-11-12T09:26:08
Java
UTF-8
Java
false
false
1,415
java
package lucene9.indexing.reader; import lucene9.IndexAssistant; import org.apache.lucene.index.DirectoryReader; import org.apache.lucene.util.BytesRef; import org.junit.jupiter.api.Test; import java.io.IOException; import java.util.ArrayList; import java.util.List; import static org.assertj.core.api.Assertions.assertThat; class IterateAllTermsTest { @Test void test() throws IOException { var fieldName = "text"; try (var assistant = IndexAssistant.create().addDoc(fieldName, List.of("John drinks water.", "Mary eats a cake."))) { var directory = assistant.getDirectory(); var actTermList = new ArrayList<String>(); try (var reader = DirectoryReader.open(directory)) { for (var context : reader.leaves()) { var leafReader = context.reader(); var terms = leafReader.terms(fieldName); if (terms != null) { var termsEnum = terms.iterator(); BytesRef term; while ((term = termsEnum.next()) != null) { actTermList.add(term.utf8ToString()); } } } } assertThat(actTermList).containsExactlyInAnyOrder( "john", "drinks", "water", "mary", "eats", "a", "cake"); } } }
[ "ya_al@bk.ru" ]
ya_al@bk.ru
b2a8ed4955e52718c34eef4ff712a35f96e4b332
2ca93846ab8f638a7d8cd80f91566ee3632cf186
/Entire Dataset/1-21/disc/TournamentShow.java
bd7f3a473a7b3a53e4e422b7ca4d5ec83938da5b
[ "MIT" ]
permissive
hjc851/SourceCodePlagiarismDetectionDataset
729483c3b823c455ffa947fc18d6177b8a78a21f
f67bc79576a8df85e8a7b4f5d012346e3a76db37
refs/heads/master
2020-07-05T10:48:29.980984
2019-08-15T23:51:55
2019-08-15T23:51:55
202,626,196
0
0
null
null
null
null
UTF-8
Java
false
false
270
java
package disc; public abstract class TournamentShow { public synchronized String nicky() { return this.information; } public synchronized double hours() { return this.moment; } protected double moment = 0.0; protected String information = null; }
[ "hayden.cheers@me.com" ]
hayden.cheers@me.com
18ce4d111a91f1767e3d4d6e2b6abb53eb71f27c
be73270af6be0a811bca4f1710dc6a038e4a8fd2
/crash-reproduction-moho/results/MOCKITO-7b-7-11-NSGA_II-LineCoverage:ExceptionType:StackTraceSimilarity/org/mockito/internal/handler/InvocationNotifierHandler_ESTest_scaffolding.java
1d16799990020f14278fe08fda501d4b2f6e23a3
[]
no_license
STAMP-project/Botsing-multi-objectivization-using-helper-objectives-application
cf118b23ecb87a8bf59643e42f7556b521d1f754
3bb39683f9c343b8ec94890a00b8f260d158dfe3
refs/heads/master
2022-07-29T14:44:00.774547
2020-08-10T15:14:49
2020-08-10T15:14:49
285,804,495
0
0
null
null
null
null
UTF-8
Java
false
false
458
java
/** * Scaffolding file used to store all the setups needed to run * tests automatically generated by EvoSuite * Mon Apr 06 09:49:50 UTC 2020 */ package org.mockito.internal.handler; import org.evosuite.runtime.annotation.EvoSuiteClassExclude; import org.junit.BeforeClass; import org.junit.Before; import org.junit.After; @EvoSuiteClassExclude public class InvocationNotifierHandler_ESTest_scaffolding { // Empty scaffolding for empty test suite }
[ "pouria.derakhshanfar@gmail.com" ]
pouria.derakhshanfar@gmail.com
346c085e18ddd4baad8a55637107a1b008ca583c
f11e4e1538589f1f56184745e5af7f7ba06a306b
/MVC-Proj023-Interceptors/src/main/java/com/nt/interceptor/TimeOutCheckInterceptor.java
d3c5f17d696fdb1e1ba70cc536bdb8d7f1348287
[]
no_license
varunraj2297/SpringFrameWorkWS
0473f140f7fd56a92402d69c9274a4c585ca51e8
16f54fa282710983e6714abb7dfe07c7f953d0de
refs/heads/master
2022-12-25T04:20:57.253135
2020-03-03T07:19:15
2020-03-03T07:19:15
176,875,084
0
0
null
2022-11-24T08:37:32
2019-03-21T05:19:19
Java
UTF-8
Java
false
false
766
java
package com.nt.interceptor; import java.util.Calendar; import javax.servlet.RequestDispatcher; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; import org.springframework.web.servlet.HandlerInterceptor; public class TimeOutCheckInterceptor implements HandlerInterceptor { @Override public boolean preHandle(HttpServletRequest request, HttpServletResponse response, Object handler) throws Exception { Calendar calendar=null; int hour=0; RequestDispatcher rd=null; calendar=Calendar.getInstance(); hour=calendar.get(Calendar.HOUR_OF_DAY); if(hour<13 || hour>=16) { rd=request.getRequestDispatcher("/timeout.jsp"); rd.forward(request, response); return false; } return true; } }
[ "varunraj2297@gmail.com" ]
varunraj2297@gmail.com
84000ce93e9bf7f4b86f4d59e85a05b57b0b75be
bead07e917a4deb98c962fb95e01a45692136b16
/src/tc/input/Keyboard.java
02f2cdfc663f147c6a5a4d2cf5ea15ee51efa080
[]
no_license
JamiePurchase/TerrorCrusade
e92f0614e4dacaed7e4a50495ae9ea10c9f07c05
2386988995e396b56541dc36afc8694aa1815163
refs/heads/master
2021-01-22T09:17:47.516173
2015-02-14T15:29:47
2015-02-14T15:29:47
30,796,385
0
0
null
null
null
null
UTF-8
Java
false
false
1,211
java
package tc.input; import java.awt.event.KeyEvent; import java.awt.event.KeyListener; public class Keyboard implements KeyListener { private static String keyPressed = "None"; public static String getKeyPressed() { return keyPressed; } public void keyTyped(KeyEvent e) { //System.out.println("Key typed: " + e.getKeyChar()); } public void keyPressed(KeyEvent e) { //System.out.println("Key pressed: " + e.getKeyChar()); if(e.getKeyCode() == KeyEvent.VK_ENTER){keyPressed = "Enter";} if(e.getKeyCode() == KeyEvent.VK_SPACE){keyPressed = "Space";} if(e.getKeyCode() == KeyEvent.VK_ESCAPE){keyPressed = "Escape";} if(e.getKeyCode() == KeyEvent.VK_UP){keyPressed = "Up";} if(e.getKeyCode() == KeyEvent.VK_DOWN){keyPressed = "Down";} if(e.getKeyCode() == KeyEvent.VK_LEFT){keyPressed = "Left";} if(e.getKeyCode() == KeyEvent.VK_RIGHT){keyPressed = "Right";} if(e.getKeyCode() == KeyEvent.VK_D){keyPressed = "D";} } public void keyReleased(KeyEvent e) { //System.out.println("Key released: " + e.getKeyChar()); } public static void setKeyDone() { keyPressed = "none"; } }
[ "jamie.purchase@medicapp.com" ]
jamie.purchase@medicapp.com
4988a67b1f8ec96ee4092f833db1c2b0086811d7
90f17cd659cc96c8fff1d5cfd893cbbe18b1240f
/src/main/java/com/facebook/react/bridge/AssertionException.java
95bc7357d45f43a996c1dfd564d346a5276f36a2
[]
no_license
redpicasso/fluffy-octo-robot
c9b98d2e8745805edc8ddb92e8afc1788ceadd08
b2b62d7344da65af7e35068f40d6aae0cd0835a6
refs/heads/master
2022-11-15T14:43:37.515136
2020-07-01T22:19:16
2020-07-01T22:19:16
276,492,708
0
0
null
null
null
null
UTF-8
Java
false
false
174
java
package com.facebook.react.bridge; public class AssertionException extends RuntimeException { public AssertionException(String str) { super(str); } }
[ "aaron@goodreturn.org" ]
aaron@goodreturn.org
66053b73aa3ce550a31357265cf4b7c65a1bbdaa
4bf467c2ae1fee1b5db5f6fb65e8c279c551f7f9
/src/main/java/com/zshnb/ballplatform/controller/backend/AdminFeedbackController.java
370caab553974f863c4d67728d4a0043043cc9c1
[]
no_license
chenxin360/ball-platform
24f71a5fe9066db9442d88790c77e36df181cffd
67919a4aafdbf7fcdcc0647d5dc37559b7a18983
refs/heads/master
2022-06-13T13:18:52.097957
2020-05-06T10:55:50
2020-05-06T10:55:50
null
0
0
null
null
null
null
UTF-8
Java
false
false
1,394
java
package com.zshnb.ballplatform.controller.backend; import com.zshnb.ballplatform.common.Response; import com.zshnb.ballplatform.entity.Coach; import com.zshnb.ballplatform.entity.Feedback; import com.zshnb.ballplatform.request.backend.ListCoachRequest; import com.zshnb.ballplatform.service.inter.ICoachService; import com.zshnb.ballplatform.service.inter.IFeedbackService; import com.zshnb.ballplatform.validation.CoachValidation; import java.util.List; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.web.bind.annotation.DeleteMapping; import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.PathVariable; import org.springframework.web.bind.annotation.PostMapping; import org.springframework.web.bind.annotation.PutMapping; import org.springframework.web.bind.annotation.RequestBody; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RestController; /** * <p> * 前端控制器 * </p> * * @author zsh * @since 2020-04-27 */ @RestController @RequestMapping("/backend/feedback") public class AdminFeedbackController { @Autowired private IFeedbackService feedbackService; @PostMapping("/list") public Response<List<Feedback>> list(@RequestBody ListCoachRequest request) { return feedbackService.listFeedbacks(request); } }
[ "a857681664@gmail.com" ]
a857681664@gmail.com
32cb32e0f0e09cda07e49cfdd3a0165ae0292959
7a59674f00b9b6a9b6ca3baa0eca5679f16b566a
/demo-data-jpa/src/main/java/demo/domain/ReviewDetails.java
aace715d7f669bf857284b85bab0aad5dcccceea
[ "Apache-2.0" ]
permissive
crsmejia93/spring-boot-samples
d8ae2ebb5dd449a25eb19b6fb53d88fae3902e8b
d4d43f131fa576c3dc7a036568ada5fdbddcec7d
refs/heads/master
2020-06-01T13:01:55.821348
2019-06-07T20:08:39
2019-06-07T20:08:39
190,788,185
0
0
Apache-2.0
2019-06-07T18:06:17
2019-06-07T18:06:17
null
UTF-8
Java
false
false
1,621
java
/* * Copyright 2012-2013 the original author or authors. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package demo.domain; import java.io.Serializable; import java.util.Date; public class ReviewDetails implements Serializable { private static final long serialVersionUID = 1L; private Rating rating; private Date checkInDate; private TripType tripType; private String title; private String details; public ReviewDetails() { } public Rating getRating() { return this.rating; } public void setRating(Rating rating) { this.rating = rating; } public Date getCheckInDate() { return this.checkInDate; } public void setCheckInDate(Date checkInDate) { this.checkInDate = checkInDate; } public TripType getTripType() { return this.tripType; } public void setTripType(TripType tripType) { this.tripType = tripType; } public String getTitle() { return this.title; } public void setTitle(String title) { this.title = title; } public String getDetails() { return this.details; } public void setDetails(String details) { this.details = details; } }
[ "jose.diaz@joedayz.pe" ]
jose.diaz@joedayz.pe
242b51819367a26d8b3602f63d0133f90f3a99f2
e8af9448b9ae9244fdd1d47483730df4ef0a0ef8
/replit_2MethodsOnwards/CustomMethods/CoverString.java
a30b188992d6f9bc1b9d39e2504665544bfa9274
[]
no_license
ShaazShaaz/JavaPragramming_B23
83b756967e2d9c16d617e650c6f8c13db1232bf2
432d3a5f02fa1004927c6a40f44027fe9f986141
refs/heads/master
2023-07-09T18:02:32.929144
2021-08-19T20:11:14
2021-08-19T20:11:14
395,329,318
0
0
null
null
null
null
UTF-8
Java
false
false
965
java
package CustomMethods; public class CoverString { /* The coverString method will take 2 string parameters from the caller. Your job is to write an important code that will : to search and find each appearance of coverME within main then surround it with square brackets [coverMe] if you cannot find the coverME within main then just return whole main itself covered [main]. keep in mind that coverME value can be of any length. Examples: coverString("java methods", "me") ) ; ==> "java [me]thods" */ public static void main(String[] args) { String str="java methods"; String s="me"; System.out.println(coverString(str, s)); } public static String coverString(String main, String coverME){ String result=""; if (!main.contains(coverME)){ result="["+ main+"]"; } else { result=main.replaceAll(coverME,"["+coverME+"]"); } return result; } }
[ "shaziasenol@gmail.com" ]
shaziasenol@gmail.com
3f2b5f3e499856b61519a2ab9f8cb86b755118d1
3c20f19f5a1a2d4e216d06ce9827a88038589997
/JPAServlet/src/ConsoleClient.java
f2e67c489438824d5b7ddd382299cd2a8281f08d
[]
no_license
justutkarsh/JEE6_July_09_to_13_2012
23adb05da826aff531702697795dcfd4463e3c4b
57e877aeb01b4969c031b58b5617f6fc63d27c77
refs/heads/master
2021-01-01T19:56:39.667405
2012-07-16T06:13:44
2012-07-16T06:13:44
null
0
0
null
null
null
null
UTF-8
Java
false
false
864
java
import javax.persistence.EntityManager; import javax.persistence.EntityManagerFactory; import javax.persistence.Persistence; import javax.persistence.Query; import com.durasoft.domain.User; public class ConsoleClient { public static void main(String[] args) { EntityManagerFactory emf = Persistence.createEntityManagerFactory("JPAServletLab"); EntityManager em = emf.createEntityManager(); Query query = em.createQuery("select u from User u where " + "u.userName=:p1 and u.password=:p2"); query.setParameter("p1", "sam23"); query.setParameter("p2", "abcde"); User u = (User)query.getResultList().get(0); System.out.println(u.getUserType().getDescription()); query = em.createQuery("select p from Person p " + "where p.user.id=:p1"); query.setParameter("p1", u.getId()); System.out.println(query.getResultList()); em.close(); } }
[ "iamprabhu@yahoo.com" ]
iamprabhu@yahoo.com
e8696562de0738d353747f0182390b674ed32227
9ce1a36af20dd7106d176f59279d3d75979ea620
/core/src/main/java/com/huawei/openstack4j/openstack/vpc/v1/domain/Subnet.java
1745699e5813d15a71e9ef134eb37a434f79ab36
[ "Apache-2.0" ]
permissive
githubprogramman/huaweicloud-sdk-java
de46e148b5385cbc2470d425e583b94d38e9eff4
cb66af0f70ce3eb0799f020b7f50cd665bffb7f1
refs/heads/master
2020-04-17T21:28:55.569115
2019-01-03T14:55:27
2019-01-03T14:55:27
null
0
0
null
null
null
null
UTF-8
Java
false
false
3,393
java
/******************************************************************************* * Copyright 2018 HuaWei and OTC * * 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.huawei.openstack4j.openstack.vpc.v1.domain; import java.util.List; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonRootName; import com.huawei.openstack4j.model.ModelEntity; import com.huawei.openstack4j.openstack.common.ListResult; import lombok.AllArgsConstructor; import lombok.Builder; import lombok.Getter; import lombok.NoArgsConstructor; import lombok.ToString; /** * Model represent attributes of vpc subnet * * @author ChangjunZhao * @date 2018-03-25 */ @Getter @ToString @Builder(toBuilder = true) @NoArgsConstructor @AllArgsConstructor @JsonRootName("subnet") public class Subnet implements ModelEntity{ /** * */ private static final long serialVersionUID = 1L; private String id; /** * vpc name */ private String name; /** * vpc subnet cidr */ private String cidr; /** * Subnet gateway */ @JsonProperty("gateway_ip") private String gatewayIp; /** * Whether the dhcp function is enabled on the subnet */ @JsonProperty("dhcp_enable") private boolean dhcpEnable; /** * Subnet dns server address 1 */ @JsonProperty("primary_dns") private String primaryDns; /** * Subnet dns server address 2 */ @JsonProperty("secondary_dns") private String secondaryDns; /** * Subnet dns server address list set */ private List<String> dnsList; /** * Available partition ID where the subnet is located */ @JsonProperty("availability_zone") private String availabilityZone; /** * The VPC ID of the subnet */ @JsonProperty("vpc_id") private String vpcId; /** * vpc status */ private String status; /** * network (Openstack neutron) id */ @JsonProperty("neutron_network_id") private String neutronNetworkId; /** * subnet (Openstack neutron) id */ @JsonProperty("neutron_subnet_id") private String neutronSubnetId; public static class Subnets extends ListResult<Subnet> { private static final long serialVersionUID = 1L; @JsonProperty("subnets") private List<Subnet> subnets; public List<Subnet> value() { return subnets; } } }
[ "289228042@qq.com" ]
289228042@qq.com
1bfcef6bb1255faa14a97c464a719b2b6e53a305
b7b870158ac741a303b854876f73173b3c984730
/1.JavaSyntax/src/com/codegym/task/task10/task1019/Solution.java
725b6bdf115b4b1c76152cab37ff58ccabf350a7
[]
no_license
KrisTovski/CodeGym
b788c65b0ec2cc71c7a75dfd39b4221b571090e4
74be0793b2b1f8e9e7dc576e2cb5d25da505417a
refs/heads/master
2021-12-13T01:22:09.284904
2021-11-28T19:23:57
2021-11-28T19:23:57
246,921,433
0
0
null
null
null
null
UTF-8
Java
false
false
1,194
java
package com.codegym.task.task10.task1019; import java.io.*; import java.util.HashMap; import java.util.Map; /* Functionality is not enough! */ public class Solution { public static void main(String[] args) throws IOException { BufferedReader reader = new BufferedReader(new InputStreamReader(System.in)); HashMap<String, Integer> map = new HashMap<>(); String id = ""; String name = ""; try { while (true) { id = reader.readLine(); if (id.isEmpty()) { break; } name = reader.readLine(); if (name.isEmpty()) { //map.put(name, Integer.parseInt(id)); System.out.println(id); //System.out.println("Id=" + id + " Name=" + name); break; } map.put(name, Integer.parseInt(id)); } } catch (Exception e) { } finally { for (Map.Entry<String, Integer> entry : map.entrySet()) { System.out.println(entry.getValue()+ " " + entry.getKey()); } } } }
[ "kfilak@onet.eu" ]
kfilak@onet.eu
bb22f6e50677c612c5bfbb860ee72300b492e3b1
40d844c1c780cf3618979626282cf59be833907f
/src/testcases/CWE36_Absolute_Path_Traversal/CWE36_Absolute_Path_Traversal__getQueryString_Servlet_66b.java
c0fada294b76b77f0978a0326066300db210da29
[]
no_license
rubengomez97/juliet
f9566de7be198921113658f904b521b6bca4d262
13debb7a1cc801977b9371b8cc1a313cd1de3a0e
refs/heads/master
2023-06-02T00:37:24.532638
2021-06-23T17:22:22
2021-06-23T17:22:22
379,676,259
1
0
null
null
null
null
UTF-8
Java
false
false
5,888
java
/* TEMPLATE GENERATED TESTCASE FILE Filename: CWE36_Absolute_Path_Traversal__getQueryString_Servlet_66b.java Label Definition File: CWE36_Absolute_Path_Traversal.label.xml Template File: sources-sink-66b.tmpl.java */ /* * @description * CWE: 36 Absolute Path Traversal * BadSource: getQueryString_Servlet Parse id param out of the URL query string (without using getParameter()) * GoodSource: A hardcoded string * Sinks: readFile * BadSink : read line from file from disk * Flow Variant: 66 Data flow: data passed in an array from one method to another in different source files in the same package * * */ package testcases.CWE36_Absolute_Path_Traversal; import testcasesupport.*; import java.io.*; import javax.servlet.http.*; import java.util.logging.Level; public class CWE36_Absolute_Path_Traversal__getQueryString_Servlet_66b { public void badSink(String dataArray[] , HttpServletRequest request, HttpServletResponse response) throws Throwable { String data = dataArray[2]; /* POTENTIAL FLAW: unvalidated or sandboxed value */ if (data != null) { File file = new File(data); FileInputStream streamFileInputSink = null; InputStreamReader readerInputStreamSink = null; BufferedReader readerBufferdSink = null; if (file.exists() && file.isFile()) { try { streamFileInputSink = new FileInputStream(file); readerInputStreamSink = new InputStreamReader(streamFileInputSink, "UTF-8"); readerBufferdSink = new BufferedReader(readerInputStreamSink); IO.writeLine(readerBufferdSink.readLine()); } catch (IOException exceptIO) { IO.logger.log(Level.WARNING, "Error with stream reading", exceptIO); } finally { /* Close stream reading objects */ try { if (readerBufferdSink != null) { readerBufferdSink.close(); } } catch (IOException exceptIO) { IO.logger.log(Level.WARNING, "Error closing BufferedReader", exceptIO); } try { if (readerInputStreamSink != null) { readerInputStreamSink.close(); } } catch (IOException exceptIO) { IO.logger.log(Level.WARNING, "Error closing InputStreamReader", exceptIO); } try { if (streamFileInputSink != null) { streamFileInputSink.close(); } } catch (IOException exceptIO) { IO.logger.log(Level.WARNING, "Error closing FileInputStream", exceptIO); } } } } } /* goodG2B() - use goodsource and badsink */ public void goodG2BSink(String dataArray[] , HttpServletRequest request, HttpServletResponse response) throws Throwable { String data = dataArray[2]; /* POTENTIAL FLAW: unvalidated or sandboxed value */ if (data != null) { File file = new File(data); FileInputStream streamFileInputSink = null; InputStreamReader readerInputStreamSink = null; BufferedReader readerBufferdSink = null; if (file.exists() && file.isFile()) { try { streamFileInputSink = new FileInputStream(file); readerInputStreamSink = new InputStreamReader(streamFileInputSink, "UTF-8"); readerBufferdSink = new BufferedReader(readerInputStreamSink); IO.writeLine(readerBufferdSink.readLine()); } catch (IOException exceptIO) { IO.logger.log(Level.WARNING, "Error with stream reading", exceptIO); } finally { /* Close stream reading objects */ try { if (readerBufferdSink != null) { readerBufferdSink.close(); } } catch (IOException exceptIO) { IO.logger.log(Level.WARNING, "Error closing BufferedReader", exceptIO); } try { if (readerInputStreamSink != null) { readerInputStreamSink.close(); } } catch (IOException exceptIO) { IO.logger.log(Level.WARNING, "Error closing InputStreamReader", exceptIO); } try { if (streamFileInputSink != null) { streamFileInputSink.close(); } } catch (IOException exceptIO) { IO.logger.log(Level.WARNING, "Error closing FileInputStream", exceptIO); } } } } } }
[ "you@example.com" ]
you@example.com
96ee1a7197fc48e89490888e46ad531d2196eb25
fa91450deb625cda070e82d5c31770be5ca1dec6
/Diff-Raw-Data/34/34_526bcec1d8618af6dc604b08c301337d0a9d0e7a/GenericGroupFigure/34_526bcec1d8618af6dc604b08c301337d0a9d0e7a_GenericGroupFigure_t.java
be71aa6c3a56b12bdb823daca70eeb3668739f71
[]
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
1,805
java
/******************************************************************************* * Copyright (c) 2001, 2006 IBM Corporation and others. * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License v1.0 * which accompanies this distribution, and is available at * http://www.eclipse.org/legal/epl-v10.html * * Contributors: * IBM Corporation - initial API and implementation *******************************************************************************/ package org.eclipse.wst.xsd.editor.internal.design.figures; import org.eclipse.draw2d.Figure; import org.eclipse.draw2d.geometry.Dimension; import org.eclipse.swt.graphics.Image; import org.eclipse.wst.xsd.editor.internal.design.layouts.ModelGroupLayout; public class GenericGroupFigure extends Figure { protected CenteredIconFigure centeredIconFigure; protected Figure contentFigure; public GenericGroupFigure() { super(); setLayoutManager(new ModelGroupLayout(true)); centeredIconFigure = new CenteredIconFigure(); centeredIconFigure.setPreferredSize(new Dimension(16, 16)); add(centeredIconFigure); contentFigure = new Figure(); contentFigure.setLayoutManager(new ModelGroupLayout(false, 0)); add(contentFigure); } public void setIconFigure(Image image) { centeredIconFigure.image = image; } public CenteredIconFigure getTargetFigure() { return centeredIconFigure; } public CenteredIconFigure getIconFigure() { return centeredIconFigure; } public Figure getContentFigure() { return contentFigure; } public void setToolTipText(String text) { centeredIconFigure.setToolTipText(text); } }
[ "yuzhongxing88@gmail.com" ]
yuzhongxing88@gmail.com
c963f4c717b1eab61b33807a16f03754385a950e
23812c863f6c8e393531401d70f6ea70f1da3e27
/mall-product/src/main/java/com/xpcf/mall/product/service/CategoryService.java
c9f48acd9d59913cc18e7082bd061be3ebe989f4
[ "MIT" ]
permissive
pascalcpp/mall
95d02a950f9f2a8ce84adf7c08687d17e3780174
4fb6132d576a0395ae2e9f1b1047982e75e9a9ce
refs/heads/master
2023-05-06T01:01:13.799615
2021-06-01T09:51:36
2021-06-01T09:51:36
341,478,845
0
0
null
null
null
null
UTF-8
Java
false
false
878
java
package com.xpcf.mall.product.service; import com.baomidou.mybatisplus.extension.service.IService; import com.xpcf.common.utils.PageUtils; import com.xpcf.mall.product.entity.CategoryEntity; import com.xpcf.mall.product.vo.Catalog2VO; import java.util.List; import java.util.Map; /** * 商品三级分类 * * @author xpcf * @email xpcf@gmail.com * @date 2020-12-12 02:06:34 */ public interface CategoryService extends IService<CategoryEntity> { PageUtils queryPage(Map<String, Object> params); List<CategoryEntity> listWithTree(); void removeMenuByIds(List<Long> asList); /** * 找到完整路径 * @param catelogId * @return */ Long[] findCatelogPath(Long catelogId); void updateCascade(CategoryEntity category); List<CategoryEntity> getLevel1Categories(); Map<String, List<Catalog2VO>> getCatalogJson(); }
[ "1287971058@qq.com" ]
1287971058@qq.com
658aa3be70a6a183c056d7076f49d8fc24d19449
513dd083de7730e266edd0f771bd533c79bfda03
/kafka-common/src/main/java/com/networknt/kafka/common/AvroConverter.java
5d420221fe3c7c7e3bf4119bdb026a59e6c5b648
[ "Apache-2.0" ]
permissive
networknt/light-kafka
bc92e011ee500ccc68771583df3100aab2722493
eab17889f41f9f74aa8b4227fa895bf1b3526670
refs/heads/master
2023-09-05T01:05:37.153142
2023-08-17T20:55:56
2023-08-17T20:55:56
257,418,686
5
1
Apache-2.0
2023-05-29T20:21:33
2020-04-20T22:29:12
Java
UTF-8
Java
false
false
1,041
java
package com.networknt.kafka.common; import org.apache.avro.io.DatumWriter; import org.apache.avro.io.NoWrappingJsonEncoder; import org.apache.avro.specific.SpecificDatumWriter; import org.apache.avro.specific.SpecificRecord; import java.io.ByteArrayOutputStream; import java.io.IOException; import java.nio.charset.StandardCharsets; public class AvroConverter { public static String toJson(SpecificRecord record, boolean pretty) { try (ByteArrayOutputStream baos = new ByteArrayOutputStream()) { NoWrappingJsonEncoder jsonEncoder = new NoWrappingJsonEncoder(record.getSchema(), baos, pretty); DatumWriter<SpecificRecord> writer = new SpecificDatumWriter<>(record.getSchema()); writer.write(record, jsonEncoder); jsonEncoder.flush(); baos.flush(); byte[] bytes = baos.toByteArray(); return new String(bytes, StandardCharsets.UTF_8); } catch (IOException e) { e.printStackTrace(); return null; } } }
[ "stevehu@gmail.com" ]
stevehu@gmail.com
a5ace28eddbaa7cca721d25ca09d6a19001f43da
8c745997a86a042148adecdc6511b9840e06c2b5
/ops-domain/src/main/java/cn/fooltech/fool_ops/domain/report/vo/BalanceSheetVo.java
487071643a2f128f4b8cecb047933d7e2f177327
[]
no_license
bulison/test
48166eae90e4cda38acd690725a5e1ae19bacc46
680f85ed942a589655b44b2c426adc48d5374c23
refs/heads/master
2021-01-21T23:09:24.394616
2017-06-23T09:19:51
2017-06-23T09:19:51
95,199,624
0
1
null
null
null
null
UTF-8
Java
false
false
3,491
java
package cn.fooltech.fool_ops.domain.report.vo; import java.io.Serializable; import java.math.BigDecimal; /** * <p>表单传输对象 - 资产负债</p> * * @author xjh * @version 1.0 * @date 2016-02-16 09:34:26 */ public class BalanceSheetVo implements Serializable { private static final long serialVersionUID = -7983453208651558756L; private String assetItem;//资产项目 private Integer assetNumber;//资产行号 private BigDecimal assetPeriodEnd;//资产期未余额 private BigDecimal assetYearBegin;//资产年初余额 private String assetFormula;//资产公式 private String debitItem;//负债项目 private Integer debitNumber;//负债行号 private BigDecimal debitPeriodEnd;//负债期未余额 private BigDecimal debitYearBegin;//负债年初余额 private String debitFormula;//负债公式 private String updateTime;//修改时间戳 private short flag = 0;//查找的是资产还是负债0:资产;1:负债 private String fid; private String periodId;//会计期间ID public String getAssetItem() { return this.assetItem; } public void setAssetItem(String assetItem) { this.assetItem = assetItem; } public Integer getAssetNumber() { return this.assetNumber; } public void setAssetNumber(Integer assetNumber) { this.assetNumber = assetNumber; } public String getAssetFormula() { return this.assetFormula; } public void setAssetFormula(String assetFormula) { this.assetFormula = assetFormula; } public String getDebitItem() { return this.debitItem; } public void setDebitItem(String debitItem) { this.debitItem = debitItem; } public Integer getDebitNumber() { return this.debitNumber; } public void setDebitNumber(Integer debitNumber) { this.debitNumber = debitNumber; } public String getDebitFormula() { return this.debitFormula; } public void setDebitFormula(String debitFormula) { this.debitFormula = debitFormula; } public String getUpdateTime() { return this.updateTime; } public void setUpdateTime(String updateTime) { this.updateTime = updateTime; } public String getFid() { return this.fid; } public void setFid(String fid) { this.fid = fid; } public BigDecimal getAssetPeriodEnd() { return assetPeriodEnd; } public void setAssetPeriodEnd(BigDecimal assetPeriodEnd) { this.assetPeriodEnd = assetPeriodEnd; } public BigDecimal getAssetYearBegin() { return assetYearBegin; } public void setAssetYearBegin(BigDecimal assetYearBegin) { this.assetYearBegin = assetYearBegin; } public BigDecimal getDebitPeriodEnd() { return debitPeriodEnd; } public void setDebitPeriodEnd(BigDecimal debitPeriodEnd) { this.debitPeriodEnd = debitPeriodEnd; } public BigDecimal getDebitYearBegin() { return debitYearBegin; } public void setDebitYearBegin(BigDecimal debitYearBegin) { this.debitYearBegin = debitYearBegin; } public short getFlag() { return flag; } public void setFlag(short flag) { this.flag = flag; } public String getPeriodId() { return periodId; } public void setPeriodId(String periodId) { this.periodId = periodId; } }
[ "julongren@vip.qq.com" ]
julongren@vip.qq.com
315f6bb8827d5ff95c717a213fbdfaed10984408
6c35446feb5baaadf1901a083442e14dc423fc0b
/TestCommon/src/test/java/com/cqx/common/utils/ftp/FtpUtilAutoCloseTest.java
349bb0e630d90351f8fbc4c946205a89e8ae86d6
[ "Apache-2.0" ]
permissive
chenqixu/TestSelf
8e533d2f653828f9f92564c3918041d733505a30
7488d83ffd20734ab5ca431d13fa3c5946493c11
refs/heads/master
2023-09-01T06:18:59.417999
2023-08-21T06:16:55
2023-08-21T06:16:55
75,791,787
3
1
Apache-2.0
2022-03-02T06:47:48
2016-12-07T02:36:58
Java
UTF-8
Java
false
false
3,475
java
package com.cqx.common.utils.ftp; import com.cqx.common.utils.system.SleepUtil; import org.junit.Before; import org.junit.Test; import java.io.IOException; import java.util.concurrent.Callable; import java.util.concurrent.ExecutorService; import java.util.concurrent.Executors; import java.util.concurrent.TimeUnit; import java.util.concurrent.atomic.AtomicInteger; public class FtpUtilAutoCloseTest { private FtpParamCfg ftpParamCfg; private String localFilePath = "d:\\tmp\\data\\dpi\\";//"d:\\Soft\\CLASS\\";//"d:\\tmp\\data\\dpi\\"; private String remoteFilePath = "/bi/user/cqx/data/"; private String localFileName = "sc.txt";//"jdk1.8.0_161.tar.gz";//"sc.txt"; private AtomicInteger cnt = new AtomicInteger(0); @Before public void setUp() throws Exception { ftpParamCfg = new FtpParamCfg("10.1.8.203", 21, "edc_base", "fLyxp1s*", false); } @Test public void uploadMultiActive() throws IOException, InterruptedException { ExecutorService executor = Executors.newFixedThreadPool(10); int cnt = 5; for (int i = 0; i < cnt; i++) { FtpUploadCallable ftpUploadCallable = new FtpUploadCallable(5, FtpMode.ActiveMode); executor.submit(ftpUploadCallable); } executor.shutdown(); executor.awaitTermination(5L, TimeUnit.SECONDS); } @Test public void uploadMultiPassive() throws IOException, InterruptedException { ExecutorService executor = Executors.newFixedThreadPool(10); int cnt = 5; for (int i = 0; i < cnt; i++) { FtpUploadCallable ftpUploadCallable = new FtpUploadCallable(5, FtpMode.PassiveMode); executor.submit(ftpUploadCallable); } executor.shutdown(); executor.awaitTermination(5L, TimeUnit.SECONDS); } @Test public void uploadOnceActive() throws IOException { try (FtpUtilAutoClose ftpUtilAutoClose = new FtpUtilAutoClose((ftpParamCfg))) { // 主动模式 ftpUtilAutoClose.setFtpMode(FtpMode.ActiveMode); // 上传 ftpUtilAutoClose.upload(localFilePath, remoteFilePath, localFileName, localFileName); } } @Test public void uploadOncePassive() throws IOException { try (FtpUtilAutoClose ftpUtilAutoClose = new FtpUtilAutoClose((ftpParamCfg))) { // 被动模式 ftpUtilAutoClose.setFtpMode(FtpMode.PassiveMode); // 上传 ftpUtilAutoClose.upload(localFilePath, remoteFilePath, localFileName, localFileName); } } class FtpUploadCallable implements Callable<Boolean> { int num; FtpMode ftpMode; FtpUploadCallable(int num, FtpMode ftpMode) { this.num = num; this.ftpMode = ftpMode; } @Override public Boolean call() throws Exception { try (FtpUtilAutoClose ftpUtilAutoClose = new FtpUtilAutoClose((ftpParamCfg))) { // 长连接 ftpUtilAutoClose.setLongConnect(true); // 传输模式 ftpUtilAutoClose.setFtpMode(ftpMode); for (int i = 0; i < num; i++) { String remoteFileName = cnt.incrementAndGet() + localFileName; ftpUtilAutoClose.upload(localFilePath, remoteFilePath, localFileName, remoteFileName); } } return null; } } }
[ "13509323824@139.com" ]
13509323824@139.com
8bf81471c38a80b22455403f31502b19326572ea
5f4afbc92a72bd847b8aa9ae95f9be9d706ad7d8
/commons/src/main/java/com/westangel/common/bean/UserProfileDetailResp.java
2828ce6596f36b5bf7dea25208ccf6177b27441b
[]
no_license
331491512/esz
dfc13ba9e142ab1cbacc92cd0bf1b55fec2a05a1
8edd10a74b75d36d3963d2ae64602d02ba548b43
refs/heads/master
2021-04-06T20:31:45.968785
2018-03-16T02:56:36
2018-03-16T02:56:36
125,451,748
1
0
null
null
null
null
UTF-8
Java
false
false
1,700
java
/** * <b>项目名:</b>易随诊<br/> * <b>包名:</b>com.esuizhen.cloudservice.user.bean<br/> * <b>文件名:</b>UserProfileDetailReq.java<br/> * <b>版本信息:</b><br/> * <b>日期:</b>2015年12月10日-下午2:37:50<br/> * <b>Copyright (c)</b> 2015西部天使公司-版权所有<br/> * */ package com.westangel.common.bean; import java.io.Serializable; import com.westangel.common.bean.DoctorProfile; import com.westangel.common.bean.PatientProfile; import com.westangel.common.bean.UserProfile; import com.westangel.common.bean.UserStatisProfile; /** * @ClassName: UserProfileDetailReq * @Description: 用户详细信息获取 * @author YYCHEN * @date 2015年12月10日 下午2:37:50 */ public class UserProfileDetailResp implements Serializable { private static final long serialVersionUID = 1L; private UserProfile userProfile; private DoctorProfile doctorProfile; private PatientProfile patientProfile; private UserStatisProfile statisProfile; public UserStatisProfile getStatisProfile() { return statisProfile; } public void setStatisProfile(UserStatisProfile statisProfile) { this.statisProfile = statisProfile; } public UserProfile getUserProfile() { return userProfile; } public void setUserProfile(UserProfile userProfile) { this.userProfile = userProfile; } public DoctorProfile getDoctorProfile() { return doctorProfile; } public void setDoctorProfile(DoctorProfile doctorProfile) { this.doctorProfile = doctorProfile; } public PatientProfile getPatientProfile() { return patientProfile; } public void setPatientProfile(PatientProfile patientProfile) { this.patientProfile = patientProfile; } }
[ "zhuguo@qgs-china.com" ]
zhuguo@qgs-china.com
41c06b073f6ecac9a1c1c83c7a7a0694727c1859
5c23d6703e3dbfae406315a8fe9dee997e6ec8b6
/jhs-loan-task/src/main/java/com/jhh/jhs/loan/dao/OrderRobotMapper.java
e6962c92204e8efc29c078b6ef2f83c081611661
[]
no_license
soldiers1989/loan-uhs
1dc4e766fce56ca21bc34e5a5b060eaf7116a8b0
77b06a67651898c4f1734e6c323becd0df639c22
refs/heads/master
2020-03-28T09:27:29.670311
2018-06-12T07:53:52
2018-06-12T07:53:52
148,038,503
0
1
null
null
null
null
UTF-8
Java
false
false
181
java
package com.jhh.jhs.loan.dao; import com.jhh.jhs.loan.model.OrderRobot; import tk.mybatis.mapper.common.Mapper; public interface OrderRobotMapper extends Mapper<OrderRobot> { }
[ "xingmin@jinhuhang.com.cn" ]
xingmin@jinhuhang.com.cn
a07f5902eb0780eabc9d533d3bcd558d57c3f9bf
b62c76ab304eaa5d4cfb1d7cddd13dce4a99e258
/library/logBack/logback-1.1.3/logback-core/src/main/java/ch/qos/logback/core/rolling/helper/FileStoreUtil.java
bd8257415e0dcbf00aac5f4fdc13befb6132308e
[ "MIT" ]
permissive
cscfa/bartleby
9fc069ff2fe1e0023355d8d70897b25e1b5f08a2
62a00d8710afc9c698d3336649d8da0fcf79f355
refs/heads/master
2021-01-01T19:30:51.933368
2015-06-27T23:10:10
2015-06-27T23:10:10
35,576,368
1
0
null
null
null
null
UTF-8
Java
false
false
2,338
java
/** * Logback: the reliable, generic, fast and flexible logging framework. * Copyright (C) 1999-2015, QOS.ch. All rights reserved. * * This program and the accompanying materials are dual-licensed under * either the terms of the Eclipse Public License v1.0 as published by * the Eclipse Foundation * * or (per the licensee's choosing) * * under the terms of the GNU Lesser General Public License version 2.1 * as published by the Free Software Foundation. */ package ch.qos.logback.core.rolling.helper; import ch.qos.logback.core.rolling.RolloverFailure; import java.io.File; import java.lang.reflect.Method; /** * A utility class using functionality available since JDK 1.7. * * @author ceki * @since 1.0.10 */ public class FileStoreUtil { static final String PATH_CLASS_STR = "java.nio.file.Path"; static final String FILES_CLASS_STR = "java.nio.file.Files"; /** * This method assumes that both files a and b exists. * * @param a * @param b * @return * @throws Exception */ static public boolean areOnSameFileStore(File a, File b) throws RolloverFailure { if (!a.exists()) { throw new IllegalArgumentException("File [" + a + "] does not exist."); } if (!b.exists()) { throw new IllegalArgumentException("File [" + b + "] does not exist."); } // Implements the following by reflection // Path pathA = a.toPath(); // Path pathB = b.toPath(); // // FileStore fileStoreA = Files.getFileStore(pathA); // FileStore fileStoreB = Files.getFileStore(pathB); // // return fileStoreA.equals(fileStoreB); try { Class<?> pathClass = Class.forName(PATH_CLASS_STR); Class<?> filesClass = Class.forName(FILES_CLASS_STR); Method toPath = File.class.getMethod("toPath"); Method getFileStoreMethod = filesClass.getMethod("getFileStore", pathClass); Object pathA = toPath.invoke(a); Object pathB = toPath.invoke(b); Object fileStoreA = getFileStoreMethod.invoke(null, pathA); Object fileStoreB = getFileStoreMethod.invoke(null, pathB); return fileStoreA.equals(fileStoreB); } catch (Exception e) { throw new RolloverFailure("Failed to check file store equality for [" + a + "] and [" + b + "]", e); } } }
[ "matthieu.vallance@cscfa.fr" ]
matthieu.vallance@cscfa.fr
111ec82c7bf879da851f2d7a5c323e204d7631d7
ddce1fbc658e4bf9d124dc4acfc3914817a580a5
/sources/android/support/p000v4/view/accessibility/AccessibilityManagerCompatKitKat.java
8da671ccc6a5dcdc21e81b231e8a395ed1fc195f
[]
no_license
ShahedSabab/eExpense
1011f833a614c64cbb52a203821e38f18fce8a4f
b85c7ad6ee5ce6ae433a6220df182e14c0ea2d6d
refs/heads/master
2020-12-21T07:39:45.956655
2020-07-13T21:52:04
2020-07-13T21:52:04
235,963,863
0
0
null
null
null
null
UTF-8
Java
false
false
3,076
java
package android.support.p000v4.view.accessibility; import android.annotation.TargetApi; import android.support.annotation.RequiresApi; import android.view.accessibility.AccessibilityManager; import android.view.accessibility.AccessibilityManager.TouchExplorationStateChangeListener; @TargetApi(19) @RequiresApi(19) /* renamed from: android.support.v4.view.accessibility.AccessibilityManagerCompatKitKat */ class AccessibilityManagerCompatKitKat { /* renamed from: android.support.v4.view.accessibility.AccessibilityManagerCompatKitKat$TouchExplorationStateChangeListenerBridge */ interface TouchExplorationStateChangeListenerBridge { void onTouchExplorationStateChanged(boolean z); } /* renamed from: android.support.v4.view.accessibility.AccessibilityManagerCompatKitKat$TouchExplorationStateChangeListenerWrapper */ public static class TouchExplorationStateChangeListenerWrapper implements TouchExplorationStateChangeListener { final Object mListener; final TouchExplorationStateChangeListenerBridge mListenerBridge; public TouchExplorationStateChangeListenerWrapper(Object listener, TouchExplorationStateChangeListenerBridge listenerBridge) { this.mListener = listener; this.mListenerBridge = listenerBridge; } public int hashCode() { if (this.mListener == null) { return 0; } return this.mListener.hashCode(); } public boolean equals(Object o) { if (this == o) { return true; } if (o == null || getClass() != o.getClass()) { return false; } TouchExplorationStateChangeListenerWrapper other = (TouchExplorationStateChangeListenerWrapper) o; if (this.mListener != null) { return this.mListener.equals(other.mListener); } if (other.mListener != null) { return false; } return true; } public void onTouchExplorationStateChanged(boolean enabled) { this.mListenerBridge.onTouchExplorationStateChanged(enabled); } } AccessibilityManagerCompatKitKat() { } public static Object newTouchExplorationStateChangeListener(final TouchExplorationStateChangeListenerBridge bridge) { return new TouchExplorationStateChangeListener() { public void onTouchExplorationStateChanged(boolean enabled) { bridge.onTouchExplorationStateChanged(enabled); } }; } public static boolean addTouchExplorationStateChangeListener(AccessibilityManager manager, Object listener) { return manager.addTouchExplorationStateChangeListener((TouchExplorationStateChangeListener) listener); } public static boolean removeTouchExplorationStateChangeListener(AccessibilityManager manager, Object listener) { return manager.removeTouchExplorationStateChangeListener((TouchExplorationStateChangeListener) listener); } }
[ "59721350+ShahedSabab@users.noreply.github.com" ]
59721350+ShahedSabab@users.noreply.github.com
3b6f27c9864934258f50c22b7a898024e1332e7a
5d8a5c290e9866bff6d2df0c2fe68170d8d346a8
/app/src/main/java/com/hnhy/ylfz/mvp/ui/activity/msg/ActivityMyMessage.java
4b337f9c0b72e203fed07017c5435bd6f35e6bd7
[]
no_license
myteam-gc/app-demo
6873ca823e761c32f528a6c3fa5ddd71b333b995
0969d1217c8c1d29288cebaa974fcf6d32f4f153
refs/heads/master
2020-09-30T12:32:24.531109
2020-04-16T07:46:09
2020-04-16T07:46:09
227,288,037
0
0
null
null
null
null
UTF-8
Java
false
false
2,278
java
package com.hnhy.ylfz.mvp.ui.activity.msg; import android.os.Bundle; import android.support.annotation.Nullable; import android.support.v7.widget.LinearLayoutManager; import android.support.v7.widget.RecyclerView; import android.view.View; import com.hnhy.framework.frame.BaseActivity; import com.hnhy.ylfz.R; import com.hnhy.ylfz.mvp.model.bean.Message; import com.hnhy.ylfz.mvp.ui.adapter.AdapterMessage; import com.hnhy.ylfz.mvp.ui.widget.ViewNoData; import com.scwang.smart.refresh.layout.SmartRefreshLayout; import java.util.ArrayList; import java.util.List; import butterknife.BindView; import butterknife.ButterKnife; /** * Created by guc on 2019/12/17. * 描述:我的消息 */ public class ActivityMyMessage extends BaseActivity { @BindView(R.id.rcv_content) RecyclerView mRcvContent; @BindView(R.id.view_no_data) ViewNoData mViewNoData; @BindView(R.id.refresh_layout) SmartRefreshLayout mRefreshLayout; private List<Message> mDatas; private AdapterMessage mAdapter; @Override protected void onCreate(@Nullable Bundle savedInstanceState) { super.onCreate(savedInstanceState); setLightStatusBar(); setContentView(R.layout.activity_my_message); ButterKnife.bind(this); initView(); loadData(); } private void loadData() { Message message = new Message(); message.date = "2019-11-05 10:22"; message.title = "认证申请"; message.content = "您提交的认证申请已通过"; mDatas.add(message); message = new Message(); message.type = 1; message.date = "2019-10-30 16:22"; message.title = "指标警戒"; message.content = "您好,当前指标已经超过预定目标!"; mDatas.add(message); mAdapter.notifyDataSetChanged(); mViewNoData.setVisibility(mAdapter.getItemCount() > 0 ? View.GONE : View.VISIBLE); } private void initView() { mDatas = new ArrayList<>(); mAdapter = new AdapterMessage(mContext, mDatas); mRcvContent.setLayoutManager(new LinearLayoutManager(mContext)); mRcvContent.setAdapter(mAdapter); mViewNoData.setVisibility(mAdapter.getItemCount() > 0 ? View.GONE : View.VISIBLE); } }
[ "guchaochao@huiyunit.com" ]
guchaochao@huiyunit.com
81fb6562590945866ebedd8527d76c5cb126deac
b9e8ba3f2cb7cc3aec9025385129c1fdda6ec080
/src/com/click4care/wsdl/_6_5/integrationservices/ReportFormulaList.java
9be4238203bbf2e90f369bc9da1629817939fcbe
[]
no_license
petecummings/AcopyOfAcopy
af2c75a7f066515569afff364b0faf11562024f8
c83293be0bf5aa51c508df0db0f29654b56a13f9
refs/heads/master
2020-03-14T18:26:18.217011
2018-05-01T12:38:05
2018-05-01T12:38:05
131,741,148
0
0
null
null
null
null
UTF-8
Java
false
false
2,845
java
package com.click4care.wsdl._6_5.integrationservices; import java.math.BigInteger; 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.XmlRootElement; import javax.xml.bind.annotation.XmlType; import com.click4care.thinkhealth._6_5.dto.ReportFormulaType; /** * <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="reportFormulas" type="{http://www.click4care.com/thinkhealth/6.5/dto}report_formula_type" maxOccurs="unbounded" minOccurs="0"/> * &lt;element name="queryState" type="{http://click4care.com/wsdl/6.5/integrationServices}queryStateType" minOccurs="0"/> * &lt;/sequence> * &lt;/restriction> * &lt;/complexContent> * &lt;/complexType> * </pre> * * */ @XmlAccessorType(XmlAccessType.FIELD) @XmlType(name = "", propOrder = { "reportFormulas", "queryState" }) @XmlRootElement(name = "reportFormulaList") public class ReportFormulaList { protected List<ReportFormulaType> reportFormulas; protected BigInteger queryState; /** * Gets the value of the reportFormulas 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 reportFormulas property. * * <p> * For example, to add a new item, do as follows: * <pre> * getReportFormulas().add(newItem); * </pre> * * * <p> * Objects of the following type(s) are allowed in the list * {@link ReportFormulaType } * * */ public List<ReportFormulaType> getReportFormulas() { if (reportFormulas == null) { reportFormulas = new ArrayList<ReportFormulaType>(); } return this.reportFormulas; } /** * Gets the value of the queryState property. * * @return * possible object is * {@link BigInteger } * */ public BigInteger getQueryState() { return queryState; } /** * Sets the value of the queryState property. * * @param value * allowed object is * {@link BigInteger } * */ public void setQueryState(BigInteger value) { this.queryState = value; } }
[ "you@example.com" ]
you@example.com
7a0753df62da8337211c18f663738bc54ec3202f
4bc744be758f1852399edc405c2a81a9db67c643
/app/src/main/java/com/ydys/qmb/model/PayInfoModelImp.java
3f23af71f3fe6e1f82b45889c7e10c1ca563794f
[]
no_license
YangChengTeam/bename
f405e8b3ec46f4352ad9a8a5893241131e2b22ce
a33d01974ba071db2fc3d153ccbb3706e0b24925
refs/heads/master
2020-08-21T11:09:35.460732
2019-11-05T00:41:23
2019-11-05T00:41:23
216,146,552
1
0
null
null
null
null
UTF-8
Java
false
false
3,314
java
package com.ydys.qmb.model; import android.content.Context; import com.alibaba.fastjson.JSONException; import com.alibaba.fastjson.JSONObject; import com.ydys.qmb.api.PoetryInfoService; import com.ydys.qmb.api.VipInfoService; import com.ydys.qmb.base.BaseModel; import com.ydys.qmb.base.IBaseRequestCallBack; import com.ydys.qmb.bean.PayInfoRet; import com.ydys.qmb.bean.PayRequestParams; import com.ydys.qmb.bean.PoetryInfoRet; import okhttp3.MediaType; import okhttp3.RequestBody; import rx.Subscriber; import rx.android.schedulers.AndroidSchedulers; import rx.schedulers.Schedulers; import rx.subscriptions.CompositeSubscription; /** * Created by admin on 2017/4/7. */ public class PayInfoModelImp extends BaseModel implements PayInfoModel<PayInfoRet> { private Context context; private VipInfoService vipInfoService; private CompositeSubscription mCompositeSubscription; public PayInfoModelImp(Context context) { this.context = context; vipInfoService = mRetrofit.create(VipInfoService.class); mCompositeSubscription = new CompositeSubscription(); } @Override public void createOrder(PayRequestParams payParams, IBaseRequestCallBack<PayInfoRet> iBaseRequestCallBack) { JSONObject params = new JSONObject(); try { params.put("user_id", payParams.getUser_id()); params.put("type", payParams.getType() + ""); params.put("phone", payParams.getPhone() + ""); params.put("openid", payParams.getOpenid()); params.put("pay_way", payParams.getPay_way()); params.put("amount", payParams.getAmount() + ""); params.put("xing", payParams.getXing()); params.put("title", payParams.getTitle()); } catch (JSONException e) { e.printStackTrace(); } RequestBody requestBody = RequestBody.create(MediaType.parse("application/json"), params.toString()); mCompositeSubscription.add(vipInfoService.createOrder(requestBody) .observeOn(AndroidSchedulers.mainThread()) .subscribeOn(Schedulers.io()) .subscribe(new Subscriber<PayInfoRet>() { @Override public void onStart() { super.onStart(); //onStart它总是在 subscribe 所发生的线程被调用 ,如果你的subscribe不是主线程,则会出错,则需要指定线程; iBaseRequestCallBack.beforeRequest(); } @Override public void onCompleted() { //回调接口:请求已完成,可以隐藏progress iBaseRequestCallBack.requestComplete(); } @Override public void onError(Throwable e) { //回调接口:请求异常 iBaseRequestCallBack.requestError(e); } @Override public void onNext(PayInfoRet payInfoRet) { //回调接口:请求成功,获取实体类对象 iBaseRequestCallBack.requestSuccess(payInfoRet); } })); } }
[ "512710257@qq.com" ]
512710257@qq.com
db130bba76c71ce0a74250b7841d708e43eb8afc
982f6c3a3c006d2b03f4f53c695461455bee64e9
/src/main/java/com/alipay/api/domain/AlipayMarketingCardActivateformQueryModel.java
60eb11f335d697a3c930fb64d02689d72a349b5f
[ "Apache-2.0" ]
permissive
zhaomain/Alipay-Sdk
80ffc0505fe81cc7dd8869d2bf9a894b823db150
552f68a2e7c10f9ffb33cd8e0036b0643c7c2bb3
refs/heads/master
2022-11-15T03:31:47.418847
2020-07-09T12:18:59
2020-07-09T12:18:59
null
0
0
null
null
null
null
UTF-8
Java
false
false
1,372
java
package com.alipay.api.domain; import com.alipay.api.AlipayObject; import com.alipay.api.internal.mapping.ApiField; /** * 查询用户授权的开放表单信息 * * @author auto create * @since 1.0, 2020-06-19 13:47:29 */ public class AlipayMarketingCardActivateformQueryModel extends AlipayObject { private static final long serialVersionUID = 2559777461134651468L; /** * 开放表单信息查询业务类型,可选类型如下: MEMBER_CARD -- 会员卡开卡 */ @ApiField("biz_type") private String bizType; /** * 查询用户表单提交信息的请求id,在用户授权表单确认提交后跳转商户页面url时返回此参数。 */ @ApiField("request_id") private String requestId; /** * 会员卡模板id。使用会员卡模板创建接口(alipay.marketing.card.template.create)返回的结果 */ @ApiField("template_id") private String templateId; public String getBizType() { return this.bizType; } public void setBizType(String bizType) { this.bizType = bizType; } public String getRequestId() { return this.requestId; } public void setRequestId(String requestId) { this.requestId = requestId; } public String getTemplateId() { return this.templateId; } public void setTemplateId(String templateId) { this.templateId = templateId; } }
[ "ben.zy@antfin.com" ]
ben.zy@antfin.com
2af1e96bf0aa04f4ae52645370c5ac1207239155
fa91450deb625cda070e82d5c31770be5ca1dec6
/Diff-Raw-Data/8/8_61202a48bd6fd4d43f644c86c3ce02255708d33b/SchedulerTest/8_61202a48bd6fd4d43f644c86c3ce02255708d33b_SchedulerTest_s.java
b1daf80ad2ca65757bcc68bfe715cc85755d9cc9
[]
no_license
zhongxingyu/Seer
48e7e5197624d7afa94d23f849f8ea2075bcaec0
c11a3109fdfca9be337e509ecb2c085b60076213
refs/heads/master
2023-07-06T12:48:55.516692
2023-06-22T07:55:56
2023-06-22T07:55:56
259,613,157
6
2
null
2023-06-22T07:55:57
2020-04-28T11:07:49
null
UTF-8
Java
false
false
4,573
java
package com.taobao.top.link.schedule; import static org.junit.Assert.*; import java.util.Queue; import java.util.concurrent.ConcurrentLinkedQueue; import java.util.concurrent.CountDownLatch; import java.util.concurrent.Semaphore; import org.junit.Test; import com.taobao.top.link.DefaultLoggerFactory; import com.taobao.top.link.LinkException; import com.taobao.top.link.Text; public class SchedulerTest { @Test public void queue_test() { Queue<String> queue = new ConcurrentLinkedQueue<String>(); queue.add("123"); assertNotNull(queue.peek()); assertNotNull(queue.poll()); } @Test public void semaphore_test() throws InterruptedException { final Semaphore semaphore = new Semaphore(0); new Thread(new Runnable() { @Override public void run() { try { Thread.sleep(100); } catch (InterruptedException e) { } semaphore.release(); try { Thread.sleep(100); } catch (InterruptedException e) { } semaphore.release(); semaphore.release(); } }).start(); semaphore.acquire(); semaphore.acquire(2); } @Test public void start_stop_test() throws InterruptedException { Scheduler<String> scheduler = new Scheduler<String>(); scheduler.start(); Thread.sleep(500); scheduler.stop(); } @Test public void schedule_test() throws InterruptedException, LinkException { Scheduler<String> scheduler = new Scheduler<String>(); scheduler.start(); final CountDownLatch latch = new CountDownLatch(1); scheduler.schedule("user", new Runnable() { @Override public void run() { latch.countDown(); } }); latch.await(); scheduler.stop(); } @Test public void drop_test() throws InterruptedException, LinkException { final Scheduler<String> scheduler = new Scheduler<String>(); scheduler.setUserMaxPendingCount(10000); scheduler.start(); new Thread(new Runnable() { @Override public void run() { while (true) { try { scheduler.schedule("user", new Runnable() { @Override public void run() { } }); } catch (LinkException e) { e.printStackTrace(); } } } }).start(); scheduler.drop("user"); scheduler.stop(); } @Test(expected = LinkException.class) public void got_max_test() throws InterruptedException, LinkException { Scheduler<String> scheduler = new Scheduler<String>(); scheduler.setUserMaxPendingCount(10); scheduler.start(); for (int i = 0; i < 100; i++) { try { scheduler.schedule("user", new Runnable() { @Override public void run() { } }); } catch (LinkException e) { scheduler.stop(); assertEquals(String.format(Text.SCHEDULE_GOT_MAX, 10), e.getMessage()); throw e; } } } @Test public void schedule_sequence_test() throws InterruptedException, LinkException { final Scheduler<String> scheduler = new Scheduler<String>(new DefaultLoggerFactory(true, true, true, true, true)); scheduler.setUserMaxPendingCount(10000); scheduler.start(); int count = 1000; final CountDownLatch latch = new CountDownLatch(count); long begin = System.currentTimeMillis(); for (int i = 0; i < count; i++) { scheduler.schedule("user", new Runnable() { @Override public void run() { latch.countDown(); } }); } latch.await(); System.out.println(count + " cost=" + (System.currentTimeMillis() - begin)); scheduler.stop(); // 1000 cost=36 } @Test public void schedule_threaded_test() throws InterruptedException, LinkException { final Scheduler<String> scheduler = new Scheduler<String>(new DefaultLoggerFactory(true, true, true, true, true)); scheduler.setUserMaxPendingCount(1000000); scheduler.start(); final int count = 1000; int thread = 4; final CountDownLatch latch = new CountDownLatch(count * thread); long begin = System.currentTimeMillis(); for (int i = 0; i < thread; i++) { new Thread(new Runnable() { @Override public void run() { for (int i = 0; i < count; i++) { try { scheduler.schedule("user" + i, new Runnable() { @Override public void run() { latch.countDown(); } }); } catch (LinkException e) { e.printStackTrace(); } } } }).start(); } latch.await(); System.out.println(count * thread + " cost=" + (System.currentTimeMillis() - begin)); scheduler.stop(); // 1000 cost=182 } }
[ "yuzhongxing88@gmail.com" ]
yuzhongxing88@gmail.com
b2b1d4410097d2fe0d2e7f7892d98b4233f6da2d
3ef55e152decb43bdd90e3de821ffea1a2ec8f75
/large/module1145_public/tests/more/src/java/module1145_public_tests_more/a/Foo0.java
0757de8c7ba84aea6087cfffbed329c896eb92ea
[ "BSD-3-Clause" ]
permissive
salesforce/bazel-ls-demo-project
5cc6ef749d65d6626080f3a94239b6a509ef145a
948ed278f87338edd7e40af68b8690ae4f73ebf0
refs/heads/master
2023-06-24T08:06:06.084651
2023-03-14T11:54:29
2023-03-14T11:54:29
241,489,944
0
5
BSD-3-Clause
2023-03-27T11:28:14
2020-02-18T23:30:47
Java
UTF-8
Java
false
false
1,318
java
package module1145_public_tests_more.a; import java.nio.file.*; import java.sql.*; import java.util.logging.*; /** * Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut * labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. * Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet. * * @see javax.annotation.processing.Completion * @see javax.lang.model.AnnotatedConstruct * @see javax.management.Attribute */ @SuppressWarnings("all") public abstract class Foo0<M> implements module1145_public_tests_more.a.IFoo0<M> { javax.naming.directory.DirContext f0 = null; javax.net.ssl.ExtendedSSLSession f1 = null; javax.rmi.ssl.SslRMIClientSocketFactory f2 = null; public M element; public static Foo0 instance; public static Foo0 getInstance() { return instance; } public static <T> T create(java.util.List<T> input) { return null; } public String getName() { return element.toString(); } public void setName(String string) { return; } public M get() { return element; } public void set(Object element) { this.element = (M)element; } public M call() throws Exception { return (M)getInstance().call(); } }
[ "gwagenknecht@salesforce.com" ]
gwagenknecht@salesforce.com
62892ede9bf087b92d96eec261335a1a53327f07
631b0d5bf3c08be14d95663ba19fcb53124b262d
/src/main/scala/com/builtbroken/mc/framework/access/global/gui/frame/group/nodes/GuiFrameGroupNodes.java
61f18fd9f3f3c816aeb8132f65b25664986dba00
[]
no_license
VoltzEngine-Project/Lib-Access
902b34460b2a91dd7ad1af4234cf8c05f9a2dcff
848b29cb4ad2450ff7c8939b4c82b56a3744a606
refs/heads/master
2021-01-18T16:42:41.560934
2018-06-30T04:42:07
2018-06-30T04:42:07
86,756,250
0
0
null
null
null
null
UTF-8
Java
false
false
3,701
java
package com.builtbroken.mc.framework.access.global.gui.frame.group.nodes; import com.builtbroken.mc.framework.access.global.gui.frame.group.GuiSubFrameGroup; import com.builtbroken.mc.framework.access.global.gui.frame.main.GuiFrameCenter; import com.builtbroken.mc.framework.access.global.packets.PacketAccessGui; import com.builtbroken.mc.framework.access.perm.Permission; import com.builtbroken.mc.framework.access.perm.Permissions; import com.builtbroken.mc.prefab.gui.GuiButton2; import com.builtbroken.mc.prefab.gui.components.GuiArray; import com.builtbroken.mc.prefab.gui.components.GuiField; import com.builtbroken.mc.prefab.gui.pos.GuiRelativePos; import com.builtbroken.mc.prefab.gui.pos.HugBottom; import com.builtbroken.mc.prefab.gui.pos.size.GuiRelativeSize; import net.minecraft.client.Minecraft; import net.minecraft.client.gui.GuiButton; /** * @see <a href="https://github.com/BuiltBrokenModding/VoltzEngine/blob/development/license.md">License</a> for what you can and can't do with the code. * Created by Dark(DarkGuardsman, Robert) on 4/25/2017. */ public class GuiFrameGroupNodes extends GuiSubFrameGroup<GuiFrameGroupNodes> { public String[] nodes; public static int rowSpacingY = 10; public static int rows = 15; public GuiArray groupArray; public GuiField nodeField; public GuiButton2 addButton; public GuiFrameGroupNodes(GuiFrameCenter parent, String groupID, int id, int x, int y) { super(parent, groupID, id, x, y); } @Override public void initGui() { super.initGui(); if (getGroup() != null) { groupArray = add(new GuiArray(new NodeArrayCallback(this), 1, 0, 0, rows, rowSpacingY)); groupArray.setRelativePosition(new GuiRelativePos(this, 0, 20)); groupArray.setWidth(200); nodeField = add(new GuiField(0, 0)); nodeField.setRelativePosition(new HugBottom(this, 1, -41, true)); nodeField.setRelativeSize(new GuiRelativeSize(this, -55, 20).setUseHostHeight(false)); addButton = add(new GuiButton2(2, 0, 0, "Add")); addButton.setWidth(50); addButton.setRelativePosition(new HugBottom(this, -addButton.getWidth(), -40, false)); } updatePositions(); } @Override protected void update(Minecraft mc, int mouseX, int mouseY) { super.update(mc, mouseX, mouseY); if (getGroup() == null || nodes == null || nodes != null && getGroup().getNodes().size() != nodes.length) //TODO check if exact match { if (getGroup() != null) { nodes = new String[getGroup().getNodes().size()]; int i = 0; for (String node : getGroup().getNodes()) { nodes[i++] = node; } } else { nodes = null; } groupArray.reloadEntries(); } if (getGroup() != null) { addButton.setEnabled(canEditGroup() && hasNodes(Permissions.groupPermissionAdd)); } } protected boolean hasNodes(Permission... nodes) { return getHost().doesPlayerHavePerms(nodes); } @Override public void actionPerformed(GuiButton button) { int id = button.id; if (id == 2) { if (nodeField.getText() != null && !nodeField.getText().isEmpty()) { PacketAccessGui.addNodeToGroup(getHost().currentProfile.getID(), groupID, nodeField.getText()); } } else { super.actionPerformed(button); } } }
[ "rseifert.phone@gmail.com" ]
rseifert.phone@gmail.com
2d48d4a3f46dc52e562b218e503c31e6f199f7d2
82134d53ae99b3105b817cc457b8f506ebecb842
/vbox-app/src/main/java/com/kedzie/vbox/api/IMachineEvent.java
1fbd0a6a74e3d4cc60aa6703a321a485942a5bc8
[]
no_license
Arif4405/VBoxManager
5a63e8a036caaa247ed4ac5edf594f4f60881ea4
e8fe0df525e90730deba77006bb6c4c1df56416a
refs/heads/master
2023-05-05T21:34:57.530327
2019-10-02T15:00:50
2019-10-02T15:00:50
null
0
0
null
null
null
null
UTF-8
Java
false
false
956
java
package com.kedzie.vbox.api; import java.util.HashMap; import java.util.Map; import android.os.Parcel; import android.os.Parcelable; import com.kedzie.vbox.soap.KSOAP; import com.kedzie.vbox.soap.VBoxSvc; @KSOAP() public interface IMachineEvent extends IEvent, Parcelable { static ClassLoader loader = IEvent.class.getClassLoader(); public static final Parcelable.Creator<IMachineEvent> CREATOR = new Parcelable.Creator<IMachineEvent>() { public IMachineEvent createFromParcel(Parcel in) { VBoxSvc vmgr = in.readParcelable(loader); String id = in.readString(); Map<String, Object> cache = new HashMap<String, Object>(); in.readMap(cache, loader); return (IMachineEvent) vmgr.getProxy(IMachineEvent.class, id, cache); } public IMachineEvent[] newArray(int size) { return new IMachineEvent[size]; } }; @KSOAP(cacheable=true, prefix="IMachineEvent") public String getMachineId(); }
[ "mark.kedzierski@gmail.com" ]
mark.kedzierski@gmail.com
3c2013d5a37c6655b703c3a1fa877a87210b1dde
36995a4a2672b51f9662a21979e69e57eeca0dca
/src/main/java/org/xbib/graphics/chart/io/vector/intermediate/commands/SetClipCommand.java
4d865da0addbadb55bf2b36647665bb4fddb6351
[]
no_license
jprante/chart
211e4dd0ac674919de88e7d170e5e1444617e144
71403bc3ab669c9ed0d403e6a8e6c29c884a3f99
refs/heads/master
2023-08-14T17:46:18.688343
2020-10-07T22:43:54
2020-10-07T22:43:54
146,636,273
0
0
null
null
null
null
UTF-8
Java
false
false
220
java
package org.xbib.graphics.chart.io.vector.intermediate.commands; import java.awt.Shape; public class SetClipCommand extends StateCommand<Shape> { public SetClipCommand(Shape shape) { super(shape); } }
[ "joergprante@gmail.com" ]
joergprante@gmail.com
c477df81998f5d6b2a2d72933834b945c035ee06
09e32567a083c4e68e1845244fd92650d7a5df27
/Fact.java
a6bb1327c88dd563f601bd2a7377a362427bc72b
[]
no_license
akash65/Java
a3f30cb7d18f6f5434bfd4467e350c0d24c4e19a
89e8d53c2e08b1c17e8388438e980e888a177710
refs/heads/master
2020-03-21T07:39:54.006680
2018-06-27T04:24:18
2018-06-27T04:24:18
138,292,305
0
0
null
null
null
null
UTF-8
Java
false
false
1,090
java
import java.util.Scanner; class Fact{ /*for largest numbers public static void main(String[] args){ int fact=1; Scanner sc=new Scanner(System.in); System.out.println("enter the number to find factorial:"); int num=sc.nextInt(); if(num<0){ System.out.println("enter only positive number"); } else if(num==0){ System.out.println("1"); } else{ for(int i=1;i<=num;i++){ fact=num*(num-1); } System.out.println("value is"+fact); } }*/ //using functions public static void main(String[] args){ int fact=1; Scanner sc=new Scanner(System.in); System.out.println("enter the number to find factorial:"); int num=sc.nextInt(); fact=fact(num); System.out.println("value is"+fact); sc.close(); } static int fact(int n){ if (n == 0) return 1; else return(n * fact(n-1)); } }
[ "you@example.com" ]
you@example.com
4221fb95175324b387e8900ce442b56aa4268897
cca87c4ade972a682c9bf0663ffdf21232c9b857
/com/tencent/mm/protocal/c/ahy.java
26b98202eb32e9a4a433f698a66114a1adae73dc
[]
no_license
ZoranLi/wechat_reversing
b246d43f7c2d7beb00a339e2f825fcb127e0d1a1
36b10ef49d2c75d69e3c8fdd5b1ea3baa2bba49a
refs/heads/master
2021-07-05T01:17:20.533427
2017-09-25T09:07:33
2017-09-25T09:07:33
104,726,592
12
1
null
null
null
null
UTF-8
Java
false
false
3,076
java
package com.tencent.mm.protocal.c; import a.a.a.b; import a.a.a.c.a; import java.util.LinkedList; public final class ahy extends avp { public LinkedList<bpl> tMf = new LinkedList(); protected final int a(int i, Object... objArr) { if (i == 0) { a aVar = (a) objArr[0]; if (this.tZe == null) { throw new b("Not all required fields were included: BaseResponse"); } if (this.tZe != null) { aVar.eQ(1, this.tZe.aUk()); this.tZe.a(aVar); } aVar.d(2, 8, this.tMf); return 0; } else if (i == 1) { if (this.tZe != null) { r0 = a.a.a.a.eN(1, this.tZe.aUk()) + 0; } else { r0 = 0; } return r0 + a.a.a.a.c(2, 8, this.tMf); } else if (i == 2) { r0 = (byte[]) objArr[0]; this.tMf.clear(); a.a.a.a.a aVar2 = new a.a.a.a.a(r0, unknownTagHandler); for (r0 = com.tencent.mm.bd.a.a(aVar2); r0 > 0; r0 = com.tencent.mm.bd.a.a(aVar2)) { if (!super.a(aVar2, this, r0)) { aVar2.cid(); } } if (this.tZe != null) { return 0; } throw new b("Not all required fields were included: BaseResponse"); } else if (i != 3) { return -1; } else { a.a.a.a.a aVar3 = (a.a.a.a.a) objArr[0]; ahy com_tencent_mm_protocal_c_ahy = (ahy) objArr[1]; int intValue = ((Integer) objArr[2]).intValue(); LinkedList En; int size; com.tencent.mm.bd.a enVar; a.a.a.a.a aVar4; boolean z; switch (intValue) { case 1: En = aVar3.En(intValue); size = En.size(); for (intValue = 0; intValue < size; intValue++) { r0 = (byte[]) En.get(intValue); enVar = new en(); aVar4 = new a.a.a.a.a(r0, unknownTagHandler); for (z = true; z; z = enVar.a(aVar4, enVar, com.tencent.mm.bd.a.a(aVar4))) { } com_tencent_mm_protocal_c_ahy.tZe = enVar; } return 0; case 2: En = aVar3.En(intValue); size = En.size(); for (intValue = 0; intValue < size; intValue++) { r0 = (byte[]) En.get(intValue); enVar = new bpl(); aVar4 = new a.a.a.a.a(r0, unknownTagHandler); for (z = true; z; z = enVar.a(aVar4, enVar, com.tencent.mm.bd.a.a(aVar4))) { } com_tencent_mm_protocal_c_ahy.tMf.add(enVar); } return 0; default: return -1; } } } }
[ "lizhangliao@xiaohongchun.com" ]
lizhangliao@xiaohongchun.com
48771d1148d09e7ea69e669c4334ee259b988c80
2e59950c3a0e32c9748c1e3303d5530f6e9b67ca
/Thinksns_v4.0/src/com/abcs/sociax/t4/adapter/AdapterFindPeopleByVerify.java
890231e3527df0c3e4ff709d04205275bd701fc7
[]
no_license
xiaozhugua/Myhuarenb
a27e87451c792a76ade79fc29d7050997ac2bdf6
9a81815ce90a7b4e5c22ff99fb8fc5e13844d326
refs/heads/master
2021-01-23T02:05:42.432793
2017-05-31T04:05:42
2017-05-31T04:05:42
92,902,840
0
1
null
null
null
null
UTF-8
Java
false
false
6,415
java
package com.abcs.sociax.t4.adapter; import com.bumptech.glide.Glide; import com.bumptech.glide.load.engine.DiskCacheStrategy; import com.handmark.pulltorefresh.library.PullToRefreshListView; import com.abcs.sociax.android.R; import com.abcs.sociax.t4.android.fragment.FragmentSociax; import com.abcs.sociax.t4.android.function.FunctionChangeFollow; import com.abcs.sociax.t4.component.GlideCircleTransform; import com.abcs.sociax.t4.component.HolderSociax; import com.abcs.sociax.t4.exception.VerifyErrorException; import com.thinksns.sociax.thinksnsbase.bean.ListData; import com.thinksns.sociax.thinksnsbase.bean.SociaxItem; import com.thinksns.sociax.thinksnsbase.exception.*; import android.view.View; import android.view.View.OnClickListener; import android.view.ViewGroup; import android.widget.AbsListView; import android.widget.ImageView; import android.widget.TextView; /** * 类说明: 根据官方验证找人 * * @author wz * @version 1.0 * @date 2014-11-4 */ public class AdapterFindPeopleByVerify extends AdapterUserFollowingList { String verify_id; public AdapterFindPeopleByVerify(FragmentSociax fragment, ListData<SociaxItem> list, int uid, String verify_id) { super(fragment, list, uid); this.verify_id = verify_id; } @Override public ListData<SociaxItem> refreshNew(int count) throws VerifyErrorException, ApiException, ListAreEmptyException, DataInvalidException { return (ListData<SociaxItem>) getApiUser().searchUserByVerifyCode( verify_id, 0, httpListener); } @Override public ListData<SociaxItem> refreshFooter(SociaxItem obj) throws VerifyErrorException, ApiException, ListAreEmptyException, DataInvalidException { return (ListData<SociaxItem>) getApiUser().searchUserByVerifyCode( verify_id, getMaxid(), httpListener); } @Override public View getView(int position, View convertView, ViewGroup parent) { HolderSociax viewHolder = null; int type = getItemViewType(position); if (convertView == null || convertView.getTag(R.id.tag_viewholder) == null) { if (type == 1) { viewHolder = new HolderSociax(); convertView = inflater.inflate(R.layout.listitem_user, null); viewHolder.tv_user_photo = (ImageView) convertView .findViewById(R.id.image_photo); viewHolder.tv_user_name = (TextView) convertView .findViewById(R.id.unnames); viewHolder.tv_user_content = (TextView) convertView .findViewById(R.id.uncontent); viewHolder.tv_user_add = (TextView) convertView .findViewById(R.id.image_add); } else if (type == 0) { convertView = inflater.inflate(R.layout.default_nobody_bg, null); holder = new HolderSociax(); holder.tv_empty_content = (TextView) convertView.findViewById(R.id.tv_empty_content); } else if (type == 2) { //加载正在加载数据的界面 convertView = inflater.inflate(R.layout.loading, null); PullToRefreshListView listView = (PullToRefreshListView)getPullRefreshView(); int width = listView.getWidth(); int height = listView.getHeight() - 100; AbsListView.LayoutParams params = new AbsListView.LayoutParams(width, height); convertView.setLayoutParams(params); } convertView.setTag(R.id.tag_viewholder, viewHolder); } else { viewHolder = (HolderSociax) convertView.getTag(R.id.tag_viewholder); } if (type == 1) { convertView.setTag(R.id.tag_search_user, getItem(position)); Glide.with(context).load(getItem(position).getUserface()) .diskCacheStrategy(DiskCacheStrategy.ALL) .transform(new GlideCircleTransform(context)) .crossFade() .into(viewHolder.tv_user_photo); viewHolder.tv_user_name.setText(getItem(position).getUname()); String intro = getItem(position).getIntro(); if (intro == null || intro.isEmpty() || intro.equals("null")) intro = "这家伙很懒,什么也没留下"; viewHolder.tv_user_content.setText(intro); viewHolder.tv_user_add.setVisibility(View.VISIBLE); viewHolder.tv_user_add.setTag(R.id.tag_position, position); viewHolder.tv_user_add.setTag(R.id.tag_follow, getItem(position)); if (getItem(position).getFollowing().equals("0")) { //加关注 viewHolder.tv_user_add.setBackgroundResource(R.drawable.roundbackground_green_digg); viewHolder.tv_user_add.setText(R.string.fav_add_follow); viewHolder.tv_user_add.setTextColor(context.getResources().getColor(R.color.fav_border)); } else { //取消关注 viewHolder.tv_user_add.setBackgroundResource(R.drawable.roundbackground_fav_true); viewHolder.tv_user_add.setText(R.string.fav_followed); viewHolder.tv_user_add.setTextColor(context.getResources().getColor(R.color.fav_text_true)); } viewHolder.tv_user_add.setOnClickListener(new OnClickListener() { @Override public void onClick(View v) { FunctionChangeFollow fcChangeFollow = new FunctionChangeFollow( context, AdapterFindPeopleByVerify.this, v); fcChangeFollow.changeListFollow(); } }); } else if (type == 0) { holder.tv_empty_content.setText("当前分类下还没有小伙伴"); } return convertView; } /** * 底部追加信息 * * @param list */ public void addFooter(ListData<SociaxItem> list) { super.addFooter(list); } public void addHeader(ListData<SociaxItem> list) { super.addHeader(list); } @Override public int getMaxid() { if (getLast() == null) return 0; else return getLast().getId(); } }
[ "1343012815@qq.com" ]
1343012815@qq.com
8b614d81eeed26d9a39fc9ada116ffcc26033ad4
71f52fc512d887b4733a032f9be8d130169f8396
/src/main/java/com/sunny/service/UserService.java
058e242d0db3aeec76ec53707476e0c226ee18c9
[]
no_license
sadskkaldj/-
ac9239db896d85fae6f9c96a293a30b46cbf73b6
0dcefb578414372ecc0bebbb57da7d1bb12d6d80
refs/heads/master
2020-09-17T00:44:38.922095
2019-11-12T03:32:46
2019-11-12T03:32:46
null
0
0
null
null
null
null
UTF-8
Java
false
false
221
java
package com.sunny.service; /** * @Classname UserService * @Description 微冷的雨训练营 www.cnblogs.com/weilengdeyu * @Date 2019/11/12 11:29 * @Created by Happy-微冷的雨 */ public interface UserService { }
[ "yymqqc@126.com" ]
yymqqc@126.com
4f0c04f8454e98466a8d06e2df37776868b5fade
57fd6326757d8dcddc4aa46b852464895e5683e4
/src/main/java/com/webank/blockchain/data/stash/db/model/DylamicTableInfo.java
1f3242186a356f934095c1064d3068257ba2c149
[ "Apache-2.0", "Apache-1.1" ]
permissive
Skkypy/Data-Stash
c29cba6aad841c8f102719f831e17dcc52ab57c7
40239f1efc1264e27296114087cb55d5b260f5f4
refs/heads/master
2023-03-23T17:53:35.887807
2021-03-22T09:49:48
2021-03-22T09:49:48
null
0
0
null
null
null
null
UTF-8
Java
false
false
1,017
java
/** * Copyright 2020 Webank. * * <p>Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file * except in compliance with the License. You may obtain a copy of the License at * * <p>http://www.apache.org/licenses/LICENSE-2.0 * * <p>Unless required by applicable law or agreed to in writing, software distributed under the * License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either * express or implied. See the License for the specific language governing permissions and * limitations under the License. */ package com.webank.blockchain.data.stash.db.model; import lombok.Data; import lombok.EqualsAndHashCode; import lombok.ToString; /** * UserTableInfo * * @Description: UserTableInfo * @author graysonzhang * @data 2019-08-08 18:08:03 * */ @Data @ToString(callSuper = true) @EqualsAndHashCode(callSuper = true) public class DylamicTableInfo extends BaseInfo{ private String fields; private String values; }
[ "njumjy06@126.com" ]
njumjy06@126.com